aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--.gitignore34
-rw-r--r--.gitmodules3
-rw-r--r--.mailmap14
-rw-r--r--.travis.yml36
-rw-r--r--Dockerfile39
-rw-r--r--Godeps/Godeps.json131
-rw-r--r--Godeps/Readme5
-rw-r--r--Godeps/_workspace/.gitignore2
-rw-r--r--Godeps/_workspace/src/code.google.com/p/go-uuid/uuid/LICENSE27
-rw-r--r--Godeps/_workspace/src/code.google.com/p/go-uuid/uuid/dce.go84
-rw-r--r--Godeps/_workspace/src/code.google.com/p/go-uuid/uuid/doc.go8
-rw-r--r--Godeps/_workspace/src/code.google.com/p/go-uuid/uuid/hash.go53
-rw-r--r--Godeps/_workspace/src/code.google.com/p/go-uuid/uuid/node.go101
-rw-r--r--Godeps/_workspace/src/code.google.com/p/go-uuid/uuid/time.go132
-rw-r--r--Godeps/_workspace/src/code.google.com/p/go-uuid/uuid/util.go43
-rw-r--r--Godeps/_workspace/src/code.google.com/p/go-uuid/uuid/uuid.go163
-rw-r--r--Godeps/_workspace/src/code.google.com/p/go-uuid/uuid/uuid_test.go390
-rw-r--r--Godeps/_workspace/src/code.google.com/p/go-uuid/uuid/version1.go41
-rw-r--r--Godeps/_workspace/src/code.google.com/p/go-uuid/uuid/version4.go25
-rw-r--r--Godeps/_workspace/src/code.google.com/p/snappy-go/snappy/decode.go124
-rw-r--r--Godeps/_workspace/src/code.google.com/p/snappy-go/snappy/encode.go174
-rw-r--r--Godeps/_workspace/src/code.google.com/p/snappy-go/snappy/snappy.go38
-rw-r--r--Godeps/_workspace/src/code.google.com/p/snappy-go/snappy/snappy_test.go261
-rw-r--r--Godeps/_workspace/src/github.com/codegangsta/cli/.travis.yml6
-rw-r--r--Godeps/_workspace/src/github.com/codegangsta/cli/LICENSE21
-rw-r--r--Godeps/_workspace/src/github.com/codegangsta/cli/README.md298
-rw-r--r--Godeps/_workspace/src/github.com/codegangsta/cli/app.go321
-rw-r--r--Godeps/_workspace/src/github.com/codegangsta/cli/app_test.go622
-rw-r--r--Godeps/_workspace/src/github.com/codegangsta/cli/autocomplete/bash_autocomplete13
-rw-r--r--Godeps/_workspace/src/github.com/codegangsta/cli/autocomplete/zsh_autocomplete5
-rw-r--r--Godeps/_workspace/src/github.com/codegangsta/cli/cli.go19
-rw-r--r--Godeps/_workspace/src/github.com/codegangsta/cli/cli_test.go100
-rw-r--r--Godeps/_workspace/src/github.com/codegangsta/cli/command.go177
-rw-r--r--Godeps/_workspace/src/github.com/codegangsta/cli/command_test.go49
-rw-r--r--Godeps/_workspace/src/github.com/codegangsta/cli/context.go344
-rw-r--r--Godeps/_workspace/src/github.com/codegangsta/cli/context_test.go111
-rw-r--r--Godeps/_workspace/src/github.com/codegangsta/cli/flag.go454
-rw-r--r--Godeps/_workspace/src/github.com/codegangsta/cli/flag_test.go742
-rw-r--r--Godeps/_workspace/src/github.com/codegangsta/cli/help.go215
-rw-r--r--Godeps/_workspace/src/github.com/codegangsta/cli/helpers_test.go19
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/ethash/.gitignore12
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/ethash/.travis.yml6
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/ethash/CMakeLists.txt21
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/ethash/MANIFEST.in17
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/ethash/Makefile6
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/ethash/README.md7
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/ethash/Vagrantfile7
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/ethash/cmake/modules/CMakeParseArguments.cmake161
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/ethash/cmake/modules/FindCryptoPP.cmake108
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/ethash/cmake/modules/FindOpenCL.cmake148
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/ethash/cmake/modules/FindPackageHandleStandardArgs.cmake382
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/ethash/cmake/modules/FindPackageMessage.cmake57
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/ethash/cryptopp/CMakeLists.txt13
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/ethash/ethash.go437
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/ethash/js/LICENSE22
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/ethash/js/ethash.js190
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/ethash/js/keccak.js404
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/ethash/js/makekeccak.js201
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/ethash/js/test.js53
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/ethash/js/util.js100
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/ethash/setup.py33
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/ethash/src/benchmark/CMakeLists.txt53
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/ethash/src/benchmark/benchmark.cpp260
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash-cl/CMakeLists.txt40
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash-cl/bin2h.cmake86
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash-cl/cl.hpp12906
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash-cl/ethash_cl_miner.cpp323
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash-cl/ethash_cl_miner.h44
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash-cl/ethash_cl_miner_kernel.cl461
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash/CMakeLists.txt38
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash/compiler.h33
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash/data_sizes.h812
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash/endian.h74
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash/ethash.h116
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash/fnv.h38
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash/internal.c300
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash/internal.h48
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash/sha3.c151
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash/sha3.h27
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash/sha3_cryptopp.cpp34
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash/sha3_cryptopp.h15
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash/util.c41
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash/util.h47
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/ethash/src/python/core.c305
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/ethash/test/c/CMakeLists.txt30
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/ethash/test/c/test.cpp228
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/ethash/test/c/test.sh19
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/ethash/test/go/ethash_test.go82
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/ethash/test/go/test.sh20
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/ethash/test/python/.gitignore1
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/ethash/test/python/requirements.txt3
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/ethash/test/python/test.sh19
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/ethash/test/python/test_pyethash.py105
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/ethash/test/test.sh31
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/.gitignore5
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/.gitmodules3
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/README.md12
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/all.cpp16
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/cpp/api.cpp26
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/cpp/api.h14
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent.go27
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/.gitignore12
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/MANIFEST.in5
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/Makefile55
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/README.md3
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/bignum.cpp112
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/bignum.h41
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/cmdline.cpp132
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/compiler.cpp554
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/compiler.h43
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/example.cpp11
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/collatz.se11
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/counterparty/counterparty.se274
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/counterparty/heap.se69
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/crowdfund.se53
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/cyberdyne/futarchy.se136
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/cyberdyne/heap.se55
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/cyberdyne/market.se117
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/cyberdyne/subcurrency.se35
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/cyberdyne/test.py39
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/datafeed.se12
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/ecc/ecrecover.se40
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/ecc/ecrecover_compiled.evm1
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/ecc/jacobian_add.se32
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/ecc/jacobian_double.se16
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/ecc/jacobian_mul.se37
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/ecc/modexp.se11
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/ecc/substitutes.py78
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/ecc/test.py129
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/eth15/channel.se45
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/eth15/map.se19
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/eth15/multiforward.se14
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/eth15/shadowchain.se166
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/fixedpoint.se31
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/long_integer_macros.se116
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/mul2.se2
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/mutuala.se187
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/namecoin.se7
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/peano.se43
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/returnten.se4
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/schellingcoin/quicksort.se33
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/schellingcoin/quicksort_pairs.se46
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/schellingcoin/schellingcoin.se94
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/schellingcoin/schellingdollar.se171
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/schellinghelper.se1
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/short_namecoin.se3
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/subcurrency.se11
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/funcs.cpp35
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/funcs.h35
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/functions.cpp203
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/functions.h39
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/lllparser.cpp70
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/lllparser.h13
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/opcodes.cpp154
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/opcodes.h45
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/optimize.cpp98
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/optimize.h19
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/parser.cpp430
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/parser.h13
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/preprocess.cpp299
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/preprocess.h58
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/pyserpent.cpp173
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/pyserpent.py1
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/rewriter.cpp804
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/rewriter.h16
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/rewriteutils.cpp211
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/rewriteutils.h51
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/serpent.py201
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/setup.py46
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/tokenize.cpp115
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/tokenize.h16
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/util.cpp305
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/util.h127
-rw-r--r--Godeps/_workspace/src/github.com/ethereum/serpent-go/tests/main.go21
-rw-r--r--Godeps/_workspace/src/github.com/howeyc/fsnotify/.gitignore5
-rw-r--r--Godeps/_workspace/src/github.com/howeyc/fsnotify/AUTHORS28
-rw-r--r--Godeps/_workspace/src/github.com/howeyc/fsnotify/CHANGELOG.md160
-rw-r--r--Godeps/_workspace/src/github.com/howeyc/fsnotify/CONTRIBUTING.md7
-rw-r--r--Godeps/_workspace/src/github.com/howeyc/fsnotify/LICENSE28
-rw-r--r--Godeps/_workspace/src/github.com/howeyc/fsnotify/README.md92
-rw-r--r--Godeps/_workspace/src/github.com/howeyc/fsnotify/example_test.go34
-rw-r--r--Godeps/_workspace/src/github.com/howeyc/fsnotify/fsnotify.go111
-rw-r--r--Godeps/_workspace/src/github.com/howeyc/fsnotify/fsnotify_bsd.go496
-rw-r--r--Godeps/_workspace/src/github.com/howeyc/fsnotify/fsnotify_linux.go304
-rw-r--r--Godeps/_workspace/src/github.com/howeyc/fsnotify/fsnotify_open_bsd.go11
-rw-r--r--Godeps/_workspace/src/github.com/howeyc/fsnotify/fsnotify_open_darwin.go11
-rw-r--r--Godeps/_workspace/src/github.com/howeyc/fsnotify/fsnotify_symlink_test.go74
-rw-r--r--Godeps/_workspace/src/github.com/howeyc/fsnotify/fsnotify_test.go1010
-rw-r--r--Godeps/_workspace/src/github.com/howeyc/fsnotify/fsnotify_windows.go598
-rw-r--r--Godeps/_workspace/src/github.com/huin/goupnp/LICENSE23
-rw-r--r--Godeps/_workspace/src/github.com/huin/goupnp/README.md14
-rw-r--r--Godeps/_workspace/src/github.com/huin/goupnp/cmd/example_httpu_serving/example_httpu_serving.go20
-rw-r--r--Godeps/_workspace/src/github.com/huin/goupnp/cmd/example_internetgateway1/example_internetgateway1.go67
-rw-r--r--Godeps/_workspace/src/github.com/huin/goupnp/dcps/internetgateway1/internetgateway1.go3957
-rw-r--r--Godeps/_workspace/src/github.com/huin/goupnp/dcps/internetgateway2/internetgateway2.go5271
-rw-r--r--Godeps/_workspace/src/github.com/huin/goupnp/device.go184
-rw-r--r--Godeps/_workspace/src/github.com/huin/goupnp/example/example.go6
-rw-r--r--Godeps/_workspace/src/github.com/huin/goupnp/example/example_test.go62
-rw-r--r--Godeps/_workspace/src/github.com/huin/goupnp/gotasks/specgen_task.go539
-rw-r--r--Godeps/_workspace/src/github.com/huin/goupnp/goupnp.go109
-rw-r--r--Godeps/_workspace/src/github.com/huin/goupnp/httpu/httpu.go117
-rw-r--r--Godeps/_workspace/src/github.com/huin/goupnp/httpu/serve.go108
-rw-r--r--Godeps/_workspace/src/github.com/huin/goupnp/scpd/scpd.go167
-rw-r--r--Godeps/_workspace/src/github.com/huin/goupnp/service_client.go56
-rw-r--r--Godeps/_workspace/src/github.com/huin/goupnp/soap/soap.go157
-rw-r--r--Godeps/_workspace/src/github.com/huin/goupnp/soap/soap_test.go85
-rw-r--r--Godeps/_workspace/src/github.com/huin/goupnp/soap/types.go508
-rw-r--r--Godeps/_workspace/src/github.com/huin/goupnp/soap/types_test.go481
-rw-r--r--Godeps/_workspace/src/github.com/huin/goupnp/ssdp/registry.go202
-rw-r--r--Godeps/_workspace/src/github.com/huin/goupnp/ssdp/ssdp.go83
-rw-r--r--Godeps/_workspace/src/github.com/jackpal/go-nat-pmp/LICENSE13
-rw-r--r--Godeps/_workspace/src/github.com/jackpal/go-nat-pmp/README.md48
-rw-r--r--Godeps/_workspace/src/github.com/jackpal/go-nat-pmp/natpmp.go184
-rw-r--r--Godeps/_workspace/src/github.com/kardianos/osext/LICENSE27
-rw-r--r--Godeps/_workspace/src/github.com/kardianos/osext/README.md14
-rw-r--r--Godeps/_workspace/src/github.com/kardianos/osext/osext.go27
-rw-r--r--Godeps/_workspace/src/github.com/kardianos/osext/osext_plan9.go20
-rw-r--r--Godeps/_workspace/src/github.com/kardianos/osext/osext_procfs.go28
-rw-r--r--Godeps/_workspace/src/github.com/kardianos/osext/osext_sysctl.go79
-rw-r--r--Godeps/_workspace/src/github.com/kardianos/osext/osext_test.go79
-rw-r--r--Godeps/_workspace/src/github.com/kardianos/osext/osext_windows.go34
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/.gitignore5
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/LICENSE185
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/README.md157
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/all.cpp12
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/bridge.go681
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/cdata/cdata.go6
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/cdata/cdata12.c18
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/cdata/cdata14_386.s17
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/cdata/cdata14_amd64.s17
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/cdata/cdata14_arm.s18
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/cdata/cdata_test.go42
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/cmd/genqrc/main.go218
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/cmd/ubuntu-touch/particle.desktop15
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/cmd/ubuntu-touch/setup.sh41
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/cpp/capi.cpp884
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/cpp/capi.h211
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/cpp/connector.cpp46
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/cpp/connector.h58
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/cpp/govalue.cpp236
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/cpp/govalue.h56
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/cpp/govaluetype.cpp254
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/cpp/govaluetype.h48
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/cpp/idletimer.cpp58
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/cpp/mmemwin.cpp27
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/cpp/moc_all.cpp4
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/cpp/moc_connector.cpp211
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/cpp/moc_govalue.cpp155
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/cpp/moc_idletimer.cpp108
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/cpp/private/qmetaobject_p.h2
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/cpp/private/qmetaobjectbuilder_p.h2
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/cpp/private/qobject_p.h2
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/cpp/private/qtheader.h70
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/cpp/update-moc.sh19
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/cpptest/cpptest.cpp14
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/cpptest/cpptest.go30
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/cpptest/cpptest.h23
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/cpptest/moc_testtype.cpp202
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/cpptest/testtype.h45
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/cpptest/update-moc.sh12
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/datatype.go531
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/doc.go199
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/.gitignore5
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/README.md8
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/basiclayouts/basiclayouts.go29
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/basiclayouts/main.qml116
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/content/AboutDialog.qml48
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/content/ChildWindow.qml122
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/content/Controls.qml229
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/content/ImageViewer.qml58
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/content/Layouts.qml107
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/content/ModelView.qml103
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/content/Styles.qml387
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/gallery.go29
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/bubble.pngbin0 -> 214 bytes
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/button-pressed.pngbin0 -> 3094 bytes
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/button.pngbin0 -> 3164 bytes
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/document-open.pngbin0 -> 1550 bytes
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/document-open@2x.pngbin0 -> 3355 bytes
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/document-save-as.pngbin0 -> 1837 bytes
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/document-save-as@2x.pngbin0 -> 4500 bytes
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/folder_new.pngbin0 -> 1199 bytes
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/go-next.pngbin0 -> 1219 bytes
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/go-previous.pngbin0 -> 1200 bytes
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/preferences-system.pngbin0 -> 2129 bytes
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/process-stop.pngbin0 -> 1927 bytes
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/progress-background.pngbin0 -> 456 bytes
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/progress-fill.pngbin0 -> 507 bytes
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/slider-handle.pngbin0 -> 3523 bytes
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/tab.pngbin0 -> 9877 bytes
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/tab_selected.pngbin0 -> 10184 bytes
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/textfield.pngbin0 -> 3023 bytes
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/toplevel_window.pngbin0 -> 3690 bytes
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/view-refresh.pngbin0 -> 2024 bytes
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/window-new.pngbin0 -> 671 bytes
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/window-new@2x.pngbin0 -> 1900 bytes
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/main.qml266
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/splitview/main.qml82
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/splitview/splitview.go29
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/tableview/images/header.pngbin0 -> 356 bytes
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/tableview/images/selectedrow.pngbin0 -> 303 bytes
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/tableview/main.qml405
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/tableview/tableview.go29
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/content/AndroidDelegate.qml92
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/content/ButtonPage.qml176
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/content/ListPage.qml82
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/content/ProgressBarPage.qml114
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/content/SliderPage.qml106
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/content/TabBarPage.qml102
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/content/TextInputPage.qml106
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/images/NOTICE.txt2
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/images/button_default.pngbin0 -> 1406 bytes
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/images/button_pressed.pngbin0 -> 1694 bytes
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/images/navigation_next_item.pngbin0 -> 1341 bytes
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/images/navigation_previous_item.pngbin0 -> 1343 bytes
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/images/tab_selected.pngbin0 -> 217 bytes
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/images/tabs_standard.pngbin0 -> 1230 bytes
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/images/textinput.pngbin0 -> 4132 bytes
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/images/toolbar.pngbin0 -> 1643 bytes
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/main.qml147
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/touch.go29
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/customtype/customtype.go48
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/customtype/customtype.qml5
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/gopher/gopher.go117
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/gopher/gopher.qml42
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/gopher/mix.qml68
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/gopher/model/README.md10
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/gopher/model/gopher.blendbin0 -> 1370816 bytes
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/gopher/model/gopher.mtl65
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/gopher/model/gopher.obj31375
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/gopher/wavefront.go280
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/imgprovider/imgprovider.go43
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/imgprovider/imgprovider.qml5
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/imgprovider/ubuntu-gopher.pngbin0 -> 59635 bytes
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/modelview/delegate/delegate.go53
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/modelview/delegate/delegate.qml17
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/painting-es2/painting.go115
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/painting-es2/painting.qml66
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/painting/painting.go64
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/painting/painting.qml66
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/particle/main.go84
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/particle/particle.pngbin0 -> 861 bytes
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/particle/particle.qml89
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/qmlscene/Cell.qml20
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/qmlscene/qmlscene.go33
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/qmlscene/tutorial1.qml17
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/qmlscene/tutorial2.qml30
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/qmlscene/tutorial3.qml45
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/qrcpacking/assets/particle.pngbin0 -> 861 bytes
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/qrcpacking/assets/particle.qml89
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/qrcpacking/main.go86
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/qrcpacking/qrc.go58
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/reparent/base.qml7
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/reparent/rect.qml8
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/reparent/reparent.go37
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/examples/snapweb/snapweb.go70
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/1.0/funcs.cpp1848
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/1.0/funcs.h347
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/1.0/gl.go2528
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/1.1/funcs.cpp2022
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/1.1/funcs.h376
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/1.1/gl.go2789
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/1.2/funcs.cpp2250
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/1.2/funcs.h414
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/1.2/gl.go3152
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/1.3/funcs.cpp2526
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/1.3/funcs.h460
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/1.3/gl.go3571
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/1.4/funcs.cpp2790
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/1.4/funcs.h504
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/1.4/gl.go3892
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/1.5/funcs.cpp2892
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/1.5/funcs.h521
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/1.5/gl.go4237
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/2.0/funcs.cpp3444
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/2.0/funcs.h613
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/2.0/gl.go6407
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/2.1/funcs.cpp3480
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/2.1/funcs.h619
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/2.1/gl.go6652
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/3.0/funcs.cpp3966
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/3.0/funcs.h700
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/3.0/gl.go7663
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/3.1/funcs.cpp1422
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/3.1/funcs.h276
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/3.1/gl.go4999
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/3.2compat/funcs.cpp4140
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/3.2compat/funcs.h729
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/3.2compat/gl.go7973
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/3.2core/funcs.cpp1530
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/3.2core/funcs.h294
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/3.2core/gl.go4729
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/3.3compat/funcs.cpp4488
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/3.3compat/funcs.h787
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/3.3compat/gl.go8281
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/3.3core/funcs.cpp1878
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/3.3core/funcs.h352
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/3.3core/gl.go5489
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/4.0compat/funcs.cpp4764
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/4.0compat/funcs.h833
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/4.0compat/gl.go8607
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/4.0core/funcs.cpp2154
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/4.0core/funcs.h398
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/4.0core/gl.go5815
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/4.1compat/funcs.cpp5286
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/4.1compat/funcs.h920
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/4.1compat/gl.go9201
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/4.1core/funcs.cpp2676
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/4.1core/funcs.h485
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/4.1core/gl.go6409
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/4.2compat/funcs.cpp5358
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/4.2compat/funcs.h932
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/4.2compat/gl.go9386
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/4.2core/funcs.cpp2748
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/4.2core/funcs.h497
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/4.2core/gl.go6594
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/4.3compat/funcs.cpp5556
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/4.3compat/funcs.h965
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/4.3compat/gl.go9845
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/4.3core/funcs.cpp2946
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/4.3core/funcs.h530
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/4.3core/gl.go7052
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/es2/funcs.cpp813
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/es2/funcs.h182
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/es2/gl.go2990
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/gengl/Makefile9
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/gengl/funcs.go1764
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/gengl/gl.xml43891
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/gengl/main.go1283
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/gengl/parseqt.go13904
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/gengl/parseqt.rl184
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/gl/glbase/glbase.go33
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/log.go157
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/qml.go1109
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/qml_test.go1436
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/resources.go375
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/stats.go68
-rw-r--r--Godeps/_workspace/src/github.com/obscuren/qml/testing.go69
-rw-r--r--Godeps/_workspace/src/github.com/peterh/liner/COPYING21
-rw-r--r--Godeps/_workspace/src/github.com/peterh/liner/README.md95
-rw-r--r--Godeps/_workspace/src/github.com/peterh/liner/bsdinput.go39
-rw-r--r--Godeps/_workspace/src/github.com/peterh/liner/common.go219
-rw-r--r--Godeps/_workspace/src/github.com/peterh/liner/fallbackinput.go57
-rw-r--r--Godeps/_workspace/src/github.com/peterh/liner/input.go359
-rw-r--r--Godeps/_workspace/src/github.com/peterh/liner/input_darwin.go39
-rw-r--r--Godeps/_workspace/src/github.com/peterh/liner/input_linux.go26
-rw-r--r--Godeps/_workspace/src/github.com/peterh/liner/input_test.go61
-rw-r--r--Godeps/_workspace/src/github.com/peterh/liner/input_windows.go313
-rw-r--r--Godeps/_workspace/src/github.com/peterh/liner/line.go864
-rw-r--r--Godeps/_workspace/src/github.com/peterh/liner/line_test.go90
-rw-r--r--Godeps/_workspace/src/github.com/peterh/liner/output.go63
-rw-r--r--Godeps/_workspace/src/github.com/peterh/liner/output_windows.go54
-rw-r--r--Godeps/_workspace/src/github.com/peterh/liner/prefix_test.go37
-rw-r--r--Godeps/_workspace/src/github.com/peterh/liner/race_test.go44
-rw-r--r--Godeps/_workspace/src/github.com/peterh/liner/signal.go12
-rw-r--r--Godeps/_workspace/src/github.com/peterh/liner/signal_legacy.go11
-rw-r--r--Godeps/_workspace/src/github.com/peterh/liner/unixmode.go37
-rw-r--r--Godeps/_workspace/src/github.com/peterh/liner/width.go47
-rw-r--r--Godeps/_workspace/src/github.com/peterh/liner/width_test.go87
-rw-r--r--Godeps/_workspace/src/github.com/rakyll/globalconf/.travis.yml2
-rw-r--r--Godeps/_workspace/src/github.com/rakyll/globalconf/README.md144
-rw-r--r--Godeps/_workspace/src/github.com/rakyll/globalconf/globalconf.go179
-rw-r--r--Godeps/_workspace/src/github.com/rakyll/globalconf/globalconf_test.go267
-rw-r--r--Godeps/_workspace/src/github.com/rakyll/globalconf/testdata/custom.ini2
-rw-r--r--Godeps/_workspace/src/github.com/rakyll/globalconf/testdata/global.ini3
-rw-r--r--Godeps/_workspace/src/github.com/rakyll/globalconf/testdata/globalandcustom.ini6
-rw-r--r--Godeps/_workspace/src/github.com/rakyll/goini/.gitignore8
-rw-r--r--Godeps/_workspace/src/github.com/rakyll/goini/Makefile7
-rw-r--r--Godeps/_workspace/src/github.com/rakyll/goini/empty.ini0
-rw-r--r--Godeps/_workspace/src/github.com/rakyll/goini/example.ini18
-rw-r--r--Godeps/_workspace/src/github.com/rakyll/goini/ini.go241
-rw-r--r--Godeps/_workspace/src/github.com/rakyll/goini/ini_test.go169
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/.gitignore5
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/DESIGN.markdown1
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/LICENSE7
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/Makefile63
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/README.markdown825
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/array_test.go716
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/ast/README.markdown1068
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/ast/node.go498
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/bug_test.go617
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/builtin.go353
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/builtin_array.go672
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/builtin_boolean.go28
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/builtin_date.go615
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/builtin_error.go126
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/builtin_function.go129
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/builtin_json.go299
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/builtin_math.go145
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/builtin_number.go93
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/builtin_object.go289
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/builtin_regexp.go65
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/builtin_string.go500
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/builtin_test.go136
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/clone.go155
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/cmpl.go24
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/cmpl_evaluate.go96
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/cmpl_evaluate_expression.go456
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/cmpl_evaluate_statement.go421
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/cmpl_parse.go650
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/cmpl_test.go54
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/console.go51
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/date_test.go481
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/dbg.go9
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/dbg/dbg.go387
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/documentation_test.go95
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/error.go245
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/error_test.go192
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/evaluate.go318
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/file/README.markdown110
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/file/file.go135
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/function_test.go280
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/global.go221
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/global_test.go355
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/inline1086
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/inline.go6649
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/json_test.go183
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/math_test.go303
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/number_test.go165
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/object.go156
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/object_class.go493
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/object_test.go639
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/otto.go578
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/otto/Makefile5
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/otto/main.go48
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/otto_.go178
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/otto_error_test.go48
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/otto_test.go1379
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/panic_test.go40
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/parser/Makefile4
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/parser/README.markdown190
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/parser/dbg.go9
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/parser/error.go175
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/parser/expression.go815
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/parser/lexer.go819
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/parser/lexer_test.go380
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/parser/marshal_test.go930
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/parser/parser.go273
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/parser/parser_test.go1004
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/parser/regexp.go358
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/parser/regexp_test.go149
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/parser/scope.go44
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/parser/statement.go663
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/parser_test.go42
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/property.go220
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/reflect_test.go483
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/regexp_test.go290
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/registry/README.markdown51
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/registry/registry.go47
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/result.go30
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/runtime.go331
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/runtime_test.go778
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/scope.go34
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/script.go122
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/script_test.go78
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/stash.go275
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/string_test.go365
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/terst/terst.go669
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/test/Makefile26
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/test/tester.go196
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/testing_test.go135
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/token/Makefile2
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/token/README.markdown171
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/token/token.go116
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/token/token_const.go349
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/token/tokenfmt222
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/type_arguments.go106
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/type_array.go109
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/type_boolean.go13
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/type_date.go299
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/type_error.go13
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/type_function.go262
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/type_go_array.go134
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/type_go_map.go87
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/type_go_slice.go118
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/type_go_struct.go146
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/type_number.go5
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/type_reference.go103
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/type_regexp.go146
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/type_string.go112
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/underscore/Makefile11
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/underscore/README.markdown53
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/underscore/source.go3462
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/underscore/testify84
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/underscore/underscore.go49
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/underscore_arrays_test.go344
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/underscore_chaining_test.go95
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/underscore_collections_test.go698
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/underscore_functions_test.go208
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/underscore_objects_test.go826
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/underscore_test.go165
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/underscore_utility_test.go419
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/value.go989
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/value_boolean.go40
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/value_number.go324
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/value_primitive.go23
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/value_string.go103
-rw-r--r--Godeps/_workspace/src/github.com/robertkrimen/otto/value_test.go281
-rw-r--r--Godeps/_workspace/src/github.com/rs/cors/.travis.yml4
-rw-r--r--Godeps/_workspace/src/github.com/rs/cors/LICENSE19
-rw-r--r--Godeps/_workspace/src/github.com/rs/cors/README.md84
-rw-r--r--Godeps/_workspace/src/github.com/rs/cors/bench_test.go37
-rw-r--r--Godeps/_workspace/src/github.com/rs/cors/cors.go308
-rw-r--r--Godeps/_workspace/src/github.com/rs/cors/cors_test.go288
-rw-r--r--Godeps/_workspace/src/github.com/rs/cors/examples/alice/server.go24
-rw-r--r--Godeps/_workspace/src/github.com/rs/cors/examples/default/server.go18
-rw-r--r--Godeps/_workspace/src/github.com/rs/cors/examples/goji/server.go22
-rw-r--r--Godeps/_workspace/src/github.com/rs/cors/examples/martini/server.go23
-rw-r--r--Godeps/_workspace/src/github.com/rs/cors/examples/negroni/server.go26
-rw-r--r--Godeps/_workspace/src/github.com/rs/cors/examples/nethttp/server.go20
-rw-r--r--Godeps/_workspace/src/github.com/rs/cors/examples/openbar/server.go22
-rw-r--r--Godeps/_workspace/src/github.com/rs/cors/utils.go27
-rw-r--r--Godeps/_workspace/src/github.com/rs/cors/utils_test.go28
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/batch.go216
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/batch_test.go120
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/bench_test.go461
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/cache/cache.go125
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/cache/cache_test.go236
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/cache/empty_cache.go246
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/cache/lru_cache.go354
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/comparer.go75
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/comparer/bytes_comparer.go51
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/comparer/comparer.go57
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/config.go40
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/corrupt_test.go472
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/db.go755
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/db_compaction.go688
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/db_iter.go310
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/db_snapshot.go165
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/db_state.go114
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/db_test.go1888
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/db_util.go95
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/db_write.go279
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/doc.go80
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/error.go38
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/external_test.go58
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/filter.go31
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/filter/bloom.go116
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/filter/bloom_test.go142
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/filter/filter.go60
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/iterator/array_iter.go158
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/iterator/array_iter_test.go30
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/iterator/indexed_iter.go221
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/iterator/indexed_iter_test.go83
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/iterator/iter.go142
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/iterator/iter_suite_test.go17
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/iterator/merged_iter.go307
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/iterator/merged_iter_test.go60
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/journal/journal.go513
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/journal/journal_test.go328
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/key.go139
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/key_test.go123
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/leveldb_suite_test.go20
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/memdb/bench_test.go75
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/memdb/memdb.go450
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/memdb/memdb_suite_test.go17
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/memdb/memdb_test.go135
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/opt/options.go318
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/options.go41
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/session.go403
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/session_record.go308
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/session_record_test.go62
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/session_util.go253
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/storage/file_storage.go534
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/storage/file_storage_plan9.go52
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/storage/file_storage_test.go142
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/storage/file_storage_unix.go63
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/storage/file_storage_windows.go69
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/storage/mem_storage.go203
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/storage/mem_storage_test.go66
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/storage/storage.go127
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/storage_test.go459
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/table.go424
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/table/block_test.go131
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/table/reader.go848
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/table/table.go177
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/table/table_suite_test.go17
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/table/table_test.go119
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/table/writer.go379
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/testutil/db.go216
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/testutil/iter.go327
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/testutil/kv.go352
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/testutil/kvtest.go136
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/testutil/storage.go585
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/testutil/util.go157
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/testutil_test.go58
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/util.go91
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/util/buffer.go293
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/util/buffer_test.go369
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/util/crc32.go30
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/util/hash.go48
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/util/range.go16
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/util/util.go49
-rw-r--r--Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/version.go428
-rw-r--r--Godeps/_workspace/src/golang.org/x/crypto/pbkdf2/pbkdf2.go77
-rw-r--r--Godeps/_workspace/src/golang.org/x/crypto/pbkdf2/pbkdf2_test.go157
-rw-r--r--Godeps/_workspace/src/golang.org/x/crypto/ripemd160/ripemd160.go120
-rw-r--r--Godeps/_workspace/src/golang.org/x/crypto/ripemd160/ripemd160_test.go64
-rw-r--r--Godeps/_workspace/src/golang.org/x/crypto/ripemd160/ripemd160block.go161
-rw-r--r--Godeps/_workspace/src/golang.org/x/crypto/scrypt/scrypt.go243
-rw-r--r--Godeps/_workspace/src/golang.org/x/crypto/scrypt/scrypt_test.go160
-rw-r--r--Godeps/_workspace/src/gopkg.in/check.v1/.gitignore4
-rw-r--r--Godeps/_workspace/src/gopkg.in/check.v1/LICENSE25
-rw-r--r--Godeps/_workspace/src/gopkg.in/check.v1/README.md20
-rw-r--r--Godeps/_workspace/src/gopkg.in/check.v1/TODO2
-rw-r--r--Godeps/_workspace/src/gopkg.in/check.v1/benchmark.go163
-rw-r--r--Godeps/_workspace/src/gopkg.in/check.v1/benchmark_test.go91
-rw-r--r--Godeps/_workspace/src/gopkg.in/check.v1/bootstrap_test.go82
-rw-r--r--Godeps/_workspace/src/gopkg.in/check.v1/check.go945
-rw-r--r--Godeps/_workspace/src/gopkg.in/check.v1/check_test.go207
-rw-r--r--Godeps/_workspace/src/gopkg.in/check.v1/checkers.go458
-rw-r--r--Godeps/_workspace/src/gopkg.in/check.v1/checkers_test.go272
-rw-r--r--Godeps/_workspace/src/gopkg.in/check.v1/export_test.go9
-rw-r--r--Godeps/_workspace/src/gopkg.in/check.v1/fixture_test.go484
-rw-r--r--Godeps/_workspace/src/gopkg.in/check.v1/foundation_test.go335
-rw-r--r--Godeps/_workspace/src/gopkg.in/check.v1/helpers.go231
-rw-r--r--Godeps/_workspace/src/gopkg.in/check.v1/helpers_test.go519
-rw-r--r--Godeps/_workspace/src/gopkg.in/check.v1/printer.go168
-rw-r--r--Godeps/_workspace/src/gopkg.in/check.v1/printer_test.go104
-rw-r--r--Godeps/_workspace/src/gopkg.in/check.v1/run.go175
-rw-r--r--Godeps/_workspace/src/gopkg.in/check.v1/run_test.go419
-rw-r--r--Godeps/_workspace/src/gopkg.in/fatih/set.v0/.travis.yml3
-rw-r--r--Godeps/_workspace/src/gopkg.in/fatih/set.v0/LICENSE.md20
-rw-r--r--Godeps/_workspace/src/gopkg.in/fatih/set.v0/README.md245
-rw-r--r--Godeps/_workspace/src/gopkg.in/fatih/set.v0/set.go121
-rw-r--r--Godeps/_workspace/src/gopkg.in/fatih/set.v0/set_nots.go195
-rw-r--r--Godeps/_workspace/src/gopkg.in/fatih/set.v0/set_nots_test.go282
-rw-r--r--Godeps/_workspace/src/gopkg.in/fatih/set.v0/set_test.go188
-rw-r--r--Godeps/_workspace/src/gopkg.in/fatih/set.v0/set_ts.go200
-rw-r--r--Godeps/_workspace/src/gopkg.in/fatih/set.v0/set_ts_test.go321
-rw-r--r--Godeps/_workspace/src/gopkg.in/qml.v1/cdata/cdata.go6
-rw-r--r--Godeps/_workspace/src/gopkg.in/qml.v1/cdata/cdata12.c18
-rw-r--r--Godeps/_workspace/src/gopkg.in/qml.v1/cdata/cdata14_386.s17
-rw-r--r--Godeps/_workspace/src/gopkg.in/qml.v1/cdata/cdata14_amd64.s17
-rw-r--r--Godeps/_workspace/src/gopkg.in/qml.v1/cdata/cdata14_arm.s18
-rw-r--r--Godeps/_workspace/src/gopkg.in/qml.v1/cdata/cdata_test.go42
-rw-r--r--Godeps/_workspace/src/gopkg.in/qml.v1/gl/glbase/glbase.go33
-rw-r--r--LICENSE16
-rw-r--r--README.md110
-rwxr-xr-x_data/invalid1bin0 -> 36072 bytes
-rwxr-xr-x_data/valid1bin0 -> 18036 bytes
-rwxr-xr-x_data/valid2bin0 -> 6125 bytes
-rwxr-xr-x_data/valid3bin0 -> 14712 bytes
-rwxr-xr-x_data/valid4bin0 -> 12496 bytes
-rw-r--r--accounts/abi/abi.go155
-rw-r--r--accounts/abi/abi_test.go330
-rw-r--r--accounts/abi/doc.go10
-rw-r--r--accounts/abi/numbers.go106
-rw-r--r--accounts/abi/numbers_test.go72
-rw-r--r--accounts/abi/type.go190
-rw-r--r--accounts/account_manager.go237
-rw-r--r--accounts/accounts_test.go69
-rw-r--r--blockpool/blockpool.go874
-rw-r--r--blockpool/blockpool_test.go449
-rw-r--r--blockpool/blockpool_util_test.go373
-rw-r--r--blockpool/config_test.go47
-rw-r--r--blockpool/errors_test.go181
-rw-r--r--blockpool/peers.go600
-rw-r--r--blockpool/peers_test.go189
-rw-r--r--blockpool/section.go678
-rw-r--r--blockpool/status.go111
-rw-r--r--blockpool/status_test.go251
-rw-r--r--blockpool/test/hash_pool.go55
-rw-r--r--blockpool/test/logger.go74
-rw-r--r--blockpool/test/util.go41
-rw-r--r--cmd/LICENSE16
-rw-r--r--cmd/bootnode/main.go93
-rw-r--r--cmd/disasm/main.go34
-rw-r--r--cmd/ethtest/.bowerrc5
-rw-r--r--cmd/ethtest/.editorconfig12
-rw-r--r--cmd/ethtest/.gitignore18
-rw-r--r--cmd/ethtest/.jshintrc50
-rw-r--r--cmd/ethtest/.npmignore9
-rw-r--r--cmd/ethtest/.travis.yml11
-rw-r--r--cmd/ethtest/main.go229
-rw-r--r--cmd/evm/code.txt1
-rw-r--r--cmd/evm/input.txt1
-rw-r--r--cmd/evm/main.go163
-rw-r--r--cmd/geth/admin.go261
-rw-r--r--cmd/geth/blocktest.go80
-rw-r--r--cmd/geth/js.go245
-rw-r--r--cmd/geth/js_test.go262
-rw-r--r--cmd/geth/main.go517
-rw-r--r--cmd/mist/assets/back.pngbin0 -> 1004 bytes
-rw-r--r--cmd/mist/assets/backButton.pngbin0 -> 663 bytes
-rw-r--r--cmd/mist/assets/backButton@2x.pngbin0 -> 1499 bytes
-rw-r--r--cmd/mist/assets/backButtonDisabled.pngbin0 -> 634 bytes
-rw-r--r--cmd/mist/assets/backButtonDisabled@2x.pngbin0 -> 1458 bytes
-rw-r--r--cmd/mist/assets/backButtonHover.pngbin0 -> 657 bytes
-rw-r--r--cmd/mist/assets/backButtonHover@2x.pngbin0 -> 1517 bytes
-rw-r--r--cmd/mist/assets/browser.pngbin0 -> 756 bytes
-rw-r--r--cmd/mist/assets/browser@2x.pngbin0 -> 1603 bytes
-rw-r--r--cmd/mist/assets/bug.pngbin0 -> 1671 bytes
-rw-r--r--cmd/mist/assets/close.pngbin0 -> 905 bytes
-rw-r--r--cmd/mist/assets/debugger/debugger.qml436
-rw-r--r--cmd/mist/assets/examples/abi.html55
-rw-r--r--cmd/mist/assets/examples/balance.html40
-rw-r--r--cmd/mist/assets/examples/bomb.html22
-rw-r--r--cmd/mist/assets/examples/coin.html148
-rw-r--r--cmd/mist/assets/examples/coin.js65
-rw-r--r--cmd/mist/assets/examples/info.html84
-rw-r--r--cmd/mist/assets/examples/whisper.html70
-rw-r--r--cmd/mist/assets/ext/.bowerrc5
-rw-r--r--cmd/mist/assets/ext/.editorconfig12
-rw-r--r--cmd/mist/assets/ext/.gitignore18
-rw-r--r--cmd/mist/assets/ext/.jshintrc50
-rw-r--r--cmd/mist/assets/ext/.npmignore9
-rw-r--r--cmd/mist/assets/ext/.travis.yml13
-rw-r--r--cmd/mist/assets/ext/bignumber.min.js4
m---------cmd/mist/assets/ext/ethereum.js0
-rw-r--r--cmd/mist/assets/ext/filter.js66
-rw-r--r--cmd/mist/assets/ext/http.js30
-rw-r--r--cmd/mist/assets/ext/mist.js36
-rw-r--r--cmd/mist/assets/facet.pngbin0 -> 27302 bytes
-rw-r--r--cmd/mist/assets/heart.pngbin0 -> 4277 bytes
-rw-r--r--cmd/mist/assets/html/home.html83
-rw-r--r--cmd/mist/assets/html/logo.pngbin0 -> 12767 bytes
-rw-r--r--cmd/mist/assets/icecream.pngbin0 -> 4643 bytes
-rw-r--r--cmd/mist/assets/mining-icon.pngbin0 -> 1029 bytes
-rw-r--r--cmd/mist/assets/mining-icon@2x.pngbin0 -> 2312 bytes
-rw-r--r--cmd/mist/assets/muted/codemirror.css272
-rw-r--r--cmd/mist/assets/muted/debugger.html53
-rw-r--r--cmd/mist/assets/muted/eclipse.css23
-rw-r--r--cmd/mist/assets/muted/index.html80
-rw-r--r--cmd/mist/assets/muted/lib/codemirror.js7526
-rw-r--r--cmd/mist/assets/muted/lib/go.js182
-rw-r--r--cmd/mist/assets/muted/lib/matchbrackets.js117
-rw-r--r--cmd/mist/assets/muted/muted.js78
-rw-r--r--cmd/mist/assets/net.pngbin0 -> 4669 bytes
-rw-r--r--cmd/mist/assets/network.pngbin0 -> 2900 bytes
-rw-r--r--cmd/mist/assets/new.pngbin0 -> 4776 bytes
-rw-r--r--cmd/mist/assets/pick.pngbin0 -> 932 bytes
-rw-r--r--cmd/mist/assets/qml/QmlApp.qml22
-rw-r--r--cmd/mist/assets/qml/depricated_browser.qml486
-rw-r--r--cmd/mist/assets/qml/first_run.qml155
-rwxr-xr-xcmd/mist/assets/qml/fonts/Simple-Line-Icons.ttfbin0 -> 35304 bytes
-rw-r--r--cmd/mist/assets/qml/fonts/SourceSansPro-Black.ttfbin0 -> 117460 bytes
-rw-r--r--cmd/mist/assets/qml/fonts/SourceSansPro-BlackIt.ttfbin0 -> 123840 bytes
-rw-r--r--cmd/mist/assets/qml/fonts/SourceSansPro-Bold.ttfbin0 -> 119096 bytes
-rw-r--r--cmd/mist/assets/qml/fonts/SourceSansPro-BoldIt.ttfbin0 -> 123756 bytes
-rw-r--r--cmd/mist/assets/qml/fonts/SourceSansPro-ExtraLight.ttfbin0 -> 120812 bytes
-rw-r--r--cmd/mist/assets/qml/fonts/SourceSansPro-ExtraLightIt.ttfbin0 -> 125720 bytes
-rw-r--r--cmd/mist/assets/qml/fonts/SourceSansPro-It.ttfbin0 -> 124668 bytes
-rw-r--r--cmd/mist/assets/qml/fonts/SourceSansPro-Light.ttfbin0 -> 121124 bytes
-rw-r--r--cmd/mist/assets/qml/fonts/SourceSansPro-LightIt.ttfbin0 -> 125480 bytes
-rw-r--r--cmd/mist/assets/qml/fonts/SourceSansPro-Regular.ttfbin0 -> 120672 bytes
-rw-r--r--cmd/mist/assets/qml/fonts/SourceSansPro-Semibold.ttfbin0 -> 120036 bytes
-rw-r--r--cmd/mist/assets/qml/fonts/SourceSansPro-SemiboldIt.ttfbin0 -> 123840 bytes
-rw-r--r--cmd/mist/assets/qml/fonts/SourceSerifPro-Bold.ttfbin0 -> 113188 bytes
-rw-r--r--cmd/mist/assets/qml/fonts/SourceSerifPro-Regular.ttfbin0 -> 113640 bytes
-rw-r--r--cmd/mist/assets/qml/fonts/SourceSerifPro-Semibold.ttfbin0 -> 114352 bytes
-rw-r--r--cmd/mist/assets/qml/main.qml1030
-rw-r--r--cmd/mist/assets/qml/muted.qml74
-rw-r--r--cmd/mist/assets/qml/test_app.qml70
-rw-r--r--cmd/mist/assets/qml/transactions.qml9
-rw-r--r--cmd/mist/assets/qml/views/browser.qml506
-rw-r--r--cmd/mist/assets/qml/views/catalog.qml144
-rw-r--r--cmd/mist/assets/qml/views/chain.qml244
-rw-r--r--cmd/mist/assets/qml/views/history.qml51
-rw-r--r--cmd/mist/assets/qml/views/info.qml143
-rw-r--r--cmd/mist/assets/qml/views/jeffcoin/jeff.pngbin0 -> 84076 bytes
-rw-r--r--cmd/mist/assets/qml/views/jeffcoin/jeffcoin.qml190
-rw-r--r--cmd/mist/assets/qml/views/miner.qml283
-rw-r--r--cmd/mist/assets/qml/views/network-health/205f39107b64acf34cb35d7edb57f47893187a12.js176
-rw-r--r--cmd/mist/assets/qml/views/network-health/529f30ee0ee386c5143b4ccb62073179ca8253c3.css4
-rw-r--r--cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/Montserrat-Black.otfbin0 -> 45336 bytes
-rw-r--r--cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/Montserrat-Bold.otfbin0 -> 45968 bytes
-rw-r--r--cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/Montserrat-Hairline.otfbin0 -> 44156 bytes
-rw-r--r--cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/Montserrat-Light.otfbin0 -> 44792 bytes
-rw-r--r--cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/Montserrat-Regular.otfbin0 -> 45360 bytes
-rw-r--r--cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/SIL Open Font License.txt43
-rw-r--r--cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/SourceSansPro-Black.otfbin0 -> 122372 bytes
-rw-r--r--cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/SourceSansPro-BlackIt.otfbin0 -> 95056 bytes
-rw-r--r--cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/SourceSansPro-Bold.otfbin0 -> 129212 bytes
-rw-r--r--cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/SourceSansPro-BoldIt.otfbin0 -> 100072 bytes
-rw-r--r--cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/SourceSansPro-ExtraLight.otfbin0 -> 117832 bytes
-rw-r--r--cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/SourceSansPro-ExtraLightIt.otfbin0 -> 90924 bytes
-rw-r--r--cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/SourceSansPro-It.otfbin0 -> 98820 bytes
-rw-r--r--cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/SourceSansPro-Light.otfbin0 -> 124476 bytes
-rw-r--r--cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/SourceSansPro-LightIt.otfbin0 -> 95536 bytes
-rw-r--r--cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/SourceSansPro-Regular.otfbin0 -> 127448 bytes
-rw-r--r--cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/SourceSansPro-Semibold.otfbin0 -> 127336 bytes
-rw-r--r--cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/SourceSansPro-SemiboldIt.otfbin0 -> 98352 bytes
-rwxr-xr-xcmd/mist/assets/qml/views/network-health/index.html30
-rw-r--r--cmd/mist/assets/qml/views/network-health/loading.css92
-rw-r--r--cmd/mist/assets/qml/views/network.qml159
-rw-r--r--cmd/mist/assets/qml/views/pending_tx.qml53
-rw-r--r--cmd/mist/assets/qml/views/transaction.qml216
-rw-r--r--cmd/mist/assets/qml/views/wallet.qml190
-rw-r--r--cmd/mist/assets/qml/views/whisper.qml74
-rw-r--r--cmd/mist/assets/tx.pngbin0 -> 4070 bytes
-rw-r--r--cmd/mist/assets/util/test.html43
-rw-r--r--cmd/mist/assets/wallet.pngbin0 -> 1114 bytes
-rw-r--r--cmd/mist/bindings.go92
-rw-r--r--cmd/mist/errors.go56
-rw-r--r--cmd/mist/gui.go464
-rw-r--r--cmd/mist/html_container.go153
-rw-r--r--cmd/mist/main.go127
-rw-r--r--cmd/mist/qml_container.go82
-rw-r--r--cmd/mist/ui_lib.go280
-rw-r--r--cmd/rlpdump/main.go148
-rw-r--r--cmd/utils/cmd.go186
-rw-r--r--cmd/utils/flags.go267
-rw-r--r--common/.gitignore12
-rw-r--r--common/.travis.yml3
-rw-r--r--common/README.md139
-rw-r--r--common/big.go136
-rw-r--r--common/big_test.go73
-rw-r--r--common/bytes.go256
-rw-r--r--common/bytes_test.go214
-rw-r--r--common/config.go67
-rw-r--r--common/db.go12
-rw-r--r--common/list.go81
-rw-r--r--common/main_test.go9
-rw-r--r--common/math/dist.go80
-rw-r--r--common/math/dist_test.go66
-rw-r--r--common/natspec/natspec.go63
-rw-r--r--common/natspec/natspec_js.go4
-rw-r--r--common/natspec/natspec_test.go97
-rw-r--r--common/number/int.go181
-rw-r--r--common/number/uint_test.go92
-rw-r--r--common/package.go123
-rw-r--r--common/path.go106
-rw-r--r--common/path_test.go36
-rw-r--r--common/rlp.go276
-rw-r--r--common/rlp_test.go160
-rw-r--r--common/size.go79
-rw-r--r--common/size_test.go57
-rw-r--r--common/types.go84
-rw-r--r--common/types_template.go48
-rw-r--r--common/types_test.go15
-rw-r--r--common/value.go412
-rw-r--r--common/value_test.go70
-rw-r--r--compression/rle/read_write.go84
-rw-r--r--compression/rle/read_write_test.go118
-rw-r--r--core/.gitignore12
-rw-r--r--core/asm.go50
-rw-r--r--core/block_cache.go73
-rw-r--r--core/block_cache_test.go48
-rw-r--r--core/block_processor.go393
-rw-r--r--core/block_processor_test.go36
-rw-r--r--core/chain_makers.go142
-rw-r--r--core/chain_manager.go542
-rw-r--r--core/chain_manager_test.go345
-rw-r--r--core/error.go167
-rw-r--r--core/events.go49
-rw-r--r--core/execution.go96
-rw-r--r--core/fees.go7
-rw-r--r--core/filter.go181
-rw-r--r--core/filter_test.go1
-rw-r--r--core/genesis.go72
-rw-r--r--core/helper_test.go83
-rw-r--r--core/manager.go19
-rw-r--r--core/state/dump.go62
-rw-r--r--core/state/errors.go23
-rw-r--r--core/state/log.go99
-rw-r--r--core/state/main_test.go9
-rw-r--r--core/state/managed_state.go89
-rw-r--r--core/state/managed_state_test.go89
-rw-r--r--core/state/state_object.go357
-rw-r--r--core/state/state_test.go106
-rw-r--r--core/state/statedb.go341
-rw-r--r--core/state_transition.go258
-rw-r--r--core/transaction_pool.go197
-rw-r--r--core/transaction_pool_test.go95
-rw-r--r--core/types/block.go403
-rw-r--r--core/types/block_test.go60
-rw-r--r--core/types/bloom9.go59
-rw-r--r--core/types/bloom9_test.go31
-rw-r--r--core/types/common.go40
-rw-r--r--core/types/derive_sha.go24
-rw-r--r--core/types/receipt.go81
-rw-r--r--core/types/transaction.go214
-rw-r--r--core/types/transaction_test.go111
-rw-r--r--core/vm/address.go95
-rw-r--r--core/vm/analysis.go36
-rw-r--r--core/vm/asm.go45
-rw-r--r--core/vm/common.go91
-rw-r--r--core/vm/context.go94
-rw-r--r--core/vm/environment.go91
-rw-r--r--core/vm/errors.go52
-rw-r--r--core/vm/gas.go125
-rw-r--r--core/vm/main_test.go9
-rw-r--r--core/vm/memory.go72
-rw-r--r--core/vm/stack.go67
-rw-r--r--core/vm/types.go334
-rw-r--r--core/vm/virtual_machine.go8
-rw-r--r--core/vm/vm.go909
-rw-r--r--core/vm/vm_jit.go370
-rw-r--r--core/vm/vm_jit_fake.go10
-rw-r--r--core/vm/vm_test.go3
-rw-r--r--core/vm_env.go70
-rw-r--r--crypto/crypto.go276
-rw-r--r--crypto/crypto_test.go80
-rw-r--r--crypto/curve.go363
-rw-r--r--crypto/ecies/.gitignore24
-rw-r--r--crypto/ecies/LICENSE28
-rw-r--r--crypto/ecies/README94
-rw-r--r--crypto/ecies/asn1.go556
-rw-r--r--crypto/ecies/ecies.go331
-rw-r--r--crypto/ecies/ecies_test.go489
-rw-r--r--crypto/ecies/params.go181
-rw-r--r--crypto/encrypt_decrypt_test.go40
-rw-r--r--crypto/key.go111
-rw-r--r--crypto/key_store_passphrase.go200
-rw-r--r--crypto/key_store_plain.go129
-rw-r--r--crypto/key_store_test.go99
-rw-r--r--crypto/keypair.go50
-rw-r--r--crypto/mnemonic.go60
-rw-r--r--crypto/mnemonic_test.go74
-rw-r--r--crypto/mnemonic_words.go1630
-rw-r--r--crypto/randentropy/rand_entropy.go84
-rw-r--r--crypto/secp256k1/.gitignore24
-rw-r--r--crypto/secp256k1/README.md22
-rw-r--r--crypto/secp256k1/notes.go192
-rw-r--r--crypto/secp256k1/secp256.go306
-rw-r--r--crypto/secp256k1/secp256_test.go238
-rw-r--r--crypto/secp256k1/secp256k1/COPYING19
-rw-r--r--crypto/secp256k1/secp256k1/Makefile55
-rw-r--r--crypto/secp256k1/secp256k1/TODO3
-rw-r--r--crypto/secp256k1/secp256k1/config.mk9
-rwxr-xr-xcrypto/secp256k1/secp256k1/configure175
-rw-r--r--crypto/secp256k1/secp256k1/include/secp256k1.h121
-rw-r--r--crypto/secp256k1/secp256k1/src/bench.c64
-rw-r--r--crypto/secp256k1/secp256k1/src/ecdsa.h28
-rw-r--r--crypto/secp256k1/secp256k1/src/ecmult.h19
-rw-r--r--crypto/secp256k1/secp256k1/src/field.h101
-rw-r--r--crypto/secp256k1/secp256k1/src/field_10x26.h19
-rw-r--r--crypto/secp256k1/secp256k1/src/field_5x52.h19
-rw-r--r--crypto/secp256k1/secp256k1/src/field_5x52_asm.asm463
-rw-r--r--crypto/secp256k1/secp256k1/src/field_5x64.h19
-rw-r--r--crypto/secp256k1/secp256k1/src/field_5x64_asm.asm332
-rw-r--r--crypto/secp256k1/secp256k1/src/field_gmp.h16
-rw-r--r--crypto/secp256k1/secp256k1/src/group.h108
-rw-r--r--crypto/secp256k1/secp256k1/src/impl/ecdsa.h309
-rw-r--r--crypto/secp256k1/secp256k1/src/impl/ecmult.h238
-rw-r--r--crypto/secp256k1/secp256k1/src/impl/field.h175
-rw-r--r--crypto/secp256k1/secp256k1/src/impl/field_10x26.h487
-rw-r--r--crypto/secp256k1/secp256k1/src/impl/field_5x52.h196
-rw-r--r--crypto/secp256k1/secp256k1/src/impl/field_5x52_asm.h11
-rw-r--r--crypto/secp256k1/secp256k1/src/impl/field_5x52_int128.h105
-rw-r--r--crypto/secp256k1/secp256k1/src/impl/field_5x64.h371
-rw-r--r--crypto/secp256k1/secp256k1/src/impl/field_5x64_asm.h11
-rw-r--r--crypto/secp256k1/secp256k1/src/impl/field_gmp.h155
-rw-r--r--crypto/secp256k1/secp256k1/src/impl/group.h397
-rw-r--r--crypto/secp256k1/secp256k1/src/impl/num.h18
-rw-r--r--crypto/secp256k1/secp256k1/src/impl/num_gmp.h346
-rw-r--r--crypto/secp256k1/secp256k1/src/impl/num_openssl.h145
-rw-r--r--crypto/secp256k1/secp256k1/src/impl/util.h45
-rw-r--r--crypto/secp256k1/secp256k1/src/java/org/bitcoin/NativeSecp256k1.java60
-rw-r--r--crypto/secp256k1/secp256k1/src/java/org_bitcoin_NativeSecp256k1.c23
-rw-r--r--crypto/secp256k1/secp256k1/src/java/org_bitcoin_NativeSecp256k1.h21
-rw-r--r--crypto/secp256k1/secp256k1/src/num.h93
-rw-r--r--crypto/secp256k1/secp256k1/src/num_gmp.h18
-rw-r--r--crypto/secp256k1/secp256k1/src/num_openssl.h14
-rw-r--r--crypto/secp256k1/secp256k1/src/secp256k1.c269
-rw-r--r--crypto/secp256k1/secp256k1/src/tests.c465
-rw-r--r--crypto/secp256k1/secp256k1/src/util.h19
-rw-r--r--crypto/sha3/keccakf.go171
-rw-r--r--crypto/sha3/sha3.go216
-rw-r--r--errs/errors.go91
-rw-r--r--errs/errors_test.go46
-rw-r--r--eth/backend.go459
-rw-r--r--eth/protocol.go389
-rw-r--r--eth/protocol_test.go400
-rw-r--r--ethdb/.gitignore12
-rw-r--r--ethdb/README.md11
-rw-r--r--ethdb/database.go88
-rw-r--r--ethdb/database_test.go26
-rw-r--r--ethdb/memory_database.go67
-rw-r--r--event/event.go183
-rw-r--r--event/event_test.go176
-rw-r--r--event/example_test.go42
-rw-r--r--event/filter/eth_filter.go111
-rw-r--r--event/filter/filter.go78
-rw-r--r--event/filter/filter_test.go34
-rw-r--r--event/filter/generic_filter.go32
-rw-r--r--generators/defaults.go65
-rwxr-xr-xgocoverage.sh31
-rw-r--r--jsre/bignumber_js.go6
-rw-r--r--jsre/ethereum_js.go4
-rw-r--r--jsre/jsre.go125
-rw-r--r--jsre/jsre_test.go84
-rw-r--r--jsre/pp_js.go81
-rw-r--r--logger/example_test.go21
-rw-r--r--logger/log.go49
-rw-r--r--logger/loggers.go133
-rw-r--r--logger/loggers_test.go176
-rw-r--r--logger/logsystem.go60
-rw-r--r--logger/sys.go126
-rw-r--r--logger/types.go365
-rw-r--r--miner/agent.go98
-rw-r--r--miner/miner.go63
-rw-r--r--miner/remote_agent.go85
-rw-r--r--miner/worker.go326
-rw-r--r--p2p/discover/node.go345
-rw-r--r--p2p/discover/node_test.go219
-rw-r--r--p2p/discover/table.go363
-rw-r--r--p2p/discover/table_test.go323
-rw-r--r--p2p/discover/udp.go486
-rw-r--r--p2p/discover/udp_test.go339
-rw-r--r--p2p/handshake.go432
-rw-r--r--p2p/handshake_test.go171
-rw-r--r--p2p/message.go255
-rw-r--r--p2p/message_test.go135
-rw-r--r--p2p/nat/nat.go235
-rw-r--r--p2p/nat/natpmp.go115
-rw-r--r--p2p/nat/natupnp.go149
-rw-r--r--p2p/peer.go313
-rw-r--r--p2p/peer_error.go131
-rw-r--r--p2p/peer_test.go195
-rw-r--r--p2p/protocol.go50
-rw-r--r--p2p/rlpx.go174
-rw-r--r--p2p/rlpx_test.go124
-rw-r--r--p2p/server.go426
-rw-r--r--p2p/server_test.go179
-rw-r--r--p2p/testlog_test.go25
-rwxr-xr-xparams/protocol_params.go54
-rw-r--r--pow/block.go21
-rw-r--r--pow/dagger/dagger.go160
-rw-r--r--pow/dagger/dagger_test.go19
-rw-r--r--pow/ezp/pow.go99
-rw-r--r--pow/pow.go8
-rw-r--r--rlp/decode.go798
-rw-r--r--rlp/decode_test.go596
-rw-r--r--rlp/doc.go17
-rw-r--r--rlp/encode.go638
-rw-r--r--rlp/encode_test.go297
-rw-r--r--rlp/encoder_example_test.go38
-rw-r--r--rlp/typecache.go81
-rw-r--r--rpc/api.go462
-rw-r--r--rpc/api_test.go101
-rw-r--r--rpc/args.go1080
-rw-r--r--rpc/args_test.go2173
-rw-r--r--rpc/http.go127
-rw-r--r--rpc/jeth.go58
-rw-r--r--rpc/responses.go257
-rw-r--r--rpc/responses_test.go219
-rw-r--r--rpc/types.go269
-rw-r--r--rpc/types_test.go50
-rw-r--r--tests/blocktest.go289
-rw-r--r--tests/files/.gitignore5
-rw-r--r--tests/files/BasicTests/blockgenesistest.json (renamed from BasicTests/blockgenesistest.json)0
-rw-r--r--tests/files/BasicTests/crypto.json (renamed from BasicTests/crypto.json)0
-rw-r--r--tests/files/BasicTests/genesishashestest.json (renamed from BasicTests/genesishashestest.json)0
-rw-r--r--tests/files/BasicTests/hexencodetest.json (renamed from BasicTests/hexencodetest.json)0
-rw-r--r--tests/files/BasicTests/keyaddrtest.json (renamed from BasicTests/keyaddrtest.json)0
-rw-r--r--tests/files/BasicTests/rlptest.json (renamed from BasicTests/rlptest.json)0
-rw-r--r--tests/files/BasicTests/txtest.json (renamed from BasicTests/txtest.json)0
-rw-r--r--tests/files/BlockTests/bcInvalidHeaderTest.json (renamed from BlockTests/bcInvalidHeaderTest.json)0
-rw-r--r--tests/files/BlockTests/bcInvalidRLPTest.json (renamed from BlockTests/bcInvalidRLPTest.json)0
-rw-r--r--tests/files/BlockTests/bcJS_API_Test.json (renamed from BlockTests/bcJS_API_Test.json)0
-rw-r--r--tests/files/BlockTests/bcUncleTest.json (renamed from BlockTests/bcUncleTest.json)0
-rw-r--r--tests/files/BlockTests/bcValidBlockTest.json (renamed from BlockTests/bcValidBlockTest.json)0
-rw-r--r--tests/files/BlockchainTests/badBlockChain.json (renamed from BlockchainTests/badBlockChain.json)0
-rw-r--r--tests/files/BlockchainTests/basicBlockChain.json (renamed from BlockchainTests/basicBlockChain.json)0
-rw-r--r--tests/files/PoWTests/ethash_tests.json (renamed from PoWTests/ethash_tests.json)0
-rw-r--r--tests/files/README.md26
-rw-r--r--tests/files/StateTests/RandomTests/st201503121803PYTHON.json (renamed from StateTests/RandomTests/st201503121803PYTHON.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503121806PYTHON.json (renamed from StateTests/RandomTests/st201503121806PYTHON.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503121848GO.json (renamed from StateTests/RandomTests/st201503121848GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503121849GO.json (renamed from StateTests/RandomTests/st201503121849GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503121850GO.json (renamed from StateTests/RandomTests/st201503121850GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503121851GO.json (renamed from StateTests/RandomTests/st201503121851GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503121953GO.json (renamed from StateTests/RandomTests/st201503121953GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503122023GO.json (renamed from StateTests/RandomTests/st201503122023GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503122023PYTHON.json (renamed from StateTests/RandomTests/st201503122023PYTHON.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503122027GO.json (renamed from StateTests/RandomTests/st201503122027GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503122054GO.json (renamed from StateTests/RandomTests/st201503122054GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503122055GO.json (renamed from StateTests/RandomTests/st201503122055GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503122115CPPJIT.json (renamed from StateTests/RandomTests/st201503122115CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503122115GO.json (renamed from StateTests/RandomTests/st201503122115GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503122123GO.json (renamed from StateTests/RandomTests/st201503122123GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503122124GO.json (renamed from StateTests/RandomTests/st201503122124GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503122128PYTHON.json (renamed from StateTests/RandomTests/st201503122128PYTHON.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503122140GO.json (renamed from StateTests/RandomTests/st201503122140GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503122159GO.json (renamed from StateTests/RandomTests/st201503122159GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503122204GO.json (renamed from StateTests/RandomTests/st201503122204GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503122212GO.json (renamed from StateTests/RandomTests/st201503122212GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503122231GO.json (renamed from StateTests/RandomTests/st201503122231GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503122238GO.json (renamed from StateTests/RandomTests/st201503122238GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503122252GO.json (renamed from StateTests/RandomTests/st201503122252GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503122316GO.json (renamed from StateTests/RandomTests/st201503122316GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503122324GO.json (renamed from StateTests/RandomTests/st201503122324GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503122358GO.json (renamed from StateTests/RandomTests/st201503122358GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503130002GO.json (renamed from StateTests/RandomTests/st201503130002GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503130005GO.json (renamed from StateTests/RandomTests/st201503130005GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503130007GO.json (renamed from StateTests/RandomTests/st201503130007GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503130010GO.json (renamed from StateTests/RandomTests/st201503130010GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503130023PYTHON.json (renamed from StateTests/RandomTests/st201503130023PYTHON.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503130059GO.json (renamed from StateTests/RandomTests/st201503130059GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503130101GO.json (renamed from StateTests/RandomTests/st201503130101GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503130109GO.json (renamed from StateTests/RandomTests/st201503130109GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503130117GO.json (renamed from StateTests/RandomTests/st201503130117GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503130122GO.json (renamed from StateTests/RandomTests/st201503130122GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503130156GO.json (renamed from StateTests/RandomTests/st201503130156GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503130156PYTHON.json (renamed from StateTests/RandomTests/st201503130156PYTHON.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503130207GO.json (renamed from StateTests/RandomTests/st201503130207GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503130219CPPJIT.json (renamed from StateTests/RandomTests/st201503130219CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503130219GO.json (renamed from StateTests/RandomTests/st201503130219GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503130243GO.json (renamed from StateTests/RandomTests/st201503130243GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503130246GO.json (renamed from StateTests/RandomTests/st201503130246GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503130321GO.json (renamed from StateTests/RandomTests/st201503130321GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503130322GO.json (renamed from StateTests/RandomTests/st201503130322GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503130332GO.json (renamed from StateTests/RandomTests/st201503130332GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503130359GO.json (renamed from StateTests/RandomTests/st201503130359GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503130405GO.json (renamed from StateTests/RandomTests/st201503130405GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503130408GO.json (renamed from StateTests/RandomTests/st201503130408GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503130411GO.json (renamed from StateTests/RandomTests/st201503130411GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503130431GO.json (renamed from StateTests/RandomTests/st201503130431GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503130437GO.json (renamed from StateTests/RandomTests/st201503130437GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503130450GO.json (renamed from StateTests/RandomTests/st201503130450GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503130512CPPJIT.json (renamed from StateTests/RandomTests/st201503130512CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503130512GO.json (renamed from StateTests/RandomTests/st201503130512GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503130615GO.json (renamed from StateTests/RandomTests/st201503130615GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503130705GO.json (renamed from StateTests/RandomTests/st201503130705GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503130733CPPJIT.json (renamed from StateTests/RandomTests/st201503130733CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503130733GO.json (renamed from StateTests/RandomTests/st201503130733GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503130747GO.json (renamed from StateTests/RandomTests/st201503130747GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503130751GO.json (renamed from StateTests/RandomTests/st201503130751GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503130752PYTHON.json (renamed from StateTests/RandomTests/st201503130752PYTHON.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503130757PYTHON.json (renamed from StateTests/RandomTests/st201503130757PYTHON.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503131658GO.json (renamed from StateTests/RandomTests/st201503131658GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503131739GO.json (renamed from StateTests/RandomTests/st201503131739GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503131755CPPJIT.json (renamed from StateTests/RandomTests/st201503131755CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503131755GO.json (renamed from StateTests/RandomTests/st201503131755GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503132001CPPJIT.json (renamed from StateTests/RandomTests/st201503132001CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503132127PYTHON.json (renamed from StateTests/RandomTests/st201503132127PYTHON.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503132201CPPJIT.json (renamed from StateTests/RandomTests/st201503132201CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503132201GO.json (renamed from StateTests/RandomTests/st201503132201GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503132202PYTHON.json (renamed from StateTests/RandomTests/st201503132202PYTHON.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503140002PYTHON.json (renamed from StateTests/RandomTests/st201503140002PYTHON.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503140240PYTHON.json (renamed from StateTests/RandomTests/st201503140240PYTHON.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503140522PYTHON.json (renamed from StateTests/RandomTests/st201503140522PYTHON.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503140756PYTHON.json (renamed from StateTests/RandomTests/st201503140756PYTHON.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503141144PYTHON.json (renamed from StateTests/RandomTests/st201503141144PYTHON.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503141510PYTHON.json (renamed from StateTests/RandomTests/st201503141510PYTHON.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503150427PYTHON.json (renamed from StateTests/RandomTests/st201503150427PYTHON.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503150716PYTHON.json (renamed from StateTests/RandomTests/st201503150716PYTHON.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503151450PYTHON.json (renamed from StateTests/RandomTests/st201503151450PYTHON.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503151516PYTHON.json (renamed from StateTests/RandomTests/st201503151516PYTHON.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503151753PYTHON.json (renamed from StateTests/RandomTests/st201503151753PYTHON.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503152057PYTHON.json (renamed from StateTests/RandomTests/st201503152057PYTHON.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503152241PYTHON.json (renamed from StateTests/RandomTests/st201503152241PYTHON.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503160014PYTHON.json (renamed from StateTests/RandomTests/st201503160014PYTHON.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503160733PYTHON.json (renamed from StateTests/RandomTests/st201503160733PYTHON.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503170051PYTHON.json (renamed from StateTests/RandomTests/st201503170051PYTHON.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503170433PYTHON.json (renamed from StateTests/RandomTests/st201503170433PYTHON.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503170523PYTHON.json (renamed from StateTests/RandomTests/st201503170523PYTHON.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503171108PYTHON.json (renamed from StateTests/RandomTests/st201503171108PYTHON.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181223GO.json (renamed from StateTests/RandomTests/st201503181223GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181225GO.json (renamed from StateTests/RandomTests/st201503181225GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181226CPPJIT.json (renamed from StateTests/RandomTests/st201503181226CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181227CPPJIT.json (renamed from StateTests/RandomTests/st201503181227CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181227GO.json (renamed from StateTests/RandomTests/st201503181227GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181229GO.json (renamed from StateTests/RandomTests/st201503181229GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181230CPPJIT.json (renamed from StateTests/RandomTests/st201503181230CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181230GO.json (renamed from StateTests/RandomTests/st201503181230GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181231GO.json (renamed from StateTests/RandomTests/st201503181231GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181232CPPJIT.json (renamed from StateTests/RandomTests/st201503181232CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181232GO.json (renamed from StateTests/RandomTests/st201503181232GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181233GO.json (renamed from StateTests/RandomTests/st201503181233GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181234CPPJIT.json (renamed from StateTests/RandomTests/st201503181234CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181234GO.json (renamed from StateTests/RandomTests/st201503181234GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181235CPPJIT.json (renamed from StateTests/RandomTests/st201503181235CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181235GO.json (renamed from StateTests/RandomTests/st201503181235GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181236GO.json (renamed from StateTests/RandomTests/st201503181236GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181237GO.json (renamed from StateTests/RandomTests/st201503181237GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181239GO.json (renamed from StateTests/RandomTests/st201503181239GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181241CPPJIT.json (renamed from StateTests/RandomTests/st201503181241CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181241GO.json (renamed from StateTests/RandomTests/st201503181241GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181243GO.json (renamed from StateTests/RandomTests/st201503181243GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181244GO.json (renamed from StateTests/RandomTests/st201503181244GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181245CPPJIT.json (renamed from StateTests/RandomTests/st201503181245CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181245GO.json (renamed from StateTests/RandomTests/st201503181245GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181246CPPJIT.json (renamed from StateTests/RandomTests/st201503181246CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181246GO.json (renamed from StateTests/RandomTests/st201503181246GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181247GO.json (renamed from StateTests/RandomTests/st201503181247GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181248GO.json (renamed from StateTests/RandomTests/st201503181248GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181249GO.json (renamed from StateTests/RandomTests/st201503181249GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181250CPPJIT.json (renamed from StateTests/RandomTests/st201503181250CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181250GO.json (renamed from StateTests/RandomTests/st201503181250GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181251GO.json (renamed from StateTests/RandomTests/st201503181251GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181252CPPJIT.json (renamed from StateTests/RandomTests/st201503181252CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181253GO.json (renamed from StateTests/RandomTests/st201503181253GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181255CPPJIT.json (renamed from StateTests/RandomTests/st201503181255CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181255GO.json (renamed from StateTests/RandomTests/st201503181255GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181257GO.json (renamed from StateTests/RandomTests/st201503181257GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181258CPPJIT.json (renamed from StateTests/RandomTests/st201503181258CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181258GO.json (renamed from StateTests/RandomTests/st201503181258GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181301CPPJIT.json (renamed from StateTests/RandomTests/st201503181301CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181301GO.json (renamed from StateTests/RandomTests/st201503181301GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181303GO.json (renamed from StateTests/RandomTests/st201503181303GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181304GO.json (renamed from StateTests/RandomTests/st201503181304GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181305GO.json (renamed from StateTests/RandomTests/st201503181305GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181306GO.json (renamed from StateTests/RandomTests/st201503181306GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181307CPPJIT.json (renamed from StateTests/RandomTests/st201503181307CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181307GO.json (renamed from StateTests/RandomTests/st201503181307GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181308GO.json (renamed from StateTests/RandomTests/st201503181308GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181309GO.json (renamed from StateTests/RandomTests/st201503181309GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181310GO.json (renamed from StateTests/RandomTests/st201503181310GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181311GO.json (renamed from StateTests/RandomTests/st201503181311GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181313GO.json (renamed from StateTests/RandomTests/st201503181313GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181314GO.json (renamed from StateTests/RandomTests/st201503181314GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181315CPPJIT.json (renamed from StateTests/RandomTests/st201503181315CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181315GO.json (renamed from StateTests/RandomTests/st201503181315GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181316CPPJIT.json (renamed from StateTests/RandomTests/st201503181316CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181316PYTHON.json (renamed from StateTests/RandomTests/st201503181316PYTHON.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181317GO.json (renamed from StateTests/RandomTests/st201503181317GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181318CPPJIT.json (renamed from StateTests/RandomTests/st201503181318CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181318GO.json (renamed from StateTests/RandomTests/st201503181318GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181319GO.json (renamed from StateTests/RandomTests/st201503181319GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181319PYTHON.json (renamed from StateTests/RandomTests/st201503181319PYTHON.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181322GO.json (renamed from StateTests/RandomTests/st201503181322GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181323CPPJIT.json (renamed from StateTests/RandomTests/st201503181323CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181323GO.json (renamed from StateTests/RandomTests/st201503181323GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181324GO.json (renamed from StateTests/RandomTests/st201503181324GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181325GO.json (renamed from StateTests/RandomTests/st201503181325GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181326CPPJIT.json (renamed from StateTests/RandomTests/st201503181326CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181326GO.json (renamed from StateTests/RandomTests/st201503181326GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181327GO.json (renamed from StateTests/RandomTests/st201503181327GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181329CPPJIT.json (renamed from StateTests/RandomTests/st201503181329CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181329GO.json (renamed from StateTests/RandomTests/st201503181329GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181330GO.json (renamed from StateTests/RandomTests/st201503181330GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181332GO.json (renamed from StateTests/RandomTests/st201503181332GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181333GO.json (renamed from StateTests/RandomTests/st201503181333GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181334GO.json (renamed from StateTests/RandomTests/st201503181334GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181336CPPJIT.json (renamed from StateTests/RandomTests/st201503181336CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181337GO.json (renamed from StateTests/RandomTests/st201503181337GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181338GO.json (renamed from StateTests/RandomTests/st201503181338GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181339CPPJIT.json (renamed from StateTests/RandomTests/st201503181339CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181339GO.json (renamed from StateTests/RandomTests/st201503181339GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181340GO.json (renamed from StateTests/RandomTests/st201503181340GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181341CPPJIT.json (renamed from StateTests/RandomTests/st201503181341CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181342CPPJIT.json (renamed from StateTests/RandomTests/st201503181342CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181342GO.json (renamed from StateTests/RandomTests/st201503181342GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181345GO.json (renamed from StateTests/RandomTests/st201503181345GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181346GO.json (renamed from StateTests/RandomTests/st201503181346GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181347CPPJIT.json (renamed from StateTests/RandomTests/st201503181347CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181347GO.json (renamed from StateTests/RandomTests/st201503181347GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181347PYTHON.json (renamed from StateTests/RandomTests/st201503181347PYTHON.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181350CPPJIT.json (renamed from StateTests/RandomTests/st201503181350CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181352GO.json (renamed from StateTests/RandomTests/st201503181352GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181353GO.json (renamed from StateTests/RandomTests/st201503181353GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181354CPPJIT.json (renamed from StateTests/RandomTests/st201503181354CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181354GO.json (renamed from StateTests/RandomTests/st201503181354GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181355GO.json (renamed from StateTests/RandomTests/st201503181355GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181356CPPJIT.json (renamed from StateTests/RandomTests/st201503181356CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181357CPPJIT.json (renamed from StateTests/RandomTests/st201503181357CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181358CPPJIT.json (renamed from StateTests/RandomTests/st201503181358CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181358GO.json (renamed from StateTests/RandomTests/st201503181358GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181359GO.json (renamed from StateTests/RandomTests/st201503181359GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181402CPPJIT.json (renamed from StateTests/RandomTests/st201503181402CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181403GO.json (renamed from StateTests/RandomTests/st201503181403GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181406CPPJIT.json (renamed from StateTests/RandomTests/st201503181406CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181406GO.json (renamed from StateTests/RandomTests/st201503181406GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181410GO.json (renamed from StateTests/RandomTests/st201503181410GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181412CPPJIT.json (renamed from StateTests/RandomTests/st201503181412CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181413GO.json (renamed from StateTests/RandomTests/st201503181413GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181415GO.json (renamed from StateTests/RandomTests/st201503181415GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181416GO.json (renamed from StateTests/RandomTests/st201503181416GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181417CPPJIT.json (renamed from StateTests/RandomTests/st201503181417CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181417GO.json (renamed from StateTests/RandomTests/st201503181417GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181418CPPJIT.json (renamed from StateTests/RandomTests/st201503181418CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181422GO.json (renamed from StateTests/RandomTests/st201503181422GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181423CPPJIT.json (renamed from StateTests/RandomTests/st201503181423CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181424GO.json (renamed from StateTests/RandomTests/st201503181424GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181426CPPJIT.json (renamed from StateTests/RandomTests/st201503181426CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181426GO.json (renamed from StateTests/RandomTests/st201503181426GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181428GO.json (renamed from StateTests/RandomTests/st201503181428GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181430CPPJIT.json (renamed from StateTests/RandomTests/st201503181430CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181435GO.json (renamed from StateTests/RandomTests/st201503181435GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181436GO.json (renamed from StateTests/RandomTests/st201503181436GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181437CPPJIT.json (renamed from StateTests/RandomTests/st201503181437CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181437GO.json (renamed from StateTests/RandomTests/st201503181437GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181438CPPJIT.json (renamed from StateTests/RandomTests/st201503181438CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181438GO.json (renamed from StateTests/RandomTests/st201503181438GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181439CPPJIT.json (renamed from StateTests/RandomTests/st201503181439CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181439GO.json (renamed from StateTests/RandomTests/st201503181439GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181439PYTHON.json (renamed from StateTests/RandomTests/st201503181439PYTHON.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181440GO.json (renamed from StateTests/RandomTests/st201503181440GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181441GO.json (renamed from StateTests/RandomTests/st201503181441GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181442GO.json (renamed from StateTests/RandomTests/st201503181442GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181445CPPJIT.json (renamed from StateTests/RandomTests/st201503181445CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181446GO.json (renamed from StateTests/RandomTests/st201503181446GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181447GO.json (renamed from StateTests/RandomTests/st201503181447GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181450GO.json (renamed from StateTests/RandomTests/st201503181450GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181451CPPJIT.json (renamed from StateTests/RandomTests/st201503181451CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181453GO.json (renamed from StateTests/RandomTests/st201503181453GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181455GO.json (renamed from StateTests/RandomTests/st201503181455GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181456CPPJIT.json (renamed from StateTests/RandomTests/st201503181456CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181457GO.json (renamed from StateTests/RandomTests/st201503181457GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181458GO.json (renamed from StateTests/RandomTests/st201503181458GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181459GO.json (renamed from StateTests/RandomTests/st201503181459GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181500GO.json (renamed from StateTests/RandomTests/st201503181500GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181501GO.json (renamed from StateTests/RandomTests/st201503181501GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181503GO.json (renamed from StateTests/RandomTests/st201503181503GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181504GO.json (renamed from StateTests/RandomTests/st201503181504GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181505GO.json (renamed from StateTests/RandomTests/st201503181505GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181506CPPJIT.json (renamed from StateTests/RandomTests/st201503181506CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181507GO.json (renamed from StateTests/RandomTests/st201503181507GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181509CPPJIT.json (renamed from StateTests/RandomTests/st201503181509CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181509GO.json (renamed from StateTests/RandomTests/st201503181509GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181510GO.json (renamed from StateTests/RandomTests/st201503181510GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181511GO.json (renamed from StateTests/RandomTests/st201503181511GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181512GO.json (renamed from StateTests/RandomTests/st201503181512GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181513CPPJIT.json (renamed from StateTests/RandomTests/st201503181513CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181513GO.json (renamed from StateTests/RandomTests/st201503181513GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181514CPPJIT.json (renamed from StateTests/RandomTests/st201503181514CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181514GO.json (renamed from StateTests/RandomTests/st201503181514GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181517CPPJIT.json (renamed from StateTests/RandomTests/st201503181517CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181517GO.json (renamed from StateTests/RandomTests/st201503181517GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181519CPPJIT.json (renamed from StateTests/RandomTests/st201503181519CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181519GO.json (renamed from StateTests/RandomTests/st201503181519GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181520CPPJIT.json (renamed from StateTests/RandomTests/st201503181520CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181520GO.json (renamed from StateTests/RandomTests/st201503181520GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181521GO.json (renamed from StateTests/RandomTests/st201503181521GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181522GO.json (renamed from StateTests/RandomTests/st201503181522GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181524CPPJIT.json (renamed from StateTests/RandomTests/st201503181524CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181524GO.json (renamed from StateTests/RandomTests/st201503181524GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181526GO.json (renamed from StateTests/RandomTests/st201503181526GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181527GO.json (renamed from StateTests/RandomTests/st201503181527GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181528CPPJIT.json (renamed from StateTests/RandomTests/st201503181528CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181528GO.json (renamed from StateTests/RandomTests/st201503181528GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181528PYTHON.json (renamed from StateTests/RandomTests/st201503181528PYTHON.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181529GO.json (renamed from StateTests/RandomTests/st201503181529GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181531CPPJIT.json (renamed from StateTests/RandomTests/st201503181531CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181533GO.json (renamed from StateTests/RandomTests/st201503181533GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181534CPPJIT.json (renamed from StateTests/RandomTests/st201503181534CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181534GO.json (renamed from StateTests/RandomTests/st201503181534GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181536CPPJIT.json (renamed from StateTests/RandomTests/st201503181536CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181536GO.json (renamed from StateTests/RandomTests/st201503181536GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181537GO.json (renamed from StateTests/RandomTests/st201503181537GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181538GO.json (renamed from StateTests/RandomTests/st201503181538GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181539GO.json (renamed from StateTests/RandomTests/st201503181539GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181540CPPJIT.json (renamed from StateTests/RandomTests/st201503181540CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181540PYTHON.json (renamed from StateTests/RandomTests/st201503181540PYTHON.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181543GO.json (renamed from StateTests/RandomTests/st201503181543GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181544CPPJIT.json (renamed from StateTests/RandomTests/st201503181544CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181544GO.json (renamed from StateTests/RandomTests/st201503181544GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181547GO.json (renamed from StateTests/RandomTests/st201503181547GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181548CPPJIT.json (renamed from StateTests/RandomTests/st201503181548CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181548GO.json (renamed from StateTests/RandomTests/st201503181548GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181551GO.json (renamed from StateTests/RandomTests/st201503181551GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181552CPPJIT.json (renamed from StateTests/RandomTests/st201503181552CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181553GO.json (renamed from StateTests/RandomTests/st201503181553GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181555CPPJIT.json (renamed from StateTests/RandomTests/st201503181555CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181555GO.json (renamed from StateTests/RandomTests/st201503181555GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181557GO.json (renamed from StateTests/RandomTests/st201503181557GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181559GO.json (renamed from StateTests/RandomTests/st201503181559GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181601CPPJIT.json (renamed from StateTests/RandomTests/st201503181601CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181601GO.json (renamed from StateTests/RandomTests/st201503181601GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181602GO.json (renamed from StateTests/RandomTests/st201503181602GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181603GO.json (renamed from StateTests/RandomTests/st201503181603GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181604GO.json (renamed from StateTests/RandomTests/st201503181604GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181605GO.json (renamed from StateTests/RandomTests/st201503181605GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181606GO.json (renamed from StateTests/RandomTests/st201503181606GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181607GO.json (renamed from StateTests/RandomTests/st201503181607GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181608CPPJIT.json (renamed from StateTests/RandomTests/st201503181608CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181608GO.json (renamed from StateTests/RandomTests/st201503181608GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181609GO.json (renamed from StateTests/RandomTests/st201503181609GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181610CPPJIT.json (renamed from StateTests/RandomTests/st201503181610CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181610GO.json (renamed from StateTests/RandomTests/st201503181610GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181611CPPJIT.json (renamed from StateTests/RandomTests/st201503181611CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181611GO.json (renamed from StateTests/RandomTests/st201503181611GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181612GO.json (renamed from StateTests/RandomTests/st201503181612GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181614CPPJIT.json (renamed from StateTests/RandomTests/st201503181614CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181614GO.json (renamed from StateTests/RandomTests/st201503181614GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181616CPPJIT.json (renamed from StateTests/RandomTests/st201503181616CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181616GO.json (renamed from StateTests/RandomTests/st201503181616GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181617GO.json (renamed from StateTests/RandomTests/st201503181617GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181618GO.json (renamed from StateTests/RandomTests/st201503181618GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181619GO.json (renamed from StateTests/RandomTests/st201503181619GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181620CPPJIT.json (renamed from StateTests/RandomTests/st201503181620CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181620GO.json (renamed from StateTests/RandomTests/st201503181620GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181621GO.json (renamed from StateTests/RandomTests/st201503181621GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181625GO.json (renamed from StateTests/RandomTests/st201503181625GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181626CPPJIT.json (renamed from StateTests/RandomTests/st201503181626CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181626GO.json (renamed from StateTests/RandomTests/st201503181626GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181627GO.json (renamed from StateTests/RandomTests/st201503181627GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181628GO.json (renamed from StateTests/RandomTests/st201503181628GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181629GO.json (renamed from StateTests/RandomTests/st201503181629GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181630CPPJIT.json (renamed from StateTests/RandomTests/st201503181630CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181630GO.json (renamed from StateTests/RandomTests/st201503181630GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181630PYTHON.json (renamed from StateTests/RandomTests/st201503181630PYTHON.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181632GO.json (renamed from StateTests/RandomTests/st201503181632GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181634CPPJIT.json (renamed from StateTests/RandomTests/st201503181634CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181635GO.json (renamed from StateTests/RandomTests/st201503181635GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181636GO.json (renamed from StateTests/RandomTests/st201503181636GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181638GO.json (renamed from StateTests/RandomTests/st201503181638GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181639CPPJIT.json (renamed from StateTests/RandomTests/st201503181639CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181641GO.json (renamed from StateTests/RandomTests/st201503181641GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181645GO.json (renamed from StateTests/RandomTests/st201503181645GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181646GO.json (renamed from StateTests/RandomTests/st201503181646GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181647CPPJIT.json (renamed from StateTests/RandomTests/st201503181647CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181649CPPJIT.json (renamed from StateTests/RandomTests/st201503181649CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181650GO.json (renamed from StateTests/RandomTests/st201503181650GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181652CPPJIT.json (renamed from StateTests/RandomTests/st201503181652CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181653GO.json (renamed from StateTests/RandomTests/st201503181653GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181654GO.json (renamed from StateTests/RandomTests/st201503181654GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181655CPPJIT.json (renamed from StateTests/RandomTests/st201503181655CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181655GO.json (renamed from StateTests/RandomTests/st201503181655GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181656CPPJIT.json (renamed from StateTests/RandomTests/st201503181656CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181656GO.json (renamed from StateTests/RandomTests/st201503181656GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181657GO.json (renamed from StateTests/RandomTests/st201503181657GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181658GO.json (renamed from StateTests/RandomTests/st201503181658GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181700GO.json (renamed from StateTests/RandomTests/st201503181700GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181702GO.json (renamed from StateTests/RandomTests/st201503181702GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181703CPPJIT.json (renamed from StateTests/RandomTests/st201503181703CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181703GO.json (renamed from StateTests/RandomTests/st201503181703GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181704GO.json (renamed from StateTests/RandomTests/st201503181704GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181706GO.json (renamed from StateTests/RandomTests/st201503181706GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181709GO.json (renamed from StateTests/RandomTests/st201503181709GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181711CPPJIT.json (renamed from StateTests/RandomTests/st201503181711CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181711GO.json (renamed from StateTests/RandomTests/st201503181711GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181713CPPJIT.json (renamed from StateTests/RandomTests/st201503181713CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181713GO.json (renamed from StateTests/RandomTests/st201503181713GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181714GO.json (renamed from StateTests/RandomTests/st201503181714GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181715CPPJIT.json (renamed from StateTests/RandomTests/st201503181715CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181715GO.json (renamed from StateTests/RandomTests/st201503181715GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181716GO.json (renamed from StateTests/RandomTests/st201503181716GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181717GO.json (renamed from StateTests/RandomTests/st201503181717GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181720CPPJIT.json (renamed from StateTests/RandomTests/st201503181720CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181722GO.json (renamed from StateTests/RandomTests/st201503181722GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181723CPPJIT.json (renamed from StateTests/RandomTests/st201503181723CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181723GO.json (renamed from StateTests/RandomTests/st201503181723GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181724CPPJIT.json (renamed from StateTests/RandomTests/st201503181724CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181724GO.json (renamed from StateTests/RandomTests/st201503181724GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181725GO.json (renamed from StateTests/RandomTests/st201503181725GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181728GO.json (renamed from StateTests/RandomTests/st201503181728GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181729GO.json (renamed from StateTests/RandomTests/st201503181729GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181730GO.json (renamed from StateTests/RandomTests/st201503181730GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181731CPPJIT.json (renamed from StateTests/RandomTests/st201503181731CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181732GO.json (renamed from StateTests/RandomTests/st201503181732GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181734CPPJIT.json (renamed from StateTests/RandomTests/st201503181734CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181734GO.json (renamed from StateTests/RandomTests/st201503181734GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181735GO.json (renamed from StateTests/RandomTests/st201503181735GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181737CPPJIT.json (renamed from StateTests/RandomTests/st201503181737CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181737GO.json (renamed from StateTests/RandomTests/st201503181737GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181738CPPJIT.json (renamed from StateTests/RandomTests/st201503181738CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181738GO.json (renamed from StateTests/RandomTests/st201503181738GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181739GO.json (renamed from StateTests/RandomTests/st201503181739GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181740CPPJIT.json (renamed from StateTests/RandomTests/st201503181740CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181740GO.json (renamed from StateTests/RandomTests/st201503181740GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181742CPPJIT.json (renamed from StateTests/RandomTests/st201503181742CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181743GO.json (renamed from StateTests/RandomTests/st201503181743GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181744GO.json (renamed from StateTests/RandomTests/st201503181744GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181745CPPJIT.json (renamed from StateTests/RandomTests/st201503181745CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181746GO.json (renamed from StateTests/RandomTests/st201503181746GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181747GO.json (renamed from StateTests/RandomTests/st201503181747GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181748GO.json (renamed from StateTests/RandomTests/st201503181748GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181749GO.json (renamed from StateTests/RandomTests/st201503181749GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181750CPPJIT.json (renamed from StateTests/RandomTests/st201503181750CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181750GO.json (renamed from StateTests/RandomTests/st201503181750GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181752GO.json (renamed from StateTests/RandomTests/st201503181752GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181753CPPJIT.json (renamed from StateTests/RandomTests/st201503181753CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181754CPPJIT.json (renamed from StateTests/RandomTests/st201503181754CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181754GO.json (renamed from StateTests/RandomTests/st201503181754GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181755CPPJIT.json (renamed from StateTests/RandomTests/st201503181755CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181755GO.json (renamed from StateTests/RandomTests/st201503181755GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181756GO.json (renamed from StateTests/RandomTests/st201503181756GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181757CPPJIT.json (renamed from StateTests/RandomTests/st201503181757CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181757GO.json (renamed from StateTests/RandomTests/st201503181757GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181759GO.json (renamed from StateTests/RandomTests/st201503181759GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181800GO.json (renamed from StateTests/RandomTests/st201503181800GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181801GO.json (renamed from StateTests/RandomTests/st201503181801GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181802GO.json (renamed from StateTests/RandomTests/st201503181802GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181803CPPJIT.json (renamed from StateTests/RandomTests/st201503181803CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181803GO.json (renamed from StateTests/RandomTests/st201503181803GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181804GO.json (renamed from StateTests/RandomTests/st201503181804GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181806GO.json (renamed from StateTests/RandomTests/st201503181806GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181808GO.json (renamed from StateTests/RandomTests/st201503181808GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181809CPPJIT.json (renamed from StateTests/RandomTests/st201503181809CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181812CPPJIT.json (renamed from StateTests/RandomTests/st201503181812CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181812GO.json (renamed from StateTests/RandomTests/st201503181812GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181814CPPJIT.json (renamed from StateTests/RandomTests/st201503181814CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181815GO.json (renamed from StateTests/RandomTests/st201503181815GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181816CPPJIT.json (renamed from StateTests/RandomTests/st201503181816CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181817CPPJIT.json (renamed from StateTests/RandomTests/st201503181817CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181819GO.json (renamed from StateTests/RandomTests/st201503181819GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181821GO.json (renamed from StateTests/RandomTests/st201503181821GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181822GO.json (renamed from StateTests/RandomTests/st201503181822GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181823GO.json (renamed from StateTests/RandomTests/st201503181823GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181824GO.json (renamed from StateTests/RandomTests/st201503181824GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181825GO.json (renamed from StateTests/RandomTests/st201503181825GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181829GO.json (renamed from StateTests/RandomTests/st201503181829GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181830CPPJIT.json (renamed from StateTests/RandomTests/st201503181830CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181833GO.json (renamed from StateTests/RandomTests/st201503181833GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181834CPPJIT.json (renamed from StateTests/RandomTests/st201503181834CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181834GO.json (renamed from StateTests/RandomTests/st201503181834GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181837GO.json (renamed from StateTests/RandomTests/st201503181837GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181840GO.json (renamed from StateTests/RandomTests/st201503181840GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181842GO.json (renamed from StateTests/RandomTests/st201503181842GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181843GO.json (renamed from StateTests/RandomTests/st201503181843GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181844GO.json (renamed from StateTests/RandomTests/st201503181844GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181845GO.json (renamed from StateTests/RandomTests/st201503181845GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181846GO.json (renamed from StateTests/RandomTests/st201503181846GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181847GO.json (renamed from StateTests/RandomTests/st201503181847GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181848GO.json (renamed from StateTests/RandomTests/st201503181848GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181849GO.json (renamed from StateTests/RandomTests/st201503181849GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181850GO.json (renamed from StateTests/RandomTests/st201503181850GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181851CPPJIT.json (renamed from StateTests/RandomTests/st201503181851CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181851GO.json (renamed from StateTests/RandomTests/st201503181851GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181852CPPJIT.json (renamed from StateTests/RandomTests/st201503181852CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181854GO.json (renamed from StateTests/RandomTests/st201503181854GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181855CPPJIT.json (renamed from StateTests/RandomTests/st201503181855CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181857PYTHON.json (renamed from StateTests/RandomTests/st201503181857PYTHON.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181859GO.json (renamed from StateTests/RandomTests/st201503181859GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181900GO.json (renamed from StateTests/RandomTests/st201503181900GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181903GO.json (renamed from StateTests/RandomTests/st201503181903GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181904GO.json (renamed from StateTests/RandomTests/st201503181904GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181906GO.json (renamed from StateTests/RandomTests/st201503181906GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181907GO.json (renamed from StateTests/RandomTests/st201503181907GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181910GO.json (renamed from StateTests/RandomTests/st201503181910GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181915GO.json (renamed from StateTests/RandomTests/st201503181915GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181919CPPJIT.json (renamed from StateTests/RandomTests/st201503181919CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181919PYTHON.json (renamed from StateTests/RandomTests/st201503181919PYTHON.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181920GO.json (renamed from StateTests/RandomTests/st201503181920GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181922GO.json (renamed from StateTests/RandomTests/st201503181922GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181926GO.json (renamed from StateTests/RandomTests/st201503181926GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181929GO.json (renamed from StateTests/RandomTests/st201503181929GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181931CPPJIT.json (renamed from StateTests/RandomTests/st201503181931CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181931GO.json (renamed from StateTests/RandomTests/st201503181931GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503181931PYTHON.json (renamed from StateTests/RandomTests/st201503181931PYTHON.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503191646GO.json (renamed from StateTests/RandomTests/st201503191646GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503200837JS.json (renamed from StateTests/RandomTests/st201503200837JS.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503200838JS.json (renamed from StateTests/RandomTests/st201503200838JS.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503200841JS.json (renamed from StateTests/RandomTests/st201503200841JS.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503200848JS.json (renamed from StateTests/RandomTests/st201503200848JS.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503240609JS.json (renamed from StateTests/RandomTests/st201503240609JS.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503302200JS.json (renamed from StateTests/RandomTests/st201503302200JS.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503302202JS.json (renamed from StateTests/RandomTests/st201503302202JS.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503302206JS.json (renamed from StateTests/RandomTests/st201503302206JS.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503302208JS.json (renamed from StateTests/RandomTests/st201503302208JS.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503302210JS.json (renamed from StateTests/RandomTests/st201503302210JS.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201503302211JS.json (renamed from StateTests/RandomTests/st201503302211JS.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201504011535GO.json (renamed from StateTests/RandomTests/st201504011535GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201504011536GO.json (renamed from StateTests/RandomTests/st201504011536GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201504011547GO.json (renamed from StateTests/RandomTests/st201504011547GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201504011916JS.json (renamed from StateTests/RandomTests/st201504011916JS.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201504012130JS.json (renamed from StateTests/RandomTests/st201504012130JS.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201504012259JS.json (renamed from StateTests/RandomTests/st201504012259JS.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201504012359JS.json (renamed from StateTests/RandomTests/st201504012359JS.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201504020305JS.json (renamed from StateTests/RandomTests/st201504020305JS.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201504020400JS.json (renamed from StateTests/RandomTests/st201504020400JS.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201504020428JS.json (renamed from StateTests/RandomTests/st201504020428JS.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201504020431JS.json (renamed from StateTests/RandomTests/st201504020431JS.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201504020444JS.json (renamed from StateTests/RandomTests/st201504020444JS.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201504020538JS.json (renamed from StateTests/RandomTests/st201504020538JS.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201504020639JS.json (renamed from StateTests/RandomTests/st201504020639JS.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201504020836JS.json (renamed from StateTests/RandomTests/st201504020836JS.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201504020910JS.json (renamed from StateTests/RandomTests/st201504020910JS.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201504021057JS.json (renamed from StateTests/RandomTests/st201504021057JS.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201504021104JS.json (renamed from StateTests/RandomTests/st201504021104JS.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201504021237CPPJIT.json (renamed from StateTests/RandomTests/st201504021237CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201504021237GO.json (renamed from StateTests/RandomTests/st201504021237GO.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201504021237JS.json (renamed from StateTests/RandomTests/st201504021237JS.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201504021237PYTHON.json (renamed from StateTests/RandomTests/st201504021237PYTHON.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201504021949JS.json (renamed from StateTests/RandomTests/st201504021949JS.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201504022003CPPJIT.json (renamed from StateTests/RandomTests/st201504022003CPPJIT.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201504022124JS.json (renamed from StateTests/RandomTests/st201504022124JS.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201504030138JS.json (renamed from StateTests/RandomTests/st201504030138JS.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201504030646JS.json (renamed from StateTests/RandomTests/st201504030646JS.json)0
-rw-r--r--tests/files/StateTests/RandomTests/st201504030709JS.json (renamed from StateTests/RandomTests/st201504030709JS.json)0
-rw-r--r--tests/files/StateTests/stBlockHashTest.json (renamed from StateTests/stBlockHashTest.json)0
-rw-r--r--tests/files/StateTests/stCallCreateCallCodeTest.json (renamed from StateTests/stCallCreateCallCodeTest.json)0
-rw-r--r--tests/files/StateTests/stExample.json (renamed from StateTests/stExample.json)0
-rw-r--r--tests/files/StateTests/stInitCodeTest.json (renamed from StateTests/stInitCodeTest.json)0
-rw-r--r--tests/files/StateTests/stLogTests.json (renamed from StateTests/stLogTests.json)0
-rw-r--r--tests/files/StateTests/stMemoryStressTest.json (renamed from StateTests/stMemoryStressTest.json)0
-rw-r--r--tests/files/StateTests/stMemoryTest.json (renamed from StateTests/stMemoryTest.json)0
-rw-r--r--tests/files/StateTests/stPreCompiledContracts.json (renamed from StateTests/stPreCompiledContracts.json)0
-rw-r--r--tests/files/StateTests/stQuadraticComplexityTest.json (renamed from StateTests/stQuadraticComplexityTest.json)0
-rw-r--r--tests/files/StateTests/stRecursiveCreate.json (renamed from StateTests/stRecursiveCreate.json)0
-rw-r--r--tests/files/StateTests/stRefundTest.json (renamed from StateTests/stRefundTest.json)0
-rw-r--r--tests/files/StateTests/stSolidityTest.json (renamed from StateTests/stSolidityTest.json)0
-rw-r--r--tests/files/StateTests/stSpecialTest.json (renamed from StateTests/stSpecialTest.json)0
-rw-r--r--tests/files/StateTests/stSystemOperationsTest.json (renamed from StateTests/stSystemOperationsTest.json)0
-rw-r--r--tests/files/StateTests/stTransactionTest.json (renamed from StateTests/stTransactionTest.json)0
-rw-r--r--tests/files/TODO (renamed from TODO)0
-rw-r--r--tests/files/TransactionTests/tt10mbDataField.json (renamed from TransactionTests/tt10mbDataField.json)0
-rw-r--r--tests/files/TransactionTests/ttTransactionTest.json (renamed from TransactionTests/ttTransactionTest.json)0
-rw-r--r--tests/files/TransactionTests/ttWrongRLPTransaction.json (renamed from TransactionTests/ttWrongRLPTransaction.json)0
-rw-r--r--tests/files/TrieTests/hex_encoded_securetrie_test.json (renamed from TrieTests/hex_encoded_securetrie_test.json)0
-rw-r--r--tests/files/TrieTests/trieanyorder.json (renamed from TrieTests/trieanyorder.json)0
-rw-r--r--tests/files/TrieTests/trieanyorder_secureTrie.json (renamed from TrieTests/trieanyorder_secureTrie.json)0
-rw-r--r--tests/files/TrieTests/trietest.json (renamed from TrieTests/trietest.json)0
-rw-r--r--tests/files/TrieTests/trietest_secureTrie.json (renamed from TrieTests/trietest_secureTrie.json)0
-rw-r--r--tests/files/TrieTests/trietestnextprev.json (renamed from TrieTests/trietestnextprev.json)0
-rw-r--r--tests/files/VMTests/RandomTests/201503102037PYTHON.json (renamed from VMTests/RandomTests/201503102037PYTHON.json)0
-rw-r--r--tests/files/VMTests/RandomTests/201503102148PYTHON.json (renamed from VMTests/RandomTests/201503102148PYTHON.json)0
-rw-r--r--tests/files/VMTests/RandomTests/201503102300PYTHON.json (renamed from VMTests/RandomTests/201503102300PYTHON.json)0
-rw-r--r--tests/files/VMTests/RandomTests/201503102320PYTHON.json (renamed from VMTests/RandomTests/201503102320PYTHON.json)0
-rw-r--r--tests/files/VMTests/RandomTests/201503110050PYTHON.json (renamed from VMTests/RandomTests/201503110050PYTHON.json)0
-rw-r--r--tests/files/VMTests/RandomTests/201503110206PYTHON.json (renamed from VMTests/RandomTests/201503110206PYTHON.json)0
-rw-r--r--tests/files/VMTests/RandomTests/201503110219PYTHON.json (renamed from VMTests/RandomTests/201503110219PYTHON.json)0
-rw-r--r--tests/files/VMTests/RandomTests/201503110226PYTHON_DUP6.json (renamed from VMTests/RandomTests/201503110226PYTHON_DUP6.json)0
-rw-r--r--tests/files/VMTests/RandomTests/201503110346PYTHON_PUSH24.json (renamed from VMTests/RandomTests/201503110346PYTHON_PUSH24.json)0
-rw-r--r--tests/files/VMTests/RandomTests/201503110526PYTHON.json (renamed from VMTests/RandomTests/201503110526PYTHON.json)0
-rw-r--r--tests/files/VMTests/RandomTests/201503111844PYTHON.json (renamed from VMTests/RandomTests/201503111844PYTHON.json)0
-rw-r--r--tests/files/VMTests/RandomTests/201503112218PYTHON.json (renamed from VMTests/RandomTests/201503112218PYTHON.json)0
-rw-r--r--tests/files/VMTests/RandomTests/201503120317PYTHON.json (renamed from VMTests/RandomTests/201503120317PYTHON.json)0
-rw-r--r--tests/files/VMTests/RandomTests/201503120525PYTHON.json (renamed from VMTests/RandomTests/201503120525PYTHON.json)0
-rw-r--r--tests/files/VMTests/RandomTests/201503120547PYTHON.json (renamed from VMTests/RandomTests/201503120547PYTHON.json)0
-rw-r--r--tests/files/VMTests/RandomTests/201503120909PYTHON.json (renamed from VMTests/RandomTests/201503120909PYTHON.json)0
-rw-r--r--tests/files/VMTests/RandomTests/randomTest.json (renamed from VMTests/RandomTests/randomTest.json)0
-rw-r--r--tests/files/VMTests/vmArithmeticTest.json (renamed from VMTests/vmArithmeticTest.json)0
-rw-r--r--tests/files/VMTests/vmBitwiseLogicOperationTest.json (renamed from VMTests/vmBitwiseLogicOperationTest.json)0
-rw-r--r--tests/files/VMTests/vmBlockInfoTest.json (renamed from VMTests/vmBlockInfoTest.json)0
-rw-r--r--tests/files/VMTests/vmEnvironmentalInfoTest.json (renamed from VMTests/vmEnvironmentalInfoTest.json)0
-rw-r--r--tests/files/VMTests/vmIOandFlowOperationsTest.json (renamed from VMTests/vmIOandFlowOperationsTest.json)0
-rw-r--r--tests/files/VMTests/vmInputLimits1.json (renamed from VMTests/vmInputLimits1.json)0
-rw-r--r--tests/files/VMTests/vmInputLimits2.json (renamed from VMTests/vmInputLimits2.json)0
-rw-r--r--tests/files/VMTests/vmInputLimitsLight.json (renamed from VMTests/vmInputLimitsLight.json)0
-rw-r--r--tests/files/VMTests/vmLogTest.json (renamed from VMTests/vmLogTest.json)0
-rw-r--r--tests/files/VMTests/vmPerformanceTest.json (renamed from VMTests/vmPerformanceTest.json)0
-rw-r--r--tests/files/VMTests/vmPushDupSwapTest.json (renamed from VMTests/vmPushDupSwapTest.json)0
-rw-r--r--tests/files/VMTests/vmSha3Test.json (renamed from VMTests/vmSha3Test.json)0
-rw-r--r--tests/files/VMTests/vmSystemOperationsTest.json (renamed from VMTests/vmSystemOperationsTest.json)0
-rw-r--r--tests/files/VMTests/vmtests.json (renamed from VMTests/vmtests.json)0
-rw-r--r--tests/files/ansible/README.md (renamed from ansible/README.md)0
-rw-r--r--tests/files/ansible/Vagrantfile (renamed from ansible/Vagrantfile)0
-rw-r--r--tests/files/ansible/ec2-setup.yml (renamed from ansible/ec2-setup.yml)0
-rw-r--r--tests/files/ansible/ec2-terminate.yml (renamed from ansible/ec2-terminate.yml)0
-rw-r--r--tests/files/ansible/ec2.ini (renamed from ansible/ec2.ini)0
-rwxr-xr-xtests/files/ansible/ec2.py (renamed from ansible/ec2.py)0
-rw-r--r--tests/files/ansible/host-config.yml (renamed from ansible/host-config.yml)0
-rw-r--r--tests/files/ansible/roles/common/handlers/main.yml (renamed from ansible/roles/common/handlers/main.yml)0
-rw-r--r--tests/files/ansible/roles/common/tasks/main.yml (renamed from ansible/roles/common/tasks/main.yml)0
-rw-r--r--tests/files/ansible/roles/docker/handlers/main.yml (renamed from ansible/roles/docker/handlers/main.yml)0
-rw-r--r--tests/files/ansible/roles/docker/tasks/main.yml (renamed from ansible/roles/docker/tasks/main.yml)0
-rw-r--r--tests/files/ansible/roles/ec2/tasks/setup.yml (renamed from ansible/roles/ec2/tasks/setup.yml)0
-rw-r--r--tests/files/ansible/roles/ec2/tasks/terminate.yml (renamed from ansible/roles/ec2/tasks/terminate.yml)0
-rw-r--r--tests/files/ansible/roles/ec2/vars/main.yml (renamed from ansible/roles/ec2/vars/main.yml)0
-rw-r--r--tests/files/ansible/roles/testrunner/tasks/main.yml (renamed from ansible/roles/testrunner/tasks/main.yml)0
-rw-r--r--tests/files/ansible/site.yml (renamed from ansible/site.yml)0
-rwxr-xr-xtests/files/ansible/test-files/create-docker-images.sh (renamed from ansible/test-files/create-docker-images.sh)0
-rw-r--r--tests/files/ansible/test-files/docker-cpp/Dockerfile (renamed from ansible/test-files/docker-cpp/Dockerfile)0
-rw-r--r--tests/files/ansible/test-files/docker-cppjit/Dockerfile (renamed from ansible/test-files/docker-cppjit/Dockerfile)0
-rw-r--r--tests/files/ansible/test-files/docker-go/Dockerfile (renamed from ansible/test-files/docker-go/Dockerfile)0
-rw-r--r--tests/files/ansible/test-files/docker-python/Dockerfile (renamed from ansible/test-files/docker-python/Dockerfile)0
-rwxr-xr-xtests/files/ansible/test-files/testrunner.sh (renamed from ansible/test-files/testrunner.sh)0
-rw-r--r--tests/files/ansible/testrunner-config.yml (renamed from ansible/testrunner-config.yml)0
-rw-r--r--tests/files/index.js (renamed from index.js)0
-rw-r--r--tests/files/package.json (renamed from package.json)0
-rw-r--r--tests/helper/common.go11
-rw-r--r--tests/helper/init.go16
-rw-r--r--tests/helper/readers.go42
-rw-r--r--tests/helper/trie.go31
-rw-r--r--tests/helper/vm.go211
-rw-r--r--tests/vm/.ethtest0
-rw-r--r--tests/vm/gh_test.go313
-rw-r--r--tests/vm/nowarn.go3
-rw-r--r--trie/cache.go50
-rw-r--r--trie/encoding.go76
-rw-r--r--trie/encoding_test.go59
-rw-r--r--trie/fullnode.go77
-rw-r--r--trie/hashnode.go25
-rw-r--r--trie/iterator.go124
-rw-r--r--trie/iterator_test.go33
-rw-r--r--trie/node.go44
-rw-r--r--trie/secure_trie.go45
-rw-r--r--trie/shortnode.go35
-rw-r--r--trie/slice.go53
-rw-r--r--trie/trie.go352
-rw-r--r--trie/trie_test.go338
-rw-r--r--trie/valuenode.go15
-rw-r--r--ui/filter.go1
-rw-r--r--ui/qt/filter.go1
-rw-r--r--ui/qt/qwhisper/message.go23
-rw-r--r--ui/qt/qwhisper/watch.go13
-rw-r--r--ui/qt/qwhisper/whisper.go113
-rw-r--r--ui/qt/qwhisper/whisper_test.go15
-rw-r--r--ui/qt/webengine/all.cpp1
-rw-r--r--ui/qt/webengine/cpp/webengine.cpp6
-rw-r--r--ui/qt/webengine/cpp/webengine.h14
-rw-r--r--ui/qt/webengine/webengine.go18
-rw-r--r--update-license.go248
-rw-r--r--whisper/doc.go16
-rw-r--r--whisper/envelope.go129
-rw-r--r--whisper/filter.go10
-rw-r--r--whisper/main.go37
-rw-r--r--whisper/message.go81
-rw-r--r--whisper/messages_test.go50
-rw-r--r--whisper/peer.go113
-rw-r--r--whisper/sort.go29
-rw-r--r--whisper/sort_test.go23
-rw-r--r--whisper/util.go36
-rw-r--r--whisper/whisper.go275
-rw-r--r--whisper/whisper_test.go38
-rw-r--r--xeth/frontend.go32
-rw-r--r--xeth/state.go36
-rw-r--r--xeth/types.go223
-rw-r--r--xeth/whisper.go120
-rw-r--r--xeth/xeth.go729
1795 files changed, 516717 insertions, 22 deletions
diff --git a/.gitignore b/.gitignore
index 188ff005d..e5a5d2fbe 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1,5 +1,31 @@
-venv/
+# See http://help.github.com/ignore-files/ for more about ignoring files.
+#
+# If you find yourself ignoring temporary files generated by your text editor
+# or operating system, you probably want to add a global ignore instead:
+# git config --global core.excludesfile ~/.gitignore_global
+
+/tmp
+*/**/*un~
+*/**/*.test
+*un~
+.DS_Store
+*/**/.DS_Store
+.ethtest
+*/**/*tx_database*
+*/**/*dapps*
+Godeps/_workspace/pkg
+Godeps/_workspace/bin
+
+#*
+.#*
+*#
*~
-*.sw?
-.vagrant/
-*.pem
+.project
+.settings
+
+geth
+mist
+cmd/geth/geth
+cmd/mist/mist
+deploy/osx/Mist.app
+deploy/osx/Mist\ Installer.dmg
diff --git a/.gitmodules b/.gitmodules
new file mode 100644
index 000000000..3284c329d
--- /dev/null
+++ b/.gitmodules
@@ -0,0 +1,3 @@
+[submodule "cmd/mist/assets/ext/ethereum.js"]
+ path = cmd/mist/assets/ext/ethereum.js
+ url = https://github.com/ethereum/ethereum.js
diff --git a/.mailmap b/.mailmap
new file mode 100644
index 000000000..a3a3020ac
--- /dev/null
+++ b/.mailmap
@@ -0,0 +1,14 @@
+Jeffrey Wilcke <jeffrey@ethereum.org>
+Jeffrey Wilcke <jeffrey@ethereum.org> <geffobscura@gmail.com>
+Jeffrey Wilcke <jeffrey@ethereum.org> <obscuren@obscura.com>
+Jeffrey Wilcke <jeffrey@ethereum.org> <obscuren@users.noreply.github.com>
+
+Viktor Trón <viktor.tron@gmail.com>
+
+Joseph Goulden <joegoulden@gmail.com>
+
+Nick Savers <nicksavers@gmail.com>
+
+Maran Hidskes <maran.hidskes@gmail.com>
+
+Taylor Gerring <taylor.gerring@gmail.com> <taylor.gerring@ethereum.org>
diff --git a/.travis.yml b/.travis.yml
new file mode 100644
index 000000000..d6954e0cb
--- /dev/null
+++ b/.travis.yml
@@ -0,0 +1,36 @@
+language: go
+go:
+ - 1.4.2
+before_install:
+ - sudo add-apt-repository ppa:beineri/opt-qt541 -y
+ - sudo apt-get update -qq
+ - sudo apt-get install -yqq libgmp3-dev libreadline6-dev qt54quickcontrols qt54webengine
+install:
+ # - go get code.google.com/p/go.tools/cmd/goimports
+ # - go get github.com/golang/lint/golint
+ # - go get golang.org/x/tools/cmd/vet
+ - go get golang.org/x/tools/cmd/cover
+ - go get github.com/mattn/goveralls
+before_script:
+ # - gofmt -l -w .
+ # - goimports -l -w .
+ # - golint .
+ # - go vet ./...
+ # - go test -race ./...
+script:
+ - ./gocoverage.sh
+after_success:
+ - if [ "$COVERALLS_TOKEN" ]; then goveralls -coverprofile=profile.cov -service=travis-ci -repotoken $COVERALLS_TOKEN; fi
+env:
+ global:
+ - PKG_CONFIG_PATH=/opt/qt54/lib/pkgconfig
+ - LD_LIBRARY_PATH=/opt/qt54/lib
+ - secure: "U2U1AmkU4NJBgKR/uUAebQY87cNL0+1JHjnLOmmXwxYYyj5ralWb1aSuSH3qSXiT93qLBmtaUkuv9fberHVqrbAeVlztVdUsKAq7JMQH+M99iFkC9UiRMqHmtjWJ0ok4COD1sRYixxi21wb/JrMe3M1iL4QJVS61iltjHhVdM64="
+
+notifications:
+ webhooks:
+ urls:
+ - https://webhooks.gitter.im/e/e09ccdce1048c5e03445
+ on_success: change # options: [always|never|change] default: always
+ on_failure: always # options: [always|never|change] default: always
+ on_start: false # default: false
diff --git a/Dockerfile b/Dockerfile
new file mode 100644
index 000000000..fcd564a34
--- /dev/null
+++ b/Dockerfile
@@ -0,0 +1,39 @@
+FROM ubuntu:14.04.2
+
+## Environment setup
+ENV HOME /root
+ENV GOPATH /root/go
+ENV PATH /root/go/bin:/usr/local/go/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games
+
+RUN mkdir -p /root/go
+ENV DEBIAN_FRONTEND noninteractive
+
+## Install base dependencies
+RUN apt-get update && apt-get upgrade -y
+RUN apt-get install -y git mercurial build-essential software-properties-common wget pkg-config libgmp3-dev libreadline6-dev libpcre3-dev libpcre++-dev
+
+## Install Qt5.4.1 (not required for CLI)
+# RUN add-apt-repository ppa:beineri/opt-qt541-trusty -y
+# RUN apt-get update -y
+# RUN apt-get install -y qt54quickcontrols qt54webengine mesa-common-dev libglu1-mesa-dev
+# ENV PKG_CONFIG_PATH /opt/qt54/lib/pkgconfig
+
+# Install Golang
+RUN wget https://storage.googleapis.com/golang/go1.4.2.linux-amd64.tar.gz
+RUN tar -C /usr/local -xzf go*.tar.gz && go version
+
+# this is a workaround, to make sure that docker's cache is invalidated whenever the git repo changes
+ADD https://api.github.com/repos/ethereum/go-ethereum/git/refs/heads/develop file_does_not_exist
+
+## Fetch and install go-ethereum
+RUN mkdir -p $GOPATH/src/github.com/ethereum/
+RUN git clone https://github.com/ethereum/go-ethereum $GOPATH/src/github.com/ethereum/go-ethereum
+WORKDIR $GOPATH/src/github.com/ethereum/go-ethereum
+RUN git checkout develop
+RUN GOPATH=$GOPATH:$GOPATH/src/github.com/ethereum/go-ethereum/Godeps/_workspace go install -v ./cmd/geth
+
+## Run & expose JSON RPC
+ENTRYPOINT ["geth", "-rpc=true", "-rpcport=8545"]
+EXPOSE 8545
+
+
diff --git a/Godeps/Godeps.json b/Godeps/Godeps.json
new file mode 100644
index 000000000..4c8c8281e
--- /dev/null
+++ b/Godeps/Godeps.json
@@ -0,0 +1,131 @@
+{
+ "ImportPath": "github.com/ethereum/go-ethereum",
+ "GoVersion": "go1.4.2",
+ "Packages": [
+ "./..."
+ ],
+ "Deps": [
+ {
+ "ImportPath": "code.google.com/p/go-uuid/uuid",
+ "Comment": "null-12",
+ "Rev": "7dda39b2e7d5e265014674c5af696ba4186679e9"
+ },
+ {
+ "ImportPath": "code.google.com/p/snappy-go/snappy",
+ "Comment": "null-15",
+ "Rev": "12e4b4183793ac4b061921e7980845e750679fd0"
+ },
+ {
+ "ImportPath": "github.com/codegangsta/cli",
+ "Comment": "1.2.0-95-g9b2bd2b",
+ "Rev": "9b2bd2b3489748d4d0a204fa4eb2ee9e89e0ebc6"
+ },
+ {
+ "ImportPath": "github.com/ethereum/ethash",
+ "Comment": "v23.1-33-g6ecb8e6",
+ "Rev": "6ecb8e610d60240187b44f61e66b06198c26fae6"
+ },
+ {
+ "ImportPath": "github.com/ethereum/serpent-go",
+ "Rev": "5767a0dbd759d313df3f404dadb7f98d7ab51443"
+ },
+ {
+ "ImportPath": "github.com/howeyc/fsnotify",
+ "Comment": "v0.9.0-11-g6b1ef89",
+ "Rev": "6b1ef893dc11e0447abda6da20a5203481878dda"
+ },
+ {
+ "ImportPath": "github.com/huin/goupnp",
+ "Rev": "4191d8a85005844ea202fde52799681971b12dfe"
+ },
+ {
+ "ImportPath": "github.com/jackpal/go-nat-pmp",
+ "Rev": "a45aa3d54aef73b504e15eb71bea0e5565b5e6e1"
+ },
+ {
+ "ImportPath": "github.com/kardianos/osext",
+ "Rev": "ccfcd0245381f0c94c68f50626665eed3c6b726a"
+ },
+ {
+ "ImportPath": "github.com/robertkrimen/otto",
+ "Rev": "dea31a3d392779af358ec41f77a07fcc7e9d04ba"
+ },
+ {
+ "ImportPath": "github.com/obscuren/qml",
+ "Rev": "c288002b52e905973b131089a8a7c761d4a2c36a"
+ },
+ {
+ "ImportPath": "github.com/peterh/liner",
+ "Rev": "29f6a646557d83e2b6e9ba05c45fbea9c006dbe8"
+ },
+ {
+ "ImportPath": "github.com/rakyll/globalconf",
+ "Rev": "415abc325023f1a00cd2d9fa512e0e71745791a2"
+ },
+ {
+ "ImportPath": "github.com/rakyll/goini",
+ "Rev": "907cca0f578a5316fb864ec6992dc3d9730ec58c"
+ },
+ {
+ "ImportPath": "github.com/robertkrimen/otto/ast",
+ "Rev": "dea31a3d392779af358ec41f77a07fcc7e9d04ba"
+ },
+ {
+ "ImportPath": "github.com/robertkrimen/otto/dbg",
+ "Rev": "dea31a3d392779af358ec41f77a07fcc7e9d04ba"
+ },
+ {
+ "ImportPath": "github.com/robertkrimen/otto/file",
+ "Rev": "dea31a3d392779af358ec41f77a07fcc7e9d04ba"
+ },
+ {
+ "ImportPath": "github.com/robertkrimen/otto/parser",
+ "Rev": "dea31a3d392779af358ec41f77a07fcc7e9d04ba"
+ },
+ {
+ "ImportPath": "github.com/robertkrimen/otto/registry",
+ "Rev": "dea31a3d392779af358ec41f77a07fcc7e9d04ba"
+ },
+ {
+ "ImportPath": "github.com/robertkrimen/otto/token",
+ "Rev": "dea31a3d392779af358ec41f77a07fcc7e9d04ba"
+ },
+ {
+ "ImportPath": "github.com/rs/cors",
+ "Rev": "6e0c3cb65fc0fdb064c743d176a620e3ca446dfb"
+ },
+ {
+ "ImportPath": "github.com/syndtr/goleveldb/leveldb",
+ "Rev": "832fa7ed4d28545eab80f19e1831fc004305cade"
+ },
+ {
+ "ImportPath": "golang.org/x/crypto/pbkdf2",
+ "Rev": "4ed45ec682102c643324fae5dff8dab085b6c300"
+ },
+ {
+ "ImportPath": "golang.org/x/crypto/ripemd160",
+ "Rev": "4ed45ec682102c643324fae5dff8dab085b6c300"
+ },
+ {
+ "ImportPath": "golang.org/x/crypto/scrypt",
+ "Rev": "4ed45ec682102c643324fae5dff8dab085b6c300"
+ },
+ {
+ "ImportPath": "gopkg.in/check.v1",
+ "Rev": "64131543e7896d5bcc6bd5a76287eb75ea96c673"
+ },
+ {
+ "ImportPath": "gopkg.in/fatih/set.v0",
+ "Comment": "v0.1.0-3-g27c4092",
+ "Rev": "27c40922c40b43fe04554d8223a402af3ea333f3"
+ },
+ {
+ "ImportPath": "gopkg.in/qml.v1/cdata",
+ "Rev": "1116cb9cd8dee23f8d444ded354eb53122739f99"
+ },
+ {
+ "ImportPath": "gopkg.in/qml.v1/gl/glbase",
+ "Rev": "1116cb9cd8dee23f8d444ded354eb53122739f99"
+ }
+ ]
+}
diff --git a/Godeps/Readme b/Godeps/Readme
new file mode 100644
index 000000000..4cdaa53d5
--- /dev/null
+++ b/Godeps/Readme
@@ -0,0 +1,5 @@
+This directory tree is generated automatically by godep.
+
+Please do not edit.
+
+See https://github.com/tools/godep for more information.
diff --git a/Godeps/_workspace/.gitignore b/Godeps/_workspace/.gitignore
new file mode 100644
index 000000000..f037d684e
--- /dev/null
+++ b/Godeps/_workspace/.gitignore
@@ -0,0 +1,2 @@
+/pkg
+/bin
diff --git a/Godeps/_workspace/src/code.google.com/p/go-uuid/uuid/LICENSE b/Godeps/_workspace/src/code.google.com/p/go-uuid/uuid/LICENSE
new file mode 100644
index 000000000..ab6b011a1
--- /dev/null
+++ b/Godeps/_workspace/src/code.google.com/p/go-uuid/uuid/LICENSE
@@ -0,0 +1,27 @@
+Copyright (c) 2009 Google Inc. All rights reserved.
+
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions are
+met:
+
+ * Redistributions of source code must retain the above copyright
+notice, this list of conditions and the following disclaimer.
+ * Redistributions in binary form must reproduce the above
+copyright notice, this list of conditions and the following disclaimer
+in the documentation and/or other materials provided with the
+distribution.
+ * Neither the name of Google Inc. nor the names of its
+contributors may be used to endorse or promote products derived from
+this software without specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
diff --git a/Godeps/_workspace/src/code.google.com/p/go-uuid/uuid/dce.go b/Godeps/_workspace/src/code.google.com/p/go-uuid/uuid/dce.go
new file mode 100644
index 000000000..50a0f2d09
--- /dev/null
+++ b/Godeps/_workspace/src/code.google.com/p/go-uuid/uuid/dce.go
@@ -0,0 +1,84 @@
+// Copyright 2011 Google Inc. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+package uuid
+
+import (
+ "encoding/binary"
+ "fmt"
+ "os"
+)
+
+// A Domain represents a Version 2 domain
+type Domain byte
+
+// Domain constants for DCE Security (Version 2) UUIDs.
+const (
+ Person = Domain(0)
+ Group = Domain(1)
+ Org = Domain(2)
+)
+
+// NewDCESecurity returns a DCE Security (Version 2) UUID.
+//
+// The domain should be one of Person, Group or Org.
+// On a POSIX system the id should be the users UID for the Person
+// domain and the users GID for the Group. The meaning of id for
+// the domain Org or on non-POSIX systems is site defined.
+//
+// For a given domain/id pair the same token may be returned for up to
+// 7 minutes and 10 seconds.
+func NewDCESecurity(domain Domain, id uint32) UUID {
+ uuid := NewUUID()
+ if uuid != nil {
+ uuid[6] = (uuid[6] & 0x0f) | 0x20 // Version 2
+ uuid[9] = byte(domain)
+ binary.BigEndian.PutUint32(uuid[0:], id)
+ }
+ return uuid
+}
+
+// NewDCEPerson returns a DCE Security (Version 2) UUID in the person
+// domain with the id returned by os.Getuid.
+//
+// NewDCEPerson(Person, uint32(os.Getuid()))
+func NewDCEPerson() UUID {
+ return NewDCESecurity(Person, uint32(os.Getuid()))
+}
+
+// NewDCEGroup returns a DCE Security (Version 2) UUID in the group
+// domain with the id returned by os.Getgid.
+//
+// NewDCEGroup(Group, uint32(os.Getgid()))
+func NewDCEGroup() UUID {
+ return NewDCESecurity(Group, uint32(os.Getgid()))
+}
+
+// Domain returns the domain for a Version 2 UUID or false.
+func (uuid UUID) Domain() (Domain, bool) {
+ if v, _ := uuid.Version(); v != 2 {
+ return 0, false
+ }
+ return Domain(uuid[9]), true
+}
+
+// Id returns the id for a Version 2 UUID or false.
+func (uuid UUID) Id() (uint32, bool) {
+ if v, _ := uuid.Version(); v != 2 {
+ return 0, false
+ }
+ return binary.BigEndian.Uint32(uuid[0:4]), true
+}
+
+func (d Domain) String() string {
+ switch d {
+ case Person:
+ return "Person"
+ case Group:
+ return "Group"
+ case Org:
+ return "Org"
+ }
+ return fmt.Sprintf("Domain%d", int(d))
+}
diff --git a/Godeps/_workspace/src/code.google.com/p/go-uuid/uuid/doc.go b/Godeps/_workspace/src/code.google.com/p/go-uuid/uuid/doc.go
new file mode 100644
index 000000000..d8bd013e6
--- /dev/null
+++ b/Godeps/_workspace/src/code.google.com/p/go-uuid/uuid/doc.go
@@ -0,0 +1,8 @@
+// Copyright 2011 Google Inc. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// The uuid package generates and inspects UUIDs.
+//
+// UUIDs are based on RFC 4122 and DCE 1.1: Authentication and Security Services.
+package uuid
diff --git a/Godeps/_workspace/src/code.google.com/p/go-uuid/uuid/hash.go b/Godeps/_workspace/src/code.google.com/p/go-uuid/uuid/hash.go
new file mode 100644
index 000000000..cdd4192fd
--- /dev/null
+++ b/Godeps/_workspace/src/code.google.com/p/go-uuid/uuid/hash.go
@@ -0,0 +1,53 @@
+// Copyright 2011 Google Inc. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+package uuid
+
+import (
+ "crypto/md5"
+ "crypto/sha1"
+ "hash"
+)
+
+// Well known Name Space IDs and UUIDs
+var (
+ NameSpace_DNS = Parse("6ba7b810-9dad-11d1-80b4-00c04fd430c8")
+ NameSpace_URL = Parse("6ba7b811-9dad-11d1-80b4-00c04fd430c8")
+ NameSpace_OID = Parse("6ba7b812-9dad-11d1-80b4-00c04fd430c8")
+ NameSpace_X500 = Parse("6ba7b814-9dad-11d1-80b4-00c04fd430c8")
+ NIL = Parse("00000000-0000-0000-0000-000000000000")
+)
+
+// NewHash returns a new UUID dervied from the hash of space concatenated with
+// data generated by h. The hash should be at least 16 byte in length. The
+// first 16 bytes of the hash are used to form the UUID. The version of the
+// UUID will be the lower 4 bits of version. NewHash is used to implement
+// NewMD5 and NewSHA1.
+func NewHash(h hash.Hash, space UUID, data []byte, version int) UUID {
+ h.Reset()
+ h.Write(space)
+ h.Write([]byte(data))
+ s := h.Sum(nil)
+ uuid := make([]byte, 16)
+ copy(uuid, s)
+ uuid[6] = (uuid[6] & 0x0f) | uint8((version&0xf)<<4)
+ uuid[8] = (uuid[8] & 0x3f) | 0x80 // RFC 4122 variant
+ return uuid
+}
+
+// NewMD5 returns a new MD5 (Version 3) UUID based on the
+// supplied name space and data.
+//
+// NewHash(md5.New(), space, data, 3)
+func NewMD5(space UUID, data []byte) UUID {
+ return NewHash(md5.New(), space, data, 3)
+}
+
+// NewSHA1 returns a new SHA1 (Version 5) UUID based on the
+// supplied name space and data.
+//
+// NewHash(sha1.New(), space, data, 5)
+func NewSHA1(space UUID, data []byte) UUID {
+ return NewHash(sha1.New(), space, data, 5)
+}
diff --git a/Godeps/_workspace/src/code.google.com/p/go-uuid/uuid/node.go b/Godeps/_workspace/src/code.google.com/p/go-uuid/uuid/node.go
new file mode 100644
index 000000000..dd0a8ac18
--- /dev/null
+++ b/Godeps/_workspace/src/code.google.com/p/go-uuid/uuid/node.go
@@ -0,0 +1,101 @@
+// Copyright 2011 Google Inc. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+package uuid
+
+import "net"
+
+var (
+ interfaces []net.Interface // cached list of interfaces
+ ifname string // name of interface being used
+ nodeID []byte // hardware for version 1 UUIDs
+)
+
+// NodeInterface returns the name of the interface from which the NodeID was
+// derived. The interface "user" is returned if the NodeID was set by
+// SetNodeID.
+func NodeInterface() string {
+ return ifname
+}
+
+// SetNodeInterface selects the hardware address to be used for Version 1 UUIDs.
+// If name is "" then the first usable interface found will be used or a random
+// Node ID will be generated. If a named interface cannot be found then false
+// is returned.
+//
+// SetNodeInterface never fails when name is "".
+func SetNodeInterface(name string) bool {
+ if interfaces == nil {
+ var err error
+ interfaces, err = net.Interfaces()
+ if err != nil && name != "" {
+ return false
+ }
+ }
+
+ for _, ifs := range interfaces {
+ if len(ifs.HardwareAddr) >= 6 && (name == "" || name == ifs.Name) {
+ if setNodeID(ifs.HardwareAddr) {
+ ifname = ifs.Name
+ return true
+ }
+ }
+ }
+
+ // We found no interfaces with a valid hardware address. If name
+ // does not specify a specific interface generate a random Node ID
+ // (section 4.1.6)
+ if name == "" {
+ if nodeID == nil {
+ nodeID = make([]byte, 6)
+ }
+ randomBits(nodeID)
+ return true
+ }
+ return false
+}
+
+// NodeID returns a slice of a copy of the current Node ID, setting the Node ID
+// if not already set.
+func NodeID() []byte {
+ if nodeID == nil {
+ SetNodeInterface("")
+ }
+ nid := make([]byte, 6)
+ copy(nid, nodeID)
+ return nid
+}
+
+// SetNodeID sets the Node ID to be used for Version 1 UUIDs. The first 6 bytes
+// of id are used. If id is less than 6 bytes then false is returned and the
+// Node ID is not set.
+func SetNodeID(id []byte) bool {
+ if setNodeID(id) {
+ ifname = "user"
+ return true
+ }
+ return false
+}
+
+func setNodeID(id []byte) bool {
+ if len(id) < 6 {
+ return false
+ }
+ if nodeID == nil {
+ nodeID = make([]byte, 6)
+ }
+ copy(nodeID, id)
+ return true
+}
+
+// NodeID returns the 6 byte node id encoded in uuid. It returns nil if uuid is
+// not valid. The NodeID is only well defined for version 1 and 2 UUIDs.
+func (uuid UUID) NodeID() []byte {
+ if len(uuid) != 16 {
+ return nil
+ }
+ node := make([]byte, 6)
+ copy(node, uuid[10:])
+ return node
+}
diff --git a/Godeps/_workspace/src/code.google.com/p/go-uuid/uuid/time.go b/Godeps/_workspace/src/code.google.com/p/go-uuid/uuid/time.go
new file mode 100644
index 000000000..b9369c200
--- /dev/null
+++ b/Godeps/_workspace/src/code.google.com/p/go-uuid/uuid/time.go
@@ -0,0 +1,132 @@
+// Copyright 2014 Google Inc. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+package uuid
+
+import (
+ "encoding/binary"
+ "sync"
+ "time"
+)
+
+// A Time represents a time as the number of 100's of nanoseconds since 15 Oct
+// 1582.
+type Time int64
+
+const (
+ lillian = 2299160 // Julian day of 15 Oct 1582
+ unix = 2440587 // Julian day of 1 Jan 1970
+ epoch = unix - lillian // Days between epochs
+ g1582 = epoch * 86400 // seconds between epochs
+ g1582ns100 = g1582 * 10000000 // 100s of a nanoseconds between epochs
+)
+
+var (
+ mu sync.Mutex
+ lasttime uint64 // last time we returned
+ clock_seq uint16 // clock sequence for this run
+
+ timeNow = time.Now // for testing
+)
+
+// UnixTime converts t the number of seconds and nanoseconds using the Unix
+// epoch of 1 Jan 1970.
+func (t Time) UnixTime() (sec, nsec int64) {
+ sec = int64(t - g1582ns100)
+ nsec = (sec % 10000000) * 100
+ sec /= 10000000
+ return sec, nsec
+}
+
+// GetTime returns the current Time (100s of nanoseconds since 15 Oct 1582) and
+// adjusts the clock sequence as needed. An error is returned if the current
+// time cannot be determined.
+func GetTime() (Time, error) {
+ defer mu.Unlock()
+ mu.Lock()
+ return getTime()
+}
+
+func getTime() (Time, error) {
+ t := timeNow()
+
+ // If we don't have a clock sequence already, set one.
+ if clock_seq == 0 {
+ setClockSequence(-1)
+ }
+ now := uint64(t.UnixNano()/100) + g1582ns100
+
+ // If time has gone backwards with this clock sequence then we
+ // increment the clock sequence
+ if now <= lasttime {
+ clock_seq = ((clock_seq + 1) & 0x3fff) | 0x8000
+ }
+ lasttime = now
+ return Time(now), nil
+}
+
+// ClockSequence returns the current clock sequence, generating one if not
+// already set. The clock sequence is only used for Version 1 UUIDs.
+//
+// The uuid package does not use global static storage for the clock sequence or
+// the last time a UUID was generated. Unless SetClockSequence a new random
+// clock sequence is generated the first time a clock sequence is requested by
+// ClockSequence, GetTime, or NewUUID. (section 4.2.1.1) sequence is generated
+// for
+func ClockSequence() int {
+ defer mu.Unlock()
+ mu.Lock()
+ return clockSequence()
+}
+
+func clockSequence() int {
+ if clock_seq == 0 {
+ setClockSequence(-1)
+ }
+ return int(clock_seq & 0x3fff)
+}
+
+// SetClockSeq sets the clock sequence to the lower 14 bits of seq. Setting to
+// -1 causes a new sequence to be generated.
+func SetClockSequence(seq int) {
+ defer mu.Unlock()
+ mu.Lock()
+ setClockSequence(seq)
+}
+
+func setClockSequence(seq int) {
+ if seq == -1 {
+ var b [2]byte
+ randomBits(b[:]) // clock sequence
+ seq = int(b[0])<<8 | int(b[1])
+ }
+ old_seq := clock_seq
+ clock_seq = uint16(seq&0x3fff) | 0x8000 // Set our variant
+ if old_seq != clock_seq {
+ lasttime = 0
+ }
+}
+
+// Time returns the time in 100s of nanoseconds since 15 Oct 1582 encoded in
+// uuid. It returns false if uuid is not valid. The time is only well defined
+// for version 1 and 2 UUIDs.
+func (uuid UUID) Time() (Time, bool) {
+ if len(uuid) != 16 {
+ return 0, false
+ }
+ time := int64(binary.BigEndian.Uint32(uuid[0:4]))
+ time |= int64(binary.BigEndian.Uint16(uuid[4:6])) << 32
+ time |= int64(binary.BigEndian.Uint16(uuid[6:8])&0xfff) << 48
+ return Time(time), true
+}
+
+// ClockSequence returns the clock sequence encoded in uuid. It returns false
+// if uuid is not valid. The clock sequence is only well defined for version 1
+// and 2 UUIDs.
+func (uuid UUID) ClockSequence() (int, bool) {
+ if len(uuid) != 16 {
+ return 0, false
+ }
+ return int(binary.BigEndian.Uint16(uuid[8:10])) & 0x3fff, true
+}
diff --git a/Godeps/_workspace/src/code.google.com/p/go-uuid/uuid/util.go b/Godeps/_workspace/src/code.google.com/p/go-uuid/uuid/util.go
new file mode 100644
index 000000000..de40b102c
--- /dev/null
+++ b/Godeps/_workspace/src/code.google.com/p/go-uuid/uuid/util.go
@@ -0,0 +1,43 @@
+// Copyright 2011 Google Inc. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+package uuid
+
+import (
+ "io"
+)
+
+// randomBits completely fills slice b with random data.
+func randomBits(b []byte) {
+ if _, err := io.ReadFull(rander, b); err != nil {
+ panic(err.Error()) // rand should never fail
+ }
+}
+
+// xvalues returns the value of a byte as a hexadecimal digit or 255.
+var xvalues = []byte{
+ 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255,
+ 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255,
+ 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255,
+ 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 255, 255, 255, 255, 255, 255,
+ 255, 10, 11, 12, 13, 14, 15, 255, 255, 255, 255, 255, 255, 255, 255, 255,
+ 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255,
+ 255, 10, 11, 12, 13, 14, 15, 255, 255, 255, 255, 255, 255, 255, 255, 255,
+ 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255,
+ 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255,
+ 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255,
+ 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255,
+ 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255,
+ 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255,
+ 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255,
+ 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255,
+ 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255,
+}
+
+// xtob converts the the first two hex bytes of x into a byte.
+func xtob(x string) (byte, bool) {
+ b1 := xvalues[x[0]]
+ b2 := xvalues[x[1]]
+ return (b1 << 4) | b2, b1 != 255 && b2 != 255
+}
diff --git a/Godeps/_workspace/src/code.google.com/p/go-uuid/uuid/uuid.go b/Godeps/_workspace/src/code.google.com/p/go-uuid/uuid/uuid.go
new file mode 100644
index 000000000..2920fae63
--- /dev/null
+++ b/Godeps/_workspace/src/code.google.com/p/go-uuid/uuid/uuid.go
@@ -0,0 +1,163 @@
+// Copyright 2011 Google Inc. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+package uuid
+
+import (
+ "bytes"
+ "crypto/rand"
+ "fmt"
+ "io"
+ "strings"
+)
+
+// A UUID is a 128 bit (16 byte) Universal Unique IDentifier as defined in RFC
+// 4122.
+type UUID []byte
+
+// A Version represents a UUIDs version.
+type Version byte
+
+// A Variant represents a UUIDs variant.
+type Variant byte
+
+// Constants returned by Variant.
+const (
+ Invalid = Variant(iota) // Invalid UUID
+ RFC4122 // The variant specified in RFC4122
+ Reserved // Reserved, NCS backward compatibility.
+ Microsoft // Reserved, Microsoft Corporation backward compatibility.
+ Future // Reserved for future definition.
+)
+
+var rander = rand.Reader // random function
+
+// New returns a new random (version 4) UUID as a string. It is a convenience
+// function for NewRandom().String().
+func New() string {
+ return NewRandom().String()
+}
+
+// Parse decodes s into a UUID or returns nil. Both the UUID form of
+// xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx and
+// urn:uuid:xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx are decoded.
+func Parse(s string) UUID {
+ if len(s) == 36+9 {
+ if strings.ToLower(s[:9]) != "urn:uuid:" {
+ return nil
+ }
+ s = s[9:]
+ } else if len(s) != 36 {
+ return nil
+ }
+ if s[8] != '-' || s[13] != '-' || s[18] != '-' || s[23] != '-' {
+ return nil
+ }
+ uuid := make([]byte, 16)
+ for i, x := range []int{
+ 0, 2, 4, 6,
+ 9, 11,
+ 14, 16,
+ 19, 21,
+ 24, 26, 28, 30, 32, 34} {
+ if v, ok := xtob(s[x:]); !ok {
+ return nil
+ } else {
+ uuid[i] = v
+ }
+ }
+ return uuid
+}
+
+// Equal returns true if uuid1 and uuid2 are equal.
+func Equal(uuid1, uuid2 UUID) bool {
+ return bytes.Equal(uuid1, uuid2)
+}
+
+// String returns the string form of uuid, xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx
+// , or "" if uuid is invalid.
+func (uuid UUID) String() string {
+ if uuid == nil || len(uuid) != 16 {
+ return ""
+ }
+ b := []byte(uuid)
+ return fmt.Sprintf("%08x-%04x-%04x-%04x-%012x",
+ b[:4], b[4:6], b[6:8], b[8:10], b[10:])
+}
+
+// URN returns the RFC 2141 URN form of uuid,
+// urn:uuid:xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx, or "" if uuid is invalid.
+func (uuid UUID) URN() string {
+ if uuid == nil || len(uuid) != 16 {
+ return ""
+ }
+ b := []byte(uuid)
+ return fmt.Sprintf("urn:uuid:%08x-%04x-%04x-%04x-%012x",
+ b[:4], b[4:6], b[6:8], b[8:10], b[10:])
+}
+
+// Variant returns the variant encoded in uuid. It returns Invalid if
+// uuid is invalid.
+func (uuid UUID) Variant() Variant {
+ if len(uuid) != 16 {
+ return Invalid
+ }
+ switch {
+ case (uuid[8] & 0xc0) == 0x80:
+ return RFC4122
+ case (uuid[8] & 0xe0) == 0xc0:
+ return Microsoft
+ case (uuid[8] & 0xe0) == 0xe0:
+ return Future
+ default:
+ return Reserved
+ }
+ panic("unreachable")
+}
+
+// Version returns the verison of uuid. It returns false if uuid is not
+// valid.
+func (uuid UUID) Version() (Version, bool) {
+ if len(uuid) != 16 {
+ return 0, false
+ }
+ return Version(uuid[6] >> 4), true
+}
+
+func (v Version) String() string {
+ if v > 15 {
+ return fmt.Sprintf("BAD_VERSION_%d", v)
+ }
+ return fmt.Sprintf("VERSION_%d", v)
+}
+
+func (v Variant) String() string {
+ switch v {
+ case RFC4122:
+ return "RFC4122"
+ case Reserved:
+ return "Reserved"
+ case Microsoft:
+ return "Microsoft"
+ case Future:
+ return "Future"
+ case Invalid:
+ return "Invalid"
+ }
+ return fmt.Sprintf("BadVariant%d", int(v))
+}
+
+// SetRand sets the random number generator to r, which implents io.Reader.
+// If r.Read returns an error when the package requests random data then
+// a panic will be issued.
+//
+// Calling SetRand with nil sets the random number generator to the default
+// generator.
+func SetRand(r io.Reader) {
+ if r == nil {
+ rander = rand.Reader
+ return
+ }
+ rander = r
+}
diff --git a/Godeps/_workspace/src/code.google.com/p/go-uuid/uuid/uuid_test.go b/Godeps/_workspace/src/code.google.com/p/go-uuid/uuid/uuid_test.go
new file mode 100644
index 000000000..417ebeb26
--- /dev/null
+++ b/Godeps/_workspace/src/code.google.com/p/go-uuid/uuid/uuid_test.go
@@ -0,0 +1,390 @@
+// Copyright 2011 Google Inc. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+package uuid
+
+import (
+ "bytes"
+ "fmt"
+ "os"
+ "strings"
+ "testing"
+ "time"
+)
+
+type test struct {
+ in string
+ version Version
+ variant Variant
+ isuuid bool
+}
+
+var tests = []test{
+ {"f47ac10b-58cc-0372-8567-0e02b2c3d479", 0, RFC4122, true},
+ {"f47ac10b-58cc-1372-8567-0e02b2c3d479", 1, RFC4122, true},
+ {"f47ac10b-58cc-2372-8567-0e02b2c3d479", 2, RFC4122, true},
+ {"f47ac10b-58cc-3372-8567-0e02b2c3d479", 3, RFC4122, true},
+ {"f47ac10b-58cc-4372-8567-0e02b2c3d479", 4, RFC4122, true},
+ {"f47ac10b-58cc-5372-8567-0e02b2c3d479", 5, RFC4122, true},
+ {"f47ac10b-58cc-6372-8567-0e02b2c3d479", 6, RFC4122, true},
+ {"f47ac10b-58cc-7372-8567-0e02b2c3d479", 7, RFC4122, true},
+ {"f47ac10b-58cc-8372-8567-0e02b2c3d479", 8, RFC4122, true},
+ {"f47ac10b-58cc-9372-8567-0e02b2c3d479", 9, RFC4122, true},
+ {"f47ac10b-58cc-a372-8567-0e02b2c3d479", 10, RFC4122, true},
+ {"f47ac10b-58cc-b372-8567-0e02b2c3d479", 11, RFC4122, true},
+ {"f47ac10b-58cc-c372-8567-0e02b2c3d479", 12, RFC4122, true},
+ {"f47ac10b-58cc-d372-8567-0e02b2c3d479", 13, RFC4122, true},
+ {"f47ac10b-58cc-e372-8567-0e02b2c3d479", 14, RFC4122, true},
+ {"f47ac10b-58cc-f372-8567-0e02b2c3d479", 15, RFC4122, true},
+
+ {"urn:uuid:f47ac10b-58cc-4372-0567-0e02b2c3d479", 4, Reserved, true},
+ {"URN:UUID:f47ac10b-58cc-4372-0567-0e02b2c3d479", 4, Reserved, true},
+ {"f47ac10b-58cc-4372-0567-0e02b2c3d479", 4, Reserved, true},
+ {"f47ac10b-58cc-4372-1567-0e02b2c3d479", 4, Reserved, true},
+ {"f47ac10b-58cc-4372-2567-0e02b2c3d479", 4, Reserved, true},
+ {"f47ac10b-58cc-4372-3567-0e02b2c3d479", 4, Reserved, true},
+ {"f47ac10b-58cc-4372-4567-0e02b2c3d479", 4, Reserved, true},
+ {"f47ac10b-58cc-4372-5567-0e02b2c3d479", 4, Reserved, true},
+ {"f47ac10b-58cc-4372-6567-0e02b2c3d479", 4, Reserved, true},
+ {"f47ac10b-58cc-4372-7567-0e02b2c3d479", 4, Reserved, true},
+ {"f47ac10b-58cc-4372-8567-0e02b2c3d479", 4, RFC4122, true},
+ {"f47ac10b-58cc-4372-9567-0e02b2c3d479", 4, RFC4122, true},
+ {"f47ac10b-58cc-4372-a567-0e02b2c3d479", 4, RFC4122, true},
+ {"f47ac10b-58cc-4372-b567-0e02b2c3d479", 4, RFC4122, true},
+ {"f47ac10b-58cc-4372-c567-0e02b2c3d479", 4, Microsoft, true},
+ {"f47ac10b-58cc-4372-d567-0e02b2c3d479", 4, Microsoft, true},
+ {"f47ac10b-58cc-4372-e567-0e02b2c3d479", 4, Future, true},
+ {"f47ac10b-58cc-4372-f567-0e02b2c3d479", 4, Future, true},
+
+ {"f47ac10b158cc-5372-a567-0e02b2c3d479", 0, Invalid, false},
+ {"f47ac10b-58cc25372-a567-0e02b2c3d479", 0, Invalid, false},
+ {"f47ac10b-58cc-53723a567-0e02b2c3d479", 0, Invalid, false},
+ {"f47ac10b-58cc-5372-a56740e02b2c3d479", 0, Invalid, false},
+ {"f47ac10b-58cc-5372-a567-0e02-2c3d479", 0, Invalid, false},
+ {"g47ac10b-58cc-4372-a567-0e02b2c3d479", 0, Invalid, false},
+}
+
+var constants = []struct {
+ c interface{}
+ name string
+}{
+ {Person, "Person"},
+ {Group, "Group"},
+ {Org, "Org"},
+ {Invalid, "Invalid"},
+ {RFC4122, "RFC4122"},
+ {Reserved, "Reserved"},
+ {Microsoft, "Microsoft"},
+ {Future, "Future"},
+ {Domain(17), "Domain17"},
+ {Variant(42), "BadVariant42"},
+}
+
+func testTest(t *testing.T, in string, tt test) {
+ uuid := Parse(in)
+ if ok := (uuid != nil); ok != tt.isuuid {
+ t.Errorf("Parse(%s) got %v expected %v\b", in, ok, tt.isuuid)
+ }
+ if uuid == nil {
+ return
+ }
+
+ if v := uuid.Variant(); v != tt.variant {
+ t.Errorf("Variant(%s) got %d expected %d\b", in, v, tt.variant)
+ }
+ if v, _ := uuid.Version(); v != tt.version {
+ t.Errorf("Version(%s) got %d expected %d\b", in, v, tt.version)
+ }
+}
+
+func TestUUID(t *testing.T) {
+ for _, tt := range tests {
+ testTest(t, tt.in, tt)
+ testTest(t, strings.ToUpper(tt.in), tt)
+ }
+}
+
+func TestConstants(t *testing.T) {
+ for x, tt := range constants {
+ v, ok := tt.c.(fmt.Stringer)
+ if !ok {
+ t.Errorf("%x: %v: not a stringer", x, v)
+ } else if s := v.String(); s != tt.name {
+ v, _ := tt.c.(int)
+ t.Errorf("%x: Constant %T:%d gives %q, expected %q\n", x, tt.c, v, s, tt.name)
+ }
+ }
+}
+
+func TestRandomUUID(t *testing.T) {
+ m := make(map[string]bool)
+ for x := 1; x < 32; x++ {
+ uuid := NewRandom()
+ s := uuid.String()
+ if m[s] {
+ t.Errorf("NewRandom returned duplicated UUID %s\n", s)
+ }
+ m[s] = true
+ if v, _ := uuid.Version(); v != 4 {
+ t.Errorf("Random UUID of version %s\n", v)
+ }
+ if uuid.Variant() != RFC4122 {
+ t.Errorf("Random UUID is variant %d\n", uuid.Variant())
+ }
+ }
+}
+
+func TestNew(t *testing.T) {
+ m := make(map[string]bool)
+ for x := 1; x < 32; x++ {
+ s := New()
+ if m[s] {
+ t.Errorf("New returned duplicated UUID %s\n", s)
+ }
+ m[s] = true
+ uuid := Parse(s)
+ if uuid == nil {
+ t.Errorf("New returned %q which does not decode\n", s)
+ continue
+ }
+ if v, _ := uuid.Version(); v != 4 {
+ t.Errorf("Random UUID of version %s\n", v)
+ }
+ if uuid.Variant() != RFC4122 {
+ t.Errorf("Random UUID is variant %d\n", uuid.Variant())
+ }
+ }
+}
+
+func clockSeq(t *testing.T, uuid UUID) int {
+ seq, ok := uuid.ClockSequence()
+ if !ok {
+ t.Fatalf("%s: invalid clock sequence\n", uuid)
+ }
+ return seq
+}
+
+func TestClockSeq(t *testing.T) {
+ // Fake time.Now for this test to return a monotonically advancing time; restore it at end.
+ defer func(orig func() time.Time) { timeNow = orig }(timeNow)
+ monTime := time.Now()
+ timeNow = func() time.Time {
+ monTime = monTime.Add(1 * time.Second)
+ return monTime
+ }
+
+ SetClockSequence(-1)
+ uuid1 := NewUUID()
+ uuid2 := NewUUID()
+
+ if clockSeq(t, uuid1) != clockSeq(t, uuid2) {
+ t.Errorf("clock sequence %d != %d\n", clockSeq(t, uuid1), clockSeq(t, uuid2))
+ }
+
+ SetClockSequence(-1)
+ uuid2 = NewUUID()
+
+ // Just on the very off chance we generated the same sequence
+ // two times we try again.
+ if clockSeq(t, uuid1) == clockSeq(t, uuid2) {
+ SetClockSequence(-1)
+ uuid2 = NewUUID()
+ }
+ if clockSeq(t, uuid1) == clockSeq(t, uuid2) {
+ t.Errorf("Duplicate clock sequence %d\n", clockSeq(t, uuid1))
+ }
+
+ SetClockSequence(0x1234)
+ uuid1 = NewUUID()
+ if seq := clockSeq(t, uuid1); seq != 0x1234 {
+ t.Errorf("%s: expected seq 0x1234 got 0x%04x\n", uuid1, seq)
+ }
+}
+
+func TestCoding(t *testing.T) {
+ text := "7d444840-9dc0-11d1-b245-5ffdce74fad2"
+ urn := "urn:uuid:7d444840-9dc0-11d1-b245-5ffdce74fad2"
+ data := UUID{
+ 0x7d, 0x44, 0x48, 0x40,
+ 0x9d, 0xc0,
+ 0x11, 0xd1,
+ 0xb2, 0x45,
+ 0x5f, 0xfd, 0xce, 0x74, 0xfa, 0xd2,
+ }
+ if v := data.String(); v != text {
+ t.Errorf("%x: encoded to %s, expected %s\n", data, v, text)
+ }
+ if v := data.URN(); v != urn {
+ t.Errorf("%x: urn is %s, expected %s\n", data, v, urn)
+ }
+
+ uuid := Parse(text)
+ if !Equal(uuid, data) {
+ t.Errorf("%s: decoded to %s, expected %s\n", text, uuid, data)
+ }
+}
+
+func TestVersion1(t *testing.T) {
+ uuid1 := NewUUID()
+ uuid2 := NewUUID()
+
+ if Equal(uuid1, uuid2) {
+ t.Errorf("%s:duplicate uuid\n", uuid1)
+ }
+ if v, _ := uuid1.Version(); v != 1 {
+ t.Errorf("%s: version %s expected 1\n", uuid1, v)
+ }
+ if v, _ := uuid2.Version(); v != 1 {
+ t.Errorf("%s: version %s expected 1\n", uuid2, v)
+ }
+ n1 := uuid1.NodeID()
+ n2 := uuid2.NodeID()
+ if !bytes.Equal(n1, n2) {
+ t.Errorf("Different nodes %x != %x\n", n1, n2)
+ }
+ t1, ok := uuid1.Time()
+ if !ok {
+ t.Errorf("%s: invalid time\n", uuid1)
+ }
+ t2, ok := uuid2.Time()
+ if !ok {
+ t.Errorf("%s: invalid time\n", uuid2)
+ }
+ q1, ok := uuid1.ClockSequence()
+ if !ok {
+ t.Errorf("%s: invalid clock sequence\n", uuid1)
+ }
+ q2, ok := uuid2.ClockSequence()
+ if !ok {
+ t.Errorf("%s: invalid clock sequence", uuid2)
+ }
+
+ switch {
+ case t1 == t2 && q1 == q2:
+ t.Errorf("time stopped\n")
+ case t1 > t2 && q1 == q2:
+ t.Errorf("time reversed\n")
+ case t1 < t2 && q1 != q2:
+ t.Errorf("clock sequence chaned unexpectedly\n")
+ }
+}
+
+func TestNodeAndTime(t *testing.T) {
+ // Time is February 5, 1998 12:30:23.136364800 AM GMT
+
+ uuid := Parse("7d444840-9dc0-11d1-b245-5ffdce74fad2")
+ node := []byte{0x5f, 0xfd, 0xce, 0x74, 0xfa, 0xd2}
+
+ ts, ok := uuid.Time()
+ if ok {
+ c := time.Unix(ts.UnixTime())
+ want := time.Date(1998, 2, 5, 0, 30, 23, 136364800, time.UTC)
+ if !c.Equal(want) {
+ t.Errorf("Got time %v, want %v", c, want)
+ }
+ } else {
+ t.Errorf("%s: bad time\n", uuid)
+ }
+ if !bytes.Equal(node, uuid.NodeID()) {
+ t.Errorf("Expected node %v got %v\n", node, uuid.NodeID())
+ }
+}
+
+func TestMD5(t *testing.T) {
+ uuid := NewMD5(NameSpace_DNS, []byte("python.org")).String()
+ want := "6fa459ea-ee8a-3ca4-894e-db77e160355e"
+ if uuid != want {
+ t.Errorf("MD5: got %q expected %q\n", uuid, want)
+ }
+}
+
+func TestSHA1(t *testing.T) {
+ uuid := NewSHA1(NameSpace_DNS, []byte("python.org")).String()
+ want := "886313e1-3b8a-5372-9b90-0c9aee199e5d"
+ if uuid != want {
+ t.Errorf("SHA1: got %q expected %q\n", uuid, want)
+ }
+}
+
+func TestNodeID(t *testing.T) {
+ nid := []byte{1, 2, 3, 4, 5, 6}
+ SetNodeInterface("")
+ s := NodeInterface()
+ if s == "" || s == "user" {
+ t.Errorf("NodeInterface %q after SetInteface\n", s)
+ }
+ node1 := NodeID()
+ if node1 == nil {
+ t.Errorf("NodeID nil after SetNodeInterface\n", s)
+ }
+ SetNodeID(nid)
+ s = NodeInterface()
+ if s != "user" {
+ t.Errorf("Expected NodeInterface %q got %q\n", "user", s)
+ }
+ node2 := NodeID()
+ if node2 == nil {
+ t.Errorf("NodeID nil after SetNodeID\n", s)
+ }
+ if bytes.Equal(node1, node2) {
+ t.Errorf("NodeID not changed after SetNodeID\n", s)
+ } else if !bytes.Equal(nid, node2) {
+ t.Errorf("NodeID is %x, expected %x\n", node2, nid)
+ }
+}
+
+func testDCE(t *testing.T, name string, uuid UUID, domain Domain, id uint32) {
+ if uuid == nil {
+ t.Errorf("%s failed\n", name)
+ return
+ }
+ if v, _ := uuid.Version(); v != 2 {
+ t.Errorf("%s: %s: expected version 2, got %s\n", name, uuid, v)
+ return
+ }
+ if v, ok := uuid.Domain(); !ok || v != domain {
+ if !ok {
+ t.Errorf("%s: %d: Domain failed\n", name, uuid)
+ } else {
+ t.Errorf("%s: %s: expected domain %d, got %d\n", name, uuid, domain, v)
+ }
+ }
+ if v, ok := uuid.Id(); !ok || v != id {
+ if !ok {
+ t.Errorf("%s: %d: Id failed\n", name, uuid)
+ } else {
+ t.Errorf("%s: %s: expected id %d, got %d\n", name, uuid, id, v)
+ }
+ }
+}
+
+func TestDCE(t *testing.T) {
+ testDCE(t, "NewDCESecurity", NewDCESecurity(42, 12345678), 42, 12345678)
+ testDCE(t, "NewDCEPerson", NewDCEPerson(), Person, uint32(os.Getuid()))
+ testDCE(t, "NewDCEGroup", NewDCEGroup(), Group, uint32(os.Getgid()))
+}
+
+type badRand struct{}
+
+func (r badRand) Read(buf []byte) (int, error) {
+ for i, _ := range buf {
+ buf[i] = byte(i)
+ }
+ return len(buf), nil
+}
+
+func TestBadRand(t *testing.T) {
+ SetRand(badRand{})
+ uuid1 := New()
+ uuid2 := New()
+ if uuid1 != uuid2 {
+ t.Errorf("execpted duplicates, got %q and %q\n", uuid1, uuid2)
+ }
+ SetRand(nil)
+ uuid1 = New()
+ uuid2 = New()
+ if uuid1 == uuid2 {
+ t.Errorf("unexecpted duplicates, got %q\n", uuid1)
+ }
+}
diff --git a/Godeps/_workspace/src/code.google.com/p/go-uuid/uuid/version1.go b/Godeps/_workspace/src/code.google.com/p/go-uuid/uuid/version1.go
new file mode 100644
index 000000000..63580044b
--- /dev/null
+++ b/Godeps/_workspace/src/code.google.com/p/go-uuid/uuid/version1.go
@@ -0,0 +1,41 @@
+// Copyright 2011 Google Inc. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+package uuid
+
+import (
+ "encoding/binary"
+)
+
+// NewUUID returns a Version 1 UUID based on the current NodeID and clock
+// sequence, and the current time. If the NodeID has not been set by SetNodeID
+// or SetNodeInterface then it will be set automatically. If the NodeID cannot
+// be set NewUUID returns nil. If clock sequence has not been set by
+// SetClockSequence then it will be set automatically. If GetTime fails to
+// return the current NewUUID returns nil.
+func NewUUID() UUID {
+ if nodeID == nil {
+ SetNodeInterface("")
+ }
+
+ now, err := GetTime()
+ if err != nil {
+ return nil
+ }
+
+ uuid := make([]byte, 16)
+
+ time_low := uint32(now & 0xffffffff)
+ time_mid := uint16((now >> 32) & 0xffff)
+ time_hi := uint16((now >> 48) & 0x0fff)
+ time_hi |= 0x1000 // Version 1
+
+ binary.BigEndian.PutUint32(uuid[0:], time_low)
+ binary.BigEndian.PutUint16(uuid[4:], time_mid)
+ binary.BigEndian.PutUint16(uuid[6:], time_hi)
+ binary.BigEndian.PutUint16(uuid[8:], clock_seq)
+ copy(uuid[10:], nodeID)
+
+ return uuid
+}
diff --git a/Godeps/_workspace/src/code.google.com/p/go-uuid/uuid/version4.go b/Godeps/_workspace/src/code.google.com/p/go-uuid/uuid/version4.go
new file mode 100644
index 000000000..b3d4a368d
--- /dev/null
+++ b/Godeps/_workspace/src/code.google.com/p/go-uuid/uuid/version4.go
@@ -0,0 +1,25 @@
+// Copyright 2011 Google Inc. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+package uuid
+
+// Random returns a Random (Version 4) UUID or panics.
+//
+// The strength of the UUIDs is based on the strength of the crypto/rand
+// package.
+//
+// A note about uniqueness derived from from the UUID Wikipedia entry:
+//
+// Randomly generated UUIDs have 122 random bits. One's annual risk of being
+// hit by a meteorite is estimated to be one chance in 17 billion, that
+// means the probability is about 0.00000000006 (6 × 10−11),
+// equivalent to the odds of creating a few tens of trillions of UUIDs in a
+// year and having one duplicate.
+func NewRandom() UUID {
+ uuid := make([]byte, 16)
+ randomBits([]byte(uuid))
+ uuid[6] = (uuid[6] & 0x0f) | 0x40 // Version 4
+ uuid[8] = (uuid[8] & 0x3f) | 0x80 // Variant is 10
+ return uuid
+}
diff --git a/Godeps/_workspace/src/code.google.com/p/snappy-go/snappy/decode.go b/Godeps/_workspace/src/code.google.com/p/snappy-go/snappy/decode.go
new file mode 100644
index 000000000..d93c1b9db
--- /dev/null
+++ b/Godeps/_workspace/src/code.google.com/p/snappy-go/snappy/decode.go
@@ -0,0 +1,124 @@
+// Copyright 2011 The Snappy-Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+package snappy
+
+import (
+ "encoding/binary"
+ "errors"
+)
+
+// ErrCorrupt reports that the input is invalid.
+var ErrCorrupt = errors.New("snappy: corrupt input")
+
+// DecodedLen returns the length of the decoded block.
+func DecodedLen(src []byte) (int, error) {
+ v, _, err := decodedLen(src)
+ return v, err
+}
+
+// decodedLen returns the length of the decoded block and the number of bytes
+// that the length header occupied.
+func decodedLen(src []byte) (blockLen, headerLen int, err error) {
+ v, n := binary.Uvarint(src)
+ if n == 0 {
+ return 0, 0, ErrCorrupt
+ }
+ if uint64(int(v)) != v {
+ return 0, 0, errors.New("snappy: decoded block is too large")
+ }
+ return int(v), n, nil
+}
+
+// Decode returns the decoded form of src. The returned slice may be a sub-
+// slice of dst if dst was large enough to hold the entire decoded block.
+// Otherwise, a newly allocated slice will be returned.
+// It is valid to pass a nil dst.
+func Decode(dst, src []byte) ([]byte, error) {
+ dLen, s, err := decodedLen(src)
+ if err != nil {
+ return nil, err
+ }
+ if len(dst) < dLen {
+ dst = make([]byte, dLen)
+ }
+
+ var d, offset, length int
+ for s < len(src) {
+ switch src[s] & 0x03 {
+ case tagLiteral:
+ x := uint(src[s] >> 2)
+ switch {
+ case x < 60:
+ s += 1
+ case x == 60:
+ s += 2
+ if s > len(src) {
+ return nil, ErrCorrupt
+ }
+ x = uint(src[s-1])
+ case x == 61:
+ s += 3
+ if s > len(src) {
+ return nil, ErrCorrupt
+ }
+ x = uint(src[s-2]) | uint(src[s-1])<<8
+ case x == 62:
+ s += 4
+ if s > len(src) {
+ return nil, ErrCorrupt
+ }
+ x = uint(src[s-3]) | uint(src[s-2])<<8 | uint(src[s-1])<<16
+ case x == 63:
+ s += 5
+ if s > len(src) {
+ return nil, ErrCorrupt
+ }
+ x = uint(src[s-4]) | uint(src[s-3])<<8 | uint(src[s-2])<<16 | uint(src[s-1])<<24
+ }
+ length = int(x + 1)
+ if length <= 0 {
+ return nil, errors.New("snappy: unsupported literal length")
+ }
+ if length > len(dst)-d || length > len(src)-s {
+ return nil, ErrCorrupt
+ }
+ copy(dst[d:], src[s:s+length])
+ d += length
+ s += length
+ continue
+
+ case tagCopy1:
+ s += 2
+ if s > len(src) {
+ return nil, ErrCorrupt
+ }
+ length = 4 + int(src[s-2])>>2&0x7
+ offset = int(src[s-2])&0xe0<<3 | int(src[s-1])
+
+ case tagCopy2:
+ s += 3
+ if s > len(src) {
+ return nil, ErrCorrupt
+ }
+ length = 1 + int(src[s-3])>>2
+ offset = int(src[s-2]) | int(src[s-1])<<8
+
+ case tagCopy4:
+ return nil, errors.New("snappy: unsupported COPY_4 tag")
+ }
+
+ end := d + length
+ if offset > d || end > len(dst) {
+ return nil, ErrCorrupt
+ }
+ for ; d < end; d++ {
+ dst[d] = dst[d-offset]
+ }
+ }
+ if d != dLen {
+ return nil, ErrCorrupt
+ }
+ return dst[:d], nil
+}
diff --git a/Godeps/_workspace/src/code.google.com/p/snappy-go/snappy/encode.go b/Godeps/_workspace/src/code.google.com/p/snappy-go/snappy/encode.go
new file mode 100644
index 000000000..b2371db11
--- /dev/null
+++ b/Godeps/_workspace/src/code.google.com/p/snappy-go/snappy/encode.go
@@ -0,0 +1,174 @@
+// Copyright 2011 The Snappy-Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+package snappy
+
+import (
+ "encoding/binary"
+)
+
+// We limit how far copy back-references can go, the same as the C++ code.
+const maxOffset = 1 << 15
+
+// emitLiteral writes a literal chunk and returns the number of bytes written.
+func emitLiteral(dst, lit []byte) int {
+ i, n := 0, uint(len(lit)-1)
+ switch {
+ case n < 60:
+ dst[0] = uint8(n)<<2 | tagLiteral
+ i = 1
+ case n < 1<<8:
+ dst[0] = 60<<2 | tagLiteral
+ dst[1] = uint8(n)
+ i = 2
+ case n < 1<<16:
+ dst[0] = 61<<2 | tagLiteral
+ dst[1] = uint8(n)
+ dst[2] = uint8(n >> 8)
+ i = 3
+ case n < 1<<24:
+ dst[0] = 62<<2 | tagLiteral
+ dst[1] = uint8(n)
+ dst[2] = uint8(n >> 8)
+ dst[3] = uint8(n >> 16)
+ i = 4
+ case int64(n) < 1<<32:
+ dst[0] = 63<<2 | tagLiteral
+ dst[1] = uint8(n)
+ dst[2] = uint8(n >> 8)
+ dst[3] = uint8(n >> 16)
+ dst[4] = uint8(n >> 24)
+ i = 5
+ default:
+ panic("snappy: source buffer is too long")
+ }
+ if copy(dst[i:], lit) != len(lit) {
+ panic("snappy: destination buffer is too short")
+ }
+ return i + len(lit)
+}
+
+// emitCopy writes a copy chunk and returns the number of bytes written.
+func emitCopy(dst []byte, offset, length int) int {
+ i := 0
+ for length > 0 {
+ x := length - 4
+ if 0 <= x && x < 1<<3 && offset < 1<<11 {
+ dst[i+0] = uint8(offset>>8)&0x07<<5 | uint8(x)<<2 | tagCopy1
+ dst[i+1] = uint8(offset)
+ i += 2
+ break
+ }
+
+ x = length
+ if x > 1<<6 {
+ x = 1 << 6
+ }
+ dst[i+0] = uint8(x-1)<<2 | tagCopy2
+ dst[i+1] = uint8(offset)
+ dst[i+2] = uint8(offset >> 8)
+ i += 3
+ length -= x
+ }
+ return i
+}
+
+// Encode returns the encoded form of src. The returned slice may be a sub-
+// slice of dst if dst was large enough to hold the entire encoded block.
+// Otherwise, a newly allocated slice will be returned.
+// It is valid to pass a nil dst.
+func Encode(dst, src []byte) ([]byte, error) {
+ if n := MaxEncodedLen(len(src)); len(dst) < n {
+ dst = make([]byte, n)
+ }
+
+ // The block starts with the varint-encoded length of the decompressed bytes.
+ d := binary.PutUvarint(dst, uint64(len(src)))
+
+ // Return early if src is short.
+ if len(src) <= 4 {
+ if len(src) != 0 {
+ d += emitLiteral(dst[d:], src)
+ }
+ return dst[:d], nil
+ }
+
+ // Initialize the hash table. Its size ranges from 1<<8 to 1<<14 inclusive.
+ const maxTableSize = 1 << 14
+ shift, tableSize := uint(32-8), 1<<8
+ for tableSize < maxTableSize && tableSize < len(src) {
+ shift--
+ tableSize *= 2
+ }
+ var table [maxTableSize]int
+
+ // Iterate over the source bytes.
+ var (
+ s int // The iterator position.
+ t int // The last position with the same hash as s.
+ lit int // The start position of any pending literal bytes.
+ )
+ for s+3 < len(src) {
+ // Update the hash table.
+ b0, b1, b2, b3 := src[s], src[s+1], src[s+2], src[s+3]
+ h := uint32(b0) | uint32(b1)<<8 | uint32(b2)<<16 | uint32(b3)<<24
+ p := &table[(h*0x1e35a7bd)>>shift]
+ // We need to to store values in [-1, inf) in table. To save
+ // some initialization time, (re)use the table's zero value
+ // and shift the values against this zero: add 1 on writes,
+ // subtract 1 on reads.
+ t, *p = *p-1, s+1
+ // If t is invalid or src[s:s+4] differs from src[t:t+4], accumulate a literal byte.
+ if t < 0 || s-t >= maxOffset || b0 != src[t] || b1 != src[t+1] || b2 != src[t+2] || b3 != src[t+3] {
+ s++
+ continue
+ }
+ // Otherwise, we have a match. First, emit any pending literal bytes.
+ if lit != s {
+ d += emitLiteral(dst[d:], src[lit:s])
+ }
+ // Extend the match to be as long as possible.
+ s0 := s
+ s, t = s+4, t+4
+ for s < len(src) && src[s] == src[t] {
+ s++
+ t++
+ }
+ // Emit the copied bytes.
+ d += emitCopy(dst[d:], s-t, s-s0)
+ lit = s
+ }
+
+ // Emit any final pending literal bytes and return.
+ if lit != len(src) {
+ d += emitLiteral(dst[d:], src[lit:])
+ }
+ return dst[:d], nil
+}
+
+// MaxEncodedLen returns the maximum length of a snappy block, given its
+// uncompressed length.
+func MaxEncodedLen(srcLen int) int {
+ // Compressed data can be defined as:
+ // compressed := item* literal*
+ // item := literal* copy
+ //
+ // The trailing literal sequence has a space blowup of at most 62/60
+ // since a literal of length 60 needs one tag byte + one extra byte
+ // for length information.
+ //
+ // Item blowup is trickier to measure. Suppose the "copy" op copies
+ // 4 bytes of data. Because of a special check in the encoding code,
+ // we produce a 4-byte copy only if the offset is < 65536. Therefore
+ // the copy op takes 3 bytes to encode, and this type of item leads
+ // to at most the 62/60 blowup for representing literals.
+ //
+ // Suppose the "copy" op copies 5 bytes of data. If the offset is big
+ // enough, it will take 5 bytes to encode the copy op. Therefore the
+ // worst case here is a one-byte literal followed by a five-byte copy.
+ // That is, 6 bytes of input turn into 7 bytes of "compressed" data.
+ //
+ // This last factor dominates the blowup, so the final estimate is:
+ return 32 + srcLen + srcLen/6
+}
diff --git a/Godeps/_workspace/src/code.google.com/p/snappy-go/snappy/snappy.go b/Godeps/_workspace/src/code.google.com/p/snappy-go/snappy/snappy.go
new file mode 100644
index 000000000..2f1b790d0
--- /dev/null
+++ b/Godeps/_workspace/src/code.google.com/p/snappy-go/snappy/snappy.go
@@ -0,0 +1,38 @@
+// Copyright 2011 The Snappy-Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Package snappy implements the snappy block-based compression format.
+// It aims for very high speeds and reasonable compression.
+//
+// The C++ snappy implementation is at http://code.google.com/p/snappy/
+package snappy
+
+/*
+Each encoded block begins with the varint-encoded length of the decoded data,
+followed by a sequence of chunks. Chunks begin and end on byte boundaries. The
+first byte of each chunk is broken into its 2 least and 6 most significant bits
+called l and m: l ranges in [0, 4) and m ranges in [0, 64). l is the chunk tag.
+Zero means a literal tag. All other values mean a copy tag.
+
+For literal tags:
+ - If m < 60, the next 1 + m bytes are literal bytes.
+ - Otherwise, let n be the little-endian unsigned integer denoted by the next
+ m - 59 bytes. The next 1 + n bytes after that are literal bytes.
+
+For copy tags, length bytes are copied from offset bytes ago, in the style of
+Lempel-Ziv compression algorithms. In particular:
+ - For l == 1, the offset ranges in [0, 1<<11) and the length in [4, 12).
+ The length is 4 + the low 3 bits of m. The high 3 bits of m form bits 8-10
+ of the offset. The next byte is bits 0-7 of the offset.
+ - For l == 2, the offset ranges in [0, 1<<16) and the length in [1, 65).
+ The length is 1 + m. The offset is the little-endian unsigned integer
+ denoted by the next 2 bytes.
+ - For l == 3, this tag is a legacy format that is no longer supported.
+*/
+const (
+ tagLiteral = 0x00
+ tagCopy1 = 0x01
+ tagCopy2 = 0x02
+ tagCopy4 = 0x03
+)
diff --git a/Godeps/_workspace/src/code.google.com/p/snappy-go/snappy/snappy_test.go b/Godeps/_workspace/src/code.google.com/p/snappy-go/snappy/snappy_test.go
new file mode 100644
index 000000000..7ba839244
--- /dev/null
+++ b/Godeps/_workspace/src/code.google.com/p/snappy-go/snappy/snappy_test.go
@@ -0,0 +1,261 @@
+// Copyright 2011 The Snappy-Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+package snappy
+
+import (
+ "bytes"
+ "flag"
+ "fmt"
+ "io"
+ "io/ioutil"
+ "math/rand"
+ "net/http"
+ "os"
+ "path/filepath"
+ "strings"
+ "testing"
+)
+
+var download = flag.Bool("download", false, "If true, download any missing files before running benchmarks")
+
+func roundtrip(b, ebuf, dbuf []byte) error {
+ e, err := Encode(ebuf, b)
+ if err != nil {
+ return fmt.Errorf("encoding error: %v", err)
+ }
+ d, err := Decode(dbuf, e)
+ if err != nil {
+ return fmt.Errorf("decoding error: %v", err)
+ }
+ if !bytes.Equal(b, d) {
+ return fmt.Errorf("roundtrip mismatch:\n\twant %v\n\tgot %v", b, d)
+ }
+ return nil
+}
+
+func TestEmpty(t *testing.T) {
+ if err := roundtrip(nil, nil, nil); err != nil {
+ t.Fatal(err)
+ }
+}
+
+func TestSmallCopy(t *testing.T) {
+ for _, ebuf := range [][]byte{nil, make([]byte, 20), make([]byte, 64)} {
+ for _, dbuf := range [][]byte{nil, make([]byte, 20), make([]byte, 64)} {
+ for i := 0; i < 32; i++ {
+ s := "aaaa" + strings.Repeat("b", i) + "aaaabbbb"
+ if err := roundtrip([]byte(s), ebuf, dbuf); err != nil {
+ t.Errorf("len(ebuf)=%d, len(dbuf)=%d, i=%d: %v", len(ebuf), len(dbuf), i, err)
+ }
+ }
+ }
+ }
+}
+
+func TestSmallRand(t *testing.T) {
+ rand.Seed(27354294)
+ for n := 1; n < 20000; n += 23 {
+ b := make([]byte, n)
+ for i, _ := range b {
+ b[i] = uint8(rand.Uint32())
+ }
+ if err := roundtrip(b, nil, nil); err != nil {
+ t.Fatal(err)
+ }
+ }
+}
+
+func TestSmallRegular(t *testing.T) {
+ for n := 1; n < 20000; n += 23 {
+ b := make([]byte, n)
+ for i, _ := range b {
+ b[i] = uint8(i%10 + 'a')
+ }
+ if err := roundtrip(b, nil, nil); err != nil {
+ t.Fatal(err)
+ }
+ }
+}
+
+func benchDecode(b *testing.B, src []byte) {
+ encoded, err := Encode(nil, src)
+ if err != nil {
+ b.Fatal(err)
+ }
+ // Bandwidth is in amount of uncompressed data.
+ b.SetBytes(int64(len(src)))
+ b.ResetTimer()
+ for i := 0; i < b.N; i++ {
+ Decode(src, encoded)
+ }
+}
+
+func benchEncode(b *testing.B, src []byte) {
+ // Bandwidth is in amount of uncompressed data.
+ b.SetBytes(int64(len(src)))
+ dst := make([]byte, MaxEncodedLen(len(src)))
+ b.ResetTimer()
+ for i := 0; i < b.N; i++ {
+ Encode(dst, src)
+ }
+}
+
+func readFile(b *testing.B, filename string) []byte {
+ src, err := ioutil.ReadFile(filename)
+ if err != nil {
+ b.Fatalf("failed reading %s: %s", filename, err)
+ }
+ if len(src) == 0 {
+ b.Fatalf("%s has zero length", filename)
+ }
+ return src
+}
+
+// expand returns a slice of length n containing repeated copies of src.
+func expand(src []byte, n int) []byte {
+ dst := make([]byte, n)
+ for x := dst; len(x) > 0; {
+ i := copy(x, src)
+ x = x[i:]
+ }
+ return dst
+}
+
+func benchWords(b *testing.B, n int, decode bool) {
+ // Note: the file is OS-language dependent so the resulting values are not
+ // directly comparable for non-US-English OS installations.
+ data := expand(readFile(b, "/usr/share/dict/words"), n)
+ if decode {
+ benchDecode(b, data)
+ } else {
+ benchEncode(b, data)
+ }
+}
+
+func BenchmarkWordsDecode1e3(b *testing.B) { benchWords(b, 1e3, true) }
+func BenchmarkWordsDecode1e4(b *testing.B) { benchWords(b, 1e4, true) }
+func BenchmarkWordsDecode1e5(b *testing.B) { benchWords(b, 1e5, true) }
+func BenchmarkWordsDecode1e6(b *testing.B) { benchWords(b, 1e6, true) }
+func BenchmarkWordsEncode1e3(b *testing.B) { benchWords(b, 1e3, false) }
+func BenchmarkWordsEncode1e4(b *testing.B) { benchWords(b, 1e4, false) }
+func BenchmarkWordsEncode1e5(b *testing.B) { benchWords(b, 1e5, false) }
+func BenchmarkWordsEncode1e6(b *testing.B) { benchWords(b, 1e6, false) }
+
+// testFiles' values are copied directly from
+// https://code.google.com/p/snappy/source/browse/trunk/snappy_unittest.cc.
+// The label field is unused in snappy-go.
+var testFiles = []struct {
+ label string
+ filename string
+}{
+ {"html", "html"},
+ {"urls", "urls.10K"},
+ {"jpg", "house.jpg"},
+ {"pdf", "mapreduce-osdi-1.pdf"},
+ {"html4", "html_x_4"},
+ {"cp", "cp.html"},
+ {"c", "fields.c"},
+ {"lsp", "grammar.lsp"},
+ {"xls", "kennedy.xls"},
+ {"txt1", "alice29.txt"},
+ {"txt2", "asyoulik.txt"},
+ {"txt3", "lcet10.txt"},
+ {"txt4", "plrabn12.txt"},
+ {"bin", "ptt5"},
+ {"sum", "sum"},
+ {"man", "xargs.1"},
+ {"pb", "geo.protodata"},
+ {"gaviota", "kppkn.gtb"},
+}
+
+// The test data files are present at this canonical URL.
+const baseURL = "https://snappy.googlecode.com/svn/trunk/testdata/"
+
+func downloadTestdata(basename string) (errRet error) {
+ filename := filepath.Join("testdata", basename)
+ f, err := os.Create(filename)
+ if err != nil {
+ return fmt.Errorf("failed to create %s: %s", filename, err)
+ }
+ defer f.Close()
+ defer func() {
+ if errRet != nil {
+ os.Remove(filename)
+ }
+ }()
+ resp, err := http.Get(baseURL + basename)
+ if err != nil {
+ return fmt.Errorf("failed to download %s: %s", baseURL+basename, err)
+ }
+ defer resp.Body.Close()
+ _, err = io.Copy(f, resp.Body)
+ if err != nil {
+ return fmt.Errorf("failed to write %s: %s", filename, err)
+ }
+ return nil
+}
+
+func benchFile(b *testing.B, n int, decode bool) {
+ filename := filepath.Join("testdata", testFiles[n].filename)
+ if stat, err := os.Stat(filename); err != nil || stat.Size() == 0 {
+ if !*download {
+ b.Fatal("test data not found; skipping benchmark without the -download flag")
+ }
+ // Download the official snappy C++ implementation reference test data
+ // files for benchmarking.
+ if err := os.Mkdir("testdata", 0777); err != nil && !os.IsExist(err) {
+ b.Fatalf("failed to create testdata: %s", err)
+ }
+ for _, tf := range testFiles {
+ if err := downloadTestdata(tf.filename); err != nil {
+ b.Fatalf("failed to download testdata: %s", err)
+ }
+ }
+ }
+ data := readFile(b, filename)
+ if decode {
+ benchDecode(b, data)
+ } else {
+ benchEncode(b, data)
+ }
+}
+
+// Naming convention is kept similar to what snappy's C++ implementation uses.
+func Benchmark_UFlat0(b *testing.B) { benchFile(b, 0, true) }
+func Benchmark_UFlat1(b *testing.B) { benchFile(b, 1, true) }
+func Benchmark_UFlat2(b *testing.B) { benchFile(b, 2, true) }
+func Benchmark_UFlat3(b *testing.B) { benchFile(b, 3, true) }
+func Benchmark_UFlat4(b *testing.B) { benchFile(b, 4, true) }
+func Benchmark_UFlat5(b *testing.B) { benchFile(b, 5, true) }
+func Benchmark_UFlat6(b *testing.B) { benchFile(b, 6, true) }
+func Benchmark_UFlat7(b *testing.B) { benchFile(b, 7, true) }
+func Benchmark_UFlat8(b *testing.B) { benchFile(b, 8, true) }
+func Benchmark_UFlat9(b *testing.B) { benchFile(b, 9, true) }
+func Benchmark_UFlat10(b *testing.B) { benchFile(b, 10, true) }
+func Benchmark_UFlat11(b *testing.B) { benchFile(b, 11, true) }
+func Benchmark_UFlat12(b *testing.B) { benchFile(b, 12, true) }
+func Benchmark_UFlat13(b *testing.B) { benchFile(b, 13, true) }
+func Benchmark_UFlat14(b *testing.B) { benchFile(b, 14, true) }
+func Benchmark_UFlat15(b *testing.B) { benchFile(b, 15, true) }
+func Benchmark_UFlat16(b *testing.B) { benchFile(b, 16, true) }
+func Benchmark_UFlat17(b *testing.B) { benchFile(b, 17, true) }
+func Benchmark_ZFlat0(b *testing.B) { benchFile(b, 0, false) }
+func Benchmark_ZFlat1(b *testing.B) { benchFile(b, 1, false) }
+func Benchmark_ZFlat2(b *testing.B) { benchFile(b, 2, false) }
+func Benchmark_ZFlat3(b *testing.B) { benchFile(b, 3, false) }
+func Benchmark_ZFlat4(b *testing.B) { benchFile(b, 4, false) }
+func Benchmark_ZFlat5(b *testing.B) { benchFile(b, 5, false) }
+func Benchmark_ZFlat6(b *testing.B) { benchFile(b, 6, false) }
+func Benchmark_ZFlat7(b *testing.B) { benchFile(b, 7, false) }
+func Benchmark_ZFlat8(b *testing.B) { benchFile(b, 8, false) }
+func Benchmark_ZFlat9(b *testing.B) { benchFile(b, 9, false) }
+func Benchmark_ZFlat10(b *testing.B) { benchFile(b, 10, false) }
+func Benchmark_ZFlat11(b *testing.B) { benchFile(b, 11, false) }
+func Benchmark_ZFlat12(b *testing.B) { benchFile(b, 12, false) }
+func Benchmark_ZFlat13(b *testing.B) { benchFile(b, 13, false) }
+func Benchmark_ZFlat14(b *testing.B) { benchFile(b, 14, false) }
+func Benchmark_ZFlat15(b *testing.B) { benchFile(b, 15, false) }
+func Benchmark_ZFlat16(b *testing.B) { benchFile(b, 16, false) }
+func Benchmark_ZFlat17(b *testing.B) { benchFile(b, 17, false) }
diff --git a/Godeps/_workspace/src/github.com/codegangsta/cli/.travis.yml b/Godeps/_workspace/src/github.com/codegangsta/cli/.travis.yml
new file mode 100644
index 000000000..baf46abc6
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/codegangsta/cli/.travis.yml
@@ -0,0 +1,6 @@
+language: go
+go: 1.1
+
+script:
+- go vet ./...
+- go test -v ./...
diff --git a/Godeps/_workspace/src/github.com/codegangsta/cli/LICENSE b/Godeps/_workspace/src/github.com/codegangsta/cli/LICENSE
new file mode 100644
index 000000000..5515ccfb7
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/codegangsta/cli/LICENSE
@@ -0,0 +1,21 @@
+Copyright (C) 2013 Jeremy Saenz
+All Rights Reserved.
+
+MIT LICENSE
+
+Permission is hereby granted, free of charge, to any person obtaining a copy of
+this software and associated documentation files (the "Software"), to deal in
+the Software without restriction, including without limitation the rights to
+use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
+the Software, and to permit persons to whom the Software is furnished to do so,
+subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in all
+copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
+FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
+COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
+IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
+CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
diff --git a/Godeps/_workspace/src/github.com/codegangsta/cli/README.md b/Godeps/_workspace/src/github.com/codegangsta/cli/README.md
new file mode 100644
index 000000000..4b3ddb0a3
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/codegangsta/cli/README.md
@@ -0,0 +1,298 @@
+[![Build Status](https://travis-ci.org/codegangsta/cli.png?branch=master)](https://travis-ci.org/codegangsta/cli)
+
+# cli.go
+cli.go is simple, fast, and fun package for building command line apps in Go. The goal is to enable developers to write fast and distributable command line applications in an expressive way.
+
+You can view the API docs here:
+http://godoc.org/github.com/codegangsta/cli
+
+## Overview
+Command line apps are usually so tiny that there is absolutely no reason why your code should *not* be self-documenting. Things like generating help text and parsing command flags/options should not hinder productivity when writing a command line app.
+
+**This is where cli.go comes into play.** cli.go makes command line programming fun, organized, and expressive!
+
+## Installation
+Make sure you have a working Go environment (go 1.1 is *required*). [See the install instructions](http://golang.org/doc/install.html).
+
+To install `cli.go`, simply run:
+```
+$ go get github.com/codegangsta/cli
+```
+
+Make sure your `PATH` includes to the `$GOPATH/bin` directory so your commands can be easily used:
+```
+export PATH=$PATH:$GOPATH/bin
+```
+
+## Getting Started
+One of the philosophies behind cli.go is that an API should be playful and full of discovery. So a cli.go app can be as little as one line of code in `main()`.
+
+``` go
+package main
+
+import (
+ "os"
+ "github.com/codegangsta/cli"
+)
+
+func main() {
+ cli.NewApp().Run(os.Args)
+}
+```
+
+This app will run and show help text, but is not very useful. Let's give an action to execute and some help documentation:
+
+``` go
+package main
+
+import (
+ "os"
+ "github.com/codegangsta/cli"
+)
+
+func main() {
+ app := cli.NewApp()
+ app.Name = "boom"
+ app.Usage = "make an explosive entrance"
+ app.Action = func(c *cli.Context) {
+ println("boom! I say!")
+ }
+
+ app.Run(os.Args)
+}
+```
+
+Running this already gives you a ton of functionality, plus support for things like subcommands and flags, which are covered below.
+
+## Example
+
+Being a programmer can be a lonely job. Thankfully by the power of automation that is not the case! Let's create a greeter app to fend off our demons of loneliness!
+
+Start by creating a directory named `greet`, and within it, add a file, `greet.go` with the following code in it:
+
+``` go
+package main
+
+import (
+ "os"
+ "github.com/codegangsta/cli"
+)
+
+func main() {
+ app := cli.NewApp()
+ app.Name = "greet"
+ app.Usage = "fight the loneliness!"
+ app.Action = func(c *cli.Context) {
+ println("Hello friend!")
+ }
+
+ app.Run(os.Args)
+}
+```
+
+Install our command to the `$GOPATH/bin` directory:
+
+```
+$ go install
+```
+
+Finally run our new command:
+
+```
+$ greet
+Hello friend!
+```
+
+cli.go also generates some bitchass help text:
+```
+$ greet help
+NAME:
+ greet - fight the loneliness!
+
+USAGE:
+ greet [global options] command [command options] [arguments...]
+
+VERSION:
+ 0.0.0
+
+COMMANDS:
+ help, h Shows a list of commands or help for one command
+
+GLOBAL OPTIONS
+ --version Shows version information
+```
+
+### Arguments
+You can lookup arguments by calling the `Args` function on `cli.Context`.
+
+``` go
+...
+app.Action = func(c *cli.Context) {
+ println("Hello", c.Args()[0])
+}
+...
+```
+
+### Flags
+Setting and querying flags is simple.
+``` go
+...
+app.Flags = []cli.Flag {
+ cli.StringFlag{
+ Name: "lang",
+ Value: "english",
+ Usage: "language for the greeting",
+ },
+}
+app.Action = func(c *cli.Context) {
+ name := "someone"
+ if len(c.Args()) > 0 {
+ name = c.Args()[0]
+ }
+ if c.String("lang") == "spanish" {
+ println("Hola", name)
+ } else {
+ println("Hello", name)
+ }
+}
+...
+```
+
+#### Alternate Names
+
+You can set alternate (or short) names for flags by providing a comma-delimited list for the `Name`. e.g.
+
+``` go
+app.Flags = []cli.Flag {
+ cli.StringFlag{
+ Name: "lang, l",
+ Value: "english",
+ Usage: "language for the greeting",
+ },
+}
+```
+
+That flag can then be set with `--lang spanish` or `-l spanish`. Note that giving two different forms of the same flag in the same command invocation is an error.
+
+#### Values from the Environment
+
+You can also have the default value set from the environment via `EnvVar`. e.g.
+
+``` go
+app.Flags = []cli.Flag {
+ cli.StringFlag{
+ Name: "lang, l",
+ Value: "english",
+ Usage: "language for the greeting",
+ EnvVar: "APP_LANG",
+ },
+}
+```
+
+The `EnvVar` may also be given as a comma-delimited "cascade", where the first environment variable that resolves is used as the default.
+
+``` go
+app.Flags = []cli.Flag {
+ cli.StringFlag{
+ Name: "lang, l",
+ Value: "english",
+ Usage: "language for the greeting",
+ EnvVar: "LEGACY_COMPAT_LANG,APP_LANG,LANG",
+ },
+}
+```
+
+### Subcommands
+
+Subcommands can be defined for a more git-like command line app.
+```go
+...
+app.Commands = []cli.Command{
+ {
+ Name: "add",
+ Aliases: []string{"a"},
+ Usage: "add a task to the list",
+ Action: func(c *cli.Context) {
+ println("added task: ", c.Args().First())
+ },
+ },
+ {
+ Name: "complete",
+ Aliases: []string{"c"},
+ Usage: "complete a task on the list",
+ Action: func(c *cli.Context) {
+ println("completed task: ", c.Args().First())
+ },
+ },
+ {
+ Name: "template",
+ Aliases: []string{"r"},
+ Usage: "options for task templates",
+ Subcommands: []cli.Command{
+ {
+ Name: "add",
+ Usage: "add a new template",
+ Action: func(c *cli.Context) {
+ println("new task template: ", c.Args().First())
+ },
+ },
+ {
+ Name: "remove",
+ Usage: "remove an existing template",
+ Action: func(c *cli.Context) {
+ println("removed task template: ", c.Args().First())
+ },
+ },
+ },
+ },
+}
+...
+```
+
+### Bash Completion
+
+You can enable completion commands by setting the `EnableBashCompletion`
+flag on the `App` object. By default, this setting will only auto-complete to
+show an app's subcommands, but you can write your own completion methods for
+the App or its subcommands.
+```go
+...
+var tasks = []string{"cook", "clean", "laundry", "eat", "sleep", "code"}
+app := cli.NewApp()
+app.EnableBashCompletion = true
+app.Commands = []cli.Command{
+ {
+ Name: "complete",
+ Aliases: []string{"c"},
+ Usage: "complete a task on the list",
+ Action: func(c *cli.Context) {
+ println("completed task: ", c.Args().First())
+ },
+ BashComplete: func(c *cli.Context) {
+ // This will complete if no args are passed
+ if len(c.Args()) > 0 {
+ return
+ }
+ for _, t := range tasks {
+ fmt.Println(t)
+ }
+ },
+ }
+}
+...
+```
+
+#### To Enable
+
+Source the `autocomplete/bash_autocomplete` file in your `.bashrc` file while
+setting the `PROG` variable to the name of your program:
+
+`PROG=myprogram source /.../cli/autocomplete/bash_autocomplete`
+
+
+## Contribution Guidelines
+Feel free to put up a pull request to fix a bug or maybe add a feature. I will give it a code review and make sure that it does not break backwards compatibility. If I or any other collaborators agree that it is in line with the vision of the project, we will work with you to get the code into a mergeable state and merge it into the master branch.
+
+If you have contributed something significant to the project, I will most likely add you as a collaborator. As a collaborator you are given the ability to merge others pull requests. It is very important that new code does not break existing code, so be careful about what code you do choose to merge. If you have any questions feel free to link @codegangsta to the issue in question and we can review it together.
+
+If you feel like you have contributed to the project but have not yet been added as a collaborator, I probably forgot to add you. Hit @codegangsta up over email and we will get it figured out.
diff --git a/Godeps/_workspace/src/github.com/codegangsta/cli/app.go b/Godeps/_workspace/src/github.com/codegangsta/cli/app.go
new file mode 100644
index 000000000..cd2900519
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/codegangsta/cli/app.go
@@ -0,0 +1,321 @@
+package cli
+
+import (
+ "fmt"
+ "io"
+ "io/ioutil"
+ "os"
+ "strings"
+ "text/tabwriter"
+ "text/template"
+ "time"
+)
+
+// App is the main structure of a cli application. It is recomended that
+// and app be created with the cli.NewApp() function
+type App struct {
+ // The name of the program. Defaults to os.Args[0]
+ Name string
+ // Description of the program.
+ Usage string
+ // Version of the program
+ Version string
+ // List of commands to execute
+ Commands []Command
+ // List of flags to parse
+ Flags []Flag
+ // Boolean to enable bash completion commands
+ EnableBashCompletion bool
+ // Boolean to hide built-in help command
+ HideHelp bool
+ // Boolean to hide built-in version flag
+ HideVersion bool
+ // An action to execute when the bash-completion flag is set
+ BashComplete func(context *Context)
+ // An action to execute before any subcommands are run, but after the context is ready
+ // If a non-nil error is returned, no subcommands are run
+ Before func(context *Context) error
+ // An action to execute after any subcommands are run, but after the subcommand has finished
+ // It is run even if Action() panics
+ After func(context *Context) error
+ // The action to execute when no subcommands are specified
+ Action func(context *Context)
+ // Execute this function if the proper command cannot be found
+ CommandNotFound func(context *Context, command string)
+ // Compilation date
+ Compiled time.Time
+ // List of all authors who contributed
+ Authors []Author
+ // Name of Author (Note: Use App.Authors, this is deprecated)
+ Author string
+ // Email of Author (Note: Use App.Authors, this is deprecated)
+ Email string
+ // Writer writer to write output to
+ Writer io.Writer
+}
+
+// Tries to find out when this binary was compiled.
+// Returns the current time if it fails to find it.
+func compileTime() time.Time {
+ info, err := os.Stat(os.Args[0])
+ if err != nil {
+ return time.Now()
+ }
+ return info.ModTime()
+}
+
+// Creates a new cli Application with some reasonable defaults for Name, Usage, Version and Action.
+func NewApp() *App {
+ return &App{
+ Name: os.Args[0],
+ Usage: "A new cli application",
+ Version: "0.0.0",
+ BashComplete: DefaultAppComplete,
+ Action: helpCommand.Action,
+ Compiled: compileTime(),
+ Writer: os.Stdout,
+ }
+}
+
+// Entry point to the cli app. Parses the arguments slice and routes to the proper flag/args combination
+func (a *App) Run(arguments []string) (err error) {
+ if a.Author != "" || a.Email != "" {
+ a.Authors = append(a.Authors, Author{Name: a.Author, Email: a.Email})
+ }
+
+ if HelpPrinter == nil {
+ defer func() {
+ HelpPrinter = nil
+ }()
+
+ HelpPrinter = func(templ string, data interface{}) {
+ funcMap := template.FuncMap{
+ "join": strings.Join,
+ }
+
+ w := tabwriter.NewWriter(a.Writer, 0, 8, 1, '\t', 0)
+ t := template.Must(template.New("help").Funcs(funcMap).Parse(templ))
+ err := t.Execute(w, data)
+ if err != nil {
+ panic(err)
+ }
+ w.Flush()
+ }
+ }
+
+ // append help to commands
+ if a.Command(helpCommand.Name) == nil && !a.HideHelp {
+ a.Commands = append(a.Commands, helpCommand)
+ if (HelpFlag != BoolFlag{}) {
+ a.appendFlag(HelpFlag)
+ }
+ }
+
+ //append version/help flags
+ if a.EnableBashCompletion {
+ a.appendFlag(BashCompletionFlag)
+ }
+
+ if !a.HideVersion {
+ a.appendFlag(VersionFlag)
+ }
+
+ // parse flags
+ set := flagSet(a.Name, a.Flags)
+ set.SetOutput(ioutil.Discard)
+ err = set.Parse(arguments[1:])
+ nerr := normalizeFlags(a.Flags, set)
+ if nerr != nil {
+ fmt.Fprintln(a.Writer, nerr)
+ context := NewContext(a, set, set)
+ ShowAppHelp(context)
+ fmt.Fprintln(a.Writer)
+ return nerr
+ }
+ context := NewContext(a, set, set)
+
+ if err != nil {
+ fmt.Fprintf(a.Writer, "Incorrect Usage.\n\n")
+ ShowAppHelp(context)
+ fmt.Fprintln(a.Writer)
+ return err
+ }
+
+ if checkCompletions(context) {
+ return nil
+ }
+
+ if checkHelp(context) {
+ return nil
+ }
+
+ if checkVersion(context) {
+ return nil
+ }
+
+ if a.After != nil {
+ defer func() {
+ // err is always nil here.
+ // There is a check to see if it is non-nil
+ // just few lines before.
+ err = a.After(context)
+ }()
+ }
+
+ if a.Before != nil {
+ err := a.Before(context)
+ if err != nil {
+ return err
+ }
+ }
+
+ args := context.Args()
+ if args.Present() {
+ name := args.First()
+ c := a.Command(name)
+ if c != nil {
+ return c.Run(context)
+ }
+ }
+
+ // Run default Action
+ a.Action(context)
+ return nil
+}
+
+// Another entry point to the cli app, takes care of passing arguments and error handling
+func (a *App) RunAndExitOnError() {
+ if err := a.Run(os.Args); err != nil {
+ fmt.Fprintln(os.Stderr, err)
+ os.Exit(1)
+ }
+}
+
+// Invokes the subcommand given the context, parses ctx.Args() to generate command-specific flags
+func (a *App) RunAsSubcommand(ctx *Context) (err error) {
+ // append help to commands
+ if len(a.Commands) > 0 {
+ if a.Command(helpCommand.Name) == nil && !a.HideHelp {
+ a.Commands = append(a.Commands, helpCommand)
+ if (HelpFlag != BoolFlag{}) {
+ a.appendFlag(HelpFlag)
+ }
+ }
+ }
+
+ // append flags
+ if a.EnableBashCompletion {
+ a.appendFlag(BashCompletionFlag)
+ }
+
+ // parse flags
+ set := flagSet(a.Name, a.Flags)
+ set.SetOutput(ioutil.Discard)
+ err = set.Parse(ctx.Args().Tail())
+ nerr := normalizeFlags(a.Flags, set)
+ context := NewContext(a, set, ctx.globalSet)
+
+ if nerr != nil {
+ fmt.Fprintln(a.Writer, nerr)
+ if len(a.Commands) > 0 {
+ ShowSubcommandHelp(context)
+ } else {
+ ShowCommandHelp(ctx, context.Args().First())
+ }
+ fmt.Fprintln(a.Writer)
+ return nerr
+ }
+
+ if err != nil {
+ fmt.Fprintf(a.Writer, "Incorrect Usage.\n\n")
+ ShowSubcommandHelp(context)
+ return err
+ }
+
+ if checkCompletions(context) {
+ return nil
+ }
+
+ if len(a.Commands) > 0 {
+ if checkSubcommandHelp(context) {
+ return nil
+ }
+ } else {
+ if checkCommandHelp(ctx, context.Args().First()) {
+ return nil
+ }
+ }
+
+ if a.After != nil {
+ defer func() {
+ // err is always nil here.
+ // There is a check to see if it is non-nil
+ // just few lines before.
+ err = a.After(context)
+ }()
+ }
+
+ if a.Before != nil {
+ err := a.Before(context)
+ if err != nil {
+ return err
+ }
+ }
+
+ args := context.Args()
+ if args.Present() {
+ name := args.First()
+ c := a.Command(name)
+ if c != nil {
+ return c.Run(context)
+ }
+ }
+
+ // Run default Action
+ a.Action(context)
+
+ return nil
+}
+
+// Returns the named command on App. Returns nil if the command does not exist
+func (a *App) Command(name string) *Command {
+ for _, c := range a.Commands {
+ if c.HasName(name) {
+ return &c
+ }
+ }
+
+ return nil
+}
+
+func (a *App) hasFlag(flag Flag) bool {
+ for _, f := range a.Flags {
+ if flag == f {
+ return true
+ }
+ }
+
+ return false
+}
+
+func (a *App) appendFlag(flag Flag) {
+ if !a.hasFlag(flag) {
+ a.Flags = append(a.Flags, flag)
+ }
+}
+
+// Author represents someone who has contributed to a cli project.
+type Author struct {
+ Name string // The Authors name
+ Email string // The Authors email
+}
+
+// String makes Author comply to the Stringer interface, to allow an easy print in the templating process
+func (a Author) String() string {
+ e := ""
+ if a.Email != "" {
+ e = "<" + a.Email + "> "
+ }
+
+ return fmt.Sprintf("%v %v", a.Name, e)
+}
diff --git a/Godeps/_workspace/src/github.com/codegangsta/cli/app_test.go b/Godeps/_workspace/src/github.com/codegangsta/cli/app_test.go
new file mode 100644
index 000000000..4a40b89cd
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/codegangsta/cli/app_test.go
@@ -0,0 +1,622 @@
+package cli_test
+
+import (
+ "flag"
+ "fmt"
+ "os"
+ "testing"
+
+ "github.com/codegangsta/cli"
+)
+
+func ExampleApp() {
+ // set args for examples sake
+ os.Args = []string{"greet", "--name", "Jeremy"}
+
+ app := cli.NewApp()
+ app.Name = "greet"
+ app.Flags = []cli.Flag{
+ cli.StringFlag{Name: "name", Value: "bob", Usage: "a name to say"},
+ }
+ app.Action = func(c *cli.Context) {
+ fmt.Printf("Hello %v\n", c.String("name"))
+ }
+ app.Author = "Harrison"
+ app.Email = "harrison@lolwut.com"
+ app.Authors = []cli.Author{cli.Author{Name: "Oliver Allen", Email: "oliver@toyshop.com"}}
+ app.Run(os.Args)
+ // Output:
+ // Hello Jeremy
+}
+
+func ExampleAppSubcommand() {
+ // set args for examples sake
+ os.Args = []string{"say", "hi", "english", "--name", "Jeremy"}
+ app := cli.NewApp()
+ app.Name = "say"
+ app.Commands = []cli.Command{
+ {
+ Name: "hello",
+ Aliases: []string{"hi"},
+ Usage: "use it to see a description",
+ Description: "This is how we describe hello the function",
+ Subcommands: []cli.Command{
+ {
+ Name: "english",
+ Aliases: []string{"en"},
+ Usage: "sends a greeting in english",
+ Description: "greets someone in english",
+ Flags: []cli.Flag{
+ cli.StringFlag{
+ Name: "name",
+ Value: "Bob",
+ Usage: "Name of the person to greet",
+ },
+ },
+ Action: func(c *cli.Context) {
+ fmt.Println("Hello,", c.String("name"))
+ },
+ },
+ },
+ },
+ }
+
+ app.Run(os.Args)
+ // Output:
+ // Hello, Jeremy
+}
+
+func ExampleAppHelp() {
+ // set args for examples sake
+ os.Args = []string{"greet", "h", "describeit"}
+
+ app := cli.NewApp()
+ app.Name = "greet"
+ app.Flags = []cli.Flag{
+ cli.StringFlag{Name: "name", Value: "bob", Usage: "a name to say"},
+ }
+ app.Commands = []cli.Command{
+ {
+ Name: "describeit",
+ Aliases: []string{"d"},
+ Usage: "use it to see a description",
+ Description: "This is how we describe describeit the function",
+ Action: func(c *cli.Context) {
+ fmt.Printf("i like to describe things")
+ },
+ },
+ }
+ app.Run(os.Args)
+ // Output:
+ // NAME:
+ // describeit - use it to see a description
+ //
+ // USAGE:
+ // command describeit [arguments...]
+ //
+ // DESCRIPTION:
+ // This is how we describe describeit the function
+}
+
+func ExampleAppBashComplete() {
+ // set args for examples sake
+ os.Args = []string{"greet", "--generate-bash-completion"}
+
+ app := cli.NewApp()
+ app.Name = "greet"
+ app.EnableBashCompletion = true
+ app.Commands = []cli.Command{
+ {
+ Name: "describeit",
+ Aliases: []string{"d"},
+ Usage: "use it to see a description",
+ Description: "This is how we describe describeit the function",
+ Action: func(c *cli.Context) {
+ fmt.Printf("i like to describe things")
+ },
+ }, {
+ Name: "next",
+ Usage: "next example",
+ Description: "more stuff to see when generating bash completion",
+ Action: func(c *cli.Context) {
+ fmt.Printf("the next example")
+ },
+ },
+ }
+
+ app.Run(os.Args)
+ // Output:
+ // describeit
+ // d
+ // next
+ // help
+ // h
+}
+
+func TestApp_Run(t *testing.T) {
+ s := ""
+
+ app := cli.NewApp()
+ app.Action = func(c *cli.Context) {
+ s = s + c.Args().First()
+ }
+
+ err := app.Run([]string{"command", "foo"})
+ expect(t, err, nil)
+ err = app.Run([]string{"command", "bar"})
+ expect(t, err, nil)
+ expect(t, s, "foobar")
+}
+
+var commandAppTests = []struct {
+ name string
+ expected bool
+}{
+ {"foobar", true},
+ {"batbaz", true},
+ {"b", true},
+ {"f", true},
+ {"bat", false},
+ {"nothing", false},
+}
+
+func TestApp_Command(t *testing.T) {
+ app := cli.NewApp()
+ fooCommand := cli.Command{Name: "foobar", Aliases: []string{"f"}}
+ batCommand := cli.Command{Name: "batbaz", Aliases: []string{"b"}}
+ app.Commands = []cli.Command{
+ fooCommand,
+ batCommand,
+ }
+
+ for _, test := range commandAppTests {
+ expect(t, app.Command(test.name) != nil, test.expected)
+ }
+}
+
+func TestApp_CommandWithArgBeforeFlags(t *testing.T) {
+ var parsedOption, firstArg string
+
+ app := cli.NewApp()
+ command := cli.Command{
+ Name: "cmd",
+ Flags: []cli.Flag{
+ cli.StringFlag{Name: "option", Value: "", Usage: "some option"},
+ },
+ Action: func(c *cli.Context) {
+ parsedOption = c.String("option")
+ firstArg = c.Args().First()
+ },
+ }
+ app.Commands = []cli.Command{command}
+
+ app.Run([]string{"", "cmd", "my-arg", "--option", "my-option"})
+
+ expect(t, parsedOption, "my-option")
+ expect(t, firstArg, "my-arg")
+}
+
+func TestApp_RunAsSubcommandParseFlags(t *testing.T) {
+ var context *cli.Context
+
+ a := cli.NewApp()
+ a.Commands = []cli.Command{
+ {
+ Name: "foo",
+ Action: func(c *cli.Context) {
+ context = c
+ },
+ Flags: []cli.Flag{
+ cli.StringFlag{
+ Name: "lang",
+ Value: "english",
+ Usage: "language for the greeting",
+ },
+ },
+ Before: func(_ *cli.Context) error { return nil },
+ },
+ }
+ a.Run([]string{"", "foo", "--lang", "spanish", "abcd"})
+
+ expect(t, context.Args().Get(0), "abcd")
+ expect(t, context.String("lang"), "spanish")
+}
+
+func TestApp_CommandWithFlagBeforeTerminator(t *testing.T) {
+ var parsedOption string
+ var args []string
+
+ app := cli.NewApp()
+ command := cli.Command{
+ Name: "cmd",
+ Flags: []cli.Flag{
+ cli.StringFlag{Name: "option", Value: "", Usage: "some option"},
+ },
+ Action: func(c *cli.Context) {
+ parsedOption = c.String("option")
+ args = c.Args()
+ },
+ }
+ app.Commands = []cli.Command{command}
+
+ app.Run([]string{"", "cmd", "my-arg", "--option", "my-option", "--", "--notARealFlag"})
+
+ expect(t, parsedOption, "my-option")
+ expect(t, args[0], "my-arg")
+ expect(t, args[1], "--")
+ expect(t, args[2], "--notARealFlag")
+}
+
+func TestApp_CommandWithNoFlagBeforeTerminator(t *testing.T) {
+ var args []string
+
+ app := cli.NewApp()
+ command := cli.Command{
+ Name: "cmd",
+ Action: func(c *cli.Context) {
+ args = c.Args()
+ },
+ }
+ app.Commands = []cli.Command{command}
+
+ app.Run([]string{"", "cmd", "my-arg", "--", "notAFlagAtAll"})
+
+ expect(t, args[0], "my-arg")
+ expect(t, args[1], "--")
+ expect(t, args[2], "notAFlagAtAll")
+}
+
+func TestApp_Float64Flag(t *testing.T) {
+ var meters float64
+
+ app := cli.NewApp()
+ app.Flags = []cli.Flag{
+ cli.Float64Flag{Name: "height", Value: 1.5, Usage: "Set the height, in meters"},
+ }
+ app.Action = func(c *cli.Context) {
+ meters = c.Float64("height")
+ }
+
+ app.Run([]string{"", "--height", "1.93"})
+ expect(t, meters, 1.93)
+}
+
+func TestApp_ParseSliceFlags(t *testing.T) {
+ var parsedOption, firstArg string
+ var parsedIntSlice []int
+ var parsedStringSlice []string
+
+ app := cli.NewApp()
+ command := cli.Command{
+ Name: "cmd",
+ Flags: []cli.Flag{
+ cli.IntSliceFlag{Name: "p", Value: &cli.IntSlice{}, Usage: "set one or more ip addr"},
+ cli.StringSliceFlag{Name: "ip", Value: &cli.StringSlice{}, Usage: "set one or more ports to open"},
+ },
+ Action: func(c *cli.Context) {
+ parsedIntSlice = c.IntSlice("p")
+ parsedStringSlice = c.StringSlice("ip")
+ parsedOption = c.String("option")
+ firstArg = c.Args().First()
+ },
+ }
+ app.Commands = []cli.Command{command}
+
+ app.Run([]string{"", "cmd", "my-arg", "-p", "22", "-p", "80", "-ip", "8.8.8.8", "-ip", "8.8.4.4"})
+
+ IntsEquals := func(a, b []int) bool {
+ if len(a) != len(b) {
+ return false
+ }
+ for i, v := range a {
+ if v != b[i] {
+ return false
+ }
+ }
+ return true
+ }
+
+ StrsEquals := func(a, b []string) bool {
+ if len(a) != len(b) {
+ return false
+ }
+ for i, v := range a {
+ if v != b[i] {
+ return false
+ }
+ }
+ return true
+ }
+ var expectedIntSlice = []int{22, 80}
+ var expectedStringSlice = []string{"8.8.8.8", "8.8.4.4"}
+
+ if !IntsEquals(parsedIntSlice, expectedIntSlice) {
+ t.Errorf("%v does not match %v", parsedIntSlice, expectedIntSlice)
+ }
+
+ if !StrsEquals(parsedStringSlice, expectedStringSlice) {
+ t.Errorf("%v does not match %v", parsedStringSlice, expectedStringSlice)
+ }
+}
+
+func TestApp_DefaultStdout(t *testing.T) {
+ app := cli.NewApp()
+
+ if app.Writer != os.Stdout {
+ t.Error("Default output writer not set.")
+ }
+}
+
+type mockWriter struct {
+ written []byte
+}
+
+func (fw *mockWriter) Write(p []byte) (n int, err error) {
+ if fw.written == nil {
+ fw.written = p
+ } else {
+ fw.written = append(fw.written, p...)
+ }
+
+ return len(p), nil
+}
+
+func (fw *mockWriter) GetWritten() (b []byte) {
+ return fw.written
+}
+
+func TestApp_SetStdout(t *testing.T) {
+ w := &mockWriter{}
+
+ app := cli.NewApp()
+ app.Name = "test"
+ app.Writer = w
+
+ err := app.Run([]string{"help"})
+
+ if err != nil {
+ t.Fatalf("Run error: %s", err)
+ }
+
+ if len(w.written) == 0 {
+ t.Error("App did not write output to desired writer.")
+ }
+}
+
+func TestApp_BeforeFunc(t *testing.T) {
+ beforeRun, subcommandRun := false, false
+ beforeError := fmt.Errorf("fail")
+ var err error
+
+ app := cli.NewApp()
+
+ app.Before = func(c *cli.Context) error {
+ beforeRun = true
+ s := c.String("opt")
+ if s == "fail" {
+ return beforeError
+ }
+
+ return nil
+ }
+
+ app.Commands = []cli.Command{
+ cli.Command{
+ Name: "sub",
+ Action: func(c *cli.Context) {
+ subcommandRun = true
+ },
+ },
+ }
+
+ app.Flags = []cli.Flag{
+ cli.StringFlag{Name: "opt"},
+ }
+
+ // run with the Before() func succeeding
+ err = app.Run([]string{"command", "--opt", "succeed", "sub"})
+
+ if err != nil {
+ t.Fatalf("Run error: %s", err)
+ }
+
+ if beforeRun == false {
+ t.Errorf("Before() not executed when expected")
+ }
+
+ if subcommandRun == false {
+ t.Errorf("Subcommand not executed when expected")
+ }
+
+ // reset
+ beforeRun, subcommandRun = false, false
+
+ // run with the Before() func failing
+ err = app.Run([]string{"command", "--opt", "fail", "sub"})
+
+ // should be the same error produced by the Before func
+ if err != beforeError {
+ t.Errorf("Run error expected, but not received")
+ }
+
+ if beforeRun == false {
+ t.Errorf("Before() not executed when expected")
+ }
+
+ if subcommandRun == true {
+ t.Errorf("Subcommand executed when NOT expected")
+ }
+
+}
+
+func TestApp_AfterFunc(t *testing.T) {
+ afterRun, subcommandRun := false, false
+ afterError := fmt.Errorf("fail")
+ var err error
+
+ app := cli.NewApp()
+
+ app.After = func(c *cli.Context) error {
+ afterRun = true
+ s := c.String("opt")
+ if s == "fail" {
+ return afterError
+ }
+
+ return nil
+ }
+
+ app.Commands = []cli.Command{
+ cli.Command{
+ Name: "sub",
+ Action: func(c *cli.Context) {
+ subcommandRun = true
+ },
+ },
+ }
+
+ app.Flags = []cli.Flag{
+ cli.StringFlag{Name: "opt"},
+ }
+
+ // run with the After() func succeeding
+ err = app.Run([]string{"command", "--opt", "succeed", "sub"})
+
+ if err != nil {
+ t.Fatalf("Run error: %s", err)
+ }
+
+ if afterRun == false {
+ t.Errorf("After() not executed when expected")
+ }
+
+ if subcommandRun == false {
+ t.Errorf("Subcommand not executed when expected")
+ }
+
+ // reset
+ afterRun, subcommandRun = false, false
+
+ // run with the Before() func failing
+ err = app.Run([]string{"command", "--opt", "fail", "sub"})
+
+ // should be the same error produced by the Before func
+ if err != afterError {
+ t.Errorf("Run error expected, but not received")
+ }
+
+ if afterRun == false {
+ t.Errorf("After() not executed when expected")
+ }
+
+ if subcommandRun == false {
+ t.Errorf("Subcommand not executed when expected")
+ }
+}
+
+func TestAppNoHelpFlag(t *testing.T) {
+ oldFlag := cli.HelpFlag
+ defer func() {
+ cli.HelpFlag = oldFlag
+ }()
+
+ cli.HelpFlag = cli.BoolFlag{}
+
+ app := cli.NewApp()
+ err := app.Run([]string{"test", "-h"})
+
+ if err != flag.ErrHelp {
+ t.Errorf("expected error about missing help flag, but got: %s (%T)", err, err)
+ }
+}
+
+func TestAppHelpPrinter(t *testing.T) {
+ oldPrinter := cli.HelpPrinter
+ defer func() {
+ cli.HelpPrinter = oldPrinter
+ }()
+
+ var wasCalled = false
+ cli.HelpPrinter = func(template string, data interface{}) {
+ wasCalled = true
+ }
+
+ app := cli.NewApp()
+ app.Run([]string{"-h"})
+
+ if wasCalled == false {
+ t.Errorf("Help printer expected to be called, but was not")
+ }
+}
+
+func TestAppVersionPrinter(t *testing.T) {
+ oldPrinter := cli.VersionPrinter
+ defer func() {
+ cli.VersionPrinter = oldPrinter
+ }()
+
+ var wasCalled = false
+ cli.VersionPrinter = func(c *cli.Context) {
+ wasCalled = true
+ }
+
+ app := cli.NewApp()
+ ctx := cli.NewContext(app, nil, nil)
+ cli.ShowVersion(ctx)
+
+ if wasCalled == false {
+ t.Errorf("Version printer expected to be called, but was not")
+ }
+}
+
+func TestAppCommandNotFound(t *testing.T) {
+ beforeRun, subcommandRun := false, false
+ app := cli.NewApp()
+
+ app.CommandNotFound = func(c *cli.Context, command string) {
+ beforeRun = true
+ }
+
+ app.Commands = []cli.Command{
+ cli.Command{
+ Name: "bar",
+ Action: func(c *cli.Context) {
+ subcommandRun = true
+ },
+ },
+ }
+
+ app.Run([]string{"command", "foo"})
+
+ expect(t, beforeRun, true)
+ expect(t, subcommandRun, false)
+}
+
+func TestGlobalFlagsInSubcommands(t *testing.T) {
+ subcommandRun := false
+ app := cli.NewApp()
+
+ app.Flags = []cli.Flag{
+ cli.BoolFlag{Name: "debug, d", Usage: "Enable debugging"},
+ }
+
+ app.Commands = []cli.Command{
+ cli.Command{
+ Name: "foo",
+ Subcommands: []cli.Command{
+ {
+ Name: "bar",
+ Action: func(c *cli.Context) {
+ if c.GlobalBool("debug") {
+ subcommandRun = true
+ }
+ },
+ },
+ },
+ },
+ }
+
+ app.Run([]string{"command", "-d", "foo", "bar"})
+
+ expect(t, subcommandRun, true)
+}
diff --git a/Godeps/_workspace/src/github.com/codegangsta/cli/autocomplete/bash_autocomplete b/Godeps/_workspace/src/github.com/codegangsta/cli/autocomplete/bash_autocomplete
new file mode 100644
index 000000000..9b55dd990
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/codegangsta/cli/autocomplete/bash_autocomplete
@@ -0,0 +1,13 @@
+#! /bin/bash
+
+_cli_bash_autocomplete() {
+ local cur prev opts base
+ COMPREPLY=()
+ cur="${COMP_WORDS[COMP_CWORD]}"
+ prev="${COMP_WORDS[COMP_CWORD-1]}"
+ opts=$( ${COMP_WORDS[@]:0:$COMP_CWORD} --generate-bash-completion )
+ COMPREPLY=( $(compgen -W "${opts}" -- ${cur}) )
+ return 0
+ }
+
+ complete -F _cli_bash_autocomplete $PROG \ No newline at end of file
diff --git a/Godeps/_workspace/src/github.com/codegangsta/cli/autocomplete/zsh_autocomplete b/Godeps/_workspace/src/github.com/codegangsta/cli/autocomplete/zsh_autocomplete
new file mode 100644
index 000000000..5430a18f9
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/codegangsta/cli/autocomplete/zsh_autocomplete
@@ -0,0 +1,5 @@
+autoload -U compinit && compinit
+autoload -U bashcompinit && bashcompinit
+
+script_dir=$(dirname $0)
+source ${script_dir}/bash_autocomplete
diff --git a/Godeps/_workspace/src/github.com/codegangsta/cli/cli.go b/Godeps/_workspace/src/github.com/codegangsta/cli/cli.go
new file mode 100644
index 000000000..b74254581
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/codegangsta/cli/cli.go
@@ -0,0 +1,19 @@
+// Package cli provides a minimal framework for creating and organizing command line
+// Go applications. cli is designed to be easy to understand and write, the most simple
+// cli application can be written as follows:
+// func main() {
+// cli.NewApp().Run(os.Args)
+// }
+//
+// Of course this application does not do much, so let's make this an actual application:
+// func main() {
+// app := cli.NewApp()
+// app.Name = "greet"
+// app.Usage = "say a greeting"
+// app.Action = func(c *cli.Context) {
+// println("Greetings")
+// }
+//
+// app.Run(os.Args)
+// }
+package cli
diff --git a/Godeps/_workspace/src/github.com/codegangsta/cli/cli_test.go b/Godeps/_workspace/src/github.com/codegangsta/cli/cli_test.go
new file mode 100644
index 000000000..8a8df9736
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/codegangsta/cli/cli_test.go
@@ -0,0 +1,100 @@
+package cli_test
+
+import (
+ "os"
+
+ "github.com/codegangsta/cli"
+)
+
+func Example() {
+ app := cli.NewApp()
+ app.Name = "todo"
+ app.Usage = "task list on the command line"
+ app.Commands = []cli.Command{
+ {
+ Name: "add",
+ Aliases: []string{"a"},
+ Usage: "add a task to the list",
+ Action: func(c *cli.Context) {
+ println("added task: ", c.Args().First())
+ },
+ },
+ {
+ Name: "complete",
+ Aliases: []string{"c"},
+ Usage: "complete a task on the list",
+ Action: func(c *cli.Context) {
+ println("completed task: ", c.Args().First())
+ },
+ },
+ }
+
+ app.Run(os.Args)
+}
+
+func ExampleSubcommand() {
+ app := cli.NewApp()
+ app.Name = "say"
+ app.Commands = []cli.Command{
+ {
+ Name: "hello",
+ Aliases: []string{"hi"},
+ Usage: "use it to see a description",
+ Description: "This is how we describe hello the function",
+ Subcommands: []cli.Command{
+ {
+ Name: "english",
+ Aliases: []string{"en"},
+ Usage: "sends a greeting in english",
+ Description: "greets someone in english",
+ Flags: []cli.Flag{
+ cli.StringFlag{
+ Name: "name",
+ Value: "Bob",
+ Usage: "Name of the person to greet",
+ },
+ },
+ Action: func(c *cli.Context) {
+ println("Hello, ", c.String("name"))
+ },
+ }, {
+ Name: "spanish",
+ Aliases: []string{"sp"},
+ Usage: "sends a greeting in spanish",
+ Flags: []cli.Flag{
+ cli.StringFlag{
+ Name: "surname",
+ Value: "Jones",
+ Usage: "Surname of the person to greet",
+ },
+ },
+ Action: func(c *cli.Context) {
+ println("Hola, ", c.String("surname"))
+ },
+ }, {
+ Name: "french",
+ Aliases: []string{"fr"},
+ Usage: "sends a greeting in french",
+ Flags: []cli.Flag{
+ cli.StringFlag{
+ Name: "nickname",
+ Value: "Stevie",
+ Usage: "Nickname of the person to greet",
+ },
+ },
+ Action: func(c *cli.Context) {
+ println("Bonjour, ", c.String("nickname"))
+ },
+ },
+ },
+ }, {
+ Name: "bye",
+ Usage: "says goodbye",
+ Action: func(c *cli.Context) {
+ println("bye")
+ },
+ },
+ }
+
+ app.Run(os.Args)
+}
diff --git a/Godeps/_workspace/src/github.com/codegangsta/cli/command.go b/Godeps/_workspace/src/github.com/codegangsta/cli/command.go
new file mode 100644
index 000000000..b61691c86
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/codegangsta/cli/command.go
@@ -0,0 +1,177 @@
+package cli
+
+import (
+ "fmt"
+ "io/ioutil"
+ "strings"
+)
+
+// Command is a subcommand for a cli.App.
+type Command struct {
+ // The name of the command
+ Name string
+ // short name of the command. Typically one character (deprecated, use `Aliases`)
+ ShortName string
+ // A list of aliases for the command
+ Aliases []string
+ // A short description of the usage of this command
+ Usage string
+ // A longer explanation of how the command works
+ Description string
+ // The function to call when checking for bash command completions
+ BashComplete func(context *Context)
+ // An action to execute before any sub-subcommands are run, but after the context is ready
+ // If a non-nil error is returned, no sub-subcommands are run
+ Before func(context *Context) error
+ // An action to execute after any subcommands are run, but after the subcommand has finished
+ // It is run even if Action() panics
+ After func(context *Context) error
+ // The function to call when this command is invoked
+ Action func(context *Context)
+ // List of child commands
+ Subcommands []Command
+ // List of flags to parse
+ Flags []Flag
+ // Treat all flags as normal arguments if true
+ SkipFlagParsing bool
+ // Boolean to hide built-in help command
+ HideHelp bool
+}
+
+// Invokes the command given the context, parses ctx.Args() to generate command-specific flags
+func (c Command) Run(ctx *Context) error {
+
+ if len(c.Subcommands) > 0 || c.Before != nil || c.After != nil {
+ return c.startApp(ctx)
+ }
+
+ if !c.HideHelp && (HelpFlag != BoolFlag{}) {
+ // append help to flags
+ c.Flags = append(
+ c.Flags,
+ HelpFlag,
+ )
+ }
+
+ if ctx.App.EnableBashCompletion {
+ c.Flags = append(c.Flags, BashCompletionFlag)
+ }
+
+ set := flagSet(c.Name, c.Flags)
+ set.SetOutput(ioutil.Discard)
+
+ firstFlagIndex := -1
+ terminatorIndex := -1
+ for index, arg := range ctx.Args() {
+ if arg == "--" {
+ terminatorIndex = index
+ break
+ } else if strings.HasPrefix(arg, "-") && firstFlagIndex == -1 {
+ firstFlagIndex = index
+ }
+ }
+
+ var err error
+ if firstFlagIndex > -1 && !c.SkipFlagParsing {
+ args := ctx.Args()
+ regularArgs := make([]string, len(args[1:firstFlagIndex]))
+ copy(regularArgs, args[1:firstFlagIndex])
+
+ var flagArgs []string
+ if terminatorIndex > -1 {
+ flagArgs = args[firstFlagIndex:terminatorIndex]
+ regularArgs = append(regularArgs, args[terminatorIndex:]...)
+ } else {
+ flagArgs = args[firstFlagIndex:]
+ }
+
+ err = set.Parse(append(flagArgs, regularArgs...))
+ } else {
+ err = set.Parse(ctx.Args().Tail())
+ }
+
+ if err != nil {
+ fmt.Fprint(ctx.App.Writer, "Incorrect Usage.\n\n")
+ ShowCommandHelp(ctx, c.Name)
+ fmt.Fprintln(ctx.App.Writer)
+ return err
+ }
+
+ nerr := normalizeFlags(c.Flags, set)
+ if nerr != nil {
+ fmt.Fprintln(ctx.App.Writer, nerr)
+ fmt.Fprintln(ctx.App.Writer)
+ ShowCommandHelp(ctx, c.Name)
+ fmt.Fprintln(ctx.App.Writer)
+ return nerr
+ }
+ context := NewContext(ctx.App, set, ctx.globalSet)
+
+ if checkCommandCompletions(context, c.Name) {
+ return nil
+ }
+
+ if checkCommandHelp(context, c.Name) {
+ return nil
+ }
+ context.Command = c
+ c.Action(context)
+ return nil
+}
+
+func (c Command) Names() []string {
+ names := []string{c.Name}
+
+ if c.ShortName != "" {
+ names = append(names, c.ShortName)
+ }
+
+ return append(names, c.Aliases...)
+}
+
+// Returns true if Command.Name or Command.ShortName matches given name
+func (c Command) HasName(name string) bool {
+ for _, n := range c.Names() {
+ if n == name {
+ return true
+ }
+ }
+ return false
+}
+
+func (c Command) startApp(ctx *Context) error {
+ app := NewApp()
+
+ // set the name and usage
+ app.Name = fmt.Sprintf("%s %s", ctx.App.Name, c.Name)
+ if c.Description != "" {
+ app.Usage = c.Description
+ } else {
+ app.Usage = c.Usage
+ }
+
+ // set CommandNotFound
+ app.CommandNotFound = ctx.App.CommandNotFound
+
+ // set the flags and commands
+ app.Commands = c.Subcommands
+ app.Flags = c.Flags
+ app.HideHelp = c.HideHelp
+
+ // bash completion
+ app.EnableBashCompletion = ctx.App.EnableBashCompletion
+ if c.BashComplete != nil {
+ app.BashComplete = c.BashComplete
+ }
+
+ // set the actions
+ app.Before = c.Before
+ app.After = c.After
+ if c.Action != nil {
+ app.Action = c.Action
+ } else {
+ app.Action = helpSubcommand.Action
+ }
+
+ return app.RunAsSubcommand(ctx)
+}
diff --git a/Godeps/_workspace/src/github.com/codegangsta/cli/command_test.go b/Godeps/_workspace/src/github.com/codegangsta/cli/command_test.go
new file mode 100644
index 000000000..4125b0c1b
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/codegangsta/cli/command_test.go
@@ -0,0 +1,49 @@
+package cli_test
+
+import (
+ "flag"
+ "testing"
+
+ "github.com/codegangsta/cli"
+)
+
+func TestCommandDoNotIgnoreFlags(t *testing.T) {
+ app := cli.NewApp()
+ set := flag.NewFlagSet("test", 0)
+ test := []string{"blah", "blah", "-break"}
+ set.Parse(test)
+
+ c := cli.NewContext(app, set, set)
+
+ command := cli.Command{
+ Name: "test-cmd",
+ Aliases: []string{"tc"},
+ Usage: "this is for testing",
+ Description: "testing",
+ Action: func(_ *cli.Context) {},
+ }
+ err := command.Run(c)
+
+ expect(t, err.Error(), "flag provided but not defined: -break")
+}
+
+func TestCommandIgnoreFlags(t *testing.T) {
+ app := cli.NewApp()
+ set := flag.NewFlagSet("test", 0)
+ test := []string{"blah", "blah"}
+ set.Parse(test)
+
+ c := cli.NewContext(app, set, set)
+
+ command := cli.Command{
+ Name: "test-cmd",
+ Aliases: []string{"tc"},
+ Usage: "this is for testing",
+ Description: "testing",
+ Action: func(_ *cli.Context) {},
+ SkipFlagParsing: true,
+ }
+ err := command.Run(c)
+
+ expect(t, err, nil)
+}
diff --git a/Godeps/_workspace/src/github.com/codegangsta/cli/context.go b/Godeps/_workspace/src/github.com/codegangsta/cli/context.go
new file mode 100644
index 000000000..37221bdc2
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/codegangsta/cli/context.go
@@ -0,0 +1,344 @@
+package cli
+
+import (
+ "errors"
+ "flag"
+ "strconv"
+ "strings"
+ "time"
+)
+
+// Context is a type that is passed through to
+// each Handler action in a cli application. Context
+// can be used to retrieve context-specific Args and
+// parsed command-line options.
+type Context struct {
+ App *App
+ Command Command
+ flagSet *flag.FlagSet
+ globalSet *flag.FlagSet
+ setFlags map[string]bool
+ globalSetFlags map[string]bool
+}
+
+// Creates a new context. For use in when invoking an App or Command action.
+func NewContext(app *App, set *flag.FlagSet, globalSet *flag.FlagSet) *Context {
+ return &Context{App: app, flagSet: set, globalSet: globalSet}
+}
+
+// Looks up the value of a local int flag, returns 0 if no int flag exists
+func (c *Context) Int(name string) int {
+ return lookupInt(name, c.flagSet)
+}
+
+// Looks up the value of a local time.Duration flag, returns 0 if no time.Duration flag exists
+func (c *Context) Duration(name string) time.Duration {
+ return lookupDuration(name, c.flagSet)
+}
+
+// Looks up the value of a local float64 flag, returns 0 if no float64 flag exists
+func (c *Context) Float64(name string) float64 {
+ return lookupFloat64(name, c.flagSet)
+}
+
+// Looks up the value of a local bool flag, returns false if no bool flag exists
+func (c *Context) Bool(name string) bool {
+ return lookupBool(name, c.flagSet)
+}
+
+// Looks up the value of a local boolT flag, returns false if no bool flag exists
+func (c *Context) BoolT(name string) bool {
+ return lookupBoolT(name, c.flagSet)
+}
+
+// Looks up the value of a local string flag, returns "" if no string flag exists
+func (c *Context) String(name string) string {
+ return lookupString(name, c.flagSet)
+}
+
+// Looks up the value of a local string slice flag, returns nil if no string slice flag exists
+func (c *Context) StringSlice(name string) []string {
+ return lookupStringSlice(name, c.flagSet)
+}
+
+// Looks up the value of a local int slice flag, returns nil if no int slice flag exists
+func (c *Context) IntSlice(name string) []int {
+ return lookupIntSlice(name, c.flagSet)
+}
+
+// Looks up the value of a local generic flag, returns nil if no generic flag exists
+func (c *Context) Generic(name string) interface{} {
+ return lookupGeneric(name, c.flagSet)
+}
+
+// Looks up the value of a global int flag, returns 0 if no int flag exists
+func (c *Context) GlobalInt(name string) int {
+ return lookupInt(name, c.globalSet)
+}
+
+// Looks up the value of a global time.Duration flag, returns 0 if no time.Duration flag exists
+func (c *Context) GlobalDuration(name string) time.Duration {
+ return lookupDuration(name, c.globalSet)
+}
+
+// Looks up the value of a global bool flag, returns false if no bool flag exists
+func (c *Context) GlobalBool(name string) bool {
+ return lookupBool(name, c.globalSet)
+}
+
+// Looks up the value of a global string flag, returns "" if no string flag exists
+func (c *Context) GlobalString(name string) string {
+ return lookupString(name, c.globalSet)
+}
+
+// Looks up the value of a global string slice flag, returns nil if no string slice flag exists
+func (c *Context) GlobalStringSlice(name string) []string {
+ return lookupStringSlice(name, c.globalSet)
+}
+
+// Looks up the value of a global int slice flag, returns nil if no int slice flag exists
+func (c *Context) GlobalIntSlice(name string) []int {
+ return lookupIntSlice(name, c.globalSet)
+}
+
+// Looks up the value of a global generic flag, returns nil if no generic flag exists
+func (c *Context) GlobalGeneric(name string) interface{} {
+ return lookupGeneric(name, c.globalSet)
+}
+
+// Returns the number of flags set
+func (c *Context) NumFlags() int {
+ return c.flagSet.NFlag()
+}
+
+// Determines if the flag was actually set
+func (c *Context) IsSet(name string) bool {
+ if c.setFlags == nil {
+ c.setFlags = make(map[string]bool)
+ c.flagSet.Visit(func(f *flag.Flag) {
+ c.setFlags[f.Name] = true
+ })
+ }
+ return c.setFlags[name] == true
+}
+
+// Determines if the global flag was actually set
+func (c *Context) GlobalIsSet(name string) bool {
+ if c.globalSetFlags == nil {
+ c.globalSetFlags = make(map[string]bool)
+ c.globalSet.Visit(func(f *flag.Flag) {
+ c.globalSetFlags[f.Name] = true
+ })
+ }
+ return c.globalSetFlags[name] == true
+}
+
+// Returns a slice of flag names used in this context.
+func (c *Context) FlagNames() (names []string) {
+ for _, flag := range c.Command.Flags {
+ name := strings.Split(flag.getName(), ",")[0]
+ if name == "help" {
+ continue
+ }
+ names = append(names, name)
+ }
+ return
+}
+
+// Returns a slice of global flag names used by the app.
+func (c *Context) GlobalFlagNames() (names []string) {
+ for _, flag := range c.App.Flags {
+ name := strings.Split(flag.getName(), ",")[0]
+ if name == "help" || name == "version" {
+ continue
+ }
+ names = append(names, name)
+ }
+ return
+}
+
+type Args []string
+
+// Returns the command line arguments associated with the context.
+func (c *Context) Args() Args {
+ args := Args(c.flagSet.Args())
+ return args
+}
+
+// Returns the nth argument, or else a blank string
+func (a Args) Get(n int) string {
+ if len(a) > n {
+ return a[n]
+ }
+ return ""
+}
+
+// Returns the first argument, or else a blank string
+func (a Args) First() string {
+ return a.Get(0)
+}
+
+// Return the rest of the arguments (not the first one)
+// or else an empty string slice
+func (a Args) Tail() []string {
+ if len(a) >= 2 {
+ return []string(a)[1:]
+ }
+ return []string{}
+}
+
+// Checks if there are any arguments present
+func (a Args) Present() bool {
+ return len(a) != 0
+}
+
+// Swaps arguments at the given indexes
+func (a Args) Swap(from, to int) error {
+ if from >= len(a) || to >= len(a) {
+ return errors.New("index out of range")
+ }
+ a[from], a[to] = a[to], a[from]
+ return nil
+}
+
+func lookupInt(name string, set *flag.FlagSet) int {
+ f := set.Lookup(name)
+ if f != nil {
+ val, err := strconv.Atoi(f.Value.String())
+ if err != nil {
+ return 0
+ }
+ return val
+ }
+
+ return 0
+}
+
+func lookupDuration(name string, set *flag.FlagSet) time.Duration {
+ f := set.Lookup(name)
+ if f != nil {
+ val, err := time.ParseDuration(f.Value.String())
+ if err == nil {
+ return val
+ }
+ }
+
+ return 0
+}
+
+func lookupFloat64(name string, set *flag.FlagSet) float64 {
+ f := set.Lookup(name)
+ if f != nil {
+ val, err := strconv.ParseFloat(f.Value.String(), 64)
+ if err != nil {
+ return 0
+ }
+ return val
+ }
+
+ return 0
+}
+
+func lookupString(name string, set *flag.FlagSet) string {
+ f := set.Lookup(name)
+ if f != nil {
+ return f.Value.String()
+ }
+
+ return ""
+}
+
+func lookupStringSlice(name string, set *flag.FlagSet) []string {
+ f := set.Lookup(name)
+ if f != nil {
+ return (f.Value.(*StringSlice)).Value()
+
+ }
+
+ return nil
+}
+
+func lookupIntSlice(name string, set *flag.FlagSet) []int {
+ f := set.Lookup(name)
+ if f != nil {
+ return (f.Value.(*IntSlice)).Value()
+
+ }
+
+ return nil
+}
+
+func lookupGeneric(name string, set *flag.FlagSet) interface{} {
+ f := set.Lookup(name)
+ if f != nil {
+ return f.Value
+ }
+ return nil
+}
+
+func lookupBool(name string, set *flag.FlagSet) bool {
+ f := set.Lookup(name)
+ if f != nil {
+ val, err := strconv.ParseBool(f.Value.String())
+ if err != nil {
+ return false
+ }
+ return val
+ }
+
+ return false
+}
+
+func lookupBoolT(name string, set *flag.FlagSet) bool {
+ f := set.Lookup(name)
+ if f != nil {
+ val, err := strconv.ParseBool(f.Value.String())
+ if err != nil {
+ return true
+ }
+ return val
+ }
+
+ return false
+}
+
+func copyFlag(name string, ff *flag.Flag, set *flag.FlagSet) {
+ switch ff.Value.(type) {
+ case *StringSlice:
+ default:
+ set.Set(name, ff.Value.String())
+ }
+}
+
+func normalizeFlags(flags []Flag, set *flag.FlagSet) error {
+ visited := make(map[string]bool)
+ set.Visit(func(f *flag.Flag) {
+ visited[f.Name] = true
+ })
+ for _, f := range flags {
+ parts := strings.Split(f.getName(), ",")
+ if len(parts) == 1 {
+ continue
+ }
+ var ff *flag.Flag
+ for _, name := range parts {
+ name = strings.Trim(name, " ")
+ if visited[name] {
+ if ff != nil {
+ return errors.New("Cannot use two forms of the same flag: " + name + " " + ff.Name)
+ }
+ ff = set.Lookup(name)
+ }
+ }
+ if ff == nil {
+ continue
+ }
+ for _, name := range parts {
+ name = strings.Trim(name, " ")
+ if !visited[name] {
+ copyFlag(name, ff, set)
+ }
+ }
+ }
+ return nil
+}
diff --git a/Godeps/_workspace/src/github.com/codegangsta/cli/context_test.go b/Godeps/_workspace/src/github.com/codegangsta/cli/context_test.go
new file mode 100644
index 000000000..d4a1877f0
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/codegangsta/cli/context_test.go
@@ -0,0 +1,111 @@
+package cli_test
+
+import (
+ "flag"
+ "testing"
+ "time"
+
+ "github.com/codegangsta/cli"
+)
+
+func TestNewContext(t *testing.T) {
+ set := flag.NewFlagSet("test", 0)
+ set.Int("myflag", 12, "doc")
+ globalSet := flag.NewFlagSet("test", 0)
+ globalSet.Int("myflag", 42, "doc")
+ command := cli.Command{Name: "mycommand"}
+ c := cli.NewContext(nil, set, globalSet)
+ c.Command = command
+ expect(t, c.Int("myflag"), 12)
+ expect(t, c.GlobalInt("myflag"), 42)
+ expect(t, c.Command.Name, "mycommand")
+}
+
+func TestContext_Int(t *testing.T) {
+ set := flag.NewFlagSet("test", 0)
+ set.Int("myflag", 12, "doc")
+ c := cli.NewContext(nil, set, set)
+ expect(t, c.Int("myflag"), 12)
+}
+
+func TestContext_Duration(t *testing.T) {
+ set := flag.NewFlagSet("test", 0)
+ set.Duration("myflag", time.Duration(12*time.Second), "doc")
+ c := cli.NewContext(nil, set, set)
+ expect(t, c.Duration("myflag"), time.Duration(12*time.Second))
+}
+
+func TestContext_String(t *testing.T) {
+ set := flag.NewFlagSet("test", 0)
+ set.String("myflag", "hello world", "doc")
+ c := cli.NewContext(nil, set, set)
+ expect(t, c.String("myflag"), "hello world")
+}
+
+func TestContext_Bool(t *testing.T) {
+ set := flag.NewFlagSet("test", 0)
+ set.Bool("myflag", false, "doc")
+ c := cli.NewContext(nil, set, set)
+ expect(t, c.Bool("myflag"), false)
+}
+
+func TestContext_BoolT(t *testing.T) {
+ set := flag.NewFlagSet("test", 0)
+ set.Bool("myflag", true, "doc")
+ c := cli.NewContext(nil, set, set)
+ expect(t, c.BoolT("myflag"), true)
+}
+
+func TestContext_Args(t *testing.T) {
+ set := flag.NewFlagSet("test", 0)
+ set.Bool("myflag", false, "doc")
+ c := cli.NewContext(nil, set, set)
+ set.Parse([]string{"--myflag", "bat", "baz"})
+ expect(t, len(c.Args()), 2)
+ expect(t, c.Bool("myflag"), true)
+}
+
+func TestContext_IsSet(t *testing.T) {
+ set := flag.NewFlagSet("test", 0)
+ set.Bool("myflag", false, "doc")
+ set.String("otherflag", "hello world", "doc")
+ globalSet := flag.NewFlagSet("test", 0)
+ globalSet.Bool("myflagGlobal", true, "doc")
+ c := cli.NewContext(nil, set, globalSet)
+ set.Parse([]string{"--myflag", "bat", "baz"})
+ globalSet.Parse([]string{"--myflagGlobal", "bat", "baz"})
+ expect(t, c.IsSet("myflag"), true)
+ expect(t, c.IsSet("otherflag"), false)
+ expect(t, c.IsSet("bogusflag"), false)
+ expect(t, c.IsSet("myflagGlobal"), false)
+}
+
+func TestContext_GlobalIsSet(t *testing.T) {
+ set := flag.NewFlagSet("test", 0)
+ set.Bool("myflag", false, "doc")
+ set.String("otherflag", "hello world", "doc")
+ globalSet := flag.NewFlagSet("test", 0)
+ globalSet.Bool("myflagGlobal", true, "doc")
+ globalSet.Bool("myflagGlobalUnset", true, "doc")
+ c := cli.NewContext(nil, set, globalSet)
+ set.Parse([]string{"--myflag", "bat", "baz"})
+ globalSet.Parse([]string{"--myflagGlobal", "bat", "baz"})
+ expect(t, c.GlobalIsSet("myflag"), false)
+ expect(t, c.GlobalIsSet("otherflag"), false)
+ expect(t, c.GlobalIsSet("bogusflag"), false)
+ expect(t, c.GlobalIsSet("myflagGlobal"), true)
+ expect(t, c.GlobalIsSet("myflagGlobalUnset"), false)
+ expect(t, c.GlobalIsSet("bogusGlobal"), false)
+}
+
+func TestContext_NumFlags(t *testing.T) {
+ set := flag.NewFlagSet("test", 0)
+ set.Bool("myflag", false, "doc")
+ set.String("otherflag", "hello world", "doc")
+ globalSet := flag.NewFlagSet("test", 0)
+ globalSet.Bool("myflagGlobal", true, "doc")
+ c := cli.NewContext(nil, set, globalSet)
+ set.Parse([]string{"--myflag", "--otherflag=foo"})
+ globalSet.Parse([]string{"--myflagGlobal"})
+ expect(t, c.NumFlags(), 2)
+}
diff --git a/Godeps/_workspace/src/github.com/codegangsta/cli/flag.go b/Godeps/_workspace/src/github.com/codegangsta/cli/flag.go
new file mode 100644
index 000000000..251158667
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/codegangsta/cli/flag.go
@@ -0,0 +1,454 @@
+package cli
+
+import (
+ "flag"
+ "fmt"
+ "os"
+ "strconv"
+ "strings"
+ "time"
+)
+
+// This flag enables bash-completion for all commands and subcommands
+var BashCompletionFlag = BoolFlag{
+ Name: "generate-bash-completion",
+}
+
+// This flag prints the version for the application
+var VersionFlag = BoolFlag{
+ Name: "version, v",
+ Usage: "print the version",
+}
+
+// This flag prints the help for all commands and subcommands
+// Set to the zero value (BoolFlag{}) to disable flag -- keeps subcommand
+// unless HideHelp is set to true)
+var HelpFlag = BoolFlag{
+ Name: "help, h",
+ Usage: "show help",
+}
+
+// Flag is a common interface related to parsing flags in cli.
+// For more advanced flag parsing techniques, it is recomended that
+// this interface be implemented.
+type Flag interface {
+ fmt.Stringer
+ // Apply Flag settings to the given flag set
+ Apply(*flag.FlagSet)
+ getName() string
+}
+
+func flagSet(name string, flags []Flag) *flag.FlagSet {
+ set := flag.NewFlagSet(name, flag.ContinueOnError)
+
+ for _, f := range flags {
+ f.Apply(set)
+ }
+ return set
+}
+
+func eachName(longName string, fn func(string)) {
+ parts := strings.Split(longName, ",")
+ for _, name := range parts {
+ name = strings.Trim(name, " ")
+ fn(name)
+ }
+}
+
+// Generic is a generic parseable type identified by a specific flag
+type Generic interface {
+ Set(value string) error
+ String() string
+}
+
+// GenericFlag is the flag type for types implementing Generic
+type GenericFlag struct {
+ Name string
+ Value Generic
+ Usage string
+ EnvVar string
+}
+
+// String returns the string representation of the generic flag to display the
+// help text to the user (uses the String() method of the generic flag to show
+// the value)
+func (f GenericFlag) String() string {
+ return withEnvHint(f.EnvVar, fmt.Sprintf("%s%s \"%v\"\t%v", prefixFor(f.Name), f.Name, f.Value, f.Usage))
+}
+
+// Apply takes the flagset and calls Set on the generic flag with the value
+// provided by the user for parsing by the flag
+func (f GenericFlag) Apply(set *flag.FlagSet) {
+ val := f.Value
+ if f.EnvVar != "" {
+ for _, envVar := range strings.Split(f.EnvVar, ",") {
+ envVar = strings.TrimSpace(envVar)
+ if envVal := os.Getenv(envVar); envVal != "" {
+ val.Set(envVal)
+ break
+ }
+ }
+ }
+
+ eachName(f.Name, func(name string) {
+ set.Var(f.Value, name, f.Usage)
+ })
+}
+
+func (f GenericFlag) getName() string {
+ return f.Name
+}
+
+type StringSlice []string
+
+func (f *StringSlice) Set(value string) error {
+ *f = append(*f, value)
+ return nil
+}
+
+func (f *StringSlice) String() string {
+ return fmt.Sprintf("%s", *f)
+}
+
+func (f *StringSlice) Value() []string {
+ return *f
+}
+
+type StringSliceFlag struct {
+ Name string
+ Value *StringSlice
+ Usage string
+ EnvVar string
+}
+
+func (f StringSliceFlag) String() string {
+ firstName := strings.Trim(strings.Split(f.Name, ",")[0], " ")
+ pref := prefixFor(firstName)
+ return withEnvHint(f.EnvVar, fmt.Sprintf("%s [%v]\t%v", prefixedNames(f.Name), pref+firstName+" option "+pref+firstName+" option", f.Usage))
+}
+
+func (f StringSliceFlag) Apply(set *flag.FlagSet) {
+ if f.EnvVar != "" {
+ for _, envVar := range strings.Split(f.EnvVar, ",") {
+ envVar = strings.TrimSpace(envVar)
+ if envVal := os.Getenv(envVar); envVal != "" {
+ newVal := &StringSlice{}
+ for _, s := range strings.Split(envVal, ",") {
+ s = strings.TrimSpace(s)
+ newVal.Set(s)
+ }
+ f.Value = newVal
+ break
+ }
+ }
+ }
+
+ eachName(f.Name, func(name string) {
+ set.Var(f.Value, name, f.Usage)
+ })
+}
+
+func (f StringSliceFlag) getName() string {
+ return f.Name
+}
+
+type IntSlice []int
+
+func (f *IntSlice) Set(value string) error {
+
+ tmp, err := strconv.Atoi(value)
+ if err != nil {
+ return err
+ } else {
+ *f = append(*f, tmp)
+ }
+ return nil
+}
+
+func (f *IntSlice) String() string {
+ return fmt.Sprintf("%d", *f)
+}
+
+func (f *IntSlice) Value() []int {
+ return *f
+}
+
+type IntSliceFlag struct {
+ Name string
+ Value *IntSlice
+ Usage string
+ EnvVar string
+}
+
+func (f IntSliceFlag) String() string {
+ firstName := strings.Trim(strings.Split(f.Name, ",")[0], " ")
+ pref := prefixFor(firstName)
+ return withEnvHint(f.EnvVar, fmt.Sprintf("%s [%v]\t%v", prefixedNames(f.Name), pref+firstName+" option "+pref+firstName+" option", f.Usage))
+}
+
+func (f IntSliceFlag) Apply(set *flag.FlagSet) {
+ if f.EnvVar != "" {
+ for _, envVar := range strings.Split(f.EnvVar, ",") {
+ envVar = strings.TrimSpace(envVar)
+ if envVal := os.Getenv(envVar); envVal != "" {
+ newVal := &IntSlice{}
+ for _, s := range strings.Split(envVal, ",") {
+ s = strings.TrimSpace(s)
+ err := newVal.Set(s)
+ if err != nil {
+ fmt.Fprintf(os.Stderr, err.Error())
+ }
+ }
+ f.Value = newVal
+ break
+ }
+ }
+ }
+
+ eachName(f.Name, func(name string) {
+ set.Var(f.Value, name, f.Usage)
+ })
+}
+
+func (f IntSliceFlag) getName() string {
+ return f.Name
+}
+
+type BoolFlag struct {
+ Name string
+ Usage string
+ EnvVar string
+}
+
+func (f BoolFlag) String() string {
+ return withEnvHint(f.EnvVar, fmt.Sprintf("%s\t%v", prefixedNames(f.Name), f.Usage))
+}
+
+func (f BoolFlag) Apply(set *flag.FlagSet) {
+ val := false
+ if f.EnvVar != "" {
+ for _, envVar := range strings.Split(f.EnvVar, ",") {
+ envVar = strings.TrimSpace(envVar)
+ if envVal := os.Getenv(envVar); envVal != "" {
+ envValBool, err := strconv.ParseBool(envVal)
+ if err == nil {
+ val = envValBool
+ }
+ break
+ }
+ }
+ }
+
+ eachName(f.Name, func(name string) {
+ set.Bool(name, val, f.Usage)
+ })
+}
+
+func (f BoolFlag) getName() string {
+ return f.Name
+}
+
+type BoolTFlag struct {
+ Name string
+ Usage string
+ EnvVar string
+}
+
+func (f BoolTFlag) String() string {
+ return withEnvHint(f.EnvVar, fmt.Sprintf("%s\t%v", prefixedNames(f.Name), f.Usage))
+}
+
+func (f BoolTFlag) Apply(set *flag.FlagSet) {
+ val := true
+ if f.EnvVar != "" {
+ for _, envVar := range strings.Split(f.EnvVar, ",") {
+ envVar = strings.TrimSpace(envVar)
+ if envVal := os.Getenv(envVar); envVal != "" {
+ envValBool, err := strconv.ParseBool(envVal)
+ if err == nil {
+ val = envValBool
+ break
+ }
+ }
+ }
+ }
+
+ eachName(f.Name, func(name string) {
+ set.Bool(name, val, f.Usage)
+ })
+}
+
+func (f BoolTFlag) getName() string {
+ return f.Name
+}
+
+type StringFlag struct {
+ Name string
+ Value string
+ Usage string
+ EnvVar string
+}
+
+func (f StringFlag) String() string {
+ var fmtString string
+ fmtString = "%s %v\t%v"
+
+ if len(f.Value) > 0 {
+ fmtString = "%s \"%v\"\t%v"
+ } else {
+ fmtString = "%s %v\t%v"
+ }
+
+ return withEnvHint(f.EnvVar, fmt.Sprintf(fmtString, prefixedNames(f.Name), f.Value, f.Usage))
+}
+
+func (f StringFlag) Apply(set *flag.FlagSet) {
+ if f.EnvVar != "" {
+ for _, envVar := range strings.Split(f.EnvVar, ",") {
+ envVar = strings.TrimSpace(envVar)
+ if envVal := os.Getenv(envVar); envVal != "" {
+ f.Value = envVal
+ break
+ }
+ }
+ }
+
+ eachName(f.Name, func(name string) {
+ set.String(name, f.Value, f.Usage)
+ })
+}
+
+func (f StringFlag) getName() string {
+ return f.Name
+}
+
+type IntFlag struct {
+ Name string
+ Value int
+ Usage string
+ EnvVar string
+}
+
+func (f IntFlag) String() string {
+ return withEnvHint(f.EnvVar, fmt.Sprintf("%s \"%v\"\t%v", prefixedNames(f.Name), f.Value, f.Usage))
+}
+
+func (f IntFlag) Apply(set *flag.FlagSet) {
+ if f.EnvVar != "" {
+ for _, envVar := range strings.Split(f.EnvVar, ",") {
+ envVar = strings.TrimSpace(envVar)
+ if envVal := os.Getenv(envVar); envVal != "" {
+ envValInt, err := strconv.ParseInt(envVal, 0, 64)
+ if err == nil {
+ f.Value = int(envValInt)
+ break
+ }
+ }
+ }
+ }
+
+ eachName(f.Name, func(name string) {
+ set.Int(name, f.Value, f.Usage)
+ })
+}
+
+func (f IntFlag) getName() string {
+ return f.Name
+}
+
+type DurationFlag struct {
+ Name string
+ Value time.Duration
+ Usage string
+ EnvVar string
+}
+
+func (f DurationFlag) String() string {
+ return withEnvHint(f.EnvVar, fmt.Sprintf("%s \"%v\"\t%v", prefixedNames(f.Name), f.Value, f.Usage))
+}
+
+func (f DurationFlag) Apply(set *flag.FlagSet) {
+ if f.EnvVar != "" {
+ for _, envVar := range strings.Split(f.EnvVar, ",") {
+ envVar = strings.TrimSpace(envVar)
+ if envVal := os.Getenv(envVar); envVal != "" {
+ envValDuration, err := time.ParseDuration(envVal)
+ if err == nil {
+ f.Value = envValDuration
+ break
+ }
+ }
+ }
+ }
+
+ eachName(f.Name, func(name string) {
+ set.Duration(name, f.Value, f.Usage)
+ })
+}
+
+func (f DurationFlag) getName() string {
+ return f.Name
+}
+
+type Float64Flag struct {
+ Name string
+ Value float64
+ Usage string
+ EnvVar string
+}
+
+func (f Float64Flag) String() string {
+ return withEnvHint(f.EnvVar, fmt.Sprintf("%s \"%v\"\t%v", prefixedNames(f.Name), f.Value, f.Usage))
+}
+
+func (f Float64Flag) Apply(set *flag.FlagSet) {
+ if f.EnvVar != "" {
+ for _, envVar := range strings.Split(f.EnvVar, ",") {
+ envVar = strings.TrimSpace(envVar)
+ if envVal := os.Getenv(envVar); envVal != "" {
+ envValFloat, err := strconv.ParseFloat(envVal, 10)
+ if err == nil {
+ f.Value = float64(envValFloat)
+ }
+ }
+ }
+ }
+
+ eachName(f.Name, func(name string) {
+ set.Float64(name, f.Value, f.Usage)
+ })
+}
+
+func (f Float64Flag) getName() string {
+ return f.Name
+}
+
+func prefixFor(name string) (prefix string) {
+ if len(name) == 1 {
+ prefix = "-"
+ } else {
+ prefix = "--"
+ }
+
+ return
+}
+
+func prefixedNames(fullName string) (prefixed string) {
+ parts := strings.Split(fullName, ",")
+ for i, name := range parts {
+ name = strings.Trim(name, " ")
+ prefixed += prefixFor(name) + name
+ if i < len(parts)-1 {
+ prefixed += ", "
+ }
+ }
+ return
+}
+
+func withEnvHint(envVar, str string) string {
+ envText := ""
+ if envVar != "" {
+ envText = fmt.Sprintf(" [$%s]", strings.Join(strings.Split(envVar, ","), ", $"))
+ }
+ return str + envText
+}
diff --git a/Godeps/_workspace/src/github.com/codegangsta/cli/flag_test.go b/Godeps/_workspace/src/github.com/codegangsta/cli/flag_test.go
new file mode 100644
index 000000000..f0f096a2d
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/codegangsta/cli/flag_test.go
@@ -0,0 +1,742 @@
+package cli_test
+
+import (
+ "fmt"
+ "os"
+ "reflect"
+ "strings"
+ "testing"
+
+ "github.com/codegangsta/cli"
+)
+
+var boolFlagTests = []struct {
+ name string
+ expected string
+}{
+ {"help", "--help\t"},
+ {"h", "-h\t"},
+}
+
+func TestBoolFlagHelpOutput(t *testing.T) {
+
+ for _, test := range boolFlagTests {
+ flag := cli.BoolFlag{Name: test.name}
+ output := flag.String()
+
+ if output != test.expected {
+ t.Errorf("%s does not match %s", output, test.expected)
+ }
+ }
+}
+
+var stringFlagTests = []struct {
+ name string
+ value string
+ expected string
+}{
+ {"help", "", "--help \t"},
+ {"h", "", "-h \t"},
+ {"h", "", "-h \t"},
+ {"test", "Something", "--test \"Something\"\t"},
+}
+
+func TestStringFlagHelpOutput(t *testing.T) {
+
+ for _, test := range stringFlagTests {
+ flag := cli.StringFlag{Name: test.name, Value: test.value}
+ output := flag.String()
+
+ if output != test.expected {
+ t.Errorf("%s does not match %s", output, test.expected)
+ }
+ }
+}
+
+func TestStringFlagWithEnvVarHelpOutput(t *testing.T) {
+ os.Clearenv()
+ os.Setenv("APP_FOO", "derp")
+ for _, test := range stringFlagTests {
+ flag := cli.StringFlag{Name: test.name, Value: test.value, EnvVar: "APP_FOO"}
+ output := flag.String()
+
+ if !strings.HasSuffix(output, " [$APP_FOO]") {
+ t.Errorf("%s does not end with [$APP_FOO]", output)
+ }
+ }
+}
+
+var stringSliceFlagTests = []struct {
+ name string
+ value *cli.StringSlice
+ expected string
+}{
+ {"help", func() *cli.StringSlice {
+ s := &cli.StringSlice{}
+ s.Set("")
+ return s
+ }(), "--help [--help option --help option]\t"},
+ {"h", func() *cli.StringSlice {
+ s := &cli.StringSlice{}
+ s.Set("")
+ return s
+ }(), "-h [-h option -h option]\t"},
+ {"h", func() *cli.StringSlice {
+ s := &cli.StringSlice{}
+ s.Set("")
+ return s
+ }(), "-h [-h option -h option]\t"},
+ {"test", func() *cli.StringSlice {
+ s := &cli.StringSlice{}
+ s.Set("Something")
+ return s
+ }(), "--test [--test option --test option]\t"},
+}
+
+func TestStringSliceFlagHelpOutput(t *testing.T) {
+
+ for _, test := range stringSliceFlagTests {
+ flag := cli.StringSliceFlag{Name: test.name, Value: test.value}
+ output := flag.String()
+
+ if output != test.expected {
+ t.Errorf("%q does not match %q", output, test.expected)
+ }
+ }
+}
+
+func TestStringSliceFlagWithEnvVarHelpOutput(t *testing.T) {
+ os.Clearenv()
+ os.Setenv("APP_QWWX", "11,4")
+ for _, test := range stringSliceFlagTests {
+ flag := cli.StringSliceFlag{Name: test.name, Value: test.value, EnvVar: "APP_QWWX"}
+ output := flag.String()
+
+ if !strings.HasSuffix(output, " [$APP_QWWX]") {
+ t.Errorf("%q does not end with [$APP_QWWX]", output)
+ }
+ }
+}
+
+var intFlagTests = []struct {
+ name string
+ expected string
+}{
+ {"help", "--help \"0\"\t"},
+ {"h", "-h \"0\"\t"},
+}
+
+func TestIntFlagHelpOutput(t *testing.T) {
+
+ for _, test := range intFlagTests {
+ flag := cli.IntFlag{Name: test.name}
+ output := flag.String()
+
+ if output != test.expected {
+ t.Errorf("%s does not match %s", output, test.expected)
+ }
+ }
+}
+
+func TestIntFlagWithEnvVarHelpOutput(t *testing.T) {
+ os.Clearenv()
+ os.Setenv("APP_BAR", "2")
+ for _, test := range intFlagTests {
+ flag := cli.IntFlag{Name: test.name, EnvVar: "APP_BAR"}
+ output := flag.String()
+
+ if !strings.HasSuffix(output, " [$APP_BAR]") {
+ t.Errorf("%s does not end with [$APP_BAR]", output)
+ }
+ }
+}
+
+var durationFlagTests = []struct {
+ name string
+ expected string
+}{
+ {"help", "--help \"0\"\t"},
+ {"h", "-h \"0\"\t"},
+}
+
+func TestDurationFlagHelpOutput(t *testing.T) {
+
+ for _, test := range durationFlagTests {
+ flag := cli.DurationFlag{Name: test.name}
+ output := flag.String()
+
+ if output != test.expected {
+ t.Errorf("%s does not match %s", output, test.expected)
+ }
+ }
+}
+
+func TestDurationFlagWithEnvVarHelpOutput(t *testing.T) {
+ os.Clearenv()
+ os.Setenv("APP_BAR", "2h3m6s")
+ for _, test := range durationFlagTests {
+ flag := cli.DurationFlag{Name: test.name, EnvVar: "APP_BAR"}
+ output := flag.String()
+
+ if !strings.HasSuffix(output, " [$APP_BAR]") {
+ t.Errorf("%s does not end with [$APP_BAR]", output)
+ }
+ }
+}
+
+var intSliceFlagTests = []struct {
+ name string
+ value *cli.IntSlice
+ expected string
+}{
+ {"help", &cli.IntSlice{}, "--help [--help option --help option]\t"},
+ {"h", &cli.IntSlice{}, "-h [-h option -h option]\t"},
+ {"h", &cli.IntSlice{}, "-h [-h option -h option]\t"},
+ {"test", func() *cli.IntSlice {
+ i := &cli.IntSlice{}
+ i.Set("9")
+ return i
+ }(), "--test [--test option --test option]\t"},
+}
+
+func TestIntSliceFlagHelpOutput(t *testing.T) {
+
+ for _, test := range intSliceFlagTests {
+ flag := cli.IntSliceFlag{Name: test.name, Value: test.value}
+ output := flag.String()
+
+ if output != test.expected {
+ t.Errorf("%q does not match %q", output, test.expected)
+ }
+ }
+}
+
+func TestIntSliceFlagWithEnvVarHelpOutput(t *testing.T) {
+ os.Clearenv()
+ os.Setenv("APP_SMURF", "42,3")
+ for _, test := range intSliceFlagTests {
+ flag := cli.IntSliceFlag{Name: test.name, Value: test.value, EnvVar: "APP_SMURF"}
+ output := flag.String()
+
+ if !strings.HasSuffix(output, " [$APP_SMURF]") {
+ t.Errorf("%q does not end with [$APP_SMURF]", output)
+ }
+ }
+}
+
+var float64FlagTests = []struct {
+ name string
+ expected string
+}{
+ {"help", "--help \"0\"\t"},
+ {"h", "-h \"0\"\t"},
+}
+
+func TestFloat64FlagHelpOutput(t *testing.T) {
+
+ for _, test := range float64FlagTests {
+ flag := cli.Float64Flag{Name: test.name}
+ output := flag.String()
+
+ if output != test.expected {
+ t.Errorf("%s does not match %s", output, test.expected)
+ }
+ }
+}
+
+func TestFloat64FlagWithEnvVarHelpOutput(t *testing.T) {
+ os.Clearenv()
+ os.Setenv("APP_BAZ", "99.4")
+ for _, test := range float64FlagTests {
+ flag := cli.Float64Flag{Name: test.name, EnvVar: "APP_BAZ"}
+ output := flag.String()
+
+ if !strings.HasSuffix(output, " [$APP_BAZ]") {
+ t.Errorf("%s does not end with [$APP_BAZ]", output)
+ }
+ }
+}
+
+var genericFlagTests = []struct {
+ name string
+ value cli.Generic
+ expected string
+}{
+ {"test", &Parser{"abc", "def"}, "--test \"abc,def\"\ttest flag"},
+ {"t", &Parser{"abc", "def"}, "-t \"abc,def\"\ttest flag"},
+}
+
+func TestGenericFlagHelpOutput(t *testing.T) {
+
+ for _, test := range genericFlagTests {
+ flag := cli.GenericFlag{Name: test.name, Value: test.value, Usage: "test flag"}
+ output := flag.String()
+
+ if output != test.expected {
+ t.Errorf("%q does not match %q", output, test.expected)
+ }
+ }
+}
+
+func TestGenericFlagWithEnvVarHelpOutput(t *testing.T) {
+ os.Clearenv()
+ os.Setenv("APP_ZAP", "3")
+ for _, test := range genericFlagTests {
+ flag := cli.GenericFlag{Name: test.name, EnvVar: "APP_ZAP"}
+ output := flag.String()
+
+ if !strings.HasSuffix(output, " [$APP_ZAP]") {
+ t.Errorf("%s does not end with [$APP_ZAP]", output)
+ }
+ }
+}
+
+func TestParseMultiString(t *testing.T) {
+ (&cli.App{
+ Flags: []cli.Flag{
+ cli.StringFlag{Name: "serve, s"},
+ },
+ Action: func(ctx *cli.Context) {
+ if ctx.String("serve") != "10" {
+ t.Errorf("main name not set")
+ }
+ if ctx.String("s") != "10" {
+ t.Errorf("short name not set")
+ }
+ },
+ }).Run([]string{"run", "-s", "10"})
+}
+
+func TestParseMultiStringFromEnv(t *testing.T) {
+ os.Clearenv()
+ os.Setenv("APP_COUNT", "20")
+ (&cli.App{
+ Flags: []cli.Flag{
+ cli.StringFlag{Name: "count, c", EnvVar: "APP_COUNT"},
+ },
+ Action: func(ctx *cli.Context) {
+ if ctx.String("count") != "20" {
+ t.Errorf("main name not set")
+ }
+ if ctx.String("c") != "20" {
+ t.Errorf("short name not set")
+ }
+ },
+ }).Run([]string{"run"})
+}
+
+func TestParseMultiStringFromEnvCascade(t *testing.T) {
+ os.Clearenv()
+ os.Setenv("APP_COUNT", "20")
+ (&cli.App{
+ Flags: []cli.Flag{
+ cli.StringFlag{Name: "count, c", EnvVar: "COMPAT_COUNT,APP_COUNT"},
+ },
+ Action: func(ctx *cli.Context) {
+ if ctx.String("count") != "20" {
+ t.Errorf("main name not set")
+ }
+ if ctx.String("c") != "20" {
+ t.Errorf("short name not set")
+ }
+ },
+ }).Run([]string{"run"})
+}
+
+func TestParseMultiStringSlice(t *testing.T) {
+ (&cli.App{
+ Flags: []cli.Flag{
+ cli.StringSliceFlag{Name: "serve, s", Value: &cli.StringSlice{}},
+ },
+ Action: func(ctx *cli.Context) {
+ if !reflect.DeepEqual(ctx.StringSlice("serve"), []string{"10", "20"}) {
+ t.Errorf("main name not set")
+ }
+ if !reflect.DeepEqual(ctx.StringSlice("s"), []string{"10", "20"}) {
+ t.Errorf("short name not set")
+ }
+ },
+ }).Run([]string{"run", "-s", "10", "-s", "20"})
+}
+
+func TestParseMultiStringSliceFromEnv(t *testing.T) {
+ os.Clearenv()
+ os.Setenv("APP_INTERVALS", "20,30,40")
+
+ (&cli.App{
+ Flags: []cli.Flag{
+ cli.StringSliceFlag{Name: "intervals, i", Value: &cli.StringSlice{}, EnvVar: "APP_INTERVALS"},
+ },
+ Action: func(ctx *cli.Context) {
+ if !reflect.DeepEqual(ctx.StringSlice("intervals"), []string{"20", "30", "40"}) {
+ t.Errorf("main name not set from env")
+ }
+ if !reflect.DeepEqual(ctx.StringSlice("i"), []string{"20", "30", "40"}) {
+ t.Errorf("short name not set from env")
+ }
+ },
+ }).Run([]string{"run"})
+}
+
+func TestParseMultiStringSliceFromEnvCascade(t *testing.T) {
+ os.Clearenv()
+ os.Setenv("APP_INTERVALS", "20,30,40")
+
+ (&cli.App{
+ Flags: []cli.Flag{
+ cli.StringSliceFlag{Name: "intervals, i", Value: &cli.StringSlice{}, EnvVar: "COMPAT_INTERVALS,APP_INTERVALS"},
+ },
+ Action: func(ctx *cli.Context) {
+ if !reflect.DeepEqual(ctx.StringSlice("intervals"), []string{"20", "30", "40"}) {
+ t.Errorf("main name not set from env")
+ }
+ if !reflect.DeepEqual(ctx.StringSlice("i"), []string{"20", "30", "40"}) {
+ t.Errorf("short name not set from env")
+ }
+ },
+ }).Run([]string{"run"})
+}
+
+func TestParseMultiInt(t *testing.T) {
+ a := cli.App{
+ Flags: []cli.Flag{
+ cli.IntFlag{Name: "serve, s"},
+ },
+ Action: func(ctx *cli.Context) {
+ if ctx.Int("serve") != 10 {
+ t.Errorf("main name not set")
+ }
+ if ctx.Int("s") != 10 {
+ t.Errorf("short name not set")
+ }
+ },
+ }
+ a.Run([]string{"run", "-s", "10"})
+}
+
+func TestParseMultiIntFromEnv(t *testing.T) {
+ os.Clearenv()
+ os.Setenv("APP_TIMEOUT_SECONDS", "10")
+ a := cli.App{
+ Flags: []cli.Flag{
+ cli.IntFlag{Name: "timeout, t", EnvVar: "APP_TIMEOUT_SECONDS"},
+ },
+ Action: func(ctx *cli.Context) {
+ if ctx.Int("timeout") != 10 {
+ t.Errorf("main name not set")
+ }
+ if ctx.Int("t") != 10 {
+ t.Errorf("short name not set")
+ }
+ },
+ }
+ a.Run([]string{"run"})
+}
+
+func TestParseMultiIntFromEnvCascade(t *testing.T) {
+ os.Clearenv()
+ os.Setenv("APP_TIMEOUT_SECONDS", "10")
+ a := cli.App{
+ Flags: []cli.Flag{
+ cli.IntFlag{Name: "timeout, t", EnvVar: "COMPAT_TIMEOUT_SECONDS,APP_TIMEOUT_SECONDS"},
+ },
+ Action: func(ctx *cli.Context) {
+ if ctx.Int("timeout") != 10 {
+ t.Errorf("main name not set")
+ }
+ if ctx.Int("t") != 10 {
+ t.Errorf("short name not set")
+ }
+ },
+ }
+ a.Run([]string{"run"})
+}
+
+func TestParseMultiIntSlice(t *testing.T) {
+ (&cli.App{
+ Flags: []cli.Flag{
+ cli.IntSliceFlag{Name: "serve, s", Value: &cli.IntSlice{}},
+ },
+ Action: func(ctx *cli.Context) {
+ if !reflect.DeepEqual(ctx.IntSlice("serve"), []int{10, 20}) {
+ t.Errorf("main name not set")
+ }
+ if !reflect.DeepEqual(ctx.IntSlice("s"), []int{10, 20}) {
+ t.Errorf("short name not set")
+ }
+ },
+ }).Run([]string{"run", "-s", "10", "-s", "20"})
+}
+
+func TestParseMultiIntSliceFromEnv(t *testing.T) {
+ os.Clearenv()
+ os.Setenv("APP_INTERVALS", "20,30,40")
+
+ (&cli.App{
+ Flags: []cli.Flag{
+ cli.IntSliceFlag{Name: "intervals, i", Value: &cli.IntSlice{}, EnvVar: "APP_INTERVALS"},
+ },
+ Action: func(ctx *cli.Context) {
+ if !reflect.DeepEqual(ctx.IntSlice("intervals"), []int{20, 30, 40}) {
+ t.Errorf("main name not set from env")
+ }
+ if !reflect.DeepEqual(ctx.IntSlice("i"), []int{20, 30, 40}) {
+ t.Errorf("short name not set from env")
+ }
+ },
+ }).Run([]string{"run"})
+}
+
+func TestParseMultiIntSliceFromEnvCascade(t *testing.T) {
+ os.Clearenv()
+ os.Setenv("APP_INTERVALS", "20,30,40")
+
+ (&cli.App{
+ Flags: []cli.Flag{
+ cli.IntSliceFlag{Name: "intervals, i", Value: &cli.IntSlice{}, EnvVar: "COMPAT_INTERVALS,APP_INTERVALS"},
+ },
+ Action: func(ctx *cli.Context) {
+ if !reflect.DeepEqual(ctx.IntSlice("intervals"), []int{20, 30, 40}) {
+ t.Errorf("main name not set from env")
+ }
+ if !reflect.DeepEqual(ctx.IntSlice("i"), []int{20, 30, 40}) {
+ t.Errorf("short name not set from env")
+ }
+ },
+ }).Run([]string{"run"})
+}
+
+func TestParseMultiFloat64(t *testing.T) {
+ a := cli.App{
+ Flags: []cli.Flag{
+ cli.Float64Flag{Name: "serve, s"},
+ },
+ Action: func(ctx *cli.Context) {
+ if ctx.Float64("serve") != 10.2 {
+ t.Errorf("main name not set")
+ }
+ if ctx.Float64("s") != 10.2 {
+ t.Errorf("short name not set")
+ }
+ },
+ }
+ a.Run([]string{"run", "-s", "10.2"})
+}
+
+func TestParseMultiFloat64FromEnv(t *testing.T) {
+ os.Clearenv()
+ os.Setenv("APP_TIMEOUT_SECONDS", "15.5")
+ a := cli.App{
+ Flags: []cli.Flag{
+ cli.Float64Flag{Name: "timeout, t", EnvVar: "APP_TIMEOUT_SECONDS"},
+ },
+ Action: func(ctx *cli.Context) {
+ if ctx.Float64("timeout") != 15.5 {
+ t.Errorf("main name not set")
+ }
+ if ctx.Float64("t") != 15.5 {
+ t.Errorf("short name not set")
+ }
+ },
+ }
+ a.Run([]string{"run"})
+}
+
+func TestParseMultiFloat64FromEnvCascade(t *testing.T) {
+ os.Clearenv()
+ os.Setenv("APP_TIMEOUT_SECONDS", "15.5")
+ a := cli.App{
+ Flags: []cli.Flag{
+ cli.Float64Flag{Name: "timeout, t", EnvVar: "COMPAT_TIMEOUT_SECONDS,APP_TIMEOUT_SECONDS"},
+ },
+ Action: func(ctx *cli.Context) {
+ if ctx.Float64("timeout") != 15.5 {
+ t.Errorf("main name not set")
+ }
+ if ctx.Float64("t") != 15.5 {
+ t.Errorf("short name not set")
+ }
+ },
+ }
+ a.Run([]string{"run"})
+}
+
+func TestParseMultiBool(t *testing.T) {
+ a := cli.App{
+ Flags: []cli.Flag{
+ cli.BoolFlag{Name: "serve, s"},
+ },
+ Action: func(ctx *cli.Context) {
+ if ctx.Bool("serve") != true {
+ t.Errorf("main name not set")
+ }
+ if ctx.Bool("s") != true {
+ t.Errorf("short name not set")
+ }
+ },
+ }
+ a.Run([]string{"run", "--serve"})
+}
+
+func TestParseMultiBoolFromEnv(t *testing.T) {
+ os.Clearenv()
+ os.Setenv("APP_DEBUG", "1")
+ a := cli.App{
+ Flags: []cli.Flag{
+ cli.BoolFlag{Name: "debug, d", EnvVar: "APP_DEBUG"},
+ },
+ Action: func(ctx *cli.Context) {
+ if ctx.Bool("debug") != true {
+ t.Errorf("main name not set from env")
+ }
+ if ctx.Bool("d") != true {
+ t.Errorf("short name not set from env")
+ }
+ },
+ }
+ a.Run([]string{"run"})
+}
+
+func TestParseMultiBoolFromEnvCascade(t *testing.T) {
+ os.Clearenv()
+ os.Setenv("APP_DEBUG", "1")
+ a := cli.App{
+ Flags: []cli.Flag{
+ cli.BoolFlag{Name: "debug, d", EnvVar: "COMPAT_DEBUG,APP_DEBUG"},
+ },
+ Action: func(ctx *cli.Context) {
+ if ctx.Bool("debug") != true {
+ t.Errorf("main name not set from env")
+ }
+ if ctx.Bool("d") != true {
+ t.Errorf("short name not set from env")
+ }
+ },
+ }
+ a.Run([]string{"run"})
+}
+
+func TestParseMultiBoolT(t *testing.T) {
+ a := cli.App{
+ Flags: []cli.Flag{
+ cli.BoolTFlag{Name: "serve, s"},
+ },
+ Action: func(ctx *cli.Context) {
+ if ctx.BoolT("serve") != true {
+ t.Errorf("main name not set")
+ }
+ if ctx.BoolT("s") != true {
+ t.Errorf("short name not set")
+ }
+ },
+ }
+ a.Run([]string{"run", "--serve"})
+}
+
+func TestParseMultiBoolTFromEnv(t *testing.T) {
+ os.Clearenv()
+ os.Setenv("APP_DEBUG", "0")
+ a := cli.App{
+ Flags: []cli.Flag{
+ cli.BoolTFlag{Name: "debug, d", EnvVar: "APP_DEBUG"},
+ },
+ Action: func(ctx *cli.Context) {
+ if ctx.BoolT("debug") != false {
+ t.Errorf("main name not set from env")
+ }
+ if ctx.BoolT("d") != false {
+ t.Errorf("short name not set from env")
+ }
+ },
+ }
+ a.Run([]string{"run"})
+}
+
+func TestParseMultiBoolTFromEnvCascade(t *testing.T) {
+ os.Clearenv()
+ os.Setenv("APP_DEBUG", "0")
+ a := cli.App{
+ Flags: []cli.Flag{
+ cli.BoolTFlag{Name: "debug, d", EnvVar: "COMPAT_DEBUG,APP_DEBUG"},
+ },
+ Action: func(ctx *cli.Context) {
+ if ctx.BoolT("debug") != false {
+ t.Errorf("main name not set from env")
+ }
+ if ctx.BoolT("d") != false {
+ t.Errorf("short name not set from env")
+ }
+ },
+ }
+ a.Run([]string{"run"})
+}
+
+type Parser [2]string
+
+func (p *Parser) Set(value string) error {
+ parts := strings.Split(value, ",")
+ if len(parts) != 2 {
+ return fmt.Errorf("invalid format")
+ }
+
+ (*p)[0] = parts[0]
+ (*p)[1] = parts[1]
+
+ return nil
+}
+
+func (p *Parser) String() string {
+ return fmt.Sprintf("%s,%s", p[0], p[1])
+}
+
+func TestParseGeneric(t *testing.T) {
+ a := cli.App{
+ Flags: []cli.Flag{
+ cli.GenericFlag{Name: "serve, s", Value: &Parser{}},
+ },
+ Action: func(ctx *cli.Context) {
+ if !reflect.DeepEqual(ctx.Generic("serve"), &Parser{"10", "20"}) {
+ t.Errorf("main name not set")
+ }
+ if !reflect.DeepEqual(ctx.Generic("s"), &Parser{"10", "20"}) {
+ t.Errorf("short name not set")
+ }
+ },
+ }
+ a.Run([]string{"run", "-s", "10,20"})
+}
+
+func TestParseGenericFromEnv(t *testing.T) {
+ os.Clearenv()
+ os.Setenv("APP_SERVE", "20,30")
+ a := cli.App{
+ Flags: []cli.Flag{
+ cli.GenericFlag{Name: "serve, s", Value: &Parser{}, EnvVar: "APP_SERVE"},
+ },
+ Action: func(ctx *cli.Context) {
+ if !reflect.DeepEqual(ctx.Generic("serve"), &Parser{"20", "30"}) {
+ t.Errorf("main name not set from env")
+ }
+ if !reflect.DeepEqual(ctx.Generic("s"), &Parser{"20", "30"}) {
+ t.Errorf("short name not set from env")
+ }
+ },
+ }
+ a.Run([]string{"run"})
+}
+
+func TestParseGenericFromEnvCascade(t *testing.T) {
+ os.Clearenv()
+ os.Setenv("APP_FOO", "99,2000")
+ a := cli.App{
+ Flags: []cli.Flag{
+ cli.GenericFlag{Name: "foos", Value: &Parser{}, EnvVar: "COMPAT_FOO,APP_FOO"},
+ },
+ Action: func(ctx *cli.Context) {
+ if !reflect.DeepEqual(ctx.Generic("foos"), &Parser{"99", "2000"}) {
+ t.Errorf("value not set from env")
+ }
+ },
+ }
+ a.Run([]string{"run"})
+}
diff --git a/Godeps/_workspace/src/github.com/codegangsta/cli/help.go b/Godeps/_workspace/src/github.com/codegangsta/cli/help.go
new file mode 100644
index 000000000..7c4f81be6
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/codegangsta/cli/help.go
@@ -0,0 +1,215 @@
+package cli
+
+import "fmt"
+
+// The text template for the Default help topic.
+// cli.go uses text/template to render templates. You can
+// render custom help text by setting this variable.
+var AppHelpTemplate = `NAME:
+ {{.Name}} - {{.Usage}}
+
+USAGE:
+ {{.Name}} {{if .Flags}}[global options] {{end}}command{{if .Flags}} [command options]{{end}} [arguments...]
+
+VERSION:
+ {{.Version}}
+
+AUTHOR(S):
+ {{range .Authors}}{{ . }}
+ {{end}}
+COMMANDS:
+ {{range .Commands}}{{join .Names ", "}}{{ "\t" }}{{.Usage}}
+ {{end}}{{if .Flags}}
+GLOBAL OPTIONS:
+ {{range .Flags}}{{.}}
+ {{end}}{{end}}
+`
+
+// The text template for the command help topic.
+// cli.go uses text/template to render templates. You can
+// render custom help text by setting this variable.
+var CommandHelpTemplate = `NAME:
+ {{.Name}} - {{.Usage}}
+
+USAGE:
+ command {{.Name}}{{if .Flags}} [command options]{{end}} [arguments...]{{if .Description}}
+
+DESCRIPTION:
+ {{.Description}}{{end}}{{if .Flags}}
+
+OPTIONS:
+ {{range .Flags}}{{.}}
+ {{end}}{{ end }}
+`
+
+// The text template for the subcommand help topic.
+// cli.go uses text/template to render templates. You can
+// render custom help text by setting this variable.
+var SubcommandHelpTemplate = `NAME:
+ {{.Name}} - {{.Usage}}
+
+USAGE:
+ {{.Name}} command{{if .Flags}} [command options]{{end}} [arguments...]
+
+COMMANDS:
+ {{range .Commands}}{{join .Names ", "}}{{ "\t" }}{{.Usage}}
+ {{end}}{{if .Flags}}
+OPTIONS:
+ {{range .Flags}}{{.}}
+ {{end}}{{end}}
+`
+
+var helpCommand = Command{
+ Name: "help",
+ Aliases: []string{"h"},
+ Usage: "Shows a list of commands or help for one command",
+ Action: func(c *Context) {
+ args := c.Args()
+ if args.Present() {
+ ShowCommandHelp(c, args.First())
+ } else {
+ ShowAppHelp(c)
+ }
+ },
+}
+
+var helpSubcommand = Command{
+ Name: "help",
+ Aliases: []string{"h"},
+ Usage: "Shows a list of commands or help for one command",
+ Action: func(c *Context) {
+ args := c.Args()
+ if args.Present() {
+ ShowCommandHelp(c, args.First())
+ } else {
+ ShowSubcommandHelp(c)
+ }
+ },
+}
+
+// Prints help for the App
+type helpPrinter func(templ string, data interface{})
+
+var HelpPrinter helpPrinter = nil
+
+// Prints version for the App
+var VersionPrinter = printVersion
+
+func ShowAppHelp(c *Context) {
+ HelpPrinter(AppHelpTemplate, c.App)
+}
+
+// Prints the list of subcommands as the default app completion method
+func DefaultAppComplete(c *Context) {
+ for _, command := range c.App.Commands {
+ for _, name := range command.Names() {
+ fmt.Fprintln(c.App.Writer, name)
+ }
+ }
+}
+
+// Prints help for the given command
+func ShowCommandHelp(c *Context, command string) {
+ // show the subcommand help for a command with subcommands
+ if command == "" {
+ HelpPrinter(SubcommandHelpTemplate, c.App)
+ return
+ }
+
+ for _, c := range c.App.Commands {
+ if c.HasName(command) {
+ HelpPrinter(CommandHelpTemplate, c)
+ return
+ }
+ }
+
+ if c.App.CommandNotFound != nil {
+ c.App.CommandNotFound(c, command)
+ } else {
+ fmt.Fprintf(c.App.Writer, "No help topic for '%v'\n", command)
+ }
+}
+
+// Prints help for the given subcommand
+func ShowSubcommandHelp(c *Context) {
+ ShowCommandHelp(c, c.Command.Name)
+}
+
+// Prints the version number of the App
+func ShowVersion(c *Context) {
+ VersionPrinter(c)
+}
+
+func printVersion(c *Context) {
+ fmt.Fprintf(c.App.Writer, "%v version %v\n", c.App.Name, c.App.Version)
+}
+
+// Prints the lists of commands within a given context
+func ShowCompletions(c *Context) {
+ a := c.App
+ if a != nil && a.BashComplete != nil {
+ a.BashComplete(c)
+ }
+}
+
+// Prints the custom completions for a given command
+func ShowCommandCompletions(ctx *Context, command string) {
+ c := ctx.App.Command(command)
+ if c != nil && c.BashComplete != nil {
+ c.BashComplete(ctx)
+ }
+}
+
+func checkVersion(c *Context) bool {
+ if c.GlobalBool("version") {
+ ShowVersion(c)
+ return true
+ }
+
+ return false
+}
+
+func checkHelp(c *Context) bool {
+ if c.GlobalBool("h") || c.GlobalBool("help") {
+ ShowAppHelp(c)
+ return true
+ }
+
+ return false
+}
+
+func checkCommandHelp(c *Context, name string) bool {
+ if c.Bool("h") || c.Bool("help") {
+ ShowCommandHelp(c, name)
+ return true
+ }
+
+ return false
+}
+
+func checkSubcommandHelp(c *Context) bool {
+ if c.GlobalBool("h") || c.GlobalBool("help") {
+ ShowSubcommandHelp(c)
+ return true
+ }
+
+ return false
+}
+
+func checkCompletions(c *Context) bool {
+ if (c.GlobalBool(BashCompletionFlag.Name) || c.Bool(BashCompletionFlag.Name)) && c.App.EnableBashCompletion {
+ ShowCompletions(c)
+ return true
+ }
+
+ return false
+}
+
+func checkCommandCompletions(c *Context, name string) bool {
+ if c.Bool(BashCompletionFlag.Name) && c.App.EnableBashCompletion {
+ ShowCommandCompletions(c, name)
+ return true
+ }
+
+ return false
+}
diff --git a/Godeps/_workspace/src/github.com/codegangsta/cli/helpers_test.go b/Godeps/_workspace/src/github.com/codegangsta/cli/helpers_test.go
new file mode 100644
index 000000000..cdc4feb2f
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/codegangsta/cli/helpers_test.go
@@ -0,0 +1,19 @@
+package cli_test
+
+import (
+ "reflect"
+ "testing"
+)
+
+/* Test Helpers */
+func expect(t *testing.T, a interface{}, b interface{}) {
+ if a != b {
+ t.Errorf("Expected %v (type %v) - Got %v (type %v)", b, reflect.TypeOf(b), a, reflect.TypeOf(a))
+ }
+}
+
+func refute(t *testing.T, a interface{}, b interface{}) {
+ if a == b {
+ t.Errorf("Did not expect %v (type %v) - Got %v (type %v)", b, reflect.TypeOf(b), a, reflect.TypeOf(a))
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/ethereum/ethash/.gitignore b/Godeps/_workspace/src/github.com/ethereum/ethash/.gitignore
new file mode 100644
index 000000000..da074e6b3
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/ethash/.gitignore
@@ -0,0 +1,12 @@
+.idea/
+.DS_Store
+*/**/*un~
+.vagrant/
+*.pyc
+build/
+pyethash.egg-info/
+*.so
+*~
+*.swp
+MANIFEST
+dist/
diff --git a/Godeps/_workspace/src/github.com/ethereum/ethash/.travis.yml b/Godeps/_workspace/src/github.com/ethereum/ethash/.travis.yml
new file mode 100644
index 000000000..4b929eb69
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/ethash/.travis.yml
@@ -0,0 +1,6 @@
+before_install:
+ - sudo apt-get update -qq
+ - sudo apt-get install -qq wget cmake gcc bash libboost-test-dev nodejs python-pip python-dev
+ - sudo pip install virtualenv -q
+
+script: "./test/test.sh"
diff --git a/Godeps/_workspace/src/github.com/ethereum/ethash/CMakeLists.txt b/Godeps/_workspace/src/github.com/ethereum/ethash/CMakeLists.txt
new file mode 100644
index 000000000..79f2e5335
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/ethash/CMakeLists.txt
@@ -0,0 +1,21 @@
+cmake_minimum_required(VERSION 2.8.7)
+project(ethash)
+
+set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${CMAKE_SOURCE_DIR}/cmake/modules/")
+set(ETHHASH_LIBS ethash)
+
+if (WIN32 AND WANT_CRYPTOPP)
+ add_subdirectory(cryptopp)
+endif()
+
+add_subdirectory(src/libethash)
+# bin2h.cmake doesn't work
+if (NOT OpenCL_FOUND)
+ find_package(OpenCL)
+endif()
+
+if (OpenCL_FOUND)
+ add_subdirectory(src/libethash-cl)
+endif()
+add_subdirectory(src/benchmark EXCLUDE_FROM_ALL)
+add_subdirectory(test/c EXCLUDE_FROM_ALL)
diff --git a/Godeps/_workspace/src/github.com/ethereum/ethash/MANIFEST.in b/Godeps/_workspace/src/github.com/ethereum/ethash/MANIFEST.in
new file mode 100644
index 000000000..74e73c8be
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/ethash/MANIFEST.in
@@ -0,0 +1,17 @@
+include setup.py
+
+# C sources
+include src/libethash/internal.c
+include src/libethash/sha3.c
+include src/libethash/util.c
+include src/python/core.c
+
+# Headers
+include src/libethash/compiler.h
+include src/libethash/data_sizes.h
+include src/libethash/endian.h
+include src/libethash/ethash.h
+include src/libethash/fnv.h
+include src/libethash/internal.h
+include src/libethash/sha3.h
+include src/libethash/util.h
diff --git a/Godeps/_workspace/src/github.com/ethereum/ethash/Makefile b/Godeps/_workspace/src/github.com/ethereum/ethash/Makefile
new file mode 100644
index 000000000..741d3b56d
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/ethash/Makefile
@@ -0,0 +1,6 @@
+.PHONY: clean test
+test:
+ ./test/test.sh
+
+clean:
+ rm -rf *.so pyethash.egg-info/ build/ test/python/python-virtual-env/ test/c/build/ pyethash.so test/python/*.pyc dist/ MANIFEST
diff --git a/Godeps/_workspace/src/github.com/ethereum/ethash/README.md b/Godeps/_workspace/src/github.com/ethereum/ethash/README.md
new file mode 100644
index 000000000..8b9e015cf
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/ethash/README.md
@@ -0,0 +1,7 @@
+[![Build Status](https://travis-ci.org/ethereum/ethash.svg?branch=master)](https://travis-ci.org/ethereum/ethash)
+
+
+# Ethash
+
+For details on this project, please see the Ethereum wiki:
+https://github.com/ethereum/wiki/wiki/Ethash
diff --git a/Godeps/_workspace/src/github.com/ethereum/ethash/Vagrantfile b/Godeps/_workspace/src/github.com/ethereum/ethash/Vagrantfile
new file mode 100644
index 000000000..03891653f
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/ethash/Vagrantfile
@@ -0,0 +1,7 @@
+# -*- mode: ruby -*-
+# vi: set ft=ruby :
+
+Vagrant.configure(2) do |config|
+ config.vm.box = "Ubuntu 12.04"
+ config.vm.box_url = "https://cloud-images.ubuntu.com/vagrant/precise/current/precise-server-cloudimg-amd64-vagrant-disk1.box"
+end
diff --git a/Godeps/_workspace/src/github.com/ethereum/ethash/cmake/modules/CMakeParseArguments.cmake b/Godeps/_workspace/src/github.com/ethereum/ethash/cmake/modules/CMakeParseArguments.cmake
new file mode 100644
index 000000000..8553f38f5
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/ethash/cmake/modules/CMakeParseArguments.cmake
@@ -0,0 +1,161 @@
+#.rst:
+# CMakeParseArguments
+# -------------------
+#
+#
+#
+# CMAKE_PARSE_ARGUMENTS(<prefix> <options> <one_value_keywords>
+# <multi_value_keywords> args...)
+#
+# CMAKE_PARSE_ARGUMENTS() is intended to be used in macros or functions
+# for parsing the arguments given to that macro or function. It
+# processes the arguments and defines a set of variables which hold the
+# values of the respective options.
+#
+# The <options> argument contains all options for the respective macro,
+# i.e. keywords which can be used when calling the macro without any
+# value following, like e.g. the OPTIONAL keyword of the install()
+# command.
+#
+# The <one_value_keywords> argument contains all keywords for this macro
+# which are followed by one value, like e.g. DESTINATION keyword of the
+# install() command.
+#
+# The <multi_value_keywords> argument contains all keywords for this
+# macro which can be followed by more than one value, like e.g. the
+# TARGETS or FILES keywords of the install() command.
+#
+# When done, CMAKE_PARSE_ARGUMENTS() will have defined for each of the
+# keywords listed in <options>, <one_value_keywords> and
+# <multi_value_keywords> a variable composed of the given <prefix>
+# followed by "_" and the name of the respective keyword. These
+# variables will then hold the respective value from the argument list.
+# For the <options> keywords this will be TRUE or FALSE.
+#
+# All remaining arguments are collected in a variable
+# <prefix>_UNPARSED_ARGUMENTS, this can be checked afterwards to see
+# whether your macro was called with unrecognized parameters.
+#
+# As an example here a my_install() macro, which takes similar arguments
+# as the real install() command:
+#
+# ::
+#
+# function(MY_INSTALL)
+# set(options OPTIONAL FAST)
+# set(oneValueArgs DESTINATION RENAME)
+# set(multiValueArgs TARGETS CONFIGURATIONS)
+# cmake_parse_arguments(MY_INSTALL "${options}" "${oneValueArgs}"
+# "${multiValueArgs}" ${ARGN} )
+# ...
+#
+#
+#
+# Assume my_install() has been called like this:
+#
+# ::
+#
+# my_install(TARGETS foo bar DESTINATION bin OPTIONAL blub)
+#
+#
+#
+# After the cmake_parse_arguments() call the macro will have set the
+# following variables:
+#
+# ::
+#
+# MY_INSTALL_OPTIONAL = TRUE
+# MY_INSTALL_FAST = FALSE (this option was not used when calling my_install()
+# MY_INSTALL_DESTINATION = "bin"
+# MY_INSTALL_RENAME = "" (was not used)
+# MY_INSTALL_TARGETS = "foo;bar"
+# MY_INSTALL_CONFIGURATIONS = "" (was not used)
+# MY_INSTALL_UNPARSED_ARGUMENTS = "blub" (no value expected after "OPTIONAL"
+#
+#
+#
+# You can then continue and process these variables.
+#
+# Keywords terminate lists of values, e.g. if directly after a
+# one_value_keyword another recognized keyword follows, this is
+# interpreted as the beginning of the new option. E.g.
+# my_install(TARGETS foo DESTINATION OPTIONAL) would result in
+# MY_INSTALL_DESTINATION set to "OPTIONAL", but MY_INSTALL_DESTINATION
+# would be empty and MY_INSTALL_OPTIONAL would be set to TRUE therefor.
+
+#=============================================================================
+# Copyright 2010 Alexander Neundorf <neundorf@kde.org>
+#
+# Distributed under the OSI-approved BSD License (the "License");
+# see accompanying file Copyright.txt for details.
+#
+# This software is distributed WITHOUT ANY WARRANTY; without even the
+# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
+# See the License for more information.
+#=============================================================================
+# (To distribute this file outside of CMake, substitute the full
+# License text for the above reference.)
+
+
+if(__CMAKE_PARSE_ARGUMENTS_INCLUDED)
+ return()
+endif()
+set(__CMAKE_PARSE_ARGUMENTS_INCLUDED TRUE)
+
+
+function(CMAKE_PARSE_ARGUMENTS prefix _optionNames _singleArgNames _multiArgNames)
+ # first set all result variables to empty/FALSE
+ foreach(arg_name ${_singleArgNames} ${_multiArgNames})
+ set(${prefix}_${arg_name})
+ endforeach()
+
+ foreach(option ${_optionNames})
+ set(${prefix}_${option} FALSE)
+ endforeach()
+
+ set(${prefix}_UNPARSED_ARGUMENTS)
+
+ set(insideValues FALSE)
+ set(currentArgName)
+
+ # now iterate over all arguments and fill the result variables
+ foreach(currentArg ${ARGN})
+ list(FIND _optionNames "${currentArg}" optionIndex) # ... then this marks the end of the arguments belonging to this keyword
+ list(FIND _singleArgNames "${currentArg}" singleArgIndex) # ... then this marks the end of the arguments belonging to this keyword
+ list(FIND _multiArgNames "${currentArg}" multiArgIndex) # ... then this marks the end of the arguments belonging to this keyword
+
+ if(${optionIndex} EQUAL -1 AND ${singleArgIndex} EQUAL -1 AND ${multiArgIndex} EQUAL -1)
+ if(insideValues)
+ if("${insideValues}" STREQUAL "SINGLE")
+ set(${prefix}_${currentArgName} ${currentArg})
+ set(insideValues FALSE)
+ elseif("${insideValues}" STREQUAL "MULTI")
+ list(APPEND ${prefix}_${currentArgName} ${currentArg})
+ endif()
+ else()
+ list(APPEND ${prefix}_UNPARSED_ARGUMENTS ${currentArg})
+ endif()
+ else()
+ if(NOT ${optionIndex} EQUAL -1)
+ set(${prefix}_${currentArg} TRUE)
+ set(insideValues FALSE)
+ elseif(NOT ${singleArgIndex} EQUAL -1)
+ set(currentArgName ${currentArg})
+ set(${prefix}_${currentArgName})
+ set(insideValues "SINGLE")
+ elseif(NOT ${multiArgIndex} EQUAL -1)
+ set(currentArgName ${currentArg})
+ set(${prefix}_${currentArgName})
+ set(insideValues "MULTI")
+ endif()
+ endif()
+
+ endforeach()
+
+ # propagate the result variables to the caller:
+ foreach(arg_name ${_singleArgNames} ${_multiArgNames} ${_optionNames})
+ set(${prefix}_${arg_name} ${${prefix}_${arg_name}} PARENT_SCOPE)
+ endforeach()
+ set(${prefix}_UNPARSED_ARGUMENTS ${${prefix}_UNPARSED_ARGUMENTS} PARENT_SCOPE)
+
+endfunction()
diff --git a/Godeps/_workspace/src/github.com/ethereum/ethash/cmake/modules/FindCryptoPP.cmake b/Godeps/_workspace/src/github.com/ethereum/ethash/cmake/modules/FindCryptoPP.cmake
new file mode 100644
index 000000000..5ca01e446
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/ethash/cmake/modules/FindCryptoPP.cmake
@@ -0,0 +1,108 @@
+# Module for locating the Crypto++ encryption library.
+#
+# Customizable variables:
+# CRYPTOPP_ROOT_DIR
+# This variable points to the CryptoPP root directory. On Windows the
+# library location typically will have to be provided explicitly using the
+# -D command-line option. The directory should include the include/cryptopp,
+# lib and/or bin sub-directories.
+#
+# Read-only variables:
+# CRYPTOPP_FOUND
+# Indicates whether the library has been found.
+#
+# CRYPTOPP_INCLUDE_DIRS
+# Points to the CryptoPP include directory.
+#
+# CRYPTOPP_LIBRARIES
+# Points to the CryptoPP libraries that should be passed to
+# target_link_libararies.
+#
+#
+# Copyright (c) 2012 Sergiu Dotenco
+#
+# Permission is hereby granted, free of charge, to any person obtaining a copy
+# of this software and associated documentation files (the "Software"), to deal
+# in the Software without restriction, including without limitation the rights
+# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+# copies of the Software, and to permit persons to whom the Software is
+# furnished to do so, subject to the following conditions:
+#
+# The above copyright notice and this permission notice shall be included in all
+# copies or substantial portions of the Software.
+#
+# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+# SOFTWARE.
+
+INCLUDE (FindPackageHandleStandardArgs)
+
+FIND_PATH (CRYPTOPP_ROOT_DIR
+ NAMES cryptopp/cryptlib.h include/cryptopp/cryptlib.h
+ PATHS ENV CRYPTOPPROOT
+ DOC "CryptoPP root directory")
+
+# Re-use the previous path:
+FIND_PATH (CRYPTOPP_INCLUDE_DIR
+ NAMES cryptopp/cryptlib.h
+ HINTS ${CRYPTOPP_ROOT_DIR}
+ PATH_SUFFIXES include
+ DOC "CryptoPP include directory")
+
+FIND_LIBRARY (CRYPTOPP_LIBRARY_DEBUG
+ NAMES cryptlibd cryptoppd
+ HINTS ${CRYPTOPP_ROOT_DIR}
+ PATH_SUFFIXES lib
+ DOC "CryptoPP debug library")
+
+FIND_LIBRARY (CRYPTOPP_LIBRARY_RELEASE
+ NAMES cryptlib cryptopp
+ HINTS ${CRYPTOPP_ROOT_DIR}
+ PATH_SUFFIXES lib
+ DOC "CryptoPP release library")
+
+IF (CRYPTOPP_LIBRARY_DEBUG AND CRYPTOPP_LIBRARY_RELEASE)
+ SET (CRYPTOPP_LIBRARY
+ optimized ${CRYPTOPP_LIBRARY_RELEASE}
+ debug ${CRYPTOPP_LIBRARY_DEBUG} CACHE DOC "CryptoPP library")
+ELSEIF (CRYPTOPP_LIBRARY_RELEASE)
+ SET (CRYPTOPP_LIBRARY ${CRYPTOPP_LIBRARY_RELEASE} CACHE DOC
+ "CryptoPP library")
+ENDIF (CRYPTOPP_LIBRARY_DEBUG AND CRYPTOPP_LIBRARY_RELEASE)
+
+IF (CRYPTOPP_INCLUDE_DIR)
+ SET (_CRYPTOPP_VERSION_HEADER ${CRYPTOPP_INCLUDE_DIR}/cryptopp/config.h)
+
+ IF (EXISTS ${_CRYPTOPP_VERSION_HEADER})
+ FILE (STRINGS ${_CRYPTOPP_VERSION_HEADER} _CRYPTOPP_VERSION_TMP REGEX
+ "^#define CRYPTOPP_VERSION[ \t]+[0-9]+$")
+
+ STRING (REGEX REPLACE
+ "^#define CRYPTOPP_VERSION[ \t]+([0-9]+)" "\\1" _CRYPTOPP_VERSION_TMP
+ ${_CRYPTOPP_VERSION_TMP})
+
+ STRING (REGEX REPLACE "([0-9]+)[0-9][0-9]" "\\1" CRYPTOPP_VERSION_MAJOR
+ ${_CRYPTOPP_VERSION_TMP})
+ STRING (REGEX REPLACE "[0-9]([0-9])[0-9]" "\\1" CRYPTOPP_VERSION_MINOR
+ ${_CRYPTOPP_VERSION_TMP})
+ STRING (REGEX REPLACE "[0-9][0-9]([0-9])" "\\1" CRYPTOPP_VERSION_PATCH
+ ${_CRYPTOPP_VERSION_TMP})
+
+ SET (CRYPTOPP_VERSION_COUNT 3)
+ SET (CRYPTOPP_VERSION
+ ${CRYPTOPP_VERSION_MAJOR}.${CRYPTOPP_VERSION_MINOR}.${CRYPTOPP_VERSION_PATCH})
+ ENDIF (EXISTS ${_CRYPTOPP_VERSION_HEADER})
+ENDIF (CRYPTOPP_INCLUDE_DIR)
+
+SET (CRYPTOPP_INCLUDE_DIRS ${CRYPTOPP_INCLUDE_DIR})
+SET (CRYPTOPP_LIBRARIES ${CRYPTOPP_LIBRARY})
+
+MARK_AS_ADVANCED (CRYPTOPP_INCLUDE_DIR CRYPTOPP_LIBRARY CRYPTOPP_LIBRARY_DEBUG
+ CRYPTOPP_LIBRARY_RELEASE)
+
+FIND_PACKAGE_HANDLE_STANDARD_ARGS (CryptoPP REQUIRED_VARS CRYPTOPP_ROOT_DIR
+ CRYPTOPP_INCLUDE_DIR CRYPTOPP_LIBRARY VERSION_VAR CRYPTOPP_VERSION) \ No newline at end of file
diff --git a/Godeps/_workspace/src/github.com/ethereum/ethash/cmake/modules/FindOpenCL.cmake b/Godeps/_workspace/src/github.com/ethereum/ethash/cmake/modules/FindOpenCL.cmake
new file mode 100644
index 000000000..415c95dbd
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/ethash/cmake/modules/FindOpenCL.cmake
@@ -0,0 +1,148 @@
+#.rst:
+# FindOpenCL
+# ----------
+#
+# Try to find OpenCL
+#
+# Once done this will define::
+#
+# OpenCL_FOUND - True if OpenCL was found
+# OpenCL_INCLUDE_DIRS - include directories for OpenCL
+# OpenCL_LIBRARIES - link against this library to use OpenCL
+# OpenCL_VERSION_STRING - Highest supported OpenCL version (eg. 1.2)
+# OpenCL_VERSION_MAJOR - The major version of the OpenCL implementation
+# OpenCL_VERSION_MINOR - The minor version of the OpenCL implementation
+#
+# The module will also define two cache variables::
+#
+# OpenCL_INCLUDE_DIR - the OpenCL include directory
+# OpenCL_LIBRARY - the path to the OpenCL library
+#
+
+#=============================================================================
+# Copyright 2014 Matthaeus G. Chajdas
+#
+# Distributed under the OSI-approved BSD License (the "License");
+# see accompanying file Copyright.txt for details.
+#
+# This software is distributed WITHOUT ANY WARRANTY; without even the
+# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
+# See the License for more information.
+#=============================================================================
+# (To distribute this file outside of CMake, substitute the full
+# License text for the above reference.)
+
+function(_FIND_OPENCL_VERSION)
+ include(CheckSymbolExists)
+ include(CMakePushCheckState)
+ set(CMAKE_REQUIRED_QUIET ${OpenCL_FIND_QUIETLY})
+
+ CMAKE_PUSH_CHECK_STATE()
+ foreach(VERSION "2_0" "1_2" "1_1" "1_0")
+ set(CMAKE_REQUIRED_INCLUDES "${OpenCL_INCLUDE_DIR}")
+
+ if(APPLE)
+ CHECK_SYMBOL_EXISTS(
+ CL_VERSION_${VERSION}
+ "${OpenCL_INCLUDE_DIR}/OpenCL/cl.h"
+ OPENCL_VERSION_${VERSION})
+ else()
+ CHECK_SYMBOL_EXISTS(
+ CL_VERSION_${VERSION}
+ "${OpenCL_INCLUDE_DIR}/CL/cl.h"
+ OPENCL_VERSION_${VERSION})
+ endif()
+
+ if(OPENCL_VERSION_${VERSION})
+ string(REPLACE "_" "." VERSION "${VERSION}")
+ set(OpenCL_VERSION_STRING ${VERSION} PARENT_SCOPE)
+ string(REGEX MATCHALL "[0-9]+" version_components "${VERSION}")
+ list(GET version_components 0 major_version)
+ list(GET version_components 1 minor_version)
+ set(OpenCL_VERSION_MAJOR ${major_version} PARENT_SCOPE)
+ set(OpenCL_VERSION_MINOR ${minor_version} PARENT_SCOPE)
+ break()
+ endif()
+ endforeach()
+ CMAKE_POP_CHECK_STATE()
+endfunction()
+
+find_path(OpenCL_INCLUDE_DIR
+ NAMES
+ CL/cl.h OpenCL/cl.h
+ PATHS
+ ENV "PROGRAMFILES(X86)"
+ ENV AMDAPPSDKROOT
+ ENV INTELOCLSDKROOT
+ ENV NVSDKCOMPUTE_ROOT
+ ENV CUDA_PATH
+ ENV ATISTREAMSDKROOT
+ PATH_SUFFIXES
+ include
+ OpenCL/common/inc
+ "AMD APP/include")
+
+_FIND_OPENCL_VERSION()
+
+if(WIN32)
+ if(CMAKE_SIZEOF_VOID_P EQUAL 4)
+ find_library(OpenCL_LIBRARY
+ NAMES OpenCL
+ PATHS
+ ENV "PROGRAMFILES(X86)"
+ ENV AMDAPPSDKROOT
+ ENV INTELOCLSDKROOT
+ ENV CUDA_PATH
+ ENV NVSDKCOMPUTE_ROOT
+ ENV ATISTREAMSDKROOT
+ PATH_SUFFIXES
+ "AMD APP/lib/x86"
+ lib/x86
+ lib/Win32
+ OpenCL/common/lib/Win32)
+ elseif(CMAKE_SIZEOF_VOID_P EQUAL 8)
+ find_library(OpenCL_LIBRARY
+ NAMES OpenCL
+ PATHS
+ ENV "PROGRAMFILES(X86)"
+ ENV AMDAPPSDKROOT
+ ENV INTELOCLSDKROOT
+ ENV CUDA_PATH
+ ENV NVSDKCOMPUTE_ROOT
+ ENV ATISTREAMSDKROOT
+ PATH_SUFFIXES
+ "AMD APP/lib/x86_64"
+ lib/x86_64
+ lib/x64
+ OpenCL/common/lib/x64)
+ endif()
+else()
+ find_library(OpenCL_LIBRARY
+ NAMES OpenCL
+ PATHS
+ ENV "PROGRAMFILES(X86)"
+ ENV AMDAPPSDKROOT
+ ENV INTELOCLSDKROOT
+ ENV CUDA_PATH
+ ENV NVSDKCOMPUTE_ROOT
+ ENV ATISTREAMSDKROOT
+ PATH_SUFFIXES
+ "AMD APP/lib/x86_64"
+ lib/x86_64
+ lib/x64
+ OpenCL/common/lib/x64)
+endif()
+
+set(OpenCL_LIBRARIES ${OpenCL_LIBRARY})
+set(OpenCL_INCLUDE_DIRS ${OpenCL_INCLUDE_DIR})
+
+include(${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake)
+find_package_handle_standard_args(
+ OpenCL
+ FOUND_VAR OpenCL_FOUND
+ REQUIRED_VARS OpenCL_LIBRARY OpenCL_INCLUDE_DIR
+ VERSION_VAR OpenCL_VERSION_STRING)
+
+mark_as_advanced(
+ OpenCL_INCLUDE_DIR
+ OpenCL_LIBRARY)
diff --git a/Godeps/_workspace/src/github.com/ethereum/ethash/cmake/modules/FindPackageHandleStandardArgs.cmake b/Godeps/_workspace/src/github.com/ethereum/ethash/cmake/modules/FindPackageHandleStandardArgs.cmake
new file mode 100644
index 000000000..6bcf1e788
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/ethash/cmake/modules/FindPackageHandleStandardArgs.cmake
@@ -0,0 +1,382 @@
+#.rst:
+# FindPackageHandleStandardArgs
+# -----------------------------
+#
+#
+#
+# FIND_PACKAGE_HANDLE_STANDARD_ARGS(<name> ... )
+#
+# This function is intended to be used in FindXXX.cmake modules files.
+# It handles the REQUIRED, QUIET and version-related arguments to
+# find_package(). It also sets the <packagename>_FOUND variable. The
+# package is considered found if all variables <var1>... listed contain
+# valid results, e.g. valid filepaths.
+#
+# There are two modes of this function. The first argument in both
+# modes is the name of the Find-module where it is called (in original
+# casing).
+#
+# The first simple mode looks like this:
+#
+# ::
+#
+# FIND_PACKAGE_HANDLE_STANDARD_ARGS(<name>
+# (DEFAULT_MSG|"Custom failure message") <var1>...<varN> )
+#
+# If the variables <var1> to <varN> are all valid, then
+# <UPPERCASED_NAME>_FOUND will be set to TRUE. If DEFAULT_MSG is given
+# as second argument, then the function will generate itself useful
+# success and error messages. You can also supply a custom error
+# message for the failure case. This is not recommended.
+#
+# The second mode is more powerful and also supports version checking:
+#
+# ::
+#
+# FIND_PACKAGE_HANDLE_STANDARD_ARGS(NAME
+# [FOUND_VAR <resultVar>]
+# [REQUIRED_VARS <var1>...<varN>]
+# [VERSION_VAR <versionvar>]
+# [HANDLE_COMPONENTS]
+# [CONFIG_MODE]
+# [FAIL_MESSAGE "Custom failure message"] )
+#
+# In this mode, the name of the result-variable can be set either to
+# either <UPPERCASED_NAME>_FOUND or <OriginalCase_Name>_FOUND using the
+# FOUND_VAR option. Other names for the result-variable are not
+# allowed. So for a Find-module named FindFooBar.cmake, the two
+# possible names are FooBar_FOUND and FOOBAR_FOUND. It is recommended
+# to use the original case version. If the FOUND_VAR option is not
+# used, the default is <UPPERCASED_NAME>_FOUND.
+#
+# As in the simple mode, if <var1> through <varN> are all valid,
+# <packagename>_FOUND will be set to TRUE. After REQUIRED_VARS the
+# variables which are required for this package are listed. Following
+# VERSION_VAR the name of the variable can be specified which holds the
+# version of the package which has been found. If this is done, this
+# version will be checked against the (potentially) specified required
+# version used in the find_package() call. The EXACT keyword is also
+# handled. The default messages include information about the required
+# version and the version which has been actually found, both if the
+# version is ok or not. If the package supports components, use the
+# HANDLE_COMPONENTS option to enable handling them. In this case,
+# find_package_handle_standard_args() will report which components have
+# been found and which are missing, and the <packagename>_FOUND variable
+# will be set to FALSE if any of the required components (i.e. not the
+# ones listed after OPTIONAL_COMPONENTS) are missing. Use the option
+# CONFIG_MODE if your FindXXX.cmake module is a wrapper for a
+# find_package(... NO_MODULE) call. In this case VERSION_VAR will be
+# set to <NAME>_VERSION and the macro will automatically check whether
+# the Config module was found. Via FAIL_MESSAGE a custom failure
+# message can be specified, if this is not used, the default message
+# will be displayed.
+#
+# Example for mode 1:
+#
+# ::
+#
+# find_package_handle_standard_args(LibXml2 DEFAULT_MSG
+# LIBXML2_LIBRARY LIBXML2_INCLUDE_DIR)
+#
+#
+#
+# LibXml2 is considered to be found, if both LIBXML2_LIBRARY and
+# LIBXML2_INCLUDE_DIR are valid. Then also LIBXML2_FOUND is set to
+# TRUE. If it is not found and REQUIRED was used, it fails with
+# FATAL_ERROR, independent whether QUIET was used or not. If it is
+# found, success will be reported, including the content of <var1>. On
+# repeated Cmake runs, the same message won't be printed again.
+#
+# Example for mode 2:
+#
+# ::
+#
+# find_package_handle_standard_args(LibXslt
+# FOUND_VAR LibXslt_FOUND
+# REQUIRED_VARS LibXslt_LIBRARIES LibXslt_INCLUDE_DIRS
+# VERSION_VAR LibXslt_VERSION_STRING)
+#
+# In this case, LibXslt is considered to be found if the variable(s)
+# listed after REQUIRED_VAR are all valid, i.e. LibXslt_LIBRARIES and
+# LibXslt_INCLUDE_DIRS in this case. The result will then be stored in
+# LibXslt_FOUND . Also the version of LibXslt will be checked by using
+# the version contained in LibXslt_VERSION_STRING. Since no
+# FAIL_MESSAGE is given, the default messages will be printed.
+#
+# Another example for mode 2:
+#
+# ::
+#
+# find_package(Automoc4 QUIET NO_MODULE HINTS /opt/automoc4)
+# find_package_handle_standard_args(Automoc4 CONFIG_MODE)
+#
+# In this case, FindAutmoc4.cmake wraps a call to find_package(Automoc4
+# NO_MODULE) and adds an additional search directory for automoc4. Here
+# the result will be stored in AUTOMOC4_FOUND. The following
+# FIND_PACKAGE_HANDLE_STANDARD_ARGS() call produces a proper
+# success/error message.
+
+#=============================================================================
+# Copyright 2007-2009 Kitware, Inc.
+#
+# Distributed under the OSI-approved BSD License (the "License");
+# see accompanying file Copyright.txt for details.
+#
+# This software is distributed WITHOUT ANY WARRANTY; without even the
+# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
+# See the License for more information.
+#=============================================================================
+# (To distribute this file outside of CMake, substitute the full
+# License text for the above reference.)
+
+include(${CMAKE_CURRENT_LIST_DIR}/FindPackageMessage.cmake)
+include(${CMAKE_CURRENT_LIST_DIR}/CMakeParseArguments.cmake)
+
+# internal helper macro
+macro(_FPHSA_FAILURE_MESSAGE _msg)
+ if (${_NAME}_FIND_REQUIRED)
+ message(FATAL_ERROR "${_msg}")
+ else ()
+ if (NOT ${_NAME}_FIND_QUIETLY)
+ message(STATUS "${_msg}")
+ endif ()
+ endif ()
+endmacro()
+
+
+# internal helper macro to generate the failure message when used in CONFIG_MODE:
+macro(_FPHSA_HANDLE_FAILURE_CONFIG_MODE)
+ # <name>_CONFIG is set, but FOUND is false, this means that some other of the REQUIRED_VARS was not found:
+ if(${_NAME}_CONFIG)
+ _FPHSA_FAILURE_MESSAGE("${FPHSA_FAIL_MESSAGE}: missing: ${MISSING_VARS} (found ${${_NAME}_CONFIG} ${VERSION_MSG})")
+ else()
+ # If _CONSIDERED_CONFIGS is set, the config-file has been found, but no suitable version.
+ # List them all in the error message:
+ if(${_NAME}_CONSIDERED_CONFIGS)
+ set(configsText "")
+ list(LENGTH ${_NAME}_CONSIDERED_CONFIGS configsCount)
+ math(EXPR configsCount "${configsCount} - 1")
+ foreach(currentConfigIndex RANGE ${configsCount})
+ list(GET ${_NAME}_CONSIDERED_CONFIGS ${currentConfigIndex} filename)
+ list(GET ${_NAME}_CONSIDERED_VERSIONS ${currentConfigIndex} version)
+ set(configsText "${configsText} ${filename} (version ${version})\n")
+ endforeach()
+ if (${_NAME}_NOT_FOUND_MESSAGE)
+ set(configsText "${configsText} Reason given by package: ${${_NAME}_NOT_FOUND_MESSAGE}\n")
+ endif()
+ _FPHSA_FAILURE_MESSAGE("${FPHSA_FAIL_MESSAGE} ${VERSION_MSG}, checked the following files:\n${configsText}")
+
+ else()
+ # Simple case: No Config-file was found at all:
+ _FPHSA_FAILURE_MESSAGE("${FPHSA_FAIL_MESSAGE}: found neither ${_NAME}Config.cmake nor ${_NAME_LOWER}-config.cmake ${VERSION_MSG}")
+ endif()
+ endif()
+endmacro()
+
+
+function(FIND_PACKAGE_HANDLE_STANDARD_ARGS _NAME _FIRST_ARG)
+
+# set up the arguments for CMAKE_PARSE_ARGUMENTS and check whether we are in
+# new extended or in the "old" mode:
+ set(options CONFIG_MODE HANDLE_COMPONENTS)
+ set(oneValueArgs FAIL_MESSAGE VERSION_VAR FOUND_VAR)
+ set(multiValueArgs REQUIRED_VARS)
+ set(_KEYWORDS_FOR_EXTENDED_MODE ${options} ${oneValueArgs} ${multiValueArgs} )
+ list(FIND _KEYWORDS_FOR_EXTENDED_MODE "${_FIRST_ARG}" INDEX)
+
+ if(${INDEX} EQUAL -1)
+ set(FPHSA_FAIL_MESSAGE ${_FIRST_ARG})
+ set(FPHSA_REQUIRED_VARS ${ARGN})
+ set(FPHSA_VERSION_VAR)
+ else()
+
+ CMAKE_PARSE_ARGUMENTS(FPHSA "${options}" "${oneValueArgs}" "${multiValueArgs}" ${_FIRST_ARG} ${ARGN})
+
+ if(FPHSA_UNPARSED_ARGUMENTS)
+ message(FATAL_ERROR "Unknown keywords given to FIND_PACKAGE_HANDLE_STANDARD_ARGS(): \"${FPHSA_UNPARSED_ARGUMENTS}\"")
+ endif()
+
+ if(NOT FPHSA_FAIL_MESSAGE)
+ set(FPHSA_FAIL_MESSAGE "DEFAULT_MSG")
+ endif()
+ endif()
+
+# now that we collected all arguments, process them
+
+ if("x${FPHSA_FAIL_MESSAGE}" STREQUAL "xDEFAULT_MSG")
+ set(FPHSA_FAIL_MESSAGE "Could NOT find ${_NAME}")
+ endif()
+
+ # In config-mode, we rely on the variable <package>_CONFIG, which is set by find_package()
+ # when it successfully found the config-file, including version checking:
+ if(FPHSA_CONFIG_MODE)
+ list(INSERT FPHSA_REQUIRED_VARS 0 ${_NAME}_CONFIG)
+ list(REMOVE_DUPLICATES FPHSA_REQUIRED_VARS)
+ set(FPHSA_VERSION_VAR ${_NAME}_VERSION)
+ endif()
+
+ if(NOT FPHSA_REQUIRED_VARS)
+ message(FATAL_ERROR "No REQUIRED_VARS specified for FIND_PACKAGE_HANDLE_STANDARD_ARGS()")
+ endif()
+
+ list(GET FPHSA_REQUIRED_VARS 0 _FIRST_REQUIRED_VAR)
+
+ string(TOUPPER ${_NAME} _NAME_UPPER)
+ string(TOLOWER ${_NAME} _NAME_LOWER)
+
+ if(FPHSA_FOUND_VAR)
+ if(FPHSA_FOUND_VAR MATCHES "^${_NAME}_FOUND$" OR FPHSA_FOUND_VAR MATCHES "^${_NAME_UPPER}_FOUND$")
+ set(_FOUND_VAR ${FPHSA_FOUND_VAR})
+ else()
+ message(FATAL_ERROR "The argument for FOUND_VAR is \"${FPHSA_FOUND_VAR}\", but only \"${_NAME}_FOUND\" and \"${_NAME_UPPER}_FOUND\" are valid names.")
+ endif()
+ else()
+ set(_FOUND_VAR ${_NAME_UPPER}_FOUND)
+ endif()
+
+ # collect all variables which were not found, so they can be printed, so the
+ # user knows better what went wrong (#6375)
+ set(MISSING_VARS "")
+ set(DETAILS "")
+ # check if all passed variables are valid
+ unset(${_FOUND_VAR})
+ foreach(_CURRENT_VAR ${FPHSA_REQUIRED_VARS})
+ if(NOT ${_CURRENT_VAR})
+ set(${_FOUND_VAR} FALSE)
+ set(MISSING_VARS "${MISSING_VARS} ${_CURRENT_VAR}")
+ else()
+ set(DETAILS "${DETAILS}[${${_CURRENT_VAR}}]")
+ endif()
+ endforeach()
+ if(NOT "${${_FOUND_VAR}}" STREQUAL "FALSE")
+ set(${_FOUND_VAR} TRUE)
+ endif()
+
+ # component handling
+ unset(FOUND_COMPONENTS_MSG)
+ unset(MISSING_COMPONENTS_MSG)
+
+ if(FPHSA_HANDLE_COMPONENTS)
+ foreach(comp ${${_NAME}_FIND_COMPONENTS})
+ if(${_NAME}_${comp}_FOUND)
+
+ if(NOT DEFINED FOUND_COMPONENTS_MSG)
+ set(FOUND_COMPONENTS_MSG "found components: ")
+ endif()
+ set(FOUND_COMPONENTS_MSG "${FOUND_COMPONENTS_MSG} ${comp}")
+
+ else()
+
+ if(NOT DEFINED MISSING_COMPONENTS_MSG)
+ set(MISSING_COMPONENTS_MSG "missing components: ")
+ endif()
+ set(MISSING_COMPONENTS_MSG "${MISSING_COMPONENTS_MSG} ${comp}")
+
+ if(${_NAME}_FIND_REQUIRED_${comp})
+ set(${_FOUND_VAR} FALSE)
+ set(MISSING_VARS "${MISSING_VARS} ${comp}")
+ endif()
+
+ endif()
+ endforeach()
+ set(COMPONENT_MSG "${FOUND_COMPONENTS_MSG} ${MISSING_COMPONENTS_MSG}")
+ set(DETAILS "${DETAILS}[c${COMPONENT_MSG}]")
+ endif()
+
+ # version handling:
+ set(VERSION_MSG "")
+ set(VERSION_OK TRUE)
+ set(VERSION ${${FPHSA_VERSION_VAR}})
+
+ # check with DEFINED here as the requested or found version may be "0"
+ if (DEFINED ${_NAME}_FIND_VERSION)
+ if(DEFINED ${FPHSA_VERSION_VAR})
+
+ if(${_NAME}_FIND_VERSION_EXACT) # exact version required
+ # count the dots in the version string
+ string(REGEX REPLACE "[^.]" "" _VERSION_DOTS "${VERSION}")
+ # add one dot because there is one dot more than there are components
+ string(LENGTH "${_VERSION_DOTS}." _VERSION_DOTS)
+ if (_VERSION_DOTS GREATER ${_NAME}_FIND_VERSION_COUNT)
+ # Because of the C++ implementation of find_package() ${_NAME}_FIND_VERSION_COUNT
+ # is at most 4 here. Therefore a simple lookup table is used.
+ if (${_NAME}_FIND_VERSION_COUNT EQUAL 1)
+ set(_VERSION_REGEX "[^.]*")
+ elseif (${_NAME}_FIND_VERSION_COUNT EQUAL 2)
+ set(_VERSION_REGEX "[^.]*\\.[^.]*")
+ elseif (${_NAME}_FIND_VERSION_COUNT EQUAL 3)
+ set(_VERSION_REGEX "[^.]*\\.[^.]*\\.[^.]*")
+ else ()
+ set(_VERSION_REGEX "[^.]*\\.[^.]*\\.[^.]*\\.[^.]*")
+ endif ()
+ string(REGEX REPLACE "^(${_VERSION_REGEX})\\..*" "\\1" _VERSION_HEAD "${VERSION}")
+ unset(_VERSION_REGEX)
+ if (NOT ${_NAME}_FIND_VERSION VERSION_EQUAL _VERSION_HEAD)
+ set(VERSION_MSG "Found unsuitable version \"${VERSION}\", but required is exact version \"${${_NAME}_FIND_VERSION}\"")
+ set(VERSION_OK FALSE)
+ else ()
+ set(VERSION_MSG "(found suitable exact version \"${VERSION}\")")
+ endif ()
+ unset(_VERSION_HEAD)
+ else ()
+ if (NOT "${${_NAME}_FIND_VERSION}" VERSION_EQUAL "${VERSION}")
+ set(VERSION_MSG "Found unsuitable version \"${VERSION}\", but required is exact version \"${${_NAME}_FIND_VERSION}\"")
+ set(VERSION_OK FALSE)
+ else ()
+ set(VERSION_MSG "(found suitable exact version \"${VERSION}\")")
+ endif ()
+ endif ()
+ unset(_VERSION_DOTS)
+
+ else() # minimum version specified:
+ if ("${${_NAME}_FIND_VERSION}" VERSION_GREATER "${VERSION}")
+ set(VERSION_MSG "Found unsuitable version \"${VERSION}\", but required is at least \"${${_NAME}_FIND_VERSION}\"")
+ set(VERSION_OK FALSE)
+ else ()
+ set(VERSION_MSG "(found suitable version \"${VERSION}\", minimum required is \"${${_NAME}_FIND_VERSION}\")")
+ endif ()
+ endif()
+
+ else()
+
+ # if the package was not found, but a version was given, add that to the output:
+ if(${_NAME}_FIND_VERSION_EXACT)
+ set(VERSION_MSG "(Required is exact version \"${${_NAME}_FIND_VERSION}\")")
+ else()
+ set(VERSION_MSG "(Required is at least version \"${${_NAME}_FIND_VERSION}\")")
+ endif()
+
+ endif()
+ else ()
+ if(VERSION)
+ set(VERSION_MSG "(found version \"${VERSION}\")")
+ endif()
+ endif ()
+
+ if(VERSION_OK)
+ set(DETAILS "${DETAILS}[v${VERSION}(${${_NAME}_FIND_VERSION})]")
+ else()
+ set(${_FOUND_VAR} FALSE)
+ endif()
+
+
+ # print the result:
+ if (${_FOUND_VAR})
+ FIND_PACKAGE_MESSAGE(${_NAME} "Found ${_NAME}: ${${_FIRST_REQUIRED_VAR}} ${VERSION_MSG} ${COMPONENT_MSG}" "${DETAILS}")
+ else ()
+
+ if(FPHSA_CONFIG_MODE)
+ _FPHSA_HANDLE_FAILURE_CONFIG_MODE()
+ else()
+ if(NOT VERSION_OK)
+ _FPHSA_FAILURE_MESSAGE("${FPHSA_FAIL_MESSAGE}: ${VERSION_MSG} (found ${${_FIRST_REQUIRED_VAR}})")
+ else()
+ _FPHSA_FAILURE_MESSAGE("${FPHSA_FAIL_MESSAGE} (missing: ${MISSING_VARS}) ${VERSION_MSG}")
+ endif()
+ endif()
+
+ endif ()
+
+ set(${_FOUND_VAR} ${${_FOUND_VAR}} PARENT_SCOPE)
+
+endfunction()
diff --git a/Godeps/_workspace/src/github.com/ethereum/ethash/cmake/modules/FindPackageMessage.cmake b/Godeps/_workspace/src/github.com/ethereum/ethash/cmake/modules/FindPackageMessage.cmake
new file mode 100644
index 000000000..a0349d3db
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/ethash/cmake/modules/FindPackageMessage.cmake
@@ -0,0 +1,57 @@
+#.rst:
+# FindPackageMessage
+# ------------------
+#
+#
+#
+# FIND_PACKAGE_MESSAGE(<name> "message for user" "find result details")
+#
+# This macro is intended to be used in FindXXX.cmake modules files. It
+# will print a message once for each unique find result. This is useful
+# for telling the user where a package was found. The first argument
+# specifies the name (XXX) of the package. The second argument
+# specifies the message to display. The third argument lists details
+# about the find result so that if they change the message will be
+# displayed again. The macro also obeys the QUIET argument to the
+# find_package command.
+#
+# Example:
+#
+# ::
+#
+# if(X11_FOUND)
+# FIND_PACKAGE_MESSAGE(X11 "Found X11: ${X11_X11_LIB}"
+# "[${X11_X11_LIB}][${X11_INCLUDE_DIR}]")
+# else()
+# ...
+# endif()
+
+#=============================================================================
+# Copyright 2008-2009 Kitware, Inc.
+#
+# Distributed under the OSI-approved BSD License (the "License");
+# see accompanying file Copyright.txt for details.
+#
+# This software is distributed WITHOUT ANY WARRANTY; without even the
+# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
+# See the License for more information.
+#=============================================================================
+# (To distribute this file outside of CMake, substitute the full
+# License text for the above reference.)
+
+function(FIND_PACKAGE_MESSAGE pkg msg details)
+ # Avoid printing a message repeatedly for the same find result.
+ if(NOT ${pkg}_FIND_QUIETLY)
+ string(REPLACE "\n" "" details "${details}")
+ set(DETAILS_VAR FIND_PACKAGE_MESSAGE_DETAILS_${pkg})
+ if(NOT "${details}" STREQUAL "${${DETAILS_VAR}}")
+ # The message has not yet been printed.
+ message(STATUS "${msg}")
+
+ # Save the find details in the cache to avoid printing the same
+ # message again.
+ set("${DETAILS_VAR}" "${details}"
+ CACHE INTERNAL "Details about finding ${pkg}")
+ endif()
+ endif()
+endfunction()
diff --git a/Godeps/_workspace/src/github.com/ethereum/ethash/cryptopp/CMakeLists.txt b/Godeps/_workspace/src/github.com/ethereum/ethash/cryptopp/CMakeLists.txt
new file mode 100644
index 000000000..6f4280532
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/ethash/cryptopp/CMakeLists.txt
@@ -0,0 +1,13 @@
+set(LIBRARY cryptopp)
+
+include_directories(../../cryptopp)
+
+# todo, subset
+file(GLOB HEADERS "../../cryptopp/*.h")
+file(GLOB SOURCE "../../cryptopp/*.cpp")
+
+add_library(${LIBRARY} ${HEADERS} ${SOURCE})
+
+set(CRYPTOPP_INCLUDE_DIRS "../.." "../../../" PARENT_SCOPE)
+set(CRYPTOPP_LIBRARIES ${LIBRARY} PARENT_SCOPE)
+set(CRYPTOPP_FOUND TRUE PARENT_SCOPE)
diff --git a/Godeps/_workspace/src/github.com/ethereum/ethash/ethash.go b/Godeps/_workspace/src/github.com/ethereum/ethash/ethash.go
new file mode 100644
index 000000000..8746aaca9
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/ethash/ethash.go
@@ -0,0 +1,437 @@
+/*
+###################################################################################
+###################################################################################
+#################### ####################
+#################### EDIT AND YOU SHALL FEEL MY WRATH - jeff ####################
+#################### ####################
+###################################################################################
+###################################################################################
+*/
+
+package ethash
+
+/*
+#cgo CFLAGS: -std=gnu99 -Wall
+#include "src/libethash/util.c"
+#include "src/libethash/internal.c"
+#include "src/libethash/sha3.c"
+*/
+import "C"
+
+import (
+ "bytes"
+ "encoding/binary"
+ "fmt"
+ "io/ioutil"
+ "math/big"
+ "math/rand"
+ "os"
+ "path"
+ "sync"
+ "time"
+ "unsafe"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/crypto"
+ "github.com/ethereum/go-ethereum/logger"
+ "github.com/ethereum/go-ethereum/pow"
+)
+
+var minDifficulty = new(big.Int).Exp(big.NewInt(2), big.NewInt(256), big.NewInt(0))
+
+var powlogger = logger.NewLogger("POW")
+
+type ParamsAndCache struct {
+ params *C.ethash_params
+ cache *C.ethash_cache
+ Epoch uint64
+}
+
+type DAG struct {
+ dag unsafe.Pointer // full GB of memory for dag
+ file bool
+ paramsAndCache *ParamsAndCache
+}
+
+type Ethash struct {
+ turbo bool
+ HashRate int64
+ chainManager pow.ChainManager
+ dag *DAG
+ paramsAndCache *ParamsAndCache
+ ret *C.ethash_return_value
+ dagMutex *sync.RWMutex
+ cacheMutex *sync.RWMutex
+}
+
+func parseNonce(nonce []byte) (uint64, error) {
+ nonceBuf := bytes.NewBuffer(nonce)
+ nonceInt, err := binary.ReadUvarint(nonceBuf)
+ if err != nil {
+ return 0, err
+ }
+ return nonceInt, nil
+}
+
+const epochLength uint64 = 30000
+
+func makeParamsAndCache(chainManager pow.ChainManager, blockNum uint64) (*ParamsAndCache, error) {
+ if blockNum >= epochLength*2048 {
+ return nil, fmt.Errorf("block number is out of bounds (value %v, limit is %v)", blockNum, epochLength*2048)
+ }
+ paramsAndCache := &ParamsAndCache{
+ params: new(C.ethash_params),
+ cache: new(C.ethash_cache),
+ Epoch: blockNum / epochLength,
+ }
+ C.ethash_params_init(paramsAndCache.params, C.uint32_t(uint32(blockNum)))
+ paramsAndCache.cache.mem = C.malloc(paramsAndCache.params.cache_size)
+
+ seedHash, err := GetSeedHash(blockNum)
+ if err != nil {
+ return nil, err
+ }
+
+ powlogger.Infoln("Making Cache")
+ start := time.Now()
+ C.ethash_mkcache(paramsAndCache.cache, paramsAndCache.params, (*C.uint8_t)(unsafe.Pointer(&seedHash[0])))
+ powlogger.Infoln("Took:", time.Since(start))
+
+ return paramsAndCache, nil
+}
+
+func (pow *Ethash) UpdateCache(force bool) error {
+ pow.cacheMutex.Lock()
+ defer pow.cacheMutex.Unlock()
+
+ thisEpoch := pow.chainManager.CurrentBlock().NumberU64() / epochLength
+ if force || pow.paramsAndCache.Epoch != thisEpoch {
+ var err error
+ pow.paramsAndCache, err = makeParamsAndCache(pow.chainManager, pow.chainManager.CurrentBlock().NumberU64())
+ if err != nil {
+ panic(err)
+ }
+ }
+
+ return nil
+}
+
+func makeDAG(p *ParamsAndCache) *DAG {
+ d := &DAG{
+ dag: C.malloc(p.params.full_size),
+ file: false,
+ paramsAndCache: p,
+ }
+
+ donech := make(chan string)
+ go func() {
+ t := time.NewTicker(5 * time.Second)
+ tstart := time.Now()
+ done:
+ for {
+ select {
+ case <-t.C:
+ powlogger.Infof("... still generating DAG (%v) ...\n", time.Since(tstart).Seconds())
+ case str := <-donech:
+ powlogger.Infof("... %s ...\n", str)
+ break done
+ }
+ }
+ }()
+ C.ethash_compute_full_data(d.dag, p.params, p.cache)
+ donech <- "DAG generation completed"
+ return d
+}
+
+func (pow *Ethash) writeDagToDisk(dag *DAG, epoch uint64) *os.File {
+ if epoch > 2048 {
+ panic(fmt.Errorf("Epoch must be less than 2048 (is %v)", epoch))
+ }
+ data := C.GoBytes(unsafe.Pointer(dag.dag), C.int(dag.paramsAndCache.params.full_size))
+ file, err := os.Create("/tmp/dag")
+ if err != nil {
+ panic(err)
+ }
+
+ dataEpoch := make([]byte, 8)
+ binary.BigEndian.PutUint64(dataEpoch, epoch)
+
+ file.Write(dataEpoch)
+ file.Write(data)
+
+ return file
+}
+
+func (pow *Ethash) UpdateDAG() {
+ blockNum := pow.chainManager.CurrentBlock().NumberU64()
+ if blockNum >= epochLength*2048 {
+ // This will crash in the 2030s or 2040s
+ panic(fmt.Errorf("Current block number is out of bounds (value %v, limit is %v)", blockNum, epochLength*2048))
+ }
+
+ pow.dagMutex.Lock()
+ defer pow.dagMutex.Unlock()
+ thisEpoch := blockNum / epochLength
+ if pow.dag == nil || pow.dag.paramsAndCache.Epoch != thisEpoch {
+ if pow.dag != nil && pow.dag.dag != nil {
+ C.free(pow.dag.dag)
+ pow.dag.dag = nil
+ }
+
+ if pow.dag != nil && pow.dag.paramsAndCache.cache.mem != nil {
+ C.free(pow.dag.paramsAndCache.cache.mem)
+ pow.dag.paramsAndCache.cache.mem = nil
+ }
+
+ // Make the params and cache for the DAG
+ paramsAndCache, err := makeParamsAndCache(pow.chainManager, blockNum)
+ if err != nil {
+ panic(err)
+ }
+
+ // TODO: On non-SSD disks, loading the DAG from disk takes longer than generating it in memory
+ pow.paramsAndCache = paramsAndCache
+ path := path.Join("/", "tmp", "dag")
+ pow.dag = nil
+ powlogger.Infoln("Retrieving DAG")
+ start := time.Now()
+
+ file, err := os.Open(path)
+ if err != nil {
+ powlogger.Infof("No DAG found. Generating new DAG in '%s' (this takes a while)...\n", path)
+ pow.dag = makeDAG(paramsAndCache)
+ file = pow.writeDagToDisk(pow.dag, thisEpoch)
+ pow.dag.file = true
+ } else {
+ data, err := ioutil.ReadAll(file)
+ if err != nil {
+ powlogger.Infof("DAG load err: %v\n", err)
+ }
+
+ if len(data) < 8 {
+ powlogger.Infof("DAG in '%s' is less than 8 bytes, it must be corrupted. Generating new DAG (this takes a while)...\n", path)
+ pow.dag = makeDAG(paramsAndCache)
+ file = pow.writeDagToDisk(pow.dag, thisEpoch)
+ pow.dag.file = true
+ } else {
+ dataEpoch := binary.BigEndian.Uint64(data[0:8])
+ if dataEpoch < thisEpoch {
+ powlogger.Infof("DAG in '%s' is stale. Generating new DAG (this takes a while)...\n", path)
+ pow.dag = makeDAG(paramsAndCache)
+ file = pow.writeDagToDisk(pow.dag, thisEpoch)
+ pow.dag.file = true
+ } else if dataEpoch > thisEpoch {
+ // FIXME
+ panic(fmt.Errorf("Saved DAG in '%s' reports to be from future epoch %v (current epoch is %v)\n", path, dataEpoch, thisEpoch))
+ } else if len(data) != (int(paramsAndCache.params.full_size) + 8) {
+ powlogger.Infof("DAG in '%s' is corrupted. Generating new DAG (this takes a while)...\n", path)
+ pow.dag = makeDAG(paramsAndCache)
+ file = pow.writeDagToDisk(pow.dag, thisEpoch)
+ pow.dag.file = true
+ } else {
+ data = data[8:]
+ pow.dag = &DAG{
+ dag: unsafe.Pointer(&data[0]),
+ file: true,
+ paramsAndCache: paramsAndCache,
+ }
+ }
+ }
+ }
+ powlogger.Infoln("Took:", time.Since(start))
+
+ file.Close()
+ }
+}
+
+func New(chainManager pow.ChainManager) *Ethash {
+ paramsAndCache, err := makeParamsAndCache(chainManager, chainManager.CurrentBlock().NumberU64())
+ if err != nil {
+ panic(err)
+ }
+
+ return &Ethash{
+ turbo: true,
+ paramsAndCache: paramsAndCache,
+ chainManager: chainManager,
+ dag: nil,
+ cacheMutex: new(sync.RWMutex),
+ dagMutex: new(sync.RWMutex),
+ }
+}
+
+func (pow *Ethash) DAGSize() uint64 {
+ return uint64(pow.dag.paramsAndCache.params.full_size)
+}
+
+func (pow *Ethash) CacheSize() uint64 {
+ return uint64(pow.paramsAndCache.params.cache_size)
+}
+
+func GetSeedHash(blockNum uint64) ([]byte, error) {
+ if blockNum >= epochLength*2048 {
+ return nil, fmt.Errorf("block number is out of bounds (value %v, limit is %v)", blockNum, epochLength*2048)
+ }
+
+ epoch := blockNum / epochLength
+ seedHash := make([]byte, 32)
+ var i uint64
+ for i = 0; i < 32; i++ {
+ seedHash[i] = 0
+ }
+ for i = 0; i < epoch; i++ {
+ seedHash = crypto.Sha3(seedHash)
+ }
+ return seedHash, nil
+}
+
+func (pow *Ethash) Stop() {
+ pow.cacheMutex.Lock()
+ pow.dagMutex.Lock()
+ defer pow.dagMutex.Unlock()
+ defer pow.cacheMutex.Unlock()
+
+ if pow.paramsAndCache.cache != nil {
+ C.free(pow.paramsAndCache.cache.mem)
+ }
+ if pow.dag.dag != nil && !pow.dag.file {
+ C.free(pow.dag.dag)
+ }
+ if pow.dag != nil && pow.dag.paramsAndCache != nil && pow.dag.paramsAndCache.cache.mem != nil {
+ C.free(pow.dag.paramsAndCache.cache.mem)
+ pow.dag.paramsAndCache.cache.mem = nil
+ }
+ pow.dag.dag = nil
+}
+
+func (pow *Ethash) Search(block pow.Block, stop <-chan struct{}) (uint64, []byte, []byte) {
+ pow.UpdateDAG()
+
+ pow.dagMutex.RLock()
+ defer pow.dagMutex.RUnlock()
+
+ r := rand.New(rand.NewSource(time.Now().UnixNano()))
+ miningHash := block.HashNoNonce()
+ diff := block.Difficulty()
+
+ i := int64(0)
+ starti := i
+ start := time.Now().UnixNano()
+
+ nonce := uint64(r.Int63())
+ cMiningHash := (*C.uint8_t)(unsafe.Pointer(&miningHash[0]))
+ target := new(big.Int).Div(minDifficulty, diff)
+
+ var ret C.ethash_return_value
+ for {
+ select {
+ case <-stop:
+ powlogger.Infoln("Breaking from mining")
+ pow.HashRate = 0
+ return 0, nil, nil
+ default:
+ i++
+
+ elapsed := time.Now().UnixNano() - start
+ hashes := ((float64(1e9) / float64(elapsed)) * float64(i-starti)) / 1000
+ pow.HashRate = int64(hashes)
+
+ C.ethash_full(&ret, pow.dag.dag, pow.dag.paramsAndCache.params, cMiningHash, C.uint64_t(nonce))
+ result := common.Bytes2Big(C.GoBytes(unsafe.Pointer(&ret.result[0]), C.int(32)))
+
+ // TODO: disagrees with the spec https://github.com/ethereum/wiki/wiki/Ethash#mining
+ if result.Cmp(target) <= 0 {
+ mixDigest := C.GoBytes(unsafe.Pointer(&ret.mix_hash[0]), C.int(32))
+ seedHash, err := GetSeedHash(block.NumberU64()) // This seedhash is useless
+ if err != nil {
+ panic(err)
+ }
+ return nonce, mixDigest, seedHash
+ }
+
+ nonce += 1
+ }
+
+ if !pow.turbo {
+ time.Sleep(20 * time.Microsecond)
+ }
+ }
+
+}
+
+func (pow *Ethash) Verify(block pow.Block) bool {
+
+ return pow.verify(block.HashNoNonce(), block.MixDigest(), block.Difficulty(), block.NumberU64(), block.Nonce())
+}
+
+func (pow *Ethash) verify(hash common.Hash, mixDigest common.Hash, difficulty *big.Int, blockNum uint64, nonce uint64) bool {
+ // Make sure the block num is valid
+ if blockNum >= epochLength*2048 {
+ powlogger.Infoln(fmt.Sprintf("Block number exceeds limit, invalid (value is %v, limit is %v)",
+ blockNum, epochLength*2048))
+ return false
+ }
+
+ // First check: make sure header, mixDigest, nonce are correct without hitting the cache
+ // This is to prevent DOS attacks
+ chash := (*C.uint8_t)(unsafe.Pointer(&hash[0]))
+ cnonce := C.uint64_t(nonce)
+ target := new(big.Int).Div(minDifficulty, difficulty)
+
+ var pAc *ParamsAndCache
+ // If its an old block (doesn't use the current cache)
+ // get the cache for it but don't update (so we don't need the mutex)
+ // Otherwise, it's the current block or a future block.
+ // If current, updateCache will do nothing.
+ if blockNum/epochLength < pow.paramsAndCache.Epoch {
+ var err error
+ // If we can't make the params for some reason, this block is invalid
+ pAc, err = makeParamsAndCache(pow.chainManager, blockNum)
+ if err != nil {
+ powlogger.Infoln(err)
+ return false
+ }
+ } else {
+ pow.UpdateCache(false)
+ pow.cacheMutex.RLock()
+ defer pow.cacheMutex.RUnlock()
+ pAc = pow.paramsAndCache
+ }
+
+ ret := new(C.ethash_return_value)
+
+ C.ethash_light(ret, pAc.cache, pAc.params, chash, cnonce)
+
+ result := common.Bytes2Big(C.GoBytes(unsafe.Pointer(&ret.result[0]), C.int(32)))
+ return result.Cmp(target) <= 0
+}
+
+func (pow *Ethash) GetHashrate() int64 {
+ return pow.HashRate
+}
+
+func (pow *Ethash) Turbo(on bool) {
+ pow.turbo = on
+}
+
+func (pow *Ethash) FullHash(nonce uint64, miningHash []byte) []byte {
+ pow.UpdateDAG()
+ pow.dagMutex.Lock()
+ defer pow.dagMutex.Unlock()
+ cMiningHash := (*C.uint8_t)(unsafe.Pointer(&miningHash[0]))
+ cnonce := C.uint64_t(nonce)
+ ret := new(C.ethash_return_value)
+ // pow.hash is the output/return of ethash_full
+ C.ethash_full(ret, pow.dag.dag, pow.paramsAndCache.params, cMiningHash, cnonce)
+ ghash_full := C.GoBytes(unsafe.Pointer(&ret.result), 32)
+ return ghash_full
+}
+
+func (pow *Ethash) LightHash(nonce uint64, miningHash []byte) []byte {
+ cMiningHash := (*C.uint8_t)(unsafe.Pointer(&miningHash[0]))
+ cnonce := C.uint64_t(nonce)
+ ret := new(C.ethash_return_value)
+ C.ethash_light(ret, pow.paramsAndCache.cache, pow.paramsAndCache.params, cMiningHash, cnonce)
+ ghash_light := C.GoBytes(unsafe.Pointer(&ret.result), 32)
+ return ghash_light
+}
diff --git a/Godeps/_workspace/src/github.com/ethereum/ethash/js/LICENSE b/Godeps/_workspace/src/github.com/ethereum/ethash/js/LICENSE
new file mode 100644
index 000000000..070be633d
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/ethash/js/LICENSE
@@ -0,0 +1,22 @@
+The MIT License (MIT)
+
+Copyright (c) 2015 Tim Hughes
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in all
+copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+SOFTWARE.
+
diff --git a/Godeps/_workspace/src/github.com/ethereum/ethash/js/ethash.js b/Godeps/_workspace/src/github.com/ethereum/ethash/js/ethash.js
new file mode 100644
index 000000000..bec1284f6
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/ethash/js/ethash.js
@@ -0,0 +1,190 @@
+// ethash.js
+// Tim Hughes <tim@twistedfury.com>
+// Revision 19
+
+/*jslint node: true, shadow:true */
+"use strict";
+
+var Keccak = require('./keccak');
+var util = require('./util');
+
+// 32-bit unsigned modulo
+function mod32(x, n)
+{
+ return (x>>>0) % (n>>>0);
+}
+
+function fnv(x, y)
+{
+ // js integer multiply by 0x01000193 will lose precision
+ return ((x*0x01000000 | 0) + (x*0x193 | 0)) ^ y;
+}
+
+function computeCache(params, seedWords)
+{
+ var cache = new Uint32Array(params.cacheSize >> 2);
+ var cacheNodeCount = params.cacheSize >> 6;
+
+ // Initialize cache
+ var keccak = new Keccak();
+ keccak.digestWords(cache, 0, 16, seedWords, 0, seedWords.length);
+ for (var n = 1; n < cacheNodeCount; ++n)
+ {
+ keccak.digestWords(cache, n<<4, 16, cache, (n-1)<<4, 16);
+ }
+
+ var tmp = new Uint32Array(16);
+
+ // Do randmemohash passes
+ for (var r = 0; r < params.cacheRounds; ++r)
+ {
+ for (var n = 0; n < cacheNodeCount; ++n)
+ {
+ var p0 = mod32(n + cacheNodeCount - 1, cacheNodeCount) << 4;
+ var p1 = mod32(cache[n<<4|0], cacheNodeCount) << 4;
+
+ for (var w = 0; w < 16; w=(w+1)|0)
+ {
+ tmp[w] = cache[p0 | w] ^ cache[p1 | w];
+ }
+
+ keccak.digestWords(cache, n<<4, 16, tmp, 0, tmp.length);
+ }
+ }
+ return cache;
+}
+
+function computeDagNode(o_node, params, cache, keccak, nodeIndex)
+{
+ var cacheNodeCount = params.cacheSize >> 6;
+ var dagParents = params.dagParents;
+
+ var c = (nodeIndex % cacheNodeCount) << 4;
+ var mix = o_node;
+ for (var w = 0; w < 16; ++w)
+ {
+ mix[w] = cache[c|w];
+ }
+ mix[0] ^= nodeIndex;
+ keccak.digestWords(mix, 0, 16, mix, 0, 16);
+
+ for (var p = 0; p < dagParents; ++p)
+ {
+ // compute cache node (word) index
+ c = mod32(fnv(nodeIndex ^ p, mix[p&15]), cacheNodeCount) << 4;
+
+ for (var w = 0; w < 16; ++w)
+ {
+ mix[w] = fnv(mix[w], cache[c|w]);
+ }
+ }
+
+ keccak.digestWords(mix, 0, 16, mix, 0, 16);
+}
+
+function computeHashInner(mix, params, cache, keccak, tempNode)
+{
+ var mixParents = params.mixParents|0;
+ var mixWordCount = params.mixSize >> 2;
+ var mixNodeCount = mixWordCount >> 4;
+ var dagPageCount = (params.dagSize / params.mixSize) >> 0;
+
+ // grab initial first word
+ var s0 = mix[0];
+
+ // initialise mix from initial 64 bytes
+ for (var w = 16; w < mixWordCount; ++w)
+ {
+ mix[w] = mix[w & 15];
+ }
+
+ for (var a = 0; a < mixParents; ++a)
+ {
+ var p = mod32(fnv(s0 ^ a, mix[a & (mixWordCount-1)]), dagPageCount);
+ var d = (p * mixNodeCount)|0;
+
+ for (var n = 0, w = 0; n < mixNodeCount; ++n, w += 16)
+ {
+ computeDagNode(tempNode, params, cache, keccak, (d + n)|0);
+
+ for (var v = 0; v < 16; ++v)
+ {
+ mix[w|v] = fnv(mix[w|v], tempNode[v]);
+ }
+ }
+ }
+}
+
+function convertSeed(seed)
+{
+ // todo, reconcile with spec, byte ordering?
+ // todo, big-endian conversion
+ var newSeed = util.toWords(seed);
+ if (newSeed === null)
+ throw Error("Invalid seed '" + seed + "'");
+ return newSeed;
+}
+
+exports.defaultParams = function()
+{
+ return {
+ cacheSize: 1048384,
+ cacheRounds: 3,
+ dagSize: 1073739904,
+ dagParents: 256,
+ mixSize: 128,
+ mixParents: 64,
+ };
+};
+
+exports.Ethash = function(params, seed)
+{
+ // precompute cache and related values
+ seed = convertSeed(seed);
+ var cache = computeCache(params, seed);
+
+ // preallocate buffers/etc
+ var initBuf = new ArrayBuffer(96);
+ var initBytes = new Uint8Array(initBuf);
+ var initWords = new Uint32Array(initBuf);
+ var mixWords = new Uint32Array(params.mixSize / 4);
+ var tempNode = new Uint32Array(16);
+ var keccak = new Keccak();
+
+ var retWords = new Uint32Array(8);
+ var retBytes = new Uint8Array(retWords.buffer); // supposedly read-only
+
+ this.hash = function(header, nonce)
+ {
+ // compute initial hash
+ initBytes.set(header, 0);
+ initBytes.set(nonce, 32);
+ keccak.digestWords(initWords, 0, 16, initWords, 0, 8 + nonce.length/4);
+
+ // compute mix
+ for (var i = 0; i != 16; ++i)
+ {
+ mixWords[i] = initWords[i];
+ }
+ computeHashInner(mixWords, params, cache, keccak, tempNode);
+
+ // compress mix and append to initWords
+ for (var i = 0; i != mixWords.length; i += 4)
+ {
+ initWords[16 + i/4] = fnv(fnv(fnv(mixWords[i], mixWords[i+1]), mixWords[i+2]), mixWords[i+3]);
+ }
+
+ // final Keccak hashes
+ keccak.digestWords(retWords, 0, 8, initWords, 0, 24); // Keccak-256(s + cmix)
+ return retBytes;
+ };
+
+ this.cacheDigest = function()
+ {
+ return keccak.digest(32, new Uint8Array(cache.buffer));
+ };
+};
+
+
+
+
diff --git a/Godeps/_workspace/src/github.com/ethereum/ethash/js/keccak.js b/Godeps/_workspace/src/github.com/ethereum/ethash/js/keccak.js
new file mode 100644
index 000000000..84ddde645
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/ethash/js/keccak.js
@@ -0,0 +1,404 @@
+// keccak.js
+// Tim Hughes <tim@twistedfury.com>
+// derived from Markku-Juhani O. Saarinen's C code (http://keccak.noekeon.org/readable_code.html)
+
+/*jslint node: true, shadow:true */
+"use strict";
+
+var Keccak_f1600_RC = new Uint32Array([
+ 0x00000001, 0x00000000,
+ 0x00008082, 0x00000000,
+ 0x0000808a, 0x80000000,
+ 0x80008000, 0x80000000,
+ 0x0000808b, 0x00000000,
+ 0x80000001, 0x00000000,
+ 0x80008081, 0x80000000,
+ 0x00008009, 0x80000000,
+ 0x0000008a, 0x00000000,
+ 0x00000088, 0x00000000,
+ 0x80008009, 0x00000000,
+ 0x8000000a, 0x00000000,
+ 0x8000808b, 0x00000000,
+ 0x0000008b, 0x80000000,
+ 0x00008089, 0x80000000,
+ 0x00008003, 0x80000000,
+ 0x00008002, 0x80000000,
+ 0x00000080, 0x80000000,
+ 0x0000800a, 0x00000000,
+ 0x8000000a, 0x80000000,
+ 0x80008081, 0x80000000,
+ 0x00008080, 0x80000000,
+ 0x80000001, 0x00000000,
+ 0x80008008, 0x80000000
+]);
+
+function keccak_f1600(outState, outOffset, outSize, inState)
+{
+ // todo, handle big endian loads
+ var a00l = inState[0]|0;
+ var a00h = inState[1]|0;
+ var a01l = inState[2]|0;
+ var a01h = inState[3]|0;
+ var a02l = inState[4]|0;
+ var a02h = inState[5]|0;
+ var a03l = inState[6]|0;
+ var a03h = inState[7]|0;
+ var a04l = inState[8]|0;
+ var a04h = inState[9]|0;
+ var a05l = inState[10]|0;
+ var a05h = inState[11]|0;
+ var a06l = inState[12]|0;
+ var a06h = inState[13]|0;
+ var a07l = inState[14]|0;
+ var a07h = inState[15]|0;
+ var a08l = inState[16]|0;
+ var a08h = inState[17]|0;
+ var a09l = inState[18]|0;
+ var a09h = inState[19]|0;
+ var a10l = inState[20]|0;
+ var a10h = inState[21]|0;
+ var a11l = inState[22]|0;
+ var a11h = inState[23]|0;
+ var a12l = inState[24]|0;
+ var a12h = inState[25]|0;
+ var a13l = inState[26]|0;
+ var a13h = inState[27]|0;
+ var a14l = inState[28]|0;
+ var a14h = inState[29]|0;
+ var a15l = inState[30]|0;
+ var a15h = inState[31]|0;
+ var a16l = inState[32]|0;
+ var a16h = inState[33]|0;
+ var a17l = inState[34]|0;
+ var a17h = inState[35]|0;
+ var a18l = inState[36]|0;
+ var a18h = inState[37]|0;
+ var a19l = inState[38]|0;
+ var a19h = inState[39]|0;
+ var a20l = inState[40]|0;
+ var a20h = inState[41]|0;
+ var a21l = inState[42]|0;
+ var a21h = inState[43]|0;
+ var a22l = inState[44]|0;
+ var a22h = inState[45]|0;
+ var a23l = inState[46]|0;
+ var a23h = inState[47]|0;
+ var a24l = inState[48]|0;
+ var a24h = inState[49]|0;
+ var b00l, b00h, b01l, b01h, b02l, b02h, b03l, b03h, b04l, b04h;
+ var b05l, b05h, b06l, b06h, b07l, b07h, b08l, b08h, b09l, b09h;
+ var b10l, b10h, b11l, b11h, b12l, b12h, b13l, b13h, b14l, b14h;
+ var b15l, b15h, b16l, b16h, b17l, b17h, b18l, b18h, b19l, b19h;
+ var b20l, b20h, b21l, b21h, b22l, b22h, b23l, b23h, b24l, b24h;
+ var tl, nl;
+ var th, nh;
+
+ for (var r = 0; r < 48; r = (r+2)|0)
+ {
+ // Theta
+ b00l = a00l ^ a05l ^ a10l ^ a15l ^ a20l;
+ b00h = a00h ^ a05h ^ a10h ^ a15h ^ a20h;
+ b01l = a01l ^ a06l ^ a11l ^ a16l ^ a21l;
+ b01h = a01h ^ a06h ^ a11h ^ a16h ^ a21h;
+ b02l = a02l ^ a07l ^ a12l ^ a17l ^ a22l;
+ b02h = a02h ^ a07h ^ a12h ^ a17h ^ a22h;
+ b03l = a03l ^ a08l ^ a13l ^ a18l ^ a23l;
+ b03h = a03h ^ a08h ^ a13h ^ a18h ^ a23h;
+ b04l = a04l ^ a09l ^ a14l ^ a19l ^ a24l;
+ b04h = a04h ^ a09h ^ a14h ^ a19h ^ a24h;
+ tl = b04l ^ (b01l << 1 | b01h >>> 31);
+ th = b04h ^ (b01h << 1 | b01l >>> 31);
+ a00l ^= tl;
+ a00h ^= th;
+ a05l ^= tl;
+ a05h ^= th;
+ a10l ^= tl;
+ a10h ^= th;
+ a15l ^= tl;
+ a15h ^= th;
+ a20l ^= tl;
+ a20h ^= th;
+ tl = b00l ^ (b02l << 1 | b02h >>> 31);
+ th = b00h ^ (b02h << 1 | b02l >>> 31);
+ a01l ^= tl;
+ a01h ^= th;
+ a06l ^= tl;
+ a06h ^= th;
+ a11l ^= tl;
+ a11h ^= th;
+ a16l ^= tl;
+ a16h ^= th;
+ a21l ^= tl;
+ a21h ^= th;
+ tl = b01l ^ (b03l << 1 | b03h >>> 31);
+ th = b01h ^ (b03h << 1 | b03l >>> 31);
+ a02l ^= tl;
+ a02h ^= th;
+ a07l ^= tl;
+ a07h ^= th;
+ a12l ^= tl;
+ a12h ^= th;
+ a17l ^= tl;
+ a17h ^= th;
+ a22l ^= tl;
+ a22h ^= th;
+ tl = b02l ^ (b04l << 1 | b04h >>> 31);
+ th = b02h ^ (b04h << 1 | b04l >>> 31);
+ a03l ^= tl;
+ a03h ^= th;
+ a08l ^= tl;
+ a08h ^= th;
+ a13l ^= tl;
+ a13h ^= th;
+ a18l ^= tl;
+ a18h ^= th;
+ a23l ^= tl;
+ a23h ^= th;
+ tl = b03l ^ (b00l << 1 | b00h >>> 31);
+ th = b03h ^ (b00h << 1 | b00l >>> 31);
+ a04l ^= tl;
+ a04h ^= th;
+ a09l ^= tl;
+ a09h ^= th;
+ a14l ^= tl;
+ a14h ^= th;
+ a19l ^= tl;
+ a19h ^= th;
+ a24l ^= tl;
+ a24h ^= th;
+
+ // Rho Pi
+ b00l = a00l;
+ b00h = a00h;
+ b10l = a01l << 1 | a01h >>> 31;
+ b10h = a01h << 1 | a01l >>> 31;
+ b07l = a10l << 3 | a10h >>> 29;
+ b07h = a10h << 3 | a10l >>> 29;
+ b11l = a07l << 6 | a07h >>> 26;
+ b11h = a07h << 6 | a07l >>> 26;
+ b17l = a11l << 10 | a11h >>> 22;
+ b17h = a11h << 10 | a11l >>> 22;
+ b18l = a17l << 15 | a17h >>> 17;
+ b18h = a17h << 15 | a17l >>> 17;
+ b03l = a18l << 21 | a18h >>> 11;
+ b03h = a18h << 21 | a18l >>> 11;
+ b05l = a03l << 28 | a03h >>> 4;
+ b05h = a03h << 28 | a03l >>> 4;
+ b16l = a05h << 4 | a05l >>> 28;
+ b16h = a05l << 4 | a05h >>> 28;
+ b08l = a16h << 13 | a16l >>> 19;
+ b08h = a16l << 13 | a16h >>> 19;
+ b21l = a08h << 23 | a08l >>> 9;
+ b21h = a08l << 23 | a08h >>> 9;
+ b24l = a21l << 2 | a21h >>> 30;
+ b24h = a21h << 2 | a21l >>> 30;
+ b04l = a24l << 14 | a24h >>> 18;
+ b04h = a24h << 14 | a24l >>> 18;
+ b15l = a04l << 27 | a04h >>> 5;
+ b15h = a04h << 27 | a04l >>> 5;
+ b23l = a15h << 9 | a15l >>> 23;
+ b23h = a15l << 9 | a15h >>> 23;
+ b19l = a23h << 24 | a23l >>> 8;
+ b19h = a23l << 24 | a23h >>> 8;
+ b13l = a19l << 8 | a19h >>> 24;
+ b13h = a19h << 8 | a19l >>> 24;
+ b12l = a13l << 25 | a13h >>> 7;
+ b12h = a13h << 25 | a13l >>> 7;
+ b02l = a12h << 11 | a12l >>> 21;
+ b02h = a12l << 11 | a12h >>> 21;
+ b20l = a02h << 30 | a02l >>> 2;
+ b20h = a02l << 30 | a02h >>> 2;
+ b14l = a20l << 18 | a20h >>> 14;
+ b14h = a20h << 18 | a20l >>> 14;
+ b22l = a14h << 7 | a14l >>> 25;
+ b22h = a14l << 7 | a14h >>> 25;
+ b09l = a22h << 29 | a22l >>> 3;
+ b09h = a22l << 29 | a22h >>> 3;
+ b06l = a09l << 20 | a09h >>> 12;
+ b06h = a09h << 20 | a09l >>> 12;
+ b01l = a06h << 12 | a06l >>> 20;
+ b01h = a06l << 12 | a06h >>> 20;
+
+ // Chi
+ a00l = b00l ^ ~b01l & b02l;
+ a00h = b00h ^ ~b01h & b02h;
+ a01l = b01l ^ ~b02l & b03l;
+ a01h = b01h ^ ~b02h & b03h;
+ a02l = b02l ^ ~b03l & b04l;
+ a02h = b02h ^ ~b03h & b04h;
+ a03l = b03l ^ ~b04l & b00l;
+ a03h = b03h ^ ~b04h & b00h;
+ a04l = b04l ^ ~b00l & b01l;
+ a04h = b04h ^ ~b00h & b01h;
+ a05l = b05l ^ ~b06l & b07l;
+ a05h = b05h ^ ~b06h & b07h;
+ a06l = b06l ^ ~b07l & b08l;
+ a06h = b06h ^ ~b07h & b08h;
+ a07l = b07l ^ ~b08l & b09l;
+ a07h = b07h ^ ~b08h & b09h;
+ a08l = b08l ^ ~b09l & b05l;
+ a08h = b08h ^ ~b09h & b05h;
+ a09l = b09l ^ ~b05l & b06l;
+ a09h = b09h ^ ~b05h & b06h;
+ a10l = b10l ^ ~b11l & b12l;
+ a10h = b10h ^ ~b11h & b12h;
+ a11l = b11l ^ ~b12l & b13l;
+ a11h = b11h ^ ~b12h & b13h;
+ a12l = b12l ^ ~b13l & b14l;
+ a12h = b12h ^ ~b13h & b14h;
+ a13l = b13l ^ ~b14l & b10l;
+ a13h = b13h ^ ~b14h & b10h;
+ a14l = b14l ^ ~b10l & b11l;
+ a14h = b14h ^ ~b10h & b11h;
+ a15l = b15l ^ ~b16l & b17l;
+ a15h = b15h ^ ~b16h & b17h;
+ a16l = b16l ^ ~b17l & b18l;
+ a16h = b16h ^ ~b17h & b18h;
+ a17l = b17l ^ ~b18l & b19l;
+ a17h = b17h ^ ~b18h & b19h;
+ a18l = b18l ^ ~b19l & b15l;
+ a18h = b18h ^ ~b19h & b15h;
+ a19l = b19l ^ ~b15l & b16l;
+ a19h = b19h ^ ~b15h & b16h;
+ a20l = b20l ^ ~b21l & b22l;
+ a20h = b20h ^ ~b21h & b22h;
+ a21l = b21l ^ ~b22l & b23l;
+ a21h = b21h ^ ~b22h & b23h;
+ a22l = b22l ^ ~b23l & b24l;
+ a22h = b22h ^ ~b23h & b24h;
+ a23l = b23l ^ ~b24l & b20l;
+ a23h = b23h ^ ~b24h & b20h;
+ a24l = b24l ^ ~b20l & b21l;
+ a24h = b24h ^ ~b20h & b21h;
+
+ // Iota
+ a00l ^= Keccak_f1600_RC[r|0];
+ a00h ^= Keccak_f1600_RC[r|1];
+ }
+
+ // todo, handle big-endian stores
+ outState[outOffset|0] = a00l;
+ outState[outOffset|1] = a00h;
+ outState[outOffset|2] = a01l;
+ outState[outOffset|3] = a01h;
+ outState[outOffset|4] = a02l;
+ outState[outOffset|5] = a02h;
+ outState[outOffset|6] = a03l;
+ outState[outOffset|7] = a03h;
+ if (outSize == 8)
+ return;
+ outState[outOffset|8] = a04l;
+ outState[outOffset|9] = a04h;
+ outState[outOffset|10] = a05l;
+ outState[outOffset|11] = a05h;
+ outState[outOffset|12] = a06l;
+ outState[outOffset|13] = a06h;
+ outState[outOffset|14] = a07l;
+ outState[outOffset|15] = a07h;
+ if (outSize == 16)
+ return;
+ outState[outOffset|16] = a08l;
+ outState[outOffset|17] = a08h;
+ outState[outOffset|18] = a09l;
+ outState[outOffset|19] = a09h;
+ outState[outOffset|20] = a10l;
+ outState[outOffset|21] = a10h;
+ outState[outOffset|22] = a11l;
+ outState[outOffset|23] = a11h;
+ outState[outOffset|24] = a12l;
+ outState[outOffset|25] = a12h;
+ outState[outOffset|26] = a13l;
+ outState[outOffset|27] = a13h;
+ outState[outOffset|28] = a14l;
+ outState[outOffset|29] = a14h;
+ outState[outOffset|30] = a15l;
+ outState[outOffset|31] = a15h;
+ outState[outOffset|32] = a16l;
+ outState[outOffset|33] = a16h;
+ outState[outOffset|34] = a17l;
+ outState[outOffset|35] = a17h;
+ outState[outOffset|36] = a18l;
+ outState[outOffset|37] = a18h;
+ outState[outOffset|38] = a19l;
+ outState[outOffset|39] = a19h;
+ outState[outOffset|40] = a20l;
+ outState[outOffset|41] = a20h;
+ outState[outOffset|42] = a21l;
+ outState[outOffset|43] = a21h;
+ outState[outOffset|44] = a22l;
+ outState[outOffset|45] = a22h;
+ outState[outOffset|46] = a23l;
+ outState[outOffset|47] = a23h;
+ outState[outOffset|48] = a24l;
+ outState[outOffset|49] = a24h;
+}
+
+var Keccak = function()
+{
+ var stateBuf = new ArrayBuffer(200);
+ var stateBytes = new Uint8Array(stateBuf);
+ var stateWords = new Uint32Array(stateBuf);
+
+ this.digest = function(oSize, iBytes)
+ {
+ for (var i = 0; i < 50; ++i)
+ {
+ stateWords[i] = 0;
+ }
+
+ var r = 200 - oSize*2;
+ var iLength = iBytes.length;
+ var iOffset = 0;
+ for ( ; ;)
+ {
+ var len = iLength < r ? iLength : r;
+ for (i = 0; i < len; ++i, ++iOffset)
+ {
+ stateBytes[i] ^= iBytes[iOffset];
+ }
+
+ if (iLength < r)
+ break;
+ iLength -= len;
+
+ keccak_f1600(stateWords, 0, 50, stateWords);
+ }
+
+ stateBytes[iLength] ^= 1;
+ stateBytes[r-1] ^= 0x80;
+ keccak_f1600(stateWords, 0, 50, stateWords);
+ return stateBytes.subarray(0, oSize);
+ };
+
+ this.digestWords = function(oWords, oOffset, oLength, iWords, iOffset, iLength)
+ {
+ for (var i = 0; i < 50; ++i)
+ {
+ stateWords[i] = 0;
+ }
+
+ var r = 50 - oLength*2;
+ for (; ; )
+ {
+ var len = iLength < r ? iLength : r;
+ for (i = 0; i < len; ++i, ++iOffset)
+ {
+ stateWords[i] ^= iWords[iOffset];
+ }
+
+ if (iLength < r)
+ break;
+ iLength -= len;
+
+ keccak_f1600(stateWords, 0, 50, stateWords);
+ }
+
+ stateBytes[iLength<<2] ^= 1;
+ stateBytes[(r<<2) - 1] ^= 0x80;
+ keccak_f1600(oWords, oOffset, oLength, stateWords);
+ };
+};
+
+module.exports = Keccak;
+
+
diff --git a/Godeps/_workspace/src/github.com/ethereum/ethash/js/makekeccak.js b/Godeps/_workspace/src/github.com/ethereum/ethash/js/makekeccak.js
new file mode 100644
index 000000000..c4db2b80a
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/ethash/js/makekeccak.js
@@ -0,0 +1,201 @@
+#!/usr/bin/env node
+// makekeccak.js
+// Tim Hughes <tim@twistedfury.com>
+
+/*jslint node: true, shadow:true */
+"use strict";
+
+var Keccak_f1600_Rho = [
+ 1, 3, 6, 10, 15, 21, 28, 36, 45, 55, 2, 14,
+ 27, 41, 56, 8, 25, 43, 62, 18, 39, 61, 20, 44
+];
+
+var Keccak_f1600_Pi= [
+ 10, 7, 11, 17, 18, 3, 5, 16, 8, 21, 24, 4,
+ 15, 23, 19, 13, 12, 2, 20, 14, 22, 9, 6, 1
+];
+
+var Keccak_f1600_RC = [
+ 0x00000001, 0x00000000,
+ 0x00008082, 0x00000000,
+ 0x0000808a, 0x80000000,
+ 0x80008000, 0x80000000,
+ 0x0000808b, 0x00000000,
+ 0x80000001, 0x00000000,
+ 0x80008081, 0x80000000,
+ 0x00008009, 0x80000000,
+ 0x0000008a, 0x00000000,
+ 0x00000088, 0x00000000,
+ 0x80008009, 0x00000000,
+ 0x8000000a, 0x00000000,
+ 0x8000808b, 0x00000000,
+ 0x0000008b, 0x80000000,
+ 0x00008089, 0x80000000,
+ 0x00008003, 0x80000000,
+ 0x00008002, 0x80000000,
+ 0x00000080, 0x80000000,
+ 0x0000800a, 0x00000000,
+ 0x8000000a, 0x80000000,
+ 0x80008081, 0x80000000,
+ 0x00008080, 0x80000000,
+ 0x80000001, 0x00000000,
+ 0x80008008, 0x80000000,
+];
+
+function makeRotLow(lo, hi, n)
+{
+ if (n === 0 || n === 32) throw Error("unsupported");
+ if ((n & 0x20) !== 0)
+ {
+ n &= ~0x20;
+ var t = hi;
+ hi = lo;
+ lo = t;
+ }
+ var hir = hi + " >>> " + (32 - n);
+ var los = lo + " << " + n;
+ return los + " | " + hir;
+}
+
+function makeRotHigh(lo, hi, n)
+{
+ if (n === 0 || n === 32) throw Error("unsupported");
+ if ((n & 0x20) !== 0)
+ {
+ n &= ~0x20;
+ var t = hi;
+ hi = lo;
+ lo = t;
+ }
+ var his = hi + " << " + n;
+ var lor = lo + " >>> " + (32 - n);
+ return his + " | " + lor;
+}
+
+function makeKeccak_f1600()
+{
+ var format = function(n)
+ {
+ return n < 10 ? "0"+n : ""+n;
+ };
+
+ var a = function(n, w)
+ {
+ return "a" + format(n) + (w !== 0?'h':'l');
+ };
+
+ var b = function(n, w)
+ {
+ return "b" + format(n) + (w !== 0?'h':'l');
+ };
+
+ var str = "";
+ str += "function keccak_f1600(outState, outOffset, outSize, inState)\n";
+ str += "{\n";
+
+ for (var i = 0; i < 25; ++i)
+ {
+ for (var w = 0; w <= 1; ++w)
+ {
+ str += "\tvar " + a(i,w) + " = inState["+(i<<1|w)+"]|0;\n";
+ }
+ }
+
+ for (var j = 0; j < 5; ++j)
+ {
+ str += "\tvar ";
+ for (var i = 0; i < 5; ++i)
+ {
+ if (i !== 0)
+ str += ", ";
+ str += b(j*5+i,0) + ", " + b(j*5+i,1);
+ }
+ str += ";\n";
+ }
+
+ str += "\tvar tl, th;\n";
+ str += "\n";
+ str += "\tfor (var r = 0; r < 48; r = (r+2)|0)\n";
+ str += "\t{\n";
+
+
+ // Theta
+ str += "\t\t// Theta\n";
+ for (var i = 0; i < 5; ++i)
+ {
+ for (var w = 0; w <= 1; ++w)
+ {
+ str += "\t\t" + b(i,w) + " = " + a(i,w) + " ^ " + a(i+5,w) + " ^ " + a(i+10,w) + " ^ " + a(i+15,w) + " ^ " + a(i+20,w) + ";\n";
+ }
+ }
+
+ for (var i = 0; i < 5; ++i)
+ {
+ var i4 = (i + 4) % 5;
+ var i1 = (i + 1) % 5;
+ str += "\t\ttl = " + b(i4,0) + " ^ (" + b(i1,0) + " << 1 | " + b(i1,1) + " >>> 31);\n";
+ str += "\t\tth = " + b(i4,1) + " ^ (" + b(i1,1) + " << 1 | " + b(i1,0) + " >>> 31);\n";
+
+ for (var j = 0; j < 25; j = (j+5)|0)
+ {
+ str += "\t\t" + a((j+i),0) + " ^= tl;\n";
+ str += "\t\t" + a((j+i),1) + " ^= th;\n";
+ }
+ }
+
+
+ // Rho Pi
+ str += "\n\t\t// Rho Pi\n";
+ for (var w = 0; w <= 1; ++w)
+ {
+ str += "\t\t" + b(0,w) + " = " + a(0,w) + ";\n";
+ }
+ var opi = 1;
+ for (var i = 0; i < 24; ++i)
+ {
+ var pi = Keccak_f1600_Pi[i];
+ str += "\t\t" + b(pi,0) + " = " + makeRotLow(a(opi,0), a(opi,1), Keccak_f1600_Rho[i]) + ";\n";
+ str += "\t\t" + b(pi,1) + " = " + makeRotHigh(a(opi,0), a(opi,1), Keccak_f1600_Rho[i]) + ";\n";
+ opi = pi;
+ }
+
+ // Chi
+ str += "\n\t\t// Chi\n";
+ for (var j = 0; j < 25; j += 5)
+ {
+ for (var i = 0; i < 5; ++i)
+ {
+ for (var w = 0; w <= 1; ++w)
+ {
+ str += "\t\t" + a(j+i,w) + " = " + b(j+i,w) + " ^ ~" + b(j+(i+1)%5,w) + " & " + b(j+(i+2)%5,w) + ";\n";
+ }
+ }
+ }
+
+ // Iota
+ str += "\n\t\t// Iota\n";
+ for (var w = 0; w <= 1; ++w)
+ {
+ str += "\t\t" + a(0,w) + " ^= Keccak_f1600_RC[r|" + w + "];\n";
+ }
+
+
+ str += "\t}\n";
+
+ for (var i = 0; i < 25; ++i)
+ {
+ if (i == 4 || i == 8)
+ {
+ str += "\tif (outSize == " + i*2 + ")\n\t\treturn;\n";
+ }
+ for (var w = 0; w <= 1; ++w)
+ {
+ str += "\toutState[outOffset|"+(i<<1|w)+"] = " + a(i,w) + ";\n";
+ }
+ }
+ str += "}\n";
+
+ return str;
+}
+
+console.log(makeKeccak_f1600());
diff --git a/Godeps/_workspace/src/github.com/ethereum/ethash/js/test.js b/Godeps/_workspace/src/github.com/ethereum/ethash/js/test.js
new file mode 100644
index 000000000..7ebb733ff
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/ethash/js/test.js
@@ -0,0 +1,53 @@
+// test.js
+// Tim Hughes <tim@twistedfury.com>
+
+/*jslint node: true, shadow:true */
+"use strict";
+
+var ethash = require('./ethash');
+var util = require('./util');
+var Keccak = require('./keccak');
+
+// sanity check hash functions
+var src = util.stringToBytes("");
+if (util.bytesToHexString(new Keccak().digest(32, src)) != "c5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470") throw Error("Keccak-256 failed");
+if (util.bytesToHexString(new Keccak().digest(64, src)) != "0eab42de4c3ceb9235fc91acffe746b29c29a8c366b7c60e4e67c466f36a4304c00fa9caf9d87976ba469bcbe06713b435f091ef2769fb160cdab33d3670680e") throw Error("Keccak-512 failed");
+
+src = new Uint32Array(src.buffer);
+var dst = new Uint32Array(8);
+new Keccak().digestWords(dst, 0, dst.length, src, 0, src.length);
+if (util.wordsToHexString(dst) != "c5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470") throw Error("Keccak-256 Fast failed");
+
+var dst = new Uint32Array(16);
+new Keccak().digestWords(dst, 0, dst.length, src, 0, src.length);
+if (util.wordsToHexString(dst) != "0eab42de4c3ceb9235fc91acffe746b29c29a8c366b7c60e4e67c466f36a4304c00fa9caf9d87976ba469bcbe06713b435f091ef2769fb160cdab33d3670680e") throw Error("Keccak-512 Fast failed");
+
+
+// init params
+var ethashParams = ethash.defaultParams();
+//ethashParams.cacheRounds = 0;
+
+// create hasher
+var seed = util.hexStringToBytes("9410b944535a83d9adf6bbdcc80e051f30676173c16ca0d32d6f1263fc246466")
+var startTime = new Date().getTime();
+var hasher = new ethash.Ethash(ethashParams, seed);
+console.log('Ethash startup took: '+(new Date().getTime() - startTime) + "ms");
+console.log('Ethash cache hash: ' + util.bytesToHexString(hasher.cacheDigest()));
+
+var testHexString = "c5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470";
+if (testHexString != util.bytesToHexString(util.hexStringToBytes(testHexString)))
+ throw Error("bytesToHexString or hexStringToBytes broken");
+
+
+var header = util.hexStringToBytes("c5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470");
+var nonce = util.hexStringToBytes("0000000000000000");
+var hash;
+
+startTime = new Date().getTime();
+var trials = 10;
+for (var i = 0; i < trials; ++i)
+{
+ hash = hasher.hash(header, nonce);
+}
+console.log("Light client hashes averaged: " + (new Date().getTime() - startTime)/trials + "ms");
+console.log("Hash = " + util.bytesToHexString(hash));
diff --git a/Godeps/_workspace/src/github.com/ethereum/ethash/js/util.js b/Godeps/_workspace/src/github.com/ethereum/ethash/js/util.js
new file mode 100644
index 000000000..79743cd91
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/ethash/js/util.js
@@ -0,0 +1,100 @@
+// util.js
+// Tim Hughes <tim@twistedfury.com>
+
+/*jslint node: true, shadow:true */
+"use strict";
+
+function nibbleToChar(nibble)
+{
+ return String.fromCharCode((nibble < 10 ? 48 : 87) + nibble);
+}
+
+function charToNibble(chr)
+{
+ if (chr >= 48 && chr <= 57)
+ {
+ return chr - 48;
+ }
+ if (chr >= 65 && chr <= 70)
+ {
+ return chr - 65 + 10;
+ }
+ if (chr >= 97 && chr <= 102)
+ {
+ return chr - 97 + 10;
+ }
+ return 0;
+}
+
+function stringToBytes(str)
+{
+ var bytes = new Uint8Array(str.length);
+ for (var i = 0; i != str.length; ++i)
+ {
+ bytes[i] = str.charCodeAt(i);
+ }
+ return bytes;
+}
+
+function hexStringToBytes(str)
+{
+ var bytes = new Uint8Array(str.length>>>1);
+ for (var i = 0; i != bytes.length; ++i)
+ {
+ bytes[i] = charToNibble(str.charCodeAt(i<<1 | 0)) << 4;
+ bytes[i] |= charToNibble(str.charCodeAt(i<<1 | 1));
+ }
+ return bytes;
+}
+
+function bytesToHexString(bytes)
+{
+ var str = "";
+ for (var i = 0; i != bytes.length; ++i)
+ {
+ str += nibbleToChar(bytes[i] >>> 4);
+ str += nibbleToChar(bytes[i] & 0xf);
+ }
+ return str;
+}
+
+function wordsToHexString(words)
+{
+ return bytesToHexString(new Uint8Array(words.buffer));
+}
+
+function uint32ToHexString(num)
+{
+ var buf = new Uint8Array(4);
+ buf[0] = (num >> 24) & 0xff;
+ buf[1] = (num >> 16) & 0xff;
+ buf[2] = (num >> 8) & 0xff;
+ buf[3] = (num >> 0) & 0xff;
+ return bytesToHexString(buf);
+}
+
+function toWords(input)
+{
+ if (input instanceof Uint32Array)
+ {
+ return input;
+ }
+ else if (input instanceof Uint8Array)
+ {
+ var tmp = new Uint8Array((input.length + 3) & ~3);
+ tmp.set(input);
+ return new Uint32Array(tmp.buffer);
+ }
+ else if (typeof input === typeof "")
+ {
+ return toWords(stringToBytes(input));
+ }
+ return null;
+}
+
+exports.stringToBytes = stringToBytes;
+exports.hexStringToBytes = hexStringToBytes;
+exports.bytesToHexString = bytesToHexString;
+exports.wordsToHexString = wordsToHexString;
+exports.uint32ToHexString = uint32ToHexString;
+exports.toWords = toWords; \ No newline at end of file
diff --git a/Godeps/_workspace/src/github.com/ethereum/ethash/setup.py b/Godeps/_workspace/src/github.com/ethereum/ethash/setup.py
new file mode 100644
index 000000000..29d6ad6d2
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/ethash/setup.py
@@ -0,0 +1,33 @@
+#!/usr/bin/env python
+from distutils.core import setup, Extension
+
+pyethash = Extension('pyethash',
+ sources = [
+ 'src/python/core.c',
+ 'src/libethash/util.c',
+ 'src/libethash/internal.c',
+ 'src/libethash/sha3.c'],
+ depends = [
+ 'src/libethash/ethash.h',
+ 'src/libethash/compiler.h',
+ 'src/libethash/data_sizes.h',
+ 'src/libethash/endian.h',
+ 'src/libethash/ethash.h',
+ 'src/libethash/fnv.h',
+ 'src/libethash/internal.h',
+ 'src/libethash/sha3.h',
+ 'src/libethash/util.h'
+ ],
+ extra_compile_args = ["-Isrc/", "-std=gnu99", "-Wall"])
+
+setup (
+ name = 'pyethash',
+ author = "Matthew Wampler-Doty",
+ author_email = "matthew.wampler.doty@gmail.com",
+ license = 'GPL',
+ version = '23',
+ url = 'https://github.com/ethereum/ethash',
+ download_url = 'https://github.com/ethereum/ethash/tarball/v23',
+ description = 'Python wrappers for ethash, the ethereum proof of work hashing function',
+ ext_modules = [pyethash],
+ )
diff --git a/Godeps/_workspace/src/github.com/ethereum/ethash/src/benchmark/CMakeLists.txt b/Godeps/_workspace/src/github.com/ethereum/ethash/src/benchmark/CMakeLists.txt
new file mode 100644
index 000000000..e6ba85790
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/ethash/src/benchmark/CMakeLists.txt
@@ -0,0 +1,53 @@
+include_directories(..)
+
+set(CMAKE_BUILD_TYPE Release)
+
+if (MSVC)
+ add_definitions("/openmp")
+endif()
+
+if (NOT MPI_FOUND)
+ find_package(MPI)
+endif()
+
+if (NOT CRYPTOPP_FOUND)
+ find_package(CryptoPP 5.6.2)
+endif()
+
+if (CRYPTOPP_FOUND)
+ add_definitions(-DWITH_CRYPTOPP)
+endif()
+
+if (NOT OpenCL_FOUND)
+ find_package(OpenCL)
+endif()
+if (OpenCL_FOUND)
+ add_definitions(-DWITH_OPENCL)
+ include_directories(${OpenCL_INCLUDE_DIRS})
+ list(APPEND FILES ethash_cl_miner.cpp ethash_cl_miner.h)
+endif()
+
+if (MPI_FOUND)
+ include_directories(${MPI_INCLUDE_PATH})
+ add_executable (Benchmark_MPI_FULL benchmark.cpp)
+ target_link_libraries (Benchmark_MPI_FULL ${ETHHASH_LIBS} ${MPI_LIBRARIES})
+ SET_TARGET_PROPERTIES(Benchmark_MPI_FULL PROPERTIES COMPILE_FLAGS "${COMPILE_FLAGS} ${MPI_COMPILE_FLAGS} -DFULL -DMPI")
+
+ add_executable (Benchmark_MPI_LIGHT benchmark.cpp)
+ target_link_libraries (Benchmark_MPI_LIGHT ${ETHHASH_LIBS} ${MPI_LIBRARIES})
+ SET_TARGET_PROPERTIES(Benchmark_MPI_LIGHT PROPERTIES COMPILE_FLAGS "${COMPILE_FLAGS} ${MPI_COMPILE_FLAGS} -DMPI")
+endif()
+
+add_executable (Benchmark_FULL benchmark.cpp)
+target_link_libraries (Benchmark_FULL ${ETHHASH_LIBS})
+SET_TARGET_PROPERTIES(Benchmark_FULL PROPERTIES COMPILE_FLAGS "${COMPILE_FLAGS} -DFULL")
+
+add_executable (Benchmark_LIGHT benchmark.cpp)
+target_link_libraries (Benchmark_LIGHT ${ETHHASH_LIBS})
+
+if (OpenCL_FOUND)
+ add_executable (Benchmark_CL benchmark.cpp)
+ target_link_libraries (Benchmark_CL ${ETHHASH_LIBS} ethash-cl)
+ SET_TARGET_PROPERTIES(Benchmark_CL PROPERTIES COMPILE_FLAGS "${COMPILE_FLAGS} -DOPENCL")
+endif()
+
diff --git a/Godeps/_workspace/src/github.com/ethereum/ethash/src/benchmark/benchmark.cpp b/Godeps/_workspace/src/github.com/ethereum/ethash/src/benchmark/benchmark.cpp
new file mode 100644
index 000000000..7dae4f18c
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/ethash/src/benchmark/benchmark.cpp
@@ -0,0 +1,260 @@
+/*
+ This file is part of cpp-ethereum.
+
+ cpp-ethereum is free software: you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation, either version 3 of the License, or
+ (at your option) any later version.
+
+ cpp-ethereum is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with cpp-ethereum. If not, see <http://www.gnu.org/licenses/>.
+*/
+/** @file benchmark.cpp
+ * @author Tim Hughes <tim@twistedfury.com>
+ * @date 2015
+ */
+
+#include <stdio.h>
+#include <stdlib.h>
+#include <time.h>
+#include <libethash/ethash.h>
+#include <libethash/util.h>
+#ifdef OPENCL
+#include <libethash-cl/ethash_cl_miner.h>
+#endif
+#include <vector>
+#include <algorithm>
+
+#ifdef WITH_CRYPTOPP
+#include <libethash/sha3_cryptopp.h>
+#include <string>
+
+#else
+#include "libethash/sha3.h"
+#endif // WITH_CRYPTOPP
+
+#undef min
+#undef max
+
+#if defined(OPENCL)
+const unsigned trials = 1024*1024*32;
+#elif defined(FULL)
+const unsigned trials = 1024*1024/8;
+#else
+const unsigned trials = 1024*1024/1024;
+#endif
+uint8_t g_hashes[1024*32];
+
+static char nibbleToChar(unsigned nibble)
+{
+ return (char) ((nibble >= 10 ? 'a'-10 : '0') + nibble);
+}
+
+static uint8_t charToNibble(char chr)
+{
+ if (chr >= '0' && chr <= '9')
+ {
+ return (uint8_t) (chr - '0');
+ }
+ if (chr >= 'a' && chr <= 'z')
+ {
+ return (uint8_t) (chr - 'a' + 10);
+ }
+ if (chr >= 'A' && chr <= 'Z')
+ {
+ return (uint8_t) (chr - 'A' + 10);
+ }
+ return 0;
+}
+
+static std::vector<uint8_t> hexStringToBytes(char const* str)
+{
+ std::vector<uint8_t> bytes(strlen(str) >> 1);
+ for (unsigned i = 0; i != bytes.size(); ++i)
+ {
+ bytes[i] = charToNibble(str[i*2 | 0]) << 4;
+ bytes[i] |= charToNibble(str[i*2 | 1]);
+ }
+ return bytes;
+}
+
+static std::string bytesToHexString(uint8_t const* bytes, unsigned size)
+{
+ std::string str;
+ for (unsigned i = 0; i != size; ++i)
+ {
+ str += nibbleToChar(bytes[i] >> 4);
+ str += nibbleToChar(bytes[i] & 0xf);
+ }
+ return str;
+}
+
+extern "C" int main(void)
+{
+ // params for ethash
+ ethash_params params;
+ ethash_params_init(&params, 0);
+ //params.full_size = 262147 * 4096; // 1GBish;
+ //params.full_size = 32771 * 4096; // 128MBish;
+ //params.full_size = 8209 * 4096; // 8MBish;
+ //params.cache_size = 8209*4096;
+ //params.cache_size = 2053*4096;
+ uint8_t seed[32], previous_hash[32];
+
+ memcpy(seed, hexStringToBytes("9410b944535a83d9adf6bbdcc80e051f30676173c16ca0d32d6f1263fc246466").data(), 32);
+ memcpy(previous_hash, hexStringToBytes("c5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470").data(), 32);
+
+ // allocate page aligned buffer for dataset
+#ifdef FULL
+ void* full_mem_buf = malloc(params.full_size + 4095);
+ void* full_mem = (void*)((uintptr_t(full_mem_buf) + 4095) & ~4095);
+#endif
+ void* cache_mem_buf = malloc(params.cache_size + 63);
+ void* cache_mem = (void*)((uintptr_t(cache_mem_buf) + 63) & ~63);
+
+ ethash_cache cache;
+ cache.mem = cache_mem;
+
+ // compute cache or full data
+ {
+ clock_t startTime = clock();
+ ethash_mkcache(&cache, &params, seed);
+ clock_t time = clock() - startTime;
+
+ uint8_t cache_hash[32];
+ SHA3_256(cache_hash, (uint8_t const*)cache_mem, params.cache_size);
+ debugf("ethash_mkcache: %ums, sha3: %s\n", (unsigned)((time*1000)/CLOCKS_PER_SEC), bytesToHexString(cache_hash,sizeof(cache_hash)).data());
+
+ // print a couple of test hashes
+ {
+ const clock_t startTime = clock();
+ ethash_return_value hash;
+ ethash_light(&hash, &cache, &params, previous_hash, 0);
+ const clock_t time = clock() - startTime;
+ debugf("ethash_light test: %ums, %s\n", (unsigned)((time*1000)/CLOCKS_PER_SEC), bytesToHexString(hash.result, 32).data());
+ }
+
+ #ifdef FULL
+ startTime = clock();
+ ethash_compute_full_data(full_mem, &params, &cache);
+ time = clock() - startTime;
+ debugf("ethash_compute_full_data: %ums\n", (unsigned)((time*1000)/CLOCKS_PER_SEC));
+ #endif // FULL
+ }
+
+#ifdef OPENCL
+ ethash_cl_miner miner;
+ {
+ const clock_t startTime = clock();
+ if (!miner.init(params, seed))
+ exit(-1);
+ const clock_t time = clock() - startTime;
+ debugf("ethash_cl_miner init: %ums\n", (unsigned)((time*1000)/CLOCKS_PER_SEC));
+ }
+#endif
+
+
+#ifdef FULL
+ {
+ const clock_t startTime = clock();
+ ethash_return_value hash;
+ ethash_full(&hash, full_mem, &params, previous_hash, 0);
+ const clock_t time = clock() - startTime;
+ debugf("ethash_full test: %uns, %s\n", (unsigned)((time*1000000)/CLOCKS_PER_SEC), bytesToHexString(hash.result, 32).data());
+ }
+#endif
+
+#ifdef OPENCL
+ // validate 1024 hashes against CPU
+ miner.hash(g_hashes, previous_hash, 0, 1024);
+ for (unsigned i = 0; i != 1024; ++i)
+ {
+ ethash_return_value hash;
+ ethash_light(&hash, &cache, &params, previous_hash, i);
+ if (memcmp(hash.result, g_hashes + 32*i, 32) != 0)
+ {
+ debugf("nonce %u failed: %s %s\n", i, bytesToHexString(g_hashes + 32*i, 32).c_str(), bytesToHexString(hash.result, 32).c_str());
+ static unsigned c = 0;
+ if (++c == 16)
+ {
+ exit(-1);
+ }
+ }
+ }
+#endif
+
+
+ clock_t startTime = clock();
+ unsigned hash_count = trials;
+
+ #ifdef OPENCL
+ {
+ struct search_hook : ethash_cl_miner::search_hook
+ {
+ unsigned hash_count;
+ std::vector<uint64_t> nonce_vec;
+
+ virtual bool found(uint64_t const* nonces, uint32_t count)
+ {
+ nonce_vec.assign(nonces, nonces + count);
+ return false;
+ }
+
+ virtual bool searched(uint64_t start_nonce, uint32_t count)
+ {
+ // do nothing
+ hash_count += count;
+ return hash_count >= trials;
+ }
+ };
+ search_hook hook;
+ hook.hash_count = 0;
+
+ miner.search(previous_hash, 0x000000ffffffffff, hook);
+
+ for (unsigned i = 0; i != hook.nonce_vec.size(); ++i)
+ {
+ uint64_t nonce = hook.nonce_vec[i];
+ ethash_return_value hash;
+ ethash_light(&hash, &cache, &params, previous_hash, nonce);
+ debugf("found: %.8x%.8x -> %s\n", unsigned(nonce>>32), unsigned(nonce), bytesToHexString(hash.result, 32).c_str());
+ }
+
+ hash_count = hook.hash_count;
+ }
+ #else
+ {
+ //#pragma omp parallel for
+ for (int nonce = 0; nonce < trials; ++nonce)
+ {
+ ethash_return_value hash;
+ #ifdef FULL
+ ethash_full(&hash, full_mem, &params, previous_hash, nonce);
+ #else
+ ethash_light(&hash, &cache, &params, previous_hash, nonce);
+ #endif // FULL
+ }
+ }
+ #endif
+
+ clock_t time = std::max((clock_t)1u, clock() - startTime);
+
+ unsigned read_size = ACCESSES * MIX_BYTES;
+ debugf(
+ "hashrate: %8u, bw: %6u MB/s\n",
+ (unsigned)(((uint64_t)hash_count*CLOCKS_PER_SEC)/time),
+ (unsigned)((((uint64_t)hash_count*read_size*CLOCKS_PER_SEC)/time) / (1024*1024))
+ );
+
+ free(cache_mem_buf);
+#ifdef FULL
+ free(full_mem_buf);
+#endif
+
+ return 0;
+}
diff --git a/Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash-cl/CMakeLists.txt b/Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash-cl/CMakeLists.txt
new file mode 100644
index 000000000..f37471cf3
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash-cl/CMakeLists.txt
@@ -0,0 +1,40 @@
+set(LIBRARY ethash-cl)
+set(CMAKE_BUILD_TYPE Release)
+
+include(bin2h.cmake)
+bin2h(SOURCE_FILE ethash_cl_miner_kernel.cl
+ VARIABLE_NAME ethash_cl_miner_kernel
+ HEADER_FILE ${CMAKE_CURRENT_BINARY_DIR}/ethash_cl_miner_kernel.h)
+
+if (NOT MSVC)
+ # Initialize CXXFLAGS for c++11
+ set(CMAKE_CXX_FLAGS "-Wall -std=c++11")
+ set(CMAKE_CXX_FLAGS_DEBUG "-O0 -g")
+ set(CMAKE_CXX_FLAGS_MINSIZEREL "-Os -DNDEBUG")
+ set(CMAKE_CXX_FLAGS_RELEASE "-O4 -DNDEBUG")
+ set(CMAKE_CXX_FLAGS_RELWITHDEBINFO "-O2 -g")
+
+ # Compiler-specific C++11 activation.
+ if ("${CMAKE_CXX_COMPILER_ID}" MATCHES "GNU")
+ execute_process(
+ COMMAND ${CMAKE_CXX_COMPILER} -dumpversion OUTPUT_VARIABLE GCC_VERSION)
+ if (NOT (GCC_VERSION VERSION_GREATER 4.7 OR GCC_VERSION VERSION_EQUAL 4.7))
+ message(FATAL_ERROR "${PROJECT_NAME} requires g++ 4.7 or greater.")
+ endif ()
+ elseif ("${CMAKE_CXX_COMPILER_ID}" MATCHES "Clang")
+ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -stdlib=libc++")
+ else ()
+ message(FATAL_ERROR "Your C++ compiler does not support C++11.")
+ endif ()
+endif()
+
+if (NOT OpenCL_FOUND)
+ find_package(OpenCL)
+endif()
+
+if (OpenCL_FOUND)
+ include_directories(${OpenCL_INCLUDE_DIRS} ${CMAKE_CURRENT_BINARY_DIR})
+ include_directories(..)
+ add_library(${LIBRARY} ethash_cl_miner.cpp ethash_cl_miner.h cl.hpp)
+ TARGET_LINK_LIBRARIES(${LIBRARY} ${OpenCL_LIBRARIES} ethash)
+endif()
diff --git a/Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash-cl/bin2h.cmake b/Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash-cl/bin2h.cmake
new file mode 100644
index 000000000..90ca9cc5b
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash-cl/bin2h.cmake
@@ -0,0 +1,86 @@
+# https://gist.github.com/sivachandran/3a0de157dccef822a230
+include(CMakeParseArguments)
+
+# Function to wrap a given string into multiple lines at the given column position.
+# Parameters:
+# VARIABLE - The name of the CMake variable holding the string.
+# AT_COLUMN - The column position at which string will be wrapped.
+function(WRAP_STRING)
+ set(oneValueArgs VARIABLE AT_COLUMN)
+ cmake_parse_arguments(WRAP_STRING "${options}" "${oneValueArgs}" "" ${ARGN})
+
+ string(LENGTH ${${WRAP_STRING_VARIABLE}} stringLength)
+ math(EXPR offset "0")
+
+ while(stringLength GREATER 0)
+
+ if(stringLength GREATER ${WRAP_STRING_AT_COLUMN})
+ math(EXPR length "${WRAP_STRING_AT_COLUMN}")
+ else()
+ math(EXPR length "${stringLength}")
+ endif()
+
+ string(SUBSTRING ${${WRAP_STRING_VARIABLE}} ${offset} ${length} line)
+ set(lines "${lines}\n${line}")
+
+ math(EXPR stringLength "${stringLength} - ${length}")
+ math(EXPR offset "${offset} + ${length}")
+ endwhile()
+
+ set(${WRAP_STRING_VARIABLE} "${lines}" PARENT_SCOPE)
+endfunction()
+
+# Function to embed contents of a file as byte array in C/C++ header file(.h). The header file
+# will contain a byte array and integer variable holding the size of the array.
+# Parameters
+# SOURCE_FILE - The path of source file whose contents will be embedded in the header file.
+# VARIABLE_NAME - The name of the variable for the byte array. The string "_SIZE" will be append
+# to this name and will be used a variable name for size variable.
+# HEADER_FILE - The path of header file.
+# APPEND - If specified appends to the header file instead of overwriting it
+# NULL_TERMINATE - If specified a null byte(zero) will be append to the byte array. This will be
+# useful if the source file is a text file and we want to use the file contents
+# as string. But the size variable holds size of the byte array without this
+# null byte.
+# Usage:
+# bin2h(SOURCE_FILE "Logo.png" HEADER_FILE "Logo.h" VARIABLE_NAME "LOGO_PNG")
+function(BIN2H)
+ set(options APPEND NULL_TERMINATE)
+ set(oneValueArgs SOURCE_FILE VARIABLE_NAME HEADER_FILE)
+ cmake_parse_arguments(BIN2H "${options}" "${oneValueArgs}" "" ${ARGN})
+
+ # reads source file contents as hex string
+ file(READ ${BIN2H_SOURCE_FILE} hexString HEX)
+ string(LENGTH ${hexString} hexStringLength)
+
+ # appends null byte if asked
+ if(BIN2H_NULL_TERMINATE)
+ set(hexString "${hexString}00")
+ endif()
+
+ # wraps the hex string into multiple lines at column 32(i.e. 16 bytes per line)
+ wrap_string(VARIABLE hexString AT_COLUMN 32)
+ math(EXPR arraySize "${hexStringLength} / 2")
+
+ # adds '0x' prefix and comma suffix before and after every byte respectively
+ string(REGEX REPLACE "([0-9a-f][0-9a-f])" "0x\\1, " arrayValues ${hexString})
+ # removes trailing comma
+ string(REGEX REPLACE ", $" "" arrayValues ${arrayValues})
+
+ # converts the variable name into proper C identifier
+ IF (${CMAKE_VERSION} GREATER 2.8.10) # fix for legacy cmake
+ string(MAKE_C_IDENTIFIER "${BIN2H_VARIABLE_NAME}" BIN2H_VARIABLE_NAME)
+ ENDIF()
+ string(TOUPPER "${BIN2H_VARIABLE_NAME}" BIN2H_VARIABLE_NAME)
+
+ # declares byte array and the length variables
+ set(arrayDefinition "const unsigned char ${BIN2H_VARIABLE_NAME}[] = { ${arrayValues} };")
+ set(arraySizeDefinition "const size_t ${BIN2H_VARIABLE_NAME}_SIZE = ${arraySize};")
+
+ set(declarations "${arrayDefinition}\n\n${arraySizeDefinition}\n\n")
+ if(BIN2H_APPEND)
+ file(APPEND ${BIN2H_HEADER_FILE} "${declarations}")
+ else()
+ file(WRITE ${BIN2H_HEADER_FILE} "${declarations}")
+ endif()
+endfunction()
diff --git a/Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash-cl/cl.hpp b/Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash-cl/cl.hpp
new file mode 100644
index 000000000..5c9be5c5e
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash-cl/cl.hpp
@@ -0,0 +1,12906 @@
+/*******************************************************************************
+ * Copyright (c) 2008-2015 The Khronos Group Inc.
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a
+ * copy of this software and/or associated documentation files (the
+ * "Materials"), to deal in the Materials without restriction, including
+ * without limitation the rights to use, copy, modify, merge, publish,
+ * distribute, sublicense, and/or sell copies of the Materials, and to
+ * permit persons to whom the Materials are furnished to do so, subject to
+ * the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included
+ * in all copies or substantial portions of the Materials.
+ *
+ * THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+ * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
+ * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
+ * CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
+ * TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+ * MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
+ ******************************************************************************/
+
+/*! \file
+ *
+ * \brief C++ bindings for OpenCL 1.0 (rev 48), OpenCL 1.1 (rev 33) and
+ * OpenCL 1.2 (rev 15)
+ * \author Benedict R. Gaster, Laurent Morichetti and Lee Howes
+ *
+ * Additions and fixes from:
+ * Brian Cole, March 3rd 2010 and April 2012
+ * Matt Gruenke, April 2012.
+ * Bruce Merry, February 2013.
+ * Tom Deakin and Simon McIntosh-Smith, July 2013
+ *
+ * \version 1.2.7
+ * \date January 2015
+ *
+ * Optional extension support
+ *
+ * cl
+ * cl_ext_device_fission
+ * #define USE_CL_DEVICE_FISSION
+ */
+
+/*! \mainpage
+ * \section intro Introduction
+ * For many large applications C++ is the language of choice and so it seems
+ * reasonable to define C++ bindings for OpenCL.
+ *
+ *
+ * The interface is contained with a single C++ header file \em cl.hpp and all
+ * definitions are contained within the namespace \em cl. There is no additional
+ * requirement to include \em cl.h and to use either the C++ or original C
+ * bindings it is enough to simply include \em cl.hpp.
+ *
+ * The bindings themselves are lightweight and correspond closely to the
+ * underlying C API. Using the C++ bindings introduces no additional execution
+ * overhead.
+ *
+ * For detail documentation on the bindings see:
+ *
+ * The OpenCL C++ Wrapper API 1.2 (revision 09)
+ * http://www.khronos.org/registry/cl/specs/opencl-cplusplus-1.2.pdf
+ *
+ * \section example Example
+ *
+ * The following example shows a general use case for the C++
+ * bindings, including support for the optional exception feature and
+ * also the supplied vector and string classes, see following sections for
+ * decriptions of these features.
+ *
+ * \code
+ * #define __CL_ENABLE_EXCEPTIONS
+ *
+ * #if defined(__APPLE__) || defined(__MACOSX)
+ * #include <OpenCL/cl.hpp>
+ * #else
+ * #include <CL/cl.hpp>
+ * #endif
+ * #include <cstdio>
+ * #include <cstdlib>
+ * #include <iostream>
+ *
+ * const char * helloStr = "__kernel void "
+ * "hello(void) "
+ * "{ "
+ * " "
+ * "} ";
+ *
+ * int
+ * main(void)
+ * {
+ * cl_int err = CL_SUCCESS;
+ * try {
+ *
+ * std::vector<cl::Platform> platforms;
+ * cl::Platform::get(&platforms);
+ * if (platforms.size() == 0) {
+ * std::cout << "Platform size 0\n";
+ * return -1;
+ * }
+ *
+ * cl_context_properties properties[] =
+ * { CL_CONTEXT_PLATFORM, (cl_context_properties)(platforms[0])(), 0};
+ * cl::Context context(CL_DEVICE_TYPE_CPU, properties);
+ *
+ * std::vector<cl::Device> devices = context.getInfo<CL_CONTEXT_DEVICES>();
+ *
+ * cl::Program::Sources source(1,
+ * std::make_pair(helloStr,strlen(helloStr)));
+ * cl::Program program_ = cl::Program(context, source);
+ * program_.build(devices);
+ *
+ * cl::Kernel kernel(program_, "hello", &err);
+ *
+ * cl::Event event;
+ * cl::CommandQueue queue(context, devices[0], 0, &err);
+ * queue.enqueueNDRangeKernel(
+ * kernel,
+ * cl::NullRange,
+ * cl::NDRange(4,4),
+ * cl::NullRange,
+ * NULL,
+ * &event);
+ *
+ * event.wait();
+ * }
+ * catch (cl::Error err) {
+ * std::cerr
+ * << "ERROR: "
+ * << err.what()
+ * << "("
+ * << err.err()
+ * << ")"
+ * << std::endl;
+ * }
+ *
+ * return EXIT_SUCCESS;
+ * }
+ *
+ * \endcode
+ *
+ */
+#ifndef CL_HPP_
+#define CL_HPP_
+
+#ifdef _WIN32
+
+#include <malloc.h>
+
+#if defined(USE_DX_INTEROP)
+#include <CL/cl_d3d10.h>
+#include <CL/cl_dx9_media_sharing.h>
+#endif
+#endif // _WIN32
+
+#if defined(_MSC_VER)
+#include <intrin.h>
+#endif // _MSC_VER
+
+//
+#if defined(USE_CL_DEVICE_FISSION)
+#include <CL/cl_ext.h>
+#endif
+
+#if defined(__APPLE__) || defined(__MACOSX)
+#include <OpenCL/opencl.h>
+#else
+#include <CL/opencl.h>
+#endif // !__APPLE__
+
+#if (_MSC_VER >= 1700) || (__cplusplus >= 201103L)
+#define CL_HPP_RVALUE_REFERENCES_SUPPORTED
+#define CL_HPP_CPP11_ATOMICS_SUPPORTED
+#include <atomic>
+#endif
+
+#if (__cplusplus >= 201103L)
+#define CL_HPP_NOEXCEPT noexcept
+#else
+#define CL_HPP_NOEXCEPT
+#endif
+
+
+// To avoid accidentally taking ownership of core OpenCL types
+// such as cl_kernel constructors are made explicit
+// under OpenCL 1.2
+#if defined(CL_VERSION_1_2) && !defined(CL_USE_DEPRECATED_OPENCL_1_1_APIS)
+#define __CL_EXPLICIT_CONSTRUCTORS explicit
+#else // #if defined(CL_USE_DEPRECATED_OPENCL_1_1_APIS)
+#define __CL_EXPLICIT_CONSTRUCTORS
+#endif // #if defined(CL_USE_DEPRECATED_OPENCL_1_1_APIS)
+
+// Define deprecated prefixes and suffixes to ensure compilation
+// in case they are not pre-defined
+#if !defined(CL_EXT_PREFIX__VERSION_1_1_DEPRECATED)
+#define CL_EXT_PREFIX__VERSION_1_1_DEPRECATED
+#endif // #if !defined(CL_EXT_PREFIX__VERSION_1_1_DEPRECATED)
+#if !defined(CL_EXT_SUFFIX__VERSION_1_1_DEPRECATED)
+#define CL_EXT_SUFFIX__VERSION_1_1_DEPRECATED
+#endif // #if !defined(CL_EXT_PREFIX__VERSION_1_1_DEPRECATED)
+
+#if !defined(CL_CALLBACK)
+#define CL_CALLBACK
+#endif //CL_CALLBACK
+
+#include <utility>
+#include <limits>
+#include <iterator>
+
+#if defined(__CL_ENABLE_EXCEPTIONS)
+#include <exception>
+#endif // #if defined(__CL_ENABLE_EXCEPTIONS)
+
+#if !defined(__NO_STD_VECTOR)
+#include <vector>
+#endif
+
+#if !defined(__NO_STD_STRING)
+#include <string>
+#endif
+
+#if defined(__ANDROID__) || defined(linux) || defined(__APPLE__) || defined(__MACOSX)
+#include <alloca.h>
+#endif // linux
+
+#include <cstring>
+
+
+/*! \namespace cl
+ *
+ * \brief The OpenCL C++ bindings are defined within this namespace.
+ *
+ */
+namespace cl {
+
+class Memory;
+
+/**
+ * Deprecated APIs for 1.2
+ */
+#if defined(CL_USE_DEPRECATED_OPENCL_1_1_APIS) || (defined(CL_VERSION_1_1) && !defined(CL_VERSION_1_2))
+#define __INIT_CL_EXT_FCN_PTR(name) \
+ if(!pfn_##name) { \
+ pfn_##name = (PFN_##name) \
+ clGetExtensionFunctionAddress(#name); \
+ if(!pfn_##name) { \
+ } \
+ }
+#endif // #if defined(CL_VERSION_1_1)
+
+#if defined(CL_VERSION_1_2)
+#define __INIT_CL_EXT_FCN_PTR_PLATFORM(platform, name) \
+ if(!pfn_##name) { \
+ pfn_##name = (PFN_##name) \
+ clGetExtensionFunctionAddressForPlatform(platform, #name); \
+ if(!pfn_##name) { \
+ } \
+ }
+#endif // #if defined(CL_VERSION_1_1)
+
+class Program;
+class Device;
+class Context;
+class CommandQueue;
+class Memory;
+class Buffer;
+
+#if defined(__CL_ENABLE_EXCEPTIONS)
+/*! \brief Exception class
+ *
+ * This may be thrown by API functions when __CL_ENABLE_EXCEPTIONS is defined.
+ */
+class Error : public std::exception
+{
+private:
+ cl_int err_;
+ const char * errStr_;
+public:
+ /*! \brief Create a new CL error exception for a given error code
+ * and corresponding message.
+ *
+ * \param err error code value.
+ *
+ * \param errStr a descriptive string that must remain in scope until
+ * handling of the exception has concluded. If set, it
+ * will be returned by what().
+ */
+ Error(cl_int err, const char * errStr = NULL) : err_(err), errStr_(errStr)
+ {}
+
+ ~Error() throw() {}
+
+ /*! \brief Get error string associated with exception
+ *
+ * \return A memory pointer to the error message string.
+ */
+ virtual const char * what() const throw ()
+ {
+ if (errStr_ == NULL) {
+ return "empty";
+ }
+ else {
+ return errStr_;
+ }
+ }
+
+ /*! \brief Get error code associated with exception
+ *
+ * \return The error code.
+ */
+ cl_int err(void) const { return err_; }
+};
+
+#define __ERR_STR(x) #x
+#else
+#define __ERR_STR(x) NULL
+#endif // __CL_ENABLE_EXCEPTIONS
+
+
+namespace detail
+{
+#if defined(__CL_ENABLE_EXCEPTIONS)
+static inline cl_int errHandler (
+ cl_int err,
+ const char * errStr = NULL)
+{
+ if (err != CL_SUCCESS) {
+ throw Error(err, errStr);
+ }
+ return err;
+}
+#else
+static inline cl_int errHandler (cl_int err, const char * errStr = NULL)
+{
+ (void) errStr; // suppress unused variable warning
+ return err;
+}
+#endif // __CL_ENABLE_EXCEPTIONS
+}
+
+
+
+//! \cond DOXYGEN_DETAIL
+#if !defined(__CL_USER_OVERRIDE_ERROR_STRINGS)
+#define __GET_DEVICE_INFO_ERR __ERR_STR(clGetDeviceInfo)
+#define __GET_PLATFORM_INFO_ERR __ERR_STR(clGetPlatformInfo)
+#define __GET_DEVICE_IDS_ERR __ERR_STR(clGetDeviceIDs)
+#define __GET_PLATFORM_IDS_ERR __ERR_STR(clGetPlatformIDs)
+#define __GET_CONTEXT_INFO_ERR __ERR_STR(clGetContextInfo)
+#define __GET_EVENT_INFO_ERR __ERR_STR(clGetEventInfo)
+#define __GET_EVENT_PROFILE_INFO_ERR __ERR_STR(clGetEventProfileInfo)
+#define __GET_MEM_OBJECT_INFO_ERR __ERR_STR(clGetMemObjectInfo)
+#define __GET_IMAGE_INFO_ERR __ERR_STR(clGetImageInfo)
+#define __GET_SAMPLER_INFO_ERR __ERR_STR(clGetSamplerInfo)
+#define __GET_KERNEL_INFO_ERR __ERR_STR(clGetKernelInfo)
+#if defined(CL_VERSION_1_2)
+#define __GET_KERNEL_ARG_INFO_ERR __ERR_STR(clGetKernelArgInfo)
+#endif // #if defined(CL_VERSION_1_2)
+#define __GET_KERNEL_WORK_GROUP_INFO_ERR __ERR_STR(clGetKernelWorkGroupInfo)
+#define __GET_PROGRAM_INFO_ERR __ERR_STR(clGetProgramInfo)
+#define __GET_PROGRAM_BUILD_INFO_ERR __ERR_STR(clGetProgramBuildInfo)
+#define __GET_COMMAND_QUEUE_INFO_ERR __ERR_STR(clGetCommandQueueInfo)
+
+#define __CREATE_CONTEXT_ERR __ERR_STR(clCreateContext)
+#define __CREATE_CONTEXT_FROM_TYPE_ERR __ERR_STR(clCreateContextFromType)
+#define __GET_SUPPORTED_IMAGE_FORMATS_ERR __ERR_STR(clGetSupportedImageFormats)
+
+#define __CREATE_BUFFER_ERR __ERR_STR(clCreateBuffer)
+#define __COPY_ERR __ERR_STR(cl::copy)
+#define __CREATE_SUBBUFFER_ERR __ERR_STR(clCreateSubBuffer)
+#define __CREATE_GL_BUFFER_ERR __ERR_STR(clCreateFromGLBuffer)
+#define __CREATE_GL_RENDER_BUFFER_ERR __ERR_STR(clCreateFromGLBuffer)
+#define __GET_GL_OBJECT_INFO_ERR __ERR_STR(clGetGLObjectInfo)
+#if defined(CL_VERSION_1_2)
+#define __CREATE_IMAGE_ERR __ERR_STR(clCreateImage)
+#define __CREATE_GL_TEXTURE_ERR __ERR_STR(clCreateFromGLTexture)
+#define __IMAGE_DIMENSION_ERR __ERR_STR(Incorrect image dimensions)
+#endif // #if defined(CL_VERSION_1_2)
+#define __CREATE_SAMPLER_ERR __ERR_STR(clCreateSampler)
+#define __SET_MEM_OBJECT_DESTRUCTOR_CALLBACK_ERR __ERR_STR(clSetMemObjectDestructorCallback)
+
+#define __CREATE_USER_EVENT_ERR __ERR_STR(clCreateUserEvent)
+#define __SET_USER_EVENT_STATUS_ERR __ERR_STR(clSetUserEventStatus)
+#define __SET_EVENT_CALLBACK_ERR __ERR_STR(clSetEventCallback)
+#define __WAIT_FOR_EVENTS_ERR __ERR_STR(clWaitForEvents)
+
+#define __CREATE_KERNEL_ERR __ERR_STR(clCreateKernel)
+#define __SET_KERNEL_ARGS_ERR __ERR_STR(clSetKernelArg)
+#define __CREATE_PROGRAM_WITH_SOURCE_ERR __ERR_STR(clCreateProgramWithSource)
+#define __CREATE_PROGRAM_WITH_BINARY_ERR __ERR_STR(clCreateProgramWithBinary)
+#if defined(CL_VERSION_1_2)
+#define __CREATE_PROGRAM_WITH_BUILT_IN_KERNELS_ERR __ERR_STR(clCreateProgramWithBuiltInKernels)
+#endif // #if defined(CL_VERSION_1_2)
+#define __BUILD_PROGRAM_ERR __ERR_STR(clBuildProgram)
+#if defined(CL_VERSION_1_2)
+#define __COMPILE_PROGRAM_ERR __ERR_STR(clCompileProgram)
+#define __LINK_PROGRAM_ERR __ERR_STR(clLinkProgram)
+#endif // #if defined(CL_VERSION_1_2)
+#define __CREATE_KERNELS_IN_PROGRAM_ERR __ERR_STR(clCreateKernelsInProgram)
+
+#define __CREATE_COMMAND_QUEUE_ERR __ERR_STR(clCreateCommandQueue)
+#define __SET_COMMAND_QUEUE_PROPERTY_ERR __ERR_STR(clSetCommandQueueProperty)
+#define __ENQUEUE_READ_BUFFER_ERR __ERR_STR(clEnqueueReadBuffer)
+#define __ENQUEUE_READ_BUFFER_RECT_ERR __ERR_STR(clEnqueueReadBufferRect)
+#define __ENQUEUE_WRITE_BUFFER_ERR __ERR_STR(clEnqueueWriteBuffer)
+#define __ENQUEUE_WRITE_BUFFER_RECT_ERR __ERR_STR(clEnqueueWriteBufferRect)
+#define __ENQEUE_COPY_BUFFER_ERR __ERR_STR(clEnqueueCopyBuffer)
+#define __ENQEUE_COPY_BUFFER_RECT_ERR __ERR_STR(clEnqueueCopyBufferRect)
+#define __ENQUEUE_FILL_BUFFER_ERR __ERR_STR(clEnqueueFillBuffer)
+#define __ENQUEUE_READ_IMAGE_ERR __ERR_STR(clEnqueueReadImage)
+#define __ENQUEUE_WRITE_IMAGE_ERR __ERR_STR(clEnqueueWriteImage)
+#define __ENQUEUE_COPY_IMAGE_ERR __ERR_STR(clEnqueueCopyImage)
+#define __ENQUEUE_FILL_IMAGE_ERR __ERR_STR(clEnqueueFillImage)
+#define __ENQUEUE_COPY_IMAGE_TO_BUFFER_ERR __ERR_STR(clEnqueueCopyImageToBuffer)
+#define __ENQUEUE_COPY_BUFFER_TO_IMAGE_ERR __ERR_STR(clEnqueueCopyBufferToImage)
+#define __ENQUEUE_MAP_BUFFER_ERR __ERR_STR(clEnqueueMapBuffer)
+#define __ENQUEUE_MAP_IMAGE_ERR __ERR_STR(clEnqueueMapImage)
+#define __ENQUEUE_UNMAP_MEM_OBJECT_ERR __ERR_STR(clEnqueueUnMapMemObject)
+#define __ENQUEUE_NDRANGE_KERNEL_ERR __ERR_STR(clEnqueueNDRangeKernel)
+#define __ENQUEUE_TASK_ERR __ERR_STR(clEnqueueTask)
+#define __ENQUEUE_NATIVE_KERNEL __ERR_STR(clEnqueueNativeKernel)
+#if defined(CL_VERSION_1_2)
+#define __ENQUEUE_MIGRATE_MEM_OBJECTS_ERR __ERR_STR(clEnqueueMigrateMemObjects)
+#endif // #if defined(CL_VERSION_1_2)
+
+#define __ENQUEUE_ACQUIRE_GL_ERR __ERR_STR(clEnqueueAcquireGLObjects)
+#define __ENQUEUE_RELEASE_GL_ERR __ERR_STR(clEnqueueReleaseGLObjects)
+
+
+#define __RETAIN_ERR __ERR_STR(Retain Object)
+#define __RELEASE_ERR __ERR_STR(Release Object)
+#define __FLUSH_ERR __ERR_STR(clFlush)
+#define __FINISH_ERR __ERR_STR(clFinish)
+#define __VECTOR_CAPACITY_ERR __ERR_STR(Vector capacity error)
+
+/**
+ * CL 1.2 version that uses device fission.
+ */
+#if defined(CL_VERSION_1_2)
+#define __CREATE_SUB_DEVICES __ERR_STR(clCreateSubDevices)
+#else
+#define __CREATE_SUB_DEVICES __ERR_STR(clCreateSubDevicesEXT)
+#endif // #if defined(CL_VERSION_1_2)
+
+/**
+ * Deprecated APIs for 1.2
+ */
+#if defined(CL_USE_DEPRECATED_OPENCL_1_1_APIS) || (defined(CL_VERSION_1_1) && !defined(CL_VERSION_1_2))
+#define __ENQUEUE_MARKER_ERR __ERR_STR(clEnqueueMarker)
+#define __ENQUEUE_WAIT_FOR_EVENTS_ERR __ERR_STR(clEnqueueWaitForEvents)
+#define __ENQUEUE_BARRIER_ERR __ERR_STR(clEnqueueBarrier)
+#define __UNLOAD_COMPILER_ERR __ERR_STR(clUnloadCompiler)
+#define __CREATE_GL_TEXTURE_2D_ERR __ERR_STR(clCreateFromGLTexture2D)
+#define __CREATE_GL_TEXTURE_3D_ERR __ERR_STR(clCreateFromGLTexture3D)
+#define __CREATE_IMAGE2D_ERR __ERR_STR(clCreateImage2D)
+#define __CREATE_IMAGE3D_ERR __ERR_STR(clCreateImage3D)
+#endif // #if defined(CL_VERSION_1_1)
+
+#endif // __CL_USER_OVERRIDE_ERROR_STRINGS
+//! \endcond
+
+/**
+ * CL 1.2 marker and barrier commands
+ */
+#if defined(CL_VERSION_1_2)
+#define __ENQUEUE_MARKER_WAIT_LIST_ERR __ERR_STR(clEnqueueMarkerWithWaitList)
+#define __ENQUEUE_BARRIER_WAIT_LIST_ERR __ERR_STR(clEnqueueBarrierWithWaitList)
+#endif // #if defined(CL_VERSION_1_2)
+
+#if !defined(__USE_DEV_STRING) && !defined(__NO_STD_STRING)
+typedef std::string STRING_CLASS;
+#elif !defined(__USE_DEV_STRING)
+
+/*! \class string
+ * \brief Simple string class, that provides a limited subset of std::string
+ * functionality but avoids many of the issues that come with that class.
+
+ * \note Deprecated. Please use std::string as default or
+ * re-define the string class to match the std::string
+ * interface by defining STRING_CLASS
+ */
+class CL_EXT_PREFIX__VERSION_1_1_DEPRECATED string CL_EXT_SUFFIX__VERSION_1_1_DEPRECATED
+{
+private:
+ ::size_t size_;
+ char * str_;
+public:
+ //! \brief Constructs an empty string, allocating no memory.
+ string(void) : size_(0), str_(NULL)
+ {
+ }
+
+ /*! \brief Constructs a string populated from an arbitrary value of
+ * specified size.
+ *
+ * An extra '\0' is added, in case none was contained in str.
+ *
+ * \param str the initial value of the string instance. Note that '\0'
+ * characters receive no special treatment. If NULL,
+ * the string is left empty, with a size of 0.
+ *
+ * \param size the number of characters to copy from str.
+ */
+ string(const char * str, ::size_t size) :
+ size_(size),
+ str_(NULL)
+ {
+ if( size > 0 ) {
+ str_ = new char[size_+1];
+ if (str_ != NULL) {
+ memcpy(str_, str, size_ * sizeof(char));
+ str_[size_] = '\0';
+ }
+ else {
+ size_ = 0;
+ }
+ }
+ }
+
+ /*! \brief Constructs a string populated from a null-terminated value.
+ *
+ * \param str the null-terminated initial value of the string instance.
+ * If NULL, the string is left empty, with a size of 0.
+ */
+ string(const char * str) :
+ size_(0),
+ str_(NULL)
+ {
+ if( str ) {
+ size_= ::strlen(str);
+ }
+ if( size_ > 0 ) {
+ str_ = new char[size_ + 1];
+ if (str_ != NULL) {
+ memcpy(str_, str, (size_ + 1) * sizeof(char));
+ }
+ }
+ }
+
+ void resize( ::size_t n )
+ {
+ if( size_ == n ) {
+ return;
+ }
+ if (n == 0) {
+ if( str_ ) {
+ delete [] str_;
+ }
+ str_ = NULL;
+ size_ = 0;
+ }
+ else {
+ char *newString = new char[n + 1];
+ ::size_t copySize = n;
+ if( size_ < n ) {
+ copySize = size_;
+ }
+ size_ = n;
+
+ if(str_) {
+ memcpy(newString, str_, (copySize + 1) * sizeof(char));
+ }
+ if( copySize < size_ ) {
+ memset(newString + copySize, 0, size_ - copySize);
+ }
+ newString[size_] = '\0';
+
+ delete [] str_;
+ str_ = newString;
+ }
+ }
+
+ const char& operator[] ( ::size_t pos ) const
+ {
+ return str_[pos];
+ }
+
+ char& operator[] ( ::size_t pos )
+ {
+ return str_[pos];
+ }
+
+ /*! \brief Copies the value of another string to this one.
+ *
+ * \param rhs the string to copy.
+ *
+ * \returns a reference to the modified instance.
+ */
+ string& operator=(const string& rhs)
+ {
+ if (this == &rhs) {
+ return *this;
+ }
+
+ if( str_ != NULL ) {
+ delete [] str_;
+ str_ = NULL;
+ size_ = 0;
+ }
+
+ if (rhs.size_ == 0 || rhs.str_ == NULL) {
+ str_ = NULL;
+ size_ = 0;
+ }
+ else {
+ str_ = new char[rhs.size_ + 1];
+ size_ = rhs.size_;
+
+ if (str_ != NULL) {
+ memcpy(str_, rhs.str_, (size_ + 1) * sizeof(char));
+ }
+ else {
+ size_ = 0;
+ }
+ }
+
+ return *this;
+ }
+
+ /*! \brief Constructs a string by copying the value of another instance.
+ *
+ * \param rhs the string to copy.
+ */
+ string(const string& rhs) :
+ size_(0),
+ str_(NULL)
+ {
+ *this = rhs;
+ }
+
+ //! \brief Destructor - frees memory used to hold the current value.
+ ~string()
+ {
+ delete[] str_;
+ str_ = NULL;
+ }
+
+ //! \brief Queries the length of the string, excluding any added '\0's.
+ ::size_t size(void) const { return size_; }
+
+ //! \brief Queries the length of the string, excluding any added '\0's.
+ ::size_t length(void) const { return size(); }
+
+ /*! \brief Returns a pointer to the private copy held by this instance,
+ * or "" if empty/unset.
+ */
+ const char * c_str(void) const { return (str_) ? str_ : "";}
+};
+typedef cl::string STRING_CLASS;
+#endif // #elif !defined(__USE_DEV_STRING)
+
+#if !defined(__USE_DEV_VECTOR) && !defined(__NO_STD_VECTOR)
+#define VECTOR_CLASS std::vector
+#elif !defined(__USE_DEV_VECTOR)
+#define VECTOR_CLASS cl::vector
+
+#if !defined(__MAX_DEFAULT_VECTOR_SIZE)
+#define __MAX_DEFAULT_VECTOR_SIZE 10
+#endif
+
+/*! \class vector
+ * \brief Fixed sized vector implementation that mirroring
+ *
+ * \note Deprecated. Please use std::vector as default or
+ * re-define the vector class to match the std::vector
+ * interface by defining VECTOR_CLASS
+
+ * \note Not recommended for use with custom objects as
+ * current implementation will construct N elements
+ *
+ * std::vector functionality.
+ * \brief Fixed sized vector compatible with std::vector.
+ *
+ * \note
+ * This differs from std::vector<> not just in memory allocation,
+ * but also in terms of when members are constructed, destroyed,
+ * and assigned instead of being copy constructed.
+ *
+ * \param T type of element contained in the vector.
+ *
+ * \param N maximum size of the vector.
+ */
+template <typename T, unsigned int N = __MAX_DEFAULT_VECTOR_SIZE>
+class CL_EXT_PREFIX__VERSION_1_1_DEPRECATED vector
+{
+private:
+ T data_[N];
+ unsigned int size_;
+
+public:
+ //! \brief Constructs an empty vector with no memory allocated.
+ vector() :
+ size_(static_cast<unsigned int>(0))
+ {}
+
+ //! \brief Deallocates the vector's memory and destroys all of its elements.
+ ~vector()
+ {
+ clear();
+ }
+
+ //! \brief Returns the number of elements currently contained.
+ unsigned int size(void) const
+ {
+ return size_;
+ }
+
+ /*! \brief Empties the vector of all elements.
+ * \note
+ * This does not deallocate memory but will invoke destructors
+ * on contained elements.
+ */
+ void clear()
+ {
+ while(!empty()) {
+ pop_back();
+ }
+ }
+
+ /*! \brief Appends an element after the last valid element.
+ * Calling this on a vector that has reached capacity will throw an
+ * exception if exceptions are enabled.
+ */
+ void push_back (const T& x)
+ {
+ if (size() < N) {
+ new (&data_[size_]) T(x);
+ size_++;
+ } else {
+ detail::errHandler(CL_MEM_OBJECT_ALLOCATION_FAILURE, __VECTOR_CAPACITY_ERR);
+ }
+ }
+
+ /*! \brief Removes the last valid element from the vector.
+ * Calling this on an empty vector will throw an exception
+ * if exceptions are enabled.
+ */
+ void pop_back(void)
+ {
+ if (size_ != 0) {
+ --size_;
+ data_[size_].~T();
+ } else {
+ detail::errHandler(CL_MEM_OBJECT_ALLOCATION_FAILURE, __VECTOR_CAPACITY_ERR);
+ }
+ }
+
+ /*! \brief Constructs with a value copied from another.
+ *
+ * \param vec the vector to copy.
+ */
+ vector(const vector<T, N>& vec) :
+ size_(vec.size_)
+ {
+ if (size_ != 0) {
+ assign(vec.begin(), vec.end());
+ }
+ }
+
+ /*! \brief Constructs with a specified number of initial elements.
+ *
+ * \param size number of initial elements.
+ *
+ * \param val value of initial elements.
+ */
+ vector(unsigned int size, const T& val = T()) :
+ size_(0)
+ {
+ for (unsigned int i = 0; i < size; i++) {
+ push_back(val);
+ }
+ }
+
+ /*! \brief Overwrites the current content with that copied from another
+ * instance.
+ *
+ * \param rhs vector to copy.
+ *
+ * \returns a reference to this.
+ */
+ vector<T, N>& operator=(const vector<T, N>& rhs)
+ {
+ if (this == &rhs) {
+ return *this;
+ }
+
+ if (rhs.size_ != 0) {
+ assign(rhs.begin(), rhs.end());
+ } else {
+ clear();
+ }
+
+ return *this;
+ }
+
+ /*! \brief Tests equality against another instance.
+ *
+ * \param vec the vector against which to compare.
+ */
+ bool operator==(vector<T,N> &vec)
+ {
+ if (size() != vec.size()) {
+ return false;
+ }
+
+ for( unsigned int i = 0; i < size(); ++i ) {
+ if( operator[](i) != vec[i] ) {
+ return false;
+ }
+ }
+ return true;
+ }
+
+ //! \brief Conversion operator to T*.
+ operator T* () { return data_; }
+
+ //! \brief Conversion operator to const T*.
+ operator const T* () const { return data_; }
+
+ //! \brief Tests whether this instance has any elements.
+ bool empty (void) const
+ {
+ return size_==0;
+ }
+
+ //! \brief Returns the maximum number of elements this instance can hold.
+ unsigned int max_size (void) const
+ {
+ return N;
+ }
+
+ //! \brief Returns the maximum number of elements this instance can hold.
+ unsigned int capacity () const
+ {
+ return N;
+ }
+
+ //! \brief Resizes the vector to the given size
+ void resize(unsigned int newSize, T fill = T())
+ {
+ if (newSize > N)
+ {
+ detail::errHandler(CL_MEM_OBJECT_ALLOCATION_FAILURE, __VECTOR_CAPACITY_ERR);
+ }
+ else
+ {
+ while (size_ < newSize)
+ {
+ new (&data_[size_]) T(fill);
+ size_++;
+ }
+ while (size_ > newSize)
+ {
+ --size_;
+ data_[size_].~T();
+ }
+ }
+ }
+
+ /*! \brief Returns a reference to a given element.
+ *
+ * \param index which element to access. *
+ * \note
+ * The caller is responsible for ensuring index is >= 0 and < size().
+ */
+ T& operator[](int index)
+ {
+ return data_[index];
+ }
+
+ /*! \brief Returns a const reference to a given element.
+ *
+ * \param index which element to access.
+ *
+ * \note
+ * The caller is responsible for ensuring index is >= 0 and < size().
+ */
+ const T& operator[](int index) const
+ {
+ return data_[index];
+ }
+
+ /*! \brief Assigns elements of the vector based on a source iterator range.
+ *
+ * \param start Beginning iterator of source range
+ * \param end Enditerator of source range
+ *
+ * \note
+ * Will throw an exception if exceptions are enabled and size exceeded.
+ */
+ template<class I>
+ void assign(I start, I end)
+ {
+ clear();
+ while(start != end) {
+ push_back(*start);
+ start++;
+ }
+ }
+
+ /*! \class iterator
+ * \brief Const iterator class for vectors
+ */
+ class iterator
+ {
+ private:
+ const vector<T,N> *vec_;
+ int index_;
+
+ /**
+ * Internal iterator constructor to capture reference
+ * to the vector it iterates over rather than taking
+ * the vector by copy.
+ */
+ iterator (const vector<T,N> &vec, int index) :
+ vec_(&vec)
+ {
+ if( !vec.empty() ) {
+ index_ = index;
+ } else {
+ index_ = -1;
+ }
+ }
+
+ public:
+ iterator(void) :
+ index_(-1),
+ vec_(NULL)
+ {
+ }
+
+ iterator(const iterator& rhs) :
+ vec_(rhs.vec_),
+ index_(rhs.index_)
+ {
+ }
+
+ ~iterator(void) {}
+
+ static iterator begin(const cl::vector<T,N> &vec)
+ {
+ iterator i(vec, 0);
+
+ return i;
+ }
+
+ static iterator end(const cl::vector<T,N> &vec)
+ {
+ iterator i(vec, vec.size());
+
+ return i;
+ }
+
+ bool operator==(iterator i)
+ {
+ return ((vec_ == i.vec_) &&
+ (index_ == i.index_));
+ }
+
+ bool operator!=(iterator i)
+ {
+ return (!(*this==i));
+ }
+
+ iterator& operator++()
+ {
+ ++index_;
+ return *this;
+ }
+
+ iterator operator++(int)
+ {
+ iterator retVal(*this);
+ ++index_;
+ return retVal;
+ }
+
+ iterator& operator--()
+ {
+ --index_;
+ return *this;
+ }
+
+ iterator operator--(int)
+ {
+ iterator retVal(*this);
+ --index_;
+ return retVal;
+ }
+
+ const T& operator *() const
+ {
+ return (*vec_)[index_];
+ }
+ };
+
+ iterator begin(void)
+ {
+ return iterator::begin(*this);
+ }
+
+ iterator begin(void) const
+ {
+ return iterator::begin(*this);
+ }
+
+ iterator end(void)
+ {
+ return iterator::end(*this);
+ }
+
+ iterator end(void) const
+ {
+ return iterator::end(*this);
+ }
+
+ T& front(void)
+ {
+ return data_[0];
+ }
+
+ T& back(void)
+ {
+ return data_[size_];
+ }
+
+ const T& front(void) const
+ {
+ return data_[0];
+ }
+
+ const T& back(void) const
+ {
+ return data_[size_-1];
+ }
+} CL_EXT_SUFFIX__VERSION_1_1_DEPRECATED;
+#endif // #if !defined(__USE_DEV_VECTOR) && !defined(__NO_STD_VECTOR)
+
+
+
+
+
+namespace detail {
+#define __DEFAULT_NOT_INITIALIZED 1
+#define __DEFAULT_BEING_INITIALIZED 2
+#define __DEFAULT_INITIALIZED 4
+
+ /*
+ * Compare and exchange primitives are needed for handling of defaults
+ */
+
+#ifdef CL_HPP_CPP11_ATOMICS_SUPPORTED
+ inline int compare_exchange(std::atomic<int> * dest, int exchange, int comparand)
+#else // !CL_HPP_CPP11_ATOMICS_SUPPORTED
+ inline int compare_exchange(volatile int * dest, int exchange, int comparand)
+#endif // !CL_HPP_CPP11_ATOMICS_SUPPORTED
+ {
+#ifdef CL_HPP_CPP11_ATOMICS_SUPPORTED
+ std::atomic_compare_exchange_strong(dest, &comparand, exchange);
+ return comparand;
+#elif _MSC_VER
+ return (int)(_InterlockedCompareExchange(
+ (volatile long*)dest,
+ (long)exchange,
+ (long)comparand));
+#else // !_MSC_VER && !CL_HPP_CPP11_ATOMICS_SUPPORTED
+ return (__sync_val_compare_and_swap(
+ dest,
+ comparand,
+ exchange));
+#endif // !CL_HPP_CPP11_ATOMICS_SUPPORTED
+ }
+
+ inline void fence() {
+#ifdef CL_HPP_CPP11_ATOMICS_SUPPORTED
+ std::atomic_thread_fence(std::memory_order_seq_cst);
+#elif _MSC_VER // !CL_HPP_CPP11_ATOMICS_SUPPORTED
+ _ReadWriteBarrier();
+#else // !_MSC_VER && !CL_HPP_CPP11_ATOMICS_SUPPORTED
+ __sync_synchronize();
+#endif // !CL_HPP_CPP11_ATOMICS_SUPPORTED
+ }
+} // namespace detail
+
+
+/*! \brief class used to interface between C++ and
+ * OpenCL C calls that require arrays of size_t values, whose
+ * size is known statically.
+ */
+template <int N>
+class size_t
+{
+private:
+ ::size_t data_[N];
+
+public:
+ //! \brief Initialize size_t to all 0s
+ size_t()
+ {
+ for( int i = 0; i < N; ++i ) {
+ data_[i] = 0;
+ }
+ }
+
+ ::size_t& operator[](int index)
+ {
+ return data_[index];
+ }
+
+ const ::size_t& operator[](int index) const
+ {
+ return data_[index];
+ }
+
+ //! \brief Conversion operator to T*.
+ operator ::size_t* () { return data_; }
+
+ //! \brief Conversion operator to const T*.
+ operator const ::size_t* () const { return data_; }
+};
+
+namespace detail {
+
+// Generic getInfoHelper. The final parameter is used to guide overload
+// resolution: the actual parameter passed is an int, which makes this
+// a worse conversion sequence than a specialization that declares the
+// parameter as an int.
+template<typename Functor, typename T>
+inline cl_int getInfoHelper(Functor f, cl_uint name, T* param, long)
+{
+ return f(name, sizeof(T), param, NULL);
+}
+
+// Specialized getInfoHelper for VECTOR_CLASS params
+template <typename Func, typename T>
+inline cl_int getInfoHelper(Func f, cl_uint name, VECTOR_CLASS<T>* param, long)
+{
+ ::size_t required;
+ cl_int err = f(name, 0, NULL, &required);
+ if (err != CL_SUCCESS) {
+ return err;
+ }
+
+ T* value = (T*) alloca(required);
+ err = f(name, required, value, NULL);
+ if (err != CL_SUCCESS) {
+ return err;
+ }
+
+ param->assign(&value[0], &value[required/sizeof(T)]);
+ return CL_SUCCESS;
+}
+
+/* Specialization for reference-counted types. This depends on the
+ * existence of Wrapper<T>::cl_type, and none of the other types having the
+ * cl_type member. Note that simplify specifying the parameter as Wrapper<T>
+ * does not work, because when using a derived type (e.g. Context) the generic
+ * template will provide a better match.
+ */
+template <typename Func, typename T>
+inline cl_int getInfoHelper(Func f, cl_uint name, VECTOR_CLASS<T>* param, int, typename T::cl_type = 0)
+{
+ ::size_t required;
+ cl_int err = f(name, 0, NULL, &required);
+ if (err != CL_SUCCESS) {
+ return err;
+ }
+
+ typename T::cl_type * value = (typename T::cl_type *) alloca(required);
+ err = f(name, required, value, NULL);
+ if (err != CL_SUCCESS) {
+ return err;
+ }
+
+ ::size_t elements = required / sizeof(typename T::cl_type);
+ param->assign(&value[0], &value[elements]);
+ for (::size_t i = 0; i < elements; i++)
+ {
+ if (value[i] != NULL)
+ {
+ err = (*param)[i].retain();
+ if (err != CL_SUCCESS) {
+ return err;
+ }
+ }
+ }
+ return CL_SUCCESS;
+}
+
+// Specialized for getInfo<CL_PROGRAM_BINARIES>
+template <typename Func>
+inline cl_int getInfoHelper(Func f, cl_uint name, VECTOR_CLASS<char *>* param, int)
+{
+ cl_int err = f(name, param->size() * sizeof(char *), &(*param)[0], NULL);
+
+ if (err != CL_SUCCESS) {
+ return err;
+ }
+
+ return CL_SUCCESS;
+}
+
+// Specialized GetInfoHelper for STRING_CLASS params
+template <typename Func>
+inline cl_int getInfoHelper(Func f, cl_uint name, STRING_CLASS* param, long)
+{
+ ::size_t required;
+ cl_int err = f(name, 0, NULL, &required);
+ if (err != CL_SUCCESS) {
+ return err;
+ }
+
+ // std::string has a constant data member
+ // a char vector does not
+ VECTOR_CLASS<char> value(required);
+ err = f(name, required, value.data(), NULL);
+ if (err != CL_SUCCESS) {
+ return err;
+ }
+ if (param) {
+ param->assign(value.begin(), value.end());
+ }
+ return CL_SUCCESS;
+}
+
+// Specialized GetInfoHelper for cl::size_t params
+template <typename Func, ::size_t N>
+inline cl_int getInfoHelper(Func f, cl_uint name, size_t<N>* param, long)
+{
+ ::size_t required;
+ cl_int err = f(name, 0, NULL, &required);
+ if (err != CL_SUCCESS) {
+ return err;
+ }
+
+ ::size_t* value = (::size_t*) alloca(required);
+ err = f(name, required, value, NULL);
+ if (err != CL_SUCCESS) {
+ return err;
+ }
+
+ for(int i = 0; i < N; ++i) {
+ (*param)[i] = value[i];
+ }
+
+ return CL_SUCCESS;
+}
+
+template<typename T> struct ReferenceHandler;
+
+/* Specialization for reference-counted types. This depends on the
+ * existence of Wrapper<T>::cl_type, and none of the other types having the
+ * cl_type member. Note that simplify specifying the parameter as Wrapper<T>
+ * does not work, because when using a derived type (e.g. Context) the generic
+ * template will provide a better match.
+ */
+template<typename Func, typename T>
+inline cl_int getInfoHelper(Func f, cl_uint name, T* param, int, typename T::cl_type = 0)
+{
+ typename T::cl_type value;
+ cl_int err = f(name, sizeof(value), &value, NULL);
+ if (err != CL_SUCCESS) {
+ return err;
+ }
+ *param = value;
+ if (value != NULL)
+ {
+ err = param->retain();
+ if (err != CL_SUCCESS) {
+ return err;
+ }
+ }
+ return CL_SUCCESS;
+}
+
+#define __PARAM_NAME_INFO_1_0(F) \
+ F(cl_platform_info, CL_PLATFORM_PROFILE, STRING_CLASS) \
+ F(cl_platform_info, CL_PLATFORM_VERSION, STRING_CLASS) \
+ F(cl_platform_info, CL_PLATFORM_NAME, STRING_CLASS) \
+ F(cl_platform_info, CL_PLATFORM_VENDOR, STRING_CLASS) \
+ F(cl_platform_info, CL_PLATFORM_EXTENSIONS, STRING_CLASS) \
+ \
+ F(cl_device_info, CL_DEVICE_TYPE, cl_device_type) \
+ F(cl_device_info, CL_DEVICE_VENDOR_ID, cl_uint) \
+ F(cl_device_info, CL_DEVICE_MAX_COMPUTE_UNITS, cl_uint) \
+ F(cl_device_info, CL_DEVICE_MAX_WORK_ITEM_DIMENSIONS, cl_uint) \
+ F(cl_device_info, CL_DEVICE_MAX_WORK_GROUP_SIZE, ::size_t) \
+ F(cl_device_info, CL_DEVICE_MAX_WORK_ITEM_SIZES, VECTOR_CLASS< ::size_t>) \
+ F(cl_device_info, CL_DEVICE_PREFERRED_VECTOR_WIDTH_CHAR, cl_uint) \
+ F(cl_device_info, CL_DEVICE_PREFERRED_VECTOR_WIDTH_SHORT, cl_uint) \
+ F(cl_device_info, CL_DEVICE_PREFERRED_VECTOR_WIDTH_INT, cl_uint) \
+ F(cl_device_info, CL_DEVICE_PREFERRED_VECTOR_WIDTH_LONG, cl_uint) \
+ F(cl_device_info, CL_DEVICE_PREFERRED_VECTOR_WIDTH_FLOAT, cl_uint) \
+ F(cl_device_info, CL_DEVICE_PREFERRED_VECTOR_WIDTH_DOUBLE, cl_uint) \
+ F(cl_device_info, CL_DEVICE_MAX_CLOCK_FREQUENCY, cl_uint) \
+ F(cl_device_info, CL_DEVICE_ADDRESS_BITS, cl_uint) \
+ F(cl_device_info, CL_DEVICE_MAX_READ_IMAGE_ARGS, cl_uint) \
+ F(cl_device_info, CL_DEVICE_MAX_WRITE_IMAGE_ARGS, cl_uint) \
+ F(cl_device_info, CL_DEVICE_MAX_MEM_ALLOC_SIZE, cl_ulong) \
+ F(cl_device_info, CL_DEVICE_IMAGE2D_MAX_WIDTH, ::size_t) \
+ F(cl_device_info, CL_DEVICE_IMAGE2D_MAX_HEIGHT, ::size_t) \
+ F(cl_device_info, CL_DEVICE_IMAGE3D_MAX_WIDTH, ::size_t) \
+ F(cl_device_info, CL_DEVICE_IMAGE3D_MAX_HEIGHT, ::size_t) \
+ F(cl_device_info, CL_DEVICE_IMAGE3D_MAX_DEPTH, ::size_t) \
+ F(cl_device_info, CL_DEVICE_IMAGE_SUPPORT, cl_bool) \
+ F(cl_device_info, CL_DEVICE_MAX_PARAMETER_SIZE, ::size_t) \
+ F(cl_device_info, CL_DEVICE_MAX_SAMPLERS, cl_uint) \
+ F(cl_device_info, CL_DEVICE_MEM_BASE_ADDR_ALIGN, cl_uint) \
+ F(cl_device_info, CL_DEVICE_MIN_DATA_TYPE_ALIGN_SIZE, cl_uint) \
+ F(cl_device_info, CL_DEVICE_SINGLE_FP_CONFIG, cl_device_fp_config) \
+ F(cl_device_info, CL_DEVICE_GLOBAL_MEM_CACHE_TYPE, cl_device_mem_cache_type) \
+ F(cl_device_info, CL_DEVICE_GLOBAL_MEM_CACHELINE_SIZE, cl_uint)\
+ F(cl_device_info, CL_DEVICE_GLOBAL_MEM_CACHE_SIZE, cl_ulong) \
+ F(cl_device_info, CL_DEVICE_GLOBAL_MEM_SIZE, cl_ulong) \
+ F(cl_device_info, CL_DEVICE_MAX_CONSTANT_BUFFER_SIZE, cl_ulong) \
+ F(cl_device_info, CL_DEVICE_MAX_CONSTANT_ARGS, cl_uint) \
+ F(cl_device_info, CL_DEVICE_LOCAL_MEM_TYPE, cl_device_local_mem_type) \
+ F(cl_device_info, CL_DEVICE_LOCAL_MEM_SIZE, cl_ulong) \
+ F(cl_device_info, CL_DEVICE_ERROR_CORRECTION_SUPPORT, cl_bool) \
+ F(cl_device_info, CL_DEVICE_PROFILING_TIMER_RESOLUTION, ::size_t) \
+ F(cl_device_info, CL_DEVICE_ENDIAN_LITTLE, cl_bool) \
+ F(cl_device_info, CL_DEVICE_AVAILABLE, cl_bool) \
+ F(cl_device_info, CL_DEVICE_COMPILER_AVAILABLE, cl_bool) \
+ F(cl_device_info, CL_DEVICE_EXECUTION_CAPABILITIES, cl_device_exec_capabilities) \
+ F(cl_device_info, CL_DEVICE_QUEUE_PROPERTIES, cl_command_queue_properties) \
+ F(cl_device_info, CL_DEVICE_PLATFORM, cl_platform_id) \
+ F(cl_device_info, CL_DEVICE_NAME, STRING_CLASS) \
+ F(cl_device_info, CL_DEVICE_VENDOR, STRING_CLASS) \
+ F(cl_device_info, CL_DRIVER_VERSION, STRING_CLASS) \
+ F(cl_device_info, CL_DEVICE_PROFILE, STRING_CLASS) \
+ F(cl_device_info, CL_DEVICE_VERSION, STRING_CLASS) \
+ F(cl_device_info, CL_DEVICE_EXTENSIONS, STRING_CLASS) \
+ \
+ F(cl_context_info, CL_CONTEXT_REFERENCE_COUNT, cl_uint) \
+ F(cl_context_info, CL_CONTEXT_DEVICES, VECTOR_CLASS<Device>) \
+ F(cl_context_info, CL_CONTEXT_PROPERTIES, VECTOR_CLASS<cl_context_properties>) \
+ \
+ F(cl_event_info, CL_EVENT_COMMAND_QUEUE, cl::CommandQueue) \
+ F(cl_event_info, CL_EVENT_COMMAND_TYPE, cl_command_type) \
+ F(cl_event_info, CL_EVENT_REFERENCE_COUNT, cl_uint) \
+ F(cl_event_info, CL_EVENT_COMMAND_EXECUTION_STATUS, cl_int) \
+ \
+ F(cl_profiling_info, CL_PROFILING_COMMAND_QUEUED, cl_ulong) \
+ F(cl_profiling_info, CL_PROFILING_COMMAND_SUBMIT, cl_ulong) \
+ F(cl_profiling_info, CL_PROFILING_COMMAND_START, cl_ulong) \
+ F(cl_profiling_info, CL_PROFILING_COMMAND_END, cl_ulong) \
+ \
+ F(cl_mem_info, CL_MEM_TYPE, cl_mem_object_type) \
+ F(cl_mem_info, CL_MEM_FLAGS, cl_mem_flags) \
+ F(cl_mem_info, CL_MEM_SIZE, ::size_t) \
+ F(cl_mem_info, CL_MEM_HOST_PTR, void*) \
+ F(cl_mem_info, CL_MEM_MAP_COUNT, cl_uint) \
+ F(cl_mem_info, CL_MEM_REFERENCE_COUNT, cl_uint) \
+ F(cl_mem_info, CL_MEM_CONTEXT, cl::Context) \
+ \
+ F(cl_image_info, CL_IMAGE_FORMAT, cl_image_format) \
+ F(cl_image_info, CL_IMAGE_ELEMENT_SIZE, ::size_t) \
+ F(cl_image_info, CL_IMAGE_ROW_PITCH, ::size_t) \
+ F(cl_image_info, CL_IMAGE_SLICE_PITCH, ::size_t) \
+ F(cl_image_info, CL_IMAGE_WIDTH, ::size_t) \
+ F(cl_image_info, CL_IMAGE_HEIGHT, ::size_t) \
+ F(cl_image_info, CL_IMAGE_DEPTH, ::size_t) \
+ \
+ F(cl_sampler_info, CL_SAMPLER_REFERENCE_COUNT, cl_uint) \
+ F(cl_sampler_info, CL_SAMPLER_CONTEXT, cl::Context) \
+ F(cl_sampler_info, CL_SAMPLER_NORMALIZED_COORDS, cl_addressing_mode) \
+ F(cl_sampler_info, CL_SAMPLER_ADDRESSING_MODE, cl_filter_mode) \
+ F(cl_sampler_info, CL_SAMPLER_FILTER_MODE, cl_bool) \
+ \
+ F(cl_program_info, CL_PROGRAM_REFERENCE_COUNT, cl_uint) \
+ F(cl_program_info, CL_PROGRAM_CONTEXT, cl::Context) \
+ F(cl_program_info, CL_PROGRAM_NUM_DEVICES, cl_uint) \
+ F(cl_program_info, CL_PROGRAM_DEVICES, VECTOR_CLASS<Device>) \
+ F(cl_program_info, CL_PROGRAM_SOURCE, STRING_CLASS) \
+ F(cl_program_info, CL_PROGRAM_BINARY_SIZES, VECTOR_CLASS< ::size_t>) \
+ F(cl_program_info, CL_PROGRAM_BINARIES, VECTOR_CLASS<char *>) \
+ \
+ F(cl_program_build_info, CL_PROGRAM_BUILD_STATUS, cl_build_status) \
+ F(cl_program_build_info, CL_PROGRAM_BUILD_OPTIONS, STRING_CLASS) \
+ F(cl_program_build_info, CL_PROGRAM_BUILD_LOG, STRING_CLASS) \
+ \
+ F(cl_kernel_info, CL_KERNEL_FUNCTION_NAME, STRING_CLASS) \
+ F(cl_kernel_info, CL_KERNEL_NUM_ARGS, cl_uint) \
+ F(cl_kernel_info, CL_KERNEL_REFERENCE_COUNT, cl_uint) \
+ F(cl_kernel_info, CL_KERNEL_CONTEXT, cl::Context) \
+ F(cl_kernel_info, CL_KERNEL_PROGRAM, cl::Program) \
+ \
+ F(cl_kernel_work_group_info, CL_KERNEL_WORK_GROUP_SIZE, ::size_t) \
+ F(cl_kernel_work_group_info, CL_KERNEL_COMPILE_WORK_GROUP_SIZE, cl::size_t<3>) \
+ F(cl_kernel_work_group_info, CL_KERNEL_LOCAL_MEM_SIZE, cl_ulong) \
+ \
+ F(cl_command_queue_info, CL_QUEUE_CONTEXT, cl::Context) \
+ F(cl_command_queue_info, CL_QUEUE_DEVICE, cl::Device) \
+ F(cl_command_queue_info, CL_QUEUE_REFERENCE_COUNT, cl_uint) \
+ F(cl_command_queue_info, CL_QUEUE_PROPERTIES, cl_command_queue_properties)
+
+#if defined(CL_VERSION_1_1)
+#define __PARAM_NAME_INFO_1_1(F) \
+ F(cl_context_info, CL_CONTEXT_NUM_DEVICES, cl_uint)\
+ F(cl_device_info, CL_DEVICE_PREFERRED_VECTOR_WIDTH_HALF, cl_uint) \
+ F(cl_device_info, CL_DEVICE_NATIVE_VECTOR_WIDTH_CHAR, cl_uint) \
+ F(cl_device_info, CL_DEVICE_NATIVE_VECTOR_WIDTH_SHORT, cl_uint) \
+ F(cl_device_info, CL_DEVICE_NATIVE_VECTOR_WIDTH_INT, cl_uint) \
+ F(cl_device_info, CL_DEVICE_NATIVE_VECTOR_WIDTH_LONG, cl_uint) \
+ F(cl_device_info, CL_DEVICE_NATIVE_VECTOR_WIDTH_FLOAT, cl_uint) \
+ F(cl_device_info, CL_DEVICE_NATIVE_VECTOR_WIDTH_DOUBLE, cl_uint) \
+ F(cl_device_info, CL_DEVICE_NATIVE_VECTOR_WIDTH_HALF, cl_uint) \
+ F(cl_device_info, CL_DEVICE_DOUBLE_FP_CONFIG, cl_device_fp_config) \
+ F(cl_device_info, CL_DEVICE_HALF_FP_CONFIG, cl_device_fp_config) \
+ F(cl_device_info, CL_DEVICE_HOST_UNIFIED_MEMORY, cl_bool) \
+ F(cl_device_info, CL_DEVICE_OPENCL_C_VERSION, STRING_CLASS) \
+ \
+ F(cl_mem_info, CL_MEM_ASSOCIATED_MEMOBJECT, cl::Memory) \
+ F(cl_mem_info, CL_MEM_OFFSET, ::size_t) \
+ \
+ F(cl_kernel_work_group_info, CL_KERNEL_PREFERRED_WORK_GROUP_SIZE_MULTIPLE, ::size_t) \
+ F(cl_kernel_work_group_info, CL_KERNEL_PRIVATE_MEM_SIZE, cl_ulong) \
+ \
+ F(cl_event_info, CL_EVENT_CONTEXT, cl::Context)
+#endif // CL_VERSION_1_1
+
+
+#if defined(CL_VERSION_1_2)
+#define __PARAM_NAME_INFO_1_2(F) \
+ F(cl_image_info, CL_IMAGE_BUFFER, cl::Buffer) \
+ \
+ F(cl_program_info, CL_PROGRAM_NUM_KERNELS, ::size_t) \
+ F(cl_program_info, CL_PROGRAM_KERNEL_NAMES, STRING_CLASS) \
+ \
+ F(cl_program_build_info, CL_PROGRAM_BINARY_TYPE, cl_program_binary_type) \
+ \
+ F(cl_kernel_info, CL_KERNEL_ATTRIBUTES, STRING_CLASS) \
+ \
+ F(cl_kernel_arg_info, CL_KERNEL_ARG_ADDRESS_QUALIFIER, cl_kernel_arg_address_qualifier) \
+ F(cl_kernel_arg_info, CL_KERNEL_ARG_ACCESS_QUALIFIER, cl_kernel_arg_access_qualifier) \
+ F(cl_kernel_arg_info, CL_KERNEL_ARG_TYPE_NAME, STRING_CLASS) \
+ F(cl_kernel_arg_info, CL_KERNEL_ARG_NAME, STRING_CLASS) \
+ \
+ F(cl_device_info, CL_DEVICE_PARENT_DEVICE, cl_device_id) \
+ F(cl_device_info, CL_DEVICE_PARTITION_PROPERTIES, VECTOR_CLASS<cl_device_partition_property>) \
+ F(cl_device_info, CL_DEVICE_PARTITION_TYPE, VECTOR_CLASS<cl_device_partition_property>) \
+ F(cl_device_info, CL_DEVICE_REFERENCE_COUNT, cl_uint) \
+ F(cl_device_info, CL_DEVICE_PREFERRED_INTEROP_USER_SYNC, ::size_t) \
+ F(cl_device_info, CL_DEVICE_PARTITION_AFFINITY_DOMAIN, cl_device_affinity_domain) \
+ F(cl_device_info, CL_DEVICE_BUILT_IN_KERNELS, STRING_CLASS)
+#endif // #if defined(CL_VERSION_1_2)
+
+#if defined(USE_CL_DEVICE_FISSION)
+#define __PARAM_NAME_DEVICE_FISSION(F) \
+ F(cl_device_info, CL_DEVICE_PARENT_DEVICE_EXT, cl_device_id) \
+ F(cl_device_info, CL_DEVICE_PARTITION_TYPES_EXT, VECTOR_CLASS<cl_device_partition_property_ext>) \
+ F(cl_device_info, CL_DEVICE_AFFINITY_DOMAINS_EXT, VECTOR_CLASS<cl_device_partition_property_ext>) \
+ F(cl_device_info, CL_DEVICE_REFERENCE_COUNT_EXT , cl_uint) \
+ F(cl_device_info, CL_DEVICE_PARTITION_STYLE_EXT, VECTOR_CLASS<cl_device_partition_property_ext>)
+#endif // USE_CL_DEVICE_FISSION
+
+template <typename enum_type, cl_int Name>
+struct param_traits {};
+
+#define __CL_DECLARE_PARAM_TRAITS(token, param_name, T) \
+struct token; \
+template<> \
+struct param_traits<detail:: token,param_name> \
+{ \
+ enum { value = param_name }; \
+ typedef T param_type; \
+};
+
+__PARAM_NAME_INFO_1_0(__CL_DECLARE_PARAM_TRAITS)
+#if defined(CL_VERSION_1_1)
+__PARAM_NAME_INFO_1_1(__CL_DECLARE_PARAM_TRAITS)
+#endif // CL_VERSION_1_1
+#if defined(CL_VERSION_1_2)
+__PARAM_NAME_INFO_1_2(__CL_DECLARE_PARAM_TRAITS)
+#endif // CL_VERSION_1_1
+
+#if defined(USE_CL_DEVICE_FISSION)
+__PARAM_NAME_DEVICE_FISSION(__CL_DECLARE_PARAM_TRAITS);
+#endif // USE_CL_DEVICE_FISSION
+
+#ifdef CL_PLATFORM_ICD_SUFFIX_KHR
+__CL_DECLARE_PARAM_TRAITS(cl_platform_info, CL_PLATFORM_ICD_SUFFIX_KHR, STRING_CLASS)
+#endif
+
+#ifdef CL_DEVICE_PROFILING_TIMER_OFFSET_AMD
+__CL_DECLARE_PARAM_TRAITS(cl_device_info, CL_DEVICE_PROFILING_TIMER_OFFSET_AMD, cl_ulong)
+#endif
+
+#ifdef CL_DEVICE_GLOBAL_FREE_MEMORY_AMD
+__CL_DECLARE_PARAM_TRAITS(cl_device_info, CL_DEVICE_GLOBAL_FREE_MEMORY_AMD, VECTOR_CLASS< ::size_t>)
+#endif
+#ifdef CL_DEVICE_SIMD_PER_COMPUTE_UNIT_AMD
+__CL_DECLARE_PARAM_TRAITS(cl_device_info, CL_DEVICE_SIMD_PER_COMPUTE_UNIT_AMD, cl_uint)
+#endif
+#ifdef CL_DEVICE_SIMD_WIDTH_AMD
+__CL_DECLARE_PARAM_TRAITS(cl_device_info, CL_DEVICE_SIMD_WIDTH_AMD, cl_uint)
+#endif
+#ifdef CL_DEVICE_SIMD_INSTRUCTION_WIDTH_AMD
+__CL_DECLARE_PARAM_TRAITS(cl_device_info, CL_DEVICE_SIMD_INSTRUCTION_WIDTH_AMD, cl_uint)
+#endif
+#ifdef CL_DEVICE_WAVEFRONT_WIDTH_AMD
+__CL_DECLARE_PARAM_TRAITS(cl_device_info, CL_DEVICE_WAVEFRONT_WIDTH_AMD, cl_uint)
+#endif
+#ifdef CL_DEVICE_GLOBAL_MEM_CHANNELS_AMD
+__CL_DECLARE_PARAM_TRAITS(cl_device_info, CL_DEVICE_GLOBAL_MEM_CHANNELS_AMD, cl_uint)
+#endif
+#ifdef CL_DEVICE_GLOBAL_MEM_CHANNEL_BANKS_AMD
+__CL_DECLARE_PARAM_TRAITS(cl_device_info, CL_DEVICE_GLOBAL_MEM_CHANNEL_BANKS_AMD, cl_uint)
+#endif
+#ifdef CL_DEVICE_GLOBAL_MEM_CHANNEL_BANK_WIDTH_AMD
+__CL_DECLARE_PARAM_TRAITS(cl_device_info, CL_DEVICE_GLOBAL_MEM_CHANNEL_BANK_WIDTH_AMD, cl_uint)
+#endif
+#ifdef CL_DEVICE_LOCAL_MEM_SIZE_PER_COMPUTE_UNIT_AMD
+__CL_DECLARE_PARAM_TRAITS(cl_device_info, CL_DEVICE_LOCAL_MEM_SIZE_PER_COMPUTE_UNIT_AMD, cl_uint)
+#endif
+#ifdef CL_DEVICE_LOCAL_MEM_BANKS_AMD
+__CL_DECLARE_PARAM_TRAITS(cl_device_info, CL_DEVICE_LOCAL_MEM_BANKS_AMD, cl_uint)
+#endif
+
+#ifdef CL_DEVICE_COMPUTE_CAPABILITY_MAJOR_NV
+__CL_DECLARE_PARAM_TRAITS(cl_device_info, CL_DEVICE_COMPUTE_CAPABILITY_MAJOR_NV, cl_uint)
+#endif
+#ifdef CL_DEVICE_COMPUTE_CAPABILITY_MINOR_NV
+__CL_DECLARE_PARAM_TRAITS(cl_device_info, CL_DEVICE_COMPUTE_CAPABILITY_MINOR_NV, cl_uint)
+#endif
+#ifdef CL_DEVICE_REGISTERS_PER_BLOCK_NV
+__CL_DECLARE_PARAM_TRAITS(cl_device_info, CL_DEVICE_REGISTERS_PER_BLOCK_NV, cl_uint)
+#endif
+#ifdef CL_DEVICE_WARP_SIZE_NV
+__CL_DECLARE_PARAM_TRAITS(cl_device_info, CL_DEVICE_WARP_SIZE_NV, cl_uint)
+#endif
+#ifdef CL_DEVICE_GPU_OVERLAP_NV
+__CL_DECLARE_PARAM_TRAITS(cl_device_info, CL_DEVICE_GPU_OVERLAP_NV, cl_bool)
+#endif
+#ifdef CL_DEVICE_KERNEL_EXEC_TIMEOUT_NV
+__CL_DECLARE_PARAM_TRAITS(cl_device_info, CL_DEVICE_KERNEL_EXEC_TIMEOUT_NV, cl_bool)
+#endif
+#ifdef CL_DEVICE_INTEGRATED_MEMORY_NV
+__CL_DECLARE_PARAM_TRAITS(cl_device_info, CL_DEVICE_INTEGRATED_MEMORY_NV, cl_bool)
+#endif
+
+// Convenience functions
+
+template <typename Func, typename T>
+inline cl_int
+getInfo(Func f, cl_uint name, T* param)
+{
+ return getInfoHelper(f, name, param, 0);
+}
+
+template <typename Func, typename Arg0>
+struct GetInfoFunctor0
+{
+ Func f_; const Arg0& arg0_;
+ cl_int operator ()(
+ cl_uint param, ::size_t size, void* value, ::size_t* size_ret)
+ { return f_(arg0_, param, size, value, size_ret); }
+};
+
+template <typename Func, typename Arg0, typename Arg1>
+struct GetInfoFunctor1
+{
+ Func f_; const Arg0& arg0_; const Arg1& arg1_;
+ cl_int operator ()(
+ cl_uint param, ::size_t size, void* value, ::size_t* size_ret)
+ { return f_(arg0_, arg1_, param, size, value, size_ret); }
+};
+
+template <typename Func, typename Arg0, typename T>
+inline cl_int
+getInfo(Func f, const Arg0& arg0, cl_uint name, T* param)
+{
+ GetInfoFunctor0<Func, Arg0> f0 = { f, arg0 };
+ return getInfoHelper(f0, name, param, 0);
+}
+
+template <typename Func, typename Arg0, typename Arg1, typename T>
+inline cl_int
+getInfo(Func f, const Arg0& arg0, const Arg1& arg1, cl_uint name, T* param)
+{
+ GetInfoFunctor1<Func, Arg0, Arg1> f0 = { f, arg0, arg1 };
+ return getInfoHelper(f0, name, param, 0);
+}
+
+template<typename T>
+struct ReferenceHandler
+{ };
+
+#if defined(CL_VERSION_1_2)
+/**
+ * OpenCL 1.2 devices do have retain/release.
+ */
+template <>
+struct ReferenceHandler<cl_device_id>
+{
+ /**
+ * Retain the device.
+ * \param device A valid device created using createSubDevices
+ * \return
+ * CL_SUCCESS if the function executed successfully.
+ * CL_INVALID_DEVICE if device was not a valid subdevice
+ * CL_OUT_OF_RESOURCES
+ * CL_OUT_OF_HOST_MEMORY
+ */
+ static cl_int retain(cl_device_id device)
+ { return ::clRetainDevice(device); }
+ /**
+ * Retain the device.
+ * \param device A valid device created using createSubDevices
+ * \return
+ * CL_SUCCESS if the function executed successfully.
+ * CL_INVALID_DEVICE if device was not a valid subdevice
+ * CL_OUT_OF_RESOURCES
+ * CL_OUT_OF_HOST_MEMORY
+ */
+ static cl_int release(cl_device_id device)
+ { return ::clReleaseDevice(device); }
+};
+#else // #if defined(CL_VERSION_1_2)
+/**
+ * OpenCL 1.1 devices do not have retain/release.
+ */
+template <>
+struct ReferenceHandler<cl_device_id>
+{
+ // cl_device_id does not have retain().
+ static cl_int retain(cl_device_id)
+ { return CL_SUCCESS; }
+ // cl_device_id does not have release().
+ static cl_int release(cl_device_id)
+ { return CL_SUCCESS; }
+};
+#endif // #if defined(CL_VERSION_1_2)
+
+template <>
+struct ReferenceHandler<cl_platform_id>
+{
+ // cl_platform_id does not have retain().
+ static cl_int retain(cl_platform_id)
+ { return CL_SUCCESS; }
+ // cl_platform_id does not have release().
+ static cl_int release(cl_platform_id)
+ { return CL_SUCCESS; }
+};
+
+template <>
+struct ReferenceHandler<cl_context>
+{
+ static cl_int retain(cl_context context)
+ { return ::clRetainContext(context); }
+ static cl_int release(cl_context context)
+ { return ::clReleaseContext(context); }
+};
+
+template <>
+struct ReferenceHandler<cl_command_queue>
+{
+ static cl_int retain(cl_command_queue queue)
+ { return ::clRetainCommandQueue(queue); }
+ static cl_int release(cl_command_queue queue)
+ { return ::clReleaseCommandQueue(queue); }
+};
+
+template <>
+struct ReferenceHandler<cl_mem>
+{
+ static cl_int retain(cl_mem memory)
+ { return ::clRetainMemObject(memory); }
+ static cl_int release(cl_mem memory)
+ { return ::clReleaseMemObject(memory); }
+};
+
+template <>
+struct ReferenceHandler<cl_sampler>
+{
+ static cl_int retain(cl_sampler sampler)
+ { return ::clRetainSampler(sampler); }
+ static cl_int release(cl_sampler sampler)
+ { return ::clReleaseSampler(sampler); }
+};
+
+template <>
+struct ReferenceHandler<cl_program>
+{
+ static cl_int retain(cl_program program)
+ { return ::clRetainProgram(program); }
+ static cl_int release(cl_program program)
+ { return ::clReleaseProgram(program); }
+};
+
+template <>
+struct ReferenceHandler<cl_kernel>
+{
+ static cl_int retain(cl_kernel kernel)
+ { return ::clRetainKernel(kernel); }
+ static cl_int release(cl_kernel kernel)
+ { return ::clReleaseKernel(kernel); }
+};
+
+template <>
+struct ReferenceHandler<cl_event>
+{
+ static cl_int retain(cl_event event)
+ { return ::clRetainEvent(event); }
+ static cl_int release(cl_event event)
+ { return ::clReleaseEvent(event); }
+};
+
+
+// Extracts version number with major in the upper 16 bits, minor in the lower 16
+static cl_uint getVersion(const char *versionInfo)
+{
+ int highVersion = 0;
+ int lowVersion = 0;
+ int index = 7;
+ while(versionInfo[index] != '.' ) {
+ highVersion *= 10;
+ highVersion += versionInfo[index]-'0';
+ ++index;
+ }
+ ++index;
+ while(versionInfo[index] != ' ' && versionInfo[index] != '\0') {
+ lowVersion *= 10;
+ lowVersion += versionInfo[index]-'0';
+ ++index;
+ }
+ return (highVersion << 16) | lowVersion;
+}
+
+static cl_uint getPlatformVersion(cl_platform_id platform)
+{
+ ::size_t size = 0;
+ clGetPlatformInfo(platform, CL_PLATFORM_VERSION, 0, NULL, &size);
+ char *versionInfo = (char *) alloca(size);
+ clGetPlatformInfo(platform, CL_PLATFORM_VERSION, size, &versionInfo[0], &size);
+ return getVersion(versionInfo);
+}
+
+static cl_uint getDevicePlatformVersion(cl_device_id device)
+{
+ cl_platform_id platform;
+ clGetDeviceInfo(device, CL_DEVICE_PLATFORM, sizeof(platform), &platform, NULL);
+ return getPlatformVersion(platform);
+}
+
+#if defined(CL_VERSION_1_2) && defined(CL_USE_DEPRECATED_OPENCL_1_1_APIS)
+static cl_uint getContextPlatformVersion(cl_context context)
+{
+ // The platform cannot be queried directly, so we first have to grab a
+ // device and obtain its context
+ ::size_t size = 0;
+ clGetContextInfo(context, CL_CONTEXT_DEVICES, 0, NULL, &size);
+ if (size == 0)
+ return 0;
+ cl_device_id *devices = (cl_device_id *) alloca(size);
+ clGetContextInfo(context, CL_CONTEXT_DEVICES, size, devices, NULL);
+ return getDevicePlatformVersion(devices[0]);
+}
+#endif // #if defined(CL_VERSION_1_2) && defined(CL_USE_DEPRECATED_OPENCL_1_1_APIS)
+
+template <typename T>
+class Wrapper
+{
+public:
+ typedef T cl_type;
+
+protected:
+ cl_type object_;
+
+public:
+ Wrapper() : object_(NULL) { }
+
+ Wrapper(const cl_type &obj) : object_(obj) { }
+
+ ~Wrapper()
+ {
+ if (object_ != NULL) { release(); }
+ }
+
+ Wrapper(const Wrapper<cl_type>& rhs)
+ {
+ object_ = rhs.object_;
+ if (object_ != NULL) { detail::errHandler(retain(), __RETAIN_ERR); }
+ }
+
+#if defined(CL_HPP_RVALUE_REFERENCES_SUPPORTED)
+ Wrapper(Wrapper<cl_type>&& rhs) CL_HPP_NOEXCEPT
+ {
+ object_ = rhs.object_;
+ rhs.object_ = NULL;
+ }
+#endif
+
+ Wrapper<cl_type>& operator = (const Wrapper<cl_type>& rhs)
+ {
+ if (this != &rhs) {
+ if (object_ != NULL) { detail::errHandler(release(), __RELEASE_ERR); }
+ object_ = rhs.object_;
+ if (object_ != NULL) { detail::errHandler(retain(), __RETAIN_ERR); }
+ }
+ return *this;
+ }
+
+#if defined(CL_HPP_RVALUE_REFERENCES_SUPPORTED)
+ Wrapper<cl_type>& operator = (Wrapper<cl_type>&& rhs)
+ {
+ if (this != &rhs) {
+ if (object_ != NULL) { detail::errHandler(release(), __RELEASE_ERR); }
+ object_ = rhs.object_;
+ rhs.object_ = NULL;
+ }
+ return *this;
+ }
+#endif
+
+ Wrapper<cl_type>& operator = (const cl_type &rhs)
+ {
+ if (object_ != NULL) { detail::errHandler(release(), __RELEASE_ERR); }
+ object_ = rhs;
+ return *this;
+ }
+
+ cl_type operator ()() const { return object_; }
+
+ cl_type& operator ()() { return object_; }
+
+protected:
+ template<typename Func, typename U>
+ friend inline cl_int getInfoHelper(Func, cl_uint, U*, int, typename U::cl_type);
+
+ cl_int retain() const
+ {
+ return ReferenceHandler<cl_type>::retain(object_);
+ }
+
+ cl_int release() const
+ {
+ return ReferenceHandler<cl_type>::release(object_);
+ }
+};
+
+template <>
+class Wrapper<cl_device_id>
+{
+public:
+ typedef cl_device_id cl_type;
+
+protected:
+ cl_type object_;
+ bool referenceCountable_;
+
+ static bool isReferenceCountable(cl_device_id device)
+ {
+ bool retVal = false;
+ if (device != NULL) {
+ int version = getDevicePlatformVersion(device);
+ if(version > ((1 << 16) + 1)) {
+ retVal = true;
+ }
+ }
+ return retVal;
+ }
+
+public:
+ Wrapper() : object_(NULL), referenceCountable_(false)
+ {
+ }
+
+ Wrapper(const cl_type &obj) : object_(obj), referenceCountable_(false)
+ {
+ referenceCountable_ = isReferenceCountable(obj);
+ }
+
+ ~Wrapper()
+ {
+ if (object_ != NULL) { release(); }
+ }
+
+ Wrapper(const Wrapper<cl_type>& rhs)
+ {
+ object_ = rhs.object_;
+ referenceCountable_ = isReferenceCountable(object_);
+ if (object_ != NULL) { detail::errHandler(retain(), __RETAIN_ERR); }
+ }
+
+#if defined(CL_HPP_RVALUE_REFERENCES_SUPPORTED)
+ Wrapper(Wrapper<cl_type>&& rhs) CL_HPP_NOEXCEPT
+ {
+ object_ = rhs.object_;
+ referenceCountable_ = rhs.referenceCountable_;
+ rhs.object_ = NULL;
+ rhs.referenceCountable_ = false;
+ }
+#endif
+
+ Wrapper<cl_type>& operator = (const Wrapper<cl_type>& rhs)
+ {
+ if (this != &rhs) {
+ if (object_ != NULL) { detail::errHandler(release(), __RELEASE_ERR); }
+ object_ = rhs.object_;
+ referenceCountable_ = rhs.referenceCountable_;
+ if (object_ != NULL) { detail::errHandler(retain(), __RETAIN_ERR); }
+ }
+ return *this;
+ }
+
+#if defined(CL_HPP_RVALUE_REFERENCES_SUPPORTED)
+ Wrapper<cl_type>& operator = (Wrapper<cl_type>&& rhs)
+ {
+ if (this != &rhs) {
+ if (object_ != NULL) { detail::errHandler(release(), __RELEASE_ERR); }
+ object_ = rhs.object_;
+ referenceCountable_ = rhs.referenceCountable_;
+ rhs.object_ = NULL;
+ rhs.referenceCountable_ = false;
+ }
+ return *this;
+ }
+#endif
+
+ Wrapper<cl_type>& operator = (const cl_type &rhs)
+ {
+ if (object_ != NULL) { detail::errHandler(release(), __RELEASE_ERR); }
+ object_ = rhs;
+ referenceCountable_ = isReferenceCountable(object_);
+ return *this;
+ }
+
+ cl_type operator ()() const { return object_; }
+
+ cl_type& operator ()() { return object_; }
+
+protected:
+ template<typename Func, typename U>
+ friend inline cl_int getInfoHelper(Func, cl_uint, U*, int, typename U::cl_type);
+
+ template<typename Func, typename U>
+ friend inline cl_int getInfoHelper(Func, cl_uint, VECTOR_CLASS<U>*, int, typename U::cl_type);
+
+ cl_int retain() const
+ {
+ if( referenceCountable_ ) {
+ return ReferenceHandler<cl_type>::retain(object_);
+ }
+ else {
+ return CL_SUCCESS;
+ }
+ }
+
+ cl_int release() const
+ {
+ if( referenceCountable_ ) {
+ return ReferenceHandler<cl_type>::release(object_);
+ }
+ else {
+ return CL_SUCCESS;
+ }
+ }
+};
+
+} // namespace detail
+//! \endcond
+
+/*! \stuct ImageFormat
+ * \brief Adds constructors and member functions for cl_image_format.
+ *
+ * \see cl_image_format
+ */
+struct ImageFormat : public cl_image_format
+{
+ //! \brief Default constructor - performs no initialization.
+ ImageFormat(){}
+
+ //! \brief Initializing constructor.
+ ImageFormat(cl_channel_order order, cl_channel_type type)
+ {
+ image_channel_order = order;
+ image_channel_data_type = type;
+ }
+
+ //! \brief Assignment operator.
+ ImageFormat& operator = (const ImageFormat& rhs)
+ {
+ if (this != &rhs) {
+ this->image_channel_data_type = rhs.image_channel_data_type;
+ this->image_channel_order = rhs.image_channel_order;
+ }
+ return *this;
+ }
+};
+
+/*! \brief Class interface for cl_device_id.
+ *
+ * \note Copies of these objects are inexpensive, since they don't 'own'
+ * any underlying resources or data structures.
+ *
+ * \see cl_device_id
+ */
+class Device : public detail::Wrapper<cl_device_id>
+{
+public:
+ //! \brief Default constructor - initializes to NULL.
+ Device() : detail::Wrapper<cl_type>() { }
+
+ /*! \brief Constructor from cl_device_id.
+ *
+ * This simply copies the device ID value, which is an inexpensive operation.
+ */
+ __CL_EXPLICIT_CONSTRUCTORS Device(const cl_device_id &device) : detail::Wrapper<cl_type>(device) { }
+
+ /*! \brief Returns the first device on the default context.
+ *
+ * \see Context::getDefault()
+ */
+ static Device getDefault(cl_int * err = NULL);
+
+ /*! \brief Assignment operator from cl_device_id.
+ *
+ * This simply copies the device ID value, which is an inexpensive operation.
+ */
+ Device& operator = (const cl_device_id& rhs)
+ {
+ detail::Wrapper<cl_type>::operator=(rhs);
+ return *this;
+ }
+
+ /*! \brief Copy constructor to forward copy to the superclass correctly.
+ * Required for MSVC.
+ */
+ Device(const Device& dev) : detail::Wrapper<cl_type>(dev) {}
+
+ /*! \brief Copy assignment to forward copy to the superclass correctly.
+ * Required for MSVC.
+ */
+ Device& operator = (const Device &dev)
+ {
+ detail::Wrapper<cl_type>::operator=(dev);
+ return *this;
+ }
+
+#if defined(CL_HPP_RVALUE_REFERENCES_SUPPORTED)
+ /*! \brief Move constructor to forward move to the superclass correctly.
+ * Required for MSVC.
+ */
+ Device(Device&& dev) CL_HPP_NOEXCEPT : detail::Wrapper<cl_type>(std::move(dev)) {}
+
+ /*! \brief Move assignment to forward move to the superclass correctly.
+ * Required for MSVC.
+ */
+ Device& operator = (Device &&dev)
+ {
+ detail::Wrapper<cl_type>::operator=(std::move(dev));
+ return *this;
+ }
+#endif // #if defined(CL_HPP_RVALUE_REFERENCES_SUPPORTED)
+
+ //! \brief Wrapper for clGetDeviceInfo().
+ template <typename T>
+ cl_int getInfo(cl_device_info name, T* param) const
+ {
+ return detail::errHandler(
+ detail::getInfo(&::clGetDeviceInfo, object_, name, param),
+ __GET_DEVICE_INFO_ERR);
+ }
+
+ //! \brief Wrapper for clGetDeviceInfo() that returns by value.
+ template <cl_int name> typename
+ detail::param_traits<detail::cl_device_info, name>::param_type
+ getInfo(cl_int* err = NULL) const
+ {
+ typename detail::param_traits<
+ detail::cl_device_info, name>::param_type param;
+ cl_int result = getInfo(name, &param);
+ if (err != NULL) {
+ *err = result;
+ }
+ return param;
+ }
+
+ /**
+ * CL 1.2 version
+ */
+#if defined(CL_VERSION_1_2)
+ //! \brief Wrapper for clCreateSubDevicesEXT().
+ cl_int createSubDevices(
+ const cl_device_partition_property * properties,
+ VECTOR_CLASS<Device>* devices)
+ {
+ cl_uint n = 0;
+ cl_int err = clCreateSubDevices(object_, properties, 0, NULL, &n);
+ if (err != CL_SUCCESS) {
+ return detail::errHandler(err, __CREATE_SUB_DEVICES);
+ }
+
+ cl_device_id* ids = (cl_device_id*) alloca(n * sizeof(cl_device_id));
+ err = clCreateSubDevices(object_, properties, n, ids, NULL);
+ if (err != CL_SUCCESS) {
+ return detail::errHandler(err, __CREATE_SUB_DEVICES);
+ }
+
+ devices->assign(&ids[0], &ids[n]);
+ return CL_SUCCESS;
+ }
+#endif // #if defined(CL_VERSION_1_2)
+
+/**
+ * CL 1.1 version that uses device fission.
+ */
+#if defined(CL_VERSION_1_1)
+#if defined(USE_CL_DEVICE_FISSION)
+ cl_int createSubDevices(
+ const cl_device_partition_property_ext * properties,
+ VECTOR_CLASS<Device>* devices)
+ {
+ typedef CL_API_ENTRY cl_int
+ ( CL_API_CALL * PFN_clCreateSubDevicesEXT)(
+ cl_device_id /*in_device*/,
+ const cl_device_partition_property_ext * /* properties */,
+ cl_uint /*num_entries*/,
+ cl_device_id * /*out_devices*/,
+ cl_uint * /*num_devices*/ ) CL_EXT_SUFFIX__VERSION_1_1;
+
+ static PFN_clCreateSubDevicesEXT pfn_clCreateSubDevicesEXT = NULL;
+ __INIT_CL_EXT_FCN_PTR(clCreateSubDevicesEXT);
+
+ cl_uint n = 0;
+ cl_int err = pfn_clCreateSubDevicesEXT(object_, properties, 0, NULL, &n);
+ if (err != CL_SUCCESS) {
+ return detail::errHandler(err, __CREATE_SUB_DEVICES);
+ }
+
+ cl_device_id* ids = (cl_device_id*) alloca(n * sizeof(cl_device_id));
+ err = pfn_clCreateSubDevicesEXT(object_, properties, n, ids, NULL);
+ if (err != CL_SUCCESS) {
+ return detail::errHandler(err, __CREATE_SUB_DEVICES);
+ }
+
+ devices->assign(&ids[0], &ids[n]);
+ return CL_SUCCESS;
+ }
+#endif // #if defined(USE_CL_DEVICE_FISSION)
+#endif // #if defined(CL_VERSION_1_1)
+};
+
+/*! \brief Class interface for cl_platform_id.
+ *
+ * \note Copies of these objects are inexpensive, since they don't 'own'
+ * any underlying resources or data structures.
+ *
+ * \see cl_platform_id
+ */
+class Platform : public detail::Wrapper<cl_platform_id>
+{
+public:
+ //! \brief Default constructor - initializes to NULL.
+ Platform() : detail::Wrapper<cl_type>() { }
+
+ /*! \brief Constructor from cl_platform_id.
+ *
+ * This simply copies the platform ID value, which is an inexpensive operation.
+ */
+ __CL_EXPLICIT_CONSTRUCTORS Platform(const cl_platform_id &platform) : detail::Wrapper<cl_type>(platform) { }
+
+ /*! \brief Assignment operator from cl_platform_id.
+ *
+ * This simply copies the platform ID value, which is an inexpensive operation.
+ */
+ Platform& operator = (const cl_platform_id& rhs)
+ {
+ detail::Wrapper<cl_type>::operator=(rhs);
+ return *this;
+ }
+
+ //! \brief Wrapper for clGetPlatformInfo().
+ cl_int getInfo(cl_platform_info name, STRING_CLASS* param) const
+ {
+ return detail::errHandler(
+ detail::getInfo(&::clGetPlatformInfo, object_, name, param),
+ __GET_PLATFORM_INFO_ERR);
+ }
+
+ //! \brief Wrapper for clGetPlatformInfo() that returns by value.
+ template <cl_int name> typename
+ detail::param_traits<detail::cl_platform_info, name>::param_type
+ getInfo(cl_int* err = NULL) const
+ {
+ typename detail::param_traits<
+ detail::cl_platform_info, name>::param_type param;
+ cl_int result = getInfo(name, &param);
+ if (err != NULL) {
+ *err = result;
+ }
+ return param;
+ }
+
+ /*! \brief Gets a list of devices for this platform.
+ *
+ * Wraps clGetDeviceIDs().
+ */
+ cl_int getDevices(
+ cl_device_type type,
+ VECTOR_CLASS<Device>* devices) const
+ {
+ cl_uint n = 0;
+ if( devices == NULL ) {
+ return detail::errHandler(CL_INVALID_ARG_VALUE, __GET_DEVICE_IDS_ERR);
+ }
+ cl_int err = ::clGetDeviceIDs(object_, type, 0, NULL, &n);
+ if (err != CL_SUCCESS) {
+ return detail::errHandler(err, __GET_DEVICE_IDS_ERR);
+ }
+
+ cl_device_id* ids = (cl_device_id*) alloca(n * sizeof(cl_device_id));
+ err = ::clGetDeviceIDs(object_, type, n, ids, NULL);
+ if (err != CL_SUCCESS) {
+ return detail::errHandler(err, __GET_DEVICE_IDS_ERR);
+ }
+
+ devices->assign(&ids[0], &ids[n]);
+ return CL_SUCCESS;
+ }
+
+#if defined(USE_DX_INTEROP)
+ /*! \brief Get the list of available D3D10 devices.
+ *
+ * \param d3d_device_source.
+ *
+ * \param d3d_object.
+ *
+ * \param d3d_device_set.
+ *
+ * \param devices returns a vector of OpenCL D3D10 devices found. The cl::Device
+ * values returned in devices can be used to identify a specific OpenCL
+ * device. If \a devices argument is NULL, this argument is ignored.
+ *
+ * \return One of the following values:
+ * - CL_SUCCESS if the function is executed successfully.
+ *
+ * The application can query specific capabilities of the OpenCL device(s)
+ * returned by cl::getDevices. This can be used by the application to
+ * determine which device(s) to use.
+ *
+ * \note In the case that exceptions are enabled and a return value
+ * other than CL_SUCCESS is generated, then cl::Error exception is
+ * generated.
+ */
+ cl_int getDevices(
+ cl_d3d10_device_source_khr d3d_device_source,
+ void * d3d_object,
+ cl_d3d10_device_set_khr d3d_device_set,
+ VECTOR_CLASS<Device>* devices) const
+ {
+ typedef CL_API_ENTRY cl_int (CL_API_CALL *PFN_clGetDeviceIDsFromD3D10KHR)(
+ cl_platform_id platform,
+ cl_d3d10_device_source_khr d3d_device_source,
+ void * d3d_object,
+ cl_d3d10_device_set_khr d3d_device_set,
+ cl_uint num_entries,
+ cl_device_id * devices,
+ cl_uint* num_devices);
+
+ if( devices == NULL ) {
+ return detail::errHandler(CL_INVALID_ARG_VALUE, __GET_DEVICE_IDS_ERR);
+ }
+
+ static PFN_clGetDeviceIDsFromD3D10KHR pfn_clGetDeviceIDsFromD3D10KHR = NULL;
+ __INIT_CL_EXT_FCN_PTR_PLATFORM(object_, clGetDeviceIDsFromD3D10KHR);
+
+ cl_uint n = 0;
+ cl_int err = pfn_clGetDeviceIDsFromD3D10KHR(
+ object_,
+ d3d_device_source,
+ d3d_object,
+ d3d_device_set,
+ 0,
+ NULL,
+ &n);
+ if (err != CL_SUCCESS) {
+ return detail::errHandler(err, __GET_DEVICE_IDS_ERR);
+ }
+
+ cl_device_id* ids = (cl_device_id*) alloca(n * sizeof(cl_device_id));
+ err = pfn_clGetDeviceIDsFromD3D10KHR(
+ object_,
+ d3d_device_source,
+ d3d_object,
+ d3d_device_set,
+ n,
+ ids,
+ NULL);
+ if (err != CL_SUCCESS) {
+ return detail::errHandler(err, __GET_DEVICE_IDS_ERR);
+ }
+
+ devices->assign(&ids[0], &ids[n]);
+ return CL_SUCCESS;
+ }
+#endif
+
+ /*! \brief Gets a list of available platforms.
+ *
+ * Wraps clGetPlatformIDs().
+ */
+ static cl_int get(
+ VECTOR_CLASS<Platform>* platforms)
+ {
+ cl_uint n = 0;
+
+ if( platforms == NULL ) {
+ return detail::errHandler(CL_INVALID_ARG_VALUE, __GET_PLATFORM_IDS_ERR);
+ }
+
+ cl_int err = ::clGetPlatformIDs(0, NULL, &n);
+ if (err != CL_SUCCESS) {
+ return detail::errHandler(err, __GET_PLATFORM_IDS_ERR);
+ }
+
+ cl_platform_id* ids = (cl_platform_id*) alloca(
+ n * sizeof(cl_platform_id));
+ err = ::clGetPlatformIDs(n, ids, NULL);
+ if (err != CL_SUCCESS) {
+ return detail::errHandler(err, __GET_PLATFORM_IDS_ERR);
+ }
+
+ platforms->assign(&ids[0], &ids[n]);
+ return CL_SUCCESS;
+ }
+
+ /*! \brief Gets the first available platform.
+ *
+ * Wraps clGetPlatformIDs(), returning the first result.
+ */
+ static cl_int get(
+ Platform * platform)
+ {
+ cl_uint n = 0;
+
+ if( platform == NULL ) {
+ return detail::errHandler(CL_INVALID_ARG_VALUE, __GET_PLATFORM_IDS_ERR);
+ }
+
+ cl_int err = ::clGetPlatformIDs(0, NULL, &n);
+ if (err != CL_SUCCESS) {
+ return detail::errHandler(err, __GET_PLATFORM_IDS_ERR);
+ }
+
+ cl_platform_id* ids = (cl_platform_id*) alloca(
+ n * sizeof(cl_platform_id));
+ err = ::clGetPlatformIDs(n, ids, NULL);
+ if (err != CL_SUCCESS) {
+ return detail::errHandler(err, __GET_PLATFORM_IDS_ERR);
+ }
+
+ *platform = ids[0];
+ return CL_SUCCESS;
+ }
+
+ /*! \brief Gets the first available platform, returning it by value.
+ *
+ * Wraps clGetPlatformIDs(), returning the first result.
+ */
+ static Platform get(
+ cl_int * errResult = NULL)
+ {
+ Platform platform;
+ cl_uint n = 0;
+ cl_int err = ::clGetPlatformIDs(0, NULL, &n);
+ if (err != CL_SUCCESS) {
+ detail::errHandler(err, __GET_PLATFORM_IDS_ERR);
+ if (errResult != NULL) {
+ *errResult = err;
+ }
+ return Platform();
+ }
+
+ cl_platform_id* ids = (cl_platform_id*) alloca(
+ n * sizeof(cl_platform_id));
+ err = ::clGetPlatformIDs(n, ids, NULL);
+
+ if (err != CL_SUCCESS) {
+ detail::errHandler(err, __GET_PLATFORM_IDS_ERR);
+ if (errResult != NULL) {
+ *errResult = err;
+ }
+ return Platform();
+ }
+
+
+ return Platform(ids[0]);
+ }
+
+ static Platform getDefault(
+ cl_int *errResult = NULL )
+ {
+ return get(errResult);
+ }
+
+
+#if defined(CL_VERSION_1_2)
+ //! \brief Wrapper for clUnloadCompiler().
+ cl_int
+ unloadCompiler()
+ {
+ return ::clUnloadPlatformCompiler(object_);
+ }
+#endif // #if defined(CL_VERSION_1_2)
+}; // class Platform
+
+/**
+ * Deprecated APIs for 1.2
+ */
+#if defined(CL_USE_DEPRECATED_OPENCL_1_1_APIS) || (defined(CL_VERSION_1_1) && !defined(CL_VERSION_1_2))
+/**
+ * Unload the OpenCL compiler.
+ * \note Deprecated for OpenCL 1.2. Use Platform::unloadCompiler instead.
+ */
+inline CL_EXT_PREFIX__VERSION_1_1_DEPRECATED cl_int
+UnloadCompiler() CL_EXT_SUFFIX__VERSION_1_1_DEPRECATED;
+inline cl_int
+UnloadCompiler()
+{
+ return ::clUnloadCompiler();
+}
+#endif // #if defined(CL_VERSION_1_1)
+
+/*! \brief Class interface for cl_context.
+ *
+ * \note Copies of these objects are shallow, meaning that the copy will refer
+ * to the same underlying cl_context as the original. For details, see
+ * clRetainContext() and clReleaseContext().
+ *
+ * \see cl_context
+ */
+class Context
+ : public detail::Wrapper<cl_context>
+{
+private:
+
+#ifdef CL_HPP_CPP11_ATOMICS_SUPPORTED
+ static std::atomic<int> default_initialized_;
+#else // !CL_HPP_CPP11_ATOMICS_SUPPORTED
+ static volatile int default_initialized_;
+#endif // !CL_HPP_CPP11_ATOMICS_SUPPORTED
+ static Context default_;
+ static volatile cl_int default_error_;
+public:
+ /*! \brief Constructs a context including a list of specified devices.
+ *
+ * Wraps clCreateContext().
+ */
+ Context(
+ const VECTOR_CLASS<Device>& devices,
+ cl_context_properties* properties = NULL,
+ void (CL_CALLBACK * notifyFptr)(
+ const char *,
+ const void *,
+ ::size_t,
+ void *) = NULL,
+ void* data = NULL,
+ cl_int* err = NULL)
+ {
+ cl_int error;
+
+ ::size_t numDevices = devices.size();
+ cl_device_id* deviceIDs = (cl_device_id*) alloca(numDevices * sizeof(cl_device_id));
+ for( ::size_t deviceIndex = 0; deviceIndex < numDevices; ++deviceIndex ) {
+ deviceIDs[deviceIndex] = (devices[deviceIndex])();
+ }
+
+ object_ = ::clCreateContext(
+ properties, (cl_uint) numDevices,
+ deviceIDs,
+ notifyFptr, data, &error);
+
+ detail::errHandler(error, __CREATE_CONTEXT_ERR);
+ if (err != NULL) {
+ *err = error;
+ }
+ }
+
+ Context(
+ const Device& device,
+ cl_context_properties* properties = NULL,
+ void (CL_CALLBACK * notifyFptr)(
+ const char *,
+ const void *,
+ ::size_t,
+ void *) = NULL,
+ void* data = NULL,
+ cl_int* err = NULL)
+ {
+ cl_int error;
+
+ cl_device_id deviceID = device();
+
+ object_ = ::clCreateContext(
+ properties, 1,
+ &deviceID,
+ notifyFptr, data, &error);
+
+ detail::errHandler(error, __CREATE_CONTEXT_ERR);
+ if (err != NULL) {
+ *err = error;
+ }
+ }
+
+ /*! \brief Constructs a context including all or a subset of devices of a specified type.
+ *
+ * Wraps clCreateContextFromType().
+ */
+ Context(
+ cl_device_type type,
+ cl_context_properties* properties = NULL,
+ void (CL_CALLBACK * notifyFptr)(
+ const char *,
+ const void *,
+ ::size_t,
+ void *) = NULL,
+ void* data = NULL,
+ cl_int* err = NULL)
+ {
+ cl_int error;
+
+#if !defined(__APPLE__) && !defined(__MACOS)
+ cl_context_properties prop[4] = {CL_CONTEXT_PLATFORM, 0, 0, 0 };
+
+ if (properties == NULL) {
+ // Get a valid platform ID as we cannot send in a blank one
+ VECTOR_CLASS<Platform> platforms;
+ error = Platform::get(&platforms);
+ if (error != CL_SUCCESS) {
+ detail::errHandler(error, __CREATE_CONTEXT_FROM_TYPE_ERR);
+ if (err != NULL) {
+ *err = error;
+ }
+ return;
+ }
+
+ // Check the platforms we found for a device of our specified type
+ cl_context_properties platform_id = 0;
+ for (unsigned int i = 0; i < platforms.size(); i++) {
+
+ VECTOR_CLASS<Device> devices;
+
+#if defined(__CL_ENABLE_EXCEPTIONS)
+ try {
+#endif
+
+ error = platforms[i].getDevices(type, &devices);
+
+#if defined(__CL_ENABLE_EXCEPTIONS)
+ } catch (Error) {}
+ // Catch if exceptions are enabled as we don't want to exit if first platform has no devices of type
+ // We do error checking next anyway, and can throw there if needed
+#endif
+
+ // Only squash CL_SUCCESS and CL_DEVICE_NOT_FOUND
+ if (error != CL_SUCCESS && error != CL_DEVICE_NOT_FOUND) {
+ detail::errHandler(error, __CREATE_CONTEXT_FROM_TYPE_ERR);
+ if (err != NULL) {
+ *err = error;
+ }
+ }
+
+ if (devices.size() > 0) {
+ platform_id = (cl_context_properties)platforms[i]();
+ break;
+ }
+ }
+
+ if (platform_id == 0) {
+ detail::errHandler(CL_DEVICE_NOT_FOUND, __CREATE_CONTEXT_FROM_TYPE_ERR);
+ if (err != NULL) {
+ *err = CL_DEVICE_NOT_FOUND;
+ }
+ return;
+ }
+
+ prop[1] = platform_id;
+ properties = &prop[0];
+ }
+#endif
+ object_ = ::clCreateContextFromType(
+ properties, type, notifyFptr, data, &error);
+
+ detail::errHandler(error, __CREATE_CONTEXT_FROM_TYPE_ERR);
+ if (err != NULL) {
+ *err = error;
+ }
+ }
+
+ /*! \brief Copy constructor to forward copy to the superclass correctly.
+ * Required for MSVC.
+ */
+ Context(const Context& ctx) : detail::Wrapper<cl_type>(ctx) {}
+
+ /*! \brief Copy assignment to forward copy to the superclass correctly.
+ * Required for MSVC.
+ */
+ Context& operator = (const Context &ctx)
+ {
+ detail::Wrapper<cl_type>::operator=(ctx);
+ return *this;
+ }
+
+#if defined(CL_HPP_RVALUE_REFERENCES_SUPPORTED)
+ /*! \brief Move constructor to forward move to the superclass correctly.
+ * Required for MSVC.
+ */
+ Context(Context&& ctx) CL_HPP_NOEXCEPT : detail::Wrapper<cl_type>(std::move(ctx)) {}
+
+ /*! \brief Move assignment to forward move to the superclass correctly.
+ * Required for MSVC.
+ */
+ Context& operator = (Context &&ctx)
+ {
+ detail::Wrapper<cl_type>::operator=(std::move(ctx));
+ return *this;
+ }
+#endif // #if defined(CL_HPP_RVALUE_REFERENCES_SUPPORTED)
+
+ /*! \brief Returns a singleton context including all devices of CL_DEVICE_TYPE_DEFAULT.
+ *
+ * \note All calls to this function return the same cl_context as the first.
+ */
+ static Context getDefault(cl_int * err = NULL)
+ {
+ int state = detail::compare_exchange(
+ &default_initialized_,
+ __DEFAULT_BEING_INITIALIZED, __DEFAULT_NOT_INITIALIZED);
+
+ if (state & __DEFAULT_INITIALIZED) {
+ if (err != NULL) {
+ *err = default_error_;
+ }
+ return default_;
+ }
+
+ if (state & __DEFAULT_BEING_INITIALIZED) {
+ // Assume writes will propagate eventually...
+ while(default_initialized_ != __DEFAULT_INITIALIZED) {
+ detail::fence();
+ }
+
+ if (err != NULL) {
+ *err = default_error_;
+ }
+ return default_;
+ }
+
+ cl_int error;
+ default_ = Context(
+ CL_DEVICE_TYPE_DEFAULT,
+ NULL,
+ NULL,
+ NULL,
+ &error);
+
+ detail::fence();
+
+ default_error_ = error;
+ // Assume writes will propagate eventually...
+ default_initialized_ = __DEFAULT_INITIALIZED;
+
+ detail::fence();
+
+ if (err != NULL) {
+ *err = default_error_;
+ }
+ return default_;
+
+ }
+
+ //! \brief Default constructor - initializes to NULL.
+ Context() : detail::Wrapper<cl_type>() { }
+
+ /*! \brief Constructor from cl_context - takes ownership.
+ *
+ * This effectively transfers ownership of a refcount on the cl_context
+ * into the new Context object.
+ */
+ __CL_EXPLICIT_CONSTRUCTORS Context(const cl_context& context) : detail::Wrapper<cl_type>(context) { }
+
+ /*! \brief Assignment operator from cl_context - takes ownership.
+ *
+ * This effectively transfers ownership of a refcount on the rhs and calls
+ * clReleaseContext() on the value previously held by this instance.
+ */
+ Context& operator = (const cl_context& rhs)
+ {
+ detail::Wrapper<cl_type>::operator=(rhs);
+ return *this;
+ }
+
+ //! \brief Wrapper for clGetContextInfo().
+ template <typename T>
+ cl_int getInfo(cl_context_info name, T* param) const
+ {
+ return detail::errHandler(
+ detail::getInfo(&::clGetContextInfo, object_, name, param),
+ __GET_CONTEXT_INFO_ERR);
+ }
+
+ //! \brief Wrapper for clGetContextInfo() that returns by value.
+ template <cl_int name> typename
+ detail::param_traits<detail::cl_context_info, name>::param_type
+ getInfo(cl_int* err = NULL) const
+ {
+ typename detail::param_traits<
+ detail::cl_context_info, name>::param_type param;
+ cl_int result = getInfo(name, &param);
+ if (err != NULL) {
+ *err = result;
+ }
+ return param;
+ }
+
+ /*! \brief Gets a list of supported image formats.
+ *
+ * Wraps clGetSupportedImageFormats().
+ */
+ cl_int getSupportedImageFormats(
+ cl_mem_flags flags,
+ cl_mem_object_type type,
+ VECTOR_CLASS<ImageFormat>* formats) const
+ {
+ cl_uint numEntries;
+ cl_int err = ::clGetSupportedImageFormats(
+ object_,
+ flags,
+ type,
+ 0,
+ NULL,
+ &numEntries);
+ if (err != CL_SUCCESS) {
+ return detail::errHandler(err, __GET_SUPPORTED_IMAGE_FORMATS_ERR);
+ }
+
+ ImageFormat* value = (ImageFormat*)
+ alloca(numEntries * sizeof(ImageFormat));
+ err = ::clGetSupportedImageFormats(
+ object_,
+ flags,
+ type,
+ numEntries,
+ (cl_image_format*) value,
+ NULL);
+ if (err != CL_SUCCESS) {
+ return detail::errHandler(err, __GET_SUPPORTED_IMAGE_FORMATS_ERR);
+ }
+
+ formats->assign(&value[0], &value[numEntries]);
+ return CL_SUCCESS;
+ }
+};
+
+inline Device Device::getDefault(cl_int * err)
+{
+ cl_int error;
+ Device device;
+
+ Context context = Context::getDefault(&error);
+ detail::errHandler(error, __CREATE_CONTEXT_ERR);
+
+ if (error != CL_SUCCESS) {
+ if (err != NULL) {
+ *err = error;
+ }
+ }
+ else {
+ device = context.getInfo<CL_CONTEXT_DEVICES>()[0];
+ if (err != NULL) {
+ *err = CL_SUCCESS;
+ }
+ }
+
+ return device;
+}
+
+
+#ifdef _WIN32
+#ifdef CL_HPP_CPP11_ATOMICS_SUPPORTED
+__declspec(selectany) std::atomic<int> Context::default_initialized_;
+#else // !CL_HPP_CPP11_ATOMICS_SUPPORTED
+__declspec(selectany) volatile int Context::default_initialized_ = __DEFAULT_NOT_INITIALIZED;
+#endif // !CL_HPP_CPP11_ATOMICS_SUPPORTED
+__declspec(selectany) Context Context::default_;
+__declspec(selectany) volatile cl_int Context::default_error_ = CL_SUCCESS;
+#else // !_WIN32
+#ifdef CL_HPP_CPP11_ATOMICS_SUPPORTED
+__attribute__((weak)) std::atomic<int> Context::default_initialized_;
+#else // !CL_HPP_CPP11_ATOMICS_SUPPORTED
+__attribute__((weak)) volatile int Context::default_initialized_ = __DEFAULT_NOT_INITIALIZED;
+#endif // !CL_HPP_CPP11_ATOMICS_SUPPORTED
+__attribute__((weak)) Context Context::default_;
+__attribute__((weak)) volatile cl_int Context::default_error_ = CL_SUCCESS;
+#endif // !_WIN32
+
+/*! \brief Class interface for cl_event.
+ *
+ * \note Copies of these objects are shallow, meaning that the copy will refer
+ * to the same underlying cl_event as the original. For details, see
+ * clRetainEvent() and clReleaseEvent().
+ *
+ * \see cl_event
+ */
+class Event : public detail::Wrapper<cl_event>
+{
+public:
+ //! \brief Default constructor - initializes to NULL.
+ Event() : detail::Wrapper<cl_type>() { }
+
+ /*! \brief Constructor from cl_event - takes ownership.
+ *
+ * This effectively transfers ownership of a refcount on the cl_event
+ * into the new Event object.
+ */
+ __CL_EXPLICIT_CONSTRUCTORS Event(const cl_event& event) : detail::Wrapper<cl_type>(event) { }
+
+ /*! \brief Assignment operator from cl_event - takes ownership.
+ *
+ * This effectively transfers ownership of a refcount on the rhs and calls
+ * clReleaseEvent() on the value previously held by this instance.
+ */
+ Event& operator = (const cl_event& rhs)
+ {
+ detail::Wrapper<cl_type>::operator=(rhs);
+ return *this;
+ }
+
+ //! \brief Wrapper for clGetEventInfo().
+ template <typename T>
+ cl_int getInfo(cl_event_info name, T* param) const
+ {
+ return detail::errHandler(
+ detail::getInfo(&::clGetEventInfo, object_, name, param),
+ __GET_EVENT_INFO_ERR);
+ }
+
+ //! \brief Wrapper for clGetEventInfo() that returns by value.
+ template <cl_int name> typename
+ detail::param_traits<detail::cl_event_info, name>::param_type
+ getInfo(cl_int* err = NULL) const
+ {
+ typename detail::param_traits<
+ detail::cl_event_info, name>::param_type param;
+ cl_int result = getInfo(name, &param);
+ if (err != NULL) {
+ *err = result;
+ }
+ return param;
+ }
+
+ //! \brief Wrapper for clGetEventProfilingInfo().
+ template <typename T>
+ cl_int getProfilingInfo(cl_profiling_info name, T* param) const
+ {
+ return detail::errHandler(detail::getInfo(
+ &::clGetEventProfilingInfo, object_, name, param),
+ __GET_EVENT_PROFILE_INFO_ERR);
+ }
+
+ //! \brief Wrapper for clGetEventProfilingInfo() that returns by value.
+ template <cl_int name> typename
+ detail::param_traits<detail::cl_profiling_info, name>::param_type
+ getProfilingInfo(cl_int* err = NULL) const
+ {
+ typename detail::param_traits<
+ detail::cl_profiling_info, name>::param_type param;
+ cl_int result = getProfilingInfo(name, &param);
+ if (err != NULL) {
+ *err = result;
+ }
+ return param;
+ }
+
+ /*! \brief Blocks the calling thread until this event completes.
+ *
+ * Wraps clWaitForEvents().
+ */
+ cl_int wait() const
+ {
+ return detail::errHandler(
+ ::clWaitForEvents(1, &object_),
+ __WAIT_FOR_EVENTS_ERR);
+ }
+
+#if defined(CL_VERSION_1_1)
+ /*! \brief Registers a user callback function for a specific command execution status.
+ *
+ * Wraps clSetEventCallback().
+ */
+ cl_int setCallback(
+ cl_int type,
+ void (CL_CALLBACK * pfn_notify)(cl_event, cl_int, void *),
+ void * user_data = NULL)
+ {
+ return detail::errHandler(
+ ::clSetEventCallback(
+ object_,
+ type,
+ pfn_notify,
+ user_data),
+ __SET_EVENT_CALLBACK_ERR);
+ }
+#endif
+
+ /*! \brief Blocks the calling thread until every event specified is complete.
+ *
+ * Wraps clWaitForEvents().
+ */
+ static cl_int
+ waitForEvents(const VECTOR_CLASS<Event>& events)
+ {
+ return detail::errHandler(
+ ::clWaitForEvents(
+ (cl_uint) events.size(), (events.size() > 0) ? (cl_event*)&events.front() : NULL),
+ __WAIT_FOR_EVENTS_ERR);
+ }
+};
+
+#if defined(CL_VERSION_1_1)
+/*! \brief Class interface for user events (a subset of cl_event's).
+ *
+ * See Event for details about copy semantics, etc.
+ */
+class UserEvent : public Event
+{
+public:
+ /*! \brief Constructs a user event on a given context.
+ *
+ * Wraps clCreateUserEvent().
+ */
+ UserEvent(
+ const Context& context,
+ cl_int * err = NULL)
+ {
+ cl_int error;
+ object_ = ::clCreateUserEvent(
+ context(),
+ &error);
+
+ detail::errHandler(error, __CREATE_USER_EVENT_ERR);
+ if (err != NULL) {
+ *err = error;
+ }
+ }
+
+ //! \brief Default constructor - initializes to NULL.
+ UserEvent() : Event() { }
+
+ /*! \brief Sets the execution status of a user event object.
+ *
+ * Wraps clSetUserEventStatus().
+ */
+ cl_int setStatus(cl_int status)
+ {
+ return detail::errHandler(
+ ::clSetUserEventStatus(object_,status),
+ __SET_USER_EVENT_STATUS_ERR);
+ }
+};
+#endif
+
+/*! \brief Blocks the calling thread until every event specified is complete.
+ *
+ * Wraps clWaitForEvents().
+ */
+inline static cl_int
+WaitForEvents(const VECTOR_CLASS<Event>& events)
+{
+ return detail::errHandler(
+ ::clWaitForEvents(
+ (cl_uint) events.size(), (events.size() > 0) ? (cl_event*)&events.front() : NULL),
+ __WAIT_FOR_EVENTS_ERR);
+}
+
+/*! \brief Class interface for cl_mem.
+ *
+ * \note Copies of these objects are shallow, meaning that the copy will refer
+ * to the same underlying cl_mem as the original. For details, see
+ * clRetainMemObject() and clReleaseMemObject().
+ *
+ * \see cl_mem
+ */
+class Memory : public detail::Wrapper<cl_mem>
+{
+public:
+ //! \brief Default constructor - initializes to NULL.
+ Memory() : detail::Wrapper<cl_type>() { }
+
+ /*! \brief Constructor from cl_mem - takes ownership.
+ *
+ * This effectively transfers ownership of a refcount on the cl_mem
+ * into the new Memory object.
+ */
+ __CL_EXPLICIT_CONSTRUCTORS Memory(const cl_mem& memory) : detail::Wrapper<cl_type>(memory) { }
+
+ /*! \brief Assignment operator from cl_mem - takes ownership.
+ *
+ * This effectively transfers ownership of a refcount on the rhs and calls
+ * clReleaseMemObject() on the value previously held by this instance.
+ */
+ Memory& operator = (const cl_mem& rhs)
+ {
+ detail::Wrapper<cl_type>::operator=(rhs);
+ return *this;
+ }
+
+ /*! \brief Copy constructor to forward copy to the superclass correctly.
+ * Required for MSVC.
+ */
+ Memory(const Memory& mem) : detail::Wrapper<cl_type>(mem) {}
+
+ /*! \brief Copy assignment to forward copy to the superclass correctly.
+ * Required for MSVC.
+ */
+ Memory& operator = (const Memory &mem)
+ {
+ detail::Wrapper<cl_type>::operator=(mem);
+ return *this;
+ }
+
+#if defined(CL_HPP_RVALUE_REFERENCES_SUPPORTED)
+ /*! \brief Move constructor to forward move to the superclass correctly.
+ * Required for MSVC.
+ */
+ Memory(Memory&& mem) CL_HPP_NOEXCEPT : detail::Wrapper<cl_type>(std::move(mem)) {}
+
+ /*! \brief Move assignment to forward move to the superclass correctly.
+ * Required for MSVC.
+ */
+ Memory& operator = (Memory &&mem)
+ {
+ detail::Wrapper<cl_type>::operator=(std::move(mem));
+ return *this;
+ }
+#endif // #if defined(CL_HPP_RVALUE_REFERENCES_SUPPORTED)
+
+ //! \brief Wrapper for clGetMemObjectInfo().
+ template <typename T>
+ cl_int getInfo(cl_mem_info name, T* param) const
+ {
+ return detail::errHandler(
+ detail::getInfo(&::clGetMemObjectInfo, object_, name, param),
+ __GET_MEM_OBJECT_INFO_ERR);
+ }
+
+ //! \brief Wrapper for clGetMemObjectInfo() that returns by value.
+ template <cl_int name> typename
+ detail::param_traits<detail::cl_mem_info, name>::param_type
+ getInfo(cl_int* err = NULL) const
+ {
+ typename detail::param_traits<
+ detail::cl_mem_info, name>::param_type param;
+ cl_int result = getInfo(name, &param);
+ if (err != NULL) {
+ *err = result;
+ }
+ return param;
+ }
+
+#if defined(CL_VERSION_1_1)
+ /*! \brief Registers a callback function to be called when the memory object
+ * is no longer needed.
+ *
+ * Wraps clSetMemObjectDestructorCallback().
+ *
+ * Repeated calls to this function, for a given cl_mem value, will append
+ * to the list of functions called (in reverse order) when memory object's
+ * resources are freed and the memory object is deleted.
+ *
+ * \note
+ * The registered callbacks are associated with the underlying cl_mem
+ * value - not the Memory class instance.
+ */
+ cl_int setDestructorCallback(
+ void (CL_CALLBACK * pfn_notify)(cl_mem, void *),
+ void * user_data = NULL)
+ {
+ return detail::errHandler(
+ ::clSetMemObjectDestructorCallback(
+ object_,
+ pfn_notify,
+ user_data),
+ __SET_MEM_OBJECT_DESTRUCTOR_CALLBACK_ERR);
+ }
+#endif
+
+};
+
+// Pre-declare copy functions
+class Buffer;
+template< typename IteratorType >
+cl_int copy( IteratorType startIterator, IteratorType endIterator, cl::Buffer &buffer );
+template< typename IteratorType >
+cl_int copy( const cl::Buffer &buffer, IteratorType startIterator, IteratorType endIterator );
+template< typename IteratorType >
+cl_int copy( const CommandQueue &queue, IteratorType startIterator, IteratorType endIterator, cl::Buffer &buffer );
+template< typename IteratorType >
+cl_int copy( const CommandQueue &queue, const cl::Buffer &buffer, IteratorType startIterator, IteratorType endIterator );
+
+
+/*! \brief Class interface for Buffer Memory Objects.
+ *
+ * See Memory for details about copy semantics, etc.
+ *
+ * \see Memory
+ */
+class Buffer : public Memory
+{
+public:
+
+ /*! \brief Constructs a Buffer in a specified context.
+ *
+ * Wraps clCreateBuffer().
+ *
+ * \param host_ptr Storage to be used if the CL_MEM_USE_HOST_PTR flag was
+ * specified. Note alignment & exclusivity requirements.
+ */
+ Buffer(
+ const Context& context,
+ cl_mem_flags flags,
+ ::size_t size,
+ void* host_ptr = NULL,
+ cl_int* err = NULL)
+ {
+ cl_int error;
+ object_ = ::clCreateBuffer(context(), flags, size, host_ptr, &error);
+
+ detail::errHandler(error, __CREATE_BUFFER_ERR);
+ if (err != NULL) {
+ *err = error;
+ }
+ }
+
+ /*! \brief Constructs a Buffer in the default context.
+ *
+ * Wraps clCreateBuffer().
+ *
+ * \param host_ptr Storage to be used if the CL_MEM_USE_HOST_PTR flag was
+ * specified. Note alignment & exclusivity requirements.
+ *
+ * \see Context::getDefault()
+ */
+ Buffer(
+ cl_mem_flags flags,
+ ::size_t size,
+ void* host_ptr = NULL,
+ cl_int* err = NULL)
+ {
+ cl_int error;
+
+ Context context = Context::getDefault(err);
+
+ object_ = ::clCreateBuffer(context(), flags, size, host_ptr, &error);
+
+ detail::errHandler(error, __CREATE_BUFFER_ERR);
+ if (err != NULL) {
+ *err = error;
+ }
+ }
+
+ /*!
+ * \brief Construct a Buffer from a host container via iterators.
+ * IteratorType must be random access.
+ * If useHostPtr is specified iterators must represent contiguous data.
+ */
+ template< typename IteratorType >
+ Buffer(
+ IteratorType startIterator,
+ IteratorType endIterator,
+ bool readOnly,
+ bool useHostPtr = false,
+ cl_int* err = NULL)
+ {
+ typedef typename std::iterator_traits<IteratorType>::value_type DataType;
+ cl_int error;
+
+ cl_mem_flags flags = 0;
+ if( readOnly ) {
+ flags |= CL_MEM_READ_ONLY;
+ }
+ else {
+ flags |= CL_MEM_READ_WRITE;
+ }
+ if( useHostPtr ) {
+ flags |= CL_MEM_USE_HOST_PTR;
+ }
+
+ ::size_t size = sizeof(DataType)*(endIterator - startIterator);
+
+ Context context = Context::getDefault(err);
+
+ if( useHostPtr ) {
+ object_ = ::clCreateBuffer(context(), flags, size, static_cast<DataType*>(&*startIterator), &error);
+ } else {
+ object_ = ::clCreateBuffer(context(), flags, size, 0, &error);
+ }
+
+ detail::errHandler(error, __CREATE_BUFFER_ERR);
+ if (err != NULL) {
+ *err = error;
+ }
+
+ if( !useHostPtr ) {
+ error = cl::copy(startIterator, endIterator, *this);
+ detail::errHandler(error, __CREATE_BUFFER_ERR);
+ if (err != NULL) {
+ *err = error;
+ }
+ }
+ }
+
+ /*!
+ * \brief Construct a Buffer from a host container via iterators using a specified context.
+ * IteratorType must be random access.
+ * If useHostPtr is specified iterators must represent contiguous data.
+ */
+ template< typename IteratorType >
+ Buffer(const Context &context, IteratorType startIterator, IteratorType endIterator,
+ bool readOnly, bool useHostPtr = false, cl_int* err = NULL);
+
+ /*!
+ * \brief Construct a Buffer from a host container via iterators using a specified queue.
+ * If useHostPtr is specified iterators must represent contiguous data.
+ */
+ template< typename IteratorType >
+ Buffer(const CommandQueue &queue, IteratorType startIterator, IteratorType endIterator,
+ bool readOnly, bool useHostPtr = false, cl_int* err = NULL);
+
+ //! \brief Default constructor - initializes to NULL.
+ Buffer() : Memory() { }
+
+ /*! \brief Constructor from cl_mem - takes ownership.
+ *
+ * See Memory for further details.
+ */
+ __CL_EXPLICIT_CONSTRUCTORS Buffer(const cl_mem& buffer) : Memory(buffer) { }
+
+ /*! \brief Assignment from cl_mem - performs shallow copy.
+ *
+ * See Memory for further details.
+ */
+ Buffer& operator = (const cl_mem& rhs)
+ {
+ Memory::operator=(rhs);
+ return *this;
+ }
+
+ /*! \brief Copy constructor to forward copy to the superclass correctly.
+ * Required for MSVC.
+ */
+ Buffer(const Buffer& buf) : Memory(buf) {}
+
+ /*! \brief Copy assignment to forward copy to the superclass correctly.
+ * Required for MSVC.
+ */
+ Buffer& operator = (const Buffer &buf)
+ {
+ Memory::operator=(buf);
+ return *this;
+ }
+
+#if defined(CL_HPP_RVALUE_REFERENCES_SUPPORTED)
+ /*! \brief Move constructor to forward move to the superclass correctly.
+ * Required for MSVC.
+ */
+ Buffer(Buffer&& buf) CL_HPP_NOEXCEPT : Memory(std::move(buf)) {}
+
+ /*! \brief Move assignment to forward move to the superclass correctly.
+ * Required for MSVC.
+ */
+ Buffer& operator = (Buffer &&buf)
+ {
+ Memory::operator=(std::move(buf));
+ return *this;
+ }
+#endif // #if defined(CL_HPP_RVALUE_REFERENCES_SUPPORTED)
+
+#if defined(CL_VERSION_1_1)
+ /*! \brief Creates a new buffer object from this.
+ *
+ * Wraps clCreateSubBuffer().
+ */
+ Buffer createSubBuffer(
+ cl_mem_flags flags,
+ cl_buffer_create_type buffer_create_type,
+ const void * buffer_create_info,
+ cl_int * err = NULL)
+ {
+ Buffer result;
+ cl_int error;
+ result.object_ = ::clCreateSubBuffer(
+ object_,
+ flags,
+ buffer_create_type,
+ buffer_create_info,
+ &error);
+
+ detail::errHandler(error, __CREATE_SUBBUFFER_ERR);
+ if (err != NULL) {
+ *err = error;
+ }
+
+ return result;
+ }
+#endif
+};
+
+#if defined (USE_DX_INTEROP)
+/*! \brief Class interface for creating OpenCL buffers from ID3D10Buffer's.
+ *
+ * This is provided to facilitate interoperability with Direct3D.
+ *
+ * See Memory for details about copy semantics, etc.
+ *
+ * \see Memory
+ */
+class BufferD3D10 : public Buffer
+{
+public:
+ typedef CL_API_ENTRY cl_mem (CL_API_CALL *PFN_clCreateFromD3D10BufferKHR)(
+ cl_context context, cl_mem_flags flags, ID3D10Buffer* buffer,
+ cl_int* errcode_ret);
+
+ /*! \brief Constructs a BufferD3D10, in a specified context, from a
+ * given ID3D10Buffer.
+ *
+ * Wraps clCreateFromD3D10BufferKHR().
+ */
+ BufferD3D10(
+ const Context& context,
+ cl_mem_flags flags,
+ ID3D10Buffer* bufobj,
+ cl_int * err = NULL)
+ {
+ static PFN_clCreateFromD3D10BufferKHR pfn_clCreateFromD3D10BufferKHR = NULL;
+
+#if defined(CL_VERSION_1_2)
+ vector<cl_context_properties> props = context.getInfo<CL_CONTEXT_PROPERTIES>();
+ cl_platform platform = -1;
+ for( int i = 0; i < props.size(); ++i ) {
+ if( props[i] == CL_CONTEXT_PLATFORM ) {
+ platform = props[i+1];
+ }
+ }
+ __INIT_CL_EXT_FCN_PTR_PLATFORM(platform, clCreateFromD3D10BufferKHR);
+#endif
+#if defined(CL_VERSION_1_1)
+ __INIT_CL_EXT_FCN_PTR(clCreateFromD3D10BufferKHR);
+#endif
+
+ cl_int error;
+ object_ = pfn_clCreateFromD3D10BufferKHR(
+ context(),
+ flags,
+ bufobj,
+ &error);
+
+ detail::errHandler(error, __CREATE_GL_BUFFER_ERR);
+ if (err != NULL) {
+ *err = error;
+ }
+ }
+
+ //! \brief Default constructor - initializes to NULL.
+ BufferD3D10() : Buffer() { }
+
+ /*! \brief Constructor from cl_mem - takes ownership.
+ *
+ * See Memory for further details.
+ */
+ __CL_EXPLICIT_CONSTRUCTORS BufferD3D10(const cl_mem& buffer) : Buffer(buffer) { }
+
+ /*! \brief Assignment from cl_mem - performs shallow copy.
+ *
+ * See Memory for further details.
+ */
+ BufferD3D10& operator = (const cl_mem& rhs)
+ {
+ Buffer::operator=(rhs);
+ return *this;
+ }
+
+ /*! \brief Copy constructor to forward copy to the superclass correctly.
+ * Required for MSVC.
+ */
+ BufferD3D10(const BufferD3D10& buf) : Buffer(buf) {}
+
+ /*! \brief Copy assignment to forward copy to the superclass correctly.
+ * Required for MSVC.
+ */
+ BufferD3D10& operator = (const BufferD3D10 &buf)
+ {
+ Buffer::operator=(buf);
+ return *this;
+ }
+
+#if defined(CL_HPP_RVALUE_REFERENCES_SUPPORTED)
+ /*! \brief Move constructor to forward move to the superclass correctly.
+ * Required for MSVC.
+ */
+ BufferD3D10(BufferD3D10&& buf) CL_HPP_NOEXCEPT : Buffer(std::move(buf)) {}
+
+ /*! \brief Move assignment to forward move to the superclass correctly.
+ * Required for MSVC.
+ */
+ BufferD3D10& operator = (BufferD3D10 &&buf)
+ {
+ Buffer::operator=(std::move(buf));
+ return *this;
+ }
+#endif // #if defined(CL_HPP_RVALUE_REFERENCES_SUPPORTED)
+};
+#endif
+
+/*! \brief Class interface for GL Buffer Memory Objects.
+ *
+ * This is provided to facilitate interoperability with OpenGL.
+ *
+ * See Memory for details about copy semantics, etc.
+ *
+ * \see Memory
+ */
+class BufferGL : public Buffer
+{
+public:
+ /*! \brief Constructs a BufferGL in a specified context, from a given
+ * GL buffer.
+ *
+ * Wraps clCreateFromGLBuffer().
+ */
+ BufferGL(
+ const Context& context,
+ cl_mem_flags flags,
+ cl_GLuint bufobj,
+ cl_int * err = NULL)
+ {
+ cl_int error;
+ object_ = ::clCreateFromGLBuffer(
+ context(),
+ flags,
+ bufobj,
+ &error);
+
+ detail::errHandler(error, __CREATE_GL_BUFFER_ERR);
+ if (err != NULL) {
+ *err = error;
+ }
+ }
+
+ //! \brief Default constructor - initializes to NULL.
+ BufferGL() : Buffer() { }
+
+ /*! \brief Constructor from cl_mem - takes ownership.
+ *
+ * See Memory for further details.
+ */
+ __CL_EXPLICIT_CONSTRUCTORS BufferGL(const cl_mem& buffer) : Buffer(buffer) { }
+
+ /*! \brief Assignment from cl_mem - performs shallow copy.
+ *
+ * See Memory for further details.
+ */
+ BufferGL& operator = (const cl_mem& rhs)
+ {
+ Buffer::operator=(rhs);
+ return *this;
+ }
+
+ /*! \brief Copy constructor to forward copy to the superclass correctly.
+ * Required for MSVC.
+ */
+ BufferGL(const BufferGL& buf) : Buffer(buf) {}
+
+ /*! \brief Copy assignment to forward copy to the superclass correctly.
+ * Required for MSVC.
+ */
+ BufferGL& operator = (const BufferGL &buf)
+ {
+ Buffer::operator=(buf);
+ return *this;
+ }
+
+#if defined(CL_HPP_RVALUE_REFERENCES_SUPPORTED)
+ /*! \brief Move constructor to forward move to the superclass correctly.
+ * Required for MSVC.
+ */
+ BufferGL(BufferGL&& buf) CL_HPP_NOEXCEPT : Buffer(std::move(buf)) {}
+
+ /*! \brief Move assignment to forward move to the superclass correctly.
+ * Required for MSVC.
+ */
+ BufferGL& operator = (BufferGL &&buf)
+ {
+ Buffer::operator=(std::move(buf));
+ return *this;
+ }
+#endif // #if defined(CL_HPP_RVALUE_REFERENCES_SUPPORTED)
+
+ //! \brief Wrapper for clGetGLObjectInfo().
+ cl_int getObjectInfo(
+ cl_gl_object_type *type,
+ cl_GLuint * gl_object_name)
+ {
+ return detail::errHandler(
+ ::clGetGLObjectInfo(object_,type,gl_object_name),
+ __GET_GL_OBJECT_INFO_ERR);
+ }
+};
+
+/*! \brief C++ base class for Image Memory objects.
+ *
+ * See Memory for details about copy semantics, etc.
+ *
+ * \see Memory
+ */
+class Image : public Memory
+{
+protected:
+ //! \brief Default constructor - initializes to NULL.
+ Image() : Memory() { }
+
+ /*! \brief Constructor from cl_mem - takes ownership.
+ *
+ * See Memory for further details.
+ */
+ __CL_EXPLICIT_CONSTRUCTORS Image(const cl_mem& image) : Memory(image) { }
+
+ /*! \brief Assignment from cl_mem - performs shallow copy.
+ *
+ * See Memory for further details.
+ */
+ Image& operator = (const cl_mem& rhs)
+ {
+ Memory::operator=(rhs);
+ return *this;
+ }
+
+ /*! \brief Copy constructor to forward copy to the superclass correctly.
+ * Required for MSVC.
+ */
+ Image(const Image& img) : Memory(img) {}
+
+ /*! \brief Copy assignment to forward copy to the superclass correctly.
+ * Required for MSVC.
+ */
+ Image& operator = (const Image &img)
+ {
+ Memory::operator=(img);
+ return *this;
+ }
+
+#if defined(CL_HPP_RVALUE_REFERENCES_SUPPORTED)
+ /*! \brief Move constructor to forward move to the superclass correctly.
+ * Required for MSVC.
+ */
+ Image(Image&& img) CL_HPP_NOEXCEPT : Memory(std::move(img)) {}
+
+ /*! \brief Move assignment to forward move to the superclass correctly.
+ * Required for MSVC.
+ */
+ Image& operator = (Image &&img)
+ {
+ Memory::operator=(std::move(img));
+ return *this;
+ }
+#endif // #if defined(CL_HPP_RVALUE_REFERENCES_SUPPORTED)
+
+public:
+ //! \brief Wrapper for clGetImageInfo().
+ template <typename T>
+ cl_int getImageInfo(cl_image_info name, T* param) const
+ {
+ return detail::errHandler(
+ detail::getInfo(&::clGetImageInfo, object_, name, param),
+ __GET_IMAGE_INFO_ERR);
+ }
+
+ //! \brief Wrapper for clGetImageInfo() that returns by value.
+ template <cl_int name> typename
+ detail::param_traits<detail::cl_image_info, name>::param_type
+ getImageInfo(cl_int* err = NULL) const
+ {
+ typename detail::param_traits<
+ detail::cl_image_info, name>::param_type param;
+ cl_int result = getImageInfo(name, &param);
+ if (err != NULL) {
+ *err = result;
+ }
+ return param;
+ }
+};
+
+#if defined(CL_VERSION_1_2)
+/*! \brief Class interface for 1D Image Memory objects.
+ *
+ * See Memory for details about copy semantics, etc.
+ *
+ * \see Memory
+ */
+class Image1D : public Image
+{
+public:
+ /*! \brief Constructs a 1D Image in a specified context.
+ *
+ * Wraps clCreateImage().
+ */
+ Image1D(
+ const Context& context,
+ cl_mem_flags flags,
+ ImageFormat format,
+ ::size_t width,
+ void* host_ptr = NULL,
+ cl_int* err = NULL)
+ {
+ cl_int error;
+ cl_image_desc desc =
+ {
+ CL_MEM_OBJECT_IMAGE1D,
+ width,
+ 0, 0, 0, 0, 0, 0, 0, 0
+ };
+ object_ = ::clCreateImage(
+ context(),
+ flags,
+ &format,
+ &desc,
+ host_ptr,
+ &error);
+
+ detail::errHandler(error, __CREATE_IMAGE_ERR);
+ if (err != NULL) {
+ *err = error;
+ }
+ }
+
+ //! \brief Default constructor - initializes to NULL.
+ Image1D() { }
+
+ /*! \brief Constructor from cl_mem - takes ownership.
+ *
+ * See Memory for further details.
+ */
+ __CL_EXPLICIT_CONSTRUCTORS Image1D(const cl_mem& image1D) : Image(image1D) { }
+
+ /*! \brief Assignment from cl_mem - performs shallow copy.
+ *
+ * See Memory for further details.
+ */
+ Image1D& operator = (const cl_mem& rhs)
+ {
+ Image::operator=(rhs);
+ return *this;
+ }
+
+ /*! \brief Copy constructor to forward copy to the superclass correctly.
+ * Required for MSVC.
+ */
+ Image1D(const Image1D& img) : Image(img) {}
+
+ /*! \brief Copy assignment to forward copy to the superclass correctly.
+ * Required for MSVC.
+ */
+ Image1D& operator = (const Image1D &img)
+ {
+ Image::operator=(img);
+ return *this;
+ }
+
+#if defined(CL_HPP_RVALUE_REFERENCES_SUPPORTED)
+ /*! \brief Move constructor to forward move to the superclass correctly.
+ * Required for MSVC.
+ */
+ Image1D(Image1D&& img) CL_HPP_NOEXCEPT : Image(std::move(img)) {}
+
+ /*! \brief Move assignment to forward move to the superclass correctly.
+ * Required for MSVC.
+ */
+ Image1D& operator = (Image1D &&img)
+ {
+ Image::operator=(std::move(img));
+ return *this;
+ }
+#endif // #if defined(CL_HPP_RVALUE_REFERENCES_SUPPORTED)
+};
+
+/*! \class Image1DBuffer
+ * \brief Image interface for 1D buffer images.
+ */
+class Image1DBuffer : public Image
+{
+public:
+ Image1DBuffer(
+ const Context& context,
+ cl_mem_flags flags,
+ ImageFormat format,
+ ::size_t width,
+ const Buffer &buffer,
+ cl_int* err = NULL)
+ {
+ cl_int error;
+ cl_image_desc desc =
+ {
+ CL_MEM_OBJECT_IMAGE1D_BUFFER,
+ width,
+ 0, 0, 0, 0, 0, 0, 0,
+ buffer()
+ };
+ object_ = ::clCreateImage(
+ context(),
+ flags,
+ &format,
+ &desc,
+ NULL,
+ &error);
+
+ detail::errHandler(error, __CREATE_IMAGE_ERR);
+ if (err != NULL) {
+ *err = error;
+ }
+ }
+
+ Image1DBuffer() { }
+
+ __CL_EXPLICIT_CONSTRUCTORS Image1DBuffer(const cl_mem& image1D) : Image(image1D) { }
+
+ Image1DBuffer& operator = (const cl_mem& rhs)
+ {
+ Image::operator=(rhs);
+ return *this;
+ }
+
+ /*! \brief Copy constructor to forward copy to the superclass correctly.
+ * Required for MSVC.
+ */
+ Image1DBuffer(const Image1DBuffer& img) : Image(img) {}
+
+ /*! \brief Copy assignment to forward copy to the superclass correctly.
+ * Required for MSVC.
+ */
+ Image1DBuffer& operator = (const Image1DBuffer &img)
+ {
+ Image::operator=(img);
+ return *this;
+ }
+
+#if defined(CL_HPP_RVALUE_REFERENCES_SUPPORTED)
+ /*! \brief Move constructor to forward move to the superclass correctly.
+ * Required for MSVC.
+ */
+ Image1DBuffer(Image1DBuffer&& img) CL_HPP_NOEXCEPT : Image(std::move(img)) {}
+
+ /*! \brief Move assignment to forward move to the superclass correctly.
+ * Required for MSVC.
+ */
+ Image1DBuffer& operator = (Image1DBuffer &&img)
+ {
+ Image::operator=(std::move(img));
+ return *this;
+ }
+#endif // #if defined(CL_HPP_RVALUE_REFERENCES_SUPPORTED)
+};
+
+/*! \class Image1DArray
+ * \brief Image interface for arrays of 1D images.
+ */
+class Image1DArray : public Image
+{
+public:
+ Image1DArray(
+ const Context& context,
+ cl_mem_flags flags,
+ ImageFormat format,
+ ::size_t arraySize,
+ ::size_t width,
+ ::size_t rowPitch,
+ void* host_ptr = NULL,
+ cl_int* err = NULL)
+ {
+ cl_int error;
+ cl_image_desc desc =
+ {
+ CL_MEM_OBJECT_IMAGE1D_ARRAY,
+ width,
+ 0, 0, // height, depth (unused)
+ arraySize,
+ rowPitch,
+ 0, 0, 0, 0
+ };
+ object_ = ::clCreateImage(
+ context(),
+ flags,
+ &format,
+ &desc,
+ host_ptr,
+ &error);
+
+ detail::errHandler(error, __CREATE_IMAGE_ERR);
+ if (err != NULL) {
+ *err = error;
+ }
+ }
+
+ Image1DArray() { }
+
+ __CL_EXPLICIT_CONSTRUCTORS Image1DArray(const cl_mem& imageArray) : Image(imageArray) { }
+
+ Image1DArray& operator = (const cl_mem& rhs)
+ {
+ Image::operator=(rhs);
+ return *this;
+ }
+
+ /*! \brief Copy constructor to forward copy to the superclass correctly.
+ * Required for MSVC.
+ */
+ Image1DArray(const Image1DArray& img) : Image(img) {}
+
+ /*! \brief Copy assignment to forward copy to the superclass correctly.
+ * Required for MSVC.
+ */
+ Image1DArray& operator = (const Image1DArray &img)
+ {
+ Image::operator=(img);
+ return *this;
+ }
+
+#if defined(CL_HPP_RVALUE_REFERENCES_SUPPORTED)
+ /*! \brief Move constructor to forward move to the superclass correctly.
+ * Required for MSVC.
+ */
+ Image1DArray(Image1DArray&& img) CL_HPP_NOEXCEPT : Image(std::move(img)) {}
+
+ /*! \brief Move assignment to forward move to the superclass correctly.
+ * Required for MSVC.
+ */
+ Image1DArray& operator = (Image1DArray &&img)
+ {
+ Image::operator=(std::move(img));
+ return *this;
+ }
+#endif // #if defined(CL_HPP_RVALUE_REFERENCES_SUPPORTED)
+};
+#endif // #if defined(CL_VERSION_1_2)
+
+
+/*! \brief Class interface for 2D Image Memory objects.
+ *
+ * See Memory for details about copy semantics, etc.
+ *
+ * \see Memory
+ */
+class Image2D : public Image
+{
+public:
+ /*! \brief Constructs a 1D Image in a specified context.
+ *
+ * Wraps clCreateImage().
+ */
+ Image2D(
+ const Context& context,
+ cl_mem_flags flags,
+ ImageFormat format,
+ ::size_t width,
+ ::size_t height,
+ ::size_t row_pitch = 0,
+ void* host_ptr = NULL,
+ cl_int* err = NULL)
+ {
+ cl_int error;
+ bool useCreateImage;
+
+#if defined(CL_VERSION_1_2) && defined(CL_USE_DEPRECATED_OPENCL_1_1_APIS)
+ // Run-time decision based on the actual platform
+ {
+ cl_uint version = detail::getContextPlatformVersion(context());
+ useCreateImage = (version >= 0x10002); // OpenCL 1.2 or above
+ }
+#elif defined(CL_VERSION_1_2)
+ useCreateImage = true;
+#else
+ useCreateImage = false;
+#endif
+
+#if defined(CL_VERSION_1_2)
+ if (useCreateImage)
+ {
+ cl_image_desc desc =
+ {
+ CL_MEM_OBJECT_IMAGE2D,
+ width,
+ height,
+ 0, 0, // depth, array size (unused)
+ row_pitch,
+ 0, 0, 0, 0
+ };
+ object_ = ::clCreateImage(
+ context(),
+ flags,
+ &format,
+ &desc,
+ host_ptr,
+ &error);
+
+ detail::errHandler(error, __CREATE_IMAGE_ERR);
+ if (err != NULL) {
+ *err = error;
+ }
+ }
+#endif // #if defined(CL_VERSION_1_2)
+#if !defined(CL_VERSION_1_2) || defined(CL_USE_DEPRECATED_OPENCL_1_1_APIS)
+ if (!useCreateImage)
+ {
+ object_ = ::clCreateImage2D(
+ context(), flags,&format, width, height, row_pitch, host_ptr, &error);
+
+ detail::errHandler(error, __CREATE_IMAGE2D_ERR);
+ if (err != NULL) {
+ *err = error;
+ }
+ }
+#endif // #if !defined(CL_VERSION_1_2) || defined(CL_USE_DEPRECATED_OPENCL_1_1_APIS)
+ }
+
+ //! \brief Default constructor - initializes to NULL.
+ Image2D() { }
+
+ /*! \brief Constructor from cl_mem - takes ownership.
+ *
+ * See Memory for further details.
+ */
+ __CL_EXPLICIT_CONSTRUCTORS Image2D(const cl_mem& image2D) : Image(image2D) { }
+
+ /*! \brief Assignment from cl_mem - performs shallow copy.
+ *
+ * See Memory for further details.
+ */
+ Image2D& operator = (const cl_mem& rhs)
+ {
+ Image::operator=(rhs);
+ return *this;
+ }
+
+ /*! \brief Copy constructor to forward copy to the superclass correctly.
+ * Required for MSVC.
+ */
+ Image2D(const Image2D& img) : Image(img) {}
+
+ /*! \brief Copy assignment to forward copy to the superclass correctly.
+ * Required for MSVC.
+ */
+ Image2D& operator = (const Image2D &img)
+ {
+ Image::operator=(img);
+ return *this;
+ }
+
+#if defined(CL_HPP_RVALUE_REFERENCES_SUPPORTED)
+ /*! \brief Move constructor to forward move to the superclass correctly.
+ * Required for MSVC.
+ */
+ Image2D(Image2D&& img) CL_HPP_NOEXCEPT : Image(std::move(img)) {}
+
+ /*! \brief Move assignment to forward move to the superclass correctly.
+ * Required for MSVC.
+ */
+ Image2D& operator = (Image2D &&img)
+ {
+ Image::operator=(std::move(img));
+ return *this;
+ }
+#endif // #if defined(CL_HPP_RVALUE_REFERENCES_SUPPORTED)
+};
+
+
+#if !defined(CL_VERSION_1_2)
+/*! \brief Class interface for GL 2D Image Memory objects.
+ *
+ * This is provided to facilitate interoperability with OpenGL.
+ *
+ * See Memory for details about copy semantics, etc.
+ *
+ * \see Memory
+ * \note Deprecated for OpenCL 1.2. Please use ImageGL instead.
+ */
+class CL_EXT_PREFIX__VERSION_1_1_DEPRECATED Image2DGL CL_EXT_SUFFIX__VERSION_1_1_DEPRECATED : public Image2D
+{
+public:
+ /*! \brief Constructs an Image2DGL in a specified context, from a given
+ * GL Texture.
+ *
+ * Wraps clCreateFromGLTexture2D().
+ */
+ Image2DGL(
+ const Context& context,
+ cl_mem_flags flags,
+ cl_GLenum target,
+ cl_GLint miplevel,
+ cl_GLuint texobj,
+ cl_int * err = NULL)
+ {
+ cl_int error;
+ object_ = ::clCreateFromGLTexture2D(
+ context(),
+ flags,
+ target,
+ miplevel,
+ texobj,
+ &error);
+
+ detail::errHandler(error, __CREATE_GL_TEXTURE_2D_ERR);
+ if (err != NULL) {
+ *err = error;
+ }
+
+ }
+
+ //! \brief Default constructor - initializes to NULL.
+ Image2DGL() : Image2D() { }
+
+ /*! \brief Constructor from cl_mem - takes ownership.
+ *
+ * See Memory for further details.
+ */
+ __CL_EXPLICIT_CONSTRUCTORS Image2DGL(const cl_mem& image) : Image2D(image) { }
+
+ /*! \brief Assignment from cl_mem - performs shallow copy.
+ *
+ * See Memory for further details.
+ */
+ Image2DGL& operator = (const cl_mem& rhs)
+ {
+ Image2D::operator=(rhs);
+ return *this;
+ }
+
+ /*! \brief Copy constructor to forward copy to the superclass correctly.
+ * Required for MSVC.
+ */
+ Image2DGL(const Image2DGL& img) : Image2D(img) {}
+
+ /*! \brief Copy assignment to forward copy to the superclass correctly.
+ * Required for MSVC.
+ */
+ Image2DGL& operator = (const Image2DGL &img)
+ {
+ Image2D::operator=(img);
+ return *this;
+ }
+
+#if defined(CL_HPP_RVALUE_REFERENCES_SUPPORTED)
+ /*! \brief Move constructor to forward move to the superclass correctly.
+ * Required for MSVC.
+ */
+ Image2DGL(Image2DGL&& img) CL_HPP_NOEXCEPT : Image2D(std::move(img)) {}
+
+ /*! \brief Move assignment to forward move to the superclass correctly.
+ * Required for MSVC.
+ */
+ Image2DGL& operator = (Image2DGL &&img)
+ {
+ Image2D::operator=(std::move(img));
+ return *this;
+ }
+#endif // #if defined(CL_HPP_RVALUE_REFERENCES_SUPPORTED)
+};
+#endif // #if !defined(CL_VERSION_1_2)
+
+#if defined(CL_VERSION_1_2)
+/*! \class Image2DArray
+ * \brief Image interface for arrays of 2D images.
+ */
+class Image2DArray : public Image
+{
+public:
+ Image2DArray(
+ const Context& context,
+ cl_mem_flags flags,
+ ImageFormat format,
+ ::size_t arraySize,
+ ::size_t width,
+ ::size_t height,
+ ::size_t rowPitch,
+ ::size_t slicePitch,
+ void* host_ptr = NULL,
+ cl_int* err = NULL)
+ {
+ cl_int error;
+ cl_image_desc desc =
+ {
+ CL_MEM_OBJECT_IMAGE2D_ARRAY,
+ width,
+ height,
+ 0, // depth (unused)
+ arraySize,
+ rowPitch,
+ slicePitch,
+ 0, 0, 0
+ };
+ object_ = ::clCreateImage(
+ context(),
+ flags,
+ &format,
+ &desc,
+ host_ptr,
+ &error);
+
+ detail::errHandler(error, __CREATE_IMAGE_ERR);
+ if (err != NULL) {
+ *err = error;
+ }
+ }
+
+ Image2DArray() { }
+
+ __CL_EXPLICIT_CONSTRUCTORS Image2DArray(const cl_mem& imageArray) : Image(imageArray) { }
+
+ Image2DArray& operator = (const cl_mem& rhs)
+ {
+ Image::operator=(rhs);
+ return *this;
+ }
+
+ /*! \brief Copy constructor to forward copy to the superclass correctly.
+ * Required for MSVC.
+ */
+ Image2DArray(const Image2DArray& img) : Image(img) {}
+
+ /*! \brief Copy assignment to forward copy to the superclass correctly.
+ * Required for MSVC.
+ */
+ Image2DArray& operator = (const Image2DArray &img)
+ {
+ Image::operator=(img);
+ return *this;
+ }
+
+#if defined(CL_HPP_RVALUE_REFERENCES_SUPPORTED)
+ /*! \brief Move constructor to forward move to the superclass correctly.
+ * Required for MSVC.
+ */
+ Image2DArray(Image2DArray&& img) CL_HPP_NOEXCEPT : Image(std::move(img)) {}
+
+ /*! \brief Move assignment to forward move to the superclass correctly.
+ * Required for MSVC.
+ */
+ Image2DArray& operator = (Image2DArray &&img)
+ {
+ Image::operator=(std::move(img));
+ return *this;
+ }
+#endif // #if defined(CL_HPP_RVALUE_REFERENCES_SUPPORTED)
+};
+#endif // #if defined(CL_VERSION_1_2)
+
+/*! \brief Class interface for 3D Image Memory objects.
+ *
+ * See Memory for details about copy semantics, etc.
+ *
+ * \see Memory
+ */
+class Image3D : public Image
+{
+public:
+ /*! \brief Constructs a 3D Image in a specified context.
+ *
+ * Wraps clCreateImage().
+ */
+ Image3D(
+ const Context& context,
+ cl_mem_flags flags,
+ ImageFormat format,
+ ::size_t width,
+ ::size_t height,
+ ::size_t depth,
+ ::size_t row_pitch = 0,
+ ::size_t slice_pitch = 0,
+ void* host_ptr = NULL,
+ cl_int* err = NULL)
+ {
+ cl_int error;
+ bool useCreateImage;
+
+#if defined(CL_VERSION_1_2) && defined(CL_USE_DEPRECATED_OPENCL_1_1_APIS)
+ // Run-time decision based on the actual platform
+ {
+ cl_uint version = detail::getContextPlatformVersion(context());
+ useCreateImage = (version >= 0x10002); // OpenCL 1.2 or above
+ }
+#elif defined(CL_VERSION_1_2)
+ useCreateImage = true;
+#else
+ useCreateImage = false;
+#endif
+
+#if defined(CL_VERSION_1_2)
+ if (useCreateImage)
+ {
+ cl_image_desc desc =
+ {
+ CL_MEM_OBJECT_IMAGE3D,
+ width,
+ height,
+ depth,
+ 0, // array size (unused)
+ row_pitch,
+ slice_pitch,
+ 0, 0, 0
+ };
+ object_ = ::clCreateImage(
+ context(),
+ flags,
+ &format,
+ &desc,
+ host_ptr,
+ &error);
+
+ detail::errHandler(error, __CREATE_IMAGE_ERR);
+ if (err != NULL) {
+ *err = error;
+ }
+ }
+#endif // #if defined(CL_VERSION_1_2)
+#if !defined(CL_VERSION_1_2) || defined(CL_USE_DEPRECATED_OPENCL_1_1_APIS)
+ if (!useCreateImage)
+ {
+ object_ = ::clCreateImage3D(
+ context(), flags, &format, width, height, depth, row_pitch,
+ slice_pitch, host_ptr, &error);
+
+ detail::errHandler(error, __CREATE_IMAGE3D_ERR);
+ if (err != NULL) {
+ *err = error;
+ }
+ }
+#endif // #if !defined(CL_VERSION_1_2) || defined(CL_USE_DEPRECATED_OPENCL_1_1_APIS)
+ }
+
+ //! \brief Default constructor - initializes to NULL.
+ Image3D() : Image() { }
+
+ /*! \brief Constructor from cl_mem - takes ownership.
+ *
+ * See Memory for further details.
+ */
+ __CL_EXPLICIT_CONSTRUCTORS Image3D(const cl_mem& image3D) : Image(image3D) { }
+
+ /*! \brief Assignment from cl_mem - performs shallow copy.
+ *
+ * See Memory for further details.
+ */
+ Image3D& operator = (const cl_mem& rhs)
+ {
+ Image::operator=(rhs);
+ return *this;
+ }
+
+ /*! \brief Copy constructor to forward copy to the superclass correctly.
+ * Required for MSVC.
+ */
+ Image3D(const Image3D& img) : Image(img) {}
+
+ /*! \brief Copy assignment to forward copy to the superclass correctly.
+ * Required for MSVC.
+ */
+ Image3D& operator = (const Image3D &img)
+ {
+ Image::operator=(img);
+ return *this;
+ }
+
+#if defined(CL_HPP_RVALUE_REFERENCES_SUPPORTED)
+ /*! \brief Move constructor to forward move to the superclass correctly.
+ * Required for MSVC.
+ */
+ Image3D(Image3D&& img) CL_HPP_NOEXCEPT : Image(std::move(img)) {}
+
+ /*! \brief Move assignment to forward move to the superclass correctly.
+ * Required for MSVC.
+ */
+ Image3D& operator = (Image3D &&img)
+ {
+ Image::operator=(std::move(img));
+ return *this;
+ }
+#endif // #if defined(CL_HPP_RVALUE_REFERENCES_SUPPORTED)
+};
+
+#if !defined(CL_VERSION_1_2)
+/*! \brief Class interface for GL 3D Image Memory objects.
+ *
+ * This is provided to facilitate interoperability with OpenGL.
+ *
+ * See Memory for details about copy semantics, etc.
+ *
+ * \see Memory
+ */
+class Image3DGL : public Image3D
+{
+public:
+ /*! \brief Constructs an Image3DGL in a specified context, from a given
+ * GL Texture.
+ *
+ * Wraps clCreateFromGLTexture3D().
+ */
+ Image3DGL(
+ const Context& context,
+ cl_mem_flags flags,
+ cl_GLenum target,
+ cl_GLint miplevel,
+ cl_GLuint texobj,
+ cl_int * err = NULL)
+ {
+ cl_int error;
+ object_ = ::clCreateFromGLTexture3D(
+ context(),
+ flags,
+ target,
+ miplevel,
+ texobj,
+ &error);
+
+ detail::errHandler(error, __CREATE_GL_TEXTURE_3D_ERR);
+ if (err != NULL) {
+ *err = error;
+ }
+ }
+
+ //! \brief Default constructor - initializes to NULL.
+ Image3DGL() : Image3D() { }
+
+ /*! \brief Constructor from cl_mem - takes ownership.
+ *
+ * See Memory for further details.
+ */
+ __CL_EXPLICIT_CONSTRUCTORS Image3DGL(const cl_mem& image) : Image3D(image) { }
+
+ /*! \brief Assignment from cl_mem - performs shallow copy.
+ *
+ * See Memory for further details.
+ */
+ Image3DGL& operator = (const cl_mem& rhs)
+ {
+ Image3D::operator=(rhs);
+ return *this;
+ }
+
+ /*! \brief Copy constructor to forward copy to the superclass correctly.
+ * Required for MSVC.
+ */
+ Image3DGL(const Image3DGL& img) : Image3D(img) {}
+
+ /*! \brief Copy assignment to forward copy to the superclass correctly.
+ * Required for MSVC.
+ */
+ Image3DGL& operator = (const Image3DGL &img)
+ {
+ Image3D::operator=(img);
+ return *this;
+ }
+
+#if defined(CL_HPP_RVALUE_REFERENCES_SUPPORTED)
+ /*! \brief Move constructor to forward move to the superclass correctly.
+ * Required for MSVC.
+ */
+ Image3DGL(Image3DGL&& img) CL_HPP_NOEXCEPT : Image3D(std::move(img)) {}
+
+ /*! \brief Move assignment to forward move to the superclass correctly.
+ * Required for MSVC.
+ */
+ Image3DGL& operator = (Image3DGL &&img)
+ {
+ Image3D::operator=(std::move(img));
+ return *this;
+ }
+#endif // #if defined(CL_HPP_RVALUE_REFERENCES_SUPPORTED)
+};
+#endif // #if !defined(CL_VERSION_1_2)
+
+#if defined(CL_VERSION_1_2)
+/*! \class ImageGL
+ * \brief general image interface for GL interop.
+ * We abstract the 2D and 3D GL images into a single instance here
+ * that wraps all GL sourced images on the grounds that setup information
+ * was performed by OpenCL anyway.
+ */
+class ImageGL : public Image
+{
+public:
+ ImageGL(
+ const Context& context,
+ cl_mem_flags flags,
+ cl_GLenum target,
+ cl_GLint miplevel,
+ cl_GLuint texobj,
+ cl_int * err = NULL)
+ {
+ cl_int error;
+ object_ = ::clCreateFromGLTexture(
+ context(),
+ flags,
+ target,
+ miplevel,
+ texobj,
+ &error);
+
+ detail::errHandler(error, __CREATE_GL_TEXTURE_ERR);
+ if (err != NULL) {
+ *err = error;
+ }
+ }
+
+ ImageGL() : Image() { }
+
+ __CL_EXPLICIT_CONSTRUCTORS ImageGL(const cl_mem& image) : Image(image) { }
+
+ ImageGL& operator = (const cl_mem& rhs)
+ {
+ Image::operator=(rhs);
+ return *this;
+ }
+
+ /*! \brief Copy constructor to forward copy to the superclass correctly.
+ * Required for MSVC.
+ */
+ ImageGL(const ImageGL& img) : Image(img) {}
+
+ /*! \brief Copy assignment to forward copy to the superclass correctly.
+ * Required for MSVC.
+ */
+ ImageGL& operator = (const ImageGL &img)
+ {
+ Image::operator=(img);
+ return *this;
+ }
+
+#if defined(CL_HPP_RVALUE_REFERENCES_SUPPORTED)
+ /*! \brief Move constructor to forward move to the superclass correctly.
+ * Required for MSVC.
+ */
+ ImageGL(ImageGL&& img) CL_HPP_NOEXCEPT : Image(std::move(img)) {}
+
+ /*! \brief Move assignment to forward move to the superclass correctly.
+ * Required for MSVC.
+ */
+ ImageGL& operator = (ImageGL &&img)
+ {
+ Image::operator=(std::move(img));
+ return *this;
+ }
+#endif // #if defined(CL_HPP_RVALUE_REFERENCES_SUPPORTED)
+};
+#endif // #if defined(CL_VERSION_1_2)
+
+/*! \brief Class interface for GL Render Buffer Memory Objects.
+*
+* This is provided to facilitate interoperability with OpenGL.
+*
+* See Memory for details about copy semantics, etc.
+*
+* \see Memory
+*/
+class BufferRenderGL :
+#if defined(CL_VERSION_1_2)
+ public ImageGL
+#else // #if defined(CL_VERSION_1_2)
+ public Image2DGL
+#endif //#if defined(CL_VERSION_1_2)
+{
+public:
+ /*! \brief Constructs a BufferRenderGL in a specified context, from a given
+ * GL Renderbuffer.
+ *
+ * Wraps clCreateFromGLRenderbuffer().
+ */
+ BufferRenderGL(
+ const Context& context,
+ cl_mem_flags flags,
+ cl_GLuint bufobj,
+ cl_int * err = NULL)
+ {
+ cl_int error;
+ object_ = ::clCreateFromGLRenderbuffer(
+ context(),
+ flags,
+ bufobj,
+ &error);
+
+ detail::errHandler(error, __CREATE_GL_RENDER_BUFFER_ERR);
+ if (err != NULL) {
+ *err = error;
+ }
+ }
+
+ //! \brief Default constructor - initializes to NULL.
+#if defined(CL_VERSION_1_2)
+ BufferRenderGL() : ImageGL() {};
+#else // #if defined(CL_VERSION_1_2)
+ BufferRenderGL() : Image2DGL() {};
+#endif //#if defined(CL_VERSION_1_2)
+
+ /*! \brief Constructor from cl_mem - takes ownership.
+ *
+ * See Memory for further details.
+ */
+#if defined(CL_VERSION_1_2)
+ __CL_EXPLICIT_CONSTRUCTORS BufferRenderGL(const cl_mem& buffer) : ImageGL(buffer) { }
+#else // #if defined(CL_VERSION_1_2)
+ __CL_EXPLICIT_CONSTRUCTORS BufferRenderGL(const cl_mem& buffer) : Image2DGL(buffer) { }
+#endif //#if defined(CL_VERSION_1_2)
+
+
+ /*! \brief Assignment from cl_mem - performs shallow copy.
+ *
+ * See Memory for further details.
+ */
+ BufferRenderGL& operator = (const cl_mem& rhs)
+ {
+#if defined(CL_VERSION_1_2)
+ ImageGL::operator=(rhs);
+#else // #if defined(CL_VERSION_1_2)
+ Image2DGL::operator=(rhs);
+#endif //#if defined(CL_VERSION_1_2)
+
+ return *this;
+ }
+
+ /*! \brief Copy constructor to forward copy to the superclass correctly.
+ * Required for MSVC.
+ */
+#if defined(CL_VERSION_1_2)
+ BufferRenderGL(const BufferRenderGL& buf) : ImageGL(buf) {}
+#else // #if defined(CL_VERSION_1_2)
+ BufferRenderGL(const BufferRenderGL& buf) : Image2DGL(buf) {}
+#endif //#if defined(CL_VERSION_1_2)
+
+ /*! \brief Copy assignment to forward copy to the superclass correctly.
+ * Required for MSVC.
+ */
+ BufferRenderGL& operator = (const BufferRenderGL &rhs)
+ {
+#if defined(CL_VERSION_1_2)
+ ImageGL::operator=(rhs);
+#else // #if defined(CL_VERSION_1_2)
+ Image2DGL::operator=(rhs);
+#endif //#if defined(CL_VERSION_1_2)
+ return *this;
+ }
+
+#if defined(CL_HPP_RVALUE_REFERENCES_SUPPORTED)
+ /*! \brief Move constructor to forward move to the superclass correctly.
+ * Required for MSVC.
+ */
+#if defined(CL_VERSION_1_2)
+ BufferRenderGL(BufferRenderGL&& buf) CL_HPP_NOEXCEPT : ImageGL(std::move(buf)) {}
+#else // #if defined(CL_VERSION_1_2)
+ BufferRenderGL(BufferRenderGL&& buf) CL_HPP_NOEXCEPT : Image2DGL(std::move(buf)) {}
+#endif //#if defined(CL_VERSION_1_2)
+
+
+ /*! \brief Move assignment to forward move to the superclass correctly.
+ * Required for MSVC.
+ */
+ BufferRenderGL& operator = (BufferRenderGL &&buf)
+ {
+#if defined(CL_VERSION_1_2)
+ ImageGL::operator=(std::move(buf));
+#else // #if defined(CL_VERSION_1_2)
+ Image2DGL::operator=(std::move(buf));
+#endif //#if defined(CL_VERSION_1_2)
+
+ return *this;
+ }
+#endif // #if defined(CL_HPP_RVALUE_REFERENCES_SUPPORTED)
+
+ //! \brief Wrapper for clGetGLObjectInfo().
+ cl_int getObjectInfo(
+ cl_gl_object_type *type,
+ cl_GLuint * gl_object_name)
+ {
+ return detail::errHandler(
+ ::clGetGLObjectInfo(object_, type, gl_object_name),
+ __GET_GL_OBJECT_INFO_ERR);
+ }
+};
+
+/*! \brief Class interface for cl_sampler.
+ *
+ * \note Copies of these objects are shallow, meaning that the copy will refer
+ * to the same underlying cl_sampler as the original. For details, see
+ * clRetainSampler() and clReleaseSampler().
+ *
+ * \see cl_sampler
+ */
+class Sampler : public detail::Wrapper<cl_sampler>
+{
+public:
+ //! \brief Default constructor - initializes to NULL.
+ Sampler() { }
+
+ /*! \brief Constructs a Sampler in a specified context.
+ *
+ * Wraps clCreateSampler().
+ */
+ Sampler(
+ const Context& context,
+ cl_bool normalized_coords,
+ cl_addressing_mode addressing_mode,
+ cl_filter_mode filter_mode,
+ cl_int* err = NULL)
+ {
+ cl_int error;
+ object_ = ::clCreateSampler(
+ context(),
+ normalized_coords,
+ addressing_mode,
+ filter_mode,
+ &error);
+
+ detail::errHandler(error, __CREATE_SAMPLER_ERR);
+ if (err != NULL) {
+ *err = error;
+ }
+ }
+
+ /*! \brief Constructor from cl_sampler - takes ownership.
+ *
+ * This effectively transfers ownership of a refcount on the cl_sampler
+ * into the new Sampler object.
+ */
+ __CL_EXPLICIT_CONSTRUCTORS Sampler(const cl_sampler& sampler) : detail::Wrapper<cl_type>(sampler) { }
+
+ /*! \brief Assignment operator from cl_sampler - takes ownership.
+ *
+ * This effectively transfers ownership of a refcount on the rhs and calls
+ * clReleaseSampler() on the value previously held by this instance.
+ */
+ Sampler& operator = (const cl_sampler& rhs)
+ {
+ detail::Wrapper<cl_type>::operator=(rhs);
+ return *this;
+ }
+
+ /*! \brief Copy constructor to forward copy to the superclass correctly.
+ * Required for MSVC.
+ */
+ Sampler(const Sampler& sam) : detail::Wrapper<cl_type>(sam) {}
+
+ /*! \brief Copy assignment to forward copy to the superclass correctly.
+ * Required for MSVC.
+ */
+ Sampler& operator = (const Sampler &sam)
+ {
+ detail::Wrapper<cl_type>::operator=(sam);
+ return *this;
+ }
+
+#if defined(CL_HPP_RVALUE_REFERENCES_SUPPORTED)
+ /*! \brief Move constructor to forward move to the superclass correctly.
+ * Required for MSVC.
+ */
+ Sampler(Sampler&& sam) CL_HPP_NOEXCEPT : detail::Wrapper<cl_type>(std::move(sam)) {}
+
+ /*! \brief Move assignment to forward move to the superclass correctly.
+ * Required for MSVC.
+ */
+ Sampler& operator = (Sampler &&sam)
+ {
+ detail::Wrapper<cl_type>::operator=(std::move(sam));
+ return *this;
+ }
+#endif // #if defined(CL_HPP_RVALUE_REFERENCES_SUPPORTED)
+
+ //! \brief Wrapper for clGetSamplerInfo().
+ template <typename T>
+ cl_int getInfo(cl_sampler_info name, T* param) const
+ {
+ return detail::errHandler(
+ detail::getInfo(&::clGetSamplerInfo, object_, name, param),
+ __GET_SAMPLER_INFO_ERR);
+ }
+
+ //! \brief Wrapper for clGetSamplerInfo() that returns by value.
+ template <cl_int name> typename
+ detail::param_traits<detail::cl_sampler_info, name>::param_type
+ getInfo(cl_int* err = NULL) const
+ {
+ typename detail::param_traits<
+ detail::cl_sampler_info, name>::param_type param;
+ cl_int result = getInfo(name, &param);
+ if (err != NULL) {
+ *err = result;
+ }
+ return param;
+ }
+};
+
+class Program;
+class CommandQueue;
+class Kernel;
+
+//! \brief Class interface for specifying NDRange values.
+class NDRange
+{
+private:
+ size_t<3> sizes_;
+ cl_uint dimensions_;
+
+public:
+ //! \brief Default constructor - resulting range has zero dimensions.
+ NDRange()
+ : dimensions_(0)
+ { }
+
+ //! \brief Constructs one-dimensional range.
+ NDRange(::size_t size0)
+ : dimensions_(1)
+ {
+ sizes_[0] = size0;
+ }
+
+ //! \brief Constructs two-dimensional range.
+ NDRange(::size_t size0, ::size_t size1)
+ : dimensions_(2)
+ {
+ sizes_[0] = size0;
+ sizes_[1] = size1;
+ }
+
+ //! \brief Constructs three-dimensional range.
+ NDRange(::size_t size0, ::size_t size1, ::size_t size2)
+ : dimensions_(3)
+ {
+ sizes_[0] = size0;
+ sizes_[1] = size1;
+ sizes_[2] = size2;
+ }
+
+ /*! \brief Conversion operator to const ::size_t *.
+ *
+ * \returns a pointer to the size of the first dimension.
+ */
+ operator const ::size_t*() const {
+ return (const ::size_t*) sizes_;
+ }
+
+ //! \brief Queries the number of dimensions in the range.
+ ::size_t dimensions() const { return dimensions_; }
+};
+
+//! \brief A zero-dimensional range.
+static const NDRange NullRange;
+
+//! \brief Local address wrapper for use with Kernel::setArg
+struct LocalSpaceArg
+{
+ ::size_t size_;
+};
+
+namespace detail {
+
+template <typename T>
+struct KernelArgumentHandler
+{
+ static ::size_t size(const T&) { return sizeof(T); }
+ static const T* ptr(const T& value) { return &value; }
+};
+
+template <>
+struct KernelArgumentHandler<LocalSpaceArg>
+{
+ static ::size_t size(const LocalSpaceArg& value) { return value.size_; }
+ static const void* ptr(const LocalSpaceArg&) { return NULL; }
+};
+
+}
+//! \endcond
+
+/*! __local
+ * \brief Helper function for generating LocalSpaceArg objects.
+ * Deprecated. Replaced with Local.
+ */
+inline CL_EXT_PREFIX__VERSION_1_1_DEPRECATED LocalSpaceArg
+__local(::size_t size) CL_EXT_SUFFIX__VERSION_1_1_DEPRECATED;
+inline LocalSpaceArg
+__local(::size_t size)
+{
+ LocalSpaceArg ret = { size };
+ return ret;
+}
+
+/*! Local
+ * \brief Helper function for generating LocalSpaceArg objects.
+ */
+inline LocalSpaceArg
+Local(::size_t size)
+{
+ LocalSpaceArg ret = { size };
+ return ret;
+}
+
+//class KernelFunctor;
+
+/*! \brief Class interface for cl_kernel.
+ *
+ * \note Copies of these objects are shallow, meaning that the copy will refer
+ * to the same underlying cl_kernel as the original. For details, see
+ * clRetainKernel() and clReleaseKernel().
+ *
+ * \see cl_kernel
+ */
+class Kernel : public detail::Wrapper<cl_kernel>
+{
+public:
+ inline Kernel(const Program& program, const char* name, cl_int* err = NULL);
+
+ //! \brief Default constructor - initializes to NULL.
+ Kernel() { }
+
+ /*! \brief Constructor from cl_kernel - takes ownership.
+ *
+ * This effectively transfers ownership of a refcount on the cl_kernel
+ * into the new Kernel object.
+ */
+ __CL_EXPLICIT_CONSTRUCTORS Kernel(const cl_kernel& kernel) : detail::Wrapper<cl_type>(kernel) { }
+
+ /*! \brief Assignment operator from cl_kernel - takes ownership.
+ *
+ * This effectively transfers ownership of a refcount on the rhs and calls
+ * clReleaseKernel() on the value previously held by this instance.
+ */
+ Kernel& operator = (const cl_kernel& rhs)
+ {
+ detail::Wrapper<cl_type>::operator=(rhs);
+ return *this;
+ }
+
+ /*! \brief Copy constructor to forward copy to the superclass correctly.
+ * Required for MSVC.
+ */
+ Kernel(const Kernel& kernel) : detail::Wrapper<cl_type>(kernel) {}
+
+ /*! \brief Copy assignment to forward copy to the superclass correctly.
+ * Required for MSVC.
+ */
+ Kernel& operator = (const Kernel &kernel)
+ {
+ detail::Wrapper<cl_type>::operator=(kernel);
+ return *this;
+ }
+
+#if defined(CL_HPP_RVALUE_REFERENCES_SUPPORTED)
+ /*! \brief Move constructor to forward move to the superclass correctly.
+ * Required for MSVC.
+ */
+ Kernel(Kernel&& kernel) CL_HPP_NOEXCEPT : detail::Wrapper<cl_type>(std::move(kernel)) {}
+
+ /*! \brief Move assignment to forward move to the superclass correctly.
+ * Required for MSVC.
+ */
+ Kernel& operator = (Kernel &&kernel)
+ {
+ detail::Wrapper<cl_type>::operator=(std::move(kernel));
+ return *this;
+ }
+#endif // #if defined(CL_HPP_RVALUE_REFERENCES_SUPPORTED)
+
+ template <typename T>
+ cl_int getInfo(cl_kernel_info name, T* param) const
+ {
+ return detail::errHandler(
+ detail::getInfo(&::clGetKernelInfo, object_, name, param),
+ __GET_KERNEL_INFO_ERR);
+ }
+
+ template <cl_int name> typename
+ detail::param_traits<detail::cl_kernel_info, name>::param_type
+ getInfo(cl_int* err = NULL) const
+ {
+ typename detail::param_traits<
+ detail::cl_kernel_info, name>::param_type param;
+ cl_int result = getInfo(name, &param);
+ if (err != NULL) {
+ *err = result;
+ }
+ return param;
+ }
+
+#if defined(CL_VERSION_1_2)
+ template <typename T>
+ cl_int getArgInfo(cl_uint argIndex, cl_kernel_arg_info name, T* param) const
+ {
+ return detail::errHandler(
+ detail::getInfo(&::clGetKernelArgInfo, object_, argIndex, name, param),
+ __GET_KERNEL_ARG_INFO_ERR);
+ }
+
+ template <cl_int name> typename
+ detail::param_traits<detail::cl_kernel_arg_info, name>::param_type
+ getArgInfo(cl_uint argIndex, cl_int* err = NULL) const
+ {
+ typename detail::param_traits<
+ detail::cl_kernel_arg_info, name>::param_type param;
+ cl_int result = getArgInfo(argIndex, name, &param);
+ if (err != NULL) {
+ *err = result;
+ }
+ return param;
+ }
+#endif // #if defined(CL_VERSION_1_2)
+
+ template <typename T>
+ cl_int getWorkGroupInfo(
+ const Device& device, cl_kernel_work_group_info name, T* param) const
+ {
+ return detail::errHandler(
+ detail::getInfo(
+ &::clGetKernelWorkGroupInfo, object_, device(), name, param),
+ __GET_KERNEL_WORK_GROUP_INFO_ERR);
+ }
+
+ template <cl_int name> typename
+ detail::param_traits<detail::cl_kernel_work_group_info, name>::param_type
+ getWorkGroupInfo(const Device& device, cl_int* err = NULL) const
+ {
+ typename detail::param_traits<
+ detail::cl_kernel_work_group_info, name>::param_type param;
+ cl_int result = getWorkGroupInfo(device, name, &param);
+ if (err != NULL) {
+ *err = result;
+ }
+ return param;
+ }
+
+ template <typename T>
+ cl_int setArg(cl_uint index, const T &value)
+ {
+ return detail::errHandler(
+ ::clSetKernelArg(
+ object_,
+ index,
+ detail::KernelArgumentHandler<T>::size(value),
+ detail::KernelArgumentHandler<T>::ptr(value)),
+ __SET_KERNEL_ARGS_ERR);
+ }
+
+ cl_int setArg(cl_uint index, ::size_t size, const void* argPtr)
+ {
+ return detail::errHandler(
+ ::clSetKernelArg(object_, index, size, argPtr),
+ __SET_KERNEL_ARGS_ERR);
+ }
+};
+
+/*! \class Program
+ * \brief Program interface that implements cl_program.
+ */
+class Program : public detail::Wrapper<cl_program>
+{
+public:
+ typedef VECTOR_CLASS<std::pair<const void*, ::size_t> > Binaries;
+ typedef VECTOR_CLASS<std::pair<const char*, ::size_t> > Sources;
+
+ Program(
+ const STRING_CLASS& source,
+ bool build = false,
+ cl_int* err = NULL)
+ {
+ cl_int error;
+
+ const char * strings = source.c_str();
+ const ::size_t length = source.size();
+
+ Context context = Context::getDefault(err);
+
+ object_ = ::clCreateProgramWithSource(
+ context(), (cl_uint)1, &strings, &length, &error);
+
+ detail::errHandler(error, __CREATE_PROGRAM_WITH_SOURCE_ERR);
+
+ if (error == CL_SUCCESS && build) {
+
+ error = ::clBuildProgram(
+ object_,
+ 0,
+ NULL,
+ "",
+ NULL,
+ NULL);
+
+ detail::errHandler(error, __BUILD_PROGRAM_ERR);
+ }
+
+ if (err != NULL) {
+ *err = error;
+ }
+ }
+
+ Program(
+ const Context& context,
+ const STRING_CLASS& source,
+ bool build = false,
+ cl_int* err = NULL)
+ {
+ cl_int error;
+
+ const char * strings = source.c_str();
+ const ::size_t length = source.size();
+
+ object_ = ::clCreateProgramWithSource(
+ context(), (cl_uint)1, &strings, &length, &error);
+
+ detail::errHandler(error, __CREATE_PROGRAM_WITH_SOURCE_ERR);
+
+ if (error == CL_SUCCESS && build) {
+
+ error = ::clBuildProgram(
+ object_,
+ 0,
+ NULL,
+ "",
+ NULL,
+ NULL);
+
+ detail::errHandler(error, __BUILD_PROGRAM_ERR);
+ }
+
+ if (err != NULL) {
+ *err = error;
+ }
+ }
+
+ Program(
+ const Context& context,
+ const Sources& sources,
+ cl_int* err = NULL)
+ {
+ cl_int error;
+
+ const ::size_t n = (::size_t)sources.size();
+ ::size_t* lengths = (::size_t*) alloca(n * sizeof(::size_t));
+ const char** strings = (const char**) alloca(n * sizeof(const char*));
+
+ for (::size_t i = 0; i < n; ++i) {
+ strings[i] = sources[(int)i].first;
+ lengths[i] = sources[(int)i].second;
+ }
+
+ object_ = ::clCreateProgramWithSource(
+ context(), (cl_uint)n, strings, lengths, &error);
+
+ detail::errHandler(error, __CREATE_PROGRAM_WITH_SOURCE_ERR);
+ if (err != NULL) {
+ *err = error;
+ }
+ }
+
+ /**
+ * Construct a program object from a list of devices and a per-device list of binaries.
+ * \param context A valid OpenCL context in which to construct the program.
+ * \param devices A vector of OpenCL device objects for which the program will be created.
+ * \param binaries A vector of pairs of a pointer to a binary object and its length.
+ * \param binaryStatus An optional vector that on completion will be resized to
+ * match the size of binaries and filled with values to specify if each binary
+ * was successfully loaded.
+ * Set to CL_SUCCESS if the binary was successfully loaded.
+ * Set to CL_INVALID_VALUE if the length is 0 or the binary pointer is NULL.
+ * Set to CL_INVALID_BINARY if the binary provided is not valid for the matching device.
+ * \param err if non-NULL will be set to CL_SUCCESS on successful operation or one of the following errors:
+ * CL_INVALID_CONTEXT if context is not a valid context.
+ * CL_INVALID_VALUE if the length of devices is zero; or if the length of binaries does not match the length of devices;
+ * or if any entry in binaries is NULL or has length 0.
+ * CL_INVALID_DEVICE if OpenCL devices listed in devices are not in the list of devices associated with context.
+ * CL_INVALID_BINARY if an invalid program binary was encountered for any device. binaryStatus will return specific status for each device.
+ * CL_OUT_OF_HOST_MEMORY if there is a failure to allocate resources required by the OpenCL implementation on the host.
+ */
+ Program(
+ const Context& context,
+ const VECTOR_CLASS<Device>& devices,
+ const Binaries& binaries,
+ VECTOR_CLASS<cl_int>* binaryStatus = NULL,
+ cl_int* err = NULL)
+ {
+ cl_int error;
+
+ const ::size_t numDevices = devices.size();
+
+ // Catch size mismatch early and return
+ if(binaries.size() != numDevices) {
+ error = CL_INVALID_VALUE;
+ detail::errHandler(error, __CREATE_PROGRAM_WITH_BINARY_ERR);
+ if (err != NULL) {
+ *err = error;
+ }
+ return;
+ }
+
+ ::size_t* lengths = (::size_t*) alloca(numDevices * sizeof(::size_t));
+ const unsigned char** images = (const unsigned char**) alloca(numDevices * sizeof(const unsigned char**));
+
+ for (::size_t i = 0; i < numDevices; ++i) {
+ images[i] = (const unsigned char*)binaries[i].first;
+ lengths[i] = binaries[(int)i].second;
+ }
+
+ cl_device_id* deviceIDs = (cl_device_id*) alloca(numDevices * sizeof(cl_device_id));
+ for( ::size_t deviceIndex = 0; deviceIndex < numDevices; ++deviceIndex ) {
+ deviceIDs[deviceIndex] = (devices[deviceIndex])();
+ }
+
+ if(binaryStatus) {
+ binaryStatus->resize(numDevices);
+ }
+
+ object_ = ::clCreateProgramWithBinary(
+ context(), (cl_uint) devices.size(),
+ deviceIDs,
+ lengths, images, (binaryStatus != NULL && numDevices > 0)
+ ? &binaryStatus->front()
+ : NULL, &error);
+
+ detail::errHandler(error, __CREATE_PROGRAM_WITH_BINARY_ERR);
+ if (err != NULL) {
+ *err = error;
+ }
+ }
+
+
+#if defined(CL_VERSION_1_2)
+ /**
+ * Create program using builtin kernels.
+ * \param kernelNames Semi-colon separated list of builtin kernel names
+ */
+ Program(
+ const Context& context,
+ const VECTOR_CLASS<Device>& devices,
+ const STRING_CLASS& kernelNames,
+ cl_int* err = NULL)
+ {
+ cl_int error;
+
+
+ ::size_t numDevices = devices.size();
+ cl_device_id* deviceIDs = (cl_device_id*) alloca(numDevices * sizeof(cl_device_id));
+ for( ::size_t deviceIndex = 0; deviceIndex < numDevices; ++deviceIndex ) {
+ deviceIDs[deviceIndex] = (devices[deviceIndex])();
+ }
+
+ object_ = ::clCreateProgramWithBuiltInKernels(
+ context(),
+ (cl_uint) devices.size(),
+ deviceIDs,
+ kernelNames.c_str(),
+ &error);
+
+ detail::errHandler(error, __CREATE_PROGRAM_WITH_BUILT_IN_KERNELS_ERR);
+ if (err != NULL) {
+ *err = error;
+ }
+ }
+#endif // #if defined(CL_VERSION_1_2)
+
+ Program() { }
+
+ __CL_EXPLICIT_CONSTRUCTORS Program(const cl_program& program) : detail::Wrapper<cl_type>(program) { }
+
+ Program& operator = (const cl_program& rhs)
+ {
+ detail::Wrapper<cl_type>::operator=(rhs);
+ return *this;
+ }
+
+ /*! \brief Copy constructor to forward copy to the superclass correctly.
+ * Required for MSVC.
+ */
+ Program(const Program& program) : detail::Wrapper<cl_type>(program) {}
+
+ /*! \brief Copy assignment to forward copy to the superclass correctly.
+ * Required for MSVC.
+ */
+ Program& operator = (const Program &program)
+ {
+ detail::Wrapper<cl_type>::operator=(program);
+ return *this;
+ }
+
+#if defined(CL_HPP_RVALUE_REFERENCES_SUPPORTED)
+ /*! \brief Move constructor to forward move to the superclass correctly.
+ * Required for MSVC.
+ */
+ Program(Program&& program) CL_HPP_NOEXCEPT : detail::Wrapper<cl_type>(std::move(program)) {}
+
+ /*! \brief Move assignment to forward move to the superclass correctly.
+ * Required for MSVC.
+ */
+ Program& operator = (Program &&program)
+ {
+ detail::Wrapper<cl_type>::operator=(std::move(program));
+ return *this;
+ }
+#endif // #if defined(CL_HPP_RVALUE_REFERENCES_SUPPORTED)
+
+ cl_int build(
+ const VECTOR_CLASS<Device>& devices,
+ const char* options = NULL,
+ void (CL_CALLBACK * notifyFptr)(cl_program, void *) = NULL,
+ void* data = NULL) const
+ {
+ ::size_t numDevices = devices.size();
+ cl_device_id* deviceIDs = (cl_device_id*) alloca(numDevices * sizeof(cl_device_id));
+ for( ::size_t deviceIndex = 0; deviceIndex < numDevices; ++deviceIndex ) {
+ deviceIDs[deviceIndex] = (devices[deviceIndex])();
+ }
+
+ return detail::errHandler(
+ ::clBuildProgram(
+ object_,
+ (cl_uint)
+ devices.size(),
+ deviceIDs,
+ options,
+ notifyFptr,
+ data),
+ __BUILD_PROGRAM_ERR);
+ }
+
+ cl_int build(
+ const char* options = NULL,
+ void (CL_CALLBACK * notifyFptr)(cl_program, void *) = NULL,
+ void* data = NULL) const
+ {
+ return detail::errHandler(
+ ::clBuildProgram(
+ object_,
+ 0,
+ NULL,
+ options,
+ notifyFptr,
+ data),
+ __BUILD_PROGRAM_ERR);
+ }
+
+#if defined(CL_VERSION_1_2)
+ cl_int compile(
+ const char* options = NULL,
+ void (CL_CALLBACK * notifyFptr)(cl_program, void *) = NULL,
+ void* data = NULL) const
+ {
+ return detail::errHandler(
+ ::clCompileProgram(
+ object_,
+ 0,
+ NULL,
+ options,
+ 0,
+ NULL,
+ NULL,
+ notifyFptr,
+ data),
+ __COMPILE_PROGRAM_ERR);
+ }
+#endif
+
+ template <typename T>
+ cl_int getInfo(cl_program_info name, T* param) const
+ {
+ return detail::errHandler(
+ detail::getInfo(&::clGetProgramInfo, object_, name, param),
+ __GET_PROGRAM_INFO_ERR);
+ }
+
+ template <cl_int name> typename
+ detail::param_traits<detail::cl_program_info, name>::param_type
+ getInfo(cl_int* err = NULL) const
+ {
+ typename detail::param_traits<
+ detail::cl_program_info, name>::param_type param;
+ cl_int result = getInfo(name, &param);
+ if (err != NULL) {
+ *err = result;
+ }
+ return param;
+ }
+
+ template <typename T>
+ cl_int getBuildInfo(
+ const Device& device, cl_program_build_info name, T* param) const
+ {
+ return detail::errHandler(
+ detail::getInfo(
+ &::clGetProgramBuildInfo, object_, device(), name, param),
+ __GET_PROGRAM_BUILD_INFO_ERR);
+ }
+
+ template <cl_int name> typename
+ detail::param_traits<detail::cl_program_build_info, name>::param_type
+ getBuildInfo(const Device& device, cl_int* err = NULL) const
+ {
+ typename detail::param_traits<
+ detail::cl_program_build_info, name>::param_type param;
+ cl_int result = getBuildInfo(device, name, &param);
+ if (err != NULL) {
+ *err = result;
+ }
+ return param;
+ }
+
+ cl_int createKernels(VECTOR_CLASS<Kernel>* kernels)
+ {
+ cl_uint numKernels;
+ cl_int err = ::clCreateKernelsInProgram(object_, 0, NULL, &numKernels);
+ if (err != CL_SUCCESS) {
+ return detail::errHandler(err, __CREATE_KERNELS_IN_PROGRAM_ERR);
+ }
+
+ Kernel* value = (Kernel*) alloca(numKernels * sizeof(Kernel));
+ err = ::clCreateKernelsInProgram(
+ object_, numKernels, (cl_kernel*) value, NULL);
+ if (err != CL_SUCCESS) {
+ return detail::errHandler(err, __CREATE_KERNELS_IN_PROGRAM_ERR);
+ }
+
+ kernels->assign(&value[0], &value[numKernels]);
+ return CL_SUCCESS;
+ }
+};
+
+#if defined(CL_VERSION_1_2)
+inline Program linkProgram(
+ Program input1,
+ Program input2,
+ const char* options = NULL,
+ void (CL_CALLBACK * notifyFptr)(cl_program, void *) = NULL,
+ void* data = NULL,
+ cl_int* err = NULL)
+{
+ cl_int error_local = CL_SUCCESS;
+
+ cl_program programs[2] = { input1(), input2() };
+
+ Context ctx = input1.getInfo<CL_PROGRAM_CONTEXT>(&error_local);
+ if(error_local!=CL_SUCCESS) {
+ detail::errHandler(error_local, __LINK_PROGRAM_ERR);
+ }
+
+ cl_program prog = ::clLinkProgram(
+ ctx(),
+ 0,
+ NULL,
+ options,
+ 2,
+ programs,
+ notifyFptr,
+ data,
+ &error_local);
+
+ detail::errHandler(error_local,__COMPILE_PROGRAM_ERR);
+ if (err != NULL) {
+ *err = error_local;
+ }
+
+ return Program(prog);
+}
+
+inline Program linkProgram(
+ VECTOR_CLASS<Program> inputPrograms,
+ const char* options = NULL,
+ void (CL_CALLBACK * notifyFptr)(cl_program, void *) = NULL,
+ void* data = NULL,
+ cl_int* err = NULL)
+{
+ cl_int error_local = CL_SUCCESS;
+
+ cl_program * programs = (cl_program*) alloca(inputPrograms.size() * sizeof(cl_program));
+
+ if (programs != NULL) {
+ for (unsigned int i = 0; i < inputPrograms.size(); i++) {
+ programs[i] = inputPrograms[i]();
+ }
+ }
+
+ Context ctx;
+ if(inputPrograms.size() > 0) {
+ ctx = inputPrograms[0].getInfo<CL_PROGRAM_CONTEXT>(&error_local);
+ if(error_local!=CL_SUCCESS) {
+ detail::errHandler(error_local, __LINK_PROGRAM_ERR);
+ }
+ }
+ cl_program prog = ::clLinkProgram(
+ ctx(),
+ 0,
+ NULL,
+ options,
+ (cl_uint)inputPrograms.size(),
+ programs,
+ notifyFptr,
+ data,
+ &error_local);
+
+ detail::errHandler(error_local,__COMPILE_PROGRAM_ERR);
+ if (err != NULL) {
+ *err = error_local;
+ }
+
+ return Program(prog);
+}
+#endif
+
+template<>
+inline VECTOR_CLASS<char *> cl::Program::getInfo<CL_PROGRAM_BINARIES>(cl_int* err) const
+{
+ VECTOR_CLASS< ::size_t> sizes = getInfo<CL_PROGRAM_BINARY_SIZES>();
+ VECTOR_CLASS<char *> binaries;
+ for (VECTOR_CLASS< ::size_t>::iterator s = sizes.begin(); s != sizes.end(); ++s)
+ {
+ char *ptr = NULL;
+ if (*s != 0)
+ ptr = new char[*s];
+ binaries.push_back(ptr);
+ }
+
+ cl_int result = getInfo(CL_PROGRAM_BINARIES, &binaries);
+ if (err != NULL) {
+ *err = result;
+ }
+ return binaries;
+}
+
+inline Kernel::Kernel(const Program& program, const char* name, cl_int* err)
+{
+ cl_int error;
+
+ object_ = ::clCreateKernel(program(), name, &error);
+ detail::errHandler(error, __CREATE_KERNEL_ERR);
+
+ if (err != NULL) {
+ *err = error;
+ }
+
+}
+
+/*! \class CommandQueue
+ * \brief CommandQueue interface for cl_command_queue.
+ */
+class CommandQueue : public detail::Wrapper<cl_command_queue>
+{
+private:
+#ifdef CL_HPP_CPP11_ATOMICS_SUPPORTED
+ static std::atomic<int> default_initialized_;
+#else // !CL_HPP_CPP11_ATOMICS_SUPPORTED
+ static volatile int default_initialized_;
+#endif // !CL_HPP_CPP11_ATOMICS_SUPPORTED
+ static CommandQueue default_;
+ static volatile cl_int default_error_;
+public:
+ CommandQueue(
+ cl_command_queue_properties properties,
+ cl_int* err = NULL)
+ {
+ cl_int error;
+
+ Context context = Context::getDefault(&error);
+ detail::errHandler(error, __CREATE_CONTEXT_ERR);
+
+ if (error != CL_SUCCESS) {
+ if (err != NULL) {
+ *err = error;
+ }
+ }
+ else {
+ Device device = context.getInfo<CL_CONTEXT_DEVICES>()[0];
+
+ object_ = ::clCreateCommandQueue(
+ context(), device(), properties, &error);
+
+ detail::errHandler(error, __CREATE_COMMAND_QUEUE_ERR);
+ if (err != NULL) {
+ *err = error;
+ }
+ }
+ }
+ /*!
+ * \brief Constructs a CommandQueue for an implementation defined device in the given context
+ */
+ explicit CommandQueue(
+ const Context& context,
+ cl_command_queue_properties properties = 0,
+ cl_int* err = NULL)
+ {
+ cl_int error;
+ VECTOR_CLASS<cl::Device> devices;
+ error = context.getInfo(CL_CONTEXT_DEVICES, &devices);
+
+ detail::errHandler(error, __CREATE_CONTEXT_ERR);
+
+ if (error != CL_SUCCESS)
+ {
+ if (err != NULL) {
+ *err = error;
+ }
+ return;
+ }
+
+ object_ = ::clCreateCommandQueue(context(), devices[0](), properties, &error);
+
+ detail::errHandler(error, __CREATE_COMMAND_QUEUE_ERR);
+
+ if (err != NULL) {
+ *err = error;
+ }
+
+ }
+
+ CommandQueue(
+ const Context& context,
+ const Device& device,
+ cl_command_queue_properties properties = 0,
+ cl_int* err = NULL)
+ {
+ cl_int error;
+ object_ = ::clCreateCommandQueue(
+ context(), device(), properties, &error);
+
+ detail::errHandler(error, __CREATE_COMMAND_QUEUE_ERR);
+ if (err != NULL) {
+ *err = error;
+ }
+ }
+
+ /*! \brief Copy constructor to forward copy to the superclass correctly.
+ * Required for MSVC.
+ */
+ CommandQueue(const CommandQueue& queue) : detail::Wrapper<cl_type>(queue) {}
+
+ /*! \brief Copy assignment to forward copy to the superclass correctly.
+ * Required for MSVC.
+ */
+ CommandQueue& operator = (const CommandQueue &queue)
+ {
+ detail::Wrapper<cl_type>::operator=(queue);
+ return *this;
+ }
+
+#if defined(CL_HPP_RVALUE_REFERENCES_SUPPORTED)
+ /*! \brief Move constructor to forward move to the superclass correctly.
+ * Required for MSVC.
+ */
+ CommandQueue(CommandQueue&& queue) CL_HPP_NOEXCEPT : detail::Wrapper<cl_type>(std::move(queue)) {}
+
+ /*! \brief Move assignment to forward move to the superclass correctly.
+ * Required for MSVC.
+ */
+ CommandQueue& operator = (CommandQueue &&queue)
+ {
+ detail::Wrapper<cl_type>::operator=(std::move(queue));
+ return *this;
+ }
+#endif // #if defined(CL_HPP_RVALUE_REFERENCES_SUPPORTED)
+
+ static CommandQueue getDefault(cl_int * err = NULL)
+ {
+ int state = detail::compare_exchange(
+ &default_initialized_,
+ __DEFAULT_BEING_INITIALIZED, __DEFAULT_NOT_INITIALIZED);
+
+ if (state & __DEFAULT_INITIALIZED) {
+ if (err != NULL) {
+ *err = default_error_;
+ }
+ return default_;
+ }
+
+ if (state & __DEFAULT_BEING_INITIALIZED) {
+ // Assume writes will propagate eventually...
+ while(default_initialized_ != __DEFAULT_INITIALIZED) {
+ detail::fence();
+ }
+
+ if (err != NULL) {
+ *err = default_error_;
+ }
+ return default_;
+ }
+
+ cl_int error;
+
+ Context context = Context::getDefault(&error);
+ detail::errHandler(error, __CREATE_COMMAND_QUEUE_ERR);
+
+ if (error != CL_SUCCESS) {
+ if (err != NULL) {
+ *err = error;
+ }
+ }
+ else {
+ Device device = context.getInfo<CL_CONTEXT_DEVICES>()[0];
+
+ default_ = CommandQueue(context, device, 0, &error);
+
+ detail::errHandler(error, __CREATE_COMMAND_QUEUE_ERR);
+ if (err != NULL) {
+ *err = error;
+ }
+ }
+
+ detail::fence();
+
+ default_error_ = error;
+ // Assume writes will propagate eventually...
+ default_initialized_ = __DEFAULT_INITIALIZED;
+
+ detail::fence();
+
+ if (err != NULL) {
+ *err = default_error_;
+ }
+ return default_;
+
+ }
+
+ CommandQueue() { }
+
+ __CL_EXPLICIT_CONSTRUCTORS CommandQueue(const cl_command_queue& commandQueue) : detail::Wrapper<cl_type>(commandQueue) { }
+
+ CommandQueue& operator = (const cl_command_queue& rhs)
+ {
+ detail::Wrapper<cl_type>::operator=(rhs);
+ return *this;
+ }
+
+ template <typename T>
+ cl_int getInfo(cl_command_queue_info name, T* param) const
+ {
+ return detail::errHandler(
+ detail::getInfo(
+ &::clGetCommandQueueInfo, object_, name, param),
+ __GET_COMMAND_QUEUE_INFO_ERR);
+ }
+
+ template <cl_int name> typename
+ detail::param_traits<detail::cl_command_queue_info, name>::param_type
+ getInfo(cl_int* err = NULL) const
+ {
+ typename detail::param_traits<
+ detail::cl_command_queue_info, name>::param_type param;
+ cl_int result = getInfo(name, &param);
+ if (err != NULL) {
+ *err = result;
+ }
+ return param;
+ }
+
+ cl_int enqueueReadBuffer(
+ const Buffer& buffer,
+ cl_bool blocking,
+ ::size_t offset,
+ ::size_t size,
+ void* ptr,
+ const VECTOR_CLASS<Event>* events = NULL,
+ Event* event = NULL) const
+ {
+ cl_event tmp;
+ cl_int err = detail::errHandler(
+ ::clEnqueueReadBuffer(
+ object_, buffer(), blocking, offset, size,
+ ptr,
+ (events != NULL) ? (cl_uint) events->size() : 0,
+ (events != NULL && events->size() > 0) ? (cl_event*) &events->front() : NULL,
+ (event != NULL) ? &tmp : NULL),
+ __ENQUEUE_READ_BUFFER_ERR);
+
+ if (event != NULL && err == CL_SUCCESS)
+ *event = tmp;
+
+ return err;
+ }
+
+ cl_int enqueueWriteBuffer(
+ const Buffer& buffer,
+ cl_bool blocking,
+ ::size_t offset,
+ ::size_t size,
+ const void* ptr,
+ const VECTOR_CLASS<Event>* events = NULL,
+ Event* event = NULL) const
+ {
+ cl_event tmp;
+ cl_int err = detail::errHandler(
+ ::clEnqueueWriteBuffer(
+ object_, buffer(), blocking, offset, size,
+ ptr,
+ (events != NULL) ? (cl_uint) events->size() : 0,
+ (events != NULL && events->size() > 0) ? (cl_event*) &events->front() : NULL,
+ (event != NULL) ? &tmp : NULL),
+ __ENQUEUE_WRITE_BUFFER_ERR);
+
+ if (event != NULL && err == CL_SUCCESS)
+ *event = tmp;
+
+ return err;
+ }
+
+ cl_int enqueueCopyBuffer(
+ const Buffer& src,
+ const Buffer& dst,
+ ::size_t src_offset,
+ ::size_t dst_offset,
+ ::size_t size,
+ const VECTOR_CLASS<Event>* events = NULL,
+ Event* event = NULL) const
+ {
+ cl_event tmp;
+ cl_int err = detail::errHandler(
+ ::clEnqueueCopyBuffer(
+ object_, src(), dst(), src_offset, dst_offset, size,
+ (events != NULL) ? (cl_uint) events->size() : 0,
+ (events != NULL && events->size() > 0) ? (cl_event*) &events->front() : NULL,
+ (event != NULL) ? &tmp : NULL),
+ __ENQEUE_COPY_BUFFER_ERR);
+
+ if (event != NULL && err == CL_SUCCESS)
+ *event = tmp;
+
+ return err;
+ }
+
+ cl_int enqueueReadBufferRect(
+ const Buffer& buffer,
+ cl_bool blocking,
+ const size_t<3>& buffer_offset,
+ const size_t<3>& host_offset,
+ const size_t<3>& region,
+ ::size_t buffer_row_pitch,
+ ::size_t buffer_slice_pitch,
+ ::size_t host_row_pitch,
+ ::size_t host_slice_pitch,
+ void *ptr,
+ const VECTOR_CLASS<Event>* events = NULL,
+ Event* event = NULL) const
+ {
+ cl_event tmp;
+ cl_int err = detail::errHandler(
+ ::clEnqueueReadBufferRect(
+ object_,
+ buffer(),
+ blocking,
+ (const ::size_t *)buffer_offset,
+ (const ::size_t *)host_offset,
+ (const ::size_t *)region,
+ buffer_row_pitch,
+ buffer_slice_pitch,
+ host_row_pitch,
+ host_slice_pitch,
+ ptr,
+ (events != NULL) ? (cl_uint) events->size() : 0,
+ (events != NULL && events->size() > 0) ? (cl_event*) &events->front() : NULL,
+ (event != NULL) ? &tmp : NULL),
+ __ENQUEUE_READ_BUFFER_RECT_ERR);
+
+ if (event != NULL && err == CL_SUCCESS)
+ *event = tmp;
+
+ return err;
+ }
+
+ cl_int enqueueWriteBufferRect(
+ const Buffer& buffer,
+ cl_bool blocking,
+ const size_t<3>& buffer_offset,
+ const size_t<3>& host_offset,
+ const size_t<3>& region,
+ ::size_t buffer_row_pitch,
+ ::size_t buffer_slice_pitch,
+ ::size_t host_row_pitch,
+ ::size_t host_slice_pitch,
+ void *ptr,
+ const VECTOR_CLASS<Event>* events = NULL,
+ Event* event = NULL) const
+ {
+ cl_event tmp;
+ cl_int err = detail::errHandler(
+ ::clEnqueueWriteBufferRect(
+ object_,
+ buffer(),
+ blocking,
+ (const ::size_t *)buffer_offset,
+ (const ::size_t *)host_offset,
+ (const ::size_t *)region,
+ buffer_row_pitch,
+ buffer_slice_pitch,
+ host_row_pitch,
+ host_slice_pitch,
+ ptr,
+ (events != NULL) ? (cl_uint) events->size() : 0,
+ (events != NULL && events->size() > 0) ? (cl_event*) &events->front() : NULL,
+ (event != NULL) ? &tmp : NULL),
+ __ENQUEUE_WRITE_BUFFER_RECT_ERR);
+
+ if (event != NULL && err == CL_SUCCESS)
+ *event = tmp;
+
+ return err;
+ }
+
+ cl_int enqueueCopyBufferRect(
+ const Buffer& src,
+ const Buffer& dst,
+ const size_t<3>& src_origin,
+ const size_t<3>& dst_origin,
+ const size_t<3>& region,
+ ::size_t src_row_pitch,
+ ::size_t src_slice_pitch,
+ ::size_t dst_row_pitch,
+ ::size_t dst_slice_pitch,
+ const VECTOR_CLASS<Event>* events = NULL,
+ Event* event = NULL) const
+ {
+ cl_event tmp;
+ cl_int err = detail::errHandler(
+ ::clEnqueueCopyBufferRect(
+ object_,
+ src(),
+ dst(),
+ (const ::size_t *)src_origin,
+ (const ::size_t *)dst_origin,
+ (const ::size_t *)region,
+ src_row_pitch,
+ src_slice_pitch,
+ dst_row_pitch,
+ dst_slice_pitch,
+ (events != NULL) ? (cl_uint) events->size() : 0,
+ (events != NULL && events->size() > 0) ? (cl_event*) &events->front() : NULL,
+ (event != NULL) ? &tmp : NULL),
+ __ENQEUE_COPY_BUFFER_RECT_ERR);
+
+ if (event != NULL && err == CL_SUCCESS)
+ *event = tmp;
+
+ return err;
+ }
+
+#if defined(CL_VERSION_1_2)
+ /**
+ * Enqueue a command to fill a buffer object with a pattern
+ * of a given size. The pattern is specified a as vector.
+ * \tparam PatternType The datatype of the pattern field.
+ * The pattern type must be an accepted OpenCL data type.
+ */
+ template<typename PatternType>
+ cl_int enqueueFillBuffer(
+ const Buffer& buffer,
+ PatternType pattern,
+ ::size_t offset,
+ ::size_t size,
+ const VECTOR_CLASS<Event>* events = NULL,
+ Event* event = NULL) const
+ {
+ cl_event tmp;
+ cl_int err = detail::errHandler(
+ ::clEnqueueFillBuffer(
+ object_,
+ buffer(),
+ static_cast<void*>(&pattern),
+ sizeof(PatternType),
+ offset,
+ size,
+ (events != NULL) ? (cl_uint) events->size() : 0,
+ (events != NULL && events->size() > 0) ? (cl_event*) &events->front() : NULL,
+ (event != NULL) ? &tmp : NULL),
+ __ENQUEUE_FILL_BUFFER_ERR);
+
+ if (event != NULL && err == CL_SUCCESS)
+ *event = tmp;
+
+ return err;
+ }
+#endif // #if defined(CL_VERSION_1_2)
+
+ cl_int enqueueReadImage(
+ const Image& image,
+ cl_bool blocking,
+ const size_t<3>& origin,
+ const size_t<3>& region,
+ ::size_t row_pitch,
+ ::size_t slice_pitch,
+ void* ptr,
+ const VECTOR_CLASS<Event>* events = NULL,
+ Event* event = NULL) const
+ {
+ cl_event tmp;
+ cl_int err = detail::errHandler(
+ ::clEnqueueReadImage(
+ object_, image(), blocking, (const ::size_t *) origin,
+ (const ::size_t *) region, row_pitch, slice_pitch, ptr,
+ (events != NULL) ? (cl_uint) events->size() : 0,
+ (events != NULL && events->size() > 0) ? (cl_event*) &events->front() : NULL,
+ (event != NULL) ? &tmp : NULL),
+ __ENQUEUE_READ_IMAGE_ERR);
+
+ if (event != NULL && err == CL_SUCCESS)
+ *event = tmp;
+
+ return err;
+ }
+
+ cl_int enqueueWriteImage(
+ const Image& image,
+ cl_bool blocking,
+ const size_t<3>& origin,
+ const size_t<3>& region,
+ ::size_t row_pitch,
+ ::size_t slice_pitch,
+ void* ptr,
+ const VECTOR_CLASS<Event>* events = NULL,
+ Event* event = NULL) const
+ {
+ cl_event tmp;
+ cl_int err = detail::errHandler(
+ ::clEnqueueWriteImage(
+ object_, image(), blocking, (const ::size_t *) origin,
+ (const ::size_t *) region, row_pitch, slice_pitch, ptr,
+ (events != NULL) ? (cl_uint) events->size() : 0,
+ (events != NULL && events->size() > 0) ? (cl_event*) &events->front() : NULL,
+ (event != NULL) ? &tmp : NULL),
+ __ENQUEUE_WRITE_IMAGE_ERR);
+
+ if (event != NULL && err == CL_SUCCESS)
+ *event = tmp;
+
+ return err;
+ }
+
+ cl_int enqueueCopyImage(
+ const Image& src,
+ const Image& dst,
+ const size_t<3>& src_origin,
+ const size_t<3>& dst_origin,
+ const size_t<3>& region,
+ const VECTOR_CLASS<Event>* events = NULL,
+ Event* event = NULL) const
+ {
+ cl_event tmp;
+ cl_int err = detail::errHandler(
+ ::clEnqueueCopyImage(
+ object_, src(), dst(), (const ::size_t *) src_origin,
+ (const ::size_t *)dst_origin, (const ::size_t *) region,
+ (events != NULL) ? (cl_uint) events->size() : 0,
+ (events != NULL && events->size() > 0) ? (cl_event*) &events->front() : NULL,
+ (event != NULL) ? &tmp : NULL),
+ __ENQUEUE_COPY_IMAGE_ERR);
+
+ if (event != NULL && err == CL_SUCCESS)
+ *event = tmp;
+
+ return err;
+ }
+
+#if defined(CL_VERSION_1_2)
+ /**
+ * Enqueue a command to fill an image object with a specified color.
+ * \param fillColor is the color to use to fill the image.
+ * This is a four component RGBA floating-point color value if
+ * the image channel data type is not an unnormalized signed or
+ * unsigned data type.
+ */
+ cl_int enqueueFillImage(
+ const Image& image,
+ cl_float4 fillColor,
+ const size_t<3>& origin,
+ const size_t<3>& region,
+ const VECTOR_CLASS<Event>* events = NULL,
+ Event* event = NULL) const
+ {
+ cl_event tmp;
+ cl_int err = detail::errHandler(
+ ::clEnqueueFillImage(
+ object_,
+ image(),
+ static_cast<void*>(&fillColor),
+ (const ::size_t *) origin,
+ (const ::size_t *) region,
+ (events != NULL) ? (cl_uint) events->size() : 0,
+ (events != NULL && events->size() > 0) ? (cl_event*) &events->front() : NULL,
+ (event != NULL) ? &tmp : NULL),
+ __ENQUEUE_FILL_IMAGE_ERR);
+
+ if (event != NULL && err == CL_SUCCESS)
+ *event = tmp;
+
+ return err;
+ }
+
+ /**
+ * Enqueue a command to fill an image object with a specified color.
+ * \param fillColor is the color to use to fill the image.
+ * This is a four component RGBA signed integer color value if
+ * the image channel data type is an unnormalized signed integer
+ * type.
+ */
+ cl_int enqueueFillImage(
+ const Image& image,
+ cl_int4 fillColor,
+ const size_t<3>& origin,
+ const size_t<3>& region,
+ const VECTOR_CLASS<Event>* events = NULL,
+ Event* event = NULL) const
+ {
+ cl_event tmp;
+ cl_int err = detail::errHandler(
+ ::clEnqueueFillImage(
+ object_,
+ image(),
+ static_cast<void*>(&fillColor),
+ (const ::size_t *) origin,
+ (const ::size_t *) region,
+ (events != NULL) ? (cl_uint) events->size() : 0,
+ (events != NULL && events->size() > 0) ? (cl_event*) &events->front() : NULL,
+ (event != NULL) ? &tmp : NULL),
+ __ENQUEUE_FILL_IMAGE_ERR);
+
+ if (event != NULL && err == CL_SUCCESS)
+ *event = tmp;
+
+ return err;
+ }
+
+ /**
+ * Enqueue a command to fill an image object with a specified color.
+ * \param fillColor is the color to use to fill the image.
+ * This is a four component RGBA unsigned integer color value if
+ * the image channel data type is an unnormalized unsigned integer
+ * type.
+ */
+ cl_int enqueueFillImage(
+ const Image& image,
+ cl_uint4 fillColor,
+ const size_t<3>& origin,
+ const size_t<3>& region,
+ const VECTOR_CLASS<Event>* events = NULL,
+ Event* event = NULL) const
+ {
+ cl_event tmp;
+ cl_int err = detail::errHandler(
+ ::clEnqueueFillImage(
+ object_,
+ image(),
+ static_cast<void*>(&fillColor),
+ (const ::size_t *) origin,
+ (const ::size_t *) region,
+ (events != NULL) ? (cl_uint) events->size() : 0,
+ (events != NULL && events->size() > 0) ? (cl_event*) &events->front() : NULL,
+ (event != NULL) ? &tmp : NULL),
+ __ENQUEUE_FILL_IMAGE_ERR);
+
+ if (event != NULL && err == CL_SUCCESS)
+ *event = tmp;
+
+ return err;
+ }
+#endif // #if defined(CL_VERSION_1_2)
+
+ cl_int enqueueCopyImageToBuffer(
+ const Image& src,
+ const Buffer& dst,
+ const size_t<3>& src_origin,
+ const size_t<3>& region,
+ ::size_t dst_offset,
+ const VECTOR_CLASS<Event>* events = NULL,
+ Event* event = NULL) const
+ {
+ cl_event tmp;
+ cl_int err = detail::errHandler(
+ ::clEnqueueCopyImageToBuffer(
+ object_, src(), dst(), (const ::size_t *) src_origin,
+ (const ::size_t *) region, dst_offset,
+ (events != NULL) ? (cl_uint) events->size() : 0,
+ (events != NULL && events->size() > 0) ? (cl_event*) &events->front() : NULL,
+ (event != NULL) ? &tmp : NULL),
+ __ENQUEUE_COPY_IMAGE_TO_BUFFER_ERR);
+
+ if (event != NULL && err == CL_SUCCESS)
+ *event = tmp;
+
+ return err;
+ }
+
+ cl_int enqueueCopyBufferToImage(
+ const Buffer& src,
+ const Image& dst,
+ ::size_t src_offset,
+ const size_t<3>& dst_origin,
+ const size_t<3>& region,
+ const VECTOR_CLASS<Event>* events = NULL,
+ Event* event = NULL) const
+ {
+ cl_event tmp;
+ cl_int err = detail::errHandler(
+ ::clEnqueueCopyBufferToImage(
+ object_, src(), dst(), src_offset,
+ (const ::size_t *) dst_origin, (const ::size_t *) region,
+ (events != NULL) ? (cl_uint) events->size() : 0,
+ (events != NULL && events->size() > 0) ? (cl_event*) &events->front() : NULL,
+ (event != NULL) ? &tmp : NULL),
+ __ENQUEUE_COPY_BUFFER_TO_IMAGE_ERR);
+
+ if (event != NULL && err == CL_SUCCESS)
+ *event = tmp;
+
+ return err;
+ }
+
+ void* enqueueMapBuffer(
+ const Buffer& buffer,
+ cl_bool blocking,
+ cl_map_flags flags,
+ ::size_t offset,
+ ::size_t size,
+ const VECTOR_CLASS<Event>* events = NULL,
+ Event* event = NULL,
+ cl_int* err = NULL) const
+ {
+ cl_event tmp;
+ cl_int error;
+ void * result = ::clEnqueueMapBuffer(
+ object_, buffer(), blocking, flags, offset, size,
+ (events != NULL) ? (cl_uint) events->size() : 0,
+ (events != NULL && events->size() > 0) ? (cl_event*) &events->front() : NULL,
+ (event != NULL) ? &tmp : NULL,
+ &error);
+
+ detail::errHandler(error, __ENQUEUE_MAP_BUFFER_ERR);
+ if (err != NULL) {
+ *err = error;
+ }
+ if (event != NULL && error == CL_SUCCESS)
+ *event = tmp;
+
+ return result;
+ }
+
+ void* enqueueMapImage(
+ const Image& buffer,
+ cl_bool blocking,
+ cl_map_flags flags,
+ const size_t<3>& origin,
+ const size_t<3>& region,
+ ::size_t * row_pitch,
+ ::size_t * slice_pitch,
+ const VECTOR_CLASS<Event>* events = NULL,
+ Event* event = NULL,
+ cl_int* err = NULL) const
+ {
+ cl_event tmp;
+ cl_int error;
+ void * result = ::clEnqueueMapImage(
+ object_, buffer(), blocking, flags,
+ (const ::size_t *) origin, (const ::size_t *) region,
+ row_pitch, slice_pitch,
+ (events != NULL) ? (cl_uint) events->size() : 0,
+ (events != NULL && events->size() > 0) ? (cl_event*) &events->front() : NULL,
+ (event != NULL) ? &tmp : NULL,
+ &error);
+
+ detail::errHandler(error, __ENQUEUE_MAP_IMAGE_ERR);
+ if (err != NULL) {
+ *err = error;
+ }
+ if (event != NULL && error == CL_SUCCESS)
+ *event = tmp;
+ return result;
+ }
+
+ cl_int enqueueUnmapMemObject(
+ const Memory& memory,
+ void* mapped_ptr,
+ const VECTOR_CLASS<Event>* events = NULL,
+ Event* event = NULL) const
+ {
+ cl_event tmp;
+ cl_int err = detail::errHandler(
+ ::clEnqueueUnmapMemObject(
+ object_, memory(), mapped_ptr,
+ (events != NULL) ? (cl_uint) events->size() : 0,
+ (events != NULL && events->size() > 0) ? (cl_event*) &events->front() : NULL,
+ (event != NULL) ? &tmp : NULL),
+ __ENQUEUE_UNMAP_MEM_OBJECT_ERR);
+
+ if (event != NULL && err == CL_SUCCESS)
+ *event = tmp;
+
+ return err;
+ }
+
+#if defined(CL_VERSION_1_2)
+ /**
+ * Enqueues a marker command which waits for either a list of events to complete,
+ * or all previously enqueued commands to complete.
+ *
+ * Enqueues a marker command which waits for either a list of events to complete,
+ * or if the list is empty it waits for all commands previously enqueued in command_queue
+ * to complete before it completes. This command returns an event which can be waited on,
+ * i.e. this event can be waited on to insure that all events either in the event_wait_list
+ * or all previously enqueued commands, queued before this command to command_queue,
+ * have completed.
+ */
+ cl_int enqueueMarkerWithWaitList(
+ const VECTOR_CLASS<Event> *events = 0,
+ Event *event = 0)
+ {
+ cl_event tmp;
+ cl_int err = detail::errHandler(
+ ::clEnqueueMarkerWithWaitList(
+ object_,
+ (events != NULL) ? (cl_uint) events->size() : 0,
+ (events != NULL && events->size() > 0) ? (cl_event*) &events->front() : NULL,
+ (event != NULL) ? &tmp : NULL),
+ __ENQUEUE_MARKER_WAIT_LIST_ERR);
+
+ if (event != NULL && err == CL_SUCCESS)
+ *event = tmp;
+
+ return err;
+ }
+
+ /**
+ * A synchronization point that enqueues a barrier operation.
+ *
+ * Enqueues a barrier command which waits for either a list of events to complete,
+ * or if the list is empty it waits for all commands previously enqueued in command_queue
+ * to complete before it completes. This command blocks command execution, that is, any
+ * following commands enqueued after it do not execute until it completes. This command
+ * returns an event which can be waited on, i.e. this event can be waited on to insure that
+ * all events either in the event_wait_list or all previously enqueued commands, queued
+ * before this command to command_queue, have completed.
+ */
+ cl_int enqueueBarrierWithWaitList(
+ const VECTOR_CLASS<Event> *events = 0,
+ Event *event = 0)
+ {
+ cl_event tmp;
+ cl_int err = detail::errHandler(
+ ::clEnqueueBarrierWithWaitList(
+ object_,
+ (events != NULL) ? (cl_uint) events->size() : 0,
+ (events != NULL && events->size() > 0) ? (cl_event*) &events->front() : NULL,
+ (event != NULL) ? &tmp : NULL),
+ __ENQUEUE_BARRIER_WAIT_LIST_ERR);
+
+ if (event != NULL && err == CL_SUCCESS)
+ *event = tmp;
+
+ return err;
+ }
+
+ /**
+ * Enqueues a command to indicate with which device a set of memory objects
+ * should be associated.
+ */
+ cl_int enqueueMigrateMemObjects(
+ const VECTOR_CLASS<Memory> &memObjects,
+ cl_mem_migration_flags flags,
+ const VECTOR_CLASS<Event>* events = NULL,
+ Event* event = NULL
+ )
+ {
+ cl_event tmp;
+
+ cl_mem* localMemObjects = static_cast<cl_mem*>(alloca(memObjects.size() * sizeof(cl_mem)));
+ for( int i = 0; i < (int)memObjects.size(); ++i ) {
+ localMemObjects[i] = memObjects[i]();
+ }
+
+
+ cl_int err = detail::errHandler(
+ ::clEnqueueMigrateMemObjects(
+ object_,
+ (cl_uint)memObjects.size(),
+ static_cast<const cl_mem*>(localMemObjects),
+ flags,
+ (events != NULL) ? (cl_uint) events->size() : 0,
+ (events != NULL && events->size() > 0) ? (cl_event*) &events->front() : NULL,
+ (event != NULL) ? &tmp : NULL),
+ __ENQUEUE_UNMAP_MEM_OBJECT_ERR);
+
+ if (event != NULL && err == CL_SUCCESS)
+ *event = tmp;
+
+ return err;
+ }
+#endif // #if defined(CL_VERSION_1_2)
+
+ cl_int enqueueNDRangeKernel(
+ const Kernel& kernel,
+ const NDRange& offset,
+ const NDRange& global,
+ const NDRange& local = NullRange,
+ const VECTOR_CLASS<Event>* events = NULL,
+ Event* event = NULL) const
+ {
+ cl_event tmp;
+ cl_int err = detail::errHandler(
+ ::clEnqueueNDRangeKernel(
+ object_, kernel(), (cl_uint) global.dimensions(),
+ offset.dimensions() != 0 ? (const ::size_t*) offset : NULL,
+ (const ::size_t*) global,
+ local.dimensions() != 0 ? (const ::size_t*) local : NULL,
+ (events != NULL) ? (cl_uint) events->size() : 0,
+ (events != NULL && events->size() > 0) ? (cl_event*) &events->front() : NULL,
+ (event != NULL) ? &tmp : NULL),
+ __ENQUEUE_NDRANGE_KERNEL_ERR);
+
+ if (event != NULL && err == CL_SUCCESS)
+ *event = tmp;
+
+ return err;
+ }
+
+ cl_int enqueueTask(
+ const Kernel& kernel,
+ const VECTOR_CLASS<Event>* events = NULL,
+ Event* event = NULL) const
+ {
+ cl_event tmp;
+ cl_int err = detail::errHandler(
+ ::clEnqueueTask(
+ object_, kernel(),
+ (events != NULL) ? (cl_uint) events->size() : 0,
+ (events != NULL && events->size() > 0) ? (cl_event*) &events->front() : NULL,
+ (event != NULL) ? &tmp : NULL),
+ __ENQUEUE_TASK_ERR);
+
+ if (event != NULL && err == CL_SUCCESS)
+ *event = tmp;
+
+ return err;
+ }
+
+ cl_int enqueueNativeKernel(
+ void (CL_CALLBACK *userFptr)(void *),
+ std::pair<void*, ::size_t> args,
+ const VECTOR_CLASS<Memory>* mem_objects = NULL,
+ const VECTOR_CLASS<const void*>* mem_locs = NULL,
+ const VECTOR_CLASS<Event>* events = NULL,
+ Event* event = NULL) const
+ {
+ cl_mem * mems = (mem_objects != NULL && mem_objects->size() > 0)
+ ? (cl_mem*) alloca(mem_objects->size() * sizeof(cl_mem))
+ : NULL;
+
+ if (mems != NULL) {
+ for (unsigned int i = 0; i < mem_objects->size(); i++) {
+ mems[i] = ((*mem_objects)[i])();
+ }
+ }
+
+ cl_event tmp;
+ cl_int err = detail::errHandler(
+ ::clEnqueueNativeKernel(
+ object_, userFptr, args.first, args.second,
+ (mem_objects != NULL) ? (cl_uint) mem_objects->size() : 0,
+ mems,
+ (mem_locs != NULL && mem_locs->size() > 0) ? (const void **) &mem_locs->front() : NULL,
+ (events != NULL) ? (cl_uint) events->size() : 0,
+ (events != NULL && events->size() > 0) ? (cl_event*) &events->front() : NULL,
+ (event != NULL) ? &tmp : NULL),
+ __ENQUEUE_NATIVE_KERNEL);
+
+ if (event != NULL && err == CL_SUCCESS)
+ *event = tmp;
+
+ return err;
+ }
+
+/**
+ * Deprecated APIs for 1.2
+ */
+#if defined(CL_USE_DEPRECATED_OPENCL_1_1_APIS) || (defined(CL_VERSION_1_1) && !defined(CL_VERSION_1_2))
+ CL_EXT_PREFIX__VERSION_1_1_DEPRECATED
+ cl_int enqueueMarker(Event* event = NULL) const CL_EXT_SUFFIX__VERSION_1_1_DEPRECATED
+ {
+ cl_event tmp;
+ cl_int err = detail::errHandler(
+ ::clEnqueueMarker(
+ object_,
+ (event != NULL) ? &tmp : NULL),
+ __ENQUEUE_MARKER_ERR);
+
+ if (event != NULL && err == CL_SUCCESS)
+ *event = tmp;
+
+ return err;
+ }
+
+ CL_EXT_PREFIX__VERSION_1_1_DEPRECATED
+ cl_int enqueueWaitForEvents(const VECTOR_CLASS<Event>& events) const CL_EXT_SUFFIX__VERSION_1_1_DEPRECATED
+ {
+ return detail::errHandler(
+ ::clEnqueueWaitForEvents(
+ object_,
+ (cl_uint) events.size(),
+ events.size() > 0 ? (const cl_event*) &events.front() : NULL),
+ __ENQUEUE_WAIT_FOR_EVENTS_ERR);
+ }
+#endif // #if defined(CL_VERSION_1_1)
+
+ cl_int enqueueAcquireGLObjects(
+ const VECTOR_CLASS<Memory>* mem_objects = NULL,
+ const VECTOR_CLASS<Event>* events = NULL,
+ Event* event = NULL) const
+ {
+ cl_event tmp;
+ cl_int err = detail::errHandler(
+ ::clEnqueueAcquireGLObjects(
+ object_,
+ (mem_objects != NULL) ? (cl_uint) mem_objects->size() : 0,
+ (mem_objects != NULL && mem_objects->size() > 0) ? (const cl_mem *) &mem_objects->front(): NULL,
+ (events != NULL) ? (cl_uint) events->size() : 0,
+ (events != NULL && events->size() > 0) ? (cl_event*) &events->front() : NULL,
+ (event != NULL) ? &tmp : NULL),
+ __ENQUEUE_ACQUIRE_GL_ERR);
+
+ if (event != NULL && err == CL_SUCCESS)
+ *event = tmp;
+
+ return err;
+ }
+
+ cl_int enqueueReleaseGLObjects(
+ const VECTOR_CLASS<Memory>* mem_objects = NULL,
+ const VECTOR_CLASS<Event>* events = NULL,
+ Event* event = NULL) const
+ {
+ cl_event tmp;
+ cl_int err = detail::errHandler(
+ ::clEnqueueReleaseGLObjects(
+ object_,
+ (mem_objects != NULL) ? (cl_uint) mem_objects->size() : 0,
+ (mem_objects != NULL && mem_objects->size() > 0) ? (const cl_mem *) &mem_objects->front(): NULL,
+ (events != NULL) ? (cl_uint) events->size() : 0,
+ (events != NULL && events->size() > 0) ? (cl_event*) &events->front() : NULL,
+ (event != NULL) ? &tmp : NULL),
+ __ENQUEUE_RELEASE_GL_ERR);
+
+ if (event != NULL && err == CL_SUCCESS)
+ *event = tmp;
+
+ return err;
+ }
+
+#if defined (USE_DX_INTEROP)
+typedef CL_API_ENTRY cl_int (CL_API_CALL *PFN_clEnqueueAcquireD3D10ObjectsKHR)(
+ cl_command_queue command_queue, cl_uint num_objects,
+ const cl_mem* mem_objects, cl_uint num_events_in_wait_list,
+ const cl_event* event_wait_list, cl_event* event);
+typedef CL_API_ENTRY cl_int (CL_API_CALL *PFN_clEnqueueReleaseD3D10ObjectsKHR)(
+ cl_command_queue command_queue, cl_uint num_objects,
+ const cl_mem* mem_objects, cl_uint num_events_in_wait_list,
+ const cl_event* event_wait_list, cl_event* event);
+
+ cl_int enqueueAcquireD3D10Objects(
+ const VECTOR_CLASS<Memory>* mem_objects = NULL,
+ const VECTOR_CLASS<Event>* events = NULL,
+ Event* event = NULL) const
+ {
+ static PFN_clEnqueueAcquireD3D10ObjectsKHR pfn_clEnqueueAcquireD3D10ObjectsKHR = NULL;
+#if defined(CL_VERSION_1_2)
+ cl_context context = getInfo<CL_QUEUE_CONTEXT>();
+ cl::Device device(getInfo<CL_QUEUE_DEVICE>());
+ cl_platform_id platform = device.getInfo<CL_DEVICE_PLATFORM>();
+ __INIT_CL_EXT_FCN_PTR_PLATFORM(platform, clEnqueueAcquireD3D10ObjectsKHR);
+#endif
+#if defined(CL_VERSION_1_1)
+ __INIT_CL_EXT_FCN_PTR(clEnqueueAcquireD3D10ObjectsKHR);
+#endif
+
+ cl_event tmp;
+ cl_int err = detail::errHandler(
+ pfn_clEnqueueAcquireD3D10ObjectsKHR(
+ object_,
+ (mem_objects != NULL) ? (cl_uint) mem_objects->size() : 0,
+ (mem_objects != NULL && mem_objects->size() > 0) ? (const cl_mem *) &mem_objects->front(): NULL,
+ (events != NULL) ? (cl_uint) events->size() : 0,
+ (events != NULL) ? (cl_event*) &events->front() : NULL,
+ (event != NULL) ? &tmp : NULL),
+ __ENQUEUE_ACQUIRE_GL_ERR);
+
+ if (event != NULL && err == CL_SUCCESS)
+ *event = tmp;
+
+ return err;
+ }
+
+ cl_int enqueueReleaseD3D10Objects(
+ const VECTOR_CLASS<Memory>* mem_objects = NULL,
+ const VECTOR_CLASS<Event>* events = NULL,
+ Event* event = NULL) const
+ {
+ static PFN_clEnqueueReleaseD3D10ObjectsKHR pfn_clEnqueueReleaseD3D10ObjectsKHR = NULL;
+#if defined(CL_VERSION_1_2)
+ cl_context context = getInfo<CL_QUEUE_CONTEXT>();
+ cl::Device device(getInfo<CL_QUEUE_DEVICE>());
+ cl_platform_id platform = device.getInfo<CL_DEVICE_PLATFORM>();
+ __INIT_CL_EXT_FCN_PTR_PLATFORM(platform, clEnqueueReleaseD3D10ObjectsKHR);
+#endif // #if defined(CL_VERSION_1_2)
+#if defined(CL_VERSION_1_1)
+ __INIT_CL_EXT_FCN_PTR(clEnqueueReleaseD3D10ObjectsKHR);
+#endif // #if defined(CL_VERSION_1_1)
+
+ cl_event tmp;
+ cl_int err = detail::errHandler(
+ pfn_clEnqueueReleaseD3D10ObjectsKHR(
+ object_,
+ (mem_objects != NULL) ? (cl_uint) mem_objects->size() : 0,
+ (mem_objects != NULL && mem_objects->size() > 0) ? (const cl_mem *) &mem_objects->front(): NULL,
+ (events != NULL) ? (cl_uint) events->size() : 0,
+ (events != NULL && events->size() > 0) ? (cl_event*) &events->front() : NULL,
+ (event != NULL) ? &tmp : NULL),
+ __ENQUEUE_RELEASE_GL_ERR);
+
+ if (event != NULL && err == CL_SUCCESS)
+ *event = tmp;
+
+ return err;
+ }
+#endif
+
+/**
+ * Deprecated APIs for 1.2
+ */
+#if defined(CL_USE_DEPRECATED_OPENCL_1_1_APIS) || (defined(CL_VERSION_1_1) && !defined(CL_VERSION_1_2))
+ CL_EXT_PREFIX__VERSION_1_1_DEPRECATED
+ cl_int enqueueBarrier() const CL_EXT_SUFFIX__VERSION_1_1_DEPRECATED
+ {
+ return detail::errHandler(
+ ::clEnqueueBarrier(object_),
+ __ENQUEUE_BARRIER_ERR);
+ }
+#endif // #if defined(CL_VERSION_1_1)
+
+ cl_int flush() const
+ {
+ return detail::errHandler(::clFlush(object_), __FLUSH_ERR);
+ }
+
+ cl_int finish() const
+ {
+ return detail::errHandler(::clFinish(object_), __FINISH_ERR);
+ }
+};
+
+#ifdef _WIN32
+#ifdef CL_HPP_CPP11_ATOMICS_SUPPORTED
+__declspec(selectany) std::atomic<int> CommandQueue::default_initialized_;
+#else // !CL_HPP_CPP11_ATOMICS_SUPPORTED
+__declspec(selectany) volatile int CommandQueue::default_initialized_ = __DEFAULT_NOT_INITIALIZED;
+#endif // !CL_HPP_CPP11_ATOMICS_SUPPORTED
+__declspec(selectany) CommandQueue CommandQueue::default_;
+__declspec(selectany) volatile cl_int CommandQueue::default_error_ = CL_SUCCESS;
+#else // !_WIN32
+#ifdef CL_HPP_CPP11_ATOMICS_SUPPORTED
+__attribute__((weak)) std::atomic<int> CommandQueue::default_initialized_;
+#else // !CL_HPP_CPP11_ATOMICS_SUPPORTED
+__attribute__((weak)) volatile int CommandQueue::default_initialized_ = __DEFAULT_NOT_INITIALIZED;
+#endif // !CL_HPP_CPP11_ATOMICS_SUPPORTED
+__attribute__((weak)) CommandQueue CommandQueue::default_;
+__attribute__((weak)) volatile cl_int CommandQueue::default_error_ = CL_SUCCESS;
+#endif // !_WIN32
+
+template< typename IteratorType >
+Buffer::Buffer(
+ const Context &context,
+ IteratorType startIterator,
+ IteratorType endIterator,
+ bool readOnly,
+ bool useHostPtr,
+ cl_int* err)
+{
+ typedef typename std::iterator_traits<IteratorType>::value_type DataType;
+ cl_int error;
+
+ cl_mem_flags flags = 0;
+ if( readOnly ) {
+ flags |= CL_MEM_READ_ONLY;
+ }
+ else {
+ flags |= CL_MEM_READ_WRITE;
+ }
+ if( useHostPtr ) {
+ flags |= CL_MEM_USE_HOST_PTR;
+ }
+
+ ::size_t size = sizeof(DataType)*(endIterator - startIterator);
+
+ if( useHostPtr ) {
+ object_ = ::clCreateBuffer(context(), flags, size, static_cast<DataType*>(&*startIterator), &error);
+ } else {
+ object_ = ::clCreateBuffer(context(), flags, size, 0, &error);
+ }
+
+ detail::errHandler(error, __CREATE_BUFFER_ERR);
+ if (err != NULL) {
+ *err = error;
+ }
+
+ if( !useHostPtr ) {
+ CommandQueue queue(context, 0, &error);
+ detail::errHandler(error, __CREATE_BUFFER_ERR);
+ if (err != NULL) {
+ *err = error;
+ }
+
+ error = cl::copy(queue, startIterator, endIterator, *this);
+ detail::errHandler(error, __CREATE_BUFFER_ERR);
+ if (err != NULL) {
+ *err = error;
+ }
+ }
+}
+
+template< typename IteratorType >
+Buffer::Buffer(
+ const CommandQueue &queue,
+ IteratorType startIterator,
+ IteratorType endIterator,
+ bool readOnly,
+ bool useHostPtr,
+ cl_int* err)
+{
+ typedef typename std::iterator_traits<IteratorType>::value_type DataType;
+ cl_int error;
+
+ cl_mem_flags flags = 0;
+ if (readOnly) {
+ flags |= CL_MEM_READ_ONLY;
+ }
+ else {
+ flags |= CL_MEM_READ_WRITE;
+ }
+ if (useHostPtr) {
+ flags |= CL_MEM_USE_HOST_PTR;
+ }
+
+ ::size_t size = sizeof(DataType)*(endIterator - startIterator);
+
+ Context context = queue.getInfo<CL_QUEUE_CONTEXT>();
+
+ if (useHostPtr) {
+ object_ = ::clCreateBuffer(context(), flags, size, static_cast<DataType*>(&*startIterator), &error);
+ }
+ else {
+ object_ = ::clCreateBuffer(context(), flags, size, 0, &error);
+ }
+
+ detail::errHandler(error, __CREATE_BUFFER_ERR);
+ if (err != NULL) {
+ *err = error;
+ }
+
+ if (!useHostPtr) {
+ error = cl::copy(queue, startIterator, endIterator, *this);
+ detail::errHandler(error, __CREATE_BUFFER_ERR);
+ if (err != NULL) {
+ *err = error;
+ }
+ }
+}
+
+inline cl_int enqueueReadBuffer(
+ const Buffer& buffer,
+ cl_bool blocking,
+ ::size_t offset,
+ ::size_t size,
+ void* ptr,
+ const VECTOR_CLASS<Event>* events = NULL,
+ Event* event = NULL)
+{
+ cl_int error;
+ CommandQueue queue = CommandQueue::getDefault(&error);
+
+ if (error != CL_SUCCESS) {
+ return error;
+ }
+
+ return queue.enqueueReadBuffer(buffer, blocking, offset, size, ptr, events, event);
+}
+
+inline cl_int enqueueWriteBuffer(
+ const Buffer& buffer,
+ cl_bool blocking,
+ ::size_t offset,
+ ::size_t size,
+ const void* ptr,
+ const VECTOR_CLASS<Event>* events = NULL,
+ Event* event = NULL)
+{
+ cl_int error;
+ CommandQueue queue = CommandQueue::getDefault(&error);
+
+ if (error != CL_SUCCESS) {
+ return error;
+ }
+
+ return queue.enqueueWriteBuffer(buffer, blocking, offset, size, ptr, events, event);
+}
+
+inline void* enqueueMapBuffer(
+ const Buffer& buffer,
+ cl_bool blocking,
+ cl_map_flags flags,
+ ::size_t offset,
+ ::size_t size,
+ const VECTOR_CLASS<Event>* events = NULL,
+ Event* event = NULL,
+ cl_int* err = NULL)
+{
+ cl_int error;
+ CommandQueue queue = CommandQueue::getDefault(&error);
+ detail::errHandler(error, __ENQUEUE_MAP_BUFFER_ERR);
+ if (err != NULL) {
+ *err = error;
+ }
+
+ void * result = ::clEnqueueMapBuffer(
+ queue(), buffer(), blocking, flags, offset, size,
+ (events != NULL) ? (cl_uint) events->size() : 0,
+ (events != NULL && events->size() > 0) ? (cl_event*) &events->front() : NULL,
+ (cl_event*) event,
+ &error);
+
+ detail::errHandler(error, __ENQUEUE_MAP_BUFFER_ERR);
+ if (err != NULL) {
+ *err = error;
+ }
+ return result;
+}
+
+inline cl_int enqueueUnmapMemObject(
+ const Memory& memory,
+ void* mapped_ptr,
+ const VECTOR_CLASS<Event>* events = NULL,
+ Event* event = NULL)
+{
+ cl_int error;
+ CommandQueue queue = CommandQueue::getDefault(&error);
+ detail::errHandler(error, __ENQUEUE_MAP_BUFFER_ERR);
+ if (error != CL_SUCCESS) {
+ return error;
+ }
+
+ cl_event tmp;
+ cl_int err = detail::errHandler(
+ ::clEnqueueUnmapMemObject(
+ queue(), memory(), mapped_ptr,
+ (events != NULL) ? (cl_uint) events->size() : 0,
+ (events != NULL && events->size() > 0) ? (cl_event*) &events->front() : NULL,
+ (event != NULL) ? &tmp : NULL),
+ __ENQUEUE_UNMAP_MEM_OBJECT_ERR);
+
+ if (event != NULL && err == CL_SUCCESS)
+ *event = tmp;
+
+ return err;
+}
+
+inline cl_int enqueueCopyBuffer(
+ const Buffer& src,
+ const Buffer& dst,
+ ::size_t src_offset,
+ ::size_t dst_offset,
+ ::size_t size,
+ const VECTOR_CLASS<Event>* events = NULL,
+ Event* event = NULL)
+{
+ cl_int error;
+ CommandQueue queue = CommandQueue::getDefault(&error);
+
+ if (error != CL_SUCCESS) {
+ return error;
+ }
+
+ return queue.enqueueCopyBuffer(src, dst, src_offset, dst_offset, size, events, event);
+}
+
+/**
+ * Blocking copy operation between iterators and a buffer.
+ * Host to Device.
+ * Uses default command queue.
+ */
+template< typename IteratorType >
+inline cl_int copy( IteratorType startIterator, IteratorType endIterator, cl::Buffer &buffer )
+{
+ cl_int error;
+ CommandQueue queue = CommandQueue::getDefault(&error);
+ if (error != CL_SUCCESS)
+ return error;
+
+ return cl::copy(queue, startIterator, endIterator, buffer);
+}
+
+/**
+ * Blocking copy operation between iterators and a buffer.
+ * Device to Host.
+ * Uses default command queue.
+ */
+template< typename IteratorType >
+inline cl_int copy( const cl::Buffer &buffer, IteratorType startIterator, IteratorType endIterator )
+{
+ cl_int error;
+ CommandQueue queue = CommandQueue::getDefault(&error);
+ if (error != CL_SUCCESS)
+ return error;
+
+ return cl::copy(queue, buffer, startIterator, endIterator);
+}
+
+/**
+ * Blocking copy operation between iterators and a buffer.
+ * Host to Device.
+ * Uses specified queue.
+ */
+template< typename IteratorType >
+inline cl_int copy( const CommandQueue &queue, IteratorType startIterator, IteratorType endIterator, cl::Buffer &buffer )
+{
+ typedef typename std::iterator_traits<IteratorType>::value_type DataType;
+ cl_int error;
+
+ ::size_t length = endIterator-startIterator;
+ ::size_t byteLength = length*sizeof(DataType);
+
+ DataType *pointer =
+ static_cast<DataType*>(queue.enqueueMapBuffer(buffer, CL_TRUE, CL_MAP_WRITE, 0, byteLength, 0, 0, &error));
+ // if exceptions enabled, enqueueMapBuffer will throw
+ if( error != CL_SUCCESS ) {
+ return error;
+ }
+#if defined(_MSC_VER)
+ std::copy(
+ startIterator,
+ endIterator,
+ stdext::checked_array_iterator<DataType*>(
+ pointer, length));
+#else
+ std::copy(startIterator, endIterator, pointer);
+#endif
+ Event endEvent;
+ error = queue.enqueueUnmapMemObject(buffer, pointer, 0, &endEvent);
+ // if exceptions enabled, enqueueUnmapMemObject will throw
+ if( error != CL_SUCCESS ) {
+ return error;
+ }
+ endEvent.wait();
+ return CL_SUCCESS;
+}
+
+/**
+ * Blocking copy operation between iterators and a buffer.
+ * Device to Host.
+ * Uses specified queue.
+ */
+template< typename IteratorType >
+inline cl_int copy( const CommandQueue &queue, const cl::Buffer &buffer, IteratorType startIterator, IteratorType endIterator )
+{
+ typedef typename std::iterator_traits<IteratorType>::value_type DataType;
+ cl_int error;
+
+ ::size_t length = endIterator-startIterator;
+ ::size_t byteLength = length*sizeof(DataType);
+
+ DataType *pointer =
+ static_cast<DataType*>(queue.enqueueMapBuffer(buffer, CL_TRUE, CL_MAP_READ, 0, byteLength, 0, 0, &error));
+ // if exceptions enabled, enqueueMapBuffer will throw
+ if( error != CL_SUCCESS ) {
+ return error;
+ }
+ std::copy(pointer, pointer + length, startIterator);
+ Event endEvent;
+ error = queue.enqueueUnmapMemObject(buffer, pointer, 0, &endEvent);
+ // if exceptions enabled, enqueueUnmapMemObject will throw
+ if( error != CL_SUCCESS ) {
+ return error;
+ }
+ endEvent.wait();
+ return CL_SUCCESS;
+}
+
+#if defined(CL_VERSION_1_1)
+inline cl_int enqueueReadBufferRect(
+ const Buffer& buffer,
+ cl_bool blocking,
+ const size_t<3>& buffer_offset,
+ const size_t<3>& host_offset,
+ const size_t<3>& region,
+ ::size_t buffer_row_pitch,
+ ::size_t buffer_slice_pitch,
+ ::size_t host_row_pitch,
+ ::size_t host_slice_pitch,
+ void *ptr,
+ const VECTOR_CLASS<Event>* events = NULL,
+ Event* event = NULL)
+{
+ cl_int error;
+ CommandQueue queue = CommandQueue::getDefault(&error);
+
+ if (error != CL_SUCCESS) {
+ return error;
+ }
+
+ return queue.enqueueReadBufferRect(
+ buffer,
+ blocking,
+ buffer_offset,
+ host_offset,
+ region,
+ buffer_row_pitch,
+ buffer_slice_pitch,
+ host_row_pitch,
+ host_slice_pitch,
+ ptr,
+ events,
+ event);
+}
+
+inline cl_int enqueueWriteBufferRect(
+ const Buffer& buffer,
+ cl_bool blocking,
+ const size_t<3>& buffer_offset,
+ const size_t<3>& host_offset,
+ const size_t<3>& region,
+ ::size_t buffer_row_pitch,
+ ::size_t buffer_slice_pitch,
+ ::size_t host_row_pitch,
+ ::size_t host_slice_pitch,
+ void *ptr,
+ const VECTOR_CLASS<Event>* events = NULL,
+ Event* event = NULL)
+{
+ cl_int error;
+ CommandQueue queue = CommandQueue::getDefault(&error);
+
+ if (error != CL_SUCCESS) {
+ return error;
+ }
+
+ return queue.enqueueWriteBufferRect(
+ buffer,
+ blocking,
+ buffer_offset,
+ host_offset,
+ region,
+ buffer_row_pitch,
+ buffer_slice_pitch,
+ host_row_pitch,
+ host_slice_pitch,
+ ptr,
+ events,
+ event);
+}
+
+inline cl_int enqueueCopyBufferRect(
+ const Buffer& src,
+ const Buffer& dst,
+ const size_t<3>& src_origin,
+ const size_t<3>& dst_origin,
+ const size_t<3>& region,
+ ::size_t src_row_pitch,
+ ::size_t src_slice_pitch,
+ ::size_t dst_row_pitch,
+ ::size_t dst_slice_pitch,
+ const VECTOR_CLASS<Event>* events = NULL,
+ Event* event = NULL)
+{
+ cl_int error;
+ CommandQueue queue = CommandQueue::getDefault(&error);
+
+ if (error != CL_SUCCESS) {
+ return error;
+ }
+
+ return queue.enqueueCopyBufferRect(
+ src,
+ dst,
+ src_origin,
+ dst_origin,
+ region,
+ src_row_pitch,
+ src_slice_pitch,
+ dst_row_pitch,
+ dst_slice_pitch,
+ events,
+ event);
+}
+#endif
+
+inline cl_int enqueueReadImage(
+ const Image& image,
+ cl_bool blocking,
+ const size_t<3>& origin,
+ const size_t<3>& region,
+ ::size_t row_pitch,
+ ::size_t slice_pitch,
+ void* ptr,
+ const VECTOR_CLASS<Event>* events = NULL,
+ Event* event = NULL)
+{
+ cl_int error;
+ CommandQueue queue = CommandQueue::getDefault(&error);
+
+ if (error != CL_SUCCESS) {
+ return error;
+ }
+
+ return queue.enqueueReadImage(
+ image,
+ blocking,
+ origin,
+ region,
+ row_pitch,
+ slice_pitch,
+ ptr,
+ events,
+ event);
+}
+
+inline cl_int enqueueWriteImage(
+ const Image& image,
+ cl_bool blocking,
+ const size_t<3>& origin,
+ const size_t<3>& region,
+ ::size_t row_pitch,
+ ::size_t slice_pitch,
+ void* ptr,
+ const VECTOR_CLASS<Event>* events = NULL,
+ Event* event = NULL)
+{
+ cl_int error;
+ CommandQueue queue = CommandQueue::getDefault(&error);
+
+ if (error != CL_SUCCESS) {
+ return error;
+ }
+
+ return queue.enqueueWriteImage(
+ image,
+ blocking,
+ origin,
+ region,
+ row_pitch,
+ slice_pitch,
+ ptr,
+ events,
+ event);
+}
+
+inline cl_int enqueueCopyImage(
+ const Image& src,
+ const Image& dst,
+ const size_t<3>& src_origin,
+ const size_t<3>& dst_origin,
+ const size_t<3>& region,
+ const VECTOR_CLASS<Event>* events = NULL,
+ Event* event = NULL)
+{
+ cl_int error;
+ CommandQueue queue = CommandQueue::getDefault(&error);
+
+ if (error != CL_SUCCESS) {
+ return error;
+ }
+
+ return queue.enqueueCopyImage(
+ src,
+ dst,
+ src_origin,
+ dst_origin,
+ region,
+ events,
+ event);
+}
+
+inline cl_int enqueueCopyImageToBuffer(
+ const Image& src,
+ const Buffer& dst,
+ const size_t<3>& src_origin,
+ const size_t<3>& region,
+ ::size_t dst_offset,
+ const VECTOR_CLASS<Event>* events = NULL,
+ Event* event = NULL)
+{
+ cl_int error;
+ CommandQueue queue = CommandQueue::getDefault(&error);
+
+ if (error != CL_SUCCESS) {
+ return error;
+ }
+
+ return queue.enqueueCopyImageToBuffer(
+ src,
+ dst,
+ src_origin,
+ region,
+ dst_offset,
+ events,
+ event);
+}
+
+inline cl_int enqueueCopyBufferToImage(
+ const Buffer& src,
+ const Image& dst,
+ ::size_t src_offset,
+ const size_t<3>& dst_origin,
+ const size_t<3>& region,
+ const VECTOR_CLASS<Event>* events = NULL,
+ Event* event = NULL)
+{
+ cl_int error;
+ CommandQueue queue = CommandQueue::getDefault(&error);
+
+ if (error != CL_SUCCESS) {
+ return error;
+ }
+
+ return queue.enqueueCopyBufferToImage(
+ src,
+ dst,
+ src_offset,
+ dst_origin,
+ region,
+ events,
+ event);
+}
+
+
+inline cl_int flush(void)
+{
+ cl_int error;
+ CommandQueue queue = CommandQueue::getDefault(&error);
+
+ if (error != CL_SUCCESS) {
+ return error;
+ }
+
+ return queue.flush();
+}
+
+inline cl_int finish(void)
+{
+ cl_int error;
+ CommandQueue queue = CommandQueue::getDefault(&error);
+
+ if (error != CL_SUCCESS) {
+ return error;
+ }
+
+
+ return queue.finish();
+}
+
+// Kernel Functor support
+// New interface as of September 2011
+// Requires the C++11 std::tr1::function (note do not support TR1)
+// Visual Studio 2010 and GCC 4.2
+
+struct EnqueueArgs
+{
+ CommandQueue queue_;
+ const NDRange offset_;
+ const NDRange global_;
+ const NDRange local_;
+ VECTOR_CLASS<Event> events_;
+
+ EnqueueArgs(NDRange global) :
+ queue_(CommandQueue::getDefault()),
+ offset_(NullRange),
+ global_(global),
+ local_(NullRange)
+ {
+
+ }
+
+ EnqueueArgs(NDRange global, NDRange local) :
+ queue_(CommandQueue::getDefault()),
+ offset_(NullRange),
+ global_(global),
+ local_(local)
+ {
+
+ }
+
+ EnqueueArgs(NDRange offset, NDRange global, NDRange local) :
+ queue_(CommandQueue::getDefault()),
+ offset_(offset),
+ global_(global),
+ local_(local)
+ {
+
+ }
+
+ EnqueueArgs(Event e, NDRange global) :
+ queue_(CommandQueue::getDefault()),
+ offset_(NullRange),
+ global_(global),
+ local_(NullRange)
+ {
+ events_.push_back(e);
+ }
+
+ EnqueueArgs(Event e, NDRange global, NDRange local) :
+ queue_(CommandQueue::getDefault()),
+ offset_(NullRange),
+ global_(global),
+ local_(local)
+ {
+ events_.push_back(e);
+ }
+
+ EnqueueArgs(Event e, NDRange offset, NDRange global, NDRange local) :
+ queue_(CommandQueue::getDefault()),
+ offset_(offset),
+ global_(global),
+ local_(local)
+ {
+ events_.push_back(e);
+ }
+
+ EnqueueArgs(const VECTOR_CLASS<Event> &events, NDRange global) :
+ queue_(CommandQueue::getDefault()),
+ offset_(NullRange),
+ global_(global),
+ local_(NullRange),
+ events_(events)
+ {
+
+ }
+
+ EnqueueArgs(const VECTOR_CLASS<Event> &events, NDRange global, NDRange local) :
+ queue_(CommandQueue::getDefault()),
+ offset_(NullRange),
+ global_(global),
+ local_(local),
+ events_(events)
+ {
+
+ }
+
+ EnqueueArgs(const VECTOR_CLASS<Event> &events, NDRange offset, NDRange global, NDRange local) :
+ queue_(CommandQueue::getDefault()),
+ offset_(offset),
+ global_(global),
+ local_(local),
+ events_(events)
+ {
+
+ }
+
+ EnqueueArgs(CommandQueue &queue, NDRange global) :
+ queue_(queue),
+ offset_(NullRange),
+ global_(global),
+ local_(NullRange)
+ {
+
+ }
+
+ EnqueueArgs(CommandQueue &queue, NDRange global, NDRange local) :
+ queue_(queue),
+ offset_(NullRange),
+ global_(global),
+ local_(local)
+ {
+
+ }
+
+ EnqueueArgs(CommandQueue &queue, NDRange offset, NDRange global, NDRange local) :
+ queue_(queue),
+ offset_(offset),
+ global_(global),
+ local_(local)
+ {
+
+ }
+
+ EnqueueArgs(CommandQueue &queue, Event e, NDRange global) :
+ queue_(queue),
+ offset_(NullRange),
+ global_(global),
+ local_(NullRange)
+ {
+ events_.push_back(e);
+ }
+
+ EnqueueArgs(CommandQueue &queue, Event e, NDRange global, NDRange local) :
+ queue_(queue),
+ offset_(NullRange),
+ global_(global),
+ local_(local)
+ {
+ events_.push_back(e);
+ }
+
+ EnqueueArgs(CommandQueue &queue, Event e, NDRange offset, NDRange global, NDRange local) :
+ queue_(queue),
+ offset_(offset),
+ global_(global),
+ local_(local)
+ {
+ events_.push_back(e);
+ }
+
+ EnqueueArgs(CommandQueue &queue, const VECTOR_CLASS<Event> &events, NDRange global) :
+ queue_(queue),
+ offset_(NullRange),
+ global_(global),
+ local_(NullRange),
+ events_(events)
+ {
+
+ }
+
+ EnqueueArgs(CommandQueue &queue, const VECTOR_CLASS<Event> &events, NDRange global, NDRange local) :
+ queue_(queue),
+ offset_(NullRange),
+ global_(global),
+ local_(local),
+ events_(events)
+ {
+
+ }
+
+ EnqueueArgs(CommandQueue &queue, const VECTOR_CLASS<Event> &events, NDRange offset, NDRange global, NDRange local) :
+ queue_(queue),
+ offset_(offset),
+ global_(global),
+ local_(local),
+ events_(events)
+ {
+
+ }
+};
+
+namespace detail {
+
+class NullType {};
+
+template<int index, typename T0>
+struct SetArg
+{
+ static void set (Kernel kernel, T0 arg)
+ {
+ kernel.setArg(index, arg);
+ }
+};
+
+template<int index>
+struct SetArg<index, NullType>
+{
+ static void set (Kernel, NullType)
+ {
+ }
+};
+
+template <
+ typename T0, typename T1, typename T2, typename T3,
+ typename T4, typename T5, typename T6, typename T7,
+ typename T8, typename T9, typename T10, typename T11,
+ typename T12, typename T13, typename T14, typename T15,
+ typename T16, typename T17, typename T18, typename T19,
+ typename T20, typename T21, typename T22, typename T23,
+ typename T24, typename T25, typename T26, typename T27,
+ typename T28, typename T29, typename T30, typename T31
+>
+class KernelFunctorGlobal
+{
+private:
+ Kernel kernel_;
+
+public:
+ KernelFunctorGlobal(
+ Kernel kernel) :
+ kernel_(kernel)
+ {}
+
+ KernelFunctorGlobal(
+ const Program& program,
+ const STRING_CLASS name,
+ cl_int * err = NULL) :
+ kernel_(program, name.c_str(), err)
+ {}
+
+ Event operator() (
+ const EnqueueArgs& args,
+ T0 t0,
+ T1 t1 = NullType(),
+ T2 t2 = NullType(),
+ T3 t3 = NullType(),
+ T4 t4 = NullType(),
+ T5 t5 = NullType(),
+ T6 t6 = NullType(),
+ T7 t7 = NullType(),
+ T8 t8 = NullType(),
+ T9 t9 = NullType(),
+ T10 t10 = NullType(),
+ T11 t11 = NullType(),
+ T12 t12 = NullType(),
+ T13 t13 = NullType(),
+ T14 t14 = NullType(),
+ T15 t15 = NullType(),
+ T16 t16 = NullType(),
+ T17 t17 = NullType(),
+ T18 t18 = NullType(),
+ T19 t19 = NullType(),
+ T20 t20 = NullType(),
+ T21 t21 = NullType(),
+ T22 t22 = NullType(),
+ T23 t23 = NullType(),
+ T24 t24 = NullType(),
+ T25 t25 = NullType(),
+ T26 t26 = NullType(),
+ T27 t27 = NullType(),
+ T28 t28 = NullType(),
+ T29 t29 = NullType(),
+ T30 t30 = NullType(),
+ T31 t31 = NullType()
+ )
+ {
+ Event event;
+ SetArg<0, T0>::set(kernel_, t0);
+ SetArg<1, T1>::set(kernel_, t1);
+ SetArg<2, T2>::set(kernel_, t2);
+ SetArg<3, T3>::set(kernel_, t3);
+ SetArg<4, T4>::set(kernel_, t4);
+ SetArg<5, T5>::set(kernel_, t5);
+ SetArg<6, T6>::set(kernel_, t6);
+ SetArg<7, T7>::set(kernel_, t7);
+ SetArg<8, T8>::set(kernel_, t8);
+ SetArg<9, T9>::set(kernel_, t9);
+ SetArg<10, T10>::set(kernel_, t10);
+ SetArg<11, T11>::set(kernel_, t11);
+ SetArg<12, T12>::set(kernel_, t12);
+ SetArg<13, T13>::set(kernel_, t13);
+ SetArg<14, T14>::set(kernel_, t14);
+ SetArg<15, T15>::set(kernel_, t15);
+ SetArg<16, T16>::set(kernel_, t16);
+ SetArg<17, T17>::set(kernel_, t17);
+ SetArg<18, T18>::set(kernel_, t18);
+ SetArg<19, T19>::set(kernel_, t19);
+ SetArg<20, T20>::set(kernel_, t20);
+ SetArg<21, T21>::set(kernel_, t21);
+ SetArg<22, T22>::set(kernel_, t22);
+ SetArg<23, T23>::set(kernel_, t23);
+ SetArg<24, T24>::set(kernel_, t24);
+ SetArg<25, T25>::set(kernel_, t25);
+ SetArg<26, T26>::set(kernel_, t26);
+ SetArg<27, T27>::set(kernel_, t27);
+ SetArg<28, T28>::set(kernel_, t28);
+ SetArg<29, T29>::set(kernel_, t29);
+ SetArg<30, T30>::set(kernel_, t30);
+ SetArg<31, T31>::set(kernel_, t31);
+
+ args.queue_.enqueueNDRangeKernel(
+ kernel_,
+ args.offset_,
+ args.global_,
+ args.local_,
+ &args.events_,
+ &event);
+
+ return event;
+ }
+
+};
+
+//------------------------------------------------------------------------------------------------------
+
+
+template<
+ typename T0,
+ typename T1,
+ typename T2,
+ typename T3,
+ typename T4,
+ typename T5,
+ typename T6,
+ typename T7,
+ typename T8,
+ typename T9,
+ typename T10,
+ typename T11,
+ typename T12,
+ typename T13,
+ typename T14,
+ typename T15,
+ typename T16,
+ typename T17,
+ typename T18,
+ typename T19,
+ typename T20,
+ typename T21,
+ typename T22,
+ typename T23,
+ typename T24,
+ typename T25,
+ typename T26,
+ typename T27,
+ typename T28,
+ typename T29,
+ typename T30,
+ typename T31>
+struct functionImplementation_
+{
+ typedef detail::KernelFunctorGlobal<
+ T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11,
+ T12,
+ T13,
+ T14,
+ T15,
+ T16,
+ T17,
+ T18,
+ T19,
+ T20,
+ T21,
+ T22,
+ T23,
+ T24,
+ T25,
+ T26,
+ T27,
+ T28,
+ T29,
+ T30,
+ T31> FunctorType;
+
+ FunctorType functor_;
+
+ functionImplementation_(const FunctorType &functor) :
+ functor_(functor)
+ {
+
+ #if (defined(_WIN32) && defined(_VARIADIC_MAX) && (_VARIADIC_MAX < 32))
+ // Fail variadic expansion for dev11
+ static_assert(0, "Visual Studio has a hard limit of argument count for a std::function expansion. Please define _VARIADIC_MAX to be 10. If you need more arguments than that VC12 and below cannot support it.");
+ #endif
+
+ }
+
+ //! \brief Return type of the functor
+ typedef Event result_type;
+
+ //! \brief Function signature of kernel functor with no event dependency.
+ typedef Event type_(
+ const EnqueueArgs&,
+ T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11,
+ T12,
+ T13,
+ T14,
+ T15,
+ T16,
+ T17,
+ T18,
+ T19,
+ T20,
+ T21,
+ T22,
+ T23,
+ T24,
+ T25,
+ T26,
+ T27,
+ T28,
+ T29,
+ T30,
+ T31);
+
+ Event operator()(
+ const EnqueueArgs& enqueueArgs,
+ T0 arg0,
+ T1 arg1,
+ T2 arg2,
+ T3 arg3,
+ T4 arg4,
+ T5 arg5,
+ T6 arg6,
+ T7 arg7,
+ T8 arg8,
+ T9 arg9,
+ T10 arg10,
+ T11 arg11,
+ T12 arg12,
+ T13 arg13,
+ T14 arg14,
+ T15 arg15,
+ T16 arg16,
+ T17 arg17,
+ T18 arg18,
+ T19 arg19,
+ T20 arg20,
+ T21 arg21,
+ T22 arg22,
+ T23 arg23,
+ T24 arg24,
+ T25 arg25,
+ T26 arg26,
+ T27 arg27,
+ T28 arg28,
+ T29 arg29,
+ T30 arg30,
+ T31 arg31)
+ {
+ return functor_(
+ enqueueArgs,
+ arg0,
+ arg1,
+ arg2,
+ arg3,
+ arg4,
+ arg5,
+ arg6,
+ arg7,
+ arg8,
+ arg9,
+ arg10,
+ arg11,
+ arg12,
+ arg13,
+ arg14,
+ arg15,
+ arg16,
+ arg17,
+ arg18,
+ arg19,
+ arg20,
+ arg21,
+ arg22,
+ arg23,
+ arg24,
+ arg25,
+ arg26,
+ arg27,
+ arg28,
+ arg29,
+ arg30,
+ arg31);
+ }
+
+
+};
+
+template<
+ typename T0,
+ typename T1,
+ typename T2,
+ typename T3,
+ typename T4,
+ typename T5,
+ typename T6,
+ typename T7,
+ typename T8,
+ typename T9,
+ typename T10,
+ typename T11,
+ typename T12,
+ typename T13,
+ typename T14,
+ typename T15,
+ typename T16,
+ typename T17,
+ typename T18,
+ typename T19,
+ typename T20,
+ typename T21,
+ typename T22,
+ typename T23,
+ typename T24,
+ typename T25,
+ typename T26,
+ typename T27,
+ typename T28,
+ typename T29,
+ typename T30>
+struct functionImplementation_
+< T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11,
+ T12,
+ T13,
+ T14,
+ T15,
+ T16,
+ T17,
+ T18,
+ T19,
+ T20,
+ T21,
+ T22,
+ T23,
+ T24,
+ T25,
+ T26,
+ T27,
+ T28,
+ T29,
+ T30,
+ NullType>
+{
+ typedef detail::KernelFunctorGlobal<
+ T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11,
+ T12,
+ T13,
+ T14,
+ T15,
+ T16,
+ T17,
+ T18,
+ T19,
+ T20,
+ T21,
+ T22,
+ T23,
+ T24,
+ T25,
+ T26,
+ T27,
+ T28,
+ T29,
+ T30,
+ NullType> FunctorType;
+
+ FunctorType functor_;
+
+ functionImplementation_(const FunctorType &functor) :
+ functor_(functor)
+ {
+
+ #if (defined(_WIN32) && defined(_VARIADIC_MAX) && (_VARIADIC_MAX < 31))
+ // Fail variadic expansion for dev11
+ static_assert(0, "Visual Studio has a hard limit of argument count for a std::function expansion. Please define _VARIADIC_MAX to be 10. If you need more arguments than that VC12 and below cannot support it.");
+ #endif
+
+ }
+
+ //! \brief Return type of the functor
+ typedef Event result_type;
+
+ //! \brief Function signature of kernel functor with no event dependency.
+ typedef Event type_(
+ const EnqueueArgs&,
+ T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11,
+ T12,
+ T13,
+ T14,
+ T15,
+ T16,
+ T17,
+ T18,
+ T19,
+ T20,
+ T21,
+ T22,
+ T23,
+ T24,
+ T25,
+ T26,
+ T27,
+ T28,
+ T29,
+ T30);
+
+ Event operator()(
+ const EnqueueArgs& enqueueArgs,
+ T0 arg0,
+ T1 arg1,
+ T2 arg2,
+ T3 arg3,
+ T4 arg4,
+ T5 arg5,
+ T6 arg6,
+ T7 arg7,
+ T8 arg8,
+ T9 arg9,
+ T10 arg10,
+ T11 arg11,
+ T12 arg12,
+ T13 arg13,
+ T14 arg14,
+ T15 arg15,
+ T16 arg16,
+ T17 arg17,
+ T18 arg18,
+ T19 arg19,
+ T20 arg20,
+ T21 arg21,
+ T22 arg22,
+ T23 arg23,
+ T24 arg24,
+ T25 arg25,
+ T26 arg26,
+ T27 arg27,
+ T28 arg28,
+ T29 arg29,
+ T30 arg30)
+ {
+ return functor_(
+ enqueueArgs,
+ arg0,
+ arg1,
+ arg2,
+ arg3,
+ arg4,
+ arg5,
+ arg6,
+ arg7,
+ arg8,
+ arg9,
+ arg10,
+ arg11,
+ arg12,
+ arg13,
+ arg14,
+ arg15,
+ arg16,
+ arg17,
+ arg18,
+ arg19,
+ arg20,
+ arg21,
+ arg22,
+ arg23,
+ arg24,
+ arg25,
+ arg26,
+ arg27,
+ arg28,
+ arg29,
+ arg30);
+ }
+
+
+};
+
+template<
+ typename T0,
+ typename T1,
+ typename T2,
+ typename T3,
+ typename T4,
+ typename T5,
+ typename T6,
+ typename T7,
+ typename T8,
+ typename T9,
+ typename T10,
+ typename T11,
+ typename T12,
+ typename T13,
+ typename T14,
+ typename T15,
+ typename T16,
+ typename T17,
+ typename T18,
+ typename T19,
+ typename T20,
+ typename T21,
+ typename T22,
+ typename T23,
+ typename T24,
+ typename T25,
+ typename T26,
+ typename T27,
+ typename T28,
+ typename T29>
+struct functionImplementation_
+< T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11,
+ T12,
+ T13,
+ T14,
+ T15,
+ T16,
+ T17,
+ T18,
+ T19,
+ T20,
+ T21,
+ T22,
+ T23,
+ T24,
+ T25,
+ T26,
+ T27,
+ T28,
+ T29,
+ NullType,
+ NullType>
+{
+ typedef detail::KernelFunctorGlobal<
+ T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11,
+ T12,
+ T13,
+ T14,
+ T15,
+ T16,
+ T17,
+ T18,
+ T19,
+ T20,
+ T21,
+ T22,
+ T23,
+ T24,
+ T25,
+ T26,
+ T27,
+ T28,
+ T29,
+ NullType,
+ NullType> FunctorType;
+
+ FunctorType functor_;
+
+ functionImplementation_(const FunctorType &functor) :
+ functor_(functor)
+ {
+
+ #if (defined(_WIN32) && defined(_VARIADIC_MAX) && (_VARIADIC_MAX < 30))
+ // Fail variadic expansion for dev11
+ static_assert(0, "Visual Studio has a hard limit of argument count for a std::function expansion. Please define _VARIADIC_MAX to be 10. If you need more arguments than that VC12 and below cannot support it.");
+ #endif
+
+ }
+
+ //! \brief Return type of the functor
+ typedef Event result_type;
+
+ //! \brief Function signature of kernel functor with no event dependency.
+ typedef Event type_(
+ const EnqueueArgs&,
+ T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11,
+ T12,
+ T13,
+ T14,
+ T15,
+ T16,
+ T17,
+ T18,
+ T19,
+ T20,
+ T21,
+ T22,
+ T23,
+ T24,
+ T25,
+ T26,
+ T27,
+ T28,
+ T29);
+
+ Event operator()(
+ const EnqueueArgs& enqueueArgs,
+ T0 arg0,
+ T1 arg1,
+ T2 arg2,
+ T3 arg3,
+ T4 arg4,
+ T5 arg5,
+ T6 arg6,
+ T7 arg7,
+ T8 arg8,
+ T9 arg9,
+ T10 arg10,
+ T11 arg11,
+ T12 arg12,
+ T13 arg13,
+ T14 arg14,
+ T15 arg15,
+ T16 arg16,
+ T17 arg17,
+ T18 arg18,
+ T19 arg19,
+ T20 arg20,
+ T21 arg21,
+ T22 arg22,
+ T23 arg23,
+ T24 arg24,
+ T25 arg25,
+ T26 arg26,
+ T27 arg27,
+ T28 arg28,
+ T29 arg29)
+ {
+ return functor_(
+ enqueueArgs,
+ arg0,
+ arg1,
+ arg2,
+ arg3,
+ arg4,
+ arg5,
+ arg6,
+ arg7,
+ arg8,
+ arg9,
+ arg10,
+ arg11,
+ arg12,
+ arg13,
+ arg14,
+ arg15,
+ arg16,
+ arg17,
+ arg18,
+ arg19,
+ arg20,
+ arg21,
+ arg22,
+ arg23,
+ arg24,
+ arg25,
+ arg26,
+ arg27,
+ arg28,
+ arg29);
+ }
+
+
+};
+
+template<
+ typename T0,
+ typename T1,
+ typename T2,
+ typename T3,
+ typename T4,
+ typename T5,
+ typename T6,
+ typename T7,
+ typename T8,
+ typename T9,
+ typename T10,
+ typename T11,
+ typename T12,
+ typename T13,
+ typename T14,
+ typename T15,
+ typename T16,
+ typename T17,
+ typename T18,
+ typename T19,
+ typename T20,
+ typename T21,
+ typename T22,
+ typename T23,
+ typename T24,
+ typename T25,
+ typename T26,
+ typename T27,
+ typename T28>
+struct functionImplementation_
+< T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11,
+ T12,
+ T13,
+ T14,
+ T15,
+ T16,
+ T17,
+ T18,
+ T19,
+ T20,
+ T21,
+ T22,
+ T23,
+ T24,
+ T25,
+ T26,
+ T27,
+ T28,
+ NullType,
+ NullType,
+ NullType>
+{
+ typedef detail::KernelFunctorGlobal<
+ T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11,
+ T12,
+ T13,
+ T14,
+ T15,
+ T16,
+ T17,
+ T18,
+ T19,
+ T20,
+ T21,
+ T22,
+ T23,
+ T24,
+ T25,
+ T26,
+ T27,
+ T28,
+ NullType,
+ NullType,
+ NullType> FunctorType;
+
+ FunctorType functor_;
+
+ functionImplementation_(const FunctorType &functor) :
+ functor_(functor)
+ {
+
+ #if (defined(_WIN32) && defined(_VARIADIC_MAX) && (_VARIADIC_MAX < 29))
+ // Fail variadic expansion for dev11
+ static_assert(0, "Visual Studio has a hard limit of argument count for a std::function expansion. Please define _VARIADIC_MAX to be 10. If you need more arguments than that VC12 and below cannot support it.");
+ #endif
+
+ }
+
+ //! \brief Return type of the functor
+ typedef Event result_type;
+
+ //! \brief Function signature of kernel functor with no event dependency.
+ typedef Event type_(
+ const EnqueueArgs&,
+ T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11,
+ T12,
+ T13,
+ T14,
+ T15,
+ T16,
+ T17,
+ T18,
+ T19,
+ T20,
+ T21,
+ T22,
+ T23,
+ T24,
+ T25,
+ T26,
+ T27,
+ T28);
+
+ Event operator()(
+ const EnqueueArgs& enqueueArgs,
+ T0 arg0,
+ T1 arg1,
+ T2 arg2,
+ T3 arg3,
+ T4 arg4,
+ T5 arg5,
+ T6 arg6,
+ T7 arg7,
+ T8 arg8,
+ T9 arg9,
+ T10 arg10,
+ T11 arg11,
+ T12 arg12,
+ T13 arg13,
+ T14 arg14,
+ T15 arg15,
+ T16 arg16,
+ T17 arg17,
+ T18 arg18,
+ T19 arg19,
+ T20 arg20,
+ T21 arg21,
+ T22 arg22,
+ T23 arg23,
+ T24 arg24,
+ T25 arg25,
+ T26 arg26,
+ T27 arg27,
+ T28 arg28)
+ {
+ return functor_(
+ enqueueArgs,
+ arg0,
+ arg1,
+ arg2,
+ arg3,
+ arg4,
+ arg5,
+ arg6,
+ arg7,
+ arg8,
+ arg9,
+ arg10,
+ arg11,
+ arg12,
+ arg13,
+ arg14,
+ arg15,
+ arg16,
+ arg17,
+ arg18,
+ arg19,
+ arg20,
+ arg21,
+ arg22,
+ arg23,
+ arg24,
+ arg25,
+ arg26,
+ arg27,
+ arg28);
+ }
+
+
+};
+
+template<
+ typename T0,
+ typename T1,
+ typename T2,
+ typename T3,
+ typename T4,
+ typename T5,
+ typename T6,
+ typename T7,
+ typename T8,
+ typename T9,
+ typename T10,
+ typename T11,
+ typename T12,
+ typename T13,
+ typename T14,
+ typename T15,
+ typename T16,
+ typename T17,
+ typename T18,
+ typename T19,
+ typename T20,
+ typename T21,
+ typename T22,
+ typename T23,
+ typename T24,
+ typename T25,
+ typename T26,
+ typename T27>
+struct functionImplementation_
+< T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11,
+ T12,
+ T13,
+ T14,
+ T15,
+ T16,
+ T17,
+ T18,
+ T19,
+ T20,
+ T21,
+ T22,
+ T23,
+ T24,
+ T25,
+ T26,
+ T27,
+ NullType,
+ NullType,
+ NullType,
+ NullType>
+{
+ typedef detail::KernelFunctorGlobal<
+ T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11,
+ T12,
+ T13,
+ T14,
+ T15,
+ T16,
+ T17,
+ T18,
+ T19,
+ T20,
+ T21,
+ T22,
+ T23,
+ T24,
+ T25,
+ T26,
+ T27,
+ NullType,
+ NullType,
+ NullType,
+ NullType> FunctorType;
+
+ FunctorType functor_;
+
+ functionImplementation_(const FunctorType &functor) :
+ functor_(functor)
+ {
+
+ #if (defined(_WIN32) && defined(_VARIADIC_MAX) && (_VARIADIC_MAX < 28))
+ // Fail variadic expansion for dev11
+ static_assert(0, "Visual Studio has a hard limit of argument count for a std::function expansion. Please define _VARIADIC_MAX to be 10. If you need more arguments than that VC12 and below cannot support it.");
+ #endif
+
+ }
+
+ //! \brief Return type of the functor
+ typedef Event result_type;
+
+ //! \brief Function signature of kernel functor with no event dependency.
+ typedef Event type_(
+ const EnqueueArgs&,
+ T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11,
+ T12,
+ T13,
+ T14,
+ T15,
+ T16,
+ T17,
+ T18,
+ T19,
+ T20,
+ T21,
+ T22,
+ T23,
+ T24,
+ T25,
+ T26,
+ T27);
+
+ Event operator()(
+ const EnqueueArgs& enqueueArgs,
+ T0 arg0,
+ T1 arg1,
+ T2 arg2,
+ T3 arg3,
+ T4 arg4,
+ T5 arg5,
+ T6 arg6,
+ T7 arg7,
+ T8 arg8,
+ T9 arg9,
+ T10 arg10,
+ T11 arg11,
+ T12 arg12,
+ T13 arg13,
+ T14 arg14,
+ T15 arg15,
+ T16 arg16,
+ T17 arg17,
+ T18 arg18,
+ T19 arg19,
+ T20 arg20,
+ T21 arg21,
+ T22 arg22,
+ T23 arg23,
+ T24 arg24,
+ T25 arg25,
+ T26 arg26,
+ T27 arg27)
+ {
+ return functor_(
+ enqueueArgs,
+ arg0,
+ arg1,
+ arg2,
+ arg3,
+ arg4,
+ arg5,
+ arg6,
+ arg7,
+ arg8,
+ arg9,
+ arg10,
+ arg11,
+ arg12,
+ arg13,
+ arg14,
+ arg15,
+ arg16,
+ arg17,
+ arg18,
+ arg19,
+ arg20,
+ arg21,
+ arg22,
+ arg23,
+ arg24,
+ arg25,
+ arg26,
+ arg27);
+ }
+
+
+};
+
+template<
+ typename T0,
+ typename T1,
+ typename T2,
+ typename T3,
+ typename T4,
+ typename T5,
+ typename T6,
+ typename T7,
+ typename T8,
+ typename T9,
+ typename T10,
+ typename T11,
+ typename T12,
+ typename T13,
+ typename T14,
+ typename T15,
+ typename T16,
+ typename T17,
+ typename T18,
+ typename T19,
+ typename T20,
+ typename T21,
+ typename T22,
+ typename T23,
+ typename T24,
+ typename T25,
+ typename T26>
+struct functionImplementation_
+< T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11,
+ T12,
+ T13,
+ T14,
+ T15,
+ T16,
+ T17,
+ T18,
+ T19,
+ T20,
+ T21,
+ T22,
+ T23,
+ T24,
+ T25,
+ T26,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType>
+{
+ typedef detail::KernelFunctorGlobal<
+ T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11,
+ T12,
+ T13,
+ T14,
+ T15,
+ T16,
+ T17,
+ T18,
+ T19,
+ T20,
+ T21,
+ T22,
+ T23,
+ T24,
+ T25,
+ T26,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType> FunctorType;
+
+ FunctorType functor_;
+
+ functionImplementation_(const FunctorType &functor) :
+ functor_(functor)
+ {
+
+ #if (defined(_WIN32) && defined(_VARIADIC_MAX) && (_VARIADIC_MAX < 27))
+ // Fail variadic expansion for dev11
+ static_assert(0, "Visual Studio has a hard limit of argument count for a std::function expansion. Please define _VARIADIC_MAX to be 10. If you need more arguments than that VC12 and below cannot support it.");
+ #endif
+
+ }
+
+ //! \brief Return type of the functor
+ typedef Event result_type;
+
+ //! \brief Function signature of kernel functor with no event dependency.
+ typedef Event type_(
+ const EnqueueArgs&,
+ T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11,
+ T12,
+ T13,
+ T14,
+ T15,
+ T16,
+ T17,
+ T18,
+ T19,
+ T20,
+ T21,
+ T22,
+ T23,
+ T24,
+ T25,
+ T26);
+
+ Event operator()(
+ const EnqueueArgs& enqueueArgs,
+ T0 arg0,
+ T1 arg1,
+ T2 arg2,
+ T3 arg3,
+ T4 arg4,
+ T5 arg5,
+ T6 arg6,
+ T7 arg7,
+ T8 arg8,
+ T9 arg9,
+ T10 arg10,
+ T11 arg11,
+ T12 arg12,
+ T13 arg13,
+ T14 arg14,
+ T15 arg15,
+ T16 arg16,
+ T17 arg17,
+ T18 arg18,
+ T19 arg19,
+ T20 arg20,
+ T21 arg21,
+ T22 arg22,
+ T23 arg23,
+ T24 arg24,
+ T25 arg25,
+ T26 arg26)
+ {
+ return functor_(
+ enqueueArgs,
+ arg0,
+ arg1,
+ arg2,
+ arg3,
+ arg4,
+ arg5,
+ arg6,
+ arg7,
+ arg8,
+ arg9,
+ arg10,
+ arg11,
+ arg12,
+ arg13,
+ arg14,
+ arg15,
+ arg16,
+ arg17,
+ arg18,
+ arg19,
+ arg20,
+ arg21,
+ arg22,
+ arg23,
+ arg24,
+ arg25,
+ arg26);
+ }
+
+
+};
+
+template<
+ typename T0,
+ typename T1,
+ typename T2,
+ typename T3,
+ typename T4,
+ typename T5,
+ typename T6,
+ typename T7,
+ typename T8,
+ typename T9,
+ typename T10,
+ typename T11,
+ typename T12,
+ typename T13,
+ typename T14,
+ typename T15,
+ typename T16,
+ typename T17,
+ typename T18,
+ typename T19,
+ typename T20,
+ typename T21,
+ typename T22,
+ typename T23,
+ typename T24,
+ typename T25>
+struct functionImplementation_
+< T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11,
+ T12,
+ T13,
+ T14,
+ T15,
+ T16,
+ T17,
+ T18,
+ T19,
+ T20,
+ T21,
+ T22,
+ T23,
+ T24,
+ T25,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType>
+{
+ typedef detail::KernelFunctorGlobal<
+ T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11,
+ T12,
+ T13,
+ T14,
+ T15,
+ T16,
+ T17,
+ T18,
+ T19,
+ T20,
+ T21,
+ T22,
+ T23,
+ T24,
+ T25,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType> FunctorType;
+
+ FunctorType functor_;
+
+ functionImplementation_(const FunctorType &functor) :
+ functor_(functor)
+ {
+
+ #if (defined(_WIN32) && defined(_VARIADIC_MAX) && (_VARIADIC_MAX < 26))
+ // Fail variadic expansion for dev11
+ static_assert(0, "Visual Studio has a hard limit of argument count for a std::function expansion. Please define _VARIADIC_MAX to be 10. If you need more arguments than that VC12 and below cannot support it.");
+ #endif
+
+ }
+
+ //! \brief Return type of the functor
+ typedef Event result_type;
+
+ //! \brief Function signature of kernel functor with no event dependency.
+ typedef Event type_(
+ const EnqueueArgs&,
+ T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11,
+ T12,
+ T13,
+ T14,
+ T15,
+ T16,
+ T17,
+ T18,
+ T19,
+ T20,
+ T21,
+ T22,
+ T23,
+ T24,
+ T25);
+
+ Event operator()(
+ const EnqueueArgs& enqueueArgs,
+ T0 arg0,
+ T1 arg1,
+ T2 arg2,
+ T3 arg3,
+ T4 arg4,
+ T5 arg5,
+ T6 arg6,
+ T7 arg7,
+ T8 arg8,
+ T9 arg9,
+ T10 arg10,
+ T11 arg11,
+ T12 arg12,
+ T13 arg13,
+ T14 arg14,
+ T15 arg15,
+ T16 arg16,
+ T17 arg17,
+ T18 arg18,
+ T19 arg19,
+ T20 arg20,
+ T21 arg21,
+ T22 arg22,
+ T23 arg23,
+ T24 arg24,
+ T25 arg25)
+ {
+ return functor_(
+ enqueueArgs,
+ arg0,
+ arg1,
+ arg2,
+ arg3,
+ arg4,
+ arg5,
+ arg6,
+ arg7,
+ arg8,
+ arg9,
+ arg10,
+ arg11,
+ arg12,
+ arg13,
+ arg14,
+ arg15,
+ arg16,
+ arg17,
+ arg18,
+ arg19,
+ arg20,
+ arg21,
+ arg22,
+ arg23,
+ arg24,
+ arg25);
+ }
+
+
+};
+
+template<
+ typename T0,
+ typename T1,
+ typename T2,
+ typename T3,
+ typename T4,
+ typename T5,
+ typename T6,
+ typename T7,
+ typename T8,
+ typename T9,
+ typename T10,
+ typename T11,
+ typename T12,
+ typename T13,
+ typename T14,
+ typename T15,
+ typename T16,
+ typename T17,
+ typename T18,
+ typename T19,
+ typename T20,
+ typename T21,
+ typename T22,
+ typename T23,
+ typename T24>
+struct functionImplementation_
+< T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11,
+ T12,
+ T13,
+ T14,
+ T15,
+ T16,
+ T17,
+ T18,
+ T19,
+ T20,
+ T21,
+ T22,
+ T23,
+ T24,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType>
+{
+ typedef detail::KernelFunctorGlobal<
+ T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11,
+ T12,
+ T13,
+ T14,
+ T15,
+ T16,
+ T17,
+ T18,
+ T19,
+ T20,
+ T21,
+ T22,
+ T23,
+ T24,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType> FunctorType;
+
+ FunctorType functor_;
+
+ functionImplementation_(const FunctorType &functor) :
+ functor_(functor)
+ {
+
+ #if (defined(_WIN32) && defined(_VARIADIC_MAX) && (_VARIADIC_MAX < 25))
+ // Fail variadic expansion for dev11
+ static_assert(0, "Visual Studio has a hard limit of argument count for a std::function expansion. Please define _VARIADIC_MAX to be 10. If you need more arguments than that VC12 and below cannot support it.");
+ #endif
+
+ }
+
+ //! \brief Return type of the functor
+ typedef Event result_type;
+
+ //! \brief Function signature of kernel functor with no event dependency.
+ typedef Event type_(
+ const EnqueueArgs&,
+ T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11,
+ T12,
+ T13,
+ T14,
+ T15,
+ T16,
+ T17,
+ T18,
+ T19,
+ T20,
+ T21,
+ T22,
+ T23,
+ T24);
+
+ Event operator()(
+ const EnqueueArgs& enqueueArgs,
+ T0 arg0,
+ T1 arg1,
+ T2 arg2,
+ T3 arg3,
+ T4 arg4,
+ T5 arg5,
+ T6 arg6,
+ T7 arg7,
+ T8 arg8,
+ T9 arg9,
+ T10 arg10,
+ T11 arg11,
+ T12 arg12,
+ T13 arg13,
+ T14 arg14,
+ T15 arg15,
+ T16 arg16,
+ T17 arg17,
+ T18 arg18,
+ T19 arg19,
+ T20 arg20,
+ T21 arg21,
+ T22 arg22,
+ T23 arg23,
+ T24 arg24)
+ {
+ return functor_(
+ enqueueArgs,
+ arg0,
+ arg1,
+ arg2,
+ arg3,
+ arg4,
+ arg5,
+ arg6,
+ arg7,
+ arg8,
+ arg9,
+ arg10,
+ arg11,
+ arg12,
+ arg13,
+ arg14,
+ arg15,
+ arg16,
+ arg17,
+ arg18,
+ arg19,
+ arg20,
+ arg21,
+ arg22,
+ arg23,
+ arg24);
+ }
+
+
+};
+
+template<
+ typename T0,
+ typename T1,
+ typename T2,
+ typename T3,
+ typename T4,
+ typename T5,
+ typename T6,
+ typename T7,
+ typename T8,
+ typename T9,
+ typename T10,
+ typename T11,
+ typename T12,
+ typename T13,
+ typename T14,
+ typename T15,
+ typename T16,
+ typename T17,
+ typename T18,
+ typename T19,
+ typename T20,
+ typename T21,
+ typename T22,
+ typename T23>
+struct functionImplementation_
+< T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11,
+ T12,
+ T13,
+ T14,
+ T15,
+ T16,
+ T17,
+ T18,
+ T19,
+ T20,
+ T21,
+ T22,
+ T23,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType>
+{
+ typedef detail::KernelFunctorGlobal<
+ T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11,
+ T12,
+ T13,
+ T14,
+ T15,
+ T16,
+ T17,
+ T18,
+ T19,
+ T20,
+ T21,
+ T22,
+ T23,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType> FunctorType;
+
+ FunctorType functor_;
+
+ functionImplementation_(const FunctorType &functor) :
+ functor_(functor)
+ {
+
+ #if (defined(_WIN32) && defined(_VARIADIC_MAX) && (_VARIADIC_MAX < 24))
+ // Fail variadic expansion for dev11
+ static_assert(0, "Visual Studio has a hard limit of argument count for a std::function expansion. Please define _VARIADIC_MAX to be 10. If you need more arguments than that VC12 and below cannot support it.");
+ #endif
+
+ }
+
+ //! \brief Return type of the functor
+ typedef Event result_type;
+
+ //! \brief Function signature of kernel functor with no event dependency.
+ typedef Event type_(
+ const EnqueueArgs&,
+ T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11,
+ T12,
+ T13,
+ T14,
+ T15,
+ T16,
+ T17,
+ T18,
+ T19,
+ T20,
+ T21,
+ T22,
+ T23);
+
+ Event operator()(
+ const EnqueueArgs& enqueueArgs,
+ T0 arg0,
+ T1 arg1,
+ T2 arg2,
+ T3 arg3,
+ T4 arg4,
+ T5 arg5,
+ T6 arg6,
+ T7 arg7,
+ T8 arg8,
+ T9 arg9,
+ T10 arg10,
+ T11 arg11,
+ T12 arg12,
+ T13 arg13,
+ T14 arg14,
+ T15 arg15,
+ T16 arg16,
+ T17 arg17,
+ T18 arg18,
+ T19 arg19,
+ T20 arg20,
+ T21 arg21,
+ T22 arg22,
+ T23 arg23)
+ {
+ return functor_(
+ enqueueArgs,
+ arg0,
+ arg1,
+ arg2,
+ arg3,
+ arg4,
+ arg5,
+ arg6,
+ arg7,
+ arg8,
+ arg9,
+ arg10,
+ arg11,
+ arg12,
+ arg13,
+ arg14,
+ arg15,
+ arg16,
+ arg17,
+ arg18,
+ arg19,
+ arg20,
+ arg21,
+ arg22,
+ arg23);
+ }
+
+
+};
+
+template<
+ typename T0,
+ typename T1,
+ typename T2,
+ typename T3,
+ typename T4,
+ typename T5,
+ typename T6,
+ typename T7,
+ typename T8,
+ typename T9,
+ typename T10,
+ typename T11,
+ typename T12,
+ typename T13,
+ typename T14,
+ typename T15,
+ typename T16,
+ typename T17,
+ typename T18,
+ typename T19,
+ typename T20,
+ typename T21,
+ typename T22>
+struct functionImplementation_
+< T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11,
+ T12,
+ T13,
+ T14,
+ T15,
+ T16,
+ T17,
+ T18,
+ T19,
+ T20,
+ T21,
+ T22,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType>
+{
+ typedef detail::KernelFunctorGlobal<
+ T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11,
+ T12,
+ T13,
+ T14,
+ T15,
+ T16,
+ T17,
+ T18,
+ T19,
+ T20,
+ T21,
+ T22,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType> FunctorType;
+
+ FunctorType functor_;
+
+ functionImplementation_(const FunctorType &functor) :
+ functor_(functor)
+ {
+
+ #if (defined(_WIN32) && defined(_VARIADIC_MAX) && (_VARIADIC_MAX < 23))
+ // Fail variadic expansion for dev11
+ static_assert(0, "Visual Studio has a hard limit of argument count for a std::function expansion. Please define _VARIADIC_MAX to be 10. If you need more arguments than that VC12 and below cannot support it.");
+ #endif
+
+ }
+
+ //! \brief Return type of the functor
+ typedef Event result_type;
+
+ //! \brief Function signature of kernel functor with no event dependency.
+ typedef Event type_(
+ const EnqueueArgs&,
+ T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11,
+ T12,
+ T13,
+ T14,
+ T15,
+ T16,
+ T17,
+ T18,
+ T19,
+ T20,
+ T21,
+ T22);
+
+ Event operator()(
+ const EnqueueArgs& enqueueArgs,
+ T0 arg0,
+ T1 arg1,
+ T2 arg2,
+ T3 arg3,
+ T4 arg4,
+ T5 arg5,
+ T6 arg6,
+ T7 arg7,
+ T8 arg8,
+ T9 arg9,
+ T10 arg10,
+ T11 arg11,
+ T12 arg12,
+ T13 arg13,
+ T14 arg14,
+ T15 arg15,
+ T16 arg16,
+ T17 arg17,
+ T18 arg18,
+ T19 arg19,
+ T20 arg20,
+ T21 arg21,
+ T22 arg22)
+ {
+ return functor_(
+ enqueueArgs,
+ arg0,
+ arg1,
+ arg2,
+ arg3,
+ arg4,
+ arg5,
+ arg6,
+ arg7,
+ arg8,
+ arg9,
+ arg10,
+ arg11,
+ arg12,
+ arg13,
+ arg14,
+ arg15,
+ arg16,
+ arg17,
+ arg18,
+ arg19,
+ arg20,
+ arg21,
+ arg22);
+ }
+
+
+};
+
+template<
+ typename T0,
+ typename T1,
+ typename T2,
+ typename T3,
+ typename T4,
+ typename T5,
+ typename T6,
+ typename T7,
+ typename T8,
+ typename T9,
+ typename T10,
+ typename T11,
+ typename T12,
+ typename T13,
+ typename T14,
+ typename T15,
+ typename T16,
+ typename T17,
+ typename T18,
+ typename T19,
+ typename T20,
+ typename T21>
+struct functionImplementation_
+< T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11,
+ T12,
+ T13,
+ T14,
+ T15,
+ T16,
+ T17,
+ T18,
+ T19,
+ T20,
+ T21,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType>
+{
+ typedef detail::KernelFunctorGlobal<
+ T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11,
+ T12,
+ T13,
+ T14,
+ T15,
+ T16,
+ T17,
+ T18,
+ T19,
+ T20,
+ T21,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType> FunctorType;
+
+ FunctorType functor_;
+
+ functionImplementation_(const FunctorType &functor) :
+ functor_(functor)
+ {
+
+ #if (defined(_WIN32) && defined(_VARIADIC_MAX) && (_VARIADIC_MAX < 22))
+ // Fail variadic expansion for dev11
+ static_assert(0, "Visual Studio has a hard limit of argument count for a std::function expansion. Please define _VARIADIC_MAX to be 10. If you need more arguments than that VC12 and below cannot support it.");
+ #endif
+
+ }
+
+ //! \brief Return type of the functor
+ typedef Event result_type;
+
+ //! \brief Function signature of kernel functor with no event dependency.
+ typedef Event type_(
+ const EnqueueArgs&,
+ T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11,
+ T12,
+ T13,
+ T14,
+ T15,
+ T16,
+ T17,
+ T18,
+ T19,
+ T20,
+ T21);
+
+ Event operator()(
+ const EnqueueArgs& enqueueArgs,
+ T0 arg0,
+ T1 arg1,
+ T2 arg2,
+ T3 arg3,
+ T4 arg4,
+ T5 arg5,
+ T6 arg6,
+ T7 arg7,
+ T8 arg8,
+ T9 arg9,
+ T10 arg10,
+ T11 arg11,
+ T12 arg12,
+ T13 arg13,
+ T14 arg14,
+ T15 arg15,
+ T16 arg16,
+ T17 arg17,
+ T18 arg18,
+ T19 arg19,
+ T20 arg20,
+ T21 arg21)
+ {
+ return functor_(
+ enqueueArgs,
+ arg0,
+ arg1,
+ arg2,
+ arg3,
+ arg4,
+ arg5,
+ arg6,
+ arg7,
+ arg8,
+ arg9,
+ arg10,
+ arg11,
+ arg12,
+ arg13,
+ arg14,
+ arg15,
+ arg16,
+ arg17,
+ arg18,
+ arg19,
+ arg20,
+ arg21);
+ }
+
+
+};
+
+template<
+ typename T0,
+ typename T1,
+ typename T2,
+ typename T3,
+ typename T4,
+ typename T5,
+ typename T6,
+ typename T7,
+ typename T8,
+ typename T9,
+ typename T10,
+ typename T11,
+ typename T12,
+ typename T13,
+ typename T14,
+ typename T15,
+ typename T16,
+ typename T17,
+ typename T18,
+ typename T19,
+ typename T20>
+struct functionImplementation_
+< T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11,
+ T12,
+ T13,
+ T14,
+ T15,
+ T16,
+ T17,
+ T18,
+ T19,
+ T20,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType>
+{
+ typedef detail::KernelFunctorGlobal<
+ T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11,
+ T12,
+ T13,
+ T14,
+ T15,
+ T16,
+ T17,
+ T18,
+ T19,
+ T20,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType> FunctorType;
+
+ FunctorType functor_;
+
+ functionImplementation_(const FunctorType &functor) :
+ functor_(functor)
+ {
+
+ #if (defined(_WIN32) && defined(_VARIADIC_MAX) && (_VARIADIC_MAX < 21))
+ // Fail variadic expansion for dev11
+ static_assert(0, "Visual Studio has a hard limit of argument count for a std::function expansion. Please define _VARIADIC_MAX to be 10. If you need more arguments than that VC12 and below cannot support it.");
+ #endif
+
+ }
+
+ //! \brief Return type of the functor
+ typedef Event result_type;
+
+ //! \brief Function signature of kernel functor with no event dependency.
+ typedef Event type_(
+ const EnqueueArgs&,
+ T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11,
+ T12,
+ T13,
+ T14,
+ T15,
+ T16,
+ T17,
+ T18,
+ T19,
+ T20);
+
+ Event operator()(
+ const EnqueueArgs& enqueueArgs,
+ T0 arg0,
+ T1 arg1,
+ T2 arg2,
+ T3 arg3,
+ T4 arg4,
+ T5 arg5,
+ T6 arg6,
+ T7 arg7,
+ T8 arg8,
+ T9 arg9,
+ T10 arg10,
+ T11 arg11,
+ T12 arg12,
+ T13 arg13,
+ T14 arg14,
+ T15 arg15,
+ T16 arg16,
+ T17 arg17,
+ T18 arg18,
+ T19 arg19,
+ T20 arg20)
+ {
+ return functor_(
+ enqueueArgs,
+ arg0,
+ arg1,
+ arg2,
+ arg3,
+ arg4,
+ arg5,
+ arg6,
+ arg7,
+ arg8,
+ arg9,
+ arg10,
+ arg11,
+ arg12,
+ arg13,
+ arg14,
+ arg15,
+ arg16,
+ arg17,
+ arg18,
+ arg19,
+ arg20);
+ }
+
+
+};
+
+template<
+ typename T0,
+ typename T1,
+ typename T2,
+ typename T3,
+ typename T4,
+ typename T5,
+ typename T6,
+ typename T7,
+ typename T8,
+ typename T9,
+ typename T10,
+ typename T11,
+ typename T12,
+ typename T13,
+ typename T14,
+ typename T15,
+ typename T16,
+ typename T17,
+ typename T18,
+ typename T19>
+struct functionImplementation_
+< T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11,
+ T12,
+ T13,
+ T14,
+ T15,
+ T16,
+ T17,
+ T18,
+ T19,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType>
+{
+ typedef detail::KernelFunctorGlobal<
+ T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11,
+ T12,
+ T13,
+ T14,
+ T15,
+ T16,
+ T17,
+ T18,
+ T19,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType> FunctorType;
+
+ FunctorType functor_;
+
+ functionImplementation_(const FunctorType &functor) :
+ functor_(functor)
+ {
+
+ #if (defined(_WIN32) && defined(_VARIADIC_MAX) && (_VARIADIC_MAX < 20))
+ // Fail variadic expansion for dev11
+ static_assert(0, "Visual Studio has a hard limit of argument count for a std::function expansion. Please define _VARIADIC_MAX to be 10. If you need more arguments than that VC12 and below cannot support it.");
+ #endif
+
+ }
+
+ //! \brief Return type of the functor
+ typedef Event result_type;
+
+ //! \brief Function signature of kernel functor with no event dependency.
+ typedef Event type_(
+ const EnqueueArgs&,
+ T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11,
+ T12,
+ T13,
+ T14,
+ T15,
+ T16,
+ T17,
+ T18,
+ T19);
+
+ Event operator()(
+ const EnqueueArgs& enqueueArgs,
+ T0 arg0,
+ T1 arg1,
+ T2 arg2,
+ T3 arg3,
+ T4 arg4,
+ T5 arg5,
+ T6 arg6,
+ T7 arg7,
+ T8 arg8,
+ T9 arg9,
+ T10 arg10,
+ T11 arg11,
+ T12 arg12,
+ T13 arg13,
+ T14 arg14,
+ T15 arg15,
+ T16 arg16,
+ T17 arg17,
+ T18 arg18,
+ T19 arg19)
+ {
+ return functor_(
+ enqueueArgs,
+ arg0,
+ arg1,
+ arg2,
+ arg3,
+ arg4,
+ arg5,
+ arg6,
+ arg7,
+ arg8,
+ arg9,
+ arg10,
+ arg11,
+ arg12,
+ arg13,
+ arg14,
+ arg15,
+ arg16,
+ arg17,
+ arg18,
+ arg19);
+ }
+
+
+};
+
+template<
+ typename T0,
+ typename T1,
+ typename T2,
+ typename T3,
+ typename T4,
+ typename T5,
+ typename T6,
+ typename T7,
+ typename T8,
+ typename T9,
+ typename T10,
+ typename T11,
+ typename T12,
+ typename T13,
+ typename T14,
+ typename T15,
+ typename T16,
+ typename T17,
+ typename T18>
+struct functionImplementation_
+< T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11,
+ T12,
+ T13,
+ T14,
+ T15,
+ T16,
+ T17,
+ T18,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType>
+{
+ typedef detail::KernelFunctorGlobal<
+ T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11,
+ T12,
+ T13,
+ T14,
+ T15,
+ T16,
+ T17,
+ T18,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType> FunctorType;
+
+ FunctorType functor_;
+
+ functionImplementation_(const FunctorType &functor) :
+ functor_(functor)
+ {
+
+ #if (defined(_WIN32) && defined(_VARIADIC_MAX) && (_VARIADIC_MAX < 19))
+ // Fail variadic expansion for dev11
+ static_assert(0, "Visual Studio has a hard limit of argument count for a std::function expansion. Please define _VARIADIC_MAX to be 10. If you need more arguments than that VC12 and below cannot support it.");
+ #endif
+
+ }
+
+ //! \brief Return type of the functor
+ typedef Event result_type;
+
+ //! \brief Function signature of kernel functor with no event dependency.
+ typedef Event type_(
+ const EnqueueArgs&,
+ T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11,
+ T12,
+ T13,
+ T14,
+ T15,
+ T16,
+ T17,
+ T18);
+
+ Event operator()(
+ const EnqueueArgs& enqueueArgs,
+ T0 arg0,
+ T1 arg1,
+ T2 arg2,
+ T3 arg3,
+ T4 arg4,
+ T5 arg5,
+ T6 arg6,
+ T7 arg7,
+ T8 arg8,
+ T9 arg9,
+ T10 arg10,
+ T11 arg11,
+ T12 arg12,
+ T13 arg13,
+ T14 arg14,
+ T15 arg15,
+ T16 arg16,
+ T17 arg17,
+ T18 arg18)
+ {
+ return functor_(
+ enqueueArgs,
+ arg0,
+ arg1,
+ arg2,
+ arg3,
+ arg4,
+ arg5,
+ arg6,
+ arg7,
+ arg8,
+ arg9,
+ arg10,
+ arg11,
+ arg12,
+ arg13,
+ arg14,
+ arg15,
+ arg16,
+ arg17,
+ arg18);
+ }
+
+
+};
+
+template<
+ typename T0,
+ typename T1,
+ typename T2,
+ typename T3,
+ typename T4,
+ typename T5,
+ typename T6,
+ typename T7,
+ typename T8,
+ typename T9,
+ typename T10,
+ typename T11,
+ typename T12,
+ typename T13,
+ typename T14,
+ typename T15,
+ typename T16,
+ typename T17>
+struct functionImplementation_
+< T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11,
+ T12,
+ T13,
+ T14,
+ T15,
+ T16,
+ T17,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType>
+{
+ typedef detail::KernelFunctorGlobal<
+ T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11,
+ T12,
+ T13,
+ T14,
+ T15,
+ T16,
+ T17,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType> FunctorType;
+
+ FunctorType functor_;
+
+ functionImplementation_(const FunctorType &functor) :
+ functor_(functor)
+ {
+
+ #if (defined(_WIN32) && defined(_VARIADIC_MAX) && (_VARIADIC_MAX < 18))
+ // Fail variadic expansion for dev11
+ static_assert(0, "Visual Studio has a hard limit of argument count for a std::function expansion. Please define _VARIADIC_MAX to be 10. If you need more arguments than that VC12 and below cannot support it.");
+ #endif
+
+ }
+
+ //! \brief Return type of the functor
+ typedef Event result_type;
+
+ //! \brief Function signature of kernel functor with no event dependency.
+ typedef Event type_(
+ const EnqueueArgs&,
+ T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11,
+ T12,
+ T13,
+ T14,
+ T15,
+ T16,
+ T17);
+
+ Event operator()(
+ const EnqueueArgs& enqueueArgs,
+ T0 arg0,
+ T1 arg1,
+ T2 arg2,
+ T3 arg3,
+ T4 arg4,
+ T5 arg5,
+ T6 arg6,
+ T7 arg7,
+ T8 arg8,
+ T9 arg9,
+ T10 arg10,
+ T11 arg11,
+ T12 arg12,
+ T13 arg13,
+ T14 arg14,
+ T15 arg15,
+ T16 arg16,
+ T17 arg17)
+ {
+ return functor_(
+ enqueueArgs,
+ arg0,
+ arg1,
+ arg2,
+ arg3,
+ arg4,
+ arg5,
+ arg6,
+ arg7,
+ arg8,
+ arg9,
+ arg10,
+ arg11,
+ arg12,
+ arg13,
+ arg14,
+ arg15,
+ arg16,
+ arg17);
+ }
+
+
+};
+
+template<
+ typename T0,
+ typename T1,
+ typename T2,
+ typename T3,
+ typename T4,
+ typename T5,
+ typename T6,
+ typename T7,
+ typename T8,
+ typename T9,
+ typename T10,
+ typename T11,
+ typename T12,
+ typename T13,
+ typename T14,
+ typename T15,
+ typename T16>
+struct functionImplementation_
+< T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11,
+ T12,
+ T13,
+ T14,
+ T15,
+ T16,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType>
+{
+ typedef detail::KernelFunctorGlobal<
+ T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11,
+ T12,
+ T13,
+ T14,
+ T15,
+ T16,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType> FunctorType;
+
+ FunctorType functor_;
+
+ functionImplementation_(const FunctorType &functor) :
+ functor_(functor)
+ {
+
+ #if (defined(_WIN32) && defined(_VARIADIC_MAX) && (_VARIADIC_MAX < 17))
+ // Fail variadic expansion for dev11
+ static_assert(0, "Visual Studio has a hard limit of argument count for a std::function expansion. Please define _VARIADIC_MAX to be 10. If you need more arguments than that VC12 and below cannot support it.");
+ #endif
+
+ }
+
+ //! \brief Return type of the functor
+ typedef Event result_type;
+
+ //! \brief Function signature of kernel functor with no event dependency.
+ typedef Event type_(
+ const EnqueueArgs&,
+ T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11,
+ T12,
+ T13,
+ T14,
+ T15,
+ T16);
+
+ Event operator()(
+ const EnqueueArgs& enqueueArgs,
+ T0 arg0,
+ T1 arg1,
+ T2 arg2,
+ T3 arg3,
+ T4 arg4,
+ T5 arg5,
+ T6 arg6,
+ T7 arg7,
+ T8 arg8,
+ T9 arg9,
+ T10 arg10,
+ T11 arg11,
+ T12 arg12,
+ T13 arg13,
+ T14 arg14,
+ T15 arg15,
+ T16 arg16)
+ {
+ return functor_(
+ enqueueArgs,
+ arg0,
+ arg1,
+ arg2,
+ arg3,
+ arg4,
+ arg5,
+ arg6,
+ arg7,
+ arg8,
+ arg9,
+ arg10,
+ arg11,
+ arg12,
+ arg13,
+ arg14,
+ arg15,
+ arg16);
+ }
+
+
+};
+
+template<
+ typename T0,
+ typename T1,
+ typename T2,
+ typename T3,
+ typename T4,
+ typename T5,
+ typename T6,
+ typename T7,
+ typename T8,
+ typename T9,
+ typename T10,
+ typename T11,
+ typename T12,
+ typename T13,
+ typename T14,
+ typename T15>
+struct functionImplementation_
+< T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11,
+ T12,
+ T13,
+ T14,
+ T15,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType>
+{
+ typedef detail::KernelFunctorGlobal<
+ T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11,
+ T12,
+ T13,
+ T14,
+ T15,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType> FunctorType;
+
+ FunctorType functor_;
+
+ functionImplementation_(const FunctorType &functor) :
+ functor_(functor)
+ {
+
+ #if (defined(_WIN32) && defined(_VARIADIC_MAX) && (_VARIADIC_MAX < 16))
+ // Fail variadic expansion for dev11
+ static_assert(0, "Visual Studio has a hard limit of argument count for a std::function expansion. Please define _VARIADIC_MAX to be 10. If you need more arguments than that VC12 and below cannot support it.");
+ #endif
+
+ }
+
+ //! \brief Return type of the functor
+ typedef Event result_type;
+
+ //! \brief Function signature of kernel functor with no event dependency.
+ typedef Event type_(
+ const EnqueueArgs&,
+ T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11,
+ T12,
+ T13,
+ T14,
+ T15);
+
+ Event operator()(
+ const EnqueueArgs& enqueueArgs,
+ T0 arg0,
+ T1 arg1,
+ T2 arg2,
+ T3 arg3,
+ T4 arg4,
+ T5 arg5,
+ T6 arg6,
+ T7 arg7,
+ T8 arg8,
+ T9 arg9,
+ T10 arg10,
+ T11 arg11,
+ T12 arg12,
+ T13 arg13,
+ T14 arg14,
+ T15 arg15)
+ {
+ return functor_(
+ enqueueArgs,
+ arg0,
+ arg1,
+ arg2,
+ arg3,
+ arg4,
+ arg5,
+ arg6,
+ arg7,
+ arg8,
+ arg9,
+ arg10,
+ arg11,
+ arg12,
+ arg13,
+ arg14,
+ arg15);
+ }
+
+
+};
+
+template<
+ typename T0,
+ typename T1,
+ typename T2,
+ typename T3,
+ typename T4,
+ typename T5,
+ typename T6,
+ typename T7,
+ typename T8,
+ typename T9,
+ typename T10,
+ typename T11,
+ typename T12,
+ typename T13,
+ typename T14>
+struct functionImplementation_
+< T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11,
+ T12,
+ T13,
+ T14,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType>
+{
+ typedef detail::KernelFunctorGlobal<
+ T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11,
+ T12,
+ T13,
+ T14,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType> FunctorType;
+
+ FunctorType functor_;
+
+ functionImplementation_(const FunctorType &functor) :
+ functor_(functor)
+ {
+
+ #if (defined(_WIN32) && defined(_VARIADIC_MAX) && (_VARIADIC_MAX < 15))
+ // Fail variadic expansion for dev11
+ static_assert(0, "Visual Studio has a hard limit of argument count for a std::function expansion. Please define _VARIADIC_MAX to be 10. If you need more arguments than that VC12 and below cannot support it.");
+ #endif
+
+ }
+
+ //! \brief Return type of the functor
+ typedef Event result_type;
+
+ //! \brief Function signature of kernel functor with no event dependency.
+ typedef Event type_(
+ const EnqueueArgs&,
+ T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11,
+ T12,
+ T13,
+ T14);
+
+ Event operator()(
+ const EnqueueArgs& enqueueArgs,
+ T0 arg0,
+ T1 arg1,
+ T2 arg2,
+ T3 arg3,
+ T4 arg4,
+ T5 arg5,
+ T6 arg6,
+ T7 arg7,
+ T8 arg8,
+ T9 arg9,
+ T10 arg10,
+ T11 arg11,
+ T12 arg12,
+ T13 arg13,
+ T14 arg14)
+ {
+ return functor_(
+ enqueueArgs,
+ arg0,
+ arg1,
+ arg2,
+ arg3,
+ arg4,
+ arg5,
+ arg6,
+ arg7,
+ arg8,
+ arg9,
+ arg10,
+ arg11,
+ arg12,
+ arg13,
+ arg14);
+ }
+
+
+};
+
+template<
+ typename T0,
+ typename T1,
+ typename T2,
+ typename T3,
+ typename T4,
+ typename T5,
+ typename T6,
+ typename T7,
+ typename T8,
+ typename T9,
+ typename T10,
+ typename T11,
+ typename T12,
+ typename T13>
+struct functionImplementation_
+< T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11,
+ T12,
+ T13,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType>
+{
+ typedef detail::KernelFunctorGlobal<
+ T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11,
+ T12,
+ T13,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType> FunctorType;
+
+ FunctorType functor_;
+
+ functionImplementation_(const FunctorType &functor) :
+ functor_(functor)
+ {
+
+ #if (defined(_WIN32) && defined(_VARIADIC_MAX) && (_VARIADIC_MAX < 14))
+ // Fail variadic expansion for dev11
+ static_assert(0, "Visual Studio has a hard limit of argument count for a std::function expansion. Please define _VARIADIC_MAX to be 10. If you need more arguments than that VC12 and below cannot support it.");
+ #endif
+
+ }
+
+ //! \brief Return type of the functor
+ typedef Event result_type;
+
+ //! \brief Function signature of kernel functor with no event dependency.
+ typedef Event type_(
+ const EnqueueArgs&,
+ T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11,
+ T12,
+ T13);
+
+ Event operator()(
+ const EnqueueArgs& enqueueArgs,
+ T0 arg0,
+ T1 arg1,
+ T2 arg2,
+ T3 arg3,
+ T4 arg4,
+ T5 arg5,
+ T6 arg6,
+ T7 arg7,
+ T8 arg8,
+ T9 arg9,
+ T10 arg10,
+ T11 arg11,
+ T12 arg12,
+ T13 arg13)
+ {
+ return functor_(
+ enqueueArgs,
+ arg0,
+ arg1,
+ arg2,
+ arg3,
+ arg4,
+ arg5,
+ arg6,
+ arg7,
+ arg8,
+ arg9,
+ arg10,
+ arg11,
+ arg12,
+ arg13);
+ }
+
+
+};
+
+template<
+ typename T0,
+ typename T1,
+ typename T2,
+ typename T3,
+ typename T4,
+ typename T5,
+ typename T6,
+ typename T7,
+ typename T8,
+ typename T9,
+ typename T10,
+ typename T11,
+ typename T12>
+struct functionImplementation_
+< T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11,
+ T12,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType>
+{
+ typedef detail::KernelFunctorGlobal<
+ T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11,
+ T12,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType> FunctorType;
+
+ FunctorType functor_;
+
+ functionImplementation_(const FunctorType &functor) :
+ functor_(functor)
+ {
+
+ #if (defined(_WIN32) && defined(_VARIADIC_MAX) && (_VARIADIC_MAX < 13))
+ // Fail variadic expansion for dev11
+ static_assert(0, "Visual Studio has a hard limit of argument count for a std::function expansion. Please define _VARIADIC_MAX to be 10. If you need more arguments than that VC12 and below cannot support it.");
+ #endif
+
+ }
+
+ //! \brief Return type of the functor
+ typedef Event result_type;
+
+ //! \brief Function signature of kernel functor with no event dependency.
+ typedef Event type_(
+ const EnqueueArgs&,
+ T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11,
+ T12);
+
+ Event operator()(
+ const EnqueueArgs& enqueueArgs,
+ T0 arg0,
+ T1 arg1,
+ T2 arg2,
+ T3 arg3,
+ T4 arg4,
+ T5 arg5,
+ T6 arg6,
+ T7 arg7,
+ T8 arg8,
+ T9 arg9,
+ T10 arg10,
+ T11 arg11,
+ T12 arg12)
+ {
+ return functor_(
+ enqueueArgs,
+ arg0,
+ arg1,
+ arg2,
+ arg3,
+ arg4,
+ arg5,
+ arg6,
+ arg7,
+ arg8,
+ arg9,
+ arg10,
+ arg11,
+ arg12);
+ }
+
+
+};
+
+template<
+ typename T0,
+ typename T1,
+ typename T2,
+ typename T3,
+ typename T4,
+ typename T5,
+ typename T6,
+ typename T7,
+ typename T8,
+ typename T9,
+ typename T10,
+ typename T11>
+struct functionImplementation_
+< T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType>
+{
+ typedef detail::KernelFunctorGlobal<
+ T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType> FunctorType;
+
+ FunctorType functor_;
+
+ functionImplementation_(const FunctorType &functor) :
+ functor_(functor)
+ {
+
+ #if (defined(_WIN32) && defined(_VARIADIC_MAX) && (_VARIADIC_MAX < 12))
+ // Fail variadic expansion for dev11
+ static_assert(0, "Visual Studio has a hard limit of argument count for a std::function expansion. Please define _VARIADIC_MAX to be 10. If you need more arguments than that VC12 and below cannot support it.");
+ #endif
+
+ }
+
+ //! \brief Return type of the functor
+ typedef Event result_type;
+
+ //! \brief Function signature of kernel functor with no event dependency.
+ typedef Event type_(
+ const EnqueueArgs&,
+ T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ T11);
+
+ Event operator()(
+ const EnqueueArgs& enqueueArgs,
+ T0 arg0,
+ T1 arg1,
+ T2 arg2,
+ T3 arg3,
+ T4 arg4,
+ T5 arg5,
+ T6 arg6,
+ T7 arg7,
+ T8 arg8,
+ T9 arg9,
+ T10 arg10,
+ T11 arg11)
+ {
+ return functor_(
+ enqueueArgs,
+ arg0,
+ arg1,
+ arg2,
+ arg3,
+ arg4,
+ arg5,
+ arg6,
+ arg7,
+ arg8,
+ arg9,
+ arg10,
+ arg11);
+ }
+
+
+};
+
+template<
+ typename T0,
+ typename T1,
+ typename T2,
+ typename T3,
+ typename T4,
+ typename T5,
+ typename T6,
+ typename T7,
+ typename T8,
+ typename T9,
+ typename T10>
+struct functionImplementation_
+< T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType>
+{
+ typedef detail::KernelFunctorGlobal<
+ T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType> FunctorType;
+
+ FunctorType functor_;
+
+ functionImplementation_(const FunctorType &functor) :
+ functor_(functor)
+ {
+
+ #if (defined(_WIN32) && defined(_VARIADIC_MAX) && (_VARIADIC_MAX < 11))
+ // Fail variadic expansion for dev11
+ static_assert(0, "Visual Studio has a hard limit of argument count for a std::function expansion. Please define _VARIADIC_MAX to be 10. If you need more arguments than that VC12 and below cannot support it.");
+ #endif
+
+ }
+
+ //! \brief Return type of the functor
+ typedef Event result_type;
+
+ //! \brief Function signature of kernel functor with no event dependency.
+ typedef Event type_(
+ const EnqueueArgs&,
+ T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ T10);
+
+ Event operator()(
+ const EnqueueArgs& enqueueArgs,
+ T0 arg0,
+ T1 arg1,
+ T2 arg2,
+ T3 arg3,
+ T4 arg4,
+ T5 arg5,
+ T6 arg6,
+ T7 arg7,
+ T8 arg8,
+ T9 arg9,
+ T10 arg10)
+ {
+ return functor_(
+ enqueueArgs,
+ arg0,
+ arg1,
+ arg2,
+ arg3,
+ arg4,
+ arg5,
+ arg6,
+ arg7,
+ arg8,
+ arg9,
+ arg10);
+ }
+
+
+};
+
+template<
+ typename T0,
+ typename T1,
+ typename T2,
+ typename T3,
+ typename T4,
+ typename T5,
+ typename T6,
+ typename T7,
+ typename T8,
+ typename T9>
+struct functionImplementation_
+< T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType>
+{
+ typedef detail::KernelFunctorGlobal<
+ T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType> FunctorType;
+
+ FunctorType functor_;
+
+ functionImplementation_(const FunctorType &functor) :
+ functor_(functor)
+ {
+
+ #if (defined(_WIN32) && defined(_VARIADIC_MAX) && (_VARIADIC_MAX < 10))
+ // Fail variadic expansion for dev11
+ static_assert(0, "Visual Studio has a hard limit of argument count for a std::function expansion. Please define _VARIADIC_MAX to be 10. If you need more arguments than that VC12 and below cannot support it.");
+ #endif
+
+ }
+
+ //! \brief Return type of the functor
+ typedef Event result_type;
+
+ //! \brief Function signature of kernel functor with no event dependency.
+ typedef Event type_(
+ const EnqueueArgs&,
+ T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ T9);
+
+ Event operator()(
+ const EnqueueArgs& enqueueArgs,
+ T0 arg0,
+ T1 arg1,
+ T2 arg2,
+ T3 arg3,
+ T4 arg4,
+ T5 arg5,
+ T6 arg6,
+ T7 arg7,
+ T8 arg8,
+ T9 arg9)
+ {
+ return functor_(
+ enqueueArgs,
+ arg0,
+ arg1,
+ arg2,
+ arg3,
+ arg4,
+ arg5,
+ arg6,
+ arg7,
+ arg8,
+ arg9);
+ }
+
+
+};
+
+template<
+ typename T0,
+ typename T1,
+ typename T2,
+ typename T3,
+ typename T4,
+ typename T5,
+ typename T6,
+ typename T7,
+ typename T8>
+struct functionImplementation_
+< T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType>
+{
+ typedef detail::KernelFunctorGlobal<
+ T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType> FunctorType;
+
+ FunctorType functor_;
+
+ functionImplementation_(const FunctorType &functor) :
+ functor_(functor)
+ {
+
+ #if (defined(_WIN32) && defined(_VARIADIC_MAX) && (_VARIADIC_MAX < 9))
+ // Fail variadic expansion for dev11
+ static_assert(0, "Visual Studio has a hard limit of argument count for a std::function expansion. Please define _VARIADIC_MAX to be 10. If you need more arguments than that VC12 and below cannot support it.");
+ #endif
+
+ }
+
+ //! \brief Return type of the functor
+ typedef Event result_type;
+
+ //! \brief Function signature of kernel functor with no event dependency.
+ typedef Event type_(
+ const EnqueueArgs&,
+ T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ T8);
+
+ Event operator()(
+ const EnqueueArgs& enqueueArgs,
+ T0 arg0,
+ T1 arg1,
+ T2 arg2,
+ T3 arg3,
+ T4 arg4,
+ T5 arg5,
+ T6 arg6,
+ T7 arg7,
+ T8 arg8)
+ {
+ return functor_(
+ enqueueArgs,
+ arg0,
+ arg1,
+ arg2,
+ arg3,
+ arg4,
+ arg5,
+ arg6,
+ arg7,
+ arg8);
+ }
+
+
+};
+
+template<
+ typename T0,
+ typename T1,
+ typename T2,
+ typename T3,
+ typename T4,
+ typename T5,
+ typename T6,
+ typename T7>
+struct functionImplementation_
+< T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType>
+{
+ typedef detail::KernelFunctorGlobal<
+ T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType> FunctorType;
+
+ FunctorType functor_;
+
+ functionImplementation_(const FunctorType &functor) :
+ functor_(functor)
+ {
+
+ #if (defined(_WIN32) && defined(_VARIADIC_MAX) && (_VARIADIC_MAX < 8))
+ // Fail variadic expansion for dev11
+ static_assert(0, "Visual Studio has a hard limit of argument count for a std::function expansion. Please define _VARIADIC_MAX to be 10. If you need more arguments than that VC12 and below cannot support it.");
+ #endif
+
+ }
+
+ //! \brief Return type of the functor
+ typedef Event result_type;
+
+ //! \brief Function signature of kernel functor with no event dependency.
+ typedef Event type_(
+ const EnqueueArgs&,
+ T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ T7);
+
+ Event operator()(
+ const EnqueueArgs& enqueueArgs,
+ T0 arg0,
+ T1 arg1,
+ T2 arg2,
+ T3 arg3,
+ T4 arg4,
+ T5 arg5,
+ T6 arg6,
+ T7 arg7)
+ {
+ return functor_(
+ enqueueArgs,
+ arg0,
+ arg1,
+ arg2,
+ arg3,
+ arg4,
+ arg5,
+ arg6,
+ arg7);
+ }
+
+
+};
+
+template<
+ typename T0,
+ typename T1,
+ typename T2,
+ typename T3,
+ typename T4,
+ typename T5,
+ typename T6>
+struct functionImplementation_
+< T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType>
+{
+ typedef detail::KernelFunctorGlobal<
+ T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType> FunctorType;
+
+ FunctorType functor_;
+
+ functionImplementation_(const FunctorType &functor) :
+ functor_(functor)
+ {
+
+ #if (defined(_WIN32) && defined(_VARIADIC_MAX) && (_VARIADIC_MAX < 7))
+ // Fail variadic expansion for dev11
+ static_assert(0, "Visual Studio has a hard limit of argument count for a std::function expansion. Please define _VARIADIC_MAX to be 10. If you need more arguments than that VC12 and below cannot support it.");
+ #endif
+
+ }
+
+ //! \brief Return type of the functor
+ typedef Event result_type;
+
+ //! \brief Function signature of kernel functor with no event dependency.
+ typedef Event type_(
+ const EnqueueArgs&,
+ T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ T6);
+
+ Event operator()(
+ const EnqueueArgs& enqueueArgs,
+ T0 arg0,
+ T1 arg1,
+ T2 arg2,
+ T3 arg3,
+ T4 arg4,
+ T5 arg5,
+ T6 arg6)
+ {
+ return functor_(
+ enqueueArgs,
+ arg0,
+ arg1,
+ arg2,
+ arg3,
+ arg4,
+ arg5,
+ arg6);
+ }
+
+
+};
+
+template<
+ typename T0,
+ typename T1,
+ typename T2,
+ typename T3,
+ typename T4,
+ typename T5>
+struct functionImplementation_
+< T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType>
+{
+ typedef detail::KernelFunctorGlobal<
+ T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType> FunctorType;
+
+ FunctorType functor_;
+
+ functionImplementation_(const FunctorType &functor) :
+ functor_(functor)
+ {
+
+ #if (defined(_WIN32) && defined(_VARIADIC_MAX) && (_VARIADIC_MAX < 6))
+ // Fail variadic expansion for dev11
+ static_assert(0, "Visual Studio has a hard limit of argument count for a std::function expansion. Please define _VARIADIC_MAX to be 10. If you need more arguments than that VC12 and below cannot support it.");
+ #endif
+
+ }
+
+ //! \brief Return type of the functor
+ typedef Event result_type;
+
+ //! \brief Function signature of kernel functor with no event dependency.
+ typedef Event type_(
+ const EnqueueArgs&,
+ T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ T5);
+
+ Event operator()(
+ const EnqueueArgs& enqueueArgs,
+ T0 arg0,
+ T1 arg1,
+ T2 arg2,
+ T3 arg3,
+ T4 arg4,
+ T5 arg5)
+ {
+ return functor_(
+ enqueueArgs,
+ arg0,
+ arg1,
+ arg2,
+ arg3,
+ arg4,
+ arg5);
+ }
+
+
+};
+
+template<
+ typename T0,
+ typename T1,
+ typename T2,
+ typename T3,
+ typename T4>
+struct functionImplementation_
+< T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType>
+{
+ typedef detail::KernelFunctorGlobal<
+ T0,
+ T1,
+ T2,
+ T3,
+ T4,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType> FunctorType;
+
+ FunctorType functor_;
+
+ functionImplementation_(const FunctorType &functor) :
+ functor_(functor)
+ {
+
+ #if (defined(_WIN32) && defined(_VARIADIC_MAX) && (_VARIADIC_MAX < 5))
+ // Fail variadic expansion for dev11
+ static_assert(0, "Visual Studio has a hard limit of argument count for a std::function expansion. Please define _VARIADIC_MAX to be 10. If you need more arguments than that VC12 and below cannot support it.");
+ #endif
+
+ }
+
+ //! \brief Return type of the functor
+ typedef Event result_type;
+
+ //! \brief Function signature of kernel functor with no event dependency.
+ typedef Event type_(
+ const EnqueueArgs&,
+ T0,
+ T1,
+ T2,
+ T3,
+ T4);
+
+ Event operator()(
+ const EnqueueArgs& enqueueArgs,
+ T0 arg0,
+ T1 arg1,
+ T2 arg2,
+ T3 arg3,
+ T4 arg4)
+ {
+ return functor_(
+ enqueueArgs,
+ arg0,
+ arg1,
+ arg2,
+ arg3,
+ arg4);
+ }
+
+
+};
+
+template<
+ typename T0,
+ typename T1,
+ typename T2,
+ typename T3>
+struct functionImplementation_
+< T0,
+ T1,
+ T2,
+ T3,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType>
+{
+ typedef detail::KernelFunctorGlobal<
+ T0,
+ T1,
+ T2,
+ T3,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType> FunctorType;
+
+ FunctorType functor_;
+
+ functionImplementation_(const FunctorType &functor) :
+ functor_(functor)
+ {
+
+ #if (defined(_WIN32) && defined(_VARIADIC_MAX) && (_VARIADIC_MAX < 4))
+ // Fail variadic expansion for dev11
+ static_assert(0, "Visual Studio has a hard limit of argument count for a std::function expansion. Please define _VARIADIC_MAX to be 10. If you need more arguments than that VC12 and below cannot support it.");
+ #endif
+
+ }
+
+ //! \brief Return type of the functor
+ typedef Event result_type;
+
+ //! \brief Function signature of kernel functor with no event dependency.
+ typedef Event type_(
+ const EnqueueArgs&,
+ T0,
+ T1,
+ T2,
+ T3);
+
+ Event operator()(
+ const EnqueueArgs& enqueueArgs,
+ T0 arg0,
+ T1 arg1,
+ T2 arg2,
+ T3 arg3)
+ {
+ return functor_(
+ enqueueArgs,
+ arg0,
+ arg1,
+ arg2,
+ arg3);
+ }
+
+
+};
+
+template<
+ typename T0,
+ typename T1,
+ typename T2>
+struct functionImplementation_
+< T0,
+ T1,
+ T2,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType>
+{
+ typedef detail::KernelFunctorGlobal<
+ T0,
+ T1,
+ T2,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType> FunctorType;
+
+ FunctorType functor_;
+
+ functionImplementation_(const FunctorType &functor) :
+ functor_(functor)
+ {
+
+ #if (defined(_WIN32) && defined(_VARIADIC_MAX) && (_VARIADIC_MAX < 3))
+ // Fail variadic expansion for dev11
+ static_assert(0, "Visual Studio has a hard limit of argument count for a std::function expansion. Please define _VARIADIC_MAX to be 10. If you need more arguments than that VC12 and below cannot support it.");
+ #endif
+
+ }
+
+ //! \brief Return type of the functor
+ typedef Event result_type;
+
+ //! \brief Function signature of kernel functor with no event dependency.
+ typedef Event type_(
+ const EnqueueArgs&,
+ T0,
+ T1,
+ T2);
+
+ Event operator()(
+ const EnqueueArgs& enqueueArgs,
+ T0 arg0,
+ T1 arg1,
+ T2 arg2)
+ {
+ return functor_(
+ enqueueArgs,
+ arg0,
+ arg1,
+ arg2);
+ }
+
+
+};
+
+template<
+ typename T0,
+ typename T1>
+struct functionImplementation_
+< T0,
+ T1,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType>
+{
+ typedef detail::KernelFunctorGlobal<
+ T0,
+ T1,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType> FunctorType;
+
+ FunctorType functor_;
+
+ functionImplementation_(const FunctorType &functor) :
+ functor_(functor)
+ {
+
+ #if (defined(_WIN32) && defined(_VARIADIC_MAX) && (_VARIADIC_MAX < 2))
+ // Fail variadic expansion for dev11
+ static_assert(0, "Visual Studio has a hard limit of argument count for a std::function expansion. Please define _VARIADIC_MAX to be 10. If you need more arguments than that VC12 and below cannot support it.");
+ #endif
+
+ }
+
+ //! \brief Return type of the functor
+ typedef Event result_type;
+
+ //! \brief Function signature of kernel functor with no event dependency.
+ typedef Event type_(
+ const EnqueueArgs&,
+ T0,
+ T1);
+
+ Event operator()(
+ const EnqueueArgs& enqueueArgs,
+ T0 arg0,
+ T1 arg1)
+ {
+ return functor_(
+ enqueueArgs,
+ arg0,
+ arg1);
+ }
+
+
+};
+
+template<
+ typename T0>
+struct functionImplementation_
+< T0,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType>
+{
+ typedef detail::KernelFunctorGlobal<
+ T0,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType,
+ NullType> FunctorType;
+
+ FunctorType functor_;
+
+ functionImplementation_(const FunctorType &functor) :
+ functor_(functor)
+ {
+
+ #if (defined(_WIN32) && defined(_VARIADIC_MAX) && (_VARIADIC_MAX < 1))
+ // Fail variadic expansion for dev11
+ static_assert(0, "Visual Studio has a hard limit of argument count for a std::function expansion. Please define _VARIADIC_MAX to be 10. If you need more arguments than that VC12 and below cannot support it.");
+ #endif
+
+ }
+
+ //! \brief Return type of the functor
+ typedef Event result_type;
+
+ //! \brief Function signature of kernel functor with no event dependency.
+ typedef Event type_(
+ const EnqueueArgs&,
+ T0);
+
+ Event operator()(
+ const EnqueueArgs& enqueueArgs,
+ T0 arg0)
+ {
+ return functor_(
+ enqueueArgs,
+ arg0);
+ }
+
+
+};
+
+
+
+
+
+} // namespace detail
+
+//----------------------------------------------------------------------------------------------
+
+template <
+ typename T0, typename T1 = detail::NullType, typename T2 = detail::NullType,
+ typename T3 = detail::NullType, typename T4 = detail::NullType,
+ typename T5 = detail::NullType, typename T6 = detail::NullType,
+ typename T7 = detail::NullType, typename T8 = detail::NullType,
+ typename T9 = detail::NullType, typename T10 = detail::NullType,
+ typename T11 = detail::NullType, typename T12 = detail::NullType,
+ typename T13 = detail::NullType, typename T14 = detail::NullType,
+ typename T15 = detail::NullType, typename T16 = detail::NullType,
+ typename T17 = detail::NullType, typename T18 = detail::NullType,
+ typename T19 = detail::NullType, typename T20 = detail::NullType,
+ typename T21 = detail::NullType, typename T22 = detail::NullType,
+ typename T23 = detail::NullType, typename T24 = detail::NullType,
+ typename T25 = detail::NullType, typename T26 = detail::NullType,
+ typename T27 = detail::NullType, typename T28 = detail::NullType,
+ typename T29 = detail::NullType, typename T30 = detail::NullType,
+ typename T31 = detail::NullType
+>
+struct make_kernel :
+ public detail::functionImplementation_<
+ T0, T1, T2, T3,
+ T4, T5, T6, T7,
+ T8, T9, T10, T11,
+ T12, T13, T14, T15,
+ T16, T17, T18, T19,
+ T20, T21, T22, T23,
+ T24, T25, T26, T27,
+ T28, T29, T30, T31
+ >
+{
+public:
+ typedef detail::KernelFunctorGlobal<
+ T0, T1, T2, T3,
+ T4, T5, T6, T7,
+ T8, T9, T10, T11,
+ T12, T13, T14, T15,
+ T16, T17, T18, T19,
+ T20, T21, T22, T23,
+ T24, T25, T26, T27,
+ T28, T29, T30, T31
+ > FunctorType;
+
+ make_kernel(
+ const Program& program,
+ const STRING_CLASS name,
+ cl_int * err = NULL) :
+ detail::functionImplementation_<
+ T0, T1, T2, T3,
+ T4, T5, T6, T7,
+ T8, T9, T10, T11,
+ T12, T13, T14, T15,
+ T16, T17, T18, T19,
+ T20, T21, T22, T23,
+ T24, T25, T26, T27,
+ T28, T29, T30, T31
+ >(
+ FunctorType(program, name, err))
+ {}
+
+ make_kernel(
+ const Kernel kernel) :
+ detail::functionImplementation_<
+ T0, T1, T2, T3,
+ T4, T5, T6, T7,
+ T8, T9, T10, T11,
+ T12, T13, T14, T15,
+ T16, T17, T18, T19,
+ T20, T21, T22, T23,
+ T24, T25, T26, T27,
+ T28, T29, T30, T31
+ >(
+ FunctorType(kernel))
+ {}
+};
+
+
+//----------------------------------------------------------------------------------------------------------------------
+
+#undef __ERR_STR
+#if !defined(__CL_USER_OVERRIDE_ERROR_STRINGS)
+#undef __GET_DEVICE_INFO_ERR
+#undef __GET_PLATFORM_INFO_ERR
+#undef __GET_DEVICE_IDS_ERR
+#undef __GET_CONTEXT_INFO_ERR
+#undef __GET_EVENT_INFO_ERR
+#undef __GET_EVENT_PROFILE_INFO_ERR
+#undef __GET_MEM_OBJECT_INFO_ERR
+#undef __GET_IMAGE_INFO_ERR
+#undef __GET_SAMPLER_INFO_ERR
+#undef __GET_KERNEL_INFO_ERR
+#undef __GET_KERNEL_ARG_INFO_ERR
+#undef __GET_KERNEL_WORK_GROUP_INFO_ERR
+#undef __GET_PROGRAM_INFO_ERR
+#undef __GET_PROGRAM_BUILD_INFO_ERR
+#undef __GET_COMMAND_QUEUE_INFO_ERR
+
+#undef __CREATE_CONTEXT_ERR
+#undef __CREATE_CONTEXT_FROM_TYPE_ERR
+#undef __GET_SUPPORTED_IMAGE_FORMATS_ERR
+
+#undef __CREATE_BUFFER_ERR
+#undef __CREATE_SUBBUFFER_ERR
+#undef __CREATE_IMAGE2D_ERR
+#undef __CREATE_IMAGE3D_ERR
+#undef __CREATE_SAMPLER_ERR
+#undef __SET_MEM_OBJECT_DESTRUCTOR_CALLBACK_ERR
+
+#undef __CREATE_USER_EVENT_ERR
+#undef __SET_USER_EVENT_STATUS_ERR
+#undef __SET_EVENT_CALLBACK_ERR
+#undef __SET_PRINTF_CALLBACK_ERR
+
+#undef __WAIT_FOR_EVENTS_ERR
+
+#undef __CREATE_KERNEL_ERR
+#undef __SET_KERNEL_ARGS_ERR
+#undef __CREATE_PROGRAM_WITH_SOURCE_ERR
+#undef __CREATE_PROGRAM_WITH_BINARY_ERR
+#undef __CREATE_PROGRAM_WITH_BUILT_IN_KERNELS_ERR
+#undef __BUILD_PROGRAM_ERR
+#undef __CREATE_KERNELS_IN_PROGRAM_ERR
+
+#undef __CREATE_COMMAND_QUEUE_ERR
+#undef __SET_COMMAND_QUEUE_PROPERTY_ERR
+#undef __ENQUEUE_READ_BUFFER_ERR
+#undef __ENQUEUE_WRITE_BUFFER_ERR
+#undef __ENQUEUE_READ_BUFFER_RECT_ERR
+#undef __ENQUEUE_WRITE_BUFFER_RECT_ERR
+#undef __ENQEUE_COPY_BUFFER_ERR
+#undef __ENQEUE_COPY_BUFFER_RECT_ERR
+#undef __ENQUEUE_READ_IMAGE_ERR
+#undef __ENQUEUE_WRITE_IMAGE_ERR
+#undef __ENQUEUE_COPY_IMAGE_ERR
+#undef __ENQUEUE_COPY_IMAGE_TO_BUFFER_ERR
+#undef __ENQUEUE_COPY_BUFFER_TO_IMAGE_ERR
+#undef __ENQUEUE_MAP_BUFFER_ERR
+#undef __ENQUEUE_MAP_IMAGE_ERR
+#undef __ENQUEUE_UNMAP_MEM_OBJECT_ERR
+#undef __ENQUEUE_NDRANGE_KERNEL_ERR
+#undef __ENQUEUE_TASK_ERR
+#undef __ENQUEUE_NATIVE_KERNEL
+
+#undef __CL_EXPLICIT_CONSTRUCTORS
+
+#undef __UNLOAD_COMPILER_ERR
+#endif //__CL_USER_OVERRIDE_ERROR_STRINGS
+
+#undef __CL_FUNCTION_TYPE
+
+// Extensions
+/**
+ * Deprecated APIs for 1.2
+ */
+#if defined(CL_VERSION_1_1)
+#undef __INIT_CL_EXT_FCN_PTR
+#endif // #if defined(CL_VERSION_1_1)
+#undef __CREATE_SUB_DEVICES
+
+#if defined(USE_CL_DEVICE_FISSION)
+#undef __PARAM_NAME_DEVICE_FISSION
+#endif // USE_CL_DEVICE_FISSION
+
+#undef __DEFAULT_NOT_INITIALIZED
+#undef __DEFAULT_BEING_INITIALIZED
+#undef __DEFAULT_INITIALIZED
+
+#undef CL_HPP_RVALUE_REFERENCES_SUPPORTED
+#undef CL_HPP_NOEXCEPT
+
+} // namespace cl
+
+#endif // CL_HPP_
diff --git a/Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash-cl/ethash_cl_miner.cpp b/Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash-cl/ethash_cl_miner.cpp
new file mode 100644
index 000000000..d3f0e9611
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash-cl/ethash_cl_miner.cpp
@@ -0,0 +1,323 @@
+/*
+ This file is part of c-ethash.
+
+ c-ethash is free software: you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation, either version 3 of the License, or
+ (at your option) any later version.
+
+ c-ethash is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with cpp-ethereum. If not, see <http://www.gnu.org/licenses/>.
+*/
+/** @file ethash_cl_miner.cpp
+* @author Tim Hughes <tim@twistedfury.com>
+* @date 2015
+*/
+
+
+#define _CRT_SECURE_NO_WARNINGS
+
+#include <assert.h>
+#include <queue>
+#include <vector>
+#include "ethash_cl_miner.h"
+#include "ethash_cl_miner_kernel.h"
+#include <libethash/util.h>
+
+#define ETHASH_BYTES 32
+
+// workaround lame platforms
+#if !CL_VERSION_1_2
+#define CL_MAP_WRITE_INVALIDATE_REGION CL_MAP_WRITE
+#define CL_MEM_HOST_READ_ONLY 0
+#endif
+
+#undef min
+#undef max
+
+static void add_definition(std::string& source, char const* id, unsigned value)
+{
+ char buf[256];
+ sprintf(buf, "#define %s %uu\n", id, value);
+ source.insert(source.begin(), buf, buf + strlen(buf));
+}
+
+ethash_cl_miner::ethash_cl_miner()
+: m_opencl_1_1()
+{
+}
+
+bool ethash_cl_miner::init(ethash_params const& params, const uint8_t seed[32], unsigned workgroup_size)
+{
+ // store params
+ m_params = params;
+
+ // get all platforms
+ std::vector<cl::Platform> platforms;
+ cl::Platform::get(&platforms);
+ if (platforms.empty())
+ {
+ debugf("No OpenCL platforms found.\n");
+ return false;
+ }
+
+ // use default platform
+ debugf("Using platform: %s\n", platforms[0].getInfo<CL_PLATFORM_NAME>().c_str());
+
+ // get GPU device of the default platform
+ std::vector<cl::Device> devices;
+ platforms[0].getDevices(CL_DEVICE_TYPE_ALL, &devices);
+ if (devices.empty())
+ {
+ debugf("No OpenCL devices found.\n");
+ return false;
+ }
+
+ // use default device
+ unsigned device_num = 0;
+ cl::Device& device = devices[device_num];
+ std::string device_version = device.getInfo<CL_DEVICE_VERSION>();
+ debugf("Using device: %s (%s)\n", device.getInfo<CL_DEVICE_NAME>().c_str(),device_version.c_str());
+
+ if (strncmp("OpenCL 1.0", device_version.c_str(), 10) == 0)
+ {
+ debugf("OpenCL 1.0 is not supported.\n");
+ return false;
+ }
+ if (strncmp("OpenCL 1.1", device_version.c_str(), 10) == 0)
+ {
+ m_opencl_1_1 = true;
+ }
+
+ // create context
+ m_context = cl::Context(std::vector<cl::Device>(&device, &device+1));
+ m_queue = cl::CommandQueue(m_context, device);
+
+ // use requested workgroup size, but we require multiple of 8
+ m_workgroup_size = ((workgroup_size + 7) / 8) * 8;
+
+ // patch source code
+ std::string code(ETHASH_CL_MINER_KERNEL, ETHASH_CL_MINER_KERNEL + ETHASH_CL_MINER_KERNEL_SIZE);
+ add_definition(code, "GROUP_SIZE", m_workgroup_size);
+ add_definition(code, "DAG_SIZE", (unsigned)(params.full_size / MIX_BYTES));
+ add_definition(code, "ACCESSES", ACCESSES);
+ add_definition(code, "MAX_OUTPUTS", c_max_search_results);
+ //debugf("%s", code.c_str());
+
+ // create miner OpenCL program
+ cl::Program::Sources sources;
+ sources.push_back({code.c_str(), code.size()});
+
+ cl::Program program(m_context, sources);
+ try
+ {
+ program.build({device});
+ }
+ catch (cl::Error err)
+ {
+ debugf("%s\n", program.getBuildInfo<CL_PROGRAM_BUILD_LOG>(device).c_str());
+ return false;
+ }
+ m_hash_kernel = cl::Kernel(program, "ethash_hash");
+ m_search_kernel = cl::Kernel(program, "ethash_search");
+
+ // create buffer for dag
+ m_dag = cl::Buffer(m_context, CL_MEM_READ_ONLY, params.full_size);
+
+ // create buffer for header
+ m_header = cl::Buffer(m_context, CL_MEM_READ_ONLY, 32);
+
+ // compute dag on CPU
+ {
+ void* cache_mem = malloc(params.cache_size + 63);
+ ethash_cache cache;
+ cache.mem = (void*)(((uintptr_t)cache_mem + 63) & ~63);
+ ethash_mkcache(&cache, &params, seed);
+
+ // if this throws then it's because we probably need to subdivide the dag uploads for compatibility
+ void* dag_ptr = m_queue.enqueueMapBuffer(m_dag, true, m_opencl_1_1 ? CL_MAP_WRITE : CL_MAP_WRITE_INVALIDATE_REGION, 0, params.full_size);
+ ethash_compute_full_data(dag_ptr, &params, &cache);
+ m_queue.enqueueUnmapMemObject(m_dag, dag_ptr);
+
+ free(cache_mem);
+ }
+
+ // create mining buffers
+ for (unsigned i = 0; i != c_num_buffers; ++i)
+ {
+ m_hash_buf[i] = cl::Buffer(m_context, CL_MEM_WRITE_ONLY | (!m_opencl_1_1 ? CL_MEM_HOST_READ_ONLY : 0), 32*c_hash_batch_size);
+ m_search_buf[i] = cl::Buffer(m_context, CL_MEM_WRITE_ONLY, (c_max_search_results + 1) * sizeof(uint32_t));
+ }
+ return true;
+}
+
+void ethash_cl_miner::hash(uint8_t* ret, uint8_t const* header, uint64_t nonce, unsigned count)
+{
+ struct pending_batch
+ {
+ unsigned base;
+ unsigned count;
+ unsigned buf;
+ };
+ std::queue<pending_batch> pending;
+
+ // update header constant buffer
+ m_queue.enqueueWriteBuffer(m_header, true, 0, 32, header);
+
+ /*
+ __kernel void ethash_combined_hash(
+ __global hash32_t* g_hashes,
+ __constant hash32_t const* g_header,
+ __global hash128_t const* g_dag,
+ ulong start_nonce,
+ uint isolate
+ )
+ */
+ m_hash_kernel.setArg(1, m_header);
+ m_hash_kernel.setArg(2, m_dag);
+ m_hash_kernel.setArg(3, nonce);
+ m_hash_kernel.setArg(4, ~0u); // have to pass this to stop the compile unrolling the loop
+
+ unsigned buf = 0;
+ for (unsigned i = 0; i < count || !pending.empty(); )
+ {
+ // how many this batch
+ if (i < count)
+ {
+ unsigned const this_count = std::min(count - i, c_hash_batch_size);
+ unsigned const batch_count = std::max(this_count, m_workgroup_size);
+
+ // supply output hash buffer to kernel
+ m_hash_kernel.setArg(0, m_hash_buf[buf]);
+
+ // execute it!
+ m_queue.enqueueNDRangeKernel(
+ m_hash_kernel,
+ cl::NullRange,
+ cl::NDRange(batch_count),
+ cl::NDRange(m_workgroup_size)
+ );
+ m_queue.flush();
+
+ pending.push({i, this_count, buf});
+ i += this_count;
+ buf = (buf + 1) % c_num_buffers;
+ }
+
+ // read results
+ if (i == count || pending.size() == c_num_buffers)
+ {
+ pending_batch const& batch = pending.front();
+
+ // could use pinned host pointer instead, but this path isn't that important.
+ uint8_t* hashes = (uint8_t*)m_queue.enqueueMapBuffer(m_hash_buf[batch.buf], true, CL_MAP_READ, 0, batch.count * ETHASH_BYTES);
+ memcpy(ret + batch.base*ETHASH_BYTES, hashes, batch.count*ETHASH_BYTES);
+ m_queue.enqueueUnmapMemObject(m_hash_buf[batch.buf], hashes);
+
+ pending.pop();
+ }
+ }
+}
+
+
+void ethash_cl_miner::search(uint8_t const* header, uint64_t target, search_hook& hook)
+{
+ struct pending_batch
+ {
+ uint64_t start_nonce;
+ unsigned buf;
+ };
+ std::queue<pending_batch> pending;
+
+ static uint32_t const c_zero = 0;
+
+ // update header constant buffer
+ m_queue.enqueueWriteBuffer(m_header, false, 0, 32, header);
+ for (unsigned i = 0; i != c_num_buffers; ++i)
+ {
+ m_queue.enqueueWriteBuffer(m_search_buf[i], false, 0, 4, &c_zero);
+ }
+
+#if CL_VERSION_1_2
+ cl::Event pre_return_event;
+ if (!m_opencl_1_1)
+ {
+ m_queue.enqueueBarrierWithWaitList(NULL, &pre_return_event);
+ }
+ else
+#endif
+ {
+ m_queue.finish();
+ }
+
+ /*
+ __kernel void ethash_combined_search(
+ __global hash32_t* g_hashes, // 0
+ __constant hash32_t const* g_header, // 1
+ __global hash128_t const* g_dag, // 2
+ ulong start_nonce, // 3
+ ulong target, // 4
+ uint isolate // 5
+ )
+ */
+ m_search_kernel.setArg(1, m_header);
+ m_search_kernel.setArg(2, m_dag);
+
+ // pass these to stop the compiler unrolling the loops
+ m_search_kernel.setArg(4, target);
+ m_search_kernel.setArg(5, ~0u);
+
+
+ unsigned buf = 0;
+ for (uint64_t start_nonce = 0; ; start_nonce += c_search_batch_size)
+ {
+ // supply output buffer to kernel
+ m_search_kernel.setArg(0, m_search_buf[buf]);
+ m_search_kernel.setArg(3, start_nonce);
+
+ // execute it!
+ m_queue.enqueueNDRangeKernel(m_search_kernel, cl::NullRange, c_search_batch_size, m_workgroup_size);
+
+ pending.push({start_nonce, buf});
+ buf = (buf + 1) % c_num_buffers;
+
+ // read results
+ if (pending.size() == c_num_buffers)
+ {
+ pending_batch const& batch = pending.front();
+
+ // could use pinned host pointer instead
+ uint32_t* results = (uint32_t*)m_queue.enqueueMapBuffer(m_search_buf[batch.buf], true, CL_MAP_READ, 0, (1+c_max_search_results) * sizeof(uint32_t));
+ unsigned num_found = std::min(results[0], c_max_search_results);
+
+ uint64_t nonces[c_max_search_results];
+ for (unsigned i = 0; i != num_found; ++i)
+ {
+ nonces[i] = batch.start_nonce + results[i+1];
+ }
+
+ m_queue.enqueueUnmapMemObject(m_search_buf[batch.buf], results);
+
+ bool exit = num_found && hook.found(nonces, num_found);
+ exit |= hook.searched(batch.start_nonce, c_search_batch_size); // always report searched before exit
+ if (exit)
+ break;
+
+ pending.pop();
+ }
+ }
+
+ // not safe to return until this is ready
+#if CL_VERSION_1_2
+ if (!m_opencl_1_1)
+ {
+ pre_return_event.wait();
+ }
+#endif
+}
+
diff --git a/Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash-cl/ethash_cl_miner.h b/Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash-cl/ethash_cl_miner.h
new file mode 100644
index 000000000..3fb98b5b7
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash-cl/ethash_cl_miner.h
@@ -0,0 +1,44 @@
+#pragma once
+
+#define __CL_ENABLE_EXCEPTIONS
+#define CL_USE_DEPRECATED_OPENCL_2_0_APIS
+#include "cl.hpp"
+#include <time.h>
+#include <libethash/ethash.h>
+
+class ethash_cl_miner
+{
+public:
+ struct search_hook
+ {
+ // reports progress, return true to abort
+ virtual bool found(uint64_t const* nonces, uint32_t count) = 0;
+ virtual bool searched(uint64_t start_nonce, uint32_t count) = 0;
+ };
+
+public:
+ ethash_cl_miner();
+
+ bool init(ethash_params const& params, const uint8_t seed[32], unsigned workgroup_size = 64);
+
+ void hash(uint8_t* ret, uint8_t const* header, uint64_t nonce, unsigned count);
+ void search(uint8_t const* header, uint64_t target, search_hook& hook);
+
+private:
+ static unsigned const c_max_search_results = 63;
+ static unsigned const c_num_buffers = 2;
+ static unsigned const c_hash_batch_size = 1024;
+ static unsigned const c_search_batch_size = 1024*256;
+
+ ethash_params m_params;
+ cl::Context m_context;
+ cl::CommandQueue m_queue;
+ cl::Kernel m_hash_kernel;
+ cl::Kernel m_search_kernel;
+ cl::Buffer m_dag;
+ cl::Buffer m_header;
+ cl::Buffer m_hash_buf[c_num_buffers];
+ cl::Buffer m_search_buf[c_num_buffers];
+ unsigned m_workgroup_size;
+ bool m_opencl_1_1;
+}; \ No newline at end of file
diff --git a/Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash-cl/ethash_cl_miner_kernel.cl b/Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash-cl/ethash_cl_miner_kernel.cl
new file mode 100644
index 000000000..ee21a331e
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash-cl/ethash_cl_miner_kernel.cl
@@ -0,0 +1,461 @@
+// author Tim Hughes <tim@twistedfury.com>
+// Tested on Radeon HD 7850
+// Hashrate: 15940347 hashes/s
+// Bandwidth: 124533 MB/s
+// search kernel should fit in <= 84 VGPRS (3 wavefronts)
+
+#define THREADS_PER_HASH (128 / 16)
+#define HASHES_PER_LOOP (GROUP_SIZE / THREADS_PER_HASH)
+
+#define FNV_PRIME 0x01000193
+
+__constant uint2 const Keccak_f1600_RC[24] = {
+ (uint2)(0x00000001, 0x00000000),
+ (uint2)(0x00008082, 0x00000000),
+ (uint2)(0x0000808a, 0x80000000),
+ (uint2)(0x80008000, 0x80000000),
+ (uint2)(0x0000808b, 0x00000000),
+ (uint2)(0x80000001, 0x00000000),
+ (uint2)(0x80008081, 0x80000000),
+ (uint2)(0x00008009, 0x80000000),
+ (uint2)(0x0000008a, 0x00000000),
+ (uint2)(0x00000088, 0x00000000),
+ (uint2)(0x80008009, 0x00000000),
+ (uint2)(0x8000000a, 0x00000000),
+ (uint2)(0x8000808b, 0x00000000),
+ (uint2)(0x0000008b, 0x80000000),
+ (uint2)(0x00008089, 0x80000000),
+ (uint2)(0x00008003, 0x80000000),
+ (uint2)(0x00008002, 0x80000000),
+ (uint2)(0x00000080, 0x80000000),
+ (uint2)(0x0000800a, 0x00000000),
+ (uint2)(0x8000000a, 0x80000000),
+ (uint2)(0x80008081, 0x80000000),
+ (uint2)(0x00008080, 0x80000000),
+ (uint2)(0x80000001, 0x00000000),
+ (uint2)(0x80008008, 0x80000000),
+};
+
+void keccak_f1600_round(uint2* a, uint r, uint out_size)
+{
+ #if !__ENDIAN_LITTLE__
+ for (uint i = 0; i != 25; ++i)
+ a[i] = a[i].yx;
+ #endif
+
+ uint2 b[25];
+ uint2 t;
+
+ // Theta
+ b[0] = a[0] ^ a[5] ^ a[10] ^ a[15] ^ a[20];
+ b[1] = a[1] ^ a[6] ^ a[11] ^ a[16] ^ a[21];
+ b[2] = a[2] ^ a[7] ^ a[12] ^ a[17] ^ a[22];
+ b[3] = a[3] ^ a[8] ^ a[13] ^ a[18] ^ a[23];
+ b[4] = a[4] ^ a[9] ^ a[14] ^ a[19] ^ a[24];
+ t = b[4] ^ (uint2)(b[1].x << 1 | b[1].y >> 31, b[1].y << 1 | b[1].x >> 31);
+ a[0] ^= t;
+ a[5] ^= t;
+ a[10] ^= t;
+ a[15] ^= t;
+ a[20] ^= t;
+ t = b[0] ^ (uint2)(b[2].x << 1 | b[2].y >> 31, b[2].y << 1 | b[2].x >> 31);
+ a[1] ^= t;
+ a[6] ^= t;
+ a[11] ^= t;
+ a[16] ^= t;
+ a[21] ^= t;
+ t = b[1] ^ (uint2)(b[3].x << 1 | b[3].y >> 31, b[3].y << 1 | b[3].x >> 31);
+ a[2] ^= t;
+ a[7] ^= t;
+ a[12] ^= t;
+ a[17] ^= t;
+ a[22] ^= t;
+ t = b[2] ^ (uint2)(b[4].x << 1 | b[4].y >> 31, b[4].y << 1 | b[4].x >> 31);
+ a[3] ^= t;
+ a[8] ^= t;
+ a[13] ^= t;
+ a[18] ^= t;
+ a[23] ^= t;
+ t = b[3] ^ (uint2)(b[0].x << 1 | b[0].y >> 31, b[0].y << 1 | b[0].x >> 31);
+ a[4] ^= t;
+ a[9] ^= t;
+ a[14] ^= t;
+ a[19] ^= t;
+ a[24] ^= t;
+
+ // Rho Pi
+ b[0] = a[0];
+ b[10] = (uint2)(a[1].x << 1 | a[1].y >> 31, a[1].y << 1 | a[1].x >> 31);
+ b[7] = (uint2)(a[10].x << 3 | a[10].y >> 29, a[10].y << 3 | a[10].x >> 29);
+ b[11] = (uint2)(a[7].x << 6 | a[7].y >> 26, a[7].y << 6 | a[7].x >> 26);
+ b[17] = (uint2)(a[11].x << 10 | a[11].y >> 22, a[11].y << 10 | a[11].x >> 22);
+ b[18] = (uint2)(a[17].x << 15 | a[17].y >> 17, a[17].y << 15 | a[17].x >> 17);
+ b[3] = (uint2)(a[18].x << 21 | a[18].y >> 11, a[18].y << 21 | a[18].x >> 11);
+ b[5] = (uint2)(a[3].x << 28 | a[3].y >> 4, a[3].y << 28 | a[3].x >> 4);
+ b[16] = (uint2)(a[5].y << 4 | a[5].x >> 28, a[5].x << 4 | a[5].y >> 28);
+ b[8] = (uint2)(a[16].y << 13 | a[16].x >> 19, a[16].x << 13 | a[16].y >> 19);
+ b[21] = (uint2)(a[8].y << 23 | a[8].x >> 9, a[8].x << 23 | a[8].y >> 9);
+ b[24] = (uint2)(a[21].x << 2 | a[21].y >> 30, a[21].y << 2 | a[21].x >> 30);
+ b[4] = (uint2)(a[24].x << 14 | a[24].y >> 18, a[24].y << 14 | a[24].x >> 18);
+ b[15] = (uint2)(a[4].x << 27 | a[4].y >> 5, a[4].y << 27 | a[4].x >> 5);
+ b[23] = (uint2)(a[15].y << 9 | a[15].x >> 23, a[15].x << 9 | a[15].y >> 23);
+ b[19] = (uint2)(a[23].y << 24 | a[23].x >> 8, a[23].x << 24 | a[23].y >> 8);
+ b[13] = (uint2)(a[19].x << 8 | a[19].y >> 24, a[19].y << 8 | a[19].x >> 24);
+ b[12] = (uint2)(a[13].x << 25 | a[13].y >> 7, a[13].y << 25 | a[13].x >> 7);
+ b[2] = (uint2)(a[12].y << 11 | a[12].x >> 21, a[12].x << 11 | a[12].y >> 21);
+ b[20] = (uint2)(a[2].y << 30 | a[2].x >> 2, a[2].x << 30 | a[2].y >> 2);
+ b[14] = (uint2)(a[20].x << 18 | a[20].y >> 14, a[20].y << 18 | a[20].x >> 14);
+ b[22] = (uint2)(a[14].y << 7 | a[14].x >> 25, a[14].x << 7 | a[14].y >> 25);
+ b[9] = (uint2)(a[22].y << 29 | a[22].x >> 3, a[22].x << 29 | a[22].y >> 3);
+ b[6] = (uint2)(a[9].x << 20 | a[9].y >> 12, a[9].y << 20 | a[9].x >> 12);
+ b[1] = (uint2)(a[6].y << 12 | a[6].x >> 20, a[6].x << 12 | a[6].y >> 20);
+
+ // Chi
+ a[0] = bitselect(b[0] ^ b[2], b[0], b[1]);
+ a[1] = bitselect(b[1] ^ b[3], b[1], b[2]);
+ a[2] = bitselect(b[2] ^ b[4], b[2], b[3]);
+ a[3] = bitselect(b[3] ^ b[0], b[3], b[4]);
+ if (out_size >= 4)
+ {
+ a[4] = bitselect(b[4] ^ b[1], b[4], b[0]);
+ a[5] = bitselect(b[5] ^ b[7], b[5], b[6]);
+ a[6] = bitselect(b[6] ^ b[8], b[6], b[7]);
+ a[7] = bitselect(b[7] ^ b[9], b[7], b[8]);
+ a[8] = bitselect(b[8] ^ b[5], b[8], b[9]);
+ if (out_size >= 8)
+ {
+ a[9] = bitselect(b[9] ^ b[6], b[9], b[5]);
+ a[10] = bitselect(b[10] ^ b[12], b[10], b[11]);
+ a[11] = bitselect(b[11] ^ b[13], b[11], b[12]);
+ a[12] = bitselect(b[12] ^ b[14], b[12], b[13]);
+ a[13] = bitselect(b[13] ^ b[10], b[13], b[14]);
+ a[14] = bitselect(b[14] ^ b[11], b[14], b[10]);
+ a[15] = bitselect(b[15] ^ b[17], b[15], b[16]);
+ a[16] = bitselect(b[16] ^ b[18], b[16], b[17]);
+ a[17] = bitselect(b[17] ^ b[19], b[17], b[18]);
+ a[18] = bitselect(b[18] ^ b[15], b[18], b[19]);
+ a[19] = bitselect(b[19] ^ b[16], b[19], b[15]);
+ a[20] = bitselect(b[20] ^ b[22], b[20], b[21]);
+ a[21] = bitselect(b[21] ^ b[23], b[21], b[22]);
+ a[22] = bitselect(b[22] ^ b[24], b[22], b[23]);
+ a[23] = bitselect(b[23] ^ b[20], b[23], b[24]);
+ a[24] = bitselect(b[24] ^ b[21], b[24], b[20]);
+ }
+ }
+
+ // Iota
+ a[0] ^= Keccak_f1600_RC[r];
+
+ #if !__ENDIAN_LITTLE__
+ for (uint i = 0; i != 25; ++i)
+ a[i] = a[i].yx;
+ #endif
+}
+
+void keccak_f1600_no_absorb(ulong* a, uint in_size, uint out_size, uint isolate)
+{
+ for (uint i = in_size; i != 25; ++i)
+ {
+ a[i] = 0;
+ }
+#if __ENDIAN_LITTLE__
+ a[in_size] ^= 0x0000000000000001;
+ a[24-out_size*2] ^= 0x8000000000000000;
+#else
+ a[in_size] ^= 0x0100000000000000;
+ a[24-out_size*2] ^= 0x0000000000000080;
+#endif
+
+ // Originally I unrolled the first and last rounds to interface
+ // better with surrounding code, however I haven't done this
+ // without causing the AMD compiler to blow up the VGPR usage.
+ uint r = 0;
+ do
+ {
+ // This dynamic branch stops the AMD compiler unrolling the loop
+ // and additionally saves about 33% of the VGPRs, enough to gain another
+ // wavefront. Ideally we'd get 4 in flight, but 3 is the best I can
+ // massage out of the compiler. It doesn't really seem to matter how
+ // much we try and help the compiler save VGPRs because it seems to throw
+ // that information away, hence the implementation of keccak here
+ // doesn't bother.
+ if (isolate)
+ {
+ keccak_f1600_round((uint2*)a, r++, 25);
+ }
+ }
+ while (r < 23);
+
+ // final round optimised for digest size
+ keccak_f1600_round((uint2*)a, r++, out_size);
+}
+
+#define copy(dst, src, count) for (uint i = 0; i != count; ++i) { (dst)[i] = (src)[i]; }
+
+#define countof(x) (sizeof(x) / sizeof(x[0]))
+
+uint fnv(uint x, uint y)
+{
+ return x * FNV_PRIME ^ y;
+}
+
+uint4 fnv4(uint4 x, uint4 y)
+{
+ return x * FNV_PRIME ^ y;
+}
+
+uint fnv_reduce(uint4 v)
+{
+ return fnv(fnv(fnv(v.x, v.y), v.z), v.w);
+}
+
+typedef union
+{
+ ulong ulongs[32 / sizeof(ulong)];
+ uint uints[32 / sizeof(uint)];
+} hash32_t;
+
+typedef union
+{
+ ulong ulongs[64 / sizeof(ulong)];
+ uint4 uint4s[64 / sizeof(uint4)];
+} hash64_t;
+
+typedef union
+{
+ uint uints[128 / sizeof(uint)];
+ uint4 uint4s[128 / sizeof(uint4)];
+} hash128_t;
+
+hash64_t init_hash(__constant hash32_t const* header, ulong nonce, uint isolate)
+{
+ hash64_t init;
+ uint const init_size = countof(init.ulongs);
+ uint const hash_size = countof(header->ulongs);
+
+ // sha3_512(header .. nonce)
+ ulong state[25];
+ copy(state, header->ulongs, hash_size);
+ state[hash_size] = nonce;
+ keccak_f1600_no_absorb(state, hash_size + 1, init_size, isolate);
+
+ copy(init.ulongs, state, init_size);
+ return init;
+}
+
+uint inner_loop(uint4 init, uint thread_id, __local uint* share, __global hash128_t const* g_dag, uint isolate)
+{
+ uint4 mix = init;
+
+ // share init0
+ if (thread_id == 0)
+ *share = mix.x;
+ barrier(CLK_LOCAL_MEM_FENCE);
+ uint init0 = *share;
+
+ uint a = 0;
+ do
+ {
+ bool update_share = thread_id == (a/4) % THREADS_PER_HASH;
+
+ #pragma unroll
+ for (uint i = 0; i != 4; ++i)
+ {
+ if (update_share)
+ {
+ uint m[4] = { mix.x, mix.y, mix.z, mix.w };
+ *share = fnv(init0 ^ (a+i), m[i]) % DAG_SIZE;
+ }
+ barrier(CLK_LOCAL_MEM_FENCE);
+
+ mix = fnv4(mix, g_dag[*share].uint4s[thread_id]);
+ }
+ }
+ while ((a += 4) != (ACCESSES & isolate));
+
+ return fnv_reduce(mix);
+}
+
+hash32_t final_hash(hash64_t const* init, hash32_t const* mix, uint isolate)
+{
+ ulong state[25];
+
+ hash32_t hash;
+ uint const hash_size = countof(hash.ulongs);
+ uint const init_size = countof(init->ulongs);
+ uint const mix_size = countof(mix->ulongs);
+
+ // keccak_256(keccak_512(header..nonce) .. mix);
+ copy(state, init->ulongs, init_size);
+ copy(state + init_size, mix->ulongs, mix_size);
+ keccak_f1600_no_absorb(state, init_size+mix_size, hash_size, isolate);
+
+ // copy out
+ copy(hash.ulongs, state, hash_size);
+ return hash;
+}
+
+hash32_t compute_hash_simple(
+ __constant hash32_t const* g_header,
+ __global hash128_t const* g_dag,
+ ulong nonce,
+ uint isolate
+ )
+{
+ hash64_t init = init_hash(g_header, nonce, isolate);
+
+ hash128_t mix;
+ for (uint i = 0; i != countof(mix.uint4s); ++i)
+ {
+ mix.uint4s[i] = init.uint4s[i % countof(init.uint4s)];
+ }
+
+ uint mix_val = mix.uints[0];
+ uint init0 = mix.uints[0];
+ uint a = 0;
+ do
+ {
+ uint pi = fnv(init0 ^ a, mix_val) % DAG_SIZE;
+ uint n = (a+1) % countof(mix.uints);
+
+ #pragma unroll
+ for (uint i = 0; i != countof(mix.uints); ++i)
+ {
+ mix.uints[i] = fnv(mix.uints[i], g_dag[pi].uints[i]);
+ mix_val = i == n ? mix.uints[i] : mix_val;
+ }
+ }
+ while (++a != (ACCESSES & isolate));
+
+ // reduce to output
+ hash32_t fnv_mix;
+ for (uint i = 0; i != countof(fnv_mix.uints); ++i)
+ {
+ fnv_mix.uints[i] = fnv_reduce(mix.uint4s[i]);
+ }
+
+ return final_hash(&init, &fnv_mix, isolate);
+}
+
+typedef union
+{
+ struct
+ {
+ hash64_t init;
+ uint pad; // avoid lds bank conflicts
+ };
+ hash32_t mix;
+} compute_hash_share;
+
+hash32_t compute_hash(
+ __local compute_hash_share* share,
+ __constant hash32_t const* g_header,
+ __global hash128_t const* g_dag,
+ ulong nonce,
+ uint isolate
+ )
+{
+ uint const gid = get_global_id(0);
+
+ // Compute one init hash per work item.
+ hash64_t init = init_hash(g_header, nonce, isolate);
+
+ // Threads work together in this phase in groups of 8.
+ uint const thread_id = gid % THREADS_PER_HASH;
+ uint const hash_id = (gid % GROUP_SIZE) / THREADS_PER_HASH;
+
+ hash32_t mix;
+ uint i = 0;
+ do
+ {
+ // share init with other threads
+ if (i == thread_id)
+ share[hash_id].init = init;
+ barrier(CLK_LOCAL_MEM_FENCE);
+
+ uint4 thread_init = share[hash_id].init.uint4s[thread_id % (64 / sizeof(uint4))];
+ barrier(CLK_LOCAL_MEM_FENCE);
+
+ uint thread_mix = inner_loop(thread_init, thread_id, share[hash_id].mix.uints, g_dag, isolate);
+
+ share[hash_id].mix.uints[thread_id] = thread_mix;
+ barrier(CLK_LOCAL_MEM_FENCE);
+
+ if (i == thread_id)
+ mix = share[hash_id].mix;
+ barrier(CLK_LOCAL_MEM_FENCE);
+ }
+ while (++i != (THREADS_PER_HASH & isolate));
+
+ return final_hash(&init, &mix, isolate);
+}
+
+__attribute__((reqd_work_group_size(GROUP_SIZE, 1, 1)))
+__kernel void ethash_hash_simple(
+ __global hash32_t* g_hashes,
+ __constant hash32_t const* g_header,
+ __global hash128_t const* g_dag,
+ ulong start_nonce,
+ uint isolate
+ )
+{
+ uint const gid = get_global_id(0);
+ g_hashes[gid] = compute_hash_simple(g_header, g_dag, start_nonce + gid, isolate);
+}
+
+__attribute__((reqd_work_group_size(GROUP_SIZE, 1, 1)))
+__kernel void ethash_search_simple(
+ __global volatile uint* restrict g_output,
+ __constant hash32_t const* g_header,
+ __global hash128_t const* g_dag,
+ ulong start_nonce,
+ ulong target,
+ uint isolate
+ )
+{
+ uint const gid = get_global_id(0);
+ hash32_t hash = compute_hash_simple(g_header, g_dag, start_nonce + gid, isolate);
+
+ if (hash.ulongs[countof(hash.ulongs)-1] < target)
+ {
+ uint slot = min(MAX_OUTPUTS, atomic_inc(&g_output[0]) + 1);
+ g_output[slot] = gid;
+ }
+}
+
+__attribute__((reqd_work_group_size(GROUP_SIZE, 1, 1)))
+__kernel void ethash_hash(
+ __global hash32_t* g_hashes,
+ __constant hash32_t const* g_header,
+ __global hash128_t const* g_dag,
+ ulong start_nonce,
+ uint isolate
+ )
+{
+ __local compute_hash_share share[HASHES_PER_LOOP];
+
+ uint const gid = get_global_id(0);
+ g_hashes[gid] = compute_hash(share, g_header, g_dag, start_nonce + gid, isolate);
+}
+
+__attribute__((reqd_work_group_size(GROUP_SIZE, 1, 1)))
+__kernel void ethash_search(
+ __global volatile uint* restrict g_output,
+ __constant hash32_t const* g_header,
+ __global hash128_t const* g_dag,
+ ulong start_nonce,
+ ulong target,
+ uint isolate
+ )
+{
+ __local compute_hash_share share[HASHES_PER_LOOP];
+
+ uint const gid = get_global_id(0);
+ hash32_t hash = compute_hash(share, g_header, g_dag, start_nonce + gid, isolate);
+
+ if (hash.ulongs[countof(hash.ulongs)-1] < target)
+ {
+ uint slot = min(MAX_OUTPUTS, atomic_inc(&g_output[0]) + 1);
+ g_output[slot] = gid;
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash/CMakeLists.txt b/Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash/CMakeLists.txt
new file mode 100644
index 000000000..38fc821c0
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash/CMakeLists.txt
@@ -0,0 +1,38 @@
+set(LIBRARY ethash)
+
+if (CPPETHEREUM)
+ set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC")
+endif ()
+
+set(CMAKE_BUILD_TYPE Release)
+
+if (NOT MSVC)
+ set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -std=gnu99")
+endif()
+
+set(FILES util.c
+ util.h
+ internal.c
+ ethash.h
+ endian.h
+ compiler.h
+ fnv.h
+ data_sizes.h)
+
+if (NOT CRYPTOPP_FOUND)
+ find_package(CryptoPP 5.6.2)
+endif()
+
+if (CRYPTOPP_FOUND)
+ add_definitions(-DWITH_CRYPTOPP)
+ include_directories( ${CRYPTOPP_INCLUDE_DIRS} )
+ list(APPEND FILES sha3_cryptopp.cpp sha3_cryptopp.h)
+else()
+ list(APPEND FILES sha3.c sha3.h)
+endif()
+
+add_library(${LIBRARY} ${FILES})
+
+if (CRYPTOPP_FOUND)
+ TARGET_LINK_LIBRARIES(${LIBRARY} ${CRYPTOPP_LIBRARIES})
+endif()
diff --git a/Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash/compiler.h b/Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash/compiler.h
new file mode 100644
index 000000000..9695871cd
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash/compiler.h
@@ -0,0 +1,33 @@
+/*
+ This file is part of cpp-ethereum.
+
+ cpp-ethereum is free software: you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation, either version 3 of the License, or
+ (at your option) any later version.
+
+ cpp-ethereum is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with cpp-ethereum. If not, see <http://www.gnu.org/licenses/>.
+*/
+/** @file compiler.h
+ * @date 2014
+ */
+#pragma once
+
+// Visual Studio doesn't support the inline keyword in C mode
+#if defined(_MSC_VER) && !defined(__cplusplus)
+#define inline __inline
+#endif
+
+// pretend restrict is a standard keyword
+#if defined(_MSC_VER)
+#define restrict __restrict
+#else
+#define restrict __restrict__
+#endif
+
diff --git a/Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash/data_sizes.h b/Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash/data_sizes.h
new file mode 100644
index 000000000..3b747b3ea
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash/data_sizes.h
@@ -0,0 +1,812 @@
+/*
+ This file is part of cpp-ethereum.
+
+ cpp-ethereum is free software: you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software FoundationUUU,either version 3 of the LicenseUUU,or
+ (at your option) any later version.
+
+ cpp-ethereum is distributed in the hope that it will be usefulU,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with cpp-ethereum. If notUUU,see <http://www.gnu.org/licenses/>.
+*/
+
+/** @file data_sizes.h
+* @author Matthew Wampler-Doty <negacthulhu@gmail.com>
+* @date 2015
+*/
+
+#pragma once
+
+#include <stdint.h>
+#include "compiler.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+#include <stdint.h>
+
+// 2048 Epochs (~20 years) worth of tabulated DAG sizes
+
+// Generated with the following Mathematica Code:
+
+// GetCacheSizes[n_] := Module[{
+// CacheSizeBytesInit = 2^24,
+// CacheGrowth = 2^17,
+// HashBytes = 64,
+// j = 0},
+// Reap[
+// While[j < n,
+// Module[{i =
+// Floor[(CacheSizeBytesInit + CacheGrowth * j) / HashBytes]},
+// While[! PrimeQ[i], i--];
+// Sow[i*HashBytes]; j++]]]][[2]][[1]]
+
+
+static const size_t dag_sizes[2048] = {
+ 1073739904U, 1082130304U, 1090514816U, 1098906752U, 1107293056U,
+ 1115684224U, 1124070016U, 1132461952U, 1140849536U, 1149232768U,
+ 1157627776U, 1166013824U, 1174404736U, 1182786944U, 1191180416U,
+ 1199568512U, 1207958912U, 1216345216U, 1224732032U, 1233124736U,
+ 1241513344U, 1249902464U, 1258290304U, 1266673792U, 1275067264U,
+ 1283453312U, 1291844992U, 1300234112U, 1308619904U, 1317010048U,
+ 1325397376U, 1333787776U, 1342176128U, 1350561664U, 1358954368U,
+ 1367339392U, 1375731584U, 1384118144U, 1392507008U, 1400897408U,
+ 1409284736U, 1417673344U, 1426062464U, 1434451072U, 1442839168U,
+ 1451229056U, 1459615616U, 1468006016U, 1476394112U, 1484782976U,
+ 1493171584U, 1501559168U, 1509948032U, 1518337664U, 1526726528U,
+ 1535114624U, 1543503488U, 1551892096U, 1560278656U, 1568669056U,
+ 1577056384U, 1585446272U, 1593831296U, 1602219392U, 1610610304U,
+ 1619000192U, 1627386752U, 1635773824U, 1644164224U, 1652555648U,
+ 1660943488U, 1669332608U, 1677721216U, 1686109312U, 1694497664U,
+ 1702886272U, 1711274624U, 1719661184U, 1728047744U, 1736434816U,
+ 1744829056U, 1753218944U, 1761606272U, 1769995904U, 1778382464U,
+ 1786772864U, 1795157888U, 1803550592U, 1811937664U, 1820327552U,
+ 1828711552U, 1837102976U, 1845488768U, 1853879936U, 1862269312U,
+ 1870656896U, 1879048064U, 1887431552U, 1895825024U, 1904212096U,
+ 1912601216U, 1920988544U, 1929379456U, 1937765504U, 1946156672U,
+ 1954543232U, 1962932096U, 1971321728U, 1979707264U, 1988093056U,
+ 1996487552U, 2004874624U, 2013262208U, 2021653888U, 2030039936U,
+ 2038430848U, 2046819968U, 2055208576U, 2063596672U, 2071981952U,
+ 2080373632U, 2088762752U, 2097149056U, 2105539712U, 2113928576U,
+ 2122315136U, 2130700672U, 2139092608U, 2147483264U, 2155872128U,
+ 2164257664U, 2172642176U, 2181035392U, 2189426048U, 2197814912U,
+ 2206203008U, 2214587264U, 2222979712U, 2231367808U, 2239758208U,
+ 2248145024U, 2256527744U, 2264922752U, 2273312128U, 2281701248U,
+ 2290086272U, 2298476672U, 2306867072U, 2315251072U, 2323639168U,
+ 2332032128U, 2340420224U, 2348808064U, 2357196416U, 2365580416U,
+ 2373966976U, 2382363008U, 2390748544U, 2399139968U, 2407530368U,
+ 2415918976U, 2424307328U, 2432695424U, 2441084288U, 2449472384U,
+ 2457861248U, 2466247808U, 2474637184U, 2483026816U, 2491414144U,
+ 2499803776U, 2508191872U, 2516582272U, 2524970368U, 2533359232U,
+ 2541743488U, 2550134144U, 2558525056U, 2566913408U, 2575301504U,
+ 2583686528U, 2592073856U, 2600467328U, 2608856192U, 2617240448U,
+ 2625631616U, 2634022016U, 2642407552U, 2650796416U, 2659188352U,
+ 2667574912U, 2675965312U, 2684352896U, 2692738688U, 2701130624U,
+ 2709518464U, 2717907328U, 2726293376U, 2734685056U, 2743073152U,
+ 2751462016U, 2759851648U, 2768232832U, 2776625536U, 2785017728U,
+ 2793401984U, 2801794432U, 2810182016U, 2818571648U, 2826959488U,
+ 2835349376U, 2843734144U, 2852121472U, 2860514432U, 2868900992U,
+ 2877286784U, 2885676928U, 2894069632U, 2902451584U, 2910843008U,
+ 2919234688U, 2927622784U, 2936011648U, 2944400768U, 2952789376U,
+ 2961177728U, 2969565568U, 2977951616U, 2986338944U, 2994731392U,
+ 3003120256U, 3011508352U, 3019895936U, 3028287104U, 3036675968U,
+ 3045063808U, 3053452928U, 3061837696U, 3070228352U, 3078615424U,
+ 3087003776U, 3095394944U, 3103782272U, 3112173184U, 3120562048U,
+ 3128944768U, 3137339264U, 3145725056U, 3154109312U, 3162505088U,
+ 3170893184U, 3179280256U, 3187669376U, 3196056704U, 3204445568U,
+ 3212836736U, 3221224064U, 3229612928U, 3238002304U, 3246391168U,
+ 3254778496U, 3263165824U, 3271556224U, 3279944576U, 3288332416U,
+ 3296719232U, 3305110912U, 3313500032U, 3321887104U, 3330273152U,
+ 3338658944U, 3347053184U, 3355440512U, 3363827072U, 3372220288U,
+ 3380608384U, 3388997504U, 3397384576U, 3405774208U, 3414163072U,
+ 3422551936U, 3430937984U, 3439328384U, 3447714176U, 3456104576U,
+ 3464493952U, 3472883584U, 3481268864U, 3489655168U, 3498048896U,
+ 3506434432U, 3514826368U, 3523213952U, 3531603584U, 3539987072U,
+ 3548380288U, 3556763264U, 3565157248U, 3573545344U, 3581934464U,
+ 3590324096U, 3598712704U, 3607098752U, 3615488384U, 3623877248U,
+ 3632265856U, 3640646528U, 3649043584U, 3657430144U, 3665821568U,
+ 3674207872U, 3682597504U, 3690984832U, 3699367808U, 3707764352U,
+ 3716152448U, 3724541056U, 3732925568U, 3741318016U, 3749706368U,
+ 3758091136U, 3766481536U, 3774872704U, 3783260032U, 3791650432U,
+ 3800036224U, 3808427648U, 3816815488U, 3825204608U, 3833592704U,
+ 3841981568U, 3850370432U, 3858755968U, 3867147904U, 3875536256U,
+ 3883920512U, 3892313728U, 3900702592U, 3909087872U, 3917478784U,
+ 3925868416U, 3934256512U, 3942645376U, 3951032192U, 3959422336U,
+ 3967809152U, 3976200064U, 3984588416U, 3992974976U, 4001363584U,
+ 4009751168U, 4018141312U, 4026530432U, 4034911616U, 4043308928U,
+ 4051695488U, 4060084352U, 4068472448U, 4076862848U, 4085249408U,
+ 4093640576U, 4102028416U, 4110413696U, 4118805632U, 4127194496U,
+ 4135583104U, 4143971968U, 4152360832U, 4160746112U, 4169135744U,
+ 4177525888U, 4185912704U, 4194303616U, 4202691968U, 4211076736U,
+ 4219463552U, 4227855488U, 4236246656U, 4244633728U, 4253022848U,
+ 4261412224U, 4269799808U, 4278184832U, 4286578048U, 4294962304U,
+ 4303349632U, 4311743104U, 4320130432U, 4328521088U, 4336909184U,
+ 4345295488U, 4353687424U, 4362073472U, 4370458496U, 4378852736U,
+ 4387238528U, 4395630208U, 4404019072U, 4412407424U, 4420790656U,
+ 4429182848U, 4437571456U, 4445962112U, 4454344064U, 4462738048U,
+ 4471119232U, 4479516544U, 4487904128U, 4496289664U, 4504682368U,
+ 4513068416U, 4521459584U, 4529846144U, 4538232704U, 4546619776U,
+ 4555010176U, 4563402112U, 4571790208U, 4580174464U, 4588567936U,
+ 4596957056U, 4605344896U, 4613734016U, 4622119808U, 4630511488U,
+ 4638898816U, 4647287936U, 4655675264U, 4664065664U, 4672451968U,
+ 4680842624U, 4689231488U, 4697620352U, 4706007424U, 4714397056U,
+ 4722786176U, 4731173248U, 4739562368U, 4747951744U, 4756340608U,
+ 4764727936U, 4773114496U, 4781504384U, 4789894784U, 4798283648U,
+ 4806667648U, 4815059584U, 4823449472U, 4831835776U, 4840226176U,
+ 4848612224U, 4857003392U, 4865391488U, 4873780096U, 4882169728U,
+ 4890557312U, 4898946944U, 4907333248U, 4915722368U, 4924110976U,
+ 4932499328U, 4940889728U, 4949276032U, 4957666432U, 4966054784U,
+ 4974438016U, 4982831488U, 4991221376U, 4999607168U, 5007998848U,
+ 5016386432U, 5024763776U, 5033164672U, 5041544576U, 5049941888U,
+ 5058329728U, 5066717056U, 5075107456U, 5083494272U, 5091883904U,
+ 5100273536U, 5108662144U, 5117048192U, 5125436032U, 5133827456U,
+ 5142215296U, 5150605184U, 5158993024U, 5167382144U, 5175769472U,
+ 5184157568U, 5192543872U, 5200936064U, 5209324928U, 5217711232U,
+ 5226102656U, 5234490496U, 5242877312U, 5251263872U, 5259654016U,
+ 5268040832U, 5276434304U, 5284819328U, 5293209728U, 5301598592U,
+ 5309986688U, 5318374784U, 5326764416U, 5335151488U, 5343542144U,
+ 5351929472U, 5360319872U, 5368706944U, 5377096576U, 5385484928U,
+ 5393871232U, 5402263424U, 5410650496U, 5419040384U, 5427426944U,
+ 5435816576U, 5444205952U, 5452594816U, 5460981376U, 5469367936U,
+ 5477760896U, 5486148736U, 5494536832U, 5502925952U, 5511315328U,
+ 5519703424U, 5528089984U, 5536481152U, 5544869504U, 5553256064U,
+ 5561645696U, 5570032768U, 5578423936U, 5586811264U, 5595193216U,
+ 5603585408U, 5611972736U, 5620366208U, 5628750464U, 5637143936U,
+ 5645528192U, 5653921408U, 5662310272U, 5670694784U, 5679082624U,
+ 5687474048U, 5695864448U, 5704251008U, 5712641408U, 5721030272U,
+ 5729416832U, 5737806208U, 5746194304U, 5754583936U, 5762969984U,
+ 5771358592U, 5779748224U, 5788137856U, 5796527488U, 5804911232U,
+ 5813300608U, 5821692544U, 5830082176U, 5838468992U, 5846855552U,
+ 5855247488U, 5863636096U, 5872024448U, 5880411008U, 5888799872U,
+ 5897186432U, 5905576832U, 5913966976U, 5922352768U, 5930744704U,
+ 5939132288U, 5947522432U, 5955911296U, 5964299392U, 5972688256U,
+ 5981074304U, 5989465472U, 5997851008U, 6006241408U, 6014627968U,
+ 6023015552U, 6031408256U, 6039796096U, 6048185216U, 6056574848U,
+ 6064963456U, 6073351808U, 6081736064U, 6090128768U, 6098517632U,
+ 6106906496U, 6115289216U, 6123680896U, 6132070016U, 6140459648U,
+ 6148849024U, 6157237376U, 6165624704U, 6174009728U, 6182403712U,
+ 6190792064U, 6199176064U, 6207569792U, 6215952256U, 6224345216U,
+ 6232732544U, 6241124224U, 6249510272U, 6257899136U, 6266287744U,
+ 6274676864U, 6283065728U, 6291454336U, 6299843456U, 6308232064U,
+ 6316620928U, 6325006208U, 6333395584U, 6341784704U, 6350174848U,
+ 6358562176U, 6366951296U, 6375337856U, 6383729536U, 6392119168U,
+ 6400504192U, 6408895616U, 6417283456U, 6425673344U, 6434059136U,
+ 6442444672U, 6450837376U, 6459223424U, 6467613056U, 6476004224U,
+ 6484393088U, 6492781952U, 6501170048U, 6509555072U, 6517947008U,
+ 6526336384U, 6534725504U, 6543112832U, 6551500672U, 6559888768U,
+ 6568278656U, 6576662912U, 6585055616U, 6593443456U, 6601834112U,
+ 6610219648U, 6618610304U, 6626999168U, 6635385472U, 6643777408U,
+ 6652164224U, 6660552832U, 6668941952U, 6677330048U, 6685719424U,
+ 6694107776U, 6702493568U, 6710882176U, 6719274112U, 6727662976U,
+ 6736052096U, 6744437632U, 6752825984U, 6761213824U, 6769604224U,
+ 6777993856U, 6786383488U, 6794770816U, 6803158144U, 6811549312U,
+ 6819937664U, 6828326528U, 6836706176U, 6845101696U, 6853491328U,
+ 6861880448U, 6870269312U, 6878655104U, 6887046272U, 6895433344U,
+ 6903822208U, 6912212864U, 6920596864U, 6928988288U, 6937377152U,
+ 6945764992U, 6954149248U, 6962544256U, 6970928768U, 6979317376U,
+ 6987709312U, 6996093824U, 7004487296U, 7012875392U, 7021258624U,
+ 7029652352U, 7038038912U, 7046427776U, 7054818944U, 7063207808U,
+ 7071595136U, 7079980928U, 7088372608U, 7096759424U, 7105149824U,
+ 7113536896U, 7121928064U, 7130315392U, 7138699648U, 7147092352U,
+ 7155479168U, 7163865728U, 7172249984U, 7180648064U, 7189036672U,
+ 7197424768U, 7205810816U, 7214196608U, 7222589824U, 7230975104U,
+ 7239367552U, 7247755904U, 7256145536U, 7264533376U, 7272921472U,
+ 7281308032U, 7289694848U, 7298088832U, 7306471808U, 7314864512U,
+ 7323253888U, 7331643008U, 7340029568U, 7348419712U, 7356808832U,
+ 7365196672U, 7373585792U, 7381973888U, 7390362752U, 7398750592U,
+ 7407138944U, 7415528576U, 7423915648U, 7432302208U, 7440690304U,
+ 7449080192U, 7457472128U, 7465860992U, 7474249088U, 7482635648U,
+ 7491023744U, 7499412608U, 7507803008U, 7516192384U, 7524579968U,
+ 7532967296U, 7541358464U, 7549745792U, 7558134656U, 7566524032U,
+ 7574912896U, 7583300992U, 7591690112U, 7600075136U, 7608466816U,
+ 7616854912U, 7625244544U, 7633629824U, 7642020992U, 7650410368U,
+ 7658794112U, 7667187328U, 7675574912U, 7683961984U, 7692349568U,
+ 7700739712U, 7709130368U, 7717519232U, 7725905536U, 7734295424U,
+ 7742683264U, 7751069056U, 7759457408U, 7767849088U, 7776238208U,
+ 7784626816U, 7793014912U, 7801405312U, 7809792128U, 7818179968U,
+ 7826571136U, 7834957184U, 7843347328U, 7851732352U, 7860124544U,
+ 7868512384U, 7876902016U, 7885287808U, 7893679744U, 7902067072U,
+ 7910455936U, 7918844288U, 7927230848U, 7935622784U, 7944009344U,
+ 7952400256U, 7960786048U, 7969176704U, 7977565312U, 7985953408U,
+ 7994339968U, 8002730368U, 8011119488U, 8019508096U, 8027896192U,
+ 8036285056U, 8044674688U, 8053062272U, 8061448832U, 8069838464U,
+ 8078227328U, 8086616704U, 8095006592U, 8103393664U, 8111783552U,
+ 8120171392U, 8128560256U, 8136949376U, 8145336704U, 8153726848U,
+ 8162114944U, 8170503296U, 8178891904U, 8187280768U, 8195669632U,
+ 8204058496U, 8212444544U, 8220834176U, 8229222272U, 8237612672U,
+ 8246000768U, 8254389376U, 8262775168U, 8271167104U, 8279553664U,
+ 8287944064U, 8296333184U, 8304715136U, 8313108352U, 8321497984U,
+ 8329885568U, 8338274432U, 8346663296U, 8355052928U, 8363441536U,
+ 8371828352U, 8380217984U, 8388606592U, 8396996224U, 8405384576U,
+ 8413772672U, 8422161536U, 8430549376U, 8438939008U, 8447326592U,
+ 8455715456U, 8464104832U, 8472492928U, 8480882048U, 8489270656U,
+ 8497659776U, 8506045312U, 8514434944U, 8522823808U, 8531208832U,
+ 8539602304U, 8547990656U, 8556378752U, 8564768384U, 8573154176U,
+ 8581542784U, 8589933952U, 8598322816U, 8606705024U, 8615099264U,
+ 8623487872U, 8631876992U, 8640264064U, 8648653952U, 8657040256U,
+ 8665430656U, 8673820544U, 8682209152U, 8690592128U, 8698977152U,
+ 8707374464U, 8715763328U, 8724151424U, 8732540032U, 8740928384U,
+ 8749315712U, 8757704576U, 8766089344U, 8774480768U, 8782871936U,
+ 8791260032U, 8799645824U, 8808034432U, 8816426368U, 8824812928U,
+ 8833199488U, 8841591424U, 8849976448U, 8858366336U, 8866757248U,
+ 8875147136U, 8883532928U, 8891923328U, 8900306816U, 8908700288U,
+ 8917088384U, 8925478784U, 8933867392U, 8942250368U, 8950644608U,
+ 8959032704U, 8967420544U, 8975809664U, 8984197504U, 8992584064U,
+ 9000976256U, 9009362048U, 9017752448U, 9026141312U, 9034530688U,
+ 9042917504U, 9051307904U, 9059694208U, 9068084864U, 9076471424U,
+ 9084861824U, 9093250688U, 9101638528U, 9110027648U, 9118416512U,
+ 9126803584U, 9135188096U, 9143581312U, 9151969664U, 9160356224U,
+ 9168747136U, 9177134464U, 9185525632U, 9193910144U, 9202302848U,
+ 9210690688U, 9219079552U, 9227465344U, 9235854464U, 9244244864U,
+ 9252633472U, 9261021824U, 9269411456U, 9277799296U, 9286188928U,
+ 9294574208U, 9302965888U, 9311351936U, 9319740032U, 9328131968U,
+ 9336516736U, 9344907392U, 9353296768U, 9361685888U, 9370074752U,
+ 9378463616U, 9386849408U, 9395239808U, 9403629184U, 9412016512U,
+ 9420405376U, 9428795008U, 9437181568U, 9445570688U, 9453960832U,
+ 9462346624U, 9470738048U, 9479121536U, 9487515008U, 9495903616U,
+ 9504289664U, 9512678528U, 9521067904U, 9529456256U, 9537843584U,
+ 9546233728U, 9554621312U, 9563011456U, 9571398784U, 9579788672U,
+ 9588178304U, 9596567168U, 9604954496U, 9613343104U, 9621732992U,
+ 9630121856U, 9638508416U, 9646898816U, 9655283584U, 9663675776U,
+ 9672061312U, 9680449664U, 9688840064U, 9697230464U, 9705617536U,
+ 9714003584U, 9722393984U, 9730772608U, 9739172224U, 9747561088U,
+ 9755945344U, 9764338816U, 9772726144U, 9781116544U, 9789503872U,
+ 9797892992U, 9806282624U, 9814670464U, 9823056512U, 9831439232U,
+ 9839833984U, 9848224384U, 9856613504U, 9865000576U, 9873391232U,
+ 9881772416U, 9890162816U, 9898556288U, 9906940544U, 9915333248U,
+ 9923721088U, 9932108672U, 9940496512U, 9948888448U, 9957276544U,
+ 9965666176U, 9974048384U, 9982441088U, 9990830464U, 9999219584U,
+ 10007602816U, 10015996544U, 10024385152U, 10032774016U, 10041163648U,
+ 10049548928U, 10057940096U, 10066329472U, 10074717824U, 10083105152U,
+ 10091495296U, 10099878784U, 10108272256U, 10116660608U, 10125049216U,
+ 10133437312U, 10141825664U, 10150213504U, 10158601088U, 10166991232U,
+ 10175378816U, 10183766144U, 10192157312U, 10200545408U, 10208935552U,
+ 10217322112U, 10225712768U, 10234099328U, 10242489472U, 10250876032U,
+ 10259264896U, 10267656064U, 10276042624U, 10284429184U, 10292820352U,
+ 10301209472U, 10309598848U, 10317987712U, 10326375296U, 10334763392U,
+ 10343153536U, 10351541632U, 10359930752U, 10368318592U, 10376707456U,
+ 10385096576U, 10393484672U, 10401867136U, 10410262144U, 10418647424U,
+ 10427039104U, 10435425664U, 10443810176U, 10452203648U, 10460589952U,
+ 10468982144U, 10477369472U, 10485759104U, 10494147712U, 10502533504U,
+ 10510923392U, 10519313536U, 10527702656U, 10536091264U, 10544478592U,
+ 10552867712U, 10561255808U, 10569642368U, 10578032768U, 10586423168U,
+ 10594805632U, 10603200128U, 10611588992U, 10619976064U, 10628361344U,
+ 10636754048U, 10645143424U, 10653531776U, 10661920384U, 10670307968U,
+ 10678696832U, 10687086464U, 10695475072U, 10703863168U, 10712246144U,
+ 10720639616U, 10729026688U, 10737414784U, 10745806208U, 10754190976U,
+ 10762581376U, 10770971264U, 10779356288U, 10787747456U, 10796135552U,
+ 10804525184U, 10812915584U, 10821301888U, 10829692288U, 10838078336U,
+ 10846469248U, 10854858368U, 10863247232U, 10871631488U, 10880023424U,
+ 10888412032U, 10896799616U, 10905188992U, 10913574016U, 10921964672U,
+ 10930352768U, 10938742912U, 10947132544U, 10955518592U, 10963909504U,
+ 10972298368U, 10980687488U, 10989074816U, 10997462912U, 11005851776U,
+ 11014241152U, 11022627712U, 11031017344U, 11039403904U, 11047793024U,
+ 11056184704U, 11064570752U, 11072960896U, 11081343872U, 11089737856U,
+ 11098128256U, 11106514816U, 11114904448U, 11123293568U, 11131680128U,
+ 11140065152U, 11148458368U, 11156845696U, 11165236864U, 11173624192U,
+ 11182013824U, 11190402688U, 11198790784U, 11207179136U, 11215568768U,
+ 11223957376U, 11232345728U, 11240734592U, 11249122688U, 11257511296U,
+ 11265899648U, 11274285952U, 11282675584U, 11291065472U, 11299452544U,
+ 11307842432U, 11316231296U, 11324616832U, 11333009024U, 11341395584U,
+ 11349782656U, 11358172288U, 11366560384U, 11374950016U, 11383339648U,
+ 11391721856U, 11400117376U, 11408504192U, 11416893568U, 11425283456U,
+ 11433671552U, 11442061184U, 11450444672U, 11458837888U, 11467226752U,
+ 11475611776U, 11484003968U, 11492392064U, 11500780672U, 11509169024U,
+ 11517550976U, 11525944448U, 11534335616U, 11542724224U, 11551111808U,
+ 11559500672U, 11567890304U, 11576277376U, 11584667008U, 11593056128U,
+ 11601443456U, 11609830016U, 11618221952U, 11626607488U, 11634995072U,
+ 11643387776U, 11651775104U, 11660161664U, 11668552576U, 11676940928U,
+ 11685330304U, 11693718656U, 11702106496U, 11710496128U, 11718882688U,
+ 11727273088U, 11735660416U, 11744050048U, 11752437376U, 11760824704U,
+ 11769216128U, 11777604736U, 11785991296U, 11794381952U, 11802770048U,
+ 11811157888U, 11819548544U, 11827932544U, 11836324736U, 11844713344U,
+ 11853100928U, 11861486464U, 11869879936U, 11878268032U, 11886656896U,
+ 11895044992U, 11903433088U, 11911822976U, 11920210816U, 11928600448U,
+ 11936987264U, 11945375872U, 11953761152U, 11962151296U, 11970543488U,
+ 11978928512U, 11987320448U, 11995708288U, 12004095104U, 12012486272U,
+ 12020875136U, 12029255552U, 12037652096U, 12046039168U, 12054429568U,
+ 12062813824U, 12071206528U, 12079594624U, 12087983744U, 12096371072U,
+ 12104759936U, 12113147264U, 12121534592U, 12129924992U, 12138314624U,
+ 12146703232U, 12155091584U, 12163481216U, 12171864704U, 12180255872U,
+ 12188643968U, 12197034112U, 12205424512U, 12213811328U, 12222199424U,
+ 12230590336U, 12238977664U, 12247365248U, 12255755392U, 12264143488U,
+ 12272531584U, 12280920448U, 12289309568U, 12297694592U, 12306086528U,
+ 12314475392U, 12322865024U, 12331253632U, 12339640448U, 12348029312U,
+ 12356418944U, 12364805248U, 12373196672U, 12381580928U, 12389969024U,
+ 12398357632U, 12406750592U, 12415138432U, 12423527552U, 12431916416U,
+ 12440304512U, 12448692352U, 12457081216U, 12465467776U, 12473859968U,
+ 12482245504U, 12490636672U, 12499025536U, 12507411584U, 12515801728U,
+ 12524190592U, 12532577152U, 12540966272U, 12549354368U, 12557743232U,
+ 12566129536U, 12574523264U, 12582911872U, 12591299456U, 12599688064U,
+ 12608074624U, 12616463488U, 12624845696U, 12633239936U, 12641631616U,
+ 12650019968U, 12658407296U, 12666795136U, 12675183232U, 12683574656U,
+ 12691960192U, 12700350592U, 12708740224U, 12717128576U, 12725515904U,
+ 12733906816U, 12742295168U, 12750680192U, 12759071872U, 12767460736U,
+ 12775848832U, 12784236928U, 12792626816U, 12801014656U, 12809404288U,
+ 12817789312U, 12826181504U, 12834568832U, 12842954624U, 12851345792U,
+ 12859732352U, 12868122496U, 12876512128U, 12884901248U, 12893289088U,
+ 12901672832U, 12910067584U, 12918455168U, 12926842496U, 12935232896U,
+ 12943620736U, 12952009856U, 12960396928U, 12968786816U, 12977176192U,
+ 12985563776U, 12993951104U, 13002341504U, 13010730368U, 13019115392U,
+ 13027506304U, 13035895168U, 13044272512U, 13052673152U, 13061062528U,
+ 13069446272U, 13077838976U, 13086227072U, 13094613632U, 13103000192U,
+ 13111393664U, 13119782528U, 13128157568U, 13136559232U, 13144945024U,
+ 13153329536U, 13161724288U, 13170111872U, 13178502784U, 13186884736U,
+ 13195279744U, 13203667072U, 13212057472U, 13220445824U, 13228832128U,
+ 13237221248U, 13245610624U, 13254000512U, 13262388352U, 13270777472U,
+ 13279166336U, 13287553408U, 13295943296U, 13304331904U, 13312719488U,
+ 13321108096U, 13329494656U, 13337885824U, 13346274944U, 13354663808U,
+ 13363051136U, 13371439232U, 13379825024U, 13388210816U, 13396605056U,
+ 13404995456U, 13413380224U, 13421771392U, 13430159744U, 13438546048U,
+ 13446937216U, 13455326848U, 13463708288U, 13472103808U, 13480492672U,
+ 13488875648U, 13497269888U, 13505657728U, 13514045312U, 13522435712U,
+ 13530824576U, 13539210112U, 13547599232U, 13555989376U, 13564379008U,
+ 13572766336U, 13581154432U, 13589544832U, 13597932928U, 13606320512U,
+ 13614710656U, 13623097472U, 13631477632U, 13639874944U, 13648264064U,
+ 13656652928U, 13665041792U, 13673430656U, 13681818496U, 13690207616U,
+ 13698595712U, 13706982272U, 13715373184U, 13723762048U, 13732150144U,
+ 13740536704U, 13748926592U, 13757316224U, 13765700992U, 13774090112U,
+ 13782477952U, 13790869376U, 13799259008U, 13807647872U, 13816036736U,
+ 13824425344U, 13832814208U, 13841202304U, 13849591424U, 13857978752U,
+ 13866368896U, 13874754688U, 13883145344U, 13891533184U, 13899919232U,
+ 13908311168U, 13916692096U, 13925085056U, 13933473152U, 13941866368U,
+ 13950253696U, 13958643584U, 13967032192U, 13975417216U, 13983807616U,
+ 13992197504U, 14000582272U, 14008973696U, 14017363072U, 14025752192U,
+ 14034137984U, 14042528384U, 14050918016U, 14059301504U, 14067691648U,
+ 14076083584U, 14084470144U, 14092852352U, 14101249664U, 14109635968U,
+ 14118024832U, 14126407552U, 14134804352U, 14143188608U, 14151577984U,
+ 14159968384U, 14168357248U, 14176741504U, 14185127296U, 14193521024U,
+ 14201911424U, 14210301824U, 14218685056U, 14227067264U, 14235467392U,
+ 14243855488U, 14252243072U, 14260630144U, 14269021568U, 14277409408U,
+ 14285799296U, 14294187904U, 14302571392U, 14310961792U, 14319353728U,
+ 14327738752U, 14336130944U, 14344518784U, 14352906368U, 14361296512U,
+ 14369685376U, 14378071424U, 14386462592U, 14394848128U, 14403230848U,
+ 14411627392U, 14420013952U, 14428402304U, 14436793472U, 14445181568U,
+ 14453569664U, 14461959808U, 14470347904U, 14478737024U, 14487122816U,
+ 14495511424U, 14503901824U, 14512291712U, 14520677504U, 14529064832U,
+ 14537456768U, 14545845632U, 14554234496U, 14562618496U, 14571011456U,
+ 14579398784U, 14587789184U, 14596172672U, 14604564608U, 14612953984U,
+ 14621341312U, 14629724288U, 14638120832U, 14646503296U, 14654897536U,
+ 14663284864U, 14671675264U, 14680061056U, 14688447616U, 14696835968U,
+ 14705228416U, 14713616768U, 14722003328U, 14730392192U, 14738784128U,
+ 14747172736U, 14755561088U, 14763947648U, 14772336512U, 14780725376U,
+ 14789110144U, 14797499776U, 14805892736U, 14814276992U, 14822670208U,
+ 14831056256U, 14839444352U, 14847836032U, 14856222848U, 14864612992U,
+ 14872997504U, 14881388672U, 14889775744U, 14898165376U, 14906553472U,
+ 14914944896U, 14923329664U, 14931721856U, 14940109696U, 14948497024U,
+ 14956887424U, 14965276544U, 14973663616U, 14982053248U, 14990439808U,
+ 14998830976U, 15007216768U, 15015605888U, 15023995264U, 15032385152U,
+ 15040768384U, 15049154944U, 15057549184U, 15065939072U, 15074328448U,
+ 15082715008U, 15091104128U, 15099493504U, 15107879296U, 15116269184U,
+ 15124659584U, 15133042304U, 15141431936U, 15149824384U, 15158214272U,
+ 15166602368U, 15174991232U, 15183378304U, 15191760512U, 15200154496U,
+ 15208542592U, 15216931712U, 15225323392U, 15233708416U, 15242098048U,
+ 15250489216U, 15258875264U, 15267265408U, 15275654528U, 15284043136U,
+ 15292431488U, 15300819584U, 15309208192U, 15317596544U, 15325986176U,
+ 15334374784U, 15342763648U, 15351151744U, 15359540608U, 15367929728U,
+ 15376318336U, 15384706432U, 15393092992U, 15401481856U, 15409869952U,
+ 15418258816U, 15426649984U, 15435037568U, 15443425664U, 15451815296U,
+ 15460203392U, 15468589184U, 15476979328U, 15485369216U, 15493755776U,
+ 15502146944U, 15510534272U, 15518924416U, 15527311232U, 15535699072U,
+ 15544089472U, 15552478336U, 15560866688U, 15569254528U, 15577642624U,
+ 15586031488U, 15594419072U, 15602809472U, 15611199104U, 15619586432U,
+ 15627975296U, 15636364928U, 15644753792U, 15653141888U, 15661529216U,
+ 15669918848U, 15678305152U, 15686696576U, 15695083136U, 15703474048U,
+ 15711861632U, 15720251264U, 15728636288U, 15737027456U, 15745417088U,
+ 15753804928U, 15762194048U, 15770582656U, 15778971008U, 15787358336U,
+ 15795747712U, 15804132224U, 15812523392U, 15820909696U, 15829300096U,
+ 15837691264U, 15846071936U, 15854466944U, 15862855808U, 15871244672U,
+ 15879634816U, 15888020608U, 15896409728U, 15904799104U, 15913185152U,
+ 15921577088U, 15929966464U, 15938354816U, 15946743424U, 15955129472U,
+ 15963519872U, 15971907968U, 15980296064U, 15988684928U, 15997073024U,
+ 16005460864U, 16013851264U, 16022241152U, 16030629248U, 16039012736U,
+ 16047406976U, 16055794816U, 16064181376U, 16072571264U, 16080957824U,
+ 16089346688U, 16097737856U, 16106125184U, 16114514816U, 16122904192U,
+ 16131292544U, 16139678848U, 16148066944U, 16156453504U, 16164839552U,
+ 16173236096U, 16181623424U, 16190012032U, 16198401152U, 16206790528U,
+ 16215177344U, 16223567744U, 16231956352U, 16240344704U, 16248731008U,
+ 16257117824U, 16265504384U, 16273898624U, 16282281856U, 16290668672U,
+ 16299064192U, 16307449216U, 16315842176U, 16324230016U, 16332613504U,
+ 16341006464U, 16349394304U, 16357783168U, 16366172288U, 16374561664U,
+ 16382951296U, 16391337856U, 16399726208U, 16408116352U, 16416505472U,
+ 16424892032U, 16433282176U, 16441668224U, 16450058624U, 16458448768U,
+ 16466836864U, 16475224448U, 16483613056U, 16492001408U, 16500391808U,
+ 16508779648U, 16517166976U, 16525555328U, 16533944192U, 16542330752U,
+ 16550719616U, 16559110528U, 16567497088U, 16575888512U, 16584274816U,
+ 16592665472U, 16601051008U, 16609442944U, 16617832064U, 16626218624U,
+ 16634607488U, 16642996096U, 16651385728U, 16659773824U, 16668163712U,
+ 16676552576U, 16684938112U, 16693328768U, 16701718144U, 16710095488U,
+ 16718492288U, 16726883968U, 16735272832U, 16743661184U, 16752049792U,
+ 16760436608U, 16768827008U, 16777214336U, 16785599104U, 16793992832U,
+ 16802381696U, 16810768768U, 16819151744U, 16827542656U, 16835934848U,
+ 16844323712U, 16852711552U, 16861101952U, 16869489536U, 16877876864U,
+ 16886265728U, 16894653056U, 16903044736U, 16911431296U, 16919821696U,
+ 16928207488U, 16936592768U, 16944987776U, 16953375616U, 16961763968U,
+ 16970152832U, 16978540928U, 16986929536U, 16995319168U, 17003704448U,
+ 17012096896U, 17020481152U, 17028870784U, 17037262208U, 17045649536U,
+ 17054039936U, 17062426496U, 17070814336U, 17079205504U, 17087592064U,
+ 17095978112U, 17104369024U, 17112759424U, 17121147776U, 17129536384U,
+ 17137926016U, 17146314368U, 17154700928U, 17163089792U, 17171480192U,
+ 17179864192U, 17188256896U, 17196644992U, 17205033856U, 17213423488U,
+ 17221811072U, 17230198912U, 17238588032U, 17246976896U, 17255360384U,
+ 17263754624U, 17272143232U, 17280530048U, 17288918912U, 17297309312U,
+ 17305696384U, 17314085504U, 17322475136U, 17330863744U, 17339252096U,
+ 17347640192U, 17356026496U, 17364413824U, 17372796544U, 17381190016U,
+ 17389583488U, 17397972608U, 17406360704U, 17414748544U, 17423135872U,
+ 17431527296U, 17439915904U, 17448303232U, 17456691584U, 17465081728U,
+ 17473468288U, 17481857408U, 17490247552U, 17498635904U, 17507022464U,
+ 17515409024U, 17523801728U, 17532189824U, 17540577664U, 17548966016U,
+ 17557353344U, 17565741184U, 17574131584U, 17582519168U, 17590907008U,
+ 17599296128U, 17607687808U, 17616076672U, 17624455808U, 17632852352U,
+ 17641238656U, 17649630848U, 17658018944U, 17666403968U, 17674794112U,
+ 17683178368U, 17691573376U, 17699962496U, 17708350592U, 17716739968U,
+ 17725126528U, 17733517184U, 17741898112U, 17750293888U, 17758673024U,
+ 17767070336U, 17775458432U, 17783848832U, 17792236928U, 17800625536U,
+ 17809012352U, 17817402752U, 17825785984U, 17834178944U, 17842563968U,
+ 17850955648U, 17859344512U, 17867732864U, 17876119424U, 17884511872U,
+ 17892900224U, 17901287296U, 17909677696U, 17918058112U, 17926451072U,
+ 17934843776U, 17943230848U, 17951609216U, 17960008576U, 17968397696U,
+ 17976784256U, 17985175424U, 17993564032U, 18001952128U, 18010339712U,
+ 18018728576U, 18027116672U, 18035503232U, 18043894144U, 18052283264U,
+ 18060672128U, 18069056384U, 18077449856U, 18085837184U, 18094225792U,
+ 18102613376U, 18111004544U, 18119388544U, 18127781248U, 18136170368U,
+ 18144558976U, 18152947328U, 18161336192U, 18169724288U, 18178108544U,
+ 18186498944U, 18194886784U, 18203275648U, 18211666048U, 18220048768U,
+ 18228444544U, 18236833408U, 18245220736U
+};
+
+
+// Generated with the following Mathematica Code:
+
+// GetCacheSizes[n_] := Module[{
+// DataSetSizeBytesInit = 2^30,
+// MixBytes = 128,
+// DataSetGrowth = 2^23,
+// HashBytes = 64,
+// CacheMultiplier = 1024,
+// j = 0},
+// Reap[
+// While[j < n,
+// Module[{i = Floor[(DataSetSizeBytesInit + DataSetGrowth * j) / (CacheMultiplier * HashBytes)]},
+// While[! PrimeQ[i], i--];
+// Sow[i*HashBytes]; j++]]]][[2]][[1]]
+
+const size_t cache_sizes[2048] = {
+ 16776896U, 16907456U, 17039296U, 17170112U, 17301056U, 17432512U, 17563072U,
+ 17693888U, 17824192U, 17955904U, 18087488U, 18218176U, 18349504U, 18481088U,
+ 18611392U, 18742336U, 18874304U, 19004224U, 19135936U, 19267264U, 19398208U,
+ 19529408U, 19660096U, 19791424U, 19922752U, 20053952U, 20184896U, 20315968U,
+ 20446912U, 20576576U, 20709184U, 20840384U, 20971072U, 21102272U, 21233216U,
+ 21364544U, 21494848U, 21626816U, 21757376U, 21887552U, 22019392U, 22151104U,
+ 22281536U, 22412224U, 22543936U, 22675264U, 22806464U, 22935872U, 23068096U,
+ 23198272U, 23330752U, 23459008U, 23592512U, 23723968U, 23854912U, 23986112U,
+ 24116672U, 24247616U, 24378688U, 24509504U, 24640832U, 24772544U, 24903488U,
+ 25034432U, 25165376U, 25296704U, 25427392U, 25558592U, 25690048U, 25820096U,
+ 25951936U, 26081728U, 26214208U, 26345024U, 26476096U, 26606656U, 26737472U,
+ 26869184U, 26998208U, 27131584U, 27262528U, 27393728U, 27523904U, 27655744U,
+ 27786688U, 27917888U, 28049344U, 28179904U, 28311488U, 28441792U, 28573504U,
+ 28700864U, 28835648U, 28966208U, 29096768U, 29228608U, 29359808U, 29490752U,
+ 29621824U, 29752256U, 29882816U, 30014912U, 30144448U, 30273728U, 30406976U,
+ 30538432U, 30670784U, 30799936U, 30932672U, 31063744U, 31195072U, 31325248U,
+ 31456192U, 31588288U, 31719232U, 31850432U, 31981504U, 32110784U, 32243392U,
+ 32372672U, 32505664U, 32636608U, 32767808U, 32897344U, 33029824U, 33160768U,
+ 33289664U, 33423296U, 33554368U, 33683648U, 33816512U, 33947456U, 34076992U,
+ 34208704U, 34340032U, 34471744U, 34600256U, 34734016U, 34864576U, 34993984U,
+ 35127104U, 35258176U, 35386688U, 35518528U, 35650624U, 35782336U, 35910976U,
+ 36044608U, 36175808U, 36305728U, 36436672U, 36568384U, 36699968U, 36830656U,
+ 36961984U, 37093312U, 37223488U, 37355072U, 37486528U, 37617472U, 37747904U,
+ 37879232U, 38009792U, 38141888U, 38272448U, 38403392U, 38535104U, 38660672U,
+ 38795584U, 38925632U, 39059264U, 39190336U, 39320768U, 39452096U, 39581632U,
+ 39713984U, 39844928U, 39974848U, 40107968U, 40238144U, 40367168U, 40500032U,
+ 40631744U, 40762816U, 40894144U, 41023552U, 41155904U, 41286208U, 41418304U,
+ 41547712U, 41680448U, 41811904U, 41942848U, 42073792U, 42204992U, 42334912U,
+ 42467008U, 42597824U, 42729152U, 42860096U, 42991552U, 43122368U, 43253696U,
+ 43382848U, 43515712U, 43646912U, 43777088U, 43907648U, 44039104U, 44170432U,
+ 44302144U, 44433344U, 44564288U, 44694976U, 44825152U, 44956864U, 45088448U,
+ 45219008U, 45350464U, 45481024U, 45612608U, 45744064U, 45874496U, 46006208U,
+ 46136768U, 46267712U, 46399424U, 46529344U, 46660672U, 46791488U, 46923328U,
+ 47053504U, 47185856U, 47316928U, 47447872U, 47579072U, 47710144U, 47839936U,
+ 47971648U, 48103232U, 48234176U, 48365248U, 48496192U, 48627136U, 48757312U,
+ 48889664U, 49020736U, 49149248U, 49283008U, 49413824U, 49545152U, 49675712U,
+ 49807168U, 49938368U, 50069056U, 50200256U, 50331584U, 50462656U, 50593472U,
+ 50724032U, 50853952U, 50986048U, 51117632U, 51248576U, 51379904U, 51510848U,
+ 51641792U, 51773248U, 51903296U, 52035136U, 52164032U, 52297664U, 52427968U,
+ 52557376U, 52690112U, 52821952U, 52952896U, 53081536U, 53213504U, 53344576U,
+ 53475776U, 53608384U, 53738816U, 53870528U, 54000832U, 54131776U, 54263744U,
+ 54394688U, 54525248U, 54655936U, 54787904U, 54918592U, 55049152U, 55181248U,
+ 55312064U, 55442752U, 55574336U, 55705024U, 55836224U, 55967168U, 56097856U,
+ 56228672U, 56358592U, 56490176U, 56621888U, 56753728U, 56884928U, 57015488U,
+ 57146816U, 57278272U, 57409216U, 57540416U, 57671104U, 57802432U, 57933632U,
+ 58064576U, 58195264U, 58326976U, 58457408U, 58588864U, 58720192U, 58849984U,
+ 58981696U, 59113024U, 59243456U, 59375552U, 59506624U, 59637568U, 59768512U,
+ 59897792U, 60030016U, 60161984U, 60293056U, 60423872U, 60554432U, 60683968U,
+ 60817216U, 60948032U, 61079488U, 61209664U, 61341376U, 61471936U, 61602752U,
+ 61733696U, 61865792U, 61996736U, 62127808U, 62259136U, 62389568U, 62520512U,
+ 62651584U, 62781632U, 62910784U, 63045056U, 63176128U, 63307072U, 63438656U,
+ 63569216U, 63700928U, 63831616U, 63960896U, 64093888U, 64225088U, 64355392U,
+ 64486976U, 64617664U, 64748608U, 64879424U, 65009216U, 65142464U, 65273792U,
+ 65402816U, 65535424U, 65666752U, 65797696U, 65927744U, 66060224U, 66191296U,
+ 66321344U, 66453056U, 66584384U, 66715328U, 66846656U, 66977728U, 67108672U,
+ 67239104U, 67370432U, 67501888U, 67631296U, 67763776U, 67895104U, 68026304U,
+ 68157248U, 68287936U, 68419264U, 68548288U, 68681408U, 68811968U, 68942912U,
+ 69074624U, 69205568U, 69337024U, 69467584U, 69599168U, 69729472U, 69861184U,
+ 69989824U, 70122944U, 70253888U, 70385344U, 70515904U, 70647232U, 70778816U,
+ 70907968U, 71040832U, 71171648U, 71303104U, 71432512U, 71564992U, 71695168U,
+ 71826368U, 71958464U, 72089536U, 72219712U, 72350144U, 72482624U, 72613568U,
+ 72744512U, 72875584U, 73006144U, 73138112U, 73268672U, 73400128U, 73530944U,
+ 73662272U, 73793344U, 73924544U, 74055104U, 74185792U, 74316992U, 74448832U,
+ 74579392U, 74710976U, 74841664U, 74972864U, 75102784U, 75233344U, 75364544U,
+ 75497024U, 75627584U, 75759296U, 75890624U, 76021696U, 76152256U, 76283072U,
+ 76414144U, 76545856U, 76676672U, 76806976U, 76937792U, 77070016U, 77200832U,
+ 77331392U, 77462464U, 77593664U, 77725376U, 77856448U, 77987776U, 78118336U,
+ 78249664U, 78380992U, 78511424U, 78642496U, 78773056U, 78905152U, 79033664U,
+ 79166656U, 79297472U, 79429568U, 79560512U, 79690816U, 79822784U, 79953472U,
+ 80084672U, 80214208U, 80346944U, 80477632U, 80608576U, 80740288U, 80870848U,
+ 81002048U, 81133504U, 81264448U, 81395648U, 81525952U, 81657536U, 81786304U,
+ 81919808U, 82050112U, 82181312U, 82311616U, 82443968U, 82573376U, 82705984U,
+ 82835776U, 82967744U, 83096768U, 83230528U, 83359552U, 83491264U, 83622464U,
+ 83753536U, 83886016U, 84015296U, 84147776U, 84277184U, 84409792U, 84540608U,
+ 84672064U, 84803008U, 84934336U, 85065152U, 85193792U, 85326784U, 85458496U,
+ 85589312U, 85721024U, 85851968U, 85982656U, 86112448U, 86244416U, 86370112U,
+ 86506688U, 86637632U, 86769344U, 86900672U, 87031744U, 87162304U, 87293632U,
+ 87424576U, 87555392U, 87687104U, 87816896U, 87947968U, 88079168U, 88211264U,
+ 88341824U, 88473152U, 88603712U, 88735424U, 88862912U, 88996672U, 89128384U,
+ 89259712U, 89390272U, 89521984U, 89652544U, 89783872U, 89914816U, 90045376U,
+ 90177088U, 90307904U, 90438848U, 90569152U, 90700096U, 90832832U, 90963776U,
+ 91093696U, 91223744U, 91356992U, 91486784U, 91618496U, 91749824U, 91880384U,
+ 92012224U, 92143552U, 92273344U, 92405696U, 92536768U, 92666432U, 92798912U,
+ 92926016U, 93060544U, 93192128U, 93322816U, 93453632U, 93583936U, 93715136U,
+ 93845056U, 93977792U, 94109504U, 94240448U, 94371776U, 94501184U, 94632896U,
+ 94764224U, 94895552U, 95023424U, 95158208U, 95287744U, 95420224U, 95550016U,
+ 95681216U, 95811904U, 95943872U, 96075328U, 96203584U, 96337856U, 96468544U,
+ 96599744U, 96731072U, 96860992U, 96992576U, 97124288U, 97254848U, 97385536U,
+ 97517248U, 97647808U, 97779392U, 97910464U, 98041408U, 98172608U, 98303168U,
+ 98434496U, 98565568U, 98696768U, 98827328U, 98958784U, 99089728U, 99220928U,
+ 99352384U, 99482816U, 99614272U, 99745472U, 99876416U, 100007104U,
+ 100138048U, 100267072U, 100401088U, 100529984U, 100662592U, 100791872U,
+ 100925248U, 101056064U, 101187392U, 101317952U, 101449408U, 101580608U,
+ 101711296U, 101841728U, 101973824U, 102104896U, 102235712U, 102366016U,
+ 102498112U, 102628672U, 102760384U, 102890432U, 103021888U, 103153472U,
+ 103284032U, 103415744U, 103545152U, 103677248U, 103808576U, 103939648U,
+ 104070976U, 104201792U, 104332736U, 104462528U, 104594752U, 104725952U,
+ 104854592U, 104988608U, 105118912U, 105247808U, 105381184U, 105511232U,
+ 105643072U, 105774784U, 105903296U, 106037056U, 106167872U, 106298944U,
+ 106429504U, 106561472U, 106691392U, 106822592U, 106954304U, 107085376U,
+ 107216576U, 107346368U, 107478464U, 107609792U, 107739712U, 107872192U,
+ 108003136U, 108131392U, 108265408U, 108396224U, 108527168U, 108657344U,
+ 108789568U, 108920384U, 109049792U, 109182272U, 109312576U, 109444928U,
+ 109572928U, 109706944U, 109837888U, 109969088U, 110099648U, 110230976U,
+ 110362432U, 110492992U, 110624704U, 110755264U, 110886208U, 111017408U,
+ 111148864U, 111279296U, 111410752U, 111541952U, 111673024U, 111803456U,
+ 111933632U, 112066496U, 112196416U, 112328512U, 112457792U, 112590784U,
+ 112715968U, 112852672U, 112983616U, 113114944U, 113244224U, 113376448U,
+ 113505472U, 113639104U, 113770304U, 113901376U, 114031552U, 114163264U,
+ 114294592U, 114425536U, 114556864U, 114687424U, 114818624U, 114948544U,
+ 115080512U, 115212224U, 115343296U, 115473472U, 115605184U, 115736128U,
+ 115867072U, 115997248U, 116128576U, 116260288U, 116391488U, 116522944U,
+ 116652992U, 116784704U, 116915648U, 117046208U, 117178304U, 117308608U,
+ 117440192U, 117569728U, 117701824U, 117833024U, 117964096U, 118094656U,
+ 118225984U, 118357312U, 118489024U, 118617536U, 118749632U, 118882112U,
+ 119012416U, 119144384U, 119275328U, 119406016U, 119537344U, 119668672U,
+ 119798464U, 119928896U, 120061376U, 120192832U, 120321728U, 120454336U,
+ 120584512U, 120716608U, 120848192U, 120979136U, 121109056U, 121241408U,
+ 121372352U, 121502912U, 121634752U, 121764416U, 121895744U, 122027072U,
+ 122157632U, 122289088U, 122421184U, 122550592U, 122682944U, 122813888U,
+ 122945344U, 123075776U, 123207488U, 123338048U, 123468736U, 123600704U,
+ 123731264U, 123861952U, 123993664U, 124124608U, 124256192U, 124386368U,
+ 124518208U, 124649024U, 124778048U, 124911296U, 125041088U, 125173696U,
+ 125303744U, 125432896U, 125566912U, 125696576U, 125829056U, 125958592U,
+ 126090304U, 126221248U, 126352832U, 126483776U, 126615232U, 126746432U,
+ 126876608U, 127008704U, 127139392U, 127270336U, 127401152U, 127532224U,
+ 127663552U, 127794752U, 127925696U, 128055232U, 128188096U, 128319424U,
+ 128449856U, 128581312U, 128712256U, 128843584U, 128973632U, 129103808U,
+ 129236288U, 129365696U, 129498944U, 129629888U, 129760832U, 129892288U,
+ 130023104U, 130154048U, 130283968U, 130416448U, 130547008U, 130678336U,
+ 130807616U, 130939456U, 131071552U, 131202112U, 131331776U, 131464384U,
+ 131594048U, 131727296U, 131858368U, 131987392U, 132120256U, 132250816U,
+ 132382528U, 132513728U, 132644672U, 132774976U, 132905792U, 133038016U,
+ 133168832U, 133299392U, 133429312U, 133562048U, 133692992U, 133823296U,
+ 133954624U, 134086336U, 134217152U, 134348608U, 134479808U, 134607296U,
+ 134741056U, 134872384U, 135002944U, 135134144U, 135265472U, 135396544U,
+ 135527872U, 135659072U, 135787712U, 135921472U, 136052416U, 136182848U,
+ 136313792U, 136444864U, 136576448U, 136707904U, 136837952U, 136970048U,
+ 137099584U, 137232064U, 137363392U, 137494208U, 137625536U, 137755712U,
+ 137887424U, 138018368U, 138149824U, 138280256U, 138411584U, 138539584U,
+ 138672832U, 138804928U, 138936128U, 139066688U, 139196864U, 139328704U,
+ 139460032U, 139590208U, 139721024U, 139852864U, 139984576U, 140115776U,
+ 140245696U, 140376512U, 140508352U, 140640064U, 140769856U, 140902336U,
+ 141032768U, 141162688U, 141294016U, 141426496U, 141556544U, 141687488U,
+ 141819584U, 141949888U, 142080448U, 142212544U, 142342336U, 142474432U,
+ 142606144U, 142736192U, 142868288U, 142997824U, 143129408U, 143258944U,
+ 143392448U, 143523136U, 143653696U, 143785024U, 143916992U, 144045632U,
+ 144177856U, 144309184U, 144440768U, 144570688U, 144701888U, 144832448U,
+ 144965056U, 145096384U, 145227584U, 145358656U, 145489856U, 145620928U,
+ 145751488U, 145883072U, 146011456U, 146144704U, 146275264U, 146407232U,
+ 146538176U, 146668736U, 146800448U, 146931392U, 147062336U, 147193664U,
+ 147324224U, 147455936U, 147586624U, 147717056U, 147848768U, 147979456U,
+ 148110784U, 148242368U, 148373312U, 148503232U, 148635584U, 148766144U,
+ 148897088U, 149028416U, 149159488U, 149290688U, 149420224U, 149551552U,
+ 149683136U, 149814976U, 149943616U, 150076352U, 150208064U, 150338624U,
+ 150470464U, 150600256U, 150732224U, 150862784U, 150993088U, 151125952U,
+ 151254976U, 151388096U, 151519168U, 151649728U, 151778752U, 151911104U,
+ 152042944U, 152174144U, 152304704U, 152435648U, 152567488U, 152698816U,
+ 152828992U, 152960576U, 153091648U, 153222976U, 153353792U, 153484096U,
+ 153616192U, 153747008U, 153878336U, 154008256U, 154139968U, 154270912U,
+ 154402624U, 154533824U, 154663616U, 154795712U, 154926272U, 155057984U,
+ 155188928U, 155319872U, 155450816U, 155580608U, 155712064U, 155843392U,
+ 155971136U, 156106688U, 156237376U, 156367424U, 156499264U, 156630976U,
+ 156761536U, 156892352U, 157024064U, 157155008U, 157284416U, 157415872U,
+ 157545536U, 157677248U, 157810496U, 157938112U, 158071744U, 158203328U,
+ 158334656U, 158464832U, 158596288U, 158727616U, 158858048U, 158988992U,
+ 159121216U, 159252416U, 159381568U, 159513152U, 159645632U, 159776192U,
+ 159906496U, 160038464U, 160169536U, 160300352U, 160430656U, 160563008U,
+ 160693952U, 160822208U, 160956352U, 161086784U, 161217344U, 161349184U,
+ 161480512U, 161611456U, 161742272U, 161873216U, 162002752U, 162135872U,
+ 162266432U, 162397888U, 162529216U, 162660032U, 162790976U, 162922048U,
+ 163052096U, 163184576U, 163314752U, 163446592U, 163577408U, 163707968U,
+ 163839296U, 163969984U, 164100928U, 164233024U, 164364224U, 164494912U,
+ 164625856U, 164756672U, 164887616U, 165019072U, 165150016U, 165280064U,
+ 165412672U, 165543104U, 165674944U, 165805888U, 165936832U, 166067648U,
+ 166198336U, 166330048U, 166461248U, 166591552U, 166722496U, 166854208U,
+ 166985408U, 167116736U, 167246656U, 167378368U, 167508416U, 167641024U,
+ 167771584U, 167903168U, 168034112U, 168164032U, 168295744U, 168427456U,
+ 168557632U, 168688448U, 168819136U, 168951616U, 169082176U, 169213504U,
+ 169344832U, 169475648U, 169605952U, 169738048U, 169866304U, 169999552U,
+ 170131264U, 170262464U, 170393536U, 170524352U, 170655424U, 170782016U,
+ 170917696U, 171048896U, 171179072U, 171310784U, 171439936U, 171573184U,
+ 171702976U, 171835072U, 171966272U, 172097216U, 172228288U, 172359232U,
+ 172489664U, 172621376U, 172747712U, 172883264U, 173014208U, 173144512U,
+ 173275072U, 173407424U, 173539136U, 173669696U, 173800768U, 173931712U,
+ 174063424U, 174193472U, 174325696U, 174455744U, 174586816U, 174718912U,
+ 174849728U, 174977728U, 175109696U, 175242688U, 175374272U, 175504832U,
+ 175636288U, 175765696U, 175898432U, 176028992U, 176159936U, 176291264U,
+ 176422592U, 176552512U, 176684864U, 176815424U, 176946496U, 177076544U,
+ 177209152U, 177340096U, 177470528U, 177600704U, 177731648U, 177864256U,
+ 177994816U, 178126528U, 178257472U, 178387648U, 178518464U, 178650176U,
+ 178781888U, 178912064U, 179044288U, 179174848U, 179305024U, 179436736U,
+ 179568448U, 179698496U, 179830208U, 179960512U, 180092608U, 180223808U,
+ 180354752U, 180485696U, 180617152U, 180748096U, 180877504U, 181009984U,
+ 181139264U, 181272512U, 181402688U, 181532608U, 181663168U, 181795136U,
+ 181926592U, 182057536U, 182190016U, 182320192U, 182451904U, 182582336U,
+ 182713792U, 182843072U, 182976064U, 183107264U, 183237056U, 183368384U,
+ 183494848U, 183631424U, 183762752U, 183893824U, 184024768U, 184154816U,
+ 184286656U, 184417984U, 184548928U, 184680128U, 184810816U, 184941248U,
+ 185072704U, 185203904U, 185335616U, 185465408U, 185596352U, 185727296U,
+ 185859904U, 185989696U, 186121664U, 186252992U, 186383552U, 186514112U,
+ 186645952U, 186777152U, 186907328U, 187037504U, 187170112U, 187301824U,
+ 187429184U, 187562048U, 187693504U, 187825472U, 187957184U, 188087104U,
+ 188218304U, 188349376U, 188481344U, 188609728U, 188743616U, 188874304U,
+ 189005248U, 189136448U, 189265088U, 189396544U, 189528128U, 189660992U,
+ 189791936U, 189923264U, 190054208U, 190182848U, 190315072U, 190447424U,
+ 190577984U, 190709312U, 190840768U, 190971328U, 191102656U, 191233472U,
+ 191364032U, 191495872U, 191626816U, 191758016U, 191888192U, 192020288U,
+ 192148928U, 192282176U, 192413504U, 192542528U, 192674752U, 192805952U,
+ 192937792U, 193068608U, 193198912U, 193330496U, 193462208U, 193592384U,
+ 193723456U, 193854272U, 193985984U, 194116672U, 194247232U, 194379712U,
+ 194508352U, 194641856U, 194772544U, 194900672U, 195035072U, 195166016U,
+ 195296704U, 195428032U, 195558592U, 195690304U, 195818176U, 195952576U,
+ 196083392U, 196214336U, 196345792U, 196476736U, 196607552U, 196739008U,
+ 196869952U, 197000768U, 197130688U, 197262784U, 197394368U, 197523904U,
+ 197656384U, 197787584U, 197916608U, 198049472U, 198180544U, 198310208U,
+ 198442432U, 198573632U, 198705088U, 198834368U, 198967232U, 199097792U,
+ 199228352U, 199360192U, 199491392U, 199621696U, 199751744U, 199883968U,
+ 200014016U, 200146624U, 200276672U, 200408128U, 200540096U, 200671168U,
+ 200801984U, 200933312U, 201062464U, 201194944U, 201326144U, 201457472U,
+ 201588544U, 201719744U, 201850816U, 201981632U, 202111552U, 202244032U,
+ 202374464U, 202505152U, 202636352U, 202767808U, 202898368U, 203030336U,
+ 203159872U, 203292608U, 203423296U, 203553472U, 203685824U, 203816896U,
+ 203947712U, 204078272U, 204208192U, 204341056U, 204472256U, 204603328U,
+ 204733888U, 204864448U, 204996544U, 205125568U, 205258304U, 205388864U,
+ 205517632U, 205650112U, 205782208U, 205913536U, 206044736U, 206176192U,
+ 206307008U, 206434496U, 206569024U, 206700224U, 206831168U, 206961856U,
+ 207093056U, 207223616U, 207355328U, 207486784U, 207616832U, 207749056U,
+ 207879104U, 208010048U, 208141888U, 208273216U, 208404032U, 208534336U,
+ 208666048U, 208796864U, 208927424U, 209059264U, 209189824U, 209321792U,
+ 209451584U, 209582656U, 209715136U, 209845568U, 209976896U, 210106432U,
+ 210239296U, 210370112U, 210501568U, 210630976U, 210763712U, 210894272U,
+ 211024832U, 211156672U, 211287616U, 211418176U, 211549376U, 211679296U,
+ 211812032U, 211942592U, 212074432U, 212204864U, 212334016U, 212467648U,
+ 212597824U, 212727616U, 212860352U, 212991424U, 213120832U, 213253952U,
+ 213385024U, 213515584U, 213645632U, 213777728U, 213909184U, 214040128U,
+ 214170688U, 214302656U, 214433728U, 214564544U, 214695232U, 214826048U,
+ 214956992U, 215089088U, 215219776U, 215350592U, 215482304U, 215613248U,
+ 215743552U, 215874752U, 216005312U, 216137024U, 216267328U, 216399296U,
+ 216530752U, 216661696U, 216790592U, 216923968U, 217054528U, 217183168U,
+ 217316672U, 217448128U, 217579072U, 217709504U, 217838912U, 217972672U,
+ 218102848U, 218233024U, 218364736U, 218496832U, 218627776U, 218759104U,
+ 218888896U, 219021248U, 219151936U, 219281728U, 219413056U, 219545024U,
+ 219675968U, 219807296U, 219938624U, 220069312U, 220200128U, 220331456U,
+ 220461632U, 220592704U, 220725184U, 220855744U, 220987072U, 221117888U,
+ 221249216U, 221378368U, 221510336U, 221642048U, 221772736U, 221904832U,
+ 222031808U, 222166976U, 222297536U, 222428992U, 222559936U, 222690368U,
+ 222820672U, 222953152U, 223083968U, 223213376U, 223345984U, 223476928U,
+ 223608512U, 223738688U, 223869376U, 224001472U, 224132672U, 224262848U,
+ 224394944U, 224524864U, 224657344U, 224788288U, 224919488U, 225050432U,
+ 225181504U, 225312704U, 225443776U, 225574592U, 225704768U, 225834176U,
+ 225966784U, 226097216U, 226229824U, 226360384U, 226491712U, 226623424U,
+ 226754368U, 226885312U, 227015104U, 227147456U, 227278528U, 227409472U,
+ 227539904U, 227669696U, 227802944U, 227932352U, 228065216U, 228196288U,
+ 228326464U, 228457792U, 228588736U, 228720064U, 228850112U, 228981056U,
+ 229113152U, 229243328U, 229375936U, 229505344U, 229636928U, 229769152U,
+ 229894976U, 230030272U, 230162368U, 230292416U, 230424512U, 230553152U,
+ 230684864U, 230816704U, 230948416U, 231079616U, 231210944U, 231342016U,
+ 231472448U, 231603776U, 231733952U, 231866176U, 231996736U, 232127296U,
+ 232259392U, 232388672U, 232521664U, 232652608U, 232782272U, 232914496U,
+ 233043904U, 233175616U, 233306816U, 233438528U, 233569984U, 233699776U,
+ 233830592U, 233962688U, 234092224U, 234221888U, 234353984U, 234485312U,
+ 234618304U, 234749888U, 234880832U, 235011776U, 235142464U, 235274048U,
+ 235403456U, 235535936U, 235667392U, 235797568U, 235928768U, 236057152U,
+ 236190272U, 236322752U, 236453312U, 236583616U, 236715712U, 236846528U,
+ 236976448U, 237108544U, 237239104U, 237371072U, 237501632U, 237630784U,
+ 237764416U, 237895232U, 238026688U, 238157632U, 238286912U, 238419392U,
+ 238548032U, 238681024U, 238812608U, 238941632U, 239075008U, 239206336U,
+ 239335232U, 239466944U, 239599168U, 239730496U, 239861312U, 239992384U,
+ 240122816U, 240254656U, 240385856U, 240516928U, 240647872U, 240779072U,
+ 240909632U, 241040704U, 241171904U, 241302848U, 241433408U, 241565248U,
+ 241696192U, 241825984U, 241958848U, 242088256U, 242220224U, 242352064U,
+ 242481856U, 242611648U, 242744896U, 242876224U, 243005632U, 243138496U,
+ 243268672U, 243400384U, 243531712U, 243662656U, 243793856U, 243924544U,
+ 244054592U, 244187072U, 244316608U, 244448704U, 244580032U, 244710976U,
+ 244841536U, 244972864U, 245104448U, 245233984U, 245365312U, 245497792U,
+ 245628736U, 245759936U, 245889856U, 246021056U, 246152512U, 246284224U,
+ 246415168U, 246545344U, 246675904U, 246808384U, 246939584U, 247070144U,
+ 247199552U, 247331648U, 247463872U, 247593536U, 247726016U, 247857088U,
+ 247987648U, 248116928U, 248249536U, 248380736U, 248512064U, 248643008U,
+ 248773312U, 248901056U, 249036608U, 249167552U, 249298624U, 249429184U,
+ 249560512U, 249692096U, 249822784U, 249954112U, 250085312U, 250215488U,
+ 250345792U, 250478528U, 250608704U, 250739264U, 250870976U, 251002816U,
+ 251133632U, 251263552U, 251395136U, 251523904U, 251657792U, 251789248U,
+ 251919424U, 252051392U, 252182464U, 252313408U, 252444224U, 252575552U,
+ 252706624U, 252836032U, 252968512U, 253099712U, 253227584U, 253361728U,
+ 253493056U, 253623488U, 253754432U, 253885504U, 254017216U, 254148032U,
+ 254279488U, 254410432U, 254541376U, 254672576U, 254803264U, 254933824U,
+ 255065792U, 255196736U, 255326528U, 255458752U, 255589952U, 255721408U,
+ 255851072U, 255983296U, 256114624U, 256244416U, 256374208U, 256507712U,
+ 256636096U, 256768832U, 256900544U, 257031616U, 257162176U, 257294272U,
+ 257424448U, 257555776U, 257686976U, 257818432U, 257949632U, 258079552U,
+ 258211136U, 258342464U, 258473408U, 258603712U, 258734656U, 258867008U,
+ 258996544U, 259127744U, 259260224U, 259391296U, 259522112U, 259651904U,
+ 259784384U, 259915328U, 260045888U, 260175424U, 260308544U, 260438336U,
+ 260570944U, 260700992U, 260832448U, 260963776U, 261092672U, 261226304U,
+ 261356864U, 261487936U, 261619648U, 261750592U, 261879872U, 262011968U,
+ 262143424U, 262274752U, 262404416U, 262537024U, 262667968U, 262799296U,
+ 262928704U, 263061184U, 263191744U, 263322944U, 263454656U, 263585216U,
+ 263716672U, 263847872U, 263978944U, 264108608U, 264241088U, 264371648U,
+ 264501184U, 264632768U, 264764096U, 264895936U, 265024576U, 265158464U,
+ 265287488U, 265418432U, 265550528U, 265681216U, 265813312U, 265943488U,
+ 266075968U, 266206144U, 266337728U, 266468032U, 266600384U, 266731072U,
+ 266862272U, 266993344U, 267124288U, 267255616U, 267386432U, 267516992U,
+ 267648704U, 267777728U, 267910592U, 268040512U, 268172096U, 268302784U,
+ 268435264U, 268566208U, 268696256U, 268828096U, 268959296U, 269090368U,
+ 269221312U, 269352256U, 269482688U, 269614784U, 269745856U, 269876416U,
+ 270007616U, 270139328U, 270270272U, 270401216U, 270531904U, 270663616U,
+ 270791744U, 270924736U, 271056832U, 271186112U, 271317184U, 271449536U,
+ 271580992U, 271711936U, 271843136U, 271973056U, 272105408U, 272236352U,
+ 272367296U, 272498368U, 272629568U, 272759488U, 272891456U, 273022784U,
+ 273153856U, 273284672U, 273415616U, 273547072U, 273677632U, 273808448U,
+ 273937088U, 274071488U, 274200896U, 274332992U, 274463296U, 274595392U,
+ 274726208U, 274857536U, 274988992U, 275118656U, 275250496U, 275382208U,
+ 275513024U, 275643968U, 275775296U, 275906368U, 276037184U, 276167872U,
+ 276297664U, 276429376U, 276560576U, 276692672U, 276822976U, 276955072U,
+ 277085632U, 277216832U, 277347008U, 277478848U, 277609664U, 277740992U,
+ 277868608U, 278002624U, 278134336U, 278265536U, 278395328U, 278526784U,
+ 278657728U, 278789824U, 278921152U, 279052096U, 279182912U, 279313088U,
+ 279443776U, 279576256U, 279706048U, 279838528U, 279969728U, 280099648U,
+ 280230976U, 280361408U, 280493632U, 280622528U, 280755392U, 280887104U,
+ 281018176U, 281147968U, 281278912U, 281411392U, 281542592U, 281673152U,
+ 281803712U, 281935552U, 282066496U, 282197312U, 282329024U, 282458816U,
+ 282590272U, 282720832U, 282853184U, 282983744U, 283115072U, 283246144U,
+ 283377344U, 283508416U, 283639744U, 283770304U, 283901504U, 284032576U,
+ 284163136U, 284294848U, 284426176U, 284556992U, 284687296U, 284819264U,
+ 284950208U, 285081536U
+};
+
+#ifdef __cplusplus
+}
+#endif \ No newline at end of file
diff --git a/Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash/endian.h b/Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash/endian.h
new file mode 100644
index 000000000..9ca842e47
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash/endian.h
@@ -0,0 +1,74 @@
+#pragma once
+
+#include <stdint.h>
+#include "compiler.h"
+
+static const uint8_t BitReverseTable256[] =
+ {
+ 0x00, 0x80, 0x40, 0xC0, 0x20, 0xA0, 0x60, 0xE0, 0x10, 0x90, 0x50, 0xD0, 0x30, 0xB0, 0x70, 0xF0,
+ 0x08, 0x88, 0x48, 0xC8, 0x28, 0xA8, 0x68, 0xE8, 0x18, 0x98, 0x58, 0xD8, 0x38, 0xB8, 0x78, 0xF8,
+ 0x04, 0x84, 0x44, 0xC4, 0x24, 0xA4, 0x64, 0xE4, 0x14, 0x94, 0x54, 0xD4, 0x34, 0xB4, 0x74, 0xF4,
+ 0x0C, 0x8C, 0x4C, 0xCC, 0x2C, 0xAC, 0x6C, 0xEC, 0x1C, 0x9C, 0x5C, 0xDC, 0x3C, 0xBC, 0x7C, 0xFC,
+ 0x02, 0x82, 0x42, 0xC2, 0x22, 0xA2, 0x62, 0xE2, 0x12, 0x92, 0x52, 0xD2, 0x32, 0xB2, 0x72, 0xF2,
+ 0x0A, 0x8A, 0x4A, 0xCA, 0x2A, 0xAA, 0x6A, 0xEA, 0x1A, 0x9A, 0x5A, 0xDA, 0x3A, 0xBA, 0x7A, 0xFA,
+ 0x06, 0x86, 0x46, 0xC6, 0x26, 0xA6, 0x66, 0xE6, 0x16, 0x96, 0x56, 0xD6, 0x36, 0xB6, 0x76, 0xF6,
+ 0x0E, 0x8E, 0x4E, 0xCE, 0x2E, 0xAE, 0x6E, 0xEE, 0x1E, 0x9E, 0x5E, 0xDE, 0x3E, 0xBE, 0x7E, 0xFE,
+ 0x01, 0x81, 0x41, 0xC1, 0x21, 0xA1, 0x61, 0xE1, 0x11, 0x91, 0x51, 0xD1, 0x31, 0xB1, 0x71, 0xF1,
+ 0x09, 0x89, 0x49, 0xC9, 0x29, 0xA9, 0x69, 0xE9, 0x19, 0x99, 0x59, 0xD9, 0x39, 0xB9, 0x79, 0xF9,
+ 0x05, 0x85, 0x45, 0xC5, 0x25, 0xA5, 0x65, 0xE5, 0x15, 0x95, 0x55, 0xD5, 0x35, 0xB5, 0x75, 0xF5,
+ 0x0D, 0x8D, 0x4D, 0xCD, 0x2D, 0xAD, 0x6D, 0xED, 0x1D, 0x9D, 0x5D, 0xDD, 0x3D, 0xBD, 0x7D, 0xFD,
+ 0x03, 0x83, 0x43, 0xC3, 0x23, 0xA3, 0x63, 0xE3, 0x13, 0x93, 0x53, 0xD3, 0x33, 0xB3, 0x73, 0xF3,
+ 0x0B, 0x8B, 0x4B, 0xCB, 0x2B, 0xAB, 0x6B, 0xEB, 0x1B, 0x9B, 0x5B, 0xDB, 0x3B, 0xBB, 0x7B, 0xFB,
+ 0x07, 0x87, 0x47, 0xC7, 0x27, 0xA7, 0x67, 0xE7, 0x17, 0x97, 0x57, 0xD7, 0x37, 0xB7, 0x77, 0xF7,
+ 0x0F, 0x8F, 0x4F, 0xCF, 0x2F, 0xAF, 0x6F, 0xEF, 0x1F, 0x9F, 0x5F, 0xDF, 0x3F, 0xBF, 0x7F, 0xFF
+ };
+
+static inline uint32_t bitfn_swap32(uint32_t a) {
+ return (BitReverseTable256[a & 0xff] << 24) |
+ (BitReverseTable256[(a >> 8) & 0xff] << 16) |
+ (BitReverseTable256[(a >> 16) & 0xff] << 8) |
+ (BitReverseTable256[(a >> 24) & 0xff]);
+}
+
+static inline uint64_t bitfn_swap64(uint64_t a) {
+ return ((uint64_t) bitfn_swap32((uint32_t) (a >> 32))) |
+ (((uint64_t) bitfn_swap32((uint32_t) a)) << 32);
+}
+
+#if defined(__MINGW32__) || defined(_WIN32)
+ # define LITTLE_ENDIAN 1234
+ # define BYTE_ORDER LITTLE_ENDIAN
+#elif defined(__FreeBSD__) || defined(__DragonFly__) || defined(__NetBSD__)
+ # include <sys/endian.h>
+#elif defined(__OpenBSD__) || defined(__SVR4)
+ # include <sys/types.h>
+#elif defined(__APPLE__)
+# include <machine/endian.h>
+#elif defined( BSD ) && (BSD >= 199103)
+ # include <machine/endian.h>
+#elif defined( __QNXNTO__ ) && defined( __LITTLEENDIAN__ )
+ # define LITTLE_ENDIAN 1234
+ # define BYTE_ORDER LITTLE_ENDIAN
+#elif defined( __QNXNTO__ ) && defined( __BIGENDIAN__ )
+ # define BIG_ENDIAN 1234
+ # define BYTE_ORDER BIG_ENDIAN
+#else
+
+# include <endian.h>
+
+#endif
+
+
+#if LITTLE_ENDIAN == BYTE_ORDER
+
+#define fix_endian32(x) (x)
+#define fix_endian64(x) (x)
+
+#elif BIG_ENDIAN == BYTE_ORDER
+
+#define fix_endian32(x) bitfn_swap32(x)
+#define fix_endian64(x) bitfn_swap64(x)
+
+#else
+# error "endian not supported"
+#endif // BYTE_ORDER \ No newline at end of file
diff --git a/Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash/ethash.h b/Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash/ethash.h
new file mode 100644
index 000000000..a7159de65
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash/ethash.h
@@ -0,0 +1,116 @@
+/*
+ This file is part of ethash.
+
+ ethash is free software: you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation, either version 3 of the License, or
+ (at your option) any later version.
+
+ ethash is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with ethash. If not, see <http://www.gnu.org/licenses/>.
+*/
+
+/** @file ethash.h
+* @date 2015
+*/
+#pragma once
+
+#include <stdint.h>
+#include <stdbool.h>
+#include <string.h>
+#include <stddef.h>
+#include "compiler.h"
+
+#define REVISION 23
+#define DATASET_BYTES_INIT 1073741824U // 2**30
+#define DATASET_BYTES_GROWTH 8388608U // 2**23
+#define CACHE_BYTES_INIT 1073741824U // 2**24
+#define CACHE_BYTES_GROWTH 131072U // 2**17
+#define EPOCH_LENGTH 30000U
+#define MIX_BYTES 128
+#define HASH_BYTES 64
+#define DATASET_PARENTS 256
+#define CACHE_ROUNDS 3
+#define ACCESSES 64
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+typedef struct ethash_params {
+ size_t full_size; // Size of full data set (in bytes, multiple of mix size (128)).
+ size_t cache_size; // Size of compute cache (in bytes, multiple of node size (64)).
+} ethash_params;
+
+typedef struct ethash_return_value {
+ uint8_t result[32];
+ uint8_t mix_hash[32];
+} ethash_return_value;
+
+size_t ethash_get_datasize(const uint32_t block_number);
+size_t ethash_get_cachesize(const uint32_t block_number);
+
+// initialize the parameters
+static inline void ethash_params_init(ethash_params *params, const uint32_t block_number) {
+ params->full_size = ethash_get_datasize(block_number);
+ params->cache_size = ethash_get_cachesize(block_number);
+}
+
+typedef struct ethash_cache {
+ void *mem;
+} ethash_cache;
+
+void ethash_mkcache(ethash_cache *cache, ethash_params const *params, const uint8_t seed[32]);
+void ethash_compute_full_data(void *mem, ethash_params const *params, ethash_cache const *cache);
+void ethash_full(ethash_return_value *ret, void const *full_mem, ethash_params const *params, const uint8_t header_hash[32], const uint64_t nonce);
+void ethash_light(ethash_return_value *ret, ethash_cache const *cache, ethash_params const *params, const uint8_t header_hash[32], const uint64_t nonce);
+void ethash_get_seedhash(uint8_t seedhash[32], const uint32_t block_number);
+
+static inline void ethash_prep_light(void *cache, ethash_params const *params, const uint8_t seed[32]) {
+ ethash_cache c;
+ c.mem = cache;
+ ethash_mkcache(&c, params, seed);
+}
+
+static inline void ethash_compute_light(ethash_return_value *ret, void const *cache, ethash_params const *params, const uint8_t header_hash[32], const uint64_t nonce) {
+ ethash_cache c;
+ c.mem = (void *) cache;
+ ethash_light(ret, &c, params, header_hash, nonce);
+}
+
+static inline void ethash_prep_full(void *full, ethash_params const *params, void const *cache) {
+ ethash_cache c;
+ c.mem = (void *) cache;
+ ethash_compute_full_data(full, params, &c);
+}
+
+static inline void ethash_compute_full(ethash_return_value *ret, void const *full, ethash_params const *params, const uint8_t header_hash[32], const uint64_t nonce) {
+ ethash_full(ret, full, params, header_hash, nonce);
+}
+
+// Returns if hash is less than or equal to difficulty
+static inline int ethash_check_difficulty(
+ const uint8_t hash[32],
+ const uint8_t difficulty[32]) {
+ // Difficulty is big endian
+ for (int i = 0; i < 32; i++) {
+ if (hash[i] == difficulty[i]) continue;
+ return hash[i] < difficulty[i];
+ }
+ return 1;
+}
+
+int ethash_quick_check_difficulty(
+ const uint8_t header_hash[32],
+ const uint64_t nonce,
+ const uint8_t mix_hash[32],
+ const uint8_t difficulty[32]);
+
+#ifdef __cplusplus
+}
+#endif
diff --git a/Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash/fnv.h b/Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash/fnv.h
new file mode 100644
index 000000000..edabeaae2
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash/fnv.h
@@ -0,0 +1,38 @@
+/*
+ This file is part of cpp-ethereum.
+
+ cpp-ethereum is free software: you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation, either version 3 of the License, or
+ (at your option) any later version.
+
+ cpp-ethereum is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with cpp-ethereum. If not, see <http://www.gnu.org/licenses/>.
+*/
+/** @file fnv.h
+* @author Matthew Wampler-Doty <negacthulhu@gmail.com>
+* @date 2015
+*/
+
+#pragma once
+#include <stdint.h>
+#include "compiler.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+#define FNV_PRIME 0x01000193
+
+static inline uint32_t fnv_hash(const uint32_t x, const uint32_t y) {
+ return x*FNV_PRIME ^ y;
+}
+
+#ifdef __cplusplus
+}
+#endif \ No newline at end of file
diff --git a/Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash/internal.c b/Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash/internal.c
new file mode 100644
index 000000000..0a7e767e7
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash/internal.c
@@ -0,0 +1,300 @@
+/*
+ This file is part of ethash.
+
+ ethash is free software: you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation, either version 3 of the License, or
+ (at your option) any later version.
+
+ ethash is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with cpp-ethereum. If not, see <http://www.gnu.org/licenses/>.
+*/
+/** @file internal.c
+* @author Tim Hughes <tim@twistedfury.com>
+* @author Matthew Wampler-Doty
+* @date 2015
+*/
+
+#include <assert.h>
+#include <inttypes.h>
+#include <stddef.h>
+#include "ethash.h"
+#include "fnv.h"
+#include "endian.h"
+#include "internal.h"
+#include "data_sizes.h"
+
+#ifdef WITH_CRYPTOPP
+
+#include "sha3_cryptopp.h"
+
+#else
+#include "sha3.h"
+#endif // WITH_CRYPTOPP
+
+size_t ethash_get_datasize(const uint32_t block_number) {
+ assert(block_number / EPOCH_LENGTH < 2048);
+ return dag_sizes[block_number / EPOCH_LENGTH];
+}
+
+size_t ethash_get_cachesize(const uint32_t block_number) {
+ assert(block_number / EPOCH_LENGTH < 2048);
+ return cache_sizes[block_number / EPOCH_LENGTH];
+}
+
+// Follows Sergio's "STRICT MEMORY HARD HASHING FUNCTIONS" (2014)
+// https://bitslog.files.wordpress.com/2013/12/memohash-v0-3.pdf
+// SeqMemoHash(s, R, N)
+void static ethash_compute_cache_nodes(
+ node *const nodes,
+ ethash_params const *params,
+ const uint8_t seed[32]) {
+ assert((params->cache_size % sizeof(node)) == 0);
+ uint32_t const num_nodes = (uint32_t) (params->cache_size / sizeof(node));
+
+ SHA3_512(nodes[0].bytes, seed, 32);
+
+ for (unsigned i = 1; i != num_nodes; ++i) {
+ SHA3_512(nodes[i].bytes, nodes[i - 1].bytes, 64);
+ }
+
+ for (unsigned j = 0; j != CACHE_ROUNDS; j++) {
+ for (unsigned i = 0; i != num_nodes; i++) {
+ uint32_t const idx = nodes[i].words[0] % num_nodes;
+ node data;
+ data = nodes[(num_nodes - 1 + i) % num_nodes];
+ for (unsigned w = 0; w != NODE_WORDS; ++w) {
+ data.words[w] ^= nodes[idx].words[w];
+ }
+ SHA3_512(nodes[i].bytes, data.bytes, sizeof(data));
+ }
+ }
+
+ // now perform endian conversion
+#if BYTE_ORDER != LITTLE_ENDIAN
+ for (unsigned w = 0; w != (num_nodes*NODE_WORDS); ++w)
+ {
+ nodes->words[w] = fix_endian32(nodes->words[w]);
+ }
+#endif
+}
+
+void ethash_mkcache(
+ ethash_cache *cache,
+ ethash_params const *params,
+ const uint8_t seed[32]) {
+ node *nodes = (node *) cache->mem;
+ ethash_compute_cache_nodes(nodes, params, seed);
+}
+
+void ethash_calculate_dag_item(
+ node *const ret,
+ const unsigned node_index,
+ const struct ethash_params *params,
+ const struct ethash_cache *cache) {
+
+ uint32_t num_parent_nodes = (uint32_t) (params->cache_size / sizeof(node));
+ node const *cache_nodes = (node const *) cache->mem;
+ node const *init = &cache_nodes[node_index % num_parent_nodes];
+
+ memcpy(ret, init, sizeof(node));
+ ret->words[0] ^= node_index;
+ SHA3_512(ret->bytes, ret->bytes, sizeof(node));
+
+#if defined(_M_X64) && ENABLE_SSE
+ __m128i const fnv_prime = _mm_set1_epi32(FNV_PRIME);
+ __m128i xmm0 = ret->xmm[0];
+ __m128i xmm1 = ret->xmm[1];
+ __m128i xmm2 = ret->xmm[2];
+ __m128i xmm3 = ret->xmm[3];
+#endif
+
+ for (unsigned i = 0; i != DATASET_PARENTS; ++i) {
+ uint32_t parent_index = ((node_index ^ i) * FNV_PRIME ^ ret->words[i % NODE_WORDS]) % num_parent_nodes;
+ node const *parent = &cache_nodes[parent_index];
+
+#if defined(_M_X64) && ENABLE_SSE
+ {
+ xmm0 = _mm_mullo_epi32(xmm0, fnv_prime);
+ xmm1 = _mm_mullo_epi32(xmm1, fnv_prime);
+ xmm2 = _mm_mullo_epi32(xmm2, fnv_prime);
+ xmm3 = _mm_mullo_epi32(xmm3, fnv_prime);
+ xmm0 = _mm_xor_si128(xmm0, parent->xmm[0]);
+ xmm1 = _mm_xor_si128(xmm1, parent->xmm[1]);
+ xmm2 = _mm_xor_si128(xmm2, parent->xmm[2]);
+ xmm3 = _mm_xor_si128(xmm3, parent->xmm[3]);
+
+ // have to write to ret as values are used to compute index
+ ret->xmm[0] = xmm0;
+ ret->xmm[1] = xmm1;
+ ret->xmm[2] = xmm2;
+ ret->xmm[3] = xmm3;
+ }
+ #else
+ {
+ for (unsigned w = 0; w != NODE_WORDS; ++w) {
+ ret->words[w] = fnv_hash(ret->words[w], parent->words[w]);
+ }
+ }
+#endif
+ }
+
+ SHA3_512(ret->bytes, ret->bytes, sizeof(node));
+}
+
+void ethash_compute_full_data(
+ void *mem,
+ ethash_params const *params,
+ ethash_cache const *cache) {
+ assert((params->full_size % (sizeof(uint32_t) * MIX_WORDS)) == 0);
+ assert((params->full_size % sizeof(node)) == 0);
+ node *full_nodes = mem;
+
+ // now compute full nodes
+ for (unsigned n = 0; n != (params->full_size / sizeof(node)); ++n) {
+ ethash_calculate_dag_item(&(full_nodes[n]), n, params, cache);
+ }
+}
+
+static void ethash_hash(
+ ethash_return_value *ret,
+ node const *full_nodes,
+ ethash_cache const *cache,
+ ethash_params const *params,
+ const uint8_t header_hash[32],
+ const uint64_t nonce) {
+
+ assert((params->full_size % MIX_WORDS) == 0);
+
+ // pack hash and nonce together into first 40 bytes of s_mix
+ assert(sizeof(node) * 8 == 512);
+ node s_mix[MIX_NODES + 1];
+ memcpy(s_mix[0].bytes, header_hash, 32);
+
+#if BYTE_ORDER != LITTLE_ENDIAN
+ s_mix[0].double_words[4] = fix_endian64(nonce);
+#else
+ s_mix[0].double_words[4] = nonce;
+#endif
+
+ // compute sha3-512 hash and replicate across mix
+ SHA3_512(s_mix->bytes, s_mix->bytes, 40);
+
+#if BYTE_ORDER != LITTLE_ENDIAN
+ for (unsigned w = 0; w != 16; ++w) {
+ s_mix[0].words[w] = fix_endian32(s_mix[0].words[w]);
+ }
+#endif
+
+ node *const mix = s_mix + 1;
+ for (unsigned w = 0; w != MIX_WORDS; ++w) {
+ mix->words[w] = s_mix[0].words[w % NODE_WORDS];
+ }
+
+ unsigned const
+ page_size = sizeof(uint32_t) * MIX_WORDS,
+ num_full_pages = (unsigned) (params->full_size / page_size);
+
+
+ for (unsigned i = 0; i != ACCESSES; ++i) {
+ uint32_t const index = ((s_mix->words[0] ^ i) * FNV_PRIME ^ mix->words[i % MIX_WORDS]) % num_full_pages;
+
+ for (unsigned n = 0; n != MIX_NODES; ++n) {
+ const node *dag_node = &full_nodes[MIX_NODES * index + n];
+
+ if (!full_nodes) {
+ node tmp_node;
+ ethash_calculate_dag_item(&tmp_node, index * MIX_NODES + n, params, cache);
+ dag_node = &tmp_node;
+ }
+
+#if defined(_M_X64) && ENABLE_SSE
+ {
+ __m128i fnv_prime = _mm_set1_epi32(FNV_PRIME);
+ __m128i xmm0 = _mm_mullo_epi32(fnv_prime, mix[n].xmm[0]);
+ __m128i xmm1 = _mm_mullo_epi32(fnv_prime, mix[n].xmm[1]);
+ __m128i xmm2 = _mm_mullo_epi32(fnv_prime, mix[n].xmm[2]);
+ __m128i xmm3 = _mm_mullo_epi32(fnv_prime, mix[n].xmm[3]);
+ mix[n].xmm[0] = _mm_xor_si128(xmm0, dag_node->xmm[0]);
+ mix[n].xmm[1] = _mm_xor_si128(xmm1, dag_node->xmm[1]);
+ mix[n].xmm[2] = _mm_xor_si128(xmm2, dag_node->xmm[2]);
+ mix[n].xmm[3] = _mm_xor_si128(xmm3, dag_node->xmm[3]);
+ }
+ #else
+ {
+ for (unsigned w = 0; w != NODE_WORDS; ++w) {
+ mix[n].words[w] = fnv_hash(mix[n].words[w], dag_node->words[w]);
+ }
+ }
+#endif
+ }
+
+ }
+
+ // compress mix
+ for (unsigned w = 0; w != MIX_WORDS; w += 4) {
+ uint32_t reduction = mix->words[w + 0];
+ reduction = reduction * FNV_PRIME ^ mix->words[w + 1];
+ reduction = reduction * FNV_PRIME ^ mix->words[w + 2];
+ reduction = reduction * FNV_PRIME ^ mix->words[w + 3];
+ mix->words[w / 4] = reduction;
+ }
+
+#if BYTE_ORDER != LITTLE_ENDIAN
+ for (unsigned w = 0; w != MIX_WORDS/4; ++w) {
+ mix->words[w] = fix_endian32(mix->words[w]);
+ }
+#endif
+
+ memcpy(ret->mix_hash, mix->bytes, 32);
+ // final Keccak hash
+ SHA3_256(ret->result, s_mix->bytes, 64 + 32); // Keccak-256(s + compressed_mix)
+}
+
+void ethash_quick_hash(
+ uint8_t return_hash[32],
+ const uint8_t header_hash[32],
+ const uint64_t nonce,
+ const uint8_t mix_hash[32]) {
+
+ uint8_t buf[64 + 32];
+ memcpy(buf, header_hash, 32);
+#if BYTE_ORDER != LITTLE_ENDIAN
+ nonce = fix_endian64(nonce);
+#endif
+ memcpy(&(buf[32]), &nonce, 8);
+ SHA3_512(buf, buf, 40);
+ memcpy(&(buf[64]), mix_hash, 32);
+ SHA3_256(return_hash, buf, 64 + 32);
+}
+
+void ethash_get_seedhash(uint8_t seedhash[32], const uint32_t block_number) {
+ memset(seedhash, 0, 32);
+ const uint32_t epochs = block_number / EPOCH_LENGTH;
+ for (uint32_t i = 0; i < epochs; ++i)
+ SHA3_256(seedhash, seedhash, 32);
+}
+
+int ethash_quick_check_difficulty(
+ const uint8_t header_hash[32],
+ const uint64_t nonce,
+ const uint8_t mix_hash[32],
+ const uint8_t difficulty[32]) {
+
+ uint8_t return_hash[32];
+ ethash_quick_hash(return_hash, header_hash, nonce, mix_hash);
+ return ethash_check_difficulty(return_hash, difficulty);
+}
+
+void ethash_full(ethash_return_value *ret, void const *full_mem, ethash_params const *params, const uint8_t previous_hash[32], const uint64_t nonce) {
+ ethash_hash(ret, (node const *) full_mem, NULL, params, previous_hash, nonce);
+}
+
+void ethash_light(ethash_return_value *ret, ethash_cache const *cache, ethash_params const *params, const uint8_t previous_hash[32], const uint64_t nonce) {
+ ethash_hash(ret, NULL, cache, params, previous_hash, nonce);
+} \ No newline at end of file
diff --git a/Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash/internal.h b/Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash/internal.h
new file mode 100644
index 000000000..ddd06e8f4
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash/internal.h
@@ -0,0 +1,48 @@
+#pragma once
+#include "compiler.h"
+#include "endian.h"
+#include "ethash.h"
+
+#define ENABLE_SSE 0
+
+#if defined(_M_X64) && ENABLE_SSE
+#include <smmintrin.h>
+#endif
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+// compile time settings
+#define NODE_WORDS (64/4)
+#define MIX_WORDS (MIX_BYTES/4)
+#define MIX_NODES (MIX_WORDS / NODE_WORDS)
+#include <stdint.h>
+
+typedef union node {
+ uint8_t bytes[NODE_WORDS * 4];
+ uint32_t words[NODE_WORDS];
+ uint64_t double_words[NODE_WORDS / 2];
+
+#if defined(_M_X64) && ENABLE_SSE
+ __m128i xmm[NODE_WORDS/4];
+#endif
+
+} node;
+
+void ethash_calculate_dag_item(
+ node *const ret,
+ const unsigned node_index,
+ ethash_params const *params,
+ ethash_cache const *cache
+);
+
+void ethash_quick_hash(
+ uint8_t return_hash[32],
+ const uint8_t header_hash[32],
+ const uint64_t nonce,
+ const uint8_t mix_hash[32]);
+
+#ifdef __cplusplus
+}
+#endif \ No newline at end of file
diff --git a/Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash/sha3.c b/Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash/sha3.c
new file mode 100644
index 000000000..0c28230b8
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash/sha3.c
@@ -0,0 +1,151 @@
+/** libkeccak-tiny
+*
+* A single-file implementation of SHA-3 and SHAKE.
+*
+* Implementor: David Leon Gil
+* License: CC0, attribution kindly requested. Blame taken too,
+* but not liability.
+*/
+#include "sha3.h"
+
+#include <stdint.h>
+#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+
+/******** The Keccak-f[1600] permutation ********/
+
+/*** Constants. ***/
+static const uint8_t rho[24] = \
+ { 1, 3, 6, 10, 15, 21,
+ 28, 36, 45, 55, 2, 14,
+ 27, 41, 56, 8, 25, 43,
+ 62, 18, 39, 61, 20, 44};
+static const uint8_t pi[24] = \
+ {10, 7, 11, 17, 18, 3,
+ 5, 16, 8, 21, 24, 4,
+ 15, 23, 19, 13, 12, 2,
+ 20, 14, 22, 9, 6, 1};
+static const uint64_t RC[24] = \
+ {1ULL, 0x8082ULL, 0x800000000000808aULL, 0x8000000080008000ULL,
+ 0x808bULL, 0x80000001ULL, 0x8000000080008081ULL, 0x8000000000008009ULL,
+ 0x8aULL, 0x88ULL, 0x80008009ULL, 0x8000000aULL,
+ 0x8000808bULL, 0x800000000000008bULL, 0x8000000000008089ULL, 0x8000000000008003ULL,
+ 0x8000000000008002ULL, 0x8000000000000080ULL, 0x800aULL, 0x800000008000000aULL,
+ 0x8000000080008081ULL, 0x8000000000008080ULL, 0x80000001ULL, 0x8000000080008008ULL};
+
+/*** Helper macros to unroll the permutation. ***/
+#define rol(x, s) (((x) << s) | ((x) >> (64 - s)))
+#define REPEAT6(e) e e e e e e
+#define REPEAT24(e) REPEAT6(e e e e)
+#define REPEAT5(e) e e e e e
+#define FOR5(v, s, e) \
+ v = 0; \
+ REPEAT5(e; v += s;)
+
+/*** Keccak-f[1600] ***/
+static inline void keccakf(void* state) {
+ uint64_t* a = (uint64_t*)state;
+ uint64_t b[5] = {0};
+ uint64_t t = 0;
+ uint8_t x, y;
+
+ for (int i = 0; i < 24; i++) {
+ // Theta
+ FOR5(x, 1,
+ b[x] = 0;
+ FOR5(y, 5,
+ b[x] ^= a[x + y]; ))
+ FOR5(x, 1,
+ FOR5(y, 5,
+ a[y + x] ^= b[(x + 4) % 5] ^ rol(b[(x + 1) % 5], 1); ))
+ // Rho and pi
+ t = a[1];
+ x = 0;
+ REPEAT24(b[0] = a[pi[x]];
+ a[pi[x]] = rol(t, rho[x]);
+ t = b[0];
+ x++; )
+ // Chi
+ FOR5(y,
+ 5,
+ FOR5(x, 1,
+ b[x] = a[y + x];)
+ FOR5(x, 1,
+ a[y + x] = b[x] ^ ((~b[(x + 1) % 5]) & b[(x + 2) % 5]); ))
+ // Iota
+ a[0] ^= RC[i];
+ }
+}
+
+/******** The FIPS202-defined functions. ********/
+
+/*** Some helper macros. ***/
+
+#define _(S) do { S } while (0)
+#define FOR(i, ST, L, S) \
+ _(for (size_t i = 0; i < L; i += ST) { S; })
+#define mkapply_ds(NAME, S) \
+ static inline void NAME(uint8_t* dst, \
+ const uint8_t* src, \
+ size_t len) { \
+ FOR(i, 1, len, S); \
+ }
+#define mkapply_sd(NAME, S) \
+ static inline void NAME(const uint8_t* src, \
+ uint8_t* dst, \
+ size_t len) { \
+ FOR(i, 1, len, S); \
+ }
+
+mkapply_ds(xorin, dst[i] ^= src[i]) // xorin
+mkapply_sd(setout, dst[i] = src[i]) // setout
+
+#define P keccakf
+#define Plen 200
+
+// Fold P*F over the full blocks of an input.
+#define foldP(I, L, F) \
+ while (L >= rate) { \
+ F(a, I, rate); \
+ P(a); \
+ I += rate; \
+ L -= rate; \
+ }
+
+/** The sponge-based hash construction. **/
+static inline int hash(uint8_t* out, size_t outlen,
+ const uint8_t* in, size_t inlen,
+ size_t rate, uint8_t delim) {
+ if ((out == NULL) || ((in == NULL) && inlen != 0) || (rate >= Plen)) {
+ return -1;
+ }
+ uint8_t a[Plen] = {0};
+ // Absorb input.
+ foldP(in, inlen, xorin);
+ // Xor in the DS and pad frame.
+ a[inlen] ^= delim;
+ a[rate - 1] ^= 0x80;
+ // Xor in the last block.
+ xorin(a, in, inlen);
+ // Apply P
+ P(a);
+ // Squeeze output.
+ foldP(out, outlen, setout);
+ setout(a, out, outlen);
+ memset(a, 0, 200);
+ return 0;
+}
+
+#define defsha3(bits) \
+ int sha3_##bits(uint8_t* out, size_t outlen, \
+ const uint8_t* in, size_t inlen) { \
+ if (outlen > (bits/8)) { \
+ return -1; \
+ } \
+ return hash(out, outlen, in, inlen, 200 - (bits / 4), 0x01); \
+ }
+
+/*** FIPS202 SHA3 FOFs ***/
+defsha3(256)
+defsha3(512) \ No newline at end of file
diff --git a/Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash/sha3.h b/Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash/sha3.h
new file mode 100644
index 000000000..36a0a5301
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash/sha3.h
@@ -0,0 +1,27 @@
+#pragma once
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+#include "compiler.h"
+#include <stdint.h>
+#include <stdlib.h>
+
+#define decsha3(bits) \
+ int sha3_##bits(uint8_t*, size_t, const uint8_t*, size_t);
+
+decsha3(256)
+decsha3(512)
+
+static inline void SHA3_256(uint8_t * const ret, uint8_t const *data, const size_t size) {
+ sha3_256(ret, 32, data, size);
+}
+
+static inline void SHA3_512(uint8_t * const ret, uint8_t const *data, const size_t size) {
+ sha3_512(ret, 64, data, size);
+}
+
+#ifdef __cplusplus
+}
+#endif \ No newline at end of file
diff --git a/Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash/sha3_cryptopp.cpp b/Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash/sha3_cryptopp.cpp
new file mode 100644
index 000000000..6cbbcad8f
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash/sha3_cryptopp.cpp
@@ -0,0 +1,34 @@
+/*
+ This file is part of ethash.
+
+ ethash is free software: you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation, either version 3 of the License, or
+ (at your option) any later version.
+
+ ethash is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with ethash. If not, see <http://www.gnu.org/licenses/>.
+*/
+
+/** @file sha3.cpp
+* @author Tim Hughes <tim@twistedfury.com>
+* @date 2015
+*/
+
+#include <stdint.h>
+#include <cryptopp/sha3.h>
+
+extern "C" {
+void SHA3_256(uint8_t *const ret, const uint8_t *data, size_t size) {
+ CryptoPP::SHA3_256().CalculateDigest(ret, data, size);
+}
+
+void SHA3_512(uint8_t *const ret, const uint8_t *data, size_t size) {
+ CryptoPP::SHA3_512().CalculateDigest(ret, data, size);
+}
+} \ No newline at end of file
diff --git a/Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash/sha3_cryptopp.h b/Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash/sha3_cryptopp.h
new file mode 100644
index 000000000..f910960e1
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash/sha3_cryptopp.h
@@ -0,0 +1,15 @@
+#pragma once
+
+#include "compiler.h"
+#include <stdint.h>
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+void SHA3_256(uint8_t *const ret, const uint8_t *data, size_t size);
+void SHA3_512(uint8_t *const ret, const uint8_t *data, size_t size);
+
+#ifdef __cplusplus
+}
+#endif \ No newline at end of file
diff --git a/Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash/util.c b/Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash/util.c
new file mode 100644
index 000000000..fbf268b7d
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash/util.c
@@ -0,0 +1,41 @@
+/*
+ This file is part of cpp-ethereum.
+
+ cpp-ethereum is free software: you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation, either version 3 of the License, or
+ (at your option) any later version.
+
+ cpp-ethereum is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with cpp-ethereum. If not, see <http://www.gnu.org/licenses/>.
+*/
+/** @file util.c
+ * @author Tim Hughes <tim@twistedfury.com>
+ * @date 2015
+ */
+#include <stdarg.h>
+#include <stdio.h>
+#include "util.h"
+
+#ifdef _MSC_VER
+
+// foward declare without all of Windows.h
+__declspec(dllimport) void __stdcall OutputDebugStringA(const char* lpOutputString);
+
+void debugf(const char *str, ...)
+{
+ va_list args;
+ va_start(args, str);
+
+ char buf[1<<16];
+ _vsnprintf_s(buf, sizeof(buf), sizeof(buf), str, args);
+ buf[sizeof(buf)-1] = '\0';
+ OutputDebugStringA(buf);
+}
+
+#endif
diff --git a/Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash/util.h b/Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash/util.h
new file mode 100644
index 000000000..ba8957815
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/ethash/src/libethash/util.h
@@ -0,0 +1,47 @@
+/*
+ This file is part of ethash.
+
+ ethash is free software: you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation, either version 3 of the License, or
+ (at your option) any later version.
+
+ ethash is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with ethash. If not, see <http://www.gnu.org/licenses/>.
+*/
+/** @file util.h
+ * @author Tim Hughes <tim@twistedfury.com>
+ * @date 2015
+ */
+#pragma once
+#include <stdint.h>
+#include "compiler.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+#ifdef _MSC_VER
+void debugf(const char *str, ...);
+#else
+#define debugf printf
+#endif
+
+static inline uint32_t min_u32(uint32_t a, uint32_t b)
+{
+ return a < b ? a : b;
+}
+
+static inline uint32_t clamp_u32(uint32_t x, uint32_t min_, uint32_t max_)
+{
+ return x < min_ ? min_ : (x > max_ ? max_ : x);
+}
+
+#ifdef __cplusplus
+}
+#endif
diff --git a/Godeps/_workspace/src/github.com/ethereum/ethash/src/python/core.c b/Godeps/_workspace/src/github.com/ethereum/ethash/src/python/core.c
new file mode 100644
index 000000000..359735998
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/ethash/src/python/core.c
@@ -0,0 +1,305 @@
+#include <Python.h>
+#include <alloca.h>
+#include <stdint.h>
+#include <stdlib.h>
+#include <time.h>
+#include "../libethash/ethash.h"
+
+#define MIX_WORDS (MIX_BYTES/4)
+
+static PyObject *
+get_cache_size(PyObject *self, PyObject *args) {
+ unsigned long block_number;
+ if (!PyArg_ParseTuple(args, "k", &block_number))
+ return 0;
+ if (block_number >= EPOCH_LENGTH * 2048) {
+ char error_message[1024];
+ sprintf(error_message, "Block number must be less than %i (was %lu)", EPOCH_LENGTH * 2048, block_number);
+
+ PyErr_SetString(PyExc_ValueError, error_message);
+ return 0;
+ }
+
+ return Py_BuildValue("i", ethash_get_cachesize(block_number));
+}
+
+static PyObject *
+get_full_size(PyObject *self, PyObject *args) {
+ unsigned long block_number;
+ if (!PyArg_ParseTuple(args, "k", &block_number))
+ return 0;
+ if (block_number >= EPOCH_LENGTH * 2048) {
+ char error_message[1024];
+ sprintf(error_message, "Block number must be less than %i (was %lu)", EPOCH_LENGTH * 2048, block_number);
+
+ PyErr_SetString(PyExc_ValueError, error_message);
+ return 0;
+ }
+
+ return Py_BuildValue("i", ethash_get_datasize(block_number));
+}
+
+
+static PyObject *
+mkcache_bytes(PyObject *self, PyObject *args) {
+ char *seed;
+ unsigned long cache_size;
+ int seed_len;
+
+ if (!PyArg_ParseTuple(args, "ks#", &cache_size, &seed, &seed_len))
+ return 0;
+
+ if (seed_len != 32) {
+ char error_message[1024];
+ sprintf(error_message, "Seed must be 32 bytes long (was %i)", seed_len);
+
+ PyErr_SetString(PyExc_ValueError, error_message);
+ return 0;
+ }
+
+ ethash_params params;
+ params.cache_size = (size_t) cache_size;
+ ethash_cache cache;
+ cache.mem = malloc(cache_size);
+ ethash_mkcache(&cache, &params, (uint8_t *) seed);
+ PyObject * val = Py_BuildValue("s#", cache.mem, cache_size);
+ free(cache.mem);
+ return val;
+}
+
+
+static PyObject *
+calc_dataset_bytes(PyObject *self, PyObject *args) {
+ char *cache_bytes;
+ unsigned long full_size;
+ int cache_size;
+
+ if (!PyArg_ParseTuple(args, "ks#", &full_size, &cache_bytes, &cache_size))
+ return 0;
+
+ if (full_size % MIX_WORDS != 0) {
+ char error_message[1024];
+ sprintf(error_message, "The size of data set must be a multiple of %i bytes (was %lu)", MIX_WORDS, full_size);
+ PyErr_SetString(PyExc_ValueError, error_message);
+ return 0;
+ }
+
+ if (cache_size % HASH_BYTES != 0) {
+ char error_message[1024];
+ sprintf(error_message, "The size of the cache must be a multiple of %i bytes (was %i)", HASH_BYTES, cache_size);
+ PyErr_SetString(PyExc_ValueError, error_message);
+ return 0;
+ }
+
+ ethash_params params;
+ params.cache_size = (size_t) cache_size;
+ params.full_size = (size_t) full_size;
+ ethash_cache cache;
+ cache.mem = (void *) cache_bytes;
+ void *mem = malloc(params.full_size);
+ ethash_compute_full_data(mem, &params, &cache);
+ PyObject * val = Py_BuildValue("s#", (char *) mem, full_size);
+ free(mem);
+ return val;
+}
+
+// hashimoto_light(full_size, cache, header, nonce)
+static PyObject *
+hashimoto_light(PyObject *self, PyObject *args) {
+ char *cache_bytes, *header;
+ unsigned long full_size;
+ unsigned long long nonce;
+ int cache_size, header_size;
+
+ if (!PyArg_ParseTuple(args, "ks#s#K", &full_size, &cache_bytes, &cache_size, &header, &header_size, &nonce))
+ return 0;
+
+ if (full_size % MIX_WORDS != 0) {
+ char error_message[1024];
+ sprintf(error_message, "The size of data set must be a multiple of %i bytes (was %lu)", MIX_WORDS, full_size);
+ PyErr_SetString(PyExc_ValueError, error_message);
+ return 0;
+ }
+
+ if (cache_size % HASH_BYTES != 0) {
+ char error_message[1024];
+ sprintf(error_message, "The size of the cache must be a multiple of %i bytes (was %i)", HASH_BYTES, cache_size);
+ PyErr_SetString(PyExc_ValueError, error_message);
+ return 0;
+ }
+
+ if (header_size != 32) {
+ char error_message[1024];
+ sprintf(error_message, "Seed must be 32 bytes long (was %i)", header_size);
+ PyErr_SetString(PyExc_ValueError, error_message);
+ return 0;
+ }
+
+
+ ethash_return_value out;
+ ethash_params params;
+ params.cache_size = (size_t) cache_size;
+ params.full_size = (size_t) full_size;
+ ethash_cache cache;
+ cache.mem = (void *) cache_bytes;
+ ethash_light(&out, &cache, &params, (uint8_t *) header, nonce);
+ return Py_BuildValue("{s:s#,s:s#}",
+ "mix digest", out.mix_hash, 32,
+ "result", out.result, 32);
+}
+
+// hashimoto_full(dataset, header, nonce)
+static PyObject *
+hashimoto_full(PyObject *self, PyObject *args) {
+ char *full_bytes, *header;
+ unsigned long long nonce;
+ int full_size, header_size;
+
+ if (!PyArg_ParseTuple(args, "s#s#K", &full_bytes, &full_size, &header, &header_size, &nonce))
+ return 0;
+
+ if (full_size % MIX_WORDS != 0) {
+ char error_message[1024];
+ sprintf(error_message, "The size of data set must be a multiple of %i bytes (was %i)", MIX_WORDS, full_size);
+ PyErr_SetString(PyExc_ValueError, error_message);
+ return 0;
+ }
+
+ if (header_size != 32) {
+ char error_message[1024];
+ sprintf(error_message, "Header must be 32 bytes long (was %i)", header_size);
+ PyErr_SetString(PyExc_ValueError, error_message);
+ return 0;
+ }
+
+
+ ethash_return_value out;
+ ethash_params params;
+ params.full_size = (size_t) full_size;
+ ethash_full(&out, (void *) full_bytes, &params, (uint8_t *) header, nonce);
+ return Py_BuildValue("{s:s#, s:s#}",
+ "mix digest", out.mix_hash, 32,
+ "result", out.result, 32);
+}
+
+// mine(dataset_bytes, header, difficulty_bytes)
+static PyObject *
+mine(PyObject *self, PyObject *args) {
+ char *full_bytes, *header, *difficulty;
+ srand(time(0));
+ uint64_t nonce = ((uint64_t) rand()) << 32 | rand();
+ int full_size, header_size, difficulty_size;
+
+ if (!PyArg_ParseTuple(args, "s#s#s#", &full_bytes, &full_size, &header, &header_size, &difficulty, &difficulty_size))
+ return 0;
+
+ if (full_size % MIX_WORDS != 0) {
+ char error_message[1024];
+ sprintf(error_message, "The size of data set must be a multiple of %i bytes (was %i)", MIX_WORDS, full_size);
+ PyErr_SetString(PyExc_ValueError, error_message);
+ return 0;
+ }
+
+ if (header_size != 32) {
+ char error_message[1024];
+ sprintf(error_message, "Header must be 32 bytes long (was %i)", header_size);
+ PyErr_SetString(PyExc_ValueError, error_message);
+ return 0;
+ }
+
+ if (difficulty_size != 32) {
+ char error_message[1024];
+ sprintf(error_message, "Difficulty must be an array of 32 bytes (only had %i)", difficulty_size);
+ PyErr_SetString(PyExc_ValueError, error_message);
+ return 0;
+ }
+
+ ethash_return_value out;
+ ethash_params params;
+ params.full_size = (size_t) full_size;
+
+ // TODO: Multi threading?
+ do {
+ ethash_full(&out, (void *) full_bytes, &params, (const uint8_t *) header, nonce++);
+ // TODO: disagrees with the spec https://github.com/ethereum/wiki/wiki/Ethash#mining
+ } while (!ethash_check_difficulty(out.result, (const uint8_t *) difficulty));
+
+ return Py_BuildValue("{s:s#, s:s#, s:K}",
+ "mix digest", out.mix_hash, 32,
+ "result", out.result, 32,
+ "nonce", nonce);
+}
+
+//get_seedhash(block_number)
+static PyObject *
+get_seedhash(PyObject *self, PyObject *args) {
+ unsigned long block_number;
+ if (!PyArg_ParseTuple(args, "k", &block_number))
+ return 0;
+ if (block_number >= EPOCH_LENGTH * 2048) {
+ char error_message[1024];
+ sprintf(error_message, "Block number must be less than %i (was %lu)", EPOCH_LENGTH * 2048, block_number);
+
+ PyErr_SetString(PyExc_ValueError, error_message);
+ return 0;
+ }
+ uint8_t seedhash[32];
+ ethash_get_seedhash(seedhash, block_number);
+ return Py_BuildValue("s#", (char *) seedhash, 32);
+}
+
+static PyMethodDef PyethashMethods[] =
+ {
+ {"get_cache_size", get_cache_size, METH_VARARGS,
+ "get_cache_size(block_number)\n\n"
+ "Get the cache size for a given block number\n"
+ "\nExample:\n"
+ ">>> get_cache_size(0)\n"
+ "1048384"},
+ {"get_full_size", get_full_size, METH_VARARGS,
+ "get_full_size(block_number)\n\n"
+ "Get the full size for a given block number\n"
+ "\nExample:\n"
+ ">>> get_full_size(0)\n"
+ "1073739904"
+ },
+ {"get_seedhash", get_seedhash, METH_VARARGS,
+ "get_seedhash(block_number)\n\n"
+ "Gets the seedhash for a block."},
+ {"mkcache_bytes", mkcache_bytes, METH_VARARGS,
+ "mkcache_bytes(size, header)\n\n"
+ "Makes a byte array for the cache for given cache size and seed hash\n"
+ "\nExample:\n"
+ ">>> pyethash.mkcache_bytes( 1024, \"~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\").encode('hex')"
+ "\"2da2b506f21070e1143d908e867962486d6b0a02e31d468fd5e3a7143aafa76a14201f63374314e2a6aaf84ad2eb57105dea3378378965a1b3873453bb2b78f9a8620b2ebeca41fbc773bb837b5e724d6eb2de570d99858df0d7d97067fb8103b21757873b735097b35d3bea8fd1c359a9e8a63c1540c76c9784cf8d975e995ca8620b2ebeca41fbc773bb837b5e724d6eb2de570d99858df0d7d97067fb8103b21757873b735097b35d3bea8fd1c359a9e8a63c1540c76c9784cf8d975e995ca8620b2ebeca41fbc773bb837b5e724d6eb2de570d99858df0d7d97067fb8103b21757873b735097b35d3bea8fd1c359a9e8a63c1540c76c9784cf8d975e995c259440b89fa3481c2c33171477c305c8e1e421f8d8f6d59585449d0034f3e421808d8da6bbd0b6378f567647cc6c4ba6c434592b198ad444e7284905b7c6adaf70bf43ec2daa7bd5e8951aa609ab472c124cf9eba3d38cff5091dc3f58409edcc386c743c3bd66f92408796ee1e82dd149eaefbf52b00ce33014a6eb3e50625413b072a58bc01da28262f42cbe4f87d4abc2bf287d15618405a1fe4e386fcdafbb171064bd99901d8f81dd6789396ce5e364ac944bbbd75a7827291c70b42d26385910cd53ca535ab29433dd5c5714d26e0dce95514c5ef866329c12e958097e84462197c2b32087849dab33e88b11da61d52f9dbc0b92cc61f742c07dbbf751c49d7678624ee60dfbe62e5e8c47a03d8247643f3d16ad8c8e663953bcda1f59d7e2d4a9bf0768e789432212621967a8f41121ad1df6ae1fa78782530695414c6213942865b2730375019105cae91a4c17a558d4b63059661d9f108362143107babe0b848de412e4da59168cce82bfbff3c99e022dd6ac1e559db991f2e3f7bb910cefd173e65ed00a8d5d416534e2c8416ff23977dbf3eb7180b75c71580d08ce95efeb9b0afe904ea12285a392aff0c8561ff79fca67f694a62b9e52377485c57cc3598d84cac0a9d27960de0cc31ff9bbfe455acaa62c8aa5d2cce96f345da9afe843d258a99c4eaf3650fc62efd81c7b81cd0d534d2d71eeda7a6e315d540b4473c80f8730037dc2ae3e47b986240cfc65ccc565f0d8cde0bc68a57e39a271dda57440b3598bee19f799611d25731a96b5dbbbefdff6f4f656161462633030d62560ea4e9c161cf78fc96a2ca5aaa32453a6c5dea206f766244e8c9d9a8dc61185ce37f1fc804459c5f07434f8ecb34141b8dcae7eae704c950b55556c5f40140c3714b45eddb02637513268778cbf937a33e4e33183685f9deb31ef54e90161e76d969587dd782eaa94e289420e7c2ee908517f5893a26fdb5873d68f92d118d4bcf98d7a4916794d6ab290045e30f9ea00ca547c584b8482b0331ba1539a0f2714fddc3a0b06b0cfbb6a607b8339c39bcfd6640b1f653e9d70ef6c985b\""},
+ {"calc_dataset_bytes", calc_dataset_bytes, METH_VARARGS,
+ "calc_dataset_bytes(full_size, cache_bytes)\n\n"
+ "Makes a byte array for the dataset for a given size given cache bytes"},
+ {"hashimoto_light", hashimoto_light, METH_VARARGS,
+ "hashimoto_light(full_size, cache_bytes, header, nonce)\n\n"
+ "Runs the hashimoto hashing function just using cache bytes. Takes an int (full_size), byte array (cache_bytes), another byte array (header), and an int (nonce). Returns an object containing the mix digest, and hash result."},
+ {"hashimoto_full", hashimoto_full, METH_VARARGS,
+ "hashimoto_full(dataset_bytes, header, nonce)\n\n"
+ "Runs the hashimoto hashing function using the dataset bytes. Useful for testing. Returns an object containing the mix digest (byte array), and hash result (another byte array)."},
+ {"mine", mine, METH_VARARGS,
+ "mine(dataset_bytes, header, difficulty_bytes)\n\n"
+ "Mine for an adequate header. Returns an object containing the mix digest (byte array), hash result (another byte array) and nonce (an int)."},
+ {NULL, NULL, 0, NULL}
+ };
+
+PyMODINIT_FUNC
+initpyethash(void) {
+ PyObject *module = Py_InitModule("pyethash", PyethashMethods);
+ // Following Spec: https://github.com/ethereum/wiki/wiki/Ethash#definitions
+ PyModule_AddIntConstant(module, "REVISION", (long) REVISION);
+ PyModule_AddIntConstant(module, "DATASET_BYTES_INIT", (long) DATASET_BYTES_INIT);
+ PyModule_AddIntConstant(module, "DATASET_BYTES_GROWTH", (long) DATASET_BYTES_GROWTH);
+ PyModule_AddIntConstant(module, "CACHE_BYTES_INIT", (long) CACHE_BYTES_INIT);
+ PyModule_AddIntConstant(module, "CACHE_BYTES_GROWTH", (long) CACHE_BYTES_GROWTH);
+ PyModule_AddIntConstant(module, "EPOCH_LENGTH", (long) EPOCH_LENGTH);
+ PyModule_AddIntConstant(module, "MIX_BYTES", (long) MIX_BYTES);
+ PyModule_AddIntConstant(module, "HASH_BYTES", (long) HASH_BYTES);
+ PyModule_AddIntConstant(module, "DATASET_PARENTS", (long) DATASET_PARENTS);
+ PyModule_AddIntConstant(module, "CACHE_ROUNDS", (long) CACHE_ROUNDS);
+ PyModule_AddIntConstant(module, "ACCESSES", (long) ACCESSES);
+}
diff --git a/Godeps/_workspace/src/github.com/ethereum/ethash/test/c/CMakeLists.txt b/Godeps/_workspace/src/github.com/ethereum/ethash/test/c/CMakeLists.txt
new file mode 100644
index 000000000..02e2aab91
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/ethash/test/c/CMakeLists.txt
@@ -0,0 +1,30 @@
+IF( NOT Boost_FOUND )
+ find_package(Boost COMPONENTS unit_test_framework)
+ENDIF()
+
+IF( Boost_FOUND )
+ include_directories( ${Boost_INCLUDE_DIR} )
+ include_directories(../../src)
+
+ link_directories ( ${Boost_LIBRARY_DIRS} )
+ file(GLOB HEADERS "*.h")
+ ADD_DEFINITIONS(-DBOOST_TEST_DYN_LINK)
+
+ if (NOT CRYPTOPP_FOUND)
+ find_package (CryptoPP)
+ endif()
+
+ if (CRYPTOPP_FOUND)
+ add_definitions(-DWITH_CRYPTOPP)
+ endif()
+
+ add_executable (Test test.cpp ${HEADERS})
+ target_link_libraries (Test ${Boost_UNIT_TEST_FRAMEWORK_LIBRARY} ${ETHHASH_LIBS})
+
+ if (CRYPTOPP_FOUND)
+ TARGET_LINK_LIBRARIES(Test ${CRYPTOPP_LIBRARIES})
+ endif()
+
+ enable_testing ()
+ add_test(NAME ethash COMMAND Test)
+ENDIF()
diff --git a/Godeps/_workspace/src/github.com/ethereum/ethash/test/c/test.cpp b/Godeps/_workspace/src/github.com/ethereum/ethash/test/c/test.cpp
new file mode 100644
index 000000000..21cb251fc
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/ethash/test/c/test.cpp
@@ -0,0 +1,228 @@
+#include <iomanip>
+#include <libethash/fnv.h>
+#include <libethash/ethash.h>
+#include <libethash/internal.h>
+
+#ifdef WITH_CRYPTOPP
+
+#include <libethash/sha3_cryptopp.h>
+
+#else
+#include <libethash/sha3.h>
+#endif // WITH_CRYPTOPP
+
+#define BOOST_TEST_MODULE Daggerhashimoto
+#define BOOST_TEST_MAIN
+
+#include <boost/test/unit_test.hpp>
+#include <iostream>
+
+std::string bytesToHexString(const uint8_t *str, const size_t s) {
+ std::ostringstream ret;
+
+ for (int i = 0; i < s; ++i)
+ ret << std::hex << std::setfill('0') << std::setw(2) << std::nouppercase << (int) str[i];
+
+ return ret.str();
+}
+
+BOOST_AUTO_TEST_CASE(fnv_hash_check) {
+ uint32_t x = 1235U;
+ const uint32_t
+ y = 9999999U,
+ expected = (FNV_PRIME * x) ^y;
+
+ x = fnv_hash(x, y);
+
+ BOOST_REQUIRE_MESSAGE(x == expected,
+ "\nexpected: " << expected << "\n"
+ << "actual: " << x << "\n");
+
+}
+
+BOOST_AUTO_TEST_CASE(SHA256_check) {
+ uint8_t input[32], out[32];
+ memcpy(input, "~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~", 32);
+ SHA3_256(out, input, 32);
+ const std::string
+ expected = "2b5ddf6f4d21c23de216f44d5e4bdc68e044b71897837ea74c83908be7037cd7",
+ actual = bytesToHexString(out, 32);
+ BOOST_REQUIRE_MESSAGE(expected == actual,
+ "\nexpected: " << expected.c_str() << "\n"
+ << "actual: " << actual.c_str() << "\n");
+}
+
+BOOST_AUTO_TEST_CASE(SHA512_check) {
+ uint8_t input[64], out[64];
+ memcpy(input, "~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~", 64);
+ SHA3_512(out, input, 64);
+ const std::string
+ expected = "0be8a1d334b4655fe58c6b38789f984bb13225684e86b20517a55ab2386c7b61c306f25e0627c60064cecd6d80cd67a82b3890bd1289b7ceb473aad56a359405",
+ actual = bytesToHexString(out, 64);
+ BOOST_REQUIRE_MESSAGE(expected == actual,
+ "\nexpected: " << expected.c_str() << "\n"
+ << "actual: " << actual.c_str() << "\n");
+}
+
+BOOST_AUTO_TEST_CASE(ethash_params_init_genesis_check) {
+ ethash_params params;
+ ethash_params_init(&params, 0);
+ BOOST_REQUIRE_MESSAGE(params.full_size < DATASET_BYTES_INIT,
+ "\nfull size: " << params.full_size << "\n"
+ << "should be less than or equal to: " << DATASET_BYTES_INIT << "\n");
+ BOOST_REQUIRE_MESSAGE(params.full_size + 20 * MIX_BYTES >= DATASET_BYTES_INIT,
+ "\nfull size + 20*MIX_BYTES: " << params.full_size + 20 * MIX_BYTES << "\n"
+ << "should be greater than or equal to: " << DATASET_BYTES_INIT << "\n");
+ BOOST_REQUIRE_MESSAGE(params.cache_size < DATASET_BYTES_INIT / 32,
+ "\ncache size: " << params.cache_size << "\n"
+ << "should be less than or equal to: " << DATASET_BYTES_INIT / 32 << "\n");
+}
+
+BOOST_AUTO_TEST_CASE(ethash_params_init_genesis_calcifide_check) {
+ ethash_params params;
+ ethash_params_init(&params, 0);
+ const uint32_t expected_full_size = 1073739904;
+ const uint32_t expected_cache_size = 16776896;
+ BOOST_REQUIRE_MESSAGE(params.full_size == expected_full_size,
+ "\nexpected: " << expected_cache_size << "\n"
+ << "actual: " << params.full_size << "\n");
+ BOOST_REQUIRE_MESSAGE(params.cache_size == expected_cache_size,
+ "\nexpected: " << expected_cache_size << "\n"
+ << "actual: " << params.cache_size << "\n");
+}
+
+BOOST_AUTO_TEST_CASE(light_and_full_client_checks) {
+ ethash_params params;
+ uint8_t seed[32], hash[32], difficulty[32];
+ ethash_return_value light_out, full_out;
+ memcpy(seed, "~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~", 32);
+ memcpy(hash, "~~~X~~~~~~~~~~~~~~~~~~~~~~~~~~~~", 32);
+
+ // Set the difficulty
+ difficulty[0] = 197;
+ difficulty[1] = 90;
+ for (int i = 2; i < 32; i++)
+ difficulty[i] = (uint8_t) 255;
+
+ ethash_params_init(&params, 0);
+ params.cache_size = 1024;
+ params.full_size = 1024 * 32;
+ ethash_cache cache;
+ cache.mem = alloca(params.cache_size);
+ ethash_mkcache(&cache, &params, seed);
+ node *full_mem = (node *) alloca(params.full_size);
+ ethash_compute_full_data(full_mem, &params, &cache);
+
+ {
+ const std::string
+ expected = "2da2b506f21070e1143d908e867962486d6b0a02e31d468fd5e3a7143aafa76a14201f63374314e2a6aaf84ad2eb57105dea3378378965a1b3873453bb2b78f9a8620b2ebeca41fbc773bb837b5e724d6eb2de570d99858df0d7d97067fb8103b21757873b735097b35d3bea8fd1c359a9e8a63c1540c76c9784cf8d975e995ca8620b2ebeca41fbc773bb837b5e724d6eb2de570d99858df0d7d97067fb8103b21757873b735097b35d3bea8fd1c359a9e8a63c1540c76c9784cf8d975e995ca8620b2ebeca41fbc773bb837b5e724d6eb2de570d99858df0d7d97067fb8103b21757873b735097b35d3bea8fd1c359a9e8a63c1540c76c9784cf8d975e995c259440b89fa3481c2c33171477c305c8e1e421f8d8f6d59585449d0034f3e421808d8da6bbd0b6378f567647cc6c4ba6c434592b198ad444e7284905b7c6adaf70bf43ec2daa7bd5e8951aa609ab472c124cf9eba3d38cff5091dc3f58409edcc386c743c3bd66f92408796ee1e82dd149eaefbf52b00ce33014a6eb3e50625413b072a58bc01da28262f42cbe4f87d4abc2bf287d15618405a1fe4e386fcdafbb171064bd99901d8f81dd6789396ce5e364ac944bbbd75a7827291c70b42d26385910cd53ca535ab29433dd5c5714d26e0dce95514c5ef866329c12e958097e84462197c2b32087849dab33e88b11da61d52f9dbc0b92cc61f742c07dbbf751c49d7678624ee60dfbe62e5e8c47a03d8247643f3d16ad8c8e663953bcda1f59d7e2d4a9bf0768e789432212621967a8f41121ad1df6ae1fa78782530695414c6213942865b2730375019105cae91a4c17a558d4b63059661d9f108362143107babe0b848de412e4da59168cce82bfbff3c99e022dd6ac1e559db991f2e3f7bb910cefd173e65ed00a8d5d416534e2c8416ff23977dbf3eb7180b75c71580d08ce95efeb9b0afe904ea12285a392aff0c8561ff79fca67f694a62b9e52377485c57cc3598d84cac0a9d27960de0cc31ff9bbfe455acaa62c8aa5d2cce96f345da9afe843d258a99c4eaf3650fc62efd81c7b81cd0d534d2d71eeda7a6e315d540b4473c80f8730037dc2ae3e47b986240cfc65ccc565f0d8cde0bc68a57e39a271dda57440b3598bee19f799611d25731a96b5dbbbefdff6f4f656161462633030d62560ea4e9c161cf78fc96a2ca5aaa32453a6c5dea206f766244e8c9d9a8dc61185ce37f1fc804459c5f07434f8ecb34141b8dcae7eae704c950b55556c5f40140c3714b45eddb02637513268778cbf937a33e4e33183685f9deb31ef54e90161e76d969587dd782eaa94e289420e7c2ee908517f5893a26fdb5873d68f92d118d4bcf98d7a4916794d6ab290045e30f9ea00ca547c584b8482b0331ba1539a0f2714fddc3a0b06b0cfbb6a607b8339c39bcfd6640b1f653e9d70ef6c985b",
+ actual = bytesToHexString((uint8_t const *) cache.mem, params.cache_size);
+
+ BOOST_REQUIRE_MESSAGE(expected == actual,
+ "\nexpected: " << expected.c_str() << "\n"
+ << "actual: " << actual.c_str() << "\n");
+ }
+
+
+ {
+ node node;
+ ethash_calculate_dag_item(&node, 0, &params, &cache);
+ const std::string
+ actual = bytesToHexString((uint8_t const *) &node, sizeof(node)),
+ expected = "b1698f829f90b35455804e5185d78f549fcb1bdce2bee006d4d7e68eb154b596be1427769eb1c3c3e93180c760af75f81d1023da6a0ffbe321c153a7c0103597";
+ BOOST_REQUIRE_MESSAGE(actual == expected,
+ "\n" << "expected: " << expected.c_str() << "\n"
+ << "actual: " << actual.c_str() << "\n");
+ }
+
+ {
+ for (int i = 0; i < params.full_size / sizeof(node); ++i) {
+ for (uint32_t j = 0; j < 32; ++j) {
+ node expected_node;
+ ethash_calculate_dag_item(&expected_node, j, &params, &cache);
+ const std::string
+ actual = bytesToHexString((uint8_t const *) &(full_mem[j]), sizeof(node)),
+ expected = bytesToHexString((uint8_t const *) &expected_node, sizeof(node));
+ BOOST_REQUIRE_MESSAGE(actual == expected,
+ "\ni: " << j << "\n"
+ << "expected: " << expected.c_str() << "\n"
+ << "actual: " << actual.c_str() << "\n");
+ }
+ }
+ }
+
+ {
+ uint64_t nonce = 0x7c7c597c;
+ ethash_full(&full_out, full_mem, &params, hash, nonce);
+ ethash_light(&light_out, &cache, &params, hash, nonce);
+ const std::string
+ light_result_string = bytesToHexString(light_out.result, 32),
+ full_result_string = bytesToHexString(full_out.result, 32);
+ BOOST_REQUIRE_MESSAGE(light_result_string == full_result_string,
+ "\nlight result: " << light_result_string.c_str() << "\n"
+ << "full result: " << full_result_string.c_str() << "\n");
+ const std::string
+ light_mix_hash_string = bytesToHexString(light_out.mix_hash, 32),
+ full_mix_hash_string = bytesToHexString(full_out.mix_hash, 32);
+ BOOST_REQUIRE_MESSAGE(full_mix_hash_string == light_mix_hash_string,
+ "\nlight mix hash: " << light_mix_hash_string.c_str() << "\n"
+ << "full mix hash: " << full_mix_hash_string.c_str() << "\n");
+ uint8_t check_hash[32];
+ ethash_quick_hash(check_hash, hash, nonce, full_out.mix_hash);
+ const std::string check_hash_string = bytesToHexString(check_hash, 32);
+ BOOST_REQUIRE_MESSAGE(check_hash_string == full_result_string,
+ "\ncheck hash string: " << check_hash_string.c_str() << "\n"
+ << "full result: " << full_result_string.c_str() << "\n");
+ }
+ {
+ ethash_full(&full_out, full_mem, &params, hash, 5);
+ std::string
+ light_result_string = bytesToHexString(light_out.result, 32),
+ full_result_string = bytesToHexString(full_out.result, 32);
+
+ BOOST_REQUIRE_MESSAGE(light_result_string != full_result_string,
+ "\nlight result and full result should differ: " << light_result_string.c_str() << "\n");
+
+ ethash_light(&light_out, &cache, &params, hash, 5);
+ light_result_string = bytesToHexString(light_out.result, 32);
+ BOOST_REQUIRE_MESSAGE(light_result_string == full_result_string,
+ "\nlight result and full result should be the same\n"
+ << "light result: " << light_result_string.c_str() << "\n"
+ << "full result: " << full_result_string.c_str() << "\n");
+ std::string
+ light_mix_hash_string = bytesToHexString(light_out.mix_hash, 32),
+ full_mix_hash_string = bytesToHexString(full_out.mix_hash, 32);
+ BOOST_REQUIRE_MESSAGE(full_mix_hash_string == light_mix_hash_string,
+ "\nlight mix hash: " << light_mix_hash_string.c_str() << "\n"
+ << "full mix hash: " << full_mix_hash_string.c_str() << "\n");
+ BOOST_REQUIRE_MESSAGE(ethash_check_difficulty(full_out.result, difficulty),
+ "ethash_check_difficulty failed"
+ );
+ BOOST_REQUIRE_MESSAGE(ethash_quick_check_difficulty(hash, 5U, full_out.mix_hash, difficulty),
+ "ethash_quick_check_difficulty failed"
+ );
+ }
+}
+
+BOOST_AUTO_TEST_CASE(ethash_check_difficulty_check) {
+ uint8_t hash[32], target[32];
+ memset(hash, 0, 32);
+ memset(target, 0, 32);
+
+ memcpy(hash, "11111111111111111111111111111111", 32);
+ memcpy(target, "22222222222222222222222222222222", 32);
+ BOOST_REQUIRE_MESSAGE(
+ ethash_check_difficulty(hash, target),
+ "\nexpected \"" << std::string((char *) hash, 32).c_str() << "\" to have the same or less difficulty than \"" << std::string((char *) target, 32).c_str() << "\"\n");
+ BOOST_REQUIRE_MESSAGE(
+ ethash_check_difficulty(hash, hash),
+ "\nexpected \"" << hash << "\" to have the same or less difficulty than \"" << hash << "\"\n");
+ memcpy(target, "11111111111111111111111111111112", 32);
+ BOOST_REQUIRE_MESSAGE(
+ ethash_check_difficulty(hash, target),
+ "\nexpected \"" << hash << "\" to have the same or less difficulty than \"" << target << "\"\n");
+ memcpy(target, "11111111111111111111111111111110", 32);
+ BOOST_REQUIRE_MESSAGE(
+ !ethash_check_difficulty(hash, target),
+ "\nexpected \"" << hash << "\" to have more difficulty than \"" << target << "\"\n");
+} \ No newline at end of file
diff --git a/Godeps/_workspace/src/github.com/ethereum/ethash/test/c/test.sh b/Godeps/_workspace/src/github.com/ethereum/ethash/test/c/test.sh
new file mode 100644
index 000000000..6d02d30f8
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/ethash/test/c/test.sh
@@ -0,0 +1,19 @@
+#!/bin/bash
+
+# Strict mode
+set -e
+
+SOURCE="${BASH_SOURCE[0]}"
+while [ -h "$SOURCE" ]; do
+ DIR="$( cd -P "$( dirname "$SOURCE" )" && pwd )"
+ SOURCE="$(readlink "$SOURCE")"
+ [[ $SOURCE != /* ]] && SOURCE="$DIR/$SOURCE"
+done
+TEST_DIR="$( cd -P "$( dirname "$SOURCE" )" && pwd )"
+
+rm -rf $TEST_DIR/build
+mkdir -p $TEST_DIR/build
+cd $TEST_DIR/build ;
+cmake ../../.. > /dev/null
+make Test
+./test/c/Test
diff --git a/Godeps/_workspace/src/github.com/ethereum/ethash/test/go/ethash_test.go b/Godeps/_workspace/src/github.com/ethereum/ethash/test/go/ethash_test.go
new file mode 100644
index 000000000..67ca51702
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/ethash/test/go/ethash_test.go
@@ -0,0 +1,82 @@
+package ethashTest
+
+import (
+ "bytes"
+ "crypto/rand"
+ "encoding/hex"
+ "log"
+ "math/big"
+ "testing"
+
+ "github.com/ethereum/ethash"
+ "github.com/ethereum/go-ethereum/core"
+ "github.com/ethereum/go-ethereum/ethdb"
+)
+
+func TestEthash(t *testing.T) {
+ seedHash := make([]byte, 32)
+ _, err := rand.Read(seedHash)
+ if err != nil {
+ panic(err)
+ }
+
+ db, err := ethdb.NewMemDatabase()
+ if err != nil {
+ panic(err)
+ }
+
+ blockProcessor, err := core.NewCanonical(5, db)
+ if err != nil {
+ panic(err)
+ }
+
+ log.Println("Block Number: ", blockProcessor.ChainManager().CurrentBlock().Number())
+
+ e := ethash.New(blockProcessor.ChainManager())
+
+ miningHash := make([]byte, 32)
+ if _, err := rand.Read(miningHash); err != nil {
+ panic(err)
+ }
+ diff := big.NewInt(10000)
+ log.Println("difficulty", diff)
+
+ nonce := uint64(0)
+
+ ghash_full := e.FullHash(nonce, miningHash)
+ log.Printf("ethash full (on nonce): %x %x\n", ghash_full, nonce)
+
+ ghash_light := e.LightHash(nonce, miningHash)
+ log.Printf("ethash light (on nonce): %x %x\n", ghash_light, nonce)
+
+ if bytes.Compare(ghash_full, ghash_light) != 0 {
+ t.Errorf("full: %x, light: %x", ghash_full, ghash_light)
+ }
+}
+
+func TestGetSeedHash(t *testing.T) {
+ seed0, err := ethash.GetSeedHash(0)
+ if err != nil {
+ t.Errorf("Failed to get seedHash for block 0: %v", err)
+ }
+ if bytes.Compare(seed0, []byte{0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}) != 0 {
+ log.Printf("seedHash for block 0 should be 0s, was: %v\n", seed0)
+ }
+ seed1, err := ethash.GetSeedHash(30000)
+ if err != nil {
+ t.Error(err)
+ }
+
+ // From python:
+ // > from pyethash import get_seedhash
+ // > get_seedhash(30000)
+ expectedSeed1, err := hex.DecodeString("290decd9548b62a8d60345a988386fc84ba6bc95484008f6362f93160ef3e563")
+ if err != nil {
+ t.Error(err)
+ }
+
+ if bytes.Compare(seed1, expectedSeed1) != 0 {
+ log.Printf("seedHash for block 1 should be: %v,\nactual value: %v\n", expectedSeed1, seed1)
+ }
+
+}
diff --git a/Godeps/_workspace/src/github.com/ethereum/ethash/test/go/test.sh b/Godeps/_workspace/src/github.com/ethereum/ethash/test/go/test.sh
new file mode 100644
index 000000000..c6224858e
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/ethash/test/go/test.sh
@@ -0,0 +1,20 @@
+#!/bin/bash
+
+# Strict mode
+set -e
+
+SOURCE="${BASH_SOURCE[0]}"
+while [ -h "$SOURCE" ]; do
+ DIR="$( cd -P "$( dirname "$SOURCE" )" && pwd )"
+ SOURCE="$(readlink "$SOURCE")"
+ [[ $SOURCE != /* ]] && SOURCE="$DIR/$SOURCE"
+done
+TEST_DIR="$( cd -P "$( dirname "$SOURCE" )" && pwd )"
+
+export GOPATH=${HOME}/.go
+export PATH=$PATH:$GOPATH/bin
+echo "# getting go dependencies (can take some time)..."
+cd ${TEST_DIR}/../.. && go get
+cd ${GOPATH}/src/github.com/ethereum/go-ethereum
+git checkout poc-9
+cd ${TEST_DIR} && go test
diff --git a/Godeps/_workspace/src/github.com/ethereum/ethash/test/python/.gitignore b/Godeps/_workspace/src/github.com/ethereum/ethash/test/python/.gitignore
new file mode 100644
index 000000000..c304fd615
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/ethash/test/python/.gitignore
@@ -0,0 +1 @@
+python-virtual-env/
diff --git a/Godeps/_workspace/src/github.com/ethereum/ethash/test/python/requirements.txt b/Godeps/_workspace/src/github.com/ethereum/ethash/test/python/requirements.txt
new file mode 100644
index 000000000..378263c62
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/ethash/test/python/requirements.txt
@@ -0,0 +1,3 @@
+pyethereum==0.7.522
+nose==1.3.4
+pysha3==0.3 \ No newline at end of file
diff --git a/Godeps/_workspace/src/github.com/ethereum/ethash/test/python/test.sh b/Godeps/_workspace/src/github.com/ethereum/ethash/test/python/test.sh
new file mode 100644
index 000000000..95cea0215
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/ethash/test/python/test.sh
@@ -0,0 +1,19 @@
+#!/bin/bash
+
+# Strict mode
+set -e
+
+SOURCE="${BASH_SOURCE[0]}"
+while [ -h "$SOURCE" ]; do
+ DIR="$( cd -P "$( dirname "$SOURCE" )" && pwd )"
+ SOURCE="$(readlink "$SOURCE")"
+ [[ $SOURCE != /* ]] && SOURCE="$DIR/$SOURCE"
+done
+TEST_DIR="$( cd -P "$( dirname "$SOURCE" )" && pwd )"
+
+[ -d $TEST_DIR/python-virtual-env ] || virtualenv --system-site-packages $TEST_DIR/python-virtual-env
+source $TEST_DIR/python-virtual-env/bin/activate
+pip install -r $TEST_DIR/requirements.txt > /dev/null
+pip install --upgrade --no-deps --force-reinstall -e $TEST_DIR/../..
+cd $TEST_DIR
+nosetests --with-doctest -v --nocapture
diff --git a/Godeps/_workspace/src/github.com/ethereum/ethash/test/python/test_pyethash.py b/Godeps/_workspace/src/github.com/ethereum/ethash/test/python/test_pyethash.py
new file mode 100644
index 000000000..7eb1b60c7
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/ethash/test/python/test_pyethash.py
@@ -0,0 +1,105 @@
+import pyethash
+from random import randint
+
+def test_get_cache_size_not_None():
+ for _ in range(100):
+ block_num = randint(0,12456789)
+ out = pyethash.get_cache_size(block_num)
+ assert out != None
+
+def test_get_full_size_not_None():
+ for _ in range(100):
+ block_num = randint(0,12456789)
+ out = pyethash.get_full_size(block_num)
+ assert out != None
+
+def test_get_cache_size_based_on_EPOCH():
+ for _ in range(100):
+ block_num = randint(0,12456789)
+ out1 = pyethash.get_cache_size(block_num)
+ out2 = pyethash.get_cache_size((block_num // pyethash.EPOCH_LENGTH) * pyethash.EPOCH_LENGTH)
+ assert out1 == out2
+
+def test_get_full_size_based_on_EPOCH():
+ for _ in range(100):
+ block_num = randint(0,12456789)
+ out1 = pyethash.get_full_size(block_num)
+ out2 = pyethash.get_full_size((block_num // pyethash.EPOCH_LENGTH) * pyethash.EPOCH_LENGTH)
+ assert out1 == out2
+
+# See light_and_full_client_checks in test.cpp
+def test_mkcache_is_as_expected():
+ actual = pyethash.mkcache_bytes(
+ 1024,
+ "~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~").encode('hex')
+ expected = "2da2b506f21070e1143d908e867962486d6b0a02e31d468fd5e3a7143aafa76a14201f63374314e2a6aaf84ad2eb57105dea3378378965a1b3873453bb2b78f9a8620b2ebeca41fbc773bb837b5e724d6eb2de570d99858df0d7d97067fb8103b21757873b735097b35d3bea8fd1c359a9e8a63c1540c76c9784cf8d975e995ca8620b2ebeca41fbc773bb837b5e724d6eb2de570d99858df0d7d97067fb8103b21757873b735097b35d3bea8fd1c359a9e8a63c1540c76c9784cf8d975e995ca8620b2ebeca41fbc773bb837b5e724d6eb2de570d99858df0d7d97067fb8103b21757873b735097b35d3bea8fd1c359a9e8a63c1540c76c9784cf8d975e995c259440b89fa3481c2c33171477c305c8e1e421f8d8f6d59585449d0034f3e421808d8da6bbd0b6378f567647cc6c4ba6c434592b198ad444e7284905b7c6adaf70bf43ec2daa7bd5e8951aa609ab472c124cf9eba3d38cff5091dc3f58409edcc386c743c3bd66f92408796ee1e82dd149eaefbf52b00ce33014a6eb3e50625413b072a58bc01da28262f42cbe4f87d4abc2bf287d15618405a1fe4e386fcdafbb171064bd99901d8f81dd6789396ce5e364ac944bbbd75a7827291c70b42d26385910cd53ca535ab29433dd5c5714d26e0dce95514c5ef866329c12e958097e84462197c2b32087849dab33e88b11da61d52f9dbc0b92cc61f742c07dbbf751c49d7678624ee60dfbe62e5e8c47a03d8247643f3d16ad8c8e663953bcda1f59d7e2d4a9bf0768e789432212621967a8f41121ad1df6ae1fa78782530695414c6213942865b2730375019105cae91a4c17a558d4b63059661d9f108362143107babe0b848de412e4da59168cce82bfbff3c99e022dd6ac1e559db991f2e3f7bb910cefd173e65ed00a8d5d416534e2c8416ff23977dbf3eb7180b75c71580d08ce95efeb9b0afe904ea12285a392aff0c8561ff79fca67f694a62b9e52377485c57cc3598d84cac0a9d27960de0cc31ff9bbfe455acaa62c8aa5d2cce96f345da9afe843d258a99c4eaf3650fc62efd81c7b81cd0d534d2d71eeda7a6e315d540b4473c80f8730037dc2ae3e47b986240cfc65ccc565f0d8cde0bc68a57e39a271dda57440b3598bee19f799611d25731a96b5dbbbefdff6f4f656161462633030d62560ea4e9c161cf78fc96a2ca5aaa32453a6c5dea206f766244e8c9d9a8dc61185ce37f1fc804459c5f07434f8ecb34141b8dcae7eae704c950b55556c5f40140c3714b45eddb02637513268778cbf937a33e4e33183685f9deb31ef54e90161e76d969587dd782eaa94e289420e7c2ee908517f5893a26fdb5873d68f92d118d4bcf98d7a4916794d6ab290045e30f9ea00ca547c584b8482b0331ba1539a0f2714fddc3a0b06b0cfbb6a607b8339c39bcfd6640b1f653e9d70ef6c985b"
+ assert actual == expected
+
+def test_calc_dataset_is_not_None():
+ cache = pyethash.mkcache_bytes(
+ 1024,
+ "~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~")
+ assert pyethash.calc_dataset_bytes(1024 * 32, cache) != None
+
+def test_light_and_full_agree():
+ cache = pyethash.mkcache_bytes(
+ 1024,
+ "~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~")
+ full_size = 1024 * 32
+ header = "~~~~~X~~~~~~~~~~~~~~~~~~~~~~~~~~"
+ light_result = pyethash.hashimoto_light(full_size, cache, header, 0)
+ dataset = pyethash.calc_dataset_bytes(full_size, cache)
+ full_result = pyethash.hashimoto_full(dataset, header, 0)
+ assert light_result["mix digest"] != None
+ assert len(light_result["mix digest"]) == 32
+ assert light_result["mix digest"] == full_result["mix digest"]
+ assert light_result["result"] != None
+ assert len(light_result["result"]) == 32
+ assert light_result["result"] == full_result["result"]
+
+def int_to_bytes(i):
+ b = []
+ for _ in range(32):
+ b.append(chr(i & 0xff))
+ i >>= 8
+ b.reverse()
+ return "".join(b)
+
+def test_mining_basic():
+ easy_difficulty = int_to_bytes(2**256 - 1)
+ assert easy_difficulty.encode('hex') == 'f' * 64
+ cache = pyethash.mkcache_bytes(
+ 1024,
+ "~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~")
+ full_size = 1024 * 32
+ header = "~~~~~X~~~~~~~~~~~~~~~~~~~~~~~~~~"
+ dataset = pyethash.calc_dataset_bytes(full_size, cache)
+ # Check type of outputs
+ assert type(pyethash.mine(dataset,header,easy_difficulty)) == dict
+ assert type(pyethash.mine(dataset,header,easy_difficulty)["nonce"]) == long
+ assert type(pyethash.mine(dataset,header,easy_difficulty)["mix digest"]) == str
+ assert type(pyethash.mine(dataset,header,easy_difficulty)["result"]) == str
+
+def test_mining_doesnt_always_return_the_same_value():
+ easy_difficulty1 = int_to_bytes(int(2**256 * 0.999))
+ # 1 in 1000 difficulty
+ easy_difficulty2 = int_to_bytes(int(2**256 * 0.001))
+ assert easy_difficulty1 != easy_difficulty2
+ cache = pyethash.mkcache_bytes(
+ 1024,
+ "~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~")
+ full_size = 1024 * 32
+ header = "~~~~~X~~~~~~~~~~~~~~~~~~~~~~~~~~"
+ dataset = pyethash.calc_dataset_bytes(full_size, cache)
+ # Check type of outputs
+ assert pyethash.mine(dataset, header, easy_difficulty1)['nonce'] != pyethash.mine(dataset, header, easy_difficulty2)['nonce']
+
+def test_get_seedhash():
+ assert pyethash.get_seedhash(0).encode('hex') == '0' * 64
+ import hashlib, sha3
+ expected = pyethash.get_seedhash(0)
+ #print "checking seed hashes:",
+ for i in range(0, 30000*2048, 30000):
+ #print i // 30000,
+ assert pyethash.get_seedhash(i) == expected
+ expected = hashlib.sha3_256(expected).digest()
diff --git a/Godeps/_workspace/src/github.com/ethereum/ethash/test/test.sh b/Godeps/_workspace/src/github.com/ethereum/ethash/test/test.sh
new file mode 100644
index 000000000..fd3508609
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/ethash/test/test.sh
@@ -0,0 +1,31 @@
+#!/bin/bash
+
+# Strict mode
+set -e
+
+SOURCE="${BASH_SOURCE[0]}"
+while [ -h "$SOURCE" ]; do
+ DIR="$( cd -P "$( dirname "$SOURCE" )" && pwd )"
+ SOURCE="$(readlink "$SOURCE")"
+ [[ $SOURCE != /* ]] && SOURCE="$DIR/$SOURCE"
+done
+TEST_DIR="$( cd -P "$( dirname "$SOURCE" )" && pwd )"
+
+echo -e "\n################# Testing JS ##################"
+# TODO: Use mocha and real testing tools instead of rolling our own
+cd $TEST_DIR/../js
+if [ -x "$(which nodejs)" ] ; then
+ nodejs test.js
+fi
+if [ -x "$(which node)" ] ; then
+ node test.js
+fi
+
+echo -e "\n################# Testing C ##################"
+$TEST_DIR/c/test.sh
+
+echo -e "\n################# Testing Python ##################"
+$TEST_DIR/python/test.sh
+
+#echo "################# Testing Go ##################"
+#$TEST_DIR/go/test.sh
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/.gitignore b/Godeps/_workspace/src/github.com/ethereum/serpent-go/.gitignore
new file mode 100644
index 000000000..5d02b54e5
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/.gitignore
@@ -0,0 +1,5 @@
+/tmp
+*/**/*un~
+*un~
+.DS_Store
+*/**/.DS_Store
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/.gitmodules b/Godeps/_workspace/src/github.com/ethereum/serpent-go/.gitmodules
new file mode 100644
index 000000000..054c7d628
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/.gitmodules
@@ -0,0 +1,3 @@
+[submodule "serp"]
+ path = serpent
+ url = https://github.com/ethereum/serpent.git
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/README.md b/Godeps/_workspace/src/github.com/ethereum/serpent-go/README.md
new file mode 100644
index 000000000..404f1b380
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/README.md
@@ -0,0 +1,12 @@
+[serpent](https://github.com/ethereum/serpent) go bindings.
+
+## Build instructions
+
+```
+go get -d github.com/ethereum/serpent-go
+cd $GOPATH/src/github.com/ethereum/serpent-go
+git submodule init
+git submodule update
+```
+
+You're now ready to go :-)
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/all.cpp b/Godeps/_workspace/src/github.com/ethereum/serpent-go/all.cpp
new file mode 100644
index 000000000..80032f900
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/all.cpp
@@ -0,0 +1,16 @@
+#include "serpent/bignum.cpp"
+#include "serpent/util.cpp"
+#include "serpent/tokenize.cpp"
+#include "serpent/parser.cpp"
+#include "serpent/compiler.cpp"
+#include "serpent/funcs.cpp"
+#include "serpent/lllparser.cpp"
+#include "serpent/rewriter.cpp"
+
+#include "serpent/opcodes.cpp"
+#include "serpent/optimize.cpp"
+#include "serpent/functions.cpp"
+#include "serpent/preprocess.cpp"
+#include "serpent/rewriteutils.cpp"
+
+#include "cpp/api.cpp"
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/cpp/api.cpp b/Godeps/_workspace/src/github.com/ethereum/serpent-go/cpp/api.cpp
new file mode 100644
index 000000000..bd2c85c7d
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/cpp/api.cpp
@@ -0,0 +1,26 @@
+#include <string>
+
+#include "serpent/lllparser.h"
+#include "serpent/bignum.h"
+#include "serpent/util.h"
+#include "serpent/tokenize.h"
+#include "serpent/parser.h"
+#include "serpent/compiler.h"
+
+#include "cpp/api.h"
+
+const char *compileGo(char *code, int *err)
+{
+ try {
+ std::string c = binToHex(compile(std::string(code)));
+
+ return c.c_str();
+ }
+ catch(std::string &error) {
+ *err = 1;
+ return error.c_str();
+ }
+ catch(...) {
+ return "Unknown error";
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/cpp/api.h b/Godeps/_workspace/src/github.com/ethereum/serpent-go/cpp/api.h
new file mode 100644
index 000000000..235b5eb4a
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/cpp/api.h
@@ -0,0 +1,14 @@
+#ifndef CPP_API_H
+#define CPP_API_H
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+const char *compileGo(char *code, int *err);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent.go b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent.go
new file mode 100644
index 000000000..39b60eed7
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent.go
@@ -0,0 +1,27 @@
+package serpent
+
+// #cgo CXXFLAGS: -I. -Ilangs/ -std=c++0x -Wall -fno-strict-aliasing
+// #cgo LDFLAGS: -lstdc++
+//
+// #include "cpp/api.h"
+//
+import "C"
+
+import (
+ "encoding/hex"
+ "errors"
+ "unsafe"
+)
+
+func Compile(str string) ([]byte, error) {
+ var err C.int
+ out := C.GoString(C.compileGo(C.CString(str), (*C.int)(unsafe.Pointer(&err))))
+
+ if err == C.int(1) {
+ return nil, errors.New(out)
+ }
+
+ bytes, _ := hex.DecodeString(out)
+
+ return bytes, nil
+}
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/.gitignore b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/.gitignore
new file mode 100644
index 000000000..72b65e446
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/.gitignore
@@ -0,0 +1,12 @@
+[._]*.s[a-w][a-z]
+[._]s[a-w][a-z]
+*.un~
+Session.vim
+.netrwhist
+*~
+*.o
+serpent
+libserpent.a
+pyserpent.so
+dist
+*.egg-info
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/MANIFEST.in b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/MANIFEST.in
new file mode 100644
index 000000000..5f5766ced
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/MANIFEST.in
@@ -0,0 +1,5 @@
+include *.cpp
+include *.h
+include *py
+include README.md
+include Makefile
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/Makefile b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/Makefile
new file mode 100644
index 000000000..28c38728e
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/Makefile
@@ -0,0 +1,55 @@
+PLATFORM_OPTS =
+PYTHON = /usr/include/python2.7
+CXXFLAGS = -fPIC
+# -g3 -O0
+BOOST_INC = /usr/include
+BOOST_LIB = /usr/lib
+TARGET = pyserpent
+COMMON_OBJS = bignum.o util.o tokenize.o lllparser.o parser.o opcodes.o optimize.o functions.o rewriteutils.o preprocess.o rewriter.o compiler.o funcs.o
+HEADERS = bignum.h util.h tokenize.h lllparser.h parser.h opcodes.h functions.h optimize.h rewriteutils.h preprocess.h rewriter.h compiler.h funcs.h
+PYTHON_VERSION = 2.7
+
+serpent : serpentc lib
+
+lib:
+ ar rvs libserpent.a $(COMMON_OBJS)
+ g++ $(CXXFLAGS) -shared $(COMMON_OBJS) -o libserpent.so
+
+serpentc: $(COMMON_OBJS) cmdline.o
+ rm -rf serpent
+ g++ -Wall $(COMMON_OBJS) cmdline.o -o serpent
+
+bignum.o : bignum.cpp bignum.h
+
+opcodes.o : opcodes.cpp opcodes.h
+
+util.o : util.cpp util.h bignum.o
+
+tokenize.o : tokenize.cpp tokenize.h util.o
+
+lllparser.o : lllparser.cpp lllparser.h tokenize.o util.o
+
+parser.o : parser.cpp parser.h tokenize.o util.o
+
+rewriter.o : rewriter.cpp rewriter.h lllparser.o util.o rewriteutils.o preprocess.o opcodes.o functions.o
+
+preprocessor.o: rewriteutils.o functions.o
+
+compiler.o : compiler.cpp compiler.h util.o
+
+funcs.o : funcs.cpp funcs.h
+
+cmdline.o: cmdline.cpp
+
+pyext.o: pyext.cpp
+
+clean:
+ rm -f serpent *\.o libserpent.a libserpent.so
+
+install:
+ cp serpent /usr/local/bin
+ cp libserpent.a /usr/local/lib
+ cp libserpent.so /usr/local/lib
+ rm -rf /usr/local/include/libserpent
+ mkdir -p /usr/local/include/libserpent
+ cp $(HEADERS) /usr/local/include/libserpent
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/README.md b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/README.md
new file mode 100644
index 000000000..03dfcc15f
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/README.md
@@ -0,0 +1,3 @@
+Installation:
+
+```make && sudo make install```
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/bignum.cpp b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/bignum.cpp
new file mode 100644
index 000000000..108b1eb04
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/bignum.cpp
@@ -0,0 +1,112 @@
+#include <stdio.h>
+#include <iostream>
+#include <vector>
+#include <map>
+#include "bignum.h"
+
+//Integer to string conversion
+std::string unsignedToDecimal(unsigned branch) {
+ if (branch < 10) return nums.substr(branch, 1);
+ else return unsignedToDecimal(branch / 10) + nums.substr(branch % 10,1);
+}
+
+//Add two strings representing decimal values
+std::string decimalAdd(std::string a, std::string b) {
+ std::string o = a;
+ while (b.length() < a.length()) b = "0" + b;
+ while (o.length() < b.length()) o = "0" + o;
+ bool carry = false;
+ for (int i = o.length() - 1; i >= 0; i--) {
+ o[i] = o[i] + b[i] - '0';
+ if (carry) o[i]++;
+ if (o[i] > '9') {
+ o[i] -= 10;
+ carry = true;
+ }
+ else carry = false;
+ }
+ if (carry) o = "1" + o;
+ return o;
+}
+
+//Helper function for decimalMul
+std::string decimalDigitMul(std::string a, int dig) {
+ if (dig == 0) return "0";
+ else return decimalAdd(a, decimalDigitMul(a, dig - 1));
+}
+
+//Multiply two strings representing decimal values
+std::string decimalMul(std::string a, std::string b) {
+ std::string o = "0";
+ for (unsigned i = 0; i < b.length(); i++) {
+ std::string n = decimalDigitMul(a, b[i] - '0');
+ if (n != "0") {
+ for (unsigned j = i + 1; j < b.length(); j++) n += "0";
+ }
+ o = decimalAdd(o, n);
+ }
+ return o;
+}
+
+//Modexp
+std::string decimalModExp(std::string b, std::string e, std::string m) {
+ if (e == "0") return "1";
+ else if (e == "1") return b;
+ else if (decimalMod(e, "2") == "0") {
+ std::string o = decimalModExp(b, decimalDiv(e, "2"), m);
+ return decimalMod(decimalMul(o, o), m);
+ }
+ else {
+ std::string o = decimalModExp(b, decimalDiv(e, "2"), m);
+ return decimalMod(decimalMul(decimalMul(o, o), b), m);
+ }
+}
+
+//Is a greater than b? Flag allows equality
+bool decimalGt(std::string a, std::string b, bool eqAllowed) {
+ if (a == b) return eqAllowed;
+ return (a.length() > b.length()) || (a.length() >= b.length() && a > b);
+}
+
+//Subtract the two strings representing decimal values
+std::string decimalSub(std::string a, std::string b) {
+ if (b == "0") return a;
+ if (b == a) return "0";
+ while (b.length() < a.length()) b = "0" + b;
+ std::string c = b;
+ for (unsigned i = 0; i < c.length(); i++) c[i] = '0' + ('9' - c[i]);
+ std::string o = decimalAdd(decimalAdd(a, c).substr(1), "1");
+ while (o.size() > 1 && o[0] == '0') o = o.substr(1);
+ return o;
+}
+
+//Divide the two strings representing decimal values
+std::string decimalDiv(std::string a, std::string b) {
+ std::string c = b;
+ if (decimalGt(c, a)) return "0";
+ int zeroes = -1;
+ while (decimalGt(a, c, true)) {
+ zeroes += 1;
+ c = c + "0";
+ }
+ c = c.substr(0, c.size() - 1);
+ std::string quot = "0";
+ while (decimalGt(a, c, true)) {
+ a = decimalSub(a, c);
+ quot = decimalAdd(quot, "1");
+ }
+ for (int i = 0; i < zeroes; i++) quot += "0";
+ return decimalAdd(quot, decimalDiv(a, b));
+}
+
+//Modulo the two strings representing decimal values
+std::string decimalMod(std::string a, std::string b) {
+ return decimalSub(a, decimalMul(decimalDiv(a, b), b));
+}
+
+//String to int conversion
+unsigned decimalToUnsigned(std::string a) {
+ if (a.size() == 0) return 0;
+ else return (a[a.size() - 1] - '0')
+ + decimalToUnsigned(a.substr(0,a.size()-1)) * 10;
+}
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/bignum.h b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/bignum.h
new file mode 100644
index 000000000..99571acd2
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/bignum.h
@@ -0,0 +1,41 @@
+#ifndef ETHSERP_BIGNUM
+#define ETHSERP_BIGNUM
+
+const std::string nums = "0123456789";
+
+const std::string tt256 =
+"115792089237316195423570985008687907853269984665640564039457584007913129639936"
+;
+
+const std::string tt256m1 =
+"115792089237316195423570985008687907853269984665640564039457584007913129639935"
+;
+
+const std::string tt255 =
+"57896044618658097711785492504343953926634992332820282019728792003956564819968";
+
+const std::string tt176 =
+"95780971304118053647396689196894323976171195136475136";
+
+std::string unsignedToDecimal(unsigned branch);
+
+std::string decimalAdd(std::string a, std::string b);
+
+std::string decimalMul(std::string a, std::string b);
+
+std::string decimalSub(std::string a, std::string b);
+
+std::string decimalDiv(std::string a, std::string b);
+
+std::string decimalMod(std::string a, std::string b);
+
+std::string decimalModExp(std::string b, std::string e, std::string m);
+
+bool decimalGt(std::string a, std::string b, bool eqAllowed=false);
+
+unsigned decimalToUnsigned(std::string a);
+
+#define utd unsignedToDecimal
+#define dtu decimalToUnsigned
+
+#endif
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/cmdline.cpp b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/cmdline.cpp
new file mode 100644
index 000000000..fe2560830
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/cmdline.cpp
@@ -0,0 +1,132 @@
+#include <stdio.h>
+#include <string>
+#include <iostream>
+#include <vector>
+#include <map>
+#include "funcs.h"
+
+int main(int argv, char** argc) {
+ if (argv == 1) {
+ std::cerr << "Must provide a command and arguments! Try parse, rewrite, compile, assemble\n";
+ return 0;
+ }
+ if (argv == 2 && std::string(argc[1]) == "--help" || std::string(argc[1]) == "-h" ) {
+ std::cout << argc[1] << "\n";
+
+ std::cout << "serpent command input\n";
+ std::cout << "where input -s for from stdin, a file, or interpreted as serpent code if does not exist as file.";
+ std::cout << "where command: \n";
+ std::cout << " parse: Just parses and returns s-expression code.\n";
+ std::cout << " rewrite: Parse, use rewrite rules print s-expressions of result.\n";
+ std::cout << " compile: Return resulting compiled EVM code in hex.\n";
+ std::cout << " assemble: Return result from step before compilation.\n";
+ return 0;
+ }
+
+ std::string flag = "";
+ std::string command = argc[1];
+ std::string input;
+ std::string secondInput;
+ if (std::string(argc[1]) == "-s") {
+ flag = command.substr(1);
+ command = argc[2];
+ input = "";
+ std::string line;
+ while (std::getline(std::cin, line)) {
+ input += line + "\n";
+ }
+ secondInput = argv == 3 ? "" : argc[3];
+ }
+ else {
+ if (argv == 2) {
+ std::cerr << "Not enough arguments for serpent cmdline\n";
+ throw(0);
+ }
+ input = argc[2];
+ secondInput = argv == 3 ? "" : argc[3];
+ }
+ bool haveSec = secondInput.length() > 0;
+ if (command == "parse" || command == "parse_serpent") {
+ std::cout << printAST(parseSerpent(input), haveSec) << "\n";
+ }
+ else if (command == "rewrite") {
+ std::cout << printAST(rewrite(parseLLL(input, true)), haveSec) << "\n";
+ }
+ else if (command == "compile_to_lll") {
+ std::cout << printAST(compileToLLL(input), haveSec) << "\n";
+ }
+ else if (command == "rewrite_chunk") {
+ std::cout << printAST(rewriteChunk(parseLLL(input, true)), haveSec) << "\n";
+ }
+ else if (command == "compile_chunk_to_lll") {
+ std::cout << printAST(compileChunkToLLL(input), haveSec) << "\n";
+ }
+ else if (command == "build_fragtree") {
+ std::cout << printAST(buildFragmentTree(parseLLL(input, true))) << "\n";
+ }
+ else if (command == "compile_lll") {
+ std::cout << binToHex(compileLLL(parseLLL(input, true))) << "\n";
+ }
+ else if (command == "dereference") {
+ std::cout << printAST(dereference(parseLLL(input, true)), haveSec) <<"\n";
+ }
+ else if (command == "pretty_assemble") {
+ std::cout << printTokens(prettyAssemble(parseLLL(input, true))) <<"\n";
+ }
+ else if (command == "pretty_compile_lll") {
+ std::cout << printTokens(prettyCompileLLL(parseLLL(input, true))) << "\n";
+ }
+ else if (command == "pretty_compile") {
+ std::cout << printTokens(prettyCompile(input)) << "\n";
+ }
+ else if (command == "pretty_compile_chunk") {
+ std::cout << printTokens(prettyCompileChunk(input)) << "\n";
+ }
+ else if (command == "assemble") {
+ std::cout << assemble(parseLLL(input, true)) << "\n";
+ }
+ else if (command == "serialize") {
+ std::cout << binToHex(serialize(tokenize(input, Metadata(), false))) << "\n";
+ }
+ else if (command == "flatten") {
+ std::cout << printTokens(flatten(parseLLL(input, true))) << "\n";
+ }
+ else if (command == "deserialize") {
+ std::cout << printTokens(deserialize(hexToBin(input))) << "\n";
+ }
+ else if (command == "compile") {
+ std::cout << binToHex(compile(input)) << "\n";
+ }
+ else if (command == "compile_chunk") {
+ std::cout << binToHex(compileChunk(input)) << "\n";
+ }
+ else if (command == "encode_datalist") {
+ std::vector<Node> tokens = tokenize(input);
+ std::vector<std::string> o;
+ for (int i = 0; i < (int)tokens.size(); i++) {
+ o.push_back(tokens[i].val);
+ }
+ std::cout << binToHex(encodeDatalist(o)) << "\n";
+ }
+ else if (command == "decode_datalist") {
+ std::vector<std::string> o = decodeDatalist(hexToBin(input));
+ std::vector<Node> tokens;
+ for (int i = 0; i < (int)o.size(); i++)
+ tokens.push_back(token(o[i]));
+ std::cout << printTokens(tokens) << "\n";
+ }
+ else if (command == "tokenize") {
+ std::cout << printTokens(tokenize(input));
+ }
+ else if (command == "biject") {
+ if (argv == 3)
+ std::cerr << "Not enough arguments for biject\n";
+ int pos = decimalToUnsigned(secondInput);
+ std::vector<Node> n = prettyCompile(input);
+ if (pos >= (int)n.size())
+ std::cerr << "Code position too high\n";
+ Metadata m = n[pos].metadata;
+ std::cout << "Opcode: " << n[pos].val << ", file: " << m.file <<
+ ", line: " << m.ln << ", char: " << m.ch << "\n";
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/compiler.cpp b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/compiler.cpp
new file mode 100644
index 000000000..b9281dcbc
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/compiler.cpp
@@ -0,0 +1,554 @@
+#include <stdio.h>
+#include <iostream>
+#include <vector>
+#include <map>
+#include "util.h"
+#include "bignum.h"
+#include "opcodes.h"
+
+struct programAux {
+ std::map<std::string, std::string> vars;
+ int nextVarMem;
+ bool allocUsed;
+ bool calldataUsed;
+ int step;
+ int labelLength;
+};
+
+struct programVerticalAux {
+ int height;
+ std::string innerScopeName;
+ std::map<std::string, int> dupvars;
+ std::map<std::string, int> funvars;
+ std::vector<mss> scopes;
+};
+
+struct programData {
+ programAux aux;
+ Node code;
+ int outs;
+};
+
+programAux Aux() {
+ programAux o;
+ o.allocUsed = false;
+ o.calldataUsed = false;
+ o.step = 0;
+ o.nextVarMem = 32;
+ return o;
+}
+
+programVerticalAux verticalAux() {
+ programVerticalAux o;
+ o.height = 0;
+ o.dupvars = std::map<std::string, int>();
+ o.funvars = std::map<std::string, int>();
+ o.scopes = std::vector<mss>();
+ return o;
+}
+
+programData pd(programAux aux = Aux(), Node code=token("_"), int outs=0) {
+ programData o;
+ o.aux = aux;
+ o.code = code;
+ o.outs = outs;
+ return o;
+}
+
+Node multiToken(Node nodes[], int len, Metadata met) {
+ std::vector<Node> out;
+ for (int i = 0; i < len; i++) {
+ out.push_back(nodes[i]);
+ }
+ return astnode("_", out, met);
+}
+
+Node finalize(programData c);
+
+Node popwrap(Node node) {
+ Node nodelist[] = {
+ node,
+ token("POP", node.metadata)
+ };
+ return multiToken(nodelist, 2, node.metadata);
+}
+
+// Grabs variables
+mss getVariables(Node node, mss cur=mss()) {
+ Metadata m = node.metadata;
+ // Tokens don't contain any variables
+ if (node.type == TOKEN)
+ return cur;
+ // Don't descend into call fragments
+ else if (node.val == "lll")
+ return getVariables(node.args[1], cur);
+ // At global scope get/set/ref also declare
+ else if (node.val == "get" || node.val == "set" || node.val == "ref") {
+ if (node.args[0].type != TOKEN)
+ err("Variable name must be simple token,"
+ " not complex expression!", m);
+ if (!cur.count(node.args[0].val)) {
+ cur[node.args[0].val] = utd(cur.size() * 32 + 32);
+ //std::cerr << node.args[0].val << " " << cur[node.args[0].val] << "\n";
+ }
+ }
+ // Recursively process children
+ for (unsigned i = 0; i < node.args.size(); i++) {
+ cur = getVariables(node.args[i], cur);
+ }
+ return cur;
+}
+
+// Turns LLL tree into tree of code fragments
+programData opcodeify(Node node,
+ programAux aux=Aux(),
+ programVerticalAux vaux=verticalAux()) {
+ std::string symb = "_"+mkUniqueToken();
+ Metadata m = node.metadata;
+ // Get variables
+ if (!aux.vars.size()) {
+ aux.vars = getVariables(node);
+ aux.nextVarMem = aux.vars.size() * 32 + 32;
+ }
+ // Numbers
+ if (node.type == TOKEN) {
+ return pd(aux, nodeToNumeric(node), 1);
+ }
+ else if (node.val == "ref" || node.val == "get" || node.val == "set") {
+ std::string varname = node.args[0].val;
+ // Determine reference to variable
+ Node varNode = tkn(aux.vars[varname], m);
+ //std::cerr << varname << " " << printSimple(varNode) << "\n";
+ // Set variable
+ if (node.val == "set") {
+ programData sub = opcodeify(node.args[1], aux, vaux);
+ if (!sub.outs)
+ err("Value to set variable must have nonzero arity!", m);
+ // What if we are setting a stack variable?
+ if (vaux.dupvars.count(node.args[0].val)) {
+ int h = vaux.height - vaux.dupvars[node.args[0].val];
+ if (h > 16) err("Too deep for stack variable (max 16)", m);
+ Node nodelist[] = {
+ sub.code,
+ token("SWAP"+unsignedToDecimal(h), m),
+ token("POP", m)
+ };
+ return pd(sub.aux, multiToken(nodelist, 3, m), 0);
+ }
+ // Setting a memory variable
+ else {
+ Node nodelist[] = {
+ sub.code,
+ varNode,
+ token("MSTORE", m),
+ };
+ return pd(sub.aux, multiToken(nodelist, 3, m), 0);
+ }
+ }
+ // Get variable
+ else if (node.val == "get") {
+ // Getting a stack variable
+ if (vaux.dupvars.count(node.args[0].val)) {
+ int h = vaux.height - vaux.dupvars[node.args[0].val];
+ if (h > 16) err("Too deep for stack variable (max 16)", m);
+ return pd(aux, token("DUP"+unsignedToDecimal(h)), 1);
+ }
+ // Getting a memory variable
+ else {
+ Node nodelist[] =
+ { varNode, token("MLOAD", m) };
+ return pd(aux, multiToken(nodelist, 2, m), 1);
+ }
+ }
+ // Refer variable
+ else if (node.val == "ref") {
+ if (vaux.dupvars.count(node.args[0].val))
+ err("Cannot ref stack variable!", m);
+ return pd(aux, varNode, 1);
+ }
+ }
+ // Comments do nothing
+ else if (node.val == "comment") {
+ Node nodelist[] = { };
+ return pd(aux, multiToken(nodelist, 0, m), 0);
+ }
+ // Custom operation sequence
+ // eg. (ops bytez id msize swap1 msize add 0 swap1 mstore) == alloc
+ if (node.val == "ops") {
+ std::vector<Node> subs2;
+ int depth = 0;
+ for (unsigned i = 0; i < node.args.size(); i++) {
+ std::string op = upperCase(node.args[i].val);
+ if (node.args[i].type == ASTNODE || opinputs(op) == -1) {
+ programVerticalAux vaux2 = vaux;
+ vaux2.height = vaux.height - i - 1 + node.args.size();
+ programData sub = opcodeify(node.args[i], aux, vaux2);
+ aux = sub.aux;
+ depth += sub.outs;
+ subs2.push_back(sub.code);
+ }
+ else {
+ subs2.push_back(token(op, m));
+ depth += opoutputs(op) - opinputs(op);
+ }
+ }
+ if (depth < 0 || depth > 1) err("Stack depth mismatch", m);
+ return pd(aux, astnode("_", subs2, m), 0);
+ }
+ // Code blocks
+ if (node.val == "lll" && node.args.size() == 2) {
+ if (node.args[1].val != "0") aux.allocUsed = true;
+ std::vector<Node> o;
+ o.push_back(finalize(opcodeify(node.args[0])));
+ programData sub = opcodeify(node.args[1], aux, vaux);
+ Node code = astnode("____CODE", o, m);
+ Node nodelist[] = {
+ token("$begincode"+symb+".endcode"+symb, m), token("DUP1", m),
+ token("$begincode"+symb, m), sub.code, token("CODECOPY", m),
+ token("$endcode"+symb, m), token("JUMP", m),
+ token("~begincode"+symb, m), code,
+ token("~endcode"+symb, m), token("JUMPDEST", m)
+ };
+ return pd(sub.aux, multiToken(nodelist, 11, m), 1);
+ }
+ // Stack variables
+ if (node.val == "with") {
+ programData initial = opcodeify(node.args[1], aux, vaux);
+ programVerticalAux vaux2 = vaux;
+ vaux2.dupvars[node.args[0].val] = vaux.height;
+ vaux2.height += 1;
+ if (!initial.outs)
+ err("Initial variable value must have nonzero arity!", m);
+ programData sub = opcodeify(node.args[2], initial.aux, vaux2);
+ Node nodelist[] = {
+ initial.code,
+ sub.code
+ };
+ programData o = pd(sub.aux, multiToken(nodelist, 2, m), sub.outs);
+ if (sub.outs)
+ o.code.args.push_back(token("SWAP1", m));
+ o.code.args.push_back(token("POP", m));
+ return o;
+ }
+ // Seq of multiple statements
+ if (node.val == "seq") {
+ std::vector<Node> children;
+ int lastOut = 0;
+ for (unsigned i = 0; i < node.args.size(); i++) {
+ programData sub = opcodeify(node.args[i], aux, vaux);
+ aux = sub.aux;
+ if (sub.outs == 1) {
+ if (i < node.args.size() - 1) sub.code = popwrap(sub.code);
+ else lastOut = 1;
+ }
+ children.push_back(sub.code);
+ }
+ return pd(aux, astnode("_", children, m), lastOut);
+ }
+ // 2-part conditional (if gets rewritten to unless in rewrites)
+ else if (node.val == "unless" && node.args.size() == 2) {
+ programData cond = opcodeify(node.args[0], aux, vaux);
+ programData action = opcodeify(node.args[1], cond.aux, vaux);
+ aux = action.aux;
+ if (!cond.outs) err("Condition of if/unless statement has arity 0", m);
+ if (action.outs) action.code = popwrap(action.code);
+ Node nodelist[] = {
+ cond.code,
+ token("$endif"+symb, m), token("JUMPI", m),
+ action.code,
+ token("~endif"+symb, m), token("JUMPDEST", m)
+ };
+ return pd(aux, multiToken(nodelist, 6, m), 0);
+ }
+ // 3-part conditional
+ else if (node.val == "if" && node.args.size() == 3) {
+ programData ifd = opcodeify(node.args[0], aux, vaux);
+ programData thend = opcodeify(node.args[1], ifd.aux, vaux);
+ programData elsed = opcodeify(node.args[2], thend.aux, vaux);
+ aux = elsed.aux;
+ if (!ifd.outs)
+ err("Condition of if/unless statement has arity 0", m);
+ // Handle cases where one conditional outputs something
+ // and the other does not
+ int outs = (thend.outs && elsed.outs) ? 1 : 0;
+ if (thend.outs > outs) thend.code = popwrap(thend.code);
+ if (elsed.outs > outs) elsed.code = popwrap(elsed.code);
+ Node nodelist[] = {
+ ifd.code,
+ token("ISZERO", m),
+ token("$else"+symb, m), token("JUMPI", m),
+ thend.code,
+ token("$endif"+symb, m), token("JUMP", m),
+ token("~else"+symb, m), token("JUMPDEST", m),
+ elsed.code,
+ token("~endif"+symb, m), token("JUMPDEST", m)
+ };
+ return pd(aux, multiToken(nodelist, 12, m), outs);
+ }
+ // While (rewritten to this in rewrites)
+ else if (node.val == "until") {
+ programData cond = opcodeify(node.args[0], aux, vaux);
+ programData action = opcodeify(node.args[1], cond.aux, vaux);
+ aux = action.aux;
+ if (!cond.outs)
+ err("Condition of while/until loop has arity 0", m);
+ if (action.outs) action.code = popwrap(action.code);
+ Node nodelist[] = {
+ token("~beg"+symb, m), token("JUMPDEST", m),
+ cond.code,
+ token("$end"+symb, m), token("JUMPI", m),
+ action.code,
+ token("$beg"+symb, m), token("JUMP", m),
+ token("~end"+symb, m), token("JUMPDEST", m),
+ };
+ return pd(aux, multiToken(nodelist, 10, m));
+ }
+ // Memory allocations
+ else if (node.val == "alloc") {
+ programData bytez = opcodeify(node.args[0], aux, vaux);
+ aux = bytez.aux;
+ if (!bytez.outs)
+ err("Alloc input has arity 0", m);
+ aux.allocUsed = true;
+ Node nodelist[] = {
+ bytez.code,
+ token("MSIZE", m), token("SWAP1", m), token("MSIZE", m),
+ token("ADD", m),
+ token("0", m), token("SWAP1", m), token("MSTORE", m)
+ };
+ return pd(aux, multiToken(nodelist, 8, m), 1);
+ }
+ // All other functions/operators
+ else {
+ std::vector<Node> subs2;
+ int depth = opinputs(upperCase(node.val));
+ if (depth == -1)
+ err("Not a function or opcode: "+node.val, m);
+ if ((int)node.args.size() != depth)
+ err("Invalid arity for "+node.val, m);
+ for (int i = node.args.size() - 1; i >= 0; i--) {
+ programVerticalAux vaux2 = vaux;
+ vaux2.height = vaux.height - i - 1 + node.args.size();
+ programData sub = opcodeify(node.args[i], aux, vaux2);
+ aux = sub.aux;
+ if (!sub.outs)
+ err("Input "+unsignedToDecimal(i)+" has arity 0", sub.code.metadata);
+ subs2.push_back(sub.code);
+ }
+ subs2.push_back(token(upperCase(node.val), m));
+ int outdepth = opoutputs(upperCase(node.val));
+ return pd(aux, astnode("_", subs2, m), outdepth);
+ }
+}
+
+// Adds necessary wrappers to a program
+Node finalize(programData c) {
+ std::vector<Node> bottom;
+ Metadata m = c.code.metadata;
+ // If we are using both alloc and variables, we need to pre-zfill
+ // some memory
+ if ((c.aux.allocUsed || c.aux.calldataUsed) && c.aux.vars.size() > 0) {
+ Node nodelist[] = {
+ token("0", m),
+ token(unsignedToDecimal(c.aux.nextVarMem - 1)),
+ token("MSTORE8", m)
+ };
+ bottom.push_back(multiToken(nodelist, 3, m));
+ }
+ // The actual code
+ bottom.push_back(c.code);
+ return astnode("_", bottom, m);
+}
+
+//LLL -> code fragment tree
+Node buildFragmentTree(Node node) {
+ return finalize(opcodeify(node));
+}
+
+
+// Builds a dictionary mapping labels to variable names
+programAux buildDict(Node program, programAux aux, int labelLength) {
+ Metadata m = program.metadata;
+ // Token
+ if (program.type == TOKEN) {
+ if (isNumberLike(program)) {
+ aux.step += 1 + toByteArr(program.val, m).size();
+ }
+ else if (program.val[0] == '~') {
+ aux.vars[program.val.substr(1)] = unsignedToDecimal(aux.step);
+ }
+ else if (program.val[0] == '$') {
+ aux.step += labelLength + 1;
+ }
+ else aux.step += 1;
+ }
+ // A sub-program (ie. LLL)
+ else if (program.val == "____CODE") {
+ programAux auks = Aux();
+ for (unsigned i = 0; i < program.args.size(); i++) {
+ auks = buildDict(program.args[i], auks, labelLength);
+ }
+ for (std::map<std::string,std::string>::iterator it=auks.vars.begin();
+ it != auks.vars.end();
+ it++) {
+ aux.vars[(*it).first] = (*it).second;
+ }
+ aux.step += auks.step;
+ }
+ // Normal sub-block
+ else {
+ for (unsigned i = 0; i < program.args.size(); i++) {
+ aux = buildDict(program.args[i], aux, labelLength);
+ }
+ }
+ return aux;
+}
+
+// Applies that dictionary
+Node substDict(Node program, programAux aux, int labelLength) {
+ Metadata m = program.metadata;
+ std::vector<Node> out;
+ std::vector<Node> inner;
+ if (program.type == TOKEN) {
+ if (program.val[0] == '$') {
+ std::string tokStr = "PUSH"+unsignedToDecimal(labelLength);
+ out.push_back(token(tokStr, m));
+ int dotLoc = program.val.find('.');
+ if (dotLoc == -1) {
+ std::string val = aux.vars[program.val.substr(1)];
+ inner = toByteArr(val, m, labelLength);
+ }
+ else {
+ std::string start = aux.vars[program.val.substr(1, dotLoc-1)],
+ end = aux.vars[program.val.substr(dotLoc + 1)],
+ dist = decimalSub(end, start);
+ inner = toByteArr(dist, m, labelLength);
+ }
+ out.push_back(astnode("_", inner, m));
+ }
+ else if (program.val[0] == '~') { }
+ else if (isNumberLike(program)) {
+ inner = toByteArr(program.val, m);
+ out.push_back(token("PUSH"+unsignedToDecimal(inner.size())));
+ out.push_back(astnode("_", inner, m));
+ }
+ else return program;
+ }
+ else {
+ for (unsigned i = 0; i < program.args.size(); i++) {
+ Node n = substDict(program.args[i], aux, labelLength);
+ if (n.type == TOKEN || n.args.size()) out.push_back(n);
+ }
+ }
+ return astnode("_", out, m);
+}
+
+// Compiled fragtree -> compiled fragtree without labels
+Node dereference(Node program) {
+ int sz = treeSize(program) * 4;
+ int labelLength = 1;
+ while (sz >= 256) { labelLength += 1; sz /= 256; }
+ programAux aux = buildDict(program, Aux(), labelLength);
+ return substDict(program, aux, labelLength);
+}
+
+// Dereferenced fragtree -> opcodes
+std::vector<Node> flatten(Node derefed) {
+ std::vector<Node> o;
+ if (derefed.type == TOKEN) {
+ o.push_back(derefed);
+ }
+ else {
+ for (unsigned i = 0; i < derefed.args.size(); i++) {
+ std::vector<Node> oprime = flatten(derefed.args[i]);
+ for (unsigned j = 0; j < oprime.size(); j++) o.push_back(oprime[j]);
+ }
+ }
+ return o;
+}
+
+// Opcodes -> bin
+std::string serialize(std::vector<Node> codons) {
+ std::string o;
+ for (unsigned i = 0; i < codons.size(); i++) {
+ int v;
+ if (isNumberLike(codons[i])) {
+ v = decimalToUnsigned(codons[i].val);
+ }
+ else if (codons[i].val.substr(0,4) == "PUSH") {
+ v = 95 + decimalToUnsigned(codons[i].val.substr(4));
+ }
+ else {
+ v = opcode(codons[i].val);
+ }
+ o += (char)v;
+ }
+ return o;
+}
+
+// Bin -> opcodes
+std::vector<Node> deserialize(std::string ser) {
+ std::vector<Node> o;
+ int backCount = 0;
+ for (unsigned i = 0; i < ser.length(); i++) {
+ unsigned char v = (unsigned char)ser[i];
+ std::string oper = op((int)v);
+ if (oper != "" && backCount <= 0) o.push_back(token(oper));
+ else if (v >= 96 && v < 128 && backCount <= 0) {
+ o.push_back(token("PUSH"+unsignedToDecimal(v - 95)));
+ }
+ else o.push_back(token(unsignedToDecimal(v)));
+ if (v >= 96 && v < 128 && backCount <= 0) {
+ backCount = v - 95;
+ }
+ else backCount--;
+ }
+ return o;
+}
+
+// Fragtree -> bin
+std::string assemble(Node fragTree) {
+ return serialize(flatten(dereference(fragTree)));
+}
+
+// Fragtree -> tokens
+std::vector<Node> prettyAssemble(Node fragTree) {
+ return flatten(dereference(fragTree));
+}
+
+// LLL -> bin
+std::string compileLLL(Node program) {
+ return assemble(buildFragmentTree(program));
+}
+
+// LLL -> tokens
+std::vector<Node> prettyCompileLLL(Node program) {
+ return prettyAssemble(buildFragmentTree(program));
+}
+
+// Converts a list of integer values to binary transaction data
+std::string encodeDatalist(std::vector<std::string> vals) {
+ std::string o;
+ for (unsigned i = 0; i < vals.size(); i++) {
+ std::vector<Node> n = toByteArr(strToNumeric(vals[i]), Metadata(), 32);
+ for (unsigned j = 0; j < n.size(); j++) {
+ int v = decimalToUnsigned(n[j].val);
+ o += (char)v;
+ }
+ }
+ return o;
+}
+
+// Converts binary transaction data into a list of integer values
+std::vector<std::string> decodeDatalist(std::string ser) {
+ std::vector<std::string> out;
+ for (unsigned i = 0; i < ser.length(); i+= 32) {
+ std::string o = "0";
+ for (unsigned j = i; j < i + 32; j++) {
+ int vj = (int)(unsigned char)ser[j];
+ o = decimalAdd(decimalMul(o, "256"), unsignedToDecimal(vj));
+ }
+ out.push_back(o);
+ }
+ return out;
+}
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/compiler.h b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/compiler.h
new file mode 100644
index 000000000..aecaa3718
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/compiler.h
@@ -0,0 +1,43 @@
+#ifndef ETHSERP_COMPILER
+#define ETHSERP_COMPILER
+
+#include <stdio.h>
+#include <iostream>
+#include <vector>
+#include <map>
+#include "util.h"
+
+// Compiled fragtree -> compiled fragtree without labels
+Node dereference(Node program);
+
+// LLL -> fragtree
+Node buildFragmentTree(Node program);
+
+// Dereferenced fragtree -> opcodes
+std::vector<Node> flatten(Node derefed);
+
+// opcodes -> bin
+std::string serialize(std::vector<Node> codons);
+
+// Fragtree -> bin
+std::string assemble(Node fragTree);
+
+// Fragtree -> opcodes
+std::vector<Node> prettyAssemble(Node fragTree);
+
+// LLL -> bin
+std::string compileLLL(Node program);
+
+// LLL -> opcodes
+std::vector<Node> prettyCompileLLL(Node program);
+
+// bin -> opcodes
+std::vector<Node> deserialize(std::string ser);
+
+// Converts a list of integer values to binary transaction data
+std::string encodeDatalist(std::vector<std::string> vals);
+
+// Converts binary transaction data into a list of integer values
+std::vector<std::string> decodeDatalist(std::string ser);
+
+#endif
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/example.cpp b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/example.cpp
new file mode 100644
index 000000000..1ce2590d0
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/example.cpp
@@ -0,0 +1,11 @@
+#include <libserpent/funcs.h>
+#include <libserpent/bignum.h>
+#include <iostream>
+
+using namespace std;
+
+int main() {
+ cout << printAST(compileToLLL(get_file_contents("examples/namecoin.se"))) << "\n";
+ cout << decimalSub("10234", "10234") << "\n";
+ cout << decimalSub("10234", "10233") << "\n";
+}
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/collatz.se b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/collatz.se
new file mode 100644
index 000000000..148b47b59
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/collatz.se
@@ -0,0 +1,11 @@
+x = msg.data[0]
+steps = 0
+
+while x > 1:
+ steps += 1
+ if (x % 2) == 0:
+ x /= 2
+ else:
+ x = 3 * x + 1
+
+return(steps)
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/counterparty/counterparty.se b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/counterparty/counterparty.se
new file mode 100644
index 000000000..abec0d102
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/counterparty/counterparty.se
@@ -0,0 +1,274 @@
+# Ethereum forks Counterparty in 340 lines of serpent
+# Not yet tested
+
+# assets[i] = a registered asset, assets[i].holders[j] = former or current i-holder
+data assets[2^50](creator, name, calldate, callprice, dividend_paid, holders[2^50], holdersCount)
+data nextAssetId
+
+# holdersMap: holdersMap[addr][asset] = 1 if addr holds asset
+data holdersMap[2^160][2^50]
+
+# balances[x][y] = how much of y x holds
+data balances[2^160][2^50]
+
+# orders[a][b] = heap of indices to (c, d, e)
+# = c offers to sell d units of a at a price of e units of b per 10^18 units
+# of a
+data orderbooks[2^50][2^50]
+
+# store of general order data
+data orders[2^50](seller, asset_sold, quantity, price)
+data ordersCount
+
+# data feeds
+data feeds[2^50](owner, value)
+data feedCount
+
+# heap
+data heap
+extern heap: [register, push, pop, top, size]
+
+data cfds[2^50](maker, acceptor, feed, asset, strike, leverage, min, max, maturity)
+data cfdCount
+
+data bets[2^50](maker, acceptor, feed, asset, makerstake, acceptorstake, eqtest, maturity)
+data betCount
+
+def init():
+ heap = create('heap.se')
+
+# Add units (internal method)
+def add(to, asset, value):
+ assert msg.sender == self
+ self.balances[to][asset] += value
+ # Add the holder to the holders list
+ if not self.holdersMap[to][asset]:
+ self.holdersMap[to][asset] = 1
+ c = self.assets[asset].holdersCount
+ self.assets[asset].holders[c] = to
+ self.assets[asset].holdersCount = c + 1
+
+# Register a new asset
+def register_asset(q, name, calldate, callprice):
+ newid = self.nextAssetId
+ self.assets[newid].creator = msg.sender
+ self.assets[newid].name = name
+ self.assets[newid].calldate = calldate
+ self.assets[newid].callprice = callprice
+ self.assets[newid].holders[0] = msg.sender
+ self.assets[newid].holdersCount = 1
+ self.balances[msg.sender][newid] = q
+ self.holdersMap[msg.sender][newid] = 1
+
+# Send
+def send(to, asset, value):
+ fromval = self.balances[msg.sender][asset]
+ if fromval >= value:
+ self.balances[msg.sender][asset] -= value
+ self.add(to, asset, value)
+
+# Order
+def mkorder(selling, buying, quantity, price):
+ # Make sure you have enough to pay for the order
+ assert self.balances[msg.sender][selling] >= quantity:
+ # Try to match existing orders
+ o = orderbooks[buying][selling]
+ if not o:
+ o = self.heap.register()
+ orderbooks[selling][buying] = o
+ sz = self.heap.size(o)
+ invprice = 10^36 / price
+ while quantity > 0 and sz > 0:
+ orderid = self.heap.pop()
+ p = self.orders[orderid].price
+ if p > invprice:
+ sz = 0
+ else:
+ q = self.orders[orderid].quantity
+ oq = min(q, quantity)
+ b = self.orders[orderid].seller
+ self.balances[msg.sender][selling] -= oq * p / 10^18
+ self.add(msg.sender, buying, oq)
+ self.add(b, selling, oq * p / 10^18)
+ self.orders[orderid].quantity = q - oq
+ if oq == q:
+ self.orders[orderid].seller = 0
+ self.orders[orderid].price = 0
+ self.orders[orderid].asset_sold = 0
+ quantity -= oq
+ sz -= 1
+ assert quantity > 0
+ # Make the order
+ c = self.ordersCount
+ self.orders[c].seller = msg.sender
+ self.orders[c].asset_sold = selling
+ self.orders[c].quantity = quantity
+ self.orders[c].price = price
+ self.ordersCount += 1
+ # Add it to the heap
+ o = orderbooks[selling][buying]
+ if not o:
+ o = self.heap.register()
+ orderbooks[selling][buying] = o
+ self.balances[msg.sender][selling] -= quantity
+ self.heap.push(o, price, c)
+ return(c)
+
+def cancel_order(id):
+ if self.orders[id].seller == msg.sender:
+ self.orders[id].seller = 0
+ self.orders[id].price = 0
+ self.balances[msg.sender][self.orders[id].asset_sold] += self.orders[id].quantity
+ self.orders[id].quantity = 0
+ self.orders[id].asset_sold = 0
+
+def register_feed():
+ c = self.feedCount
+ self.feeds[c].owner = msg.sender
+ self.feedCount = c + 1
+ return(c)
+
+def set_feed(id, v):
+ if self.feeds[id].owner == msg.sender:
+ self.feeds[id].value = v
+
+def mk_cfd_offer(feed, asset, strike, leverage, min, max, maturity):
+ b = self.balances[msg.sender][asset]
+ req = max((strike - min) * leverage, (strike - max) * leverage)
+ assert b >= req
+ self.balances[msg.sender][asset] = b - req
+ c = self.cfdCount
+ self.cfds[c].maker = msg.sender
+ self.cfds[c].feed = feed
+ self.cfds[c].asset = asset
+ self.cfds[c].strike = strike
+ self.cfds[c].leverage = leverage
+ self.cfds[c].min = min
+ self.cfds[c].max = max
+ self.cfds[c].maturity = maturity
+ self.cfdCount = c + 1
+ return(c)
+
+def accept_cfd_offer(c):
+ assert not self.cfds[c].acceptor and self.cfds[c].maker
+ asset = self.cfds[c].asset
+ strike = self.cfds[c].strike
+ min = self.cfds[c].min
+ max = self.cfds[c].max
+ leverage = self.cfds[c].leverage
+ b = self.balances[msg.sender][asset]
+ req = max((min - strike) * leverage, (max - strike) * leverage)
+ assert b >= req
+ self.balances[msg.sender][asset] = b - req
+ self.cfds[c].acceptor = msg.sender
+ self.cfds[c].maturity += block.timestamp
+
+def claim_cfd_offer(c):
+ asset = self.cfds[c].asset
+ strike = self.cfds[c].strike
+ min = self.cfds[c].min
+ max = self.cfds[c].max
+ leverage = self.cfds[c].leverage
+ v = self.feeds[self.cfds[c].feed].value
+ assert v <= min or v >= max or block.timestamp >= self.cfds[c].maturity
+ maker_req = max((strike - min) * leverage, (strike - max) * leverage)
+ acceptor_req = max((min - strike) * leverage, (max - strike) * leverage)
+ paydelta = (strike - v) * leverage
+ self.add(self.cfds[c].maker, asset, maker_req + paydelta)
+ self.add(self.cfds[c].acceptor, asset, acceptor_req - paydelta)
+ self.cfds[c].maker = 0
+ self.cfds[c].acceptor = 0
+ self.cfds[c].feed = 0
+ self.cfds[c].asset = 0
+ self.cfds[c].strike = 0
+ self.cfds[c].leverage = 0
+ self.cfds[c].min = 0
+ self.cfds[c].max = 0
+ self.cfds[c].maturity = 0
+
+def withdraw_cfd_offer(c):
+ if self.cfds[c].maker == msg.sender and not self.cfds[c].acceptor:
+ asset = self.cfds[c].asset
+ strike = self.cfds[c].strike
+ min = self.cfds[c].min
+ max = self.cfds[c].max
+ leverage = self.cfds[c].leverage
+ maker_req = max((strike - min) * leverage, (strike - max) * leverage)
+ self.balances[self.cfds[c].maker][asset] += maker_req
+ self.cfds[c].maker = 0
+ self.cfds[c].acceptor = 0
+ self.cfds[c].feed = 0
+ self.cfds[c].asset = 0
+ self.cfds[c].strike = 0
+ self.cfds[c].leverage = 0
+ self.cfds[c].min = 0
+ self.cfds[c].max = 0
+ self.cfds[c].maturity = 0
+
+
+def mk_bet_offer(feed, asset, makerstake, acceptorstake, eqtest, maturity):
+ assert self.balances[msg.sender][asset] >= makerstake
+ c = self.betCount
+ self.bets[c].maker = msg.sender
+ self.bets[c].feed = feed
+ self.bets[c].asset = asset
+ self.bets[c].makerstake = makerstake
+ self.bets[c].acceptorstake = acceptorstake
+ self.bets[c].eqtest = eqtest
+ self.bets[c].maturity = maturity
+ self.balances[msg.sender][asset] -= makerstake
+ self.betCount = c + 1
+ return(c)
+
+def accept_bet_offer(c):
+ assert self.bets[c].maker and not self.bets[c].acceptor
+ asset = self.bets[c].asset
+ acceptorstake = self.bets[c].acceptorstake
+ assert self.balances[msg.sender][asset] >= acceptorstake
+ self.balances[msg.sender][asset] -= acceptorstake
+ self.bets[c].acceptor = msg.sender
+
+def claim_bet_offer(c):
+ assert block.timestamp >= self.bets[c].maturity
+ v = self.feeds[self.bets[c].feed].value
+ totalstake = self.bets[c].makerstake + self.bets[c].acceptorstake
+ if v == self.bets[c].eqtest:
+ self.add(self.bets[c].maker, self.bets[c].asset, totalstake)
+ else:
+ self.add(self.bets[c].acceptor, self.bets[c].asset, totalstake)
+ self.bets[c].maker = 0
+ self.bets[c].feed = 0
+ self.bets[c].asset = 0
+ self.bets[c].makerstake = 0
+ self.bets[c].acceptorstake = 0
+ self.bets[c].eqtest = 0
+ self.bets[c].maturity = 0
+
+def cancel_bet(c):
+ assert not self.bets[c].acceptor and msg.sender == self.bets[c].maker
+ self.balances[msg.sender][self.bets[c].asset] += self.bets[c].makerstake
+ self.bets[c].maker = 0
+ self.bets[c].feed = 0
+ self.bets[c].asset = 0
+ self.bets[c].makerstake = 0
+ self.bets[c].acceptorstake = 0
+ self.bets[c].eqtest = 0
+ self.bets[c].maturity = 0
+
+def dividend(holder_asset, divvying_asset, ratio):
+ i = 0
+ sz = self.assets[holder_asset].holdersCount
+ t = 0
+ holders = array(sz)
+ payments = array(sz)
+ while i < sz:
+ holders[i] = self.assets[holder_asset].holders[i]
+ payments[i] = self.balances[holders[i]][holder_asset] * ratio / 10^18
+ t += payments[i]
+ i += 1
+ if self.balances[msg.sender][divvying_asset] >= t:
+ i = 0
+ while i < sz:
+ self.add(holders[i], divvying_asset, payments[i])
+ i += 1
+ self.balances[msg.sender][divvying_asset] -= t
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/counterparty/heap.se b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/counterparty/heap.se
new file mode 100644
index 000000000..4a43a3974
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/counterparty/heap.se
@@ -0,0 +1,69 @@
+data heaps[2^50](owner, size, nodes[2^50](key, value))
+data heapIndex
+
+def register():
+ i = self.heapIndex
+ self.heaps[i].owner = msg.sender
+ self.heapIndex = i + 1
+ return(i)
+
+def push(heap, key, value):
+ assert msg.sender == self.heaps[heap].owner
+ sz = self.heaps[heap].size
+ self.heaps[heap].nodes[sz].key = key
+ self.heaps[heap].nodes[sz].value = value
+ k = sz + 1
+ while k > 1:
+ bottom = self.heaps[heap].nodes[k].key
+ top = self.heaps[heap].nodes[k/2].key
+ if bottom < top:
+ tvalue = self.heaps[heap].nodes[k/2].value
+ bvalue = self.heaps[heap].nodes[k].value
+ self.heaps[heap].nodes[k].key = top
+ self.heaps[heap].nodes[k].value = tvalue
+ self.heaps[heap].nodes[k/2].key = bottom
+ self.heaps[heap].nodes[k/2].value = bvalue
+ k /= 2
+ else:
+ k = 0
+ self.heaps[heap].size = sz + 1
+
+def pop(heap):
+ sz = self.heaps[heap].size
+ assert sz
+ prevtop = self.heaps[heap].nodes[1].value
+ self.heaps[heap].nodes[1].key = self.heaps[heap].nodes[sz].key
+ self.heaps[heap].nodes[1].value = self.heaps[heap].nodes[sz].value
+ self.heaps[heap].nodes[sz].key = 0
+ self.heaps[heap].nodes[sz].value = 0
+ top = self.heaps[heap].nodes[1].key
+ k = 1
+ while k * 2 < sz:
+ bottom1 = self.heaps[heap].nodes[k * 2].key
+ bottom2 = self.heaps[heap].nodes[k * 2 + 1].key
+ if bottom1 < top and (bottom1 < bottom2 or k * 2 + 1 >= sz):
+ tvalue = self.heaps[heap].nodes[1].value
+ bvalue = self.heaps[heap].nodes[k * 2].value
+ self.heaps[heap].nodes[k].key = bottom1
+ self.heaps[heap].nodes[k].value = bvalue
+ self.heaps[heap].nodes[k * 2].key = top
+ self.heaps[heap].nodes[k * 2].value = tvalue
+ k = k * 2
+ elif bottom2 < top and bottom2 < bottom1 and k * 2 + 1 < sz:
+ tvalue = self.heaps[heap].nodes[1].value
+ bvalue = self.heaps[heap].nodes[k * 2 + 1].value
+ self.heaps[heap].nodes[k].key = bottom2
+ self.heaps[heap].nodes[k].value = bvalue
+ self.heaps[heap].nodes[k * 2 + 1].key = top
+ self.heaps[heap].nodes[k * 2 + 1].value = tvalue
+ k = k * 2 + 1
+ else:
+ k = sz
+ self.heaps[heap].size = sz - 1
+ return(prevtop)
+
+def top(heap):
+ return(self.heaps[heap].nodes[1].value)
+
+def size(heap):
+ return(self.heaps[heap].size)
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/crowdfund.se b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/crowdfund.se
new file mode 100644
index 000000000..9fd1e0643
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/crowdfund.se
@@ -0,0 +1,53 @@
+data campaigns[2^80](recipient, goal, deadline, contrib_total, contrib_count, contribs[2^50](sender, value))
+
+def create_campaign(id, recipient, goal, timelimit):
+ if self.campaigns[id].recipient:
+ return(0)
+ self.campaigns[id].recipient = recipient
+ self.campaigns[id].goal = goal
+ self.campaigns[id].deadline = block.timestamp + timelimit
+
+def contribute(id):
+ # Update contribution total
+ total_contributed = self.campaigns[id].contrib_total + msg.value
+ self.campaigns[id].contrib_total = total_contributed
+
+ # Record new contribution
+ sub_index = self.campaigns[id].contrib_count
+ self.campaigns[id].contribs[sub_index].sender = msg.sender
+ self.campaigns[id].contribs[sub_index].value = msg.value
+ self.campaigns[id].contrib_count = sub_index + 1
+
+ # Enough funding?
+ if total_contributed >= self.campaigns[id].goal:
+ send(self.campaigns[id].recipient, total_contributed)
+ self.clear(id)
+ return(1)
+
+ # Expired?
+ if block.timestamp > self.campaigns[id].deadline:
+ i = 0
+ c = self.campaigns[id].contrib_count
+ while i < c:
+ send(self.campaigns[id].contribs[i].sender, self.campaigns[id].contribs[i].value)
+ i += 1
+ self.clear(id)
+ return(2)
+
+def progress_report(id):
+ return(self.campaigns[id].contrib_total)
+
+# Clearing function for internal use
+def clear(id):
+ if self == msg.sender:
+ self.campaigns[id].recipient = 0
+ self.campaigns[id].goal = 0
+ self.campaigns[id].deadline = 0
+ c = self.campaigns[id].contrib_count
+ self.campaigns[id].contrib_count = 0
+ self.campaigns[id].contrib_total = 0
+ i = 0
+ while i < c:
+ self.campaigns[id].contribs[i].sender = 0
+ self.campaigns[id].contribs[i].value = 0
+ i += 1
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/cyberdyne/futarchy.se b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/cyberdyne/futarchy.se
new file mode 100644
index 000000000..0d68622ac
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/cyberdyne/futarchy.se
@@ -0,0 +1,136 @@
+# 0: current epoch
+# 1: number of proposals
+# 2: master currency
+# 3: last winning market
+# 4: last txid
+# 5: long-term ema currency units purchased
+# 6: last block when currency units purchased
+# 7: ether allocated to last round
+# 8: last block when currency units claimed
+# 9: ether allocated to current round
+# 1000+: [proposal address, market ID, totprice, totvolume]
+
+init:
+ # We technically have two levels of epoch here. We have
+ # one epoch of 1000, to synchronize with the 1000 epoch
+ # of the market, and then 100 of those epochs make a
+ # meta-epoch (I'll nominate the term "seculum") over
+ # which the futarchy protocol will take place
+ contract.storage[0] = block.number / 1000
+ # The master currency of the futarchy. The futarchy will
+ # assign currency units to whoever the prediction market
+ # thinks will best increase the currency's value
+ master_currency = create('subcurrency.se')
+ contract.storage[2] = master_currency
+code:
+ curepoch = block.number / 1000
+ prevepoch = contract.storage[0]
+ if curepoch > prevepoch:
+ if (curepoch % 100) > 50:
+ # Collect price data
+ # We take an average over 50 subepochs to determine
+ # the price of each asset, weighting by volume to
+ # prevent abuse
+ contract.storage[0] = curepoch
+ i = 0
+ numprop = contract.storage[1]
+ while i < numprop:
+ market = contract.storage[1001 + i * 4]
+ price = call(market, 2)
+ volume = call(market, 3)
+ contract.storage[1002 + i * 4] += price
+ contract.storage[1003 + i * 4] += volume * price
+ i += 1
+ if (curepoch / 100) > (prevepoch / 100):
+ # If we are entering a new seculum, we determine the
+ # market with the highest total average price
+ best = 0
+ bestmarket = 0
+ besti = 0
+ i = 0
+ while i < numprop:
+ curtotprice = contract.storage[1002 + i * 4]
+ curvolume = contract.storage[1002 + i * 4]
+ curavgprice = curtotprice / curvolume
+ if curavgprice > best:
+ best = curavgprice
+ besti = i
+ bestmarket = contract.storage[1003 + i * 4]
+ i += 1
+ # Reset the number of proposals to 0
+ contract.storage[1] = 0
+ # Reward the highest proposal
+ call(contract.storage[2], [best, 10^9, 0], 3)
+ # Record the winning market so we can later appropriately
+ # compensate the participants
+ contract.storage[2] = bestmarket
+ # The amount of ether allocated to the last round
+ contract.storage[7] = contract.storage[9]
+ # The amount of ether allocated to the next round
+ contract.storage[9] = contract.balance / 2
+ # Make a proposal [0, address]
+ if msg.data[0] == 0 and curepoch % 100 < 50:
+ pid = contract.storage[1]
+ market = create('market.se')
+ c1 = create('subcurrency.se')
+ c2 = create('subcurrency.se')
+ call(market, [c1, c2], 2)
+ contract.storage[1000 + pid * 4] = msg.data[1]
+ contract.storage[1001 + pid * 4] = market
+ contract.storage[1] += 1
+ # Claim ether [1, address]
+ # One unit of the first currency in the last round's winning
+ # market entitles you to a quantity of ether that was decided
+ # at the start of that epoch
+ elif msg.data[0] == 1:
+ first_subcurrency = call(contract.storage[2], 3)
+ # We ask the first subcurrency contract what the last transaction was. The
+ # way to make a claim is to send the amount of first currency units that
+ # you wish to claim with, and then immediately call this contract. For security
+ # it makes sense to set up a tx which sends both messages in sequence atomically
+ data = call(first_subcurrency, [], 0, 4)
+ from = data[0]
+ to = data[1]
+ value = data[2]
+ txid = data[3]
+ if txid > contract.storage[4] and to == contract.address:
+ send(to, contract.storage[7] * value / 10^9)
+ contract.storage[4] = txid
+ # Claim second currency [2, address]
+ # One unit of the second currency in the last round's winning
+ # market entitles you to one unit of the futarchy's master
+ # currency
+ elif msg.data[0] == 2:
+ second_subcurrency = call(contract.storage[2], 3)
+ data = call(first_subcurrency, [], 0, 4)
+ from = data[0]
+ to = data[1]
+ value = data[2]
+ txid = data[3]
+ if txid > contract.storage[4] and to == contract.address:
+ call(contract.storage[2], [to, value], 2)
+ contract.storage[4] = txid
+ # Purchase currency for ether (target releasing 10^9 units per seculum)
+ # Price starts off 1 eth for 10^9 units but increases hyperbolically to
+ # limit issuance
+ elif msg.data[0] == 3:
+ pre_ema = contract.storage[5]
+ post_ema = pre_ema + msg.value
+ pre_reserve = 10^18 / (10^9 + pre_ema / 10^9)
+ post_reserve = 10^18 / (10^9 + post_ema / 10^9)
+ call(contract.storage[2], [msg.sender, pre_reserve - post_reserve], 2)
+ last_sold = contract.storage[6]
+ contract.storage[5] = pre_ema * (100000 + last_sold - block.number) + msg.value
+ contract.storage[6] = block.number
+ # Claim all currencies as the ether miner of the current block
+ elif msg.data[0] == 2 and msg.sender == block.coinbase and block.number > contract.storage[8]:
+ i = 0
+ numproposals = contract.storage[1]
+ while i < numproposals:
+ market = contract.storage[1001 + i * 3]
+ fc = call(market, 4)
+ sc = call(market, 5)
+ call(fc, [msg.sender, 1000], 2)
+ call(sc, [msg.sender, 1000], 2)
+ i += 1
+ contract.storage[8] = block.number
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/cyberdyne/heap.se b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/cyberdyne/heap.se
new file mode 100644
index 000000000..1bc442e6d
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/cyberdyne/heap.se
@@ -0,0 +1,55 @@
+# 0: size
+# 1-n: elements
+
+init:
+ contract.storage[1000] = msg.sender
+code:
+ # Only owner of the heap is allowed to modify it
+ if contract.storage[1000] != msg.sender:
+ stop
+ # push
+ if msg.data[0] == 0:
+ sz = contract.storage[0]
+ contract.storage[sz + 1] = msg.data[1]
+ k = sz + 1
+ while k > 1:
+ bottom = contract.storage[k]
+ top = contract.storage[k/2]
+ if bottom < top:
+ contract.storage[k] = top
+ contract.storage[k/2] = bottom
+ k /= 2
+ else:
+ k = 0
+ contract.storage[0] = sz + 1
+ # pop
+ elif msg.data[0] == 1:
+ sz = contract.storage[0]
+ if !sz:
+ return(0)
+ prevtop = contract.storage[1]
+ contract.storage[1] = contract.storage[sz]
+ contract.storage[sz] = 0
+ top = contract.storage[1]
+ k = 1
+ while k * 2 < sz:
+ bottom1 = contract.storage[k * 2]
+ bottom2 = contract.storage[k * 2 + 1]
+ if bottom1 < top and (bottom1 < bottom2 or k * 2 + 1 >= sz):
+ contract.storage[k] = bottom1
+ contract.storage[k * 2] = top
+ k = k * 2
+ elif bottom2 < top and bottom2 < bottom1 and k * 2 + 1 < sz:
+ contract.storage[k] = bottom2
+ contract.storage[k * 2 + 1] = top
+ k = k * 2 + 1
+ else:
+ k = sz
+ contract.storage[0] = sz - 1
+ return(prevtop)
+ # top
+ elif msg.data[0] == 2:
+ return(contract.storage[1])
+ # size
+ elif msg.data[0] == 3:
+ return(contract.storage[0])
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/cyberdyne/market.se b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/cyberdyne/market.se
new file mode 100644
index 000000000..2303a0b60
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/cyberdyne/market.se
@@ -0,0 +1,117 @@
+# Creates a decentralized market between any two subcurrencies
+
+# Here, the first subcurrency is the base asset and the second
+# subcurrency is the asset priced against the base asset. Hence,
+# "buying" refers to trading the first for the second, and
+# "selling" refers to trading the second for the first
+
+# storage 0: buy orders
+# storage 1: sell orders
+# storage 1000: first subcurrency
+# storage 1001: last first subcurrency txid
+# storage 2000: second subcurrency
+# storage 2001: last second subcurrency txid
+# storage 3000: current epoch
+# storage 4000: price
+# storage 4001: volume
+
+init:
+ # Heap for buy orders
+ contract.storage[0] = create('heap.se')
+ # Heap for sell orders
+ contract.storage[1] = create('heap.se')
+code:
+ # Initialize with [ first_subcurrency, second_subcurrency ]
+ if !contract.storage[1000]:
+ contract.storage[1000] = msg.data[0] # First subcurrency
+ contract.storage[1001] = -1
+ contract.storage[2000] = msg.data[1] # Second subcurrency
+ contract.storage[2001] = -1
+ contract.storage[3000] = block.number / 1000
+ stop
+ first_subcurrency = contract.storage[1000]
+ second_subcurrency = contract.storage[2000]
+ buy_heap = contract.storage[0]
+ sell_heap = contract.storage[1]
+ # This contract operates in "epochs" of 100 blocks
+ # At the end of each epoch, we process all orders
+ # simultaneously, independent of order. This algorithm
+ # prevents front-running, and generates a profit from
+ # the spread. The profit is permanently kept in the
+ # market (ie. destroyed), making both subcurrencies
+ # more valuable
+
+ # Epoch transition code
+ if contract.storage[3000] < block.number / 100:
+ done = 0
+ volume = 0
+ while !done:
+ # Grab the top buy and sell order from each heap
+ topbuy = call(buy_heap, 1)
+ topsell = call(sell_heap, 1)
+ # An order is recorded in the heap as:
+ # Buys: (2^48 - 1 - price) * 2^208 + units of first currency * 2^160 + from
+ # Sells: price * 2^208 + units of second currency * 2^160 + from
+ buyprice = -(topbuy / 2^208)
+ buyfcvalue = (topbuy / 2^160) % 2^48
+ buyer = topbuy % 2^160
+ sellprice = topsell / 2^208
+ sellscvalue = (topsell / 2^160) % 2^48
+ seller = topsell % 2^160
+ # Heap empty, or no more matching orders
+ if not topbuy or not topsell or buyprice < sellprice:
+ done = 1
+ else:
+ # Add to volume counter
+ volume += buyfcvalue
+ # Calculate how much of the second currency the buyer gets, and
+ # how much of the first currency the seller gets
+ sellfcvalue = sellscvalue / buyprice
+ buyscvalue = buyfcvalue * sellprice
+ # Send the currency units along
+ call(second_subcurrency, [buyer, buyscvalue], 2)
+ call(first_subcurrency, [seller, sellfcvalue], 2)
+ if volume:
+ contract.storage[4000] = (buyprice + sellprice) / 2
+ contract.storage[4001] = volume
+ contract.storage[3000] = block.number / 100
+ # Make buy order [0, price]
+ if msg.data[0] == 0:
+ # We ask the first subcurrency contract what the last transaction was. The
+ # way to make a buy order is to send the amount of first currency units that
+ # you wish to buy with, and then immediately call this contract. For security
+ # it makes sense to set up a tx which sends both messages in sequence atomically
+ data = call(first_subcurrency, [], 0, 4)
+ from = data[0]
+ to = data[1]
+ value = data[2]
+ txid = data[3]
+ price = msg.data[1]
+ if txid > contract.storage[1001] and to == contract.address:
+ contract.storage[1001] = txid
+ # Adds the order to the heap
+ call(buy_heap, [0, -price * 2^208 + (value % 2^48) * 2^160 + from], 2)
+ # Make sell order [1, price]
+ elif msg.data[0] == 1:
+ # Same mechanics as buying
+ data = call(second_subcurrency, [], 0, 4)
+ from = data[0]
+ to = data[1]
+ value = data[2]
+ txid = data[3]
+ price = msg.data[1]
+ if txid > contract.storage[2001] and to == contract.address:
+ contract.storage[2001] = txid
+ call(sell_heap, [0, price * 2^208 + (value % 2^48) * 2^160 + from], 2)
+ # Ask for price
+ elif msg.data[0] == 2:
+ return(contract.storage[4000])
+ # Ask for volume
+ elif msg.data[0] == 3:
+ return(contract.storage[1000])
+ # Ask for first currency
+ elif msg.data[0] == 4:
+ return(contract.storage[2000])
+ # Ask for second currency
+ elif msg.data[0] == 5:
+ return(contract.storage[4001])
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/cyberdyne/subcurrency.se b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/cyberdyne/subcurrency.se
new file mode 100644
index 000000000..1501beff7
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/cyberdyne/subcurrency.se
@@ -0,0 +1,35 @@
+# Initialization
+# Admin can issue and delete at will
+init:
+ contract.storage[0] = msg.sender
+code:
+ # If a message with one item is sent, that's a balance query
+ if msg.datasize == 1:
+ addr = msg.data[0]
+ return(contract.storage[addr])
+ # If a message with two items [to, value] are sent, that's a transfer request
+ elif msg.datasize == 2:
+ from = msg.sender
+ fromvalue = contract.storage[from]
+ to = msg.data[0]
+ value = msg.data[1]
+ if fromvalue >= value and value > 0 and to > 4:
+ contract.storage[from] = fromvalue - value
+ contract.storage[to] += value
+ contract.storage[2] = from
+ contract.storage[3] = to
+ contract.storage[4] = value
+ contract.storage[5] += 1
+ return(1)
+ return(0)
+ elif msg.datasize == 3 and msg.sender == contract.storage[0]:
+ # Admin can issue at will by sending a [to, value, 0] message
+ if msg.data[2] == 0:
+ contract.storage[msg.data[0]] += msg.data[1]
+ # Change admin [ newadmin, 0, 1 ]
+ # Set admin to 0 to disable administration
+ elif msg.data[2] == 1:
+ contract.storage[0] = msg.data[0]
+ # Fetch last transaction
+ else:
+ return([contract.storage[2], contract.storage[3], contract.storage[4], contract.storage[5]], 4)
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/cyberdyne/test.py b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/cyberdyne/test.py
new file mode 100644
index 000000000..301a4a845
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/cyberdyne/test.py
@@ -0,0 +1,39 @@
+from __future__ import print_function
+import pyethereum
+t = pyethereum.tester
+s = t.state()
+# Create currencies
+c1 = s.contract('subcurrency.se')
+print("First currency: %s" % c1)
+c2 = s.contract('subcurrency.se')
+print("First currency: %s" % c2)
+# Allocate units
+s.send(t.k0, c1, 0, [t.a0, 1000, 0])
+s.send(t.k0, c1, 0, [t.a1, 1000, 0])
+s.send(t.k0, c2, 0, [t.a2, 1000000, 0])
+s.send(t.k0, c2, 0, [t.a3, 1000000, 0])
+print("Allocated units")
+# Market
+m = s.contract('market.se')
+s.send(t.k0, m, 0, [c1, c2])
+# Place orders
+s.send(t.k0, c1, 0, [m, 1000])
+s.send(t.k0, m, 0, [0, 1200])
+s.send(t.k1, c1, 0, [m, 1000])
+s.send(t.k1, m, 0, [0, 1400])
+s.send(t.k2, c2, 0, [m, 1000000])
+s.send(t.k2, m, 0, [1, 800])
+s.send(t.k3, c2, 0, [m, 1000000])
+s.send(t.k3, m, 0, [1, 600])
+print("Orders placed")
+# Next epoch and ping
+s.mine(100)
+print("Mined 100")
+s.send(t.k0, m, 0, [])
+print("Updating")
+# Check
+assert s.send(t.k0, c2, 0, [t.a0]) == [800000]
+assert s.send(t.k0, c2, 0, [t.a1]) == [600000]
+assert s.send(t.k0, c1, 0, [t.a2]) == [833]
+assert s.send(t.k0, c1, 0, [t.a3]) == [714]
+print("Balance checks passed")
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/datafeed.se b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/datafeed.se
new file mode 100644
index 000000000..4c4a56de8
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/datafeed.se
@@ -0,0 +1,12 @@
+# Database updateable only by the original creator
+data creator
+
+def init():
+ self.creator = msg.sender
+
+def update(k, v):
+ if msg.sender == self.creator:
+ self.storage[k] = v
+
+def query(k):
+ return(self.storage[k])
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/ecc/ecrecover.se b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/ecc/ecrecover.se
new file mode 100644
index 000000000..ce28f58c2
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/ecc/ecrecover.se
@@ -0,0 +1,40 @@
+# So I looked up on Wikipedia what Jacobian form actually is, and noticed that it's
+# actually a rather different and more clever construction than the naive version
+# that I created. It may possible to achieve a further 20-50% savings by applying
+# that version.
+
+extern all: [call]
+
+data JORDANMUL
+data JORDANADD
+data EXP
+
+def init():
+ self.JORDANMUL = create('jacobian_mul.se')
+ self.JORDANADD = create('jacobian_add.se')
+ self.EXP = create('modexp.se')
+
+def call(h, v, r, s):
+ N = -432420386565659656852420866394968145599
+ P = -4294968273
+ h = mod(h, N)
+ r = mod(r, P)
+ s = mod(s, N)
+ Gx = 55066263022277343669578718895168534326250603453777594175500187360389116729240
+ Gy = 32670510020758816978083085130507043184471273380659243275938904335757337482424
+ x = r
+ xcubed = mulmod(mulmod(x, x, P), x, P)
+ beta = self.EXP.call(addmod(xcubed, 7, P), div(P + 1, 4), P)
+
+ # Static-gascost ghetto conditional
+ y_is_positive = mod(v, 2) xor mod(beta, 2)
+ y = beta * y_is_positive + (P - beta) * (1 - y_is_positive)
+
+ GZ = self.JORDANMUL.call(Gx, 1, Gy, 1, N - h, outsz=4)
+ XY = self.JORDANMUL.call(x, 1, y, 1, s, outsz=4)
+ COMB = self.JORDANADD.call(GZ[0], GZ[1], GZ[2], GZ[3], XY[0], XY[1], XY[2], XY[3], 1, outsz=5)
+ COMB[4] = self.EXP.call(r, N - 2, N)
+ Q = self.JORDANMUL.call(data=COMB, datasz=5, outsz=4)
+ ox = mulmod(Q[0], self.EXP.call(Q[1], P - 2, P), P)
+ oy = mulmod(Q[2], self.EXP.call(Q[3], P - 2, P), P)
+ return([ox, oy], 2)
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/ecc/ecrecover_compiled.evm b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/ecc/ecrecover_compiled.evm
new file mode 100644
index 000000000..f575fe70f
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/ecc/ecrecover_compiled.evm
@@ -0,0 +1 @@
+6000607f535961071c80610013593961072f566000605f535961013d8061001359396101505661012b8061000e60003961013956600061023f5360003560001a6000141561012a5760806001602037602051151561002c576060511561002f565b60005b156100695760806080599059016000905260a052600060a051526001602060a05101526000604060a05101526001606060a051015260a051f25b6401000003d160000380608051826003846020516020510909098182600260605109836040516040510909828283098382830984858660026020510983098603866040518509088560405183098686888985604051098a038a85602051090809878689846040510909888960605183098a038a6080518509088960805183096080608059905901600090526101e052866101e051528560206101e05101528260406101e05101528160606101e05101526101e051f250505050505050505050505b5b6000f25b816000f090506000555961040680610168593961056e566000603f535961013d8061001359396101505661012b8061000e60003961013956600061023f5360003560001a6000141561012a5760806001602037602051151561002c576060511561002f565b60005b156100695760806080599059016000905260a052600060a051526001602060a05101526000604060a05101526001606060a051015260a051f25b6401000003d160000380608051826003846020516020510909098182600260605109836040516040510909828283098382830984858660026020510983098603866040518509088560405183098686888985604051098a038a85602051090809878689846040510909888960605183098a038a6080518509088960805183096080608059905901600090526101e052866101e051528560206101e05101528260406101e05101528160606101e05101526101e051f250505050505050505050505b5b6000f25b816000f0905060005561029a8061016860003961040256600061043f5360003560001a60001415610299576101006001602037602051151561002d5760605115610030565b60005b1561007657608059905901600090526101405260a051610140515260c051602061014051015260e051604061014051015261010051606061014051015261014051610120525b60a05115156100885760e0511561008b565b60005b156100d0576080599059016000905261016052602051610160515260405160206101605101526060516040610160510152608051606061016051015261016051610120525b61012051156100e157608061012051f25b6401000003d16000036000818260a0516040510983038360c051602051090814156101b1576000818260e051608051098303836101005160605109081415610175576080608080599059016000905260006101c0601f01536020516101e052604051610200526060516102205260805161024052818160816101c0601f01600060005460195a03f1508090509050f26101b0565b608060805990590160009052610280526000610280515260016020610280510152600060406102805101526001606061028051015261028051f25b5b808160405160c051098283610100516060510984038460805160e05109080981828360c0516020510984038460405160a051090883608051610100510909828283098382830984856020518309860386604051850908856040518309868760a051830988038860c0518509088760c051830988898a60405185098b038b8460205109088909898a836040510989098a8b60605183098c038c6080518509088b60805183096080608059905901600090526103e052866103e051528560206103e05101528260406103e05101528160606103e05101526103e051f2505050505050505050505050505b5b6000f25b816000f090506001556101928061058660003961071856600061013f5360003560001a600014156101915760a0600160203770014551231950b75fc4402da1732fc9bebf60000360a0510660a05260a05115606051156020511502011561007e5760806080599059016000905260c052600060c051526001602060c05101526000604060c05101526001606060c051015260c051f25b610120599059016000905260e052600060e051526000602060e05101526001604060e05101526000606060e05101526001608060e0510152600060a060e0510152600060c060e0510152600060e060e0510152600061010060e051015260e0517f80000000000000000000000000000000000000000000000000000000000000005b6000811115610187578060a0511615610165576080602083016081601f85016000600054614e20f15060205160a083015260405160c083015260605160e0830152608051610100830152608060208301610101601f85016000600154614e20f161017b565b6080602083016081601f85016000600054614e20f15b50600281049050610100565b608060208301f250505b5b6000f25b816000f0905060005559610406806107475939610b4d566000603f535961013d8061001359396101505661012b8061000e60003961013956600061023f5360003560001a6000141561012a5760806001602037602051151561002c576060511561002f565b60005b156100695760806080599059016000905260a052600060a051526001602060a05101526000604060a05101526001606060a051015260a051f25b6401000003d160000380608051826003846020516020510909098182600260605109836040516040510909828283098382830984858660026020510983098603866040518509088560405183098686888985604051098a038a85602051090809878689846040510909888960605183098a038a6080518509088960805183096080608059905901600090526101e052866101e051528560206101e05101528260406101e05101528160606101e05101526101e051f250505050505050505050505b5b6000f25b816000f0905060005561029a8061016860003961040256600061043f5360003560001a60001415610299576101006001602037602051151561002d5760605115610030565b60005b1561007657608059905901600090526101405260a051610140515260c051602061014051015260e051604061014051015261010051606061014051015261014051610120525b60a05115156100885760e0511561008b565b60005b156100d0576080599059016000905261016052602051610160515260405160206101605101526060516040610160510152608051606061016051015261016051610120525b61012051156100e157608061012051f25b6401000003d16000036000818260a0516040510983038360c051602051090814156101b1576000818260e051608051098303836101005160605109081415610175576080608080599059016000905260006101c0601f01536020516101e052604051610200526060516102205260805161024052818160816101c0601f01600060005460195a03f1508090509050f26101b0565b608060805990590160009052610280526000610280515260016020610280510152600060406102805101526001606061028051015261028051f25b5b808160405160c051098283610100516060510984038460805160e05109080981828360c0516020510984038460405160a051090883608051610100510909828283098382830984856020518309860386604051850908856040518309868760a051830988038860c0518509088760c051830988898a60405185098b038b8460205109088909898a836040510989098a8b60605183098c038c6080518509088b60805183096080608059905901600090526103e052866103e051528560206103e05101528260406103e05101528160606103e05101526103e051f2505050505050505050505050505b5b6000f25b816000f09050600155596100d080610b655939610c35566100be8061000e6000396100cc5660003560001a600014156100bd576060600160203760017f80000000000000000000000000000000000000000000000000000000000000005b60008111156100b157606051816040511615156020510a606051848509099150606051600282046040511615156020510a606051848509099150606051600482046040511615156020510a606051848509099150606051600882046040511615156020510a606051848509099150601081049050610038565b8160c052602060c0f250505b5b6000f25b816000f090506002556103d280610c4d60003961101f56600061095f5360003560001a600014156103d1576080600160203770014551231950b75fc4402da1732fc9bebf60000360a0526401000003d160000360c05260a0516020510660205260c0516060510660605260a051608051066080527f79be667ef9dcbbac55a06295ce870b07029bfcdb2dce28d959f2815b16f8179860e0527f483ada7726a3c4655da4fbfc0e1108a8fd17b448a68554199c47d08ffb10d4b8610100526060516101205260c0516101205160c05161012051610120510909610140526000610180601f015360c051600761014051086101a0526004600160c05101046101c05260c0516101e05260206102006061610180601f01600060025460195a03f1506102005161016052600261016051066002604051061861022052610220516001036101605160c05103026102205161016051020161024052608080599059016000905260006102a0601f015360e0516102c05260016102e052610100516103005260016103205260205160a0510361034052818160a16102a0601f01600060005460195a03f150809050905061026052608080599059016000905260006103c0601f0153610120516103e052600161040052610240516104205260016104405260805161046052818160a16103c0601f01600060005460195a03f15080905090506103805260a080599059016000905260006104e0601f015361026051516105005260206102605101516105205260406102605101516105405260606102605101516105605261038051516105805260206103805101516105a05260406103805101516105c05260606103805101516105e05260016106005281816101216104e0601f01600060015460195a03f15080905090506104a0526000610640601f015360605161066052600260a051036106805260a0516106a05260206106c06061610640601f01600060025460195a03f1506106c05160806104a05101526104a05160208103805160018303608080599059016000905260008353818160a185600060005460195a03f150838552809050905090509050905090506106e05260c05160006107e0601f015360206106e051015161080052600260c051036108205260c05161084052602061086060616107e0601f01600060025460195a03f150610860516106e05151096107c05260c05160006108a0601f015360606106e05101516108c052600260c051036108e05260c05161090052602061092060616108a0601f01600060025460195a03f1506109205160406106e05101510961088052604060405990590160009052610940526107c051610940515261088051602061094051015261094051f25b5b6000f2
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/ecc/jacobian_add.se b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/ecc/jacobian_add.se
new file mode 100644
index 000000000..29dc390b2
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/ecc/jacobian_add.se
@@ -0,0 +1,32 @@
+extern all: [call]
+data DOUBLE
+
+def init():
+ self.DOUBLE = create('jacobian_double.se')
+
+def call(axn, axd, ayn, ayd, bxn, bxd, byn, byd):
+ if !axn and !ayn:
+ o = [bxn, bxd, byn, byd]
+ if !bxn and !byn:
+ o = [axn, axd, ayn, ayd]
+ if o:
+ return(o, 4)
+ with P = -4294968273:
+ if addmod(mulmod(axn, bxd, P), P - mulmod(axd, bxn, P), P) == 0:
+ if addmod(mulmod(ayn, byd, P), P - mulmod(ayd, byn, P), P) == 0:
+ return(self.DOUBLE.call(axn, axd, ayn, ayd, outsz=4), 4)
+ else:
+ return([0, 1, 0, 1], 4)
+ with mn = mulmod(addmod(mulmod(byn, ayd, P), P - mulmod(ayn, byd, P), P), mulmod(bxd, axd, P), P):
+ with md = mulmod(mulmod(byd, ayd, P), addmod(mulmod(bxn, axd, P), P - mulmod(axn, bxd, P), P), P):
+ with msqn = mulmod(mn, mn, P):
+ with msqd = mulmod(md, md, P):
+ with msqman = addmod(mulmod(msqn, axd, P), P - mulmod(msqd, axn, P), P):
+ with msqmad = mulmod(msqd, axd, P):
+ with xn = addmod(mulmod(msqman, bxd, P), P - mulmod(msqmad, bxn, P), P):
+ with xd = mulmod(msqmad, bxd, P):
+ with mamxn = mulmod(mn, addmod(mulmod(axn, xd, P), P - mulmod(xn, axd, P), P), P):
+ with mamxd = mulmod(md, mulmod(axd, xd, P), P):
+ with yn = addmod(mulmod(mamxn, ayd, P), P - mulmod(mamxd, ayn, P), P):
+ with yd = mulmod(mamxd, ayd, P):
+ return([xn, xd, yn, yd], 4)
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/ecc/jacobian_double.se b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/ecc/jacobian_double.se
new file mode 100644
index 000000000..b7d8221a6
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/ecc/jacobian_double.se
@@ -0,0 +1,16 @@
+def call(axn, axd, ayn, ayd):
+ if !axn and !ayn:
+ return([0, 1, 0, 1], 4)
+ with P = -4294968273:
+ # No need to add (A, 1) because A = 0 for bitcoin
+ with mn = mulmod(mulmod(mulmod(axn, axn, P), 3, P), ayd, P):
+ with md = mulmod(mulmod(axd, axd, P), mulmod(ayn, 2, P), P):
+ with msqn = mulmod(mn, mn, P):
+ with msqd = mulmod(md, md, P):
+ with xn = addmod(mulmod(msqn, axd, P), P - mulmod(msqd, mulmod(axn, 2, P), P), P):
+ with xd = mulmod(msqd, axd, P):
+ with mamxn = mulmod(addmod(mulmod(axn, xd, P), P - mulmod(axd, xn, P), P), mn, P):
+ with mamxd = mulmod(mulmod(axd, xd, P), md, P):
+ with yn = addmod(mulmod(mamxn, ayd, P), P - mulmod(mamxd, ayn, P), P):
+ with yd = mulmod(mamxd, ayd, P):
+ return([xn, xd, yn, yd], 4)
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/ecc/jacobian_mul.se b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/ecc/jacobian_mul.se
new file mode 100644
index 000000000..bf5b96bb4
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/ecc/jacobian_mul.se
@@ -0,0 +1,37 @@
+# Expected gas cost
+#
+# def expect(n, point_at_infinity=False):
+# n = n % (2**256 - 432420386565659656852420866394968145599)
+# if point_at_infinity:
+# return 79
+# if n == 0:
+# return 34479
+# L = int(1 + math.log(n) / math.log(2))
+# H = len([x for x in b.encode(n, 2) if x == '1'])
+# return 34221 + 94 * L + 343 * H
+
+data DOUBLE
+data ADD
+
+def init():
+ self.DOUBLE = create('jacobian_double.se')
+ self.ADD = create('jacobian_add.se')
+
+def call(axn, axd, ayn, ayd, n):
+ n = mod(n, -432420386565659656852420866394968145599)
+ if !axn * !ayn + !n: # Constant-gas version of !axn and !ayn or !n
+ return([0, 1, 0, 1], 4)
+ with o = [0, 0, 1, 0, 1, 0, 0, 0, 0]:
+ with b = 2 ^ 255:
+ while gt(b, 0):
+ if n & b:
+ ~call(20000, self.DOUBLE, 0, o + 31, 129, o + 32, 128)
+ o[5] = axn
+ o[6] = axd
+ o[7] = ayn
+ o[8] = ayd
+ ~call(20000, self.ADD, 0, o + 31, 257, o + 32, 128)
+ else:
+ ~call(20000, self.DOUBLE, 0, o + 31, 129, o + 32, 128)
+ b = div(b, 2)
+ return(o + 32, 4)
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/ecc/modexp.se b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/ecc/modexp.se
new file mode 100644
index 000000000..687b12a04
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/ecc/modexp.se
@@ -0,0 +1,11 @@
+def call(b, e, m):
+ with o = 1:
+ with bit = 2 ^ 255:
+ while gt(bit, 0):
+ # A touch of loop unrolling for 20% efficiency gain
+ o = mulmod(mulmod(o, o, m), b ^ !(!(e & bit)), m)
+ o = mulmod(mulmod(o, o, m), b ^ !(!(e & div(bit, 2))), m)
+ o = mulmod(mulmod(o, o, m), b ^ !(!(e & div(bit, 4))), m)
+ o = mulmod(mulmod(o, o, m), b ^ !(!(e & div(bit, 8))), m)
+ bit = div(bit, 16)
+ return(o)
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/ecc/substitutes.py b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/ecc/substitutes.py
new file mode 100644
index 000000000..0007da0cf
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/ecc/substitutes.py
@@ -0,0 +1,78 @@
+import bitcoin as b
+import math
+import sys
+
+
+def signed(o):
+ return map(lambda x: x - 2**256 if x >= 2**255 else x, o)
+
+
+def hamming_weight(n):
+ return len([x for x in b.encode(n, 2) if x == '1'])
+
+
+def binary_length(n):
+ return len(b.encode(n, 2))
+
+
+def jacobian_mul_substitute(A, B, C, D, N):
+ if A == 0 and C == 0 or (N % b.N) == 0:
+ return {"gas": 86, "output": [0, 1, 0, 1]}
+ else:
+ output = b.jordan_multiply(((A, B), (C, D)), N)
+ return {
+ "gas": 35262 + 95 * binary_length(N % b.N) + 355 * hamming_weight(N % b.N),
+ "output": signed(list(output[0]) + list(output[1]))
+ }
+
+
+def jacobian_add_substitute(A, B, C, D, E, F, G, H):
+ if A == 0 or E == 0:
+ gas = 149
+ elif (A * F - B * E) % b.P == 0:
+ if (C * H - D * G) % b.P == 0:
+ gas = 442
+ else:
+ gas = 177
+ else:
+ gas = 301
+ output = b.jordan_add(((A, B), (C, D)), ((E, F), (G, H)))
+ return {
+ "gas": gas,
+ "output": signed(list(output[0]) + list(output[1]))
+ }
+
+
+def modexp_substitute(base, exp, mod):
+ return {
+ "gas": 5150,
+ "output": signed([pow(base, exp, mod) if mod > 0 else 0])
+ }
+
+
+def ecrecover_substitute(z, v, r, s):
+ P, A, B, N, Gx, Gy = b.P, b.A, b.B, b.N, b.Gx, b.Gy
+ x = r
+ beta = pow(x*x*x+A*x+B, (P + 1) / 4, P)
+ BETA_PREMIUM = modexp_substitute(x, (P + 1) / 4, P)["gas"]
+ y = beta if v % 2 ^ beta % 2 else (P - beta)
+ Gz = b.jordan_multiply(((Gx, 1), (Gy, 1)), (N - z) % N)
+ GZ_PREMIUM = jacobian_mul_substitute(Gx, 1, Gy, 1, (N - z) % N)["gas"]
+ XY = b.jordan_multiply(((x, 1), (y, 1)), s)
+ XY_PREMIUM = jacobian_mul_substitute(x, 1, y, 1, s % N)["gas"]
+ Qr = b.jordan_add(Gz, XY)
+ QR_PREMIUM = jacobian_add_substitute(Gz[0][0], Gz[0][1], Gz[1][0], Gz[1][1],
+ XY[0][0], XY[0][1], XY[1][0], XY[1][1]
+ )["gas"]
+ Q = b.jordan_multiply(Qr, pow(r, N - 2, N))
+ Q_PREMIUM = jacobian_mul_substitute(Qr[0][0], Qr[0][1], Qr[1][0], Qr[1][1],
+ pow(r, N - 2, N))["gas"]
+ R_PREMIUM = modexp_substitute(r, N - 2, N)["gas"]
+ OX_PREMIUM = modexp_substitute(Q[0][1], P - 2, P)["gas"]
+ OY_PREMIUM = modexp_substitute(Q[1][1], P - 2, P)["gas"]
+ Q = b.from_jordan(Q)
+ return {
+ "gas": 991 + BETA_PREMIUM + GZ_PREMIUM + XY_PREMIUM + QR_PREMIUM +
+ Q_PREMIUM + R_PREMIUM + OX_PREMIUM + OY_PREMIUM,
+ "output": signed(Q)
+ }
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/ecc/test.py b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/ecc/test.py
new file mode 100644
index 000000000..48d21e32f
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/ecc/test.py
@@ -0,0 +1,129 @@
+import bitcoin as b
+import random
+import sys
+import math
+from pyethereum import tester as t
+import substitutes
+import time
+
+vals = [random.randrange(2**256) for i in range(12)]
+
+test_points = [list(p[0]) + list(p[1]) for p in
+ [b.jordan_multiply(((b.Gx, 1), (b.Gy, 1)), r) for r in vals]]
+
+G = [b.Gx, 1, b.Gy, 1]
+Z = [0, 1, 0, 1]
+
+
+def neg_point(p):
+ return [p[0], b.P - p[1], p[2], b.P - p[3]]
+
+s = t.state()
+s.block.gas_limit = 10000000
+t.gas_limit = 1000000
+
+
+c = s.contract('modexp.se')
+print "Starting modexp tests"
+
+for i in range(0, len(vals) - 2, 3):
+ o1 = substitutes.modexp_substitute(vals[i], vals[i+1], vals[i+2])
+ o2 = s.profile(t.k0, c, 0, funid=0, abi=vals[i:i+3])
+ #assert o1["gas"] == o2["gas"], (o1, o2)
+ assert o1["output"] == o2["output"], (o1, o2)
+
+c = s.contract('jacobian_add.se')
+print "Starting addition tests"
+
+for i in range(2):
+ P = test_points[i * 2]
+ Q = test_points[i * 2 + 1]
+ NP = neg_point(P)
+
+ o1 = substitutes.jacobian_add_substitute(*(P + Q))
+ o2 = s.profile(t.k0, c, 0, funid=0, abi=P + Q)
+ #assert o1["gas"] == o2["gas"], (o1, o2)
+ assert o1["output"] == o2["output"], (o1, o2)
+
+ o1 = substitutes.jacobian_add_substitute(*(P + NP))
+ o2 = s.profile(t.k0, c, 0, funid=0, abi=P + NP)
+ #assert o1["gas"] == o2["gas"], (o1, o2)
+ assert o1["output"] == o2["output"], (o1, o2)
+
+ o1 = substitutes.jacobian_add_substitute(*(P + P))
+ o2 = s.profile(t.k0, c, 0, funid=0, abi=P + P)
+ #assert o1["gas"] == o2["gas"], (o1, o2)
+ assert o1["output"] == o2["output"], (o1, o2)
+
+ o1 = substitutes.jacobian_add_substitute(*(P + Z))
+ o2 = s.profile(t.k0, c, 0, funid=0, abi=P + Z)
+ #assert o1["gas"] == o2["gas"], (o1, o2)
+ assert o1["output"] == o2["output"], (o1, o2)
+
+ o1 = substitutes.jacobian_add_substitute(*(Z + P))
+ o2 = s.profile(t.k0, c, 0, funid=0, abi=Z + P)
+ #assert o1["gas"] == o2["gas"], (o1, o2)
+ assert o1["output"] == o2["output"], (o1, o2)
+
+
+c = s.contract('jacobian_mul.se')
+print "Starting multiplication tests"
+
+
+mul_tests = [
+ Z + [0],
+ Z + [vals[0]],
+ test_points[0] + [0],
+ test_points[1] + [b.N],
+ test_points[2] + [1],
+ test_points[2] + [2],
+ test_points[2] + [3],
+ test_points[2] + [4],
+ test_points[3] + [5],
+ test_points[3] + [6],
+ test_points[4] + [7],
+ test_points[4] + [2**254],
+ test_points[4] + [vals[1]],
+ test_points[4] + [vals[2]],
+ test_points[4] + [vals[3]],
+ test_points[5] + [2**256 - 1],
+]
+
+for i, test in enumerate(mul_tests):
+ print 'trying mul_test %i' % i, test
+ o1 = substitutes.jacobian_mul_substitute(*test)
+ o2 = s.profile(t.k0, c, 0, funid=0, abi=test)
+ # assert o1["gas"] == o2["gas"], (o1, o2, test)
+ assert o1["output"] == o2["output"], (o1, o2, test)
+
+c = s.contract('ecrecover.se')
+print "Starting ecrecover tests"
+
+for i in range(5):
+ print 'trying ecrecover_test', vals[i*2], vals[i*2+1]
+ k = vals[i*2]
+ h = vals[i*2+1]
+ V, R, S = b.ecdsa_raw_sign(b.encode(h, 256, 32), k)
+ aa = time.time()
+ o1 = substitutes.ecrecover_substitute(h, V, R, S)
+ print 'sub', time.time() - aa
+ a = time.time()
+ o2 = s.profile(t.k0, c, 0, funid=0, abi=[h, V, R, S])
+ print time.time() - a
+ # assert o1["gas"] == o2["gas"], (o1, o2, h, V, R, S)
+ assert o1["output"] == o2["output"], (o1, o2, h, V, R, S)
+
+# Explicit tests
+
+data = [[
+ 0xf007a9c78a4b2213220adaaf50c89a49d533fbefe09d52bbf9b0da55b0b90b60,
+ 0x1b,
+ 0x5228fc9e2fabfe470c32f459f4dc17ef6a0a81026e57e4d61abc3bc268fc92b5,
+ 0x697d4221cd7bc5943b482173de95d3114b9f54c5f37cc7f02c6910c6dd8bd107
+]]
+
+for datum in data:
+ o1 = substitutes.ecrecover_substitute(*datum)
+ o2 = s.profile(t.k0, c, 0, funid=0, abi=datum)
+ #assert o1["gas"] == o2["gas"], (o1, o2, datum)
+ assert o1["output"] == o2["output"], (o1, o2, datum)
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/eth15/channel.se b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/eth15/channel.se
new file mode 100644
index 000000000..733f4a95b
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/eth15/channel.se
@@ -0,0 +1,45 @@
+if msg.data[0] == 0:
+ new_id = contract.storage[-1]
+ # store [from, to, value, maxvalue, timeout] in contract storage
+ contract.storage[new_id] = msg.sender
+ contract.storage[new_id + 1] = msg.data[1]
+ contract.storage[new_id + 2] = 0
+ contract.storage[new_id + 3] = msg.value
+ contract.storage[new_id + 4] = 2^254
+ # increment next id
+ contract.storage[-1] = new_id + 10
+ # return id of this channel
+ return(new_id)
+
+# Increase payment on channel: [1, id, value, v, r, s]
+elif msg.data[0] == 1:
+ # Ecrecover native extension; will be a different address in testnet and live
+ ecrecover = 0x46a8d0b21b1336d83b06829f568d7450df36883f
+ # Message data parameters
+ id = msg.data[1] % 2^160
+ value = msg.data[2]
+ # Determine sender from signature
+ h = sha3([id, value], 2)
+ sender = call(ecrecover, [h, msg.data[3], msg.data[4], msg.data[5]], 4)
+ # Check sender matches and new value is greater than old
+ if sender == contract.storage[id]:
+ if value > contract.storage[id + 2] and value <= contract.storage[id + 3]:
+ # Update channel, increasing value and setting timeout
+ contract.storage[id + 2] = value
+ contract.storage[id + 4] = block.number + 1000
+
+# Cash out channel: [2, id]
+elif msg.data[0] == 2:
+ id = msg.data[1] % 2^160
+ # Check if timeout has run out
+ if block.number >= contract.storage[id + 3]:
+ # Send funds
+ send(contract.storage[id + 1], contract.storage[id + 2])
+ # Send refund
+ send(contract.storage[id], contract.storage[id + 3] - contract.storage[id + 2])
+ # Clear storage
+ contract.storage[id] = 0
+ contract.storage[id + 1] = 0
+ contract.storage[id + 2] = 0
+ contract.storage[id + 3] = 0
+ contract.storage[id + 4] = 0
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/eth15/map.se b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/eth15/map.se
new file mode 100644
index 000000000..768dfb9fc
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/eth15/map.se
@@ -0,0 +1,19 @@
+# An implementation of a contract for storing a key/value binding
+init:
+ # Set owner
+ contract.storage[0] = msg.sender
+code:
+ # Check ownership
+ if msg.sender == contract.storage[0]:
+ # Get: returns (found, val)
+ if msg.data[0] == 0:
+ s = sha3(msg.data[1])
+ return([contract.storage[s], contract.storage[s+1]], 2)
+ # Set: sets map[k] = v
+ elif msg.data[0] == 1:
+ s = sha3(msg.data[1])
+ contract.storage[s] = 1
+ contract.storage[s + 1] = msg.data[2]
+ # Suicide
+ elif msg.data[2] == 1:
+ suicide(0)
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/eth15/multiforward.se b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/eth15/multiforward.se
new file mode 100644
index 000000000..577794d97
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/eth15/multiforward.se
@@ -0,0 +1,14 @@
+init:
+ contract.storage[0] = msg.sender
+code:
+ if msg.sender != contract.storage[0]:
+ stop
+ i = 0
+ while i < ~calldatasize():
+ to = ~calldataload(i)
+ value = ~calldataload(i+20) / 256^12
+ datasize = ~calldataload(i+32) / 256^30
+ data = alloc(datasize)
+ ~calldatacopy(data, i+34, datasize)
+ ~call(tx.gas - 25, to, value, data, datasize, 0, 0)
+ i += 34 + datasize
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/eth15/shadowchain.se b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/eth15/shadowchain.se
new file mode 100644
index 000000000..1e466a355
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/eth15/shadowchain.se
@@ -0,0 +1,166 @@
+# Exists in state:
+# (i) last committed block
+# (ii) chain of uncommitted blocks (linear only)
+# (iii) transactions, each tx with an associated block number
+#
+# Uncommitted block =
+# [ numtxs, numkvs, tx1 (N words), tx2 (N words) ..., [k1, v1], [k2, v2], [k3, v3] ... ]
+#
+# Block checking process
+#
+# Suppose last committed state is m
+# Last uncommitted state is n
+# Contested block is b
+#
+# 1. Temporarily apply all state transitions from
+# m to b
+# 2. Run code, get list of changes
+# 3. Check is list of changes matches deltas
+# * if yes, do nothing
+# * if no, set last uncommitted state to pre-b
+#
+# Storage variables:
+#
+# Last committed block: 0
+# Last uncommitted block: 1
+# Contract holding code: 2
+# Uncommitted map: 3
+# Transaction length (parameter): 4
+# Block b: 2^160 + b * 2^40:
+# + 1: submission blknum
+# + 2: submitter
+# + 3: data in uncommitted block format above
+# Last committed storage:
+# sha3(k): index k
+
+# Initialize: [0, c, txlength], set address of the code-holding contract and the transaction
+# length
+if not contract.storage[2]:
+ contract.storage[2] = msg.data[1]
+ contract.storage[4] = msg.data[2]
+ stop
+
+# Sequentially commit all uncommitted blocks that are more than 1000 mainchain-blocks old
+last_committed_block = contract.storage[0]
+last_uncommitted_block = contract.storage[1]
+lcb_storage_index = 2^160 + last_committed_block * 2^40
+while contract.storage[lcb_storage_index + 1] < block.number - 1000 and last_committed_block < last_uncommitted_block:
+ kvpairs = contract.storage[lcb_storage_index]
+ i = 0
+ while i < kvpairs:
+ k = contract.storage[lcb_storage_index + 3 + i * 2]
+ v = contract.storage[lcb_storage_index + 4 + i * 2]
+ contract.storage[sha3(k)] = v
+ i += 1
+ last_committed_block += 1
+ lcb_storage_index += 2^40
+contract.storage[0] = last_committed_block
+
+
+# Propose block: [ 0, block number, data in block format above ... ]
+if msg.data[0] == 0:
+ blknumber = msg.data[1]
+ # Block number must be correct
+ if blknumber != contract.storage[1]:
+ stop
+ # Deposit requirement
+ if msg.value < 10^19:
+ stop
+ # Store the proposal in storage as
+ # [ 0, main-chain block number, sender, block data...]
+ start_index = 2^160 + blknumber * 2^40
+ numkvs = (msg.datasize - 2) / 2
+ contract.storage[start_index + 1] = block.number
+ 1ontract.storage[start_index + 2] = msg.sender
+ i = 0
+ while i < msg.datasize - 2:
+ contract.storage[start_index + 3 + i] = msg.data[2 + i]
+ i += 1
+ contract.storage[1] = blknumber + 1
+
+# Challenge block: [ 1, b ]
+elif msg.data[0] == 1:
+ blknumber = msg.data[1]
+ txwidth = contract.storage[4]
+ last_uncommitted_block = contract.storage[1]
+ last_committed_block = contract.storage[0]
+ # Cannot challenge nonexistent or committed blocks
+ if blknumber <= last_uncommitted_block or blknumber > last_committed_block:
+ stop
+ # Create a contract to serve as a map that maintains keys and values
+ # temporarily
+ tempstore = create('map.se')
+ contract.storage[3] = tempstore
+ # Unquestioningly apply the state transitions from the last committed block
+ # up to b
+ b = last_committed_block
+ cur_storage_index = 2^160 + last_committed_block * 2^40
+ while b < blknumber:
+ numtxs = contract.storage[cur_storage_index + 3]
+ numkvs = contract.storage[cur_storage_index + 4]
+ kv0index = cur_storage_index + 5 + numtxs * txwidth
+ i = 0
+ while i < numkvs:
+ k = contract.storage[kv0index + i * 2]
+ v = contract.storage[kx0index + i * 2 + 1]
+ call(tempstore, [1, k, v], 3)
+ i += 1
+ b += 1
+ cur_storage_index += 2^40
+ # Run the actual code, and see what state transitions it outputs
+ # The way that the code is expected to work is to:
+ #
+ # (1) take as input the list of transactions (the contract should
+ # use msg.datasize to determine how many txs there are, and it should
+ # be aware of the value of txwidth)
+ # (2) call this contract with [2, k] to read current state data
+ # (3) call this contract with [3, k, v] to write current state data
+ # (4) return as output a list of all state transitions that it made
+ # in the form [kvcount, k1, v1, k2, v2 ... ]
+ #
+ # The reason for separating (2) from (3) is that sometimes the state
+ # transition may end up changing a given key many times, and we don't
+ # need to inefficiently store that in storage
+ numkvs = contract.storage[cur_storage_index + 3]
+ numtxs = contract.storage[cur_storage_index + 4]
+ # Populate input array
+ inpwidth = numtxs * txwidth
+ inp = array(inpwidth)
+ i = 0
+ while i < inpwidth:
+ inp[i] = contract.storage[cur_storage_index + 5 + i]
+ i += 1
+ out = call(contract.storage[2], inp, inpwidth, numkvs * 2 + 1)
+ # Check that the number of state transitions is the same
+ if out[0] != kvcount:
+ send(msg.sender, 10^19)
+ contract.storage[0] = last_committed_block
+ stop
+ kv0index = cur_storage_index + 5 + numtxs * txwidth
+ i = 0
+ while i < kvcount:
+ # Check that each individual state transition matches
+ k = contract.storage[kv0index + i * 2 + 1]
+ v = contract.storage[kv0index + i * 2 + 2]
+ if k != out[i * 2 + 1] or v != out[i * 2 + 2]:
+ send(msg.sender, 10^19)
+ contract.storage[0] = last_committed_block
+ stop
+ i += 1
+ # Suicide tempstore
+ call(tempstore, 2)
+
+
+# Read data [2, k]
+elif msg.data[0] == 2:
+ tempstore = contract.storage[3]
+ o = call(tempstore, [0, msg.data[1]], 2, 2)
+ if o[0]:
+ return(o[1])
+ else:
+ return contract.storage[sha3(msg.data[1])]
+
+# Write data [3, k, v]
+elif msg.data[0] == 3:
+ tempstore = contract.storage[3]
+ call(tempstore, [1, msg.data[1], msg.data[2]], 3, 2)
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/fixedpoint.se b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/fixedpoint.se
new file mode 100644
index 000000000..a8073c685
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/fixedpoint.se
@@ -0,0 +1,31 @@
+type f: [a, b, c, d, e]
+
+macro f($a) + f($b):
+ f(add($a, $b))
+
+macro f($a) - f($b):
+ f(sub($a, $b))
+
+macro f($a) * f($b):
+ f(mul($a, $b) / 10000)
+
+macro f($a) / f($b):
+ f(sdiv($a * 10000, $b))
+
+macro f($a) % f($b):
+ f(smod($a, $b))
+
+macro f($v) = f($w):
+ $v = $w
+
+macro unfify(f($a)):
+ $a / 10000
+
+macro fify($a):
+ f($a * 10000)
+
+a = fify(5)
+b = fify(2)
+c = a / b
+e = c + (a / b)
+return(unfify(e))
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/long_integer_macros.se b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/long_integer_macros.se
new file mode 100644
index 000000000..58cdce6ab
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/long_integer_macros.se
@@ -0,0 +1,116 @@
+macro smin($a, $b):
+ with $1 = $a:
+ with $2 = $b:
+ if(slt($1, $2), $1, $2)
+
+macro smax($a, $b):
+ with $1 = $a:
+ with $2 = $b:
+ if(slt($1, $2), $2, $1)
+
+def omul(x, y):
+ o = expose(mklong(x) * mklong(y))
+ return(slice(o, 1), o[0]+1)
+
+def oadd(x, y):
+ o = expose(mklong(x) + mklong(y))
+ return(slice(o, 1), o[0]+1)
+
+def osub(x, y):
+ o = expose(mklong(x) - mklong(y))
+ return(slice(o, 1), o[0]+1)
+
+def odiv(x, y):
+ o = expose(mklong(x) / mklong(y))
+ return(slice(o, 1), o[0]+1)
+
+def comb(a:a, b:a, sign):
+ sz = smax(a[0], b[0])
+ msz = smin(a[0], b[0])
+ c = array(sz + 2)
+ c[0] = sz
+ i = 0
+ carry = 0
+ while i < msz:
+ m = a[i + 1] + sign * b[i + 1] + carry
+ c[i + 1] = mod(m + 2^127, 2^128) - 2^127
+ carry = (div(m + 2^127, 2^128) + 2^127) % 2^128 - 2^127
+ i += 1
+ u = if(a[0] > msz, a, b)
+ s = if(a[0] > msz, 1, sign)
+ while i < sz:
+ m = s * u[i + 1] + carry
+ c[i + 1] = mod(m + 2^127, 2^128) - 2^127
+ carry = (div(m + 2^127, 2^128) + 2^127) % 2^128 - 2^127
+ i += 1
+ if carry:
+ c[0] += 1
+ c[sz + 1] = carry
+ return(c, c[0]+1)
+
+def mul(a:a, b:a):
+ c = array(a[0] + b[0] + 2)
+ c[0] = a[0] + b[0]
+ i = 0
+ while i < a[0]:
+ j = 0
+ carry = 0
+ while j < b[0]:
+ m = c[i + j + 1] + a[i + 1] * b[j + 1] + carry
+ c[i + j + 1] = mod(m + 2^127, 2^128) - 2^127
+ carry = (div(m + 2^127, 2^128) + 2^127) % 2^128 - 2^127
+ j += 1
+ if carry:
+ c[0] = a[0] + b[0] + 1
+ c[i + j + 1] += carry
+ i += 1
+ return(c, c[0]+1)
+
+macro long($a) + long($b):
+ long(self.comb($a:$a[0]+1, $b:$b[0]+1, 1, outsz=$a[0]+$b[0]+2))
+
+macro long($a) - long($b):
+ long(self.comb($a:$a[0]+1, $b:$b[0]+1, -1, outsz=$a[0]+$b[0]+2))
+
+macro long($a) * long($b):
+ long(self.mul($a:$a[0]+1, $b:$b[0]+1, outsz=$a[0]+$b[0]+2))
+
+macro long($a) / long($b):
+ long(self.div($a:$a[0]+1, $b:$b[0]+1, outsz=$a[0]+$b[0]+2))
+
+macro mulexpand(long($a), $k, $m):
+ long:
+ with $c = array($a[0]+k+2):
+ $c[0] = $a[0]+$k
+ with i = 0:
+ while i < $a[0]:
+ v = $a[i+1] * $m + $c[i+$k+1]
+ $c[i+$k+1] = mod(v + 2^127, 2^128) - 2^127
+ $c[i+$k+2] = div(v + 2^127, 2^128)
+ i += 1
+ $c
+
+def div(a:a, b:a):
+ asz = a[0]
+ bsz = b[0]
+ while b[bsz] == 0 and bsz > 0:
+ bsz -= 1
+ c = array(asz+2)
+ c[0] = asz+1
+ while 1:
+ while a[asz] == 0 and asz > 0:
+ asz -= 1
+ if asz < bsz:
+ return(c, c[0]+1)
+ sub = expose(mulexpand(long(b), asz - bsz, a[asz] / b[bsz]))
+ c[asz - bsz+1] = a[asz] / b[bsz]
+ a = expose(long(a) - long(sub))
+ a[asz-1] += 2^128 * a[asz]
+ a[asz] = 0
+
+macro mklong($i):
+ long([2, mod($i + 2^127, 2^128) - 2^127, div($i + 2^127, 2^128)])
+
+macro expose(long($i)):
+ $i
+
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/mul2.se b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/mul2.se
new file mode 100644
index 000000000..65adff1e6
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/mul2.se
@@ -0,0 +1,2 @@
+def double(v):
+ return(v*2)
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/mutuala.se b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/mutuala.se
new file mode 100644
index 000000000..3efb0edeb
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/mutuala.se
@@ -0,0 +1,187 @@
+# mutuala - subcurrency
+
+# We want to issue a currency that reduces in value as you store it through negative interest.
+# That negative interest would be stored in a commons account. It's like the p2p version of a
+# capital tax
+
+# the same things goes for transactions - you pay as you use the currency. However, the more
+# you pay, the more you get to say about what the tax is used for
+
+# each participant can propose a recipient for a payout to be made out of the commons account,
+# others can vote on it by awarding it tax_credits.
+
+# TODO should proposal have expiration timestamp?, after which the tax_credits are refunded
+# TODO multiple proposals can take more credits that available in the Commons, how to handle this
+# TODO how to handle lost accounts, after which no longer possible to get 2/3 majority
+
+shared:
+ COMMONS = 42
+ ADMIN = 666
+ CAPITAL_TAX_PER_DAY = 7305 # 5% per year
+ PAYMENT_TAX = 20 # 5%
+
+ ACCOUNT_LIST_OFFSET = 2^160
+ ACCOUNT_MAP_OFFSET = 2^161
+ PROPOSAL_LIST_OFFSET = 2^162
+ PROPOSAL_MAP_OFFSET = 2^163
+
+init:
+ contract.storage[ADMIN] = msg.sender
+ contract.storage[ACCOUNT_LIST_OFFSET - 1] = 1
+ contract.storage[ACCOUNT_LIST_OFFSET] = msg.sender
+ contract.storage[ACCOUNT_MAP_OFFSET + msg.sender] = 10^12
+ contract.storage[ACCOUNT_MAP_OFFSET + msg.sender + 1] = block.timestamp
+
+# contract.storage[COMMONS] = balance commons
+
+# contract.storage[ACCOUNT_LIST_OFFSET - 1] = number of accounts
+# contract.storage[ACCOUNT_LIST_OFFSET + n] = account n
+
+# contract.storage[PROPOSAL_LIST_OFFSET - 1] contains the number of proposals
+# contract.storage[PROPOSAL_LIST_OFFSET + n] = proposal n
+
+# per account:
+# contract.storage[ACCOUNT_MAP_OFFSET + account] = balance
+# contract.storage[ACCOUNT_MAP_OFFSET + account+1] = timestamp_last_transaction
+# contract.storage[ACCOUNT_MAP_OFFSET + account+2] = tax_credits
+
+# per proposal:
+# contract.storage[PROPOSAL_MAP_OFFSET + proposal_id] = recipient
+# contract.storage[PROPOSAL_MAP_OFFSET + proposal_id+1] = amount
+# contract.storage[PROPOSAL_MAP_OFFSET + proposal_id+2] = total vote credits
+
+code:
+ if msg.data[0] == "suicide" and msg.sender == contract.storage[ADMIN]:
+ suicide(msg.sender)
+
+ elif msg.data[0] == "balance":
+ addr = msg.data[1]
+ return(contract.storage[ACCOUNT_MAP_OFFSET + addr])
+
+ elif msg.data[0] == "pay":
+ from = msg.sender
+ fromvalue = contract.storage[ACCOUNT_MAP_OFFSET + from]
+ to = msg.data[1]
+ if to == 0 or to >= 2^160:
+ return([0, "invalid address"], 2)
+ value = msg.data[2]
+ tax = value / PAYMENT_TAX
+
+ if fromvalue >= value + tax:
+ contract.storage[ACCOUNT_MAP_OFFSET + from] = fromvalue - (value + tax)
+ contract.storage[ACCOUNT_MAP_OFFSET + to] += value
+ # tax
+ contract.storage[COMMONS] += tax
+ contract.storage[ACCOUNT_MAP_OFFSET + from + 2] += tax
+
+ # check timestamp field to see if target account exists
+ if contract.storage[ACCOUNT_MAP_OFFSET + to + 1] == 0:
+ # register new account
+ nr_accounts = contract.storage[ACCOUNT_LIST_OFFSET - 1]
+ contract.storage[ACCOUNT_LIST_OFFSET + nr_accounts] = to
+ contract.storage[ACCOUNT_LIST_OFFSET - 1] += 1
+ contract.storage[ACCOUNT_MAP_OFFSET + to + 1] = block.timestamp
+
+ return(1)
+ else:
+ return([0, "insufficient balance"], 2)
+
+ elif msg.data[0] == "hash":
+ proposal_id = sha3(msg.data[1])
+ return(proposal_id)
+
+ elif msg.data[0] == "propose":
+ from = msg.sender
+ # check if sender has an account and has tax credits
+ if contract.storage[ACCOUNT_MAP_OFFSET + from + 2] == 0:
+ return([0, "sender has no tax credits"], 2)
+
+ proposal_id = sha3(msg.data[1])
+ # check if proposal doesn't already exist
+ if contract.storage[PROPOSAL_MAP_OFFSET + proposal_id]:
+ return([0, "proposal already exists"])
+
+ to = msg.data[2]
+ # check if recipient is a valid address and has an account (with timestamp)
+ if to == 0 or to >= 2^160:
+ return([0, "invalid address"], 2)
+ if contract.storage[ACCOUNT_MAP_OFFSET + to + 1] == 0:
+ return([0, "invalid to account"], 2)
+
+ value = msg.data[3]
+ # check if there is enough money in the commons account
+ if value > contract.storage[COMMONS]:
+ return([0, "not enough credits in commons"], 2)
+
+ # record proposal in list
+ nr_proposals = contract.storage[PROPOSAL_LIST_OFFSET - 1]
+ contract.storage[PROPOSAL_LIST_OFFSET + nr_proposals] = proposal_id
+ contract.storage[PROPOSAL_LIST_OFFSET - 1] += 1
+
+ # record proposal in map
+ contract.storage[PROPOSAL_MAP_OFFSET + proposal_id] = to
+ contract.storage[PROPOSAL_MAP_OFFSET + proposal_id + 1] = value
+
+ return(proposal_id)
+
+ elif msg.data[0] == "vote":
+ from = msg.sender
+ proposal_id = sha3(msg.data[1])
+ value = msg.data[2]
+ # check if sender has an account and has tax credits
+ if value < contract.storage[ACCOUNT_MAP_OFFSET + from + 2]:
+ return([0, "sender doesn't have enough tax credits"], 2)
+
+ # check if proposal exist
+ if contract.storage[PROPOSAL_MAP_OFFSET + proposal_id] == 0:
+ return([0, "proposal doesn't exist"], 2)
+
+ # increase votes
+ contract.storage[PROPOSAL_MAP_OFFSET + proposal_id + 2] += value
+ # withdraw tax credits
+ contract.storage[ACCOUNT_MAP_OFFSET + from + 2] -= value
+
+ # did we reach 2/3 threshold?
+ if contract.storage[PROPOSAL_MAP_OFFSET + proposal_id + 2] >= contract.storage[COMMONS] * 2 / 3:
+ # got majority
+ to = contract.storage[PROPOSAL_MAP_OFFSET + proposal_id]
+ amount = contract.storage[PROPOSAL_MAP_OFFSET + proposal_id + 1]
+
+ # adjust balances
+ contract.storage[ACCOUNT_MAP_OFFSET + to] += amount
+ contract.storage[COMMONS] -= amount
+
+ # reset proposal
+ contract.storage[PROPOSAL_MAP_OFFSET + proposal_id] = 0
+ contract.storage[PROPOSAL_MAP_OFFSET + proposal_id + 1] = 0
+ contract.storage[PROPOSAL_MAP_OFFSET + proposal_id + 2] = 0
+ return(1)
+
+ return(proposal_id)
+
+ elif msg.data[0] == "tick":
+ nr_accounts = contract.storage[ACCOUNT_LIST_OFFSET - 1]
+ account_idx = 0
+ tax_paid = 0
+ # process all accounts and see if they have to pay their daily capital tax
+ while account_idx < nr_accounts:
+ cur_account = contract.storage[ACCOUNT_LIST_OFFSET + account_idx]
+ last_timestamp = contract.storage[ACCOUNT_MAP_OFFSET + cur_account + 1]
+ time_diff = block.timestamp - last_timestamp
+ if time_diff >= 86400:
+ tax_days = time_diff / 86400
+ balance = contract.storage[ACCOUNT_MAP_OFFSET + cur_account]
+ tax = tax_days * (balance / CAPITAL_TAX_PER_DAY)
+ if tax > 0:
+ # charge capital tax, but give tax credits in return
+ contract.storage[ACCOUNT_MAP_OFFSET + cur_account] -= tax
+ contract.storage[ACCOUNT_MAP_OFFSET + cur_account + 1] += tax_days * 86400
+ contract.storage[ACCOUNT_MAP_OFFSET + cur_account + 2] += tax
+
+ contract.storage[COMMONS] += tax
+ tax_paid += 1
+ account_idx += 1
+ return(tax_paid) # how many accounts did we charge tax on
+
+ else:
+ return([0, "unknown command"], 2)
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/namecoin.se b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/namecoin.se
new file mode 100644
index 000000000..11d6274ae
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/namecoin.se
@@ -0,0 +1,7 @@
+def register(k, v):
+ if !self.storage[k]: # Is the key not yet taken?
+ # Then take it!
+ self.storage[k] = v
+ return(1)
+ else:
+ return(0) // Otherwise do nothing
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/peano.se b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/peano.se
new file mode 100644
index 000000000..979854444
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/peano.se
@@ -0,0 +1,43 @@
+macro padd($x, psuc($y)):
+ psuc(padd($x, $y))
+
+macro padd($x, z()):
+ $x
+
+macro dec(psuc($x)):
+ dec($x) + 1
+
+macro dec(z()):
+ 0
+
+macro pmul($x, z()):
+ z()
+
+macro pmul($x, psuc($y)):
+ padd(pmul($x, $y), $x)
+
+macro pexp($x, z()):
+ one()
+
+macro pexp($x, psuc($y)):
+ pmul($x, pexp($x, $y))
+
+macro fac(z()):
+ one()
+
+macro fac(psuc($x)):
+ pmul(psuc($x), fac($x))
+
+macro one():
+ psuc(z())
+
+macro two():
+ psuc(psuc(z()))
+
+macro three():
+ psuc(psuc(psuc(z())))
+
+macro five():
+ padd(three(), two())
+
+return([dec(pmul(three(), pmul(three(), three()))), dec(fac(five()))], 2)
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/returnten.se b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/returnten.se
new file mode 100644
index 000000000..7969c9eb8
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/returnten.se
@@ -0,0 +1,4 @@
+extern mul2: [double]
+
+x = create("mul2.se")
+return(x.double(5))
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/schellingcoin/quicksort.se b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/schellingcoin/quicksort.se
new file mode 100644
index 000000000..be5d97fc7
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/schellingcoin/quicksort.se
@@ -0,0 +1,33 @@
+def kall():
+ argcount = ~calldatasize() / 32
+ if argcount == 1:
+ return(~calldataload(1))
+
+ args = array(argcount)
+ ~calldatacopy(args, 1, argcount * 32)
+ low = array(argcount)
+ lsz = 0
+ high = array(argcount)
+ hsz = 0
+ i = 1
+ while i < argcount:
+ if args[i] < args[0]:
+ low[lsz] = args[i]
+ lsz += 1
+ else:
+ high[hsz] = args[i]
+ hsz += 1
+ i += 1
+ low = self.kall(data=low, datasz=lsz, outsz=lsz)
+ high = self.kall(data=high, datasz=hsz, outsz=hsz)
+ o = array(argcount)
+ i = 0
+ while i < lsz:
+ o[i] = low[i]
+ i += 1
+ o[lsz] = args[0]
+ j = 0
+ while j < hsz:
+ o[lsz + 1 + j] = high[j]
+ j += 1
+ return(o, argcount)
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/schellingcoin/quicksort_pairs.se b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/schellingcoin/quicksort_pairs.se
new file mode 100644
index 000000000..0e603a238
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/schellingcoin/quicksort_pairs.se
@@ -0,0 +1,46 @@
+# Quicksort pairs
+# eg. input of the form [ 30, 1, 90, 2, 70, 3, 50, 4]
+# outputs [ 30, 1, 50, 4, 70, 3, 90, 2 ]
+#
+# Note: this can be used as a generalized sorting algorithm:
+# map every object to [ key, ref ] where `ref` is the index
+# in memory to all of the properties and `key` is the key to
+# sort by
+
+
+def kall():
+ argcount = ~calldatasize() / 64
+ if argcount == 1:
+ return([~calldataload(1), ~calldataload(33)], 2)
+
+ args = array(argcount * 2)
+ ~calldatacopy(args, 1, argcount * 64)
+ low = array(argcount * 2)
+ lsz = 0
+ high = array(argcount * 2)
+ hsz = 0
+ i = 2
+ while i < argcount * 2:
+ if args[i] < args[0]:
+ low[lsz] = args[i]
+ low[lsz + 1] = args[i + 1]
+ lsz += 2
+ else:
+ high[hsz] = args[i]
+ high[hsz + 1] = args[i + 1]
+ hsz += 2
+ i = i + 2
+ low = self.kall(data=low, datasz=lsz, outsz=lsz)
+ high = self.kall(data=high, datasz=hsz, outsz=hsz)
+ o = array(argcount * 2)
+ i = 0
+ while i < lsz:
+ o[i] = low[i]
+ i += 1
+ o[lsz] = args[0]
+ o[lsz + 1] = args[1]
+ j = 0
+ while j < hsz:
+ o[lsz + 2 + j] = high[j]
+ j += 1
+ return(o, argcount * 2)
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/schellingcoin/schellingcoin.se b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/schellingcoin/schellingcoin.se
new file mode 100644
index 000000000..a7d7da9c5
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/schellingcoin/schellingcoin.se
@@ -0,0 +1,94 @@
+# SchellingCoin implementation
+#
+# Epoch length: 100 blocks
+# Target savings depletion rate: 0.1% per epoch
+
+data epoch
+data hashes_submitted
+data output
+data quicksort_pairs
+data accounts[2^160]
+data submissions[2^80](hash, deposit, address, value)
+extern any: [call]
+
+
+def init():
+ self.epoch = block.number / 100
+ self.quicksort_pairs = create('quicksort_pairs.se')
+
+def any():
+ if block.number / 100 > epoch:
+ # Sort all values submitted
+ N = self.hashes_submitted
+ o = array(N * 2)
+ i = 0
+ j = 0
+ while i < N:
+ v = self.submissions[i].value
+ if v:
+ o[j] = v
+ o[j + 1] = i
+ j += 2
+ i += 1
+ values = self.quicksort_pairs.call(data=o, datasz=j, outsz=j)
+
+ # Calculate total deposit, refund non-submitters and
+ # cleanup
+
+ deposits = array(j / 2)
+ addresses = array(j / 2)
+
+ i = 0
+ total_deposit = 0
+ while i < j / 2:
+ base_index = HASHES + values[i * 2 + 1] * 3
+ deposits[i] = self.submissions[i].deposit
+ addresses[i] = self.submissions[i].address
+ if self.submissions[values[i * 2 + 1]].value:
+ total_deposit += deposits[i]
+ else:
+ send(addresses[i], deposits[i] * 999 / 1000)
+ i += 1
+
+ inverse_profit_ratio = total_deposit / (contract.balance / 1000) + 1
+
+ # Reward everyone
+ i = 0
+ running_deposit_sum = 0
+ halfway_passed = 0
+ while i < j / 2:
+ new_deposit_sum = running_deposit_sum + deposits[i]
+ if new_deposit_sum > total_deposit / 4 and running_deposit_sum < total_deposit * 3 / 4:
+ send(addresses[i], deposits[i] + deposits[i] / inverse_profit_ratio * 2)
+ else:
+ send(addresses[i], deposits[i] - deposits[i] / inverse_profit_ratio)
+
+ if not halfway_passed and new_deposit_sum > total_deposit / 2:
+ self.output = self.submissions[i].value
+ halfway_passed = 1
+ self.submissions[i].value = 0
+ running_deposit_sum = new_deposit_sum
+ i += 1
+ self.epoch = block.number / 100
+ self.hashes_submitted = 0
+
+def submit_hash(h):
+ if block.number % 100 < 50:
+ cur = self.hashes_submitted
+ pos = HASHES + cur * 3
+ self.submissions[cur].hash = h
+ self.submissions[cur].deposit = msg.value
+ self.submissions[cur].address = msg.sender
+ self.hashes_submitted = cur + 1
+ return(cur)
+
+def submit_value(index, v):
+ if sha3([msg.sender, v], 2) == self.submissions[index].hash:
+ self.submissions[index].value = v
+ return(1)
+
+def request_balance():
+ return(contract.balance)
+
+def request_output():
+ return(self.output)
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/schellingcoin/schellingdollar.se b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/schellingcoin/schellingdollar.se
new file mode 100644
index 000000000..a34f42ce2
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/schellingcoin/schellingdollar.se
@@ -0,0 +1,171 @@
+# Hedged zero-supply dollar implementation
+# Uses SchellingCoin as price-determining backend
+#
+# Stored variables:
+#
+# 0: Schelling coin contract
+# 1: Last epoch
+# 2: Genesis block of contract
+# 3: USD exposure
+# 4: ETH exposure
+# 5: Cached price
+# 6: Last interest rate
+# 2^160 + k: interest rate accumulator at k epochs
+# 2^161 + ADDR * 3: eth-balance of a particular address
+# 2^161 + ADDR * 3 + 1: usd-balance of a particular address
+# 2^161 + ADDR * 3 + 1: last accessed epoch of a particular address
+#
+# Transaction types:
+#
+# [1, to, val]: send ETH
+# [2, to, val]: send USD
+# [3, wei_amount]: convert ETH to USD
+# [4, usd_amount]: converts USD to ETH
+# [5]: deposit
+# [6, amount]: withdraw
+# [7]: my balance query
+# [7, acct]: balance query for any acct
+# [8]: global state query
+# [9]: liquidation test any account
+#
+# The purpose of the contract is to serve as a sort of cryptographic
+# bank account where users can store both ETH and USD. ETH must be
+# stored in zero or positive quantities, but USD balances can be
+# positive or negative. If the USD balance is negative, the invariant
+# usdbal * 10 >= ethbal * 9 must be satisfied; if any account falls
+# below this value, then that account's balances are zeroed. Note
+# that there is a 2% bounty to ping the app if an account does go
+# below zero; one weakness is that if no one does ping then it is
+# quite possible for accounts to go negative-net-worth, then zero
+# themselves out, draining the reserves of the "bank" and potentially
+# bankrupting it. A 0.1% fee on ETH <-> USD trade is charged to
+# minimize this risk. Additionally, the bank itself will inevitably
+# end up with positive or negative USD exposure; to mitigate this,
+# it automatically updates interest rates on USD to keep exposure
+# near zero.
+
+data schelling_coin
+data last_epoch
+data starting_block
+data usd_exposure
+data eth_exposure
+data price
+data last_interest_rate
+data interest_rate_accum[2^50]
+data accounts[2^160](eth, usd, last_epoch)
+
+extern sc: [submit_hash, submit_value, request_balance, request_output]
+
+def init():
+ self.schelling_coin = create('schellingcoin.se')
+ self.price = self.schelling_coin.request_output()
+ self.interest_rate_accum[0] = 10^18
+ self.starting_block = block.number
+
+def any():
+ sender = msg.sender
+ epoch = (block.number - self.starting_block) / 100
+ last_epoch = self.last_epoch
+ usdprice = self.price
+
+ # Update contract epochs
+ if epoch > last_epoch:
+ delta = epoch - last_epoch
+ last_interest_rate = self.last_interest_rate
+ usd_exposure - self.usd_exposure
+ last_accum = self.interest_rate_accum[last_epoch]
+
+ if usd_exposure < 0:
+ self.last_interest_rate = last_interest_rate - 10000 * delta
+ elif usd_exposure > 0:
+ self.last_interest_rate = last_interest_rate + 10000 * delta
+
+ self.interest_rate_accum[epoch] = last_accum + last_accum * last_interest_rate * delta / 10^9
+
+ # Proceeds go to support the SchellingCoin feeding it price data, ultimately providing the depositors
+ # of the SchellingCoin an interest rate
+ bal = max(self.balance - self.eth_exposure, 0) / 10000
+ usdprice = self.schelling_coin.request_output()
+ self.price = usdprice
+ self.last_epoch = epoch
+
+ ethbal = self.accounts[msg.sender].eth
+ usdbal = self.accounts[msg.sender].usd
+
+ # Apply interest rates to sender and liquidation-test self
+ if msg.sender != self:
+ self.ping(self)
+
+def send_eth(to, value):
+ if value > 0 and value <= ethbal and usdbal * usdprice * 2 + (ethbal - value) >= 0:
+ self.accounts[msg.sender].eth = ethbal - value
+ self.ping(to)
+ self.accounts[to].eth += value
+ return(1)
+
+def send_usd(to, value):
+ if value > 0 and value <= usdbal and (usdbal - value) * usdprice * 2 + ethbal >= 0:
+ self.accounts[msg.sender].usd = usdbal - value
+ self.ping(to)
+ self.accounts[to].usd += value
+ return(1)
+
+def convert_to_eth(usdvalue):
+ ethplus = usdvalue * usdprice * 999 / 1000
+ if usdvalue > 0 and (usdbal - usdvalue) * usdprice * 2 + (ethbal + ethplus) >= 0:
+ self.accounts[msg.sender].eth = ethbal + ethplus
+ self.accounts[msg.sender].usd = usdbal - usdvalue
+ self.eth_exposure += ethplus
+ self.usd_exposure -= usdvalue
+ return([ethbal + ethplus, usdbal - usdvalue], 2)
+
+def convert_to_usd(ethvalue):
+ usdplus = ethvalue / usdprice * 999 / 1000
+ if ethvalue > 0 and (usdbal + usdplus) * usdprice * 2 + (ethbal - ethvalue) >= 0:
+ self.accounts[msg.sender].eth = ethbal - ethvalue
+ self.accounts[msg.sender].usd = usdbal + usdplus
+ self.eth_exposure -= ethvalue
+ self.usd_exposure += usdplus
+ return([ethbal - ethvalue, usdbal + usdplus], 2)
+
+def deposit():
+ self.accounts[msg.sender].eth = ethbal + msg.value
+ self.eth_exposure += msg.value
+ return(ethbal + msg.value)
+
+def withdraw(value):
+ if value > 0 and value <= ethbal and usdbal * usdprice * 2 + (ethbal - value) >= 0:
+ self.accounts[msg.sender].eth -= value
+ self.eth_exposure -= value
+ return(ethbal - value)
+
+def balance(acct):
+ self.ping(acct)
+ return([self.accounts[acct].eth, self.accounts[acct].usd], 2)
+
+def global_state_query(acct):
+ interest = self.last_interest_rate
+ usd_exposure = self.usd_exposure
+ eth_exposure = self.eth_exposure
+ eth_balance = self.balance
+ return([epoch, usdprice, interest, usd_exposure, eth_exposure, eth_balance], 6)
+
+def ping(acct):
+ account_last_epoch = self.accounts[acct].last_epoch
+ if account_last_epoch != epoch:
+ cur_usd_balance = self.accounts[acct].usd
+ new_usd_balance = cur_usd_balance * self.interest_rate_accum[epoch] / self.interest_rate_accum[account_last_epoch]
+ self.accounts[acct].usd = new_usd_balance
+ self.accounts[acct].last_epoch = epoch
+ self.usd_exposure += new_usd_balance - cur_usd_balance
+
+ ethbal = self.accounts[acct].eth
+
+ if new_usd_balance * usdval * 10 + ethbal * 9 < 0:
+ self.accounts[acct].eth = 0
+ self.accounts[acct].usd = 0
+ self.accounts[msg.sender].eth += ethbal / 50
+ self.eth_exposure += -ethbal + ethbal / 50
+ self.usd_exposure += new_usd_balance
+ return(1)
+ return(0)
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/schellinghelper.se b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/schellinghelper.se
new file mode 100644
index 000000000..0e522d6e8
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/schellinghelper.se
@@ -0,0 +1 @@
+return(sha3([msg.sender, msg.data[0]], 2))
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/short_namecoin.se b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/short_namecoin.se
new file mode 100644
index 000000000..db327a77d
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/short_namecoin.se
@@ -0,0 +1,3 @@
+def register(k, v):
+ if !self.storage[k]:
+ self.storage[k] = v
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/subcurrency.se b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/subcurrency.se
new file mode 100644
index 000000000..fbda822b6
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/examples/subcurrency.se
@@ -0,0 +1,11 @@
+def init():
+ self.storage[msg.sender] = 1000000
+
+def balance_query(k):
+ return(self.storage[addr])
+
+def send(to, value):
+ fromvalue = self.storage[msg.sender]
+ if fromvalue >= value:
+ self.storage[from] = fromvalue - value
+ self.storage[to] += value
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/funcs.cpp b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/funcs.cpp
new file mode 100644
index 000000000..ea9be14a6
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/funcs.cpp
@@ -0,0 +1,35 @@
+#include <stdio.h>
+#include <iostream>
+#include <vector>
+#include "funcs.h"
+#include "bignum.h"
+#include "util.h"
+#include "parser.h"
+#include "lllparser.h"
+#include "compiler.h"
+#include "rewriter.h"
+#include "tokenize.h"
+
+Node compileToLLL(std::string input) {
+ return rewrite(parseSerpent(input));
+}
+
+Node compileChunkToLLL(std::string input) {
+ return rewriteChunk(parseSerpent(input));
+}
+
+std::string compile(std::string input) {
+ return compileLLL(compileToLLL(input));
+}
+
+std::vector<Node> prettyCompile(std::string input) {
+ return prettyCompileLLL(compileToLLL(input));
+}
+
+std::string compileChunk(std::string input) {
+ return compileLLL(compileChunkToLLL(input));
+}
+
+std::vector<Node> prettyCompileChunk(std::string input) {
+ return prettyCompileLLL(compileChunkToLLL(input));
+}
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/funcs.h b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/funcs.h
new file mode 100644
index 000000000..d9bf44549
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/funcs.h
@@ -0,0 +1,35 @@
+#include <stdio.h>
+#include <iostream>
+#include <vector>
+#include "bignum.h"
+#include "util.h"
+#include "parser.h"
+#include "lllparser.h"
+#include "compiler.h"
+#include "rewriter.h"
+#include "tokenize.h"
+
+// Function listing:
+//
+// parseSerpent (serpent -> AST) std::string -> Node
+// parseLLL (LLL -> AST) std::string -> Node
+// rewrite (apply rewrite rules) Node -> Node
+// compileToLLL (serpent -> LLL) std::string -> Node
+// compileLLL (LLL -> EVMhex) Node -> std::string
+// prettyCompileLLL (LLL -> EVMasm) Node -> std::vector<Node>
+// prettyCompile (serpent -> EVMasm) std::string -> std::vector>Node>
+// compile (serpent -> EVMhex) std::string -> std::string
+// get_file_contents (filename -> file) std::string -> std::string
+// exists (does file exist?) std::string -> bool
+
+Node compileToLLL(std::string input);
+
+Node compileChunkToLLL(std::string input);
+
+std::string compile(std::string input);
+
+std::vector<Node> prettyCompile(std::string input);
+
+std::string compileChunk(std::string input);
+
+std::vector<Node> prettyCompileChunk(std::string input);
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/functions.cpp b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/functions.cpp
new file mode 100644
index 000000000..78e12e84a
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/functions.cpp
@@ -0,0 +1,203 @@
+#include <stdio.h>
+#include <iostream>
+#include <vector>
+#include <map>
+#include "util.h"
+#include "lllparser.h"
+#include "bignum.h"
+#include "optimize.h"
+#include "rewriteutils.h"
+#include "preprocess.h"
+#include "functions.h"
+
+std::string getSignature(std::vector<Node> args) {
+ std::string o;
+ for (unsigned i = 0; i < args.size(); i++) {
+ if (args[i].val == ":" && args[i].args[1].val == "s")
+ o += "s";
+ else if (args[i].val == ":" && args[i].args[1].val == "a")
+ o += "a";
+ else
+ o += "i";
+ }
+ return o;
+}
+
+// Convert a list of arguments into a node containing a
+// < datastart, datasz > pair
+
+Node packArguments(std::vector<Node> args, std::string sig,
+ int funId, Metadata m) {
+ // Plain old 32 byte arguments
+ std::vector<Node> nargs;
+ // Variable-sized arguments
+ std::vector<Node> vargs;
+ // Variable sizes
+ std::vector<Node> sizes;
+ // Is a variable an array?
+ std::vector<bool> isArray;
+ // Fill up above three argument lists
+ int argCount = 0;
+ for (unsigned i = 0; i < args.size(); i++) {
+ Metadata m = args[i].metadata;
+ if (args[i].val == "=") {
+ // do nothing
+ }
+ else {
+ // Determine the correct argument type
+ char argType;
+ if (sig.size() > 0) {
+ if (argCount >= (signed)sig.size())
+ err("Too many args", m);
+ argType = sig[argCount];
+ }
+ else argType = 'i';
+ // Integer (also usable for short strings)
+ if (argType == 'i') {
+ if (args[i].val == ":")
+ err("Function asks for int, provided string or array", m);
+ nargs.push_back(args[i]);
+ }
+ // Long string
+ else if (argType == 's') {
+ if (args[i].val != ":")
+ err("Must specify string length", m);
+ vargs.push_back(args[i].args[0]);
+ sizes.push_back(args[i].args[1]);
+ isArray.push_back(false);
+ }
+ // Array
+ else if (argType == 'a') {
+ if (args[i].val != ":")
+ err("Must specify array length", m);
+ vargs.push_back(args[i].args[0]);
+ sizes.push_back(args[i].args[1]);
+ isArray.push_back(true);
+ }
+ else err("Invalid arg type in signature", m);
+ argCount++;
+ }
+ }
+ int static_arg_size = 1 + (vargs.size() + nargs.size()) * 32;
+ // Start off by saving the size variables and calculating the total
+ msn kwargs;
+ kwargs["funid"] = tkn(utd(funId), m);
+ std::string pattern =
+ "(with _sztot "+utd(static_arg_size)+" "
+ " (with _sizes (alloc "+utd(sizes.size() * 32)+") "
+ " (seq ";
+ for (unsigned i = 0; i < sizes.size(); i++) {
+ std::string sizeIncrement =
+ isArray[i] ? "(mul 32 _x)" : "_x";
+ pattern +=
+ "(with _x $sz"+utd(i)+"(seq "
+ " (mstore (add _sizes "+utd(i * 32)+") _x) "
+ " (set _sztot (add _sztot "+sizeIncrement+" )))) ";
+ kwargs["sz"+utd(i)] = sizes[i];
+ }
+ // Allocate memory, and set first data byte
+ pattern +=
+ "(with _datastart (alloc (add _sztot 32)) (seq "
+ " (mstore8 _datastart $funid) ";
+ // Copy over size variables
+ for (unsigned i = 0; i < sizes.size(); i++) {
+ int v = 1 + i * 32;
+ pattern +=
+ " (mstore "
+ " (add _datastart "+utd(v)+") "
+ " (mload (add _sizes "+utd(v-1)+"))) ";
+ }
+ // Store normal arguments
+ for (unsigned i = 0; i < nargs.size(); i++) {
+ int v = 1 + (i + sizes.size()) * 32;
+ pattern +=
+ " (mstore (add _datastart "+utd(v)+") $"+utd(i)+") ";
+ kwargs[utd(i)] = nargs[i];
+ }
+ // Loop through variable-sized arguments, store them
+ pattern +=
+ " (with _pos (add _datastart "+utd(static_arg_size)+") (seq";
+ for (unsigned i = 0; i < vargs.size(); i++) {
+ std::string copySize =
+ isArray[i] ? "(mul 32 (mload (add _sizes "+utd(i * 32)+")))"
+ : "(mload (add _sizes "+utd(i * 32)+"))";
+ pattern +=
+ " (unsafe_mcopy _pos $vl"+utd(i)+" "+copySize+") "
+ " (set _pos (add _pos "+copySize+")) ";
+ kwargs["vl"+utd(i)] = vargs[i];
+ }
+ // Return a 2-item array containing the start and size
+ pattern += " (array_lit _datastart _sztot))))))))";
+ std::string prefix = "_temp_"+mkUniqueToken();
+ // Fill in pattern, return triple
+ return subst(parseLLL(pattern), kwargs, prefix, m);
+}
+
+// Create a node for argument unpacking
+Node unpackArguments(std::vector<Node> vars, Metadata m) {
+ std::vector<std::string> varNames;
+ std::vector<std::string> longVarNames;
+ std::vector<bool> longVarIsArray;
+ // Fill in variable and long variable names, as well as which
+ // long variables are arrays and which are strings
+ for (unsigned i = 0; i < vars.size(); i++) {
+ if (vars[i].val == ":") {
+ if (vars[i].args.size() != 2)
+ err("Malformed def!", m);
+ longVarNames.push_back(vars[i].args[0].val);
+ std::string tag = vars[i].args[1].val;
+ if (tag == "s")
+ longVarIsArray.push_back(false);
+ else if (tag == "a")
+ longVarIsArray.push_back(true);
+ else
+ err("Function value can only be string or array", m);
+ }
+ else {
+ varNames.push_back(vars[i].val);
+ }
+ }
+ std::vector<Node> sub;
+ if (!varNames.size() && !longVarNames.size()) {
+ // do nothing if we have no arguments
+ }
+ else {
+ std::vector<Node> varNodes;
+ for (unsigned i = 0; i < longVarNames.size(); i++)
+ varNodes.push_back(token(longVarNames[i], m));
+ for (unsigned i = 0; i < varNames.size(); i++)
+ varNodes.push_back(token(varNames[i], m));
+ // Copy over variable lengths and short variables
+ for (unsigned i = 0; i < varNodes.size(); i++) {
+ int pos = 1 + i * 32;
+ std::string prefix = (i < longVarNames.size()) ? "_len_" : "";
+ sub.push_back(asn("untyped", asn("set",
+ token(prefix+varNodes[i].val, m),
+ asn("calldataload", tkn(utd(pos), m), m),
+ m)));
+ }
+ // Copy over long variables
+ if (longVarNames.size() > 0) {
+ std::vector<Node> sub2;
+ int pos = varNodes.size() * 32 + 1;
+ Node tot = tkn("_tot", m);
+ for (unsigned i = 0; i < longVarNames.size(); i++) {
+ Node var = tkn(longVarNames[i], m);
+ Node varlen = longVarIsArray[i]
+ ? asn("mul", tkn("32", m), tkn("_len_"+longVarNames[i], m))
+ : tkn("_len_"+longVarNames[i], m);
+ sub2.push_back(asn("untyped",
+ asn("set", var, asn("alloc", varlen))));
+ sub2.push_back(asn("calldatacopy", var, tot, varlen));
+ sub2.push_back(asn("set", tot, asn("add", tot, varlen)));
+ }
+ std::string prefix = "_temp_"+mkUniqueToken();
+ sub.push_back(subst(
+ astnode("with", tot, tkn(utd(pos), m), asn("seq", sub2)),
+ msn(),
+ prefix,
+ m));
+ }
+ }
+ return asn("seq", sub, m);
+}
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/functions.h b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/functions.h
new file mode 100644
index 000000000..68a1c69ce
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/functions.h
@@ -0,0 +1,39 @@
+#ifndef ETHSERP_FUNCTIONS
+#define ETHSERP_FUNCTIONS
+
+#include <stdio.h>
+#include <iostream>
+#include <vector>
+#include <map>
+#include "util.h"
+#include "lllparser.h"
+#include "bignum.h"
+#include "optimize.h"
+#include "rewriteutils.h"
+#include "preprocess.h"
+
+
+class argPack {
+ public:
+ argPack(Node a, Node b, Node c) {
+ pre = a;
+ datastart = b;
+ datasz = c;
+ }
+ Node pre;
+ Node datastart;
+ Node datasz;
+};
+
+// Get a signature from a function
+std::string getSignature(std::vector<Node> args);
+
+// Convert a list of arguments into a <pre, mstart, msize> node
+// triple, given the signature of a function
+Node packArguments(std::vector<Node> args, std::string sig,
+ int funId, Metadata m);
+
+// Create a node for argument unpacking
+Node unpackArguments(std::vector<Node> vars, Metadata m);
+
+#endif
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/lllparser.cpp b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/lllparser.cpp
new file mode 100644
index 000000000..ad4fbd52d
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/lllparser.cpp
@@ -0,0 +1,70 @@
+#include <stdio.h>
+#include <iostream>
+#include <vector>
+#include <map>
+#include "util.h"
+#include "lllparser.h"
+#include "tokenize.h"
+
+struct _parseOutput {
+ Node node;
+ int newpos;
+};
+
+// Helper, returns subtree and position of start of next node
+_parseOutput _parse(std::vector<Node> inp, int pos) {
+ Metadata met = inp[pos].metadata;
+ _parseOutput o;
+ // Bracket: keep grabbing tokens until we get to the
+ // corresponding closing bracket
+ if (inp[pos].val == "(" || inp[pos].val == "[") {
+ std::string fun, rbrack;
+ std::vector<Node> args;
+ pos += 1;
+ if (inp[pos].val == "[") {
+ fun = "access";
+ rbrack = "]";
+ }
+ else rbrack = ")";
+ // First argument is the function
+ while (inp[pos].val != ")") {
+ _parseOutput po = _parse(inp, pos);
+ if (fun.length() == 0 && po.node.type == 1) {
+ std::cerr << "Error: first arg must be function\n";
+ fun = po.node.val;
+ }
+ else if (fun.length() == 0) {
+ fun = po.node.val;
+ }
+ else {
+ args.push_back(po.node);
+ }
+ pos = po.newpos;
+ }
+ o.newpos = pos + 1;
+ o.node = astnode(fun, args, met);
+ }
+ // Normal token, return it and advance to next token
+ else {
+ o.newpos = pos + 1;
+ o.node = token(inp[pos].val, met);
+ }
+ return o;
+}
+
+// stream of tokens -> lisp parse tree
+Node parseLLLTokenStream(std::vector<Node> inp) {
+ _parseOutput o = _parse(inp, 0);
+ return o.node;
+}
+
+// Parses LLL
+Node parseLLL(std::string s, bool allowFileRead) {
+ std::string input = s;
+ std::string file = "main";
+ if (exists(s) && allowFileRead) {
+ file = s;
+ input = get_file_contents(s);
+ }
+ return parseLLLTokenStream(tokenize(s, Metadata(file, 0, 0), true));
+}
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/lllparser.h b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/lllparser.h
new file mode 100644
index 000000000..4bfa7b82e
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/lllparser.h
@@ -0,0 +1,13 @@
+#ifndef ETHSERP_LLLPARSER
+#define ETHSERP_LLLPARSER
+
+#include <stdio.h>
+#include <iostream>
+#include <vector>
+#include <map>
+#include "util.h"
+
+// LLL text -> parse tree
+Node parseLLL(std::string s, bool allowFileRead=false);
+
+#endif
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/opcodes.cpp b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/opcodes.cpp
new file mode 100644
index 000000000..b24144e46
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/opcodes.cpp
@@ -0,0 +1,154 @@
+#include <stdio.h>
+#include <iostream>
+#include <vector>
+#include <map>
+#include "opcodes.h"
+#include "util.h"
+#include "bignum.h"
+
+Mapping mapping[] = {
+ Mapping("STOP", 0x00, 0, 0),
+ Mapping("ADD", 0x01, 2, 1),
+ Mapping("MUL", 0x02, 2, 1),
+ Mapping("SUB", 0x03, 2, 1),
+ Mapping("DIV", 0x04, 2, 1),
+ Mapping("SDIV", 0x05, 2, 1),
+ Mapping("MOD", 0x06, 2, 1),
+ Mapping("SMOD", 0x07, 2, 1),
+ Mapping("ADDMOD", 0x08, 3, 1),
+ Mapping("MULMOD", 0x09, 3, 1),
+ Mapping("EXP", 0x0a, 2, 1),
+ Mapping("SIGNEXTEND", 0x0b, 2, 1),
+ Mapping("LT", 0x10, 2, 1),
+ Mapping("GT", 0x11, 2, 1),
+ Mapping("SLT", 0x12, 2, 1),
+ Mapping("SGT", 0x13, 2, 1),
+ Mapping("EQ", 0x14, 2, 1),
+ Mapping("ISZERO", 0x15, 1, 1),
+ Mapping("AND", 0x16, 2, 1),
+ Mapping("OR", 0x17, 2, 1),
+ Mapping("XOR", 0x18, 2, 1),
+ Mapping("NOT", 0x19, 1, 1),
+ Mapping("BYTE", 0x1a, 2, 1),
+ Mapping("SHA3", 0x20, 2, 1),
+ Mapping("ADDRESS", 0x30, 0, 1),
+ Mapping("BALANCE", 0x31, 1, 1),
+ Mapping("ORIGIN", 0x32, 0, 1),
+ Mapping("CALLER", 0x33, 0, 1),
+ Mapping("CALLVALUE", 0x34, 0, 1),
+ Mapping("CALLDATALOAD", 0x35, 1, 1),
+ Mapping("CALLDATASIZE", 0x36, 0, 1),
+ Mapping("CALLDATACOPY", 0x37, 3, 0),
+ Mapping("CODESIZE", 0x38, 0, 1),
+ Mapping("CODECOPY", 0x39, 3, 0),
+ Mapping("GASPRICE", 0x3a, 0, 1),
+ Mapping("EXTCODESIZE", 0x3b, 1, 1),
+ Mapping("EXTCODECOPY", 0x3c, 4, 0),
+ Mapping("PREVHASH", 0x40, 0, 1),
+ Mapping("COINBASE", 0x41, 0, 1),
+ Mapping("TIMESTAMP", 0x42, 0, 1),
+ Mapping("NUMBER", 0x43, 0, 1),
+ Mapping("DIFFICULTY", 0x44, 0, 1),
+ Mapping("GASLIMIT", 0x45, 0, 1),
+ Mapping("POP", 0x50, 1, 0),
+ Mapping("MLOAD", 0x51, 1, 1),
+ Mapping("MSTORE", 0x52, 2, 0),
+ Mapping("MSTORE8", 0x53, 2, 0),
+ Mapping("SLOAD", 0x54, 1, 1),
+ Mapping("SSTORE", 0x55, 2, 0),
+ Mapping("JUMP", 0x56, 1, 0),
+ Mapping("JUMPI", 0x57, 2, 0),
+ Mapping("PC", 0x58, 0, 1),
+ Mapping("MSIZE", 0x59, 0, 1),
+ Mapping("GAS", 0x5a, 0, 1),
+ Mapping("JUMPDEST", 0x5b, 0, 0),
+ Mapping("LOG0", 0xa0, 2, 0),
+ Mapping("LOG1", 0xa1, 3, 0),
+ Mapping("LOG2", 0xa2, 4, 0),
+ Mapping("LOG3", 0xa3, 5, 0),
+ Mapping("LOG4", 0xa4, 6, 0),
+ Mapping("CREATE", 0xf0, 3, 1),
+ Mapping("CALL", 0xf1, 7, 1),
+ Mapping("CALLCODE", 0xf2, 7, 1),
+ Mapping("RETURN", 0xf3, 2, 0),
+ Mapping("SUICIDE", 0xff, 1, 0),
+ Mapping("---END---", 0x00, 0, 0),
+};
+
+std::map<std::string, std::vector<int> > opcodes;
+std::map<int, std::string> reverseOpcodes;
+
+// Fetches everything EXCEPT PUSH1..32
+std::pair<std::string, std::vector<int> > _opdata(std::string ops, int opi) {
+ if (!opcodes.size()) {
+ int i = 0;
+ while (mapping[i].op != "---END---") {
+ Mapping mi = mapping[i];
+ opcodes[mi.op] = triple(mi.opcode, mi.in, mi.out);
+ i++;
+ }
+ for (i = 1; i <= 16; i++) {
+ opcodes["DUP"+unsignedToDecimal(i)] = triple(0x7f + i, i, i+1);
+ opcodes["SWAP"+unsignedToDecimal(i)] = triple(0x8f + i, i+1, i+1);
+ }
+ for (std::map<std::string, std::vector<int> >::iterator it=opcodes.begin();
+ it != opcodes.end();
+ it++) {
+ reverseOpcodes[(*it).second[0]] = (*it).first;
+ }
+ }
+ ops = upperCase(ops);
+ std::string op;
+ std::vector<int> opdata;
+ op = reverseOpcodes.count(opi) ? reverseOpcodes[opi] : "";
+ opdata = opcodes.count(ops) ? opcodes[ops] : triple(-1, -1, -1);
+ return std::pair<std::string, std::vector<int> >(op, opdata);
+}
+
+int opcode(std::string op) {
+ return _opdata(op, -1).second[0];
+}
+
+int opinputs(std::string op) {
+ return _opdata(op, -1).second[1];
+}
+
+int opoutputs(std::string op) {
+ return _opdata(op, -1).second[2];
+}
+
+std::string op(int opcode) {
+ return _opdata("", opcode).first;
+}
+
+std::string lllSpecials[][3] = {
+ { "ref", "1", "1" },
+ { "get", "1", "1" },
+ { "set", "2", "2" },
+ { "with", "3", "3" },
+ { "comment", "0", "2147483647" },
+ { "ops", "0", "2147483647" },
+ { "lll", "2", "2" },
+ { "seq", "0", "2147483647" },
+ { "if", "3", "3" },
+ { "unless", "2", "2" },
+ { "until", "2", "2" },
+ { "alloc", "1", "1" },
+ { "---END---", "0", "0" },
+};
+
+std::map<std::string, std::pair<int, int> > lllMap;
+
+// Is a function name one of the valid functions above?
+bool isValidLLLFunc(std::string f, int argc) {
+ if (lllMap.size() == 0) {
+ for (int i = 0; ; i++) {
+ if (lllSpecials[i][0] == "---END---") break;
+ lllMap[lllSpecials[i][0]] = std::pair<int, int>(
+ dtu(lllSpecials[i][1]), dtu(lllSpecials[i][2]));
+ }
+ }
+ return lllMap.count(f)
+ && argc >= lllMap[f].first
+ && argc <= lllMap[f].second;
+}
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/opcodes.h b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/opcodes.h
new file mode 100644
index 000000000..41423c169
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/opcodes.h
@@ -0,0 +1,45 @@
+#ifndef ETHSERP_OPCODES
+#define ETHSERP_OPCODES
+
+#include <stdio.h>
+#include <iostream>
+#include <vector>
+#include <map>
+#include "util.h"
+
+class Mapping {
+ public:
+ Mapping(std::string Op, int Opcode, int In, int Out) {
+ op = Op;
+ opcode = Opcode;
+ in = In;
+ out = Out;
+ }
+ std::string op;
+ int opcode;
+ int in;
+ int out;
+};
+
+extern Mapping mapping[];
+
+extern std::map<std::string, std::vector<int> > opcodes;
+extern std::map<int, std::string> reverseOpcodes;
+
+std::pair<std::string, std::vector<int> > _opdata(std::string ops, int opi);
+
+int opcode(std::string op);
+
+int opinputs(std::string op);
+
+int opoutputs(std::string op);
+
+std::string op(int opcode);
+
+extern std::string lllSpecials[][3];
+
+extern std::map<std::string, std::pair<int, int> > lllMap;
+
+bool isValidLLLFunc(std::string f, int argc);
+
+#endif
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/optimize.cpp b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/optimize.cpp
new file mode 100644
index 000000000..e689fcb69
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/optimize.cpp
@@ -0,0 +1,98 @@
+#include <stdio.h>
+#include <iostream>
+#include <vector>
+#include <map>
+#include "util.h"
+#include "lllparser.h"
+#include "bignum.h"
+
+// Compile-time arithmetic calculations
+Node optimize(Node inp) {
+ if (inp.type == TOKEN) {
+ Node o = tryNumberize(inp);
+ if (decimalGt(o.val, tt256, true))
+ err("Value too large (exceeds 32 bytes or 2^256)", inp.metadata);
+ return o;
+ }
+ for (unsigned i = 0; i < inp.args.size(); i++) {
+ inp.args[i] = optimize(inp.args[i]);
+ }
+ // Arithmetic-specific transform
+ if (inp.val == "+") inp.val = "add";
+ if (inp.val == "*") inp.val = "mul";
+ if (inp.val == "-") inp.val = "sub";
+ if (inp.val == "/") inp.val = "sdiv";
+ if (inp.val == "^") inp.val = "exp";
+ if (inp.val == "**") inp.val = "exp";
+ if (inp.val == "%") inp.val = "smod";
+ // Degenerate cases for add and mul
+ if (inp.args.size() == 2) {
+ if (inp.val == "add" && inp.args[0].type == TOKEN &&
+ inp.args[0].val == "0") {
+ Node x = inp.args[1];
+ inp = x;
+ }
+ if (inp.val == "add" && inp.args[1].type == TOKEN &&
+ inp.args[1].val == "0") {
+ Node x = inp.args[0];
+ inp = x;
+ }
+ if (inp.val == "mul" && inp.args[0].type == TOKEN &&
+ inp.args[0].val == "1") {
+ Node x = inp.args[1];
+ inp = x;
+ }
+ if (inp.val == "mul" && inp.args[1].type == TOKEN &&
+ inp.args[1].val == "1") {
+ Node x = inp.args[0];
+ inp = x;
+ }
+ }
+ // Arithmetic computation
+ if (inp.args.size() == 2
+ && inp.args[0].type == TOKEN
+ && inp.args[1].type == TOKEN) {
+ std::string o;
+ if (inp.val == "add") {
+ o = decimalMod(decimalAdd(inp.args[0].val, inp.args[1].val), tt256);
+ }
+ else if (inp.val == "sub") {
+ if (decimalGt(inp.args[0].val, inp.args[1].val, true))
+ o = decimalSub(inp.args[0].val, inp.args[1].val);
+ }
+ else if (inp.val == "mul") {
+ o = decimalMod(decimalMul(inp.args[0].val, inp.args[1].val), tt256);
+ }
+ else if (inp.val == "div" && inp.args[1].val != "0") {
+ o = decimalDiv(inp.args[0].val, inp.args[1].val);
+ }
+ else if (inp.val == "sdiv" && inp.args[1].val != "0"
+ && decimalGt(tt255, inp.args[0].val)
+ && decimalGt(tt255, inp.args[1].val)) {
+ o = decimalDiv(inp.args[0].val, inp.args[1].val);
+ }
+ else if (inp.val == "mod" && inp.args[1].val != "0") {
+ o = decimalMod(inp.args[0].val, inp.args[1].val);
+ }
+ else if (inp.val == "smod" && inp.args[1].val != "0"
+ && decimalGt(tt255, inp.args[0].val)
+ && decimalGt(tt255, inp.args[1].val)) {
+ o = decimalMod(inp.args[0].val, inp.args[1].val);
+ }
+ else if (inp.val == "exp") {
+ o = decimalModExp(inp.args[0].val, inp.args[1].val, tt256);
+ }
+ if (o.length()) return token(o, inp.metadata);
+ }
+ return inp;
+}
+
+// Is a node degenerate (ie. trivial to calculate) ?
+bool isDegenerate(Node n) {
+ return optimize(n).type == TOKEN;
+}
+
+// Is a node purely arithmetic?
+bool isPureArithmetic(Node n) {
+ return isNumberLike(optimize(n));
+}
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/optimize.h b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/optimize.h
new file mode 100644
index 000000000..06ea3bba1
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/optimize.h
@@ -0,0 +1,19 @@
+#ifndef ETHSERP_OPTIMIZER
+#define ETHSERP_OPTIMIZER
+
+#include <stdio.h>
+#include <iostream>
+#include <vector>
+#include <map>
+#include "util.h"
+
+// Compile-time arithmetic calculations
+Node optimize(Node inp);
+
+// Is a node degenerate (ie. trivial to calculate) ?
+bool isDegenerate(Node n);
+
+// Is a node purely arithmetic?
+bool isPureArithmetic(Node n);
+
+#endif
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/parser.cpp b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/parser.cpp
new file mode 100644
index 000000000..5e8c459c3
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/parser.cpp
@@ -0,0 +1,430 @@
+#include <stdio.h>
+#include <iostream>
+#include <vector>
+#include <map>
+#include "util.h"
+#include "parser.h"
+#include "tokenize.h"
+
+// Extended BEDMAS precedence order
+int precedence(Node tok) {
+ std::string v = tok.val;
+ if (v == ".") return -1;
+ else if (v == "!" || v == "not") return 1;
+ else if (v=="^" || v == "**") return 2;
+ else if (v=="*" || v=="/" || v=="%") return 3;
+ else if (v=="+" || v=="-") return 4;
+ else if (v=="<" || v==">" || v=="<=" || v==">=") return 5;
+ else if (v=="&" || v=="|" || v=="xor" || v=="==" || v == "!=") return 6;
+ else if (v=="&&" || v=="and") return 7;
+ else if (v=="||" || v=="or") return 8;
+ else if (v=="=") return 10;
+ else if (v=="+=" || v=="-=" || v=="*=" || v=="/=" || v=="%=") return 10;
+ else if (v==":" || v == "::") return 11;
+ else return 0;
+}
+
+// Token classification for shunting-yard purposes
+int toktype(Node tok) {
+ if (tok.type == ASTNODE) return COMPOUND;
+ std::string v = tok.val;
+ if (v == "(" || v == "[" || v == "{") return LPAREN;
+ else if (v == ")" || v == "]" || v == "}") return RPAREN;
+ else if (v == ",") return COMMA;
+ else if (v == "!" || v == "~" || v == "not") return UNARY_OP;
+ else if (precedence(tok) > 0) return BINARY_OP;
+ else if (precedence(tok) < 0) return TOKEN_SPLITTER;
+ if (tok.val[0] != '"' && tok.val[0] != '\'') {
+ for (unsigned i = 0; i < tok.val.length(); i++) {
+ if (chartype(tok.val[i]) == SYMB) {
+ err("Invalid symbol: "+tok.val, tok.metadata);
+ }
+ }
+ }
+ return ALPHANUM;
+}
+
+
+// Converts to reverse polish notation
+std::vector<Node> shuntingYard(std::vector<Node> tokens) {
+ std::vector<Node> iq;
+ for (int i = tokens.size() - 1; i >= 0; i--) {
+ iq.push_back(tokens[i]);
+ }
+ std::vector<Node> oq;
+ std::vector<Node> stack;
+ Node prev, tok;
+ int prevtyp = 0, toktyp = 0;
+
+ while (iq.size()) {
+ prev = tok;
+ prevtyp = toktyp;
+ tok = iq.back();
+ toktyp = toktype(tok);
+ iq.pop_back();
+ // Alphanumerics go straight to output queue
+ if (toktyp == ALPHANUM) {
+ oq.push_back(tok);
+ }
+ // Left parens go on stack and output queue
+ else if (toktyp == LPAREN) {
+ while (stack.size() && toktype(stack.back()) == TOKEN_SPLITTER) {
+ oq.push_back(stack.back());
+ stack.pop_back();
+ }
+ if (prevtyp != ALPHANUM && prevtyp != RPAREN) {
+ oq.push_back(token("id", tok.metadata));
+ }
+ stack.push_back(tok);
+ oq.push_back(tok);
+ }
+ // If rparen, keep moving from stack to output queue until lparen
+ else if (toktyp == RPAREN) {
+ while (stack.size() && toktype(stack.back()) != LPAREN) {
+ oq.push_back(stack.back());
+ stack.pop_back();
+ }
+ if (stack.size()) {
+ stack.pop_back();
+ }
+ oq.push_back(tok);
+ }
+ else if (toktyp == UNARY_OP) {
+ stack.push_back(tok);
+ }
+ // If token splitter, just push it to the stack
+ else if (toktyp == TOKEN_SPLITTER) {
+ while (stack.size() && toktype(stack.back()) == TOKEN_SPLITTER) {
+ oq.push_back(stack.back());
+ stack.pop_back();
+ }
+ stack.push_back(tok);
+ }
+ // If binary op, keep popping from stack while higher bedmas precedence
+ else if (toktyp == BINARY_OP) {
+ if (tok.val == "-" && prevtyp != ALPHANUM && prevtyp != RPAREN) {
+ stack.push_back(tok);
+ oq.push_back(token("0", tok.metadata));
+ }
+ else {
+ int prec = precedence(tok);
+ while (stack.size()
+ && (toktype(stack.back()) == BINARY_OP
+ || toktype(stack.back()) == UNARY_OP
+ || toktype(stack.back()) == TOKEN_SPLITTER)
+ && precedence(stack.back()) <= prec) {
+ oq.push_back(stack.back());
+ stack.pop_back();
+ }
+ stack.push_back(tok);
+ }
+ }
+ // Comma means finish evaluating the argument
+ else if (toktyp == COMMA) {
+ while (stack.size() && toktype(stack.back()) != LPAREN) {
+ oq.push_back(stack.back());
+ stack.pop_back();
+ }
+ }
+ }
+ while (stack.size()) {
+ oq.push_back(stack.back());
+ stack.pop_back();
+ }
+ return oq;
+}
+
+// Converts reverse polish notation into tree
+Node treefy(std::vector<Node> stream) {
+ std::vector<Node> iq;
+ for (int i = stream.size() -1; i >= 0; i--) {
+ iq.push_back(stream[i]);
+ }
+ std::vector<Node> oq;
+ while (iq.size()) {
+ Node tok = iq.back();
+ iq.pop_back();
+ int typ = toktype(tok);
+ // If unary, take node off end of oq and wrap it with the operator
+ // If binary, do the same with two nodes
+ if (typ == UNARY_OP || typ == BINARY_OP || typ == TOKEN_SPLITTER) {
+ std::vector<Node> args;
+ int rounds = (typ == UNARY_OP) ? 1 : 2;
+ for (int i = 0; i < rounds; i++) {
+ if (oq.size() == 0) {
+ err("Line malformed, not enough args for "+tok.val,
+ tok.metadata);
+ }
+ args.push_back(oq.back());
+ oq.pop_back();
+ }
+ std::vector<Node> args2;
+ while (args.size()) {
+ args2.push_back(args.back());
+ args.pop_back();
+ }
+ oq.push_back(astnode(tok.val, args2, tok.metadata));
+ }
+ // If rparen, keep grabbing until we get to an lparen
+ else if (typ == RPAREN) {
+ std::vector<Node> args;
+ while (1) {
+ if (toktype(oq.back()) == LPAREN) break;
+ args.push_back(oq.back());
+ oq.pop_back();
+ if (!oq.size()) err("Bracket without matching", tok.metadata);
+ }
+ oq.pop_back();
+ args.push_back(oq.back());
+ oq.pop_back();
+ // We represent a[b] as (access a b)
+ if (tok.val == "]")
+ args.push_back(token("access", tok.metadata));
+ if (args.back().type == ASTNODE)
+ args.push_back(token("fun", tok.metadata));
+ std::string fun = args.back().val;
+ args.pop_back();
+ // We represent [1,2,3] as (array_lit 1 2 3)
+ if (fun == "access" && args.size() && args.back().val == "id") {
+ fun = "array_lit";
+ args.pop_back();
+ }
+ std::vector<Node> args2;
+ while (args.size()) {
+ args2.push_back(args.back());
+ args.pop_back();
+ }
+ // When evaluating 2 + (3 * 5), the shunting yard algo turns that
+ // into 2 ( id 3 5 * ) +, effectively putting "id" as a dummy
+ // function where the algo was expecting a function to call the
+ // thing inside the brackets. This reverses that step
+ if (fun == "id" && args2.size() == 1) {
+ oq.push_back(args2[0]);
+ }
+ else {
+ oq.push_back(astnode(fun, args2, tok.metadata));
+ }
+ }
+ else oq.push_back(tok);
+ // This is messy, but has to be done. Import/inset other files here
+ std::string v = oq.back().val;
+ if ((v == "inset" || v == "import" || v == "create")
+ && oq.back().args.size() == 1
+ && oq.back().args[0].type == TOKEN) {
+ int lastSlashPos = tok.metadata.file.rfind("/");
+ std::string root;
+ if (lastSlashPos >= 0)
+ root = tok.metadata.file.substr(0, lastSlashPos) + "/";
+ else
+ root = "";
+ std::string filename = oq.back().args[0].val;
+ filename = filename.substr(1, filename.length() - 2);
+ if (!exists(root + filename))
+ err("File does not exist: "+root + filename, tok.metadata);
+ oq.back().args.pop_back();
+ oq.back().args.push_back(parseSerpent(root + filename));
+ }
+ //Useful for debugging
+ //for (int i = 0; i < oq.size(); i++) {
+ // std::cerr << printSimple(oq[i]) << " ";
+ //}
+ //std::cerr << " <-\n";
+ }
+ // Output must have one argument
+ if (oq.size() == 0) {
+ err("Output blank", Metadata());
+ }
+ else if (oq.size() > 1) {
+ return asn("multi", oq, oq[0].metadata);
+ }
+
+ return oq[0];
+}
+
+
+// Parses one line of serpent
+Node parseSerpentTokenStream(std::vector<Node> s) {
+ return treefy(shuntingYard(s));
+}
+
+
+// Count spaces at beginning of line
+int spaceCount(std::string s) {
+ unsigned pos = 0;
+ while (pos < s.length() && (s[pos] == ' ' || s[pos] == '\t'))
+ pos++;
+ return pos;
+}
+
+// Is this a command that takes an argument on the same line?
+bool bodied(std::string tok) {
+ return tok == "if" || tok == "elif" || tok == "while"
+ || tok == "with" || tok == "def" || tok == "extern"
+ || tok == "data" || tok == "assert" || tok == "return"
+ || tok == "fun" || tok == "scope" || tok == "macro"
+ || tok == "type";
+}
+
+// Are the two commands meant to continue each other?
+bool bodiedContinued(std::string prev, std::string tok) {
+ return (prev == "if" && tok == "elif")
+ || (prev == "elif" && tok == "else")
+ || (prev == "elif" && tok == "elif")
+ || (prev == "if" && tok == "else");
+}
+
+// Is a line of code empty?
+bool isLineEmpty(std::string line) {
+ std::vector<Node> tokens = tokenize(line);
+ if (!tokens.size() || tokens[0].val == "#" || tokens[0].val == "//")
+ return true;
+ return false;
+}
+
+// Parse lines of serpent (helper function)
+Node parseLines(std::vector<std::string> lines, Metadata metadata, int sp) {
+ std::vector<Node> o;
+ int origLine = metadata.ln;
+ unsigned i = 0;
+ while (i < lines.size()) {
+ metadata.ln = origLine + i;
+ std::string main = lines[i];
+ if (isLineEmpty(main)) {
+ i += 1;
+ continue;
+ }
+ int spaces = spaceCount(main);
+ if (spaces != sp) {
+ err("Indent mismatch", metadata);
+ }
+ // Tokenize current line
+ std::vector<Node> tokens = tokenize(main.substr(sp), metadata);
+ // Remove comments
+ std::vector<Node> tokens2;
+ for (unsigned j = 0; j < tokens.size(); j++) {
+ if (tokens[j].val == "#" || tokens[j].val == "//") break;
+ tokens2.push_back(tokens[j]);
+ }
+ bool expectingChildBlock = false;
+ if (tokens2.size() > 0 && tokens2.back().val == ":") {
+ tokens2.pop_back();
+ expectingChildBlock = true;
+ }
+ // Parse current line
+ Node out = parseSerpentTokenStream(tokens2);
+ // Parse child block
+ int childIndent = 999999;
+ std::vector<std::string> childBlock;
+ while (1) {
+ i++;
+ if (i >= lines.size())
+ break;
+ bool ile = isLineEmpty(lines[i]);
+ if (!ile) {
+ int spaces = spaceCount(lines[i]);
+ if (spaces <= sp) break;
+ childBlock.push_back(lines[i]);
+ if (spaces < childIndent) childIndent = spaces;
+ }
+ else childBlock.push_back("");
+ }
+ // Child block empty?
+ bool cbe = true;
+ for (unsigned i = 0; i < childBlock.size(); i++) {
+ if (childBlock[i].length() > 0) { cbe = false; break; }
+ }
+ // Add child block to AST
+ if (expectingChildBlock) {
+ if (cbe)
+ err("Expected indented child block!", out.metadata);
+ out.type = ASTNODE;
+ metadata.ln += 1;
+ out.args.push_back(parseLines(childBlock, metadata, childIndent));
+ metadata.ln -= 1;
+ }
+ else if (!cbe)
+ err("Did not expect indented child block!", out.metadata);
+ else if (out.args.size() && out.args[out.args.size() - 1].val == ":") {
+ Node n = out.args[out.args.size() - 1];
+ out.args.pop_back();
+ out.args.push_back(n.args[0]);
+ out.args.push_back(n.args[1]);
+ }
+ // Bring back if / elif into AST
+ if (bodied(tokens[0].val)) {
+ if (out.val != "multi") {
+ // token not being used in bodied form
+ }
+ else if (out.args[0].val == "id")
+ out = astnode(tokens[0].val, out.args[1].args, out.metadata);
+ else if (out.args[0].type == TOKEN) {
+ std::vector<Node> out2;
+ for (unsigned i = 1; i < out.args.size(); i++)
+ out2.push_back(out.args[i]);
+ out = astnode(tokens[0].val, out2, out.metadata);
+ }
+ else
+ out = astnode("fun", out.args, out.metadata);
+ }
+ // Multi not supported
+ if (out.val == "multi")
+ err("Multiple expressions or unclosed bracket", out.metadata);
+ // Convert top-level colon expressions into non-colon expressions;
+ // makes if statements and the like equivalent indented or not
+ //if (out.val == ":" && out.args[0].type == TOKEN)
+ // out = asn(out.args[0].val, out.args[1], out.metadata);
+ //if (bodied(tokens[0].val) && out.args[0].val == ":")
+ // out = asn(tokens[0].val, out.args[0].args);
+ if (o.size() == 0 || o.back().type == TOKEN) {
+ o.push_back(out);
+ continue;
+ }
+ // This is a little complicated. Basically, the idea here is to build
+ // constructions like [if [< x 5] [a] [elif [< x 10] [b] [else [c]]]]
+ std::vector<Node> u;
+ u.push_back(o.back());
+ if (bodiedContinued(o.back().val, out.val)) {
+ while (1) {
+ if (!bodiedContinued(u.back().val, out.val)) {
+ u.pop_back();
+ break;
+ }
+ if (!u.back().args.size()
+ || !bodiedContinued(u.back().val, u.back().args.back().val)) {
+ break;
+ }
+ u.push_back(u.back().args.back());
+ }
+ u.back().args.push_back(out);
+ while (u.size() > 1) {
+ Node v = u.back();
+ u.pop_back();
+ u.back().args.pop_back();
+ u.back().args.push_back(v);
+ }
+ o.pop_back();
+ o.push_back(u[0]);
+ }
+ else o.push_back(out);
+ }
+ if (o.size() == 1)
+ return o[0];
+ else if (o.size())
+ return astnode("seq", o, o[0].metadata);
+ else
+ return astnode("seq", o, Metadata());
+}
+
+// Parses serpent code
+Node parseSerpent(std::string s) {
+ std::string input = s;
+ std::string file = "main";
+ if (exists(s)) {
+ file = s;
+ input = get_file_contents(s);
+ }
+ return parseLines(splitLines(input), Metadata(file, 0, 0), 0);
+}
+
+
+using namespace std;
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/parser.h b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/parser.h
new file mode 100644
index 000000000..e3632220a
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/parser.h
@@ -0,0 +1,13 @@
+#ifndef ETHSERP_PARSER
+#define ETHSERP_PARSER
+
+#include <stdio.h>
+#include <iostream>
+#include <vector>
+#include <map>
+#include "util.h"
+
+// Serpent text -> parse tree
+Node parseSerpent(std::string s);
+
+#endif
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/preprocess.cpp b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/preprocess.cpp
new file mode 100644
index 000000000..3f08ea8b1
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/preprocess.cpp
@@ -0,0 +1,299 @@
+#include <stdio.h>
+#include <iostream>
+#include <vector>
+#include <map>
+#include "util.h"
+#include "lllparser.h"
+#include "bignum.h"
+#include "rewriteutils.h"
+#include "optimize.h"
+#include "preprocess.h"
+#include "functions.h"
+#include "opcodes.h"
+
+// Convert a function of the form (def (f x y z) (do stuff)) into
+// (if (first byte of ABI is correct) (seq (setup x y z) (do stuff)))
+Node convFunction(Node node, int functionCount) {
+ std::string prefix = "_temp"+mkUniqueToken()+"_";
+ Metadata m = node.metadata;
+
+ if (node.args.size() != 2)
+ err("Malformed def!", m);
+ // Collect the list of variable names and variable byte counts
+ Node unpack = unpackArguments(node.args[0].args, m);
+ // And the actual code
+ Node body = node.args[1];
+ // Main LLL-based function body
+ return astnode("if",
+ astnode("eq",
+ astnode("get", token("__funid", m), m),
+ token(unsignedToDecimal(functionCount), m),
+ m),
+ astnode("seq", unpack, body, m));
+}
+
+// Populate an svObj with the arguments needed to determine
+// the storage position of a node
+svObj getStorageVars(svObj pre, Node node, std::string prefix,
+ int index) {
+ Metadata m = node.metadata;
+ if (!pre.globalOffset.size()) pre.globalOffset = "0";
+ std::vector<Node> h;
+ std::vector<std::string> coefficients;
+ // Array accesses or atoms
+ if (node.val == "access" || node.type == TOKEN) {
+ std::string tot = "1";
+ h = listfyStorageAccess(node);
+ coefficients.push_back("1");
+ for (unsigned i = h.size() - 1; i >= 1; i--) {
+ // Array sizes must be constant or at least arithmetically
+ // evaluable at compile time
+ if (!isPureArithmetic(h[i]))
+ err("Array size must be fixed value", m);
+ // Create a list of the coefficient associated with each
+ // array index
+ coefficients.push_back(decimalMul(coefficients.back(), h[i].val));
+ }
+ }
+ // Tuples
+ else {
+ int startc;
+ // Handle the (fun <fun_astnode> args...) case
+ if (node.val == "fun") {
+ startc = 1;
+ h = listfyStorageAccess(node.args[0]);
+ }
+ // Handle the (<fun_name> args...) case, which
+ // the serpent parser produces when the function
+ // is a simple name and not a complex astnode
+ else {
+ startc = 0;
+ h = listfyStorageAccess(token(node.val, m));
+ }
+ svObj sub = pre;
+ sub.globalOffset = "0";
+ // Evaluate tuple elements recursively
+ for (unsigned i = startc; i < node.args.size(); i++) {
+ sub = getStorageVars(sub,
+ node.args[i],
+ prefix+h[0].val.substr(2)+".",
+ i-startc);
+ }
+ coefficients.push_back(sub.globalOffset);
+ for (unsigned i = h.size() - 1; i >= 1; i--) {
+ // Array sizes must be constant or at least arithmetically
+ // evaluable at compile time
+ if (!isPureArithmetic(h[i]))
+ err("Array size must be fixed value", m);
+ // Create a list of the coefficient associated with each
+ // array index
+ coefficients.push_back(decimalMul(coefficients.back(), h[i].val));
+ }
+ pre.offsets = sub.offsets;
+ pre.coefficients = sub.coefficients;
+ pre.nonfinal = sub.nonfinal;
+ pre.nonfinal[prefix+h[0].val.substr(2)] = true;
+ }
+ pre.coefficients[prefix+h[0].val.substr(2)] = coefficients;
+ pre.offsets[prefix+h[0].val.substr(2)] = pre.globalOffset;
+ pre.indices[prefix+h[0].val.substr(2)] = index;
+ if (decimalGt(tt176, coefficients.back()))
+ pre.globalOffset = decimalAdd(pre.globalOffset, coefficients.back());
+ return pre;
+}
+
+// Preprocess input containing functions
+//
+// localExterns is a map of the form, eg,
+//
+// { x: { foo: 0, bar: 1, baz: 2 }, y: { qux: 0, foo: 1 } ... }
+//
+// localExternSigs is a map of the form, eg,
+//
+// { x : { foo: iii, bar: iis, baz: ia }, y: { qux: i, foo: as } ... }
+//
+// Signifying that x.foo = 0, x.baz = 2, y.foo = 1, etc
+// and that x.foo has three integers as arguments, x.bar has two
+// integers and a variable-length string, and baz has an integer
+// and an array
+//
+// globalExterns is a one-level map, eg from above
+//
+// { foo: 1, bar: 1, baz: 2, qux: 0 }
+//
+// globalExternSigs is a one-level map, eg from above
+//
+// { foo: as, bar: iis, baz: ia, qux: i}
+//
+// Note that globalExterns and globalExternSigs may be ambiguous
+// Also, a null signature implies an infinite tail of integers
+preprocessResult preprocessInit(Node inp) {
+ Metadata m = inp.metadata;
+ if (inp.val != "seq")
+ inp = astnode("seq", inp, m);
+ std::vector<Node> empty = std::vector<Node>();
+ Node init = astnode("seq", empty, m);
+ Node shared = astnode("seq", empty, m);
+ std::vector<Node> any;
+ std::vector<Node> functions;
+ preprocessAux out = preprocessAux();
+ out.localExterns["self"] = std::map<std::string, int>();
+ int functionCount = 0;
+ int storageDataCount = 0;
+ for (unsigned i = 0; i < inp.args.size(); i++) {
+ Node obj = inp.args[i];
+ // Functions
+ if (obj.val == "def") {
+ if (obj.args.size() == 0)
+ err("Empty def", m);
+ std::string funName = obj.args[0].val;
+ // Init, shared and any are special functions
+ if (funName == "init" || funName == "shared" || funName == "any") {
+ if (obj.args[0].args.size())
+ err(funName+" cannot have arguments", m);
+ }
+ if (funName == "init") init = obj.args[1];
+ else if (funName == "shared") shared = obj.args[1];
+ else if (funName == "any") any.push_back(obj.args[1]);
+ else {
+ // Other functions
+ functions.push_back(convFunction(obj, functionCount));
+ out.localExterns["self"][obj.args[0].val] = functionCount;
+ out.localExternSigs["self"][obj.args[0].val]
+ = getSignature(obj.args[0].args);
+ functionCount++;
+ }
+ }
+ // Extern declarations
+ else if (obj.val == "extern") {
+ std::string externName = obj.args[0].val;
+ Node al = obj.args[1];
+ if (!out.localExterns.count(externName))
+ out.localExterns[externName] = std::map<std::string, int>();
+ for (unsigned i = 0; i < al.args.size(); i++) {
+ if (al.args[i].val == ":") {
+ std::string v = al.args[i].args[0].val;
+ std::string sig = al.args[i].args[1].val;
+ out.globalExterns[v] = i;
+ out.globalExternSigs[v] = sig;
+ out.localExterns[externName][v] = i;
+ out.localExternSigs[externName][v] = sig;
+ }
+ else {
+ std::string v = al.args[i].val;
+ out.globalExterns[v] = i;
+ out.globalExternSigs[v] = "";
+ out.localExterns[externName][v] = i;
+ out.localExternSigs[externName][v] = "";
+ }
+ }
+ }
+ // Custom macros
+ else if (obj.val == "macro") {
+ // Rules for valid macros:
+ //
+ // There are only four categories of valid macros:
+ //
+ // 1. a macro where the outer function is something
+ // which is NOT an existing valid function/extern/datum
+ // 2. a macro of the form set(c(x), d) where c must NOT
+ // be an existing valid function/extern/datum
+ // 3. something of the form access(c(x)), where c must NOT
+ // be an existing valid function/extern/datum
+ // 4. something of the form set(access(c(x)), d) where c must
+ // NOT be an existing valid function/extern/datum
+ bool valid = false;
+ Node pattern = obj.args[0];
+ Node substitution = obj.args[1];
+ if (opcode(pattern.val) < 0 && !isValidFunctionName(pattern.val))
+ valid = true;
+ if (pattern.val == "set" &&
+ opcode(pattern.args[0].val) < 0 &&
+ !isValidFunctionName(pattern.args[0].val))
+ valid = true;
+ if (pattern.val == "access" &&
+ opcode(pattern.args[0].val) < 0 &&
+ !isValidFunctionName(pattern.args[0].val))
+ if (pattern.val == "set" &&
+ pattern.args[0].val == "access" &&
+ opcode(pattern.args[0].args[0].val) < 0 &&
+ !isValidFunctionName(pattern.args[0].args[0].val))
+ valid = true;
+ if (valid) {
+ out.customMacros.push_back(rewriteRule(pattern, substitution));
+ }
+ }
+ // Variable types
+ else if (obj.val == "type") {
+ std::string typeName = obj.args[0].val;
+ std::vector<Node> vars = obj.args[1].args;
+ for (unsigned i = 0; i < vars.size(); i++)
+ out.types[vars[i].val] = typeName;
+ }
+ // Storage variables/structures
+ else if (obj.val == "data") {
+ out.storageVars = getStorageVars(out.storageVars,
+ obj.args[0],
+ "",
+ storageDataCount);
+ storageDataCount += 1;
+ }
+ else any.push_back(obj);
+ }
+ std::vector<Node> main;
+ if (shared.args.size()) main.push_back(shared);
+ if (init.args.size()) main.push_back(init);
+
+ std::vector<Node> code;
+ if (shared.args.size()) code.push_back(shared);
+ for (unsigned i = 0; i < any.size(); i++)
+ code.push_back(any[i]);
+ for (unsigned i = 0; i < functions.size(); i++)
+ code.push_back(functions[i]);
+ Node codeNode;
+ if (functions.size() > 0) {
+ codeNode = astnode("with",
+ token("__funid", m),
+ astnode("byte",
+ token("0", m),
+ astnode("calldataload", token("0", m), m),
+ m),
+ astnode("seq", code, m),
+ m);
+ }
+ else codeNode = astnode("seq", code, m);
+ main.push_back(astnode("~return",
+ token("0", m),
+ astnode("lll",
+ codeNode,
+ token("0", m),
+ m),
+ m));
+
+
+ Node result;
+ if (main.size() == 1) result = main[0];
+ else result = astnode("seq", main, inp.metadata);
+ return preprocessResult(result, out);
+}
+
+preprocessResult processTypes (preprocessResult pr) {
+ preprocessAux aux = pr.second;
+ Node node = pr.first;
+ if (node.type == TOKEN && aux.types.count(node.val)) {
+ node = asn(aux.types[node.val], node, node.metadata);
+ }
+ else if (node.val == "untyped")
+ return preprocessResult(node.args[0], aux);
+ else {
+ for (unsigned i = 0; i < node.args.size(); i++) {
+ node.args[i] =
+ processTypes(preprocessResult(node.args[i], aux)).first;
+ }
+ }
+ return preprocessResult(node, aux);
+}
+
+preprocessResult preprocess(Node n) {
+ return processTypes(preprocessInit(n));
+}
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/preprocess.h b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/preprocess.h
new file mode 100644
index 000000000..944436aef
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/preprocess.h
@@ -0,0 +1,58 @@
+#ifndef ETHSERP_PREPROCESSOR
+#define ETHSERP_PREPROCESSOR
+
+#include <stdio.h>
+#include <iostream>
+#include <vector>
+#include <map>
+#include "util.h"
+
+// Storage variable index storing object
+struct svObj {
+ std::map<std::string, std::string> offsets;
+ std::map<std::string, int> indices;
+ std::map<std::string, std::vector<std::string> > coefficients;
+ std::map<std::string, bool> nonfinal;
+ std::string globalOffset;
+};
+
+class rewriteRule {
+ public:
+ rewriteRule(Node p, Node s) {
+ pattern = p;
+ substitution = s;
+ }
+ Node pattern;
+ Node substitution;
+};
+
+
+// Preprocessing result storing object
+class preprocessAux {
+ public:
+ preprocessAux() {
+ globalExterns = std::map<std::string, int>();
+ localExterns = std::map<std::string, std::map<std::string, int> >();
+ localExterns["self"] = std::map<std::string, int>();
+ }
+ std::map<std::string, int> globalExterns;
+ std::map<std::string, std::string> globalExternSigs;
+ std::map<std::string, std::map<std::string, int> > localExterns;
+ std::map<std::string, std::map<std::string, std::string> > localExternSigs;
+ std::vector<rewriteRule> customMacros;
+ std::map<std::string, std::string> types;
+ svObj storageVars;
+};
+
+#define preprocessResult std::pair<Node, preprocessAux>
+
+// Populate an svObj with the arguments needed to determine
+// the storage position of a node
+svObj getStorageVars(svObj pre, Node node, std::string prefix="",
+ int index=0);
+
+// Preprocess a function (see cpp for details)
+preprocessResult preprocess(Node inp);
+
+
+#endif
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/pyserpent.cpp b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/pyserpent.cpp
new file mode 100644
index 000000000..38398aa46
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/pyserpent.cpp
@@ -0,0 +1,173 @@
+#include <Python.h>
+#include "structmember.h"
+
+#include <stdlib.h>
+#include <stdio.h>
+#include <iostream>
+#include "funcs.h"
+
+#define PYMETHOD(name, FROM, method, TO) \
+ static PyObject * name(PyObject *, PyObject *args) { \
+ try { \
+ FROM(med) \
+ return TO(method(med)); \
+ } \
+ catch (std::string e) { \
+ PyErr_SetString(PyExc_Exception, e.c_str()); \
+ return NULL; \
+ } \
+ }
+
+#define FROMSTR(v) \
+ const char *command; \
+ int len; \
+ if (!PyArg_ParseTuple(args, "s#", &command, &len)) \
+ return NULL; \
+ std::string v = std::string(command, len); \
+
+#define FROMNODE(v) \
+ PyObject *node; \
+ if (!PyArg_ParseTuple(args, "O", &node)) \
+ return NULL; \
+ Node v = cppifyNode(node);
+
+#define FROMLIST(v) \
+ PyObject *node; \
+ if (!PyArg_ParseTuple(args, "O", &node)) \
+ return NULL; \
+ std::vector<Node> v = cppifyNodeList(node);
+
+// Convert metadata into python wrapper form [file, ln, ch]
+PyObject* pyifyMetadata(Metadata m) {
+ PyObject* a = PyList_New(0);
+ PyList_Append(a, Py_BuildValue("s#", m.file.c_str(), m.file.length()));
+ PyList_Append(a, Py_BuildValue("i", m.ln));
+ PyList_Append(a, Py_BuildValue("i", m.ch));
+ return a;
+}
+
+// Convert node into python wrapper form
+// [token=0/astnode=1, val, metadata, args]
+PyObject* pyifyNode(Node n) {
+ PyObject* a = PyList_New(0);
+ PyList_Append(a, Py_BuildValue("i", n.type == ASTNODE));
+ PyList_Append(a, Py_BuildValue("s#", n.val.c_str(), n.val.length()));
+ PyList_Append(a, pyifyMetadata(n.metadata));
+ for (unsigned i = 0; i < n.args.size(); i++)
+ PyList_Append(a, pyifyNode(n.args[i]));
+ return a;
+}
+
+// Convert string into python wrapper form
+PyObject* pyifyString(std::string s) {
+ return Py_BuildValue("s#", s.c_str(), s.length());
+}
+
+// Convert list of nodes into python wrapper form
+PyObject* pyifyNodeList(std::vector<Node> n) {
+ PyObject* a = PyList_New(0);
+ for (unsigned i = 0; i < n.size(); i++)
+ PyList_Append(a, pyifyNode(n[i]));
+ return a;
+}
+
+// Convert pyobject int into normal form
+int cppifyInt(PyObject* o) {
+ int out;
+ if (!PyArg_Parse(o, "i", &out))
+ err("Argument should be integer", Metadata());
+ return out;
+}
+
+// Convert pyobject string into normal form
+std::string cppifyString(PyObject* o) {
+ const char *command;
+ if (!PyArg_Parse(o, "s", &command))
+ err("Argument should be string", Metadata());
+ return std::string(command);
+}
+
+// Convert metadata from python wrapper form
+Metadata cppifyMetadata(PyObject* o) {
+ std::string file = cppifyString(PyList_GetItem(o, 0));
+ int ln = cppifyInt(PyList_GetItem(o, 1));
+ int ch = cppifyInt(PyList_GetItem(o, 2));
+ return Metadata(file, ln, ch);
+}
+
+// Convert node from python wrapper form
+Node cppifyNode(PyObject* o) {
+ Node n;
+ int isAstNode = cppifyInt(PyList_GetItem(o, 0));
+ n.type = isAstNode ? ASTNODE : TOKEN;
+ n.val = cppifyString(PyList_GetItem(o, 1));
+ n.metadata = cppifyMetadata(PyList_GetItem(o, 2));
+ std::vector<Node> args;
+ for (int i = 3; i < PyList_Size(o); i++) {
+ args.push_back(cppifyNode(PyList_GetItem(o, i)));
+ }
+ n.args = args;
+ return n;
+}
+
+//Convert list of nodes into normal form
+std::vector<Node> cppifyNodeList(PyObject* o) {
+ std::vector<Node> out;
+ for (int i = 0; i < PyList_Size(o); i++) {
+ out.push_back(cppifyNode(PyList_GetItem(o,i)));
+ }
+ return out;
+}
+
+PYMETHOD(ps_compile, FROMSTR, compile, pyifyString)
+PYMETHOD(ps_compile_chunk, FROMSTR, compileChunk, pyifyString)
+PYMETHOD(ps_compile_to_lll, FROMSTR, compileToLLL, pyifyNode)
+PYMETHOD(ps_compile_chunk_to_lll, FROMSTR, compileChunkToLLL, pyifyNode)
+PYMETHOD(ps_compile_lll, FROMNODE, compileLLL, pyifyString)
+PYMETHOD(ps_parse, FROMSTR, parseSerpent, pyifyNode)
+PYMETHOD(ps_rewrite, FROMNODE, rewrite, pyifyNode)
+PYMETHOD(ps_rewrite_chunk, FROMNODE, rewriteChunk, pyifyNode)
+PYMETHOD(ps_pretty_compile, FROMSTR, prettyCompile, pyifyNodeList)
+PYMETHOD(ps_pretty_compile_chunk, FROMSTR, prettyCompileChunk, pyifyNodeList)
+PYMETHOD(ps_pretty_compile_lll, FROMNODE, prettyCompileLLL, pyifyNodeList)
+PYMETHOD(ps_serialize, FROMLIST, serialize, pyifyString)
+PYMETHOD(ps_deserialize, FROMSTR, deserialize, pyifyNodeList)
+PYMETHOD(ps_parse_lll, FROMSTR, parseLLL, pyifyNode)
+
+
+static PyMethodDef PyextMethods[] = {
+ {"compile", ps_compile, METH_VARARGS,
+ "Compile code."},
+ {"compile_chunk", ps_compile_chunk, METH_VARARGS,
+ "Compile code chunk (no wrappers)."},
+ {"compile_to_lll", ps_compile_to_lll, METH_VARARGS,
+ "Compile code to LLL."},
+ {"compile_chunk_to_lll", ps_compile_chunk_to_lll, METH_VARARGS,
+ "Compile code chunk to LLL (no wrappers)."},
+ {"compile_lll", ps_compile_lll, METH_VARARGS,
+ "Compile LLL to EVM."},
+ {"parse", ps_parse, METH_VARARGS,
+ "Parse serpent"},
+ {"rewrite", ps_rewrite, METH_VARARGS,
+ "Rewrite parsed serpent to LLL"},
+ {"rewrite_chunk", ps_rewrite_chunk, METH_VARARGS,
+ "Rewrite parsed serpent to LLL (no wrappers)"},
+ {"pretty_compile", ps_pretty_compile, METH_VARARGS,
+ "Compile to EVM opcodes"},
+ {"pretty_compile_chunk", ps_pretty_compile_chunk, METH_VARARGS,
+ "Compile chunk to EVM opcodes (no wrappers)"},
+ {"pretty_compile_lll", ps_pretty_compile_lll, METH_VARARGS,
+ "Compile LLL to EVM opcodes"},
+ {"serialize", ps_serialize, METH_VARARGS,
+ "Convert EVM opcodes to bin"},
+ {"deserialize", ps_deserialize, METH_VARARGS,
+ "Convert EVM bin to opcodes"},
+ {"parse_lll", ps_parse_lll, METH_VARARGS,
+ "Parse LLL"},
+ {NULL, NULL, 0, NULL} /* Sentinel */
+};
+
+PyMODINIT_FUNC initserpent_pyext(void)
+{
+ Py_InitModule( "serpent_pyext", PyextMethods );
+}
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/pyserpent.py b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/pyserpent.py
new file mode 100644
index 000000000..2103b48fe
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/pyserpent.py
@@ -0,0 +1 @@
+from serpent import *
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/rewriter.cpp b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/rewriter.cpp
new file mode 100644
index 000000000..4cdce4f0a
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/rewriter.cpp
@@ -0,0 +1,804 @@
+#include <stdio.h>
+#include <iostream>
+#include <vector>
+#include <map>
+#include "util.h"
+#include "lllparser.h"
+#include "bignum.h"
+#include "optimize.h"
+#include "rewriteutils.h"
+#include "preprocess.h"
+#include "functions.h"
+#include "opcodes.h"
+
+// Rewrite rules
+std::string macros[][2] = {
+ {
+ "(seq $x)",
+ "$x"
+ },
+ {
+ "(seq (seq) $x)",
+ "$x"
+ },
+ {
+ "(+= $a $b)",
+ "(set $a (+ $a $b))"
+ },
+ {
+ "(*= $a $b)",
+ "(set $a (* $a $b))"
+ },
+ {
+ "(-= $a $b)",
+ "(set $a (- $a $b))"
+ },
+ {
+ "(/= $a $b)",
+ "(set $a (/ $a $b))"
+ },
+ {
+ "(%= $a $b)",
+ "(set $a (% $a $b))"
+ },
+ {
+ "(^= $a $b)",
+ "(set $a (^ $a $b))"
+ },
+ {
+ "(!= $a $b)",
+ "(iszero (eq $a $b))"
+ },
+ {
+ "(assert $x)",
+ "(unless $x (stop))"
+ },
+ {
+ "(min $a $b)",
+ "(with $1 $a (with $2 $b (if (lt $1 $2) $1 $2)))"
+ },
+ {
+ "(max $a $b)",
+ "(with $1 $a (with $2 $b (if (lt $1 $2) $2 $1)))"
+ },
+ {
+ "(smin $a $b)",
+ "(with $1 $a (with $2 $b (if (slt $1 $2) $1 $2)))"
+ },
+ {
+ "(smax $a $b)",
+ "(with $1 $a (with $2 $b (if (slt $1 $2) $2 $1)))"
+ },
+ {
+ "(if $cond $do (else $else))",
+ "(if $cond $do $else)"
+ },
+ {
+ "(code $code)",
+ "$code"
+ },
+ {
+ "(slice $arr $pos)",
+ "(add $arr (mul 32 $pos))",
+ },
+ {
+ "(array $len)",
+ "(alloc (mul 32 $len))"
+ },
+ {
+ "(while $cond $do)",
+ "(until (iszero $cond) $do)",
+ },
+ {
+ "(while (iszero $cond) $do)",
+ "(until $cond $do)",
+ },
+ {
+ "(if $cond $do)",
+ "(unless (iszero $cond) $do)",
+ },
+ {
+ "(if (iszero $cond) $do)",
+ "(unless $cond $do)",
+ },
+ {
+ "(access (. self storage) $ind)",
+ "(sload $ind)"
+ },
+ {
+ "(access $var $ind)",
+ "(mload (add $var (mul 32 $ind)))"
+ },
+ {
+ "(set (access (. self storage) $ind) $val)",
+ "(sstore $ind $val)"
+ },
+ {
+ "(set (access $var $ind) $val)",
+ "(mstore (add $var (mul 32 $ind)) $val)"
+ },
+ {
+ "(getch $var $ind)",
+ "(mod (mload (sub (add $var $ind) 31)) 256)"
+ },
+ {
+ "(setch $var $ind $val)",
+ "(mstore8 (add $var $ind) $val)",
+ },
+ {
+ "(send $to $value)",
+ "(~call (sub (gas) 25) $to $value 0 0 0 0)"
+ },
+ {
+ "(send $gas $to $value)",
+ "(~call $gas $to $value 0 0 0 0)"
+ },
+ {
+ "(sha3 $x)",
+ "(seq (set $1 $x) (~sha3 (ref $1) 32))"
+ },
+ {
+ "(sha3 $mstart (= chars $msize))",
+ "(~sha3 $mstart $msize)"
+ },
+ {
+ "(sha3 $mstart $msize)",
+ "(~sha3 $mstart (mul 32 $msize))"
+ },
+ {
+ "(id $0)",
+ "$0"
+ },
+ {
+ "(return $x)",
+ "(seq (set $1 $x) (~return (ref $1) 32))"
+ },
+ {
+ "(return $mstart (= chars $msize))",
+ "(~return $mstart $msize)"
+ },
+ {
+ "(return $start $len)",
+ "(~return $start (mul 32 $len))"
+ },
+ {
+ "(&& $x $y)",
+ "(if $x $y 0)"
+ },
+ {
+ "(|| $x $y)",
+ "(with $1 $x (if $1 $1 $y))"
+ },
+ {
+ "(>= $x $y)",
+ "(iszero (slt $x $y))"
+ },
+ {
+ "(<= $x $y)",
+ "(iszero (sgt $x $y))"
+ },
+ {
+ "(create $code)",
+ "(create 0 $code)"
+ },
+ {
+ "(create $endowment $code)",
+ "(with $1 (msize) (create $endowment (get $1) (lll (outer $code) (msize))))"
+ },
+ {
+ "(sha256 $x)",
+ "(with $1 (alloc 64) (seq (mstore (add (get $1) 32) $x) (pop (~call 101 2 0 (add (get $1) 32) 32 (get $1) 32)) (mload (get $1))))"
+ },
+ {
+ "(sha256 $arr (= chars $sz))",
+ "(with $1 (alloc 32) (seq (pop (~call 101 2 0 $arr $sz (get $1) 32)) (mload (get $1))))"
+ },
+ {
+ "(sha256 $arr $sz)",
+ "(with $1 (alloc 32) (seq (pop (~call 101 2 0 $arr (mul 32 $sz) (get $1) 32)) (mload (get $1))))"
+ },
+ {
+ "(ripemd160 $x)",
+ "(with $1 (alloc 64) (seq (mstore (add (get $1) 32) $x) (pop (~call 101 3 0 (add (get $1) 32) 32 (get $1) 32)) (mload (get $1))))"
+ },
+ {
+ "(ripemd160 $arr (= chars $sz))",
+ "(with $1 (alloc 32) (seq (pop (~call 101 3 0 $arr $sz (mload $1) 32)) (mload (get $1))))"
+ },
+ {
+ "(ripemd160 $arr $sz)",
+ "(with $1 (alloc 32) (seq (pop (~call 101 3 0 $arr (mul 32 $sz) (get $1) 32)) (mload (get $1))))"
+ },
+ {
+ "(ecrecover $h $v $r $s)",
+ "(with $1 (alloc 160) (seq (mstore (get $1) $h) (mstore (add (get $1) 32) $v) (mstore (add (get $1) 64) $r) (mstore (add (get $1) 96) $s) (pop (~call 101 1 0 (get $1) 128 (add (get $1 128)) 32)) (mload (add (get $1) 128))))"
+ },
+ {
+ "(inset $x)",
+ "$x"
+ },
+ {
+ "(create $x)",
+ "(with $1 (msize) (create $val (get $1) (lll $code (get $1))))"
+ },
+ {
+ "(with (= $var $val) $cond)",
+ "(with $var $val $cond)"
+ },
+ {
+ "(log $t1)",
+ "(~log1 0 0 $t1)"
+ },
+ {
+ "(log $t1 $t2)",
+ "(~log2 0 0 $t1 $t2)"
+ },
+ {
+ "(log $t1 $t2 $t3)",
+ "(~log3 0 0 $t1 $t2 $t3)"
+ },
+ {
+ "(log $t1 $t2 $t3 $t4)",
+ "(~log4 0 0 $t1 $t2 $t3 $t4)"
+ },
+ {
+ "(logarr $a $sz)",
+ "(~log0 $a (mul 32 $sz))"
+ },
+ {
+ "(logarr $a $sz $t1)",
+ "(~log1 $a (mul 32 $sz) $t1)"
+ },
+ {
+ "(logarr $a $sz $t1 $t2)",
+ "(~log2 $a (mul 32 $sz) $t1 $t2)"
+ },
+ {
+ "(logarr $a $sz $t1 $t2 $t3)",
+ "(~log3 $a (mul 32 $sz) $t1 $t2 $t3)"
+ },
+ {
+ "(logarr $a $sz $t1 $t2 $t3 $t4)",
+ "(~log4 $a (mul 32 $sz) $t1 $t2 $t3 $t4)"
+ },
+ {
+ "(save $loc $array (= chars $count))",
+ "(with $location (ref $loc) (with $c $count (with $end (div $c 32) (with $i 0 (seq (while (slt $i $end) (seq (sstore (add $i $location) (access $array $i)) (set $i (add $i 1)))) (sstore (add $i $location) (~and (access $array $i) (sub 0 (exp 256 (sub 32 (mod $c 32)))))))))))"
+ },
+ {
+ "(save $loc $array $count)",
+ "(with $location (ref $loc) (with $end $count (with $i 0 (while (slt $i $end) (seq (sstore (add $i $location) (access $array $i)) (set $i (add $i 1)))))))"
+ },
+ {
+ "(load $loc (= chars $count))",
+ "(with $location (ref $loc) (with $c $count (with $a (alloc $c) (with $i 0 (seq (while (slt $i (div $c 32)) (seq (set (access $a $i) (sload (add $location $i))) (set $i (add $i 1)))) (set (access $a $i) (~and (sload (add $location $i)) (sub 0 (exp 256 (sub 32 (mod $c 32)))))) $a)))))"
+ },
+ {
+ "(load $loc $count)",
+ "(with $location (ref $loc) (with $c $count (with $a (alloc $c) (with $i 0 (seq (while (slt $i $c) (seq (set (access $a $i) (sload (add $location $i))) (set $i (add $i 1)))) $a)))))"
+ },
+ {
+ "(unsafe_mcopy $to $from $sz)",
+ "(with _sz $sz (with _from $from (with _to $to (seq (comment STARTING UNSAFE MCOPY) (with _i 0 (while (lt _i _sz) (seq (mstore (add $to _i) (mload (add _from _i))) (set _i (add _i 32)))))))))"
+ },
+ {
+ "(mcopy $to $from $_sz)",
+ "(with _to $to (with _from $from (with _sz $sz (seq (comment STARTING MCOPY (with _i 0 (seq (while (lt (add _i 31) _sz) (seq (mstore (add _to _i) (mload (add _from _i))) (set _i (add _i 32)))) (with _mask (exp 256 (sub 32 (mod _sz 32))) (mstore (add $to _i) (add (mod (mload (add $to _i)) _mask) (and (mload (add $from _i)) (sub 0 _mask))))))))))))"
+ },
+ { "(. msg sender)", "(caller)" },
+ { "(. msg value)", "(callvalue)" },
+ { "(. tx gasprice)", "(gasprice)" },
+ { "(. tx origin)", "(origin)" },
+ { "(. tx gas)", "(gas)" },
+ { "(. $x balance)", "(balance $x)" },
+ { "self", "(address)" },
+ { "(. block prevhash)", "(prevhash)" },
+ { "(. block coinbase)", "(coinbase)" },
+ { "(. block timestamp)", "(timestamp)" },
+ { "(. block number)", "(number)" },
+ { "(. block difficulty)", "(difficulty)" },
+ { "(. block gaslimit)", "(gaslimit)" },
+ { "stop", "(stop)" },
+ { "---END---", "" } //Keep this line at the end of the list
+};
+
+std::vector<rewriteRule> nodeMacros;
+
+// Token synonyms
+std::string synonyms[][2] = {
+ { "or", "||" },
+ { "and", "&&" },
+ { "|", "~or" },
+ { "&", "~and" },
+ { "elif", "if" },
+ { "!", "iszero" },
+ { "~", "~not" },
+ { "not", "iszero" },
+ { "string", "alloc" },
+ { "+", "add" },
+ { "-", "sub" },
+ { "*", "mul" },
+ { "/", "sdiv" },
+ { "^", "exp" },
+ { "**", "exp" },
+ { "%", "smod" },
+ { "<", "slt" },
+ { ">", "sgt" },
+ { "=", "set" },
+ { "==", "eq" },
+ { ":", "kv" },
+ { "---END---", "" } //Keep this line at the end of the list
+};
+
+// Custom setters (need to be registered separately
+// for use with managed storage)
+std::string setters[][2] = {
+ { "+=", "+" },
+ { "-=", "-" },
+ { "*=", "*" },
+ { "/=", "/" },
+ { "%=", "%" },
+ { "^=", "^" },
+ { "---END---", "" } //Keep this line at the end of the list
+};
+
+// Processes mutable array literals
+Node array_lit_transform(Node node) {
+ std::string prefix = "_temp"+mkUniqueToken() + "_";
+ Metadata m = node.metadata;
+ std::map<std::string, Node> d;
+ std::string o = "(seq (set $arr (alloc "+utd(node.args.size()*32)+"))";
+ for (unsigned i = 0; i < node.args.size(); i++) {
+ o += " (mstore (add (get $arr) "+utd(i * 32)+") $"+utd(i)+")";
+ d[utd(i)] = node.args[i];
+ }
+ o += " (get $arr))";
+ return subst(parseLLL(o), d, prefix, m);
+}
+
+
+Node apply_rules(preprocessResult pr);
+
+// Transform "<variable>.<fun>(args...)" into
+// a call
+Node dotTransform(Node node, preprocessAux aux) {
+ Metadata m = node.metadata;
+ // We're gonna make lots of temporary variables,
+ // so set up a unique flag for them
+ std::string prefix = "_temp"+mkUniqueToken()+"_";
+ // Check that the function name is a token
+ if (node.args[0].args[1].type == ASTNODE)
+ err("Function name must be static", m);
+
+ Node dotOwner = node.args[0].args[0];
+ std::string dotMember = node.args[0].args[1].val;
+ // kwargs = map of special arguments
+ std::map<std::string, Node> kwargs;
+ kwargs["value"] = token("0", m);
+ kwargs["gas"] = subst(parseLLL("(- (gas) 25)"), msn(), prefix, m);
+ // Search for as=? and call=code keywords, and isolate the actual
+ // function arguments
+ std::vector<Node> fnargs;
+ std::string as = "";
+ std::string op = "call";
+ for (unsigned i = 1; i < node.args.size(); i++) {
+ fnargs.push_back(node.args[i]);
+ Node arg = fnargs.back();
+ if (arg.val == "=" || arg.val == "set") {
+ if (arg.args[0].val == "as")
+ as = arg.args[1].val;
+ if (arg.args[0].val == "call" && arg.args[1].val == "code")
+ op = "callcode";
+ if (arg.args[0].val == "gas")
+ kwargs["gas"] = arg.args[1];
+ if (arg.args[0].val == "value")
+ kwargs["value"] = arg.args[1];
+ if (arg.args[0].val == "outsz")
+ kwargs["outsz"] = arg.args[1];
+ }
+ }
+ if (dotOwner.val == "self") {
+ if (as.size()) err("Cannot use \"as\" when calling self!", m);
+ as = dotOwner.val;
+ }
+ // Determine the funId and sig assuming the "as" keyword was used
+ int funId = 0;
+ std::string sig;
+ if (as.size() > 0 && aux.localExterns.count(as)) {
+ if (!aux.localExterns[as].count(dotMember))
+ err("Invalid call: "+printSimple(dotOwner)+"."+dotMember, m);
+ funId = aux.localExterns[as][dotMember];
+ sig = aux.localExternSigs[as][dotMember];
+ }
+ // Determine the funId and sig otherwise
+ else if (!as.size()) {
+ if (!aux.globalExterns.count(dotMember))
+ err("Invalid call: "+printSimple(dotOwner)+"."+dotMember, m);
+ std::string key = unsignedToDecimal(aux.globalExterns[dotMember]);
+ funId = aux.globalExterns[dotMember];
+ sig = aux.globalExternSigs[dotMember];
+ }
+ else err("Invalid call: "+printSimple(dotOwner)+"."+dotMember, m);
+ // Pack arguments
+ kwargs["data"] = packArguments(fnargs, sig, funId, m);
+ kwargs["to"] = dotOwner;
+ Node main;
+ // Pack output
+ if (!kwargs.count("outsz")) {
+ main = parseLLL(
+ "(with _data $data (seq "
+ "(pop (~"+op+" $gas $to $value (access _data 0) (access _data 1) (ref $dataout) 32))"
+ "(get $dataout)))");
+ }
+ else {
+ main = parseLLL(
+ "(with _data $data (with _outsz (mul 32 $outsz) (with _out (alloc _outsz) (seq "
+ "(pop (~"+op+" $gas $to $value (access _data 0) (access _data 1) _out _outsz))"
+ "(get _out)))))");
+ }
+ // Set up main call
+
+ Node o = subst(main, kwargs, prefix, m);
+ return o;
+}
+
+// Transform an access of the form self.bob, self.users[5], etc into
+// a storage access
+//
+// There exist two types of objects: finite objects, and infinite
+// objects. Finite objects are packed optimally tightly into storage
+// accesses; for example:
+//
+// data obj[100](a, b[2][4], c)
+//
+// obj[0].a -> 0
+// obj[0].b[0][0] -> 1
+// obj[0].b[1][3] -> 8
+// obj[45].c -> 459
+//
+// Infinite objects are accessed by sha3([v1, v2, v3 ... ]), where
+// the values are a list of array indices and keyword indices, for
+// example:
+// data obj[](a, b[2][4], c)
+// data obj2[](a, b[][], c)
+//
+// obj[0].a -> sha3([0, 0, 0])
+// obj[5].b[1][3] -> sha3([0, 5, 1, 1, 3])
+// obj[45].c -> sha3([0, 45, 2])
+// obj2[0].a -> sha3([1, 0, 0])
+// obj2[5].b[1][3] -> sha3([1, 5, 1, 1, 3])
+// obj2[45].c -> sha3([1, 45, 2])
+Node storageTransform(Node node, preprocessAux aux,
+ bool mapstyle=false, bool ref=false) {
+ Metadata m = node.metadata;
+ // Get a list of all of the "access parameters" used in order
+ // eg. self.users[5].cow[4][m[2]][woof] ->
+ // [--self, --users, 5, --cow, 4, m[2], woof]
+ std::vector<Node> hlist = listfyStorageAccess(node);
+ // For infinite arrays, the terms array will just provide a list
+ // of indices. For finite arrays, it's a list of index*coefficient
+ std::vector<Node> terms;
+ std::string offset = "0";
+ std::string prefix = "";
+ std::string varPrefix = "_temp"+mkUniqueToken()+"_";
+ int c = 0;
+ std::vector<std::string> coefficients;
+ coefficients.push_back("");
+ for (unsigned i = 1; i < hlist.size(); i++) {
+ // We pre-add the -- flag to parameter-like terms. For example,
+ // self.users[m] -> [--self, --users, m]
+ // self.users.m -> [--self, --users, --m]
+ if (hlist[i].val.substr(0, 2) == "--") {
+ prefix += hlist[i].val.substr(2) + ".";
+ std::string tempPrefix = prefix.substr(0, prefix.size()-1);
+ if (!aux.storageVars.offsets.count(tempPrefix))
+ return node;
+ if (c < (signed)coefficients.size() - 1)
+ err("Too few array index lookups", m);
+ if (c > (signed)coefficients.size() - 1)
+ err("Too many array index lookups", m);
+ coefficients = aux.storageVars.coefficients[tempPrefix];
+ // If the size of an object exceeds 2^176, we make it an infinite
+ // array
+ if (decimalGt(coefficients.back(), tt176) && !mapstyle)
+ return storageTransform(node, aux, true, ref);
+ offset = decimalAdd(offset, aux.storageVars.offsets[tempPrefix]);
+ c = 0;
+ if (mapstyle)
+ terms.push_back(token(unsignedToDecimal(
+ aux.storageVars.indices[tempPrefix])));
+ }
+ else if (mapstyle) {
+ terms.push_back(hlist[i]);
+ c += 1;
+ }
+ else {
+ if (c > (signed)coefficients.size() - 2)
+ err("Too many array index lookups", m);
+ terms.push_back(
+ astnode("mul",
+ hlist[i],
+ token(coefficients[coefficients.size() - 2 - c], m),
+ m));
+
+ c += 1;
+ }
+ }
+ if (aux.storageVars.nonfinal.count(prefix.substr(0, prefix.size()-1)))
+ err("Storage variable access not deep enough", m);
+ if (c < (signed)coefficients.size() - 1) {
+ err("Too few array index lookups", m);
+ }
+ if (c > (signed)coefficients.size() - 1) {
+ err("Too many array index lookups", m);
+ }
+ Node o;
+ if (mapstyle) {
+ std::string t = "_temp_"+mkUniqueToken();
+ std::vector<Node> sub;
+ for (unsigned i = 0; i < terms.size(); i++)
+ sub.push_back(asn("mstore",
+ asn("add",
+ tkn(utd(i * 32), m),
+ asn("get", tkn(t+"pos", m), m),
+ m),
+ terms[i],
+ m));
+ sub.push_back(tkn(t+"pos", m));
+ Node main = asn("with",
+ tkn(t+"pos", m),
+ asn("alloc", tkn(utd(terms.size() * 32), m), m),
+ asn("seq", sub, m),
+ m);
+ Node sz = token(utd(terms.size() * 32), m);
+ o = astnode("~sha3",
+ main,
+ sz,
+ m);
+ }
+ else {
+ // We add up all the index*coefficients
+ Node out = token(offset, node.metadata);
+ for (unsigned i = 0; i < terms.size(); i++) {
+ std::vector<Node> temp;
+ temp.push_back(out);
+ temp.push_back(terms[i]);
+ out = astnode("add", temp, node.metadata);
+ }
+ o = out;
+ }
+ if (ref) return o;
+ else return astnode("sload", o, node.metadata);
+}
+
+
+// Recursively applies rewrite rules
+std::pair<Node, bool> apply_rules_iter(preprocessResult pr) {
+ bool changed = false;
+ Node node = pr.first;
+ // If the rewrite rules have not yet been parsed, parse them
+ if (!nodeMacros.size()) {
+ for (int i = 0; i < 9999; i++) {
+ std::vector<Node> o;
+ if (macros[i][0] == "---END---") break;
+ nodeMacros.push_back(rewriteRule(
+ parseLLL(macros[i][0]),
+ parseLLL(macros[i][1])
+ ));
+ }
+ }
+ // Assignment transformations
+ for (int i = 0; i < 9999; i++) {
+ if (setters[i][0] == "---END---") break;
+ if (node.val == setters[i][0]) {
+ node = astnode("=",
+ node.args[0],
+ astnode(setters[i][1],
+ node.args[0],
+ node.args[1],
+ node.metadata),
+ node.metadata);
+ }
+ }
+ // Do nothing to macros
+ if (node.val == "macro") {
+ return std::pair<Node, bool>(node, changed);
+ }
+ // Ignore comments
+ if (node.val == "comment") {
+ return std::pair<Node, bool>(node, changed);
+ }
+ // Special storage transformation
+ if (isNodeStorageVariable(node)) {
+ node = storageTransform(node, pr.second);
+ changed = true;
+ }
+ if (node.val == "ref" && isNodeStorageVariable(node.args[0])) {
+ node = storageTransform(node.args[0], pr.second, false, true);
+ changed = true;
+ }
+ if (node.val == "=" && isNodeStorageVariable(node.args[0])) {
+ Node t = storageTransform(node.args[0], pr.second);
+ if (t.val == "sload") {
+ std::vector<Node> o;
+ o.push_back(t.args[0]);
+ o.push_back(node.args[1]);
+ node = astnode("sstore", o, node.metadata);
+ }
+ changed = true;
+ }
+ // Main code
+ unsigned pos = 0;
+ std::string prefix = "_temp"+mkUniqueToken()+"_";
+ while(1) {
+ if (synonyms[pos][0] == "---END---") {
+ break;
+ }
+ else if (node.type == ASTNODE && node.val == synonyms[pos][0]) {
+ node.val = synonyms[pos][1];
+ changed = true;
+ }
+ pos++;
+ }
+ for (pos = 0; pos < nodeMacros.size() + pr.second.customMacros.size(); pos++) {
+ rewriteRule macro = pos < nodeMacros.size()
+ ? nodeMacros[pos]
+ : pr.second.customMacros[pos - nodeMacros.size()];
+ matchResult mr = match(macro.pattern, node);
+ if (mr.success) {
+ node = subst(macro.substitution, mr.map, prefix, node.metadata);
+ std::pair<Node, bool> o =
+ apply_rules_iter(preprocessResult(node, pr.second));
+ o.second = true;
+ return o;
+ }
+ }
+ // Special transformations
+ if (node.val == "outer") {
+ node = apply_rules(preprocess(node.args[0]));
+ changed = true;
+ }
+ if (node.val == "array_lit") {
+ node = array_lit_transform(node);
+ changed = true;
+ }
+ if (node.val == "fun" && node.args[0].val == ".") {
+ node = dotTransform(node, pr.second);
+ changed = true;
+ }
+ if (node.type == ASTNODE) {
+ unsigned i = 0;
+ if (node.val == "set" || node.val == "ref"
+ || node.val == "get" || node.val == "with") {
+ if (node.args[0].val.size() > 0 && node.args[0].val[0] != '\''
+ && node.args[0].type == TOKEN && node.args[0].val[0] != '$') {
+ node.args[0].val = "'" + node.args[0].val;
+ changed = true;
+ }
+ i = 1;
+ }
+ else if (node.val == "arglen") {
+ node.val = "get";
+ node.args[0].val = "'_len_" + node.args[0].val;
+ i = 1;
+ changed = true;
+ }
+ for (; i < node.args.size(); i++) {
+ std::pair<Node, bool> r =
+ apply_rules_iter(preprocessResult(node.args[i], pr.second));
+ node.args[i] = r.first;
+ changed = changed || r.second;
+ }
+ }
+ else if (node.type == TOKEN && !isNumberLike(node)) {
+ if (node.val.size() >= 2
+ && node.val[0] == '"'
+ && node.val[node.val.size() - 1] == '"') {
+ std::string bin = node.val.substr(1, node.val.size() - 2);
+ unsigned sz = bin.size();
+ std::vector<Node> o;
+ for (unsigned i = 0; i < sz; i += 32) {
+ std::string t = binToNumeric(bin.substr(i, 32));
+ if ((sz - i) < 32 && (sz - i) > 0) {
+ while ((sz - i) < 32) {
+ t = decimalMul(t, "256");
+ i--;
+ }
+ i = sz;
+ }
+ o.push_back(token(t, node.metadata));
+ }
+ node = astnode("array_lit", o, node.metadata);
+ std::pair<Node, bool> r =
+ apply_rules_iter(preprocessResult(node, pr.second));
+ node = r.first;
+ changed = true;
+ }
+ else if (node.val.size() && node.val[0] != '\'' && node.val[0] != '$') {
+ node.val = "'" + node.val;
+ std::vector<Node> args;
+ args.push_back(node);
+ std::string v = node.val.substr(1);
+ node = astnode("get", args, node.metadata);
+ changed = true;
+ }
+ }
+ return std::pair<Node, bool>(node, changed);
+}
+
+Node apply_rules(preprocessResult pr) {
+ for (unsigned i = 0; i < pr.second.customMacros.size(); i++) {
+ pr.second.customMacros[i].pattern =
+ apply_rules(preprocessResult(pr.second.customMacros[i].pattern, preprocessAux()));
+ }
+ while (1) {
+ //std::cerr << printAST(pr.first) <<
+ // " " << pr.second.customMacros.size() << "\n";
+ std::pair<Node, bool> r = apply_rules_iter(pr);
+ if (!r.second) {
+ return r.first;
+ }
+ pr.first = r.first;
+ }
+}
+
+Node validate(Node inp) {
+ Metadata m = inp.metadata;
+ if (inp.type == ASTNODE) {
+ int i = 0;
+ while(validFunctions[i][0] != "---END---") {
+ if (inp.val == validFunctions[i][0]) {
+ std::string sz = unsignedToDecimal(inp.args.size());
+ if (decimalGt(validFunctions[i][1], sz)) {
+ err("Too few arguments for "+inp.val, inp.metadata);
+ }
+ if (decimalGt(sz, validFunctions[i][2])) {
+ err("Too many arguments for "+inp.val, inp.metadata);
+ }
+ }
+ i++;
+ }
+ }
+ for (unsigned i = 0; i < inp.args.size(); i++) validate(inp.args[i]);
+ return inp;
+}
+
+Node postValidate(Node inp) {
+ // This allows people to use ~x as a way of having functions with the same
+ // name and arity as macros; the idea is that ~x is a "final" form, and
+ // should not be remacroed, but it is converted back at the end
+ if (inp.val.size() > 0 && inp.val[0] == '~') {
+ inp.val = inp.val.substr(1);
+ }
+ if (inp.type == ASTNODE) {
+ if (inp.val == ".")
+ err("Invalid object member (ie. a foo.bar not mapped to anything)",
+ inp.metadata);
+ else if (opcode(inp.val) >= 0) {
+ if ((signed)inp.args.size() < opinputs(inp.val))
+ err("Too few arguments for "+inp.val, inp.metadata);
+ if ((signed)inp.args.size() > opinputs(inp.val))
+ err("Too many arguments for "+inp.val, inp.metadata);
+ }
+ else if (isValidLLLFunc(inp.val, inp.args.size())) {
+ // do nothing
+ }
+ else err ("Invalid argument count or LLL function: "+inp.val, inp.metadata);
+ for (unsigned i = 0; i < inp.args.size(); i++) {
+ inp.args[i] = postValidate(inp.args[i]);
+ }
+ }
+ return inp;
+}
+
+Node rewrite(Node inp) {
+ return postValidate(optimize(apply_rules(preprocess(inp))));
+}
+
+Node rewriteChunk(Node inp) {
+ return postValidate(optimize(apply_rules(
+ preprocessResult(
+ validate(inp), preprocessAux()))));
+}
+
+using namespace std;
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/rewriter.h b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/rewriter.h
new file mode 100644
index 000000000..716815cee
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/rewriter.h
@@ -0,0 +1,16 @@
+#ifndef ETHSERP_REWRITER
+#define ETHSERP_REWRITER
+
+#include <stdio.h>
+#include <iostream>
+#include <vector>
+#include <map>
+#include "util.h"
+
+// Applies rewrite rules
+Node rewrite(Node inp);
+
+// Applies rewrite rules adding without wrapper
+Node rewriteChunk(Node inp);
+
+#endif
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/rewriteutils.cpp b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/rewriteutils.cpp
new file mode 100644
index 000000000..0d810bdbc
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/rewriteutils.cpp
@@ -0,0 +1,211 @@
+#include <stdio.h>
+#include <iostream>
+#include <vector>
+#include <map>
+#include "util.h"
+#include "lllparser.h"
+#include "bignum.h"
+#include "rewriteutils.h"
+#include "optimize.h"
+
+// Valid functions and their min and max argument counts
+std::string validFunctions[][3] = {
+ { "if", "2", "3" },
+ { "unless", "2", "2" },
+ { "while", "2", "2" },
+ { "until", "2", "2" },
+ { "alloc", "1", "1" },
+ { "array", "1", "1" },
+ { "call", "2", tt256 },
+ { "callcode", "2", tt256 },
+ { "create", "1", "4" },
+ { "getch", "2", "2" },
+ { "setch", "3", "3" },
+ { "sha3", "1", "2" },
+ { "return", "1", "2" },
+ { "inset", "1", "1" },
+ { "min", "2", "2" },
+ { "max", "2", "2" },
+ { "array_lit", "0", tt256 },
+ { "seq", "0", tt256 },
+ { "log", "1", "6" },
+ { "outer", "1", "1" },
+ { "set", "2", "2" },
+ { "get", "1", "1" },
+ { "ref", "1", "1" },
+ { "declare", "1", tt256 },
+ { "with", "3", "3" },
+ { "outer", "1", "1" },
+ { "mcopy", "3", "3" },
+ { "unsafe_mcopy", "3", "3" },
+ { "save", "3", "3" },
+ { "load", "2", "2" },
+ { "---END---", "", "" } //Keep this line at the end of the list
+};
+
+std::map<std::string, bool> vfMap;
+
+// Is a function name one of the valid functions above?
+bool isValidFunctionName(std::string f) {
+ if (vfMap.size() == 0) {
+ for (int i = 0; ; i++) {
+ if (validFunctions[i][0] == "---END---") break;
+ vfMap[validFunctions[i][0]] = true;
+ }
+ }
+ return vfMap.count(f);
+}
+
+// Cool function for debug purposes (named cerrStringList to make
+// all prints searchable via 'cerr')
+void cerrStringList(std::vector<std::string> s, std::string suffix) {
+ for (unsigned i = 0; i < s.size(); i++) std::cerr << s[i] << " ";
+ std::cerr << suffix << "\n";
+}
+
+// Convert:
+// self.cow -> ["cow"]
+// self.horse[0] -> ["horse", "0"]
+// self.a[6][7][self.storage[3]].chicken[9] ->
+// ["6", "7", (sload 3), "chicken", "9"]
+std::vector<Node> listfyStorageAccess(Node node) {
+ std::vector<Node> out;
+ std::vector<Node> nodez;
+ nodez.push_back(node);
+ while (1) {
+ if (nodez.back().type == TOKEN) {
+ out.push_back(token("--" + nodez.back().val, node.metadata));
+ std::vector<Node> outrev;
+ for (int i = (signed)out.size() - 1; i >= 0; i--) {
+ outrev.push_back(out[i]);
+ }
+ return outrev;
+ }
+ if (nodez.back().val == ".")
+ nodez.back().args[1].val = "--" + nodez.back().args[1].val;
+ if (nodez.back().args.size() == 0)
+ err("Error parsing storage variable statement", node.metadata);
+ if (nodez.back().args.size() == 1)
+ out.push_back(token(tt256m1, node.metadata));
+ else
+ out.push_back(nodez.back().args[1]);
+ nodez.push_back(nodez.back().args[0]);
+ }
+}
+
+// Is the given node something of the form
+// self.cow
+// self.horse[0]
+// self.a[6][7][self.storage[3]].chicken[9]
+bool isNodeStorageVariable(Node node) {
+ std::vector<Node> nodez;
+ nodez.push_back(node);
+ while (1) {
+ if (nodez.back().type == TOKEN) return false;
+ if (nodez.back().args.size() == 0) return false;
+ if (nodez.back().val != "." && nodez.back().val != "access")
+ return false;
+ if (nodez.back().args[0].val == "self") return true;
+ nodez.push_back(nodez.back().args[0]);
+ }
+}
+
+// Main pattern matching routine, for those patterns that can be expressed
+// using our standard mini-language above
+//
+// Returns two values. First, a boolean to determine whether the node matches
+// the pattern, second, if the node does match then a map mapping variables
+// in the pattern to nodes
+matchResult match(Node p, Node n) {
+ matchResult o;
+ o.success = false;
+ if (p.type == TOKEN) {
+ if (p.val == n.val && n.type == TOKEN) o.success = true;
+ else if (p.val[0] == '$' || p.val[0] == '@') {
+ o.success = true;
+ o.map[p.val.substr(1)] = n;
+ }
+ }
+ else if (n.type==TOKEN || p.val!=n.val || p.args.size()!=n.args.size()) {
+ // do nothing
+ }
+ else {
+ for (unsigned i = 0; i < p.args.size(); i++) {
+ matchResult oPrime = match(p.args[i], n.args[i]);
+ if (!oPrime.success) {
+ o.success = false;
+ return o;
+ }
+ for (std::map<std::string, Node>::iterator it = oPrime.map.begin();
+ it != oPrime.map.end();
+ it++) {
+ o.map[(*it).first] = (*it).second;
+ }
+ }
+ o.success = true;
+ }
+ return o;
+}
+
+
+// Fills in the pattern with a dictionary mapping variable names to
+// nodes (these dicts are generated by match). Match and subst together
+// create a full pattern-matching engine.
+Node subst(Node pattern,
+ std::map<std::string, Node> dict,
+ std::string varflag,
+ Metadata m) {
+ // Swap out patterns at the token level
+ if (pattern.metadata.ln == -1)
+ pattern.metadata = m;
+ if (pattern.type == TOKEN &&
+ pattern.val[0] == '$') {
+ if (dict.count(pattern.val.substr(1))) {
+ return dict[pattern.val.substr(1)];
+ }
+ else {
+ return token(varflag + pattern.val.substr(1), m);
+ }
+ }
+ // Other tokens are untouched
+ else if (pattern.type == TOKEN) {
+ return pattern;
+ }
+ // Substitute recursively for ASTs
+ else {
+ std::vector<Node> args;
+ for (unsigned i = 0; i < pattern.args.size(); i++) {
+ args.push_back(subst(pattern.args[i], dict, varflag, m));
+ }
+ return asn(pattern.val, args, m);
+ }
+}
+
+// Transforms a sequence containing two-argument with statements
+// into a statement containing those statements in nested form
+Node withTransform (Node source) {
+ Node o = token("--");
+ Metadata m = source.metadata;
+ std::vector<Node> args;
+ for (int i = source.args.size() - 1; i >= 0; i--) {
+ Node a = source.args[i];
+ if (a.val == "with" && a.args.size() == 2) {
+ std::vector<Node> flipargs;
+ for (int j = args.size() - 1; j >= 0; j--)
+ flipargs.push_back(args[i]);
+ if (o.val != "--")
+ flipargs.push_back(o);
+ o = asn("with", a.args[0], a.args[1], asn("seq", flipargs, m), m);
+ args = std::vector<Node>();
+ }
+ else {
+ args.push_back(a);
+ }
+ }
+ std::vector<Node> flipargs;
+ for (int j = args.size() - 1; j >= 0; j--)
+ flipargs.push_back(args[j]);
+ if (o.val != "--")
+ flipargs.push_back(o);
+ return asn("seq", flipargs, m);
+}
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/rewriteutils.h b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/rewriteutils.h
new file mode 100644
index 000000000..8abf44a9f
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/rewriteutils.h
@@ -0,0 +1,51 @@
+#ifndef ETHSERP_REWRITEUTILS
+#define ETHSERP_REWRITEUTILS
+
+#include <stdio.h>
+#include <iostream>
+#include <vector>
+#include <map>
+#include "util.h"
+
+// Valid functions and their min and max argument counts
+extern std::string validFunctions[][3];
+
+extern std::map<std::string, bool> vfMap;
+
+bool isValidFunctionName(std::string f);
+
+// Converts deep array access into ordered list of the arguments
+// along the descent
+std::vector<Node> listfyStorageAccess(Node node);
+
+// Cool function for debug purposes (named cerrStringList to make
+// all prints searchable via 'cerr')
+void cerrStringList(std::vector<std::string> s, std::string suffix="");
+
+// Is the given node something of the form
+// self.cow
+// self.horse[0]
+// self.a[6][7][self.storage[3]].chicken[9]
+bool isNodeStorageVariable(Node node);
+
+// Applies rewrite rules adding without wrapper
+Node rewriteChunk(Node inp);
+
+// Match result storing object
+struct matchResult {
+ bool success;
+ std::map<std::string, Node> map;
+};
+
+// Match node to pattern
+matchResult match(Node p, Node n);
+
+// Substitute node using pattern
+Node subst(Node pattern,
+ std::map<std::string, Node> dict,
+ std::string varflag,
+ Metadata m);
+
+Node withTransform(Node source);
+
+#endif
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/serpent.py b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/serpent.py
new file mode 100644
index 000000000..8d6bedfe3
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/serpent.py
@@ -0,0 +1,201 @@
+import serpent_pyext as pyext
+import sys
+import re
+
+VERSION = '1.7.7'
+
+
+class Metadata(object):
+ def __init__(self, li):
+ self.file = li[0]
+ self.ln = li[1]
+ self.ch = li[2]
+
+ def out(self):
+ return [self.file, self.ln, self.ch]
+
+
+class Token(object):
+ def __init__(self, val, metadata):
+ self.val = val
+ self.metadata = Metadata(metadata)
+
+ def out(self):
+ return [0, self.val, self.metadata.out()]
+
+ def __repr__(self):
+ return str(self.val)
+
+
+class Astnode(object):
+ def __init__(self, val, args, metadata):
+ self.val = val
+ self.args = map(node, args)
+ self.metadata = Metadata(metadata)
+
+ def out(self):
+ o = [1, self.val, self.metadata.out()]+[x.out() for x in self.args]
+ return o
+
+ def __repr__(self):
+ o = '(' + self.val
+ subs = map(repr, self.args)
+ k = 0
+ out = " "
+ while k < len(subs) and o != "(seq":
+ if '\n' in subs[k] or len(out + subs[k]) >= 80:
+ break
+ out += subs[k] + " "
+ k += 1
+ if k < len(subs):
+ o += out + "\n "
+ o += '\n '.join('\n'.join(subs[k:]).split('\n'))
+ o += '\n)'
+ else:
+ o += out[:-1] + ')'
+ return o
+
+
+def node(li):
+ if li[0]:
+ return Astnode(li[1], li[3:], li[2])
+ else:
+ return Token(li[1], li[2])
+
+
+def take(x):
+ return pyext.parse_lll(x) if isinstance(x, (str, unicode)) else x.out()
+
+
+def takelist(x):
+ return map(take, parse(x).args if isinstance(x, (str, unicode)) else x)
+
+
+compile = lambda x: pyext.compile(x)
+compile_chunk = lambda x: pyext.compile_chunk(x)
+compile_to_lll = lambda x: node(pyext.compile_to_lll(x))
+compile_chunk_to_lll = lambda x: node(pyext.compile_chunk_to_lll(x))
+compile_lll = lambda x: pyext.compile_lll(take(x))
+parse = lambda x: node(pyext.parse(x))
+rewrite = lambda x: node(pyext.rewrite(take(x)))
+rewrite_chunk = lambda x: node(pyext.rewrite_chunk(take(x)))
+pretty_compile = lambda x: map(node, pyext.pretty_compile(x))
+pretty_compile_chunk = lambda x: map(node, pyext.pretty_compile_chunk(x))
+pretty_compile_lll = lambda x: map(node, pyext.pretty_compile_lll(take(x)))
+serialize = lambda x: pyext.serialize(takelist(x))
+deserialize = lambda x: map(node, pyext.deserialize(x))
+
+is_numeric = lambda x: isinstance(x, (int, long))
+is_string = lambda x: isinstance(x, (str, unicode))
+tobytearr = lambda n, L: [] if L == 0 else tobytearr(n / 256, L - 1)+[n % 256]
+
+
+# A set of methods for detecting raw values (numbers and strings) and
+# converting them to integers
+def frombytes(b):
+ return 0 if len(b) == 0 else ord(b[-1]) + 256 * frombytes(b[:-1])
+
+
+def fromhex(b):
+ hexord = lambda x: '0123456789abcdef'.find(x)
+ return 0 if len(b) == 0 else hexord(b[-1]) + 16 * fromhex(b[:-1])
+
+
+def numberize(b):
+ if is_numeric(b):
+ return b
+ elif b[0] in ["'", '"']:
+ return frombytes(b[1:-1])
+ elif b[:2] == '0x':
+ return fromhex(b[2:])
+ elif re.match('^[0-9]*$', b):
+ return int(b)
+ elif len(b) == 40:
+ return fromhex(b)
+ else:
+ raise Exception("Cannot identify data type: %r" % b)
+
+
+def enc(n):
+ if is_numeric(n):
+ return ''.join(map(chr, tobytearr(n, 32)))
+ elif is_string(n) and len(n) == 40:
+ return '\x00' * 12 + n.decode('hex')
+ elif is_string(n):
+ return '\x00' * (32 - len(n)) + n
+ elif n is True:
+ return 1
+ elif n is False or n is None:
+ return 0
+
+
+def encode_datalist(*args):
+ if isinstance(args, (tuple, list)):
+ return ''.join(map(enc, args))
+ elif not len(args) or args[0] == '':
+ return ''
+ else:
+ # Assume you're getting in numbers or addresses or 0x...
+ return ''.join(map(enc, map(numberize, args)))
+
+
+def decode_datalist(arr):
+ if isinstance(arr, list):
+ arr = ''.join(map(chr, arr))
+ o = []
+ for i in range(0, len(arr), 32):
+ o.append(frombytes(arr[i:i + 32]))
+ return o
+
+
+def encode_abi(funid, *args):
+ len_args = ''
+ normal_args = ''
+ var_args = ''
+ for arg in args:
+ if isinstance(arg, str) and len(arg) and \
+ arg[0] == '"' and arg[-1] == '"':
+ len_args += enc(numberize(len(arg[1:-1])))
+ var_args += arg[1:-1]
+ elif isinstance(arg, list):
+ for a in arg:
+ var_args += enc(numberize(a))
+ len_args += enc(numberize(len(arg)))
+ else:
+ normal_args += enc(numberize(arg))
+ return chr(int(funid)) + len_args + normal_args + var_args
+
+
+def decode_abi(arr, *lens):
+ o = []
+ pos = 1
+ i = 0
+ if len(lens) == 1 and isinstance(lens[0], list):
+ lens = lens[0]
+ while pos < len(arr):
+ bytez = int(lens[i]) if i < len(lens) else 32
+ o.append(frombytes(arr[pos: pos + bytez]))
+ i, pos = i + 1, pos + bytez
+ return o
+
+
+def main():
+ if len(sys.argv) == 1:
+ print "serpent <command> <arg1> <arg2> ..."
+ else:
+ cmd = sys.argv[2] if sys.argv[1] == '-s' else sys.argv[1]
+ if sys.argv[1] == '-s':
+ args = [sys.stdin.read()] + sys.argv[3:]
+ elif sys.argv[1] == '-v':
+ print VERSION
+ sys.exit()
+ else:
+ cmd = sys.argv[1]
+ args = sys.argv[2:]
+ if cmd in ['deserialize', 'decode_datalist', 'decode_abi']:
+ args[0] = args[0].strip().decode('hex')
+ o = globals()[cmd](*args)
+ if isinstance(o, (Token, Astnode, list)):
+ print repr(o)
+ else:
+ print o.encode('hex')
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/setup.py b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/setup.py
new file mode 100644
index 000000000..5fdc1c16a
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/setup.py
@@ -0,0 +1,46 @@
+from setuptools import setup, Extension
+
+import os
+from distutils.sysconfig import get_config_vars
+
+(opt,) = get_config_vars('OPT')
+os.environ['OPT'] = " ".join(
+ flag for flag in opt.split() if flag != '-Wstrict-prototypes'
+)
+
+setup(
+ # Name of this package
+ name="ethereum-serpent",
+
+ # Package version
+ version='1.7.7',
+
+ description='Serpent compiler',
+ maintainer='Vitalik Buterin',
+ maintainer_email='v@buterin.com',
+ license='WTFPL',
+ url='http://www.ethereum.org/',
+
+ # Describes how to build the actual extension module from C source files.
+ ext_modules=[
+ Extension(
+ 'serpent_pyext', # Python name of the module
+ ['bignum.cpp', 'util.cpp', 'tokenize.cpp',
+ 'lllparser.cpp', 'parser.cpp', 'functions.cpp',
+ 'optimize.cpp', 'opcodes.cpp',
+ 'rewriteutils.cpp', 'preprocess.cpp', 'rewriter.cpp',
+ 'compiler.cpp', 'funcs.cpp', 'pyserpent.cpp']
+ )],
+ py_modules=[
+ 'serpent',
+ 'pyserpent'
+ ],
+ scripts=[
+ 'serpent.py'
+ ],
+ entry_points={
+ 'console_scripts': [
+ 'serpent = serpent:main',
+ ],
+ }
+ ),
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/tokenize.cpp b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/tokenize.cpp
new file mode 100644
index 000000000..b60cc8a44
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/tokenize.cpp
@@ -0,0 +1,115 @@
+#include <stdio.h>
+#include <iostream>
+#include <vector>
+#include <map>
+#include "util.h"
+
+// These appear as independent tokens even if inside a stream of symbols
+const std::string atoms[] = { "#", "//", "(", ")", "[", "]", "{", "}" };
+const int numAtoms = 8;
+
+// Is the char alphanumeric, a space, a bracket, a quote, a symbol?
+int chartype(char c) {
+ if (c >= '0' && c <= '9') return ALPHANUM;
+ else if (c >= 'a' && c <= 'z') return ALPHANUM;
+ else if (c >= 'A' && c <= 'Z') return ALPHANUM;
+ else if (std::string("~_$@").find(c) != std::string::npos) return ALPHANUM;
+ else if (c == '\t' || c == ' ' || c == '\n' || c == '\r') return SPACE;
+ else if (std::string("()[]{}").find(c) != std::string::npos) return BRACK;
+ else if (c == '"') return DQUOTE;
+ else if (c == '\'') return SQUOTE;
+ else return SYMB;
+}
+
+// "y = f(45,124)/3" -> [ "y", "f", "(", "45", ",", "124", ")", "/", "3"]
+std::vector<Node> tokenize(std::string inp, Metadata metadata, bool lispMode) {
+ int curtype = SPACE;
+ unsigned pos = 0;
+ int lastNewline = 0;
+ metadata.ch = 0;
+ std::string cur;
+ std::vector<Node> out;
+
+ inp += " ";
+ while (pos < inp.length()) {
+ int headtype = chartype(inp[pos]);
+ if (lispMode) {
+ if (inp[pos] == '\'') headtype = ALPHANUM;
+ }
+ // Are we inside a quote?
+ if (curtype == SQUOTE || curtype == DQUOTE) {
+ // Close quote
+ if (headtype == curtype) {
+ cur += inp[pos];
+ out.push_back(token(cur, metadata));
+ cur = "";
+ metadata.ch = pos - lastNewline;
+ curtype = SPACE;
+ pos += 1;
+ }
+ // eg. \xc3
+ else if (inp.length() >= pos + 4 && inp.substr(pos, 2) == "\\x") {
+ cur += (std::string("0123456789abcdef").find(inp[pos+2]) * 16
+ + std::string("0123456789abcdef").find(inp[pos+3]));
+ pos += 4;
+ }
+ // Newline
+ else if (inp.substr(pos, 2) == "\\n") {
+ cur += '\n';
+ pos += 2;
+ }
+ // Backslash escape
+ else if (inp.length() >= pos + 2 && inp[pos] == '\\') {
+ cur += inp[pos + 1];
+ pos += 2;
+ }
+ // Normal character
+ else {
+ cur += inp[pos];
+ pos += 1;
+ }
+ }
+ else {
+ // Handle atoms ( '//', '#', brackets )
+ for (int i = 0; i < numAtoms; i++) {
+ int split = cur.length() - atoms[i].length();
+ if (split >= 0 && cur.substr(split) == atoms[i]) {
+ if (split > 0) {
+ out.push_back(token(cur.substr(0, split), metadata));
+ }
+ metadata.ch += split;
+ out.push_back(token(cur.substr(split), metadata));
+ metadata.ch = pos - lastNewline;
+ cur = "";
+ curtype = SPACE;
+ }
+ }
+ // Special case the minus sign
+ if (cur.length() > 1 && (cur.substr(cur.length() - 1) == "-"
+ || cur.substr(cur.length() - 1) == "!")) {
+ out.push_back(token(cur.substr(0, cur.length() - 1), metadata));
+ out.push_back(token(cur.substr(cur.length() - 1), metadata));
+ cur = "";
+ }
+ // Boundary between different char types
+ if (headtype != curtype) {
+ if (curtype != SPACE && cur != "") {
+ out.push_back(token(cur, metadata));
+ }
+ metadata.ch = pos - lastNewline;
+ cur = "";
+ }
+ cur += inp[pos];
+ curtype = headtype;
+ pos += 1;
+ }
+ if (inp[pos] == '\n') {
+ lastNewline = pos;
+ metadata.ch = 0;
+ metadata.ln += 1;
+ }
+ }
+ return out;
+}
+
+
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/tokenize.h b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/tokenize.h
new file mode 100644
index 000000000..04a42f3c6
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/tokenize.h
@@ -0,0 +1,16 @@
+#ifndef ETHSERP_TOKENIZE
+#define ETHSERP_TOKENIZE
+
+#include <stdio.h>
+#include <iostream>
+#include <vector>
+#include <map>
+#include "util.h"
+
+int chartype(char c);
+
+std::vector<Node> tokenize(std::string inp,
+ Metadata meta=Metadata(),
+ bool lispMode=false);
+
+#endif
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/util.cpp b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/util.cpp
new file mode 100644
index 000000000..56f642fc8
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/util.cpp
@@ -0,0 +1,305 @@
+#include <stdio.h>
+#include <iostream>
+#include <vector>
+#include <map>
+#include "util.h"
+#include "bignum.h"
+#include <fstream>
+#include <cerrno>
+
+//Token or value node constructor
+Node token(std::string val, Metadata met) {
+ Node o;
+ o.type = 0;
+ o.val = val;
+ o.metadata = met;
+ return o;
+}
+
+//AST node constructor
+Node astnode(std::string val, std::vector<Node> args, Metadata met) {
+ Node o;
+ o.type = 1;
+ o.val = val;
+ o.args = args;
+ o.metadata = met;
+ return o;
+}
+
+//AST node constructors for a specific number of children
+Node astnode(std::string val, Metadata met) {
+ std::vector<Node> args;
+ return astnode(val, args, met);
+}
+
+Node astnode(std::string val, Node a, Metadata met) {
+ std::vector<Node> args;
+ args.push_back(a);
+ return astnode(val, args, met);
+}
+
+Node astnode(std::string val, Node a, Node b, Metadata met) {
+ std::vector<Node> args;
+ args.push_back(a);
+ args.push_back(b);
+ return astnode(val, args, met);
+}
+
+Node astnode(std::string val, Node a, Node b, Node c, Metadata met) {
+ std::vector<Node> args;
+ args.push_back(a);
+ args.push_back(b);
+ args.push_back(c);
+ return astnode(val, args, met);
+}
+
+Node astnode(std::string val, Node a, Node b, Node c, Node d, Metadata met) {
+ std::vector<Node> args;
+ args.push_back(a);
+ args.push_back(b);
+ args.push_back(c);
+ args.push_back(d);
+ return astnode(val, args, met);
+}
+
+
+// Print token list
+std::string printTokens(std::vector<Node> tokens) {
+ std::string s = "";
+ for (unsigned i = 0; i < tokens.size(); i++) {
+ s += tokens[i].val + " ";
+ }
+ return s;
+}
+
+// Prints a lisp AST on one line
+std::string printSimple(Node ast) {
+ if (ast.type == TOKEN) return ast.val;
+ std::string o = "(" + ast.val;
+ std::vector<std::string> subs;
+ for (unsigned i = 0; i < ast.args.size(); i++) {
+ o += " " + printSimple(ast.args[i]);
+ }
+ return o + ")";
+}
+
+// Number of tokens in a tree
+int treeSize(Node prog) {
+ if (prog.type == TOKEN) return 1;
+ int o = 0;
+ for (unsigned i = 0; i < prog.args.size(); i++) o += treeSize(prog.args[i]);
+ return o;
+}
+
+// Pretty-prints a lisp AST
+std::string printAST(Node ast, bool printMetadata) {
+ if (ast.type == TOKEN) return ast.val;
+ std::string o = "(";
+ if (printMetadata) {
+ o += ast.metadata.file + " ";
+ o += unsignedToDecimal(ast.metadata.ln) + " ";
+ o += unsignedToDecimal(ast.metadata.ch) + ": ";
+ }
+ o += ast.val;
+ std::vector<std::string> subs;
+ for (unsigned i = 0; i < ast.args.size(); i++) {
+ subs.push_back(printAST(ast.args[i], printMetadata));
+ }
+ unsigned k = 0;
+ std::string out = " ";
+ // As many arguments as possible go on the same line as the function,
+ // except when seq is used
+ while (k < subs.size() && o != "(seq") {
+ if (subs[k].find("\n") != std::string::npos || (out + subs[k]).length() >= 80) break;
+ out += subs[k] + " ";
+ k += 1;
+ }
+ // All remaining arguments go on their own lines
+ if (k < subs.size()) {
+ o += out + "\n";
+ std::vector<std::string> subsSliceK;
+ for (unsigned i = k; i < subs.size(); i++) subsSliceK.push_back(subs[i]);
+ o += indentLines(joinLines(subsSliceK));
+ o += "\n)";
+ }
+ else {
+ o += out.substr(0, out.size() - 1) + ")";
+ }
+ return o;
+}
+
+// Splits text by line
+std::vector<std::string> splitLines(std::string s) {
+ unsigned pos = 0;
+ int lastNewline = 0;
+ std::vector<std::string> o;
+ while (pos < s.length()) {
+ if (s[pos] == '\n') {
+ o.push_back(s.substr(lastNewline, pos - lastNewline));
+ lastNewline = pos + 1;
+ }
+ pos = pos + 1;
+ }
+ o.push_back(s.substr(lastNewline));
+ return o;
+}
+
+// Inverse of splitLines
+std::string joinLines(std::vector<std::string> lines) {
+ std::string o = "\n";
+ for (unsigned i = 0; i < lines.size(); i++) {
+ o += lines[i] + "\n";
+ }
+ return o.substr(1, o.length() - 2);
+}
+
+// Indent all lines by 4 spaces
+std::string indentLines(std::string inp) {
+ std::vector<std::string> lines = splitLines(inp);
+ for (unsigned i = 0; i < lines.size(); i++) lines[i] = " "+lines[i];
+ return joinLines(lines);
+}
+
+// Binary to hexadecimal
+std::string binToNumeric(std::string inp) {
+ std::string o = "0";
+ for (unsigned i = 0; i < inp.length(); i++) {
+ o = decimalAdd(decimalMul(o,"256"), unsignedToDecimal((unsigned char)inp[i]));
+ }
+ return o;
+}
+
+// Converts string to simple numeric format
+std::string strToNumeric(std::string inp) {
+ std::string o = "0";
+ if (inp == "") {
+ o = "";
+ }
+ else if (inp.substr(0,2) == "0x") {
+ for (unsigned i = 2; i < inp.length(); i++) {
+ int dig = std::string("0123456789abcdef0123456789ABCDEF").find(inp[i]) % 16;
+ if (dig < 0) return "";
+ o = decimalAdd(decimalMul(o,"16"), unsignedToDecimal(dig));
+ }
+ }
+ else {
+ bool isPureNum = true;
+ for (unsigned i = 0; i < inp.length(); i++) {
+ isPureNum = isPureNum && inp[i] >= '0' && inp[i] <= '9';
+ }
+ o = isPureNum ? inp : "";
+ }
+ return o;
+}
+
+// Does the node contain a number (eg. 124, 0xf012c, "george")
+bool isNumberLike(Node node) {
+ if (node.type == ASTNODE) return false;
+ return strToNumeric(node.val) != "";
+}
+
+//Normalizes number representations
+Node nodeToNumeric(Node node) {
+ std::string o = strToNumeric(node.val);
+ return token(o == "" ? node.val : o, node.metadata);
+}
+
+Node tryNumberize(Node node) {
+ if (node.type == TOKEN && isNumberLike(node)) return nodeToNumeric(node);
+ return node;
+}
+
+//Converts a value to an array of byte number nodes
+std::vector<Node> toByteArr(std::string val, Metadata metadata, int minLen) {
+ std::vector<Node> o;
+ int L = 0;
+ while (val != "0" || L < minLen) {
+ o.push_back(token(decimalMod(val, "256"), metadata));
+ val = decimalDiv(val, "256");
+ L++;
+ }
+ std::vector<Node> o2;
+ for (int i = o.size() - 1; i >= 0; i--) o2.push_back(o[i]);
+ return o2;
+}
+
+int counter = 0;
+
+//Makes a unique token
+std::string mkUniqueToken() {
+ counter++;
+ return unsignedToDecimal(counter);
+}
+
+//Does a file exist? http://stackoverflow.com/questions/12774207
+bool exists(std::string fileName) {
+ std::ifstream infile(fileName.c_str());
+ return infile.good();
+}
+
+//Reads a file: http://stackoverflow.com/questions/2602013
+std::string get_file_contents(std::string filename)
+{
+ std::ifstream in(filename.c_str(), std::ios::in | std::ios::binary);
+ if (in)
+ {
+ std::string contents;
+ in.seekg(0, std::ios::end);
+ contents.resize(in.tellg());
+ in.seekg(0, std::ios::beg);
+ in.read(&contents[0], contents.size());
+ in.close();
+ return(contents);
+ }
+ throw(errno);
+}
+
+//Report error
+void err(std::string errtext, Metadata met) {
+ std::string err = "Error (file \"" + met.file + "\", line " +
+ unsignedToDecimal(met.ln + 1) + ", char " + unsignedToDecimal(met.ch) +
+ "): " + errtext;
+ std::cerr << err << "\n";
+ throw(err);
+}
+
+//Bin to hex
+std::string binToHex(std::string inp) {
+ std::string o = "";
+ for (unsigned i = 0; i < inp.length(); i++) {
+ unsigned char v = inp[i];
+ o += std::string("0123456789abcdef").substr(v/16, 1)
+ + std::string("0123456789abcdef").substr(v%16, 1);
+ }
+ return o;
+}
+
+//Hex to bin
+std::string hexToBin(std::string inp) {
+ std::string o = "";
+ for (unsigned i = 0; i+1 < inp.length(); i+=2) {
+ char v = (char)(std::string("0123456789abcdef").find(inp[i]) * 16 +
+ std::string("0123456789abcdef").find(inp[i+1]));
+ o += v;
+ }
+ return o;
+}
+
+//Lower to upper
+std::string upperCase(std::string inp) {
+ std::string o = "";
+ for (unsigned i = 0; i < inp.length(); i++) {
+ if (inp[i] >= 97 && inp[i] <= 122) o += inp[i] - 32;
+ else o += inp[i];
+ }
+ return o;
+}
+
+//Three-int vector
+std::vector<int> triple(int a, int b, int c) {
+ std::vector<int> v;
+ v.push_back(a);
+ v.push_back(b);
+ v.push_back(c);
+ return v;
+}
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/util.h b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/util.h
new file mode 100644
index 000000000..f7d6744f9
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/serpent/util.h
@@ -0,0 +1,127 @@
+#ifndef ETHSERP_UTIL
+#define ETHSERP_UTIL
+
+#include <stdio.h>
+#include <iostream>
+#include <vector>
+#include <map>
+#include <fstream>
+#include <cerrno>
+
+const int TOKEN = 0,
+ ASTNODE = 1,
+ SPACE = 2,
+ BRACK = 3,
+ SQUOTE = 4,
+ DQUOTE = 5,
+ SYMB = 6,
+ ALPHANUM = 7,
+ LPAREN = 8,
+ RPAREN = 9,
+ COMMA = 10,
+ COLON = 11,
+ UNARY_OP = 12,
+ BINARY_OP = 13,
+ COMPOUND = 14,
+ TOKEN_SPLITTER = 15;
+
+// Stores metadata about each token
+class Metadata {
+ public:
+ Metadata(std::string File="main", int Ln=-1, int Ch=-1) {
+ file = File;
+ ln = Ln;
+ ch = Ch;
+ fixed = false;
+ }
+ std::string file;
+ int ln;
+ int ch;
+ bool fixed;
+};
+
+std::string mkUniqueToken();
+
+// type can be TOKEN or ASTNODE
+struct Node {
+ int type;
+ std::string val;
+ std::vector<Node> args;
+ Metadata metadata;
+};
+Node token(std::string val, Metadata met=Metadata());
+Node astnode(std::string val, std::vector<Node> args, Metadata met=Metadata());
+Node astnode(std::string val, Metadata met=Metadata());
+Node astnode(std::string val, Node a, Metadata met=Metadata());
+Node astnode(std::string val, Node a, Node b, Metadata met=Metadata());
+Node astnode(std::string val, Node a, Node b, Node c, Metadata met=Metadata());
+Node astnode(std::string val, Node a, Node b,
+ Node c, Node d, Metadata met=Metadata());
+
+// Number of tokens in a tree
+int treeSize(Node prog);
+
+// Print token list
+std::string printTokens(std::vector<Node> tokens);
+
+// Prints a lisp AST on one line
+std::string printSimple(Node ast);
+
+// Pretty-prints a lisp AST
+std::string printAST(Node ast, bool printMetadata=false);
+
+// Splits text by line
+std::vector<std::string> splitLines(std::string s);
+
+// Inverse of splitLines
+std::string joinLines(std::vector<std::string> lines);
+
+// Indent all lines by 4 spaces
+std::string indentLines(std::string inp);
+
+// Converts binary to simple numeric format
+std::string binToNumeric(std::string inp);
+
+// Converts string to simple numeric format
+std::string strToNumeric(std::string inp);
+
+// Does the node contain a number (eg. 124, 0xf012c, "george")
+bool isNumberLike(Node node);
+
+//Normalizes number representations
+Node nodeToNumeric(Node node);
+
+//If a node is numeric, normalize its representation
+Node tryNumberize(Node node);
+
+//Converts a value to an array of byte number nodes
+std::vector<Node> toByteArr(std::string val, Metadata metadata, int minLen=1);
+
+//Reads a file
+std::string get_file_contents(std::string filename);
+
+//Does a file exist?
+bool exists(std::string fileName);
+
+//Report error
+void err(std::string errtext, Metadata met);
+
+//Bin to hex
+std::string binToHex(std::string inp);
+
+//Hex to bin
+std::string hexToBin(std::string inp);
+
+//Lower to upper
+std::string upperCase(std::string inp);
+
+//Three-int vector
+std::vector<int> triple(int a, int b, int c);
+
+#define asn astnode
+#define tkn token
+#define msi std::map<std::string, int>
+#define msn std::map<std::string, Node>
+#define mss std::map<std::string, std::string>
+
+#endif
diff --git a/Godeps/_workspace/src/github.com/ethereum/serpent-go/tests/main.go b/Godeps/_workspace/src/github.com/ethereum/serpent-go/tests/main.go
new file mode 100644
index 000000000..2f2d17784
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/ethereum/serpent-go/tests/main.go
@@ -0,0 +1,21 @@
+package main
+
+import (
+ "fmt"
+
+ "github.com/ethereum/serpent-go"
+)
+
+func main() {
+ out, _ := serpent.Compile(`
+// Namecoin
+if !contract.storage[msg.data[0]]: # Is the key not yet taken?
+ # Then take it!
+ contract.storage[msg.data[0]] = msg.data[1]
+ return(1)
+else:
+ return(0) // Otherwise do nothing
+ `)
+
+ fmt.Printf("%x\n", out)
+}
diff --git a/Godeps/_workspace/src/github.com/howeyc/fsnotify/.gitignore b/Godeps/_workspace/src/github.com/howeyc/fsnotify/.gitignore
new file mode 100644
index 000000000..e4706a9e9
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/howeyc/fsnotify/.gitignore
@@ -0,0 +1,5 @@
+# Setup a Global .gitignore for OS and editor generated files:
+# https://help.github.com/articles/ignoring-files
+# git config --global core.excludesfile ~/.gitignore_global
+
+.vagrant
diff --git a/Godeps/_workspace/src/github.com/howeyc/fsnotify/AUTHORS b/Godeps/_workspace/src/github.com/howeyc/fsnotify/AUTHORS
new file mode 100644
index 000000000..e52b72f83
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/howeyc/fsnotify/AUTHORS
@@ -0,0 +1,28 @@
+# Names should be added to this file as
+# Name or Organization <email address>
+# The email address is not required for organizations.
+
+# You can update this list using the following command:
+#
+# $ git shortlog -se | awk '{print $2 " " $3 " " $4}'
+
+# Please keep the list sorted.
+
+Adrien Bustany <adrien@bustany.org>
+Caleb Spare <cespare@gmail.com>
+Case Nelson <case@teammating.com>
+Chris Howey <howeyc@gmail.com> <chris@howey.me>
+Christoffer Buchholz <christoffer.buchholz@gmail.com>
+Dave Cheney <dave@cheney.net>
+Francisco Souza <f@souza.cc>
+John C Barstow
+Kelvin Fo <vmirage@gmail.com>
+Nathan Youngman <git@nathany.com>
+Paul Hammond <paul@paulhammond.org>
+Pursuit92 <JoshChase@techpursuit.net>
+Rob Figueiredo <robfig@gmail.com>
+Travis Cline <travis.cline@gmail.com>
+Tudor Golubenco <tudor.g@gmail.com>
+bronze1man <bronze1man@gmail.com>
+debrando <denis.brandolini@gmail.com>
+henrikedwards <henrik.edwards@gmail.com>
diff --git a/Godeps/_workspace/src/github.com/howeyc/fsnotify/CHANGELOG.md b/Godeps/_workspace/src/github.com/howeyc/fsnotify/CHANGELOG.md
new file mode 100644
index 000000000..761686aa9
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/howeyc/fsnotify/CHANGELOG.md
@@ -0,0 +1,160 @@
+# Changelog
+
+## v0.9.0 / 2014-01-17
+
+* IsAttrib() for events that only concern a file's metadata [#79][] (thanks @abustany)
+* [Fix] kqueue: fix deadlock [#77][] (thanks @cespare)
+* [NOTICE] Development has moved to `code.google.com/p/go.exp/fsnotify` in preparation for inclusion in the Go standard library.
+
+## v0.8.12 / 2013-11-13
+
+* [API] Remove FD_SET and friends from Linux adapter
+
+## v0.8.11 / 2013-11-02
+
+* [Doc] Add Changelog [#72][] (thanks @nathany)
+* [Doc] Spotlight and double modify events on OS X [#62][] (reported by @paulhammond)
+
+## v0.8.10 / 2013-10-19
+
+* [Fix] kqueue: remove file watches when parent directory is removed [#71][] (reported by @mdwhatcott)
+* [Fix] kqueue: race between Close and readEvents [#70][] (reported by @bernerdschaefer)
+* [Doc] specify OS-specific limits in README (thanks @debrando)
+
+## v0.8.9 / 2013-09-08
+
+* [Doc] Contributing (thanks @nathany)
+* [Doc] update package path in example code [#63][] (thanks @paulhammond)
+* [Doc] GoCI badge in README (Linux only) [#60][]
+* [Doc] Cross-platform testing with Vagrant [#59][] (thanks @nathany)
+
+## v0.8.8 / 2013-06-17
+
+* [Fix] Windows: handle `ERROR_MORE_DATA` on Windows [#49][] (thanks @jbowtie)
+
+## v0.8.7 / 2013-06-03
+
+* [API] Make syscall flags internal
+* [Fix] inotify: ignore event changes
+* [Fix] race in symlink test [#45][] (reported by @srid)
+* [Fix] tests on Windows
+* lower case error messages
+
+## v0.8.6 / 2013-05-23
+
+* kqueue: Use EVT_ONLY flag on Darwin
+* [Doc] Update README with full example
+
+## v0.8.5 / 2013-05-09
+
+* [Fix] inotify: allow monitoring of "broken" symlinks (thanks @tsg)
+
+## v0.8.4 / 2013-04-07
+
+* [Fix] kqueue: watch all file events [#40][] (thanks @ChrisBuchholz)
+
+## v0.8.3 / 2013-03-13
+
+* [Fix] inoitfy/kqueue memory leak [#36][] (reported by @nbkolchin)
+* [Fix] kqueue: use fsnFlags for watching a directory [#33][] (reported by @nbkolchin)
+
+## v0.8.2 / 2013-02-07
+
+* [Doc] add Authors
+* [Fix] fix data races for map access [#29][] (thanks @fsouza)
+
+## v0.8.1 / 2013-01-09
+
+* [Fix] Windows path separators
+* [Doc] BSD License
+
+## v0.8.0 / 2012-11-09
+
+* kqueue: directory watching improvements (thanks @vmirage)
+* inotify: add `IN_MOVED_TO` [#25][] (requested by @cpisto)
+* [Fix] kqueue: deleting watched directory [#24][] (reported by @jakerr)
+
+## v0.7.4 / 2012-10-09
+
+* [Fix] inotify: fixes from https://codereview.appspot.com/5418045/ (ugorji)
+* [Fix] kqueue: preserve watch flags when watching for delete [#21][] (reported by @robfig)
+* [Fix] kqueue: watch the directory even if it isn't a new watch (thanks @robfig)
+* [Fix] kqueue: modify after recreation of file
+
+## v0.7.3 / 2012-09-27
+
+* [Fix] kqueue: watch with an existing folder inside the watched folder (thanks @vmirage)
+* [Fix] kqueue: no longer get duplicate CREATE events
+
+## v0.7.2 / 2012-09-01
+
+* kqueue: events for created directories
+
+## v0.7.1 / 2012-07-14
+
+* [Fix] for renaming files
+
+## v0.7.0 / 2012-07-02
+
+* [Feature] FSNotify flags
+* [Fix] inotify: Added file name back to event path
+
+## v0.6.0 / 2012-06-06
+
+* kqueue: watch files after directory created (thanks @tmc)
+
+## v0.5.1 / 2012-05-22
+
+* [Fix] inotify: remove all watches before Close()
+
+## v0.5.0 / 2012-05-03
+
+* [API] kqueue: return errors during watch instead of sending over channel
+* kqueue: match symlink behavior on Linux
+* inotify: add `DELETE_SELF` (requested by @taralx)
+* [Fix] kqueue: handle EINTR (reported by @robfig)
+* [Doc] Godoc example [#1][] (thanks @davecheney)
+
+## v0.4.0 / 2012-03-30
+
+* Go 1 released: build with go tool
+* [Feature] Windows support using winfsnotify
+* Windows does not have attribute change notifications
+* Roll attribute notifications into IsModify
+
+## v0.3.0 / 2012-02-19
+
+* kqueue: add files when watch directory
+
+## v0.2.0 / 2011-12-30
+
+* update to latest Go weekly code
+
+## v0.1.0 / 2011-10-19
+
+* kqueue: add watch on file creation to match inotify
+* kqueue: create file event
+* inotify: ignore `IN_IGNORED` events
+* event String()
+* linux: common FileEvent functions
+* initial commit
+
+[#79]: https://github.com/howeyc/fsnotify/pull/79
+[#77]: https://github.com/howeyc/fsnotify/pull/77
+[#72]: https://github.com/howeyc/fsnotify/issues/72
+[#71]: https://github.com/howeyc/fsnotify/issues/71
+[#70]: https://github.com/howeyc/fsnotify/issues/70
+[#63]: https://github.com/howeyc/fsnotify/issues/63
+[#62]: https://github.com/howeyc/fsnotify/issues/62
+[#60]: https://github.com/howeyc/fsnotify/issues/60
+[#59]: https://github.com/howeyc/fsnotify/issues/59
+[#49]: https://github.com/howeyc/fsnotify/issues/49
+[#45]: https://github.com/howeyc/fsnotify/issues/45
+[#40]: https://github.com/howeyc/fsnotify/issues/40
+[#36]: https://github.com/howeyc/fsnotify/issues/36
+[#33]: https://github.com/howeyc/fsnotify/issues/33
+[#29]: https://github.com/howeyc/fsnotify/issues/29
+[#25]: https://github.com/howeyc/fsnotify/issues/25
+[#24]: https://github.com/howeyc/fsnotify/issues/24
+[#21]: https://github.com/howeyc/fsnotify/issues/21
+[#1]: https://github.com/howeyc/fsnotify/issues/1
diff --git a/Godeps/_workspace/src/github.com/howeyc/fsnotify/CONTRIBUTING.md b/Godeps/_workspace/src/github.com/howeyc/fsnotify/CONTRIBUTING.md
new file mode 100644
index 000000000..b2025d72c
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/howeyc/fsnotify/CONTRIBUTING.md
@@ -0,0 +1,7 @@
+# Contributing
+
+## Moving Notice
+
+There is a fork being actively developed with a new API in preparation for the Go Standard Library:
+[github.com/go-fsnotify/fsnotify](https://github.com/go-fsnotify/fsnotify)
+
diff --git a/Godeps/_workspace/src/github.com/howeyc/fsnotify/LICENSE b/Godeps/_workspace/src/github.com/howeyc/fsnotify/LICENSE
new file mode 100644
index 000000000..f21e54080
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/howeyc/fsnotify/LICENSE
@@ -0,0 +1,28 @@
+Copyright (c) 2012 The Go Authors. All rights reserved.
+Copyright (c) 2012 fsnotify Authors. All rights reserved.
+
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions are
+met:
+
+ * Redistributions of source code must retain the above copyright
+notice, this list of conditions and the following disclaimer.
+ * Redistributions in binary form must reproduce the above
+copyright notice, this list of conditions and the following disclaimer
+in the documentation and/or other materials provided with the
+distribution.
+ * Neither the name of Google Inc. nor the names of its
+contributors may be used to endorse or promote products derived from
+this software without specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
diff --git a/Godeps/_workspace/src/github.com/howeyc/fsnotify/README.md b/Godeps/_workspace/src/github.com/howeyc/fsnotify/README.md
new file mode 100644
index 000000000..4c7498d38
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/howeyc/fsnotify/README.md
@@ -0,0 +1,92 @@
+# File system notifications for Go
+
+[![GoDoc](https://godoc.org/github.com/howeyc/fsnotify?status.png)](http://godoc.org/github.com/howeyc/fsnotify)
+
+Cross platform: Windows, Linux, BSD and OS X.
+
+## Moving Notice
+
+There is a fork being actively developed with a new API in preparation for the Go Standard Library:
+[github.com/go-fsnotify/fsnotify](https://github.com/go-fsnotify/fsnotify)
+
+## Example:
+
+```go
+package main
+
+import (
+ "log"
+
+ "github.com/howeyc/fsnotify"
+)
+
+func main() {
+ watcher, err := fsnotify.NewWatcher()
+ if err != nil {
+ log.Fatal(err)
+ }
+
+ done := make(chan bool)
+
+ // Process events
+ go func() {
+ for {
+ select {
+ case ev := <-watcher.Event:
+ log.Println("event:", ev)
+ case err := <-watcher.Error:
+ log.Println("error:", err)
+ }
+ }
+ }()
+
+ err = watcher.Watch("testDir")
+ if err != nil {
+ log.Fatal(err)
+ }
+
+ <-done
+
+ /* ... do stuff ... */
+ watcher.Close()
+}
+```
+
+For each event:
+* Name
+* IsCreate()
+* IsDelete()
+* IsModify()
+* IsRename()
+
+## FAQ
+
+**When a file is moved to another directory is it still being watched?**
+
+No (it shouldn't be, unless you are watching where it was moved to).
+
+**When I watch a directory, are all subdirectories watched as well?**
+
+No, you must add watches for any directory you want to watch (a recursive watcher is in the works [#56][]).
+
+**Do I have to watch the Error and Event channels in a separate goroutine?**
+
+As of now, yes. Looking into making this single-thread friendly (see [#7][])
+
+**Why am I receiving multiple events for the same file on OS X?**
+
+Spotlight indexing on OS X can result in multiple events (see [#62][]). A temporary workaround is to add your folder(s) to the *Spotlight Privacy settings* until we have a native FSEvents implementation (see [#54][]).
+
+**How many files can be watched at once?**
+
+There are OS-specific limits as to how many watches can be created:
+* Linux: /proc/sys/fs/inotify/max_user_watches contains the limit,
+reaching this limit results in a "no space left on device" error.
+* BSD / OSX: sysctl variables "kern.maxfiles" and "kern.maxfilesperproc", reaching these limits results in a "too many open files" error.
+
+
+[#62]: https://github.com/howeyc/fsnotify/issues/62
+[#56]: https://github.com/howeyc/fsnotify/issues/56
+[#54]: https://github.com/howeyc/fsnotify/issues/54
+[#7]: https://github.com/howeyc/fsnotify/issues/7
+
diff --git a/Godeps/_workspace/src/github.com/howeyc/fsnotify/example_test.go b/Godeps/_workspace/src/github.com/howeyc/fsnotify/example_test.go
new file mode 100644
index 000000000..d3130e222
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/howeyc/fsnotify/example_test.go
@@ -0,0 +1,34 @@
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+package fsnotify_test
+
+import (
+ "log"
+
+ "github.com/howeyc/fsnotify"
+)
+
+func ExampleNewWatcher() {
+ watcher, err := fsnotify.NewWatcher()
+ if err != nil {
+ log.Fatal(err)
+ }
+
+ go func() {
+ for {
+ select {
+ case ev := <-watcher.Event:
+ log.Println("event:", ev)
+ case err := <-watcher.Error:
+ log.Println("error:", err)
+ }
+ }
+ }()
+
+ err = watcher.Watch("/tmp/foo")
+ if err != nil {
+ log.Fatal(err)
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/howeyc/fsnotify/fsnotify.go b/Godeps/_workspace/src/github.com/howeyc/fsnotify/fsnotify.go
new file mode 100644
index 000000000..9a48d847d
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/howeyc/fsnotify/fsnotify.go
@@ -0,0 +1,111 @@
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Package fsnotify implements file system notification.
+package fsnotify
+
+import "fmt"
+
+const (
+ FSN_CREATE = 1
+ FSN_MODIFY = 2
+ FSN_DELETE = 4
+ FSN_RENAME = 8
+
+ FSN_ALL = FSN_MODIFY | FSN_DELETE | FSN_RENAME | FSN_CREATE
+)
+
+// Purge events from interal chan to external chan if passes filter
+func (w *Watcher) purgeEvents() {
+ for ev := range w.internalEvent {
+ sendEvent := false
+ w.fsnmut.Lock()
+ fsnFlags := w.fsnFlags[ev.Name]
+ w.fsnmut.Unlock()
+
+ if (fsnFlags&FSN_CREATE == FSN_CREATE) && ev.IsCreate() {
+ sendEvent = true
+ }
+
+ if (fsnFlags&FSN_MODIFY == FSN_MODIFY) && ev.IsModify() {
+ sendEvent = true
+ }
+
+ if (fsnFlags&FSN_DELETE == FSN_DELETE) && ev.IsDelete() {
+ sendEvent = true
+ }
+
+ if (fsnFlags&FSN_RENAME == FSN_RENAME) && ev.IsRename() {
+ sendEvent = true
+ }
+
+ if sendEvent {
+ w.Event <- ev
+ }
+
+ // If there's no file, then no more events for user
+ // BSD must keep watch for internal use (watches DELETEs to keep track
+ // what files exist for create events)
+ if ev.IsDelete() {
+ w.fsnmut.Lock()
+ delete(w.fsnFlags, ev.Name)
+ w.fsnmut.Unlock()
+ }
+ }
+
+ close(w.Event)
+}
+
+// Watch a given file path
+func (w *Watcher) Watch(path string) error {
+ return w.WatchFlags(path, FSN_ALL)
+}
+
+// Watch a given file path for a particular set of notifications (FSN_MODIFY etc.)
+func (w *Watcher) WatchFlags(path string, flags uint32) error {
+ w.fsnmut.Lock()
+ w.fsnFlags[path] = flags
+ w.fsnmut.Unlock()
+ return w.watch(path)
+}
+
+// Remove a watch on a file
+func (w *Watcher) RemoveWatch(path string) error {
+ w.fsnmut.Lock()
+ delete(w.fsnFlags, path)
+ w.fsnmut.Unlock()
+ return w.removeWatch(path)
+}
+
+// String formats the event e in the form
+// "filename: DELETE|MODIFY|..."
+func (e *FileEvent) String() string {
+ var events string = ""
+
+ if e.IsCreate() {
+ events += "|" + "CREATE"
+ }
+
+ if e.IsDelete() {
+ events += "|" + "DELETE"
+ }
+
+ if e.IsModify() {
+ events += "|" + "MODIFY"
+ }
+
+ if e.IsRename() {
+ events += "|" + "RENAME"
+ }
+
+ if e.IsAttrib() {
+ events += "|" + "ATTRIB"
+ }
+
+ if len(events) > 0 {
+ events = events[1:]
+ }
+
+ return fmt.Sprintf("%q: %s", e.Name, events)
+}
diff --git a/Godeps/_workspace/src/github.com/howeyc/fsnotify/fsnotify_bsd.go b/Godeps/_workspace/src/github.com/howeyc/fsnotify/fsnotify_bsd.go
new file mode 100644
index 000000000..e6ffd7e5b
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/howeyc/fsnotify/fsnotify_bsd.go
@@ -0,0 +1,496 @@
+// Copyright 2010 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// +build freebsd openbsd netbsd darwin
+
+package fsnotify
+
+import (
+ "errors"
+ "fmt"
+ "io/ioutil"
+ "os"
+ "path/filepath"
+ "sync"
+ "syscall"
+)
+
+const (
+ // Flags (from <sys/event.h>)
+ sys_NOTE_DELETE = 0x0001 /* vnode was removed */
+ sys_NOTE_WRITE = 0x0002 /* data contents changed */
+ sys_NOTE_EXTEND = 0x0004 /* size increased */
+ sys_NOTE_ATTRIB = 0x0008 /* attributes changed */
+ sys_NOTE_LINK = 0x0010 /* link count changed */
+ sys_NOTE_RENAME = 0x0020 /* vnode was renamed */
+ sys_NOTE_REVOKE = 0x0040 /* vnode access was revoked */
+
+ // Watch all events
+ sys_NOTE_ALLEVENTS = sys_NOTE_DELETE | sys_NOTE_WRITE | sys_NOTE_ATTRIB | sys_NOTE_RENAME
+
+ // Block for 100 ms on each call to kevent
+ keventWaitTime = 100e6
+)
+
+type FileEvent struct {
+ mask uint32 // Mask of events
+ Name string // File name (optional)
+ create bool // set by fsnotify package if found new file
+}
+
+// IsCreate reports whether the FileEvent was triggered by a creation
+func (e *FileEvent) IsCreate() bool { return e.create }
+
+// IsDelete reports whether the FileEvent was triggered by a delete
+func (e *FileEvent) IsDelete() bool { return (e.mask & sys_NOTE_DELETE) == sys_NOTE_DELETE }
+
+// IsModify reports whether the FileEvent was triggered by a file modification
+func (e *FileEvent) IsModify() bool {
+ return ((e.mask&sys_NOTE_WRITE) == sys_NOTE_WRITE || (e.mask&sys_NOTE_ATTRIB) == sys_NOTE_ATTRIB)
+}
+
+// IsRename reports whether the FileEvent was triggered by a change name
+func (e *FileEvent) IsRename() bool { return (e.mask & sys_NOTE_RENAME) == sys_NOTE_RENAME }
+
+// IsAttrib reports whether the FileEvent was triggered by a change in the file metadata.
+func (e *FileEvent) IsAttrib() bool {
+ return (e.mask & sys_NOTE_ATTRIB) == sys_NOTE_ATTRIB
+}
+
+type Watcher struct {
+ mu sync.Mutex // Mutex for the Watcher itself.
+ kq int // File descriptor (as returned by the kqueue() syscall)
+ watches map[string]int // Map of watched file descriptors (key: path)
+ wmut sync.Mutex // Protects access to watches.
+ fsnFlags map[string]uint32 // Map of watched files to flags used for filter
+ fsnmut sync.Mutex // Protects access to fsnFlags.
+ enFlags map[string]uint32 // Map of watched files to evfilt note flags used in kqueue
+ enmut sync.Mutex // Protects access to enFlags.
+ paths map[int]string // Map of watched paths (key: watch descriptor)
+ finfo map[int]os.FileInfo // Map of file information (isDir, isReg; key: watch descriptor)
+ pmut sync.Mutex // Protects access to paths and finfo.
+ fileExists map[string]bool // Keep track of if we know this file exists (to stop duplicate create events)
+ femut sync.Mutex // Protects access to fileExists.
+ externalWatches map[string]bool // Map of watches added by user of the library.
+ ewmut sync.Mutex // Protects access to externalWatches.
+ Error chan error // Errors are sent on this channel
+ internalEvent chan *FileEvent // Events are queued on this channel
+ Event chan *FileEvent // Events are returned on this channel
+ done chan bool // Channel for sending a "quit message" to the reader goroutine
+ isClosed bool // Set to true when Close() is first called
+}
+
+// NewWatcher creates and returns a new kevent instance using kqueue(2)
+func NewWatcher() (*Watcher, error) {
+ fd, errno := syscall.Kqueue()
+ if fd == -1 {
+ return nil, os.NewSyscallError("kqueue", errno)
+ }
+ w := &Watcher{
+ kq: fd,
+ watches: make(map[string]int),
+ fsnFlags: make(map[string]uint32),
+ enFlags: make(map[string]uint32),
+ paths: make(map[int]string),
+ finfo: make(map[int]os.FileInfo),
+ fileExists: make(map[string]bool),
+ externalWatches: make(map[string]bool),
+ internalEvent: make(chan *FileEvent),
+ Event: make(chan *FileEvent),
+ Error: make(chan error),
+ done: make(chan bool, 1),
+ }
+
+ go w.readEvents()
+ go w.purgeEvents()
+ return w, nil
+}
+
+// Close closes a kevent watcher instance
+// It sends a message to the reader goroutine to quit and removes all watches
+// associated with the kevent instance
+func (w *Watcher) Close() error {
+ w.mu.Lock()
+ if w.isClosed {
+ w.mu.Unlock()
+ return nil
+ }
+ w.isClosed = true
+ w.mu.Unlock()
+
+ // Send "quit" message to the reader goroutine
+ w.done <- true
+ w.wmut.Lock()
+ ws := w.watches
+ w.wmut.Unlock()
+ for path := range ws {
+ w.removeWatch(path)
+ }
+
+ return nil
+}
+
+// AddWatch adds path to the watched file set.
+// The flags are interpreted as described in kevent(2).
+func (w *Watcher) addWatch(path string, flags uint32) error {
+ w.mu.Lock()
+ if w.isClosed {
+ w.mu.Unlock()
+ return errors.New("kevent instance already closed")
+ }
+ w.mu.Unlock()
+
+ watchDir := false
+
+ w.wmut.Lock()
+ watchfd, found := w.watches[path]
+ w.wmut.Unlock()
+ if !found {
+ fi, errstat := os.Lstat(path)
+ if errstat != nil {
+ return errstat
+ }
+
+ // don't watch socket
+ if fi.Mode()&os.ModeSocket == os.ModeSocket {
+ return nil
+ }
+
+ // Follow Symlinks
+ // Unfortunately, Linux can add bogus symlinks to watch list without
+ // issue, and Windows can't do symlinks period (AFAIK). To maintain
+ // consistency, we will act like everything is fine. There will simply
+ // be no file events for broken symlinks.
+ // Hence the returns of nil on errors.
+ if fi.Mode()&os.ModeSymlink == os.ModeSymlink {
+ path, err := filepath.EvalSymlinks(path)
+ if err != nil {
+ return nil
+ }
+
+ fi, errstat = os.Lstat(path)
+ if errstat != nil {
+ return nil
+ }
+ }
+
+ fd, errno := syscall.Open(path, open_FLAGS, 0700)
+ if fd == -1 {
+ return errno
+ }
+ watchfd = fd
+
+ w.wmut.Lock()
+ w.watches[path] = watchfd
+ w.wmut.Unlock()
+
+ w.pmut.Lock()
+ w.paths[watchfd] = path
+ w.finfo[watchfd] = fi
+ w.pmut.Unlock()
+ }
+ // Watch the directory if it has not been watched before.
+ w.pmut.Lock()
+ w.enmut.Lock()
+ if w.finfo[watchfd].IsDir() &&
+ (flags&sys_NOTE_WRITE) == sys_NOTE_WRITE &&
+ (!found || (w.enFlags[path]&sys_NOTE_WRITE) != sys_NOTE_WRITE) {
+ watchDir = true
+ }
+ w.enmut.Unlock()
+ w.pmut.Unlock()
+
+ w.enmut.Lock()
+ w.enFlags[path] = flags
+ w.enmut.Unlock()
+
+ var kbuf [1]syscall.Kevent_t
+ watchEntry := &kbuf[0]
+ watchEntry.Fflags = flags
+ syscall.SetKevent(watchEntry, watchfd, syscall.EVFILT_VNODE, syscall.EV_ADD|syscall.EV_CLEAR)
+ entryFlags := watchEntry.Flags
+ success, errno := syscall.Kevent(w.kq, kbuf[:], nil, nil)
+ if success == -1 {
+ return errno
+ } else if (entryFlags & syscall.EV_ERROR) == syscall.EV_ERROR {
+ return errors.New("kevent add error")
+ }
+
+ if watchDir {
+ errdir := w.watchDirectoryFiles(path)
+ if errdir != nil {
+ return errdir
+ }
+ }
+ return nil
+}
+
+// Watch adds path to the watched file set, watching all events.
+func (w *Watcher) watch(path string) error {
+ w.ewmut.Lock()
+ w.externalWatches[path] = true
+ w.ewmut.Unlock()
+ return w.addWatch(path, sys_NOTE_ALLEVENTS)
+}
+
+// RemoveWatch removes path from the watched file set.
+func (w *Watcher) removeWatch(path string) error {
+ w.wmut.Lock()
+ watchfd, ok := w.watches[path]
+ w.wmut.Unlock()
+ if !ok {
+ return errors.New(fmt.Sprintf("can't remove non-existent kevent watch for: %s", path))
+ }
+ var kbuf [1]syscall.Kevent_t
+ watchEntry := &kbuf[0]
+ syscall.SetKevent(watchEntry, watchfd, syscall.EVFILT_VNODE, syscall.EV_DELETE)
+ entryFlags := watchEntry.Flags
+ success, errno := syscall.Kevent(w.kq, kbuf[:], nil, nil)
+ if success == -1 {
+ return os.NewSyscallError("kevent_rm_watch", errno)
+ } else if (entryFlags & syscall.EV_ERROR) == syscall.EV_ERROR {
+ return errors.New("kevent rm error")
+ }
+ syscall.Close(watchfd)
+ w.wmut.Lock()
+ delete(w.watches, path)
+ w.wmut.Unlock()
+ w.enmut.Lock()
+ delete(w.enFlags, path)
+ w.enmut.Unlock()
+ w.pmut.Lock()
+ delete(w.paths, watchfd)
+ fInfo := w.finfo[watchfd]
+ delete(w.finfo, watchfd)
+ w.pmut.Unlock()
+
+ // Find all watched paths that are in this directory that are not external.
+ if fInfo.IsDir() {
+ var pathsToRemove []string
+ w.pmut.Lock()
+ for _, wpath := range w.paths {
+ wdir, _ := filepath.Split(wpath)
+ if filepath.Clean(wdir) == filepath.Clean(path) {
+ w.ewmut.Lock()
+ if !w.externalWatches[wpath] {
+ pathsToRemove = append(pathsToRemove, wpath)
+ }
+ w.ewmut.Unlock()
+ }
+ }
+ w.pmut.Unlock()
+ for _, p := range pathsToRemove {
+ // Since these are internal, not much sense in propagating error
+ // to the user, as that will just confuse them with an error about
+ // a path they did not explicitly watch themselves.
+ w.removeWatch(p)
+ }
+ }
+
+ return nil
+}
+
+// readEvents reads from the kqueue file descriptor, converts the
+// received events into Event objects and sends them via the Event channel
+func (w *Watcher) readEvents() {
+ var (
+ eventbuf [10]syscall.Kevent_t // Event buffer
+ events []syscall.Kevent_t // Received events
+ twait *syscall.Timespec // Time to block waiting for events
+ n int // Number of events returned from kevent
+ errno error // Syscall errno
+ )
+ events = eventbuf[0:0]
+ twait = new(syscall.Timespec)
+ *twait = syscall.NsecToTimespec(keventWaitTime)
+
+ for {
+ // See if there is a message on the "done" channel
+ var done bool
+ select {
+ case done = <-w.done:
+ default:
+ }
+
+ // If "done" message is received
+ if done {
+ errno := syscall.Close(w.kq)
+ if errno != nil {
+ w.Error <- os.NewSyscallError("close", errno)
+ }
+ close(w.internalEvent)
+ close(w.Error)
+ return
+ }
+
+ // Get new events
+ if len(events) == 0 {
+ n, errno = syscall.Kevent(w.kq, nil, eventbuf[:], twait)
+
+ // EINTR is okay, basically the syscall was interrupted before
+ // timeout expired.
+ if errno != nil && errno != syscall.EINTR {
+ w.Error <- os.NewSyscallError("kevent", errno)
+ continue
+ }
+
+ // Received some events
+ if n > 0 {
+ events = eventbuf[0:n]
+ }
+ }
+
+ // Flush the events we received to the events channel
+ for len(events) > 0 {
+ fileEvent := new(FileEvent)
+ watchEvent := &events[0]
+ fileEvent.mask = uint32(watchEvent.Fflags)
+ w.pmut.Lock()
+ fileEvent.Name = w.paths[int(watchEvent.Ident)]
+ fileInfo := w.finfo[int(watchEvent.Ident)]
+ w.pmut.Unlock()
+ if fileInfo != nil && fileInfo.IsDir() && !fileEvent.IsDelete() {
+ // Double check to make sure the directory exist. This can happen when
+ // we do a rm -fr on a recursively watched folders and we receive a
+ // modification event first but the folder has been deleted and later
+ // receive the delete event
+ if _, err := os.Lstat(fileEvent.Name); os.IsNotExist(err) {
+ // mark is as delete event
+ fileEvent.mask |= sys_NOTE_DELETE
+ }
+ }
+
+ if fileInfo != nil && fileInfo.IsDir() && fileEvent.IsModify() && !fileEvent.IsDelete() {
+ w.sendDirectoryChangeEvents(fileEvent.Name)
+ } else {
+ // Send the event on the events channel
+ w.internalEvent <- fileEvent
+ }
+
+ // Move to next event
+ events = events[1:]
+
+ if fileEvent.IsRename() {
+ w.removeWatch(fileEvent.Name)
+ w.femut.Lock()
+ delete(w.fileExists, fileEvent.Name)
+ w.femut.Unlock()
+ }
+ if fileEvent.IsDelete() {
+ w.removeWatch(fileEvent.Name)
+ w.femut.Lock()
+ delete(w.fileExists, fileEvent.Name)
+ w.femut.Unlock()
+
+ // Look for a file that may have overwritten this
+ // (ie mv f1 f2 will delete f2 then create f2)
+ fileDir, _ := filepath.Split(fileEvent.Name)
+ fileDir = filepath.Clean(fileDir)
+ w.wmut.Lock()
+ _, found := w.watches[fileDir]
+ w.wmut.Unlock()
+ if found {
+ // make sure the directory exist before we watch for changes. When we
+ // do a recursive watch and perform rm -fr, the parent directory might
+ // have gone missing, ignore the missing directory and let the
+ // upcoming delete event remove the watch form the parent folder
+ if _, err := os.Lstat(fileDir); !os.IsNotExist(err) {
+ w.sendDirectoryChangeEvents(fileDir)
+ }
+ }
+ }
+ }
+ }
+}
+
+func (w *Watcher) watchDirectoryFiles(dirPath string) error {
+ // Get all files
+ files, err := ioutil.ReadDir(dirPath)
+ if err != nil {
+ return err
+ }
+
+ // Search for new files
+ for _, fileInfo := range files {
+ filePath := filepath.Join(dirPath, fileInfo.Name())
+
+ // Inherit fsnFlags from parent directory
+ w.fsnmut.Lock()
+ if flags, found := w.fsnFlags[dirPath]; found {
+ w.fsnFlags[filePath] = flags
+ } else {
+ w.fsnFlags[filePath] = FSN_ALL
+ }
+ w.fsnmut.Unlock()
+
+ if fileInfo.IsDir() == false {
+ // Watch file to mimic linux fsnotify
+ e := w.addWatch(filePath, sys_NOTE_ALLEVENTS)
+ if e != nil {
+ return e
+ }
+ } else {
+ // If the user is currently watching directory
+ // we want to preserve the flags used
+ w.enmut.Lock()
+ currFlags, found := w.enFlags[filePath]
+ w.enmut.Unlock()
+ var newFlags uint32 = sys_NOTE_DELETE
+ if found {
+ newFlags |= currFlags
+ }
+
+ // Linux gives deletes if not explicitly watching
+ e := w.addWatch(filePath, newFlags)
+ if e != nil {
+ return e
+ }
+ }
+ w.femut.Lock()
+ w.fileExists[filePath] = true
+ w.femut.Unlock()
+ }
+
+ return nil
+}
+
+// sendDirectoryEvents searches the directory for newly created files
+// and sends them over the event channel. This functionality is to have
+// the BSD version of fsnotify match linux fsnotify which provides a
+// create event for files created in a watched directory.
+func (w *Watcher) sendDirectoryChangeEvents(dirPath string) {
+ // Get all files
+ files, err := ioutil.ReadDir(dirPath)
+ if err != nil {
+ w.Error <- err
+ }
+
+ // Search for new files
+ for _, fileInfo := range files {
+ filePath := filepath.Join(dirPath, fileInfo.Name())
+ w.femut.Lock()
+ _, doesExist := w.fileExists[filePath]
+ w.femut.Unlock()
+ if !doesExist {
+ // Inherit fsnFlags from parent directory
+ w.fsnmut.Lock()
+ if flags, found := w.fsnFlags[dirPath]; found {
+ w.fsnFlags[filePath] = flags
+ } else {
+ w.fsnFlags[filePath] = FSN_ALL
+ }
+ w.fsnmut.Unlock()
+
+ // Send create event
+ fileEvent := new(FileEvent)
+ fileEvent.Name = filePath
+ fileEvent.create = true
+ w.internalEvent <- fileEvent
+ }
+ w.femut.Lock()
+ w.fileExists[filePath] = true
+ w.femut.Unlock()
+ }
+ w.watchDirectoryFiles(dirPath)
+}
diff --git a/Godeps/_workspace/src/github.com/howeyc/fsnotify/fsnotify_linux.go b/Godeps/_workspace/src/github.com/howeyc/fsnotify/fsnotify_linux.go
new file mode 100644
index 000000000..80ade879f
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/howeyc/fsnotify/fsnotify_linux.go
@@ -0,0 +1,304 @@
+// Copyright 2010 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// +build linux
+
+package fsnotify
+
+import (
+ "errors"
+ "fmt"
+ "os"
+ "strings"
+ "sync"
+ "syscall"
+ "unsafe"
+)
+
+const (
+ // Options for inotify_init() are not exported
+ // sys_IN_CLOEXEC uint32 = syscall.IN_CLOEXEC
+ // sys_IN_NONBLOCK uint32 = syscall.IN_NONBLOCK
+
+ // Options for AddWatch
+ sys_IN_DONT_FOLLOW uint32 = syscall.IN_DONT_FOLLOW
+ sys_IN_ONESHOT uint32 = syscall.IN_ONESHOT
+ sys_IN_ONLYDIR uint32 = syscall.IN_ONLYDIR
+
+ // The "sys_IN_MASK_ADD" option is not exported, as AddWatch
+ // adds it automatically, if there is already a watch for the given path
+ // sys_IN_MASK_ADD uint32 = syscall.IN_MASK_ADD
+
+ // Events
+ sys_IN_ACCESS uint32 = syscall.IN_ACCESS
+ sys_IN_ALL_EVENTS uint32 = syscall.IN_ALL_EVENTS
+ sys_IN_ATTRIB uint32 = syscall.IN_ATTRIB
+ sys_IN_CLOSE uint32 = syscall.IN_CLOSE
+ sys_IN_CLOSE_NOWRITE uint32 = syscall.IN_CLOSE_NOWRITE
+ sys_IN_CLOSE_WRITE uint32 = syscall.IN_CLOSE_WRITE
+ sys_IN_CREATE uint32 = syscall.IN_CREATE
+ sys_IN_DELETE uint32 = syscall.IN_DELETE
+ sys_IN_DELETE_SELF uint32 = syscall.IN_DELETE_SELF
+ sys_IN_MODIFY uint32 = syscall.IN_MODIFY
+ sys_IN_MOVE uint32 = syscall.IN_MOVE
+ sys_IN_MOVED_FROM uint32 = syscall.IN_MOVED_FROM
+ sys_IN_MOVED_TO uint32 = syscall.IN_MOVED_TO
+ sys_IN_MOVE_SELF uint32 = syscall.IN_MOVE_SELF
+ sys_IN_OPEN uint32 = syscall.IN_OPEN
+
+ sys_AGNOSTIC_EVENTS = sys_IN_MOVED_TO | sys_IN_MOVED_FROM | sys_IN_CREATE | sys_IN_ATTRIB | sys_IN_MODIFY | sys_IN_MOVE_SELF | sys_IN_DELETE | sys_IN_DELETE_SELF
+
+ // Special events
+ sys_IN_ISDIR uint32 = syscall.IN_ISDIR
+ sys_IN_IGNORED uint32 = syscall.IN_IGNORED
+ sys_IN_Q_OVERFLOW uint32 = syscall.IN_Q_OVERFLOW
+ sys_IN_UNMOUNT uint32 = syscall.IN_UNMOUNT
+)
+
+type FileEvent struct {
+ mask uint32 // Mask of events
+ cookie uint32 // Unique cookie associating related events (for rename(2))
+ Name string // File name (optional)
+}
+
+// IsCreate reports whether the FileEvent was triggered by a creation
+func (e *FileEvent) IsCreate() bool {
+ return (e.mask&sys_IN_CREATE) == sys_IN_CREATE || (e.mask&sys_IN_MOVED_TO) == sys_IN_MOVED_TO
+}
+
+// IsDelete reports whether the FileEvent was triggered by a delete
+func (e *FileEvent) IsDelete() bool {
+ return (e.mask&sys_IN_DELETE_SELF) == sys_IN_DELETE_SELF || (e.mask&sys_IN_DELETE) == sys_IN_DELETE
+}
+
+// IsModify reports whether the FileEvent was triggered by a file modification or attribute change
+func (e *FileEvent) IsModify() bool {
+ return ((e.mask&sys_IN_MODIFY) == sys_IN_MODIFY || (e.mask&sys_IN_ATTRIB) == sys_IN_ATTRIB)
+}
+
+// IsRename reports whether the FileEvent was triggered by a change name
+func (e *FileEvent) IsRename() bool {
+ return ((e.mask&sys_IN_MOVE_SELF) == sys_IN_MOVE_SELF || (e.mask&sys_IN_MOVED_FROM) == sys_IN_MOVED_FROM)
+}
+
+// IsAttrib reports whether the FileEvent was triggered by a change in the file metadata.
+func (e *FileEvent) IsAttrib() bool {
+ return (e.mask & sys_IN_ATTRIB) == sys_IN_ATTRIB
+}
+
+type watch struct {
+ wd uint32 // Watch descriptor (as returned by the inotify_add_watch() syscall)
+ flags uint32 // inotify flags of this watch (see inotify(7) for the list of valid flags)
+}
+
+type Watcher struct {
+ mu sync.Mutex // Map access
+ fd int // File descriptor (as returned by the inotify_init() syscall)
+ watches map[string]*watch // Map of inotify watches (key: path)
+ fsnFlags map[string]uint32 // Map of watched files to flags used for filter
+ fsnmut sync.Mutex // Protects access to fsnFlags.
+ paths map[int]string // Map of watched paths (key: watch descriptor)
+ Error chan error // Errors are sent on this channel
+ internalEvent chan *FileEvent // Events are queued on this channel
+ Event chan *FileEvent // Events are returned on this channel
+ done chan bool // Channel for sending a "quit message" to the reader goroutine
+ isClosed bool // Set to true when Close() is first called
+}
+
+// NewWatcher creates and returns a new inotify instance using inotify_init(2)
+func NewWatcher() (*Watcher, error) {
+ fd, errno := syscall.InotifyInit()
+ if fd == -1 {
+ return nil, os.NewSyscallError("inotify_init", errno)
+ }
+ w := &Watcher{
+ fd: fd,
+ watches: make(map[string]*watch),
+ fsnFlags: make(map[string]uint32),
+ paths: make(map[int]string),
+ internalEvent: make(chan *FileEvent),
+ Event: make(chan *FileEvent),
+ Error: make(chan error),
+ done: make(chan bool, 1),
+ }
+
+ go w.readEvents()
+ go w.purgeEvents()
+ return w, nil
+}
+
+// Close closes an inotify watcher instance
+// It sends a message to the reader goroutine to quit and removes all watches
+// associated with the inotify instance
+func (w *Watcher) Close() error {
+ if w.isClosed {
+ return nil
+ }
+ w.isClosed = true
+
+ // Remove all watches
+ for path := range w.watches {
+ w.RemoveWatch(path)
+ }
+
+ // Send "quit" message to the reader goroutine
+ w.done <- true
+
+ return nil
+}
+
+// AddWatch adds path to the watched file set.
+// The flags are interpreted as described in inotify_add_watch(2).
+func (w *Watcher) addWatch(path string, flags uint32) error {
+ if w.isClosed {
+ return errors.New("inotify instance already closed")
+ }
+
+ w.mu.Lock()
+ watchEntry, found := w.watches[path]
+ w.mu.Unlock()
+ if found {
+ watchEntry.flags |= flags
+ flags |= syscall.IN_MASK_ADD
+ }
+ wd, errno := syscall.InotifyAddWatch(w.fd, path, flags)
+ if wd == -1 {
+ return errno
+ }
+
+ w.mu.Lock()
+ w.watches[path] = &watch{wd: uint32(wd), flags: flags}
+ w.paths[wd] = path
+ w.mu.Unlock()
+
+ return nil
+}
+
+// Watch adds path to the watched file set, watching all events.
+func (w *Watcher) watch(path string) error {
+ return w.addWatch(path, sys_AGNOSTIC_EVENTS)
+}
+
+// RemoveWatch removes path from the watched file set.
+func (w *Watcher) removeWatch(path string) error {
+ w.mu.Lock()
+ defer w.mu.Unlock()
+ watch, ok := w.watches[path]
+ if !ok {
+ return errors.New(fmt.Sprintf("can't remove non-existent inotify watch for: %s", path))
+ }
+ success, errno := syscall.InotifyRmWatch(w.fd, watch.wd)
+ if success == -1 {
+ return os.NewSyscallError("inotify_rm_watch", errno)
+ }
+ delete(w.watches, path)
+ return nil
+}
+
+// readEvents reads from the inotify file descriptor, converts the
+// received events into Event objects and sends them via the Event channel
+func (w *Watcher) readEvents() {
+ var (
+ buf [syscall.SizeofInotifyEvent * 4096]byte // Buffer for a maximum of 4096 raw events
+ n int // Number of bytes read with read()
+ errno error // Syscall errno
+ )
+
+ for {
+ // See if there is a message on the "done" channel
+ select {
+ case <-w.done:
+ syscall.Close(w.fd)
+ close(w.internalEvent)
+ close(w.Error)
+ return
+ default:
+ }
+
+ n, errno = syscall.Read(w.fd, buf[:])
+
+ // If EOF is received
+ if n == 0 {
+ syscall.Close(w.fd)
+ close(w.internalEvent)
+ close(w.Error)
+ return
+ }
+
+ if n < 0 {
+ w.Error <- os.NewSyscallError("read", errno)
+ continue
+ }
+ if n < syscall.SizeofInotifyEvent {
+ w.Error <- errors.New("inotify: short read in readEvents()")
+ continue
+ }
+
+ var offset uint32 = 0
+ // We don't know how many events we just read into the buffer
+ // While the offset points to at least one whole event...
+ for offset <= uint32(n-syscall.SizeofInotifyEvent) {
+ // Point "raw" to the event in the buffer
+ raw := (*syscall.InotifyEvent)(unsafe.Pointer(&buf[offset]))
+ event := new(FileEvent)
+ event.mask = uint32(raw.Mask)
+ event.cookie = uint32(raw.Cookie)
+ nameLen := uint32(raw.Len)
+ // If the event happened to the watched directory or the watched file, the kernel
+ // doesn't append the filename to the event, but we would like to always fill the
+ // the "Name" field with a valid filename. We retrieve the path of the watch from
+ // the "paths" map.
+ w.mu.Lock()
+ event.Name = w.paths[int(raw.Wd)]
+ w.mu.Unlock()
+ watchedName := event.Name
+ if nameLen > 0 {
+ // Point "bytes" at the first byte of the filename
+ bytes := (*[syscall.PathMax]byte)(unsafe.Pointer(&buf[offset+syscall.SizeofInotifyEvent]))
+ // The filename is padded with NUL bytes. TrimRight() gets rid of those.
+ event.Name += "/" + strings.TrimRight(string(bytes[0:nameLen]), "\000")
+ }
+
+ // Send the events that are not ignored on the events channel
+ if !event.ignoreLinux() {
+ // Setup FSNotify flags (inherit from directory watch)
+ w.fsnmut.Lock()
+ if _, fsnFound := w.fsnFlags[event.Name]; !fsnFound {
+ if fsnFlags, watchFound := w.fsnFlags[watchedName]; watchFound {
+ w.fsnFlags[event.Name] = fsnFlags
+ } else {
+ w.fsnFlags[event.Name] = FSN_ALL
+ }
+ }
+ w.fsnmut.Unlock()
+
+ w.internalEvent <- event
+ }
+
+ // Move to the next event in the buffer
+ offset += syscall.SizeofInotifyEvent + nameLen
+ }
+ }
+}
+
+// Certain types of events can be "ignored" and not sent over the Event
+// channel. Such as events marked ignore by the kernel, or MODIFY events
+// against files that do not exist.
+func (e *FileEvent) ignoreLinux() bool {
+ // Ignore anything the inotify API says to ignore
+ if e.mask&sys_IN_IGNORED == sys_IN_IGNORED {
+ return true
+ }
+
+ // If the event is not a DELETE or RENAME, the file must exist.
+ // Otherwise the event is ignored.
+ // *Note*: this was put in place because it was seen that a MODIFY
+ // event was sent after the DELETE. This ignores that MODIFY and
+ // assumes a DELETE will come or has come if the file doesn't exist.
+ if !(e.IsDelete() || e.IsRename()) {
+ _, statErr := os.Lstat(e.Name)
+ return os.IsNotExist(statErr)
+ }
+ return false
+}
diff --git a/Godeps/_workspace/src/github.com/howeyc/fsnotify/fsnotify_open_bsd.go b/Godeps/_workspace/src/github.com/howeyc/fsnotify/fsnotify_open_bsd.go
new file mode 100644
index 000000000..37ea998d0
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/howeyc/fsnotify/fsnotify_open_bsd.go
@@ -0,0 +1,11 @@
+// Copyright 2013 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// +build freebsd openbsd netbsd
+
+package fsnotify
+
+import "syscall"
+
+const open_FLAGS = syscall.O_NONBLOCK | syscall.O_RDONLY
diff --git a/Godeps/_workspace/src/github.com/howeyc/fsnotify/fsnotify_open_darwin.go b/Godeps/_workspace/src/github.com/howeyc/fsnotify/fsnotify_open_darwin.go
new file mode 100644
index 000000000..d450318e6
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/howeyc/fsnotify/fsnotify_open_darwin.go
@@ -0,0 +1,11 @@
+// Copyright 2013 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// +build darwin
+
+package fsnotify
+
+import "syscall"
+
+const open_FLAGS = syscall.O_EVTONLY
diff --git a/Godeps/_workspace/src/github.com/howeyc/fsnotify/fsnotify_symlink_test.go b/Godeps/_workspace/src/github.com/howeyc/fsnotify/fsnotify_symlink_test.go
new file mode 100644
index 000000000..39061f844
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/howeyc/fsnotify/fsnotify_symlink_test.go
@@ -0,0 +1,74 @@
+// Copyright 2010 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// +build freebsd openbsd netbsd darwin linux
+
+package fsnotify
+
+import (
+ "os"
+ "path/filepath"
+ "testing"
+ "time"
+)
+
+func TestFsnotifyFakeSymlink(t *testing.T) {
+ watcher := newWatcher(t)
+
+ // Create directory to watch
+ testDir := tempMkdir(t)
+ defer os.RemoveAll(testDir)
+
+ var errorsReceived counter
+ // Receive errors on the error channel on a separate goroutine
+ go func() {
+ for errors := range watcher.Error {
+ t.Logf("Received error: %s", errors)
+ errorsReceived.increment()
+ }
+ }()
+
+ // Count the CREATE events received
+ var createEventsReceived, otherEventsReceived counter
+ go func() {
+ for ev := range watcher.Event {
+ t.Logf("event received: %s", ev)
+ if ev.IsCreate() {
+ createEventsReceived.increment()
+ } else {
+ otherEventsReceived.increment()
+ }
+ }
+ }()
+
+ addWatch(t, watcher, testDir)
+
+ if err := os.Symlink(filepath.Join(testDir, "zzz"), filepath.Join(testDir, "zzznew")); err != nil {
+ t.Fatalf("Failed to create bogus symlink: %s", err)
+ }
+ t.Logf("Created bogus symlink")
+
+ // We expect this event to be received almost immediately, but let's wait 500 ms to be sure
+ time.Sleep(500 * time.Millisecond)
+
+ // Should not be error, just no events for broken links (watching nothing)
+ if errorsReceived.value() > 0 {
+ t.Fatal("fsnotify errors have been received.")
+ }
+ if otherEventsReceived.value() > 0 {
+ t.Fatal("fsnotify other events received on the broken link")
+ }
+
+ // Except for 1 create event (for the link itself)
+ if createEventsReceived.value() == 0 {
+ t.Fatal("fsnotify create events were not received after 500 ms")
+ }
+ if createEventsReceived.value() > 1 {
+ t.Fatal("fsnotify more create events received than expected")
+ }
+
+ // Try closing the fsnotify instance
+ t.Log("calling Close()")
+ watcher.Close()
+}
diff --git a/Godeps/_workspace/src/github.com/howeyc/fsnotify/fsnotify_test.go b/Godeps/_workspace/src/github.com/howeyc/fsnotify/fsnotify_test.go
new file mode 100644
index 000000000..3f5a6487f
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/howeyc/fsnotify/fsnotify_test.go
@@ -0,0 +1,1010 @@
+// Copyright 2010 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+package fsnotify
+
+import (
+ "io/ioutil"
+ "os"
+ "os/exec"
+ "path/filepath"
+ "runtime"
+ "sync/atomic"
+ "testing"
+ "time"
+)
+
+// An atomic counter
+type counter struct {
+ val int32
+}
+
+func (c *counter) increment() {
+ atomic.AddInt32(&c.val, 1)
+}
+
+func (c *counter) value() int32 {
+ return atomic.LoadInt32(&c.val)
+}
+
+func (c *counter) reset() {
+ atomic.StoreInt32(&c.val, 0)
+}
+
+// tempMkdir makes a temporary directory
+func tempMkdir(t *testing.T) string {
+ dir, err := ioutil.TempDir("", "fsnotify")
+ if err != nil {
+ t.Fatalf("failed to create test directory: %s", err)
+ }
+ return dir
+}
+
+// newWatcher initializes an fsnotify Watcher instance.
+func newWatcher(t *testing.T) *Watcher {
+ watcher, err := NewWatcher()
+ if err != nil {
+ t.Fatalf("NewWatcher() failed: %s", err)
+ }
+ return watcher
+}
+
+// addWatch adds a watch for a directory
+func addWatch(t *testing.T, watcher *Watcher, dir string) {
+ if err := watcher.Watch(dir); err != nil {
+ t.Fatalf("watcher.Watch(%q) failed: %s", dir, err)
+ }
+}
+
+func TestFsnotifyMultipleOperations(t *testing.T) {
+ watcher := newWatcher(t)
+
+ // Receive errors on the error channel on a separate goroutine
+ go func() {
+ for err := range watcher.Error {
+ t.Fatalf("error received: %s", err)
+ }
+ }()
+
+ // Create directory to watch
+ testDir := tempMkdir(t)
+ defer os.RemoveAll(testDir)
+
+ // Create directory that's not watched
+ testDirToMoveFiles := tempMkdir(t)
+ defer os.RemoveAll(testDirToMoveFiles)
+
+ testFile := filepath.Join(testDir, "TestFsnotifySeq.testfile")
+ testFileRenamed := filepath.Join(testDirToMoveFiles, "TestFsnotifySeqRename.testfile")
+
+ addWatch(t, watcher, testDir)
+
+ // Receive events on the event channel on a separate goroutine
+ eventstream := watcher.Event
+ var createReceived, modifyReceived, deleteReceived, renameReceived counter
+ done := make(chan bool)
+ go func() {
+ for event := range eventstream {
+ // Only count relevant events
+ if event.Name == filepath.Clean(testDir) || event.Name == filepath.Clean(testFile) {
+ t.Logf("event received: %s", event)
+ if event.IsDelete() {
+ deleteReceived.increment()
+ }
+ if event.IsModify() {
+ modifyReceived.increment()
+ }
+ if event.IsCreate() {
+ createReceived.increment()
+ }
+ if event.IsRename() {
+ renameReceived.increment()
+ }
+ } else {
+ t.Logf("unexpected event received: %s", event)
+ }
+ }
+ done <- true
+ }()
+
+ // Create a file
+ // This should add at least one event to the fsnotify event queue
+ var f *os.File
+ f, err := os.OpenFile(testFile, os.O_WRONLY|os.O_CREATE, 0666)
+ if err != nil {
+ t.Fatalf("creating test file failed: %s", err)
+ }
+ f.Sync()
+
+ time.Sleep(time.Millisecond)
+ f.WriteString("data")
+ f.Sync()
+ f.Close()
+
+ time.Sleep(50 * time.Millisecond) // give system time to sync write change before delete
+
+ if err := testRename(testFile, testFileRenamed); err != nil {
+ t.Fatalf("rename failed: %s", err)
+ }
+
+ // Modify the file outside of the watched dir
+ f, err = os.Open(testFileRenamed)
+ if err != nil {
+ t.Fatalf("open test renamed file failed: %s", err)
+ }
+ f.WriteString("data")
+ f.Sync()
+ f.Close()
+
+ time.Sleep(50 * time.Millisecond) // give system time to sync write change before delete
+
+ // Recreate the file that was moved
+ f, err = os.OpenFile(testFile, os.O_WRONLY|os.O_CREATE, 0666)
+ if err != nil {
+ t.Fatalf("creating test file failed: %s", err)
+ }
+ f.Close()
+ time.Sleep(50 * time.Millisecond) // give system time to sync write change before delete
+
+ // We expect this event to be received almost immediately, but let's wait 500 ms to be sure
+ time.Sleep(500 * time.Millisecond)
+ cReceived := createReceived.value()
+ if cReceived != 2 {
+ t.Fatalf("incorrect number of create events received after 500 ms (%d vs %d)", cReceived, 2)
+ }
+ mReceived := modifyReceived.value()
+ if mReceived != 1 {
+ t.Fatalf("incorrect number of modify events received after 500 ms (%d vs %d)", mReceived, 1)
+ }
+ dReceived := deleteReceived.value()
+ rReceived := renameReceived.value()
+ if dReceived+rReceived != 1 {
+ t.Fatalf("incorrect number of rename+delete events received after 500 ms (%d vs %d)", rReceived+dReceived, 1)
+ }
+
+ // Try closing the fsnotify instance
+ t.Log("calling Close()")
+ watcher.Close()
+ t.Log("waiting for the event channel to become closed...")
+ select {
+ case <-done:
+ t.Log("event channel closed")
+ case <-time.After(2 * time.Second):
+ t.Fatal("event stream was not closed after 2 seconds")
+ }
+}
+
+func TestFsnotifyMultipleCreates(t *testing.T) {
+ watcher := newWatcher(t)
+
+ // Receive errors on the error channel on a separate goroutine
+ go func() {
+ for err := range watcher.Error {
+ t.Fatalf("error received: %s", err)
+ }
+ }()
+
+ // Create directory to watch
+ testDir := tempMkdir(t)
+ defer os.RemoveAll(testDir)
+
+ testFile := filepath.Join(testDir, "TestFsnotifySeq.testfile")
+
+ addWatch(t, watcher, testDir)
+
+ // Receive events on the event channel on a separate goroutine
+ eventstream := watcher.Event
+ var createReceived, modifyReceived, deleteReceived counter
+ done := make(chan bool)
+ go func() {
+ for event := range eventstream {
+ // Only count relevant events
+ if event.Name == filepath.Clean(testDir) || event.Name == filepath.Clean(testFile) {
+ t.Logf("event received: %s", event)
+ if event.IsDelete() {
+ deleteReceived.increment()
+ }
+ if event.IsCreate() {
+ createReceived.increment()
+ }
+ if event.IsModify() {
+ modifyReceived.increment()
+ }
+ } else {
+ t.Logf("unexpected event received: %s", event)
+ }
+ }
+ done <- true
+ }()
+
+ // Create a file
+ // This should add at least one event to the fsnotify event queue
+ var f *os.File
+ f, err := os.OpenFile(testFile, os.O_WRONLY|os.O_CREATE, 0666)
+ if err != nil {
+ t.Fatalf("creating test file failed: %s", err)
+ }
+ f.Sync()
+
+ time.Sleep(time.Millisecond)
+ f.WriteString("data")
+ f.Sync()
+ f.Close()
+
+ time.Sleep(50 * time.Millisecond) // give system time to sync write change before delete
+
+ os.Remove(testFile)
+
+ time.Sleep(50 * time.Millisecond) // give system time to sync write change before delete
+
+ // Recreate the file
+ f, err = os.OpenFile(testFile, os.O_WRONLY|os.O_CREATE, 0666)
+ if err != nil {
+ t.Fatalf("creating test file failed: %s", err)
+ }
+ f.Close()
+ time.Sleep(50 * time.Millisecond) // give system time to sync write change before delete
+
+ // Modify
+ f, err = os.OpenFile(testFile, os.O_WRONLY, 0666)
+ if err != nil {
+ t.Fatalf("creating test file failed: %s", err)
+ }
+ f.Sync()
+
+ time.Sleep(time.Millisecond)
+ f.WriteString("data")
+ f.Sync()
+ f.Close()
+
+ time.Sleep(50 * time.Millisecond) // give system time to sync write change before delete
+
+ // Modify
+ f, err = os.OpenFile(testFile, os.O_WRONLY, 0666)
+ if err != nil {
+ t.Fatalf("creating test file failed: %s", err)
+ }
+ f.Sync()
+
+ time.Sleep(time.Millisecond)
+ f.WriteString("data")
+ f.Sync()
+ f.Close()
+
+ time.Sleep(50 * time.Millisecond) // give system time to sync write change before delete
+
+ // We expect this event to be received almost immediately, but let's wait 500 ms to be sure
+ time.Sleep(500 * time.Millisecond)
+ cReceived := createReceived.value()
+ if cReceived != 2 {
+ t.Fatalf("incorrect number of create events received after 500 ms (%d vs %d)", cReceived, 2)
+ }
+ mReceived := modifyReceived.value()
+ if mReceived < 3 {
+ t.Fatalf("incorrect number of modify events received after 500 ms (%d vs atleast %d)", mReceived, 3)
+ }
+ dReceived := deleteReceived.value()
+ if dReceived != 1 {
+ t.Fatalf("incorrect number of rename+delete events received after 500 ms (%d vs %d)", dReceived, 1)
+ }
+
+ // Try closing the fsnotify instance
+ t.Log("calling Close()")
+ watcher.Close()
+ t.Log("waiting for the event channel to become closed...")
+ select {
+ case <-done:
+ t.Log("event channel closed")
+ case <-time.After(2 * time.Second):
+ t.Fatal("event stream was not closed after 2 seconds")
+ }
+}
+
+func TestFsnotifyDirOnly(t *testing.T) {
+ watcher := newWatcher(t)
+
+ // Create directory to watch
+ testDir := tempMkdir(t)
+ defer os.RemoveAll(testDir)
+
+ // Create a file before watching directory
+ // This should NOT add any events to the fsnotify event queue
+ testFileAlreadyExists := filepath.Join(testDir, "TestFsnotifyEventsExisting.testfile")
+ {
+ var f *os.File
+ f, err := os.OpenFile(testFileAlreadyExists, os.O_WRONLY|os.O_CREATE, 0666)
+ if err != nil {
+ t.Fatalf("creating test file failed: %s", err)
+ }
+ f.Sync()
+ f.Close()
+ }
+
+ addWatch(t, watcher, testDir)
+
+ // Receive errors on the error channel on a separate goroutine
+ go func() {
+ for err := range watcher.Error {
+ t.Fatalf("error received: %s", err)
+ }
+ }()
+
+ testFile := filepath.Join(testDir, "TestFsnotifyDirOnly.testfile")
+
+ // Receive events on the event channel on a separate goroutine
+ eventstream := watcher.Event
+ var createReceived, modifyReceived, deleteReceived counter
+ done := make(chan bool)
+ go func() {
+ for event := range eventstream {
+ // Only count relevant events
+ if event.Name == filepath.Clean(testDir) || event.Name == filepath.Clean(testFile) || event.Name == filepath.Clean(testFileAlreadyExists) {
+ t.Logf("event received: %s", event)
+ if event.IsDelete() {
+ deleteReceived.increment()
+ }
+ if event.IsModify() {
+ modifyReceived.increment()
+ }
+ if event.IsCreate() {
+ createReceived.increment()
+ }
+ } else {
+ t.Logf("unexpected event received: %s", event)
+ }
+ }
+ done <- true
+ }()
+
+ // Create a file
+ // This should add at least one event to the fsnotify event queue
+ var f *os.File
+ f, err := os.OpenFile(testFile, os.O_WRONLY|os.O_CREATE, 0666)
+ if err != nil {
+ t.Fatalf("creating test file failed: %s", err)
+ }
+ f.Sync()
+
+ time.Sleep(time.Millisecond)
+ f.WriteString("data")
+ f.Sync()
+ f.Close()
+
+ time.Sleep(50 * time.Millisecond) // give system time to sync write change before delete
+
+ os.Remove(testFile)
+ os.Remove(testFileAlreadyExists)
+
+ // We expect this event to be received almost immediately, but let's wait 500 ms to be sure
+ time.Sleep(500 * time.Millisecond)
+ cReceived := createReceived.value()
+ if cReceived != 1 {
+ t.Fatalf("incorrect number of create events received after 500 ms (%d vs %d)", cReceived, 1)
+ }
+ mReceived := modifyReceived.value()
+ if mReceived != 1 {
+ t.Fatalf("incorrect number of modify events received after 500 ms (%d vs %d)", mReceived, 1)
+ }
+ dReceived := deleteReceived.value()
+ if dReceived != 2 {
+ t.Fatalf("incorrect number of delete events received after 500 ms (%d vs %d)", dReceived, 2)
+ }
+
+ // Try closing the fsnotify instance
+ t.Log("calling Close()")
+ watcher.Close()
+ t.Log("waiting for the event channel to become closed...")
+ select {
+ case <-done:
+ t.Log("event channel closed")
+ case <-time.After(2 * time.Second):
+ t.Fatal("event stream was not closed after 2 seconds")
+ }
+}
+
+func TestFsnotifyDeleteWatchedDir(t *testing.T) {
+ watcher := newWatcher(t)
+ defer watcher.Close()
+
+ // Create directory to watch
+ testDir := tempMkdir(t)
+ defer os.RemoveAll(testDir)
+
+ // Create a file before watching directory
+ testFileAlreadyExists := filepath.Join(testDir, "TestFsnotifyEventsExisting.testfile")
+ {
+ var f *os.File
+ f, err := os.OpenFile(testFileAlreadyExists, os.O_WRONLY|os.O_CREATE, 0666)
+ if err != nil {
+ t.Fatalf("creating test file failed: %s", err)
+ }
+ f.Sync()
+ f.Close()
+ }
+
+ addWatch(t, watcher, testDir)
+
+ // Add a watch for testFile
+ addWatch(t, watcher, testFileAlreadyExists)
+
+ // Receive errors on the error channel on a separate goroutine
+ go func() {
+ for err := range watcher.Error {
+ t.Fatalf("error received: %s", err)
+ }
+ }()
+
+ // Receive events on the event channel on a separate goroutine
+ eventstream := watcher.Event
+ var deleteReceived counter
+ go func() {
+ for event := range eventstream {
+ // Only count relevant events
+ if event.Name == filepath.Clean(testDir) || event.Name == filepath.Clean(testFileAlreadyExists) {
+ t.Logf("event received: %s", event)
+ if event.IsDelete() {
+ deleteReceived.increment()
+ }
+ } else {
+ t.Logf("unexpected event received: %s", event)
+ }
+ }
+ }()
+
+ os.RemoveAll(testDir)
+
+ // We expect this event to be received almost immediately, but let's wait 500 ms to be sure
+ time.Sleep(500 * time.Millisecond)
+ dReceived := deleteReceived.value()
+ if dReceived < 2 {
+ t.Fatalf("did not receive at least %d delete events, received %d after 500 ms", 2, dReceived)
+ }
+}
+
+func TestFsnotifySubDir(t *testing.T) {
+ watcher := newWatcher(t)
+
+ // Create directory to watch
+ testDir := tempMkdir(t)
+ defer os.RemoveAll(testDir)
+
+ testFile1 := filepath.Join(testDir, "TestFsnotifyFile1.testfile")
+ testSubDir := filepath.Join(testDir, "sub")
+ testSubDirFile := filepath.Join(testDir, "sub/TestFsnotifyFile1.testfile")
+
+ // Receive errors on the error channel on a separate goroutine
+ go func() {
+ for err := range watcher.Error {
+ t.Fatalf("error received: %s", err)
+ }
+ }()
+
+ // Receive events on the event channel on a separate goroutine
+ eventstream := watcher.Event
+ var createReceived, deleteReceived counter
+ done := make(chan bool)
+ go func() {
+ for event := range eventstream {
+ // Only count relevant events
+ if event.Name == filepath.Clean(testDir) || event.Name == filepath.Clean(testSubDir) || event.Name == filepath.Clean(testFile1) {
+ t.Logf("event received: %s", event)
+ if event.IsCreate() {
+ createReceived.increment()
+ }
+ if event.IsDelete() {
+ deleteReceived.increment()
+ }
+ } else {
+ t.Logf("unexpected event received: %s", event)
+ }
+ }
+ done <- true
+ }()
+
+ addWatch(t, watcher, testDir)
+
+ // Create sub-directory
+ if err := os.Mkdir(testSubDir, 0777); err != nil {
+ t.Fatalf("failed to create test sub-directory: %s", err)
+ }
+
+ // Create a file
+ var f *os.File
+ f, err := os.OpenFile(testFile1, os.O_WRONLY|os.O_CREATE, 0666)
+ if err != nil {
+ t.Fatalf("creating test file failed: %s", err)
+ }
+ f.Sync()
+ f.Close()
+
+ // Create a file (Should not see this! we are not watching subdir)
+ var fs *os.File
+ fs, err = os.OpenFile(testSubDirFile, os.O_WRONLY|os.O_CREATE, 0666)
+ if err != nil {
+ t.Fatalf("creating test file failed: %s", err)
+ }
+ fs.Sync()
+ fs.Close()
+
+ time.Sleep(200 * time.Millisecond)
+
+ // Make sure receive deletes for both file and sub-directory
+ os.RemoveAll(testSubDir)
+ os.Remove(testFile1)
+
+ // We expect this event to be received almost immediately, but let's wait 500 ms to be sure
+ time.Sleep(500 * time.Millisecond)
+ cReceived := createReceived.value()
+ if cReceived != 2 {
+ t.Fatalf("incorrect number of create events received after 500 ms (%d vs %d)", cReceived, 2)
+ }
+ dReceived := deleteReceived.value()
+ if dReceived != 2 {
+ t.Fatalf("incorrect number of delete events received after 500 ms (%d vs %d)", dReceived, 2)
+ }
+
+ // Try closing the fsnotify instance
+ t.Log("calling Close()")
+ watcher.Close()
+ t.Log("waiting for the event channel to become closed...")
+ select {
+ case <-done:
+ t.Log("event channel closed")
+ case <-time.After(2 * time.Second):
+ t.Fatal("event stream was not closed after 2 seconds")
+ }
+}
+
+func TestFsnotifyRename(t *testing.T) {
+ watcher := newWatcher(t)
+
+ // Create directory to watch
+ testDir := tempMkdir(t)
+ defer os.RemoveAll(testDir)
+
+ addWatch(t, watcher, testDir)
+
+ // Receive errors on the error channel on a separate goroutine
+ go func() {
+ for err := range watcher.Error {
+ t.Fatalf("error received: %s", err)
+ }
+ }()
+
+ testFile := filepath.Join(testDir, "TestFsnotifyEvents.testfile")
+ testFileRenamed := filepath.Join(testDir, "TestFsnotifyEvents.testfileRenamed")
+
+ // Receive events on the event channel on a separate goroutine
+ eventstream := watcher.Event
+ var renameReceived counter
+ done := make(chan bool)
+ go func() {
+ for event := range eventstream {
+ // Only count relevant events
+ if event.Name == filepath.Clean(testDir) || event.Name == filepath.Clean(testFile) || event.Name == filepath.Clean(testFileRenamed) {
+ if event.IsRename() {
+ renameReceived.increment()
+ }
+ t.Logf("event received: %s", event)
+ } else {
+ t.Logf("unexpected event received: %s", event)
+ }
+ }
+ done <- true
+ }()
+
+ // Create a file
+ // This should add at least one event to the fsnotify event queue
+ var f *os.File
+ f, err := os.OpenFile(testFile, os.O_WRONLY|os.O_CREATE, 0666)
+ if err != nil {
+ t.Fatalf("creating test file failed: %s", err)
+ }
+ f.Sync()
+
+ f.WriteString("data")
+ f.Sync()
+ f.Close()
+
+ // Add a watch for testFile
+ addWatch(t, watcher, testFile)
+
+ if err := testRename(testFile, testFileRenamed); err != nil {
+ t.Fatalf("rename failed: %s", err)
+ }
+
+ // We expect this event to be received almost immediately, but let's wait 500 ms to be sure
+ time.Sleep(500 * time.Millisecond)
+ if renameReceived.value() == 0 {
+ t.Fatal("fsnotify rename events have not been received after 500 ms")
+ }
+
+ // Try closing the fsnotify instance
+ t.Log("calling Close()")
+ watcher.Close()
+ t.Log("waiting for the event channel to become closed...")
+ select {
+ case <-done:
+ t.Log("event channel closed")
+ case <-time.After(2 * time.Second):
+ t.Fatal("event stream was not closed after 2 seconds")
+ }
+
+ os.Remove(testFileRenamed)
+}
+
+func TestFsnotifyRenameToCreate(t *testing.T) {
+ watcher := newWatcher(t)
+
+ // Create directory to watch
+ testDir := tempMkdir(t)
+ defer os.RemoveAll(testDir)
+
+ // Create directory to get file
+ testDirFrom := tempMkdir(t)
+ defer os.RemoveAll(testDirFrom)
+
+ addWatch(t, watcher, testDir)
+
+ // Receive errors on the error channel on a separate goroutine
+ go func() {
+ for err := range watcher.Error {
+ t.Fatalf("error received: %s", err)
+ }
+ }()
+
+ testFile := filepath.Join(testDirFrom, "TestFsnotifyEvents.testfile")
+ testFileRenamed := filepath.Join(testDir, "TestFsnotifyEvents.testfileRenamed")
+
+ // Receive events on the event channel on a separate goroutine
+ eventstream := watcher.Event
+ var createReceived counter
+ done := make(chan bool)
+ go func() {
+ for event := range eventstream {
+ // Only count relevant events
+ if event.Name == filepath.Clean(testDir) || event.Name == filepath.Clean(testFile) || event.Name == filepath.Clean(testFileRenamed) {
+ if event.IsCreate() {
+ createReceived.increment()
+ }
+ t.Logf("event received: %s", event)
+ } else {
+ t.Logf("unexpected event received: %s", event)
+ }
+ }
+ done <- true
+ }()
+
+ // Create a file
+ // This should add at least one event to the fsnotify event queue
+ var f *os.File
+ f, err := os.OpenFile(testFile, os.O_WRONLY|os.O_CREATE, 0666)
+ if err != nil {
+ t.Fatalf("creating test file failed: %s", err)
+ }
+ f.Sync()
+ f.Close()
+
+ if err := testRename(testFile, testFileRenamed); err != nil {
+ t.Fatalf("rename failed: %s", err)
+ }
+
+ // We expect this event to be received almost immediately, but let's wait 500 ms to be sure
+ time.Sleep(500 * time.Millisecond)
+ if createReceived.value() == 0 {
+ t.Fatal("fsnotify create events have not been received after 500 ms")
+ }
+
+ // Try closing the fsnotify instance
+ t.Log("calling Close()")
+ watcher.Close()
+ t.Log("waiting for the event channel to become closed...")
+ select {
+ case <-done:
+ t.Log("event channel closed")
+ case <-time.After(2 * time.Second):
+ t.Fatal("event stream was not closed after 2 seconds")
+ }
+
+ os.Remove(testFileRenamed)
+}
+
+func TestFsnotifyRenameToOverwrite(t *testing.T) {
+ switch runtime.GOOS {
+ case "plan9", "windows":
+ t.Skipf("skipping test on %q (os.Rename over existing file does not create event).", runtime.GOOS)
+ }
+
+ watcher := newWatcher(t)
+
+ // Create directory to watch
+ testDir := tempMkdir(t)
+ defer os.RemoveAll(testDir)
+
+ // Create directory to get file
+ testDirFrom := tempMkdir(t)
+ defer os.RemoveAll(testDirFrom)
+
+ testFile := filepath.Join(testDirFrom, "TestFsnotifyEvents.testfile")
+ testFileRenamed := filepath.Join(testDir, "TestFsnotifyEvents.testfileRenamed")
+
+ // Create a file
+ var fr *os.File
+ fr, err := os.OpenFile(testFileRenamed, os.O_WRONLY|os.O_CREATE, 0666)
+ if err != nil {
+ t.Fatalf("creating test file failed: %s", err)
+ }
+ fr.Sync()
+ fr.Close()
+
+ addWatch(t, watcher, testDir)
+
+ // Receive errors on the error channel on a separate goroutine
+ go func() {
+ for err := range watcher.Error {
+ t.Fatalf("error received: %s", err)
+ }
+ }()
+
+ // Receive events on the event channel on a separate goroutine
+ eventstream := watcher.Event
+ var eventReceived counter
+ done := make(chan bool)
+ go func() {
+ for event := range eventstream {
+ // Only count relevant events
+ if event.Name == filepath.Clean(testFileRenamed) {
+ eventReceived.increment()
+ t.Logf("event received: %s", event)
+ } else {
+ t.Logf("unexpected event received: %s", event)
+ }
+ }
+ done <- true
+ }()
+
+ // Create a file
+ // This should add at least one event to the fsnotify event queue
+ var f *os.File
+ f, err = os.OpenFile(testFile, os.O_WRONLY|os.O_CREATE, 0666)
+ if err != nil {
+ t.Fatalf("creating test file failed: %s", err)
+ }
+ f.Sync()
+ f.Close()
+
+ if err := testRename(testFile, testFileRenamed); err != nil {
+ t.Fatalf("rename failed: %s", err)
+ }
+
+ // We expect this event to be received almost immediately, but let's wait 500 ms to be sure
+ time.Sleep(500 * time.Millisecond)
+ if eventReceived.value() == 0 {
+ t.Fatal("fsnotify events have not been received after 500 ms")
+ }
+
+ // Try closing the fsnotify instance
+ t.Log("calling Close()")
+ watcher.Close()
+ t.Log("waiting for the event channel to become closed...")
+ select {
+ case <-done:
+ t.Log("event channel closed")
+ case <-time.After(2 * time.Second):
+ t.Fatal("event stream was not closed after 2 seconds")
+ }
+
+ os.Remove(testFileRenamed)
+}
+
+func TestRemovalOfWatch(t *testing.T) {
+ // Create directory to watch
+ testDir := tempMkdir(t)
+ defer os.RemoveAll(testDir)
+
+ // Create a file before watching directory
+ testFileAlreadyExists := filepath.Join(testDir, "TestFsnotifyEventsExisting.testfile")
+ {
+ var f *os.File
+ f, err := os.OpenFile(testFileAlreadyExists, os.O_WRONLY|os.O_CREATE, 0666)
+ if err != nil {
+ t.Fatalf("creating test file failed: %s", err)
+ }
+ f.Sync()
+ f.Close()
+ }
+
+ watcher := newWatcher(t)
+ defer watcher.Close()
+
+ addWatch(t, watcher, testDir)
+ if err := watcher.RemoveWatch(testDir); err != nil {
+ t.Fatalf("Could not remove the watch: %v\n", err)
+ }
+
+ go func() {
+ select {
+ case ev := <-watcher.Event:
+ t.Fatalf("We received event: %v\n", ev)
+ case <-time.After(500 * time.Millisecond):
+ t.Log("No event received, as expected.")
+ }
+ }()
+
+ time.Sleep(200 * time.Millisecond)
+ // Modify the file outside of the watched dir
+ f, err := os.Open(testFileAlreadyExists)
+ if err != nil {
+ t.Fatalf("Open test file failed: %s", err)
+ }
+ f.WriteString("data")
+ f.Sync()
+ f.Close()
+ if err := os.Chmod(testFileAlreadyExists, 0700); err != nil {
+ t.Fatalf("chmod failed: %s", err)
+ }
+ time.Sleep(400 * time.Millisecond)
+}
+
+func TestFsnotifyAttrib(t *testing.T) {
+ if runtime.GOOS == "windows" {
+ t.Skip("attributes don't work on Windows.")
+ }
+
+ watcher := newWatcher(t)
+
+ // Create directory to watch
+ testDir := tempMkdir(t)
+ defer os.RemoveAll(testDir)
+
+ // Receive errors on the error channel on a separate goroutine
+ go func() {
+ for err := range watcher.Error {
+ t.Fatalf("error received: %s", err)
+ }
+ }()
+
+ testFile := filepath.Join(testDir, "TestFsnotifyAttrib.testfile")
+
+ // Receive events on the event channel on a separate goroutine
+ eventstream := watcher.Event
+ // The modifyReceived counter counts IsModify events that are not IsAttrib,
+ // and the attribReceived counts IsAttrib events (which are also IsModify as
+ // a consequence).
+ var modifyReceived counter
+ var attribReceived counter
+ done := make(chan bool)
+ go func() {
+ for event := range eventstream {
+ // Only count relevant events
+ if event.Name == filepath.Clean(testDir) || event.Name == filepath.Clean(testFile) {
+ if event.IsModify() {
+ modifyReceived.increment()
+ }
+ if event.IsAttrib() {
+ attribReceived.increment()
+ }
+ t.Logf("event received: %s", event)
+ } else {
+ t.Logf("unexpected event received: %s", event)
+ }
+ }
+ done <- true
+ }()
+
+ // Create a file
+ // This should add at least one event to the fsnotify event queue
+ var f *os.File
+ f, err := os.OpenFile(testFile, os.O_WRONLY|os.O_CREATE, 0666)
+ if err != nil {
+ t.Fatalf("creating test file failed: %s", err)
+ }
+ f.Sync()
+
+ f.WriteString("data")
+ f.Sync()
+ f.Close()
+
+ // Add a watch for testFile
+ addWatch(t, watcher, testFile)
+
+ if err := os.Chmod(testFile, 0700); err != nil {
+ t.Fatalf("chmod failed: %s", err)
+ }
+
+ // We expect this event to be received almost immediately, but let's wait 500 ms to be sure
+ // Creating/writing a file changes also the mtime, so IsAttrib should be set to true here
+ time.Sleep(500 * time.Millisecond)
+ if modifyReceived.value() == 0 {
+ t.Fatal("fsnotify modify events have not received after 500 ms")
+ }
+ if attribReceived.value() == 0 {
+ t.Fatal("fsnotify attribute events have not received after 500 ms")
+ }
+
+ // Modifying the contents of the file does not set the attrib flag (although eg. the mtime
+ // might have been modified).
+ modifyReceived.reset()
+ attribReceived.reset()
+
+ f, err = os.OpenFile(testFile, os.O_WRONLY, 0)
+ if err != nil {
+ t.Fatalf("reopening test file failed: %s", err)
+ }
+
+ f.WriteString("more data")
+ f.Sync()
+ f.Close()
+
+ time.Sleep(500 * time.Millisecond)
+
+ if modifyReceived.value() != 1 {
+ t.Fatal("didn't receive a modify event after changing test file contents")
+ }
+
+ if attribReceived.value() != 0 {
+ t.Fatal("did receive an unexpected attrib event after changing test file contents")
+ }
+
+ modifyReceived.reset()
+ attribReceived.reset()
+
+ // Doing a chmod on the file should trigger an event with the "attrib" flag set (the contents
+ // of the file are not changed though)
+ if err := os.Chmod(testFile, 0600); err != nil {
+ t.Fatalf("chmod failed: %s", err)
+ }
+
+ time.Sleep(500 * time.Millisecond)
+
+ if attribReceived.value() != 1 {
+ t.Fatal("didn't receive an attribute change after 500ms")
+ }
+
+ // Try closing the fsnotify instance
+ t.Log("calling Close()")
+ watcher.Close()
+ t.Log("waiting for the event channel to become closed...")
+ select {
+ case <-done:
+ t.Log("event channel closed")
+ case <-time.After(1e9):
+ t.Fatal("event stream was not closed after 1 second")
+ }
+
+ os.Remove(testFile)
+}
+
+func TestFsnotifyClose(t *testing.T) {
+ watcher := newWatcher(t)
+ watcher.Close()
+
+ var done int32
+ go func() {
+ watcher.Close()
+ atomic.StoreInt32(&done, 1)
+ }()
+
+ time.Sleep(50e6) // 50 ms
+ if atomic.LoadInt32(&done) == 0 {
+ t.Fatal("double Close() test failed: second Close() call didn't return")
+ }
+
+ testDir := tempMkdir(t)
+ defer os.RemoveAll(testDir)
+
+ if err := watcher.Watch(testDir); err == nil {
+ t.Fatal("expected error on Watch() after Close(), got nil")
+ }
+}
+
+func testRename(file1, file2 string) error {
+ switch runtime.GOOS {
+ case "windows", "plan9":
+ return os.Rename(file1, file2)
+ default:
+ cmd := exec.Command("mv", file1, file2)
+ return cmd.Run()
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/howeyc/fsnotify/fsnotify_windows.go b/Godeps/_workspace/src/github.com/howeyc/fsnotify/fsnotify_windows.go
new file mode 100644
index 000000000..d88ae6340
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/howeyc/fsnotify/fsnotify_windows.go
@@ -0,0 +1,598 @@
+// Copyright 2011 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// +build windows
+
+package fsnotify
+
+import (
+ "errors"
+ "fmt"
+ "os"
+ "path/filepath"
+ "runtime"
+ "sync"
+ "syscall"
+ "unsafe"
+)
+
+const (
+ // Options for AddWatch
+ sys_FS_ONESHOT = 0x80000000
+ sys_FS_ONLYDIR = 0x1000000
+
+ // Events
+ sys_FS_ACCESS = 0x1
+ sys_FS_ALL_EVENTS = 0xfff
+ sys_FS_ATTRIB = 0x4
+ sys_FS_CLOSE = 0x18
+ sys_FS_CREATE = 0x100
+ sys_FS_DELETE = 0x200
+ sys_FS_DELETE_SELF = 0x400
+ sys_FS_MODIFY = 0x2
+ sys_FS_MOVE = 0xc0
+ sys_FS_MOVED_FROM = 0x40
+ sys_FS_MOVED_TO = 0x80
+ sys_FS_MOVE_SELF = 0x800
+
+ // Special events
+ sys_FS_IGNORED = 0x8000
+ sys_FS_Q_OVERFLOW = 0x4000
+)
+
+const (
+ // TODO(nj): Use syscall.ERROR_MORE_DATA from ztypes_windows in Go 1.3+
+ sys_ERROR_MORE_DATA syscall.Errno = 234
+)
+
+// Event is the type of the notification messages
+// received on the watcher's Event channel.
+type FileEvent struct {
+ mask uint32 // Mask of events
+ cookie uint32 // Unique cookie associating related events (for rename)
+ Name string // File name (optional)
+}
+
+// IsCreate reports whether the FileEvent was triggered by a creation
+func (e *FileEvent) IsCreate() bool { return (e.mask & sys_FS_CREATE) == sys_FS_CREATE }
+
+// IsDelete reports whether the FileEvent was triggered by a delete
+func (e *FileEvent) IsDelete() bool {
+ return ((e.mask&sys_FS_DELETE) == sys_FS_DELETE || (e.mask&sys_FS_DELETE_SELF) == sys_FS_DELETE_SELF)
+}
+
+// IsModify reports whether the FileEvent was triggered by a file modification or attribute change
+func (e *FileEvent) IsModify() bool {
+ return ((e.mask&sys_FS_MODIFY) == sys_FS_MODIFY || (e.mask&sys_FS_ATTRIB) == sys_FS_ATTRIB)
+}
+
+// IsRename reports whether the FileEvent was triggered by a change name
+func (e *FileEvent) IsRename() bool {
+ return ((e.mask&sys_FS_MOVE) == sys_FS_MOVE || (e.mask&sys_FS_MOVE_SELF) == sys_FS_MOVE_SELF || (e.mask&sys_FS_MOVED_FROM) == sys_FS_MOVED_FROM || (e.mask&sys_FS_MOVED_TO) == sys_FS_MOVED_TO)
+}
+
+// IsAttrib reports whether the FileEvent was triggered by a change in the file metadata.
+func (e *FileEvent) IsAttrib() bool {
+ return (e.mask & sys_FS_ATTRIB) == sys_FS_ATTRIB
+}
+
+const (
+ opAddWatch = iota
+ opRemoveWatch
+)
+
+const (
+ provisional uint64 = 1 << (32 + iota)
+)
+
+type input struct {
+ op int
+ path string
+ flags uint32
+ reply chan error
+}
+
+type inode struct {
+ handle syscall.Handle
+ volume uint32
+ index uint64
+}
+
+type watch struct {
+ ov syscall.Overlapped
+ ino *inode // i-number
+ path string // Directory path
+ mask uint64 // Directory itself is being watched with these notify flags
+ names map[string]uint64 // Map of names being watched and their notify flags
+ rename string // Remembers the old name while renaming a file
+ buf [4096]byte
+}
+
+type indexMap map[uint64]*watch
+type watchMap map[uint32]indexMap
+
+// A Watcher waits for and receives event notifications
+// for a specific set of files and directories.
+type Watcher struct {
+ mu sync.Mutex // Map access
+ port syscall.Handle // Handle to completion port
+ watches watchMap // Map of watches (key: i-number)
+ fsnFlags map[string]uint32 // Map of watched files to flags used for filter
+ fsnmut sync.Mutex // Protects access to fsnFlags.
+ input chan *input // Inputs to the reader are sent on this channel
+ internalEvent chan *FileEvent // Events are queued on this channel
+ Event chan *FileEvent // Events are returned on this channel
+ Error chan error // Errors are sent on this channel
+ isClosed bool // Set to true when Close() is first called
+ quit chan chan<- error
+ cookie uint32
+}
+
+// NewWatcher creates and returns a Watcher.
+func NewWatcher() (*Watcher, error) {
+ port, e := syscall.CreateIoCompletionPort(syscall.InvalidHandle, 0, 0, 0)
+ if e != nil {
+ return nil, os.NewSyscallError("CreateIoCompletionPort", e)
+ }
+ w := &Watcher{
+ port: port,
+ watches: make(watchMap),
+ fsnFlags: make(map[string]uint32),
+ input: make(chan *input, 1),
+ Event: make(chan *FileEvent, 50),
+ internalEvent: make(chan *FileEvent),
+ Error: make(chan error),
+ quit: make(chan chan<- error, 1),
+ }
+ go w.readEvents()
+ go w.purgeEvents()
+ return w, nil
+}
+
+// Close closes a Watcher.
+// It sends a message to the reader goroutine to quit and removes all watches
+// associated with the watcher.
+func (w *Watcher) Close() error {
+ if w.isClosed {
+ return nil
+ }
+ w.isClosed = true
+
+ // Send "quit" message to the reader goroutine
+ ch := make(chan error)
+ w.quit <- ch
+ if err := w.wakeupReader(); err != nil {
+ return err
+ }
+ return <-ch
+}
+
+// AddWatch adds path to the watched file set.
+func (w *Watcher) AddWatch(path string, flags uint32) error {
+ if w.isClosed {
+ return errors.New("watcher already closed")
+ }
+ in := &input{
+ op: opAddWatch,
+ path: filepath.Clean(path),
+ flags: flags,
+ reply: make(chan error),
+ }
+ w.input <- in
+ if err := w.wakeupReader(); err != nil {
+ return err
+ }
+ return <-in.reply
+}
+
+// Watch adds path to the watched file set, watching all events.
+func (w *Watcher) watch(path string) error {
+ return w.AddWatch(path, sys_FS_ALL_EVENTS)
+}
+
+// RemoveWatch removes path from the watched file set.
+func (w *Watcher) removeWatch(path string) error {
+ in := &input{
+ op: opRemoveWatch,
+ path: filepath.Clean(path),
+ reply: make(chan error),
+ }
+ w.input <- in
+ if err := w.wakeupReader(); err != nil {
+ return err
+ }
+ return <-in.reply
+}
+
+func (w *Watcher) wakeupReader() error {
+ e := syscall.PostQueuedCompletionStatus(w.port, 0, 0, nil)
+ if e != nil {
+ return os.NewSyscallError("PostQueuedCompletionStatus", e)
+ }
+ return nil
+}
+
+func getDir(pathname string) (dir string, err error) {
+ attr, e := syscall.GetFileAttributes(syscall.StringToUTF16Ptr(pathname))
+ if e != nil {
+ return "", os.NewSyscallError("GetFileAttributes", e)
+ }
+ if attr&syscall.FILE_ATTRIBUTE_DIRECTORY != 0 {
+ dir = pathname
+ } else {
+ dir, _ = filepath.Split(pathname)
+ dir = filepath.Clean(dir)
+ }
+ return
+}
+
+func getIno(path string) (ino *inode, err error) {
+ h, e := syscall.CreateFile(syscall.StringToUTF16Ptr(path),
+ syscall.FILE_LIST_DIRECTORY,
+ syscall.FILE_SHARE_READ|syscall.FILE_SHARE_WRITE|syscall.FILE_SHARE_DELETE,
+ nil, syscall.OPEN_EXISTING,
+ syscall.FILE_FLAG_BACKUP_SEMANTICS|syscall.FILE_FLAG_OVERLAPPED, 0)
+ if e != nil {
+ return nil, os.NewSyscallError("CreateFile", e)
+ }
+ var fi syscall.ByHandleFileInformation
+ if e = syscall.GetFileInformationByHandle(h, &fi); e != nil {
+ syscall.CloseHandle(h)
+ return nil, os.NewSyscallError("GetFileInformationByHandle", e)
+ }
+ ino = &inode{
+ handle: h,
+ volume: fi.VolumeSerialNumber,
+ index: uint64(fi.FileIndexHigh)<<32 | uint64(fi.FileIndexLow),
+ }
+ return ino, nil
+}
+
+// Must run within the I/O thread.
+func (m watchMap) get(ino *inode) *watch {
+ if i := m[ino.volume]; i != nil {
+ return i[ino.index]
+ }
+ return nil
+}
+
+// Must run within the I/O thread.
+func (m watchMap) set(ino *inode, watch *watch) {
+ i := m[ino.volume]
+ if i == nil {
+ i = make(indexMap)
+ m[ino.volume] = i
+ }
+ i[ino.index] = watch
+}
+
+// Must run within the I/O thread.
+func (w *Watcher) addWatch(pathname string, flags uint64) error {
+ dir, err := getDir(pathname)
+ if err != nil {
+ return err
+ }
+ if flags&sys_FS_ONLYDIR != 0 && pathname != dir {
+ return nil
+ }
+ ino, err := getIno(dir)
+ if err != nil {
+ return err
+ }
+ w.mu.Lock()
+ watchEntry := w.watches.get(ino)
+ w.mu.Unlock()
+ if watchEntry == nil {
+ if _, e := syscall.CreateIoCompletionPort(ino.handle, w.port, 0, 0); e != nil {
+ syscall.CloseHandle(ino.handle)
+ return os.NewSyscallError("CreateIoCompletionPort", e)
+ }
+ watchEntry = &watch{
+ ino: ino,
+ path: dir,
+ names: make(map[string]uint64),
+ }
+ w.mu.Lock()
+ w.watches.set(ino, watchEntry)
+ w.mu.Unlock()
+ flags |= provisional
+ } else {
+ syscall.CloseHandle(ino.handle)
+ }
+ if pathname == dir {
+ watchEntry.mask |= flags
+ } else {
+ watchEntry.names[filepath.Base(pathname)] |= flags
+ }
+ if err = w.startRead(watchEntry); err != nil {
+ return err
+ }
+ if pathname == dir {
+ watchEntry.mask &= ^provisional
+ } else {
+ watchEntry.names[filepath.Base(pathname)] &= ^provisional
+ }
+ return nil
+}
+
+// Must run within the I/O thread.
+func (w *Watcher) remWatch(pathname string) error {
+ dir, err := getDir(pathname)
+ if err != nil {
+ return err
+ }
+ ino, err := getIno(dir)
+ if err != nil {
+ return err
+ }
+ w.mu.Lock()
+ watch := w.watches.get(ino)
+ w.mu.Unlock()
+ if watch == nil {
+ return fmt.Errorf("can't remove non-existent watch for: %s", pathname)
+ }
+ if pathname == dir {
+ w.sendEvent(watch.path, watch.mask&sys_FS_IGNORED)
+ watch.mask = 0
+ } else {
+ name := filepath.Base(pathname)
+ w.sendEvent(watch.path+"\\"+name, watch.names[name]&sys_FS_IGNORED)
+ delete(watch.names, name)
+ }
+ return w.startRead(watch)
+}
+
+// Must run within the I/O thread.
+func (w *Watcher) deleteWatch(watch *watch) {
+ for name, mask := range watch.names {
+ if mask&provisional == 0 {
+ w.sendEvent(watch.path+"\\"+name, mask&sys_FS_IGNORED)
+ }
+ delete(watch.names, name)
+ }
+ if watch.mask != 0 {
+ if watch.mask&provisional == 0 {
+ w.sendEvent(watch.path, watch.mask&sys_FS_IGNORED)
+ }
+ watch.mask = 0
+ }
+}
+
+// Must run within the I/O thread.
+func (w *Watcher) startRead(watch *watch) error {
+ if e := syscall.CancelIo(watch.ino.handle); e != nil {
+ w.Error <- os.NewSyscallError("CancelIo", e)
+ w.deleteWatch(watch)
+ }
+ mask := toWindowsFlags(watch.mask)
+ for _, m := range watch.names {
+ mask |= toWindowsFlags(m)
+ }
+ if mask == 0 {
+ if e := syscall.CloseHandle(watch.ino.handle); e != nil {
+ w.Error <- os.NewSyscallError("CloseHandle", e)
+ }
+ w.mu.Lock()
+ delete(w.watches[watch.ino.volume], watch.ino.index)
+ w.mu.Unlock()
+ return nil
+ }
+ e := syscall.ReadDirectoryChanges(watch.ino.handle, &watch.buf[0],
+ uint32(unsafe.Sizeof(watch.buf)), false, mask, nil, &watch.ov, 0)
+ if e != nil {
+ err := os.NewSyscallError("ReadDirectoryChanges", e)
+ if e == syscall.ERROR_ACCESS_DENIED && watch.mask&provisional == 0 {
+ // Watched directory was probably removed
+ if w.sendEvent(watch.path, watch.mask&sys_FS_DELETE_SELF) {
+ if watch.mask&sys_FS_ONESHOT != 0 {
+ watch.mask = 0
+ }
+ }
+ err = nil
+ }
+ w.deleteWatch(watch)
+ w.startRead(watch)
+ return err
+ }
+ return nil
+}
+
+// readEvents reads from the I/O completion port, converts the
+// received events into Event objects and sends them via the Event channel.
+// Entry point to the I/O thread.
+func (w *Watcher) readEvents() {
+ var (
+ n, key uint32
+ ov *syscall.Overlapped
+ )
+ runtime.LockOSThread()
+
+ for {
+ e := syscall.GetQueuedCompletionStatus(w.port, &n, &key, &ov, syscall.INFINITE)
+ watch := (*watch)(unsafe.Pointer(ov))
+
+ if watch == nil {
+ select {
+ case ch := <-w.quit:
+ w.mu.Lock()
+ var indexes []indexMap
+ for _, index := range w.watches {
+ indexes = append(indexes, index)
+ }
+ w.mu.Unlock()
+ for _, index := range indexes {
+ for _, watch := range index {
+ w.deleteWatch(watch)
+ w.startRead(watch)
+ }
+ }
+ var err error
+ if e := syscall.CloseHandle(w.port); e != nil {
+ err = os.NewSyscallError("CloseHandle", e)
+ }
+ close(w.internalEvent)
+ close(w.Error)
+ ch <- err
+ return
+ case in := <-w.input:
+ switch in.op {
+ case opAddWatch:
+ in.reply <- w.addWatch(in.path, uint64(in.flags))
+ case opRemoveWatch:
+ in.reply <- w.remWatch(in.path)
+ }
+ default:
+ }
+ continue
+ }
+
+ switch e {
+ case sys_ERROR_MORE_DATA:
+ if watch == nil {
+ w.Error <- errors.New("ERROR_MORE_DATA has unexpectedly null lpOverlapped buffer")
+ } else {
+ // The i/o succeeded but the buffer is full.
+ // In theory we should be building up a full packet.
+ // In practice we can get away with just carrying on.
+ n = uint32(unsafe.Sizeof(watch.buf))
+ }
+ case syscall.ERROR_ACCESS_DENIED:
+ // Watched directory was probably removed
+ w.sendEvent(watch.path, watch.mask&sys_FS_DELETE_SELF)
+ w.deleteWatch(watch)
+ w.startRead(watch)
+ continue
+ case syscall.ERROR_OPERATION_ABORTED:
+ // CancelIo was called on this handle
+ continue
+ default:
+ w.Error <- os.NewSyscallError("GetQueuedCompletionPort", e)
+ continue
+ case nil:
+ }
+
+ var offset uint32
+ for {
+ if n == 0 {
+ w.internalEvent <- &FileEvent{mask: sys_FS_Q_OVERFLOW}
+ w.Error <- errors.New("short read in readEvents()")
+ break
+ }
+
+ // Point "raw" to the event in the buffer
+ raw := (*syscall.FileNotifyInformation)(unsafe.Pointer(&watch.buf[offset]))
+ buf := (*[syscall.MAX_PATH]uint16)(unsafe.Pointer(&raw.FileName))
+ name := syscall.UTF16ToString(buf[:raw.FileNameLength/2])
+ fullname := watch.path + "\\" + name
+
+ var mask uint64
+ switch raw.Action {
+ case syscall.FILE_ACTION_REMOVED:
+ mask = sys_FS_DELETE_SELF
+ case syscall.FILE_ACTION_MODIFIED:
+ mask = sys_FS_MODIFY
+ case syscall.FILE_ACTION_RENAMED_OLD_NAME:
+ watch.rename = name
+ case syscall.FILE_ACTION_RENAMED_NEW_NAME:
+ if watch.names[watch.rename] != 0 {
+ watch.names[name] |= watch.names[watch.rename]
+ delete(watch.names, watch.rename)
+ mask = sys_FS_MOVE_SELF
+ }
+ }
+
+ sendNameEvent := func() {
+ if w.sendEvent(fullname, watch.names[name]&mask) {
+ if watch.names[name]&sys_FS_ONESHOT != 0 {
+ delete(watch.names, name)
+ }
+ }
+ }
+ if raw.Action != syscall.FILE_ACTION_RENAMED_NEW_NAME {
+ sendNameEvent()
+ }
+ if raw.Action == syscall.FILE_ACTION_REMOVED {
+ w.sendEvent(fullname, watch.names[name]&sys_FS_IGNORED)
+ delete(watch.names, name)
+ }
+ if w.sendEvent(fullname, watch.mask&toFSnotifyFlags(raw.Action)) {
+ if watch.mask&sys_FS_ONESHOT != 0 {
+ watch.mask = 0
+ }
+ }
+ if raw.Action == syscall.FILE_ACTION_RENAMED_NEW_NAME {
+ fullname = watch.path + "\\" + watch.rename
+ sendNameEvent()
+ }
+
+ // Move to the next event in the buffer
+ if raw.NextEntryOffset == 0 {
+ break
+ }
+ offset += raw.NextEntryOffset
+
+ // Error!
+ if offset >= n {
+ w.Error <- errors.New("Windows system assumed buffer larger than it is, events have likely been missed.")
+ break
+ }
+ }
+
+ if err := w.startRead(watch); err != nil {
+ w.Error <- err
+ }
+ }
+}
+
+func (w *Watcher) sendEvent(name string, mask uint64) bool {
+ if mask == 0 {
+ return false
+ }
+ event := &FileEvent{mask: uint32(mask), Name: name}
+ if mask&sys_FS_MOVE != 0 {
+ if mask&sys_FS_MOVED_FROM != 0 {
+ w.cookie++
+ }
+ event.cookie = w.cookie
+ }
+ select {
+ case ch := <-w.quit:
+ w.quit <- ch
+ case w.Event <- event:
+ }
+ return true
+}
+
+func toWindowsFlags(mask uint64) uint32 {
+ var m uint32
+ if mask&sys_FS_ACCESS != 0 {
+ m |= syscall.FILE_NOTIFY_CHANGE_LAST_ACCESS
+ }
+ if mask&sys_FS_MODIFY != 0 {
+ m |= syscall.FILE_NOTIFY_CHANGE_LAST_WRITE
+ }
+ if mask&sys_FS_ATTRIB != 0 {
+ m |= syscall.FILE_NOTIFY_CHANGE_ATTRIBUTES
+ }
+ if mask&(sys_FS_MOVE|sys_FS_CREATE|sys_FS_DELETE) != 0 {
+ m |= syscall.FILE_NOTIFY_CHANGE_FILE_NAME | syscall.FILE_NOTIFY_CHANGE_DIR_NAME
+ }
+ return m
+}
+
+func toFSnotifyFlags(action uint32) uint64 {
+ switch action {
+ case syscall.FILE_ACTION_ADDED:
+ return sys_FS_CREATE
+ case syscall.FILE_ACTION_REMOVED:
+ return sys_FS_DELETE
+ case syscall.FILE_ACTION_MODIFIED:
+ return sys_FS_MODIFY
+ case syscall.FILE_ACTION_RENAMED_OLD_NAME:
+ return sys_FS_MOVED_FROM
+ case syscall.FILE_ACTION_RENAMED_NEW_NAME:
+ return sys_FS_MOVED_TO
+ }
+ return 0
+}
diff --git a/Godeps/_workspace/src/github.com/huin/goupnp/LICENSE b/Godeps/_workspace/src/github.com/huin/goupnp/LICENSE
new file mode 100644
index 000000000..252e3d639
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/huin/goupnp/LICENSE
@@ -0,0 +1,23 @@
+Copyright (c) 2013, John Beisley <greatred@gmail.com>
+All rights reserved.
+
+Redistribution and use in source and binary forms, with or without modification,
+are permitted provided that the following conditions are met:
+
+* Redistributions of source code must retain the above copyright notice, this
+ list of conditions and the following disclaimer.
+
+* Redistributions in binary form must reproduce the above copyright notice, this
+ list of conditions and the following disclaimer in the documentation and/or
+ other materials provided with the distribution.
+
+THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR
+ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
+ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
diff --git a/Godeps/_workspace/src/github.com/huin/goupnp/README.md b/Godeps/_workspace/src/github.com/huin/goupnp/README.md
new file mode 100644
index 000000000..ea2c155a1
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/huin/goupnp/README.md
@@ -0,0 +1,14 @@
+goupnp is a UPnP client library for Go
+
+Installation
+------------
+
+Run `go get -u github.com/huin/goupnp`.
+
+Regenerating dcps generated source code:
+----------------------------------------
+
+1. Install gotasks: `go get -u github.com/jingweno/gotask`
+2. Change to the gotasks directory: `cd gotasks`
+3. Download UPnP specification data (if not done already): `wget http://upnp.org/resources/upnpresources.zip`
+4. Regenerate source code: `gotask specgen -s upnpresources.zip -o ../dcps`
diff --git a/Godeps/_workspace/src/github.com/huin/goupnp/cmd/example_httpu_serving/example_httpu_serving.go b/Godeps/_workspace/src/github.com/huin/goupnp/cmd/example_httpu_serving/example_httpu_serving.go
new file mode 100644
index 000000000..d9d9daa93
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/huin/goupnp/cmd/example_httpu_serving/example_httpu_serving.go
@@ -0,0 +1,20 @@
+package main
+
+import (
+ "log"
+ "net/http"
+
+ "github.com/huin/goupnp/httpu"
+)
+
+func main() {
+ srv := httpu.Server{
+ Addr: "239.255.255.250:1900",
+ Multicast: true,
+ Handler: httpu.HandlerFunc(func(r *http.Request) {
+ log.Printf("Got %s %s message from %v: %v", r.Method, r.URL.Path, r.RemoteAddr, r.Header)
+ }),
+ }
+ err := srv.ListenAndServe()
+ log.Printf("Serving failed with error: %v", err)
+}
diff --git a/Godeps/_workspace/src/github.com/huin/goupnp/cmd/example_internetgateway1/example_internetgateway1.go b/Godeps/_workspace/src/github.com/huin/goupnp/cmd/example_internetgateway1/example_internetgateway1.go
new file mode 100644
index 000000000..29e8adc8b
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/huin/goupnp/cmd/example_internetgateway1/example_internetgateway1.go
@@ -0,0 +1,67 @@
+package main
+
+import (
+ "fmt"
+ "log"
+
+ "github.com/huin/goupnp/dcps/internetgateway1"
+)
+
+func main() {
+ clients, errors, err := internetgateway1.NewWANPPPConnection1Clients()
+ if err != nil {
+ log.Fatal(err)
+ }
+
+ fmt.Printf("Got %d errors finding servers and %d successfully discovered.\n",
+ len(errors), len(clients))
+ for i, e := range errors {
+ fmt.Printf("Error finding server #%d: %v\n", i+1, e)
+ }
+
+ for _, c := range clients {
+ dev := &c.ServiceClient.RootDevice.Device
+ srv := c.ServiceClient.Service
+ fmt.Println(dev.FriendlyName, " :: ", srv.String())
+ scpd, err := srv.RequestSCDP()
+ if err != nil {
+ fmt.Printf(" Error requesting service SCPD: %v\n", err)
+ } else {
+ fmt.Println(" Available actions:")
+ for _, action := range scpd.Actions {
+ fmt.Printf(" * %s\n", action.Name)
+ for _, arg := range action.Arguments {
+ var varDesc string
+ if stateVar := scpd.GetStateVariable(arg.RelatedStateVariable); stateVar != nil {
+ varDesc = fmt.Sprintf(" (%s)", stateVar.DataType.Name)
+ }
+ fmt.Printf(" * [%s] %s%s\n", arg.Direction, arg.Name, varDesc)
+ }
+ }
+ }
+
+ if scpd == nil || scpd.GetAction("GetExternalIPAddress") != nil {
+ ip, err := c.GetExternalIPAddress()
+ fmt.Println("GetExternalIPAddress: ", ip, err)
+ }
+
+ if scpd == nil || scpd.GetAction("GetStatusInfo") != nil {
+ status, lastErr, uptime, err := c.GetStatusInfo()
+ fmt.Println("GetStatusInfo: ", status, lastErr, uptime, err)
+ }
+
+ if scpd == nil || scpd.GetAction("GetIdleDisconnectTime") != nil {
+ idleTime, err := c.GetIdleDisconnectTime()
+ fmt.Println("GetIdleDisconnectTime: ", idleTime, err)
+ }
+
+ if scpd == nil || scpd.GetAction("AddPortMapping") != nil {
+ err := c.AddPortMapping("", 5000, "TCP", 5001, "192.168.1.2", true, "Test port mapping", 0)
+ fmt.Println("AddPortMapping: ", err)
+ }
+ if scpd == nil || scpd.GetAction("DeletePortMapping") != nil {
+ err := c.DeletePortMapping("", 5000, "TCP")
+ fmt.Println("DeletePortMapping: ", err)
+ }
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/huin/goupnp/dcps/internetgateway1/internetgateway1.go b/Godeps/_workspace/src/github.com/huin/goupnp/dcps/internetgateway1/internetgateway1.go
new file mode 100644
index 000000000..be71855a9
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/huin/goupnp/dcps/internetgateway1/internetgateway1.go
@@ -0,0 +1,3957 @@
+// Client for UPnP Device Control Protocol Internet Gateway Device v1.
+//
+// This DCP is documented in detail at: http://upnp.org/specs/gw/UPnP-gw-InternetGatewayDevice-v1-Device.pdf
+//
+// Typically, use one of the New* functions to discover services on the local
+// network.
+package internetgateway1
+
+// Generated file - do not edit by hand. See README.md
+
+import (
+ "time"
+
+ "github.com/huin/goupnp"
+ "github.com/huin/goupnp/soap"
+)
+
+// Hack to avoid Go complaining if time isn't used.
+var _ time.Time
+
+// Device URNs:
+const (
+ URN_LANDevice_1 = "urn:schemas-upnp-org:device:LANDevice:1"
+ URN_WANConnectionDevice_1 = "urn:schemas-upnp-org:device:WANConnectionDevice:1"
+ URN_WANDevice_1 = "urn:schemas-upnp-org:device:WANDevice:1"
+)
+
+// Service URNs:
+const (
+ URN_LANHostConfigManagement_1 = "urn:schemas-upnp-org:service:LANHostConfigManagement:1"
+ URN_Layer3Forwarding_1 = "urn:schemas-upnp-org:service:Layer3Forwarding:1"
+ URN_WANCableLinkConfig_1 = "urn:schemas-upnp-org:service:WANCableLinkConfig:1"
+ URN_WANCommonInterfaceConfig_1 = "urn:schemas-upnp-org:service:WANCommonInterfaceConfig:1"
+ URN_WANDSLLinkConfig_1 = "urn:schemas-upnp-org:service:WANDSLLinkConfig:1"
+ URN_WANEthernetLinkConfig_1 = "urn:schemas-upnp-org:service:WANEthernetLinkConfig:1"
+ URN_WANIPConnection_1 = "urn:schemas-upnp-org:service:WANIPConnection:1"
+ URN_WANPOTSLinkConfig_1 = "urn:schemas-upnp-org:service:WANPOTSLinkConfig:1"
+ URN_WANPPPConnection_1 = "urn:schemas-upnp-org:service:WANPPPConnection:1"
+)
+
+// LANHostConfigManagement1 is a client for UPnP SOAP service with URN "urn:schemas-upnp-org:service:LANHostConfigManagement:1". See
+// goupnp.ServiceClient, which contains RootDevice and Service attributes which
+// are provided for informational value.
+type LANHostConfigManagement1 struct {
+ goupnp.ServiceClient
+}
+
+// NewLANHostConfigManagement1Clients discovers instances of the service on the network,
+// and returns clients to any that are found. errors will contain an error for
+// any devices that replied but which could not be queried, and err will be set
+// if the discovery process failed outright.
+//
+// This is a typical entry calling point into this package.
+func NewLANHostConfigManagement1Clients() (clients []*LANHostConfigManagement1, errors []error, err error) {
+ var genericClients []goupnp.ServiceClient
+ if genericClients, errors, err = goupnp.NewServiceClients(URN_LANHostConfigManagement_1); err != nil {
+ return
+ }
+ clients = make([]*LANHostConfigManagement1, len(genericClients))
+ for i := range genericClients {
+ clients[i] = &LANHostConfigManagement1{genericClients[i]}
+ }
+ return
+}
+
+// Arguments:
+//
+// * NewDHCPServerConfigurable:
+//
+//
+func (client *LANHostConfigManagement1) SetDHCPServerConfigurable(NewDHCPServerConfigurable bool) (err error) {
+ // Request structure.
+ request := &struct {
+ NewDHCPServerConfigurable string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewDHCPServerConfigurable, err = soap.MarshalBoolean(NewDHCPServerConfigurable); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_LANHostConfigManagement_1, "SetDHCPServerConfigurable", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewDHCPServerConfigurable:
+func (client *LANHostConfigManagement1) GetDHCPServerConfigurable() (NewDHCPServerConfigurable bool, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewDHCPServerConfigurable string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_LANHostConfigManagement_1, "GetDHCPServerConfigurable", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewDHCPServerConfigurable, err = soap.UnmarshalBoolean(response.NewDHCPServerConfigurable); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewDHCPRelay:
+//
+//
+func (client *LANHostConfigManagement1) SetDHCPRelay(NewDHCPRelay bool) (err error) {
+ // Request structure.
+ request := &struct {
+ NewDHCPRelay string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewDHCPRelay, err = soap.MarshalBoolean(NewDHCPRelay); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_LANHostConfigManagement_1, "SetDHCPRelay", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewDHCPRelay:
+func (client *LANHostConfigManagement1) GetDHCPRelay() (NewDHCPRelay bool, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewDHCPRelay string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_LANHostConfigManagement_1, "GetDHCPRelay", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewDHCPRelay, err = soap.UnmarshalBoolean(response.NewDHCPRelay); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewSubnetMask:
+//
+//
+func (client *LANHostConfigManagement1) SetSubnetMask(NewSubnetMask string) (err error) {
+ // Request structure.
+ request := &struct {
+ NewSubnetMask string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewSubnetMask, err = soap.MarshalString(NewSubnetMask); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_LANHostConfigManagement_1, "SetSubnetMask", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewSubnetMask:
+func (client *LANHostConfigManagement1) GetSubnetMask() (NewSubnetMask string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewSubnetMask string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_LANHostConfigManagement_1, "GetSubnetMask", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewSubnetMask, err = soap.UnmarshalString(response.NewSubnetMask); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewIPRouters:
+//
+//
+func (client *LANHostConfigManagement1) SetIPRouter(NewIPRouters string) (err error) {
+ // Request structure.
+ request := &struct {
+ NewIPRouters string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewIPRouters, err = soap.MarshalString(NewIPRouters); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_LANHostConfigManagement_1, "SetIPRouter", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewIPRouters:
+//
+//
+func (client *LANHostConfigManagement1) DeleteIPRouter(NewIPRouters string) (err error) {
+ // Request structure.
+ request := &struct {
+ NewIPRouters string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewIPRouters, err = soap.MarshalString(NewIPRouters); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_LANHostConfigManagement_1, "DeleteIPRouter", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewIPRouters:
+func (client *LANHostConfigManagement1) GetIPRoutersList() (NewIPRouters string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewIPRouters string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_LANHostConfigManagement_1, "GetIPRoutersList", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewIPRouters, err = soap.UnmarshalString(response.NewIPRouters); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewDomainName:
+//
+//
+func (client *LANHostConfigManagement1) SetDomainName(NewDomainName string) (err error) {
+ // Request structure.
+ request := &struct {
+ NewDomainName string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewDomainName, err = soap.MarshalString(NewDomainName); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_LANHostConfigManagement_1, "SetDomainName", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewDomainName:
+func (client *LANHostConfigManagement1) GetDomainName() (NewDomainName string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewDomainName string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_LANHostConfigManagement_1, "GetDomainName", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewDomainName, err = soap.UnmarshalString(response.NewDomainName); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewMinAddress:
+//
+// * NewMaxAddress:
+//
+//
+func (client *LANHostConfigManagement1) SetAddressRange(NewMinAddress string, NewMaxAddress string) (err error) {
+ // Request structure.
+ request := &struct {
+ NewMinAddress string
+
+ NewMaxAddress string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewMinAddress, err = soap.MarshalString(NewMinAddress); err != nil {
+ return
+ }
+ if request.NewMaxAddress, err = soap.MarshalString(NewMaxAddress); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_LANHostConfigManagement_1, "SetAddressRange", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewMinAddress:
+//
+// * NewMaxAddress:
+func (client *LANHostConfigManagement1) GetAddressRange() (NewMinAddress string, NewMaxAddress string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewMinAddress string
+
+ NewMaxAddress string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_LANHostConfigManagement_1, "GetAddressRange", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewMinAddress, err = soap.UnmarshalString(response.NewMinAddress); err != nil {
+ return
+ }
+ if NewMaxAddress, err = soap.UnmarshalString(response.NewMaxAddress); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewReservedAddresses:
+//
+//
+func (client *LANHostConfigManagement1) SetReservedAddress(NewReservedAddresses string) (err error) {
+ // Request structure.
+ request := &struct {
+ NewReservedAddresses string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewReservedAddresses, err = soap.MarshalString(NewReservedAddresses); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_LANHostConfigManagement_1, "SetReservedAddress", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewReservedAddresses:
+//
+//
+func (client *LANHostConfigManagement1) DeleteReservedAddress(NewReservedAddresses string) (err error) {
+ // Request structure.
+ request := &struct {
+ NewReservedAddresses string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewReservedAddresses, err = soap.MarshalString(NewReservedAddresses); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_LANHostConfigManagement_1, "DeleteReservedAddress", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewReservedAddresses:
+func (client *LANHostConfigManagement1) GetReservedAddresses() (NewReservedAddresses string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewReservedAddresses string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_LANHostConfigManagement_1, "GetReservedAddresses", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewReservedAddresses, err = soap.UnmarshalString(response.NewReservedAddresses); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewDNSServers:
+//
+//
+func (client *LANHostConfigManagement1) SetDNSServer(NewDNSServers string) (err error) {
+ // Request structure.
+ request := &struct {
+ NewDNSServers string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewDNSServers, err = soap.MarshalString(NewDNSServers); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_LANHostConfigManagement_1, "SetDNSServer", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewDNSServers:
+//
+//
+func (client *LANHostConfigManagement1) DeleteDNSServer(NewDNSServers string) (err error) {
+ // Request structure.
+ request := &struct {
+ NewDNSServers string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewDNSServers, err = soap.MarshalString(NewDNSServers); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_LANHostConfigManagement_1, "DeleteDNSServer", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewDNSServers:
+func (client *LANHostConfigManagement1) GetDNSServers() (NewDNSServers string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewDNSServers string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_LANHostConfigManagement_1, "GetDNSServers", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewDNSServers, err = soap.UnmarshalString(response.NewDNSServers); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Layer3Forwarding1 is a client for UPnP SOAP service with URN "urn:schemas-upnp-org:service:Layer3Forwarding:1". See
+// goupnp.ServiceClient, which contains RootDevice and Service attributes which
+// are provided for informational value.
+type Layer3Forwarding1 struct {
+ goupnp.ServiceClient
+}
+
+// NewLayer3Forwarding1Clients discovers instances of the service on the network,
+// and returns clients to any that are found. errors will contain an error for
+// any devices that replied but which could not be queried, and err will be set
+// if the discovery process failed outright.
+//
+// This is a typical entry calling point into this package.
+func NewLayer3Forwarding1Clients() (clients []*Layer3Forwarding1, errors []error, err error) {
+ var genericClients []goupnp.ServiceClient
+ if genericClients, errors, err = goupnp.NewServiceClients(URN_Layer3Forwarding_1); err != nil {
+ return
+ }
+ clients = make([]*Layer3Forwarding1, len(genericClients))
+ for i := range genericClients {
+ clients[i] = &Layer3Forwarding1{genericClients[i]}
+ }
+ return
+}
+
+// Arguments:
+//
+// * NewDefaultConnectionService:
+//
+//
+func (client *Layer3Forwarding1) SetDefaultConnectionService(NewDefaultConnectionService string) (err error) {
+ // Request structure.
+ request := &struct {
+ NewDefaultConnectionService string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewDefaultConnectionService, err = soap.MarshalString(NewDefaultConnectionService); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_Layer3Forwarding_1, "SetDefaultConnectionService", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewDefaultConnectionService:
+func (client *Layer3Forwarding1) GetDefaultConnectionService() (NewDefaultConnectionService string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewDefaultConnectionService string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_Layer3Forwarding_1, "GetDefaultConnectionService", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewDefaultConnectionService, err = soap.UnmarshalString(response.NewDefaultConnectionService); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// WANCableLinkConfig1 is a client for UPnP SOAP service with URN "urn:schemas-upnp-org:service:WANCableLinkConfig:1". See
+// goupnp.ServiceClient, which contains RootDevice and Service attributes which
+// are provided for informational value.
+type WANCableLinkConfig1 struct {
+ goupnp.ServiceClient
+}
+
+// NewWANCableLinkConfig1Clients discovers instances of the service on the network,
+// and returns clients to any that are found. errors will contain an error for
+// any devices that replied but which could not be queried, and err will be set
+// if the discovery process failed outright.
+//
+// This is a typical entry calling point into this package.
+func NewWANCableLinkConfig1Clients() (clients []*WANCableLinkConfig1, errors []error, err error) {
+ var genericClients []goupnp.ServiceClient
+ if genericClients, errors, err = goupnp.NewServiceClients(URN_WANCableLinkConfig_1); err != nil {
+ return
+ }
+ clients = make([]*WANCableLinkConfig1, len(genericClients))
+ for i := range genericClients {
+ clients[i] = &WANCableLinkConfig1{genericClients[i]}
+ }
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewCableLinkConfigState: allowed values: notReady, dsSyncComplete, usParamAcquired, rangingComplete, ipComplete, todEstablished, paramTransferComplete, registrationComplete, operational, accessDenied
+//
+// * NewLinkType: allowed values: Ethernet
+func (client *WANCableLinkConfig1) GetCableLinkConfigInfo() (NewCableLinkConfigState string, NewLinkType string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewCableLinkConfigState string
+
+ NewLinkType string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANCableLinkConfig_1, "GetCableLinkConfigInfo", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewCableLinkConfigState, err = soap.UnmarshalString(response.NewCableLinkConfigState); err != nil {
+ return
+ }
+ if NewLinkType, err = soap.UnmarshalString(response.NewLinkType); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewDownstreamFrequency:
+func (client *WANCableLinkConfig1) GetDownstreamFrequency() (NewDownstreamFrequency uint32, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewDownstreamFrequency string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANCableLinkConfig_1, "GetDownstreamFrequency", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewDownstreamFrequency, err = soap.UnmarshalUi4(response.NewDownstreamFrequency); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewDownstreamModulation: allowed values: 64QAM, 256QAM
+func (client *WANCableLinkConfig1) GetDownstreamModulation() (NewDownstreamModulation string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewDownstreamModulation string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANCableLinkConfig_1, "GetDownstreamModulation", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewDownstreamModulation, err = soap.UnmarshalString(response.NewDownstreamModulation); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewUpstreamFrequency:
+func (client *WANCableLinkConfig1) GetUpstreamFrequency() (NewUpstreamFrequency uint32, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewUpstreamFrequency string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANCableLinkConfig_1, "GetUpstreamFrequency", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewUpstreamFrequency, err = soap.UnmarshalUi4(response.NewUpstreamFrequency); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewUpstreamModulation: allowed values: QPSK, 16QAM
+func (client *WANCableLinkConfig1) GetUpstreamModulation() (NewUpstreamModulation string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewUpstreamModulation string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANCableLinkConfig_1, "GetUpstreamModulation", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewUpstreamModulation, err = soap.UnmarshalString(response.NewUpstreamModulation); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewUpstreamChannelID:
+func (client *WANCableLinkConfig1) GetUpstreamChannelID() (NewUpstreamChannelID uint32, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewUpstreamChannelID string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANCableLinkConfig_1, "GetUpstreamChannelID", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewUpstreamChannelID, err = soap.UnmarshalUi4(response.NewUpstreamChannelID); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewUpstreamPowerLevel:
+func (client *WANCableLinkConfig1) GetUpstreamPowerLevel() (NewUpstreamPowerLevel uint32, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewUpstreamPowerLevel string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANCableLinkConfig_1, "GetUpstreamPowerLevel", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewUpstreamPowerLevel, err = soap.UnmarshalUi4(response.NewUpstreamPowerLevel); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewBPIEncryptionEnabled:
+func (client *WANCableLinkConfig1) GetBPIEncryptionEnabled() (NewBPIEncryptionEnabled bool, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewBPIEncryptionEnabled string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANCableLinkConfig_1, "GetBPIEncryptionEnabled", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewBPIEncryptionEnabled, err = soap.UnmarshalBoolean(response.NewBPIEncryptionEnabled); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewConfigFile:
+func (client *WANCableLinkConfig1) GetConfigFile() (NewConfigFile string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewConfigFile string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANCableLinkConfig_1, "GetConfigFile", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewConfigFile, err = soap.UnmarshalString(response.NewConfigFile); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewTFTPServer:
+func (client *WANCableLinkConfig1) GetTFTPServer() (NewTFTPServer string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewTFTPServer string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANCableLinkConfig_1, "GetTFTPServer", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewTFTPServer, err = soap.UnmarshalString(response.NewTFTPServer); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// WANCommonInterfaceConfig1 is a client for UPnP SOAP service with URN "urn:schemas-upnp-org:service:WANCommonInterfaceConfig:1". See
+// goupnp.ServiceClient, which contains RootDevice and Service attributes which
+// are provided for informational value.
+type WANCommonInterfaceConfig1 struct {
+ goupnp.ServiceClient
+}
+
+// NewWANCommonInterfaceConfig1Clients discovers instances of the service on the network,
+// and returns clients to any that are found. errors will contain an error for
+// any devices that replied but which could not be queried, and err will be set
+// if the discovery process failed outright.
+//
+// This is a typical entry calling point into this package.
+func NewWANCommonInterfaceConfig1Clients() (clients []*WANCommonInterfaceConfig1, errors []error, err error) {
+ var genericClients []goupnp.ServiceClient
+ if genericClients, errors, err = goupnp.NewServiceClients(URN_WANCommonInterfaceConfig_1); err != nil {
+ return
+ }
+ clients = make([]*WANCommonInterfaceConfig1, len(genericClients))
+ for i := range genericClients {
+ clients[i] = &WANCommonInterfaceConfig1{genericClients[i]}
+ }
+ return
+}
+
+// Arguments:
+//
+// * NewEnabledForInternet:
+//
+//
+func (client *WANCommonInterfaceConfig1) SetEnabledForInternet(NewEnabledForInternet bool) (err error) {
+ // Request structure.
+ request := &struct {
+ NewEnabledForInternet string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewEnabledForInternet, err = soap.MarshalBoolean(NewEnabledForInternet); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANCommonInterfaceConfig_1, "SetEnabledForInternet", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewEnabledForInternet:
+func (client *WANCommonInterfaceConfig1) GetEnabledForInternet() (NewEnabledForInternet bool, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewEnabledForInternet string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANCommonInterfaceConfig_1, "GetEnabledForInternet", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewEnabledForInternet, err = soap.UnmarshalBoolean(response.NewEnabledForInternet); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewWANAccessType: allowed values: DSL, POTS, Cable, Ethernet
+//
+// * NewLayer1UpstreamMaxBitRate:
+//
+// * NewLayer1DownstreamMaxBitRate:
+//
+// * NewPhysicalLinkStatus: allowed values: Up, Down
+func (client *WANCommonInterfaceConfig1) GetCommonLinkProperties() (NewWANAccessType string, NewLayer1UpstreamMaxBitRate uint32, NewLayer1DownstreamMaxBitRate uint32, NewPhysicalLinkStatus string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewWANAccessType string
+
+ NewLayer1UpstreamMaxBitRate string
+
+ NewLayer1DownstreamMaxBitRate string
+
+ NewPhysicalLinkStatus string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANCommonInterfaceConfig_1, "GetCommonLinkProperties", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewWANAccessType, err = soap.UnmarshalString(response.NewWANAccessType); err != nil {
+ return
+ }
+ if NewLayer1UpstreamMaxBitRate, err = soap.UnmarshalUi4(response.NewLayer1UpstreamMaxBitRate); err != nil {
+ return
+ }
+ if NewLayer1DownstreamMaxBitRate, err = soap.UnmarshalUi4(response.NewLayer1DownstreamMaxBitRate); err != nil {
+ return
+ }
+ if NewPhysicalLinkStatus, err = soap.UnmarshalString(response.NewPhysicalLinkStatus); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewWANAccessProvider:
+func (client *WANCommonInterfaceConfig1) GetWANAccessProvider() (NewWANAccessProvider string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewWANAccessProvider string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANCommonInterfaceConfig_1, "GetWANAccessProvider", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewWANAccessProvider, err = soap.UnmarshalString(response.NewWANAccessProvider); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewMaximumActiveConnections: allowed value range: minimum=1, step=1
+func (client *WANCommonInterfaceConfig1) GetMaximumActiveConnections() (NewMaximumActiveConnections uint16, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewMaximumActiveConnections string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANCommonInterfaceConfig_1, "GetMaximumActiveConnections", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewMaximumActiveConnections, err = soap.UnmarshalUi2(response.NewMaximumActiveConnections); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewTotalBytesSent:
+func (client *WANCommonInterfaceConfig1) GetTotalBytesSent() (NewTotalBytesSent uint32, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewTotalBytesSent string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANCommonInterfaceConfig_1, "GetTotalBytesSent", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewTotalBytesSent, err = soap.UnmarshalUi4(response.NewTotalBytesSent); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewTotalBytesReceived:
+func (client *WANCommonInterfaceConfig1) GetTotalBytesReceived() (NewTotalBytesReceived uint32, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewTotalBytesReceived string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANCommonInterfaceConfig_1, "GetTotalBytesReceived", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewTotalBytesReceived, err = soap.UnmarshalUi4(response.NewTotalBytesReceived); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewTotalPacketsSent:
+func (client *WANCommonInterfaceConfig1) GetTotalPacketsSent() (NewTotalPacketsSent uint32, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewTotalPacketsSent string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANCommonInterfaceConfig_1, "GetTotalPacketsSent", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewTotalPacketsSent, err = soap.UnmarshalUi4(response.NewTotalPacketsSent); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewTotalPacketsReceived:
+func (client *WANCommonInterfaceConfig1) GetTotalPacketsReceived() (NewTotalPacketsReceived uint32, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewTotalPacketsReceived string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANCommonInterfaceConfig_1, "GetTotalPacketsReceived", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewTotalPacketsReceived, err = soap.UnmarshalUi4(response.NewTotalPacketsReceived); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewActiveConnectionIndex:
+//
+// Return values:
+//
+// * NewActiveConnDeviceContainer:
+//
+// * NewActiveConnectionServiceID:
+func (client *WANCommonInterfaceConfig1) GetActiveConnection(NewActiveConnectionIndex uint16) (NewActiveConnDeviceContainer string, NewActiveConnectionServiceID string, err error) {
+ // Request structure.
+ request := &struct {
+ NewActiveConnectionIndex string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewActiveConnectionIndex, err = soap.MarshalUi2(NewActiveConnectionIndex); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewActiveConnDeviceContainer string
+
+ NewActiveConnectionServiceID string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANCommonInterfaceConfig_1, "GetActiveConnection", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewActiveConnDeviceContainer, err = soap.UnmarshalString(response.NewActiveConnDeviceContainer); err != nil {
+ return
+ }
+ if NewActiveConnectionServiceID, err = soap.UnmarshalString(response.NewActiveConnectionServiceID); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// WANDSLLinkConfig1 is a client for UPnP SOAP service with URN "urn:schemas-upnp-org:service:WANDSLLinkConfig:1". See
+// goupnp.ServiceClient, which contains RootDevice and Service attributes which
+// are provided for informational value.
+type WANDSLLinkConfig1 struct {
+ goupnp.ServiceClient
+}
+
+// NewWANDSLLinkConfig1Clients discovers instances of the service on the network,
+// and returns clients to any that are found. errors will contain an error for
+// any devices that replied but which could not be queried, and err will be set
+// if the discovery process failed outright.
+//
+// This is a typical entry calling point into this package.
+func NewWANDSLLinkConfig1Clients() (clients []*WANDSLLinkConfig1, errors []error, err error) {
+ var genericClients []goupnp.ServiceClient
+ if genericClients, errors, err = goupnp.NewServiceClients(URN_WANDSLLinkConfig_1); err != nil {
+ return
+ }
+ clients = make([]*WANDSLLinkConfig1, len(genericClients))
+ for i := range genericClients {
+ clients[i] = &WANDSLLinkConfig1{genericClients[i]}
+ }
+ return
+}
+
+// Arguments:
+//
+// * NewLinkType:
+//
+//
+func (client *WANDSLLinkConfig1) SetDSLLinkType(NewLinkType string) (err error) {
+ // Request structure.
+ request := &struct {
+ NewLinkType string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewLinkType, err = soap.MarshalString(NewLinkType); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANDSLLinkConfig_1, "SetDSLLinkType", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewLinkType:
+//
+// * NewLinkStatus: allowed values: Up, Down
+func (client *WANDSLLinkConfig1) GetDSLLinkInfo() (NewLinkType string, NewLinkStatus string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewLinkType string
+
+ NewLinkStatus string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANDSLLinkConfig_1, "GetDSLLinkInfo", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewLinkType, err = soap.UnmarshalString(response.NewLinkType); err != nil {
+ return
+ }
+ if NewLinkStatus, err = soap.UnmarshalString(response.NewLinkStatus); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewAutoConfig:
+func (client *WANDSLLinkConfig1) GetAutoConfig() (NewAutoConfig bool, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewAutoConfig string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANDSLLinkConfig_1, "GetAutoConfig", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewAutoConfig, err = soap.UnmarshalBoolean(response.NewAutoConfig); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewModulationType:
+func (client *WANDSLLinkConfig1) GetModulationType() (NewModulationType string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewModulationType string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANDSLLinkConfig_1, "GetModulationType", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewModulationType, err = soap.UnmarshalString(response.NewModulationType); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewDestinationAddress:
+//
+//
+func (client *WANDSLLinkConfig1) SetDestinationAddress(NewDestinationAddress string) (err error) {
+ // Request structure.
+ request := &struct {
+ NewDestinationAddress string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewDestinationAddress, err = soap.MarshalString(NewDestinationAddress); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANDSLLinkConfig_1, "SetDestinationAddress", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewDestinationAddress:
+func (client *WANDSLLinkConfig1) GetDestinationAddress() (NewDestinationAddress string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewDestinationAddress string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANDSLLinkConfig_1, "GetDestinationAddress", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewDestinationAddress, err = soap.UnmarshalString(response.NewDestinationAddress); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewATMEncapsulation:
+//
+//
+func (client *WANDSLLinkConfig1) SetATMEncapsulation(NewATMEncapsulation string) (err error) {
+ // Request structure.
+ request := &struct {
+ NewATMEncapsulation string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewATMEncapsulation, err = soap.MarshalString(NewATMEncapsulation); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANDSLLinkConfig_1, "SetATMEncapsulation", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewATMEncapsulation:
+func (client *WANDSLLinkConfig1) GetATMEncapsulation() (NewATMEncapsulation string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewATMEncapsulation string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANDSLLinkConfig_1, "GetATMEncapsulation", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewATMEncapsulation, err = soap.UnmarshalString(response.NewATMEncapsulation); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewFCSPreserved:
+//
+//
+func (client *WANDSLLinkConfig1) SetFCSPreserved(NewFCSPreserved bool) (err error) {
+ // Request structure.
+ request := &struct {
+ NewFCSPreserved string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewFCSPreserved, err = soap.MarshalBoolean(NewFCSPreserved); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANDSLLinkConfig_1, "SetFCSPreserved", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewFCSPreserved:
+func (client *WANDSLLinkConfig1) GetFCSPreserved() (NewFCSPreserved bool, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewFCSPreserved string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANDSLLinkConfig_1, "GetFCSPreserved", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewFCSPreserved, err = soap.UnmarshalBoolean(response.NewFCSPreserved); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// WANEthernetLinkConfig1 is a client for UPnP SOAP service with URN "urn:schemas-upnp-org:service:WANEthernetLinkConfig:1". See
+// goupnp.ServiceClient, which contains RootDevice and Service attributes which
+// are provided for informational value.
+type WANEthernetLinkConfig1 struct {
+ goupnp.ServiceClient
+}
+
+// NewWANEthernetLinkConfig1Clients discovers instances of the service on the network,
+// and returns clients to any that are found. errors will contain an error for
+// any devices that replied but which could not be queried, and err will be set
+// if the discovery process failed outright.
+//
+// This is a typical entry calling point into this package.
+func NewWANEthernetLinkConfig1Clients() (clients []*WANEthernetLinkConfig1, errors []error, err error) {
+ var genericClients []goupnp.ServiceClient
+ if genericClients, errors, err = goupnp.NewServiceClients(URN_WANEthernetLinkConfig_1); err != nil {
+ return
+ }
+ clients = make([]*WANEthernetLinkConfig1, len(genericClients))
+ for i := range genericClients {
+ clients[i] = &WANEthernetLinkConfig1{genericClients[i]}
+ }
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewEthernetLinkStatus: allowed values: Up, Down
+func (client *WANEthernetLinkConfig1) GetEthernetLinkStatus() (NewEthernetLinkStatus string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewEthernetLinkStatus string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANEthernetLinkConfig_1, "GetEthernetLinkStatus", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewEthernetLinkStatus, err = soap.UnmarshalString(response.NewEthernetLinkStatus); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// WANIPConnection1 is a client for UPnP SOAP service with URN "urn:schemas-upnp-org:service:WANIPConnection:1". See
+// goupnp.ServiceClient, which contains RootDevice and Service attributes which
+// are provided for informational value.
+type WANIPConnection1 struct {
+ goupnp.ServiceClient
+}
+
+// NewWANIPConnection1Clients discovers instances of the service on the network,
+// and returns clients to any that are found. errors will contain an error for
+// any devices that replied but which could not be queried, and err will be set
+// if the discovery process failed outright.
+//
+// This is a typical entry calling point into this package.
+func NewWANIPConnection1Clients() (clients []*WANIPConnection1, errors []error, err error) {
+ var genericClients []goupnp.ServiceClient
+ if genericClients, errors, err = goupnp.NewServiceClients(URN_WANIPConnection_1); err != nil {
+ return
+ }
+ clients = make([]*WANIPConnection1, len(genericClients))
+ for i := range genericClients {
+ clients[i] = &WANIPConnection1{genericClients[i]}
+ }
+ return
+}
+
+// Arguments:
+//
+// * NewConnectionType:
+//
+//
+func (client *WANIPConnection1) SetConnectionType(NewConnectionType string) (err error) {
+ // Request structure.
+ request := &struct {
+ NewConnectionType string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewConnectionType, err = soap.MarshalString(NewConnectionType); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPConnection_1, "SetConnectionType", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewConnectionType:
+//
+// * NewPossibleConnectionTypes: allowed values: Unconfigured, IP_Routed, IP_Bridged
+func (client *WANIPConnection1) GetConnectionTypeInfo() (NewConnectionType string, NewPossibleConnectionTypes string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewConnectionType string
+
+ NewPossibleConnectionTypes string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPConnection_1, "GetConnectionTypeInfo", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewConnectionType, err = soap.UnmarshalString(response.NewConnectionType); err != nil {
+ return
+ }
+ if NewPossibleConnectionTypes, err = soap.UnmarshalString(response.NewPossibleConnectionTypes); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+//
+func (client *WANIPConnection1) RequestConnection() (err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPConnection_1, "RequestConnection", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+//
+func (client *WANIPConnection1) RequestTermination() (err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPConnection_1, "RequestTermination", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+//
+func (client *WANIPConnection1) ForceTermination() (err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPConnection_1, "ForceTermination", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewAutoDisconnectTime:
+//
+//
+func (client *WANIPConnection1) SetAutoDisconnectTime(NewAutoDisconnectTime uint32) (err error) {
+ // Request structure.
+ request := &struct {
+ NewAutoDisconnectTime string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewAutoDisconnectTime, err = soap.MarshalUi4(NewAutoDisconnectTime); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPConnection_1, "SetAutoDisconnectTime", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewIdleDisconnectTime:
+//
+//
+func (client *WANIPConnection1) SetIdleDisconnectTime(NewIdleDisconnectTime uint32) (err error) {
+ // Request structure.
+ request := &struct {
+ NewIdleDisconnectTime string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewIdleDisconnectTime, err = soap.MarshalUi4(NewIdleDisconnectTime); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPConnection_1, "SetIdleDisconnectTime", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewWarnDisconnectDelay:
+//
+//
+func (client *WANIPConnection1) SetWarnDisconnectDelay(NewWarnDisconnectDelay uint32) (err error) {
+ // Request structure.
+ request := &struct {
+ NewWarnDisconnectDelay string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewWarnDisconnectDelay, err = soap.MarshalUi4(NewWarnDisconnectDelay); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPConnection_1, "SetWarnDisconnectDelay", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewConnectionStatus: allowed values: Unconfigured, Connected, Disconnected
+//
+// * NewLastConnectionError: allowed values: ERROR_NONE
+//
+// * NewUptime:
+func (client *WANIPConnection1) GetStatusInfo() (NewConnectionStatus string, NewLastConnectionError string, NewUptime uint32, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewConnectionStatus string
+
+ NewLastConnectionError string
+
+ NewUptime string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPConnection_1, "GetStatusInfo", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewConnectionStatus, err = soap.UnmarshalString(response.NewConnectionStatus); err != nil {
+ return
+ }
+ if NewLastConnectionError, err = soap.UnmarshalString(response.NewLastConnectionError); err != nil {
+ return
+ }
+ if NewUptime, err = soap.UnmarshalUi4(response.NewUptime); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewAutoDisconnectTime:
+func (client *WANIPConnection1) GetAutoDisconnectTime() (NewAutoDisconnectTime uint32, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewAutoDisconnectTime string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPConnection_1, "GetAutoDisconnectTime", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewAutoDisconnectTime, err = soap.UnmarshalUi4(response.NewAutoDisconnectTime); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewIdleDisconnectTime:
+func (client *WANIPConnection1) GetIdleDisconnectTime() (NewIdleDisconnectTime uint32, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewIdleDisconnectTime string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPConnection_1, "GetIdleDisconnectTime", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewIdleDisconnectTime, err = soap.UnmarshalUi4(response.NewIdleDisconnectTime); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewWarnDisconnectDelay:
+func (client *WANIPConnection1) GetWarnDisconnectDelay() (NewWarnDisconnectDelay uint32, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewWarnDisconnectDelay string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPConnection_1, "GetWarnDisconnectDelay", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewWarnDisconnectDelay, err = soap.UnmarshalUi4(response.NewWarnDisconnectDelay); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewRSIPAvailable:
+//
+// * NewNATEnabled:
+func (client *WANIPConnection1) GetNATRSIPStatus() (NewRSIPAvailable bool, NewNATEnabled bool, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewRSIPAvailable string
+
+ NewNATEnabled string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPConnection_1, "GetNATRSIPStatus", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewRSIPAvailable, err = soap.UnmarshalBoolean(response.NewRSIPAvailable); err != nil {
+ return
+ }
+ if NewNATEnabled, err = soap.UnmarshalBoolean(response.NewNATEnabled); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewPortMappingIndex:
+//
+// Return values:
+//
+// * NewRemoteHost:
+//
+// * NewExternalPort:
+//
+// * NewProtocol: allowed values: TCP, UDP
+//
+// * NewInternalPort:
+//
+// * NewInternalClient:
+//
+// * NewEnabled:
+//
+// * NewPortMappingDescription:
+//
+// * NewLeaseDuration:
+func (client *WANIPConnection1) GetGenericPortMappingEntry(NewPortMappingIndex uint16) (NewRemoteHost string, NewExternalPort uint16, NewProtocol string, NewInternalPort uint16, NewInternalClient string, NewEnabled bool, NewPortMappingDescription string, NewLeaseDuration uint32, err error) {
+ // Request structure.
+ request := &struct {
+ NewPortMappingIndex string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewPortMappingIndex, err = soap.MarshalUi2(NewPortMappingIndex); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewRemoteHost string
+
+ NewExternalPort string
+
+ NewProtocol string
+
+ NewInternalPort string
+
+ NewInternalClient string
+
+ NewEnabled string
+
+ NewPortMappingDescription string
+
+ NewLeaseDuration string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPConnection_1, "GetGenericPortMappingEntry", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewRemoteHost, err = soap.UnmarshalString(response.NewRemoteHost); err != nil {
+ return
+ }
+ if NewExternalPort, err = soap.UnmarshalUi2(response.NewExternalPort); err != nil {
+ return
+ }
+ if NewProtocol, err = soap.UnmarshalString(response.NewProtocol); err != nil {
+ return
+ }
+ if NewInternalPort, err = soap.UnmarshalUi2(response.NewInternalPort); err != nil {
+ return
+ }
+ if NewInternalClient, err = soap.UnmarshalString(response.NewInternalClient); err != nil {
+ return
+ }
+ if NewEnabled, err = soap.UnmarshalBoolean(response.NewEnabled); err != nil {
+ return
+ }
+ if NewPortMappingDescription, err = soap.UnmarshalString(response.NewPortMappingDescription); err != nil {
+ return
+ }
+ if NewLeaseDuration, err = soap.UnmarshalUi4(response.NewLeaseDuration); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewRemoteHost:
+//
+// * NewExternalPort:
+//
+// * NewProtocol: allowed values: TCP, UDP
+//
+// Return values:
+//
+// * NewInternalPort:
+//
+// * NewInternalClient:
+//
+// * NewEnabled:
+//
+// * NewPortMappingDescription:
+//
+// * NewLeaseDuration:
+func (client *WANIPConnection1) GetSpecificPortMappingEntry(NewRemoteHost string, NewExternalPort uint16, NewProtocol string) (NewInternalPort uint16, NewInternalClient string, NewEnabled bool, NewPortMappingDescription string, NewLeaseDuration uint32, err error) {
+ // Request structure.
+ request := &struct {
+ NewRemoteHost string
+
+ NewExternalPort string
+
+ NewProtocol string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewRemoteHost, err = soap.MarshalString(NewRemoteHost); err != nil {
+ return
+ }
+ if request.NewExternalPort, err = soap.MarshalUi2(NewExternalPort); err != nil {
+ return
+ }
+ if request.NewProtocol, err = soap.MarshalString(NewProtocol); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewInternalPort string
+
+ NewInternalClient string
+
+ NewEnabled string
+
+ NewPortMappingDescription string
+
+ NewLeaseDuration string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPConnection_1, "GetSpecificPortMappingEntry", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewInternalPort, err = soap.UnmarshalUi2(response.NewInternalPort); err != nil {
+ return
+ }
+ if NewInternalClient, err = soap.UnmarshalString(response.NewInternalClient); err != nil {
+ return
+ }
+ if NewEnabled, err = soap.UnmarshalBoolean(response.NewEnabled); err != nil {
+ return
+ }
+ if NewPortMappingDescription, err = soap.UnmarshalString(response.NewPortMappingDescription); err != nil {
+ return
+ }
+ if NewLeaseDuration, err = soap.UnmarshalUi4(response.NewLeaseDuration); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewRemoteHost:
+//
+// * NewExternalPort:
+//
+// * NewProtocol: allowed values: TCP, UDP
+//
+// * NewInternalPort:
+//
+// * NewInternalClient:
+//
+// * NewEnabled:
+//
+// * NewPortMappingDescription:
+//
+// * NewLeaseDuration:
+//
+//
+func (client *WANIPConnection1) AddPortMapping(NewRemoteHost string, NewExternalPort uint16, NewProtocol string, NewInternalPort uint16, NewInternalClient string, NewEnabled bool, NewPortMappingDescription string, NewLeaseDuration uint32) (err error) {
+ // Request structure.
+ request := &struct {
+ NewRemoteHost string
+
+ NewExternalPort string
+
+ NewProtocol string
+
+ NewInternalPort string
+
+ NewInternalClient string
+
+ NewEnabled string
+
+ NewPortMappingDescription string
+
+ NewLeaseDuration string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewRemoteHost, err = soap.MarshalString(NewRemoteHost); err != nil {
+ return
+ }
+ if request.NewExternalPort, err = soap.MarshalUi2(NewExternalPort); err != nil {
+ return
+ }
+ if request.NewProtocol, err = soap.MarshalString(NewProtocol); err != nil {
+ return
+ }
+ if request.NewInternalPort, err = soap.MarshalUi2(NewInternalPort); err != nil {
+ return
+ }
+ if request.NewInternalClient, err = soap.MarshalString(NewInternalClient); err != nil {
+ return
+ }
+ if request.NewEnabled, err = soap.MarshalBoolean(NewEnabled); err != nil {
+ return
+ }
+ if request.NewPortMappingDescription, err = soap.MarshalString(NewPortMappingDescription); err != nil {
+ return
+ }
+ if request.NewLeaseDuration, err = soap.MarshalUi4(NewLeaseDuration); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPConnection_1, "AddPortMapping", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewRemoteHost:
+//
+// * NewExternalPort:
+//
+// * NewProtocol: allowed values: TCP, UDP
+//
+//
+func (client *WANIPConnection1) DeletePortMapping(NewRemoteHost string, NewExternalPort uint16, NewProtocol string) (err error) {
+ // Request structure.
+ request := &struct {
+ NewRemoteHost string
+
+ NewExternalPort string
+
+ NewProtocol string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewRemoteHost, err = soap.MarshalString(NewRemoteHost); err != nil {
+ return
+ }
+ if request.NewExternalPort, err = soap.MarshalUi2(NewExternalPort); err != nil {
+ return
+ }
+ if request.NewProtocol, err = soap.MarshalString(NewProtocol); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPConnection_1, "DeletePortMapping", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewExternalIPAddress:
+func (client *WANIPConnection1) GetExternalIPAddress() (NewExternalIPAddress string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewExternalIPAddress string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPConnection_1, "GetExternalIPAddress", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewExternalIPAddress, err = soap.UnmarshalString(response.NewExternalIPAddress); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// WANPOTSLinkConfig1 is a client for UPnP SOAP service with URN "urn:schemas-upnp-org:service:WANPOTSLinkConfig:1". See
+// goupnp.ServiceClient, which contains RootDevice and Service attributes which
+// are provided for informational value.
+type WANPOTSLinkConfig1 struct {
+ goupnp.ServiceClient
+}
+
+// NewWANPOTSLinkConfig1Clients discovers instances of the service on the network,
+// and returns clients to any that are found. errors will contain an error for
+// any devices that replied but which could not be queried, and err will be set
+// if the discovery process failed outright.
+//
+// This is a typical entry calling point into this package.
+func NewWANPOTSLinkConfig1Clients() (clients []*WANPOTSLinkConfig1, errors []error, err error) {
+ var genericClients []goupnp.ServiceClient
+ if genericClients, errors, err = goupnp.NewServiceClients(URN_WANPOTSLinkConfig_1); err != nil {
+ return
+ }
+ clients = make([]*WANPOTSLinkConfig1, len(genericClients))
+ for i := range genericClients {
+ clients[i] = &WANPOTSLinkConfig1{genericClients[i]}
+ }
+ return
+}
+
+// Arguments:
+//
+// * NewISPPhoneNumber:
+//
+// * NewISPInfo:
+//
+// * NewLinkType: allowed values: PPP_Dialup
+//
+//
+func (client *WANPOTSLinkConfig1) SetISPInfo(NewISPPhoneNumber string, NewISPInfo string, NewLinkType string) (err error) {
+ // Request structure.
+ request := &struct {
+ NewISPPhoneNumber string
+
+ NewISPInfo string
+
+ NewLinkType string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewISPPhoneNumber, err = soap.MarshalString(NewISPPhoneNumber); err != nil {
+ return
+ }
+ if request.NewISPInfo, err = soap.MarshalString(NewISPInfo); err != nil {
+ return
+ }
+ if request.NewLinkType, err = soap.MarshalString(NewLinkType); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPOTSLinkConfig_1, "SetISPInfo", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewNumberOfRetries:
+//
+// * NewDelayBetweenRetries:
+//
+//
+func (client *WANPOTSLinkConfig1) SetCallRetryInfo(NewNumberOfRetries uint32, NewDelayBetweenRetries uint32) (err error) {
+ // Request structure.
+ request := &struct {
+ NewNumberOfRetries string
+
+ NewDelayBetweenRetries string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewNumberOfRetries, err = soap.MarshalUi4(NewNumberOfRetries); err != nil {
+ return
+ }
+ if request.NewDelayBetweenRetries, err = soap.MarshalUi4(NewDelayBetweenRetries); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPOTSLinkConfig_1, "SetCallRetryInfo", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewISPPhoneNumber:
+//
+// * NewISPInfo:
+//
+// * NewLinkType: allowed values: PPP_Dialup
+func (client *WANPOTSLinkConfig1) GetISPInfo() (NewISPPhoneNumber string, NewISPInfo string, NewLinkType string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewISPPhoneNumber string
+
+ NewISPInfo string
+
+ NewLinkType string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPOTSLinkConfig_1, "GetISPInfo", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewISPPhoneNumber, err = soap.UnmarshalString(response.NewISPPhoneNumber); err != nil {
+ return
+ }
+ if NewISPInfo, err = soap.UnmarshalString(response.NewISPInfo); err != nil {
+ return
+ }
+ if NewLinkType, err = soap.UnmarshalString(response.NewLinkType); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewNumberOfRetries:
+//
+// * NewDelayBetweenRetries:
+func (client *WANPOTSLinkConfig1) GetCallRetryInfo() (NewNumberOfRetries uint32, NewDelayBetweenRetries uint32, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewNumberOfRetries string
+
+ NewDelayBetweenRetries string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPOTSLinkConfig_1, "GetCallRetryInfo", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewNumberOfRetries, err = soap.UnmarshalUi4(response.NewNumberOfRetries); err != nil {
+ return
+ }
+ if NewDelayBetweenRetries, err = soap.UnmarshalUi4(response.NewDelayBetweenRetries); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewFclass:
+func (client *WANPOTSLinkConfig1) GetFclass() (NewFclass string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewFclass string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPOTSLinkConfig_1, "GetFclass", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewFclass, err = soap.UnmarshalString(response.NewFclass); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewDataModulationSupported:
+func (client *WANPOTSLinkConfig1) GetDataModulationSupported() (NewDataModulationSupported string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewDataModulationSupported string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPOTSLinkConfig_1, "GetDataModulationSupported", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewDataModulationSupported, err = soap.UnmarshalString(response.NewDataModulationSupported); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewDataProtocol:
+func (client *WANPOTSLinkConfig1) GetDataProtocol() (NewDataProtocol string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewDataProtocol string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPOTSLinkConfig_1, "GetDataProtocol", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewDataProtocol, err = soap.UnmarshalString(response.NewDataProtocol); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewDataCompression:
+func (client *WANPOTSLinkConfig1) GetDataCompression() (NewDataCompression string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewDataCompression string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPOTSLinkConfig_1, "GetDataCompression", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewDataCompression, err = soap.UnmarshalString(response.NewDataCompression); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewPlusVTRCommandSupported:
+func (client *WANPOTSLinkConfig1) GetPlusVTRCommandSupported() (NewPlusVTRCommandSupported bool, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewPlusVTRCommandSupported string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPOTSLinkConfig_1, "GetPlusVTRCommandSupported", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewPlusVTRCommandSupported, err = soap.UnmarshalBoolean(response.NewPlusVTRCommandSupported); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// WANPPPConnection1 is a client for UPnP SOAP service with URN "urn:schemas-upnp-org:service:WANPPPConnection:1". See
+// goupnp.ServiceClient, which contains RootDevice and Service attributes which
+// are provided for informational value.
+type WANPPPConnection1 struct {
+ goupnp.ServiceClient
+}
+
+// NewWANPPPConnection1Clients discovers instances of the service on the network,
+// and returns clients to any that are found. errors will contain an error for
+// any devices that replied but which could not be queried, and err will be set
+// if the discovery process failed outright.
+//
+// This is a typical entry calling point into this package.
+func NewWANPPPConnection1Clients() (clients []*WANPPPConnection1, errors []error, err error) {
+ var genericClients []goupnp.ServiceClient
+ if genericClients, errors, err = goupnp.NewServiceClients(URN_WANPPPConnection_1); err != nil {
+ return
+ }
+ clients = make([]*WANPPPConnection1, len(genericClients))
+ for i := range genericClients {
+ clients[i] = &WANPPPConnection1{genericClients[i]}
+ }
+ return
+}
+
+// Arguments:
+//
+// * NewConnectionType:
+//
+//
+func (client *WANPPPConnection1) SetConnectionType(NewConnectionType string) (err error) {
+ // Request structure.
+ request := &struct {
+ NewConnectionType string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewConnectionType, err = soap.MarshalString(NewConnectionType); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPPPConnection_1, "SetConnectionType", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewConnectionType:
+//
+// * NewPossibleConnectionTypes: allowed values: Unconfigured, IP_Routed, DHCP_Spoofed, PPPoE_Bridged, PPTP_Relay, L2TP_Relay, PPPoE_Relay
+func (client *WANPPPConnection1) GetConnectionTypeInfo() (NewConnectionType string, NewPossibleConnectionTypes string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewConnectionType string
+
+ NewPossibleConnectionTypes string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPPPConnection_1, "GetConnectionTypeInfo", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewConnectionType, err = soap.UnmarshalString(response.NewConnectionType); err != nil {
+ return
+ }
+ if NewPossibleConnectionTypes, err = soap.UnmarshalString(response.NewPossibleConnectionTypes); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewUserName:
+//
+// * NewPassword:
+//
+//
+func (client *WANPPPConnection1) ConfigureConnection(NewUserName string, NewPassword string) (err error) {
+ // Request structure.
+ request := &struct {
+ NewUserName string
+
+ NewPassword string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewUserName, err = soap.MarshalString(NewUserName); err != nil {
+ return
+ }
+ if request.NewPassword, err = soap.MarshalString(NewPassword); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPPPConnection_1, "ConfigureConnection", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+//
+func (client *WANPPPConnection1) RequestConnection() (err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPPPConnection_1, "RequestConnection", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+//
+func (client *WANPPPConnection1) RequestTermination() (err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPPPConnection_1, "RequestTermination", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+//
+func (client *WANPPPConnection1) ForceTermination() (err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPPPConnection_1, "ForceTermination", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewAutoDisconnectTime:
+//
+//
+func (client *WANPPPConnection1) SetAutoDisconnectTime(NewAutoDisconnectTime uint32) (err error) {
+ // Request structure.
+ request := &struct {
+ NewAutoDisconnectTime string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewAutoDisconnectTime, err = soap.MarshalUi4(NewAutoDisconnectTime); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPPPConnection_1, "SetAutoDisconnectTime", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewIdleDisconnectTime:
+//
+//
+func (client *WANPPPConnection1) SetIdleDisconnectTime(NewIdleDisconnectTime uint32) (err error) {
+ // Request structure.
+ request := &struct {
+ NewIdleDisconnectTime string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewIdleDisconnectTime, err = soap.MarshalUi4(NewIdleDisconnectTime); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPPPConnection_1, "SetIdleDisconnectTime", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewWarnDisconnectDelay:
+//
+//
+func (client *WANPPPConnection1) SetWarnDisconnectDelay(NewWarnDisconnectDelay uint32) (err error) {
+ // Request structure.
+ request := &struct {
+ NewWarnDisconnectDelay string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewWarnDisconnectDelay, err = soap.MarshalUi4(NewWarnDisconnectDelay); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPPPConnection_1, "SetWarnDisconnectDelay", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewConnectionStatus: allowed values: Unconfigured, Connected, Disconnected
+//
+// * NewLastConnectionError: allowed values: ERROR_NONE
+//
+// * NewUptime:
+func (client *WANPPPConnection1) GetStatusInfo() (NewConnectionStatus string, NewLastConnectionError string, NewUptime uint32, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewConnectionStatus string
+
+ NewLastConnectionError string
+
+ NewUptime string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPPPConnection_1, "GetStatusInfo", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewConnectionStatus, err = soap.UnmarshalString(response.NewConnectionStatus); err != nil {
+ return
+ }
+ if NewLastConnectionError, err = soap.UnmarshalString(response.NewLastConnectionError); err != nil {
+ return
+ }
+ if NewUptime, err = soap.UnmarshalUi4(response.NewUptime); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewUpstreamMaxBitRate:
+//
+// * NewDownstreamMaxBitRate:
+func (client *WANPPPConnection1) GetLinkLayerMaxBitRates() (NewUpstreamMaxBitRate uint32, NewDownstreamMaxBitRate uint32, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewUpstreamMaxBitRate string
+
+ NewDownstreamMaxBitRate string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPPPConnection_1, "GetLinkLayerMaxBitRates", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewUpstreamMaxBitRate, err = soap.UnmarshalUi4(response.NewUpstreamMaxBitRate); err != nil {
+ return
+ }
+ if NewDownstreamMaxBitRate, err = soap.UnmarshalUi4(response.NewDownstreamMaxBitRate); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewPPPEncryptionProtocol:
+func (client *WANPPPConnection1) GetPPPEncryptionProtocol() (NewPPPEncryptionProtocol string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewPPPEncryptionProtocol string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPPPConnection_1, "GetPPPEncryptionProtocol", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewPPPEncryptionProtocol, err = soap.UnmarshalString(response.NewPPPEncryptionProtocol); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewPPPCompressionProtocol:
+func (client *WANPPPConnection1) GetPPPCompressionProtocol() (NewPPPCompressionProtocol string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewPPPCompressionProtocol string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPPPConnection_1, "GetPPPCompressionProtocol", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewPPPCompressionProtocol, err = soap.UnmarshalString(response.NewPPPCompressionProtocol); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewPPPAuthenticationProtocol:
+func (client *WANPPPConnection1) GetPPPAuthenticationProtocol() (NewPPPAuthenticationProtocol string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewPPPAuthenticationProtocol string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPPPConnection_1, "GetPPPAuthenticationProtocol", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewPPPAuthenticationProtocol, err = soap.UnmarshalString(response.NewPPPAuthenticationProtocol); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewUserName:
+func (client *WANPPPConnection1) GetUserName() (NewUserName string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewUserName string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPPPConnection_1, "GetUserName", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewUserName, err = soap.UnmarshalString(response.NewUserName); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewPassword:
+func (client *WANPPPConnection1) GetPassword() (NewPassword string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewPassword string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPPPConnection_1, "GetPassword", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewPassword, err = soap.UnmarshalString(response.NewPassword); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewAutoDisconnectTime:
+func (client *WANPPPConnection1) GetAutoDisconnectTime() (NewAutoDisconnectTime uint32, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewAutoDisconnectTime string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPPPConnection_1, "GetAutoDisconnectTime", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewAutoDisconnectTime, err = soap.UnmarshalUi4(response.NewAutoDisconnectTime); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewIdleDisconnectTime:
+func (client *WANPPPConnection1) GetIdleDisconnectTime() (NewIdleDisconnectTime uint32, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewIdleDisconnectTime string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPPPConnection_1, "GetIdleDisconnectTime", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewIdleDisconnectTime, err = soap.UnmarshalUi4(response.NewIdleDisconnectTime); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewWarnDisconnectDelay:
+func (client *WANPPPConnection1) GetWarnDisconnectDelay() (NewWarnDisconnectDelay uint32, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewWarnDisconnectDelay string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPPPConnection_1, "GetWarnDisconnectDelay", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewWarnDisconnectDelay, err = soap.UnmarshalUi4(response.NewWarnDisconnectDelay); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewRSIPAvailable:
+//
+// * NewNATEnabled:
+func (client *WANPPPConnection1) GetNATRSIPStatus() (NewRSIPAvailable bool, NewNATEnabled bool, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewRSIPAvailable string
+
+ NewNATEnabled string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPPPConnection_1, "GetNATRSIPStatus", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewRSIPAvailable, err = soap.UnmarshalBoolean(response.NewRSIPAvailable); err != nil {
+ return
+ }
+ if NewNATEnabled, err = soap.UnmarshalBoolean(response.NewNATEnabled); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewPortMappingIndex:
+//
+// Return values:
+//
+// * NewRemoteHost:
+//
+// * NewExternalPort:
+//
+// * NewProtocol: allowed values: TCP, UDP
+//
+// * NewInternalPort:
+//
+// * NewInternalClient:
+//
+// * NewEnabled:
+//
+// * NewPortMappingDescription:
+//
+// * NewLeaseDuration:
+func (client *WANPPPConnection1) GetGenericPortMappingEntry(NewPortMappingIndex uint16) (NewRemoteHost string, NewExternalPort uint16, NewProtocol string, NewInternalPort uint16, NewInternalClient string, NewEnabled bool, NewPortMappingDescription string, NewLeaseDuration uint32, err error) {
+ // Request structure.
+ request := &struct {
+ NewPortMappingIndex string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewPortMappingIndex, err = soap.MarshalUi2(NewPortMappingIndex); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewRemoteHost string
+
+ NewExternalPort string
+
+ NewProtocol string
+
+ NewInternalPort string
+
+ NewInternalClient string
+
+ NewEnabled string
+
+ NewPortMappingDescription string
+
+ NewLeaseDuration string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPPPConnection_1, "GetGenericPortMappingEntry", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewRemoteHost, err = soap.UnmarshalString(response.NewRemoteHost); err != nil {
+ return
+ }
+ if NewExternalPort, err = soap.UnmarshalUi2(response.NewExternalPort); err != nil {
+ return
+ }
+ if NewProtocol, err = soap.UnmarshalString(response.NewProtocol); err != nil {
+ return
+ }
+ if NewInternalPort, err = soap.UnmarshalUi2(response.NewInternalPort); err != nil {
+ return
+ }
+ if NewInternalClient, err = soap.UnmarshalString(response.NewInternalClient); err != nil {
+ return
+ }
+ if NewEnabled, err = soap.UnmarshalBoolean(response.NewEnabled); err != nil {
+ return
+ }
+ if NewPortMappingDescription, err = soap.UnmarshalString(response.NewPortMappingDescription); err != nil {
+ return
+ }
+ if NewLeaseDuration, err = soap.UnmarshalUi4(response.NewLeaseDuration); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewRemoteHost:
+//
+// * NewExternalPort:
+//
+// * NewProtocol: allowed values: TCP, UDP
+//
+// Return values:
+//
+// * NewInternalPort:
+//
+// * NewInternalClient:
+//
+// * NewEnabled:
+//
+// * NewPortMappingDescription:
+//
+// * NewLeaseDuration:
+func (client *WANPPPConnection1) GetSpecificPortMappingEntry(NewRemoteHost string, NewExternalPort uint16, NewProtocol string) (NewInternalPort uint16, NewInternalClient string, NewEnabled bool, NewPortMappingDescription string, NewLeaseDuration uint32, err error) {
+ // Request structure.
+ request := &struct {
+ NewRemoteHost string
+
+ NewExternalPort string
+
+ NewProtocol string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewRemoteHost, err = soap.MarshalString(NewRemoteHost); err != nil {
+ return
+ }
+ if request.NewExternalPort, err = soap.MarshalUi2(NewExternalPort); err != nil {
+ return
+ }
+ if request.NewProtocol, err = soap.MarshalString(NewProtocol); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewInternalPort string
+
+ NewInternalClient string
+
+ NewEnabled string
+
+ NewPortMappingDescription string
+
+ NewLeaseDuration string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPPPConnection_1, "GetSpecificPortMappingEntry", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewInternalPort, err = soap.UnmarshalUi2(response.NewInternalPort); err != nil {
+ return
+ }
+ if NewInternalClient, err = soap.UnmarshalString(response.NewInternalClient); err != nil {
+ return
+ }
+ if NewEnabled, err = soap.UnmarshalBoolean(response.NewEnabled); err != nil {
+ return
+ }
+ if NewPortMappingDescription, err = soap.UnmarshalString(response.NewPortMappingDescription); err != nil {
+ return
+ }
+ if NewLeaseDuration, err = soap.UnmarshalUi4(response.NewLeaseDuration); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewRemoteHost:
+//
+// * NewExternalPort:
+//
+// * NewProtocol: allowed values: TCP, UDP
+//
+// * NewInternalPort:
+//
+// * NewInternalClient:
+//
+// * NewEnabled:
+//
+// * NewPortMappingDescription:
+//
+// * NewLeaseDuration:
+//
+//
+func (client *WANPPPConnection1) AddPortMapping(NewRemoteHost string, NewExternalPort uint16, NewProtocol string, NewInternalPort uint16, NewInternalClient string, NewEnabled bool, NewPortMappingDescription string, NewLeaseDuration uint32) (err error) {
+ // Request structure.
+ request := &struct {
+ NewRemoteHost string
+
+ NewExternalPort string
+
+ NewProtocol string
+
+ NewInternalPort string
+
+ NewInternalClient string
+
+ NewEnabled string
+
+ NewPortMappingDescription string
+
+ NewLeaseDuration string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewRemoteHost, err = soap.MarshalString(NewRemoteHost); err != nil {
+ return
+ }
+ if request.NewExternalPort, err = soap.MarshalUi2(NewExternalPort); err != nil {
+ return
+ }
+ if request.NewProtocol, err = soap.MarshalString(NewProtocol); err != nil {
+ return
+ }
+ if request.NewInternalPort, err = soap.MarshalUi2(NewInternalPort); err != nil {
+ return
+ }
+ if request.NewInternalClient, err = soap.MarshalString(NewInternalClient); err != nil {
+ return
+ }
+ if request.NewEnabled, err = soap.MarshalBoolean(NewEnabled); err != nil {
+ return
+ }
+ if request.NewPortMappingDescription, err = soap.MarshalString(NewPortMappingDescription); err != nil {
+ return
+ }
+ if request.NewLeaseDuration, err = soap.MarshalUi4(NewLeaseDuration); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPPPConnection_1, "AddPortMapping", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewRemoteHost:
+//
+// * NewExternalPort:
+//
+// * NewProtocol: allowed values: TCP, UDP
+//
+//
+func (client *WANPPPConnection1) DeletePortMapping(NewRemoteHost string, NewExternalPort uint16, NewProtocol string) (err error) {
+ // Request structure.
+ request := &struct {
+ NewRemoteHost string
+
+ NewExternalPort string
+
+ NewProtocol string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewRemoteHost, err = soap.MarshalString(NewRemoteHost); err != nil {
+ return
+ }
+ if request.NewExternalPort, err = soap.MarshalUi2(NewExternalPort); err != nil {
+ return
+ }
+ if request.NewProtocol, err = soap.MarshalString(NewProtocol); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPPPConnection_1, "DeletePortMapping", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewExternalIPAddress:
+func (client *WANPPPConnection1) GetExternalIPAddress() (NewExternalIPAddress string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewExternalIPAddress string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPPPConnection_1, "GetExternalIPAddress", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewExternalIPAddress, err = soap.UnmarshalString(response.NewExternalIPAddress); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
diff --git a/Godeps/_workspace/src/github.com/huin/goupnp/dcps/internetgateway2/internetgateway2.go b/Godeps/_workspace/src/github.com/huin/goupnp/dcps/internetgateway2/internetgateway2.go
new file mode 100644
index 000000000..a5892288e
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/huin/goupnp/dcps/internetgateway2/internetgateway2.go
@@ -0,0 +1,5271 @@
+// Client for UPnP Device Control Protocol Internet Gateway Device v2.
+//
+// This DCP is documented in detail at: http://upnp.org/specs/gw/UPnP-gw-InternetGatewayDevice-v2-Device.pdf
+//
+// Typically, use one of the New* functions to discover services on the local
+// network.
+package internetgateway2
+
+// Generated file - do not edit by hand. See README.md
+
+import (
+ "time"
+
+ "github.com/huin/goupnp"
+ "github.com/huin/goupnp/soap"
+)
+
+// Hack to avoid Go complaining if time isn't used.
+var _ time.Time
+
+// Device URNs:
+const (
+ URN_LANDevice_1 = "urn:schemas-upnp-org:device:LANDevice:1"
+ URN_WANConnectionDevice_1 = "urn:schemas-upnp-org:device:WANConnectionDevice:1"
+ URN_WANConnectionDevice_2 = "urn:schemas-upnp-org:device:WANConnectionDevice:2"
+ URN_WANDevice_1 = "urn:schemas-upnp-org:device:WANDevice:1"
+ URN_WANDevice_2 = "urn:schemas-upnp-org:device:WANDevice:2"
+)
+
+// Service URNs:
+const (
+ URN_LANHostConfigManagement_1 = "urn:schemas-upnp-org:service:LANHostConfigManagement:1"
+ URN_Layer3Forwarding_1 = "urn:schemas-upnp-org:service:Layer3Forwarding:1"
+ URN_WANCableLinkConfig_1 = "urn:schemas-upnp-org:service:WANCableLinkConfig:1"
+ URN_WANCommonInterfaceConfig_1 = "urn:schemas-upnp-org:service:WANCommonInterfaceConfig:1"
+ URN_WANDSLLinkConfig_1 = "urn:schemas-upnp-org:service:WANDSLLinkConfig:1"
+ URN_WANEthernetLinkConfig_1 = "urn:schemas-upnp-org:service:WANEthernetLinkConfig:1"
+ URN_WANIPConnection_1 = "urn:schemas-upnp-org:service:WANIPConnection:1"
+ URN_WANIPConnection_2 = "urn:schemas-upnp-org:service:WANIPConnection:2"
+ URN_WANIPv6FirewallControl_1 = "urn:schemas-upnp-org:service:WANIPv6FirewallControl:1"
+ URN_WANPOTSLinkConfig_1 = "urn:schemas-upnp-org:service:WANPOTSLinkConfig:1"
+ URN_WANPPPConnection_1 = "urn:schemas-upnp-org:service:WANPPPConnection:1"
+)
+
+// LANHostConfigManagement1 is a client for UPnP SOAP service with URN "urn:schemas-upnp-org:service:LANHostConfigManagement:1". See
+// goupnp.ServiceClient, which contains RootDevice and Service attributes which
+// are provided for informational value.
+type LANHostConfigManagement1 struct {
+ goupnp.ServiceClient
+}
+
+// NewLANHostConfigManagement1Clients discovers instances of the service on the network,
+// and returns clients to any that are found. errors will contain an error for
+// any devices that replied but which could not be queried, and err will be set
+// if the discovery process failed outright.
+//
+// This is a typical entry calling point into this package.
+func NewLANHostConfigManagement1Clients() (clients []*LANHostConfigManagement1, errors []error, err error) {
+ var genericClients []goupnp.ServiceClient
+ if genericClients, errors, err = goupnp.NewServiceClients(URN_LANHostConfigManagement_1); err != nil {
+ return
+ }
+ clients = make([]*LANHostConfigManagement1, len(genericClients))
+ for i := range genericClients {
+ clients[i] = &LANHostConfigManagement1{genericClients[i]}
+ }
+ return
+}
+
+// Arguments:
+//
+// * NewDHCPServerConfigurable:
+//
+//
+func (client *LANHostConfigManagement1) SetDHCPServerConfigurable(NewDHCPServerConfigurable bool) (err error) {
+ // Request structure.
+ request := &struct {
+ NewDHCPServerConfigurable string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewDHCPServerConfigurable, err = soap.MarshalBoolean(NewDHCPServerConfigurable); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_LANHostConfigManagement_1, "SetDHCPServerConfigurable", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewDHCPServerConfigurable:
+func (client *LANHostConfigManagement1) GetDHCPServerConfigurable() (NewDHCPServerConfigurable bool, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewDHCPServerConfigurable string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_LANHostConfigManagement_1, "GetDHCPServerConfigurable", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewDHCPServerConfigurable, err = soap.UnmarshalBoolean(response.NewDHCPServerConfigurable); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewDHCPRelay:
+//
+//
+func (client *LANHostConfigManagement1) SetDHCPRelay(NewDHCPRelay bool) (err error) {
+ // Request structure.
+ request := &struct {
+ NewDHCPRelay string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewDHCPRelay, err = soap.MarshalBoolean(NewDHCPRelay); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_LANHostConfigManagement_1, "SetDHCPRelay", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewDHCPRelay:
+func (client *LANHostConfigManagement1) GetDHCPRelay() (NewDHCPRelay bool, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewDHCPRelay string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_LANHostConfigManagement_1, "GetDHCPRelay", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewDHCPRelay, err = soap.UnmarshalBoolean(response.NewDHCPRelay); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewSubnetMask:
+//
+//
+func (client *LANHostConfigManagement1) SetSubnetMask(NewSubnetMask string) (err error) {
+ // Request structure.
+ request := &struct {
+ NewSubnetMask string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewSubnetMask, err = soap.MarshalString(NewSubnetMask); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_LANHostConfigManagement_1, "SetSubnetMask", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewSubnetMask:
+func (client *LANHostConfigManagement1) GetSubnetMask() (NewSubnetMask string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewSubnetMask string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_LANHostConfigManagement_1, "GetSubnetMask", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewSubnetMask, err = soap.UnmarshalString(response.NewSubnetMask); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewIPRouters:
+//
+//
+func (client *LANHostConfigManagement1) SetIPRouter(NewIPRouters string) (err error) {
+ // Request structure.
+ request := &struct {
+ NewIPRouters string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewIPRouters, err = soap.MarshalString(NewIPRouters); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_LANHostConfigManagement_1, "SetIPRouter", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewIPRouters:
+//
+//
+func (client *LANHostConfigManagement1) DeleteIPRouter(NewIPRouters string) (err error) {
+ // Request structure.
+ request := &struct {
+ NewIPRouters string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewIPRouters, err = soap.MarshalString(NewIPRouters); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_LANHostConfigManagement_1, "DeleteIPRouter", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewIPRouters:
+func (client *LANHostConfigManagement1) GetIPRoutersList() (NewIPRouters string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewIPRouters string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_LANHostConfigManagement_1, "GetIPRoutersList", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewIPRouters, err = soap.UnmarshalString(response.NewIPRouters); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewDomainName:
+//
+//
+func (client *LANHostConfigManagement1) SetDomainName(NewDomainName string) (err error) {
+ // Request structure.
+ request := &struct {
+ NewDomainName string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewDomainName, err = soap.MarshalString(NewDomainName); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_LANHostConfigManagement_1, "SetDomainName", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewDomainName:
+func (client *LANHostConfigManagement1) GetDomainName() (NewDomainName string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewDomainName string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_LANHostConfigManagement_1, "GetDomainName", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewDomainName, err = soap.UnmarshalString(response.NewDomainName); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewMinAddress:
+//
+// * NewMaxAddress:
+//
+//
+func (client *LANHostConfigManagement1) SetAddressRange(NewMinAddress string, NewMaxAddress string) (err error) {
+ // Request structure.
+ request := &struct {
+ NewMinAddress string
+
+ NewMaxAddress string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewMinAddress, err = soap.MarshalString(NewMinAddress); err != nil {
+ return
+ }
+ if request.NewMaxAddress, err = soap.MarshalString(NewMaxAddress); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_LANHostConfigManagement_1, "SetAddressRange", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewMinAddress:
+//
+// * NewMaxAddress:
+func (client *LANHostConfigManagement1) GetAddressRange() (NewMinAddress string, NewMaxAddress string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewMinAddress string
+
+ NewMaxAddress string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_LANHostConfigManagement_1, "GetAddressRange", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewMinAddress, err = soap.UnmarshalString(response.NewMinAddress); err != nil {
+ return
+ }
+ if NewMaxAddress, err = soap.UnmarshalString(response.NewMaxAddress); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewReservedAddresses:
+//
+//
+func (client *LANHostConfigManagement1) SetReservedAddress(NewReservedAddresses string) (err error) {
+ // Request structure.
+ request := &struct {
+ NewReservedAddresses string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewReservedAddresses, err = soap.MarshalString(NewReservedAddresses); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_LANHostConfigManagement_1, "SetReservedAddress", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewReservedAddresses:
+//
+//
+func (client *LANHostConfigManagement1) DeleteReservedAddress(NewReservedAddresses string) (err error) {
+ // Request structure.
+ request := &struct {
+ NewReservedAddresses string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewReservedAddresses, err = soap.MarshalString(NewReservedAddresses); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_LANHostConfigManagement_1, "DeleteReservedAddress", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewReservedAddresses:
+func (client *LANHostConfigManagement1) GetReservedAddresses() (NewReservedAddresses string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewReservedAddresses string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_LANHostConfigManagement_1, "GetReservedAddresses", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewReservedAddresses, err = soap.UnmarshalString(response.NewReservedAddresses); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewDNSServers:
+//
+//
+func (client *LANHostConfigManagement1) SetDNSServer(NewDNSServers string) (err error) {
+ // Request structure.
+ request := &struct {
+ NewDNSServers string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewDNSServers, err = soap.MarshalString(NewDNSServers); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_LANHostConfigManagement_1, "SetDNSServer", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewDNSServers:
+//
+//
+func (client *LANHostConfigManagement1) DeleteDNSServer(NewDNSServers string) (err error) {
+ // Request structure.
+ request := &struct {
+ NewDNSServers string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewDNSServers, err = soap.MarshalString(NewDNSServers); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_LANHostConfigManagement_1, "DeleteDNSServer", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewDNSServers:
+func (client *LANHostConfigManagement1) GetDNSServers() (NewDNSServers string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewDNSServers string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_LANHostConfigManagement_1, "GetDNSServers", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewDNSServers, err = soap.UnmarshalString(response.NewDNSServers); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Layer3Forwarding1 is a client for UPnP SOAP service with URN "urn:schemas-upnp-org:service:Layer3Forwarding:1". See
+// goupnp.ServiceClient, which contains RootDevice and Service attributes which
+// are provided for informational value.
+type Layer3Forwarding1 struct {
+ goupnp.ServiceClient
+}
+
+// NewLayer3Forwarding1Clients discovers instances of the service on the network,
+// and returns clients to any that are found. errors will contain an error for
+// any devices that replied but which could not be queried, and err will be set
+// if the discovery process failed outright.
+//
+// This is a typical entry calling point into this package.
+func NewLayer3Forwarding1Clients() (clients []*Layer3Forwarding1, errors []error, err error) {
+ var genericClients []goupnp.ServiceClient
+ if genericClients, errors, err = goupnp.NewServiceClients(URN_Layer3Forwarding_1); err != nil {
+ return
+ }
+ clients = make([]*Layer3Forwarding1, len(genericClients))
+ for i := range genericClients {
+ clients[i] = &Layer3Forwarding1{genericClients[i]}
+ }
+ return
+}
+
+// Arguments:
+//
+// * NewDefaultConnectionService:
+//
+//
+func (client *Layer3Forwarding1) SetDefaultConnectionService(NewDefaultConnectionService string) (err error) {
+ // Request structure.
+ request := &struct {
+ NewDefaultConnectionService string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewDefaultConnectionService, err = soap.MarshalString(NewDefaultConnectionService); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_Layer3Forwarding_1, "SetDefaultConnectionService", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewDefaultConnectionService:
+func (client *Layer3Forwarding1) GetDefaultConnectionService() (NewDefaultConnectionService string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewDefaultConnectionService string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_Layer3Forwarding_1, "GetDefaultConnectionService", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewDefaultConnectionService, err = soap.UnmarshalString(response.NewDefaultConnectionService); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// WANCableLinkConfig1 is a client for UPnP SOAP service with URN "urn:schemas-upnp-org:service:WANCableLinkConfig:1". See
+// goupnp.ServiceClient, which contains RootDevice and Service attributes which
+// are provided for informational value.
+type WANCableLinkConfig1 struct {
+ goupnp.ServiceClient
+}
+
+// NewWANCableLinkConfig1Clients discovers instances of the service on the network,
+// and returns clients to any that are found. errors will contain an error for
+// any devices that replied but which could not be queried, and err will be set
+// if the discovery process failed outright.
+//
+// This is a typical entry calling point into this package.
+func NewWANCableLinkConfig1Clients() (clients []*WANCableLinkConfig1, errors []error, err error) {
+ var genericClients []goupnp.ServiceClient
+ if genericClients, errors, err = goupnp.NewServiceClients(URN_WANCableLinkConfig_1); err != nil {
+ return
+ }
+ clients = make([]*WANCableLinkConfig1, len(genericClients))
+ for i := range genericClients {
+ clients[i] = &WANCableLinkConfig1{genericClients[i]}
+ }
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewCableLinkConfigState: allowed values: notReady, dsSyncComplete, usParamAcquired, rangingComplete, ipComplete, todEstablished, paramTransferComplete, registrationComplete, operational, accessDenied
+//
+// * NewLinkType: allowed values: Ethernet
+func (client *WANCableLinkConfig1) GetCableLinkConfigInfo() (NewCableLinkConfigState string, NewLinkType string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewCableLinkConfigState string
+
+ NewLinkType string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANCableLinkConfig_1, "GetCableLinkConfigInfo", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewCableLinkConfigState, err = soap.UnmarshalString(response.NewCableLinkConfigState); err != nil {
+ return
+ }
+ if NewLinkType, err = soap.UnmarshalString(response.NewLinkType); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewDownstreamFrequency:
+func (client *WANCableLinkConfig1) GetDownstreamFrequency() (NewDownstreamFrequency uint32, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewDownstreamFrequency string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANCableLinkConfig_1, "GetDownstreamFrequency", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewDownstreamFrequency, err = soap.UnmarshalUi4(response.NewDownstreamFrequency); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewDownstreamModulation: allowed values: 64QAM, 256QAM
+func (client *WANCableLinkConfig1) GetDownstreamModulation() (NewDownstreamModulation string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewDownstreamModulation string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANCableLinkConfig_1, "GetDownstreamModulation", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewDownstreamModulation, err = soap.UnmarshalString(response.NewDownstreamModulation); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewUpstreamFrequency:
+func (client *WANCableLinkConfig1) GetUpstreamFrequency() (NewUpstreamFrequency uint32, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewUpstreamFrequency string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANCableLinkConfig_1, "GetUpstreamFrequency", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewUpstreamFrequency, err = soap.UnmarshalUi4(response.NewUpstreamFrequency); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewUpstreamModulation: allowed values: QPSK, 16QAM
+func (client *WANCableLinkConfig1) GetUpstreamModulation() (NewUpstreamModulation string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewUpstreamModulation string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANCableLinkConfig_1, "GetUpstreamModulation", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewUpstreamModulation, err = soap.UnmarshalString(response.NewUpstreamModulation); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewUpstreamChannelID:
+func (client *WANCableLinkConfig1) GetUpstreamChannelID() (NewUpstreamChannelID uint32, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewUpstreamChannelID string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANCableLinkConfig_1, "GetUpstreamChannelID", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewUpstreamChannelID, err = soap.UnmarshalUi4(response.NewUpstreamChannelID); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewUpstreamPowerLevel:
+func (client *WANCableLinkConfig1) GetUpstreamPowerLevel() (NewUpstreamPowerLevel uint32, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewUpstreamPowerLevel string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANCableLinkConfig_1, "GetUpstreamPowerLevel", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewUpstreamPowerLevel, err = soap.UnmarshalUi4(response.NewUpstreamPowerLevel); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewBPIEncryptionEnabled:
+func (client *WANCableLinkConfig1) GetBPIEncryptionEnabled() (NewBPIEncryptionEnabled bool, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewBPIEncryptionEnabled string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANCableLinkConfig_1, "GetBPIEncryptionEnabled", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewBPIEncryptionEnabled, err = soap.UnmarshalBoolean(response.NewBPIEncryptionEnabled); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewConfigFile:
+func (client *WANCableLinkConfig1) GetConfigFile() (NewConfigFile string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewConfigFile string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANCableLinkConfig_1, "GetConfigFile", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewConfigFile, err = soap.UnmarshalString(response.NewConfigFile); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewTFTPServer:
+func (client *WANCableLinkConfig1) GetTFTPServer() (NewTFTPServer string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewTFTPServer string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANCableLinkConfig_1, "GetTFTPServer", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewTFTPServer, err = soap.UnmarshalString(response.NewTFTPServer); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// WANCommonInterfaceConfig1 is a client for UPnP SOAP service with URN "urn:schemas-upnp-org:service:WANCommonInterfaceConfig:1". See
+// goupnp.ServiceClient, which contains RootDevice and Service attributes which
+// are provided for informational value.
+type WANCommonInterfaceConfig1 struct {
+ goupnp.ServiceClient
+}
+
+// NewWANCommonInterfaceConfig1Clients discovers instances of the service on the network,
+// and returns clients to any that are found. errors will contain an error for
+// any devices that replied but which could not be queried, and err will be set
+// if the discovery process failed outright.
+//
+// This is a typical entry calling point into this package.
+func NewWANCommonInterfaceConfig1Clients() (clients []*WANCommonInterfaceConfig1, errors []error, err error) {
+ var genericClients []goupnp.ServiceClient
+ if genericClients, errors, err = goupnp.NewServiceClients(URN_WANCommonInterfaceConfig_1); err != nil {
+ return
+ }
+ clients = make([]*WANCommonInterfaceConfig1, len(genericClients))
+ for i := range genericClients {
+ clients[i] = &WANCommonInterfaceConfig1{genericClients[i]}
+ }
+ return
+}
+
+// Arguments:
+//
+// * NewEnabledForInternet:
+//
+//
+func (client *WANCommonInterfaceConfig1) SetEnabledForInternet(NewEnabledForInternet bool) (err error) {
+ // Request structure.
+ request := &struct {
+ NewEnabledForInternet string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewEnabledForInternet, err = soap.MarshalBoolean(NewEnabledForInternet); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANCommonInterfaceConfig_1, "SetEnabledForInternet", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewEnabledForInternet:
+func (client *WANCommonInterfaceConfig1) GetEnabledForInternet() (NewEnabledForInternet bool, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewEnabledForInternet string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANCommonInterfaceConfig_1, "GetEnabledForInternet", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewEnabledForInternet, err = soap.UnmarshalBoolean(response.NewEnabledForInternet); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewWANAccessType: allowed values: DSL, POTS, Cable, Ethernet
+//
+// * NewLayer1UpstreamMaxBitRate:
+//
+// * NewLayer1DownstreamMaxBitRate:
+//
+// * NewPhysicalLinkStatus: allowed values: Up, Down
+func (client *WANCommonInterfaceConfig1) GetCommonLinkProperties() (NewWANAccessType string, NewLayer1UpstreamMaxBitRate uint32, NewLayer1DownstreamMaxBitRate uint32, NewPhysicalLinkStatus string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewWANAccessType string
+
+ NewLayer1UpstreamMaxBitRate string
+
+ NewLayer1DownstreamMaxBitRate string
+
+ NewPhysicalLinkStatus string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANCommonInterfaceConfig_1, "GetCommonLinkProperties", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewWANAccessType, err = soap.UnmarshalString(response.NewWANAccessType); err != nil {
+ return
+ }
+ if NewLayer1UpstreamMaxBitRate, err = soap.UnmarshalUi4(response.NewLayer1UpstreamMaxBitRate); err != nil {
+ return
+ }
+ if NewLayer1DownstreamMaxBitRate, err = soap.UnmarshalUi4(response.NewLayer1DownstreamMaxBitRate); err != nil {
+ return
+ }
+ if NewPhysicalLinkStatus, err = soap.UnmarshalString(response.NewPhysicalLinkStatus); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewWANAccessProvider:
+func (client *WANCommonInterfaceConfig1) GetWANAccessProvider() (NewWANAccessProvider string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewWANAccessProvider string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANCommonInterfaceConfig_1, "GetWANAccessProvider", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewWANAccessProvider, err = soap.UnmarshalString(response.NewWANAccessProvider); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewMaximumActiveConnections: allowed value range: minimum=1, step=1
+func (client *WANCommonInterfaceConfig1) GetMaximumActiveConnections() (NewMaximumActiveConnections uint16, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewMaximumActiveConnections string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANCommonInterfaceConfig_1, "GetMaximumActiveConnections", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewMaximumActiveConnections, err = soap.UnmarshalUi2(response.NewMaximumActiveConnections); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewTotalBytesSent:
+func (client *WANCommonInterfaceConfig1) GetTotalBytesSent() (NewTotalBytesSent uint32, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewTotalBytesSent string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANCommonInterfaceConfig_1, "GetTotalBytesSent", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewTotalBytesSent, err = soap.UnmarshalUi4(response.NewTotalBytesSent); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewTotalBytesReceived:
+func (client *WANCommonInterfaceConfig1) GetTotalBytesReceived() (NewTotalBytesReceived uint32, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewTotalBytesReceived string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANCommonInterfaceConfig_1, "GetTotalBytesReceived", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewTotalBytesReceived, err = soap.UnmarshalUi4(response.NewTotalBytesReceived); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewTotalPacketsSent:
+func (client *WANCommonInterfaceConfig1) GetTotalPacketsSent() (NewTotalPacketsSent uint32, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewTotalPacketsSent string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANCommonInterfaceConfig_1, "GetTotalPacketsSent", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewTotalPacketsSent, err = soap.UnmarshalUi4(response.NewTotalPacketsSent); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewTotalPacketsReceived:
+func (client *WANCommonInterfaceConfig1) GetTotalPacketsReceived() (NewTotalPacketsReceived uint32, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewTotalPacketsReceived string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANCommonInterfaceConfig_1, "GetTotalPacketsReceived", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewTotalPacketsReceived, err = soap.UnmarshalUi4(response.NewTotalPacketsReceived); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewActiveConnectionIndex:
+//
+// Return values:
+//
+// * NewActiveConnDeviceContainer:
+//
+// * NewActiveConnectionServiceID:
+func (client *WANCommonInterfaceConfig1) GetActiveConnection(NewActiveConnectionIndex uint16) (NewActiveConnDeviceContainer string, NewActiveConnectionServiceID string, err error) {
+ // Request structure.
+ request := &struct {
+ NewActiveConnectionIndex string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewActiveConnectionIndex, err = soap.MarshalUi2(NewActiveConnectionIndex); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewActiveConnDeviceContainer string
+
+ NewActiveConnectionServiceID string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANCommonInterfaceConfig_1, "GetActiveConnection", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewActiveConnDeviceContainer, err = soap.UnmarshalString(response.NewActiveConnDeviceContainer); err != nil {
+ return
+ }
+ if NewActiveConnectionServiceID, err = soap.UnmarshalString(response.NewActiveConnectionServiceID); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// WANDSLLinkConfig1 is a client for UPnP SOAP service with URN "urn:schemas-upnp-org:service:WANDSLLinkConfig:1". See
+// goupnp.ServiceClient, which contains RootDevice and Service attributes which
+// are provided for informational value.
+type WANDSLLinkConfig1 struct {
+ goupnp.ServiceClient
+}
+
+// NewWANDSLLinkConfig1Clients discovers instances of the service on the network,
+// and returns clients to any that are found. errors will contain an error for
+// any devices that replied but which could not be queried, and err will be set
+// if the discovery process failed outright.
+//
+// This is a typical entry calling point into this package.
+func NewWANDSLLinkConfig1Clients() (clients []*WANDSLLinkConfig1, errors []error, err error) {
+ var genericClients []goupnp.ServiceClient
+ if genericClients, errors, err = goupnp.NewServiceClients(URN_WANDSLLinkConfig_1); err != nil {
+ return
+ }
+ clients = make([]*WANDSLLinkConfig1, len(genericClients))
+ for i := range genericClients {
+ clients[i] = &WANDSLLinkConfig1{genericClients[i]}
+ }
+ return
+}
+
+// Arguments:
+//
+// * NewLinkType:
+//
+//
+func (client *WANDSLLinkConfig1) SetDSLLinkType(NewLinkType string) (err error) {
+ // Request structure.
+ request := &struct {
+ NewLinkType string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewLinkType, err = soap.MarshalString(NewLinkType); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANDSLLinkConfig_1, "SetDSLLinkType", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewLinkType:
+//
+// * NewLinkStatus: allowed values: Up, Down
+func (client *WANDSLLinkConfig1) GetDSLLinkInfo() (NewLinkType string, NewLinkStatus string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewLinkType string
+
+ NewLinkStatus string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANDSLLinkConfig_1, "GetDSLLinkInfo", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewLinkType, err = soap.UnmarshalString(response.NewLinkType); err != nil {
+ return
+ }
+ if NewLinkStatus, err = soap.UnmarshalString(response.NewLinkStatus); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewAutoConfig:
+func (client *WANDSLLinkConfig1) GetAutoConfig() (NewAutoConfig bool, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewAutoConfig string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANDSLLinkConfig_1, "GetAutoConfig", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewAutoConfig, err = soap.UnmarshalBoolean(response.NewAutoConfig); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewModulationType:
+func (client *WANDSLLinkConfig1) GetModulationType() (NewModulationType string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewModulationType string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANDSLLinkConfig_1, "GetModulationType", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewModulationType, err = soap.UnmarshalString(response.NewModulationType); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewDestinationAddress:
+//
+//
+func (client *WANDSLLinkConfig1) SetDestinationAddress(NewDestinationAddress string) (err error) {
+ // Request structure.
+ request := &struct {
+ NewDestinationAddress string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewDestinationAddress, err = soap.MarshalString(NewDestinationAddress); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANDSLLinkConfig_1, "SetDestinationAddress", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewDestinationAddress:
+func (client *WANDSLLinkConfig1) GetDestinationAddress() (NewDestinationAddress string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewDestinationAddress string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANDSLLinkConfig_1, "GetDestinationAddress", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewDestinationAddress, err = soap.UnmarshalString(response.NewDestinationAddress); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewATMEncapsulation:
+//
+//
+func (client *WANDSLLinkConfig1) SetATMEncapsulation(NewATMEncapsulation string) (err error) {
+ // Request structure.
+ request := &struct {
+ NewATMEncapsulation string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewATMEncapsulation, err = soap.MarshalString(NewATMEncapsulation); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANDSLLinkConfig_1, "SetATMEncapsulation", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewATMEncapsulation:
+func (client *WANDSLLinkConfig1) GetATMEncapsulation() (NewATMEncapsulation string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewATMEncapsulation string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANDSLLinkConfig_1, "GetATMEncapsulation", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewATMEncapsulation, err = soap.UnmarshalString(response.NewATMEncapsulation); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewFCSPreserved:
+//
+//
+func (client *WANDSLLinkConfig1) SetFCSPreserved(NewFCSPreserved bool) (err error) {
+ // Request structure.
+ request := &struct {
+ NewFCSPreserved string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewFCSPreserved, err = soap.MarshalBoolean(NewFCSPreserved); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANDSLLinkConfig_1, "SetFCSPreserved", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewFCSPreserved:
+func (client *WANDSLLinkConfig1) GetFCSPreserved() (NewFCSPreserved bool, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewFCSPreserved string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANDSLLinkConfig_1, "GetFCSPreserved", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewFCSPreserved, err = soap.UnmarshalBoolean(response.NewFCSPreserved); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// WANEthernetLinkConfig1 is a client for UPnP SOAP service with URN "urn:schemas-upnp-org:service:WANEthernetLinkConfig:1". See
+// goupnp.ServiceClient, which contains RootDevice and Service attributes which
+// are provided for informational value.
+type WANEthernetLinkConfig1 struct {
+ goupnp.ServiceClient
+}
+
+// NewWANEthernetLinkConfig1Clients discovers instances of the service on the network,
+// and returns clients to any that are found. errors will contain an error for
+// any devices that replied but which could not be queried, and err will be set
+// if the discovery process failed outright.
+//
+// This is a typical entry calling point into this package.
+func NewWANEthernetLinkConfig1Clients() (clients []*WANEthernetLinkConfig1, errors []error, err error) {
+ var genericClients []goupnp.ServiceClient
+ if genericClients, errors, err = goupnp.NewServiceClients(URN_WANEthernetLinkConfig_1); err != nil {
+ return
+ }
+ clients = make([]*WANEthernetLinkConfig1, len(genericClients))
+ for i := range genericClients {
+ clients[i] = &WANEthernetLinkConfig1{genericClients[i]}
+ }
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewEthernetLinkStatus: allowed values: Up, Down
+func (client *WANEthernetLinkConfig1) GetEthernetLinkStatus() (NewEthernetLinkStatus string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewEthernetLinkStatus string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANEthernetLinkConfig_1, "GetEthernetLinkStatus", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewEthernetLinkStatus, err = soap.UnmarshalString(response.NewEthernetLinkStatus); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// WANIPConnection1 is a client for UPnP SOAP service with URN "urn:schemas-upnp-org:service:WANIPConnection:1". See
+// goupnp.ServiceClient, which contains RootDevice and Service attributes which
+// are provided for informational value.
+type WANIPConnection1 struct {
+ goupnp.ServiceClient
+}
+
+// NewWANIPConnection1Clients discovers instances of the service on the network,
+// and returns clients to any that are found. errors will contain an error for
+// any devices that replied but which could not be queried, and err will be set
+// if the discovery process failed outright.
+//
+// This is a typical entry calling point into this package.
+func NewWANIPConnection1Clients() (clients []*WANIPConnection1, errors []error, err error) {
+ var genericClients []goupnp.ServiceClient
+ if genericClients, errors, err = goupnp.NewServiceClients(URN_WANIPConnection_1); err != nil {
+ return
+ }
+ clients = make([]*WANIPConnection1, len(genericClients))
+ for i := range genericClients {
+ clients[i] = &WANIPConnection1{genericClients[i]}
+ }
+ return
+}
+
+// Arguments:
+//
+// * NewConnectionType:
+//
+//
+func (client *WANIPConnection1) SetConnectionType(NewConnectionType string) (err error) {
+ // Request structure.
+ request := &struct {
+ NewConnectionType string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewConnectionType, err = soap.MarshalString(NewConnectionType); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPConnection_1, "SetConnectionType", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewConnectionType:
+//
+// * NewPossibleConnectionTypes: allowed values: Unconfigured, IP_Routed, IP_Bridged
+func (client *WANIPConnection1) GetConnectionTypeInfo() (NewConnectionType string, NewPossibleConnectionTypes string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewConnectionType string
+
+ NewPossibleConnectionTypes string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPConnection_1, "GetConnectionTypeInfo", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewConnectionType, err = soap.UnmarshalString(response.NewConnectionType); err != nil {
+ return
+ }
+ if NewPossibleConnectionTypes, err = soap.UnmarshalString(response.NewPossibleConnectionTypes); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+//
+func (client *WANIPConnection1) RequestConnection() (err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPConnection_1, "RequestConnection", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+//
+func (client *WANIPConnection1) RequestTermination() (err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPConnection_1, "RequestTermination", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+//
+func (client *WANIPConnection1) ForceTermination() (err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPConnection_1, "ForceTermination", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewAutoDisconnectTime:
+//
+//
+func (client *WANIPConnection1) SetAutoDisconnectTime(NewAutoDisconnectTime uint32) (err error) {
+ // Request structure.
+ request := &struct {
+ NewAutoDisconnectTime string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewAutoDisconnectTime, err = soap.MarshalUi4(NewAutoDisconnectTime); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPConnection_1, "SetAutoDisconnectTime", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewIdleDisconnectTime:
+//
+//
+func (client *WANIPConnection1) SetIdleDisconnectTime(NewIdleDisconnectTime uint32) (err error) {
+ // Request structure.
+ request := &struct {
+ NewIdleDisconnectTime string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewIdleDisconnectTime, err = soap.MarshalUi4(NewIdleDisconnectTime); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPConnection_1, "SetIdleDisconnectTime", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewWarnDisconnectDelay:
+//
+//
+func (client *WANIPConnection1) SetWarnDisconnectDelay(NewWarnDisconnectDelay uint32) (err error) {
+ // Request structure.
+ request := &struct {
+ NewWarnDisconnectDelay string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewWarnDisconnectDelay, err = soap.MarshalUi4(NewWarnDisconnectDelay); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPConnection_1, "SetWarnDisconnectDelay", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewConnectionStatus: allowed values: Unconfigured, Connected, Disconnected
+//
+// * NewLastConnectionError: allowed values: ERROR_NONE
+//
+// * NewUptime:
+func (client *WANIPConnection1) GetStatusInfo() (NewConnectionStatus string, NewLastConnectionError string, NewUptime uint32, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewConnectionStatus string
+
+ NewLastConnectionError string
+
+ NewUptime string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPConnection_1, "GetStatusInfo", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewConnectionStatus, err = soap.UnmarshalString(response.NewConnectionStatus); err != nil {
+ return
+ }
+ if NewLastConnectionError, err = soap.UnmarshalString(response.NewLastConnectionError); err != nil {
+ return
+ }
+ if NewUptime, err = soap.UnmarshalUi4(response.NewUptime); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewAutoDisconnectTime:
+func (client *WANIPConnection1) GetAutoDisconnectTime() (NewAutoDisconnectTime uint32, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewAutoDisconnectTime string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPConnection_1, "GetAutoDisconnectTime", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewAutoDisconnectTime, err = soap.UnmarshalUi4(response.NewAutoDisconnectTime); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewIdleDisconnectTime:
+func (client *WANIPConnection1) GetIdleDisconnectTime() (NewIdleDisconnectTime uint32, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewIdleDisconnectTime string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPConnection_1, "GetIdleDisconnectTime", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewIdleDisconnectTime, err = soap.UnmarshalUi4(response.NewIdleDisconnectTime); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewWarnDisconnectDelay:
+func (client *WANIPConnection1) GetWarnDisconnectDelay() (NewWarnDisconnectDelay uint32, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewWarnDisconnectDelay string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPConnection_1, "GetWarnDisconnectDelay", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewWarnDisconnectDelay, err = soap.UnmarshalUi4(response.NewWarnDisconnectDelay); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewRSIPAvailable:
+//
+// * NewNATEnabled:
+func (client *WANIPConnection1) GetNATRSIPStatus() (NewRSIPAvailable bool, NewNATEnabled bool, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewRSIPAvailable string
+
+ NewNATEnabled string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPConnection_1, "GetNATRSIPStatus", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewRSIPAvailable, err = soap.UnmarshalBoolean(response.NewRSIPAvailable); err != nil {
+ return
+ }
+ if NewNATEnabled, err = soap.UnmarshalBoolean(response.NewNATEnabled); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewPortMappingIndex:
+//
+// Return values:
+//
+// * NewRemoteHost:
+//
+// * NewExternalPort:
+//
+// * NewProtocol: allowed values: TCP, UDP
+//
+// * NewInternalPort:
+//
+// * NewInternalClient:
+//
+// * NewEnabled:
+//
+// * NewPortMappingDescription:
+//
+// * NewLeaseDuration:
+func (client *WANIPConnection1) GetGenericPortMappingEntry(NewPortMappingIndex uint16) (NewRemoteHost string, NewExternalPort uint16, NewProtocol string, NewInternalPort uint16, NewInternalClient string, NewEnabled bool, NewPortMappingDescription string, NewLeaseDuration uint32, err error) {
+ // Request structure.
+ request := &struct {
+ NewPortMappingIndex string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewPortMappingIndex, err = soap.MarshalUi2(NewPortMappingIndex); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewRemoteHost string
+
+ NewExternalPort string
+
+ NewProtocol string
+
+ NewInternalPort string
+
+ NewInternalClient string
+
+ NewEnabled string
+
+ NewPortMappingDescription string
+
+ NewLeaseDuration string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPConnection_1, "GetGenericPortMappingEntry", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewRemoteHost, err = soap.UnmarshalString(response.NewRemoteHost); err != nil {
+ return
+ }
+ if NewExternalPort, err = soap.UnmarshalUi2(response.NewExternalPort); err != nil {
+ return
+ }
+ if NewProtocol, err = soap.UnmarshalString(response.NewProtocol); err != nil {
+ return
+ }
+ if NewInternalPort, err = soap.UnmarshalUi2(response.NewInternalPort); err != nil {
+ return
+ }
+ if NewInternalClient, err = soap.UnmarshalString(response.NewInternalClient); err != nil {
+ return
+ }
+ if NewEnabled, err = soap.UnmarshalBoolean(response.NewEnabled); err != nil {
+ return
+ }
+ if NewPortMappingDescription, err = soap.UnmarshalString(response.NewPortMappingDescription); err != nil {
+ return
+ }
+ if NewLeaseDuration, err = soap.UnmarshalUi4(response.NewLeaseDuration); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewRemoteHost:
+//
+// * NewExternalPort:
+//
+// * NewProtocol: allowed values: TCP, UDP
+//
+// Return values:
+//
+// * NewInternalPort:
+//
+// * NewInternalClient:
+//
+// * NewEnabled:
+//
+// * NewPortMappingDescription:
+//
+// * NewLeaseDuration:
+func (client *WANIPConnection1) GetSpecificPortMappingEntry(NewRemoteHost string, NewExternalPort uint16, NewProtocol string) (NewInternalPort uint16, NewInternalClient string, NewEnabled bool, NewPortMappingDescription string, NewLeaseDuration uint32, err error) {
+ // Request structure.
+ request := &struct {
+ NewRemoteHost string
+
+ NewExternalPort string
+
+ NewProtocol string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewRemoteHost, err = soap.MarshalString(NewRemoteHost); err != nil {
+ return
+ }
+ if request.NewExternalPort, err = soap.MarshalUi2(NewExternalPort); err != nil {
+ return
+ }
+ if request.NewProtocol, err = soap.MarshalString(NewProtocol); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewInternalPort string
+
+ NewInternalClient string
+
+ NewEnabled string
+
+ NewPortMappingDescription string
+
+ NewLeaseDuration string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPConnection_1, "GetSpecificPortMappingEntry", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewInternalPort, err = soap.UnmarshalUi2(response.NewInternalPort); err != nil {
+ return
+ }
+ if NewInternalClient, err = soap.UnmarshalString(response.NewInternalClient); err != nil {
+ return
+ }
+ if NewEnabled, err = soap.UnmarshalBoolean(response.NewEnabled); err != nil {
+ return
+ }
+ if NewPortMappingDescription, err = soap.UnmarshalString(response.NewPortMappingDescription); err != nil {
+ return
+ }
+ if NewLeaseDuration, err = soap.UnmarshalUi4(response.NewLeaseDuration); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewRemoteHost:
+//
+// * NewExternalPort:
+//
+// * NewProtocol: allowed values: TCP, UDP
+//
+// * NewInternalPort:
+//
+// * NewInternalClient:
+//
+// * NewEnabled:
+//
+// * NewPortMappingDescription:
+//
+// * NewLeaseDuration:
+//
+//
+func (client *WANIPConnection1) AddPortMapping(NewRemoteHost string, NewExternalPort uint16, NewProtocol string, NewInternalPort uint16, NewInternalClient string, NewEnabled bool, NewPortMappingDescription string, NewLeaseDuration uint32) (err error) {
+ // Request structure.
+ request := &struct {
+ NewRemoteHost string
+
+ NewExternalPort string
+
+ NewProtocol string
+
+ NewInternalPort string
+
+ NewInternalClient string
+
+ NewEnabled string
+
+ NewPortMappingDescription string
+
+ NewLeaseDuration string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewRemoteHost, err = soap.MarshalString(NewRemoteHost); err != nil {
+ return
+ }
+ if request.NewExternalPort, err = soap.MarshalUi2(NewExternalPort); err != nil {
+ return
+ }
+ if request.NewProtocol, err = soap.MarshalString(NewProtocol); err != nil {
+ return
+ }
+ if request.NewInternalPort, err = soap.MarshalUi2(NewInternalPort); err != nil {
+ return
+ }
+ if request.NewInternalClient, err = soap.MarshalString(NewInternalClient); err != nil {
+ return
+ }
+ if request.NewEnabled, err = soap.MarshalBoolean(NewEnabled); err != nil {
+ return
+ }
+ if request.NewPortMappingDescription, err = soap.MarshalString(NewPortMappingDescription); err != nil {
+ return
+ }
+ if request.NewLeaseDuration, err = soap.MarshalUi4(NewLeaseDuration); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPConnection_1, "AddPortMapping", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewRemoteHost:
+//
+// * NewExternalPort:
+//
+// * NewProtocol: allowed values: TCP, UDP
+//
+//
+func (client *WANIPConnection1) DeletePortMapping(NewRemoteHost string, NewExternalPort uint16, NewProtocol string) (err error) {
+ // Request structure.
+ request := &struct {
+ NewRemoteHost string
+
+ NewExternalPort string
+
+ NewProtocol string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewRemoteHost, err = soap.MarshalString(NewRemoteHost); err != nil {
+ return
+ }
+ if request.NewExternalPort, err = soap.MarshalUi2(NewExternalPort); err != nil {
+ return
+ }
+ if request.NewProtocol, err = soap.MarshalString(NewProtocol); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPConnection_1, "DeletePortMapping", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewExternalIPAddress:
+func (client *WANIPConnection1) GetExternalIPAddress() (NewExternalIPAddress string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewExternalIPAddress string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPConnection_1, "GetExternalIPAddress", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewExternalIPAddress, err = soap.UnmarshalString(response.NewExternalIPAddress); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// WANIPConnection2 is a client for UPnP SOAP service with URN "urn:schemas-upnp-org:service:WANIPConnection:2". See
+// goupnp.ServiceClient, which contains RootDevice and Service attributes which
+// are provided for informational value.
+type WANIPConnection2 struct {
+ goupnp.ServiceClient
+}
+
+// NewWANIPConnection2Clients discovers instances of the service on the network,
+// and returns clients to any that are found. errors will contain an error for
+// any devices that replied but which could not be queried, and err will be set
+// if the discovery process failed outright.
+//
+// This is a typical entry calling point into this package.
+func NewWANIPConnection2Clients() (clients []*WANIPConnection2, errors []error, err error) {
+ var genericClients []goupnp.ServiceClient
+ if genericClients, errors, err = goupnp.NewServiceClients(URN_WANIPConnection_2); err != nil {
+ return
+ }
+ clients = make([]*WANIPConnection2, len(genericClients))
+ for i := range genericClients {
+ clients[i] = &WANIPConnection2{genericClients[i]}
+ }
+ return
+}
+
+// Arguments:
+//
+// * NewConnectionType: allowed values: Unconfigured, IP_Routed, IP_Bridged
+//
+//
+func (client *WANIPConnection2) SetConnectionType(NewConnectionType string) (err error) {
+ // Request structure.
+ request := &struct {
+ NewConnectionType string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewConnectionType, err = soap.MarshalString(NewConnectionType); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPConnection_2, "SetConnectionType", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewConnectionType: allowed values: Unconfigured, IP_Routed, IP_Bridged
+//
+// * NewPossibleConnectionTypes:
+func (client *WANIPConnection2) GetConnectionTypeInfo() (NewConnectionType string, NewPossibleConnectionTypes string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewConnectionType string
+
+ NewPossibleConnectionTypes string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPConnection_2, "GetConnectionTypeInfo", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewConnectionType, err = soap.UnmarshalString(response.NewConnectionType); err != nil {
+ return
+ }
+ if NewPossibleConnectionTypes, err = soap.UnmarshalString(response.NewPossibleConnectionTypes); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+//
+func (client *WANIPConnection2) RequestConnection() (err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPConnection_2, "RequestConnection", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+//
+func (client *WANIPConnection2) RequestTermination() (err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPConnection_2, "RequestTermination", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+//
+func (client *WANIPConnection2) ForceTermination() (err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPConnection_2, "ForceTermination", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewAutoDisconnectTime:
+//
+//
+func (client *WANIPConnection2) SetAutoDisconnectTime(NewAutoDisconnectTime uint32) (err error) {
+ // Request structure.
+ request := &struct {
+ NewAutoDisconnectTime string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewAutoDisconnectTime, err = soap.MarshalUi4(NewAutoDisconnectTime); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPConnection_2, "SetAutoDisconnectTime", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewIdleDisconnectTime:
+//
+//
+func (client *WANIPConnection2) SetIdleDisconnectTime(NewIdleDisconnectTime uint32) (err error) {
+ // Request structure.
+ request := &struct {
+ NewIdleDisconnectTime string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewIdleDisconnectTime, err = soap.MarshalUi4(NewIdleDisconnectTime); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPConnection_2, "SetIdleDisconnectTime", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewWarnDisconnectDelay:
+//
+//
+func (client *WANIPConnection2) SetWarnDisconnectDelay(NewWarnDisconnectDelay uint32) (err error) {
+ // Request structure.
+ request := &struct {
+ NewWarnDisconnectDelay string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewWarnDisconnectDelay, err = soap.MarshalUi4(NewWarnDisconnectDelay); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPConnection_2, "SetWarnDisconnectDelay", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewConnectionStatus: allowed values: Unconfigured, Connected, Disconnected
+//
+// * NewLastConnectionError: allowed values: ERROR_NONE
+//
+// * NewUptime:
+func (client *WANIPConnection2) GetStatusInfo() (NewConnectionStatus string, NewLastConnectionError string, NewUptime uint32, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewConnectionStatus string
+
+ NewLastConnectionError string
+
+ NewUptime string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPConnection_2, "GetStatusInfo", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewConnectionStatus, err = soap.UnmarshalString(response.NewConnectionStatus); err != nil {
+ return
+ }
+ if NewLastConnectionError, err = soap.UnmarshalString(response.NewLastConnectionError); err != nil {
+ return
+ }
+ if NewUptime, err = soap.UnmarshalUi4(response.NewUptime); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewAutoDisconnectTime:
+func (client *WANIPConnection2) GetAutoDisconnectTime() (NewAutoDisconnectTime uint32, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewAutoDisconnectTime string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPConnection_2, "GetAutoDisconnectTime", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewAutoDisconnectTime, err = soap.UnmarshalUi4(response.NewAutoDisconnectTime); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewIdleDisconnectTime:
+func (client *WANIPConnection2) GetIdleDisconnectTime() (NewIdleDisconnectTime uint32, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewIdleDisconnectTime string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPConnection_2, "GetIdleDisconnectTime", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewIdleDisconnectTime, err = soap.UnmarshalUi4(response.NewIdleDisconnectTime); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewWarnDisconnectDelay:
+func (client *WANIPConnection2) GetWarnDisconnectDelay() (NewWarnDisconnectDelay uint32, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewWarnDisconnectDelay string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPConnection_2, "GetWarnDisconnectDelay", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewWarnDisconnectDelay, err = soap.UnmarshalUi4(response.NewWarnDisconnectDelay); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewRSIPAvailable:
+//
+// * NewNATEnabled:
+func (client *WANIPConnection2) GetNATRSIPStatus() (NewRSIPAvailable bool, NewNATEnabled bool, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewRSIPAvailable string
+
+ NewNATEnabled string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPConnection_2, "GetNATRSIPStatus", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewRSIPAvailable, err = soap.UnmarshalBoolean(response.NewRSIPAvailable); err != nil {
+ return
+ }
+ if NewNATEnabled, err = soap.UnmarshalBoolean(response.NewNATEnabled); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewPortMappingIndex:
+//
+// Return values:
+//
+// * NewRemoteHost:
+//
+// * NewExternalPort:
+//
+// * NewProtocol: allowed values: TCP, UDP
+//
+// * NewInternalPort: allowed value range: minimum=1, maximum=65535
+//
+// * NewInternalClient:
+//
+// * NewEnabled:
+//
+// * NewPortMappingDescription:
+//
+// * NewLeaseDuration: allowed value range: minimum=0, maximum=604800
+func (client *WANIPConnection2) GetGenericPortMappingEntry(NewPortMappingIndex uint16) (NewRemoteHost string, NewExternalPort uint16, NewProtocol string, NewInternalPort uint16, NewInternalClient string, NewEnabled bool, NewPortMappingDescription string, NewLeaseDuration uint32, err error) {
+ // Request structure.
+ request := &struct {
+ NewPortMappingIndex string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewPortMappingIndex, err = soap.MarshalUi2(NewPortMappingIndex); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewRemoteHost string
+
+ NewExternalPort string
+
+ NewProtocol string
+
+ NewInternalPort string
+
+ NewInternalClient string
+
+ NewEnabled string
+
+ NewPortMappingDescription string
+
+ NewLeaseDuration string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPConnection_2, "GetGenericPortMappingEntry", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewRemoteHost, err = soap.UnmarshalString(response.NewRemoteHost); err != nil {
+ return
+ }
+ if NewExternalPort, err = soap.UnmarshalUi2(response.NewExternalPort); err != nil {
+ return
+ }
+ if NewProtocol, err = soap.UnmarshalString(response.NewProtocol); err != nil {
+ return
+ }
+ if NewInternalPort, err = soap.UnmarshalUi2(response.NewInternalPort); err != nil {
+ return
+ }
+ if NewInternalClient, err = soap.UnmarshalString(response.NewInternalClient); err != nil {
+ return
+ }
+ if NewEnabled, err = soap.UnmarshalBoolean(response.NewEnabled); err != nil {
+ return
+ }
+ if NewPortMappingDescription, err = soap.UnmarshalString(response.NewPortMappingDescription); err != nil {
+ return
+ }
+ if NewLeaseDuration, err = soap.UnmarshalUi4(response.NewLeaseDuration); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewRemoteHost:
+//
+// * NewExternalPort:
+//
+// * NewProtocol: allowed values: TCP, UDP
+//
+// Return values:
+//
+// * NewInternalPort: allowed value range: minimum=1, maximum=65535
+//
+// * NewInternalClient:
+//
+// * NewEnabled:
+//
+// * NewPortMappingDescription:
+//
+// * NewLeaseDuration: allowed value range: minimum=0, maximum=604800
+func (client *WANIPConnection2) GetSpecificPortMappingEntry(NewRemoteHost string, NewExternalPort uint16, NewProtocol string) (NewInternalPort uint16, NewInternalClient string, NewEnabled bool, NewPortMappingDescription string, NewLeaseDuration uint32, err error) {
+ // Request structure.
+ request := &struct {
+ NewRemoteHost string
+
+ NewExternalPort string
+
+ NewProtocol string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewRemoteHost, err = soap.MarshalString(NewRemoteHost); err != nil {
+ return
+ }
+ if request.NewExternalPort, err = soap.MarshalUi2(NewExternalPort); err != nil {
+ return
+ }
+ if request.NewProtocol, err = soap.MarshalString(NewProtocol); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewInternalPort string
+
+ NewInternalClient string
+
+ NewEnabled string
+
+ NewPortMappingDescription string
+
+ NewLeaseDuration string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPConnection_2, "GetSpecificPortMappingEntry", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewInternalPort, err = soap.UnmarshalUi2(response.NewInternalPort); err != nil {
+ return
+ }
+ if NewInternalClient, err = soap.UnmarshalString(response.NewInternalClient); err != nil {
+ return
+ }
+ if NewEnabled, err = soap.UnmarshalBoolean(response.NewEnabled); err != nil {
+ return
+ }
+ if NewPortMappingDescription, err = soap.UnmarshalString(response.NewPortMappingDescription); err != nil {
+ return
+ }
+ if NewLeaseDuration, err = soap.UnmarshalUi4(response.NewLeaseDuration); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewRemoteHost:
+//
+// * NewExternalPort:
+//
+// * NewProtocol: allowed values: TCP, UDP
+//
+// * NewInternalPort: allowed value range: minimum=1, maximum=65535
+//
+// * NewInternalClient:
+//
+// * NewEnabled:
+//
+// * NewPortMappingDescription:
+//
+// * NewLeaseDuration: allowed value range: minimum=0, maximum=604800
+//
+//
+func (client *WANIPConnection2) AddPortMapping(NewRemoteHost string, NewExternalPort uint16, NewProtocol string, NewInternalPort uint16, NewInternalClient string, NewEnabled bool, NewPortMappingDescription string, NewLeaseDuration uint32) (err error) {
+ // Request structure.
+ request := &struct {
+ NewRemoteHost string
+
+ NewExternalPort string
+
+ NewProtocol string
+
+ NewInternalPort string
+
+ NewInternalClient string
+
+ NewEnabled string
+
+ NewPortMappingDescription string
+
+ NewLeaseDuration string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewRemoteHost, err = soap.MarshalString(NewRemoteHost); err != nil {
+ return
+ }
+ if request.NewExternalPort, err = soap.MarshalUi2(NewExternalPort); err != nil {
+ return
+ }
+ if request.NewProtocol, err = soap.MarshalString(NewProtocol); err != nil {
+ return
+ }
+ if request.NewInternalPort, err = soap.MarshalUi2(NewInternalPort); err != nil {
+ return
+ }
+ if request.NewInternalClient, err = soap.MarshalString(NewInternalClient); err != nil {
+ return
+ }
+ if request.NewEnabled, err = soap.MarshalBoolean(NewEnabled); err != nil {
+ return
+ }
+ if request.NewPortMappingDescription, err = soap.MarshalString(NewPortMappingDescription); err != nil {
+ return
+ }
+ if request.NewLeaseDuration, err = soap.MarshalUi4(NewLeaseDuration); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPConnection_2, "AddPortMapping", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewRemoteHost:
+//
+// * NewExternalPort:
+//
+// * NewProtocol: allowed values: TCP, UDP
+//
+//
+func (client *WANIPConnection2) DeletePortMapping(NewRemoteHost string, NewExternalPort uint16, NewProtocol string) (err error) {
+ // Request structure.
+ request := &struct {
+ NewRemoteHost string
+
+ NewExternalPort string
+
+ NewProtocol string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewRemoteHost, err = soap.MarshalString(NewRemoteHost); err != nil {
+ return
+ }
+ if request.NewExternalPort, err = soap.MarshalUi2(NewExternalPort); err != nil {
+ return
+ }
+ if request.NewProtocol, err = soap.MarshalString(NewProtocol); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPConnection_2, "DeletePortMapping", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewStartPort:
+//
+// * NewEndPort:
+//
+// * NewProtocol: allowed values: TCP, UDP
+//
+// * NewManage:
+//
+//
+func (client *WANIPConnection2) DeletePortMappingRange(NewStartPort uint16, NewEndPort uint16, NewProtocol string, NewManage bool) (err error) {
+ // Request structure.
+ request := &struct {
+ NewStartPort string
+
+ NewEndPort string
+
+ NewProtocol string
+
+ NewManage string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewStartPort, err = soap.MarshalUi2(NewStartPort); err != nil {
+ return
+ }
+ if request.NewEndPort, err = soap.MarshalUi2(NewEndPort); err != nil {
+ return
+ }
+ if request.NewProtocol, err = soap.MarshalString(NewProtocol); err != nil {
+ return
+ }
+ if request.NewManage, err = soap.MarshalBoolean(NewManage); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPConnection_2, "DeletePortMappingRange", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewExternalIPAddress:
+func (client *WANIPConnection2) GetExternalIPAddress() (NewExternalIPAddress string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewExternalIPAddress string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPConnection_2, "GetExternalIPAddress", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewExternalIPAddress, err = soap.UnmarshalString(response.NewExternalIPAddress); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewStartPort:
+//
+// * NewEndPort:
+//
+// * NewProtocol: allowed values: TCP, UDP
+//
+// * NewManage:
+//
+// * NewNumberOfPorts:
+//
+// Return values:
+//
+// * NewPortListing:
+func (client *WANIPConnection2) GetListOfPortMappings(NewStartPort uint16, NewEndPort uint16, NewProtocol string, NewManage bool, NewNumberOfPorts uint16) (NewPortListing string, err error) {
+ // Request structure.
+ request := &struct {
+ NewStartPort string
+
+ NewEndPort string
+
+ NewProtocol string
+
+ NewManage string
+
+ NewNumberOfPorts string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewStartPort, err = soap.MarshalUi2(NewStartPort); err != nil {
+ return
+ }
+ if request.NewEndPort, err = soap.MarshalUi2(NewEndPort); err != nil {
+ return
+ }
+ if request.NewProtocol, err = soap.MarshalString(NewProtocol); err != nil {
+ return
+ }
+ if request.NewManage, err = soap.MarshalBoolean(NewManage); err != nil {
+ return
+ }
+ if request.NewNumberOfPorts, err = soap.MarshalUi2(NewNumberOfPorts); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewPortListing string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPConnection_2, "GetListOfPortMappings", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewPortListing, err = soap.UnmarshalString(response.NewPortListing); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewRemoteHost:
+//
+// * NewExternalPort:
+//
+// * NewProtocol: allowed values: TCP, UDP
+//
+// * NewInternalPort: allowed value range: minimum=1, maximum=65535
+//
+// * NewInternalClient:
+//
+// * NewEnabled:
+//
+// * NewPortMappingDescription:
+//
+// * NewLeaseDuration: allowed value range: minimum=0, maximum=604800
+//
+// Return values:
+//
+// * NewReservedPort:
+func (client *WANIPConnection2) AddAnyPortMapping(NewRemoteHost string, NewExternalPort uint16, NewProtocol string, NewInternalPort uint16, NewInternalClient string, NewEnabled bool, NewPortMappingDescription string, NewLeaseDuration uint32) (NewReservedPort uint16, err error) {
+ // Request structure.
+ request := &struct {
+ NewRemoteHost string
+
+ NewExternalPort string
+
+ NewProtocol string
+
+ NewInternalPort string
+
+ NewInternalClient string
+
+ NewEnabled string
+
+ NewPortMappingDescription string
+
+ NewLeaseDuration string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewRemoteHost, err = soap.MarshalString(NewRemoteHost); err != nil {
+ return
+ }
+ if request.NewExternalPort, err = soap.MarshalUi2(NewExternalPort); err != nil {
+ return
+ }
+ if request.NewProtocol, err = soap.MarshalString(NewProtocol); err != nil {
+ return
+ }
+ if request.NewInternalPort, err = soap.MarshalUi2(NewInternalPort); err != nil {
+ return
+ }
+ if request.NewInternalClient, err = soap.MarshalString(NewInternalClient); err != nil {
+ return
+ }
+ if request.NewEnabled, err = soap.MarshalBoolean(NewEnabled); err != nil {
+ return
+ }
+ if request.NewPortMappingDescription, err = soap.MarshalString(NewPortMappingDescription); err != nil {
+ return
+ }
+ if request.NewLeaseDuration, err = soap.MarshalUi4(NewLeaseDuration); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewReservedPort string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPConnection_2, "AddAnyPortMapping", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewReservedPort, err = soap.UnmarshalUi2(response.NewReservedPort); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// WANIPv6FirewallControl1 is a client for UPnP SOAP service with URN "urn:schemas-upnp-org:service:WANIPv6FirewallControl:1". See
+// goupnp.ServiceClient, which contains RootDevice and Service attributes which
+// are provided for informational value.
+type WANIPv6FirewallControl1 struct {
+ goupnp.ServiceClient
+}
+
+// NewWANIPv6FirewallControl1Clients discovers instances of the service on the network,
+// and returns clients to any that are found. errors will contain an error for
+// any devices that replied but which could not be queried, and err will be set
+// if the discovery process failed outright.
+//
+// This is a typical entry calling point into this package.
+func NewWANIPv6FirewallControl1Clients() (clients []*WANIPv6FirewallControl1, errors []error, err error) {
+ var genericClients []goupnp.ServiceClient
+ if genericClients, errors, err = goupnp.NewServiceClients(URN_WANIPv6FirewallControl_1); err != nil {
+ return
+ }
+ clients = make([]*WANIPv6FirewallControl1, len(genericClients))
+ for i := range genericClients {
+ clients[i] = &WANIPv6FirewallControl1{genericClients[i]}
+ }
+ return
+}
+
+//
+//
+// Return values:
+//
+// * FirewallEnabled:
+//
+// * InboundPinholeAllowed:
+func (client *WANIPv6FirewallControl1) GetFirewallStatus() (FirewallEnabled bool, InboundPinholeAllowed bool, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ FirewallEnabled string
+
+ InboundPinholeAllowed string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPv6FirewallControl_1, "GetFirewallStatus", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if FirewallEnabled, err = soap.UnmarshalBoolean(response.FirewallEnabled); err != nil {
+ return
+ }
+ if InboundPinholeAllowed, err = soap.UnmarshalBoolean(response.InboundPinholeAllowed); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * RemoteHost:
+//
+// * RemotePort:
+//
+// * InternalClient:
+//
+// * InternalPort:
+//
+// * Protocol:
+//
+// Return values:
+//
+// * OutboundPinholeTimeout:
+func (client *WANIPv6FirewallControl1) GetOutboundPinholeTimeout(RemoteHost string, RemotePort uint16, InternalClient string, InternalPort uint16, Protocol uint16) (OutboundPinholeTimeout uint32, err error) {
+ // Request structure.
+ request := &struct {
+ RemoteHost string
+
+ RemotePort string
+
+ InternalClient string
+
+ InternalPort string
+
+ Protocol string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.RemoteHost, err = soap.MarshalString(RemoteHost); err != nil {
+ return
+ }
+ if request.RemotePort, err = soap.MarshalUi2(RemotePort); err != nil {
+ return
+ }
+ if request.InternalClient, err = soap.MarshalString(InternalClient); err != nil {
+ return
+ }
+ if request.InternalPort, err = soap.MarshalUi2(InternalPort); err != nil {
+ return
+ }
+ if request.Protocol, err = soap.MarshalUi2(Protocol); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ OutboundPinholeTimeout string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPv6FirewallControl_1, "GetOutboundPinholeTimeout", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if OutboundPinholeTimeout, err = soap.UnmarshalUi4(response.OutboundPinholeTimeout); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * RemoteHost:
+//
+// * RemotePort:
+//
+// * InternalClient:
+//
+// * InternalPort:
+//
+// * Protocol:
+//
+// * LeaseTime: allowed value range: minimum=1, maximum=86400
+//
+// Return values:
+//
+// * UniqueID:
+func (client *WANIPv6FirewallControl1) AddPinhole(RemoteHost string, RemotePort uint16, InternalClient string, InternalPort uint16, Protocol uint16, LeaseTime uint32) (UniqueID uint16, err error) {
+ // Request structure.
+ request := &struct {
+ RemoteHost string
+
+ RemotePort string
+
+ InternalClient string
+
+ InternalPort string
+
+ Protocol string
+
+ LeaseTime string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.RemoteHost, err = soap.MarshalString(RemoteHost); err != nil {
+ return
+ }
+ if request.RemotePort, err = soap.MarshalUi2(RemotePort); err != nil {
+ return
+ }
+ if request.InternalClient, err = soap.MarshalString(InternalClient); err != nil {
+ return
+ }
+ if request.InternalPort, err = soap.MarshalUi2(InternalPort); err != nil {
+ return
+ }
+ if request.Protocol, err = soap.MarshalUi2(Protocol); err != nil {
+ return
+ }
+ if request.LeaseTime, err = soap.MarshalUi4(LeaseTime); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ UniqueID string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPv6FirewallControl_1, "AddPinhole", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if UniqueID, err = soap.UnmarshalUi2(response.UniqueID); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * UniqueID:
+//
+// * NewLeaseTime: allowed value range: minimum=1, maximum=86400
+//
+//
+func (client *WANIPv6FirewallControl1) UpdatePinhole(UniqueID uint16, NewLeaseTime uint32) (err error) {
+ // Request structure.
+ request := &struct {
+ UniqueID string
+
+ NewLeaseTime string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.UniqueID, err = soap.MarshalUi2(UniqueID); err != nil {
+ return
+ }
+ if request.NewLeaseTime, err = soap.MarshalUi4(NewLeaseTime); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPv6FirewallControl_1, "UpdatePinhole", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * UniqueID:
+//
+//
+func (client *WANIPv6FirewallControl1) DeletePinhole(UniqueID uint16) (err error) {
+ // Request structure.
+ request := &struct {
+ UniqueID string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.UniqueID, err = soap.MarshalUi2(UniqueID); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPv6FirewallControl_1, "DeletePinhole", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * UniqueID:
+//
+// Return values:
+//
+// * PinholePackets:
+func (client *WANIPv6FirewallControl1) GetPinholePackets(UniqueID uint16) (PinholePackets uint32, err error) {
+ // Request structure.
+ request := &struct {
+ UniqueID string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.UniqueID, err = soap.MarshalUi2(UniqueID); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ PinholePackets string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPv6FirewallControl_1, "GetPinholePackets", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if PinholePackets, err = soap.UnmarshalUi4(response.PinholePackets); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * UniqueID:
+//
+// Return values:
+//
+// * IsWorking:
+func (client *WANIPv6FirewallControl1) CheckPinholeWorking(UniqueID uint16) (IsWorking bool, err error) {
+ // Request structure.
+ request := &struct {
+ UniqueID string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.UniqueID, err = soap.MarshalUi2(UniqueID); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ IsWorking string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANIPv6FirewallControl_1, "CheckPinholeWorking", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if IsWorking, err = soap.UnmarshalBoolean(response.IsWorking); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// WANPOTSLinkConfig1 is a client for UPnP SOAP service with URN "urn:schemas-upnp-org:service:WANPOTSLinkConfig:1". See
+// goupnp.ServiceClient, which contains RootDevice and Service attributes which
+// are provided for informational value.
+type WANPOTSLinkConfig1 struct {
+ goupnp.ServiceClient
+}
+
+// NewWANPOTSLinkConfig1Clients discovers instances of the service on the network,
+// and returns clients to any that are found. errors will contain an error for
+// any devices that replied but which could not be queried, and err will be set
+// if the discovery process failed outright.
+//
+// This is a typical entry calling point into this package.
+func NewWANPOTSLinkConfig1Clients() (clients []*WANPOTSLinkConfig1, errors []error, err error) {
+ var genericClients []goupnp.ServiceClient
+ if genericClients, errors, err = goupnp.NewServiceClients(URN_WANPOTSLinkConfig_1); err != nil {
+ return
+ }
+ clients = make([]*WANPOTSLinkConfig1, len(genericClients))
+ for i := range genericClients {
+ clients[i] = &WANPOTSLinkConfig1{genericClients[i]}
+ }
+ return
+}
+
+// Arguments:
+//
+// * NewISPPhoneNumber:
+//
+// * NewISPInfo:
+//
+// * NewLinkType: allowed values: PPP_Dialup
+//
+//
+func (client *WANPOTSLinkConfig1) SetISPInfo(NewISPPhoneNumber string, NewISPInfo string, NewLinkType string) (err error) {
+ // Request structure.
+ request := &struct {
+ NewISPPhoneNumber string
+
+ NewISPInfo string
+
+ NewLinkType string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewISPPhoneNumber, err = soap.MarshalString(NewISPPhoneNumber); err != nil {
+ return
+ }
+ if request.NewISPInfo, err = soap.MarshalString(NewISPInfo); err != nil {
+ return
+ }
+ if request.NewLinkType, err = soap.MarshalString(NewLinkType); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPOTSLinkConfig_1, "SetISPInfo", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewNumberOfRetries:
+//
+// * NewDelayBetweenRetries:
+//
+//
+func (client *WANPOTSLinkConfig1) SetCallRetryInfo(NewNumberOfRetries uint32, NewDelayBetweenRetries uint32) (err error) {
+ // Request structure.
+ request := &struct {
+ NewNumberOfRetries string
+
+ NewDelayBetweenRetries string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewNumberOfRetries, err = soap.MarshalUi4(NewNumberOfRetries); err != nil {
+ return
+ }
+ if request.NewDelayBetweenRetries, err = soap.MarshalUi4(NewDelayBetweenRetries); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPOTSLinkConfig_1, "SetCallRetryInfo", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewISPPhoneNumber:
+//
+// * NewISPInfo:
+//
+// * NewLinkType: allowed values: PPP_Dialup
+func (client *WANPOTSLinkConfig1) GetISPInfo() (NewISPPhoneNumber string, NewISPInfo string, NewLinkType string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewISPPhoneNumber string
+
+ NewISPInfo string
+
+ NewLinkType string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPOTSLinkConfig_1, "GetISPInfo", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewISPPhoneNumber, err = soap.UnmarshalString(response.NewISPPhoneNumber); err != nil {
+ return
+ }
+ if NewISPInfo, err = soap.UnmarshalString(response.NewISPInfo); err != nil {
+ return
+ }
+ if NewLinkType, err = soap.UnmarshalString(response.NewLinkType); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewNumberOfRetries:
+//
+// * NewDelayBetweenRetries:
+func (client *WANPOTSLinkConfig1) GetCallRetryInfo() (NewNumberOfRetries uint32, NewDelayBetweenRetries uint32, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewNumberOfRetries string
+
+ NewDelayBetweenRetries string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPOTSLinkConfig_1, "GetCallRetryInfo", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewNumberOfRetries, err = soap.UnmarshalUi4(response.NewNumberOfRetries); err != nil {
+ return
+ }
+ if NewDelayBetweenRetries, err = soap.UnmarshalUi4(response.NewDelayBetweenRetries); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewFclass:
+func (client *WANPOTSLinkConfig1) GetFclass() (NewFclass string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewFclass string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPOTSLinkConfig_1, "GetFclass", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewFclass, err = soap.UnmarshalString(response.NewFclass); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewDataModulationSupported:
+func (client *WANPOTSLinkConfig1) GetDataModulationSupported() (NewDataModulationSupported string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewDataModulationSupported string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPOTSLinkConfig_1, "GetDataModulationSupported", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewDataModulationSupported, err = soap.UnmarshalString(response.NewDataModulationSupported); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewDataProtocol:
+func (client *WANPOTSLinkConfig1) GetDataProtocol() (NewDataProtocol string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewDataProtocol string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPOTSLinkConfig_1, "GetDataProtocol", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewDataProtocol, err = soap.UnmarshalString(response.NewDataProtocol); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewDataCompression:
+func (client *WANPOTSLinkConfig1) GetDataCompression() (NewDataCompression string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewDataCompression string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPOTSLinkConfig_1, "GetDataCompression", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewDataCompression, err = soap.UnmarshalString(response.NewDataCompression); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewPlusVTRCommandSupported:
+func (client *WANPOTSLinkConfig1) GetPlusVTRCommandSupported() (NewPlusVTRCommandSupported bool, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewPlusVTRCommandSupported string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPOTSLinkConfig_1, "GetPlusVTRCommandSupported", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewPlusVTRCommandSupported, err = soap.UnmarshalBoolean(response.NewPlusVTRCommandSupported); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// WANPPPConnection1 is a client for UPnP SOAP service with URN "urn:schemas-upnp-org:service:WANPPPConnection:1". See
+// goupnp.ServiceClient, which contains RootDevice and Service attributes which
+// are provided for informational value.
+type WANPPPConnection1 struct {
+ goupnp.ServiceClient
+}
+
+// NewWANPPPConnection1Clients discovers instances of the service on the network,
+// and returns clients to any that are found. errors will contain an error for
+// any devices that replied but which could not be queried, and err will be set
+// if the discovery process failed outright.
+//
+// This is a typical entry calling point into this package.
+func NewWANPPPConnection1Clients() (clients []*WANPPPConnection1, errors []error, err error) {
+ var genericClients []goupnp.ServiceClient
+ if genericClients, errors, err = goupnp.NewServiceClients(URN_WANPPPConnection_1); err != nil {
+ return
+ }
+ clients = make([]*WANPPPConnection1, len(genericClients))
+ for i := range genericClients {
+ clients[i] = &WANPPPConnection1{genericClients[i]}
+ }
+ return
+}
+
+// Arguments:
+//
+// * NewConnectionType:
+//
+//
+func (client *WANPPPConnection1) SetConnectionType(NewConnectionType string) (err error) {
+ // Request structure.
+ request := &struct {
+ NewConnectionType string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewConnectionType, err = soap.MarshalString(NewConnectionType); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPPPConnection_1, "SetConnectionType", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewConnectionType:
+//
+// * NewPossibleConnectionTypes: allowed values: Unconfigured, IP_Routed, DHCP_Spoofed, PPPoE_Bridged, PPTP_Relay, L2TP_Relay, PPPoE_Relay
+func (client *WANPPPConnection1) GetConnectionTypeInfo() (NewConnectionType string, NewPossibleConnectionTypes string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewConnectionType string
+
+ NewPossibleConnectionTypes string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPPPConnection_1, "GetConnectionTypeInfo", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewConnectionType, err = soap.UnmarshalString(response.NewConnectionType); err != nil {
+ return
+ }
+ if NewPossibleConnectionTypes, err = soap.UnmarshalString(response.NewPossibleConnectionTypes); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewUserName:
+//
+// * NewPassword:
+//
+//
+func (client *WANPPPConnection1) ConfigureConnection(NewUserName string, NewPassword string) (err error) {
+ // Request structure.
+ request := &struct {
+ NewUserName string
+
+ NewPassword string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewUserName, err = soap.MarshalString(NewUserName); err != nil {
+ return
+ }
+ if request.NewPassword, err = soap.MarshalString(NewPassword); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPPPConnection_1, "ConfigureConnection", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+//
+func (client *WANPPPConnection1) RequestConnection() (err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPPPConnection_1, "RequestConnection", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+//
+func (client *WANPPPConnection1) RequestTermination() (err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPPPConnection_1, "RequestTermination", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+//
+func (client *WANPPPConnection1) ForceTermination() (err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPPPConnection_1, "ForceTermination", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewAutoDisconnectTime:
+//
+//
+func (client *WANPPPConnection1) SetAutoDisconnectTime(NewAutoDisconnectTime uint32) (err error) {
+ // Request structure.
+ request := &struct {
+ NewAutoDisconnectTime string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewAutoDisconnectTime, err = soap.MarshalUi4(NewAutoDisconnectTime); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPPPConnection_1, "SetAutoDisconnectTime", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewIdleDisconnectTime:
+//
+//
+func (client *WANPPPConnection1) SetIdleDisconnectTime(NewIdleDisconnectTime uint32) (err error) {
+ // Request structure.
+ request := &struct {
+ NewIdleDisconnectTime string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewIdleDisconnectTime, err = soap.MarshalUi4(NewIdleDisconnectTime); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPPPConnection_1, "SetIdleDisconnectTime", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewWarnDisconnectDelay:
+//
+//
+func (client *WANPPPConnection1) SetWarnDisconnectDelay(NewWarnDisconnectDelay uint32) (err error) {
+ // Request structure.
+ request := &struct {
+ NewWarnDisconnectDelay string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewWarnDisconnectDelay, err = soap.MarshalUi4(NewWarnDisconnectDelay); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPPPConnection_1, "SetWarnDisconnectDelay", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewConnectionStatus: allowed values: Unconfigured, Connected, Disconnected
+//
+// * NewLastConnectionError: allowed values: ERROR_NONE
+//
+// * NewUptime:
+func (client *WANPPPConnection1) GetStatusInfo() (NewConnectionStatus string, NewLastConnectionError string, NewUptime uint32, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewConnectionStatus string
+
+ NewLastConnectionError string
+
+ NewUptime string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPPPConnection_1, "GetStatusInfo", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewConnectionStatus, err = soap.UnmarshalString(response.NewConnectionStatus); err != nil {
+ return
+ }
+ if NewLastConnectionError, err = soap.UnmarshalString(response.NewLastConnectionError); err != nil {
+ return
+ }
+ if NewUptime, err = soap.UnmarshalUi4(response.NewUptime); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewUpstreamMaxBitRate:
+//
+// * NewDownstreamMaxBitRate:
+func (client *WANPPPConnection1) GetLinkLayerMaxBitRates() (NewUpstreamMaxBitRate uint32, NewDownstreamMaxBitRate uint32, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewUpstreamMaxBitRate string
+
+ NewDownstreamMaxBitRate string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPPPConnection_1, "GetLinkLayerMaxBitRates", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewUpstreamMaxBitRate, err = soap.UnmarshalUi4(response.NewUpstreamMaxBitRate); err != nil {
+ return
+ }
+ if NewDownstreamMaxBitRate, err = soap.UnmarshalUi4(response.NewDownstreamMaxBitRate); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewPPPEncryptionProtocol:
+func (client *WANPPPConnection1) GetPPPEncryptionProtocol() (NewPPPEncryptionProtocol string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewPPPEncryptionProtocol string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPPPConnection_1, "GetPPPEncryptionProtocol", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewPPPEncryptionProtocol, err = soap.UnmarshalString(response.NewPPPEncryptionProtocol); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewPPPCompressionProtocol:
+func (client *WANPPPConnection1) GetPPPCompressionProtocol() (NewPPPCompressionProtocol string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewPPPCompressionProtocol string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPPPConnection_1, "GetPPPCompressionProtocol", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewPPPCompressionProtocol, err = soap.UnmarshalString(response.NewPPPCompressionProtocol); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewPPPAuthenticationProtocol:
+func (client *WANPPPConnection1) GetPPPAuthenticationProtocol() (NewPPPAuthenticationProtocol string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewPPPAuthenticationProtocol string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPPPConnection_1, "GetPPPAuthenticationProtocol", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewPPPAuthenticationProtocol, err = soap.UnmarshalString(response.NewPPPAuthenticationProtocol); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewUserName:
+func (client *WANPPPConnection1) GetUserName() (NewUserName string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewUserName string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPPPConnection_1, "GetUserName", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewUserName, err = soap.UnmarshalString(response.NewUserName); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewPassword:
+func (client *WANPPPConnection1) GetPassword() (NewPassword string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewPassword string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPPPConnection_1, "GetPassword", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewPassword, err = soap.UnmarshalString(response.NewPassword); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewAutoDisconnectTime:
+func (client *WANPPPConnection1) GetAutoDisconnectTime() (NewAutoDisconnectTime uint32, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewAutoDisconnectTime string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPPPConnection_1, "GetAutoDisconnectTime", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewAutoDisconnectTime, err = soap.UnmarshalUi4(response.NewAutoDisconnectTime); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewIdleDisconnectTime:
+func (client *WANPPPConnection1) GetIdleDisconnectTime() (NewIdleDisconnectTime uint32, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewIdleDisconnectTime string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPPPConnection_1, "GetIdleDisconnectTime", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewIdleDisconnectTime, err = soap.UnmarshalUi4(response.NewIdleDisconnectTime); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewWarnDisconnectDelay:
+func (client *WANPPPConnection1) GetWarnDisconnectDelay() (NewWarnDisconnectDelay uint32, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewWarnDisconnectDelay string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPPPConnection_1, "GetWarnDisconnectDelay", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewWarnDisconnectDelay, err = soap.UnmarshalUi4(response.NewWarnDisconnectDelay); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewRSIPAvailable:
+//
+// * NewNATEnabled:
+func (client *WANPPPConnection1) GetNATRSIPStatus() (NewRSIPAvailable bool, NewNATEnabled bool, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewRSIPAvailable string
+
+ NewNATEnabled string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPPPConnection_1, "GetNATRSIPStatus", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewRSIPAvailable, err = soap.UnmarshalBoolean(response.NewRSIPAvailable); err != nil {
+ return
+ }
+ if NewNATEnabled, err = soap.UnmarshalBoolean(response.NewNATEnabled); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewPortMappingIndex:
+//
+// Return values:
+//
+// * NewRemoteHost:
+//
+// * NewExternalPort:
+//
+// * NewProtocol: allowed values: TCP, UDP
+//
+// * NewInternalPort:
+//
+// * NewInternalClient:
+//
+// * NewEnabled:
+//
+// * NewPortMappingDescription:
+//
+// * NewLeaseDuration:
+func (client *WANPPPConnection1) GetGenericPortMappingEntry(NewPortMappingIndex uint16) (NewRemoteHost string, NewExternalPort uint16, NewProtocol string, NewInternalPort uint16, NewInternalClient string, NewEnabled bool, NewPortMappingDescription string, NewLeaseDuration uint32, err error) {
+ // Request structure.
+ request := &struct {
+ NewPortMappingIndex string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewPortMappingIndex, err = soap.MarshalUi2(NewPortMappingIndex); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewRemoteHost string
+
+ NewExternalPort string
+
+ NewProtocol string
+
+ NewInternalPort string
+
+ NewInternalClient string
+
+ NewEnabled string
+
+ NewPortMappingDescription string
+
+ NewLeaseDuration string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPPPConnection_1, "GetGenericPortMappingEntry", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewRemoteHost, err = soap.UnmarshalString(response.NewRemoteHost); err != nil {
+ return
+ }
+ if NewExternalPort, err = soap.UnmarshalUi2(response.NewExternalPort); err != nil {
+ return
+ }
+ if NewProtocol, err = soap.UnmarshalString(response.NewProtocol); err != nil {
+ return
+ }
+ if NewInternalPort, err = soap.UnmarshalUi2(response.NewInternalPort); err != nil {
+ return
+ }
+ if NewInternalClient, err = soap.UnmarshalString(response.NewInternalClient); err != nil {
+ return
+ }
+ if NewEnabled, err = soap.UnmarshalBoolean(response.NewEnabled); err != nil {
+ return
+ }
+ if NewPortMappingDescription, err = soap.UnmarshalString(response.NewPortMappingDescription); err != nil {
+ return
+ }
+ if NewLeaseDuration, err = soap.UnmarshalUi4(response.NewLeaseDuration); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewRemoteHost:
+//
+// * NewExternalPort:
+//
+// * NewProtocol: allowed values: TCP, UDP
+//
+// Return values:
+//
+// * NewInternalPort:
+//
+// * NewInternalClient:
+//
+// * NewEnabled:
+//
+// * NewPortMappingDescription:
+//
+// * NewLeaseDuration:
+func (client *WANPPPConnection1) GetSpecificPortMappingEntry(NewRemoteHost string, NewExternalPort uint16, NewProtocol string) (NewInternalPort uint16, NewInternalClient string, NewEnabled bool, NewPortMappingDescription string, NewLeaseDuration uint32, err error) {
+ // Request structure.
+ request := &struct {
+ NewRemoteHost string
+
+ NewExternalPort string
+
+ NewProtocol string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewRemoteHost, err = soap.MarshalString(NewRemoteHost); err != nil {
+ return
+ }
+ if request.NewExternalPort, err = soap.MarshalUi2(NewExternalPort); err != nil {
+ return
+ }
+ if request.NewProtocol, err = soap.MarshalString(NewProtocol); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewInternalPort string
+
+ NewInternalClient string
+
+ NewEnabled string
+
+ NewPortMappingDescription string
+
+ NewLeaseDuration string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPPPConnection_1, "GetSpecificPortMappingEntry", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewInternalPort, err = soap.UnmarshalUi2(response.NewInternalPort); err != nil {
+ return
+ }
+ if NewInternalClient, err = soap.UnmarshalString(response.NewInternalClient); err != nil {
+ return
+ }
+ if NewEnabled, err = soap.UnmarshalBoolean(response.NewEnabled); err != nil {
+ return
+ }
+ if NewPortMappingDescription, err = soap.UnmarshalString(response.NewPortMappingDescription); err != nil {
+ return
+ }
+ if NewLeaseDuration, err = soap.UnmarshalUi4(response.NewLeaseDuration); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewRemoteHost:
+//
+// * NewExternalPort:
+//
+// * NewProtocol: allowed values: TCP, UDP
+//
+// * NewInternalPort:
+//
+// * NewInternalClient:
+//
+// * NewEnabled:
+//
+// * NewPortMappingDescription:
+//
+// * NewLeaseDuration:
+//
+//
+func (client *WANPPPConnection1) AddPortMapping(NewRemoteHost string, NewExternalPort uint16, NewProtocol string, NewInternalPort uint16, NewInternalClient string, NewEnabled bool, NewPortMappingDescription string, NewLeaseDuration uint32) (err error) {
+ // Request structure.
+ request := &struct {
+ NewRemoteHost string
+
+ NewExternalPort string
+
+ NewProtocol string
+
+ NewInternalPort string
+
+ NewInternalClient string
+
+ NewEnabled string
+
+ NewPortMappingDescription string
+
+ NewLeaseDuration string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewRemoteHost, err = soap.MarshalString(NewRemoteHost); err != nil {
+ return
+ }
+ if request.NewExternalPort, err = soap.MarshalUi2(NewExternalPort); err != nil {
+ return
+ }
+ if request.NewProtocol, err = soap.MarshalString(NewProtocol); err != nil {
+ return
+ }
+ if request.NewInternalPort, err = soap.MarshalUi2(NewInternalPort); err != nil {
+ return
+ }
+ if request.NewInternalClient, err = soap.MarshalString(NewInternalClient); err != nil {
+ return
+ }
+ if request.NewEnabled, err = soap.MarshalBoolean(NewEnabled); err != nil {
+ return
+ }
+ if request.NewPortMappingDescription, err = soap.MarshalString(NewPortMappingDescription); err != nil {
+ return
+ }
+ if request.NewLeaseDuration, err = soap.MarshalUi4(NewLeaseDuration); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPPPConnection_1, "AddPortMapping", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+// Arguments:
+//
+// * NewRemoteHost:
+//
+// * NewExternalPort:
+//
+// * NewProtocol: allowed values: TCP, UDP
+//
+//
+func (client *WANPPPConnection1) DeletePortMapping(NewRemoteHost string, NewExternalPort uint16, NewProtocol string) (err error) {
+ // Request structure.
+ request := &struct {
+ NewRemoteHost string
+
+ NewExternalPort string
+
+ NewProtocol string
+ }{}
+ // BEGIN Marshal arguments into request.
+
+ if request.NewRemoteHost, err = soap.MarshalString(NewRemoteHost); err != nil {
+ return
+ }
+ if request.NewExternalPort, err = soap.MarshalUi2(NewExternalPort); err != nil {
+ return
+ }
+ if request.NewProtocol, err = soap.MarshalString(NewProtocol); err != nil {
+ return
+ }
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := interface{}(nil)
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPPPConnection_1, "DeletePortMapping", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ // END Unmarshal arguments from response.
+ return
+}
+
+//
+//
+// Return values:
+//
+// * NewExternalIPAddress:
+func (client *WANPPPConnection1) GetExternalIPAddress() (NewExternalIPAddress string, err error) {
+ // Request structure.
+ request := interface{}(nil)
+ // BEGIN Marshal arguments into request.
+
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := &struct {
+ NewExternalIPAddress string
+ }{}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction(URN_WANPPPConnection_1, "GetExternalIPAddress", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+
+ if NewExternalIPAddress, err = soap.UnmarshalString(response.NewExternalIPAddress); err != nil {
+ return
+ }
+ // END Unmarshal arguments from response.
+ return
+}
diff --git a/Godeps/_workspace/src/github.com/huin/goupnp/device.go b/Godeps/_workspace/src/github.com/huin/goupnp/device.go
new file mode 100644
index 000000000..e5b658b21
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/huin/goupnp/device.go
@@ -0,0 +1,184 @@
+// This file contains XML structures for communicating with UPnP devices.
+
+package goupnp
+
+import (
+ "encoding/xml"
+ "errors"
+ "fmt"
+ "net/url"
+
+ "github.com/huin/goupnp/scpd"
+ "github.com/huin/goupnp/soap"
+)
+
+const (
+ DeviceXMLNamespace = "urn:schemas-upnp-org:device-1-0"
+)
+
+// RootDevice is the device description as described by section 2.3 "Device
+// description" in
+// http://upnp.org/specs/arch/UPnP-arch-DeviceArchitecture-v1.1.pdf
+type RootDevice struct {
+ XMLName xml.Name `xml:"root"`
+ SpecVersion SpecVersion `xml:"specVersion"`
+ URLBase url.URL `xml:"-"`
+ URLBaseStr string `xml:"URLBase"`
+ Device Device `xml:"device"`
+}
+
+// SetURLBase sets the URLBase for the RootDevice and its underlying components.
+func (root *RootDevice) SetURLBase(urlBase *url.URL) {
+ root.URLBase = *urlBase
+ root.URLBaseStr = urlBase.String()
+ root.Device.SetURLBase(urlBase)
+}
+
+// SpecVersion is part of a RootDevice, describes the version of the
+// specification that the data adheres to.
+type SpecVersion struct {
+ Major int32 `xml:"major"`
+ Minor int32 `xml:"minor"`
+}
+
+// Device is a UPnP device. It can have child devices.
+type Device struct {
+ DeviceType string `xml:"deviceType"`
+ FriendlyName string `xml:"friendlyName"`
+ Manufacturer string `xml:"manufacturer"`
+ ManufacturerURL URLField `xml:"manufacturerURL"`
+ ModelDescription string `xml:"modelDescription"`
+ ModelName string `xml:"modelName"`
+ ModelNumber string `xml:"modelNumber"`
+ ModelURL URLField `xml:"modelURL"`
+ SerialNumber string `xml:"serialNumber"`
+ UDN string `xml:"UDN"`
+ UPC string `xml:"UPC,omitempty"`
+ Icons []Icon `xml:"iconList>icon,omitempty"`
+ Services []Service `xml:"serviceList>service,omitempty"`
+ Devices []Device `xml:"deviceList>device,omitempty"`
+
+ // Extra observed elements:
+ PresentationURL URLField `xml:"presentationURL"`
+}
+
+// VisitDevices calls visitor for the device, and all its descendent devices.
+func (device *Device) VisitDevices(visitor func(*Device)) {
+ visitor(device)
+ for i := range device.Devices {
+ device.Devices[i].VisitDevices(visitor)
+ }
+}
+
+// VisitServices calls visitor for all Services under the device and all its
+// descendent devices.
+func (device *Device) VisitServices(visitor func(*Service)) {
+ device.VisitDevices(func(d *Device) {
+ for i := range d.Services {
+ visitor(&d.Services[i])
+ }
+ })
+}
+
+// FindService finds all (if any) Services under the device and its descendents
+// that have the given ServiceType.
+func (device *Device) FindService(serviceType string) []*Service {
+ var services []*Service
+ device.VisitServices(func(s *Service) {
+ if s.ServiceType == serviceType {
+ services = append(services, s)
+ }
+ })
+ return services
+}
+
+// SetURLBase sets the URLBase for the Device and its underlying components.
+func (device *Device) SetURLBase(urlBase *url.URL) {
+ device.ManufacturerURL.SetURLBase(urlBase)
+ device.ModelURL.SetURLBase(urlBase)
+ device.PresentationURL.SetURLBase(urlBase)
+ for i := range device.Icons {
+ device.Icons[i].SetURLBase(urlBase)
+ }
+ for i := range device.Services {
+ device.Services[i].SetURLBase(urlBase)
+ }
+ for i := range device.Devices {
+ device.Devices[i].SetURLBase(urlBase)
+ }
+}
+
+func (device *Device) String() string {
+ return fmt.Sprintf("Device ID %s : %s (%s)", device.UDN, device.DeviceType, device.FriendlyName)
+}
+
+// Icon is a representative image that a device might include in its
+// description.
+type Icon struct {
+ Mimetype string `xml:"mimetype"`
+ Width int32 `xml:"width"`
+ Height int32 `xml:"height"`
+ Depth int32 `xml:"depth"`
+ URL URLField `xml:"url"`
+}
+
+// SetURLBase sets the URLBase for the Icon.
+func (icon *Icon) SetURLBase(url *url.URL) {
+ icon.URL.SetURLBase(url)
+}
+
+// Service is a service provided by a UPnP Device.
+type Service struct {
+ ServiceType string `xml:"serviceType"`
+ ServiceId string `xml:"serviceId"`
+ SCPDURL URLField `xml:"SCPDURL"`
+ ControlURL URLField `xml:"controlURL"`
+ EventSubURL URLField `xml:"eventSubURL"`
+}
+
+// SetURLBase sets the URLBase for the Service.
+func (srv *Service) SetURLBase(urlBase *url.URL) {
+ srv.SCPDURL.SetURLBase(urlBase)
+ srv.ControlURL.SetURLBase(urlBase)
+ srv.EventSubURL.SetURLBase(urlBase)
+}
+
+func (srv *Service) String() string {
+ return fmt.Sprintf("Service ID %s : %s", srv.ServiceId, srv.ServiceType)
+}
+
+// RequestSCDP requests the SCPD (soap actions and state variables description)
+// for the service.
+func (srv *Service) RequestSCDP() (*scpd.SCPD, error) {
+ if !srv.SCPDURL.Ok {
+ return nil, errors.New("bad/missing SCPD URL, or no URLBase has been set")
+ }
+ s := new(scpd.SCPD)
+ if err := requestXml(srv.SCPDURL.URL.String(), scpd.SCPDXMLNamespace, s); err != nil {
+ return nil, err
+ }
+ return s, nil
+}
+
+func (srv *Service) NewSOAPClient() *soap.SOAPClient {
+ return soap.NewSOAPClient(srv.ControlURL.URL)
+}
+
+// URLField is a URL that is part of a device description.
+type URLField struct {
+ URL url.URL `xml:"-"`
+ Ok bool `xml:"-"`
+ Str string `xml:",chardata"`
+}
+
+func (uf *URLField) SetURLBase(urlBase *url.URL) {
+ refUrl, err := url.Parse(uf.Str)
+ if err != nil {
+ uf.URL = url.URL{}
+ uf.Ok = false
+ return
+ }
+
+ uf.URL = *urlBase.ResolveReference(refUrl)
+ uf.Ok = true
+}
diff --git a/Godeps/_workspace/src/github.com/huin/goupnp/example/example.go b/Godeps/_workspace/src/github.com/huin/goupnp/example/example.go
new file mode 100644
index 000000000..df7420226
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/huin/goupnp/example/example.go
@@ -0,0 +1,6 @@
+// Serves as examples of using the goupnp library.
+//
+// To run examples and see the output for your local network, run the following
+// command (specifically including the -v flag):
+// go test -v github.com/huin/goupnp/example
+package example
diff --git a/Godeps/_workspace/src/github.com/huin/goupnp/example/example_test.go b/Godeps/_workspace/src/github.com/huin/goupnp/example/example_test.go
new file mode 100644
index 000000000..1f3667df7
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/huin/goupnp/example/example_test.go
@@ -0,0 +1,62 @@
+package example_test
+
+import (
+ "fmt"
+ "os"
+
+ "github.com/huin/goupnp"
+ "github.com/huin/goupnp/dcps/internetgateway1"
+)
+
+// Use discovered WANPPPConnection1 services to find external IP addresses.
+func Example_WANPPPConnection1_GetExternalIPAddress() {
+ clients, errors, err := internetgateway1.NewWANPPPConnection1Clients()
+ extIPClients := make([]GetExternalIPAddresser, len(clients))
+ for i, client := range clients {
+ extIPClients[i] = client
+ }
+ DisplayExternalIPResults(extIPClients, errors, err)
+ // Output:
+}
+
+// Use discovered WANIPConnection services to find external IP addresses.
+func Example_WANIPConnection_GetExternalIPAddress() {
+ clients, errors, err := internetgateway1.NewWANIPConnection1Clients()
+ extIPClients := make([]GetExternalIPAddresser, len(clients))
+ for i, client := range clients {
+ extIPClients[i] = client
+ }
+ DisplayExternalIPResults(extIPClients, errors, err)
+ // Output:
+}
+
+type GetExternalIPAddresser interface {
+ GetExternalIPAddress() (NewExternalIPAddress string, err error)
+ GetServiceClient() *goupnp.ServiceClient
+}
+
+func DisplayExternalIPResults(clients []GetExternalIPAddresser, errors []error, err error) {
+ if err != nil {
+ fmt.Fprintln(os.Stderr, "Error discovering service with UPnP: ", err)
+ return
+ }
+
+ if len(errors) > 0 {
+ fmt.Fprintf(os.Stderr, "Error discovering %d services:\n", len(errors))
+ for _, err := range errors {
+ fmt.Println(" ", err)
+ }
+ }
+
+ fmt.Fprintf(os.Stderr, "Successfully discovered %d services:\n", len(clients))
+ for _, client := range clients {
+ device := &client.GetServiceClient().RootDevice.Device
+
+ fmt.Fprintln(os.Stderr, " Device:", device.FriendlyName)
+ if addr, err := client.GetExternalIPAddress(); err != nil {
+ fmt.Fprintf(os.Stderr, " Failed to get external IP address: %v\n", err)
+ } else {
+ fmt.Fprintf(os.Stderr, " External IP address: %v\n", addr)
+ }
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/huin/goupnp/gotasks/specgen_task.go b/Godeps/_workspace/src/github.com/huin/goupnp/gotasks/specgen_task.go
new file mode 100644
index 000000000..0ac1d4ff3
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/huin/goupnp/gotasks/specgen_task.go
@@ -0,0 +1,539 @@
+// +build gotask
+
+package gotasks
+
+import (
+ "archive/zip"
+ "bytes"
+ "encoding/xml"
+ "fmt"
+ "io"
+ "io/ioutil"
+ "log"
+ "os"
+ "path"
+ "path/filepath"
+ "regexp"
+ "strings"
+ "text/template"
+
+ "github.com/huin/goupnp"
+ "github.com/huin/goupnp/scpd"
+ "github.com/huin/goutil/codegen"
+ "github.com/jingweno/gotask/tasking"
+)
+
+var (
+ deviceURNPrefix = "urn:schemas-upnp-org:device:"
+ serviceURNPrefix = "urn:schemas-upnp-org:service:"
+)
+
+// NAME
+// specgen - generates Go code from the UPnP specification files.
+//
+// DESCRIPTION
+// The specification is available for download from:
+//
+// OPTIONS
+// -s, --spec_filename=<upnpresources.zip>
+// Path to the specification file, available from http://upnp.org/resources/upnpresources.zip
+// -o, --out_dir=<output directory>
+// Path to the output directory. This is is where the DCP source files will be placed. Should normally correspond to the directory for github.com/huin/goupnp/dcps
+// --nogofmt
+// Disable passing the output through gofmt. Do this if debugging code output problems and needing to see the generated code prior to being passed through gofmt.
+func TaskSpecgen(t *tasking.T) {
+ specFilename := t.Flags.String("spec-filename")
+ if specFilename == "" {
+ specFilename = t.Flags.String("s")
+ }
+ if specFilename == "" {
+ t.Fatal("--spec_filename is required")
+ }
+ outDir := t.Flags.String("out-dir")
+ if outDir == "" {
+ outDir = t.Flags.String("o")
+ }
+ if outDir == "" {
+ log.Fatal("--out_dir is required")
+ }
+ useGofmt := !t.Flags.Bool("nogofmt")
+
+ specArchive, err := openZipfile(specFilename)
+ if err != nil {
+ t.Fatalf("Error opening spec file: %v", err)
+ }
+ defer specArchive.Close()
+
+ dcpCol := newDcpsCollection()
+ for _, f := range globFiles("standardizeddcps/*/*.zip", specArchive.Reader) {
+ dirName := strings.TrimPrefix(f.Name, "standardizeddcps/")
+ slashIndex := strings.Index(dirName, "/")
+ if slashIndex == -1 {
+ // Should not happen.
+ t.Logf("Could not find / in %q", dirName)
+ return
+ }
+ dirName = dirName[:slashIndex]
+
+ dcp := dcpCol.dcpForDir(dirName)
+ if dcp == nil {
+ t.Logf("No alias defined for directory %q: skipping %s\n", dirName, f.Name)
+ continue
+ } else {
+ t.Logf("Alias found for directory %q: processing %s\n", dirName, f.Name)
+ }
+
+ dcp.processZipFile(f)
+ }
+
+ for _, dcp := range dcpCol.dcpByAlias {
+ if err := dcp.writePackage(outDir, useGofmt); err != nil {
+ log.Printf("Error writing package %q: %v", dcp.Metadata.Name, err)
+ }
+ }
+}
+
+// DCP contains extra metadata to use when generating DCP source files.
+type DCPMetadata struct {
+ Name string // What to name the Go DCP package.
+ OfficialName string // Official name for the DCP.
+ DocURL string // Optional - URL for futher documentation about the DCP.
+}
+
+var dcpMetadataByDir = map[string]DCPMetadata{
+ "Internet Gateway_1": {
+ Name: "internetgateway1",
+ OfficialName: "Internet Gateway Device v1",
+ DocURL: "http://upnp.org/specs/gw/UPnP-gw-InternetGatewayDevice-v1-Device.pdf",
+ },
+ "Internet Gateway_2": {
+ Name: "internetgateway2",
+ OfficialName: "Internet Gateway Device v2",
+ DocURL: "http://upnp.org/specs/gw/UPnP-gw-InternetGatewayDevice-v2-Device.pdf",
+ },
+}
+
+type dcpCollection struct {
+ dcpByAlias map[string]*DCP
+}
+
+func newDcpsCollection() *dcpCollection {
+ c := &dcpCollection{
+ dcpByAlias: make(map[string]*DCP),
+ }
+ for _, metadata := range dcpMetadataByDir {
+ c.dcpByAlias[metadata.Name] = newDCP(metadata)
+ }
+ return c
+}
+
+func (c *dcpCollection) dcpForDir(dirName string) *DCP {
+ metadata, ok := dcpMetadataByDir[dirName]
+ if !ok {
+ return nil
+ }
+ return c.dcpByAlias[metadata.Name]
+}
+
+// DCP collects together information about a UPnP Device Control Protocol.
+type DCP struct {
+ Metadata DCPMetadata
+ DeviceTypes map[string]*URNParts
+ ServiceTypes map[string]*URNParts
+ Services []SCPDWithURN
+}
+
+func newDCP(metadata DCPMetadata) *DCP {
+ return &DCP{
+ Metadata: metadata,
+ DeviceTypes: make(map[string]*URNParts),
+ ServiceTypes: make(map[string]*URNParts),
+ }
+}
+
+func (dcp *DCP) processZipFile(file *zip.File) {
+ archive, err := openChildZip(file)
+ if err != nil {
+ log.Println("Error reading child zip file:", err)
+ return
+ }
+ for _, deviceFile := range globFiles("*/device/*.xml", archive) {
+ dcp.processDeviceFile(deviceFile)
+ }
+ for _, scpdFile := range globFiles("*/service/*.xml", archive) {
+ dcp.processSCPDFile(scpdFile)
+ }
+}
+
+func (dcp *DCP) processDeviceFile(file *zip.File) {
+ var device goupnp.Device
+ if err := unmarshalXmlFile(file, &device); err != nil {
+ log.Printf("Error decoding device XML from file %q: %v", file.Name, err)
+ return
+ }
+ device.VisitDevices(func(d *goupnp.Device) {
+ t := strings.TrimSpace(d.DeviceType)
+ if t != "" {
+ u, err := extractURNParts(t, deviceURNPrefix)
+ if err != nil {
+ log.Println(err)
+ return
+ }
+ dcp.DeviceTypes[t] = u
+ }
+ })
+ device.VisitServices(func(s *goupnp.Service) {
+ u, err := extractURNParts(s.ServiceType, serviceURNPrefix)
+ if err != nil {
+ log.Println(err)
+ return
+ }
+ dcp.ServiceTypes[s.ServiceType] = u
+ })
+}
+
+func (dcp *DCP) writePackage(outDir string, useGofmt bool) error {
+ packageDirname := filepath.Join(outDir, dcp.Metadata.Name)
+ err := os.MkdirAll(packageDirname, os.ModePerm)
+ if err != nil && !os.IsExist(err) {
+ return err
+ }
+ packageFilename := filepath.Join(packageDirname, dcp.Metadata.Name+".go")
+ packageFile, err := os.Create(packageFilename)
+ if err != nil {
+ return err
+ }
+ var output io.WriteCloser = packageFile
+ if useGofmt {
+ if output, err = codegen.NewGofmtWriteCloser(output); err != nil {
+ packageFile.Close()
+ return err
+ }
+ }
+ if err = packageTmpl.Execute(output, dcp); err != nil {
+ output.Close()
+ return err
+ }
+ return output.Close()
+}
+
+func (dcp *DCP) processSCPDFile(file *zip.File) {
+ scpd := new(scpd.SCPD)
+ if err := unmarshalXmlFile(file, scpd); err != nil {
+ log.Printf("Error decoding SCPD XML from file %q: %v", file.Name, err)
+ return
+ }
+ scpd.Clean()
+ urnParts, err := urnPartsFromSCPDFilename(file.Name)
+ if err != nil {
+ log.Printf("Could not recognize SCPD filename %q: %v", file.Name, err)
+ return
+ }
+ dcp.Services = append(dcp.Services, SCPDWithURN{
+ URNParts: urnParts,
+ SCPD: scpd,
+ })
+}
+
+type SCPDWithURN struct {
+ *URNParts
+ SCPD *scpd.SCPD
+}
+
+func (s *SCPDWithURN) WrapArgument(arg scpd.Argument) (*argumentWrapper, error) {
+ relVar := s.SCPD.GetStateVariable(arg.RelatedStateVariable)
+ if relVar == nil {
+ return nil, fmt.Errorf("no such state variable: %q, for argument %q", arg.RelatedStateVariable, arg.Name)
+ }
+ cnv, ok := typeConvs[relVar.DataType.Name]
+ if !ok {
+ return nil, fmt.Errorf("unknown data type: %q, for state variable %q, for argument %q", relVar.DataType.Type, arg.RelatedStateVariable, arg.Name)
+ }
+ return &argumentWrapper{
+ Argument: arg,
+ relVar: relVar,
+ conv: cnv,
+ }, nil
+}
+
+type argumentWrapper struct {
+ scpd.Argument
+ relVar *scpd.StateVariable
+ conv conv
+}
+
+func (arg *argumentWrapper) AsParameter() string {
+ return fmt.Sprintf("%s %s", arg.Name, arg.conv.ExtType)
+}
+
+func (arg *argumentWrapper) Document() string {
+ relVar := arg.relVar
+ if rng := relVar.AllowedValueRange; rng != nil {
+ var parts []string
+ if rng.Minimum != "" {
+ parts = append(parts, fmt.Sprintf("minimum=%s", rng.Minimum))
+ }
+ if rng.Maximum != "" {
+ parts = append(parts, fmt.Sprintf("maximum=%s", rng.Maximum))
+ }
+ if rng.Step != "" {
+ parts = append(parts, fmt.Sprintf("step=%s", rng.Step))
+ }
+ return "allowed value range: " + strings.Join(parts, ", ")
+ }
+ if len(relVar.AllowedValues) != 0 {
+ return "allowed values: " + strings.Join(relVar.AllowedValues, ", ")
+ }
+ return ""
+}
+
+func (arg *argumentWrapper) Marshal() string {
+ return fmt.Sprintf("soap.Marshal%s(%s)", arg.conv.FuncSuffix, arg.Name)
+}
+
+func (arg *argumentWrapper) Unmarshal(objVar string) string {
+ return fmt.Sprintf("soap.Unmarshal%s(%s.%s)", arg.conv.FuncSuffix, objVar, arg.Name)
+}
+
+type conv struct {
+ FuncSuffix string
+ ExtType string
+}
+
+// typeConvs maps from a SOAP type (e.g "fixed.14.4") to the function name
+// suffix inside the soap module (e.g "Fixed14_4") and the Go type.
+var typeConvs = map[string]conv{
+ "ui1": conv{"Ui1", "uint8"},
+ "ui2": conv{"Ui2", "uint16"},
+ "ui4": conv{"Ui4", "uint32"},
+ "i1": conv{"I1", "int8"},
+ "i2": conv{"I2", "int16"},
+ "i4": conv{"I4", "int32"},
+ "int": conv{"Int", "int64"},
+ "r4": conv{"R4", "float32"},
+ "r8": conv{"R8", "float64"},
+ "number": conv{"R8", "float64"}, // Alias for r8.
+ "fixed.14.4": conv{"Fixed14_4", "float64"},
+ "float": conv{"R8", "float64"},
+ "char": conv{"Char", "rune"},
+ "string": conv{"String", "string"},
+ "date": conv{"Date", "time.Time"},
+ "dateTime": conv{"DateTime", "time.Time"},
+ "dateTime.tz": conv{"DateTimeTz", "time.Time"},
+ "time": conv{"TimeOfDay", "soap.TimeOfDay"},
+ "time.tz": conv{"TimeOfDayTz", "soap.TimeOfDay"},
+ "boolean": conv{"Boolean", "bool"},
+ "bin.base64": conv{"BinBase64", "[]byte"},
+ "bin.hex": conv{"BinHex", "[]byte"},
+}
+
+type closeableZipReader struct {
+ io.Closer
+ *zip.Reader
+}
+
+func openZipfile(filename string) (*closeableZipReader, error) {
+ file, err := os.Open(filename)
+ if err != nil {
+ return nil, err
+ }
+ fi, err := file.Stat()
+ if err != nil {
+ return nil, err
+ }
+ archive, err := zip.NewReader(file, fi.Size())
+ if err != nil {
+ return nil, err
+ }
+ return &closeableZipReader{
+ Closer: file,
+ Reader: archive,
+ }, nil
+}
+
+// openChildZip opens a zip file within another zip file.
+func openChildZip(file *zip.File) (*zip.Reader, error) {
+ zipFile, err := file.Open()
+ if err != nil {
+ return nil, err
+ }
+ defer zipFile.Close()
+
+ zipBytes, err := ioutil.ReadAll(zipFile)
+ if err != nil {
+ return nil, err
+ }
+
+ return zip.NewReader(bytes.NewReader(zipBytes), int64(len(zipBytes)))
+}
+
+func globFiles(pattern string, archive *zip.Reader) []*zip.File {
+ var files []*zip.File
+ for _, f := range archive.File {
+ if matched, err := path.Match(pattern, f.Name); err != nil {
+ // This shouldn't happen - all patterns are hard-coded, errors in them
+ // are a programming error.
+ panic(err)
+ } else if matched {
+ files = append(files, f)
+ }
+ }
+ return files
+}
+
+func unmarshalXmlFile(file *zip.File, data interface{}) error {
+ r, err := file.Open()
+ if err != nil {
+ return err
+ }
+ decoder := xml.NewDecoder(r)
+ r.Close()
+ return decoder.Decode(data)
+}
+
+type URNParts struct {
+ URN string
+ Name string
+ Version string
+}
+
+func (u *URNParts) Const() string {
+ return fmt.Sprintf("URN_%s_%s", u.Name, u.Version)
+}
+
+// extractURNParts extracts the name and version from a URN string.
+func extractURNParts(urn, expectedPrefix string) (*URNParts, error) {
+ if !strings.HasPrefix(urn, expectedPrefix) {
+ return nil, fmt.Errorf("%q does not have expected prefix %q", urn, expectedPrefix)
+ }
+ parts := strings.SplitN(strings.TrimPrefix(urn, expectedPrefix), ":", 2)
+ if len(parts) != 2 {
+ return nil, fmt.Errorf("%q does not have a name and version", urn)
+ }
+ name, version := parts[0], parts[1]
+ return &URNParts{urn, name, version}, nil
+}
+
+var scpdFilenameRe = regexp.MustCompile(
+ `.*/([a-zA-Z0-9]+)([0-9]+)\.xml`)
+
+func urnPartsFromSCPDFilename(filename string) (*URNParts, error) {
+ parts := scpdFilenameRe.FindStringSubmatch(filename)
+ if len(parts) != 3 {
+ return nil, fmt.Errorf("SCPD filename %q does not have expected number of parts", filename)
+ }
+ name, version := parts[1], parts[2]
+ return &URNParts{
+ URN: serviceURNPrefix + name + ":" + version,
+ Name: name,
+ Version: version,
+ }, nil
+}
+
+var packageTmpl = template.Must(template.New("package").Parse(`{{$name := .Metadata.Name}}
+// Client for UPnP Device Control Protocol {{.Metadata.OfficialName}}.
+// {{if .Metadata.DocURL}}
+// This DCP is documented in detail at: {{.Metadata.DocURL}}{{end}}
+//
+// Typically, use one of the New* functions to discover services on the local
+// network.
+package {{$name}}
+
+// Generated file - do not edit by hand. See README.md
+
+
+import (
+ "time"
+
+ "github.com/huin/goupnp"
+ "github.com/huin/goupnp/soap"
+)
+
+// Hack to avoid Go complaining if time isn't used.
+var _ time.Time
+
+// Device URNs:
+const ({{range .DeviceTypes}}
+ {{.Const}} = "{{.URN}}"{{end}}
+)
+
+// Service URNs:
+const ({{range .ServiceTypes}}
+ {{.Const}} = "{{.URN}}"{{end}}
+)
+
+{{range .Services}}
+{{$srv := .}}
+{{$srvIdent := printf "%s%s" .Name .Version}}
+
+// {{$srvIdent}} is a client for UPnP SOAP service with URN "{{.URN}}". See
+// goupnp.ServiceClient, which contains RootDevice and Service attributes which
+// are provided for informational value.
+type {{$srvIdent}} struct {
+ goupnp.ServiceClient
+}
+
+// New{{$srvIdent}}Clients discovers instances of the service on the network,
+// and returns clients to any that are found. errors will contain an error for
+// any devices that replied but which could not be queried, and err will be set
+// if the discovery process failed outright.
+//
+// This is a typical entry calling point into this package.
+func New{{$srvIdent}}Clients() (clients []*{{$srvIdent}}, errors []error, err error) {
+ var genericClients []goupnp.ServiceClient
+ if genericClients, errors, err = goupnp.NewServiceClients({{$srv.Const}}); err != nil {
+ return
+ }
+ clients = make([]*{{$srvIdent}}, len(genericClients))
+ for i := range genericClients {
+ clients[i] = &{{$srvIdent}}{genericClients[i]}
+ }
+ return
+}
+
+{{range .SCPD.Actions}}{{/* loops over *SCPDWithURN values */}}
+
+{{$inargs := .InputArguments}}{{$outargs := .OutputArguments}}
+// {{if $inargs}}Arguments:{{range $inargs}}{{$argWrap := $srv.WrapArgument .}}
+//
+// * {{.Name}}: {{$argWrap.Document}}{{end}}{{end}}
+//
+// {{if $outargs}}Return values:{{range $outargs}}{{$argWrap := $srv.WrapArgument .}}
+//
+// * {{.Name}}: {{$argWrap.Document}}{{end}}{{end}}
+func (client *{{$srvIdent}}) {{.Name}}({{range $inargs}}{{/*
+*/}}{{$argWrap := $srv.WrapArgument .}}{{$argWrap.AsParameter}}, {{end}}{{/*
+*/}}) ({{range $outargs}}{{/*
+*/}}{{$argWrap := $srv.WrapArgument .}}{{$argWrap.AsParameter}}, {{end}} err error) {
+ // Request structure.
+ request := {{if $inargs}}&{{template "argstruct" $inargs}}{{"{}"}}{{else}}{{"interface{}(nil)"}}{{end}}
+ // BEGIN Marshal arguments into request.
+{{range $inargs}}{{$argWrap := $srv.WrapArgument .}}
+ if request.{{.Name}}, err = {{$argWrap.Marshal}}; err != nil {
+ return
+ }{{end}}
+ // END Marshal arguments into request.
+
+ // Response structure.
+ response := {{if $outargs}}&{{template "argstruct" $outargs}}{{"{}"}}{{else}}{{"interface{}(nil)"}}{{end}}
+
+ // Perform the SOAP call.
+ if err = client.SOAPClient.PerformAction({{$srv.URNParts.Const}}, "{{.Name}}", request, response); err != nil {
+ return
+ }
+
+ // BEGIN Unmarshal arguments from response.
+{{range $outargs}}{{$argWrap := $srv.WrapArgument .}}
+ if {{.Name}}, err = {{$argWrap.Unmarshal "response"}}; err != nil {
+ return
+ }{{end}}
+ // END Unmarshal arguments from response.
+ return
+}
+{{end}}{{/* range .SCPD.Actions */}}
+{{end}}{{/* range .Services */}}
+
+{{define "argstruct"}}struct {{"{"}}{{range .}}
+{{.Name}} string
+{{end}}{{"}"}}{{end}}
+`))
diff --git a/Godeps/_workspace/src/github.com/huin/goupnp/goupnp.go b/Godeps/_workspace/src/github.com/huin/goupnp/goupnp.go
new file mode 100644
index 000000000..120b92444
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/huin/goupnp/goupnp.go
@@ -0,0 +1,109 @@
+// goupnp is an implementation of a client for various UPnP services.
+//
+// For most uses, it is recommended to use the code-generated packages under
+// github.com/huin/goupnp/dcps. Example use is shown at
+// http://godoc.org/github.com/huin/goupnp/example
+//
+// A commonly used client is internetgateway1.WANPPPConnection1:
+// http://godoc.org/github.com/huin/goupnp/dcps/internetgateway1#WANPPPConnection1
+//
+// Currently only a couple of schemas have code generated for them from the
+// UPnP example XML specifications. Not all methods will work on these clients,
+// because the generated stubs contain the full set of specified methods from
+// the XML specifications, and the discovered services will likely support a
+// subset of those methods.
+package goupnp
+
+import (
+ "encoding/xml"
+ "fmt"
+ "net/http"
+ "net/url"
+
+ "github.com/huin/goupnp/httpu"
+ "github.com/huin/goupnp/ssdp"
+)
+
+// ContextError is an error that wraps an error with some context information.
+type ContextError struct {
+ Context string
+ Err error
+}
+
+func (err ContextError) Error() string {
+ return fmt.Sprintf("%s: %v", err.Context, err.Err)
+}
+
+// MaybeRootDevice contains either a RootDevice or an error.
+type MaybeRootDevice struct {
+ Root *RootDevice
+ Err error
+}
+
+// DiscoverDevices attempts to find targets of the given type. This is
+// typically the entry-point for this package. searchTarget is typically a URN
+// in the form "urn:schemas-upnp-org:device:..." or
+// "urn:schemas-upnp-org:service:...". A single error is returned for errors
+// while attempting to send the query. An error or RootDevice is returned for
+// each discovered RootDevice.
+func DiscoverDevices(searchTarget string) ([]MaybeRootDevice, error) {
+ httpu, err := httpu.NewHTTPUClient()
+ if err != nil {
+ return nil, err
+ }
+ defer httpu.Close()
+ responses, err := ssdp.SSDPRawSearch(httpu, string(searchTarget), 2, 3)
+ if err != nil {
+ return nil, err
+ }
+
+ results := make([]MaybeRootDevice, len(responses))
+ for i, response := range responses {
+ maybe := &results[i]
+ loc, err := response.Location()
+ if err != nil {
+
+ maybe.Err = ContextError{"unexpected bad location from search", err}
+ continue
+ }
+ locStr := loc.String()
+ root := new(RootDevice)
+ if err := requestXml(locStr, DeviceXMLNamespace, root); err != nil {
+ maybe.Err = ContextError{fmt.Sprintf("error requesting root device details from %q", locStr), err}
+ continue
+ }
+ var urlBaseStr string
+ if root.URLBaseStr != "" {
+ urlBaseStr = root.URLBaseStr
+ } else {
+ urlBaseStr = locStr
+ }
+ urlBase, err := url.Parse(urlBaseStr)
+ if err != nil {
+ maybe.Err = ContextError{fmt.Sprintf("error parsing location URL %q", locStr), err}
+ continue
+ }
+ root.SetURLBase(urlBase)
+ maybe.Root = root
+ }
+
+ return results, nil
+}
+
+func requestXml(url string, defaultSpace string, doc interface{}) error {
+ resp, err := http.Get(url)
+ if err != nil {
+ return err
+ }
+ defer resp.Body.Close()
+
+ if resp.StatusCode != 200 {
+ return fmt.Errorf("goupnp: got response status %s from %q",
+ resp.Status, url)
+ }
+
+ decoder := xml.NewDecoder(resp.Body)
+ decoder.DefaultSpace = defaultSpace
+
+ return decoder.Decode(doc)
+}
diff --git a/Godeps/_workspace/src/github.com/huin/goupnp/httpu/httpu.go b/Godeps/_workspace/src/github.com/huin/goupnp/httpu/httpu.go
new file mode 100644
index 000000000..862c3def4
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/huin/goupnp/httpu/httpu.go
@@ -0,0 +1,117 @@
+package httpu
+
+import (
+ "bufio"
+ "bytes"
+ "fmt"
+ "log"
+ "net"
+ "net/http"
+ "sync"
+ "time"
+)
+
+// HTTPUClient is a client for dealing with HTTPU (HTTP over UDP). Its typical
+// function is for HTTPMU, and particularly SSDP.
+type HTTPUClient struct {
+ connLock sync.Mutex // Protects use of conn.
+ conn net.PacketConn
+}
+
+// NewHTTPUClient creates a new HTTPUClient, opening up a new UDP socket for the
+// purpose.
+func NewHTTPUClient() (*HTTPUClient, error) {
+ conn, err := net.ListenPacket("udp", ":0")
+ if err != nil {
+ return nil, err
+ }
+ return &HTTPUClient{conn: conn}, nil
+}
+
+// Close shuts down the client. The client will no longer be useful following
+// this.
+func (httpu *HTTPUClient) Close() error {
+ httpu.connLock.Lock()
+ defer httpu.connLock.Unlock()
+ return httpu.conn.Close()
+}
+
+// Do performs a request. The timeout is how long to wait for before returning
+// the responses that were received. An error is only returned for failing to
+// send the request. Failures in receipt simply do not add to the resulting
+// responses.
+//
+// Note that at present only one concurrent connection will happen per
+// HTTPUClient.
+func (httpu *HTTPUClient) Do(req *http.Request, timeout time.Duration, numSends int) ([]*http.Response, error) {
+ httpu.connLock.Lock()
+ defer httpu.connLock.Unlock()
+
+ // Create the request. This is a subset of what http.Request.Write does
+ // deliberately to avoid creating extra fields which may confuse some
+ // devices.
+ var requestBuf bytes.Buffer
+ method := req.Method
+ if method == "" {
+ method = "GET"
+ }
+ if _, err := fmt.Fprintf(&requestBuf, "%s %s HTTP/1.1\r\n", method, req.URL.RequestURI()); err != nil {
+ return nil, err
+ }
+ if err := req.Header.Write(&requestBuf); err != nil {
+ return nil, err
+ }
+ if _, err := requestBuf.Write([]byte{'\r', '\n'}); err != nil {
+ return nil, err
+ }
+
+ destAddr, err := net.ResolveUDPAddr("udp", req.Host)
+ if err != nil {
+ return nil, err
+ }
+ if err = httpu.conn.SetDeadline(time.Now().Add(timeout)); err != nil {
+ return nil, err
+ }
+
+ // Send request.
+ for i := 0; i < numSends; i++ {
+ if n, err := httpu.conn.WriteTo(requestBuf.Bytes(), destAddr); err != nil {
+ return nil, err
+ } else if n < len(requestBuf.Bytes()) {
+ return nil, fmt.Errorf("httpu: wrote %d bytes rather than full %d in request",
+ n, len(requestBuf.Bytes()))
+ }
+ time.Sleep(5 * time.Millisecond)
+ }
+
+ // Await responses until timeout.
+ var responses []*http.Response
+ responseBytes := make([]byte, 2048)
+ for {
+ // 2048 bytes should be sufficient for most networks.
+ n, _, err := httpu.conn.ReadFrom(responseBytes)
+ if err != nil {
+ if err, ok := err.(net.Error); ok {
+ if err.Timeout() {
+ break
+ }
+ if err.Temporary() {
+ // Sleep in case this is a persistent error to avoid pegging CPU until deadline.
+ time.Sleep(10 * time.Millisecond)
+ continue
+ }
+ }
+ return nil, err
+ }
+
+ // Parse response.
+ response, err := http.ReadResponse(bufio.NewReader(bytes.NewBuffer(responseBytes[:n])), req)
+ if err != nil {
+ log.Print("httpu: error while parsing response: %v", err)
+ continue
+ }
+
+ responses = append(responses, response)
+ }
+ return responses, err
+}
diff --git a/Godeps/_workspace/src/github.com/huin/goupnp/httpu/serve.go b/Godeps/_workspace/src/github.com/huin/goupnp/httpu/serve.go
new file mode 100644
index 000000000..9f67af85b
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/huin/goupnp/httpu/serve.go
@@ -0,0 +1,108 @@
+package httpu
+
+import (
+ "bufio"
+ "bytes"
+ "log"
+ "net"
+ "net/http"
+ "regexp"
+)
+
+const (
+ DefaultMaxMessageBytes = 2048
+)
+
+var (
+ trailingWhitespaceRx = regexp.MustCompile(" +\r\n")
+ crlf = []byte("\r\n")
+)
+
+// Handler is the interface by which received HTTPU messages are passed to
+// handling code.
+type Handler interface {
+ // ServeMessage is called for each HTTPU message received. peerAddr contains
+ // the address that the message was received from.
+ ServeMessage(r *http.Request)
+}
+
+// HandlerFunc is a function-to-Handler adapter.
+type HandlerFunc func(r *http.Request)
+
+func (f HandlerFunc) ServeMessage(r *http.Request) {
+ f(r)
+}
+
+// A Server defines parameters for running an HTTPU server.
+type Server struct {
+ Addr string // UDP address to listen on
+ Multicast bool // Should listen for multicast?
+ Interface *net.Interface // Network interface to listen on for multicast, nil for default multicast interface
+ Handler Handler // handler to invoke
+ MaxMessageBytes int // maximum number of bytes to read from a packet, DefaultMaxMessageBytes if 0
+}
+
+// ListenAndServe listens on the UDP network address srv.Addr. If srv.Multicast
+// is true, then a multicast UDP listener will be used on srv.Interface (or
+// default interface if nil).
+func (srv *Server) ListenAndServe() error {
+ var err error
+
+ var addr *net.UDPAddr
+ if addr, err = net.ResolveUDPAddr("udp", srv.Addr); err != nil {
+ log.Fatal(err)
+ }
+
+ var conn net.PacketConn
+ if srv.Multicast {
+ if conn, err = net.ListenMulticastUDP("udp", srv.Interface, addr); err != nil {
+ return err
+ }
+ } else {
+ if conn, err = net.ListenUDP("udp", addr); err != nil {
+ return err
+ }
+ }
+
+ return srv.Serve(conn)
+}
+
+// Serve messages received on the given packet listener to the srv.Handler.
+func (srv *Server) Serve(l net.PacketConn) error {
+ maxMessageBytes := DefaultMaxMessageBytes
+ if srv.MaxMessageBytes != 0 {
+ maxMessageBytes = srv.MaxMessageBytes
+ }
+ for {
+ buf := make([]byte, maxMessageBytes)
+ n, peerAddr, err := l.ReadFrom(buf)
+ if err != nil {
+ return err
+ }
+ buf = buf[:n]
+
+ go func(buf []byte, peerAddr net.Addr) {
+ // At least one router's UPnP implementation has added a trailing space
+ // after "HTTP/1.1" - trim it.
+ buf = trailingWhitespaceRx.ReplaceAllLiteral(buf, crlf)
+
+ req, err := http.ReadRequest(bufio.NewReader(bytes.NewBuffer(buf)))
+ if err != nil {
+ log.Printf("httpu: Failed to parse request: %v", err)
+ return
+ }
+ req.RemoteAddr = peerAddr.String()
+ srv.Handler.ServeMessage(req)
+ // No need to call req.Body.Close - underlying reader is bytes.Buffer.
+ }(buf, peerAddr)
+ }
+}
+
+// Serve messages received on the given packet listener to the given handler.
+func Serve(l net.PacketConn, handler Handler) error {
+ srv := Server{
+ Handler: handler,
+ MaxMessageBytes: DefaultMaxMessageBytes,
+ }
+ return srv.Serve(l)
+}
diff --git a/Godeps/_workspace/src/github.com/huin/goupnp/scpd/scpd.go b/Godeps/_workspace/src/github.com/huin/goupnp/scpd/scpd.go
new file mode 100644
index 000000000..c9d2e69e8
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/huin/goupnp/scpd/scpd.go
@@ -0,0 +1,167 @@
+package scpd
+
+import (
+ "encoding/xml"
+ "strings"
+)
+
+const (
+ SCPDXMLNamespace = "urn:schemas-upnp-org:service-1-0"
+)
+
+func cleanWhitespace(s *string) {
+ *s = strings.TrimSpace(*s)
+}
+
+// SCPD is the service description as described by section 2.5 "Service
+// description" in
+// http://upnp.org/specs/arch/UPnP-arch-DeviceArchitecture-v1.1.pdf
+type SCPD struct {
+ XMLName xml.Name `xml:"scpd"`
+ ConfigId string `xml:"configId,attr"`
+ SpecVersion SpecVersion `xml:"specVersion"`
+ Actions []Action `xml:"actionList>action"`
+ StateVariables []StateVariable `xml:"serviceStateTable>stateVariable"`
+}
+
+// Clean attempts to remove stray whitespace etc. in the structure. It seems
+// unfortunately common for stray whitespace to be present in SCPD documents,
+// this method attempts to make it easy to clean them out.
+func (scpd *SCPD) Clean() {
+ cleanWhitespace(&scpd.ConfigId)
+ for i := range scpd.Actions {
+ scpd.Actions[i].clean()
+ }
+ for i := range scpd.StateVariables {
+ scpd.StateVariables[i].clean()
+ }
+}
+
+func (scpd *SCPD) GetStateVariable(variable string) *StateVariable {
+ for i := range scpd.StateVariables {
+ v := &scpd.StateVariables[i]
+ if v.Name == variable {
+ return v
+ }
+ }
+ return nil
+}
+
+func (scpd *SCPD) GetAction(action string) *Action {
+ for i := range scpd.Actions {
+ a := &scpd.Actions[i]
+ if a.Name == action {
+ return a
+ }
+ }
+ return nil
+}
+
+// SpecVersion is part of a SCPD document, describes the version of the
+// specification that the data adheres to.
+type SpecVersion struct {
+ Major int32 `xml:"major"`
+ Minor int32 `xml:"minor"`
+}
+
+type Action struct {
+ Name string `xml:"name"`
+ Arguments []Argument `xml:"argumentList>argument"`
+}
+
+func (action *Action) clean() {
+ cleanWhitespace(&action.Name)
+ for i := range action.Arguments {
+ action.Arguments[i].clean()
+ }
+}
+
+func (action *Action) InputArguments() []*Argument {
+ var result []*Argument
+ for i := range action.Arguments {
+ arg := &action.Arguments[i]
+ if arg.IsInput() {
+ result = append(result, arg)
+ }
+ }
+ return result
+}
+
+func (action *Action) OutputArguments() []*Argument {
+ var result []*Argument
+ for i := range action.Arguments {
+ arg := &action.Arguments[i]
+ if arg.IsOutput() {
+ result = append(result, arg)
+ }
+ }
+ return result
+}
+
+type Argument struct {
+ Name string `xml:"name"`
+ Direction string `xml:"direction"` // in|out
+ RelatedStateVariable string `xml:"relatedStateVariable"` // ?
+ Retval string `xml:"retval"` // ?
+}
+
+func (arg *Argument) clean() {
+ cleanWhitespace(&arg.Name)
+ cleanWhitespace(&arg.Direction)
+ cleanWhitespace(&arg.RelatedStateVariable)
+ cleanWhitespace(&arg.Retval)
+}
+
+func (arg *Argument) IsInput() bool {
+ return arg.Direction == "in"
+}
+
+func (arg *Argument) IsOutput() bool {
+ return arg.Direction == "out"
+}
+
+type StateVariable struct {
+ Name string `xml:"name"`
+ SendEvents string `xml:"sendEvents,attr"` // yes|no
+ Multicast string `xml:"multicast,attr"` // yes|no
+ DataType DataType `xml:"dataType"`
+ DefaultValue string `xml:"defaultValue"`
+ AllowedValueRange *AllowedValueRange `xml:"allowedValueRange"`
+ AllowedValues []string `xml:"allowedValueList>allowedValue"`
+}
+
+func (v *StateVariable) clean() {
+ cleanWhitespace(&v.Name)
+ cleanWhitespace(&v.SendEvents)
+ cleanWhitespace(&v.Multicast)
+ v.DataType.clean()
+ cleanWhitespace(&v.DefaultValue)
+ if v.AllowedValueRange != nil {
+ v.AllowedValueRange.clean()
+ }
+ for i := range v.AllowedValues {
+ cleanWhitespace(&v.AllowedValues[i])
+ }
+}
+
+type AllowedValueRange struct {
+ Minimum string `xml:"minimum"`
+ Maximum string `xml:"maximum"`
+ Step string `xml:"step"`
+}
+
+func (r *AllowedValueRange) clean() {
+ cleanWhitespace(&r.Minimum)
+ cleanWhitespace(&r.Maximum)
+ cleanWhitespace(&r.Step)
+}
+
+type DataType struct {
+ Name string `xml:",chardata"`
+ Type string `xml:"type,attr"`
+}
+
+func (dt *DataType) clean() {
+ cleanWhitespace(&dt.Name)
+ cleanWhitespace(&dt.Type)
+}
diff --git a/Godeps/_workspace/src/github.com/huin/goupnp/service_client.go b/Godeps/_workspace/src/github.com/huin/goupnp/service_client.go
new file mode 100644
index 000000000..c0d16ce2a
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/huin/goupnp/service_client.go
@@ -0,0 +1,56 @@
+package goupnp
+
+import (
+ "fmt"
+ "github.com/huin/goupnp/soap"
+)
+
+// ServiceClient is a SOAP client, root device and the service for the SOAP
+// client rolled into one value. The root device and service are intended to be
+// informational.
+type ServiceClient struct {
+ SOAPClient *soap.SOAPClient
+ RootDevice *RootDevice
+ Service *Service
+}
+
+func NewServiceClients(searchTarget string) (clients []ServiceClient, errors []error, err error) {
+ var maybeRootDevices []MaybeRootDevice
+ if maybeRootDevices, err = DiscoverDevices(searchTarget); err != nil {
+ return
+ }
+
+ clients = make([]ServiceClient, 0, len(maybeRootDevices))
+
+ for _, maybeRootDevice := range maybeRootDevices {
+ if maybeRootDevice.Err != nil {
+ errors = append(errors, maybeRootDevice.Err)
+ continue
+ }
+
+ device := &maybeRootDevice.Root.Device
+ srvs := device.FindService(searchTarget)
+ if len(srvs) == 0 {
+ errors = append(errors, fmt.Errorf("goupnp: service %q not found within device %q (UDN=%q)",
+ searchTarget, device.FriendlyName, device.UDN))
+ continue
+ }
+
+ for _, srv := range srvs {
+ clients = append(clients, ServiceClient{
+ SOAPClient: srv.NewSOAPClient(),
+ RootDevice: maybeRootDevice.Root,
+ Service: srv,
+ })
+ }
+ }
+
+ return
+}
+
+// GetServiceClient returns the ServiceClient itself. This is provided so that the
+// service client attributes can be accessed via an interface method on a
+// wrapping type.
+func (client *ServiceClient) GetServiceClient() *ServiceClient {
+ return client
+}
diff --git a/Godeps/_workspace/src/github.com/huin/goupnp/soap/soap.go b/Godeps/_workspace/src/github.com/huin/goupnp/soap/soap.go
new file mode 100644
index 000000000..815610734
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/huin/goupnp/soap/soap.go
@@ -0,0 +1,157 @@
+// Definition for the SOAP structure required for UPnP's SOAP usage.
+
+package soap
+
+import (
+ "bytes"
+ "encoding/xml"
+ "fmt"
+ "io/ioutil"
+ "net/http"
+ "net/url"
+ "reflect"
+)
+
+const (
+ soapEncodingStyle = "http://schemas.xmlsoap.org/soap/encoding/"
+ soapPrefix = xml.Header + `<s:Envelope xmlns:s="http://schemas.xmlsoap.org/soap/envelope/" s:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"><s:Body>`
+ soapSuffix = `</s:Body></s:Envelope>`
+)
+
+type SOAPClient struct {
+ EndpointURL url.URL
+ HTTPClient http.Client
+}
+
+func NewSOAPClient(endpointURL url.URL) *SOAPClient {
+ return &SOAPClient{
+ EndpointURL: endpointURL,
+ }
+}
+
+// PerformSOAPAction makes a SOAP request, with the given action.
+// inAction and outAction must both be pointers to structs with string fields
+// only.
+func (client *SOAPClient) PerformAction(actionNamespace, actionName string, inAction interface{}, outAction interface{}) error {
+ requestBytes, err := encodeRequestAction(actionNamespace, actionName, inAction)
+ if err != nil {
+ return err
+ }
+
+ response, err := client.HTTPClient.Do(&http.Request{
+ Method: "POST",
+ URL: &client.EndpointURL,
+ Header: http.Header{
+ "SOAPACTION": []string{`"` + actionNamespace + "#" + actionName + `"`},
+ "CONTENT-TYPE": []string{"text/xml; charset=\"utf-8\""},
+ },
+ Body: ioutil.NopCloser(bytes.NewBuffer(requestBytes)),
+ // Set ContentLength to avoid chunked encoding - some servers might not support it.
+ ContentLength: int64(len(requestBytes)),
+ })
+ if err != nil {
+ return fmt.Errorf("goupnp: error performing SOAP HTTP request: %v", err)
+ }
+ defer response.Body.Close()
+ if response.StatusCode != 200 {
+ return fmt.Errorf("goupnp: SOAP request got HTTP %s", response.Status)
+ }
+
+ responseEnv := newSOAPEnvelope()
+ decoder := xml.NewDecoder(response.Body)
+ if err := decoder.Decode(responseEnv); err != nil {
+ return fmt.Errorf("goupnp: error decoding response body: %v", err)
+ }
+
+ if responseEnv.Body.Fault != nil {
+ return responseEnv.Body.Fault
+ }
+
+ if outAction != nil {
+ if err := xml.Unmarshal(responseEnv.Body.RawAction, outAction); err != nil {
+ return fmt.Errorf("goupnp: error unmarshalling out action: %v, %v", err, responseEnv.Body.RawAction)
+ }
+ }
+
+ return nil
+}
+
+// newSOAPAction creates a soapEnvelope with the given action and arguments.
+func newSOAPEnvelope() *soapEnvelope {
+ return &soapEnvelope{
+ EncodingStyle: soapEncodingStyle,
+ }
+}
+
+// encodeRequestAction is a hacky way to create an encoded SOAP envelope
+// containing the given action. Experiments with one router have shown that it
+// 500s for requests where the outer default xmlns is set to the SOAP
+// namespace, and then reassigning the default namespace within that to the
+// service namespace. Hand-coding the outer XML to work-around this.
+func encodeRequestAction(actionNamespace, actionName string, inAction interface{}) ([]byte, error) {
+ requestBuf := new(bytes.Buffer)
+ requestBuf.WriteString(soapPrefix)
+ requestBuf.WriteString(`<u:`)
+ xml.EscapeText(requestBuf, []byte(actionName))
+ requestBuf.WriteString(` xmlns:u="`)
+ xml.EscapeText(requestBuf, []byte(actionNamespace))
+ requestBuf.WriteString(`">`)
+ if inAction != nil {
+ if err := encodeRequestArgs(requestBuf, inAction); err != nil {
+ return nil, err
+ }
+ }
+ requestBuf.WriteString(`</u:`)
+ xml.EscapeText(requestBuf, []byte(actionName))
+ requestBuf.WriteString(`>`)
+ requestBuf.WriteString(soapSuffix)
+ return requestBuf.Bytes(), nil
+}
+
+func encodeRequestArgs(w *bytes.Buffer, inAction interface{}) error {
+ in := reflect.Indirect(reflect.ValueOf(inAction))
+ if in.Kind() != reflect.Struct {
+ return fmt.Errorf("goupnp: SOAP inAction is not a struct but of type %v", in.Type())
+ }
+ enc := xml.NewEncoder(w)
+ nFields := in.NumField()
+ inType := in.Type()
+ for i := 0; i < nFields; i++ {
+ field := inType.Field(i)
+ argName := field.Name
+ if nameOverride := field.Tag.Get("soap"); nameOverride != "" {
+ argName = nameOverride
+ }
+ value := in.Field(i)
+ if value.Kind() != reflect.String {
+ return fmt.Errorf("goupnp: SOAP arg %q is not of type string, but of type %v", argName, value.Type())
+ }
+ if err := enc.EncodeElement(value.Interface(), xml.StartElement{xml.Name{"", argName}, nil}); err != nil {
+ return fmt.Errorf("goupnp: error encoding SOAP arg %q: %v", argName, err)
+ }
+ }
+ enc.Flush()
+ return nil
+}
+
+type soapEnvelope struct {
+ XMLName xml.Name `xml:"http://schemas.xmlsoap.org/soap/envelope/ Envelope"`
+ EncodingStyle string `xml:"http://schemas.xmlsoap.org/soap/envelope/ encodingStyle,attr"`
+ Body soapBody `xml:"http://schemas.xmlsoap.org/soap/envelope/ Body"`
+}
+
+type soapBody struct {
+ Fault *SOAPFaultError `xml:"Fault"`
+ RawAction []byte `xml:",innerxml"`
+}
+
+// SOAPFaultError implements error, and contains SOAP fault information.
+type SOAPFaultError struct {
+ FaultCode string `xml:"faultcode"`
+ FaultString string `xml:"faultstring"`
+ Detail string `xml:"detail"`
+}
+
+func (err *SOAPFaultError) Error() string {
+ return fmt.Sprintf("SOAP fault: %s", err.FaultString)
+}
diff --git a/Godeps/_workspace/src/github.com/huin/goupnp/soap/soap_test.go b/Godeps/_workspace/src/github.com/huin/goupnp/soap/soap_test.go
new file mode 100644
index 000000000..75dbbdbf1
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/huin/goupnp/soap/soap_test.go
@@ -0,0 +1,85 @@
+package soap
+
+import (
+ "bytes"
+ "io/ioutil"
+ "net/http"
+ "net/url"
+ "reflect"
+ "testing"
+)
+
+type capturingRoundTripper struct {
+ err error
+ resp *http.Response
+ capturedReq *http.Request
+}
+
+func (rt *capturingRoundTripper) RoundTrip(req *http.Request) (*http.Response, error) {
+ rt.capturedReq = req
+ return rt.resp, rt.err
+}
+
+func TestActionInputs(t *testing.T) {
+ url, err := url.Parse("http://example.com/soap")
+ if err != nil {
+ t.Fatal(err)
+ }
+ rt := &capturingRoundTripper{
+ err: nil,
+ resp: &http.Response{
+ StatusCode: 200,
+ Body: ioutil.NopCloser(bytes.NewBufferString(`
+ <s:Envelope xmlns:s="http://schemas.xmlsoap.org/soap/envelope/">
+ <s:Body>
+ <u:myactionResponse xmlns:u="mynamespace">
+ <A>valueA</A>
+ <B>valueB</B>
+ </u:myactionResponse>
+ </s:Body>
+ </s:Envelope>
+ `)),
+ },
+ }
+ client := SOAPClient{
+ EndpointURL: *url,
+ HTTPClient: http.Client{
+ Transport: rt,
+ },
+ }
+
+ type In struct {
+ Foo string
+ Bar string `soap:"bar"`
+ }
+ type Out struct {
+ A string
+ B string
+ }
+ in := In{"foo", "bar"}
+ gotOut := Out{}
+ err = client.PerformAction("mynamespace", "myaction", &in, &gotOut)
+ if err != nil {
+ t.Fatal(err)
+ }
+
+ wantBody := (soapPrefix +
+ `<u:myaction xmlns:u="mynamespace">` +
+ `<Foo>foo</Foo>` +
+ `<bar>bar</bar>` +
+ `</u:myaction>` +
+ soapSuffix)
+ body, err := ioutil.ReadAll(rt.capturedReq.Body)
+ if err != nil {
+ t.Fatal(err)
+ }
+ gotBody := string(body)
+ if wantBody != gotBody {
+ t.Errorf("Bad request body\nwant: %q\n got: %q", wantBody, gotBody)
+ }
+
+ wantOut := Out{"valueA", "valueB"}
+ if !reflect.DeepEqual(wantOut, gotOut) {
+ t.Errorf("Bad output\nwant: %+v\n got: %+v", wantOut, gotOut)
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/huin/goupnp/soap/types.go b/Godeps/_workspace/src/github.com/huin/goupnp/soap/types.go
new file mode 100644
index 000000000..cd16510e3
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/huin/goupnp/soap/types.go
@@ -0,0 +1,508 @@
+package soap
+
+import (
+ "encoding/base64"
+ "encoding/hex"
+ "errors"
+ "fmt"
+ "regexp"
+ "strconv"
+ "strings"
+ "time"
+ "unicode/utf8"
+)
+
+var (
+ // localLoc acts like time.Local for this package, but is faked out by the
+ // unit tests to ensure that things stay constant (especially when running
+ // this test in a place where local time is UTC which might mask bugs).
+ localLoc = time.Local
+)
+
+func MarshalUi1(v uint8) (string, error) {
+ return strconv.FormatUint(uint64(v), 10), nil
+}
+
+func UnmarshalUi1(s string) (uint8, error) {
+ v, err := strconv.ParseUint(s, 10, 8)
+ return uint8(v), err
+}
+
+func MarshalUi2(v uint16) (string, error) {
+ return strconv.FormatUint(uint64(v), 10), nil
+}
+
+func UnmarshalUi2(s string) (uint16, error) {
+ v, err := strconv.ParseUint(s, 10, 16)
+ return uint16(v), err
+}
+
+func MarshalUi4(v uint32) (string, error) {
+ return strconv.FormatUint(uint64(v), 10), nil
+}
+
+func UnmarshalUi4(s string) (uint32, error) {
+ v, err := strconv.ParseUint(s, 10, 32)
+ return uint32(v), err
+}
+
+func MarshalI1(v int8) (string, error) {
+ return strconv.FormatInt(int64(v), 10), nil
+}
+
+func UnmarshalI1(s string) (int8, error) {
+ v, err := strconv.ParseInt(s, 10, 8)
+ return int8(v), err
+}
+
+func MarshalI2(v int16) (string, error) {
+ return strconv.FormatInt(int64(v), 10), nil
+}
+
+func UnmarshalI2(s string) (int16, error) {
+ v, err := strconv.ParseInt(s, 10, 16)
+ return int16(v), err
+}
+
+func MarshalI4(v int32) (string, error) {
+ return strconv.FormatInt(int64(v), 10), nil
+}
+
+func UnmarshalI4(s string) (int32, error) {
+ v, err := strconv.ParseInt(s, 10, 32)
+ return int32(v), err
+}
+
+func MarshalInt(v int64) (string, error) {
+ return strconv.FormatInt(v, 10), nil
+}
+
+func UnmarshalInt(s string) (int64, error) {
+ return strconv.ParseInt(s, 10, 64)
+}
+
+func MarshalR4(v float32) (string, error) {
+ return strconv.FormatFloat(float64(v), 'G', -1, 32), nil
+}
+
+func UnmarshalR4(s string) (float32, error) {
+ v, err := strconv.ParseFloat(s, 32)
+ return float32(v), err
+}
+
+func MarshalR8(v float64) (string, error) {
+ return strconv.FormatFloat(v, 'G', -1, 64), nil
+}
+
+func UnmarshalR8(s string) (float64, error) {
+ v, err := strconv.ParseFloat(s, 64)
+ return float64(v), err
+}
+
+// MarshalFixed14_4 marshals float64 to SOAP "fixed.14.4" type.
+func MarshalFixed14_4(v float64) (string, error) {
+ if v >= 1e14 || v <= -1e14 {
+ return "", fmt.Errorf("soap fixed14.4: value %v out of bounds", v)
+ }
+ return strconv.FormatFloat(v, 'f', 4, 64), nil
+}
+
+// UnmarshalFixed14_4 unmarshals float64 from SOAP "fixed.14.4" type.
+func UnmarshalFixed14_4(s string) (float64, error) {
+ v, err := strconv.ParseFloat(s, 64)
+ if err != nil {
+ return 0, err
+ }
+ if v >= 1e14 || v <= -1e14 {
+ return 0, fmt.Errorf("soap fixed14.4: value %q out of bounds", s)
+ }
+ return v, nil
+}
+
+// MarshalChar marshals rune to SOAP "char" type.
+func MarshalChar(v rune) (string, error) {
+ if v == 0 {
+ return "", errors.New("soap char: rune 0 is not allowed")
+ }
+ return string(v), nil
+}
+
+// UnmarshalChar unmarshals rune from SOAP "char" type.
+func UnmarshalChar(s string) (rune, error) {
+ if len(s) == 0 {
+ return 0, errors.New("soap char: got empty string")
+ }
+ r, n := utf8.DecodeRune([]byte(s))
+ if n != len(s) {
+ return 0, fmt.Errorf("soap char: value %q is not a single rune", s)
+ }
+ return r, nil
+}
+
+func MarshalString(v string) (string, error) {
+ return v, nil
+}
+
+func UnmarshalString(v string) (string, error) {
+ return v, nil
+}
+
+func parseInt(s string, err *error) int {
+ v, parseErr := strconv.ParseInt(s, 10, 64)
+ if parseErr != nil {
+ *err = parseErr
+ }
+ return int(v)
+}
+
+var dateRegexps = []*regexp.Regexp{
+ // yyyy[-mm[-dd]]
+ regexp.MustCompile(`^(\d{4})(?:-(\d{2})(?:-(\d{2}))?)?$`),
+ // yyyy[mm[dd]]
+ regexp.MustCompile(`^(\d{4})(?:(\d{2})(?:(\d{2}))?)?$`),
+}
+
+func parseDateParts(s string) (year, month, day int, err error) {
+ var parts []string
+ for _, re := range dateRegexps {
+ parts = re.FindStringSubmatch(s)
+ if parts != nil {
+ break
+ }
+ }
+ if parts == nil {
+ err = fmt.Errorf("soap date: value %q is not in a recognized ISO8601 date format", s)
+ return
+ }
+
+ year = parseInt(parts[1], &err)
+ month = 1
+ day = 1
+ if len(parts[2]) != 0 {
+ month = parseInt(parts[2], &err)
+ if len(parts[3]) != 0 {
+ day = parseInt(parts[3], &err)
+ }
+ }
+
+ if err != nil {
+ err = fmt.Errorf("soap date: %q: %v", s, err)
+ }
+
+ return
+}
+
+var timeRegexps = []*regexp.Regexp{
+ // hh[:mm[:ss]]
+ regexp.MustCompile(`^(\d{2})(?::(\d{2})(?::(\d{2}))?)?$`),
+ // hh[mm[ss]]
+ regexp.MustCompile(`^(\d{2})(?:(\d{2})(?:(\d{2}))?)?$`),
+}
+
+func parseTimeParts(s string) (hour, minute, second int, err error) {
+ var parts []string
+ for _, re := range timeRegexps {
+ parts = re.FindStringSubmatch(s)
+ if parts != nil {
+ break
+ }
+ }
+ if parts == nil {
+ err = fmt.Errorf("soap time: value %q is not in ISO8601 time format", s)
+ return
+ }
+
+ hour = parseInt(parts[1], &err)
+ if len(parts[2]) != 0 {
+ minute = parseInt(parts[2], &err)
+ if len(parts[3]) != 0 {
+ second = parseInt(parts[3], &err)
+ }
+ }
+
+ if err != nil {
+ err = fmt.Errorf("soap time: %q: %v", s, err)
+ }
+
+ return
+}
+
+// (+|-)hh[[:]mm]
+var timezoneRegexp = regexp.MustCompile(`^([+-])(\d{2})(?::?(\d{2}))?$`)
+
+func parseTimezone(s string) (offset int, err error) {
+ if s == "Z" {
+ return 0, nil
+ }
+ parts := timezoneRegexp.FindStringSubmatch(s)
+ if parts == nil {
+ err = fmt.Errorf("soap timezone: value %q is not in ISO8601 timezone format", s)
+ return
+ }
+
+ offset = parseInt(parts[2], &err) * 3600
+ if len(parts[3]) != 0 {
+ offset += parseInt(parts[3], &err) * 60
+ }
+ if parts[1] == "-" {
+ offset = -offset
+ }
+
+ if err != nil {
+ err = fmt.Errorf("soap timezone: %q: %v", s, err)
+ }
+
+ return
+}
+
+var completeDateTimeZoneRegexp = regexp.MustCompile(`^([^T]+)(?:T([^-+Z]+)(.+)?)?$`)
+
+// splitCompleteDateTimeZone splits date, time and timezone apart from an
+// ISO8601 string. It does not ensure that the contents of each part are
+// correct, it merely splits on certain delimiters.
+// e.g "2010-09-08T12:15:10+0700" => "2010-09-08", "12:15:10", "+0700".
+// Timezone can only be present if time is also present.
+func splitCompleteDateTimeZone(s string) (dateStr, timeStr, zoneStr string, err error) {
+ parts := completeDateTimeZoneRegexp.FindStringSubmatch(s)
+ if parts == nil {
+ err = fmt.Errorf("soap date/time/zone: value %q is not in ISO8601 datetime format", s)
+ return
+ }
+ dateStr = parts[1]
+ timeStr = parts[2]
+ zoneStr = parts[3]
+ return
+}
+
+// MarshalDate marshals time.Time to SOAP "date" type. Note that this converts
+// to local time, and discards the time-of-day components.
+func MarshalDate(v time.Time) (string, error) {
+ return v.In(localLoc).Format("2006-01-02"), nil
+}
+
+var dateFmts = []string{"2006-01-02", "20060102"}
+
+// UnmarshalDate unmarshals time.Time from SOAP "date" type. This outputs the
+// date as midnight in the local time zone.
+func UnmarshalDate(s string) (time.Time, error) {
+ year, month, day, err := parseDateParts(s)
+ if err != nil {
+ return time.Time{}, err
+ }
+ return time.Date(year, time.Month(month), day, 0, 0, 0, 0, localLoc), nil
+}
+
+// TimeOfDay is used in cases where SOAP "time" or "time.tz" is used.
+type TimeOfDay struct {
+ // Duration of time since midnight.
+ FromMidnight time.Duration
+
+ // Set to true if Offset is specified. If false, then the timezone is
+ // unspecified (and by ISO8601 - implies some "local" time).
+ HasOffset bool
+
+ // Offset is non-zero only if time.tz is used. It is otherwise ignored. If
+ // non-zero, then it is regarded as a UTC offset in seconds. Note that the
+ // sub-minutes is ignored by the marshal function.
+ Offset int
+}
+
+// MarshalTimeOfDay marshals TimeOfDay to the "time" type.
+func MarshalTimeOfDay(v TimeOfDay) (string, error) {
+ d := int64(v.FromMidnight / time.Second)
+ hour := d / 3600
+ d = d % 3600
+ minute := d / 60
+ second := d % 60
+
+ return fmt.Sprintf("%02d:%02d:%02d", hour, minute, second), nil
+}
+
+// UnmarshalTimeOfDay unmarshals TimeOfDay from the "time" type.
+func UnmarshalTimeOfDay(s string) (TimeOfDay, error) {
+ t, err := UnmarshalTimeOfDayTz(s)
+ if err != nil {
+ return TimeOfDay{}, err
+ } else if t.HasOffset {
+ return TimeOfDay{}, fmt.Errorf("soap time: value %q contains unexpected timezone")
+ }
+ return t, nil
+}
+
+// MarshalTimeOfDayTz marshals TimeOfDay to the "time.tz" type.
+func MarshalTimeOfDayTz(v TimeOfDay) (string, error) {
+ d := int64(v.FromMidnight / time.Second)
+ hour := d / 3600
+ d = d % 3600
+ minute := d / 60
+ second := d % 60
+
+ tz := ""
+ if v.HasOffset {
+ if v.Offset == 0 {
+ tz = "Z"
+ } else {
+ offsetMins := v.Offset / 60
+ sign := '+'
+ if offsetMins < 1 {
+ offsetMins = -offsetMins
+ sign = '-'
+ }
+ tz = fmt.Sprintf("%c%02d:%02d", sign, offsetMins/60, offsetMins%60)
+ }
+ }
+
+ return fmt.Sprintf("%02d:%02d:%02d%s", hour, minute, second, tz), nil
+}
+
+// UnmarshalTimeOfDayTz unmarshals TimeOfDay from the "time.tz" type.
+func UnmarshalTimeOfDayTz(s string) (tod TimeOfDay, err error) {
+ zoneIndex := strings.IndexAny(s, "Z+-")
+ var timePart string
+ var hasOffset bool
+ var offset int
+ if zoneIndex == -1 {
+ hasOffset = false
+ timePart = s
+ } else {
+ hasOffset = true
+ timePart = s[:zoneIndex]
+ if offset, err = parseTimezone(s[zoneIndex:]); err != nil {
+ return
+ }
+ }
+
+ hour, minute, second, err := parseTimeParts(timePart)
+ if err != nil {
+ return
+ }
+
+ fromMidnight := time.Duration(hour*3600+minute*60+second) * time.Second
+
+ // ISO8601 special case - values up to 24:00:00 are allowed, so using
+ // strictly greater-than for the maximum value.
+ if fromMidnight > 24*time.Hour || minute >= 60 || second >= 60 {
+ return TimeOfDay{}, fmt.Errorf("soap time.tz: value %q has value(s) out of range", s)
+ }
+
+ return TimeOfDay{
+ FromMidnight: time.Duration(hour*3600+minute*60+second) * time.Second,
+ HasOffset: hasOffset,
+ Offset: offset,
+ }, nil
+}
+
+// MarshalDateTime marshals time.Time to SOAP "dateTime" type. Note that this
+// converts to local time.
+func MarshalDateTime(v time.Time) (string, error) {
+ return v.In(localLoc).Format("2006-01-02T15:04:05"), nil
+}
+
+// UnmarshalDateTime unmarshals time.Time from the SOAP "dateTime" type. This
+// returns a value in the local timezone.
+func UnmarshalDateTime(s string) (result time.Time, err error) {
+ dateStr, timeStr, zoneStr, err := splitCompleteDateTimeZone(s)
+ if err != nil {
+ return
+ }
+
+ if len(zoneStr) != 0 {
+ err = fmt.Errorf("soap datetime: unexpected timezone in %q", s)
+ return
+ }
+
+ year, month, day, err := parseDateParts(dateStr)
+ if err != nil {
+ return
+ }
+
+ var hour, minute, second int
+ if len(timeStr) != 0 {
+ hour, minute, second, err = parseTimeParts(timeStr)
+ if err != nil {
+ return
+ }
+ }
+
+ result = time.Date(year, time.Month(month), day, hour, minute, second, 0, localLoc)
+ return
+}
+
+// MarshalDateTimeTz marshals time.Time to SOAP "dateTime.tz" type.
+func MarshalDateTimeTz(v time.Time) (string, error) {
+ return v.Format("2006-01-02T15:04:05-07:00"), nil
+}
+
+// UnmarshalDateTimeTz unmarshals time.Time from the SOAP "dateTime.tz" type.
+// This returns a value in the local timezone when the timezone is unspecified.
+func UnmarshalDateTimeTz(s string) (result time.Time, err error) {
+ dateStr, timeStr, zoneStr, err := splitCompleteDateTimeZone(s)
+ if err != nil {
+ return
+ }
+
+ year, month, day, err := parseDateParts(dateStr)
+ if err != nil {
+ return
+ }
+
+ var hour, minute, second int
+ var location *time.Location = localLoc
+ if len(timeStr) != 0 {
+ hour, minute, second, err = parseTimeParts(timeStr)
+ if err != nil {
+ return
+ }
+ if len(zoneStr) != 0 {
+ var offset int
+ offset, err = parseTimezone(zoneStr)
+ if offset == 0 {
+ location = time.UTC
+ } else {
+ location = time.FixedZone("", offset)
+ }
+ }
+ }
+
+ result = time.Date(year, time.Month(month), day, hour, minute, second, 0, location)
+ return
+}
+
+// MarshalBoolean marshals bool to SOAP "boolean" type.
+func MarshalBoolean(v bool) (string, error) {
+ if v {
+ return "1", nil
+ }
+ return "0", nil
+}
+
+// UnmarshalBoolean unmarshals bool from the SOAP "boolean" type.
+func UnmarshalBoolean(s string) (bool, error) {
+ switch s {
+ case "0", "false", "no":
+ return false, nil
+ case "1", "true", "yes":
+ return true, nil
+ }
+ return false, fmt.Errorf("soap boolean: %q is not a valid boolean value", s)
+}
+
+// MarshalBinBase64 marshals []byte to SOAP "bin.base64" type.
+func MarshalBinBase64(v []byte) (string, error) {
+ return base64.StdEncoding.EncodeToString(v), nil
+}
+
+// UnmarshalBinBase64 unmarshals []byte from the SOAP "bin.base64" type.
+func UnmarshalBinBase64(s string) ([]byte, error) {
+ return base64.StdEncoding.DecodeString(s)
+}
+
+// MarshalBinHex marshals []byte to SOAP "bin.hex" type.
+func MarshalBinHex(v []byte) (string, error) {
+ return hex.EncodeToString(v), nil
+}
+
+// UnmarshalBinHex unmarshals []byte from the SOAP "bin.hex" type.
+func UnmarshalBinHex(s string) ([]byte, error) {
+ return hex.DecodeString(s)
+}
diff --git a/Godeps/_workspace/src/github.com/huin/goupnp/soap/types_test.go b/Godeps/_workspace/src/github.com/huin/goupnp/soap/types_test.go
new file mode 100644
index 000000000..da6816190
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/huin/goupnp/soap/types_test.go
@@ -0,0 +1,481 @@
+package soap
+
+import (
+ "bytes"
+ "math"
+ "testing"
+ "time"
+)
+
+type convTest interface {
+ Marshal() (string, error)
+ Unmarshal(string) (interface{}, error)
+ Equal(result interface{}) bool
+}
+
+// duper is an interface that convTest values may optionally also implement to
+// generate another convTest for a value in an otherwise identical testCase.
+type duper interface {
+ Dupe(tag string) []convTest
+}
+
+type testCase struct {
+ value convTest
+ str string
+ wantMarshalErr bool
+ wantUnmarshalErr bool
+ noMarshal bool
+ noUnMarshal bool
+ tag string
+}
+
+type Ui1Test uint8
+
+func (v Ui1Test) Marshal() (string, error) {
+ return MarshalUi1(uint8(v))
+}
+func (v Ui1Test) Unmarshal(s string) (interface{}, error) {
+ return UnmarshalUi1(s)
+}
+func (v Ui1Test) Equal(result interface{}) bool {
+ return uint8(v) == result.(uint8)
+}
+func (v Ui1Test) Dupe(tag string) []convTest {
+ if tag == "dupe" {
+ return []convTest{
+ Ui2Test(v),
+ Ui4Test(v),
+ }
+ }
+ return nil
+}
+
+type Ui2Test uint16
+
+func (v Ui2Test) Marshal() (string, error) {
+ return MarshalUi2(uint16(v))
+}
+func (v Ui2Test) Unmarshal(s string) (interface{}, error) {
+ return UnmarshalUi2(s)
+}
+func (v Ui2Test) Equal(result interface{}) bool {
+ return uint16(v) == result.(uint16)
+}
+
+type Ui4Test uint32
+
+func (v Ui4Test) Marshal() (string, error) {
+ return MarshalUi4(uint32(v))
+}
+func (v Ui4Test) Unmarshal(s string) (interface{}, error) {
+ return UnmarshalUi4(s)
+}
+func (v Ui4Test) Equal(result interface{}) bool {
+ return uint32(v) == result.(uint32)
+}
+
+type I1Test int8
+
+func (v I1Test) Marshal() (string, error) {
+ return MarshalI1(int8(v))
+}
+func (v I1Test) Unmarshal(s string) (interface{}, error) {
+ return UnmarshalI1(s)
+}
+func (v I1Test) Equal(result interface{}) bool {
+ return int8(v) == result.(int8)
+}
+func (v I1Test) Dupe(tag string) []convTest {
+ if tag == "dupe" {
+ return []convTest{
+ I2Test(v),
+ I4Test(v),
+ }
+ }
+ return nil
+}
+
+type I2Test int16
+
+func (v I2Test) Marshal() (string, error) {
+ return MarshalI2(int16(v))
+}
+func (v I2Test) Unmarshal(s string) (interface{}, error) {
+ return UnmarshalI2(s)
+}
+func (v I2Test) Equal(result interface{}) bool {
+ return int16(v) == result.(int16)
+}
+
+type I4Test int32
+
+func (v I4Test) Marshal() (string, error) {
+ return MarshalI4(int32(v))
+}
+func (v I4Test) Unmarshal(s string) (interface{}, error) {
+ return UnmarshalI4(s)
+}
+func (v I4Test) Equal(result interface{}) bool {
+ return int32(v) == result.(int32)
+}
+
+type IntTest int64
+
+func (v IntTest) Marshal() (string, error) {
+ return MarshalInt(int64(v))
+}
+func (v IntTest) Unmarshal(s string) (interface{}, error) {
+ return UnmarshalInt(s)
+}
+func (v IntTest) Equal(result interface{}) bool {
+ return int64(v) == result.(int64)
+}
+
+type Fixed14_4Test float64
+
+func (v Fixed14_4Test) Marshal() (string, error) {
+ return MarshalFixed14_4(float64(v))
+}
+func (v Fixed14_4Test) Unmarshal(s string) (interface{}, error) {
+ return UnmarshalFixed14_4(s)
+}
+func (v Fixed14_4Test) Equal(result interface{}) bool {
+ return math.Abs(float64(v)-result.(float64)) < 0.001
+}
+
+type CharTest rune
+
+func (v CharTest) Marshal() (string, error) {
+ return MarshalChar(rune(v))
+}
+func (v CharTest) Unmarshal(s string) (interface{}, error) {
+ return UnmarshalChar(s)
+}
+func (v CharTest) Equal(result interface{}) bool {
+ return rune(v) == result.(rune)
+}
+
+type DateTest struct{ time.Time }
+
+func (v DateTest) Marshal() (string, error) {
+ return MarshalDate(time.Time(v.Time))
+}
+func (v DateTest) Unmarshal(s string) (interface{}, error) {
+ return UnmarshalDate(s)
+}
+func (v DateTest) Equal(result interface{}) bool {
+ return v.Time.Equal(result.(time.Time))
+}
+func (v DateTest) Dupe(tag string) []convTest {
+ if tag != "no:dateTime" {
+ return []convTest{DateTimeTest{v.Time}}
+ }
+ return nil
+}
+
+type TimeOfDayTest struct {
+ TimeOfDay
+}
+
+func (v TimeOfDayTest) Marshal() (string, error) {
+ return MarshalTimeOfDay(v.TimeOfDay)
+}
+func (v TimeOfDayTest) Unmarshal(s string) (interface{}, error) {
+ return UnmarshalTimeOfDay(s)
+}
+func (v TimeOfDayTest) Equal(result interface{}) bool {
+ return v.TimeOfDay == result.(TimeOfDay)
+}
+func (v TimeOfDayTest) Dupe(tag string) []convTest {
+ if tag != "no:time.tz" {
+ return []convTest{TimeOfDayTzTest{v.TimeOfDay}}
+ }
+ return nil
+}
+
+type TimeOfDayTzTest struct {
+ TimeOfDay
+}
+
+func (v TimeOfDayTzTest) Marshal() (string, error) {
+ return MarshalTimeOfDayTz(v.TimeOfDay)
+}
+func (v TimeOfDayTzTest) Unmarshal(s string) (interface{}, error) {
+ return UnmarshalTimeOfDayTz(s)
+}
+func (v TimeOfDayTzTest) Equal(result interface{}) bool {
+ return v.TimeOfDay == result.(TimeOfDay)
+}
+
+type DateTimeTest struct{ time.Time }
+
+func (v DateTimeTest) Marshal() (string, error) {
+ return MarshalDateTime(time.Time(v.Time))
+}
+func (v DateTimeTest) Unmarshal(s string) (interface{}, error) {
+ return UnmarshalDateTime(s)
+}
+func (v DateTimeTest) Equal(result interface{}) bool {
+ return v.Time.Equal(result.(time.Time))
+}
+func (v DateTimeTest) Dupe(tag string) []convTest {
+ if tag != "no:dateTime.tz" {
+ return []convTest{DateTimeTzTest{v.Time}}
+ }
+ return nil
+}
+
+type DateTimeTzTest struct{ time.Time }
+
+func (v DateTimeTzTest) Marshal() (string, error) {
+ return MarshalDateTimeTz(time.Time(v.Time))
+}
+func (v DateTimeTzTest) Unmarshal(s string) (interface{}, error) {
+ return UnmarshalDateTimeTz(s)
+}
+func (v DateTimeTzTest) Equal(result interface{}) bool {
+ return v.Time.Equal(result.(time.Time))
+}
+
+type BooleanTest bool
+
+func (v BooleanTest) Marshal() (string, error) {
+ return MarshalBoolean(bool(v))
+}
+func (v BooleanTest) Unmarshal(s string) (interface{}, error) {
+ return UnmarshalBoolean(s)
+}
+func (v BooleanTest) Equal(result interface{}) bool {
+ return bool(v) == result.(bool)
+}
+
+type BinBase64Test []byte
+
+func (v BinBase64Test) Marshal() (string, error) {
+ return MarshalBinBase64([]byte(v))
+}
+func (v BinBase64Test) Unmarshal(s string) (interface{}, error) {
+ return UnmarshalBinBase64(s)
+}
+func (v BinBase64Test) Equal(result interface{}) bool {
+ return bytes.Equal([]byte(v), result.([]byte))
+}
+
+type BinHexTest []byte
+
+func (v BinHexTest) Marshal() (string, error) {
+ return MarshalBinHex([]byte(v))
+}
+func (v BinHexTest) Unmarshal(s string) (interface{}, error) {
+ return UnmarshalBinHex(s)
+}
+func (v BinHexTest) Equal(result interface{}) bool {
+ return bytes.Equal([]byte(v), result.([]byte))
+}
+
+func Test(t *testing.T) {
+ const time010203 time.Duration = (1*3600 + 2*60 + 3) * time.Second
+ const time0102 time.Duration = (1*3600 + 2*60) * time.Second
+ const time01 time.Duration = (1 * 3600) * time.Second
+ const time235959 time.Duration = (23*3600 + 59*60 + 59) * time.Second
+
+ // Fake out the local time for the implementation.
+ localLoc = time.FixedZone("Fake/Local", 6*3600)
+ defer func() {
+ localLoc = time.Local
+ }()
+
+ tests := []testCase{
+ // ui1
+ {str: "", value: Ui1Test(0), wantUnmarshalErr: true, noMarshal: true, tag: "dupe"},
+ {str: " ", value: Ui1Test(0), wantUnmarshalErr: true, noMarshal: true, tag: "dupe"},
+ {str: "abc", value: Ui1Test(0), wantUnmarshalErr: true, noMarshal: true, tag: "dupe"},
+ {str: "-1", value: Ui1Test(0), wantUnmarshalErr: true, noMarshal: true, tag: "dupe"},
+ {str: "0", value: Ui1Test(0), tag: "dupe"},
+ {str: "1", value: Ui1Test(1), tag: "dupe"},
+ {str: "255", value: Ui1Test(255), tag: "dupe"},
+ {str: "256", value: Ui1Test(0), wantUnmarshalErr: true, noMarshal: true},
+
+ // ui2
+ {str: "65535", value: Ui2Test(65535)},
+ {str: "65536", value: Ui2Test(0), wantUnmarshalErr: true, noMarshal: true},
+
+ // ui4
+ {str: "4294967295", value: Ui4Test(4294967295)},
+ {str: "4294967296", value: Ui4Test(0), wantUnmarshalErr: true, noMarshal: true},
+
+ // i1
+ {str: "", value: I1Test(0), wantUnmarshalErr: true, noMarshal: true, tag: "dupe"},
+ {str: " ", value: I1Test(0), wantUnmarshalErr: true, noMarshal: true, tag: "dupe"},
+ {str: "abc", value: I1Test(0), wantUnmarshalErr: true, noMarshal: true, tag: "dupe"},
+ {str: "0", value: I1Test(0), tag: "dupe"},
+ {str: "-1", value: I1Test(-1), tag: "dupe"},
+ {str: "127", value: I1Test(127), tag: "dupe"},
+ {str: "-128", value: I1Test(-128), tag: "dupe"},
+ {str: "128", value: I1Test(0), wantUnmarshalErr: true, noMarshal: true},
+ {str: "-129", value: I1Test(0), wantUnmarshalErr: true, noMarshal: true},
+
+ // i2
+ {str: "32767", value: I2Test(32767)},
+ {str: "-32768", value: I2Test(-32768)},
+ {str: "32768", value: I2Test(0), wantUnmarshalErr: true, noMarshal: true},
+ {str: "-32769", value: I2Test(0), wantUnmarshalErr: true, noMarshal: true},
+
+ // i4
+ {str: "2147483647", value: I4Test(2147483647)},
+ {str: "-2147483648", value: I4Test(-2147483648)},
+ {str: "2147483648", value: I4Test(0), wantUnmarshalErr: true, noMarshal: true},
+ {str: "-2147483649", value: I4Test(0), wantUnmarshalErr: true, noMarshal: true},
+
+ // int
+ {str: "9223372036854775807", value: IntTest(9223372036854775807)},
+ {str: "-9223372036854775808", value: IntTest(-9223372036854775808)},
+ {str: "9223372036854775808", value: IntTest(0), wantUnmarshalErr: true, noMarshal: true},
+ {str: "-9223372036854775809", value: IntTest(0), wantUnmarshalErr: true, noMarshal: true},
+
+ // fixed.14.4
+ {str: "0.0000", value: Fixed14_4Test(0)},
+ {str: "1.0000", value: Fixed14_4Test(1)},
+ {str: "1.2346", value: Fixed14_4Test(1.23456)},
+ {str: "-1.0000", value: Fixed14_4Test(-1)},
+ {str: "-1.2346", value: Fixed14_4Test(-1.23456)},
+ {str: "10000000000000.0000", value: Fixed14_4Test(1e13)},
+ {str: "100000000000000.0000", value: Fixed14_4Test(1e14), wantMarshalErr: true, wantUnmarshalErr: true},
+ {str: "-10000000000000.0000", value: Fixed14_4Test(-1e13)},
+ {str: "-100000000000000.0000", value: Fixed14_4Test(-1e14), wantMarshalErr: true, wantUnmarshalErr: true},
+
+ // char
+ {str: "a", value: CharTest('a')},
+ {str: "z", value: CharTest('z')},
+ {str: "\u1234", value: CharTest(0x1234)},
+ {str: "aa", value: CharTest(0), wantMarshalErr: true, wantUnmarshalErr: true},
+ {str: "", value: CharTest(0), wantMarshalErr: true, wantUnmarshalErr: true},
+
+ // date
+ {str: "2013-10-08", value: DateTest{time.Date(2013, 10, 8, 0, 0, 0, 0, localLoc)}, tag: "no:dateTime"},
+ {str: "20131008", value: DateTest{time.Date(2013, 10, 8, 0, 0, 0, 0, localLoc)}, noMarshal: true, tag: "no:dateTime"},
+ {str: "2013-10-08T10:30:50", value: DateTest{}, wantUnmarshalErr: true, noMarshal: true, tag: "no:dateTime"},
+ {str: "2013-10-08T10:30:50Z", value: DateTest{}, wantUnmarshalErr: true, noMarshal: true, tag: "no:dateTime"},
+ {str: "", value: DateTest{}, wantMarshalErr: true, wantUnmarshalErr: true, noMarshal: true},
+ {str: "-1", value: DateTest{}, wantUnmarshalErr: true, noMarshal: true},
+
+ // time
+ {str: "00:00:00", value: TimeOfDayTest{TimeOfDay{FromMidnight: 0}}},
+ {str: "000000", value: TimeOfDayTest{TimeOfDay{FromMidnight: 0}}, noMarshal: true},
+ {str: "24:00:00", value: TimeOfDayTest{TimeOfDay{FromMidnight: 24 * time.Hour}}, noMarshal: true}, // ISO8601 special case
+ {str: "24:01:00", value: TimeOfDayTest{}, wantUnmarshalErr: true, noMarshal: true},
+ {str: "24:00:01", value: TimeOfDayTest{}, wantUnmarshalErr: true, noMarshal: true},
+ {str: "25:00:00", value: TimeOfDayTest{}, wantUnmarshalErr: true, noMarshal: true},
+ {str: "00:60:00", value: TimeOfDayTest{}, wantUnmarshalErr: true, noMarshal: true},
+ {str: "00:00:60", value: TimeOfDayTest{}, wantUnmarshalErr: true, noMarshal: true},
+ {str: "01:02:03", value: TimeOfDayTest{TimeOfDay{FromMidnight: time010203}}},
+ {str: "010203", value: TimeOfDayTest{TimeOfDay{FromMidnight: time010203}}, noMarshal: true},
+ {str: "23:59:59", value: TimeOfDayTest{TimeOfDay{FromMidnight: time235959}}},
+ {str: "235959", value: TimeOfDayTest{TimeOfDay{FromMidnight: time235959}}, noMarshal: true},
+ {str: "01:02", value: TimeOfDayTest{TimeOfDay{FromMidnight: time0102}}, noMarshal: true},
+ {str: "0102", value: TimeOfDayTest{TimeOfDay{FromMidnight: time0102}}, noMarshal: true},
+ {str: "01", value: TimeOfDayTest{TimeOfDay{FromMidnight: time01}}, noMarshal: true},
+ {str: "foo 01:02:03", value: TimeOfDayTest{}, wantUnmarshalErr: true, noMarshal: true, tag: "no:time.tz"},
+ {str: "foo\n01:02:03", value: TimeOfDayTest{}, wantUnmarshalErr: true, noMarshal: true, tag: "no:time.tz"},
+ {str: "01:02:03 foo", value: TimeOfDayTest{}, wantUnmarshalErr: true, noMarshal: true, tag: "no:time.tz"},
+ {str: "01:02:03\nfoo", value: TimeOfDayTest{}, wantUnmarshalErr: true, noMarshal: true, tag: "no:time.tz"},
+ {str: "01:02:03Z", value: TimeOfDayTest{}, wantUnmarshalErr: true, noMarshal: true, tag: "no:time.tz"},
+ {str: "01:02:03+01", value: TimeOfDayTest{}, wantUnmarshalErr: true, noMarshal: true, tag: "no:time.tz"},
+ {str: "01:02:03+01:23", value: TimeOfDayTest{}, wantUnmarshalErr: true, noMarshal: true, tag: "no:time.tz"},
+ {str: "01:02:03+0123", value: TimeOfDayTest{}, wantUnmarshalErr: true, noMarshal: true, tag: "no:time.tz"},
+ {str: "01:02:03-01", value: TimeOfDayTest{}, wantUnmarshalErr: true, noMarshal: true, tag: "no:time.tz"},
+ {str: "01:02:03-01:23", value: TimeOfDayTest{}, wantUnmarshalErr: true, noMarshal: true, tag: "no:time.tz"},
+ {str: "01:02:03-0123", value: TimeOfDayTest{}, wantUnmarshalErr: true, noMarshal: true, tag: "no:time.tz"},
+
+ // time.tz
+ {str: "24:00:01", value: TimeOfDayTzTest{}, wantUnmarshalErr: true, noMarshal: true},
+ {str: "01Z", value: TimeOfDayTzTest{TimeOfDay{time01, true, 0}}, noMarshal: true},
+ {str: "01:02:03Z", value: TimeOfDayTzTest{TimeOfDay{time010203, true, 0}}},
+ {str: "01+01", value: TimeOfDayTzTest{TimeOfDay{time01, true, 3600}}, noMarshal: true},
+ {str: "01:02:03+01", value: TimeOfDayTzTest{TimeOfDay{time010203, true, 3600}}, noMarshal: true},
+ {str: "01:02:03+01:23", value: TimeOfDayTzTest{TimeOfDay{time010203, true, 3600 + 23*60}}},
+ {str: "01:02:03+0123", value: TimeOfDayTzTest{TimeOfDay{time010203, true, 3600 + 23*60}}, noMarshal: true},
+ {str: "01:02:03-01", value: TimeOfDayTzTest{TimeOfDay{time010203, true, -3600}}, noMarshal: true},
+ {str: "01:02:03-01:23", value: TimeOfDayTzTest{TimeOfDay{time010203, true, -(3600 + 23*60)}}},
+ {str: "01:02:03-0123", value: TimeOfDayTzTest{TimeOfDay{time010203, true, -(3600 + 23*60)}}, noMarshal: true},
+
+ // dateTime
+ {str: "2013-10-08T00:00:00", value: DateTimeTest{time.Date(2013, 10, 8, 0, 0, 0, 0, localLoc)}, tag: "no:dateTime.tz"},
+ {str: "20131008", value: DateTimeTest{time.Date(2013, 10, 8, 0, 0, 0, 0, localLoc)}, noMarshal: true},
+ {str: "2013-10-08T10:30:50", value: DateTimeTest{time.Date(2013, 10, 8, 10, 30, 50, 0, localLoc)}, tag: "no:dateTime.tz"},
+ {str: "2013-10-08T10:30:50T", value: DateTimeTest{}, wantUnmarshalErr: true, noMarshal: true},
+ {str: "2013-10-08T10:30:50+01", value: DateTimeTest{}, wantUnmarshalErr: true, noMarshal: true, tag: "no:dateTime.tz"},
+ {str: "2013-10-08T10:30:50+01:23", value: DateTimeTest{}, wantUnmarshalErr: true, noMarshal: true, tag: "no:dateTime.tz"},
+ {str: "2013-10-08T10:30:50+0123", value: DateTimeTest{}, wantUnmarshalErr: true, noMarshal: true, tag: "no:dateTime.tz"},
+ {str: "2013-10-08T10:30:50-01", value: DateTimeTest{}, wantUnmarshalErr: true, noMarshal: true, tag: "no:dateTime.tz"},
+ {str: "2013-10-08T10:30:50-01:23", value: DateTimeTest{}, wantUnmarshalErr: true, noMarshal: true, tag: "no:dateTime.tz"},
+ {str: "2013-10-08T10:30:50-0123", value: DateTimeTest{}, wantUnmarshalErr: true, noMarshal: true, tag: "no:dateTime.tz"},
+
+ // dateTime.tz
+ {str: "2013-10-08T10:30:50", value: DateTimeTzTest{time.Date(2013, 10, 8, 10, 30, 50, 0, localLoc)}, noMarshal: true},
+ {str: "2013-10-08T10:30:50+01", value: DateTimeTzTest{time.Date(2013, 10, 8, 10, 30, 50, 0, time.FixedZone("+01:00", 3600))}, noMarshal: true},
+ {str: "2013-10-08T10:30:50+01:23", value: DateTimeTzTest{time.Date(2013, 10, 8, 10, 30, 50, 0, time.FixedZone("+01:23", 3600+23*60))}},
+ {str: "2013-10-08T10:30:50+0123", value: DateTimeTzTest{time.Date(2013, 10, 8, 10, 30, 50, 0, time.FixedZone("+01:23", 3600+23*60))}, noMarshal: true},
+ {str: "2013-10-08T10:30:50-01", value: DateTimeTzTest{time.Date(2013, 10, 8, 10, 30, 50, 0, time.FixedZone("-01:00", -3600))}, noMarshal: true},
+ {str: "2013-10-08T10:30:50-01:23", value: DateTimeTzTest{time.Date(2013, 10, 8, 10, 30, 50, 0, time.FixedZone("-01:23", -(3600+23*60)))}},
+ {str: "2013-10-08T10:30:50-0123", value: DateTimeTzTest{time.Date(2013, 10, 8, 10, 30, 50, 0, time.FixedZone("-01:23", -(3600+23*60)))}, noMarshal: true},
+
+ // boolean
+ {str: "0", value: BooleanTest(false)},
+ {str: "1", value: BooleanTest(true)},
+ {str: "false", value: BooleanTest(false), noMarshal: true},
+ {str: "true", value: BooleanTest(true), noMarshal: true},
+ {str: "no", value: BooleanTest(false), noMarshal: true},
+ {str: "yes", value: BooleanTest(true), noMarshal: true},
+ {str: "", value: BooleanTest(false), noMarshal: true, wantUnmarshalErr: true},
+ {str: "other", value: BooleanTest(false), noMarshal: true, wantUnmarshalErr: true},
+ {str: "2", value: BooleanTest(false), noMarshal: true, wantUnmarshalErr: true},
+ {str: "-1", value: BooleanTest(false), noMarshal: true, wantUnmarshalErr: true},
+
+ // bin.base64
+ {str: "", value: BinBase64Test{}},
+ {str: "YQ==", value: BinBase64Test("a")},
+ {str: "TG9uZ2VyIFN0cmluZy4=", value: BinBase64Test("Longer String.")},
+ {str: "TG9uZ2VyIEFsaWduZWQu", value: BinBase64Test("Longer Aligned.")},
+
+ // bin.hex
+ {str: "", value: BinHexTest{}},
+ {str: "61", value: BinHexTest("a")},
+ {str: "4c6f6e67657220537472696e672e", value: BinHexTest("Longer String.")},
+ {str: "4C6F6E67657220537472696E672E", value: BinHexTest("Longer String."), noMarshal: true},
+ }
+
+ // Generate extra test cases from convTests that implement duper.
+ var extras []testCase
+ for i := range tests {
+ if duper, ok := tests[i].value.(duper); ok {
+ dupes := duper.Dupe(tests[i].tag)
+ for _, duped := range dupes {
+ dupedCase := testCase(tests[i])
+ dupedCase.value = duped
+ extras = append(extras, dupedCase)
+ }
+ }
+ }
+ tests = append(tests, extras...)
+
+ for _, test := range tests {
+ if test.noMarshal {
+ } else if resultStr, err := test.value.Marshal(); err != nil && !test.wantMarshalErr {
+ t.Errorf("For %T marshal %v, want %q, got error: %v", test.value, test.value, test.str, err)
+ } else if err == nil && test.wantMarshalErr {
+ t.Errorf("For %T marshal %v, want error, got %q", test.value, test.value, resultStr)
+ } else if err == nil && resultStr != test.str {
+ t.Errorf("For %T marshal %v, want %q, got %q", test.value, test.value, test.str, resultStr)
+ }
+
+ if test.noUnMarshal {
+ } else if resultValue, err := test.value.Unmarshal(test.str); err != nil && !test.wantUnmarshalErr {
+ t.Errorf("For %T unmarshal %q, want %v, got error: %v", test.value, test.str, test.value, err)
+ } else if err == nil && test.wantUnmarshalErr {
+ t.Errorf("For %T unmarshal %q, want error, got %v", test.value, test.str, resultValue)
+ } else if err == nil && !test.value.Equal(resultValue) {
+ t.Errorf("For %T unmarshal %q, want %v, got %v", test.value, test.str, test.value, resultValue)
+ }
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/huin/goupnp/ssdp/registry.go b/Godeps/_workspace/src/github.com/huin/goupnp/ssdp/registry.go
new file mode 100644
index 000000000..38d10203f
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/huin/goupnp/ssdp/registry.go
@@ -0,0 +1,202 @@
+package ssdp
+
+import (
+ "fmt"
+ "log"
+ "net/http"
+ "net/url"
+ "regexp"
+ "strconv"
+ "sync"
+ "time"
+
+ "github.com/huin/goupnp/httpu"
+)
+
+const (
+ maxExpiryTimeSeconds = 24 * 60 * 60
+)
+
+var (
+ maxAgeRx = regexp.MustCompile("max-age=([0-9]+)")
+)
+
+type Entry struct {
+ // The address that the entry data was actually received from.
+ RemoteAddr string
+ // Unique Service Name. Identifies a unique instance of a device or service.
+ USN string
+ // Notfication Type. The type of device or service being announced.
+ NT string
+ // Server's self-identifying string.
+ Server string
+ Host string
+ // Location of the UPnP root device description.
+ Location *url.URL
+
+ // Despite BOOTID,CONFIGID being required fields, apparently they are not
+ // always set by devices. Set to -1 if not present.
+
+ BootID int32
+ ConfigID int32
+
+ SearchPort uint16
+
+ // When the last update was received for this entry identified by this USN.
+ LastUpdate time.Time
+ // When the last update's cached values are advised to expire.
+ CacheExpiry time.Time
+}
+
+func newEntryFromRequest(r *http.Request) (*Entry, error) {
+ now := time.Now()
+ expiryDuration, err := parseCacheControlMaxAge(r.Header.Get("CACHE-CONTROL"))
+ if err != nil {
+ return nil, fmt.Errorf("ssdp: error parsing CACHE-CONTROL max age: %v", err)
+ }
+
+ loc, err := url.Parse(r.Header.Get("LOCATION"))
+ if err != nil {
+ return nil, fmt.Errorf("ssdp: error parsing entry Location URL: %v", err)
+ }
+
+ bootID, err := parseUpnpIntHeader(r.Header, "BOOTID.UPNP.ORG", -1)
+ if err != nil {
+ return nil, err
+ }
+ configID, err := parseUpnpIntHeader(r.Header, "CONFIGID.UPNP.ORG", -1)
+ if err != nil {
+ return nil, err
+ }
+ searchPort, err := parseUpnpIntHeader(r.Header, "SEARCHPORT.UPNP.ORG", ssdpSearchPort)
+ if err != nil {
+ return nil, err
+ }
+
+ if searchPort < 1 || searchPort > 65535 {
+ return nil, fmt.Errorf("ssdp: search port %d is out of range", searchPort)
+ }
+
+ return &Entry{
+ RemoteAddr: r.RemoteAddr,
+ USN: r.Header.Get("USN"),
+ NT: r.Header.Get("NT"),
+ Server: r.Header.Get("SERVER"),
+ Host: r.Header.Get("HOST"),
+ Location: loc,
+ BootID: bootID,
+ ConfigID: configID,
+ SearchPort: uint16(searchPort),
+ LastUpdate: now,
+ CacheExpiry: now.Add(expiryDuration),
+ }, nil
+}
+
+func parseCacheControlMaxAge(cc string) (time.Duration, error) {
+ matches := maxAgeRx.FindStringSubmatch(cc)
+ if len(matches) != 2 {
+ return 0, fmt.Errorf("did not find exactly one max-age in cache control header: %q", cc)
+ }
+ expirySeconds, err := strconv.ParseInt(matches[1], 10, 16)
+ if err != nil {
+ return 0, err
+ }
+ if expirySeconds < 1 || expirySeconds > maxExpiryTimeSeconds {
+ return 0, fmt.Errorf("rejecting bad expiry time of %d seconds", expirySeconds)
+ }
+ return time.Duration(expirySeconds) * time.Second, nil
+}
+
+// parseUpnpIntHeader is intended to parse the
+// {BOOT,CONFIGID,SEARCHPORT}.UPNP.ORG header fields. It returns the def if
+// the head is empty or missing.
+func parseUpnpIntHeader(headers http.Header, headerName string, def int32) (int32, error) {
+ s := headers.Get(headerName)
+ if s == "" {
+ return def, nil
+ }
+ v, err := strconv.ParseInt(s, 10, 32)
+ if err != nil {
+ return 0, fmt.Errorf("ssdp: could not parse header %s: %v", headerName, err)
+ }
+ return int32(v), nil
+}
+
+var _ httpu.Handler = new(Registry)
+
+// Registry maintains knowledge of discovered devices and services.
+type Registry struct {
+ lock sync.Mutex
+ byUSN map[string]*Entry
+}
+
+func NewRegistry() *Registry {
+ return &Registry{
+ byUSN: make(map[string]*Entry),
+ }
+}
+
+// ServeMessage implements httpu.Handler, and uses SSDP NOTIFY requests to
+// maintain the registry of devices and services.
+func (reg *Registry) ServeMessage(r *http.Request) {
+ if r.Method != methodNotify {
+ return
+ }
+
+ nts := r.Header.Get("nts")
+
+ var err error
+ switch nts {
+ case ntsAlive:
+ err = reg.handleNTSAlive(r)
+ case ntsUpdate:
+ err = reg.handleNTSUpdate(r)
+ case ntsByebye:
+ err = reg.handleNTSByebye(r)
+ default:
+ err = fmt.Errorf("unknown NTS value: %q", nts)
+ }
+ log.Printf("In %s request from %s: %v", nts, r.RemoteAddr, err)
+}
+
+func (reg *Registry) handleNTSAlive(r *http.Request) error {
+ entry, err := newEntryFromRequest(r)
+ if err != nil {
+ return err
+ }
+
+ reg.lock.Lock()
+ defer reg.lock.Unlock()
+
+ reg.byUSN[entry.USN] = entry
+
+ return nil
+}
+
+func (reg *Registry) handleNTSUpdate(r *http.Request) error {
+ entry, err := newEntryFromRequest(r)
+ if err != nil {
+ return err
+ }
+ nextBootID, err := parseUpnpIntHeader(r.Header, "NEXTBOOTID.UPNP.ORG", -1)
+ if err != nil {
+ return err
+ }
+ entry.BootID = nextBootID
+
+ reg.lock.Lock()
+ defer reg.lock.Unlock()
+
+ reg.byUSN[entry.USN] = entry
+
+ return nil
+}
+
+func (reg *Registry) handleNTSByebye(r *http.Request) error {
+ reg.lock.Lock()
+ defer reg.lock.Unlock()
+
+ delete(reg.byUSN, r.Header.Get("USN"))
+
+ return nil
+}
diff --git a/Godeps/_workspace/src/github.com/huin/goupnp/ssdp/ssdp.go b/Godeps/_workspace/src/github.com/huin/goupnp/ssdp/ssdp.go
new file mode 100644
index 000000000..8178f5d94
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/huin/goupnp/ssdp/ssdp.go
@@ -0,0 +1,83 @@
+package ssdp
+
+import (
+ "errors"
+ "log"
+ "net/http"
+ "net/url"
+ "strconv"
+ "time"
+
+ "github.com/huin/goupnp/httpu"
+)
+
+const (
+ ssdpDiscover = `"ssdp:discover"`
+ ntsAlive = `ssdp:alive`
+ ntsByebye = `ssdp:byebye`
+ ntsUpdate = `ssdp:update`
+ ssdpUDP4Addr = "239.255.255.250:1900"
+ ssdpSearchPort = 1900
+ methodSearch = "M-SEARCH"
+ methodNotify = "NOTIFY"
+)
+
+// SSDPRawSearch performs a fairly raw SSDP search request, and returns the
+// unique response(s) that it receives. Each response has the requested
+// searchTarget, a USN, and a valid location. maxWaitSeconds states how long to
+// wait for responses in seconds, and must be a minimum of 1 (the
+// implementation waits an additional 100ms for responses to arrive), 2 is a
+// reasonable value for this. numSends is the number of requests to send - 3 is
+// a reasonable value for this.
+func SSDPRawSearch(httpu *httpu.HTTPUClient, searchTarget string, maxWaitSeconds int, numSends int) ([]*http.Response, error) {
+ if maxWaitSeconds < 1 {
+ return nil, errors.New("ssdp: maxWaitSeconds must be >= 1")
+ }
+
+ seenUsns := make(map[string]bool)
+ var responses []*http.Response
+ req := http.Request{
+ Method: methodSearch,
+ // TODO: Support both IPv4 and IPv6.
+ Host: ssdpUDP4Addr,
+ URL: &url.URL{Opaque: "*"},
+ Header: http.Header{
+ // Putting headers in here avoids them being title-cased.
+ // (The UPnP discovery protocol uses case-sensitive headers)
+ "HOST": []string{ssdpUDP4Addr},
+ "MX": []string{strconv.FormatInt(int64(maxWaitSeconds), 10)},
+ "MAN": []string{ssdpDiscover},
+ "ST": []string{searchTarget},
+ },
+ }
+ allResponses, err := httpu.Do(&req, time.Duration(maxWaitSeconds)*time.Second+100*time.Millisecond, numSends)
+ if err != nil {
+ return nil, err
+ }
+ for _, response := range allResponses {
+ if response.StatusCode != 200 {
+ log.Printf("ssdp: got response status code %q in search response", response.Status)
+ continue
+ }
+ if st := response.Header.Get("ST"); st != searchTarget {
+ log.Printf("ssdp: got unexpected search target result %q", st)
+ continue
+ }
+ location, err := response.Location()
+ if err != nil {
+ log.Printf("ssdp: no usable location in search response (discarding): %v", err)
+ continue
+ }
+ usn := response.Header.Get("USN")
+ if usn == "" {
+ log.Printf("ssdp: empty/missing USN in search response (using location instead): %v", err)
+ usn = location.String()
+ }
+ if _, alreadySeen := seenUsns[usn]; !alreadySeen {
+ seenUsns[usn] = true
+ responses = append(responses, response)
+ }
+ }
+
+ return responses, nil
+}
diff --git a/Godeps/_workspace/src/github.com/jackpal/go-nat-pmp/LICENSE b/Godeps/_workspace/src/github.com/jackpal/go-nat-pmp/LICENSE
new file mode 100644
index 000000000..249514b0f
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/jackpal/go-nat-pmp/LICENSE
@@ -0,0 +1,13 @@
+ Copyright 2013 John Howard Palevich
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
diff --git a/Godeps/_workspace/src/github.com/jackpal/go-nat-pmp/README.md b/Godeps/_workspace/src/github.com/jackpal/go-nat-pmp/README.md
new file mode 100644
index 000000000..15f72fd81
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/jackpal/go-nat-pmp/README.md
@@ -0,0 +1,48 @@
+go-nat-pmp
+==========
+
+A Go language client for the NAT-PMP internet protocol for port mapping and discovering the external
+IP address of a firewall.
+
+NAT-PMP is supported by Apple brand routers and open source routers like Tomato and DD-WRT.
+
+See http://tools.ietf.org/html/draft-cheshire-nat-pmp-03
+
+Get the package
+---------------
+
+ go get -u github.com/jackpal/go-nat-pmp
+
+Usage
+-----
+
+ import natpmp "github.com/jackpal/go-nat-pmp"
+
+ client := natpmp.NewClient(gatewayIP)
+ response, err := client.GetExternalAddress()
+ if err != nil {
+ return
+ }
+ print("External IP address:", response.ExternalIPAddress)
+
+Notes
+-----
+
+There doesn't seem to be an easy way to programmatically determine the address of the default gateway.
+(Linux and OSX have a "routes" kernel API that can be examined to get this information, but there is
+no Go package for getting this information.)
+
+Clients
+-------
+
+This library is used in the Taipei Torrent BitTorrent client http://github.com/jackpal/Taipei-Torrent
+
+Complete documentation
+----------------------
+
+ http://godoc.org/github.com/jackpal/go-nat-pmp
+
+License
+-------
+
+This project is licensed under the Apache License 2.0.
diff --git a/Godeps/_workspace/src/github.com/jackpal/go-nat-pmp/natpmp.go b/Godeps/_workspace/src/github.com/jackpal/go-nat-pmp/natpmp.go
new file mode 100644
index 000000000..8ce4e8342
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/jackpal/go-nat-pmp/natpmp.go
@@ -0,0 +1,184 @@
+package natpmp
+
+import (
+ "fmt"
+ "log"
+ "net"
+ "time"
+)
+
+// Implement the NAT-PMP protocol, typically supported by Apple routers and open source
+// routers such as DD-WRT and Tomato.
+//
+// See http://tools.ietf.org/html/draft-cheshire-nat-pmp-03
+//
+// Usage:
+//
+// client := natpmp.NewClient(gatewayIP)
+// response, err := client.GetExternalAddress()
+
+const nAT_PMP_PORT = 5351
+
+const nAT_TRIES = 9
+
+const nAT_INITIAL_MS = 250
+
+// The recommended mapping lifetime for AddPortMapping
+const RECOMMENDED_MAPPING_LIFETIME_SECONDS = 3600
+
+// Client is a NAT-PMP protocol client.
+type Client struct {
+ gateway net.IP
+}
+
+// Create a NAT-PMP client for the NAT-PMP server at the gateway.
+func NewClient(gateway net.IP) (nat *Client) {
+ return &Client{gateway}
+}
+
+// Results of the NAT-PMP GetExternalAddress operation
+type GetExternalAddressResult struct {
+ SecondsSinceStartOfEpoc uint32
+ ExternalIPAddress [4]byte
+}
+
+// Get the external address of the router.
+func (n *Client) GetExternalAddress() (result *GetExternalAddressResult, err error) {
+ msg := make([]byte, 2)
+ msg[0] = 0 // Version 0
+ msg[1] = 0 // OP Code 0
+ response, err := n.rpc(msg, 12)
+ if err != nil {
+ return
+ }
+ result = &GetExternalAddressResult{}
+ result.SecondsSinceStartOfEpoc = readNetworkOrderUint32(response[4:8])
+ copy(result.ExternalIPAddress[:], response[8:12])
+ return
+}
+
+// Results of the NAT-PMP AddPortMapping operation
+type AddPortMappingResult struct {
+ SecondsSinceStartOfEpoc uint32
+ InternalPort uint16
+ MappedExternalPort uint16
+ PortMappingLifetimeInSeconds uint32
+}
+
+// Add (or delete) a port mapping. To delete a mapping, set the requestedExternalPort and lifetime to 0
+func (n *Client) AddPortMapping(protocol string, internalPort, requestedExternalPort int, lifetime int) (result *AddPortMappingResult, err error) {
+ var opcode byte
+ if protocol == "udp" {
+ opcode = 1
+ } else if protocol == "tcp" {
+ opcode = 2
+ } else {
+ err = fmt.Errorf("unknown protocol %v", protocol)
+ return
+ }
+ msg := make([]byte, 12)
+ msg[0] = 0 // Version 0
+ msg[1] = opcode
+ writeNetworkOrderUint16(msg[4:6], uint16(internalPort))
+ writeNetworkOrderUint16(msg[6:8], uint16(requestedExternalPort))
+ writeNetworkOrderUint32(msg[8:12], uint32(lifetime))
+ response, err := n.rpc(msg, 16)
+ if err != nil {
+ return
+ }
+ result = &AddPortMappingResult{}
+ result.SecondsSinceStartOfEpoc = readNetworkOrderUint32(response[4:8])
+ result.InternalPort = readNetworkOrderUint16(response[8:10])
+ result.MappedExternalPort = readNetworkOrderUint16(response[10:12])
+ result.PortMappingLifetimeInSeconds = readNetworkOrderUint32(response[12:16])
+ return
+}
+
+func (n *Client) rpc(msg []byte, resultSize int) (result []byte, err error) {
+ var server net.UDPAddr
+ server.IP = n.gateway
+ server.Port = nAT_PMP_PORT
+ conn, err := net.DialUDP("udp", nil, &server)
+ if err != nil {
+ return
+ }
+ defer conn.Close()
+
+ result = make([]byte, resultSize)
+
+ needNewDeadline := true
+
+ var tries uint
+ for tries = 0; tries < nAT_TRIES; {
+ if needNewDeadline {
+ err = conn.SetDeadline(time.Now().Add((nAT_INITIAL_MS << tries) * time.Millisecond))
+ if err != nil {
+ return
+ }
+ needNewDeadline = false
+ }
+ _, err = conn.Write(msg)
+ if err != nil {
+ return
+ }
+ var bytesRead int
+ var remoteAddr *net.UDPAddr
+ bytesRead, remoteAddr, err = conn.ReadFromUDP(result)
+ if err != nil {
+ if err.(net.Error).Timeout() {
+ tries++
+ needNewDeadline = true
+ continue
+ }
+ return
+ }
+ if !remoteAddr.IP.Equal(n.gateway) {
+ log.Printf("Ignoring packet because IPs differ:", remoteAddr, n.gateway)
+ // Ignore this packet.
+ // Continue without increasing retransmission timeout or deadline.
+ continue
+ }
+ if bytesRead != resultSize {
+ err = fmt.Errorf("unexpected result size %d, expected %d", bytesRead, resultSize)
+ return
+ }
+ if result[0] != 0 {
+ err = fmt.Errorf("unknown protocol version %d", result[0])
+ return
+ }
+ expectedOp := msg[1] | 0x80
+ if result[1] != expectedOp {
+ err = fmt.Errorf("Unexpected opcode %d. Expected %d", result[1], expectedOp)
+ return
+ }
+ resultCode := readNetworkOrderUint16(result[2:4])
+ if resultCode != 0 {
+ err = fmt.Errorf("Non-zero result code %d", resultCode)
+ return
+ }
+ // If we got here the RPC is good.
+ return
+ }
+ err = fmt.Errorf("Timed out trying to contact gateway")
+ return
+}
+
+func writeNetworkOrderUint16(buf []byte, d uint16) {
+ buf[0] = byte(d >> 8)
+ buf[1] = byte(d)
+}
+
+func writeNetworkOrderUint32(buf []byte, d uint32) {
+ buf[0] = byte(d >> 24)
+ buf[1] = byte(d >> 16)
+ buf[2] = byte(d >> 8)
+ buf[3] = byte(d)
+}
+
+func readNetworkOrderUint16(buf []byte) uint16 {
+ return (uint16(buf[0]) << 8) | uint16(buf[1])
+}
+
+func readNetworkOrderUint32(buf []byte) uint32 {
+ return (uint32(buf[0]) << 24) | (uint32(buf[1]) << 16) | (uint32(buf[2]) << 8) | uint32(buf[3])
+}
diff --git a/Godeps/_workspace/src/github.com/kardianos/osext/LICENSE b/Godeps/_workspace/src/github.com/kardianos/osext/LICENSE
new file mode 100644
index 000000000..744875676
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/kardianos/osext/LICENSE
@@ -0,0 +1,27 @@
+Copyright (c) 2012 The Go Authors. All rights reserved.
+
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions are
+met:
+
+ * Redistributions of source code must retain the above copyright
+notice, this list of conditions and the following disclaimer.
+ * Redistributions in binary form must reproduce the above
+copyright notice, this list of conditions and the following disclaimer
+in the documentation and/or other materials provided with the
+distribution.
+ * Neither the name of Google Inc. nor the names of its
+contributors may be used to endorse or promote products derived from
+this software without specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
diff --git a/Godeps/_workspace/src/github.com/kardianos/osext/README.md b/Godeps/_workspace/src/github.com/kardianos/osext/README.md
new file mode 100644
index 000000000..820e1ecb5
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/kardianos/osext/README.md
@@ -0,0 +1,14 @@
+### Extensions to the "os" package.
+
+## Find the current Executable and ExecutableFolder.
+
+There is sometimes utility in finding the current executable file
+that is running. This can be used for upgrading the current executable
+or finding resources located relative to the executable file.
+
+Multi-platform and supports:
+ * Linux
+ * OS X
+ * Windows
+ * Plan 9
+ * BSDs.
diff --git a/Godeps/_workspace/src/github.com/kardianos/osext/osext.go b/Godeps/_workspace/src/github.com/kardianos/osext/osext.go
new file mode 100644
index 000000000..4ed4b9aa3
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/kardianos/osext/osext.go
@@ -0,0 +1,27 @@
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Extensions to the standard "os" package.
+package osext
+
+import "path/filepath"
+
+// Executable returns an absolute path that can be used to
+// re-invoke the current program.
+// It may not be valid after the current program exits.
+func Executable() (string, error) {
+ p, err := executable()
+ return filepath.Clean(p), err
+}
+
+// Returns same path as Executable, returns just the folder
+// path. Excludes the executable name.
+func ExecutableFolder() (string, error) {
+ p, err := Executable()
+ if err != nil {
+ return "", err
+ }
+ folder, _ := filepath.Split(p)
+ return folder, nil
+}
diff --git a/Godeps/_workspace/src/github.com/kardianos/osext/osext_plan9.go b/Godeps/_workspace/src/github.com/kardianos/osext/osext_plan9.go
new file mode 100644
index 000000000..655750c54
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/kardianos/osext/osext_plan9.go
@@ -0,0 +1,20 @@
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+package osext
+
+import (
+ "os"
+ "strconv"
+ "syscall"
+)
+
+func executable() (string, error) {
+ f, err := os.Open("/proc/" + strconv.Itoa(os.Getpid()) + "/text")
+ if err != nil {
+ return "", err
+ }
+ defer f.Close()
+ return syscall.Fd2path(int(f.Fd()))
+}
diff --git a/Godeps/_workspace/src/github.com/kardianos/osext/osext_procfs.go b/Godeps/_workspace/src/github.com/kardianos/osext/osext_procfs.go
new file mode 100644
index 000000000..a50021ad5
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/kardianos/osext/osext_procfs.go
@@ -0,0 +1,28 @@
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// +build linux netbsd openbsd solaris dragonfly
+
+package osext
+
+import (
+ "errors"
+ "fmt"
+ "os"
+ "runtime"
+)
+
+func executable() (string, error) {
+ switch runtime.GOOS {
+ case "linux":
+ return os.Readlink("/proc/self/exe")
+ case "netbsd":
+ return os.Readlink("/proc/curproc/exe")
+ case "openbsd", "dragonfly":
+ return os.Readlink("/proc/curproc/file")
+ case "solaris":
+ return os.Readlink(fmt.Sprintf("/proc/%d/path/a.out", os.Getpid()))
+ }
+ return "", errors.New("ExecPath not implemented for " + runtime.GOOS)
+}
diff --git a/Godeps/_workspace/src/github.com/kardianos/osext/osext_sysctl.go b/Godeps/_workspace/src/github.com/kardianos/osext/osext_sysctl.go
new file mode 100644
index 000000000..b66cac878
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/kardianos/osext/osext_sysctl.go
@@ -0,0 +1,79 @@
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// +build darwin freebsd
+
+package osext
+
+import (
+ "os"
+ "path/filepath"
+ "runtime"
+ "syscall"
+ "unsafe"
+)
+
+var initCwd, initCwdErr = os.Getwd()
+
+func executable() (string, error) {
+ var mib [4]int32
+ switch runtime.GOOS {
+ case "freebsd":
+ mib = [4]int32{1 /* CTL_KERN */, 14 /* KERN_PROC */, 12 /* KERN_PROC_PATHNAME */, -1}
+ case "darwin":
+ mib = [4]int32{1 /* CTL_KERN */, 38 /* KERN_PROCARGS */, int32(os.Getpid()), -1}
+ }
+
+ n := uintptr(0)
+ // Get length.
+ _, _, errNum := syscall.Syscall6(syscall.SYS___SYSCTL, uintptr(unsafe.Pointer(&mib[0])), 4, 0, uintptr(unsafe.Pointer(&n)), 0, 0)
+ if errNum != 0 {
+ return "", errNum
+ }
+ if n == 0 { // This shouldn't happen.
+ return "", nil
+ }
+ buf := make([]byte, n)
+ _, _, errNum = syscall.Syscall6(syscall.SYS___SYSCTL, uintptr(unsafe.Pointer(&mib[0])), 4, uintptr(unsafe.Pointer(&buf[0])), uintptr(unsafe.Pointer(&n)), 0, 0)
+ if errNum != 0 {
+ return "", errNum
+ }
+ if n == 0 { // This shouldn't happen.
+ return "", nil
+ }
+ for i, v := range buf {
+ if v == 0 {
+ buf = buf[:i]
+ break
+ }
+ }
+ var err error
+ execPath := string(buf)
+ // execPath will not be empty due to above checks.
+ // Try to get the absolute path if the execPath is not rooted.
+ if execPath[0] != '/' {
+ execPath, err = getAbs(execPath)
+ if err != nil {
+ return execPath, err
+ }
+ }
+ // For darwin KERN_PROCARGS may return the path to a symlink rather than the
+ // actual executable.
+ if runtime.GOOS == "darwin" {
+ if execPath, err = filepath.EvalSymlinks(execPath); err != nil {
+ return execPath, err
+ }
+ }
+ return execPath, nil
+}
+
+func getAbs(execPath string) (string, error) {
+ if initCwdErr != nil {
+ return execPath, initCwdErr
+ }
+ // The execPath may begin with a "../" or a "./" so clean it first.
+ // Join the two paths, trailing and starting slashes undetermined, so use
+ // the generic Join function.
+ return filepath.Join(initCwd, filepath.Clean(execPath)), nil
+}
diff --git a/Godeps/_workspace/src/github.com/kardianos/osext/osext_test.go b/Godeps/_workspace/src/github.com/kardianos/osext/osext_test.go
new file mode 100644
index 000000000..dc661dbc2
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/kardianos/osext/osext_test.go
@@ -0,0 +1,79 @@
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// +build darwin linux freebsd netbsd windows
+
+package osext
+
+import (
+ "fmt"
+ "os"
+ oexec "os/exec"
+ "path/filepath"
+ "runtime"
+ "testing"
+)
+
+const execPath_EnvVar = "OSTEST_OUTPUT_EXECPATH"
+
+func TestExecPath(t *testing.T) {
+ ep, err := Executable()
+ if err != nil {
+ t.Fatalf("ExecPath failed: %v", err)
+ }
+ // we want fn to be of the form "dir/prog"
+ dir := filepath.Dir(filepath.Dir(ep))
+ fn, err := filepath.Rel(dir, ep)
+ if err != nil {
+ t.Fatalf("filepath.Rel: %v", err)
+ }
+ cmd := &oexec.Cmd{}
+ // make child start with a relative program path
+ cmd.Dir = dir
+ cmd.Path = fn
+ // forge argv[0] for child, so that we can verify we could correctly
+ // get real path of the executable without influenced by argv[0].
+ cmd.Args = []string{"-", "-test.run=XXXX"}
+ cmd.Env = []string{fmt.Sprintf("%s=1", execPath_EnvVar)}
+ out, err := cmd.CombinedOutput()
+ if err != nil {
+ t.Fatalf("exec(self) failed: %v", err)
+ }
+ outs := string(out)
+ if !filepath.IsAbs(outs) {
+ t.Fatalf("Child returned %q, want an absolute path", out)
+ }
+ if !sameFile(outs, ep) {
+ t.Fatalf("Child returned %q, not the same file as %q", out, ep)
+ }
+}
+
+func sameFile(fn1, fn2 string) bool {
+ fi1, err := os.Stat(fn1)
+ if err != nil {
+ return false
+ }
+ fi2, err := os.Stat(fn2)
+ if err != nil {
+ return false
+ }
+ return os.SameFile(fi1, fi2)
+}
+
+func init() {
+ if e := os.Getenv(execPath_EnvVar); e != "" {
+ // first chdir to another path
+ dir := "/"
+ if runtime.GOOS == "windows" {
+ dir = filepath.VolumeName(".")
+ }
+ os.Chdir(dir)
+ if ep, err := Executable(); err != nil {
+ fmt.Fprint(os.Stderr, "ERROR: ", err)
+ } else {
+ fmt.Fprint(os.Stderr, ep)
+ }
+ os.Exit(0)
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/kardianos/osext/osext_windows.go b/Godeps/_workspace/src/github.com/kardianos/osext/osext_windows.go
new file mode 100644
index 000000000..72d282cf8
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/kardianos/osext/osext_windows.go
@@ -0,0 +1,34 @@
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+package osext
+
+import (
+ "syscall"
+ "unicode/utf16"
+ "unsafe"
+)
+
+var (
+ kernel = syscall.MustLoadDLL("kernel32.dll")
+ getModuleFileNameProc = kernel.MustFindProc("GetModuleFileNameW")
+)
+
+// GetModuleFileName() with hModule = NULL
+func executable() (exePath string, err error) {
+ return getModuleFileName()
+}
+
+func getModuleFileName() (string, error) {
+ var n uint32
+ b := make([]uint16, syscall.MAX_PATH)
+ size := uint32(len(b))
+
+ r0, _, e1 := getModuleFileNameProc.Call(0, uintptr(unsafe.Pointer(&b[0])), uintptr(size))
+ n = uint32(r0)
+ if n == 0 {
+ return "", e1
+ }
+ return string(utf16.Decode(b[0:n])), nil
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/.gitignore b/Godeps/_workspace/src/github.com/obscuren/qml/.gitignore
new file mode 100644
index 000000000..e4b7f45b7
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/.gitignore
@@ -0,0 +1,5 @@
+examples/qmlscene/qmlscene
+examples/snapweb/snapweb
+examples/particle/particle
+gl/gengl/gengl
+*.swp
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/LICENSE b/Godeps/_workspace/src/github.com/obscuren/qml/LICENSE
new file mode 100644
index 000000000..53320c352
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/LICENSE
@@ -0,0 +1,185 @@
+This software is licensed under the LGPLv3, included below.
+
+As a special exception to the GNU Lesser General Public License version 3
+("LGPL3"), the copyright holders of this Library give you permission to
+convey to a third party a Combined Work that links statically or dynamically
+to this Library without providing any Minimal Corresponding Source or
+Minimal Application Code as set out in 4d or providing the installation
+information set out in section 4e, provided that you comply with the other
+provisions of LGPL3 and provided that you meet, for the Application the
+terms and conditions of the license(s) which apply to the Application.
+
+Except as stated in this special exception, the provisions of LGPL3 will
+continue to comply in full to this Library. If you modify this Library, you
+may apply this exception to your version of this Library, but you are not
+obliged to do so. If you do not wish to do so, delete this exception
+statement from your version. This exception does not (and cannot) modify any
+license terms which apply to the Application, with which you must still
+comply.
+
+
+ GNU LESSER GENERAL PUBLIC LICENSE
+ Version 3, 29 June 2007
+
+ Copyright (C) 2007 Free Software Foundation, Inc. <http://fsf.org/>
+ Everyone is permitted to copy and distribute verbatim copies
+ of this license document, but changing it is not allowed.
+
+
+ This version of the GNU Lesser General Public License incorporates
+the terms and conditions of version 3 of the GNU General Public
+License, supplemented by the additional permissions listed below.
+
+ 0. Additional Definitions.
+
+ As used herein, "this License" refers to version 3 of the GNU Lesser
+General Public License, and the "GNU GPL" refers to version 3 of the GNU
+General Public License.
+
+ "The Library" refers to a covered work governed by this License,
+other than an Application or a Combined Work as defined below.
+
+ An "Application" is any work that makes use of an interface provided
+by the Library, but which is not otherwise based on the Library.
+Defining a subclass of a class defined by the Library is deemed a mode
+of using an interface provided by the Library.
+
+ A "Combined Work" is a work produced by combining or linking an
+Application with the Library. The particular version of the Library
+with which the Combined Work was made is also called the "Linked
+Version".
+
+ The "Minimal Corresponding Source" for a Combined Work means the
+Corresponding Source for the Combined Work, excluding any source code
+for portions of the Combined Work that, considered in isolation, are
+based on the Application, and not on the Linked Version.
+
+ The "Corresponding Application Code" for a Combined Work means the
+object code and/or source code for the Application, including any data
+and utility programs needed for reproducing the Combined Work from the
+Application, but excluding the System Libraries of the Combined Work.
+
+ 1. Exception to Section 3 of the GNU GPL.
+
+ You may convey a covered work under sections 3 and 4 of this License
+without being bound by section 3 of the GNU GPL.
+
+ 2. Conveying Modified Versions.
+
+ If you modify a copy of the Library, and, in your modifications, a
+facility refers to a function or data to be supplied by an Application
+that uses the facility (other than as an argument passed when the
+facility is invoked), then you may convey a copy of the modified
+version:
+
+ a) under this License, provided that you make a good faith effort to
+ ensure that, in the event an Application does not supply the
+ function or data, the facility still operates, and performs
+ whatever part of its purpose remains meaningful, or
+
+ b) under the GNU GPL, with none of the additional permissions of
+ this License applicable to that copy.
+
+ 3. Object Code Incorporating Material from Library Header Files.
+
+ The object code form of an Application may incorporate material from
+a header file that is part of the Library. You may convey such object
+code under terms of your choice, provided that, if the incorporated
+material is not limited to numerical parameters, data structure
+layouts and accessors, or small macros, inline functions and templates
+(ten or fewer lines in length), you do both of the following:
+
+ a) Give prominent notice with each copy of the object code that the
+ Library is used in it and that the Library and its use are
+ covered by this License.
+
+ b) Accompany the object code with a copy of the GNU GPL and this license
+ document.
+
+ 4. Combined Works.
+
+ You may convey a Combined Work under terms of your choice that,
+taken together, effectively do not restrict modification of the
+portions of the Library contained in the Combined Work and reverse
+engineering for debugging such modifications, if you also do each of
+the following:
+
+ a) Give prominent notice with each copy of the Combined Work that
+ the Library is used in it and that the Library and its use are
+ covered by this License.
+
+ b) Accompany the Combined Work with a copy of the GNU GPL and this license
+ document.
+
+ c) For a Combined Work that displays copyright notices during
+ execution, include the copyright notice for the Library among
+ these notices, as well as a reference directing the user to the
+ copies of the GNU GPL and this license document.
+
+ d) Do one of the following:
+
+ 0) Convey the Minimal Corresponding Source under the terms of this
+ License, and the Corresponding Application Code in a form
+ suitable for, and under terms that permit, the user to
+ recombine or relink the Application with a modified version of
+ the Linked Version to produce a modified Combined Work, in the
+ manner specified by section 6 of the GNU GPL for conveying
+ Corresponding Source.
+
+ 1) Use a suitable shared library mechanism for linking with the
+ Library. A suitable mechanism is one that (a) uses at run time
+ a copy of the Library already present on the user's computer
+ system, and (b) will operate properly with a modified version
+ of the Library that is interface-compatible with the Linked
+ Version.
+
+ e) Provide Installation Information, but only if you would otherwise
+ be required to provide such information under section 6 of the
+ GNU GPL, and only to the extent that such information is
+ necessary to install and execute a modified version of the
+ Combined Work produced by recombining or relinking the
+ Application with a modified version of the Linked Version. (If
+ you use option 4d0, the Installation Information must accompany
+ the Minimal Corresponding Source and Corresponding Application
+ Code. If you use option 4d1, you must provide the Installation
+ Information in the manner specified by section 6 of the GNU GPL
+ for conveying Corresponding Source.)
+
+ 5. Combined Libraries.
+
+ You may place library facilities that are a work based on the
+Library side by side in a single library together with other library
+facilities that are not Applications and are not covered by this
+License, and convey such a combined library under terms of your
+choice, if you do both of the following:
+
+ a) Accompany the combined library with a copy of the same work based
+ on the Library, uncombined with any other library facilities,
+ conveyed under the terms of this License.
+
+ b) Give prominent notice with the combined library that part of it
+ is a work based on the Library, and explaining where to find the
+ accompanying uncombined form of the same work.
+
+ 6. Revised Versions of the GNU Lesser General Public License.
+
+ The Free Software Foundation may publish revised and/or new versions
+of the GNU Lesser General Public License from time to time. Such new
+versions will be similar in spirit to the present version, but may
+differ in detail to address new problems or concerns.
+
+ Each version is given a distinguishing version number. If the
+Library as you received it specifies that a certain numbered version
+of the GNU Lesser General Public License "or any later version"
+applies to it, you have the option of following the terms and
+conditions either of that published version or of any later version
+published by the Free Software Foundation. If the Library as you
+received it does not specify a version number of the GNU Lesser
+General Public License, you may choose any version of the GNU Lesser
+General Public License ever published by the Free Software Foundation.
+
+ If the Library as you received it specifies that a proxy can decide
+whether future versions of the GNU Lesser General Public License shall
+apply, that proxy's public statement of acceptance of any version is
+permanent authorization for you to choose that version for the
+Library.
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/README.md b/Godeps/_workspace/src/github.com/obscuren/qml/README.md
new file mode 100644
index 000000000..e969c9e1d
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/README.md
@@ -0,0 +1,157 @@
+# QML support for the Go language
+
+Documentation
+-------------
+
+The introductory documentation as well as the detailed API documentation is
+available at [gopkg.in/qml.v1](http://godoc.org/gopkg.in/qml.v1).
+
+
+Blog posts
+----------
+
+Some relevant blog posts:
+
+ * [Announcing qml v1 for Go](http://blog.labix.org/2014/08/13/announcing-qml-v1-for-go)
+ * [Packing resources into Go qml binaries](http://blog.labix.org/2014/09/26/packing-resources-into-go-qml-binaries)
+ * [Go qml contest results](http://blog.labix.org/2014/04/25/qml-contest-results)
+ * [Arbitrary Qt extensions with Go qml](http://blog.labix.org/2014/03/21/arbitrary-qt-extensions-with-go-qml)
+ * [The new Go qml OpenGL API](http://blog.labix.org/2014/08/29/the-new-go-qml-opengl-api)
+ * [QML components with Go and OpenGL](http://blog.labix.org/2013/12/23/qml-components-with-go-and-opengl)
+
+
+Videos
+------
+
+These introductory videos demonstrate the use of Go QML:
+
+ * [Initial demo and overview](http://youtu.be/FVQlMrPa7lI)
+ * [Initial demo running on an Ubuntu Touch phone](http://youtu.be/HB-3o8Cysec)
+ * [Spinning Gopher with Go + QML + OpenGL](http://youtu.be/qkH7_dtOyPk)
+ * [SameGame QML tutorial in Go](http://youtu.be/z8noX48hiMI)
+
+
+Community
+---------
+
+Please join the [mailing list](https://groups.google.com/forum/#!forum/go-qml) for
+following relevant development news and discussing project details.
+
+
+Installation
+------------
+
+To try the alpha release you'll need:
+
+ * Go >= 1.2, for the C++ support of _go build_
+ * Qt 5.0.X or 5.1.X with the development files
+ * The Qt headers qmetaobject_p.h and qmetaobjectbuilder_p.h, for the dynamic meta object support
+
+See below for more details about getting these requirements installed in different environments and operating systems.
+
+After the requirements are satisfied, _go get_ should work as usual:
+
+ go get gopkg.in/qml.v1
+
+
+Requirements on Ubuntu
+----------------------
+
+If you are using Ubuntu, the [Ubuntu SDK](http://developer.ubuntu.com/get-started/) will take care of the Qt dependencies:
+
+ $ sudo add-apt-repository ppa:ubuntu-sdk-team/ppa
+ $ sudo apt-get update
+ $ sudo apt-get install qtdeclarative5-dev qtbase5-private-dev qtdeclarative5-private-dev libqt5opengl5-dev qtdeclarative5-qtquick2-plugin
+
+and Go >= 1.2 may be installed using [godeb](http://blog.labix.org/2013/06/15/in-flight-deb-packages-of-go):
+
+ $ # Pick the right one for your system: 386 or amd64
+ $ ARCH=amd64
+ $ wget -q https://godeb.s3.amazonaws.com/godeb-$ARCH.tar.gz
+ $ tar xzvf godeb-$ARCH.tar.gz
+ godeb
+ $ sudo mv godeb /usr/local/bin
+ $ godeb install
+ $ go get gopkg.in/qml.v1
+
+
+Requirements on Ubuntu Touch
+----------------------------
+
+After following the [installation instructions](https://wiki.ubuntu.com/Touch/Install) for Ubuntu Touch,
+run the following commands to get a working build environment inside the device:
+
+ $ adb shell
+ # cd /tmp
+ # wget https://github.com/go-qml/qml/raw/v1/cmd/ubuntu-touch/setup.sh
+ # /bin/bash setup.sh
+ # su - phablet
+ $
+
+At the end of setup.sh, the phablet user will have GOPATH=$HOME in the environment,
+the qml package will be built, and the particle example will be built and run. For
+stopping it from the command line, run as the phablet user:
+
+ $ ubuntu-app-stop gopkg.in.qml.particle-example
+
+for running it again:
+
+ $ ubuntu-app-launch gopkg.in.qml.particle-example
+
+These commands depend on the following file, installed by setup.sh:
+
+ ~/.local/share/applications/gopkg.in.qml.particle-example.desktop
+
+
+Requirements on Mac OS X
+------------------------
+
+On Mac OS X you'll need QT5. It's easiest to install with Homebrew, a
+third-party package management system for OS X.
+
+Installation instructions for Homebrew are here:
+
+ http://brew.sh/
+
+Then, install the qt5 and pkg-config packages:
+
+ $ brew install qt5 pkg-config
+
+Then, force brew to "link" qt5 (this makes it available under /usr/local):
+
+ $ brew link --force qt5
+
+And finally, fetch and install go-qml:
+
+ $ go get gopkg.in/qml.v1
+
+
+Requirements on Windows
+-----------------------
+
+On Windows you'll need the following:
+
+ * [MinGW gcc](http://sourceforge.net/projects/mingw/files/latest/download) 4.8.1 (install mingw-get and install the gcc from within the setup GUI)
+ * [Qt 5.1.1](http://download.qt-project.org/official_releases/qt/5.1/5.1.1/qt-windows-opensource-5.1.1-mingw48_opengl-x86-offline.exe) for MinGW 4.8
+ * [Go >= 1.2](http://golang.org/doc/install)
+
+Then, assuming Qt was installed under `C:\Qt5.1.1\`, set up the following environment variables in the respective configuration:
+
+ CPATH += C:\Qt5.1.1\5.1.1\mingw48_32\include
+ LIBRARY_PATH += C:\Qt5.1.1\5.1.1\mingw48_32\lib
+ PATH += C:\Qt5.1.1\5.1.1\mingw48_32\bin
+
+After reopening the shell for the environment changes to take effect, this should work:
+
+ go get gopkg.in/qml.v1
+
+
+Requirements everywhere else
+----------------------------
+
+If your operating system does not offer these dependencies readily,
+you may still have success installing [Go >= 1.2](http://golang.org/doc/install)
+and [Qt 5.0.2](http://download.qt-project.org/archive/qt/5.0/5.0.2/)
+directly from the upstreams. Note that you'll likely have to adapt
+environment variables to reflect the custom installation path for
+these libraries. See the instructions above for examples.
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/all.cpp b/Godeps/_workspace/src/github.com/obscuren/qml/all.cpp
new file mode 100644
index 000000000..965867b1b
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/all.cpp
@@ -0,0 +1,12 @@
+
+#include "cpp/capi.cpp"
+#include "cpp/govalue.cpp"
+#include "cpp/govaluetype.cpp"
+#include "cpp/idletimer.cpp"
+#include "cpp/connector.cpp"
+
+#include "cpp/moc_all.cpp"
+
+#ifdef _WIN32
+#include "cpp/mmemwin.cpp"
+#endif
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/bridge.go b/Godeps/_workspace/src/github.com/obscuren/qml/bridge.go
new file mode 100644
index 000000000..77b36a566
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/bridge.go
@@ -0,0 +1,681 @@
+package qml
+
+// #cgo CPPFLAGS: -I./cpp
+// #cgo CXXFLAGS: -std=c++0x -pedantic-errors -Wall -fno-strict-aliasing
+// #cgo LDFLAGS: -lstdc++
+// #cgo pkg-config: Qt5Core Qt5Widgets Qt5Quick
+//
+// #include <stdlib.h>
+//
+// #include "cpp/capi.h"
+//
+import "C"
+
+import (
+ "fmt"
+ "os"
+ "reflect"
+ "runtime"
+ "sync/atomic"
+ "unsafe"
+
+ "gopkg.in/qml.v1/cdata"
+)
+
+var (
+ guiFunc = make(chan func())
+ guiDone = make(chan struct{})
+ guiLock = 0
+ guiMainRef uintptr
+ guiPaintRef uintptr
+ guiIdleRun int32
+
+ initialized int32
+)
+
+func init() {
+ runtime.LockOSThread()
+ guiMainRef = cdata.Ref()
+}
+
+// Run runs the main QML event loop, runs f, and then terminates the
+// event loop once f returns.
+//
+// Most functions from the qml package block until Run is called.
+//
+// The Run function must necessarily be called from the same goroutine as
+// the main function or the application may fail when running on Mac OS.
+func Run(f func() error) error {
+ if cdata.Ref() != guiMainRef {
+ panic("Run must be called on the initial goroutine so apps are portable to Mac OS")
+ }
+ if !atomic.CompareAndSwapInt32(&initialized, 0, 1) {
+ panic("qml.Run called more than once")
+ }
+ C.newGuiApplication()
+ C.idleTimerInit((*C.int32_t)(&guiIdleRun))
+ done := make(chan error, 1)
+ go func() {
+ RunMain(func() {}) // Block until the event loop is running.
+ done <- f()
+ C.applicationExit()
+ }()
+ C.applicationExec()
+ return <-done
+}
+
+// RunMain runs f in the main QML thread and waits for f to return.
+//
+// This is meant to be used by extensions that integrate directly with the
+// underlying QML logic.
+func RunMain(f func()) {
+ ref := cdata.Ref()
+ if ref == guiMainRef || ref == atomic.LoadUintptr(&guiPaintRef) {
+ // Already within the GUI or render threads. Attempting to wait would deadlock.
+ f()
+ return
+ }
+
+ // Tell Qt we're waiting for the idle hook to be called.
+ if atomic.AddInt32(&guiIdleRun, 1) == 1 {
+ C.idleTimerStart()
+ }
+
+ // Send f to be executed by the idle hook in the main GUI thread.
+ guiFunc <- f
+
+ // Wait until f is done executing.
+ <-guiDone
+}
+
+// Lock freezes all QML activity by blocking the main event loop.
+// Locking is necessary before updating shared data structures
+// without race conditions.
+//
+// It's safe to use qml functionality while holding a lock, as
+// long as the requests made do not depend on follow up QML
+// events to be processed before returning. If that happens, the
+// problem will be observed as the application freezing.
+//
+// The Lock function is reentrant. That means it may be called
+// multiple times, and QML activities will only be resumed after
+// Unlock is called a matching number of times.
+func Lock() {
+ // TODO Better testing for this.
+ RunMain(func() {
+ guiLock++
+ })
+}
+
+// Unlock releases the QML event loop. See Lock for details.
+func Unlock() {
+ RunMain(func() {
+ if guiLock == 0 {
+ panic("qml.Unlock called without lock being held")
+ }
+ guiLock--
+ })
+}
+
+// Flush synchronously flushes all pending QML activities.
+func Flush() {
+ // TODO Better testing for this.
+ RunMain(func() {
+ C.applicationFlushAll()
+ })
+}
+
+// Changed notifies all QML bindings that the given field value has changed.
+//
+// For example:
+//
+// qml.Changed(&value, &value.Field)
+//
+func Changed(value, fieldAddr interface{}) {
+ valuev := reflect.ValueOf(value)
+ fieldv := reflect.ValueOf(fieldAddr)
+ for valuev.Kind() == reflect.Ptr {
+ valuev = valuev.Elem()
+ }
+ if fieldv.Kind() != reflect.Ptr {
+ panic("qml.Changed received non-address value as fieldAddr")
+ }
+ fieldv = fieldv.Elem()
+ if fieldv.Type().Size() == 0 {
+ panic("cannot report changes on zero-sized fields")
+ }
+ offset := fieldv.UnsafeAddr() - valuev.UnsafeAddr()
+ if !(0 <= offset && offset < valuev.Type().Size()) {
+ panic("provided field is not a member of the given value")
+ }
+
+ RunMain(func() {
+ tinfo := typeInfo(value)
+ for _, engine := range engines {
+ fold := engine.values[value]
+ for fold != nil {
+ C.goValueActivate(fold.cvalue, tinfo, C.int(offset))
+ fold = fold.next
+ }
+ // TODO typeNew might also be a linked list keyed by the gvalue.
+ // This would prevent the iteration and the deferrals.
+ for fold, _ = range typeNew {
+ if fold.gvalue == value {
+ // Activate these later so they don't get recursively moved
+ // out of typeNew while the iteration is still happening.
+ defer C.goValueActivate(fold.cvalue, tinfo, C.int(offset))
+ }
+ }
+ }
+ })
+}
+
+// hookIdleTimer is run once per iteration of the Qt event loop,
+// within the main GUI thread, but only if at least one goroutine
+// has atomically incremented guiIdleRun.
+//
+//export hookIdleTimer
+func hookIdleTimer() {
+ var f func()
+ for {
+ select {
+ case f = <-guiFunc:
+ default:
+ if guiLock > 0 {
+ f = <-guiFunc
+ } else {
+ return
+ }
+ }
+ f()
+ guiDone <- struct{}{}
+ atomic.AddInt32(&guiIdleRun, -1)
+ }
+}
+
+type valueFold struct {
+ engine *Engine
+ gvalue interface{}
+ cvalue unsafe.Pointer
+ init reflect.Value
+ prev *valueFold
+ next *valueFold
+ owner valueOwner
+}
+
+type valueOwner uint8
+
+const (
+ cppOwner = 1 << iota
+ jsOwner
+)
+
+// wrapGoValue creates a new GoValue object in C++ land wrapping
+// the Go value contained in the given interface.
+//
+// This must be run from the main GUI thread.
+func wrapGoValue(engine *Engine, gvalue interface{}, owner valueOwner) (cvalue unsafe.Pointer) {
+ gvaluev := reflect.ValueOf(gvalue)
+ gvaluek := gvaluev.Kind()
+ if gvaluek == reflect.Struct && !hashable(gvalue) {
+ name := gvaluev.Type().Name()
+ if name != "" {
+ name = " (" + name + ")"
+ }
+ panic("cannot hand an unhashable struct value" + name + " to QML logic; use its address instead")
+ }
+ if gvaluek == reflect.Ptr && gvaluev.Elem().Kind() == reflect.Ptr {
+ panic("cannot hand pointer of pointer to QML logic; use a simple pointer instead")
+ }
+
+ painting := cdata.Ref() == atomic.LoadUintptr(&guiPaintRef)
+
+ // Cannot reuse a jsOwner because the QML runtime may choose to destroy
+ // the value _after_ we hand it a new reference to the same value.
+ // See issue #68 for details.
+ prev, ok := engine.values[gvalue]
+ if ok && (prev.owner == cppOwner || painting) {
+ return prev.cvalue
+ }
+
+ if painting {
+ panic("cannot allocate new objects while painting")
+ }
+
+ parent := nilPtr
+ if owner == cppOwner {
+ parent = engine.addr
+ }
+ fold := &valueFold{
+ engine: engine,
+ gvalue: gvalue,
+ owner: owner,
+ }
+ fold.cvalue = C.newGoValue(unsafe.Pointer(fold), typeInfo(gvalue), parent)
+ if prev != nil {
+ // Put new fold first so the single cppOwner, if any, is always the first entry.
+ fold.next = prev
+ prev.prev = fold
+ }
+ engine.values[gvalue] = fold
+
+ //fmt.Printf("[DEBUG] value alive (wrapped): cvalue=%x gvalue=%x/%#v\n", fold.cvalue, addrOf(fold.gvalue), fold.gvalue)
+ stats.valuesAlive(+1)
+ C.engineSetContextForObject(engine.addr, fold.cvalue)
+ switch owner {
+ case cppOwner:
+ C.engineSetOwnershipCPP(engine.addr, fold.cvalue)
+ case jsOwner:
+ C.engineSetOwnershipJS(engine.addr, fold.cvalue)
+ }
+ return fold.cvalue
+}
+
+func addrOf(gvalue interface{}) uintptr {
+ return reflect.ValueOf(gvalue).Pointer()
+}
+
+// typeNew holds fold values that are created by registered types.
+// These values are special in two senses: first, they don't have a
+// reference to an engine before they are used in a context that can
+// set the reference; second, these values always hold a new cvalue,
+// because they are created as a side-effect of the registered type
+// being instantiated (it's too late to reuse an existent cvalue).
+//
+// For these reasons, typeNew holds the fold for these values until
+// their engine is known, and once it's known they may have to be
+// added to the linked list, since mulitple references for the same
+// gvalue may occur.
+var typeNew = make(map[*valueFold]bool)
+
+//export hookGoValueTypeNew
+func hookGoValueTypeNew(cvalue unsafe.Pointer, specp unsafe.Pointer) (foldp unsafe.Pointer) {
+ // Initialization is postponed until the engine is available, so that
+ // we can hand Init the qml.Object that represents the object.
+ init := reflect.ValueOf((*TypeSpec)(specp).Init)
+ fold := &valueFold{
+ init: init,
+ gvalue: reflect.New(init.Type().In(0).Elem()).Interface(),
+ cvalue: cvalue,
+ owner: jsOwner,
+ }
+ typeNew[fold] = true
+ //fmt.Printf("[DEBUG] value alive (type-created): cvalue=%x gvalue=%x/%#v\n", fold.cvalue, addrOf(fold.gvalue), fold.gvalue)
+ stats.valuesAlive(+1)
+ return unsafe.Pointer(fold)
+}
+
+//export hookGoValueDestroyed
+func hookGoValueDestroyed(enginep unsafe.Pointer, foldp unsafe.Pointer) {
+ fold := (*valueFold)(foldp)
+ engine := fold.engine
+ if engine == nil {
+ before := len(typeNew)
+ delete(typeNew, fold)
+ if len(typeNew) == before {
+ panic("destroying value without an associated engine; who created the value?")
+ }
+ } else if engines[engine.addr] == nil {
+ // Must never do that. The engine holds memory references that C++ depends on.
+ panic(fmt.Sprintf("engine %p was released from global list while its values were still alive", engine.addr))
+ } else {
+ switch {
+ case fold.prev != nil:
+ fold.prev.next = fold.next
+ if fold.next != nil {
+ fold.next.prev = fold.prev
+ }
+ case fold.next != nil:
+ fold.next.prev = fold.prev
+ if fold.prev != nil {
+ fold.prev.next = fold.next
+ } else {
+ fold.engine.values[fold.gvalue] = fold.next
+ }
+ default:
+ before := len(engine.values)
+ delete(engine.values, fold.gvalue)
+ if len(engine.values) == before {
+ panic("destroying value that knows about the engine, but the engine doesn't know about the value; who cleared the engine?")
+ }
+ if engine.destroyed && len(engine.values) == 0 {
+ delete(engines, engine.addr)
+ }
+ }
+ }
+ //fmt.Printf("[DEBUG] value destroyed: cvalue=%x gvalue=%x/%#v\n", fold.cvalue, addrOf(fold.gvalue), fold.gvalue)
+ stats.valuesAlive(-1)
+}
+
+func deref(value reflect.Value) reflect.Value {
+ for {
+ switch value.Kind() {
+ case reflect.Ptr, reflect.Interface:
+ value = value.Elem()
+ continue
+ }
+ return value
+ }
+ panic("cannot happen")
+}
+
+//export hookGoValueReadField
+func hookGoValueReadField(enginep, foldp unsafe.Pointer, reflectIndex, getIndex, setIndex C.int, resultdv *C.DataValue) {
+ fold := ensureEngine(enginep, foldp)
+
+ var field reflect.Value
+ if getIndex >= 0 {
+ field = reflect.ValueOf(fold.gvalue).Method(int(getIndex)).Call(nil)[0]
+ } else {
+ field = deref(reflect.ValueOf(fold.gvalue)).Field(int(reflectIndex))
+ }
+ field = deref(field)
+
+ // Cannot compare Type directly as field may be invalid (nil).
+ if field.Kind() == reflect.Slice && field.Type() == typeObjSlice {
+ // TODO Handle getters that return []qml.Object.
+ // TODO Handle other GoValue slices (!= []qml.Object).
+ resultdv.dataType = C.DTListProperty
+ *(*unsafe.Pointer)(unsafe.Pointer(&resultdv.data)) = C.newListProperty(foldp, C.intptr_t(reflectIndex), C.intptr_t(setIndex))
+ return
+ }
+
+ fieldk := field.Kind()
+ if fieldk == reflect.Slice || fieldk == reflect.Struct && field.Type() != typeRGBA {
+ if field.CanAddr() {
+ field = field.Addr()
+ } else if !hashable(field.Interface()) {
+ t := reflect.ValueOf(fold.gvalue).Type()
+ for t.Kind() == reflect.Ptr {
+ t = t.Elem()
+ }
+ panic(fmt.Sprintf("cannot access unaddressable and unhashable struct value on interface field %s.%s; value: %#v", t.Name(), t.Field(int(reflectIndex)).Name, field.Interface()))
+ }
+ }
+ var gvalue interface{}
+ if field.IsValid() {
+ gvalue = field.Interface()
+ }
+
+ // TODO Strings are being passed in an unsafe manner here. There is a
+ // small chance that the field is changed and the garbage collector is run
+ // before C++ has a chance to look at the data. We can solve this problem
+ // by queuing up values in a stack, and cleaning the stack when the
+ // idle timer fires next.
+ packDataValue(gvalue, resultdv, fold.engine, jsOwner)
+}
+
+//export hookGoValueWriteField
+func hookGoValueWriteField(enginep, foldp unsafe.Pointer, reflectIndex, setIndex C.int, assigndv *C.DataValue) {
+ fold := ensureEngine(enginep, foldp)
+ v := reflect.ValueOf(fold.gvalue)
+ ve := v
+ for ve.Type().Kind() == reflect.Ptr {
+ ve = ve.Elem()
+ }
+ var field, setMethod reflect.Value
+ if reflectIndex >= 0 {
+ // It's a real field rather than a getter.
+ field = ve.Field(int(reflectIndex))
+ }
+ if setIndex >= 0 {
+ // It has a setter.
+ setMethod = v.Method(int(setIndex))
+ }
+
+ assign := unpackDataValue(assigndv, fold.engine)
+
+ // TODO Return false to the call site if it fails. That's how Qt seems to handle it internally.
+ err := convertAndSet(field, reflect.ValueOf(assign), setMethod)
+ if err != nil {
+ panic(err.Error())
+ }
+}
+
+func convertAndSet(to, from reflect.Value, setMethod reflect.Value) (err error) {
+ var toType reflect.Type
+ if setMethod.IsValid() {
+ toType = setMethod.Type().In(0)
+ } else {
+ toType = to.Type()
+ }
+ fromType := from.Type()
+ defer func() {
+ // TODO This is catching more than it should. There are calls
+ // to custom code below that should be isolated.
+ if v := recover(); v != nil {
+ err = fmt.Errorf("cannot use %s as a %s", fromType, toType)
+ }
+ }()
+ if fromType == typeList && toType.Kind() == reflect.Slice {
+ list := from.Interface().(*List)
+ from = reflect.MakeSlice(toType, len(list.data), len(list.data))
+ elemType := toType.Elem()
+ for i, elem := range list.data {
+ from.Index(i).Set(reflect.ValueOf(elem).Convert(elemType))
+ }
+ } else if fromType == typeMap && toType.Kind() == reflect.Map {
+ qmap := from.Interface().(*Map)
+ from = reflect.MakeMap(toType)
+ elemType := toType.Elem()
+ for i := 0; i < len(qmap.data); i += 2 {
+ key := reflect.ValueOf(qmap.data[i])
+ val := reflect.ValueOf(qmap.data[i+1])
+ if val.Type() != elemType {
+ val = val.Convert(elemType)
+ }
+ from.SetMapIndex(key, val)
+ }
+ } else if toType != fromType {
+ from = from.Convert(toType)
+ }
+ if setMethod.IsValid() {
+ setMethod.Call([]reflect.Value{from})
+ } else {
+ to.Set(from)
+ }
+ return nil
+}
+
+var (
+ dataValueSize = uintptr(unsafe.Sizeof(C.DataValue{}))
+ dataValueArray [C.MaxParams]C.DataValue
+)
+
+//export hookGoValueCallMethod
+func hookGoValueCallMethod(enginep, foldp unsafe.Pointer, reflectIndex C.int, args *C.DataValue) {
+ fold := ensureEngine(enginep, foldp)
+ v := reflect.ValueOf(fold.gvalue)
+
+ // TODO Must assert that v is necessarily a pointer here, but we shouldn't have to manipulate
+ // gvalue here for that. This should happen in a sensible place in the wrapping functions
+ // that can still error out to the user in due time.
+
+ method := v.Method(int(reflectIndex))
+ methodt := method.Type()
+ methodName := v.Type().Method(int(reflectIndex)).Name
+
+ // TODO Ensure methods with more parameters than this are not registered.
+ var params [C.MaxParams]reflect.Value
+ var err error
+
+ numIn := methodt.NumIn()
+ for i := 0; i < numIn; i++ {
+ paramdv := (*C.DataValue)(unsafe.Pointer(uintptr(unsafe.Pointer(args)) + (uintptr(i)+1)*dataValueSize))
+ param := reflect.ValueOf(unpackDataValue(paramdv, fold.engine))
+ if argt := methodt.In(i); param.Type() != argt {
+ param, err = convertParam(methodName, i, param, argt)
+ if err != nil {
+ panic(err.Error())
+ }
+ }
+ params[i] = param
+ }
+
+ result := method.Call(params[:numIn])
+
+ if len(result) == 1 {
+ packDataValue(result[0].Interface(), args, fold.engine, jsOwner)
+ } else if len(result) > 1 {
+ if len(result) > len(dataValueArray) {
+ panic("function has too many results")
+ }
+ for i, v := range result {
+ packDataValue(v.Interface(), &dataValueArray[i], fold.engine, jsOwner)
+ }
+ args.dataType = C.DTVariantList
+ *(*unsafe.Pointer)(unsafe.Pointer(&args.data)) = C.newVariantList(&dataValueArray[0], C.int(len(result)))
+ }
+}
+
+func convertParam(methodName string, index int, param reflect.Value, argt reflect.Type) (reflect.Value, error) {
+ out := reflect.New(argt).Elem()
+ err := convertAndSet(out, param, reflect.Value{})
+ if err != nil {
+ err = fmt.Errorf("cannot convert parameter %d of method %s from %s to %s; provided value: %#v",
+ index, methodName, param.Type(), argt, param.Interface())
+ return reflect.Value{}, err
+ }
+ return out, nil
+}
+
+func printPaintPanic() {
+ if v := recover(); v != nil {
+ buf := make([]byte, 8192)
+ runtime.Stack(buf, false)
+ fmt.Fprintf(os.Stderr, "panic while painting: %s\n\n%s", v, buf)
+ }
+}
+
+//export hookGoValuePaint
+func hookGoValuePaint(enginep, foldp unsafe.Pointer, reflectIndex C.intptr_t) {
+ // Besides a convenience this is a workaround for http://golang.org/issue/8588
+ defer printPaintPanic()
+ defer atomic.StoreUintptr(&guiPaintRef, 0)
+
+ // The main GUI thread is mutex-locked while paint methods are called,
+ // so no two paintings should be happening at the same time.
+ atomic.StoreUintptr(&guiPaintRef, cdata.Ref())
+
+ fold := ensureEngine(enginep, foldp)
+ if fold.init.IsValid() {
+ return
+ }
+
+ painter := &Painter{engine: fold.engine, obj: &Common{fold.cvalue, fold.engine}}
+ v := reflect.ValueOf(fold.gvalue)
+ method := v.Method(int(reflectIndex))
+ method.Call([]reflect.Value{reflect.ValueOf(painter)})
+}
+
+func ensureEngine(enginep, foldp unsafe.Pointer) *valueFold {
+ fold := (*valueFold)(foldp)
+ if fold.engine != nil {
+ if fold.init.IsValid() {
+ initGoType(fold)
+ }
+ return fold
+ }
+
+ if enginep == nilPtr {
+ panic("accessing value without an engine pointer; who created the value?")
+ }
+ engine := engines[enginep]
+ if engine == nil {
+ panic("unknown engine pointer; who created the engine?")
+ }
+ fold.engine = engine
+ prev := engine.values[fold.gvalue]
+ if prev != nil {
+ for prev.next != nil {
+ prev = prev.next
+ }
+ prev.next = fold
+ fold.prev = prev
+ } else {
+ engine.values[fold.gvalue] = fold
+ }
+ before := len(typeNew)
+ delete(typeNew, fold)
+ if len(typeNew) == before {
+ panic("value had no engine, but was not created by a registered type; who created the value?")
+ }
+ initGoType(fold)
+ return fold
+}
+
+func initGoType(fold *valueFold) {
+ if cdata.Ref() == atomic.LoadUintptr(&guiPaintRef) {
+ go RunMain(func() { _initGoType(fold, true) })
+ } else {
+ _initGoType(fold, false)
+ }
+}
+
+func _initGoType(fold *valueFold, schedulePaint bool) {
+ if !fold.init.IsValid() {
+ return
+ }
+ // TODO Would be good to preserve identity on the Go side. See unpackDataValue as well.
+ obj := &Common{engine: fold.engine, addr: fold.cvalue}
+ fold.init.Call([]reflect.Value{reflect.ValueOf(fold.gvalue), reflect.ValueOf(obj)})
+ fold.init = reflect.Value{}
+ if schedulePaint {
+ obj.Call("update")
+ }
+}
+
+//export hookPanic
+func hookPanic(message *C.char) {
+ defer C.free(unsafe.Pointer(message))
+ panic(C.GoString(message))
+}
+
+func listSlice(fold *valueFold, reflectIndex C.intptr_t) *[]Object {
+ field := deref(reflect.ValueOf(fold.gvalue)).Field(int(reflectIndex))
+ return field.Addr().Interface().(*[]Object)
+}
+
+//export hookListPropertyAt
+func hookListPropertyAt(foldp unsafe.Pointer, reflectIndex, setIndex C.intptr_t, index C.int) (objp unsafe.Pointer) {
+ fold := (*valueFold)(foldp)
+ slice := listSlice(fold, reflectIndex)
+ return (*slice)[int(index)].Common().addr
+}
+
+//export hookListPropertyCount
+func hookListPropertyCount(foldp unsafe.Pointer, reflectIndex, setIndex C.intptr_t) C.int {
+ fold := (*valueFold)(foldp)
+ slice := listSlice(fold, reflectIndex)
+ return C.int(len(*slice))
+}
+
+//export hookListPropertyAppend
+func hookListPropertyAppend(foldp unsafe.Pointer, reflectIndex, setIndex C.intptr_t, objp unsafe.Pointer) {
+ fold := (*valueFold)(foldp)
+ slice := listSlice(fold, reflectIndex)
+ var objdv C.DataValue
+ objdv.dataType = C.DTObject
+ *(*unsafe.Pointer)(unsafe.Pointer(&objdv.data)) = objp
+ newslice := append(*slice, unpackDataValue(&objdv, fold.engine).(Object))
+ if setIndex >= 0 {
+ reflect.ValueOf(fold.gvalue).Method(int(setIndex)).Call([]reflect.Value{reflect.ValueOf(newslice)})
+ } else {
+ *slice = newslice
+ }
+}
+
+//export hookListPropertyClear
+func hookListPropertyClear(foldp unsafe.Pointer, reflectIndex, setIndex C.intptr_t) {
+ fold := (*valueFold)(foldp)
+ slice := listSlice(fold, reflectIndex)
+ newslice := (*slice)[0:0]
+ if setIndex >= 0 {
+ reflect.ValueOf(fold.gvalue).Method(int(setIndex)).Call([]reflect.Value{reflect.ValueOf(newslice)})
+ } else {
+ for i := range *slice {
+ (*slice)[i] = nil
+ }
+ *slice = newslice
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/cdata/cdata.go b/Godeps/_workspace/src/github.com/obscuren/qml/cdata/cdata.go
new file mode 100644
index 000000000..6f13b810f
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/cdata/cdata.go
@@ -0,0 +1,6 @@
+// Package cdata supports the implementation of the qml package.
+package cdata
+
+func Ref() uintptr
+
+func Addrs() (uintptr, uintptr)
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/cdata/cdata12.c b/Godeps/_workspace/src/github.com/obscuren/qml/cdata/cdata12.c
new file mode 100644
index 000000000..2e60abfa2
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/cdata/cdata12.c
@@ -0,0 +1,18 @@
+// +build !go1.4
+
+#include "runtime.h"
+
+void ·Ref(uintptr ref) {
+ ref = (uintptr)g->m;
+ FLUSH(&ref);
+}
+
+void runtime·main(void);
+void main·main(void);
+
+void ·Addrs(uintptr rmain, uintptr mmain) {
+ rmain = (uintptr)runtime·main;
+ mmain = (uintptr)main·main;
+ FLUSH(&rmain);
+ FLUSH(&mmain);
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/cdata/cdata14_386.s b/Godeps/_workspace/src/github.com/obscuren/qml/cdata/cdata14_386.s
new file mode 100644
index 000000000..7dae9b961
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/cdata/cdata14_386.s
@@ -0,0 +1,17 @@
+// +build go1.4
+
+#include "textflag.h"
+
+TEXT ·Ref(SB),NOSPLIT,$4-4
+ CALL runtime·acquirem(SB)
+ MOVL 0(SP), AX
+ MOVL AX, ret+0(FP)
+ CALL runtime·releasem(SB)
+ RET
+
+TEXT ·Addrs(SB),NOSPLIT,$0-8
+ MOVL $runtime·main(SB), AX
+ MOVL AX, ret+0(FP)
+ MOVL $runtime·main_main(SB), AX
+ MOVL AX, ret+8(FP)
+ RET
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/cdata/cdata14_amd64.s b/Godeps/_workspace/src/github.com/obscuren/qml/cdata/cdata14_amd64.s
new file mode 100644
index 000000000..83cc22c9c
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/cdata/cdata14_amd64.s
@@ -0,0 +1,17 @@
+// +build go1.4
+
+#include "textflag.h"
+
+TEXT ·Ref(SB),NOSPLIT,$8-8
+ CALL runtime·acquirem(SB)
+ MOVQ 0(SP), AX
+ MOVQ AX, ret+0(FP)
+ CALL runtime·releasem(SB)
+ RET
+
+TEXT ·Addrs(SB),NOSPLIT,$0-16
+ MOVQ $runtime·main(SB), AX
+ MOVQ AX, ret+0(FP)
+ MOVQ $runtime·main_main(SB), AX
+ MOVQ AX, ret+8(FP)
+ RET
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/cdata/cdata14_arm.s b/Godeps/_workspace/src/github.com/obscuren/qml/cdata/cdata14_arm.s
new file mode 100644
index 000000000..c66bbafbf
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/cdata/cdata14_arm.s
@@ -0,0 +1,18 @@
+// +build go1.4
+
+#include "textflag.h"
+
+TEXT ·Ref(SB),NOSPLIT,$4-4
+ BL runtime·acquirem(SB)
+ MOVW 4(R13), R0
+ MOVW R0, ret+0(FP)
+ MOVW R0, 4(R13)
+ BL runtime·releasem(SB)
+ RET
+
+TEXT ·Addrs(SB),NOSPLIT,$0-8
+ MOVW $runtime·main(SB), R0
+ MOVW R0, ret+0(FP)
+ MOVW $runtime·main_main(SB), R0
+ MOVW R0, ret+4(FP)
+ RET
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/cdata/cdata_test.go b/Godeps/_workspace/src/github.com/obscuren/qml/cdata/cdata_test.go
new file mode 100644
index 000000000..e7c3f33c5
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/cdata/cdata_test.go
@@ -0,0 +1,42 @@
+package cdata
+
+import (
+ "runtime"
+ "sync"
+ "testing"
+)
+
+type refPair struct {
+ ref1, ref2 uintptr
+}
+
+func TestRef(t *testing.T) {
+ const N = 10
+ runtime.LockOSThread()
+ exit := sync.WaitGroup{}
+ exit.Add(1)
+ defer exit.Done()
+ wg := sync.WaitGroup{}
+ wg.Add(N)
+ ch := make(chan refPair)
+ for i := 0; i < N; i++ {
+ go func() {
+ runtime.LockOSThread()
+ wg.Done()
+ ch <- refPair{Ref(), Ref()}
+ exit.Wait()
+ }()
+ }
+ wg.Wait()
+ refs := make(map[uintptr]bool)
+ for i := 0; i < N; i++ {
+ pair := <-ch
+ if pair.ref1 != pair.ref2 {
+ t.Fatalf("found inconsistent ref: %d != %d", pair.ref1, pair.ref2)
+ }
+ if refs[pair.ref1] {
+ t.Fatalf("found duplicated ref: %d", pair.ref1)
+ }
+ refs[pair.ref1] = true
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/cmd/genqrc/main.go b/Godeps/_workspace/src/github.com/obscuren/qml/cmd/genqrc/main.go
new file mode 100644
index 000000000..a601d8126
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/cmd/genqrc/main.go
@@ -0,0 +1,218 @@
+
+// XXX: The documentation is duplicated here and in the the doc variable
+// below. Update both at the same time.
+
+// Command genqrc packs resource files into the Go binary.
+//
+// Usage: genqrc [options] <subdir1> [<subdir2> ...]
+//
+// The genqrc tool packs all resource files under the provided subdirectories into
+// a single qrc.go file that may be built into the generated binary. Bundled files
+// may then be loaded by Go or QML code under the URL "qrc:///some/path", where
+// "some/path" matches the original path for the resource file locally.
+//
+// For example, the following will load a .qml file from the resource pack, and
+// that file may in turn reference other content (code, images, etc) in the pack:
+//
+// component, err := engine.LoadFile("qrc://path/to/file.qml")
+//
+// Starting with Go 1.4, this tool may be conveniently run by the "go generate"
+// subcommand by adding a line similar to the following one to any existent .go
+// file in the project (assuming the subdirectories ./code/ and ./images/ exist):
+//
+// //go:generate genqrc code images
+//
+// Then, just run "go generate" to update the qrc.go file.
+//
+// During development, the generated qrc.go can repack the filesystem content at
+// runtime to avoid the process of regenerating the qrc.go file and rebuilding the
+// application to test every minor change made. Runtime repacking is enabled by
+// setting the QRC_REPACK environment variable to 1:
+//
+// export QRC_REPACK=1
+//
+// This does not update the static content in the qrc.go file, though, so after
+// the changes are performed, genqrc must be run again to update the content that
+// will ship with built binaries.
+package main
+
+import (
+ "flag"
+ "fmt"
+ "io/ioutil"
+ "os"
+ "path/filepath"
+ "text/template"
+
+ "gopkg.in/qml.v1"
+)
+
+const doc = `
+Usage: genqrc [options] <subdir1> [<subdir2> ...]
+
+The genqrc tool packs all resource files under the provided subdirectories into
+a single qrc.go file that may be built into the generated binary. Bundled files
+may then be loaded by Go or QML code under the URL "qrc:///some/path", where
+"some/path" matches the original path for the resource file locally.
+
+For example, the following will load a .qml file from the resource pack, and
+that file may in turn reference other content (code, images, etc) in the pack:
+
+ component, err := engine.LoadFile("qrc://path/to/file.qml")
+
+Starting with Go 1.4, this tool may be conveniently run by the "go generate"
+subcommand by adding a line similar to the following one to any existent .go
+file in the project (assuming the subdirectories ./code/ and ./images/ exist):
+
+ //go:generate genqrc code images
+
+Then, just run "go generate" to update the qrc.go file.
+
+During development, the generated qrc.go can repack the filesystem content at
+runtime to avoid the process of regenerating the qrc.go file and rebuilding the
+application to test every minor change made. Runtime repacking is enabled by
+setting the QRC_REPACK environment variable to 1:
+
+ export QRC_REPACK=1
+
+This does not update the static content in the qrc.go file, though, so after
+the changes are performed, genqrc must be run again to update the content that
+will ship with built binaries.
+`
+
+// XXX: The documentation is duplicated here and in the the package comment
+// above. Update both at the same time.
+
+var packageName = flag.String("package", "main", "package name that qrc.go will be under (not needed for go generate)")
+
+func main() {
+ flag.Usage = func() {
+ fmt.Fprintf(os.Stderr, "%s", doc)
+ flag.PrintDefaults()
+ }
+ flag.Parse()
+ if err := run(); err != nil {
+ fmt.Fprintf(os.Stderr, "error: %v\n", err)
+ os.Exit(1)
+ }
+}
+
+func run() error {
+ subdirs := flag.Args()
+ if len(subdirs) == 0 {
+ return fmt.Errorf("must provide at least one subdirectory path")
+ }
+
+ var rp qml.ResourcesPacker
+
+ for _, subdir := range flag.Args() {
+ err := filepath.Walk(subdir, func(path string, info os.FileInfo, err error) error {
+ if err != nil {
+ return err
+ }
+ if info.IsDir() {
+ return nil
+ }
+ data, err := ioutil.ReadFile(path)
+ if err != nil {
+ return err
+ }
+ rp.Add(filepath.ToSlash(path), data)
+ return nil
+ })
+ if err != nil {
+ return err
+ }
+ }
+
+ resdata := rp.Pack().Bytes()
+
+ f, err := os.Create("qrc.go")
+ if err != nil {
+ return err
+ }
+ defer f.Close()
+
+ data := templateData{
+ PackageName: *packageName,
+ SubDirs: subdirs,
+ ResourcesData: resdata,
+ }
+
+ // $GOPACKAGE is set automatically by go generate.
+ if pkgname := os.Getenv("GOPACKAGE"); pkgname != "" {
+ data.PackageName = pkgname
+ }
+
+ return tmpl.Execute(f, data)
+}
+
+type templateData struct {
+ PackageName string
+ SubDirs []string
+ ResourcesData []byte
+}
+
+func buildTemplate(name, content string) *template.Template {
+ return template.Must(template.New(name).Parse(content))
+}
+
+var tmpl = buildTemplate("qrc.go", `package {{.PackageName}}
+
+// This file is automatically generated by gopkg.in/qml.v1/cmd/genqrc
+
+import (
+ "io/ioutil"
+ "os"
+ "path/filepath"
+
+ "gopkg.in/qml.v1"
+)
+
+func init() {
+ var r *qml.Resources
+ var err error
+ if os.Getenv("QRC_REPACK") == "1" {
+ err = qrcRepackResources()
+ if err != nil {
+ panic("cannot repack qrc resources: " + err.Error())
+ }
+ r, err = qml.ParseResources(qrcResourcesRepacked)
+ } else {
+ r, err = qml.ParseResourcesString(qrcResourcesData)
+ }
+ if err != nil {
+ panic("cannot parse bundled resources data: " + err.Error())
+ }
+ qml.LoadResources(r)
+}
+
+func qrcRepackResources() error {
+ subdirs := {{printf "%#v" .SubDirs}}
+ var rp qml.ResourcesPacker
+ for _, subdir := range subdirs {
+ err := filepath.Walk(subdir, func(path string, info os.FileInfo, err error) error {
+ if err != nil {
+ return err
+ }
+ if info.IsDir() {
+ return nil
+ }
+ data, err := ioutil.ReadFile(path)
+ if err != nil {
+ return err
+ }
+ rp.Add(filepath.ToSlash(path), data)
+ return nil
+ })
+ if err != nil {
+ return err
+ }
+ }
+ qrcResourcesRepacked = rp.Pack().Bytes()
+ return nil
+}
+
+var qrcResourcesRepacked []byte
+var qrcResourcesData = {{printf "%q" .ResourcesData}}
+`)
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/cmd/ubuntu-touch/particle.desktop b/Godeps/_workspace/src/github.com/obscuren/qml/cmd/ubuntu-touch/particle.desktop
new file mode 100644
index 000000000..76a62cb50
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/cmd/ubuntu-touch/particle.desktop
@@ -0,0 +1,15 @@
+[Desktop Entry]
+Encoding=UTF-8
+Version=1.0
+Type=Application
+Terminal=false
+Path=/home/phablet/src/gopkg.in/qml.v0/examples/particle/
+Exec=./particle
+Icon=properties
+Name=Particle Example
+X-Ubuntu-Touch=true
+X-Ubuntu-StageHint=SideStage
+
+# Copy this file to:
+#
+# ~phablet/.local/share/applications/gopkg.in.qml.particle-example.desktop
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/cmd/ubuntu-touch/setup.sh b/Godeps/_workspace/src/github.com/obscuren/qml/cmd/ubuntu-touch/setup.sh
new file mode 100644
index 000000000..1d0454110
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/cmd/ubuntu-touch/setup.sh
@@ -0,0 +1,41 @@
+#!/bin/sh
+
+set -e
+
+if [ "$USER" != "root" ]; then
+ echo 'This script must be run as root.'
+ exit 1
+fi
+
+echo 'Remounting root as read-write ------------------------------------------------'
+
+mount -o remount,rw /
+
+echo 'Installing Go and dependencies -----------------------------------------------'
+
+apt-get update
+apt-get install -y \
+ golang-go g++ git pkg-config ubuntu-app-launch\
+ qtbase5-private-dev qtdeclarative5-private-dev libqt5opengl5-dev
+apt-get clean
+
+echo 'Setting up environment for phablet user --------------------------------------'
+
+echo 'export GOPATH=$HOME' >> ~phablet/.bash_profile
+
+echo 'Fetching the qml package -----------------------------------------------------'
+
+su -l phablet -c 'go get gopkg.in/qml.v0'
+
+echo 'Installing the .desktop file for the particle example ------------------------'
+
+APP_ID='gopkg.in.qml.particle-example'
+cp ~phablet/src/gopkg.in/qml.v*/cmd/ubuntu-touch/particle.desktop ~phablet/.local/share/applications/$APP_ID.desktop
+
+echo 'Building and launching particle example --------------------------------------'
+
+su -l phablet -c 'cd $HOME/src/gopkg.in/qml.v0/examples/particle; go build'
+
+echo 'Launching particle example ---------------------------------------------------'
+
+su -l phablet -c "ubuntu-app-launch $APP_ID"
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/cpp/capi.cpp b/Godeps/_workspace/src/github.com/obscuren/qml/cpp/capi.cpp
new file mode 100644
index 000000000..024e5ec9c
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/cpp/capi.cpp
@@ -0,0 +1,884 @@
+#include <QApplication>
+#include <QQuickView>
+#include <QQuickItem>
+#include <QtQml>
+#include <QDebug>
+#include <QQuickImageProvider>
+
+#include <string.h>
+
+#include "govalue.h"
+#include "govaluetype.h"
+#include "connector.h"
+#include "capi.h"
+
+static char *local_strdup(const char *str)
+{
+ char *strcopy = 0;
+ if (str) {
+ size_t len = strlen(str) + 1;
+ strcopy = (char *)malloc(len);
+ memcpy(strcopy, str, len);
+ }
+ return strcopy;
+}
+
+error *errorf(const char *format, ...)
+{
+ va_list ap;
+ va_start(ap, format);
+ QString str = QString().vsprintf(format, ap);
+ va_end(ap);
+ QByteArray ba = str.toUtf8();
+ return local_strdup(ba.constData());
+}
+
+void panicf(const char *format, ...)
+{
+ va_list ap;
+ va_start(ap, format);
+ QString str = QString().vsprintf(format, ap);
+ va_end(ap);
+ QByteArray ba = str.toUtf8();
+ hookPanic(local_strdup(ba.constData()));
+}
+
+void newGuiApplication()
+{
+ static char empty[1] = {0};
+ static char *argv[] = {empty, 0};
+ static int argc = 1;
+ new QApplication(argc, argv);
+
+ // The event loop should never die.
+ qApp->setQuitOnLastWindowClosed(false);
+}
+
+void applicationExec()
+{
+ qApp->exec();
+}
+
+void applicationExit()
+{
+ qApp->exit(0);
+}
+
+void applicationFlushAll()
+{
+ qApp->processEvents();
+}
+
+void *currentThread()
+{
+ return QThread::currentThread();
+}
+
+void *appThread()
+{
+ return QCoreApplication::instance()->thread();
+}
+
+QQmlEngine_ *newEngine(QObject_ *parent)
+{
+ return new QQmlEngine(reinterpret_cast<QObject *>(parent));
+}
+
+QQmlContext_ *engineRootContext(QQmlEngine_ *engine)
+{
+ return reinterpret_cast<QQmlEngine *>(engine)->rootContext();
+}
+
+void engineSetContextForObject(QQmlEngine_ *engine, QObject_ *object)
+{
+ QQmlEngine *qengine = reinterpret_cast<QQmlEngine *>(engine);
+ QObject *qobject = reinterpret_cast<QObject *>(object);
+
+ QQmlEngine::setContextForObject(qobject, qengine->rootContext());
+}
+
+void engineSetOwnershipCPP(QQmlEngine_ *engine, QObject_ *object)
+{
+ QQmlEngine *qengine = reinterpret_cast<QQmlEngine *>(engine);
+ QObject *qobject = reinterpret_cast<QObject *>(object);
+
+ qengine->setObjectOwnership(qobject, QQmlEngine::CppOwnership);
+}
+
+void engineSetOwnershipJS(QQmlEngine_ *engine, QObject_ *object)
+{
+ QQmlEngine *qengine = reinterpret_cast<QQmlEngine *>(engine);
+ QObject *qobject = reinterpret_cast<QObject *>(object);
+
+ qengine->setObjectOwnership(qobject, QQmlEngine::JavaScriptOwnership);
+}
+
+QQmlComponent_ *newComponent(QQmlEngine_ *engine, QObject_ *parent)
+{
+ QQmlEngine *qengine = reinterpret_cast<QQmlEngine *>(engine);
+ //QObject *qparent = reinterpret_cast<QObject *>(parent);
+ QQmlComponent *qcomponent = new QQmlComponent(qengine);
+ // Qt 5.2.0 returns NULL on qmlEngine(qcomponent) without this.
+ QQmlEngine::setContextForObject(qcomponent, qengine->rootContext());
+ return qcomponent;
+}
+
+class GoImageProvider : public QQuickImageProvider {
+
+ // TODO Destroy this when engine is destroyed.
+
+ public:
+
+ GoImageProvider(void *imageFunc) : QQuickImageProvider(QQmlImageProviderBase::Image), imageFunc(imageFunc) {};
+
+ virtual QImage requestImage(const QString &id, QSize *size, const QSize &requestedSize)
+ {
+ QByteArray ba = id.toUtf8();
+ int width = 0, height = 0;
+ if (requestedSize.isValid()) {
+ width = requestedSize.width();
+ height = requestedSize.height();
+ }
+ QImage *ptr = reinterpret_cast<QImage *>(hookRequestImage(imageFunc, (char*)ba.constData(), ba.size(), width, height));
+ QImage image = *ptr;
+ delete ptr;
+
+ *size = image.size();
+ if (requestedSize.isValid() && requestedSize != *size) {
+ image = image.scaled(requestedSize, Qt::KeepAspectRatio);
+ }
+ return image;
+ };
+
+ private:
+
+ void *imageFunc;
+};
+
+void engineAddImageProvider(QQmlEngine_ *engine, QString_ *providerId, void *imageFunc)
+{
+ QQmlEngine *qengine = reinterpret_cast<QQmlEngine *>(engine);
+ QString *qproviderId = reinterpret_cast<QString *>(providerId);
+
+ qengine->addImageProvider(*qproviderId, new GoImageProvider(imageFunc));
+}
+
+void componentLoadURL(QQmlComponent_ *component, const char *url, int urlLen)
+{
+ QByteArray qurl(url, urlLen);
+ QString qsurl = QString::fromUtf8(qurl);
+ reinterpret_cast<QQmlComponent *>(component)->loadUrl(qsurl);
+}
+
+void componentSetData(QQmlComponent_ *component, const char *data, int dataLen, const char *url, int urlLen)
+{
+ QByteArray qdata(data, dataLen);
+ QByteArray qurl(url, urlLen);
+ QString qsurl = QString::fromUtf8(qurl);
+ reinterpret_cast<QQmlComponent *>(component)->setData(qdata, qsurl);
+}
+
+char *componentErrorString(QQmlComponent_ *component)
+{
+ QQmlComponent *qcomponent = reinterpret_cast<QQmlComponent *>(component);
+ if (qcomponent->isReady()) {
+ return NULL;
+ }
+ if (qcomponent->isError()) {
+ QByteArray ba = qcomponent->errorString().toUtf8();
+ return local_strdup(ba.constData());
+ }
+ return local_strdup("component is not ready (why!?)");
+}
+
+QObject_ *componentCreate(QQmlComponent_ *component, QQmlContext_ *context)
+{
+ QQmlComponent *qcomponent = reinterpret_cast<QQmlComponent *>(component);
+ QQmlContext *qcontext = reinterpret_cast<QQmlContext *>(context);
+
+ if (!qcontext) {
+ qcontext = qmlContext(qcomponent);
+ }
+ return qcomponent->create(qcontext);
+}
+
+QQuickWindow_ *componentCreateWindow(QQmlComponent_ *component, QQmlContext_ *context)
+{
+ QQmlComponent *qcomponent = reinterpret_cast<QQmlComponent *>(component);
+ QQmlContext *qcontext = reinterpret_cast<QQmlContext *>(context);
+
+ if (!qcontext) {
+ qcontext = qmlContext(qcomponent);
+ }
+ QObject *obj = qcomponent->create(qcontext);
+ if (!objectIsWindow(obj)) {
+ QQuickView *view = new QQuickView(qmlEngine(qcomponent), 0);
+ view->setContent(qcomponent->url(), qcomponent, obj);
+ view->setResizeMode(QQuickView::SizeRootObjectToView);
+ obj = view;
+ }
+ return obj;
+}
+
+// Workaround for bug https://bugs.launchpad.net/bugs/1179716
+struct DoShowWindow : public QQuickWindow {
+ void show() {
+ QQuickWindow::show();
+ QResizeEvent resize(size(), size());
+ resizeEvent(&resize);
+ }
+};
+
+void windowShow(QQuickWindow_ *win)
+{
+ reinterpret_cast<DoShowWindow *>(win)->show();
+}
+
+void windowHide(QQuickWindow_ *win)
+{
+ reinterpret_cast<QQuickWindow *>(win)->hide();
+}
+
+uintptr_t windowPlatformId(QQuickWindow_ *win)
+{
+ return reinterpret_cast<QQuickWindow *>(win)->winId();
+}
+
+void windowConnectHidden(QQuickWindow_ *win)
+{
+ QQuickWindow *qwin = reinterpret_cast<QQuickWindow *>(win);
+ QObject::connect(qwin, &QWindow::visibleChanged, [=](bool visible){
+ if (!visible) {
+ hookWindowHidden(win);
+ }
+ });
+}
+
+QObject_ *windowRootObject(QQuickWindow_ *win)
+{
+ if (objectIsView(win)) {
+ return reinterpret_cast<QQuickView *>(win)->rootObject();
+ }
+ return win;
+}
+
+QImage_ *windowGrabWindow(QQuickWindow_ *win)
+{
+ QQuickWindow *qwin = reinterpret_cast<QQuickWindow *>(win);
+ QImage *image = new QImage;
+ *image = qwin->grabWindow().convertToFormat(QImage::Format_ARGB32_Premultiplied);
+ return image;
+}
+
+QImage_ *newImage(int width, int height)
+{
+ return new QImage(width, height, QImage::Format_ARGB32_Premultiplied);
+}
+
+void delImage(QImage_ *image)
+{
+ delete reinterpret_cast<QImage *>(image);
+}
+
+void imageSize(QImage_ *image, int *width, int *height)
+{
+ QImage *qimage = reinterpret_cast<QImage *>(image);
+ *width = qimage->width();
+ *height = qimage->height();
+}
+
+unsigned char *imageBits(QImage_ *image)
+{
+ QImage *qimage = reinterpret_cast<QImage *>(image);
+ return qimage->bits();
+}
+
+const unsigned char *imageConstBits(QImage_ *image)
+{
+ QImage *qimage = reinterpret_cast<QImage *>(image);
+ return qimage->constBits();
+}
+
+void contextSetObject(QQmlContext_ *context, QObject_ *value)
+{
+ QQmlContext *qcontext = reinterpret_cast<QQmlContext *>(context);
+ QObject *qvalue = reinterpret_cast<QObject *>(value);
+
+ // Give qvalue an engine reference if it doesn't yet have one.
+ if (!qmlEngine(qvalue)) {
+ QQmlEngine::setContextForObject(qvalue, qcontext->engine()->rootContext());
+ }
+
+ qcontext->setContextObject(qvalue);
+}
+
+void contextSetProperty(QQmlContext_ *context, QString_ *name, DataValue *value)
+{
+ const QString *qname = reinterpret_cast<QString *>(name);
+ QQmlContext *qcontext = reinterpret_cast<QQmlContext *>(context);
+
+ QVariant var;
+ unpackDataValue(value, &var);
+
+ // Give qvalue an engine reference if it doesn't yet have one .
+ QObject *obj = var.value<QObject *>();
+ if (obj && !qmlEngine(obj)) {
+ QQmlEngine::setContextForObject(obj, qcontext);
+ }
+
+ qcontext->setContextProperty(*qname, var);
+}
+
+void contextGetProperty(QQmlContext_ *context, QString_ *name, DataValue *result)
+{
+ QQmlContext *qcontext = reinterpret_cast<QQmlContext *>(context);
+ const QString *qname = reinterpret_cast<QString *>(name);
+
+ QVariant var = qcontext->contextProperty(*qname);
+ packDataValue(&var, result);
+}
+
+QQmlContext_ *contextSpawn(QQmlContext_ *context)
+{
+ QQmlContext *qcontext = reinterpret_cast<QQmlContext *>(context);
+ return new QQmlContext(qcontext);
+}
+
+void delObject(QObject_ *object)
+{
+ delete reinterpret_cast<QObject *>(object);
+}
+
+void delObjectLater(QObject_ *object)
+{
+ reinterpret_cast<QObject *>(object)->deleteLater();
+}
+
+const char *objectTypeName(QObject_ *object)
+{
+ return reinterpret_cast<QObject *>(object)->metaObject()->className();
+}
+
+int objectGetProperty(QObject_ *object, const char *name, DataValue *result)
+{
+ QObject *qobject = reinterpret_cast<QObject *>(object);
+
+ QVariant var = qobject->property(name);
+ packDataValue(&var, result);
+
+ if (!var.isValid() && qobject->metaObject()->indexOfProperty(name) == -1) {
+ // TODO May have to check the dynamic property names too.
+ return 0;
+ }
+ return 1;
+}
+
+error *objectSetProperty(QObject_ *object, const char *name, DataValue *value)
+{
+ QObject *qobject = reinterpret_cast<QObject *>(object);
+ QVariant var;
+ unpackDataValue(value, &var);
+
+ // Give qvalue an engine reference if it doesn't yet have one.
+ QObject *obj = var.value<QObject *>();
+ if (obj && !qmlEngine(obj)) {
+ QQmlContext *context = qmlContext(qobject);
+ if (context) {
+ QQmlEngine::setContextForObject(obj, context);
+ }
+ }
+
+ // Check that the types are compatible. There's probably more to be done here.
+ const QMetaObject *metaObject = qobject->metaObject();
+ int propIndex = metaObject->indexOfProperty(name);
+ if (propIndex == -1) {
+ return errorf("cannot set non-existent property \"%s\" on type %s", name, qobject->metaObject()->className());
+ }
+
+ QMetaProperty prop = metaObject->property(propIndex);
+ int propType = prop.userType();
+ void *valueArg;
+ if (propType == QMetaType::QVariant) {
+ valueArg = (void *)&var;
+ } else {
+ int varType = var.userType();
+ QVariant saved = var;
+ if (propType != varType && !var.convert(propType)) {
+ if (varType == QMetaType::QObjectStar) {
+ return errorf("cannot set property \"%s\" with type %s to value of %s*",
+ name, QMetaType::typeName(propType), saved.value<QObject*>()->metaObject()->className());
+ } else {
+ return errorf("cannot set property \"%s\" with type %s to value of %s",
+ name, QMetaType::typeName(propType), QMetaType::typeName(varType));
+ }
+ }
+ valueArg = (void *)var.constData();
+ }
+
+ int status = -1;
+ int flags = 0;
+ void *args[] = {valueArg, 0, &status, &flags};
+ QMetaObject::metacall(qobject, QMetaObject::WriteProperty, propIndex, args);
+ return 0;
+}
+
+error *objectInvoke(QObject_ *object, const char *method, int methodLen, DataValue *resultdv, DataValue *paramsdv, int paramsLen)
+{
+ QObject *qobject = reinterpret_cast<QObject *>(object);
+
+ QVariant result;
+ QVariant param[MaxParams];
+ QGenericArgument arg[MaxParams];
+ for (int i = 0; i < paramsLen; i++) {
+ unpackDataValue(&paramsdv[i], &param[i]);
+ arg[i] = Q_ARG(QVariant, param[i]);
+ }
+ if (paramsLen > 10) {
+ panicf("fix the parameter dispatching");
+ }
+
+ const QMetaObject *metaObject = qobject->metaObject();
+ // Walk backwards so descendants have priority.
+ for (int i = metaObject->methodCount()-1; i >= 0; i--) {
+ QMetaMethod metaMethod = metaObject->method(i);
+ QMetaMethod::MethodType methodType = metaMethod.methodType();
+ if (methodType == QMetaMethod::Method || methodType == QMetaMethod::Slot) {
+ QByteArray name = metaMethod.name();
+ if (name.length() == methodLen && qstrncmp(name.constData(), method, methodLen) == 0) {
+ if (metaMethod.parameterCount() < paramsLen) {
+ // TODO Might continue looking to see if a different signal has the same name and enough arguments.
+ return errorf("method \"%s\" has too few parameters for provided arguments", method);
+ }
+
+ bool ok;
+ if (metaMethod.returnType() == QMetaType::Void) {
+ ok = metaMethod.invoke(qobject, Qt::DirectConnection,
+ arg[0], arg[1], arg[2], arg[3], arg[4], arg[5], arg[6], arg[7], arg[8], arg[9]);
+ } else {
+ ok = metaMethod.invoke(qobject, Qt::DirectConnection, Q_RETURN_ARG(QVariant, result),
+ arg[0], arg[1], arg[2], arg[3], arg[4], arg[5], arg[6], arg[7], arg[8], arg[9]);
+ }
+ if (!ok) {
+ return errorf("invalid parameters to method \"%s\"", method);
+ }
+
+ packDataValue(&result, resultdv);
+ return 0;
+ }
+ }
+ }
+
+ return errorf("object does not expose a method \"%s\"", method);
+}
+
+void objectFindChild(QObject_ *object, QString_ *name, DataValue *resultdv)
+{
+ QObject *qobject = reinterpret_cast<QObject *>(object);
+ QString *qname = reinterpret_cast<QString *>(name);
+
+ QVariant var;
+ QObject *result = qobject->findChild<QObject *>(*qname);
+ if (result) {
+ var.setValue(result);
+ }
+ packDataValue(&var, resultdv);
+}
+
+void objectSetParent(QObject_ *object, QObject_ *parent)
+{
+ QObject *qobject = reinterpret_cast<QObject *>(object);
+ QObject *qparent = reinterpret_cast<QObject *>(parent);
+
+ qobject->setParent(qparent);
+}
+
+error *objectConnect(QObject_ *object, const char *signal, int signalLen, QQmlEngine_ *engine, void *func, int argsLen)
+{
+ QObject *qobject = reinterpret_cast<QObject *>(object);
+ QQmlEngine *qengine = reinterpret_cast<QQmlEngine *>(engine);
+ QByteArray qsignal(signal, signalLen);
+
+ const QMetaObject *meta = qobject->metaObject();
+ // Walk backwards so descendants have priority.
+ for (int i = meta->methodCount()-1; i >= 0; i--) {
+ QMetaMethod method = meta->method(i);
+ if (method.methodType() == QMetaMethod::Signal) {
+ QByteArray name = method.name();
+ if (name.length() == signalLen && qstrncmp(name.constData(), signal, signalLen) == 0) {
+ if (method.parameterCount() < argsLen) {
+ // TODO Might continue looking to see if a different signal has the same name and enough arguments.
+ return errorf("signal \"%s\" has too few parameters for provided function", name.constData());
+ }
+ Connector *connector = new Connector(qobject, method, qengine, func, argsLen);
+ const QMetaObject *connmeta = connector->metaObject();
+ QObject::connect(qobject, method, connector, connmeta->method(connmeta->methodOffset()));
+ return 0;
+ }
+ }
+ }
+ // Cannot use constData here as the byte array is not null-terminated.
+ return errorf("object does not expose a \"%s\" signal", qsignal.data());
+}
+
+QQmlContext_ *objectContext(QObject_ *object)
+{
+ return qmlContext(static_cast<QObject *>(object));
+}
+
+int objectIsComponent(QObject_ *object)
+{
+ QObject *qobject = static_cast<QObject *>(object);
+ return dynamic_cast<QQmlComponent *>(qobject) ? 1 : 0;
+}
+
+int objectIsWindow(QObject_ *object)
+{
+ QObject *qobject = static_cast<QObject *>(object);
+ return dynamic_cast<QQuickWindow *>(qobject) ? 1 : 0;
+}
+
+int objectIsView(QObject_ *object)
+{
+ QObject *qobject = static_cast<QObject *>(object);
+ return dynamic_cast<QQuickView *>(qobject) ? 1 : 0;
+}
+
+error *objectGoAddr(QObject_ *object, GoAddr **addr)
+{
+ QObject *qobject = static_cast<QObject *>(object);
+ GoValue *goValue = dynamic_cast<GoValue *>(qobject);
+ if (goValue) {
+ *addr = goValue->addr;
+ return 0;
+ }
+ GoPaintedValue *goPaintedValue = dynamic_cast<GoPaintedValue *>(qobject);
+ if (goPaintedValue) {
+ *addr = goPaintedValue->addr;
+ return 0;
+ }
+ return errorf("QML object is not backed by a Go value");
+}
+
+QString_ *newString(const char *data, int len)
+{
+ // This will copy data only once.
+ QByteArray ba = QByteArray::fromRawData(data, len);
+ return new QString(ba);
+}
+
+void delString(QString_ *s)
+{
+ delete reinterpret_cast<QString *>(s);
+}
+
+GoValue_ *newGoValue(GoAddr *addr, GoTypeInfo *typeInfo, QObject_ *parent)
+{
+ QObject *qparent = reinterpret_cast<QObject *>(parent);
+ if (typeInfo->paint) {
+ return new GoPaintedValue(addr, typeInfo, qparent);
+ }
+ return new GoValue(addr, typeInfo, qparent);
+}
+
+void goValueActivate(GoValue_ *value, GoTypeInfo *typeInfo, int addrOffset)
+{
+ GoMemberInfo *fieldInfo = typeInfo->fields;
+ for (int i = 0; i < typeInfo->fieldsLen; i++) {
+ if (fieldInfo->addrOffset == addrOffset) {
+ if (typeInfo->paint) {
+ static_cast<GoPaintedValue *>(value)->activate(fieldInfo->metaIndex);
+ } else {
+ static_cast<GoValue *>(value)->activate(fieldInfo->metaIndex);
+ }
+ return;
+ }
+ fieldInfo++;
+ }
+
+ // TODO Return an error; probably an unexported field.
+}
+
+void unpackDataValue(DataValue *value, QVariant_ *var)
+{
+ QVariant *qvar = reinterpret_cast<QVariant *>(var);
+ switch (value->dataType) {
+ case DTString:
+ *qvar = QString::fromUtf8(*(char **)value->data, value->len);
+ break;
+ case DTBool:
+ *qvar = bool(*(char *)(value->data) != 0);
+ break;
+ case DTInt64:
+ *qvar = *(qint64*)(value->data);
+ break;
+ case DTInt32:
+ *qvar = *(qint32*)(value->data);
+ break;
+ case DTUint64:
+ *qvar = *(quint64*)(value->data);
+ break;
+ case DTUint32:
+ *qvar = *(quint32*)(value->data);
+ break;
+ case DTFloat64:
+ *qvar = *(double*)(value->data);
+ break;
+ case DTFloat32:
+ *qvar = *(float*)(value->data);
+ break;
+ case DTColor:
+ *qvar = QColor::fromRgba(*(QRgb*)(value->data));
+ break;
+ case DTVariantList:
+ *qvar = **(QVariantList**)(value->data);
+ delete *(QVariantList**)(value->data);
+ break;
+ case DTObject:
+ qvar->setValue(*(QObject**)(value->data));
+ break;
+ case DTInvalid:
+ // null would be more natural, but an invalid variant means
+ // it has proper semantics when dealing with non-qml qt code.
+ //qvar->setValue(QJSValue(QJSValue::NullValue));
+ qvar->clear();
+ break;
+ default:
+ panicf("unknown data type: %d", value->dataType);
+ break;
+ }
+}
+
+void packDataValue(QVariant_ *var, DataValue *value)
+{
+ QVariant *qvar = reinterpret_cast<QVariant *>(var);
+
+ // Some assumptions are made below regarding the size of types.
+ // There's apparently no better way to handle this since that's
+ // how the types with well defined sizes (qint64) are mapped to
+ // meta-types (QMetaType::LongLong).
+ switch ((int)qvar->type()) {
+ case QVariant::Invalid:
+ value->dataType = DTInvalid;
+ break;
+ case QMetaType::QUrl:
+ *qvar = qvar->value<QUrl>().toString();
+ // fallthrough
+ case QMetaType::QString:
+ {
+ value->dataType = DTString;
+ QByteArray ba = qvar->toByteArray();
+ *(char**)(value->data) = local_strdup(ba.constData());
+ value->len = ba.size();
+ break;
+ }
+ case QMetaType::Bool:
+ value->dataType = DTBool;
+ *(qint8*)(value->data) = (qint8)qvar->toInt();
+ break;
+ case QMetaType::LongLong:
+ // Some of these entries will have to be fixed when handling platforms
+ // where sizeof(long long) != 8 or sizeof(int) != 4.
+ value->dataType = DTInt64;
+ *(qint64*)(value->data) = qvar->toLongLong();
+ break;
+ case QMetaType::ULongLong:
+ value->dataType = DTUint64;
+ *(quint64*)(value->data) = qvar->toLongLong();
+ break;
+ case QMetaType::Int:
+ value->dataType = DTInt32;
+ *(qint32*)(value->data) = qvar->toInt();
+ break;
+ case QMetaType::UInt:
+ value->dataType = DTUint32;
+ *(quint32*)(value->data) = qvar->toUInt();
+ break;
+ case QMetaType::VoidStar:
+ value->dataType = DTUintptr;
+ *(uintptr_t*)(value->data) = (uintptr_t)qvar->value<void *>();
+ break;
+ case QMetaType::Double:
+ value->dataType = DTFloat64;
+ *(double*)(value->data) = qvar->toDouble();
+ break;
+ case QMetaType::Float:
+ value->dataType = DTFloat32;
+ *(float*)(value->data) = qvar->toFloat();
+ break;
+ case QMetaType::QColor:
+ value->dataType = DTColor;
+ *(unsigned int*)(value->data) = qvar->value<QColor>().rgba();
+ break;
+ case QMetaType::QVariantList:
+ {
+ QVariantList varlist = qvar->toList();
+ int len = varlist.size();
+ DataValue *dvlist = (DataValue *) malloc(sizeof(DataValue) * len);
+ for (int i = 0; i < len; i++) {
+ packDataValue((void*)&varlist.at(i), &dvlist[i]);
+ }
+ value->dataType = DTValueList;
+ value->len = len;
+ *(DataValue**)(value->data) = dvlist;
+ }
+ break;
+ case QMetaType::QVariantMap:
+ {
+ QVariantMap varmap = qvar->toMap();
+ int len = varmap.size() * 2;
+ DataValue *dvlist = (DataValue *) malloc(sizeof(DataValue) * len);
+ QMapIterator<QString, QVariant> it(varmap);
+ for (int i = 0; i < len; i += 2) {
+ if (!it.hasNext()) {
+ panicf("QVariantMap mutated during iteration");
+ }
+ it.next();
+ QVariant key = it.key();
+ QVariant val = it.value();
+ packDataValue((void*)&key, &dvlist[i]);
+ packDataValue((void*)&val, &dvlist[i+1]);
+ }
+ value->dataType = DTValueMap;
+ value->len = len;
+ *(DataValue**)(value->data) = dvlist;
+ }
+ break;
+ case QMetaType::User:
+ {
+ static const int qjstype = QVariant::fromValue(QJSValue()).userType();
+ if (qvar->userType() == qjstype) {
+ auto var = qvar->value<QJSValue>().toVariant();
+ packDataValue(&var, value);
+ }
+ }
+ break;
+ default:
+ if (qvar->type() == (int)QMetaType::QObjectStar || qvar->canConvert<QObject *>()) {
+ QObject *qobject = qvar->value<QObject *>();
+ GoValue *goValue = dynamic_cast<GoValue *>(qobject);
+ if (goValue) {
+ value->dataType = DTGoAddr;
+ *(void **)(value->data) = goValue->addr;
+ break;
+ }
+ GoPaintedValue *goPaintedValue = dynamic_cast<GoPaintedValue *>(qobject);
+ if (goPaintedValue) {
+ value->dataType = DTGoAddr;
+ *(void **)(value->data) = goPaintedValue->addr;
+ break;
+ }
+ value->dataType = DTObject;
+ *(void **)(value->data) = qobject;
+ break;
+ }
+ {
+ QQmlListReference ref = qvar->value<QQmlListReference>();
+ if (ref.isValid() && ref.canCount() && ref.canAt()) {
+ int len = ref.count();
+ DataValue *dvlist = (DataValue *) malloc(sizeof(DataValue) * len);
+ QVariant elem;
+ for (int i = 0; i < len; i++) {
+ elem.setValue(ref.at(i));
+ packDataValue(&elem, &dvlist[i]);
+ }
+ value->dataType = DTValueList;
+ value->len = len;
+ *(DataValue**)(value->data) = dvlist;
+ break;
+ }
+ }
+ if (qstrncmp(qvar->typeName(), "QQmlListProperty<", 17) == 0) {
+ QQmlListProperty<QObject> *list = reinterpret_cast<QQmlListProperty<QObject>*>(qvar->data());
+ if (list->count && list->at) {
+ int len = list->count(list);
+ DataValue *dvlist = (DataValue *) malloc(sizeof(DataValue) * len);
+ QVariant elem;
+ for (int i = 0; i < len; i++) {
+ elem.setValue(list->at(list, i));
+ packDataValue(&elem, &dvlist[i]);
+ }
+ value->dataType = DTValueList;
+ value->len = len;
+ *(DataValue**)(value->data) = dvlist;
+ break;
+ }
+ }
+ panicf("unsupported variant type: %d (%s)", qvar->type(), qvar->typeName());
+ break;
+ }
+}
+
+QVariantList_ *newVariantList(DataValue *list, int len)
+{
+ QVariantList *vlist = new QVariantList();
+ vlist->reserve(len);
+ for (int i = 0; i < len; i++) {
+ QVariant var;
+ unpackDataValue(&list[i], &var);
+ vlist->append(var);
+ }
+ return vlist;
+}
+
+QObject *listPropertyAt(QQmlListProperty<QObject> *list, int i)
+{
+ return reinterpret_cast<QObject *>(hookListPropertyAt(list->data, (intptr_t)list->dummy1, (intptr_t)list->dummy2, i));
+}
+
+int listPropertyCount(QQmlListProperty<QObject> *list)
+{
+ return hookListPropertyCount(list->data, (intptr_t)list->dummy1, (intptr_t)list->dummy2);
+}
+
+void listPropertyAppend(QQmlListProperty<QObject> *list, QObject *obj)
+{
+ hookListPropertyAppend(list->data, (intptr_t)list->dummy1, (intptr_t)list->dummy2, obj);
+}
+
+void listPropertyClear(QQmlListProperty<QObject> *list)
+{
+ hookListPropertyClear(list->data, (intptr_t)list->dummy1, (intptr_t)list->dummy2);
+}
+
+QQmlListProperty_ *newListProperty(GoAddr *addr, intptr_t reflectIndex, intptr_t setIndex)
+{
+ QQmlListProperty<QObject> *list = new QQmlListProperty<QObject>();
+ list->data = addr;
+ list->dummy1 = (void*)reflectIndex;
+ list->dummy2 = (void*)setIndex;
+ list->at = listPropertyAt;
+ list->count = listPropertyCount;
+ list->append = listPropertyAppend;
+ list->clear = listPropertyClear;
+ return list;
+}
+
+void internalLogHandler(QtMsgType severity, const QMessageLogContext &context, const QString &text)
+{
+ if (context.file == NULL) return;
+
+ QByteArray textba = text.toUtf8();
+ LogMessage message = {severity, textba.constData(), textba.size(), context.file, (int)strlen(context.file), context.line};
+ hookLogHandler(&message);
+}
+
+void installLogHandler()
+{
+ qInstallMessageHandler(internalLogHandler);
+}
+
+
+extern bool qRegisterResourceData(int version, const unsigned char *tree, const unsigned char *name, const unsigned char *data);
+extern bool qUnregisterResourceData(int version, const unsigned char *tree, const unsigned char *name, const unsigned char *data);
+
+void registerResourceData(int version, char *tree, char *name, char *data)
+{
+ qRegisterResourceData(version, (unsigned char*)tree, (unsigned char*)name, (unsigned char*)data);
+}
+
+void unregisterResourceData(int version, char *tree, char *name, char *data)
+{
+ qUnregisterResourceData(version, (unsigned char*)tree, (unsigned char*)name, (unsigned char*)data);
+}
+
+// vim:ts=4:sw=4:et:ft=cpp
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/cpp/capi.h b/Godeps/_workspace/src/github.com/obscuren/qml/cpp/capi.h
new file mode 100644
index 000000000..25218637d
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/cpp/capi.h
@@ -0,0 +1,211 @@
+#ifndef CAPI_H
+#define CAPI_H
+
+#include <stdint.h>
+#include <stddef.h>
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+// It's surprising that MaximumParamCount is privately defined within qmetaobject.cpp.
+// Must fix the objectInvoke function if this is changed.
+// This is Qt's MaximuParamCount - 1, as it does not take the result value in account.
+enum { MaxParams = 10 };
+
+typedef void QApplication_;
+typedef void QMetaObject_;
+typedef void QObject_;
+typedef void QVariant_;
+typedef void QVariantList_;
+typedef void QString_;
+typedef void QQmlEngine_;
+typedef void QQmlContext_;
+typedef void QQmlComponent_;
+typedef void QQmlListProperty_;
+typedef void QQuickWindow_;
+typedef void QQuickView_;
+typedef void QMessageLogContext_;
+typedef void QImage_;
+typedef void GoValue_;
+typedef void GoAddr;
+typedef void GoTypeSpec_;
+
+typedef char error;
+error *errorf(const char *format, ...);
+void panicf(const char *format, ...);
+
+typedef enum {
+ DTUnknown = 0, // Has an unsupported type.
+ DTInvalid = 1, // Does not exist or similar.
+
+ DTString = 10,
+ DTBool = 11,
+ DTInt64 = 12,
+ DTInt32 = 13,
+ DTUint64 = 14,
+ DTUint32 = 15,
+ DTUintptr = 16,
+ DTFloat64 = 17,
+ DTFloat32 = 18,
+ DTColor = 19,
+
+ DTGoAddr = 100,
+ DTObject = 101,
+ DTValueMap = 102,
+ DTValueList = 103,
+ DTVariantList = 104,
+ DTListProperty = 105,
+
+ // Used in type information, not in an actual data value.
+ DTAny = 201, // Can hold any of the above types.
+ DTMethod = 202
+} DataType;
+
+typedef struct {
+ DataType dataType;
+ char data[8];
+ int len;
+} DataValue;
+
+typedef struct {
+ char *memberName; // points to memberNames
+ DataType memberType;
+ int reflectIndex;
+ int reflectGetIndex;
+ int reflectSetIndex;
+ int metaIndex;
+ int addrOffset;
+ char *methodSignature;
+ char *resultSignature;
+ int numIn;
+ int numOut;
+} GoMemberInfo;
+
+typedef struct {
+ char *typeName;
+ GoMemberInfo *fields;
+ GoMemberInfo *methods;
+ GoMemberInfo *members; // fields + methods
+ GoMemberInfo *paint; // in methods too
+ int fieldsLen;
+ int methodsLen;
+ int membersLen;
+ char *memberNames;
+
+ QMetaObject_ *metaObject;
+} GoTypeInfo;
+
+typedef struct {
+ int severity;
+ const char *text;
+ int textLen;
+ const char *file;
+ int fileLen;
+ int line;
+} LogMessage;
+
+void newGuiApplication();
+void applicationExec();
+void applicationExit();
+void applicationFlushAll();
+
+void idleTimerInit(int32_t *guiIdleRun);
+void idleTimerStart();
+
+void *currentThread();
+void *appThread();
+
+QQmlEngine_ *newEngine(QObject_ *parent);
+QQmlContext_ *engineRootContext(QQmlEngine_ *engine);
+void engineSetOwnershipCPP(QQmlEngine_ *engine, QObject_ *object);
+void engineSetOwnershipJS(QQmlEngine_ *engine, QObject_ *object);
+void engineSetContextForObject(QQmlEngine_ *engine, QObject_ *object);
+void engineAddImageProvider(QQmlEngine_ *engine, QString_ *providerId, void *imageFunc);
+
+void contextGetProperty(QQmlContext_ *context, QString_ *name, DataValue *value);
+void contextSetProperty(QQmlContext_ *context, QString_ *name, DataValue *value);
+void contextSetObject(QQmlContext_ *context, QObject_ *value);
+QQmlContext_ *contextSpawn(QQmlContext_ *context);
+
+void delObject(QObject_ *object);
+void delObjectLater(QObject_ *object);
+const char *objectTypeName(QObject_ *object);
+int objectGetProperty(QObject_ *object, const char *name, DataValue *result);
+error *objectSetProperty(QObject_ *object, const char *name, DataValue *value);
+void objectSetParent(QObject_ *object, QObject_ *parent);
+error *objectInvoke(QObject_ *object, const char *method, int methodLen, DataValue *result, DataValue *params, int paramsLen);
+void objectFindChild(QObject_ *object, QString_ *name, DataValue *result);
+QQmlContext_ *objectContext(QObject_ *object);
+int objectIsComponent(QObject_ *object);
+int objectIsWindow(QObject_ *object);
+int objectIsView(QObject_ *object);
+error *objectConnect(QObject_ *object, const char *signal, int signalLen, QQmlEngine_ *engine, void *func, int argsLen);
+error *objectGoAddr(QObject_ *object, GoAddr **addr);
+
+QQmlComponent_ *newComponent(QQmlEngine_ *engine, QObject_ *parent);
+void componentLoadURL(QQmlComponent_ *component, const char *url, int urlLen);
+void componentSetData(QQmlComponent_ *component, const char *data, int dataLen, const char *url, int urlLen);
+char *componentErrorString(QQmlComponent_ *component);
+QObject_ *componentCreate(QQmlComponent_ *component, QQmlContext_ *context);
+QQuickWindow_ *componentCreateWindow(QQmlComponent_ *component, QQmlContext_ *context);
+
+void windowShow(QQuickWindow_ *win);
+void windowHide(QQuickWindow_ *win);
+uintptr_t windowPlatformId(QQuickWindow_ *win);
+void windowConnectHidden(QQuickWindow_ *win);
+QObject_ *windowRootObject(QQuickWindow_ *win);
+QImage_ *windowGrabWindow(QQuickWindow_ *win);
+
+QImage_ *newImage(int width, int height);
+void delImage(QImage_ *image);
+void imageSize(QImage_ *image, int *width, int *height);
+unsigned char *imageBits(QImage_ *image);
+const unsigned char *imageConstBits(QImage_ *image);
+
+QString_ *newString(const char *data, int len);
+void delString(QString_ *s);
+
+GoValue_ *newGoValue(GoAddr *addr, GoTypeInfo *typeInfo, QObject_ *parent);
+void goValueActivate(GoValue_ *value, GoTypeInfo *typeInfo, int addrOffset);
+
+void packDataValue(QVariant_ *var, DataValue *result);
+void unpackDataValue(DataValue *value, QVariant_ *result);
+
+QVariantList_ *newVariantList(DataValue *list, int len);
+
+QQmlListProperty_ *newListProperty(GoAddr *addr, intptr_t reflectIndex, intptr_t setIndex);
+
+int registerType(char *location, int major, int minor, char *name, GoTypeInfo *typeInfo, GoTypeSpec_ *spec);
+int registerSingleton(char *location, int major, int minor, char *name, GoTypeInfo *typeInfo, GoTypeSpec_ *spec);
+
+void installLogHandler();
+
+void hookIdleTimer();
+void hookLogHandler(LogMessage *message);
+void hookGoValueReadField(QQmlEngine_ *engine, GoAddr *addr, int memberIndex, int getIndex, int setIndex, DataValue *result);
+void hookGoValueWriteField(QQmlEngine_ *engine, GoAddr *addr, int memberIndex, int setIndex, DataValue *assign);
+void hookGoValueCallMethod(QQmlEngine_ *engine, GoAddr *addr, int memberIndex, DataValue *result);
+void hookGoValueDestroyed(QQmlEngine_ *engine, GoAddr *addr);
+void hookGoValuePaint(QQmlEngine_ *engine, GoAddr *addr, intptr_t reflextIndex);
+QImage_ *hookRequestImage(void *imageFunc, char *id, int idLen, int width, int height);
+GoAddr *hookGoValueTypeNew(GoValue_ *value, GoTypeSpec_ *spec);
+void hookWindowHidden(QObject_ *addr);
+void hookSignalCall(QQmlEngine_ *engine, void *func, DataValue *params);
+void hookSignalDisconnect(void *func);
+void hookPanic(char *message);
+int hookListPropertyCount(GoAddr *addr, intptr_t reflectIndex, intptr_t setIndex);
+QObject_ *hookListPropertyAt(GoAddr *addr, intptr_t reflectIndex, intptr_t setIndex, int i);
+void hookListPropertyAppend(GoAddr *addr, intptr_t reflectIndex, intptr_t setIndex, QObject_ *obj);
+void hookListPropertyClear(GoAddr *addr, intptr_t reflectIndex, intptr_t setIndex);
+
+void registerResourceData(int version, char *tree, char *name, char *data);
+void unregisterResourceData(int version, char *tree, char *name, char *data);
+
+#ifdef __cplusplus
+} // extern "C"
+#endif
+
+#endif // CAPI_H
+
+// vim:ts=4:et
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/cpp/connector.cpp b/Godeps/_workspace/src/github.com/obscuren/qml/cpp/connector.cpp
new file mode 100644
index 000000000..6005bfc62
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/cpp/connector.cpp
@@ -0,0 +1,46 @@
+#include <QObject>
+
+#include "connector.h"
+#include "capi.h"
+
+Connector::~Connector()
+{
+ hookSignalDisconnect(func);
+}
+
+void Connector::invoke()
+{
+ panicf("should never get called");
+}
+
+int Connector::qt_metacall(QMetaObject::Call c, int idx, void **a)
+{
+ if (c == QMetaObject::InvokeMetaMethod && idx == metaObject()->methodOffset()) {
+ DataValue args[MaxParams];
+ QObject *plain = NULL;
+ for (int i = 0; i < argsLen; i++) {
+ int paramType = method.parameterType(i);
+ if (paramType == 0 && a[1 + i] != NULL) {
+ const char *typeName = method.parameterTypes()[i].constData();
+ void *addr = a[1 + i];
+ if (typeName[strlen(typeName)-1] == '*') {
+ addr = *(void **)addr;
+ }
+ plain = new PlainObject(typeName, addr, plain);
+ QVariant var = QVariant::fromValue((QObject *)plain);
+ packDataValue(&var, &args[i]);
+ } else {
+ QVariant var(method.parameterType(i), a[1 + i]);
+ packDataValue(&var, &args[i]);
+ }
+ }
+ hookSignalCall(engine, func, args);
+ if (plain != NULL) {
+ delete plain;
+ }
+ return -1;
+ }
+ return standard_qt_metacall(c, idx, a);
+}
+
+// vim:ts=4:sw=4:et
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/cpp/connector.h b/Godeps/_workspace/src/github.com/obscuren/qml/cpp/connector.h
new file mode 100644
index 000000000..82954927b
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/cpp/connector.h
@@ -0,0 +1,58 @@
+#ifndef CONNECTOR_H
+#define CONNECTOR_H
+
+#include <QObject>
+
+#include <stdint.h>
+
+class Connector : public QObject
+{
+ Q_OBJECT
+
+ public:
+
+ Connector(QObject *sender, QMetaMethod method, QQmlEngine *engine, void *func, int argsLen)
+ : QObject(sender), engine(engine), method(method), func(func), argsLen(argsLen) {};
+
+ virtual ~Connector();
+
+ // MOC HACK: s/Connector::qt_metacall/Connector::standard_qt_metacall/
+ int standard_qt_metacall(QMetaObject::Call c, int idx, void **a);
+
+ public slots:
+
+ void invoke();
+
+ private:
+
+ QQmlEngine *engine;
+ QMetaMethod method;
+ void *func;
+ int argsLen;
+};
+
+class PlainObject : public QObject
+{
+ Q_OBJECT
+
+ Q_PROPERTY(QString plainType READ getPlainType)
+ Q_PROPERTY(void *plainAddr READ getPlainAddr)
+
+ QString plainType;
+ void *plainAddr;
+
+ public:
+
+ PlainObject(QObject *parent = 0)
+ : QObject(parent) {};
+
+ PlainObject(const char *plainType, void *plainAddr, QObject *parent = 0)
+ : QObject(parent), plainType(plainType), plainAddr(plainAddr) {};
+
+ QString getPlainType() { return plainType; };
+ void *getPlainAddr() { return plainAddr; };
+};
+
+#endif // CONNECTOR_H
+
+// vim:ts=4:sw=4:et
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/cpp/govalue.cpp b/Godeps/_workspace/src/github.com/obscuren/qml/cpp/govalue.cpp
new file mode 100644
index 000000000..5cf58a62d
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/cpp/govalue.cpp
@@ -0,0 +1,236 @@
+#include <private/qmetaobjectbuilder_p.h>
+
+#include <QtOpenGL/QtOpenGL>
+#include <QtOpenGL/QGLFunctions>
+
+#include <QtQml/QtQml>
+#include <QQmlEngine>
+#include <QDebug>
+
+#include "govalue.h"
+#include "capi.h"
+
+class GoValueMetaObject : public QAbstractDynamicMetaObject
+{
+public:
+ GoValueMetaObject(QObject* value, GoAddr *addr, GoTypeInfo *typeInfo);
+
+ void activatePropIndex(int propIndex);
+
+protected:
+ int metaCall(QMetaObject::Call c, int id, void **a);
+
+private:
+ QObject *value;
+ GoAddr *addr;
+ GoTypeInfo *typeInfo;
+};
+
+GoValueMetaObject::GoValueMetaObject(QObject *value, GoAddr *addr, GoTypeInfo *typeInfo)
+ : value(value), addr(addr), typeInfo(typeInfo)
+{
+ //d->parent = static_cast<QAbstractDynamicMetaObject *>(priv->metaObject);
+ *static_cast<QMetaObject *>(this) = *metaObjectFor(typeInfo);
+
+ QObjectPrivate *objPriv = QObjectPrivate::get(value);
+ objPriv->metaObject = this;
+}
+
+int GoValueMetaObject::metaCall(QMetaObject::Call c, int idx, void **a)
+{
+ //qWarning() << "GoValueMetaObject::metaCall" << c << idx;
+ switch (c) {
+ case QMetaObject::ReadProperty:
+ case QMetaObject::WriteProperty:
+ {
+ // TODO Cache propertyOffset, methodOffset (and maybe qmlEngine)
+ int propOffset = propertyOffset();
+ if (idx < propOffset) {
+ return value->qt_metacall(c, idx, a);
+ }
+ GoMemberInfo *memberInfo = typeInfo->fields;
+ for (int i = 0; i < typeInfo->fieldsLen; i++) {
+ if (memberInfo->metaIndex == idx) {
+ if (c == QMetaObject::ReadProperty) {
+ DataValue result;
+ hookGoValueReadField(qmlEngine(value), addr, memberInfo->reflectIndex, memberInfo->reflectGetIndex, memberInfo->reflectSetIndex, &result);
+ if (memberInfo->memberType == DTListProperty) {
+ if (result.dataType != DTListProperty) {
+ panicf("reading DTListProperty field returned non-DTListProperty result");
+ }
+ QQmlListProperty<QObject> *in = *reinterpret_cast<QQmlListProperty<QObject> **>(result.data);
+ QQmlListProperty<QObject> *out = reinterpret_cast<QQmlListProperty<QObject> *>(a[0]);
+ *out = *in;
+ // TODO Could provide a single variable in the stack to ReadField instead.
+ delete in;
+ } else {
+ QVariant *out = reinterpret_cast<QVariant *>(a[0]);
+ unpackDataValue(&result, out);
+ }
+ } else {
+ DataValue assign;
+ QVariant *in = reinterpret_cast<QVariant *>(a[0]);
+ packDataValue(in, &assign);
+ hookGoValueWriteField(qmlEngine(value), addr, memberInfo->reflectIndex, memberInfo->reflectSetIndex, &assign);
+ activate(value, methodOffset() + (idx - propOffset), 0);
+ }
+ return -1;
+ }
+ memberInfo++;
+ }
+ QMetaProperty prop = property(idx);
+ qWarning() << "Property" << prop.name() << "not found!?";
+ break;
+ }
+ case QMetaObject::InvokeMetaMethod:
+ {
+ if (idx < methodOffset()) {
+ return value->qt_metacall(c, idx, a);
+ }
+ GoMemberInfo *memberInfo = typeInfo->methods;
+ for (int i = 0; i < typeInfo->methodsLen; i++) {
+ if (memberInfo->metaIndex == idx) {
+ // args[0] is the result if any.
+ DataValue args[1 + MaxParams];
+ for (int i = 1; i < memberInfo->numIn+1; i++) {
+ packDataValue(reinterpret_cast<QVariant *>(a[i]), &args[i]);
+ }
+ hookGoValueCallMethod(qmlEngine(value), addr, memberInfo->reflectIndex, args);
+ if (memberInfo->numOut > 0) {
+ unpackDataValue(&args[0], reinterpret_cast<QVariant *>(a[0]));
+ }
+ return -1;
+ }
+ memberInfo++;
+ }
+ QMetaMethod m = method(idx);
+ qWarning() << "Method" << m.name() << "not found!?";
+ break;
+ }
+ default:
+ break; // Unhandled.
+ }
+ return -1;
+}
+
+void GoValueMetaObject::activatePropIndex(int propIndex)
+{
+ // Properties are added first, so the first fieldLen methods are in
+ // fact the signals of the respective properties.
+ int relativeIndex = propIndex - propertyOffset();
+ activate(value, methodOffset() + relativeIndex, 0);
+}
+
+GoValue::GoValue(GoAddr *addr, GoTypeInfo *typeInfo, QObject *parent)
+ : addr(addr), typeInfo(typeInfo)
+{
+ valueMeta = new GoValueMetaObject(this, addr, typeInfo);
+ setParent(parent);
+}
+
+GoValue::~GoValue()
+{
+ hookGoValueDestroyed(qmlEngine(this), addr);
+}
+
+void GoValue::activate(int propIndex)
+{
+ valueMeta->activatePropIndex(propIndex);
+}
+
+GoPaintedValue::GoPaintedValue(GoAddr *addr, GoTypeInfo *typeInfo, QObject *parent)
+ : addr(addr), typeInfo(typeInfo)
+{
+ valueMeta = new GoValueMetaObject(this, addr, typeInfo);
+ setParent(parent);
+
+ QQuickItem::setFlag(QQuickItem::ItemHasContents, true);
+ QQuickPaintedItem::setRenderTarget(QQuickPaintedItem::FramebufferObject);
+}
+
+GoPaintedValue::~GoPaintedValue()
+{
+ hookGoValueDestroyed(qmlEngine(this), addr);
+}
+
+void GoPaintedValue::activate(int propIndex)
+{
+ valueMeta->activatePropIndex(propIndex);
+}
+
+void GoPaintedValue::paint(QPainter *painter)
+{
+ painter->beginNativePainting();
+ hookGoValuePaint(qmlEngine(this), addr, typeInfo->paint->reflectIndex);
+ painter->endNativePainting();
+}
+
+QMetaObject *metaObjectFor(GoTypeInfo *typeInfo)
+{
+ if (typeInfo->metaObject) {
+ return reinterpret_cast<QMetaObject *>(typeInfo->metaObject);
+ }
+
+ QMetaObjectBuilder mob;
+ if (typeInfo->paint) {
+ mob.setSuperClass(&QQuickPaintedItem::staticMetaObject);
+ } else {
+ mob.setSuperClass(&QObject::staticMetaObject);
+ }
+ mob.setClassName(typeInfo->typeName);
+ mob.setFlags(QMetaObjectBuilder::DynamicMetaObject);
+
+ GoMemberInfo *memberInfo;
+
+ memberInfo = typeInfo->fields;
+ int relativePropIndex = mob.propertyCount();
+ for (int i = 0; i < typeInfo->fieldsLen; i++) {
+ mob.addSignal("__" + QByteArray::number(relativePropIndex) + "()");
+ const char *typeName = "QVariant";
+ if (memberInfo->memberType == DTListProperty) {
+ typeName = "QQmlListProperty<QObject>";
+ }
+ QMetaPropertyBuilder propb = mob.addProperty(memberInfo->memberName, typeName, relativePropIndex);
+ propb.setWritable(true);
+ memberInfo->metaIndex = relativePropIndex;
+ memberInfo++;
+ relativePropIndex++;
+ }
+
+ memberInfo = typeInfo->methods;
+ int relativeMethodIndex = mob.methodCount();
+ for (int i = 0; i < typeInfo->methodsLen; i++) {
+ if (*memberInfo->resultSignature) {
+ mob.addMethod(memberInfo->methodSignature, memberInfo->resultSignature);
+ } else {
+ mob.addMethod(memberInfo->methodSignature);
+ }
+ memberInfo->metaIndex = relativeMethodIndex;
+ memberInfo++;
+ relativeMethodIndex++;
+ }
+
+ // TODO Support default properties.
+ //mob.addClassInfo("DefaultProperty", "objects");
+
+ QMetaObject *mo = mob.toMetaObject();
+
+ // Turn the relative indexes into absolute indexes.
+ memberInfo = typeInfo->fields;
+ int propOffset = mo->propertyOffset();
+ for (int i = 0; i < typeInfo->fieldsLen; i++) {
+ memberInfo->metaIndex += propOffset;
+ memberInfo++;
+ }
+ memberInfo = typeInfo->methods;
+ int methodOffset = mo->methodOffset();
+ for (int i = 0; i < typeInfo->methodsLen; i++) {
+ memberInfo->metaIndex += methodOffset;
+ memberInfo++;
+ }
+
+ typeInfo->metaObject = mo;
+ return mo;
+}
+
+// vim:ts=4:sw=4:et:ft=cpp
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/cpp/govalue.h b/Godeps/_workspace/src/github.com/obscuren/qml/cpp/govalue.h
new file mode 100644
index 000000000..aa6ddd10c
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/cpp/govalue.h
@@ -0,0 +1,56 @@
+#ifndef GOVALUE_H
+#define GOVALUE_H
+
+// Unfortunatley we need access to private bits, because the
+// whole dynamic meta-object concept is sadly being hidden
+// away, and without it this package wouldn't exist.
+#include <private/qmetaobject_p.h>
+
+#include <QQuickPaintedItem>
+#include <QPainter>
+
+#include "capi.h"
+
+class GoValueMetaObject;
+
+QMetaObject *metaObjectFor(GoTypeInfo *typeInfo);
+
+class GoValue : public QObject
+{
+ Q_OBJECT
+
+public:
+ GoAddr *addr;
+ GoTypeInfo *typeInfo;
+
+ GoValue(GoAddr *addr, GoTypeInfo *typeInfo, QObject *parent);
+ virtual ~GoValue();
+
+ void activate(int propIndex);
+
+private:
+ GoValueMetaObject *valueMeta;
+};
+
+class GoPaintedValue : public QQuickPaintedItem
+{
+ Q_OBJECT
+
+public:
+ GoAddr *addr;
+ GoTypeInfo *typeInfo;
+
+ GoPaintedValue(GoAddr *addr, GoTypeInfo *typeInfo, QObject *parent);
+ virtual ~GoPaintedValue();
+
+ void activate(int propIndex);
+
+ virtual void paint(QPainter *painter);
+
+private:
+ GoValueMetaObject *valueMeta;
+};
+
+#endif // GOVALUE_H
+
+// vim:ts=4:sw=4:et:ft=cpp
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/cpp/govaluetype.cpp b/Godeps/_workspace/src/github.com/obscuren/qml/cpp/govaluetype.cpp
new file mode 100644
index 000000000..925045390
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/cpp/govaluetype.cpp
@@ -0,0 +1,254 @@
+#include "govaluetype.h"
+
+#define DEFINE_GOVALUETYPE(N) \
+ template<> QMetaObject GoValueType<N>::staticMetaObject = QMetaObject(); \
+ template<> GoTypeInfo *GoValueType<N>::typeInfo = 0; \
+ template<> GoTypeSpec_ *GoValueType<N>::typeSpec = 0;
+
+#define DEFINE_GOPAINTEDVALUETYPE(N) \
+ template<> QMetaObject GoPaintedValueType<N>::staticMetaObject = QMetaObject(); \
+ template<> GoTypeInfo *GoPaintedValueType<N>::typeInfo = 0; \
+ template<> GoTypeSpec_ *GoPaintedValueType<N>::typeSpec = 0;
+
+DEFINE_GOVALUETYPE(1)
+DEFINE_GOVALUETYPE(2)
+DEFINE_GOVALUETYPE(3)
+DEFINE_GOVALUETYPE(4)
+DEFINE_GOVALUETYPE(5)
+DEFINE_GOVALUETYPE(6)
+DEFINE_GOVALUETYPE(7)
+DEFINE_GOVALUETYPE(8)
+DEFINE_GOVALUETYPE(9)
+DEFINE_GOVALUETYPE(10)
+DEFINE_GOVALUETYPE(11)
+DEFINE_GOVALUETYPE(12)
+DEFINE_GOVALUETYPE(13)
+DEFINE_GOVALUETYPE(14)
+DEFINE_GOVALUETYPE(15)
+DEFINE_GOVALUETYPE(16)
+DEFINE_GOVALUETYPE(17)
+DEFINE_GOVALUETYPE(18)
+DEFINE_GOVALUETYPE(19)
+DEFINE_GOVALUETYPE(20)
+DEFINE_GOVALUETYPE(21)
+DEFINE_GOVALUETYPE(22)
+DEFINE_GOVALUETYPE(23)
+DEFINE_GOVALUETYPE(24)
+DEFINE_GOVALUETYPE(25)
+DEFINE_GOVALUETYPE(26)
+DEFINE_GOVALUETYPE(27)
+DEFINE_GOVALUETYPE(28)
+DEFINE_GOVALUETYPE(29)
+DEFINE_GOVALUETYPE(30)
+
+DEFINE_GOPAINTEDVALUETYPE(1)
+DEFINE_GOPAINTEDVALUETYPE(2)
+DEFINE_GOPAINTEDVALUETYPE(3)
+DEFINE_GOPAINTEDVALUETYPE(4)
+DEFINE_GOPAINTEDVALUETYPE(5)
+DEFINE_GOPAINTEDVALUETYPE(6)
+DEFINE_GOPAINTEDVALUETYPE(7)
+DEFINE_GOPAINTEDVALUETYPE(8)
+DEFINE_GOPAINTEDVALUETYPE(9)
+DEFINE_GOPAINTEDVALUETYPE(10)
+DEFINE_GOPAINTEDVALUETYPE(11)
+DEFINE_GOPAINTEDVALUETYPE(12)
+DEFINE_GOPAINTEDVALUETYPE(13)
+DEFINE_GOPAINTEDVALUETYPE(14)
+DEFINE_GOPAINTEDVALUETYPE(15)
+DEFINE_GOPAINTEDVALUETYPE(16)
+DEFINE_GOPAINTEDVALUETYPE(17)
+DEFINE_GOPAINTEDVALUETYPE(18)
+DEFINE_GOPAINTEDVALUETYPE(19)
+DEFINE_GOPAINTEDVALUETYPE(20)
+DEFINE_GOPAINTEDVALUETYPE(21)
+DEFINE_GOPAINTEDVALUETYPE(22)
+DEFINE_GOPAINTEDVALUETYPE(23)
+DEFINE_GOPAINTEDVALUETYPE(24)
+DEFINE_GOPAINTEDVALUETYPE(25)
+DEFINE_GOPAINTEDVALUETYPE(26)
+DEFINE_GOPAINTEDVALUETYPE(27)
+DEFINE_GOPAINTEDVALUETYPE(28)
+DEFINE_GOPAINTEDVALUETYPE(29)
+DEFINE_GOPAINTEDVALUETYPE(30)
+
+static int goValueTypeN = 0;
+static int goPaintedValueTypeN = 0;
+
+template<int N>
+int registerSingletonN(char *location, int major, int minor, char *name, GoTypeInfo *info, GoTypeSpec_ *spec) {
+ GoValueType<N>::init(info, spec);
+ return qmlRegisterSingletonType< GoValueType<N> >(location, major, minor, name, [](QQmlEngine *qmlEngine, QJSEngine *jsEngine) -> QObject* {
+ QObject *singleton = new GoValueType<N>();
+ QQmlEngine::setContextForObject(singleton, qmlEngine->rootContext());
+ return singleton;
+ });
+}
+
+template<int N>
+int registerPaintedSingletonN(char *location, int major, int minor, char *name, GoTypeInfo *info, GoTypeSpec_ *spec) {
+ GoPaintedValueType<N>::init(info, spec);
+ return qmlRegisterSingletonType< GoPaintedValueType<N> >(location, major, minor, name, [](QQmlEngine *qmlEngine, QJSEngine *jsEngine) -> QObject* {
+ QObject *singleton = new GoPaintedValueType<N>();
+ QQmlEngine::setContextForObject(singleton, qmlEngine->rootContext());
+ return singleton;
+ });
+}
+
+#define GOVALUETYPE_CASE_SINGLETON(N) \
+ case N: return registerSingletonN<N>(location, major, minor, name, info, spec);
+#define GOPAINTEDVALUETYPE_CASE_SINGLETON(N) \
+ case N: return registerPaintedSingletonN<N>(location, major, minor, name, info, spec);
+
+int registerSingleton(char *location, int major, int minor, char *name, GoTypeInfo *info, GoTypeSpec_ *spec)
+{
+ if (!info->paint) {
+ switch (++goValueTypeN) {
+ GOVALUETYPE_CASE_SINGLETON(1)
+ GOVALUETYPE_CASE_SINGLETON(2)
+ GOVALUETYPE_CASE_SINGLETON(3)
+ GOVALUETYPE_CASE_SINGLETON(4)
+ GOVALUETYPE_CASE_SINGLETON(5)
+ GOVALUETYPE_CASE_SINGLETON(6)
+ GOVALUETYPE_CASE_SINGLETON(7)
+ GOVALUETYPE_CASE_SINGLETON(8)
+ GOVALUETYPE_CASE_SINGLETON(9)
+ GOVALUETYPE_CASE_SINGLETON(10)
+ GOVALUETYPE_CASE_SINGLETON(11)
+ GOVALUETYPE_CASE_SINGLETON(12)
+ GOVALUETYPE_CASE_SINGLETON(13)
+ GOVALUETYPE_CASE_SINGLETON(14)
+ GOVALUETYPE_CASE_SINGLETON(15)
+ GOVALUETYPE_CASE_SINGLETON(16)
+ GOVALUETYPE_CASE_SINGLETON(17)
+ GOVALUETYPE_CASE_SINGLETON(18)
+ GOVALUETYPE_CASE_SINGLETON(19)
+ GOVALUETYPE_CASE_SINGLETON(20)
+ GOVALUETYPE_CASE_SINGLETON(21)
+ GOVALUETYPE_CASE_SINGLETON(22)
+ GOVALUETYPE_CASE_SINGLETON(23)
+ GOVALUETYPE_CASE_SINGLETON(24)
+ GOVALUETYPE_CASE_SINGLETON(25)
+ GOVALUETYPE_CASE_SINGLETON(26)
+ GOVALUETYPE_CASE_SINGLETON(27)
+ GOVALUETYPE_CASE_SINGLETON(28)
+ GOVALUETYPE_CASE_SINGLETON(29)
+ GOVALUETYPE_CASE_SINGLETON(30)
+ }
+ } else {
+ switch (++goPaintedValueTypeN) {
+ GOPAINTEDVALUETYPE_CASE_SINGLETON(1)
+ GOPAINTEDVALUETYPE_CASE_SINGLETON(2)
+ GOPAINTEDVALUETYPE_CASE_SINGLETON(3)
+ GOPAINTEDVALUETYPE_CASE_SINGLETON(4)
+ GOPAINTEDVALUETYPE_CASE_SINGLETON(5)
+ GOPAINTEDVALUETYPE_CASE_SINGLETON(6)
+ GOPAINTEDVALUETYPE_CASE_SINGLETON(7)
+ GOPAINTEDVALUETYPE_CASE_SINGLETON(8)
+ GOPAINTEDVALUETYPE_CASE_SINGLETON(9)
+ GOPAINTEDVALUETYPE_CASE_SINGLETON(10)
+ GOPAINTEDVALUETYPE_CASE_SINGLETON(11)
+ GOPAINTEDVALUETYPE_CASE_SINGLETON(12)
+ GOPAINTEDVALUETYPE_CASE_SINGLETON(13)
+ GOPAINTEDVALUETYPE_CASE_SINGLETON(14)
+ GOPAINTEDVALUETYPE_CASE_SINGLETON(15)
+ GOPAINTEDVALUETYPE_CASE_SINGLETON(16)
+ GOPAINTEDVALUETYPE_CASE_SINGLETON(17)
+ GOPAINTEDVALUETYPE_CASE_SINGLETON(18)
+ GOPAINTEDVALUETYPE_CASE_SINGLETON(19)
+ GOPAINTEDVALUETYPE_CASE_SINGLETON(20)
+ GOPAINTEDVALUETYPE_CASE_SINGLETON(21)
+ GOPAINTEDVALUETYPE_CASE_SINGLETON(22)
+ GOPAINTEDVALUETYPE_CASE_SINGLETON(23)
+ GOPAINTEDVALUETYPE_CASE_SINGLETON(24)
+ GOPAINTEDVALUETYPE_CASE_SINGLETON(25)
+ GOPAINTEDVALUETYPE_CASE_SINGLETON(26)
+ GOPAINTEDVALUETYPE_CASE_SINGLETON(27)
+ GOPAINTEDVALUETYPE_CASE_SINGLETON(28)
+ GOPAINTEDVALUETYPE_CASE_SINGLETON(29)
+ GOPAINTEDVALUETYPE_CASE_SINGLETON(30)
+ }
+ }
+ panicf("too many registered types; please contact the Go QML developers");
+ return 0;
+}
+
+#define GOVALUETYPE_CASE(N) \
+ case N: GoValueType<N>::init(info, spec); return qmlRegisterType< GoValueType<N> >(location, major, minor, name);
+#define GOPAINTEDVALUETYPE_CASE(N) \
+ case N: GoPaintedValueType<N>::init(info, spec); return qmlRegisterType< GoPaintedValueType<N> >(location, major, minor, name);
+
+int registerType(char *location, int major, int minor, char *name, GoTypeInfo *info, GoTypeSpec_ *spec)
+{
+ if (!info->paint) {
+ switch (++goValueTypeN) {
+ GOVALUETYPE_CASE(1)
+ GOVALUETYPE_CASE(2)
+ GOVALUETYPE_CASE(3)
+ GOVALUETYPE_CASE(4)
+ GOVALUETYPE_CASE(5)
+ GOVALUETYPE_CASE(6)
+ GOVALUETYPE_CASE(7)
+ GOVALUETYPE_CASE(8)
+ GOVALUETYPE_CASE(9)
+ GOVALUETYPE_CASE(10)
+ GOVALUETYPE_CASE(11)
+ GOVALUETYPE_CASE(12)
+ GOVALUETYPE_CASE(13)
+ GOVALUETYPE_CASE(14)
+ GOVALUETYPE_CASE(15)
+ GOVALUETYPE_CASE(16)
+ GOVALUETYPE_CASE(17)
+ GOVALUETYPE_CASE(18)
+ GOVALUETYPE_CASE(19)
+ GOVALUETYPE_CASE(20)
+ GOVALUETYPE_CASE(21)
+ GOVALUETYPE_CASE(22)
+ GOVALUETYPE_CASE(23)
+ GOVALUETYPE_CASE(24)
+ GOVALUETYPE_CASE(25)
+ GOVALUETYPE_CASE(26)
+ GOVALUETYPE_CASE(27)
+ GOVALUETYPE_CASE(28)
+ GOVALUETYPE_CASE(29)
+ GOVALUETYPE_CASE(30)
+ }
+ } else {
+ switch (++goPaintedValueTypeN) {
+ GOPAINTEDVALUETYPE_CASE(1)
+ GOPAINTEDVALUETYPE_CASE(2)
+ GOPAINTEDVALUETYPE_CASE(3)
+ GOPAINTEDVALUETYPE_CASE(4)
+ GOPAINTEDVALUETYPE_CASE(5)
+ GOPAINTEDVALUETYPE_CASE(6)
+ GOPAINTEDVALUETYPE_CASE(7)
+ GOPAINTEDVALUETYPE_CASE(8)
+ GOPAINTEDVALUETYPE_CASE(9)
+ GOPAINTEDVALUETYPE_CASE(10)
+ GOPAINTEDVALUETYPE_CASE(11)
+ GOPAINTEDVALUETYPE_CASE(12)
+ GOPAINTEDVALUETYPE_CASE(13)
+ GOPAINTEDVALUETYPE_CASE(14)
+ GOPAINTEDVALUETYPE_CASE(15)
+ GOPAINTEDVALUETYPE_CASE(16)
+ GOPAINTEDVALUETYPE_CASE(17)
+ GOPAINTEDVALUETYPE_CASE(18)
+ GOPAINTEDVALUETYPE_CASE(19)
+ GOPAINTEDVALUETYPE_CASE(20)
+ GOPAINTEDVALUETYPE_CASE(21)
+ GOPAINTEDVALUETYPE_CASE(22)
+ GOPAINTEDVALUETYPE_CASE(23)
+ GOPAINTEDVALUETYPE_CASE(24)
+ GOPAINTEDVALUETYPE_CASE(25)
+ GOPAINTEDVALUETYPE_CASE(26)
+ GOPAINTEDVALUETYPE_CASE(27)
+ GOPAINTEDVALUETYPE_CASE(28)
+ GOPAINTEDVALUETYPE_CASE(29)
+ GOPAINTEDVALUETYPE_CASE(30)
+ }
+ }
+ panicf("too many registered types; please contact the Go QML developers");
+ return 0;
+}
+
+// vim:sw=4:st=4:et:ft=cpp
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/cpp/govaluetype.h b/Godeps/_workspace/src/github.com/obscuren/qml/cpp/govaluetype.h
new file mode 100644
index 000000000..6007d394c
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/cpp/govaluetype.h
@@ -0,0 +1,48 @@
+#ifndef GOVALUETYPE_H
+#define GOVALUETYPE_H
+
+#include "govalue.h"
+
+template <int N>
+class GoValueType : public GoValue
+{
+public:
+
+ GoValueType()
+ : GoValue(hookGoValueTypeNew(this, typeSpec), typeInfo, 0) {};
+
+ static void init(GoTypeInfo *info, GoTypeSpec_ *spec)
+ {
+ typeInfo = info;
+ typeSpec = spec;
+ static_cast<QMetaObject &>(staticMetaObject) = *metaObjectFor(typeInfo);
+ };
+
+ static GoTypeSpec_ *typeSpec;
+ static GoTypeInfo *typeInfo;
+ static QMetaObject staticMetaObject;
+};
+
+template <int N>
+class GoPaintedValueType : public GoPaintedValue
+{
+public:
+
+ GoPaintedValueType()
+ : GoPaintedValue(hookGoValueTypeNew(this, typeSpec), typeInfo, 0) {};
+
+ static void init(GoTypeInfo *info, GoTypeSpec_ *spec)
+ {
+ typeInfo = info;
+ typeSpec = spec;
+ static_cast<QMetaObject &>(staticMetaObject) = *metaObjectFor(typeInfo);
+ };
+
+ static GoTypeSpec_ *typeSpec;
+ static GoTypeInfo *typeInfo;
+ static QMetaObject staticMetaObject;
+};
+
+#endif // GOVALUETYPE_H
+
+// vim:ts=4:sw=4:et
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/cpp/idletimer.cpp b/Godeps/_workspace/src/github.com/obscuren/qml/cpp/idletimer.cpp
new file mode 100644
index 000000000..3bd097508
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/cpp/idletimer.cpp
@@ -0,0 +1,58 @@
+#include <QBasicTimer>
+#include <QThread>
+#include <QDebug>
+#include <mutex>
+
+#include "capi.h"
+
+class IdleTimer : public QObject
+{
+ Q_OBJECT
+
+ public:
+
+ static IdleTimer *singleton() {
+ static IdleTimer singleton;
+ return &singleton;
+ }
+
+ void init(int32_t *guiIdleRun)
+ {
+ this->guiIdleRun = guiIdleRun;
+ }
+
+ Q_INVOKABLE void start()
+ {
+ timer.start(0, this);
+ }
+
+ protected:
+
+ void timerEvent(QTimerEvent *event)
+ {
+ __sync_synchronize();
+ if (*guiIdleRun > 0) {
+ hookIdleTimer();
+ } else {
+ timer.stop();
+ }
+ }
+
+ private:
+
+ int32_t *guiIdleRun;
+
+ QBasicTimer timer;
+};
+
+void idleTimerInit(int32_t *guiIdleRun)
+{
+ IdleTimer::singleton()->init(guiIdleRun);
+}
+
+void idleTimerStart()
+{
+ QMetaObject::invokeMethod(IdleTimer::singleton(), "start", Qt::QueuedConnection);
+}
+
+// vim:ts=4:sw=4:et:ft=cpp
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/cpp/mmemwin.cpp b/Godeps/_workspace/src/github.com/obscuren/qml/cpp/mmemwin.cpp
new file mode 100644
index 000000000..7aa3bff2b
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/cpp/mmemwin.cpp
@@ -0,0 +1,27 @@
+#include <windows.h>
+
+#define protREAD 1
+#define protWRITE 2
+#define protEXEC 4
+
+extern "C" {
+
+int mprotect(void *addr, size_t len, int prot)
+{
+ DWORD wprot = 0;
+ if (prot & protWRITE) {
+ wprot = PAGE_READWRITE;
+ } else if (prot & protREAD) {
+ wprot = PAGE_READONLY;
+ }
+ if (prot & protEXEC) {
+ wprot <<= 4;
+ }
+ DWORD oldwprot;
+ if (!VirtualProtect(addr, len, wprot, &oldwprot)) {
+ return -1;
+ }
+ return 0;
+}
+
+} // extern "C"
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/cpp/moc_all.cpp b/Godeps/_workspace/src/github.com/obscuren/qml/cpp/moc_all.cpp
new file mode 100644
index 000000000..cff097058
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/cpp/moc_all.cpp
@@ -0,0 +1,4 @@
+// This file is automatically generated by cpp/update-moc.sh
+#include "cpp/moc_connector.cpp"
+#include "cpp/moc_govalue.cpp"
+#include "cpp/moc_idletimer.cpp"
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/cpp/moc_connector.cpp b/Godeps/_workspace/src/github.com/obscuren/qml/cpp/moc_connector.cpp
new file mode 100644
index 000000000..2de2d827a
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/cpp/moc_connector.cpp
@@ -0,0 +1,211 @@
+/****************************************************************************
+** Meta object code from reading C++ file 'connector.h'
+**
+** Created by: The Qt Meta Object Compiler version 67 (Qt 5.2.1)
+**
+** WARNING! All changes made in this file will be lost!
+*****************************************************************************/
+
+#include "connector.h"
+#include <QtCore/qbytearray.h>
+#include <QtCore/qmetatype.h>
+#if !defined(Q_MOC_OUTPUT_REVISION)
+#error "The header file 'connector.h' doesn't include <QObject>."
+#elif Q_MOC_OUTPUT_REVISION != 67
+#error "This file was generated using the moc from 5.2.1. It"
+#error "cannot be used with the include files from this version of Qt."
+#error "(The moc has changed too much.)"
+#endif
+
+QT_BEGIN_MOC_NAMESPACE
+struct qt_meta_stringdata_Connector_t {
+ QByteArrayData data[3];
+ char stringdata[19];
+};
+#define QT_MOC_LITERAL(idx, ofs, len) \
+ Q_STATIC_BYTE_ARRAY_DATA_HEADER_INITIALIZER_WITH_OFFSET(len, \
+ offsetof(qt_meta_stringdata_Connector_t, stringdata) + ofs \
+ - idx * sizeof(QByteArrayData) \
+ )
+static const qt_meta_stringdata_Connector_t qt_meta_stringdata_Connector = {
+ {
+QT_MOC_LITERAL(0, 0, 9),
+QT_MOC_LITERAL(1, 10, 6),
+QT_MOC_LITERAL(2, 17, 0)
+ },
+ "Connector\0invoke\0\0"
+};
+#undef QT_MOC_LITERAL
+
+static const uint qt_meta_data_Connector[] = {
+
+ // content:
+ 7, // revision
+ 0, // classname
+ 0, 0, // classinfo
+ 1, 14, // methods
+ 0, 0, // properties
+ 0, 0, // enums/sets
+ 0, 0, // constructors
+ 0, // flags
+ 0, // signalCount
+
+ // slots: name, argc, parameters, tag, flags
+ 1, 0, 19, 2, 0x0a,
+
+ // slots: parameters
+ QMetaType::Void,
+
+ 0 // eod
+};
+
+void Connector::qt_static_metacall(QObject *_o, QMetaObject::Call _c, int _id, void **_a)
+{
+ if (_c == QMetaObject::InvokeMetaMethod) {
+ Connector *_t = static_cast<Connector *>(_o);
+ switch (_id) {
+ case 0: _t->invoke(); break;
+ default: ;
+ }
+ }
+ Q_UNUSED(_a);
+}
+
+const QMetaObject Connector::staticMetaObject = {
+ { &QObject::staticMetaObject, qt_meta_stringdata_Connector.data,
+ qt_meta_data_Connector, qt_static_metacall, 0, 0}
+};
+
+
+const QMetaObject *Connector::metaObject() const
+{
+ return QObject::d_ptr->metaObject ? QObject::d_ptr->dynamicMetaObject() : &staticMetaObject;
+}
+
+void *Connector::qt_metacast(const char *_clname)
+{
+ if (!_clname) return 0;
+ if (!strcmp(_clname, qt_meta_stringdata_Connector.stringdata))
+ return static_cast<void*>(const_cast< Connector*>(this));
+ return QObject::qt_metacast(_clname);
+}
+
+int Connector::standard_qt_metacall(QMetaObject::Call _c, int _id, void **_a)
+{
+ _id = QObject::qt_metacall(_c, _id, _a);
+ if (_id < 0)
+ return _id;
+ if (_c == QMetaObject::InvokeMetaMethod) {
+ if (_id < 1)
+ qt_static_metacall(this, _c, _id, _a);
+ _id -= 1;
+ } else if (_c == QMetaObject::RegisterMethodArgumentMetaType) {
+ if (_id < 1)
+ *reinterpret_cast<int*>(_a[0]) = -1;
+ _id -= 1;
+ }
+ return _id;
+}
+struct qt_meta_stringdata_PlainObject_t {
+ QByteArrayData data[3];
+ char stringdata[33];
+};
+#define QT_MOC_LITERAL(idx, ofs, len) \
+ Q_STATIC_BYTE_ARRAY_DATA_HEADER_INITIALIZER_WITH_OFFSET(len, \
+ offsetof(qt_meta_stringdata_PlainObject_t, stringdata) + ofs \
+ - idx * sizeof(QByteArrayData) \
+ )
+static const qt_meta_stringdata_PlainObject_t qt_meta_stringdata_PlainObject = {
+ {
+QT_MOC_LITERAL(0, 0, 11),
+QT_MOC_LITERAL(1, 12, 9),
+QT_MOC_LITERAL(2, 22, 9)
+ },
+ "PlainObject\0plainType\0plainAddr\0"
+};
+#undef QT_MOC_LITERAL
+
+static const uint qt_meta_data_PlainObject[] = {
+
+ // content:
+ 7, // revision
+ 0, // classname
+ 0, 0, // classinfo
+ 0, 0, // methods
+ 2, 14, // properties
+ 0, 0, // enums/sets
+ 0, 0, // constructors
+ 0, // flags
+ 0, // signalCount
+
+ // properties: name, type, flags
+ 1, QMetaType::QString, 0x00095001,
+ 2, QMetaType::VoidStar, 0x00095001,
+
+ 0 // eod
+};
+
+void PlainObject::qt_static_metacall(QObject *_o, QMetaObject::Call _c, int _id, void **_a)
+{
+ Q_UNUSED(_o);
+ Q_UNUSED(_id);
+ Q_UNUSED(_c);
+ Q_UNUSED(_a);
+}
+
+const QMetaObject PlainObject::staticMetaObject = {
+ { &QObject::staticMetaObject, qt_meta_stringdata_PlainObject.data,
+ qt_meta_data_PlainObject, qt_static_metacall, 0, 0}
+};
+
+
+const QMetaObject *PlainObject::metaObject() const
+{
+ return QObject::d_ptr->metaObject ? QObject::d_ptr->dynamicMetaObject() : &staticMetaObject;
+}
+
+void *PlainObject::qt_metacast(const char *_clname)
+{
+ if (!_clname) return 0;
+ if (!strcmp(_clname, qt_meta_stringdata_PlainObject.stringdata))
+ return static_cast<void*>(const_cast< PlainObject*>(this));
+ return QObject::qt_metacast(_clname);
+}
+
+int PlainObject::qt_metacall(QMetaObject::Call _c, int _id, void **_a)
+{
+ _id = QObject::qt_metacall(_c, _id, _a);
+ if (_id < 0)
+ return _id;
+
+#ifndef QT_NO_PROPERTIES
+ if (_c == QMetaObject::ReadProperty) {
+ void *_v = _a[0];
+ switch (_id) {
+ case 0: *reinterpret_cast< QString*>(_v) = getPlainType(); break;
+ case 1: *reinterpret_cast< void**>(_v) = getPlainAddr(); break;
+ }
+ _id -= 2;
+ } else if (_c == QMetaObject::WriteProperty) {
+ _id -= 2;
+ } else if (_c == QMetaObject::ResetProperty) {
+ _id -= 2;
+ } else if (_c == QMetaObject::QueryPropertyDesignable) {
+ _id -= 2;
+ } else if (_c == QMetaObject::QueryPropertyScriptable) {
+ _id -= 2;
+ } else if (_c == QMetaObject::QueryPropertyStored) {
+ _id -= 2;
+ } else if (_c == QMetaObject::QueryPropertyEditable) {
+ _id -= 2;
+ } else if (_c == QMetaObject::QueryPropertyUser) {
+ _id -= 2;
+ } else if (_c == QMetaObject::RegisterPropertyMetaType) {
+ if (_id < 2)
+ *reinterpret_cast<int*>(_a[0]) = -1;
+ _id -= 2;
+ }
+#endif // QT_NO_PROPERTIES
+ return _id;
+}
+QT_END_MOC_NAMESPACE
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/cpp/moc_govalue.cpp b/Godeps/_workspace/src/github.com/obscuren/qml/cpp/moc_govalue.cpp
new file mode 100644
index 000000000..e41f86042
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/cpp/moc_govalue.cpp
@@ -0,0 +1,155 @@
+/****************************************************************************
+** Meta object code from reading C++ file 'govalue.h'
+**
+** Created by: The Qt Meta Object Compiler version 67 (Qt 5.2.1)
+**
+** WARNING! All changes made in this file will be lost!
+*****************************************************************************/
+
+#include "govalue.h"
+#include <QtCore/qbytearray.h>
+#include <QtCore/qmetatype.h>
+#if !defined(Q_MOC_OUTPUT_REVISION)
+#error "The header file 'govalue.h' doesn't include <QObject>."
+#elif Q_MOC_OUTPUT_REVISION != 67
+#error "This file was generated using the moc from 5.2.1. It"
+#error "cannot be used with the include files from this version of Qt."
+#error "(The moc has changed too much.)"
+#endif
+
+QT_BEGIN_MOC_NAMESPACE
+struct qt_meta_stringdata_GoValue_t {
+ QByteArrayData data[1];
+ char stringdata[9];
+};
+#define QT_MOC_LITERAL(idx, ofs, len) \
+ Q_STATIC_BYTE_ARRAY_DATA_HEADER_INITIALIZER_WITH_OFFSET(len, \
+ offsetof(qt_meta_stringdata_GoValue_t, stringdata) + ofs \
+ - idx * sizeof(QByteArrayData) \
+ )
+static const qt_meta_stringdata_GoValue_t qt_meta_stringdata_GoValue = {
+ {
+QT_MOC_LITERAL(0, 0, 7)
+ },
+ "GoValue\0"
+};
+#undef QT_MOC_LITERAL
+
+static const uint qt_meta_data_GoValue[] = {
+
+ // content:
+ 7, // revision
+ 0, // classname
+ 0, 0, // classinfo
+ 0, 0, // methods
+ 0, 0, // properties
+ 0, 0, // enums/sets
+ 0, 0, // constructors
+ 0, // flags
+ 0, // signalCount
+
+ 0 // eod
+};
+
+void GoValue::qt_static_metacall(QObject *_o, QMetaObject::Call _c, int _id, void **_a)
+{
+ Q_UNUSED(_o);
+ Q_UNUSED(_id);
+ Q_UNUSED(_c);
+ Q_UNUSED(_a);
+}
+
+const QMetaObject GoValue::staticMetaObject = {
+ { &QObject::staticMetaObject, qt_meta_stringdata_GoValue.data,
+ qt_meta_data_GoValue, qt_static_metacall, 0, 0}
+};
+
+
+const QMetaObject *GoValue::metaObject() const
+{
+ return QObject::d_ptr->metaObject ? QObject::d_ptr->dynamicMetaObject() : &staticMetaObject;
+}
+
+void *GoValue::qt_metacast(const char *_clname)
+{
+ if (!_clname) return 0;
+ if (!strcmp(_clname, qt_meta_stringdata_GoValue.stringdata))
+ return static_cast<void*>(const_cast< GoValue*>(this));
+ return QObject::qt_metacast(_clname);
+}
+
+int GoValue::qt_metacall(QMetaObject::Call _c, int _id, void **_a)
+{
+ _id = QObject::qt_metacall(_c, _id, _a);
+ if (_id < 0)
+ return _id;
+ return _id;
+}
+struct qt_meta_stringdata_GoPaintedValue_t {
+ QByteArrayData data[1];
+ char stringdata[16];
+};
+#define QT_MOC_LITERAL(idx, ofs, len) \
+ Q_STATIC_BYTE_ARRAY_DATA_HEADER_INITIALIZER_WITH_OFFSET(len, \
+ offsetof(qt_meta_stringdata_GoPaintedValue_t, stringdata) + ofs \
+ - idx * sizeof(QByteArrayData) \
+ )
+static const qt_meta_stringdata_GoPaintedValue_t qt_meta_stringdata_GoPaintedValue = {
+ {
+QT_MOC_LITERAL(0, 0, 14)
+ },
+ "GoPaintedValue\0"
+};
+#undef QT_MOC_LITERAL
+
+static const uint qt_meta_data_GoPaintedValue[] = {
+
+ // content:
+ 7, // revision
+ 0, // classname
+ 0, 0, // classinfo
+ 0, 0, // methods
+ 0, 0, // properties
+ 0, 0, // enums/sets
+ 0, 0, // constructors
+ 0, // flags
+ 0, // signalCount
+
+ 0 // eod
+};
+
+void GoPaintedValue::qt_static_metacall(QObject *_o, QMetaObject::Call _c, int _id, void **_a)
+{
+ Q_UNUSED(_o);
+ Q_UNUSED(_id);
+ Q_UNUSED(_c);
+ Q_UNUSED(_a);
+}
+
+const QMetaObject GoPaintedValue::staticMetaObject = {
+ { &QQuickPaintedItem::staticMetaObject, qt_meta_stringdata_GoPaintedValue.data,
+ qt_meta_data_GoPaintedValue, qt_static_metacall, 0, 0}
+};
+
+
+const QMetaObject *GoPaintedValue::metaObject() const
+{
+ return QObject::d_ptr->metaObject ? QObject::d_ptr->dynamicMetaObject() : &staticMetaObject;
+}
+
+void *GoPaintedValue::qt_metacast(const char *_clname)
+{
+ if (!_clname) return 0;
+ if (!strcmp(_clname, qt_meta_stringdata_GoPaintedValue.stringdata))
+ return static_cast<void*>(const_cast< GoPaintedValue*>(this));
+ return QQuickPaintedItem::qt_metacast(_clname);
+}
+
+int GoPaintedValue::qt_metacall(QMetaObject::Call _c, int _id, void **_a)
+{
+ _id = QQuickPaintedItem::qt_metacall(_c, _id, _a);
+ if (_id < 0)
+ return _id;
+ return _id;
+}
+QT_END_MOC_NAMESPACE
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/cpp/moc_idletimer.cpp b/Godeps/_workspace/src/github.com/obscuren/qml/cpp/moc_idletimer.cpp
new file mode 100644
index 000000000..98dda16e3
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/cpp/moc_idletimer.cpp
@@ -0,0 +1,108 @@
+/****************************************************************************
+** Meta object code from reading C++ file 'idletimer.cpp'
+**
+** Created by: The Qt Meta Object Compiler version 67 (Qt 5.2.1)
+**
+** WARNING! All changes made in this file will be lost!
+*****************************************************************************/
+
+#include <QtCore/qbytearray.h>
+#include <QtCore/qmetatype.h>
+#if !defined(Q_MOC_OUTPUT_REVISION)
+#error "The header file 'idletimer.cpp' doesn't include <QObject>."
+#elif Q_MOC_OUTPUT_REVISION != 67
+#error "This file was generated using the moc from 5.2.1. It"
+#error "cannot be used with the include files from this version of Qt."
+#error "(The moc has changed too much.)"
+#endif
+
+QT_BEGIN_MOC_NAMESPACE
+struct qt_meta_stringdata_IdleTimer_t {
+ QByteArrayData data[3];
+ char stringdata[18];
+};
+#define QT_MOC_LITERAL(idx, ofs, len) \
+ Q_STATIC_BYTE_ARRAY_DATA_HEADER_INITIALIZER_WITH_OFFSET(len, \
+ offsetof(qt_meta_stringdata_IdleTimer_t, stringdata) + ofs \
+ - idx * sizeof(QByteArrayData) \
+ )
+static const qt_meta_stringdata_IdleTimer_t qt_meta_stringdata_IdleTimer = {
+ {
+QT_MOC_LITERAL(0, 0, 9),
+QT_MOC_LITERAL(1, 10, 5),
+QT_MOC_LITERAL(2, 16, 0)
+ },
+ "IdleTimer\0start\0\0"
+};
+#undef QT_MOC_LITERAL
+
+static const uint qt_meta_data_IdleTimer[] = {
+
+ // content:
+ 7, // revision
+ 0, // classname
+ 0, 0, // classinfo
+ 1, 14, // methods
+ 0, 0, // properties
+ 0, 0, // enums/sets
+ 0, 0, // constructors
+ 0, // flags
+ 0, // signalCount
+
+ // methods: name, argc, parameters, tag, flags
+ 1, 0, 19, 2, 0x02,
+
+ // methods: parameters
+ QMetaType::Void,
+
+ 0 // eod
+};
+
+void IdleTimer::qt_static_metacall(QObject *_o, QMetaObject::Call _c, int _id, void **_a)
+{
+ if (_c == QMetaObject::InvokeMetaMethod) {
+ IdleTimer *_t = static_cast<IdleTimer *>(_o);
+ switch (_id) {
+ case 0: _t->start(); break;
+ default: ;
+ }
+ }
+ Q_UNUSED(_a);
+}
+
+const QMetaObject IdleTimer::staticMetaObject = {
+ { &QObject::staticMetaObject, qt_meta_stringdata_IdleTimer.data,
+ qt_meta_data_IdleTimer, qt_static_metacall, 0, 0}
+};
+
+
+const QMetaObject *IdleTimer::metaObject() const
+{
+ return QObject::d_ptr->metaObject ? QObject::d_ptr->dynamicMetaObject() : &staticMetaObject;
+}
+
+void *IdleTimer::qt_metacast(const char *_clname)
+{
+ if (!_clname) return 0;
+ if (!strcmp(_clname, qt_meta_stringdata_IdleTimer.stringdata))
+ return static_cast<void*>(const_cast< IdleTimer*>(this));
+ return QObject::qt_metacast(_clname);
+}
+
+int IdleTimer::qt_metacall(QMetaObject::Call _c, int _id, void **_a)
+{
+ _id = QObject::qt_metacall(_c, _id, _a);
+ if (_id < 0)
+ return _id;
+ if (_c == QMetaObject::InvokeMetaMethod) {
+ if (_id < 1)
+ qt_static_metacall(this, _c, _id, _a);
+ _id -= 1;
+ } else if (_c == QMetaObject::RegisterMethodArgumentMetaType) {
+ if (_id < 1)
+ *reinterpret_cast<int*>(_a[0]) = -1;
+ _id -= 1;
+ }
+ return _id;
+}
+QT_END_MOC_NAMESPACE
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/cpp/private/qmetaobject_p.h b/Godeps/_workspace/src/github.com/obscuren/qml/cpp/private/qmetaobject_p.h
new file mode 100644
index 000000000..af506e54f
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/cpp/private/qmetaobject_p.h
@@ -0,0 +1,2 @@
+#include "private/qtheader.h"
+#include QT_PRIVATE_HEADER(QtCore,qmetaobject_p.h)
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/cpp/private/qmetaobjectbuilder_p.h b/Godeps/_workspace/src/github.com/obscuren/qml/cpp/private/qmetaobjectbuilder_p.h
new file mode 100644
index 000000000..47cd9b77f
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/cpp/private/qmetaobjectbuilder_p.h
@@ -0,0 +1,2 @@
+#include "private/qtheader.h"
+#include QT_PRIVATE_HEADER(QtCore,qmetaobjectbuilder_p.h)
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/cpp/private/qobject_p.h b/Godeps/_workspace/src/github.com/obscuren/qml/cpp/private/qobject_p.h
new file mode 100644
index 000000000..75c7f84b4
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/cpp/private/qobject_p.h
@@ -0,0 +1,2 @@
+#include "private/qtheader.h"
+#include QT_PRIVATE_HEADER(QtCore,qobject_p.h)
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/cpp/private/qtheader.h b/Godeps/_workspace/src/github.com/obscuren/qml/cpp/private/qtheader.h
new file mode 100644
index 000000000..efa8b87c4
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/cpp/private/qtheader.h
@@ -0,0 +1,70 @@
+#ifndef QTPRIVATE_H
+#define QTPRIVATE_H
+
+#include <QtCore/qglobal.h>
+
+#define QT_MAJOR_ (QT_VERSION>>16)
+#define QT_MINOR_ (QT_VERSION>>8&0xFF)
+#define QT_MICRO_ (QT_VERSION&0xFF)
+
+#if QT_MAJOR_ == 5
+#define QT_MAJOR 5
+#else
+#error Unupported Qt major version. Please report.
+#endif
+
+#if QT_MINOR_ == 0
+#define QT_MINOR 0
+#elif QT_MINOR_ == 1
+#define QT_MINOR 1
+#elif QT_MINOR_ == 2
+#define QT_MINOR 2
+#elif QT_MINOR_ == 3
+#define QT_MINOR 3
+#elif QT_MINOR_ == 4
+#define QT_MINOR 4
+#elif QT_MINOR_ == 5
+#define QT_MINOR 5
+#elif QT_MINOR_ == 6
+#define QT_MINOR 6
+#elif QT_MINOR_ == 7
+#define QT_MINOR 7
+#elif QT_MINOR_ == 8
+#define QT_MINOR 8
+#elif QT_MINOR_ == 9
+#define QT_MINOR 9
+#elif QT_MINOR_ == 10
+#define QT_MINOR 10
+#else
+#error Unupported Qt minor version. Please report.
+#endif
+
+#if QT_MICRO_ == 0
+#define QT_MICRO 0
+#elif QT_MICRO_ == 1
+#define QT_MICRO 1
+#elif QT_MICRO_ == 2
+#define QT_MICRO 2
+#elif QT_MICRO_ == 3
+#define QT_MICRO 3
+#elif QT_MICRO_ == 4
+#define QT_MICRO 4
+#elif QT_MICRO_ == 5
+#define QT_MICRO 5
+#elif QT_MICRO_ == 6
+#define QT_MICRO 6
+#elif QT_MICRO_ == 7
+#define QT_MICRO 7
+#elif QT_MICRO_ == 8
+#define QT_MICRO 8
+#elif QT_MICRO_ == 9
+#define QT_MICRO 9
+#elif QT_MICRO_ == 10
+#define QT_MICRO 10
+#else
+#error Unupported Qt micro version. Please report.
+#endif
+
+#define QT_PRIVATE_HEADER(dir,file) <dir/QT_MAJOR.QT_MINOR.QT_MICRO/dir/private/file>
+
+#endif // QTPRIVATE_H
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/cpp/update-moc.sh b/Godeps/_workspace/src/github.com/obscuren/qml/cpp/update-moc.sh
new file mode 100644
index 000000000..135840f45
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/cpp/update-moc.sh
@@ -0,0 +1,19 @@
+#!/bin/sh
+
+set -e
+cd `dirname $0`
+
+subdir=`basename $PWD`
+
+export QT_SELECT=5
+
+ALL=moc_all.cpp
+
+echo "// This file is automatically generated by cpp/update-moc.sh" > $ALL
+
+for file in `grep -l Q_''OBJECT *`; do
+ mocfile=`echo $file | awk -F. '{print("moc_"$1".cpp")}'`
+ mochack=`sed -n 's,^ *// MOC HACK: \(.*\),\1,p' $file`
+ moc $file | sed "$mochack" > $mocfile
+ echo "#include \"$subdir/$mocfile\"" >> $ALL
+done
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/cpptest/cpptest.cpp b/Godeps/_workspace/src/github.com/obscuren/qml/cpptest/cpptest.cpp
new file mode 100644
index 000000000..e0b25699f
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/cpptest/cpptest.cpp
@@ -0,0 +1,14 @@
+#include <string.h>
+
+#include "cpptest.h"
+#include "testtype.h"
+
+TestType_ *newTestType()
+{
+ return new TestType();
+}
+
+int plainTestTypeN(PlainTestType_ *plain)
+{
+ return static_cast<PlainTestType *>(plain)->n;
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/cpptest/cpptest.go b/Godeps/_workspace/src/github.com/obscuren/qml/cpptest/cpptest.go
new file mode 100644
index 000000000..4ba24bce0
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/cpptest/cpptest.go
@@ -0,0 +1,30 @@
+// Package cpptest is an internal test helper.
+package cpptest
+
+// #cgo CXXFLAGS: -std=c++0x -Wall -fno-strict-aliasing -I..
+// #cgo LDFLAGS: -lstdc++
+//
+// #cgo pkg-config: Qt5Core
+//
+// #include "cpptest.h"
+//
+import "C"
+
+import (
+ "unsafe"
+
+ "gopkg.in/qml.v1"
+)
+
+func NewTestType(engine *qml.Engine) qml.Object {
+ var obj qml.Object
+ qml.RunMain(func() {
+ addr := C.newTestType()
+ obj = qml.CommonOf(addr, engine)
+ })
+ return obj
+}
+
+func PlainTestTypeN(obj qml.Object) int {
+ return int(C.plainTestTypeN(unsafe.Pointer(obj.Property("plainAddr").(uintptr))))
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/cpptest/cpptest.h b/Godeps/_workspace/src/github.com/obscuren/qml/cpptest/cpptest.h
new file mode 100644
index 000000000..e06a8af3f
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/cpptest/cpptest.h
@@ -0,0 +1,23 @@
+#ifndef UONEAUTH_H
+#define UONEAUTH_H
+
+#include <stdint.h>
+#include <stddef.h>
+#include <stdlib.h>
+
+typedef void TestType_;
+typedef void PlainTestType_;
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+TestType_ *newTestType();
+
+int plainTestTypeN(PlainTestType_ *plain);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif // UONEAUTH_H
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/cpptest/moc_testtype.cpp b/Godeps/_workspace/src/github.com/obscuren/qml/cpptest/moc_testtype.cpp
new file mode 100644
index 000000000..f958d1b8c
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/cpptest/moc_testtype.cpp
@@ -0,0 +1,202 @@
+/****************************************************************************
+** Meta object code from reading C++ file 'testtype.h'
+**
+** Created by: The Qt Meta Object Compiler version 67 (Qt 5.2.1)
+**
+** WARNING! All changes made in this file will be lost!
+*****************************************************************************/
+
+#include "testtype.h"
+#include <QtCore/qbytearray.h>
+#include <QtCore/qmetatype.h>
+#if !defined(Q_MOC_OUTPUT_REVISION)
+#error "The header file 'testtype.h' doesn't include <QObject>."
+#elif Q_MOC_OUTPUT_REVISION != 67
+#error "This file was generated using the moc from 5.2.1. It"
+#error "cannot be used with the include files from this version of Qt."
+#error "(The moc has changed too much.)"
+#endif
+
+QT_BEGIN_MOC_NAMESPACE
+struct qt_meta_stringdata_TestType_t {
+ QByteArrayData data[10];
+ char stringdata[119];
+};
+#define QT_MOC_LITERAL(idx, ofs, len) \
+ Q_STATIC_BYTE_ARRAY_DATA_HEADER_INITIALIZER_WITH_OFFSET(len, \
+ offsetof(qt_meta_stringdata_TestType_t, stringdata) + ofs \
+ - idx * sizeof(QByteArrayData) \
+ )
+static const qt_meta_stringdata_TestType_t qt_meta_stringdata_TestType = {
+ {
+QT_MOC_LITERAL(0, 0, 8),
+QT_MOC_LITERAL(1, 9, 15),
+QT_MOC_LITERAL(2, 25, 0),
+QT_MOC_LITERAL(3, 26, 13),
+QT_MOC_LITERAL(4, 40, 5),
+QT_MOC_LITERAL(5, 46, 15),
+QT_MOC_LITERAL(6, 62, 15),
+QT_MOC_LITERAL(7, 78, 20),
+QT_MOC_LITERAL(8, 99, 9),
+QT_MOC_LITERAL(9, 109, 8)
+ },
+ "TestType\0plainEmittedCpy\0\0PlainTestType\0"
+ "plain\0plainEmittedRef\0plainEmittedPtr\0"
+ "const PlainTestType*\0emitPlain\0voidAddr\0"
+};
+#undef QT_MOC_LITERAL
+
+static const uint qt_meta_data_TestType[] = {
+
+ // content:
+ 7, // revision
+ 0, // classname
+ 0, 0, // classinfo
+ 4, 14, // methods
+ 1, 44, // properties
+ 0, 0, // enums/sets
+ 0, 0, // constructors
+ 0, // flags
+ 3, // signalCount
+
+ // signals: name, argc, parameters, tag, flags
+ 1, 1, 34, 2, 0x06,
+ 5, 1, 37, 2, 0x06,
+ 6, 1, 40, 2, 0x06,
+
+ // methods: name, argc, parameters, tag, flags
+ 8, 0, 43, 2, 0x02,
+
+ // signals: parameters
+ QMetaType::Void, 0x80000000 | 3, 4,
+ QMetaType::Void, 0x80000000 | 3, 4,
+ QMetaType::Void, 0x80000000 | 7, 4,
+
+ // methods: parameters
+ QMetaType::Void,
+
+ // properties: name, type, flags
+ 9, QMetaType::VoidStar, 0x00095001,
+
+ 0 // eod
+};
+
+void TestType::qt_static_metacall(QObject *_o, QMetaObject::Call _c, int _id, void **_a)
+{
+ if (_c == QMetaObject::InvokeMetaMethod) {
+ TestType *_t = static_cast<TestType *>(_o);
+ switch (_id) {
+ case 0: _t->plainEmittedCpy((*reinterpret_cast< const PlainTestType(*)>(_a[1]))); break;
+ case 1: _t->plainEmittedRef((*reinterpret_cast< const PlainTestType(*)>(_a[1]))); break;
+ case 2: _t->plainEmittedPtr((*reinterpret_cast< const PlainTestType*(*)>(_a[1]))); break;
+ case 3: _t->emitPlain(); break;
+ default: ;
+ }
+ } else if (_c == QMetaObject::IndexOfMethod) {
+ int *result = reinterpret_cast<int *>(_a[0]);
+ void **func = reinterpret_cast<void **>(_a[1]);
+ {
+ typedef void (TestType::*_t)(const PlainTestType );
+ if (*reinterpret_cast<_t *>(func) == static_cast<_t>(&TestType::plainEmittedCpy)) {
+ *result = 0;
+ }
+ }
+ {
+ typedef void (TestType::*_t)(const PlainTestType & );
+ if (*reinterpret_cast<_t *>(func) == static_cast<_t>(&TestType::plainEmittedRef)) {
+ *result = 1;
+ }
+ }
+ {
+ typedef void (TestType::*_t)(const PlainTestType * );
+ if (*reinterpret_cast<_t *>(func) == static_cast<_t>(&TestType::plainEmittedPtr)) {
+ *result = 2;
+ }
+ }
+ }
+}
+
+const QMetaObject TestType::staticMetaObject = {
+ { &QObject::staticMetaObject, qt_meta_stringdata_TestType.data,
+ qt_meta_data_TestType, qt_static_metacall, 0, 0}
+};
+
+
+const QMetaObject *TestType::metaObject() const
+{
+ return QObject::d_ptr->metaObject ? QObject::d_ptr->dynamicMetaObject() : &staticMetaObject;
+}
+
+void *TestType::qt_metacast(const char *_clname)
+{
+ if (!_clname) return 0;
+ if (!strcmp(_clname, qt_meta_stringdata_TestType.stringdata))
+ return static_cast<void*>(const_cast< TestType*>(this));
+ return QObject::qt_metacast(_clname);
+}
+
+int TestType::qt_metacall(QMetaObject::Call _c, int _id, void **_a)
+{
+ _id = QObject::qt_metacall(_c, _id, _a);
+ if (_id < 0)
+ return _id;
+ if (_c == QMetaObject::InvokeMetaMethod) {
+ if (_id < 4)
+ qt_static_metacall(this, _c, _id, _a);
+ _id -= 4;
+ } else if (_c == QMetaObject::RegisterMethodArgumentMetaType) {
+ if (_id < 4)
+ *reinterpret_cast<int*>(_a[0]) = -1;
+ _id -= 4;
+ }
+#ifndef QT_NO_PROPERTIES
+ else if (_c == QMetaObject::ReadProperty) {
+ void *_v = _a[0];
+ switch (_id) {
+ case 0: *reinterpret_cast< void**>(_v) = getVoidAddr(); break;
+ }
+ _id -= 1;
+ } else if (_c == QMetaObject::WriteProperty) {
+ _id -= 1;
+ } else if (_c == QMetaObject::ResetProperty) {
+ _id -= 1;
+ } else if (_c == QMetaObject::QueryPropertyDesignable) {
+ _id -= 1;
+ } else if (_c == QMetaObject::QueryPropertyScriptable) {
+ _id -= 1;
+ } else if (_c == QMetaObject::QueryPropertyStored) {
+ _id -= 1;
+ } else if (_c == QMetaObject::QueryPropertyEditable) {
+ _id -= 1;
+ } else if (_c == QMetaObject::QueryPropertyUser) {
+ _id -= 1;
+ } else if (_c == QMetaObject::RegisterPropertyMetaType) {
+ if (_id < 1)
+ *reinterpret_cast<int*>(_a[0]) = -1;
+ _id -= 1;
+ }
+#endif // QT_NO_PROPERTIES
+ return _id;
+}
+
+// SIGNAL 0
+void TestType::plainEmittedCpy(const PlainTestType _t1)
+{
+ void *_a[] = { 0, const_cast<void*>(reinterpret_cast<const void*>(&_t1)) };
+ QMetaObject::activate(this, &staticMetaObject, 0, _a);
+}
+
+// SIGNAL 1
+void TestType::plainEmittedRef(const PlainTestType & _t1)
+{
+ void *_a[] = { 0, const_cast<void*>(reinterpret_cast<const void*>(&_t1)) };
+ QMetaObject::activate(this, &staticMetaObject, 1, _a);
+}
+
+// SIGNAL 2
+void TestType::plainEmittedPtr(const PlainTestType * _t1)
+{
+ void *_a[] = { 0, const_cast<void*>(reinterpret_cast<const void*>(&_t1)) };
+ QMetaObject::activate(this, &staticMetaObject, 2, _a);
+}
+QT_END_MOC_NAMESPACE
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/cpptest/testtype.h b/Godeps/_workspace/src/github.com/obscuren/qml/cpptest/testtype.h
new file mode 100644
index 000000000..4d281b98f
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/cpptest/testtype.h
@@ -0,0 +1,45 @@
+#ifndef TESTTYPE_H
+#define TESTTYPE_H
+
+#include <QObject>
+
+class PlainTestType {
+
+ public:
+
+ PlainTestType(int n) : n(n) {};
+
+ int n;
+};
+
+class TestType : public QObject
+{
+ Q_OBJECT
+
+ Q_PROPERTY(void *voidAddr READ getVoidAddr)
+
+ void *voidAddr;
+
+ public:
+
+ TestType(QObject *parent = 0) : QObject(parent), voidAddr((void*)42) {};
+
+ void *getVoidAddr() { return voidAddr; };
+
+ Q_INVOKABLE void emitPlain() {
+ PlainTestType plain = PlainTestType(42);
+ emit plainEmittedCpy(plain);
+ emit plainEmittedRef(plain);
+ emit plainEmittedPtr(&plain);
+ };
+
+ signals:
+
+ void plainEmittedCpy(const PlainTestType plain);
+ void plainEmittedRef(const PlainTestType &plain);
+ void plainEmittedPtr(const PlainTestType *plain);
+};
+
+#endif // TESTTYPE_H
+
+// vim:ts=4:sw=4:et
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/cpptest/update-moc.sh b/Godeps/_workspace/src/github.com/obscuren/qml/cpptest/update-moc.sh
new file mode 100644
index 000000000..9abbfdf2b
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/cpptest/update-moc.sh
@@ -0,0 +1,12 @@
+#!/bin/sh
+
+set -e
+cd `dirname $0`
+
+export QT_SELECT=5
+
+for file in `grep -l Q_''OBJECT *`; do
+ mocfile=`echo $file | awk -F. '{print("moc_"$1".cpp")}'`
+ mochack=`sed -n 's,^ *// MOC HACK: \(.*\),\1,p' $file`
+ moc $file | sed "$mochack" > $mocfile
+done
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/datatype.go b/Godeps/_workspace/src/github.com/obscuren/qml/datatype.go
new file mode 100644
index 000000000..875c54622
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/datatype.go
@@ -0,0 +1,531 @@
+package qml
+
+// #include <stdlib.h>
+// #include "capi.h"
+import "C"
+
+import (
+ "bytes"
+ "fmt"
+ "image/color"
+ "reflect"
+ "strings"
+ "unicode"
+ "unsafe"
+)
+
+var (
+ intIs64 bool
+ intDT C.DataType
+
+ ptrSize = C.size_t(unsafe.Sizeof(uintptr(0)))
+
+ nilPtr = unsafe.Pointer(uintptr(0))
+ nilCharPtr = (*C.char)(nilPtr)
+
+ typeString = reflect.TypeOf("")
+ typeBool = reflect.TypeOf(false)
+ typeInt = reflect.TypeOf(int(0))
+ typeInt64 = reflect.TypeOf(int64(0))
+ typeInt32 = reflect.TypeOf(int32(0))
+ typeFloat64 = reflect.TypeOf(float64(0))
+ typeFloat32 = reflect.TypeOf(float32(0))
+ typeIface = reflect.TypeOf(new(interface{})).Elem()
+ typeRGBA = reflect.TypeOf(color.RGBA{})
+ typeObjSlice = reflect.TypeOf([]Object(nil))
+ typeObject = reflect.TypeOf([]Object(nil)).Elem()
+ typePainter = reflect.TypeOf(&Painter{})
+ typeList = reflect.TypeOf(&List{})
+ typeMap = reflect.TypeOf(&Map{})
+ typeGenericMap = reflect.TypeOf(map[string]interface{}(nil))
+)
+
+func init() {
+ var i int = 1<<31 - 1
+ intIs64 = (i+1 > 0)
+ if intIs64 {
+ intDT = C.DTInt64
+ } else {
+ intDT = C.DTInt32
+ }
+}
+
+// packDataValue packs the provided Go value into a C.DataValue for
+// shiping into C++ land.
+//
+// For simple types (bool, int, etc) value is converted into a
+// native C++ value. For anything else, including cases when value
+// has a type that has an underlying simple type, the Go value itself
+// is encapsulated into a C++ wrapper so that field access and method
+// calls work.
+//
+// This must be run from the main GUI thread due to the cases where
+// calling wrapGoValue is necessary.
+func packDataValue(value interface{}, dvalue *C.DataValue, engine *Engine, owner valueOwner) {
+ datap := unsafe.Pointer(&dvalue.data)
+ if value == nil {
+ dvalue.dataType = C.DTInvalid
+ return
+ }
+ switch value := value.(type) {
+ case string:
+ dvalue.dataType = C.DTString
+ cstr, cstrlen := unsafeStringData(value)
+ *(**C.char)(datap) = cstr
+ dvalue.len = cstrlen
+ case bool:
+ dvalue.dataType = C.DTBool
+ *(*bool)(datap) = value
+ case int:
+ if value > 1<<31-1 {
+ dvalue.dataType = C.DTInt64
+ *(*int64)(datap) = int64(value)
+ } else {
+ dvalue.dataType = C.DTInt32
+ *(*int32)(datap) = int32(value)
+ }
+ case int64:
+ dvalue.dataType = C.DTInt64
+ *(*int64)(datap) = value
+ case int32:
+ dvalue.dataType = C.DTInt32
+ *(*int32)(datap) = value
+ case uint64:
+ dvalue.dataType = C.DTUint64
+ *(*uint64)(datap) = value
+ case uint32:
+ dvalue.dataType = C.DTUint32
+ *(*uint32)(datap) = value
+ case float64:
+ dvalue.dataType = C.DTFloat64
+ *(*float64)(datap) = value
+ case float32:
+ dvalue.dataType = C.DTFloat32
+ *(*float32)(datap) = value
+ case *Common:
+ dvalue.dataType = C.DTObject
+ *(*unsafe.Pointer)(datap) = value.addr
+ case color.RGBA:
+ dvalue.dataType = C.DTColor
+ *(*uint32)(datap) = uint32(value.A)<<24 | uint32(value.R)<<16 | uint32(value.G)<<8 | uint32(value.B)
+ default:
+ dvalue.dataType = C.DTObject
+ if obj, ok := value.(Object); ok {
+ *(*unsafe.Pointer)(datap) = obj.Common().addr
+ } else {
+ *(*unsafe.Pointer)(datap) = wrapGoValue(engine, value, owner)
+ }
+ }
+}
+
+// TODO Handle byte slices.
+
+// unpackDataValue converts a value shipped by C++ into a native Go value.
+//
+// HEADS UP: This is considered safe to be run out of the main GUI thread.
+// If that changes, fix the call sites.
+func unpackDataValue(dvalue *C.DataValue, engine *Engine) interface{} {
+ datap := unsafe.Pointer(&dvalue.data)
+ switch dvalue.dataType {
+ case C.DTString:
+ s := C.GoStringN(*(**C.char)(datap), dvalue.len)
+ // TODO If we move all unpackDataValue calls to the GUI thread,
+ // can we get rid of this allocation somehow?
+ C.free(unsafe.Pointer(*(**C.char)(datap)))
+ return s
+ case C.DTBool:
+ return *(*bool)(datap)
+ case C.DTInt64:
+ return *(*int64)(datap)
+ case C.DTInt32:
+ return int(*(*int32)(datap))
+ case C.DTUint64:
+ return *(*uint64)(datap)
+ case C.DTUint32:
+ return *(*uint32)(datap)
+ case C.DTUintptr:
+ return *(*uintptr)(datap)
+ case C.DTFloat64:
+ return *(*float64)(datap)
+ case C.DTFloat32:
+ return *(*float32)(datap)
+ case C.DTColor:
+ var c uint32 = *(*uint32)(datap)
+ return color.RGBA{byte(c >> 16), byte(c >> 8), byte(c), byte(c >> 24)}
+ case C.DTGoAddr:
+ // ObjectByName also does this fold conversion, to have access
+ // to the cvalue. Perhaps the fold should be returned.
+ fold := (*(**valueFold)(datap))
+ ensureEngine(engine.addr, unsafe.Pointer(fold))
+ return fold.gvalue
+ case C.DTInvalid:
+ return nil
+ case C.DTObject:
+ // TODO Would be good to preserve identity on the Go side. See initGoType as well.
+ obj := &Common{
+ engine: engine,
+ addr: *(*unsafe.Pointer)(datap),
+ }
+ if len(converters) > 0 {
+ // TODO Embed the type name in DataValue to drop these calls.
+ typeName := obj.TypeName()
+ if typeName == "PlainObject" {
+ typeName = strings.TrimRight(obj.String("plainType"), "&*")
+ if strings.HasPrefix(typeName, "const ") {
+ typeName = typeName[6:]
+ }
+ }
+ if f, ok := converters[typeName]; ok {
+ return f(engine, obj)
+ }
+ }
+ return obj
+ case C.DTValueList, C.DTValueMap:
+ var dvlist []C.DataValue
+ var dvlisth = (*reflect.SliceHeader)(unsafe.Pointer(&dvlist))
+ dvlisth.Data = uintptr(*(*unsafe.Pointer)(datap))
+ dvlisth.Len = int(dvalue.len)
+ dvlisth.Cap = int(dvalue.len)
+ result := make([]interface{}, len(dvlist))
+ for i := range result {
+ result[i] = unpackDataValue(&dvlist[i], engine)
+ }
+ C.free(*(*unsafe.Pointer)(datap))
+ if dvalue.dataType == C.DTValueList {
+ return &List{result}
+ } else {
+ return &Map{result}
+ }
+ }
+ panic(fmt.Sprintf("unsupported data type: %d", dvalue.dataType))
+}
+
+func dataTypeOf(typ reflect.Type) C.DataType {
+ // Compare against the specific types rather than their kind.
+ // Custom types may have methods that must be supported.
+ switch typ {
+ case typeString:
+ return C.DTString
+ case typeBool:
+ return C.DTBool
+ case typeInt:
+ return intDT
+ case typeInt64:
+ return C.DTInt64
+ case typeInt32:
+ return C.DTInt32
+ case typeFloat32:
+ return C.DTFloat32
+ case typeFloat64:
+ return C.DTFloat64
+ case typeIface:
+ return C.DTAny
+ case typeRGBA:
+ return C.DTColor
+ case typeObjSlice:
+ return C.DTListProperty
+ }
+ return C.DTObject
+}
+
+var typeInfoSize = C.size_t(unsafe.Sizeof(C.GoTypeInfo{}))
+var memberInfoSize = C.size_t(unsafe.Sizeof(C.GoMemberInfo{}))
+
+var typeInfoCache = make(map[reflect.Type]*C.GoTypeInfo)
+
+func appendLoweredName(buf []byte, name string) []byte {
+ var last rune
+ var lasti int
+ for i, rune := range name {
+ if !unicode.IsUpper(rune) {
+ if lasti == 0 {
+ last = unicode.ToLower(last)
+ }
+ buf = append(buf, string(last)...)
+ buf = append(buf, name[i:]...)
+ return buf
+ }
+ if i > 0 {
+ buf = append(buf, string(unicode.ToLower(last))...)
+ }
+ lasti, last = i, rune
+ }
+ return append(buf, string(unicode.ToLower(last))...)
+}
+
+func typeInfo(v interface{}) *C.GoTypeInfo {
+ vt := reflect.TypeOf(v)
+ for vt.Kind() == reflect.Ptr {
+ vt = vt.Elem()
+ }
+
+ typeInfo := typeInfoCache[vt]
+ if typeInfo != nil {
+ return typeInfo
+ }
+
+ typeInfo = (*C.GoTypeInfo)(C.malloc(typeInfoSize))
+ typeInfo.typeName = C.CString(vt.Name())
+ typeInfo.metaObject = nilPtr
+ typeInfo.paint = (*C.GoMemberInfo)(nilPtr)
+
+ var setters map[string]int
+ var getters map[string]int
+
+ // TODO Only do that if it's a struct?
+ vtptr := reflect.PtrTo(vt)
+
+ if vt.Kind() != reflect.Struct {
+ panic(fmt.Sprintf("handling of %s (%#v) is incomplete; please report to the developers", vt, v))
+ }
+
+ numField := vt.NumField()
+ numMethod := vtptr.NumMethod()
+ privateFields := 0
+ privateMethods := 0
+
+ // struct { FooBar T; Baz T } => "fooBar\0baz\0"
+ namesLen := 0
+ for i := 0; i < numField; i++ {
+ field := vt.Field(i)
+ if field.PkgPath != "" {
+ privateFields++
+ continue
+ }
+ namesLen += len(field.Name) + 1
+ }
+ for i := 0; i < numMethod; i++ {
+ method := vtptr.Method(i)
+ if method.PkgPath != "" {
+ privateMethods++
+ continue
+ }
+ namesLen += len(method.Name) + 1
+
+ // Track setters and getters.
+ if len(method.Name) > 3 && method.Name[:3] == "Set" {
+ if method.Type.NumIn() == 2 {
+ if setters == nil {
+ setters = make(map[string]int)
+ }
+ setters[method.Name[3:]] = i
+ }
+ } else if method.Type.NumIn() == 1 && method.Type.NumOut() == 1 {
+ if getters == nil {
+ getters = make(map[string]int)
+ }
+ getters[method.Name] = i
+ }
+ }
+ names := make([]byte, 0, namesLen)
+ for i := 0; i < numField; i++ {
+ field := vt.Field(i)
+ if field.PkgPath != "" {
+ continue // not exported
+ }
+ names = appendLoweredName(names, field.Name)
+ names = append(names, 0)
+ }
+ for i := 0; i < numMethod; i++ {
+ method := vtptr.Method(i)
+ if method.PkgPath != "" {
+ continue // not exported
+ }
+ if _, ok := getters[method.Name]; !ok {
+ continue
+ }
+ if _, ok := setters[method.Name]; !ok {
+ delete(getters, method.Name)
+ continue
+ }
+ // This is a getter method
+ names = appendLoweredName(names, method.Name)
+ names = append(names, 0)
+ }
+ for i := 0; i < numMethod; i++ {
+ method := vtptr.Method(i)
+ if method.PkgPath != "" {
+ continue // not exported
+ }
+ if _, ok := getters[method.Name]; ok {
+ continue // getter already handled above
+ }
+ names = appendLoweredName(names, method.Name)
+ names = append(names, 0)
+ }
+ if len(names) != namesLen {
+ panic("pre-allocated buffer size was wrong")
+ }
+ typeInfo.memberNames = C.CString(string(names))
+
+ // Assemble information on members.
+ membersLen := numField - privateFields + numMethod - privateMethods
+ membersi := uintptr(0)
+ mnamesi := uintptr(0)
+ members := uintptr(C.malloc(memberInfoSize * C.size_t(membersLen)))
+ mnames := uintptr(unsafe.Pointer(typeInfo.memberNames))
+ for i := 0; i < numField; i++ {
+ field := vt.Field(i)
+ if field.PkgPath != "" {
+ continue // not exported
+ }
+ memberInfo := (*C.GoMemberInfo)(unsafe.Pointer(members + uintptr(memberInfoSize)*membersi))
+ memberInfo.memberName = (*C.char)(unsafe.Pointer(mnames + mnamesi))
+ memberInfo.memberType = dataTypeOf(field.Type)
+ memberInfo.reflectIndex = C.int(i)
+ memberInfo.reflectGetIndex = -1
+ memberInfo.reflectSetIndex = -1
+ memberInfo.addrOffset = C.int(field.Offset)
+ membersi += 1
+ mnamesi += uintptr(len(field.Name)) + 1
+ if methodIndex, ok := setters[field.Name]; ok {
+ memberInfo.reflectSetIndex = C.int(methodIndex)
+ }
+ }
+ for i := 0; i < numMethod; i++ {
+ method := vtptr.Method(i)
+ if method.PkgPath != "" {
+ continue // not exported
+ }
+ if _, ok := getters[method.Name]; !ok {
+ continue // not a getter
+ }
+ memberInfo := (*C.GoMemberInfo)(unsafe.Pointer(members + uintptr(memberInfoSize)*membersi))
+ memberInfo.memberName = (*C.char)(unsafe.Pointer(mnames + mnamesi))
+ memberInfo.memberType = dataTypeOf(method.Type.Out(0))
+ memberInfo.reflectIndex = -1
+ memberInfo.reflectGetIndex = C.int(getters[method.Name])
+ memberInfo.reflectSetIndex = C.int(setters[method.Name])
+ memberInfo.addrOffset = 0
+ membersi += 1
+ mnamesi += uintptr(len(method.Name)) + 1
+ }
+ for i := 0; i < numMethod; i++ {
+ method := vtptr.Method(i)
+ if method.PkgPath != "" {
+ continue // not exported
+ }
+ if _, ok := getters[method.Name]; ok {
+ continue // getter already handled above
+ }
+ memberInfo := (*C.GoMemberInfo)(unsafe.Pointer(members + uintptr(memberInfoSize)*membersi))
+ memberInfo.memberName = (*C.char)(unsafe.Pointer(mnames + mnamesi))
+ memberInfo.memberType = C.DTMethod
+ memberInfo.reflectIndex = C.int(i)
+ memberInfo.reflectGetIndex = -1
+ memberInfo.reflectSetIndex = -1
+ memberInfo.addrOffset = 0
+ signature, result := methodQtSignature(method)
+ // TODO The signature data might be embedded in the same array as the member names.
+ memberInfo.methodSignature = C.CString(signature)
+ memberInfo.resultSignature = C.CString(result)
+ // TODO Sort out methods with a variable number of arguments.
+ // It's called while bound, so drop the receiver.
+ memberInfo.numIn = C.int(method.Type.NumIn() - 1)
+ memberInfo.numOut = C.int(method.Type.NumOut())
+ membersi += 1
+ mnamesi += uintptr(len(method.Name)) + 1
+
+ if method.Name == "Paint" && memberInfo.numIn == 1 && memberInfo.numOut == 0 && method.Type.In(1) == typePainter {
+ typeInfo.paint = memberInfo
+ }
+ }
+ typeInfo.members = (*C.GoMemberInfo)(unsafe.Pointer(members))
+ typeInfo.membersLen = C.int(membersLen)
+
+ typeInfo.fields = typeInfo.members
+ typeInfo.fieldsLen = C.int(numField - privateFields + len(getters))
+ typeInfo.methods = (*C.GoMemberInfo)(unsafe.Pointer(members + uintptr(memberInfoSize)*uintptr(typeInfo.fieldsLen)))
+ typeInfo.methodsLen = C.int(numMethod - privateMethods - len(getters))
+
+ if int(membersi) != membersLen {
+ panic("used more space than allocated for member names")
+ }
+ if int(mnamesi) != namesLen {
+ panic("allocated buffer doesn't match used space")
+ }
+ if typeInfo.fieldsLen+typeInfo.methodsLen != typeInfo.membersLen {
+ panic("lengths are inconsistent")
+ }
+
+ typeInfoCache[vt] = typeInfo
+ return typeInfo
+}
+
+func methodQtSignature(method reflect.Method) (signature, result string) {
+ var buf bytes.Buffer
+ for i, rune := range method.Name {
+ if i == 0 {
+ buf.WriteRune(unicode.ToLower(rune))
+ } else {
+ buf.WriteString(method.Name[i:])
+ break
+ }
+ }
+ buf.WriteByte('(')
+ n := method.Type.NumIn()
+ for i := 1; i < n; i++ {
+ if i > 1 {
+ buf.WriteByte(',')
+ }
+ buf.WriteString("QVariant")
+ }
+ buf.WriteByte(')')
+ signature = buf.String()
+
+ switch method.Type.NumOut() {
+ case 0:
+ // keep it as ""
+ case 1:
+ result = "QVariant"
+ default:
+ result = "QVariantList"
+ }
+ return
+}
+
+func hashable(value interface{}) (hashable bool) {
+ defer func() { recover() }()
+ return value == value
+}
+
+// unsafeString returns a Go string backed by C data.
+//
+// If the C data is deallocated or moved, the string will be
+// invalid and will crash the program if used. As such, the
+// resulting string must only be used inside the implementation
+// of the qml package and while the life time of the C data
+// is guaranteed.
+func unsafeString(data *C.char, size C.int) string {
+ var s string
+ sh := (*reflect.StringHeader)(unsafe.Pointer(&s))
+ sh.Data = uintptr(unsafe.Pointer(data))
+ sh.Len = int(size)
+ return s
+}
+
+// unsafeStringData returns a C string backed by Go data. The C
+// string is NOT null-terminated, so its length must be taken
+// into account.
+//
+// If the s Go string is garbage collected, the returned C data
+// will be invalid and will crash the program if used. As such,
+// the resulting data must only be used inside the implementation
+// of the qml package and while the life time of the Go string
+// is guaranteed.
+func unsafeStringData(s string) (*C.char, C.int) {
+ return *(**C.char)(unsafe.Pointer(&s)), C.int(len(s))
+}
+
+// unsafeBytesData returns a C string backed by Go data. The C
+// string is NOT null-terminated, so its length must be taken
+// into account.
+//
+// If the array backing the b Go slice is garbage collected, the
+// returned C data will be invalid and will crash the program if
+// used. As such, the resulting data must only be used inside the
+// implementation of the qml package and while the life time of
+// the Go array is guaranteed.
+func unsafeBytesData(b []byte) (*C.char, C.int) {
+ return *(**C.char)(unsafe.Pointer(&b)), C.int(len(b))
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/doc.go b/Godeps/_workspace/src/github.com/obscuren/qml/doc.go
new file mode 100644
index 000000000..94b2404a9
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/doc.go
@@ -0,0 +1,199 @@
+// Package qml offers graphical QML application support for the Go language.
+//
+// Attention
+//
+// This package is in an alpha stage, and still in heavy development. APIs may
+// change, and things may break.
+//
+// At this time contributors and developers that are interested in tracking the
+// development closely are encouraged to use it. If you'd prefer a more stable
+// release, please hold on a bit and subscribe to the mailing list for news. It's
+// in a pretty good state, so it shall not take too long.
+//
+// See http://github.com/go-qml/qml for details.
+//
+//
+// Introduction
+//
+// The qml package enables Go programs to display and manipulate graphical content
+// using Qt's QML framework. QML uses a declarative language to express structure
+// and style, and supports JavaScript for in-place manipulation of the described
+// content. When using the Go qml package, such QML content can also interact with
+// Go values, making use of its exported fields and methods, and even explicitly
+// creating new instances of registered Go types.
+//
+// A simple Go application that integrates with QML may perform the following steps
+// for offering a graphical interface:
+//
+// * Call qml.Run from function main providing a function with the logic below
+// * Create an engine for loading and running QML content (see NewEngine)
+// * Make Go values and types available to QML (see Context.SetVar and RegisterType)
+// * Load QML content (see Engine.LoadString and Engine.LoadFile)
+// * Create a new window for the content (see Component.CreateWindow)
+// * Show the window and wait for it to be closed (see Window.Show and Window.Wait)
+//
+// Some of these topics are covered below, and may also be observed in practice
+// in the following examples:
+//
+// https://github.com/go-qml/qml/tree/v1/examples
+//
+//
+// Simple example
+//
+// The following logic demonstrates loading a QML file into a window:
+//
+// func main() {
+// err := qml.Run(run)
+// ...
+// }
+//
+// func run() error {
+// engine := qml.NewEngine()
+// component, err := engine.LoadFile("file.qml")
+// if err != nil {
+// return err
+// }
+// win := component.CreateWindow(nil)
+// win.Show()
+// win.Wait()
+// return nil
+// }
+//
+// Handling QML objects in Go
+//
+// Any QML object may be manipulated by Go via the Object interface. That
+// interface is implemented both by dynamic QML values obtained from a running
+// engine, and by Go types in the qml package that represent QML values, such as
+// Window, Context, and Engine.
+//
+// For example, the following logic creates a window and prints its width
+// whenever it's made visible:
+//
+// win := component.CreateWindow(nil)
+// win.On("visibleChanged", func(visible bool) {
+// if (visible) {
+// fmt.Println("Width:", win.Int("width"))
+// }
+// })
+//
+// Information about the methods, properties, and signals that are available for QML
+// objects may be obtained in the Qt documentation. As a reference, the "visibleChanged"
+// signal and the "width" property used in the example above are described at:
+//
+// http://qt-project.org/doc/qt-5.0/qtgui/qwindow.html
+//
+// When in doubt about what type is being manipulated, the Object.TypeName method
+// provides the type name of the underlying value.
+//
+//
+// Publishing Go values to QML
+//
+// The simplest way of making a Go value available to QML code is setting it
+// as a variable of the engine's root context, as in:
+//
+// context := engine.Context()
+// context.SetVar("person", &Person{Name: "Ale"})
+//
+// This logic would enable the following QML code to successfully run:
+//
+// import QtQuick 2.0
+// Item {
+// Component.onCompleted: console.log("Name is", person.name)
+// }
+//
+//
+// Publishing Go types to QML
+//
+// While registering an individual Go value as described above is a quick way to get
+// started, it is also fairly limited. For more flexibility, a Go type may be
+// registered so that QML code can natively create new instances in an arbitrary
+// position of the structure. This may be achieved via the RegisterType function, as
+// the following example demonstrates:
+//
+// qml.RegisterTypes("GoExtensions", 1, 0, []qml.TypeSpec{{
+// Init: func(p *Person, obj qml.Object) { p.Name = "<none>" },
+// }})
+//
+// With this logic in place, QML code can create new instances of Person by itself:
+//
+// import QtQuick 2.0
+// import GoExtensions 1.0
+// Item{
+// Person {
+// id: person
+// name: "Ale"
+// }
+// Component.onCompleted: console.log("Name is", person.name)
+// }
+//
+//
+// Lowercasing of names
+//
+// Independently from the mechanism used to publish a Go value to QML code, its methods
+// and fields are available to QML logic as methods and properties of the
+// respective QML object representing it. As required by QML, though, the Go
+// method and field names are lowercased according to the following scheme when
+// being accesed from QML:
+//
+// value.Name => value.name
+// value.UPPERName => value.upperName
+// value.UPPER => value.upper
+//
+//
+// Setters and getters
+//
+// While QML code can directly read and write exported fields of Go values, as described
+// above, a Go type can also intercept writes to specific fields by declaring a setter
+// method according to common Go conventions. This is often useful for updating the
+// internal state or the visible content of a Go-defined type.
+//
+// For example:
+//
+// type Person struct {
+// Name string
+// }
+//
+// func (p *Person) SetName(name string) {
+// fmt.Println("Old name is", p.Name)
+// p.Name = name
+// fmt.Println("New name is", p.Name)
+// }
+//
+// In the example above, whenever QML code attempts to update the Person.Name field
+// via any means (direct assignment, object declarations, etc) the SetName method
+// is invoked with the provided value instead.
+//
+// A setter method may also be used in conjunction with a getter method rather
+// than a real type field. A method is only considered a getter in the presence
+// of the respective setter, and according to common Go conventions it must not
+// have the Get prefix.
+//
+// Inside QML logic, the getter and setter pair is seen as a single object property.
+//
+//
+// Painting
+//
+// Custom types implemented in Go may have displayable content by defining
+// a Paint method such as:
+//
+// func (p *Person) Paint(painter *qml.Painter) {
+// // ... OpenGL calls with the gopkg.in/qml.v1/gl/<VERSION> package ...
+// }
+//
+// A simple example is available at:
+//
+// https://github.com/go-qml/qml/tree/v1/examples/painting
+//
+//
+// Packing resources into the Go qml binary
+//
+// Resource files (qml code, images, etc) may be packed into the Go qml application
+// binary to simplify its handling and distribution. This is done with the genqrc tool:
+//
+// http://gopkg.in/qml.v1/cmd/genqrc#usage
+//
+// The following blog post provides more details:
+//
+// http://blog.labix.org/2014/09/26/packing-resources-into-go-qml-binaries
+//
+package qml
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/.gitignore b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/.gitignore
new file mode 100644
index 000000000..309fbb35d
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/.gitignore
@@ -0,0 +1,5 @@
+basiclayouts/basiclayouts
+gallery/gallery
+splitview/splitview
+tableview/tableview
+touch/touch
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/README.md b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/README.md
new file mode 100644
index 000000000..201846d89
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/README.md
@@ -0,0 +1,8 @@
+These examples were ported from [qtquickcontrols](git@gitorious.org:qt/qtquickcontrols.git).
+
+Only the basic ones were ported, in order to demonstrate how easy it is to create a full-fledged UI with Go and QML.
+
+There were a few more, but they that had native modules and those were omitted due to laziness.
+
+In order to run them you might need some extra Qt5 plugins. On Ubuntu those can be installed using this command:
+ sudo apt-get install qtdeclarative5-controls-plugin qtdeclarative5-xmllistmodel-plugin
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/basiclayouts/basiclayouts.go b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/basiclayouts/basiclayouts.go
new file mode 100644
index 000000000..a16b6b1ab
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/basiclayouts/basiclayouts.go
@@ -0,0 +1,29 @@
+package main
+
+import (
+ "fmt"
+ "gopkg.in/qml.v1"
+ "os"
+)
+
+func main() {
+ if err := qml.Run(run); err != nil {
+ fmt.Fprintf(os.Stderr, "error: %v\n", err)
+ os.Exit(1)
+ }
+}
+
+func run() error {
+ engine := qml.NewEngine()
+
+ controls, err := engine.LoadFile("main.qml")
+ if err != nil {
+ return err
+ }
+
+ window := controls.CreateWindow(nil)
+
+ window.Show()
+ window.Wait()
+ return nil
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/basiclayouts/main.qml b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/basiclayouts/main.qml
new file mode 100644
index 000000000..ecbbb75a1
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/basiclayouts/main.qml
@@ -0,0 +1,116 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the Qt Quick Controls module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:BSD$
+** You may use this file under the terms of the BSD license as follows:
+**
+** "Redistribution and use in source and binary forms, with or without
+** modification, are permitted provided that the following conditions are
+** met:
+** * Redistributions of source code must retain the above copyright
+** notice, this list of conditions and the following disclaimer.
+** * Redistributions in binary form must reproduce the above copyright
+** notice, this list of conditions and the following disclaimer in
+** the documentation and/or other materials provided with the
+** distribution.
+** * Neither the name of Digia Plc and its Subsidiary(-ies) nor the names
+** of its contributors may be used to endorse or promote products derived
+** from this software without specific prior written permission.
+**
+**
+** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+
+
+
+
+import QtQuick 2.2
+import QtQuick.Controls 1.1
+import QtQuick.Layouts 1.0
+
+ApplicationWindow {
+ visible: true
+ title: "Basic layouts"
+ property int margin: 11
+ width: mainLayout.implicitWidth + 2 * margin
+ height: mainLayout.implicitHeight + 2 * margin
+ minimumWidth: mainLayout.Layout.minimumWidth + 2 * margin
+ minimumHeight: mainLayout.Layout.minimumHeight + 2 * margin
+
+ ColumnLayout {
+ id: mainLayout
+ anchors.fill: parent
+ anchors.margins: margin
+ GroupBox {
+ id: rowBox
+ title: "Row layout"
+ Layout.fillWidth: true
+
+ RowLayout {
+ id: rowLayout
+ anchors.fill: parent
+ TextField {
+ placeholderText: "This wants to grow horizontally"
+ Layout.fillWidth: true
+ }
+ Button {
+ text: "Button"
+ }
+ }
+ }
+
+ GroupBox {
+ id: gridBox
+ title: "Grid layout"
+ Layout.fillWidth: true
+
+ GridLayout {
+ id: gridLayout
+ rows: 3
+ flow: GridLayout.TopToBottom
+ anchors.fill: parent
+
+ Label { text: "Line 1" }
+ Label { text: "Line 2" }
+ Label { text: "Line 3" }
+
+ TextField { }
+ TextField { }
+ TextField { }
+
+ TextArea {
+ text: "This widget spans over three rows in the GridLayout.\n"
+ + "All items in the GridLayout are implicitly positioned from top to bottom."
+ Layout.rowSpan: 3
+ Layout.fillHeight: true
+ Layout.fillWidth: true
+ }
+ }
+ }
+ TextArea {
+ id: t3
+ text: "This fills the whole cell"
+ Layout.minimumHeight: 30
+ Layout.fillHeight: true
+ Layout.fillWidth: true
+ }
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/content/AboutDialog.qml b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/content/AboutDialog.qml
new file mode 100644
index 000000000..aec7b6043
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/content/AboutDialog.qml
@@ -0,0 +1,48 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the Qt Quick Controls module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:BSD$
+** You may use this file under the terms of the BSD license as follows:
+**
+** "Redistribution and use in source and binary forms, with or without
+** modification, are permitted provided that the following conditions are
+** met:
+** * Redistributions of source code must retain the above copyright
+** notice, this list of conditions and the following disclaimer.
+** * Redistributions in binary form must reproduce the above copyright
+** notice, this list of conditions and the following disclaimer in
+** the documentation and/or other materials provided with the
+** distribution.
+** * Neither the name of Digia Plc and its Subsidiary(-ies) nor the names
+** of its contributors may be used to endorse or promote products derived
+** from this software without specific prior written permission.
+**
+**
+** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+import QtQuick 2.2
+import QtQuick.Dialogs 1.1
+
+MessageDialog {
+ icon: StandardIcon.Information
+ text: "QtQuick.Controls gallery example"
+ detailedText: "This example demonstrates most of the available Qt Quick Controls."
+ title: "About Gallery"
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/content/ChildWindow.qml b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/content/ChildWindow.qml
new file mode 100644
index 000000000..08925f632
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/content/ChildWindow.qml
@@ -0,0 +1,122 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the Qt Quick Controls module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:BSD$
+** You may use this file under the terms of the BSD license as follows:
+**
+** "Redistribution and use in source and binary forms, with or without
+** modification, are permitted provided that the following conditions are
+** met:
+** * Redistributions of source code must retain the above copyright
+** notice, this list of conditions and the following disclaimer.
+** * Redistributions in binary form must reproduce the above copyright
+** notice, this list of conditions and the following disclaimer in
+** the documentation and/or other materials provided with the
+** distribution.
+** * Neither the name of Digia Plc and its Subsidiary(-ies) nor the names
+** of its contributors may be used to endorse or promote products derived
+** from this software without specific prior written permission.
+**
+**
+** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+
+
+
+
+import QtQuick 2.2
+import QtQuick.Window 2.1
+import QtQuick.Controls 1.1
+
+Window {
+ id: window1
+
+ width: 400
+ height: 400
+
+ title: "child window"
+ flags: Qt.Dialog
+
+ Rectangle {
+ color: syspal.window
+ anchors.fill: parent
+
+ Label {
+ id: dimensionsText
+ anchors.horizontalCenter: parent.horizontalCenter
+ anchors.top: parent.top
+ width: parent.width
+ horizontalAlignment: Text.AlignHCenter
+ }
+
+ Label {
+ id: availableDimensionsText
+ anchors.horizontalCenter: parent.horizontalCenter
+ anchors.top: dimensionsText.bottom
+ width: parent.width
+ horizontalAlignment: Text.AlignHCenter
+ }
+
+ Label {
+ id: closeText
+ anchors.horizontalCenter: parent.horizontalCenter
+ anchors.top: availableDimensionsText.bottom
+ text: "This is a new Window, press the\nbutton below to close it again."
+ }
+ Button {
+ anchors.horizontalCenter: closeText.horizontalCenter
+ anchors.top: closeText.bottom
+ id: closeWindowButton
+ text:"Close"
+ width: 98
+ tooltip:"Press me, to close this window again"
+ onClicked: window1.visible = false
+ }
+ Button {
+ anchors.horizontalCenter: closeText.horizontalCenter
+ anchors.top: closeWindowButton.bottom
+ id: maximizeWindowButton
+ text:"Maximize"
+ width: 98
+ tooltip:"Press me, to maximize this window again"
+ onClicked: window1.visibility = Window.Maximized;
+ }
+ Button {
+ anchors.horizontalCenter: closeText.horizontalCenter
+ anchors.top: maximizeWindowButton.bottom
+ id: normalizeWindowButton
+ text:"Normalize"
+ width: 98
+ tooltip:"Press me, to normalize this window again"
+ onClicked: window1.visibility = Window.Windowed;
+ }
+ Button {
+ anchors.horizontalCenter: closeText.horizontalCenter
+ anchors.top: normalizeWindowButton.bottom
+ id: minimizeWindowButton
+ text:"Minimize"
+ width: 98
+ tooltip:"Press me, to minimize this window again"
+ onClicked: window1.visibility = Window.Minimized;
+ }
+ }
+}
+
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/content/Controls.qml b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/content/Controls.qml
new file mode 100644
index 000000000..b7e461881
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/content/Controls.qml
@@ -0,0 +1,229 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the Qt Quick Controls module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:BSD$
+** You may use this file under the terms of the BSD license as follows:
+**
+** "Redistribution and use in source and binary forms, with or without
+** modification, are permitted provided that the following conditions are
+** met:
+** * Redistributions of source code must retain the above copyright
+** notice, this list of conditions and the following disclaimer.
+** * Redistributions in binary form must reproduce the above copyright
+** notice, this list of conditions and the following disclaimer in
+** the documentation and/or other materials provided with the
+** distribution.
+** * Neither the name of Digia Plc and its Subsidiary(-ies) nor the names
+** of its contributors may be used to endorse or promote products derived
+** from this software without specific prior written permission.
+**
+**
+** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+
+
+
+
+import QtQuick 2.2
+import QtQuick.Controls 1.1
+import QtQuick.Layouts 1.1
+import QtQuick.Controls.Styles 1.1
+
+Item {
+ id: flickable
+ anchors.fill: parent
+ enabled: enabledCheck.checked
+
+ property int tabPosition: tabPositionGroup.current === r2 ? Qt.BottomEdge : Qt.TopEdge
+
+ RowLayout {
+ id: contentRow
+ anchors.fill:parent
+ anchors.margins: 8
+ spacing: 16
+ ColumnLayout {
+ id: firstColumn
+ Layout.minimumWidth: implicitWidth
+ Layout.fillWidth: false
+ RowLayout {
+ id: buttonrow
+ Button {
+ id: button1
+ text: "Button 1"
+ tooltip:"This is an interesting tool tip"
+ Layout.fillWidth: true
+ }
+ Button {
+ id:button2
+ text:"Button 2"
+ Layout.fillWidth: true
+ menu: Menu {
+ MenuItem { text: "This Button" }
+ MenuItem { text: "Happens To Have" }
+ MenuItem { text: "A Menu Assigned" }
+ }
+ }
+ }
+ ComboBox {
+ id: combo
+ model: choices
+ currentIndex: 2
+ Layout.fillWidth: true
+ }
+ ComboBox {
+ model: Qt.fontFamilies()
+ Layout.fillWidth: true
+ currentIndex: 47
+ }
+ ComboBox {
+ id: editableCombo
+ editable: true
+ model: choices
+ Layout.fillWidth: true
+ currentIndex: 2
+ onAccepted: {
+ if (editableCombo.find(currentText) === -1) {
+ choices.append({text: editText})
+ currentIndex = editableCombo.find(editText)
+ }
+ }
+ }
+ RowLayout {
+ SpinBox {
+ id: t1
+ Layout.fillWidth: true
+ minimumValue: -50
+ value: -20
+ }
+ SpinBox {
+ id: t2
+ Layout.fillWidth: true
+ }
+ }
+ TextField {
+ id: t3
+ placeholderText: "This is a placeholder for a TextField"
+ Layout.fillWidth: true
+ }
+ ProgressBar {
+ // normalize value [0.0 .. 1.0]
+ value: (slider.value - slider.minimumValue) / (slider.maximumValue - slider.minimumValue)
+ Layout.fillWidth: true
+ }
+ ProgressBar {
+ indeterminate: true
+ Layout.fillWidth: true
+ }
+ Slider {
+ id: slider
+ value: 0.5
+ Layout.fillWidth: true
+ tickmarksEnabled: tickmarkCheck.checked
+ stepSize: tickmarksEnabled ? 0.1 : 0
+ }
+ MouseArea {
+ id: busyCheck
+ Layout.fillWidth: true
+ Layout.fillHeight: true
+ hoverEnabled:true
+ Layout.preferredHeight: busyIndicator.height
+ BusyIndicator {
+ id: busyIndicator
+ running: busyCheck.containsMouse
+ anchors.horizontalCenter: parent.horizontalCenter
+ }
+ }
+ }
+ ColumnLayout {
+ id: rightcol
+ Layout.fillWidth: true
+ anchors {
+ top: parent.top
+ bottom: parent.bottom
+ }
+
+ GroupBox {
+ id: group1
+ title: "CheckBox"
+ Layout.fillWidth: true
+ RowLayout {
+ Layout.fillWidth: true
+ CheckBox {
+ id: frameCheckbox
+ text: "Text frame"
+ checked: true
+ Layout.minimumWidth: 100
+ }
+ CheckBox {
+ id: tickmarkCheck
+ text: "Tickmarks"
+ checked: false
+ Layout.minimumWidth: 100
+ }
+ CheckBox {
+ id: wrapCheck
+ text: "Word wrap"
+ checked: true
+ Layout.minimumWidth: 100
+ }
+ }
+ }
+ GroupBox {
+ id: group2
+ title:"Tab Position"
+ Layout.fillWidth: true
+ RowLayout {
+ ExclusiveGroup { id: tabPositionGroup }
+ RadioButton {
+ id: r1
+ text: "Top"
+ checked: true
+ exclusiveGroup: tabPositionGroup
+ Layout.minimumWidth: 100
+ }
+ RadioButton {
+ id: r2
+ text: "Bottom"
+ exclusiveGroup: tabPositionGroup
+ Layout.minimumWidth: 100
+ }
+ }
+ }
+
+ TextArea {
+ id: area
+ frameVisible: frameCheckbox.checked
+ text: loremIpsum + loremIpsum
+ textFormat: Qt.RichText
+ wrapMode: wrapCheck.checked ? TextEdit.WordWrap : TextEdit.NoWrap
+ Layout.fillWidth: true
+ Layout.fillHeight: true
+ MouseArea {
+ id: contextMenu
+ parent: area.viewport
+ anchors.fill: parent
+ acceptedButtons: Qt.RightButton
+ onPressed: editmenu.popup()
+ }
+ }
+ }
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/content/ImageViewer.qml b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/content/ImageViewer.qml
new file mode 100644
index 000000000..01f24ab33
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/content/ImageViewer.qml
@@ -0,0 +1,58 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the Qt Quick Controls module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:BSD$
+** You may use this file under the terms of the BSD license as follows:
+**
+** "Redistribution and use in source and binary forms, with or without
+** modification, are permitted provided that the following conditions are
+** met:
+** * Redistributions of source code must retain the above copyright
+** notice, this list of conditions and the following disclaimer.
+** * Redistributions in binary form must reproduce the above copyright
+** notice, this list of conditions and the following disclaimer in
+** the documentation and/or other materials provided with the
+** distribution.
+** * Neither the name of Digia Plc and its Subsidiary(-ies) nor the names
+** of its contributors may be used to endorse or promote products derived
+** from this software without specific prior written permission.
+**
+**
+** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+import QtQuick 2.2
+import QtQuick.Window 2.1
+
+Window {
+ id: imageViewer
+ minimumWidth: viewerImage.width
+ minimumHeight: viewerImage.height
+ function open(source) {
+ viewerImage.source = source
+ width = viewerImage.implicitWidth + 20
+ height = viewerImage.implicitHeight + 20
+ title = source
+ visible = true
+ }
+ Image {
+ id: viewerImage
+ anchors.centerIn: parent
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/content/Layouts.qml b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/content/Layouts.qml
new file mode 100644
index 000000000..0cb234c39
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/content/Layouts.qml
@@ -0,0 +1,107 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the Qt Quick Controls module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:BSD$
+** You may use this file under the terms of the BSD license as follows:
+**
+** "Redistribution and use in source and binary forms, with or without
+** modification, are permitted provided that the following conditions are
+** met:
+** * Redistributions of source code must retain the above copyright
+** notice, this list of conditions and the following disclaimer.
+** * Redistributions in binary form must reproduce the above copyright
+** notice, this list of conditions and the following disclaimer in
+** the documentation and/or other materials provided with the
+** distribution.
+** * Neither the name of Digia Plc and its Subsidiary(-ies) nor the names
+** of its contributors may be used to endorse or promote products derived
+** from this software without specific prior written permission.
+**
+**
+** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+import QtQuick 2.2
+import QtQuick.Controls 1.1
+import QtQuick.Layouts 1.0
+
+Item {
+ id:root
+ anchors.fill: parent
+ anchors.margins: 8
+
+ ColumnLayout {
+ id: mainLayout
+ anchors.fill: parent
+ spacing: 4
+ GroupBox {
+ id: rowBox
+ title: "Row layout"
+ Layout.fillWidth: true
+ RowLayout {
+ id: rowLayout
+ anchors.fill: parent
+ TextField {
+ placeholderText: "This wants to grow horizontally"
+ Layout.fillWidth: true
+ }
+ Button {
+ text: "Button"
+ }
+ }
+ }
+
+ GroupBox {
+ id: gridBox
+ title: "Grid layout"
+ Layout.fillWidth: true
+
+ GridLayout {
+ id: gridLayout
+ anchors.fill: parent
+ rows: 3
+ flow: GridLayout.TopToBottom
+
+ Label { text: "Line 1" }
+ Label { text: "Line 2" }
+ Label { text: "Line 3" }
+
+ TextField { }
+ TextField { }
+ TextField { }
+
+ TextArea {
+ text: "This widget spans over three rows in the GridLayout.\n"
+ + "All items in the GridLayout are implicitly positioned from top to bottom."
+ Layout.rowSpan: 3
+ Layout.fillHeight: true
+ Layout.fillWidth: true
+ }
+ }
+ }
+ TextArea {
+ id: t3
+ text: "This fills the whole cell"
+ Layout.minimumHeight: 30
+ Layout.fillHeight: true
+ Layout.fillWidth: true
+ }
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/content/ModelView.qml b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/content/ModelView.qml
new file mode 100644
index 000000000..be334458d
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/content/ModelView.qml
@@ -0,0 +1,103 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the Qt Quick Controls module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:BSD$
+** You may use this file under the terms of the BSD license as follows:
+**
+** "Redistribution and use in source and binary forms, with or without
+** modification, are permitted provided that the following conditions are
+** met:
+** * Redistributions of source code must retain the above copyright
+** notice, this list of conditions and the following disclaimer.
+** * Redistributions in binary form must reproduce the above copyright
+** notice, this list of conditions and the following disclaimer in
+** the documentation and/or other materials provided with the
+** distribution.
+** * Neither the name of Digia Plc and its Subsidiary(-ies) nor the names
+** of its contributors may be used to endorse or promote products derived
+** from this software without specific prior written permission.
+**
+**
+** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+
+
+
+
+import QtQuick 2.2
+import QtQuick.Controls 1.1
+//import QtQuick.XmlListModel 2.1
+
+Item {
+ id: root
+ width: 600
+ height: 300
+ anchors.fill: parent
+ anchors.margins: Qt.platform.os === "osx" ? 12 : 6
+
+// XmlListModel {
+// id: flickerModel
+// source: "http://api.flickr.com/services/feeds/photos_public.gne?format=rss2&tags=" + "Cat"
+// query: "/rss/channel/item"
+// namespaceDeclarations: "declare namespace media=\"http://search.yahoo.com/mrss/\";"
+// XmlRole { name: "title"; query: "title/string()" }
+// XmlRole { name: "imagesource"; query: "media:thumbnail/@url/string()" }
+// XmlRole { name: "credit"; query: "media:credit/string()" }
+// }
+
+ ListModel {
+ id: dummyModel
+ Component.onCompleted: {
+ for (var i = 0 ; i < 100 ; ++i) {
+ append({"index": i, "title": "A title " + i, "imagesource" :"http://someurl.com", "credit" : "N/A"})
+ }
+ }
+ }
+
+ TableView{
+ model: dummyModel
+ anchors.fill: parent
+
+ TableViewColumn {
+ role: "index"
+ title: "#"
+ width: 36
+ resizable: false
+ movable: false
+ }
+ TableViewColumn {
+ role: "title"
+ title: "Title"
+ width: 120
+ }
+ TableViewColumn {
+ role: "credit"
+ title: "Credit"
+ width: 120
+ }
+ TableViewColumn {
+ role: "imagesource"
+ title: "Image source"
+ width: 200
+ visible: true
+ }
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/content/Styles.qml b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/content/Styles.qml
new file mode 100644
index 000000000..ed237d82b
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/content/Styles.qml
@@ -0,0 +1,387 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the Qt Quick Controls module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:BSD$
+** You may use this file under the terms of the BSD license as follows:
+**
+** "Redistribution and use in source and binary forms, with or without
+** modification, are permitted provided that the following conditions are
+** met:
+** * Redistributions of source code must retain the above copyright
+** notice, this list of conditions and the following disclaimer.
+** * Redistributions in binary form must reproduce the above copyright
+** notice, this list of conditions and the following disclaimer in
+** the documentation and/or other materials provided with the
+** distribution.
+** * Neither the name of Digia Plc and its Subsidiary(-ies) nor the names
+** of its contributors may be used to endorse or promote products derived
+** from this software without specific prior written permission.
+**
+**
+** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+
+
+
+
+import QtQuick 2.2
+import QtQuick.Controls 1.1
+import QtQuick.Controls.Styles 1.1
+import QtQuick.Particles 2.0
+import QtQuick.Layouts 1.0
+
+Item {
+ id: root
+ width: 300
+ height: 200
+
+ property int columnWidth: 120
+ GridLayout {
+ rowSpacing: 12
+ columnSpacing: 30
+ anchors.top: parent.top
+ anchors.horizontalCenter: parent.horizontalCenter
+ anchors.margins: 30
+
+ Button {
+ text: "Push me"
+ style: ButtonStyle { }
+ implicitWidth: columnWidth
+ }
+ Button {
+ text: "Push me"
+ style: ButtonStyle {
+ background: BorderImage {
+ source: control.pressed ? "../images/button-pressed.png" : "../images/button.png"
+ border.left: 4 ; border.right: 4 ; border.top: 4 ; border.bottom: 4
+ }
+ }
+ implicitWidth: columnWidth
+ }
+ Button {
+ text: "Push me"
+ style: buttonStyle
+ implicitWidth: columnWidth
+ }
+
+ TextField {
+ Layout.row: 1
+ style: TextFieldStyle { }
+ implicitWidth: columnWidth
+ }
+ TextField {
+ style: TextFieldStyle {
+ background: BorderImage {
+ source: "../images/textfield.png"
+ border.left: 4 ; border.right: 4 ; border.top: 4 ; border.bottom: 4
+ }
+ }
+ implicitWidth: columnWidth
+ }
+ TextField {
+ style: textfieldStyle
+ implicitWidth: columnWidth
+ }
+
+ Slider {
+ id: slider1
+ Layout.row: 2
+ value: 0.5
+ implicitWidth: columnWidth
+ style: SliderStyle { }
+ }
+ Slider {
+ id: slider2
+ value: 0.5
+ implicitWidth: columnWidth
+ style: SliderStyle {
+ groove: BorderImage {
+ height: 6
+ border.top: 1
+ border.bottom: 1
+ source: "../images/progress-background.png"
+ border.left: 6
+ border.right: 6
+ BorderImage {
+ anchors.verticalCenter: parent.verticalCenter
+ source: "../images/progress-fill.png"
+ border.left: 5 ; border.top: 1
+ border.right: 5 ; border.bottom: 1
+ width: styleData.handlePosition
+ height: parent.height
+ }
+ }
+ handle: Item {
+ width: 13
+ height: 13
+ Image {
+ anchors.centerIn: parent
+ source: "../images/slider-handle.png"
+ }
+ }
+ }
+ }
+ Slider {
+ id: slider3
+ value: 0.5
+ implicitWidth: columnWidth
+ style: sliderStyle
+ }
+
+ ProgressBar {
+ Layout.row: 3
+ value: slider1.value
+ implicitWidth: columnWidth
+ style: ProgressBarStyle{ }
+ }
+ ProgressBar {
+ value: slider2.value
+ implicitWidth: columnWidth
+ style: progressBarStyle
+ }
+ ProgressBar {
+ value: slider3.value
+ implicitWidth: columnWidth
+ style: progressBarStyle2
+ }
+
+ CheckBox {
+ text: "CheckBox"
+ style: CheckBoxStyle{}
+ Layout.row: 4
+ implicitWidth: columnWidth
+ }
+ RadioButton {
+ style: RadioButtonStyle{}
+ text: "RadioButton"
+ implicitWidth: columnWidth
+ }
+
+ ComboBox {
+ model: ["Paris", "Oslo", "New York"]
+ style: ComboBoxStyle{}
+ implicitWidth: columnWidth
+ }
+
+ TabView {
+ Layout.row: 5
+ Layout.columnSpan: 3
+ Layout.fillWidth: true
+ implicitHeight: 30
+ Tab { title: "One" ; Item {}}
+ Tab { title: "Two" ; Item {}}
+ Tab { title: "Three" ; Item {}}
+ Tab { title: "Four" ; Item {}}
+ style: TabViewStyle {}
+ }
+
+ TabView {
+ Layout.row: 6
+ Layout.columnSpan: 3
+ Layout.fillWidth: true
+ implicitHeight: 30
+ Tab { title: "One" ; Item {}}
+ Tab { title: "Two" ; Item {}}
+ Tab { title: "Three" ; Item {}}
+ Tab { title: "Four" ; Item {}}
+ style: tabViewStyle
+ }
+ }
+
+ // Style delegates:
+
+ property Component buttonStyle: ButtonStyle {
+ background: Rectangle {
+ implicitHeight: 22
+ implicitWidth: columnWidth
+ color: control.pressed ? "darkGray" : control.activeFocus ? "#cdd" : "#ccc"
+ antialiasing: true
+ border.color: "gray"
+ radius: height/2
+ Rectangle {
+ anchors.fill: parent
+ anchors.margins: 1
+ color: "transparent"
+ antialiasing: true
+ visible: !control.pressed
+ border.color: "#aaffffff"
+ radius: height/2
+ }
+ }
+ }
+
+ property Component textfieldStyle: TextFieldStyle {
+ background: Rectangle {
+ implicitWidth: columnWidth
+ implicitHeight: 22
+ color: "#f0f0f0"
+ antialiasing: true
+ border.color: "gray"
+ radius: height/2
+ Rectangle {
+ anchors.fill: parent
+ anchors.margins: 1
+ color: "transparent"
+ antialiasing: true
+ border.color: "#aaffffff"
+ radius: height/2
+ }
+ }
+ }
+
+ property Component sliderStyle: SliderStyle {
+ handle: Rectangle {
+ width: 18
+ height: 18
+ color: control.pressed ? "darkGray" : "lightGray"
+ border.color: "gray"
+ antialiasing: true
+ radius: height/2
+ Rectangle {
+ anchors.fill: parent
+ anchors.margins: 1
+ color: "transparent"
+ antialiasing: true
+ border.color: "#eee"
+ radius: height/2
+ }
+ }
+
+ groove: Rectangle {
+ height: 8
+ implicitWidth: columnWidth
+ implicitHeight: 22
+
+ antialiasing: true
+ color: "#ccc"
+ border.color: "#777"
+ radius: height/2
+ Rectangle {
+ anchors.fill: parent
+ anchors.margins: 1
+ color: "transparent"
+ antialiasing: true
+ border.color: "#66ffffff"
+ radius: height/2
+ }
+ }
+ }
+
+ property Component progressBarStyle: ProgressBarStyle {
+ background: BorderImage {
+ source: "../images/progress-background.png"
+ border.left: 2 ; border.right: 2 ; border.top: 2 ; border.bottom: 2
+ }
+ progress: Item {
+ clip: true
+ BorderImage {
+ anchors.fill: parent
+ anchors.rightMargin: (control.value < control.maximumValue) ? -4 : 0
+ source: "../images/progress-fill.png"
+ border.left: 10 ; border.right: 10
+ Rectangle {
+ width: 1
+ color: "#a70"
+ opacity: 0.8
+ anchors.top: parent.top
+ anchors.bottom: parent.bottom
+ anchors.bottomMargin: 1
+ anchors.right: parent.right
+ visible: control.value < control.maximumValue
+ anchors.rightMargin: -parent.anchors.rightMargin
+ }
+ }
+ ParticleSystem{ id: bubbles; running: visible }
+ ImageParticle{
+ id: fireball
+ system: bubbles
+ source: "../images/bubble.png"
+ opacity: 0.7
+ }
+ Emitter{
+ system: bubbles
+ anchors.bottom: parent.bottom
+ anchors.margins: 4
+ anchors.bottomMargin: -4
+ anchors.left: parent.left
+ anchors.right: parent.right
+ size: 4
+ sizeVariation: 4
+ acceleration: PointDirection{ y: -6; xVariation: 3 }
+ emitRate: 6 * control.value
+ lifeSpan: 3000
+ }
+ }
+ }
+
+ property Component progressBarStyle2: ProgressBarStyle {
+ background: Rectangle {
+ implicitWidth: columnWidth
+ implicitHeight: 24
+ color: "#f0f0f0"
+ border.color: "gray"
+ }
+ progress: Rectangle {
+ color: "#ccc"
+ border.color: "gray"
+ Rectangle {
+ color: "transparent"
+ border.color: "#44ffffff"
+ anchors.fill: parent
+ anchors.margins: 1
+ }
+ }
+ }
+
+ property Component tabViewStyle: TabViewStyle {
+ tabOverlap: 16
+ frameOverlap: 4
+ tabsMovable: true
+
+ frame: Rectangle {
+ gradient: Gradient{
+ GradientStop { color: "#e5e5e5" ; position: 0 }
+ GradientStop { color: "#e0e0e0" ; position: 1 }
+ }
+ border.color: "#898989"
+ Rectangle { anchors.fill: parent ; anchors.margins: 1 ; border.color: "white" ; color: "transparent" }
+ }
+ tab: Item {
+ property int totalOverlap: tabOverlap * (control.count - 1)
+ implicitWidth: Math.min ((styleData.availableWidth + totalOverlap)/control.count - 4, image.sourceSize.width)
+ implicitHeight: image.sourceSize.height
+ BorderImage {
+ id: image
+ anchors.fill: parent
+ source: styleData.selected ? "../images/tab_selected.png" : "../images/tab.png"
+ border.left: 30
+ smooth: false
+ border.right: 30
+ }
+ Text {
+ text: styleData.title
+ anchors.centerIn: parent
+ }
+ }
+ leftCorner: Item { implicitWidth: 12 }
+ }
+}
+
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/gallery.go b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/gallery.go
new file mode 100644
index 000000000..a16b6b1ab
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/gallery.go
@@ -0,0 +1,29 @@
+package main
+
+import (
+ "fmt"
+ "gopkg.in/qml.v1"
+ "os"
+)
+
+func main() {
+ if err := qml.Run(run); err != nil {
+ fmt.Fprintf(os.Stderr, "error: %v\n", err)
+ os.Exit(1)
+ }
+}
+
+func run() error {
+ engine := qml.NewEngine()
+
+ controls, err := engine.LoadFile("main.qml")
+ if err != nil {
+ return err
+ }
+
+ window := controls.CreateWindow(nil)
+
+ window.Show()
+ window.Wait()
+ return nil
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/bubble.png b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/bubble.png
new file mode 100644
index 000000000..62aa1efe5
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/bubble.png
Binary files differ
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/button-pressed.png b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/button-pressed.png
new file mode 100644
index 000000000..d64cdaa78
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/button-pressed.png
Binary files differ
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/button.png b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/button.png
new file mode 100644
index 000000000..8ab41cc80
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/button.png
Binary files differ
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/document-open.png b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/document-open.png
new file mode 100644
index 000000000..f35f25835
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/document-open.png
Binary files differ
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/document-open@2x.png b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/document-open@2x.png
new file mode 100644
index 000000000..9fdbb6657
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/document-open@2x.png
Binary files differ
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/document-save-as.png b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/document-save-as.png
new file mode 100644
index 000000000..5c9f6b343
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/document-save-as.png
Binary files differ
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/document-save-as@2x.png b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/document-save-as@2x.png
new file mode 100644
index 000000000..a15e34c92
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/document-save-as@2x.png
Binary files differ
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/folder_new.png b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/folder_new.png
new file mode 100644
index 000000000..8d8bb9bd7
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/folder_new.png
Binary files differ
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/go-next.png b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/go-next.png
new file mode 100644
index 000000000..a68e2db77
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/go-next.png
Binary files differ
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/go-previous.png b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/go-previous.png
new file mode 100644
index 000000000..c37bc0414
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/go-previous.png
Binary files differ
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/preferences-system.png b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/preferences-system.png
new file mode 100644
index 000000000..6e52db7cf
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/preferences-system.png
Binary files differ
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/process-stop.png b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/process-stop.png
new file mode 100644
index 000000000..e7a8d1722
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/process-stop.png
Binary files differ
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/progress-background.png b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/progress-background.png
new file mode 100644
index 000000000..55a069dfc
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/progress-background.png
Binary files differ
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/progress-fill.png b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/progress-fill.png
new file mode 100644
index 000000000..b588c9586
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/progress-fill.png
Binary files differ
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/slider-handle.png b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/slider-handle.png
new file mode 100644
index 000000000..ac4d4a0d9
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/slider-handle.png
Binary files differ
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/tab.png b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/tab.png
new file mode 100644
index 000000000..74fefab78
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/tab.png
Binary files differ
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/tab_selected.png b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/tab_selected.png
new file mode 100644
index 000000000..665400ccf
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/tab_selected.png
Binary files differ
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/textfield.png b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/textfield.png
new file mode 100644
index 000000000..1d4a38ab3
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/textfield.png
Binary files differ
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/toplevel_window.png b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/toplevel_window.png
new file mode 100644
index 000000000..4dc6a8cee
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/toplevel_window.png
Binary files differ
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/view-refresh.png b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/view-refresh.png
new file mode 100644
index 000000000..606ea9eba
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/view-refresh.png
Binary files differ
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/window-new.png b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/window-new.png
new file mode 100644
index 000000000..e091702e3
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/window-new.png
Binary files differ
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/window-new@2x.png b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/window-new@2x.png
new file mode 100644
index 000000000..36503018e
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/images/window-new@2x.png
Binary files differ
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/main.qml b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/main.qml
new file mode 100644
index 000000000..7250bb313
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/gallery/main.qml
@@ -0,0 +1,266 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the Qt Quick Controls module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:BSD$
+** You may use this file under the terms of the BSD license as follows:
+**
+** "Redistribution and use in source and binary forms, with or without
+** modification, are permitted provided that the following conditions are
+** met:
+** * Redistributions of source code must retain the above copyright
+** notice, this list of conditions and the following disclaimer.
+** * Redistributions in binary form must reproduce the above copyright
+** notice, this list of conditions and the following disclaimer in
+** the documentation and/or other materials provided with the
+** distribution.
+** * Neither the name of Digia Plc and its Subsidiary(-ies) nor the names
+** of its contributors may be used to endorse or promote products derived
+** from this software without specific prior written permission.
+**
+**
+** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+
+
+
+
+import QtQuick 2.2
+import QtQuick.Controls 1.1
+import QtQuick.Layouts 1.0
+import QtQuick.Dialogs 1.0
+import "content"
+
+ApplicationWindow {
+ visible: true
+ title: "Component Gallery"
+
+ width: 640
+ height: 420
+ minimumHeight: 400
+ minimumWidth: 600
+
+ property string loremIpsum:
+ "Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor "+
+ "Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor "+
+ "incididunt ut labore et dolore magna aliqua.\n Ut enim ad minim veniam, quis nostrud "+
+ "exercitation ullamco laboris nisi ut aliquip ex ea commodo cosnsequat. ";
+
+ ImageViewer { id: imageViewer }
+
+ FileDialog {
+ id: fileDialog
+ nameFilters: [ "Image files (*.png *.jpg)" ]
+ onAccepted: imageViewer.open(fileUrl)
+ }
+
+ AboutDialog { id: aboutDialog }
+
+ Action {
+ id: openAction
+ text: "&Open"
+ shortcut: StandardKey.Open
+ iconSource: "images/document-open.png"
+ onTriggered: fileDialog.open()
+ tooltip: "Open an image"
+ }
+
+ Action {
+ id: copyAction
+ text: "&Copy"
+ shortcut: StandardKey.Copy
+ iconName: "edit-copy"
+ enabled: (!!activeFocusItem && !!activeFocusItem["copy"])
+ onTriggered: activeFocusItem.copy()
+ }
+
+ Action {
+ id: cutAction
+ text: "Cu&t"
+ shortcut: StandardKey.Cut
+ iconName: "edit-cut"
+ enabled: (!!activeFocusItem && !!activeFocusItem["cut"])
+ onTriggered: activeFocusItem.cut()
+ }
+
+ Action {
+ id: pasteAction
+ text: "&Paste"
+ shortcut: StandardKey.Paste
+ iconName: "edit-paste"
+ enabled: (!!activeFocusItem && !!activeFocusItem["paste"])
+ onTriggered: activeFocusItem.paste()
+ }
+
+ Action {
+ id: aboutAction
+ text: "About"
+ onTriggered: aboutDialog.open()
+ }
+
+ ExclusiveGroup {
+ id: textFormatGroup
+
+ Action {
+ id: a1
+ text: "Align &Left"
+ checkable: true
+ Component.onCompleted: checked = true
+ }
+
+ Action {
+ id: a2
+ text: "&Center"
+ checkable: true
+ }
+
+ Action {
+ id: a3
+ text: "Align &Right"
+ checkable: true
+ }
+ }
+
+ ChildWindow { id: window1 }
+
+ Menu {
+ id: editmenu
+ MenuItem { action: cutAction }
+ MenuItem { action: copyAction }
+ MenuItem { action: pasteAction }
+ MenuSeparator {}
+ Menu {
+ title: "Text &Format"
+ MenuItem { action: a1 }
+ MenuItem { action: a2 }
+ MenuItem { action: a3 }
+ MenuSeparator { }
+ MenuItem { text: "Allow &Hyphenation"; checkable: true }
+ }
+ Menu {
+ title: "Font &Style"
+ MenuItem { text: "&Bold"; checkable: true }
+ MenuItem { text: "&Italic"; checkable: true }
+ MenuItem { text: "&Underline"; checkable: true }
+ }
+ }
+
+ toolBar: ToolBar {
+ id: toolbar
+ RowLayout {
+ id: toolbarLayout
+ spacing: 0
+ width: parent.width
+ ToolButton {
+ iconSource: "images/window-new.png"
+ onClicked: window1.visible = !window1.visible
+ Accessible.name: "New window"
+ tooltip: "Toggle visibility of the second window"
+ }
+ ToolButton { action: openAction }
+ ToolButton {
+ Accessible.name: "Save as"
+ iconSource: "images/document-save-as.png"
+ tooltip: "(Pretend to) Save as..."
+ }
+ Item { Layout.fillWidth: true }
+ CheckBox {
+ id: enabledCheck
+ text: "Enabled"
+ checked: true
+ }
+ }
+ }
+
+ menuBar: MenuBar {
+ Menu {
+ title: "&File"
+ MenuItem { action: openAction }
+ MenuItem {
+ text: "Close"
+ shortcut: StandardKey.Quit
+ onTriggered: Qt.quit()
+ }
+ }
+ Menu {
+ title: "&Edit"
+ MenuItem { action: cutAction }
+ MenuItem { action: copyAction }
+ MenuItem { action: pasteAction }
+ MenuSeparator { }
+ MenuItem {
+ text: "Do Nothing"
+ shortcut: "Ctrl+E,Shift+Ctrl+X"
+ enabled: false
+ }
+ MenuItem {
+ text: "Not Even There"
+ shortcut: "Ctrl+E,Shift+Ctrl+Y"
+ visible: false
+ }
+ Menu {
+ title: "Me Neither"
+ visible: false
+ }
+ }
+ Menu {
+ title: "&Help"
+ MenuItem { action: aboutAction }
+ }
+ }
+
+
+ SystemPalette {id: syspal}
+ color: syspal.window
+ ListModel {
+ id: choices
+ ListElement { text: "Banana" }
+ ListElement { text: "Orange" }
+ ListElement { text: "Apple" }
+ ListElement { text: "Coconut" }
+ }
+
+ TabView {
+ id:frame
+ enabled: enabledCheck.checked
+ tabPosition: controlPage.item ? controlPage.item.tabPosition : Qt.TopEdge
+ anchors.fill: parent
+ anchors.margins: Qt.platform.os === "osx" ? 12 : 2
+
+ Tab {
+ id: controlPage
+ title: "Controls"
+ Controls { }
+ }
+ Tab {
+ title: "Itemviews"
+ ModelView { }
+ }
+ Tab {
+ title: "Styles"
+ Styles { anchors.fill: parent }
+ }
+ Tab {
+ title: "Layouts"
+ Layouts { anchors.fill:parent }
+ }
+ }
+}
+
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/splitview/main.qml b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/splitview/main.qml
new file mode 100644
index 000000000..d93c74d3d
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/splitview/main.qml
@@ -0,0 +1,82 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the Qt Quick Controls module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:BSD$
+** You may use this file under the terms of the BSD license as follows:
+**
+** "Redistribution and use in source and binary forms, with or without
+** modification, are permitted provided that the following conditions are
+** met:
+** * Redistributions of source code must retain the above copyright
+** notice, this list of conditions and the following disclaimer.
+** * Redistributions in binary form must reproduce the above copyright
+** notice, this list of conditions and the following disclaimer in
+** the documentation and/or other materials provided with the
+** distribution.
+** * Neither the name of Digia Plc and its Subsidiary(-ies) nor the names
+** of its contributors may be used to endorse or promote products derived
+** from this software without specific prior written permission.
+**
+**
+** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+
+
+
+
+import QtQuick 2.2
+import QtQuick.Controls 1.1
+import QtQuick.Layouts 1.0
+
+ApplicationWindow {
+ visible: true
+ width: 600
+ height: 400
+
+ SplitView {
+ anchors.fill: parent
+
+ Rectangle {
+ id: column
+ width: 200
+ Layout.minimumWidth: 100
+ Layout.maximumWidth: 300
+ color: "lightsteelblue"
+ }
+
+ SplitView {
+ orientation: Qt.Vertical
+ Layout.fillWidth: true
+
+ Rectangle {
+ id: row1
+ height: 200
+ color: "lightblue"
+ Layout.minimumHeight: 1
+ }
+
+ Rectangle {
+ id: row2
+ color: "lightgray"
+ }
+ }
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/splitview/splitview.go b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/splitview/splitview.go
new file mode 100644
index 000000000..a16b6b1ab
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/splitview/splitview.go
@@ -0,0 +1,29 @@
+package main
+
+import (
+ "fmt"
+ "gopkg.in/qml.v1"
+ "os"
+)
+
+func main() {
+ if err := qml.Run(run); err != nil {
+ fmt.Fprintf(os.Stderr, "error: %v\n", err)
+ os.Exit(1)
+ }
+}
+
+func run() error {
+ engine := qml.NewEngine()
+
+ controls, err := engine.LoadFile("main.qml")
+ if err != nil {
+ return err
+ }
+
+ window := controls.CreateWindow(nil)
+
+ window.Show()
+ window.Wait()
+ return nil
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/tableview/images/header.png b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/tableview/images/header.png
new file mode 100644
index 000000000..dba664609
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/tableview/images/header.png
Binary files differ
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/tableview/images/selectedrow.png b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/tableview/images/selectedrow.png
new file mode 100644
index 000000000..71192ea4e
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/tableview/images/selectedrow.png
Binary files differ
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/tableview/main.qml b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/tableview/main.qml
new file mode 100644
index 000000000..9fb361369
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/tableview/main.qml
@@ -0,0 +1,405 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the Qt Quick Controls module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:BSD$
+** You may use this file under the terms of the BSD license as follows:
+**
+** "Redistribution and use in source and binary forms, with or without
+** modification, are permitted provided that the following conditions are
+** met:
+** * Redistributions of source code must retain the above copyright
+** notice, this list of conditions and the following disclaimer.
+** * Redistributions in binary form must reproduce the above copyright
+** notice, this list of conditions and the following disclaimer in
+** the documentation and/or other materials provided with the
+** distribution.
+** * Neither the name of Digia Plc and its Subsidiary(-ies) nor the names
+** of its contributors may be used to endorse or promote products derived
+** from this software without specific prior written permission.
+**
+**
+** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+
+
+
+
+import QtQuick 2.2
+import QtQuick.Window 2.1
+import QtQuick.Controls 1.1
+import QtQuick.XmlListModel 2.0
+
+Window {
+ visible: true
+ width: 538 + frame.margins * 2
+ height: 360 + frame.margins * 2
+
+ ToolBar {
+ id: toolbar
+ width: parent.width
+
+ ListModel {
+ id: delegatemenu
+ ListElement { text: "Shiny delegate" }
+ ListElement { text: "Scale selected" }
+ ListElement { text: "Editable items" }
+ }
+
+ ComboBox {
+ id: delegateChooser
+ enabled: frame.currentIndex === 3 ? 1 : 0
+ model: delegatemenu
+ width: 150
+ anchors.left: parent.left
+ anchors.leftMargin: 8
+ anchors.verticalCenter: parent.verticalCenter
+ }
+
+ CheckBox {
+ id: enabledCheck
+ text: "Enabled"
+ checked: true
+ anchors.right: parent.right
+ anchors.verticalCenter: parent.verticalCenter
+ }
+ }
+
+ SystemPalette {id: syspal}
+ color: syspal.window
+
+ XmlListModel {
+ id: flickerModel
+ source: "http://api.flickr.com/services/feeds/photos_public.gne?format=rss2&tags=" + "Qt"
+ query: "/rss/channel/item"
+ namespaceDeclarations: "declare namespace media=\"http://search.yahoo.com/mrss/\";"
+ XmlRole { name: "title"; query: "title/string()" }
+ XmlRole { name: "imagesource"; query: "media:thumbnail/@url/string()" }
+ XmlRole { name: "credit"; query: "media:credit/string()" }
+ }
+
+ ListModel {
+ id: nestedModel
+ ListElement{content: ListElement { description: "Core" ; color:"#ffaacc"}}
+ ListElement{content: ListElement { description: "Second" ; color:"#ffccaa"}}
+ ListElement{content: ListElement { description: "Third" ; color:"#ffffaa"}}
+ }
+
+ ListModel {
+ id: largeModel
+ Component.onCompleted: {
+ for (var i=0 ; i< 500 ; ++i)
+ largeModel.append({"name":"Person "+i , "age": Math.round(Math.random()*100), "gender": Math.random()>0.5 ? "Male" : "Female"})
+ }
+ }
+
+ Column {
+ anchors.top: toolbar.bottom
+ anchors.right: parent.right
+ anchors.left: parent.left
+ anchors.bottom: parent.bottom
+ anchors.margins: 8
+
+ TabView {
+ id:frame
+ focus:true
+ enabled: enabledCheck.checked
+
+ property int margins: Qt.platform.os === "osx" ? 16 : 0
+
+ height: parent.height - 34
+ anchors.right: parent.right
+ anchors.left: parent.left
+ anchors.margins: margins
+
+ Tab {
+ title: "XmlListModel"
+
+ TableView {
+ model: flickerModel
+ anchors.fill: parent
+ anchors.margins: 12
+
+ TableViewColumn {
+ role: "title"
+ title: "Title"
+ width: 120
+ }
+ TableViewColumn {
+ role: "credit"
+ title: "Credit"
+ width: 120
+ }
+ TableViewColumn {
+ role: "imagesource"
+ title: "Image source"
+ width: 200
+ visible: true
+ }
+
+ frameVisible: frameCheckbox.checked
+ headerVisible: headerCheckbox.checked
+ sortIndicatorVisible: sortableCheckbox.checked
+ alternatingRowColors: alternateCheckbox.checked
+ }
+ }
+ Tab {
+ title: "Multivalue"
+
+ TableView {
+ model: nestedModel
+ anchors.fill: parent
+ anchors.margins: 12
+
+ TableViewColumn {
+ role: "content"
+ title: "Text and Color"
+ width: 220
+ }
+
+ itemDelegate: Item {
+ Rectangle{
+ color: styleData.value.get(0).color
+ anchors.top:parent.top
+ anchors.right:parent.right
+ anchors.bottom:parent.bottom
+ anchors.margins: 4
+ width:32
+ border.color:"#666"
+ }
+ Text {
+ width: parent.width
+ anchors.margins: 4
+ anchors.left: parent.left
+ anchors.verticalCenter: parent.verticalCenter
+ elide: styleData.elideMode
+ text: styleData.value.get(0).description
+ color: styleData.textColor
+ }
+ }
+
+ frameVisible: frameCheckbox.checked
+ headerVisible: headerCheckbox.checked
+ sortIndicatorVisible: sortableCheckbox.checked
+ alternatingRowColors: alternateCheckbox.checked
+ }
+ }
+ Tab {
+ title: "Generated"
+
+ TableView {
+ model: largeModel
+ anchors.margins: 12
+ anchors.fill: parent
+ TableViewColumn {
+ role: "name"
+ title: "Name"
+ width: 120
+ }
+ TableViewColumn {
+ role: "age"
+ title: "Age"
+ width: 120
+ }
+ TableViewColumn {
+ role: "gender"
+ title: "Gender"
+ width: 120
+ }
+ frameVisible: frameCheckbox.checked
+ headerVisible: headerCheckbox.checked
+ sortIndicatorVisible: sortableCheckbox.checked
+ alternatingRowColors: alternateCheckbox.checked
+ }
+ }
+
+ Tab {
+ title: "Delegates"
+ Item {
+ anchors.fill: parent
+
+ Component {
+ id: delegate1
+ Item {
+ clip: true
+ Text {
+ width: parent.width
+ anchors.margins: 4
+ anchors.left: parent.left
+ anchors.verticalCenter: parent.verticalCenter
+ elide: styleData.elideMode
+ text: styleData.value !== undefined ? styleData.value : ""
+ color: styleData.textColor
+ }
+ }
+ }
+
+ Component {
+ id: delegate2
+ Text {
+ width: parent.width
+ anchors.margins: 4
+ anchors.left: parent.left
+ anchors.verticalCenter: parent.verticalCenter
+ elide: styleData.elideMode
+ text: styleData.value !== undefined ? styleData.value : ""
+ color: styleData.textColor
+ }
+ }
+
+ Component {
+ id: editableDelegate
+ Item {
+
+ Text {
+ width: parent.width
+ anchors.margins: 4
+ anchors.left: parent.left
+ anchors.verticalCenter: parent.verticalCenter
+ elide: styleData.elideMode
+ text: styleData.value !== undefined ? styleData.value : ""
+ color: styleData.textColor
+ visible: !styleData.selected
+ }
+ Loader { // Initialize text editor lazily to improve performance
+ id: loaderEditor
+ anchors.fill: parent
+ anchors.margins: 4
+ Connections {
+ target: loaderEditor.item
+ onAccepted: {
+ if (typeof styleData.value === 'number')
+ largeModel.setProperty(styleData.row, styleData.role, Number(parseFloat(loaderEditor.item.text).toFixed(0)))
+ else
+ largeModel.setProperty(styleData.row, styleData.role, loaderEditor.item.text)
+ }
+ }
+ sourceComponent: styleData.selected ? editor : null
+ Component {
+ id: editor
+ TextInput {
+ id: textinput
+ color: styleData.textColor
+ text: styleData.value
+ MouseArea {
+ id: mouseArea
+ anchors.fill: parent
+ hoverEnabled: true
+ onClicked: textinput.forceActiveFocus()
+ }
+ }
+ }
+ }
+ }
+ }
+ TableView {
+ model: largeModel
+ anchors.margins: 12
+ anchors.fill:parent
+ frameVisible: frameCheckbox.checked
+ headerVisible: headerCheckbox.checked
+ sortIndicatorVisible: sortableCheckbox.checked
+ alternatingRowColors: alternateCheckbox.checked
+
+ TableViewColumn {
+ role: "name"
+ title: "Name"
+ width: 120
+ }
+ TableViewColumn {
+ role: "age"
+ title: "Age"
+ width: 120
+ }
+ TableViewColumn {
+ role: "gender"
+ title: "Gender"
+ width: 120
+ }
+
+ headerDelegate: BorderImage{
+ source: "images/header.png"
+ border{left:2;right:2;top:2;bottom:2}
+ Text {
+ text: styleData.value
+ anchors.centerIn:parent
+ color:"#333"
+ }
+ }
+
+ rowDelegate: Rectangle {
+ height: (delegateChooser.currentIndex == 1 && styleData.selected) ? 30 : 20
+ Behavior on height{ NumberAnimation{} }
+
+ color: styleData.selected ? "#448" : (styleData.alternate? "#eee" : "#fff")
+ BorderImage{
+ id: selected
+ anchors.fill: parent
+ source: "images/selectedrow.png"
+ visible: styleData.selected
+ border{left:2; right:2; top:2; bottom:2}
+ SequentialAnimation {
+ running: true; loops: Animation.Infinite
+ NumberAnimation { target:selected; property: "opacity"; to: 1.0; duration: 900}
+ NumberAnimation { target:selected; property: "opacity"; to: 0.5; duration: 900}
+ }
+ }
+ }
+
+ itemDelegate: {
+ if (delegateChooser.currentIndex == 2)
+ return editableDelegate;
+ else
+ return delegate1;
+ }
+ }
+ }
+ }
+ }
+ Row{
+ x: 12
+ height: 34
+ CheckBox{
+ id: alternateCheckbox
+ checked: true
+ text: "Alternate"
+ anchors.verticalCenter: parent.verticalCenter
+ }
+ CheckBox{
+ id: sortableCheckbox
+ checked: false
+ text: "Sort indicator"
+ anchors.verticalCenter: parent.verticalCenter
+ }
+ CheckBox{
+ id: frameCheckbox
+ checked: true
+ text: "Frame"
+ anchors.verticalCenter: parent.verticalCenter
+ }
+ CheckBox{
+ id: headerCheckbox
+ checked: true
+ text: "Headers"
+ anchors.verticalCenter: parent.verticalCenter
+ }
+ }
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/tableview/tableview.go b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/tableview/tableview.go
new file mode 100644
index 000000000..a16b6b1ab
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/tableview/tableview.go
@@ -0,0 +1,29 @@
+package main
+
+import (
+ "fmt"
+ "gopkg.in/qml.v1"
+ "os"
+)
+
+func main() {
+ if err := qml.Run(run); err != nil {
+ fmt.Fprintf(os.Stderr, "error: %v\n", err)
+ os.Exit(1)
+ }
+}
+
+func run() error {
+ engine := qml.NewEngine()
+
+ controls, err := engine.LoadFile("main.qml")
+ if err != nil {
+ return err
+ }
+
+ window := controls.CreateWindow(nil)
+
+ window.Show()
+ window.Wait()
+ return nil
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/content/AndroidDelegate.qml b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/content/AndroidDelegate.qml
new file mode 100644
index 000000000..21ee8e680
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/content/AndroidDelegate.qml
@@ -0,0 +1,92 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the Qt Quick Controls module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:BSD$
+** You may use this file under the terms of the BSD license as follows:
+**
+** "Redistribution and use in source and binary forms, with or without
+** modification, are permitted provided that the following conditions are
+** met:
+** * Redistributions of source code must retain the above copyright
+** notice, this list of conditions and the following disclaimer.
+** * Redistributions in binary form must reproduce the above copyright
+** notice, this list of conditions and the following disclaimer in
+** the documentation and/or other materials provided with the
+** distribution.
+** * Neither the name of Digia Plc and its Subsidiary(-ies) nor the names
+** of its contributors may be used to endorse or promote products derived
+** from this software without specific prior written permission.
+**
+**
+** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+
+
+
+
+import QtQuick 2.2
+
+Item {
+ id: root
+ width: parent.width
+ height: 88
+
+ property alias text: textitem.text
+ signal clicked
+
+ Rectangle {
+ anchors.fill: parent
+ color: "#11ffffff"
+ visible: mouse.pressed
+ }
+
+ Text {
+ id: textitem
+ color: "white"
+ font.pixelSize: 32
+ text: modelData
+ anchors.verticalCenter: parent.verticalCenter
+ anchors.left: parent.left
+ anchors.leftMargin: 30
+ }
+
+ Rectangle {
+ anchors.left: parent.left
+ anchors.right: parent.right
+ anchors.margins: 15
+ height: 1
+ color: "#424246"
+ }
+
+ Image {
+ anchors.right: parent.right
+ anchors.rightMargin: 20
+ anchors.verticalCenter: parent.verticalCenter
+ source: "../images/navigation_next_item.png"
+ }
+
+ MouseArea {
+ id: mouse
+ anchors.fill: parent
+ onClicked: root.clicked()
+
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/content/ButtonPage.qml b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/content/ButtonPage.qml
new file mode 100644
index 000000000..6058671c5
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/content/ButtonPage.qml
@@ -0,0 +1,176 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the Qt Quick Controls module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:BSD$
+** You may use this file under the terms of the BSD license as follows:
+**
+** "Redistribution and use in source and binary forms, with or without
+** modification, are permitted provided that the following conditions are
+** met:
+** * Redistributions of source code must retain the above copyright
+** notice, this list of conditions and the following disclaimer.
+** * Redistributions in binary form must reproduce the above copyright
+** notice, this list of conditions and the following disclaimer in
+** the documentation and/or other materials provided with the
+** distribution.
+** * Neither the name of Digia Plc and its Subsidiary(-ies) nor the names
+** of its contributors may be used to endorse or promote products derived
+** from this software without specific prior written permission.
+**
+**
+** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+
+
+
+
+import QtQuick 2.2
+import QtQuick.Controls 1.1
+import QtQuick.Controls.Styles 1.1
+
+Item {
+ width: parent.width
+ height: parent.height
+
+ property real progress: 0
+ SequentialAnimation on progress {
+ loops: Animation.Infinite
+ running: true
+ NumberAnimation {
+ from: 0
+ to: 1
+ duration: 3000
+ }
+ NumberAnimation {
+ from: 1
+ to: 0
+ duration: 3000
+ }
+ }
+
+ Column {
+ spacing: 40
+ anchors.centerIn: parent
+
+ Button {
+ text: "Press me"
+ style: touchStyle
+ }
+
+ Button {
+ style: touchStyle
+ text: "Press me too"
+ }
+
+ Button {
+ anchors.margins: 20
+ style: touchStyle
+ text: "Don't press me"
+ onClicked: if (stackView) stackView.pop()
+ }
+
+ Row {
+ spacing: 20
+ Switch {
+ style: switchStyle
+ }
+ Switch {
+ style: switchStyle
+ }
+ }
+
+ }
+
+ Component {
+ id: touchStyle
+ ButtonStyle {
+ panel: Item {
+ implicitHeight: 50
+ implicitWidth: 320
+ BorderImage {
+ anchors.fill: parent
+ antialiasing: true
+ border.bottom: 8
+ border.top: 8
+ border.left: 8
+ border.right: 8
+ anchors.margins: control.pressed ? -4 : 0
+ source: control.pressed ? "../images/button_pressed.png" : "../images/button_default.png"
+ Text {
+ text: control.text
+ anchors.centerIn: parent
+ color: "white"
+ font.pixelSize: 23
+ renderType: Text.NativeRendering
+ }
+ }
+ }
+ }
+ }
+
+ Component {
+ id: switchStyle
+ SwitchStyle {
+
+ groove: Rectangle {
+ implicitHeight: 50
+ implicitWidth: 1.1
+ Rectangle {
+ anchors.top: parent.top
+ anchors.left: parent.left
+ anchors.bottom: parent.bottom
+ width: parent.width/2 - 2
+ height: 20
+ anchors.margins: 2
+ color: control.checked ? "#468bb7" : "#222"
+ Behavior on color {ColorAnimation {}}
+ Text {
+ font.pixelSize: 23
+ color: "white"
+ anchors.centerIn: parent
+ text: "ON"
+ }
+ }
+ Item {
+ width: parent.width/2
+ height: parent.height
+ anchors.right: parent.right
+ Text {
+ font.pixelSize: 23
+ color: "white"
+ anchors.centerIn: parent
+ text: "OFF"
+ }
+ }
+ color: "#222"
+ border.color: "#444"
+ border.width: 2
+ }
+ handle: Rectangle {
+ width: parent.parent.width/2
+ height: control.height
+ color: "#444"
+ border.color: "#555"
+ border.width: 2
+ }
+ }
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/content/ListPage.qml b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/content/ListPage.qml
new file mode 100644
index 000000000..65dc99f51
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/content/ListPage.qml
@@ -0,0 +1,82 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the Qt Quick Controls module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:BSD$
+** You may use this file under the terms of the BSD license as follows:
+**
+** "Redistribution and use in source and binary forms, with or without
+** modification, are permitted provided that the following conditions are
+** met:
+** * Redistributions of source code must retain the above copyright
+** notice, this list of conditions and the following disclaimer.
+** * Redistributions in binary form must reproduce the above copyright
+** notice, this list of conditions and the following disclaimer in
+** the documentation and/or other materials provided with the
+** distribution.
+** * Neither the name of Digia Plc and its Subsidiary(-ies) nor the names
+** of its contributors may be used to endorse or promote products derived
+** from this software without specific prior written permission.
+**
+**
+** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+
+
+
+
+import QtQuick 2.2
+import QtQuick.Controls 1.1
+import QtQuick.Controls.Styles 1.1
+
+ScrollView {
+ width: parent.width
+ height: parent.height
+
+ flickableItem.interactive: true
+
+ ListView {
+ anchors.fill: parent
+ model: 100
+ delegate: AndroidDelegate {
+ text: "Item #" + modelData
+ }
+ }
+
+ style: ScrollViewStyle {
+ transientScrollBars: true
+ handle: Item {
+ implicitWidth: 14
+ implicitHeight: 26
+ Rectangle {
+ color: "#424246"
+ anchors.fill: parent
+ anchors.topMargin: 6
+ anchors.leftMargin: 4
+ anchors.rightMargin: 4
+ anchors.bottomMargin: 6
+ }
+ }
+ scrollBarBackground: Item {
+ implicitWidth: 14
+ implicitHeight: 26
+ }
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/content/ProgressBarPage.qml b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/content/ProgressBarPage.qml
new file mode 100644
index 000000000..019d72061
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/content/ProgressBarPage.qml
@@ -0,0 +1,114 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the Qt Quick Controls module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:BSD$
+** You may use this file under the terms of the BSD license as follows:
+**
+** "Redistribution and use in source and binary forms, with or without
+** modification, are permitted provided that the following conditions are
+** met:
+** * Redistributions of source code must retain the above copyright
+** notice, this list of conditions and the following disclaimer.
+** * Redistributions in binary form must reproduce the above copyright
+** notice, this list of conditions and the following disclaimer in
+** the documentation and/or other materials provided with the
+** distribution.
+** * Neither the name of Digia Plc and its Subsidiary(-ies) nor the names
+** of its contributors may be used to endorse or promote products derived
+** from this software without specific prior written permission.
+**
+**
+** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+
+
+
+
+import QtQuick 2.2
+import QtQuick.Controls 1.1
+import QtQuick.Controls.Styles 1.1
+
+Item {
+ width: parent.width
+ height: parent.height
+
+ property real progress: 0
+ SequentialAnimation on progress {
+ loops: Animation.Infinite
+ running: true
+ NumberAnimation {
+ from: 0
+ to: 1
+ duration: 3000
+ }
+ NumberAnimation {
+ from: 1
+ to: 0
+ duration: 3000
+ }
+ }
+
+ Column {
+ spacing: 40
+ anchors.centerIn: parent
+
+ ProgressBar {
+ anchors.margins: 20
+ style: touchStyle
+ width: 400
+ value: progress
+ }
+
+ ProgressBar {
+ anchors.margins: 20
+ style: touchStyle
+ width: 400
+ value: 1 - progress
+ }
+
+ ProgressBar {
+ anchors.margins: 20
+ style: touchStyle
+ value: 1
+ width: 400
+ }
+
+ }
+
+ Component {
+ id: touchStyle
+ ProgressBarStyle {
+ panel: Rectangle {
+ implicitHeight: 15
+ implicitWidth: 400
+ color: "#444"
+ opacity: 0.8
+ Rectangle {
+ antialiasing: true
+ radius: 1
+ color: "#468bb7"
+ height: parent.height
+ width: parent.width * control.value / control.maximumValue
+ }
+ }
+ }
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/content/SliderPage.qml b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/content/SliderPage.qml
new file mode 100644
index 000000000..95009e4f2
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/content/SliderPage.qml
@@ -0,0 +1,106 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the Qt Quick Controls module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:BSD$
+** You may use this file under the terms of the BSD license as follows:
+**
+** "Redistribution and use in source and binary forms, with or without
+** modification, are permitted provided that the following conditions are
+** met:
+** * Redistributions of source code must retain the above copyright
+** notice, this list of conditions and the following disclaimer.
+** * Redistributions in binary form must reproduce the above copyright
+** notice, this list of conditions and the following disclaimer in
+** the documentation and/or other materials provided with the
+** distribution.
+** * Neither the name of Digia Plc and its Subsidiary(-ies) nor the names
+** of its contributors may be used to endorse or promote products derived
+** from this software without specific prior written permission.
+**
+**
+** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+
+
+
+
+import QtQuick 2.2
+import QtQuick.Controls 1.1
+import QtQuick.Controls.Styles 1.1
+
+Item {
+ width: parent.width
+ height: parent.height
+
+ Column {
+ spacing: 12
+ anchors.centerIn: parent
+
+ Slider {
+ anchors.margins: 20
+ style: touchStyle
+ value: 0
+ }
+ Slider {
+ anchors.margins: 20
+ style: touchStyle
+ value: 0.5
+ }
+ Slider {
+ anchors.margins: 20
+ style: touchStyle
+ value: 1.0
+ }
+
+ }
+
+ Component {
+ id: touchStyle
+ SliderStyle {
+ handle: Rectangle {
+ width: 30
+ height: 30
+ radius: height
+ antialiasing: true
+ color: Qt.lighter("#468bb7", 1.1)
+ }
+
+ groove: Item {
+ implicitHeight: 50
+ implicitWidth: 400
+ Rectangle {
+ height: 8
+ width: parent.width
+ anchors.verticalCenter: parent.verticalCenter
+ color: "#444"
+ opacity: 0.8
+ Rectangle {
+ antialiasing: true
+ radius: 1
+ color: "#468bb7"
+ height: parent.height
+ width: parent.width * control.value / control.maximumValue
+ }
+ }
+ }
+ }
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/content/TabBarPage.qml b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/content/TabBarPage.qml
new file mode 100644
index 000000000..c9bebccd3
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/content/TabBarPage.qml
@@ -0,0 +1,102 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the Qt Quick Controls module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:BSD$
+** You may use this file under the terms of the BSD license as follows:
+**
+** "Redistribution and use in source and binary forms, with or without
+** modification, are permitted provided that the following conditions are
+** met:
+** * Redistributions of source code must retain the above copyright
+** notice, this list of conditions and the following disclaimer.
+** * Redistributions in binary form must reproduce the above copyright
+** notice, this list of conditions and the following disclaimer in
+** the documentation and/or other materials provided with the
+** distribution.
+** * Neither the name of Digia Plc and its Subsidiary(-ies) nor the names
+** of its contributors may be used to endorse or promote products derived
+** from this software without specific prior written permission.
+**
+**
+** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+
+
+
+
+import QtQuick 2.2
+import QtQuick.Controls 1.1
+import QtQuick.Controls.Styles 1.1
+
+Item {
+ width: parent.width
+ height: parent.height
+
+ TabView {
+ anchors.fill: parent
+ style: touchStyle
+ Tab {
+ title: "Buttons"
+ ButtonPage{ visible: true }
+ }
+ Tab {
+ title: "Sliders"
+ SliderPage{ visible: true }
+ }
+ Tab {
+ title: "Progress"
+ ProgressBarPage{ visible: true }
+ }
+ }
+
+ Component {
+ id: touchStyle
+ TabViewStyle {
+ tabsAlignment: Qt.AlignVCenter
+ tabOverlap: 0
+ frame: Item { }
+ tab: Item {
+ implicitWidth: control.width/control.count
+ implicitHeight: 50
+ BorderImage {
+ anchors.fill: parent
+ border.bottom: 8
+ border.top: 8
+ source: styleData.selected ? "../images/tab_selected.png":"../images/tabs_standard.png"
+ Text {
+ anchors.centerIn: parent
+ color: "white"
+ text: styleData.title.toUpperCase()
+ font.pixelSize: 16
+ }
+ Rectangle {
+ visible: index > 0
+ anchors.top: parent.top
+ anchors.bottom: parent.bottom
+ anchors.margins: 10
+ width:1
+ color: "#3a3a3a"
+ }
+ }
+ }
+ }
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/content/TextInputPage.qml b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/content/TextInputPage.qml
new file mode 100644
index 000000000..0eeea03a2
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/content/TextInputPage.qml
@@ -0,0 +1,106 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the Qt Quick Controls module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:BSD$
+** You may use this file under the terms of the BSD license as follows:
+**
+** "Redistribution and use in source and binary forms, with or without
+** modification, are permitted provided that the following conditions are
+** met:
+** * Redistributions of source code must retain the above copyright
+** notice, this list of conditions and the following disclaimer.
+** * Redistributions in binary form must reproduce the above copyright
+** notice, this list of conditions and the following disclaimer in
+** the documentation and/or other materials provided with the
+** distribution.
+** * Neither the name of Digia Plc and its Subsidiary(-ies) nor the names
+** of its contributors may be used to endorse or promote products derived
+** from this software without specific prior written permission.
+**
+**
+** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+
+
+
+
+import QtQuick 2.2
+import QtQuick.Controls 1.1
+import QtQuick.Controls.Styles 1.1
+
+Item {
+ width: parent.width
+ height: parent.height
+
+ property real progress: 0
+ SequentialAnimation on progress {
+ loops: Animation.Infinite
+ running: true
+ NumberAnimation {
+ from: 0
+ to: 1
+ duration: 3000
+ }
+ NumberAnimation {
+ from: 1
+ to: 0
+ duration: 3000
+ }
+ }
+
+ Column {
+ spacing: 40
+ anchors.centerIn: parent
+
+ TextField {
+ anchors.margins: 20
+ text: "Text input"
+ style: touchStyle
+ }
+
+ TextField {
+ anchors.margins: 20
+ text: "Readonly Text input"
+ style: touchStyle
+ readOnly: true
+ }
+ }
+ Component {
+ id: touchStyle
+
+ TextFieldStyle {
+ textColor: "white"
+ font.pixelSize: 28
+ background: Item {
+ implicitHeight: 50
+ implicitWidth: 320
+ BorderImage {
+ source: "../images/textinput.png"
+ border.left: 8
+ border.right: 8
+ anchors.bottom: parent.bottom
+ anchors.left: parent.left
+ anchors.right: parent.right
+ }
+ }
+ }
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/images/NOTICE.txt b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/images/NOTICE.txt
new file mode 100644
index 000000000..93a9afc8c
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/images/NOTICE.txt
@@ -0,0 +1,2 @@
+Notice some of these images are derived from Google applications resources. They were provided under the following license:
+You may use the materials in this directory without restriction to develop your apps and to use in your apps.
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/images/button_default.png b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/images/button_default.png
new file mode 100644
index 000000000..6d6cfd9ad
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/images/button_default.png
Binary files differ
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/images/button_pressed.png b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/images/button_pressed.png
new file mode 100644
index 000000000..ab78b6ea3
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/images/button_pressed.png
Binary files differ
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/images/navigation_next_item.png b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/images/navigation_next_item.png
new file mode 100644
index 000000000..6665c9d85
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/images/navigation_next_item.png
Binary files differ
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/images/navigation_previous_item.png b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/images/navigation_previous_item.png
new file mode 100644
index 000000000..f8be01197
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/images/navigation_previous_item.png
Binary files differ
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/images/tab_selected.png b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/images/tab_selected.png
new file mode 100644
index 000000000..2345f7a8e
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/images/tab_selected.png
Binary files differ
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/images/tabs_standard.png b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/images/tabs_standard.png
new file mode 100644
index 000000000..7140ab7b7
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/images/tabs_standard.png
Binary files differ
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/images/textinput.png b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/images/textinput.png
new file mode 100644
index 000000000..b0256db2c
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/images/textinput.png
Binary files differ
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/images/toolbar.png b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/images/toolbar.png
new file mode 100644
index 000000000..e9eba4c74
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/images/toolbar.png
Binary files differ
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/main.qml b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/main.qml
new file mode 100644
index 000000000..c794f7dcc
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/main.qml
@@ -0,0 +1,147 @@
+/****************************************************************************
+**
+** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies).
+** Contact: http://www.qt-project.org/legal
+**
+** This file is part of the Qt Quick Controls module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:BSD$
+** You may use this file under the terms of the BSD license as follows:
+**
+** "Redistribution and use in source and binary forms, with or without
+** modification, are permitted provided that the following conditions are
+** met:
+** * Redistributions of source code must retain the above copyright
+** notice, this list of conditions and the following disclaimer.
+** * Redistributions in binary form must reproduce the above copyright
+** notice, this list of conditions and the following disclaimer in
+** the documentation and/or other materials provided with the
+** distribution.
+** * Neither the name of Digia Plc and its Subsidiary(-ies) nor the names
+** of its contributors may be used to endorse or promote products derived
+** from this software without specific prior written permission.
+**
+**
+** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+import QtQuick 2.2
+import QtQuick.Controls 1.1
+import "content"
+
+ApplicationWindow {
+ visible: true
+ width: 800
+ height: 1280
+
+ Rectangle {
+ color: "#212126"
+ anchors.fill: parent
+ }
+
+ toolBar: BorderImage {
+ border.bottom: 8
+ source: "images/toolbar.png"
+ width: parent.width
+ height: 100
+
+ Rectangle {
+ id: backButton
+ width: opacity ? 60 : 0
+ anchors.left: parent.left
+ anchors.leftMargin: 20
+ opacity: stackView.depth > 1 ? 1 : 0
+ anchors.verticalCenter: parent.verticalCenter
+ antialiasing: true
+ height: 60
+ radius: 4
+ color: backmouse.pressed ? "#222" : "transparent"
+ Behavior on opacity { NumberAnimation{} }
+ Image {
+ anchors.verticalCenter: parent.verticalCenter
+ source: "images/navigation_previous_item.png"
+ }
+ MouseArea {
+ id: backmouse
+ anchors.fill: parent
+ anchors.margins: -10
+ onClicked: stackView.pop()
+ }
+ }
+
+ Text {
+ font.pixelSize: 42
+ Behavior on x { NumberAnimation{ easing.type: Easing.OutCubic} }
+ x: backButton.x + backButton.width + 20
+ anchors.verticalCenter: parent.verticalCenter
+ color: "white"
+ text: "Widget Gallery"
+ }
+ }
+
+ ListModel {
+ id: pageModel
+ ListElement {
+ title: "Buttons"
+ page: "content/ButtonPage.qml"
+ }
+ ListElement {
+ title: "Sliders"
+ page: "content/SliderPage.qml"
+ }
+ ListElement {
+ title: "ProgressBar"
+ page: "content/ProgressBarPage.qml"
+ }
+ ListElement {
+ title: "Tabs"
+ page: "content/TabBarPage.qml"
+ }
+ ListElement {
+ title: "TextInput"
+ page: "content/TextInputPage.qml"
+ }
+ ListElement {
+ title: "List"
+ page: "content/ListPage.qml"
+ }
+ }
+
+ StackView {
+ id: stackView
+ anchors.fill: parent
+ // Implements back key navigation
+ focus: true
+ Keys.onReleased: if (event.key === Qt.Key_Back && stackView.depth > 1) {
+ stackView.pop();
+ event.accepted = true;
+ }
+
+ initialItem: Item {
+ width: parent.width
+ height: parent.height
+ ListView {
+ model: pageModel
+ anchors.fill: parent
+ delegate: AndroidDelegate {
+ text: title
+ onClicked: stackView.push(Qt.resolvedUrl(page))
+ }
+ }
+ }
+ }
+
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/touch.go b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/touch.go
new file mode 100644
index 000000000..a16b6b1ab
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/controls/touch/touch.go
@@ -0,0 +1,29 @@
+package main
+
+import (
+ "fmt"
+ "gopkg.in/qml.v1"
+ "os"
+)
+
+func main() {
+ if err := qml.Run(run); err != nil {
+ fmt.Fprintf(os.Stderr, "error: %v\n", err)
+ os.Exit(1)
+ }
+}
+
+func run() error {
+ engine := qml.NewEngine()
+
+ controls, err := engine.LoadFile("main.qml")
+ if err != nil {
+ return err
+ }
+
+ window := controls.CreateWindow(nil)
+
+ window.Show()
+ window.Wait()
+ return nil
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/customtype/customtype.go b/Godeps/_workspace/src/github.com/obscuren/qml/examples/customtype/customtype.go
new file mode 100644
index 000000000..1433d6ed8
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/customtype/customtype.go
@@ -0,0 +1,48 @@
+package main
+
+import (
+ "fmt"
+ "os"
+
+ "gopkg.in/qml.v1"
+)
+
+func main() {
+ if err := qml.Run(run); err != nil {
+ fmt.Fprintf(os.Stderr, "error: %v\n", err)
+ os.Exit(1)
+ }
+}
+
+type GoType struct {
+ Text string
+}
+
+func (v *GoType) SetText(text string) {
+ fmt.Println("Text changing to:", text)
+ v.Text = text
+}
+
+type GoSingleton struct {
+ Event string
+}
+
+func run() error {
+ qml.RegisterTypes("GoExtensions", 1, 0, []qml.TypeSpec{{
+ Init: func(v *GoType, obj qml.Object) {},
+ }, {
+ Init: func(v *GoSingleton, obj qml.Object) { v.Event = "birthday" },
+
+ Singleton: true,
+ }})
+
+ engine := qml.NewEngine()
+ component, err := engine.LoadFile("customtype.qml")
+ if err != nil {
+ return err
+ }
+
+ value := component.Create(nil)
+ fmt.Println("Text is:", value.Interface().(*GoType).Text)
+ return nil
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/customtype/customtype.qml b/Godeps/_workspace/src/github.com/obscuren/qml/examples/customtype/customtype.qml
new file mode 100644
index 000000000..54f7aa046
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/customtype/customtype.qml
@@ -0,0 +1,5 @@
+import GoExtensions 1.0
+
+GoType {
+ text: "Happy " + GoSingleton.event + ", Go!"
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/gopher/gopher.go b/Godeps/_workspace/src/github.com/obscuren/qml/examples/gopher/gopher.go
new file mode 100644
index 000000000..45f18789f
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/gopher/gopher.go
@@ -0,0 +1,117 @@
+package main
+
+import (
+ "fmt"
+ "gopkg.in/qml.v1"
+ "gopkg.in/qml.v1/gl/2.0"
+ "os"
+)
+
+var filename = "gopher.qml"
+
+func main() {
+ if len(os.Args) == 2 {
+ filename = os.Args[1]
+ }
+ if err := qml.Run(run); err != nil {
+ fmt.Fprintf(os.Stderr, "error: %v\n", err)
+ os.Exit(1)
+ }
+}
+
+func run() error {
+ engine := qml.NewEngine()
+
+ model, err := Read("model/gopher.obj")
+ if err != nil {
+ return err
+ }
+
+ qml.RegisterTypes("GoExtensions", 1, 0, []qml.TypeSpec{{
+ Init: func(g *Gopher, obj qml.Object) {
+ g.Object = obj
+ g.model = model
+ },
+ }})
+
+ component, err := engine.LoadFile(filename)
+ if err != nil {
+ return err
+ }
+
+ win := component.CreateWindow(nil)
+ win.Set("x", 560)
+ win.Set("y", 320)
+ win.Show()
+ win.Wait()
+ return nil
+}
+
+type Gopher struct {
+ qml.Object
+
+ model map[string]*Object
+
+ Rotation int
+}
+
+func (r *Gopher) SetRotation(rotation int) {
+ r.Rotation = rotation
+ r.Call("update")
+}
+
+func (r *Gopher) Paint(p *qml.Painter) {
+ gl := GL.API(p)
+
+ width := float32(r.Int("width"))
+
+ gl.Enable(GL.BLEND)
+ gl.BlendFunc(GL.SRC_ALPHA, GL.ONE_MINUS_SRC_ALPHA)
+
+ gl.ShadeModel(GL.SMOOTH)
+ gl.Enable(GL.DEPTH_TEST)
+ gl.DepthMask(true)
+ gl.Enable(GL.NORMALIZE)
+
+ gl.Clear(GL.DEPTH_BUFFER_BIT)
+
+ gl.Scalef(width/3, width/3, width/3)
+
+ lka := []float32{0.3, 0.3, 0.3, 1.0}
+ lkd := []float32{1.0, 1.0, 1.0, 0.0}
+ lks := []float32{1.0, 1.0, 1.0, 1.0}
+ lpos := []float32{-2, 6, 3, 1.0}
+
+ gl.Enable(GL.LIGHTING)
+ gl.Lightfv(GL.LIGHT0, GL.AMBIENT, lka)
+ gl.Lightfv(GL.LIGHT0, GL.DIFFUSE, lkd)
+ gl.Lightfv(GL.LIGHT0, GL.SPECULAR, lks)
+ gl.Lightfv(GL.LIGHT0, GL.POSITION, lpos)
+ gl.Enable(GL.LIGHT0)
+
+ gl.EnableClientState(GL.NORMAL_ARRAY)
+ gl.EnableClientState(GL.VERTEX_ARRAY)
+
+ gl.Translatef(1.5, 1.5, 0)
+ gl.Rotatef(-90, 0, 0, 1)
+ gl.Rotatef(float32(90+((36000+r.Rotation)%360)), 1, 0, 0)
+
+ gl.Disable(GL.COLOR_MATERIAL)
+
+ for _, obj := range r.model {
+ for _, group := range obj.Groups {
+ gl.Materialfv(GL.FRONT, GL.AMBIENT, group.Material.Ambient)
+ gl.Materialfv(GL.FRONT, GL.DIFFUSE, group.Material.Diffuse)
+ gl.Materialfv(GL.FRONT, GL.SPECULAR, group.Material.Specular)
+ gl.Materialf(GL.FRONT, GL.SHININESS, group.Material.Shininess)
+ gl.VertexPointer(3, GL.FLOAT, 0, group.Vertexes)
+ gl.NormalPointer(GL.FLOAT, 0, group.Normals)
+ gl.DrawArrays(GL.TRIANGLES, 0, len(group.Vertexes)/3)
+ }
+ }
+
+ gl.Enable(GL.COLOR_MATERIAL)
+
+ gl.DisableClientState(GL.NORMAL_ARRAY)
+ gl.DisableClientState(GL.VERTEX_ARRAY)
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/gopher/gopher.qml b/Godeps/_workspace/src/github.com/obscuren/qml/examples/gopher/gopher.qml
new file mode 100644
index 000000000..1f4be6dd4
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/gopher/gopher.qml
@@ -0,0 +1,42 @@
+import QtQuick 2.0
+import GoExtensions 1.0
+
+Rectangle {
+ width: 640; height: 400
+ color: "black"
+
+ Gopher {
+ id: gopher
+ width: 300; height: 300
+ anchors.centerIn: parent
+
+ NumberAnimation on rotation {
+ id: anim
+ from: 360; to: 0
+ duration: 5000
+ loops: Animation.Infinite
+ }
+
+ MouseArea {
+ anchors.fill: parent
+
+ property real startX
+ property real startR
+
+ onPressed: {
+ startX = mouse.x
+ startR = gopher.rotation
+ anim.running = false
+ }
+ onReleased: {
+ anim.from = gopher.rotation + 360
+ anim.to = gopher.rotation
+ anim.running = true
+ }
+ onPositionChanged: {
+ gopher.rotation = (36000 + (startR - (mouse.x - startX))) % 360
+ }
+ }
+
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/gopher/mix.qml b/Godeps/_workspace/src/github.com/obscuren/qml/examples/gopher/mix.qml
new file mode 100644
index 000000000..0a9541ffe
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/gopher/mix.qml
@@ -0,0 +1,68 @@
+import QtQuick 2.0
+import GoExtensions 1.0
+
+Rectangle {
+ id: root
+
+ width: 640
+ height: 220
+ color: "black"
+
+ Rectangle {
+ x: 20; y: 20; width: 100; height: 100
+ color: "red"
+
+ SequentialAnimation on x {
+ loops: Animation.Infinite
+ NumberAnimation { from: 20; to: 120; duration: 4000; easing.type: Easing.InOutQuad }
+ NumberAnimation { from: 120; to: 20; duration: 4000; easing.type: Easing.InOutQuad }
+ }
+ }
+
+ Rectangle {
+ x: 40; y: 40; width: 100; height: 100
+ color: "yellow"
+ opacity: 0.7
+
+ SequentialAnimation on x {
+ loops: Animation.Infinite
+ NumberAnimation { from: 40; to: 220; duration: 4000; easing.type: Easing.InOutQuad }
+ NumberAnimation { from: 220; to: 40; duration: 4000; easing.type: Easing.InOutQuad }
+ }
+ }
+
+ Gopher {
+ id: gopher
+
+ x: 60; y: 60; width: 100; height: 100
+
+ SequentialAnimation on x {
+ loops: Animation.Infinite
+ NumberAnimation { from: 60; to: 320; duration: 4000; easing.type: Easing.InOutQuad }
+ NumberAnimation { from: 320; to: 60; duration: 4000; easing.type: Easing.InOutQuad }
+ }
+ }
+
+ Rectangle {
+ x: 80; y: 80; width: 100; height: 100
+ color: "yellow"
+ opacity: 0.7
+
+ SequentialAnimation on x {
+ loops: Animation.Infinite
+ NumberAnimation { from: 80; to: 420; duration: 4000; easing.type: Easing.InOutQuad }
+ NumberAnimation { from: 420; to: 80; duration: 4000; easing.type: Easing.InOutQuad }
+ }
+ }
+
+ Rectangle {
+ x: 100; y: 100; width: 100; height: 100
+ color: "red"
+
+ SequentialAnimation on x {
+ loops: Animation.Infinite
+ NumberAnimation { from: 100; to: 520; duration: 4000; easing.type: Easing.InOutQuad }
+ NumberAnimation { from: 520; to: 100; duration: 4000; easing.type: Easing.InOutQuad }
+ }
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/gopher/model/README.md b/Godeps/_workspace/src/github.com/obscuren/qml/examples/gopher/model/README.md
new file mode 100644
index 000000000..77af72910
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/gopher/model/README.md
@@ -0,0 +1,10 @@
+
+Author
+------
+
+ * https://github.com/golang-samples/gopher-3d
+
+License
+-------
+
+ * http://creativecommons.org/licenses/by/3.0/deed.en
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/gopher/model/gopher.blend b/Godeps/_workspace/src/github.com/obscuren/qml/examples/gopher/model/gopher.blend
new file mode 100644
index 000000000..89c92b0da
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/gopher/model/gopher.blend
Binary files differ
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/gopher/model/gopher.mtl b/Godeps/_workspace/src/github.com/obscuren/qml/examples/gopher/model/gopher.mtl
new file mode 100644
index 000000000..532f5dc6c
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/gopher/model/gopher.mtl
@@ -0,0 +1,65 @@
+# Blender MTL File: 'gopher.blend'
+# Material Count: 7
+
+newmtl Body
+Ns 96.078431
+Ka 0.000000 0.000000 0.000000
+Kd 0.000000 0.429367 0.640000
+Ks 0.500000 0.500000 0.500000
+Ni 1.000000
+d 1.000000
+illum 2
+
+newmtl Eye-White
+Ns 96.078431
+Ka 0.000000 0.000000 0.000000
+Kd 0.800000 0.800000 0.800000
+Ks 1.000000 1.000000 1.000000
+Ni 1.000000
+d 1.000000
+illum 2
+
+newmtl Material
+Ns 96.078431
+Ka 0.000000 0.000000 0.000000
+Kd 0.640000 0.640000 0.640000
+Ks 0.500000 0.500000 0.500000
+Ni 1.000000
+d 1.000000
+illum 2
+
+newmtl Material.001
+Ns 96.078431
+Ka 0.000000 0.000000 0.000000
+Kd 0.000000 0.000000 0.000000
+Ks 0.000000 0.000000 0.000000
+Ni 1.000000
+d 1.000000
+illum 2
+
+newmtl NoseTop
+Ns 96.078431
+Ka 0.000000 0.000000 0.000000
+Kd 0.000000 0.000000 0.000000
+Ks 0.000000 0.000000 0.000000
+Ni 1.000000
+d 1.000000
+illum 2
+
+newmtl SkinColor
+Ns 96.078431
+Ka 0.000000 0.000000 0.000000
+Kd 0.609017 0.353452 0.144174
+Ks 0.500000 0.500000 0.500000
+Ni 1.000000
+d 1.000000
+illum 2
+
+newmtl Tooth
+Ns 96.078431
+Ka 0.000000 0.000000 0.000000
+Kd 0.640000 0.640000 0.640000
+Ks 0.500000 0.500000 0.500000
+Ni 1.000000
+d 1.000000
+illum 2
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/gopher/model/gopher.obj b/Godeps/_workspace/src/github.com/obscuren/qml/examples/gopher/model/gopher.obj
new file mode 100644
index 000000000..478a52be5
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/gopher/model/gopher.obj
@@ -0,0 +1,31375 @@
+# Blender v2.68 (sub 0) OBJ File: 'gopher.blend'
+# www.blender.org
+mtllib gopher.mtl
+o Tail_Sphere.015
+v 0.836333 -0.874988 0.092526
+v 0.823645 -0.873627 0.085005
+v 0.812676 -0.872312 0.074263
+v 0.803848 -0.871095 0.060713
+v 0.796247 -0.876140 0.053739
+v 0.789379 -0.876140 0.037016
+v 0.785150 -0.876140 0.018871
+v 0.783722 -0.876140 -0.000000
+v 0.785150 -0.876140 -0.018871
+v 0.789379 -0.876140 -0.037016
+v 0.796247 -0.876140 -0.053739
+v 0.805489 -0.876140 -0.068397
+v 0.816750 -0.876140 -0.080426
+v 0.829598 -0.876140 -0.089365
+v 0.843539 -0.876140 -0.094869
+v 0.836872 -0.867136 0.092646
+v 0.824701 -0.858223 0.085240
+v 0.814209 -0.849949 0.074605
+v 0.805800 -0.842633 0.061148
+v 0.797434 -0.842508 0.053739
+v 0.790698 -0.838771 0.037016
+v 0.786551 -0.836469 0.018871
+v 0.785150 -0.835692 -0.000000
+v 0.786551 -0.836469 -0.018871
+v 0.790698 -0.838770 -0.037016
+v 0.797434 -0.842508 -0.053739
+v 0.806498 -0.847539 -0.068397
+v 0.817543 -0.853668 -0.080426
+v 0.830145 -0.860661 -0.089365
+v 0.843818 -0.868249 -0.094869
+v 0.837938 -0.859636 0.092845
+v 0.826792 -0.843511 0.085631
+v 0.817245 -0.828592 0.075171
+v 0.809664 -0.815450 0.061869
+v 0.800950 -0.810169 0.053739
+v 0.794605 -0.802837 0.037016
+v 0.790698 -0.798322 0.018871
+v 0.789379 -0.796797 -0.000000
+v 0.790698 -0.798322 -0.018871
+v 0.794605 -0.802837 -0.037016
+v 0.800950 -0.810169 -0.053739
+v 0.809489 -0.820036 -0.068397
+v 0.819893 -0.832060 -0.080426
+v 0.831763 -0.845777 -0.089365
+v 0.844643 -0.860661 -0.094869
+v 0.839491 -0.852777 0.093115
+v 0.829838 -0.830057 0.086161
+v 0.821667 -0.809059 0.075942
+v 0.815293 -0.790590 0.062850
+v 0.806660 -0.780365 0.053739
+v 0.800950 -0.769721 0.037016
+v 0.797434 -0.763166 0.018871
+v 0.796247 -0.760952 -0.000000
+v 0.797434 -0.763166 -0.018871
+v 0.800950 -0.769721 -0.037016
+v 0.806660 -0.780365 -0.053739
+v 0.814345 -0.794690 -0.068397
+v 0.823708 -0.812145 -0.080426
+v 0.834391 -0.832060 -0.089365
+v 0.845982 -0.853668 -0.094869
+v 0.841471 -0.846823 0.093447
+v 0.833722 -0.818378 0.086812
+v 0.827306 -0.792103 0.076886
+v 0.822469 -0.769009 0.064052
+v 0.814345 -0.754242 0.053739
+v 0.809489 -0.740694 0.037016
+v 0.806498 -0.732351 0.018871
+v 0.805489 -0.729534 -0.000000
+v 0.806498 -0.732351 -0.018871
+v 0.809489 -0.740694 -0.037016
+v 0.814345 -0.754242 -0.053739
+v 0.820880 -0.772474 -0.068397
+v 0.828843 -0.794690 -0.080426
+v 0.837928 -0.820036 -0.089365
+v 0.847785 -0.847539 -0.094869
+v 0.843802 -0.842002 0.093827
+v 0.838294 -0.808922 0.087557
+v 0.833943 -0.778375 0.077968
+v 0.830917 -0.751536 0.065429
+v 0.823708 -0.732803 0.053739
+v 0.819893 -0.716872 0.037016
+v 0.817543 -0.707062 0.018871
+v 0.816750 -0.703750 0.000000
+v 0.817543 -0.707062 -0.018871
+v 0.819893 -0.716872 -0.037016
+v 0.823708 -0.732803 -0.053739
+v 0.828843 -0.754242 -0.068397
+v 0.835099 -0.780365 -0.080426
+v 0.842237 -0.810169 -0.089365
+v 0.849982 -0.842508 -0.094869
+v 0.846394 -0.838500 0.094241
+v 0.843379 -0.802052 0.088369
+v 0.841325 -0.768402 0.079147
+v 0.840312 -0.738843 0.066929
+v 0.834391 -0.716872 0.053739
+v 0.831763 -0.699171 0.037016
+v 0.830145 -0.688271 0.018871
+v 0.829598 -0.684590 0.000000
+v 0.830145 -0.688271 -0.018871
+v 0.831763 -0.699171 -0.037016
+v 0.834391 -0.716872 -0.053739
+v 0.837928 -0.740694 -0.068397
+v 0.842237 -0.769721 -0.080426
+v 0.847154 -0.802837 -0.089365
+v 0.852489 -0.838770 -0.094869
+v 0.849148 -0.836451 0.094672
+v 0.848781 -0.798033 0.089215
+v 0.849168 -0.762567 0.080376
+v 0.850294 -0.731417 0.068493
+v 0.845982 -0.707062 0.053739
+v 0.844643 -0.688271 0.037016
+v 0.843818 -0.676699 0.018871
+v 0.843539 -0.672792 0.000000
+v 0.843818 -0.676699 -0.018871
+v 0.844643 -0.688271 -0.037016
+v 0.845982 -0.707062 -0.053739
+v 0.847785 -0.732351 -0.068397
+v 0.849982 -0.763166 -0.080426
+v 0.852489 -0.798322 -0.089365
+v 0.855209 -0.836469 -0.094869
+v 0.851958 -0.835934 0.095105
+v 0.854293 -0.797019 0.090064
+v 0.857170 -0.761096 0.081608
+v 0.860479 -0.729544 0.070062
+v 0.858037 -0.703750 0.053739
+v 0.858037 -0.684590 0.037016
+v 0.858037 -0.672792 0.018871
+v 0.858037 -0.668808 0.000000
+v 0.858037 -0.672792 -0.018871
+v 0.858037 -0.684590 -0.037016
+v 0.858037 -0.703750 -0.053739
+v 0.858037 -0.729534 -0.068397
+v 0.858037 -0.760952 -0.080426
+v 0.858037 -0.796797 -0.089365
+v 0.858037 -0.835691 -0.094869
+v 0.854716 -0.836969 0.095522
+v 0.859703 -0.799050 0.090883
+v 0.865024 -0.764043 0.082797
+v 0.870475 -0.733295 0.071575
+v 0.870092 -0.707062 0.053739
+v 0.871432 -0.688271 0.037016
+v 0.872257 -0.676699 0.018871
+v 0.872535 -0.672792 0.000000
+v 0.872257 -0.676699 -0.018871
+v 0.871432 -0.688271 -0.037016
+v 0.870092 -0.707062 -0.053739
+v 0.868289 -0.732351 -0.068397
+v 0.866092 -0.763166 -0.080426
+v 0.863585 -0.798322 -0.089365
+v 0.860866 -0.836469 -0.094869
+v 0.857315 -0.839517 0.095908
+v 0.864802 -0.804046 0.091640
+v 0.872427 -0.771297 0.083896
+v 0.879898 -0.742528 0.072974
+v 0.881683 -0.716872 0.053739
+v 0.884311 -0.699171 0.037016
+v 0.885930 -0.688271 0.018871
+v 0.886476 -0.684590 0.000000
+v 0.885930 -0.688271 -0.018871
+v 0.884311 -0.699171 -0.037016
+v 0.881683 -0.716872 -0.053739
+v 0.878147 -0.740694 -0.068397
+v 0.873837 -0.769721 -0.080426
+v 0.868920 -0.802837 -0.089365
+v 0.863585 -0.838770 -0.094869
+v 0.859657 -0.843478 0.096248
+v 0.869396 -0.811817 0.092306
+v 0.879096 -0.782578 0.084863
+v 0.888386 -0.756886 0.074205
+v 0.892366 -0.732803 0.053739
+v 0.896182 -0.716872 0.037016
+v 0.898531 -0.707062 0.018871
+v 0.899324 -0.703750 0.000000
+v 0.898531 -0.707062 -0.018871
+v 0.896182 -0.716872 -0.037016
+v 0.892366 -0.732803 -0.053739
+v 0.887232 -0.754242 -0.068397
+v 0.880975 -0.780365 -0.080426
+v 0.873837 -0.810169 -0.089365
+v 0.866092 -0.842508 -0.094869
+v 0.861651 -0.848701 0.096528
+v 0.873307 -0.822063 0.092857
+v 0.884775 -0.797453 0.085662
+v 0.895613 -0.775818 0.075221
+v 0.901730 -0.754242 0.053739
+v 0.906586 -0.740694 0.037016
+v 0.909576 -0.732351 0.018871
+v 0.910586 -0.729534 -0.000000
+v 0.909576 -0.732351 -0.018871
+v 0.906586 -0.740694 -0.037016
+v 0.901730 -0.754242 -0.053739
+v 0.895195 -0.772474 -0.068397
+v 0.887232 -0.794690 -0.080426
+v 0.878147 -0.820036 -0.089365
+v 0.868289 -0.847539 -0.094869
+v 0.863221 -0.854986 0.096739
+v 0.876386 -0.834390 0.093269
+v 0.889244 -0.815350 0.086261
+v 0.901301 -0.798597 0.075984
+v 0.909414 -0.780365 0.053739
+v 0.915124 -0.769721 0.037016
+v 0.918640 -0.763166 0.018871
+v 0.919828 -0.760953 -0.000000
+v 0.918640 -0.763166 -0.018871
+v 0.915124 -0.769721 -0.037016
+v 0.909414 -0.780365 -0.053739
+v 0.901730 -0.794690 -0.068397
+v 0.892366 -0.812145 -0.080426
+v 0.881683 -0.832060 -0.089365
+v 0.870092 -0.853668 -0.094869
+v 0.864305 -0.862090 0.096871
+v 0.878513 -0.848326 0.093528
+v 0.892332 -0.835581 0.086637
+v 0.905232 -0.824346 0.076463
+v 0.915124 -0.810169 0.053739
+v 0.921469 -0.802837 0.037016
+v 0.925376 -0.798322 0.018871
+v 0.926695 -0.796798 -0.000000
+v 0.925376 -0.798322 -0.018871
+v 0.921469 -0.802837 -0.037016
+v 0.915124 -0.810169 -0.053739
+v 0.906586 -0.820036 -0.068397
+v 0.896182 -0.832060 -0.080426
+v 0.884311 -0.845777 -0.089365
+v 0.871432 -0.860661 -0.094869
+v 0.864863 -0.869741 0.096920
+v 0.879607 -0.863334 0.093624
+v 0.893921 -0.857370 0.086777
+v 0.907254 -0.852077 0.076640
+v 0.918640 -0.842508 0.053739
+v 0.925376 -0.838771 0.037016
+v 0.929524 -0.836469 0.018871
+v 0.930924 -0.835692 -0.000000
+v 0.929524 -0.836469 -0.018871
+v 0.925376 -0.838771 -0.037016
+v 0.918640 -0.842508 -0.053739
+v 0.909576 -0.847539 -0.068397
+v 0.898531 -0.853668 -0.080426
+v 0.885930 -0.860661 -0.089365
+v 0.872257 -0.868249 -0.094869
+v 0.864873 -0.877645 0.096884
+v 0.879627 -0.878838 0.093553
+v 0.893949 -0.879878 0.086673
+v 0.907290 -0.880725 0.076509
+v 0.919828 -0.876140 0.053739
+v 0.926695 -0.876140 0.037016
+v 0.930924 -0.876140 0.018871
+v 0.932352 -0.876140 -0.000000
+v 0.930924 -0.876140 -0.018871
+v 0.926695 -0.876140 -0.037016
+v 0.919828 -0.876140 -0.053739
+v 0.910586 -0.876140 -0.068397
+v 0.899324 -0.876140 -0.080426
+v 0.886476 -0.876140 -0.089365
+v 0.872535 -0.876140 -0.094869
+v 0.864334 -0.885498 0.096764
+v 0.878570 -0.894241 0.093318
+v 0.892416 -0.902240 0.086332
+v 0.905338 -0.909187 0.076074
+v 0.918640 -0.909772 0.053739
+v 0.925376 -0.913510 0.037016
+v 0.929524 -0.915811 0.018871
+v 0.930924 -0.916589 -0.000000
+v 0.929524 -0.915811 -0.018871
+v 0.925376 -0.913510 -0.037016
+v 0.918640 -0.909772 -0.053739
+v 0.909576 -0.904741 -0.068397
+v 0.898531 -0.898612 -0.080426
+v 0.885930 -0.891619 -0.089365
+v 0.872257 -0.884031 -0.094869
+v 0.863268 -0.892998 0.096565
+v 0.876479 -0.908953 0.092927
+v 0.889380 -0.923598 0.085765
+v 0.901474 -0.936370 0.075352
+v 0.915124 -0.942111 0.053739
+v 0.921469 -0.949443 0.037016
+v 0.925376 -0.953958 0.018870
+v 0.926695 -0.955483 -0.000000
+v 0.925376 -0.953958 -0.018871
+v 0.921469 -0.949443 -0.037016
+v 0.915124 -0.942111 -0.053739
+v 0.906586 -0.932244 -0.068397
+v 0.896182 -0.920220 -0.080426
+v 0.884311 -0.906503 -0.089365
+v 0.871432 -0.891619 -0.094869
+v 0.861715 -0.899857 0.096294
+v 0.873433 -0.922407 0.092397
+v 0.884957 -0.943130 0.084994
+v 0.895845 -0.961230 0.074372
+v 0.909414 -0.971915 0.053739
+v 0.915124 -0.982559 0.037016
+v 0.918640 -0.989114 0.018870
+v 0.919828 -0.991328 -0.000000
+v 0.918640 -0.989114 -0.018871
+v 0.915124 -0.982559 -0.037016
+v 0.909414 -0.971915 -0.053739
+v 0.901730 -0.957590 -0.068397
+v 0.892366 -0.940135 -0.080426
+v 0.881683 -0.920220 -0.089365
+v 0.870092 -0.898612 -0.094869
+v 0.859735 -0.905811 0.095962
+v 0.869549 -0.934087 0.091746
+v 0.879319 -0.960086 0.084050
+v 0.888669 -0.982811 0.073170
+v 0.901730 -0.998038 0.053739
+v 0.906586 -1.011586 0.037016
+v 0.909576 -1.019929 0.018870
+v 0.910586 -1.022746 -0.000000
+v 0.909576 -1.019929 -0.018871
+v 0.906586 -1.011586 -0.037016
+v 0.901730 -0.998038 -0.053739
+v 0.895195 -0.979806 -0.068397
+v 0.887232 -0.957590 -0.080426
+v 0.878147 -0.932244 -0.089365
+v 0.868289 -0.904741 -0.094869
+v 0.857405 -0.910632 0.095582
+v 0.864977 -0.943543 0.091001
+v 0.872681 -0.973815 0.082968
+v 0.880221 -1.000284 0.071792
+v 0.892366 -1.019477 0.053739
+v 0.896182 -1.035408 0.037016
+v 0.898531 -1.045218 0.018870
+v 0.899324 -1.048530 -0.000000
+v 0.898531 -1.045218 -0.018871
+v 0.896182 -1.035408 -0.037016
+v 0.892366 -1.019477 -0.053739
+v 0.887232 -0.998038 -0.068397
+v 0.880975 -0.971915 -0.080426
+v 0.873837 -0.942111 -0.089365
+v 0.866092 -0.909772 -0.094869
+v 0.858037 -0.876140 -0.096728
+v 0.854812 -0.914134 0.095169
+v 0.859892 -0.950413 0.090189
+v 0.865299 -0.983788 0.081790
+v 0.870826 -1.012977 0.070293
+v 0.881683 -1.035408 0.053739
+v 0.884311 -1.053109 0.037016
+v 0.885930 -1.064009 0.018870
+v 0.886476 -1.067690 -0.000000
+v 0.885930 -1.064009 -0.018871
+v 0.884311 -1.053109 -0.037016
+v 0.881683 -1.035408 -0.053739
+v 0.878147 -1.011586 -0.068397
+v 0.873837 -0.982559 -0.080426
+v 0.868920 -0.949443 -0.089365
+v 0.863585 -0.913509 -0.094869
+v 0.852058 -0.916182 0.094737
+v 0.854490 -0.954431 0.089343
+v 0.857457 -0.989622 0.080561
+v 0.860844 -1.020403 0.068729
+v 0.870092 -1.045218 0.053739
+v 0.871432 -1.064009 0.037016
+v 0.872257 -1.075581 0.018870
+v 0.872535 -1.079488 -0.000000
+v 0.872257 -1.075581 -0.018871
+v 0.871432 -1.064009 -0.037016
+v 0.870092 -1.045218 -0.053739
+v 0.868289 -1.019929 -0.068397
+v 0.866092 -0.989114 -0.080426
+v 0.863585 -0.953958 -0.089365
+v 0.860866 -0.915811 -0.094869
+v 0.849249 -0.916699 0.094304
+v 0.848979 -0.955445 0.088494
+v 0.849455 -0.991094 0.079328
+v 0.850659 -1.022276 0.067160
+v 0.858037 -1.048530 0.053739
+v 0.858037 -1.067690 0.037016
+v 0.858037 -1.079488 0.018870
+v 0.858037 -1.083472 -0.000000
+v 0.858037 -1.079488 -0.018871
+v 0.858037 -1.067690 -0.037016
+v 0.858037 -1.048530 -0.053739
+v 0.858037 -1.022746 -0.068397
+v 0.858037 -0.991327 -0.080426
+v 0.858037 -0.955482 -0.089365
+v 0.858037 -0.916588 -0.094869
+v 0.846491 -0.915664 0.093887
+v 0.843569 -0.953415 0.087675
+v 0.841601 -0.988146 0.078140
+v 0.840663 -1.018525 0.065647
+v 0.845982 -1.045218 0.053739
+v 0.844643 -1.064009 0.037016
+v 0.843818 -1.075581 0.018870
+v 0.843539 -1.079488 -0.000000
+v 0.843818 -1.075581 -0.018871
+v 0.844643 -1.064009 -0.037016
+v 0.845982 -1.045218 -0.053739
+v 0.847785 -1.019929 -0.068397
+v 0.849982 -0.989114 -0.080426
+v 0.852489 -0.953958 -0.089365
+v 0.855209 -0.915811 -0.094869
+v 0.843891 -0.913117 0.093501
+v 0.838469 -0.948418 0.086918
+v 0.834198 -0.980893 0.077040
+v 0.831240 -1.009292 0.064248
+v 0.834391 -1.035408 0.053739
+v 0.831763 -1.053109 0.037016
+v 0.830145 -1.064009 0.018870
+v 0.829598 -1.067690 -0.000000
+v 0.830145 -1.064009 -0.018871
+v 0.831763 -1.053109 -0.037016
+v 0.834391 -1.035408 -0.053739
+v 0.837928 -1.011586 -0.068397
+v 0.842237 -0.982559 -0.080426
+v 0.847154 -0.949443 -0.089365
+v 0.852489 -0.913509 -0.094869
+v 0.841549 -0.909156 0.093161
+v 0.833875 -0.940648 0.086252
+v 0.827529 -0.969612 0.076073
+v 0.822752 -0.994934 0.063017
+v 0.823708 -1.019477 0.053739
+v 0.819893 -1.035408 0.037016
+v 0.817543 -1.045218 0.018870
+v 0.816750 -1.048530 -0.000000
+v 0.817543 -1.045218 -0.018871
+v 0.819893 -1.035408 -0.037016
+v 0.823708 -1.019477 -0.053739
+v 0.828843 -0.998038 -0.068397
+v 0.835099 -0.971915 -0.080426
+v 0.842237 -0.942111 -0.089365
+v 0.849982 -0.909772 -0.094869
+v 0.839555 -0.903932 0.092881
+v 0.829964 -0.930402 0.085701
+v 0.821850 -0.954737 0.075274
+v 0.815525 -0.976002 0.062000
+v 0.814345 -0.998038 0.053739
+v 0.809489 -1.011586 0.037016
+v 0.806498 -1.019929 0.018870
+v 0.805489 -1.022746 -0.000000
+v 0.806498 -1.019929 -0.018871
+v 0.809489 -1.011586 -0.037016
+v 0.814345 -0.998038 -0.053739
+v 0.820880 -0.979806 -0.068397
+v 0.828843 -0.957590 -0.080426
+v 0.837928 -0.932244 -0.089365
+v 0.847785 -0.904741 -0.094869
+v 0.837986 -0.897648 0.092671
+v 0.826886 -0.918074 0.085289
+v 0.817381 -0.936840 0.074675
+v 0.809837 -0.953223 0.061238
+v 0.806660 -0.971915 0.053739
+v 0.800950 -0.982559 0.037016
+v 0.797434 -0.989114 0.018870
+v 0.796247 -0.991327 -0.000000
+v 0.797434 -0.989114 -0.018871
+v 0.800950 -0.982559 -0.037016
+v 0.806660 -0.971915 -0.053739
+v 0.814345 -0.957590 -0.068397
+v 0.823708 -0.940135 -0.080426
+v 0.834391 -0.920220 -0.089365
+v 0.845982 -0.898612 -0.094869
+v 0.850254 -0.876345 0.096537
+v 0.836901 -0.890543 0.092538
+v 0.824759 -0.904138 0.085030
+v 0.814293 -0.916608 0.074299
+v 0.805907 -0.927474 0.060759
+v 0.800950 -0.942111 0.053739
+v 0.794605 -0.949443 0.037016
+v 0.790698 -0.953958 0.018870
+v 0.789379 -0.955482 -0.000000
+v 0.790698 -0.953958 -0.018871
+v 0.794605 -0.949443 -0.037016
+v 0.800950 -0.942111 -0.053739
+v 0.809489 -0.932244 -0.068397
+v 0.819893 -0.920220 -0.080426
+v 0.831763 -0.906503 -0.089365
+v 0.844643 -0.891619 -0.094869
+v 0.836343 -0.882892 0.092489
+v 0.823664 -0.889130 0.084934
+v 0.812704 -0.894820 0.074160
+v 0.803884 -0.899742 0.060582
+v 0.797434 -0.909772 0.053739
+v 0.790698 -0.913509 0.037016
+v 0.786551 -0.915811 0.018871
+v 0.785150 -0.916588 -0.000000
+v 0.786551 -0.915811 -0.018871
+v 0.790698 -0.913509 -0.037016
+v 0.797434 -0.909772 -0.053739
+v 0.806498 -0.904741 -0.068397
+v 0.817543 -0.898612 -0.080426
+v 0.830145 -0.891619 -0.089365
+v 0.843818 -0.884031 -0.094869
+vn -0.474349 0.000000 -0.880306
+vn -0.655507 0.000000 -0.755150
+vn -0.647633 0.046113 -0.760521
+vn -0.988464 0.000000 -0.151402
+vn -0.999969 0.000000 0.000000
+vn -0.997345 0.072542 0.000000
+vn -0.765252 0.020234 0.643361
+vn -0.773370 0.019623 0.633595
+vn -0.748558 0.065889 0.659749
+vn -0.251717 0.000000 -0.967772
+vn -0.467391 0.032685 -0.883419
+vn -0.952696 0.000000 -0.303873
+vn -0.985443 0.071627 -0.153996
+vn -0.820399 -0.001923 0.571764
+vn -0.889187 0.000000 -0.457533
+vn -0.948637 0.068850 -0.308725
+vn -0.952696 0.000000 0.303873
+vn -0.948637 0.068850 0.308725
+vn -0.792291 0.000000 -0.610096
+vn -0.883602 0.063936 -0.463820
+vn -0.988464 0.000000 0.151402
+vn -0.985443 0.071627 0.154027
+vn -0.610096 0.012482 0.792199
+vn -0.398755 0.004120 0.917020
+vn -0.600971 0.045442 0.797937
+vn -0.785180 0.056490 -0.616627
+vn -0.763176 0.066286 0.642750
+vn -0.623493 0.092318 -0.776330
+vn -0.988678 0.149998 0.000000
+vn -0.726035 0.115757 0.677816
+vn -0.247871 0.016572 -0.968627
+vn -0.446333 0.065004 -0.892483
+vn -0.975585 0.147893 -0.162267
+vn -0.813562 0.056154 0.578722
+vn -0.798059 0.118290 0.590808
+vn -0.935453 0.141453 -0.323862
+vn -0.935453 0.141453 0.323862
+vn -0.865780 0.130345 -0.483108
+vn -0.975585 0.147893 0.162267
+vn -0.393628 0.020753 0.919004
+vn -0.578478 0.077517 0.811975
+vn -0.762963 0.114109 -0.636250
+vn -0.737999 0.112491 0.665304
+vn -0.380627 0.037080 0.923948
+vn -0.541765 0.108127 0.833522
+vn -0.722526 0.174047 -0.669057
+vn -0.971160 0.238380 0.000000
+vn -0.695730 0.158147 0.700644
+vn -0.581256 0.138615 -0.801782
+vn -0.694723 0.165868 0.699850
+vn -0.236000 0.033082 -0.971160
+vn -0.410535 0.096469 -0.906705
+vn -0.955840 0.234291 -0.177343
+vn -0.771081 0.184210 0.609455
+vn -0.909665 0.222144 -0.350932
+vn -0.909665 0.222144 0.350932
+vn -0.832057 0.202002 -0.516556
+vn -0.955840 0.234291 0.177343
+vn -0.863491 0.316263 0.392804
+vn -0.774987 0.281594 -0.565752
+vn -0.919065 0.338603 0.201514
+vn -0.359539 0.052492 0.931639
+vn -0.489944 0.136296 0.860988
+vn -0.658132 0.236946 -0.714621
+vn -0.938078 0.346385 0.000000
+vn -0.632801 0.202429 0.747368
+vn -0.517869 0.184515 -0.835292
+vn -0.647328 0.220069 0.729728
+vn -0.215888 0.049043 -0.975158
+vn -0.359264 0.126194 -0.924650
+vn -0.919065 0.338603 -0.201514
+vn -0.726005 0.259590 0.636799
+vn -0.863491 0.316263 -0.392804
+vn -0.849025 0.471603 -0.238166
+vn -0.649464 0.347636 0.676229
+vn -0.781121 0.429792 -0.452834
+vn -0.781121 0.429792 0.452834
+vn -0.681265 0.370678 -0.631214
+vn -0.849025 0.471572 0.238166
+vn -0.330454 0.066439 0.941465
+vn -0.422285 0.160894 0.892056
+vn -0.561144 0.301920 -0.770653
+vn -0.873379 0.487014 0.000000
+vn -0.544939 0.243538 0.802301
+vn -0.429518 0.228523 -0.873653
+vn -0.575243 0.279366 0.768761
+vn -0.187597 0.063875 -0.980132
+vn -0.291940 0.153142 -0.944060
+vn -0.312937 0.267800 -0.911222
+vn -0.738243 0.674490 0.000000
+vn -0.466842 0.344157 0.814600
+vn -0.151463 0.077120 -0.985443
+vn -0.208625 0.176000 -0.962004
+vn -0.708945 0.643117 -0.289438
+vn -0.518967 0.448225 0.727805
+vn -0.632313 0.564592 -0.530412
+vn -0.632313 0.564592 0.530412
+vn -0.530625 0.466109 -0.707907
+vn -0.708945 0.643117 0.289438
+vn -0.293710 0.078433 0.952666
+vn -0.338694 0.180486 0.923399
+vn -0.421216 0.364910 -0.830287
+vn -0.428510 0.278115 0.859645
+vn -0.231147 0.416120 -0.879421
+vn -0.456832 0.889523 0.000000
+vn -0.282876 0.301004 0.910672
+vn -0.167486 0.297586 -0.939848
+vn -0.304575 0.412214 0.858638
+vn -0.108036 0.088382 -0.990204
+vn -0.110172 0.192907 -0.975005
+vn -0.433058 0.832545 -0.345378
+vn -0.305216 0.546983 0.779473
+vn -0.373699 0.700034 -0.608478
+vn -0.373699 0.700034 0.608478
+vn -0.301431 0.551836 -0.777551
+vn -0.433058 0.832545 0.345378
+vn -0.249733 0.088198 0.964263
+vn -0.239937 0.193182 0.951353
+vn 0.000000 0.589892 -0.807459
+vn 0.000000 0.928312 0.371776
+vn -0.198462 0.095065 0.975463
+vn -0.130131 0.194739 0.972167
+vn 0.000000 0.437483 -0.899197
+vn 0.000000 1.000000 0.000000
+vn -0.116214 0.304025 0.945524
+vn 0.000000 0.309641 -0.950835
+vn -0.079653 0.456710 0.886013
+vn -0.057314 0.097201 -0.993591
+vn 0.000000 0.199774 -0.979827
+vn 0.000000 0.928312 -0.371776
+vn -0.007996 0.604389 0.796625
+vn 0.000000 0.764885 -0.644154
+vn 0.000000 0.764885 0.644154
+vn 0.190344 0.451918 0.871487
+vn 0.301431 0.551836 -0.777551
+vn 0.312357 0.582080 0.750694
+vn 0.231117 0.416120 -0.879421
+vn 0.373699 0.700034 0.608478
+vn -0.141118 0.096316 0.985290
+vn -0.084964 0.089877 0.992309
+vn 0.167486 0.297586 -0.939848
+vn 0.433058 0.832545 0.345378
+vn -0.021851 0.182775 0.982910
+vn 0.110172 0.192907 -0.975005
+vn 0.433058 0.832545 -0.345378
+vn 0.048067 0.283486 0.957762
+vn 0.000000 0.101108 -0.994873
+vn 0.057314 0.097201 -0.993591
+vn 0.373699 0.700034 -0.608478
+vn 0.456832 0.889523 0.000000
+vn 0.708945 0.643117 -0.289438
+vn 0.190039 0.247749 0.949980
+vn 0.108036 0.088382 -0.990204
+vn 0.632313 0.564592 -0.530412
+vn 0.416395 0.396496 0.818140
+vn 0.530625 0.466109 -0.707907
+vn 0.560320 0.496719 0.662770
+vn 0.421216 0.364910 -0.830287
+vn 0.632313 0.564592 0.530412
+vn -0.035615 0.079226 0.996216
+vn 0.312937 0.267800 -0.911222
+vn 0.708945 0.643117 0.289468
+vn 0.074343 0.162053 0.983947
+vn 0.208625 0.176000 -0.962004
+vn 0.429518 0.228492 -0.873653
+vn 0.738243 0.674490 0.000000
+vn 0.849025 0.471603 0.238166
+vn 0.155705 0.136418 0.978332
+vn 0.291940 0.153142 -0.944060
+vn 0.849025 0.471603 -0.238166
+vn 0.304086 0.204810 0.930357
+vn 0.151494 0.077120 -0.985443
+vn 0.781121 0.429792 -0.452834
+vn 0.571764 0.317209 0.756584
+vn 0.681265 0.370678 -0.631214
+vn 0.719779 0.392926 0.572283
+vn 0.561144 0.301920 -0.770653
+vn 0.781121 0.429792 0.452834
+vn 0.006561 0.066561 0.997742
+vn 0.658132 0.236946 -0.714621
+vn 0.863491 0.316263 0.392804
+vn 0.041444 0.052217 0.997772
+vn 0.517869 0.184515 -0.835292
+vn 0.873379 0.487014 0.000000
+vn 0.919065 0.338603 0.201514
+vn 0.221351 0.107547 0.969237
+vn 0.359264 0.126194 -0.924650
+vn 0.919065 0.338603 -0.201514
+vn 0.390820 0.158757 0.906644
+vn 0.187597 0.063906 -0.980163
+vn 0.863491 0.316263 -0.392804
+vn 0.668630 0.236610 0.704886
+vn 0.774987 0.281594 -0.565752
+vn 0.812281 0.294595 0.503342
+vn 0.725761 0.162084 0.668538
+vn 0.832057 0.202002 -0.516556
+vn 0.863643 0.208136 0.459059
+vn 0.722526 0.174047 -0.669057
+vn 0.909665 0.222144 0.350902
+vn 0.068514 0.036592 0.996979
+vn 0.581256 0.138615 -0.801782
+vn 0.938078 0.346385 0.000000
+vn 0.955840 0.234291 0.177343
+vn 0.271065 0.076571 0.959471
+vn 0.410535 0.096469 -0.906705
+vn 0.955840 0.234291 -0.177343
+vn 0.453108 0.111942 0.884365
+vn 0.215888 0.049043 -0.975158
+vn 0.909665 0.222144 -0.350902
+vn 0.971160 0.238380 0.000000
+vn 0.975585 0.147893 -0.162267
+vn 0.494186 0.065462 0.866848
+vn 0.236030 0.033082 -0.971160
+vn 0.935453 0.141453 -0.323862
+vn 0.756218 0.093966 0.647481
+vn 0.865780 0.130345 -0.483108
+vn 0.890439 0.132023 0.435469
+vn 0.762963 0.114109 -0.636250
+vn 0.935453 0.141453 0.323862
+vn 0.087374 0.020142 0.995972
+vn 0.623493 0.092318 -0.776330
+vn 0.975585 0.147893 0.162267
+vn 0.305277 0.044527 0.951201
+vn 0.446333 0.065004 -0.892483
+vn 0.647633 0.046113 -0.760521
+vn 0.988678 0.149998 0.000000
+vn 0.985443 0.071627 0.154027
+vn 0.324534 0.012085 0.945769
+vn 0.467391 0.032685 -0.883419
+vn 0.985443 0.071627 -0.154027
+vn 0.516739 0.019532 0.855892
+vn 0.247871 0.016572 -0.968627
+vn 0.948637 0.068850 -0.308725
+vn 0.767357 0.030549 0.640461
+vn 0.883602 0.063936 -0.463820
+vn 0.901456 0.062929 0.428266
+vn 0.785180 0.056490 -0.616627
+vn 0.948637 0.068850 0.308725
+vn 0.097934 0.003418 0.995178
+vn 0.792291 0.000000 -0.610096
+vn 0.952696 0.000000 0.303873
+vn 0.100528 -0.013092 0.994842
+vn 0.655507 0.000000 -0.755150
+vn 0.997345 0.072542 0.000000
+vn 0.988464 0.000000 0.151402
+vn 0.329356 -0.020356 0.943968
+vn 0.474349 0.000000 -0.880306
+vn 0.988464 0.000000 -0.151402
+vn 0.522233 -0.026002 0.852382
+vn 0.251717 0.000000 -0.967772
+vn 0.952696 0.000000 -0.303873
+vn 0.762444 -0.030000 0.646321
+vn 0.889187 0.000000 -0.457533
+vn 0.900571 -0.002441 0.434675
+vn 0.948637 -0.068850 -0.308725
+vn 0.948637 -0.068850 0.308725
+vn 0.883602 -0.063936 -0.463820
+vn 0.985443 -0.071627 0.154027
+vn 0.319773 -0.052461 0.946013
+vn 0.785180 -0.056490 -0.616627
+vn 1.000000 0.000000 0.000000
+vn 0.997345 -0.072542 0.000000
+vn 0.511002 -0.071200 0.856594
+vn 0.647633 -0.046113 -0.760521
+vn 0.739006 -0.082705 0.668569
+vn 0.467391 -0.032685 -0.883419
+vn 0.985443 -0.071627 -0.154027
+vn 0.696951 -0.147862 0.701682
+vn 0.247841 -0.016572 -0.968627
+vn 0.446333 -0.065004 -0.892483
+vn 0.975585 -0.147893 -0.162267
+vn 0.891446 -0.062014 0.448836
+vn 0.870388 -0.132664 0.474136
+vn 0.935453 -0.141453 -0.323862
+vn 0.935453 -0.141453 0.323862
+vn 0.865780 -0.130345 -0.483108
+vn 0.975585 -0.147893 0.162267
+vn 0.095340 -0.029481 0.994995
+vn 0.295663 -0.083834 0.951567
+vn 0.762963 -0.114109 -0.636250
+vn 0.988678 -0.149998 0.000000
+vn 0.482406 -0.116214 0.868191
+vn 0.623493 -0.092318 -0.776330
+vn 0.971160 -0.238380 0.000000
+vn 0.434706 -0.160985 0.886044
+vn 0.581256 -0.138615 -0.801782
+vn 0.637593 -0.208747 0.741539
+vn 0.236000 -0.033082 -0.971160
+vn 0.410535 -0.096469 -0.906705
+vn 0.955840 -0.234291 -0.177343
+vn 0.832209 -0.203070 0.515915
+vn 0.909665 -0.222144 -0.350932
+vn 0.909665 -0.222144 0.350902
+vn 0.832057 -0.202002 -0.516556
+vn 0.955840 -0.234291 0.177343
+vn 0.082064 -0.045534 0.995575
+vn 0.256508 -0.113987 0.959777
+vn 0.722526 -0.174047 -0.669057
+vn 0.774987 -0.281594 -0.565752
+vn 0.919065 -0.338603 0.201514
+vn 0.060488 -0.060823 0.996307
+vn 0.201636 -0.142125 0.969085
+vn 0.658132 -0.236946 -0.714621
+vn 0.938078 -0.346385 0.000000
+vn 0.364940 -0.204962 0.908170
+vn 0.517869 -0.184515 -0.835292
+vn 0.550890 -0.270608 0.789453
+vn 0.215888 -0.049043 -0.975158
+vn 0.359264 -0.126194 -0.924650
+vn 0.919065 -0.338603 -0.201514
+vn 0.771477 -0.280831 0.570879
+vn 0.863491 -0.316263 -0.392804
+vn 0.863491 -0.316263 0.392804
+vn 0.781121 -0.429792 -0.452834
+vn 0.781121 -0.429792 0.452834
+vn 0.681265 -0.370678 -0.631214
+vn 0.849025 -0.471603 0.238166
+vn 0.030824 -0.074740 0.996704
+vn 0.130833 -0.167150 0.977203
+vn 0.561144 -0.301920 -0.770653
+vn 0.873379 -0.487014 0.000000
+vn 0.269753 -0.246559 0.930784
+vn 0.429518 -0.228492 -0.873653
+vn 0.428663 -0.331248 0.840510
+vn 0.187597 -0.063906 -0.980163
+vn 0.291940 -0.153142 -0.944060
+vn 0.849025 -0.471603 -0.238166
+vn 0.675710 -0.367534 0.638966
+vn 0.263527 -0.384533 0.884671
+vn 0.151494 -0.077120 -0.985443
+vn 0.208655 -0.176000 -0.962004
+vn 0.708945 -0.643117 -0.289468
+vn 0.525498 -0.460768 0.715201
+vn 0.632313 -0.564592 -0.530412
+vn 0.632313 -0.564592 0.530412
+vn 0.530625 -0.466109 -0.707907
+vn 0.708945 -0.643117 0.289438
+vn -0.006500 -0.086886 0.996185
+vn 0.044496 -0.187719 0.981201
+vn 0.421216 -0.364910 -0.830287
+vn 0.738243 -0.674490 0.000000
+vn 0.146733 -0.282876 0.947844
+vn 0.312937 -0.267800 -0.911222
+vn 0.456832 -0.889523 0.000000
+vn -0.003662 -0.308847 0.951079
+vn 0.167486 -0.297586 -0.939848
+vn 0.049257 -0.434462 0.899319
+vn 0.108036 -0.088382 -0.990204
+vn 0.110172 -0.192907 -0.975005
+vn 0.433058 -0.832545 -0.345378
+vn 0.288614 -0.540483 0.790277
+vn 0.373699 -0.700034 -0.608478
+vn 0.373699 -0.700034 0.608478
+vn 0.301431 -0.551836 -0.777551
+vn 0.433058 -0.832545 0.345378
+vn -0.050996 -0.096957 0.993957
+vn -0.056215 -0.201880 0.977783
+vn 0.231117 -0.416120 -0.879421
+vn 0.000000 -0.589892 -0.807459
+vn 0.000000 -0.928312 0.371776
+vn -0.102664 -0.104282 0.989227
+vn -0.166997 -0.205145 0.964354
+vn 0.000000 -0.437483 -0.899197
+vn 0.000000 -1.000000 0.000000
+vn -0.172643 -0.315592 0.933042
+vn 0.000000 -0.309641 -0.950835
+vn -0.174261 -0.448103 0.876797
+vn 0.057314 -0.097232 -0.993591
+vn 0.000000 -0.199774 -0.979827
+vn 0.000000 -0.928312 -0.371776
+vn 0.000000 -0.764885 -0.644154
+vn 0.000000 -0.764885 0.644154
+vn -0.301431 -0.551836 -0.777551
+vn 0.000946 -0.567644 0.823237
+vn -0.288766 -0.529832 0.797388
+vn -0.231147 -0.416120 -0.879421
+vn -0.373699 -0.700034 0.608478
+vn -0.160222 -0.106052 0.981353
+vn -0.216468 -0.100040 0.971129
+vn -0.167516 -0.297586 -0.939848
+vn -0.433058 -0.832545 0.345378
+vn -0.275094 -0.194525 0.941527
+vn -0.110172 -0.192907 -0.975005
+vn -0.433058 -0.832545 -0.345378
+vn -0.336253 -0.297891 0.893399
+vn 0.000000 -0.101108 -0.994873
+vn -0.057283 -0.097201 -0.993591
+vn -0.373699 -0.700034 -0.608478
+vn -0.397290 -0.408582 0.821680
+vn -0.108036 -0.088382 -0.990204
+vn -0.632313 -0.564592 -0.530412
+vn -0.564409 -0.343852 0.750450
+vn -0.530625 -0.466109 -0.707907
+vn -0.507706 -0.447005 0.736442
+vn -0.421216 -0.364910 -0.830287
+vn -0.632313 -0.564592 0.530412
+vn -0.265603 -0.089602 0.959899
+vn -0.312937 -0.267800 -0.911222
+vn -0.456832 -0.889523 0.000000
+vn -0.708945 -0.643117 0.289438
+vn -0.369793 -0.174444 0.912564
+vn -0.208655 -0.176000 -0.962004
+vn -0.708945 -0.643117 -0.289438
+vn -0.474197 -0.263222 0.840114
+vn -0.448561 -0.148778 0.881252
+vn -0.291940 -0.153142 -0.944060
+vn -0.738243 -0.674490 0.000000
+vn -0.849025 -0.471572 -0.238166
+vn -0.581683 -0.219764 0.783135
+vn -0.151463 -0.077120 -0.985443
+vn -0.781121 -0.429792 -0.452834
+vn -0.675222 -0.272042 0.685568
+vn -0.681265 -0.370678 -0.631214
+vn -0.650624 -0.355327 0.671102
+vn -0.561144 -0.301920 -0.770653
+vn -0.781121 -0.429792 0.452834
+vn -0.307321 -0.076937 0.948454
+vn -0.429518 -0.228492 -0.873653
+vn -0.849025 -0.471603 0.238166
+vn -0.863491 -0.316263 0.392804
+vn -0.341594 -0.062441 0.937742
+vn -0.517869 -0.184515 -0.835292
+vn -0.873379 -0.487014 0.000000
+vn -0.919065 -0.338603 0.201514
+vn -0.510971 -0.119327 0.851253
+vn -0.359264 -0.126194 -0.924650
+vn -0.919065 -0.338603 -0.201514
+vn -0.660726 -0.172308 0.730552
+vn -0.187597 -0.063875 -0.980163
+vn -0.863491 -0.316263 -0.392804
+vn -0.740806 -0.201972 0.640614
+vn -0.774987 -0.281594 -0.565752
+vn -0.737144 -0.269326 0.619709
+vn -0.658132 -0.236946 -0.714621
+vn -0.832057 -0.202002 -0.516556
+vn -0.785943 -0.192419 0.587573
+vn -0.722526 -0.174047 -0.669057
+vn -0.909665 -0.222144 0.350932
+vn -0.367992 -0.046541 0.928648
+vn -0.581256 -0.138615 -0.801782
+vn -0.938078 -0.346385 0.000000
+vn -0.955840 -0.234291 0.177343
+vn -0.557390 -0.087497 0.825587
+vn -0.410535 -0.096469 -0.906705
+vn -0.955840 -0.234291 -0.177343
+vn -0.715659 -0.123692 0.687399
+vn -0.215888 -0.049043 -0.975158
+vn -0.909665 -0.222144 -0.350932
+vn -0.772942 -0.137364 0.619373
+vn -0.236000 -0.033082 -0.971160
+vn -0.935453 -0.141453 -0.323862
+vn -0.782128 -0.079409 0.618000
+vn -0.865780 -0.130345 -0.483108
+vn -0.810572 -0.123783 0.572375
+vn -0.762963 -0.114109 -0.636250
+vn -0.935453 -0.141453 0.323862
+vn -0.386242 -0.029756 0.921903
+vn -0.623493 -0.092318 -0.776330
+vn -0.971160 -0.238380 0.000000
+vn -0.975585 -0.147893 0.162267
+vn -0.588763 -0.054415 0.806452
+vn -0.446333 -0.065004 -0.892483
+vn -0.975585 -0.147893 -0.162267
+vn -0.750755 -0.075289 0.656240
+vn -0.606067 -0.020905 0.795099
+vn -0.467391 -0.032685 -0.883419
+vn -0.988678 -0.149998 0.000000
+vn -0.985443 -0.071657 -0.154027
+vn -0.769402 -0.027558 0.638142
+vn -0.247871 -0.016572 -0.968627
+vn -0.948637 -0.068850 -0.308725
+vn -0.777337 -0.027436 0.628437
+vn -0.883602 -0.063936 -0.463820
+vn -0.820246 -0.061220 0.568712
+vn -0.785180 -0.056490 -0.616627
+vn -0.948637 -0.068850 0.308725
+vn -0.396374 -0.012726 0.917997
+vn -0.647633 -0.046113 -0.760521
+vn -0.985443 -0.071657 0.154027
+vn 0.000000 0.000000 -1.000000
+vn -0.151952 -0.004700 0.988372
+vn -0.997345 -0.072542 0.000000
+usemtl SkinColor
+s 1
+f 14//1 13//2 28//3
+f 9//4 8//5 23//6
+f 4//7 3//8 19//9
+f 15//10 14//1 29//11
+f 10//12 9//4 24//13
+f 5//14 4//7 19//9
+f 11//15 10//12 25//16
+f 6//17 5//14 21//18
+f 12//19 11//15 26//20
+f 7//21 6//17 22//22
+f 2//23 1//24 17//25
+f 13//2 12//19 27//26
+f 8//5 7//21 23//6
+f 3//8 2//23 18//27
+f 29//11 28//3 43//28
+f 24//13 23//6 38//29
+f 19//9 18//27 34//30
+f 30//31 29//11 44//32
+f 25//16 24//13 39//33
+f 20//34 19//9 35//35
+f 26//20 25//16 40//36
+f 21//18 20//34 36//37
+f 27//26 26//20 41//38
+f 22//22 21//18 37//39
+f 17//25 16//40 32//41
+f 28//3 27//26 42//42
+f 23//6 22//22 38//29
+f 18//27 17//25 33//43
+f 32//41 31//44 47//45
+f 43//28 42//42 57//46
+f 38//29 37//39 53//47
+f 33//43 32//41 48//48
+f 44//32 43//28 58//49
+f 39//33 38//29 53//47
+f 34//30 33//43 49//50
+f 45//51 44//32 59//52
+f 40//36 39//33 54//53
+f 35//35 34//30 50//54
+f 41//38 40//36 55//55
+f 36//37 35//35 51//56
+f 42//42 41//38 56//57
+f 37//39 36//37 52//58
+f 51//56 50//54 66//59
+f 57//46 56//57 71//60
+f 52//58 51//56 67//61
+f 47//45 46//62 62//63
+f 58//49 57//46 72//64
+f 53//47 52//58 68//65
+f 48//48 47//45 63//66
+f 59//52 58//49 73//67
+f 54//53 53//47 68//65
+f 49//50 48//48 64//68
+f 60//69 59//52 74//70
+f 55//55 54//53 69//71
+f 50//54 49//50 65//72
+f 56//57 55//55 70//73
+f 70//73 69//71 84//74
+f 65//72 64//68 80//75
+f 71//60 70//73 85//76
+f 66//59 65//72 81//77
+f 72//64 71//60 86//78
+f 67//61 66//59 82//79
+f 62//63 61//80 77//81
+f 73//67 72//64 87//82
+f 68//65 67//61 83//83
+f 63//66 62//63 78//84
+f 74//70 73//67 88//85
+f 69//71 68//65 83//83
+f 64//68 63//66 79//86
+f 75//87 74//70 89//88
+f 89//88 88//85 103//89
+f 84//74 83//83 98//90
+f 79//86 78//84 94//91
+f 90//92 89//88 104//93
+f 85//76 84//74 99//94
+f 80//75 79//86 95//95
+f 86//78 85//76 100//96
+f 81//77 80//75 96//97
+f 87//82 86//78 101//98
+f 82//79 81//77 97//99
+f 77//81 76//100 92//101
+f 88//85 87//82 102//102
+f 83//83 82//79 98//90
+f 78//84 77//81 93//103
+f 103//89 102//102 117//104
+f 98//90 97//99 113//105
+f 93//103 92//101 108//106
+f 104//93 103//89 118//107
+f 99//94 98//90 113//105
+f 94//91 93//103 109//108
+f 105//109 104//93 119//110
+f 100//96 99//94 114//111
+f 95//95 94//91 110//112
+f 101//98 100//96 115//113
+f 96//97 95//95 111//114
+f 102//102 101//98 116//115
+f 97//99 96//97 112//116
+f 92//101 91//117 107//118
+f 117//104 116//115 131//119
+f 112//116 111//114 127//120
+f 107//118 106//121 122//122
+f 118//107 117//104 132//123
+f 113//105 112//116 128//124
+f 108//106 107//118 123//125
+f 119//110 118//107 133//126
+f 114//111 113//105 128//124
+f 109//108 108//106 124//127
+f 120//128 119//110 134//129
+f 115//113 114//111 129//130
+f 110//112 109//108 125//131
+f 116//115 115//113 130//132
+f 111//114 110//112 126//133
+f 125//131 124//127 139//134
+f 131//119 130//132 146//135
+f 126//133 125//131 140//136
+f 132//123 131//119 147//137
+f 127//120 126//133 141//138
+f 122//122 121//139 136//140
+f 133//126 132//123 148//141
+f 128//124 127//120 142//142
+f 123//125 122//122 137//143
+f 134//129 133//126 149//144
+f 129//130 128//124 144//145
+f 124//127 123//125 138//146
+f 135//147 134//129 150//148
+f 130//132 129//130 145//149
+f 144//145 143//150 159//151
+f 139//134 138//146 153//152
+f 150//148 149//144 165//153
+f 145//149 144//145 160//154
+f 140//136 139//134 154//155
+f 146//135 145//149 161//156
+f 141//138 140//136 155//157
+f 147//137 146//135 162//158
+f 142//142 141//138 156//159
+f 137//143 136//140 151//160
+f 148//141 147//137 163//161
+f 143//150 142//142 157//162
+f 138//146 137//143 152//163
+f 149//144 148//141 164//164
+f 163//161 162//158 178//165
+f 158//166 157//162 172//167
+f 153//152 152//163 167//168
+f 164//164 163//161 179//169
+f 159//151 158//166 174//170
+f 154//155 153//152 168//171
+f 165//153 164//164 180//172
+f 160//154 159//151 175//173
+f 155//157 154//155 169//174
+f 161//156 160//154 176//175
+f 156//159 155//157 170//176
+f 162//158 161//156 177//177
+f 157//162 156//159 171//178
+f 152//163 151//160 166//179
+f 177//177 176//175 192//180
+f 172//167 171//178 186//181
+f 167//168 166//179 181//182
+f 178//165 177//177 193//183
+f 173//184 172//167 187//185
+f 168//171 167//168 182//186
+f 179//169 178//165 194//187
+f 174//170 173//184 189//188
+f 169//174 168//171 183//189
+f 180//172 179//169 195//190
+f 175//173 174//170 190//191
+f 170//176 169//174 184//192
+f 176//175 175//173 191//193
+f 171//178 170//176 185//194
+f 185//194 184//192 199//195
+f 191//193 190//191 206//196
+f 186//181 185//194 200//197
+f 192//180 191//193 207//198
+f 187//185 186//181 201//199
+f 182//186 181//182 196//200
+f 193//183 192//180 208//201
+f 188//202 187//185 202//203
+f 183//189 182//186 197//204
+f 194//187 193//183 209//205
+f 189//188 188//202 204//206
+f 184//192 183//189 198//207
+f 195//190 194//187 210//208
+f 190//191 189//188 205//209
+f 204//206 203//210 219//211
+f 199//195 198//207 213//212
+f 210//208 209//205 225//213
+f 205//209 204//206 220//214
+f 200//197 199//195 214//215
+f 206//196 205//209 221//216
+f 201//199 200//197 215//217
+f 207//198 206//196 222//218
+f 202//203 201//199 216//219
+f 197//204 196//200 211//220
+f 208//201 207//198 223//221
+f 203//210 202//203 217//222
+f 198//207 197//204 212//223
+f 209//205 208//201 224//224
+f 223//221 222//218 238//225
+f 218//226 217//222 232//227
+f 213//212 212//223 227//228
+f 224//224 223//221 239//229
+f 219//211 218//226 234//230
+f 214//215 213//212 228//231
+f 225//213 224//224 240//232
+f 220//214 219//211 235//233
+f 215//217 214//215 229//234
+f 221//216 220//214 236//235
+f 216//219 215//217 230//236
+f 222//218 221//216 237//237
+f 217//222 216//219 231//238
+f 212//223 211//220 226//239
+f 237//237 236//235 252//240
+f 232//227 231//238 246//241
+f 227//228 226//239 241//242
+f 238//225 237//237 253//243
+f 233//244 232//227 247//245
+f 228//231 227//228 242//246
+f 239//229 238//225 254//247
+f 234//230 233//244 249//248
+f 229//234 228//231 243//249
+f 240//232 239//229 255//250
+f 235//233 234//230 250//251
+f 230//236 229//234 244//252
+f 236//235 235//233 251//253
+f 231//238 230//236 245//254
+f 251//253 250//251 265//255
+f 246//241 245//254 261//256
+f 252//240 251//253 266//257
+f 247//245 246//241 262//258
+f 242//246 241//242 257//259
+f 253//243 252//240 267//260
+f 248//261 247//245 263//262
+f 243//249 242//246 258//263
+f 254//247 253//243 268//264
+f 249//248 248//261 263//262
+f 244//252 243//249 259//265
+f 255//250 254//247 269//266
+f 250//251 249//248 264//267
+f 245//254 244//252 259//265
+f 259//265 258//263 274//268
+f 270//269 269//266 284//270
+f 265//255 264//267 279//271
+f 260//272 259//265 275//273
+f 266//257 265//255 280//274
+f 261//256 260//272 276//275
+f 267//260 266//257 281//276
+f 262//258 261//256 277//277
+f 257//259 256//278 272//279
+f 268//264 267//260 282//280
+f 263//262 262//258 278//281
+f 258//263 257//259 273//282
+f 269//266 268//264 283//283
+f 264//267 263//262 278//281
+f 278//281 277//277 293//284
+f 273//282 272//279 288//285
+f 284//270 283//283 298//286
+f 279//271 278//281 293//284
+f 274//268 273//282 289//287
+f 285//288 284//270 299//289
+f 280//274 279//271 294//290
+f 275//273 274//268 290//291
+f 281//276 280//274 295//292
+f 276//275 275//273 291//293
+f 282//280 281//276 296//294
+f 277//277 276//275 292//295
+f 272//279 271//296 287//297
+f 283//283 282//280 297//298
+f 297//298 296//294 311//299
+f 292//295 291//293 307//300
+f 287//297 286//301 302//302
+f 298//286 297//298 312//303
+f 293//284 292//295 308//304
+f 288//285 287//297 303//305
+f 299//289 298//286 313//306
+f 294//290 293//284 308//304
+f 289//287 288//285 304//307
+f 300//308 299//289 314//309
+f 295//292 294//290 309//310
+f 290//291 289//287 305//311
+f 296//294 295//292 310//312
+f 291//293 290//291 306//313
+f 311//299 310//312 325//314
+f 306//313 305//311 321//315
+f 312//303 311//299 326//316
+f 307//300 306//313 322//317
+f 302//302 301//318 317//319
+f 313//306 312//303 327//320
+f 308//304 307//300 323//321
+f 303//305 302//302 318//322
+f 314//309 313//306 328//323
+f 309//310 308//304 323//321
+f 304//307 303//305 319//324
+f 315//325 314//309 329//326
+f 310//312 309//310 324//327
+f 305//311 304//307 320//328
+f 319//324 318//322 335//329
+f 330//330 329//326 345//331
+f 325//314 324//327 340//332
+f 320//328 319//324 336//333
+f 326//316 325//314 341//334
+f 321//315 320//328 337//335
+f 327//320 326//316 342//336
+f 322//317 321//315 338//337
+f 317//319 316//338 333//339
+f 328//323 327//320 343//340
+f 323//321 322//317 339//341
+f 318//322 317//319 334//342
+f 329//326 328//323 344//343
+f 324//327 323//321 339//341
+f 339//341 338//337 354//344
+f 334//342 333//339 349//345
+f 345//331 344//343 359//346
+f 340//332 339//341 354//344
+f 335//329 334//342 350//347
+f 346//348 345//331 360//349
+f 341//334 340//332 355//350
+f 336//333 335//329 351//351
+f 342//336 341//334 356//352
+f 337//335 336//333 352//353
+f 343//340 342//336 357//354
+f 338//337 337//335 353//355
+f 333//339 332//356 348//357
+f 344//343 343//340 358//358
+f 358//358 357//354 372//359
+f 353//355 352//353 368//360
+f 348//357 347//361 363//362
+f 359//346 358//358 373//363
+f 354//344 353//355 369//364
+f 349//345 348//357 364//365
+f 360//349 359//346 374//366
+f 355//350 354//344 369//364
+f 350//347 349//345 365//367
+f 361//368 360//349 375//369
+f 356//352 355//350 370//370
+f 351//351 350//347 365//367
+f 357//354 356//352 371//371
+f 352//353 351//351 367//372
+f 372//359 371//371 387//373
+f 367//372 366//374 381//375
+f 373//363 372//359 388//376
+f 368//360 367//372 382//377
+f 363//362 362//378 377//379
+f 374//366 373//363 389//380
+f 369//364 368//360 383//381
+f 364//365 363//362 378//382
+f 375//369 374//366 390//383
+f 370//370 369//364 385//384
+f 365//367 364//365 379//385
+f 376//386 375//369 391//387
+f 371//371 370//370 386//388
+f 366//374 365//367 380//389
+f 391//387 390//383 406//390
+f 386//388 385//384 401//391
+f 381//375 380//389 395//392
+f 387//373 386//388 402//393
+f 382//377 381//375 396//394
+f 388//376 387//373 403//395
+f 383//381 382//377 397//396
+f 378//382 377//379 392//397
+f 389//380 388//376 404//398
+f 384//399 383//381 398//400
+f 379//385 378//382 393//401
+f 390//383 389//380 405//402
+f 385//384 384//399 400//403
+f 380//389 379//385 394//404
+f 394//404 393//401 408//405
+f 405//402 404//398 420//406
+f 400//403 399//407 415//408
+f 395//392 394//404 409//409
+f 406//390 405//402 421//410
+f 401//391 400//403 416//411
+f 396//394 395//392 410//412
+f 402//393 401//391 417//413
+f 397//396 396//394 411//414
+f 403//395 402//393 418//415
+f 398//400 397//396 412//416
+f 393//401 392//397 407//417
+f 404//398 403//395 419//418
+f 399//407 398//400 413//419
+f 413//419 412//416 427//420
+f 408//405 407//417 422//421
+f 419//418 418//415 434//422
+f 414//423 413//419 428//424
+f 409//409 408//405 423//425
+f 420//406 419//418 435//426
+f 415//408 414//423 430//427
+f 410//412 409//409 424//428
+f 421//410 420//406 436//429
+f 416//411 415//408 431//430
+f 411//414 410//412 425//431
+f 417//413 416//411 432//432
+f 412//416 411//414 426//433
+f 418//415 417//413 433//434
+f 432//432 431//430 447//435
+f 427//420 426//433 441//436
+f 433//434 432//432 448//437
+f 428//424 427//420 442//438
+f 423//425 422//421 437//439
+f 434//422 433//434 449//440
+f 429//441 428//424 443//442
+f 424//428 423//425 438//443
+f 435//426 434//422 450//444
+f 430//427 429//441 445//445
+f 425//431 424//428 439//446
+f 436//429 435//426 451//447
+f 431//430 430//427 446//448
+f 426//433 425//431 440//449
+f 451//447 450//444 467//450
+f 446//448 445//445 462//451
+f 441//436 440//449 456//452
+f 447//435 446//448 463//453
+f 442//438 441//436 457//454
+f 448//437 447//435 464//455
+f 443//442 442//438 458//456
+f 438//443 437//439 453//457
+f 449//440 448//437 465//458
+f 444//459 443//442 459//460
+f 439//446 438//443 454//461
+f 450//444 449//440 466//462
+f 445//445 444//459 461//463
+f 440//449 439//446 455//464
+f 455//464 454//461 469//465
+f 466//462 465//458 481//466
+f 461//463 460//467 476//468
+f 456//452 455//464 470//469
+f 467//450 466//462 482//470
+f 462//451 461//463 477//471
+f 457//454 456//452 471//472
+f 463//453 462//451 478//473
+f 458//456 457//454 472//474
+f 464//455 463//453 479//475
+f 459//460 458//456 473//476
+f 454//461 453//457 468//477
+f 465//458 464//455 480//478
+f 460//467 459//460 474//479
+f 331//480 15//10 30//31
+f 1//24 452//481 16//40
+f 331//480 30//31 45//51
+f 16//40 452//481 31//44
+f 331//480 45//51 60//69
+f 31//44 452//481 46//62
+f 46//62 452//481 61//80
+f 331//480 60//69 75//87
+f 331//480 75//87 90//92
+f 61//80 452//481 76//100
+f 331//480 90//92 105//109
+f 76//100 452//481 91//117
+f 331//480 105//109 120//128
+f 91//117 452//481 106//121
+f 106//121 452//481 121//139
+f 331//480 120//128 135//147
+f 331//480 135//147 150//148
+f 121//139 452//481 136//140
+f 331//480 150//148 165//153
+f 136//140 452//481 151//160
+f 331//480 165//153 180//172
+f 151//160 452//481 166//179
+f 166//179 452//481 181//182
+f 331//480 180//172 195//190
+f 331//480 195//190 210//208
+f 181//182 452//481 196//200
+f 331//480 210//208 225//213
+f 196//200 452//481 211//220
+f 331//480 225//213 240//232
+f 211//220 452//481 226//239
+f 331//480 240//232 255//250
+f 226//239 452//481 241//242
+f 331//480 255//250 270//269
+f 241//242 452//481 256//278
+f 331//480 270//269 285//288
+f 256//278 452//481 271//296
+f 331//480 285//288 300//308
+f 271//296 452//481 286//301
+f 331//480 300//308 315//325
+f 286//301 452//481 301//318
+f 331//480 315//325 330//330
+f 301//318 452//481 316//338
+f 331//480 330//330 346//348
+f 316//338 452//481 332//356
+f 331//480 346//348 361//368
+f 332//356 452//481 347//361
+f 331//480 361//368 376//386
+f 347//361 452//481 362//378
+f 331//480 376//386 391//387
+f 362//378 452//481 377//379
+f 331//480 391//387 406//390
+f 377//379 452//481 392//397
+f 331//480 406//390 421//410
+f 392//397 452//481 407//417
+f 331//480 421//410 436//429
+f 407//417 452//481 422//421
+f 422//421 452//481 437//439
+f 331//480 436//429 451//447
+f 331//480 451//447 467//450
+f 437//439 452//481 453//457
+f 331//480 467//450 482//470
+f 453//457 452//481 468//477
+f 474//479 473//476 6//17
+f 469//465 468//477 1//24
+f 480//478 479//475 13//2
+f 475//482 474//479 7//21
+f 470//469 469//465 2//23
+f 481//466 480//478 14//1
+f 476//468 475//482 9//4
+f 471//472 470//469 3//8
+f 482//470 481//466 15//10
+f 477//471 476//468 10//12
+f 472//474 471//472 4//7
+f 331//480 482//470 15//10
+f 478//473 477//471 11//15
+f 473//476 472//474 5//14
+f 468//477 452//481 1//24
+f 479//475 478//473 12//19
+f 29//11 14//1 28//3
+f 24//13 9//4 23//6
+f 3//8 18//27 19//9
+f 30//31 15//10 29//11
+f 25//16 10//12 24//13
+f 20//34 5//14 19//9
+f 26//20 11//15 25//16
+f 5//14 20//34 21//18
+f 27//26 12//19 26//20
+f 6//17 21//18 22//22
+f 1//24 16//40 17//25
+f 28//3 13//2 27//26
+f 7//21 22//22 23//6
+f 2//23 17//25 18//27
+f 44//32 29//11 43//28
+f 39//33 24//13 38//29
+f 18//27 33//43 34//30
+f 45//51 30//31 44//32
+f 40//36 25//16 39//33
+f 19//9 34//30 35//35
+f 41//38 26//20 40//36
+f 20//34 35//35 36//37
+f 42//42 27//26 41//38
+f 21//18 36//37 37//39
+f 16//40 31//44 32//41
+f 43//28 28//3 42//42
+f 22//22 37//39 38//29
+f 17//25 32//41 33//43
+f 31//44 46//62 47//45
+f 58//49 43//28 57//46
+f 37//39 52//58 53//47
+f 32//41 47//45 48//48
+f 59//52 44//32 58//49
+f 54//53 39//33 53//47
+f 33//43 48//48 49//50
+f 60//69 45//51 59//52
+f 55//55 40//36 54//53
+f 34//30 49//50 50//54
+f 56//57 41//38 55//55
+f 35//35 50//54 51//56
+f 57//46 42//42 56//57
+f 36//37 51//56 52//58
+f 50//54 65//72 66//59
+f 72//64 57//46 71//60
+f 51//56 66//59 67//61
+f 46//62 61//80 62//63
+f 73//67 58//49 72//64
+f 52//58 67//61 68//65
+f 47//45 62//63 63//66
+f 74//70 59//52 73//67
+f 69//71 54//53 68//65
+f 48//48 63//66 64//68
+f 75//87 60//69 74//70
+f 70//73 55//55 69//71
+f 49//50 64//68 65//72
+f 71//60 56//57 70//73
+f 85//76 70//73 84//74
+f 64//68 79//86 80//75
+f 86//78 71//60 85//76
+f 65//72 80//75 81//77
+f 87//82 72//64 86//78
+f 66//59 81//77 82//79
+f 61//80 76//100 77//81
+f 88//85 73//67 87//82
+f 67//61 82//79 83//83
+f 62//63 77//81 78//84
+f 89//88 74//70 88//85
+f 84//74 69//71 83//83
+f 63//66 78//84 79//86
+f 90//92 75//87 89//88
+f 104//93 89//88 103//89
+f 99//94 84//74 98//90
+f 78//84 93//103 94//91
+f 105//109 90//92 104//93
+f 100//96 85//76 99//94
+f 79//86 94//91 95//95
+f 101//98 86//78 100//96
+f 80//75 95//95 96//97
+f 102//102 87//82 101//98
+f 81//77 96//97 97//99
+f 76//100 91//117 92//101
+f 103//89 88//85 102//102
+f 82//79 97//99 98//90
+f 77//81 92//101 93//103
+f 118//107 103//89 117//104
+f 97//99 112//116 113//105
+f 92//101 107//118 108//106
+f 119//110 104//93 118//107
+f 114//111 99//94 113//105
+f 93//103 108//106 109//108
+f 120//128 105//109 119//110
+f 115//113 100//96 114//111
+f 94//91 109//108 110//112
+f 116//115 101//98 115//113
+f 95//95 110//112 111//114
+f 117//104 102//102 116//115
+f 96//97 111//114 112//116
+f 91//117 106//121 107//118
+f 132//123 117//104 131//119
+f 111//114 126//133 127//120
+f 106//121 121//139 122//122
+f 133//126 118//107 132//123
+f 112//116 127//120 128//124
+f 107//118 122//122 123//125
+f 134//129 119//110 133//126
+f 129//130 114//111 128//124
+f 108//106 123//125 124//127
+f 135//147 120//128 134//129
+f 130//132 115//113 129//130
+f 109//108 124//127 125//131
+f 131//119 116//115 130//132
+f 110//112 125//131 126//133
+f 140//136 125//131 139//134
+f 130//132 145//149 146//135
+f 141//138 126//133 140//136
+f 131//119 146//135 147//137
+f 142//142 127//120 141//138
+f 137//143 122//122 136//140
+f 132//123 147//137 148//141
+f 143//150 128//124 142//142
+f 138//146 123//125 137//143
+f 133//126 148//141 149//144
+f 128//124 143//150 144//145
+f 139//134 124//127 138//146
+f 134//129 149//144 150//148
+f 129//130 144//145 145//149
+f 143//150 158//166 159//151
+f 154//155 139//134 153//152
+f 149//144 164//164 165//153
+f 144//145 159//151 160//154
+f 155//157 140//136 154//155
+f 145//149 160//154 161//156
+f 156//159 141//138 155//157
+f 146//135 161//156 162//158
+f 157//162 142//142 156//159
+f 152//163 137//143 151//160
+f 147//137 162//158 163//161
+f 158//166 143//150 157//162
+f 153//152 138//146 152//163
+f 148//141 163//161 164//164
+f 162//158 177//177 178//165
+f 173//184 158//166 172//167
+f 168//171 153//152 167//168
+f 163//161 178//165 179//169
+f 158//166 173//184 174//170
+f 169//174 154//155 168//171
+f 164//164 179//169 180//172
+f 159//151 174//170 175//173
+f 170//176 155//157 169//174
+f 160//154 175//173 176//175
+f 171//178 156//159 170//176
+f 161//156 176//175 177//177
+f 172//167 157//162 171//178
+f 167//168 152//163 166//179
+f 176//175 191//193 192//180
+f 187//185 172//167 186//181
+f 182//186 167//168 181//182
+f 177//177 192//180 193//183
+f 188//202 173//184 187//185
+f 183//189 168//171 182//186
+f 178//165 193//183 194//187
+f 173//184 188//202 189//188
+f 184//192 169//174 183//189
+f 179//169 194//187 195//190
+f 174//170 189//188 190//191
+f 185//194 170//176 184//192
+f 175//173 190//191 191//193
+f 186//181 171//178 185//194
+f 200//197 185//194 199//195
+f 190//191 205//209 206//196
+f 201//199 186//181 200//197
+f 191//193 206//196 207//198
+f 202//203 187//185 201//199
+f 197//204 182//186 196//200
+f 192//180 207//198 208//201
+f 203//210 188//202 202//203
+f 198//207 183//189 197//204
+f 193//183 208//201 209//205
+f 188//202 203//210 204//206
+f 199//195 184//192 198//207
+f 194//187 209//205 210//208
+f 189//188 204//206 205//209
+f 203//210 218//226 219//211
+f 214//215 199//195 213//212
+f 209//205 224//224 225//213
+f 204//206 219//211 220//214
+f 215//217 200//197 214//215
+f 205//209 220//214 221//216
+f 216//219 201//199 215//217
+f 206//196 221//216 222//218
+f 217//222 202//203 216//219
+f 212//223 197//204 211//220
+f 207//198 222//218 223//221
+f 218//226 203//210 217//222
+f 213//212 198//207 212//223
+f 208//201 223//221 224//224
+f 222//218 237//237 238//225
+f 233//244 218//226 232//227
+f 228//231 213//212 227//228
+f 223//221 238//225 239//229
+f 218//226 233//244 234//230
+f 229//234 214//215 228//231
+f 224//224 239//229 240//232
+f 219//211 234//230 235//233
+f 230//236 215//217 229//234
+f 220//214 235//233 236//235
+f 231//238 216//219 230//236
+f 221//216 236//235 237//237
+f 232//227 217//222 231//238
+f 227//228 212//223 226//239
+f 236//235 251//253 252//240
+f 247//245 232//227 246//241
+f 242//246 227//228 241//242
+f 237//237 252//240 253//243
+f 248//261 233//244 247//245
+f 243//249 228//231 242//246
+f 238//225 253//243 254//247
+f 233//244 248//261 249//248
+f 244//252 229//234 243//249
+f 239//229 254//247 255//250
+f 234//230 249//248 250//251
+f 245//254 230//236 244//252
+f 235//233 250//251 251//253
+f 246//241 231//238 245//254
+f 266//257 251//253 265//255
+f 245//254 260//272 261//256
+f 267//260 252//240 266//257
+f 246//241 261//256 262//258
+f 241//242 256//278 257//259
+f 268//264 253//243 267//260
+f 247//245 262//258 263//262
+f 242//246 257//259 258//263
+f 269//266 254//247 268//264
+f 264//267 249//248 263//262
+f 243//249 258//263 259//265
+f 270//269 255//250 269//266
+f 265//255 250//251 264//267
+f 260//272 245//254 259//265
+f 258//263 273//282 274//268
+f 285//288 270//269 284//270
+f 280//274 265//255 279//271
+f 259//265 274//268 275//273
+f 281//276 266//257 280//274
+f 260//272 275//273 276//275
+f 282//280 267//260 281//276
+f 261//256 276//275 277//277
+f 256//278 271//296 272//279
+f 283//283 268//264 282//280
+f 262//258 277//277 278//281
+f 257//259 272//279 273//282
+f 284//270 269//266 283//283
+f 279//271 264//267 278//281
+f 277//277 292//295 293//284
+f 272//279 287//297 288//285
+f 299//289 284//270 298//286
+f 294//290 279//271 293//284
+f 273//282 288//285 289//287
+f 300//308 285//288 299//289
+f 295//292 280//274 294//290
+f 274//268 289//287 290//291
+f 296//294 281//276 295//292
+f 275//273 290//291 291//293
+f 297//298 282//280 296//294
+f 276//275 291//293 292//295
+f 271//296 286//301 287//297
+f 298//286 283//283 297//298
+f 312//303 297//298 311//299
+f 291//293 306//313 307//300
+f 286//301 301//318 302//302
+f 313//306 298//286 312//303
+f 292//295 307//300 308//304
+f 287//297 302//302 303//305
+f 314//309 299//289 313//306
+f 309//310 294//290 308//304
+f 288//285 303//305 304//307
+f 315//325 300//308 314//309
+f 310//312 295//292 309//310
+f 289//287 304//307 305//311
+f 311//299 296//294 310//312
+f 290//291 305//311 306//313
+f 326//316 311//299 325//314
+f 305//311 320//328 321//315
+f 327//320 312//303 326//316
+f 306//313 321//315 322//317
+f 301//318 316//338 317//319
+f 328//323 313//306 327//320
+f 307//300 322//317 323//321
+f 302//302 317//319 318//322
+f 329//326 314//309 328//323
+f 324//327 309//310 323//321
+f 303//305 318//322 319//324
+f 330//330 315//325 329//326
+f 325//314 310//312 324//327
+f 304//307 319//324 320//328
+f 318//322 334//342 335//329
+f 346//348 330//330 345//331
+f 341//334 325//314 340//332
+f 319//324 335//329 336//333
+f 342//336 326//316 341//334
+f 320//328 336//333 337//335
+f 343//340 327//320 342//336
+f 321//315 337//335 338//337
+f 316//338 332//356 333//339
+f 344//343 328//323 343//340
+f 322//317 338//337 339//341
+f 317//319 333//339 334//342
+f 345//331 329//326 344//343
+f 340//332 324//327 339//341
+f 338//337 353//355 354//344
+f 333//339 348//357 349//345
+f 360//349 345//331 359//346
+f 355//350 340//332 354//344
+f 334//342 349//345 350//347
+f 361//368 346//348 360//349
+f 356//352 341//334 355//350
+f 335//329 350//347 351//351
+f 357//354 342//336 356//352
+f 336//333 351//351 352//353
+f 358//358 343//340 357//354
+f 337//335 352//353 353//355
+f 332//356 347//361 348//357
+f 359//346 344//343 358//358
+f 373//363 358//358 372//359
+f 352//353 367//372 368//360
+f 347//361 362//378 363//362
+f 374//366 359//346 373//363
+f 353//355 368//360 369//364
+f 348//357 363//362 364//365
+f 375//369 360//349 374//366
+f 370//370 355//350 369//364
+f 349//345 364//365 365//367
+f 376//386 361//368 375//369
+f 371//371 356//352 370//370
+f 366//374 351//351 365//367
+f 372//359 357//354 371//371
+f 351//351 366//374 367//372
+f 371//371 386//388 387//373
+f 382//377 367//372 381//375
+f 372//359 387//373 388//376
+f 383//381 368//360 382//377
+f 378//382 363//362 377//379
+f 373//363 388//376 389//380
+f 384//399 369//364 383//381
+f 379//385 364//365 378//382
+f 374//366 389//380 390//383
+f 369//364 384//399 385//384
+f 380//389 365//367 379//385
+f 375//369 390//383 391//387
+f 370//370 385//384 386//388
+f 381//375 366//374 380//389
+f 390//383 405//402 406//390
+f 385//384 400//403 401//391
+f 396//394 381//375 395//392
+f 386//388 401//391 402//393
+f 397//396 382//377 396//394
+f 387//373 402//393 403//395
+f 398//400 383//381 397//396
+f 393//401 378//382 392//397
+f 388//376 403//395 404//398
+f 399//407 384//399 398//400
+f 394//404 379//385 393//401
+f 389//380 404//398 405//402
+f 384//399 399//407 400//403
+f 395//392 380//389 394//404
+f 409//409 394//404 408//405
+f 404//398 419//418 420//406
+f 399//407 414//423 415//408
+f 410//412 395//392 409//409
+f 405//402 420//406 421//410
+f 400//403 415//408 416//411
+f 411//414 396//394 410//412
+f 401//391 416//411 417//413
+f 412//416 397//396 411//414
+f 402//393 417//413 418//415
+f 413//419 398//400 412//416
+f 408//405 393//401 407//417
+f 403//395 418//415 419//418
+f 414//423 399//407 413//419
+f 428//424 413//419 427//420
+f 423//425 408//405 422//421
+f 418//415 433//434 434//422
+f 429//441 414//423 428//424
+f 424//428 409//409 423//425
+f 419//418 434//422 435//426
+f 414//423 429//441 430//427
+f 425//431 410//412 424//428
+f 420//406 435//426 436//429
+f 415//408 430//427 431//430
+f 426//433 411//414 425//431
+f 416//411 431//430 432//432
+f 427//420 412//416 426//433
+f 417//413 432//432 433//434
+f 431//430 446//448 447//435
+f 442//438 427//420 441//436
+f 432//432 447//435 448//437
+f 443//442 428//424 442//438
+f 438//443 423//425 437//439
+f 433//434 448//437 449//440
+f 444//459 429//441 443//442
+f 439//446 424//428 438//443
+f 434//422 449//440 450//444
+f 429//441 444//459 445//445
+f 440//449 425//431 439//446
+f 435//426 450//444 451//447
+f 430//427 445//445 446//448
+f 441//436 426//433 440//449
+f 450//444 466//462 467//450
+f 445//445 461//463 462//451
+f 457//454 441//436 456//452
+f 446//448 462//451 463//453
+f 458//456 442//438 457//454
+f 447//435 463//453 464//455
+f 459//460 443//442 458//456
+f 454//461 438//443 453//457
+f 448//437 464//455 465//458
+f 460//467 444//459 459//460
+f 455//464 439//446 454//461
+f 449//440 465//458 466//462
+f 444//459 460//467 461//463
+f 456//452 440//449 455//464
+f 470//469 455//464 469//465
+f 465//458 480//478 481//466
+f 460//467 475//482 476//468
+f 471//472 456//452 470//469
+f 466//462 481//466 482//470
+f 461//463 476//468 477//471
+f 472//474 457//454 471//472
+f 462//451 477//471 478//473
+f 473//476 458//456 472//474
+f 463//453 478//473 479//475
+f 474//479 459//460 473//476
+f 469//465 454//461 468//477
+f 464//455 479//475 480//478
+f 475//482 460//467 474//479
+f 7//21 474//479 6//17
+f 2//23 469//465 1//24
+f 479//475 12//19 13//2
+f 8//5 475//482 7//21
+f 3//8 470//469 2//23
+f 480//478 13//2 14//1
+f 475//482 8//5 9//4
+f 4//7 471//472 3//8
+f 481//466 14//1 15//10
+f 476//468 9//4 10//12
+f 5//14 472//474 4//7
+f 477//471 10//12 11//15
+f 6//17 473//476 5//14
+f 478//473 11//15 12//19
+o Foot_R.001_Sphere.014
+v 1.075241 0.496383 0.547398
+v 1.072531 0.479456 0.520507
+v 1.071806 0.464152 0.495335
+v 1.073094 0.451061 0.472848
+v 1.076347 0.440684 0.453912
+v 1.081437 0.433421 0.439254
+v 1.088171 0.429551 0.429436
+v 1.096290 0.429222 0.424838
+v 1.105480 0.432448 0.425634
+v 1.115390 0.439104 0.431795
+v 1.125638 0.448934 0.443084
+v 1.135830 0.461562 0.459067
+v 1.145576 0.476500 0.479129
+v 1.154499 0.493176 0.502500
+v 1.162258 0.510949 0.528282
+v 1.075570 0.500339 0.546759
+v 1.073176 0.487215 0.519253
+v 1.072743 0.475417 0.493515
+v 1.074287 0.465397 0.470532
+v 1.077749 0.457542 0.451188
+v 1.082996 0.452153 0.436227
+v 1.089826 0.449436 0.426224
+v 1.097976 0.449498 0.421562
+v 1.107134 0.452334 0.422421
+v 1.116948 0.457836 0.428768
+v 1.127040 0.465793 0.440360
+v 1.137023 0.475899 0.456750
+v 1.146513 0.487765 0.477309
+v 1.155145 0.500935 0.501247
+v 1.162587 0.514904 0.527643
+v 1.076095 0.504836 0.547197
+v 1.074207 0.496036 0.520113
+v 1.074240 0.488223 0.494762
+v 1.076192 0.481697 0.472119
+v 1.079989 0.476708 0.453055
+v 1.085485 0.473449 0.438301
+v 1.092468 0.472044 0.428425
+v 1.100670 0.472548 0.423807
+v 1.109777 0.474941 0.424623
+v 1.119437 0.479132 0.430843
+v 1.129280 0.484959 0.442227
+v 1.138928 0.492198 0.458338
+v 1.148009 0.500571 0.478557
+v 1.156176 0.509757 0.502106
+v 1.163113 0.519401 0.528081
+v 1.076797 0.509701 0.548695
+v 1.075584 0.505580 0.523052
+v 1.076239 0.502079 0.499029
+v 1.078736 0.499332 0.477550
+v 1.082981 0.497444 0.459441
+v 1.088809 0.496490 0.445397
+v 1.095997 0.496504 0.435958
+v 1.104268 0.497488 0.431487
+v 1.113306 0.499402 0.432155
+v 1.122761 0.502173 0.437938
+v 1.132272 0.505695 0.448612
+v 1.141472 0.509833 0.463768
+v 1.150008 0.514427 0.482823
+v 1.157552 0.519301 0.505045
+v 1.163815 0.524267 0.529580
+v 1.077649 0.514748 0.551196
+v 1.077254 0.515480 0.527957
+v 1.078663 0.516451 0.506151
+v 1.081822 0.517625 0.486615
+v 1.086609 0.518955 0.470100
+v 1.092840 0.520391 0.457240
+v 1.100277 0.521878 0.448531
+v 1.108632 0.523358 0.444306
+v 1.117585 0.524775 0.444729
+v 1.126793 0.526074 0.449782
+v 1.135900 0.527206 0.459271
+v 1.144558 0.528126 0.472833
+v 1.152433 0.528800 0.489945
+v 1.159222 0.529201 0.509951
+v 1.164666 0.529314 0.532081
+v 1.078617 0.519783 0.554604
+v 1.079153 0.525356 0.534642
+v 1.081419 0.530789 0.515855
+v 1.085330 0.535873 0.498965
+v 1.090734 0.540413 0.484623
+v 1.097424 0.544234 0.473377
+v 1.105143 0.547189 0.465662
+v 1.113594 0.549165 0.461773
+v 1.122452 0.550086 0.461860
+v 1.131377 0.549917 0.465919
+v 1.140026 0.548664 0.473794
+v 1.148066 0.546374 0.485184
+v 1.155189 0.543137 0.499649
+v 1.161121 0.539077 0.516635
+v 1.165634 0.534349 0.535488
+v 1.079664 0.524612 0.558787
+v 1.081207 0.534828 0.542847
+v 1.084402 0.544541 0.527767
+v 1.089127 0.553375 0.514127
+v 1.095199 0.560993 0.502451
+v 1.102385 0.567102 0.493187
+v 1.110409 0.571466 0.486692
+v 1.118963 0.573917 0.483215
+v 1.127718 0.574363 0.482890
+v 1.136337 0.572785 0.485729
+v 1.144490 0.569244 0.491623
+v 1.151863 0.563877 0.500346
+v 1.158172 0.556889 0.511562
+v 1.163176 0.548549 0.524841
+v 1.166681 0.539178 0.539671
+v 1.080751 0.529050 0.563585
+v 1.083339 0.543533 0.552259
+v 1.087497 0.557178 0.541431
+v 1.093065 0.569459 0.531518
+v 1.099830 0.579906 0.522900
+v 1.107531 0.588116 0.515909
+v 1.115872 0.593774 0.510814
+v 1.124533 0.596663 0.507809
+v 1.133181 0.596672 0.507011
+v 1.141483 0.593799 0.508451
+v 1.149121 0.588157 0.512072
+v 1.155801 0.579960 0.517736
+v 1.161267 0.569526 0.525226
+v 1.165307 0.557253 0.534252
+v 1.167768 0.543615 0.544469
+v 1.081835 0.532925 0.568814
+v 1.085465 0.551135 0.562515
+v 1.090584 0.568214 0.556321
+v 1.096995 0.583506 0.550469
+v 1.104450 0.596423 0.545184
+v 1.112665 0.606469 0.540670
+v 1.121322 0.613258 0.537100
+v 1.130090 0.616529 0.534610
+v 1.138631 0.616155 0.533297
+v 1.146617 0.612152 0.533212
+v 1.153742 0.604674 0.534356
+v 1.159731 0.594007 0.536687
+v 1.164354 0.580562 0.540115
+v 1.167434 0.564855 0.544509
+v 1.168852 0.547491 0.549698
+v 1.082875 0.536090 0.574272
+v 1.087505 0.557343 0.573222
+v 1.093546 0.577226 0.571864
+v 1.100764 0.594976 0.570252
+v 1.108882 0.609911 0.568447
+v 1.117589 0.621456 0.566518
+v 1.126550 0.629168 0.564539
+v 1.135420 0.632750 0.562587
+v 1.143859 0.632065 0.560737
+v 1.151542 0.627139 0.559059
+v 1.158174 0.618162 0.557619
+v 1.163500 0.605478 0.556470
+v 1.167315 0.589574 0.555659
+v 1.169474 0.571063 0.555215
+v 1.169892 0.550655 0.555156
+v 1.083830 0.538422 0.579750
+v 1.089380 0.561917 0.583967
+v 1.096267 0.583868 0.587464
+v 1.104228 0.603429 0.590107
+v 1.112956 0.619851 0.591794
+v 1.122115 0.632500 0.592459
+v 1.131355 0.640892 0.592079
+v 1.140319 0.644704 0.590666
+v 1.148664 0.643789 0.588276
+v 1.156068 0.638183 0.585001
+v 1.162247 0.628101 0.580965
+v 1.166964 0.613930 0.576325
+v 1.170037 0.596216 0.571259
+v 1.171348 0.575638 0.565960
+v 1.170848 0.552987 0.560634
+v 1.084665 0.539832 0.585037
+v 1.091017 0.564683 0.594338
+v 1.098645 0.587883 0.602521
+v 1.107254 0.608540 0.609270
+v 1.116514 0.625860 0.614328
+v 1.126069 0.639178 0.617498
+v 1.135552 0.647981 0.618659
+v 1.144598 0.651932 0.617768
+v 1.152861 0.650878 0.614857
+v 1.160021 0.644861 0.610039
+v 1.165805 0.634111 0.603499
+v 1.169990 0.619041 0.595489
+v 1.172414 0.600231 0.586315
+v 1.172986 0.578404 0.576332
+v 1.171683 0.554397 0.565921
+v 1.085347 0.540266 0.589930
+v 1.092355 0.565534 0.603937
+v 1.100587 0.589118 0.616456
+v 1.109725 0.610112 0.627006
+v 1.119420 0.627709 0.635183
+v 1.129298 0.641232 0.640671
+v 1.138980 0.650162 0.643260
+v 1.148093 0.654155 0.642850
+v 1.156289 0.653059 0.639457
+v 1.163250 0.646915 0.633212
+v 1.168711 0.635959 0.624355
+v 1.172461 0.620613 0.613225
+v 1.174356 0.601466 0.600250
+v 1.174324 0.579255 0.585930
+v 1.172364 0.554831 0.570815
+v 1.085850 0.539706 0.594242
+v 1.093341 0.564437 0.612394
+v 1.102018 0.587526 0.628734
+v 1.111547 0.608085 0.642633
+v 1.121562 0.625325 0.653558
+v 1.131678 0.638583 0.661088
+v 1.141507 0.647350 0.664935
+v 1.150670 0.651289 0.664950
+v 1.158816 0.650247 0.661132
+v 1.165631 0.644267 0.653629
+v 1.170853 0.633576 0.642730
+v 1.174283 0.618586 0.628851
+v 1.175788 0.599874 0.612528
+v 1.175310 0.578158 0.594387
+v 1.172867 0.554272 0.575126
+v 1.086154 0.538176 0.597805
+v 1.093938 0.561435 0.619385
+v 1.102884 0.583167 0.638882
+v 1.112649 0.602537 0.655550
+v 1.122858 0.618801 0.668746
+v 1.133119 0.631334 0.677965
+v 1.143036 0.639655 0.682851
+v 1.152229 0.643442 0.683217
+v 1.160345 0.642552 0.679048
+v 1.167071 0.637018 0.670506
+v 1.172150 0.627052 0.657918
+v 1.175385 0.613038 0.641768
+v 1.176654 0.595515 0.622677
+v 1.175906 0.575155 0.601378
+v 1.173171 0.552741 0.578690
+v 1.086248 0.535732 0.600485
+v 1.094122 0.556642 0.624640
+v 1.103152 0.576209 0.646512
+v 1.112990 0.593681 0.665261
+v 1.123259 0.608388 0.680165
+v 1.133564 0.619763 0.690652
+v 1.143508 0.627371 0.696320
+v 1.152711 0.630918 0.696950
+v 1.160817 0.630268 0.692518
+v 1.167516 0.625447 0.683194
+v 1.172550 0.616639 0.669337
+v 1.175726 0.604182 0.651479
+v 1.176921 0.588557 0.630307
+v 1.176091 0.570362 0.606633
+v 1.173265 0.550298 0.581369
+v 1.086128 0.532470 0.602176
+v 1.093887 0.550243 0.627958
+v 1.102811 0.566919 0.651329
+v 1.112556 0.581857 0.671392
+v 1.122748 0.594485 0.687375
+v 1.132996 0.604315 0.698664
+v 1.142906 0.610971 0.704824
+v 1.152097 0.614197 0.705621
+v 1.160215 0.613869 0.701022
+v 1.166949 0.609998 0.691205
+v 1.172040 0.602735 0.676547
+v 1.175292 0.592359 0.657610
+v 1.176580 0.579267 0.635124
+v 1.175856 0.563963 0.609952
+v 1.173145 0.547036 0.583061
+v 1.085799 0.528515 0.602815
+v 1.093242 0.542484 0.629212
+v 1.101874 0.555654 0.653149
+v 1.111363 0.567521 0.673708
+v 1.121346 0.577626 0.690099
+v 1.131438 0.585583 0.701690
+v 1.141252 0.591085 0.708037
+v 1.150410 0.593922 0.708897
+v 1.158561 0.593983 0.704235
+v 1.165390 0.591266 0.694232
+v 1.170637 0.585877 0.679270
+v 1.174099 0.578022 0.659927
+v 1.175643 0.568003 0.636944
+v 1.175210 0.556204 0.611205
+v 1.172816 0.543080 0.583700
+v 1.085274 0.524018 0.602377
+v 1.092211 0.533663 0.628353
+v 1.100377 0.542848 0.651902
+v 1.109458 0.551222 0.672121
+v 1.119106 0.558461 0.688232
+v 1.128949 0.564287 0.699616
+v 1.138610 0.568478 0.705836
+v 1.147716 0.570871 0.706652
+v 1.155918 0.571375 0.702033
+v 1.162902 0.569971 0.692157
+v 1.168397 0.566711 0.677404
+v 1.172194 0.561723 0.658339
+v 1.174147 0.555196 0.635697
+v 1.174179 0.547383 0.610346
+v 1.172291 0.538583 0.583262
+v 1.084572 0.519152 0.600879
+v 1.090834 0.524119 0.625414
+v 1.098378 0.528993 0.647635
+v 1.106914 0.533587 0.666690
+v 1.116114 0.537724 0.681846
+v 1.125625 0.541246 0.692521
+v 1.135081 0.544017 0.698303
+v 1.144118 0.545932 0.698972
+v 1.152390 0.546915 0.694501
+v 1.159577 0.546929 0.685062
+v 1.165406 0.545975 0.671018
+v 1.169650 0.544088 0.652909
+v 1.172148 0.541341 0.631430
+v 1.172802 0.537839 0.607407
+v 1.171589 0.533718 0.581763
+v 1.083720 0.514105 0.598378
+v 1.089164 0.514219 0.620508
+v 1.095954 0.514620 0.640513
+v 1.103829 0.515293 0.657626
+v 1.112486 0.516214 0.671187
+v 1.121593 0.517345 0.680677
+v 1.130801 0.518644 0.685730
+v 1.139754 0.520061 0.686152
+v 1.148110 0.521541 0.681928
+v 1.155546 0.523028 0.673218
+v 1.161777 0.524464 0.660359
+v 1.166564 0.525795 0.643844
+v 1.169723 0.526968 0.624308
+v 1.171132 0.527939 0.602501
+v 1.170738 0.528671 0.579262
+v 1.082752 0.509071 0.594971
+v 1.087265 0.504343 0.613824
+v 1.093197 0.500282 0.630809
+v 1.100320 0.497045 0.645275
+v 1.108361 0.494756 0.656664
+v 1.117010 0.493502 0.664540
+v 1.125934 0.493333 0.668599
+v 1.134793 0.494254 0.668686
+v 1.143243 0.496230 0.664797
+v 1.150962 0.499185 0.657081
+v 1.157652 0.503006 0.645836
+v 1.163056 0.507546 0.631493
+v 1.166967 0.512630 0.614604
+v 1.169234 0.518063 0.595817
+v 1.169770 0.523636 0.575855
+v 1.168554 0.529135 0.555484
+v 1.081705 0.504242 0.590787
+v 1.085210 0.494870 0.605618
+v 1.090214 0.486531 0.618897
+v 1.096524 0.479543 0.630113
+v 1.103896 0.474175 0.638836
+v 1.112049 0.470634 0.644730
+v 1.120669 0.469056 0.647569
+v 1.129423 0.469502 0.647243
+v 1.137977 0.471954 0.643766
+v 1.146002 0.476318 0.637271
+v 1.153188 0.482426 0.628007
+v 1.159260 0.490044 0.616331
+v 1.163984 0.498879 0.602691
+v 1.167179 0.508591 0.587611
+v 1.168722 0.518807 0.571672
+v 1.080618 0.499804 0.585989
+v 1.083079 0.486166 0.596206
+v 1.087120 0.473894 0.605233
+v 1.092585 0.463459 0.612722
+v 1.099265 0.455263 0.618386
+v 1.106903 0.449620 0.622008
+v 1.115206 0.446748 0.623447
+v 1.123853 0.446756 0.622649
+v 1.132514 0.449645 0.619645
+v 1.140856 0.455303 0.614549
+v 1.148556 0.463513 0.607558
+v 1.155321 0.473960 0.598941
+v 1.160889 0.486242 0.589027
+v 1.165047 0.499886 0.578200
+v 1.167636 0.514370 0.566874
+v 1.079534 0.495929 0.580761
+v 1.080952 0.478564 0.585950
+v 1.084032 0.462857 0.590343
+v 1.088656 0.449412 0.593771
+v 1.094645 0.438745 0.596102
+v 1.101769 0.431267 0.597247
+v 1.109755 0.427264 0.597161
+v 1.118297 0.426891 0.595849
+v 1.127064 0.430161 0.593359
+v 1.135722 0.436950 0.589789
+v 1.143936 0.446996 0.585274
+v 1.151392 0.459913 0.579990
+v 1.157802 0.475205 0.574138
+v 1.162921 0.492284 0.567944
+v 1.166551 0.510494 0.561645
+v 1.078494 0.492764 0.575303
+v 1.078912 0.472356 0.575244
+v 1.081071 0.453845 0.574800
+v 1.084886 0.437942 0.573988
+v 1.090213 0.425258 0.572840
+v 1.096845 0.416280 0.571399
+v 1.104527 0.411354 0.569722
+v 1.112966 0.410669 0.567871
+v 1.121836 0.414252 0.565919
+v 1.130797 0.421963 0.563941
+v 1.139504 0.433508 0.562012
+v 1.147622 0.448443 0.560207
+v 1.154841 0.466193 0.558594
+v 1.160881 0.486077 0.557237
+v 1.165511 0.507330 0.556187
+v 1.077538 0.490432 0.569825
+v 1.077038 0.467781 0.564498
+v 1.078349 0.447204 0.559200
+v 1.081422 0.429489 0.554133
+v 1.086139 0.415318 0.549493
+v 1.092318 0.405236 0.545458
+v 1.099723 0.399630 0.542182
+v 1.108067 0.398715 0.539792
+v 1.117031 0.402527 0.538380
+v 1.126271 0.410919 0.537999
+v 1.135431 0.423569 0.538665
+v 1.144158 0.439990 0.540352
+v 1.152119 0.459552 0.542995
+v 1.159006 0.481502 0.546492
+v 1.164556 0.504997 0.550709
+v 1.076704 0.489022 0.564537
+v 1.075400 0.465016 0.554127
+v 1.075972 0.443188 0.544143
+v 1.078396 0.424378 0.534970
+v 1.082581 0.409308 0.526959
+v 1.088365 0.398558 0.520419
+v 1.095526 0.392541 0.515602
+v 1.103788 0.391487 0.512691
+v 1.112834 0.395438 0.511799
+v 1.122317 0.404242 0.512961
+v 1.131873 0.417559 0.516131
+v 1.141132 0.434879 0.521188
+v 1.149742 0.455536 0.527938
+v 1.157369 0.478736 0.536121
+v 1.163721 0.503587 0.545422
+v 1.076022 0.488588 0.559644
+v 1.074063 0.464165 0.544528
+v 1.074030 0.441953 0.530208
+v 1.075925 0.422806 0.517234
+v 1.079675 0.407460 0.506104
+v 1.085136 0.396504 0.497246
+v 1.092098 0.390360 0.491001
+v 1.100293 0.389264 0.487609
+v 1.109407 0.393258 0.487199
+v 1.119088 0.402188 0.489788
+v 1.128966 0.415711 0.495276
+v 1.138661 0.433307 0.503452
+v 1.147800 0.454301 0.514003
+v 1.156031 0.477885 0.526522
+v 1.163039 0.503154 0.540528
+v 1.075519 0.489147 0.555333
+v 1.073077 0.465262 0.536071
+v 1.072599 0.443545 0.517931
+v 1.074103 0.424833 0.501607
+v 1.077533 0.409843 0.487729
+v 1.082756 0.399153 0.476829
+v 1.089571 0.393172 0.469326
+v 1.097716 0.392131 0.465509
+v 1.106879 0.396069 0.465524
+v 1.116708 0.404836 0.469371
+v 1.126824 0.418094 0.476901
+v 1.136839 0.435334 0.487826
+v 1.146368 0.455893 0.501725
+v 1.155045 0.478982 0.518065
+v 1.162536 0.503713 0.536217
+v 1.079832 0.514284 0.574974
+v 1.075215 0.490678 0.551769
+v 1.072480 0.468264 0.529081
+v 1.071732 0.447905 0.507782
+v 1.073001 0.430381 0.488690
+v 1.076236 0.416367 0.472540
+v 1.081315 0.406402 0.459953
+v 1.088042 0.400867 0.451410
+v 1.096157 0.399977 0.447242
+v 1.105350 0.403765 0.447608
+v 1.115268 0.412085 0.452494
+v 1.125528 0.424618 0.461712
+v 1.135737 0.440882 0.474909
+v 1.145502 0.460253 0.491576
+v 1.154449 0.481985 0.511074
+v 1.162232 0.505244 0.532653
+v 1.075121 0.493121 0.549090
+v 1.072296 0.473057 0.523825
+v 1.071465 0.454863 0.500152
+v 1.072660 0.439237 0.478980
+v 1.075836 0.426781 0.461122
+v 1.080870 0.417973 0.447265
+v 1.087569 0.413151 0.437941
+v 1.095675 0.412501 0.433509
+v 1.104878 0.416048 0.434139
+v 1.114823 0.423656 0.439806
+v 1.125127 0.435031 0.450294
+v 1.135396 0.449738 0.465198
+v 1.145234 0.467211 0.483947
+v 1.154264 0.486778 0.505819
+v 1.162138 0.507687 0.529974
+v 1.070255 0.396948 0.582602
+v 1.067545 0.380021 0.555711
+v 1.066820 0.364717 0.530538
+v 1.068109 0.351625 0.508052
+v 1.071361 0.341249 0.489116
+v 1.076452 0.333986 0.474457
+v 1.083186 0.330116 0.464640
+v 1.091304 0.329787 0.460041
+v 1.100495 0.333013 0.460838
+v 1.110404 0.339669 0.466999
+v 1.120652 0.349499 0.478287
+v 1.130845 0.362126 0.494270
+v 1.140590 0.377065 0.514333
+v 1.149514 0.393741 0.537704
+v 1.157272 0.411514 0.563486
+v 1.070584 0.400904 0.581962
+v 1.068190 0.387780 0.554457
+v 1.067757 0.375982 0.528718
+v 1.069301 0.365962 0.505735
+v 1.072763 0.358107 0.486392
+v 1.078010 0.352718 0.471431
+v 1.084840 0.350001 0.461427
+v 1.092991 0.350062 0.456765
+v 1.102149 0.352899 0.457625
+v 1.111962 0.358401 0.463972
+v 1.122055 0.366358 0.475564
+v 1.132037 0.376463 0.491954
+v 1.141527 0.388330 0.512513
+v 1.150159 0.401500 0.536450
+v 1.157601 0.415469 0.562847
+v 1.071110 0.405401 0.582401
+v 1.069221 0.396601 0.555316
+v 1.069254 0.388788 0.529966
+v 1.071206 0.382261 0.507323
+v 1.075003 0.377273 0.488258
+v 1.080499 0.374013 0.473505
+v 1.087482 0.372609 0.463629
+v 1.095685 0.373113 0.459010
+v 1.104791 0.375506 0.459827
+v 1.114451 0.379697 0.466046
+v 1.124295 0.385523 0.477430
+v 1.133942 0.392762 0.493541
+v 1.143024 0.401136 0.513760
+v 1.151190 0.410321 0.537310
+v 1.158127 0.419966 0.563285
+v 1.071812 0.410266 0.583899
+v 1.070598 0.406145 0.558255
+v 1.071253 0.402643 0.534232
+v 1.073750 0.399896 0.512753
+v 1.077995 0.398009 0.494644
+v 1.083823 0.397055 0.480600
+v 1.091011 0.397069 0.471161
+v 1.099283 0.398053 0.466690
+v 1.108320 0.399967 0.467359
+v 1.117776 0.402738 0.473142
+v 1.127286 0.406260 0.483816
+v 1.136486 0.410397 0.498972
+v 1.145023 0.414991 0.518027
+v 1.152567 0.419865 0.540249
+v 1.158829 0.424832 0.564783
+v 1.072663 0.415313 0.586400
+v 1.072268 0.416045 0.563161
+v 1.073677 0.417016 0.541354
+v 1.076836 0.418190 0.521818
+v 1.081623 0.419520 0.505303
+v 1.087855 0.420956 0.492444
+v 1.095291 0.422443 0.483735
+v 1.103646 0.423923 0.479510
+v 1.112600 0.425340 0.479932
+v 1.121807 0.426639 0.484985
+v 1.130914 0.427771 0.494475
+v 1.139572 0.428691 0.508037
+v 1.147447 0.429364 0.525149
+v 1.154237 0.429766 0.545154
+v 1.159680 0.429879 0.567284
+v 1.073631 0.420348 0.589807
+v 1.074167 0.425921 0.569845
+v 1.076434 0.431354 0.551058
+v 1.080345 0.436438 0.534169
+v 1.085749 0.440978 0.519826
+v 1.092439 0.444799 0.508581
+v 1.100157 0.447754 0.500866
+v 1.108608 0.449730 0.496976
+v 1.117466 0.450651 0.497063
+v 1.126391 0.450482 0.501122
+v 1.135040 0.449228 0.508998
+v 1.143080 0.446939 0.520387
+v 1.150204 0.443702 0.534853
+v 1.156135 0.439642 0.551839
+v 1.160648 0.434914 0.570692
+v 1.074678 0.425177 0.593991
+v 1.076222 0.435393 0.578051
+v 1.079417 0.445106 0.562971
+v 1.084141 0.453940 0.549331
+v 1.090213 0.461558 0.537655
+v 1.097399 0.467667 0.528391
+v 1.105423 0.472030 0.521896
+v 1.113977 0.474482 0.518419
+v 1.122732 0.474928 0.518093
+v 1.131351 0.473350 0.520932
+v 1.139504 0.469809 0.526827
+v 1.146877 0.464442 0.535549
+v 1.153186 0.457454 0.546766
+v 1.158190 0.449114 0.560044
+v 1.161696 0.439742 0.574875
+v 1.075765 0.429614 0.598789
+v 1.078353 0.444098 0.587462
+v 1.082511 0.457742 0.576635
+v 1.088080 0.470024 0.566722
+v 1.094844 0.480471 0.558104
+v 1.102545 0.488681 0.551113
+v 1.110886 0.494339 0.546017
+v 1.119547 0.497228 0.543013
+v 1.128195 0.497236 0.542215
+v 1.136497 0.494364 0.543654
+v 1.144135 0.488721 0.547276
+v 1.150816 0.480525 0.552940
+v 1.156281 0.470090 0.560429
+v 1.160322 0.457818 0.569456
+v 1.162782 0.444180 0.579673
+v 1.076849 0.433490 0.604017
+v 1.080480 0.451700 0.597719
+v 1.085599 0.468779 0.591524
+v 1.092009 0.484071 0.585673
+v 1.099465 0.496988 0.580388
+v 1.107679 0.507034 0.575874
+v 1.116336 0.513823 0.572303
+v 1.125104 0.517093 0.569814
+v 1.133645 0.516720 0.568501
+v 1.141631 0.512717 0.568415
+v 1.148756 0.505239 0.569560
+v 1.154745 0.494572 0.571891
+v 1.159368 0.481127 0.575319
+v 1.162448 0.465420 0.579712
+v 1.163867 0.448055 0.584902
+v 1.077889 0.436655 0.609475
+v 1.082520 0.457908 0.608425
+v 1.088560 0.477791 0.607068
+v 1.095778 0.495541 0.605456
+v 1.103897 0.510476 0.603650
+v 1.112604 0.522021 0.601721
+v 1.121564 0.529733 0.599743
+v 1.130434 0.533315 0.597791
+v 1.138873 0.532630 0.595941
+v 1.146556 0.527704 0.594263
+v 1.153188 0.518726 0.592822
+v 1.158514 0.506042 0.591674
+v 1.162330 0.490139 0.590862
+v 1.164488 0.471628 0.590419
+v 1.164906 0.451220 0.590360
+v 1.078845 0.438987 0.614953
+v 1.084394 0.462482 0.619170
+v 1.091282 0.484433 0.622668
+v 1.099242 0.503994 0.625310
+v 1.107970 0.520415 0.626997
+v 1.117130 0.533065 0.627663
+v 1.126369 0.541457 0.627282
+v 1.135333 0.545269 0.625870
+v 1.143678 0.544354 0.623480
+v 1.151082 0.538748 0.620204
+v 1.157261 0.528666 0.616169
+v 1.161978 0.514495 0.611529
+v 1.165051 0.496781 0.606462
+v 1.166363 0.476203 0.601164
+v 1.165862 0.453552 0.595838
+v 1.079680 0.440397 0.620240
+v 1.086032 0.465248 0.629542
+v 1.093659 0.488448 0.637724
+v 1.102268 0.509105 0.644474
+v 1.111528 0.526425 0.649531
+v 1.121083 0.539742 0.652701
+v 1.130566 0.548546 0.653863
+v 1.139613 0.552497 0.652971
+v 1.147875 0.551443 0.650061
+v 1.155035 0.545426 0.645243
+v 1.160819 0.534676 0.638703
+v 1.165004 0.519606 0.630692
+v 1.167429 0.500796 0.621519
+v 1.168000 0.478969 0.611535
+v 1.166697 0.454962 0.601125
+v 1.080361 0.440831 0.625134
+v 1.087369 0.466099 0.639140
+v 1.095601 0.489683 0.651659
+v 1.104739 0.510677 0.662210
+v 1.114434 0.528274 0.670386
+v 1.124312 0.541797 0.675874
+v 1.133994 0.550726 0.678463
+v 1.143108 0.554720 0.678054
+v 1.151303 0.553624 0.674661
+v 1.158265 0.547480 0.668416
+v 1.163725 0.536524 0.659558
+v 1.167475 0.521178 0.648428
+v 1.169371 0.502031 0.635454
+v 1.169338 0.479819 0.621134
+v 1.167379 0.455396 0.606018
+v 1.080864 0.440271 0.629445
+v 1.088355 0.465002 0.647597
+v 1.097032 0.488091 0.663937
+v 1.106561 0.508650 0.677836
+v 1.116576 0.525890 0.688761
+v 1.126693 0.539148 0.696292
+v 1.136521 0.547915 0.700138
+v 1.145684 0.551853 0.700153
+v 1.153830 0.550812 0.696336
+v 1.160645 0.544831 0.688833
+v 1.165868 0.534141 0.677933
+v 1.169297 0.519151 0.664055
+v 1.170802 0.500439 0.647732
+v 1.170324 0.478722 0.629591
+v 1.167881 0.454837 0.610329
+v 1.081168 0.438741 0.633009
+v 1.088952 0.461999 0.654588
+v 1.097898 0.483732 0.674086
+v 1.107664 0.503102 0.690753
+v 1.117873 0.519366 0.703950
+v 1.128133 0.531899 0.713168
+v 1.138050 0.540220 0.718054
+v 1.147243 0.544007 0.718420
+v 1.155359 0.543117 0.714252
+v 1.162085 0.537583 0.705710
+v 1.167164 0.527617 0.693122
+v 1.170400 0.513603 0.676972
+v 1.171668 0.496080 0.657880
+v 1.170921 0.475720 0.636581
+v 1.168186 0.453306 0.613893
+v 1.081262 0.436297 0.635688
+v 1.089136 0.457207 0.659843
+v 1.098166 0.476773 0.681716
+v 1.108004 0.494246 0.700464
+v 1.118273 0.508953 0.715369
+v 1.128578 0.520328 0.725856
+v 1.138523 0.527936 0.731524
+v 1.147725 0.531483 0.732153
+v 1.155831 0.530833 0.727721
+v 1.162531 0.526012 0.718397
+v 1.167565 0.517203 0.704540
+v 1.170740 0.504747 0.686682
+v 1.171936 0.489121 0.665510
+v 1.171105 0.470927 0.641837
+v 1.168280 0.450863 0.616572
+v 1.081143 0.433035 0.637380
+v 1.088901 0.450808 0.663162
+v 1.097825 0.467484 0.686533
+v 1.107570 0.482422 0.706595
+v 1.117763 0.495050 0.722578
+v 1.128011 0.504880 0.733867
+v 1.137920 0.511536 0.740028
+v 1.147111 0.514762 0.740824
+v 1.155229 0.514433 0.736226
+v 1.161963 0.510563 0.726409
+v 1.167054 0.503300 0.711750
+v 1.170306 0.492923 0.692814
+v 1.171595 0.479832 0.670327
+v 1.170870 0.464528 0.645155
+v 1.168160 0.447601 0.618264
+v 1.080813 0.429080 0.638019
+v 1.088256 0.443049 0.664415
+v 1.096888 0.456219 0.688353
+v 1.106378 0.468085 0.708912
+v 1.116360 0.478191 0.725302
+v 1.126452 0.486148 0.736894
+v 1.136266 0.491650 0.743241
+v 1.145424 0.494486 0.744100
+v 1.153575 0.494548 0.739439
+v 1.160405 0.491831 0.729435
+v 1.165652 0.486442 0.714474
+v 1.169114 0.478587 0.695130
+v 1.170658 0.468567 0.672148
+v 1.170224 0.456769 0.646409
+v 1.167831 0.443645 0.618903
+v 1.080288 0.424583 0.637581
+v 1.087225 0.434228 0.663556
+v 1.095391 0.443413 0.687106
+v 1.104473 0.451786 0.707324
+v 1.114120 0.459026 0.723435
+v 1.123963 0.464852 0.734819
+v 1.133624 0.469043 0.741039
+v 1.142730 0.471436 0.741855
+v 1.150933 0.471940 0.737237
+v 1.157916 0.470535 0.727361
+v 1.163412 0.467276 0.712607
+v 1.167209 0.462288 0.693543
+v 1.169161 0.455761 0.670900
+v 1.169194 0.447948 0.645550
+v 1.167305 0.439148 0.618465
+v 1.079586 0.419717 0.636083
+v 1.085848 0.424684 0.660617
+v 1.093392 0.429557 0.682839
+v 1.101928 0.434151 0.701894
+v 1.111129 0.438289 0.717050
+v 1.120639 0.441811 0.727724
+v 1.130095 0.444582 0.733507
+v 1.139132 0.446496 0.734175
+v 1.147404 0.447480 0.729704
+v 1.154592 0.447494 0.720266
+v 1.160420 0.446540 0.706222
+v 1.164664 0.444653 0.688112
+v 1.167162 0.441905 0.666633
+v 1.167817 0.438404 0.642611
+v 1.166603 0.434283 0.616967
+v 1.078735 0.414670 0.633582
+v 1.084178 0.414783 0.655711
+v 1.090968 0.415185 0.675717
+v 1.098843 0.415858 0.692829
+v 1.107500 0.416778 0.706391
+v 1.116608 0.417910 0.715880
+v 1.125815 0.419209 0.720933
+v 1.134769 0.420626 0.721356
+v 1.143124 0.422106 0.717131
+v 1.150560 0.423593 0.708422
+v 1.156792 0.425029 0.695562
+v 1.161579 0.426359 0.679047
+v 1.164738 0.427533 0.659511
+v 1.166147 0.428504 0.637705
+v 1.165752 0.429236 0.614466
+v 1.077767 0.409635 0.630174
+v 1.082279 0.404907 0.649027
+v 1.088211 0.400847 0.666013
+v 1.095334 0.397610 0.680478
+v 1.103375 0.395321 0.691868
+v 1.112024 0.394067 0.699743
+v 1.120949 0.393898 0.703802
+v 1.129807 0.394819 0.703889
+v 1.138258 0.396795 0.700000
+v 1.145976 0.399750 0.692285
+v 1.152666 0.403571 0.681040
+v 1.158070 0.408111 0.666697
+v 1.161981 0.413195 0.649807
+v 1.164248 0.418628 0.631021
+v 1.164784 0.424201 0.611058
+v 1.163568 0.429700 0.590688
+v 1.076719 0.404806 0.625991
+v 1.080225 0.395435 0.640822
+v 1.085228 0.387095 0.654100
+v 1.091538 0.380107 0.665316
+v 1.098911 0.374740 0.674039
+v 1.107064 0.371199 0.679933
+v 1.115683 0.369621 0.682772
+v 1.124438 0.370067 0.682447
+v 1.132992 0.372519 0.678970
+v 1.141016 0.376882 0.672475
+v 1.148202 0.382991 0.663211
+v 1.154274 0.390609 0.651535
+v 1.158998 0.399443 0.637895
+v 1.162193 0.409156 0.622815
+v 1.163736 0.419372 0.606875
+v 1.075633 0.400369 0.621193
+v 1.078093 0.386731 0.631410
+v 1.082134 0.374459 0.640436
+v 1.087599 0.364024 0.647926
+v 1.094279 0.355828 0.653590
+v 1.101918 0.350185 0.657211
+v 1.110220 0.347313 0.658651
+v 1.118868 0.347321 0.657853
+v 1.127529 0.350210 0.654848
+v 1.135870 0.355868 0.649753
+v 1.143571 0.364078 0.642762
+v 1.150335 0.374525 0.634144
+v 1.155904 0.386807 0.624231
+v 1.160062 0.400451 0.613403
+v 1.162650 0.414935 0.602077
+v 1.074548 0.396493 0.615964
+v 1.075967 0.379129 0.621154
+v 1.079047 0.363422 0.625547
+v 1.083670 0.349977 0.628975
+v 1.089659 0.339310 0.631306
+v 1.096784 0.331832 0.632451
+v 1.104770 0.327829 0.632365
+v 1.113311 0.327456 0.631052
+v 1.122079 0.330726 0.628563
+v 1.130736 0.337515 0.624992
+v 1.138950 0.347561 0.620478
+v 1.146406 0.360478 0.615193
+v 1.152816 0.375770 0.609341
+v 1.157935 0.392849 0.603147
+v 1.161566 0.411059 0.596849
+v 1.073509 0.393329 0.610506
+v 1.073927 0.372921 0.610447
+v 1.076085 0.354410 0.610003
+v 1.079901 0.338507 0.609192
+v 1.085227 0.325823 0.608044
+v 1.091859 0.316845 0.606603
+v 1.099542 0.311919 0.604925
+v 1.107980 0.311234 0.603075
+v 1.116851 0.314816 0.601123
+v 1.125811 0.322528 0.599144
+v 1.134518 0.334073 0.597215
+v 1.142637 0.349008 0.595410
+v 1.149855 0.366758 0.593798
+v 1.155895 0.386641 0.592441
+v 1.160526 0.407894 0.591390
+v 1.072553 0.390997 0.605028
+v 1.072052 0.368346 0.599702
+v 1.073364 0.347768 0.594404
+v 1.076437 0.330054 0.589337
+v 1.081154 0.315883 0.584697
+v 1.087333 0.305801 0.580661
+v 1.094737 0.300195 0.577386
+v 1.103082 0.299280 0.574996
+v 1.112046 0.303092 0.573583
+v 1.121285 0.311484 0.573203
+v 1.130445 0.324134 0.573869
+v 1.139173 0.340555 0.575555
+v 1.147133 0.360116 0.578198
+v 1.154021 0.382067 0.581695
+v 1.159570 0.405562 0.585913
+v 1.071718 0.389587 0.599741
+v 1.070414 0.365580 0.589331
+v 1.070986 0.343753 0.579347
+v 1.073411 0.324943 0.570173
+v 1.077595 0.309873 0.562163
+v 1.083379 0.299123 0.555623
+v 1.090540 0.293106 0.550805
+v 1.098802 0.292052 0.547894
+v 1.107849 0.296003 0.547003
+v 1.117332 0.304807 0.548164
+v 1.126887 0.318124 0.551335
+v 1.136147 0.335444 0.556392
+v 1.144756 0.356101 0.563141
+v 1.152383 0.379301 0.571324
+v 1.158735 0.404152 0.580625
+v 1.071036 0.389153 0.594848
+v 1.069077 0.364730 0.579732
+v 1.069044 0.342518 0.565412
+v 1.070939 0.323371 0.552438
+v 1.074690 0.308025 0.541308
+v 1.080150 0.297069 0.532450
+v 1.087112 0.290925 0.526205
+v 1.095307 0.289829 0.522812
+v 1.104421 0.293823 0.522402
+v 1.114103 0.302752 0.524991
+v 1.123981 0.316275 0.530479
+v 1.133675 0.333872 0.538656
+v 1.142814 0.354866 0.549206
+v 1.151046 0.378450 0.561725
+v 1.158053 0.403718 0.575732
+v 1.070533 0.389712 0.590536
+v 1.068091 0.365826 0.571275
+v 1.067613 0.344110 0.553134
+v 1.069118 0.325398 0.536811
+v 1.072547 0.310408 0.522933
+v 1.077770 0.299718 0.512033
+v 1.084585 0.293737 0.504530
+v 1.092731 0.292696 0.500713
+v 1.101894 0.296634 0.500728
+v 1.111722 0.305401 0.504574
+v 1.121838 0.318659 0.512105
+v 1.131854 0.335899 0.523029
+v 1.141383 0.356458 0.536929
+v 1.150059 0.379547 0.553268
+v 1.157551 0.404278 0.571421
+v 1.074846 0.414849 0.610178
+v 1.070229 0.391243 0.586972
+v 1.067494 0.368829 0.564284
+v 1.066747 0.348469 0.542985
+v 1.068015 0.330946 0.523894
+v 1.071251 0.316932 0.507744
+v 1.076329 0.306967 0.495156
+v 1.083056 0.301432 0.486614
+v 1.091172 0.300542 0.482445
+v 1.100365 0.304330 0.482811
+v 1.110282 0.312650 0.487697
+v 1.120542 0.325183 0.496916
+v 1.130751 0.341447 0.510112
+v 1.140516 0.360817 0.526780
+v 1.149463 0.382550 0.546278
+v 1.157247 0.405808 0.567857
+v 1.070135 0.393686 0.584293
+v 1.067310 0.373622 0.559029
+v 1.066479 0.355428 0.535356
+v 1.067675 0.339802 0.514183
+v 1.070850 0.327346 0.496325
+v 1.075884 0.318537 0.482468
+v 1.082583 0.313716 0.473145
+v 1.090690 0.313066 0.468712
+v 1.099892 0.316613 0.469342
+v 1.109837 0.324221 0.475010
+v 1.120142 0.335596 0.485497
+v 1.130410 0.350303 0.500402
+v 1.140249 0.367776 0.519150
+v 1.149279 0.387342 0.541022
+v 1.157153 0.408252 0.565178
+vn -0.672781 -0.204535 -0.710959
+vn -0.898373 -0.088931 -0.430067
+vn -0.876644 0.072756 -0.475539
+vn -0.997467 0.068545 0.018494
+vn -0.993500 0.086367 0.074129
+vn -0.992523 0.102908 0.065584
+vn 0.941404 -0.153844 -0.300119
+vn 0.908231 -0.176580 -0.379315
+vn 0.937925 -0.100772 -0.331828
+vn -0.152104 -0.310160 -0.938414
+vn -0.198889 -0.023286 -0.979736
+vn -0.997772 0.047273 -0.046663
+vn -0.994812 0.101535 0.001404
+vn 0.962035 -0.135166 -0.236976
+vn 0.961150 -0.101779 -0.256539
+vn 0.412458 -0.301157 -0.859737
+vn 0.343089 -0.060488 -0.937315
+vn -0.991333 0.019440 -0.129917
+vn -0.992401 0.099338 -0.072451
+vn 0.976043 -0.118656 -0.182318
+vn 0.976135 -0.101993 -0.191595
+vn 0.719718 -0.248726 -0.648152
+vn 0.676351 -0.081973 -0.731986
+vn -0.968688 -0.021241 -0.247261
+vn -0.981689 0.095645 -0.164678
+vn 0.848048 -0.206641 -0.487930
+vn 0.827662 -0.093204 -0.553392
+vn -0.952849 0.088565 -0.290139
+vn 0.899289 -0.098392 -0.426069
+vn -0.665792 0.034822 -0.745293
+vn -0.846431 0.208655 -0.489853
+vn -0.991119 0.118686 0.059786
+vn 0.933683 -0.046907 -0.354991
+vn -0.228523 0.209021 -0.950804
+vn -0.991028 0.133061 -0.010193
+vn 0.960173 -0.068239 -0.270821
+vn 0.277139 0.153752 -0.948424
+vn -0.984832 0.148473 -0.089450
+vn 0.976409 -0.085635 -0.198157
+vn 0.626759 0.080386 -0.775018
+vn -0.968413 0.165899 -0.185949
+vn 0.802332 0.021424 -0.596423
+vn -0.931425 0.186224 -0.312632
+vn 0.888028 -0.018738 -0.459365
+vn 0.776208 0.130039 -0.616901
+vn -0.908689 0.270241 -0.318155
+vn 0.876247 0.058138 -0.478256
+vn -0.643361 0.224097 -0.732017
+vn -0.815516 0.319437 -0.482528
+vn -0.989441 0.133274 0.056642
+vn 0.929441 0.005188 -0.368877
+vn -0.245003 0.383892 -0.890255
+vn -0.986602 0.162206 -0.016449
+vn 0.959471 -0.035951 -0.279458
+vn 0.222266 0.328990 -0.917783
+vn -0.976226 0.193304 -0.097964
+vn 0.976836 -0.070193 -0.202002
+vn 0.579180 0.226264 -0.783135
+vn -0.953795 0.228553 -0.194952
+vn 0.977538 -0.056124 -0.203040
+vn 0.539903 0.351177 -0.764946
+vn -0.939543 0.282876 -0.192877
+vn 0.753441 0.227729 -0.616779
+vn -0.887509 0.341136 -0.309702
+vn 0.866146 0.128880 -0.482833
+vn -0.617603 0.368267 -0.694906
+vn -0.788049 0.409223 -0.459883
+vn -0.987640 0.146306 0.056093
+vn 0.926176 0.053438 -0.373211
+vn -0.252632 0.515458 -0.818781
+vn -0.981933 0.188269 -0.017457
+vn 0.959319 -0.006195 -0.282235
+vn 0.181738 0.468245 -0.864681
+vn -0.967498 0.232887 -0.098361
+vn -0.977447 0.210639 -0.013398
+vn 0.960021 0.019868 -0.279122
+vn 0.156011 0.579455 -0.799890
+vn -0.959441 0.266671 -0.091220
+vn 0.978515 -0.043947 -0.201361
+vn 0.512742 0.455367 -0.727805
+vn -0.926969 0.328654 -0.180822
+vn 0.737602 0.311899 -0.598865
+vn -0.869625 0.399915 -0.289468
+vn 0.859706 0.190771 -0.473769
+vn -0.594195 0.479232 -0.645924
+vn -0.765801 0.482040 -0.425611
+vn -0.985809 0.157445 0.058077
+vn 0.924833 0.095828 -0.368084
+vn -0.254433 0.617847 -0.743980
+vn -0.575182 0.566820 -0.589770
+vn -0.749413 0.541063 -0.381573
+vn -0.984039 0.166540 0.062349
+vn 0.926054 0.130741 -0.353923
+vn -0.252022 0.701041 -0.667074
+vn -0.973418 0.228889 -0.004578
+vn 0.961852 0.041292 -0.270394
+vn 0.144475 0.670217 -0.727958
+vn -0.952635 0.294168 -0.076998
+vn 0.979766 -0.034028 -0.197089
+vn 0.499863 0.540849 -0.676443
+vn -0.916837 0.365856 -0.159734
+vn 0.731132 0.381237 -0.565752
+vn -0.855892 0.447584 -0.258950
+vn 0.858486 0.241798 -0.452193
+vn 0.735557 0.435041 -0.519272
+vn -0.738945 0.588336 -0.328318
+vn 0.863369 0.280618 -0.419263
+vn -0.560869 0.637928 -0.527665
+vn -0.551073 0.696860 -0.458968
+vn -0.982421 0.173345 0.068819
+vn 0.930296 0.157018 -0.331462
+vn -0.246101 0.771630 -0.586505
+vn -0.970061 0.242653 0.008667
+vn 0.964843 0.057344 -0.256386
+vn 0.146641 0.746055 -0.649495
+vn -0.947386 0.315043 -0.056307
+vn 0.981323 -0.026582 -0.190435
+vn 0.502518 0.609516 -0.613117
+vn -0.909635 0.394391 -0.130345
+vn 0.968993 0.067476 -0.237648
+vn 0.162847 0.810358 -0.562792
+vn -0.846767 0.484756 -0.219001
+vn -0.842189 0.511643 -0.169958
+vn 0.521378 0.662160 -0.538224
+vn -0.734153 0.624866 -0.265572
+vn 0.751366 0.472518 -0.460555
+vn -0.545396 0.746117 -0.381878
+vn -0.967437 0.251656 0.026002
+vn 0.874599 0.306070 -0.375988
+vn -0.236579 0.833583 -0.499130
+vn -0.943876 0.328959 -0.029603
+vn 0.937498 0.173742 -0.301431
+vn -0.905423 0.414075 -0.093265
+vn 0.947325 0.180242 -0.264657
+vn -0.222541 0.888974 -0.400189
+vn -0.904111 0.424451 -0.048921
+vn 0.983123 -0.021821 -0.181585
+vn 0.974059 0.071322 -0.214667
+vn 0.194128 0.864284 -0.464003
+vn -0.841853 0.527909 -0.111942
+vn 0.556658 0.697928 -0.450545
+vn -0.734581 0.650655 -0.192328
+vn 0.778161 0.492233 -0.390027
+vn -0.543321 0.786554 -0.293374
+vn -0.980987 0.177831 0.077303
+vn -0.965606 0.255593 0.046937
+vn 0.891568 0.317057 -0.323283
+vn -0.941984 0.335551 0.002533
+vn -0.979766 0.179785 0.087619
+vn -0.964476 0.254311 0.071078
+vn 0.912961 0.312510 -0.262276
+vn -0.202246 0.937559 -0.282876
+vn -0.941557 0.334452 0.039460
+vn 0.958953 0.175939 -0.222266
+vn -0.905209 0.424940 0.002136
+vn 0.985107 -0.019868 -0.170721
+vn 0.979736 0.068575 -0.188147
+vn 0.242317 0.905911 -0.347209
+vn -0.845149 0.532579 -0.044771
+vn 0.607868 0.713858 -0.347667
+vn -0.739555 0.664510 -0.106906
+vn 0.814203 0.492172 -0.307871
+vn -0.544053 0.817408 -0.189245
+vn -0.747826 0.663808 -0.007324
+vn 0.856349 0.469527 -0.214789
+vn -0.546098 0.835261 -0.063662
+vn -0.978759 0.179113 0.099521
+vn -0.963897 0.247597 0.097720
+vn 0.936521 0.291574 -0.194586
+vn -0.172582 0.975341 -0.137455
+vn -0.942167 0.325297 0.080508
+vn 0.971221 0.160680 -0.175665
+vn -0.907987 0.414686 0.059420
+vn 0.987182 -0.020905 -0.158086
+vn 0.985473 0.059206 -0.159062
+vn 0.309305 0.928678 -0.204505
+vn -0.851039 0.524094 0.031678
+vn 0.672811 0.704062 -0.227058
+vn 0.394635 0.918393 -0.027894
+vn -0.857936 0.500168 0.117161
+vn 0.746147 0.659902 -0.087893
+vn -0.757225 0.644093 0.108249
+vn 0.899625 0.421735 -0.113041
+vn -0.546434 0.832606 0.090152
+vn -0.977935 0.175726 0.112766
+vn -0.963652 0.235450 0.126164
+vn 0.959380 0.254067 -0.122593
+vn -0.129063 0.990448 0.048250
+vn -0.943266 0.307718 0.124638
+vn 0.982727 0.134770 -0.126621
+vn -0.911496 0.392743 0.121952
+vn 0.989227 -0.025056 -0.144139
+vn 0.990753 0.043428 -0.128483
+vn 0.992035 0.099155 -0.077273
+vn -0.067629 0.956816 0.282693
+vn -0.914487 0.358104 0.188299
+vn 0.991058 -0.032136 -0.129307
+vn 0.994964 0.021851 -0.097629
+vn 0.491501 0.851314 0.183416
+vn -0.863643 0.457991 0.210425
+vn 0.817621 0.572069 0.064760
+vn -0.764183 0.598590 0.240181
+vn 0.937468 0.347911 -0.007447
+vn -0.539506 0.794885 0.277505
+vn -0.977294 0.169591 0.126957
+vn -0.963500 0.217780 0.155644
+vn 0.978332 0.200964 -0.049623
+vn -0.944243 0.281503 0.170690
+vn -0.976745 0.160680 0.141728
+vn -0.963225 0.194769 0.185003
+vn 0.990692 0.134587 0.019929
+vn -0.517350 0.699820 0.492477
+vn -0.944487 0.246529 0.217017
+vn 0.998016 0.055269 -0.030091
+vn 0.009095 0.835170 0.549883
+vn -0.915586 0.309976 0.256050
+vn 0.992553 -0.042146 -0.114078
+vn 0.997681 -0.004883 -0.067843
+vn 0.583148 0.701956 0.408826
+vn -0.865474 0.394910 0.308145
+vn 0.873012 0.437117 0.216193
+vn -0.763482 0.519150 0.384075
+vn 0.963469 0.250710 0.093905
+vn -0.860775 0.309885 0.403668
+vn 0.973693 0.137883 0.181341
+vn -0.749626 0.400525 0.526872
+vn -0.976348 0.148991 0.156529
+vn -0.962737 0.166814 0.212714
+vn 0.994934 0.059145 0.081149
+vn -0.474044 0.529954 0.703116
+vn -0.943602 0.203375 0.261116
+vn 0.999908 0.005371 0.012055
+vn 0.087130 0.605884 0.790735
+vn -0.913724 0.248634 0.321360
+vn 0.993530 -0.054872 -0.099124
+vn 0.998505 -0.035646 -0.040925
+vn 0.647694 0.470229 0.599414
+vn 0.900327 0.267037 0.343608
+vn 0.672781 0.204535 0.710959
+vn -0.908231 0.176580 0.379345
+vn 0.968688 0.021241 0.247261
+vn -0.848048 0.206641 0.487960
+vn 0.991333 -0.019440 0.129917
+vn -0.719718 0.248726 0.648152
+vn -0.976104 0.134678 0.170446
+vn -0.976043 0.118625 0.182318
+vn 0.997772 -0.047273 0.046663
+vn -0.412458 0.301126 0.859737
+vn -0.962035 0.135166 0.236976
+vn 0.997467 -0.068545 -0.018494
+vn 0.152104 0.310160 0.938414
+vn -0.941404 0.153844 0.300119
+vn 0.993866 -0.069948 -0.085452
+vn 0.993469 -0.086398 -0.074099
+vn 0.994812 -0.101505 -0.001434
+vn 0.198889 0.023316 0.979736
+vn -0.937925 0.100772 0.331828
+vn 0.992523 -0.102908 -0.065554
+vn 0.898373 0.088931 0.430067
+vn 0.876644 -0.072756 0.475539
+vn -0.899289 0.098392 0.426069
+vn 0.952849 -0.088565 0.290139
+vn -0.827662 0.093204 0.553392
+vn 0.981689 -0.095645 0.164678
+vn -0.676351 0.081973 0.731986
+vn -0.976135 0.102023 0.191595
+vn 0.992401 -0.099338 0.072481
+vn -0.343089 0.060488 0.937315
+vn -0.961150 0.101749 0.256539
+vn 0.984832 -0.148503 0.089450
+vn -0.277139 -0.153752 0.948424
+vn -0.960173 0.068209 0.270821
+vn 0.991028 -0.133061 0.010193
+vn 0.665822 -0.034822 0.745293
+vn 0.228523 -0.209021 0.950804
+vn -0.933683 0.046937 0.354991
+vn 0.991119 -0.118686 -0.059786
+vn 0.846431 -0.208625 0.489853
+vn -0.888028 0.018738 0.459365
+vn 0.931425 -0.186224 0.312632
+vn -0.802332 -0.021424 0.596454
+vn 0.968413 -0.165899 0.185949
+vn -0.626789 -0.080386 0.775018
+vn -0.976409 0.085665 0.198157
+vn 0.953795 -0.228523 0.194952
+vn -0.579180 -0.226264 0.783135
+vn -0.976836 0.070193 0.201972
+vn 0.976226 -0.193304 0.097964
+vn -0.222236 -0.328990 0.917783
+vn -0.959471 0.035951 0.279458
+vn 0.986602 -0.162206 0.016449
+vn 0.643361 -0.224097 0.732017
+vn 0.245003 -0.383892 0.890255
+vn -0.929441 -0.005188 0.368908
+vn 0.989441 -0.133274 -0.056642
+vn 0.815516 -0.319437 0.482528
+vn -0.876247 -0.058168 0.478256
+vn 0.908689 -0.270241 0.318155
+vn -0.776208 -0.130039 0.616901
+vn -0.866146 -0.128880 0.482833
+vn 0.887509 -0.341136 0.309702
+vn -0.753441 -0.227729 0.616779
+vn 0.939543 -0.282876 0.192877
+vn -0.539872 -0.351177 0.764946
+vn -0.977538 0.056154 0.203040
+vn 0.967498 -0.232887 0.098361
+vn -0.181738 -0.468245 0.864681
+vn -0.959319 0.006195 0.282235
+vn 0.981933 -0.188269 0.017457
+vn 0.617573 -0.368267 0.694906
+vn 0.252632 -0.515458 0.818781
+vn -0.926176 -0.053438 0.373211
+vn 0.987640 -0.146275 -0.056093
+vn 0.788049 -0.409223 0.459883
+vn 0.594226 -0.479202 0.645924
+vn 0.254433 -0.617847 0.743980
+vn -0.924833 -0.095828 0.368084
+vn 0.985809 -0.157445 -0.058077
+vn 0.765801 -0.482040 0.425611
+vn -0.859706 -0.190741 0.473769
+vn 0.869625 -0.399915 0.289468
+vn -0.737602 -0.311899 0.598865
+vn 0.926969 -0.328654 0.180822
+vn -0.512742 -0.455367 0.727805
+vn -0.978515 0.043947 0.201361
+vn 0.959441 -0.266671 0.091220
+vn -0.156011 -0.579455 0.799890
+vn -0.960021 -0.019868 0.279122
+vn 0.977447 -0.210639 0.013398
+vn 0.952635 -0.294137 0.076998
+vn -0.144475 -0.670217 0.727958
+vn -0.961852 -0.041292 0.270394
+vn 0.973418 -0.228889 0.004578
+vn 0.575182 -0.566820 0.589770
+vn 0.252022 -0.701041 0.667074
+vn -0.926084 -0.130741 0.353923
+vn 0.984039 -0.166540 -0.062349
+vn 0.749413 -0.541063 0.381573
+vn -0.858486 -0.241798 0.452193
+vn 0.855892 -0.447584 0.258950
+vn -0.731132 -0.381237 0.565752
+vn 0.916837 -0.365856 0.159734
+vn -0.499863 -0.540849 0.676443
+vn -0.979766 0.033998 0.197089
+vn 0.909604 -0.394421 0.130345
+vn -0.502518 -0.609516 0.613117
+vn -0.981323 0.026582 0.190435
+vn 0.947386 -0.315043 0.056307
+vn -0.146641 -0.746055 0.649525
+vn -0.964843 -0.057314 0.256417
+vn 0.970061 -0.242653 -0.008667
+vn 0.560869 -0.637928 0.527665
+vn 0.246101 -0.771630 0.586505
+vn -0.930296 -0.157018 0.331462
+vn 0.982421 -0.173376 -0.068819
+vn 0.551073 -0.696860 0.458968
+vn -0.863369 -0.280618 0.419263
+vn 0.738945 -0.588336 0.328318
+vn -0.735527 -0.435041 0.519272
+vn -0.751396 -0.472488 0.460555
+vn 0.846767 -0.484756 0.219001
+vn 0.734153 -0.624866 0.265572
+vn -0.521378 -0.662160 0.538224
+vn 0.842189 -0.511673 0.169988
+vn -0.162816 -0.810389 0.562792
+vn -0.968993 -0.067476 0.237648
+vn 0.905423 -0.414075 0.093265
+vn -0.937498 -0.173742 0.301431
+vn 0.943876 -0.328959 0.029603
+vn 0.236549 -0.833583 0.499130
+vn -0.874599 -0.306070 0.375988
+vn 0.967467 -0.251625 -0.025971
+vn 0.545396 -0.746117 0.381878
+vn 0.222541 -0.888974 0.400189
+vn -0.891568 -0.317057 0.323283
+vn 0.980987 -0.177831 -0.077303
+vn 0.965606 -0.255593 -0.046968
+vn 0.543321 -0.786554 0.293374
+vn -0.778161 -0.492233 0.390027
+vn 0.734611 -0.650624 0.192328
+vn -0.556658 -0.697928 0.450545
+vn 0.841853 -0.527909 0.111942
+vn -0.194098 -0.864284 0.464003
+vn -0.983123 0.021821 0.181585
+vn -0.974059 -0.071322 0.214667
+vn 0.904111 -0.424451 0.048921
+vn -0.947325 -0.180242 0.264687
+vn 0.941984 -0.335551 -0.002533
+vn 0.905179 -0.424940 -0.002136
+vn 0.202246 -0.937559 0.282876
+vn -0.958953 -0.175939 0.222266
+vn 0.941557 -0.334452 -0.039491
+vn -0.912961 -0.312510 0.262276
+vn 0.979766 -0.179785 -0.087588
+vn 0.964476 -0.254311 -0.071078
+vn 0.544053 -0.817408 0.189245
+vn -0.814203 -0.492141 0.307871
+vn 0.739555 -0.664510 0.106906
+vn -0.607868 -0.713828 0.347697
+vn 0.845149 -0.532579 0.044771
+vn -0.242317 -0.905911 0.347209
+vn -0.985107 0.019868 0.170721
+vn -0.979736 -0.068575 0.188147
+vn 0.851039 -0.524094 -0.031678
+vn -0.309305 -0.928709 0.204505
+vn -0.987182 0.020905 0.158086
+vn -0.985473 -0.059206 0.159062
+vn 0.907987 -0.414686 -0.059420
+vn 0.172582 -0.975341 0.137455
+vn -0.971221 -0.160649 0.175665
+vn 0.942167 -0.325297 -0.080508
+vn -0.936521 -0.291574 0.194586
+vn 0.978759 -0.179113 -0.099521
+vn 0.963897 -0.247597 -0.097720
+vn 0.546098 -0.835261 0.063662
+vn -0.856349 -0.469527 0.214789
+vn 0.747826 -0.663808 0.007324
+vn -0.672811 -0.704062 0.227027
+vn 0.757225 -0.644093 -0.108249
+vn -0.746147 -0.659902 0.087893
+vn 0.857936 -0.500168 -0.117161
+vn -0.394635 -0.918393 0.027894
+vn -0.989227 0.025056 0.144108
+vn -0.990753 -0.043458 0.128483
+vn 0.911496 -0.392743 -0.121952
+vn 0.129063 -0.990448 -0.048250
+vn -0.982727 -0.134770 0.126621
+vn 0.943266 -0.307718 -0.124638
+vn -0.959380 -0.254067 0.122593
+vn 0.977935 -0.175695 -0.112766
+vn 0.963652 -0.235420 -0.126164
+vn 0.546434 -0.832606 -0.090152
+vn -0.899625 -0.421766 0.113010
+vn -0.978332 -0.200934 0.049623
+vn 0.977294 -0.169561 -0.126988
+vn 0.963500 -0.217780 -0.155614
+vn 0.539506 -0.794885 -0.277505
+vn -0.937468 -0.347911 0.007447
+vn 0.764183 -0.598590 -0.240181
+vn -0.817621 -0.572069 -0.064760
+vn 0.863643 -0.458022 -0.210425
+vn -0.491501 -0.851314 -0.183416
+vn -0.991058 0.032167 0.129276
+vn -0.994964 -0.021851 0.097598
+vn 0.914487 -0.358104 -0.188299
+vn 0.067629 -0.956816 -0.282693
+vn -0.992035 -0.099155 0.077273
+vn 0.944243 -0.281503 -0.170690
+vn -0.009095 -0.835170 -0.549883
+vn -0.998016 -0.055269 0.030091
+vn 0.944487 -0.246559 -0.217017
+vn 0.517350 -0.699820 -0.492477
+vn -0.990692 -0.134587 -0.019929
+vn 0.976745 -0.160680 -0.141728
+vn 0.963225 -0.194769 -0.185003
+vn -0.963469 -0.250710 -0.093905
+vn 0.763482 -0.519150 -0.384075
+vn -0.873012 -0.437117 -0.216193
+vn 0.865474 -0.394910 -0.308145
+vn -0.583148 -0.701956 -0.408826
+vn -0.992553 0.042146 0.114078
+vn -0.997681 0.004852 0.067843
+vn 0.915586 -0.309976 -0.256050
+vn 0.860775 -0.309915 -0.403668
+vn -0.647694 -0.470260 -0.599414
+vn -0.993530 0.054872 0.099124
+vn -0.998505 0.035646 0.040925
+vn 0.913724 -0.248634 -0.321360
+vn -0.087130 -0.605914 -0.790735
+vn -0.999908 -0.005371 -0.012055
+vn 0.943602 -0.203375 -0.261116
+vn 0.474044 -0.529954 -0.703116
+vn -0.994934 -0.059175 -0.081149
+vn 0.976348 -0.148991 -0.156560
+vn 0.962737 -0.166784 -0.212714
+vn 0.749626 -0.400525 -0.526872
+vn -0.973693 -0.137883 -0.181341
+vn -0.900327 -0.267037 -0.343608
+vn 0.986389 -0.102298 -0.128636
+vn -0.986389 0.102298 0.128636
+vn 0.976104 -0.134739 -0.170446
+vn -0.993866 0.069948 0.085452
+vn -0.992523 0.102878 0.065584
+vn 0.908231 -0.176580 -0.379345
+vn 0.937925 -0.100742 -0.331828
+vn -0.198889 -0.023316 -0.979736
+vn -0.994812 0.101505 0.001434
+vn -0.992401 0.099338 -0.072481
+vn 0.976043 -0.118625 -0.182318
+vn 0.848048 -0.206641 -0.487960
+vn -0.846431 0.208625 -0.489853
+vn 0.933683 -0.046937 -0.354991
+vn 0.960173 -0.068209 -0.270821
+vn -0.984832 0.148473 -0.089480
+vn 0.976409 -0.085665 -0.198157
+vn 0.802332 0.021424 -0.596454
+vn 0.876247 0.058168 -0.478256
+vn 0.959471 -0.035920 -0.279458
+vn 0.222236 0.328990 -0.917783
+vn 0.977538 -0.056154 -0.203040
+vn -0.617573 0.368267 -0.694906
+vn 0.926176 0.053407 -0.373211
+vn -0.967498 0.232917 -0.098361
+vn 0.156011 0.579485 -0.799890
+vn 0.859706 0.190741 -0.473769
+vn -0.594226 0.479202 -0.645924
+vn 0.924833 0.095798 -0.368084
+vn -0.254402 0.617847 -0.743980
+vn 0.926084 0.130741 -0.353923
+vn -0.855892 0.447554 -0.258950
+vn 0.735557 0.435072 -0.519272
+vn -0.738945 0.588305 -0.328318
+vn -0.982421 0.173376 0.068819
+vn 0.964843 0.057344 -0.256417
+vn -0.909604 0.394421 -0.130345
+vn 0.162816 0.810389 -0.562792
+vn -0.842189 0.511643 -0.169988
+vn 0.751396 0.472488 -0.460555
+vn -0.967467 0.251625 0.025971
+vn -0.236549 0.833583 -0.499130
+vn 0.947325 0.180242 -0.264687
+vn 0.194098 0.864284 -0.464003
+vn -0.734611 0.650624 -0.192328
+vn -0.965606 0.255593 0.046968
+vn 0.891568 0.317087 -0.323283
+vn -0.979766 0.179785 0.087588
+vn -0.941557 0.334452 0.039491
+vn -0.905179 0.424940 0.002136
+vn 0.985107 -0.019868 -0.170690
+vn 0.607868 0.713828 -0.347697
+vn -0.747826 0.663839 -0.007324
+vn 0.856380 0.469527 -0.214789
+vn -0.963897 0.247627 0.097720
+vn 0.936521 0.291543 -0.194586
+vn 0.985473 0.059175 -0.159062
+vn -0.851039 0.524094 0.031648
+vn 0.394665 0.918393 -0.027894
+vn 0.899625 0.421766 -0.113010
+vn -0.977935 0.175695 0.112766
+vn -0.963652 0.235420 0.126164
+vn 0.989227 -0.025025 -0.144139
+vn 0.990753 0.043458 -0.128483
+vn -0.067598 0.956816 0.282693
+vn 0.991058 -0.032136 -0.129276
+vn -0.863643 0.458022 0.210425
+vn -0.977294 0.169561 0.126988
+vn 0.978332 0.200934 -0.049623
+vn -0.944487 0.246559 0.217017
+vn -0.915586 0.309946 0.256081
+vn 0.997681 -0.004852 -0.067843
+vn -0.860805 0.309885 0.403668
+vn -0.962737 0.166784 0.212714
+vn 0.994934 0.059175 0.081149
+vn -0.474044 0.529923 0.703116
+vn 0.087130 0.605914 0.790735
+vn 0.993530 -0.054903 -0.099124
+vn 0.647694 0.470260 0.599414
+vn -0.976043 0.118656 0.182318
+vn -0.343089 0.060518 0.937315
+vn -0.961150 0.101779 0.256539
+vn 0.984832 -0.148473 0.089480
+vn -0.960173 0.068239 0.270821
+vn 0.665792 -0.034822 0.745293
+vn -0.933683 0.046907 0.354991
+vn 0.846431 -0.208655 0.489853
+vn -0.976409 0.085635 0.198157
+vn 0.953795 -0.228553 0.194952
+vn -0.976867 0.070193 0.201972
+vn -0.222266 -0.328990 0.917783
+vn -0.959471 0.035981 0.279458
+vn 0.986602 -0.162236 0.016449
+vn 0.245033 -0.383892 0.890255
+vn -0.929441 -0.005219 0.368877
+vn 0.989441 -0.133244 -0.056642
+vn -0.876247 -0.058138 0.478256
+vn -0.753441 -0.227760 0.616779
+vn -0.539903 -0.351177 0.764946
+vn -0.977538 0.056124 0.203040
+vn 0.967498 -0.232887 0.098392
+vn 0.252632 -0.515488 0.818781
+vn 0.985809 -0.157476 -0.058077
+vn -0.978515 0.043977 0.201361
+vn -0.156041 -0.579455 0.799890
+vn 0.952635 -0.294168 0.076998
+vn -0.926054 -0.130741 0.353923
+vn 0.984039 -0.166509 -0.062349
+vn -0.979766 0.034028 0.197089
+vn 0.909635 -0.394391 0.130345
+vn -0.502518 -0.609516 0.613147
+vn -0.146641 -0.746055 0.649495
+vn -0.964843 -0.057344 0.256417
+vn 0.982421 -0.173345 -0.068819
+vn -0.735557 -0.435041 0.519272
+vn -0.751366 -0.472518 0.460555
+vn 0.842189 -0.511673 0.169958
+vn -0.162816 -0.810358 0.562792
+vn 0.967437 -0.251656 -0.025971
+vn -0.194128 -0.864284 0.464003
+vn 0.905209 -0.424940 -0.002136
+vn 0.979766 -0.179785 -0.087619
+vn -0.814203 -0.492172 0.307871
+vn -0.607868 -0.713858 0.347667
+vn 0.845180 -0.532579 0.044771
+vn 0.851039 -0.524094 -0.031648
+vn -0.309305 -0.928678 0.204505
+vn 0.907987 -0.414716 -0.059420
+vn -0.971221 -0.160680 0.175665
+vn -0.856380 -0.469527 0.214789
+vn 0.857936 -0.500137 -0.117161
+vn -0.989227 0.025056 0.144139
+vn -0.990753 -0.043428 0.128483
+vn -0.899625 -0.421735 0.113041
+vn 0.977294 -0.169561 -0.126957
+vn 0.963500 -0.217780 -0.155644
+vn 0.863643 -0.457991 -0.210425
+vn -0.991058 0.032136 0.129307
+vn -0.994964 -0.021851 0.097629
+vn 0.067598 -0.956816 -0.282693
+vn 0.944487 -0.246529 -0.217017
+vn -0.997681 0.004883 0.067843
+vn -0.647694 -0.470229 -0.599414
+vn -0.993530 0.054903 0.099124
+vn 0.962737 -0.166814 -0.212714
+vn 0.976104 -0.134709 -0.170446
+usemtl SkinColor
+s 1
+f 489//483 488//484 503//485
+f 484//486 483//487 498//488
+f 495//489 494//490 510//491
+f 490//492 489//483 505//493
+f 485//494 484//486 499//495
+f 496//496 495//489 511//497
+f 491//498 490//492 506//499
+f 486//500 485//494 500//501
+f 497//502 496//496 512//503
+f 492//504 491//498 507//505
+f 487//506 486//500 501//507
+f 493//508 492//504 508//509
+f 488//484 487//506 502//510
+f 494//490 493//508 509//511
+f 504//512 503//485 518//513
+f 499//495 498//488 513//514
+f 510//491 509//511 525//515
+f 505//493 504//512 520//516
+f 500//501 499//495 514//517
+f 511//497 510//491 526//518
+f 506//499 505//493 521//519
+f 501//507 500//501 515//520
+f 512//503 511//497 527//521
+f 507//505 506//499 522//522
+f 502//510 501//507 516//523
+f 508//509 507//505 523//524
+f 503//485 502//510 517//525
+f 509//511 508//509 524//526
+f 523//524 522//522 538//527
+f 518//513 517//525 532//528
+f 524//526 523//524 539//529
+f 519//530 518//513 533//531
+f 514//517 513//514 528//532
+f 525//515 524//526 540//533
+f 520//516 519//530 535//534
+f 515//520 514//517 529//535
+f 526//518 525//515 541//536
+f 521//519 520//516 536//537
+f 516//523 515//520 530//538
+f 527//521 526//518 542//539
+f 522//522 521//519 537//540
+f 517//525 516//523 531//541
+f 542//539 541//536 557//542
+f 537//540 536//537 552//543
+f 532//528 531//541 546//544
+f 538//527 537//540 553//545
+f 533//531 532//528 547//546
+f 539//529 538//527 554//547
+f 534//548 533//531 548//549
+f 529//535 528//532 543//550
+f 540//533 539//529 555//551
+f 535//534 534//548 550//552
+f 530//538 529//535 544//553
+f 541//536 540//533 556//554
+f 536//537 535//534 551//555
+f 531//541 530//538 545//556
+f 545//556 544//553 559//557
+f 556//554 555//551 571//558
+f 551//555 550//552 566//559
+f 546//544 545//556 560//560
+f 557//542 556//554 572//561
+f 552//543 551//555 567//562
+f 547//546 546//544 561//563
+f 553//545 552//543 568//564
+f 548//549 547//546 562//565
+f 554//547 553//545 569//566
+f 549//567 548//549 563//568
+f 544//553 543//550 558//569
+f 555//551 554//547 570//570
+f 550//552 549//567 565//571
+f 564//572 563//568 578//573
+f 559//557 558//569 573//574
+f 570//570 569//566 585//575
+f 565//571 564//572 580//576
+f 560//560 559//557 574//577
+f 571//558 570//570 586//578
+f 566//559 565//571 581//579
+f 561//563 560//560 575//580
+f 572//561 571//558 587//581
+f 567//562 566//559 582//582
+f 562//565 561//563 576//583
+f 568//564 567//562 583//584
+f 563//568 562//565 577//585
+f 569//566 568//564 584//586
+f 583//584 582//582 598//587
+f 578//573 577//585 593//588
+f 584//586 583//584 599//589
+f 579//590 578//573 594//591
+f 574//577 573//574 588//592
+f 585//575 584//586 600//593
+f 580//576 579//590 595//594
+f 575//580 574//577 589//595
+f 586//578 585//575 601//596
+f 581//579 580//576 596//597
+f 576//583 575//580 590//598
+f 587//581 586//578 602//599
+f 582//582 581//579 597//600
+f 577//585 576//583 591//601
+f 602//599 601//596 616//602
+f 597//600 596//597 611//603
+f 592//604 591//601 607//605
+f 598//587 597//600 612//606
+f 593//588 592//604 608//607
+f 599//589 598//587 613//608
+f 594//591 593//588 609//609
+f 589//595 588//592 604//610
+f 600//593 599//589 614//611
+f 595//594 594//591 610//612
+f 590//598 589//595 605//613
+f 601//596 600//593 615//614
+f 596//597 595//594 611//603
+f 591//601 590//598 606//615
+f 616//602 615//614 630//616
+f 611//603 610//612 625//617
+f 606//615 605//613 621//618
+f 617//619 616//602 631//620
+f 612//606 611//603 626//621
+f 607//605 606//615 622//622
+f 613//608 612//606 627//623
+f 608//607 607//605 623//624
+f 614//611 613//608 628//625
+f 609//609 608//607 624//626
+f 604//610 603//627 619//628
+f 615//614 614//611 629//629
+f 610//612 609//609 625//617
+f 605//613 604//610 620//630
+f 619//628 618//631 634//632
+f 630//616 629//629 644//633
+f 625//617 624//626 640//634
+f 620//630 619//628 635//635
+f 631//620 630//616 645//636
+f 626//621 625//617 640//634
+f 621//618 620//630 636//637
+f 632//638 631//620 646//639
+f 627//623 626//621 641//640
+f 622//622 621//618 637//641
+f 628//625 627//623 642//642
+f 623//624 622//622 638//643
+f 629//629 628//625 643//644
+f 624//626 623//624 639//645
+f 638//643 637//641 653//646
+f 644//633 643//644 658//647
+f 639//645 638//643 654//648
+f 634//632 633//649 649//650
+f 645//636 644//633 659//651
+f 640//634 639//645 655//652
+f 635//635 634//632 650//653
+f 646//639 645//636 660//654
+f 641//640 640//634 655//652
+f 636//637 635//635 651//655
+f 647//656 646//639 661//657
+f 642//642 641//640 656//658
+f 637//641 636//637 652//659
+f 643//644 642//642 657//660
+f 657//660 656//658 671//661
+f 652//659 651//655 667//662
+f 658//647 657//660 672//663
+f 653//646 652//659 668//664
+f 659//651 658//647 673//665
+f 654//648 653//646 669//666
+f 649//650 648//667 664//668
+f 660//654 659//651 674//669
+f 655//652 654//648 670//670
+f 650//653 649//650 665//671
+f 661//657 660//654 675//672
+f 656//658 655//652 670//670
+f 651//655 650//653 666//673
+f 662//674 661//657 676//675
+f 676//675 675//672 690//676
+f 671//661 670//670 685//677
+f 666//673 665//671 681//678
+f 677//679 676//675 691//680
+f 672//663 671//661 686//681
+f 667//662 666//673 682//682
+f 673//665 672//663 687//683
+f 668//664 667//662 683//684
+f 674//669 673//665 688//685
+f 669//666 668//664 684//686
+f 664//668 663//687 679//688
+f 675//672 674//669 689//689
+f 670//670 669//666 685//677
+f 665//671 664//668 680//690
+f 679//688 678//691 694//692
+f 690//676 689//689 704//693
+f 685//677 684//686 699//694
+f 680//690 679//688 695//695
+f 691//680 690//676 705//696
+f 686//681 685//677 700//697
+f 681//678 680//690 696//698
+f 692//699 691//680 706//700
+f 687//683 686//681 701//701
+f 682//682 681//678 697//702
+f 688//685 687//683 702//703
+f 683//684 682//682 698//704
+f 689//689 688//685 703//705
+f 684//686 683//684 699//694
+f 698//704 697//702 712//706
+f 704//693 703//705 718//707
+f 699//694 698//704 713//708
+f 694//692 693//709 709//710
+f 705//696 704//693 719//711
+f 700//697 699//694 714//712
+f 695//695 694//692 710//713
+f 706//700 705//696 720//714
+f 701//701 700//697 715//715
+f 696//698 695//695 711//716
+f 707//717 706//700 721//718
+f 702//703 701//701 716//719
+f 697//702 696//698 712//706
+f 703//705 702//703 717//720
+f 717//720 716//719 731//721
+f 712//706 711//716 726//722
+f 718//707 717//720 733//723
+f 713//708 712//706 727//724
+f 719//711 718//707 734//725
+f 714//712 713//708 728//726
+f 709//710 708//727 723//728
+f 720//714 719//711 735//729
+f 715//715 714//712 729//730
+f 710//713 709//710 724//731
+f 721//718 720//714 736//732
+f 716//719 715//715 730//733
+f 711//716 710//713 725//734
+f 722//735 721//718 737//736
+f 736//732 735//729 751//737
+f 731//721 730//733 745//738
+f 726//722 725//734 740//739
+f 737//736 736//732 752//740
+f 732//741 731//721 747//742
+f 727//724 726//722 741//743
+f 733//723 732//741 748//744
+f 728//726 727//724 742//745
+f 734//725 733//723 749//746
+f 729//730 728//726 743//747
+f 724//731 723//728 738//748
+f 735//729 734//725 750//749
+f 730//733 729//730 744//750
+f 725//734 724//731 739//751
+f 750//749 749//746 765//752
+f 745//738 744//750 759//753
+f 740//739 739//751 754//754
+f 751//737 750//749 766//755
+f 746//756 745//738 760//757
+f 741//743 740//739 755//758
+f 752//740 751//737 767//759
+f 747//742 746//756 762//760
+f 742//745 741//743 756//761
+f 748//744 747//742 763//762
+f 743//747 742//745 757//763
+f 749//746 748//744 764//764
+f 744//750 743//747 758//765
+f 739//751 738//748 753//766
+f 764//764 763//762 779//767
+f 759//753 758//765 773//768
+f 754//754 753//766 768//769
+f 765//752 764//764 780//770
+f 760//757 759//753 774//771
+f 755//758 754//754 769//772
+f 766//755 765//752 781//773
+f 761//774 760//757 775//775
+f 756//761 755//758 770//776
+f 767//759 766//755 782//777
+f 762//760 761//774 777//778
+f 757//763 756//761 771//779
+f 763//762 762//760 778//780
+f 758//765 757//763 772//781
+f 772//781 771//779 786//782
+f 778//780 777//778 793//783
+f 773//768 772//781 787//784
+f 779//767 778//780 794//785
+f 774//771 773//768 788//786
+f 769//772 768//769 783//787
+f 780//770 779//767 795//788
+f 775//775 774//771 789//789
+f 770//776 769//772 784//790
+f 781//773 780//770 796//791
+f 776//792 775//775 790//793
+f 771//779 770//776 785//794
+f 782//777 781//773 797//795
+f 777//778 776//792 792//796
+f 791//797 790//793 805//798
+f 786//782 785//794 800//799
+f 797//795 796//791 812//800
+f 792//796 791//797 807//801
+f 787//784 786//782 801//802
+f 793//783 792//796 808//803
+f 788//786 787//784 802//804
+f 794//785 793//783 809//805
+f 789//789 788//786 803//806
+f 784//790 783//787 798//807
+f 795//788 794//785 810//808
+f 790//793 789//789 804//809
+f 785//794 784//790 799//810
+f 796//791 795//788 811//811
+f 810//808 809//805 826//812
+f 805//798 804//809 820//813
+f 800//799 799//810 815//814
+f 811//811 810//808 827//815
+f 806//816 805//798 821//817
+f 801//802 800//799 816//818
+f 812//800 811//811 828//819
+f 807//801 806//816 823//820
+f 802//804 801//802 817//821
+f 808//803 807//801 824//822
+f 803//806 802//804 818//823
+f 809//805 808//803 825//824
+f 804//809 803//806 819//825
+f 799//810 798//807 814//826
+f 825//824 824//822 840//827
+f 820//813 819//825 834//828
+f 815//814 814//826 829//829
+f 826//812 825//824 841//830
+f 821//817 820//813 835//831
+f 816//818 815//814 830//832
+f 827//815 826//812 842//833
+f 822//834 821//817 836//835
+f 817//821 816//818 831//836
+f 828//819 827//815 843//837
+f 823//820 822//834 837//838
+f 818//823 817//821 832//839
+f 824//822 823//820 838//840
+f 819//825 818//823 833//841
+f 833//841 832//839 848//842
+f 839//843 838//840 853//844
+f 834//828 833//841 849//845
+f 840//827 839//843 854//846
+f 835//831 834//828 850//847
+f 830//832 829//829 845//848
+f 841//830 840//827 855//849
+f 836//835 835//831 850//847
+f 831//836 830//832 846//850
+f 842//833 841//830 856//851
+f 837//838 836//835 851//852
+f 832//839 831//836 847//853
+f 843//837 842//833 857//854
+f 838//840 837//838 852//855
+f 852//855 851//852 866//856
+f 847//853 846//850 862//857
+f 858//858 857//854 872//859
+f 853//844 852//855 867//860
+f 848//842 847//853 863//861
+f 854//846 853//844 868//862
+f 849//845 848//842 864//863
+f 855//849 854//846 869//864
+f 850//847 849//845 865//865
+f 845//848 844//866 860//867
+f 856//851 855//849 870//868
+f 851//852 850//847 866//856
+f 846//850 845//848 861//869
+f 857//854 856//851 871//870
+f 871//870 870//868 885//871
+f 866//856 865//865 881//872
+f 861//869 860//867 876//873
+f 872//859 871//870 886//874
+f 867//860 866//856 881//872
+f 862//857 861//869 877//875
+f 873//876 872//859 887//877
+f 868//862 867//860 882//878
+f 863//861 862//857 878//879
+f 869//864 868//862 883//880
+f 864//863 863//861 879//881
+f 870//868 869//864 884//882
+f 865//865 864//863 880//883
+f 860//867 859//884 875//885
+f 885//871 884//882 899//886
+f 880//883 879//881 895//887
+f 875//885 874//888 890//889
+f 886//874 885//871 900//890
+f 881//872 880//883 896//891
+f 876//873 875//885 891//892
+f 887//877 886//874 901//893
+f 882//878 881//872 896//891
+f 877//875 876//873 892//894
+f 888//895 887//877 902//896
+f 883//880 882//878 897//897
+f 878//879 877//875 893//898
+f 884//882 883//880 898//899
+f 879//881 878//879 894//900
+f 899//886 898//899 913//901
+f 894//900 893//898 909//902
+f 900//890 899//886 914//903
+f 895//887 894//900 910//904
+f 890//889 889//905 905//906
+f 901//893 900//890 915//907
+f 896//891 895//887 911//908
+f 891//892 890//889 906//909
+f 902//896 901//893 916//910
+f 897//897 896//891 911//908
+f 892//894 891//892 907//911
+f 903//912 902//896 917//913
+f 898//899 897//897 912//914
+f 893//898 892//894 908//915
+f 907//911 906//909 922//916
+f 918//917 917//913 932//918
+f 913//901 912//914 927//919
+f 908//915 907//911 923//920
+f 914//903 913//901 928//921
+f 909//902 908//915 924//922
+f 915//907 914//903 929//923
+f 910//904 909//902 925//924
+f 905//906 904//925 920//926
+f 916//910 915//907 930//927
+f 911//908 910//904 926//928
+f 906//909 905//906 921//929
+f 917//913 916//910 931//930
+f 912//914 911//908 926//928
+f 926//928 925//924 942//931
+f 921//929 920//926 937//932
+f 932//918 931//930 947//933
+f 927//919 926//928 943//934
+f 922//916 921//929 938//935
+f 933//936 932//918 948//937
+f 928//921 927//919 943//934
+f 923//920 922//916 939//938
+f 929//923 928//921 944//939
+f 924//922 923//920 940//940
+f 930//927 929//923 945//941
+f 925//924 924//922 941//942
+f 920//926 919//943 936//944
+f 931//930 930//927 946//945
+f 946//945 945//941 960//946
+f 941//942 940//940 956//947
+f 936//944 935//948 951//949
+f 947//933 946//945 961//950
+f 942//931 941//942 957//951
+f 937//932 936//944 952//952
+f 948//937 947//933 962//953
+f 943//934 942//931 958//954
+f 938//935 937//932 953//955
+f 949//956 948//937 963//957
+f 944//939 943//934 959//958
+f 939//938 938//935 954//959
+f 945//941 944//939 960//946
+f 940//940 939//938 955//960
+f 813//961 497//502 512//503
+f 483//487 934//962 498//488
+f 813//961 512//503 527//521
+f 498//488 934//962 513//514
+f 513//514 934//962 528//532
+f 813//961 527//521 542//539
+f 813//961 542//539 557//542
+f 528//532 934//962 543//550
+f 813//961 557//542 572//561
+f 543//550 934//962 558//569
+f 813//961 572//561 587//581
+f 558//569 934//962 573//574
+f 573//574 934//962 588//592
+f 813//961 587//581 602//599
+f 813//961 602//599 617//619
+f 588//592 934//962 603//627
+f 813//961 617//619 632//638
+f 603//627 934//962 618//631
+f 813//961 632//638 647//656
+f 618//631 934//962 633//649
+f 633//649 934//962 648//667
+f 813//961 647//656 662//674
+f 813//961 662//674 677//679
+f 648//667 934//962 663//687
+f 813//961 677//679 692//699
+f 663//687 934//962 678//691
+f 813//961 692//699 707//717
+f 678//691 934//962 693//709
+f 693//709 934//962 708//727
+f 813//961 707//717 722//735
+f 813//961 722//735 737//736
+f 708//727 934//962 723//728
+f 813//961 737//736 752//740
+f 723//728 934//962 738//748
+f 813//961 752//740 767//759
+f 738//748 934//962 753//766
+f 753//766 934//962 768//769
+f 813//961 767//759 782//777
+f 813//961 782//777 797//795
+f 768//769 934//962 783//787
+f 813//961 797//795 812//800
+f 783//787 934//962 798//807
+f 813//961 812//800 828//819
+f 798//807 934//962 814//826
+f 814//826 934//962 829//829
+f 813//961 828//819 843//837
+f 813//961 843//837 858//858
+f 829//829 934//962 844//866
+f 813//961 858//858 873//876
+f 844//866 934//962 859//884
+f 813//961 873//876 888//895
+f 859//884 934//962 874//888
+f 813//961 888//895 903//912
+f 874//888 934//962 889//905
+f 813//961 903//912 918//917
+f 889//905 934//962 904//925
+f 813//961 918//917 933//936
+f 904//925 934//962 919//943
+f 813//961 933//936 949//956
+f 919//943 934//962 935//948
+f 813//961 949//956 964//963
+f 935//948 934//962 950//964
+f 813//961 964//963 497//502
+f 960//946 959//958 493//508
+f 955//960 954//959 487//506
+f 950//964 934//962 483//487
+f 961//950 960//946 494//490
+f 956//947 955//960 489//483
+f 951//949 950//964 483//487
+f 962//953 961//950 495//489
+f 957//951 956//947 490//492
+f 952//952 951//949 484//486
+f 963//957 962//953 496//496
+f 958//954 957//951 491//498
+f 953//955 952//952 485//494
+f 964//963 963//957 497//502
+f 959//958 958//954 492//504
+f 954//959 953//955 486//500
+f 971//483 970//484 985//485
+f 966//486 965//487 980//965
+f 977//489 976//966 992//967
+f 972//492 971//483 987//968
+f 967//494 966//486 981//969
+f 978//496 977//489 993//497
+f 973//498 972//492 988//499
+f 968//500 967//494 982//970
+f 979//971 978//496 994//503
+f 974//504 973//498 989//505
+f 969//506 968//500 983//507
+f 975//972 974//504 990//509
+f 970//484 969//506 984//510
+f 976//966 975//972 991//511
+f 986//512 985//485 1000//973
+f 981//969 980//965 995//514
+f 992//967 991//511 1007//974
+f 987//968 986//512 1002//516
+f 982//970 981//969 996//517
+f 993//497 992//967 1008//975
+f 988//499 987//968 1003//519
+f 983//507 982//970 997//976
+f 994//503 993//497 1009//977
+f 989//505 988//499 1004//522
+f 984//510 983//507 998//523
+f 990//509 989//505 1005//978
+f 985//485 984//510 999//525
+f 991//511 990//509 1006//526
+f 1005//978 1004//522 1020//527
+f 1000//973 999//525 1014//528
+f 1006//526 1005//978 1021//979
+f 1001//530 1000//973 1015//531
+f 996//517 995//514 1010//532
+f 1007//974 1006//526 1022//533
+f 1002//516 1001//530 1017//534
+f 997//976 996//517 1011//535
+f 1008//975 1007//974 1023//980
+f 1003//519 1002//516 1018//981
+f 998//523 997//976 1012//538
+f 1009//977 1008//975 1024//539
+f 1004//522 1003//519 1019//540
+f 999//525 998//523 1013//541
+f 1024//539 1023//980 1039//982
+f 1019//540 1018//981 1034//543
+f 1014//528 1013//541 1028//544
+f 1020//527 1019//540 1035//545
+f 1015//531 1014//528 1029//546
+f 1021//979 1020//527 1036//547
+f 1016//983 1015//531 1030//549
+f 1011//535 1010//532 1025//550
+f 1022//533 1021//979 1037//984
+f 1017//534 1016//983 1032//552
+f 1012//538 1011//535 1026//553
+f 1023//980 1022//533 1038//554
+f 1018//981 1017//534 1033//555
+f 1013//541 1012//538 1027//985
+f 1027//985 1026//553 1041//557
+f 1038//554 1037//984 1053//558
+f 1033//555 1032//552 1048//986
+f 1028//544 1027//985 1042//560
+f 1039//982 1038//554 1054//561
+f 1034//543 1033//555 1049//562
+f 1029//546 1028//544 1043//563
+f 1035//545 1034//543 1050//564
+f 1030//549 1029//546 1044//565
+f 1036//547 1035//545 1051//987
+f 1031//988 1030//549 1045//568
+f 1026//553 1025//550 1040//569
+f 1037//984 1036//547 1052//989
+f 1032//552 1031//988 1047//990
+f 1046//572 1045//568 1060//573
+f 1041//557 1040//569 1055//574
+f 1052//989 1051//987 1067//991
+f 1047//990 1046//572 1062//576
+f 1042//560 1041//557 1056//577
+f 1053//558 1052//989 1068//578
+f 1048//986 1047//990 1063//579
+f 1043//563 1042//560 1057//580
+f 1054//561 1053//558 1069//581
+f 1049//562 1048//986 1064//582
+f 1044//565 1043//563 1058//583
+f 1050//564 1049//562 1065//584
+f 1045//568 1044//565 1059//992
+f 1051//987 1050//564 1066//586
+f 1065//584 1064//582 1080//993
+f 1060//573 1059//992 1075//994
+f 1066//586 1065//584 1081//589
+f 1061//590 1060//573 1076//591
+f 1056//577 1055//574 1070//995
+f 1067//991 1066//586 1082//593
+f 1062//576 1061//590 1077//594
+f 1057//580 1056//577 1071//595
+f 1068//578 1067//991 1083//996
+f 1063//579 1062//576 1078//597
+f 1058//583 1057//580 1072//598
+f 1069//581 1068//578 1084//599
+f 1064//582 1063//579 1079//600
+f 1059//992 1058//583 1073//997
+f 1084//599 1083//996 1098//602
+f 1079//600 1078//597 1093//998
+f 1074//604 1073//997 1089//999
+f 1080//993 1079//600 1094//606
+f 1075//994 1074//604 1090//607
+f 1081//589 1080//993 1095//1000
+f 1076//591 1075//994 1091//609
+f 1071//595 1070//995 1086//1001
+f 1082//593 1081//589 1096//611
+f 1077//594 1076//591 1092//1002
+f 1072//598 1071//595 1087//613
+f 1083//996 1082//593 1097//614
+f 1078//597 1077//594 1093//998
+f 1073//997 1072//598 1088//615
+f 1098//602 1097//614 1112//1003
+f 1093//998 1092//1002 1107//617
+f 1088//615 1087//613 1103//618
+f 1099//619 1098//602 1113//620
+f 1094//606 1093//998 1108//1004
+f 1089//999 1088//615 1104//622
+f 1095//1000 1094//606 1109//623
+f 1090//607 1089//999 1105//1005
+f 1096//611 1095//1000 1110//625
+f 1091//609 1090//607 1106//626
+f 1086//1001 1085//627 1101//1006
+f 1097//614 1096//611 1111//1007
+f 1092//1002 1091//609 1107//617
+f 1087//613 1086//1001 1102//630
+f 1101//1006 1100//1008 1116//632
+f 1112//1003 1111//1007 1126//633
+f 1107//617 1106//626 1122//634
+f 1102//630 1101//1006 1117//1009
+f 1113//620 1112//1003 1127//636
+f 1108//1004 1107//617 1122//634
+f 1103//618 1102//630 1118//1010
+f 1114//1011 1113//620 1128//639
+f 1109//623 1108//1004 1123//640
+f 1104//622 1103//618 1119//641
+f 1110//625 1109//623 1124//1012
+f 1105//1005 1104//622 1120//643
+f 1111//1007 1110//625 1125//644
+f 1106//626 1105//1005 1121//645
+f 1120//643 1119//641 1135//1013
+f 1126//633 1125//644 1140//1014
+f 1121//645 1120//643 1136//648
+f 1116//632 1115//649 1131//1015
+f 1127//636 1126//633 1141//1016
+f 1122//634 1121//645 1137//652
+f 1117//1009 1116//632 1132//653
+f 1128//639 1127//636 1142//654
+f 1123//640 1122//634 1137//652
+f 1118//1010 1117//1009 1133//655
+f 1129//656 1128//639 1143//1017
+f 1124//1012 1123//640 1138//658
+f 1119//641 1118//1010 1134//1018
+f 1125//644 1124//1012 1139//660
+f 1139//660 1138//658 1153//1019
+f 1134//1018 1133//655 1149//662
+f 1140//1014 1139//660 1154//663
+f 1135//1013 1134//1018 1150//664
+f 1141//1016 1140//1014 1155//1020
+f 1136//648 1135//1013 1151//666
+f 1131//1015 1130//1021 1146//1022
+f 1142//654 1141//1016 1156//669
+f 1137//652 1136//648 1152//670
+f 1132//653 1131//1015 1147//671
+f 1143//1017 1142//654 1157//672
+f 1138//658 1137//652 1152//670
+f 1133//655 1132//653 1148//673
+f 1144//1023 1143//1017 1158//1024
+f 1158//1024 1157//672 1172//676
+f 1153//1019 1152//670 1167//1025
+f 1148//673 1147//671 1163//678
+f 1159//1026 1158//1024 1173//680
+f 1154//663 1153//1019 1168//681
+f 1149//662 1148//673 1164//1027
+f 1155//1020 1154//663 1169//683
+f 1150//664 1149//662 1165//684
+f 1156//669 1155//1020 1170//685
+f 1151//666 1150//664 1166//686
+f 1146//1022 1145//1028 1161//688
+f 1157//672 1156//669 1171//1029
+f 1152//670 1151//666 1167//1025
+f 1147//671 1146//1022 1162//690
+f 1161//688 1160//691 1176//692
+f 1172//676 1171//1029 1186//693
+f 1167//1025 1166//686 1181//694
+f 1162//690 1161//688 1177//1030
+f 1173//680 1172//676 1187//696
+f 1168//681 1167//1025 1182//697
+f 1163//678 1162//690 1178//1031
+f 1174//699 1173//680 1188//1032
+f 1169//683 1168//681 1183//701
+f 1164//1027 1163//678 1179//702
+f 1170//685 1169//683 1184//703
+f 1165//684 1164//1027 1180//704
+f 1171//1029 1170//685 1185//705
+f 1166//686 1165//684 1181//694
+f 1180//704 1179//702 1194//1033
+f 1186//693 1185//705 1200//707
+f 1181//694 1180//704 1195//708
+f 1176//692 1175//709 1191//1034
+f 1187//696 1186//693 1201//1035
+f 1182//697 1181//694 1196//1036
+f 1177//1030 1176//692 1192//713
+f 1188//1032 1187//696 1202//714
+f 1183//701 1182//697 1197//1037
+f 1178//1031 1177//1030 1193//716
+f 1189//1038 1188//1032 1203//718
+f 1184//703 1183//701 1198//1039
+f 1179//702 1178//1031 1194//1033
+f 1185//705 1184//703 1199//720
+f 1199//720 1198//1039 1213//721
+f 1194//1033 1193//716 1208//722
+f 1200//707 1199//720 1215//723
+f 1195//708 1194//1033 1209//724
+f 1201//1035 1200//707 1216//725
+f 1196//1036 1195//708 1210//726
+f 1191//1034 1190//727 1205//1040
+f 1202//714 1201//1035 1217//729
+f 1197//1037 1196//1036 1211//730
+f 1192//713 1191//1034 1206//731
+f 1203//718 1202//714 1218//732
+f 1198//1039 1197//1037 1212//733
+f 1193//716 1192//713 1207//734
+f 1204//735 1203//718 1219//736
+f 1218//732 1217//729 1233//737
+f 1213//721 1212//733 1227//738
+f 1208//722 1207//734 1222//739
+f 1219//736 1218//732 1234//740
+f 1214//741 1213//721 1229//742
+f 1209//724 1208//722 1223//743
+f 1215//723 1214//741 1230//744
+f 1210//726 1209//724 1224//745
+f 1216//725 1215//723 1231//746
+f 1211//730 1210//726 1225//747
+f 1206//731 1205//1040 1220//748
+f 1217//729 1216//725 1232//749
+f 1212//733 1211//730 1226//1041
+f 1207//734 1206//731 1221//1042
+f 1232//749 1231//746 1247//1043
+f 1227//738 1226//1041 1241//753
+f 1222//739 1221//1042 1236//1044
+f 1233//737 1232//749 1248//755
+f 1228//1045 1227//738 1242//757
+f 1223//743 1222//739 1237//1046
+f 1234//740 1233//737 1249//759
+f 1229//742 1228//1045 1244//1047
+f 1224//745 1223//743 1238//761
+f 1230//744 1229//742 1245//762
+f 1225//747 1224//745 1239//763
+f 1231//746 1230//744 1246//764
+f 1226//1041 1225//747 1240//765
+f 1221//1042 1220//748 1235//1048
+f 1246//764 1245//762 1261//1049
+f 1241//753 1240//765 1255//768
+f 1236//1044 1235//1048 1250//1050
+f 1247//1043 1246//764 1262//770
+f 1242//757 1241//753 1256//1051
+f 1237//1046 1236//1044 1251//1052
+f 1248//755 1247//1043 1263//1053
+f 1243//774 1242//757 1257//1054
+f 1238//761 1237//1046 1252//1055
+f 1249//759 1248//755 1264//1056
+f 1244//1047 1243//774 1259//778
+f 1239//763 1238//761 1253//1057
+f 1245//762 1244//1047 1260//780
+f 1240//765 1239//763 1254//781
+f 1254//781 1253//1057 1268//782
+f 1260//780 1259//778 1275//783
+f 1255//768 1254//781 1269//1058
+f 1261//1049 1260//780 1276//785
+f 1256//1051 1255//768 1270//1059
+f 1251//1052 1250//1050 1265//1060
+f 1262//770 1261//1049 1277//1061
+f 1257//1054 1256//1051 1271//789
+f 1252//1055 1251//1052 1266//790
+f 1263//1053 1262//770 1278//791
+f 1258//792 1257//1054 1272//1062
+f 1253//1057 1252//1055 1267//794
+f 1264//1056 1263//1053 1279//795
+f 1259//778 1258//792 1274//796
+f 1273//797 1272//1062 1287//798
+f 1268//782 1267//794 1282//799
+f 1279//795 1278//791 1294//1063
+f 1274//796 1273//797 1289//801
+f 1269//1058 1268//782 1283//802
+f 1275//783 1274//796 1290//803
+f 1270//1059 1269//1058 1284//804
+f 1276//785 1275//783 1291//805
+f 1271//789 1270//1059 1285//806
+f 1266//790 1265//1060 1280//1064
+f 1277//1061 1276//785 1292//808
+f 1272//1062 1271//789 1286//1065
+f 1267//794 1266//790 1281//810
+f 1278//791 1277//1061 1293//811
+f 1292//808 1291//805 1308//1066
+f 1287//798 1286//1065 1302//813
+f 1282//799 1281//810 1297//814
+f 1293//811 1292//808 1309//815
+f 1288//816 1287//798 1303//817
+f 1283//802 1282//799 1298//1067
+f 1294//1063 1293//811 1310//1068
+f 1289//801 1288//816 1305//820
+f 1284//804 1283//802 1299//821
+f 1290//803 1289//801 1306//822
+f 1285//806 1284//804 1300//823
+f 1291//805 1290//803 1307//824
+f 1286//1065 1285//806 1301//825
+f 1281//810 1280//1064 1296//1069
+f 1307//824 1306//822 1322//1070
+f 1302//813 1301//825 1316//1071
+f 1297//814 1296//1069 1311//829
+f 1308//1066 1307//824 1323//830
+f 1303//817 1302//813 1317//1072
+f 1298//1067 1297//814 1312//1073
+f 1309//815 1308//1066 1324//833
+f 1304//834 1303//817 1318//835
+f 1299//821 1298//1067 1313//836
+f 1310//1068 1309//815 1325//1074
+f 1305//820 1304//834 1319//838
+f 1300//823 1299//821 1314//839
+f 1306//822 1305//820 1320//840
+f 1301//825 1300//823 1315//1075
+f 1315//1075 1314//839 1330//1076
+f 1321//843 1320//840 1335//844
+f 1316//1071 1315//1075 1331//845
+f 1322//1070 1321//843 1336//1077
+f 1317//1072 1316//1071 1332//1078
+f 1312//1073 1311//829 1327//848
+f 1323//830 1322//1070 1337//849
+f 1318//835 1317//1072 1332//1078
+f 1313//836 1312//1073 1328//850
+f 1324//833 1323//830 1338//851
+f 1319//838 1318//835 1333//852
+f 1314//839 1313//836 1329//853
+f 1325//1074 1324//833 1339//1079
+f 1320//840 1319//838 1334//855
+f 1334//855 1333//852 1348//856
+f 1329//853 1328//850 1344//857
+f 1340//858 1339//1079 1354//859
+f 1335//844 1334//855 1349//860
+f 1330//1076 1329//853 1345//861
+f 1336//1077 1335//844 1350//862
+f 1331//845 1330//1076 1346//863
+f 1337//849 1336//1077 1351//864
+f 1332//1078 1331//845 1347//1080
+f 1327//848 1326//866 1342//867
+f 1338//851 1337//849 1352//868
+f 1333//852 1332//1078 1348//856
+f 1328//850 1327//848 1343//869
+f 1339//1079 1338//851 1353//870
+f 1353//870 1352//868 1367//1081
+f 1348//856 1347//1080 1363//872
+f 1343//869 1342//867 1358//873
+f 1354//859 1353//870 1368//874
+f 1349//860 1348//856 1363//872
+f 1344//857 1343//869 1359//875
+f 1355//1082 1354//859 1369//877
+f 1350//862 1349//860 1364//878
+f 1345//861 1344//857 1360//1083
+f 1351//864 1350//862 1365//880
+f 1346//863 1345//861 1361//1084
+f 1352//868 1351//864 1366//1085
+f 1347//1080 1346//863 1362//883
+f 1342//867 1341//884 1357//885
+f 1367//1081 1366//1085 1381//1086
+f 1362//883 1361//1084 1377//1087
+f 1357//885 1356//888 1372//889
+f 1368//874 1367//1081 1382//1088
+f 1363//872 1362//883 1378//891
+f 1358//873 1357//885 1373//1089
+f 1369//877 1368//874 1383//893
+f 1364//878 1363//872 1378//891
+f 1359//875 1358//873 1374//894
+f 1370//895 1369//877 1384//896
+f 1365//880 1364//878 1379//897
+f 1360//1083 1359//875 1375//1090
+f 1366//1085 1365//880 1380//899
+f 1361//1084 1360//1083 1376//900
+f 1381//1086 1380//899 1395//901
+f 1376//900 1375//1090 1391//902
+f 1382//1088 1381//1086 1396//1091
+f 1377//1087 1376//900 1392//904
+f 1372//889 1371//1092 1387//1093
+f 1383//893 1382//1088 1397//907
+f 1378//891 1377//1087 1393//908
+f 1373//1089 1372//889 1388//909
+f 1384//896 1383//893 1398//910
+f 1379//897 1378//891 1393//908
+f 1374//894 1373//1089 1389//911
+f 1385//912 1384//896 1399//913
+f 1380//899 1379//897 1394//914
+f 1375//1090 1374//894 1390//1094
+f 1389//911 1388//909 1404//916
+f 1400//1095 1399//913 1414//1096
+f 1395//901 1394//914 1409//919
+f 1390//1094 1389//911 1405//920
+f 1396//1091 1395//901 1410//921
+f 1391//902 1390//1094 1406//922
+f 1397//907 1396//1091 1411//1097
+f 1392//904 1391//902 1407//924
+f 1387//1093 1386//1098 1402//1099
+f 1398//910 1397//907 1412//927
+f 1393//908 1392//904 1408//1100
+f 1388//909 1387//1093 1403//929
+f 1399//913 1398//910 1413//930
+f 1394//914 1393//908 1408//1100
+f 1408//1100 1407//924 1424//931
+f 1403//929 1402//1099 1419//932
+f 1414//1096 1413//930 1429//1101
+f 1409//919 1408//1100 1425//934
+f 1404//916 1403//929 1420//935
+f 1415//936 1414//1096 1430//937
+f 1410//921 1409//919 1425//934
+f 1405//920 1404//916 1421//938
+f 1411//1097 1410//921 1426//939
+f 1406//922 1405//920 1422//940
+f 1412//927 1411//1097 1427//941
+f 1407//924 1406//922 1423//942
+f 1402//1099 1401//943 1418//1102
+f 1413//930 1412//927 1428//945
+f 1428//945 1427//941 1442//946
+f 1423//942 1422//940 1438//1103
+f 1418//1102 1417//1104 1433//949
+f 1429//1101 1428//945 1443//950
+f 1424//931 1423//942 1439//951
+f 1419//932 1418//1102 1434//952
+f 1430//937 1429//1101 1444//953
+f 1425//934 1424//931 1440//954
+f 1420//935 1419//932 1435//955
+f 1431//956 1430//937 1445//1105
+f 1426//939 1425//934 1441//958
+f 1421//938 1420//935 1436//959
+f 1427//941 1426//939 1442//946
+f 1422//940 1421//938 1437//960
+f 1295//961 979//971 994//503
+f 965//487 1416//962 980//965
+f 1295//961 994//503 1009//977
+f 980//965 1416//962 995//514
+f 995//514 1416//962 1010//532
+f 1295//961 1009//977 1024//539
+f 1295//961 1024//539 1039//982
+f 1010//532 1416//962 1025//550
+f 1295//961 1039//982 1054//561
+f 1025//550 1416//962 1040//569
+f 1295//961 1054//561 1069//581
+f 1040//569 1416//962 1055//574
+f 1055//574 1416//962 1070//995
+f 1295//961 1069//581 1084//599
+f 1295//961 1084//599 1099//619
+f 1070//995 1416//962 1085//627
+f 1295//961 1099//619 1114//1011
+f 1085//627 1416//962 1100//1008
+f 1295//961 1114//1011 1129//656
+f 1100//1008 1416//962 1115//649
+f 1115//649 1416//962 1130//1021
+f 1295//961 1129//656 1144//1023
+f 1295//961 1144//1023 1159//1026
+f 1130//1021 1416//962 1145//1028
+f 1295//961 1159//1026 1174//699
+f 1145//1028 1416//962 1160//691
+f 1295//961 1174//699 1189//1038
+f 1160//691 1416//962 1175//709
+f 1175//709 1416//962 1190//727
+f 1295//961 1189//1038 1204//735
+f 1295//961 1204//735 1219//736
+f 1190//727 1416//962 1205//1040
+f 1295//961 1219//736 1234//740
+f 1205//1040 1416//962 1220//748
+f 1295//961 1234//740 1249//759
+f 1220//748 1416//962 1235//1048
+f 1235//1048 1416//962 1250//1050
+f 1295//961 1249//759 1264//1056
+f 1295//961 1264//1056 1279//795
+f 1250//1050 1416//962 1265//1060
+f 1295//961 1279//795 1294//1063
+f 1265//1060 1416//962 1280//1064
+f 1295//961 1294//1063 1310//1068
+f 1280//1064 1416//962 1296//1069
+f 1296//1069 1416//962 1311//829
+f 1295//961 1310//1068 1325//1074
+f 1295//961 1325//1074 1340//858
+f 1311//829 1416//962 1326//866
+f 1295//961 1340//858 1355//1082
+f 1326//866 1416//962 1341//884
+f 1295//961 1355//1082 1370//895
+f 1341//884 1416//962 1356//888
+f 1295//961 1370//895 1385//912
+f 1356//888 1416//962 1371//1092
+f 1295//961 1385//912 1400//1095
+f 1371//1092 1416//962 1386//1098
+f 1295//961 1400//1095 1415//936
+f 1386//1098 1416//962 1401//943
+f 1295//961 1415//936 1431//956
+f 1401//943 1416//962 1417//1104
+f 1295//961 1431//956 1446//1106
+f 1417//1104 1416//962 1432//964
+f 1295//961 1446//1106 979//971
+f 1442//946 1441//958 975//972
+f 1437//960 1436//959 969//506
+f 1432//964 1416//962 965//487
+f 1443//950 1442//946 976//966
+f 1438//1103 1437//960 971//483
+f 1433//949 1432//964 965//487
+f 1444//953 1443//950 977//489
+f 1439//951 1438//1103 972//492
+f 1434//952 1433//949 966//486
+f 1445//1105 1444//953 978//496
+f 1440//954 1439//951 973//498
+f 1435//955 1434//952 967//494
+f 1446//1106 1445//1105 979//971
+f 1441//958 1440//954 974//504
+f 1436//959 1435//955 968//500
+f 504//512 489//483 503//485
+f 499//495 484//486 498//488
+f 494//490 509//511 510//491
+f 489//483 504//512 505//493
+f 500//501 485//494 499//495
+f 495//489 510//491 511//497
+f 490//492 505//493 506//499
+f 501//507 486//500 500//501
+f 496//496 511//497 512//503
+f 491//498 506//499 507//505
+f 502//510 487//506 501//507
+f 492//504 507//505 508//509
+f 503//485 488//484 502//510
+f 493//508 508//509 509//511
+f 519//530 504//512 518//513
+f 514//517 499//495 513//514
+f 509//511 524//526 525//515
+f 504//512 519//530 520//516
+f 515//520 500//501 514//517
+f 510//491 525//515 526//518
+f 505//493 520//516 521//519
+f 516//523 501//507 515//520
+f 511//497 526//518 527//521
+f 506//499 521//519 522//522
+f 517//525 502//510 516//523
+f 507//505 522//522 523//524
+f 518//513 503//485 517//525
+f 508//509 523//524 524//526
+f 522//522 537//540 538//527
+f 533//531 518//513 532//528
+f 523//524 538//527 539//529
+f 534//548 519//530 533//531
+f 529//535 514//517 528//532
+f 524//526 539//529 540//533
+f 519//530 534//548 535//534
+f 530//538 515//520 529//535
+f 525//515 540//533 541//536
+f 520//516 535//534 536//537
+f 531//541 516//523 530//538
+f 526//518 541//536 542//539
+f 521//519 536//537 537//540
+f 532//528 517//525 531//541
+f 541//536 556//554 557//542
+f 536//537 551//555 552//543
+f 547//546 532//528 546//544
+f 537//540 552//543 553//545
+f 548//549 533//531 547//546
+f 538//527 553//545 554//547
+f 549//567 534//548 548//549
+f 544//553 529//535 543//550
+f 539//529 554//547 555//551
+f 534//548 549//567 550//552
+f 545//556 530//538 544//553
+f 540//533 555//551 556//554
+f 535//534 550//552 551//555
+f 546//544 531//541 545//556
+f 560//560 545//556 559//557
+f 555//551 570//570 571//558
+f 550//552 565//571 566//559
+f 561//563 546//544 560//560
+f 556//554 571//558 572//561
+f 551//555 566//559 567//562
+f 562//565 547//546 561//563
+f 552//543 567//562 568//564
+f 563//568 548//549 562//565
+f 553//545 568//564 569//566
+f 564//572 549//567 563//568
+f 559//557 544//553 558//569
+f 554//547 569//566 570//570
+f 549//567 564//572 565//571
+f 579//590 564//572 578//573
+f 574//577 559//557 573//574
+f 569//566 584//586 585//575
+f 564//572 579//590 580//576
+f 575//580 560//560 574//577
+f 570//570 585//575 586//578
+f 565//571 580//576 581//579
+f 576//583 561//563 575//580
+f 571//558 586//578 587//581
+f 566//559 581//579 582//582
+f 577//585 562//565 576//583
+f 567//562 582//582 583//584
+f 578//573 563//568 577//585
+f 568//564 583//584 584//586
+f 582//582 597//600 598//587
+f 577//585 592//604 593//588
+f 583//584 598//587 599//589
+f 578//573 593//588 594//591
+f 589//595 574//577 588//592
+f 584//586 599//589 600//593
+f 579//590 594//591 595//594
+f 590//598 575//580 589//595
+f 585//575 600//593 601//596
+f 580//576 595//594 596//597
+f 591//601 576//583 590//598
+f 586//578 601//596 602//599
+f 581//579 596//597 597//600
+f 592//604 577//585 591//601
+f 617//619 602//599 616//602
+f 612//606 597//600 611//603
+f 591//601 606//615 607//605
+f 613//608 598//587 612//606
+f 592//604 607//605 608//607
+f 614//611 599//589 613//608
+f 593//588 608//607 609//609
+f 588//592 603//627 604//610
+f 615//614 600//593 614//611
+f 594//591 609//609 610//612
+f 589//595 604//610 605//613
+f 616//602 601//596 615//614
+f 595//594 610//612 611//603
+f 590//598 605//613 606//615
+f 631//620 616//602 630//616
+f 626//621 611//603 625//617
+f 605//613 620//630 621//618
+f 632//638 617//619 631//620
+f 627//623 612//606 626//621
+f 606//615 621//618 622//622
+f 628//625 613//608 627//623
+f 607//605 622//622 623//624
+f 629//629 614//611 628//625
+f 608//607 623//624 624//626
+f 603//627 618//631 619//628
+f 630//616 615//614 629//629
+f 609//609 624//626 625//617
+f 604//610 619//628 620//630
+f 618//631 633//649 634//632
+f 645//636 630//616 644//633
+f 624//626 639//645 640//634
+f 619//628 634//632 635//635
+f 646//639 631//620 645//636
+f 641//640 626//621 640//634
+f 620//630 635//635 636//637
+f 647//656 632//638 646//639
+f 642//642 627//623 641//640
+f 621//618 636//637 637//641
+f 643//644 628//625 642//642
+f 622//622 637//641 638//643
+f 644//633 629//629 643//644
+f 623//624 638//643 639//645
+f 637//641 652//659 653//646
+f 659//651 644//633 658//647
+f 638//643 653//646 654//648
+f 633//649 648//667 649//650
+f 660//654 645//636 659//651
+f 639//645 654//648 655//652
+f 634//632 649//650 650//653
+f 661//657 646//639 660//654
+f 656//658 641//640 655//652
+f 635//635 650//653 651//655
+f 662//674 647//656 661//657
+f 657//660 642//642 656//658
+f 636//637 651//655 652//659
+f 658//647 643//644 657//660
+f 672//663 657//660 671//661
+f 651//655 666//673 667//662
+f 673//665 658//647 672//663
+f 652//659 667//662 668//664
+f 674//669 659//651 673//665
+f 653//646 668//664 669//666
+f 648//667 663//687 664//668
+f 675//672 660//654 674//669
+f 654//648 669//666 670//670
+f 649//650 664//668 665//671
+f 676//675 661//657 675//672
+f 671//661 656//658 670//670
+f 650//653 665//671 666//673
+f 677//679 662//674 676//675
+f 691//680 676//675 690//676
+f 686//681 671//661 685//677
+f 665//671 680//690 681//678
+f 692//699 677//679 691//680
+f 687//683 672//663 686//681
+f 666//673 681//678 682//682
+f 688//685 673//665 687//683
+f 667//662 682//682 683//684
+f 689//689 674//669 688//685
+f 668//664 683//684 684//686
+f 663//687 678//691 679//688
+f 690//676 675//672 689//689
+f 669//666 684//686 685//677
+f 664//668 679//688 680//690
+f 678//691 693//709 694//692
+f 705//696 690//676 704//693
+f 700//697 685//677 699//694
+f 679//688 694//692 695//695
+f 706//700 691//680 705//696
+f 701//701 686//681 700//697
+f 680//690 695//695 696//698
+f 707//717 692//699 706//700
+f 702//703 687//683 701//701
+f 681//678 696//698 697//702
+f 703//705 688//685 702//703
+f 682//682 697//702 698//704
+f 704//693 689//689 703//705
+f 683//684 698//704 699//694
+f 713//708 698//704 712//706
+f 719//711 704//693 718//707
+f 714//712 699//694 713//708
+f 693//709 708//727 709//710
+f 720//714 705//696 719//711
+f 715//715 700//697 714//712
+f 694//692 709//710 710//713
+f 721//718 706//700 720//714
+f 716//719 701//701 715//715
+f 695//695 710//713 711//716
+f 722//735 707//717 721//718
+f 717//720 702//703 716//719
+f 696//698 711//716 712//706
+f 718//707 703//705 717//720
+f 732//741 717//720 731//721
+f 727//724 712//706 726//722
+f 717//720 732//741 733//723
+f 728//726 713//708 727//724
+f 718//707 733//723 734//725
+f 729//730 714//712 728//726
+f 724//731 709//710 723//728
+f 719//711 734//725 735//729
+f 730//733 715//715 729//730
+f 725//734 710//713 724//731
+f 720//714 735//729 736//732
+f 731//721 716//719 730//733
+f 726//722 711//716 725//734
+f 721//718 736//732 737//736
+f 735//729 750//749 751//737
+f 746//756 731//721 745//738
+f 741//743 726//722 740//739
+f 736//732 751//737 752//740
+f 731//721 746//756 747//742
+f 742//745 727//724 741//743
+f 732//741 747//742 748//744
+f 743//747 728//726 742//745
+f 733//723 748//744 749//746
+f 744//750 729//730 743//747
+f 739//751 724//731 738//748
+f 734//725 749//746 750//749
+f 745//738 730//733 744//750
+f 740//739 725//734 739//751
+f 749//746 764//764 765//752
+f 760//757 745//738 759//753
+f 755//758 740//739 754//754
+f 750//749 765//752 766//755
+f 761//774 746//756 760//757
+f 756//761 741//743 755//758
+f 751//737 766//755 767//759
+f 746//756 761//774 762//760
+f 757//763 742//745 756//761
+f 747//742 762//760 763//762
+f 758//765 743//747 757//763
+f 748//744 763//762 764//764
+f 759//753 744//750 758//765
+f 754//754 739//751 753//766
+f 763//762 778//780 779//767
+f 774//771 759//753 773//768
+f 769//772 754//754 768//769
+f 764//764 779//767 780//770
+f 775//775 760//757 774//771
+f 770//776 755//758 769//772
+f 765//752 780//770 781//773
+f 776//792 761//774 775//775
+f 771//779 756//761 770//776
+f 766//755 781//773 782//777
+f 761//774 776//792 777//778
+f 772//781 757//763 771//779
+f 762//760 777//778 778//780
+f 773//768 758//765 772//781
+f 787//784 772//781 786//782
+f 777//778 792//796 793//783
+f 788//786 773//768 787//784
+f 778//780 793//783 794//785
+f 789//789 774//771 788//786
+f 784//790 769//772 783//787
+f 779//767 794//785 795//788
+f 790//793 775//775 789//789
+f 785//794 770//776 784//790
+f 780//770 795//788 796//791
+f 791//797 776//792 790//793
+f 786//782 771//779 785//794
+f 781//773 796//791 797//795
+f 776//792 791//797 792//796
+f 806//816 791//797 805//798
+f 801//802 786//782 800//799
+f 796//791 811//811 812//800
+f 791//797 806//816 807//801
+f 802//804 787//784 801//802
+f 792//796 807//801 808//803
+f 803//806 788//786 802//804
+f 793//783 808//803 809//805
+f 804//809 789//789 803//806
+f 799//810 784//790 798//807
+f 794//785 809//805 810//808
+f 805//798 790//793 804//809
+f 800//799 785//794 799//810
+f 795//788 810//808 811//811
+f 809//805 825//824 826//812
+f 821//817 805//798 820//813
+f 816//818 800//799 815//814
+f 810//808 826//812 827//815
+f 822//834 806//816 821//817
+f 817//821 801//802 816//818
+f 811//811 827//815 828//819
+f 806//816 822//834 823//820
+f 818//823 802//804 817//821
+f 807//801 823//820 824//822
+f 819//825 803//806 818//823
+f 808//803 824//822 825//824
+f 820//813 804//809 819//825
+f 815//814 799//810 814//826
+f 824//822 839//843 840//827
+f 835//831 820//813 834//828
+f 830//832 815//814 829//829
+f 825//824 840//827 841//830
+f 836//835 821//817 835//831
+f 831//836 816//818 830//832
+f 826//812 841//830 842//833
+f 837//838 822//834 836//835
+f 832//839 817//821 831//836
+f 827//815 842//833 843//837
+f 838//840 823//820 837//838
+f 833//841 818//823 832//839
+f 839//843 824//822 838//840
+f 834//828 819//825 833//841
+f 832//839 847//853 848//842
+f 854//846 839//843 853//844
+f 833//841 848//842 849//845
+f 855//849 840//827 854//846
+f 834//828 849//845 850//847
+f 829//829 844//866 845//848
+f 856//851 841//830 855//849
+f 851//852 836//835 850//847
+f 830//832 845//848 846//850
+f 857//854 842//833 856//851
+f 852//855 837//838 851//852
+f 831//836 846//850 847//853
+f 858//858 843//837 857//854
+f 853//844 838//840 852//855
+f 867//860 852//855 866//856
+f 846//850 861//869 862//857
+f 873//876 858//858 872//859
+f 868//862 853//844 867//860
+f 847//853 862//857 863//861
+f 869//864 854//846 868//862
+f 848//842 863//861 864//863
+f 870//868 855//849 869//864
+f 849//845 864//863 865//865
+f 844//866 859//884 860//867
+f 871//870 856//851 870//868
+f 850//847 865//865 866//856
+f 845//848 860//867 861//869
+f 872//859 857//854 871//870
+f 886//874 871//870 885//871
+f 865//865 880//883 881//872
+f 860//867 875//885 876//873
+f 887//877 872//859 886//874
+f 882//878 867//860 881//872
+f 861//869 876//873 877//875
+f 888//895 873//876 887//877
+f 883//880 868//862 882//878
+f 862//857 877//875 878//879
+f 884//882 869//864 883//880
+f 863//861 878//879 879//881
+f 885//871 870//868 884//882
+f 864//863 879//881 880//883
+f 859//884 874//888 875//885
+f 900//890 885//871 899//886
+f 879//881 894//900 895//887
+f 874//888 889//905 890//889
+f 901//893 886//874 900//890
+f 880//883 895//887 896//891
+f 875//885 890//889 891//892
+f 902//896 887//877 901//893
+f 897//897 882//878 896//891
+f 876//873 891//892 892//894
+f 903//912 888//895 902//896
+f 898//899 883//880 897//897
+f 877//875 892//894 893//898
+f 899//886 884//882 898//899
+f 878//879 893//898 894//900
+f 914//903 899//886 913//901
+f 893//898 908//915 909//902
+f 915//907 900//890 914//903
+f 894//900 909//902 910//904
+f 889//905 904//925 905//906
+f 916//910 901//893 915//907
+f 895//887 910//904 911//908
+f 890//889 905//906 906//909
+f 917//913 902//896 916//910
+f 912//914 897//897 911//908
+f 891//892 906//909 907//911
+f 918//917 903//912 917//913
+f 913//901 898//899 912//914
+f 892//894 907//911 908//915
+f 906//909 921//929 922//916
+f 933//936 918//917 932//918
+f 928//921 913//901 927//919
+f 907//911 922//916 923//920
+f 929//923 914//903 928//921
+f 908//915 923//920 924//922
+f 930//927 915//907 929//923
+f 909//902 924//922 925//924
+f 904//925 919//943 920//926
+f 931//930 916//910 930//927
+f 910//904 925//924 926//928
+f 905//906 920//926 921//929
+f 932//918 917//913 931//930
+f 927//919 912//914 926//928
+f 925//924 941//942 942//931
+f 920//926 936//944 937//932
+f 948//937 932//918 947//933
+f 926//928 942//931 943//934
+f 921//929 937//932 938//935
+f 949//956 933//936 948//937
+f 944//939 928//921 943//934
+f 922//916 938//935 939//938
+f 945//941 929//923 944//939
+f 923//920 939//938 940//940
+f 946//945 930//927 945//941
+f 924//922 940//940 941//942
+f 919//943 935//948 936//944
+f 947//933 931//930 946//945
+f 961//950 946//945 960//946
+f 940//940 955//960 956//947
+f 935//948 950//964 951//949
+f 962//953 947//933 961//950
+f 941//942 956//947 957//951
+f 936//944 951//949 952//952
+f 963//957 948//937 962//953
+f 942//931 957//951 958//954
+f 937//932 952//952 953//955
+f 964//963 949//956 963//957
+f 943//934 958//954 959//958
+f 938//935 953//955 954//959
+f 944//939 959//958 960//946
+f 939//938 954//959 955//960
+f 959//958 492//504 493//508
+f 488//484 955//960 487//506
+f 960//946 493//508 494//490
+f 955//960 488//484 489//483
+f 484//486 951//949 483//487
+f 961//950 494//490 495//489
+f 956//947 489//483 490//492
+f 485//494 952//952 484//486
+f 962//953 495//489 496//496
+f 957//951 490//492 491//498
+f 486//500 953//955 485//494
+f 963//957 496//496 497//502
+f 958//954 491//498 492//504
+f 487//506 954//959 486//500
+f 986//512 971//483 985//485
+f 981//969 966//486 980//965
+f 976//966 991//511 992//967
+f 971//483 986//512 987//968
+f 982//970 967//494 981//969
+f 977//489 992//967 993//497
+f 972//492 987//968 988//499
+f 983//507 968//500 982//970
+f 978//496 993//497 994//503
+f 973//498 988//499 989//505
+f 984//510 969//506 983//507
+f 974//504 989//505 990//509
+f 985//485 970//484 984//510
+f 975//972 990//509 991//511
+f 1001//530 986//512 1000//973
+f 996//517 981//969 995//514
+f 991//511 1006//526 1007//974
+f 986//512 1001//530 1002//516
+f 997//976 982//970 996//517
+f 992//967 1007//974 1008//975
+f 987//968 1002//516 1003//519
+f 998//523 983//507 997//976
+f 993//497 1008//975 1009//977
+f 988//499 1003//519 1004//522
+f 999//525 984//510 998//523
+f 989//505 1004//522 1005//978
+f 1000//973 985//485 999//525
+f 990//509 1005//978 1006//526
+f 1004//522 1019//540 1020//527
+f 1015//531 1000//973 1014//528
+f 1005//978 1020//527 1021//979
+f 1016//983 1001//530 1015//531
+f 1011//535 996//517 1010//532
+f 1006//526 1021//979 1022//533
+f 1001//530 1016//983 1017//534
+f 1012//538 997//976 1011//535
+f 1007//974 1022//533 1023//980
+f 1002//516 1017//534 1018//981
+f 1013//541 998//523 1012//538
+f 1008//975 1023//980 1024//539
+f 1003//519 1018//981 1019//540
+f 1014//528 999//525 1013//541
+f 1023//980 1038//554 1039//982
+f 1018//981 1033//555 1034//543
+f 1029//546 1014//528 1028//544
+f 1019//540 1034//543 1035//545
+f 1030//549 1015//531 1029//546
+f 1020//527 1035//545 1036//547
+f 1031//988 1016//983 1030//549
+f 1026//553 1011//535 1025//550
+f 1021//979 1036//547 1037//984
+f 1016//983 1031//988 1032//552
+f 1027//985 1012//538 1026//553
+f 1022//533 1037//984 1038//554
+f 1017//534 1032//552 1033//555
+f 1028//544 1013//541 1027//985
+f 1042//560 1027//985 1041//557
+f 1037//984 1052//989 1053//558
+f 1032//552 1047//990 1048//986
+f 1043//563 1028//544 1042//560
+f 1038//554 1053//558 1054//561
+f 1033//555 1048//986 1049//562
+f 1044//565 1029//546 1043//563
+f 1034//543 1049//562 1050//564
+f 1045//568 1030//549 1044//565
+f 1035//545 1050//564 1051//987
+f 1046//572 1031//988 1045//568
+f 1041//557 1026//553 1040//569
+f 1036//547 1051//987 1052//989
+f 1031//988 1046//572 1047//990
+f 1061//590 1046//572 1060//573
+f 1056//577 1041//557 1055//574
+f 1051//987 1066//586 1067//991
+f 1046//572 1061//590 1062//576
+f 1057//580 1042//560 1056//577
+f 1052//989 1067//991 1068//578
+f 1047//990 1062//576 1063//579
+f 1058//583 1043//563 1057//580
+f 1053//558 1068//578 1069//581
+f 1048//986 1063//579 1064//582
+f 1059//992 1044//565 1058//583
+f 1049//562 1064//582 1065//584
+f 1060//573 1045//568 1059//992
+f 1050//564 1065//584 1066//586
+f 1064//582 1079//600 1080//993
+f 1059//992 1074//604 1075//994
+f 1065//584 1080//993 1081//589
+f 1060//573 1075//994 1076//591
+f 1071//595 1056//577 1070//995
+f 1066//586 1081//589 1082//593
+f 1061//590 1076//591 1077//594
+f 1072//598 1057//580 1071//595
+f 1067//991 1082//593 1083//996
+f 1062//576 1077//594 1078//597
+f 1073//997 1058//583 1072//598
+f 1068//578 1083//996 1084//599
+f 1063//579 1078//597 1079//600
+f 1074//604 1059//992 1073//997
+f 1099//619 1084//599 1098//602
+f 1094//606 1079//600 1093//998
+f 1073//997 1088//615 1089//999
+f 1095//1000 1080//993 1094//606
+f 1074//604 1089//999 1090//607
+f 1096//611 1081//589 1095//1000
+f 1075//994 1090//607 1091//609
+f 1070//995 1085//627 1086//1001
+f 1097//614 1082//593 1096//611
+f 1076//591 1091//609 1092//1002
+f 1071//595 1086//1001 1087//613
+f 1098//602 1083//996 1097//614
+f 1077//594 1092//1002 1093//998
+f 1072//598 1087//613 1088//615
+f 1113//620 1098//602 1112//1003
+f 1108//1004 1093//998 1107//617
+f 1087//613 1102//630 1103//618
+f 1114//1011 1099//619 1113//620
+f 1109//623 1094//606 1108//1004
+f 1088//615 1103//618 1104//622
+f 1110//625 1095//1000 1109//623
+f 1089//999 1104//622 1105//1005
+f 1111//1007 1096//611 1110//625
+f 1090//607 1105//1005 1106//626
+f 1085//627 1100//1008 1101//1006
+f 1112//1003 1097//614 1111//1007
+f 1091//609 1106//626 1107//617
+f 1086//1001 1101//1006 1102//630
+f 1100//1008 1115//649 1116//632
+f 1127//636 1112//1003 1126//633
+f 1106//626 1121//645 1122//634
+f 1101//1006 1116//632 1117//1009
+f 1128//639 1113//620 1127//636
+f 1123//640 1108//1004 1122//634
+f 1102//630 1117//1009 1118//1010
+f 1129//656 1114//1011 1128//639
+f 1124//1012 1109//623 1123//640
+f 1103//618 1118//1010 1119//641
+f 1125//644 1110//625 1124//1012
+f 1104//622 1119//641 1120//643
+f 1126//633 1111//1007 1125//644
+f 1105//1005 1120//643 1121//645
+f 1119//641 1134//1018 1135//1013
+f 1141//1016 1126//633 1140//1014
+f 1120//643 1135//1013 1136//648
+f 1115//649 1130//1021 1131//1015
+f 1142//654 1127//636 1141//1016
+f 1121//645 1136//648 1137//652
+f 1116//632 1131//1015 1132//653
+f 1143//1017 1128//639 1142//654
+f 1138//658 1123//640 1137//652
+f 1117//1009 1132//653 1133//655
+f 1144//1023 1129//656 1143//1017
+f 1139//660 1124//1012 1138//658
+f 1118//1010 1133//655 1134//1018
+f 1140//1014 1125//644 1139//660
+f 1154//663 1139//660 1153//1019
+f 1133//655 1148//673 1149//662
+f 1155//1020 1140//1014 1154//663
+f 1134//1018 1149//662 1150//664
+f 1156//669 1141//1016 1155//1020
+f 1135//1013 1150//664 1151//666
+f 1130//1021 1145//1028 1146//1022
+f 1157//672 1142//654 1156//669
+f 1136//648 1151//666 1152//670
+f 1131//1015 1146//1022 1147//671
+f 1158//1024 1143//1017 1157//672
+f 1153//1019 1138//658 1152//670
+f 1132//653 1147//671 1148//673
+f 1159//1026 1144//1023 1158//1024
+f 1173//680 1158//1024 1172//676
+f 1168//681 1153//1019 1167//1025
+f 1147//671 1162//690 1163//678
+f 1174//699 1159//1026 1173//680
+f 1169//683 1154//663 1168//681
+f 1148//673 1163//678 1164//1027
+f 1170//685 1155//1020 1169//683
+f 1149//662 1164//1027 1165//684
+f 1171//1029 1156//669 1170//685
+f 1150//664 1165//684 1166//686
+f 1145//1028 1160//691 1161//688
+f 1172//676 1157//672 1171//1029
+f 1151//666 1166//686 1167//1025
+f 1146//1022 1161//688 1162//690
+f 1160//691 1175//709 1176//692
+f 1187//696 1172//676 1186//693
+f 1182//697 1167//1025 1181//694
+f 1161//688 1176//692 1177//1030
+f 1188//1032 1173//680 1187//696
+f 1183//701 1168//681 1182//697
+f 1162//690 1177//1030 1178//1031
+f 1189//1038 1174//699 1188//1032
+f 1184//703 1169//683 1183//701
+f 1163//678 1178//1031 1179//702
+f 1185//705 1170//685 1184//703
+f 1164//1027 1179//702 1180//704
+f 1186//693 1171//1029 1185//705
+f 1165//684 1180//704 1181//694
+f 1195//708 1180//704 1194//1033
+f 1201//1035 1186//693 1200//707
+f 1196//1036 1181//694 1195//708
+f 1175//709 1190//727 1191//1034
+f 1202//714 1187//696 1201//1035
+f 1197//1037 1182//697 1196//1036
+f 1176//692 1191//1034 1192//713
+f 1203//718 1188//1032 1202//714
+f 1198//1039 1183//701 1197//1037
+f 1177//1030 1192//713 1193//716
+f 1204//735 1189//1038 1203//718
+f 1199//720 1184//703 1198//1039
+f 1178//1031 1193//716 1194//1033
+f 1200//707 1185//705 1199//720
+f 1214//741 1199//720 1213//721
+f 1209//724 1194//1033 1208//722
+f 1199//720 1214//741 1215//723
+f 1210//726 1195//708 1209//724
+f 1200//707 1215//723 1216//725
+f 1211//730 1196//1036 1210//726
+f 1206//731 1191//1034 1205//1040
+f 1201//1035 1216//725 1217//729
+f 1212//733 1197//1037 1211//730
+f 1207//734 1192//713 1206//731
+f 1202//714 1217//729 1218//732
+f 1213//721 1198//1039 1212//733
+f 1208//722 1193//716 1207//734
+f 1203//718 1218//732 1219//736
+f 1217//729 1232//749 1233//737
+f 1228//1045 1213//721 1227//738
+f 1223//743 1208//722 1222//739
+f 1218//732 1233//737 1234//740
+f 1213//721 1228//1045 1229//742
+f 1224//745 1209//724 1223//743
+f 1214//741 1229//742 1230//744
+f 1225//747 1210//726 1224//745
+f 1215//723 1230//744 1231//746
+f 1226//1041 1211//730 1225//747
+f 1221//1042 1206//731 1220//748
+f 1216//725 1231//746 1232//749
+f 1227//738 1212//733 1226//1041
+f 1222//739 1207//734 1221//1042
+f 1231//746 1246//764 1247//1043
+f 1242//757 1227//738 1241//753
+f 1237//1046 1222//739 1236//1044
+f 1232//749 1247//1043 1248//755
+f 1243//774 1228//1045 1242//757
+f 1238//761 1223//743 1237//1046
+f 1233//737 1248//755 1249//759
+f 1228//1045 1243//774 1244//1047
+f 1239//763 1224//745 1238//761
+f 1229//742 1244//1047 1245//762
+f 1240//765 1225//747 1239//763
+f 1230//744 1245//762 1246//764
+f 1241//753 1226//1041 1240//765
+f 1236//1044 1221//1042 1235//1048
+f 1245//762 1260//780 1261//1049
+f 1256//1051 1241//753 1255//768
+f 1251//1052 1236//1044 1250//1050
+f 1246//764 1261//1049 1262//770
+f 1257//1054 1242//757 1256//1051
+f 1252//1055 1237//1046 1251//1052
+f 1247//1043 1262//770 1263//1053
+f 1258//792 1243//774 1257//1054
+f 1253//1057 1238//761 1252//1055
+f 1248//755 1263//1053 1264//1056
+f 1243//774 1258//792 1259//778
+f 1254//781 1239//763 1253//1057
+f 1244//1047 1259//778 1260//780
+f 1255//768 1240//765 1254//781
+f 1269//1058 1254//781 1268//782
+f 1259//778 1274//796 1275//783
+f 1270//1059 1255//768 1269//1058
+f 1260//780 1275//783 1276//785
+f 1271//789 1256//1051 1270//1059
+f 1266//790 1251//1052 1265//1060
+f 1261//1049 1276//785 1277//1061
+f 1272//1062 1257//1054 1271//789
+f 1267//794 1252//1055 1266//790
+f 1262//770 1277//1061 1278//791
+f 1273//797 1258//792 1272//1062
+f 1268//782 1253//1057 1267//794
+f 1263//1053 1278//791 1279//795
+f 1258//792 1273//797 1274//796
+f 1288//816 1273//797 1287//798
+f 1283//802 1268//782 1282//799
+f 1278//791 1293//811 1294//1063
+f 1273//797 1288//816 1289//801
+f 1284//804 1269//1058 1283//802
+f 1274//796 1289//801 1290//803
+f 1285//806 1270//1059 1284//804
+f 1275//783 1290//803 1291//805
+f 1286//1065 1271//789 1285//806
+f 1281//810 1266//790 1280//1064
+f 1276//785 1291//805 1292//808
+f 1287//798 1272//1062 1286//1065
+f 1282//799 1267//794 1281//810
+f 1277//1061 1292//808 1293//811
+f 1291//805 1307//824 1308//1066
+f 1303//817 1287//798 1302//813
+f 1298//1067 1282//799 1297//814
+f 1292//808 1308//1066 1309//815
+f 1304//834 1288//816 1303//817
+f 1299//821 1283//802 1298//1067
+f 1293//811 1309//815 1310//1068
+f 1288//816 1304//834 1305//820
+f 1300//823 1284//804 1299//821
+f 1289//801 1305//820 1306//822
+f 1301//825 1285//806 1300//823
+f 1290//803 1306//822 1307//824
+f 1302//813 1286//1065 1301//825
+f 1297//814 1281//810 1296//1069
+f 1306//822 1321//843 1322//1070
+f 1317//1072 1302//813 1316//1071
+f 1312//1073 1297//814 1311//829
+f 1307//824 1322//1070 1323//830
+f 1318//835 1303//817 1317//1072
+f 1313//836 1298//1067 1312//1073
+f 1308//1066 1323//830 1324//833
+f 1319//838 1304//834 1318//835
+f 1314//839 1299//821 1313//836
+f 1309//815 1324//833 1325//1074
+f 1320//840 1305//820 1319//838
+f 1315//1075 1300//823 1314//839
+f 1321//843 1306//822 1320//840
+f 1316//1071 1301//825 1315//1075
+f 1314//839 1329//853 1330//1076
+f 1336//1077 1321//843 1335//844
+f 1315//1075 1330//1076 1331//845
+f 1337//849 1322//1070 1336//1077
+f 1316//1071 1331//845 1332//1078
+f 1311//829 1326//866 1327//848
+f 1338//851 1323//830 1337//849
+f 1333//852 1318//835 1332//1078
+f 1312//1073 1327//848 1328//850
+f 1339//1079 1324//833 1338//851
+f 1334//855 1319//838 1333//852
+f 1313//836 1328//850 1329//853
+f 1340//858 1325//1074 1339//1079
+f 1335//844 1320//840 1334//855
+f 1349//860 1334//855 1348//856
+f 1328//850 1343//869 1344//857
+f 1355//1082 1340//858 1354//859
+f 1350//862 1335//844 1349//860
+f 1329//853 1344//857 1345//861
+f 1351//864 1336//1077 1350//862
+f 1330//1076 1345//861 1346//863
+f 1352//868 1337//849 1351//864
+f 1331//845 1346//863 1347//1080
+f 1326//866 1341//884 1342//867
+f 1353//870 1338//851 1352//868
+f 1332//1078 1347//1080 1348//856
+f 1327//848 1342//867 1343//869
+f 1354//859 1339//1079 1353//870
+f 1368//874 1353//870 1367//1081
+f 1347//1080 1362//883 1363//872
+f 1342//867 1357//885 1358//873
+f 1369//877 1354//859 1368//874
+f 1364//878 1349//860 1363//872
+f 1343//869 1358//873 1359//875
+f 1370//895 1355//1082 1369//877
+f 1365//880 1350//862 1364//878
+f 1344//857 1359//875 1360//1083
+f 1366//1085 1351//864 1365//880
+f 1345//861 1360//1083 1361//1084
+f 1367//1081 1352//868 1366//1085
+f 1346//863 1361//1084 1362//883
+f 1341//884 1356//888 1357//885
+f 1382//1088 1367//1081 1381//1086
+f 1361//1084 1376//900 1377//1087
+f 1356//888 1371//1092 1372//889
+f 1383//893 1368//874 1382//1088
+f 1362//883 1377//1087 1378//891
+f 1357//885 1372//889 1373//1089
+f 1384//896 1369//877 1383//893
+f 1379//897 1364//878 1378//891
+f 1358//873 1373//1089 1374//894
+f 1385//912 1370//895 1384//896
+f 1380//899 1365//880 1379//897
+f 1359//875 1374//894 1375//1090
+f 1381//1086 1366//1085 1380//899
+f 1360//1083 1375//1090 1376//900
+f 1396//1091 1381//1086 1395//901
+f 1375//1090 1390//1094 1391//902
+f 1397//907 1382//1088 1396//1091
+f 1376//900 1391//902 1392//904
+f 1371//1092 1386//1098 1387//1093
+f 1398//910 1383//893 1397//907
+f 1377//1087 1392//904 1393//908
+f 1372//889 1387//1093 1388//909
+f 1399//913 1384//896 1398//910
+f 1394//914 1379//897 1393//908
+f 1373//1089 1388//909 1389//911
+f 1400//1095 1385//912 1399//913
+f 1395//901 1380//899 1394//914
+f 1374//894 1389//911 1390//1094
+f 1388//909 1403//929 1404//916
+f 1415//936 1400//1095 1414//1096
+f 1410//921 1395//901 1409//919
+f 1389//911 1404//916 1405//920
+f 1411//1097 1396//1091 1410//921
+f 1390//1094 1405//920 1406//922
+f 1412//927 1397//907 1411//1097
+f 1391//902 1406//922 1407//924
+f 1386//1098 1401//943 1402//1099
+f 1413//930 1398//910 1412//927
+f 1392//904 1407//924 1408//1100
+f 1387//1093 1402//1099 1403//929
+f 1414//1096 1399//913 1413//930
+f 1409//919 1394//914 1408//1100
+f 1407//924 1423//942 1424//931
+f 1402//1099 1418//1102 1419//932
+f 1430//937 1414//1096 1429//1101
+f 1408//1100 1424//931 1425//934
+f 1403//929 1419//932 1420//935
+f 1431//956 1415//936 1430//937
+f 1426//939 1410//921 1425//934
+f 1404//916 1420//935 1421//938
+f 1427//941 1411//1097 1426//939
+f 1405//920 1421//938 1422//940
+f 1428//945 1412//927 1427//941
+f 1406//922 1422//940 1423//942
+f 1401//943 1417//1104 1418//1102
+f 1429//1101 1413//930 1428//945
+f 1443//950 1428//945 1442//946
+f 1422//940 1437//960 1438//1103
+f 1417//1104 1432//964 1433//949
+f 1444//953 1429//1101 1443//950
+f 1423//942 1438//1103 1439//951
+f 1418//1102 1433//949 1434//952
+f 1445//1105 1430//937 1444//953
+f 1424//931 1439//951 1440//954
+f 1419//932 1434//952 1435//955
+f 1446//1106 1431//956 1445//1105
+f 1425//934 1440//954 1441//958
+f 1420//935 1435//955 1436//959
+f 1426//939 1441//958 1442//946
+f 1421//938 1436//959 1437//960
+f 1441//958 974//504 975//972
+f 970//484 1437//960 969//506
+f 1442//946 975//972 976//966
+f 1437//960 970//484 971//483
+f 966//486 1433//949 965//487
+f 1443//950 976//966 977//489
+f 1438//1103 971//483 972//492
+f 967//494 1434//952 966//486
+f 1444//953 977//489 978//496
+f 1439//951 972//492 973//498
+f 968//500 1435//955 967//494
+f 1445//1105 978//496 979//971
+f 1440//954 973//498 974//504
+f 969//506 1436//959 968//500
+o Foot_R_Sphere.013
+v 1.070087 0.436287 -0.613739
+v 1.067775 0.408819 -0.597702
+v 1.067363 0.383059 -0.583396
+v 1.068870 0.359998 -0.571371
+v 1.072236 0.340521 -0.562090
+v 1.077332 0.325377 -0.555908
+v 1.083963 0.315147 -0.553064
+v 1.091874 0.310225 -0.553667
+v 1.100760 0.310801 -0.557693
+v 1.110280 0.316851 -0.564988
+v 1.120069 0.328144 -0.575272
+v 1.129750 0.344245 -0.588149
+v 1.138951 0.364536 -0.603124
+v 1.147318 0.388237 -0.619623
+v 1.154530 0.414437 -0.637010
+v 1.070029 0.435806 -0.617730
+v 1.067660 0.407876 -0.605530
+v 1.067197 0.381690 -0.594761
+v 1.068659 0.358255 -0.585837
+v 1.071988 0.338472 -0.579100
+v 1.077056 0.323099 -0.574808
+v 1.083670 0.312730 -0.573128
+v 1.091575 0.307761 -0.574124
+v 1.100467 0.308383 -0.577757
+v 1.110004 0.314574 -0.583888
+v 1.119821 0.326095 -0.592281
+v 1.129539 0.342502 -0.602614
+v 1.138785 0.363167 -0.614490
+v 1.147204 0.387294 -0.627451
+v 1.154472 0.413956 -0.641001
+v 1.070163 0.436416 -0.622236
+v 1.067924 0.409072 -0.614368
+v 1.067580 0.383428 -0.607592
+v 1.069145 0.360466 -0.602167
+v 1.072560 0.341072 -0.598302
+v 1.077693 0.325989 -0.596145
+v 1.084346 0.315797 -0.595780
+v 1.092264 0.310888 -0.597219
+v 1.101142 0.311450 -0.600408
+v 1.110641 0.317463 -0.605225
+v 1.120393 0.328695 -0.611484
+v 1.130026 0.344713 -0.618945
+v 1.139167 0.364904 -0.627320
+v 1.147467 0.388490 -0.636289
+v 1.154606 0.414566 -0.645507
+v 1.070485 0.438093 -0.627082
+v 1.068555 0.412363 -0.623876
+v 1.068496 0.388205 -0.621395
+v 1.070312 0.366547 -0.619735
+v 1.073931 0.348221 -0.618960
+v 1.079216 0.333933 -0.619099
+v 1.085963 0.324230 -0.620147
+v 1.093913 0.319486 -0.622064
+v 1.102760 0.319884 -0.624776
+v 1.112164 0.325407 -0.628179
+v 1.121764 0.335844 -0.632142
+v 1.131192 0.350794 -0.636513
+v 1.140084 0.369681 -0.641123
+v 1.148098 0.391781 -0.645797
+v 1.154928 0.416243 -0.650353
+v 1.070982 0.440774 -0.632085
+v 1.069529 0.417621 -0.633688
+v 1.069911 0.395838 -0.635640
+v 1.072112 0.376262 -0.637865
+v 1.076049 0.359645 -0.640278
+v 1.081569 0.346627 -0.642787
+v 1.088461 0.337706 -0.645294
+v 1.096459 0.333226 -0.647703
+v 1.105257 0.333360 -0.649923
+v 1.114517 0.338101 -0.651867
+v 1.123882 0.347268 -0.653460
+v 1.132992 0.360509 -0.654643
+v 1.141498 0.377315 -0.655368
+v 1.149073 0.397039 -0.655609
+v 1.155425 0.418924 -0.655356
+v 1.071635 0.444354 -0.637050
+v 1.070810 0.424644 -0.643427
+v 1.071770 0.406034 -0.649779
+v 1.074478 0.389240 -0.655861
+v 1.078831 0.374905 -0.661439
+v 1.084660 0.363582 -0.666299
+v 1.091742 0.355706 -0.670255
+v 1.099805 0.351579 -0.673153
+v 1.108539 0.351360 -0.674883
+v 1.117608 0.355057 -0.675379
+v 1.126664 0.362528 -0.674621
+v 1.135358 0.373487 -0.672638
+v 1.143357 0.387511 -0.669507
+v 1.150353 0.404062 -0.665348
+v 1.156078 0.422504 -0.660321
+v 1.072418 0.448697 -0.641787
+v 1.072347 0.433163 -0.652719
+v 1.074001 0.418402 -0.663269
+v 1.077318 0.404980 -0.673030
+v 1.082170 0.393414 -0.681628
+v 1.088371 0.384149 -0.688732
+v 1.095682 0.377539 -0.694069
+v 1.103822 0.373840 -0.697434
+v 1.112479 0.373193 -0.698698
+v 1.121319 0.375623 -0.697812
+v 1.130004 0.381037 -0.694810
+v 1.138198 0.389227 -0.689808
+v 1.145589 0.399878 -0.682997
+v 1.151890 0.412581 -0.674640
+v 1.156861 0.426847 -0.665058
+v 1.073303 0.453636 -0.646114
+v 1.074082 0.442850 -0.661207
+v 1.076520 0.432465 -0.675592
+v 1.080524 0.422879 -0.688714
+v 1.085940 0.414462 -0.700070
+v 1.092559 0.407535 -0.709224
+v 1.100128 0.402366 -0.715823
+v 1.108355 0.399153 -0.719615
+v 1.116925 0.398020 -0.720452
+v 1.125507 0.399010 -0.718304
+v 1.133773 0.402085 -0.713252
+v 1.141404 0.407126 -0.705492
+v 1.148107 0.413942 -0.695320
+v 1.153625 0.422268 -0.683128
+v 1.157746 0.431786 -0.669385
+v 1.074254 0.458980 -0.649865
+v 1.075948 0.453333 -0.668565
+v 1.079229 0.447684 -0.686273
+v 1.083971 0.442249 -0.702309
+v 1.089994 0.437238 -0.716057
+v 1.097064 0.432843 -0.726987
+v 1.104910 0.429232 -0.734680
+v 1.113231 0.426546 -0.738841
+v 1.121707 0.424886 -0.739309
+v 1.130012 0.424317 -0.736067
+v 1.137827 0.424861 -0.729239
+v 1.144851 0.426496 -0.719087
+v 1.150816 0.429160 -0.706001
+v 1.155491 0.432751 -0.690486
+v 1.158697 0.437130 -0.673136
+v 1.075235 0.464524 -0.652895
+v 1.077873 0.464209 -0.674509
+v 1.082023 0.463473 -0.694903
+v 1.087528 0.462345 -0.713293
+v 1.094176 0.460868 -0.728972
+v 1.101711 0.459099 -0.741338
+v 1.109844 0.457106 -0.749916
+v 1.118261 0.454966 -0.754375
+v 1.126640 0.452760 -0.754545
+v 1.134659 0.450574 -0.750418
+v 1.142009 0.448491 -0.742154
+v 1.148408 0.446592 -0.730071
+v 1.153611 0.444949 -0.714632
+v 1.157416 0.443626 -0.696430
+v 1.159678 0.442674 -0.676166
+v 1.076209 0.470056 -0.655089
+v 1.079783 0.475059 -0.678813
+v 1.084797 0.479226 -0.701150
+v 1.091058 0.482394 -0.721244
+v 1.098327 0.484444 -0.738322
+v 1.106323 0.485295 -0.751727
+v 1.114740 0.484916 -0.760944
+v 1.123253 0.483320 -0.765619
+v 1.131536 0.480569 -0.765573
+v 1.139271 0.476770 -0.760807
+v 1.146160 0.472067 -0.751504
+v 1.151938 0.466641 -0.738022
+v 1.156384 0.460702 -0.720879
+v 1.159326 0.454477 -0.700733
+v 1.160652 0.448206 -0.678360
+v 1.077138 0.475362 -0.656361
+v 1.081605 0.485468 -0.681309
+v 1.087442 0.494337 -0.704774
+v 1.094425 0.501627 -0.725857
+v 1.102286 0.507059 -0.743745
+v 1.110722 0.510424 -0.757753
+v 1.119410 0.511593 -0.767341
+v 1.128015 0.510520 -0.772142
+v 1.136207 0.507246 -0.771970
+v 1.143670 0.501899 -0.766833
+v 1.150119 0.494682 -0.756927
+v 1.155306 0.485874 -0.742634
+v 1.159030 0.475813 -0.724503
+v 1.161149 0.464886 -0.703229
+v 1.161581 0.453512 -0.679632
+v 1.077987 0.480239 -0.656664
+v 1.083269 0.495035 -0.681902
+v 1.089858 0.508226 -0.705636
+v 1.097500 0.519305 -0.726953
+v 1.105902 0.527846 -0.745034
+v 1.114740 0.533521 -0.759185
+v 1.123675 0.536112 -0.768862
+v 1.132364 0.535519 -0.773692
+v 1.140472 0.531765 -0.773491
+v 1.147688 0.524995 -0.768265
+v 1.153735 0.515469 -0.758216
+v 1.158380 0.503552 -0.743730
+v 1.161445 0.489702 -0.725364
+v 1.162813 0.474453 -0.703823
+v 1.162430 0.458389 -0.679935
+v 1.078722 0.484500 -0.655985
+v 1.084711 0.503392 -0.680570
+v 1.091952 0.520359 -0.703701
+v 1.100165 0.534747 -0.724491
+v 1.109035 0.546004 -0.742140
+v 1.118221 0.553697 -0.755969
+v 1.127371 0.557530 -0.765448
+v 1.136132 0.557357 -0.770211
+v 1.144168 0.553184 -0.770076
+v 1.151169 0.545171 -0.765049
+v 1.156868 0.533627 -0.755322
+v 1.161045 0.518994 -0.741269
+v 1.163539 0.501835 -0.723430
+v 1.164255 0.482810 -0.702490
+v 1.163165 0.462650 -0.679256
+v 1.079315 0.487980 -0.654350
+v 1.085876 0.510219 -0.677363
+v 1.093642 0.530269 -0.699046
+v 1.102317 0.547360 -0.718566
+v 1.111565 0.560836 -0.735172
+v 1.121033 0.570177 -0.748227
+v 1.130355 0.575026 -0.757229
+v 1.139175 0.575196 -0.761832
+v 1.147152 0.570680 -0.761858
+v 1.153981 0.561652 -0.757307
+v 1.159398 0.548459 -0.748354
+v 1.163197 0.531607 -0.735343
+v 1.165230 0.511746 -0.718774
+v 1.165419 0.489637 -0.699284
+v 1.163758 0.466130 -0.677621
+v 1.079745 0.490546 -0.651822
+v 1.086718 0.515252 -0.672405
+v 1.094865 0.537576 -0.691848
+v 1.103873 0.556661 -0.709405
+v 1.113395 0.571772 -0.724400
+v 1.123066 0.582329 -0.736258
+v 1.132514 0.587926 -0.744522
+v 1.141376 0.588349 -0.748876
+v 1.149311 0.583580 -0.749151
+v 1.156014 0.573803 -0.745338
+v 1.161228 0.559395 -0.737582
+v 1.164753 0.540908 -0.726182
+v 1.166453 0.519053 -0.711577
+v 1.166262 0.494670 -0.694326
+v 1.164188 0.468696 -0.675093
+v 1.079993 0.492099 -0.648499
+v 1.087206 0.518299 -0.665887
+v 1.095573 0.542000 -0.682385
+v 1.104774 0.562291 -0.697360
+v 1.114455 0.578392 -0.710237
+v 1.124243 0.589685 -0.720521
+v 1.133764 0.595735 -0.727816
+v 1.142650 0.596310 -0.731842
+v 1.150560 0.591389 -0.732445
+v 1.157191 0.581159 -0.729601
+v 1.162288 0.566015 -0.723419
+v 1.165654 0.546538 -0.714138
+v 1.167160 0.523476 -0.702113
+v 1.166749 0.497717 -0.687807
+v 1.164436 0.470249 -0.671770
+v 1.080052 0.492580 -0.644508
+v 1.087320 0.519242 -0.658058
+v 1.095739 0.543369 -0.671019
+v 1.104985 0.564033 -0.682895
+v 1.114703 0.580441 -0.693228
+v 1.124519 0.591962 -0.701621
+v 1.134057 0.598152 -0.707752
+v 1.142949 0.598775 -0.711385
+v 1.150853 0.593806 -0.712381
+v 1.157467 0.583436 -0.710701
+v 1.162536 0.568064 -0.706410
+v 1.165865 0.548280 -0.699672
+v 1.167326 0.524845 -0.690748
+v 1.166864 0.498660 -0.679979
+v 1.164495 0.470730 -0.667779
+v 1.079917 0.491970 -0.640003
+v 1.087057 0.518046 -0.649220
+v 1.095356 0.541632 -0.658189
+v 1.104498 0.561822 -0.666564
+v 1.114131 0.577841 -0.674025
+v 1.123883 0.589073 -0.680284
+v 1.133381 0.595085 -0.685101
+v 1.142260 0.595648 -0.688290
+v 1.150178 0.590739 -0.689730
+v 1.156831 0.580547 -0.689364
+v 1.161964 0.565464 -0.687207
+v 1.165378 0.546069 -0.683342
+v 1.166944 0.523108 -0.677917
+v 1.166600 0.497463 -0.671141
+v 1.164360 0.470120 -0.663274
+v 1.079596 0.490292 -0.635156
+v 1.086425 0.514755 -0.639712
+v 1.094440 0.536855 -0.644386
+v 1.103332 0.555742 -0.648996
+v 1.112759 0.570692 -0.653367
+v 1.122360 0.581128 -0.657331
+v 1.131764 0.586652 -0.660733
+v 1.140611 0.587049 -0.663445
+v 1.148561 0.582306 -0.665362
+v 1.155308 0.572603 -0.666410
+v 1.160592 0.558315 -0.666549
+v 1.164212 0.539989 -0.665774
+v 1.166028 0.518331 -0.664114
+v 1.165969 0.494173 -0.661633
+v 1.164039 0.468442 -0.658427
+v 1.079099 0.487612 -0.630154
+v 1.085451 0.509497 -0.629900
+v 1.093026 0.529221 -0.630141
+v 1.101532 0.546027 -0.630866
+v 1.110642 0.559267 -0.632049
+v 1.120007 0.568435 -0.633642
+v 1.129266 0.573176 -0.635586
+v 1.138065 0.573309 -0.637806
+v 1.146063 0.568830 -0.640215
+v 1.152955 0.559909 -0.642722
+v 1.158475 0.546890 -0.645231
+v 1.162411 0.530274 -0.647644
+v 1.164613 0.510698 -0.649869
+v 1.164994 0.488915 -0.651821
+v 1.163542 0.465762 -0.653425
+v 1.078446 0.484031 -0.625189
+v 1.084170 0.502474 -0.620161
+v 1.091167 0.519025 -0.616002
+v 1.099166 0.533049 -0.612871
+v 1.107860 0.544007 -0.610888
+v 1.116916 0.551479 -0.610130
+v 1.125985 0.555176 -0.610626
+v 1.134719 0.554956 -0.612356
+v 1.142781 0.550829 -0.615255
+v 1.149864 0.542953 -0.619210
+v 1.155693 0.531630 -0.624070
+v 1.160046 0.517296 -0.629648
+v 1.162754 0.500501 -0.635730
+v 1.163714 0.481891 -0.642082
+v 1.162889 0.462181 -0.648460
+v 1.160311 0.442129 -0.654618
+v 1.077662 0.479688 -0.620452
+v 1.082633 0.493955 -0.610869
+v 1.088935 0.506657 -0.602512
+v 1.096325 0.517308 -0.595701
+v 1.104520 0.525498 -0.590699
+v 1.113205 0.530912 -0.587697
+v 1.122045 0.533343 -0.586811
+v 1.130702 0.532696 -0.588075
+v 1.138842 0.528996 -0.591440
+v 1.146153 0.522387 -0.596777
+v 1.152353 0.513121 -0.603881
+v 1.157205 0.501555 -0.612479
+v 1.160522 0.488134 -0.622240
+v 1.162177 0.473372 -0.632790
+v 1.162105 0.457838 -0.643723
+v 1.076778 0.474750 -0.616124
+v 1.080899 0.484268 -0.602381
+v 1.086416 0.492594 -0.590189
+v 1.093120 0.499409 -0.580018
+v 1.100751 0.504451 -0.572257
+v 1.109017 0.507526 -0.567205
+v 1.117599 0.508516 -0.565057
+v 1.126169 0.507383 -0.565895
+v 1.134396 0.504170 -0.569686
+v 1.141965 0.499001 -0.576285
+v 1.148584 0.492074 -0.585439
+v 1.154000 0.483656 -0.596795
+v 1.158004 0.474071 -0.609918
+v 1.160442 0.463686 -0.624302
+v 1.161221 0.452900 -0.639395
+v 1.075827 0.469406 -0.612374
+v 1.079033 0.473785 -0.595023
+v 1.083708 0.477376 -0.579508
+v 1.089672 0.480040 -0.566422
+v 1.096697 0.481675 -0.556271
+v 1.104512 0.482218 -0.549442
+v 1.112817 0.481649 -0.546200
+v 1.121293 0.479990 -0.546668
+v 1.129614 0.477303 -0.550829
+v 1.137460 0.473693 -0.558522
+v 1.144530 0.469298 -0.569453
+v 1.150552 0.464287 -0.583200
+v 1.155295 0.458852 -0.599236
+v 1.158576 0.453203 -0.616944
+v 1.160270 0.447556 -0.635645
+v 1.074845 0.463862 -0.609343
+v 1.077108 0.462909 -0.589079
+v 1.080913 0.461586 -0.570878
+v 1.086115 0.459944 -0.555438
+v 1.092515 0.458045 -0.543355
+v 1.099865 0.455962 -0.535091
+v 1.107883 0.453776 -0.530965
+v 1.116263 0.451570 -0.531134
+v 1.124680 0.449430 -0.535594
+v 1.132813 0.447437 -0.544171
+v 1.140348 0.445668 -0.556537
+v 1.146995 0.444191 -0.572216
+v 1.152500 0.443063 -0.590606
+v 1.156651 0.442327 -0.611000
+v 1.159288 0.442012 -0.632614
+v 1.073872 0.458330 -0.607149
+v 1.075197 0.452059 -0.584776
+v 1.078140 0.445834 -0.564631
+v 1.082585 0.439894 -0.547487
+v 1.088364 0.434469 -0.534005
+v 1.095253 0.429766 -0.524702
+v 1.102987 0.425966 -0.519936
+v 1.111271 0.423216 -0.519890
+v 1.119784 0.421620 -0.524565
+v 1.128201 0.421241 -0.533782
+v 1.136197 0.422092 -0.547187
+v 1.143465 0.424141 -0.564265
+v 1.149727 0.427310 -0.584359
+v 1.154741 0.431476 -0.606697
+v 1.158315 0.436480 -0.630420
+v 1.072943 0.453024 -0.605877
+v 1.073375 0.441650 -0.582280
+v 1.075494 0.430722 -0.561007
+v 1.079218 0.420661 -0.542875
+v 1.084404 0.411853 -0.528582
+v 1.090853 0.404637 -0.518676
+v 1.098317 0.399289 -0.513539
+v 1.106509 0.396016 -0.513367
+v 1.115114 0.394943 -0.518168
+v 1.123801 0.396112 -0.527756
+v 1.132238 0.399476 -0.541764
+v 1.140098 0.404908 -0.559653
+v 1.147081 0.412199 -0.580735
+v 1.152919 0.421067 -0.604201
+v 1.157386 0.431174 -0.629148
+v 1.072094 0.448146 -0.605574
+v 1.071711 0.432083 -0.581686
+v 1.073078 0.416833 -0.560145
+v 1.076143 0.402984 -0.541779
+v 1.080789 0.391067 -0.527293
+v 1.086836 0.381541 -0.517244
+v 1.094052 0.374770 -0.512018
+v 1.102160 0.371017 -0.511817
+v 1.110849 0.370424 -0.516647
+v 1.119784 0.373015 -0.526324
+v 1.128622 0.378690 -0.540475
+v 1.137023 0.387231 -0.558556
+v 1.144665 0.398310 -0.579874
+v 1.151255 0.411501 -0.603607
+v 1.156537 0.426296 -0.628845
+v 1.071359 0.443886 -0.606254
+v 1.070269 0.423726 -0.583019
+v 1.070985 0.404701 -0.562080
+v 1.073479 0.387542 -0.544241
+v 1.077656 0.372909 -0.530187
+v 1.083354 0.361364 -0.520460
+v 1.090356 0.353352 -0.515433
+v 1.098392 0.349178 -0.515298
+v 1.107153 0.349005 -0.520062
+v 1.116302 0.352839 -0.529540
+v 1.125489 0.360532 -0.543369
+v 1.134359 0.371789 -0.561018
+v 1.142572 0.386177 -0.581808
+v 1.149812 0.403143 -0.604940
+v 1.155802 0.422036 -0.629525
+v 1.074213 0.464407 -0.630891
+v 1.070765 0.440406 -0.607888
+v 1.069104 0.416899 -0.586225
+v 1.069294 0.394790 -0.566735
+v 1.071327 0.374928 -0.550166
+v 1.075125 0.358077 -0.537155
+v 1.080543 0.344884 -0.528202
+v 1.087372 0.335856 -0.523651
+v 1.095349 0.331340 -0.523678
+v 1.104168 0.331510 -0.528280
+v 1.113491 0.336358 -0.537282
+v 1.122959 0.345700 -0.550337
+v 1.132207 0.359175 -0.566943
+v 1.140881 0.376267 -0.586463
+v 1.148648 0.396317 -0.608146
+v 1.155208 0.418556 -0.631159
+v 1.070336 0.437840 -0.610416
+v 1.068262 0.411866 -0.591183
+v 1.068071 0.387483 -0.573933
+v 1.069771 0.365628 -0.559327
+v 1.073295 0.347141 -0.547927
+v 1.078510 0.332732 -0.540171
+v 1.085213 0.322956 -0.536358
+v 1.093148 0.318187 -0.536633
+v 1.102010 0.318610 -0.540987
+v 1.111458 0.324207 -0.549251
+v 1.121129 0.334764 -0.561109
+v 1.130651 0.349875 -0.576104
+v 1.139659 0.368959 -0.593661
+v 1.147806 0.391284 -0.613104
+v 1.154779 0.415990 -0.633687
+v 1.075639 0.467351 -0.512964
+v 1.073326 0.439884 -0.496926
+v 1.072915 0.414124 -0.482621
+v 1.074422 0.391063 -0.470596
+v 1.077788 0.371585 -0.461315
+v 1.082884 0.356441 -0.455133
+v 1.089515 0.346212 -0.452289
+v 1.097425 0.341290 -0.452892
+v 1.106312 0.341865 -0.456918
+v 1.115832 0.347916 -0.464213
+v 1.125621 0.359208 -0.474496
+v 1.135301 0.375310 -0.487373
+v 1.144502 0.395600 -0.502349
+v 1.152870 0.419301 -0.518847
+v 1.160082 0.445501 -0.536235
+v 1.075581 0.466870 -0.516955
+v 1.073212 0.438940 -0.504755
+v 1.072749 0.412755 -0.493986
+v 1.074210 0.389320 -0.485061
+v 1.077539 0.369536 -0.478324
+v 1.082608 0.354164 -0.474033
+v 1.089222 0.343794 -0.472353
+v 1.097127 0.338825 -0.473349
+v 1.106019 0.339448 -0.476982
+v 1.115556 0.345639 -0.483113
+v 1.125372 0.357159 -0.491506
+v 1.135090 0.373567 -0.501839
+v 1.144336 0.394231 -0.513714
+v 1.152755 0.418358 -0.526676
+v 1.160024 0.445020 -0.540226
+v 1.075715 0.467480 -0.521460
+v 1.073475 0.440137 -0.513593
+v 1.073132 0.414492 -0.506817
+v 1.074697 0.391531 -0.501392
+v 1.078112 0.372136 -0.497527
+v 1.083244 0.357053 -0.495370
+v 1.089897 0.346861 -0.495004
+v 1.097815 0.341952 -0.496444
+v 1.106694 0.342515 -0.499633
+v 1.116192 0.348528 -0.504450
+v 1.125945 0.359759 -0.510709
+v 1.135577 0.375778 -0.518169
+v 1.144719 0.395968 -0.526545
+v 1.153019 0.419555 -0.535514
+v 1.160158 0.445630 -0.544731
+v 1.076037 0.469158 -0.526307
+v 1.074107 0.443428 -0.523101
+v 1.074048 0.419269 -0.520620
+v 1.075863 0.397611 -0.518960
+v 1.079483 0.379286 -0.518184
+v 1.084768 0.364997 -0.518323
+v 1.091515 0.355295 -0.519371
+v 1.099465 0.350551 -0.521288
+v 1.108312 0.350948 -0.524000
+v 1.117716 0.356472 -0.527403
+v 1.127316 0.366909 -0.531366
+v 1.136743 0.381858 -0.535737
+v 1.145635 0.400746 -0.540348
+v 1.153650 0.422845 -0.545022
+v 1.160480 0.447308 -0.549578
+v 1.076534 0.471838 -0.531309
+v 1.075081 0.448686 -0.532913
+v 1.075463 0.426903 -0.534865
+v 1.077664 0.407327 -0.537090
+v 1.081600 0.390710 -0.539503
+v 1.087121 0.377691 -0.542011
+v 1.094012 0.368770 -0.544519
+v 1.102011 0.364291 -0.546928
+v 1.110809 0.364424 -0.549147
+v 1.120069 0.369166 -0.551091
+v 1.129433 0.378333 -0.552685
+v 1.138544 0.391574 -0.553867
+v 1.147050 0.408379 -0.554593
+v 1.154625 0.428103 -0.554833
+v 1.160977 0.449988 -0.554580
+v 1.077186 0.475419 -0.536274
+v 1.076361 0.455709 -0.542652
+v 1.077322 0.437099 -0.549004
+v 1.080030 0.420304 -0.555085
+v 1.084382 0.405970 -0.560664
+v 1.090212 0.394647 -0.565524
+v 1.097294 0.386771 -0.569479
+v 1.105357 0.382644 -0.572378
+v 1.114091 0.382425 -0.574108
+v 1.123160 0.386122 -0.574604
+v 1.132215 0.393593 -0.573846
+v 1.140910 0.404551 -0.571863
+v 1.148909 0.418575 -0.568732
+v 1.155905 0.435127 -0.564573
+v 1.161629 0.453569 -0.559545
+v 1.077970 0.479762 -0.541011
+v 1.077899 0.464228 -0.551944
+v 1.079553 0.449466 -0.562494
+v 1.082870 0.436045 -0.572255
+v 1.087722 0.424479 -0.580853
+v 1.093923 0.415213 -0.587957
+v 1.101233 0.408604 -0.593294
+v 1.109374 0.404905 -0.596659
+v 1.118030 0.404258 -0.597923
+v 1.126871 0.406688 -0.597037
+v 1.135555 0.412102 -0.594035
+v 1.143750 0.420292 -0.589033
+v 1.151140 0.430943 -0.582222
+v 1.157442 0.443646 -0.573865
+v 1.162413 0.457912 -0.564282
+v 1.078855 0.484700 -0.545338
+v 1.079633 0.473915 -0.560432
+v 1.082072 0.463530 -0.574816
+v 1.086076 0.453944 -0.587939
+v 1.091491 0.445526 -0.599295
+v 1.098111 0.438600 -0.608449
+v 1.105680 0.433431 -0.615048
+v 1.113907 0.430218 -0.618839
+v 1.122476 0.429084 -0.619677
+v 1.131059 0.430074 -0.617529
+v 1.139325 0.433149 -0.612477
+v 1.146956 0.438191 -0.604716
+v 1.153659 0.445006 -0.594545
+v 1.159177 0.453332 -0.582353
+v 1.163297 0.462850 -0.568609
+v 1.079806 0.490044 -0.549089
+v 1.081499 0.484398 -0.567790
+v 1.084780 0.478748 -0.585498
+v 1.089523 0.473314 -0.601534
+v 1.095545 0.468302 -0.615281
+v 1.102615 0.463907 -0.626212
+v 1.110461 0.460297 -0.633905
+v 1.118782 0.457610 -0.638066
+v 1.127258 0.455951 -0.638534
+v 1.135563 0.455382 -0.635291
+v 1.143378 0.455925 -0.628463
+v 1.150403 0.457561 -0.618311
+v 1.156368 0.460225 -0.605226
+v 1.161043 0.463815 -0.589710
+v 1.164249 0.468194 -0.572360
+v 1.080787 0.495589 -0.552120
+v 1.083424 0.495273 -0.573734
+v 1.087575 0.494537 -0.594128
+v 1.093080 0.493409 -0.612518
+v 1.099728 0.491933 -0.628197
+v 1.107263 0.490164 -0.640563
+v 1.115395 0.488171 -0.649140
+v 1.123813 0.486030 -0.653600
+v 1.132192 0.483824 -0.653769
+v 1.140211 0.481638 -0.649643
+v 1.147561 0.479555 -0.641379
+v 1.153960 0.477656 -0.629295
+v 1.159162 0.476014 -0.613856
+v 1.162968 0.474691 -0.595655
+v 1.165230 0.473739 -0.575391
+v 1.081761 0.501120 -0.554313
+v 1.085335 0.506124 -0.578037
+v 1.090348 0.510290 -0.600375
+v 1.096610 0.513459 -0.620469
+v 1.103879 0.515508 -0.637547
+v 1.111875 0.516360 -0.650951
+v 1.120291 0.515980 -0.660169
+v 1.128805 0.514385 -0.664844
+v 1.137088 0.511634 -0.664798
+v 1.144823 0.507834 -0.660031
+v 1.151712 0.503131 -0.650728
+v 1.157490 0.497706 -0.637246
+v 1.161936 0.491767 -0.620103
+v 1.164878 0.485542 -0.599958
+v 1.166204 0.479270 -0.577584
+v 1.082690 0.506427 -0.555586
+v 1.087157 0.516533 -0.580533
+v 1.092994 0.525402 -0.603999
+v 1.099977 0.532692 -0.625081
+v 1.107838 0.538124 -0.642970
+v 1.116274 0.541489 -0.656978
+v 1.124962 0.542657 -0.666566
+v 1.133567 0.541584 -0.671367
+v 1.141758 0.538311 -0.671195
+v 1.149222 0.532963 -0.666058
+v 1.155671 0.525747 -0.656152
+v 1.160857 0.516939 -0.641859
+v 1.164581 0.506878 -0.623727
+v 1.166700 0.495951 -0.602454
+v 1.167133 0.484577 -0.578857
+v 1.083538 0.511304 -0.555888
+v 1.088821 0.526100 -0.581127
+v 1.095410 0.539290 -0.604860
+v 1.103052 0.550369 -0.626178
+v 1.111454 0.558910 -0.644259
+v 1.120292 0.564585 -0.658410
+v 1.129227 0.567176 -0.668087
+v 1.137915 0.566583 -0.672917
+v 1.146023 0.562830 -0.672716
+v 1.153240 0.556060 -0.667490
+v 1.159287 0.546533 -0.657441
+v 1.163932 0.534616 -0.642955
+v 1.166997 0.520767 -0.624589
+v 1.168365 0.505517 -0.603047
+v 1.167981 0.489454 -0.579159
+v 1.084273 0.515564 -0.555209
+v 1.090263 0.534457 -0.579794
+v 1.097503 0.551423 -0.602926
+v 1.105717 0.565811 -0.623716
+v 1.114587 0.577068 -0.641364
+v 1.123773 0.584761 -0.655194
+v 1.132923 0.588595 -0.664672
+v 1.141683 0.588422 -0.669436
+v 1.149719 0.584249 -0.669301
+v 1.156721 0.576236 -0.664274
+v 1.162420 0.564691 -0.654546
+v 1.166597 0.550058 -0.640493
+v 1.169091 0.532900 -0.622654
+v 1.169806 0.513875 -0.601715
+v 1.168716 0.493714 -0.578480
+v 1.084867 0.519044 -0.553575
+v 1.091428 0.541283 -0.576588
+v 1.099194 0.561334 -0.598271
+v 1.107868 0.578425 -0.617791
+v 1.117117 0.591900 -0.634397
+v 1.126584 0.601242 -0.647452
+v 1.135907 0.606091 -0.656454
+v 1.144727 0.606260 -0.661056
+v 1.152704 0.601744 -0.661083
+v 1.159532 0.592716 -0.656532
+v 1.164950 0.579523 -0.647579
+v 1.168748 0.562672 -0.634568
+v 1.170781 0.542810 -0.617999
+v 1.170971 0.520701 -0.598508
+v 1.169310 0.497194 -0.576846
+v 1.085297 0.521610 -0.551047
+v 1.092270 0.546317 -0.571630
+v 1.100417 0.568641 -0.591073
+v 1.109425 0.587725 -0.608630
+v 1.118947 0.602836 -0.623625
+v 1.128618 0.613393 -0.635483
+v 1.138066 0.618991 -0.643747
+v 1.146927 0.619413 -0.648101
+v 1.154862 0.614645 -0.648376
+v 1.161566 0.604868 -0.644563
+v 1.166780 0.590459 -0.636807
+v 1.170305 0.571972 -0.625407
+v 1.172004 0.550117 -0.610801
+v 1.171813 0.525734 -0.593551
+v 1.169739 0.499760 -0.574318
+v 1.085545 0.523164 -0.547724
+v 1.092757 0.549364 -0.565111
+v 1.101125 0.573064 -0.581610
+v 1.110326 0.593355 -0.596585
+v 1.120007 0.609456 -0.609462
+v 1.129795 0.620749 -0.619746
+v 1.139315 0.626799 -0.627041
+v 1.148202 0.627375 -0.631067
+v 1.156112 0.622453 -0.631669
+v 1.162743 0.612224 -0.628825
+v 1.167840 0.597079 -0.622644
+v 1.171206 0.577602 -0.613362
+v 1.172712 0.554541 -0.601338
+v 1.172301 0.528781 -0.587032
+v 1.169988 0.501314 -0.570995
+v 1.085603 0.523645 -0.543733
+v 1.092872 0.550307 -0.557283
+v 1.101291 0.574434 -0.570244
+v 1.110537 0.595098 -0.582119
+v 1.120255 0.611506 -0.592452
+v 1.130071 0.623026 -0.600845
+v 1.139608 0.629217 -0.606976
+v 1.148500 0.629840 -0.610610
+v 1.156405 0.624871 -0.611605
+v 1.163019 0.614501 -0.609925
+v 1.168088 0.599129 -0.605634
+v 1.171417 0.579345 -0.598897
+v 1.172878 0.555910 -0.589972
+v 1.172415 0.529724 -0.579203
+v 1.170046 0.501794 -0.567004
+v 1.085469 0.523034 -0.539227
+v 1.092608 0.549110 -0.548445
+v 1.100908 0.572696 -0.557413
+v 1.110050 0.592887 -0.565789
+v 1.119682 0.608906 -0.573250
+v 1.129435 0.620137 -0.579509
+v 1.138933 0.626150 -0.584325
+v 1.147812 0.626713 -0.587515
+v 1.155730 0.621804 -0.588954
+v 1.162383 0.611612 -0.588589
+v 1.167515 0.596529 -0.586432
+v 1.170930 0.577134 -0.582566
+v 1.172495 0.554173 -0.577142
+v 1.172152 0.528528 -0.570365
+v 1.169912 0.501184 -0.562498
+v 1.085147 0.521357 -0.534380
+v 1.091977 0.545820 -0.538937
+v 1.099992 0.567919 -0.543610
+v 1.108884 0.586807 -0.548221
+v 1.118311 0.601756 -0.552592
+v 1.127911 0.612193 -0.556555
+v 1.137316 0.617716 -0.559958
+v 1.146163 0.618114 -0.562670
+v 1.154112 0.613370 -0.564587
+v 1.160859 0.603668 -0.565635
+v 1.166144 0.589379 -0.565774
+v 1.169764 0.571054 -0.564999
+v 1.171579 0.549396 -0.563339
+v 1.171521 0.525237 -0.560858
+v 1.169590 0.499507 -0.557651
+v 1.084651 0.518676 -0.529378
+v 1.091003 0.540561 -0.529125
+v 1.098577 0.560286 -0.529366
+v 1.107083 0.577091 -0.530091
+v 1.116194 0.590332 -0.531273
+v 1.125559 0.599499 -0.532867
+v 1.134818 0.604241 -0.534811
+v 1.143616 0.604374 -0.537030
+v 1.151615 0.599894 -0.539440
+v 1.158507 0.590974 -0.541947
+v 1.164027 0.577955 -0.544455
+v 1.167963 0.561338 -0.546869
+v 1.170165 0.541762 -0.549094
+v 1.170546 0.519979 -0.551046
+v 1.169093 0.496826 -0.552649
+v 1.083998 0.515096 -0.524413
+v 1.089722 0.533538 -0.519386
+v 1.096718 0.550089 -0.515227
+v 1.104717 0.564114 -0.512096
+v 1.113412 0.575072 -0.510113
+v 1.122468 0.582543 -0.509355
+v 1.131536 0.586240 -0.509850
+v 1.140270 0.586021 -0.511581
+v 1.148333 0.581894 -0.514479
+v 1.155415 0.574018 -0.518435
+v 1.161245 0.562695 -0.523295
+v 1.165597 0.548361 -0.528873
+v 1.168306 0.531566 -0.534955
+v 1.169266 0.512956 -0.541307
+v 1.168441 0.493246 -0.547684
+v 1.165862 0.473193 -0.553843
+v 1.083214 0.510753 -0.519676
+v 1.088185 0.525019 -0.510094
+v 1.094487 0.537722 -0.501737
+v 1.101877 0.548373 -0.494926
+v 1.110072 0.556563 -0.489924
+v 1.118756 0.561977 -0.486922
+v 1.127597 0.564407 -0.486036
+v 1.136253 0.563760 -0.487299
+v 1.144394 0.560061 -0.490664
+v 1.151704 0.553451 -0.496002
+v 1.157905 0.544186 -0.503106
+v 1.162757 0.532620 -0.511703
+v 1.166074 0.519198 -0.521465
+v 1.167729 0.504437 -0.532015
+v 1.167657 0.488903 -0.542947
+v 1.082330 0.505815 -0.515349
+v 1.086450 0.515332 -0.501606
+v 1.091968 0.523659 -0.489414
+v 1.098672 0.530474 -0.479242
+v 1.106303 0.535516 -0.471482
+v 1.114568 0.538591 -0.466430
+v 1.123151 0.539580 -0.464282
+v 1.131720 0.538447 -0.465119
+v 1.139948 0.535234 -0.468911
+v 1.147516 0.530065 -0.475510
+v 1.154136 0.523139 -0.484663
+v 1.159552 0.514721 -0.496020
+v 1.163556 0.505135 -0.509142
+v 1.165994 0.494750 -0.523527
+v 1.166773 0.483965 -0.538620
+v 1.081379 0.500471 -0.511598
+v 1.084584 0.504850 -0.494248
+v 1.089260 0.508440 -0.478732
+v 1.095224 0.511104 -0.465647
+v 1.102249 0.512739 -0.455495
+v 1.110064 0.513283 -0.448667
+v 1.118369 0.512714 -0.445425
+v 1.126845 0.511054 -0.445893
+v 1.135166 0.508368 -0.450054
+v 1.143012 0.504758 -0.457747
+v 1.150082 0.500362 -0.468677
+v 1.156104 0.495351 -0.482425
+v 1.160847 0.489917 -0.498461
+v 1.164128 0.484267 -0.516169
+v 1.165822 0.478621 -0.534869
+v 1.080397 0.494926 -0.508568
+v 1.082659 0.493974 -0.488304
+v 1.086465 0.492651 -0.470102
+v 1.091667 0.491008 -0.454663
+v 1.098066 0.489109 -0.442579
+v 1.105416 0.487027 -0.434316
+v 1.113435 0.484840 -0.430189
+v 1.121814 0.482635 -0.430359
+v 1.130232 0.480494 -0.434818
+v 1.138364 0.478501 -0.443396
+v 1.145899 0.476732 -0.455761
+v 1.152547 0.475255 -0.471441
+v 1.158052 0.474127 -0.489830
+v 1.162203 0.473392 -0.510224
+v 1.164840 0.473076 -0.531839
+v 1.079423 0.489395 -0.506374
+v 1.080749 0.483123 -0.484001
+v 1.083691 0.476898 -0.463855
+v 1.088137 0.470959 -0.446712
+v 1.093915 0.465534 -0.433230
+v 1.100804 0.460831 -0.423927
+v 1.108539 0.457031 -0.419161
+v 1.116822 0.454280 -0.419115
+v 1.125336 0.452685 -0.423790
+v 1.133752 0.452305 -0.433007
+v 1.141749 0.453157 -0.446412
+v 1.149017 0.455206 -0.463490
+v 1.155279 0.458375 -0.483583
+v 1.160293 0.462541 -0.505921
+v 1.163866 0.467545 -0.529645
+v 1.078494 0.484088 -0.505102
+v 1.078927 0.472714 -0.481504
+v 1.081046 0.461787 -0.460231
+v 1.084770 0.451726 -0.442100
+v 1.089956 0.442918 -0.427807
+v 1.096405 0.435702 -0.417901
+v 1.103869 0.430354 -0.412764
+v 1.112061 0.427081 -0.412592
+v 1.120666 0.426008 -0.417392
+v 1.129353 0.427176 -0.426981
+v 1.137789 0.430541 -0.440989
+v 1.145650 0.435973 -0.458877
+v 1.152633 0.443263 -0.479960
+v 1.158470 0.452132 -0.503425
+v 1.162937 0.462238 -0.528373
+v 1.077646 0.479211 -0.504799
+v 1.077263 0.463147 -0.480911
+v 1.078630 0.447898 -0.459370
+v 1.081695 0.434049 -0.441004
+v 1.086341 0.422132 -0.426517
+v 1.092388 0.412605 -0.416469
+v 1.099604 0.405835 -0.411243
+v 1.107712 0.402081 -0.411041
+v 1.116400 0.401489 -0.415872
+v 1.125335 0.404080 -0.425548
+v 1.134174 0.409755 -0.439699
+v 1.142575 0.418296 -0.457781
+v 1.150217 0.429374 -0.479098
+v 1.156806 0.442565 -0.502832
+v 1.162089 0.457361 -0.528070
+v 1.076911 0.474951 -0.505478
+v 1.075821 0.454790 -0.482243
+v 1.076536 0.435765 -0.461304
+v 1.079031 0.418607 -0.443465
+v 1.083207 0.403974 -0.429412
+v 1.088906 0.392429 -0.419685
+v 1.095908 0.384416 -0.414658
+v 1.103944 0.380243 -0.414523
+v 1.112705 0.380070 -0.419286
+v 1.121854 0.383904 -0.428765
+v 1.131040 0.391597 -0.442594
+v 1.139911 0.402854 -0.460243
+v 1.148124 0.417242 -0.481032
+v 1.155364 0.434208 -0.504164
+v 1.161354 0.453101 -0.528749
+v 1.079765 0.495471 -0.530116
+v 1.076317 0.471470 -0.507113
+v 1.074656 0.447964 -0.485450
+v 1.074846 0.425855 -0.465960
+v 1.076879 0.405993 -0.449390
+v 1.080677 0.389142 -0.436379
+v 1.086095 0.375948 -0.427427
+v 1.092923 0.366920 -0.422876
+v 1.100901 0.362405 -0.422902
+v 1.109720 0.362574 -0.427505
+v 1.119043 0.367423 -0.436507
+v 1.128510 0.376765 -0.449561
+v 1.137759 0.390240 -0.466168
+v 1.146433 0.407331 -0.485688
+v 1.154200 0.427381 -0.507371
+v 1.160760 0.449620 -0.530384
+v 1.075888 0.468904 -0.509640
+v 1.073814 0.442930 -0.490408
+v 1.073623 0.418547 -0.473157
+v 1.075323 0.396692 -0.458551
+v 1.078847 0.378205 -0.447152
+v 1.084061 0.363797 -0.439396
+v 1.090765 0.354020 -0.435583
+v 1.098700 0.349252 -0.435858
+v 1.107561 0.349674 -0.440212
+v 1.117009 0.355271 -0.448476
+v 1.126680 0.365828 -0.460334
+v 1.136203 0.380939 -0.475329
+v 1.145210 0.400024 -0.492886
+v 1.153357 0.422348 -0.512329
+v 1.160331 0.447054 -0.532911
+vn -0.681265 -0.692312 0.237709
+vn -0.904202 -0.398114 0.154515
+vn -0.899167 -0.437422 -0.010163
+vn -0.997864 0.060305 0.024537
+vn -0.993133 0.116459 0.008606
+vn -0.994049 0.108585 -0.008240
+vn 0.937773 -0.342936 0.054415
+vn 0.903439 -0.421674 0.077029
+vn 0.928129 -0.372173 0.000702
+vn -0.163366 -0.944243 0.285836
+vn -0.237678 -0.971313 0.003082
+vn -0.999023 -0.005646 0.043184
+vn -0.998962 0.044557 -0.009156
+vn 0.959319 -0.279885 0.036439
+vn 0.954558 -0.297952 0.002503
+vn 0.400891 -0.887326 0.227851
+vn 0.306772 -0.951720 -0.008209
+vn -0.993652 -0.090213 0.066988
+vn -0.999512 -0.029389 -0.010102
+vn 0.974090 -0.225135 0.020844
+vn 0.972289 -0.233711 0.003906
+vn 0.710898 -0.685812 0.155644
+vn 0.649068 -0.760643 -0.009552
+vn -0.972472 -0.209967 0.100833
+vn -0.992462 -0.122013 -0.011048
+vn 0.841639 -0.529069 0.108188
+vn 0.808283 -0.588733 -0.005341
+vn -0.968505 -0.248695 -0.011597
+vn 0.885464 -0.464644 -0.001770
+vn -0.697470 -0.716575 -0.002472
+vn -0.882015 -0.447066 -0.148717
+vn -0.994324 0.103427 -0.024293
+vn 0.918058 -0.392804 -0.053377
+vn -0.286966 -0.931303 -0.224189
+vn -0.998535 0.034150 -0.041353
+vn 0.949950 -0.310739 -0.031312
+vn 0.221259 -0.951018 -0.215766
+vn -0.997162 -0.044527 -0.060366
+vn 0.970763 -0.239570 -0.012604
+vn 0.583178 -0.794702 -0.168218
+vn -0.986541 -0.140751 -0.083010
+vn 0.770867 -0.625782 -0.118748
+vn -0.956969 -0.267769 -0.111606
+vn 0.865627 -0.494003 -0.081301
+vn 0.734123 -0.640522 -0.225196
+vn -0.942198 -0.270577 -0.197516
+vn 0.846126 -0.509140 -0.157476
+vn -0.691702 -0.696066 -0.192328
+vn -0.860988 -0.436171 -0.261513
+vn -0.994110 0.100864 -0.039064
+vn 0.908505 -0.404279 -0.105411
+vn -0.316630 -0.862697 -0.394269
+vn -0.997040 0.028993 -0.071017
+vn 0.945952 -0.317942 -0.063692
+vn 0.152104 -0.910764 -0.383831
+vn -0.993011 -0.051424 -0.106113
+vn 0.969665 -0.242744 -0.028199
+vn 0.522294 -0.794671 -0.309305
+vn -0.978027 -0.147618 -0.147038
+vn 0.969024 -0.243233 -0.042268
+vn 0.472671 -0.769616 -0.429243
+vn -0.968688 -0.143742 -0.202338
+vn 0.702658 -0.635334 -0.320322
+vn -0.927183 -0.259926 -0.269662
+vn 0.829463 -0.510239 -0.227088
+vn -0.677541 -0.653829 -0.336711
+vn -0.840815 -0.410779 -0.352489
+vn -0.993530 0.100803 -0.052217
+vn 0.900723 -0.406415 -0.153264
+vn -0.333079 -0.785394 -0.521683
+vn -0.994812 0.028932 -0.097415
+vn 0.942961 -0.319437 -0.093387
+vn 0.101444 -0.850185 -0.516587
+vn -0.987945 -0.050478 -0.146306
+vn -0.992187 0.033753 -0.119938
+vn 0.941465 -0.315226 -0.119297
+vn 0.068545 -0.779717 -0.622333
+vn -0.982665 -0.042177 -0.180364
+vn 0.968963 -0.241066 -0.054415
+vn 0.437788 -0.726981 -0.528947
+vn -0.959807 -0.130222 -0.248573
+vn 0.680013 -0.613208 -0.401868
+vn -0.913846 -0.237892 -0.329020
+vn 0.817866 -0.498276 -0.287698
+vn -0.662252 -0.601062 -0.447310
+vn -0.823817 -0.374310 -0.425642
+vn -0.992615 0.103183 -0.063448
+vn 0.895749 -0.399396 -0.195105
+vn -0.340922 -0.706229 -0.620441
+vn -0.648854 -0.541978 -0.534043
+vn -0.810968 -0.328440 -0.484146
+vn -0.991516 0.107791 -0.072451
+vn 0.894436 -0.383801 -0.229408
+vn -0.342784 -0.625996 -0.700430
+vn -0.989471 0.043184 -0.138096
+vn 0.941710 -0.305643 -0.140446
+vn 0.051912 -0.703543 -0.708731
+vn -0.977783 -0.027100 -0.207801
+vn 0.969512 -0.236396 -0.064272
+vn 0.419446 -0.671529 -0.610767
+vn -0.952208 -0.108005 -0.285684
+vn 0.668722 -0.576891 -0.468978
+vn -0.903226 -0.205908 -0.376507
+vn 0.812922 -0.474502 -0.337535
+vn 0.670217 -0.528398 -0.521104
+vn -0.802545 -0.273659 -0.530045
+vn 0.815699 -0.440138 -0.375317
+vn -0.638386 -0.477462 -0.603687
+vn -0.631031 -0.406751 -0.660512
+vn -0.990265 0.114475 -0.079134
+vn 0.897214 -0.360424 -0.255074
+vn -0.339854 -0.542741 -0.768029
+vn -0.986785 0.056887 -0.151585
+vn 0.943846 -0.291116 -0.156133
+vn 0.050569 -0.622059 -0.781304
+vn -0.973571 -0.005737 -0.228248
+vn 0.970641 -0.229530 -0.071535
+vn 0.418561 -0.605487 -0.676870
+vn -0.946348 -0.077731 -0.313608
+vn 0.947844 -0.272134 -0.165868
+vn 0.064547 -0.533372 -0.843379
+vn -0.895779 -0.164769 -0.412793
+vn -0.891568 -0.114872 -0.438032
+vn 0.435743 -0.529191 -0.728050
+vn -0.798425 -0.209632 -0.564379
+vn 0.685110 -0.468764 -0.557512
+vn -0.626576 -0.327891 -0.706992
+vn -0.984283 0.074465 -0.160100
+vn 0.826380 -0.396283 -0.399976
+vn -0.332224 -0.453230 -0.827143
+vn -0.970183 0.021363 -0.241371
+vn 0.904172 -0.329997 -0.271218
+vn -0.942381 -0.040010 -0.332102
+vn 0.914914 -0.293435 -0.277139
+vn -0.319071 -0.352641 -0.879665
+vn -0.940092 0.004639 -0.340831
+vn 0.972381 -0.220557 -0.076113
+vn 0.953520 -0.249214 -0.169256
+vn 0.095004 -0.433637 -0.896054
+vn -0.890225 -0.056246 -0.451949
+vn 0.471389 -0.441481 -0.763451
+vn -0.798059 -0.135380 -0.587115
+vn 0.712973 -0.398541 -0.576861
+vn -0.624378 -0.237892 -0.743980
+vn -0.988861 0.123081 -0.083377
+vn -0.981903 0.095523 -0.163366
+vn 0.844539 -0.343883 -0.410413
+vn -0.967559 0.053652 -0.246834
+vn -0.987396 0.133366 -0.085025
+vn -0.979644 0.119510 -0.161260
+vn 0.868831 -0.284005 -0.405469
+vn -0.298257 -0.234230 -0.925291
+vn -0.965423 0.090487 -0.244331
+vn 0.928678 -0.251717 -0.272256
+vn -0.939055 0.055696 -0.339213
+vn 0.974639 -0.209693 -0.077792
+vn 0.960540 -0.223090 -0.166021
+vn 0.144200 -0.317118 -0.937346
+vn -0.891079 0.011109 -0.453688
+vn 0.525285 -0.340129 -0.779962
+vn -0.800623 -0.049318 -0.597125
+vn 0.752373 -0.317942 -0.576891
+vn -0.623463 -0.132572 -0.770501
+vn -0.804498 0.050356 -0.591754
+vn 0.800348 -0.227638 -0.554613
+vn -0.621754 -0.006378 -0.783166
+vn -0.985809 0.145207 -0.083987
+vn -0.977294 0.145787 -0.153600
+vn 0.897092 -0.218238 -0.384136
+vn -0.265938 -0.088595 -0.959899
+vn -0.963439 0.131077 -0.233558
+vn 0.944273 -0.206336 -0.256355
+vn -0.938444 0.112522 -0.326518
+vn 0.977355 -0.197211 -0.076449
+vn 0.968352 -0.194678 -0.156072
+vn 0.214881 -0.176305 -0.960570
+vn -0.892880 0.087313 -0.441694
+vn 0.595965 -0.222633 -0.771508
+vn 0.308267 -0.003754 -0.951262
+vn -0.893918 0.171911 -0.413892
+vn 0.678854 -0.088473 -0.728874
+vn -0.807123 0.165288 -0.566729
+vn 0.852046 -0.129795 -0.507065
+vn -0.615253 0.147099 -0.774438
+vn -0.984130 0.158269 -0.080172
+vn -0.974731 0.173650 -0.140385
+vn 0.926298 -0.148839 -0.346110
+vn -0.216071 0.095767 -0.971648
+vn -0.961058 0.174444 -0.214240
+vn 0.960173 -0.158940 -0.229743
+vn -0.937284 0.174139 -0.301889
+vn 0.980346 -0.183538 -0.071993
+vn 0.976318 -0.165014 -0.139683
+vn 0.974761 -0.111576 -0.193213
+vn -0.141850 0.325968 -0.934660
+vn -0.934263 0.239021 -0.264534
+vn 0.983459 -0.169134 -0.064486
+vn 0.983795 -0.135289 -0.117374
+vn 0.419752 0.200537 -0.885189
+vn -0.891812 0.263436 -0.367748
+vn 0.764458 0.057344 -0.642079
+vn -0.804285 0.295297 -0.515641
+vn 0.900937 -0.029054 -0.432966
+vn -0.596942 0.332255 -0.730216
+vn -0.982299 0.172155 -0.073550
+vn -0.971709 0.202277 -0.121677
+vn 0.953093 -0.079043 -0.292154
+vn -0.957671 0.219337 -0.186254
+vn -0.980346 0.186499 -0.064180
+vn -0.968108 0.230628 -0.097659
+vn 0.974364 -0.012909 -0.224555
+vn -0.557085 0.541917 -0.629231
+vn -0.952788 0.264077 -0.149632
+vn 0.986694 -0.066561 -0.148259
+vn -0.043062 0.584490 -0.810236
+vn -0.928129 0.304666 -0.213874
+vn 0.986511 -0.154393 -0.054079
+vn 0.990204 -0.106845 -0.089846
+vn 0.534135 0.415540 -0.736198
+vn -0.883724 0.358348 -0.300974
+vn 0.838252 0.200598 -0.506974
+vn -0.790246 0.435530 -0.431013
+vn 0.939940 0.066958 -0.334666
+vn -0.867275 0.449873 -0.213080
+vn 0.964049 0.148991 -0.219916
+vn -0.759606 0.572436 -0.308664
+vn -0.978240 0.200751 -0.052004
+vn -0.963927 0.257057 -0.068789
+vn 0.988037 0.044771 -0.147496
+vn -0.489608 0.743217 -0.455947
+vn -0.946135 0.306223 -0.105045
+vn 0.994903 -0.026673 -0.097140
+vn 0.065615 0.812037 -0.579852
+vn -0.917905 0.367138 -0.150456
+vn 0.989288 -0.140049 -0.040925
+vn 0.994964 -0.081301 -0.058260
+vn 0.627491 0.593371 -0.504105
+vn 0.886288 0.319407 -0.335276
+vn 0.681265 0.692312 -0.237678
+vn -0.903439 0.421705 -0.077029
+vn 0.972472 0.209998 -0.100833
+vn -0.841639 0.529069 -0.108188
+vn 0.993652 0.090213 -0.066988
+vn -0.710898 0.685812 -0.155644
+vn -0.976104 0.213996 -0.037294
+vn -0.974090 0.225166 -0.020844
+vn 0.999023 0.005646 -0.043153
+vn -0.400891 0.887326 -0.227821
+vn -0.959319 0.279885 -0.036439
+vn 0.997864 -0.060305 -0.024537
+vn 0.163366 0.944243 -0.285806
+vn -0.937773 0.342936 -0.054415
+vn 0.991546 -0.127049 -0.025422
+vn 0.993133 -0.116428 -0.008606
+vn 0.998962 -0.044557 0.009156
+vn 0.237678 0.971313 -0.003082
+vn -0.928129 0.372173 -0.000702
+vn 0.994049 -0.108585 0.008240
+vn 0.904202 0.398114 -0.154515
+vn 0.899167 0.437422 0.010163
+vn -0.885464 0.464644 0.001770
+vn 0.968505 0.248695 0.011597
+vn -0.808283 0.588733 0.005341
+vn 0.992462 0.122013 0.011048
+vn -0.649068 0.760643 0.009552
+vn -0.972289 0.233711 -0.003906
+vn 0.999512 0.029389 0.010102
+vn -0.306772 0.951720 0.008209
+vn -0.954558 0.297952 -0.002503
+vn 0.997162 0.044527 0.060366
+vn -0.221259 0.951018 0.215766
+vn -0.949950 0.310739 0.031312
+vn 0.998535 -0.034150 0.041353
+vn 0.697470 0.716575 0.002472
+vn 0.286966 0.931303 0.224189
+vn -0.918058 0.392804 0.053377
+vn 0.994324 -0.103427 0.024293
+vn 0.882015 0.447066 0.148717
+vn -0.865627 0.494003 0.081301
+vn 0.956969 0.267769 0.111606
+vn -0.770867 0.625782 0.118748
+vn 0.986541 0.140751 0.083010
+vn -0.583209 0.794702 0.168218
+vn -0.970763 0.239570 0.012604
+vn 0.978027 0.147618 0.147038
+vn -0.522294 0.794671 0.309305
+vn -0.969665 0.242744 0.028199
+vn 0.993011 0.051424 0.106113
+vn -0.152104 0.910764 0.383831
+vn -0.945952 0.317942 0.063692
+vn 0.997040 -0.028993 0.071017
+vn 0.691702 0.696066 0.192328
+vn 0.316630 0.862697 0.394269
+vn -0.908505 0.404279 0.105411
+vn 0.994110 -0.100864 0.039064
+vn 0.860988 0.436171 0.261513
+vn -0.846126 0.509140 0.157476
+vn 0.942198 0.270577 0.197516
+vn -0.734123 0.640522 0.225196
+vn -0.829463 0.510239 0.227088
+vn 0.927183 0.259926 0.269662
+vn -0.702658 0.635334 0.320322
+vn 0.968688 0.143742 0.202338
+vn -0.472671 0.769616 0.429243
+vn -0.969024 0.243233 0.042268
+vn 0.987945 0.050478 0.146336
+vn -0.101444 0.850185 0.516587
+vn -0.942961 0.319437 0.093387
+vn 0.994812 -0.028901 0.097415
+vn 0.677572 0.653829 0.336711
+vn 0.333079 0.785394 0.521683
+vn -0.900723 0.406384 0.153264
+vn 0.993530 -0.100803 0.052217
+vn 0.840815 0.410779 0.352489
+vn 0.662252 0.601062 0.447310
+vn 0.340922 0.706229 0.620441
+vn -0.895749 0.399396 0.195105
+vn 0.992615 -0.103183 0.063417
+vn 0.823817 0.374310 0.425642
+vn -0.817835 0.498306 0.287698
+vn 0.913846 0.237892 0.329020
+vn -0.680013 0.613208 0.401868
+vn 0.959807 0.130222 0.248573
+vn -0.437788 0.726981 0.528947
+vn -0.968963 0.241066 0.054415
+vn 0.982665 0.042177 0.180364
+vn -0.068545 0.779717 0.622333
+vn -0.941465 0.315226 0.119297
+vn 0.992187 -0.033753 0.119938
+vn 0.977783 0.027100 0.207801
+vn -0.051912 0.703543 0.708731
+vn -0.941710 0.305643 0.140446
+vn 0.989471 -0.043214 0.138096
+vn 0.648854 0.541978 0.534043
+vn 0.342784 0.625996 0.700430
+vn -0.894436 0.383801 0.229408
+vn 0.991516 -0.107791 0.072451
+vn 0.810968 0.328440 0.484146
+vn -0.812922 0.474502 0.337535
+vn 0.903226 0.205908 0.376507
+vn -0.668722 0.576891 0.468978
+vn 0.952208 0.108005 0.285684
+vn -0.419446 0.671529 0.610767
+vn -0.969512 0.236427 0.064272
+vn 0.946348 0.077731 0.313608
+vn -0.418561 0.605487 0.676870
+vn -0.970641 0.229530 0.071535
+vn 0.973571 0.005707 0.228248
+vn -0.050569 0.622059 0.781304
+vn -0.943846 0.291116 0.156133
+vn 0.986785 -0.056887 0.151585
+vn 0.638386 0.477493 0.603687
+vn 0.339854 0.542741 0.768029
+vn -0.897214 0.360424 0.255074
+vn 0.990265 -0.114444 0.079134
+vn 0.631062 0.406751 0.660512
+vn -0.815699 0.440138 0.375317
+vn 0.802545 0.273659 0.530045
+vn -0.670217 0.528398 0.521104
+vn -0.685110 0.468764 0.557512
+vn 0.895779 0.164800 0.412793
+vn 0.798425 0.209632 0.564379
+vn -0.435743 0.529191 0.728050
+vn 0.891568 0.114872 0.438032
+vn -0.064547 0.533372 0.843410
+vn -0.947844 0.272134 0.165868
+vn 0.942381 0.040010 0.332102
+vn -0.904172 0.329997 0.271218
+vn 0.970183 -0.021363 0.241371
+vn 0.332224 0.453230 0.827143
+vn -0.826380 0.396283 0.399976
+vn 0.984283 -0.074465 0.160100
+vn 0.626545 0.327891 0.706992
+vn 0.319071 0.352641 0.879665
+vn -0.844539 0.343883 0.410413
+vn 0.988861 -0.123051 0.083377
+vn 0.981903 -0.095523 0.163366
+vn 0.624378 0.237892 0.743980
+vn -0.712973 0.398541 0.576861
+vn 0.798059 0.135380 0.587115
+vn -0.471389 0.441481 0.763451
+vn 0.890225 0.056246 0.451979
+vn -0.095004 0.433637 0.896054
+vn -0.972381 0.220557 0.076113
+vn -0.953520 0.249214 0.169256
+vn 0.940092 -0.004639 0.340831
+vn -0.914914 0.293405 0.277139
+vn 0.967559 -0.053652 0.246834
+vn 0.939055 -0.055696 0.339213
+vn 0.298257 0.234230 0.925291
+vn -0.928678 0.251717 0.272256
+vn 0.965423 -0.090487 0.244362
+vn -0.868831 0.284005 0.405469
+vn 0.987396 -0.133396 0.085055
+vn 0.979644 -0.119510 0.161260
+vn 0.623463 0.132572 0.770501
+vn -0.752373 0.317942 0.576891
+vn 0.800623 0.049318 0.597125
+vn -0.525285 0.340098 0.779962
+vn 0.891079 -0.011109 0.453688
+vn -0.144200 0.317118 0.937346
+vn -0.974639 0.209693 0.077792
+vn -0.960540 0.223060 0.166021
+vn 0.892880 -0.087313 0.441694
+vn -0.214881 0.176305 0.960570
+vn -0.977355 0.197211 0.076449
+vn -0.968352 0.194678 0.156072
+vn 0.938444 -0.112522 0.326518
+vn 0.265938 0.088595 0.959899
+vn -0.944273 0.206336 0.256355
+vn 0.963439 -0.131077 0.233558
+vn -0.897092 0.218238 0.384136
+vn 0.985809 -0.145207 0.083987
+vn 0.977294 -0.145787 0.153600
+vn 0.621754 0.006378 0.783166
+vn -0.800348 0.227638 0.554613
+vn 0.804498 -0.050356 0.591754
+vn -0.595965 0.222633 0.771508
+vn 0.807123 -0.165288 0.566729
+vn -0.678854 0.088473 0.728874
+vn 0.893918 -0.171911 0.413892
+vn -0.308267 0.003754 0.951262
+vn -0.980346 0.183538 0.071993
+vn -0.976318 0.165014 0.139683
+vn 0.937284 -0.174169 0.301889
+vn 0.216071 -0.095767 0.971648
+vn -0.960173 0.158940 0.229743
+vn 0.961058 -0.174444 0.214240
+vn -0.926298 0.148839 0.346110
+vn 0.984130 -0.158269 0.080172
+vn 0.974731 -0.173650 0.140385
+vn 0.615253 -0.147099 0.774438
+vn -0.852046 0.129795 0.507065
+vn -0.953063 0.079043 0.292154
+vn 0.982299 -0.172155 0.073550
+vn 0.971709 -0.202277 0.121677
+vn 0.596942 -0.332255 0.730216
+vn -0.900937 0.029054 0.432966
+vn 0.804285 -0.295297 0.515641
+vn -0.764458 -0.057344 0.642079
+vn 0.891812 -0.263436 0.367748
+vn -0.419752 -0.200537 0.885189
+vn -0.983459 0.169103 0.064486
+vn -0.983795 0.135289 0.117374
+vn 0.934263 -0.239021 0.264534
+vn 0.141850 -0.325968 0.934660
+vn -0.974761 0.111576 0.193213
+vn 0.957671 -0.219337 0.186254
+vn 0.043062 -0.584490 0.810236
+vn -0.986694 0.066561 0.148259
+vn 0.952788 -0.264077 0.149632
+vn 0.557085 -0.541887 0.629231
+vn -0.974364 0.012909 0.224555
+vn 0.980346 -0.186499 0.064180
+vn 0.968108 -0.230628 0.097659
+vn -0.939940 -0.066958 0.334666
+vn 0.790246 -0.435530 0.431013
+vn -0.838282 -0.200598 0.506974
+vn 0.883724 -0.358348 0.300974
+vn -0.534104 -0.415571 0.736198
+vn -0.986511 0.154393 0.054079
+vn -0.990204 0.106815 0.089846
+vn 0.928129 -0.304666 0.213874
+vn 0.867275 -0.449873 0.213080
+vn -0.627491 -0.593371 0.504135
+vn -0.989288 0.140049 0.040925
+vn -0.994964 0.081301 0.058260
+vn 0.917905 -0.367138 0.150456
+vn -0.065615 -0.812037 0.579882
+vn -0.994903 0.026673 0.097140
+vn 0.946135 -0.306223 0.105045
+vn 0.489608 -0.743217 0.455947
+vn -0.988037 -0.044771 0.147496
+vn 0.978240 -0.200751 0.052004
+vn 0.963927 -0.257057 0.068789
+vn 0.759606 -0.572436 0.308664
+vn -0.964049 -0.148991 0.219916
+vn -0.886288 -0.319407 0.335276
+vn 0.985198 -0.171270 0.005707
+vn -0.985198 0.171270 -0.005707
+vn 0.976104 -0.213996 0.037294
+vn -0.991546 0.127079 0.025422
+vn -0.993133 0.116428 0.008606
+vn 0.928159 -0.372173 0.000702
+vn 0.974090 -0.225166 0.020814
+vn 0.841609 -0.529069 0.108188
+vn 0.583209 -0.794702 -0.168218
+vn 0.865627 -0.494034 -0.081301
+vn 0.846126 -0.509110 -0.157476
+vn -0.994110 0.100864 -0.039094
+vn 0.152074 -0.910764 -0.383831
+vn 0.969665 -0.242744 -0.028169
+vn 0.472640 -0.769616 -0.429243
+vn 0.702658 -0.635304 -0.320322
+vn -0.927183 -0.259896 -0.269662
+vn -0.987945 -0.050478 -0.146336
+vn -0.982665 -0.042207 -0.180364
+vn -0.959807 -0.130253 -0.248573
+vn -0.992615 0.103183 -0.063417
+vn -0.340922 -0.706259 -0.620441
+vn -0.342784 -0.625965 -0.700430
+vn 0.969512 -0.236427 -0.064272
+vn -0.952208 -0.107974 -0.285684
+vn -0.638386 -0.477462 -0.603656
+vn -0.339824 -0.542741 -0.768029
+vn 0.970641 -0.229499 -0.071535
+vn 0.064547 -0.533372 -0.843410
+vn -0.798425 -0.209662 -0.564379
+vn -0.626545 -0.327891 -0.707022
+vn -0.984283 0.074465 -0.160070
+vn 0.914914 -0.293405 -0.277139
+vn -0.940092 0.004608 -0.340831
+vn -0.890225 -0.056246 -0.451979
+vn -0.967559 0.053682 -0.246834
+vn -0.987396 0.133396 -0.085025
+vn -0.979644 0.119480 -0.161260
+vn -0.965423 0.090487 -0.244362
+vn 0.144200 -0.317148 -0.937346
+vn 0.525285 -0.340098 -0.779962
+vn -0.800623 -0.049348 -0.597125
+vn -0.621723 -0.006378 -0.783166
+vn -0.985809 0.145268 -0.083987
+vn -0.938444 0.112552 -0.326487
+vn 0.595935 -0.222633 -0.771508
+vn 0.852046 -0.129765 -0.507065
+vn 0.926267 -0.148869 -0.346110
+vn -0.961058 0.174413 -0.214240
+vn -0.937284 0.174169 -0.301889
+vn 0.983459 -0.169073 -0.064516
+vn -0.982299 0.172124 -0.073550
+vn -0.971709 0.202307 -0.121677
+vn 0.953063 -0.079043 -0.292154
+vn -0.957701 0.219337 -0.186254
+vn -0.557085 0.541887 -0.629231
+vn 0.990173 -0.106845 -0.089846
+vn 0.534104 0.415571 -0.736198
+vn 0.838282 0.200568 -0.506974
+vn 0.988037 0.044771 -0.147465
+vn -0.489578 0.743217 -0.455947
+vn 0.989288 -0.140080 -0.040925
+vn 0.627461 0.593371 -0.504135
+vn 0.972472 0.209967 -0.100833
+vn -0.976104 0.213996 -0.037263
+vn 0.999023 0.005646 -0.043184
+vn -0.959319 0.279885 -0.036409
+vn 0.998962 -0.044588 0.009156
+vn 0.237678 0.971313 -0.003113
+vn -0.928159 0.372173 -0.000702
+vn -0.808283 0.588733 0.005310
+vn -0.972259 0.233741 -0.003906
+vn 0.993011 0.051424 0.106082
+vn -0.152104 0.910764 0.383862
+vn 0.316630 0.862697 0.394299
+vn 0.860988 0.436201 0.261513
+vn -0.846126 0.509110 0.157476
+vn -0.829463 0.510239 0.227119
+vn 0.927183 0.259896 0.269662
+vn -0.702658 0.635304 0.320322
+vn -0.472640 0.769616 0.429243
+vn 0.987945 0.050478 0.146306
+vn 0.994812 -0.028932 0.097415
+vn 0.677541 0.653829 0.336711
+vn -0.900723 0.406415 0.153264
+vn 0.340922 0.706259 0.620441
+vn -0.817866 0.498276 0.287698
+vn 0.982665 0.042177 0.180395
+vn 0.989471 -0.043184 0.138096
+vn 0.342784 0.625965 0.700430
+vn 0.952208 0.107974 0.285684
+vn -0.970641 0.229499 0.071535
+vn 0.973571 0.005737 0.228248
+vn 0.638386 0.477462 0.603656
+vn 0.339824 0.542741 0.768029
+vn -0.897214 0.360424 0.255043
+vn 0.990265 -0.114475 0.079134
+vn 0.631031 0.406751 0.660512
+vn -0.670217 0.528367 0.521104
+vn 0.895779 0.164769 0.412793
+vn 0.798425 0.209662 0.564379
+vn -0.904141 0.330027 0.271218
+vn 0.984283 -0.074496 0.160100
+vn 0.626545 0.327891 0.707022
+vn 0.890225 0.056246 0.451949
+vn 0.940092 -0.004608 0.340831
+vn 0.967559 -0.053682 0.246834
+vn 0.987396 -0.133366 0.085055
+vn 0.979644 -0.119480 0.161260
+vn -0.960540 0.223090 0.166021
+vn -0.977355 0.197180 0.076449
+vn -0.944273 0.206336 0.256386
+vn 0.985809 -0.145238 0.083987
+vn -0.976318 0.165044 0.139683
+vn -0.926298 0.148869 0.346110
+vn 0.974731 -0.173681 0.140385
+vn 0.615253 -0.147099 0.774468
+vn -0.852046 0.129765 0.507065
+vn 0.971709 -0.202307 0.121677
+vn -0.974761 0.111545 0.193213
+vn 0.957701 -0.219306 0.186254
+vn 0.043092 -0.584490 0.810236
+vn -0.990204 0.106845 0.089846
+vn 0.928098 -0.304666 0.213874
+vn -0.065615 -0.812037 0.579852
+vn 0.978240 -0.200751 0.052034
+usemtl SkinColor
+s 1
+f 1453//1107 1452//1108 1467//1109
+f 1448//1110 1447//1111 1462//1112
+f 1459//1113 1458//1114 1474//1115
+f 1454//1116 1453//1107 1469//1117
+f 1449//1118 1448//1110 1463//1119
+f 1460//1120 1459//1113 1475//1121
+f 1455//1122 1454//1116 1470//1123
+f 1450//1124 1449//1118 1464//1125
+f 1461//1126 1460//1120 1476//1127
+f 1456//1128 1455//1122 1471//1129
+f 1451//1130 1450//1124 1465//1131
+f 1457//1132 1456//1128 1472//1133
+f 1452//1108 1451//1130 1466//1134
+f 1458//1114 1457//1132 1473//1135
+f 1468//1136 1467//1109 1482//1137
+f 1463//1119 1462//1112 1477//1138
+f 1474//1115 1473//1135 1489//1139
+f 1469//1117 1468//1136 1484//1140
+f 1464//1125 1463//1119 1478//1141
+f 1475//1121 1474//1115 1490//1142
+f 1470//1123 1469//1117 1485//1143
+f 1465//1131 1464//1125 1479//1144
+f 1476//1127 1475//1121 1491//1145
+f 1471//1129 1470//1123 1486//1146
+f 1466//1134 1465//1131 1480//1147
+f 1472//1133 1471//1129 1487//1148
+f 1467//1109 1466//1134 1481//1149
+f 1473//1135 1472//1133 1488//1150
+f 1487//1148 1486//1146 1502//1151
+f 1482//1137 1481//1149 1496//1152
+f 1488//1150 1487//1148 1503//1153
+f 1483//1154 1482//1137 1497//1155
+f 1478//1141 1477//1138 1492//1156
+f 1489//1139 1488//1150 1504//1157
+f 1484//1140 1483//1154 1499//1158
+f 1479//1144 1478//1141 1493//1159
+f 1490//1142 1489//1139 1505//1160
+f 1485//1143 1484//1140 1500//1161
+f 1480//1147 1479//1144 1494//1162
+f 1491//1145 1490//1142 1506//1163
+f 1486//1146 1485//1143 1501//1164
+f 1481//1149 1480//1147 1495//1165
+f 1506//1163 1505//1160 1521//1166
+f 1501//1164 1500//1161 1516//1167
+f 1496//1152 1495//1165 1510//1168
+f 1502//1151 1501//1164 1517//1169
+f 1497//1155 1496//1152 1511//1170
+f 1503//1153 1502//1151 1518//1171
+f 1498//1172 1497//1155 1512//1173
+f 1493//1159 1492//1156 1507//1174
+f 1504//1157 1503//1153 1519//1175
+f 1499//1158 1498//1172 1514//1176
+f 1494//1162 1493//1159 1508//1177
+f 1505//1160 1504//1157 1520//1178
+f 1500//1161 1499//1158 1515//1179
+f 1495//1165 1494//1162 1509//1180
+f 1509//1180 1508//1177 1523//1181
+f 1520//1178 1519//1175 1535//1182
+f 1515//1179 1514//1176 1530//1183
+f 1510//1168 1509//1180 1524//1184
+f 1521//1166 1520//1178 1536//1185
+f 1516//1167 1515//1179 1531//1186
+f 1511//1170 1510//1168 1525//1187
+f 1517//1169 1516//1167 1532//1188
+f 1512//1173 1511//1170 1526//1189
+f 1518//1171 1517//1169 1533//1190
+f 1513//1191 1512//1173 1527//1192
+f 1508//1177 1507//1174 1522//1193
+f 1519//1175 1518//1171 1534//1194
+f 1514//1176 1513//1191 1529//1195
+f 1528//1196 1527//1192 1542//1197
+f 1523//1181 1522//1193 1537//1198
+f 1534//1194 1533//1190 1549//1199
+f 1529//1195 1528//1196 1544//1200
+f 1524//1184 1523//1181 1538//1201
+f 1535//1182 1534//1194 1550//1202
+f 1530//1183 1529//1195 1545//1203
+f 1525//1187 1524//1184 1539//1204
+f 1536//1185 1535//1182 1551//1205
+f 1531//1186 1530//1183 1546//1206
+f 1526//1189 1525//1187 1540//1207
+f 1532//1188 1531//1186 1547//1208
+f 1527//1192 1526//1189 1541//1209
+f 1533//1190 1532//1188 1548//1210
+f 1547//1208 1546//1206 1562//1211
+f 1542//1197 1541//1209 1557//1212
+f 1548//1210 1547//1208 1563//1213
+f 1543//1214 1542//1197 1558//1215
+f 1538//1201 1537//1198 1552//1216
+f 1549//1199 1548//1210 1564//1217
+f 1544//1200 1543//1214 1559//1218
+f 1539//1204 1538//1201 1553//1219
+f 1550//1202 1549//1199 1565//1220
+f 1545//1203 1544//1200 1560//1221
+f 1540//1207 1539//1204 1554//1222
+f 1551//1205 1550//1202 1566//1223
+f 1546//1206 1545//1203 1561//1224
+f 1541//1209 1540//1207 1555//1225
+f 1566//1223 1565//1220 1580//1226
+f 1561//1224 1560//1221 1575//1227
+f 1556//1228 1555//1225 1571//1229
+f 1562//1211 1561//1224 1576//1230
+f 1557//1212 1556//1228 1572//1231
+f 1563//1213 1562//1211 1577//1232
+f 1558//1215 1557//1212 1573//1233
+f 1553//1219 1552//1216 1568//1234
+f 1564//1217 1563//1213 1578//1235
+f 1559//1218 1558//1215 1574//1236
+f 1554//1222 1553//1219 1569//1237
+f 1565//1220 1564//1217 1579//1238
+f 1560//1221 1559//1218 1575//1227
+f 1555//1225 1554//1222 1570//1239
+f 1580//1226 1579//1238 1594//1240
+f 1575//1227 1574//1236 1589//1241
+f 1570//1239 1569//1237 1585//1242
+f 1581//1243 1580//1226 1595//1244
+f 1576//1230 1575//1227 1590//1245
+f 1571//1229 1570//1239 1586//1246
+f 1577//1232 1576//1230 1591//1247
+f 1572//1231 1571//1229 1587//1248
+f 1578//1235 1577//1232 1592//1249
+f 1573//1233 1572//1231 1588//1250
+f 1568//1234 1567//1251 1583//1252
+f 1579//1238 1578//1235 1593//1253
+f 1574//1236 1573//1233 1589//1241
+f 1569//1237 1568//1234 1584//1254
+f 1583//1252 1582//1255 1598//1256
+f 1594//1240 1593//1253 1608//1257
+f 1589//1241 1588//1250 1604//1258
+f 1584//1254 1583//1252 1599//1259
+f 1595//1244 1594//1240 1609//1260
+f 1590//1245 1589//1241 1604//1258
+f 1585//1242 1584//1254 1600//1261
+f 1596//1262 1595//1244 1610//1263
+f 1591//1247 1590//1245 1605//1264
+f 1586//1246 1585//1242 1601//1265
+f 1592//1249 1591//1247 1606//1266
+f 1587//1248 1586//1246 1602//1267
+f 1593//1253 1592//1249 1607//1268
+f 1588//1250 1587//1248 1603//1269
+f 1602//1267 1601//1265 1617//1270
+f 1608//1257 1607//1268 1622//1271
+f 1603//1269 1602//1267 1618//1272
+f 1598//1256 1597//1273 1613//1274
+f 1609//1260 1608//1257 1623//1275
+f 1604//1258 1603//1269 1619//1276
+f 1599//1259 1598//1256 1614//1277
+f 1610//1263 1609//1260 1624//1278
+f 1605//1264 1604//1258 1619//1276
+f 1600//1261 1599//1259 1615//1279
+f 1611//1280 1610//1263 1625//1281
+f 1606//1266 1605//1264 1620//1282
+f 1601//1265 1600//1261 1616//1283
+f 1607//1268 1606//1266 1621//1284
+f 1621//1284 1620//1282 1635//1285
+f 1616//1283 1615//1279 1631//1286
+f 1622//1271 1621//1284 1636//1287
+f 1617//1270 1616//1283 1632//1288
+f 1623//1275 1622//1271 1637//1289
+f 1618//1272 1617//1270 1633//1290
+f 1613//1274 1612//1291 1628//1292
+f 1624//1278 1623//1275 1638//1293
+f 1619//1276 1618//1272 1634//1294
+f 1614//1277 1613//1274 1629//1295
+f 1625//1281 1624//1278 1639//1296
+f 1620//1282 1619//1276 1634//1294
+f 1615//1279 1614//1277 1630//1297
+f 1626//1298 1625//1281 1640//1299
+f 1640//1299 1639//1296 1654//1300
+f 1635//1285 1634//1294 1649//1301
+f 1630//1297 1629//1295 1645//1302
+f 1641//1303 1640//1299 1655//1304
+f 1636//1287 1635//1285 1650//1305
+f 1631//1286 1630//1297 1646//1306
+f 1637//1289 1636//1287 1651//1307
+f 1632//1288 1631//1286 1647//1308
+f 1638//1293 1637//1289 1652//1309
+f 1633//1290 1632//1288 1648//1310
+f 1628//1292 1627//1311 1643//1312
+f 1639//1296 1638//1293 1653//1313
+f 1634//1294 1633//1290 1649//1301
+f 1629//1295 1628//1292 1644//1314
+f 1643//1312 1642//1315 1658//1316
+f 1654//1300 1653//1313 1668//1317
+f 1649//1301 1648//1310 1663//1318
+f 1644//1314 1643//1312 1659//1319
+f 1655//1304 1654//1300 1669//1320
+f 1650//1305 1649//1301 1664//1321
+f 1645//1302 1644//1314 1660//1322
+f 1656//1323 1655//1304 1670//1324
+f 1651//1307 1650//1305 1665//1325
+f 1646//1306 1645//1302 1661//1326
+f 1652//1309 1651//1307 1666//1327
+f 1647//1308 1646//1306 1662//1328
+f 1653//1313 1652//1309 1667//1329
+f 1648//1310 1647//1308 1663//1318
+f 1662//1328 1661//1326 1676//1330
+f 1668//1317 1667//1329 1682//1331
+f 1663//1318 1662//1328 1677//1332
+f 1658//1316 1657//1333 1673//1334
+f 1669//1320 1668//1317 1683//1335
+f 1664//1321 1663//1318 1678//1336
+f 1659//1319 1658//1316 1674//1337
+f 1670//1324 1669//1320 1684//1338
+f 1665//1325 1664//1321 1679//1339
+f 1660//1322 1659//1319 1675//1340
+f 1671//1341 1670//1324 1685//1342
+f 1666//1327 1665//1325 1680//1343
+f 1661//1326 1660//1322 1676//1330
+f 1667//1329 1666//1327 1681//1344
+f 1681//1344 1680//1343 1695//1345
+f 1676//1330 1675//1340 1690//1346
+f 1682//1331 1681//1344 1697//1347
+f 1677//1332 1676//1330 1691//1348
+f 1683//1335 1682//1331 1698//1349
+f 1678//1336 1677//1332 1692//1350
+f 1673//1334 1672//1351 1687//1352
+f 1684//1338 1683//1335 1699//1353
+f 1679//1339 1678//1336 1693//1354
+f 1674//1337 1673//1334 1688//1355
+f 1685//1342 1684//1338 1700//1356
+f 1680//1343 1679//1339 1694//1357
+f 1675//1340 1674//1337 1689//1358
+f 1686//1359 1685//1342 1701//1360
+f 1700//1356 1699//1353 1715//1361
+f 1695//1345 1694//1357 1709//1362
+f 1690//1346 1689//1358 1704//1363
+f 1701//1360 1700//1356 1716//1364
+f 1696//1365 1695//1345 1711//1366
+f 1691//1348 1690//1346 1705//1367
+f 1697//1347 1696//1365 1712//1368
+f 1692//1350 1691//1348 1706//1369
+f 1698//1349 1697//1347 1713//1370
+f 1693//1354 1692//1350 1707//1371
+f 1688//1355 1687//1352 1702//1372
+f 1699//1353 1698//1349 1714//1373
+f 1694//1357 1693//1354 1708//1374
+f 1689//1358 1688//1355 1703//1375
+f 1714//1373 1713//1370 1729//1376
+f 1709//1362 1708//1374 1723//1377
+f 1704//1363 1703//1375 1718//1378
+f 1715//1361 1714//1373 1730//1379
+f 1710//1380 1709//1362 1724//1381
+f 1705//1367 1704//1363 1719//1382
+f 1716//1364 1715//1361 1731//1383
+f 1711//1366 1710//1380 1726//1384
+f 1706//1369 1705//1367 1720//1385
+f 1712//1368 1711//1366 1727//1386
+f 1707//1371 1706//1369 1721//1387
+f 1713//1370 1712//1368 1728//1388
+f 1708//1374 1707//1371 1722//1389
+f 1703//1375 1702//1372 1717//1390
+f 1728//1388 1727//1386 1743//1391
+f 1723//1377 1722//1389 1737//1392
+f 1718//1378 1717//1390 1732//1393
+f 1729//1376 1728//1388 1744//1394
+f 1724//1381 1723//1377 1738//1395
+f 1719//1382 1718//1378 1733//1396
+f 1730//1379 1729//1376 1745//1397
+f 1725//1398 1724//1381 1739//1399
+f 1720//1385 1719//1382 1734//1400
+f 1731//1383 1730//1379 1746//1401
+f 1726//1384 1725//1398 1741//1402
+f 1721//1387 1720//1385 1735//1403
+f 1727//1386 1726//1384 1742//1404
+f 1722//1389 1721//1387 1736//1405
+f 1736//1405 1735//1403 1750//1406
+f 1742//1404 1741//1402 1757//1407
+f 1737//1392 1736//1405 1751//1408
+f 1743//1391 1742//1404 1758//1409
+f 1738//1395 1737//1392 1752//1410
+f 1733//1396 1732//1393 1747//1411
+f 1744//1394 1743//1391 1759//1412
+f 1739//1399 1738//1395 1753//1413
+f 1734//1400 1733//1396 1748//1414
+f 1745//1397 1744//1394 1760//1415
+f 1740//1416 1739//1399 1754//1417
+f 1735//1403 1734//1400 1749//1418
+f 1746//1401 1745//1397 1761//1419
+f 1741//1402 1740//1416 1756//1420
+f 1755//1421 1754//1417 1769//1422
+f 1750//1406 1749//1418 1764//1423
+f 1761//1419 1760//1415 1776//1424
+f 1756//1420 1755//1421 1771//1425
+f 1751//1408 1750//1406 1765//1426
+f 1757//1407 1756//1420 1772//1427
+f 1752//1410 1751//1408 1766//1428
+f 1758//1409 1757//1407 1773//1429
+f 1753//1413 1752//1410 1767//1430
+f 1748//1414 1747//1411 1762//1431
+f 1759//1412 1758//1409 1774//1432
+f 1754//1417 1753//1413 1768//1433
+f 1749//1418 1748//1414 1763//1434
+f 1760//1415 1759//1412 1775//1435
+f 1774//1432 1773//1429 1790//1436
+f 1769//1422 1768//1433 1784//1437
+f 1764//1423 1763//1434 1779//1438
+f 1775//1435 1774//1432 1791//1439
+f 1770//1440 1769//1422 1785//1441
+f 1765//1426 1764//1423 1780//1442
+f 1776//1424 1775//1435 1792//1443
+f 1771//1425 1770//1440 1787//1444
+f 1766//1428 1765//1426 1781//1445
+f 1772//1427 1771//1425 1788//1446
+f 1767//1430 1766//1428 1782//1447
+f 1773//1429 1772//1427 1789//1448
+f 1768//1433 1767//1430 1783//1449
+f 1763//1434 1762//1431 1778//1450
+f 1789//1448 1788//1446 1804//1451
+f 1784//1437 1783//1449 1798//1452
+f 1779//1438 1778//1450 1793//1453
+f 1790//1436 1789//1448 1805//1454
+f 1785//1441 1784//1437 1799//1455
+f 1780//1442 1779//1438 1794//1456
+f 1791//1439 1790//1436 1806//1457
+f 1786//1458 1785//1441 1800//1459
+f 1781//1445 1780//1442 1795//1460
+f 1792//1443 1791//1439 1807//1461
+f 1787//1444 1786//1458 1801//1462
+f 1782//1447 1781//1445 1796//1463
+f 1788//1446 1787//1444 1802//1464
+f 1783//1449 1782//1447 1797//1465
+f 1797//1465 1796//1463 1812//1466
+f 1803//1467 1802//1464 1817//1468
+f 1798//1452 1797//1465 1813//1469
+f 1804//1451 1803//1467 1818//1470
+f 1799//1455 1798//1452 1814//1471
+f 1794//1456 1793//1453 1809//1472
+f 1805//1454 1804//1451 1819//1473
+f 1800//1459 1799//1455 1814//1471
+f 1795//1460 1794//1456 1810//1474
+f 1806//1457 1805//1454 1820//1475
+f 1801//1462 1800//1459 1815//1476
+f 1796//1463 1795//1460 1811//1477
+f 1807//1461 1806//1457 1821//1478
+f 1802//1464 1801//1462 1816//1479
+f 1816//1479 1815//1476 1830//1480
+f 1811//1477 1810//1474 1826//1481
+f 1822//1482 1821//1478 1836//1483
+f 1817//1468 1816//1479 1831//1484
+f 1812//1466 1811//1477 1827//1485
+f 1818//1470 1817//1468 1832//1486
+f 1813//1469 1812//1466 1828//1487
+f 1819//1473 1818//1470 1833//1488
+f 1814//1471 1813//1469 1829//1489
+f 1809//1472 1808//1490 1824//1491
+f 1820//1475 1819//1473 1834//1492
+f 1815//1476 1814//1471 1830//1480
+f 1810//1474 1809//1472 1825//1493
+f 1821//1478 1820//1475 1835//1494
+f 1835//1494 1834//1492 1849//1495
+f 1830//1480 1829//1489 1845//1496
+f 1825//1493 1824//1491 1840//1497
+f 1836//1483 1835//1494 1850//1498
+f 1831//1484 1830//1480 1845//1496
+f 1826//1481 1825//1493 1841//1499
+f 1837//1500 1836//1483 1851//1501
+f 1832//1486 1831//1484 1846//1502
+f 1827//1485 1826//1481 1842//1503
+f 1833//1488 1832//1486 1847//1504
+f 1828//1487 1827//1485 1843//1505
+f 1834//1492 1833//1488 1848//1506
+f 1829//1489 1828//1487 1844//1507
+f 1824//1491 1823//1508 1839//1509
+f 1849//1495 1848//1506 1863//1510
+f 1844//1507 1843//1505 1859//1511
+f 1839//1509 1838//1512 1854//1513
+f 1850//1498 1849//1495 1864//1514
+f 1845//1496 1844//1507 1860//1515
+f 1840//1497 1839//1509 1855//1516
+f 1851//1501 1850//1498 1865//1517
+f 1846//1502 1845//1496 1860//1515
+f 1841//1499 1840//1497 1856//1518
+f 1852//1519 1851//1501 1866//1520
+f 1847//1504 1846//1502 1861//1521
+f 1842//1503 1841//1499 1857//1522
+f 1848//1506 1847//1504 1862//1523
+f 1843//1505 1842//1503 1858//1524
+f 1863//1510 1862//1523 1877//1525
+f 1858//1524 1857//1522 1873//1526
+f 1864//1514 1863//1510 1878//1527
+f 1859//1511 1858//1524 1874//1528
+f 1854//1513 1853//1529 1869//1530
+f 1865//1517 1864//1514 1879//1531
+f 1860//1515 1859//1511 1875//1532
+f 1855//1516 1854//1513 1870//1533
+f 1866//1520 1865//1517 1880//1534
+f 1861//1521 1860//1515 1875//1532
+f 1856//1518 1855//1516 1871//1535
+f 1867//1536 1866//1520 1881//1537
+f 1862//1523 1861//1521 1876//1538
+f 1857//1522 1856//1518 1872//1539
+f 1871//1535 1870//1533 1886//1540
+f 1882//1541 1881//1537 1896//1542
+f 1877//1525 1876//1538 1891//1543
+f 1872//1539 1871//1535 1887//1544
+f 1878//1527 1877//1525 1892//1545
+f 1873//1526 1872//1539 1888//1546
+f 1879//1531 1878//1527 1893//1547
+f 1874//1528 1873//1526 1889//1548
+f 1869//1530 1868//1549 1884//1550
+f 1880//1534 1879//1531 1894//1551
+f 1875//1532 1874//1528 1890//1552
+f 1870//1533 1869//1530 1885//1553
+f 1881//1537 1880//1534 1895//1554
+f 1876//1538 1875//1532 1890//1552
+f 1890//1552 1889//1548 1906//1555
+f 1885//1553 1884//1550 1901//1556
+f 1896//1542 1895//1554 1911//1557
+f 1891//1543 1890//1552 1907//1558
+f 1886//1540 1885//1553 1902//1559
+f 1897//1560 1896//1542 1912//1561
+f 1892//1545 1891//1543 1907//1558
+f 1887//1544 1886//1540 1903//1562
+f 1893//1547 1892//1545 1908//1563
+f 1888//1546 1887//1544 1904//1564
+f 1894//1551 1893//1547 1909//1565
+f 1889//1548 1888//1546 1905//1566
+f 1884//1550 1883//1567 1900//1568
+f 1895//1554 1894//1551 1910//1569
+f 1910//1569 1909//1565 1924//1570
+f 1905//1566 1904//1564 1920//1571
+f 1900//1568 1899//1572 1915//1573
+f 1911//1557 1910//1569 1925//1574
+f 1906//1555 1905//1566 1921//1575
+f 1901//1556 1900//1568 1916//1576
+f 1912//1561 1911//1557 1926//1577
+f 1907//1558 1906//1555 1922//1578
+f 1902//1559 1901//1556 1917//1579
+f 1913//1580 1912//1561 1927//1581
+f 1908//1563 1907//1558 1923//1582
+f 1903//1562 1902//1559 1918//1583
+f 1909//1565 1908//1563 1924//1570
+f 1904//1564 1903//1562 1919//1584
+f 1777//1585 1461//1126 1476//1127
+f 1447//1111 1898//1586 1462//1112
+f 1777//1585 1476//1127 1491//1145
+f 1462//1112 1898//1586 1477//1138
+f 1477//1138 1898//1586 1492//1156
+f 1777//1585 1491//1145 1506//1163
+f 1777//1585 1506//1163 1521//1166
+f 1492//1156 1898//1586 1507//1174
+f 1777//1585 1521//1166 1536//1185
+f 1507//1174 1898//1586 1522//1193
+f 1777//1585 1536//1185 1551//1205
+f 1522//1193 1898//1586 1537//1198
+f 1537//1198 1898//1586 1552//1216
+f 1777//1585 1551//1205 1566//1223
+f 1777//1585 1566//1223 1581//1243
+f 1552//1216 1898//1586 1567//1251
+f 1777//1585 1581//1243 1596//1262
+f 1567//1251 1898//1586 1582//1255
+f 1777//1585 1596//1262 1611//1280
+f 1582//1255 1898//1586 1597//1273
+f 1597//1273 1898//1586 1612//1291
+f 1777//1585 1611//1280 1626//1298
+f 1777//1585 1626//1298 1641//1303
+f 1612//1291 1898//1586 1627//1311
+f 1777//1585 1641//1303 1656//1323
+f 1627//1311 1898//1586 1642//1315
+f 1777//1585 1656//1323 1671//1341
+f 1642//1315 1898//1586 1657//1333
+f 1657//1333 1898//1586 1672//1351
+f 1777//1585 1671//1341 1686//1359
+f 1777//1585 1686//1359 1701//1360
+f 1672//1351 1898//1586 1687//1352
+f 1777//1585 1701//1360 1716//1364
+f 1687//1352 1898//1586 1702//1372
+f 1777//1585 1716//1364 1731//1383
+f 1702//1372 1898//1586 1717//1390
+f 1717//1390 1898//1586 1732//1393
+f 1777//1585 1731//1383 1746//1401
+f 1777//1585 1746//1401 1761//1419
+f 1732//1393 1898//1586 1747//1411
+f 1777//1585 1761//1419 1776//1424
+f 1747//1411 1898//1586 1762//1431
+f 1777//1585 1776//1424 1792//1443
+f 1762//1431 1898//1586 1778//1450
+f 1778//1450 1898//1586 1793//1453
+f 1777//1585 1792//1443 1807//1461
+f 1777//1585 1807//1461 1822//1482
+f 1793//1453 1898//1586 1808//1490
+f 1777//1585 1822//1482 1837//1500
+f 1808//1490 1898//1586 1823//1508
+f 1777//1585 1837//1500 1852//1519
+f 1823//1508 1898//1586 1838//1512
+f 1777//1585 1852//1519 1867//1536
+f 1838//1512 1898//1586 1853//1529
+f 1777//1585 1867//1536 1882//1541
+f 1853//1529 1898//1586 1868//1549
+f 1777//1585 1882//1541 1897//1560
+f 1868//1549 1898//1586 1883//1567
+f 1777//1585 1897//1560 1913//1580
+f 1883//1567 1898//1586 1899//1572
+f 1777//1585 1913//1580 1928//1587
+f 1899//1572 1898//1586 1914//1588
+f 1777//1585 1928//1587 1461//1126
+f 1924//1570 1923//1582 1457//1132
+f 1919//1584 1918//1583 1451//1130
+f 1914//1588 1898//1586 1447//1111
+f 1925//1574 1924//1570 1458//1114
+f 1920//1571 1919//1584 1453//1107
+f 1915//1573 1914//1588 1447//1111
+f 1926//1577 1925//1574 1459//1113
+f 1921//1575 1920//1571 1454//1116
+f 1916//1576 1915//1573 1448//1110
+f 1927//1581 1926//1577 1460//1120
+f 1922//1578 1921//1575 1455//1122
+f 1917//1579 1916//1576 1449//1118
+f 1928//1587 1927//1581 1461//1126
+f 1923//1582 1922//1578 1456//1128
+f 1918//1583 1917//1579 1450//1124
+f 1935//1107 1934//1108 1949//1109
+f 1930//1110 1929//1589 1944//1112
+f 1941//1113 1940//1114 1956//1590
+f 1936//1116 1935//1107 1951//1117
+f 1931//1118 1930//1110 1945//1119
+f 1942//1120 1941//1113 1957//1121
+f 1937//1122 1936//1116 1952//1123
+f 1932//1124 1931//1118 1946//1125
+f 1943//1591 1942//1120 1958//1127
+f 1938//1128 1937//1122 1953//1129
+f 1933//1130 1932//1124 1947//1131
+f 1939//1592 1938//1128 1954//1133
+f 1934//1108 1933//1130 1948//1134
+f 1940//1114 1939//1592 1955//1135
+f 1950//1136 1949//1109 1964//1137
+f 1945//1119 1944//1112 1959//1138
+f 1956//1590 1955//1135 1971//1139
+f 1951//1117 1950//1136 1966//1140
+f 1946//1125 1945//1119 1960//1141
+f 1957//1121 1956//1590 1972//1142
+f 1952//1123 1951//1117 1967//1143
+f 1947//1131 1946//1125 1961//1144
+f 1958//1127 1957//1121 1973//1145
+f 1953//1129 1952//1123 1968//1593
+f 1948//1134 1947//1131 1962//1147
+f 1954//1133 1953//1129 1969//1148
+f 1949//1109 1948//1134 1963//1149
+f 1955//1135 1954//1133 1970//1594
+f 1969//1148 1968//1593 1984//1151
+f 1964//1137 1963//1149 1978//1152
+f 1970//1594 1969//1148 1985//1595
+f 1965//1154 1964//1137 1979//1155
+f 1960//1141 1959//1138 1974//1596
+f 1971//1139 1970//1594 1986//1157
+f 1966//1140 1965//1154 1981//1158
+f 1961//1144 1960//1141 1975//1159
+f 1972//1142 1971//1139 1987//1160
+f 1967//1143 1966//1140 1982//1597
+f 1962//1147 1961//1144 1976//1162
+f 1973//1145 1972//1142 1988//1598
+f 1968//1593 1967//1143 1983//1164
+f 1963//1149 1962//1147 1977//1165
+f 1988//1598 1987//1160 2003//1166
+f 1983//1164 1982//1597 1998//1599
+f 1978//1152 1977//1165 1992//1168
+f 1984//1151 1983//1164 1999//1600
+f 1979//1155 1978//1152 1993//1601
+f 1985//1595 1984//1151 2000//1171
+f 1980//1172 1979//1155 1994//1173
+f 1975//1159 1974//1596 1989//1174
+f 1986//1157 1985//1595 2001//1175
+f 1981//1158 1980//1172 1996//1176
+f 1976//1162 1975//1159 1990//1177
+f 1987//1160 1986//1157 2002//1178
+f 1982//1597 1981//1158 1997//1179
+f 1977//1165 1976//1162 1991//1602
+f 1991//1602 1990//1177 2005//1181
+f 2002//1178 2001//1175 2017//1182
+f 1997//1179 1996//1176 2012//1183
+f 1992//1168 1991//1602 2006//1603
+f 2003//1166 2002//1178 2018//1185
+f 1998//1599 1997//1179 2013//1186
+f 1993//1601 1992//1168 2007//1604
+f 1999//1600 1998//1599 2014//1188
+f 1994//1173 1993//1601 2008//1189
+f 2000//1171 1999//1600 2015//1190
+f 1995//1191 1994//1173 2009//1192
+f 1990//1177 1989//1174 2004//1605
+f 2001//1175 2000//1171 2016//1194
+f 1996//1176 1995//1191 2011//1606
+f 2010//1196 2009//1192 2024//1197
+f 2005//1181 2004//1605 2019//1198
+f 2016//1194 2015//1190 2031//1199
+f 2011//1606 2010//1196 2026//1607
+f 2006//1603 2005//1181 2020//1201
+f 2017//1182 2016//1194 2032//1202
+f 2012//1183 2011//1606 2027//1203
+f 2007//1604 2006//1603 2021//1204
+f 2018//1185 2017//1182 2033//1608
+f 2013//1186 2012//1183 2028//1206
+f 2008//1189 2007//1604 2022//1609
+f 2014//1188 2013//1186 2029//1208
+f 2009//1192 2008//1189 2023//1209
+f 2015//1190 2014//1188 2030//1210
+f 2029//1208 2028//1206 2044//1211
+f 2024//1197 2023//1209 2039//1212
+f 2030//1210 2029//1208 2045//1213
+f 2025//1610 2024//1197 2040//1215
+f 2020//1201 2019//1198 2034//1216
+f 2031//1199 2030//1210 2046//1217
+f 2026//1607 2025//1610 2041//1611
+f 2021//1204 2020//1201 2035//1219
+f 2032//1202 2031//1199 2047//1220
+f 2027//1203 2026//1607 2042//1221
+f 2022//1609 2021//1204 2036//1222
+f 2033//1608 2032//1202 2048//1612
+f 2028//1206 2027//1203 2043//1224
+f 2023//1209 2022//1609 2037//1225
+f 2048//1612 2047//1220 2062//1226
+f 2043//1224 2042//1221 2057//1613
+f 2038//1228 2037//1225 2053//1229
+f 2044//1211 2043//1224 2058//1230
+f 2039//1212 2038//1228 2054//1614
+f 2045//1213 2044//1211 2059//1232
+f 2040//1215 2039//1212 2055//1615
+f 2035//1219 2034//1216 2050//1616
+f 2046//1217 2045//1213 2060//1235
+f 2041//1611 2040//1215 2056//1236
+f 2036//1222 2035//1219 2051//1237
+f 2047//1220 2046//1217 2061//1238
+f 2042//1221 2041//1611 2057//1613
+f 2037//1225 2036//1222 2052//1239
+f 2062//1226 2061//1238 2076//1617
+f 2057//1613 2056//1236 2071//1241
+f 2052//1239 2051//1237 2067//1618
+f 2063//1243 2062//1226 2077//1244
+f 2058//1230 2057//1613 2072//1245
+f 2053//1229 2052//1239 2068//1619
+f 2059//1232 2058//1230 2073//1247
+f 2054//1614 2053//1229 2069//1248
+f 2060//1235 2059//1232 2074//1249
+f 2055//1615 2054//1614 2070//1250
+f 2050//1616 2049//1251 2065//1252
+f 2061//1238 2060//1235 2075//1253
+f 2056//1236 2055//1615 2071//1241
+f 2051//1237 2050//1616 2066//1620
+f 2065//1252 2064//1621 2080//1622
+f 2076//1617 2075//1253 2090//1257
+f 2071//1241 2070//1250 2086//1258
+f 2066//1620 2065//1252 2081//1623
+f 2077//1244 2076//1617 2091//1260
+f 2072//1245 2071//1241 2086//1258
+f 2067//1618 2066//1620 2082//1261
+f 2078//1262 2077//1244 2092//1263
+f 2073//1247 2072//1245 2087//1624
+f 2068//1619 2067//1618 2083//1265
+f 2074//1249 2073//1247 2088//1625
+f 2069//1248 2068//1619 2084//1626
+f 2075//1253 2074//1249 2089//1268
+f 2070//1250 2069//1248 2085//1269
+f 2084//1626 2083//1265 2099//1270
+f 2090//1257 2089//1268 2104//1271
+f 2085//1269 2084//1626 2100//1627
+f 2080//1622 2079//1628 2095//1274
+f 2091//1260 2090//1257 2105//1275
+f 2086//1258 2085//1269 2101//1276
+f 2081//1623 2080//1622 2096//1277
+f 2092//1263 2091//1260 2106//1278
+f 2087//1624 2086//1258 2101//1276
+f 2082//1261 2081//1623 2097//1629
+f 2093//1280 2092//1263 2107//1281
+f 2088//1625 2087//1624 2102//1282
+f 2083//1265 2082//1261 2098//1283
+f 2089//1268 2088//1625 2103//1630
+f 2103//1630 2102//1282 2117//1285
+f 2098//1283 2097//1629 2113//1286
+f 2104//1271 2103//1630 2118//1287
+f 2099//1270 2098//1283 2114//1288
+f 2105//1275 2104//1271 2119//1631
+f 2100//1627 2099//1270 2115//1290
+f 2095//1274 2094//1291 2110//1292
+f 2106//1278 2105//1275 2120//1632
+f 2101//1276 2100//1627 2116//1294
+f 2096//1277 2095//1274 2111//1633
+f 2107//1281 2106//1278 2121//1296
+f 2102//1282 2101//1276 2116//1294
+f 2097//1629 2096//1277 2112//1634
+f 2108//1298 2107//1281 2122//1299
+f 2122//1299 2121//1296 2136//1300
+f 2117//1285 2116//1294 2131//1301
+f 2112//1634 2111//1633 2127//1302
+f 2123//1635 2122//1299 2137//1304
+f 2118//1287 2117//1285 2132//1305
+f 2113//1286 2112//1634 2128//1306
+f 2119//1631 2118//1287 2133//1307
+f 2114//1288 2113//1286 2129//1308
+f 2120//1632 2119//1631 2134//1309
+f 2115//1290 2114//1288 2130//1310
+f 2110//1292 2109//1636 2125//1637
+f 2121//1296 2120//1632 2135//1638
+f 2116//1294 2115//1290 2131//1301
+f 2111//1633 2110//1292 2126//1639
+f 2125//1637 2124//1315 2140//1316
+f 2136//1300 2135//1638 2150//1317
+f 2131//1301 2130//1310 2145//1640
+f 2126//1639 2125//1637 2141//1319
+f 2137//1304 2136//1300 2151//1320
+f 2132//1305 2131//1301 2146//1321
+f 2127//1302 2126//1639 2142//1322
+f 2138//1323 2137//1304 2152//1641
+f 2133//1307 2132//1305 2147//1642
+f 2128//1306 2127//1302 2143//1326
+f 2134//1309 2133//1307 2148//1643
+f 2129//1308 2128//1306 2144//1328
+f 2135//1638 2134//1309 2149//1329
+f 2130//1310 2129//1308 2145//1640
+f 2144//1328 2143//1326 2158//1330
+f 2150//1317 2149//1329 2164//1331
+f 2145//1640 2144//1328 2159//1332
+f 2140//1316 2139//1333 2155//1334
+f 2151//1320 2150//1317 2165//1644
+f 2146//1321 2145//1640 2160//1645
+f 2141//1319 2140//1316 2156//1337
+f 2152//1641 2151//1320 2166//1338
+f 2147//1642 2146//1321 2161//1339
+f 2142//1322 2141//1319 2157//1340
+f 2153//1646 2152//1641 2167//1342
+f 2148//1643 2147//1642 2162//1647
+f 2143//1326 2142//1322 2158//1330
+f 2149//1329 2148//1643 2163//1344
+f 2163//1344 2162//1647 2177//1345
+f 2158//1330 2157//1340 2172//1346
+f 2164//1331 2163//1344 2179//1648
+f 2159//1332 2158//1330 2173//1348
+f 2165//1644 2164//1331 2180//1349
+f 2160//1645 2159//1332 2174//1350
+f 2155//1334 2154//1649 2169//1352
+f 2166//1338 2165//1644 2181//1650
+f 2161//1339 2160//1645 2175//1354
+f 2156//1337 2155//1334 2170//1651
+f 2167//1342 2166//1338 2182//1356
+f 2162//1647 2161//1339 2176//1357
+f 2157//1340 2156//1337 2171//1358
+f 2168//1359 2167//1342 2183//1360
+f 2182//1356 2181//1650 2197//1652
+f 2177//1345 2176//1357 2191//1653
+f 2172//1346 2171//1358 2186//1654
+f 2183//1360 2182//1356 2198//1364
+f 2178//1365 2177//1345 2193//1366
+f 2173//1348 2172//1346 2187//1367
+f 2179//1648 2178//1365 2194//1368
+f 2174//1350 2173//1348 2188//1655
+f 2180//1349 2179//1648 2195//1370
+f 2175//1354 2174//1350 2189//1371
+f 2170//1651 2169//1352 2184//1656
+f 2181//1650 2180//1349 2196//1373
+f 2176//1357 2175//1354 2190//1374
+f 2171//1358 2170//1651 2185//1375
+f 2196//1373 2195//1370 2211//1376
+f 2191//1653 2190//1374 2205//1377
+f 2186//1654 2185//1375 2200//1378
+f 2197//1652 2196//1373 2212//1379
+f 2192//1380 2191//1653 2206//1381
+f 2187//1367 2186//1654 2201//1382
+f 2198//1364 2197//1652 2213//1383
+f 2193//1366 2192//1380 2208//1384
+f 2188//1655 2187//1367 2202//1385
+f 2194//1368 2193//1366 2209//1386
+f 2189//1371 2188//1655 2203//1387
+f 2195//1370 2194//1368 2210//1388
+f 2190//1374 2189//1371 2204//1389
+f 2185//1375 2184//1656 2199//1390
+f 2210//1388 2209//1386 2225//1391
+f 2205//1377 2204//1389 2219//1392
+f 2200//1378 2199//1390 2214//1393
+f 2211//1376 2210//1388 2226//1657
+f 2206//1381 2205//1377 2220//1658
+f 2201//1382 2200//1378 2215//1396
+f 2212//1379 2211//1376 2227//1397
+f 2207//1398 2206//1381 2221//1659
+f 2202//1385 2201//1382 2216//1400
+f 2213//1383 2212//1379 2228//1401
+f 2208//1384 2207//1398 2223//1660
+f 2203//1387 2202//1385 2217//1661
+f 2209//1386 2208//1384 2224//1404
+f 2204//1389 2203//1387 2218//1405
+f 2218//1405 2217//1661 2232//1662
+f 2224//1404 2223//1660 2239//1663
+f 2219//1392 2218//1405 2233//1664
+f 2225//1391 2224//1404 2240//1409
+f 2220//1658 2219//1392 2234//1665
+f 2215//1396 2214//1393 2229//1411
+f 2226//1657 2225//1391 2241//1666
+f 2221//1659 2220//1658 2235//1413
+f 2216//1400 2215//1396 2230//1414
+f 2227//1397 2226//1657 2242//1667
+f 2222//1668 2221//1659 2236//1417
+f 2217//1661 2216//1400 2231//1669
+f 2228//1401 2227//1397 2243//1419
+f 2223//1660 2222//1668 2238//1420
+f 2237//1421 2236//1417 2251//1670
+f 2232//1662 2231//1669 2246//1423
+f 2243//1419 2242//1667 2258//1424
+f 2238//1420 2237//1421 2253//1425
+f 2233//1664 2232//1662 2247//1671
+f 2239//1663 2238//1420 2254//1427
+f 2234//1665 2233//1664 2248//1428
+f 2240//1409 2239//1663 2255//1429
+f 2235//1413 2234//1665 2249//1430
+f 2230//1414 2229//1411 2244//1431
+f 2241//1666 2240//1409 2256//1672
+f 2236//1417 2235//1413 2250//1433
+f 2231//1669 2230//1414 2245//1434
+f 2242//1667 2241//1666 2257//1435
+f 2256//1672 2255//1429 2272//1436
+f 2251//1670 2250//1433 2266//1437
+f 2246//1423 2245//1434 2261//1438
+f 2257//1435 2256//1672 2273//1673
+f 2252//1440 2251//1670 2267//1674
+f 2247//1671 2246//1423 2262//1442
+f 2258//1424 2257//1435 2274//1443
+f 2253//1425 2252//1440 2269//1444
+f 2248//1428 2247//1671 2263//1445
+f 2254//1427 2253//1425 2270//1446
+f 2249//1430 2248//1428 2264//1447
+f 2255//1429 2254//1427 2271//1675
+f 2250//1433 2249//1430 2265//1449
+f 2245//1434 2244//1431 2260//1450
+f 2271//1675 2270//1446 2286//1451
+f 2266//1437 2265//1449 2280//1452
+f 2261//1438 2260//1450 2275//1676
+f 2272//1436 2271//1675 2287//1677
+f 2267//1674 2266//1437 2281//1455
+f 2262//1442 2261//1438 2276//1456
+f 2273//1673 2272//1436 2288//1457
+f 2268//1678 2267//1674 2282//1679
+f 2263//1445 2262//1442 2277//1680
+f 2274//1443 2273//1673 2289//1681
+f 2269//1444 2268//1678 2283//1682
+f 2264//1447 2263//1445 2278//1463
+f 2270//1446 2269//1444 2284//1464
+f 2265//1449 2264//1447 2279//1683
+f 2279//1683 2278//1463 2294//1466
+f 2285//1684 2284//1464 2299//1685
+f 2280//1452 2279//1683 2295//1469
+f 2286//1451 2285//1684 2300//1470
+f 2281//1455 2280//1452 2296//1471
+f 2276//1456 2275//1676 2291//1472
+f 2287//1677 2286//1451 2301//1473
+f 2282//1679 2281//1455 2296//1471
+f 2277//1680 2276//1456 2292//1686
+f 2288//1457 2287//1677 2302//1475
+f 2283//1682 2282//1679 2297//1476
+f 2278//1463 2277//1680 2293//1477
+f 2289//1681 2288//1457 2303//1687
+f 2284//1464 2283//1682 2298//1688
+f 2298//1688 2297//1476 2312//1480
+f 2293//1477 2292//1686 2308//1481
+f 2304//1482 2303//1687 2318//1483
+f 2299//1685 2298//1688 2313//1484
+f 2294//1466 2293//1477 2309//1485
+f 2300//1470 2299//1685 2314//1486
+f 2295//1469 2294//1466 2310//1487
+f 2301//1473 2300//1470 2315//1689
+f 2296//1471 2295//1469 2311//1489
+f 2291//1472 2290//1490 2306//1491
+f 2302//1475 2301//1473 2316//1690
+f 2297//1476 2296//1471 2312//1480
+f 2292//1686 2291//1472 2307//1493
+f 2303//1687 2302//1475 2317//1691
+f 2317//1691 2316//1690 2331//1495
+f 2312//1480 2311//1489 2327//1496
+f 2307//1493 2306//1491 2322//1497
+f 2318//1483 2317//1691 2332//1498
+f 2313//1484 2312//1480 2327//1496
+f 2308//1481 2307//1493 2323//1499
+f 2319//1692 2318//1483 2333//1693
+f 2314//1486 2313//1484 2328//1502
+f 2309//1485 2308//1481 2324//1503
+f 2315//1689 2314//1486 2329//1504
+f 2310//1487 2309//1485 2325//1505
+f 2316//1690 2315//1689 2330//1506
+f 2311//1489 2310//1487 2326//1507
+f 2306//1491 2305//1508 2321//1694
+f 2331//1495 2330//1506 2345//1510
+f 2326//1507 2325//1505 2341//1511
+f 2321//1694 2320//1695 2336//1513
+f 2332//1498 2331//1495 2346//1514
+f 2327//1496 2326//1507 2342//1515
+f 2322//1497 2321//1694 2337//1696
+f 2333//1693 2332//1498 2347//1517
+f 2328//1502 2327//1496 2342//1515
+f 2323//1499 2322//1497 2338//1518
+f 2334//1697 2333//1693 2348//1520
+f 2329//1504 2328//1502 2343//1521
+f 2324//1503 2323//1499 2339//1522
+f 2330//1506 2329//1504 2344//1523
+f 2325//1505 2324//1503 2340//1524
+f 2345//1510 2344//1523 2359//1525
+f 2340//1524 2339//1522 2355//1526
+f 2346//1514 2345//1510 2360//1527
+f 2341//1511 2340//1524 2356//1528
+f 2336//1513 2335//1529 2351//1698
+f 2347//1517 2346//1514 2361//1531
+f 2342//1515 2341//1511 2357//1532
+f 2337//1696 2336//1513 2352//1533
+f 2348//1520 2347//1517 2362//1534
+f 2343//1521 2342//1515 2357//1532
+f 2338//1518 2337//1696 2353//1699
+f 2349//1536 2348//1520 2363//1700
+f 2344//1523 2343//1521 2358//1701
+f 2339//1522 2338//1518 2354//1702
+f 2353//1699 2352//1533 2368//1540
+f 2364//1541 2363//1700 2378//1703
+f 2359//1525 2358//1701 2373//1543
+f 2354//1702 2353//1699 2369//1544
+f 2360//1527 2359//1525 2374//1545
+f 2355//1526 2354//1702 2370//1546
+f 2361//1531 2360//1527 2375//1547
+f 2356//1528 2355//1526 2371//1548
+f 2351//1698 2350//1549 2366//1550
+f 2362//1534 2361//1531 2376//1551
+f 2357//1532 2356//1528 2372//1552
+f 2352//1533 2351//1698 2367//1704
+f 2363//1700 2362//1534 2377//1705
+f 2358//1701 2357//1532 2372//1552
+f 2372//1552 2371//1548 2388//1706
+f 2367//1704 2366//1550 2383//1556
+f 2378//1703 2377//1705 2393//1557
+f 2373//1543 2372//1552 2389//1558
+f 2368//1540 2367//1704 2384//1559
+f 2379//1560 2378//1703 2394//1561
+f 2374//1545 2373//1543 2389//1558
+f 2369//1544 2368//1540 2385//1562
+f 2375//1547 2374//1545 2390//1563
+f 2370//1546 2369//1544 2386//1564
+f 2376//1551 2375//1547 2391//1565
+f 2371//1548 2370//1546 2387//1566
+f 2366//1550 2365//1567 2382//1707
+f 2377//1705 2376//1551 2392//1708
+f 2392//1708 2391//1565 2406//1570
+f 2387//1566 2386//1564 2402//1571
+f 2382//1707 2381//1572 2397//1573
+f 2393//1557 2392//1708 2407//1574
+f 2388//1706 2387//1566 2403//1709
+f 2383//1556 2382//1707 2398//1576
+f 2394//1561 2393//1557 2408//1577
+f 2389//1558 2388//1706 2404//1578
+f 2384//1559 2383//1556 2399//1579
+f 2395//1710 2394//1561 2409//1581
+f 2390//1563 2389//1558 2405//1582
+f 2385//1562 2384//1559 2400//1583
+f 2391//1565 2390//1563 2406//1570
+f 2386//1564 2385//1562 2401//1584
+f 2259//1585 1943//1591 1958//1127
+f 1929//1589 2380//1586 1944//1112
+f 2259//1585 1958//1127 1973//1145
+f 1944//1112 2380//1586 1959//1138
+f 1959//1138 2380//1586 1974//1596
+f 2259//1585 1973//1145 1988//1598
+f 2259//1585 1988//1598 2003//1166
+f 1974//1596 2380//1586 1989//1174
+f 2259//1585 2003//1166 2018//1185
+f 1989//1174 2380//1586 2004//1605
+f 2259//1585 2018//1185 2033//1608
+f 2004//1605 2380//1586 2019//1198
+f 2019//1198 2380//1586 2034//1216
+f 2259//1585 2033//1608 2048//1612
+f 2259//1585 2048//1612 2063//1243
+f 2034//1216 2380//1586 2049//1251
+f 2259//1585 2063//1243 2078//1262
+f 2049//1251 2380//1586 2064//1621
+f 2259//1585 2078//1262 2093//1280
+f 2064//1621 2380//1586 2079//1628
+f 2079//1628 2380//1586 2094//1291
+f 2259//1585 2093//1280 2108//1298
+f 2259//1585 2108//1298 2123//1635
+f 2094//1291 2380//1586 2109//1636
+f 2259//1585 2123//1635 2138//1323
+f 2109//1636 2380//1586 2124//1315
+f 2259//1585 2138//1323 2153//1646
+f 2124//1315 2380//1586 2139//1333
+f 2139//1333 2380//1586 2154//1649
+f 2259//1585 2153//1646 2168//1359
+f 2259//1585 2168//1359 2183//1360
+f 2154//1649 2380//1586 2169//1352
+f 2259//1585 2183//1360 2198//1364
+f 2169//1352 2380//1586 2184//1656
+f 2259//1585 2198//1364 2213//1383
+f 2184//1656 2380//1586 2199//1390
+f 2199//1390 2380//1586 2214//1393
+f 2259//1585 2213//1383 2228//1401
+f 2259//1585 2228//1401 2243//1419
+f 2214//1393 2380//1586 2229//1411
+f 2259//1585 2243//1419 2258//1424
+f 2229//1411 2380//1586 2244//1431
+f 2259//1585 2258//1424 2274//1443
+f 2244//1431 2380//1586 2260//1450
+f 2260//1450 2380//1586 2275//1676
+f 2259//1585 2274//1443 2289//1681
+f 2259//1585 2289//1681 2304//1482
+f 2275//1676 2380//1586 2290//1490
+f 2259//1585 2304//1482 2319//1692
+f 2290//1490 2380//1586 2305//1508
+f 2259//1585 2319//1692 2334//1697
+f 2305//1508 2380//1586 2320//1695
+f 2259//1585 2334//1697 2349//1536
+f 2320//1695 2380//1586 2335//1529
+f 2259//1585 2349//1536 2364//1541
+f 2335//1529 2380//1586 2350//1549
+f 2259//1585 2364//1541 2379//1560
+f 2350//1549 2380//1586 2365//1567
+f 2259//1585 2379//1560 2395//1710
+f 2365//1567 2380//1586 2381//1572
+f 2259//1585 2395//1710 2410//1587
+f 2381//1572 2380//1586 2396//1588
+f 2259//1585 2410//1587 1943//1591
+f 2406//1570 2405//1582 1939//1592
+f 2401//1584 2400//1583 1933//1130
+f 2396//1588 2380//1586 1929//1589
+f 2407//1574 2406//1570 1940//1114
+f 2402//1571 2401//1584 1935//1107
+f 2397//1573 2396//1588 1929//1589
+f 2408//1577 2407//1574 1941//1113
+f 2403//1709 2402//1571 1936//1116
+f 2398//1576 2397//1573 1930//1110
+f 2409//1581 2408//1577 1942//1120
+f 2404//1578 2403//1709 1937//1122
+f 2399//1579 2398//1576 1931//1118
+f 2410//1587 2409//1581 1943//1591
+f 2405//1582 2404//1578 1938//1128
+f 2400//1583 2399//1579 1932//1124
+f 1468//1136 1453//1107 1467//1109
+f 1463//1119 1448//1110 1462//1112
+f 1458//1114 1473//1135 1474//1115
+f 1453//1107 1468//1136 1469//1117
+f 1464//1125 1449//1118 1463//1119
+f 1459//1113 1474//1115 1475//1121
+f 1454//1116 1469//1117 1470//1123
+f 1465//1131 1450//1124 1464//1125
+f 1460//1120 1475//1121 1476//1127
+f 1455//1122 1470//1123 1471//1129
+f 1466//1134 1451//1130 1465//1131
+f 1456//1128 1471//1129 1472//1133
+f 1467//1109 1452//1108 1466//1134
+f 1457//1132 1472//1133 1473//1135
+f 1483//1154 1468//1136 1482//1137
+f 1478//1141 1463//1119 1477//1138
+f 1473//1135 1488//1150 1489//1139
+f 1468//1136 1483//1154 1484//1140
+f 1479//1144 1464//1125 1478//1141
+f 1474//1115 1489//1139 1490//1142
+f 1469//1117 1484//1140 1485//1143
+f 1480//1147 1465//1131 1479//1144
+f 1475//1121 1490//1142 1491//1145
+f 1470//1123 1485//1143 1486//1146
+f 1481//1149 1466//1134 1480//1147
+f 1471//1129 1486//1146 1487//1148
+f 1482//1137 1467//1109 1481//1149
+f 1472//1133 1487//1148 1488//1150
+f 1486//1146 1501//1164 1502//1151
+f 1497//1155 1482//1137 1496//1152
+f 1487//1148 1502//1151 1503//1153
+f 1498//1172 1483//1154 1497//1155
+f 1493//1159 1478//1141 1492//1156
+f 1488//1150 1503//1153 1504//1157
+f 1483//1154 1498//1172 1499//1158
+f 1494//1162 1479//1144 1493//1159
+f 1489//1139 1504//1157 1505//1160
+f 1484//1140 1499//1158 1500//1161
+f 1495//1165 1480//1147 1494//1162
+f 1490//1142 1505//1160 1506//1163
+f 1485//1143 1500//1161 1501//1164
+f 1496//1152 1481//1149 1495//1165
+f 1505//1160 1520//1178 1521//1166
+f 1500//1161 1515//1179 1516//1167
+f 1511//1170 1496//1152 1510//1168
+f 1501//1164 1516//1167 1517//1169
+f 1512//1173 1497//1155 1511//1170
+f 1502//1151 1517//1169 1518//1171
+f 1513//1191 1498//1172 1512//1173
+f 1508//1177 1493//1159 1507//1174
+f 1503//1153 1518//1171 1519//1175
+f 1498//1172 1513//1191 1514//1176
+f 1509//1180 1494//1162 1508//1177
+f 1504//1157 1519//1175 1520//1178
+f 1499//1158 1514//1176 1515//1179
+f 1510//1168 1495//1165 1509//1180
+f 1524//1184 1509//1180 1523//1181
+f 1519//1175 1534//1194 1535//1182
+f 1514//1176 1529//1195 1530//1183
+f 1525//1187 1510//1168 1524//1184
+f 1520//1178 1535//1182 1536//1185
+f 1515//1179 1530//1183 1531//1186
+f 1526//1189 1511//1170 1525//1187
+f 1516//1167 1531//1186 1532//1188
+f 1527//1192 1512//1173 1526//1189
+f 1517//1169 1532//1188 1533//1190
+f 1528//1196 1513//1191 1527//1192
+f 1523//1181 1508//1177 1522//1193
+f 1518//1171 1533//1190 1534//1194
+f 1513//1191 1528//1196 1529//1195
+f 1543//1214 1528//1196 1542//1197
+f 1538//1201 1523//1181 1537//1198
+f 1533//1190 1548//1210 1549//1199
+f 1528//1196 1543//1214 1544//1200
+f 1539//1204 1524//1184 1538//1201
+f 1534//1194 1549//1199 1550//1202
+f 1529//1195 1544//1200 1545//1203
+f 1540//1207 1525//1187 1539//1204
+f 1535//1182 1550//1202 1551//1205
+f 1530//1183 1545//1203 1546//1206
+f 1541//1209 1526//1189 1540//1207
+f 1531//1186 1546//1206 1547//1208
+f 1542//1197 1527//1192 1541//1209
+f 1532//1188 1547//1208 1548//1210
+f 1546//1206 1561//1224 1562//1211
+f 1541//1209 1556//1228 1557//1212
+f 1547//1208 1562//1211 1563//1213
+f 1542//1197 1557//1212 1558//1215
+f 1553//1219 1538//1201 1552//1216
+f 1548//1210 1563//1213 1564//1217
+f 1543//1214 1558//1215 1559//1218
+f 1554//1222 1539//1204 1553//1219
+f 1549//1199 1564//1217 1565//1220
+f 1544//1200 1559//1218 1560//1221
+f 1555//1225 1540//1207 1554//1222
+f 1550//1202 1565//1220 1566//1223
+f 1545//1203 1560//1221 1561//1224
+f 1556//1228 1541//1209 1555//1225
+f 1581//1243 1566//1223 1580//1226
+f 1576//1230 1561//1224 1575//1227
+f 1555//1225 1570//1239 1571//1229
+f 1577//1232 1562//1211 1576//1230
+f 1556//1228 1571//1229 1572//1231
+f 1578//1235 1563//1213 1577//1232
+f 1557//1212 1572//1231 1573//1233
+f 1552//1216 1567//1251 1568//1234
+f 1579//1238 1564//1217 1578//1235
+f 1558//1215 1573//1233 1574//1236
+f 1553//1219 1568//1234 1569//1237
+f 1580//1226 1565//1220 1579//1238
+f 1559//1218 1574//1236 1575//1227
+f 1554//1222 1569//1237 1570//1239
+f 1595//1244 1580//1226 1594//1240
+f 1590//1245 1575//1227 1589//1241
+f 1569//1237 1584//1254 1585//1242
+f 1596//1262 1581//1243 1595//1244
+f 1591//1247 1576//1230 1590//1245
+f 1570//1239 1585//1242 1586//1246
+f 1592//1249 1577//1232 1591//1247
+f 1571//1229 1586//1246 1587//1248
+f 1593//1253 1578//1235 1592//1249
+f 1572//1231 1587//1248 1588//1250
+f 1567//1251 1582//1255 1583//1252
+f 1594//1240 1579//1238 1593//1253
+f 1573//1233 1588//1250 1589//1241
+f 1568//1234 1583//1252 1584//1254
+f 1582//1255 1597//1273 1598//1256
+f 1609//1260 1594//1240 1608//1257
+f 1588//1250 1603//1269 1604//1258
+f 1583//1252 1598//1256 1599//1259
+f 1610//1263 1595//1244 1609//1260
+f 1605//1264 1590//1245 1604//1258
+f 1584//1254 1599//1259 1600//1261
+f 1611//1280 1596//1262 1610//1263
+f 1606//1266 1591//1247 1605//1264
+f 1585//1242 1600//1261 1601//1265
+f 1607//1268 1592//1249 1606//1266
+f 1586//1246 1601//1265 1602//1267
+f 1608//1257 1593//1253 1607//1268
+f 1587//1248 1602//1267 1603//1269
+f 1601//1265 1616//1283 1617//1270
+f 1623//1275 1608//1257 1622//1271
+f 1602//1267 1617//1270 1618//1272
+f 1597//1273 1612//1291 1613//1274
+f 1624//1278 1609//1260 1623//1275
+f 1603//1269 1618//1272 1619//1276
+f 1598//1256 1613//1274 1614//1277
+f 1625//1281 1610//1263 1624//1278
+f 1620//1282 1605//1264 1619//1276
+f 1599//1259 1614//1277 1615//1279
+f 1626//1298 1611//1280 1625//1281
+f 1621//1284 1606//1266 1620//1282
+f 1600//1261 1615//1279 1616//1283
+f 1622//1271 1607//1268 1621//1284
+f 1636//1287 1621//1284 1635//1285
+f 1615//1279 1630//1297 1631//1286
+f 1637//1289 1622//1271 1636//1287
+f 1616//1283 1631//1286 1632//1288
+f 1638//1293 1623//1275 1637//1289
+f 1617//1270 1632//1288 1633//1290
+f 1612//1291 1627//1311 1628//1292
+f 1639//1296 1624//1278 1638//1293
+f 1618//1272 1633//1290 1634//1294
+f 1613//1274 1628//1292 1629//1295
+f 1640//1299 1625//1281 1639//1296
+f 1635//1285 1620//1282 1634//1294
+f 1614//1277 1629//1295 1630//1297
+f 1641//1303 1626//1298 1640//1299
+f 1655//1304 1640//1299 1654//1300
+f 1650//1305 1635//1285 1649//1301
+f 1629//1295 1644//1314 1645//1302
+f 1656//1323 1641//1303 1655//1304
+f 1651//1307 1636//1287 1650//1305
+f 1630//1297 1645//1302 1646//1306
+f 1652//1309 1637//1289 1651//1307
+f 1631//1286 1646//1306 1647//1308
+f 1653//1313 1638//1293 1652//1309
+f 1632//1288 1647//1308 1648//1310
+f 1627//1311 1642//1315 1643//1312
+f 1654//1300 1639//1296 1653//1313
+f 1633//1290 1648//1310 1649//1301
+f 1628//1292 1643//1312 1644//1314
+f 1642//1315 1657//1333 1658//1316
+f 1669//1320 1654//1300 1668//1317
+f 1664//1321 1649//1301 1663//1318
+f 1643//1312 1658//1316 1659//1319
+f 1670//1324 1655//1304 1669//1320
+f 1665//1325 1650//1305 1664//1321
+f 1644//1314 1659//1319 1660//1322
+f 1671//1341 1656//1323 1670//1324
+f 1666//1327 1651//1307 1665//1325
+f 1645//1302 1660//1322 1661//1326
+f 1667//1329 1652//1309 1666//1327
+f 1646//1306 1661//1326 1662//1328
+f 1668//1317 1653//1313 1667//1329
+f 1647//1308 1662//1328 1663//1318
+f 1677//1332 1662//1328 1676//1330
+f 1683//1335 1668//1317 1682//1331
+f 1678//1336 1663//1318 1677//1332
+f 1657//1333 1672//1351 1673//1334
+f 1684//1338 1669//1320 1683//1335
+f 1679//1339 1664//1321 1678//1336
+f 1658//1316 1673//1334 1674//1337
+f 1685//1342 1670//1324 1684//1338
+f 1680//1343 1665//1325 1679//1339
+f 1659//1319 1674//1337 1675//1340
+f 1686//1359 1671//1341 1685//1342
+f 1681//1344 1666//1327 1680//1343
+f 1660//1322 1675//1340 1676//1330
+f 1682//1331 1667//1329 1681//1344
+f 1696//1365 1681//1344 1695//1345
+f 1691//1348 1676//1330 1690//1346
+f 1681//1344 1696//1365 1697//1347
+f 1692//1350 1677//1332 1691//1348
+f 1682//1331 1697//1347 1698//1349
+f 1693//1354 1678//1336 1692//1350
+f 1688//1355 1673//1334 1687//1352
+f 1683//1335 1698//1349 1699//1353
+f 1694//1357 1679//1339 1693//1354
+f 1689//1358 1674//1337 1688//1355
+f 1684//1338 1699//1353 1700//1356
+f 1695//1345 1680//1343 1694//1357
+f 1690//1346 1675//1340 1689//1358
+f 1685//1342 1700//1356 1701//1360
+f 1699//1353 1714//1373 1715//1361
+f 1710//1380 1695//1345 1709//1362
+f 1705//1367 1690//1346 1704//1363
+f 1700//1356 1715//1361 1716//1364
+f 1695//1345 1710//1380 1711//1366
+f 1706//1369 1691//1348 1705//1367
+f 1696//1365 1711//1366 1712//1368
+f 1707//1371 1692//1350 1706//1369
+f 1697//1347 1712//1368 1713//1370
+f 1708//1374 1693//1354 1707//1371
+f 1703//1375 1688//1355 1702//1372
+f 1698//1349 1713//1370 1714//1373
+f 1709//1362 1694//1357 1708//1374
+f 1704//1363 1689//1358 1703//1375
+f 1713//1370 1728//1388 1729//1376
+f 1724//1381 1709//1362 1723//1377
+f 1719//1382 1704//1363 1718//1378
+f 1714//1373 1729//1376 1730//1379
+f 1725//1398 1710//1380 1724//1381
+f 1720//1385 1705//1367 1719//1382
+f 1715//1361 1730//1379 1731//1383
+f 1710//1380 1725//1398 1726//1384
+f 1721//1387 1706//1369 1720//1385
+f 1711//1366 1726//1384 1727//1386
+f 1722//1389 1707//1371 1721//1387
+f 1712//1368 1727//1386 1728//1388
+f 1723//1377 1708//1374 1722//1389
+f 1718//1378 1703//1375 1717//1390
+f 1727//1386 1742//1404 1743//1391
+f 1738//1395 1723//1377 1737//1392
+f 1733//1396 1718//1378 1732//1393
+f 1728//1388 1743//1391 1744//1394
+f 1739//1399 1724//1381 1738//1395
+f 1734//1400 1719//1382 1733//1396
+f 1729//1376 1744//1394 1745//1397
+f 1740//1416 1725//1398 1739//1399
+f 1735//1403 1720//1385 1734//1400
+f 1730//1379 1745//1397 1746//1401
+f 1725//1398 1740//1416 1741//1402
+f 1736//1405 1721//1387 1735//1403
+f 1726//1384 1741//1402 1742//1404
+f 1737//1392 1722//1389 1736//1405
+f 1751//1408 1736//1405 1750//1406
+f 1741//1402 1756//1420 1757//1407
+f 1752//1410 1737//1392 1751//1408
+f 1742//1404 1757//1407 1758//1409
+f 1753//1413 1738//1395 1752//1410
+f 1748//1414 1733//1396 1747//1411
+f 1743//1391 1758//1409 1759//1412
+f 1754//1417 1739//1399 1753//1413
+f 1749//1418 1734//1400 1748//1414
+f 1744//1394 1759//1412 1760//1415
+f 1755//1421 1740//1416 1754//1417
+f 1750//1406 1735//1403 1749//1418
+f 1745//1397 1760//1415 1761//1419
+f 1740//1416 1755//1421 1756//1420
+f 1770//1440 1755//1421 1769//1422
+f 1765//1426 1750//1406 1764//1423
+f 1760//1415 1775//1435 1776//1424
+f 1755//1421 1770//1440 1771//1425
+f 1766//1428 1751//1408 1765//1426
+f 1756//1420 1771//1425 1772//1427
+f 1767//1430 1752//1410 1766//1428
+f 1757//1407 1772//1427 1773//1429
+f 1768//1433 1753//1413 1767//1430
+f 1763//1434 1748//1414 1762//1431
+f 1758//1409 1773//1429 1774//1432
+f 1769//1422 1754//1417 1768//1433
+f 1764//1423 1749//1418 1763//1434
+f 1759//1412 1774//1432 1775//1435
+f 1773//1429 1789//1448 1790//1436
+f 1785//1441 1769//1422 1784//1437
+f 1780//1442 1764//1423 1779//1438
+f 1774//1432 1790//1436 1791//1439
+f 1786//1458 1770//1440 1785//1441
+f 1781//1445 1765//1426 1780//1442
+f 1775//1435 1791//1439 1792//1443
+f 1770//1440 1786//1458 1787//1444
+f 1782//1447 1766//1428 1781//1445
+f 1771//1425 1787//1444 1788//1446
+f 1783//1449 1767//1430 1782//1447
+f 1772//1427 1788//1446 1789//1448
+f 1784//1437 1768//1433 1783//1449
+f 1779//1438 1763//1434 1778//1450
+f 1788//1446 1803//1467 1804//1451
+f 1799//1455 1784//1437 1798//1452
+f 1794//1456 1779//1438 1793//1453
+f 1789//1448 1804//1451 1805//1454
+f 1800//1459 1785//1441 1799//1455
+f 1795//1460 1780//1442 1794//1456
+f 1790//1436 1805//1454 1806//1457
+f 1801//1462 1786//1458 1800//1459
+f 1796//1463 1781//1445 1795//1460
+f 1791//1439 1806//1457 1807//1461
+f 1802//1464 1787//1444 1801//1462
+f 1797//1465 1782//1447 1796//1463
+f 1803//1467 1788//1446 1802//1464
+f 1798//1452 1783//1449 1797//1465
+f 1796//1463 1811//1477 1812//1466
+f 1818//1470 1803//1467 1817//1468
+f 1797//1465 1812//1466 1813//1469
+f 1819//1473 1804//1451 1818//1470
+f 1798//1452 1813//1469 1814//1471
+f 1793//1453 1808//1490 1809//1472
+f 1820//1475 1805//1454 1819//1473
+f 1815//1476 1800//1459 1814//1471
+f 1794//1456 1809//1472 1810//1474
+f 1821//1478 1806//1457 1820//1475
+f 1816//1479 1801//1462 1815//1476
+f 1795//1460 1810//1474 1811//1477
+f 1822//1482 1807//1461 1821//1478
+f 1817//1468 1802//1464 1816//1479
+f 1831//1484 1816//1479 1830//1480
+f 1810//1474 1825//1493 1826//1481
+f 1837//1500 1822//1482 1836//1483
+f 1832//1486 1817//1468 1831//1484
+f 1811//1477 1826//1481 1827//1485
+f 1833//1488 1818//1470 1832//1486
+f 1812//1466 1827//1485 1828//1487
+f 1834//1492 1819//1473 1833//1488
+f 1813//1469 1828//1487 1829//1489
+f 1808//1490 1823//1508 1824//1491
+f 1835//1494 1820//1475 1834//1492
+f 1814//1471 1829//1489 1830//1480
+f 1809//1472 1824//1491 1825//1493
+f 1836//1483 1821//1478 1835//1494
+f 1850//1498 1835//1494 1849//1495
+f 1829//1489 1844//1507 1845//1496
+f 1824//1491 1839//1509 1840//1497
+f 1851//1501 1836//1483 1850//1498
+f 1846//1502 1831//1484 1845//1496
+f 1825//1493 1840//1497 1841//1499
+f 1852//1519 1837//1500 1851//1501
+f 1847//1504 1832//1486 1846//1502
+f 1826//1481 1841//1499 1842//1503
+f 1848//1506 1833//1488 1847//1504
+f 1827//1485 1842//1503 1843//1505
+f 1849//1495 1834//1492 1848//1506
+f 1828//1487 1843//1505 1844//1507
+f 1823//1508 1838//1512 1839//1509
+f 1864//1514 1849//1495 1863//1510
+f 1843//1505 1858//1524 1859//1511
+f 1838//1512 1853//1529 1854//1513
+f 1865//1517 1850//1498 1864//1514
+f 1844//1507 1859//1511 1860//1515
+f 1839//1509 1854//1513 1855//1516
+f 1866//1520 1851//1501 1865//1517
+f 1861//1521 1846//1502 1860//1515
+f 1840//1497 1855//1516 1856//1518
+f 1867//1536 1852//1519 1866//1520
+f 1862//1523 1847//1504 1861//1521
+f 1841//1499 1856//1518 1857//1522
+f 1863//1510 1848//1506 1862//1523
+f 1842//1503 1857//1522 1858//1524
+f 1878//1527 1863//1510 1877//1525
+f 1857//1522 1872//1539 1873//1526
+f 1879//1531 1864//1514 1878//1527
+f 1858//1524 1873//1526 1874//1528
+f 1853//1529 1868//1549 1869//1530
+f 1880//1534 1865//1517 1879//1531
+f 1859//1511 1874//1528 1875//1532
+f 1854//1513 1869//1530 1870//1533
+f 1881//1537 1866//1520 1880//1534
+f 1876//1538 1861//1521 1875//1532
+f 1855//1516 1870//1533 1871//1535
+f 1882//1541 1867//1536 1881//1537
+f 1877//1525 1862//1523 1876//1538
+f 1856//1518 1871//1535 1872//1539
+f 1870//1533 1885//1553 1886//1540
+f 1897//1560 1882//1541 1896//1542
+f 1892//1545 1877//1525 1891//1543
+f 1871//1535 1886//1540 1887//1544
+f 1893//1547 1878//1527 1892//1545
+f 1872//1539 1887//1544 1888//1546
+f 1894//1551 1879//1531 1893//1547
+f 1873//1526 1888//1546 1889//1548
+f 1868//1549 1883//1567 1884//1550
+f 1895//1554 1880//1534 1894//1551
+f 1874//1528 1889//1548 1890//1552
+f 1869//1530 1884//1550 1885//1553
+f 1896//1542 1881//1537 1895//1554
+f 1891//1543 1876//1538 1890//1552
+f 1889//1548 1905//1566 1906//1555
+f 1884//1550 1900//1568 1901//1556
+f 1912//1561 1896//1542 1911//1557
+f 1890//1552 1906//1555 1907//1558
+f 1885//1553 1901//1556 1902//1559
+f 1913//1580 1897//1560 1912//1561
+f 1908//1563 1892//1545 1907//1558
+f 1886//1540 1902//1559 1903//1562
+f 1909//1565 1893//1547 1908//1563
+f 1887//1544 1903//1562 1904//1564
+f 1910//1569 1894//1551 1909//1565
+f 1888//1546 1904//1564 1905//1566
+f 1883//1567 1899//1572 1900//1568
+f 1911//1557 1895//1554 1910//1569
+f 1925//1574 1910//1569 1924//1570
+f 1904//1564 1919//1584 1920//1571
+f 1899//1572 1914//1588 1915//1573
+f 1926//1577 1911//1557 1925//1574
+f 1905//1566 1920//1571 1921//1575
+f 1900//1568 1915//1573 1916//1576
+f 1927//1581 1912//1561 1926//1577
+f 1906//1555 1921//1575 1922//1578
+f 1901//1556 1916//1576 1917//1579
+f 1928//1587 1913//1580 1927//1581
+f 1907//1558 1922//1578 1923//1582
+f 1902//1559 1917//1579 1918//1583
+f 1908//1563 1923//1582 1924//1570
+f 1903//1562 1918//1583 1919//1584
+f 1923//1582 1456//1128 1457//1132
+f 1452//1108 1919//1584 1451//1130
+f 1924//1570 1457//1132 1458//1114
+f 1919//1584 1452//1108 1453//1107
+f 1448//1110 1915//1573 1447//1111
+f 1925//1574 1458//1114 1459//1113
+f 1920//1571 1453//1107 1454//1116
+f 1449//1118 1916//1576 1448//1110
+f 1926//1577 1459//1113 1460//1120
+f 1921//1575 1454//1116 1455//1122
+f 1450//1124 1917//1579 1449//1118
+f 1927//1581 1460//1120 1461//1126
+f 1922//1578 1455//1122 1456//1128
+f 1451//1130 1918//1583 1450//1124
+f 1950//1136 1935//1107 1949//1109
+f 1945//1119 1930//1110 1944//1112
+f 1940//1114 1955//1135 1956//1590
+f 1935//1107 1950//1136 1951//1117
+f 1946//1125 1931//1118 1945//1119
+f 1941//1113 1956//1590 1957//1121
+f 1936//1116 1951//1117 1952//1123
+f 1947//1131 1932//1124 1946//1125
+f 1942//1120 1957//1121 1958//1127
+f 1937//1122 1952//1123 1953//1129
+f 1948//1134 1933//1130 1947//1131
+f 1938//1128 1953//1129 1954//1133
+f 1949//1109 1934//1108 1948//1134
+f 1939//1592 1954//1133 1955//1135
+f 1965//1154 1950//1136 1964//1137
+f 1960//1141 1945//1119 1959//1138
+f 1955//1135 1970//1594 1971//1139
+f 1950//1136 1965//1154 1966//1140
+f 1961//1144 1946//1125 1960//1141
+f 1956//1590 1971//1139 1972//1142
+f 1951//1117 1966//1140 1967//1143
+f 1962//1147 1947//1131 1961//1144
+f 1957//1121 1972//1142 1973//1145
+f 1952//1123 1967//1143 1968//1593
+f 1963//1149 1948//1134 1962//1147
+f 1953//1129 1968//1593 1969//1148
+f 1964//1137 1949//1109 1963//1149
+f 1954//1133 1969//1148 1970//1594
+f 1968//1593 1983//1164 1984//1151
+f 1979//1155 1964//1137 1978//1152
+f 1969//1148 1984//1151 1985//1595
+f 1980//1172 1965//1154 1979//1155
+f 1975//1159 1960//1141 1974//1596
+f 1970//1594 1985//1595 1986//1157
+f 1965//1154 1980//1172 1981//1158
+f 1976//1162 1961//1144 1975//1159
+f 1971//1139 1986//1157 1987//1160
+f 1966//1140 1981//1158 1982//1597
+f 1977//1165 1962//1147 1976//1162
+f 1972//1142 1987//1160 1988//1598
+f 1967//1143 1982//1597 1983//1164
+f 1978//1152 1963//1149 1977//1165
+f 1987//1160 2002//1178 2003//1166
+f 1982//1597 1997//1179 1998//1599
+f 1993//1601 1978//1152 1992//1168
+f 1983//1164 1998//1599 1999//1600
+f 1994//1173 1979//1155 1993//1601
+f 1984//1151 1999//1600 2000//1171
+f 1995//1191 1980//1172 1994//1173
+f 1990//1177 1975//1159 1989//1174
+f 1985//1595 2000//1171 2001//1175
+f 1980//1172 1995//1191 1996//1176
+f 1991//1602 1976//1162 1990//1177
+f 1986//1157 2001//1175 2002//1178
+f 1981//1158 1996//1176 1997//1179
+f 1992//1168 1977//1165 1991//1602
+f 2006//1603 1991//1602 2005//1181
+f 2001//1175 2016//1194 2017//1182
+f 1996//1176 2011//1606 2012//1183
+f 2007//1604 1992//1168 2006//1603
+f 2002//1178 2017//1182 2018//1185
+f 1997//1179 2012//1183 2013//1186
+f 2008//1189 1993//1601 2007//1604
+f 1998//1599 2013//1186 2014//1188
+f 2009//1192 1994//1173 2008//1189
+f 1999//1600 2014//1188 2015//1190
+f 2010//1196 1995//1191 2009//1192
+f 2005//1181 1990//1177 2004//1605
+f 2000//1171 2015//1190 2016//1194
+f 1995//1191 2010//1196 2011//1606
+f 2025//1610 2010//1196 2024//1197
+f 2020//1201 2005//1181 2019//1198
+f 2015//1190 2030//1210 2031//1199
+f 2010//1196 2025//1610 2026//1607
+f 2021//1204 2006//1603 2020//1201
+f 2016//1194 2031//1199 2032//1202
+f 2011//1606 2026//1607 2027//1203
+f 2022//1609 2007//1604 2021//1204
+f 2017//1182 2032//1202 2033//1608
+f 2012//1183 2027//1203 2028//1206
+f 2023//1209 2008//1189 2022//1609
+f 2013//1186 2028//1206 2029//1208
+f 2024//1197 2009//1192 2023//1209
+f 2014//1188 2029//1208 2030//1210
+f 2028//1206 2043//1224 2044//1211
+f 2023//1209 2038//1228 2039//1212
+f 2029//1208 2044//1211 2045//1213
+f 2024//1197 2039//1212 2040//1215
+f 2035//1219 2020//1201 2034//1216
+f 2030//1210 2045//1213 2046//1217
+f 2025//1610 2040//1215 2041//1611
+f 2036//1222 2021//1204 2035//1219
+f 2031//1199 2046//1217 2047//1220
+f 2026//1607 2041//1611 2042//1221
+f 2037//1225 2022//1609 2036//1222
+f 2032//1202 2047//1220 2048//1612
+f 2027//1203 2042//1221 2043//1224
+f 2038//1228 2023//1209 2037//1225
+f 2063//1243 2048//1612 2062//1226
+f 2058//1230 2043//1224 2057//1613
+f 2037//1225 2052//1239 2053//1229
+f 2059//1232 2044//1211 2058//1230
+f 2038//1228 2053//1229 2054//1614
+f 2060//1235 2045//1213 2059//1232
+f 2039//1212 2054//1614 2055//1615
+f 2034//1216 2049//1251 2050//1616
+f 2061//1238 2046//1217 2060//1235
+f 2040//1215 2055//1615 2056//1236
+f 2035//1219 2050//1616 2051//1237
+f 2062//1226 2047//1220 2061//1238
+f 2041//1611 2056//1236 2057//1613
+f 2036//1222 2051//1237 2052//1239
+f 2077//1244 2062//1226 2076//1617
+f 2072//1245 2057//1613 2071//1241
+f 2051//1237 2066//1620 2067//1618
+f 2078//1262 2063//1243 2077//1244
+f 2073//1247 2058//1230 2072//1245
+f 2052//1239 2067//1618 2068//1619
+f 2074//1249 2059//1232 2073//1247
+f 2053//1229 2068//1619 2069//1248
+f 2075//1253 2060//1235 2074//1249
+f 2054//1614 2069//1248 2070//1250
+f 2049//1251 2064//1621 2065//1252
+f 2076//1617 2061//1238 2075//1253
+f 2055//1615 2070//1250 2071//1241
+f 2050//1616 2065//1252 2066//1620
+f 2064//1621 2079//1628 2080//1622
+f 2091//1260 2076//1617 2090//1257
+f 2070//1250 2085//1269 2086//1258
+f 2065//1252 2080//1622 2081//1623
+f 2092//1263 2077//1244 2091//1260
+f 2087//1624 2072//1245 2086//1258
+f 2066//1620 2081//1623 2082//1261
+f 2093//1280 2078//1262 2092//1263
+f 2088//1625 2073//1247 2087//1624
+f 2067//1618 2082//1261 2083//1265
+f 2089//1268 2074//1249 2088//1625
+f 2068//1619 2083//1265 2084//1626
+f 2090//1257 2075//1253 2089//1268
+f 2069//1248 2084//1626 2085//1269
+f 2083//1265 2098//1283 2099//1270
+f 2105//1275 2090//1257 2104//1271
+f 2084//1626 2099//1270 2100//1627
+f 2079//1628 2094//1291 2095//1274
+f 2106//1278 2091//1260 2105//1275
+f 2085//1269 2100//1627 2101//1276
+f 2080//1622 2095//1274 2096//1277
+f 2107//1281 2092//1263 2106//1278
+f 2102//1282 2087//1624 2101//1276
+f 2081//1623 2096//1277 2097//1629
+f 2108//1298 2093//1280 2107//1281
+f 2103//1630 2088//1625 2102//1282
+f 2082//1261 2097//1629 2098//1283
+f 2104//1271 2089//1268 2103//1630
+f 2118//1287 2103//1630 2117//1285
+f 2097//1629 2112//1634 2113//1286
+f 2119//1631 2104//1271 2118//1287
+f 2098//1283 2113//1286 2114//1288
+f 2120//1632 2105//1275 2119//1631
+f 2099//1270 2114//1288 2115//1290
+f 2094//1291 2109//1636 2110//1292
+f 2121//1296 2106//1278 2120//1632
+f 2100//1627 2115//1290 2116//1294
+f 2095//1274 2110//1292 2111//1633
+f 2122//1299 2107//1281 2121//1296
+f 2117//1285 2102//1282 2116//1294
+f 2096//1277 2111//1633 2112//1634
+f 2123//1635 2108//1298 2122//1299
+f 2137//1304 2122//1299 2136//1300
+f 2132//1305 2117//1285 2131//1301
+f 2111//1633 2126//1639 2127//1302
+f 2138//1323 2123//1635 2137//1304
+f 2133//1307 2118//1287 2132//1305
+f 2112//1634 2127//1302 2128//1306
+f 2134//1309 2119//1631 2133//1307
+f 2113//1286 2128//1306 2129//1308
+f 2135//1638 2120//1632 2134//1309
+f 2114//1288 2129//1308 2130//1310
+f 2109//1636 2124//1315 2125//1637
+f 2136//1300 2121//1296 2135//1638
+f 2115//1290 2130//1310 2131//1301
+f 2110//1292 2125//1637 2126//1639
+f 2124//1315 2139//1333 2140//1316
+f 2151//1320 2136//1300 2150//1317
+f 2146//1321 2131//1301 2145//1640
+f 2125//1637 2140//1316 2141//1319
+f 2152//1641 2137//1304 2151//1320
+f 2147//1642 2132//1305 2146//1321
+f 2126//1639 2141//1319 2142//1322
+f 2153//1646 2138//1323 2152//1641
+f 2148//1643 2133//1307 2147//1642
+f 2127//1302 2142//1322 2143//1326
+f 2149//1329 2134//1309 2148//1643
+f 2128//1306 2143//1326 2144//1328
+f 2150//1317 2135//1638 2149//1329
+f 2129//1308 2144//1328 2145//1640
+f 2159//1332 2144//1328 2158//1330
+f 2165//1644 2150//1317 2164//1331
+f 2160//1645 2145//1640 2159//1332
+f 2139//1333 2154//1649 2155//1334
+f 2166//1338 2151//1320 2165//1644
+f 2161//1339 2146//1321 2160//1645
+f 2140//1316 2155//1334 2156//1337
+f 2167//1342 2152//1641 2166//1338
+f 2162//1647 2147//1642 2161//1339
+f 2141//1319 2156//1337 2157//1340
+f 2168//1359 2153//1646 2167//1342
+f 2163//1344 2148//1643 2162//1647
+f 2142//1322 2157//1340 2158//1330
+f 2164//1331 2149//1329 2163//1344
+f 2178//1365 2163//1344 2177//1345
+f 2173//1348 2158//1330 2172//1346
+f 2163//1344 2178//1365 2179//1648
+f 2174//1350 2159//1332 2173//1348
+f 2164//1331 2179//1648 2180//1349
+f 2175//1354 2160//1645 2174//1350
+f 2170//1651 2155//1334 2169//1352
+f 2165//1644 2180//1349 2181//1650
+f 2176//1357 2161//1339 2175//1354
+f 2171//1358 2156//1337 2170//1651
+f 2166//1338 2181//1650 2182//1356
+f 2177//1345 2162//1647 2176//1357
+f 2172//1346 2157//1340 2171//1358
+f 2167//1342 2182//1356 2183//1360
+f 2181//1650 2196//1373 2197//1652
+f 2192//1380 2177//1345 2191//1653
+f 2187//1367 2172//1346 2186//1654
+f 2182//1356 2197//1652 2198//1364
+f 2177//1345 2192//1380 2193//1366
+f 2188//1655 2173//1348 2187//1367
+f 2178//1365 2193//1366 2194//1368
+f 2189//1371 2174//1350 2188//1655
+f 2179//1648 2194//1368 2195//1370
+f 2190//1374 2175//1354 2189//1371
+f 2185//1375 2170//1651 2184//1656
+f 2180//1349 2195//1370 2196//1373
+f 2191//1653 2176//1357 2190//1374
+f 2186//1654 2171//1358 2185//1375
+f 2195//1370 2210//1388 2211//1376
+f 2206//1381 2191//1653 2205//1377
+f 2201//1382 2186//1654 2200//1378
+f 2196//1373 2211//1376 2212//1379
+f 2207//1398 2192//1380 2206//1381
+f 2202//1385 2187//1367 2201//1382
+f 2197//1652 2212//1379 2213//1383
+f 2192//1380 2207//1398 2208//1384
+f 2203//1387 2188//1655 2202//1385
+f 2193//1366 2208//1384 2209//1386
+f 2204//1389 2189//1371 2203//1387
+f 2194//1368 2209//1386 2210//1388
+f 2205//1377 2190//1374 2204//1389
+f 2200//1378 2185//1375 2199//1390
+f 2209//1386 2224//1404 2225//1391
+f 2220//1658 2205//1377 2219//1392
+f 2215//1396 2200//1378 2214//1393
+f 2210//1388 2225//1391 2226//1657
+f 2221//1659 2206//1381 2220//1658
+f 2216//1400 2201//1382 2215//1396
+f 2211//1376 2226//1657 2227//1397
+f 2222//1668 2207//1398 2221//1659
+f 2217//1661 2202//1385 2216//1400
+f 2212//1379 2227//1397 2228//1401
+f 2207//1398 2222//1668 2223//1660
+f 2218//1405 2203//1387 2217//1661
+f 2208//1384 2223//1660 2224//1404
+f 2219//1392 2204//1389 2218//1405
+f 2233//1664 2218//1405 2232//1662
+f 2223//1660 2238//1420 2239//1663
+f 2234//1665 2219//1392 2233//1664
+f 2224//1404 2239//1663 2240//1409
+f 2235//1413 2220//1658 2234//1665
+f 2230//1414 2215//1396 2229//1411
+f 2225//1391 2240//1409 2241//1666
+f 2236//1417 2221//1659 2235//1413
+f 2231//1669 2216//1400 2230//1414
+f 2226//1657 2241//1666 2242//1667
+f 2237//1421 2222//1668 2236//1417
+f 2232//1662 2217//1661 2231//1669
+f 2227//1397 2242//1667 2243//1419
+f 2222//1668 2237//1421 2238//1420
+f 2252//1440 2237//1421 2251//1670
+f 2247//1671 2232//1662 2246//1423
+f 2242//1667 2257//1435 2258//1424
+f 2237//1421 2252//1440 2253//1425
+f 2248//1428 2233//1664 2247//1671
+f 2238//1420 2253//1425 2254//1427
+f 2249//1430 2234//1665 2248//1428
+f 2239//1663 2254//1427 2255//1429
+f 2250//1433 2235//1413 2249//1430
+f 2245//1434 2230//1414 2244//1431
+f 2240//1409 2255//1429 2256//1672
+f 2251//1670 2236//1417 2250//1433
+f 2246//1423 2231//1669 2245//1434
+f 2241//1666 2256//1672 2257//1435
+f 2255//1429 2271//1675 2272//1436
+f 2267//1674 2251//1670 2266//1437
+f 2262//1442 2246//1423 2261//1438
+f 2256//1672 2272//1436 2273//1673
+f 2268//1678 2252//1440 2267//1674
+f 2263//1445 2247//1671 2262//1442
+f 2257//1435 2273//1673 2274//1443
+f 2252//1440 2268//1678 2269//1444
+f 2264//1447 2248//1428 2263//1445
+f 2253//1425 2269//1444 2270//1446
+f 2265//1449 2249//1430 2264//1447
+f 2254//1427 2270//1446 2271//1675
+f 2266//1437 2250//1433 2265//1449
+f 2261//1438 2245//1434 2260//1450
+f 2270//1446 2285//1684 2286//1451
+f 2281//1455 2266//1437 2280//1452
+f 2276//1456 2261//1438 2275//1676
+f 2271//1675 2286//1451 2287//1677
+f 2282//1679 2267//1674 2281//1455
+f 2277//1680 2262//1442 2276//1456
+f 2272//1436 2287//1677 2288//1457
+f 2283//1682 2268//1678 2282//1679
+f 2278//1463 2263//1445 2277//1680
+f 2273//1673 2288//1457 2289//1681
+f 2284//1464 2269//1444 2283//1682
+f 2279//1683 2264//1447 2278//1463
+f 2285//1684 2270//1446 2284//1464
+f 2280//1452 2265//1449 2279//1683
+f 2278//1463 2293//1477 2294//1466
+f 2300//1470 2285//1684 2299//1685
+f 2279//1683 2294//1466 2295//1469
+f 2301//1473 2286//1451 2300//1470
+f 2280//1452 2295//1469 2296//1471
+f 2275//1676 2290//1490 2291//1472
+f 2302//1475 2287//1677 2301//1473
+f 2297//1476 2282//1679 2296//1471
+f 2276//1456 2291//1472 2292//1686
+f 2303//1687 2288//1457 2302//1475
+f 2298//1688 2283//1682 2297//1476
+f 2277//1680 2292//1686 2293//1477
+f 2304//1482 2289//1681 2303//1687
+f 2299//1685 2284//1464 2298//1688
+f 2313//1484 2298//1688 2312//1480
+f 2292//1686 2307//1493 2308//1481
+f 2319//1692 2304//1482 2318//1483
+f 2314//1486 2299//1685 2313//1484
+f 2293//1477 2308//1481 2309//1485
+f 2315//1689 2300//1470 2314//1486
+f 2294//1466 2309//1485 2310//1487
+f 2316//1690 2301//1473 2315//1689
+f 2295//1469 2310//1487 2311//1489
+f 2290//1490 2305//1508 2306//1491
+f 2317//1691 2302//1475 2316//1690
+f 2296//1471 2311//1489 2312//1480
+f 2291//1472 2306//1491 2307//1493
+f 2318//1483 2303//1687 2317//1691
+f 2332//1498 2317//1691 2331//1495
+f 2311//1489 2326//1507 2327//1496
+f 2306//1491 2321//1694 2322//1497
+f 2333//1693 2318//1483 2332//1498
+f 2328//1502 2313//1484 2327//1496
+f 2307//1493 2322//1497 2323//1499
+f 2334//1697 2319//1692 2333//1693
+f 2329//1504 2314//1486 2328//1502
+f 2308//1481 2323//1499 2324//1503
+f 2330//1506 2315//1689 2329//1504
+f 2309//1485 2324//1503 2325//1505
+f 2331//1495 2316//1690 2330//1506
+f 2310//1487 2325//1505 2326//1507
+f 2305//1508 2320//1695 2321//1694
+f 2346//1514 2331//1495 2345//1510
+f 2325//1505 2340//1524 2341//1511
+f 2320//1695 2335//1529 2336//1513
+f 2347//1517 2332//1498 2346//1514
+f 2326//1507 2341//1511 2342//1515
+f 2321//1694 2336//1513 2337//1696
+f 2348//1520 2333//1693 2347//1517
+f 2343//1521 2328//1502 2342//1515
+f 2322//1497 2337//1696 2338//1518
+f 2349//1536 2334//1697 2348//1520
+f 2344//1523 2329//1504 2343//1521
+f 2323//1499 2338//1518 2339//1522
+f 2345//1510 2330//1506 2344//1523
+f 2324//1503 2339//1522 2340//1524
+f 2360//1527 2345//1510 2359//1525
+f 2339//1522 2354//1702 2355//1526
+f 2361//1531 2346//1514 2360//1527
+f 2340//1524 2355//1526 2356//1528
+f 2335//1529 2350//1549 2351//1698
+f 2362//1534 2347//1517 2361//1531
+f 2341//1511 2356//1528 2357//1532
+f 2336//1513 2351//1698 2352//1533
+f 2363//1700 2348//1520 2362//1534
+f 2358//1701 2343//1521 2357//1532
+f 2337//1696 2352//1533 2353//1699
+f 2364//1541 2349//1536 2363//1700
+f 2359//1525 2344//1523 2358//1701
+f 2338//1518 2353//1699 2354//1702
+f 2352//1533 2367//1704 2368//1540
+f 2379//1560 2364//1541 2378//1703
+f 2374//1545 2359//1525 2373//1543
+f 2353//1699 2368//1540 2369//1544
+f 2375//1547 2360//1527 2374//1545
+f 2354//1702 2369//1544 2370//1546
+f 2376//1551 2361//1531 2375//1547
+f 2355//1526 2370//1546 2371//1548
+f 2350//1549 2365//1567 2366//1550
+f 2377//1705 2362//1534 2376//1551
+f 2356//1528 2371//1548 2372//1552
+f 2351//1698 2366//1550 2367//1704
+f 2378//1703 2363//1700 2377//1705
+f 2373//1543 2358//1701 2372//1552
+f 2371//1548 2387//1566 2388//1706
+f 2366//1550 2382//1707 2383//1556
+f 2394//1561 2378//1703 2393//1557
+f 2372//1552 2388//1706 2389//1558
+f 2367//1704 2383//1556 2384//1559
+f 2395//1710 2379//1560 2394//1561
+f 2390//1563 2374//1545 2389//1558
+f 2368//1540 2384//1559 2385//1562
+f 2391//1565 2375//1547 2390//1563
+f 2369//1544 2385//1562 2386//1564
+f 2392//1708 2376//1551 2391//1565
+f 2370//1546 2386//1564 2387//1566
+f 2365//1567 2381//1572 2382//1707
+f 2393//1557 2377//1705 2392//1708
+f 2407//1574 2392//1708 2406//1570
+f 2386//1564 2401//1584 2402//1571
+f 2381//1572 2396//1588 2397//1573
+f 2408//1577 2393//1557 2407//1574
+f 2387//1566 2402//1571 2403//1709
+f 2382//1707 2397//1573 2398//1576
+f 2409//1581 2394//1561 2408//1577
+f 2388//1706 2403//1709 2404//1578
+f 2383//1556 2398//1576 2399//1579
+f 2410//1587 2395//1710 2409//1581
+f 2389//1558 2404//1578 2405//1582
+f 2384//1559 2399//1579 2400//1583
+f 2390//1563 2405//1582 2406//1570
+f 2385//1562 2400//1583 2401//1584
+f 2405//1582 1938//1128 1939//1592
+f 1934//1108 2401//1584 1933//1130
+f 2406//1570 1939//1592 1940//1114
+f 2401//1584 1934//1108 1935//1107
+f 1930//1110 2397//1573 1929//1589
+f 2407//1574 1940//1114 1941//1113
+f 2402//1571 1935//1107 1936//1116
+f 1931//1118 2398//1576 1930//1110
+f 2408//1577 1941//1113 1942//1120
+f 2403//1709 1936//1116 1937//1122
+f 1932//1124 2399//1579 1931//1118
+f 2409//1581 1942//1120 1943//1591
+f 2404//1578 1937//1122 1938//1128
+f 1933//1130 2400//1583 1932//1124
+o Hnad_L_Sphere.012
+v 0.398410 0.221774 0.909033
+v 0.378940 0.206049 0.909266
+v 0.360366 0.192203 0.911041
+v 0.343400 0.180768 0.914290
+v 0.328695 0.172185 0.918888
+v 0.316816 0.166782 0.924658
+v 0.308220 0.164768 0.931379
+v 0.303236 0.166220 0.938792
+v 0.302057 0.171081 0.946613
+v 0.304727 0.179166 0.954540
+v 0.311144 0.190164 0.962270
+v 0.321062 0.203651 0.969505
+v 0.334099 0.219110 0.975966
+v 0.349754 0.235947 0.981407
+v 0.367426 0.253514 0.985617
+v 0.400727 0.220453 0.910024
+v 0.383486 0.203457 0.911210
+v 0.366965 0.188440 0.913864
+v 0.351800 0.175979 0.917884
+v 0.338572 0.166554 0.923114
+v 0.327791 0.160525 0.929354
+v 0.319871 0.158126 0.936364
+v 0.315115 0.159447 0.943874
+v 0.313708 0.164439 0.951597
+v 0.315702 0.172909 0.959235
+v 0.321021 0.184533 0.966495
+v 0.329462 0.198862 0.973098
+v 0.340698 0.215347 0.978790
+v 0.354300 0.233355 0.983352
+v 0.369743 0.252192 0.986609
+v 0.403698 0.219848 0.911057
+v 0.389313 0.202270 0.913236
+v 0.375425 0.186717 0.916806
+v 0.362567 0.173786 0.921627
+v 0.351233 0.163974 0.927515
+v 0.341859 0.157659 0.934245
+v 0.334805 0.155083 0.941556
+v 0.330342 0.156345 0.949168
+v 0.328642 0.161396 0.956790
+v 0.329770 0.170043 0.964126
+v 0.333682 0.181953 0.970897
+v 0.340229 0.196669 0.976842
+v 0.349158 0.213624 0.981731
+v 0.360127 0.232168 0.985378
+v 0.372714 0.251587 0.987642
+v 0.407207 0.219982 0.912091
+v 0.396197 0.202533 0.915266
+v 0.385419 0.187098 0.919752
+v 0.375287 0.174272 0.925376
+v 0.366191 0.164546 0.931924
+v 0.358479 0.158294 0.939144
+v 0.352449 0.155757 0.946757
+v 0.348332 0.157032 0.954471
+v 0.346286 0.162070 0.961990
+v 0.346390 0.170678 0.969025
+v 0.348640 0.182524 0.975306
+v 0.352949 0.197154 0.980591
+v 0.359152 0.214006 0.984677
+v 0.367011 0.232431 0.987407
+v 0.376223 0.251721 0.988676
+v 0.411121 0.220850 0.913088
+v 0.403874 0.204236 0.917220
+v 0.396564 0.189571 0.922589
+v 0.389472 0.177418 0.928988
+v 0.382871 0.168246 0.936171
+v 0.377013 0.162405 0.943862
+v 0.372124 0.160122 0.951766
+v 0.368392 0.161482 0.959579
+v 0.365961 0.166435 0.967000
+v 0.364923 0.174790 0.973744
+v 0.365320 0.186225 0.979553
+v 0.367134 0.200301 0.984203
+v 0.370298 0.216478 0.987515
+v 0.374688 0.234134 0.989362
+v 0.380137 0.252589 0.989673
+v 0.415288 0.222419 0.914008
+v 0.412049 0.207314 0.919025
+v 0.408432 0.194039 0.925209
+v 0.404577 0.183105 0.932323
+v 0.400632 0.174933 0.940092
+v 0.396748 0.169836 0.948219
+v 0.393075 0.168010 0.956392
+v 0.389753 0.169525 0.964295
+v 0.386912 0.174323 0.971625
+v 0.384659 0.182220 0.978101
+v 0.383081 0.192912 0.983474
+v 0.382239 0.205988 0.987537
+v 0.382165 0.220946 0.990135
+v 0.382863 0.237211 0.991166
+v 0.384304 0.254158 0.990593
+v 0.419549 0.224628 0.914816
+v 0.420407 0.211648 0.920611
+v 0.420566 0.200331 0.927511
+v 0.420021 0.191114 0.935253
+v 0.418792 0.184350 0.943538
+v 0.416926 0.180299 0.952047
+v 0.414496 0.179117 0.960455
+v 0.411594 0.180850 0.968438
+v 0.408333 0.185431 0.975689
+v 0.404837 0.192683 0.981929
+v 0.401241 0.202329 0.986919
+v 0.397682 0.213997 0.990467
+v 0.394299 0.227238 0.992437
+v 0.391221 0.241545 0.992752
+v 0.388565 0.256368 0.991401
+v 0.423740 0.227394 0.915482
+v 0.428627 0.217072 0.921916
+v 0.432500 0.208205 0.929407
+v 0.435210 0.201136 0.937665
+v 0.436652 0.196134 0.946374
+v 0.436772 0.193394 0.955199
+v 0.435564 0.193018 0.963801
+v 0.433075 0.195024 0.971850
+v 0.429401 0.199332 0.979035
+v 0.424682 0.205778 0.985081
+v 0.419101 0.214113 0.989756
+v 0.412872 0.224019 0.992880
+v 0.406233 0.235113 0.994332
+v 0.399441 0.246969 0.994058
+v 0.392756 0.259133 0.992067
+v 0.427699 0.230608 0.915979
+v 0.436394 0.223377 0.922891
+v 0.443776 0.217359 0.930822
+v 0.449561 0.212786 0.939467
+v 0.453527 0.209834 0.948493
+v 0.455522 0.208616 0.957554
+v 0.455469 0.209178 0.966301
+v 0.453370 0.211500 0.974398
+v 0.449306 0.215492 0.981535
+v 0.443433 0.221000 0.987436
+v 0.435976 0.227813 0.991875
+v 0.427223 0.235669 0.994682
+v 0.417509 0.244267 0.995748
+v 0.407208 0.253275 0.995033
+v 0.396715 0.262347 0.992564
+v 0.431275 0.234148 0.916289
+v 0.443409 0.230321 0.923499
+v 0.453959 0.227441 0.931704
+v 0.462522 0.225618 0.940590
+v 0.468768 0.224922 0.949813
+v 0.472457 0.225381 0.959021
+v 0.473447 0.226976 0.967858
+v 0.471701 0.229647 0.975986
+v 0.467284 0.233289 0.983092
+v 0.460368 0.237765 0.988903
+v 0.451217 0.242901 0.993195
+v 0.440184 0.248501 0.995804
+v 0.427693 0.254348 0.996630
+v 0.414222 0.260219 0.995640
+v 0.400291 0.265888 0.992873
+v 0.434331 0.237878 0.916399
+v 0.449402 0.237638 0.923715
+v 0.462660 0.238063 0.932019
+v 0.473596 0.239137 0.940990
+v 0.481790 0.240819 0.950284
+v 0.486926 0.243045 0.959543
+v 0.488807 0.245728 0.968413
+v 0.487361 0.248766 0.976551
+v 0.482644 0.252041 0.983646
+v 0.474836 0.255429 0.989425
+v 0.464239 0.258798 0.993665
+v 0.451258 0.262020 0.996204
+v 0.436393 0.264970 0.996944
+v 0.420215 0.267536 0.995857
+v 0.403347 0.269618 0.992984
+v 0.436748 0.241655 0.916306
+v 0.454143 0.245045 0.923533
+v 0.469543 0.248817 0.931753
+v 0.482356 0.252825 0.940652
+v 0.492091 0.256914 0.949886
+v 0.498372 0.260928 0.959102
+v 0.500958 0.264713 0.967944
+v 0.499750 0.268122 0.976073
+v 0.494795 0.271026 0.983178
+v 0.486282 0.273312 0.988983
+v 0.474540 0.274893 0.993268
+v 0.460018 0.275707 0.995866
+v 0.443276 0.275724 0.996679
+v 0.424956 0.274943 0.995674
+v 0.405764 0.273394 0.992891
+v 0.438433 0.245332 0.916012
+v 0.457450 0.252259 0.922957
+v 0.474344 0.259290 0.930918
+v 0.488467 0.266154 0.939589
+v 0.499276 0.272588 0.948636
+v 0.506355 0.278344 0.957713
+v 0.509433 0.283202 0.966470
+v 0.508391 0.286973 0.974570
+v 0.503270 0.289515 0.981703
+v 0.494266 0.290728 0.987595
+v 0.481725 0.290567 0.992018
+v 0.466128 0.289037 0.994803
+v 0.448077 0.286197 0.995843
+v 0.428263 0.282157 0.995099
+v 0.407449 0.277072 0.992597
+v 0.439323 0.248770 0.915530
+v 0.459195 0.259002 0.922012
+v 0.476878 0.269079 0.929545
+v 0.491692 0.278614 0.937841
+v 0.503068 0.287239 0.946582
+v 0.510569 0.294623 0.955430
+v 0.513907 0.300483 0.964046
+v 0.512953 0.304594 0.972099
+v 0.507744 0.306797 0.979280
+v 0.498480 0.307007 0.985312
+v 0.485517 0.305218 0.989963
+v 0.469354 0.301497 0.993056
+v 0.450611 0.295987 0.994471
+v 0.430009 0.288900 0.994153
+v 0.408339 0.280509 0.992115
+v 0.439383 0.251835 0.914878
+v 0.459313 0.265015 0.920732
+v 0.477048 0.277809 0.927688
+v 0.491909 0.289724 0.935477
+v 0.503323 0.300304 0.943802
+v 0.510853 0.309140 0.952341
+v 0.514208 0.315894 0.960767
+v 0.513260 0.320307 0.968756
+v 0.508045 0.322208 0.976001
+v 0.498763 0.321524 0.982223
+v 0.485772 0.318283 0.987183
+v 0.469571 0.312607 0.990692
+v 0.450782 0.304716 0.992613
+v 0.430126 0.294913 0.992874
+v 0.408399 0.283575 0.991463
+v 0.438611 0.254411 0.914081
+v 0.457797 0.270067 0.919168
+v 0.474848 0.285143 0.925417
+v 0.489109 0.299059 0.932587
+v 0.500031 0.311280 0.940403
+v 0.507194 0.321337 0.948565
+v 0.510324 0.328842 0.956758
+v 0.509300 0.333508 0.964668
+v 0.504161 0.335156 0.971992
+v 0.495105 0.333721 0.978446
+v 0.482480 0.329259 0.983785
+v 0.466771 0.321942 0.987802
+v 0.448581 0.312051 0.990342
+v 0.428611 0.299965 0.991309
+v 0.407627 0.286150 0.990665
+v 0.437035 0.256397 0.913169
+v 0.454707 0.273964 0.917379
+v 0.470362 0.290801 0.922820
+v 0.483399 0.306260 0.929282
+v 0.493317 0.319747 0.936516
+v 0.499734 0.330744 0.944246
+v 0.502404 0.338829 0.952173
+v 0.501225 0.343691 0.959994
+v 0.496241 0.345143 0.967407
+v 0.487645 0.343129 0.974128
+v 0.475766 0.337726 0.979898
+v 0.461061 0.329142 0.984496
+v 0.444095 0.317708 0.987745
+v 0.425521 0.303862 0.989520
+v 0.406051 0.288137 0.989754
+v 0.434718 0.257719 0.912177
+v 0.450161 0.276556 0.915434
+v 0.463763 0.294563 0.919996
+v 0.474999 0.311049 0.925688
+v 0.483440 0.325378 0.932291
+v 0.488759 0.337002 0.939551
+v 0.490753 0.345472 0.947189
+v 0.489346 0.350464 0.954912
+v 0.484590 0.351785 0.962422
+v 0.476670 0.349386 0.969433
+v 0.465889 0.343357 0.975673
+v 0.452661 0.333931 0.980903
+v 0.437496 0.321471 0.984922
+v 0.420975 0.306454 0.987576
+v 0.403734 0.289458 0.988762
+v 0.431747 0.258324 0.911144
+v 0.444334 0.277743 0.913408
+v 0.455303 0.296287 0.917055
+v 0.464232 0.313242 0.921945
+v 0.470779 0.327958 0.927889
+v 0.474691 0.339868 0.934660
+v 0.475819 0.348515 0.941997
+v 0.474119 0.353566 0.949618
+v 0.469656 0.354828 0.957230
+v 0.462602 0.352252 0.964542
+v 0.453228 0.345937 0.971271
+v 0.441894 0.336125 0.977159
+v 0.429036 0.323194 0.981981
+v 0.415148 0.307641 0.985550
+v 0.400763 0.290063 0.987729
+v 0.428238 0.258190 0.910110
+v 0.437450 0.277480 0.911379
+v 0.445309 0.295905 0.914109
+v 0.451512 0.312756 0.918195
+v 0.455821 0.327386 0.923480
+v 0.458071 0.339233 0.929761
+v 0.458175 0.347841 0.936796
+v 0.456129 0.352879 0.944315
+v 0.452012 0.354154 0.952029
+v 0.445982 0.351617 0.959643
+v 0.438270 0.345365 0.966862
+v 0.429174 0.335639 0.973410
+v 0.419042 0.322812 0.979035
+v 0.408264 0.307378 0.983520
+v 0.397254 0.289929 0.986695
+v 0.424324 0.257321 0.909114
+v 0.429773 0.275777 0.909425
+v 0.434163 0.293433 0.911272
+v 0.437327 0.309610 0.914584
+v 0.439141 0.323686 0.919233
+v 0.439537 0.335121 0.925042
+v 0.438500 0.343476 0.931786
+v 0.436069 0.348429 0.939208
+v 0.432337 0.349789 0.947020
+v 0.427448 0.347505 0.954924
+v 0.421590 0.341665 0.962615
+v 0.414989 0.332492 0.969798
+v 0.407896 0.320340 0.976197
+v 0.400587 0.305675 0.981566
+v 0.393340 0.289061 0.985698
+v 0.420157 0.255752 0.908194
+v 0.421598 0.272699 0.907620
+v 0.422296 0.288964 0.908651
+v 0.422222 0.303923 0.911249
+v 0.421380 0.316999 0.915312
+v 0.419802 0.327691 0.920685
+v 0.417549 0.335588 0.927161
+v 0.414707 0.340386 0.934491
+v 0.411386 0.341901 0.942395
+v 0.407713 0.340075 0.950567
+v 0.403829 0.334978 0.958694
+v 0.399884 0.326805 0.966463
+v 0.396029 0.315872 0.973577
+v 0.392412 0.302597 0.979761
+v 0.389173 0.287492 0.984778
+v 0.386435 0.271136 0.988436
+v 0.415896 0.253543 0.907385
+v 0.413240 0.268365 0.906034
+v 0.410162 0.282672 0.906349
+v 0.406778 0.295914 0.908319
+v 0.403220 0.307582 0.911867
+v 0.399624 0.317228 0.916857
+v 0.396128 0.324480 0.923097
+v 0.392867 0.329061 0.930348
+v 0.389965 0.330793 0.938331
+v 0.387535 0.329612 0.946739
+v 0.385669 0.325561 0.955249
+v 0.384440 0.318797 0.963533
+v 0.383895 0.309580 0.971275
+v 0.384054 0.298263 0.978176
+v 0.384912 0.285282 0.983970
+v 0.411705 0.250778 0.906720
+v 0.405020 0.262941 0.904729
+v 0.398228 0.274798 0.904454
+v 0.391589 0.285892 0.905907
+v 0.385360 0.295797 0.909030
+v 0.379779 0.304133 0.913705
+v 0.375060 0.310579 0.919751
+v 0.371386 0.314887 0.926937
+v 0.368897 0.316892 0.934985
+v 0.367689 0.316517 0.943587
+v 0.367809 0.313776 0.952412
+v 0.369251 0.308775 0.961121
+v 0.371961 0.301705 0.969380
+v 0.375834 0.292839 0.976870
+v 0.380721 0.282517 0.983304
+v 0.407746 0.247563 0.906222
+v 0.397253 0.256636 0.903753
+v 0.386952 0.265644 0.903038
+v 0.377238 0.274242 0.904104
+v 0.368485 0.282098 0.906911
+v 0.361028 0.288911 0.911350
+v 0.355155 0.294419 0.917252
+v 0.351091 0.298411 0.924388
+v 0.348992 0.300732 0.932485
+v 0.348939 0.301295 0.941232
+v 0.350934 0.300077 0.950293
+v 0.354900 0.297124 0.959319
+v 0.360685 0.292552 0.967964
+v 0.368067 0.286534 0.975895
+v 0.376762 0.279303 0.982807
+v 0.404169 0.244023 0.905913
+v 0.390239 0.249692 0.903146
+v 0.376768 0.255563 0.902156
+v 0.364277 0.261410 0.902982
+v 0.353244 0.267010 0.905591
+v 0.344093 0.272146 0.909884
+v 0.337177 0.276621 0.915694
+v 0.332760 0.280264 0.922800
+v 0.331014 0.282935 0.930928
+v 0.332004 0.284530 0.939766
+v 0.335693 0.284988 0.948973
+v 0.341939 0.284293 0.958196
+v 0.350501 0.282470 0.967082
+v 0.361052 0.279590 0.975287
+v 0.373186 0.275763 0.982498
+v 0.401114 0.240293 0.905802
+v 0.384246 0.242375 0.902929
+v 0.368068 0.244941 0.901842
+v 0.353203 0.247891 0.902582
+v 0.340222 0.251113 0.905121
+v 0.329625 0.254482 0.909361
+v 0.321817 0.257870 0.915140
+v 0.317100 0.261145 0.922235
+v 0.315654 0.264183 0.930373
+v 0.317535 0.266866 0.939243
+v 0.322671 0.269092 0.948503
+v 0.330865 0.270774 0.957796
+v 0.341801 0.271848 0.966767
+v 0.355059 0.272273 0.975071
+v 0.370130 0.272033 0.982387
+v 0.398697 0.236517 0.905896
+v 0.379504 0.234968 0.903112
+v 0.361185 0.234187 0.902108
+v 0.344443 0.234203 0.902920
+v 0.329921 0.235018 0.905518
+v 0.318179 0.236599 0.909803
+v 0.309666 0.238885 0.915609
+v 0.304711 0.241788 0.922713
+v 0.303503 0.245198 0.930842
+v 0.306089 0.248983 0.939685
+v 0.312370 0.252997 0.948900
+v 0.322105 0.257086 0.958134
+v 0.334918 0.261094 0.967033
+v 0.350318 0.264866 0.975254
+v 0.367713 0.268256 0.982480
+v 0.397011 0.232839 0.906189
+v 0.376198 0.227754 0.903688
+v 0.356384 0.223713 0.902943
+v 0.338332 0.220874 0.903983
+v 0.322736 0.219344 0.906768
+v 0.310195 0.219183 0.911192
+v 0.301191 0.220396 0.917083
+v 0.296070 0.222937 0.924216
+v 0.295028 0.226709 0.932317
+v 0.298106 0.231567 0.941073
+v 0.305185 0.237323 0.950150
+v 0.315994 0.243757 0.959198
+v 0.330117 0.250621 0.967868
+v 0.347011 0.257652 0.975829
+v 0.366028 0.264579 0.982774
+v 0.396122 0.229402 0.906671
+v 0.374452 0.221011 0.904633
+v 0.353850 0.213924 0.904315
+v 0.335107 0.208414 0.905730
+v 0.318944 0.204693 0.908823
+v 0.305981 0.202903 0.913474
+v 0.296717 0.203114 0.919506
+v 0.291508 0.205317 0.926687
+v 0.290554 0.209427 0.934740
+v 0.293892 0.215287 0.943356
+v 0.301392 0.222672 0.952204
+v 0.312769 0.231297 0.960945
+v 0.327583 0.240831 0.969241
+v 0.345266 0.250908 0.976774
+v 0.365138 0.261141 0.983256
+v 0.418026 0.238775 0.910350
+v 0.396062 0.226336 0.907323
+v 0.374335 0.214998 0.905913
+v 0.353679 0.205194 0.906173
+v 0.334890 0.197304 0.908094
+v 0.318689 0.191628 0.911603
+v 0.305698 0.188387 0.916563
+v 0.296416 0.187703 0.922786
+v 0.291201 0.189604 0.930030
+v 0.290253 0.194016 0.938019
+v 0.293608 0.200771 0.946445
+v 0.301138 0.209607 0.954984
+v 0.312552 0.220186 0.963309
+v 0.327412 0.232102 0.971098
+v 0.345148 0.244895 0.978054
+v 0.365078 0.258076 0.983908
+v 0.396834 0.223761 0.908121
+v 0.375850 0.209946 0.907477
+v 0.355880 0.197860 0.908444
+v 0.337690 0.187969 0.910985
+v 0.321981 0.180652 0.915001
+v 0.309356 0.176190 0.920340
+v 0.300300 0.174755 0.926795
+v 0.295161 0.176403 0.934118
+v 0.294137 0.181069 0.942028
+v 0.297267 0.188574 0.950222
+v 0.304430 0.198631 0.958383
+v 0.315352 0.210852 0.966199
+v 0.329613 0.224767 0.973369
+v 0.346664 0.239843 0.979618
+v 0.365850 0.255500 0.984705
+v 0.345359 0.270175 0.883207
+v 0.325889 0.254450 0.883440
+v 0.307315 0.240604 0.885215
+v 0.290349 0.229170 0.888464
+v 0.275644 0.220586 0.893062
+v 0.263765 0.215183 0.898832
+v 0.255169 0.213169 0.905553
+v 0.250185 0.214621 0.912967
+v 0.249006 0.219483 0.920787
+v 0.251676 0.227568 0.928714
+v 0.258093 0.238565 0.936444
+v 0.268011 0.252052 0.943679
+v 0.281048 0.267511 0.950141
+v 0.296703 0.284348 0.955581
+v 0.314375 0.301915 0.959791
+v 0.347676 0.268854 0.884198
+v 0.330435 0.251858 0.885385
+v 0.313914 0.236841 0.888038
+v 0.298749 0.224381 0.892058
+v 0.285521 0.214955 0.897288
+v 0.274740 0.208926 0.903528
+v 0.266820 0.206527 0.910538
+v 0.262064 0.207848 0.918049
+v 0.260657 0.212840 0.925771
+v 0.262651 0.221310 0.933410
+v 0.267970 0.232934 0.940669
+v 0.276411 0.247263 0.947272
+v 0.287647 0.263749 0.952964
+v 0.301249 0.281756 0.957526
+v 0.316692 0.300593 0.960783
+v 0.350647 0.268249 0.885231
+v 0.336262 0.250671 0.887411
+v 0.322374 0.235118 0.890980
+v 0.309516 0.222187 0.895801
+v 0.298182 0.212375 0.901689
+v 0.288808 0.206060 0.908419
+v 0.281754 0.203484 0.915730
+v 0.277291 0.204746 0.923343
+v 0.275591 0.209797 0.930964
+v 0.276719 0.218444 0.938301
+v 0.280631 0.230354 0.945071
+v 0.287178 0.245070 0.951016
+v 0.296107 0.262025 0.955905
+v 0.307076 0.280569 0.959552
+v 0.319663 0.299988 0.961816
+v 0.354156 0.268383 0.886265
+v 0.343146 0.250934 0.889440
+v 0.332368 0.235499 0.893926
+v 0.322236 0.222673 0.899551
+v 0.313140 0.212947 0.906098
+v 0.305428 0.206695 0.913318
+v 0.299398 0.204158 0.920931
+v 0.295281 0.205433 0.928645
+v 0.293235 0.210471 0.936164
+v 0.293339 0.219079 0.943200
+v 0.295589 0.230926 0.949480
+v 0.299898 0.245556 0.954765
+v 0.306101 0.262407 0.958851
+v 0.313960 0.280832 0.961581
+v 0.323172 0.300122 0.962850
+v 0.358070 0.269251 0.887262
+v 0.350823 0.252637 0.891394
+v 0.343513 0.237972 0.896763
+v 0.336421 0.225820 0.903162
+v 0.329820 0.216647 0.910345
+v 0.323962 0.210807 0.918036
+v 0.319073 0.208523 0.925940
+v 0.315341 0.209883 0.933753
+v 0.312910 0.214836 0.941174
+v 0.311872 0.223191 0.947918
+v 0.312269 0.234626 0.953727
+v 0.314083 0.248702 0.958377
+v 0.317247 0.264879 0.961689
+v 0.321637 0.282535 0.963536
+v 0.327086 0.300991 0.963847
+v 0.362237 0.270820 0.888182
+v 0.358998 0.255715 0.893199
+v 0.355381 0.242440 0.899383
+v 0.351526 0.231507 0.906497
+v 0.347581 0.223334 0.914267
+v 0.343697 0.218237 0.922394
+v 0.340024 0.216411 0.930566
+v 0.336702 0.217926 0.938469
+v 0.333861 0.222724 0.945799
+v 0.331608 0.230621 0.952275
+v 0.330030 0.241313 0.957648
+v 0.329188 0.254389 0.961711
+v 0.329114 0.269347 0.964309
+v 0.329812 0.285613 0.965340
+v 0.331253 0.302560 0.964767
+v 0.366498 0.273030 0.888990
+v 0.367356 0.260049 0.894785
+v 0.367515 0.248732 0.901685
+v 0.366970 0.239515 0.909427
+v 0.365741 0.232751 0.917712
+v 0.363875 0.228700 0.926222
+v 0.361445 0.227519 0.934629
+v 0.358543 0.229251 0.942612
+v 0.355282 0.233832 0.949863
+v 0.351786 0.241084 0.956103
+v 0.348190 0.250730 0.961093
+v 0.344631 0.262398 0.964641
+v 0.341248 0.275640 0.966611
+v 0.338170 0.289947 0.966926
+v 0.335514 0.304769 0.965575
+v 0.370689 0.275795 0.889656
+v 0.375576 0.265473 0.896090
+v 0.379449 0.256607 0.903581
+v 0.382159 0.249537 0.911839
+v 0.383601 0.244536 0.920548
+v 0.383721 0.241795 0.929373
+v 0.382513 0.241420 0.937975
+v 0.380024 0.243425 0.946024
+v 0.376350 0.247733 0.953209
+v 0.371631 0.254179 0.959255
+v 0.366050 0.262515 0.963930
+v 0.359821 0.272420 0.967054
+v 0.353182 0.283514 0.968506
+v 0.346390 0.295371 0.968232
+v 0.339705 0.307534 0.966241
+v 0.374648 0.279009 0.890153
+v 0.383343 0.271778 0.897066
+v 0.390725 0.265760 0.904997
+v 0.396510 0.261188 0.913641
+v 0.400476 0.258235 0.922667
+v 0.402471 0.257017 0.931728
+v 0.402418 0.257580 0.940475
+v 0.400319 0.259901 0.948572
+v 0.396255 0.263893 0.955709
+v 0.390382 0.269401 0.961610
+v 0.382925 0.276214 0.966049
+v 0.374172 0.284070 0.968856
+v 0.364458 0.292668 0.969922
+v 0.354157 0.301676 0.969207
+v 0.343664 0.310749 0.966738
+v 0.378224 0.282549 0.890463
+v 0.390358 0.278722 0.897673
+v 0.400909 0.275842 0.905879
+v 0.409471 0.274019 0.914764
+v 0.415717 0.273324 0.923987
+v 0.419406 0.273782 0.933195
+v 0.420396 0.275377 0.942032
+v 0.418650 0.278048 0.950160
+v 0.414233 0.281691 0.957266
+v 0.407317 0.286166 0.963077
+v 0.398166 0.291302 0.967369
+v 0.387133 0.296902 0.969978
+v 0.374642 0.302749 0.970804
+v 0.361171 0.308620 0.969814
+v 0.347240 0.314289 0.967048
+v 0.381280 0.286279 0.890573
+v 0.396351 0.286039 0.897890
+v 0.409609 0.286464 0.906193
+v 0.420545 0.287538 0.915164
+v 0.428739 0.289220 0.924458
+v 0.433875 0.291446 0.933717
+v 0.435756 0.294129 0.942587
+v 0.434310 0.297167 0.950726
+v 0.429593 0.300442 0.957821
+v 0.421785 0.303830 0.963599
+v 0.411188 0.307199 0.967839
+v 0.398207 0.310421 0.970378
+v 0.383342 0.313371 0.971118
+v 0.367164 0.315937 0.970031
+v 0.350296 0.318019 0.967158
+v 0.383697 0.290056 0.890480
+v 0.401092 0.293446 0.897707
+v 0.416492 0.297218 0.905927
+v 0.429305 0.301226 0.914826
+v 0.439040 0.305315 0.924060
+v 0.445321 0.309329 0.933276
+v 0.447907 0.313114 0.942118
+v 0.446699 0.316524 0.950248
+v 0.441744 0.319427 0.957352
+v 0.433231 0.321713 0.963158
+v 0.421489 0.323294 0.967442
+v 0.406967 0.324109 0.970040
+v 0.390225 0.324125 0.970853
+v 0.371905 0.323344 0.969848
+v 0.352713 0.321795 0.967065
+v 0.385382 0.293733 0.890187
+v 0.404399 0.300660 0.897131
+v 0.421293 0.307691 0.905092
+v 0.435416 0.314555 0.913763
+v 0.446225 0.320989 0.922810
+v 0.453304 0.326745 0.931887
+v 0.456382 0.331603 0.940644
+v 0.455340 0.335375 0.948744
+v 0.450219 0.337916 0.955877
+v 0.441215 0.339129 0.961769
+v 0.428674 0.338968 0.966192
+v 0.413078 0.337438 0.968977
+v 0.395026 0.334599 0.970017
+v 0.375212 0.330558 0.969273
+v 0.354398 0.325473 0.966771
+v 0.386272 0.297171 0.889705
+v 0.406144 0.307403 0.896186
+v 0.423827 0.317481 0.903719
+v 0.438641 0.327015 0.912016
+v 0.450017 0.335640 0.920756
+v 0.457518 0.343025 0.929604
+v 0.460856 0.348885 0.938220
+v 0.459902 0.352995 0.946273
+v 0.454693 0.355198 0.953454
+v 0.445429 0.355409 0.959486
+v 0.432466 0.353619 0.964138
+v 0.416303 0.349898 0.967230
+v 0.397560 0.344388 0.968645
+v 0.376958 0.337301 0.968327
+v 0.355288 0.328910 0.966289
+v 0.386332 0.300236 0.889052
+v 0.406262 0.313417 0.894906
+v 0.423997 0.326210 0.901862
+v 0.438858 0.338126 0.909651
+v 0.450272 0.348705 0.917976
+v 0.457802 0.357541 0.926515
+v 0.461157 0.364296 0.934941
+v 0.460209 0.368708 0.942930
+v 0.454994 0.370609 0.950175
+v 0.445712 0.369925 0.956397
+v 0.432721 0.366684 0.961358
+v 0.416520 0.361008 0.964866
+v 0.397731 0.353118 0.966787
+v 0.377075 0.343314 0.967048
+v 0.355348 0.331976 0.965637
+v 0.385560 0.302812 0.888255
+v 0.404746 0.318469 0.893342
+v 0.421797 0.333545 0.899591
+v 0.436058 0.347460 0.906761
+v 0.446980 0.359681 0.914577
+v 0.454143 0.369738 0.922739
+v 0.457273 0.377243 0.930932
+v 0.456248 0.381909 0.938842
+v 0.451110 0.383557 0.946166
+v 0.442054 0.382122 0.952621
+v 0.429429 0.377660 0.957959
+v 0.413720 0.370343 0.961976
+v 0.395530 0.360452 0.964516
+v 0.375560 0.348366 0.965483
+v 0.354576 0.334551 0.964840
+v 0.383984 0.304798 0.887343
+v 0.401656 0.322365 0.891553
+v 0.417311 0.339202 0.896994
+v 0.430348 0.354661 0.903456
+v 0.440266 0.368148 0.910690
+v 0.446683 0.379146 0.918420
+v 0.449353 0.387230 0.926347
+v 0.448174 0.392092 0.934168
+v 0.443190 0.393544 0.941581
+v 0.434594 0.391530 0.948302
+v 0.422715 0.386127 0.954072
+v 0.408010 0.377544 0.958670
+v 0.391044 0.366109 0.961919
+v 0.372470 0.352263 0.963695
+v 0.353000 0.336538 0.963928
+v 0.381667 0.306120 0.886351
+v 0.397110 0.324957 0.889608
+v 0.410712 0.342964 0.894170
+v 0.421948 0.359450 0.899862
+v 0.430389 0.373779 0.906465
+v 0.435708 0.385403 0.913725
+v 0.437702 0.393873 0.921363
+v 0.436295 0.398865 0.929086
+v 0.431539 0.400186 0.936597
+v 0.423619 0.397787 0.943607
+v 0.412838 0.391758 0.949847
+v 0.399610 0.382333 0.955077
+v 0.384445 0.369872 0.959096
+v 0.367924 0.354855 0.961750
+v 0.350683 0.337859 0.962936
+v 0.378696 0.306725 0.885319
+v 0.391283 0.326144 0.887582
+v 0.402252 0.344688 0.891229
+v 0.411181 0.361643 0.896119
+v 0.417728 0.376359 0.902063
+v 0.421640 0.388269 0.908834
+v 0.422768 0.396916 0.916171
+v 0.421068 0.401967 0.923792
+v 0.416605 0.403229 0.931404
+v 0.409551 0.400653 0.938716
+v 0.400177 0.394338 0.945445
+v 0.388843 0.384526 0.951333
+v 0.375985 0.371595 0.956155
+v 0.362097 0.356042 0.959724
+v 0.347712 0.338464 0.961903
+v 0.375187 0.306591 0.884284
+v 0.384399 0.325881 0.885553
+v 0.392258 0.344306 0.888283
+v 0.398461 0.361158 0.892369
+v 0.402770 0.375788 0.897654
+v 0.405020 0.387634 0.903935
+v 0.405124 0.396242 0.910970
+v 0.403078 0.401280 0.918489
+v 0.398961 0.402555 0.926204
+v 0.392931 0.400018 0.933817
+v 0.385219 0.393766 0.941036
+v 0.376123 0.384040 0.947584
+v 0.365991 0.371214 0.953209
+v 0.355213 0.355779 0.957695
+v 0.344203 0.338330 0.960869
+v 0.371273 0.305723 0.883288
+v 0.376722 0.324178 0.883599
+v 0.381112 0.341834 0.885446
+v 0.384276 0.358011 0.888758
+v 0.386090 0.372087 0.893407
+v 0.386487 0.383522 0.899216
+v 0.385449 0.391877 0.905961
+v 0.383018 0.396830 0.913382
+v 0.379286 0.398190 0.921194
+v 0.374397 0.395907 0.929098
+v 0.368539 0.390066 0.936789
+v 0.361938 0.380893 0.943972
+v 0.354845 0.368741 0.950371
+v 0.347536 0.354076 0.955740
+v 0.340289 0.337462 0.959872
+v 0.367106 0.304154 0.882368
+v 0.368547 0.321101 0.881794
+v 0.369245 0.337366 0.882826
+v 0.369171 0.352324 0.885423
+v 0.368329 0.365400 0.889486
+v 0.366751 0.376092 0.894859
+v 0.364498 0.383989 0.901335
+v 0.361656 0.388787 0.908666
+v 0.358335 0.390302 0.916569
+v 0.354662 0.388476 0.924741
+v 0.350778 0.383379 0.932868
+v 0.346833 0.375207 0.940637
+v 0.342978 0.364273 0.947751
+v 0.339361 0.350998 0.953935
+v 0.336122 0.335893 0.958952
+v 0.333384 0.319537 0.962610
+v 0.362845 0.301944 0.881559
+v 0.360189 0.316766 0.880208
+v 0.357111 0.331074 0.880524
+v 0.353727 0.344315 0.882493
+v 0.350169 0.355983 0.886041
+v 0.346573 0.365629 0.891031
+v 0.343077 0.372881 0.897271
+v 0.339816 0.377462 0.904522
+v 0.336914 0.379194 0.912505
+v 0.334484 0.378013 0.920913
+v 0.332618 0.373962 0.929423
+v 0.331389 0.367198 0.937708
+v 0.330844 0.357981 0.945449
+v 0.331003 0.346664 0.952350
+v 0.331861 0.333683 0.958144
+v 0.358654 0.299179 0.880894
+v 0.351969 0.311343 0.878903
+v 0.345177 0.323199 0.878628
+v 0.338538 0.334293 0.880081
+v 0.332309 0.344199 0.883204
+v 0.326728 0.352534 0.887879
+v 0.322009 0.358980 0.893925
+v 0.318335 0.363288 0.901111
+v 0.315846 0.365293 0.909159
+v 0.314638 0.364918 0.917761
+v 0.314758 0.362177 0.926586
+v 0.316200 0.357176 0.935295
+v 0.318910 0.350107 0.943554
+v 0.322783 0.341240 0.951044
+v 0.327670 0.330918 0.957479
+v 0.354695 0.295965 0.880396
+v 0.344202 0.305037 0.877927
+v 0.333901 0.314045 0.877212
+v 0.324187 0.322643 0.878279
+v 0.315434 0.330499 0.881085
+v 0.307977 0.337312 0.885525
+v 0.302104 0.342820 0.891426
+v 0.298040 0.346812 0.898562
+v 0.295941 0.349134 0.906659
+v 0.295888 0.349696 0.915406
+v 0.297883 0.348478 0.924467
+v 0.301849 0.345526 0.933493
+v 0.307634 0.340953 0.942138
+v 0.315016 0.334935 0.950069
+v 0.323711 0.327704 0.956981
+v 0.351119 0.292424 0.880087
+v 0.337188 0.298093 0.877320
+v 0.323717 0.303964 0.876330
+v 0.311226 0.309811 0.877156
+v 0.300193 0.315411 0.879765
+v 0.291042 0.320547 0.884058
+v 0.284126 0.325022 0.889869
+v 0.279709 0.328665 0.896974
+v 0.277963 0.331336 0.905102
+v 0.278953 0.332931 0.913940
+v 0.282642 0.333390 0.923147
+v 0.288888 0.332694 0.932371
+v 0.297450 0.330871 0.941256
+v 0.308001 0.327991 0.949461
+v 0.320135 0.324164 0.956672
+v 0.348063 0.288694 0.879976
+v 0.331195 0.290776 0.877103
+v 0.315017 0.293342 0.876016
+v 0.300152 0.296292 0.876756
+v 0.287171 0.299514 0.879295
+v 0.276574 0.302883 0.883535
+v 0.268766 0.306271 0.889314
+v 0.264049 0.309546 0.896409
+v 0.262603 0.312584 0.904547
+v 0.264484 0.315267 0.913417
+v 0.269620 0.317493 0.922677
+v 0.277814 0.319175 0.931971
+v 0.288750 0.320249 0.940942
+v 0.302008 0.320674 0.949245
+v 0.317079 0.320434 0.956561
+v 0.345646 0.284918 0.880070
+v 0.326453 0.283369 0.877286
+v 0.308134 0.282588 0.876282
+v 0.291392 0.282605 0.877094
+v 0.276870 0.283419 0.879692
+v 0.265128 0.285000 0.883977
+v 0.256615 0.287286 0.889783
+v 0.251660 0.290189 0.896887
+v 0.250452 0.293599 0.905016
+v 0.253038 0.297384 0.913859
+v 0.259319 0.301398 0.923074
+v 0.269054 0.305487 0.932309
+v 0.281867 0.309495 0.941207
+v 0.297267 0.313267 0.949428
+v 0.314662 0.316657 0.956654
+v 0.343960 0.281240 0.880363
+v 0.323147 0.276155 0.877862
+v 0.303333 0.272115 0.877117
+v 0.285281 0.269275 0.878157
+v 0.269685 0.267745 0.880942
+v 0.257144 0.267584 0.885366
+v 0.248140 0.268797 0.891257
+v 0.243019 0.271339 0.898390
+v 0.241977 0.275110 0.906491
+v 0.245055 0.279968 0.915248
+v 0.252134 0.285724 0.924324
+v 0.262943 0.292158 0.933372
+v 0.277066 0.299022 0.942042
+v 0.293960 0.306053 0.950003
+v 0.312976 0.312980 0.956948
+v 0.343071 0.277803 0.880845
+v 0.321401 0.269412 0.878807
+v 0.300799 0.262325 0.878490
+v 0.282056 0.256815 0.879904
+v 0.265893 0.253094 0.882997
+v 0.252930 0.251305 0.887648
+v 0.243666 0.251515 0.893680
+v 0.238457 0.253718 0.900861
+v 0.237503 0.257829 0.908914
+v 0.240840 0.263689 0.917530
+v 0.248342 0.271073 0.926379
+v 0.259718 0.279698 0.935119
+v 0.274532 0.289233 0.943415
+v 0.292215 0.299310 0.950949
+v 0.312087 0.309542 0.957430
+v 0.364975 0.287176 0.884525
+v 0.343011 0.274737 0.881497
+v 0.321284 0.263399 0.880087
+v 0.300628 0.253596 0.880347
+v 0.281839 0.245705 0.882268
+v 0.265638 0.240029 0.885777
+v 0.252647 0.236788 0.890737
+v 0.243365 0.236104 0.896960
+v 0.238150 0.238005 0.904204
+v 0.237202 0.242418 0.912193
+v 0.240557 0.249172 0.920619
+v 0.248087 0.258008 0.929159
+v 0.259501 0.268588 0.937483
+v 0.274361 0.280503 0.945273
+v 0.292097 0.293297 0.952228
+v 0.312027 0.306477 0.958082
+v 0.343783 0.272162 0.882295
+v 0.322799 0.258347 0.881651
+v 0.302829 0.246261 0.882618
+v 0.284639 0.236370 0.885159
+v 0.268930 0.229053 0.889175
+v 0.256305 0.224591 0.894514
+v 0.247249 0.223156 0.900969
+v 0.242110 0.224804 0.908292
+v 0.241086 0.229470 0.916202
+v 0.244216 0.236975 0.924396
+v 0.251379 0.247032 0.932557
+v 0.262301 0.259253 0.940373
+v 0.276562 0.273169 0.947544
+v 0.293613 0.288245 0.953792
+v 0.312799 0.303901 0.958880
+vn -0.457839 -0.781518 -0.423750
+vn -0.223029 -0.673574 -0.704642
+vn -0.075198 -0.813440 -0.576739
+vn 0.188421 -0.315073 -0.930143
+vn 0.237678 -0.259987 -0.935881
+vn 0.254982 -0.277749 -0.926176
+vn -0.419538 0.028382 0.907285
+vn -0.475234 -0.052797 0.878231
+vn -0.363811 -0.022614 0.931181
+vn -0.664296 -0.746788 0.031007
+vn -0.251381 -0.932798 -0.258187
+vn 0.129276 -0.377697 -0.916837
+vn 0.222175 -0.351207 -0.909513
+vn -0.371807 0.093417 0.923582
+vn -0.336650 0.059999 0.939695
+vn -0.701468 -0.541581 0.463240
+vn -0.416791 -0.889676 0.186377
+vn 0.052278 -0.453749 -0.889584
+vn 0.181555 -0.434950 -0.881954
+vn -0.328257 0.149602 0.932646
+vn -0.310587 0.132694 0.941221
+vn -0.627064 -0.321024 0.709708
+vn -0.460280 -0.434584 0.774102
+vn -0.057039 -0.551073 -0.832484
+vn 0.127140 -0.535997 -0.834559
+vn -0.543626 -0.162542 0.823389
+vn -0.426374 -0.254494 0.867977
+vn 0.047731 -0.662618 -0.747398
+vn -0.393414 -0.123234 0.911039
+vn 0.075259 -0.892026 -0.445631
+vn 0.273049 -0.291879 -0.916623
+vn -0.306375 -0.062563 0.949828
+vn -0.049165 -0.992737 -0.109500
+vn 0.257790 -0.380444 -0.888119
+vn -0.300272 0.033357 0.953246
+vn -0.476608 -0.671621 0.567186
+vn -0.265786 -0.729972 0.629627
+vn 0.236885 -0.480453 -0.844386
+vn -0.292428 0.119358 0.948790
+vn -0.299600 -0.502945 0.810694
+vn 0.206091 -0.598498 -0.774132
+vn -0.309793 -0.318613 0.895810
+vn 0.157018 -0.739464 -0.654622
+vn -0.310251 -0.176244 0.934141
+vn -0.201758 -0.357830 0.911710
+vn 0.261330 -0.782128 -0.565630
+vn -0.230537 -0.212165 0.949614
+vn 0.211371 -0.920133 -0.329600
+vn 0.290933 -0.302255 -0.907712
+vn -0.250252 -0.091128 0.963866
+vn -0.182501 -0.935881 0.301279
+vn 0.121921 -0.992492 0.006439
+vn 0.293588 -0.401959 -0.867275
+vn -0.264290 0.013825 0.964324
+vn -0.090060 -0.742607 0.663594
+vn 0.292306 -0.512894 -0.807123
+vn -0.274606 0.109653 0.955260
+vn -0.157903 -0.536241 0.829127
+vn 0.283914 -0.639729 -0.714194
+vn -0.257668 0.103580 0.960662
+vn -0.037233 -0.544359 0.838008
+vn 0.357402 -0.660604 -0.660146
+vn -0.105411 -0.376049 0.920560
+vn 0.356365 -0.796319 -0.488723
+vn -0.157109 -0.232185 0.959868
+vn 0.328745 -0.914212 -0.236793
+vn 0.308145 -0.308756 -0.899808
+vn -0.197333 -0.108432 0.974303
+vn 0.008362 -0.926206 0.376843
+vn 0.260598 -0.961241 0.089969
+vn 0.328257 -0.415357 -0.848323
+vn -0.230018 0.001556 0.973174
+vn 0.051912 -0.729331 0.682150
+vn 0.345622 -0.531938 -0.773003
+vn 0.360698 -0.420545 -0.832453
+vn -0.198431 -0.003418 0.980102
+vn 0.158483 -0.891140 0.425092
+vn 0.167791 -0.700797 0.693319
+vn 0.395276 -0.537950 -0.744530
+vn -0.242073 0.101138 0.964965
+vn 0.064638 -0.534104 0.842921
+vn 0.424818 -0.663442 -0.615925
+vn -0.021363 -0.376843 0.926023
+vn 0.441206 -0.788537 -0.428358
+vn -0.091342 -0.237709 0.967009
+vn 0.429548 -0.887173 -0.168432
+vn 0.324137 -0.311350 -0.893277
+vn -0.149113 -0.114780 0.982116
+vn 0.374584 -0.915433 0.147099
+vn 0.517838 -0.846583 -0.122929
+vn 0.338359 -0.310068 -0.888424
+vn -0.106632 -0.110660 0.988098
+vn 0.279061 -0.844997 0.456160
+vn 0.472060 -0.862178 0.183752
+vn 0.389935 -0.417707 -0.820612
+vn -0.170385 -0.001251 0.985351
+vn 0.264748 -0.661702 0.701437
+vn 0.440077 -0.531754 -0.723563
+vn -0.228248 0.102268 0.968200
+vn 0.151006 -0.509445 0.847133
+vn 0.485336 -0.650594 -0.584033
+vn 0.050935 -0.362682 0.930509
+vn 0.516709 -0.764000 -0.386303
+vn -0.033998 -0.229957 0.972594
+vn 0.112369 -0.335002 0.935453
+vn 0.584063 -0.725913 -0.363140
+vn 0.014618 -0.209815 0.977599
+vn 0.597247 -0.795984 -0.098361
+vn 0.350505 -0.305155 -0.885433
+vn -0.070589 -0.096500 0.992798
+vn 0.380108 -0.792871 0.476272
+vn 0.559313 -0.803491 0.203864
+vn 0.415113 -0.407239 -0.813501
+vn -0.146611 0.007843 0.989135
+vn 0.348430 -0.613514 0.708609
+vn 0.479049 -0.514359 -0.711264
+vn -0.216559 0.106845 0.970397
+vn 0.224677 -0.472274 0.852321
+vn 0.538652 -0.624134 -0.565935
+vn -0.127567 0.023591 0.991516
+vn 0.287759 -0.422712 0.859340
+vn 0.643910 -0.675680 -0.358867
+vn 0.163396 -0.294351 0.941618
+vn 0.670370 -0.736045 -0.093600
+vn 0.054231 -0.177770 0.982543
+vn 0.640919 -0.738456 0.209418
+vn 0.435621 -0.389691 -0.811365
+vn 0.468917 -0.735588 0.488845
+vn 0.550737 -0.671651 0.495499
+vn 0.511429 -0.486648 -0.708213
+vn -0.041597 -0.072756 0.996460
+vn 0.422803 -0.555620 0.715873
+vn 0.584277 -0.585253 -0.562151
+vn -0.020203 -0.039766 0.998993
+vn 0.490616 -0.485641 0.723472
+vn 0.621326 -0.534745 -0.572680
+vn -0.207160 0.114658 0.971526
+vn -0.113773 0.045656 0.992431
+vn 0.695944 -0.613361 -0.373333
+vn 0.341441 -0.359630 0.868343
+vn 0.738456 -0.665487 -0.108493
+vn 0.204230 -0.240364 0.948943
+vn 0.720023 -0.664296 0.200598
+vn 0.360271 -0.296823 -0.884335
+vn 0.450880 -0.365551 -0.814264
+vn 0.084384 -0.134068 0.987365
+vn 0.629322 -0.597919 0.496384
+vn 0.536363 -0.449324 -0.714408
+vn 0.367504 -0.285287 -0.885159
+vn 0.460250 -0.335429 -0.821955
+vn 0.104526 -0.078646 0.991394
+vn 0.707297 -0.509049 0.490463
+vn 0.552690 -0.403119 -0.729362
+vn -0.006989 0.002045 0.999969
+vn 0.648244 -0.472793 -0.596789
+vn -0.200323 0.125614 0.971618
+vn -0.105625 0.073611 0.991668
+vn 0.553362 -0.399365 0.730918
+vn 0.738609 -0.537919 -0.406262
+vn 0.385968 -0.280496 0.878811
+vn 0.800958 -0.581164 -0.143803
+vn 0.234352 -0.172124 0.956786
+vn 0.798212 -0.576128 0.175756
+vn 0.854823 -0.478378 -0.201025
+vn 0.252510 -0.088015 0.963561
+vn 0.874722 -0.466475 0.131260
+vn 0.371868 -0.270699 -0.887906
+vn 0.463027 -0.300119 -0.833949
+vn 0.113620 -0.011383 0.993439
+vn 0.785638 -0.396802 0.474624
+vn 0.559221 -0.348979 -0.751946
+vn -0.002594 0.052187 0.998627
+vn 0.662862 -0.399701 -0.633106
+vn -0.196204 0.139500 0.970580
+vn -0.103458 0.106906 0.988861
+vn 0.611103 -0.290201 0.736412
+vn 0.768639 -0.447645 -0.456893
+vn 0.420148 -0.181494 0.889096
+vn 0.660878 -0.148473 0.735649
+vn 0.780847 -0.341227 -0.523240
+vn 0.440870 -0.057497 0.895688
+vn 0.892788 -0.351787 -0.281289
+vn 0.256417 0.013520 0.966460
+vn 0.943632 -0.325144 0.061708
+vn 0.373089 -0.253456 -0.892483
+vn 0.458846 -0.260781 -0.849361
+vn 0.110446 0.067568 0.991577
+vn 0.861446 -0.248756 0.442701
+vn 0.554765 -0.288247 -0.780450
+vn -0.007538 0.109897 0.993896
+vn 0.662343 -0.316202 -0.679159
+vn -0.195044 0.156041 0.968291
+vn -0.107578 0.144688 0.983581
+vn -0.022462 0.173925 0.984497
+vn 0.693655 0.037599 0.719291
+vn 0.644032 -0.224311 -0.731346
+vn -0.196966 0.174841 0.964660
+vn -0.118107 0.186041 0.975402
+vn 0.768395 -0.219398 -0.601154
+vn 0.441908 0.096377 0.891842
+vn 0.902219 -0.197851 -0.383190
+vn 0.242653 0.133396 0.960875
+vn 0.989196 -0.141240 -0.038545
+vn 0.370983 -0.234107 -0.898618
+vn 0.447462 -0.218635 -0.867153
+vn 0.093448 0.157414 0.983093
+vn 0.921995 -0.049165 0.384014
+vn 0.538438 -0.222785 -0.812677
+vn 0.365520 -0.213202 -0.906034
+vn 0.428846 -0.175268 -0.886196
+vn 0.061007 0.255684 0.964812
+vn 0.935392 0.209876 0.284555
+vn 0.509842 -0.155156 -0.846126
+vn -0.047792 0.242317 0.968993
+vn 0.688955 0.274575 0.670766
+vn 0.606037 -0.127842 -0.785089
+vn -0.202094 0.195410 0.959655
+vn -0.135166 0.229621 0.963836
+vn 0.724845 -0.087039 -0.683370
+vn 0.412915 0.281045 0.866298
+vn 0.866146 -0.020386 -0.499344
+vn 0.206793 0.269601 0.940489
+vn 0.981506 0.086917 -0.170507
+vn 0.771966 0.162420 -0.614521
+vn 0.144810 0.414136 0.898587
+vn 0.886258 0.333201 -0.321696
+vn 0.356548 -0.191351 -0.914457
+vn 0.403302 -0.132633 -0.905393
+vn 0.012055 0.357280 0.933897
+vn 0.854671 0.500107 0.139195
+vn 0.469527 -0.088870 -0.878414
+vn -0.083712 0.311838 0.946410
+vn 0.615253 0.542741 0.571703
+vn 0.548509 -0.032929 -0.835475
+vn -0.210547 0.217200 0.953124
+vn -0.158818 0.273598 0.948637
+vn 0.647847 0.045106 -0.760430
+vn 0.341319 0.484207 0.805597
+vn 0.223029 0.673574 0.704642
+vn 0.543626 0.162572 -0.823389
+vn 0.057039 0.551073 0.832484
+vn 0.627064 0.321024 -0.709708
+vn -0.052278 0.453749 0.889584
+vn 0.701468 0.541581 -0.463240
+vn 0.344005 -0.169622 -0.923490
+vn 0.328257 -0.149602 -0.932646
+vn -0.129276 0.377697 0.916837
+vn 0.664296 0.746788 -0.031007
+vn 0.419538 -0.028382 -0.907254
+vn -0.188421 0.315073 0.930143
+vn 0.457839 0.781518 0.423750
+vn 0.475234 0.052797 -0.878231
+vn -0.222480 0.239265 0.945097
+vn -0.237678 0.259987 0.935881
+vn -0.222175 0.351238 0.909513
+vn 0.251381 0.932798 0.258187
+vn 0.363811 0.022614 -0.931181
+vn -0.254982 0.277718 0.926176
+vn 0.075198 0.813440 0.576739
+vn 0.393414 0.123234 -0.911039
+vn -0.047731 0.662618 0.747398
+vn 0.426374 0.254494 -0.867977
+vn -0.127140 0.535997 0.834559
+vn 0.460280 0.434584 -0.774102
+vn 0.371807 -0.093417 -0.923582
+vn 0.310587 -0.132664 -0.941221
+vn -0.181555 0.434950 0.881954
+vn 0.416791 0.889676 -0.186377
+vn 0.336650 -0.059999 -0.939695
+vn -0.236885 0.480453 0.844386
+vn 0.476608 0.671621 -0.567186
+vn 0.265786 0.729972 -0.629658
+vn 0.300241 -0.033357 -0.953246
+vn -0.257790 0.380444 0.888119
+vn 0.049165 0.992737 0.109531
+vn 0.306406 0.062563 -0.949828
+vn -0.273019 0.291879 0.916623
+vn -0.075259 0.892026 0.445631
+vn 0.310221 0.176244 -0.934141
+vn -0.157018 0.739433 0.654622
+vn 0.309793 0.318613 -0.895810
+vn -0.206091 0.598498 0.774132
+vn 0.299600 0.502945 -0.810694
+vn 0.292428 -0.119358 -0.948790
+vn -0.283914 0.639729 0.714225
+vn 0.157903 0.536241 -0.829127
+vn 0.274606 -0.109653 -0.955260
+vn -0.292306 0.512894 0.807123
+vn 0.182501 0.935881 -0.301248
+vn 0.090060 0.742607 -0.663594
+vn 0.264290 -0.013825 -0.964324
+vn -0.293588 0.401959 0.867306
+vn -0.121921 0.992492 -0.006439
+vn 0.250252 0.091128 -0.963866
+vn -0.290963 0.302255 0.907712
+vn -0.211371 0.920133 0.329600
+vn 0.230537 0.212165 -0.949614
+vn -0.261330 0.782128 0.565630
+vn 0.201758 0.357799 -0.911710
+vn 0.157109 0.232185 -0.959868
+vn -0.356334 0.796319 0.488723
+vn 0.105411 0.376049 -0.920560
+vn -0.357402 0.660604 0.660146
+vn 0.037202 0.544359 -0.838008
+vn 0.257637 -0.103580 -0.960662
+vn -0.345653 0.531938 0.773003
+vn -0.008362 0.926206 -0.376843
+vn -0.051943 0.729331 -0.682150
+vn 0.230018 -0.001556 -0.973174
+vn -0.328257 0.415357 0.848323
+vn -0.260598 0.961241 -0.089969
+vn 0.197333 0.108432 -0.974303
+vn -0.308176 0.308756 0.899808
+vn -0.328745 0.914212 0.236793
+vn -0.158483 0.891140 -0.425092
+vn -0.374584 0.915433 -0.147099
+vn 0.149144 0.114780 -0.982116
+vn -0.324137 0.311350 0.893277
+vn -0.429548 0.887173 0.168432
+vn 0.091342 0.237709 -0.967009
+vn -0.441206 0.788568 0.428327
+vn 0.021363 0.376843 -0.926023
+vn -0.424818 0.663442 0.615894
+vn -0.064638 0.534104 -0.842921
+vn 0.242073 -0.101138 -0.964965
+vn -0.395276 0.537950 0.744530
+vn -0.167791 0.700797 -0.693319
+vn 0.198431 0.003418 -0.980102
+vn -0.360698 0.420545 0.832453
+vn -0.440077 0.531754 0.723563
+vn -0.279061 0.844997 -0.456160
+vn -0.264748 0.661702 -0.701437
+vn 0.170385 0.001251 -0.985351
+vn -0.389935 0.417707 0.820643
+vn -0.472060 0.862178 -0.183752
+vn 0.106632 0.110660 -0.988098
+vn -0.338359 0.310068 0.888424
+vn -0.517808 0.846583 0.122929
+vn 0.033998 0.229957 -0.972594
+vn -0.516709 0.764000 0.386303
+vn -0.050935 0.362682 -0.930509
+vn -0.485336 0.650594 0.584033
+vn -0.151006 0.509445 -0.847133
+vn 0.228248 -0.102268 -0.968200
+vn -0.538652 0.624134 0.565935
+vn -0.224677 0.472274 -0.852321
+vn 0.216559 -0.106845 -0.970397
+vn -0.479049 0.514359 0.711264
+vn -0.380108 0.792871 -0.476272
+vn -0.348430 0.613514 -0.708609
+vn 0.146611 -0.007843 -0.989135
+vn -0.415113 0.407239 0.813501
+vn -0.559313 0.803491 -0.203833
+vn 0.070589 0.096500 -0.992798
+vn -0.350505 0.305155 0.885433
+vn -0.597247 0.795984 0.098361
+vn -0.014618 0.209815 -0.977599
+vn -0.584063 0.725913 0.363140
+vn -0.112369 0.335002 -0.935453
+vn -0.054231 0.177770 -0.982543
+vn -0.670370 0.736045 0.093600
+vn -0.163396 0.294351 -0.941618
+vn -0.643910 0.675680 0.358867
+vn -0.287759 0.422712 -0.859340
+vn 0.127598 -0.023591 -0.991516
+vn -0.584277 0.585253 0.562151
+vn -0.468947 0.735588 -0.488845
+vn -0.422803 0.555620 -0.715873
+vn 0.041597 0.072756 -0.996460
+vn -0.511429 0.486648 0.708213
+vn -0.550737 0.671651 -0.495499
+vn -0.435621 0.389691 0.811365
+vn -0.640919 0.738456 -0.209418
+vn -0.629322 0.597919 -0.496384
+vn -0.084384 0.134068 -0.987365
+vn -0.360271 0.296823 0.884335
+vn -0.450880 0.365551 0.814264
+vn -0.720023 0.664296 -0.200598
+vn -0.204230 0.240364 -0.948943
+vn -0.738456 0.665487 0.108493
+vn -0.341441 0.359630 -0.868343
+vn -0.695944 0.613361 0.373333
+vn -0.490616 0.485641 -0.723472
+vn 0.207160 -0.114658 -0.971557
+vn 0.113773 -0.045656 -0.992431
+vn -0.621326 0.534745 0.572680
+vn 0.020203 0.039766 -0.998993
+vn -0.536363 0.449324 0.714408
+vn -0.648244 0.472793 0.596789
+vn -0.707297 0.509049 -0.490463
+vn 0.007019 -0.002045 -0.999969
+vn -0.552690 0.403119 0.729362
+vn -0.104495 0.078646 -0.991394
+vn -0.367504 0.285287 0.885159
+vn -0.460219 0.335429 0.821955
+vn -0.798212 0.576098 -0.175756
+vn -0.234352 0.172124 -0.956786
+vn -0.800958 0.581164 0.143803
+vn -0.385968 0.280496 -0.878811
+vn -0.738609 0.537919 0.406262
+vn -0.553392 0.399365 -0.730888
+vn 0.200323 -0.125614 -0.971618
+vn 0.105625 -0.073641 -0.991668
+vn -0.768639 0.447645 0.456893
+vn -0.611103 0.290201 -0.736412
+vn 0.196204 -0.139500 -0.970580
+vn 0.103458 -0.106906 -0.988861
+vn -0.662862 0.399701 0.633106
+vn -0.785638 0.396802 -0.474593
+vn 0.002594 -0.052187 -0.998627
+vn -0.559221 0.348979 0.751946
+vn -0.113620 0.011383 -0.993439
+vn -0.371868 0.270699 0.887906
+vn -0.463027 0.300119 0.833949
+vn -0.874722 0.466475 -0.131260
+vn -0.252510 0.088015 -0.963561
+vn -0.854793 0.478378 0.201025
+vn -0.420179 0.181463 -0.889096
+vn -0.892788 0.351787 0.281289
+vn -0.440870 0.057497 -0.895688
+vn -0.780847 0.341227 0.523240
+vn -0.660878 0.148442 -0.735649
+vn 0.195044 -0.156041 -0.968291
+vn 0.107578 -0.144688 -0.983581
+vn -0.662374 0.316202 0.679159
+vn -0.861446 0.248756 -0.442701
+vn 0.007538 -0.109897 -0.993896
+vn -0.554765 0.288247 0.780450
+vn -0.110446 -0.067598 -0.991577
+vn -0.373089 0.253456 0.892483
+vn -0.458846 0.260781 0.849361
+vn -0.943632 0.325144 -0.061708
+vn -0.256417 -0.013520 -0.966460
+vn -0.093448 -0.157414 -0.983093
+vn -0.371014 0.234107 0.898618
+vn -0.447462 0.218635 0.867153
+vn -0.989196 0.141240 0.038575
+vn -0.242653 -0.133396 -0.960875
+vn -0.902219 0.197851 0.383190
+vn -0.441908 -0.096377 -0.891842
+vn -0.768395 0.219398 0.601154
+vn -0.693655 -0.037599 -0.719291
+vn 0.196966 -0.174841 -0.964660
+vn 0.118107 -0.186041 -0.975402
+vn -0.644032 0.224311 0.731346
+vn 0.022462 -0.173925 -0.984497
+vn -0.538408 0.222785 0.812677
+vn -0.921995 0.049165 -0.384014
+vn -0.688955 -0.274575 -0.670766
+vn 0.047792 -0.242317 -0.968993
+vn -0.509842 0.155156 0.846126
+vn -0.935392 -0.209876 -0.284555
+vn -0.061007 -0.255684 -0.964812
+vn -0.365520 0.213202 0.906034
+vn -0.428877 0.175268 0.886196
+vn -0.981506 -0.086917 0.170507
+vn -0.206824 -0.269601 -0.940489
+vn -0.866146 0.020386 0.499344
+vn -0.412946 -0.281045 -0.866298
+vn -0.724845 0.087039 0.683370
+vn 0.202094 -0.195410 -0.959655
+vn 0.135166 -0.229621 -0.963836
+vn -0.606037 0.127842 0.785089
+vn -0.647816 -0.045106 0.760430
+vn -0.615253 -0.542711 -0.571703
+vn 0.210547 -0.217200 -0.953124
+vn 0.158788 -0.273598 -0.948637
+vn -0.548509 0.032929 0.835475
+vn 0.083712 -0.311838 -0.946410
+vn -0.469527 0.088870 0.878414
+vn -0.854671 -0.500107 -0.139195
+vn -0.012055 -0.357280 -0.933897
+vn -0.356548 0.191382 0.914457
+vn -0.403302 0.132633 0.905393
+vn -0.886258 -0.333201 0.321696
+vn -0.144810 -0.414136 -0.898587
+vn -0.771966 -0.162420 0.614521
+vn -0.341319 -0.484207 -0.805597
+vn -0.284280 0.205390 0.936460
+vn 0.284280 -0.205390 -0.936460
+vn -0.344005 0.169622 0.923490
+vn 0.222480 -0.239265 -0.945097
+vn -0.223060 -0.673574 -0.704642
+vn 0.254982 -0.277718 -0.926176
+vn -0.419538 0.028382 0.907254
+vn 0.222175 -0.351207 -0.909543
+vn 0.181555 -0.434950 -0.881924
+vn -0.328288 0.149602 0.932646
+vn -0.310617 0.132664 0.941221
+vn -0.543626 -0.162572 0.823389
+vn 0.273049 -0.291849 -0.916623
+vn -0.306406 -0.062563 0.949828
+vn -0.300241 0.033357 0.953246
+vn 0.157018 -0.739433 -0.654622
+vn -0.310221 -0.176244 0.934141
+vn -0.201758 -0.357799 0.911710
+vn -0.230537 -0.212165 0.949644
+vn 0.290994 -0.302255 -0.907712
+vn -0.182501 -0.935881 0.301248
+vn 0.293588 -0.401959 -0.867306
+vn -0.274575 0.109653 0.955260
+vn -0.157872 -0.536241 0.829127
+vn 0.283914 -0.639729 -0.714225
+vn -0.037202 -0.544359 0.838008
+vn -0.105441 -0.376049 0.920560
+vn 0.308176 -0.308756 -0.899808
+vn 0.051943 -0.729331 0.682150
+vn 0.345653 -0.531938 -0.773003
+vn 0.395306 -0.537919 -0.744530
+vn -0.242103 0.101138 0.964934
+vn 0.441206 -0.788568 -0.428358
+vn -0.149144 -0.114780 0.982116
+vn -0.228278 0.102268 0.968200
+vn 0.112339 -0.335002 0.935453
+vn -0.127598 0.023591 0.991516
+vn 0.468947 -0.735588 0.488845
+vn 0.695944 -0.613361 -0.373363
+vn 0.341472 -0.359630 0.868343
+vn 0.629322 -0.597919 0.496414
+vn 0.104495 -0.078646 0.991394
+vn -0.007019 0.002045 0.999969
+vn 0.553392 -0.399365 0.730918
+vn 0.800958 -0.581133 -0.143803
+vn 0.798212 -0.576098 0.175756
+vn 0.785638 -0.396802 0.474593
+vn -0.002564 0.052187 0.998627
+vn 0.420148 -0.181463 0.889096
+vn 0.660878 -0.148442 0.735649
+vn 0.780847 -0.341227 -0.523270
+vn 0.371014 -0.234107 -0.898618
+vn 0.538408 -0.222785 -0.812677
+vn 0.365520 -0.213172 -0.906034
+vn 0.428846 -0.175237 -0.886196
+vn 0.606006 -0.127842 -0.785089
+vn 0.412946 0.281045 0.866298
+vn 0.356517 -0.191382 -0.914457
+vn -0.210517 0.217200 0.953124
+vn 0.647816 0.045106 -0.760430
+vn 0.627033 0.321024 -0.709708
+vn 0.344005 -0.169652 -0.923490
+vn 0.328288 -0.149602 -0.932646
+vn -0.222449 0.239265 0.945097
+vn -0.222144 0.351238 0.909543
+vn 0.426405 0.254494 -0.867977
+vn 0.265786 0.729972 -0.629627
+vn 0.049165 0.992737 0.109500
+vn -0.273049 0.291879 0.916623
+vn 0.310251 0.176244 -0.934141
+vn -0.283914 0.639729 0.714194
+vn 0.157872 0.536241 -0.829127
+vn 0.182501 0.935881 -0.301279
+vn 0.090030 0.742607 -0.663594
+vn -0.293588 0.401959 0.867275
+vn 0.250221 0.091128 -0.963866
+vn 0.201758 0.357830 -0.911710
+vn -0.356365 0.796319 0.488723
+vn 0.105441 0.376049 -0.920560
+vn 0.257668 -0.103580 -0.960631
+vn -0.051943 0.729362 -0.682150
+vn 0.197363 0.108432 -0.974303
+vn -0.324107 0.311350 0.893277
+vn -0.424818 0.663442 0.615925
+vn 0.242103 -0.101138 -0.964934
+vn -0.395306 0.537950 0.744530
+vn -0.360729 0.420545 0.832453
+vn -0.440046 0.531754 0.723563
+vn -0.389935 0.417707 0.820612
+vn -0.338359 0.310068 0.888455
+vn 0.216529 -0.106845 -0.970397
+vn -0.350475 0.305155 0.885433
+vn -0.112339 0.335002 -0.935453
+vn 0.127567 -0.023591 -0.991516
+vn -0.629322 0.597919 -0.496414
+vn -0.360271 0.296854 0.884335
+vn 0.006989 -0.002045 -0.999969
+vn -0.798212 0.576128 -0.175756
+vn -0.553362 0.399365 -0.730918
+vn -0.768670 0.447645 0.456862
+vn -0.854823 0.478378 0.201025
+vn -0.420179 0.181494 -0.889096
+vn -0.660878 0.148473 -0.735649
+vn -0.662343 0.316202 0.679159
+vn -0.110446 -0.067568 -0.991577
+vn -0.538438 0.222785 0.812647
+vn -0.365520 0.213172 0.906034
+vn -0.428846 0.175268 0.886196
+vn -0.412915 -0.281045 -0.866298
+vn -0.606006 0.127842 0.785089
+vn -0.615253 -0.542711 -0.571734
+vn 0.158818 -0.273598 -0.948637
+vn -0.403272 0.132633 0.905393
+vn 0.222480 -0.239296 -0.945097
+usemtl SkinColor
+s 1
+f 2417//1711 2416//1712 2431//1713
+f 2412//1714 2411//1715 2426//1716
+f 2423//1717 2422//1718 2438//1719
+f 2418//1720 2417//1711 2432//1721
+f 2413//1722 2412//1714 2427//1723
+f 2424//1724 2423//1717 2439//1725
+f 2419//1726 2418//1720 2433//1727
+f 2414//1728 2413//1722 2428//1729
+f 2425//1730 2424//1724 2440//1731
+f 2420//1732 2419//1726 2435//1733
+f 2415//1734 2414//1728 2429//1735
+f 2421//1736 2420//1732 2436//1737
+f 2416//1712 2415//1734 2430//1738
+f 2422//1718 2421//1736 2437//1739
+f 2432//1721 2431//1713 2446//1740
+f 2427//1723 2426//1716 2441//1741
+f 2438//1719 2437//1739 2453//1742
+f 2433//1727 2432//1721 2447//1743
+f 2428//1729 2427//1723 2442//1744
+f 2439//1725 2438//1719 2454//1745
+f 2434//1746 2433//1727 2449//1747
+f 2429//1735 2428//1729 2443//1748
+f 2440//1731 2439//1725 2455//1749
+f 2435//1733 2434//1746 2450//1750
+f 2430//1738 2429//1735 2444//1751
+f 2436//1737 2435//1733 2451//1752
+f 2431//1713 2430//1738 2445//1753
+f 2437//1739 2436//1737 2452//1754
+f 2451//1752 2450//1750 2466//1755
+f 2446//1740 2445//1753 2460//1756
+f 2452//1754 2451//1752 2467//1757
+f 2447//1743 2446//1740 2461//1758
+f 2442//1744 2441//1741 2456//1759
+f 2453//1742 2452//1754 2468//1760
+f 2448//1761 2447//1743 2462//1762
+f 2443//1748 2442//1744 2457//1763
+f 2454//1745 2453//1742 2469//1764
+f 2449//1747 2448//1761 2464//1765
+f 2444//1751 2443//1748 2458//1766
+f 2455//1749 2454//1745 2470//1767
+f 2450//1750 2449//1747 2465//1768
+f 2445//1753 2444//1751 2459//1769
+f 2470//1767 2469//1764 2485//1770
+f 2465//1768 2464//1765 2480//1771
+f 2460//1756 2459//1769 2474//1772
+f 2466//1755 2465//1768 2481//1773
+f 2461//1758 2460//1756 2475//1774
+f 2467//1757 2466//1755 2482//1775
+f 2462//1762 2461//1758 2476//1776
+f 2457//1763 2456//1759 2471//1777
+f 2468//1760 2467//1757 2483//1778
+f 2463//1779 2462//1762 2477//1780
+f 2458//1766 2457//1763 2472//1781
+f 2469//1764 2468//1760 2484//1782
+f 2464//1765 2463//1779 2479//1783
+f 2459//1769 2458//1766 2473//1784
+f 2473//1784 2472//1781 2487//1785
+f 2484//1782 2483//1778 2499//1786
+f 2479//1783 2478//1787 2494//1788
+f 2474//1772 2473//1784 2488//1789
+f 2485//1770 2484//1782 2500//1790
+f 2480//1771 2479//1783 2495//1791
+f 2475//1774 2474//1772 2489//1792
+f 2481//1773 2480//1771 2496//1793
+f 2476//1776 2475//1774 2490//1794
+f 2482//1775 2481//1773 2497//1795
+f 2477//1780 2476//1776 2491//1796
+f 2472//1781 2471//1777 2486//1797
+f 2483//1778 2482//1775 2498//1798
+f 2478//1787 2477//1780 2492//1799
+f 2492//1799 2491//1796 2506//1800
+f 2487//1785 2486//1797 2501//1801
+f 2498//1798 2497//1795 2513//1802
+f 2493//1803 2492//1799 2507//1804
+f 2488//1789 2487//1785 2502//1805
+f 2499//1786 2498//1798 2514//1806
+f 2494//1788 2493//1803 2509//1807
+f 2489//1792 2488//1789 2503//1808
+f 2500//1790 2499//1786 2515//1809
+f 2495//1791 2494//1788 2510//1810
+f 2490//1794 2489//1792 2504//1811
+f 2496//1793 2495//1791 2511//1812
+f 2491//1796 2490//1794 2505//1813
+f 2497//1795 2496//1793 2512//1814
+f 2511//1812 2510//1810 2526//1815
+f 2506//1800 2505//1813 2520//1816
+f 2512//1814 2511//1812 2527//1817
+f 2507//1804 2506//1800 2521//1818
+f 2502//1805 2501//1801 2516//1819
+f 2513//1802 2512//1814 2528//1820
+f 2508//1821 2507//1804 2522//1822
+f 2503//1808 2502//1805 2517//1823
+f 2514//1806 2513//1802 2529//1824
+f 2509//1807 2508//1821 2524//1825
+f 2504//1811 2503//1808 2518//1826
+f 2515//1809 2514//1806 2530//1827
+f 2510//1810 2509//1807 2525//1828
+f 2505//1813 2504//1811 2519//1829
+f 2530//1827 2529//1824 2544//1830
+f 2525//1828 2524//1825 2540//1831
+f 2520//1816 2519//1829 2535//1832
+f 2526//1815 2525//1828 2541//1833
+f 2521//1818 2520//1816 2536//1834
+f 2527//1817 2526//1815 2542//1835
+f 2522//1822 2521//1818 2537//1836
+f 2517//1823 2516//1819 2532//1837
+f 2528//1820 2527//1817 2542//1835
+f 2523//1838 2522//1822 2538//1839
+f 2518//1826 2517//1823 2533//1840
+f 2529//1824 2528//1820 2543//1841
+f 2524//1825 2523//1838 2539//1842
+f 2519//1829 2518//1826 2534//1843
+f 2544//1830 2543//1841 2558//1844
+f 2539//1842 2538//1839 2554//1845
+f 2534//1843 2533//1840 2549//1846
+f 2545//1847 2544//1830 2559//1848
+f 2540//1831 2539//1842 2554//1845
+f 2535//1832 2534//1843 2550//1849
+f 2541//1833 2540//1831 2555//1850
+f 2536//1834 2535//1832 2551//1851
+f 2542//1835 2541//1833 2556//1852
+f 2537//1836 2536//1834 2552//1853
+f 2532//1837 2531//1854 2547//1855
+f 2543//1841 2542//1835 2557//1856
+f 2538//1839 2537//1836 2553//1857
+f 2533//1840 2532//1837 2548//1858
+f 2547//1855 2546//1859 2562//1860
+f 2558//1844 2557//1856 2572//1861
+f 2553//1857 2552//1853 2568//1862
+f 2548//1858 2547//1855 2563//1863
+f 2559//1848 2558//1844 2573//1864
+f 2554//1845 2553//1857 2568//1862
+f 2549//1846 2548//1858 2564//1865
+f 2560//1866 2559//1848 2574//1867
+f 2555//1850 2554//1845 2569//1868
+f 2550//1849 2549//1846 2565//1869
+f 2556//1852 2555//1850 2570//1870
+f 2551//1851 2550//1849 2566//1871
+f 2557//1856 2556//1852 2571//1872
+f 2552//1853 2551//1851 2567//1873
+f 2566//1871 2565//1869 2581//1874
+f 2572//1861 2571//1872 2586//1875
+f 2567//1873 2566//1871 2582//1876
+f 2562//1860 2561//1877 2577//1878
+f 2573//1864 2572//1861 2587//1879
+f 2568//1862 2567//1873 2583//1880
+f 2563//1863 2562//1860 2578//1881
+f 2574//1867 2573//1864 2588//1882
+f 2569//1868 2568//1862 2583//1880
+f 2564//1865 2563//1863 2579//1883
+f 2575//1884 2574//1867 2589//1885
+f 2570//1870 2569//1868 2584//1886
+f 2565//1869 2564//1865 2580//1887
+f 2571//1872 2570//1870 2585//1888
+f 2585//1888 2584//1886 2599//1889
+f 2580//1887 2579//1883 2595//1890
+f 2586//1875 2585//1888 2600//1891
+f 2581//1874 2580//1887 2596//1892
+f 2587//1879 2586//1875 2601//1893
+f 2582//1876 2581//1874 2597//1894
+f 2577//1878 2576//1895 2592//1896
+f 2588//1882 2587//1879 2602//1897
+f 2583//1880 2582//1876 2598//1898
+f 2578//1881 2577//1878 2593//1899
+f 2589//1885 2588//1882 2603//1900
+f 2584//1886 2583//1880 2598//1898
+f 2579//1883 2578//1881 2594//1901
+f 2590//1902 2589//1885 2604//1903
+f 2604//1903 2603//1900 2618//1904
+f 2599//1889 2598//1898 2614//1905
+f 2594//1901 2593//1899 2609//1906
+f 2605//1907 2604//1903 2619//1908
+f 2600//1891 2599//1889 2614//1905
+f 2595//1890 2594//1901 2610//1909
+f 2601//1893 2600//1891 2615//1910
+f 2596//1892 2595//1890 2611//1911
+f 2602//1897 2601//1893 2616//1912
+f 2597//1894 2596//1892 2612//1913
+f 2592//1896 2591//1914 2607//1915
+f 2603//1900 2602//1897 2617//1916
+f 2598//1898 2597//1894 2613//1917
+f 2593//1899 2592//1896 2608//1918
+f 2607//1915 2606//1919 2622//1920
+f 2618//1904 2617//1916 2632//1921
+f 2613//1917 2612//1913 2628//1922
+f 2608//1918 2607//1915 2623//1923
+f 2619//1908 2618//1904 2633//1924
+f 2614//1905 2613//1917 2629//1925
+f 2609//1906 2608//1918 2624//1926
+f 2620//1927 2619//1908 2634//1928
+f 2615//1910 2614//1905 2629//1925
+f 2610//1909 2609//1906 2625//1929
+f 2616//1912 2615//1910 2630//1930
+f 2611//1911 2610//1909 2626//1931
+f 2617//1916 2616//1912 2631//1932
+f 2612//1913 2611//1911 2627//1933
+f 2626//1931 2625//1929 2641//1934
+f 2632//1921 2631//1932 2646//1935
+f 2627//1933 2626//1931 2642//1936
+f 2622//1920 2621//1937 2637//1938
+f 2633//1924 2632//1921 2647//1939
+f 2628//1922 2627//1933 2643//1940
+f 2623//1923 2622//1920 2638//1941
+f 2634//1928 2633//1924 2648//1942
+f 2629//1925 2628//1922 2644//1943
+f 2624//1926 2623//1923 2639//1944
+f 2635//1945 2634//1928 2649//1946
+f 2630//1930 2629//1925 2644//1943
+f 2625//1929 2624//1926 2640//1947
+f 2631//1932 2630//1930 2645//1948
+f 2645//1948 2644//1943 2660//1949
+f 2640//1947 2639//1944 2655//1950
+f 2646//1935 2645//1948 2661//1951
+f 2641//1934 2640//1947 2656//1952
+f 2647//1939 2646//1935 2662//1953
+f 2642//1936 2641//1934 2657//1954
+f 2637//1938 2636//1955 2651//1956
+f 2648//1942 2647//1939 2663//1957
+f 2643//1940 2642//1936 2658//1958
+f 2638//1941 2637//1938 2653//1959
+f 2649//1946 2648//1942 2664//1960
+f 2644//1943 2643//1940 2659//1961
+f 2639//1944 2638//1941 2654//1962
+f 2650//1963 2649//1946 2665//1964
+f 2664//1960 2663//1957 2679//1965
+f 2659//1961 2658//1958 2674//1966
+f 2654//1962 2653//1959 2668//1967
+f 2665//1964 2664//1960 2680//1968
+f 2660//1949 2659//1961 2675//1969
+f 2655//1950 2654//1962 2669//1970
+f 2661//1951 2660//1949 2676//1971
+f 2656//1952 2655//1950 2670//1972
+f 2662//1953 2661//1951 2677//1973
+f 2657//1954 2656//1952 2671//1974
+f 2652//1975 2651//1956 2666//1976
+f 2663//1957 2662//1953 2678//1977
+f 2658//1958 2657//1954 2673//1978
+f 2653//1959 2652//1975 2667//1979
+f 2678//1977 2677//1973 2693//1980
+f 2673//1978 2672//1981 2687//1982
+f 2668//1967 2667//1979 2682//1983
+f 2679//1965 2678//1977 2694//1984
+f 2674//1966 2673//1978 2689//1985
+f 2669//1970 2668//1967 2683//1986
+f 2680//1968 2679//1965 2695//1987
+f 2675//1969 2674//1966 2690//1988
+f 2670//1972 2669//1970 2684//1989
+f 2676//1971 2675//1969 2691//1990
+f 2671//1974 2670//1972 2685//1991
+f 2677//1973 2676//1971 2692//1992
+f 2672//1981 2671//1974 2686//1993
+f 2667//1979 2666//1976 2681//1994
+f 2692//1992 2691//1990 2707//1995
+f 2687//1982 2686//1993 2701//1996
+f 2682//1983 2681//1994 2696//1997
+f 2693//1980 2692//1992 2708//1998
+f 2688//1999 2687//1982 2702//2000
+f 2683//1986 2682//1983 2697//2001
+f 2694//1984 2693//1980 2709//2002
+f 2689//1985 2688//1999 2704//2003
+f 2684//1989 2683//1986 2698//2004
+f 2695//1987 2694//1984 2710//2005
+f 2690//1988 2689//1985 2705//2006
+f 2685//1991 2684//1989 2699//2007
+f 2691//1990 2690//1988 2706//2008
+f 2686//1993 2685//1991 2700//2009
+f 2700//2009 2699//2007 2714//2010
+f 2706//2008 2705//2006 2721//2011
+f 2701//1996 2700//2009 2715//2012
+f 2707//1995 2706//2008 2722//2013
+f 2702//2000 2701//1996 2716//2014
+f 2697//2001 2696//1997 2711//2015
+f 2708//1998 2707//1995 2723//2016
+f 2703//2017 2702//2000 2717//2018
+f 2698//2004 2697//2001 2712//2019
+f 2709//2002 2708//1998 2724//2020
+f 2704//2003 2703//2017 2719//2021
+f 2699//2007 2698//2004 2713//2022
+f 2710//2005 2709//2002 2725//2023
+f 2705//2006 2704//2003 2720//2024
+f 2719//2021 2718//2025 2734//2026
+f 2714//2010 2713//2022 2728//2027
+f 2725//2023 2724//2020 2740//2028
+f 2720//2024 2719//2021 2735//2029
+f 2715//2012 2714//2010 2729//2030
+f 2721//2011 2720//2024 2736//2031
+f 2716//2014 2715//2012 2730//2032
+f 2722//2013 2721//2011 2737//2033
+f 2717//2018 2716//2014 2731//2034
+f 2712//2019 2711//2015 2726//2035
+f 2723//2016 2722//2013 2738//2036
+f 2718//2025 2717//2018 2732//2037
+f 2713//2022 2712//2019 2727//2038
+f 2724//2020 2723//2016 2739//2039
+f 2738//2036 2737//2033 2754//2040
+f 2733//2041 2732//2037 2748//2042
+f 2728//2027 2727//2038 2743//2043
+f 2739//2039 2738//2036 2755//2044
+f 2734//2026 2733//2041 2750//2045
+f 2729//2030 2728//2027 2744//2046
+f 2740//2028 2739//2039 2756//2047
+f 2735//2029 2734//2026 2751//2048
+f 2730//2032 2729//2030 2745//2049
+f 2736//2031 2735//2029 2752//2050
+f 2731//2034 2730//2032 2746//2051
+f 2737//2033 2736//2031 2753//2052
+f 2732//2037 2731//2034 2747//2053
+f 2727//2038 2726//2035 2742//2054
+f 2753//2052 2752//2050 2768//2055
+f 2748//2042 2747//2053 2762//2056
+f 2743//2043 2742//2054 2757//2057
+f 2754//2040 2753//2052 2769//2058
+f 2749//2059 2748//2042 2763//2060
+f 2744//2046 2743//2043 2758//2061
+f 2755//2044 2754//2040 2770//2062
+f 2750//2045 2749//2059 2765//2063
+f 2745//2049 2744//2046 2759//2064
+f 2756//2047 2755//2044 2771//2065
+f 2751//2048 2750//2045 2766//2066
+f 2746//2051 2745//2049 2760//2067
+f 2752//2050 2751//2048 2767//2068
+f 2747//2053 2746//2051 2761//2069
+f 2761//2069 2760//2067 2775//2070
+f 2767//2068 2766//2066 2781//2071
+f 2762//2056 2761//2069 2776//2072
+f 2768//2055 2767//2068 2782//2073
+f 2763//2060 2762//2056 2777//2074
+f 2758//2061 2757//2057 2773//2075
+f 2769//2058 2768//2055 2783//2076
+f 2764//2077 2763//2060 2778//2078
+f 2759//2064 2758//2061 2774//2079
+f 2770//2062 2769//2058 2784//2080
+f 2765//2063 2764//2077 2779//2081
+f 2760//2067 2759//2064 2775//2070
+f 2771//2065 2770//2062 2785//2082
+f 2766//2066 2765//2063 2780//2083
+f 2780//2083 2779//2081 2794//2084
+f 2775//2070 2774//2079 2790//2085
+f 2786//2086 2785//2082 2800//2087
+f 2781//2071 2780//2083 2795//2088
+f 2776//2072 2775//2070 2791//2089
+f 2782//2073 2781//2071 2796//2090
+f 2777//2074 2776//2072 2792//2091
+f 2783//2076 2782//2073 2797//2092
+f 2778//2078 2777//2074 2793//2093
+f 2773//2075 2772//2094 2788//2095
+f 2784//2080 2783//2076 2798//2096
+f 2779//2081 2778//2078 2793//2093
+f 2774//2079 2773//2075 2789//2097
+f 2785//2082 2784//2080 2799//2098
+f 2799//2098 2798//2096 2813//2099
+f 2794//2084 2793//2093 2809//2100
+f 2789//2097 2788//2095 2804//2101
+f 2800//2087 2799//2098 2814//2102
+f 2795//2088 2794//2084 2809//2100
+f 2790//2085 2789//2097 2805//2103
+f 2801//2104 2800//2087 2815//2105
+f 2796//2090 2795//2088 2810//2106
+f 2791//2089 2790//2085 2806//2107
+f 2797//2092 2796//2090 2811//2108
+f 2792//2091 2791//2089 2807//2109
+f 2798//2096 2797//2092 2812//2110
+f 2793//2093 2792//2091 2808//2111
+f 2788//2095 2787//2112 2803//2113
+f 2813//2099 2812//2110 2827//2114
+f 2808//2111 2807//2109 2823//2115
+f 2803//2113 2802//2116 2818//2117
+f 2814//2102 2813//2099 2828//2118
+f 2809//2100 2808//2111 2824//2119
+f 2804//2101 2803//2113 2819//2120
+f 2815//2105 2814//2102 2829//2121
+f 2810//2106 2809//2100 2824//2119
+f 2805//2103 2804//2101 2820//2122
+f 2816//2123 2815//2105 2830//2124
+f 2811//2108 2810//2106 2825//2125
+f 2806//2107 2805//2103 2821//2126
+f 2812//2110 2811//2108 2826//2127
+f 2807//2109 2806//2107 2822//2128
+f 2827//2114 2826//2127 2841//2129
+f 2822//2128 2821//2126 2837//2130
+f 2828//2118 2827//2114 2842//2131
+f 2823//2115 2822//2128 2838//2132
+f 2818//2117 2817//2133 2833//2134
+f 2829//2121 2828//2118 2843//2135
+f 2824//2119 2823//2115 2839//2136
+f 2819//2120 2818//2117 2834//2137
+f 2830//2124 2829//2121 2844//2138
+f 2825//2125 2824//2119 2839//2136
+f 2820//2122 2819//2120 2835//2139
+f 2831//2140 2830//2124 2845//2141
+f 2826//2127 2825//2125 2840//2142
+f 2821//2126 2820//2122 2836//2143
+f 2835//2139 2834//2137 2850//2144
+f 2846//2145 2845//2141 2860//2146
+f 2841//2129 2840//2142 2855//2147
+f 2836//2143 2835//2139 2851//2148
+f 2842//2131 2841//2129 2856//2149
+f 2837//2130 2836//2143 2852//2150
+f 2843//2135 2842//2131 2857//2151
+f 2838//2132 2837//2130 2853//2152
+f 2833//2134 2832//2153 2848//2154
+f 2844//2138 2843//2135 2858//2155
+f 2839//2136 2838//2132 2853//2152
+f 2834//2137 2833//2134 2849//2156
+f 2845//2141 2844//2138 2859//2157
+f 2840//2142 2839//2136 2854//2158
+f 2854//2158 2853//2152 2869//2159
+f 2849//2156 2848//2154 2865//2160
+f 2860//2146 2859//2157 2875//2161
+f 2855//2147 2854//2158 2870//2162
+f 2850//2144 2849//2156 2866//2163
+f 2861//2164 2860//2146 2876//2165
+f 2856//2149 2855//2147 2871//2166
+f 2851//2148 2850//2144 2867//2167
+f 2857//2151 2856//2149 2872//2168
+f 2852//2150 2851//2148 2868//2169
+f 2858//2155 2857//2151 2873//2170
+f 2853//2152 2852//2150 2869//2159
+f 2848//2154 2847//2171 2864//2172
+f 2859//2157 2858//2155 2874//2173
+f 2874//2173 2873//2170 2888//2174
+f 2869//2159 2868//2169 2884//2175
+f 2864//2172 2863//2176 2879//2177
+f 2875//2161 2874//2173 2889//2178
+f 2870//2162 2869//2159 2884//2175
+f 2865//2160 2864//2172 2880//2179
+f 2876//2165 2875//2161 2890//2180
+f 2871//2166 2870//2162 2885//2181
+f 2866//2163 2865//2160 2881//2182
+f 2877//2183 2876//2165 2891//2184
+f 2872//2168 2871//2166 2886//2185
+f 2867//2167 2866//2163 2882//2186
+f 2873//2170 2872//2168 2887//2187
+f 2868//2169 2867//2167 2883//2188
+f 2741//2189 2425//1730 2440//1731
+f 2411//1715 2862//2190 2426//1716
+f 2741//2189 2440//1731 2455//1749
+f 2426//1716 2862//2190 2441//1741
+f 2441//1741 2862//2190 2456//1759
+f 2741//2189 2455//1749 2470//1767
+f 2741//2189 2470//1767 2485//1770
+f 2456//1759 2862//2190 2471//1777
+f 2741//2189 2485//1770 2500//1790
+f 2471//1777 2862//2190 2486//1797
+f 2741//2189 2500//1790 2515//1809
+f 2486//1797 2862//2190 2501//1801
+f 2501//1801 2862//2190 2516//1819
+f 2741//2189 2515//1809 2530//1827
+f 2741//2189 2530//1827 2545//1847
+f 2516//1819 2862//2190 2531//1854
+f 2741//2189 2545//1847 2560//1866
+f 2531//1854 2862//2190 2546//1859
+f 2741//2189 2560//1866 2575//1884
+f 2546//1859 2862//2190 2561//1877
+f 2561//1877 2862//2190 2576//1895
+f 2741//2189 2575//1884 2590//1902
+f 2741//2189 2590//1902 2605//1907
+f 2576//1895 2862//2190 2591//1914
+f 2741//2189 2605//1907 2620//1927
+f 2591//1914 2862//2190 2606//1919
+f 2741//2189 2620//1927 2635//1945
+f 2606//1919 2862//2190 2621//1937
+f 2621//1937 2862//2190 2636//1955
+f 2741//2189 2635//1945 2650//1963
+f 2741//2189 2650//1963 2665//1964
+f 2636//1955 2862//2190 2651//1956
+f 2741//2189 2665//1964 2680//1968
+f 2651//1956 2862//2190 2666//1976
+f 2741//2189 2680//1968 2695//1987
+f 2666//1976 2862//2190 2681//1994
+f 2681//1994 2862//2190 2696//1997
+f 2741//2189 2695//1987 2710//2005
+f 2741//2189 2710//2005 2725//2023
+f 2696//1997 2862//2190 2711//2015
+f 2741//2189 2725//2023 2740//2028
+f 2711//2015 2862//2190 2726//2035
+f 2741//2189 2740//2028 2756//2047
+f 2726//2035 2862//2190 2742//2054
+f 2742//2054 2862//2190 2757//2057
+f 2741//2189 2756//2047 2771//2065
+f 2741//2189 2771//2065 2786//2086
+f 2757//2057 2862//2190 2772//2094
+f 2741//2189 2786//2086 2801//2104
+f 2772//2094 2862//2190 2787//2112
+f 2741//2189 2801//2104 2816//2123
+f 2787//2112 2862//2190 2802//2116
+f 2741//2189 2816//2123 2831//2140
+f 2802//2116 2862//2190 2817//2133
+f 2741//2189 2831//2140 2846//2145
+f 2817//2133 2862//2190 2832//2153
+f 2741//2189 2846//2145 2861//2164
+f 2832//2153 2862//2190 2847//2171
+f 2741//2189 2861//2164 2877//2183
+f 2847//2171 2862//2190 2863//2176
+f 2741//2189 2877//2183 2892//2191
+f 2863//2176 2862//2190 2878//2192
+f 2741//2189 2892//2191 2425//1730
+f 2888//2174 2887//2187 2420//1732
+f 2883//2188 2882//2186 2415//1734
+f 2878//2192 2862//2190 2411//1715
+f 2889//2178 2888//2174 2421//1736
+f 2884//2175 2883//2188 2416//1712
+f 2879//2177 2878//2192 2411//1715
+f 2890//2180 2889//2178 2422//1718
+f 2885//2181 2884//2175 2417//1711
+f 2880//2179 2879//2177 2412//1714
+f 2891//2184 2890//2180 2423//1717
+f 2886//2185 2885//2181 2418//1720
+f 2881//2182 2880//2179 2413//1722
+f 2892//2191 2891//2184 2425//1730
+f 2887//2187 2886//2185 2419//1726
+f 2882//2186 2881//2182 2414//1728
+f 2899//1711 2898//2193 2913//1713
+f 2894//1714 2893//1715 2908//2194
+f 2905//2195 2904//1718 2920//1719
+f 2900//1720 2899//1711 2914//1721
+f 2895//1722 2894//1714 2909//2196
+f 2906//1724 2905//2195 2921//1725
+f 2901//1726 2900//1720 2915//1727
+f 2896//1728 2895//1722 2910//2197
+f 2907//2198 2906//1724 2922//2199
+f 2902//1732 2901//1726 2917//1733
+f 2897//1734 2896//1728 2911//1735
+f 2903//2200 2902//1732 2918//1737
+f 2898//2193 2897//1734 2912//1738
+f 2904//1718 2903//2200 2919//1739
+f 2914//1721 2913//1713 2928//1740
+f 2909//2196 2908//2194 2923//2201
+f 2920//1719 2919//1739 2935//2202
+f 2915//1727 2914//1721 2929//1743
+f 2910//2197 2909//2196 2924//1744
+f 2921//1725 2920//1719 2936//2203
+f 2916//1746 2915//1727 2931//1747
+f 2911//1735 2910//2197 2925//1748
+f 2922//2199 2921//1725 2937//1749
+f 2917//1733 2916//1746 2932//1750
+f 2912//1738 2911//1735 2926//1751
+f 2918//1737 2917//1733 2933//1752
+f 2913//1713 2912//1738 2927//2204
+f 2919//1739 2918//1737 2934//2205
+f 2933//1752 2932//1750 2948//2206
+f 2928//1740 2927//2204 2942//1756
+f 2934//2205 2933//1752 2949//2207
+f 2929//1743 2928//1740 2943//1758
+f 2924//1744 2923//2201 2938//2208
+f 2935//2202 2934//2205 2950//1760
+f 2930//2209 2929//1743 2944//1762
+f 2925//1748 2924//1744 2939//2210
+f 2936//2203 2935//2202 2951//1764
+f 2931//1747 2930//2209 2946//1765
+f 2926//1751 2925//1748 2940//1766
+f 2937//1749 2936//2203 2952//2211
+f 2932//1750 2931//1747 2947//2212
+f 2927//2204 2926//1751 2941//2213
+f 2952//2211 2951//1764 2967//1770
+f 2947//2212 2946//1765 2962//2214
+f 2942//1756 2941//2213 2956//1772
+f 2948//2206 2947//2212 2963//2215
+f 2943//1758 2942//1756 2957//1774
+f 2949//2207 2948//2206 2964//1775
+f 2944//1762 2943//1758 2958//1776
+f 2939//2210 2938//2208 2953//2216
+f 2950//1760 2949//2207 2965//1778
+f 2945//1779 2944//1762 2959//1780
+f 2940//1766 2939//2210 2954//1781
+f 2951//1764 2950//1760 2966//1782
+f 2946//1765 2945//1779 2961//2217
+f 2941//2213 2940//1766 2955//2218
+f 2955//2218 2954//1781 2969//1785
+f 2966//1782 2965//1778 2981//1786
+f 2961//2217 2960//1787 2976//1788
+f 2956//1772 2955//2218 2970//2219
+f 2967//1770 2966//1782 2982//2220
+f 2962//2214 2961//2217 2977//1791
+f 2957//1774 2956//1772 2971//1792
+f 2963//2215 2962//2214 2978//1793
+f 2958//1776 2957//1774 2972//2221
+f 2964//1775 2963//2215 2979//1795
+f 2959//1780 2958//1776 2973//1796
+f 2954//1781 2953//2216 2968//1797
+f 2965//1778 2964//1775 2980//2222
+f 2960//1787 2959//1780 2974//1799
+f 2974//1799 2973//1796 2988//1800
+f 2969//1785 2968//1797 2983//1801
+f 2980//2222 2979//1795 2995//1802
+f 2975//1803 2974//1799 2989//1804
+f 2970//2219 2969//1785 2984//1805
+f 2981//1786 2980//2222 2996//1806
+f 2976//1788 2975//1803 2991//1807
+f 2971//1792 2970//2219 2985//1808
+f 2982//2220 2981//1786 2997//2223
+f 2977//1791 2976//1788 2992//1810
+f 2972//2221 2971//1792 2986//1811
+f 2978//1793 2977//1791 2993//1812
+f 2973//1796 2972//2221 2987//1813
+f 2979//1795 2978//1793 2994//1814
+f 2993//1812 2992//1810 3008//2224
+f 2988//1800 2987//1813 3002//1816
+f 2994//1814 2993//1812 3009//1817
+f 2989//1804 2988//1800 3003//1818
+f 2984//1805 2983//1801 2998//1819
+f 2995//1802 2994//1814 3010//1820
+f 2990//1821 2989//1804 3004//1822
+f 2985//1808 2984//1805 2999//1823
+f 2996//1806 2995//1802 3011//1824
+f 2991//1807 2990//1821 3006//1825
+f 2986//1811 2985//1808 3000//1826
+f 2997//2223 2996//1806 3012//1827
+f 2992//1810 2991//1807 3007//1828
+f 2987//1813 2986//1811 3001//1829
+f 3012//1827 3011//1824 3026//2225
+f 3007//1828 3006//1825 3022//1831
+f 3002//1816 3001//1829 3017//1832
+f 3008//2224 3007//1828 3023//1833
+f 3003//1818 3002//1816 3018//1834
+f 3009//1817 3008//2224 3024//1835
+f 3004//1822 3003//1818 3019//1836
+f 2999//1823 2998//1819 3014//1837
+f 3010//1820 3009//1817 3024//1835
+f 3005//2226 3004//1822 3020//1839
+f 3000//1826 2999//1823 3015//1840
+f 3011//1824 3010//1820 3025//1841
+f 3006//1825 3005//2226 3021//1842
+f 3001//1829 3000//1826 3016//1843
+f 3026//2225 3025//1841 3040//1844
+f 3021//1842 3020//1839 3036//1845
+f 3016//1843 3015//1840 3031//1846
+f 3027//1847 3026//2225 3041//1848
+f 3022//1831 3021//1842 3036//1845
+f 3017//1832 3016//1843 3032//2227
+f 3023//1833 3022//1831 3037//2228
+f 3018//1834 3017//1832 3033//1851
+f 3024//1835 3023//1833 3038//1852
+f 3019//1836 3018//1834 3034//1853
+f 3014//1837 3013//1854 3029//1855
+f 3025//1841 3024//1835 3039//1856
+f 3020//1839 3019//1836 3035//2229
+f 3015//1840 3014//1837 3030//1858
+f 3029//1855 3028//1859 3044//1860
+f 3040//1844 3039//1856 3054//2230
+f 3035//2229 3034//1853 3050//1862
+f 3030//1858 3029//1855 3045//1863
+f 3041//1848 3040//1844 3055//2231
+f 3036//1845 3035//2229 3050//1862
+f 3031//1846 3030//1858 3046//1865
+f 3042//1866 3041//1848 3056//1867
+f 3037//2228 3036//1845 3051//2232
+f 3032//2227 3031//1846 3047//1869
+f 3038//1852 3037//2228 3052//1870
+f 3033//1851 3032//2227 3048//2233
+f 3039//1856 3038//1852 3053//1872
+f 3034//1853 3033//1851 3049//2234
+f 3048//2233 3047//1869 3063//1874
+f 3054//2230 3053//1872 3068//1875
+f 3049//2234 3048//2233 3064//1876
+f 3044//1860 3043//1877 3059//1878
+f 3055//2231 3054//2230 3069//1879
+f 3050//1862 3049//2234 3065//2235
+f 3045//1863 3044//1860 3060//1881
+f 3056//1867 3055//2231 3070//2236
+f 3051//2232 3050//1862 3065//2235
+f 3046//1865 3045//1863 3061//1883
+f 3057//1884 3056//1867 3071//1885
+f 3052//1870 3051//2232 3066//1886
+f 3047//1869 3046//1865 3062//1887
+f 3053//1872 3052//1870 3067//2237
+f 3067//2237 3066//1886 3081//2238
+f 3062//1887 3061//1883 3077//2239
+f 3068//1875 3067//2237 3082//1891
+f 3063//1874 3062//1887 3078//1892
+f 3069//1879 3068//1875 3083//1893
+f 3064//1876 3063//1874 3079//1894
+f 3059//1878 3058//1895 3074//1896
+f 3070//2236 3069//1879 3084//1897
+f 3065//2235 3064//1876 3080//1898
+f 3060//1881 3059//1878 3075//1899
+f 3071//1885 3070//2236 3085//1900
+f 3066//1886 3065//2235 3080//1898
+f 3061//1883 3060//1881 3076//1901
+f 3072//1902 3071//1885 3086//1903
+f 3086//1903 3085//1900 3100//1904
+f 3081//2238 3080//1898 3096//1905
+f 3076//1901 3075//1899 3091//1906
+f 3087//1907 3086//1903 3101//1908
+f 3082//1891 3081//2238 3096//1905
+f 3077//2239 3076//1901 3092//1909
+f 3083//1893 3082//1891 3097//1910
+f 3078//1892 3077//2239 3093//1911
+f 3084//1897 3083//1893 3098//1912
+f 3079//1894 3078//1892 3094//1913
+f 3074//1896 3073//2240 3089//1915
+f 3085//1900 3084//1897 3099//1916
+f 3080//1898 3079//1894 3095//1917
+f 3075//1899 3074//1896 3090//2241
+f 3089//1915 3088//2242 3104//2243
+f 3100//1904 3099//1916 3114//1921
+f 3095//1917 3094//1913 3110//1922
+f 3090//2241 3089//1915 3105//1923
+f 3101//1908 3100//1904 3115//1924
+f 3096//1905 3095//1917 3111//1925
+f 3091//1906 3090//2241 3106//2244
+f 3102//1927 3101//1908 3116//1928
+f 3097//1910 3096//1905 3111//1925
+f 3092//1909 3091//1906 3107//1929
+f 3098//1912 3097//1910 3112//2245
+f 3093//1911 3092//1909 3108//1931
+f 3099//1916 3098//1912 3113//1932
+f 3094//1913 3093//1911 3109//1933
+f 3108//1931 3107//1929 3123//1934
+f 3114//1921 3113//1932 3128//1935
+f 3109//1933 3108//1931 3124//1936
+f 3104//2243 3103//2246 3119//1938
+f 3115//1924 3114//1921 3129//1939
+f 3110//1922 3109//1933 3125//1940
+f 3105//1923 3104//2243 3120//1941
+f 3116//1928 3115//1924 3130//1942
+f 3111//1925 3110//1922 3126//1943
+f 3106//2244 3105//1923 3121//1944
+f 3117//2247 3116//1928 3131//1946
+f 3112//2245 3111//1925 3126//1943
+f 3107//1929 3106//2244 3122//2248
+f 3113//1932 3112//2245 3127//1948
+f 3127//1948 3126//1943 3142//1949
+f 3122//2248 3121//1944 3137//1950
+f 3128//1935 3127//1948 3143//1951
+f 3123//1934 3122//2248 3138//2249
+f 3129//1939 3128//1935 3144//1953
+f 3124//1936 3123//1934 3139//1954
+f 3119//1938 3118//2250 3133//2251
+f 3130//1942 3129//1939 3145//1957
+f 3125//1940 3124//1936 3140//1958
+f 3120//1941 3119//1938 3135//1959
+f 3131//1946 3130//1942 3146//1960
+f 3126//1943 3125//1940 3141//1961
+f 3121//1944 3120//1941 3136//1962
+f 3132//2252 3131//1946 3147//1964
+f 3146//1960 3145//1957 3161//2253
+f 3141//1961 3140//1958 3156//1966
+f 3136//1962 3135//1959 3150//1967
+f 3147//1964 3146//1960 3162//1968
+f 3142//1949 3141//1961 3157//1969
+f 3137//1950 3136//1962 3151//1970
+f 3143//1951 3142//1949 3158//1971
+f 3138//2249 3137//1950 3152//2254
+f 3144//1953 3143//1951 3159//1973
+f 3139//1954 3138//2249 3153//1974
+f 3134//1975 3133//2251 3148//1976
+f 3145//1957 3144//1953 3160//1977
+f 3140//1958 3139//1954 3155//1978
+f 3135//1959 3134//1975 3149//1979
+f 3160//1977 3159//1973 3175//1980
+f 3155//1978 3154//1981 3169//2255
+f 3150//1967 3149//1979 3164//1983
+f 3161//2253 3160//1977 3176//1984
+f 3156//1966 3155//1978 3171//2256
+f 3151//1970 3150//1967 3165//1986
+f 3162//1968 3161//2253 3177//2257
+f 3157//1969 3156//1966 3172//1988
+f 3152//2254 3151//1970 3166//2258
+f 3158//1971 3157//1969 3173//1990
+f 3153//1974 3152//2254 3167//1991
+f 3159//1973 3158//1971 3174//1992
+f 3154//1981 3153//1974 3168//1993
+f 3149//1979 3148//1976 3163//1994
+f 3174//1992 3173//1990 3189//2259
+f 3169//2255 3168//1993 3183//2260
+f 3164//1983 3163//1994 3178//1997
+f 3175//1980 3174//1992 3190//1998
+f 3170//2261 3169//2255 3184//2262
+f 3165//1986 3164//1983 3179//2001
+f 3176//1984 3175//1980 3191//2263
+f 3171//2256 3170//2261 3186//2003
+f 3166//2258 3165//1986 3180//2264
+f 3177//2257 3176//1984 3192//2005
+f 3172//1988 3171//2256 3187//2006
+f 3167//1991 3166//2258 3181//2007
+f 3173//1990 3172//1988 3188//2008
+f 3168//1993 3167//1991 3182//2265
+f 3182//2265 3181//2007 3196//2010
+f 3188//2008 3187//2006 3203//2266
+f 3183//2260 3182//2265 3197//2267
+f 3189//2259 3188//2008 3204//2013
+f 3184//2262 3183//2260 3198//2014
+f 3179//2001 3178//1997 3193//2268
+f 3190//1998 3189//2259 3205//2016
+f 3185//2017 3184//2262 3199//2269
+f 3180//2264 3179//2001 3194//2019
+f 3191//2263 3190//1998 3206//2020
+f 3186//2003 3185//2017 3201//2021
+f 3181//2007 3180//2264 3195//2270
+f 3192//2005 3191//2263 3207//2023
+f 3187//2006 3186//2003 3202//2024
+f 3201//2021 3200//2025 3216//2026
+f 3196//2010 3195//2270 3210//2027
+f 3207//2023 3206//2020 3222//2271
+f 3202//2024 3201//2021 3217//2029
+f 3197//2267 3196//2010 3211//2030
+f 3203//2266 3202//2024 3218//2031
+f 3198//2014 3197//2267 3212//2032
+f 3204//2013 3203//2266 3219//2272
+f 3199//2269 3198//2014 3213//2034
+f 3194//2019 3193//2268 3208//2273
+f 3205//2016 3204//2013 3220//2274
+f 3200//2025 3199//2269 3214//2037
+f 3195//2270 3194//2019 3209//2038
+f 3206//2020 3205//2016 3221//2275
+f 3220//2274 3219//2272 3236//2276
+f 3215//2041 3214//2037 3230//2042
+f 3210//2027 3209//2038 3225//2043
+f 3221//2275 3220//2274 3237//2277
+f 3216//2026 3215//2041 3232//2045
+f 3211//2030 3210//2027 3226//2046
+f 3222//2271 3221//2275 3238//2278
+f 3217//2029 3216//2026 3233//2048
+f 3212//2032 3211//2030 3227//2049
+f 3218//2031 3217//2029 3234//2050
+f 3213//2034 3212//2032 3228//2051
+f 3219//2272 3218//2031 3235//2052
+f 3214//2037 3213//2034 3229//2053
+f 3209//2038 3208//2273 3224//2054
+f 3235//2052 3234//2050 3250//2055
+f 3230//2042 3229//2053 3244//2056
+f 3225//2043 3224//2054 3239//2279
+f 3236//2276 3235//2052 3251//2058
+f 3231//2059 3230//2042 3245//2060
+f 3226//2046 3225//2043 3240//2061
+f 3237//2277 3236//2276 3252//2062
+f 3232//2045 3231//2059 3247//2063
+f 3227//2049 3226//2046 3241//2064
+f 3238//2278 3237//2277 3253//2280
+f 3233//2048 3232//2045 3248//2066
+f 3228//2051 3227//2049 3242//2067
+f 3234//2050 3233//2048 3249//2068
+f 3229//2053 3228//2051 3243//2281
+f 3243//2281 3242//2067 3257//2070
+f 3249//2068 3248//2066 3263//2071
+f 3244//2056 3243//2281 3258//2072
+f 3250//2055 3249//2068 3264//2073
+f 3245//2060 3244//2056 3259//2074
+f 3240//2061 3239//2279 3255//2282
+f 3251//2058 3250//2055 3265//2076
+f 3246//2077 3245//2060 3260//2078
+f 3241//2064 3240//2061 3256//2079
+f 3252//2062 3251//2058 3266//2080
+f 3247//2063 3246//2077 3261//2081
+f 3242//2067 3241//2064 3257//2070
+f 3253//2280 3252//2062 3267//2082
+f 3248//2066 3247//2063 3262//2083
+f 3262//2083 3261//2081 3276//2283
+f 3257//2070 3256//2079 3272//2085
+f 3268//2284 3267//2082 3282//2087
+f 3263//2071 3262//2083 3277//2088
+f 3258//2072 3257//2070 3273//2089
+f 3264//2073 3263//2071 3278//2090
+f 3259//2074 3258//2072 3274//2091
+f 3265//2076 3264//2073 3279//2092
+f 3260//2078 3259//2074 3275//2093
+f 3255//2282 3254//2094 3270//2095
+f 3266//2080 3265//2076 3280//2096
+f 3261//2081 3260//2078 3275//2093
+f 3256//2079 3255//2282 3271//2097
+f 3267//2082 3266//2080 3281//2098
+f 3281//2098 3280//2096 3295//2099
+f 3276//2283 3275//2093 3291//2100
+f 3271//2097 3270//2095 3286//2285
+f 3282//2087 3281//2098 3296//2102
+f 3277//2088 3276//2283 3291//2100
+f 3272//2085 3271//2097 3287//2103
+f 3283//2104 3282//2087 3297//2105
+f 3278//2090 3277//2088 3292//2286
+f 3273//2089 3272//2085 3288//2107
+f 3279//2092 3278//2090 3293//2108
+f 3274//2091 3273//2089 3289//2109
+f 3280//2096 3279//2092 3294//2110
+f 3275//2093 3274//2091 3290//2287
+f 3270//2095 3269//2112 3285//2113
+f 3295//2099 3294//2110 3309//2288
+f 3290//2287 3289//2109 3305//2115
+f 3285//2113 3284//2116 3300//2117
+f 3296//2102 3295//2099 3310//2118
+f 3291//2100 3290//2287 3306//2119
+f 3286//2285 3285//2113 3301//2120
+f 3297//2105 3296//2102 3311//2121
+f 3292//2286 3291//2100 3306//2119
+f 3287//2103 3286//2285 3302//2122
+f 3298//2123 3297//2105 3312//2124
+f 3293//2108 3292//2286 3307//2125
+f 3288//2107 3287//2103 3303//2126
+f 3294//2110 3293//2108 3308//2289
+f 3289//2109 3288//2107 3304//2290
+f 3309//2288 3308//2289 3323//2129
+f 3304//2290 3303//2126 3319//2130
+f 3310//2118 3309//2288 3324//2131
+f 3305//2115 3304//2290 3320//2291
+f 3300//2117 3299//2133 3315//2134
+f 3311//2121 3310//2118 3325//2292
+f 3306//2119 3305//2115 3321//2136
+f 3301//2120 3300//2117 3316//2137
+f 3312//2124 3311//2121 3326//2138
+f 3307//2125 3306//2119 3321//2136
+f 3302//2122 3301//2120 3317//2293
+f 3313//2140 3312//2124 3327//2141
+f 3308//2289 3307//2125 3322//2142
+f 3303//2126 3302//2122 3318//2143
+f 3317//2293 3316//2137 3332//2144
+f 3328//2145 3327//2141 3342//2146
+f 3323//2129 3322//2142 3337//2147
+f 3318//2143 3317//2293 3333//2148
+f 3324//2131 3323//2129 3338//2149
+f 3319//2130 3318//2143 3334//2150
+f 3325//2292 3324//2131 3339//2151
+f 3320//2291 3319//2130 3335//2152
+f 3315//2134 3314//2153 3330//2154
+f 3326//2138 3325//2292 3340//2155
+f 3321//2136 3320//2291 3335//2152
+f 3316//2137 3315//2134 3331//2156
+f 3327//2141 3326//2138 3341//2294
+f 3322//2142 3321//2136 3336//2158
+f 3336//2158 3335//2152 3351//2159
+f 3331//2156 3330//2154 3347//2160
+f 3342//2146 3341//2294 3357//2161
+f 3337//2147 3336//2158 3352//2162
+f 3332//2144 3331//2156 3348//2163
+f 3343//2295 3342//2146 3358//2296
+f 3338//2149 3337//2147 3353//2166
+f 3333//2148 3332//2144 3349//2167
+f 3339//2151 3338//2149 3354//2168
+f 3334//2150 3333//2148 3350//2297
+f 3340//2155 3339//2151 3355//2170
+f 3335//2152 3334//2150 3351//2159
+f 3330//2154 3329//2171 3346//2172
+f 3341//2294 3340//2155 3356//2298
+f 3356//2298 3355//2170 3370//2174
+f 3351//2159 3350//2297 3366//2299
+f 3346//2172 3345//2176 3361//2300
+f 3357//2161 3356//2298 3371//2178
+f 3352//2162 3351//2159 3366//2299
+f 3347//2160 3346//2172 3362//2179
+f 3358//2296 3357//2161 3372//2180
+f 3353//2166 3352//2162 3367//2181
+f 3348//2163 3347//2160 3363//2182
+f 3359//2183 3358//2296 3373//2301
+f 3354//2168 3353//2166 3368//2185
+f 3349//2167 3348//2163 3364//2186
+f 3355//2170 3354//2168 3369//2187
+f 3350//2297 3349//2167 3365//2188
+f 3223//2189 2907//2198 2922//2199
+f 2893//1715 3344//2190 2908//2194
+f 3223//2189 2922//2199 2937//1749
+f 2908//2194 3344//2190 2923//2201
+f 2923//2201 3344//2190 2938//2208
+f 3223//2189 2937//1749 2952//2211
+f 3223//2189 2952//2211 2967//1770
+f 2938//2208 3344//2190 2953//2216
+f 3223//2189 2967//1770 2982//2220
+f 2953//2216 3344//2190 2968//1797
+f 3223//2189 2982//2220 2997//2223
+f 2968//1797 3344//2190 2983//1801
+f 2983//1801 3344//2190 2998//1819
+f 3223//2189 2997//2223 3012//1827
+f 3223//2189 3012//1827 3027//1847
+f 2998//1819 3344//2190 3013//1854
+f 3223//2189 3027//1847 3042//1866
+f 3013//1854 3344//2190 3028//1859
+f 3223//2189 3042//1866 3057//1884
+f 3028//1859 3344//2190 3043//1877
+f 3043//1877 3344//2190 3058//1895
+f 3223//2189 3057//1884 3072//1902
+f 3223//2189 3072//1902 3087//1907
+f 3058//1895 3344//2190 3073//2240
+f 3223//2189 3087//1907 3102//1927
+f 3073//2240 3344//2190 3088//2242
+f 3223//2189 3102//1927 3117//2247
+f 3088//2242 3344//2190 3103//2246
+f 3103//2246 3344//2190 3118//2250
+f 3223//2189 3117//2247 3132//2252
+f 3223//2189 3132//2252 3147//1964
+f 3118//2250 3344//2190 3133//2251
+f 3223//2189 3147//1964 3162//1968
+f 3133//2251 3344//2190 3148//1976
+f 3223//2189 3162//1968 3177//2257
+f 3148//1976 3344//2190 3163//1994
+f 3163//1994 3344//2190 3178//1997
+f 3223//2189 3177//2257 3192//2005
+f 3223//2189 3192//2005 3207//2023
+f 3178//1997 3344//2190 3193//2268
+f 3223//2189 3207//2023 3222//2271
+f 3193//2268 3344//2190 3208//2273
+f 3223//2189 3222//2271 3238//2278
+f 3208//2273 3344//2190 3224//2054
+f 3224//2054 3344//2190 3239//2279
+f 3223//2189 3238//2278 3253//2280
+f 3223//2189 3253//2280 3268//2284
+f 3239//2279 3344//2190 3254//2094
+f 3223//2189 3268//2284 3283//2104
+f 3254//2094 3344//2190 3269//2112
+f 3223//2189 3283//2104 3298//2123
+f 3269//2112 3344//2190 3284//2116
+f 3223//2189 3298//2123 3313//2140
+f 3284//2116 3344//2190 3299//2133
+f 3223//2189 3313//2140 3328//2145
+f 3299//2133 3344//2190 3314//2153
+f 3223//2189 3328//2145 3343//2295
+f 3314//2153 3344//2190 3329//2171
+f 3223//2189 3343//2295 3359//2183
+f 3329//2171 3344//2190 3345//2176
+f 3223//2189 3359//2183 3374//2191
+f 3345//2176 3344//2190 3360//2302
+f 3223//2189 3374//2191 2907//2198
+f 3370//2174 3369//2187 2902//1732
+f 3365//2188 3364//2186 2897//1734
+f 3360//2302 3344//2190 2893//1715
+f 3371//2178 3370//2174 2903//2200
+f 3366//2299 3365//2188 2898//2193
+f 3361//2300 3360//2302 2893//1715
+f 3372//2180 3371//2178 2904//1718
+f 3367//2181 3366//2299 2899//1711
+f 3362//2179 3361//2300 2894//1714
+f 3373//2301 3372//2180 2905//2195
+f 3368//2185 3367//2181 2900//1720
+f 3363//2182 3362//2179 2895//1722
+f 3374//2191 3373//2301 2907//2198
+f 3369//2187 3368//2185 2901//1726
+f 3364//2186 3363//2182 2896//1728
+f 2432//1721 2417//1711 2431//1713
+f 2427//1723 2412//1714 2426//1716
+f 2422//1718 2437//1739 2438//1719
+f 2433//1727 2418//1720 2432//1721
+f 2428//1729 2413//1722 2427//1723
+f 2423//1717 2438//1719 2439//1725
+f 2434//1746 2419//1726 2433//1727
+f 2429//1735 2414//1728 2428//1729
+f 2424//1724 2439//1725 2440//1731
+f 2419//1726 2434//1746 2435//1733
+f 2430//1738 2415//1734 2429//1735
+f 2420//1732 2435//1733 2436//1737
+f 2431//1713 2416//1712 2430//1738
+f 2421//1736 2436//1737 2437//1739
+f 2447//1743 2432//1721 2446//1740
+f 2442//1744 2427//1723 2441//1741
+f 2437//1739 2452//1754 2453//1742
+f 2448//1761 2433//1727 2447//1743
+f 2443//1748 2428//1729 2442//1744
+f 2438//1719 2453//1742 2454//1745
+f 2433//1727 2448//1761 2449//1747
+f 2444//1751 2429//1735 2443//1748
+f 2439//1725 2454//1745 2455//1749
+f 2434//1746 2449//1747 2450//1750
+f 2445//1753 2430//1738 2444//1751
+f 2435//1733 2450//1750 2451//1752
+f 2446//1740 2431//1713 2445//1753
+f 2436//1737 2451//1752 2452//1754
+f 2450//1750 2465//1768 2466//1755
+f 2461//1758 2446//1740 2460//1756
+f 2451//1752 2466//1755 2467//1757
+f 2462//1762 2447//1743 2461//1758
+f 2457//1763 2442//1744 2456//1759
+f 2452//1754 2467//1757 2468//1760
+f 2463//1779 2448//1761 2462//1762
+f 2458//1766 2443//1748 2457//1763
+f 2453//1742 2468//1760 2469//1764
+f 2448//1761 2463//1779 2464//1765
+f 2459//1769 2444//1751 2458//1766
+f 2454//1745 2469//1764 2470//1767
+f 2449//1747 2464//1765 2465//1768
+f 2460//1756 2445//1753 2459//1769
+f 2469//1764 2484//1782 2485//1770
+f 2464//1765 2479//1783 2480//1771
+f 2475//1774 2460//1756 2474//1772
+f 2465//1768 2480//1771 2481//1773
+f 2476//1776 2461//1758 2475//1774
+f 2466//1755 2481//1773 2482//1775
+f 2477//1780 2462//1762 2476//1776
+f 2472//1781 2457//1763 2471//1777
+f 2467//1757 2482//1775 2483//1778
+f 2478//1787 2463//1779 2477//1780
+f 2473//1784 2458//1766 2472//1781
+f 2468//1760 2483//1778 2484//1782
+f 2463//1779 2478//1787 2479//1783
+f 2474//1772 2459//1769 2473//1784
+f 2488//1789 2473//1784 2487//1785
+f 2483//1778 2498//1798 2499//1786
+f 2478//1787 2493//1803 2494//1788
+f 2489//1792 2474//1772 2488//1789
+f 2484//1782 2499//1786 2500//1790
+f 2479//1783 2494//1788 2495//1791
+f 2490//1794 2475//1774 2489//1792
+f 2480//1771 2495//1791 2496//1793
+f 2491//1796 2476//1776 2490//1794
+f 2481//1773 2496//1793 2497//1795
+f 2492//1799 2477//1780 2491//1796
+f 2487//1785 2472//1781 2486//1797
+f 2482//1775 2497//1795 2498//1798
+f 2493//1803 2478//1787 2492//1799
+f 2507//1804 2492//1799 2506//1800
+f 2502//1805 2487//1785 2501//1801
+f 2497//1795 2512//1814 2513//1802
+f 2508//1821 2493//1803 2507//1804
+f 2503//1808 2488//1789 2502//1805
+f 2498//1798 2513//1802 2514//1806
+f 2493//1803 2508//1821 2509//1807
+f 2504//1811 2489//1792 2503//1808
+f 2499//1786 2514//1806 2515//1809
+f 2494//1788 2509//1807 2510//1810
+f 2505//1813 2490//1794 2504//1811
+f 2495//1791 2510//1810 2511//1812
+f 2506//1800 2491//1796 2505//1813
+f 2496//1793 2511//1812 2512//1814
+f 2510//1810 2525//1828 2526//1815
+f 2521//1818 2506//1800 2520//1816
+f 2511//1812 2526//1815 2527//1817
+f 2522//1822 2507//1804 2521//1818
+f 2517//1823 2502//1805 2516//1819
+f 2512//1814 2527//1817 2528//1820
+f 2523//1838 2508//1821 2522//1822
+f 2518//1826 2503//1808 2517//1823
+f 2513//1802 2528//1820 2529//1824
+f 2508//1821 2523//1838 2524//1825
+f 2519//1829 2504//1811 2518//1826
+f 2514//1806 2529//1824 2530//1827
+f 2509//1807 2524//1825 2525//1828
+f 2520//1816 2505//1813 2519//1829
+f 2545//1847 2530//1827 2544//1830
+f 2524//1825 2539//1842 2540//1831
+f 2519//1829 2534//1843 2535//1832
+f 2525//1828 2540//1831 2541//1833
+f 2520//1816 2535//1832 2536//1834
+f 2526//1815 2541//1833 2542//1835
+f 2521//1818 2536//1834 2537//1836
+f 2516//1819 2531//1854 2532//1837
+f 2543//1841 2528//1820 2542//1835
+f 2522//1822 2537//1836 2538//1839
+f 2517//1823 2532//1837 2533//1840
+f 2544//1830 2529//1824 2543//1841
+f 2523//1838 2538//1839 2539//1842
+f 2518//1826 2533//1840 2534//1843
+f 2559//1848 2544//1830 2558//1844
+f 2538//1839 2553//1857 2554//1845
+f 2533//1840 2548//1858 2549//1846
+f 2560//1866 2545//1847 2559//1848
+f 2555//1850 2540//1831 2554//1845
+f 2534//1843 2549//1846 2550//1849
+f 2556//1852 2541//1833 2555//1850
+f 2535//1832 2550//1849 2551//1851
+f 2557//1856 2542//1835 2556//1852
+f 2536//1834 2551//1851 2552//1853
+f 2531//1854 2546//1859 2547//1855
+f 2558//1844 2543//1841 2557//1856
+f 2537//1836 2552//1853 2553//1857
+f 2532//1837 2547//1855 2548//1858
+f 2546//1859 2561//1877 2562//1860
+f 2573//1864 2558//1844 2572//1861
+f 2552//1853 2567//1873 2568//1862
+f 2547//1855 2562//1860 2563//1863
+f 2574//1867 2559//1848 2573//1864
+f 2569//1868 2554//1845 2568//1862
+f 2548//1858 2563//1863 2564//1865
+f 2575//1884 2560//1866 2574//1867
+f 2570//1870 2555//1850 2569//1868
+f 2549//1846 2564//1865 2565//1869
+f 2571//1872 2556//1852 2570//1870
+f 2550//1849 2565//1869 2566//1871
+f 2572//1861 2557//1856 2571//1872
+f 2551//1851 2566//1871 2567//1873
+f 2565//1869 2580//1887 2581//1874
+f 2587//1879 2572//1861 2586//1875
+f 2566//1871 2581//1874 2582//1876
+f 2561//1877 2576//1895 2577//1878
+f 2588//1882 2573//1864 2587//1879
+f 2567//1873 2582//1876 2583//1880
+f 2562//1860 2577//1878 2578//1881
+f 2589//1885 2574//1867 2588//1882
+f 2584//1886 2569//1868 2583//1880
+f 2563//1863 2578//1881 2579//1883
+f 2590//1902 2575//1884 2589//1885
+f 2585//1888 2570//1870 2584//1886
+f 2564//1865 2579//1883 2580//1887
+f 2586//1875 2571//1872 2585//1888
+f 2600//1891 2585//1888 2599//1889
+f 2579//1883 2594//1901 2595//1890
+f 2601//1893 2586//1875 2600//1891
+f 2580//1887 2595//1890 2596//1892
+f 2602//1897 2587//1879 2601//1893
+f 2581//1874 2596//1892 2597//1894
+f 2576//1895 2591//1914 2592//1896
+f 2603//1900 2588//1882 2602//1897
+f 2582//1876 2597//1894 2598//1898
+f 2577//1878 2592//1896 2593//1899
+f 2604//1903 2589//1885 2603//1900
+f 2599//1889 2584//1886 2598//1898
+f 2578//1881 2593//1899 2594//1901
+f 2605//1907 2590//1902 2604//1903
+f 2619//1908 2604//1903 2618//1904
+f 2598//1898 2613//1917 2614//1905
+f 2593//1899 2608//1918 2609//1906
+f 2620//1927 2605//1907 2619//1908
+f 2615//1910 2600//1891 2614//1905
+f 2594//1901 2609//1906 2610//1909
+f 2616//1912 2601//1893 2615//1910
+f 2595//1890 2610//1909 2611//1911
+f 2617//1916 2602//1897 2616//1912
+f 2596//1892 2611//1911 2612//1913
+f 2591//1914 2606//1919 2607//1915
+f 2618//1904 2603//1900 2617//1916
+f 2597//1894 2612//1913 2613//1917
+f 2592//1896 2607//1915 2608//1918
+f 2606//1919 2621//1937 2622//1920
+f 2633//1924 2618//1904 2632//1921
+f 2612//1913 2627//1933 2628//1922
+f 2607//1915 2622//1920 2623//1923
+f 2634//1928 2619//1908 2633//1924
+f 2613//1917 2628//1922 2629//1925
+f 2608//1918 2623//1923 2624//1926
+f 2635//1945 2620//1927 2634//1928
+f 2630//1930 2615//1910 2629//1925
+f 2609//1906 2624//1926 2625//1929
+f 2631//1932 2616//1912 2630//1930
+f 2610//1909 2625//1929 2626//1931
+f 2632//1921 2617//1916 2631//1932
+f 2611//1911 2626//1931 2627//1933
+f 2625//1929 2640//1947 2641//1934
+f 2647//1939 2632//1921 2646//1935
+f 2626//1931 2641//1934 2642//1936
+f 2621//1937 2636//1955 2637//1938
+f 2648//1942 2633//1924 2647//1939
+f 2627//1933 2642//1936 2643//1940
+f 2622//1920 2637//1938 2638//1941
+f 2649//1946 2634//1928 2648//1942
+f 2628//1922 2643//1940 2644//1943
+f 2623//1923 2638//1941 2639//1944
+f 2650//1963 2635//1945 2649//1946
+f 2645//1948 2630//1930 2644//1943
+f 2624//1926 2639//1944 2640//1947
+f 2646//1935 2631//1932 2645//1948
+f 2644//1943 2659//1961 2660//1949
+f 2639//1944 2654//1962 2655//1950
+f 2645//1948 2660//1949 2661//1951
+f 2640//1947 2655//1950 2656//1952
+f 2646//1935 2661//1951 2662//1953
+f 2641//1934 2656//1952 2657//1954
+f 2652//1975 2637//1938 2651//1956
+f 2647//1939 2662//1953 2663//1957
+f 2642//1936 2657//1954 2658//1958
+f 2637//1938 2652//1975 2653//1959
+f 2648//1942 2663//1957 2664//1960
+f 2643//1940 2658//1958 2659//1961
+f 2638//1941 2653//1959 2654//1962
+f 2649//1946 2664//1960 2665//1964
+f 2663//1957 2678//1977 2679//1965
+f 2658//1958 2673//1978 2674//1966
+f 2669//1970 2654//1962 2668//1967
+f 2664//1960 2679//1965 2680//1968
+f 2659//1961 2674//1966 2675//1969
+f 2670//1972 2655//1950 2669//1970
+f 2660//1949 2675//1969 2676//1971
+f 2671//1974 2656//1952 2670//1972
+f 2661//1951 2676//1971 2677//1973
+f 2672//1981 2657//1954 2671//1974
+f 2667//1979 2652//1975 2666//1976
+f 2662//1953 2677//1973 2678//1977
+f 2657//1954 2672//1981 2673//1978
+f 2668//1967 2653//1959 2667//1979
+f 2677//1973 2692//1992 2693//1980
+f 2688//1999 2673//1978 2687//1982
+f 2683//1986 2668//1967 2682//1983
+f 2678//1977 2693//1980 2694//1984
+f 2673//1978 2688//1999 2689//1985
+f 2684//1989 2669//1970 2683//1986
+f 2679//1965 2694//1984 2695//1987
+f 2674//1966 2689//1985 2690//1988
+f 2685//1991 2670//1972 2684//1989
+f 2675//1969 2690//1988 2691//1990
+f 2686//1993 2671//1974 2685//1991
+f 2676//1971 2691//1990 2692//1992
+f 2687//1982 2672//1981 2686//1993
+f 2682//1983 2667//1979 2681//1994
+f 2691//1990 2706//2008 2707//1995
+f 2702//2000 2687//1982 2701//1996
+f 2697//2001 2682//1983 2696//1997
+f 2692//1992 2707//1995 2708//1998
+f 2703//2017 2688//1999 2702//2000
+f 2698//2004 2683//1986 2697//2001
+f 2693//1980 2708//1998 2709//2002
+f 2688//1999 2703//2017 2704//2003
+f 2699//2007 2684//1989 2698//2004
+f 2694//1984 2709//2002 2710//2005
+f 2689//1985 2704//2003 2705//2006
+f 2700//2009 2685//1991 2699//2007
+f 2690//1988 2705//2006 2706//2008
+f 2701//1996 2686//1993 2700//2009
+f 2715//2012 2700//2009 2714//2010
+f 2705//2006 2720//2024 2721//2011
+f 2716//2014 2701//1996 2715//2012
+f 2706//2008 2721//2011 2722//2013
+f 2717//2018 2702//2000 2716//2014
+f 2712//2019 2697//2001 2711//2015
+f 2707//1995 2722//2013 2723//2016
+f 2718//2025 2703//2017 2717//2018
+f 2713//2022 2698//2004 2712//2019
+f 2708//1998 2723//2016 2724//2020
+f 2703//2017 2718//2025 2719//2021
+f 2714//2010 2699//2007 2713//2022
+f 2709//2002 2724//2020 2725//2023
+f 2704//2003 2719//2021 2720//2024
+f 2718//2025 2733//2041 2734//2026
+f 2729//2030 2714//2010 2728//2027
+f 2724//2020 2739//2039 2740//2028
+f 2719//2021 2734//2026 2735//2029
+f 2730//2032 2715//2012 2729//2030
+f 2720//2024 2735//2029 2736//2031
+f 2731//2034 2716//2014 2730//2032
+f 2721//2011 2736//2031 2737//2033
+f 2732//2037 2717//2018 2731//2034
+f 2727//2038 2712//2019 2726//2035
+f 2722//2013 2737//2033 2738//2036
+f 2733//2041 2718//2025 2732//2037
+f 2728//2027 2713//2022 2727//2038
+f 2723//2016 2738//2036 2739//2039
+f 2737//2033 2753//2052 2754//2040
+f 2749//2059 2733//2041 2748//2042
+f 2744//2046 2728//2027 2743//2043
+f 2738//2036 2754//2040 2755//2044
+f 2733//2041 2749//2059 2750//2045
+f 2745//2049 2729//2030 2744//2046
+f 2739//2039 2755//2044 2756//2047
+f 2734//2026 2750//2045 2751//2048
+f 2746//2051 2730//2032 2745//2049
+f 2735//2029 2751//2048 2752//2050
+f 2747//2053 2731//2034 2746//2051
+f 2736//2031 2752//2050 2753//2052
+f 2748//2042 2732//2037 2747//2053
+f 2743//2043 2727//2038 2742//2054
+f 2752//2050 2767//2068 2768//2055
+f 2763//2060 2748//2042 2762//2056
+f 2758//2061 2743//2043 2757//2057
+f 2753//2052 2768//2055 2769//2058
+f 2764//2077 2749//2059 2763//2060
+f 2759//2064 2744//2046 2758//2061
+f 2754//2040 2769//2058 2770//2062
+f 2749//2059 2764//2077 2765//2063
+f 2760//2067 2745//2049 2759//2064
+f 2755//2044 2770//2062 2771//2065
+f 2750//2045 2765//2063 2766//2066
+f 2761//2069 2746//2051 2760//2067
+f 2751//2048 2766//2066 2767//2068
+f 2762//2056 2747//2053 2761//2069
+f 2776//2072 2761//2069 2775//2070
+f 2782//2073 2767//2068 2781//2071
+f 2777//2074 2762//2056 2776//2072
+f 2783//2076 2768//2055 2782//2073
+f 2778//2078 2763//2060 2777//2074
+f 2757//2057 2772//2094 2773//2075
+f 2784//2080 2769//2058 2783//2076
+f 2779//2081 2764//2077 2778//2078
+f 2758//2061 2773//2075 2774//2079
+f 2785//2082 2770//2062 2784//2080
+f 2780//2083 2765//2063 2779//2081
+f 2759//2064 2774//2079 2775//2070
+f 2786//2086 2771//2065 2785//2082
+f 2781//2071 2766//2066 2780//2083
+f 2795//2088 2780//2083 2794//2084
+f 2774//2079 2789//2097 2790//2085
+f 2801//2104 2786//2086 2800//2087
+f 2796//2090 2781//2071 2795//2088
+f 2775//2070 2790//2085 2791//2089
+f 2797//2092 2782//2073 2796//2090
+f 2776//2072 2791//2089 2792//2091
+f 2798//2096 2783//2076 2797//2092
+f 2777//2074 2792//2091 2793//2093
+f 2772//2094 2787//2112 2788//2095
+f 2799//2098 2784//2080 2798//2096
+f 2794//2084 2779//2081 2793//2093
+f 2773//2075 2788//2095 2789//2097
+f 2800//2087 2785//2082 2799//2098
+f 2814//2102 2799//2098 2813//2099
+f 2793//2093 2808//2111 2809//2100
+f 2788//2095 2803//2113 2804//2101
+f 2815//2105 2800//2087 2814//2102
+f 2810//2106 2795//2088 2809//2100
+f 2789//2097 2804//2101 2805//2103
+f 2816//2123 2801//2104 2815//2105
+f 2811//2108 2796//2090 2810//2106
+f 2790//2085 2805//2103 2806//2107
+f 2812//2110 2797//2092 2811//2108
+f 2791//2089 2806//2107 2807//2109
+f 2813//2099 2798//2096 2812//2110
+f 2792//2091 2807//2109 2808//2111
+f 2787//2112 2802//2116 2803//2113
+f 2828//2118 2813//2099 2827//2114
+f 2807//2109 2822//2128 2823//2115
+f 2802//2116 2817//2133 2818//2117
+f 2829//2121 2814//2102 2828//2118
+f 2808//2111 2823//2115 2824//2119
+f 2803//2113 2818//2117 2819//2120
+f 2830//2124 2815//2105 2829//2121
+f 2825//2125 2810//2106 2824//2119
+f 2804//2101 2819//2120 2820//2122
+f 2831//2140 2816//2123 2830//2124
+f 2826//2127 2811//2108 2825//2125
+f 2805//2103 2820//2122 2821//2126
+f 2827//2114 2812//2110 2826//2127
+f 2806//2107 2821//2126 2822//2128
+f 2842//2131 2827//2114 2841//2129
+f 2821//2126 2836//2143 2837//2130
+f 2843//2135 2828//2118 2842//2131
+f 2822//2128 2837//2130 2838//2132
+f 2817//2133 2832//2153 2833//2134
+f 2844//2138 2829//2121 2843//2135
+f 2823//2115 2838//2132 2839//2136
+f 2818//2117 2833//2134 2834//2137
+f 2845//2141 2830//2124 2844//2138
+f 2840//2142 2825//2125 2839//2136
+f 2819//2120 2834//2137 2835//2139
+f 2846//2145 2831//2140 2845//2141
+f 2841//2129 2826//2127 2840//2142
+f 2820//2122 2835//2139 2836//2143
+f 2834//2137 2849//2156 2850//2144
+f 2861//2164 2846//2145 2860//2146
+f 2856//2149 2841//2129 2855//2147
+f 2835//2139 2850//2144 2851//2148
+f 2857//2151 2842//2131 2856//2149
+f 2836//2143 2851//2148 2852//2150
+f 2858//2155 2843//2135 2857//2151
+f 2837//2130 2852//2150 2853//2152
+f 2832//2153 2847//2171 2848//2154
+f 2859//2157 2844//2138 2858//2155
+f 2854//2158 2839//2136 2853//2152
+f 2833//2134 2848//2154 2849//2156
+f 2860//2146 2845//2141 2859//2157
+f 2855//2147 2840//2142 2854//2158
+f 2870//2162 2854//2158 2869//2159
+f 2848//2154 2864//2172 2865//2160
+f 2876//2165 2860//2146 2875//2161
+f 2871//2166 2855//2147 2870//2162
+f 2849//2156 2865//2160 2866//2163
+f 2877//2183 2861//2164 2876//2165
+f 2872//2168 2856//2149 2871//2166
+f 2850//2144 2866//2163 2867//2167
+f 2873//2170 2857//2151 2872//2168
+f 2851//2148 2867//2167 2868//2169
+f 2874//2173 2858//2155 2873//2170
+f 2852//2150 2868//2169 2869//2159
+f 2847//2171 2863//2176 2864//2172
+f 2875//2161 2859//2157 2874//2173
+f 2889//2178 2874//2173 2888//2174
+f 2868//2169 2883//2188 2884//2175
+f 2863//2176 2878//2192 2879//2177
+f 2890//2180 2875//2161 2889//2178
+f 2885//2181 2870//2162 2884//2175
+f 2864//2172 2879//2177 2880//2179
+f 2891//2184 2876//2165 2890//2180
+f 2886//2185 2871//2166 2885//2181
+f 2865//2160 2880//2179 2881//2182
+f 2892//2191 2877//2183 2891//2184
+f 2887//2187 2872//2168 2886//2185
+f 2866//2163 2881//2182 2882//2186
+f 2888//2174 2873//2170 2887//2187
+f 2867//2167 2882//2186 2883//2188
+f 2421//1736 2888//2174 2420//1732
+f 2416//1712 2883//2188 2415//1734
+f 2422//1718 2889//2178 2421//1736
+f 2417//1711 2884//2175 2416//1712
+f 2412//1714 2879//2177 2411//1715
+f 2423//1717 2890//2180 2422//1718
+f 2418//1720 2885//2181 2417//1711
+f 2413//1722 2880//2179 2412//1714
+f 2424//1724 2891//2184 2423//1717
+f 2419//1726 2886//2185 2418//1720
+f 2414//1728 2881//2182 2413//1722
+f 2891//2184 2424//1724 2425//1730
+f 2420//1732 2887//2187 2419//1726
+f 2415//1734 2882//2186 2414//1728
+f 2914//1721 2899//1711 2913//1713
+f 2909//2196 2894//1714 2908//2194
+f 2904//1718 2919//1739 2920//1719
+f 2915//1727 2900//1720 2914//1721
+f 2910//2197 2895//1722 2909//2196
+f 2905//2195 2920//1719 2921//1725
+f 2916//1746 2901//1726 2915//1727
+f 2911//1735 2896//1728 2910//2197
+f 2906//1724 2921//1725 2922//2199
+f 2901//1726 2916//1746 2917//1733
+f 2912//1738 2897//1734 2911//1735
+f 2902//1732 2917//1733 2918//1737
+f 2913//1713 2898//2193 2912//1738
+f 2903//2200 2918//1737 2919//1739
+f 2929//1743 2914//1721 2928//1740
+f 2924//1744 2909//2196 2923//2201
+f 2919//1739 2934//2205 2935//2202
+f 2930//2209 2915//1727 2929//1743
+f 2925//1748 2910//2197 2924//1744
+f 2920//1719 2935//2202 2936//2203
+f 2915//1727 2930//2209 2931//1747
+f 2926//1751 2911//1735 2925//1748
+f 2921//1725 2936//2203 2937//1749
+f 2916//1746 2931//1747 2932//1750
+f 2927//2204 2912//1738 2926//1751
+f 2917//1733 2932//1750 2933//1752
+f 2928//1740 2913//1713 2927//2204
+f 2918//1737 2933//1752 2934//2205
+f 2932//1750 2947//2212 2948//2206
+f 2943//1758 2928//1740 2942//1756
+f 2933//1752 2948//2206 2949//2207
+f 2944//1762 2929//1743 2943//1758
+f 2939//2210 2924//1744 2938//2208
+f 2934//2205 2949//2207 2950//1760
+f 2945//1779 2930//2209 2944//1762
+f 2940//1766 2925//1748 2939//2210
+f 2935//2202 2950//1760 2951//1764
+f 2930//2209 2945//1779 2946//1765
+f 2941//2213 2926//1751 2940//1766
+f 2936//2203 2951//1764 2952//2211
+f 2931//1747 2946//1765 2947//2212
+f 2942//1756 2927//2204 2941//2213
+f 2951//1764 2966//1782 2967//1770
+f 2946//1765 2961//2217 2962//2214
+f 2957//1774 2942//1756 2956//1772
+f 2947//2212 2962//2214 2963//2215
+f 2958//1776 2943//1758 2957//1774
+f 2948//2206 2963//2215 2964//1775
+f 2959//1780 2944//1762 2958//1776
+f 2954//1781 2939//2210 2953//2216
+f 2949//2207 2964//1775 2965//1778
+f 2960//1787 2945//1779 2959//1780
+f 2955//2218 2940//1766 2954//1781
+f 2950//1760 2965//1778 2966//1782
+f 2945//1779 2960//1787 2961//2217
+f 2956//1772 2941//2213 2955//2218
+f 2970//2219 2955//2218 2969//1785
+f 2965//1778 2980//2222 2981//1786
+f 2960//1787 2975//1803 2976//1788
+f 2971//1792 2956//1772 2970//2219
+f 2966//1782 2981//1786 2982//2220
+f 2961//2217 2976//1788 2977//1791
+f 2972//2221 2957//1774 2971//1792
+f 2962//2214 2977//1791 2978//1793
+f 2973//1796 2958//1776 2972//2221
+f 2963//2215 2978//1793 2979//1795
+f 2974//1799 2959//1780 2973//1796
+f 2969//1785 2954//1781 2968//1797
+f 2964//1775 2979//1795 2980//2222
+f 2975//1803 2960//1787 2974//1799
+f 2989//1804 2974//1799 2988//1800
+f 2984//1805 2969//1785 2983//1801
+f 2979//1795 2994//1814 2995//1802
+f 2990//1821 2975//1803 2989//1804
+f 2985//1808 2970//2219 2984//1805
+f 2980//2222 2995//1802 2996//1806
+f 2975//1803 2990//1821 2991//1807
+f 2986//1811 2971//1792 2985//1808
+f 2981//1786 2996//1806 2997//2223
+f 2976//1788 2991//1807 2992//1810
+f 2987//1813 2972//2221 2986//1811
+f 2977//1791 2992//1810 2993//1812
+f 2988//1800 2973//1796 2987//1813
+f 2978//1793 2993//1812 2994//1814
+f 2992//1810 3007//1828 3008//2224
+f 3003//1818 2988//1800 3002//1816
+f 2993//1812 3008//2224 3009//1817
+f 3004//1822 2989//1804 3003//1818
+f 2999//1823 2984//1805 2998//1819
+f 2994//1814 3009//1817 3010//1820
+f 3005//2226 2990//1821 3004//1822
+f 3000//1826 2985//1808 2999//1823
+f 2995//1802 3010//1820 3011//1824
+f 2990//1821 3005//2226 3006//1825
+f 3001//1829 2986//1811 3000//1826
+f 2996//1806 3011//1824 3012//1827
+f 2991//1807 3006//1825 3007//1828
+f 3002//1816 2987//1813 3001//1829
+f 3027//1847 3012//1827 3026//2225
+f 3006//1825 3021//1842 3022//1831
+f 3001//1829 3016//1843 3017//1832
+f 3007//1828 3022//1831 3023//1833
+f 3002//1816 3017//1832 3018//1834
+f 3008//2224 3023//1833 3024//1835
+f 3003//1818 3018//1834 3019//1836
+f 2998//1819 3013//1854 3014//1837
+f 3025//1841 3010//1820 3024//1835
+f 3004//1822 3019//1836 3020//1839
+f 2999//1823 3014//1837 3015//1840
+f 3026//2225 3011//1824 3025//1841
+f 3005//2226 3020//1839 3021//1842
+f 3000//1826 3015//1840 3016//1843
+f 3041//1848 3026//2225 3040//1844
+f 3020//1839 3035//2229 3036//1845
+f 3015//1840 3030//1858 3031//1846
+f 3042//1866 3027//1847 3041//1848
+f 3037//2228 3022//1831 3036//1845
+f 3016//1843 3031//1846 3032//2227
+f 3038//1852 3023//1833 3037//2228
+f 3017//1832 3032//2227 3033//1851
+f 3039//1856 3024//1835 3038//1852
+f 3018//1834 3033//1851 3034//1853
+f 3013//1854 3028//1859 3029//1855
+f 3040//1844 3025//1841 3039//1856
+f 3019//1836 3034//1853 3035//2229
+f 3014//1837 3029//1855 3030//1858
+f 3028//1859 3043//1877 3044//1860
+f 3055//2231 3040//1844 3054//2230
+f 3034//1853 3049//2234 3050//1862
+f 3029//1855 3044//1860 3045//1863
+f 3056//1867 3041//1848 3055//2231
+f 3051//2232 3036//1845 3050//1862
+f 3030//1858 3045//1863 3046//1865
+f 3057//1884 3042//1866 3056//1867
+f 3052//1870 3037//2228 3051//2232
+f 3031//1846 3046//1865 3047//1869
+f 3053//1872 3038//1852 3052//1870
+f 3032//2227 3047//1869 3048//2233
+f 3054//2230 3039//1856 3053//1872
+f 3033//1851 3048//2233 3049//2234
+f 3047//1869 3062//1887 3063//1874
+f 3069//1879 3054//2230 3068//1875
+f 3048//2233 3063//1874 3064//1876
+f 3043//1877 3058//1895 3059//1878
+f 3070//2236 3055//2231 3069//1879
+f 3049//2234 3064//1876 3065//2235
+f 3044//1860 3059//1878 3060//1881
+f 3071//1885 3056//1867 3070//2236
+f 3066//1886 3051//2232 3065//2235
+f 3045//1863 3060//1881 3061//1883
+f 3072//1902 3057//1884 3071//1885
+f 3067//2237 3052//1870 3066//1886
+f 3046//1865 3061//1883 3062//1887
+f 3068//1875 3053//1872 3067//2237
+f 3082//1891 3067//2237 3081//2238
+f 3061//1883 3076//1901 3077//2239
+f 3083//1893 3068//1875 3082//1891
+f 3062//1887 3077//2239 3078//1892
+f 3084//1897 3069//1879 3083//1893
+f 3063//1874 3078//1892 3079//1894
+f 3058//1895 3073//2240 3074//1896
+f 3085//1900 3070//2236 3084//1897
+f 3064//1876 3079//1894 3080//1898
+f 3059//1878 3074//1896 3075//1899
+f 3086//1903 3071//1885 3085//1900
+f 3081//2238 3066//1886 3080//1898
+f 3060//1881 3075//1899 3076//1901
+f 3087//1907 3072//1902 3086//1903
+f 3101//1908 3086//1903 3100//1904
+f 3080//1898 3095//1917 3096//1905
+f 3075//1899 3090//2241 3091//1906
+f 3102//1927 3087//1907 3101//1908
+f 3097//1910 3082//1891 3096//1905
+f 3076//1901 3091//1906 3092//1909
+f 3098//1912 3083//1893 3097//1910
+f 3077//2239 3092//1909 3093//1911
+f 3099//1916 3084//1897 3098//1912
+f 3078//1892 3093//1911 3094//1913
+f 3073//2240 3088//2242 3089//1915
+f 3100//1904 3085//1900 3099//1916
+f 3079//1894 3094//1913 3095//1917
+f 3074//1896 3089//1915 3090//2241
+f 3088//2242 3103//2246 3104//2243
+f 3115//1924 3100//1904 3114//1921
+f 3094//1913 3109//1933 3110//1922
+f 3089//1915 3104//2243 3105//1923
+f 3116//1928 3101//1908 3115//1924
+f 3095//1917 3110//1922 3111//1925
+f 3090//2241 3105//1923 3106//2244
+f 3117//2247 3102//1927 3116//1928
+f 3112//2245 3097//1910 3111//1925
+f 3091//1906 3106//2244 3107//1929
+f 3113//1932 3098//1912 3112//2245
+f 3092//1909 3107//1929 3108//1931
+f 3114//1921 3099//1916 3113//1932
+f 3093//1911 3108//1931 3109//1933
+f 3107//1929 3122//2248 3123//1934
+f 3129//1939 3114//1921 3128//1935
+f 3108//1931 3123//1934 3124//1936
+f 3103//2246 3118//2250 3119//1938
+f 3130//1942 3115//1924 3129//1939
+f 3109//1933 3124//1936 3125//1940
+f 3104//2243 3119//1938 3120//1941
+f 3131//1946 3116//1928 3130//1942
+f 3110//1922 3125//1940 3126//1943
+f 3105//1923 3120//1941 3121//1944
+f 3132//2252 3117//2247 3131//1946
+f 3127//1948 3112//2245 3126//1943
+f 3106//2244 3121//1944 3122//2248
+f 3128//1935 3113//1932 3127//1948
+f 3126//1943 3141//1961 3142//1949
+f 3121//1944 3136//1962 3137//1950
+f 3127//1948 3142//1949 3143//1951
+f 3122//2248 3137//1950 3138//2249
+f 3128//1935 3143//1951 3144//1953
+f 3123//1934 3138//2249 3139//1954
+f 3134//1975 3119//1938 3133//2251
+f 3129//1939 3144//1953 3145//1957
+f 3124//1936 3139//1954 3140//1958
+f 3119//1938 3134//1975 3135//1959
+f 3130//1942 3145//1957 3146//1960
+f 3125//1940 3140//1958 3141//1961
+f 3120//1941 3135//1959 3136//1962
+f 3131//1946 3146//1960 3147//1964
+f 3145//1957 3160//1977 3161//2253
+f 3140//1958 3155//1978 3156//1966
+f 3151//1970 3136//1962 3150//1967
+f 3146//1960 3161//2253 3162//1968
+f 3141//1961 3156//1966 3157//1969
+f 3152//2254 3137//1950 3151//1970
+f 3142//1949 3157//1969 3158//1971
+f 3153//1974 3138//2249 3152//2254
+f 3143//1951 3158//1971 3159//1973
+f 3154//1981 3139//1954 3153//1974
+f 3149//1979 3134//1975 3148//1976
+f 3144//1953 3159//1973 3160//1977
+f 3139//1954 3154//1981 3155//1978
+f 3150//1967 3135//1959 3149//1979
+f 3159//1973 3174//1992 3175//1980
+f 3170//2261 3155//1978 3169//2255
+f 3165//1986 3150//1967 3164//1983
+f 3160//1977 3175//1980 3176//1984
+f 3155//1978 3170//2261 3171//2256
+f 3166//2258 3151//1970 3165//1986
+f 3161//2253 3176//1984 3177//2257
+f 3156//1966 3171//2256 3172//1988
+f 3167//1991 3152//2254 3166//2258
+f 3157//1969 3172//1988 3173//1990
+f 3168//1993 3153//1974 3167//1991
+f 3158//1971 3173//1990 3174//1992
+f 3169//2255 3154//1981 3168//1993
+f 3164//1983 3149//1979 3163//1994
+f 3173//1990 3188//2008 3189//2259
+f 3184//2262 3169//2255 3183//2260
+f 3179//2001 3164//1983 3178//1997
+f 3174//1992 3189//2259 3190//1998
+f 3185//2017 3170//2261 3184//2262
+f 3180//2264 3165//1986 3179//2001
+f 3175//1980 3190//1998 3191//2263
+f 3170//2261 3185//2017 3186//2003
+f 3181//2007 3166//2258 3180//2264
+f 3176//1984 3191//2263 3192//2005
+f 3171//2256 3186//2003 3187//2006
+f 3182//2265 3167//1991 3181//2007
+f 3172//1988 3187//2006 3188//2008
+f 3183//2260 3168//1993 3182//2265
+f 3197//2267 3182//2265 3196//2010
+f 3187//2006 3202//2024 3203//2266
+f 3198//2014 3183//2260 3197//2267
+f 3188//2008 3203//2266 3204//2013
+f 3199//2269 3184//2262 3198//2014
+f 3194//2019 3179//2001 3193//2268
+f 3189//2259 3204//2013 3205//2016
+f 3200//2025 3185//2017 3199//2269
+f 3195//2270 3180//2264 3194//2019
+f 3190//1998 3205//2016 3206//2020
+f 3185//2017 3200//2025 3201//2021
+f 3196//2010 3181//2007 3195//2270
+f 3191//2263 3206//2020 3207//2023
+f 3186//2003 3201//2021 3202//2024
+f 3200//2025 3215//2041 3216//2026
+f 3211//2030 3196//2010 3210//2027
+f 3206//2020 3221//2275 3222//2271
+f 3201//2021 3216//2026 3217//2029
+f 3212//2032 3197//2267 3211//2030
+f 3202//2024 3217//2029 3218//2031
+f 3213//2034 3198//2014 3212//2032
+f 3203//2266 3218//2031 3219//2272
+f 3214//2037 3199//2269 3213//2034
+f 3209//2038 3194//2019 3208//2273
+f 3204//2013 3219//2272 3220//2274
+f 3215//2041 3200//2025 3214//2037
+f 3210//2027 3195//2270 3209//2038
+f 3205//2016 3220//2274 3221//2275
+f 3219//2272 3235//2052 3236//2276
+f 3231//2059 3215//2041 3230//2042
+f 3226//2046 3210//2027 3225//2043
+f 3220//2274 3236//2276 3237//2277
+f 3215//2041 3231//2059 3232//2045
+f 3227//2049 3211//2030 3226//2046
+f 3221//2275 3237//2277 3238//2278
+f 3216//2026 3232//2045 3233//2048
+f 3228//2051 3212//2032 3227//2049
+f 3217//2029 3233//2048 3234//2050
+f 3229//2053 3213//2034 3228//2051
+f 3218//2031 3234//2050 3235//2052
+f 3230//2042 3214//2037 3229//2053
+f 3225//2043 3209//2038 3224//2054
+f 3234//2050 3249//2068 3250//2055
+f 3245//2060 3230//2042 3244//2056
+f 3240//2061 3225//2043 3239//2279
+f 3235//2052 3250//2055 3251//2058
+f 3246//2077 3231//2059 3245//2060
+f 3241//2064 3226//2046 3240//2061
+f 3236//2276 3251//2058 3252//2062
+f 3231//2059 3246//2077 3247//2063
+f 3242//2067 3227//2049 3241//2064
+f 3237//2277 3252//2062 3253//2280
+f 3232//2045 3247//2063 3248//2066
+f 3243//2281 3228//2051 3242//2067
+f 3233//2048 3248//2066 3249//2068
+f 3244//2056 3229//2053 3243//2281
+f 3258//2072 3243//2281 3257//2070
+f 3264//2073 3249//2068 3263//2071
+f 3259//2074 3244//2056 3258//2072
+f 3265//2076 3250//2055 3264//2073
+f 3260//2078 3245//2060 3259//2074
+f 3239//2279 3254//2094 3255//2282
+f 3266//2080 3251//2058 3265//2076
+f 3261//2081 3246//2077 3260//2078
+f 3240//2061 3255//2282 3256//2079
+f 3267//2082 3252//2062 3266//2080
+f 3262//2083 3247//2063 3261//2081
+f 3241//2064 3256//2079 3257//2070
+f 3268//2284 3253//2280 3267//2082
+f 3263//2071 3248//2066 3262//2083
+f 3277//2088 3262//2083 3276//2283
+f 3256//2079 3271//2097 3272//2085
+f 3283//2104 3268//2284 3282//2087
+f 3278//2090 3263//2071 3277//2088
+f 3257//2070 3272//2085 3273//2089
+f 3279//2092 3264//2073 3278//2090
+f 3258//2072 3273//2089 3274//2091
+f 3280//2096 3265//2076 3279//2092
+f 3259//2074 3274//2091 3275//2093
+f 3254//2094 3269//2112 3270//2095
+f 3281//2098 3266//2080 3280//2096
+f 3276//2283 3261//2081 3275//2093
+f 3255//2282 3270//2095 3271//2097
+f 3282//2087 3267//2082 3281//2098
+f 3296//2102 3281//2098 3295//2099
+f 3275//2093 3290//2287 3291//2100
+f 3270//2095 3285//2113 3286//2285
+f 3297//2105 3282//2087 3296//2102
+f 3292//2286 3277//2088 3291//2100
+f 3271//2097 3286//2285 3287//2103
+f 3298//2123 3283//2104 3297//2105
+f 3293//2108 3278//2090 3292//2286
+f 3272//2085 3287//2103 3288//2107
+f 3294//2110 3279//2092 3293//2108
+f 3273//2089 3288//2107 3289//2109
+f 3295//2099 3280//2096 3294//2110
+f 3274//2091 3289//2109 3290//2287
+f 3269//2112 3284//2116 3285//2113
+f 3310//2118 3295//2099 3309//2288
+f 3289//2109 3304//2290 3305//2115
+f 3284//2116 3299//2133 3300//2117
+f 3311//2121 3296//2102 3310//2118
+f 3290//2287 3305//2115 3306//2119
+f 3285//2113 3300//2117 3301//2120
+f 3312//2124 3297//2105 3311//2121
+f 3307//2125 3292//2286 3306//2119
+f 3286//2285 3301//2120 3302//2122
+f 3313//2140 3298//2123 3312//2124
+f 3308//2289 3293//2108 3307//2125
+f 3287//2103 3302//2122 3303//2126
+f 3309//2288 3294//2110 3308//2289
+f 3288//2107 3303//2126 3304//2290
+f 3324//2131 3309//2288 3323//2129
+f 3303//2126 3318//2143 3319//2130
+f 3325//2292 3310//2118 3324//2131
+f 3304//2290 3319//2130 3320//2291
+f 3299//2133 3314//2153 3315//2134
+f 3326//2138 3311//2121 3325//2292
+f 3305//2115 3320//2291 3321//2136
+f 3300//2117 3315//2134 3316//2137
+f 3327//2141 3312//2124 3326//2138
+f 3322//2142 3307//2125 3321//2136
+f 3301//2120 3316//2137 3317//2293
+f 3328//2145 3313//2140 3327//2141
+f 3323//2129 3308//2289 3322//2142
+f 3302//2122 3317//2293 3318//2143
+f 3316//2137 3331//2156 3332//2144
+f 3343//2295 3328//2145 3342//2146
+f 3338//2149 3323//2129 3337//2147
+f 3317//2293 3332//2144 3333//2148
+f 3339//2151 3324//2131 3338//2149
+f 3318//2143 3333//2148 3334//2150
+f 3340//2155 3325//2292 3339//2151
+f 3319//2130 3334//2150 3335//2152
+f 3314//2153 3329//2171 3330//2154
+f 3341//2294 3326//2138 3340//2155
+f 3336//2158 3321//2136 3335//2152
+f 3315//2134 3330//2154 3331//2156
+f 3342//2146 3327//2141 3341//2294
+f 3337//2147 3322//2142 3336//2158
+f 3352//2162 3336//2158 3351//2159
+f 3330//2154 3346//2172 3347//2160
+f 3358//2296 3342//2146 3357//2161
+f 3353//2166 3337//2147 3352//2162
+f 3331//2156 3347//2160 3348//2163
+f 3359//2183 3343//2295 3358//2296
+f 3354//2168 3338//2149 3353//2166
+f 3332//2144 3348//2163 3349//2167
+f 3355//2170 3339//2151 3354//2168
+f 3333//2148 3349//2167 3350//2297
+f 3356//2298 3340//2155 3355//2170
+f 3334//2150 3350//2297 3351//2159
+f 3329//2171 3345//2176 3346//2172
+f 3357//2161 3341//2294 3356//2298
+f 3371//2178 3356//2298 3370//2174
+f 3350//2297 3365//2188 3366//2299
+f 3345//2176 3360//2302 3361//2300
+f 3372//2180 3357//2161 3371//2178
+f 3367//2181 3352//2162 3366//2299
+f 3346//2172 3361//2300 3362//2179
+f 3373//2301 3358//2296 3372//2180
+f 3368//2185 3353//2166 3367//2181
+f 3347//2160 3362//2179 3363//2182
+f 3374//2191 3359//2183 3373//2301
+f 3369//2187 3354//2168 3368//2185
+f 3348//2163 3363//2182 3364//2186
+f 3370//2174 3355//2170 3369//2187
+f 3349//2167 3364//2186 3365//2188
+f 2903//2200 3370//2174 2902//1732
+f 2898//2193 3365//2188 2897//1734
+f 2904//1718 3371//2178 2903//2200
+f 2899//1711 3366//2299 2898//2193
+f 2894//1714 3361//2300 2893//1715
+f 2905//2195 3372//2180 2904//1718
+f 2900//1720 3367//2181 2899//1711
+f 2895//1722 3362//2179 2894//1714
+f 2906//1724 3373//2301 2905//2195
+f 2901//1726 3368//2185 2900//1720
+f 2896//1728 3363//2182 2895//1722
+f 3373//2301 2906//1724 2907//2198
+f 2902//1732 3369//2187 2901//1726
+f 2897//1734 3364//2186 2896//1728
+o Hand_R_Sphere.011
+v 0.276990 0.207506 -0.985293
+v 0.262213 0.191256 -0.973294
+v 0.249047 0.176916 -0.960609
+v 0.238000 0.165034 -0.947728
+v 0.229496 0.156070 -0.935144
+v 0.223861 0.150366 -0.923341
+v 0.221312 0.148142 -0.912773
+v 0.221947 0.149484 -0.903846
+v 0.225742 0.154339 -0.896902
+v 0.232551 0.162523 -0.892210
+v 0.242112 0.173718 -0.889948
+v 0.254057 0.187497 -0.890205
+v 0.267928 0.203329 -0.892970
+v 0.283192 0.220605 -0.898136
+v 0.299262 0.238662 -0.905506
+v 0.279455 0.206252 -0.985965
+v 0.267048 0.188797 -0.974612
+v 0.256066 0.173344 -0.962524
+v 0.246934 0.160489 -0.950164
+v 0.240001 0.150725 -0.938009
+v 0.235533 0.144427 -0.926524
+v 0.233703 0.141838 -0.916152
+v 0.234581 0.143056 -0.907291
+v 0.238133 0.148035 -0.900282
+v 0.244223 0.156584 -0.895393
+v 0.252616 0.168374 -0.892813
+v 0.262991 0.182952 -0.892641
+v 0.274947 0.199757 -0.894884
+v 0.288027 0.218145 -0.899455
+v 0.301727 0.237408 -0.906178
+v 0.282442 0.205732 -0.986998
+v 0.272906 0.187776 -0.976639
+v 0.264571 0.171863 -0.965467
+v 0.257758 0.158603 -0.953910
+v 0.252729 0.148507 -0.942413
+v 0.249676 0.141963 -0.931418
+v 0.248717 0.139222 -0.921348
+v 0.249889 0.140389 -0.912589
+v 0.253147 0.145419 -0.905477
+v 0.258366 0.154120 -0.900287
+v 0.265344 0.166156 -0.897218
+v 0.273815 0.181066 -0.896387
+v 0.283452 0.198276 -0.897827
+v 0.293885 0.217125 -0.901482
+v 0.304713 0.236888 -0.907212
+v 0.285835 0.205965 -0.988353
+v 0.279562 0.188234 -0.979297
+v 0.274235 0.172527 -0.969325
+v 0.270057 0.159449 -0.958821
+v 0.267191 0.149502 -0.948188
+v 0.265746 0.143068 -0.937835
+v 0.265777 0.140395 -0.928160
+v 0.267283 0.141585 -0.919534
+v 0.270207 0.146593 -0.912289
+v 0.274436 0.155225 -0.906704
+v 0.279807 0.167151 -0.902993
+v 0.286114 0.181912 -0.901298
+v 0.293115 0.198940 -0.901685
+v 0.300541 0.217582 -0.904140
+v 0.308106 0.237121 -0.908567
+v 0.289505 0.206943 -0.989978
+v 0.286761 0.190152 -0.982483
+v 0.284686 0.175313 -0.973951
+v 0.283359 0.162995 -0.964709
+v 0.282832 0.153671 -0.955111
+v 0.283125 0.147701 -0.945527
+v 0.284226 0.145313 -0.936326
+v 0.286094 0.146599 -0.927860
+v 0.288657 0.151510 -0.920455
+v 0.291815 0.159857 -0.914396
+v 0.295448 0.171320 -0.909916
+v 0.299416 0.185457 -0.907186
+v 0.303566 0.201726 -0.906311
+v 0.307740 0.219501 -0.907326
+v 0.311776 0.238100 -0.910191
+v 0.293310 0.208629 -0.991809
+v 0.294225 0.193458 -0.986076
+v 0.295522 0.180112 -0.979166
+v 0.297152 0.169103 -0.971346
+v 0.299050 0.160854 -0.962916
+v 0.301146 0.155682 -0.954200
+v 0.303357 0.153786 -0.945533
+v 0.305600 0.155238 -0.937247
+v 0.307787 0.159983 -0.929662
+v 0.309836 0.167838 -0.923069
+v 0.311666 0.178503 -0.917721
+v 0.313208 0.191566 -0.913823
+v 0.314403 0.206525 -0.911527
+v 0.315204 0.222807 -0.910919
+v 0.315582 0.239785 -0.912023
+v 0.297105 0.210956 -0.993777
+v 0.301669 0.198024 -0.989936
+v 0.306329 0.186741 -0.984771
+v 0.310905 0.177540 -0.978479
+v 0.315223 0.170775 -0.971304
+v 0.319116 0.166705 -0.963520
+v 0.322434 0.165488 -0.955427
+v 0.325051 0.167169 -0.947335
+v 0.326864 0.171685 -0.939556
+v 0.327806 0.178862 -0.932389
+v 0.327839 0.188423 -0.926108
+v 0.326962 0.200003 -0.920957
+v 0.325209 0.213154 -0.917131
+v 0.322648 0.227373 -0.914779
+v 0.319376 0.242113 -0.913991
+v 0.300743 0.213837 -0.995806
+v 0.308805 0.203675 -0.993916
+v 0.316689 0.194945 -0.990549
+v 0.324091 0.187981 -0.985834
+v 0.330728 0.183052 -0.979951
+v 0.336344 0.180347 -0.973128
+v 0.340724 0.179970 -0.965627
+v 0.343699 0.181935 -0.957735
+v 0.345154 0.186167 -0.949757
+v 0.345034 0.192504 -0.941997
+v 0.343344 0.200701 -0.934756
+v 0.340148 0.210444 -0.928311
+v 0.335570 0.221358 -0.922909
+v 0.329784 0.233024 -0.918759
+v 0.323014 0.244993 -0.916020
+v 0.304085 0.217160 -0.997818
+v 0.315360 0.210193 -0.997863
+v 0.326205 0.204408 -0.996279
+v 0.336203 0.200025 -0.993126
+v 0.344970 0.197214 -0.988527
+v 0.352169 0.196083 -0.982657
+v 0.357524 0.196675 -0.975742
+v 0.360827 0.198968 -0.968049
+v 0.361954 0.202873 -0.959872
+v 0.360859 0.208240 -0.951526
+v 0.357586 0.214863 -0.943331
+v 0.352260 0.222488 -0.935603
+v 0.345086 0.230821 -0.928639
+v 0.336339 0.239542 -0.922706
+v 0.326356 0.248316 -0.918032
+v 0.307001 0.220797 -0.999736
+v 0.321082 0.217328 -1.001625
+v 0.334512 0.214766 -1.001740
+v 0.346776 0.213209 -1.000077
+v 0.357402 0.212717 -0.996700
+v 0.365983 0.213309 -0.991738
+v 0.372188 0.214962 -0.985383
+v 0.375779 0.217613 -0.977879
+v 0.376618 0.221160 -0.969513
+v 0.374673 0.225466 -0.960607
+v 0.370018 0.230366 -0.951505
+v 0.362832 0.235672 -0.942554
+v 0.353392 0.241179 -0.934100
+v 0.342061 0.246677 -0.926467
+v 0.329273 0.251954 -0.919949
+v 0.309381 0.224610 -1.001486
+v 0.325750 0.224806 -1.005057
+v 0.341289 0.225623 -1.006723
+v 0.355402 0.227027 -1.006419
+v 0.367545 0.228965 -1.004157
+v 0.377253 0.231363 -1.000025
+v 0.384153 0.234128 -0.994180
+v 0.387978 0.237154 -0.986847
+v 0.388583 0.240325 -0.978309
+v 0.385943 0.243519 -0.968893
+v 0.380161 0.246614 -0.958962
+v 0.371459 0.249489 -0.948896
+v 0.360170 0.252036 -0.939083
+v 0.346729 0.254155 -0.929900
+v 0.331653 0.255766 -0.921699
+v 0.311133 0.228450 -1.003000
+v 0.329186 0.232340 -1.008028
+v 0.346277 0.236559 -1.011036
+v 0.361750 0.240947 -1.011908
+v 0.375011 0.245333 -1.010612
+v 0.385548 0.249550 -1.007197
+v 0.392959 0.253435 -1.001794
+v 0.396957 0.256840 -0.994611
+v 0.397389 0.259633 -0.985923
+v 0.394238 0.261706 -0.976066
+v 0.387626 0.262982 -0.965417
+v 0.377807 0.263409 -0.954385
+v 0.365158 0.262972 -0.943396
+v 0.350165 0.261688 -0.932871
+v 0.333404 0.259606 -0.923214
+v 0.312189 0.232171 -1.004221
+v 0.331257 0.239639 -1.010423
+v 0.349284 0.247156 -1.014513
+v 0.365578 0.254434 -1.016334
+v 0.379511 0.261192 -1.015816
+v 0.390549 0.267172 -1.012979
+v 0.398267 0.272143 -1.007932
+v 0.402369 0.275914 -1.000870
+v 0.402697 0.278340 -0.992062
+v 0.399239 0.279329 -0.981848
+v 0.392127 0.278841 -0.970621
+v 0.381635 0.276896 -0.958811
+v 0.368165 0.273569 -0.946873
+v 0.352236 0.268988 -0.935266
+v 0.334460 0.263328 -0.924435
+v 0.312509 0.235630 -1.005102
+v 0.331884 0.246424 -1.012151
+v 0.350195 0.257006 -1.017021
+v 0.366737 0.266971 -1.019526
+v 0.380874 0.275934 -1.019570
+v 0.392063 0.283552 -1.017150
+v 0.399874 0.289531 -1.012360
+v 0.404008 0.293643 -1.005384
+v 0.404305 0.295729 -0.996490
+v 0.400753 0.295708 -0.986019
+v 0.393489 0.293582 -0.974374
+v 0.382793 0.289433 -0.962003
+v 0.369076 0.283419 -0.949381
+v 0.352864 0.275773 -0.936993
+v 0.334780 0.266786 -0.925315
+v 0.312080 0.238694 -1.005608
+v 0.331043 0.252433 -1.013144
+v 0.348974 0.265731 -1.018463
+v 0.365182 0.278074 -1.021362
+v 0.379046 0.288991 -1.021729
+v 0.390032 0.298060 -1.019549
+v 0.397719 0.304933 -1.014906
+v 0.401810 0.309346 -1.007980
+v 0.402149 0.311130 -0.999036
+v 0.398722 0.310216 -0.988418
+v 0.391662 0.306639 -0.976533
+v 0.381239 0.300537 -0.963839
+v 0.367854 0.292144 -0.950824
+v 0.352022 0.281782 -0.937987
+v 0.334351 0.269850 -0.925822
+v 0.310919 0.241244 -1.005721
+v 0.328766 0.257436 -1.013366
+v 0.345668 0.272994 -1.018785
+v 0.360975 0.287319 -1.021771
+v 0.374098 0.299861 -1.022209
+v 0.384535 0.310138 -1.020083
+v 0.391882 0.317756 -1.015474
+v 0.395859 0.322420 -1.008559
+v 0.396312 0.323953 -0.999603
+v 0.393224 0.322295 -0.988952
+v 0.386714 0.317510 -0.977014
+v 0.377031 0.309782 -0.964248
+v 0.364548 0.299407 -0.951145
+v 0.349745 0.286785 -0.938208
+v 0.333190 0.272401 -0.925935
+v 0.309071 0.243184 -1.005436
+v 0.325140 0.261241 -1.012806
+v 0.340404 0.278517 -1.017973
+v 0.354275 0.294349 -1.020737
+v 0.366221 0.308128 -1.020994
+v 0.375781 0.319324 -1.018733
+v 0.382590 0.327507 -1.014040
+v 0.386385 0.332362 -1.007097
+v 0.387020 0.333704 -0.998169
+v 0.384471 0.331480 -0.987601
+v 0.378836 0.325776 -0.975798
+v 0.370332 0.316812 -0.963214
+v 0.359285 0.304931 -0.950333
+v 0.346120 0.290590 -0.937649
+v 0.331342 0.274340 -0.925650
+v 0.306606 0.244438 -1.004764
+v 0.320306 0.263701 -1.011487
+v 0.333385 0.282089 -1.016058
+v 0.345342 0.298894 -1.018301
+v 0.355716 0.313472 -1.018129
+v 0.364109 0.325262 -1.015549
+v 0.370199 0.333811 -1.010660
+v 0.373751 0.338790 -1.003651
+v 0.374629 0.340009 -0.994790
+v 0.372799 0.337419 -0.984418
+v 0.368332 0.331121 -0.972933
+v 0.361398 0.321357 -0.960778
+v 0.352266 0.308502 -0.948419
+v 0.341285 0.293050 -0.936330
+v 0.328877 0.275594 -0.924977
+v 0.303619 0.244958 -1.003730
+v 0.314447 0.264722 -1.009460
+v 0.324880 0.283570 -1.013115
+v 0.334517 0.300780 -1.014555
+v 0.342988 0.315690 -1.013724
+v 0.349967 0.327726 -1.010655
+v 0.355185 0.336427 -1.005465
+v 0.358443 0.341458 -0.998354
+v 0.359615 0.342624 -0.989594
+v 0.358656 0.339883 -0.979524
+v 0.355604 0.333339 -0.968529
+v 0.350574 0.323243 -0.957032
+v 0.343761 0.309984 -0.945476
+v 0.335427 0.294070 -0.934303
+v 0.325891 0.276115 -0.923944
+v 0.300226 0.244725 -1.002375
+v 0.307791 0.264264 -1.006802
+v 0.315217 0.282906 -1.009257
+v 0.322218 0.299934 -1.009644
+v 0.328525 0.314695 -1.007950
+v 0.333897 0.326621 -1.004239
+v 0.338126 0.335254 -0.998653
+v 0.341049 0.340261 -0.991409
+v 0.342556 0.341451 -0.982783
+v 0.342587 0.338778 -0.973107
+v 0.341141 0.332344 -0.962754
+v 0.338275 0.322397 -0.952121
+v 0.334098 0.309319 -0.941617
+v 0.328770 0.293612 -0.931645
+v 0.322497 0.275881 -0.922589
+v 0.296556 0.243747 -1.000751
+v 0.300592 0.262345 -1.003616
+v 0.304766 0.280120 -1.004631
+v 0.308917 0.296389 -1.003757
+v 0.312885 0.310526 -1.001027
+v 0.316517 0.321989 -0.996546
+v 0.319676 0.330336 -0.990487
+v 0.322238 0.335247 -0.983082
+v 0.324106 0.336533 -0.974617
+v 0.325207 0.334145 -0.965415
+v 0.325500 0.328175 -0.955831
+v 0.324973 0.318852 -0.946234
+v 0.323647 0.306533 -0.936991
+v 0.321572 0.291694 -0.928459
+v 0.318828 0.274903 -0.920965
+v 0.292751 0.242061 -0.998920
+v 0.293128 0.259039 -1.000024
+v 0.293929 0.275321 -0.999416
+v 0.295124 0.290281 -0.997119
+v 0.296666 0.303344 -0.993221
+v 0.298497 0.314008 -0.987873
+v 0.300545 0.321863 -0.981280
+v 0.302732 0.326608 -0.973695
+v 0.304975 0.328061 -0.965410
+v 0.307186 0.326164 -0.956742
+v 0.309282 0.320992 -0.948026
+v 0.311181 0.312743 -0.939596
+v 0.312810 0.301734 -0.931776
+v 0.314107 0.288388 -0.924866
+v 0.315022 0.273218 -0.919133
+v 0.315520 0.256806 -0.914796
+v 0.288956 0.239734 -0.996952
+v 0.285684 0.254473 -0.996163
+v 0.283123 0.268692 -0.993811
+v 0.281370 0.281844 -0.989986
+v 0.280494 0.293423 -0.984834
+v 0.280527 0.302984 -0.978554
+v 0.281468 0.310161 -0.971386
+v 0.283282 0.314677 -0.963607
+v 0.285898 0.316358 -0.955516
+v 0.289216 0.315141 -0.947422
+v 0.293109 0.311071 -0.939638
+v 0.297427 0.304306 -0.932463
+v 0.302004 0.295105 -0.926171
+v 0.306664 0.283822 -0.921006
+v 0.311228 0.270890 -0.917165
+v 0.285318 0.236853 -0.994923
+v 0.278548 0.248822 -0.992183
+v 0.272763 0.260488 -0.988033
+v 0.268184 0.271403 -0.982632
+v 0.264988 0.281145 -0.976186
+v 0.263298 0.289342 -0.968945
+v 0.263178 0.295679 -0.961186
+v 0.264634 0.299911 -0.953207
+v 0.267608 0.301876 -0.945315
+v 0.271988 0.301499 -0.937814
+v 0.277604 0.298794 -0.930991
+v 0.284241 0.293865 -0.925109
+v 0.291644 0.286902 -0.920393
+v 0.299527 0.278171 -0.917026
+v 0.307589 0.268009 -0.915136
+v 0.281976 0.233530 -0.992911
+v 0.271993 0.242304 -0.988237
+v 0.263246 0.251026 -0.982303
+v 0.256072 0.259359 -0.975339
+v 0.250746 0.266983 -0.967611
+v 0.247473 0.273606 -0.959417
+v 0.246379 0.278973 -0.951071
+v 0.247505 0.282878 -0.942894
+v 0.250809 0.285171 -0.935200
+v 0.256163 0.285763 -0.928286
+v 0.263362 0.284632 -0.922416
+v 0.272129 0.281821 -0.917816
+v 0.282127 0.277439 -0.914664
+v 0.292972 0.271653 -0.913079
+v 0.304248 0.264686 -0.913124
+v 0.279060 0.229892 -0.990993
+v 0.266272 0.235169 -0.984475
+v 0.254940 0.240667 -0.976842
+v 0.245500 0.246175 -0.968388
+v 0.238315 0.251480 -0.959438
+v 0.233660 0.256380 -0.950335
+v 0.231715 0.260687 -0.941430
+v 0.232554 0.264233 -0.933064
+v 0.236145 0.266884 -0.925559
+v 0.242350 0.268537 -0.919204
+v 0.250930 0.269129 -0.914242
+v 0.261557 0.268637 -0.910865
+v 0.273821 0.267080 -0.909202
+v 0.287251 0.264518 -0.909318
+v 0.301331 0.261049 -0.911206
+v 0.276680 0.226080 -0.989243
+v 0.261603 0.227691 -0.981043
+v 0.248162 0.229811 -0.971859
+v 0.236874 0.232357 -0.962046
+v 0.228171 0.235233 -0.951980
+v 0.222389 0.238327 -0.942049
+v 0.219750 0.241521 -0.932633
+v 0.220354 0.244692 -0.924095
+v 0.224180 0.247719 -0.916763
+v 0.231079 0.250484 -0.910918
+v 0.240787 0.252881 -0.906785
+v 0.252931 0.254820 -0.904523
+v 0.267043 0.256224 -0.904220
+v 0.282582 0.257040 -0.905885
+v 0.298951 0.257237 -0.909457
+v 0.274928 0.222240 -0.987729
+v 0.258167 0.220158 -0.978072
+v 0.243174 0.218874 -0.967546
+v 0.230525 0.218437 -0.956557
+v 0.220706 0.218865 -0.945526
+v 0.214094 0.220140 -0.934877
+v 0.210944 0.222214 -0.925019
+v 0.211376 0.225007 -0.916332
+v 0.215374 0.228411 -0.909149
+v 0.222784 0.232296 -0.903746
+v 0.233322 0.236513 -0.900330
+v 0.246582 0.240900 -0.899034
+v 0.262055 0.245287 -0.899907
+v 0.279146 0.249506 -0.902915
+v 0.297199 0.253396 -0.907942
+v 0.273872 0.218519 -0.986508
+v 0.256096 0.212858 -0.975677
+v 0.240167 0.208277 -0.964069
+v 0.226698 0.204950 -0.952131
+v 0.216205 0.203005 -0.940322
+v 0.209094 0.202518 -0.929094
+v 0.205635 0.203506 -0.918880
+v 0.205963 0.205932 -0.910073
+v 0.210065 0.209704 -0.903010
+v 0.217783 0.214674 -0.897963
+v 0.228821 0.220654 -0.895126
+v 0.242755 0.227412 -0.894608
+v 0.259048 0.234690 -0.896429
+v 0.277075 0.242207 -0.900519
+v 0.296143 0.249675 -0.906721
+v 0.273552 0.215060 -0.985627
+v 0.255469 0.206074 -0.973949
+v 0.239257 0.198427 -0.961561
+v 0.225539 0.192413 -0.948939
+v 0.214843 0.188264 -0.936568
+v 0.207580 0.186138 -0.924923
+v 0.204028 0.186117 -0.914453
+v 0.204324 0.188203 -0.905558
+v 0.208458 0.192315 -0.898582
+v 0.216269 0.198295 -0.893792
+v 0.227459 0.205912 -0.891373
+v 0.241596 0.214876 -0.891416
+v 0.258137 0.224840 -0.893921
+v 0.276448 0.235422 -0.898792
+v 0.295824 0.246216 -0.905840
+v 0.292812 0.225040 -0.996146
+v 0.273981 0.211996 -0.985120
+v 0.256310 0.200064 -0.972956
+v 0.240478 0.189703 -0.960119
+v 0.227093 0.181309 -0.947103
+v 0.216671 0.175207 -0.934409
+v 0.209610 0.171630 -0.922525
+v 0.206184 0.170716 -0.911906
+v 0.206523 0.172500 -0.902962
+v 0.210614 0.176913 -0.896036
+v 0.218300 0.183787 -0.891394
+v 0.229286 0.192856 -0.889214
+v 0.243150 0.203772 -0.889580
+v 0.259359 0.216116 -0.892479
+v 0.277289 0.229413 -0.897798
+v 0.296253 0.243153 -0.905334
+v 0.275142 0.209446 -0.985008
+v 0.258587 0.195061 -0.972734
+v 0.243784 0.182439 -0.959797
+v 0.231301 0.172065 -0.946694
+v 0.221618 0.164336 -0.933928
+v 0.215108 0.159551 -0.921991
+v 0.212020 0.157893 -0.911339
+v 0.212473 0.159426 -0.902384
+v 0.216450 0.164090 -0.895469
+v 0.223798 0.171708 -0.890859
+v 0.234234 0.181985 -0.888733
+v 0.247358 0.194527 -0.889171
+v 0.262665 0.208852 -0.892158
+v 0.279566 0.224410 -0.897577
+v 0.297413 0.240602 -0.905221
+v 0.218203 0.254350 -0.972109
+v 0.203426 0.238100 -0.960110
+v 0.190261 0.223760 -0.947426
+v 0.179213 0.211878 -0.934544
+v 0.170709 0.202914 -0.921960
+v 0.165074 0.197210 -0.910158
+v 0.162525 0.194986 -0.899589
+v 0.163160 0.196328 -0.890662
+v 0.166955 0.201183 -0.883719
+v 0.173764 0.209366 -0.879026
+v 0.183325 0.220562 -0.876765
+v 0.195270 0.234341 -0.877021
+v 0.209141 0.250173 -0.879786
+v 0.224405 0.267449 -0.884953
+v 0.240475 0.285506 -0.892323
+v 0.220668 0.253096 -0.972782
+v 0.208261 0.235641 -0.961429
+v 0.197280 0.220188 -0.949340
+v 0.188147 0.207333 -0.936981
+v 0.181214 0.197569 -0.924825
+v 0.176746 0.191271 -0.913341
+v 0.174916 0.188682 -0.902969
+v 0.175794 0.189900 -0.894108
+v 0.179346 0.194879 -0.887098
+v 0.185436 0.203428 -0.882210
+v 0.193829 0.215218 -0.879630
+v 0.204204 0.229796 -0.879458
+v 0.216160 0.246601 -0.881701
+v 0.229240 0.264989 -0.886271
+v 0.242940 0.284252 -0.892995
+v 0.223655 0.252576 -0.973815
+v 0.214119 0.234620 -0.963456
+v 0.205784 0.218707 -0.952283
+v 0.198971 0.205447 -0.940727
+v 0.193942 0.195351 -0.929230
+v 0.190889 0.188807 -0.918235
+v 0.189930 0.186066 -0.908164
+v 0.191102 0.187233 -0.899405
+v 0.194360 0.192263 -0.892294
+v 0.199579 0.200964 -0.887104
+v 0.206557 0.213000 -0.884034
+v 0.215028 0.227910 -0.883204
+v 0.224665 0.245120 -0.884644
+v 0.235098 0.263969 -0.888299
+v 0.245926 0.283732 -0.894028
+v 0.227048 0.252809 -0.975170
+v 0.220775 0.235078 -0.966114
+v 0.215448 0.219371 -0.956142
+v 0.211271 0.206293 -0.945638
+v 0.208404 0.196346 -0.935005
+v 0.206959 0.189912 -0.924652
+v 0.206990 0.187239 -0.914976
+v 0.208496 0.188429 -0.906350
+v 0.211420 0.193437 -0.899106
+v 0.215649 0.202069 -0.893520
+v 0.221020 0.213995 -0.889809
+v 0.227327 0.228756 -0.888115
+v 0.234328 0.245784 -0.888502
+v 0.241754 0.264426 -0.890956
+v 0.249319 0.283965 -0.895383
+v 0.230718 0.253787 -0.976794
+v 0.227974 0.236996 -0.969300
+v 0.225899 0.222157 -0.960768
+v 0.224572 0.209839 -0.951525
+v 0.224045 0.200515 -0.941928
+v 0.224338 0.194545 -0.932344
+v 0.225440 0.192157 -0.923142
+v 0.227307 0.193443 -0.914677
+v 0.229870 0.198354 -0.907272
+v 0.233028 0.206701 -0.901213
+v 0.236661 0.218164 -0.896732
+v 0.240629 0.232301 -0.894002
+v 0.244779 0.248570 -0.893128
+v 0.248953 0.266345 -0.894143
+v 0.252989 0.284944 -0.897008
+v 0.234523 0.255472 -0.978626
+v 0.235438 0.240302 -0.972892
+v 0.236735 0.226956 -0.965983
+v 0.238365 0.215947 -0.958163
+v 0.240264 0.207698 -0.949733
+v 0.242359 0.202526 -0.941017
+v 0.244570 0.200629 -0.932349
+v 0.246813 0.202082 -0.924064
+v 0.249001 0.206827 -0.916479
+v 0.251049 0.214682 -0.909886
+v 0.252879 0.225347 -0.904537
+v 0.254422 0.238410 -0.900640
+v 0.255616 0.253369 -0.898343
+v 0.256418 0.269651 -0.897735
+v 0.256795 0.286629 -0.898839
+v 0.238318 0.257800 -0.980594
+v 0.242882 0.244868 -0.976753
+v 0.247542 0.233585 -0.971587
+v 0.252118 0.224384 -0.965296
+v 0.256436 0.217619 -0.958120
+v 0.260329 0.213549 -0.950336
+v 0.263647 0.212332 -0.942243
+v 0.266264 0.214013 -0.934152
+v 0.268077 0.218529 -0.926373
+v 0.269019 0.225706 -0.919205
+v 0.269052 0.235267 -0.912925
+v 0.268175 0.246847 -0.907773
+v 0.266422 0.259998 -0.903948
+v 0.263861 0.274217 -0.901596
+v 0.260589 0.288957 -0.900807
+v 0.241956 0.260681 -0.982623
+v 0.250018 0.250519 -0.980733
+v 0.257902 0.241789 -0.977365
+v 0.265305 0.234825 -0.972650
+v 0.271941 0.229896 -0.966768
+v 0.277558 0.227191 -0.959945
+v 0.281937 0.226814 -0.952444
+v 0.284912 0.228779 -0.944552
+v 0.286367 0.233011 -0.936573
+v 0.286247 0.239348 -0.928814
+v 0.284557 0.247545 -0.921573
+v 0.281361 0.257288 -0.915127
+v 0.276783 0.268202 -0.909726
+v 0.270997 0.279868 -0.905576
+v 0.264227 0.291837 -0.902836
+v 0.245298 0.264004 -0.984635
+v 0.256573 0.257037 -0.984680
+v 0.267418 0.251252 -0.983095
+v 0.277416 0.246869 -0.979943
+v 0.286184 0.244058 -0.975343
+v 0.293383 0.242927 -0.969473
+v 0.298737 0.243519 -0.962559
+v 0.302041 0.245812 -0.954865
+v 0.303167 0.249717 -0.946688
+v 0.302072 0.255084 -0.938342
+v 0.298799 0.261707 -0.930148
+v 0.293473 0.269332 -0.922420
+v 0.286299 0.277665 -0.915456
+v 0.277552 0.286386 -0.909522
+v 0.267569 0.295160 -0.904848
+v 0.248215 0.267641 -0.986552
+v 0.262295 0.264172 -0.988441
+v 0.275725 0.261610 -0.988557
+v 0.287989 0.260053 -0.986894
+v 0.298615 0.259561 -0.983517
+v 0.307196 0.260153 -0.978555
+v 0.313401 0.261806 -0.972200
+v 0.316992 0.264457 -0.964695
+v 0.317831 0.268004 -0.956329
+v 0.315886 0.272310 -0.947424
+v 0.311231 0.277210 -0.938321
+v 0.304045 0.282516 -0.929371
+v 0.294606 0.288023 -0.920917
+v 0.283274 0.293521 -0.913284
+v 0.270486 0.298798 -0.906766
+v 0.250594 0.271454 -0.988302
+v 0.266963 0.271650 -0.991874
+v 0.282502 0.272467 -0.993539
+v 0.296615 0.273871 -0.993236
+v 0.308758 0.275809 -0.990974
+v 0.318466 0.278207 -0.986841
+v 0.325366 0.280972 -0.980996
+v 0.329191 0.283998 -0.973664
+v 0.329796 0.287169 -0.965126
+v 0.327156 0.290363 -0.955710
+v 0.321374 0.293457 -0.945778
+v 0.312672 0.296333 -0.935713
+v 0.301383 0.298880 -0.925900
+v 0.287942 0.300999 -0.916716
+v 0.272866 0.302610 -0.908516
+v 0.252346 0.275294 -0.989817
+v 0.270399 0.279184 -0.994844
+v 0.287490 0.283403 -0.997852
+v 0.302964 0.287791 -0.998725
+v 0.316224 0.292177 -0.997429
+v 0.326762 0.296394 -0.994013
+v 0.334172 0.300279 -0.988610
+v 0.338170 0.303684 -0.981427
+v 0.338602 0.306476 -0.972740
+v 0.335451 0.308550 -0.962882
+v 0.328840 0.309826 -0.952233
+v 0.319020 0.310253 -0.941202
+v 0.306371 0.309816 -0.930213
+v 0.291378 0.308532 -0.919687
+v 0.274617 0.306450 -0.910030
+v 0.253402 0.279015 -0.991038
+v 0.272470 0.286483 -0.997240
+v 0.290498 0.294000 -1.001330
+v 0.306791 0.301278 -1.003151
+v 0.320724 0.308036 -1.002633
+v 0.331762 0.314016 -0.999796
+v 0.339480 0.318987 -0.994749
+v 0.343582 0.322758 -0.987686
+v 0.343910 0.325184 -0.978878
+v 0.340452 0.326172 -0.968665
+v 0.333340 0.325685 -0.957437
+v 0.322848 0.323740 -0.945628
+v 0.309378 0.320413 -0.933690
+v 0.293450 0.315832 -0.922082
+v 0.275673 0.310172 -0.911251
+v 0.253722 0.282474 -0.991919
+v 0.273097 0.293268 -0.998967
+v 0.291408 0.303850 -1.003838
+v 0.307950 0.313814 -1.006343
+v 0.322087 0.322778 -1.006386
+v 0.333276 0.330396 -1.003967
+v 0.341088 0.336375 -0.999177
+v 0.345221 0.340487 -0.992200
+v 0.345518 0.342573 -0.983306
+v 0.341966 0.342552 -0.972835
+v 0.334702 0.340426 -0.961191
+v 0.324006 0.336277 -0.948820
+v 0.310289 0.330263 -0.936198
+v 0.294077 0.322616 -0.923810
+v 0.275993 0.313630 -0.912132
+v 0.253293 0.285538 -0.992425
+v 0.272256 0.299277 -0.999961
+v 0.290187 0.312575 -1.005280
+v 0.306395 0.324918 -1.008179
+v 0.320259 0.335835 -1.008545
+v 0.331245 0.344904 -1.006365
+v 0.338932 0.351777 -1.001723
+v 0.343023 0.356190 -0.994797
+v 0.343362 0.357974 -0.985852
+v 0.339935 0.357060 -0.975234
+v 0.332875 0.353483 -0.963350
+v 0.322452 0.347381 -0.950656
+v 0.309068 0.338988 -0.937640
+v 0.293235 0.328626 -0.924803
+v 0.275564 0.316694 -0.912638
+v 0.252132 0.288088 -0.992538
+v 0.269979 0.304280 -1.000182
+v 0.286881 0.319838 -1.005601
+v 0.302188 0.334163 -1.008588
+v 0.315311 0.346705 -1.009026
+v 0.325748 0.356982 -1.006900
+v 0.333095 0.364600 -1.002290
+v 0.337072 0.369264 -0.995375
+v 0.337525 0.370797 -0.986420
+v 0.334438 0.369139 -0.975768
+v 0.327927 0.364354 -0.963830
+v 0.318244 0.356626 -0.951065
+v 0.305762 0.346251 -0.937962
+v 0.290958 0.333629 -0.925025
+v 0.274403 0.319245 -0.912751
+v 0.250284 0.290028 -0.992253
+v 0.266353 0.308085 -0.999623
+v 0.281617 0.325361 -1.004789
+v 0.295488 0.341193 -1.007554
+v 0.307434 0.354972 -1.007810
+v 0.316995 0.366168 -1.005549
+v 0.323803 0.374351 -1.000857
+v 0.327598 0.379206 -0.993913
+v 0.328233 0.380548 -0.984986
+v 0.325684 0.378324 -0.974418
+v 0.320050 0.372620 -0.962615
+v 0.311545 0.363656 -0.950031
+v 0.300498 0.351775 -0.937149
+v 0.287333 0.337434 -0.924465
+v 0.272555 0.321184 -0.912466
+v 0.247819 0.291282 -0.991580
+v 0.261519 0.310545 -0.998304
+v 0.274598 0.328933 -1.002875
+v 0.286555 0.345738 -1.005117
+v 0.296929 0.360316 -1.004946
+v 0.305322 0.372106 -1.002366
+v 0.311412 0.380655 -0.997477
+v 0.314964 0.385634 -0.990468
+v 0.315842 0.386853 -0.981607
+v 0.314012 0.384263 -0.971235
+v 0.309545 0.377965 -0.959750
+v 0.302612 0.368201 -0.947595
+v 0.293479 0.355346 -0.935235
+v 0.282498 0.339894 -0.923147
+v 0.270090 0.322438 -0.911794
+v 0.244833 0.291802 -0.990547
+v 0.255661 0.311566 -0.996277
+v 0.266094 0.330414 -0.999932
+v 0.275730 0.347624 -1.001372
+v 0.284201 0.362534 -1.000541
+v 0.291180 0.374570 -0.997472
+v 0.296398 0.383271 -0.992282
+v 0.299656 0.388301 -0.985170
+v 0.300828 0.389468 -0.976411
+v 0.299870 0.386727 -0.966341
+v 0.296817 0.380183 -0.955346
+v 0.291787 0.370087 -0.943849
+v 0.284974 0.356828 -0.932292
+v 0.276640 0.340914 -0.921120
+v 0.267104 0.322959 -0.910760
+v 0.241439 0.291569 -0.989192
+v 0.249004 0.311108 -0.993619
+v 0.256430 0.329750 -0.996073
+v 0.263431 0.346778 -0.996461
+v 0.269739 0.361539 -0.994766
+v 0.275110 0.373465 -0.991055
+v 0.279339 0.382098 -0.985470
+v 0.282262 0.387105 -0.978225
+v 0.283769 0.388295 -0.969599
+v 0.283800 0.385622 -0.959924
+v 0.282354 0.379188 -0.949571
+v 0.279488 0.369241 -0.938938
+v 0.275311 0.356163 -0.928434
+v 0.269983 0.340456 -0.918462
+v 0.263711 0.322725 -0.909405
+v 0.237769 0.290591 -0.987568
+v 0.241805 0.309189 -0.990433
+v 0.245979 0.326964 -0.991448
+v 0.250130 0.343233 -0.990573
+v 0.254098 0.357370 -0.987843
+v 0.257731 0.368833 -0.983363
+v 0.260889 0.377180 -0.977304
+v 0.263451 0.382091 -0.969899
+v 0.265319 0.383377 -0.961433
+v 0.266420 0.380989 -0.952232
+v 0.266713 0.375019 -0.942648
+v 0.266186 0.365695 -0.933050
+v 0.264860 0.353377 -0.923808
+v 0.262785 0.338538 -0.915275
+v 0.260041 0.321747 -0.907781
+v 0.233964 0.288905 -0.985736
+v 0.234341 0.305883 -0.986840
+v 0.235142 0.322165 -0.986232
+v 0.236337 0.337124 -0.983935
+v 0.237879 0.350187 -0.980038
+v 0.239710 0.360852 -0.974690
+v 0.241758 0.368707 -0.968097
+v 0.243945 0.373452 -0.960512
+v 0.246188 0.374905 -0.952226
+v 0.248400 0.373008 -0.943559
+v 0.250495 0.367836 -0.934843
+v 0.252394 0.359587 -0.926413
+v 0.254023 0.348578 -0.918593
+v 0.255320 0.335232 -0.911683
+v 0.256235 0.320062 -0.905950
+v 0.256733 0.303650 -0.901613
+v 0.230169 0.286578 -0.983768
+v 0.226898 0.301317 -0.982980
+v 0.224336 0.315536 -0.980628
+v 0.222583 0.328688 -0.976802
+v 0.221707 0.340267 -0.971650
+v 0.221740 0.349828 -0.965370
+v 0.222681 0.357005 -0.958203
+v 0.224495 0.361521 -0.950424
+v 0.227111 0.363202 -0.942332
+v 0.230430 0.361985 -0.934239
+v 0.234322 0.357915 -0.926455
+v 0.238640 0.351150 -0.919279
+v 0.243217 0.341949 -0.912988
+v 0.247877 0.330666 -0.907823
+v 0.252441 0.317734 -0.903982
+v 0.226531 0.283697 -0.981739
+v 0.219761 0.295666 -0.979000
+v 0.213976 0.307332 -0.974850
+v 0.209397 0.318247 -0.969448
+v 0.206201 0.327989 -0.963003
+v 0.204511 0.336186 -0.955762
+v 0.204391 0.342523 -0.948002
+v 0.205847 0.346755 -0.940024
+v 0.208822 0.348720 -0.932132
+v 0.213201 0.348343 -0.924630
+v 0.218817 0.345638 -0.917808
+v 0.225454 0.340709 -0.911925
+v 0.232857 0.333746 -0.907210
+v 0.240740 0.325015 -0.903843
+v 0.248803 0.314853 -0.901953
+v 0.223190 0.280374 -0.979727
+v 0.213206 0.289148 -0.975053
+v 0.204460 0.297870 -0.969120
+v 0.197285 0.306203 -0.962156
+v 0.191959 0.313827 -0.954428
+v 0.188686 0.320450 -0.946233
+v 0.187592 0.325817 -0.937887
+v 0.188718 0.329722 -0.929710
+v 0.192022 0.332015 -0.922017
+v 0.197376 0.332607 -0.915102
+v 0.204575 0.331476 -0.909232
+v 0.213342 0.328665 -0.904633
+v 0.223340 0.324283 -0.901480
+v 0.234186 0.318497 -0.899896
+v 0.245461 0.311530 -0.899941
+v 0.220273 0.276736 -0.977810
+v 0.207485 0.282013 -0.971291
+v 0.196153 0.287511 -0.963659
+v 0.186713 0.293018 -0.955205
+v 0.179528 0.298324 -0.946254
+v 0.174873 0.303224 -0.937152
+v 0.172928 0.307530 -0.928246
+v 0.173767 0.311077 -0.919880
+v 0.177358 0.313728 -0.912376
+v 0.183563 0.315381 -0.906020
+v 0.192143 0.315973 -0.901059
+v 0.202770 0.315481 -0.897682
+v 0.215034 0.313924 -0.896019
+v 0.228464 0.311362 -0.896134
+v 0.242544 0.307893 -0.898023
+v 0.217893 0.272924 -0.976060
+v 0.202816 0.274535 -0.967859
+v 0.189375 0.276655 -0.958676
+v 0.178087 0.279201 -0.948863
+v 0.169384 0.282077 -0.938797
+v 0.163602 0.285171 -0.928865
+v 0.160963 0.288365 -0.919450
+v 0.161567 0.291536 -0.910912
+v 0.165393 0.294562 -0.903579
+v 0.172292 0.297328 -0.897734
+v 0.182000 0.299725 -0.893602
+v 0.194144 0.301664 -0.891340
+v 0.208256 0.303068 -0.891036
+v 0.223795 0.303884 -0.892702
+v 0.240164 0.304081 -0.896273
+v 0.216141 0.269084 -0.974545
+v 0.199380 0.267002 -0.964888
+v 0.184387 0.265718 -0.954363
+v 0.171738 0.265281 -0.943374
+v 0.161919 0.265709 -0.932342
+v 0.155307 0.266984 -0.921693
+v 0.152157 0.269058 -0.911836
+v 0.152589 0.271851 -0.903148
+v 0.156587 0.275255 -0.895965
+v 0.163997 0.279140 -0.890562
+v 0.174535 0.283357 -0.887147
+v 0.187795 0.287744 -0.885851
+v 0.203268 0.292131 -0.886723
+v 0.220360 0.296350 -0.889731
+v 0.238412 0.300240 -0.894759
+v 0.215085 0.265363 -0.973324
+v 0.197309 0.259702 -0.962493
+v 0.181380 0.255121 -0.950886
+v 0.167911 0.251794 -0.938948
+v 0.157419 0.249849 -0.927138
+v 0.150307 0.249362 -0.915911
+v 0.146848 0.250350 -0.905697
+v 0.147176 0.252776 -0.896889
+v 0.151278 0.256547 -0.889826
+v 0.158996 0.261518 -0.884780
+v 0.170034 0.267498 -0.881943
+v 0.183968 0.274256 -0.881425
+v 0.200261 0.281534 -0.883246
+v 0.218288 0.289051 -0.887336
+v 0.237357 0.296519 -0.893538
+v 0.214765 0.261904 -0.972444
+v 0.196682 0.252918 -0.960766
+v 0.180470 0.245271 -0.948378
+v 0.166752 0.239257 -0.935756
+v 0.156056 0.235108 -0.923385
+v 0.148793 0.232982 -0.911740
+v 0.145241 0.232961 -0.901269
+v 0.145538 0.235047 -0.892375
+v 0.149671 0.239159 -0.885399
+v 0.157483 0.245138 -0.880609
+v 0.168672 0.252756 -0.878189
+v 0.182809 0.261720 -0.878233
+v 0.199351 0.271684 -0.880738
+v 0.217661 0.282266 -0.885608
+v 0.237037 0.293060 -0.892657
+v 0.234025 0.271884 -0.982963
+v 0.215194 0.258840 -0.971937
+v 0.197523 0.246908 -0.959772
+v 0.181691 0.236547 -0.946935
+v 0.168306 0.228153 -0.933920
+v 0.157884 0.222051 -0.921226
+v 0.150824 0.218474 -0.909341
+v 0.147397 0.217560 -0.898723
+v 0.147736 0.219344 -0.889779
+v 0.151827 0.223757 -0.882853
+v 0.159513 0.230630 -0.878210
+v 0.170500 0.239699 -0.876030
+v 0.184363 0.250616 -0.876397
+v 0.200572 0.262960 -0.879295
+v 0.218502 0.276257 -0.884615
+v 0.237466 0.289997 -0.892151
+v 0.216355 0.256290 -0.971824
+v 0.199800 0.241905 -0.959551
+v 0.184997 0.229283 -0.946614
+v 0.172514 0.218909 -0.933511
+v 0.162831 0.211180 -0.920745
+v 0.156321 0.206395 -0.908807
+v 0.153233 0.204737 -0.898156
+v 0.153686 0.206270 -0.889201
+v 0.157663 0.210934 -0.882285
+v 0.165011 0.218552 -0.877676
+v 0.175447 0.228829 -0.875550
+v 0.188571 0.241371 -0.875988
+v 0.203878 0.255696 -0.878974
+v 0.220779 0.271254 -0.884393
+v 0.238627 0.287446 -0.892038
+vn -0.603229 -0.795221 -0.060915
+vn -0.595019 -0.681906 -0.425306
+vn -0.396496 -0.817225 -0.418165
+vn -0.419721 -0.313150 -0.851894
+vn -0.385907 -0.256752 -0.886074
+vn -0.365856 -0.273995 -0.889401
+vn 0.230811 0.020173 0.972777
+vn 0.171026 -0.062593 0.983245
+vn 0.290597 -0.029206 0.956389
+vn -0.484970 -0.764519 0.424574
+vn -0.335093 -0.940214 -0.060579
+vn -0.456465 -0.377300 -0.805750
+vn -0.379620 -0.348277 -0.857051
+vn 0.276864 0.086550 0.956999
+vn 0.315195 0.054170 0.947447
+vn -0.251717 -0.558855 0.790124
+vn -0.191076 -0.900021 0.391644
+vn -0.498306 -0.455336 -0.737785
+vn -0.392468 -0.432966 -0.811457
+vn 0.315348 0.143895 0.937986
+vn 0.334941 0.127537 0.933561
+vn -0.046052 -0.335459 0.940916
+vn 0.127384 -0.444197 0.886807
+vn -0.546587 -0.555406 -0.626667
+vn -0.403516 -0.535295 -0.741997
+vn 0.085971 -0.174383 0.980895
+vn 0.207831 -0.262917 0.942137
+vn -0.409009 -0.663747 -0.626179
+vn 0.257241 -0.130680 0.957457
+vn -0.195349 -0.891232 -0.409284
+vn -0.345470 -0.287576 -0.893246
+vn 0.348155 -0.067507 0.934965
+vn -0.082888 -0.994110 -0.069613
+vn -0.337718 -0.376446 -0.862667
+vn 0.352824 0.028565 0.935240
+vn -0.007752 -0.682333 0.730949
+vn 0.197821 -0.734703 0.648885
+vn -0.324717 -0.476821 -0.816797
+vn 0.354167 0.114750 0.928098
+vn 0.277871 -0.508042 0.815271
+vn -0.302683 -0.595416 -0.744194
+vn 0.318125 -0.323740 0.891018
+vn -0.263985 -0.737236 -0.621906
+vn 0.338145 -0.181310 0.923460
+vn 0.413770 -0.359905 0.836177
+vn -0.126011 -0.776727 -0.617084
+vn 0.411145 -0.214972 0.885830
+vn -0.016022 -0.915189 -0.402661
+vn -0.325632 -0.297433 -0.897458
+vn 0.401624 -0.094485 0.910886
+vn 0.065065 -0.939421 0.336436
+vn 0.123203 -0.988769 -0.084262
+vn -0.296182 -0.396893 -0.868740
+vn 0.388409 0.010071 0.921415
+vn 0.357158 -0.742424 0.566729
+vn -0.257363 -0.507614 -0.822199
+vn 0.372417 0.105533 0.922025
+vn 0.401379 -0.537400 0.741661
+vn -0.203497 -0.634297 -0.745811
+vn 0.389233 0.099948 0.915677
+vn 0.501846 -0.542161 0.673910
+vn -0.111850 -0.652974 -0.749046
+vn 0.495315 -0.375500 0.783319
+vn -0.003479 -0.788049 -0.615589
+vn 0.475661 -0.232948 0.848201
+vn 0.133396 -0.905759 -0.402203
+vn -0.307016 -0.303446 -0.902005
+vn 0.450026 -0.110294 0.886166
+vn 0.261513 -0.924284 0.277963
+vn 0.283059 -0.953429 -0.103916
+vn -0.256935 -0.409284 -0.875454
+vn 0.421064 -0.001221 0.907010
+vn 0.479873 -0.725211 0.493698
+vn -0.193945 -0.525071 -0.828639
+vn -0.221473 -0.413526 -0.883114
+vn 0.450270 -0.005341 0.892850
+vn 0.408460 -0.884945 0.223548
+vn 0.577136 -0.693472 0.431257
+vn -0.137181 -0.529618 -0.837062
+vn 0.404187 0.097934 0.909391
+vn 0.584674 -0.529099 0.614917
+vn -0.031495 -0.653798 -0.755974
+vn 0.564745 -0.373974 0.735618
+vn 0.100314 -0.777764 -0.620472
+vn 0.531846 -0.236641 0.813074
+vn 0.254219 -0.875729 -0.410413
+vn -0.290414 -0.305582 -0.906766
+vn 0.492874 -0.115299 0.862392
+vn 0.406873 -0.904324 -0.128819
+vn 0.350749 -0.832575 -0.428632
+vn -0.276254 -0.303903 -0.911740
+vn 0.529862 -0.109989 0.840877
+vn 0.521287 -0.835414 0.174047
+vn 0.504807 -0.848323 -0.159551
+vn -0.191290 -0.409833 -0.891842
+vn 0.475509 -0.002380 0.879696
+vn 0.657369 -0.651723 0.378216
+vn -0.089175 -0.522141 -0.848170
+vn 0.417005 0.099460 0.903439
+vn 0.654500 -0.502121 0.565203
+vn 0.035432 -0.639210 -0.768181
+vn 0.624012 -0.357830 0.694632
+vn 0.185034 -0.751030 -0.633778
+vn 0.580157 -0.227332 0.782098
+vn 0.674673 -0.328471 0.660970
+vn 0.251381 -0.711020 -0.656697
+vn 0.620991 -0.205847 0.756279
+vn 0.427107 -0.779748 -0.457747
+vn -0.264992 -0.298654 -0.916807
+vn 0.560778 -0.094852 0.822504
+vn 0.611866 -0.780511 0.128117
+vn 0.584399 -0.787194 -0.196875
+vn -0.167364 -0.398694 -0.901669
+vn 0.496323 0.007355 0.868068
+vn 0.726402 -0.601245 0.332804
+vn -0.051393 -0.503647 -0.862362
+vn 0.427442 0.104373 0.897977
+vn 0.714713 -0.462905 0.524247
+vn 0.087893 -0.611225 -0.786523
+vn 0.512375 0.023652 0.858425
+vn 0.767449 -0.411634 0.491470
+vn 0.299844 -0.659139 -0.689627
+vn 0.717612 -0.286416 0.634785
+vn 0.486099 -0.717826 -0.498367
+vn 0.654408 -0.172735 0.736106
+vn 0.650410 -0.719962 -0.242042
+vn -0.150334 -0.380566 -0.912412
+vn 0.688040 -0.720756 0.083895
+vn 0.754906 -0.654622 0.039430
+vn -0.024689 -0.475051 -0.879604
+vn 0.585253 -0.070284 0.807764
+vn 0.787957 -0.541307 0.293374
+vn 0.125156 -0.571123 -0.811243
+vn 0.602832 -0.036714 0.796991
+vn 0.844264 -0.469497 0.258400
+vn 0.146550 -0.519639 -0.841700
+vn 0.435347 0.112461 0.893185
+vn 0.523240 0.046083 0.850917
+vn 0.330271 -0.595477 -0.732292
+vn 0.813715 -0.347056 0.466231
+vn 0.528672 -0.645497 -0.551164
+vn 0.752922 -0.231330 0.616077
+vn 0.705344 -0.643696 -0.296823
+vn -0.256844 -0.290048 -0.921873
+vn -0.140690 -0.356029 -0.923795
+vn 0.680044 -0.128208 0.721854
+vn 0.815455 -0.578753 -0.007355
+vn -0.009857 -0.437086 -0.899350
+vn -0.251930 -0.278298 -0.926847
+vn -0.138829 -0.325694 -0.935209
+vn 0.697043 -0.072237 0.713370
+vn 0.870937 -0.487808 -0.058992
+vn -0.007324 -0.390484 -0.920560
+vn 0.612812 0.005432 0.790185
+vn 0.151311 -0.457076 -0.876431
+vn 0.440504 0.123569 0.889187
+vn 0.528520 0.074252 0.845637
+vn 0.896115 -0.381512 0.226630
+vn 0.341655 -0.519028 -0.783471
+vn 0.853267 -0.266732 0.448042
+vn 0.553972 -0.559618 -0.616382
+vn 0.779809 -0.162236 0.604572
+vn 0.749321 -0.553514 -0.363475
+vn 0.558458 -0.455611 -0.693167
+vn 0.796289 -0.077670 0.599872
+vn 0.779290 -0.442000 -0.444166
+vn -0.250557 -0.263619 -0.931486
+vn -0.144871 -0.290384 -0.945860
+vn 0.703879 -0.004730 0.710288
+vn 0.920011 -0.373547 -0.118320
+vn -0.017457 -0.336283 -0.941588
+vn 0.614246 0.055666 0.787103
+vn 0.138585 -0.383740 -0.912961
+vn 0.442763 0.137577 0.885983
+vn 0.527696 0.107578 0.842586
+vn 0.942289 -0.270791 0.196814
+vn 0.331828 -0.428144 -0.840541
+vn 0.884152 -0.166784 0.436384
+vn 0.977538 -0.127750 0.167425
+vn 0.297830 -0.321696 -0.898770
+vn 0.901578 -0.042238 0.430494
+vn 0.535630 -0.328318 -0.777978
+vn 0.798761 0.023988 0.601123
+vn 0.787103 -0.299081 -0.539445
+vn -0.252815 -0.246376 -0.935575
+vn -0.158635 -0.251198 -0.954833
+vn 0.698355 0.074129 0.711875
+vn 0.956328 -0.223579 -0.188147
+vn -0.040010 -0.275796 -0.960356
+vn 0.606067 0.113224 0.787286
+vn 0.107761 -0.300455 -0.947661
+vn 0.441877 0.154118 0.883694
+vn 0.520310 0.145207 0.841517
+vn 0.587024 0.176763 0.790002
+vn 0.988800 0.059053 0.136937
+vn 0.058931 -0.209296 -0.976043
+vn 0.437696 0.172826 0.882321
+vn 0.505997 0.186224 0.842158
+vn 0.237007 -0.200537 -0.950560
+vn 0.896359 0.111576 0.428999
+vn 0.476394 -0.174535 -0.861721
+vn 0.781671 0.143406 0.606952
+vn 0.756523 -0.114353 -0.643880
+vn -0.258705 -0.227119 -0.938841
+vn -0.179571 -0.209449 -0.961180
+vn 0.677633 0.163427 0.717002
+vn 0.962889 -0.022645 -0.268929
+vn -0.074343 -0.210913 -0.974639
+vn -0.268136 -0.206397 -0.941008
+vn -0.206977 -0.166662 -0.964019
+vn 0.638508 0.260689 0.724082
+vn 0.905759 0.236335 -0.351726
+vn -0.119053 -0.144200 -0.982330
+vn 0.555925 0.244392 0.794458
+vn 0.949492 0.295633 0.105014
+vn -0.006409 -0.114078 -0.993439
+vn 0.430067 0.193243 0.881832
+vn 0.484390 0.229316 0.844234
+vn 0.148839 -0.069704 -0.986389
+vn 0.853420 0.295297 0.429426
+vn 0.372051 0.001404 -0.928190
+vn 0.737663 0.278512 0.615009
+vn 0.663472 0.113041 -0.739586
+vn 0.222510 0.181219 -0.957915
+vn 0.659658 0.421155 0.622456
+vn 0.489334 0.356090 -0.796045
+vn -0.280892 -0.184851 -0.941740
+vn -0.239967 -0.124821 -0.962706
+vn 0.578539 0.360820 0.731468
+vn 0.745598 0.523728 -0.411969
+vn -0.172246 -0.079196 -0.981842
+vn 0.512131 0.312815 0.799890
+vn 0.824000 0.561357 0.076510
+vn -0.084994 -0.020936 -0.996155
+vn 0.418897 0.214789 0.882229
+vn 0.455397 0.272561 0.847530
+vn 0.037568 0.060030 -0.997467
+vn 0.754845 0.496200 0.428877
+vn 0.595019 0.681936 0.425306
+vn -0.086001 0.174383 -0.980895
+vn 0.546587 0.555406 0.626667
+vn 0.046052 0.335459 -0.940916
+vn 0.498306 0.455336 0.737785
+vn 0.251717 0.558855 -0.790094
+vn -0.296823 -0.163488 -0.940825
+vn -0.315348 -0.143925 -0.937986
+vn 0.456465 0.377300 0.805750
+vn 0.484970 0.764519 -0.424574
+vn -0.230811 -0.020173 -0.972777
+vn 0.419721 0.313120 0.851894
+vn 0.603229 0.795221 0.060915
+vn -0.171026 0.062593 -0.983245
+vn 0.404035 0.236488 0.883633
+vn 0.385876 0.256752 0.886074
+vn 0.379620 0.348277 0.857051
+vn 0.335063 0.940214 0.060549
+vn -0.290597 0.029206 -0.956389
+vn 0.365856 0.273995 0.889401
+vn 0.396496 0.817225 0.418165
+vn -0.257241 0.130680 -0.957457
+vn 0.409009 0.663747 0.626179
+vn -0.207831 0.262917 -0.942137
+vn 0.403546 0.535325 0.741997
+vn -0.127384 0.444197 -0.886807
+vn -0.276864 -0.086550 -0.956969
+vn -0.334910 -0.127537 -0.933561
+vn 0.392468 0.432966 0.811457
+vn 0.191076 0.900021 -0.391644
+vn -0.315226 -0.054170 -0.947447
+vn 0.324717 0.476821 0.816797
+vn 0.007721 0.682333 -0.730949
+vn -0.197821 0.734703 -0.648885
+vn -0.352824 -0.028565 -0.935240
+vn 0.337718 0.376446 0.862667
+vn 0.082888 0.994110 0.069613
+vn -0.348155 0.067507 -0.934996
+vn 0.345470 0.287576 0.893246
+vn 0.195349 0.891232 0.409284
+vn -0.338145 0.181310 -0.923429
+vn 0.263985 0.737236 0.621906
+vn -0.318125 0.323740 -0.891018
+vn 0.302683 0.595416 0.744163
+vn -0.277840 0.508042 -0.815271
+vn -0.354167 -0.114750 -0.928098
+vn 0.203497 0.634297 0.745811
+vn -0.401379 0.537400 -0.741661
+vn -0.372417 -0.105533 -0.922025
+vn 0.257363 0.507614 0.822230
+vn -0.065035 0.939451 -0.336436
+vn -0.357158 0.742424 -0.566729
+vn -0.388379 -0.010071 -0.921415
+vn 0.296213 0.396893 0.868740
+vn -0.123203 0.988769 0.084262
+vn -0.401624 0.094485 -0.910886
+vn 0.325632 0.297433 0.897458
+vn 0.016022 0.915189 0.402661
+vn -0.411145 0.214972 -0.885830
+vn 0.126011 0.776727 0.617084
+vn -0.413770 0.359905 -0.836177
+vn -0.475661 0.232948 -0.848201
+vn 0.003479 0.788049 0.615589
+vn -0.495315 0.375500 -0.783319
+vn 0.111850 0.652974 0.749046
+vn -0.501846 0.542161 -0.673910
+vn -0.389233 -0.099948 -0.915677
+vn 0.193945 0.525071 0.828639
+vn -0.261513 0.924284 -0.277963
+vn -0.479873 0.725211 -0.493698
+vn -0.421064 0.001221 -0.907010
+vn 0.256905 0.409284 0.875454
+vn -0.283059 0.953429 0.103916
+vn -0.450026 0.110294 -0.886166
+vn 0.307047 0.303446 0.901975
+vn -0.133396 0.905759 0.402203
+vn -0.408460 0.884945 -0.223548
+vn -0.406873 0.904324 0.128849
+vn -0.492874 0.115299 -0.862392
+vn 0.290414 0.305582 0.906766
+vn -0.254219 0.875729 0.410413
+vn -0.531846 0.236641 -0.813074
+vn -0.100314 0.777764 0.620472
+vn -0.564745 0.373974 -0.735618
+vn 0.031495 0.653798 0.755974
+vn -0.584674 0.529099 -0.614917
+vn -0.404187 -0.097934 -0.909391
+vn 0.137181 0.529618 0.837031
+vn -0.577105 0.693472 -0.431257
+vn -0.450270 0.005341 -0.892850
+vn 0.221473 0.413526 0.883114
+vn 0.089175 0.522141 0.848170
+vn -0.521287 0.835414 -0.174047
+vn -0.657369 0.651723 -0.378216
+vn -0.475509 0.002380 -0.879696
+vn 0.191290 0.409833 0.891842
+vn -0.504807 0.848323 0.159551
+vn -0.529893 0.109989 -0.840877
+vn 0.276254 0.303903 0.911740
+vn -0.350749 0.832575 0.428632
+vn -0.580157 0.227302 -0.782098
+vn -0.185034 0.751030 0.633778
+vn -0.624012 0.357830 -0.694632
+vn -0.035432 0.639210 0.768181
+vn -0.654500 0.502121 -0.565203
+vn -0.417005 -0.099460 -0.903439
+vn -0.087893 0.611225 0.786523
+vn -0.714713 0.462905 -0.524247
+vn -0.427442 -0.104373 -0.897977
+vn 0.051363 0.503647 0.862362
+vn -0.611866 0.780480 -0.128117
+vn -0.726402 0.601245 -0.332835
+vn -0.496323 -0.007355 -0.868068
+vn 0.167333 0.398694 0.901669
+vn -0.584399 0.787194 0.196875
+vn -0.560778 0.094852 -0.822504
+vn 0.264992 0.298654 0.916807
+vn -0.427107 0.779748 0.457717
+vn -0.620991 0.205847 -0.756279
+vn -0.251381 0.710990 0.656697
+vn -0.674673 0.328471 -0.660970
+vn -0.654408 0.172735 -0.736106
+vn -0.486099 0.717826 0.498367
+vn -0.717612 0.286416 -0.634785
+vn -0.299844 0.659139 0.689627
+vn -0.767449 0.411634 -0.491470
+vn -0.512375 -0.023652 -0.858425
+vn -0.125156 0.571123 0.811243
+vn -0.688040 0.720756 -0.083895
+vn -0.787957 0.541337 -0.293344
+vn -0.585253 0.070284 -0.807764
+vn 0.024689 0.475051 0.879604
+vn -0.754906 0.654622 -0.039430
+vn 0.150334 0.380566 0.912412
+vn -0.650410 0.719962 0.242042
+vn -0.815455 0.578753 0.007355
+vn -0.680044 0.128178 -0.721854
+vn 0.256844 0.290048 0.921873
+vn 0.140690 0.356029 0.923795
+vn -0.705344 0.643696 0.296823
+vn -0.752922 0.231330 -0.616077
+vn -0.528703 0.645497 0.551164
+vn -0.813715 0.347087 -0.466231
+vn -0.330271 0.595508 0.732292
+vn -0.844264 0.469497 -0.258400
+vn -0.435347 -0.112461 -0.893185
+vn -0.523240 -0.046083 -0.850917
+vn -0.146550 0.519639 0.841700
+vn -0.602832 0.036714 -0.796991
+vn 0.009857 0.437056 0.899350
+vn -0.151311 0.457076 0.876431
+vn -0.870937 0.487808 0.058992
+vn -0.612812 -0.005432 -0.790185
+vn 0.007355 0.390515 0.920560
+vn -0.697043 0.072237 -0.713370
+vn 0.251930 0.278298 0.926847
+vn 0.138829 0.325694 0.935209
+vn -0.749321 0.553514 0.363475
+vn -0.779809 0.162236 -0.604572
+vn -0.553972 0.559618 0.616382
+vn -0.853267 0.266732 -0.448042
+vn -0.341655 0.519028 0.783471
+vn -0.896115 0.381512 -0.226630
+vn -0.440504 -0.123569 -0.889187
+vn -0.528520 -0.074282 -0.845637
+vn -0.331828 0.428144 0.840571
+vn -0.942289 0.270791 -0.196783
+vn -0.442763 -0.137577 -0.885983
+vn -0.527696 -0.107578 -0.842586
+vn -0.138615 0.383740 0.912961
+vn -0.920011 0.373547 0.118320
+vn -0.614277 -0.055666 -0.787103
+vn 0.017457 0.336283 0.941588
+vn -0.703879 0.004730 -0.710288
+vn 0.250557 0.263619 0.931486
+vn 0.144871 0.290384 0.945860
+vn -0.779290 0.442000 0.444166
+vn -0.796289 0.077670 -0.599872
+vn -0.558458 0.455611 0.693167
+vn -0.884152 0.166784 -0.436384
+vn -0.535661 0.328318 0.777978
+vn -0.901578 0.042268 -0.430494
+vn -0.297830 0.321696 0.898770
+vn -0.977538 0.127750 -0.167425
+vn -0.441877 -0.154118 -0.883724
+vn -0.520310 -0.145207 -0.841517
+vn -0.107761 0.300455 0.947661
+vn -0.956328 0.223579 0.188147
+vn -0.606067 -0.113224 -0.787286
+vn 0.040010 0.275796 0.960356
+vn -0.698355 -0.074129 -0.711875
+vn 0.252815 0.246376 0.935606
+vn 0.158635 0.251198 0.954833
+vn -0.787072 0.299081 0.539445
+vn -0.798761 -0.023957 -0.601154
+vn -0.677633 -0.163427 -0.717002
+vn 0.258736 0.227119 0.938841
+vn 0.179601 0.209449 0.961150
+vn -0.756523 0.114353 0.643880
+vn -0.781671 -0.143406 -0.606952
+vn -0.476394 0.174535 0.861721
+vn -0.896359 -0.111576 -0.428999
+vn -0.237007 0.200537 0.950560
+vn -0.988800 -0.059084 -0.136937
+vn -0.437666 -0.172857 -0.882351
+vn -0.505997 -0.186224 -0.842158
+vn -0.058931 0.209296 0.976074
+vn -0.587024 -0.176763 -0.790002
+vn 0.074343 0.210913 0.974639
+vn -0.962889 0.022645 0.268929
+vn -0.949492 -0.295633 -0.105014
+vn -0.555956 -0.244392 -0.794458
+vn 0.119053 0.144230 0.982330
+vn -0.905759 -0.236305 0.351726
+vn -0.638508 -0.260689 -0.724082
+vn 0.268105 0.206397 0.941008
+vn 0.206977 0.166662 0.964019
+vn -0.663472 -0.113041 0.739586
+vn -0.737663 -0.278512 -0.615009
+vn -0.372021 -0.001404 0.928190
+vn -0.853420 -0.295297 -0.429426
+vn -0.148808 0.069704 0.986389
+vn -0.430067 -0.193243 -0.881863
+vn -0.484390 -0.229316 -0.844234
+vn 0.006409 0.114078 0.993439
+vn -0.037568 -0.060030 0.997467
+vn -0.824030 -0.561327 -0.076510
+vn -0.418897 -0.214789 -0.882229
+vn -0.455397 -0.272561 -0.847530
+vn 0.084994 0.020936 0.996155
+vn -0.512131 -0.312815 -0.799890
+vn 0.172246 0.079196 0.981842
+vn -0.745628 -0.523728 0.411969
+vn -0.578539 -0.360820 -0.731468
+vn 0.280862 0.184851 0.941771
+vn 0.239937 0.124821 0.962706
+vn -0.489334 -0.356090 0.796045
+vn -0.659658 -0.421155 -0.622456
+vn -0.222510 -0.181219 0.957915
+vn -0.754845 -0.496200 -0.428877
+vn 0.350932 0.200903 0.914579
+vn -0.350932 -0.200903 -0.914579
+vn 0.296823 0.163488 0.940794
+vn -0.404035 -0.236488 -0.883633
+vn -0.595019 -0.681936 -0.425306
+vn -0.385876 -0.256752 -0.886074
+vn 0.290567 -0.029206 0.956389
+vn -0.335063 -0.940214 -0.060579
+vn 0.276864 0.086550 0.956969
+vn 0.315226 0.054170 0.947447
+vn 0.315348 0.143925 0.937986
+vn 0.334910 0.127537 0.933561
+vn -0.403546 -0.535295 -0.741997
+vn 0.207801 -0.262917 0.942137
+vn -0.345439 -0.287576 -0.893246
+vn 0.354198 0.114750 0.928098
+vn -0.302652 -0.595447 -0.744194
+vn 0.413770 -0.359935 0.836177
+vn 0.065035 -0.939421 0.336436
+vn -0.296213 -0.396893 -0.868740
+vn 0.388379 0.010071 0.921415
+vn -0.257393 -0.507614 -0.822199
+vn 0.389203 0.099948 0.915677
+vn -0.307047 -0.303446 -0.901975
+vn -0.256905 -0.409284 -0.875454
+vn 0.421094 -0.001221 0.907010
+vn -0.221503 -0.413526 -0.883114
+vn 0.450301 -0.005341 0.892850
+vn 0.577105 -0.693472 0.431257
+vn -0.137181 -0.529618 -0.837031
+vn 0.404157 0.097934 0.909391
+vn 0.564745 -0.373974 0.735649
+vn -0.290445 -0.305582 -0.906766
+vn 0.406873 -0.904324 -0.128849
+vn -0.276284 -0.303903 -0.911740
+vn 0.657399 -0.651723 0.378216
+vn 0.417005 0.099460 0.903409
+vn 0.654530 -0.502121 0.565172
+vn 0.580157 -0.227302 0.782098
+vn 0.251381 -0.711020 -0.656667
+vn 0.560778 -0.094852 0.822474
+vn -0.167333 -0.398694 -0.901669
+vn 0.787957 -0.541307 0.293344
+vn 0.330302 -0.595477 -0.732292
+vn 0.813715 -0.347087 0.466231
+vn 0.528703 -0.645497 -0.551164
+vn 0.680044 -0.128178 0.721854
+vn -0.251961 -0.278298 -0.926847
+vn -0.007324 -0.390515 -0.920560
+vn 0.612812 0.005402 0.790185
+vn 0.440535 0.123569 0.889157
+vn 0.558458 -0.455611 -0.693197
+vn -0.144902 -0.290384 -0.945860
+vn 0.614277 0.055666 0.787103
+vn 0.138615 -0.383740 -0.912961
+vn 0.331828 -0.428144 -0.840571
+vn 0.798761 0.023957 0.601154
+vn 0.787072 -0.299081 -0.539445
+vn -0.252815 -0.246376 -0.935606
+vn -0.040040 -0.275796 -0.960356
+vn 0.988800 0.059084 0.136937
+vn 0.058931 -0.209296 -0.976074
+vn 0.437666 0.172857 0.882351
+vn 0.962889 -0.022614 -0.268929
+vn -0.074343 -0.210913 -0.974670
+vn 0.905759 0.236305 -0.351726
+vn 0.555956 0.244392 0.794458
+vn 0.430036 0.193243 0.881863
+vn 0.484390 0.229286 0.844234
+vn 0.148808 -0.069704 -0.986389
+vn 0.372021 0.001404 -0.928190
+vn 0.659658 0.421155 0.622425
+vn -0.239937 -0.124821 -0.962706
+vn 0.745628 0.523728 -0.411969
+vn -0.172277 -0.079196 -0.981842
+vn 0.037538 0.060030 -0.997467
+vn 0.251717 0.558855 -0.790124
+vn -0.296854 -0.163488 -0.940794
+vn 0.484970 0.764519 -0.424604
+vn 0.419721 0.313150 0.851894
+vn 0.365886 0.273995 0.889401
+vn 0.403516 0.535325 0.741997
+vn 0.007752 0.682333 -0.730949
+vn -0.352824 -0.028596 -0.935240
+vn -0.338115 0.181310 -0.923460
+vn 0.302683 0.595416 0.744194
+vn -0.277871 0.508042 -0.815271
+vn 0.257393 0.507614 0.822199
+vn -0.357189 0.742424 -0.566729
+vn 0.296182 0.396893 0.868740
+vn 0.003449 0.788049 0.615589
+vn -0.389203 -0.099948 -0.915708
+vn 0.256874 0.409284 0.875454
+vn -0.450026 0.110294 -0.886135
+vn -0.408460 0.884976 -0.223548
+vn -0.564745 0.373974 -0.735649
+vn -0.404157 -0.097934 -0.909421
+vn -0.450301 0.005341 -0.892850
+vn 0.276284 0.303903 0.911740
+vn -0.580157 0.227332 -0.782098
+vn -0.654530 0.502121 -0.565172
+vn -0.417005 -0.099460 -0.903409
+vn -0.611866 0.780511 -0.128117
+vn -0.726402 0.601245 -0.332804
+vn -0.427137 0.779748 0.457747
+vn -0.251381 0.711020 0.656667
+vn -0.787957 0.541307 -0.293344
+vn -0.528672 0.645497 0.551164
+vn -0.612812 -0.005402 -0.790185
+vn 0.007324 0.390515 0.920560
+vn 0.251961 0.278329 0.926817
+vn -0.440535 -0.123569 -0.889157
+vn -0.528520 -0.074252 -0.845637
+vn -0.331828 0.428144 0.840541
+vn -0.138585 0.383740 0.912961
+vn -0.614246 -0.055666 -0.787103
+vn -0.535630 0.328318 0.777978
+vn 0.258705 0.227119 0.938841
+vn 0.179571 0.209449 0.961150
+vn -0.988800 -0.059053 -0.136937
+vn 0.074313 0.210913 0.974639
+vn -0.430067 -0.193243 -0.881832
+vn -0.824000 -0.561327 -0.076510
+vn -0.418867 -0.214789 -0.882260
+vn 0.280892 0.184851 0.941740
+vn 0.239967 0.124821 0.962706
+vn 0.296854 0.163488 0.940794
+vn -0.404004 -0.236488 -0.883633
+usemtl SkinColor
+s 1
+f 3381//2303 3380//2304 3395//2305
+f 3376//2306 3375//2307 3390//2308
+f 3387//2309 3386//2310 3402//2311
+f 3382//2312 3381//2303 3396//2313
+f 3377//2314 3376//2306 3391//2315
+f 3388//2316 3387//2309 3403//2317
+f 3383//2318 3382//2312 3397//2319
+f 3378//2320 3377//2314 3392//2321
+f 3389//2322 3388//2316 3404//2323
+f 3384//2324 3383//2318 3399//2325
+f 3379//2326 3378//2320 3393//2327
+f 3385//2328 3384//2324 3400//2329
+f 3380//2304 3379//2326 3394//2330
+f 3386//2310 3385//2328 3401//2331
+f 3396//2313 3395//2305 3410//2332
+f 3391//2315 3390//2308 3405//2333
+f 3402//2311 3401//2331 3417//2334
+f 3397//2319 3396//2313 3411//2335
+f 3392//2321 3391//2315 3406//2336
+f 3403//2317 3402//2311 3418//2337
+f 3398//2338 3397//2319 3413//2339
+f 3393//2327 3392//2321 3407//2340
+f 3404//2323 3403//2317 3419//2341
+f 3399//2325 3398//2338 3414//2342
+f 3394//2330 3393//2327 3408//2343
+f 3400//2329 3399//2325 3415//2344
+f 3395//2305 3394//2330 3409//2345
+f 3401//2331 3400//2329 3416//2346
+f 3415//2344 3414//2342 3430//2347
+f 3410//2332 3409//2345 3424//2348
+f 3416//2346 3415//2344 3431//2349
+f 3411//2335 3410//2332 3425//2350
+f 3406//2336 3405//2333 3420//2351
+f 3417//2334 3416//2346 3432//2352
+f 3412//2353 3411//2335 3426//2354
+f 3407//2340 3406//2336 3421//2355
+f 3418//2337 3417//2334 3433//2356
+f 3413//2339 3412//2353 3428//2357
+f 3408//2343 3407//2340 3422//2358
+f 3419//2341 3418//2337 3434//2359
+f 3414//2342 3413//2339 3429//2360
+f 3409//2345 3408//2343 3423//2361
+f 3434//2359 3433//2356 3449//2362
+f 3429//2360 3428//2357 3444//2363
+f 3424//2348 3423//2361 3438//2364
+f 3430//2347 3429//2360 3445//2365
+f 3425//2350 3424//2348 3439//2366
+f 3431//2349 3430//2347 3446//2367
+f 3426//2354 3425//2350 3440//2368
+f 3421//2355 3420//2351 3435//2369
+f 3432//2352 3431//2349 3447//2370
+f 3427//2371 3426//2354 3441//2372
+f 3422//2358 3421//2355 3436//2373
+f 3433//2356 3432//2352 3448//2374
+f 3428//2357 3427//2371 3443//2375
+f 3423//2361 3422//2358 3437//2376
+f 3437//2376 3436//2373 3451//2377
+f 3448//2374 3447//2370 3463//2378
+f 3443//2375 3442//2379 3458//2380
+f 3438//2364 3437//2376 3452//2381
+f 3449//2362 3448//2374 3464//2382
+f 3444//2363 3443//2375 3459//2383
+f 3439//2366 3438//2364 3453//2384
+f 3445//2365 3444//2363 3460//2385
+f 3440//2368 3439//2366 3454//2386
+f 3446//2367 3445//2365 3461//2387
+f 3441//2372 3440//2368 3455//2388
+f 3436//2373 3435//2369 3450//2389
+f 3447//2370 3446//2367 3462//2390
+f 3442//2379 3441//2372 3456//2391
+f 3456//2391 3455//2388 3470//2392
+f 3451//2377 3450//2389 3465//2393
+f 3462//2390 3461//2387 3477//2394
+f 3457//2395 3456//2391 3471//2396
+f 3452//2381 3451//2377 3466//2397
+f 3463//2378 3462//2390 3478//2398
+f 3458//2380 3457//2395 3473//2399
+f 3453//2384 3452//2381 3467//2400
+f 3464//2382 3463//2378 3479//2401
+f 3459//2383 3458//2380 3474//2402
+f 3454//2386 3453//2384 3468//2403
+f 3460//2385 3459//2383 3475//2404
+f 3455//2388 3454//2386 3469//2405
+f 3461//2387 3460//2385 3476//2406
+f 3475//2404 3474//2402 3490//2407
+f 3470//2392 3469//2405 3484//2408
+f 3476//2406 3475//2404 3491//2409
+f 3471//2396 3470//2392 3485//2410
+f 3466//2397 3465//2393 3480//2411
+f 3477//2394 3476//2406 3492//2412
+f 3472//2413 3471//2396 3486//2414
+f 3467//2400 3466//2397 3481//2415
+f 3478//2398 3477//2394 3493//2416
+f 3473//2399 3472//2413 3488//2417
+f 3468//2403 3467//2400 3482//2418
+f 3479//2401 3478//2398 3494//2419
+f 3474//2402 3473//2399 3489//2420
+f 3469//2405 3468//2403 3483//2421
+f 3494//2419 3493//2416 3508//2422
+f 3489//2420 3488//2417 3504//2423
+f 3484//2408 3483//2421 3499//2424
+f 3490//2407 3489//2420 3505//2425
+f 3485//2410 3484//2408 3500//2426
+f 3491//2409 3490//2407 3506//2427
+f 3486//2414 3485//2410 3501//2428
+f 3481//2415 3480//2411 3496//2429
+f 3492//2412 3491//2409 3506//2427
+f 3487//2430 3486//2414 3502//2431
+f 3482//2418 3481//2415 3497//2432
+f 3493//2416 3492//2412 3507//2433
+f 3488//2417 3487//2430 3503//2434
+f 3483//2421 3482//2418 3498//2435
+f 3508//2422 3507//2433 3522//2436
+f 3503//2434 3502//2431 3518//2437
+f 3498//2435 3497//2432 3513//2438
+f 3509//2439 3508//2422 3523//2440
+f 3504//2423 3503//2434 3518//2437
+f 3499//2424 3498//2435 3514//2441
+f 3505//2425 3504//2423 3519//2442
+f 3500//2426 3499//2424 3515//2443
+f 3506//2427 3505//2425 3520//2444
+f 3501//2428 3500//2426 3516//2445
+f 3496//2429 3495//2446 3511//2447
+f 3507//2433 3506//2427 3521//2448
+f 3502//2431 3501//2428 3517//2449
+f 3497//2432 3496//2429 3512//2450
+f 3511//2447 3510//2451 3526//2452
+f 3522//2436 3521//2448 3536//2453
+f 3517//2449 3516//2445 3532//2454
+f 3512//2450 3511//2447 3527//2455
+f 3523//2440 3522//2436 3537//2456
+f 3518//2437 3517//2449 3532//2454
+f 3513//2438 3512//2450 3528//2457
+f 3524//2458 3523//2440 3538//2459
+f 3519//2442 3518//2437 3533//2460
+f 3514//2441 3513//2438 3529//2461
+f 3520//2444 3519//2442 3534//2462
+f 3515//2443 3514//2441 3530//2463
+f 3521//2448 3520//2444 3535//2464
+f 3516//2445 3515//2443 3531//2465
+f 3530//2463 3529//2461 3545//2466
+f 3536//2453 3535//2464 3550//2467
+f 3531//2465 3530//2463 3546//2468
+f 3526//2452 3525//2469 3541//2470
+f 3537//2456 3536//2453 3551//2471
+f 3532//2454 3531//2465 3547//2472
+f 3527//2455 3526//2452 3542//2473
+f 3538//2459 3537//2456 3552//2474
+f 3533//2460 3532//2454 3547//2472
+f 3528//2457 3527//2455 3543//2475
+f 3539//2476 3538//2459 3553//2477
+f 3534//2462 3533//2460 3548//2478
+f 3529//2461 3528//2457 3544//2479
+f 3535//2464 3534//2462 3549//2480
+f 3549//2480 3548//2478 3563//2481
+f 3544//2479 3543//2475 3559//2482
+f 3550//2467 3549//2480 3564//2483
+f 3545//2466 3544//2479 3560//2484
+f 3551//2471 3550//2467 3565//2485
+f 3546//2468 3545//2466 3561//2486
+f 3541//2470 3540//2487 3556//2488
+f 3552//2474 3551//2471 3566//2489
+f 3547//2472 3546//2468 3562//2490
+f 3542//2473 3541//2470 3557//2491
+f 3553//2477 3552//2474 3567//2492
+f 3548//2478 3547//2472 3562//2490
+f 3543//2475 3542//2473 3558//2493
+f 3554//2494 3553//2477 3568//2495
+f 3568//2495 3567//2492 3582//2496
+f 3563//2481 3562//2490 3578//2497
+f 3558//2493 3557//2491 3573//2498
+f 3569//2499 3568//2495 3583//2500
+f 3564//2483 3563//2481 3578//2497
+f 3559//2482 3558//2493 3574//2501
+f 3565//2485 3564//2483 3579//2502
+f 3560//2484 3559//2482 3575//2503
+f 3566//2489 3565//2485 3580//2504
+f 3561//2486 3560//2484 3576//2505
+f 3556//2488 3555//2506 3571//2507
+f 3567//2492 3566//2489 3581//2508
+f 3562//2490 3561//2486 3577//2509
+f 3557//2491 3556//2488 3572//2510
+f 3571//2507 3570//2511 3586//2512
+f 3582//2496 3581//2508 3596//2513
+f 3577//2509 3576//2505 3592//2514
+f 3572//2510 3571//2507 3587//2515
+f 3583//2500 3582//2496 3597//2516
+f 3578//2497 3577//2509 3593//2517
+f 3573//2498 3572//2510 3588//2518
+f 3584//2519 3583//2500 3598//2520
+f 3579//2502 3578//2497 3593//2517
+f 3574//2501 3573//2498 3589//2521
+f 3580//2504 3579//2502 3594//2522
+f 3575//2503 3574//2501 3590//2523
+f 3581//2508 3580//2504 3595//2524
+f 3576//2505 3575//2503 3591//2525
+f 3590//2523 3589//2521 3605//2526
+f 3596//2513 3595//2524 3610//2527
+f 3591//2525 3590//2523 3606//2528
+f 3586//2512 3585//2529 3601//2530
+f 3597//2516 3596//2513 3611//2531
+f 3592//2514 3591//2525 3607//2532
+f 3587//2515 3586//2512 3602//2533
+f 3598//2520 3597//2516 3612//2534
+f 3593//2517 3592//2514 3608//2535
+f 3588//2518 3587//2515 3603//2536
+f 3599//2537 3598//2520 3613//2538
+f 3594//2522 3593//2517 3608//2535
+f 3589//2521 3588//2518 3604//2539
+f 3595//2524 3594//2522 3609//2540
+f 3609//2540 3608//2535 3624//2541
+f 3604//2539 3603//2536 3619//2542
+f 3610//2527 3609//2540 3625//2543
+f 3605//2526 3604//2539 3620//2544
+f 3611//2531 3610//2527 3626//2545
+f 3606//2528 3605//2526 3621//2546
+f 3601//2530 3600//2547 3615//2548
+f 3612//2534 3611//2531 3627//2549
+f 3607//2532 3606//2528 3622//2550
+f 3602//2533 3601//2530 3617//2551
+f 3613//2538 3612//2534 3628//2552
+f 3608//2535 3607//2532 3623//2553
+f 3603//2536 3602//2533 3618//2554
+f 3614//2555 3613//2538 3629//2556
+f 3628//2552 3627//2549 3643//2557
+f 3623//2553 3622//2550 3638//2558
+f 3618//2554 3617//2551 3632//2559
+f 3629//2556 3628//2552 3644//2560
+f 3624//2541 3623//2553 3639//2561
+f 3619//2542 3618//2554 3633//2562
+f 3625//2543 3624//2541 3640//2563
+f 3620//2544 3619//2542 3634//2564
+f 3626//2545 3625//2543 3641//2565
+f 3621//2546 3620//2544 3635//2566
+f 3616//2567 3615//2548 3630//2568
+f 3627//2549 3626//2545 3642//2569
+f 3622//2550 3621//2546 3637//2570
+f 3617//2551 3616//2567 3631//2571
+f 3642//2569 3641//2565 3657//2572
+f 3637//2570 3636//2573 3651//2574
+f 3632//2559 3631//2571 3646//2575
+f 3643//2557 3642//2569 3658//2576
+f 3638//2558 3637//2570 3653//2577
+f 3633//2562 3632//2559 3647//2578
+f 3644//2560 3643//2557 3659//2579
+f 3639//2561 3638//2558 3654//2580
+f 3634//2564 3633//2562 3648//2581
+f 3640//2563 3639//2561 3655//2582
+f 3635//2566 3634//2564 3649//2583
+f 3641//2565 3640//2563 3656//2584
+f 3636//2573 3635//2566 3650//2585
+f 3631//2571 3630//2568 3645//2586
+f 3656//2584 3655//2582 3671//2587
+f 3651//2574 3650//2585 3665//2588
+f 3646//2575 3645//2586 3660//2589
+f 3657//2572 3656//2584 3672//2590
+f 3652//2591 3651//2574 3666//2592
+f 3647//2578 3646//2575 3661//2593
+f 3658//2576 3657//2572 3673//2594
+f 3653//2577 3652//2591 3668//2595
+f 3648//2581 3647//2578 3662//2596
+f 3659//2579 3658//2576 3674//2597
+f 3654//2580 3653//2577 3669//2598
+f 3649//2583 3648//2581 3663//2599
+f 3655//2582 3654//2580 3670//2600
+f 3650//2585 3649//2583 3664//2601
+f 3664//2601 3663//2599 3678//2602
+f 3670//2600 3669//2598 3685//2603
+f 3665//2588 3664//2601 3679//2604
+f 3671//2587 3670//2600 3686//2605
+f 3666//2592 3665//2588 3680//2606
+f 3661//2593 3660//2589 3675//2607
+f 3672//2590 3671//2587 3687//2608
+f 3667//2609 3666//2592 3681//2610
+f 3662//2596 3661//2593 3676//2611
+f 3673//2594 3672//2590 3688//2612
+f 3668//2595 3667//2609 3683//2613
+f 3663//2599 3662//2596 3677//2614
+f 3674//2597 3673//2594 3689//2615
+f 3669//2598 3668//2595 3684//2616
+f 3683//2613 3682//2617 3698//2618
+f 3678//2602 3677//2614 3692//2619
+f 3689//2615 3688//2612 3704//2620
+f 3684//2616 3683//2613 3699//2621
+f 3679//2604 3678//2602 3693//2622
+f 3685//2603 3684//2616 3700//2623
+f 3680//2606 3679//2604 3694//2624
+f 3686//2605 3685//2603 3701//2625
+f 3681//2610 3680//2606 3695//2626
+f 3676//2611 3675//2607 3690//2627
+f 3687//2608 3686//2605 3702//2628
+f 3682//2617 3681//2610 3696//2629
+f 3677//2614 3676//2611 3691//2630
+f 3688//2612 3687//2608 3703//2631
+f 3702//2628 3701//2625 3718//2632
+f 3697//2633 3696//2629 3712//2634
+f 3692//2619 3691//2630 3707//2635
+f 3703//2631 3702//2628 3719//2636
+f 3698//2618 3697//2633 3714//2637
+f 3693//2622 3692//2619 3708//2638
+f 3704//2620 3703//2631 3720//2639
+f 3699//2621 3698//2618 3715//2640
+f 3694//2624 3693//2622 3709//2641
+f 3700//2623 3699//2621 3716//2642
+f 3695//2626 3694//2624 3710//2643
+f 3701//2625 3700//2623 3717//2644
+f 3696//2629 3695//2626 3711//2645
+f 3691//2630 3690//2627 3706//2646
+f 3717//2644 3716//2642 3732//2647
+f 3712//2634 3711//2645 3726//2648
+f 3707//2635 3706//2646 3721//2649
+f 3718//2632 3717//2644 3733//2650
+f 3713//2651 3712//2634 3727//2652
+f 3708//2638 3707//2635 3722//2653
+f 3719//2636 3718//2632 3734//2654
+f 3714//2637 3713//2651 3729//2655
+f 3709//2641 3708//2638 3723//2656
+f 3720//2639 3719//2636 3735//2657
+f 3715//2640 3714//2637 3730//2658
+f 3710//2643 3709//2641 3724//2659
+f 3716//2642 3715//2640 3731//2660
+f 3711//2645 3710//2643 3725//2661
+f 3725//2661 3724//2659 3739//2662
+f 3731//2660 3730//2658 3745//2663
+f 3726//2648 3725//2661 3740//2664
+f 3732//2647 3731//2660 3746//2665
+f 3727//2652 3726//2648 3741//2666
+f 3722//2653 3721//2649 3737//2667
+f 3733//2650 3732//2647 3747//2668
+f 3728//2669 3727//2652 3742//2670
+f 3723//2656 3722//2653 3738//2671
+f 3734//2654 3733//2650 3748//2672
+f 3729//2655 3728//2669 3743//2673
+f 3724//2659 3723//2656 3739//2662
+f 3735//2657 3734//2654 3749//2674
+f 3730//2658 3729//2655 3744//2675
+f 3744//2675 3743//2673 3758//2676
+f 3739//2662 3738//2671 3754//2677
+f 3750//2678 3749//2674 3764//2679
+f 3745//2663 3744//2675 3759//2680
+f 3740//2664 3739//2662 3755//2681
+f 3746//2665 3745//2663 3760//2682
+f 3741//2666 3740//2664 3756//2683
+f 3747//2668 3746//2665 3761//2684
+f 3742//2670 3741//2666 3757//2685
+f 3737//2667 3736//2686 3752//2687
+f 3748//2672 3747//2668 3762//2688
+f 3743//2673 3742//2670 3757//2685
+f 3738//2671 3737//2667 3753//2689
+f 3749//2674 3748//2672 3763//2690
+f 3763//2690 3762//2688 3777//2691
+f 3758//2676 3757//2685 3773//2692
+f 3753//2689 3752//2687 3768//2693
+f 3764//2679 3763//2690 3778//2694
+f 3759//2680 3758//2676 3773//2692
+f 3754//2677 3753//2689 3769//2695
+f 3765//2696 3764//2679 3779//2697
+f 3760//2682 3759//2680 3774//2698
+f 3755//2681 3754//2677 3770//2699
+f 3761//2684 3760//2682 3775//2700
+f 3756//2683 3755//2681 3771//2701
+f 3762//2688 3761//2684 3776//2702
+f 3757//2685 3756//2683 3772//2703
+f 3752//2687 3751//2704 3767//2705
+f 3777//2691 3776//2702 3791//2706
+f 3772//2703 3771//2701 3787//2707
+f 3767//2705 3766//2708 3782//2709
+f 3778//2694 3777//2691 3792//2710
+f 3773//2692 3772//2703 3788//2711
+f 3768//2693 3767//2705 3783//2712
+f 3779//2697 3778//2694 3793//2713
+f 3774//2698 3773//2692 3788//2711
+f 3769//2695 3768//2693 3784//2714
+f 3780//2715 3779//2697 3794//2716
+f 3775//2700 3774//2698 3789//2717
+f 3770//2699 3769//2695 3785//2718
+f 3776//2702 3775//2700 3790//2719
+f 3771//2701 3770//2699 3786//2720
+f 3791//2706 3790//2719 3805//2721
+f 3786//2720 3785//2718 3801//2722
+f 3792//2710 3791//2706 3806//2723
+f 3787//2707 3786//2720 3802//2724
+f 3782//2709 3781//2725 3797//2726
+f 3793//2713 3792//2710 3807//2727
+f 3788//2711 3787//2707 3803//2728
+f 3783//2712 3782//2709 3798//2729
+f 3794//2716 3793//2713 3808//2730
+f 3789//2717 3788//2711 3803//2728
+f 3784//2714 3783//2712 3799//2731
+f 3795//2732 3794//2716 3809//2733
+f 3790//2719 3789//2717 3804//2734
+f 3785//2718 3784//2714 3800//2735
+f 3799//2731 3798//2729 3814//2736
+f 3810//2737 3809//2733 3824//2738
+f 3805//2721 3804//2734 3819//2739
+f 3800//2735 3799//2731 3815//2740
+f 3806//2723 3805//2721 3820//2741
+f 3801//2722 3800//2735 3816//2742
+f 3807//2727 3806//2723 3821//2743
+f 3802//2724 3801//2722 3817//2744
+f 3797//2726 3796//2745 3812//2746
+f 3808//2730 3807//2727 3822//2747
+f 3803//2728 3802//2724 3817//2744
+f 3798//2729 3797//2726 3813//2748
+f 3809//2733 3808//2730 3823//2749
+f 3804//2734 3803//2728 3818//2750
+f 3818//2750 3817//2744 3833//2751
+f 3813//2748 3812//2746 3829//2752
+f 3824//2738 3823//2749 3839//2753
+f 3819//2739 3818//2750 3834//2754
+f 3814//2736 3813//2748 3830//2755
+f 3825//2756 3824//2738 3840//2757
+f 3820//2741 3819//2739 3835//2758
+f 3815//2740 3814//2736 3831//2759
+f 3821//2743 3820//2741 3836//2760
+f 3816//2742 3815//2740 3832//2761
+f 3822//2747 3821//2743 3837//2762
+f 3817//2744 3816//2742 3833//2751
+f 3812//2746 3811//2763 3828//2764
+f 3823//2749 3822//2747 3838//2765
+f 3838//2765 3837//2762 3852//2766
+f 3833//2751 3832//2761 3848//2767
+f 3828//2764 3827//2768 3843//2769
+f 3839//2753 3838//2765 3853//2770
+f 3834//2754 3833//2751 3848//2767
+f 3829//2752 3828//2764 3844//2771
+f 3840//2757 3839//2753 3854//2772
+f 3835//2758 3834//2754 3849//2773
+f 3830//2755 3829//2752 3845//2774
+f 3841//2775 3840//2757 3855//2776
+f 3836//2760 3835//2758 3850//2777
+f 3831//2759 3830//2755 3846//2778
+f 3837//2762 3836//2760 3851//2779
+f 3832//2761 3831//2759 3847//2780
+f 3705//2781 3389//2322 3404//2323
+f 3375//2307 3826//2782 3390//2308
+f 3705//2781 3404//2323 3419//2341
+f 3390//2308 3826//2782 3405//2333
+f 3405//2333 3826//2782 3420//2351
+f 3705//2781 3419//2341 3434//2359
+f 3705//2781 3434//2359 3449//2362
+f 3420//2351 3826//2782 3435//2369
+f 3705//2781 3449//2362 3464//2382
+f 3435//2369 3826//2782 3450//2389
+f 3705//2781 3464//2382 3479//2401
+f 3450//2389 3826//2782 3465//2393
+f 3465//2393 3826//2782 3480//2411
+f 3705//2781 3479//2401 3494//2419
+f 3705//2781 3494//2419 3509//2439
+f 3480//2411 3826//2782 3495//2446
+f 3705//2781 3509//2439 3524//2458
+f 3495//2446 3826//2782 3510//2451
+f 3705//2781 3524//2458 3539//2476
+f 3510//2451 3826//2782 3525//2469
+f 3525//2469 3826//2782 3540//2487
+f 3705//2781 3539//2476 3554//2494
+f 3705//2781 3554//2494 3569//2499
+f 3540//2487 3826//2782 3555//2506
+f 3705//2781 3569//2499 3584//2519
+f 3555//2506 3826//2782 3570//2511
+f 3705//2781 3584//2519 3599//2537
+f 3570//2511 3826//2782 3585//2529
+f 3585//2529 3826//2782 3600//2547
+f 3705//2781 3599//2537 3614//2555
+f 3705//2781 3614//2555 3629//2556
+f 3600//2547 3826//2782 3615//2548
+f 3705//2781 3629//2556 3644//2560
+f 3615//2548 3826//2782 3630//2568
+f 3705//2781 3644//2560 3659//2579
+f 3630//2568 3826//2782 3645//2586
+f 3645//2586 3826//2782 3660//2589
+f 3705//2781 3659//2579 3674//2597
+f 3705//2781 3674//2597 3689//2615
+f 3660//2589 3826//2782 3675//2607
+f 3705//2781 3689//2615 3704//2620
+f 3675//2607 3826//2782 3690//2627
+f 3705//2781 3704//2620 3720//2639
+f 3690//2627 3826//2782 3706//2646
+f 3706//2646 3826//2782 3721//2649
+f 3705//2781 3720//2639 3735//2657
+f 3705//2781 3735//2657 3750//2678
+f 3721//2649 3826//2782 3736//2686
+f 3705//2781 3750//2678 3765//2696
+f 3736//2686 3826//2782 3751//2704
+f 3705//2781 3765//2696 3780//2715
+f 3751//2704 3826//2782 3766//2708
+f 3705//2781 3780//2715 3795//2732
+f 3766//2708 3826//2782 3781//2725
+f 3705//2781 3795//2732 3810//2737
+f 3781//2725 3826//2782 3796//2745
+f 3705//2781 3810//2737 3825//2756
+f 3796//2745 3826//2782 3811//2763
+f 3705//2781 3825//2756 3841//2775
+f 3811//2763 3826//2782 3827//2768
+f 3705//2781 3841//2775 3856//2783
+f 3827//2768 3826//2782 3842//2784
+f 3705//2781 3856//2783 3389//2322
+f 3852//2766 3851//2779 3384//2324
+f 3847//2780 3846//2778 3379//2326
+f 3842//2784 3826//2782 3375//2307
+f 3853//2770 3852//2766 3385//2328
+f 3848//2767 3847//2780 3380//2304
+f 3843//2769 3842//2784 3375//2307
+f 3854//2772 3853//2770 3386//2310
+f 3849//2773 3848//2767 3381//2303
+f 3844//2771 3843//2769 3376//2306
+f 3855//2776 3854//2772 3387//2309
+f 3850//2777 3849//2773 3382//2312
+f 3845//2774 3844//2771 3377//2314
+f 3856//2783 3855//2776 3389//2322
+f 3851//2779 3850//2777 3383//2318
+f 3846//2778 3845//2774 3378//2320
+f 3863//2303 3862//2785 3877//2305
+f 3858//2306 3857//2786 3872//2308
+f 3869//2309 3868//2310 3884//2787
+f 3864//2312 3863//2303 3878//2788
+f 3859//2314 3858//2306 3873//2315
+f 3870//2789 3869//2309 3885//2790
+f 3865//2318 3864//2312 3879//2319
+f 3860//2320 3859//2314 3874//2321
+f 3871//2791 3870//2789 3886//2792
+f 3866//2324 3865//2318 3881//2325
+f 3861//2326 3860//2320 3875//2793
+f 3867//2328 3866//2324 3882//2794
+f 3862//2785 3861//2326 3876//2330
+f 3868//2310 3867//2328 3883//2331
+f 3878//2788 3877//2305 3892//2332
+f 3873//2315 3872//2308 3887//2795
+f 3884//2787 3883//2331 3899//2334
+f 3879//2319 3878//2788 3893//2335
+f 3874//2321 3873//2315 3888//2336
+f 3885//2790 3884//2787 3900//2337
+f 3880//2338 3879//2319 3895//2339
+f 3875//2793 3874//2321 3889//2340
+f 3886//2792 3885//2790 3901//2796
+f 3881//2325 3880//2338 3896//2342
+f 3876//2330 3875//2793 3890//2797
+f 3882//2794 3881//2325 3897//2344
+f 3877//2305 3876//2330 3891//2345
+f 3883//2331 3882//2794 3898//2346
+f 3897//2344 3896//2342 3912//2798
+f 3892//2332 3891//2345 3906//2348
+f 3898//2346 3897//2344 3913//2349
+f 3893//2335 3892//2332 3907//2350
+f 3888//2336 3887//2795 3902//2351
+f 3899//2334 3898//2346 3914//2352
+f 3894//2799 3893//2335 3908//2354
+f 3889//2340 3888//2336 3903//2800
+f 3900//2337 3899//2334 3915//2801
+f 3895//2339 3894//2799 3910//2357
+f 3890//2797 3889//2340 3904//2802
+f 3901//2796 3900//2337 3916//2359
+f 3896//2342 3895//2339 3911//2360
+f 3891//2345 3890//2797 3905//2361
+f 3916//2359 3915//2801 3931//2803
+f 3911//2360 3910//2357 3926//2363
+f 3906//2348 3905//2361 3920//2364
+f 3912//2798 3911//2360 3927//2365
+f 3907//2350 3906//2348 3921//2366
+f 3913//2349 3912//2798 3928//2367
+f 3908//2354 3907//2350 3922//2368
+f 3903//2800 3902//2351 3917//2804
+f 3914//2352 3913//2349 3929//2370
+f 3909//2371 3908//2354 3923//2372
+f 3904//2802 3903//2800 3918//2805
+f 3915//2801 3914//2352 3930//2806
+f 3910//2357 3909//2371 3925//2375
+f 3905//2361 3904//2802 3919//2376
+f 3919//2376 3918//2805 3933//2807
+f 3930//2806 3929//2370 3945//2808
+f 3925//2375 3924//2379 3940//2809
+f 3920//2364 3919//2376 3934//2810
+f 3931//2803 3930//2806 3946//2811
+f 3926//2363 3925//2375 3941//2383
+f 3921//2366 3920//2364 3935//2384
+f 3927//2365 3926//2363 3942//2812
+f 3922//2368 3921//2366 3936//2386
+f 3928//2367 3927//2365 3943//2387
+f 3923//2372 3922//2368 3937//2388
+f 3918//2805 3917//2804 3932//2813
+f 3929//2370 3928//2367 3944//2390
+f 3924//2379 3923//2372 3938//2814
+f 3938//2814 3937//2388 3952//2392
+f 3933//2807 3932//2813 3947//2815
+f 3944//2390 3943//2387 3959//2394
+f 3939//2395 3938//2814 3953//2396
+f 3934//2810 3933//2807 3948//2397
+f 3945//2808 3944//2390 3960//2398
+f 3940//2809 3939//2395 3955//2816
+f 3935//2384 3934//2810 3949//2400
+f 3946//2811 3945//2808 3961//2817
+f 3941//2383 3940//2809 3956//2818
+f 3936//2386 3935//2384 3950//2403
+f 3942//2812 3941//2383 3957//2404
+f 3937//2388 3936//2386 3951//2405
+f 3943//2387 3942//2812 3958//2819
+f 3957//2404 3956//2818 3972//2407
+f 3952//2392 3951//2405 3966//2820
+f 3958//2819 3957//2404 3973//2409
+f 3953//2396 3952//2392 3967//2410
+f 3948//2397 3947//2815 3962//2411
+f 3959//2394 3958//2819 3974//2821
+f 3954//2413 3953//2396 3968//2414
+f 3949//2400 3948//2397 3963//2822
+f 3960//2398 3959//2394 3975//2416
+f 3955//2816 3954//2413 3970//2417
+f 3950//2403 3949//2400 3964//2418
+f 3961//2817 3960//2398 3976//2419
+f 3956//2818 3955//2816 3971//2420
+f 3951//2405 3950//2403 3965//2421
+f 3976//2419 3975//2416 3990//2422
+f 3971//2420 3970//2417 3986//2423
+f 3966//2820 3965//2421 3981//2424
+f 3972//2407 3971//2420 3987//2425
+f 3967//2410 3966//2820 3982//2426
+f 3973//2409 3972//2407 3988//2427
+f 3968//2414 3967//2410 3983//2428
+f 3963//2822 3962//2411 3978//2429
+f 3974//2821 3973//2409 3988//2427
+f 3969//2430 3968//2414 3984//2431
+f 3964//2418 3963//2822 3979//2432
+f 3975//2416 3974//2821 3989//2433
+f 3970//2417 3969//2430 3985//2823
+f 3965//2421 3964//2418 3980//2435
+f 3990//2422 3989//2433 4004//2436
+f 3985//2823 3984//2431 4000//2437
+f 3980//2435 3979//2432 3995//2438
+f 3991//2439 3990//2422 4005//2440
+f 3986//2423 3985//2823 4000//2437
+f 3981//2424 3980//2435 3996//2824
+f 3987//2425 3986//2423 4001//2825
+f 3982//2426 3981//2424 3997//2826
+f 3988//2427 3987//2425 4002//2444
+f 3983//2428 3982//2426 3998//2445
+f 3978//2429 3977//2446 3993//2447
+f 3989//2433 3988//2427 4003//2827
+f 3984//2431 3983//2428 3999//2449
+f 3979//2432 3978//2429 3994//2450
+f 3993//2447 3992//2828 4008//2452
+f 4004//2436 4003//2827 4018//2453
+f 3999//2449 3998//2445 4014//2454
+f 3994//2450 3993//2447 4009//2829
+f 4005//2440 4004//2436 4019//2830
+f 4000//2437 3999//2449 4014//2454
+f 3995//2438 3994//2450 4010//2457
+f 4006//2831 4005//2440 4020//2459
+f 4001//2825 4000//2437 4015//2460
+f 3996//2824 3995//2438 4011//2461
+f 4002//2444 4001//2825 4016//2462
+f 3997//2826 3996//2824 4012//2463
+f 4003//2827 4002//2444 4017//2464
+f 3998//2445 3997//2826 4013//2465
+f 4012//2463 4011//2461 4027//2832
+f 4018//2453 4017//2464 4032//2467
+f 4013//2465 4012//2463 4028//2468
+f 4008//2452 4007//2469 4023//2833
+f 4019//2830 4018//2453 4033//2471
+f 4014//2454 4013//2465 4029//2472
+f 4009//2829 4008//2452 4024//2473
+f 4020//2459 4019//2830 4034//2834
+f 4015//2460 4014//2454 4029//2472
+f 4010//2457 4009//2829 4025//2835
+f 4021//2476 4020//2459 4035//2477
+f 4016//2462 4015//2460 4030//2478
+f 4011//2461 4010//2457 4026//2836
+f 4017//2464 4016//2462 4031//2480
+f 4031//2480 4030//2478 4045//2481
+f 4026//2836 4025//2835 4041//2482
+f 4032//2467 4031//2480 4046//2483
+f 4027//2832 4026//2836 4042//2484
+f 4033//2471 4032//2467 4047//2837
+f 4028//2468 4027//2832 4043//2838
+f 4023//2833 4022//2839 4038//2488
+f 4034//2834 4033//2471 4048//2489
+f 4029//2472 4028//2468 4044//2490
+f 4024//2473 4023//2833 4039//2840
+f 4035//2477 4034//2834 4049//2492
+f 4030//2478 4029//2472 4044//2490
+f 4025//2835 4024//2473 4040//2493
+f 4036//2494 4035//2477 4050//2495
+f 4050//2495 4049//2492 4064//2496
+f 4045//2481 4044//2490 4060//2841
+f 4040//2493 4039//2840 4055//2842
+f 4051//2843 4050//2495 4065//2500
+f 4046//2483 4045//2481 4060//2841
+f 4041//2482 4040//2493 4056//2501
+f 4047//2837 4046//2483 4061//2502
+f 4042//2484 4041//2482 4057//2503
+f 4048//2489 4047//2837 4062//2504
+f 4043//2838 4042//2484 4058//2505
+f 4038//2488 4037//2506 4053//2507
+f 4049//2492 4048//2489 4063//2508
+f 4044//2490 4043//2838 4059//2844
+f 4039//2840 4038//2488 4054//2845
+f 4053//2507 4052//2511 4068//2512
+f 4064//2496 4063//2508 4078//2513
+f 4059//2844 4058//2505 4074//2846
+f 4054//2845 4053//2507 4069//2515
+f 4065//2500 4064//2496 4079//2847
+f 4060//2841 4059//2844 4075//2517
+f 4055//2842 4054//2845 4070//2518
+f 4066//2848 4065//2500 4080//2849
+f 4061//2502 4060//2841 4075//2517
+f 4056//2501 4055//2842 4071//2850
+f 4062//2504 4061//2502 4076//2522
+f 4057//2503 4056//2501 4072//2851
+f 4063//2508 4062//2504 4077//2524
+f 4058//2505 4057//2503 4073//2525
+f 4072//2851 4071//2850 4087//2526
+f 4078//2513 4077//2524 4092//2852
+f 4073//2525 4072//2851 4088//2528
+f 4068//2512 4067//2529 4083//2853
+f 4079//2847 4078//2513 4093//2531
+f 4074//2846 4073//2525 4089//2854
+f 4069//2515 4068//2512 4084//2855
+f 4080//2849 4079//2847 4094//2534
+f 4075//2517 4074//2846 4090//2535
+f 4070//2518 4069//2515 4085//2536
+f 4081//2537 4080//2849 4095//2538
+f 4076//2522 4075//2517 4090//2535
+f 4071//2850 4070//2518 4086//2856
+f 4077//2524 4076//2522 4091//2540
+f 4091//2540 4090//2535 4106//2541
+f 4086//2856 4085//2536 4101//2542
+f 4092//2852 4091//2540 4107//2543
+f 4087//2526 4086//2856 4102//2544
+f 4093//2531 4092//2852 4108//2545
+f 4088//2528 4087//2526 4103//2857
+f 4083//2853 4082//2858 4097//2548
+f 4094//2534 4093//2531 4109//2549
+f 4089//2854 4088//2528 4104//2859
+f 4084//2855 4083//2853 4099//2551
+f 4095//2538 4094//2534 4110//2860
+f 4090//2535 4089//2854 4105//2553
+f 4085//2536 4084//2855 4100//2554
+f 4096//2555 4095//2538 4111//2556
+f 4110//2860 4109//2549 4125//2557
+f 4105//2553 4104//2859 4120//2558
+f 4100//2554 4099//2551 4114//2559
+f 4111//2556 4110//2860 4126//2861
+f 4106//2541 4105//2553 4121//2561
+f 4101//2542 4100//2554 4115//2562
+f 4107//2543 4106//2541 4122//2563
+f 4102//2544 4101//2542 4116//2564
+f 4108//2545 4107//2543 4123//2862
+f 4103//2857 4102//2544 4117//2566
+f 4098//2567 4097//2548 4112//2568
+f 4109//2549 4108//2545 4124//2569
+f 4104//2859 4103//2857 4119//2570
+f 4099//2551 4098//2567 4113//2571
+f 4124//2569 4123//2862 4139//2572
+f 4119//2570 4118//2863 4133//2574
+f 4114//2559 4113//2571 4128//2864
+f 4125//2557 4124//2569 4140//2576
+f 4120//2558 4119//2570 4135//2577
+f 4115//2562 4114//2559 4129//2578
+f 4126//2861 4125//2557 4141//2579
+f 4121//2561 4120//2558 4136//2580
+f 4116//2564 4115//2562 4130//2865
+f 4122//2563 4121//2561 4137//2582
+f 4117//2566 4116//2564 4131//2583
+f 4123//2862 4122//2563 4138//2866
+f 4118//2863 4117//2566 4132//2867
+f 4113//2571 4112//2568 4127//2586
+f 4138//2866 4137//2582 4153//2587
+f 4133//2574 4132//2867 4147//2588
+f 4128//2864 4127//2586 4142//2589
+f 4139//2572 4138//2866 4154//2868
+f 4134//2591 4133//2574 4148//2869
+f 4129//2578 4128//2864 4143//2593
+f 4140//2576 4139//2572 4155//2870
+f 4135//2577 4134//2591 4150//2595
+f 4130//2865 4129//2578 4144//2596
+f 4141//2579 4140//2576 4156//2597
+f 4136//2580 4135//2577 4151//2598
+f 4131//2583 4130//2865 4145//2599
+f 4137//2582 4136//2580 4152//2600
+f 4132//2867 4131//2583 4146//2601
+f 4146//2601 4145//2599 4160//2602
+f 4152//2600 4151//2598 4167//2871
+f 4147//2588 4146//2601 4161//2604
+f 4153//2587 4152//2600 4168//2605
+f 4148//2869 4147//2588 4162//2606
+f 4143//2593 4142//2589 4157//2872
+f 4154//2868 4153//2587 4169//2608
+f 4149//2609 4148//2869 4163//2610
+f 4144//2596 4143//2593 4158//2611
+f 4155//2870 4154//2868 4170//2873
+f 4150//2595 4149//2609 4165//2613
+f 4145//2599 4144//2596 4159//2874
+f 4156//2597 4155//2870 4171//2615
+f 4151//2598 4150//2595 4166//2616
+f 4165//2613 4164//2875 4180//2618
+f 4160//2602 4159//2874 4174//2619
+f 4171//2615 4170//2873 4186//2620
+f 4166//2616 4165//2613 4181//2621
+f 4161//2604 4160//2602 4175//2622
+f 4167//2871 4166//2616 4182//2623
+f 4162//2606 4161//2604 4176//2876
+f 4168//2605 4167//2871 4183//2625
+f 4163//2610 4162//2606 4177//2626
+f 4158//2611 4157//2872 4172//2877
+f 4169//2608 4168//2605 4184//2628
+f 4164//2875 4163//2610 4178//2629
+f 4159//2874 4158//2611 4173//2878
+f 4170//2873 4169//2608 4185//2631
+f 4184//2628 4183//2625 4200//2632
+f 4179//2633 4178//2629 4194//2634
+f 4174//2619 4173//2878 4189//2635
+f 4185//2631 4184//2628 4201//2636
+f 4180//2618 4179//2633 4196//2637
+f 4175//2622 4174//2619 4190//2638
+f 4186//2620 4185//2631 4202//2879
+f 4181//2621 4180//2618 4197//2640
+f 4176//2876 4175//2622 4191//2880
+f 4182//2623 4181//2621 4198//2642
+f 4177//2626 4176//2876 4192//2643
+f 4183//2625 4182//2623 4199//2644
+f 4178//2629 4177//2626 4193//2881
+f 4173//2878 4172//2877 4188//2882
+f 4199//2644 4198//2642 4214//2647
+f 4194//2634 4193//2881 4208//2648
+f 4189//2635 4188//2882 4203//2649
+f 4200//2632 4199//2644 4215//2650
+f 4195//2883 4194//2634 4209//2884
+f 4190//2638 4189//2635 4204//2653
+f 4201//2636 4200//2632 4216//2654
+f 4196//2637 4195//2883 4211//2655
+f 4191//2880 4190//2638 4205//2656
+f 4202//2879 4201//2636 4217//2657
+f 4197//2640 4196//2637 4212//2885
+f 4192//2643 4191//2880 4206//2659
+f 4198//2642 4197//2640 4213//2886
+f 4193//2881 4192//2643 4207//2661
+f 4207//2661 4206//2659 4221//2662
+f 4213//2886 4212//2885 4227//2663
+f 4208//2648 4207//2661 4222//2664
+f 4214//2647 4213//2886 4228//2665
+f 4209//2884 4208//2648 4223//2666
+f 4204//2653 4203//2649 4219//2667
+f 4215//2650 4214//2647 4229//2668
+f 4210//2669 4209//2884 4224//2887
+f 4205//2656 4204//2653 4220//2671
+f 4216//2654 4215//2650 4230//2672
+f 4211//2655 4210//2669 4225//2673
+f 4206//2659 4205//2656 4221//2662
+f 4217//2657 4216//2654 4231//2674
+f 4212//2885 4211//2655 4226//2675
+f 4226//2675 4225//2673 4240//2676
+f 4221//2662 4220//2671 4236//2677
+f 4232//2678 4231//2674 4246//2679
+f 4227//2663 4226//2675 4241//2680
+f 4222//2664 4221//2662 4237//2681
+f 4228//2665 4227//2663 4242//2888
+f 4223//2666 4222//2664 4238//2683
+f 4229//2668 4228//2665 4243//2684
+f 4224//2887 4223//2666 4239//2685
+f 4219//2667 4218//2686 4234//2687
+f 4230//2672 4229//2668 4244//2688
+f 4225//2673 4224//2887 4239//2685
+f 4220//2671 4219//2667 4235//2689
+f 4231//2674 4230//2672 4245//2690
+f 4245//2690 4244//2688 4259//2691
+f 4240//2676 4239//2685 4255//2692
+f 4235//2689 4234//2687 4250//2889
+f 4246//2679 4245//2690 4260//2890
+f 4241//2680 4240//2676 4255//2692
+f 4236//2677 4235//2689 4251//2695
+f 4247//2891 4246//2679 4261//2697
+f 4242//2888 4241//2680 4256//2698
+f 4237//2681 4236//2677 4252//2699
+f 4243//2684 4242//2888 4257//2700
+f 4238//2683 4237//2681 4253//2701
+f 4244//2688 4243//2684 4258//2702
+f 4239//2685 4238//2683 4254//2703
+f 4234//2687 4233//2892 4249//2893
+f 4259//2691 4258//2702 4273//2894
+f 4254//2703 4253//2701 4269//2707
+f 4249//2893 4248//2708 4264//2709
+f 4260//2890 4259//2691 4274//2895
+f 4255//2692 4254//2703 4270//2711
+f 4250//2889 4249//2893 4265//2896
+f 4261//2697 4260//2890 4275//2713
+f 4256//2698 4255//2692 4270//2711
+f 4251//2695 4250//2889 4266//2714
+f 4262//2715 4261//2697 4276//2716
+f 4257//2700 4256//2698 4271//2717
+f 4252//2699 4251//2695 4267//2718
+f 4258//2702 4257//2700 4272//2719
+f 4253//2701 4252//2699 4268//2720
+f 4273//2894 4272//2719 4287//2897
+f 4268//2720 4267//2718 4283//2722
+f 4274//2895 4273//2894 4288//2723
+f 4269//2707 4268//2720 4284//2724
+f 4264//2709 4263//2725 4279//2726
+f 4275//2713 4274//2895 4289//2727
+f 4270//2711 4269//2707 4285//2728
+f 4265//2896 4264//2709 4280//2729
+f 4276//2716 4275//2713 4290//2730
+f 4271//2717 4270//2711 4285//2728
+f 4266//2714 4265//2896 4281//2731
+f 4277//2732 4276//2716 4291//2733
+f 4272//2719 4271//2717 4286//2734
+f 4267//2718 4266//2714 4282//2735
+f 4281//2731 4280//2729 4296//2736
+f 4292//2898 4291//2733 4306//2899
+f 4287//2897 4286//2734 4301//2739
+f 4282//2735 4281//2731 4297//2740
+f 4288//2723 4287//2897 4302//2741
+f 4283//2722 4282//2735 4298//2742
+f 4289//2727 4288//2723 4303//2743
+f 4284//2724 4283//2722 4299//2900
+f 4279//2726 4278//2745 4294//2746
+f 4290//2730 4289//2727 4304//2747
+f 4285//2728 4284//2724 4299//2900
+f 4280//2729 4279//2726 4295//2748
+f 4291//2733 4290//2730 4305//2901
+f 4286//2734 4285//2728 4300//2750
+f 4300//2750 4299//2900 4315//2751
+f 4295//2748 4294//2746 4311//2752
+f 4306//2899 4305//2901 4321//2753
+f 4301//2739 4300//2750 4316//2754
+f 4296//2736 4295//2748 4312//2755
+f 4307//2756 4306//2899 4322//2757
+f 4302//2741 4301//2739 4317//2758
+f 4297//2740 4296//2736 4313//2759
+f 4303//2743 4302//2741 4318//2760
+f 4298//2742 4297//2740 4314//2761
+f 4304//2747 4303//2743 4319//2762
+f 4299//2900 4298//2742 4315//2751
+f 4294//2746 4293//2902 4310//2764
+f 4305//2901 4304//2747 4320//2765
+f 4320//2765 4319//2762 4334//2766
+f 4315//2751 4314//2761 4330//2903
+f 4310//2764 4309//2904 4325//2769
+f 4321//2753 4320//2765 4335//2770
+f 4316//2754 4315//2751 4330//2903
+f 4311//2752 4310//2764 4326//2771
+f 4322//2757 4321//2753 4336//2772
+f 4317//2758 4316//2754 4331//2773
+f 4312//2755 4311//2752 4327//2774
+f 4323//2905 4322//2757 4337//2906
+f 4318//2760 4317//2758 4332//2777
+f 4313//2759 4312//2755 4328//2778
+f 4319//2762 4318//2760 4333//2779
+f 4314//2761 4313//2759 4329//2780
+f 4187//2781 3871//2791 3886//2792
+f 3857//2786 4308//2782 3872//2308
+f 4187//2781 3886//2792 3901//2796
+f 3872//2308 4308//2782 3887//2795
+f 3887//2795 4308//2782 3902//2351
+f 4187//2781 3901//2796 3916//2359
+f 4187//2781 3916//2359 3931//2803
+f 3902//2351 4308//2782 3917//2804
+f 4187//2781 3931//2803 3946//2811
+f 3917//2804 4308//2782 3932//2813
+f 4187//2781 3946//2811 3961//2817
+f 3932//2813 4308//2782 3947//2815
+f 3947//2815 4308//2782 3962//2411
+f 4187//2781 3961//2817 3976//2419
+f 4187//2781 3976//2419 3991//2439
+f 3962//2411 4308//2782 3977//2446
+f 4187//2781 3991//2439 4006//2831
+f 3977//2446 4308//2782 3992//2828
+f 4187//2781 4006//2831 4021//2476
+f 3992//2828 4308//2782 4007//2469
+f 4007//2469 4308//2782 4022//2839
+f 4187//2781 4021//2476 4036//2494
+f 4187//2781 4036//2494 4051//2843
+f 4022//2839 4308//2782 4037//2506
+f 4187//2781 4051//2843 4066//2848
+f 4037//2506 4308//2782 4052//2511
+f 4187//2781 4066//2848 4081//2537
+f 4052//2511 4308//2782 4067//2529
+f 4067//2529 4308//2782 4082//2858
+f 4187//2781 4081//2537 4096//2555
+f 4187//2781 4096//2555 4111//2556
+f 4082//2858 4308//2782 4097//2548
+f 4187//2781 4111//2556 4126//2861
+f 4097//2548 4308//2782 4112//2568
+f 4187//2781 4126//2861 4141//2579
+f 4112//2568 4308//2782 4127//2586
+f 4127//2586 4308//2782 4142//2589
+f 4187//2781 4141//2579 4156//2597
+f 4187//2781 4156//2597 4171//2615
+f 4142//2589 4308//2782 4157//2872
+f 4187//2781 4171//2615 4186//2620
+f 4157//2872 4308//2782 4172//2877
+f 4187//2781 4186//2620 4202//2879
+f 4172//2877 4308//2782 4188//2882
+f 4188//2882 4308//2782 4203//2649
+f 4187//2781 4202//2879 4217//2657
+f 4187//2781 4217//2657 4232//2678
+f 4203//2649 4308//2782 4218//2686
+f 4187//2781 4232//2678 4247//2891
+f 4218//2686 4308//2782 4233//2892
+f 4187//2781 4247//2891 4262//2715
+f 4233//2892 4308//2782 4248//2708
+f 4187//2781 4262//2715 4277//2732
+f 4248//2708 4308//2782 4263//2725
+f 4187//2781 4277//2732 4292//2898
+f 4263//2725 4308//2782 4278//2745
+f 4187//2781 4292//2898 4307//2756
+f 4278//2745 4308//2782 4293//2902
+f 4187//2781 4307//2756 4323//2905
+f 4293//2902 4308//2782 4309//2904
+f 4187//2781 4323//2905 4338//2907
+f 4309//2904 4308//2782 4324//2908
+f 4187//2781 4338//2907 3871//2791
+f 4334//2766 4333//2779 3866//2324
+f 4329//2780 4328//2778 3861//2326
+f 4324//2908 4308//2782 3857//2786
+f 4335//2770 4334//2766 3867//2328
+f 4330//2903 4329//2780 3862//2785
+f 4325//2769 4324//2908 3857//2786
+f 4336//2772 4335//2770 3868//2310
+f 4331//2773 4330//2903 3863//2303
+f 4326//2771 4325//2769 3858//2306
+f 4337//2906 4336//2772 3869//2309
+f 4332//2777 4331//2773 3864//2312
+f 4327//2774 4326//2771 3859//2314
+f 4338//2907 4337//2906 3871//2791
+f 4333//2779 4332//2777 3865//2318
+f 4328//2778 4327//2774 3860//2320
+f 3396//2313 3381//2303 3395//2305
+f 3391//2315 3376//2306 3390//2308
+f 3386//2310 3401//2331 3402//2311
+f 3397//2319 3382//2312 3396//2313
+f 3392//2321 3377//2314 3391//2315
+f 3387//2309 3402//2311 3403//2317
+f 3398//2338 3383//2318 3397//2319
+f 3393//2327 3378//2320 3392//2321
+f 3388//2316 3403//2317 3404//2323
+f 3383//2318 3398//2338 3399//2325
+f 3394//2330 3379//2326 3393//2327
+f 3384//2324 3399//2325 3400//2329
+f 3395//2305 3380//2304 3394//2330
+f 3385//2328 3400//2329 3401//2331
+f 3411//2335 3396//2313 3410//2332
+f 3406//2336 3391//2315 3405//2333
+f 3401//2331 3416//2346 3417//2334
+f 3412//2353 3397//2319 3411//2335
+f 3407//2340 3392//2321 3406//2336
+f 3402//2311 3417//2334 3418//2337
+f 3397//2319 3412//2353 3413//2339
+f 3408//2343 3393//2327 3407//2340
+f 3403//2317 3418//2337 3419//2341
+f 3398//2338 3413//2339 3414//2342
+f 3409//2345 3394//2330 3408//2343
+f 3399//2325 3414//2342 3415//2344
+f 3410//2332 3395//2305 3409//2345
+f 3400//2329 3415//2344 3416//2346
+f 3414//2342 3429//2360 3430//2347
+f 3425//2350 3410//2332 3424//2348
+f 3415//2344 3430//2347 3431//2349
+f 3426//2354 3411//2335 3425//2350
+f 3421//2355 3406//2336 3420//2351
+f 3416//2346 3431//2349 3432//2352
+f 3427//2371 3412//2353 3426//2354
+f 3422//2358 3407//2340 3421//2355
+f 3417//2334 3432//2352 3433//2356
+f 3412//2353 3427//2371 3428//2357
+f 3423//2361 3408//2343 3422//2358
+f 3418//2337 3433//2356 3434//2359
+f 3413//2339 3428//2357 3429//2360
+f 3424//2348 3409//2345 3423//2361
+f 3433//2356 3448//2374 3449//2362
+f 3428//2357 3443//2375 3444//2363
+f 3439//2366 3424//2348 3438//2364
+f 3429//2360 3444//2363 3445//2365
+f 3440//2368 3425//2350 3439//2366
+f 3430//2347 3445//2365 3446//2367
+f 3441//2372 3426//2354 3440//2368
+f 3436//2373 3421//2355 3435//2369
+f 3431//2349 3446//2367 3447//2370
+f 3442//2379 3427//2371 3441//2372
+f 3437//2376 3422//2358 3436//2373
+f 3432//2352 3447//2370 3448//2374
+f 3427//2371 3442//2379 3443//2375
+f 3438//2364 3423//2361 3437//2376
+f 3452//2381 3437//2376 3451//2377
+f 3447//2370 3462//2390 3463//2378
+f 3442//2379 3457//2395 3458//2380
+f 3453//2384 3438//2364 3452//2381
+f 3448//2374 3463//2378 3464//2382
+f 3443//2375 3458//2380 3459//2383
+f 3454//2386 3439//2366 3453//2384
+f 3444//2363 3459//2383 3460//2385
+f 3455//2388 3440//2368 3454//2386
+f 3445//2365 3460//2385 3461//2387
+f 3456//2391 3441//2372 3455//2388
+f 3451//2377 3436//2373 3450//2389
+f 3446//2367 3461//2387 3462//2390
+f 3457//2395 3442//2379 3456//2391
+f 3471//2396 3456//2391 3470//2392
+f 3466//2397 3451//2377 3465//2393
+f 3461//2387 3476//2406 3477//2394
+f 3472//2413 3457//2395 3471//2396
+f 3467//2400 3452//2381 3466//2397
+f 3462//2390 3477//2394 3478//2398
+f 3457//2395 3472//2413 3473//2399
+f 3468//2403 3453//2384 3467//2400
+f 3463//2378 3478//2398 3479//2401
+f 3458//2380 3473//2399 3474//2402
+f 3469//2405 3454//2386 3468//2403
+f 3459//2383 3474//2402 3475//2404
+f 3470//2392 3455//2388 3469//2405
+f 3460//2385 3475//2404 3476//2406
+f 3474//2402 3489//2420 3490//2407
+f 3485//2410 3470//2392 3484//2408
+f 3475//2404 3490//2407 3491//2409
+f 3486//2414 3471//2396 3485//2410
+f 3481//2415 3466//2397 3480//2411
+f 3476//2406 3491//2409 3492//2412
+f 3487//2430 3472//2413 3486//2414
+f 3482//2418 3467//2400 3481//2415
+f 3477//2394 3492//2412 3493//2416
+f 3472//2413 3487//2430 3488//2417
+f 3483//2421 3468//2403 3482//2418
+f 3478//2398 3493//2416 3494//2419
+f 3473//2399 3488//2417 3489//2420
+f 3484//2408 3469//2405 3483//2421
+f 3509//2439 3494//2419 3508//2422
+f 3488//2417 3503//2434 3504//2423
+f 3483//2421 3498//2435 3499//2424
+f 3489//2420 3504//2423 3505//2425
+f 3484//2408 3499//2424 3500//2426
+f 3490//2407 3505//2425 3506//2427
+f 3485//2410 3500//2426 3501//2428
+f 3480//2411 3495//2446 3496//2429
+f 3507//2433 3492//2412 3506//2427
+f 3486//2414 3501//2428 3502//2431
+f 3481//2415 3496//2429 3497//2432
+f 3508//2422 3493//2416 3507//2433
+f 3487//2430 3502//2431 3503//2434
+f 3482//2418 3497//2432 3498//2435
+f 3523//2440 3508//2422 3522//2436
+f 3502//2431 3517//2449 3518//2437
+f 3497//2432 3512//2450 3513//2438
+f 3524//2458 3509//2439 3523//2440
+f 3519//2442 3504//2423 3518//2437
+f 3498//2435 3513//2438 3514//2441
+f 3520//2444 3505//2425 3519//2442
+f 3499//2424 3514//2441 3515//2443
+f 3521//2448 3506//2427 3520//2444
+f 3500//2426 3515//2443 3516//2445
+f 3495//2446 3510//2451 3511//2447
+f 3522//2436 3507//2433 3521//2448
+f 3501//2428 3516//2445 3517//2449
+f 3496//2429 3511//2447 3512//2450
+f 3510//2451 3525//2469 3526//2452
+f 3537//2456 3522//2436 3536//2453
+f 3516//2445 3531//2465 3532//2454
+f 3511//2447 3526//2452 3527//2455
+f 3538//2459 3523//2440 3537//2456
+f 3533//2460 3518//2437 3532//2454
+f 3512//2450 3527//2455 3528//2457
+f 3539//2476 3524//2458 3538//2459
+f 3534//2462 3519//2442 3533//2460
+f 3513//2438 3528//2457 3529//2461
+f 3535//2464 3520//2444 3534//2462
+f 3514//2441 3529//2461 3530//2463
+f 3536//2453 3521//2448 3535//2464
+f 3515//2443 3530//2463 3531//2465
+f 3529//2461 3544//2479 3545//2466
+f 3551//2471 3536//2453 3550//2467
+f 3530//2463 3545//2466 3546//2468
+f 3525//2469 3540//2487 3541//2470
+f 3552//2474 3537//2456 3551//2471
+f 3531//2465 3546//2468 3547//2472
+f 3526//2452 3541//2470 3542//2473
+f 3553//2477 3538//2459 3552//2474
+f 3548//2478 3533//2460 3547//2472
+f 3527//2455 3542//2473 3543//2475
+f 3554//2494 3539//2476 3553//2477
+f 3549//2480 3534//2462 3548//2478
+f 3528//2457 3543//2475 3544//2479
+f 3550//2467 3535//2464 3549//2480
+f 3564//2483 3549//2480 3563//2481
+f 3543//2475 3558//2493 3559//2482
+f 3565//2485 3550//2467 3564//2483
+f 3544//2479 3559//2482 3560//2484
+f 3566//2489 3551//2471 3565//2485
+f 3545//2466 3560//2484 3561//2486
+f 3540//2487 3555//2506 3556//2488
+f 3567//2492 3552//2474 3566//2489
+f 3546//2468 3561//2486 3562//2490
+f 3541//2470 3556//2488 3557//2491
+f 3568//2495 3553//2477 3567//2492
+f 3563//2481 3548//2478 3562//2490
+f 3542//2473 3557//2491 3558//2493
+f 3569//2499 3554//2494 3568//2495
+f 3583//2500 3568//2495 3582//2496
+f 3562//2490 3577//2509 3578//2497
+f 3557//2491 3572//2510 3573//2498
+f 3584//2519 3569//2499 3583//2500
+f 3579//2502 3564//2483 3578//2497
+f 3558//2493 3573//2498 3574//2501
+f 3580//2504 3565//2485 3579//2502
+f 3559//2482 3574//2501 3575//2503
+f 3581//2508 3566//2489 3580//2504
+f 3560//2484 3575//2503 3576//2505
+f 3555//2506 3570//2511 3571//2507
+f 3582//2496 3567//2492 3581//2508
+f 3561//2486 3576//2505 3577//2509
+f 3556//2488 3571//2507 3572//2510
+f 3570//2511 3585//2529 3586//2512
+f 3597//2516 3582//2496 3596//2513
+f 3576//2505 3591//2525 3592//2514
+f 3571//2507 3586//2512 3587//2515
+f 3598//2520 3583//2500 3597//2516
+f 3577//2509 3592//2514 3593//2517
+f 3572//2510 3587//2515 3588//2518
+f 3599//2537 3584//2519 3598//2520
+f 3594//2522 3579//2502 3593//2517
+f 3573//2498 3588//2518 3589//2521
+f 3595//2524 3580//2504 3594//2522
+f 3574//2501 3589//2521 3590//2523
+f 3596//2513 3581//2508 3595//2524
+f 3575//2503 3590//2523 3591//2525
+f 3589//2521 3604//2539 3605//2526
+f 3611//2531 3596//2513 3610//2527
+f 3590//2523 3605//2526 3606//2528
+f 3585//2529 3600//2547 3601//2530
+f 3612//2534 3597//2516 3611//2531
+f 3591//2525 3606//2528 3607//2532
+f 3586//2512 3601//2530 3602//2533
+f 3613//2538 3598//2520 3612//2534
+f 3592//2514 3607//2532 3608//2535
+f 3587//2515 3602//2533 3603//2536
+f 3614//2555 3599//2537 3613//2538
+f 3609//2540 3594//2522 3608//2535
+f 3588//2518 3603//2536 3604//2539
+f 3610//2527 3595//2524 3609//2540
+f 3608//2535 3623//2553 3624//2541
+f 3603//2536 3618//2554 3619//2542
+f 3609//2540 3624//2541 3625//2543
+f 3604//2539 3619//2542 3620//2544
+f 3610//2527 3625//2543 3626//2545
+f 3605//2526 3620//2544 3621//2546
+f 3616//2567 3601//2530 3615//2548
+f 3611//2531 3626//2545 3627//2549
+f 3606//2528 3621//2546 3622//2550
+f 3601//2530 3616//2567 3617//2551
+f 3612//2534 3627//2549 3628//2552
+f 3607//2532 3622//2550 3623//2553
+f 3602//2533 3617//2551 3618//2554
+f 3613//2538 3628//2552 3629//2556
+f 3627//2549 3642//2569 3643//2557
+f 3622//2550 3637//2570 3638//2558
+f 3633//2562 3618//2554 3632//2559
+f 3628//2552 3643//2557 3644//2560
+f 3623//2553 3638//2558 3639//2561
+f 3634//2564 3619//2542 3633//2562
+f 3624//2541 3639//2561 3640//2563
+f 3635//2566 3620//2544 3634//2564
+f 3625//2543 3640//2563 3641//2565
+f 3636//2573 3621//2546 3635//2566
+f 3631//2571 3616//2567 3630//2568
+f 3626//2545 3641//2565 3642//2569
+f 3621//2546 3636//2573 3637//2570
+f 3632//2559 3617//2551 3631//2571
+f 3641//2565 3656//2584 3657//2572
+f 3652//2591 3637//2570 3651//2574
+f 3647//2578 3632//2559 3646//2575
+f 3642//2569 3657//2572 3658//2576
+f 3637//2570 3652//2591 3653//2577
+f 3648//2581 3633//2562 3647//2578
+f 3643//2557 3658//2576 3659//2579
+f 3638//2558 3653//2577 3654//2580
+f 3649//2583 3634//2564 3648//2581
+f 3639//2561 3654//2580 3655//2582
+f 3650//2585 3635//2566 3649//2583
+f 3640//2563 3655//2582 3656//2584
+f 3651//2574 3636//2573 3650//2585
+f 3646//2575 3631//2571 3645//2586
+f 3655//2582 3670//2600 3671//2587
+f 3666//2592 3651//2574 3665//2588
+f 3661//2593 3646//2575 3660//2589
+f 3656//2584 3671//2587 3672//2590
+f 3667//2609 3652//2591 3666//2592
+f 3662//2596 3647//2578 3661//2593
+f 3657//2572 3672//2590 3673//2594
+f 3652//2591 3667//2609 3668//2595
+f 3663//2599 3648//2581 3662//2596
+f 3658//2576 3673//2594 3674//2597
+f 3653//2577 3668//2595 3669//2598
+f 3664//2601 3649//2583 3663//2599
+f 3654//2580 3669//2598 3670//2600
+f 3665//2588 3650//2585 3664//2601
+f 3679//2604 3664//2601 3678//2602
+f 3669//2598 3684//2616 3685//2603
+f 3680//2606 3665//2588 3679//2604
+f 3670//2600 3685//2603 3686//2605
+f 3681//2610 3666//2592 3680//2606
+f 3676//2611 3661//2593 3675//2607
+f 3671//2587 3686//2605 3687//2608
+f 3682//2617 3667//2609 3681//2610
+f 3677//2614 3662//2596 3676//2611
+f 3672//2590 3687//2608 3688//2612
+f 3667//2609 3682//2617 3683//2613
+f 3678//2602 3663//2599 3677//2614
+f 3673//2594 3688//2612 3689//2615
+f 3668//2595 3683//2613 3684//2616
+f 3682//2617 3697//2633 3698//2618
+f 3693//2622 3678//2602 3692//2619
+f 3688//2612 3703//2631 3704//2620
+f 3683//2613 3698//2618 3699//2621
+f 3694//2624 3679//2604 3693//2622
+f 3684//2616 3699//2621 3700//2623
+f 3695//2626 3680//2606 3694//2624
+f 3685//2603 3700//2623 3701//2625
+f 3696//2629 3681//2610 3695//2626
+f 3691//2630 3676//2611 3690//2627
+f 3686//2605 3701//2625 3702//2628
+f 3697//2633 3682//2617 3696//2629
+f 3692//2619 3677//2614 3691//2630
+f 3687//2608 3702//2628 3703//2631
+f 3701//2625 3717//2644 3718//2632
+f 3713//2651 3697//2633 3712//2634
+f 3708//2638 3692//2619 3707//2635
+f 3702//2628 3718//2632 3719//2636
+f 3697//2633 3713//2651 3714//2637
+f 3709//2641 3693//2622 3708//2638
+f 3703//2631 3719//2636 3720//2639
+f 3698//2618 3714//2637 3715//2640
+f 3710//2643 3694//2624 3709//2641
+f 3699//2621 3715//2640 3716//2642
+f 3711//2645 3695//2626 3710//2643
+f 3700//2623 3716//2642 3717//2644
+f 3712//2634 3696//2629 3711//2645
+f 3707//2635 3691//2630 3706//2646
+f 3716//2642 3731//2660 3732//2647
+f 3727//2652 3712//2634 3726//2648
+f 3722//2653 3707//2635 3721//2649
+f 3717//2644 3732//2647 3733//2650
+f 3728//2669 3713//2651 3727//2652
+f 3723//2656 3708//2638 3722//2653
+f 3718//2632 3733//2650 3734//2654
+f 3713//2651 3728//2669 3729//2655
+f 3724//2659 3709//2641 3723//2656
+f 3719//2636 3734//2654 3735//2657
+f 3714//2637 3729//2655 3730//2658
+f 3725//2661 3710//2643 3724//2659
+f 3715//2640 3730//2658 3731//2660
+f 3726//2648 3711//2645 3725//2661
+f 3740//2664 3725//2661 3739//2662
+f 3746//2665 3731//2660 3745//2663
+f 3741//2666 3726//2648 3740//2664
+f 3747//2668 3732//2647 3746//2665
+f 3742//2670 3727//2652 3741//2666
+f 3721//2649 3736//2686 3737//2667
+f 3748//2672 3733//2650 3747//2668
+f 3743//2673 3728//2669 3742//2670
+f 3722//2653 3737//2667 3738//2671
+f 3749//2674 3734//2654 3748//2672
+f 3744//2675 3729//2655 3743//2673
+f 3723//2656 3738//2671 3739//2662
+f 3750//2678 3735//2657 3749//2674
+f 3745//2663 3730//2658 3744//2675
+f 3759//2680 3744//2675 3758//2676
+f 3738//2671 3753//2689 3754//2677
+f 3765//2696 3750//2678 3764//2679
+f 3760//2682 3745//2663 3759//2680
+f 3739//2662 3754//2677 3755//2681
+f 3761//2684 3746//2665 3760//2682
+f 3740//2664 3755//2681 3756//2683
+f 3762//2688 3747//2668 3761//2684
+f 3741//2666 3756//2683 3757//2685
+f 3736//2686 3751//2704 3752//2687
+f 3763//2690 3748//2672 3762//2688
+f 3758//2676 3743//2673 3757//2685
+f 3737//2667 3752//2687 3753//2689
+f 3764//2679 3749//2674 3763//2690
+f 3778//2694 3763//2690 3777//2691
+f 3757//2685 3772//2703 3773//2692
+f 3752//2687 3767//2705 3768//2693
+f 3779//2697 3764//2679 3778//2694
+f 3774//2698 3759//2680 3773//2692
+f 3753//2689 3768//2693 3769//2695
+f 3780//2715 3765//2696 3779//2697
+f 3775//2700 3760//2682 3774//2698
+f 3754//2677 3769//2695 3770//2699
+f 3776//2702 3761//2684 3775//2700
+f 3755//2681 3770//2699 3771//2701
+f 3777//2691 3762//2688 3776//2702
+f 3756//2683 3771//2701 3772//2703
+f 3751//2704 3766//2708 3767//2705
+f 3792//2710 3777//2691 3791//2706
+f 3771//2701 3786//2720 3787//2707
+f 3766//2708 3781//2725 3782//2709
+f 3793//2713 3778//2694 3792//2710
+f 3772//2703 3787//2707 3788//2711
+f 3767//2705 3782//2709 3783//2712
+f 3794//2716 3779//2697 3793//2713
+f 3789//2717 3774//2698 3788//2711
+f 3768//2693 3783//2712 3784//2714
+f 3795//2732 3780//2715 3794//2716
+f 3790//2719 3775//2700 3789//2717
+f 3769//2695 3784//2714 3785//2718
+f 3791//2706 3776//2702 3790//2719
+f 3770//2699 3785//2718 3786//2720
+f 3806//2723 3791//2706 3805//2721
+f 3785//2718 3800//2735 3801//2722
+f 3807//2727 3792//2710 3806//2723
+f 3786//2720 3801//2722 3802//2724
+f 3781//2725 3796//2745 3797//2726
+f 3808//2730 3793//2713 3807//2727
+f 3787//2707 3802//2724 3803//2728
+f 3782//2709 3797//2726 3798//2729
+f 3809//2733 3794//2716 3808//2730
+f 3804//2734 3789//2717 3803//2728
+f 3783//2712 3798//2729 3799//2731
+f 3810//2737 3795//2732 3809//2733
+f 3805//2721 3790//2719 3804//2734
+f 3784//2714 3799//2731 3800//2735
+f 3798//2729 3813//2748 3814//2736
+f 3825//2756 3810//2737 3824//2738
+f 3820//2741 3805//2721 3819//2739
+f 3799//2731 3814//2736 3815//2740
+f 3821//2743 3806//2723 3820//2741
+f 3800//2735 3815//2740 3816//2742
+f 3822//2747 3807//2727 3821//2743
+f 3801//2722 3816//2742 3817//2744
+f 3796//2745 3811//2763 3812//2746
+f 3823//2749 3808//2730 3822//2747
+f 3818//2750 3803//2728 3817//2744
+f 3797//2726 3812//2746 3813//2748
+f 3824//2738 3809//2733 3823//2749
+f 3819//2739 3804//2734 3818//2750
+f 3834//2754 3818//2750 3833//2751
+f 3812//2746 3828//2764 3829//2752
+f 3840//2757 3824//2738 3839//2753
+f 3835//2758 3819//2739 3834//2754
+f 3813//2748 3829//2752 3830//2755
+f 3841//2775 3825//2756 3840//2757
+f 3836//2760 3820//2741 3835//2758
+f 3814//2736 3830//2755 3831//2759
+f 3837//2762 3821//2743 3836//2760
+f 3815//2740 3831//2759 3832//2761
+f 3838//2765 3822//2747 3837//2762
+f 3816//2742 3832//2761 3833//2751
+f 3811//2763 3827//2768 3828//2764
+f 3839//2753 3823//2749 3838//2765
+f 3853//2770 3838//2765 3852//2766
+f 3832//2761 3847//2780 3848//2767
+f 3827//2768 3842//2784 3843//2769
+f 3854//2772 3839//2753 3853//2770
+f 3849//2773 3834//2754 3848//2767
+f 3828//2764 3843//2769 3844//2771
+f 3855//2776 3840//2757 3854//2772
+f 3850//2777 3835//2758 3849//2773
+f 3829//2752 3844//2771 3845//2774
+f 3856//2783 3841//2775 3855//2776
+f 3851//2779 3836//2760 3850//2777
+f 3830//2755 3845//2774 3846//2778
+f 3852//2766 3837//2762 3851//2779
+f 3831//2759 3846//2778 3847//2780
+f 3385//2328 3852//2766 3384//2324
+f 3380//2304 3847//2780 3379//2326
+f 3386//2310 3853//2770 3385//2328
+f 3381//2303 3848//2767 3380//2304
+f 3376//2306 3843//2769 3375//2307
+f 3387//2309 3854//2772 3386//2310
+f 3382//2312 3849//2773 3381//2303
+f 3377//2314 3844//2771 3376//2306
+f 3388//2316 3855//2776 3387//2309
+f 3383//2318 3850//2777 3382//2312
+f 3378//2320 3845//2774 3377//2314
+f 3855//2776 3388//2316 3389//2322
+f 3384//2324 3851//2779 3383//2318
+f 3379//2326 3846//2778 3378//2320
+f 3878//2788 3863//2303 3877//2305
+f 3873//2315 3858//2306 3872//2308
+f 3868//2310 3883//2331 3884//2787
+f 3879//2319 3864//2312 3878//2788
+f 3874//2321 3859//2314 3873//2315
+f 3869//2309 3884//2787 3885//2790
+f 3880//2338 3865//2318 3879//2319
+f 3875//2793 3860//2320 3874//2321
+f 3870//2789 3885//2790 3886//2792
+f 3865//2318 3880//2338 3881//2325
+f 3876//2330 3861//2326 3875//2793
+f 3866//2324 3881//2325 3882//2794
+f 3877//2305 3862//2785 3876//2330
+f 3867//2328 3882//2794 3883//2331
+f 3893//2335 3878//2788 3892//2332
+f 3888//2336 3873//2315 3887//2795
+f 3883//2331 3898//2346 3899//2334
+f 3894//2799 3879//2319 3893//2335
+f 3889//2340 3874//2321 3888//2336
+f 3884//2787 3899//2334 3900//2337
+f 3879//2319 3894//2799 3895//2339
+f 3890//2797 3875//2793 3889//2340
+f 3885//2790 3900//2337 3901//2796
+f 3880//2338 3895//2339 3896//2342
+f 3891//2345 3876//2330 3890//2797
+f 3881//2325 3896//2342 3897//2344
+f 3892//2332 3877//2305 3891//2345
+f 3882//2794 3897//2344 3898//2346
+f 3896//2342 3911//2360 3912//2798
+f 3907//2350 3892//2332 3906//2348
+f 3897//2344 3912//2798 3913//2349
+f 3908//2354 3893//2335 3907//2350
+f 3903//2800 3888//2336 3902//2351
+f 3898//2346 3913//2349 3914//2352
+f 3909//2371 3894//2799 3908//2354
+f 3904//2802 3889//2340 3903//2800
+f 3899//2334 3914//2352 3915//2801
+f 3894//2799 3909//2371 3910//2357
+f 3905//2361 3890//2797 3904//2802
+f 3900//2337 3915//2801 3916//2359
+f 3895//2339 3910//2357 3911//2360
+f 3906//2348 3891//2345 3905//2361
+f 3915//2801 3930//2806 3931//2803
+f 3910//2357 3925//2375 3926//2363
+f 3921//2366 3906//2348 3920//2364
+f 3911//2360 3926//2363 3927//2365
+f 3922//2368 3907//2350 3921//2366
+f 3912//2798 3927//2365 3928//2367
+f 3923//2372 3908//2354 3922//2368
+f 3918//2805 3903//2800 3917//2804
+f 3913//2349 3928//2367 3929//2370
+f 3924//2379 3909//2371 3923//2372
+f 3919//2376 3904//2802 3918//2805
+f 3914//2352 3929//2370 3930//2806
+f 3909//2371 3924//2379 3925//2375
+f 3920//2364 3905//2361 3919//2376
+f 3934//2810 3919//2376 3933//2807
+f 3929//2370 3944//2390 3945//2808
+f 3924//2379 3939//2395 3940//2809
+f 3935//2384 3920//2364 3934//2810
+f 3930//2806 3945//2808 3946//2811
+f 3925//2375 3940//2809 3941//2383
+f 3936//2386 3921//2366 3935//2384
+f 3926//2363 3941//2383 3942//2812
+f 3937//2388 3922//2368 3936//2386
+f 3927//2365 3942//2812 3943//2387
+f 3938//2814 3923//2372 3937//2388
+f 3933//2807 3918//2805 3932//2813
+f 3928//2367 3943//2387 3944//2390
+f 3939//2395 3924//2379 3938//2814
+f 3953//2396 3938//2814 3952//2392
+f 3948//2397 3933//2807 3947//2815
+f 3943//2387 3958//2819 3959//2394
+f 3954//2413 3939//2395 3953//2396
+f 3949//2400 3934//2810 3948//2397
+f 3944//2390 3959//2394 3960//2398
+f 3939//2395 3954//2413 3955//2816
+f 3950//2403 3935//2384 3949//2400
+f 3945//2808 3960//2398 3961//2817
+f 3940//2809 3955//2816 3956//2818
+f 3951//2405 3936//2386 3950//2403
+f 3941//2383 3956//2818 3957//2404
+f 3952//2392 3937//2388 3951//2405
+f 3942//2812 3957//2404 3958//2819
+f 3956//2818 3971//2420 3972//2407
+f 3967//2410 3952//2392 3966//2820
+f 3957//2404 3972//2407 3973//2409
+f 3968//2414 3953//2396 3967//2410
+f 3963//2822 3948//2397 3962//2411
+f 3958//2819 3973//2409 3974//2821
+f 3969//2430 3954//2413 3968//2414
+f 3964//2418 3949//2400 3963//2822
+f 3959//2394 3974//2821 3975//2416
+f 3954//2413 3969//2430 3970//2417
+f 3965//2421 3950//2403 3964//2418
+f 3960//2398 3975//2416 3976//2419
+f 3955//2816 3970//2417 3971//2420
+f 3966//2820 3951//2405 3965//2421
+f 3991//2439 3976//2419 3990//2422
+f 3970//2417 3985//2823 3986//2423
+f 3965//2421 3980//2435 3981//2424
+f 3971//2420 3986//2423 3987//2425
+f 3966//2820 3981//2424 3982//2426
+f 3972//2407 3987//2425 3988//2427
+f 3967//2410 3982//2426 3983//2428
+f 3962//2411 3977//2446 3978//2429
+f 3989//2433 3974//2821 3988//2427
+f 3968//2414 3983//2428 3984//2431
+f 3963//2822 3978//2429 3979//2432
+f 3990//2422 3975//2416 3989//2433
+f 3969//2430 3984//2431 3985//2823
+f 3964//2418 3979//2432 3980//2435
+f 4005//2440 3990//2422 4004//2436
+f 3984//2431 3999//2449 4000//2437
+f 3979//2432 3994//2450 3995//2438
+f 4006//2831 3991//2439 4005//2440
+f 4001//2825 3986//2423 4000//2437
+f 3980//2435 3995//2438 3996//2824
+f 4002//2444 3987//2425 4001//2825
+f 3981//2424 3996//2824 3997//2826
+f 4003//2827 3988//2427 4002//2444
+f 3982//2426 3997//2826 3998//2445
+f 3977//2446 3992//2828 3993//2447
+f 4004//2436 3989//2433 4003//2827
+f 3983//2428 3998//2445 3999//2449
+f 3978//2429 3993//2447 3994//2450
+f 3992//2828 4007//2469 4008//2452
+f 4019//2830 4004//2436 4018//2453
+f 3998//2445 4013//2465 4014//2454
+f 3993//2447 4008//2452 4009//2829
+f 4020//2459 4005//2440 4019//2830
+f 4015//2460 4000//2437 4014//2454
+f 3994//2450 4009//2829 4010//2457
+f 4021//2476 4006//2831 4020//2459
+f 4016//2462 4001//2825 4015//2460
+f 3995//2438 4010//2457 4011//2461
+f 4017//2464 4002//2444 4016//2462
+f 3996//2824 4011//2461 4012//2463
+f 4018//2453 4003//2827 4017//2464
+f 3997//2826 4012//2463 4013//2465
+f 4011//2461 4026//2836 4027//2832
+f 4033//2471 4018//2453 4032//2467
+f 4012//2463 4027//2832 4028//2468
+f 4007//2469 4022//2839 4023//2833
+f 4034//2834 4019//2830 4033//2471
+f 4013//2465 4028//2468 4029//2472
+f 4008//2452 4023//2833 4024//2473
+f 4035//2477 4020//2459 4034//2834
+f 4030//2478 4015//2460 4029//2472
+f 4009//2829 4024//2473 4025//2835
+f 4036//2494 4021//2476 4035//2477
+f 4031//2480 4016//2462 4030//2478
+f 4010//2457 4025//2835 4026//2836
+f 4032//2467 4017//2464 4031//2480
+f 4046//2483 4031//2480 4045//2481
+f 4025//2835 4040//2493 4041//2482
+f 4047//2837 4032//2467 4046//2483
+f 4026//2836 4041//2482 4042//2484
+f 4048//2489 4033//2471 4047//2837
+f 4027//2832 4042//2484 4043//2838
+f 4022//2839 4037//2506 4038//2488
+f 4049//2492 4034//2834 4048//2489
+f 4028//2468 4043//2838 4044//2490
+f 4023//2833 4038//2488 4039//2840
+f 4050//2495 4035//2477 4049//2492
+f 4045//2481 4030//2478 4044//2490
+f 4024//2473 4039//2840 4040//2493
+f 4051//2843 4036//2494 4050//2495
+f 4065//2500 4050//2495 4064//2496
+f 4044//2490 4059//2844 4060//2841
+f 4039//2840 4054//2845 4055//2842
+f 4066//2848 4051//2843 4065//2500
+f 4061//2502 4046//2483 4060//2841
+f 4040//2493 4055//2842 4056//2501
+f 4062//2504 4047//2837 4061//2502
+f 4041//2482 4056//2501 4057//2503
+f 4063//2508 4048//2489 4062//2504
+f 4042//2484 4057//2503 4058//2505
+f 4037//2506 4052//2511 4053//2507
+f 4064//2496 4049//2492 4063//2508
+f 4043//2838 4058//2505 4059//2844
+f 4038//2488 4053//2507 4054//2845
+f 4052//2511 4067//2529 4068//2512
+f 4079//2847 4064//2496 4078//2513
+f 4058//2505 4073//2525 4074//2846
+f 4053//2507 4068//2512 4069//2515
+f 4080//2849 4065//2500 4079//2847
+f 4059//2844 4074//2846 4075//2517
+f 4054//2845 4069//2515 4070//2518
+f 4081//2537 4066//2848 4080//2849
+f 4076//2522 4061//2502 4075//2517
+f 4055//2842 4070//2518 4071//2850
+f 4077//2524 4062//2504 4076//2522
+f 4056//2501 4071//2850 4072//2851
+f 4078//2513 4063//2508 4077//2524
+f 4057//2503 4072//2851 4073//2525
+f 4071//2850 4086//2856 4087//2526
+f 4093//2531 4078//2513 4092//2852
+f 4072//2851 4087//2526 4088//2528
+f 4067//2529 4082//2858 4083//2853
+f 4094//2534 4079//2847 4093//2531
+f 4073//2525 4088//2528 4089//2854
+f 4068//2512 4083//2853 4084//2855
+f 4095//2538 4080//2849 4094//2534
+f 4074//2846 4089//2854 4090//2535
+f 4069//2515 4084//2855 4085//2536
+f 4096//2555 4081//2537 4095//2538
+f 4091//2540 4076//2522 4090//2535
+f 4070//2518 4085//2536 4086//2856
+f 4092//2852 4077//2524 4091//2540
+f 4090//2535 4105//2553 4106//2541
+f 4085//2536 4100//2554 4101//2542
+f 4091//2540 4106//2541 4107//2543
+f 4086//2856 4101//2542 4102//2544
+f 4092//2852 4107//2543 4108//2545
+f 4087//2526 4102//2544 4103//2857
+f 4098//2567 4083//2853 4097//2548
+f 4093//2531 4108//2545 4109//2549
+f 4088//2528 4103//2857 4104//2859
+f 4083//2853 4098//2567 4099//2551
+f 4094//2534 4109//2549 4110//2860
+f 4089//2854 4104//2859 4105//2553
+f 4084//2855 4099//2551 4100//2554
+f 4095//2538 4110//2860 4111//2556
+f 4109//2549 4124//2569 4125//2557
+f 4104//2859 4119//2570 4120//2558
+f 4115//2562 4100//2554 4114//2559
+f 4110//2860 4125//2557 4126//2861
+f 4105//2553 4120//2558 4121//2561
+f 4116//2564 4101//2542 4115//2562
+f 4106//2541 4121//2561 4122//2563
+f 4117//2566 4102//2544 4116//2564
+f 4107//2543 4122//2563 4123//2862
+f 4118//2863 4103//2857 4117//2566
+f 4113//2571 4098//2567 4112//2568
+f 4108//2545 4123//2862 4124//2569
+f 4103//2857 4118//2863 4119//2570
+f 4114//2559 4099//2551 4113//2571
+f 4123//2862 4138//2866 4139//2572
+f 4134//2591 4119//2570 4133//2574
+f 4129//2578 4114//2559 4128//2864
+f 4124//2569 4139//2572 4140//2576
+f 4119//2570 4134//2591 4135//2577
+f 4130//2865 4115//2562 4129//2578
+f 4125//2557 4140//2576 4141//2579
+f 4120//2558 4135//2577 4136//2580
+f 4131//2583 4116//2564 4130//2865
+f 4121//2561 4136//2580 4137//2582
+f 4132//2867 4117//2566 4131//2583
+f 4122//2563 4137//2582 4138//2866
+f 4133//2574 4118//2863 4132//2867
+f 4128//2864 4113//2571 4127//2586
+f 4137//2582 4152//2600 4153//2587
+f 4148//2869 4133//2574 4147//2588
+f 4143//2593 4128//2864 4142//2589
+f 4138//2866 4153//2587 4154//2868
+f 4149//2609 4134//2591 4148//2869
+f 4144//2596 4129//2578 4143//2593
+f 4139//2572 4154//2868 4155//2870
+f 4134//2591 4149//2609 4150//2595
+f 4145//2599 4130//2865 4144//2596
+f 4140//2576 4155//2870 4156//2597
+f 4135//2577 4150//2595 4151//2598
+f 4146//2601 4131//2583 4145//2599
+f 4136//2580 4151//2598 4152//2600
+f 4147//2588 4132//2867 4146//2601
+f 4161//2604 4146//2601 4160//2602
+f 4151//2598 4166//2616 4167//2871
+f 4162//2606 4147//2588 4161//2604
+f 4152//2600 4167//2871 4168//2605
+f 4163//2610 4148//2869 4162//2606
+f 4158//2611 4143//2593 4157//2872
+f 4153//2587 4168//2605 4169//2608
+f 4164//2875 4149//2609 4163//2610
+f 4159//2874 4144//2596 4158//2611
+f 4154//2868 4169//2608 4170//2873
+f 4149//2609 4164//2875 4165//2613
+f 4160//2602 4145//2599 4159//2874
+f 4155//2870 4170//2873 4171//2615
+f 4150//2595 4165//2613 4166//2616
+f 4164//2875 4179//2633 4180//2618
+f 4175//2622 4160//2602 4174//2619
+f 4170//2873 4185//2631 4186//2620
+f 4165//2613 4180//2618 4181//2621
+f 4176//2876 4161//2604 4175//2622
+f 4166//2616 4181//2621 4182//2623
+f 4177//2626 4162//2606 4176//2876
+f 4167//2871 4182//2623 4183//2625
+f 4178//2629 4163//2610 4177//2626
+f 4173//2878 4158//2611 4172//2877
+f 4168//2605 4183//2625 4184//2628
+f 4179//2633 4164//2875 4178//2629
+f 4174//2619 4159//2874 4173//2878
+f 4169//2608 4184//2628 4185//2631
+f 4183//2625 4199//2644 4200//2632
+f 4195//2883 4179//2633 4194//2634
+f 4190//2638 4174//2619 4189//2635
+f 4184//2628 4200//2632 4201//2636
+f 4179//2633 4195//2883 4196//2637
+f 4191//2880 4175//2622 4190//2638
+f 4185//2631 4201//2636 4202//2879
+f 4180//2618 4196//2637 4197//2640
+f 4192//2643 4176//2876 4191//2880
+f 4181//2621 4197//2640 4198//2642
+f 4193//2881 4177//2626 4192//2643
+f 4182//2623 4198//2642 4199//2644
+f 4194//2634 4178//2629 4193//2881
+f 4189//2635 4173//2878 4188//2882
+f 4198//2642 4213//2886 4214//2647
+f 4209//2884 4194//2634 4208//2648
+f 4204//2653 4189//2635 4203//2649
+f 4199//2644 4214//2647 4215//2650
+f 4210//2669 4195//2883 4209//2884
+f 4205//2656 4190//2638 4204//2653
+f 4200//2632 4215//2650 4216//2654
+f 4195//2883 4210//2669 4211//2655
+f 4206//2659 4191//2880 4205//2656
+f 4201//2636 4216//2654 4217//2657
+f 4196//2637 4211//2655 4212//2885
+f 4207//2661 4192//2643 4206//2659
+f 4197//2640 4212//2885 4213//2886
+f 4208//2648 4193//2881 4207//2661
+f 4222//2664 4207//2661 4221//2662
+f 4228//2665 4213//2886 4227//2663
+f 4223//2666 4208//2648 4222//2664
+f 4229//2668 4214//2647 4228//2665
+f 4224//2887 4209//2884 4223//2666
+f 4203//2649 4218//2686 4219//2667
+f 4230//2672 4215//2650 4229//2668
+f 4225//2673 4210//2669 4224//2887
+f 4204//2653 4219//2667 4220//2671
+f 4231//2674 4216//2654 4230//2672
+f 4226//2675 4211//2655 4225//2673
+f 4205//2656 4220//2671 4221//2662
+f 4232//2678 4217//2657 4231//2674
+f 4227//2663 4212//2885 4226//2675
+f 4241//2680 4226//2675 4240//2676
+f 4220//2671 4235//2689 4236//2677
+f 4247//2891 4232//2678 4246//2679
+f 4242//2888 4227//2663 4241//2680
+f 4221//2662 4236//2677 4237//2681
+f 4243//2684 4228//2665 4242//2888
+f 4222//2664 4237//2681 4238//2683
+f 4244//2688 4229//2668 4243//2684
+f 4223//2666 4238//2683 4239//2685
+f 4218//2686 4233//2892 4234//2687
+f 4245//2690 4230//2672 4244//2688
+f 4240//2676 4225//2673 4239//2685
+f 4219//2667 4234//2687 4235//2689
+f 4246//2679 4231//2674 4245//2690
+f 4260//2890 4245//2690 4259//2691
+f 4239//2685 4254//2703 4255//2692
+f 4234//2687 4249//2893 4250//2889
+f 4261//2697 4246//2679 4260//2890
+f 4256//2698 4241//2680 4255//2692
+f 4235//2689 4250//2889 4251//2695
+f 4262//2715 4247//2891 4261//2697
+f 4257//2700 4242//2888 4256//2698
+f 4236//2677 4251//2695 4252//2699
+f 4258//2702 4243//2684 4257//2700
+f 4237//2681 4252//2699 4253//2701
+f 4259//2691 4244//2688 4258//2702
+f 4238//2683 4253//2701 4254//2703
+f 4233//2892 4248//2708 4249//2893
+f 4274//2895 4259//2691 4273//2894
+f 4253//2701 4268//2720 4269//2707
+f 4248//2708 4263//2725 4264//2709
+f 4275//2713 4260//2890 4274//2895
+f 4254//2703 4269//2707 4270//2711
+f 4249//2893 4264//2709 4265//2896
+f 4276//2716 4261//2697 4275//2713
+f 4271//2717 4256//2698 4270//2711
+f 4250//2889 4265//2896 4266//2714
+f 4277//2732 4262//2715 4276//2716
+f 4272//2719 4257//2700 4271//2717
+f 4251//2695 4266//2714 4267//2718
+f 4273//2894 4258//2702 4272//2719
+f 4252//2699 4267//2718 4268//2720
+f 4288//2723 4273//2894 4287//2897
+f 4267//2718 4282//2735 4283//2722
+f 4289//2727 4274//2895 4288//2723
+f 4268//2720 4283//2722 4284//2724
+f 4263//2725 4278//2745 4279//2726
+f 4290//2730 4275//2713 4289//2727
+f 4269//2707 4284//2724 4285//2728
+f 4264//2709 4279//2726 4280//2729
+f 4291//2733 4276//2716 4290//2730
+f 4286//2734 4271//2717 4285//2728
+f 4265//2896 4280//2729 4281//2731
+f 4292//2898 4277//2732 4291//2733
+f 4287//2897 4272//2719 4286//2734
+f 4266//2714 4281//2731 4282//2735
+f 4280//2729 4295//2748 4296//2736
+f 4307//2756 4292//2898 4306//2899
+f 4302//2741 4287//2897 4301//2739
+f 4281//2731 4296//2736 4297//2740
+f 4303//2743 4288//2723 4302//2741
+f 4282//2735 4297//2740 4298//2742
+f 4304//2747 4289//2727 4303//2743
+f 4283//2722 4298//2742 4299//2900
+f 4278//2745 4293//2902 4294//2746
+f 4305//2901 4290//2730 4304//2747
+f 4300//2750 4285//2728 4299//2900
+f 4279//2726 4294//2746 4295//2748
+f 4306//2899 4291//2733 4305//2901
+f 4301//2739 4286//2734 4300//2750
+f 4316//2754 4300//2750 4315//2751
+f 4294//2746 4310//2764 4311//2752
+f 4322//2757 4306//2899 4321//2753
+f 4317//2758 4301//2739 4316//2754
+f 4295//2748 4311//2752 4312//2755
+f 4323//2905 4307//2756 4322//2757
+f 4318//2760 4302//2741 4317//2758
+f 4296//2736 4312//2755 4313//2759
+f 4319//2762 4303//2743 4318//2760
+f 4297//2740 4313//2759 4314//2761
+f 4320//2765 4304//2747 4319//2762
+f 4298//2742 4314//2761 4315//2751
+f 4293//2902 4309//2904 4310//2764
+f 4321//2753 4305//2901 4320//2765
+f 4335//2770 4320//2765 4334//2766
+f 4314//2761 4329//2780 4330//2903
+f 4309//2904 4324//2908 4325//2769
+f 4336//2772 4321//2753 4335//2770
+f 4331//2773 4316//2754 4330//2903
+f 4310//2764 4325//2769 4326//2771
+f 4337//2906 4322//2757 4336//2772
+f 4332//2777 4317//2758 4331//2773
+f 4311//2752 4326//2771 4327//2774
+f 4338//2907 4323//2905 4337//2906
+f 4333//2779 4318//2760 4332//2777
+f 4312//2755 4327//2774 4328//2778
+f 4334//2766 4319//2762 4333//2779
+f 4313//2759 4328//2778 4329//2780
+f 3867//2328 4334//2766 3866//2324
+f 3862//2785 4329//2780 3861//2326
+f 3868//2310 4335//2770 3867//2328
+f 3863//2303 4330//2903 3862//2785
+f 3858//2306 4325//2769 3857//2786
+f 3869//2309 4336//2772 3868//2310
+f 3864//2312 4331//2773 3863//2303
+f 3859//2314 4326//2771 3858//2306
+f 3870//2789 4337//2906 3869//2309
+f 3865//2318 4332//2777 3864//2312
+f 3860//2320 4327//2774 3859//2314
+f 4337//2906 3870//2789 3871//2791
+f 3866//2324 4333//2779 3865//2318
+f 3861//2326 4328//2778 3860//2320
+o Tooth_Sphere.009
+v -0.011752 1.034128 -0.041332
+v -0.030343 1.032763 -0.041332
+v -0.047476 1.030545 -0.041332
+v -0.062494 1.027561 -0.041332
+v -0.074818 1.023925 -0.041332
+v -0.083976 1.019777 -0.041332
+v -0.089616 1.015275 -0.041332
+v -0.091520 1.010594 -0.041332
+v -0.089616 1.005913 -0.041332
+v -0.083976 1.001411 -0.041332
+v -0.074818 0.997263 -0.041332
+v -0.062494 0.993627 -0.041332
+v -0.047476 0.990643 -0.041332
+v -0.030343 0.988425 -0.041332
+v -0.011752 0.987060 -0.041332
+v -0.011380 1.034128 -0.043251
+v -0.029614 1.032763 -0.045097
+v -0.046418 1.030545 -0.046797
+v -0.061147 1.027561 -0.048288
+v -0.073235 1.023925 -0.049511
+v -0.082217 1.019777 -0.050420
+v -0.087748 1.015275 -0.050980
+v -0.089616 1.010594 -0.051169
+v -0.087748 1.005913 -0.050980
+v -0.082217 1.001411 -0.050420
+v -0.073235 0.997263 -0.049511
+v -0.061147 0.993627 -0.048288
+v -0.046418 0.990643 -0.046797
+v -0.029614 0.988425 -0.045097
+v -0.011380 0.987060 -0.043251
+v -0.010280 1.034128 -0.045097
+v -0.027456 1.032763 -0.048716
+v -0.043285 1.030545 -0.052052
+v -0.057159 1.027561 -0.054976
+v -0.068546 1.023925 -0.057376
+v -0.077007 1.019777 -0.059159
+v -0.082217 1.015275 -0.060257
+v -0.083976 1.010594 -0.060628
+v -0.082217 1.005913 -0.060257
+v -0.077007 1.001411 -0.059159
+v -0.068546 0.997263 -0.057376
+v -0.057159 0.993627 -0.054976
+v -0.043285 0.990643 -0.052052
+v -0.027456 0.988425 -0.048716
+v -0.010280 0.987060 -0.045097
+v -0.008494 1.034128 -0.046797
+v -0.023951 1.032763 -0.052052
+v -0.038197 1.030545 -0.056895
+v -0.050684 1.027561 -0.061140
+v -0.060931 1.023925 -0.064624
+v -0.068546 1.019777 -0.067213
+v -0.073235 1.015275 -0.068807
+v -0.074818 1.010594 -0.069345
+v -0.073235 1.005913 -0.068807
+v -0.068546 1.001411 -0.067213
+v -0.060931 0.997263 -0.064624
+v -0.050684 0.993627 -0.061140
+v -0.038197 0.990643 -0.056895
+v -0.023951 0.988425 -0.052052
+v -0.008494 0.987060 -0.046797
+v -0.006089 1.034128 -0.048288
+v -0.019235 1.032763 -0.054976
+v -0.031350 1.030545 -0.061140
+v -0.041969 1.027561 -0.066543
+v -0.050684 1.023925 -0.070977
+v -0.057159 1.019777 -0.074272
+v -0.061147 1.015275 -0.076301
+v -0.062494 1.010594 -0.076986
+v -0.061147 1.005913 -0.076301
+v -0.057159 1.001411 -0.074272
+v -0.050684 0.997263 -0.070977
+v -0.041969 0.993627 -0.066543
+v -0.031350 0.990643 -0.061140
+v -0.019235 0.988425 -0.054976
+v -0.006089 0.987060 -0.048288
+v -0.003159 1.034128 -0.049511
+v -0.013488 1.032763 -0.057376
+v -0.023007 1.030545 -0.064624
+v -0.031350 1.027561 -0.070977
+v -0.038197 1.023925 -0.076191
+v -0.043285 1.019777 -0.080065
+v -0.046418 1.015275 -0.082451
+v -0.047476 1.010594 -0.083256
+v -0.046418 1.005913 -0.082451
+v -0.043285 1.001411 -0.080065
+v -0.038197 0.997263 -0.076191
+v -0.031350 0.993627 -0.070977
+v -0.023007 0.990643 -0.064624
+v -0.013488 0.988425 -0.057376
+v -0.003159 0.987060 -0.049511
+v 0.000183 1.034128 -0.050420
+v -0.006931 1.032763 -0.059159
+v -0.013488 1.030545 -0.067213
+v -0.019235 1.027561 -0.074272
+v -0.023951 1.023925 -0.080065
+v -0.027456 1.019777 -0.084370
+v -0.029614 1.015275 -0.087020
+v -0.030343 1.010594 -0.087916
+v -0.029614 1.005913 -0.087020
+v -0.027456 1.001411 -0.084370
+v -0.023951 0.997263 -0.080065
+v -0.019235 0.993627 -0.074272
+v -0.013488 0.990643 -0.067213
+v -0.006931 0.988425 -0.059159
+v 0.000183 0.987060 -0.050420
+v 0.003810 1.034128 -0.050980
+v 0.000183 1.032763 -0.060257
+v -0.003159 1.030545 -0.068807
+v -0.006089 1.027561 -0.076301
+v -0.008494 1.023925 -0.082451
+v -0.010280 1.019777 -0.087020
+v -0.011380 1.015275 -0.089835
+v -0.011752 1.010594 -0.090785
+v -0.011380 1.005913 -0.089835
+v -0.010280 1.001411 -0.087020
+v -0.008494 0.997263 -0.082451
+v -0.006089 0.993627 -0.076301
+v -0.003159 0.990643 -0.068807
+v 0.000183 0.988425 -0.060257
+v 0.003810 0.987060 -0.050980
+v 0.007582 1.034128 -0.051169
+v 0.007582 1.032763 -0.060628
+v 0.007582 1.030545 -0.069345
+v 0.007582 1.027561 -0.076986
+v 0.007582 1.023925 -0.083256
+v 0.007582 1.019777 -0.087916
+v 0.007582 1.015275 -0.090785
+v 0.007582 1.010594 -0.091754
+v 0.007582 1.005913 -0.090785
+v 0.007582 1.001411 -0.087916
+v 0.007582 0.997263 -0.083256
+v 0.007582 0.993627 -0.076986
+v 0.007582 0.990643 -0.069345
+v 0.007582 0.988425 -0.060628
+v 0.007582 0.987060 -0.051169
+v 0.011354 1.034128 -0.050980
+v 0.014981 1.032763 -0.060257
+v 0.018323 1.030545 -0.068807
+v 0.021253 1.027561 -0.076301
+v 0.023657 1.023925 -0.082451
+v 0.025444 1.019777 -0.087020
+v 0.026544 1.015275 -0.089835
+v 0.026916 1.010594 -0.090785
+v 0.026544 1.005913 -0.089835
+v 0.025444 1.001411 -0.087020
+v 0.023657 0.997263 -0.082451
+v 0.021253 0.993627 -0.076301
+v 0.018323 0.990643 -0.068807
+v 0.014981 0.988425 -0.060257
+v 0.011354 0.987060 -0.050980
+v 0.014981 1.034128 -0.050420
+v 0.022095 1.032763 -0.059159
+v 0.028652 1.030545 -0.067213
+v 0.034399 1.027561 -0.074272
+v 0.039115 1.023925 -0.080065
+v 0.042620 1.019777 -0.084370
+v 0.044778 1.015275 -0.087020
+v 0.045506 1.010594 -0.087916
+v 0.044778 1.005913 -0.087020
+v 0.042620 1.001411 -0.084370
+v 0.039115 0.997263 -0.080065
+v 0.034399 0.993627 -0.074272
+v 0.028652 0.990643 -0.067213
+v 0.022095 0.988425 -0.059159
+v 0.014981 0.987060 -0.050420
+v 0.018323 1.034128 -0.049511
+v 0.028652 1.032763 -0.057376
+v 0.038170 1.030545 -0.064624
+v 0.046514 1.027561 -0.070977
+v 0.053361 1.023925 -0.076191
+v 0.058449 1.019777 -0.080065
+v 0.061582 1.015275 -0.082451
+v 0.062640 1.010594 -0.083256
+v 0.061582 1.005913 -0.082451
+v 0.058449 1.001411 -0.080065
+v 0.053361 0.997263 -0.076191
+v 0.046514 0.993627 -0.070977
+v 0.038170 0.990643 -0.064624
+v 0.028652 0.988425 -0.057376
+v 0.018323 0.987060 -0.049511
+v 0.021253 1.034128 -0.048288
+v 0.034399 1.032763 -0.054976
+v 0.046514 1.030545 -0.061140
+v 0.057133 1.027561 -0.066543
+v 0.065848 1.023925 -0.070977
+v 0.072323 1.019777 -0.074272
+v 0.076311 1.015275 -0.076301
+v 0.077657 1.010594 -0.076986
+v 0.076311 1.005913 -0.076301
+v 0.072323 1.001411 -0.074272
+v 0.065848 0.997263 -0.070977
+v 0.057133 0.993627 -0.066543
+v 0.046514 0.990643 -0.061140
+v 0.034399 0.988425 -0.054976
+v 0.021253 0.987060 -0.048288
+v 0.023657 1.034128 -0.046797
+v 0.039115 1.032763 -0.052052
+v 0.053361 1.030545 -0.056895
+v 0.065848 1.027561 -0.061140
+v 0.076095 1.023925 -0.064624
+v 0.083710 1.019777 -0.067213
+v 0.088399 1.015275 -0.068807
+v 0.089982 1.010594 -0.069345
+v 0.088399 1.005913 -0.068807
+v 0.083710 1.001411 -0.067213
+v 0.076095 0.997263 -0.064624
+v 0.065848 0.993627 -0.061140
+v 0.053361 0.990643 -0.056895
+v 0.039115 0.988425 -0.052052
+v 0.023657 0.987060 -0.046797
+v 0.025444 1.034128 -0.045097
+v 0.042620 1.032763 -0.048716
+v 0.058449 1.030545 -0.052052
+v 0.072323 1.027561 -0.054976
+v 0.083710 1.023925 -0.057376
+v 0.092170 1.019777 -0.059159
+v 0.097381 1.015275 -0.060257
+v 0.099140 1.010594 -0.060628
+v 0.097381 1.005913 -0.060257
+v 0.092170 1.001411 -0.059159
+v 0.083710 0.997263 -0.057376
+v 0.072323 0.993627 -0.054976
+v 0.058449 0.990643 -0.052052
+v 0.042620 0.988425 -0.048716
+v 0.025444 0.987060 -0.045097
+v 0.026544 1.034128 -0.043251
+v 0.044778 1.032763 -0.045097
+v 0.061582 1.030545 -0.046797
+v 0.076311 1.027561 -0.048288
+v 0.088399 1.023925 -0.049511
+v 0.097381 1.019777 -0.050420
+v 0.102912 1.015275 -0.050980
+v 0.104779 1.010594 -0.051169
+v 0.102912 1.005913 -0.050980
+v 0.097381 1.001411 -0.050420
+v 0.088399 0.997263 -0.049511
+v 0.076311 0.993627 -0.048288
+v 0.061582 0.990643 -0.046797
+v 0.044778 0.988425 -0.045097
+v 0.026544 0.987060 -0.043251
+v 0.026916 1.034128 -0.041332
+v 0.045506 1.032763 -0.041332
+v 0.062640 1.030545 -0.041332
+v 0.077657 1.027561 -0.041332
+v 0.089982 1.023925 -0.041332
+v 0.099140 1.019777 -0.041332
+v 0.104779 1.015275 -0.041332
+v 0.106684 1.010594 -0.041332
+v 0.104779 1.005913 -0.041332
+v 0.099140 1.001411 -0.041332
+v 0.089982 0.997263 -0.041332
+v 0.077657 0.993627 -0.041332
+v 0.062640 0.990643 -0.041332
+v 0.045506 0.988425 -0.041332
+v 0.026916 0.987060 -0.041332
+v 0.026544 1.034128 -0.039413
+v 0.044778 1.032763 -0.037568
+v 0.061582 1.030545 -0.035867
+v 0.076311 1.027561 -0.034377
+v 0.088399 1.023925 -0.033154
+v 0.097381 1.019777 -0.032245
+v 0.102912 1.015275 -0.031685
+v 0.104779 1.010594 -0.031496
+v 0.102912 1.005913 -0.031685
+v 0.097381 1.001411 -0.032245
+v 0.088399 0.997263 -0.033154
+v 0.076311 0.993627 -0.034377
+v 0.061582 0.990643 -0.035867
+v 0.044778 0.988425 -0.037568
+v 0.026544 0.987060 -0.039413
+v 0.025444 1.034128 -0.037568
+v 0.042620 1.032763 -0.033948
+v 0.058449 1.030545 -0.030612
+v 0.072323 1.027561 -0.027689
+v 0.083710 1.023925 -0.025289
+v 0.092170 1.019777 -0.023506
+v 0.097381 1.015275 -0.022408
+v 0.099140 1.010594 -0.022037
+v 0.097381 1.005913 -0.022408
+v 0.092170 1.001411 -0.023506
+v 0.083710 0.997263 -0.025289
+v 0.072323 0.993627 -0.027689
+v 0.058449 0.990643 -0.030612
+v 0.042620 0.988425 -0.033948
+v 0.025444 0.987060 -0.037568
+v 0.023657 1.034128 -0.035867
+v 0.039115 1.032763 -0.030612
+v 0.053361 1.030545 -0.025770
+v 0.065847 1.027561 -0.021525
+v 0.076095 1.023925 -0.018041
+v 0.083710 1.019777 -0.015452
+v 0.088399 1.015275 -0.013858
+v 0.089982 1.010594 -0.013320
+v 0.088399 1.005913 -0.013858
+v 0.083710 1.001411 -0.015452
+v 0.076095 0.997263 -0.018041
+v 0.065847 0.993627 -0.021525
+v 0.053361 0.990643 -0.025770
+v 0.039115 0.988425 -0.030612
+v 0.023657 0.987060 -0.035867
+v 0.021253 1.034128 -0.034377
+v 0.034399 1.032763 -0.027689
+v 0.046514 1.030545 -0.021525
+v 0.057133 1.027561 -0.016122
+v 0.065847 1.023925 -0.011688
+v 0.072323 1.019777 -0.008393
+v 0.076311 1.015275 -0.006364
+v 0.077657 1.010594 -0.005679
+v 0.076311 1.005913 -0.006364
+v 0.072323 1.001411 -0.008393
+v 0.065847 0.997263 -0.011688
+v 0.057133 0.993627 -0.016122
+v 0.046514 0.990643 -0.021525
+v 0.034399 0.988425 -0.027689
+v 0.021253 0.987060 -0.034377
+v 0.018323 1.034128 -0.033154
+v 0.028652 1.032763 -0.025289
+v 0.038170 1.030545 -0.018041
+v 0.046514 1.027561 -0.011688
+v 0.053361 1.023925 -0.006474
+v 0.058449 1.019777 -0.002600
+v 0.061582 1.015275 -0.000214
+v 0.062640 1.010594 0.000591
+v 0.061582 1.005913 -0.000214
+v 0.058449 1.001411 -0.002600
+v 0.053361 0.997263 -0.006474
+v 0.046514 0.993627 -0.011688
+v 0.038170 0.990643 -0.018041
+v 0.028652 0.988425 -0.025289
+v 0.018323 0.987060 -0.033154
+v 0.007582 0.986599 -0.041332
+v 0.014981 1.034128 -0.032245
+v 0.022095 1.032763 -0.023506
+v 0.028652 1.030545 -0.015452
+v 0.034399 1.027561 -0.008393
+v 0.039115 1.023925 -0.002600
+v 0.042620 1.019777 0.001705
+v 0.044778 1.015275 0.004356
+v 0.045506 1.010594 0.005251
+v 0.044778 1.005913 0.004356
+v 0.042620 1.001411 0.001705
+v 0.039115 0.997263 -0.002600
+v 0.034399 0.993627 -0.008393
+v 0.028652 0.990643 -0.015452
+v 0.022095 0.988425 -0.023506
+v 0.014981 0.987060 -0.032245
+v 0.011354 1.034128 -0.031685
+v 0.014981 1.032763 -0.022408
+v 0.018323 1.030545 -0.013858
+v 0.021253 1.027561 -0.006364
+v 0.023657 1.023925 -0.000214
+v 0.025444 1.019777 0.004356
+v 0.026544 1.015275 0.007170
+v 0.026916 1.010594 0.008120
+v 0.026544 1.005913 0.007170
+v 0.025444 1.001411 0.004356
+v 0.023657 0.997263 -0.000214
+v 0.021253 0.993627 -0.006364
+v 0.018323 0.990643 -0.013858
+v 0.014981 0.988425 -0.022408
+v 0.011354 0.987060 -0.031685
+v 0.007582 1.034128 -0.031496
+v 0.007582 1.032763 -0.022037
+v 0.007582 1.030545 -0.013320
+v 0.007582 1.027561 -0.005679
+v 0.007582 1.023925 0.000591
+v 0.007582 1.019777 0.005251
+v 0.007582 1.015275 0.008120
+v 0.007582 1.010594 0.009089
+v 0.007582 1.005913 0.008120
+v 0.007582 1.001411 0.005251
+v 0.007582 0.997263 0.000591
+v 0.007582 0.993627 -0.005679
+v 0.007582 0.990643 -0.013320
+v 0.007582 0.988425 -0.022037
+v 0.007582 0.987060 -0.031496
+v 0.003810 1.034128 -0.031685
+v 0.000183 1.032763 -0.022408
+v -0.003159 1.030545 -0.013858
+v -0.006089 1.027561 -0.006364
+v -0.008494 1.023925 -0.000214
+v -0.010280 1.019777 0.004356
+v -0.011380 1.015275 0.007170
+v -0.011752 1.010594 0.008120
+v -0.011380 1.005913 0.007170
+v -0.010280 1.001411 0.004356
+v -0.008494 0.997263 -0.000214
+v -0.006089 0.993627 -0.006364
+v -0.003159 0.990643 -0.013858
+v 0.000183 0.988425 -0.022408
+v 0.003810 0.987060 -0.031685
+v 0.000183 1.034128 -0.032245
+v -0.006931 1.032763 -0.023506
+v -0.013488 1.030545 -0.015452
+v -0.019235 1.027561 -0.008393
+v -0.023951 1.023925 -0.002600
+v -0.027456 1.019777 0.001705
+v -0.029614 1.015275 0.004356
+v -0.030343 1.010594 0.005251
+v -0.029614 1.005913 0.004356
+v -0.027456 1.001411 0.001705
+v -0.023951 0.997263 -0.002600
+v -0.019235 0.993627 -0.008393
+v -0.013488 0.990643 -0.015452
+v -0.006931 0.988425 -0.023506
+v 0.000183 0.987060 -0.032245
+v -0.003159 1.034128 -0.033154
+v -0.013488 1.032763 -0.025289
+v -0.023007 1.030545 -0.018041
+v -0.031350 1.027561 -0.011688
+v -0.038197 1.023925 -0.006474
+v -0.043285 1.019777 -0.002600
+v -0.046418 1.015275 -0.000214
+v -0.047476 1.010594 0.000591
+v -0.046418 1.005913 -0.000214
+v -0.043285 1.001411 -0.002600
+v -0.038197 0.997263 -0.006474
+v -0.031350 0.993627 -0.011688
+v -0.023007 0.990643 -0.018041
+v -0.013488 0.988425 -0.025289
+v -0.003159 0.987060 -0.033154
+v -0.006089 1.034128 -0.034377
+v -0.019235 1.032763 -0.027689
+v -0.031350 1.030545 -0.021525
+v -0.041969 1.027561 -0.016122
+v -0.050684 1.023925 -0.011688
+v -0.057159 1.019777 -0.008393
+v -0.061147 1.015275 -0.006364
+v -0.062494 1.010594 -0.005679
+v -0.061147 1.005913 -0.006364
+v -0.057159 1.001411 -0.008393
+v -0.050684 0.997263 -0.011688
+v -0.041969 0.993627 -0.016122
+v -0.031350 0.990643 -0.021525
+v -0.019235 0.988425 -0.027689
+v -0.006089 0.987060 -0.034377
+v -0.008494 1.034128 -0.035867
+v -0.023951 1.032763 -0.030613
+v -0.038197 1.030545 -0.025770
+v -0.050684 1.027561 -0.021525
+v -0.060931 1.023925 -0.018041
+v -0.068546 1.019777 -0.015452
+v -0.073235 1.015275 -0.013858
+v -0.074818 1.010594 -0.013320
+v -0.073235 1.005913 -0.013858
+v -0.068546 1.001411 -0.015452
+v -0.060931 0.997263 -0.018041
+v -0.050684 0.993627 -0.021525
+v -0.038197 0.990643 -0.025770
+v -0.023951 0.988425 -0.030613
+v -0.008494 0.987060 -0.035867
+v 0.007582 1.034589 -0.041332
+v -0.010280 1.034128 -0.037568
+v -0.027456 1.032763 -0.033948
+v -0.043285 1.030545 -0.030613
+v -0.057159 1.027561 -0.027689
+v -0.068546 1.023925 -0.025289
+v -0.077007 1.019777 -0.023506
+v -0.082217 1.015275 -0.022408
+v -0.083976 1.010594 -0.022037
+v -0.082217 1.005913 -0.022408
+v -0.077007 1.001411 -0.023506
+v -0.068546 0.997263 -0.025289
+v -0.057159 0.993627 -0.027689
+v -0.043285 0.990643 -0.030613
+v -0.027456 0.988425 -0.033948
+v -0.010280 0.987060 -0.037568
+v -0.011380 1.034128 -0.039413
+v -0.029614 1.032763 -0.037568
+v -0.046418 1.030545 -0.035867
+v -0.061147 1.027561 -0.034377
+v -0.073235 1.023925 -0.033154
+v -0.082217 1.019777 -0.032245
+v -0.087748 1.015275 -0.031685
+v -0.089615 1.010594 -0.031496
+v -0.087748 1.005913 -0.031685
+v -0.082217 1.001411 -0.032245
+v -0.073235 0.997263 -0.033154
+v -0.061147 0.993627 -0.034377
+v -0.046418 0.990643 -0.035867
+v -0.029614 0.988425 -0.037568
+v -0.011380 0.987060 -0.039413
+v -0.009875 1.033703 0.012545
+v -0.028466 1.032337 0.012545
+v -0.045600 1.030120 0.012545
+v -0.060617 1.027136 0.012545
+v -0.072942 1.023500 0.012545
+v -0.082100 1.019351 0.012545
+v -0.087739 1.014850 0.012545
+v -0.089643 1.010168 0.012545
+v -0.087739 1.005487 0.012545
+v -0.082100 1.000986 0.012545
+v -0.072942 0.996837 0.012545
+v -0.060617 0.993201 0.012545
+v -0.045600 0.990217 0.012545
+v -0.028466 0.988000 0.012545
+v -0.009875 0.986634 0.012545
+v -0.009504 1.033703 0.010626
+v -0.027738 1.032337 0.008781
+v -0.044542 1.030120 0.007080
+v -0.059271 1.027136 0.005589
+v -0.071358 1.023500 0.004366
+v -0.080340 1.019351 0.003457
+v -0.085871 1.014850 0.002897
+v -0.087739 1.010168 0.002708
+v -0.085871 1.005487 0.002897
+v -0.080340 1.000986 0.003457
+v -0.071358 0.996837 0.004366
+v -0.059271 0.993201 0.005589
+v -0.044542 0.990217 0.007080
+v -0.027737 0.988000 0.008781
+v -0.009504 0.986634 0.010626
+v -0.008404 1.033703 0.008780
+v -0.025579 1.032337 0.005161
+v -0.041409 1.030120 0.001825
+v -0.055283 1.027136 -0.001099
+v -0.066669 1.023500 -0.003499
+v -0.075130 1.019351 -0.005282
+v -0.080340 1.014850 -0.006380
+v -0.082100 1.010168 -0.006751
+v -0.080340 1.005487 -0.006380
+v -0.075130 1.000986 -0.005282
+v -0.066669 0.996837 -0.003499
+v -0.055283 0.993201 -0.001099
+v -0.041409 0.990217 0.001825
+v -0.025579 0.988000 0.005161
+v -0.008404 0.986634 0.008781
+v -0.006617 1.033703 0.007080
+v -0.022075 1.032337 0.001825
+v -0.036321 1.030120 -0.003018
+v -0.048807 1.027136 -0.007263
+v -0.059055 1.023500 -0.010747
+v -0.066669 1.019351 -0.013335
+v -0.071358 1.014850 -0.014929
+v -0.072942 1.010168 -0.015468
+v -0.071358 1.005487 -0.014929
+v -0.066669 1.000986 -0.013335
+v -0.059055 0.996837 -0.010747
+v -0.048807 0.993201 -0.007263
+v -0.036321 0.990217 -0.003018
+v -0.022075 0.988000 0.001825
+v -0.006617 0.986634 0.007080
+v -0.004213 1.033703 0.005589
+v -0.017358 1.032337 -0.001099
+v -0.029473 1.030120 -0.007263
+v -0.040092 1.027136 -0.012666
+v -0.048807 1.023500 -0.017100
+v -0.055283 1.019351 -0.020394
+v -0.059271 1.014850 -0.022423
+v -0.060617 1.010168 -0.023108
+v -0.059271 1.005487 -0.022423
+v -0.055283 1.000986 -0.020394
+v -0.048807 0.996837 -0.017100
+v -0.040092 0.993201 -0.012666
+v -0.029473 0.990217 -0.007263
+v -0.017358 0.988000 -0.001099
+v -0.004213 0.986634 0.005589
+v -0.001283 1.033703 0.004366
+v -0.011611 1.032337 -0.003499
+v -0.021130 1.030120 -0.010747
+v -0.029473 1.027136 -0.017100
+v -0.036321 1.023500 -0.022313
+v -0.041409 1.019351 -0.026188
+v -0.044542 1.014850 -0.028573
+v -0.045600 1.010168 -0.029379
+v -0.044542 1.005487 -0.028573
+v -0.041409 1.000986 -0.026188
+v -0.036321 0.996837 -0.022313
+v -0.029473 0.993201 -0.017100
+v -0.021130 0.990217 -0.010747
+v -0.011611 0.988000 -0.003499
+v -0.001283 0.986634 0.004366
+v 0.002060 1.033703 0.003457
+v -0.005055 1.032337 -0.005282
+v -0.011611 1.030120 -0.013335
+v -0.017358 1.027136 -0.020394
+v -0.022075 1.023500 -0.026188
+v -0.025579 1.019351 -0.030492
+v -0.027737 1.014850 -0.033143
+v -0.028466 1.010168 -0.034038
+v -0.027737 1.005487 -0.033143
+v -0.025579 1.000986 -0.030492
+v -0.022075 0.996837 -0.026188
+v -0.017358 0.993201 -0.020394
+v -0.011611 0.990217 -0.013335
+v -0.005055 0.988000 -0.005282
+v 0.002060 0.986634 0.003457
+v 0.005687 1.033703 0.002897
+v 0.002060 1.032337 -0.006380
+v -0.001283 1.030120 -0.014929
+v -0.004213 1.027136 -0.022423
+v -0.006617 1.023500 -0.028573
+v -0.008404 1.019351 -0.033143
+v -0.009504 1.014850 -0.035957
+v -0.009875 1.010168 -0.036908
+v -0.009504 1.005487 -0.035957
+v -0.008404 1.000986 -0.033143
+v -0.006617 0.996837 -0.028573
+v -0.004213 0.993201 -0.022423
+v -0.001283 0.990217 -0.014929
+v 0.002060 0.988000 -0.006380
+v 0.005687 0.986634 0.002897
+v 0.009458 1.033703 0.002708
+v 0.009458 1.032337 -0.006751
+v 0.009458 1.030120 -0.015468
+v 0.009458 1.027136 -0.023108
+v 0.009458 1.023500 -0.029379
+v 0.009458 1.019351 -0.034038
+v 0.009458 1.014850 -0.036908
+v 0.009458 1.010168 -0.037876
+v 0.009458 1.005487 -0.036908
+v 0.009458 1.000986 -0.034038
+v 0.009458 0.996837 -0.029379
+v 0.009458 0.993201 -0.023108
+v 0.009458 0.990217 -0.015468
+v 0.009458 0.988000 -0.006751
+v 0.009458 0.986634 0.002708
+v 0.013230 1.033703 0.002897
+v 0.016857 1.032337 -0.006380
+v 0.020200 1.030120 -0.014929
+v 0.023129 1.027136 -0.022423
+v 0.025534 1.023500 -0.028573
+v 0.027320 1.019351 -0.033143
+v 0.028421 1.014850 -0.035957
+v 0.028792 1.010168 -0.036908
+v 0.028421 1.005487 -0.035957
+v 0.027320 1.000986 -0.033143
+v 0.025534 0.996837 -0.028573
+v 0.023129 0.993201 -0.022423
+v 0.020200 0.990217 -0.014929
+v 0.016857 0.988000 -0.006380
+v 0.013230 0.986634 0.002897
+v 0.016857 1.033703 0.003457
+v 0.023971 1.032337 -0.005282
+v 0.030528 1.030120 -0.013335
+v 0.036275 1.027136 -0.020394
+v 0.040992 1.023500 -0.026188
+v 0.044496 1.019351 -0.030492
+v 0.046654 1.014850 -0.033143
+v 0.047383 1.010168 -0.034038
+v 0.046654 1.005487 -0.033143
+v 0.044496 1.000986 -0.030492
+v 0.040992 0.996837 -0.026188
+v 0.036275 0.993201 -0.020394
+v 0.030528 0.990217 -0.013335
+v 0.023971 0.988000 -0.005282
+v 0.016857 0.986634 0.003457
+v 0.020200 1.033703 0.004366
+v 0.030528 1.032337 -0.003499
+v 0.040047 1.030120 -0.010747
+v 0.048390 1.027136 -0.017100
+v 0.055237 1.023500 -0.022313
+v 0.060325 1.019351 -0.026188
+v 0.063458 1.014850 -0.028573
+v 0.064516 1.010168 -0.029379
+v 0.063458 1.005487 -0.028573
+v 0.060325 1.000986 -0.026188
+v 0.055237 0.996837 -0.022313
+v 0.048390 0.993201 -0.017100
+v 0.040047 0.990217 -0.010747
+v 0.030528 0.988000 -0.003499
+v 0.020200 0.986634 0.004366
+v 0.023129 1.033703 0.005589
+v 0.036275 1.032337 -0.001099
+v 0.048390 1.030120 -0.007263
+v 0.059009 1.027136 -0.012666
+v 0.067724 1.023500 -0.017100
+v 0.074200 1.019351 -0.020394
+v 0.078187 1.014850 -0.022423
+v 0.079534 1.010168 -0.023108
+v 0.078187 1.005487 -0.022423
+v 0.074200 1.000986 -0.020394
+v 0.067724 0.996837 -0.017100
+v 0.059009 0.993201 -0.012666
+v 0.048390 0.990217 -0.007263
+v 0.036275 0.988000 -0.001099
+v 0.023129 0.986634 0.005589
+v 0.025534 1.033703 0.007080
+v 0.040992 1.032337 0.001825
+v 0.055237 1.030120 -0.003018
+v 0.067724 1.027136 -0.007263
+v 0.077971 1.023500 -0.010747
+v 0.085586 1.019351 -0.013335
+v 0.090275 1.014850 -0.014929
+v 0.091858 1.010168 -0.015468
+v 0.090275 1.005487 -0.014929
+v 0.085586 1.000986 -0.013335
+v 0.077971 0.996837 -0.010747
+v 0.067724 0.993201 -0.007263
+v 0.055237 0.990217 -0.003018
+v 0.040991 0.988000 0.001825
+v 0.025534 0.986634 0.007080
+v 0.027320 1.033703 0.008781
+v 0.044496 1.032337 0.005161
+v 0.060325 1.030120 0.001825
+v 0.074200 1.027136 -0.001099
+v 0.085586 1.023500 -0.003499
+v 0.094047 1.019351 -0.005282
+v 0.099257 1.014850 -0.006380
+v 0.101016 1.010168 -0.006751
+v 0.099257 1.005487 -0.006380
+v 0.094047 1.000986 -0.005282
+v 0.085586 0.996837 -0.003499
+v 0.074200 0.993201 -0.001099
+v 0.060325 0.990217 0.001825
+v 0.044496 0.988000 0.005161
+v 0.027320 0.986634 0.008781
+v 0.028421 1.033703 0.010626
+v 0.046654 1.032337 0.008781
+v 0.063458 1.030120 0.007080
+v 0.078187 1.027136 0.005589
+v 0.090275 1.023500 0.004366
+v 0.099257 1.019351 0.003457
+v 0.104788 1.014850 0.002897
+v 0.106656 1.010168 0.002708
+v 0.104788 1.005487 0.002897
+v 0.099257 1.000986 0.003457
+v 0.090275 0.996837 0.004366
+v 0.078187 0.993201 0.005589
+v 0.063458 0.990217 0.007080
+v 0.046654 0.988000 0.008781
+v 0.028421 0.986634 0.010626
+v 0.028792 1.033703 0.012545
+v 0.047383 1.032337 0.012545
+v 0.064516 1.030120 0.012545
+v 0.079534 1.027136 0.012545
+v 0.091858 1.023500 0.012545
+v 0.101016 1.019351 0.012545
+v 0.106656 1.014850 0.012545
+v 0.108560 1.010168 0.012545
+v 0.106656 1.005487 0.012545
+v 0.101016 1.000986 0.012545
+v 0.091858 0.996837 0.012545
+v 0.079534 0.993201 0.012545
+v 0.064516 0.990217 0.012545
+v 0.047383 0.988000 0.012545
+v 0.028792 0.986634 0.012545
+v 0.028421 1.033703 0.014464
+v 0.046654 1.032337 0.016309
+v 0.063458 1.030120 0.018010
+v 0.078187 1.027136 0.019500
+v 0.090275 1.023500 0.020724
+v 0.099257 1.019351 0.021633
+v 0.104788 1.014850 0.022193
+v 0.106656 1.010168 0.022382
+v 0.104788 1.005487 0.022193
+v 0.099257 1.000986 0.021633
+v 0.090275 0.996837 0.020724
+v 0.078187 0.993201 0.019500
+v 0.063458 0.990217 0.018010
+v 0.046654 0.988000 0.016309
+v 0.028421 0.986634 0.014464
+v 0.027320 1.033703 0.016309
+v 0.044496 1.032337 0.019929
+v 0.060325 1.030120 0.023265
+v 0.074200 1.027136 0.026189
+v 0.085586 1.023500 0.028588
+v 0.094047 1.019351 0.030371
+v 0.099257 1.014850 0.031469
+v 0.101016 1.010168 0.031840
+v 0.099257 1.005487 0.031469
+v 0.094047 1.000986 0.030371
+v 0.085586 0.996837 0.028588
+v 0.074200 0.993201 0.026189
+v 0.060325 0.990217 0.023265
+v 0.044496 0.988000 0.019929
+v 0.027320 0.986634 0.016309
+v 0.025534 1.033703 0.018010
+v 0.040991 1.032337 0.023265
+v 0.055237 1.030120 0.028108
+v 0.067724 1.027136 0.032353
+v 0.077971 1.023500 0.035836
+v 0.085586 1.019351 0.038425
+v 0.090275 1.014850 0.040019
+v 0.091858 1.010168 0.040557
+v 0.090275 1.005487 0.040019
+v 0.085586 1.000986 0.038425
+v 0.077971 0.996837 0.035836
+v 0.067724 0.993201 0.032353
+v 0.055237 0.990217 0.028108
+v 0.040991 0.988000 0.023265
+v 0.025534 0.986634 0.018010
+v 0.023129 1.033703 0.019500
+v 0.036275 1.032337 0.026189
+v 0.048390 1.030120 0.032353
+v 0.059009 1.027136 0.037755
+v 0.067724 1.023500 0.042189
+v 0.074200 1.019351 0.045484
+v 0.078187 1.014850 0.047513
+v 0.079534 1.010168 0.048198
+v 0.078187 1.005487 0.047513
+v 0.074200 1.000986 0.045484
+v 0.067724 0.996837 0.042189
+v 0.059009 0.993201 0.037755
+v 0.048390 0.990217 0.032353
+v 0.036275 0.988000 0.026189
+v 0.023129 0.986634 0.019500
+v 0.020200 1.033703 0.020724
+v 0.030528 1.032337 0.028588
+v 0.040047 1.030120 0.035836
+v 0.048390 1.027136 0.042189
+v 0.055237 1.023500 0.047403
+v 0.060325 1.019351 0.051277
+v 0.063458 1.014850 0.053663
+v 0.064516 1.010168 0.054469
+v 0.063458 1.005487 0.053663
+v 0.060325 1.000986 0.051277
+v 0.055237 0.996837 0.047403
+v 0.048390 0.993201 0.042189
+v 0.040047 0.990217 0.035836
+v 0.030528 0.988000 0.028588
+v 0.020200 0.986634 0.020724
+v 0.009458 0.986173 0.012545
+v 0.016857 1.033703 0.021633
+v 0.023971 1.032337 0.030371
+v 0.030528 1.030120 0.038425
+v 0.036275 1.027136 0.045484
+v 0.040991 1.023500 0.051277
+v 0.044496 1.019351 0.055582
+v 0.046654 1.014850 0.058233
+v 0.047383 1.010168 0.059128
+v 0.046654 1.005487 0.058233
+v 0.044496 1.000986 0.055582
+v 0.040991 0.996837 0.051277
+v 0.036275 0.993201 0.045484
+v 0.030528 0.990217 0.038425
+v 0.023971 0.988000 0.030371
+v 0.016857 0.986634 0.021633
+v 0.013230 1.033703 0.022193
+v 0.016857 1.032337 0.031469
+v 0.020200 1.030120 0.040019
+v 0.023129 1.027136 0.047513
+v 0.025534 1.023500 0.053663
+v 0.027320 1.019351 0.058233
+v 0.028421 1.014850 0.061047
+v 0.028792 1.010168 0.061997
+v 0.028421 1.005487 0.061047
+v 0.027320 1.000986 0.058233
+v 0.025534 0.996837 0.053663
+v 0.023129 0.993201 0.047513
+v 0.020200 0.990217 0.040019
+v 0.016857 0.988000 0.031469
+v 0.013230 0.986634 0.022193
+v 0.009458 1.033703 0.022382
+v 0.009458 1.032337 0.031840
+v 0.009458 1.030120 0.040557
+v 0.009458 1.027136 0.048198
+v 0.009458 1.023500 0.054469
+v 0.009458 1.019351 0.059128
+v 0.009458 1.014850 0.061997
+v 0.009458 1.010168 0.062966
+v 0.009458 1.005487 0.061997
+v 0.009458 1.000986 0.059128
+v 0.009458 0.996837 0.054469
+v 0.009458 0.993201 0.048198
+v 0.009458 0.990217 0.040557
+v 0.009458 0.988000 0.031840
+v 0.009458 0.986634 0.022382
+v 0.005687 1.033703 0.022193
+v 0.002060 1.032337 0.031469
+v -0.001283 1.030120 0.040019
+v -0.004213 1.027136 0.047513
+v -0.006617 1.023500 0.053663
+v -0.008404 1.019351 0.058233
+v -0.009504 1.014850 0.061047
+v -0.009875 1.010168 0.061997
+v -0.009504 1.005487 0.061047
+v -0.008404 1.000986 0.058233
+v -0.006617 0.996837 0.053663
+v -0.004213 0.993201 0.047513
+v -0.001283 0.990217 0.040019
+v 0.002060 0.988000 0.031469
+v 0.005687 0.986634 0.022193
+v 0.002060 1.033703 0.021633
+v -0.005055 1.032337 0.030371
+v -0.011611 1.030120 0.038425
+v -0.017358 1.027136 0.045484
+v -0.022075 1.023500 0.051277
+v -0.025579 1.019351 0.055582
+v -0.027737 1.014850 0.058233
+v -0.028466 1.010168 0.059128
+v -0.027737 1.005487 0.058233
+v -0.025579 1.000986 0.055582
+v -0.022075 0.996837 0.051277
+v -0.017358 0.993201 0.045484
+v -0.011611 0.990217 0.038425
+v -0.005055 0.988000 0.030371
+v 0.002060 0.986634 0.021633
+v -0.001283 1.033703 0.020724
+v -0.011611 1.032337 0.028588
+v -0.021130 1.030120 0.035836
+v -0.029473 1.027136 0.042189
+v -0.036321 1.023500 0.047403
+v -0.041409 1.019351 0.051277
+v -0.044542 1.014850 0.053663
+v -0.045600 1.010168 0.054468
+v -0.044542 1.005487 0.053663
+v -0.041408 1.000986 0.051277
+v -0.036321 0.996837 0.047403
+v -0.029473 0.993201 0.042189
+v -0.021130 0.990217 0.035836
+v -0.011611 0.988000 0.028588
+v -0.001283 0.986634 0.020724
+v -0.004213 1.033703 0.019500
+v -0.017358 1.032337 0.026189
+v -0.029473 1.030120 0.032353
+v -0.040092 1.027136 0.037755
+v -0.048807 1.023500 0.042189
+v -0.055283 1.019351 0.045484
+v -0.059271 1.014850 0.047513
+v -0.060617 1.010168 0.048198
+v -0.059271 1.005487 0.047513
+v -0.055283 1.000986 0.045484
+v -0.048807 0.996837 0.042189
+v -0.040092 0.993201 0.037755
+v -0.029473 0.990217 0.032353
+v -0.017358 0.988000 0.026189
+v -0.004213 0.986634 0.019500
+v -0.006617 1.033703 0.018010
+v -0.022075 1.032337 0.023265
+v -0.036321 1.030120 0.028108
+v -0.048807 1.027136 0.032353
+v -0.059055 1.023500 0.035836
+v -0.066669 1.019351 0.038425
+v -0.071358 1.014850 0.040019
+v -0.072942 1.010168 0.040557
+v -0.071358 1.005487 0.040019
+v -0.066669 1.000986 0.038425
+v -0.059055 0.996837 0.035836
+v -0.048807 0.993201 0.032353
+v -0.036321 0.990217 0.028108
+v -0.022075 0.988000 0.023265
+v -0.006617 0.986634 0.018010
+v 0.009458 1.034164 0.012545
+v -0.008404 1.033703 0.016309
+v -0.025579 1.032337 0.019929
+v -0.041408 1.030120 0.023265
+v -0.055283 1.027136 0.026189
+v -0.066669 1.023500 0.028588
+v -0.075130 1.019351 0.030371
+v -0.080340 1.014850 0.031469
+v -0.082100 1.010168 0.031840
+v -0.080340 1.005487 0.031469
+v -0.075130 1.000986 0.030371
+v -0.066669 0.996837 0.028588
+v -0.055283 0.993201 0.026189
+v -0.041408 0.990217 0.023265
+v -0.025579 0.988000 0.019929
+v -0.008404 0.986634 0.016309
+v -0.009504 1.033703 0.014464
+v -0.027737 1.032337 0.016309
+v -0.044542 1.030120 0.018010
+v -0.059271 1.027136 0.019500
+v -0.071358 1.023500 0.020724
+v -0.080340 1.019351 0.021633
+v -0.085871 1.014850 0.022193
+v -0.087739 1.010168 0.022382
+v -0.085871 1.005487 0.022192
+v -0.080340 1.000986 0.021633
+v -0.071358 0.996837 0.020724
+v -0.059271 0.993201 0.019500
+v -0.044542 0.990217 0.018010
+v -0.027737 0.988000 0.016309
+v -0.009504 0.986634 0.014464
+vn -0.811518 0.584307 0.000000
+vn -0.533006 0.846095 0.000000
+vn -0.513047 0.834559 -0.200568
+vn -0.104160 0.994537 0.000000
+vn -0.051546 0.998657 0.000031
+vn -0.050203 0.998505 -0.020386
+vn -0.165685 -0.986145 0.000000
+vn -0.244362 -0.969665 0.000000
+vn -0.161748 -0.984710 -0.064211
+vn -1.000000 0.000000 0.000000
+vn -0.767876 0.569903 -0.292459
+vn -0.165685 0.986145 0.000000
+vn -0.101688 0.993957 -0.040651
+vn -0.104160 -0.994537 0.000000
+vn -0.101688 -0.993957 -0.040620
+vn -0.811518 -0.584307 0.000000
+vn -0.767876 -0.569903 -0.292459
+vn -0.244362 0.969665 0.000000
+vn -0.161779 0.984710 -0.064211
+vn -0.051546 -0.998657 0.000000
+vn -0.050203 -0.998505 -0.020417
+vn -0.533006 -0.846095 0.000000
+vn -0.513047 -0.834559 -0.200598
+vn -0.355968 0.934477 0.000000
+vn -0.238197 0.966613 -0.094272
+vn -0.355968 -0.934477 0.000000
+vn -0.345683 -0.928373 -0.136296
+vn -0.345683 0.928373 -0.136296
+vn -0.238197 -0.966613 -0.094241
+vn -0.460768 0.804498 -0.374737
+vn -0.046510 0.998138 -0.039369
+vn -0.150700 -0.980682 -0.124516
+vn -0.937864 0.000000 -0.346965
+vn -0.662038 0.533647 -0.526200
+vn -0.094790 0.992340 -0.078829
+vn -0.094790 -0.992370 -0.078799
+vn -0.662038 -0.533647 -0.526200
+vn -0.150700 0.980682 -0.124516
+vn -0.046510 -0.998138 -0.039369
+vn -0.460738 -0.804498 -0.374737
+vn -0.220954 0.958129 -0.181921
+vn -0.317423 -0.911802 -0.260384
+vn -0.317423 0.911802 -0.260353
+vn -0.220954 -0.958129 -0.181951
+vn -0.276437 -0.888882 -0.365307
+vn -0.276437 0.888882 -0.365307
+vn -0.195044 -0.946013 -0.258797
+vn -0.390362 0.765465 -0.511521
+vn -0.041139 0.997559 -0.056124
+vn -0.133854 -0.974822 -0.178289
+vn -0.789727 0.000000 -0.613422
+vn -0.535539 0.489547 -0.688101
+vn -0.084323 0.989990 -0.113010
+vn -0.084323 -0.989990 -0.112980
+vn -0.535539 -0.489547 -0.688101
+vn -0.133854 0.974822 -0.178259
+vn -0.041139 -0.997559 -0.056124
+vn -0.390362 -0.765435 -0.511521
+vn -0.195044 0.946013 -0.258827
+vn -0.034425 -0.996918 -0.070345
+vn -0.312601 -0.726188 -0.612293
+vn -0.162603 0.932432 -0.322642
+vn -0.227241 -0.864162 -0.448927
+vn -0.227241 0.864162 -0.448927
+vn -0.162603 -0.932432 -0.322642
+vn -0.312601 0.726188 -0.612293
+vn -0.034425 0.996918 -0.070345
+vn -0.112369 -0.968108 -0.223853
+vn -0.620777 0.000000 -0.783959
+vn -0.411817 0.448561 -0.793207
+vn -0.070925 0.987274 -0.142216
+vn -0.070925 -0.987274 -0.142186
+vn -0.411817 -0.448561 -0.793176
+vn -0.112369 0.968108 -0.223853
+vn -0.055177 0.984619 -0.165685
+vn -0.055177 -0.984619 -0.165654
+vn -0.465529 0.000000 -0.885006
+vn -0.297830 -0.415754 -0.859310
+vn -0.087252 0.961608 -0.260109
+vn -0.026673 -0.996277 -0.081698
+vn -0.233192 -0.692373 -0.682791
+vn -0.125462 0.919523 -0.372417
+vn -0.173223 -0.841548 -0.511643
+vn -0.173223 0.841548 -0.511612
+vn -0.125462 -0.919523 -0.372417
+vn -0.233192 0.692373 -0.682791
+vn -0.026673 0.996277 -0.081698
+vn -0.087252 -0.961608 -0.260140
+vn -0.297830 0.415754 -0.859310
+vn -0.154454 0.667013 -0.728843
+vn -0.018159 0.995758 -0.089908
+vn -0.059511 -0.956236 -0.286386
+vn -0.330424 0.000000 -0.943815
+vn -0.193091 0.392499 -0.899228
+vn -0.037690 0.982421 -0.182775
+vn -0.037690 -0.982421 -0.182745
+vn -0.193121 -0.392499 -0.899228
+vn -0.059511 0.956236 -0.286355
+vn -0.018159 -0.995758 -0.089908
+vn -0.154454 -0.667013 -0.728843
+vn -0.085177 0.909055 -0.407819
+vn -0.116550 -0.823725 -0.554826
+vn -0.116550 0.823725 -0.554857
+vn -0.085177 -0.909055 -0.407819
+vn -0.058535 -0.812433 -0.580096
+vn -0.058535 0.812433 -0.580065
+vn -0.043031 -0.902280 -0.428938
+vn -0.076876 0.651418 -0.754784
+vn -0.009156 0.995422 -0.094852
+vn -0.030152 -0.952757 -0.302225
+vn -0.211585 0.000000 -0.977355
+vn -0.094913 0.378796 -0.920560
+vn -0.019105 0.980956 -0.193121
+vn -0.019105 -0.980956 -0.193121
+vn -0.094913 -0.378796 -0.920591
+vn -0.030152 0.952757 -0.302225
+vn -0.009156 -0.995422 -0.094821
+vn -0.076876 -0.651418 -0.754784
+vn -0.043031 0.902280 -0.428938
+vn 0.000000 -0.995331 -0.096469
+vn 0.000000 -0.646168 -0.763176
+vn 0.000000 0.899930 -0.435957
+vn 0.000000 -0.808557 -0.588366
+vn 0.000000 0.808557 -0.588366
+vn 0.000000 -0.899960 -0.435957
+vn 0.000000 0.646168 -0.763176
+vn 0.000000 0.995331 -0.096469
+vn 0.000000 -0.951537 -0.307505
+vn -0.103244 0.000000 -0.994629
+vn 0.000000 0.374279 -0.927305
+vn 0.000000 0.980468 -0.196570
+vn 0.000000 -0.980468 -0.196570
+vn 0.000000 -0.374248 -0.927305
+vn 0.000000 0.951537 -0.307505
+vn 0.030152 -0.952727 -0.302225
+vn 0.000000 0.000000 -0.999969
+vn 0.103244 0.000000 -0.994629
+vn 0.043031 0.902280 -0.428938
+vn 0.019105 -0.980956 -0.193121
+vn 0.094913 -0.378796 -0.920591
+vn 0.058535 0.812433 -0.580065
+vn 0.076876 -0.651418 -0.754784
+vn 0.076876 0.651418 -0.754784
+vn 0.058535 -0.812433 -0.580096
+vn 0.094913 0.378796 -0.920591
+vn 0.019105 0.980956 -0.193121
+vn 0.043031 -0.902280 -0.428938
+vn 0.030152 0.952757 -0.302225
+vn 0.009156 0.995422 -0.094852
+vn 0.037690 0.982421 -0.182775
+vn 0.085177 -0.909055 -0.407819
+vn 0.211585 0.000000 -0.977355
+vn 0.059511 0.956236 -0.286355
+vn 0.059511 -0.956236 -0.286386
+vn 0.085177 0.909055 -0.407819
+vn 0.009156 -0.995422 -0.094821
+vn 0.037690 -0.982421 -0.182745
+vn 0.193121 -0.392499 -0.899228
+vn 0.116550 0.823725 -0.554857
+vn 0.154454 -0.667013 -0.728843
+vn 0.154454 0.667013 -0.728813
+vn 0.116550 -0.823725 -0.554857
+vn 0.193121 0.392499 -0.899228
+vn 0.233192 0.692373 -0.682791
+vn 0.173223 -0.841548 -0.511643
+vn 0.297830 0.415754 -0.859310
+vn 0.018159 0.995758 -0.089908
+vn 0.055177 0.984619 -0.165654
+vn 0.125462 -0.919523 -0.372417
+vn 0.330424 0.000000 -0.943815
+vn 0.087252 0.961608 -0.260109
+vn 0.087252 -0.961608 -0.260109
+vn 0.125462 0.919523 -0.372417
+vn 0.018159 -0.995758 -0.089908
+vn 0.055177 -0.984619 -0.165654
+vn 0.297830 -0.415754 -0.859310
+vn 0.173223 0.841548 -0.511643
+vn 0.233192 -0.692373 -0.682791
+vn 0.411817 -0.448561 -0.793176
+vn 0.227241 0.864162 -0.448927
+vn 0.312601 -0.726188 -0.612262
+vn 0.312601 0.726188 -0.612293
+vn 0.227241 -0.864162 -0.448927
+vn 0.411817 0.448561 -0.793176
+vn 0.026673 0.996277 -0.081698
+vn 0.070925 0.987274 -0.142216
+vn 0.162603 -0.932432 -0.322642
+vn 0.465529 0.000000 -0.885006
+vn 0.112369 0.968108 -0.223853
+vn 0.112369 -0.968108 -0.223853
+vn 0.162603 0.932432 -0.322642
+vn 0.026673 -0.996277 -0.081668
+vn 0.070925 -0.987274 -0.142216
+vn 0.133854 -0.974822 -0.178289
+vn 0.620777 0.000000 -0.783959
+vn 0.195044 0.946013 -0.258797
+vn 0.034425 -0.996918 -0.070345
+vn 0.084323 -0.989990 -0.112980
+vn 0.535539 -0.489547 -0.688101
+vn 0.276437 0.888882 -0.365307
+vn 0.390362 -0.765465 -0.511521
+vn 0.390362 0.765465 -0.511521
+vn 0.276437 -0.888882 -0.365307
+vn 0.535539 0.489547 -0.688101
+vn 0.034425 0.996918 -0.070376
+vn 0.084323 0.989990 -0.113010
+vn 0.195044 -0.946013 -0.258797
+vn 0.133854 0.974822 -0.178259
+vn 0.041139 0.997559 -0.056124
+vn 0.094790 0.992370 -0.078799
+vn 0.220954 -0.958129 -0.181921
+vn 0.789727 0.000000 -0.613422
+vn 0.150700 0.980682 -0.124516
+vn 0.150700 -0.980682 -0.124546
+vn 0.220954 0.958129 -0.181921
+vn 0.041139 -0.997559 -0.056124
+vn 0.094790 -0.992370 -0.078799
+vn 0.662038 -0.533647 -0.526200
+vn 0.317423 0.911802 -0.260353
+vn 0.460738 -0.804498 -0.374737
+vn 0.460768 0.804498 -0.374737
+vn 0.317423 -0.911802 -0.260384
+vn 0.662038 0.533647 -0.526200
+vn 0.513047 0.834559 -0.200568
+vn 0.345683 -0.928373 -0.136296
+vn 0.767876 0.569903 -0.292459
+vn 0.046510 0.998138 -0.039399
+vn 0.101688 0.993957 -0.040620
+vn 0.238197 -0.966613 -0.094241
+vn 0.937864 0.000000 -0.346965
+vn 0.161779 0.984710 -0.064241
+vn 0.161748 -0.984710 -0.064241
+vn 0.238197 0.966613 -0.094241
+vn 0.046510 -0.998138 -0.039369
+vn 0.101688 -0.993957 -0.040620
+vn 0.767876 -0.569903 -0.292459
+vn 0.345683 0.928373 -0.136296
+vn 0.513047 -0.834559 -0.200598
+vn 0.811518 -0.584307 0.000000
+vn 0.355968 0.934477 0.000000
+vn 0.533006 -0.846065 0.000000
+vn 0.533006 0.846095 0.000000
+vn 0.355968 -0.934477 0.000000
+vn 0.811518 0.584307 0.000000
+vn 0.050203 0.998505 -0.020447
+vn 0.104160 0.994537 0.000000
+vn 0.244362 -0.969665 0.000000
+vn 0.165685 0.986145 0.000000
+vn 0.165685 -0.986145 0.000000
+vn 0.244362 0.969665 0.000000
+vn 0.050203 -0.998505 -0.020417
+vn 0.104160 -0.994537 0.000000
+vn 0.101688 -0.993957 0.040620
+vn 0.767876 -0.569903 0.292459
+vn 0.161779 0.984710 0.064241
+vn 0.051546 -0.998657 0.000000
+vn 0.050203 -0.998505 0.020417
+vn 0.513047 -0.834559 0.200598
+vn 0.238197 0.966613 0.094241
+vn 0.345683 -0.928373 0.136296
+vn 0.345683 0.928373 0.136296
+vn 0.238197 -0.966613 0.094241
+vn 0.513047 0.834559 0.200568
+vn 0.051546 0.998657 0.000000
+vn 0.050203 0.998505 0.020386
+vn 0.161748 -0.984710 0.064211
+vn 0.767876 0.569903 0.292459
+vn 0.101688 0.993957 0.040620
+vn 0.150700 -0.980682 0.124516
+vn 0.937864 0.000000 0.346965
+vn 0.662038 0.533647 0.526200
+vn 0.094790 0.992340 0.078829
+vn 0.094790 -0.992370 0.078799
+vn 0.662038 -0.533647 0.526200
+vn 0.150700 0.980682 0.124516
+vn 0.046510 -0.998138 0.039369
+vn 0.460738 -0.804498 0.374737
+vn 0.220954 0.958129 0.181951
+vn 0.317423 -0.911802 0.260384
+vn 0.317423 0.911802 0.260384
+vn 0.220954 -0.958129 0.181951
+vn 0.460768 0.804498 0.374737
+vn 0.046510 0.998138 0.039369
+vn 0.195044 -0.946013 0.258797
+vn 0.390362 0.765465 0.511521
+vn 0.041139 0.997559 0.056124
+vn 0.133854 -0.974822 0.178289
+vn 0.789727 0.000000 0.613422
+vn 0.535539 0.489547 0.688101
+vn 0.084323 0.989990 0.113010
+vn 0.084323 -0.989990 0.112980
+vn 0.535539 -0.489547 0.688101
+vn 0.133854 0.974822 0.178259
+vn 0.041139 -0.997559 0.056124
+vn 0.390362 -0.765465 0.511521
+vn 0.195044 0.946013 0.258797
+vn 0.276437 -0.888882 0.365307
+vn 0.276437 0.888882 0.365307
+vn 0.162603 0.932432 0.322642
+vn 0.227241 -0.864162 0.448927
+vn 0.227241 0.864162 0.448927
+vn 0.162603 -0.932432 0.322642
+vn 0.312601 0.726188 0.612293
+vn 0.034425 0.996918 0.070345
+vn 0.112369 -0.968108 0.223884
+vn 0.620777 0.000000 0.783959
+vn 0.411817 0.448561 0.793176
+vn 0.070925 0.987274 0.142216
+vn 0.070925 -0.987274 0.142186
+vn 0.411817 -0.448561 0.793176
+vn 0.112369 0.968108 0.223853
+vn 0.034425 -0.996918 0.070345
+vn 0.312601 -0.726188 0.612293
+vn 0.465529 0.000000 0.885006
+vn 0.297830 -0.415754 0.859310
+vn 0.087252 0.961608 0.260109
+vn 0.026673 -0.996277 0.081668
+vn 0.233192 -0.692373 0.682791
+vn 0.125462 0.919523 0.372417
+vn 0.173223 -0.841548 0.511643
+vn 0.173223 0.841517 0.511643
+vn 0.125462 -0.919523 0.372417
+vn 0.233192 0.692373 0.682791
+vn 0.026673 0.996277 0.081698
+vn 0.087252 -0.961608 0.260109
+vn 0.297830 0.415723 0.859310
+vn 0.055177 0.984619 0.165685
+vn 0.055177 -0.984619 0.165654
+vn 0.059511 -0.956236 0.286386
+vn 0.330393 0.000000 0.943815
+vn 0.193121 0.392499 0.899228
+vn 0.037690 0.982421 0.182775
+vn 0.037690 -0.982421 0.182775
+vn 0.193121 -0.392499 0.899228
+vn 0.059511 0.956236 0.286386
+vn 0.018159 -0.995758 0.089877
+vn 0.154454 -0.667013 0.728843
+vn 0.085177 0.909055 0.407819
+vn 0.116550 -0.823725 0.554826
+vn 0.116550 0.823725 0.554857
+vn 0.085177 -0.909055 0.407819
+vn 0.154454 0.667013 0.728843
+vn 0.018159 0.995758 0.089908
+vn 0.043031 -0.902280 0.428938
+vn 0.076876 0.651418 0.754784
+vn 0.009156 0.995422 0.094852
+vn 0.030152 -0.952757 0.302225
+vn 0.211585 0.000000 0.977355
+vn 0.094913 0.378796 0.920591
+vn 0.019105 0.980956 0.193121
+vn 0.019105 -0.980956 0.193121
+vn 0.094913 -0.378796 0.920591
+vn 0.030152 0.952727 0.302225
+vn 0.009156 -0.995422 0.094821
+vn 0.076876 -0.651418 0.754784
+vn 0.043031 0.902280 0.428938
+vn 0.058535 -0.812433 0.580065
+vn 0.058535 0.812433 0.580096
+vn 0.000000 0.899960 0.435957
+vn 0.000000 -0.808557 0.588366
+vn 0.000000 0.808557 0.588366
+vn 0.000000 -0.899930 0.435957
+vn 0.000000 0.646168 0.763176
+vn 0.000000 0.995331 0.096469
+vn 0.000000 -0.951537 0.307505
+vn 0.103244 0.000000 0.994629
+vn 0.000000 0.374279 0.927305
+vn 0.000000 0.980468 0.196570
+vn 0.000000 -0.980468 0.196570
+vn 0.000000 -0.374279 0.927305
+vn 0.000000 0.951537 0.307505
+vn 0.000000 -0.995331 0.096469
+vn 0.000000 -0.646168 0.763146
+vn 0.000000 0.000000 1.000000
+vn -0.103244 0.000000 0.994629
+vn -0.043031 0.902280 0.428938
+vn -0.019105 -0.980956 0.193121
+vn -0.094913 -0.378796 0.920591
+vn -0.058535 0.812433 0.580096
+vn -0.076876 -0.651418 0.754784
+vn -0.076876 0.651418 0.754784
+vn -0.058535 -0.812433 0.580096
+vn -0.094913 0.378796 0.920591
+vn -0.019105 0.980956 0.193121
+vn -0.043031 -0.902280 0.428938
+vn -0.030152 0.952757 0.302225
+vn -0.030152 -0.952727 0.302225
+vn -0.085177 -0.909055 0.407819
+vn -0.211585 0.000000 0.977355
+vn -0.059511 0.956236 0.286386
+vn -0.059511 -0.956236 0.286386
+vn -0.085177 0.909055 0.407819
+vn -0.009156 -0.995422 0.094821
+vn -0.037690 -0.982421 0.182745
+vn -0.193121 -0.392499 0.899228
+vn -0.116550 0.823725 0.554857
+vn -0.154454 -0.667013 0.728843
+vn -0.154454 0.667013 0.728843
+vn -0.116550 -0.823725 0.554857
+vn -0.193121 0.392499 0.899228
+vn -0.009156 0.995422 0.094852
+vn -0.037690 0.982421 0.182775
+vn -0.173223 -0.841548 0.511643
+vn -0.297830 0.415723 0.859310
+vn -0.018159 0.995758 0.089908
+vn -0.055177 0.984619 0.165685
+vn -0.125462 -0.919523 0.372417
+vn -0.330424 0.000000 0.943815
+vn -0.087252 0.961608 0.260109
+vn -0.087252 -0.961608 0.260109
+vn -0.125462 0.919523 0.372417
+vn -0.018159 -0.995758 0.089908
+vn -0.055177 -0.984619 0.165654
+vn -0.297830 -0.415754 0.859310
+vn -0.173223 0.841548 0.511643
+vn -0.233192 -0.692373 0.682760
+vn -0.233192 0.692373 0.682791
+vn -0.312601 -0.726188 0.612262
+vn -0.312601 0.726188 0.612293
+vn -0.227241 -0.864162 0.448927
+vn -0.411817 0.448561 0.793176
+vn -0.026673 0.996277 0.081698
+vn -0.070925 0.987274 0.142216
+vn -0.162603 -0.932432 0.322642
+vn -0.465529 0.000000 0.885006
+vn -0.112369 0.968108 0.223853
+vn -0.112369 -0.968108 0.223884
+vn -0.162603 0.932432 0.322642
+vn -0.026673 -0.996277 0.081698
+vn -0.070925 -0.987274 0.142247
+vn -0.411817 -0.448561 0.793176
+vn -0.227241 0.864162 0.448927
+vn -0.195044 0.946013 0.258797
+vn -0.034425 -0.996918 0.070345
+vn -0.084323 -0.989990 0.112980
+vn -0.535539 -0.489547 0.688101
+vn -0.276437 0.888882 0.365307
+vn -0.390362 -0.765465 0.511521
+vn -0.390362 0.765435 0.511521
+vn -0.276437 -0.888882 0.365307
+vn -0.535539 0.489547 0.688101
+vn -0.034425 0.996918 0.070345
+vn -0.084323 0.989990 0.113010
+vn -0.195044 -0.946013 0.258797
+vn -0.620777 0.000000 0.783959
+vn -0.133854 0.974822 0.178259
+vn -0.133854 -0.974822 0.178289
+vn -0.789727 0.000000 0.613422
+vn -0.150700 0.980682 0.124516
+vn -0.150700 -0.980682 0.124516
+vn -0.220954 0.958129 0.181921
+vn -0.041139 -0.997559 0.056124
+vn -0.094790 -0.992370 0.078799
+vn -0.662038 -0.533647 0.526200
+vn -0.317423 0.911802 0.260353
+vn -0.460738 -0.804498 0.374737
+vn -0.460738 0.804498 0.374737
+vn -0.317423 -0.911802 0.260384
+vn -0.662038 0.533647 0.526200
+vn -0.041139 0.997559 0.056093
+vn -0.094790 0.992370 0.078799
+vn -0.220954 -0.958129 0.181951
+vn -0.345683 -0.928373 0.136296
+vn -0.767876 0.569903 0.292459
+vn -0.046510 0.998138 0.039369
+vn -0.101688 0.993957 0.040620
+vn -0.238197 -0.966613 0.094241
+vn -0.937864 0.000000 0.346965
+vn -0.161779 0.984710 0.064241
+vn -0.161748 -0.984710 0.064211
+vn -0.238197 0.966613 0.094272
+vn -0.046510 -0.998138 0.039369
+vn -0.101688 -0.993957 0.040620
+vn -0.767876 -0.569903 0.292459
+vn -0.345683 0.928373 0.136296
+vn -0.513047 -0.834559 0.200568
+vn -0.513047 0.834559 0.200598
+vn -0.050203 -0.998505 0.020417
+vn -0.050203 0.998505 0.020447
+vn -0.513047 0.834559 -0.200598
+vn -0.051546 0.998657 0.000000
+vn -0.050203 0.998505 -0.020417
+vn -0.101688 -0.993957 -0.040651
+vn -0.161779 0.984710 -0.064241
+vn -0.050203 -0.998505 -0.020447
+vn -0.513047 -0.834559 -0.200568
+vn -0.460738 0.804498 -0.374737
+vn -0.094790 0.992370 -0.078799
+vn -0.220954 0.958129 -0.181951
+vn -0.317423 0.911802 -0.260384
+vn -0.220954 -0.958129 -0.181921
+vn -0.041139 0.997559 -0.056154
+vn -0.133854 -0.974822 -0.178259
+vn -0.390362 -0.765465 -0.511521
+vn -0.195044 0.946013 -0.258797
+vn -0.034425 -0.996918 -0.070376
+vn -0.312601 -0.726188 -0.612262
+vn -0.162603 -0.932432 -0.322672
+vn -0.312601 0.726188 -0.612262
+vn -0.034425 0.996918 -0.070376
+vn -0.411817 0.448561 -0.793176
+vn -0.070925 -0.987274 -0.142216
+vn -0.055177 0.984619 -0.165654
+vn -0.297830 -0.415723 -0.859310
+vn -0.173223 0.841548 -0.511643
+vn -0.087252 -0.961608 -0.260109
+vn -0.297830 0.415723 -0.859310
+vn -0.330393 0.000000 -0.943815
+vn -0.193121 0.392499 -0.899228
+vn -0.059511 0.956236 -0.286386
+vn -0.018159 -0.995758 -0.089938
+vn -0.154454 -0.667013 -0.728813
+vn -0.116550 0.823725 -0.554826
+vn -0.009156 0.995422 -0.094821
+vn -0.211554 0.000000 -0.977355
+vn -0.094913 0.378796 -0.920591
+vn -0.019105 -0.980987 -0.193121
+vn -0.030152 0.952757 -0.302194
+vn 0.000000 -0.646168 -0.763146
+vn 0.000000 0.646168 -0.763146
+vn 0.000000 -0.374279 -0.927305
+vn 0.030152 -0.952757 -0.302225
+vn 0.019105 -0.980987 -0.193121
+vn 0.058535 0.812433 -0.580096
+vn 0.059511 0.956236 -0.286386
+vn 0.154454 -0.667013 -0.728813
+vn 0.154454 0.667013 -0.728843
+vn 0.116550 -0.823725 -0.554826
+vn 0.297830 0.415723 -0.859310
+vn 0.087252 -0.961608 -0.260140
+vn 0.297830 -0.415723 -0.859310
+vn 0.312601 -0.726188 -0.612293
+vn 0.026673 -0.996277 -0.081698
+vn 0.133854 -0.974822 -0.178259
+vn 0.195044 0.946013 -0.258827
+vn 0.034425 -0.996918 -0.070376
+vn 0.276437 0.888852 -0.365307
+vn 0.535539 0.489547 -0.688131
+vn 0.034425 0.996918 -0.070345
+vn 0.084323 0.989990 -0.112980
+vn 0.041139 0.997559 -0.056154
+vn 0.220954 -0.958129 -0.181951
+vn 0.150700 -0.980682 -0.124516
+vn 0.317423 0.911802 -0.260384
+vn 0.046510 0.998138 -0.039369
+vn 0.101688 0.993957 -0.040651
+vn 0.161748 -0.984710 -0.064211
+vn 0.513047 -0.834559 -0.200568
+vn 0.533006 0.846065 0.000000
+vn 0.050203 0.998505 -0.020417
+vn 0.050203 -0.998505 -0.020447
+vn 0.101688 -0.993957 0.040651
+vn 0.050203 -0.998505 0.020447
+vn 0.513047 -0.834559 0.200568
+vn 0.513047 0.834559 0.200598
+vn 0.050203 0.998505 0.020417
+vn 0.101688 0.993957 0.040651
+vn 0.662038 0.533647 0.526231
+vn 0.094790 0.992370 0.078799
+vn 0.220954 -0.958129 0.181921
+vn 0.460738 0.804498 0.374737
+vn 0.046510 0.998138 0.039399
+vn 0.041139 0.997559 0.056154
+vn 0.133854 -0.974822 0.178259
+vn 0.133854 0.974822 0.178289
+vn 0.195044 0.946013 0.258827
+vn 0.312601 0.726188 0.612262
+vn 0.112369 -0.968108 0.223853
+vn 0.411817 0.448561 0.793207
+vn 0.070925 -0.987274 0.142216
+vn 0.034425 -0.996918 0.070376
+vn 0.312601 -0.726188 0.612262
+vn 0.297830 -0.415723 0.859310
+vn 0.026673 -0.996277 0.081698
+vn 0.173223 0.841548 0.511643
+vn 0.087252 -0.961608 0.260140
+vn 0.055177 0.984619 0.165654
+vn 0.059511 -0.956236 0.286355
+vn 0.018159 -0.995758 0.089908
+vn 0.154454 -0.667013 0.728813
+vn 0.116550 -0.823725 0.554857
+vn 0.116550 0.823725 0.554826
+vn 0.043031 -0.902280 0.428968
+vn 0.030152 0.952757 0.302225
+vn 0.058535 -0.812433 0.580096
+vn 0.000000 -0.899960 0.435957
+vn 0.000000 0.646168 0.763146
+vn -0.058535 0.812433 0.580065
+vn -0.030152 -0.952757 0.302225
+vn -0.059511 0.956236 0.286355
+vn -0.116550 0.823725 0.554826
+vn -0.154454 -0.667013 0.728813
+vn -0.173223 -0.841548 0.511612
+vn -0.018159 0.995758 0.089877
+vn -0.330393 0.000000 0.943815
+vn -0.087252 -0.961608 0.260140
+vn -0.297830 -0.415723 0.859310
+vn -0.233192 -0.692373 0.682791
+vn -0.312601 -0.726188 0.612293
+vn -0.026673 0.996277 0.081668
+vn -0.162603 -0.932432 0.322672
+vn -0.112369 -0.968108 0.223853
+vn -0.070925 -0.987274 0.142216
+vn -0.195044 0.946013 0.258827
+vn -0.034425 -0.996918 0.070315
+vn -0.390362 0.765465 0.511521
+vn -0.084323 0.989990 0.112980
+vn -0.133854 0.974822 0.178289
+vn -0.133854 -0.974822 0.178259
+vn -0.150700 0.980682 0.124546
+vn -0.220954 0.958129 0.181951
+vn -0.317454 -0.911802 0.260353
+vn -0.041139 0.997559 0.056124
+vn -0.046510 0.998138 0.039399
+vn -0.101688 0.993957 0.040651
+vn -0.238197 -0.966613 0.094272
+vn -0.238197 0.966613 0.094241
+vn -0.513047 -0.834559 0.200598
+vn -0.050203 -0.998505 0.020447
+vn -0.050203 0.998505 0.020417
+usemtl Tooth
+s 1
+f 4345//2909 4344//2910 4359//2911
+f 4340//2912 4339//2913 4354//2914
+f 4351//2915 4350//2916 4366//2917
+f 4346//2918 4345//2909 4360//2919
+f 4341//2920 4340//2912 4355//2921
+f 4352//2922 4351//2915 4367//2923
+f 4347//2924 4346//2918 4362//2925
+f 4342//2926 4341//2920 4356//2927
+f 4353//2928 4352//2922 4368//2929
+f 4348//2930 4347//2924 4363//2931
+f 4343//2932 4342//2926 4357//2933
+f 4349//2934 4348//2930 4364//2935
+f 4344//2910 4343//2932 4358//2936
+f 4350//2916 4349//2934 4365//2937
+f 4360//2919 4359//2911 4374//2938
+f 4355//2921 4354//2914 4369//2939
+f 4366//2917 4365//2937 4381//2940
+f 4361//2941 4360//2919 4375//2942
+f 4356//2927 4355//2921 4370//2943
+f 4367//2923 4366//2917 4382//2944
+f 4362//2925 4361//2941 4377//2945
+f 4357//2933 4356//2927 4371//2946
+f 4368//2929 4367//2923 4383//2947
+f 4363//2931 4362//2925 4378//2948
+f 4358//2936 4357//2933 4372//2949
+f 4364//2935 4363//2931 4379//2950
+f 4359//2911 4358//2936 4373//2951
+f 4365//2937 4364//2935 4380//2952
+f 4379//2950 4378//2948 4394//2953
+f 4374//2938 4373//2951 4388//2954
+f 4380//2952 4379//2950 4395//2955
+f 4375//2942 4374//2938 4389//2956
+f 4370//2943 4369//2939 4384//2957
+f 4381//2940 4380//2952 4396//2958
+f 4376//2959 4375//2942 4390//2960
+f 4371//2946 4370//2943 4385//2961
+f 4382//2944 4381//2940 4397//2962
+f 4377//2945 4376//2959 4392//2963
+f 4372//2949 4371//2946 4386//2964
+f 4383//2947 4382//2944 4398//2965
+f 4378//2948 4377//2945 4393//2966
+f 4373//2951 4372//2949 4387//2967
+f 4398//2965 4397//2962 4413//2968
+f 4393//2966 4392//2963 4408//2969
+f 4388//2954 4387//2967 4402//2970
+f 4394//2953 4393//2966 4409//2971
+f 4389//2956 4388//2954 4403//2972
+f 4395//2955 4394//2953 4410//2973
+f 4390//2960 4389//2956 4404//2974
+f 4385//2961 4384//2957 4399//2975
+f 4396//2958 4395//2955 4411//2976
+f 4391//2977 4390//2960 4405//2978
+f 4386//2964 4385//2961 4400//2979
+f 4397//2962 4396//2958 4412//2980
+f 4392//2963 4391//2977 4407//2981
+f 4387//2967 4386//2964 4401//2982
+f 4401//2982 4400//2979 4415//2983
+f 4412//2980 4411//2976 4427//2984
+f 4407//2981 4406//2985 4422//2986
+f 4402//2970 4401//2982 4416//2987
+f 4413//2968 4412//2980 4428//2988
+f 4408//2969 4407//2981 4423//2989
+f 4403//2972 4402//2970 4417//2990
+f 4409//2971 4408//2969 4424//2991
+f 4404//2974 4403//2972 4418//2992
+f 4410//2973 4409//2971 4425//2993
+f 4405//2978 4404//2974 4419//2994
+f 4400//2979 4399//2975 4414//2995
+f 4411//2976 4410//2973 4426//2996
+f 4406//2985 4405//2978 4420//2997
+f 4420//2997 4419//2994 4434//2998
+f 4415//2983 4414//2995 4429//2999
+f 4426//2996 4425//2993 4441//3000
+f 4421//3001 4420//2997 4435//3002
+f 4416//2987 4415//2983 4430//3003
+f 4427//2984 4426//2996 4442//3004
+f 4422//2986 4421//3001 4437//3005
+f 4417//2990 4416//2987 4431//3006
+f 4428//2988 4427//2984 4443//3007
+f 4423//2989 4422//2986 4438//3008
+f 4418//2992 4417//2990 4432//3009
+f 4424//2991 4423//2989 4439//3010
+f 4419//2994 4418//2992 4433//3011
+f 4425//2993 4424//2991 4440//3012
+f 4439//3010 4438//3008 4454//3013
+f 4434//2998 4433//3011 4448//3014
+f 4440//3012 4439//3010 4455//3015
+f 4435//3002 4434//2998 4449//3016
+f 4430//3003 4429//2999 4444//3017
+f 4441//3000 4440//3012 4456//3018
+f 4436//3019 4435//3002 4450//3020
+f 4431//3006 4430//3003 4445//3021
+f 4442//3004 4441//3000 4457//3022
+f 4437//3005 4436//3019 4452//3023
+f 4432//3009 4431//3006 4446//3024
+f 4443//3007 4442//3004 4458//3025
+f 4438//3008 4437//3005 4453//3026
+f 4433//3011 4432//3009 4447//3027
+f 4458//3025 4457//3022 4473//3028
+f 4453//3026 4452//3023 4468//3029
+f 4448//3014 4447//3027 4462//3030
+f 4454//3013 4453//3026 4469//3031
+f 4449//3016 4448//3014 4463//3032
+f 4455//3015 4454//3013 4470//3033
+f 4450//3020 4449//3016 4464//3034
+f 4445//3021 4444//3017 4459//3035
+f 4456//3018 4455//3015 4471//3036
+f 4451//3037 4450//3020 4465//3038
+f 4446//3024 4445//3021 4460//3039
+f 4457//3022 4456//3018 4472//3040
+f 4452//3023 4451//3037 4467//3041
+f 4447//3027 4446//3024 4461//3042
+f 4472//3040 4471//3036 4486//3043
+f 4467//3041 4466//3044 4481//3045
+f 4462//3030 4461//3042 4477//3046
+f 4473//3028 4472//3040 4487//3047
+f 4468//3029 4467//3041 4482//3048
+f 4463//3032 4462//3030 4478//3049
+f 4469//3031 4468//3029 4483//3050
+f 4464//3034 4463//3032 4479//3051
+f 4470//3033 4469//3031 4484//3052
+f 4465//3038 4464//3034 4480//3053
+f 4460//3039 4459//3035 4475//3054
+f 4471//3036 4470//3033 4485//3055
+f 4466//3044 4465//3038 4481//3045
+f 4461//3042 4460//3039 4476//3056
+f 4475//3054 4474//3057 4490//3058
+f 4486//3043 4485//3055 4500//3059
+f 4481//3045 4480//3053 4496//3060
+f 4476//3056 4475//3054 4491//3061
+f 4487//3047 4486//3043 4501//3062
+f 4482//3048 4481//3045 4496//3060
+f 4477//3046 4476//3056 4492//3063
+f 4488//3064 4487//3047 4502//3065
+f 4483//3050 4482//3048 4497//3066
+f 4478//3049 4477//3046 4493//3067
+f 4484//3052 4483//3050 4498//3068
+f 4479//3051 4478//3049 4494//3069
+f 4485//3055 4484//3052 4499//3070
+f 4480//3053 4479//3051 4495//3071
+f 4494//3069 4493//3067 4509//3072
+f 4500//3059 4499//3070 4514//3073
+f 4495//3071 4494//3069 4510//3074
+f 4490//3058 4489//3075 4505//3076
+f 4501//3062 4500//3059 4515//3077
+f 4496//3060 4495//3071 4511//3078
+f 4491//3061 4490//3058 4506//3079
+f 4502//3065 4501//3062 4516//3080
+f 4497//3066 4496//3060 4511//3078
+f 4492//3063 4491//3061 4507//3081
+f 4503//3082 4502//3065 4517//3083
+f 4498//3068 4497//3066 4512//3084
+f 4493//3067 4492//3063 4508//3085
+f 4499//3070 4498//3068 4513//3086
+f 4513//3086 4512//3084 4527//3087
+f 4508//3085 4507//3081 4523//3088
+f 4514//3073 4513//3086 4528//3089
+f 4509//3072 4508//3085 4524//3090
+f 4515//3077 4514//3073 4529//3091
+f 4510//3074 4509//3072 4525//3092
+f 4505//3076 4504//3093 4520//3094
+f 4516//3080 4515//3077 4530//3095
+f 4511//3078 4510//3074 4526//3096
+f 4506//3079 4505//3076 4521//3097
+f 4517//3083 4516//3080 4531//3098
+f 4512//3084 4511//3078 4526//3096
+f 4507//3081 4506//3079 4522//3099
+f 4518//3100 4517//3083 4532//3101
+f 4532//3101 4531//3098 4546//3102
+f 4527//3087 4526//3096 4541//3103
+f 4522//3099 4521//3097 4537//3104
+f 4533//3105 4532//3101 4547//3106
+f 4528//3089 4527//3087 4542//3107
+f 4523//3088 4522//3099 4538//3108
+f 4529//3091 4528//3089 4543//3109
+f 4524//3090 4523//3088 4539//3110
+f 4530//3095 4529//3091 4544//3111
+f 4525//3092 4524//3090 4540//3112
+f 4520//3094 4519//3113 4535//3114
+f 4531//3098 4530//3095 4545//3115
+f 4526//3096 4525//3092 4541//3103
+f 4521//3097 4520//3094 4536//3116
+f 4535//3114 4534//3117 4550//3118
+f 4546//3102 4545//3115 4560//3119
+f 4541//3103 4540//3112 4556//3120
+f 4536//3116 4535//3114 4551//3121
+f 4547//3106 4546//3102 4561//3122
+f 4542//3107 4541//3103 4556//3120
+f 4537//3104 4536//3116 4552//3123
+f 4548//3124 4547//3106 4562//3125
+f 4543//3109 4542//3107 4557//3126
+f 4538//3108 4537//3104 4553//3127
+f 4544//3111 4543//3109 4558//3128
+f 4539//3110 4538//3108 4554//3129
+f 4545//3115 4544//3111 4559//3130
+f 4540//3112 4539//3110 4555//3131
+f 4554//3129 4553//3127 4569//3132
+f 4560//3119 4559//3130 4574//3133
+f 4555//3131 4554//3129 4570//3134
+f 4550//3118 4549//3135 4565//3136
+f 4561//3122 4560//3119 4575//3137
+f 4556//3120 4555//3131 4571//3138
+f 4551//3121 4550//3118 4566//3139
+f 4562//3125 4561//3122 4576//3140
+f 4557//3126 4556//3120 4571//3138
+f 4552//3123 4551//3121 4567//3141
+f 4563//3142 4562//3125 4577//3143
+f 4558//3128 4557//3126 4572//3144
+f 4553//3127 4552//3123 4568//3145
+f 4559//3130 4558//3128 4573//3146
+f 4573//3146 4572//3144 4587//3147
+f 4568//3145 4567//3141 4583//3148
+f 4574//3133 4573//3146 4588//3149
+f 4569//3132 4568//3145 4584//3150
+f 4575//3137 4574//3133 4589//3151
+f 4570//3134 4569//3132 4585//3152
+f 4565//3136 4564//3153 4580//3154
+f 4576//3140 4575//3137 4590//3155
+f 4571//3138 4570//3134 4586//261
+f 4566//3139 4565//3136 4581//3156
+f 4577//3143 4576//3140 4591//3157
+f 4572//3144 4571//3138 4586//261
+f 4567//3141 4566//3139 4582//3158
+f 4578//3159 4577//3143 4592//3160
+f 4592//3160 4591//3157 4607//3161
+f 4587//3147 4586//261 4602//3162
+f 4582//3158 4581//3156 4596//3163
+f 4593//3164 4592//3160 4608//3165
+f 4588//3149 4587//3147 4603//3166
+f 4583//3148 4582//3158 4597//3167
+f 4589//3151 4588//3149 4604//3168
+f 4584//3150 4583//3148 4598//3169
+f 4590//3155 4589//3151 4605//3170
+f 4585//3152 4584//3150 4599//3171
+f 4580//3154 4579//3172 4594//3173
+f 4591//3157 4590//3155 4606//3174
+f 4586//261 4585//3152 4600//3175
+f 4581//3156 4580//3154 4595//3176
+f 4606//3174 4605//3170 4621//3177
+f 4601//3178 4600//3175 4615//3179
+f 4596//3163 4595//3176 4610//3180
+f 4607//3161 4606//3174 4622//3181
+f 4602//3162 4601//3178 4617//3182
+f 4597//3167 4596//3163 4611//3183
+f 4608//3165 4607//3161 4623//3184
+f 4603//3166 4602//3162 4618//3185
+f 4598//3169 4597//3167 4612//3186
+f 4604//3168 4603//3166 4619//3187
+f 4599//3171 4598//3169 4613//3188
+f 4605//3170 4604//3168 4620//3189
+f 4600//3175 4599//3171 4614//3190
+f 4595//3176 4594//3173 4609//3191
+f 4620//3189 4619//3187 4635//3192
+f 4615//3179 4614//3190 4629//3193
+f 4610//3180 4609//3191 4624//3194
+f 4621//3177 4620//3189 4636//3195
+f 4616//3196 4615//3179 4630//3197
+f 4611//3183 4610//3180 4625//3198
+f 4622//3181 4621//3177 4637//3199
+f 4617//3182 4616//3196 4632//3200
+f 4612//3186 4611//3183 4626//3201
+f 4623//3184 4622//3181 4638//3202
+f 4618//3185 4617//3182 4633//3203
+f 4613//3188 4612//3186 4627//3204
+f 4619//3187 4618//3185 4634//3205
+f 4614//3190 4613//3188 4628//3206
+f 4628//3206 4627//3204 4642//3207
+f 4634//3205 4633//3203 4649//3208
+f 4629//3193 4628//3206 4643//3209
+f 4635//3192 4634//3205 4650//3210
+f 4630//3197 4629//3193 4644//3211
+f 4625//3198 4624//3194 4639//3212
+f 4636//3195 4635//3192 4651//3213
+f 4631//3214 4630//3197 4645//3215
+f 4626//3201 4625//3198 4640//3216
+f 4637//3199 4636//3195 4652//3217
+f 4632//3200 4631//3214 4647//3218
+f 4627//3204 4626//3201 4641//3219
+f 4638//3202 4637//3199 4653//3220
+f 4633//3203 4632//3200 4648//3221
+f 4647//3218 4646//3222 4662//3223
+f 4642//3207 4641//3219 4656//3224
+f 4653//3220 4652//3217 4668//3225
+f 4648//3221 4647//3218 4663//3226
+f 4643//3209 4642//3207 4657//3227
+f 4649//3208 4648//3221 4664//3228
+f 4644//3211 4643//3209 4658//3229
+f 4650//3210 4649//3208 4665//3230
+f 4645//3215 4644//3211 4659//3231
+f 4640//3216 4639//3212 4654//3232
+f 4651//3213 4650//3210 4666//3233
+f 4646//3222 4645//3215 4660//3234
+f 4641//3219 4640//3216 4655//3235
+f 4652//3217 4651//3213 4667//3236
+f 4666//3233 4665//3230 4682//3237
+f 4661//3238 4660//3234 4676//3239
+f 4656//3224 4655//3235 4671//3240
+f 4667//3236 4666//3233 4683//3241
+f 4662//3223 4661//3238 4678//3242
+f 4657//3227 4656//3224 4672//3243
+f 4668//3225 4667//3236 4684//3244
+f 4663//3226 4662//3223 4679//3245
+f 4658//3229 4657//3227 4673//3246
+f 4664//3228 4663//3226 4680//3247
+f 4659//3231 4658//3229 4674//3248
+f 4665//3230 4664//3228 4681//3249
+f 4660//3234 4659//3231 4675//3250
+f 4655//3235 4654//3232 4670//3251
+f 4681//3249 4680//3247 4696//3252
+f 4676//3239 4675//3250 4690//3253
+f 4671//3240 4670//3251 4685//3254
+f 4682//3237 4681//3249 4697//3255
+f 4677//3256 4676//3239 4691//3257
+f 4672//3243 4671//3240 4686//3258
+f 4683//3241 4682//3237 4698//3259
+f 4678//3242 4677//3256 4693//3260
+f 4673//3246 4672//3243 4687//3261
+f 4684//3244 4683//3241 4699//3262
+f 4679//3245 4678//3242 4694//3263
+f 4674//3248 4673//3246 4688//3264
+f 4680//3247 4679//3245 4695//3265
+f 4675//3250 4674//3248 4689//3266
+f 4689//3266 4688//3264 4703//3267
+f 4695//3265 4694//3263 4710//3268
+f 4690//3253 4689//3266 4704//3269
+f 4696//3252 4695//3265 4711//3270
+f 4691//3257 4690//3253 4705//3271
+f 4686//3258 4685//3254 4700//3272
+f 4697//3255 4696//3252 4712//3273
+f 4692//3274 4691//3257 4706//3275
+f 4687//3261 4686//3258 4701//3276
+f 4698//3259 4697//3255 4713//3277
+f 4693//3260 4692//3274 4708//3278
+f 4688//3264 4687//3261 4702//3279
+f 4699//3262 4698//3259 4714//3280
+f 4694//3263 4693//3260 4709//3281
+f 4708//3278 4707//3282 4722//3283
+f 4703//3267 4702//3279 4718//3284
+f 4714//3280 4713//3277 4728//3285
+f 4709//3281 4708//3278 4723//3286
+f 4704//3269 4703//3267 4719//3287
+f 4710//3268 4709//3281 4724//3288
+f 4705//3271 4704//3269 4720//3289
+f 4711//3270 4710//3268 4725//3290
+f 4706//3275 4705//3271 4721//3291
+f 4701//3276 4700//3272 4716//3292
+f 4712//3273 4711//3270 4726//3293
+f 4707//3282 4706//3275 4722//3283
+f 4702//3279 4701//3276 4717//3294
+f 4713//3277 4712//3273 4727//3295
+f 4727//3295 4726//3293 4741//3296
+f 4722//3283 4721//3291 4737//3297
+f 4717//3294 4716//3292 4732//3298
+f 4728//3285 4727//3295 4742//3299
+f 4723//3286 4722//3283 4737//3297
+f 4718//3284 4717//3294 4733//3300
+f 4729//3301 4728//3285 4743//3302
+f 4724//3288 4723//3286 4738//3303
+f 4719//3287 4718//3284 4734//3304
+f 4725//3290 4724//3288 4739//3305
+f 4720//3289 4719//3287 4735//3306
+f 4726//3293 4725//3290 4740//3307
+f 4721//3291 4720//3289 4736//3308
+f 4716//3292 4715//3309 4731//3310
+f 4741//3296 4740//3307 4755//3311
+f 4736//3308 4735//3306 4751//3312
+f 4731//3310 4730//3313 4746//3314
+f 4742//3299 4741//3296 4756//3315
+f 4737//3297 4736//3308 4752//3316
+f 4732//3298 4731//3310 4747//3317
+f 4743//3302 4742//3299 4757//3318
+f 4738//3303 4737//3297 4752//3316
+f 4733//3300 4732//3298 4748//3319
+f 4744//3320 4743//3302 4758//3321
+f 4739//3305 4738//3303 4753//3322
+f 4734//3304 4733//3300 4749//3323
+f 4740//3307 4739//3305 4754//3324
+f 4735//3306 4734//3304 4750//3325
+f 4755//3311 4754//3324 4769//3326
+f 4750//3325 4749//3323 4765//3327
+f 4756//3315 4755//3311 4770//3328
+f 4751//3312 4750//3325 4766//3329
+f 4746//3314 4745//3330 4761//3331
+f 4757//3318 4756//3315 4771//3332
+f 4752//3316 4751//3312 4767//3333
+f 4747//3317 4746//3314 4762//3334
+f 4758//3321 4757//3318 4772//3335
+f 4753//3322 4752//3316 4767//3333
+f 4748//3319 4747//3317 4763//3336
+f 4759//3337 4758//3321 4773//3338
+f 4754//3324 4753//3322 4768//3339
+f 4749//3323 4748//3319 4764//3340
+f 4763//3336 4762//3334 4778//3341
+f 4774//3342 4773//3338 4788//3343
+f 4769//3326 4768//3339 4783//3344
+f 4764//3340 4763//3336 4779//3345
+f 4770//3328 4769//3326 4784//3346
+f 4765//3327 4764//3340 4780//3347
+f 4771//3332 4770//3328 4785//3348
+f 4766//3329 4765//3327 4781//3349
+f 4761//3331 4760//3350 4776//3351
+f 4772//3335 4771//3332 4786//3352
+f 4767//3333 4766//3329 4782//3353
+f 4762//3334 4761//3331 4777//3354
+f 4773//3338 4772//3335 4787//3355
+f 4768//3339 4767//3333 4782//3353
+f 4782//3353 4781//3349 4798//3356
+f 4777//3354 4776//3351 4793//3357
+f 4788//3343 4787//3355 4803//3358
+f 4783//3344 4782//3353 4798//3356
+f 4778//3341 4777//3354 4794//3359
+f 4789//3360 4788//3343 4804//3361
+f 4784//3346 4783//3344 4799//3362
+f 4779//3345 4778//3341 4795//3363
+f 4785//3348 4784//3346 4800//3364
+f 4780//3347 4779//3345 4796//3365
+f 4786//3352 4785//3348 4801//3366
+f 4781//3349 4780//3347 4797//3367
+f 4776//3351 4775//3368 4792//3369
+f 4787//3355 4786//3352 4802//3370
+f 4802//3370 4801//3366 4816//3371
+f 4797//3367 4796//3365 4812//3372
+f 4792//3369 4791//3373 4807//3374
+f 4803//3358 4802//3370 4817//3375
+f 4798//3356 4797//3367 4813//3376
+f 4793//3357 4792//3369 4808//3377
+f 4804//3361 4803//3358 4818//3378
+f 4799//3362 4798//3356 4813//3376
+f 4794//3359 4793//3357 4809//3379
+f 4805//3380 4804//3361 4819//3381
+f 4800//3364 4799//3362 4814//3382
+f 4795//3363 4794//3359 4810//3383
+f 4801//3366 4800//3364 4815//3384
+f 4796//3365 4795//3363 4811//3385
+f 4669//364 4353//2928 4368//2929
+f 4339//2913 4790//124 4354//2914
+f 4669//364 4368//2929 4383//2947
+f 4354//2914 4790//124 4369//2939
+f 4369//2939 4790//124 4384//2957
+f 4669//364 4383//2947 4398//2965
+f 4669//364 4398//2965 4413//2968
+f 4384//2957 4790//124 4399//2975
+f 4669//364 4413//2968 4428//2988
+f 4399//2975 4790//124 4414//2995
+f 4669//364 4428//2988 4443//3007
+f 4414//2995 4790//124 4429//2999
+f 4429//2999 4790//124 4444//3017
+f 4669//364 4443//3007 4458//3025
+f 4669//364 4458//3025 4473//3028
+f 4444//3017 4790//124 4459//3035
+f 4669//364 4473//3028 4488//3064
+f 4459//3035 4790//124 4474//3057
+f 4669//364 4488//3064 4503//3082
+f 4474//3057 4790//124 4489//3075
+f 4489//3075 4790//124 4504//3093
+f 4669//364 4503//3082 4518//3100
+f 4669//364 4518//3100 4533//3105
+f 4504//3093 4790//124 4519//3113
+f 4669//364 4533//3105 4548//3124
+f 4519//3113 4790//124 4534//3117
+f 4669//364 4548//3124 4563//3142
+f 4534//3117 4790//124 4549//3135
+f 4549//3135 4790//124 4564//3153
+f 4669//364 4563//3142 4578//3159
+f 4669//364 4578//3159 4593//3164
+f 4564//3153 4790//124 4579//3172
+f 4669//364 4593//3164 4608//3165
+f 4579//3172 4790//124 4594//3173
+f 4669//364 4608//3165 4623//3184
+f 4594//3173 4790//124 4609//3191
+f 4609//3191 4790//124 4624//3194
+f 4669//364 4623//3184 4638//3202
+f 4669//364 4638//3202 4653//3220
+f 4624//3194 4790//124 4639//3212
+f 4669//364 4653//3220 4668//3225
+f 4639//3212 4790//124 4654//3232
+f 4669//364 4668//3225 4684//3244
+f 4654//3232 4790//124 4670//3251
+f 4670//3251 4790//124 4685//3254
+f 4669//364 4684//3244 4699//3262
+f 4669//364 4699//3262 4714//3280
+f 4685//3254 4790//124 4700//3272
+f 4669//364 4714//3280 4729//3301
+f 4700//3272 4790//124 4715//3309
+f 4669//364 4729//3301 4744//3320
+f 4715//3309 4790//124 4730//3313
+f 4669//364 4744//3320 4759//3337
+f 4730//3313 4790//124 4745//3330
+f 4669//364 4759//3337 4774//3342
+f 4745//3330 4790//124 4760//3350
+f 4669//364 4774//3342 4789//3360
+f 4760//3350 4790//124 4775//3368
+f 4669//364 4789//3360 4805//3380
+f 4775//3368 4790//124 4791//3373
+f 4669//364 4805//3380 4820//3386
+f 4791//3373 4790//124 4806//3387
+f 4669//364 4820//3386 4353//2928
+f 4816//3371 4815//3384 4348//2930
+f 4811//3385 4810//3383 4344//2910
+f 4806//3387 4790//124 4339//2913
+f 4817//3375 4816//3371 4349//2934
+f 4812//3372 4811//3385 4345//2909
+f 4807//3374 4806//3387 4340//2912
+f 4818//3378 4817//3375 4350//2916
+f 4813//3376 4812//3372 4346//2918
+f 4808//3377 4807//3374 4341//2920
+f 4819//3381 4818//3378 4351//2915
+f 4814//3382 4813//3376 4346//2918
+f 4809//3379 4808//3377 4342//2926
+f 4820//3386 4819//3381 4352//2922
+f 4815//3384 4814//3382 4347//2924
+f 4810//3383 4809//3379 4343//2932
+f 4827//2909 4826//2910 4841//3388
+f 4822//2912 4821//3389 4836//3390
+f 4833//2915 4832//2916 4848//2917
+f 4828//5 4827//2909 4842//2919
+f 4823//2920 4822//2912 4837//2921
+f 4834//2922 4833//2915 4849//3391
+f 4829//2924 4828//5 4844//2925
+f 4824//2926 4823//2920 4838//3392
+f 4835//2928 4834//2922 4850//3393
+f 4830//2930 4829//2924 4845//3394
+f 4825//2932 4824//2926 4839//2933
+f 4831//2934 4830//2930 4846//2935
+f 4826//2910 4825//2932 4840//2936
+f 4832//2916 4831//2934 4847//2937
+f 4842//2919 4841//3388 4856//3395
+f 4837//2921 4836//3390 4851//2939
+f 4848//2917 4847//2937 4863//2940
+f 4843//2941 4842//2919 4857//2942
+f 4838//3392 4837//2921 4852//3396
+f 4849//3391 4848//2917 4864//2944
+f 4844//2925 4843//2941 4859//2945
+f 4839//2933 4838//3392 4853//2946
+f 4850//3393 4849//3391 4865//2947
+f 4845//3394 4844//2925 4860//2948
+f 4840//2936 4839//2933 4854//3397
+f 4846//2935 4845//3394 4861//2950
+f 4841//3388 4840//2936 4855//3398
+f 4847//2937 4846//2935 4862//3399
+f 4861//2950 4860//2948 4876//2953
+f 4856//3395 4855//3398 4870//2954
+f 4862//3399 4861//2950 4877//2955
+f 4857//2942 4856//3395 4871//2956
+f 4852//3396 4851//2939 4866//3400
+f 4863//2940 4862//3399 4878//3401
+f 4858//2959 4857//2942 4872//2960
+f 4853//2946 4852//3396 4867//2961
+f 4864//2944 4863//2940 4879//2962
+f 4859//2945 4858//2959 4874//2963
+f 4854//3397 4853//2946 4868//2964
+f 4865//2947 4864//2944 4880//2965
+f 4860//2948 4859//2945 4875//3402
+f 4855//3398 4854//3397 4869//3403
+f 4880//2965 4879//2962 4895//3404
+f 4875//3402 4874//2963 4890//3405
+f 4870//2954 4869//3403 4884//2970
+f 4876//2953 4875//3402 4891//2971
+f 4871//2956 4870//2954 4885//2972
+f 4877//2955 4876//2953 4892//3406
+f 4872//2960 4871//2956 4886//3407
+f 4867//2961 4866//3400 4881//3408
+f 4878//3401 4877//2955 4893//2976
+f 4873//2977 4872//2960 4887//3409
+f 4868//2964 4867//2961 4882//2979
+f 4879//2962 4878//3401 4894//3410
+f 4874//2963 4873//2977 4889//2981
+f 4869//3403 4868//2964 4883//2982
+f 4883//2982 4882//2979 4897//3411
+f 4894//3410 4893//2976 4909//2984
+f 4889//2981 4888//2985 4904//3412
+f 4884//2970 4883//2982 4898//2987
+f 4895//3404 4894//3410 4910//2988
+f 4890//3405 4889//2981 4905//2989
+f 4885//2972 4884//2970 4899//2990
+f 4891//2971 4890//3405 4906//2991
+f 4886//3407 4885//2972 4900//3413
+f 4892//3406 4891//2971 4907//2993
+f 4887//3409 4886//3407 4901//2994
+f 4882//2979 4881//3408 4896//2995
+f 4893//2976 4892//3406 4908//3414
+f 4888//2985 4887//3409 4902//3415
+f 4902//3415 4901//2994 4916//2998
+f 4897//3411 4896//2995 4911//2999
+f 4908//3414 4907//2993 4923//3000
+f 4903//3416 4902//3415 4917//3417
+f 4898//2987 4897//3411 4912//3003
+f 4909//2984 4908//3414 4924//3004
+f 4904//3412 4903//3416 4919//3005
+f 4899//2990 4898//2987 4913//3418
+f 4910//2988 4909//2984 4925//3419
+f 4905//2989 4904//3412 4920//3420
+f 4900//3413 4899//2990 4914//3009
+f 4906//2991 4905//2989 4921//3010
+f 4901//2994 4900//3413 4915//3421
+f 4907//2993 4906//2991 4922//3012
+f 4921//3010 4920//3420 4936//3013
+f 4916//2998 4915//3421 4930//3014
+f 4922//3012 4921//3010 4937//3015
+f 4917//3417 4916//2998 4931//3016
+f 4912//3003 4911//2999 4926//3422
+f 4923//3000 4922//3012 4938//3018
+f 4918//3423 4917//3417 4932//3424
+f 4913//3418 4912//3003 4927//3021
+f 4924//3004 4923//3000 4939//3425
+f 4919//3005 4918//3423 4934//3023
+f 4914//3009 4913//3418 4928//3426
+f 4925//3419 4924//3004 4940//3025
+f 4920//3420 4919//3005 4935//3026
+f 4915//3421 4914//3009 4929//3027
+f 4940//3025 4939//3425 4955//3028
+f 4935//3026 4934//3023 4950//3427
+f 4930//3014 4929//3027 4944//3030
+f 4936//3013 4935//3026 4951//3031
+f 4931//3016 4930//3014 4945//3032
+f 4937//3015 4936//3013 4952//3033
+f 4932//3424 4931//3016 4946//3428
+f 4927//3021 4926//3422 4941//3035
+f 4938//3018 4937//3015 4953//3036
+f 4933//3037 4932//3424 4947//3038
+f 4928//3426 4927//3021 4942//3039
+f 4939//3425 4938//3018 4954//3040
+f 4934//3023 4933//3037 4949//3429
+f 4929//3027 4928//3426 4943//3042
+f 4954//3040 4953//3036 4968//3430
+f 4949//3429 4948//480 4963//3045
+f 4944//3030 4943//3042 4959//3046
+f 4955//3028 4954//3040 4969//3431
+f 4950//3427 4949//3429 4964//3048
+f 4945//3032 4944//3030 4960//3432
+f 4951//3031 4950//3427 4965//3050
+f 4946//3428 4945//3032 4961//3051
+f 4952//3033 4951//3031 4966//3052
+f 4947//3038 4946//3428 4962//3053
+f 4942//3039 4941//3035 4957//3054
+f 4953//3036 4952//3033 4967//3055
+f 4948//480 4947//3038 4963//3045
+f 4943//3042 4942//3039 4958//3056
+f 4957//3054 4956//3057 4972//3058
+f 4968//3430 4967//3055 4982//3059
+f 4963//3045 4962//3053 4978//3060
+f 4958//3056 4957//3054 4973//3433
+f 4969//3431 4968//3430 4983//3062
+f 4964//3048 4963//3045 4978//3060
+f 4959//3046 4958//3056 4974//3063
+f 4970//3064 4969//3431 4984//3065
+f 4965//3050 4964//3048 4979//3066
+f 4960//3432 4959//3046 4975//3067
+f 4966//3052 4965//3050 4980//3434
+f 4961//3051 4960//3432 4976//3435
+f 4967//3055 4966//3052 4981//3436
+f 4962//3053 4961//3051 4977//3071
+f 4976//3435 4975//3067 4991//3072
+f 4982//3059 4981//3436 4996//3073
+f 4977//3071 4976//3435 4992//3437
+f 4972//3058 4971//3075 4987//3076
+f 4983//3062 4982//3059 4997//3077
+f 4978//3060 4977//3071 4993//3078
+f 4973//3433 4972//3058 4988//3079
+f 4984//3065 4983//3062 4998//3438
+f 4979//3066 4978//3060 4993//3078
+f 4974//3063 4973//3433 4989//3081
+f 4985//3082 4984//3065 4999//3083
+f 4980//3434 4979//3066 4994//3439
+f 4975//3067 4974//3063 4990//3085
+f 4981//3436 4980//3434 4995//3086
+f 4995//3086 4994//3439 5009//3087
+f 4990//3085 4989//3081 5005//3088
+f 4996//3073 4995//3086 5010//3440
+f 4991//3072 4990//3085 5006//3090
+f 4997//3077 4996//3073 5011//3091
+f 4992//3437 4991//3072 5007//3092
+f 4987//3076 4986//3093 5002//3094
+f 4998//3438 4997//3077 5012//3095
+f 4993//3078 4992//3437 5008//3096
+f 4988//3079 4987//3076 5003//3097
+f 4999//3083 4998//3438 5013//3098
+f 4994//3439 4993//3078 5008//3096
+f 4989//3081 4988//3079 5004//3099
+f 5000//3441 4999//3083 5014//3101
+f 5014//3101 5013//3098 5028//3442
+f 5009//3087 5008//3096 5023//3103
+f 5004//3099 5003//3097 5019//3443
+f 5015//3444 5014//3101 5029//3106
+f 5010//3440 5009//3087 5024//3107
+f 5005//3088 5004//3099 5020//3445
+f 5011//3091 5010//3440 5025//3109
+f 5006//3090 5005//3088 5021//3110
+f 5012//3095 5011//3091 5026//3111
+f 5007//3092 5006//3090 5022//3446
+f 5002//3094 5001//3447 5017//3448
+f 5013//3098 5012//3095 5027//3115
+f 5008//3096 5007//3092 5023//3103
+f 5003//3097 5002//3094 5018//3116
+f 5017//3448 5016//3449 5032//3118
+f 5028//3442 5027//3115 5042//3450
+f 5023//3103 5022//3446 5038//3120
+f 5018//3116 5017//3448 5033//3121
+f 5029//3106 5028//3442 5043//3451
+f 5024//3107 5023//3103 5038//3120
+f 5019//3443 5018//3116 5034//3123
+f 5030//3124 5029//3106 5044//3125
+f 5025//3109 5024//3107 5039//3126
+f 5020//3445 5019//3443 5035//3452
+f 5026//3111 5025//3109 5040//3128
+f 5021//3110 5020//3445 5036//3129
+f 5027//3115 5026//3111 5041//3130
+f 5022//3446 5021//3110 5037//3131
+f 5036//3129 5035//3452 5051//3132
+f 5042//3450 5041//3130 5056//3133
+f 5037//3131 5036//3129 5052//3134
+f 5032//3118 5031//3453 5047//3454
+f 5043//3451 5042//3450 5057//3137
+f 5038//3120 5037//3131 5053//3138
+f 5033//3121 5032//3118 5048//3139
+f 5044//3125 5043//3451 5058//3455
+f 5039//3126 5038//3120 5053//3138
+f 5034//3123 5033//3121 5049//3141
+f 5045//3142 5044//3125 5059//3143
+f 5040//3128 5039//3126 5054//3144
+f 5035//3452 5034//3123 5050//3145
+f 5041//3130 5040//3128 5055//3456
+f 5055//3456 5054//3144 5069//3147
+f 5050//3145 5049//3141 5065//3148
+f 5056//3133 5055//3456 5070//3149
+f 5051//3132 5050//3145 5066//3457
+f 5057//3137 5056//3133 5071//3151
+f 5052//3134 5051//3132 5067//3152
+f 5047//3454 5046//3458 5062//3154
+f 5058//3455 5057//3137 5072//3155
+f 5053//3138 5052//3134 5068//261
+f 5048//3139 5047//3454 5063//3156
+f 5059//3143 5058//3455 5073//3157
+f 5054//3144 5053//3138 5068//261
+f 5049//3141 5048//3139 5064//3158
+f 5060//3459 5059//3143 5074//3160
+f 5074//3160 5073//3157 5089//3460
+f 5069//3147 5068//261 5084//3162
+f 5064//3158 5063//3156 5078//3163
+f 5075//3164 5074//3160 5090//3461
+f 5070//3149 5069//3147 5085//3462
+f 5065//3148 5064//3158 5079//3167
+f 5071//3151 5070//3149 5086//3168
+f 5066//3457 5065//3148 5080//3169
+f 5072//3155 5071//3151 5087//3170
+f 5067//3152 5066//3457 5081//3463
+f 5062//3154 5061//3172 5076//3464
+f 5073//3157 5072//3155 5088//3174
+f 5068//261 5067//3152 5082//3175
+f 5063//3156 5062//3154 5077//3465
+f 5088//3174 5087//3170 5103//3177
+f 5083//3178 5082//3175 5097//3466
+f 5078//3163 5077//3465 5092//3467
+f 5089//3460 5088//3174 5104//3181
+f 5084//3162 5083//3178 5099//3182
+f 5079//3167 5078//3163 5093//3183
+f 5090//3461 5089//3460 5105//3184
+f 5085//3462 5084//3162 5100//3185
+f 5080//3169 5079//3167 5094//3186
+f 5086//3168 5085//3462 5101//3187
+f 5081//3463 5080//3169 5095//3188
+f 5087//3170 5086//3168 5102//3468
+f 5082//3175 5081//3463 5096//3469
+f 5077//3465 5076//3464 5091//3470
+f 5102//3468 5101//3187 5117//3192
+f 5097//3466 5096//3469 5111//3193
+f 5092//3467 5091//3470 5106//3471
+f 5103//3177 5102//3468 5118//3472
+f 5098//3196 5097//3466 5112//3197
+f 5093//3183 5092//3467 5107//3198
+f 5104//3181 5103//3177 5119//3199
+f 5099//3182 5098//3196 5114//3200
+f 5094//3186 5093//3183 5108//3473
+f 5105//3184 5104//3181 5120//3202
+f 5100//3185 5099//3182 5115//3203
+f 5095//3188 5094//3186 5109//3474
+f 5101//3187 5100//3185 5116//3205
+f 5096//3469 5095//3188 5110//3206
+f 5110//3206 5109//3474 5124//3207
+f 5116//3205 5115//3203 5131//3208
+f 5111//3193 5110//3206 5125//3209
+f 5117//3192 5116//3205 5132//3210
+f 5112//3197 5111//3193 5126//3475
+f 5107//3198 5106//3471 5121//3212
+f 5118//3472 5117//3192 5133//3476
+f 5113//3214 5112//3197 5127//3477
+f 5108//3473 5107//3198 5122//3216
+f 5119//3199 5118//3472 5134//3478
+f 5114//3200 5113//3214 5129//3218
+f 5109//3474 5108//3473 5123//3219
+f 5120//3202 5119//3199 5135//3479
+f 5115//3203 5114//3200 5130//3480
+f 5129//3218 5128//3222 5144//3481
+f 5124//3207 5123//3219 5138//3224
+f 5135//3479 5134//3478 5150//3482
+f 5130//3480 5129//3218 5145//3226
+f 5125//3209 5124//3207 5139//3227
+f 5131//3208 5130//3480 5146//3228
+f 5126//3475 5125//3209 5140//3483
+f 5132//3210 5131//3208 5147//3230
+f 5127//3477 5126//3475 5141//3231
+f 5122//3216 5121//3212 5136//3232
+f 5133//3476 5132//3210 5148//3484
+f 5128//3222 5127//3477 5142//3234
+f 5123//3219 5122//3216 5137//3485
+f 5134//3478 5133//3476 5149//3236
+f 5148//3484 5147//3230 5164//3486
+f 5143//3238 5142//3234 5158//3239
+f 5138//3224 5137//3485 5153//3240
+f 5149//3236 5148//3484 5165//3241
+f 5144//3481 5143//3238 5160//3242
+f 5139//3227 5138//3224 5154//3243
+f 5150//3482 5149//3236 5166//3487
+f 5145//3226 5144//3481 5161//3488
+f 5140//3483 5139//3227 5155//3246
+f 5146//3228 5145//3226 5162//3489
+f 5141//3231 5140//3483 5156//3490
+f 5147//3230 5146//3228 5163//3249
+f 5142//3234 5141//3231 5157//3250
+f 5137//3485 5136//3232 5152//3251
+f 5163//3249 5162//3489 5178//3491
+f 5158//3239 5157//3250 5172//3253
+f 5153//3240 5152//3251 5167//3254
+f 5164//3486 5163//3249 5179//3255
+f 5159//3256 5158//3239 5173//3257
+f 5154//3243 5153//3240 5168//3258
+f 5165//3241 5164//3486 5180//3259
+f 5160//3242 5159//3256 5175//3260
+f 5155//3246 5154//3243 5169//3492
+f 5166//3487 5165//3241 5181//3262
+f 5161//3488 5160//3242 5176//3263
+f 5156//3490 5155//3246 5170//3264
+f 5162//3489 5161//3488 5177//3493
+f 5157//3250 5156//3490 5171//3266
+f 5171//3266 5170//3264 5185//3267
+f 5177//3493 5176//3263 5192//3268
+f 5172//3253 5171//3266 5186//3269
+f 5178//3491 5177//3493 5193//3494
+f 5173//3257 5172//3253 5187//3495
+f 5168//3258 5167//3254 5182//3272
+f 5179//3255 5178//3491 5194//3273
+f 5174//3274 5173//3257 5188//3275
+f 5169//3492 5168//3258 5183//3276
+f 5180//3259 5179//3255 5195//3277
+f 5175//3260 5174//3274 5190//3278
+f 5170//3264 5169//3492 5184//3279
+f 5181//3262 5180//3259 5196//3280
+f 5176//3263 5175//3260 5191//3281
+f 5190//3278 5189//3282 5204//3283
+f 5185//3267 5184//3279 5200//3284
+f 5196//3280 5195//3277 5210//3285
+f 5191//3281 5190//3278 5205//3286
+f 5186//3269 5185//3267 5201//3496
+f 5192//3268 5191//3281 5206//3288
+f 5187//3495 5186//3269 5202//3289
+f 5193//3494 5192//3268 5207//3290
+f 5188//3275 5187//3495 5203//3291
+f 5183//3276 5182//3272 5198//3292
+f 5194//3273 5193//3494 5208//3293
+f 5189//3282 5188//3275 5204//3283
+f 5184//3279 5183//3276 5199//3294
+f 5195//3277 5194//3273 5209//3497
+f 5209//3497 5208//3293 5223//3296
+f 5204//3283 5203//3291 5219//3297
+f 5199//3294 5198//3292 5214//3498
+f 5210//3285 5209//3497 5224//3299
+f 5205//3286 5204//3283 5219//3297
+f 5200//3284 5199//3294 5215//3300
+f 5211//3301 5210//3285 5225//3302
+f 5206//3288 5205//3286 5220//3303
+f 5201//3496 5200//3284 5216//3499
+f 5207//3290 5206//3288 5221//3500
+f 5202//3289 5201//3496 5217//3306
+f 5208//3293 5207//3290 5222//3307
+f 5203//3291 5202//3289 5218//3308
+f 5198//3292 5197//3309 5213//3310
+f 5223//3296 5222//3307 5237//3501
+f 5218//3308 5217//3306 5233//3312
+f 5213//3310 5212//3502 5228//3314
+f 5224//3299 5223//3296 5238//3315
+f 5219//3297 5218//3308 5234//3503
+f 5214//3498 5213//3310 5229//3317
+f 5225//3302 5224//3299 5239//3504
+f 5220//3303 5219//3297 5234//3503
+f 5215//3300 5214//3498 5230//3319
+f 5226//3320 5225//3302 5240//3321
+f 5221//3500 5220//3303 5235//3505
+f 5216//3499 5215//3300 5231//3323
+f 5222//3307 5221//3500 5236//3506
+f 5217//3306 5216//3499 5232//3325
+f 5237//3501 5236//3506 5251//3507
+f 5232//3325 5231//3323 5247//3327
+f 5238//3315 5237//3501 5252//3328
+f 5233//3312 5232//3325 5248//3329
+f 5228//3314 5227//3508 5243//3331
+f 5239//3504 5238//3315 5253//3509
+f 5234//3503 5233//3312 5249//3333
+f 5229//3317 5228//3314 5244//3334
+f 5240//3321 5239//3504 5254//3510
+f 5235//3505 5234//3503 5249//3333
+f 5230//3319 5229//3317 5245//3336
+f 5241//3337 5240//3321 5255//3511
+f 5236//3506 5235//3505 5250//3339
+f 5231//3323 5230//3319 5246//3340
+f 5245//3336 5244//3334 5260//3512
+f 5256//3513 5255//3511 5270//3343
+f 5251//3507 5250//3339 5265//3344
+f 5246//3340 5245//3336 5261//3345
+f 5252//3328 5251//3507 5266//3346
+f 5247//3327 5246//3340 5262//3514
+f 5253//3509 5252//3328 5267//3348
+f 5248//3329 5247//3327 5263//3349
+f 5243//3331 5242//3350 5258//3515
+f 5254//3510 5253//3509 5268//3352
+f 5249//3333 5248//3329 5264//3353
+f 5244//3334 5243//3331 5259//3516
+f 5255//3511 5254//3510 5269//3517
+f 5250//3339 5249//3333 5264//3353
+f 5264//3353 5263//3349 5280//3356
+f 5259//3516 5258//3515 5275//3518
+f 5270//3343 5269//3517 5285//3358
+f 5265//3344 5264//3353 5280//3356
+f 5260//3512 5259//3516 5276//3519
+f 5271//3360 5270//3343 5286//3361
+f 5266//3346 5265//3344 5281//3362
+f 5261//3345 5260//3512 5277//3363
+f 5267//3348 5266//3346 5282//3364
+f 5262//3514 5261//3345 5278//3365
+f 5268//3352 5267//3348 5283//3520
+f 5263//3349 5262//3514 5279//3367
+f 5258//3515 5257//3521 5274//3369
+f 5269//3517 5268//3352 5284//3370
+f 5284//3370 5283//3520 5298//3371
+f 5279//3367 5278//3365 5294//3372
+f 5274//3369 5273//3522 5289//3523
+f 5285//3358 5284//3370 5299//3524
+f 5280//3356 5279//3367 5295//3376
+f 5275//3518 5274//3369 5290//3377
+f 5286//3361 5285//3358 5300//3378
+f 5281//3362 5280//3356 5295//3376
+f 5276//3519 5275//3518 5291//3525
+f 5287//3380 5286//3361 5301//3381
+f 5282//3364 5281//3362 5296//3382
+f 5277//3363 5276//3519 5292//3383
+f 5283//3520 5282//3364 5297//3526
+f 5278//3365 5277//3363 5293//3385
+f 5151//364 4835//2928 4850//3393
+f 4821//3389 5272//124 4836//3390
+f 5151//364 4850//3393 4865//2947
+f 4836//3390 5272//124 4851//2939
+f 4851//2939 5272//124 4866//3400
+f 5151//364 4865//2947 4880//2965
+f 5151//364 4880//2965 4895//3404
+f 4866//3400 5272//124 4881//3408
+f 5151//364 4895//3404 4910//2988
+f 4881//3408 5272//124 4896//2995
+f 5151//364 4910//2988 4925//3419
+f 4896//2995 5272//124 4911//2999
+f 4911//2999 5272//124 4926//3422
+f 5151//364 4925//3419 4940//3025
+f 5151//364 4940//3025 4955//3028
+f 4926//3422 5272//124 4941//3035
+f 5151//364 4955//3028 4970//3064
+f 4941//3035 5272//124 4956//3057
+f 5151//364 4970//3064 4985//3082
+f 4956//3057 5272//124 4971//3075
+f 4971//3075 5272//124 4986//3093
+f 5151//364 4985//3082 5000//3441
+f 5151//364 5000//3441 5015//3444
+f 4986//3093 5272//124 5001//3447
+f 5151//364 5015//3444 5030//3124
+f 5001//3447 5272//124 5016//3449
+f 5151//364 5030//3124 5045//3142
+f 5016//3449 5272//124 5031//3453
+f 5031//3453 5272//124 5046//3458
+f 5151//364 5045//3142 5060//3459
+f 5151//364 5060//3459 5075//3164
+f 5046//3458 5272//124 5061//3172
+f 5151//364 5075//3164 5090//3461
+f 5061//3172 5272//124 5076//3464
+f 5151//364 5090//3461 5105//3184
+f 5076//3464 5272//124 5091//3470
+f 5091//3470 5272//124 5106//3471
+f 5151//364 5105//3184 5120//3202
+f 5151//364 5120//3202 5135//3479
+f 5106//3471 5272//124 5121//3212
+f 5151//364 5135//3479 5150//3482
+f 5121//3212 5272//124 5136//3232
+f 5151//364 5150//3482 5166//3487
+f 5136//3232 5272//124 5152//3251
+f 5152//3251 5272//124 5167//3254
+f 5151//364 5166//3487 5181//3262
+f 5151//364 5181//3262 5196//3280
+f 5167//3254 5272//124 5182//3272
+f 5151//364 5196//3280 5211//3301
+f 5182//3272 5272//124 5197//3309
+f 5151//364 5211//3301 5226//3320
+f 5197//3309 5272//124 5212//3502
+f 5151//364 5226//3320 5241//3337
+f 5212//3502 5272//124 5227//3508
+f 5151//364 5241//3337 5256//3513
+f 5227//3508 5272//124 5242//3350
+f 5151//364 5256//3513 5271//3360
+f 5242//3350 5272//124 5257//3521
+f 5151//364 5271//3360 5287//3380
+f 5257//3521 5272//124 5273//3522
+f 5151//364 5287//3380 5302//3527
+f 5273//3522 5272//124 5288//3528
+f 5151//364 5302//3527 4835//2928
+f 5298//3371 5297//3526 4830//2930
+f 5293//3385 5292//3383 4826//2910
+f 5288//3528 5272//124 4821//3389
+f 5299//3524 5298//3371 4831//2934
+f 5294//3372 5293//3385 4827//2909
+f 5289//3523 5288//3528 4822//2912
+f 5300//3378 5299//3524 4832//2916
+f 5295//3376 5294//3372 4828//5
+f 5290//3377 5289//3523 4823//2920
+f 5301//3381 5300//3378 4833//2915
+f 5296//3382 5295//3376 4828//5
+f 5291//3525 5290//3377 4824//2926
+f 5302//3527 5301//3381 4834//2922
+f 5297//3526 5296//3382 4829//2924
+f 5292//3383 5291//3525 4825//2932
+f 4360//2919 4345//2909 4359//2911
+f 4355//2921 4340//2912 4354//2914
+f 4350//2916 4365//2937 4366//2917
+f 4361//2941 4346//2918 4360//2919
+f 4356//2927 4341//2920 4355//2921
+f 4351//2915 4366//2917 4367//2923
+f 4346//2918 4361//2941 4362//2925
+f 4357//2933 4342//2926 4356//2927
+f 4352//2922 4367//2923 4368//2929
+f 4347//2924 4362//2925 4363//2931
+f 4358//2936 4343//2932 4357//2933
+f 4348//2930 4363//2931 4364//2935
+f 4359//2911 4344//2910 4358//2936
+f 4349//2934 4364//2935 4365//2937
+f 4375//2942 4360//2919 4374//2938
+f 4370//2943 4355//2921 4369//2939
+f 4365//2937 4380//2952 4381//2940
+f 4376//2959 4361//2941 4375//2942
+f 4371//2946 4356//2927 4370//2943
+f 4366//2917 4381//2940 4382//2944
+f 4361//2941 4376//2959 4377//2945
+f 4372//2949 4357//2933 4371//2946
+f 4367//2923 4382//2944 4383//2947
+f 4362//2925 4377//2945 4378//2948
+f 4373//2951 4358//2936 4372//2949
+f 4363//2931 4378//2948 4379//2950
+f 4374//2938 4359//2911 4373//2951
+f 4364//2935 4379//2950 4380//2952
+f 4378//2948 4393//2966 4394//2953
+f 4389//2956 4374//2938 4388//2954
+f 4379//2950 4394//2953 4395//2955
+f 4390//2960 4375//2942 4389//2956
+f 4385//2961 4370//2943 4384//2957
+f 4380//2952 4395//2955 4396//2958
+f 4391//2977 4376//2959 4390//2960
+f 4386//2964 4371//2946 4385//2961
+f 4381//2940 4396//2958 4397//2962
+f 4376//2959 4391//2977 4392//2963
+f 4387//2967 4372//2949 4386//2964
+f 4382//2944 4397//2962 4398//2965
+f 4377//2945 4392//2963 4393//2966
+f 4388//2954 4373//2951 4387//2967
+f 4397//2962 4412//2980 4413//2968
+f 4392//2963 4407//2981 4408//2969
+f 4403//2972 4388//2954 4402//2970
+f 4393//2966 4408//2969 4409//2971
+f 4404//2974 4389//2956 4403//2972
+f 4394//2953 4409//2971 4410//2973
+f 4405//2978 4390//2960 4404//2974
+f 4400//2979 4385//2961 4399//2975
+f 4395//2955 4410//2973 4411//2976
+f 4406//2985 4391//2977 4405//2978
+f 4401//2982 4386//2964 4400//2979
+f 4396//2958 4411//2976 4412//2980
+f 4391//2977 4406//2985 4407//2981
+f 4402//2970 4387//2967 4401//2982
+f 4416//2987 4401//2982 4415//2983
+f 4411//2976 4426//2996 4427//2984
+f 4406//2985 4421//3001 4422//2986
+f 4417//2990 4402//2970 4416//2987
+f 4412//2980 4427//2984 4428//2988
+f 4407//2981 4422//2986 4423//2989
+f 4418//2992 4403//2972 4417//2990
+f 4408//2969 4423//2989 4424//2991
+f 4419//2994 4404//2974 4418//2992
+f 4409//2971 4424//2991 4425//2993
+f 4420//2997 4405//2978 4419//2994
+f 4415//2983 4400//2979 4414//2995
+f 4410//2973 4425//2993 4426//2996
+f 4421//3001 4406//2985 4420//2997
+f 4435//3002 4420//2997 4434//2998
+f 4430//3003 4415//2983 4429//2999
+f 4425//2993 4440//3012 4441//3000
+f 4436//3019 4421//3001 4435//3002
+f 4431//3006 4416//2987 4430//3003
+f 4426//2996 4441//3000 4442//3004
+f 4421//3001 4436//3019 4437//3005
+f 4432//3009 4417//2990 4431//3006
+f 4427//2984 4442//3004 4443//3007
+f 4422//2986 4437//3005 4438//3008
+f 4433//3011 4418//2992 4432//3009
+f 4423//2989 4438//3008 4439//3010
+f 4434//2998 4419//2994 4433//3011
+f 4424//2991 4439//3010 4440//3012
+f 4438//3008 4453//3026 4454//3013
+f 4449//3016 4434//2998 4448//3014
+f 4439//3010 4454//3013 4455//3015
+f 4450//3020 4435//3002 4449//3016
+f 4445//3021 4430//3003 4444//3017
+f 4440//3012 4455//3015 4456//3018
+f 4451//3037 4436//3019 4450//3020
+f 4446//3024 4431//3006 4445//3021
+f 4441//3000 4456//3018 4457//3022
+f 4436//3019 4451//3037 4452//3023
+f 4447//3027 4432//3009 4446//3024
+f 4442//3004 4457//3022 4458//3025
+f 4437//3005 4452//3023 4453//3026
+f 4448//3014 4433//3011 4447//3027
+f 4457//3022 4472//3040 4473//3028
+f 4452//3023 4467//3041 4468//3029
+f 4463//3032 4448//3014 4462//3030
+f 4453//3026 4468//3029 4469//3031
+f 4464//3034 4449//3016 4463//3032
+f 4454//3013 4469//3031 4470//3033
+f 4465//3038 4450//3020 4464//3034
+f 4460//3039 4445//3021 4459//3035
+f 4455//3015 4470//3033 4471//3036
+f 4466//3044 4451//3037 4465//3038
+f 4461//3042 4446//3024 4460//3039
+f 4456//3018 4471//3036 4472//3040
+f 4451//3037 4466//3044 4467//3041
+f 4462//3030 4447//3027 4461//3042
+f 4487//3047 4472//3040 4486//3043
+f 4482//3048 4467//3041 4481//3045
+f 4461//3042 4476//3056 4477//3046
+f 4488//3064 4473//3028 4487//3047
+f 4483//3050 4468//3029 4482//3048
+f 4462//3030 4477//3046 4478//3049
+f 4484//3052 4469//3031 4483//3050
+f 4463//3032 4478//3049 4479//3051
+f 4485//3055 4470//3033 4484//3052
+f 4464//3034 4479//3051 4480//3053
+f 4459//3035 4474//3057 4475//3054
+f 4486//3043 4471//3036 4485//3055
+f 4465//3038 4480//3053 4481//3045
+f 4460//3039 4475//3054 4476//3056
+f 4474//3057 4489//3075 4490//3058
+f 4501//3062 4486//3043 4500//3059
+f 4480//3053 4495//3071 4496//3060
+f 4475//3054 4490//3058 4491//3061
+f 4502//3065 4487//3047 4501//3062
+f 4497//3066 4482//3048 4496//3060
+f 4476//3056 4491//3061 4492//3063
+f 4503//3082 4488//3064 4502//3065
+f 4498//3068 4483//3050 4497//3066
+f 4477//3046 4492//3063 4493//3067
+f 4499//3070 4484//3052 4498//3068
+f 4478//3049 4493//3067 4494//3069
+f 4500//3059 4485//3055 4499//3070
+f 4479//3051 4494//3069 4495//3071
+f 4493//3067 4508//3085 4509//3072
+f 4515//3077 4500//3059 4514//3073
+f 4494//3069 4509//3072 4510//3074
+f 4489//3075 4504//3093 4505//3076
+f 4516//3080 4501//3062 4515//3077
+f 4495//3071 4510//3074 4511//3078
+f 4490//3058 4505//3076 4506//3079
+f 4517//3083 4502//3065 4516//3080
+f 4512//3084 4497//3066 4511//3078
+f 4491//3061 4506//3079 4507//3081
+f 4518//3100 4503//3082 4517//3083
+f 4513//3086 4498//3068 4512//3084
+f 4492//3063 4507//3081 4508//3085
+f 4514//3073 4499//3070 4513//3086
+f 4528//3089 4513//3086 4527//3087
+f 4507//3081 4522//3099 4523//3088
+f 4529//3091 4514//3073 4528//3089
+f 4508//3085 4523//3088 4524//3090
+f 4530//3095 4515//3077 4529//3091
+f 4509//3072 4524//3090 4525//3092
+f 4504//3093 4519//3113 4520//3094
+f 4531//3098 4516//3080 4530//3095
+f 4510//3074 4525//3092 4526//3096
+f 4505//3076 4520//3094 4521//3097
+f 4532//3101 4517//3083 4531//3098
+f 4527//3087 4512//3084 4526//3096
+f 4506//3079 4521//3097 4522//3099
+f 4533//3105 4518//3100 4532//3101
+f 4547//3106 4532//3101 4546//3102
+f 4542//3107 4527//3087 4541//3103
+f 4521//3097 4536//3116 4537//3104
+f 4548//3124 4533//3105 4547//3106
+f 4543//3109 4528//3089 4542//3107
+f 4522//3099 4537//3104 4538//3108
+f 4544//3111 4529//3091 4543//3109
+f 4523//3088 4538//3108 4539//3110
+f 4545//3115 4530//3095 4544//3111
+f 4524//3090 4539//3110 4540//3112
+f 4519//3113 4534//3117 4535//3114
+f 4546//3102 4531//3098 4545//3115
+f 4525//3092 4540//3112 4541//3103
+f 4520//3094 4535//3114 4536//3116
+f 4534//3117 4549//3135 4550//3118
+f 4561//3122 4546//3102 4560//3119
+f 4540//3112 4555//3131 4556//3120
+f 4535//3114 4550//3118 4551//3121
+f 4562//3125 4547//3106 4561//3122
+f 4557//3126 4542//3107 4556//3120
+f 4536//3116 4551//3121 4552//3123
+f 4563//3142 4548//3124 4562//3125
+f 4558//3128 4543//3109 4557//3126
+f 4537//3104 4552//3123 4553//3127
+f 4559//3130 4544//3111 4558//3128
+f 4538//3108 4553//3127 4554//3129
+f 4560//3119 4545//3115 4559//3130
+f 4539//3110 4554//3129 4555//3131
+f 4553//3127 4568//3145 4569//3132
+f 4575//3137 4560//3119 4574//3133
+f 4554//3129 4569//3132 4570//3134
+f 4549//3135 4564//3153 4565//3136
+f 4576//3140 4561//3122 4575//3137
+f 4555//3131 4570//3134 4571//3138
+f 4550//3118 4565//3136 4566//3139
+f 4577//3143 4562//3125 4576//3140
+f 4572//3144 4557//3126 4571//3138
+f 4551//3121 4566//3139 4567//3141
+f 4578//3159 4563//3142 4577//3143
+f 4573//3146 4558//3128 4572//3144
+f 4552//3123 4567//3141 4568//3145
+f 4574//3133 4559//3130 4573//3146
+f 4588//3149 4573//3146 4587//3147
+f 4567//3141 4582//3158 4583//3148
+f 4589//3151 4574//3133 4588//3149
+f 4568//3145 4583//3148 4584//3150
+f 4590//3155 4575//3137 4589//3151
+f 4569//3132 4584//3150 4585//3152
+f 4564//3153 4579//3172 4580//3154
+f 4591//3157 4576//3140 4590//3155
+f 4570//3134 4585//3152 4586//261
+f 4565//3136 4580//3154 4581//3156
+f 4592//3160 4577//3143 4591//3157
+f 4587//3147 4572//3144 4586//261
+f 4566//3139 4581//3156 4582//3158
+f 4593//3164 4578//3159 4592//3160
+f 4591//3157 4606//3174 4607//3161
+f 4586//261 4601//3178 4602//3162
+f 4597//3167 4582//3158 4596//3163
+f 4592//3160 4607//3161 4608//3165
+f 4587//3147 4602//3162 4603//3166
+f 4598//3169 4583//3148 4597//3167
+f 4588//3149 4603//3166 4604//3168
+f 4599//3171 4584//3150 4598//3169
+f 4589//3151 4604//3168 4605//3170
+f 4600//3175 4585//3152 4599//3171
+f 4595//3176 4580//3154 4594//3173
+f 4590//3155 4605//3170 4606//3174
+f 4601//3178 4586//261 4600//3175
+f 4596//3163 4581//3156 4595//3176
+f 4605//3170 4620//3189 4621//3177
+f 4616//3196 4601//3178 4615//3179
+f 4611//3183 4596//3163 4610//3180
+f 4606//3174 4621//3177 4622//3181
+f 4601//3178 4616//3196 4617//3182
+f 4612//3186 4597//3167 4611//3183
+f 4607//3161 4622//3181 4623//3184
+f 4602//3162 4617//3182 4618//3185
+f 4613//3188 4598//3169 4612//3186
+f 4603//3166 4618//3185 4619//3187
+f 4614//3190 4599//3171 4613//3188
+f 4604//3168 4619//3187 4620//3189
+f 4615//3179 4600//3175 4614//3190
+f 4610//3180 4595//3176 4609//3191
+f 4619//3187 4634//3205 4635//3192
+f 4630//3197 4615//3179 4629//3193
+f 4625//3198 4610//3180 4624//3194
+f 4620//3189 4635//3192 4636//3195
+f 4631//3214 4616//3196 4630//3197
+f 4626//3201 4611//3183 4625//3198
+f 4621//3177 4636//3195 4637//3199
+f 4616//3196 4631//3214 4632//3200
+f 4627//3204 4612//3186 4626//3201
+f 4622//3181 4637//3199 4638//3202
+f 4617//3182 4632//3200 4633//3203
+f 4628//3206 4613//3188 4627//3204
+f 4618//3185 4633//3203 4634//3205
+f 4629//3193 4614//3190 4628//3206
+f 4643//3209 4628//3206 4642//3207
+f 4633//3203 4648//3221 4649//3208
+f 4644//3211 4629//3193 4643//3209
+f 4634//3205 4649//3208 4650//3210
+f 4645//3215 4630//3197 4644//3211
+f 4640//3216 4625//3198 4639//3212
+f 4635//3192 4650//3210 4651//3213
+f 4646//3222 4631//3214 4645//3215
+f 4641//3219 4626//3201 4640//3216
+f 4636//3195 4651//3213 4652//3217
+f 4631//3214 4646//3222 4647//3218
+f 4642//3207 4627//3204 4641//3219
+f 4637//3199 4652//3217 4653//3220
+f 4632//3200 4647//3218 4648//3221
+f 4646//3222 4661//3238 4662//3223
+f 4657//3227 4642//3207 4656//3224
+f 4652//3217 4667//3236 4668//3225
+f 4647//3218 4662//3223 4663//3226
+f 4658//3229 4643//3209 4657//3227
+f 4648//3221 4663//3226 4664//3228
+f 4659//3231 4644//3211 4658//3229
+f 4649//3208 4664//3228 4665//3230
+f 4660//3234 4645//3215 4659//3231
+f 4655//3235 4640//3216 4654//3232
+f 4650//3210 4665//3230 4666//3233
+f 4661//3238 4646//3222 4660//3234
+f 4656//3224 4641//3219 4655//3235
+f 4651//3213 4666//3233 4667//3236
+f 4665//3230 4681//3249 4682//3237
+f 4677//3256 4661//3238 4676//3239
+f 4672//3243 4656//3224 4671//3240
+f 4666//3233 4682//3237 4683//3241
+f 4661//3238 4677//3256 4678//3242
+f 4673//3246 4657//3227 4672//3243
+f 4667//3236 4683//3241 4684//3244
+f 4662//3223 4678//3242 4679//3245
+f 4674//3248 4658//3229 4673//3246
+f 4663//3226 4679//3245 4680//3247
+f 4675//3250 4659//3231 4674//3248
+f 4664//3228 4680//3247 4681//3249
+f 4676//3239 4660//3234 4675//3250
+f 4671//3240 4655//3235 4670//3251
+f 4680//3247 4695//3265 4696//3252
+f 4691//3257 4676//3239 4690//3253
+f 4686//3258 4671//3240 4685//3254
+f 4681//3249 4696//3252 4697//3255
+f 4692//3274 4677//3256 4691//3257
+f 4687//3261 4672//3243 4686//3258
+f 4682//3237 4697//3255 4698//3259
+f 4677//3256 4692//3274 4693//3260
+f 4688//3264 4673//3246 4687//3261
+f 4683//3241 4698//3259 4699//3262
+f 4678//3242 4693//3260 4694//3263
+f 4689//3266 4674//3248 4688//3264
+f 4679//3245 4694//3263 4695//3265
+f 4690//3253 4675//3250 4689//3266
+f 4704//3269 4689//3266 4703//3267
+f 4694//3263 4709//3281 4710//3268
+f 4705//3271 4690//3253 4704//3269
+f 4695//3265 4710//3268 4711//3270
+f 4706//3275 4691//3257 4705//3271
+f 4701//3276 4686//3258 4700//3272
+f 4696//3252 4711//3270 4712//3273
+f 4707//3282 4692//3274 4706//3275
+f 4702//3279 4687//3261 4701//3276
+f 4697//3255 4712//3273 4713//3277
+f 4692//3274 4707//3282 4708//3278
+f 4703//3267 4688//3264 4702//3279
+f 4698//3259 4713//3277 4714//3280
+f 4693//3260 4708//3278 4709//3281
+f 4723//3286 4708//3278 4722//3283
+f 4702//3279 4717//3294 4718//3284
+f 4729//3301 4714//3280 4728//3285
+f 4724//3288 4709//3281 4723//3286
+f 4703//3267 4718//3284 4719//3287
+f 4725//3290 4710//3268 4724//3288
+f 4704//3269 4719//3287 4720//3289
+f 4726//3293 4711//3270 4725//3290
+f 4705//3271 4720//3289 4721//3291
+f 4700//3272 4715//3309 4716//3292
+f 4727//3295 4712//3273 4726//3293
+f 4706//3275 4721//3291 4722//3283
+f 4701//3276 4716//3292 4717//3294
+f 4728//3285 4713//3277 4727//3295
+f 4742//3299 4727//3295 4741//3296
+f 4721//3291 4736//3308 4737//3297
+f 4716//3292 4731//3310 4732//3298
+f 4743//3302 4728//3285 4742//3299
+f 4738//3303 4723//3286 4737//3297
+f 4717//3294 4732//3298 4733//3300
+f 4744//3320 4729//3301 4743//3302
+f 4739//3305 4724//3288 4738//3303
+f 4718//3284 4733//3300 4734//3304
+f 4740//3307 4725//3290 4739//3305
+f 4719//3287 4734//3304 4735//3306
+f 4741//3296 4726//3293 4740//3307
+f 4720//3289 4735//3306 4736//3308
+f 4715//3309 4730//3313 4731//3310
+f 4756//3315 4741//3296 4755//3311
+f 4735//3306 4750//3325 4751//3312
+f 4730//3313 4745//3330 4746//3314
+f 4757//3318 4742//3299 4756//3315
+f 4736//3308 4751//3312 4752//3316
+f 4731//3310 4746//3314 4747//3317
+f 4758//3321 4743//3302 4757//3318
+f 4753//3322 4738//3303 4752//3316
+f 4732//3298 4747//3317 4748//3319
+f 4759//3337 4744//3320 4758//3321
+f 4754//3324 4739//3305 4753//3322
+f 4733//3300 4748//3319 4749//3323
+f 4755//3311 4740//3307 4754//3324
+f 4734//3304 4749//3323 4750//3325
+f 4770//3328 4755//3311 4769//3326
+f 4749//3323 4764//3340 4765//3327
+f 4771//3332 4756//3315 4770//3328
+f 4750//3325 4765//3327 4766//3329
+f 4745//3330 4760//3350 4761//3331
+f 4772//3335 4757//3318 4771//3332
+f 4751//3312 4766//3329 4767//3333
+f 4746//3314 4761//3331 4762//3334
+f 4773//3338 4758//3321 4772//3335
+f 4768//3339 4753//3322 4767//3333
+f 4747//3317 4762//3334 4763//3336
+f 4774//3342 4759//3337 4773//3338
+f 4769//3326 4754//3324 4768//3339
+f 4748//3319 4763//3336 4764//3340
+f 4762//3334 4777//3354 4778//3341
+f 4789//3360 4774//3342 4788//3343
+f 4784//3346 4769//3326 4783//3344
+f 4763//3336 4778//3341 4779//3345
+f 4785//3348 4770//3328 4784//3346
+f 4764//3340 4779//3345 4780//3347
+f 4786//3352 4771//3332 4785//3348
+f 4765//3327 4780//3347 4781//3349
+f 4760//3350 4775//3368 4776//3351
+f 4787//3355 4772//3335 4786//3352
+f 4766//3329 4781//3349 4782//3353
+f 4761//3331 4776//3351 4777//3354
+f 4788//3343 4773//3338 4787//3355
+f 4783//3344 4768//3339 4782//3353
+f 4781//3349 4797//3367 4798//3356
+f 4776//3351 4792//3369 4793//3357
+f 4804//3361 4788//3343 4803//3358
+f 4799//3362 4783//3344 4798//3356
+f 4777//3354 4793//3357 4794//3359
+f 4805//3380 4789//3360 4804//3361
+f 4800//3364 4784//3346 4799//3362
+f 4778//3341 4794//3359 4795//3363
+f 4801//3366 4785//3348 4800//3364
+f 4779//3345 4795//3363 4796//3365
+f 4802//3370 4786//3352 4801//3366
+f 4780//3347 4796//3365 4797//3367
+f 4775//3368 4791//3373 4792//3369
+f 4803//3358 4787//3355 4802//3370
+f 4817//3375 4802//3370 4816//3371
+f 4796//3365 4811//3385 4812//3372
+f 4791//3373 4806//3387 4807//3374
+f 4818//3378 4803//3358 4817//3375
+f 4797//3367 4812//3372 4813//3376
+f 4792//3369 4807//3374 4808//3377
+f 4819//3381 4804//3361 4818//3378
+f 4814//3382 4799//3362 4813//3376
+f 4793//3357 4808//3377 4809//3379
+f 4820//3386 4805//3380 4819//3381
+f 4815//3384 4800//3364 4814//3382
+f 4794//3359 4809//3379 4810//3383
+f 4816//3371 4801//3366 4815//3384
+f 4795//3363 4810//3383 4811//3385
+f 4349//2934 4816//3371 4348//2930
+f 4810//3383 4343//2932 4344//2910
+f 4350//2916 4817//3375 4349//2934
+f 4811//3385 4344//2910 4345//2909
+f 4806//3387 4339//2913 4340//2912
+f 4351//2915 4818//3378 4350//2916
+f 4812//3372 4345//2909 4346//2918
+f 4807//3374 4340//2912 4341//2920
+f 4352//2922 4819//3381 4351//2915
+f 4347//2924 4814//3382 4346//2918
+f 4808//3377 4341//2920 4342//2926
+f 4353//2928 4820//3386 4352//2922
+f 4348//2930 4815//3384 4347//2924
+f 4809//3379 4342//2926 4343//2932
+f 4842//2919 4827//2909 4841//3388
+f 4837//2921 4822//2912 4836//3390
+f 4832//2916 4847//2937 4848//2917
+f 4843//2941 4828//5 4842//2919
+f 4838//3392 4823//2920 4837//2921
+f 4833//2915 4848//2917 4849//3391
+f 4828//5 4843//2941 4844//2925
+f 4839//2933 4824//2926 4838//3392
+f 4834//2922 4849//3391 4850//3393
+f 4829//2924 4844//2925 4845//3394
+f 4840//2936 4825//2932 4839//2933
+f 4830//2930 4845//3394 4846//2935
+f 4841//3388 4826//2910 4840//2936
+f 4831//2934 4846//2935 4847//2937
+f 4857//2942 4842//2919 4856//3395
+f 4852//3396 4837//2921 4851//2939
+f 4847//2937 4862//3399 4863//2940
+f 4858//2959 4843//2941 4857//2942
+f 4853//2946 4838//3392 4852//3396
+f 4848//2917 4863//2940 4864//2944
+f 4843//2941 4858//2959 4859//2945
+f 4854//3397 4839//2933 4853//2946
+f 4849//3391 4864//2944 4865//2947
+f 4844//2925 4859//2945 4860//2948
+f 4855//3398 4840//2936 4854//3397
+f 4845//3394 4860//2948 4861//2950
+f 4856//3395 4841//3388 4855//3398
+f 4846//2935 4861//2950 4862//3399
+f 4860//2948 4875//3402 4876//2953
+f 4871//2956 4856//3395 4870//2954
+f 4861//2950 4876//2953 4877//2955
+f 4872//2960 4857//2942 4871//2956
+f 4867//2961 4852//3396 4866//3400
+f 4862//3399 4877//2955 4878//3401
+f 4873//2977 4858//2959 4872//2960
+f 4868//2964 4853//2946 4867//2961
+f 4863//2940 4878//3401 4879//2962
+f 4858//2959 4873//2977 4874//2963
+f 4869//3403 4854//3397 4868//2964
+f 4864//2944 4879//2962 4880//2965
+f 4859//2945 4874//2963 4875//3402
+f 4870//2954 4855//3398 4869//3403
+f 4879//2962 4894//3410 4895//3404
+f 4874//2963 4889//2981 4890//3405
+f 4885//2972 4870//2954 4884//2970
+f 4875//3402 4890//3405 4891//2971
+f 4886//3407 4871//2956 4885//2972
+f 4876//2953 4891//2971 4892//3406
+f 4887//3409 4872//2960 4886//3407
+f 4882//2979 4867//2961 4881//3408
+f 4877//2955 4892//3406 4893//2976
+f 4888//2985 4873//2977 4887//3409
+f 4883//2982 4868//2964 4882//2979
+f 4878//3401 4893//2976 4894//3410
+f 4873//2977 4888//2985 4889//2981
+f 4884//2970 4869//3403 4883//2982
+f 4898//2987 4883//2982 4897//3411
+f 4893//2976 4908//3414 4909//2984
+f 4888//2985 4903//3416 4904//3412
+f 4899//2990 4884//2970 4898//2987
+f 4894//3410 4909//2984 4910//2988
+f 4889//2981 4904//3412 4905//2989
+f 4900//3413 4885//2972 4899//2990
+f 4890//3405 4905//2989 4906//2991
+f 4901//2994 4886//3407 4900//3413
+f 4891//2971 4906//2991 4907//2993
+f 4902//3415 4887//3409 4901//2994
+f 4897//3411 4882//2979 4896//2995
+f 4892//3406 4907//2993 4908//3414
+f 4903//3416 4888//2985 4902//3415
+f 4917//3417 4902//3415 4916//2998
+f 4912//3003 4897//3411 4911//2999
+f 4907//2993 4922//3012 4923//3000
+f 4918//3423 4903//3416 4917//3417
+f 4913//3418 4898//2987 4912//3003
+f 4908//3414 4923//3000 4924//3004
+f 4903//3416 4918//3423 4919//3005
+f 4914//3009 4899//2990 4913//3418
+f 4909//2984 4924//3004 4925//3419
+f 4904//3412 4919//3005 4920//3420
+f 4915//3421 4900//3413 4914//3009
+f 4905//2989 4920//3420 4921//3010
+f 4916//2998 4901//2994 4915//3421
+f 4906//2991 4921//3010 4922//3012
+f 4920//3420 4935//3026 4936//3013
+f 4931//3016 4916//2998 4930//3014
+f 4921//3010 4936//3013 4937//3015
+f 4932//3424 4917//3417 4931//3016
+f 4927//3021 4912//3003 4926//3422
+f 4922//3012 4937//3015 4938//3018
+f 4933//3037 4918//3423 4932//3424
+f 4928//3426 4913//3418 4927//3021
+f 4923//3000 4938//3018 4939//3425
+f 4918//3423 4933//3037 4934//3023
+f 4929//3027 4914//3009 4928//3426
+f 4924//3004 4939//3425 4940//3025
+f 4919//3005 4934//3023 4935//3026
+f 4930//3014 4915//3421 4929//3027
+f 4939//3425 4954//3040 4955//3028
+f 4934//3023 4949//3429 4950//3427
+f 4945//3032 4930//3014 4944//3030
+f 4935//3026 4950//3427 4951//3031
+f 4946//3428 4931//3016 4945//3032
+f 4936//3013 4951//3031 4952//3033
+f 4947//3038 4932//3424 4946//3428
+f 4942//3039 4927//3021 4941//3035
+f 4937//3015 4952//3033 4953//3036
+f 4948//480 4933//3037 4947//3038
+f 4943//3042 4928//3426 4942//3039
+f 4938//3018 4953//3036 4954//3040
+f 4933//3037 4948//480 4949//3429
+f 4944//3030 4929//3027 4943//3042
+f 4969//3431 4954//3040 4968//3430
+f 4964//3048 4949//3429 4963//3045
+f 4943//3042 4958//3056 4959//3046
+f 4970//3064 4955//3028 4969//3431
+f 4965//3050 4950//3427 4964//3048
+f 4944//3030 4959//3046 4960//3432
+f 4966//3052 4951//3031 4965//3050
+f 4945//3032 4960//3432 4961//3051
+f 4967//3055 4952//3033 4966//3052
+f 4946//3428 4961//3051 4962//3053
+f 4941//3035 4956//3057 4957//3054
+f 4968//3430 4953//3036 4967//3055
+f 4947//3038 4962//3053 4963//3045
+f 4942//3039 4957//3054 4958//3056
+f 4956//3057 4971//3075 4972//3058
+f 4983//3062 4968//3430 4982//3059
+f 4962//3053 4977//3071 4978//3060
+f 4957//3054 4972//3058 4973//3433
+f 4984//3065 4969//3431 4983//3062
+f 4979//3066 4964//3048 4978//3060
+f 4958//3056 4973//3433 4974//3063
+f 4985//3082 4970//3064 4984//3065
+f 4980//3434 4965//3050 4979//3066
+f 4959//3046 4974//3063 4975//3067
+f 4981//3436 4966//3052 4980//3434
+f 4960//3432 4975//3067 4976//3435
+f 4982//3059 4967//3055 4981//3436
+f 4961//3051 4976//3435 4977//3071
+f 4975//3067 4990//3085 4991//3072
+f 4997//3077 4982//3059 4996//3073
+f 4976//3435 4991//3072 4992//3437
+f 4971//3075 4986//3093 4987//3076
+f 4998//3438 4983//3062 4997//3077
+f 4977//3071 4992//3437 4993//3078
+f 4972//3058 4987//3076 4988//3079
+f 4999//3083 4984//3065 4998//3438
+f 4994//3439 4979//3066 4993//3078
+f 4973//3433 4988//3079 4989//3081
+f 5000//3441 4985//3082 4999//3083
+f 4995//3086 4980//3434 4994//3439
+f 4974//3063 4989//3081 4990//3085
+f 4996//3073 4981//3436 4995//3086
+f 5010//3440 4995//3086 5009//3087
+f 4989//3081 5004//3099 5005//3088
+f 5011//3091 4996//3073 5010//3440
+f 4990//3085 5005//3088 5006//3090
+f 5012//3095 4997//3077 5011//3091
+f 4991//3072 5006//3090 5007//3092
+f 4986//3093 5001//3447 5002//3094
+f 5013//3098 4998//3438 5012//3095
+f 4992//3437 5007//3092 5008//3096
+f 4987//3076 5002//3094 5003//3097
+f 5014//3101 4999//3083 5013//3098
+f 5009//3087 4994//3439 5008//3096
+f 4988//3079 5003//3097 5004//3099
+f 5015//3444 5000//3441 5014//3101
+f 5029//3106 5014//3101 5028//3442
+f 5024//3107 5009//3087 5023//3103
+f 5003//3097 5018//3116 5019//3443
+f 5030//3124 5015//3444 5029//3106
+f 5025//3109 5010//3440 5024//3107
+f 5004//3099 5019//3443 5020//3445
+f 5026//3111 5011//3091 5025//3109
+f 5005//3088 5020//3445 5021//3110
+f 5027//3115 5012//3095 5026//3111
+f 5006//3090 5021//3110 5022//3446
+f 5001//3447 5016//3449 5017//3448
+f 5028//3442 5013//3098 5027//3115
+f 5007//3092 5022//3446 5023//3103
+f 5002//3094 5017//3448 5018//3116
+f 5016//3449 5031//3453 5032//3118
+f 5043//3451 5028//3442 5042//3450
+f 5022//3446 5037//3131 5038//3120
+f 5017//3448 5032//3118 5033//3121
+f 5044//3125 5029//3106 5043//3451
+f 5039//3126 5024//3107 5038//3120
+f 5018//3116 5033//3121 5034//3123
+f 5045//3142 5030//3124 5044//3125
+f 5040//3128 5025//3109 5039//3126
+f 5019//3443 5034//3123 5035//3452
+f 5041//3130 5026//3111 5040//3128
+f 5020//3445 5035//3452 5036//3129
+f 5042//3450 5027//3115 5041//3130
+f 5021//3110 5036//3129 5037//3131
+f 5035//3452 5050//3145 5051//3132
+f 5057//3137 5042//3450 5056//3133
+f 5036//3129 5051//3132 5052//3134
+f 5031//3453 5046//3458 5047//3454
+f 5058//3455 5043//3451 5057//3137
+f 5037//3131 5052//3134 5053//3138
+f 5032//3118 5047//3454 5048//3139
+f 5059//3143 5044//3125 5058//3455
+f 5054//3144 5039//3126 5053//3138
+f 5033//3121 5048//3139 5049//3141
+f 5060//3459 5045//3142 5059//3143
+f 5055//3456 5040//3128 5054//3144
+f 5034//3123 5049//3141 5050//3145
+f 5056//3133 5041//3130 5055//3456
+f 5070//3149 5055//3456 5069//3147
+f 5049//3141 5064//3158 5065//3148
+f 5071//3151 5056//3133 5070//3149
+f 5050//3145 5065//3148 5066//3457
+f 5072//3155 5057//3137 5071//3151
+f 5051//3132 5066//3457 5067//3152
+f 5046//3458 5061//3172 5062//3154
+f 5073//3157 5058//3455 5072//3155
+f 5052//3134 5067//3152 5068//261
+f 5047//3454 5062//3154 5063//3156
+f 5074//3160 5059//3143 5073//3157
+f 5069//3147 5054//3144 5068//261
+f 5048//3139 5063//3156 5064//3158
+f 5075//3164 5060//3459 5074//3160
+f 5073//3157 5088//3174 5089//3460
+f 5068//261 5083//3178 5084//3162
+f 5079//3167 5064//3158 5078//3163
+f 5074//3160 5089//3460 5090//3461
+f 5069//3147 5084//3162 5085//3462
+f 5080//3169 5065//3148 5079//3167
+f 5070//3149 5085//3462 5086//3168
+f 5081//3463 5066//3457 5080//3169
+f 5071//3151 5086//3168 5087//3170
+f 5082//3175 5067//3152 5081//3463
+f 5077//3465 5062//3154 5076//3464
+f 5072//3155 5087//3170 5088//3174
+f 5083//3178 5068//261 5082//3175
+f 5078//3163 5063//3156 5077//3465
+f 5087//3170 5102//3468 5103//3177
+f 5098//3196 5083//3178 5097//3466
+f 5093//3183 5078//3163 5092//3467
+f 5088//3174 5103//3177 5104//3181
+f 5083//3178 5098//3196 5099//3182
+f 5094//3186 5079//3167 5093//3183
+f 5089//3460 5104//3181 5105//3184
+f 5084//3162 5099//3182 5100//3185
+f 5095//3188 5080//3169 5094//3186
+f 5085//3462 5100//3185 5101//3187
+f 5096//3469 5081//3463 5095//3188
+f 5086//3168 5101//3187 5102//3468
+f 5097//3466 5082//3175 5096//3469
+f 5092//3467 5077//3465 5091//3470
+f 5101//3187 5116//3205 5117//3192
+f 5112//3197 5097//3466 5111//3193
+f 5107//3198 5092//3467 5106//3471
+f 5102//3468 5117//3192 5118//3472
+f 5113//3214 5098//3196 5112//3197
+f 5108//3473 5093//3183 5107//3198
+f 5103//3177 5118//3472 5119//3199
+f 5098//3196 5113//3214 5114//3200
+f 5109//3474 5094//3186 5108//3473
+f 5104//3181 5119//3199 5120//3202
+f 5099//3182 5114//3200 5115//3203
+f 5110//3206 5095//3188 5109//3474
+f 5100//3185 5115//3203 5116//3205
+f 5111//3193 5096//3469 5110//3206
+f 5125//3209 5110//3206 5124//3207
+f 5115//3203 5130//3480 5131//3208
+f 5126//3475 5111//3193 5125//3209
+f 5116//3205 5131//3208 5132//3210
+f 5127//3477 5112//3197 5126//3475
+f 5122//3216 5107//3198 5121//3212
+f 5117//3192 5132//3210 5133//3476
+f 5128//3222 5113//3214 5127//3477
+f 5123//3219 5108//3473 5122//3216
+f 5118//3472 5133//3476 5134//3478
+f 5113//3214 5128//3222 5129//3218
+f 5124//3207 5109//3474 5123//3219
+f 5119//3199 5134//3478 5135//3479
+f 5114//3200 5129//3218 5130//3480
+f 5128//3222 5143//3238 5144//3481
+f 5139//3227 5124//3207 5138//3224
+f 5134//3478 5149//3236 5150//3482
+f 5129//3218 5144//3481 5145//3226
+f 5140//3483 5125//3209 5139//3227
+f 5130//3480 5145//3226 5146//3228
+f 5141//3231 5126//3475 5140//3483
+f 5131//3208 5146//3228 5147//3230
+f 5142//3234 5127//3477 5141//3231
+f 5137//3485 5122//3216 5136//3232
+f 5132//3210 5147//3230 5148//3484
+f 5143//3238 5128//3222 5142//3234
+f 5138//3224 5123//3219 5137//3485
+f 5133//3476 5148//3484 5149//3236
+f 5147//3230 5163//3249 5164//3486
+f 5159//3256 5143//3238 5158//3239
+f 5154//3243 5138//3224 5153//3240
+f 5148//3484 5164//3486 5165//3241
+f 5143//3238 5159//3256 5160//3242
+f 5155//3246 5139//3227 5154//3243
+f 5149//3236 5165//3241 5166//3487
+f 5144//3481 5160//3242 5161//3488
+f 5156//3490 5140//3483 5155//3246
+f 5145//3226 5161//3488 5162//3489
+f 5157//3250 5141//3231 5156//3490
+f 5146//3228 5162//3489 5163//3249
+f 5158//3239 5142//3234 5157//3250
+f 5153//3240 5137//3485 5152//3251
+f 5162//3489 5177//3493 5178//3491
+f 5173//3257 5158//3239 5172//3253
+f 5168//3258 5153//3240 5167//3254
+f 5163//3249 5178//3491 5179//3255
+f 5174//3274 5159//3256 5173//3257
+f 5169//3492 5154//3243 5168//3258
+f 5164//3486 5179//3255 5180//3259
+f 5159//3256 5174//3274 5175//3260
+f 5170//3264 5155//3246 5169//3492
+f 5165//3241 5180//3259 5181//3262
+f 5160//3242 5175//3260 5176//3263
+f 5171//3266 5156//3490 5170//3264
+f 5161//3488 5176//3263 5177//3493
+f 5172//3253 5157//3250 5171//3266
+f 5186//3269 5171//3266 5185//3267
+f 5176//3263 5191//3281 5192//3268
+f 5187//3495 5172//3253 5186//3269
+f 5177//3493 5192//3268 5193//3494
+f 5188//3275 5173//3257 5187//3495
+f 5183//3276 5168//3258 5182//3272
+f 5178//3491 5193//3494 5194//3273
+f 5189//3282 5174//3274 5188//3275
+f 5184//3279 5169//3492 5183//3276
+f 5179//3255 5194//3273 5195//3277
+f 5174//3274 5189//3282 5190//3278
+f 5185//3267 5170//3264 5184//3279
+f 5180//3259 5195//3277 5196//3280
+f 5175//3260 5190//3278 5191//3281
+f 5205//3286 5190//3278 5204//3283
+f 5184//3279 5199//3294 5200//3284
+f 5211//3301 5196//3280 5210//3285
+f 5206//3288 5191//3281 5205//3286
+f 5185//3267 5200//3284 5201//3496
+f 5207//3290 5192//3268 5206//3288
+f 5186//3269 5201//3496 5202//3289
+f 5208//3293 5193//3494 5207//3290
+f 5187//3495 5202//3289 5203//3291
+f 5182//3272 5197//3309 5198//3292
+f 5209//3497 5194//3273 5208//3293
+f 5188//3275 5203//3291 5204//3283
+f 5183//3276 5198//3292 5199//3294
+f 5210//3285 5195//3277 5209//3497
+f 5224//3299 5209//3497 5223//3296
+f 5203//3291 5218//3308 5219//3297
+f 5198//3292 5213//3310 5214//3498
+f 5225//3302 5210//3285 5224//3299
+f 5220//3303 5205//3286 5219//3297
+f 5199//3294 5214//3498 5215//3300
+f 5226//3320 5211//3301 5225//3302
+f 5221//3500 5206//3288 5220//3303
+f 5200//3284 5215//3300 5216//3499
+f 5222//3307 5207//3290 5221//3500
+f 5201//3496 5216//3499 5217//3306
+f 5223//3296 5208//3293 5222//3307
+f 5202//3289 5217//3306 5218//3308
+f 5197//3309 5212//3502 5213//3310
+f 5238//3315 5223//3296 5237//3501
+f 5217//3306 5232//3325 5233//3312
+f 5212//3502 5227//3508 5228//3314
+f 5239//3504 5224//3299 5238//3315
+f 5218//3308 5233//3312 5234//3503
+f 5213//3310 5228//3314 5229//3317
+f 5240//3321 5225//3302 5239//3504
+f 5235//3505 5220//3303 5234//3503
+f 5214//3498 5229//3317 5230//3319
+f 5241//3337 5226//3320 5240//3321
+f 5236//3506 5221//3500 5235//3505
+f 5215//3300 5230//3319 5231//3323
+f 5237//3501 5222//3307 5236//3506
+f 5216//3499 5231//3323 5232//3325
+f 5252//3328 5237//3501 5251//3507
+f 5231//3323 5246//3340 5247//3327
+f 5253//3509 5238//3315 5252//3328
+f 5232//3325 5247//3327 5248//3329
+f 5227//3508 5242//3350 5243//3331
+f 5254//3510 5239//3504 5253//3509
+f 5233//3312 5248//3329 5249//3333
+f 5228//3314 5243//3331 5244//3334
+f 5255//3511 5240//3321 5254//3510
+f 5250//3339 5235//3505 5249//3333
+f 5229//3317 5244//3334 5245//3336
+f 5256//3513 5241//3337 5255//3511
+f 5251//3507 5236//3506 5250//3339
+f 5230//3319 5245//3336 5246//3340
+f 5244//3334 5259//3516 5260//3512
+f 5271//3360 5256//3513 5270//3343
+f 5266//3346 5251//3507 5265//3344
+f 5245//3336 5260//3512 5261//3345
+f 5267//3348 5252//3328 5266//3346
+f 5246//3340 5261//3345 5262//3514
+f 5268//3352 5253//3509 5267//3348
+f 5247//3327 5262//3514 5263//3349
+f 5242//3350 5257//3521 5258//3515
+f 5269//3517 5254//3510 5268//3352
+f 5248//3329 5263//3349 5264//3353
+f 5243//3331 5258//3515 5259//3516
+f 5270//3343 5255//3511 5269//3517
+f 5265//3344 5250//3339 5264//3353
+f 5263//3349 5279//3367 5280//3356
+f 5258//3515 5274//3369 5275//3518
+f 5286//3361 5270//3343 5285//3358
+f 5281//3362 5265//3344 5280//3356
+f 5259//3516 5275//3518 5276//3519
+f 5287//3380 5271//3360 5286//3361
+f 5282//3364 5266//3346 5281//3362
+f 5260//3512 5276//3519 5277//3363
+f 5283//3520 5267//3348 5282//3364
+f 5261//3345 5277//3363 5278//3365
+f 5284//3370 5268//3352 5283//3520
+f 5262//3514 5278//3365 5279//3367
+f 5257//3521 5273//3522 5274//3369
+f 5285//3358 5269//3517 5284//3370
+f 5299//3524 5284//3370 5298//3371
+f 5278//3365 5293//3385 5294//3372
+f 5273//3522 5288//3528 5289//3523
+f 5300//3378 5285//3358 5299//3524
+f 5279//3367 5294//3372 5295//3376
+f 5274//3369 5289//3523 5290//3377
+f 5301//3381 5286//3361 5300//3378
+f 5296//3382 5281//3362 5295//3376
+f 5275//3518 5290//3377 5291//3525
+f 5302//3527 5287//3380 5301//3381
+f 5297//3526 5282//3364 5296//3382
+f 5276//3519 5291//3525 5292//3383
+f 5298//3371 5283//3520 5297//3526
+f 5277//3363 5292//3383 5293//3385
+f 4831//2934 5298//3371 4830//2930
+f 5292//3383 4825//2932 4826//2910
+f 4832//2916 5299//3524 4831//2934
+f 5293//3385 4826//2910 4827//2909
+f 5288//3528 4821//3389 4822//2912
+f 4833//2915 5300//3378 4832//2916
+f 5294//3372 4827//2909 4828//5
+f 5289//3523 4822//2912 4823//2920
+f 4834//2922 5301//3381 4833//2915
+f 4829//2924 5296//3382 4828//5
+f 5290//3377 4823//2920 4824//2926
+f 4835//2928 5302//3527 4834//2922
+f 4830//2930 5297//3526 4829//2924
+f 5291//3525 4824//2926 4825//2932
+o Ear_R_Sphere.008
+v -0.942135 0.123766 -0.790557
+v -0.971285 0.138857 -0.773109
+v -1.001178 0.167463 -0.755604
+v -1.023476 0.202632 -0.742670
+v -1.050742 0.188359 -0.726125
+v -1.065738 0.156697 -0.716845
+v -1.074973 0.122343 -0.711131
+v -1.078091 0.086615 -0.709202
+v -1.074973 0.050887 -0.711131
+v -1.065738 0.016532 -0.716845
+v -1.050742 -0.015129 -0.726125
+v -1.030561 -0.042881 -0.738613
+v -1.005970 -0.065656 -0.753829
+v -0.977914 -0.082579 -0.771190
+v -0.947472 -0.093001 -0.790027
+v -0.944261 0.123101 -0.795974
+v -0.975586 0.137204 -0.783938
+v -1.007664 0.166926 -0.771946
+v -1.030584 0.203090 -0.763045
+v -1.060842 0.188359 -0.751290
+v -1.076960 0.156697 -0.744808
+v -1.086886 0.122343 -0.740816
+v -1.090238 0.086615 -0.739468
+v -1.086886 0.050887 -0.740816
+v -1.076960 0.016532 -0.744808
+v -1.060842 -0.015129 -0.751290
+v -1.039150 -0.042881 -0.760014
+v -1.012718 -0.065656 -0.770644
+v -0.982563 -0.082579 -0.782772
+v -0.949842 -0.093001 -0.795932
+v -0.945127 0.122652 -0.801955
+v -0.977082 0.135311 -0.795837
+v -1.008829 0.160888 -0.789698
+v -1.033925 0.195448 -0.784816
+v -1.065368 0.188359 -0.778698
+v -1.081990 0.156697 -0.775261
+v -1.092225 0.122343 -0.773145
+v -1.095681 0.086615 -0.772431
+v -1.092225 0.050887 -0.773145
+v -1.081990 0.016532 -0.775261
+v -1.065368 -0.015129 -0.778698
+v -1.042999 -0.042881 -0.783322
+v -1.015743 -0.065656 -0.788957
+v -0.984646 -0.082579 -0.795386
+v -0.950904 -0.093001 -0.802362
+v -0.944911 0.122893 -0.808257
+v -0.976676 0.135723 -0.808342
+v -1.008549 0.161499 -0.808326
+v -1.033513 0.196247 -0.807634
+v -1.064147 0.188359 -0.807293
+v -1.080633 0.156697 -0.807035
+v -1.090785 0.122343 -0.806876
+v -1.094213 0.086615 -0.806822
+v -1.090785 0.050887 -0.806876
+v -1.080633 0.016532 -0.807035
+v -1.064147 -0.015129 -0.807293
+v -1.041961 -0.042881 -0.807641
+v -1.014927 -0.065656 -0.808064
+v -0.984084 -0.082579 -0.808547
+v -0.950617 -0.093001 -0.809072
+v -0.943535 0.123924 -0.814504
+v -0.973927 0.138486 -0.820733
+v -1.005204 0.165323 -0.826896
+v -1.030109 0.201373 -0.830949
+v -1.057226 0.188359 -0.835978
+v -1.072942 0.156697 -0.838908
+v -1.082621 0.122343 -0.840712
+v -1.085889 0.086615 -0.841321
+v -1.082621 0.050887 -0.840712
+v -1.072942 0.016532 -0.838908
+v -1.057226 -0.015129 -0.835978
+v -1.036075 -0.042881 -0.832035
+v -1.010302 -0.065656 -0.827231
+v -0.980898 -0.082579 -0.821750
+v -0.948993 -0.093001 -0.815802
+v -0.940978 0.125439 -0.820358
+v -0.968637 0.142257 -0.832291
+v -0.996932 0.172381 -0.843906
+v -1.025553 0.216049 -0.855564
+v -1.044870 0.188359 -0.863650
+v -1.059213 0.156697 -0.869655
+v -1.068046 0.122343 -0.873353
+v -1.071028 0.086615 -0.874601
+v -1.068046 0.050887 -0.873353
+v -1.059213 0.016532 -0.869655
+v -1.044870 -0.015129 -0.863650
+v -1.025567 -0.042881 -0.855568
+v -1.002046 -0.065656 -0.845720
+v -0.975212 -0.082579 -0.834485
+v -0.946094 -0.093001 -0.822295
+v -0.937450 0.126946 -0.825647
+v -0.961464 0.145298 -0.842862
+v -0.986055 0.174750 -0.860010
+v -1.010841 0.216110 -0.877335
+v -1.027555 0.188359 -0.889245
+v -1.039974 0.156697 -0.898095
+v -1.047621 0.122343 -0.903544
+v -1.050203 0.086615 -0.905385
+v -1.047621 0.050887 -0.903544
+v -1.039974 0.016532 -0.898095
+v -1.027555 -0.015129 -0.889245
+v -1.010841 -0.042881 -0.877335
+v -0.990476 -0.065656 -0.862823
+v -0.967242 -0.082579 -0.846266
+v -0.942032 -0.093001 -0.828300
+v -0.933134 0.128348 -0.830246
+v -0.952672 0.148285 -0.852147
+v -0.972676 0.179365 -0.874011
+v -0.992464 0.216111 -0.896500
+v -1.005945 0.188359 -0.911780
+v -1.015962 0.156697 -0.923135
+v -1.022131 0.122343 -0.930127
+v -1.024214 0.086615 -0.932487
+v -1.022131 0.050887 -0.930127
+v -1.015962 0.016532 -0.923135
+v -1.005945 -0.015129 -0.911780
+v -0.992464 -0.042881 -0.896500
+v -0.976037 -0.065656 -0.877880
+v -0.957296 -0.082579 -0.856637
+v -0.936961 -0.093001 -0.833588
+v -0.928187 0.129502 -0.834049
+v -0.942604 0.150704 -0.859907
+v -0.957388 0.183964 -0.885989
+v -0.971141 0.216109 -0.912325
+v -0.980872 0.188359 -0.930389
+v -0.988102 0.156697 -0.943812
+v -0.992555 0.122343 -0.952078
+v -0.994059 0.086615 -0.954869
+v -0.992555 0.050887 -0.952078
+v -0.988103 0.016532 -0.943812
+v -0.980872 -0.015129 -0.930389
+v -0.971141 -0.042881 -0.912325
+v -0.959284 -0.065656 -0.890314
+v -0.945756 -0.082579 -0.865202
+v -0.931078 -0.093001 -0.837954
+v -0.922745 0.129042 -0.837001
+v -0.931452 0.151400 -0.865836
+v -0.940188 0.184892 -0.895103
+v -0.947692 0.216111 -0.924204
+v -0.953298 0.188359 -0.944357
+v -0.957465 0.156697 -0.959332
+v -0.960030 0.122343 -0.968554
+v -0.960896 0.086615 -0.971668
+v -0.960030 0.050887 -0.968554
+v -0.957465 0.016532 -0.959332
+v -0.953298 -0.015129 -0.944357
+v -0.947692 -0.042881 -0.924204
+v -0.940860 -0.065656 -0.899647
+v -0.933066 -0.082579 -0.871631
+v -0.924609 -0.093001 -0.841231
+v -0.916880 0.128290 -0.838922
+v -0.919681 0.151673 -0.869631
+v -0.922271 0.186622 -0.900985
+v -0.923018 0.216110 -0.931679
+v -0.924285 0.188359 -0.953147
+v -0.925226 0.156697 -0.969099
+v -0.925806 0.122343 -0.978922
+v -0.926002 0.086615 -0.982239
+v -0.925806 0.050887 -0.978922
+v -0.925226 0.016532 -0.969099
+v -0.924285 -0.015129 -0.953147
+v -0.923018 -0.042881 -0.931679
+v -0.921474 -0.065656 -0.905521
+v -0.919712 -0.082579 -0.875677
+v -0.917801 -0.093001 -0.843294
+v -0.910856 0.127918 -0.839532
+v -0.907678 0.150681 -0.871020
+v -0.904089 0.185445 -0.903392
+v -0.898066 0.216110 -0.934464
+v -0.894945 0.188359 -0.956421
+v -0.892626 0.156697 -0.972737
+v -0.891198 0.122343 -0.982784
+v -0.890715 0.086615 -0.986177
+v -0.891198 0.050887 -0.982784
+v -0.892626 0.016532 -0.972737
+v -0.894945 -0.015129 -0.956421
+v -0.898066 -0.042881 -0.934464
+v -0.901870 -0.065656 -0.907708
+v -0.906209 -0.082579 -0.877184
+v -0.910917 -0.093001 -0.844062
+v -0.904956 0.127171 -0.838878
+v -0.895610 0.147650 -0.869788
+v -0.885492 0.179325 -0.901411
+v -0.873797 0.216110 -0.932450
+v -0.866408 0.188359 -0.954054
+v -0.860917 0.156697 -0.970107
+v -0.857535 0.122343 -0.979992
+v -0.856394 0.086615 -0.983330
+v -0.857535 0.050887 -0.979992
+v -0.860917 0.016532 -0.970107
+v -0.866408 -0.015129 -0.954054
+v -0.873797 -0.042881 -0.932450
+v -0.882801 -0.065656 -0.906127
+v -0.893074 -0.082579 -0.876094
+v -0.904221 -0.093001 -0.843507
+v -0.899294 0.127919 -0.836889
+v -0.884081 0.144468 -0.866086
+v -0.868120 0.174695 -0.895671
+v -0.851143 0.216110 -0.925717
+v -0.839769 0.188359 -0.946136
+v -0.831317 0.156697 -0.961308
+v -0.826113 0.122343 -0.970652
+v -0.824355 0.086615 -0.973807
+v -0.826113 0.050887 -0.970652
+v -0.831317 0.016532 -0.961308
+v -0.839769 -0.015129 -0.946136
+v -0.851143 -0.042881 -0.925717
+v -0.865002 -0.065656 -0.900836
+v -0.880814 -0.082579 -0.872450
+v -0.897971 -0.093001 -0.841649
+v -0.894021 0.126810 -0.833847
+v -0.873585 0.143014 -0.860071
+v -0.852517 0.173311 -0.886802
+v -0.830973 0.216110 -0.914521
+v -0.816052 0.188359 -0.932971
+v -0.804965 0.156697 -0.946681
+v -0.798137 0.122343 -0.955123
+v -0.795832 0.086615 -0.957974
+v -0.798137 0.050887 -0.955123
+v -0.804965 0.016532 -0.946681
+v -0.816052 -0.015129 -0.932971
+v -0.830973 -0.042881 -0.914521
+v -0.849155 -0.065656 -0.892040
+v -0.869898 -0.082579 -0.866391
+v -0.892406 -0.093001 -0.838560
+v -0.889469 0.126849 -0.829710
+v -0.864688 0.144003 -0.851969
+v -0.839410 0.174862 -0.874905
+v -0.814065 0.216110 -0.899294
+v -0.796169 0.188359 -0.915066
+v -0.782872 0.156697 -0.926786
+v -0.774684 0.122343 -0.934003
+v -0.771919 0.086615 -0.936440
+v -0.774684 0.050887 -0.934003
+v -0.782872 0.016532 -0.926786
+v -0.796169 -0.015129 -0.915066
+v -0.814065 -0.042881 -0.899294
+v -0.835870 -0.065656 -0.880076
+v -0.860747 -0.082579 -0.858150
+v -0.887741 -0.093001 -0.834359
+v -0.885964 0.128240 -0.824736
+v -0.857824 0.146043 -0.842318
+v -0.829233 0.178931 -0.860559
+v -0.801066 0.216110 -0.880621
+v -0.780884 0.188359 -0.893109
+v -0.765888 0.156697 -0.902389
+v -0.756654 0.122343 -0.908103
+v -0.753536 0.086615 -0.910032
+v -0.756654 0.050887 -0.908103
+v -0.765888 0.016532 -0.902389
+v -0.780884 -0.015129 -0.893109
+v -0.801066 -0.042881 -0.880621
+v -0.825657 -0.065656 -0.865405
+v -0.853712 -0.082579 -0.848044
+v -0.884154 -0.093001 -0.829207
+v -0.883748 0.130413 -0.819310
+v -0.853554 0.149753 -0.831679
+v -0.822847 0.184895 -0.844910
+v -0.792477 0.216110 -0.859220
+v -0.770785 0.188359 -0.867944
+v -0.754666 0.156697 -0.874426
+v -0.744740 0.122343 -0.878418
+v -0.741389 0.086615 -0.879766
+v -0.744740 0.050887 -0.878418
+v -0.754666 0.016532 -0.874426
+v -0.770785 -0.015129 -0.867944
+v -0.792477 -0.042881 -0.859220
+v -0.818908 -0.065656 -0.848589
+v -0.849064 -0.082579 -0.836462
+v -0.881785 -0.093001 -0.823302
+v -0.882854 0.132691 -0.813648
+v -0.851758 0.151597 -0.820254
+v -0.820580 0.180369 -0.827765
+v -0.788627 0.216110 -0.835912
+v -0.766258 0.188359 -0.840536
+v -0.749637 0.156697 -0.843973
+v -0.739401 0.122343 -0.846089
+v -0.735945 0.086615 -0.846803
+v -0.739401 0.050887 -0.846089
+v -0.749637 0.016532 -0.843973
+v -0.766258 -0.015129 -0.840536
+v -0.788627 -0.042881 -0.835912
+v -0.815884 -0.065656 -0.830277
+v -0.846981 -0.082579 -0.823848
+v -0.880723 -0.093001 -0.816872
+v -0.883030 0.134321 -0.807614
+v -0.852360 0.153154 -0.808200
+v -0.821482 0.179462 -0.809593
+v -0.789666 0.216110 -0.811593
+v -0.767479 0.188359 -0.811941
+v -0.750994 0.156697 -0.812199
+v -0.740842 0.122343 -0.812358
+v -0.737414 0.086615 -0.812412
+v -0.740842 0.050887 -0.812358
+v -0.750994 0.016532 -0.812199
+v -0.767479 -0.015129 -0.811941
+v -0.789666 -0.042881 -0.811593
+v -0.816700 -0.065656 -0.811170
+v -0.847543 -0.082579 -0.810687
+v -0.881009 -0.093001 -0.810162
+v -0.884243 0.136298 -0.801513
+v -0.855270 0.153953 -0.796135
+v -0.825879 0.181847 -0.791462
+v -0.795552 0.216110 -0.787199
+v -0.774401 0.188359 -0.783256
+v -0.758684 0.156697 -0.780326
+v -0.749006 0.122343 -0.778522
+v -0.745738 0.086615 -0.777913
+v -0.749006 0.050887 -0.778522
+v -0.758684 0.016532 -0.780326
+v -0.774401 -0.015129 -0.783256
+v -0.795552 -0.042881 -0.787199
+v -0.821325 -0.065656 -0.792003
+v -0.850728 -0.082579 -0.797484
+v -0.882633 -0.093001 -0.803432
+v -0.886581 0.138241 -0.795686
+v -0.860284 0.155550 -0.784594
+v -0.833500 0.185355 -0.774090
+v -0.806060 0.216110 -0.763666
+v -0.786757 0.188359 -0.755584
+v -0.772413 0.156697 -0.749579
+v -0.763581 0.122343 -0.745881
+v -0.760598 0.086615 -0.744633
+v -0.763581 0.050887 -0.745881
+v -0.772413 0.016532 -0.749579
+v -0.786757 -0.015129 -0.755584
+v -0.806060 -0.042881 -0.763666
+v -0.829580 -0.065656 -0.773514
+v -0.856415 -0.082579 -0.784748
+v -0.885532 -0.093001 -0.796939
+v -0.915813 -0.096520 -0.809617
+v -0.890038 0.139261 -0.790392
+v -0.867286 0.157379 -0.773981
+v -0.844186 0.189447 -0.758088
+v -0.820785 0.216110 -0.741899
+v -0.804072 0.188359 -0.729989
+v -0.791653 0.156697 -0.721139
+v -0.784005 0.122343 -0.715690
+v -0.781423 0.086615 -0.713849
+v -0.784006 0.050887 -0.715690
+v -0.791653 0.016532 -0.721139
+v -0.804072 -0.015129 -0.729989
+v -0.820785 -0.042881 -0.741899
+v -0.841150 -0.065656 -0.756411
+v -0.864384 -0.082579 -0.772968
+v -0.889595 -0.093001 -0.790934
+v -0.894322 0.139212 -0.785920
+v -0.876044 0.159367 -0.764598
+v -0.857691 0.195978 -0.743844
+v -0.839163 0.216110 -0.722734
+v -0.825682 0.188359 -0.707454
+v -0.815664 0.156697 -0.696100
+v -0.809496 0.122343 -0.689107
+v -0.807413 0.086615 -0.686747
+v -0.809496 0.050887 -0.689107
+v -0.815664 0.016532 -0.696100
+v -0.825682 -0.015129 -0.707454
+v -0.839163 -0.042881 -0.722734
+v -0.855589 -0.065656 -0.741354
+v -0.874330 -0.082579 -0.762596
+v -0.894665 -0.093001 -0.785646
+v -0.899407 0.136902 -0.782364
+v -0.886212 0.160376 -0.756934
+v -0.873610 0.206155 -0.731793
+v -0.860485 0.216111 -0.706908
+v -0.850755 0.188359 -0.688845
+v -0.843524 0.156697 -0.675422
+v -0.839072 0.122343 -0.667156
+v -0.837568 0.086615 -0.664366
+v -0.839072 0.050887 -0.667156
+v -0.843524 0.016532 -0.675422
+v -0.850755 -0.015129 -0.688845
+v -0.860486 -0.042881 -0.706909
+v -0.872343 -0.065656 -0.728920
+v -0.885870 -0.082579 -0.754032
+v -0.900548 -0.093001 -0.781280
+v -0.905213 0.133682 -0.779686
+v -0.897519 0.154168 -0.751266
+v -0.891018 0.190104 -0.722776
+v -0.883939 0.216085 -0.695043
+v -0.878328 0.188359 -0.674877
+v -0.874162 0.156697 -0.659902
+v -0.871597 0.122343 -0.650680
+v -0.870730 0.086615 -0.647566
+v -0.871597 0.050887 -0.650680
+v -0.874162 0.016532 -0.659902
+v -0.878328 -0.015129 -0.674877
+v -0.883935 -0.042881 -0.695030
+v -0.890767 -0.065656 -0.719586
+v -0.898561 -0.082579 -0.747603
+v -0.907018 -0.093001 -0.778003
+v -0.911472 0.130539 -0.777970
+v -0.909697 0.147283 -0.747585
+v -0.908971 0.177925 -0.716975
+v -0.908611 0.216063 -0.687581
+v -0.907342 0.188359 -0.666087
+v -0.906401 0.156697 -0.650135
+v -0.905821 0.122343 -0.640312
+v -0.905625 0.086615 -0.636995
+v -0.905821 0.050887 -0.640312
+v -0.906401 0.016532 -0.650135
+v -0.907342 -0.015129 -0.666087
+v -0.908609 -0.042881 -0.687555
+v -0.910153 -0.065656 -0.713713
+v -0.911914 -0.082579 -0.743557
+v -0.913826 -0.093001 -0.775940
+v -0.917902 0.128120 -0.777332
+v -0.922567 0.142034 -0.746162
+v -0.927843 0.174388 -0.715452
+v -0.933559 0.216099 -0.684777
+v -0.936682 0.188359 -0.662813
+v -0.939001 0.156697 -0.646497
+v -0.940429 0.122343 -0.636450
+v -0.940911 0.086615 -0.633057
+v -0.940429 0.050887 -0.636450
+v -0.939001 0.016532 -0.646497
+v -0.936682 -0.015129 -0.662813
+v -0.933560 -0.042881 -0.684770
+v -0.929757 -0.065656 -0.711526
+v -0.925418 -0.082579 -0.742050
+v -0.920710 -0.093001 -0.775172
+v -0.924157 0.126903 -0.777864
+v -0.934944 0.144173 -0.747654
+v -0.946151 0.174107 -0.717342
+v -0.957829 0.216110 -0.686784
+v -0.965219 0.188359 -0.665180
+v -0.970710 0.156697 -0.649127
+v -0.974091 0.122343 -0.639242
+v -0.975233 0.086615 -0.635904
+v -0.974091 0.050887 -0.639242
+v -0.970710 0.016532 -0.649127
+v -0.965219 -0.015129 -0.665180
+v -0.957829 -0.042881 -0.686784
+v -0.948825 -0.065656 -0.713107
+v -0.938552 -0.082579 -0.743140
+v -0.927406 -0.093001 -0.775727
+v -0.929866 0.126199 -0.779497
+v -0.946461 0.143623 -0.750732
+v -0.963214 0.173672 -0.722347
+v -0.980484 0.216110 -0.693517
+v -0.991858 0.188359 -0.673098
+v -1.000310 0.156697 -0.657926
+v -1.005514 0.122343 -0.648582
+v -1.007271 0.086615 -0.645427
+v -1.005514 0.050887 -0.648582
+v -1.000310 0.016532 -0.657925
+v -0.991858 -0.015129 -0.673098
+v -0.980484 -0.042881 -0.693517
+v -0.966625 -0.065656 -0.718398
+v -0.950813 -0.082579 -0.746784
+v -0.933656 -0.093001 -0.777585
+v -0.913940 0.125338 -0.808007
+v -0.934807 0.125877 -0.782239
+v -0.956393 0.142260 -0.756222
+v -0.978324 0.173236 -0.730608
+v -1.000652 0.216104 -0.704714
+v -1.015574 0.188359 -0.686263
+v -1.026662 0.156697 -0.672553
+v -1.033490 0.122343 -0.664111
+v -1.035795 0.086615 -0.661260
+v -1.033490 0.050887 -0.664111
+v -1.026662 0.016532 -0.672553
+v -1.015574 -0.015129 -0.686263
+v -1.000653 -0.042881 -0.704713
+v -0.982472 -0.065656 -0.727194
+v -0.961728 -0.082579 -0.752843
+v -0.939221 -0.093001 -0.780674
+v -0.938915 0.124942 -0.785940
+v -0.964687 0.141063 -0.763793
+v -0.990995 0.171360 -0.741843
+v -1.012732 0.204442 -0.723513
+v -1.035457 0.188359 -0.704168
+v -1.048754 0.156697 -0.692448
+v -1.056943 0.122343 -0.685231
+v -1.059708 0.086615 -0.682794
+v -1.056943 0.050887 -0.685231
+v -1.048754 0.016532 -0.692448
+v -1.035457 -0.015129 -0.704168
+v -1.017562 -0.042881 -0.719940
+v -0.995757 -0.065656 -0.739158
+v -0.970879 -0.082579 -0.761084
+v -0.943886 -0.093001 -0.784875
+vn -0.861873 0.201025 0.465529
+vn -0.809168 0.392834 0.436903
+vn -0.887997 0.386761 0.248665
+vn 0.394879 0.839015 -0.374310
+vn 0.094180 0.969878 -0.224616
+vn 0.142857 0.980804 -0.132603
+vn -0.480361 -0.838008 0.258736
+vn -0.613453 -0.717124 0.330729
+vn -0.532456 -0.833369 0.148076
+vn -0.879818 0.000000 0.475295
+vn -0.943876 0.197516 0.264595
+vn 0.590258 0.691916 -0.415693
+vn 0.474441 0.846034 -0.243110
+vn -0.331217 -0.926572 0.178137
+vn -0.368175 -0.924131 0.101962
+vn -0.861873 -0.201025 0.465529
+vn -0.943907 -0.197516 0.264595
+vn 0.189673 0.975921 -0.107700
+vn 0.702384 0.658223 -0.270852
+vn -0.171422 -0.980865 0.091922
+vn -0.190832 -0.980193 0.052400
+vn -0.809168 -0.392834 0.436903
+vn -0.887997 -0.386761 0.248665
+vn -0.605640 0.725700 0.326365
+vn 0.164586 0.966399 -0.197302
+vn -0.724815 -0.567095 0.391125
+vn -0.797845 -0.560015 0.223029
+vn -0.655782 0.738701 0.155553
+vn -0.677633 -0.710685 0.188971
+vn -0.711539 -0.701315 0.042573
+vn -0.924009 0.378124 0.056398
+vn 0.155950 0.987335 -0.028169
+vn -0.561846 -0.826563 0.033082
+vn -0.962828 0.000000 0.269997
+vn -0.979430 0.192572 0.060091
+vn 0.498184 0.863155 -0.082034
+vn -0.389996 -0.920530 0.022462
+vn -0.979430 -0.192572 0.060091
+vn 0.703879 0.698325 -0.129795
+vn -0.202521 -0.979186 0.011109
+vn -0.924009 -0.378124 0.056398
+vn 0.289987 0.948912 -0.124119
+vn -0.833705 -0.549883 0.050478
+vn -0.624317 0.780145 0.039735
+vn -0.834376 -0.538530 -0.117313
+vn -0.651082 0.755608 -0.071535
+vn -0.715964 -0.690725 -0.101138
+vn -0.920560 0.368603 -0.128971
+vn 0.161199 0.979705 0.118992
+vn -0.568407 -0.818751 -0.080813
+vn -0.998108 0.000000 0.061342
+vn -0.972869 0.187139 -0.135990
+vn 0.502365 0.849117 0.163060
+vn -0.396313 -0.916318 -0.056887
+vn -0.972869 -0.187139 -0.135990
+vn 0.718192 0.680074 0.147099
+vn -0.206183 -0.978027 -0.030183
+vn -0.920560 -0.368603 -0.128971
+vn 0.332011 0.932249 0.143742
+vn -0.202002 -0.976867 -0.069918
+vn -0.883328 -0.359722 -0.300485
+vn 0.224616 0.896847 0.380993
+vn -0.803980 -0.527818 -0.273812
+vn -0.724967 0.662526 -0.188147
+vn -0.693411 -0.680563 -0.236610
+vn -0.883328 0.359722 -0.300485
+vn 0.152043 0.954375 0.256935
+vn -0.553331 -0.811121 -0.189276
+vn -0.990356 0.000000 -0.138340
+vn -0.930937 0.182104 -0.316446
+vn 0.647175 0.650899 0.396802
+vn -0.387463 -0.912198 -0.133030
+vn -0.930937 -0.182104 -0.316446
+vn 0.461715 0.803247 0.376232
+vn 0.588702 0.623493 0.514420
+vn -0.364360 -0.908750 -0.203345
+vn -0.946806 0.000000 -0.321757
+vn -0.860256 -0.178137 -0.477645
+vn -0.084719 0.987396 0.133488
+vn -0.190283 -0.975890 -0.106662
+vn -0.818018 -0.352641 -0.454360
+vn -0.747002 -0.519181 -0.415174
+vn -0.746849 0.519608 -0.414899
+vn -0.646901 -0.672262 -0.359874
+vn -0.818018 0.352641 -0.454360
+vn 0.428510 0.772362 0.468825
+vn -0.518448 -0.804834 -0.288797
+vn -0.860256 0.178137 -0.477645
+vn -0.729270 0.348094 -0.589038
+vn 0.136876 0.934690 0.327982
+vn 0.369884 0.764306 0.528153
+vn -0.465773 -0.800714 -0.376690
+vn -0.874264 0.000000 -0.485366
+vn -0.765893 0.175604 -0.618519
+vn 0.524979 0.645924 0.554186
+vn -0.328166 -0.906461 -0.265633
+vn -0.765893 -0.175604 -0.618519
+vn -0.171667 -0.975249 -0.139225
+vn -0.729270 -0.348094 -0.589038
+vn -0.030244 0.999146 -0.027039
+vn -0.667379 -0.513627 -0.539201
+vn -0.667379 0.513627 -0.539201
+vn -0.579516 -0.666860 -0.468398
+vn -0.568072 -0.511704 -0.644520
+vn -0.568072 0.511704 -0.644520
+vn -0.493789 -0.664968 -0.560259
+vn -0.620228 0.346538 -0.703696
+vn 0.113315 0.925291 0.361888
+vn 0.312662 0.748924 0.584246
+vn -0.397351 -0.799249 -0.450850
+vn -0.777978 0.000000 -0.628254
+vn -0.651021 0.174718 -0.738639
+vn 0.385876 0.662557 0.641926
+vn -0.280313 -0.905667 -0.318033
+vn -0.651021 -0.174718 -0.738639
+vn -0.047487 0.998260 -0.034089
+vn -0.146794 -0.975036 -0.166570
+vn -0.620228 -0.346538 -0.703696
+vn -0.222327 -0.906461 -0.358989
+vn -0.517441 -0.175573 -0.837489
+vn -0.451125 0.513596 -0.729850
+vn -0.492782 -0.348064 -0.797479
+vn -0.492782 0.348064 -0.797479
+vn -0.451125 -0.513565 -0.729850
+vn -0.517441 0.175573 -0.837489
+vn 0.094211 0.919401 0.381848
+vn 0.285684 0.740074 0.608783
+vn -0.391919 -0.666799 -0.633808
+vn -0.661184 0.000000 -0.750175
+vn -0.525559 0.000000 -0.850734
+vn 0.319163 0.676260 0.663900
+vn -0.315226 -0.800653 -0.509445
+vn -0.058168 0.996155 -0.065340
+vn 0.244942 0.685903 0.685171
+vn -0.221473 -0.804743 -0.550707
+vn -0.371807 0.000000 -0.928281
+vn -0.043703 0.994903 -0.090762
+vn -0.116581 -0.975249 -0.187811
+vn -0.156041 -0.908719 -0.387097
+vn -0.365917 -0.178076 -0.913419
+vn -0.318155 0.519089 -0.793268
+vn -0.348125 -0.352550 -0.868618
+vn -0.348125 0.352550 -0.868618
+vn -0.318155 -0.519089 -0.793268
+vn -0.365917 0.178076 -0.913419
+vn 0.166204 0.917997 0.359996
+vn 0.236641 0.738182 0.631703
+vn -0.275857 -0.672170 -0.687063
+vn -0.197211 0.182043 -0.963286
+vn 0.235359 0.912442 0.334666
+vn 0.169317 0.729820 0.662282
+vn -0.147832 -0.680410 -0.717734
+vn -0.200507 0.000000 -0.979675
+vn 0.147557 0.690542 0.708029
+vn -0.118442 -0.811029 -0.572863
+vn -0.033296 0.993622 -0.107547
+vn -0.081942 -0.975890 -0.202216
+vn -0.083438 -0.912137 -0.401227
+vn -0.197211 -0.182043 -0.963286
+vn -0.170873 0.527665 -0.832057
+vn -0.187353 -0.359600 -0.914090
+vn -0.187353 0.359600 -0.914090
+vn -0.170873 -0.527665 -0.832057
+vn -0.012696 -0.368450 -0.929533
+vn -0.012696 0.368450 -0.929533
+vn -0.011902 -0.538347 -0.842616
+vn -0.013123 0.187048 -0.982238
+vn 0.163793 0.919126 0.358226
+vn 0.124119 0.733299 0.668477
+vn -0.010712 -0.690542 -0.723167
+vn -0.013276 0.000000 -0.999908
+vn 0.119846 0.670827 0.731834
+vn -0.009033 -0.818628 -0.574236
+vn -0.004913 0.993805 -0.110752
+vn -0.044038 -0.976836 -0.209235
+vn -0.006806 -0.916257 -0.400464
+vn -0.013123 -0.187048 -0.982238
+vn -0.011902 0.538347 -0.842616
+vn -0.004120 -0.977996 -0.208441
+vn 0.071078 -0.920469 -0.384289
+vn 0.182073 -0.192480 -0.964232
+vn 0.154302 0.549699 -0.820948
+vn 0.171484 -0.378002 -0.909757
+vn 0.171484 0.378002 -0.909757
+vn 0.154302 -0.549699 -0.820948
+vn 0.182073 0.192480 -0.964232
+vn 0.086184 0.925077 0.369793
+vn -0.064669 0.946013 0.317515
+vn 0.131230 -0.701163 -0.700797
+vn 0.185644 0.000000 -0.982604
+vn 0.061098 0.764367 0.641865
+vn 0.103092 -0.826441 -0.553453
+vn 0.023621 0.996399 -0.081210
+vn 0.213416 -0.833277 -0.509964
+vn 0.388104 0.000000 -0.921598
+vn 0.023347 0.660939 0.750053
+vn 0.026734 0.998230 -0.052797
+vn 0.036348 -0.979186 -0.199622
+vn 0.147160 -0.924070 -0.352672
+vn 0.380383 -0.197455 -0.903500
+vn 0.320933 0.559893 -0.763848
+vn 0.357585 -0.386639 -0.850063
+vn 0.357585 0.386639 -0.850063
+vn 0.320933 -0.559893 -0.763848
+vn 0.380383 0.197455 -0.903500
+vn -0.084780 0.949034 0.303476
+vn 0.272164 -0.710532 -0.648854
+vn -0.090457 0.807550 0.582781
+vn -0.091128 0.962859 0.254067
+vn 0.404706 -0.717032 -0.567461
+vn 0.581317 0.000000 -0.813654
+vn -0.194952 0.679647 0.707144
+vn -0.317576 0.829768 0.458876
+vn 0.316660 -0.837947 -0.444411
+vn 0.027711 0.998840 -0.038850
+vn 0.075838 -0.980193 -0.182867
+vn 0.218085 -0.926542 -0.306467
+vn 0.569384 -0.200995 -0.797082
+vn 0.478500 0.567003 -0.670431
+vn 0.534410 -0.392773 -0.748375
+vn 0.534410 0.392773 -0.748375
+vn 0.478500 -0.567003 -0.670431
+vn 0.569384 0.200995 -0.797082
+vn 0.688894 0.395001 -0.607746
+vn 0.616321 -0.569597 -0.543718
+vn 0.734367 0.202277 -0.647877
+vn -0.496139 0.814081 0.301798
+vn 0.520859 -0.719382 -0.459517
+vn 0.749870 0.000000 -0.661550
+vn -0.421827 0.695151 0.582049
+vn -0.596637 0.698996 0.394177
+vn 0.407270 -0.839625 -0.359294
+vn 0.035035 0.998749 -0.034913
+vn 0.112613 -0.980865 -0.158666
+vn 0.280435 -0.927427 -0.247414
+vn 0.734367 -0.202277 -0.647877
+vn 0.616321 0.569597 -0.543718
+vn 0.688894 -0.395001 -0.607746
+vn 0.809168 -0.392834 -0.436903
+vn 0.052553 0.997986 -0.034700
+vn 0.724845 -0.567095 -0.391125
+vn 0.724845 0.567095 -0.391125
+vn 0.613453 -0.717124 -0.330729
+vn 0.809168 0.392834 -0.436903
+vn -0.268136 0.958678 0.094790
+vn -0.612995 0.781426 0.116489
+vn 0.480361 -0.838008 -0.258736
+vn 0.861873 0.201025 -0.465529
+vn -0.699850 0.692343 0.175634
+vn 0.331217 -0.926572 -0.178137
+vn 0.861873 -0.201025 -0.465529
+vn 0.144963 -0.981109 -0.127903
+vn 0.171422 -0.980865 -0.091922
+vn 0.368175 -0.924131 -0.101962
+vn 0.879818 0.000000 -0.475295
+vn 0.943907 -0.197516 -0.264595
+vn 0.078158 0.996704 -0.021363
+vn 0.190832 -0.980193 -0.052400
+vn 0.887997 -0.386761 -0.248665
+vn 0.797845 -0.560015 -0.223029
+vn 0.797845 0.560015 -0.223029
+vn 0.677633 -0.710685 -0.188971
+vn 0.887997 0.386761 -0.248665
+vn -0.388928 0.916501 -0.093387
+vn -0.661489 0.749840 -0.011048
+vn 0.532456 -0.833369 -0.148076
+vn 0.943907 0.197516 -0.264595
+vn -0.682669 0.715537 0.148015
+vn -0.437452 0.870724 -0.224525
+vn -0.430403 0.866634 -0.252235
+vn 0.561846 -0.826563 -0.033082
+vn 0.962828 0.000000 -0.269997
+vn 0.979430 0.192572 -0.060091
+vn -0.628407 0.775262 -0.063478
+vn 0.389996 -0.920530 -0.022462
+vn 0.979430 -0.192572 -0.060091
+vn -0.678762 0.723991 0.122898
+vn 0.202490 -0.979186 -0.011109
+vn 0.924009 -0.378124 -0.056398
+vn 0.075320 0.997131 0.005707
+vn 0.833705 -0.549883 -0.050478
+vn 0.833705 0.549883 -0.050478
+vn 0.711539 -0.701315 -0.042573
+vn 0.924009 0.378124 -0.056398
+vn 0.834376 0.538530 0.117313
+vn 0.715995 -0.690725 0.101138
+vn 0.920560 0.368603 0.128971
+vn -0.399030 0.868129 -0.295114
+vn 0.568407 -0.818751 0.080813
+vn 0.998108 0.000000 -0.061373
+vn 0.972839 0.187139 0.135990
+vn -0.590625 0.791253 -0.158269
+vn 0.396313 -0.916318 0.056887
+vn 0.972839 -0.187139 0.135990
+vn -0.701682 0.700797 -0.128239
+vn 0.206183 -0.978027 0.030183
+vn 0.920560 -0.368603 0.128971
+vn 0.070742 0.997406 0.011719
+vn 0.834376 -0.538530 0.117313
+vn 0.883328 -0.359722 0.300485
+vn 0.082125 0.996277 0.024995
+vn 0.803980 -0.527818 0.273812
+vn 0.803980 0.527818 0.273812
+vn 0.693411 -0.680563 0.236610
+vn 0.883328 0.359722 0.300485
+vn -0.353648 0.861049 -0.365368
+vn 0.553362 -0.811121 0.189276
+vn 0.990356 0.000000 0.138340
+vn 0.930937 0.182104 0.316446
+vn -0.557207 0.784204 -0.272958
+vn 0.387463 -0.912198 0.133030
+vn 0.930937 -0.182104 0.316446
+vn -0.661977 0.674215 -0.327342
+vn 0.202002 -0.976867 0.069918
+vn 0.364360 -0.908750 0.203345
+vn 0.946806 0.000000 0.321757
+vn 0.860256 -0.178137 0.477676
+vn -0.585620 0.668844 -0.457839
+vn 0.190283 -0.975890 0.106662
+vn 0.818018 -0.352641 0.454360
+vn 0.099612 0.993957 0.046022
+vn 0.747002 -0.519181 0.415174
+vn 0.747002 0.519181 0.415174
+vn 0.646901 -0.672262 0.359874
+vn 0.818018 0.352641 0.454360
+vn -0.511399 0.759301 -0.402326
+vn 0.518448 -0.804834 0.288797
+vn 0.860256 0.178137 0.477645
+vn 0.465773 -0.800714 0.376690
+vn 0.874264 0.000000 0.485397
+vn 0.765893 0.175604 0.618519
+vn -0.463149 0.689291 -0.557085
+vn 0.328166 -0.906461 0.265633
+vn 0.765893 -0.175604 0.618519
+vn 0.171667 -0.975249 0.139225
+vn 0.729270 -0.348094 0.589038
+vn 0.099399 0.991485 0.083743
+vn 0.667379 -0.513627 0.539201
+vn 0.667379 0.513627 0.539201
+vn 0.579516 -0.666860 0.468398
+vn 0.729270 0.348094 0.589038
+vn -0.317911 0.862300 -0.394116
+vn -0.449049 0.737602 -0.504227
+vn 0.493789 -0.664998 0.560259
+vn 0.620228 0.346538 0.703696
+vn -0.344127 0.863186 -0.369366
+vn -0.418256 0.689077 -0.591754
+vn 0.397351 -0.799249 0.450850
+vn 0.777978 0.000000 0.628254
+vn 0.651021 0.174718 0.738639
+vn -0.235389 0.724601 -0.647694
+vn 0.280313 -0.905667 0.318033
+vn 0.651021 -0.174718 0.738639
+vn 0.132908 0.984802 0.111545
+vn 0.146794 -0.975036 0.166570
+vn 0.620228 -0.346538 0.703696
+vn 0.568072 -0.511704 0.644520
+vn 0.568072 0.511704 0.644520
+vn 0.451125 0.513565 0.729850
+vn 0.492782 -0.348064 0.797479
+vn 0.492782 0.348064 0.797479
+vn 0.451125 -0.513565 0.729850
+vn 0.517441 0.175573 0.837489
+vn -0.451216 0.846889 -0.281289
+vn -0.526963 0.814142 -0.243812
+vn 0.391919 -0.666799 0.633808
+vn 0.661184 0.000000 0.750175
+vn 0.525559 0.000000 0.850734
+vn -0.366588 0.825587 -0.428938
+vn 0.315226 -0.800653 0.509445
+vn 0.090823 0.976196 0.196814
+vn 0.222327 -0.906461 0.358989
+vn 0.517441 -0.175573 0.837489
+vn 0.371807 0.000000 0.928281
+vn -0.623188 0.634205 -0.457564
+vn 0.116581 -0.975249 0.187811
+vn 0.156041 -0.908719 0.387097
+vn 0.365917 -0.178076 0.913419
+vn 0.318033 0.519303 0.793176
+vn 0.348125 -0.352550 0.868618
+vn 0.348125 0.352550 0.868618
+vn 0.318155 -0.519089 0.793268
+vn 0.365917 0.178076 0.913419
+vn -0.512467 0.624989 -0.588794
+vn -0.520829 0.813623 -0.258309
+vn 0.275857 -0.672170 0.687063
+vn -0.570544 0.649983 -0.501968
+vn 0.221473 -0.804743 0.550707
+vn 0.147832 -0.680410 0.717734
+vn 0.200507 0.000000 0.979675
+vn -0.453413 0.716880 -0.529557
+vn 0.118442 -0.811029 0.572863
+vn -0.000916 0.994751 0.102298
+vn -0.361278 0.629170 -0.688162
+vn 0.081942 -0.975890 0.202246
+vn 0.083438 -0.912137 0.401227
+vn 0.197211 -0.182043 0.963286
+vn 0.170751 0.528184 0.831751
+vn 0.187353 -0.359600 0.914090
+vn 0.187353 0.359600 0.914090
+vn 0.170873 -0.527665 0.832057
+vn 0.197211 0.182043 0.963286
+vn -0.427473 0.859035 -0.281533
+vn 0.011902 -0.538347 0.842616
+vn 0.013123 0.187048 0.982238
+vn -0.241737 0.920347 -0.307382
+vn 0.010712 -0.690542 0.723167
+vn 0.013276 0.000000 0.999908
+vn -0.077853 0.826014 -0.558214
+vn 0.009033 -0.818628 0.574236
+vn 0.016114 0.999054 0.040284
+vn 0.003021 0.999298 0.036927
+vn 0.044038 -0.976836 0.209235
+vn 0.006806 -0.916257 0.400464
+vn 0.013123 -0.187048 0.982238
+vn 0.012024 0.538621 0.842433
+vn 0.012696 -0.368450 0.929533
+vn 0.012696 0.368450 0.929533
+vn -0.154271 0.549730 0.820948
+vn -0.171484 -0.378002 0.909757
+vn -0.171484 0.378002 0.909757
+vn -0.154332 -0.549699 0.820948
+vn -0.182073 0.192480 0.964232
+vn 0.154027 0.811884 -0.563097
+vn -0.131230 -0.701163 0.700797
+vn -0.185675 0.000000 0.982604
+vn -0.054781 0.636555 -0.769250
+vn 0.137852 0.661641 -0.736991
+vn -0.103092 -0.826441 0.553453
+vn 0.002106 0.999268 0.037935
+vn 0.004120 -0.977996 0.208441
+vn -0.071078 -0.920469 0.384289
+vn -0.182073 -0.192480 0.964232
+vn -0.388104 0.000000 0.921598
+vn -0.010132 0.999207 0.038087
+vn -0.036348 -0.979186 0.199622
+vn -0.147160 -0.924070 0.352672
+vn -0.380383 -0.197455 0.903500
+vn -0.320933 0.559893 0.763848
+vn -0.357585 -0.386639 0.850063
+vn -0.357585 0.386639 0.850063
+vn -0.320933 -0.559893 0.763848
+vn -0.380383 0.197455 0.903500
+vn -0.087680 0.942198 -0.323313
+vn 0.161962 0.802240 -0.574541
+vn -0.272134 -0.710532 0.648854
+vn 0.266884 0.674306 -0.688498
+vn -0.213416 -0.833277 0.509964
+vn -0.404706 -0.717032 0.567461
+vn -0.581317 0.000000 0.813654
+vn 0.383526 0.676107 -0.629078
+vn -0.316660 -0.837947 0.444441
+vn -0.134465 0.988800 -0.064394
+vn -0.075838 -0.980193 0.182867
+vn -0.218085 -0.926542 0.306467
+vn -0.569384 -0.200995 0.797082
+vn -0.478500 0.567064 0.670400
+vn -0.534410 -0.392773 0.748375
+vn -0.534410 0.392773 0.748375
+vn -0.478500 -0.567003 0.670431
+vn -0.569384 0.200995 0.797082
+vn 0.022523 0.957884 -0.286233
+vn 0.260842 0.812372 -0.521470
+vn -0.616321 -0.569597 0.543718
+vn -0.734367 0.202277 0.647877
+vn 0.057894 0.960967 -0.270486
+vn 0.049989 0.958129 -0.281869
+vn -0.520829 -0.719382 0.459517
+vn -0.749870 0.000000 0.661550
+vn 0.336131 0.820551 -0.462233
+vn -0.407270 -0.839625 0.359294
+vn 0.446883 0.688650 -0.570971
+vn -0.112613 -0.980865 0.158666
+vn -0.280435 -0.927427 0.247414
+vn -0.734367 -0.202277 0.647877
+vn -0.592700 0.669393 0.447829
+vn -0.688894 -0.395001 0.607746
+vn -0.688894 0.395001 0.607746
+vn -0.159246 0.985504 -0.057985
+vn -0.144963 -0.981109 0.127903
+vn -0.023957 0.937956 -0.345897
+usemtl Body
+s 1
+f 5309//3529 5308//3530 5323//3531
+f 5304//3532 5303//3533 5318//3534
+f 5315//3535 5314//3536 5330//3537
+f 5310//3538 5309//3529 5324//3539
+f 5305//3540 5304//3532 5319//3541
+f 5316//3542 5315//3535 5331//3543
+f 5311//3544 5310//3538 5326//3545
+f 5306//3546 5305//3540 5320//3547
+f 5317//3548 5316//3542 5332//3549
+f 5312//3550 5311//3544 5327//3551
+f 5307//3552 5306//3546 5321//3553
+f 5313//3554 5312//3550 5328//3555
+f 5308//3530 5307//3552 5322//3556
+f 5314//3536 5313//3554 5329//3557
+f 5329//3557 5328//3555 5344//3558
+f 5324//3539 5323//3531 5338//3559
+f 5319//3541 5318//3534 5333//3560
+f 5330//3537 5329//3557 5345//3561
+f 5325//3562 5324//3539 5339//3563
+f 5320//3547 5319//3541 5334//3564
+f 5331//3543 5330//3537 5346//3565
+f 5326//3545 5325//3562 5341//3566
+f 5321//3553 5320//3547 5335//3567
+f 5332//3549 5331//3543 5347//3568
+f 5327//3551 5326//3545 5342//3569
+f 5322//3556 5321//3553 5336//3570
+f 5328//3555 5327//3551 5343//3571
+f 5323//3531 5322//3556 5337//3572
+f 5343//3571 5342//3569 5358//3573
+f 5338//3559 5337//3572 5352//3574
+f 5344//3558 5343//3571 5359//3575
+f 5339//3563 5338//3559 5353//3576
+f 5334//3564 5333//3560 5348//3577
+f 5345//3561 5344//3558 5360//3578
+f 5340//3579 5339//3563 5354//3580
+f 5335//3567 5334//3564 5349//3581
+f 5346//3565 5345//3561 5361//3582
+f 5341//3566 5340//3579 5356//3583
+f 5336//3570 5335//3567 5350//3584
+f 5347//3568 5346//3565 5362//3585
+f 5342//3569 5341//3566 5357//3586
+f 5337//3572 5336//3570 5351//3587
+f 5362//3585 5361//3582 5377//3588
+f 5357//3586 5356//3583 5372//3589
+f 5352//3574 5351//3587 5366//3590
+f 5358//3573 5357//3586 5373//3591
+f 5353//3576 5352//3574 5367//3592
+f 5359//3575 5358//3573 5374//3593
+f 5354//3580 5353//3576 5368//3594
+f 5349//3581 5348//3577 5363//3595
+f 5360//3578 5359//3575 5375//3596
+f 5355//3597 5354//3580 5369//3598
+f 5350//3584 5349//3581 5365//3599
+f 5361//3582 5360//3578 5376//3600
+f 5356//3583 5355//3597 5371//3601
+f 5351//3587 5350//3584 5366//3590
+f 5365//3599 5364//3602 5380//3603
+f 5376//3600 5375//3596 5391//3604
+f 5371//3601 5370//3605 5386//3606
+f 5366//3590 5365//3599 5381//3607
+f 5377//3588 5376//3600 5392//3608
+f 5372//3589 5371//3601 5387//3609
+f 5367//3592 5366//3590 5381//3607
+f 5373//3591 5372//3589 5388//3610
+f 5368//3594 5367//3592 5382//3611
+f 5374//3593 5373//3591 5389//3612
+f 5369//3598 5368//3594 5383//3613
+f 5364//3602 5363//3595 5379//3614
+f 5375//3596 5374//3593 5390//3615
+f 5370//3605 5369//3598 5384//3616
+f 5384//3616 5383//3613 5398//3617
+f 5379//3614 5378//3618 5394//3619
+f 5390//3615 5389//3612 5405//3620
+f 5385//3621 5384//3616 5399//3622
+f 5380//3603 5379//3614 5395//3623
+f 5391//3604 5390//3615 5406//3624
+f 5386//3606 5385//3621 5401//3625
+f 5381//3607 5380//3603 5395//3623
+f 5392//3608 5391//3604 5407//3626
+f 5387//3609 5386//3606 5402//3627
+f 5382//3611 5381//3607 5396//3628
+f 5388//3610 5387//3609 5403//3629
+f 5383//3613 5382//3611 5397//3630
+f 5389//3612 5388//3610 5404//3631
+f 5403//3629 5402//3627 5418//3632
+f 5398//3617 5397//3630 5412//3633
+f 5404//3631 5403//3629 5419//3634
+f 5399//3622 5398//3617 5413//3635
+f 5394//3619 5393//3636 5409//3637
+f 5405//3620 5404//3631 5420//3638
+f 5400//3639 5399//3622 5414//3640
+f 5395//3623 5394//3619 5410//3641
+f 5406//3624 5405//3620 5421//3642
+f 5401//3625 5400//3639 5416//3643
+f 5396//3628 5395//3623 5411//3644
+f 5407//3626 5406//3624 5422//3645
+f 5402//3627 5401//3625 5417//3646
+f 5397//3630 5396//3628 5411//3644
+f 5422//3645 5421//3642 5436//3647
+f 5417//3646 5416//3643 5431//3648
+f 5412//3633 5411//3644 5427//3649
+f 5418//3632 5417//3646 5432//3650
+f 5413//3635 5412//3633 5428//3651
+f 5419//3634 5418//3632 5433//3652
+f 5414//3640 5413//3635 5429//3653
+f 5409//3637 5408//3654 5424//3655
+f 5420//3638 5419//3634 5434//3656
+f 5415//3657 5414//3640 5430//3658
+f 5410//3641 5409//3637 5425//3659
+f 5421//3642 5420//3638 5435//3660
+f 5416//3643 5415//3657 5430//3658
+f 5411//3644 5410//3641 5426//3661
+f 5425//3659 5424//3655 5440//3662
+f 5436//3647 5435//3660 5450//3663
+f 5431//3648 5430//3658 5445//3664
+f 5426//3661 5425//3659 5441//3665
+f 5437//3666 5436//3647 5451//3667
+f 5432//3650 5431//3648 5446//3668
+f 5427//3649 5426//3661 5442//3669
+f 5433//3652 5432//3650 5447//3670
+f 5428//3651 5427//3649 5443//3671
+f 5434//3656 5433//3652 5448//3672
+f 5429//3653 5428//3651 5444//3673
+f 5424//3655 5423//3674 5439//3675
+f 5435//3660 5434//3656 5449//3676
+f 5430//3658 5429//3653 5445//3664
+f 5444//3673 5443//3671 5459//3677
+f 5439//3675 5438//3678 5454//3679
+f 5450//3663 5449//3676 5464//3680
+f 5445//3664 5444//3673 5460//3681
+f 5440//3662 5439//3675 5455//3682
+f 5451//3667 5450//3663 5465//3683
+f 5446//3668 5445//3664 5460//3681
+f 5441//3665 5440//3662 5456//3684
+f 5452//3685 5451//3667 5466//3686
+f 5447//3670 5446//3668 5461//3687
+f 5442//3669 5441//3665 5457//3688
+f 5448//3672 5447//3670 5462//3689
+f 5443//3671 5442//3669 5458//3690
+f 5449//3676 5448//3672 5463//3691
+f 5463//3691 5462//3689 5477//3692
+f 5458//3690 5457//3688 5473//3693
+f 5464//3680 5463//3691 5478//3694
+f 5459//3677 5458//3690 5474//3695
+f 5454//3679 5453//3696 5469//3697
+f 5465//3683 5464//3680 5479//3698
+f 5460//3681 5459//3677 5475//3699
+f 5455//3682 5454//3679 5470//3700
+f 5466//3686 5465//3683 5480//3701
+f 5461//3687 5460//3681 5475//3699
+f 5456//3684 5455//3682 5471//3702
+f 5467//3703 5466//3686 5481//3704
+f 5462//3689 5461//3687 5476//3705
+f 5457//3688 5456//3684 5472//3706
+f 5482//3707 5481//3704 5496//3708
+f 5477//3692 5476//3705 5491//3709
+f 5472//3706 5471//3702 5487//3710
+f 5478//3694 5477//3692 5492//3711
+f 5473//3693 5472//3706 5488//3712
+f 5479//3698 5478//3694 5493//3713
+f 5474//3695 5473//3693 5489//3714
+f 5469//3697 5468//3715 5483//3716
+f 5480//3701 5479//3698 5494//3717
+f 5475//3699 5474//3695 5490//3718
+f 5470//3700 5469//3697 5484//3719
+f 5481//3704 5480//3701 5495//3720
+f 5476//3705 5475//3699 5490//3718
+f 5471//3702 5470//3700 5486//3721
+f 5496//3708 5495//3720 5510//3722
+f 5491//3709 5490//3718 5505//3723
+f 5486//3721 5485//3724 5501//3725
+f 5497//3726 5496//3708 5511//3727
+f 5492//3711 5491//3709 5506//3728
+f 5487//3710 5486//3721 5502//3729
+f 5493//3713 5492//3711 5507//3730
+f 5488//3712 5487//3710 5503//3731
+f 5494//3717 5493//3713 5508//3732
+f 5489//3714 5488//3712 5504//3733
+f 5484//3719 5483//3716 5498//3734
+f 5495//3720 5494//3717 5509//3735
+f 5490//3718 5489//3714 5505//3723
+f 5485//3724 5484//3719 5499//3736
+f 5499//3736 5498//3734 5513//3737
+f 5510//3722 5509//3735 5524//3738
+f 5505//3723 5504//3733 5520//3739
+f 5500//3740 5499//3736 5514//3741
+f 5511//3727 5510//3722 5525//3742
+f 5506//3728 5505//3723 5520//3739
+f 5501//3725 5500//3740 5516//3743
+f 5512//3744 5511//3727 5526//3745
+f 5507//3730 5506//3728 5521//3746
+f 5502//3729 5501//3725 5517//3747
+f 5508//3732 5507//3730 5522//3748
+f 5503//3731 5502//3729 5518//3749
+f 5509//3735 5508//3732 5523//3750
+f 5504//3733 5503//3731 5519//3751
+f 5518//3749 5517//3747 5533//3752
+f 5524//3738 5523//3750 5538//3753
+f 5519//3751 5518//3749 5534//3754
+f 5514//3741 5513//3737 5529//3755
+f 5525//3742 5524//3738 5539//3756
+f 5520//3739 5519//3751 5535//3757
+f 5515//3758 5514//3741 5530//3759
+f 5526//3745 5525//3742 5540//3760
+f 5521//3746 5520//3739 5535//3757
+f 5516//3743 5515//3758 5531//3761
+f 5527//3762 5526//3745 5541//3763
+f 5522//3748 5521//3746 5536//3764
+f 5517//3747 5516//3743 5532//3765
+f 5523//3750 5522//3748 5537//3766
+f 5537//3766 5536//3764 5552//3767
+f 5532//3765 5531//3761 5546//3768
+f 5538//3753 5537//3766 5553//3769
+f 5533//3752 5532//3765 5547//3770
+f 5539//3756 5538//3753 5554//3771
+f 5534//3754 5533//3752 5548//3772
+f 5529//3755 5528//3773 5544//3774
+f 5540//3760 5539//3756 5555//3775
+f 5535//3757 5534//3754 5549//3776
+f 5530//3759 5529//3755 5545//3777
+f 5541//3763 5540//3760 5556//3778
+f 5536//3764 5535//3757 5551//3779
+f 5531//3761 5530//3759 5546//3768
+f 5542//3780 5541//3763 5557//3781
+f 5556//3778 5555//3775 5571//3782
+f 5551//3779 5550//3783 5566//3784
+f 5546//3768 5545//3777 5561//3785
+f 5557//3781 5556//3778 5572//3786
+f 5552//3767 5551//3779 5567//3787
+f 5547//3770 5546//3768 5561//3785
+f 5553//3769 5552//3767 5568//3788
+f 5548//3772 5547//3770 5562//3789
+f 5554//3771 5553//3769 5569//3790
+f 5549//3776 5548//3772 5563//3791
+f 5544//3774 5543//3792 5559//3793
+f 5555//3775 5554//3771 5570//3794
+f 5550//3783 5549//3776 5564//3795
+f 5545//3777 5544//3774 5560//3796
+f 5559//3793 5558//3797 5573//3798
+f 5570//3794 5569//3790 5585//3799
+f 5565//3800 5564//3795 5579//3801
+f 5560//3796 5559//3793 5574//3802
+f 5571//3782 5570//3794 5586//3803
+f 5566//3784 5565//3800 5581//3804
+f 5561//3785 5560//3796 5575//3805
+f 5572//3786 5571//3782 5587//3806
+f 5567//3787 5566//3784 5582//3807
+f 5562//3789 5561//3785 5576//3808
+f 5568//3788 5567//3787 5583//3809
+f 5563//3791 5562//3789 5577//3810
+f 5569//3790 5568//3788 5584//3811
+f 5564//3795 5563//3791 5578//3812
+f 5578//3812 5577//3810 5592//3813
+f 5584//3811 5583//3809 5599//3814
+f 5579//3801 5578//3812 5593//3815
+f 5574//3802 5573//3798 5588//3816
+f 5585//3799 5584//3811 5600//3817
+f 5580//3818 5579//3801 5594//3819
+f 5575//3805 5574//3802 5589//3820
+f 5586//3803 5585//3799 5601//3821
+f 5581//3804 5580//3818 5596//3822
+f 5576//3808 5575//3805 5590//3823
+f 5587//3806 5586//3803 5602//3824
+f 5582//3807 5581//3804 5597//3825
+f 5577//3810 5576//3808 5591//3826
+f 5583//3809 5582//3807 5598//3827
+f 5597//3825 5596//3822 5612//3828
+f 5592//3813 5591//3826 5606//3829
+f 5598//3827 5597//3825 5613//3830
+f 5593//3815 5592//3813 5607//3831
+f 5599//3814 5598//3827 5614//3832
+f 5594//3819 5593//3815 5608//3833
+f 5589//3820 5588//3816 5603//3834
+f 5600//3817 5599//3814 5615//3835
+f 5595//3836 5594//3819 5609//3837
+f 5590//3823 5589//3820 5604//3838
+f 5601//3821 5600//3817 5616//3839
+f 5596//3822 5595//3836 5611//3840
+f 5591//3826 5590//3823 5605//3841
+f 5602//3824 5601//3821 5617//3842
+f 5616//3839 5615//3835 5631//3843
+f 5611//3840 5610//3844 5626//3845
+f 5606//3829 5605//3841 5620//3846
+f 5617//3842 5616//3839 5632//3847
+f 5612//3828 5611//3840 5627//3848
+f 5607//3831 5606//3829 5621//3849
+f 5613//3830 5612//3828 5628//3850
+f 5608//3833 5607//3831 5622//3851
+f 5614//3832 5613//3830 5629//3852
+f 5609//3837 5608//3833 5623//3853
+f 5604//3838 5603//3834 5619//3854
+f 5615//3835 5614//3832 5630//3855
+f 5610//3844 5609//3837 5624//3856
+f 5605//3841 5604//3838 5620//3846
+f 5630//3855 5629//3852 5646//3857
+f 5625//3858 5624//3856 5640//3859
+f 5620//3846 5619//3854 5636//3860
+f 5631//3843 5630//3855 5647//3861
+f 5626//3845 5625//3858 5642//3862
+f 5621//3849 5620//3846 5636//3860
+f 5632//3847 5631//3843 5648//3863
+f 5627//3848 5626//3845 5643//3864
+f 5622//3851 5621//3849 5637//3865
+f 5628//3850 5627//3848 5644//3866
+f 5623//3853 5622//3851 5638//3867
+f 5629//3852 5628//3850 5645//3868
+f 5624//3856 5623//3853 5639//3869
+f 5619//3854 5618//3870 5635//3871
+f 5645//3868 5644//3866 5660//3872
+f 5640//3859 5639//3869 5654//3873
+f 5635//3871 5634//3874 5650//3875
+f 5646//3857 5645//3868 5661//3876
+f 5641//3877 5640//3859 5655//3878
+f 5636//3860 5635//3871 5651//3879
+f 5647//3861 5646//3857 5662//3880
+f 5642//3862 5641//3877 5657//3881
+f 5637//3865 5636//3860 5652//3882
+f 5648//3863 5647//3861 5663//3883
+f 5643//3864 5642//3862 5658//3884
+f 5638//3867 5637//3865 5652//3882
+f 5644//3866 5643//3864 5659//3885
+f 5639//3869 5638//3867 5653//3886
+f 5653//3886 5652//3882 5668//3887
+f 5659//3885 5658//3884 5673//3888
+f 5654//3873 5653//3886 5669//3889
+f 5660//3872 5659//3885 5674//3890
+f 5655//3878 5654//3873 5670//3891
+f 5650//3875 5649//3892 5664//3893
+f 5661//3876 5660//3872 5675//3894
+f 5656//3895 5655//3878 5671//3896
+f 5651//3879 5650//3875 5666//3897
+f 5662//3880 5661//3876 5676//3898
+f 5657//3881 5656//3895 5671//3896
+f 5652//3882 5651//3879 5667//3899
+f 5663//3883 5662//3880 5677//3900
+f 5658//3884 5657//3881 5672//3901
+f 5672//3901 5671//3896 5686//3902
+f 5667//3899 5666//3897 5681//3903
+f 5678//3904 5677//3900 5692//3905
+f 5673//3888 5672//3901 5687//3906
+f 5668//3887 5667//3899 5683//3907
+f 5674//3890 5673//3888 5688//3908
+f 5669//3889 5668//3887 5684//3909
+f 5675//3894 5674//3890 5689//3910
+f 5670//3891 5669//3889 5685//3911
+f 5665//3912 5664//3893 5679//3913
+f 5676//3898 5675//3894 5690//3914
+f 5671//3896 5670//3891 5686//3902
+f 5666//3897 5665//3912 5680//3915
+f 5677//3900 5676//3898 5691//3916
+f 5691//3916 5690//3914 5705//3917
+f 5686//3902 5685//3911 5701//3918
+f 5681//3903 5680//3915 5695//3919
+f 5692//3905 5691//3916 5706//3920
+f 5687//3906 5686//3902 5701//3918
+f 5682//3921 5681//3903 5696//3922
+f 5693//3923 5692//3905 5707//3924
+f 5688//3908 5687//3906 5702//3925
+f 5683//3907 5682//3921 5698//3926
+f 5689//3910 5688//3908 5703//3927
+f 5684//3909 5683//3907 5699//3928
+f 5690//3914 5689//3910 5704//3929
+f 5685//3911 5684//3909 5700//3930
+f 5680//3915 5679//3913 5694//3931
+f 5705//3917 5704//3929 5719//3932
+f 5700//3930 5699//3928 5715//3933
+f 5695//3919 5694//3931 5709//3934
+f 5706//3920 5705//3917 5720//3935
+f 5701//3918 5700//3930 5716//3936
+f 5696//3922 5695//3919 5710//3937
+f 5707//3924 5706//3920 5721//3938
+f 5702//3925 5701//3918 5716//3936
+f 5697//3939 5696//3922 5712//3940
+f 5708//3941 5707//3924 5722//3942
+f 5703//3927 5702//3925 5717//3943
+f 5698//3926 5697//3939 5713//3944
+f 5704//3929 5703//3927 5718//3945
+f 5699//3928 5698//3926 5714//3946
+f 5713//3944 5712//3940 5728//3947
+f 5719//3932 5718//3945 5733//3948
+f 5714//3946 5713//3944 5729//3949
+f 5720//3935 5719//3932 5734//3950
+f 5715//3933 5714//3946 5730//3951
+f 5710//3937 5709//3934 5725//3952
+f 5721//3938 5720//3935 5735//3953
+f 5716//3936 5715//3933 5731//3954
+f 5711//3955 5710//3937 5726//3956
+f 5722//3942 5721//3938 5736//3957
+f 5717//3943 5716//3936 5731//3954
+f 5712//3940 5711//3955 5727//3958
+f 5723//3959 5722//3942 5737//3960
+f 5718//3945 5717//3943 5732//3961
+f 5732//3961 5731//3954 5746//3962
+f 5727//3958 5726//3956 5742//3963
+f 5738//3964 5737//3960 5752//3965
+f 5733//3948 5732//3961 5747//3966
+f 5728//3947 5727//3958 5743//3967
+f 5734//3950 5733//3948 5748//3968
+f 5729//3949 5728//3947 5744//3969
+f 5735//3953 5734//3950 5749//3970
+f 5730//3951 5729//3949 5745//3971
+f 5725//3952 5724//3972 5740//3973
+f 5736//3957 5735//3953 5750//3974
+f 5731//3954 5730//3951 5746//3962
+f 5726//3956 5725//3952 5741//3975
+f 5737//3960 5736//3957 5751//3976
+f 5751//3976 5750//3974 5766//3977
+f 5746//3962 5745//3971 5762//3978
+f 5741//3975 5740//3973 5757//3979
+f 5752//3965 5751//3976 5767//3980
+f 5747//3966 5746//3962 5762//3978
+f 5742//3963 5741//3975 5758//3981
+f 5753//3982 5752//3965 5768//3983
+f 5748//3968 5747//3966 5763//3984
+f 5743//3967 5742//3963 5759//3985
+f 5749//3970 5748//3968 5764//3986
+f 5744//3969 5743//3967 5760//3987
+f 5750//3974 5749//3970 5765//3988
+f 5745//3971 5744//3969 5761//3989
+f 5740//3973 5739//3990 5756//3991
+f 5766//3977 5765//3988 5780//3992
+f 5761//3989 5760//3987 5776//3993
+f 5756//3991 5755//3994 5770//3995
+f 5767//3980 5766//3977 5781//3996
+f 5762//3978 5761//3989 5777//3997
+f 5757//3979 5756//3991 5771//3998
+f 5768//3983 5767//3980 5782//3999
+f 5763//3984 5762//3978 5777//3997
+f 5758//3981 5757//3979 5772//4000
+f 5769//4001 5768//3983 5783//4002
+f 5764//3986 5763//3984 5778//4003
+f 5759//3985 5758//3981 5774//4004
+f 5765//3988 5764//3986 5779//4005
+f 5760//3987 5759//3985 5775//4006
+f 5633//364 5317//3548 5332//3549
+f 5303//3533 5754//4007 5318//3534
+f 5633//364 5332//3549 5347//3568
+f 5318//3534 5754//4007 5333//3560
+f 5633//364 5347//3568 5362//3585
+f 5333//3560 5754//4007 5348//3577
+f 5633//364 5362//3585 5377//3588
+f 5348//3577 5754//4007 5363//3595
+f 5633//364 5377//3588 5392//3608
+f 5363//3595 5754//4007 5378//3618
+f 5633//364 5392//3608 5407//3626
+f 5378//3618 5754//4007 5393//3636
+f 5393//3636 5754//4007 5408//3654
+f 5633//364 5407//3626 5422//3645
+f 5633//364 5422//3645 5437//3666
+f 5408//3654 5754//4007 5423//3674
+f 5633//364 5437//3666 5452//3685
+f 5423//3674 5754//4007 5438//3678
+f 5633//364 5452//3685 5467//3703
+f 5438//3678 5754//4007 5453//3696
+f 5453//3696 5754//4007 5468//3715
+f 5633//364 5467//3703 5482//3707
+f 5633//364 5482//3707 5497//3726
+f 5468//3715 5754//4007 5483//3716
+f 5633//364 5497//3726 5512//3744
+f 5483//3716 5754//4007 5498//3734
+f 5633//364 5512//3744 5527//3762
+f 5498//3734 5754//4007 5513//3737
+f 5513//3737 5754//4007 5528//3773
+f 5633//364 5527//3762 5542//3780
+f 5633//364 5542//3780 5557//3781
+f 5528//3773 5754//4007 5543//3792
+f 5633//364 5557//3781 5572//3786
+f 5543//3792 5754//4007 5558//3797
+f 5633//364 5572//3786 5587//3806
+f 5558//3797 5754//4007 5573//3798
+f 5573//3798 5754//4007 5588//3816
+f 5633//364 5587//3806 5602//3824
+f 5633//364 5602//3824 5617//3842
+f 5588//3816 5754//4007 5603//3834
+f 5633//364 5617//3842 5632//3847
+f 5603//3834 5754//4007 5618//3870
+f 5633//364 5632//3847 5648//3863
+f 5618//3870 5754//4007 5634//3874
+f 5634//3874 5754//4007 5649//3892
+f 5633//364 5648//3863 5663//3883
+f 5633//364 5663//3883 5678//3904
+f 5649//3892 5754//4007 5664//3893
+f 5633//364 5678//3904 5693//3923
+f 5664//3893 5754//4007 5679//3913
+f 5633//364 5693//3923 5708//3941
+f 5679//3913 5754//4007 5694//3931
+f 5694//3931 5754//4007 5709//3934
+f 5633//364 5708//3941 5723//3959
+f 5633//364 5723//3959 5738//3964
+f 5709//3934 5754//4007 5724//3972
+f 5633//364 5738//3964 5753//3982
+f 5724//3972 5754//4007 5739//3990
+f 5633//364 5753//3982 5769//4001
+f 5739//3990 5754//4007 5755//3994
+f 5633//364 5769//4001 5784//4008
+f 5755//3994 5754//4007 5770//3995
+f 5633//364 5784//4008 5317//3548
+f 5780//3992 5779//4005 5313//3554
+f 5775//4006 5774//4004 5307//3552
+f 5770//3995 5754//4007 5303//3533
+f 5781//3996 5780//3992 5314//3536
+f 5776//3993 5775//4006 5308//3530
+f 5771//3998 5770//3995 5303//3533
+f 5782//3999 5781//3996 5315//3535
+f 5777//3997 5776//3993 5309//3529
+f 5772//4000 5771//3998 5304//3532
+f 5783//4002 5782//3999 5316//3542
+f 5778//4003 5777//3997 5311//3544
+f 5773//4009 5772//4000 5305//3540
+f 5784//4008 5783//4002 5317//3548
+f 5779//4005 5778//4003 5312//3550
+f 5774//4004 5773//4009 5306//3546
+f 5324//3539 5309//3529 5323//3531
+f 5319//3541 5304//3532 5318//3534
+f 5314//3536 5329//3557 5330//3537
+f 5325//3562 5310//3538 5324//3539
+f 5320//3547 5305//3540 5319//3541
+f 5315//3535 5330//3537 5331//3543
+f 5310//3538 5325//3562 5326//3545
+f 5321//3553 5306//3546 5320//3547
+f 5316//3542 5331//3543 5332//3549
+f 5311//3544 5326//3545 5327//3551
+f 5322//3556 5307//3552 5321//3553
+f 5312//3550 5327//3551 5328//3555
+f 5323//3531 5308//3530 5322//3556
+f 5313//3554 5328//3555 5329//3557
+f 5328//3555 5343//3571 5344//3558
+f 5339//3563 5324//3539 5338//3559
+f 5334//3564 5319//3541 5333//3560
+f 5329//3557 5344//3558 5345//3561
+f 5340//3579 5325//3562 5339//3563
+f 5335//3567 5320//3547 5334//3564
+f 5330//3537 5345//3561 5346//3565
+f 5325//3562 5340//3579 5341//3566
+f 5336//3570 5321//3553 5335//3567
+f 5331//3543 5346//3565 5347//3568
+f 5326//3545 5341//3566 5342//3569
+f 5337//3572 5322//3556 5336//3570
+f 5327//3551 5342//3569 5343//3571
+f 5338//3559 5323//3531 5337//3572
+f 5342//3569 5357//3586 5358//3573
+f 5353//3576 5338//3559 5352//3574
+f 5343//3571 5358//3573 5359//3575
+f 5354//3580 5339//3563 5353//3576
+f 5349//3581 5334//3564 5348//3577
+f 5344//3558 5359//3575 5360//3578
+f 5355//3597 5340//3579 5354//3580
+f 5350//3584 5335//3567 5349//3581
+f 5345//3561 5360//3578 5361//3582
+f 5340//3579 5355//3597 5356//3583
+f 5351//3587 5336//3570 5350//3584
+f 5346//3565 5361//3582 5362//3585
+f 5341//3566 5356//3583 5357//3586
+f 5352//3574 5337//3572 5351//3587
+f 5361//3582 5376//3600 5377//3588
+f 5356//3583 5371//3601 5372//3589
+f 5367//3592 5352//3574 5366//3590
+f 5357//3586 5372//3589 5373//3591
+f 5368//3594 5353//3576 5367//3592
+f 5358//3573 5373//3591 5374//3593
+f 5369//3598 5354//3580 5368//3594
+f 5364//3602 5349//3581 5363//3595
+f 5359//3575 5374//3593 5375//3596
+f 5370//3605 5355//3597 5369//3598
+f 5349//3581 5364//3602 5365//3599
+f 5360//3578 5375//3596 5376//3600
+f 5355//3597 5370//3605 5371//3601
+f 5350//3584 5365//3599 5366//3590
+f 5364//3602 5379//3614 5380//3603
+f 5375//3596 5390//3615 5391//3604
+f 5370//3605 5385//3621 5386//3606
+f 5365//3599 5380//3603 5381//3607
+f 5376//3600 5391//3604 5392//3608
+f 5371//3601 5386//3606 5387//3609
+f 5382//3611 5367//3592 5381//3607
+f 5372//3589 5387//3609 5388//3610
+f 5383//3613 5368//3594 5382//3611
+f 5373//3591 5388//3610 5389//3612
+f 5384//3616 5369//3598 5383//3613
+f 5363//3595 5378//3618 5379//3614
+f 5374//3593 5389//3612 5390//3615
+f 5385//3621 5370//3605 5384//3616
+f 5399//3622 5384//3616 5398//3617
+f 5378//3618 5393//3636 5394//3619
+f 5389//3612 5404//3631 5405//3620
+f 5400//3639 5385//3621 5399//3622
+f 5379//3614 5394//3619 5395//3623
+f 5390//3615 5405//3620 5406//3624
+f 5385//3621 5400//3639 5401//3625
+f 5396//3628 5381//3607 5395//3623
+f 5391//3604 5406//3624 5407//3626
+f 5386//3606 5401//3625 5402//3627
+f 5397//3630 5382//3611 5396//3628
+f 5387//3609 5402//3627 5403//3629
+f 5398//3617 5383//3613 5397//3630
+f 5388//3610 5403//3629 5404//3631
+f 5402//3627 5417//3646 5418//3632
+f 5413//3635 5398//3617 5412//3633
+f 5403//3629 5418//3632 5419//3634
+f 5414//3640 5399//3622 5413//3635
+f 5393//3636 5408//3654 5409//3637
+f 5404//3631 5419//3634 5420//3638
+f 5415//3657 5400//3639 5414//3640
+f 5394//3619 5409//3637 5410//3641
+f 5405//3620 5420//3638 5421//3642
+f 5400//3639 5415//3657 5416//3643
+f 5395//3623 5410//3641 5411//3644
+f 5406//3624 5421//3642 5422//3645
+f 5401//3625 5416//3643 5417//3646
+f 5412//3633 5397//3630 5411//3644
+f 5437//3666 5422//3645 5436//3647
+f 5432//3650 5417//3646 5431//3648
+f 5411//3644 5426//3661 5427//3649
+f 5433//3652 5418//3632 5432//3650
+f 5412//3633 5427//3649 5428//3651
+f 5434//3656 5419//3634 5433//3652
+f 5413//3635 5428//3651 5429//3653
+f 5408//3654 5423//3674 5424//3655
+f 5435//3660 5420//3638 5434//3656
+f 5414//3640 5429//3653 5430//3658
+f 5409//3637 5424//3655 5425//3659
+f 5436//3647 5421//3642 5435//3660
+f 5431//3648 5416//3643 5430//3658
+f 5410//3641 5425//3659 5426//3661
+f 5424//3655 5439//3675 5440//3662
+f 5451//3667 5436//3647 5450//3663
+f 5446//3668 5431//3648 5445//3664
+f 5425//3659 5440//3662 5441//3665
+f 5452//3685 5437//3666 5451//3667
+f 5447//3670 5432//3650 5446//3668
+f 5426//3661 5441//3665 5442//3669
+f 5448//3672 5433//3652 5447//3670
+f 5427//3649 5442//3669 5443//3671
+f 5449//3676 5434//3656 5448//3672
+f 5428//3651 5443//3671 5444//3673
+f 5423//3674 5438//3678 5439//3675
+f 5450//3663 5435//3660 5449//3676
+f 5429//3653 5444//3673 5445//3664
+f 5443//3671 5458//3690 5459//3677
+f 5438//3678 5453//3696 5454//3679
+f 5465//3683 5450//3663 5464//3680
+f 5444//3673 5459//3677 5460//3681
+f 5439//3675 5454//3679 5455//3682
+f 5466//3686 5451//3667 5465//3683
+f 5461//3687 5446//3668 5460//3681
+f 5440//3662 5455//3682 5456//3684
+f 5467//3703 5452//3685 5466//3686
+f 5462//3689 5447//3670 5461//3687
+f 5441//3665 5456//3684 5457//3688
+f 5463//3691 5448//3672 5462//3689
+f 5442//3669 5457//3688 5458//3690
+f 5464//3680 5449//3676 5463//3691
+f 5478//3694 5463//3691 5477//3692
+f 5457//3688 5472//3706 5473//3693
+f 5479//3698 5464//3680 5478//3694
+f 5458//3690 5473//3693 5474//3695
+f 5453//3696 5468//3715 5469//3697
+f 5480//3701 5465//3683 5479//3698
+f 5459//3677 5474//3695 5475//3699
+f 5454//3679 5469//3697 5470//3700
+f 5481//3704 5466//3686 5480//3701
+f 5476//3705 5461//3687 5475//3699
+f 5455//3682 5470//3700 5471//3702
+f 5482//3707 5467//3703 5481//3704
+f 5477//3692 5462//3689 5476//3705
+f 5456//3684 5471//3702 5472//3706
+f 5497//3726 5482//3707 5496//3708
+f 5492//3711 5477//3692 5491//3709
+f 5471//3702 5486//3721 5487//3710
+f 5493//3713 5478//3694 5492//3711
+f 5472//3706 5487//3710 5488//3712
+f 5494//3717 5479//3698 5493//3713
+f 5473//3693 5488//3712 5489//3714
+f 5484//3719 5469//3697 5483//3716
+f 5495//3720 5480//3701 5494//3717
+f 5474//3695 5489//3714 5490//3718
+f 5485//3724 5470//3700 5484//3719
+f 5496//3708 5481//3704 5495//3720
+f 5491//3709 5476//3705 5490//3718
+f 5470//3700 5485//3724 5486//3721
+f 5511//3727 5496//3708 5510//3722
+f 5506//3728 5491//3709 5505//3723
+f 5485//3724 5500//3740 5501//3725
+f 5512//3744 5497//3726 5511//3727
+f 5507//3730 5492//3711 5506//3728
+f 5486//3721 5501//3725 5502//3729
+f 5508//3732 5493//3713 5507//3730
+f 5487//3710 5502//3729 5503//3731
+f 5509//3735 5494//3717 5508//3732
+f 5488//3712 5503//3731 5504//3733
+f 5499//3736 5484//3719 5498//3734
+f 5510//3722 5495//3720 5509//3735
+f 5489//3714 5504//3733 5505//3723
+f 5500//3740 5485//3724 5499//3736
+f 5514//3741 5499//3736 5513//3737
+f 5525//3742 5510//3722 5524//3738
+f 5504//3733 5519//3751 5520//3739
+f 5515//3758 5500//3740 5514//3741
+f 5526//3745 5511//3727 5525//3742
+f 5521//3746 5506//3728 5520//3739
+f 5500//3740 5515//3758 5516//3743
+f 5527//3762 5512//3744 5526//3745
+f 5522//3748 5507//3730 5521//3746
+f 5501//3725 5516//3743 5517//3747
+f 5523//3750 5508//3732 5522//3748
+f 5502//3729 5517//3747 5518//3749
+f 5524//3738 5509//3735 5523//3750
+f 5503//3731 5518//3749 5519//3751
+f 5517//3747 5532//3765 5533//3752
+f 5539//3756 5524//3738 5538//3753
+f 5518//3749 5533//3752 5534//3754
+f 5513//3737 5528//3773 5529//3755
+f 5540//3760 5525//3742 5539//3756
+f 5519//3751 5534//3754 5535//3757
+f 5514//3741 5529//3755 5530//3759
+f 5541//3763 5526//3745 5540//3760
+f 5536//3764 5521//3746 5535//3757
+f 5515//3758 5530//3759 5531//3761
+f 5542//3780 5527//3762 5541//3763
+f 5537//3766 5522//3748 5536//3764
+f 5516//3743 5531//3761 5532//3765
+f 5538//3753 5523//3750 5537//3766
+f 5536//3764 5551//3779 5552//3767
+f 5547//3770 5532//3765 5546//3768
+f 5537//3766 5552//3767 5553//3769
+f 5548//3772 5533//3752 5547//3770
+f 5538//3753 5553//3769 5554//3771
+f 5549//3776 5534//3754 5548//3772
+f 5528//3773 5543//3792 5544//3774
+f 5539//3756 5554//3771 5555//3775
+f 5550//3783 5535//3757 5549//3776
+f 5529//3755 5544//3774 5545//3777
+f 5540//3760 5555//3775 5556//3778
+f 5535//3757 5550//3783 5551//3779
+f 5530//3759 5545//3777 5546//3768
+f 5541//3763 5556//3778 5557//3781
+f 5555//3775 5570//3794 5571//3782
+f 5550//3783 5565//3800 5566//3784
+f 5545//3777 5560//3796 5561//3785
+f 5556//3778 5571//3782 5572//3786
+f 5551//3779 5566//3784 5567//3787
+f 5562//3789 5547//3770 5561//3785
+f 5552//3767 5567//3787 5568//3788
+f 5563//3791 5548//3772 5562//3789
+f 5553//3769 5568//3788 5569//3790
+f 5564//3795 5549//3776 5563//3791
+f 5543//3792 5558//3797 5559//3793
+f 5554//3771 5569//3790 5570//3794
+f 5565//3800 5550//3783 5564//3795
+f 5544//3774 5559//3793 5560//3796
+f 5574//3802 5559//3793 5573//3798
+f 5569//3790 5584//3811 5585//3799
+f 5580//3818 5565//3800 5579//3801
+f 5575//3805 5560//3796 5574//3802
+f 5570//3794 5585//3799 5586//3803
+f 5565//3800 5580//3818 5581//3804
+f 5576//3808 5561//3785 5575//3805
+f 5571//3782 5586//3803 5587//3806
+f 5566//3784 5581//3804 5582//3807
+f 5577//3810 5562//3789 5576//3808
+f 5567//3787 5582//3807 5583//3809
+f 5578//3812 5563//3791 5577//3810
+f 5568//3788 5583//3809 5584//3811
+f 5579//3801 5564//3795 5578//3812
+f 5593//3815 5578//3812 5592//3813
+f 5583//3809 5598//3827 5599//3814
+f 5594//3819 5579//3801 5593//3815
+f 5589//3820 5574//3802 5588//3816
+f 5584//3811 5599//3814 5600//3817
+f 5595//3836 5580//3818 5594//3819
+f 5590//3823 5575//3805 5589//3820
+f 5585//3799 5600//3817 5601//3821
+f 5580//3818 5595//3836 5596//3822
+f 5591//3826 5576//3808 5590//3823
+f 5586//3803 5601//3821 5602//3824
+f 5581//3804 5596//3822 5597//3825
+f 5592//3813 5577//3810 5591//3826
+f 5582//3807 5597//3825 5598//3827
+f 5596//3822 5611//3840 5612//3828
+f 5607//3831 5592//3813 5606//3829
+f 5597//3825 5612//3828 5613//3830
+f 5608//3833 5593//3815 5607//3831
+f 5598//3827 5613//3830 5614//3832
+f 5609//3837 5594//3819 5608//3833
+f 5604//3838 5589//3820 5603//3834
+f 5599//3814 5614//3832 5615//3835
+f 5610//3844 5595//3836 5609//3837
+f 5605//3841 5590//3823 5604//3838
+f 5600//3817 5615//3835 5616//3839
+f 5595//3836 5610//3844 5611//3840
+f 5606//3829 5591//3826 5605//3841
+f 5601//3821 5616//3839 5617//3842
+f 5615//3835 5630//3855 5631//3843
+f 5610//3844 5625//3858 5626//3845
+f 5621//3849 5606//3829 5620//3846
+f 5616//3839 5631//3843 5632//3847
+f 5611//3840 5626//3845 5627//3848
+f 5622//3851 5607//3831 5621//3849
+f 5612//3828 5627//3848 5628//3850
+f 5623//3853 5608//3833 5622//3851
+f 5613//3830 5628//3850 5629//3852
+f 5624//3856 5609//3837 5623//3853
+f 5603//3834 5618//3870 5619//3854
+f 5614//3832 5629//3852 5630//3855
+f 5625//3858 5610//3844 5624//3856
+f 5604//3838 5619//3854 5620//3846
+f 5629//3852 5645//3868 5646//3857
+f 5641//3877 5625//3858 5640//3859
+f 5619//3854 5635//3871 5636//3860
+f 5630//3855 5646//3857 5647//3861
+f 5625//3858 5641//3877 5642//3862
+f 5637//3865 5621//3849 5636//3860
+f 5631//3843 5647//3861 5648//3863
+f 5626//3845 5642//3862 5643//3864
+f 5638//3867 5622//3851 5637//3865
+f 5627//3848 5643//3864 5644//3866
+f 5639//3869 5623//3853 5638//3867
+f 5628//3850 5644//3866 5645//3868
+f 5640//3859 5624//3856 5639//3869
+f 5618//3870 5634//3874 5635//3871
+f 5644//3866 5659//3885 5660//3872
+f 5655//3878 5640//3859 5654//3873
+f 5634//3874 5649//3892 5650//3875
+f 5645//3868 5660//3872 5661//3876
+f 5656//3895 5641//3877 5655//3878
+f 5635//3871 5650//3875 5651//3879
+f 5646//3857 5661//3876 5662//3880
+f 5641//3877 5656//3895 5657//3881
+f 5636//3860 5651//3879 5652//3882
+f 5647//3861 5662//3880 5663//3883
+f 5642//3862 5657//3881 5658//3884
+f 5653//3886 5638//3867 5652//3882
+f 5643//3864 5658//3884 5659//3885
+f 5654//3873 5639//3869 5653//3886
+f 5652//3882 5667//3899 5668//3887
+f 5674//3890 5659//3885 5673//3888
+f 5653//3886 5668//3887 5669//3889
+f 5675//3894 5660//3872 5674//3890
+f 5654//3873 5669//3889 5670//3891
+f 5665//3912 5650//3875 5664//3893
+f 5676//3898 5661//3876 5675//3894
+f 5655//3878 5670//3891 5671//3896
+f 5650//3875 5665//3912 5666//3897
+f 5677//3900 5662//3880 5676//3898
+f 5672//3901 5657//3881 5671//3896
+f 5651//3879 5666//3897 5667//3899
+f 5678//3904 5663//3883 5677//3900
+f 5673//3888 5658//3884 5672//3901
+f 5687//3906 5672//3901 5686//3902
+f 5682//3921 5667//3899 5681//3903
+f 5693//3923 5678//3904 5692//3905
+f 5688//3908 5673//3888 5687//3906
+f 5667//3899 5682//3921 5683//3907
+f 5689//3910 5674//3890 5688//3908
+f 5668//3887 5683//3907 5684//3909
+f 5690//3914 5675//3894 5689//3910
+f 5669//3889 5684//3909 5685//3911
+f 5680//3915 5665//3912 5679//3913
+f 5691//3916 5676//3898 5690//3914
+f 5670//3891 5685//3911 5686//3902
+f 5681//3903 5666//3897 5680//3915
+f 5692//3905 5677//3900 5691//3916
+f 5706//3920 5691//3916 5705//3917
+f 5685//3911 5700//3930 5701//3918
+f 5696//3922 5681//3903 5695//3919
+f 5707//3924 5692//3905 5706//3920
+f 5702//3925 5687//3906 5701//3918
+f 5697//3939 5682//3921 5696//3922
+f 5708//3941 5693//3923 5707//3924
+f 5703//3927 5688//3908 5702//3925
+f 5682//3921 5697//3939 5698//3926
+f 5704//3929 5689//3910 5703//3927
+f 5683//3907 5698//3926 5699//3928
+f 5705//3917 5690//3914 5704//3929
+f 5684//3909 5699//3928 5700//3930
+f 5695//3919 5680//3915 5694//3931
+f 5720//3935 5705//3917 5719//3932
+f 5699//3928 5714//3946 5715//3933
+f 5710//3937 5695//3919 5709//3934
+f 5721//3938 5706//3920 5720//3935
+f 5700//3930 5715//3933 5716//3936
+f 5711//3955 5696//3922 5710//3937
+f 5722//3942 5707//3924 5721//3938
+f 5717//3943 5702//3925 5716//3936
+f 5696//3922 5711//3955 5712//3940
+f 5723//3959 5708//3941 5722//3942
+f 5718//3945 5703//3927 5717//3943
+f 5697//3939 5712//3940 5713//3944
+f 5719//3932 5704//3929 5718//3945
+f 5698//3926 5713//3944 5714//3946
+f 5712//3940 5727//3958 5728//3947
+f 5734//3950 5719//3932 5733//3948
+f 5713//3944 5728//3947 5729//3949
+f 5735//3953 5720//3935 5734//3950
+f 5714//3946 5729//3949 5730//3951
+f 5709//3934 5724//3972 5725//3952
+f 5736//3957 5721//3938 5735//3953
+f 5715//3933 5730//3951 5731//3954
+f 5710//3937 5725//3952 5726//3956
+f 5737//3960 5722//3942 5736//3957
+f 5732//3961 5717//3943 5731//3954
+f 5711//3955 5726//3956 5727//3958
+f 5738//3964 5723//3959 5737//3960
+f 5733//3948 5718//3945 5732//3961
+f 5747//3966 5732//3961 5746//3962
+f 5726//3956 5741//3975 5742//3963
+f 5753//3982 5738//3964 5752//3965
+f 5748//3968 5733//3948 5747//3966
+f 5727//3958 5742//3963 5743//3967
+f 5749//3970 5734//3950 5748//3968
+f 5728//3947 5743//3967 5744//3969
+f 5750//3974 5735//3953 5749//3970
+f 5729//3949 5744//3969 5745//3971
+f 5724//3972 5739//3990 5740//3973
+f 5751//3976 5736//3957 5750//3974
+f 5730//3951 5745//3971 5746//3962
+f 5725//3952 5740//3973 5741//3975
+f 5752//3965 5737//3960 5751//3976
+f 5767//3980 5751//3976 5766//3977
+f 5745//3971 5761//3989 5762//3978
+f 5740//3973 5756//3991 5757//3979
+f 5768//3983 5752//3965 5767//3980
+f 5763//3984 5747//3966 5762//3978
+f 5741//3975 5757//3979 5758//3981
+f 5769//4001 5753//3982 5768//3983
+f 5764//3986 5748//3968 5763//3984
+f 5742//3963 5758//3981 5759//3985
+f 5765//3988 5749//3970 5764//3986
+f 5743//3967 5759//3985 5760//3987
+f 5766//3977 5750//3974 5765//3988
+f 5744//3969 5760//3987 5761//3989
+f 5739//3990 5755//3994 5756//3991
+f 5781//3996 5766//3977 5780//3992
+f 5760//3987 5775//4006 5776//3993
+f 5771//3998 5756//3991 5770//3995
+f 5782//3999 5767//3980 5781//3996
+f 5761//3989 5776//3993 5777//3997
+f 5772//4000 5757//3979 5771//3998
+f 5783//4002 5768//3983 5782//3999
+f 5778//4003 5763//3984 5777//3997
+f 5773//4009 5758//3981 5772//4000
+f 5784//4008 5769//4001 5783//4002
+f 5779//4005 5764//3986 5778//4003
+f 5758//3981 5773//4009 5774//4004
+f 5780//3992 5765//3988 5779//4005
+f 5759//3985 5774//4004 5775//4006
+f 5779//4005 5312//3550 5313//3554
+f 5308//3530 5775//4006 5307//3552
+f 5780//3992 5313//3554 5314//3536
+f 5309//3529 5776//3993 5308//3530
+f 5304//3532 5771//3998 5303//3533
+f 5781//3996 5314//3536 5315//3535
+f 5310//3538 5777//3997 5309//3529
+f 5305//3540 5772//4000 5304//3532
+f 5782//3999 5315//3535 5316//3542
+f 5777//3997 5310//3538 5311//3544
+f 5306//3546 5773//4009 5305//3540
+f 5783//4002 5316//3542 5317//3548
+f 5778//4003 5311//3544 5312//3550
+f 5307//3552 5774//4004 5306//3546
+o Ear_L_Sphere.007
+v -0.915017 0.106478 0.822725
+v -0.944167 0.121570 0.840173
+v -0.974060 0.150175 0.857679
+v -0.996357 0.185345 0.870613
+v -1.023624 0.171071 0.887158
+v -1.038620 0.139410 0.896437
+v -1.047854 0.105055 0.902151
+v -1.050972 0.069327 0.904081
+v -1.047854 0.033599 0.902151
+v -1.038620 -0.000755 0.896437
+v -1.023624 -0.032417 0.887158
+v -1.003443 -0.060169 0.874670
+v -0.978852 -0.082944 0.859453
+v -0.950796 -0.099867 0.842093
+v -0.920354 -0.110289 0.823256
+v -0.917142 0.105813 0.817309
+v -0.948467 0.119916 0.829345
+v -0.980546 0.149639 0.841337
+v -1.003465 0.185802 0.850238
+v -1.033723 0.171071 0.861992
+v -1.049842 0.139410 0.868475
+v -1.059768 0.105055 0.872466
+v -1.063119 0.069327 0.873814
+v -1.059768 0.033599 0.872466
+v -1.049842 -0.000755 0.868475
+v -1.033723 -0.032417 0.861992
+v -1.012032 -0.060169 0.853268
+v -0.985600 -0.082944 0.842638
+v -0.955444 -0.099867 0.830510
+v -0.922723 -0.110289 0.817351
+v -0.918009 0.105364 0.811327
+v -0.949964 0.118024 0.817446
+v -0.981711 0.143600 0.823584
+v -1.006807 0.178160 0.828467
+v -1.038250 0.171071 0.834585
+v -1.054871 0.139410 0.838021
+v -1.065107 0.105055 0.840137
+v -1.068563 0.069327 0.840852
+v -1.065107 0.033599 0.840137
+v -1.054871 -0.000755 0.838021
+v -1.038250 -0.032417 0.834585
+v -1.015881 -0.060169 0.829960
+v -0.988624 -0.082944 0.824325
+v -0.957527 -0.099867 0.817896
+v -0.923785 -0.110289 0.810920
+v -0.917793 0.105605 0.805026
+v -0.949557 0.118435 0.804940
+v -0.981430 0.144211 0.804957
+v -1.006395 0.178959 0.805648
+v -1.037029 0.171071 0.805989
+v -1.053515 0.139410 0.806248
+v -1.063667 0.105055 0.806407
+v -1.067095 0.069327 0.806460
+v -1.063667 0.033599 0.806407
+v -1.053515 -0.000755 0.806248
+v -1.037029 -0.032417 0.805989
+v -1.014843 -0.060169 0.805642
+v -0.987808 -0.082944 0.805218
+v -0.956966 -0.099867 0.804735
+v -0.923499 -0.110289 0.804211
+v -0.916416 0.106636 0.798779
+v -0.946809 0.121198 0.792549
+v -0.978086 0.148035 0.786387
+v -1.002990 0.184085 0.782334
+v -1.030107 0.171071 0.777305
+v -1.045824 0.139410 0.774375
+v -1.055502 0.105055 0.772571
+v -1.058770 0.069327 0.771962
+v -1.055502 0.033599 0.772571
+v -1.045824 -0.000755 0.774375
+v -1.030107 -0.032417 0.777305
+v -1.008956 -0.060169 0.781247
+v -0.983184 -0.082944 0.786052
+v -0.953780 -0.099867 0.791533
+v -0.921875 -0.110289 0.797480
+v -0.913859 0.108151 0.792925
+v -0.941519 0.124970 0.780992
+v -0.969813 0.155093 0.769376
+v -0.998435 0.198761 0.757718
+v -1.017752 0.171071 0.749633
+v -1.032095 0.139410 0.743628
+v -1.040928 0.105055 0.739930
+v -1.043910 0.069327 0.738681
+v -1.040928 0.033599 0.739930
+v -1.032095 -0.000755 0.743628
+v -1.017752 -0.032417 0.749633
+v -0.998449 -0.060169 0.757715
+v -0.974928 -0.082944 0.767562
+v -0.948093 -0.099867 0.778797
+v -0.918976 -0.110289 0.790988
+v -0.910332 0.109658 0.787636
+v -0.934346 0.128011 0.770420
+v -0.958936 0.157463 0.753273
+v -0.983723 0.198822 0.735948
+v -1.000436 0.171071 0.724038
+v -1.012855 0.139410 0.715188
+v -1.020503 0.105055 0.709738
+v -1.023085 0.069327 0.707898
+v -1.020503 0.033599 0.709738
+v -1.012855 -0.000755 0.715188
+v -1.000436 -0.032417 0.724038
+v -0.983723 -0.060169 0.735948
+v -0.963358 -0.082944 0.750460
+v -0.940124 -0.099867 0.767017
+v -0.914913 -0.110289 0.784982
+v -0.906016 0.111060 0.783036
+v -0.925554 0.130997 0.761135
+v -0.945557 0.162077 0.739272
+v -0.965346 0.198823 0.716783
+v -0.978827 0.171071 0.701502
+v -0.988844 0.139410 0.690148
+v -0.995013 0.105055 0.683156
+v -0.997096 0.069327 0.680795
+v -0.995013 0.033599 0.683156
+v -0.988844 -0.000755 0.690148
+v -0.978827 -0.032417 0.701502
+v -0.965346 -0.060169 0.716783
+v -0.948919 -0.082944 0.735402
+v -0.930178 -0.099867 0.756645
+v -0.909843 -0.110289 0.779695
+v -0.901069 0.112214 0.779233
+v -0.915486 0.133416 0.753375
+v -0.930270 0.166676 0.727294
+v -0.944022 0.198821 0.700958
+v -0.953753 0.171071 0.682893
+v -0.960984 0.139410 0.669471
+v -0.965437 0.105055 0.661205
+v -0.966940 0.069327 0.658414
+v -0.965437 0.033599 0.661205
+v -0.960984 -0.000755 0.669471
+v -0.953753 -0.032417 0.682893
+v -0.944023 -0.060169 0.700957
+v -0.932166 -0.082944 0.722968
+v -0.918638 -0.099867 0.748080
+v -0.903960 -0.110289 0.775328
+v -0.895626 0.111755 0.776282
+v -0.904334 0.134112 0.747446
+v -0.913069 0.167604 0.718179
+v -0.920573 0.198823 0.689078
+v -0.926180 0.171071 0.668925
+v -0.930346 0.139410 0.653950
+v -0.932912 0.105055 0.644729
+v -0.933778 0.069327 0.641615
+v -0.932912 0.033599 0.644729
+v -0.930346 -0.000755 0.653950
+v -0.926180 -0.032417 0.668925
+v -0.920573 -0.060169 0.689078
+v -0.913742 -0.082944 0.713635
+v -0.905947 -0.099867 0.741651
+v -0.897490 -0.110289 0.772051
+v -0.889762 0.111002 0.774361
+v -0.892562 0.134385 0.743651
+v -0.895152 0.169335 0.712297
+v -0.895899 0.198823 0.681603
+v -0.897166 0.171071 0.660135
+v -0.898108 0.139410 0.644183
+v -0.898687 0.105055 0.634360
+v -0.898883 0.069327 0.631043
+v -0.898687 0.033599 0.634360
+v -0.898108 -0.000755 0.644183
+v -0.897166 -0.032417 0.660135
+v -0.895899 -0.060169 0.681603
+v -0.894355 -0.082944 0.707762
+v -0.892594 -0.099867 0.737606
+v -0.890683 -0.110289 0.769989
+v -0.883738 0.110630 0.773750
+v -0.880559 0.133393 0.742262
+v -0.876971 0.168158 0.709891
+v -0.870948 0.198823 0.678819
+v -0.867827 0.171071 0.656861
+v -0.865507 0.139410 0.640545
+v -0.864079 0.105055 0.630498
+v -0.863597 0.069327 0.627105
+v -0.864079 0.033599 0.630498
+v -0.865507 -0.000755 0.640545
+v -0.867827 -0.032417 0.656861
+v -0.870948 -0.060169 0.678819
+v -0.874751 -0.082944 0.705574
+v -0.879090 -0.099867 0.736099
+v -0.883799 -0.110289 0.769220
+v -0.877838 0.109884 0.774405
+v -0.868491 0.130362 0.743495
+v -0.858373 0.162037 0.711872
+v -0.846679 0.198823 0.680832
+v -0.839289 0.171071 0.659229
+v -0.833798 0.139410 0.643176
+v -0.830417 0.105055 0.633291
+v -0.829275 0.069327 0.629953
+v -0.830417 0.033599 0.633291
+v -0.833798 -0.000755 0.643176
+v -0.839289 -0.032417 0.659229
+v -0.846679 -0.060169 0.680832
+v -0.855683 -0.082944 0.707156
+v -0.865956 -0.099867 0.737189
+v -0.877103 -0.110289 0.769776
+v -0.872176 0.110631 0.776393
+v -0.856963 0.127180 0.747197
+v -0.841001 0.157407 0.717612
+v -0.824024 0.198823 0.687566
+v -0.812650 0.171071 0.667147
+v -0.804199 0.139410 0.651974
+v -0.798994 0.105055 0.642631
+v -0.797237 0.069327 0.639476
+v -0.798994 0.033599 0.642631
+v -0.804199 -0.000755 0.651974
+v -0.812650 -0.032417 0.667147
+v -0.824024 -0.060169 0.687566
+v -0.837883 -0.082944 0.712447
+v -0.853695 -0.099867 0.740833
+v -0.870852 -0.110289 0.771634
+v -0.866903 0.109523 0.779436
+v -0.846467 0.125727 0.753212
+v -0.825399 0.156023 0.726481
+v -0.803855 0.198823 0.698761
+v -0.788934 0.171071 0.680311
+v -0.777846 0.139410 0.666602
+v -0.771019 0.105055 0.658159
+v -0.768713 0.069327 0.655308
+v -0.771019 0.033599 0.658159
+v -0.777846 -0.000755 0.666602
+v -0.788934 -0.032417 0.680311
+v -0.803855 -0.060169 0.698761
+v -0.822037 -0.082944 0.721243
+v -0.842780 -0.099867 0.746892
+v -0.865288 -0.110289 0.774723
+v -0.862351 0.109562 0.783572
+v -0.837570 0.126715 0.761314
+v -0.812291 0.157574 0.738378
+v -0.786946 0.198823 0.713988
+v -0.769051 0.171071 0.698216
+v -0.755754 0.139410 0.686496
+v -0.747565 0.105055 0.679279
+v -0.744800 0.069327 0.676842
+v -0.747565 0.033599 0.679279
+v -0.755754 -0.000755 0.686496
+v -0.769051 -0.032417 0.698216
+v -0.786946 -0.060169 0.713988
+v -0.808751 -0.082944 0.733206
+v -0.833629 -0.099867 0.755132
+v -0.860622 -0.110289 0.778924
+v -0.858846 0.110952 0.788547
+v -0.830706 0.128755 0.770964
+v -0.802114 0.161643 0.752724
+v -0.773947 0.198823 0.732661
+v -0.753766 0.171071 0.720173
+v -0.738770 0.139410 0.710894
+v -0.729536 0.105055 0.705180
+v -0.726417 0.069327 0.703250
+v -0.729536 0.033599 0.705180
+v -0.738770 -0.000755 0.710894
+v -0.753766 -0.032417 0.720173
+v -0.773947 -0.060169 0.732661
+v -0.798538 -0.082944 0.747878
+v -0.826594 -0.099867 0.765238
+v -0.857036 -0.110289 0.784075
+v -0.856630 0.113125 0.793972
+v -0.826435 0.132465 0.781603
+v -0.795729 0.167607 0.768372
+v -0.765358 0.198823 0.754063
+v -0.743666 0.171071 0.745339
+v -0.727548 0.139410 0.738857
+v -0.717622 0.105055 0.734865
+v -0.714271 0.069327 0.733517
+v -0.717622 0.033599 0.734865
+v -0.727548 -0.000755 0.738857
+v -0.743666 -0.032417 0.745339
+v -0.765358 -0.060169 0.754063
+v -0.791790 -0.082944 0.764693
+v -0.821946 -0.099867 0.776821
+v -0.854666 -0.110289 0.789980
+v -0.855735 0.115404 0.799635
+v -0.824640 0.134309 0.793029
+v -0.793462 0.163081 0.785518
+v -0.761509 0.198823 0.777371
+v -0.739140 0.171071 0.772746
+v -0.722518 0.139410 0.769310
+v -0.712283 0.105055 0.767194
+v -0.708827 0.069327 0.766479
+v -0.712283 0.033599 0.767194
+v -0.722519 -0.000755 0.769310
+v -0.739140 -0.032417 0.772746
+v -0.761509 -0.060169 0.777371
+v -0.788766 -0.082944 0.783006
+v -0.819862 -0.099867 0.789435
+v -0.853604 -0.110289 0.796411
+v -0.855912 0.117033 0.805669
+v -0.825242 0.135866 0.805083
+v -0.794364 0.162174 0.803689
+v -0.762547 0.198823 0.801689
+v -0.740361 0.171071 0.801342
+v -0.723875 0.139410 0.801083
+v -0.713723 0.105055 0.800924
+v -0.710295 0.069327 0.800871
+v -0.713723 0.033599 0.800924
+v -0.723875 -0.000755 0.801083
+v -0.740361 -0.032417 0.801342
+v -0.762547 -0.060169 0.801689
+v -0.789581 -0.082944 0.802113
+v -0.820424 -0.099867 0.802596
+v -0.853891 -0.110289 0.803120
+v -0.857125 0.119010 0.811770
+v -0.828152 0.136665 0.817148
+v -0.798761 0.164559 0.821820
+v -0.768434 0.198823 0.826084
+v -0.747282 0.171071 0.830026
+v -0.731566 0.139410 0.832956
+v -0.721888 0.105055 0.834760
+v -0.718620 0.069327 0.835370
+v -0.721888 0.033599 0.834760
+v -0.731566 -0.000755 0.832956
+v -0.747282 -0.032417 0.830026
+v -0.768434 -0.060169 0.826084
+v -0.794206 -0.082944 0.821279
+v -0.823610 -0.099867 0.815798
+v -0.855515 -0.110289 0.809851
+v -0.859463 0.120953 0.817597
+v -0.833166 0.138262 0.828689
+v -0.806381 0.168068 0.839193
+v -0.778941 0.198823 0.849616
+v -0.759638 0.171071 0.857698
+v -0.745295 0.139410 0.863703
+v -0.736462 0.105055 0.867401
+v -0.733480 0.069327 0.868650
+v -0.736462 0.033599 0.867401
+v -0.745295 -0.000755 0.863703
+v -0.759638 -0.032417 0.857698
+v -0.778941 -0.060169 0.849616
+v -0.802462 -0.082944 0.839769
+v -0.829297 -0.099867 0.828534
+v -0.858414 -0.110289 0.816343
+v -0.888695 -0.113807 0.803666
+v -0.862920 0.121973 0.822890
+v -0.840167 0.140091 0.839301
+v -0.817067 0.172159 0.855194
+v -0.793667 0.198823 0.871383
+v -0.776954 0.171071 0.883293
+v -0.764535 0.139410 0.892143
+v -0.756887 0.105055 0.897593
+v -0.754305 0.069327 0.899433
+v -0.756887 0.033599 0.897593
+v -0.764535 -0.000755 0.892143
+v -0.776954 -0.032417 0.883293
+v -0.793667 -0.060169 0.871383
+v -0.814032 -0.082944 0.856871
+v -0.837266 -0.099867 0.840314
+v -0.862477 -0.110289 0.822349
+v -0.867203 0.121924 0.827362
+v -0.848925 0.142079 0.848684
+v -0.830572 0.178690 0.869438
+v -0.812044 0.198823 0.890548
+v -0.798563 0.171071 0.905829
+v -0.788546 0.139410 0.917183
+v -0.782377 0.105055 0.924175
+v -0.780294 0.069327 0.926536
+v -0.782377 0.033599 0.924175
+v -0.788546 -0.000755 0.917183
+v -0.798563 -0.032417 0.905829
+v -0.812044 -0.060169 0.890548
+v -0.828471 -0.082944 0.871929
+v -0.847212 -0.099867 0.850686
+v -0.867547 -0.110289 0.827636
+v -0.872288 0.119615 0.830918
+v -0.859094 0.143088 0.856348
+v -0.846492 0.188867 0.881489
+v -0.833367 0.198823 0.906374
+v -0.823636 0.171071 0.924438
+v -0.816406 0.139410 0.937860
+v -0.811953 0.105055 0.946126
+v -0.810450 0.069327 0.948917
+v -0.811953 0.033599 0.946126
+v -0.816406 -0.000755 0.937860
+v -0.823636 -0.032417 0.924438
+v -0.833367 -0.060169 0.906374
+v -0.845224 -0.082944 0.884363
+v -0.858752 -0.099867 0.859251
+v -0.873430 -0.110289 0.832003
+v -0.878094 0.116394 0.833596
+v -0.870401 0.136881 0.862016
+v -0.863899 0.172816 0.890506
+v -0.856820 0.198797 0.918239
+v -0.851210 0.171071 0.938406
+v -0.847044 0.139410 0.953381
+v -0.844478 0.105055 0.962602
+v -0.843612 0.069327 0.965716
+v -0.844478 0.033599 0.962602
+v -0.847044 -0.000755 0.953381
+v -0.851210 -0.032417 0.938406
+v -0.856816 -0.060169 0.918253
+v -0.863648 -0.082944 0.893696
+v -0.871442 -0.099867 0.865680
+v -0.879900 -0.110289 0.835280
+v -0.884354 0.113251 0.835312
+v -0.882579 0.129995 0.865697
+v -0.881852 0.160637 0.896308
+v -0.881493 0.198775 0.925701
+v -0.880224 0.171071 0.947196
+v -0.879282 0.139410 0.963148
+v -0.878702 0.105055 0.972971
+v -0.878507 0.069327 0.976288
+v -0.878702 0.033599 0.972971
+v -0.879282 -0.000755 0.963148
+v -0.880224 -0.032417 0.947196
+v -0.881491 -0.060169 0.925728
+v -0.883035 -0.082944 0.899569
+v -0.884796 -0.099867 0.869725
+v -0.886707 -0.110289 0.837342
+v -0.890784 0.110833 0.835950
+v -0.895449 0.124746 0.867121
+v -0.900725 0.157100 0.897831
+v -0.906441 0.198811 0.928505
+v -0.909563 0.171071 0.950470
+v -0.911882 0.139410 0.966786
+v -0.913311 0.105055 0.976833
+v -0.913793 0.069327 0.980225
+v -0.913311 0.033599 0.976833
+v -0.911882 -0.000755 0.966786
+v -0.909563 -0.032417 0.950470
+v -0.906442 -0.060169 0.928512
+v -0.902639 -0.082944 0.901757
+v -0.898300 -0.099867 0.871232
+v -0.893591 -0.110289 0.838111
+v -0.897038 0.109615 0.835419
+v -0.907826 0.126885 0.865629
+v -0.919032 0.156820 0.895940
+v -0.930711 0.198823 0.926499
+v -0.938101 0.171071 0.948102
+v -0.943592 0.139410 0.964155
+v -0.946973 0.105055 0.974040
+v -0.948115 0.069327 0.977378
+v -0.946973 0.033599 0.974040
+v -0.943592 -0.000755 0.964155
+v -0.938101 -0.032417 0.948102
+v -0.930711 -0.060169 0.926499
+v -0.921707 -0.082944 0.900175
+v -0.911434 -0.099867 0.870142
+v -0.900287 -0.110289 0.837555
+v -0.902747 0.108911 0.833785
+v -0.919343 0.126336 0.862550
+v -0.936096 0.156384 0.890935
+v -0.953366 0.198823 0.919765
+v -0.964740 0.171071 0.940184
+v -0.973191 0.139410 0.955357
+v -0.978396 0.105055 0.964700
+v -0.980153 0.069327 0.967855
+v -0.978396 0.033599 0.964700
+v -0.973191 -0.000755 0.955357
+v -0.964740 -0.032417 0.940184
+v -0.953366 -0.060169 0.919765
+v -0.939506 -0.082944 0.894884
+v -0.923694 -0.099867 0.866498
+v -0.906538 -0.110289 0.835697
+v -0.886821 0.108050 0.805276
+v -0.907688 0.108589 0.831044
+v -0.929275 0.124972 0.857060
+v -0.951206 0.155948 0.882674
+v -0.973533 0.198816 0.908568
+v -0.988456 0.171071 0.927020
+v -0.999544 0.139410 0.940729
+v -1.006371 0.105055 0.949172
+v -1.008677 0.069327 0.952022
+v -1.006371 0.033599 0.949172
+v -0.999544 -0.000755 0.940729
+v -0.988456 -0.032417 0.927020
+v -0.973535 -0.060169 0.908570
+v -0.955353 -0.082944 0.886088
+v -0.934610 -0.099867 0.860439
+v -0.912102 -0.110289 0.832609
+v -0.911797 0.107654 0.827343
+v -0.937569 0.123775 0.849490
+v -0.963876 0.154073 0.871440
+v -0.985613 0.187155 0.889769
+v -1.008339 0.171071 0.909115
+v -1.021636 0.139410 0.920835
+v -1.029824 0.105055 0.928052
+v -1.032589 0.069327 0.930489
+v -1.029825 0.033599 0.928052
+v -1.021636 -0.000755 0.920835
+v -1.008339 -0.032417 0.909115
+v -0.990444 -0.060169 0.893343
+v -0.968638 -0.082944 0.874125
+v -0.943761 -0.099867 0.852199
+v -0.916767 -0.110289 0.828407
+vn -0.943907 0.197516 0.264595
+vn 0.474410 0.846034 -0.243110
+vn 0.189673 0.975890 -0.107700
+vn -0.724845 -0.567095 0.391125
+vn -0.202490 -0.979186 0.011109
+vn -0.998108 0.000000 0.061373
+vn -0.972839 0.187139 -0.135990
+vn -0.860256 -0.178137 -0.477676
+vn 0.428510 0.772362 0.468856
+vn 0.369884 0.764306 0.528184
+vn -0.874294 0.000000 -0.485366
+vn -0.328166 -0.906491 -0.265633
+vn -0.030274 0.999146 -0.027039
+vn -0.493789 -0.664998 -0.560259
+vn 0.312662 0.748894 0.584246
+vn 0.166234 0.917997 0.359996
+vn -0.081942 -0.975890 -0.202246
+vn -0.009033 -0.818598 -0.574236
+vn -0.064699 0.946013 0.317515
+vn 0.026704 0.998230 -0.052797
+vn 0.272134 -0.710532 -0.648854
+vn -0.317606 0.829768 0.458876
+vn 0.316660 -0.837947 -0.444441
+vn 0.478469 0.567003 -0.670431
+vn 0.532487 -0.833369 -0.148076
+vn 0.972869 0.187139 0.135990
+vn 0.553331 -0.811121 0.189276
+vn 0.387494 -0.912198 0.133030
+vn 0.860256 0.178137 0.477676
+vn 0.171636 -0.975249 0.139225
+vn -0.344157 0.863186 -0.369366
+vn -0.512497 0.624989 -0.588794
+vn 0.081942 -0.975890 0.202216
+vn 0.009033 -0.818598 0.574236
+vn 0.044038 -0.976867 0.209235
+vn -0.154302 -0.549699 0.820948
+vn 0.154057 0.811884 -0.563097
+vn -0.054750 0.636555 -0.769250
+vn 0.002075 0.999268 0.037935
+vn -0.071047 -0.920469 0.384289
+vn -0.010163 0.999207 0.038087
+vn -0.087680 0.942198 -0.323344
+vn 0.161962 0.802271 -0.574541
+vn -0.272164 -0.710532 0.648854
+vn -0.213446 -0.833277 0.509964
+vn -0.520859 -0.719382 0.459517
+vn 0.336100 0.820551 -0.462233
+usemtl Body
+s 1
+f 5791//3529 5790//3530 5805//3531
+f 5786//3532 5785//3533 5800//3534
+f 5797//3535 5796//3536 5812//3537
+f 5792//3538 5791//3529 5806//4010
+f 5787//3540 5786//3532 5801//4011
+f 5798//3542 5797//3535 5813//3543
+f 5793//3544 5792//3538 5808//3545
+f 5788//4012 5787//3540 5802//3547
+f 5799//3548 5798//3542 5814//3549
+f 5794//3550 5793//3544 5809//3551
+f 5789//3552 5788//4012 5803//3553
+f 5795//4013 5794//3550 5810//3555
+f 5790//3530 5789//3552 5804//3556
+f 5796//3536 5795//4013 5811//3557
+f 5811//3557 5810//3555 5826//3558
+f 5806//4010 5805//3531 5820//3559
+f 5801//4011 5800//3534 5815//3560
+f 5812//3537 5811//3557 5827//3561
+f 5807//3562 5806//4010 5821//3563
+f 5802//3547 5801//4011 5816//3564
+f 5813//3543 5812//3537 5828//3565
+f 5808//3545 5807//3562 5823//3566
+f 5803//3553 5802//3547 5817//3567
+f 5814//3549 5813//3543 5829//4014
+f 5809//3551 5808//3545 5824//3569
+f 5804//3556 5803//3553 5818//3570
+f 5810//3555 5809//3551 5825//3571
+f 5805//3531 5804//3556 5819//3572
+f 5825//3571 5824//3569 5840//3573
+f 5820//3559 5819//3572 5834//3574
+f 5826//3558 5825//3571 5841//3575
+f 5821//3563 5820//3559 5835//3576
+f 5816//3564 5815//3560 5830//3577
+f 5827//3561 5826//3558 5842//3578
+f 5822//4015 5821//3563 5836//4016
+f 5817//3567 5816//3564 5831//3581
+f 5828//3565 5827//3561 5843//3582
+f 5823//3566 5822//4015 5838//3583
+f 5818//3570 5817//3567 5832//3584
+f 5829//4014 5828//3565 5844//3585
+f 5824//3569 5823//3566 5839//3586
+f 5819//3572 5818//3570 5833//3587
+f 5844//3585 5843//3582 5859//3588
+f 5839//3586 5838//3583 5854//3589
+f 5834//3574 5833//3587 5848//3590
+f 5840//3573 5839//3586 5855//3591
+f 5835//3576 5834//3574 5849//3592
+f 5841//3575 5840//3573 5856//3593
+f 5836//4016 5835//3576 5850//3594
+f 5831//3581 5830//3577 5845//3595
+f 5842//3578 5841//3575 5857//3596
+f 5837//3597 5836//4016 5851//3598
+f 5832//3584 5831//3581 5847//3599
+f 5843//3582 5842//3578 5858//3600
+f 5838//3583 5837//3597 5853//3601
+f 5833//3587 5832//3584 5848//3590
+f 5847//3599 5846//3602 5862//3603
+f 5858//3600 5857//3596 5873//3604
+f 5853//3601 5852//3605 5868//4017
+f 5848//3590 5847//3599 5863//3607
+f 5859//3588 5858//3600 5874//3608
+f 5854//3589 5853//3601 5869//3609
+f 5849//3592 5848//3590 5863//3607
+f 5855//3591 5854//3589 5870//3610
+f 5850//3594 5849//3592 5864//3611
+f 5856//3593 5855//3591 5871//3612
+f 5851//3598 5850//3594 5865//3613
+f 5846//3602 5845//3595 5861//4018
+f 5857//3596 5856//3593 5872//3615
+f 5852//3605 5851//3598 5866//3616
+f 5866//3616 5865//3613 5880//3617
+f 5861//4018 5860//3618 5876//4019
+f 5872//3615 5871//3612 5887//3620
+f 5867//4020 5866//3616 5881//3622
+f 5862//3603 5861//4018 5877//3623
+f 5873//3604 5872//3615 5888//4021
+f 5868//4017 5867//4020 5883//3625
+f 5863//3607 5862//3603 5877//3623
+f 5874//3608 5873//3604 5889//3626
+f 5869//3609 5868//4017 5884//3627
+f 5864//3611 5863//3607 5878//4022
+f 5870//3610 5869//3609 5885//3629
+f 5865//3613 5864//3611 5879//3630
+f 5871//3612 5870//3610 5886//3631
+f 5885//3629 5884//3627 5900//3632
+f 5880//3617 5879//3630 5894//3633
+f 5886//3631 5885//3629 5901//4023
+f 5881//3622 5880//3617 5895//3635
+f 5876//4019 5875//3636 5891//4024
+f 5887//3620 5886//3631 5902//3638
+f 5882//3639 5881//3622 5896//3640
+f 5877//3623 5876//4019 5892//3641
+f 5888//4021 5887//3620 5903//3642
+f 5883//3625 5882//3639 5898//3643
+f 5878//4022 5877//3623 5893//3644
+f 5889//3626 5888//4021 5904//3645
+f 5884//3627 5883//3625 5899//3646
+f 5879//3630 5878//4022 5893//3644
+f 5904//3645 5903//3642 5918//3647
+f 5899//3646 5898//3643 5913//3648
+f 5894//3633 5893//3644 5909//3649
+f 5900//3632 5899//3646 5914//3650
+f 5895//3635 5894//3633 5910//3651
+f 5901//4023 5900//3632 5915//3652
+f 5896//3640 5895//3635 5911//3653
+f 5891//4024 5890//3654 5906//3655
+f 5902//3638 5901//4023 5916//3656
+f 5897//3657 5896//3640 5912//3658
+f 5892//3641 5891//4024 5907//3659
+f 5903//3642 5902//3638 5917//3660
+f 5898//3643 5897//3657 5912//3658
+f 5893//3644 5892//3641 5908//3661
+f 5907//3659 5906//3655 5922//3662
+f 5918//3647 5917//3660 5932//3663
+f 5913//3648 5912//3658 5927//3664
+f 5908//3661 5907//3659 5923//3665
+f 5919//3666 5918//3647 5933//3667
+f 5914//3650 5913//3648 5928//3668
+f 5909//3649 5908//3661 5924//3669
+f 5915//3652 5914//3650 5929//3670
+f 5910//3651 5909//3649 5925//3671
+f 5916//3656 5915//3652 5930//3672
+f 5911//3653 5910//3651 5926//3673
+f 5906//3655 5905//4025 5921//3675
+f 5917//3660 5916//3656 5931//3676
+f 5912//3658 5911//3653 5927//3664
+f 5926//3673 5925//3671 5941//3677
+f 5921//3675 5920//3678 5936//3679
+f 5932//3663 5931//3676 5946//3680
+f 5927//3664 5926//3673 5942//3681
+f 5922//3662 5921//3675 5937//3682
+f 5933//3667 5932//3663 5947//3683
+f 5928//3668 5927//3664 5942//3681
+f 5923//3665 5922//3662 5938//3684
+f 5934//4026 5933//3667 5948//3686
+f 5929//3670 5928//3668 5943//3687
+f 5924//3669 5923//3665 5939//3688
+f 5930//3672 5929//3670 5944//3689
+f 5925//3671 5924//3669 5940//3690
+f 5931//3676 5930//3672 5945//3691
+f 5945//3691 5944//3689 5959//3692
+f 5940//3690 5939//3688 5955//3693
+f 5946//3680 5945//3691 5960//3694
+f 5941//3677 5940//3690 5956//3695
+f 5936//3679 5935//3696 5951//3697
+f 5947//3683 5946//3680 5961//3698
+f 5942//3681 5941//3677 5957//3699
+f 5937//3682 5936//3679 5952//3700
+f 5948//3686 5947//3683 5962//4027
+f 5943//3687 5942//3681 5957//3699
+f 5938//3684 5937//3682 5953//3702
+f 5949//3703 5948//3686 5963//3704
+f 5944//3689 5943//3687 5958//3705
+f 5939//3688 5938//3684 5954//3706
+f 5964//3707 5963//3704 5978//3708
+f 5959//3692 5958//3705 5973//3709
+f 5954//3706 5953//3702 5969//3710
+f 5960//3694 5959//3692 5974//3711
+f 5955//3693 5954//3706 5970//3712
+f 5961//3698 5960//3694 5975//3713
+f 5956//3695 5955//3693 5971//3714
+f 5951//3697 5950//3715 5965//4028
+f 5962//4027 5961//3698 5976//3717
+f 5957//3699 5956//3695 5972//3718
+f 5952//3700 5951//3697 5966//3719
+f 5963//3704 5962//4027 5977//3720
+f 5958//3705 5957//3699 5972//3718
+f 5953//3702 5952//3700 5968//3721
+f 5978//3708 5977//3720 5992//3722
+f 5973//3709 5972//3718 5987//3723
+f 5968//3721 5967//3724 5983//4029
+f 5979//3726 5978//3708 5993//3727
+f 5974//3711 5973//3709 5988//3728
+f 5969//3710 5968//3721 5984//3729
+f 5975//3713 5974//3711 5989//3730
+f 5970//3712 5969//3710 5985//3731
+f 5976//3717 5975//3713 5990//3732
+f 5971//3714 5970//3712 5986//3733
+f 5966//3719 5965//4028 5980//3734
+f 5977//3720 5976//3717 5991//4030
+f 5972//3718 5971//3714 5987//3723
+f 5967//3724 5966//3719 5981//3736
+f 5981//3736 5980//3734 5995//3737
+f 5992//3722 5991//4030 6006//3738
+f 5987//3723 5986//3733 6002//3739
+f 5982//3740 5981//3736 5996//4031
+f 5993//3727 5992//3722 6007//4032
+f 5988//3728 5987//3723 6002//3739
+f 5983//4029 5982//3740 5998//3743
+f 5994//3744 5993//3727 6008//3745
+f 5989//3730 5988//3728 6003//3746
+f 5984//3729 5983//4029 5999//4033
+f 5990//3732 5989//3730 6004//3748
+f 5985//3731 5984//3729 6000//3749
+f 5991//4030 5990//3732 6005//3750
+f 5986//3733 5985//3731 6001//3751
+f 6000//3749 5999//4033 6015//3752
+f 6006//3738 6005//3750 6020//3753
+f 6001//3751 6000//3749 6016//3754
+f 5996//4031 5995//3737 6011//3755
+f 6007//4032 6006//3738 6021//3756
+f 6002//3739 6001//3751 6017//3757
+f 5997//3758 5996//4031 6012//3759
+f 6008//3745 6007//4032 6022//3760
+f 6003//3746 6002//3739 6017//3757
+f 5998//3743 5997//3758 6013//3761
+f 6009//3762 6008//3745 6023//3763
+f 6004//3748 6003//3746 6018//3764
+f 5999//4033 5998//3743 6014//3765
+f 6005//3750 6004//3748 6019//3766
+f 6019//3766 6018//3764 6034//3767
+f 6014//3765 6013//3761 6028//3768
+f 6020//3753 6019//3766 6035//3769
+f 6015//3752 6014//3765 6029//3770
+f 6021//3756 6020//3753 6036//3771
+f 6016//3754 6015//3752 6030//3772
+f 6011//3755 6010//3773 6026//3774
+f 6022//3760 6021//3756 6037//3775
+f 6017//3757 6016//3754 6031//3776
+f 6012//3759 6011//3755 6027//3777
+f 6023//3763 6022//3760 6038//3778
+f 6018//3764 6017//3757 6033//3779
+f 6013//3761 6012//3759 6028//3768
+f 6024//3780 6023//3763 6039//3781
+f 6038//3778 6037//3775 6053//3782
+f 6033//3779 6032//3783 6048//3784
+f 6028//3768 6027//3777 6043//3785
+f 6039//3781 6038//3778 6054//3786
+f 6034//3767 6033//3779 6049//3787
+f 6029//3770 6028//3768 6043//3785
+f 6035//3769 6034//3767 6050//3788
+f 6030//3772 6029//3770 6044//3789
+f 6036//3771 6035//3769 6051//3790
+f 6031//3776 6030//3772 6045//3791
+f 6026//3774 6025//3792 6041//3793
+f 6037//3775 6036//3771 6052//4034
+f 6032//3783 6031//3776 6046//3795
+f 6027//3777 6026//3774 6042//3796
+f 6041//3793 6040//3797 6055//3798
+f 6052//4034 6051//3790 6067//3799
+f 6047//3800 6046//3795 6061//3801
+f 6042//3796 6041//3793 6056//3802
+f 6053//3782 6052//4034 6068//3803
+f 6048//3784 6047//3800 6063//3804
+f 6043//3785 6042//3796 6057//3805
+f 6054//3786 6053//3782 6069//3806
+f 6049//3787 6048//3784 6064//3807
+f 6044//3789 6043//3785 6058//3808
+f 6050//3788 6049//3787 6065//3809
+f 6045//3791 6044//3789 6059//3810
+f 6051//3790 6050//3788 6066//3811
+f 6046//3795 6045//3791 6060//3812
+f 6060//3812 6059//3810 6074//3813
+f 6066//3811 6065//3809 6081//3814
+f 6061//3801 6060//3812 6075//3815
+f 6056//3802 6055//3798 6070//3816
+f 6067//3799 6066//3811 6082//3817
+f 6062//3818 6061//3801 6076//4035
+f 6057//3805 6056//3802 6071//3820
+f 6068//3803 6067//3799 6083//3821
+f 6063//3804 6062//3818 6078//3822
+f 6058//3808 6057//3805 6072//3823
+f 6069//3806 6068//3803 6084//3824
+f 6064//3807 6063//3804 6079//3825
+f 6059//3810 6058//3808 6073//3826
+f 6065//3809 6064//3807 6080//3827
+f 6079//3825 6078//3822 6094//3828
+f 6074//3813 6073//3826 6088//3829
+f 6080//3827 6079//3825 6095//3830
+f 6075//3815 6074//3813 6089//3831
+f 6081//3814 6080//3827 6096//3832
+f 6076//4035 6075//3815 6090//3833
+f 6071//3820 6070//3816 6085//3834
+f 6082//3817 6081//3814 6097//4036
+f 6077//3836 6076//4035 6091//3837
+f 6072//3823 6071//3820 6086//3838
+f 6083//3821 6082//3817 6098//4037
+f 6078//3822 6077//3836 6093//3840
+f 6073//3826 6072//3823 6087//3841
+f 6084//3824 6083//3821 6099//3842
+f 6098//4037 6097//4036 6113//3843
+f 6093//3840 6092//3844 6108//3845
+f 6088//3829 6087//3841 6102//3846
+f 6099//3842 6098//4037 6114//3847
+f 6094//3828 6093//3840 6109//3848
+f 6089//3831 6088//3829 6103//3849
+f 6095//3830 6094//3828 6110//3850
+f 6090//3833 6089//3831 6104//3851
+f 6096//3832 6095//3830 6111//3852
+f 6091//3837 6090//3833 6105//3853
+f 6086//3838 6085//3834 6101//3854
+f 6097//4036 6096//3832 6112//3855
+f 6092//3844 6091//3837 6106//4038
+f 6087//3841 6086//3838 6102//3846
+f 6112//3855 6111//3852 6128//3857
+f 6107//3858 6106//4038 6122//3859
+f 6102//3846 6101//3854 6118//3860
+f 6113//3843 6112//3855 6129//3861
+f 6108//3845 6107//3858 6124//3862
+f 6103//3849 6102//3846 6118//3860
+f 6114//3847 6113//3843 6130//4039
+f 6109//3848 6108//3845 6125//3864
+f 6104//3851 6103//3849 6119//3865
+f 6110//3850 6109//3848 6126//3866
+f 6105//3853 6104//3851 6120//3867
+f 6111//3852 6110//3850 6127//3868
+f 6106//4038 6105//3853 6121//3869
+f 6101//3854 6100//3870 6117//3871
+f 6127//3868 6126//3866 6142//3872
+f 6122//3859 6121//3869 6136//3873
+f 6117//3871 6116//4040 6132//3875
+f 6128//3857 6127//3868 6143//3876
+f 6123//3877 6122//3859 6137//3878
+f 6118//3860 6117//3871 6133//3879
+f 6129//3861 6128//3857 6144//3880
+f 6124//3862 6123//3877 6139//3881
+f 6119//3865 6118//3860 6134//3882
+f 6130//4039 6129//3861 6145//3883
+f 6125//3864 6124//3862 6140//3884
+f 6120//3867 6119//3865 6134//3882
+f 6126//3866 6125//3864 6141//3885
+f 6121//3869 6120//3867 6135//3886
+f 6135//3886 6134//3882 6150//3887
+f 6141//3885 6140//3884 6155//3888
+f 6136//3873 6135//3886 6151//3889
+f 6142//3872 6141//3885 6156//3890
+f 6137//3878 6136//3873 6152//3891
+f 6132//3875 6131//3892 6146//3893
+f 6143//3876 6142//3872 6157//3894
+f 6138//3895 6137//3878 6153//3896
+f 6133//3879 6132//3875 6148//3897
+f 6144//3880 6143//3876 6158//3898
+f 6139//3881 6138//3895 6153//3896
+f 6134//3882 6133//3879 6149//3899
+f 6145//3883 6144//3880 6159//3900
+f 6140//3884 6139//3881 6154//3901
+f 6154//3901 6153//3896 6168//3902
+f 6149//3899 6148//3897 6163//3903
+f 6160//3904 6159//3900 6174//3905
+f 6155//3888 6154//3901 6169//3906
+f 6150//3887 6149//3899 6165//3907
+f 6156//3890 6155//3888 6170//3908
+f 6151//3889 6150//3887 6166//3909
+f 6157//3894 6156//3890 6171//3910
+f 6152//3891 6151//3889 6167//3911
+f 6147//4041 6146//3893 6161//3913
+f 6158//3898 6157//3894 6172//3914
+f 6153//3896 6152//3891 6168//3902
+f 6148//3897 6147//4041 6162//3915
+f 6159//3900 6158//3898 6173//3916
+f 6173//3916 6172//3914 6187//3917
+f 6168//3902 6167//3911 6183//3918
+f 6163//3903 6162//3915 6177//3919
+f 6174//3905 6173//3916 6188//3920
+f 6169//3906 6168//3902 6183//3918
+f 6164//3921 6163//3903 6178//3922
+f 6175//4042 6174//3905 6189//3924
+f 6170//3908 6169//3906 6184//3925
+f 6165//3907 6164//3921 6180//3926
+f 6171//3910 6170//3908 6185//3927
+f 6166//3909 6165//3907 6181//3928
+f 6172//3914 6171//3910 6186//3929
+f 6167//3911 6166//3909 6182//3930
+f 6162//3915 6161//3913 6176//3931
+f 6187//3917 6186//3929 6201//3932
+f 6182//3930 6181//3928 6197//3933
+f 6177//3919 6176//3931 6191//3934
+f 6188//3920 6187//3917 6202//3935
+f 6183//3918 6182//3930 6198//3936
+f 6178//3922 6177//3919 6192//3937
+f 6189//3924 6188//3920 6203//4043
+f 6184//3925 6183//3918 6198//3936
+f 6179//3939 6178//3922 6194//3940
+f 6190//4044 6189//3924 6204//3942
+f 6185//3927 6184//3925 6199//3943
+f 6180//3926 6179//3939 6195//3944
+f 6186//3929 6185//3927 6200//3945
+f 6181//3928 6180//3926 6196//3946
+f 6195//3944 6194//3940 6210//3947
+f 6201//3932 6200//3945 6215//3948
+f 6196//3946 6195//3944 6211//3949
+f 6202//3935 6201//3932 6216//4045
+f 6197//3933 6196//3946 6212//3951
+f 6192//3937 6191//3934 6207//4046
+f 6203//4043 6202//3935 6217//3953
+f 6198//3936 6197//3933 6213//3954
+f 6193//4047 6192//3937 6208//3956
+f 6204//3942 6203//4043 6218//3957
+f 6199//3943 6198//3936 6213//3954
+f 6194//3940 6193//4047 6209//4048
+f 6205//3959 6204//3942 6219//4049
+f 6200//3945 6199//3943 6214//3961
+f 6214//3961 6213//3954 6228//3962
+f 6209//4048 6208//3956 6224//4050
+f 6220//3964 6219//4049 6234//3965
+f 6215//3948 6214//3961 6229//3966
+f 6210//3947 6209//4048 6225//3967
+f 6216//4045 6215//3948 6230//3968
+f 6211//3949 6210//3947 6226//3969
+f 6217//3953 6216//4045 6231//3970
+f 6212//3951 6211//3949 6227//3971
+f 6207//4046 6206//4051 6222//4052
+f 6218//3957 6217//3953 6232//4053
+f 6213//3954 6212//3951 6228//3962
+f 6208//3956 6207//4046 6223//3975
+f 6219//4049 6218//3957 6233//4054
+f 6233//4054 6232//4053 6248//3977
+f 6228//3962 6227//3971 6244//3978
+f 6223//3975 6222//4052 6239//3979
+f 6234//3965 6233//4054 6249//3980
+f 6229//3966 6228//3962 6244//3978
+f 6224//4050 6223//3975 6240//3981
+f 6235//3982 6234//3965 6250//3983
+f 6230//3968 6229//3966 6245//3984
+f 6225//3967 6224//4050 6241//3985
+f 6231//3970 6230//3968 6246//3986
+f 6226//3969 6225//3967 6242//3987
+f 6232//4053 6231//3970 6247//3988
+f 6227//3971 6226//3969 6243//3989
+f 6222//4052 6221//3990 6238//3991
+f 6248//3977 6247//3988 6262//3992
+f 6243//3989 6242//3987 6258//3993
+f 6238//3991 6237//3994 6252//3995
+f 6249//3980 6248//3977 6263//4055
+f 6244//3978 6243//3989 6259//3997
+f 6239//3979 6238//3991 6253//4056
+f 6250//3983 6249//3980 6264//3999
+f 6245//3984 6244//3978 6259//3997
+f 6240//3981 6239//3979 6254//4000
+f 6251//4001 6250//3983 6265//4002
+f 6246//3986 6245//3984 6260//4003
+f 6241//3985 6240//3981 6256//4004
+f 6247//3988 6246//3986 6261//4005
+f 6242//3987 6241//3985 6257//4006
+f 6115//364 5799//3548 5814//3549
+f 5785//3533 6236//4007 5800//3534
+f 6115//364 5814//3549 5829//4014
+f 5800//3534 6236//4007 5815//3560
+f 6115//364 5829//4014 5844//3585
+f 5815//3560 6236//4007 5830//3577
+f 6115//364 5844//3585 5859//3588
+f 5830//3577 6236//4007 5845//3595
+f 6115//364 5859//3588 5874//3608
+f 5845//3595 6236//4007 5860//3618
+f 6115//364 5874//3608 5889//3626
+f 5860//3618 6236//4007 5875//3636
+f 5875//3636 6236//4007 5890//3654
+f 6115//364 5889//3626 5904//3645
+f 6115//364 5904//3645 5919//3666
+f 5890//3654 6236//4007 5905//4025
+f 6115//364 5919//3666 5934//4026
+f 5905//4025 6236//4007 5920//3678
+f 6115//364 5934//4026 5949//3703
+f 5920//3678 6236//4007 5935//3696
+f 5935//3696 6236//4007 5950//3715
+f 6115//364 5949//3703 5964//3707
+f 6115//364 5964//3707 5979//3726
+f 5950//3715 6236//4007 5965//4028
+f 6115//364 5979//3726 5994//3744
+f 5965//4028 6236//4007 5980//3734
+f 6115//364 5994//3744 6009//3762
+f 5980//3734 6236//4007 5995//3737
+f 5995//3737 6236//4007 6010//3773
+f 6115//364 6009//3762 6024//3780
+f 6115//364 6024//3780 6039//3781
+f 6010//3773 6236//4007 6025//3792
+f 6115//364 6039//3781 6054//3786
+f 6025//3792 6236//4007 6040//3797
+f 6115//364 6054//3786 6069//3806
+f 6040//3797 6236//4007 6055//3798
+f 6055//3798 6236//4007 6070//3816
+f 6115//364 6069//3806 6084//3824
+f 6115//364 6084//3824 6099//3842
+f 6070//3816 6236//4007 6085//3834
+f 6115//364 6099//3842 6114//3847
+f 6085//3834 6236//4007 6100//3870
+f 6115//364 6114//3847 6130//4039
+f 6100//3870 6236//4007 6116//4040
+f 6116//4040 6236//4007 6131//3892
+f 6115//364 6130//4039 6145//3883
+f 6115//364 6145//3883 6160//3904
+f 6131//3892 6236//4007 6146//3893
+f 6115//364 6160//3904 6175//4042
+f 6146//3893 6236//4007 6161//3913
+f 6115//364 6175//4042 6190//4044
+f 6161//3913 6236//4007 6176//3931
+f 6176//3931 6236//4007 6191//3934
+f 6115//364 6190//4044 6205//3959
+f 6115//364 6205//3959 6220//3964
+f 6191//3934 6236//4007 6206//4051
+f 6115//364 6220//3964 6235//3982
+f 6206//4051 6236//4007 6221//3990
+f 6115//364 6235//3982 6251//4001
+f 6221//3990 6236//4007 6237//3994
+f 6115//364 6251//4001 6266//4008
+f 6237//3994 6236//4007 6252//3995
+f 6115//364 6266//4008 5799//3548
+f 6262//3992 6261//4005 5795//4013
+f 6257//4006 6256//4004 5789//3552
+f 6252//3995 6236//4007 5785//3533
+f 6263//4055 6262//3992 5796//3536
+f 6258//3993 6257//4006 5790//3530
+f 6253//4056 6252//3995 5785//3533
+f 6264//3999 6263//4055 5797//3535
+f 6259//3997 6258//3993 5791//3529
+f 6254//4000 6253//4056 5786//3532
+f 6265//4002 6264//3999 5798//3542
+f 6260//4003 6259//3997 5793//3544
+f 6255//4009 6254//4000 5787//3540
+f 6266//4008 6265//4002 5799//3548
+f 6261//4005 6260//4003 5794//3550
+f 6256//4004 6255//4009 5788//4012
+f 5806//4010 5791//3529 5805//3531
+f 5801//4011 5786//3532 5800//3534
+f 5796//3536 5811//3557 5812//3537
+f 5807//3562 5792//3538 5806//4010
+f 5802//3547 5787//3540 5801//4011
+f 5797//3535 5812//3537 5813//3543
+f 5792//3538 5807//3562 5808//3545
+f 5803//3553 5788//4012 5802//3547
+f 5798//3542 5813//3543 5814//3549
+f 5793//3544 5808//3545 5809//3551
+f 5804//3556 5789//3552 5803//3553
+f 5794//3550 5809//3551 5810//3555
+f 5805//3531 5790//3530 5804//3556
+f 5795//4013 5810//3555 5811//3557
+f 5810//3555 5825//3571 5826//3558
+f 5821//3563 5806//4010 5820//3559
+f 5816//3564 5801//4011 5815//3560
+f 5811//3557 5826//3558 5827//3561
+f 5822//4015 5807//3562 5821//3563
+f 5817//3567 5802//3547 5816//3564
+f 5812//3537 5827//3561 5828//3565
+f 5807//3562 5822//4015 5823//3566
+f 5818//3570 5803//3553 5817//3567
+f 5813//3543 5828//3565 5829//4014
+f 5808//3545 5823//3566 5824//3569
+f 5819//3572 5804//3556 5818//3570
+f 5809//3551 5824//3569 5825//3571
+f 5820//3559 5805//3531 5819//3572
+f 5824//3569 5839//3586 5840//3573
+f 5835//3576 5820//3559 5834//3574
+f 5825//3571 5840//3573 5841//3575
+f 5836//4016 5821//3563 5835//3576
+f 5831//3581 5816//3564 5830//3577
+f 5826//3558 5841//3575 5842//3578
+f 5837//3597 5822//4015 5836//4016
+f 5832//3584 5817//3567 5831//3581
+f 5827//3561 5842//3578 5843//3582
+f 5822//4015 5837//3597 5838//3583
+f 5833//3587 5818//3570 5832//3584
+f 5828//3565 5843//3582 5844//3585
+f 5823//3566 5838//3583 5839//3586
+f 5834//3574 5819//3572 5833//3587
+f 5843//3582 5858//3600 5859//3588
+f 5838//3583 5853//3601 5854//3589
+f 5849//3592 5834//3574 5848//3590
+f 5839//3586 5854//3589 5855//3591
+f 5850//3594 5835//3576 5849//3592
+f 5840//3573 5855//3591 5856//3593
+f 5851//3598 5836//4016 5850//3594
+f 5846//3602 5831//3581 5845//3595
+f 5841//3575 5856//3593 5857//3596
+f 5852//3605 5837//3597 5851//3598
+f 5831//3581 5846//3602 5847//3599
+f 5842//3578 5857//3596 5858//3600
+f 5837//3597 5852//3605 5853//3601
+f 5832//3584 5847//3599 5848//3590
+f 5846//3602 5861//4018 5862//3603
+f 5857//3596 5872//3615 5873//3604
+f 5852//3605 5867//4020 5868//4017
+f 5847//3599 5862//3603 5863//3607
+f 5858//3600 5873//3604 5874//3608
+f 5853//3601 5868//4017 5869//3609
+f 5864//3611 5849//3592 5863//3607
+f 5854//3589 5869//3609 5870//3610
+f 5865//3613 5850//3594 5864//3611
+f 5855//3591 5870//3610 5871//3612
+f 5866//3616 5851//3598 5865//3613
+f 5845//3595 5860//3618 5861//4018
+f 5856//3593 5871//3612 5872//3615
+f 5867//4020 5852//3605 5866//3616
+f 5881//3622 5866//3616 5880//3617
+f 5860//3618 5875//3636 5876//4019
+f 5871//3612 5886//3631 5887//3620
+f 5882//3639 5867//4020 5881//3622
+f 5861//4018 5876//4019 5877//3623
+f 5872//3615 5887//3620 5888//4021
+f 5867//4020 5882//3639 5883//3625
+f 5878//4022 5863//3607 5877//3623
+f 5873//3604 5888//4021 5889//3626
+f 5868//4017 5883//3625 5884//3627
+f 5879//3630 5864//3611 5878//4022
+f 5869//3609 5884//3627 5885//3629
+f 5880//3617 5865//3613 5879//3630
+f 5870//3610 5885//3629 5886//3631
+f 5884//3627 5899//3646 5900//3632
+f 5895//3635 5880//3617 5894//3633
+f 5885//3629 5900//3632 5901//4023
+f 5896//3640 5881//3622 5895//3635
+f 5875//3636 5890//3654 5891//4024
+f 5886//3631 5901//4023 5902//3638
+f 5897//3657 5882//3639 5896//3640
+f 5876//4019 5891//4024 5892//3641
+f 5887//3620 5902//3638 5903//3642
+f 5882//3639 5897//3657 5898//3643
+f 5877//3623 5892//3641 5893//3644
+f 5888//4021 5903//3642 5904//3645
+f 5883//3625 5898//3643 5899//3646
+f 5894//3633 5879//3630 5893//3644
+f 5919//3666 5904//3645 5918//3647
+f 5914//3650 5899//3646 5913//3648
+f 5893//3644 5908//3661 5909//3649
+f 5915//3652 5900//3632 5914//3650
+f 5894//3633 5909//3649 5910//3651
+f 5916//3656 5901//4023 5915//3652
+f 5895//3635 5910//3651 5911//3653
+f 5890//3654 5905//4025 5906//3655
+f 5917//3660 5902//3638 5916//3656
+f 5896//3640 5911//3653 5912//3658
+f 5891//4024 5906//3655 5907//3659
+f 5918//3647 5903//3642 5917//3660
+f 5913//3648 5898//3643 5912//3658
+f 5892//3641 5907//3659 5908//3661
+f 5906//3655 5921//3675 5922//3662
+f 5933//3667 5918//3647 5932//3663
+f 5928//3668 5913//3648 5927//3664
+f 5907//3659 5922//3662 5923//3665
+f 5934//4026 5919//3666 5933//3667
+f 5929//3670 5914//3650 5928//3668
+f 5908//3661 5923//3665 5924//3669
+f 5930//3672 5915//3652 5929//3670
+f 5909//3649 5924//3669 5925//3671
+f 5931//3676 5916//3656 5930//3672
+f 5910//3651 5925//3671 5926//3673
+f 5905//4025 5920//3678 5921//3675
+f 5932//3663 5917//3660 5931//3676
+f 5911//3653 5926//3673 5927//3664
+f 5925//3671 5940//3690 5941//3677
+f 5920//3678 5935//3696 5936//3679
+f 5947//3683 5932//3663 5946//3680
+f 5926//3673 5941//3677 5942//3681
+f 5921//3675 5936//3679 5937//3682
+f 5948//3686 5933//3667 5947//3683
+f 5943//3687 5928//3668 5942//3681
+f 5922//3662 5937//3682 5938//3684
+f 5949//3703 5934//4026 5948//3686
+f 5944//3689 5929//3670 5943//3687
+f 5923//3665 5938//3684 5939//3688
+f 5945//3691 5930//3672 5944//3689
+f 5924//3669 5939//3688 5940//3690
+f 5946//3680 5931//3676 5945//3691
+f 5960//3694 5945//3691 5959//3692
+f 5939//3688 5954//3706 5955//3693
+f 5961//3698 5946//3680 5960//3694
+f 5940//3690 5955//3693 5956//3695
+f 5935//3696 5950//3715 5951//3697
+f 5962//4027 5947//3683 5961//3698
+f 5941//3677 5956//3695 5957//3699
+f 5936//3679 5951//3697 5952//3700
+f 5963//3704 5948//3686 5962//4027
+f 5958//3705 5943//3687 5957//3699
+f 5937//3682 5952//3700 5953//3702
+f 5964//3707 5949//3703 5963//3704
+f 5959//3692 5944//3689 5958//3705
+f 5938//3684 5953//3702 5954//3706
+f 5979//3726 5964//3707 5978//3708
+f 5974//3711 5959//3692 5973//3709
+f 5953//3702 5968//3721 5969//3710
+f 5975//3713 5960//3694 5974//3711
+f 5954//3706 5969//3710 5970//3712
+f 5976//3717 5961//3698 5975//3713
+f 5955//3693 5970//3712 5971//3714
+f 5966//3719 5951//3697 5965//4028
+f 5977//3720 5962//4027 5976//3717
+f 5956//3695 5971//3714 5972//3718
+f 5967//3724 5952//3700 5966//3719
+f 5978//3708 5963//3704 5977//3720
+f 5973//3709 5958//3705 5972//3718
+f 5952//3700 5967//3724 5968//3721
+f 5993//3727 5978//3708 5992//3722
+f 5988//3728 5973//3709 5987//3723
+f 5967//3724 5982//3740 5983//4029
+f 5994//3744 5979//3726 5993//3727
+f 5989//3730 5974//3711 5988//3728
+f 5968//3721 5983//4029 5984//3729
+f 5990//3732 5975//3713 5989//3730
+f 5969//3710 5984//3729 5985//3731
+f 5991//4030 5976//3717 5990//3732
+f 5970//3712 5985//3731 5986//3733
+f 5981//3736 5966//3719 5980//3734
+f 5992//3722 5977//3720 5991//4030
+f 5971//3714 5986//3733 5987//3723
+f 5982//3740 5967//3724 5981//3736
+f 5996//4031 5981//3736 5995//3737
+f 6007//4032 5992//3722 6006//3738
+f 5986//3733 6001//3751 6002//3739
+f 5997//3758 5982//3740 5996//4031
+f 6008//3745 5993//3727 6007//4032
+f 6003//3746 5988//3728 6002//3739
+f 5982//3740 5997//3758 5998//3743
+f 6009//3762 5994//3744 6008//3745
+f 6004//3748 5989//3730 6003//3746
+f 5983//4029 5998//3743 5999//4033
+f 6005//3750 5990//3732 6004//3748
+f 5984//3729 5999//4033 6000//3749
+f 6006//3738 5991//4030 6005//3750
+f 5985//3731 6000//3749 6001//3751
+f 5999//4033 6014//3765 6015//3752
+f 6021//3756 6006//3738 6020//3753
+f 6000//3749 6015//3752 6016//3754
+f 5995//3737 6010//3773 6011//3755
+f 6022//3760 6007//4032 6021//3756
+f 6001//3751 6016//3754 6017//3757
+f 5996//4031 6011//3755 6012//3759
+f 6023//3763 6008//3745 6022//3760
+f 6018//3764 6003//3746 6017//3757
+f 5997//3758 6012//3759 6013//3761
+f 6024//3780 6009//3762 6023//3763
+f 6019//3766 6004//3748 6018//3764
+f 5998//3743 6013//3761 6014//3765
+f 6020//3753 6005//3750 6019//3766
+f 6018//3764 6033//3779 6034//3767
+f 6029//3770 6014//3765 6028//3768
+f 6019//3766 6034//3767 6035//3769
+f 6030//3772 6015//3752 6029//3770
+f 6020//3753 6035//3769 6036//3771
+f 6031//3776 6016//3754 6030//3772
+f 6010//3773 6025//3792 6026//3774
+f 6021//3756 6036//3771 6037//3775
+f 6032//3783 6017//3757 6031//3776
+f 6011//3755 6026//3774 6027//3777
+f 6022//3760 6037//3775 6038//3778
+f 6017//3757 6032//3783 6033//3779
+f 6012//3759 6027//3777 6028//3768
+f 6023//3763 6038//3778 6039//3781
+f 6037//3775 6052//4034 6053//3782
+f 6032//3783 6047//3800 6048//3784
+f 6027//3777 6042//3796 6043//3785
+f 6038//3778 6053//3782 6054//3786
+f 6033//3779 6048//3784 6049//3787
+f 6044//3789 6029//3770 6043//3785
+f 6034//3767 6049//3787 6050//3788
+f 6045//3791 6030//3772 6044//3789
+f 6035//3769 6050//3788 6051//3790
+f 6046//3795 6031//3776 6045//3791
+f 6025//3792 6040//3797 6041//3793
+f 6036//3771 6051//3790 6052//4034
+f 6047//3800 6032//3783 6046//3795
+f 6026//3774 6041//3793 6042//3796
+f 6056//3802 6041//3793 6055//3798
+f 6051//3790 6066//3811 6067//3799
+f 6062//3818 6047//3800 6061//3801
+f 6057//3805 6042//3796 6056//3802
+f 6052//4034 6067//3799 6068//3803
+f 6047//3800 6062//3818 6063//3804
+f 6058//3808 6043//3785 6057//3805
+f 6053//3782 6068//3803 6069//3806
+f 6048//3784 6063//3804 6064//3807
+f 6059//3810 6044//3789 6058//3808
+f 6049//3787 6064//3807 6065//3809
+f 6060//3812 6045//3791 6059//3810
+f 6050//3788 6065//3809 6066//3811
+f 6061//3801 6046//3795 6060//3812
+f 6075//3815 6060//3812 6074//3813
+f 6065//3809 6080//3827 6081//3814
+f 6076//4035 6061//3801 6075//3815
+f 6071//3820 6056//3802 6070//3816
+f 6066//3811 6081//3814 6082//3817
+f 6077//3836 6062//3818 6076//4035
+f 6072//3823 6057//3805 6071//3820
+f 6067//3799 6082//3817 6083//3821
+f 6062//3818 6077//3836 6078//3822
+f 6073//3826 6058//3808 6072//3823
+f 6068//3803 6083//3821 6084//3824
+f 6063//3804 6078//3822 6079//3825
+f 6074//3813 6059//3810 6073//3826
+f 6064//3807 6079//3825 6080//3827
+f 6078//3822 6093//3840 6094//3828
+f 6089//3831 6074//3813 6088//3829
+f 6079//3825 6094//3828 6095//3830
+f 6090//3833 6075//3815 6089//3831
+f 6080//3827 6095//3830 6096//3832
+f 6091//3837 6076//4035 6090//3833
+f 6086//3838 6071//3820 6085//3834
+f 6081//3814 6096//3832 6097//4036
+f 6092//3844 6077//3836 6091//3837
+f 6087//3841 6072//3823 6086//3838
+f 6082//3817 6097//4036 6098//4037
+f 6077//3836 6092//3844 6093//3840
+f 6088//3829 6073//3826 6087//3841
+f 6083//3821 6098//4037 6099//3842
+f 6097//4036 6112//3855 6113//3843
+f 6092//3844 6107//3858 6108//3845
+f 6103//3849 6088//3829 6102//3846
+f 6098//4037 6113//3843 6114//3847
+f 6093//3840 6108//3845 6109//3848
+f 6104//3851 6089//3831 6103//3849
+f 6094//3828 6109//3848 6110//3850
+f 6105//3853 6090//3833 6104//3851
+f 6095//3830 6110//3850 6111//3852
+f 6106//4038 6091//3837 6105//3853
+f 6085//3834 6100//3870 6101//3854
+f 6096//3832 6111//3852 6112//3855
+f 6107//3858 6092//3844 6106//4038
+f 6086//3838 6101//3854 6102//3846
+f 6111//3852 6127//3868 6128//3857
+f 6123//3877 6107//3858 6122//3859
+f 6101//3854 6117//3871 6118//3860
+f 6112//3855 6128//3857 6129//3861
+f 6107//3858 6123//3877 6124//3862
+f 6119//3865 6103//3849 6118//3860
+f 6113//3843 6129//3861 6130//4039
+f 6108//3845 6124//3862 6125//3864
+f 6120//3867 6104//3851 6119//3865
+f 6109//3848 6125//3864 6126//3866
+f 6121//3869 6105//3853 6120//3867
+f 6110//3850 6126//3866 6127//3868
+f 6122//3859 6106//4038 6121//3869
+f 6100//3870 6116//4040 6117//3871
+f 6126//3866 6141//3885 6142//3872
+f 6137//3878 6122//3859 6136//3873
+f 6116//4040 6131//3892 6132//3875
+f 6127//3868 6142//3872 6143//3876
+f 6138//3895 6123//3877 6137//3878
+f 6117//3871 6132//3875 6133//3879
+f 6128//3857 6143//3876 6144//3880
+f 6123//3877 6138//3895 6139//3881
+f 6118//3860 6133//3879 6134//3882
+f 6129//3861 6144//3880 6145//3883
+f 6124//3862 6139//3881 6140//3884
+f 6135//3886 6120//3867 6134//3882
+f 6125//3864 6140//3884 6141//3885
+f 6136//3873 6121//3869 6135//3886
+f 6134//3882 6149//3899 6150//3887
+f 6156//3890 6141//3885 6155//3888
+f 6135//3886 6150//3887 6151//3889
+f 6157//3894 6142//3872 6156//3890
+f 6136//3873 6151//3889 6152//3891
+f 6147//4041 6132//3875 6146//3893
+f 6158//3898 6143//3876 6157//3894
+f 6137//3878 6152//3891 6153//3896
+f 6132//3875 6147//4041 6148//3897
+f 6159//3900 6144//3880 6158//3898
+f 6154//3901 6139//3881 6153//3896
+f 6133//3879 6148//3897 6149//3899
+f 6160//3904 6145//3883 6159//3900
+f 6155//3888 6140//3884 6154//3901
+f 6169//3906 6154//3901 6168//3902
+f 6164//3921 6149//3899 6163//3903
+f 6175//4042 6160//3904 6174//3905
+f 6170//3908 6155//3888 6169//3906
+f 6149//3899 6164//3921 6165//3907
+f 6171//3910 6156//3890 6170//3908
+f 6150//3887 6165//3907 6166//3909
+f 6172//3914 6157//3894 6171//3910
+f 6151//3889 6166//3909 6167//3911
+f 6162//3915 6147//4041 6161//3913
+f 6173//3916 6158//3898 6172//3914
+f 6152//3891 6167//3911 6168//3902
+f 6163//3903 6148//3897 6162//3915
+f 6174//3905 6159//3900 6173//3916
+f 6188//3920 6173//3916 6187//3917
+f 6167//3911 6182//3930 6183//3918
+f 6178//3922 6163//3903 6177//3919
+f 6189//3924 6174//3905 6188//3920
+f 6184//3925 6169//3906 6183//3918
+f 6179//3939 6164//3921 6178//3922
+f 6190//4044 6175//4042 6189//3924
+f 6185//3927 6170//3908 6184//3925
+f 6164//3921 6179//3939 6180//3926
+f 6186//3929 6171//3910 6185//3927
+f 6165//3907 6180//3926 6181//3928
+f 6187//3917 6172//3914 6186//3929
+f 6166//3909 6181//3928 6182//3930
+f 6177//3919 6162//3915 6176//3931
+f 6202//3935 6187//3917 6201//3932
+f 6181//3928 6196//3946 6197//3933
+f 6192//3937 6177//3919 6191//3934
+f 6203//4043 6188//3920 6202//3935
+f 6182//3930 6197//3933 6198//3936
+f 6193//4047 6178//3922 6192//3937
+f 6204//3942 6189//3924 6203//4043
+f 6199//3943 6184//3925 6198//3936
+f 6178//3922 6193//4047 6194//3940
+f 6205//3959 6190//4044 6204//3942
+f 6200//3945 6185//3927 6199//3943
+f 6179//3939 6194//3940 6195//3944
+f 6201//3932 6186//3929 6200//3945
+f 6180//3926 6195//3944 6196//3946
+f 6194//3940 6209//4048 6210//3947
+f 6216//4045 6201//3932 6215//3948
+f 6195//3944 6210//3947 6211//3949
+f 6217//3953 6202//3935 6216//4045
+f 6196//3946 6211//3949 6212//3951
+f 6191//3934 6206//4051 6207//4046
+f 6218//3957 6203//4043 6217//3953
+f 6197//3933 6212//3951 6213//3954
+f 6192//3937 6207//4046 6208//3956
+f 6219//4049 6204//3942 6218//3957
+f 6214//3961 6199//3943 6213//3954
+f 6193//4047 6208//3956 6209//4048
+f 6220//3964 6205//3959 6219//4049
+f 6215//3948 6200//3945 6214//3961
+f 6229//3966 6214//3961 6228//3962
+f 6208//3956 6223//3975 6224//4050
+f 6235//3982 6220//3964 6234//3965
+f 6230//3968 6215//3948 6229//3966
+f 6209//4048 6224//4050 6225//3967
+f 6231//3970 6216//4045 6230//3968
+f 6210//3947 6225//3967 6226//3969
+f 6232//4053 6217//3953 6231//3970
+f 6211//3949 6226//3969 6227//3971
+f 6206//4051 6221//3990 6222//4052
+f 6233//4054 6218//3957 6232//4053
+f 6212//3951 6227//3971 6228//3962
+f 6207//4046 6222//4052 6223//3975
+f 6234//3965 6219//4049 6233//4054
+f 6249//3980 6233//4054 6248//3977
+f 6227//3971 6243//3989 6244//3978
+f 6222//4052 6238//3991 6239//3979
+f 6250//3983 6234//3965 6249//3980
+f 6245//3984 6229//3966 6244//3978
+f 6223//3975 6239//3979 6240//3981
+f 6251//4001 6235//3982 6250//3983
+f 6246//3986 6230//3968 6245//3984
+f 6224//4050 6240//3981 6241//3985
+f 6247//3988 6231//3970 6246//3986
+f 6225//3967 6241//3985 6242//3987
+f 6248//3977 6232//4053 6247//3988
+f 6226//3969 6242//3987 6243//3989
+f 6221//3990 6237//3994 6238//3991
+f 6263//4055 6248//3977 6262//3992
+f 6242//3987 6257//4006 6258//3993
+f 6253//4056 6238//3991 6252//3995
+f 6264//3999 6249//3980 6263//4055
+f 6243//3989 6258//3993 6259//3997
+f 6254//4000 6239//3979 6253//4056
+f 6265//4002 6250//3983 6264//3999
+f 6260//4003 6245//3984 6259//3997
+f 6255//4009 6240//3981 6254//4000
+f 6266//4008 6251//4001 6265//4002
+f 6261//4005 6246//3986 6260//4003
+f 6240//3981 6255//4009 6256//4004
+f 6262//3992 6247//3988 6261//4005
+f 6241//3985 6256//4004 6257//4006
+f 6261//4005 5794//3550 5795//4013
+f 5790//3530 6257//4006 5789//3552
+f 6262//3992 5795//4013 5796//3536
+f 5791//3529 6258//3993 5790//3530
+f 5786//3532 6253//4056 5785//3533
+f 6263//4055 5796//3536 5797//3535
+f 5792//3538 6259//3997 5791//3529
+f 5787//3540 6254//4000 5786//3532
+f 6264//3999 5797//3535 5798//3542
+f 6259//3997 5792//3538 5793//3544
+f 5788//4012 6255//4009 5787//3540
+f 6265//4002 5798//3542 5799//3548
+f 6260//4003 5793//3544 5794//3550
+f 5789//3552 6256//4004 5788//4012
+o Nose_Sphere
+v -0.159802 1.092958 -0.013143
+v -0.180371 1.079367 -0.014504
+v -0.198152 1.059956 -0.015819
+v -0.212461 1.035470 -0.017036
+v -0.224784 1.022868 -0.011991
+v -0.235916 0.992648 -0.011991
+v -0.242772 0.959858 -0.011991
+v -0.245086 0.925758 -0.011991
+v -0.242772 0.891657 -0.011991
+v -0.235916 0.858867 -0.011991
+v -0.224784 0.828648 -0.011991
+v -0.209802 0.802160 -0.011991
+v -0.191547 0.780422 -0.011991
+v -0.170720 0.764269 -0.011991
+v -0.148121 0.754323 -0.011991
+v -0.158929 1.093175 -0.020995
+v -0.178659 1.079792 -0.029908
+v -0.195666 1.060573 -0.038182
+v -0.209297 1.036256 -0.045498
+v -0.222859 1.022868 -0.045623
+v -0.233778 0.992648 -0.049360
+v -0.240501 0.959858 -0.051662
+v -0.242772 0.925758 -0.052439
+v -0.240501 0.891657 -0.051662
+v -0.233778 0.858867 -0.049360
+v -0.222859 0.828648 -0.045623
+v -0.208166 0.802160 -0.040592
+v -0.190261 0.780422 -0.034463
+v -0.169834 0.764269 -0.027470
+v -0.147670 0.754323 -0.019882
+v -0.157201 1.093534 -0.028495
+v -0.175268 1.080498 -0.044620
+v -0.190744 1.061598 -0.059539
+v -0.203033 1.037560 -0.072681
+v -0.217159 1.022868 -0.077962
+v -0.227444 0.992648 -0.085294
+v -0.233778 0.959858 -0.089809
+v -0.235916 0.925758 -0.091334
+v -0.233778 0.891657 -0.089809
+v -0.227444 0.858867 -0.085294
+v -0.217159 0.828648 -0.077962
+v -0.203318 0.802160 -0.068095
+v -0.186453 0.780422 -0.056071
+v -0.167211 0.764269 -0.042354
+v -0.146332 0.754323 -0.027470
+v -0.154683 1.094023 -0.035354
+v -0.170331 1.081457 -0.058074
+v -0.183576 1.062990 -0.079072
+v -0.193910 1.039332 -0.097541
+v -0.207903 1.022868 -0.107766
+v -0.217159 0.992648 -0.118410
+v -0.222859 0.959858 -0.124965
+v -0.224784 0.925758 -0.127179
+v -0.222859 0.891657 -0.124965
+v -0.217159 0.858867 -0.118410
+v -0.207903 0.828648 -0.107766
+v -0.195446 0.802160 -0.093441
+v -0.180268 0.780422 -0.075986
+v -0.162951 0.764269 -0.056071
+v -0.144160 0.754323 -0.034463
+v -0.151474 1.094623 -0.041308
+v -0.164035 1.082633 -0.069753
+v -0.174436 1.064697 -0.096028
+v -0.182277 1.041504 -0.119122
+v -0.195446 1.022868 -0.133889
+v -0.203318 0.992648 -0.147437
+v -0.208166 0.959858 -0.155780
+v -0.209802 0.925758 -0.158597
+v -0.208166 0.891657 -0.155780
+v -0.203318 0.858867 -0.147437
+v -0.195446 0.828648 -0.133889
+v -0.184853 0.802160 -0.115657
+v -0.171944 0.780422 -0.093441
+v -0.157217 0.764269 -0.068095
+v -0.141238 0.754323 -0.040592
+v -0.147696 1.095309 -0.046129
+v -0.156623 1.083979 -0.079210
+v -0.163676 1.066652 -0.109756
+v -0.168582 1.043993 -0.136595
+v -0.180268 1.022868 -0.155328
+v -0.186453 0.992648 -0.171259
+v -0.190261 0.959858 -0.181069
+v -0.191547 0.925758 -0.184381
+v -0.190261 0.891657 -0.181069
+v -0.186453 0.858867 -0.171259
+v -0.180268 0.828648 -0.155328
+v -0.171944 0.802160 -0.133889
+v -0.161802 0.780422 -0.107766
+v -0.150231 0.764269 -0.077962
+v -0.137676 0.754323 -0.045623
+v -0.143493 1.096057 -0.049631
+v -0.148381 1.085446 -0.086079
+v -0.151709 1.068781 -0.119729
+v -0.153352 1.046703 -0.149288
+v -0.162951 1.022868 -0.171259
+v -0.167211 0.992648 -0.188960
+v -0.169834 0.959858 -0.199860
+v -0.170720 0.925758 -0.203541
+v -0.169834 0.891657 -0.199860
+v -0.167211 0.858867 -0.188960
+v -0.162951 0.828648 -0.171259
+v -0.157217 0.802160 -0.147437
+v -0.150231 0.780422 -0.118410
+v -0.142261 0.764269 -0.085294
+v -0.133613 0.754323 -0.049360
+v -0.139029 1.096837 -0.051680
+v -0.139624 1.086976 -0.090098
+v -0.138996 1.071002 -0.125564
+v -0.137171 1.049529 -0.156714
+v -0.144160 1.022868 -0.181069
+v -0.146332 0.992648 -0.199860
+v -0.147670 0.959858 -0.211432
+v -0.148121 0.925758 -0.215339
+v -0.147670 0.891657 -0.211432
+v -0.146332 0.858867 -0.199860
+v -0.144160 0.828648 -0.181069
+v -0.141238 0.802160 -0.155780
+v -0.137676 0.780422 -0.124965
+v -0.133613 0.764269 -0.089809
+v -0.129204 0.754323 -0.051662
+v -0.134474 1.097619 -0.052197
+v -0.130689 1.088510 -0.091112
+v -0.126025 1.073229 -0.127035
+v -0.120661 1.052364 -0.158587
+v -0.124619 1.022868 -0.184381
+v -0.124619 0.992648 -0.203541
+v -0.124619 0.959858 -0.215339
+v -0.124619 0.925758 -0.219323
+v -0.124619 0.891657 -0.215339
+v -0.124619 0.858867 -0.203541
+v -0.124619 0.828648 -0.184381
+v -0.124619 0.802160 -0.158597
+v -0.124619 0.780422 -0.127178
+v -0.124619 0.764269 -0.091334
+v -0.124619 0.754323 -0.052439
+v -0.130004 1.098373 -0.051162
+v -0.121920 1.089989 -0.089081
+v -0.113294 1.075377 -0.124088
+v -0.104457 1.055098 -0.154836
+v -0.105078 1.022868 -0.181069
+v -0.102906 0.992648 -0.199860
+v -0.101569 0.959858 -0.211432
+v -0.101117 0.925758 -0.215339
+v -0.101569 0.891657 -0.211432
+v -0.102906 0.858867 -0.199860
+v -0.105078 0.828648 -0.181069
+v -0.108001 0.802160 -0.155780
+v -0.111562 0.780422 -0.124965
+v -0.115625 0.764269 -0.089809
+v -0.120034 0.754323 -0.051662
+v -0.125789 1.099071 -0.048614
+v -0.113653 1.091357 -0.084085
+v -0.101292 1.077363 -0.116834
+v -0.089182 1.057626 -0.145603
+v -0.086288 1.022868 -0.171259
+v -0.082027 0.992648 -0.188960
+v -0.079404 0.959858 -0.199860
+v -0.078518 0.925758 -0.203541
+v -0.079404 0.891657 -0.199860
+v -0.082027 0.858867 -0.188960
+v -0.086288 0.828648 -0.171259
+v -0.092021 0.802160 -0.147437
+v -0.099007 0.780422 -0.118410
+v -0.106977 0.764269 -0.085294
+v -0.115625 0.754323 -0.049360
+v -0.121993 1.099684 -0.044653
+v -0.106206 1.092562 -0.076314
+v -0.090481 1.079112 -0.105553
+v -0.075423 1.059851 -0.131245
+v -0.068970 1.022868 -0.155328
+v -0.062786 0.992648 -0.171259
+v -0.058977 0.959858 -0.181069
+v -0.057691 0.925758 -0.184381
+v -0.058977 0.891657 -0.181069
+v -0.062786 0.858867 -0.171259
+v -0.068970 0.828648 -0.155328
+v -0.077294 0.802160 -0.133889
+v -0.087436 0.780422 -0.107766
+v -0.099007 0.764269 -0.077962
+v -0.111562 0.754323 -0.045623
+v -0.118761 1.100191 -0.039430
+v -0.099866 1.093556 -0.066068
+v -0.081277 1.080555 -0.090678
+v -0.063708 1.061688 -0.112313
+v -0.053792 1.022868 -0.133889
+v -0.045920 0.992648 -0.147437
+v -0.041073 0.959858 -0.155780
+v -0.039436 0.925758 -0.158597
+v -0.041073 0.891657 -0.155780
+v -0.045920 0.858867 -0.147437
+v -0.053792 0.828648 -0.133889
+v -0.064385 0.802160 -0.115657
+v -0.077294 0.780422 -0.093441
+v -0.092021 0.764269 -0.068095
+v -0.108001 0.754323 -0.040592
+v -0.116217 1.100571 -0.033145
+v -0.094876 1.094301 -0.053741
+v -0.074032 1.081637 -0.072781
+v -0.054487 1.063065 -0.089535
+v -0.041335 1.022868 -0.107766
+v -0.032079 0.992648 -0.118410
+v -0.026379 0.959858 -0.124965
+v -0.024454 0.925758 -0.127178
+v -0.026379 0.891657 -0.124965
+v -0.032079 0.858867 -0.118410
+v -0.041335 0.828648 -0.107766
+v -0.053792 0.802160 -0.093441
+v -0.068970 0.780422 -0.075986
+v -0.086288 0.764269 -0.056071
+v -0.105078 0.754323 -0.034463
+v -0.114459 1.100810 -0.026041
+v -0.091427 1.094770 -0.039805
+v -0.069026 1.082317 -0.052550
+v -0.048115 1.063931 -0.063785
+v -0.032079 1.022868 -0.077962
+v -0.021794 0.992648 -0.085294
+v -0.015460 0.959858 -0.089809
+v -0.013322 0.925758 -0.091333
+v -0.015460 0.891657 -0.089809
+v -0.021794 0.858867 -0.085294
+v -0.032079 0.828648 -0.077962
+v -0.045920 0.802160 -0.068095
+v -0.062786 0.780422 -0.056071
+v -0.082027 0.764269 -0.042354
+v -0.102906 0.754323 -0.027470
+v -0.113554 1.100899 -0.018390
+v -0.089653 1.094943 -0.024797
+v -0.066450 1.082569 -0.030761
+v -0.044837 1.064251 -0.036054
+v -0.026379 1.022868 -0.045623
+v -0.015460 0.992648 -0.049360
+v -0.008737 0.959858 -0.051662
+v -0.006467 0.925758 -0.052439
+v -0.008737 0.891657 -0.051662
+v -0.015460 0.858867 -0.049360
+v -0.026379 0.828648 -0.045623
+v -0.041073 0.802160 -0.040592
+v -0.058977 0.780422 -0.034463
+v -0.079404 0.764269 -0.027470
+v -0.101569 0.754323 -0.019882
+v -0.113538 1.100833 -0.010486
+v -0.089622 1.094815 -0.009293
+v -0.066405 1.082383 -0.008253
+v -0.044779 1.064014 -0.007406
+v -0.024454 1.022868 -0.011991
+v -0.013322 0.992648 -0.011991
+v -0.006467 0.959858 -0.011991
+v -0.004152 0.925758 -0.011991
+v -0.006467 0.891657 -0.011991
+v -0.013322 0.858867 -0.011991
+v -0.024454 0.828648 -0.011991
+v -0.039436 0.802160 -0.011991
+v -0.057691 0.780422 -0.011991
+v -0.078518 0.764269 -0.011991
+v -0.101117 0.754323 -0.011991
+v -0.114411 1.100616 -0.002633
+v -0.091334 1.094390 0.006110
+v -0.068890 1.081765 0.014109
+v -0.047943 1.063228 0.021056
+v -0.026379 1.022868 0.021641
+v -0.015460 0.992648 0.025379
+v -0.008737 0.959858 0.027680
+v -0.006467 0.925758 0.028458
+v -0.008737 0.891657 0.027680
+v -0.015460 0.858867 0.025379
+v -0.026379 0.828648 0.021641
+v -0.041073 0.802160 0.016610
+v -0.058977 0.780422 0.010481
+v -0.079404 0.764269 0.003488
+v -0.101569 0.754323 -0.004100
+v -0.116139 1.100257 0.004867
+v -0.094724 1.093684 0.020822
+v -0.073812 1.080741 0.035467
+v -0.054207 1.061924 0.048239
+v -0.032079 1.022868 0.053980
+v -0.021794 0.992648 0.061312
+v -0.015460 0.959858 0.065827
+v -0.013322 0.925758 0.067352
+v -0.015460 0.891657 0.065827
+v -0.021794 0.858867 0.061312
+v -0.032079 0.828648 0.053980
+v -0.045920 0.802160 0.044113
+v -0.062786 0.780422 0.032089
+v -0.082027 0.764269 0.018372
+v -0.102906 0.754323 0.003488
+v -0.118657 1.099768 0.011726
+v -0.099662 1.092725 0.034276
+v -0.080980 1.079349 0.054999
+v -0.063330 1.060152 0.073099
+v -0.041335 1.022868 0.083784
+v -0.032079 0.992648 0.094428
+v -0.026379 0.959858 0.100983
+v -0.024454 0.925758 0.103197
+v -0.026379 0.891657 0.100983
+v -0.032079 0.858867 0.094428
+v -0.041335 0.828648 0.083784
+v -0.053792 0.802160 0.069459
+v -0.068970 0.780422 0.052004
+v -0.086288 0.764269 0.032089
+v -0.105078 0.754323 0.010481
+v -0.121866 1.099168 0.017680
+v -0.105957 1.091549 0.045956
+v -0.090120 1.077642 0.071955
+v -0.074963 1.057980 0.094680
+v -0.053792 1.022868 0.109907
+v -0.045920 0.992648 0.123455
+v -0.041073 0.959858 0.131798
+v -0.039436 0.925758 0.134615
+v -0.041073 0.891657 0.131798
+v -0.045920 0.858867 0.123455
+v -0.053792 0.828648 0.109907
+v -0.064385 0.802160 0.091675
+v -0.077294 0.780422 0.069459
+v -0.092021 0.764269 0.044113
+v -0.108001 0.754323 0.016610
+v -0.125645 1.098482 0.022501
+v -0.113369 1.090202 0.055412
+v -0.100880 1.075686 0.085684
+v -0.088658 1.055492 0.112153
+v -0.068970 1.022868 0.131346
+v -0.062786 0.992648 0.147277
+v -0.058977 0.959858 0.157087
+v -0.057691 0.925758 0.160399
+v -0.058977 0.891657 0.157087
+v -0.062786 0.858867 0.147277
+v -0.068970 0.828648 0.131346
+v -0.077294 0.802160 0.109907
+v -0.087436 0.780422 0.083784
+v -0.099007 0.764269 0.053980
+v -0.111562 0.754323 0.021641
+v -0.124619 0.750964 -0.011991
+v -0.129847 1.097734 0.026003
+v -0.121612 1.088736 0.062281
+v -0.112847 1.073557 0.095657
+v -0.103888 1.052782 0.124846
+v -0.086288 1.022868 0.147277
+v -0.082028 0.992648 0.164978
+v -0.079404 0.959858 0.175878
+v -0.078518 0.925758 0.179559
+v -0.079404 0.891657 0.175878
+v -0.082027 0.858867 0.164978
+v -0.086288 0.828648 0.147277
+v -0.092021 0.802160 0.123455
+v -0.099007 0.780422 0.094428
+v -0.106977 0.764269 0.061312
+v -0.115625 0.754323 0.025379
+v -0.134311 1.096954 0.028051
+v -0.130369 1.087206 0.066300
+v -0.125560 1.071337 0.101491
+v -0.120069 1.049955 0.132272
+v -0.105078 1.022868 0.157087
+v -0.102906 0.992648 0.175878
+v -0.101569 0.959858 0.187450
+v -0.101117 0.925758 0.191357
+v -0.101569 0.891657 0.187450
+v -0.102906 0.858867 0.175878
+v -0.105078 0.828648 0.157087
+v -0.108001 0.802160 0.131798
+v -0.111562 0.780422 0.100983
+v -0.115625 0.764269 0.065827
+v -0.120034 0.754323 0.027680
+v -0.138866 1.096172 0.028568
+v -0.139303 1.085672 0.067314
+v -0.138531 1.069110 0.102963
+v -0.136579 1.047121 0.134145
+v -0.124619 1.022868 0.160399
+v -0.124619 0.992648 0.179559
+v -0.124619 0.959858 0.191357
+v -0.124619 0.925758 0.195341
+v -0.124619 0.891657 0.191357
+v -0.124619 0.858867 0.179559
+v -0.124619 0.828648 0.160399
+v -0.124619 0.802160 0.134615
+v -0.124619 0.780422 0.103197
+v -0.124619 0.764269 0.067352
+v -0.124619 0.754323 0.028458
+v -0.143336 1.095418 0.027533
+v -0.148073 1.084193 0.065284
+v -0.151262 1.066962 0.100015
+v -0.152783 1.044387 0.130393
+v -0.144160 1.022868 0.157087
+v -0.146332 0.992648 0.175878
+v -0.147670 0.959858 0.187450
+v -0.148121 0.925758 0.191357
+v -0.147670 0.891657 0.187450
+v -0.146332 0.858867 0.175878
+v -0.144160 0.828648 0.157087
+v -0.141238 0.802160 0.131798
+v -0.137676 0.780422 0.100983
+v -0.133613 0.764269 0.065827
+v -0.129204 0.754323 0.027680
+v -0.147551 1.094720 0.024986
+v -0.156340 1.082824 0.060287
+v -0.163264 1.064975 0.092762
+v -0.168058 1.041859 0.121161
+v -0.162951 1.022868 0.147277
+v -0.167211 0.992648 0.164978
+v -0.169834 0.959858 0.175878
+v -0.170720 0.925758 0.179559
+v -0.169834 0.891657 0.175878
+v -0.167211 0.858867 0.164978
+v -0.162951 0.828648 0.147277
+v -0.157217 0.802160 0.123455
+v -0.150231 0.780422 0.094428
+v -0.142261 0.764269 0.061312
+v -0.133613 0.754323 0.025379
+v -0.151347 1.094107 0.021025
+v -0.163786 1.081620 0.052517
+v -0.174075 1.063227 0.081481
+v -0.181817 1.039634 0.106803
+v -0.180268 1.022868 0.131346
+v -0.186453 0.992648 0.147277
+v -0.190261 0.959858 0.157087
+v -0.191547 0.925758 0.160399
+v -0.190261 0.891657 0.157087
+v -0.186453 0.858867 0.147277
+v -0.180268 0.828648 0.131346
+v -0.171944 0.802160 0.109907
+v -0.161802 0.780422 0.083784
+v -0.150231 0.764269 0.053980
+v -0.137676 0.754323 0.021641
+v -0.154579 1.093600 0.015801
+v -0.170126 1.080626 0.042271
+v -0.183279 1.061784 0.066606
+v -0.193532 1.037797 0.087871
+v -0.195446 1.022868 0.109907
+v -0.203318 0.992648 0.123455
+v -0.208166 0.959858 0.131798
+v -0.209802 0.925758 0.134615
+v -0.208166 0.891657 0.131798
+v -0.203318 0.858867 0.123455
+v -0.195446 0.828648 0.109907
+v -0.184853 0.802160 0.091675
+v -0.171944 0.780422 0.069459
+v -0.157217 0.764269 0.044113
+v -0.141238 0.754323 0.016610
+v -0.157123 1.093220 0.009517
+v -0.175117 1.079881 0.029943
+v -0.190524 1.060701 0.048709
+v -0.202753 1.036419 0.065092
+v -0.207903 1.022868 0.083784
+v -0.217159 0.992648 0.094428
+v -0.222859 0.959858 0.100983
+v -0.224784 0.925758 0.103196
+v -0.222859 0.891657 0.100983
+v -0.217159 0.858867 0.094428
+v -0.207903 0.828648 0.083784
+v -0.195446 0.802160 0.069459
+v -0.180268 0.780422 0.052004
+v -0.162951 0.764269 0.032089
+v -0.144160 0.754323 0.010481
+v -0.137235 1.100206 -0.011786
+v -0.158881 1.092981 0.002412
+v -0.178565 1.079412 0.016007
+v -0.195530 1.060021 0.028477
+v -0.209125 1.035554 0.039343
+v -0.217159 1.022868 0.053980
+v -0.227444 0.992648 0.061312
+v -0.233778 0.959858 0.065827
+v -0.235916 0.925758 0.067351
+v -0.233778 0.891657 0.065827
+v -0.227444 0.858867 0.061312
+v -0.217159 0.828648 0.053980
+v -0.203318 0.802160 0.044113
+v -0.186453 0.780422 0.032089
+v -0.167211 0.764269 0.018372
+v -0.146332 0.754323 0.003488
+v -0.159786 1.092892 -0.005239
+v -0.180339 1.079239 0.000999
+v -0.198106 1.059770 0.006689
+v -0.212403 1.035233 0.011611
+v -0.222859 1.022868 0.021641
+v -0.233778 0.992648 0.025378
+v -0.240501 0.959858 0.027680
+v -0.242772 0.925758 0.028457
+v -0.240501 0.891657 0.027680
+v -0.233778 0.858867 0.025379
+v -0.222859 0.828648 0.021641
+v -0.208166 0.802160 0.016610
+v -0.190261 0.780422 0.010481
+v -0.169834 0.764269 0.003488
+v -0.147670 0.754323 -0.004100
+vn -0.514939 -0.857204 0.000000
+vn -0.695212 -0.718772 0.000000
+vn -0.686117 -0.723106 -0.079501
+vn -0.990661 -0.136143 0.000000
+vn -0.993225 0.000000 -0.116092
+vn -0.797174 0.602863 -0.031526
+vn -0.805200 0.592029 -0.033174
+vn -0.779168 0.617084 -0.109775
+vn -0.279244 -0.960204 0.000000
+vn -0.507035 -0.859920 -0.058229
+vn -0.961364 -0.275185 0.000000
+vn -0.983734 -0.137883 -0.114963
+vn -0.846065 0.533036 0.001099
+vn -0.907865 -0.419233 0.000000
+vn -0.953948 -0.278481 -0.111423
+vn -0.961364 0.275185 0.000000
+vn -0.953948 0.278481 -0.111423
+vn -0.822626 -0.568529 0.000000
+vn -0.899686 -0.423688 -0.104953
+vn -0.990661 0.136143 0.000000
+vn -0.983734 0.137883 -0.114963
+vn -0.813746 -0.573443 -0.094699
+vn -0.651082 0.758660 -0.021790
+vn -0.792688 0.599231 -0.112003
+vn -0.658254 -0.735832 -0.158757
+vn -0.971587 0.000000 -0.236671
+vn -0.752586 0.629994 -0.191534
+vn -0.274667 -0.961028 -0.030824
+vn -0.483169 -0.867855 -0.115482
+vn -0.961577 -0.143223 -0.234169
+vn -0.836879 0.538957 -0.095462
+vn -0.930296 -0.288522 -0.226386
+vn -0.930296 0.288522 -0.226386
+vn -0.873928 -0.437117 -0.212348
+vn -0.961577 0.143223 -0.234169
+vn -0.786065 -0.588031 -0.190497
+vn -0.640584 0.763726 -0.079470
+vn -0.763115 0.617847 -0.189459
+vn -0.736595 -0.611957 -0.287912
+vn -0.930540 0.000000 -0.366100
+vn -0.615345 0.776543 -0.135228
+vn -0.714682 0.647328 -0.264809
+vn -0.609943 -0.756096 -0.237159
+vn -0.714133 0.643666 -0.275063
+vn -0.260842 -0.963439 -0.061007
+vn -0.442885 -0.880154 -0.170660
+vn -0.919706 -0.152440 -0.361736
+vn -0.814631 0.545915 -0.195654
+vn -0.775445 0.555406 -0.300272
+vn -0.886135 -0.305734 -0.348186
+vn -0.886135 0.305734 -0.348186
+vn -0.826746 -0.459700 -0.324198
+vn -0.919706 0.152440 -0.361736
+vn -0.813318 0.330302 -0.478927
+vn -0.751091 -0.491134 -0.441115
+vn -0.849422 0.165838 -0.500931
+vn -0.660237 -0.644124 -0.386212
+vn -0.861263 0.000000 -0.508133
+vn -0.574755 0.796442 -0.187933
+vn -0.644642 0.686453 -0.336406
+vn -0.538469 -0.782250 -0.313150
+vn -0.657186 0.660909 -0.362316
+vn -0.237770 -0.967132 -0.089785
+vn -0.385571 -0.895505 -0.222205
+vn -0.849422 -0.165838 -0.500931
+vn -0.712607 0.567461 -0.412488
+vn -0.813318 -0.330302 -0.478927
+vn -0.736229 -0.183203 -0.651448
+vn -0.614612 0.582446 -0.531907
+vn -0.698904 -0.361461 -0.617084
+vn -0.698904 0.361461 -0.617084
+vn -0.636860 -0.529527 -0.560289
+vn -0.736198 0.183203 -0.651448
+vn -0.550523 -0.681631 -0.481918
+vn -0.748650 0.000000 -0.662923
+vn -0.518143 0.822077 -0.236000
+vn -0.549821 0.732719 -0.400983
+vn -0.441054 -0.811365 -0.383557
+vn -0.572985 0.682669 -0.453413
+vn -0.205603 -0.971679 -0.116184
+vn -0.310953 -0.911832 -0.267953
+vn -0.316080 -0.838862 -0.443129
+vn -0.572100 0.000000 -0.820154
+vn -0.451399 0.706778 -0.544633
+vn -0.164708 -0.976440 -0.139256
+vn -0.219672 -0.926633 -0.305032
+vn -0.560656 -0.202704 -0.802850
+vn -0.467483 0.598224 -0.650777
+vn -0.526963 -0.395459 -0.752251
+vn -0.526963 0.395459 -0.752251
+vn -0.473006 -0.569720 -0.672018
+vn -0.560656 0.202704 -0.802820
+vn -0.401654 -0.718986 -0.567186
+vn -0.444960 0.851497 -0.277322
+vn -0.428205 0.781823 -0.453139
+vn -0.213813 -0.747581 -0.628773
+vn -0.316630 0.000000 -0.948515
+vn -0.355571 0.882046 -0.309061
+vn -0.281625 0.827570 -0.485580
+vn -0.165960 -0.859004 -0.484298
+vn -0.288858 0.732231 -0.616718
+vn -0.115726 -0.980651 -0.157720
+vn -0.114139 -0.937071 -0.329844
+vn -0.309336 -0.219367 -0.925291
+vn -0.266823 0.602985 -0.751793
+vn -0.288247 -0.423780 -0.858638
+vn -0.288247 0.423780 -0.858638
+vn -0.255470 -0.601917 -0.756554
+vn -0.309336 0.219367 -0.925291
+vn 0.000000 -0.614490 -0.788903
+vn 0.000000 0.226112 -0.974090
+vn 0.000000 -0.758446 -0.651692
+vn -0.252144 0.910459 -0.327799
+vn -0.118686 0.863002 -0.491012
+vn 0.000000 -0.866451 -0.499191
+vn -0.069491 0.744591 -0.663869
+vn -0.059969 -0.983581 -0.170080
+vn 0.000000 -0.940886 -0.338694
+vn 0.000000 -0.226112 -0.974090
+vn 0.000000 -0.435102 -0.900357
+vn 0.000000 0.435102 -0.900357
+vn -0.006378 0.592059 -0.805841
+vn 0.165624 0.732536 -0.660237
+vn 0.255470 -0.601917 -0.756554
+vn 0.260140 0.562822 -0.784539
+vn 0.213813 -0.747581 -0.628773
+vn 0.288247 0.423780 -0.858638
+vn 0.165960 -0.859004 -0.484268
+vn 0.309336 0.219367 -0.925291
+vn -0.139927 0.933470 -0.330149
+vn -0.027406 0.948698 -0.314890
+vn 0.114139 -0.937071 -0.329844
+vn 0.309336 -0.219367 -0.925291
+vn 0.045106 0.883175 -0.466811
+vn 0.000000 -0.984649 -0.174505
+vn 0.059969 -0.983581 -0.170080
+vn 0.288247 -0.423780 -0.858638
+vn 0.316630 0.000000 -0.948515
+vn 0.560656 -0.202704 -0.802820
+vn 0.194006 0.887753 -0.417402
+vn 0.115726 -0.980651 -0.157720
+vn 0.526963 -0.395489 -0.752251
+vn 0.381359 0.704642 -0.598346
+vn 0.473006 -0.569720 -0.672018
+vn 0.490677 0.517380 -0.701071
+vn 0.401654 -0.718986 -0.567186
+vn 0.526963 0.395459 -0.752251
+vn 0.316080 -0.838862 -0.443129
+vn 0.560656 0.202704 -0.802820
+vn 0.076815 0.955657 -0.284249
+vn 0.219672 -0.926633 -0.305032
+vn 0.441054 -0.811365 -0.383557
+vn 0.572100 0.000000 -0.820154
+vn 0.736229 0.183203 -0.651448
+vn 0.167150 0.955687 -0.242195
+vn 0.310953 -0.911832 -0.267953
+vn 0.736229 -0.183203 -0.651448
+vn 0.318369 0.880520 -0.351115
+vn 0.164708 -0.976440 -0.139225
+vn 0.698904 -0.361461 -0.617084
+vn 0.548967 0.670980 -0.498367
+vn 0.636860 -0.529527 -0.560289
+vn 0.662526 0.470107 -0.583117
+vn 0.550523 -0.681631 -0.481918
+vn 0.698904 0.361461 -0.617084
+vn 0.660237 -0.644124 -0.386212
+vn 0.813318 0.330302 -0.478927
+vn 0.538469 -0.782250 -0.313150
+vn 0.748650 0.000000 -0.662923
+vn 0.849422 0.165838 -0.500931
+vn 0.240852 0.951262 -0.192419
+vn 0.385571 -0.895505 -0.222205
+vn 0.849422 -0.165838 -0.500931
+vn 0.415357 0.866909 -0.275552
+vn 0.205603 -0.971679 -0.116184
+vn 0.813318 -0.330302 -0.478927
+vn 0.665120 0.640492 -0.383831
+vn 0.751091 -0.491134 -0.441115
+vn 0.778466 0.431745 -0.455550
+vn 0.739006 0.617817 -0.268532
+vn 0.826746 -0.459700 -0.324198
+vn 0.851558 0.406201 -0.331370
+vn 0.736595 -0.611957 -0.287912
+vn 0.886135 0.305734 -0.348186
+vn 0.609943 -0.756096 -0.237159
+vn 0.861263 0.000000 -0.508133
+vn 0.919706 0.152440 -0.361736
+vn 0.297037 0.944823 -0.137852
+vn 0.442885 -0.880154 -0.170660
+vn 0.919706 -0.152440 -0.361736
+vn 0.485946 0.851711 -0.195868
+vn 0.237770 -0.967132 -0.089785
+vn 0.886135 -0.305734 -0.348186
+vn 0.930540 0.000000 -0.366100
+vn 0.961577 -0.143223 -0.234169
+vn 0.532701 0.838435 -0.115024
+vn 0.260842 -0.963439 -0.061007
+vn 0.930296 -0.288522 -0.226386
+vn 0.780816 0.604541 -0.157598
+vn 0.873928 -0.437117 -0.212348
+vn 0.894131 0.393170 -0.214240
+vn 0.786065 -0.588031 -0.190497
+vn 0.930296 0.288522 -0.226386
+vn 0.658254 -0.735832 -0.158757
+vn 0.961577 0.143223 -0.234169
+vn 0.335795 0.938475 -0.080599
+vn 0.483169 -0.867855 -0.115482
+vn 0.686117 -0.723106 -0.079501
+vn 0.971587 0.000000 -0.236671
+vn 0.983734 0.137883 -0.114963
+vn 0.357494 0.933622 -0.022156
+vn 0.507035 -0.859920 -0.058229
+vn 0.983734 -0.137883 -0.114963
+vn 0.557939 0.829157 -0.034425
+vn 0.274667 -0.961028 -0.030824
+vn 0.953948 -0.278481 -0.111423
+vn 0.797754 0.600757 -0.051546
+vn 0.899686 -0.423688 -0.104953
+vn 0.914457 0.391186 -0.103427
+vn 0.813746 -0.573443 -0.094699
+vn 0.953948 0.278481 -0.111423
+vn 0.822626 -0.568529 0.000000
+vn 0.961364 0.275185 0.000000
+vn 0.695212 -0.718772 0.000000
+vn 0.993225 0.000000 -0.116092
+vn 0.990661 0.136143 0.000000
+vn 0.362560 0.931211 0.036378
+vn 0.514939 -0.857204 0.000000
+vn 0.990661 -0.136143 0.000000
+vn 0.563280 0.824976 0.045381
+vn 0.279244 -0.960204 0.000000
+vn 0.961364 -0.275185 0.000000
+vn 0.793847 0.605945 0.050661
+vn 0.907865 -0.419233 0.000000
+vn 0.916959 0.398907 0.003296
+vn 0.953948 -0.278481 0.111423
+vn 0.953948 0.278481 0.111423
+vn 0.899686 -0.423688 0.104953
+vn 0.983734 0.137883 0.114963
+vn 0.813746 -0.573443 0.094699
+vn 0.993225 0.000000 0.116092
+vn 0.549303 0.826289 0.124302
+vn 0.686117 -0.723106 0.079501
+vn 0.770409 0.619465 0.150639
+vn 0.507035 -0.859920 0.058229
+vn 0.983734 -0.137883 0.114963
+vn 0.723502 0.646840 0.240974
+vn 0.274667 -0.961028 0.030824
+vn 0.483169 -0.867855 0.115482
+vn 0.961577 -0.143223 0.234169
+vn 0.903134 0.415326 0.108646
+vn 0.930296 -0.288522 0.226386
+vn 0.930296 0.288522 0.226386
+vn 0.873928 -0.437117 0.212348
+vn 0.961577 0.143223 0.234169
+vn 0.786065 -0.588031 0.190497
+vn 0.971587 0.000000 0.236671
+vn 0.351177 0.931547 0.094089
+vn 0.515458 0.832759 0.201941
+vn 0.658254 -0.735832 0.158757
+vn 0.930540 0.000000 0.366100
+vn 0.323252 0.934324 0.149998
+vn 0.460219 0.843257 0.277657
+vn 0.609943 -0.756096 0.237159
+vn 0.647175 0.680319 0.343974
+vn 0.260842 -0.963439 0.061007
+vn 0.442885 -0.880154 0.170660
+vn 0.919706 -0.152440 0.361736
+vn 0.876583 0.433119 0.209693
+vn 0.826838 0.458083 0.326304
+vn 0.886135 -0.305734 0.348186
+vn 0.886135 0.305734 0.348186
+vn 0.826746 -0.459700 0.324198
+vn 0.919706 0.152440 0.361736
+vn 0.736564 -0.611957 0.287912
+vn 0.751091 -0.491134 0.441115
+vn 0.849422 0.165838 0.500931
+vn 0.660237 -0.644124 0.386212
+vn 0.861263 0.000000 0.508133
+vn 0.278512 0.938719 0.202887
+vn 0.381359 0.855708 0.349712
+vn 0.538469 -0.782250 0.313150
+vn 0.549120 0.711600 0.438215
+vn 0.237770 -0.967132 0.089785
+vn 0.385571 -0.895505 0.222205
+vn 0.849422 -0.165838 0.500931
+vn 0.748222 0.495621 0.440962
+vn 0.813318 -0.330302 0.478927
+vn 0.813318 0.330302 0.478927
+vn 0.698904 -0.361461 0.617084
+vn 0.698904 0.361461 0.617084
+vn 0.636860 -0.529527 0.560289
+vn 0.736229 0.183203 0.651448
+vn 0.550523 -0.681631 0.481918
+vn 0.748650 0.000000 0.662923
+vn 0.216742 0.943327 0.251228
+vn 0.276742 0.866787 0.414777
+vn 0.441054 -0.811365 0.383557
+vn 0.417280 0.741905 0.524796
+vn 0.205603 -0.971679 0.116184
+vn 0.310953 -0.911832 0.267953
+vn 0.736229 -0.183203 0.651448
+vn 0.632618 0.537614 0.557390
+vn 0.245094 0.754112 0.609241
+vn 0.164708 -0.976440 0.139225
+vn 0.219672 -0.926633 0.305032
+vn 0.560656 -0.202704 0.802820
+vn 0.458968 0.587359 0.666555
+vn 0.526963 -0.395459 0.752251
+vn 0.526963 0.395459 0.752251
+vn 0.473006 -0.569720 0.672018
+vn 0.560656 0.202704 0.802850
+vn 0.401654 -0.718986 0.567186
+vn 0.572100 0.000000 0.820154
+vn 0.138066 0.946104 0.292856
+vn 0.145878 0.871914 0.467391
+vn 0.316080 -0.838862 0.443129
+vn 0.316630 0.000000 0.948515
+vn 0.043703 0.944731 0.324839
+vn -0.007447 0.865871 0.500168
+vn 0.165960 -0.859004 0.484298
+vn 0.058351 0.751823 0.656728
+vn 0.115726 -0.980651 0.157720
+vn 0.114139 -0.937071 0.329844
+vn 0.309336 -0.219367 0.925291
+vn 0.288247 -0.423780 0.858638
+vn 0.288247 0.423780 0.858638
+vn 0.255470 -0.601917 0.756554
+vn 0.309336 0.219367 0.925291
+vn 0.213813 -0.747581 0.628773
+vn 0.000000 -0.614490 0.788903
+vn 0.000000 0.226112 0.974090
+vn 0.000000 -0.758446 0.651692
+vn -0.063234 0.936918 0.343730
+vn -0.172887 0.845149 0.505753
+vn 0.000000 -0.866451 0.499191
+vn -0.161382 0.734306 0.659291
+vn 0.059969 -0.983581 0.170080
+vn 0.000000 -0.940886 0.338694
+vn 0.000000 -0.226112 0.974090
+vn 0.249763 0.628559 0.736534
+vn 0.000000 -0.435102 0.900357
+vn 0.000000 0.435102 0.900357
+vn -0.255470 -0.601917 0.756554
+vn 0.002136 0.641591 0.767022
+vn -0.245430 0.631153 0.735771
+vn -0.213813 -0.747581 0.628773
+vn -0.288247 0.423780 0.858638
+vn -0.165960 -0.859004 0.484268
+vn -0.309336 0.219367 0.925291
+vn -0.176702 0.921354 0.346141
+vn -0.287942 0.898648 0.330821
+vn -0.114139 -0.937071 0.329844
+vn -0.309336 -0.219367 0.925291
+vn -0.334208 0.810236 0.481399
+vn 0.000000 -0.984649 0.174505
+vn -0.059969 -0.983581 0.170080
+vn -0.288247 -0.423780 0.858638
+vn -0.368816 0.696921 0.615009
+vn -0.115726 -0.980651 0.157720
+vn -0.526963 -0.395459 0.752251
+vn -0.539537 0.650319 0.534715
+vn -0.473006 -0.569720 0.672018
+vn -0.456343 0.603473 0.653859
+vn -0.401654 -0.718986 0.567186
+vn -0.526963 0.395459 0.752251
+vn -0.316080 -0.838862 0.443129
+vn -0.316630 0.000000 0.948515
+vn -0.560656 0.202704 0.802820
+vn -0.388684 0.871120 0.299997
+vn -0.219672 -0.926633 0.305032
+vn -0.560656 -0.202704 0.802820
+vn -0.476333 0.765984 0.431654
+vn -0.474075 0.841914 0.257698
+vn -0.310953 -0.911832 0.267953
+vn -0.572100 0.000000 0.820154
+vn -0.736229 -0.183203 0.651448
+vn -0.591449 0.719016 0.364910
+vn -0.164708 -0.976440 0.139225
+vn -0.698904 -0.361461 0.617084
+vn -0.664083 0.607868 0.435255
+vn -0.636860 -0.529527 0.560289
+vn -0.614277 0.571032 0.544542
+vn -0.550523 -0.681631 0.481918
+vn -0.698904 0.361461 0.617084
+vn -0.441054 -0.811365 0.383557
+vn -0.736229 0.183203 0.651448
+vn -0.813318 0.330302 0.478927
+vn -0.538469 -0.782250 0.313150
+vn -0.748650 0.000000 0.662923
+vn -0.849422 0.165838 0.500931
+vn -0.542253 0.814112 0.207648
+vn -0.385571 -0.895505 0.222205
+vn -0.849422 -0.165838 0.500931
+vn -0.678640 0.675253 0.288827
+vn -0.205603 -0.971679 0.116184
+vn -0.813318 -0.330302 0.478927
+vn -0.744896 0.579577 0.330424
+vn -0.751091 -0.491134 0.441115
+vn -0.721854 0.544542 0.427045
+vn -0.660237 -0.644124 0.386212
+vn -0.826746 -0.459700 0.324198
+vn -0.789148 0.529160 0.311686
+vn -0.736595 -0.611957 0.287912
+vn -0.886135 0.305734 0.348186
+vn -0.609943 -0.756096 0.237159
+vn -0.861263 0.000000 0.508133
+vn -0.919706 0.152440 0.361736
+vn -0.593280 0.790338 0.152837
+vn -0.442885 -0.880154 0.170660
+vn -0.919706 -0.152440 0.361736
+vn -0.740440 0.638844 0.208716
+vn -0.237770 -0.967132 0.089785
+vn -0.886135 -0.305734 0.348186
+vn -0.789636 0.569292 0.228828
+vn -0.260842 -0.963439 0.061007
+vn -0.930296 -0.288522 0.226386
+vn -0.807459 0.574297 0.134648
+vn -0.873928 -0.437117 0.212348
+vn -0.826899 0.524644 0.202399
+vn -0.786065 -0.588031 0.190497
+vn -0.930296 0.288522 0.226386
+vn -0.658254 -0.735832 0.158757
+vn -0.930540 0.000000 0.366100
+vn -0.961577 0.143223 0.234169
+vn -0.627888 0.772423 0.095370
+vn -0.483169 -0.867855 0.115482
+vn -0.961577 -0.143223 0.234169
+vn -0.780328 0.612171 0.127537
+vn -0.646931 0.761650 0.036775
+vn -0.507035 -0.859920 0.058199
+vn -0.971587 0.000000 0.236671
+vn -0.983734 -0.137883 0.114963
+vn -0.801294 0.596393 0.046724
+vn -0.274667 -0.961028 0.030824
+vn -0.953948 -0.278481 0.111423
+vn -0.807581 0.587695 0.048647
+vn -0.899686 -0.423688 0.104953
+vn -0.843806 0.527329 0.099399
+vn -0.813746 -0.573443 0.094699
+vn -0.953948 0.278481 0.111423
+vn -0.686117 -0.723106 0.079501
+vn -0.983734 0.137883 0.114963
+vn -0.993225 0.000000 0.116092
+vn -0.436445 0.899686 -0.007599
+vn -0.430372 0.901822 -0.038118
+vn -0.415540 0.907041 -0.067476
+vn -0.391919 0.915067 -0.094852
+vn -0.359569 0.925413 -0.119358
+vn -0.318857 0.937376 -0.140019
+vn -0.270363 0.950072 -0.155644
+vn -0.215308 0.962523 -0.164800
+vn -0.156194 0.973693 -0.165838
+vn -0.097232 0.982604 -0.158025
+vn -0.042512 0.988861 -0.142582
+vn 0.005341 0.992584 -0.121403
+vn 0.045167 0.994324 -0.096133
+vn 0.076144 0.994751 -0.067965
+vn 0.097903 0.994446 -0.037965
+vn 0.110294 0.993866 -0.007080
+vn 0.113285 0.993255 0.023957
+vn 0.106937 0.992767 0.054476
+vn 0.091281 0.992279 0.083865
+vn 0.066408 0.991546 0.111301
+vn 0.032533 0.990173 0.135899
+vn -0.009735 0.987579 0.156621
+vn -0.059664 0.983215 0.172338
+vn -0.115696 0.976531 0.181555
+vn -0.175146 0.967437 0.182592
+vn -0.233772 0.956450 0.174749
+vn -0.287484 0.944426 0.159246
+vn -0.333995 0.932401 0.138005
+vn -0.372204 0.921262 0.112644
+vn -0.401654 0.911863 0.084414
+vn -0.422163 0.904843 0.054384
+vn -0.433729 0.900723 0.023408
+vn -0.168279 0.985687 0.008484
+usemtl SkinColor
+s 1
+f 6280//4057 6279//4058 6294//4059
+f 6275//4060 6274//2918 6289//4061
+f 6270//4062 6269//4063 6285//4064
+f 6281//4065 6280//4057 6295//4066
+f 6276//4067 6275//4060 6290//4068
+f 6271//4069 6270//4062 6285//4064
+f 6277//4070 6276//4067 6291//4071
+f 6272//4072 6271//4069 6287//4073
+f 6278//4074 6277//4070 6292//4075
+f 6273//4076 6272//4072 6288//4077
+f 6279//4058 6278//4074 6293//4078
+f 6274//2918 6273//4076 6289//4061
+f 6269//4063 6268//4079 6284//4080
+f 6295//4066 6294//4059 6309//4081
+f 6290//4068 6289//4061 6304//4082
+f 6285//4064 6284//4080 6300//4083
+f 6296//4084 6295//4066 6310//4085
+f 6291//4071 6290//4068 6305//4086
+f 6286//4087 6285//4064 6300//4083
+f 6292//4075 6291//4071 6306//4088
+f 6287//4073 6286//4087 6302//4089
+f 6293//4078 6292//4075 6307//4090
+f 6288//4077 6287//4073 6303//4091
+f 6294//4059 6293//4078 6308//4092
+f 6289//4061 6288//4077 6304//4082
+f 6284//4080 6283//4093 6299//4094
+f 6309//4081 6308//4092 6323//4095
+f 6304//4082 6303//4091 6319//4096
+f 6299//4094 6298//4097 6314//4098
+f 6310//4085 6309//4081 6324//4099
+f 6305//4086 6304//4082 6319//4096
+f 6300//4083 6299//4094 6315//4100
+f 6311//4101 6310//4085 6325//4102
+f 6306//4088 6305//4086 6320//4103
+f 6301//4104 6300//4083 6316//4105
+f 6307//4090 6306//4088 6321//4106
+f 6302//4089 6301//4104 6317//4107
+f 6308//4092 6307//4090 6322//4108
+f 6303//4091 6302//4089 6318//4109
+f 6317//4107 6316//4105 6332//4110
+f 6323//4095 6322//4108 6337//4111
+f 6318//4109 6317//4107 6333//4112
+f 6324//4099 6323//4095 6338//4113
+f 6319//4096 6318//4109 6334//4114
+f 6314//4098 6313//4115 6329//4116
+f 6325//4102 6324//4099 6339//4117
+f 6320//4103 6319//4096 6334//4114
+f 6315//4100 6314//4098 6330//4118
+f 6326//4119 6325//4102 6340//4120
+f 6321//4106 6320//4103 6335//4121
+f 6316//4105 6315//4100 6331//4122
+f 6322//4108 6321//4106 6336//4123
+f 6336//4123 6335//4121 6350//4124
+f 6331//4122 6330//4118 6346//4125
+f 6337//4111 6336//4123 6351//4126
+f 6332//4110 6331//4122 6347//4127
+f 6338//4113 6337//4111 6352//4128
+f 6333//4112 6332//4110 6348//4129
+f 6339//4117 6338//4113 6353//4130
+f 6334//4114 6333//4112 6349//4131
+f 6329//4116 6328//4132 6344//4133
+f 6340//4120 6339//4117 6354//4134
+f 6335//4121 6334//4114 6349//4131
+f 6330//4118 6329//4116 6345//4135
+f 6341//4136 6340//4120 6355//4137
+f 6355//4137 6354//4134 6369//4138
+f 6350//4124 6349//4131 6364//4139
+f 6345//4135 6344//4133 6360//4140
+f 6356//4141 6355//4137 6370//4142
+f 6351//4126 6350//4124 6365//4143
+f 6346//4125 6345//4135 6361//4144
+f 6352//4128 6351//4126 6366//4145
+f 6347//4127 6346//4125 6362//4146
+f 6353//4130 6352//4128 6367//4147
+f 6348//4129 6347//4127 6363//4148
+f 6354//4134 6353//4130 6368//4149
+f 6349//4131 6348//4129 6364//4139
+f 6344//4133 6343//4150 6359//4151
+f 6369//4138 6368//4149 6383//4152
+f 6364//4139 6363//4148 6379//4153
+f 6359//4151 6358//4154 6374//4155
+f 6370//4142 6369//4138 6384//4156
+f 6365//4143 6364//4139 6379//4153
+f 6360//4140 6359//4151 6375//4157
+f 6371//4158 6370//4142 6385//4159
+f 6366//4145 6365//4143 6380//4160
+f 6361//4144 6360//4140 6376//4161
+f 6367//4147 6366//4145 6381//4162
+f 6362//4146 6361//4144 6377//4163
+f 6368//4149 6367//4147 6382//4164
+f 6363//4148 6362//4146 6378//4165
+f 6383//4152 6382//4164 6397//4166
+f 6378//4165 6377//4163 6393//4167
+f 6384//4156 6383//4152 6398//4168
+f 6379//4153 6378//4165 6394//3044
+f 6374//4155 6373//4169 6389//4170
+f 6385//4159 6384//4156 6399//4171
+f 6380//4160 6379//4153 6394//3044
+f 6375//4157 6374//4155 6390//4172
+f 6386//4173 6385//4159 6400//4174
+f 6381//4162 6380//4160 6395//4175
+f 6376//4161 6375//4157 6390//4172
+f 6382//4164 6381//4162 6396//4176
+f 6377//4163 6376//4161 6392//4177
+f 6391//4178 6390//4172 6405//4179
+f 6397//4166 6396//4176 6412//4180
+f 6392//4177 6391//4178 6406//4181
+f 6398//4168 6397//4166 6413//4182
+f 6393//4167 6392//4177 6407//4183
+f 6399//4171 6398//4168 6414//4184
+f 6394//3044 6393//4167 6408//4185
+f 6389//4170 6388//4186 6403//4187
+f 6400//4174 6399//4171 6415//4188
+f 6395//4175 6394//3044 6410//4189
+f 6390//4172 6389//4170 6404//4190
+f 6401//4191 6400//4174 6416//4192
+f 6396//4176 6395//4175 6411//4193
+f 6410//4189 6409//4194 6425//4195
+f 6405//4179 6404//4190 6419//4196
+f 6416//4192 6415//4188 6431//4197
+f 6411//4193 6410//4189 6426//4198
+f 6406//4181 6405//4179 6420//4199
+f 6412//4180 6411//4193 6427//4200
+f 6407//4183 6406//4181 6421//4201
+f 6413//4182 6412//4180 6428//4202
+f 6408//4185 6407//4183 6422//4203
+f 6414//4184 6413//4182 6429//4204
+f 6409//4194 6408//4185 6423//4205
+f 6404//4190 6403//4187 6418//4206
+f 6415//4188 6414//4184 6430//4207
+f 6429//4204 6428//4202 6444//4208
+f 6424//4209 6423//4205 6438//4210
+f 6419//4196 6418//4206 6433//4211
+f 6430//4207 6429//4204 6445//4212
+f 6425//4195 6424//4209 6440//4213
+f 6420//4199 6419//4196 6434//4214
+f 6431//4197 6430//4207 6446//4215
+f 6426//4198 6425//4195 6441//4216
+f 6421//4201 6420//4199 6435//4217
+f 6427//4200 6426//4198 6442//4218
+f 6422//4203 6421//4201 6436//4219
+f 6428//4202 6427//4200 6443//4220
+f 6423//4205 6422//4203 6437//4221
+f 6443//4220 6442//4218 6458//4222
+f 6438//4210 6437//4221 6452//4223
+f 6444//4208 6443//4220 6459//4224
+f 6439//4225 6438//4210 6453//4226
+f 6434//4214 6433//4211 6448//4227
+f 6445//4212 6444//4208 6460//4228
+f 6440//4213 6439//4225 6455//4229
+f 6435//4217 6434//4214 6449//4230
+f 6446//4215 6445//4212 6461//4231
+f 6441//4216 6440//4213 6456//4232
+f 6436//4219 6435//4217 6450//4233
+f 6442//4218 6441//4216 6457//4234
+f 6437//4221 6436//4219 6451//4235
+f 6451//4235 6450//4233 6465//4236
+f 6457//4234 6456//4232 6472//4237
+f 6452//4223 6451//4235 6466//4238
+f 6458//4222 6457//4234 6473//4239
+f 6453//4226 6452//4223 6467//4240
+f 6459//4224 6458//4222 6474//4241
+f 6454//4242 6453//4226 6468//4243
+f 6449//4230 6448//4227 6463//4244
+f 6460//4228 6459//4224 6475//4245
+f 6455//4229 6454//4242 6470//4246
+f 6450//4233 6449//4230 6464//4247
+f 6461//4231 6460//4228 6476//4248
+f 6456//4232 6455//4229 6471//4249
+f 6470//4246 6469//4250 6485//4251
+f 6465//4236 6464//4247 6479//4252
+f 6476//4248 6475//4245 6491//4253
+f 6471//4249 6470//4246 6486//4254
+f 6466//4238 6465//4236 6480//4255
+f 6472//4237 6471//4249 6487//4256
+f 6467//4240 6466//4238 6481//4257
+f 6473//4239 6472//4237 6488//4258
+f 6468//4243 6467//4240 6482//4259
+f 6474//4241 6473//4239 6489//4260
+f 6469//4250 6468//4243 6483//4261
+f 6464//4247 6463//4244 6478//4262
+f 6475//4245 6474//4241 6490//4263
+f 6489//4260 6488//4258 6504//4264
+f 6484//4265 6483//4261 6498//4266
+f 6479//4252 6478//4262 6493//4267
+f 6490//4263 6489//4260 6505//4268
+f 6485//4251 6484//4265 6500//4269
+f 6480//4255 6479//4252 6494//4270
+f 6491//4253 6490//4263 6506//4271
+f 6486//4254 6485//4251 6501//4272
+f 6481//4257 6480//4255 6495//4273
+f 6487//4256 6486//4254 6502//4274
+f 6482//4259 6481//4257 6496//4275
+f 6488//4258 6487//4256 6503//4276
+f 6483//4261 6482//4259 6497//4277
+f 6503//4276 6502//4274 6518//4278
+f 6498//4266 6497//4277 6512//4279
+f 6504//4264 6503//4276 6519//4280
+f 6499//4281 6498//4266 6513//4282
+f 6494//4270 6493//4267 6508//4283
+f 6505//4268 6504//4264 6520//4284
+f 6500//4269 6499//4281 6515//4285
+f 6495//4273 6494//4270 6509//4286
+f 6506//4271 6505//4268 6521//4287
+f 6501//4272 6500//4269 6516//4288
+f 6496//4275 6495//4273 6510//4289
+f 6502//4274 6501//4272 6517//4290
+f 6497//4277 6496//4275 6511//4291
+f 6517//4290 6516//4288 6531//4292
+f 6512//4279 6511//4291 6527//4293
+f 6518//4278 6517//4290 6532//4294
+f 6513//4282 6512//4279 6528//4295
+f 6519//4280 6518//4278 6533//4296
+f 6514//261 6513//4282 6529//4297
+f 6509//4286 6508//4283 6524//4298
+f 6520//4284 6519//4280 6534//4299
+f 6515//4285 6514//261 6529//4297
+f 6510//4289 6509//4286 6525//4300
+f 6521//4287 6520//4284 6535//4301
+f 6516//4288 6515//4285 6530//4302
+f 6511//4291 6510//4289 6525//4300
+f 6525//4300 6524//4298 6540//4303
+f 6536//4304 6535//4301 6550//4305
+f 6531//4292 6530//4302 6545//4306
+f 6526//4307 6525//4300 6540//4303
+f 6532//4294 6531//4292 6546//4308
+f 6527//4293 6526//4307 6542//4309
+f 6533//4296 6532//4294 6547//4310
+f 6528//4295 6527//4293 6543//4311
+f 6534//4299 6533//4296 6548//4312
+f 6529//4297 6528//4295 6544//4313
+f 6524//4298 6523//4314 6539//4315
+f 6535//4301 6534//4299 6549//4316
+f 6530//4302 6529//4297 6544//4313
+f 6544//4313 6543//4311 6559//4317
+f 6539//4315 6538//4318 6554//4319
+f 6550//4305 6549//4316 6564//4320
+f 6545//4306 6544//4313 6559//4317
+f 6540//4303 6539//4315 6555//4321
+f 6551//4322 6550//4305 6565//4323
+f 6546//4308 6545//4306 6560//4324
+f 6541//4325 6540//4303 6556//4326
+f 6547//4310 6546//4308 6561//4327
+f 6542//4309 6541//4325 6557//4328
+f 6548//4312 6547//4310 6562//4329
+f 6543//4311 6542//4309 6558//4330
+f 6549//4316 6548//4312 6563//4331
+f 6563//4331 6562//4329 6577//4332
+f 6558//4330 6557//4328 6573//4333
+f 6564//4320 6563//4331 6578//4334
+f 6559//4317 6558//4330 6574//4335
+f 6554//4319 6553//4336 6569//4337
+f 6565//4323 6564//4320 6579//4338
+f 6560//4324 6559//4317 6574//4335
+f 6555//4321 6554//4319 6570//4339
+f 6566//4340 6565//4323 6580//4341
+f 6561//4327 6560//4324 6575//4342
+f 6556//4326 6555//4321 6571//4343
+f 6562//4329 6561//4327 6576//4344
+f 6557//4328 6556//4326 6572//4345
+f 6577//4332 6576//4344 6591//4346
+f 6572//4345 6571//4343 6587//4347
+f 6578//4334 6577//4332 6592//4348
+f 6573//4333 6572//4345 6588//4349
+f 6579//4338 6578//4334 6593//4350
+f 6574//4335 6573//4333 6589//4351
+f 6569//4337 6568//4352 6584//4353
+f 6580//4341 6579//4338 6594//4354
+f 6575//4342 6574//4335 6589//4351
+f 6570//4339 6569//4337 6585//4355
+f 6581//4356 6580//4341 6595//4357
+f 6576//4344 6575//4342 6590//4358
+f 6571//4343 6570//4339 6586//4359
+f 6585//4355 6584//4353 6601//4360
+f 6596//4361 6595//4357 6611//4362
+f 6591//4346 6590//4358 6606//4363
+f 6586//4359 6585//4355 6602//4364
+f 6592//4348 6591//4346 6607//4365
+f 6587//4347 6586//4359 6603//4366
+f 6593//4350 6592//4348 6608//4367
+f 6588//4349 6587//4347 6604//4368
+f 6594//4354 6593//4350 6609//4369
+f 6589//4351 6588//4349 6605//4370
+f 6584//4353 6583//4371 6600//4372
+f 6595//4357 6594//4354 6610//4373
+f 6590//4358 6589//4351 6605//4370
+f 6605//4370 6604//4368 6620//4374
+f 6600//4372 6599//4375 6615//4376
+f 6611//4362 6610//4373 6625//4377
+f 6606//4363 6605//4370 6620//4374
+f 6601//4360 6600//4372 6616//4378
+f 6612//4379 6611//4362 6626//4380
+f 6607//4365 6606//4363 6621//4381
+f 6602//4364 6601//4360 6616//4378
+f 6608//4367 6607//4365 6622//4382
+f 6603//4366 6602//4364 6618//4383
+f 6609//4369 6608//4367 6623//4384
+f 6604//4368 6603//4366 6619//4385
+f 6610//4373 6609//4369 6624//4386
+f 6624//4386 6623//4384 6638//4387
+f 6619//4385 6618//4383 6634//4388
+f 6625//4377 6624//4386 6639//4389
+f 6620//4374 6619//4385 6635//3282
+f 6615//4376 6614//4390 6630//4391
+f 6626//4380 6625//4377 6640//4392
+f 6621//4381 6620//4374 6635//3282
+f 6616//4378 6615//4376 6631//4393
+f 6627//4394 6626//4380 6641//4395
+f 6622//4382 6621//4381 6636//4396
+f 6617//4397 6616//4378 6631//4393
+f 6623//4384 6622//4382 6637//4398
+f 6618//4383 6617//4397 6633//4399
+f 6638//4387 6637//4398 6653//4400
+f 6633//4399 6632//4401 6647//4402
+f 6639//4389 6638//4387 6654//4403
+f 6634//4388 6633//4399 6648//4404
+f 6640//4392 6639//4389 6655//4405
+f 6635//3282 6634//4388 6649//4406
+f 6630//4391 6629//4407 6644//4408
+f 6641//4395 6640//4392 6656//4409
+f 6636//4396 6635//3282 6651//4410
+f 6631//4393 6630//4391 6645//4411
+f 6642//4412 6641//4395 6657//4413
+f 6637//4398 6636//4396 6652//4414
+f 6632//4401 6631//4393 6646//4415
+f 6657//4413 6656//4409 6672//4416
+f 6652//4414 6651//4410 6667//4417
+f 6647//4402 6646//4415 6661//4418
+f 6653//4400 6652//4414 6668//4419
+f 6648//4404 6647//4402 6662//4420
+f 6654//4403 6653//4400 6669//4421
+f 6649//4406 6648//4404 6663//4422
+f 6655//4405 6654//4403 6670//4423
+f 6650//4424 6649//4406 6664//4425
+f 6645//4411 6644//4408 6659//4426
+f 6656//4409 6655//4405 6671//4427
+f 6651//4410 6650//4424 6666//4428
+f 6646//4415 6645//4411 6660//4429
+f 6660//4429 6659//4426 6674//4430
+f 6671//4427 6670//4423 6686//4431
+f 6666//4428 6665//4432 6681//4433
+f 6661//4418 6660//4429 6675//4434
+f 6672//4416 6671//4427 6687//4435
+f 6667//4417 6666//4428 6682//4436
+f 6662//4420 6661//4418 6676//4437
+f 6668//4419 6667//4417 6683//4438
+f 6663//4422 6662//4420 6677//4439
+f 6669//4421 6668//4419 6684//4440
+f 6664//4425 6663//4422 6678//4441
+f 6670//4423 6669//4421 6685//4442
+f 6665//4432 6664//4425 6679//4443
+f 6679//4443 6678//4441 6693//4444
+f 6685//4442 6684//4440 6700//4445
+f 6680//4446 6679//4443 6694//4447
+f 6675//4434 6674//4430 6689//4448
+f 6686//4431 6685//4442 6701//4449
+f 6681//4433 6680//4446 6696//4450
+f 6676//4437 6675//4434 6690//4451
+f 6687//4435 6686//4431 6702//4452
+f 6682//4436 6681//4433 6697//4453
+f 6677//4439 6676//4437 6691//4454
+f 6683//4438 6682//4436 6698//4455
+f 6678//4441 6677//4439 6692//4456
+f 6684//4440 6683//4438 6699//4457
+f 6698//4455 6697//4453 6713//4458
+f 6693//4444 6692//4456 6707//4459
+f 6699//4457 6698//4455 6714//4460
+f 6694//4447 6693//4444 6708//4461
+f 6700//4445 6699//4457 6715//4462
+f 6695//4463 6694//4447 6709//4464
+f 6690//4451 6689//4448 6704//4465
+f 6701//4449 6700//4445 6716//4466
+f 6696//4450 6695//4463 6711//4467
+f 6691//4454 6690//4451 6705//4468
+f 6702//4452 6701//4449 6717//4469
+f 6697//4453 6696//4450 6712//4470
+f 6692//4456 6691//4454 6706//4471
+f 6717//4469 6716//4466 6733//4472
+f 6712//4470 6711//4467 6728//4473
+f 6707//4459 6706//4471 6722//4474
+f 6713//4458 6712//4470 6729//4475
+f 6708//4461 6707//4459 6723//4476
+f 6714//4460 6713//4458 6730//4477
+f 6709//4464 6708//4461 6724//4478
+f 6715//4462 6714//4460 6731//4479
+f 6710//4480 6709//4464 6725//4481
+f 6705//4468 6704//4465 6720//4482
+f 6716//4466 6715//4462 6732//4483
+f 6711//4467 6710//4480 6727//4484
+f 6706//4471 6705//4468 6721//4485
+f 6721//4485 6720//4482 6735//4486
+f 6732//4483 6731//4479 6747//4487
+f 6727//4484 6726//4488 6742//4489
+f 6722//4474 6721//4485 6736//4490
+f 6733//4472 6732//4483 6748//4491
+f 6728//4473 6727//4484 6743//4492
+f 6723//4476 6722//4474 6737//4493
+f 6729//4475 6728//4473 6744//4494
+f 6724//4478 6723//4476 6738//4495
+f 6730//4477 6729//4475 6745//4496
+f 6725//4481 6724//4478 6739//4497
+f 6731//4479 6730//4477 6746//4498
+f 6726//4488 6725//4481 6740//4499
+f 6597//364 6281//4065 6296//4084
+f 6597//364 6296//4084 6311//4101
+f 6597//364 6311//4101 6326//4119
+f 6597//364 6326//4119 6341//4136
+f 6597//364 6341//4136 6356//4141
+f 6597//364 6356//4141 6371//4158
+f 6597//364 6371//4158 6386//4173
+f 6597//364 6386//4173 6401//4191
+f 6597//364 6401//4191 6416//4192
+f 6597//364 6416//4192 6431//4197
+f 6597//364 6431//4197 6446//4215
+f 6597//364 6446//4215 6461//4231
+f 6597//364 6461//4231 6476//4248
+f 6597//364 6476//4248 6491//4253
+f 6597//364 6491//4253 6506//4271
+f 6597//364 6506//4271 6521//4287
+f 6597//364 6521//4287 6536//4304
+f 6597//364 6536//4304 6551//4322
+f 6597//364 6551//4322 6566//4340
+f 6597//364 6566//4340 6581//4356
+f 6597//364 6581//4356 6596//4361
+f 6597//364 6596//4361 6612//4379
+f 6597//364 6612//4379 6627//4394
+f 6597//364 6627//4394 6642//4412
+f 6597//364 6642//4412 6657//4413
+f 6597//364 6657//4413 6672//4416
+f 6597//364 6672//4416 6687//4435
+f 6597//364 6687//4435 6702//4452
+f 6597//364 6702//4452 6717//4469
+f 6597//364 6717//4469 6733//4472
+f 6597//364 6733//4472 6748//4491
+f 6740//4499 6739//4497 6272//4072
+f 6746//4498 6745//4496 6279//4058
+f 6741//4500 6740//4499 6273//4076
+f 6736//4490 6735//4486 6268//4079
+f 6747//4487 6746//4498 6280//4057
+f 6742//4489 6741//4500 6275//4060
+f 6737//4493 6736//4490 6269//4063
+f 6748//4491 6747//4487 6281//4065
+f 6743//4492 6742//4489 6276//4067
+f 6738//4495 6737//4493 6270//4062
+f 6597//364 6748//4491 6281//4065
+f 6744//4494 6743//4492 6277//4070
+f 6739//4497 6738//4495 6271//4069
+f 6745//4496 6744//4494 6278//4074
+f 6295//4066 6280//4057 6294//4059
+f 6290//4068 6275//4060 6289//4061
+f 6269//4063 6284//4080 6285//4064
+f 6296//4084 6281//4065 6295//4066
+f 6291//4071 6276//4067 6290//4068
+f 6286//4087 6271//4069 6285//4064
+f 6292//4075 6277//4070 6291//4071
+f 6271//4069 6286//4087 6287//4073
+f 6293//4078 6278//4074 6292//4075
+f 6272//4072 6287//4073 6288//4077
+f 6294//4059 6279//4058 6293//4078
+f 6273//4076 6288//4077 6289//4061
+f 6268//4079 6283//4093 6284//4080
+f 6310//4085 6295//4066 6309//4081
+f 6305//4086 6290//4068 6304//4082
+f 6284//4080 6299//4094 6300//4083
+f 6311//4101 6296//4084 6310//4085
+f 6306//4088 6291//4071 6305//4086
+f 6301//4104 6286//4087 6300//4083
+f 6307//4090 6292//4075 6306//4088
+f 6286//4087 6301//4104 6302//4089
+f 6308//4092 6293//4078 6307//4090
+f 6287//4073 6302//4089 6303//4091
+f 6309//4081 6294//4059 6308//4092
+f 6288//4077 6303//4091 6304//4082
+f 6283//4093 6298//4097 6299//4094
+f 6324//4099 6309//4081 6323//4095
+f 6303//4091 6318//4109 6319//4096
+f 6298//4097 6313//4115 6314//4098
+f 6325//4102 6310//4085 6324//4099
+f 6320//4103 6305//4086 6319//4096
+f 6299//4094 6314//4098 6315//4100
+f 6326//4119 6311//4101 6325//4102
+f 6321//4106 6306//4088 6320//4103
+f 6300//4083 6315//4100 6316//4105
+f 6322//4108 6307//4090 6321//4106
+f 6301//4104 6316//4105 6317//4107
+f 6323//4095 6308//4092 6322//4108
+f 6302//4089 6317//4107 6318//4109
+f 6316//4105 6331//4122 6332//4110
+f 6338//4113 6323//4095 6337//4111
+f 6317//4107 6332//4110 6333//4112
+f 6339//4117 6324//4099 6338//4113
+f 6318//4109 6333//4112 6334//4114
+f 6313//4115 6328//4132 6329//4116
+f 6340//4120 6325//4102 6339//4117
+f 6335//4121 6320//4103 6334//4114
+f 6314//4098 6329//4116 6330//4118
+f 6341//4136 6326//4119 6340//4120
+f 6336//4123 6321//4106 6335//4121
+f 6315//4100 6330//4118 6331//4122
+f 6337//4111 6322//4108 6336//4123
+f 6351//4126 6336//4123 6350//4124
+f 6330//4118 6345//4135 6346//4125
+f 6352//4128 6337//4111 6351//4126
+f 6331//4122 6346//4125 6347//4127
+f 6353//4130 6338//4113 6352//4128
+f 6332//4110 6347//4127 6348//4129
+f 6354//4134 6339//4117 6353//4130
+f 6333//4112 6348//4129 6349//4131
+f 6328//4132 6343//4150 6344//4133
+f 6355//4137 6340//4120 6354//4134
+f 6350//4124 6335//4121 6349//4131
+f 6329//4116 6344//4133 6345//4135
+f 6356//4141 6341//4136 6355//4137
+f 6370//4142 6355//4137 6369//4138
+f 6365//4143 6350//4124 6364//4139
+f 6344//4133 6359//4151 6360//4140
+f 6371//4158 6356//4141 6370//4142
+f 6366//4145 6351//4126 6365//4143
+f 6345//4135 6360//4140 6361//4144
+f 6367//4147 6352//4128 6366//4145
+f 6346//4125 6361//4144 6362//4146
+f 6368//4149 6353//4130 6367//4147
+f 6347//4127 6362//4146 6363//4148
+f 6369//4138 6354//4134 6368//4149
+f 6348//4129 6363//4148 6364//4139
+f 6343//4150 6358//4154 6359//4151
+f 6384//4156 6369//4138 6383//4152
+f 6363//4148 6378//4165 6379//4153
+f 6358//4154 6373//4169 6374//4155
+f 6385//4159 6370//4142 6384//4156
+f 6380//4160 6365//4143 6379//4153
+f 6359//4151 6374//4155 6375//4157
+f 6386//4173 6371//4158 6385//4159
+f 6381//4162 6366//4145 6380//4160
+f 6360//4140 6375//4157 6376//4161
+f 6382//4164 6367//4147 6381//4162
+f 6361//4144 6376//4161 6377//4163
+f 6383//4152 6368//4149 6382//4164
+f 6362//4146 6377//4163 6378//4165
+f 6398//4168 6383//4152 6397//4166
+f 6377//4163 6392//4177 6393//4167
+f 6399//4171 6384//4156 6398//4168
+f 6378//4165 6393//4167 6394//3044
+f 6373//4169 6388//4186 6389//4170
+f 6400//4174 6385//4159 6399//4171
+f 6395//4175 6380//4160 6394//3044
+f 6374//4155 6389//4170 6390//4172
+f 6401//4191 6386//4173 6400//4174
+f 6396//4176 6381//4162 6395//4175
+f 6391//4178 6376//4161 6390//4172
+f 6397//4166 6382//4164 6396//4176
+f 6376//4161 6391//4178 6392//4177
+f 6406//4181 6391//4178 6405//4179
+f 6396//4176 6411//4193 6412//4180
+f 6407//4183 6392//4177 6406//4181
+f 6397//4166 6412//4180 6413//4182
+f 6408//4185 6393//4167 6407//4183
+f 6398//4168 6413//4182 6414//4184
+f 6409//4194 6394//3044 6408//4185
+f 6404//4190 6389//4170 6403//4187
+f 6399//4171 6414//4184 6415//4188
+f 6394//3044 6409//4194 6410//4189
+f 6405//4179 6390//4172 6404//4190
+f 6400//4174 6415//4188 6416//4192
+f 6395//4175 6410//4189 6411//4193
+f 6409//4194 6424//4209 6425//4195
+f 6420//4199 6405//4179 6419//4196
+f 6415//4188 6430//4207 6431//4197
+f 6410//4189 6425//4195 6426//4198
+f 6421//4201 6406//4181 6420//4199
+f 6411//4193 6426//4198 6427//4200
+f 6422//4203 6407//4183 6421//4201
+f 6412//4180 6427//4200 6428//4202
+f 6423//4205 6408//4185 6422//4203
+f 6413//4182 6428//4202 6429//4204
+f 6424//4209 6409//4194 6423//4205
+f 6419//4196 6404//4190 6418//4206
+f 6414//4184 6429//4204 6430//4207
+f 6428//4202 6443//4220 6444//4208
+f 6439//4225 6424//4209 6438//4210
+f 6434//4214 6419//4196 6433//4211
+f 6429//4204 6444//4208 6445//4212
+f 6424//4209 6439//4225 6440//4213
+f 6435//4217 6420//4199 6434//4214
+f 6430//4207 6445//4212 6446//4215
+f 6425//4195 6440//4213 6441//4216
+f 6436//4219 6421//4201 6435//4217
+f 6426//4198 6441//4216 6442//4218
+f 6437//4221 6422//4203 6436//4219
+f 6427//4200 6442//4218 6443//4220
+f 6438//4210 6423//4205 6437//4221
+f 6442//4218 6457//4234 6458//4222
+f 6453//4226 6438//4210 6452//4223
+f 6443//4220 6458//4222 6459//4224
+f 6454//4242 6439//4225 6453//4226
+f 6449//4230 6434//4214 6448//4227
+f 6444//4208 6459//4224 6460//4228
+f 6439//4225 6454//4242 6455//4229
+f 6450//4233 6435//4217 6449//4230
+f 6445//4212 6460//4228 6461//4231
+f 6440//4213 6455//4229 6456//4232
+f 6451//4235 6436//4219 6450//4233
+f 6441//4216 6456//4232 6457//4234
+f 6452//4223 6437//4221 6451//4235
+f 6466//4238 6451//4235 6465//4236
+f 6456//4232 6471//4249 6472//4237
+f 6467//4240 6452//4223 6466//4238
+f 6457//4234 6472//4237 6473//4239
+f 6468//4243 6453//4226 6467//4240
+f 6458//4222 6473//4239 6474//4241
+f 6469//4250 6454//4242 6468//4243
+f 6464//4247 6449//4230 6463//4244
+f 6459//4224 6474//4241 6475//4245
+f 6454//4242 6469//4250 6470//4246
+f 6465//4236 6450//4233 6464//4247
+f 6460//4228 6475//4245 6476//4248
+f 6455//4229 6470//4246 6471//4249
+f 6469//4250 6484//4265 6485//4251
+f 6480//4255 6465//4236 6479//4252
+f 6475//4245 6490//4263 6491//4253
+f 6470//4246 6485//4251 6486//4254
+f 6481//4257 6466//4238 6480//4255
+f 6471//4249 6486//4254 6487//4256
+f 6482//4259 6467//4240 6481//4257
+f 6472//4237 6487//4256 6488//4258
+f 6483//4261 6468//4243 6482//4259
+f 6473//4239 6488//4258 6489//4260
+f 6484//4265 6469//4250 6483//4261
+f 6479//4252 6464//4247 6478//4262
+f 6474//4241 6489//4260 6490//4263
+f 6488//4258 6503//4276 6504//4264
+f 6499//4281 6484//4265 6498//4266
+f 6494//4270 6479//4252 6493//4267
+f 6489//4260 6504//4264 6505//4268
+f 6484//4265 6499//4281 6500//4269
+f 6495//4273 6480//4255 6494//4270
+f 6490//4263 6505//4268 6506//4271
+f 6485//4251 6500//4269 6501//4272
+f 6496//4275 6481//4257 6495//4273
+f 6486//4254 6501//4272 6502//4274
+f 6497//4277 6482//4259 6496//4275
+f 6487//4256 6502//4274 6503//4276
+f 6498//4266 6483//4261 6497//4277
+f 6502//4274 6517//4290 6518//4278
+f 6513//4282 6498//4266 6512//4279
+f 6503//4276 6518//4278 6519//4280
+f 6514//261 6499//4281 6513//4282
+f 6509//4286 6494//4270 6508//4283
+f 6504//4264 6519//4280 6520//4284
+f 6499//4281 6514//261 6515//4285
+f 6510//4289 6495//4273 6509//4286
+f 6505//4268 6520//4284 6521//4287
+f 6500//4269 6515//4285 6516//4288
+f 6511//4291 6496//4275 6510//4289
+f 6501//4272 6516//4288 6517//4290
+f 6512//4279 6497//4277 6511//4291
+f 6532//4294 6517//4290 6531//4292
+f 6511//4291 6526//4307 6527//4293
+f 6533//4296 6518//4278 6532//4294
+f 6512//4279 6527//4293 6528//4295
+f 6534//4299 6519//4280 6533//4296
+f 6513//4282 6528//4295 6529//4297
+f 6508//4283 6523//4314 6524//4298
+f 6535//4301 6520//4284 6534//4299
+f 6530//4302 6515//4285 6529//4297
+f 6509//4286 6524//4298 6525//4300
+f 6536//4304 6521//4287 6535//4301
+f 6531//4292 6516//4288 6530//4302
+f 6526//4307 6511//4291 6525//4300
+f 6524//4298 6539//4315 6540//4303
+f 6551//4322 6536//4304 6550//4305
+f 6546//4308 6531//4292 6545//4306
+f 6541//4325 6526//4307 6540//4303
+f 6547//4310 6532//4294 6546//4308
+f 6526//4307 6541//4325 6542//4309
+f 6548//4312 6533//4296 6547//4310
+f 6527//4293 6542//4309 6543//4311
+f 6549//4316 6534//4299 6548//4312
+f 6528//4295 6543//4311 6544//4313
+f 6523//4314 6538//4318 6539//4315
+f 6550//4305 6535//4301 6549//4316
+f 6545//4306 6530//4302 6544//4313
+f 6543//4311 6558//4330 6559//4317
+f 6538//4318 6553//4336 6554//4319
+f 6565//4323 6550//4305 6564//4320
+f 6560//4324 6545//4306 6559//4317
+f 6539//4315 6554//4319 6555//4321
+f 6566//4340 6551//4322 6565//4323
+f 6561//4327 6546//4308 6560//4324
+f 6540//4303 6555//4321 6556//4326
+f 6562//4329 6547//4310 6561//4327
+f 6541//4325 6556//4326 6557//4328
+f 6563//4331 6548//4312 6562//4329
+f 6542//4309 6557//4328 6558//4330
+f 6564//4320 6549//4316 6563//4331
+f 6578//4334 6563//4331 6577//4332
+f 6557//4328 6572//4345 6573//4333
+f 6579//4338 6564//4320 6578//4334
+f 6558//4330 6573//4333 6574//4335
+f 6553//4336 6568//4352 6569//4337
+f 6580//4341 6565//4323 6579//4338
+f 6575//4342 6560//4324 6574//4335
+f 6554//4319 6569//4337 6570//4339
+f 6581//4356 6566//4340 6580//4341
+f 6576//4344 6561//4327 6575//4342
+f 6555//4321 6570//4339 6571//4343
+f 6577//4332 6562//4329 6576//4344
+f 6556//4326 6571//4343 6572//4345
+f 6592//4348 6577//4332 6591//4346
+f 6571//4343 6586//4359 6587//4347
+f 6593//4350 6578//4334 6592//4348
+f 6572//4345 6587//4347 6588//4349
+f 6594//4354 6579//4338 6593//4350
+f 6573//4333 6588//4349 6589//4351
+f 6568//4352 6583//4371 6584//4353
+f 6595//4357 6580//4341 6594//4354
+f 6590//4358 6575//4342 6589//4351
+f 6569//4337 6584//4353 6585//4355
+f 6596//4361 6581//4356 6595//4357
+f 6591//4346 6576//4344 6590//4358
+f 6570//4339 6585//4355 6586//4359
+f 6584//4353 6600//4372 6601//4360
+f 6612//4379 6596//4361 6611//4362
+f 6607//4365 6591//4346 6606//4363
+f 6585//4355 6601//4360 6602//4364
+f 6608//4367 6592//4348 6607//4365
+f 6586//4359 6602//4364 6603//4366
+f 6609//4369 6593//4350 6608//4367
+f 6587//4347 6603//4366 6604//4368
+f 6610//4373 6594//4354 6609//4369
+f 6588//4349 6604//4368 6605//4370
+f 6583//4371 6599//4375 6600//4372
+f 6611//4362 6595//4357 6610//4373
+f 6606//4363 6590//4358 6605//4370
+f 6604//4368 6619//4385 6620//4374
+f 6599//4375 6614//4390 6615//4376
+f 6626//4380 6611//4362 6625//4377
+f 6621//4381 6606//4363 6620//4374
+f 6600//4372 6615//4376 6616//4378
+f 6627//4394 6612//4379 6626//4380
+f 6622//4382 6607//4365 6621//4381
+f 6617//4397 6602//4364 6616//4378
+f 6623//4384 6608//4367 6622//4382
+f 6602//4364 6617//4397 6618//4383
+f 6624//4386 6609//4369 6623//4384
+f 6603//4366 6618//4383 6619//4385
+f 6625//4377 6610//4373 6624//4386
+f 6639//4389 6624//4386 6638//4387
+f 6618//4383 6633//4399 6634//4388
+f 6640//4392 6625//4377 6639//4389
+f 6619//4385 6634//4388 6635//3282
+f 6614//4390 6629//4407 6630//4391
+f 6641//4395 6626//4380 6640//4392
+f 6636//4396 6621//4381 6635//3282
+f 6615//4376 6630//4391 6631//4393
+f 6642//4412 6627//4394 6641//4395
+f 6637//4398 6622//4382 6636//4396
+f 6632//4401 6617//4397 6631//4393
+f 6638//4387 6623//4384 6637//4398
+f 6617//4397 6632//4401 6633//4399
+f 6637//4398 6652//4414 6653//4400
+f 6648//4404 6633//4399 6647//4402
+f 6638//4387 6653//4400 6654//4403
+f 6649//4406 6634//4388 6648//4404
+f 6639//4389 6654//4403 6655//4405
+f 6650//4424 6635//3282 6649//4406
+f 6645//4411 6630//4391 6644//4408
+f 6640//4392 6655//4405 6656//4409
+f 6635//3282 6650//4424 6651//4410
+f 6646//4415 6631//4393 6645//4411
+f 6641//4395 6656//4409 6657//4413
+f 6636//4396 6651//4410 6652//4414
+f 6647//4402 6632//4401 6646//4415
+f 6656//4409 6671//4427 6672//4416
+f 6651//4410 6666//4428 6667//4417
+f 6662//4420 6647//4402 6661//4418
+f 6652//4414 6667//4417 6668//4419
+f 6663//4422 6648//4404 6662//4420
+f 6653//4400 6668//4419 6669//4421
+f 6664//4425 6649//4406 6663//4422
+f 6654//4403 6669//4421 6670//4423
+f 6665//4432 6650//4424 6664//4425
+f 6660//4429 6645//4411 6659//4426
+f 6655//4405 6670//4423 6671//4427
+f 6650//4424 6665//4432 6666//4428
+f 6661//4418 6646//4415 6660//4429
+f 6675//4434 6660//4429 6674//4430
+f 6670//4423 6685//4442 6686//4431
+f 6665//4432 6680//4446 6681//4433
+f 6676//4437 6661//4418 6675//4434
+f 6671//4427 6686//4431 6687//4435
+f 6666//4428 6681//4433 6682//4436
+f 6677//4439 6662//4420 6676//4437
+f 6667//4417 6682//4436 6683//4438
+f 6678//4441 6663//4422 6677//4439
+f 6668//4419 6683//4438 6684//4440
+f 6679//4443 6664//4425 6678//4441
+f 6669//4421 6684//4440 6685//4442
+f 6680//4446 6665//4432 6679//4443
+f 6694//4447 6679//4443 6693//4444
+f 6684//4440 6699//4457 6700//4445
+f 6695//4463 6680//4446 6694//4447
+f 6690//4451 6675//4434 6689//4448
+f 6685//4442 6700//4445 6701//4449
+f 6680//4446 6695//4463 6696//4450
+f 6691//4454 6676//4437 6690//4451
+f 6686//4431 6701//4449 6702//4452
+f 6681//4433 6696//4450 6697//4453
+f 6692//4456 6677//4439 6691//4454
+f 6682//4436 6697//4453 6698//4455
+f 6693//4444 6678//4441 6692//4456
+f 6683//4438 6698//4455 6699//4457
+f 6697//4453 6712//4470 6713//4458
+f 6708//4461 6693//4444 6707//4459
+f 6698//4455 6713//4458 6714//4460
+f 6709//4464 6694//4447 6708//4461
+f 6699//4457 6714//4460 6715//4462
+f 6710//4480 6695//4463 6709//4464
+f 6705//4468 6690//4451 6704//4465
+f 6700//4445 6715//4462 6716//4466
+f 6695//4463 6710//4480 6711//4467
+f 6706//4471 6691//4454 6705//4468
+f 6701//4449 6716//4466 6717//4469
+f 6696//4450 6711//4467 6712//4470
+f 6707//4459 6692//4456 6706//4471
+f 6716//4466 6732//4483 6733//4472
+f 6711//4467 6727//4484 6728//4473
+f 6723//4476 6707//4459 6722//4474
+f 6712//4470 6728//4473 6729//4475
+f 6724//4478 6708//4461 6723//4476
+f 6713//4458 6729//4475 6730//4477
+f 6725//4481 6709//4464 6724//4478
+f 6714//4460 6730//4477 6731//4479
+f 6726//4488 6710//4480 6725//4481
+f 6721//4485 6705//4468 6720//4482
+f 6715//4462 6731//4479 6732//4483
+f 6710//4480 6726//4488 6727//4484
+f 6722//4474 6706//4471 6721//4485
+f 6736//4490 6721//4485 6735//4486
+f 6731//4479 6746//4498 6747//4487
+f 6726//4488 6741//4500 6742//4489
+f 6737//4493 6722//4474 6736//4490
+f 6732//4483 6747//4487 6748//4491
+f 6727//4484 6742//4489 6743//4492
+f 6738//4495 6723//4476 6737//4493
+f 6728//4473 6743//4492 6744//4494
+f 6739//4497 6724//4478 6738//4495
+f 6729//4475 6744//4494 6745//4496
+f 6740//4499 6725//4481 6739//4497
+f 6730//4477 6745//4496 6746//4498
+f 6741//4500 6726//4488 6740//4499
+f 6273//4076 6740//4499 6272//4072
+f 6745//4496 6278//4074 6279//4058
+f 6274//2918 6741//4500 6273//4076
+f 6269//4063 6736//4490 6268//4079
+f 6746//4498 6279//4058 6280//4057
+f 6741//4500 6274//2918 6275//4060
+f 6270//4062 6737//4493 6269//4063
+f 6747//4487 6280//4057 6281//4065
+f 6742//4489 6275//4060 6276//4067
+f 6271//4069 6738//4495 6270//4062
+f 6743//4492 6276//4067 6277//4070
+f 6272//4072 6739//4497 6271//4069
+f 6744//4494 6277//4070 6278//4074
+usemtl NoseTop
+f 6268//4079 6267//4501 6283//4093
+f 6283//4093 6282//4502 6298//4097
+f 6298//4097 6297//4503 6313//4115
+f 6313//4115 6312//4504 6328//4132
+f 6328//4132 6327//4505 6343//4150
+f 6343//4150 6342//4506 6358//4154
+f 6358//4154 6357//4507 6373//4169
+f 6373//4169 6372//4508 6388//4186
+f 6388//4186 6387//4509 6402//4510
+f 6403//4187 6402//4510 6417//4511
+f 6418//4206 6417//4511 6432//4512
+f 6433//4211 6432//4512 6447//4513
+f 6448//4227 6447//4513 6462//4514
+f 6463//4244 6462//4514 6477//4515
+f 6478//4262 6477//4515 6492//4516
+f 6493//4267 6492//4516 6507//4517
+f 6508//4283 6507//4517 6523//4314
+f 6523//4314 6522//4518 6538//4318
+f 6538//4318 6537//4519 6553//4336
+f 6553//4336 6552//4520 6568//4352
+f 6568//4352 6567//4521 6583//4371
+f 6583//4371 6582//4522 6599//4375
+f 6599//4375 6598//4523 6614//4390
+f 6614//4390 6613//4524 6629//4407
+f 6629//4407 6628//4525 6643//4526
+f 6644//4408 6643//4526 6658//4527
+f 6659//4426 6658//4527 6673//4528
+f 6674//4430 6673//4528 6688//4529
+f 6689//4448 6688//4529 6703//4530
+f 6704//4465 6703//4530 6719//4531
+f 6720//4482 6719//4531 6734//4532
+f 6267//4501 6718//4533 6282//4502
+f 6282//4502 6718//4533 6297//4503
+f 6297//4503 6718//4533 6312//4504
+f 6312//4504 6718//4533 6327//4505
+f 6327//4505 6718//4533 6342//4506
+f 6342//4506 6718//4533 6357//4507
+f 6357//4507 6718//4533 6372//4508
+f 6372//4508 6718//4533 6387//4509
+f 6387//4509 6718//4533 6402//4510
+f 6402//4510 6718//4533 6417//4511
+f 6417//4511 6718//4533 6432//4512
+f 6432//4512 6718//4533 6447//4513
+f 6447//4513 6718//4533 6462//4514
+f 6462//4514 6718//4533 6477//4515
+f 6477//4515 6718//4533 6492//4516
+f 6492//4516 6718//4533 6507//4517
+f 6507//4517 6718//4533 6522//4518
+f 6522//4518 6718//4533 6537//4519
+f 6537//4519 6718//4533 6552//4520
+f 6552//4520 6718//4533 6567//4521
+f 6567//4521 6718//4533 6582//4522
+f 6582//4522 6718//4533 6598//4523
+f 6598//4523 6718//4533 6613//4524
+f 6613//4524 6718//4533 6628//4525
+f 6628//4525 6718//4533 6643//4526
+f 6643//4526 6718//4533 6658//4527
+f 6658//4527 6718//4533 6673//4528
+f 6673//4528 6718//4533 6688//4529
+f 6688//4529 6718//4533 6703//4530
+f 6703//4530 6718//4533 6719//4531
+f 6719//4531 6718//4533 6734//4532
+f 6735//4486 6734//4532 6267//4501
+f 6734//4532 6718//4533 6267//4501
+f 6267//4501 6282//4502 6283//4093
+f 6282//4502 6297//4503 6298//4097
+f 6297//4503 6312//4504 6313//4115
+f 6312//4504 6327//4505 6328//4132
+f 6327//4505 6342//4506 6343//4150
+f 6342//4506 6357//4507 6358//4154
+f 6357//4507 6372//4508 6373//4169
+f 6372//4508 6387//4509 6388//4186
+f 6403//4187 6388//4186 6402//4510
+f 6418//4206 6403//4187 6417//4511
+f 6433//4211 6418//4206 6432//4512
+f 6448//4227 6433//4211 6447//4513
+f 6463//4244 6448//4227 6462//4514
+f 6478//4262 6463//4244 6477//4515
+f 6493//4267 6478//4262 6492//4516
+f 6508//4283 6493//4267 6507//4517
+f 6507//4517 6522//4518 6523//4314
+f 6522//4518 6537//4519 6538//4318
+f 6537//4519 6552//4520 6553//4336
+f 6552//4520 6567//4521 6568//4352
+f 6567//4521 6582//4522 6583//4371
+f 6582//4522 6598//4523 6599//4375
+f 6598//4523 6613//4524 6614//4390
+f 6613//4524 6628//4525 6629//4407
+f 6644//4408 6629//4407 6643//4526
+f 6659//4426 6644//4408 6658//4527
+f 6674//4430 6659//4426 6673//4528
+f 6689//4448 6674//4430 6688//4529
+f 6704//4465 6689//4448 6703//4530
+f 6720//4482 6704//4465 6719//4531
+f 6735//4486 6720//4482 6734//4532
+f 6268//4079 6735//4486 6267//4501
+o Eye_R_Sphere.006
+v -0.524476 0.974916 -0.429854
+v -0.531200 0.971113 -0.437667
+v -0.521508 0.974612 -0.432816
+v -0.529686 0.970959 -0.439177
+v -0.519084 0.973822 -0.436159
+v -0.528450 0.970556 -0.440881
+v -0.517299 0.972578 -0.439756
+v -0.527540 0.969921 -0.442715
+v -0.516221 0.970925 -0.443469
+v -0.526991 0.969079 -0.444608
+v -0.515891 0.968928 -0.447154
+v -0.526823 0.968061 -0.446487
+v -0.516322 0.966664 -0.450671
+v -0.527043 0.966907 -0.448279
+v -0.517498 0.964220 -0.453883
+v -0.527642 0.965661 -0.449917
+v -0.519374 0.961690 -0.456668
+v -0.528598 0.964371 -0.451337
+v -0.521876 0.959170 -0.458918
+v -0.529874 0.963086 -0.452484
+v -0.524910 0.956758 -0.460548
+v -0.531421 0.961856 -0.453314
+v -0.528358 0.954546 -0.461493
+v -0.533179 0.960729 -0.453797
+v -0.532089 0.952620 -0.461719
+v -0.535080 0.959747 -0.453912
+v -0.535957 0.951053 -0.461216
+v -0.537053 0.958948 -0.453655
+v -0.539816 0.949906 -0.460004
+v -0.539020 0.958363 -0.453038
+v -0.543517 0.949222 -0.458129
+v -0.540906 0.958015 -0.452082
+v -0.546917 0.949029 -0.455664
+v -0.542640 0.957916 -0.450825
+v -0.549886 0.949332 -0.452703
+v -0.544153 0.958071 -0.449315
+v -0.552309 0.950122 -0.449359
+v -0.545389 0.958474 -0.447611
+v -0.554094 0.951367 -0.445762
+v -0.546299 0.959108 -0.445777
+v -0.555173 0.953019 -0.442049
+v -0.546848 0.959951 -0.443884
+v -0.555502 0.955016 -0.438364
+v -0.547016 0.960968 -0.442005
+v -0.537332 0.965373 -0.444748
+v -0.555071 0.957280 -0.434848
+v -0.546796 0.962123 -0.440213
+v -0.553895 0.959724 -0.431635
+v -0.546197 0.963369 -0.438575
+v -0.552019 0.962255 -0.428850
+v -0.545241 0.964659 -0.437155
+v -0.549517 0.964774 -0.426600
+v -0.543965 0.965943 -0.436008
+v -0.546483 0.967187 -0.424971
+v -0.542418 0.967173 -0.435178
+v -0.543035 0.969398 -0.424025
+v -0.540661 0.968301 -0.434695
+v -0.539305 0.971325 -0.423799
+v -0.538759 0.969283 -0.434580
+v -0.535436 0.972891 -0.424302
+v -0.536787 0.970081 -0.434837
+v -0.531577 0.974039 -0.425514
+v -0.534819 0.970666 -0.435455
+v -0.527876 0.974722 -0.427389
+v -0.532933 0.971015 -0.436410
+v -0.527903 0.973309 -0.433843
+v -0.525649 0.973078 -0.436092
+v -0.522998 0.974809 -0.431345
+v -0.530446 0.971047 -0.438426
+v -0.523808 0.972479 -0.438630
+v -0.520299 0.974262 -0.434501
+v -0.529071 0.970768 -0.440034
+v -0.522453 0.971533 -0.441362
+v -0.527998 0.970250 -0.441803
+v -0.518193 0.973244 -0.437974
+v -0.521634 0.970279 -0.444180
+v -0.516760 0.971794 -0.441632
+v -0.527268 0.969511 -0.443667
+v -0.521384 0.968763 -0.446979
+v -0.516056 0.969968 -0.445334
+v -0.526909 0.968580 -0.445553
+v -0.521712 0.967044 -0.449649
+v -0.516107 0.967836 -0.448938
+v -0.526935 0.967494 -0.447389
+v -0.522605 0.965188 -0.452088
+v -0.527345 0.966294 -0.449105
+v -0.516911 0.965480 -0.452305
+v -0.524029 0.963266 -0.454202
+v -0.518438 0.962990 -0.455306
+v -0.528123 0.965025 -0.450634
+v -0.525929 0.961353 -0.455911
+v -0.520629 0.960463 -0.457826
+v -0.529239 0.963738 -0.451918
+v -0.528232 0.959522 -0.457148
+v -0.523399 0.957995 -0.459767
+v -0.530651 0.962480 -0.452907
+v -0.530850 0.957842 -0.457866
+v -0.532303 0.961302 -0.453563
+v -0.526643 0.955681 -0.461056
+v -0.533683 0.956380 -0.458038
+v -0.530235 0.953610 -0.461642
+v -0.534133 0.960247 -0.453862
+v -0.536620 0.955190 -0.457656
+v -0.534038 0.951862 -0.461504
+v -0.536071 0.959356 -0.453791
+v -0.539550 0.954319 -0.456735
+v -0.537905 0.950504 -0.460645
+v -0.538041 0.958664 -0.453354
+v -0.542360 0.953800 -0.455312
+v -0.541688 0.949588 -0.459101
+v -0.539968 0.958197 -0.452567
+v -0.544942 0.953653 -0.453440
+v -0.545241 0.949149 -0.456929
+v -0.541779 0.957974 -0.451461
+v -0.547196 0.953884 -0.451191
+v -0.548429 0.949204 -0.454213
+v -0.543402 0.958002 -0.450077
+v -0.549036 0.954483 -0.448653
+v -0.551127 0.949751 -0.451058
+v -0.544777 0.958281 -0.448469
+v -0.550391 0.955428 -0.445921
+v -0.553233 0.950769 -0.447585
+v -0.545850 0.958799 -0.446700
+v -0.551210 0.956683 -0.443102
+v -0.554666 0.952219 -0.443927
+v -0.546580 0.959538 -0.444836
+v -0.551460 0.958199 -0.440304
+v -0.542328 0.963416 -0.443519
+v -0.555370 0.954045 -0.440225
+v -0.546939 0.960468 -0.442950
+v -0.551133 0.959918 -0.437634
+v -0.555319 0.956177 -0.436621
+v -0.546913 0.961555 -0.441114
+v -0.550240 0.961774 -0.435195
+v -0.554515 0.958533 -0.433253
+v -0.546503 0.962755 -0.439398
+v -0.548816 0.963695 -0.433081
+v -0.545726 0.964023 -0.437869
+v -0.552988 0.961023 -0.430252
+v -0.546916 0.965609 -0.431372
+v -0.550797 0.963550 -0.427733
+v -0.544609 0.965311 -0.436586
+v -0.544612 0.967440 -0.430135
+v -0.548027 0.966018 -0.425791
+v -0.543198 0.966568 -0.435597
+v -0.541994 0.969119 -0.429417
+v -0.544783 0.968332 -0.424502
+v -0.541545 0.967747 -0.434940
+v -0.539162 0.970582 -0.429245
+v -0.539715 0.968802 -0.434641
+v -0.541191 0.970403 -0.423916
+v -0.536224 0.971772 -0.429627
+v -0.537388 0.972151 -0.424055
+v -0.537778 0.969693 -0.434712
+v -0.533294 0.972643 -0.430547
+v -0.533521 0.973509 -0.424913
+v -0.535807 0.970385 -0.435149
+v -0.530484 0.973162 -0.431971
+v -0.529738 0.974425 -0.426458
+v -0.533880 0.970852 -0.435936
+v -0.534371 0.968519 -0.441337
+v -0.533610 0.968441 -0.442096
+v -0.532988 0.968239 -0.442954
+v -0.532531 0.967919 -0.443876
+v -0.532254 0.967496 -0.444829
+v -0.532170 0.966984 -0.445774
+v -0.532280 0.966403 -0.446676
+v -0.532582 0.965776 -0.447499
+v -0.533063 0.965127 -0.448214
+v -0.533705 0.964481 -0.448791
+v -0.534483 0.963862 -0.449209
+v -0.535367 0.963295 -0.449451
+v -0.536324 0.962801 -0.449509
+v -0.537316 0.962399 -0.449380
+v -0.538306 0.962105 -0.449069
+v -0.539255 0.961930 -0.448588
+v -0.540127 0.961880 -0.447956
+v -0.540888 0.961958 -0.447197
+v -0.541509 0.962160 -0.446339
+v -0.541967 0.962480 -0.445417
+v -0.542244 0.962904 -0.444464
+v -0.542218 0.963996 -0.442618
+v -0.541916 0.964623 -0.441794
+v -0.541435 0.965272 -0.441079
+v -0.540793 0.965918 -0.440502
+v -0.540015 0.966537 -0.440085
+v -0.539131 0.967104 -0.439842
+v -0.538174 0.967598 -0.439784
+v -0.537182 0.968000 -0.439913
+v -0.536192 0.968294 -0.440224
+v -0.535243 0.968470 -0.440705
+v -0.532070 0.971075 -0.437043
+v -0.526185 0.974864 -0.428630
+v -0.526781 0.973219 -0.434975
+v -0.524733 0.972804 -0.437370
+v -0.523134 0.972031 -0.440006
+v -0.522047 0.970930 -0.442783
+v -0.521512 0.969544 -0.445593
+v -0.521551 0.967926 -0.448328
+v -0.522161 0.966138 -0.450884
+v -0.523320 0.964248 -0.453162
+v -0.524983 0.962330 -0.455074
+v -0.527086 0.960457 -0.456548
+v -0.529548 0.958700 -0.457526
+v -0.532274 0.957129 -0.457971
+v -0.535161 0.955802 -0.457866
+v -0.538096 0.954771 -0.457214
+v -0.540967 0.954075 -0.456042
+v -0.543664 0.953742 -0.454393
+v -0.546083 0.953784 -0.452332
+v -0.548132 0.954199 -0.449937
+v -0.549730 0.954972 -0.447301
+v -0.550818 0.956073 -0.444524
+v -0.551353 0.957459 -0.441714
+v -0.551314 0.959077 -0.438979
+v -0.550703 0.960865 -0.436423
+v -0.549544 0.962755 -0.434145
+v -0.547881 0.964673 -0.432233
+v -0.545779 0.966546 -0.430759
+v -0.543317 0.968303 -0.429781
+v -0.540590 0.969874 -0.429336
+v -0.537704 0.971201 -0.429441
+v -0.534768 0.972232 -0.430093
+v -0.531897 0.972928 -0.431265
+v -0.529200 0.973261 -0.432914
+v -0.278633 0.972176 -0.169592
+v -0.294496 0.987579 -0.191783
+v -0.315813 0.996242 -0.220002
+v -0.345297 1.010831 -0.259381
+v -0.379326 1.021626 -0.304026
+v -0.414714 1.021300 -0.348918
+v -0.450102 1.009866 -0.392330
+v -0.238105 0.964990 -0.207660
+v -0.256320 0.980810 -0.227642
+v -0.281455 0.990149 -0.252275
+v -0.316078 1.005650 -0.286827
+v -0.356369 1.017555 -0.325590
+v -0.398901 1.018496 -0.363771
+v -0.442040 1.008437 -0.399903
+v -0.205451 0.952861 -0.251590
+v -0.225560 0.969385 -0.269024
+v -0.253772 0.979867 -0.289517
+v -0.292535 0.996905 -0.318499
+v -0.337872 1.010685 -0.350475
+v -0.386160 1.013764 -0.380912
+v -0.435545 1.006024 -0.408641
+v -0.181925 0.936256 -0.299696
+v -0.203399 0.953743 -0.314338
+v -0.233828 0.965789 -0.330299
+v -0.275574 0.984934 -0.353181
+v -0.324545 1.001278 -0.377724
+v -0.376981 1.007284 -0.399682
+v -0.430865 1.002721 -0.418210
+v -0.168432 0.915812 -0.350127
+v -0.190689 0.934485 -0.361843
+v -0.222389 0.948458 -0.373053
+v -0.265846 0.970195 -0.389540
+v -0.316902 0.989698 -0.406291
+v -0.371716 0.999308 -0.419359
+v -0.428182 0.998655 -0.428241
+v -0.165490 0.892316 -0.400946
+v -0.187918 0.912352 -0.409714
+v -0.219895 0.928539 -0.416135
+v -0.263725 0.953255 -0.426178
+v -0.315236 0.976388 -0.435078
+v -0.370568 0.990140 -0.439188
+v -0.427596 0.993981 -0.438350
+v -0.173213 0.866670 -0.450200
+v -0.195192 0.888194 -0.456110
+v -0.226441 0.906797 -0.457890
+v -0.269293 0.934765 -0.461688
+v -0.319610 0.961861 -0.462978
+v -0.373581 0.980133 -0.458405
+v -0.429132 0.988880 -0.448147
+v -0.191302 0.839860 -0.495996
+v -0.212232 0.862940 -0.499249
+v -0.241777 0.884069 -0.496714
+v -0.282335 0.915436 -0.494706
+v -0.329857 0.946674 -0.488919
+v -0.380639 0.969673 -0.476274
+v -0.432731 0.983547 -0.457256
+v -0.219064 0.812916 -0.536574
+v -0.238383 0.837559 -0.537473
+v -0.265313 0.861227 -0.531115
+v -0.302350 0.896011 -0.523961
+v -0.345583 0.931412 -0.511905
+v -0.391472 0.959160 -0.492107
+v -0.438253 0.978187 -0.465328
+v -0.255432 0.786873 -0.570376
+v -0.272641 0.813028 -0.569313
+v -0.296143 0.839149 -0.559771
+v -0.328569 0.877235 -0.548330
+v -0.366183 0.916660 -0.531052
+v -0.405661 0.948999 -0.505296
+v -0.445487 0.973007 -0.472051
+v -0.299007 0.762734 -0.596101
+v -0.313688 0.790289 -0.593546
+v -0.333085 0.818684 -0.581579
+v -0.359985 0.859831 -0.566877
+v -0.390867 0.902986 -0.545624
+v -0.422664 0.939580 -0.515333
+v -0.454154 0.968206 -0.477168
+v -0.348115 0.741424 -0.612761
+v -0.359947 0.770215 -0.609240
+v -0.374717 0.800619 -0.595703
+v -0.395391 0.844468 -0.578889
+v -0.418684 0.890915 -0.555062
+v -0.441825 0.931265 -0.521834
+v -0.463923 0.963967 -0.480482
+v -0.400870 0.723763 -0.619717
+v -0.409640 0.753579 -0.615791
+v -0.419440 0.785647 -0.601600
+v -0.433424 0.831735 -0.583903
+v -0.448567 0.880911 -0.559002
+v -0.462409 0.924374 -0.524548
+v -0.474416 0.960454 -0.481866
+v -0.455243 0.710430 -0.616700
+v -0.460859 0.741020 -0.612950
+v -0.465535 0.774344 -0.599042
+v -0.472625 0.822123 -0.581728
+v -0.479367 0.873359 -0.557293
+v -0.483624 0.919172 -0.523371
+v -0.485232 0.957802 -0.481266
+v -0.509145 0.701937 -0.603827
+v -0.511634 0.733020 -0.600823
+v -0.511231 0.767144 -0.588129
+v -0.511487 0.816000 -0.572447
+v -0.509901 0.868548 -0.550001
+v -0.504656 0.915858 -0.518348
+v -0.495954 0.956113 -0.478705
+v -0.560505 0.698611 -0.581592
+v -0.560014 0.729886 -0.579879
+v -0.554772 0.764324 -0.569279
+v -0.548515 0.813601 -0.556417
+v -0.538994 0.866663 -0.537406
+v -0.524695 0.914560 -0.509672
+v -0.506170 0.955451 -0.474282
+v -0.607349 0.700579 -0.550850
+v -0.604140 0.731740 -0.550920
+v -0.594485 0.765992 -0.543217
+v -0.582288 0.815020 -0.534253
+v -0.565529 0.867778 -0.519992
+v -0.542973 0.915328 -0.497677
+v -0.515488 0.955842 -0.468167
+v -0.647877 0.707765 -0.512782
+v -0.642316 0.738510 -0.515061
+v -0.628843 0.772084 -0.510945
+v -0.611507 0.820201 -0.506808
+v -0.588486 0.871849 -0.498428
+v -0.558786 0.918132 -0.482824
+v -0.523804 0.953636 -0.459109
+v -0.680531 0.719894 -0.468852
+v -0.673076 0.749935 -0.473679
+v -0.656525 0.782367 -0.473702
+v -0.635049 0.828946 -0.475135
+v -0.606983 0.878720 -0.473543
+v -0.571527 0.922864 -0.465683
+v -0.531714 0.953934 -0.450611
+v -0.704057 0.736500 -0.420746
+v -0.695237 0.765577 -0.428365
+v -0.676470 0.796444 -0.432921
+v -0.652010 0.840918 -0.440454
+v -0.620309 0.888126 -0.446294
+v -0.580706 0.929344 -0.446913
+v -0.536923 0.956848 -0.440806
+v -0.717550 0.756943 -0.370315
+v -0.707947 0.784834 -0.380860
+v -0.687909 0.813776 -0.390167
+v -0.661738 0.855657 -0.404095
+v -0.627952 0.899706 -0.417727
+v -0.585971 0.937320 -0.427236
+v -0.539247 0.961473 -0.430560
+v -0.720492 0.780440 -0.319496
+v -0.710718 0.806967 -0.332990
+v -0.690402 0.833695 -0.347085
+v -0.663859 0.872597 -0.367456
+v -0.629619 0.913016 -0.388940
+v -0.587119 0.946488 -0.407407
+v -0.538122 0.967966 -0.420997
+v -0.484129 0.987764 -0.432596
+v -0.712770 0.806086 -0.270242
+v -0.703444 0.831125 -0.286594
+v -0.683856 0.855436 -0.305330
+v -0.658292 0.891086 -0.331946
+v -0.625244 0.927543 -0.361040
+v -0.584106 0.956495 -0.388189
+v -0.536457 0.976829 -0.412351
+v -0.694680 0.832896 -0.224446
+v -0.686404 0.856380 -0.243454
+v -0.668520 0.878165 -0.266505
+v -0.645250 0.910415 -0.298929
+v -0.614998 0.942730 -0.335099
+v -0.577048 0.966955 -0.370321
+v -0.532859 0.982162 -0.403242
+v -0.666918 0.859839 -0.183868
+v -0.660252 0.881760 -0.205230
+v -0.644985 0.901007 -0.232105
+v -0.625235 0.929841 -0.269673
+v -0.599272 0.957992 -0.312113
+v -0.566216 0.977468 -0.354488
+v -0.527337 0.987521 -0.395170
+v -0.630551 0.885882 -0.150066
+v -0.625995 0.906292 -0.173390
+v -0.614154 0.923084 -0.203449
+v -0.599015 0.948616 -0.245304
+v -0.578671 0.972744 -0.292966
+v -0.552026 0.987630 -0.341299
+v -0.520103 0.992701 -0.388447
+v -0.586976 0.910022 -0.124341
+v -0.584948 0.929031 -0.149158
+v -0.577213 0.943549 -0.181641
+v -0.567599 0.966020 -0.226757
+v -0.553988 0.986418 -0.278394
+v -0.535023 0.997048 -0.331262
+v -0.511435 0.997503 -0.383330
+v -0.537867 0.931331 -0.107681
+v -0.538689 0.949104 -0.133464
+v -0.535581 0.961614 -0.167517
+v -0.532194 0.981383 -0.214746
+v -0.526170 0.998489 -0.268956
+v -0.515862 1.005363 -0.324761
+v -0.501667 1.001742 -0.380015
+v -0.485113 0.948992 -0.100725
+v -0.488996 0.965740 -0.126912
+v -0.490858 0.976587 -0.161620
+v -0.494160 0.994116 -0.209731
+v -0.496287 1.008493 -0.265017
+v -0.495279 1.012254 -0.322047
+v -0.491173 1.005255 -0.378632
+v -0.430740 0.962325 -0.103742
+v -0.437777 0.978299 -0.129754
+v -0.444762 0.987890 -0.164178
+v -0.454959 1.003729 -0.211906
+v -0.465487 1.016046 -0.266725
+v -0.474063 1.017456 -0.323224
+v -0.480358 1.007907 -0.379232
+v -0.376837 0.970818 -0.116615
+v -0.387002 0.986300 -0.141880
+v -0.399066 0.995090 -0.175091
+v -0.416098 1.009852 -0.221187
+v -0.434954 1.020856 -0.274017
+v -0.453032 1.020770 -0.328247
+v -0.469636 1.009596 -0.381793
+v -0.325477 0.974144 -0.138850
+v -0.338622 0.989433 -0.162825
+v -0.355525 0.997910 -0.193941
+v -0.379070 1.012250 -0.237218
+v -0.405861 1.022741 -0.286613
+v -0.432992 1.022068 -0.336923
+v -0.459420 1.010258 -0.386215
+v -0.415446 0.857282 -0.444361
+v -0.417073 0.866694 -0.445501
+v -0.432496 1.017174 -0.370947
+v -0.420489 1.015045 -0.382225
+v -0.406800 1.020138 -0.356382
+v -0.446078 1.009213 -0.396135
+v -0.410815 1.011451 -0.395240
+v -0.392511 1.016366 -0.372392
+v -0.438798 1.007291 -0.404292
+v -0.403845 1.006532 -0.409491
+v -0.433209 1.004433 -0.413448
+v -0.381542 1.010756 -0.390363
+v -0.399848 1.000475 -0.424432
+v -0.374314 1.003522 -0.409602
+v -0.429526 1.000747 -0.423250
+v -0.398976 0.993514 -0.439488
+v -0.371104 0.994942 -0.429372
+v -0.427891 0.996376 -0.433322
+v -0.401264 0.985916 -0.454079
+v -0.372038 0.985347 -0.448912
+v -0.428367 0.991487 -0.443278
+v -0.406623 0.977974 -0.467647
+v -0.430935 0.986269 -0.452733
+v -0.377078 0.975105 -0.467471
+v -0.414848 0.969991 -0.479669
+v -0.386031 0.964609 -0.484336
+v -0.435496 0.980922 -0.461325
+v -0.425622 0.962276 -0.489683
+v -0.398552 0.954263 -0.498859
+v -0.441876 0.975651 -0.468725
+v -0.438531 0.955124 -0.497304
+v -0.414161 0.944465 -0.510482
+v -0.449828 0.970659 -0.474646
+v -0.453080 0.948811 -0.502240
+v -0.459048 0.966137 -0.478863
+v -0.432258 0.935591 -0.518758
+v -0.468709 0.943579 -0.504300
+v -0.452147 0.927981 -0.523369
+v -0.469181 0.962261 -0.481212
+v -0.484818 0.939629 -0.503407
+v -0.473065 0.921930 -0.524138
+v -0.479838 0.959177 -0.481604
+v -0.500787 0.937113 -0.499593
+v -0.494206 0.917668 -0.521035
+v -0.490609 0.957006 -0.480023
+v -0.516003 0.936127 -0.493006
+v -0.514759 0.915360 -0.514180
+v -0.501081 0.955831 -0.476531
+v -0.529881 0.936710 -0.483898
+v -0.533934 0.915095 -0.503836
+v -0.510850 0.955695 -0.471260
+v -0.540733 0.936655 -0.470678
+v -0.550994 0.916883 -0.490401
+v -0.517062 0.957178 -0.461155
+v -0.550829 0.939020 -0.457830
+v -0.565283 0.920654 -0.474390
+v -0.526043 0.955162 -0.453987
+v -0.557939 0.943609 -0.443723
+v -0.576252 0.926265 -0.456420
+v -0.532387 0.956737 -0.445250
+v -0.561669 0.949869 -0.428975
+v -0.583480 0.933499 -0.437180
+v -0.536014 0.960367 -0.435597
+v -0.561843 0.957783 -0.414486
+v -0.520832 0.975010 -0.425454
+v -0.586689 0.942078 -0.417410
+v -0.536532 0.965659 -0.426069
+v -0.561113 0.967968 -0.400765
+v -0.585756 0.951673 -0.397871
+v -0.533283 0.973412 -0.417979
+v -0.555753 0.975910 -0.387198
+v -0.580716 0.961916 -0.379312
+v -0.534685 0.979550 -0.407818
+v -0.547529 0.983893 -0.375176
+v -0.530123 0.984897 -0.399225
+v -0.571763 0.972411 -0.362447
+v -0.536754 0.991608 -0.365162
+v -0.559242 0.982757 -0.347924
+v -0.523744 0.990168 -0.391826
+v -0.523845 0.998760 -0.357541
+v -0.543633 0.992555 -0.336301
+v -0.515791 0.995160 -0.385904
+v -0.509296 1.005073 -0.352605
+v -0.525536 1.001430 -0.328025
+v -0.506571 0.999681 -0.381688
+v -0.493667 1.010305 -0.350544
+v -0.496438 1.003558 -0.379339
+v -0.505646 1.009039 -0.323414
+v -0.477559 1.014255 -0.351438
+v -0.484729 1.015090 -0.322645
+v -0.485781 1.006641 -0.378947
+v -0.461589 1.016771 -0.355252
+v -0.463588 1.019352 -0.325747
+v -0.475010 1.008812 -0.380527
+v -0.446374 1.017757 -0.361839
+v -0.443035 1.021660 -0.332602
+v -0.464539 1.009988 -0.384020
+v -0.467412 1.000360 -0.413046
+v -0.463357 0.999641 -0.416855
+v -0.460089 0.998427 -0.421251
+v -0.457735 0.996765 -0.426065
+v -0.456385 0.994720 -0.431111
+v -0.456091 0.992368 -0.436197
+v -0.456863 0.989802 -0.441125
+v -0.458674 0.987119 -0.445708
+v -0.461452 0.984423 -0.449768
+v -0.465091 0.981817 -0.453151
+v -0.469451 0.979402 -0.455725
+v -0.474365 0.977269 -0.457392
+v -0.479644 0.975502 -0.458088
+v -0.485085 0.974168 -0.457786
+v -0.490479 0.973318 -0.456498
+v -0.495618 0.972985 -0.454273
+v -0.500306 0.973182 -0.451197
+v -0.511379 0.965548 -0.450617
+v -0.517597 0.964818 -0.445377
+v -0.521351 0.966678 -0.438652
+v -0.522773 0.969998 -0.431599
+v -0.510855 0.983740 -0.423117
+v -0.509045 0.986422 -0.418535
+v -0.506266 0.989119 -0.414474
+v -0.502627 0.991724 -0.411092
+v -0.498267 0.994140 -0.408518
+v -0.493353 0.996272 -0.406851
+v -0.488074 0.998040 -0.406155
+v -0.482633 0.999374 -0.406457
+v -0.477239 1.000224 -0.407745
+v -0.472100 1.000557 -0.409970
+v -0.454769 1.010123 -0.389290
+v -0.423860 1.021925 -0.342946
+v -0.426497 1.016246 -0.376617
+v -0.415652 1.013384 -0.388769
+v -0.407326 1.009125 -0.402409
+v -0.401839 1.003634 -0.417013
+v -0.399404 0.997122 -0.432018
+v -0.400112 0.989839 -0.446849
+v -0.403937 0.982065 -0.460936
+v -0.410733 0.974099 -0.473737
+v -0.420237 0.966246 -0.484760
+v -0.432085 0.958809 -0.493582
+v -0.445820 0.952073 -0.499864
+v -0.460917 0.946298 -0.503364
+v -0.476793 0.941704 -0.503947
+v -0.492840 0.938470 -0.501592
+v -0.508440 0.936718 -0.496389
+v -0.522994 0.936517 -0.488538
+v -0.534619 0.936980 -0.476557
+v -0.545722 0.937873 -0.464221
+v -0.554352 0.941408 -0.450806
+v -0.559776 0.946836 -0.436369
+v -0.561683 0.953847 -0.421735
+v -0.560447 0.962830 -0.407806
+v -0.558503 0.972054 -0.394021
+v -0.551708 0.980021 -0.381220
+v -0.542203 0.987873 -0.370197
+v -0.530356 0.995311 -0.361375
+v -0.516620 1.002046 -0.355094
+v -0.501524 1.007822 -0.351594
+v -0.485647 1.012415 -0.351010
+v -0.469600 1.015650 -0.353365
+v -0.454000 1.017401 -0.358568
+v -0.439446 1.017603 -0.366419
+vn 0.210974 0.967528 0.139164
+vn 0.223701 0.962066 0.156041
+vn 0.306406 0.950591 0.049532
+vn 0.124363 0.991882 0.025971
+vn 0.203894 0.977783 -0.048402
+vn 0.022462 0.994324 -0.103732
+vn 0.291482 0.924070 0.247169
+vn 0.361278 0.866878 0.343425
+vn 0.400739 0.904691 0.144536
+vn 0.321390 0.944731 0.064272
+vn 0.400098 0.915494 -0.041566
+vn 0.383282 0.922025 -0.053865
+vn 0.081088 0.983428 -0.162053
+vn 0.267800 0.954039 -0.134404
+vn 0.481491 0.845576 0.230537
+vn 0.488784 0.871975 0.026124
+vn 0.552202 0.827204 -0.103549
+vn 0.438704 0.882931 -0.167150
+vn 0.313883 0.921506 -0.228614
+vn 0.128025 0.965697 -0.225837
+vn 0.578326 0.809595 0.100253
+vn 0.648091 0.760338 -0.042390
+vn 0.688131 0.699728 -0.191961
+vn 0.456801 0.875484 -0.157537
+vn 0.489334 0.826197 -0.279092
+vn 0.470473 0.834803 -0.285897
+vn 0.161718 0.941496 -0.295572
+vn 0.340281 0.881497 -0.327342
+vn 0.180883 0.911802 -0.368603
+vn 0.346233 0.835414 -0.426771
+vn 0.588580 0.772088 -0.239509
+vn 0.696829 0.630024 -0.342662
+vn 0.496445 0.769555 -0.401593
+vn 0.477401 0.779473 -0.405560
+vn 0.459212 0.719077 -0.521531
+vn 0.330699 0.785363 -0.523240
+vn 0.175787 0.840907 -0.511795
+vn 0.596515 0.708762 -0.376537
+vn 0.575701 0.639607 -0.509323
+vn 0.477828 0.707724 -0.520341
+vn 0.526933 0.567339 -0.632801
+vn 0.416608 0.655934 -0.629383
+vn 0.295480 0.732780 -0.612934
+vn 0.673940 0.553972 -0.488754
+vn 0.620289 0.474471 -0.624561
+vn 0.452101 0.494675 -0.742180
+vn 0.434217 0.643117 -0.630726
+vn 0.367290 0.578173 -0.728538
+vn 0.351238 0.592517 -0.724937
+vn 0.146641 0.801691 -0.579424
+vn 0.241310 0.679922 -0.692404
+vn 0.169958 0.629078 -0.758507
+vn 0.056154 0.726920 -0.684378
+vn 0.537950 0.394574 -0.744896
+vn 0.430097 0.317331 -0.845149
+vn 0.279611 0.515397 -0.810022
+vn 0.265603 0.531175 -0.804529
+vn 0.174596 0.457198 -0.872036
+vn 0.084658 0.581805 -0.808893
+vn -0.006653 0.691916 -0.721915
+vn 0.354045 0.424482 -0.833338
+vn 0.300882 0.245735 -0.921445
+vn 0.236549 0.359386 -0.902676
+vn 0.104160 0.301950 -0.947600
+vn 0.162999 0.474349 -0.865078
+vn 0.047365 0.424177 -0.904324
+vn -0.011475 0.540086 -0.841517
+vn -0.077548 0.660939 -0.746391
+vn 0.155217 0.182531 -0.970855
+vn -0.038057 0.254341 -0.966338
+vn 0.056215 0.405835 -0.912198
+vn -0.070925 0.363262 -0.928953
+vn -0.076815 0.382580 -0.920713
+vn -0.114841 0.505661 -0.855037
+vn -0.155278 0.633076 -0.758324
+vn -0.221229 0.479171 -0.849361
+vn -0.001190 0.130161 -0.991485
+vn -0.162450 0.090609 -0.982513
+vn -0.202002 0.331126 -0.921690
+vn -0.204871 0.351177 -0.913602
+vn -0.326762 0.462752 -0.824030
+vn -0.310526 0.603320 -0.734519
+vn -0.184637 0.218390 -0.958220
+vn -0.329966 0.195471 -0.923521
+vn -0.331919 0.310648 -0.890652
+vn -0.331767 0.331187 -0.883297
+vn -0.455733 0.302622 -0.837062
+vn -0.452712 0.323344 -0.830927
+vn -0.427290 0.456435 -0.780389
+vn -0.387432 0.596515 -0.702872
+vn -0.322306 0.065432 -0.944365
+vn -0.468429 0.186529 -0.863552
+vn -0.474624 0.055574 -0.878414
+vn -0.594714 0.191809 -0.780694
+vn -0.568651 0.307352 -0.762963
+vn -0.563005 0.327982 -0.758538
+vn -0.519089 0.460097 -0.720267
+vn -0.457930 0.613758 -0.643086
+vn -0.598437 0.474166 -0.645741
+vn -0.613544 0.061403 -0.787225
+vn -0.733757 0.082705 -0.674337
+vn -0.704001 0.211188 -0.678060
+vn -0.658437 0.344920 -0.668905
+vn -0.662465 0.497726 -0.559771
+vn -0.491714 0.649556 -0.579852
+vn -0.792016 0.243904 -0.559618
+vn -0.666341 0.324686 -0.671194
+vn -0.745079 0.353923 -0.565294
+vn -0.735343 0.373455 -0.565447
+vn -0.855464 0.288675 -0.429914
+vn -0.801782 0.393963 -0.449324
+vn -0.708274 0.530595 -0.465590
+vn -0.547624 0.694357 -0.466811
+vn -0.830592 0.118686 -0.544053
+vn -0.900357 0.167943 -0.401379
+vn -0.891842 0.343791 -0.293954
+vn -0.790735 0.412580 -0.452193
+vn -0.822504 0.460707 -0.333445
+vn -0.734977 0.570269 -0.366771
+vn -0.740440 0.616596 -0.267403
+vn -0.581835 0.737846 -0.342082
+vn -0.940367 0.228553 -0.251839
+vn -0.899777 0.407117 -0.156926
+vn -0.834315 0.443251 -0.327769
+vn -0.841395 0.499863 -0.205267
+vn -0.829432 0.516037 -0.213782
+vn -0.725455 0.666677 -0.170843
+vn -0.949095 0.298257 -0.101108
+vn -0.926206 0.374310 0.044923
+vn -0.878933 0.476272 -0.024140
+vn -0.822779 0.561693 -0.086550
+vn -0.811243 0.576434 -0.097812
+vn -0.779168 0.626331 0.023835
+vn -0.690023 0.719169 -0.081179
+vn -0.597766 0.756615 -0.264870
+vn -0.872555 0.453810 0.180761
+vn -0.830164 0.548540 0.099307
+vn -0.790216 0.533708 0.301096
+vn -0.755333 0.621204 0.208686
+vn -0.768670 0.639546 0.010010
+vn -0.712241 0.691275 0.121647
+vn -0.635823 0.771813 -0.001617
+vn -0.580157 0.793603 -0.183233
+vn -0.564531 0.822871 0.064364
+vn -0.489669 0.868374 -0.078310
+vn -0.682363 0.610950 0.401349
+vn -0.624592 0.754051 0.203131
+vn -0.703299 0.702994 0.105564
+vn -0.617664 0.764306 0.185156
+vn -0.479110 0.870235 0.114536
+vn -0.425916 0.903958 -0.037935
+vn -0.657277 0.691397 0.299814
+vn -0.553117 0.682546 0.477615
+vn -0.519547 0.812250 0.265114
+vn -0.515030 0.821162 0.245735
+vn -0.401166 0.863613 0.305277
+vn -0.382977 0.911893 0.147374
+vn -0.539781 0.756493 0.369182
+vn -0.407483 0.745750 0.527055
+vn -0.407392 0.813929 0.414106
+vn -0.251045 0.798120 0.547655
+vn -0.273995 0.906186 0.322062
+vn -0.399426 0.871334 0.284951
+vn -0.275185 0.912931 0.301340
+vn -0.352153 0.935789 -0.015412
+vn -0.279733 0.946440 0.161199
+vn -0.173315 0.972564 0.155065
+vn -0.201025 0.979522 -0.009857
+vn -0.265175 0.861568 0.432844
+vn -0.089785 0.837672 0.538713
+vn -0.142918 0.938322 0.314798
+vn -0.147160 0.944304 0.294229
+vn -0.067812 0.989227 0.129643
+vn -0.120304 0.992370 -0.026673
+vn -0.118564 0.897488 0.424726
+vn 0.070040 0.862850 0.500534
+vn -0.013001 0.958800 0.283761
+vn -0.020234 0.964324 0.263924
+vn 0.110782 0.966796 0.230171
+vn 0.032899 0.995697 0.086520
+vn 0.026734 0.920408 0.389996
+vn 0.222358 0.872707 0.434584
+vn 0.165197 0.929380 0.330058
+vn 0.100681 0.972137 0.211554
+vn 0.048250 0.989959 -0.132664
+vn 0.101382 0.976196 -0.191687
+vn 0.142277 0.955596 -0.258034
+vn 0.169347 0.928953 -0.329112
+vn 0.181585 0.897305 -0.402234
+vn 0.182653 0.879025 -0.440382
+vn 0.177984 0.860134 -0.477950
+vn 0.160222 0.824030 -0.543352
+vn 0.127415 0.785211 -0.605914
+vn 0.105502 0.764672 -0.635701
+vn 0.078921 0.745140 -0.662191
+vn 0.020936 0.708975 -0.704917
+vn -0.046175 0.676229 -0.735221
+vn -0.119877 0.648213 -0.751946
+vn -0.193609 0.626881 -0.754662
+vn -0.234596 0.617054 -0.751091
+vn -0.275491 0.610370 -0.742637
+vn -0.351451 0.602008 -0.716941
+vn -0.419050 0.601062 -0.680502
+vn -0.463057 0.637104 -0.616138
+vn -0.495712 0.667684 -0.555345
+vn -0.517838 0.675344 -0.525040
+vn -0.528306 0.690207 -0.494400
+vn -0.549638 0.711570 -0.437605
+vn -0.562700 0.720267 -0.405621
+vn -0.564898 0.736930 -0.371197
+vn -0.582324 0.754143 -0.303507
+vn -0.594317 0.773431 -0.220344
+vn -0.561510 0.812250 -0.157781
+vn -0.539445 0.832240 -0.127750
+vn -0.513016 0.852321 -0.101535
+vn -0.455031 0.888516 -0.058809
+vn -0.391247 0.919797 -0.029633
+vn -0.317789 0.948057 -0.012238
+vn -0.277627 0.960631 -0.007996
+vn -0.236763 0.971496 -0.009247
+vn -0.158574 0.987091 -0.021088
+vn -0.086123 0.995239 -0.045228
+vn -0.047731 0.996857 -0.062899
+vn -0.011841 0.996277 -0.085299
+vn -0.194830 0.936521 -0.291391
+vn -0.156560 0.954192 -0.254860
+vn -0.133274 0.951018 -0.278878
+vn -0.158269 0.929136 -0.334117
+vn -0.113315 0.945433 -0.305368
+vn -0.094485 0.938383 -0.332347
+vn -0.129734 0.915311 -0.381207
+vn -0.079562 0.929136 -0.361034
+vn -0.065950 0.918455 -0.389904
+vn -0.110324 0.895688 -0.430738
+vn -0.056612 0.905881 -0.419691
+vn -0.048708 0.892026 -0.449293
+vn -0.100772 0.870937 -0.480880
+vn -0.045320 0.876614 -0.478988
+vn -0.043428 0.860103 -0.508225
+vn -0.101474 0.842067 -0.529679
+vn -0.046144 0.842463 -0.536729
+vn -0.050325 0.823908 -0.564470
+vn -0.112369 0.810175 -0.575304
+vn -0.059023 0.804712 -0.590686
+vn -0.069155 0.784814 -0.615833
+vn -0.133061 0.776452 -0.615925
+vn -0.083499 0.764824 -0.638783
+vn -0.099124 0.744346 -0.660390
+vn -0.162725 0.742210 -0.650075
+vn -0.118595 0.724326 -0.679159
+vn -0.139164 0.704031 -0.696371
+vn -0.200262 0.708792 -0.676382
+vn -0.162969 0.684774 -0.710257
+vn -0.187689 0.665456 -0.722434
+vn -0.244209 0.677450 -0.693838
+vn -0.214972 0.647725 -0.730888
+vn -0.242836 0.630085 -0.737541
+vn -0.292825 0.649373 -0.701773
+vn -0.272530 0.614551 -0.740287
+vn -0.302469 0.599292 -0.741172
+vn -0.344371 0.625690 -0.699911
+vn -0.333445 0.586535 -0.738060
+vn -0.364360 0.574236 -0.733116
+vn -0.396741 0.607318 -0.688253
+vn -0.395428 0.564776 -0.724326
+vn -0.426069 0.555864 -0.713736
+vn -0.447981 0.594897 -0.667348
+vn -0.456008 0.550066 -0.699576
+vn -0.485275 0.544939 -0.683737
+vn -0.496109 0.588946 -0.637928
+vn -0.512986 0.543046 -0.664754
+vn -0.539628 0.541856 -0.644307
+vn -0.539293 0.589709 -0.601123
+vn -0.564043 0.543931 -0.621235
+vn -0.587146 0.546709 -0.596942
+vn -0.575823 0.597125 -0.558397
+vn -0.607288 0.552690 -0.570696
+vn -0.625904 0.559313 -0.543474
+vn -0.604358 0.610920 -0.511338
+vn -0.641011 0.568987 -0.515061
+vn -0.654439 0.579241 -0.485977
+vn -0.623768 0.630543 -0.461806
+vn -0.663991 0.592242 -0.456435
+vn -0.671682 0.605670 -0.426557
+vn -0.633320 0.655263 -0.411664
+vn -0.675283 0.621509 -0.397107
+vn -0.676962 0.637593 -0.367595
+vn -0.632618 0.684164 -0.362835
+vn -0.674459 0.655660 -0.339366
+vn -0.670064 0.673788 -0.311411
+vn -0.621723 0.716086 -0.317240
+vn -0.661580 0.693411 -0.285409
+vn -0.651234 0.712912 -0.259987
+vn -0.601062 0.749779 -0.276620
+vn -0.637104 0.733299 -0.237312
+vn -0.621265 0.753349 -0.215491
+vn -0.571368 0.784020 -0.242439
+vn -0.602008 0.773797 -0.196966
+vn -0.581225 0.793664 -0.179510
+vn -0.533860 0.817469 -0.216132
+vn -0.557604 0.813349 -0.165868
+vn -0.532701 0.832240 -0.153417
+vn -0.489914 0.848781 -0.198706
+vn -0.505631 0.850429 -0.145177
+vn -0.477523 0.867641 -0.138279
+vn -0.441237 0.876858 -0.190741
+vn -0.448073 0.883602 -0.135807
+vn -0.417890 0.898434 -0.134709
+vn -0.389752 0.900510 -0.192633
+vn -0.387127 0.911618 -0.138035
+vn -0.356029 0.923490 -0.142735
+vn -0.337352 0.918943 -0.204260
+vn -0.325175 0.933378 -0.151769
+vn -0.294290 0.941832 -0.162114
+vn -0.286111 0.931333 -0.225196
+vn -0.264534 0.948057 -0.176519
+vn -0.235115 0.952757 -0.192083
+vn -0.383465 0.797235 -0.466201
+vn -0.328898 0.853908 -0.403272
+vn -0.314951 0.852504 -0.417158
+vn -0.303568 0.848781 -0.432844
+vn -0.295206 0.842921 -0.449751
+vn -0.290139 0.835170 -0.467208
+vn -0.288583 0.825800 -0.484451
+vn -0.290628 0.815210 -0.500931
+vn -0.296152 0.803735 -0.515976
+vn -0.304941 0.791864 -0.529069
+vn -0.316660 0.780023 -0.539659
+vn -0.330912 0.768731 -0.547258
+vn -0.347118 0.758324 -0.551744
+vn -0.364574 0.749290 -0.552812
+vn -0.382702 0.741966 -0.550432
+vn -0.400830 0.736564 -0.544755
+vn -0.418165 0.733360 -0.535966
+vn -0.434126 0.732444 -0.524400
+vn -0.448073 0.733909 -0.510453
+vn -0.459426 0.737571 -0.494827
+vn -0.467818 0.743431 -0.477950
+vn -0.472884 0.751183 -0.460524
+vn -0.474410 0.760521 -0.443251
+vn -0.472396 0.771172 -0.426710
+vn -0.466872 0.782617 -0.411664
+vn -0.458083 0.794488 -0.398602
+vn -0.446364 0.806299 -0.388043
+vn -0.432112 0.817621 -0.380413
+vn -0.415937 0.828028 -0.375958
+vn -0.398450 0.837062 -0.374889
+vn -0.380291 0.844386 -0.377270
+vn -0.362163 0.849788 -0.382946
+vn -0.344859 0.852962 -0.391766
+vn -0.238014 0.937284 -0.254616
+vn -0.207617 0.955077 -0.211310
+vn -0.180731 0.955870 -0.231513
+vn -0.259590 0.899075 -0.352489
+vn -0.172674 0.934965 -0.309793
+vn -0.271981 0.901151 -0.337535
+vn -0.213233 0.939116 -0.269326
+vn -0.234840 0.894070 -0.381420
+vn -0.139531 0.924161 -0.355510
+vn -0.244514 0.898312 -0.364971
+vn -0.215583 0.884732 -0.413160
+vn -0.115146 0.907163 -0.404675
+vn -0.222114 0.891018 -0.395856
+vn -0.202429 0.871456 -0.446669
+vn -0.100406 0.884548 -0.455458
+vn -0.205603 0.879513 -0.429121
+vn -0.196020 0.854762 -0.480544
+vn -0.095889 0.857295 -0.505783
+vn -0.195624 0.864193 -0.463515
+vn -0.196448 0.835170 -0.513627
+vn -0.101779 0.826319 -0.553880
+vn -0.192572 0.845759 -0.497574
+vn -0.203833 0.813623 -0.544450
+vn -0.117862 0.792932 -0.597736
+vn -0.196570 0.824793 -0.530137
+vn -0.217811 0.790857 -0.571886
+vn -0.143498 0.758354 -0.635823
+vn -0.207465 0.802149 -0.559862
+vn -0.237861 0.767693 -0.595019
+vn -0.177709 0.723899 -0.666585
+vn -0.224799 0.778771 -0.585620
+vn -0.263253 0.745048 -0.612812
+vn -0.219184 0.690939 -0.688864
+vn -0.247963 0.755455 -0.606433
+vn -0.292947 0.723869 -0.624622
+vn -0.266274 0.660665 -0.701834
+vn -0.276040 0.733116 -0.621540
+vn -0.325877 0.704947 -0.629933
+vn -0.317301 0.634358 -0.704886
+vn -0.307932 0.712668 -0.630268
+vn -0.360698 0.688894 -0.628712
+vn -0.370159 0.612934 -0.698019
+vn -0.342448 0.694845 -0.632344
+vn -0.396130 0.676443 -0.620838
+vn -0.422926 0.597278 -0.681448
+vn -0.378246 0.680319 -0.627735
+vn -0.430769 0.668050 -0.606708
+vn -0.473525 0.587909 -0.655812
+vn -0.413953 0.669698 -0.616504
+vn -0.463332 0.664052 -0.586779
+vn -0.519974 0.585284 -0.622120
+vn -0.448195 0.663411 -0.599139
+vn -0.492508 0.664541 -0.561937
+vn -0.560564 0.589435 -0.581622
+vn -0.479659 0.661580 -0.576342
+vn -0.517228 0.669576 -0.533006
+vn -0.593677 0.600238 -0.535905
+vn -0.507096 0.664418 -0.548936
+vn -0.536515 0.678854 -0.501236
+vn -0.618061 0.617237 -0.486770
+vn -0.529557 0.671712 -0.518021
+vn -0.549669 0.692190 -0.467635
+vn -0.632832 0.639821 -0.436018
+vn -0.546068 0.683218 -0.484725
+vn -0.556078 0.708884 -0.433821
+vn -0.637318 0.667135 -0.385632
+vn -0.556047 0.698538 -0.450331
+vn -0.555620 0.728416 -0.400800
+vn -0.631428 0.698050 -0.337565
+vn -0.559099 0.717002 -0.416272
+vn -0.548265 0.749992 -0.369945
+vn -0.615345 0.731468 -0.293710
+vn -0.555101 0.737938 -0.383709
+vn -0.534288 0.772820 -0.342418
+vn -0.589709 0.766076 -0.255593
+vn -0.544206 0.760552 -0.354015
+vn -0.514206 0.795953 -0.319376
+vn -0.555528 0.800501 -0.224830
+vn -0.526841 0.783990 -0.328227
+vn -0.488815 0.818567 -0.301614
+vn -0.514054 0.833461 -0.202612
+vn -0.503708 0.807276 -0.307443
+vn -0.459120 0.839747 -0.289773
+vn -0.466933 0.863704 -0.189642
+vn -0.475631 0.829615 -0.292337
+vn -0.426221 0.858730 -0.284402
+vn -0.415937 0.890011 -0.186560
+vn -0.443709 0.850093 -0.283578
+vn -0.391369 0.874722 -0.285714
+vn -0.363018 0.911466 -0.193426
+vn -0.409223 0.867916 -0.281503
+vn -0.355998 0.887173 -0.293558
+vn -0.310312 0.927122 -0.209998
+vn -0.373424 0.882382 -0.286172
+vn -0.321329 0.895566 -0.307657
+vn -0.259713 0.936460 -0.235664
+vn -0.337718 0.893002 -0.297372
+vn -0.303446 0.899350 -0.314707
+vn -0.288736 0.899594 -0.327616
+vn -0.040223 0.973144 -0.226539
+vn -0.003021 0.963347 -0.268227
+vn 0.025513 0.948729 -0.315012
+vn 0.044313 0.929899 -0.365093
+vn 0.052675 0.907559 -0.416547
+vn 0.050233 0.882595 -0.467422
+vn 0.037141 0.855922 -0.515732
+vn 0.013825 0.828578 -0.559648
+vn -0.018738 0.801660 -0.597461
+vn -0.059389 0.776147 -0.627705
+vn -0.106479 0.753044 -0.649251
+vn -0.158269 0.733238 -0.661245
+vn -0.212714 0.717490 -0.663259
+vn -0.267769 0.706381 -0.655171
+vn -0.321268 0.700400 -0.637349
+vn -0.371197 0.699698 -0.610401
+vn -0.511979 0.737114 -0.441054
+vn -0.426923 0.764824 -0.482437
+vn -0.423017 0.776543 -0.466933
+vn -0.432417 0.785943 -0.441908
+vn -0.447127 0.785028 -0.428663
+vn -0.495315 0.720420 -0.485397
+vn -0.492965 0.821589 -0.286233
+vn -0.469680 0.848903 -0.242317
+vn -0.437086 0.875851 -0.204505
+vn -0.396435 0.901334 -0.174261
+vn -0.349315 0.924467 -0.152715
+vn -0.297555 0.944243 -0.140721
+vn -0.243080 0.960021 -0.138707
+vn -0.188055 0.971099 -0.146794
+vn -0.134556 0.977111 -0.164617
+vn -0.268075 0.864223 -0.425642
+vn -0.179052 0.919553 -0.349712
+vn -0.164800 0.917020 -0.363109
+vn -0.153325 0.912778 -0.378552
+vn -0.145054 0.906919 -0.395489
+vn -0.140294 0.899747 -0.413221
+vn -0.139256 0.891476 -0.431104
+vn -0.141972 0.882443 -0.448439
+vn -0.148350 0.873012 -0.464553
+vn -0.158116 0.863521 -0.478805
+vn -0.170904 0.854366 -0.490707
+vn -0.186224 0.845882 -0.499771
+vn -0.203497 0.838374 -0.505631
+vn -0.222053 0.832179 -0.508072
+vn -0.241188 0.827479 -0.507004
+vn -0.260170 0.824488 -0.502487
+vn -0.278237 0.823328 -0.494644
+vn -0.435316 0.832057 -0.343669
+vn -0.492935 0.797113 -0.348735
+vn -0.424390 0.795648 -0.432173
+vn -0.409894 0.792291 -0.451888
+vn -0.408918 0.780175 -0.473373
+vn -0.413160 0.717277 -0.561052
+vn -0.357555 0.754265 -0.550645
+vn -0.325449 0.870571 -0.369030
+vn -0.315683 0.880032 -0.354747
+vn -0.302866 0.889187 -0.342845
+vn -0.287545 0.897702 -0.333811
+vn -0.270272 0.905179 -0.327921
+vn -0.251717 0.911405 -0.325480
+vn -0.232582 0.916105 -0.326548
+vn -0.213599 0.919095 -0.331065
+vn -0.195532 0.920255 -0.338908
+vn -0.084628 0.977813 -0.191565
+vn -0.106571 0.950163 -0.292856
+vn -0.017609 0.969573 -0.244118
+vn -0.119327 0.953032 -0.278298
+vn -0.059175 0.976928 -0.205115
+vn -0.081423 0.943541 -0.321024
+vn 0.015809 0.957121 -0.289163
+vn -0.091189 0.948057 -0.304727
+vn -0.062105 0.933683 -0.352641
+vn 0.039918 0.940123 -0.338450
+vn -0.068545 0.939634 -0.335215
+vn -0.049379 0.920927 -0.386547
+vn 0.053774 0.919156 -0.390149
+vn -0.052217 0.928098 -0.368572
+vn -0.043733 0.905820 -0.421339
+vn 0.056764 0.895077 -0.442244
+vn -0.042848 0.913938 -0.403577
+vn -0.045381 0.888943 -0.455733
+vn 0.048860 0.868801 -0.492721
+vn -0.040803 0.897610 -0.438826
+vn -0.054262 0.870907 -0.488418
+vn 0.030305 0.841304 -0.539659
+vn -0.046175 0.879818 -0.473006
+vn -0.070009 0.852443 -0.518082
+vn 0.001862 0.813685 -0.581256
+vn -0.058718 0.861232 -0.504776
+vn -0.092074 0.834223 -0.543657
+vn -0.035371 0.786981 -0.615925
+vn -0.077975 0.842524 -0.532945
+vn -0.119541 0.816950 -0.564135
+vn -0.080050 0.762261 -0.642293
+vn -0.103214 0.824458 -0.556383
+vn -0.151402 0.801355 -0.578692
+vn -0.130375 0.740410 -0.659352
+vn -0.133457 0.807703 -0.574236
+vn -0.186407 0.787957 -0.586810
+vn -0.184454 0.722312 -0.666494
+vn -0.167547 0.792932 -0.585803
+vn -0.223212 0.777306 -0.588153
+vn -0.240181 0.708640 -0.663381
+vn -0.204138 0.780663 -0.590625
+vn -0.260445 0.769799 -0.582690
+vn -0.295450 0.699942 -0.650197
+vn -0.241859 0.771416 -0.588519
+vn -0.296609 0.765740 -0.570635
+vn -0.348094 0.696524 -0.627400
+vn -0.279275 0.765526 -0.579608
+vn -0.330393 0.765282 -0.552416
+vn -0.494949 0.705496 -0.507218
+vn -0.314890 0.763207 -0.564165
+vn -0.552904 0.768364 -0.322275
+vn -0.457961 0.759026 -0.462691
+vn -0.489914 0.762749 -0.422071
+vn -0.447127 0.776940 -0.443159
+vn -0.423292 0.771905 -0.474288
+vn -0.491501 0.773614 -0.399884
+vn -0.428724 0.778161 -0.458907
+vn -0.427625 0.781396 -0.454451
+vn -0.433607 0.777703 -0.455092
+vn -0.431806 0.781243 -0.450697
+vn -0.437971 0.786584 -0.435255
+vn -0.428968 0.780541 -0.454634
+vn -0.437239 0.766991 -0.469558
+vn -0.461043 0.762108 -0.454512
+vn -0.433454 0.777581 -0.455458
+vn -0.450789 0.666128 -0.594134
+vn -0.527757 0.738304 -0.419874
+vn -0.447188 0.729270 -0.517838
+vn -0.412732 0.847682 -0.333201
+vn -0.485611 0.834162 -0.261330
+vn -0.461348 0.734153 -0.498123
+vn -0.396985 0.866176 -0.303507
+vn -0.457167 0.861782 -0.219733
+vn -0.408002 0.856380 -0.316355
+vn -0.374920 0.884365 -0.277963
+vn -0.419874 0.888485 -0.185095
+vn -0.388745 0.875088 -0.288217
+vn -0.347453 0.901639 -0.257485
+vn -0.375225 0.913236 -0.158727
+vn -0.363506 0.893155 -0.264748
+vn -0.315592 0.917234 -0.242927
+vn -0.324870 0.935057 -0.141636
+vn -0.333262 0.909909 -0.246895
+vn -0.280587 0.930631 -0.234809
+vn -0.270821 0.953154 -0.134526
+vn -0.299203 0.924680 -0.235359
+vn -0.243751 0.941282 -0.233467
+vn -0.215064 0.966826 -0.137608
+vn -0.262581 0.936949 -0.230506
+vn -0.206549 0.948790 -0.238929
+vn -0.159825 0.975524 -0.150792
+vn -0.224860 0.946196 -0.232612
+vn -0.170354 0.952849 -0.250984
+vn -0.107181 0.978942 -0.173589
+vn -0.187445 0.952086 -0.241554
+vn -0.151830 0.954405 -0.256966
+vn -0.136601 0.953337 -0.269204
+usemtl Eye-White
+s 1
+f 6977//4534 6976//4535 6984//4536
+f 6978//4537 6977//4534 6985//4538
+f 6979//4539 6978//4537 6985//4538
+f 6975//4540 6974//4541 6982//4542
+f 6976//4535 6975//4540 6983//4543
+f 6984//4536 6983//4543 6990//4544
+f 6985//4538 6984//4536 6991//4545
+f 6986//4546 6985//4538 6992//4547
+f 6982//4542 6981//4548 6989//4549
+f 6983//4543 6982//4542 6989//4549
+f 6990//4544 6989//4549 6996//4550
+f 6991//4545 6990//4544 6998//4551
+f 6992//4547 6991//4545 6999//4552
+f 6993//4553 6992//4547 6999//4552
+f 6989//4549 6988//4554 6996//4550
+f 6996//4550 6995//4555 7002//4556
+f 6997//4557 6996//4550 7004//4558
+f 6998//4551 6997//4557 7005//4559
+f 6999//4552 6998//4551 7005//4559
+f 7000//4560 6999//4552 7006//4561
+f 7007//4562 7006//4561 7013//4563
+f 7003//4564 7002//4556 7009//4565
+f 7004//4558 7003//4564 7011//4566
+f 7005//4559 7004//4558 7011//4566
+f 7006//4561 7005//4559 7013//4563
+f 7012//4567 7011//4566 7019//4568
+f 7013//4563 7012//4567 7020//4569
+f 7013//4563 7020//4569 7021//4570
+f 7010//4571 7009//4565 7017//4572
+f 7011//4566 7010//4571 7018//4573
+f 7018//4573 7017//4572 7024//4574
+f 7019//4568 7018//4573 7026//4575
+f 7020//4569 7019//4568 7026//4575
+f 7021//4570 7020//4569 7027//4576
+f 7017//4572 7016//4577 7024//4574
+f 7024//4574 7023//4578 7031//4579
+f 7025//4580 7024//4574 7032//4581
+f 7026//4575 7025//4580 7033//4582
+f 7027//4576 7026//4575 7033//4582
+f 7028//4583 7027//4576 7034//4584
+f 7034//4584 7041//4585 7042//4586
+f 7031//4579 7030//4587 7037//4588
+f 7032//4581 7031//4579 7039//4589
+f 7033//4582 7032//4581 7039//4589
+f 7034//4584 7033//4582 7041//4585
+f 7040//4590 7039//4589 7046//4591
+f 7041//4585 7040//4590 7048//4592
+f 7041//4585 7048//4592 7049//4593
+f 7038//4594 7037//4588 7044//4595
+f 7039//4589 7038//4594 7046//4591
+f 7046//4591 7045//4596 7052//4597
+f 7047//4598 7046//4591 7054//4599
+f 7048//4592 7047//4598 7054//4599
+f 7048//4592 7055//4600 7056//4601
+f 7045//4596 7044//4595 7051//4602
+f 7052//4597 7051//4602 7059//4603
+f 7053//4604 7052//4597 7060//4605
+f 7054//4599 7053//4604 7061//4606
+f 7055//4600 7054//4599 7061//4606
+f 7055//4600 7062//4607 7063//4608
+f 7063//4608 7062//4607 7069//4609
+f 7059//4603 7058//4610 7065//4611
+f 7060//4605 7059//4603 7067//4612
+f 7061//4606 7060//4605 7068//4613
+f 7062//4607 7061//4606 7069//4609
+f 7069//4609 7068//4613 7076//4614
+f 7069//4609 7076//4614 7077//4615
+f 7066//4616 7065//4611 7073//4617
+f 7067//4612 7066//4616 7074//4618
+f 7068//4613 7067//4612 7075//4619
+f 7074//4618 7073//4617 7081//4620
+f 7075//4619 7074//4618 7081//4620
+f 7076//4614 7075//4619 7082//4621
+f 7076//4614 7083//4622 7084//4623
+f 7073//4617 7072//4624 7080//4625
+f 7080//4625 7079//4626 7087//4627
+f 7081//4620 7080//4625 7088//4628
+f 7082//4621 7081//4620 7089//4629
+f 7083//4622 7082//4621 7090//4630
+f 7084//4623 7083//4622 7090//4630
+f 7091//4631 7090//4630 7097//4632
+f 7087//4627 7086//4633 7093//4634
+f 7088//4628 7087//4627 7094//4635
+f 7089//4629 7088//4628 7096//4636
+f 7090//4630 7089//4629 7097//4632
+f 7097//4632 7096//4636 7104//4637
+f 7098//4638 7097//4632 7104//4637
+f 7094//4635 7093//4634 7101//4639
+f 7095//4640 7094//4635 7102//4641
+f 7096//4636 7095//4640 7103//4642
+f 7102//4641 7101//4639 7108//4643
+f 7103//4642 7102//4641 7109//4644
+f 7104//4637 7103//4642 7111//4645
+f 7104//4637 7111//4645 7112//4646
+f 7101//4639 7100//4647 7108//4643
+f 7108//4643 7107//4648 7115//4649
+f 7109//4644 7108//4643 7115//4649
+f 7110//4650 7109//4644 7117//4651
+f 7111//4645 7110//4650 7118//4652
+f 7112//4646 7111//4645 7118//4652
+f 7118//4652 7125//4653 7126//4654
+f 7115//4649 7114//4655 7122//4656
+f 7116//4657 7115//4649 7123//4658
+f 7117//4651 7116//4657 7124//4659
+f 7118//4652 7117//4651 7124//4659
+f 7125//4653 7124//4659 7133//4660
+f 7126//4654 7125//4653 7133//4660
+f 7122//4656 7121//4661 7129//4662
+f 7123//4658 7122//4656 7130//4663
+f 7124//4659 7123//4658 7131//4664
+f 7132//4665 7131//4664 7138//4666
+f 7133//4660 7132//4665 7140//4667
+f 7134//4668 7133//4660 7140//4667
+f 7130//4663 7129//4662 7136//4669
+f 7131//4664 7130//4663 7138//4666
+f 7137//4670 7136//4669 7143//4671
+f 7138//4666 7137//4670 7144//4672
+f 7139//4673 7138//4666 7145//4674
+f 7140//4667 7139//4673 7147//4675
+f 7141//4676 7140//4667 7147//4675
+f 7147//4675 7154//4677 7155//4678
+f 7144//4672 7143//4671 7150//4679
+f 7145//4674 7144//4672 7152//4680
+f 7146//4681 7145//4674 7153//4682
+f 7147//4675 7146//4681 7154//4677
+f 7154//4677 7153//4682 7161//4683
+f 7154//4677 7161//4683 7162//4684
+f 7151//4685 7150//4679 7157//4686
+f 7152//4680 7151//4685 7159//4687
+f 7153//4682 7152//4680 7160//4688
+f 7160//4688 7159//4687 7166//4689
+f 7161//4683 7160//4688 7168//4690
+f 7162//4684 7161//4683 7168//4690
+f 7158//4691 7157//4686 7164//4692
+f 7159//4687 7158//4691 7165//4693
+f 7165//4693 7164//4692 7171//4694
+f 7166//4689 7165//4693 7173//4695
+f 7167//4696 7166//4689 7173//4695
+f 7168//4690 7167//4696 7174//4697
+f 7169//4698 7168//4690 7175//4699
+f 7175//4699 7182//4700 7183//4701
+f 7172//4702 7171//4694 7178//4703
+f 7173//4695 7172//4702 7180//4704
+f 7174//4697 7173//4695 7181//4705
+f 7175//4699 7174//4697 7181//4705
+f 7182//4700 7181//4705 7189//4706
+f 7182//4700 7189//4706 7190//4707
+f 7179//4708 7178//4703 7185//4709
+f 7180//4704 7179//4708 7187//4710
+f 7181//4705 7180//4704 7188//4711
+f 7188//4711 7187//4710 7194//4712
+f 7189//4706 7188//4711 7196//4713
+f 7190//4707 7189//4706 7196//4713
+f 7186//4714 7185//4709 7192//4715
+f 7187//4710 7186//4714 7193//4716
+f 7194//4712 7193//4716 6975//4540
+f 7195//4717 7194//4712 6976//4535
+f 7196//4713 7195//4717 6977//4534
+f 7196//4713 6978//4537 6979//4539
+f 7193//4716 7192//4715 6974//4541
+f 6976//4535 6983//4543 6984//4536
+f 6977//4534 6984//4536 6985//4538
+f 7203//4718 6979//4539 6985//4538
+f 6986//4546 7203//4718 6985//4538
+f 6974//4541 6981//4548 6982//4542
+f 6975//4540 6982//4542 6983//4543
+f 6991//4545 6984//4536 6990//4544
+f 6992//4547 6985//4538 6991//4545
+f 7206//4719 6986//4546 6992//4547
+f 6993//4553 7206//4719 6992//4547
+f 6981//4548 6988//4554 6989//4549
+f 6990//4544 6983//4543 6989//4549
+f 6997//4557 6990//4544 6996//4550
+f 6990//4544 6997//4557 6998//4551
+f 6991//4545 6998//4551 6999//4552
+f 7210//4720 6993//4553 6999//4552
+f 7000//4560 7210//4720 6999//4552
+f 6988//4554 6995//4555 6996//4550
+f 7003//4564 6996//4550 7002//4556
+f 6996//4550 7003//4564 7004//4558
+f 6997//4557 7004//4558 7005//4559
+f 7006//4561 6999//4552 7005//4559
+f 7212//4721 7000//4560 7006//4561
+f 7007//4562 7212//4721 7006//4561
+f 7215//4722 7007//4562 7013//4563
+f 7014//4723 7215//4722 7013//4563
+f 7010//4571 7003//4564 7009//4565
+f 7003//4564 7010//4571 7011//4566
+f 7012//4567 7005//4559 7011//4566
+f 7005//4559 7012//4567 7013//4563
+f 7011//4566 7018//4573 7019//4568
+f 7012//4567 7019//4568 7020//4569
+f 7014//4723 7013//4563 7218//4724
+f 7013//4563 7021//4570 7218//4724
+f 7009//4565 7016//4577 7017//4572
+f 7010//4571 7017//4572 7018//4573
+f 7025//4580 7018//4573 7024//4574
+f 7018//4573 7025//4580 7026//4575
+f 7027//4576 7020//4569 7026//4575
+f 7222//4725 7021//4570 7027//4576
+f 7028//4583 7222//4725 7027//4576
+f 7016//4577 7023//4578 7024//4574
+f 7023//4578 7030//4587 7031//4579
+f 7024//4574 7031//4579 7032//4581
+f 7025//4580 7032//4581 7033//4582
+f 7034//4584 7027//4576 7033//4582
+f 7224//4726 7028//4583 7034//4584
+f 7035//4727 7224//4726 7034//4584
+f 7035//4727 7034//4584 7227//4728
+f 7034//4584 7042//4586 7227//4728
+f 7038//4594 7031//4579 7037//4588
+f 7031//4579 7038//4594 7039//4589
+f 7040//4590 7033//4582 7039//4589
+f 7033//4582 7040//4590 7041//4585
+f 7047//4598 7040//4590 7046//4591
+f 7040//4590 7047//4598 7048//4592
+f 7042//4586 7041//4585 7230//4729
+f 7041//4585 7049//4593 7230//4729
+f 7045//4596 7038//4594 7044//4595
+f 7038//4594 7045//4596 7046//4591
+f 7053//4604 7046//4591 7052//4597
+f 7046//4591 7053//4604 7054//4599
+f 7055//4600 7048//4592 7054//4599
+f 7049//4593 7048//4592 7234//4730
+f 7048//4592 7056//4601 7234//4730
+f 7052//4597 7045//4596 7051//4602
+f 7051//4602 7058//4610 7059//4603
+f 7052//4597 7059//4603 7060//4605
+f 7053//4604 7060//4605 7061//4606
+f 7062//4607 7055//4600 7061//4606
+f 7056//4601 7055//4600 7236//4731
+f 7055//4600 7063//4608 7236//4731
+f 7239//4732 7063//4608 7069//4609
+f 7070//4733 7239//4732 7069//4609
+f 7066//4616 7059//4603 7065//4611
+f 7059//4603 7066//4616 7067//4612
+f 7060//4605 7067//4612 7068//4613
+f 7061//4606 7068//4613 7069//4609
+f 7068//4613 7075//4619 7076//4614
+f 7070//4733 7069//4609 7242//4734
+f 7069//4609 7077//4615 7242//4734
+f 7065//4611 7072//4624 7073//4617
+f 7066//4616 7073//4617 7074//4618
+f 7067//4612 7074//4618 7075//4619
+f 7073//4617 7080//4625 7081//4620
+f 7082//4621 7075//4619 7081//4620
+f 7083//4622 7076//4614 7082//4621
+f 7077//4615 7076//4614 7245//4735
+f 7076//4614 7084//4623 7245//4735
+f 7072//4624 7079//4626 7080//4625
+f 7079//4626 7086//4633 7087//4627
+f 7080//4625 7087//4627 7088//4628
+f 7081//4620 7088//4628 7089//4629
+f 7082//4621 7089//4629 7090//4630
+f 7248//4736 7084//4623 7090//4630
+f 7091//4631 7248//4736 7090//4630
+f 7251//4737 7091//4631 7097//4632
+f 7098//4638 7251//4737 7097//4632
+f 7094//4635 7087//4627 7093//4634
+f 7095//4640 7088//4628 7094//4635
+f 7088//4628 7095//4640 7096//4636
+f 7089//4629 7096//4636 7097//4632
+f 7096//4636 7103//4642 7104//4637
+f 7254//4738 7098//4638 7104//4637
+f 7105//4739 7254//4738 7104//4637
+f 7093//4634 7100//4647 7101//4639
+f 7094//4635 7101//4639 7102//4641
+f 7095//4640 7102//4641 7103//4642
+f 7109//4644 7102//4641 7108//4643
+f 7110//4650 7103//4642 7109//4644
+f 7103//4642 7110//4650 7111//4645
+f 7105//4739 7104//4637 7257//4740
+f 7104//4637 7112//4646 7257//4740
+f 7100//4647 7107//4648 7108//4643
+f 7107//4648 7114//4655 7115//4649
+f 7116//4657 7109//4644 7115//4649
+f 7109//4644 7116//4657 7117//4651
+f 7110//4650 7117//4651 7118//4652
+f 7260//4741 7112//4646 7118//4652
+f 7119//4742 7260//4741 7118//4652
+f 7119//4742 7118//4652 7264//4743
+f 7118//4652 7126//4654 7264//4743
+f 7114//4655 7121//4661 7122//4656
+f 7115//4649 7122//4656 7123//4658
+f 7116//4657 7123//4658 7124//4659
+f 7125//4653 7118//4652 7124//4659
+f 7124//4659 7132//4665 7133//4660
+f 7267//4744 7126//4654 7133//4660
+f 7134//4668 7267//4744 7133//4660
+f 7130//4663 7122//4656 7129//4662
+f 7131//4664 7123//4658 7130//4663
+f 7132//4665 7124//4659 7131//4664
+f 7139//4673 7132//4665 7138//4666
+f 7132//4665 7139//4673 7140//4667
+f 7270//4745 7134//4668 7140//4667
+f 7141//4676 7270//4745 7140//4667
+f 7137//4670 7130//4663 7136//4669
+f 7130//4663 7137//4670 7138//4666
+f 7144//4672 7137//4670 7143//4671
+f 7145//4674 7138//4666 7144//4672
+f 7146//4681 7139//4673 7145//4674
+f 7139//4673 7146//4681 7147//4675
+f 7274//4746 7141//4676 7147//4675
+f 7148//4747 7274//4746 7147//4675
+f 7148//4747 7147//4675 7276//4748
+f 7147//4675 7155//4678 7276//4748
+f 7151//4685 7144//4672 7150//4679
+f 7144//4672 7151//4685 7152//4680
+f 7145//4674 7152//4680 7153//4682
+f 7146//4681 7153//4682 7154//4677
+f 7153//4682 7160//4688 7161//4683
+f 7155//4678 7154//4677 7279//4749
+f 7154//4677 7162//4684 7279//4749
+f 7158//4691 7151//4685 7157//4686
+f 7151//4685 7158//4691 7159//4687
+f 7152//4680 7159//4687 7160//4688
+f 7167//4696 7160//4688 7166//4689
+f 7160//4688 7167//4696 7168//4690
+f 7282//4750 7162//4684 7168//4690
+f 7169//4698 7282//4750 7168//4690
+f 7165//4693 7158//4691 7164//4692
+f 7166//4689 7159//4687 7165//4693
+f 7172//4702 7165//4693 7171//4694
+f 7165//4693 7172//4702 7173//4695
+f 7174//4697 7167//4696 7173//4695
+f 7175//4699 7168//4690 7174//4697
+f 7286//4751 7169//4698 7175//4699
+f 7176//4752 7286//4751 7175//4699
+f 7176//4752 7175//4699 7288//4753
+f 7175//4699 7183//4701 7288//4753
+f 7179//4708 7172//4702 7178//4703
+f 7172//4702 7179//4708 7180//4704
+f 7173//4695 7180//4704 7181//4705
+f 7182//4700 7175//4699 7181//4705
+f 7181//4705 7188//4711 7189//4706
+f 7183//4701 7182//4700 7291//4754
+f 7182//4700 7190//4707 7291//4754
+f 7186//4714 7179//4708 7185//4709
+f 7179//4708 7186//4714 7187//4710
+f 7180//4704 7187//4710 7188//4711
+f 7195//4717 7188//4711 7194//4712
+f 7188//4711 7195//4717 7196//4713
+f 7294//4755 7190//4707 7196//4713
+f 7197//4756 7294//4755 7196//4713
+f 7193//4716 7186//4714 7192//4715
+f 7194//4712 7187//4710 7193//4716
+f 6976//4535 7194//4712 6975//4540
+f 6977//4534 7195//4717 6976//4535
+f 6978//4537 7196//4713 6977//4534
+f 7197//4756 7196//4713 7328//4757
+f 7196//4713 6979//4539 7328//4757
+f 6975//4540 7193//4716 6974//4541
+usemtl Material
+f 6942//4758 6816//4759 6751//4760
+f 6943//4761 6819//4762 6753//4763
+f 6944//4764 6823//4765 6755//4766
+f 6945//4767 6825//4768 6757//4769
+f 6946//4770 6828//4771 6759//4772
+f 6947//4773 6831//4774 6761//4775
+f 6948//4776 6835//4777 6763//4778
+f 6949//4779 6837//4780 6765//4781
+f 6950//4782 6840//4783 6767//4784
+f 6951//4785 6843//4786 6769//4787
+f 6952//4788 6847//4789 6771//4790
+f 6953//4791 6849//4792 6773//4793
+f 6954//4794 6852//4795 6775//4796
+f 6955//4797 6855//4798 6777//4799
+f 6956//4800 6858//4801 6779//4802
+f 6957//4803 6861//4804 6781//4805
+f 6958//4806 6864//4807 6783//4808
+f 6959//4809 6867//4810 6785//4811
+f 6960//4812 6870//4813 6787//4814
+f 6961//4815 6873//4816 6789//4817
+f 6962//4818 6877//4819 6791//4820
+f 6963//4821 6880//4822 6794//4823
+f 6964//4824 6883//4825 6796//4826
+f 6965//4827 6887//4828 6798//4829
+f 6966//4830 6889//4831 6800//4832
+f 6967//4833 6892//4834 6802//4835
+f 6968//4836 6895//4837 6804//4838
+f 6969//4839 6899//4840 6806//4841
+f 6970//4842 6901//4843 6808//4844
+f 6971//4845 6904//4846 6810//4847
+f 6972//4848 6907//4849 6812//4850
+f 6793//4851 6909//4852 6910//4853
+f 6793//4851 6910//4853 6911//4854
+f 6793//4851 6911//4854 6912//4855
+f 6793//4851 6912//4855 6913//4856
+f 6793//4851 6913//4856 6914//4857
+f 6793//4851 6914//4857 6915//4858
+f 6793//4851 6915//4858 6916//4859
+f 6793//4851 6916//4859 6917//4860
+f 6793//4851 6917//4860 6918//4861
+f 6793//4851 6918//4861 6919//4862
+f 6793//4851 6919//4862 6920//4863
+f 6793//4851 6920//4863 6921//4864
+f 6793//4851 6921//4864 6922//4865
+f 6793//4851 6922//4865 6923//4866
+f 6793//4851 6923//4866 6924//4867
+f 6793//4851 6924//4867 6925//4868
+f 6793//4851 6925//4868 6926//4869
+f 6793//4851 6926//4869 6927//4870
+f 6793//4851 6927//4870 6928//4871
+f 6793//4851 6928//4871 6929//4872
+f 6793//4851 6929//4872 6876//4873
+f 6793//4851 6876//4873 6930//4874
+f 6793//4851 6930//4874 6931//4875
+f 6793//4851 6931//4875 6932//4876
+f 6793//4851 6932//4876 6933//4877
+f 6793//4851 6933//4877 6934//4878
+f 6793//4851 6934//4878 6935//4879
+f 6793//4851 6935//4879 6936//4880
+f 6793//4851 6936//4880 6937//4881
+f 6793//4851 6937//4881 6938//4882
+f 6793//4851 6938//4882 6939//4883
+f 6793//4851 6939//4883 6909//4852
+f 6973//4884 6941//4885 6749//4886
+f 6817//4887 6942//4758 6815//4888
+f 6750//4889 6814//4890 6817//4887
+f 6814//4890 6749//4886 6942//4758
+f 6820//4891 6943//4761 6818//4892
+f 6752//4893 6815//4888 6820//4891
+f 6815//4888 6751//4760 6943//4761
+f 6822//4894 6944//4764 6821//4895
+f 6754//4896 6818//4892 6822//4894
+f 6818//4892 6753//4763 6944//4764
+f 6826//4897 6945//4767 6824//4898
+f 6756//4899 6821//4895 6826//4897
+f 6821//4895 6755//4766 6945//4767
+f 6829//4900 6946//4770 6827//4901
+f 6758//4902 6824//4898 6829//4900
+f 6824//4898 6757//4769 6946//4770
+f 6832//4903 6947//4773 6830//4904
+f 6760//4905 6827//4901 6832//4903
+f 6827//4901 6759//4772 6947//4773
+f 6834//4906 6948//4776 6833//4907
+f 6762//4908 6830//4904 6834//4906
+f 6830//4904 6761//4775 6948//4776
+f 6838//4909 6949//4779 6836//4910
+f 6764//4911 6833//4907 6838//4909
+f 6833//4907 6763//4778 6949//4779
+f 6841//4912 6950//4782 6839//4913
+f 6766//4914 6836//4910 6841//4912
+f 6836//4910 6765//4781 6950//4782
+f 6844//4915 6951//4785 6842//4916
+f 6768//4917 6839//4913 6844//4915
+f 6839//4913 6767//4784 6951//4785
+f 6846//4918 6952//4788 6845//4919
+f 6770//4920 6842//4916 6846//4918
+f 6842//4916 6769//4787 6952//4788
+f 6850//4921 6953//4791 6848//4922
+f 6772//4923 6845//4919 6850//4921
+f 6845//4919 6771//4790 6953//4791
+f 6853//4924 6954//4794 6851//4925
+f 6774//4926 6848//4922 6853//4924
+f 6848//4922 6773//4793 6954//4794
+f 6856//4927 6955//4797 6854//4928
+f 6776//4929 6851//4925 6856//4927
+f 6851//4925 6775//4796 6955//4797
+f 6859//4930 6956//4800 6857//4931
+f 6778//4932 6854//4928 6859//4930
+f 6854//4928 6777//4799 6956//4800
+f 6862//4933 6957//4803 6860//4934
+f 6780//4935 6857//4931 6862//4933
+f 6857//4931 6779//4802 6957//4803
+f 6865//4936 6958//4806 6863//4937
+f 6782//4938 6860//4934 6865//4936
+f 6860//4934 6781//4805 6958//4806
+f 6868//4939 6959//4809 6866//4940
+f 6784//4941 6863//4937 6868//4939
+f 6863//4937 6783//4808 6959//4809
+f 6871//4942 6960//4812 6869//4943
+f 6786//4944 6866//4940 6871//4942
+f 6866//4940 6785//4811 6960//4812
+f 6874//4945 6961//4815 6872//4946
+f 6788//4947 6869//4943 6874//4945
+f 6869//4943 6787//4814 6961//4815
+f 6878//4948 6962//4818 6875//4949
+f 6790//4950 6872//4946 6878//4948
+f 6872//4946 6789//4817 6962//4818
+f 6881//4951 6963//4821 6879//4952
+f 6792//4953 6875//4949 6881//4951
+f 6875//4949 6791//4820 6963//4821
+f 6884//4954 6964//4824 6882//4955
+f 6795//4956 6879//4952 6884//4954
+f 6879//4952 6794//4823 6964//4824
+f 6886//4957 6965//4827 6885//4958
+f 6797//4959 6882//4955 6886//4957
+f 6882//4955 6796//4826 6965//4827
+f 6890//4960 6966//4830 6888//4961
+f 6799//4962 6885//4958 6890//4960
+f 6885//4958 6798//4829 6966//4830
+f 6893//4963 6967//4833 6891//4964
+f 6801//4965 6888//4961 6893//4963
+f 6888//4961 6800//4832 6967//4833
+f 6896//4966 6968//4836 6894//4967
+f 6803//4968 6891//4964 6896//4966
+f 6891//4964 6802//4835 6968//4836
+f 6898//4969 6969//4839 6897//4970
+f 6805//4971 6894//4967 6898//4969
+f 6894//4967 6804//4838 6969//4839
+f 6902//4972 6970//4842 6900//4973
+f 6807//4974 6897//4970 6902//4972
+f 6897//4970 6806//4841 6970//4842
+f 6905//4975 6971//4845 6903//4976
+f 6809//4977 6900//4973 6905//4975
+f 6900//4973 6808//4844 6971//4845
+f 6908//4978 6972//4848 6906//4979
+f 6811//4980 6903//4976 6908//4978
+f 6903//4976 6810//4847 6972//4848
+f 6910//4853 6817//4887 6752//4893
+f 6910//4853 6909//4852 6817//4887
+f 6909//4852 6750//4889 6817//4887
+f 6911//4854 6820//4891 6754//4896
+f 6911//4854 6910//4853 6820//4891
+f 6910//4853 6752//4893 6820//4891
+f 6912//4855 6822//4894 6756//4899
+f 6912//4855 6911//4854 6822//4894
+f 6911//4854 6754//4896 6822//4894
+f 6913//4856 6826//4897 6758//4902
+f 6913//4856 6912//4855 6826//4897
+f 6912//4855 6756//4899 6826//4897
+f 6914//4857 6829//4900 6760//4905
+f 6914//4857 6913//4856 6829//4900
+f 6913//4856 6758//4902 6829//4900
+f 6915//4858 6832//4903 6762//4908
+f 6915//4858 6914//4857 6832//4903
+f 6914//4857 6760//4905 6832//4903
+f 6916//4859 6834//4906 6764//4911
+f 6916//4859 6915//4858 6834//4906
+f 6915//4858 6762//4908 6834//4906
+f 6917//4860 6838//4909 6766//4914
+f 6917//4860 6916//4859 6838//4909
+f 6916//4859 6764//4911 6838//4909
+f 6918//4861 6841//4912 6768//4917
+f 6918//4861 6917//4860 6841//4912
+f 6917//4860 6766//4914 6841//4912
+f 6919//4862 6844//4915 6770//4920
+f 6919//4862 6918//4861 6844//4915
+f 6918//4861 6768//4917 6844//4915
+f 6920//4863 6846//4918 6772//4923
+f 6920//4863 6919//4862 6846//4918
+f 6919//4862 6770//4920 6846//4918
+f 6921//4864 6850//4921 6774//4926
+f 6921//4864 6920//4863 6850//4921
+f 6920//4863 6772//4923 6850//4921
+f 6922//4865 6853//4924 6776//4929
+f 6922//4865 6921//4864 6853//4924
+f 6921//4864 6774//4926 6853//4924
+f 6923//4866 6856//4927 6778//4932
+f 6923//4866 6922//4865 6856//4927
+f 6922//4865 6776//4929 6856//4927
+f 6924//4867 6859//4930 6780//4935
+f 6924//4867 6923//4866 6859//4930
+f 6923//4866 6778//4932 6859//4930
+f 6925//4868 6862//4933 6782//4938
+f 6925//4868 6924//4867 6862//4933
+f 6924//4867 6780//4935 6862//4933
+f 6926//4869 6865//4936 6784//4941
+f 6926//4869 6925//4868 6865//4936
+f 6925//4868 6782//4938 6865//4936
+f 6927//4870 6868//4939 6786//4944
+f 6927//4870 6926//4869 6868//4939
+f 6926//4869 6784//4941 6868//4939
+f 6928//4871 6871//4942 6788//4947
+f 6928//4871 6927//4870 6871//4942
+f 6927//4870 6786//4944 6871//4942
+f 6929//4872 6874//4945 6790//4950
+f 6929//4872 6928//4871 6874//4945
+f 6928//4871 6788//4947 6874//4945
+f 6876//4873 6878//4948 6792//4953
+f 6876//4873 6929//4872 6878//4948
+f 6929//4872 6790//4950 6878//4948
+f 6930//4874 6881//4951 6795//4956
+f 6930//4874 6876//4873 6881//4951
+f 6876//4873 6792//4953 6881//4951
+f 6931//4875 6884//4954 6797//4959
+f 6931//4875 6930//4874 6884//4954
+f 6930//4874 6795//4956 6884//4954
+f 6932//4876 6886//4957 6799//4962
+f 6932//4876 6931//4875 6886//4957
+f 6931//4875 6797//4959 6886//4957
+f 6933//4877 6890//4960 6801//4965
+f 6933//4877 6932//4876 6890//4960
+f 6932//4876 6799//4962 6890//4960
+f 6934//4878 6893//4963 6803//4968
+f 6934//4878 6933//4877 6893//4963
+f 6933//4877 6801//4965 6893//4963
+f 6935//4879 6896//4966 6805//4971
+f 6935//4879 6934//4878 6896//4966
+f 6934//4878 6803//4968 6896//4966
+f 6936//4880 6898//4969 6807//4974
+f 6936//4880 6935//4879 6898//4969
+f 6935//4879 6805//4971 6898//4969
+f 6937//4881 6902//4972 6809//4977
+f 6937//4881 6936//4880 6902//4972
+f 6936//4880 6807//4974 6902//4972
+f 6938//4882 6905//4975 6811//4980
+f 6938//4882 6937//4881 6905//4975
+f 6937//4881 6809//4977 6905//4975
+f 6939//4883 6908//4978 6813//4981
+f 6939//4883 6938//4882 6908//4978
+f 6938//4882 6811//4980 6908//4978
+f 6909//4852 6940//4982 6750//4889
+f 6909//4852 6939//4883 6940//4982
+f 6939//4883 6813//4981 6940//4982
+f 6940//4982 6973//4884 6814//4890
+f 6813//4981 6906//4979 6940//4982
+f 6906//4979 6812//4850 6973//4884
+f 6815//4888 6942//4758 6751//4760
+f 6818//4892 6943//4761 6753//4763
+f 6821//4895 6944//4764 6755//4766
+f 6824//4898 6945//4767 6757//4769
+f 6827//4901 6946//4770 6759//4772
+f 6830//4904 6947//4773 6761//4775
+f 6833//4907 6948//4776 6763//4778
+f 6836//4910 6949//4779 6765//4781
+f 6839//4913 6950//4782 6767//4784
+f 6842//4916 6951//4785 6769//4787
+f 6845//4919 6952//4788 6771//4790
+f 6848//4922 6953//4791 6773//4793
+f 6851//4925 6954//4794 6775//4796
+f 6854//4928 6955//4797 6777//4799
+f 6857//4931 6956//4800 6779//4802
+f 6860//4934 6957//4803 6781//4805
+f 6863//4937 6958//4806 6783//4808
+f 6866//4940 6959//4809 6785//4811
+f 6869//4943 6960//4812 6787//4814
+f 6872//4946 6961//4815 6789//4817
+f 6875//4949 6962//4818 6791//4820
+f 6879//4952 6963//4821 6794//4823
+f 6882//4955 6964//4824 6796//4826
+f 6885//4958 6965//4827 6798//4829
+f 6888//4961 6966//4830 6800//4832
+f 6891//4964 6967//4833 6802//4835
+f 6894//4967 6968//4836 6804//4838
+f 6897//4970 6969//4839 6806//4841
+f 6900//4973 6970//4842 6808//4844
+f 6903//4976 6971//4845 6810//4847
+f 6906//4979 6972//4848 6812//4850
+f 6814//4890 6973//4884 6749//4886
+f 6752//4893 6817//4887 6815//4888
+f 6814//4890 6942//4758 6817//4887
+f 6749//4886 6816//4759 6942//4758
+f 6754//4896 6820//4891 6818//4892
+f 6815//4888 6943//4761 6820//4891
+f 6751//4760 6819//4762 6943//4761
+f 6756//4899 6822//4894 6821//4895
+f 6818//4892 6944//4764 6822//4894
+f 6753//4763 6823//4765 6944//4764
+f 6758//4902 6826//4897 6824//4898
+f 6821//4895 6945//4767 6826//4897
+f 6755//4766 6825//4768 6945//4767
+f 6760//4905 6829//4900 6827//4901
+f 6824//4898 6946//4770 6829//4900
+f 6757//4769 6828//4771 6946//4770
+f 6762//4908 6832//4903 6830//4904
+f 6827//4901 6947//4773 6832//4903
+f 6759//4772 6831//4774 6947//4773
+f 6764//4911 6834//4906 6833//4907
+f 6830//4904 6948//4776 6834//4906
+f 6761//4775 6835//4777 6948//4776
+f 6766//4914 6838//4909 6836//4910
+f 6833//4907 6949//4779 6838//4909
+f 6763//4778 6837//4780 6949//4779
+f 6768//4917 6841//4912 6839//4913
+f 6836//4910 6950//4782 6841//4912
+f 6765//4781 6840//4783 6950//4782
+f 6770//4920 6844//4915 6842//4916
+f 6839//4913 6951//4785 6844//4915
+f 6767//4784 6843//4786 6951//4785
+f 6772//4923 6846//4918 6845//4919
+f 6842//4916 6952//4788 6846//4918
+f 6769//4787 6847//4789 6952//4788
+f 6774//4926 6850//4921 6848//4922
+f 6845//4919 6953//4791 6850//4921
+f 6771//4790 6849//4792 6953//4791
+f 6776//4929 6853//4924 6851//4925
+f 6848//4922 6954//4794 6853//4924
+f 6773//4793 6852//4795 6954//4794
+f 6778//4932 6856//4927 6854//4928
+f 6851//4925 6955//4797 6856//4927
+f 6775//4796 6855//4798 6955//4797
+f 6780//4935 6859//4930 6857//4931
+f 6854//4928 6956//4800 6859//4930
+f 6777//4799 6858//4801 6956//4800
+f 6782//4938 6862//4933 6860//4934
+f 6857//4931 6957//4803 6862//4933
+f 6779//4802 6861//4804 6957//4803
+f 6784//4941 6865//4936 6863//4937
+f 6860//4934 6958//4806 6865//4936
+f 6781//4805 6864//4807 6958//4806
+f 6786//4944 6868//4939 6866//4940
+f 6863//4937 6959//4809 6868//4939
+f 6783//4808 6867//4810 6959//4809
+f 6788//4947 6871//4942 6869//4943
+f 6866//4940 6960//4812 6871//4942
+f 6785//4811 6870//4813 6960//4812
+f 6790//4950 6874//4945 6872//4946
+f 6869//4943 6961//4815 6874//4945
+f 6787//4814 6873//4816 6961//4815
+f 6792//4953 6878//4948 6875//4949
+f 6872//4946 6962//4818 6878//4948
+f 6789//4817 6877//4819 6962//4818
+f 6795//4956 6881//4951 6879//4952
+f 6875//4949 6963//4821 6881//4951
+f 6791//4820 6880//4822 6963//4821
+f 6797//4959 6884//4954 6882//4955
+f 6879//4952 6964//4824 6884//4954
+f 6794//4823 6883//4825 6964//4824
+f 6799//4962 6886//4957 6885//4958
+f 6882//4955 6965//4827 6886//4957
+f 6796//4826 6887//4828 6965//4827
+f 6801//4965 6890//4960 6888//4961
+f 6885//4958 6966//4830 6890//4960
+f 6798//4829 6889//4831 6966//4830
+f 6803//4968 6893//4963 6891//4964
+f 6888//4961 6967//4833 6893//4963
+f 6800//4832 6892//4834 6967//4833
+f 6805//4971 6896//4966 6894//4967
+f 6891//4964 6968//4836 6896//4966
+f 6802//4835 6895//4837 6968//4836
+f 6807//4974 6898//4969 6897//4970
+f 6894//4967 6969//4839 6898//4969
+f 6804//4838 6899//4840 6969//4839
+f 6809//4977 6902//4972 6900//4973
+f 6897//4970 6970//4842 6902//4972
+f 6806//4841 6901//4843 6970//4842
+f 6811//4980 6905//4975 6903//4976
+f 6900//4973 6971//4845 6905//4975
+f 6808//4844 6904//4846 6971//4845
+f 6813//4981 6908//4978 6906//4979
+f 6903//4976 6972//4848 6908//4978
+f 6810//4847 6907//4849 6972//4848
+f 6750//4889 6940//4982 6814//4890
+f 6906//4979 6973//4884 6940//4982
+f 6812//4850 6941//4885 6973//4884
+usemtl Material.001
+f 7329//4983 7203//4718 6986//4546
+f 7330//4984 7206//4719 6993//4553
+f 7331//4985 7210//4720 7000//4560
+f 7332//4986 7212//4721 7007//4562
+f 7333//4987 7215//4722 7014//4723
+f 7334//4988 7218//4724 7021//4570
+f 7335//4989 7222//4725 7028//4583
+f 7336//4990 7224//4726 7035//4727
+f 7337//4991 7227//4728 7042//4586
+f 7338//4992 7230//4729 7049//4593
+f 7339//4993 7234//4730 7056//4601
+f 7340//4994 7236//4731 7063//4608
+f 7341//4995 7239//4732 7070//4733
+f 7342//4996 7242//4734 7077//4615
+f 7343//4997 7245//4735 7084//4623
+f 7344//4998 7248//4736 7091//4631
+f 7345//4999 7251//4737 7098//4638
+f 7346//5000 7254//4738 7105//4739
+f 7347//5001 7257//4740 7112//4646
+f 7348//5002 7260//4741 7119//4742
+f 7349//5003 7264//4743 7126//4654
+f 7350//5004 7267//4744 7134//4668
+f 7351//5005 7270//4745 7141//4676
+f 7352//5006 7274//4746 7148//4747
+f 7353//5007 7276//4748 7155//4678
+f 7354//5008 7279//4749 7162//4684
+f 7355//5009 7282//4750 7169//4698
+f 7356//5010 7286//4751 7176//4752
+f 7357//5011 7288//4753 7183//4701
+f 7358//5012 7291//4754 7190//4707
+f 7359//5013 7294//4755 7197//4756
+f 7128//5014 7296//5015 7297//5016
+f 7128//5014 7297//5016 7298//5017
+f 7128//5014 7298//5017 7299//5018
+f 7128//5014 7299//5018 7300//5019
+f 7128//5014 7300//5019 7301//5020
+f 7128//5014 7301//5020 7302//5021
+f 7128//5014 7302//5021 7303//5022
+f 7128//5014 7303//5022 7304//5023
+f 7128//5014 7304//5023 7305//5024
+f 7128//5014 7305//5024 7306//5025
+f 7128//5014 7306//5025 7307//5026
+f 7128//5014 7307//5026 7308//5027
+f 7128//5014 7308//5027 7309//5028
+f 7128//5014 7309//5028 7310//5029
+f 7128//5014 7310//5029 7311//5030
+f 7128//5014 7311//5030 7312//5031
+f 7128//5014 7312//5031 7313//5032
+f 7128//5014 7313//5032 7314//5033
+f 7128//5014 7314//5033 7315//5034
+f 7128//5014 7315//5034 7316//5035
+f 7128//5014 7316//5035 7263//5036
+f 7128//5014 7263//5036 7317//5037
+f 7128//5014 7317//5037 7318//5038
+f 7128//5014 7318//5038 7319//5039
+f 7128//5014 7319//5039 7320//5040
+f 7128//5014 7320//5040 7321//5041
+f 7128//5014 7321//5041 7322//5042
+f 7128//5014 7322//5042 7323//5043
+f 7128//5014 7323//5043 7324//5044
+f 7128//5014 7324//5044 7325//5045
+f 7128//5014 7325//5045 7326//5046
+f 7128//5014 7326//5046 7296//5015
+f 7360//5047 7328//4757 6979//4539
+f 7204//5048 7329//4983 7202//5049
+f 6980//5050 7201//5051 7204//5048
+f 7201//5051 6979//4539 7329//4983
+f 7207//5052 7330//4984 7205//5053
+f 6987//5054 7202//5049 7207//5052
+f 7202//5049 6986//4546 7330//4984
+f 7209//5055 7331//4985 7208//5056
+f 6994//5057 7205//5053 7209//5055
+f 7205//5053 6993//4553 7331//4985
+f 7213//5058 7332//4986 7211//5059
+f 7001//5060 7208//5056 7213//5058
+f 7208//5056 7000//4560 7332//4986
+f 7216//5061 7333//4987 7214//5062
+f 7008//5063 7211//5059 7216//5061
+f 7211//5059 7007//4562 7333//4987
+f 7219//5064 7334//4988 7217//5065
+f 7015//5066 7214//5062 7219//5064
+f 7214//5062 7014//4723 7334//4988
+f 7221//5067 7335//4989 7220//5068
+f 7022//5069 7217//5065 7221//5067
+f 7217//5065 7021//4570 7335//4989
+f 7225//5070 7336//4990 7223//5071
+f 7029//5072 7220//5068 7225//5070
+f 7220//5068 7028//4583 7336//4990
+f 7228//5073 7337//4991 7226//5074
+f 7036//5075 7223//5071 7228//5073
+f 7223//5071 7035//4727 7337//4991
+f 7231//5076 7338//4992 7229//5077
+f 7043//5078 7226//5074 7231//5076
+f 7226//5074 7042//4586 7338//4992
+f 7233//5079 7339//4993 7232//5080
+f 7050//5081 7229//5077 7233//5079
+f 7229//5077 7049//4593 7339//4993
+f 7237//5082 7340//4994 7235//5083
+f 7057//5084 7232//5080 7237//5082
+f 7232//5080 7056//4601 7340//4994
+f 7240//5085 7341//4995 7238//5086
+f 7064//5087 7235//5083 7240//5085
+f 7235//5083 7063//4608 7341//4995
+f 7243//5088 7342//4996 7241//5089
+f 7071//5090 7238//5086 7243//5088
+f 7238//5086 7070//4733 7342//4996
+f 7246//5091 7343//4997 7244//5092
+f 7078//5093 7241//5089 7246//5091
+f 7241//5089 7077//4615 7343//4997
+f 7249//5094 7344//4998 7247//5095
+f 7085//5096 7244//5092 7249//5094
+f 7244//5092 7084//4623 7344//4998
+f 7252//5097 7345//4999 7250//5098
+f 7092//5099 7247//5095 7252//5097
+f 7247//5095 7091//4631 7345//4999
+f 7255//5100 7346//5000 7253//5101
+f 7099//5102 7250//5098 7255//5100
+f 7250//5098 7098//4638 7346//5000
+f 7258//5103 7347//5001 7256//5104
+f 7106//5105 7253//5101 7258//5103
+f 7253//5101 7105//4739 7347//5001
+f 7261//5106 7348//5002 7259//5107
+f 7113//5108 7256//5104 7261//5106
+f 7256//5104 7112//4646 7348//5002
+f 7265//5109 7349//5003 7262//5110
+f 7120//5111 7259//5107 7265//5109
+f 7259//5107 7119//4742 7349//5003
+f 7268//5112 7350//5004 7266//5113
+f 7127//5114 7262//5110 7268//5112
+f 7262//5110 7126//4654 7350//5004
+f 7271//5115 7351//5005 7269//5116
+f 7135//5117 7266//5113 7271//5115
+f 7266//5113 7134//4668 7351//5005
+f 7273//5118 7352//5006 7272//5119
+f 7142//5120 7269//5116 7273//5118
+f 7269//5116 7141//4676 7352//5006
+f 7277//5121 7353//5007 7275//5122
+f 7149//5123 7272//5119 7277//5121
+f 7272//5119 7148//4747 7353//5007
+f 7280//5124 7354//5008 7278//5125
+f 7156//5126 7275//5122 7280//5124
+f 7275//5122 7155//4678 7354//5008
+f 7283//5127 7355//5009 7281//5128
+f 7163//5129 7278//5125 7283//5127
+f 7278//5125 7162//4684 7355//5009
+f 7285//5130 7356//5010 7284//5131
+f 7170//5132 7281//5128 7285//5130
+f 7281//5128 7169//4698 7356//5010
+f 7289//5133 7357//5011 7287//5134
+f 7177//5135 7284//5131 7289//5133
+f 7284//5131 7176//4752 7357//5011
+f 7292//5136 7358//5012 7290//5137
+f 7184//5138 7287//5134 7292//5136
+f 7287//5134 7183//4701 7358//5012
+f 7295//5139 7359//5013 7293//5140
+f 7191//5141 7290//5137 7295//5139
+f 7290//5137 7190//4707 7359//5013
+f 7297//5016 7204//5048 6987//5054
+f 7297//5016 7296//5015 7204//5048
+f 7296//5015 6980//5050 7204//5048
+f 7298//5017 7207//5052 6994//5057
+f 7298//5017 7297//5016 7207//5052
+f 7297//5016 6987//5054 7207//5052
+f 7299//5018 7209//5055 7001//5060
+f 7299//5018 7298//5017 7209//5055
+f 7298//5017 6994//5057 7209//5055
+f 7300//5019 7213//5058 7008//5063
+f 7300//5019 7299//5018 7213//5058
+f 7299//5018 7001//5060 7213//5058
+f 7301//5020 7216//5061 7015//5066
+f 7301//5020 7300//5019 7216//5061
+f 7300//5019 7008//5063 7216//5061
+f 7302//5021 7219//5064 7022//5069
+f 7302//5021 7301//5020 7219//5064
+f 7301//5020 7015//5066 7219//5064
+f 7303//5022 7221//5067 7029//5072
+f 7303//5022 7302//5021 7221//5067
+f 7302//5021 7022//5069 7221//5067
+f 7304//5023 7225//5070 7036//5075
+f 7304//5023 7303//5022 7225//5070
+f 7303//5022 7029//5072 7225//5070
+f 7305//5024 7228//5073 7043//5078
+f 7305//5024 7304//5023 7228//5073
+f 7304//5023 7036//5075 7228//5073
+f 7306//5025 7231//5076 7050//5081
+f 7306//5025 7305//5024 7231//5076
+f 7305//5024 7043//5078 7231//5076
+f 7307//5026 7233//5079 7057//5084
+f 7307//5026 7306//5025 7233//5079
+f 7306//5025 7050//5081 7233//5079
+f 7308//5027 7237//5082 7064//5087
+f 7308//5027 7307//5026 7237//5082
+f 7307//5026 7057//5084 7237//5082
+f 7309//5028 7240//5085 7071//5090
+f 7309//5028 7308//5027 7240//5085
+f 7308//5027 7064//5087 7240//5085
+f 7310//5029 7243//5088 7078//5093
+f 7310//5029 7309//5028 7243//5088
+f 7309//5028 7071//5090 7243//5088
+f 7311//5030 7246//5091 7085//5096
+f 7311//5030 7310//5029 7246//5091
+f 7310//5029 7078//5093 7246//5091
+f 7312//5031 7249//5094 7092//5099
+f 7312//5031 7311//5030 7249//5094
+f 7311//5030 7085//5096 7249//5094
+f 7313//5032 7252//5097 7099//5102
+f 7313//5032 7312//5031 7252//5097
+f 7312//5031 7092//5099 7252//5097
+f 7314//5033 7255//5100 7106//5105
+f 7314//5033 7313//5032 7255//5100
+f 7313//5032 7099//5102 7255//5100
+f 7315//5034 7258//5103 7113//5108
+f 7315//5034 7314//5033 7258//5103
+f 7314//5033 7106//5105 7258//5103
+f 7316//5035 7261//5106 7120//5111
+f 7316//5035 7315//5034 7261//5106
+f 7315//5034 7113//5108 7261//5106
+f 7263//5036 7265//5109 7127//5114
+f 7263//5036 7316//5035 7265//5109
+f 7316//5035 7120//5111 7265//5109
+f 7317//5037 7268//5112 7135//5117
+f 7317//5037 7263//5036 7268//5112
+f 7263//5036 7127//5114 7268//5112
+f 7318//5038 7271//5115 7142//5120
+f 7318//5038 7317//5037 7271//5115
+f 7317//5037 7135//5117 7271//5115
+f 7319//5039 7273//5118 7149//5123
+f 7319//5039 7318//5038 7273//5118
+f 7318//5038 7142//5120 7273//5118
+f 7320//5040 7277//5121 7156//5126
+f 7320//5040 7319//5039 7277//5121
+f 7319//5039 7149//5123 7277//5121
+f 7321//5041 7280//5124 7163//5129
+f 7321//5041 7320//5040 7280//5124
+f 7320//5040 7156//5126 7280//5124
+f 7322//5042 7283//5127 7170//5132
+f 7322//5042 7321//5041 7283//5127
+f 7321//5041 7163//5129 7283//5127
+f 7323//5043 7285//5130 7177//5135
+f 7323//5043 7322//5042 7285//5130
+f 7322//5042 7170//5132 7285//5130
+f 7324//5044 7289//5133 7184//5138
+f 7324//5044 7323//5043 7289//5133
+f 7323//5043 7177//5135 7289//5133
+f 7325//5045 7292//5136 7191//5141
+f 7325//5045 7324//5044 7292//5136
+f 7324//5044 7184//5138 7292//5136
+f 7326//5046 7295//5139 7198//5142
+f 7326//5046 7325//5045 7295//5139
+f 7325//5045 7191//5141 7295//5139
+f 7296//5015 7327//5143 6980//5050
+f 7296//5015 7326//5046 7327//5143
+f 7326//5046 7198//5142 7327//5143
+f 7327//5143 7360//5047 7201//5051
+f 7198//5142 7293//5140 7327//5143
+f 7293//5140 7197//4756 7360//5047
+f 7202//5049 7329//4983 6986//4546
+f 7205//5053 7330//4984 6993//4553
+f 7208//5056 7331//4985 7000//4560
+f 7211//5059 7332//4986 7007//4562
+f 7214//5062 7333//4987 7014//4723
+f 7217//5065 7334//4988 7021//4570
+f 7220//5068 7335//4989 7028//4583
+f 7223//5071 7336//4990 7035//4727
+f 7226//5074 7337//4991 7042//4586
+f 7229//5077 7338//4992 7049//4593
+f 7232//5080 7339//4993 7056//4601
+f 7235//5083 7340//4994 7063//4608
+f 7238//5086 7341//4995 7070//4733
+f 7241//5089 7342//4996 7077//4615
+f 7244//5092 7343//4997 7084//4623
+f 7247//5095 7344//4998 7091//4631
+f 7250//5098 7345//4999 7098//4638
+f 7253//5101 7346//5000 7105//4739
+f 7256//5104 7347//5001 7112//4646
+f 7259//5107 7348//5002 7119//4742
+f 7262//5110 7349//5003 7126//4654
+f 7266//5113 7350//5004 7134//4668
+f 7269//5116 7351//5005 7141//4676
+f 7272//5119 7352//5006 7148//4747
+f 7275//5122 7353//5007 7155//4678
+f 7278//5125 7354//5008 7162//4684
+f 7281//5128 7355//5009 7169//4698
+f 7284//5131 7356//5010 7176//4752
+f 7287//5134 7357//5011 7183//4701
+f 7290//5137 7358//5012 7190//4707
+f 7293//5140 7359//5013 7197//4756
+f 7201//5051 7360//5047 6979//4539
+f 6987//5054 7204//5048 7202//5049
+f 7201//5051 7329//4983 7204//5048
+f 6979//4539 7203//4718 7329//4983
+f 6994//5057 7207//5052 7205//5053
+f 7202//5049 7330//4984 7207//5052
+f 6986//4546 7206//4719 7330//4984
+f 7001//5060 7209//5055 7208//5056
+f 7205//5053 7331//4985 7209//5055
+f 6993//4553 7210//4720 7331//4985
+f 7008//5063 7213//5058 7211//5059
+f 7208//5056 7332//4986 7213//5058
+f 7000//4560 7212//4721 7332//4986
+f 7015//5066 7216//5061 7214//5062
+f 7211//5059 7333//4987 7216//5061
+f 7007//4562 7215//4722 7333//4987
+f 7022//5069 7219//5064 7217//5065
+f 7214//5062 7334//4988 7219//5064
+f 7014//4723 7218//4724 7334//4988
+f 7029//5072 7221//5067 7220//5068
+f 7217//5065 7335//4989 7221//5067
+f 7021//4570 7222//4725 7335//4989
+f 7036//5075 7225//5070 7223//5071
+f 7220//5068 7336//4990 7225//5070
+f 7028//4583 7224//4726 7336//4990
+f 7043//5078 7228//5073 7226//5074
+f 7223//5071 7337//4991 7228//5073
+f 7035//4727 7227//4728 7337//4991
+f 7050//5081 7231//5076 7229//5077
+f 7226//5074 7338//4992 7231//5076
+f 7042//4586 7230//4729 7338//4992
+f 7057//5084 7233//5079 7232//5080
+f 7229//5077 7339//4993 7233//5079
+f 7049//4593 7234//4730 7339//4993
+f 7064//5087 7237//5082 7235//5083
+f 7232//5080 7340//4994 7237//5082
+f 7056//4601 7236//4731 7340//4994
+f 7071//5090 7240//5085 7238//5086
+f 7235//5083 7341//4995 7240//5085
+f 7063//4608 7239//4732 7341//4995
+f 7078//5093 7243//5088 7241//5089
+f 7238//5086 7342//4996 7243//5088
+f 7070//4733 7242//4734 7342//4996
+f 7085//5096 7246//5091 7244//5092
+f 7241//5089 7343//4997 7246//5091
+f 7077//4615 7245//4735 7343//4997
+f 7092//5099 7249//5094 7247//5095
+f 7244//5092 7344//4998 7249//5094
+f 7084//4623 7248//4736 7344//4998
+f 7099//5102 7252//5097 7250//5098
+f 7247//5095 7345//4999 7252//5097
+f 7091//4631 7251//4737 7345//4999
+f 7106//5105 7255//5100 7253//5101
+f 7250//5098 7346//5000 7255//5100
+f 7098//4638 7254//4738 7346//5000
+f 7113//5108 7258//5103 7256//5104
+f 7253//5101 7347//5001 7258//5103
+f 7105//4739 7257//4740 7347//5001
+f 7120//5111 7261//5106 7259//5107
+f 7256//5104 7348//5002 7261//5106
+f 7112//4646 7260//4741 7348//5002
+f 7127//5114 7265//5109 7262//5110
+f 7259//5107 7349//5003 7265//5109
+f 7119//4742 7264//4743 7349//5003
+f 7135//5117 7268//5112 7266//5113
+f 7262//5110 7350//5004 7268//5112
+f 7126//4654 7267//4744 7350//5004
+f 7142//5120 7271//5115 7269//5116
+f 7266//5113 7351//5005 7271//5115
+f 7134//4668 7270//4745 7351//5005
+f 7149//5123 7273//5118 7272//5119
+f 7269//5116 7352//5006 7273//5118
+f 7141//4676 7274//4746 7352//5006
+f 7156//5126 7277//5121 7275//5122
+f 7272//5119 7353//5007 7277//5121
+f 7148//4747 7276//4748 7353//5007
+f 7163//5129 7280//5124 7278//5125
+f 7275//5122 7354//5008 7280//5124
+f 7155//4678 7279//4749 7354//5008
+f 7170//5132 7283//5127 7281//5128
+f 7278//5125 7355//5009 7283//5127
+f 7162//4684 7282//4750 7355//5009
+f 7177//5135 7285//5130 7284//5131
+f 7281//5128 7356//5010 7285//5130
+f 7169//4698 7286//4751 7356//5010
+f 7184//5138 7289//5133 7287//5134
+f 7284//5131 7357//5011 7289//5133
+f 7176//4752 7288//4753 7357//5011
+f 7191//5141 7292//5136 7290//5137
+f 7287//5134 7358//5012 7292//5136
+f 7183//4701 7291//4754 7358//5012
+f 7198//5142 7295//5139 7293//5140
+f 7290//5137 7359//5013 7295//5139
+f 7190//4707 7294//4755 7359//5013
+f 6980//5050 7327//5143 7201//5051
+f 7293//5140 7360//5047 7327//5143
+f 7197//4756 7328//4757 7360//5047
+l 7199 7200
+o Eye_L_Sphere.004
+v -0.483685 1.010693 0.349484
+v -0.489504 1.014649 0.341047
+v -0.480361 1.012142 0.347357
+v -0.487809 1.015388 0.339963
+v -0.477556 1.013611 0.344591
+v -0.486379 1.016137 0.338553
+v -0.475379 1.015045 0.341293
+v -0.485269 1.016868 0.336871
+v -0.473913 1.016386 0.337588
+v -0.484522 1.017552 0.334982
+v -0.473215 1.017585 0.333619
+v -0.484166 1.018163 0.332959
+v -0.473311 1.018595 0.329539
+v -0.484215 1.018678 0.330879
+v -0.474199 1.019378 0.325504
+v -0.484668 1.019077 0.328822
+v -0.475842 1.019902 0.321670
+v -0.485506 1.019344 0.326867
+v -0.478180 1.020149 0.318184
+v -0.486697 1.019470 0.325090
+v -0.481121 1.020108 0.315180
+v -0.488197 1.019449 0.323559
+v -0.484553 1.019781 0.312773
+v -0.489946 1.019282 0.322332
+v -0.488343 1.019181 0.311056
+v -0.491879 1.018976 0.321457
+v -0.492347 1.018330 0.310095
+v -0.493920 1.018543 0.320967
+v -0.496410 1.017262 0.309927
+v -0.495991 1.017998 0.320881
+v -0.500376 1.016018 0.310558
+v -0.498013 1.017364 0.321202
+v -0.504093 1.014645 0.311964
+v -0.499908 1.016664 0.321919
+v -0.507417 1.013196 0.314090
+v -0.501602 1.015925 0.323003
+v -0.510222 1.011726 0.316856
+v -0.503032 1.015176 0.324413
+v -0.512399 1.010293 0.320155
+v -0.504142 1.014446 0.326095
+v -0.513865 1.008951 0.323860
+v -0.504889 1.013762 0.327984
+v -0.514563 1.007752 0.327829
+v -0.505245 1.013150 0.330007
+v -0.494982 1.016666 0.331739
+v -0.514467 1.006742 0.331909
+v -0.505196 1.012635 0.332087
+v -0.513579 1.005960 0.335944
+v -0.504744 1.012237 0.334144
+v -0.511935 1.005435 0.339778
+v -0.503906 1.011969 0.336098
+v -0.509598 1.005189 0.343264
+v -0.502714 1.011844 0.337876
+v -0.506657 1.005230 0.346268
+v -0.501215 1.011864 0.339407
+v -0.503225 1.005557 0.348674
+v -0.499465 1.012031 0.340634
+v -0.499435 1.006157 0.350391
+v -0.497533 1.012337 0.341509
+v -0.495431 1.007007 0.351352
+v -0.495492 1.012771 0.341999
+v -0.491368 1.008075 0.351521
+v -0.493421 1.013315 0.342085
+v -0.487402 1.009320 0.350890
+v -0.491399 1.013949 0.341763
+v -0.486626 1.012941 0.345419
+v -0.484102 1.014042 0.343804
+v -0.482024 1.011457 0.348446
+v -0.488658 1.015030 0.340510
+v -0.481972 1.015157 0.341704
+v -0.478957 1.012917 0.345998
+v -0.487096 1.015774 0.339262
+v -0.480319 1.016246 0.339199
+v -0.485825 1.016514 0.337716
+v -0.476464 1.014370 0.342963
+v -0.479206 1.017264 0.336386
+v -0.474641 1.015758 0.339458
+v -0.484897 1.017222 0.335930
+v -0.478676 1.018175 0.333372
+v -0.473558 1.017030 0.335617
+v -0.484345 1.017869 0.333974
+v -0.478749 1.018942 0.330274
+v -0.473257 1.018135 0.331590
+v -0.484192 1.018432 0.331922
+v -0.479423 1.019536 0.327211
+v -0.484442 1.018889 0.329853
+v -0.473749 1.019032 0.327529
+v -0.480671 1.019934 0.324300
+v -0.475016 1.019686 0.323591
+v -0.485088 1.019223 0.327847
+v -0.482446 1.020121 0.321653
+v -0.477008 1.020072 0.319928
+v -0.486103 1.019419 0.325980
+v -0.484679 1.020090 0.319372
+v -0.479649 1.020175 0.316681
+v -0.487448 1.019472 0.324326
+v -0.487285 1.019842 0.317545
+v -0.489073 1.019378 0.322946
+v -0.482838 1.019991 0.313973
+v -0.490163 1.019386 0.316241
+v -0.486453 1.019527 0.311909
+v -0.490915 1.019141 0.321895
+v -0.493203 1.018740 0.315511
+v -0.490353 1.018801 0.310569
+v -0.492902 1.018772 0.321212
+v -0.496288 1.017930 0.315383
+v -0.494390 1.017841 0.310004
+v -0.494958 1.018283 0.320924
+v -0.499299 1.016985 0.315862
+v -0.498408 1.016684 0.310235
+v -0.497005 1.017693 0.321042
+v -0.502121 1.015942 0.316930
+v -0.502252 1.015374 0.311255
+v -0.498964 1.017026 0.321561
+v -0.504646 1.014842 0.318545
+v -0.505776 1.013961 0.313022
+v -0.500759 1.016306 0.322462
+v -0.506775 1.013726 0.320645
+v -0.508843 1.012501 0.315471
+v -0.502322 1.015562 0.323709
+v -0.508428 1.012638 0.323150
+v -0.511336 1.011048 0.318506
+v -0.503592 1.014822 0.325256
+v -0.509541 1.011619 0.325963
+v -0.513159 1.009660 0.322011
+v -0.504521 1.014114 0.327041
+v -0.510071 1.010709 0.328976
+v -0.500228 1.015201 0.330945
+v -0.514242 1.008388 0.325851
+v -0.505073 1.013467 0.328998
+v -0.509998 1.009942 0.332074
+v -0.514543 1.007283 0.329879
+v -0.505226 1.012903 0.331050
+v -0.509324 1.009348 0.335138
+v -0.514051 1.006386 0.333939
+v -0.504975 1.012447 0.333119
+v -0.508076 1.008950 0.338049
+v -0.504330 1.012113 0.335125
+v -0.512784 1.005732 0.337877
+v -0.506301 1.008762 0.340696
+v -0.510792 1.005346 0.341540
+v -0.503315 1.011917 0.336991
+v -0.504068 1.008794 0.342976
+v -0.508151 1.005243 0.344788
+v -0.501969 1.011864 0.338646
+v -0.501463 1.009042 0.344804
+v -0.504961 1.005427 0.347495
+v -0.500344 1.011958 0.340025
+v -0.498584 1.009497 0.346108
+v -0.498503 1.012195 0.341077
+v -0.501347 1.005891 0.349559
+v -0.495544 1.010143 0.346837
+v -0.497447 1.006617 0.350899
+v -0.496516 1.012564 0.341759
+v -0.492460 1.010954 0.346965
+v -0.493410 1.007577 0.351464
+v -0.494459 1.013053 0.342047
+v -0.489448 1.011899 0.346486
+v -0.489392 1.008734 0.351233
+v -0.492412 1.013643 0.341929
+v -0.492309 1.015955 0.336499
+v -0.491456 1.016326 0.335953
+v -0.490737 1.016703 0.335244
+v -0.490179 1.017071 0.334398
+v -0.489803 1.017415 0.333448
+v -0.489624 1.017722 0.332430
+v -0.489648 1.017981 0.331383
+v -0.489876 1.018182 0.330349
+v -0.490298 1.018317 0.329365
+v -0.490897 1.018380 0.328471
+v -0.491651 1.018369 0.327701
+v -0.492531 1.018286 0.327084
+v -0.493504 1.018131 0.326643
+v -0.494530 1.017913 0.326397
+v -0.495572 1.017640 0.326354
+v -0.496589 1.017320 0.326516
+v -0.497543 1.016968 0.326876
+v -0.498395 1.016597 0.327421
+v -0.499115 1.016220 0.328131
+v -0.499673 1.015852 0.328977
+v -0.500049 1.015508 0.329927
+v -0.500203 1.014942 0.331991
+v -0.499976 1.014741 0.333026
+v -0.499554 1.014606 0.334009
+v -0.498955 1.014543 0.334903
+v -0.498200 1.014554 0.335674
+v -0.497320 1.014638 0.336291
+v -0.496348 1.014791 0.336731
+v -0.495321 1.015010 0.336978
+v -0.494279 1.015283 0.337021
+v -0.493262 1.015603 0.336859
+v -0.490453 1.014310 0.341410
+v -0.485548 1.010044 0.350214
+v -0.485366 1.013515 0.344624
+v -0.483038 1.014624 0.342766
+v -0.481146 1.015726 0.340462
+v -0.479762 1.016780 0.337802
+v -0.478940 1.017745 0.334887
+v -0.478712 1.018584 0.331830
+v -0.479085 1.019265 0.328748
+v -0.480047 1.019762 0.325759
+v -0.481559 1.020054 0.322979
+v -0.483564 1.020133 0.320514
+v -0.485984 1.019993 0.318458
+v -0.488728 1.019641 0.316892
+v -0.491688 1.019090 0.315875
+v -0.494752 1.018361 0.315446
+v -0.497802 1.017483 0.315621
+v -0.500720 1.016489 0.316395
+v -0.503394 1.015417 0.317737
+v -0.505723 1.014308 0.319595
+v -0.507615 1.013206 0.321899
+v -0.508998 1.012151 0.324559
+v -0.509820 1.011186 0.327474
+v -0.510049 1.010347 0.330531
+v -0.509675 1.009667 0.333613
+v -0.508714 1.009170 0.336602
+v -0.507202 1.008878 0.339382
+v -0.505197 1.008799 0.341847
+v -0.502776 1.008939 0.343903
+v -0.500033 1.009291 0.345469
+v -0.497072 1.009842 0.346486
+v -0.494008 1.010571 0.346915
+v -0.490959 1.011449 0.346739
+v -0.488041 1.012443 0.345966
+v -0.277543 0.786707 0.537948
+v -0.288994 0.815456 0.533079
+v -0.305471 0.844683 0.518935
+v -0.328026 0.887146 0.501019
+v -0.354605 0.931433 0.476525
+v -0.383290 0.968461 0.443756
+v -0.412980 0.996808 0.403974
+v -0.232706 0.802725 0.508343
+v -0.246759 0.830544 0.505192
+v -0.267461 0.858262 0.493837
+v -0.295701 0.898694 0.479675
+v -0.329207 0.940506 0.459755
+v -0.365796 0.974710 0.432205
+v -0.404061 0.999994 0.398085
+v -0.195180 0.820703 0.470769
+v -0.211410 0.847479 0.469798
+v -0.235647 0.873503 0.461983
+v -0.268646 0.911656 0.452586
+v -0.307950 0.950690 0.438470
+v -0.351154 0.981725 0.417544
+v -0.396597 1.003570 0.390611
+v -0.166405 0.839951 0.426668
+v -0.184304 0.865610 0.428256
+v -0.211253 0.889820 0.424597
+v -0.247900 0.925533 0.420791
+v -0.291650 0.961593 0.413490
+v -0.339926 0.989235 0.400337
+v -0.390873 1.007398 0.381839
+v -0.147488 0.859728 0.377737
+v -0.166485 0.884240 0.382163
+v -0.195216 0.906587 0.383114
+v -0.234262 0.939792 0.385513
+v -0.280935 0.972796 0.385772
+v -0.332545 0.996952 0.381245
+v -0.387111 1.011332 0.372106
+v -0.139156 0.879276 0.325854
+v -0.158636 0.902654 0.333291
+v -0.188153 0.923159 0.339131
+v -0.228255 0.953885 0.348108
+v -0.276215 0.983869 0.356383
+v -0.329294 1.004579 0.361001
+v -0.385453 1.015221 0.361786
+v -0.141728 0.897842 0.273015
+v -0.161060 0.920143 0.283518
+v -0.190334 0.938898 0.294336
+v -0.230110 0.967270 0.310013
+v -0.277672 0.994386 0.326452
+v -0.330298 1.011823 0.340385
+v -0.385965 1.018914 0.351275
+v -0.155107 0.914714 0.221250
+v -0.173662 0.936036 0.234756
+v -0.201675 0.953201 0.250451
+v -0.239755 0.979434 0.272692
+v -0.285250 1.003943 0.297129
+v -0.335518 1.018407 0.320187
+v -0.388626 1.022270 0.340979
+v -0.178777 0.929242 0.172547
+v -0.195959 0.949721 0.188879
+v -0.221742 0.965518 0.209163
+v -0.256821 0.989908 0.237580
+v -0.298659 1.012172 0.269541
+v -0.344754 1.024075 0.301184
+v -0.393334 1.025160 0.331291
+v -0.211830 0.940869 0.128779
+v -0.227094 0.960673 0.147651
+v -0.249763 0.975375 0.172058
+v -0.280650 0.998291 0.206025
+v -0.317382 1.018759 0.244749
+v -0.357650 1.028612 0.284106
+v -0.399909 1.027472 0.322585
+v -0.252995 0.949148 0.091628
+v -0.265871 0.968472 0.112655
+v -0.284661 0.982393 0.140563
+v -0.310328 1.004259 0.179240
+v -0.340700 1.023448 0.223704
+v -0.373712 1.031842 0.269611
+v -0.408097 1.029119 0.315195
+v -0.300690 0.953760 0.062521
+v -0.310798 0.972816 0.085236
+v -0.325095 0.986303 0.115887
+v -0.344715 1.007585 0.158255
+v -0.367717 1.026061 0.207217
+v -0.392322 1.033641 0.258254
+v -0.417584 1.030036 0.309405
+v -0.353083 0.954529 0.042576
+v -0.360151 0.973540 0.066449
+v -0.369511 0.986955 0.098979
+v -0.382487 1.008139 0.143876
+v -0.397395 1.026496 0.195919
+v -0.412764 1.033941 0.250472
+v -0.428006 1.030189 0.305438
+v -0.408159 0.951424 0.032561
+v -0.412031 0.970616 0.057016
+v -0.416202 0.984323 0.090489
+v -0.422195 1.005901 0.136656
+v -0.428593 1.024737 0.190246
+v -0.434254 1.032730 0.246564
+v -0.438961 1.029572 0.303446
+v -0.463802 0.944565 0.032861
+v -0.464446 0.964155 0.057297
+v -0.463374 0.978508 0.090743
+v -0.462312 1.000956 0.136871
+v -0.460112 1.020852 0.190415
+v -0.455965 1.030054 0.246681
+v -0.450029 1.028207 0.303506
+v -0.517874 0.934216 0.043462
+v -0.515381 0.954407 0.067284
+v -0.509215 0.969735 0.099731
+v -0.501296 0.993495 0.144515
+v -0.490742 1.014990 0.196421
+v -0.477063 1.026016 0.250818
+v -0.460785 1.026149 0.305614
+v -0.568297 0.920775 0.063960
+v -0.562879 0.941745 0.086592
+v -0.551961 0.958340 0.117107
+v -0.537649 0.983804 0.159293
+v -0.519304 1.007376 0.208032
+v -0.496737 1.020771 0.258815
+v -0.470815 1.023475 0.309692
+v -0.613134 0.904757 0.093564
+v -0.605114 0.926657 0.114479
+v -0.589972 0.944761 0.142205
+v -0.569974 0.972256 0.180636
+v -0.544702 0.998303 0.224802
+v -0.514231 1.014522 0.270366
+v -0.480455 1.016774 0.313963
+v -0.650660 0.886779 0.131139
+v -0.640463 0.909722 0.149873
+v -0.621785 0.929520 0.174059
+v -0.597029 0.959294 0.207726
+v -0.565959 0.988119 0.246086
+v -0.528874 1.007507 0.285027
+v -0.489434 1.012130 0.319679
+v -0.679435 0.867532 0.175239
+v -0.667568 0.891591 0.191415
+v -0.646179 0.913202 0.211446
+v -0.617775 0.945418 0.239521
+v -0.582259 0.977216 0.271067
+v -0.540101 0.999997 0.302234
+v -0.495741 1.007945 0.328309
+v -0.698352 0.847754 0.224171
+v -0.685388 0.872961 0.237508
+v -0.662217 0.896436 0.252928
+v -0.631413 0.931159 0.274799
+v -0.592974 0.966013 0.298784
+v -0.547482 0.992280 0.321327
+v -0.499139 1.004188 0.338610
+v -0.706684 0.828206 0.276053
+v -0.693237 0.854547 0.286380
+v -0.669280 0.879864 0.296912
+v -0.637420 0.917066 0.312204
+v -0.597694 0.954940 0.328173
+v -0.550733 0.984653 0.341570
+v -0.498901 1.001679 0.349947
+v -0.442533 1.015384 0.358706
+v -0.704112 0.809640 0.328892
+v -0.690813 0.837058 0.336153
+v -0.667099 0.864124 0.341706
+v -0.635565 0.903680 0.350298
+v -0.596237 0.944423 0.358104
+v -0.549729 0.977409 0.362187
+v -0.497830 1.001369 0.362390
+v -0.690733 0.792768 0.380658
+v -0.678211 0.821166 0.384915
+v -0.655757 0.849821 0.385591
+v -0.625920 0.891516 0.387619
+v -0.588658 0.934866 0.387427
+v -0.544509 0.970826 0.382385
+v -0.495169 0.998013 0.372687
+v -0.667063 0.778240 0.429360
+v -0.655914 0.807480 0.430792
+v -0.635691 0.837505 0.426879
+v -0.608854 0.881042 0.422732
+v -0.575250 0.926637 0.415015
+v -0.535273 0.965157 0.401388
+v -0.490460 0.995123 0.382374
+v -0.634010 0.766613 0.473128
+v -0.624779 0.796528 0.472020
+v -0.607670 0.827648 0.463984
+v -0.585025 0.872659 0.454287
+v -0.556527 0.920050 0.439807
+v -0.522377 0.960620 0.418465
+v -0.483886 0.992811 0.391080
+v -0.592845 0.758335 0.510280
+v -0.586002 0.788730 0.507016
+v -0.572772 0.820629 0.495479
+v -0.555346 0.866691 0.481071
+v -0.533209 0.915361 0.460852
+v -0.506315 0.957390 0.432961
+v -0.475698 0.991164 0.398470
+v -0.545150 0.753722 0.539387
+v -0.541074 0.784385 0.534435
+v -0.532338 0.816719 0.520155
+v -0.520960 0.863366 0.502056
+v -0.506192 0.912748 0.477340
+v -0.487705 0.955591 0.444318
+v -0.466210 0.990246 0.404260
+v -0.492758 0.752954 0.559331
+v -0.491722 0.783661 0.553222
+v -0.487922 0.816068 0.537063
+v -0.483188 0.862811 0.516435
+v -0.476514 0.912313 0.488637
+v -0.467263 0.955291 0.452100
+v -0.455789 0.990094 0.408227
+v -0.437681 0.756058 0.569346
+v -0.439842 0.786585 0.562656
+v -0.441231 0.818700 0.545553
+v -0.443480 0.865050 0.523656
+v -0.445316 0.914072 0.494310
+v -0.445773 0.956502 0.456007
+v -0.444834 0.990711 0.410219
+v -0.382038 0.762917 0.569047
+v -0.387427 0.793046 0.562374
+v -0.394059 0.824514 0.545299
+v -0.403363 0.869995 0.523440
+v -0.413797 0.917957 0.494141
+v -0.424062 0.959178 0.455890
+v -0.433766 0.992075 0.410160
+v -0.327966 0.773266 0.558445
+v -0.336492 0.802794 0.552387
+v -0.348218 0.833287 0.536312
+v -0.364379 0.877456 0.515796
+v -0.383167 0.923819 0.488135
+v -0.402964 0.963216 0.451754
+v -0.423010 0.994134 0.408051
+v -0.377985 0.891508 0.314816
+v -0.379611 0.900920 0.313675
+v -0.398062 0.983969 0.424789
+v -0.384779 0.988715 0.416018
+v -0.374513 0.971776 0.438129
+v -0.408520 0.998457 0.401060
+v -0.373661 0.994041 0.404886
+v -0.358431 0.978413 0.425012
+v -0.400327 1.001839 0.394377
+v -0.365136 0.999743 0.391821
+v -0.393731 1.005542 0.386253
+v -0.345486 0.985682 0.409064
+v -0.359532 1.005602 0.377325
+v -0.336174 0.993302 0.390899
+v -0.388987 1.009424 0.376998
+v -0.357064 1.011394 0.361954
+v -0.330853 1.000980 0.371215
+v -0.386276 1.013336 0.366969
+v -0.357826 1.016894 0.346300
+v -0.329728 1.008422 0.350767
+v -0.385703 1.017128 0.356551
+v -0.361789 1.021892 0.330964
+v -0.387290 1.020653 0.346145
+v -0.332843 1.015342 0.330343
+v -0.368802 1.026197 0.316536
+v -0.340077 1.021473 0.310726
+v -0.390976 1.023776 0.336151
+v -0.378594 1.029641 0.303569
+v -0.351153 1.026580 0.292671
+v -0.396619 1.026378 0.326952
+v -0.390790 1.032094 0.292562
+v -0.365644 1.030466 0.276871
+v -0.404002 1.028359 0.318902
+v -0.404920 1.033460 0.283939
+v -0.412841 1.029641 0.312311
+v -0.382994 1.032983 0.263933
+v -0.420441 1.033688 0.278030
+v -0.402537 1.034034 0.254356
+v -0.422798 1.030176 0.307432
+v -0.436758 1.032768 0.275063
+v -0.423521 1.033578 0.248506
+v -0.433489 1.029944 0.304451
+v -0.453243 1.030736 0.275152
+v -0.445139 1.031632 0.246609
+v -0.444503 1.028953 0.303485
+v -0.469262 1.027670 0.278293
+v -0.466562 1.028273 0.248738
+v -0.455417 1.027241 0.304569
+v -0.484201 1.023688 0.284366
+v -0.486965 1.023627 0.254810
+v -0.465812 1.024874 0.307663
+v -0.496772 1.015887 0.292947
+v -0.505565 1.017875 0.264592
+v -0.473255 1.019645 0.315419
+v -0.508371 1.009900 0.303056
+v -0.521647 1.011238 0.277709
+v -0.483273 1.014518 0.318496
+v -0.517039 1.004095 0.315776
+v -0.534592 1.003969 0.293657
+v -0.490648 1.010345 0.325370
+v -0.522337 0.998472 0.330299
+v -0.543904 0.996349 0.311822
+v -0.495320 1.006522 0.334484
+v -0.523969 0.993633 0.345999
+v -0.480696 1.007079 0.352749
+v -0.549225 0.988671 0.331506
+v -0.496785 1.003461 0.344855
+v -0.524437 0.990763 0.362854
+v -0.550349 0.981229 0.351954
+v -0.494152 1.002545 0.356183
+v -0.520474 0.985765 0.378190
+v -0.547235 0.974309 0.372378
+v -0.496519 0.999748 0.367562
+v -0.513461 0.981461 0.392619
+v -0.492833 0.996624 0.377556
+v -0.540001 0.968178 0.391995
+v -0.503669 0.978016 0.405586
+v -0.528925 0.963071 0.410051
+v -0.487190 0.994022 0.386755
+v -0.491473 0.975564 0.416592
+v -0.514434 0.959185 0.425850
+v -0.479807 0.992042 0.394805
+v -0.477343 0.974197 0.425215
+v -0.497084 0.956668 0.438788
+v -0.470968 0.990760 0.401396
+v -0.461821 0.973969 0.431124
+v -0.461011 0.990224 0.406276
+v -0.477541 0.955617 0.448365
+v -0.445505 0.974889 0.434091
+v -0.456557 0.956073 0.454215
+v -0.450320 0.990457 0.409256
+v -0.429020 0.976921 0.434002
+v -0.434939 0.958019 0.456112
+v -0.439306 0.991448 0.410223
+v -0.413000 0.979987 0.430861
+v -0.413516 0.961378 0.453983
+v -0.428392 0.993160 0.409138
+v -0.427857 1.007615 0.382042
+v -0.423371 1.009218 0.379079
+v -0.419616 1.011017 0.375319
+v -0.416736 1.012943 0.370907
+v -0.414843 1.014922 0.366010
+v -0.414010 1.016878 0.360818
+v -0.414267 1.018736 0.355531
+v -0.415606 1.020425 0.350351
+v -0.417974 1.021878 0.345478
+v -0.421282 1.023042 0.341098
+v -0.425401 1.023870 0.337380
+v -0.430174 1.024332 0.334468
+v -0.435416 1.024409 0.332472
+v -0.440928 1.024098 0.331470
+v -0.446496 1.023412 0.331500
+v -0.451907 1.022376 0.332561
+v -0.456952 1.021031 0.334612
+v -0.468517 1.017045 0.328992
+v -0.475444 1.013756 0.331794
+v -0.479959 1.010818 0.337605
+v -0.482112 1.008299 0.344802
+v -0.470543 1.009910 0.361122
+v -0.469204 1.008222 0.366302
+v -0.466835 1.006768 0.371176
+v -0.463528 1.005605 0.375556
+v -0.459409 1.004776 0.379273
+v -0.454636 1.004315 0.382186
+v -0.449393 1.004238 0.384182
+v -0.443882 1.004549 0.385184
+v -0.438314 1.005235 0.385154
+v -0.432903 1.006270 0.384093
+v -0.417997 0.995526 0.406044
+v -0.393113 0.966024 0.447911
+v -0.391411 0.986459 0.420481
+v -0.379205 0.991497 0.410525
+v -0.369379 0.997014 0.398420
+v -0.362311 1.002798 0.384633
+v -0.358272 1.008626 0.369692
+v -0.357419 1.014275 0.354172
+v -0.359783 1.019527 0.338669
+v -0.365274 1.024180 0.323780
+v -0.373680 1.028056 0.310075
+v -0.384679 1.031006 0.298083
+v -0.397849 1.032917 0.288263
+v -0.412682 1.033714 0.280994
+v -0.428609 1.033368 0.276554
+v -0.445018 1.031892 0.275114
+v -0.461278 1.029341 0.276729
+v -0.476764 1.025816 0.281338
+v -0.489888 1.019368 0.289406
+v -0.502516 1.012886 0.298052
+v -0.512663 1.007077 0.309465
+v -0.519650 1.001359 0.323095
+v -0.523079 0.996059 0.338165
+v -0.523164 0.992139 0.354316
+v -0.522510 0.988382 0.370575
+v -0.517020 0.983729 0.385465
+v -0.508613 0.979852 0.399169
+v -0.497614 0.976902 0.411161
+v -0.484445 0.974992 0.420981
+v -0.469612 0.974194 0.428251
+v -0.453684 0.974541 0.432691
+v -0.437276 0.976017 0.434130
+v -0.421016 0.978567 0.432515
+v -0.405529 0.982093 0.427906
+vn 0.258370 0.533799 0.805139
+vn 0.268197 0.516129 0.813410
+vn 0.363964 0.571520 0.735435
+vn 0.190466 0.644063 0.740837
+vn 0.278390 0.675283 0.682974
+vn 0.108158 0.753349 0.648640
+vn 0.319651 0.415021 0.851802
+vn 0.370983 0.296793 0.879910
+vn 0.503952 0.344279 0.792108
+vn 0.376263 0.554735 0.742058
+vn 0.466720 0.598071 0.651479
+vn 0.452315 0.613849 0.646962
+vn 0.173437 0.778497 0.603168
+vn 0.351848 0.710471 0.609394
+vn 0.440535 0.458205 0.771966
+vn 0.541704 0.506668 0.670675
+vn 0.619282 0.558550 0.551775
+vn 0.536088 0.644490 0.545152
+vn 0.408338 0.748039 0.523118
+vn 0.227454 0.804559 0.548540
+vn 0.615253 0.397595 0.680685
+vn 0.700583 0.454695 0.549883
+vn 0.670278 0.611896 0.419843
+vn 0.581683 0.692160 0.427229
+vn 0.520066 0.659169 0.543107
+vn 0.564623 0.705741 0.427900
+vn 0.445021 0.786981 0.427259
+vn 0.297281 0.859554 0.415632
+vn 0.461715 0.825037 0.325663
+vn 0.756706 0.513352 0.404767
+vn 0.781396 0.571306 0.250893
+vn 0.601764 0.739280 0.302164
+vn 0.584246 0.751762 0.305734
+vn 0.595569 0.784020 0.174780
+vn 0.456282 0.861599 0.222297
+vn 0.305673 0.914975 0.263344
+vn 0.692740 0.664602 0.279977
+vn 0.685812 0.714652 0.137516
+vn 0.649739 0.760125 -0.002014
+vn 0.578173 0.795495 0.181310
+vn 0.546678 0.835200 0.059420
+vn 0.430280 0.894559 0.120853
+vn 0.773766 0.626392 0.094211
+vn 0.734092 0.676412 -0.059297
+vn 0.585925 0.799310 -0.133335
+vn 0.563311 0.824702 0.049989
+vn 0.490951 0.869411 -0.055239
+vn 0.283547 0.940519 0.187078
+vn 0.383923 0.923002 0.025483
+vn 0.248909 0.961455 0.116733
+vn 0.319376 0.945677 -0.060305
+vn 0.663900 0.719504 -0.203742
+vn 0.565874 0.753990 -0.333537
+vn 0.506272 0.859706 -0.067385
+vn 0.426588 0.887753 -0.172887
+vn 0.413099 0.896786 -0.158300
+vn 0.327372 0.907712 -0.262429
+vn 0.238655 0.961943 -0.132847
+vn 0.144200 0.989532 0.002564
+vn 0.496811 0.830653 -0.251320
+vn 0.443800 0.778527 -0.443709
+vn 0.385815 0.852962 -0.351482
+vn 0.257241 0.865413 -0.429975
+vn 0.316172 0.916288 -0.245766
+vn 0.203864 0.927152 -0.314310
+vn 0.145268 0.970977 -0.189856
+vn 0.075381 0.996338 -0.039857
+vn 0.302347 0.792199 -0.530045
+vn 0.115970 0.867458 -0.483718
+vn 0.212378 0.918821 -0.332591
+vn 0.086093 0.920682 -0.380688
+vn 0.080508 0.928953 -0.361278
+vn 0.042604 0.972533 -0.228706
+vn -0.001648 0.997406 -0.071718
+vn -0.065127 0.966369 -0.248756
+vn 0.146977 0.794488 -0.589190
+vn -0.016327 0.785272 -0.618885
+vn -0.046632 0.913175 -0.404828
+vn -0.049165 0.921659 -0.384838
+vn -0.174047 0.953001 -0.247932
+vn -0.160466 0.983459 -0.083865
+vn -0.032472 0.859096 -0.510727
+vn -0.182501 0.840602 -0.509934
+vn -0.180761 0.896664 -0.404096
+vn -0.180181 0.905484 -0.384136
+vn -0.328288 0.812708 -0.481338
+vn -0.311106 0.871700 -0.378521
+vn -0.279916 0.932798 -0.226966
+vn -0.241310 0.967864 -0.070437
+vn -0.181371 0.764946 -0.618000
+vn -0.341716 0.734245 -0.586566
+vn -0.464217 0.776482 -0.426069
+vn -0.432661 0.839320 -0.329142
+vn -0.307505 0.881130 -0.359172
+vn -0.426221 0.849483 -0.310923
+vn -0.378704 0.906400 -0.187017
+vn -0.318094 0.947844 -0.019959
+vn -0.466567 0.874966 -0.129276
+vn -0.491256 0.694388 -0.525773
+vn -0.585101 0.733299 -0.346263
+vn -0.540727 0.800684 -0.257759
+vn -0.531785 0.811762 -0.241218
+vn -0.539811 0.839930 -0.055361
+vn -0.392438 0.914274 0.100253
+vn -0.624226 0.646870 -0.437971
+vn -0.735527 0.593554 -0.326548
+vn -0.631184 0.757347 -0.167180
+vn -0.620167 0.769433 -0.152715
+vn -0.686270 0.684805 -0.244972
+vn -0.700552 0.710959 -0.060884
+vn -0.596423 0.802057 0.030671
+vn -0.763848 0.632923 -0.126072
+vn -0.820856 0.536485 -0.195746
+vn -0.814844 0.579608 0.005829
+vn -0.687918 0.724113 -0.048891
+vn -0.732475 0.677541 0.066286
+vn -0.633168 0.763543 0.126682
+vn -0.450942 0.866421 0.214362
+vn -0.649648 0.725150 0.228217
+vn -0.876980 0.477828 -0.050630
+vn -0.837306 0.526902 0.145695
+vn -0.746147 0.663289 0.057039
+vn -0.766259 0.616169 0.182104
+vn -0.752068 0.631519 0.188452
+vn -0.644765 0.688650 0.331614
+vn -0.471847 0.838008 0.274026
+vn -0.901669 0.419843 0.103214
+vn -0.894040 0.364788 0.259926
+vn -0.830378 0.476852 0.288156
+vn -0.760033 0.571398 0.309488
+vn -0.746025 0.587786 0.312876
+vn -0.714530 0.548051 0.434767
+vn -0.618244 0.655934 0.432997
+vn -0.492691 0.762169 0.419904
+vn -0.854366 0.314768 0.413434
+vn -0.727805 0.530747 0.434248
+vn -0.794305 0.431349 0.427717
+vn -0.784173 0.271676 0.557878
+vn -0.670736 0.495712 0.551653
+vn -0.572192 0.627155 0.528398
+vn -0.507370 0.604572 0.614002
+vn -0.410199 0.725974 0.551958
+vn -0.730491 0.392193 0.559038
+vn -0.686148 0.237190 0.687674
+vn -0.591052 0.467696 0.657155
+vn -0.658773 0.513840 0.549455
+vn -0.580950 0.486465 0.652516
+vn -0.426649 0.588549 0.686697
+vn -0.350322 0.712088 0.608386
+vn -0.641377 0.360851 0.677023
+vn -0.564074 0.212653 0.797845
+vn -0.491836 0.447737 0.746727
+vn -0.484024 0.466994 0.739982
+vn -0.376873 0.436628 0.816889
+vn -0.333323 0.579333 0.743797
+vn -0.530412 0.338511 0.777184
+vn -0.422620 0.198950 0.884182
+vn -0.401807 0.326090 0.855678
+vn -0.267220 0.196692 0.943327
+vn -0.250557 0.434767 0.864956
+vn -0.371715 0.456130 0.808527
+vn -0.248360 0.454329 0.855495
+vn -0.278390 0.706839 0.650258
+vn -0.230811 0.577624 0.782952
+vn -0.122990 0.583911 0.802423
+vn -0.126743 0.710135 0.692526
+vn -0.260567 0.324015 0.909452
+vn -0.103885 0.205878 0.973022
+vn -0.117801 0.442244 0.889096
+vn -0.118656 0.461623 0.879086
+vn -0.014039 0.597522 0.801721
+vn -0.043764 0.718741 0.693838
+vn -0.112064 0.332377 0.936430
+vn 0.061098 0.226234 0.972137
+vn 0.016297 0.458785 0.888363
+vn 0.012329 0.477767 0.878384
+vn 0.146641 0.483718 0.862819
+vn 0.091922 0.617420 0.781213
+vn 0.037904 0.350871 0.935636
+vn 0.221442 0.256935 0.940703
+vn 0.183691 0.378765 0.907041
+vn 0.139653 0.502152 0.853420
+vn 0.137364 0.767022 0.626698
+vn 0.197119 0.791528 0.578448
+vn 0.245308 0.818384 0.519669
+vn 0.265969 0.832698 0.485641
+vn 0.281381 0.847896 0.449293
+vn 0.300119 0.874966 0.379925
+vn 0.305216 0.889309 0.340465
+vn 0.304483 0.903775 0.300699
+vn 0.293497 0.928159 0.228706
+vn 0.267098 0.950926 0.156041
+vn 0.226447 0.969909 0.089084
+vn 0.200537 0.978027 0.056612
+vn 0.170293 0.984985 0.027863
+vn 0.105899 0.994171 -0.019684
+vn 0.033448 0.997925 -0.054811
+vn -0.040498 0.996307 -0.075411
+vn -0.082186 0.993225 -0.081912
+vn -0.124241 0.988769 -0.082766
+vn -0.203436 0.976226 -0.074557
+vn -0.275338 0.959868 -0.053133
+vn -0.325236 0.945494 0.015259
+vn -0.354930 0.933622 0.048494
+vn -0.366375 0.926969 0.080355
+vn -0.400922 0.906583 0.131565
+vn -0.422010 0.892666 0.158086
+vn -0.431684 0.881405 0.191595
+vn -0.452345 0.856624 0.248085
+vn -0.478347 0.821619 0.309976
+vn -0.497269 0.799921 0.335856
+vn -0.499557 0.776391 0.384198
+vn -0.474075 0.754753 0.453352
+vn -0.455031 0.743797 0.489517
+vn -0.431166 0.734977 0.523301
+vn -0.377270 0.720725 0.581530
+vn -0.316111 0.711844 0.627125
+vn -0.243995 0.707816 0.662862
+vn -0.204016 0.707389 0.676717
+vn -0.162694 0.709586 0.685537
+vn -0.082705 0.716910 0.692190
+vn -0.007202 0.728751 0.684683
+vn 0.033296 0.736656 0.675436
+vn 0.071810 0.746757 0.661184
+vn -0.084292 0.879818 0.467727
+vn -0.050356 0.860195 0.507401
+vn -0.024201 0.871609 0.489578
+vn -0.042756 0.899625 0.434553
+vn -0.001221 0.883602 0.468154
+vn 0.020631 0.895108 0.445326
+vn -0.008972 0.919279 0.393414
+vn 0.038697 0.906919 0.419507
+vn 0.055422 0.918058 0.392499
+vn 0.015687 0.938078 0.345988
+vn 0.067934 0.929136 0.363384
+vn 0.078890 0.939482 0.333323
+vn 0.030366 0.955321 0.293924
+vn 0.085299 0.949522 0.301767
+vn 0.090060 0.958678 0.269845
+vn 0.034425 0.970306 0.239357
+vn 0.090091 0.967223 0.237342
+vn 0.088504 0.974822 0.204566
+vn 0.027741 0.982452 0.184332
+vn 0.082217 0.981597 0.172246
+vn 0.074313 0.987335 0.140019
+vn 0.010620 0.991302 0.131046
+vn 0.061922 0.992065 0.109134
+vn 0.048036 0.995727 0.078738
+vn -0.016358 0.996521 0.081454
+vn 0.029969 0.998260 0.050417
+vn 0.010620 0.999664 0.022919
+vn -0.052126 0.997925 0.037416
+vn -0.012268 0.999908 -0.001556
+vn -0.036378 0.999023 -0.025056
+vn -0.095340 0.995422 0.000732
+vn -0.063387 0.996948 -0.045015
+vn -0.091250 0.993774 -0.063540
+vn -0.144261 0.989135 -0.027161
+vn -0.121311 0.989532 -0.078066
+vn -0.151860 0.984191 -0.091006
+vn -0.197119 0.979308 -0.045320
+vn -0.183813 0.977905 -0.099521
+vn -0.215918 0.970580 -0.106388
+vn -0.251778 0.966308 -0.052980
+vn -0.248482 0.962523 -0.108554
+vn -0.280892 0.953520 -0.109043
+vn -0.306192 0.950652 -0.049837
+vn -0.312845 0.943968 -0.104862
+vn -0.344340 0.933592 -0.098972
+vn -0.358318 0.932890 -0.036042
+vn -0.374493 0.922971 -0.088504
+vn -0.403760 0.911649 -0.076510
+vn -0.406018 0.913755 -0.012085
+vn -0.430921 0.900357 -0.060244
+vn -0.456923 0.888455 -0.042482
+vn -0.447584 0.893979 0.021058
+vn -0.480056 0.876949 -0.020936
+vn -0.501816 0.864956 0.001770
+vn -0.481338 0.874294 0.062136
+vn -0.520035 0.853664 0.027650
+vn -0.536607 0.842036 0.054445
+vn -0.506027 0.855495 0.109653
+vn -0.549242 0.831416 0.083834
+vn -0.560045 0.820582 0.113834
+vn -0.520707 0.838282 0.161657
+vn -0.566576 0.811029 0.145390
+vn -0.571215 0.801416 0.177252
+vn -0.524796 0.823298 0.216163
+vn -0.571398 0.793359 0.209906
+vn -0.569689 0.785241 0.242470
+vn -0.518113 0.811151 0.271218
+vn -0.563524 0.778954 0.274972
+vn -0.555498 0.772729 0.306986
+vn -0.500961 0.802301 0.324534
+vn -0.543229 0.768517 0.337992
+vn -0.529191 0.764336 0.368328
+vn -0.473952 0.797082 0.374157
+vn -0.511307 0.762322 0.396741
+vn -0.491836 0.760399 0.424116
+vn -0.438185 0.795679 0.418165
+vn -0.468978 0.760643 0.448775
+vn -0.444777 0.761040 0.472152
+vn -0.394971 0.798181 0.454848
+vn -0.417859 0.763573 0.492203
+vn -0.389874 0.766289 0.510636
+vn -0.346049 0.804437 0.482803
+vn -0.359966 0.771050 0.525224
+vn -0.329264 0.775903 0.538072
+vn -0.293191 0.814295 0.500931
+vn -0.297464 0.782678 0.546709
+vn -0.265236 0.789483 0.553453
+vn -0.238533 0.827296 0.508591
+vn -0.232795 0.798059 0.555742
+vn -0.200262 0.806574 0.556139
+vn -0.184088 0.842982 0.505448
+vn -0.168432 0.816614 0.552049
+vn -0.136814 0.826472 0.546037
+vn -0.256111 0.936888 0.237953
+vn -0.206946 0.922849 0.324747
+vn -0.191351 0.929655 0.314798
+vn -0.178198 0.936552 0.301798
+vn -0.167974 0.943266 0.286355
+vn -0.161107 0.949553 0.268960
+vn -0.157811 0.955199 0.250313
+vn -0.158269 0.959899 0.231269
+vn -0.162420 0.963591 0.212348
+vn -0.170141 0.966063 0.194281
+vn -0.181127 0.967223 0.177892
+vn -0.194891 0.967009 0.163884
+vn -0.211066 0.965484 0.152562
+vn -0.228828 0.962676 0.144444
+vn -0.247566 0.958678 0.139958
+vn -0.266640 0.953673 0.139195
+vn -0.285195 0.947844 0.142186
+vn -0.302683 0.941374 0.148747
+vn -0.318308 0.934599 0.158696
+vn -0.331431 0.927732 0.171606
+vn -0.341655 0.920988 0.187170
+vn -0.348521 0.914670 0.204596
+vn -0.351817 0.909055 0.223151
+vn -0.351360 0.904324 0.242347
+vn -0.347209 0.900632 0.261238
+vn -0.339488 0.898190 0.279153
+vn -0.328501 0.897031 0.295572
+vn -0.314707 0.897214 0.309702
+vn -0.298593 0.898740 0.320994
+vn -0.280801 0.901578 0.329020
+vn -0.262032 0.905545 0.333537
+vn -0.242988 0.910581 0.334330
+vn -0.224372 0.916410 0.331370
+vn -0.132023 0.860714 0.491623
+vn -0.106815 0.837581 0.535722
+vn -0.077395 0.848445 0.523576
+vn -0.142369 0.907315 0.395581
+vn -0.059938 0.888516 0.454878
+vn -0.156590 0.899960 0.406842
+vn -0.105380 0.868709 0.483932
+vn -0.114292 0.920682 0.373180
+vn -0.021607 0.908597 0.417035
+vn -0.125858 0.913388 0.387097
+vn -0.091464 0.933988 0.345378
+vn 0.008118 0.928159 0.371990
+vn -0.099918 0.926969 0.361553
+vn -0.074740 0.946715 0.313211
+vn 0.028138 0.946501 0.321360
+vn -0.079745 0.940245 0.330973
+vn -0.064852 0.958342 0.278146
+vn 0.037690 0.962920 0.267037
+vn -0.066195 0.952635 0.296731
+vn -0.062075 0.968444 0.241249
+vn 0.036378 0.976714 0.211280
+vn -0.059725 0.963713 0.260048
+vn -0.066591 0.976684 0.203986
+vn 0.024232 0.987396 0.156194
+vn -0.060640 0.973083 0.222297
+vn -0.078188 0.982696 0.167882
+vn 0.001801 0.994598 0.103732
+vn -0.068819 0.980316 0.184881
+vn -0.096438 0.986206 0.134434
+vn -0.030122 0.997955 0.056124
+vn -0.084017 0.985168 0.149480
+vn -0.120640 0.987152 0.104678
+vn -0.070345 0.997406 0.015046
+vn -0.105655 0.987457 0.117222
+vn -0.149846 0.985473 0.079806
+vn -0.117252 0.992920 -0.017823
+vn -0.132908 0.987060 0.089389
+vn -0.182928 0.981231 0.060945
+vn -0.169042 0.984741 -0.041261
+vn -0.164647 0.984039 0.067110
+vn -0.218696 0.974548 0.048677
+vn -0.223823 0.973083 -0.054445
+vn -0.199683 0.978484 0.051271
+vn -0.255654 0.965758 0.043489
+vn -0.279305 0.958495 -0.056734
+vn -0.236763 0.970611 0.042390
+vn -0.292459 0.955168 0.045595
+vn -0.333506 0.941496 -0.048097
+vn -0.274300 0.960753 0.040803
+vn -0.327647 0.943175 0.054903
+vn -0.384350 0.922727 -0.028871
+vn -0.311075 0.949217 0.046632
+vn -0.359966 0.930235 0.071169
+vn -0.429792 0.902921 0.000153
+vn -0.345408 0.936521 0.059633
+vn -0.388012 0.916868 0.093539
+vn -0.468123 0.882839 0.037996
+vn -0.376202 0.923124 0.079348
+vn -0.410871 0.903562 0.121433
+vn -0.497879 0.863247 0.083041
+vn -0.402112 0.909543 0.104892
+vn -0.427564 0.890866 0.153386
+vn -0.517899 0.844905 0.133702
+vn -0.422285 0.896268 0.135441
+vn -0.437483 0.879177 0.188665
+vn -0.527451 0.828516 0.187933
+vn -0.435835 0.883847 0.169683
+vn -0.440230 0.869076 0.225562
+vn -0.526139 0.814722 0.243690
+vn -0.442305 0.872738 0.206580
+vn -0.435743 0.860866 0.262642
+vn -0.513993 0.804010 0.298898
+vn -0.441420 0.863430 0.244118
+vn -0.424116 0.854854 0.298837
+vn -0.491531 0.796838 0.351238
+vn -0.433210 0.856166 0.281533
+vn -0.405896 0.851314 0.332408
+vn -0.459578 0.793481 0.398938
+vn -0.418012 0.851314 0.316996
+vn -0.381695 0.850398 0.362072
+vn -0.419385 0.794031 0.439985
+vn -0.396374 0.849025 0.349284
+vn -0.352489 0.852077 0.386853
+vn -0.372448 0.798517 0.472884
+vn -0.369182 0.849422 0.377026
+vn -0.319346 0.856319 0.405805
+vn -0.320688 0.806696 0.496353
+vn -0.337382 0.852443 0.399335
+vn -0.283670 0.862972 0.418073
+vn -0.265908 0.818323 0.509476
+vn -0.302316 0.857997 0.415235
+vn -0.246681 0.871761 0.423231
+vn -0.210395 0.832911 0.511795
+vn -0.265297 0.865841 0.424116
+vn -0.209876 0.882351 0.421155
+vn -0.156194 0.849940 0.503159
+vn -0.227729 0.875729 0.425672
+vn -0.190985 0.887234 0.419843
+vn -0.174657 0.894375 0.411786
+vn 0.061892 0.835566 0.545854
+vn 0.103763 0.852840 0.511704
+vn 0.137455 0.871761 0.470199
+vn 0.161718 0.891598 0.422895
+vn 0.175573 0.911588 0.371654
+vn 0.178472 0.930967 0.318430
+vn 0.170385 0.948973 0.265267
+vn 0.151555 0.964934 0.214179
+vn 0.122715 0.978240 0.167180
+vn 0.084994 0.988372 0.126041
+vn 0.039827 0.994903 0.092349
+vn -0.011017 0.997650 0.067446
+vn -0.065645 0.996460 0.052187
+vn -0.121921 0.991394 0.047273
+vn -0.177709 0.982635 0.052797
+vn -0.230811 0.970550 0.068606
+vn -0.390851 0.897061 0.206030
+vn -0.299081 0.932707 0.201392
+vn -0.296548 0.929136 0.220740
+vn -0.308664 0.919218 0.244331
+vn -0.325114 0.911405 0.252174
+vn -0.369396 0.914640 0.164190
+vn -0.387707 0.842158 0.374676
+vn -0.368877 0.826197 0.425764
+vn -0.340068 0.812922 0.472762
+vn -0.302316 0.802789 0.513871
+vn -0.257149 0.796228 0.547563
+vn -0.206275 0.793512 0.572497
+vn -0.151646 0.794702 0.587725
+vn -0.095370 0.799768 0.592669
+vn -0.039613 0.808496 0.587115
+vn -0.143040 0.936674 0.319590
+vn -0.061800 0.907254 0.415937
+vn -0.046022 0.912900 0.405530
+vn -0.032807 0.919218 0.392315
+vn -0.022675 0.925993 0.376782
+vn -0.016022 0.932951 0.359569
+vn -0.013092 0.939817 0.341350
+vn -0.014008 0.946379 0.322733
+vn -0.018708 0.952300 0.304544
+vn -0.027039 0.957396 0.287393
+vn -0.038667 0.961486 0.272011
+vn -0.053163 0.964415 0.258919
+vn -0.069918 0.966033 0.248695
+vn -0.088351 0.966308 0.241676
+vn -0.107730 0.965209 0.238136
+vn -0.127323 0.962798 0.238258
+vn -0.146336 0.959166 0.241981
+vn -0.321970 0.881527 0.345286
+vn -0.380688 0.869778 0.313913
+vn -0.301431 0.917783 0.258431
+vn -0.284585 0.927305 0.243080
+vn -0.281472 0.934080 0.219550
+vn -0.277902 0.953856 0.113437
+vn -0.221809 0.963469 0.149876
+vn -0.207160 0.909391 0.360607
+vn -0.198828 0.904294 0.377728
+vn -0.187201 0.900204 0.393139
+vn -0.172704 0.897275 0.406201
+vn -0.155950 0.895657 0.416456
+vn -0.137516 0.895383 0.423475
+vn -0.118137 0.896481 0.426984
+vn -0.098544 0.898892 0.426893
+vn -0.079531 0.902524 0.423139
+vn 0.013459 0.820582 0.571306
+vn 0.003998 0.876949 0.480544
+vn 0.086428 0.842189 0.532151
+vn -0.010376 0.870479 0.492050
+vn 0.040468 0.825770 0.562487
+vn 0.032319 0.888638 0.457442
+vn 0.124882 0.860622 0.493637
+vn 0.020692 0.881588 0.471511
+vn 0.055086 0.901425 0.429395
+vn 0.154393 0.880367 0.448439
+vn 0.046724 0.894070 0.445448
+vn 0.071505 0.914823 0.397382
+vn 0.173772 0.900632 0.398267
+vn 0.066713 0.907407 0.414838
+vn 0.080874 0.928343 0.362774
+vn 0.182318 0.920652 0.345103
+vn 0.079836 0.921140 0.380871
+vn 0.082827 0.941435 0.326762
+vn 0.179662 0.939695 0.290933
+vn 0.085604 0.934690 0.344920
+vn 0.077364 0.953642 0.290780
+vn 0.165960 0.956999 0.237861
+vn 0.083834 0.947600 0.308237
+vn 0.064638 0.964415 0.256294
+vn 0.141697 0.971892 0.187964
+vn 0.074526 0.959288 0.272286
+vn 0.045106 0.973418 0.224494
+vn 0.107822 0.983795 0.143101
+vn 0.058107 0.969359 0.238533
+vn 0.019623 0.980255 0.196661
+vn 0.065615 0.992279 0.105014
+vn 0.035188 0.977447 0.208136
+vn -0.010895 0.984680 0.173894
+vn 0.016724 0.997009 0.075167
+vn 0.006623 0.983184 0.182379
+vn -0.045289 0.986541 0.157018
+vn -0.036927 0.997803 0.054720
+vn -0.026460 0.986389 0.162175
+vn -0.082247 0.985717 0.146733
+vn -0.093387 0.994629 0.044465
+vn -0.062777 0.986938 0.148350
+vn -0.120304 0.982299 0.143406
+vn -0.150426 0.987579 0.044771
+vn -0.101016 0.984771 0.141392
+vn -0.157994 0.976409 0.147160
+vn -0.205847 0.976989 0.055635
+vn -0.139622 0.980010 0.141606
+vn -0.193915 0.968230 0.157842
+vn -0.367077 0.919828 0.138340
+vn -0.177129 0.972839 0.148961
+vn -0.445692 0.840266 0.308634
+vn -0.332926 0.919370 0.209418
+vn -0.369915 0.897885 0.238655
+vn -0.323679 0.916166 0.236274
+vn -0.296152 0.931211 0.212287
+vn -0.373791 0.889798 0.261757
+vn -0.303201 0.925413 0.227180
+vn -0.302530 0.924284 0.232643
+vn -0.308603 0.923124 0.229255
+vn -0.307169 0.922178 0.234931
+vn -0.315043 0.915769 0.249153
+vn -0.303903 0.924039 0.231819
+vn -0.310923 0.926603 0.211371
+vn -0.336894 0.916135 0.217170
+vn -0.308420 0.923276 0.228919
+vn -0.314097 0.947935 0.051973
+vn -0.409345 0.885220 0.220801
+vn -0.316691 0.936521 0.150365
+vn -0.300027 0.881405 0.364788
+vn -0.383038 0.831996 0.401288
+vn -0.333079 0.928007 0.166845
+vn -0.287301 0.870602 0.399335
+vn -0.358776 0.817103 0.451186
+vn -0.297067 0.874691 0.382916
+vn -0.267800 0.861629 0.431104
+vn -0.324900 0.805170 0.496048
+vn -0.280648 0.864589 0.416700
+vn -0.242286 0.854762 0.458937
+vn -0.282693 0.796686 0.534135
+vn -0.257729 0.856533 0.447096
+vn -0.211737 0.850337 0.481704
+vn -0.233802 0.791955 0.563982
+vn -0.229163 0.850795 0.472854
+vn -0.177343 0.848506 0.498581
+vn -0.180120 0.791192 0.584429
+vn -0.196051 0.847591 0.493057
+vn -0.140385 0.849300 0.508866
+vn -0.123661 0.794366 0.594684
+vn -0.159703 0.847072 0.506882
+vn -0.102329 0.852718 0.512192
+vn -0.066622 0.801386 0.594378
+vn -0.121494 0.849208 0.513840
+vn -0.064638 0.858638 0.508469
+vn -0.011200 0.812006 0.583514
+vn -0.082888 0.853969 0.513627
+vn -0.045381 0.861141 0.506272
+vn -0.028718 0.866817 0.497757
+usemtl Eye-White
+s 1
+f 7589//5144 7588//5145 7596//5146
+f 7590//5147 7589//5144 7597//5148
+f 7591//5149 7590//5147 7597//5148
+f 7587//5150 7586//5151 7593//5152
+f 7588//5145 7587//5150 7595//5153
+f 7596//5146 7595//5153 7602//5154
+f 7597//5148 7596//5146 7603//5155
+f 7598//5156 7597//5148 7604//5157
+f 7594//5158 7593//5152 7601//5159
+f 7595//5153 7594//5158 7602//5154
+f 7602//5154 7601//5159 7608//5160
+f 7603//5155 7602//5154 7609//5161
+f 7604//5157 7603//5155 7611//5162
+f 7605//5163 7604//5157 7611//5162
+f 7601//5159 7600//5164 7608//5160
+f 7608//5160 7607//5165 7615//5166
+f 7609//5161 7608//5160 7616//5167
+f 7610//5168 7609//5161 7617//5169
+f 7611//5162 7610//5168 7618//5170
+f 7611//5162 7618//5170 7619//5171
+f 7619//5171 7618//5170 7625//5172
+f 7615//5166 7614//5173 7621//5174
+f 7616//5167 7615//5166 7623//5175
+f 7617//5169 7616//5167 7623//5175
+f 7618//5170 7617//5169 7625//5172
+f 7624//5176 7623//5175 7630//5177
+f 7625//5172 7624//5176 7632//5178
+f 7625//5172 7632//5178 7633//5179
+f 7622//5180 7621//5174 7629//5181
+f 7623//5175 7622//5180 7630//5177
+f 7630//5177 7629//5181 7636//5182
+f 7631//5183 7630//5177 7638//5184
+f 7632//5178 7631//5183 7638//5184
+f 7633//5179 7632//5178 7639//5185
+f 7629//5181 7628//5186 7636//5182
+f 7636//5182 7635//5187 7643//5188
+f 7637//5189 7636//5182 7643//5188
+f 7638//5184 7637//5189 7645//5190
+f 7639//5185 7638//5184 7645//5190
+f 7640//5191 7639//5185 7646//5192
+f 7647//5193 7646//5192 7653//5194
+f 7643//5188 7642//5195 7649//5196
+f 7644//5197 7643//5188 7651//5198
+f 7645//5190 7644//5197 7652//5199
+f 7646//5192 7645//5190 7653//5194
+f 7652//5199 7651//5198 7658//5200
+f 7653//5194 7652//5199 7660//5201
+f 7653//5194 7660//5201 7661//5202
+f 7650//5203 7649//5196 7656//5204
+f 7651//5198 7650//5203 7658//5200
+f 7658//5200 7657//5205 7664//5206
+f 7659//5207 7658//5200 7666//5208
+f 7660//5201 7659//5207 7667//5209
+f 7660//5201 7667//5209 7668//5210
+f 7657//5205 7656//5204 7663//5211
+f 7664//5206 7663//5211 7671//5212
+f 7665//5213 7664//5206 7672//5214
+f 7666//5208 7665//5213 7673//5215
+f 7667//5209 7666//5208 7673//5215
+f 7667//5209 7674//5216 7675//5217
+f 7675//5217 7674//5216 7681//5218
+f 7671//5212 7670//5219 7677//5220
+f 7672//5214 7671//5212 7679//5221
+f 7673//5215 7672//5214 7680//5222
+f 7674//5216 7673//5215 7681//5218
+f 7681//5218 7680//5222 7688//5223
+f 7681//5218 7688//5223 7689//5224
+f 7678//5225 7677//5220 7685//5226
+f 7679//5221 7678//5225 7686//5227
+f 7680//5222 7679//5221 7687//5228
+f 7686//5227 7685//5226 7692//5229
+f 7687//5228 7686//5227 7693//5230
+f 7688//5223 7687//5228 7695//5231
+f 7688//5223 7695//5231 7696//5232
+f 7685//5226 7684//5233 7691//5234
+f 7692//5229 7691//5234 7699//5235
+f 7693//5230 7692//5229 7700//5236
+f 7694//5237 7693//5230 7701//5238
+f 7695//5231 7694//5237 7702//5239
+f 7696//5232 7695//5231 7702//5239
+f 7703//5240 7702//5239 7709//5241
+f 7699//5235 7698//5242 7706//5243
+f 7700//5236 7699//5235 7707//5244
+f 7701//5238 7700//5236 7707//5244
+f 7702//5239 7701//5238 7709//5241
+f 7709//5241 7708//5245 7716//5246
+f 7709//5241 7716//5246 7717//5247
+f 7706//5243 7705//5248 7712//5249
+f 7707//5244 7706//5243 7714//5250
+f 7708//5245 7707//5244 7715//5251
+f 7714//5250 7713//5252 7721//5253
+f 7715//5251 7714//5250 7721//5253
+f 7716//5246 7715//5251 7723//5254
+f 7717//5247 7716//5246 7723//5254
+f 7713//5252 7712//5249 7720//5255
+f 7720//5255 7719//5256 7727//5257
+f 7721//5253 7720//5255 7727//5257
+f 7722//5258 7721//5253 7729//5259
+f 7723//5254 7722//5258 7730//5260
+f 7723//5254 7730//5260 7731//5261
+f 7731//5261 7730//5260 7737//5262
+f 7727//5257 7726//5263 7734//5264
+f 7728//5265 7727//5257 7735//5266
+f 7729//5259 7728//5265 7736//5267
+f 7730//5260 7729//5259 7736//5267
+f 7737//5262 7736//5267 7745//5268
+f 7738//5269 7737//5262 7745//5268
+f 7734//5264 7733//5270 7741//5271
+f 7735//5266 7734//5264 7742//5272
+f 7736//5267 7735//5266 7743//5273
+f 7744//5274 7743//5273 7751//5275
+f 7745//5268 7744//5274 7752//5276
+f 7745//5268 7752//5276 7753//5277
+f 7742//5272 7741//5271 7748//5278
+f 7743//5273 7742//5272 7750//5279
+f 7749//5280 7748//5278 7755//5281
+f 7750//5279 7749//5280 7757//5282
+f 7751//5275 7750//5279 7757//5282
+f 7752//5276 7751//5275 7759//5283
+f 7753//5277 7752//5276 7759//5283
+f 7759//5283 7766//5284 7767//5285
+f 7756//5286 7755//5281 7762//5287
+f 7757//5282 7756//5286 7764//5288
+f 7758//5289 7757//5282 7765//5290
+f 7759//5283 7758//5289 7766//5284
+f 7766//5284 7765//5290 7773//5291
+f 7766//5284 7773//5291 7774//5292
+f 7763//5293 7762//5287 7769//5294
+f 7764//5288 7763//5293 7771//5295
+f 7765//5290 7764//5288 7772//5296
+f 7772//5296 7771//5295 7778//5297
+f 7773//5291 7772//5296 7780//5298
+f 7774//5292 7773//5291 7780//5298
+f 7770//5299 7769//5294 7776//5300
+f 7771//5295 7770//5299 7777//5301
+f 7777//5301 7776//5300 7783//5302
+f 7778//5297 7777//5301 7785//5303
+f 7779//5304 7778//5297 7785//5303
+f 7780//5298 7779//5304 7786//5305
+f 7781//5306 7780//5298 7787//5307
+f 7787//5307 7794//5308 7795//5309
+f 7784//5310 7783//5302 7790//5311
+f 7785//5303 7784//5310 7792//5312
+f 7786//5305 7785//5303 7793//5313
+f 7787//5307 7786//5305 7793//5313
+f 7794//5308 7793//5313 7801//5314
+f 7794//5308 7801//5314 7802//5315
+f 7791//5316 7790//5311 7797//5317
+f 7792//5312 7791//5316 7799//5318
+f 7793//5313 7792//5312 7800//5319
+f 7800//5319 7799//5318 7806//5320
+f 7801//5314 7800//5319 7808//5321
+f 7802//5315 7801//5314 7808//5321
+f 7798//5322 7797//5317 7804//5323
+f 7799//5318 7798//5322 7806//5320
+f 7806//5320 7805//5324 7587//5150
+f 7807//5325 7806//5320 7588//5145
+f 7808//5321 7807//5325 7589//5144
+f 7808//5321 7590//5147 7591//5149
+f 7805//5324 7804//5323 7586//5151
+f 7588//5145 7595//5153 7596//5146
+f 7589//5144 7596//5146 7597//5148
+f 7815//5326 7591//5149 7597//5148
+f 7598//5156 7815//5326 7597//5148
+f 7594//5158 7587//5150 7593//5152
+f 7587//5150 7594//5158 7595//5153
+f 7603//5155 7596//5146 7602//5154
+f 7604//5157 7597//5148 7603//5155
+f 7818//5327 7598//5156 7604//5157
+f 7605//5163 7818//5327 7604//5157
+f 7593//5152 7600//5164 7601//5159
+f 7594//5158 7601//5159 7602//5154
+f 7609//5161 7602//5154 7608//5160
+f 7610//5168 7603//5155 7609//5161
+f 7603//5155 7610//5168 7611//5162
+f 7822//5328 7605//5163 7611//5162
+f 7612//5329 7822//5328 7611//5162
+f 7600//5164 7607//5165 7608//5160
+f 7607//5165 7614//5173 7615//5166
+f 7608//5160 7615//5166 7616//5167
+f 7609//5161 7616//5167 7617//5169
+f 7610//5168 7617//5169 7618//5170
+f 7612//5329 7611//5162 7824//5330
+f 7611//5162 7619//5171 7824//5330
+f 7827//5331 7619//5171 7625//5172
+f 7626//5332 7827//5331 7625//5172
+f 7622//5180 7615//5166 7621//5174
+f 7615//5166 7622//5180 7623//5175
+f 7624//5176 7617//5169 7623//5175
+f 7617//5169 7624//5176 7625//5172
+f 7631//5183 7624//5176 7630//5177
+f 7624//5176 7631//5183 7632//5178
+f 7626//5332 7625//5172 7830//5333
+f 7625//5172 7633//5179 7830//5333
+f 7621//5174 7628//5186 7629//5181
+f 7622//5180 7629//5181 7630//5177
+f 7637//5189 7630//5177 7636//5182
+f 7630//5177 7637//5189 7638//5184
+f 7639//5185 7632//5178 7638//5184
+f 7834//5334 7633//5179 7639//5185
+f 7640//5191 7834//5334 7639//5185
+f 7628//5186 7635//5187 7636//5182
+f 7635//5187 7642//5195 7643//5188
+f 7644//5197 7637//5189 7643//5188
+f 7637//5189 7644//5197 7645//5190
+f 7646//5192 7639//5185 7645//5190
+f 7836//5335 7640//5191 7646//5192
+f 7647//5193 7836//5335 7646//5192
+f 7839//5336 7647//5193 7653//5194
+f 7654//5337 7839//5336 7653//5194
+f 7650//5203 7643//5188 7649//5196
+f 7643//5188 7650//5203 7651//5198
+f 7644//5197 7651//5198 7652//5199
+f 7645//5190 7652//5199 7653//5194
+f 7659//5207 7652//5199 7658//5200
+f 7652//5199 7659//5207 7660//5201
+f 7654//5337 7653//5194 7842//5338
+f 7653//5194 7661//5202 7842//5338
+f 7657//5205 7650//5203 7656//5204
+f 7650//5203 7657//5205 7658//5200
+f 7665//5213 7658//5200 7664//5206
+f 7658//5200 7665//5213 7666//5208
+f 7659//5207 7666//5208 7667//5209
+f 7661//5202 7660//5201 7846//5339
+f 7660//5201 7668//5210 7846//5339
+f 7664//5206 7657//5205 7663//5211
+f 7663//5211 7670//5219 7671//5212
+f 7664//5206 7671//5212 7672//5214
+f 7665//5213 7672//5214 7673//5215
+f 7674//5216 7667//5209 7673//5215
+f 7668//5210 7667//5209 7848//5340
+f 7667//5209 7675//5217 7848//5340
+f 7851//5341 7675//5217 7681//5218
+f 7682//5342 7851//5341 7681//5218
+f 7678//5225 7671//5212 7677//5220
+f 7671//5212 7678//5225 7679//5221
+f 7672//5214 7679//5221 7680//5222
+f 7673//5215 7680//5222 7681//5218
+f 7680//5222 7687//5228 7688//5223
+f 7682//5342 7681//5218 7854//5343
+f 7681//5218 7689//5224 7854//5343
+f 7677//5220 7684//5233 7685//5226
+f 7678//5225 7685//5226 7686//5227
+f 7679//5221 7686//5227 7687//5228
+f 7693//5230 7686//5227 7692//5229
+f 7694//5237 7687//5228 7693//5230
+f 7687//5228 7694//5237 7695//5231
+f 7689//5224 7688//5223 7857//5344
+f 7688//5223 7696//5232 7857//5344
+f 7692//5229 7685//5226 7691//5234
+f 7691//5234 7698//5242 7699//5235
+f 7692//5229 7699//5235 7700//5236
+f 7693//5230 7700//5236 7701//5238
+f 7694//5237 7701//5238 7702//5239
+f 7860//5345 7696//5232 7702//5239
+f 7703//5240 7860//5345 7702//5239
+f 7863//5346 7703//5240 7709//5241
+f 7710//5347 7863//5346 7709//5241
+f 7698//5242 7705//5248 7706//5243
+f 7699//5235 7706//5243 7707//5244
+f 7708//5245 7701//5238 7707//5244
+f 7701//5238 7708//5245 7709//5241
+f 7708//5245 7715//5251 7716//5246
+f 7710//5347 7709//5241 7866//5348
+f 7709//5241 7717//5247 7866//5348
+f 7713//5252 7706//5243 7712//5249
+f 7706//5243 7713//5252 7714//5250
+f 7707//5244 7714//5250 7715//5251
+f 7713//5252 7720//5255 7721//5253
+f 7722//5258 7715//5251 7721//5253
+f 7715//5251 7722//5258 7723//5254
+f 7869//5349 7717//5247 7723//5254
+f 7724//5350 7869//5349 7723//5254
+f 7712//5249 7719//5256 7720//5255
+f 7719//5256 7726//5263 7727//5257
+f 7728//5265 7721//5253 7727//5257
+f 7721//5253 7728//5265 7729//5259
+f 7722//5258 7729//5259 7730//5260
+f 7724//5350 7723//5254 7872//5351
+f 7723//5254 7731//5261 7872//5351
+f 7876//5352 7731//5261 7737//5262
+f 7738//5269 7876//5352 7737//5262
+f 7726//5263 7733//5270 7734//5264
+f 7727//5257 7734//5264 7735//5266
+f 7728//5265 7735//5266 7736//5267
+f 7737//5262 7730//5260 7736//5267
+f 7736//5267 7744//5274 7745//5268
+f 7879//5353 7738//5269 7745//5268
+f 7746//5354 7879//5353 7745//5268
+f 7742//5272 7734//5264 7741//5271
+f 7743//5273 7735//5266 7742//5272
+f 7744//5274 7736//5267 7743//5273
+f 7743//5273 7750//5279 7751//5275
+f 7744//5274 7751//5275 7752//5276
+f 7746//5354 7745//5268 7882//5355
+f 7745//5268 7753//5277 7882//5355
+f 7749//5280 7742//5272 7748//5278
+f 7742//5272 7749//5280 7750//5279
+f 7756//5286 7749//5280 7755//5281
+f 7749//5280 7756//5286 7757//5282
+f 7758//5289 7751//5275 7757//5282
+f 7751//5275 7758//5289 7759//5283
+f 7886//5356 7753//5277 7759//5283
+f 7760//5357 7886//5356 7759//5283
+f 7760//5357 7759//5283 7888//5358
+f 7759//5283 7767//5285 7888//5358
+f 7763//5293 7756//5286 7762//5287
+f 7756//5286 7763//5293 7764//5288
+f 7757//5282 7764//5288 7765//5290
+f 7758//5289 7765//5290 7766//5284
+f 7765//5290 7772//5296 7773//5291
+f 7767//5285 7766//5284 7891//5359
+f 7766//5284 7774//5292 7891//5359
+f 7770//5299 7763//5293 7769//5294
+f 7763//5293 7770//5299 7771//5295
+f 7764//5288 7771//5295 7772//5296
+f 7779//5304 7772//5296 7778//5297
+f 7772//5296 7779//5304 7780//5298
+f 7894//5360 7774//5292 7780//5298
+f 7781//5306 7894//5360 7780//5298
+f 7777//5301 7770//5299 7776//5300
+f 7778//5297 7771//5295 7777//5301
+f 7784//5310 7777//5301 7783//5302
+f 7777//5301 7784//5310 7785//5303
+f 7786//5305 7779//5304 7785//5303
+f 7787//5307 7780//5298 7786//5305
+f 7898//5361 7781//5306 7787//5307
+f 7788//5362 7898//5361 7787//5307
+f 7788//5362 7787//5307 7900//5363
+f 7787//5307 7795//5309 7900//5363
+f 7791//5316 7784//5310 7790//5311
+f 7784//5310 7791//5316 7792//5312
+f 7785//5303 7792//5312 7793//5313
+f 7794//5308 7787//5307 7793//5313
+f 7793//5313 7800//5319 7801//5314
+f 7795//5309 7794//5308 7903//5364
+f 7794//5308 7802//5315 7903//5364
+f 7798//5322 7791//5316 7797//5317
+f 7791//5316 7798//5322 7799//5318
+f 7792//5312 7799//5318 7800//5319
+f 7807//5325 7800//5319 7806//5320
+f 7800//5319 7807//5325 7808//5321
+f 7906//5365 7802//5315 7808//5321
+f 7809//5366 7906//5365 7808//5321
+f 7805//5324 7798//5322 7804//5323
+f 7798//5322 7805//5324 7806//5320
+f 7588//5145 7806//5320 7587//5150
+f 7589//5144 7807//5325 7588//5145
+f 7590//5147 7808//5321 7589//5144
+f 7809//5366 7808//5321 7940//5367
+f 7808//5321 7591//5149 7940//5367
+f 7587//5150 7805//5324 7586//5151
+usemtl Material
+f 7554//5368 7428//5369 7363//5370
+f 7555//5371 7431//5372 7365//5373
+f 7556//5374 7435//5375 7367//5376
+f 7557//5377 7437//5378 7369//5379
+f 7558//5380 7440//5381 7371//5382
+f 7559//5383 7443//5384 7373//5385
+f 7560//5386 7447//5387 7375//5388
+f 7561//5389 7449//5390 7377//5391
+f 7562//5392 7452//5393 7379//5394
+f 7563//5395 7455//5396 7381//5397
+f 7564//5398 7459//5399 7383//5400
+f 7565//5401 7461//5402 7385//5403
+f 7566//5404 7464//5405 7387//5406
+f 7567//5407 7467//5408 7389//5409
+f 7568//5410 7470//5411 7391//5412
+f 7569//5413 7473//5414 7393//5415
+f 7570//5416 7476//5417 7395//5418
+f 7571//5419 7479//5420 7397//5421
+f 7572//5422 7482//5423 7399//5424
+f 7573//5425 7485//5426 7401//5427
+f 7574//5428 7489//5429 7403//5430
+f 7575//5431 7492//5432 7406//5433
+f 7576//5434 7495//5435 7408//5436
+f 7577//5437 7499//5438 7410//5439
+f 7578//5440 7501//5441 7412//5442
+f 7579//5443 7504//5444 7414//5445
+f 7580//5446 7507//5447 7416//5448
+f 7581//5449 7511//5450 7418//5451
+f 7582//5452 7513//5453 7420//5454
+f 7583//5455 7516//5456 7422//5457
+f 7584//5458 7519//5459 7424//5460
+f 7405//5461 7521//5462 7522//5463
+f 7405//5461 7522//5463 7523//5464
+f 7405//5461 7523//5464 7524//5465
+f 7405//5461 7524//5465 7525//5466
+f 7405//5461 7525//5466 7526//5467
+f 7405//5461 7526//5467 7527//5468
+f 7405//5461 7527//5468 7528//5469
+f 7405//5461 7528//5469 7529//5470
+f 7405//5461 7529//5470 7530//5471
+f 7405//5461 7530//5471 7531//5472
+f 7405//5461 7531//5472 7532//5473
+f 7405//5461 7532//5473 7533//5474
+f 7405//5461 7533//5474 7534//5475
+f 7405//5461 7534//5475 7535//5476
+f 7405//5461 7535//5476 7536//5477
+f 7405//5461 7536//5477 7537//5478
+f 7405//5461 7537//5478 7538//5479
+f 7405//5461 7538//5479 7539//5480
+f 7405//5461 7539//5480 7540//5481
+f 7405//5461 7540//5481 7541//5482
+f 7405//5461 7541//5482 7488//5483
+f 7405//5461 7488//5483 7542//5484
+f 7405//5461 7542//5484 7543//5485
+f 7405//5461 7543//5485 7544//5486
+f 7405//5461 7544//5486 7545//5487
+f 7405//5461 7545//5487 7546//5488
+f 7405//5461 7546//5488 7547//5489
+f 7405//5461 7547//5489 7548//5490
+f 7405//5461 7548//5490 7549//5491
+f 7405//5461 7549//5491 7550//5492
+f 7405//5461 7550//5492 7551//5493
+f 7405//5461 7551//5493 7521//5462
+f 7585//5494 7553//5495 7361//5496
+f 7429//5497 7554//5368 7427//5498
+f 7362//5499 7426//5500 7429//5497
+f 7426//5500 7361//5496 7554//5368
+f 7432//5501 7555//5371 7430//5502
+f 7364//5503 7427//5498 7432//5501
+f 7427//5498 7363//5370 7555//5371
+f 7434//5504 7556//5374 7433//5505
+f 7366//5506 7430//5502 7434//5504
+f 7430//5502 7365//5373 7556//5374
+f 7438//5507 7557//5377 7436//5508
+f 7368//5509 7433//5505 7438//5507
+f 7433//5505 7367//5376 7557//5377
+f 7441//5510 7558//5380 7439//5511
+f 7370//5512 7436//5508 7441//5510
+f 7436//5508 7369//5379 7558//5380
+f 7444//5513 7559//5383 7442//5514
+f 7372//5515 7439//5511 7444//5513
+f 7439//5511 7371//5382 7559//5383
+f 7446//5516 7560//5386 7445//5517
+f 7374//5518 7442//5514 7446//5516
+f 7442//5514 7373//5385 7560//5386
+f 7450//5519 7561//5389 7448//5520
+f 7376//5521 7445//5517 7450//5519
+f 7445//5517 7375//5388 7561//5389
+f 7453//5522 7562//5392 7451//5523
+f 7378//5524 7448//5520 7453//5522
+f 7448//5520 7377//5391 7562//5392
+f 7456//5525 7563//5395 7454//5526
+f 7380//5527 7451//5523 7456//5525
+f 7451//5523 7379//5394 7563//5395
+f 7458//5528 7564//5398 7457//5529
+f 7382//5530 7454//5526 7458//5528
+f 7454//5526 7381//5397 7564//5398
+f 7462//5531 7565//5401 7460//5532
+f 7384//5533 7457//5529 7462//5531
+f 7457//5529 7383//5400 7565//5401
+f 7465//5534 7566//5404 7463//5535
+f 7386//5536 7460//5532 7465//5534
+f 7460//5532 7385//5403 7566//5404
+f 7468//5537 7567//5407 7466//5538
+f 7388//5539 7463//5535 7468//5537
+f 7463//5535 7387//5406 7567//5407
+f 7471//5540 7568//5410 7469//5541
+f 7390//5542 7466//5538 7471//5540
+f 7466//5538 7389//5409 7568//5410
+f 7474//5543 7569//5413 7472//5544
+f 7392//5545 7469//5541 7474//5543
+f 7469//5541 7391//5412 7569//5413
+f 7477//5546 7570//5416 7475//5547
+f 7394//5548 7472//5544 7477//5546
+f 7472//5544 7393//5415 7570//5416
+f 7480//5549 7571//5419 7478//5550
+f 7396//5551 7475//5547 7480//5549
+f 7475//5547 7395//5418 7571//5419
+f 7483//5552 7572//5422 7481//5553
+f 7398//5554 7478//5550 7483//5552
+f 7478//5550 7397//5421 7572//5422
+f 7486//5555 7573//5425 7484//5556
+f 7400//5557 7481//5553 7486//5555
+f 7481//5553 7399//5424 7573//5425
+f 7490//5558 7574//5428 7487//5559
+f 7402//5560 7484//5556 7490//5558
+f 7484//5556 7401//5427 7574//5428
+f 7493//5561 7575//5431 7491//5562
+f 7404//5563 7487//5559 7493//5561
+f 7487//5559 7403//5430 7575//5431
+f 7496//5564 7576//5434 7494//5565
+f 7407//5566 7491//5562 7496//5564
+f 7491//5562 7406//5433 7576//5434
+f 7498//5567 7577//5437 7497//5568
+f 7409//5569 7494//5565 7498//5567
+f 7494//5565 7408//5436 7577//5437
+f 7502//5570 7578//5440 7500//5571
+f 7411//5572 7497//5568 7502//5570
+f 7497//5568 7410//5439 7578//5440
+f 7505//5573 7579//5443 7503//5574
+f 7413//5575 7500//5571 7505//5573
+f 7500//5571 7412//5442 7579//5443
+f 7508//5576 7580//5446 7506//5577
+f 7415//5578 7503//5574 7508//5576
+f 7503//5574 7414//5445 7580//5446
+f 7510//5579 7581//5449 7509//5580
+f 7417//5581 7506//5577 7510//5579
+f 7506//5577 7416//5448 7581//5449
+f 7514//5582 7582//5452 7512//5583
+f 7419//5584 7509//5580 7514//5582
+f 7509//5580 7418//5451 7582//5452
+f 7517//5585 7583//5455 7515//5586
+f 7421//5587 7512//5583 7517//5585
+f 7512//5583 7420//5454 7583//5455
+f 7520//5588 7584//5458 7518//5589
+f 7423//5590 7515//5586 7520//5588
+f 7515//5586 7422//5457 7584//5458
+f 7522//5463 7429//5497 7364//5503
+f 7522//5463 7521//5462 7429//5497
+f 7521//5462 7362//5499 7429//5497
+f 7523//5464 7432//5501 7366//5506
+f 7523//5464 7522//5463 7432//5501
+f 7522//5463 7364//5503 7432//5501
+f 7524//5465 7434//5504 7368//5509
+f 7524//5465 7523//5464 7434//5504
+f 7523//5464 7366//5506 7434//5504
+f 7525//5466 7438//5507 7370//5512
+f 7525//5466 7524//5465 7438//5507
+f 7524//5465 7368//5509 7438//5507
+f 7526//5467 7441//5510 7372//5515
+f 7526//5467 7525//5466 7441//5510
+f 7525//5466 7370//5512 7441//5510
+f 7527//5468 7444//5513 7374//5518
+f 7527//5468 7526//5467 7444//5513
+f 7526//5467 7372//5515 7444//5513
+f 7528//5469 7446//5516 7376//5521
+f 7528//5469 7527//5468 7446//5516
+f 7527//5468 7374//5518 7446//5516
+f 7529//5470 7450//5519 7378//5524
+f 7529//5470 7528//5469 7450//5519
+f 7528//5469 7376//5521 7450//5519
+f 7530//5471 7453//5522 7380//5527
+f 7530//5471 7529//5470 7453//5522
+f 7529//5470 7378//5524 7453//5522
+f 7531//5472 7456//5525 7382//5530
+f 7531//5472 7530//5471 7456//5525
+f 7530//5471 7380//5527 7456//5525
+f 7532//5473 7458//5528 7384//5533
+f 7532//5473 7531//5472 7458//5528
+f 7531//5472 7382//5530 7458//5528
+f 7533//5474 7462//5531 7386//5536
+f 7533//5474 7532//5473 7462//5531
+f 7532//5473 7384//5533 7462//5531
+f 7534//5475 7465//5534 7388//5539
+f 7534//5475 7533//5474 7465//5534
+f 7533//5474 7386//5536 7465//5534
+f 7535//5476 7468//5537 7390//5542
+f 7535//5476 7534//5475 7468//5537
+f 7534//5475 7388//5539 7468//5537
+f 7536//5477 7471//5540 7392//5545
+f 7536//5477 7535//5476 7471//5540
+f 7535//5476 7390//5542 7471//5540
+f 7537//5478 7474//5543 7394//5548
+f 7537//5478 7536//5477 7474//5543
+f 7536//5477 7392//5545 7474//5543
+f 7538//5479 7477//5546 7396//5551
+f 7538//5479 7537//5478 7477//5546
+f 7537//5478 7394//5548 7477//5546
+f 7539//5480 7480//5549 7398//5554
+f 7539//5480 7538//5479 7480//5549
+f 7538//5479 7396//5551 7480//5549
+f 7540//5481 7483//5552 7400//5557
+f 7540//5481 7539//5480 7483//5552
+f 7539//5480 7398//5554 7483//5552
+f 7541//5482 7486//5555 7402//5560
+f 7541//5482 7540//5481 7486//5555
+f 7540//5481 7400//5557 7486//5555
+f 7488//5483 7490//5558 7404//5563
+f 7488//5483 7541//5482 7490//5558
+f 7541//5482 7402//5560 7490//5558
+f 7542//5484 7493//5561 7407//5566
+f 7542//5484 7488//5483 7493//5561
+f 7488//5483 7404//5563 7493//5561
+f 7543//5485 7496//5564 7409//5569
+f 7543//5485 7542//5484 7496//5564
+f 7542//5484 7407//5566 7496//5564
+f 7544//5486 7498//5567 7411//5572
+f 7544//5486 7543//5485 7498//5567
+f 7543//5485 7409//5569 7498//5567
+f 7545//5487 7502//5570 7413//5575
+f 7545//5487 7544//5486 7502//5570
+f 7544//5486 7411//5572 7502//5570
+f 7546//5488 7505//5573 7415//5578
+f 7546//5488 7545//5487 7505//5573
+f 7545//5487 7413//5575 7505//5573
+f 7547//5489 7508//5576 7417//5581
+f 7547//5489 7546//5488 7508//5576
+f 7546//5488 7415//5578 7508//5576
+f 7548//5490 7510//5579 7419//5584
+f 7548//5490 7547//5489 7510//5579
+f 7547//5489 7417//5581 7510//5579
+f 7549//5491 7514//5582 7421//5587
+f 7549//5491 7548//5490 7514//5582
+f 7548//5490 7419//5584 7514//5582
+f 7550//5492 7517//5585 7423//5590
+f 7550//5492 7549//5491 7517//5585
+f 7549//5491 7421//5587 7517//5585
+f 7551//5493 7520//5588 7425//5591
+f 7551//5493 7550//5492 7520//5588
+f 7550//5492 7423//5590 7520//5588
+f 7521//5462 7552//5592 7362//5499
+f 7521//5462 7551//5493 7552//5592
+f 7551//5493 7425//5591 7552//5592
+f 7552//5592 7585//5494 7426//5500
+f 7425//5591 7518//5589 7552//5592
+f 7518//5589 7424//5460 7585//5494
+f 7427//5498 7554//5368 7363//5370
+f 7430//5502 7555//5371 7365//5373
+f 7433//5505 7556//5374 7367//5376
+f 7436//5508 7557//5377 7369//5379
+f 7439//5511 7558//5380 7371//5382
+f 7442//5514 7559//5383 7373//5385
+f 7445//5517 7560//5386 7375//5388
+f 7448//5520 7561//5389 7377//5391
+f 7451//5523 7562//5392 7379//5394
+f 7454//5526 7563//5395 7381//5397
+f 7457//5529 7564//5398 7383//5400
+f 7460//5532 7565//5401 7385//5403
+f 7463//5535 7566//5404 7387//5406
+f 7466//5538 7567//5407 7389//5409
+f 7469//5541 7568//5410 7391//5412
+f 7472//5544 7569//5413 7393//5415
+f 7475//5547 7570//5416 7395//5418
+f 7478//5550 7571//5419 7397//5421
+f 7481//5553 7572//5422 7399//5424
+f 7484//5556 7573//5425 7401//5427
+f 7487//5559 7574//5428 7403//5430
+f 7491//5562 7575//5431 7406//5433
+f 7494//5565 7576//5434 7408//5436
+f 7497//5568 7577//5437 7410//5439
+f 7500//5571 7578//5440 7412//5442
+f 7503//5574 7579//5443 7414//5445
+f 7506//5577 7580//5446 7416//5448
+f 7509//5580 7581//5449 7418//5451
+f 7512//5583 7582//5452 7420//5454
+f 7515//5586 7583//5455 7422//5457
+f 7518//5589 7584//5458 7424//5460
+f 7426//5500 7585//5494 7361//5496
+f 7364//5503 7429//5497 7427//5498
+f 7426//5500 7554//5368 7429//5497
+f 7361//5496 7428//5369 7554//5368
+f 7366//5506 7432//5501 7430//5502
+f 7427//5498 7555//5371 7432//5501
+f 7363//5370 7431//5372 7555//5371
+f 7368//5509 7434//5504 7433//5505
+f 7430//5502 7556//5374 7434//5504
+f 7365//5373 7435//5375 7556//5374
+f 7370//5512 7438//5507 7436//5508
+f 7433//5505 7557//5377 7438//5507
+f 7367//5376 7437//5378 7557//5377
+f 7372//5515 7441//5510 7439//5511
+f 7436//5508 7558//5380 7441//5510
+f 7369//5379 7440//5381 7558//5380
+f 7374//5518 7444//5513 7442//5514
+f 7439//5511 7559//5383 7444//5513
+f 7371//5382 7443//5384 7559//5383
+f 7376//5521 7446//5516 7445//5517
+f 7442//5514 7560//5386 7446//5516
+f 7373//5385 7447//5387 7560//5386
+f 7378//5524 7450//5519 7448//5520
+f 7445//5517 7561//5389 7450//5519
+f 7375//5388 7449//5390 7561//5389
+f 7380//5527 7453//5522 7451//5523
+f 7448//5520 7562//5392 7453//5522
+f 7377//5391 7452//5393 7562//5392
+f 7382//5530 7456//5525 7454//5526
+f 7451//5523 7563//5395 7456//5525
+f 7379//5394 7455//5396 7563//5395
+f 7384//5533 7458//5528 7457//5529
+f 7454//5526 7564//5398 7458//5528
+f 7381//5397 7459//5399 7564//5398
+f 7386//5536 7462//5531 7460//5532
+f 7457//5529 7565//5401 7462//5531
+f 7383//5400 7461//5402 7565//5401
+f 7388//5539 7465//5534 7463//5535
+f 7460//5532 7566//5404 7465//5534
+f 7385//5403 7464//5405 7566//5404
+f 7390//5542 7468//5537 7466//5538
+f 7463//5535 7567//5407 7468//5537
+f 7387//5406 7467//5408 7567//5407
+f 7392//5545 7471//5540 7469//5541
+f 7466//5538 7568//5410 7471//5540
+f 7389//5409 7470//5411 7568//5410
+f 7394//5548 7474//5543 7472//5544
+f 7469//5541 7569//5413 7474//5543
+f 7391//5412 7473//5414 7569//5413
+f 7396//5551 7477//5546 7475//5547
+f 7472//5544 7570//5416 7477//5546
+f 7393//5415 7476//5417 7570//5416
+f 7398//5554 7480//5549 7478//5550
+f 7475//5547 7571//5419 7480//5549
+f 7395//5418 7479//5420 7571//5419
+f 7400//5557 7483//5552 7481//5553
+f 7478//5550 7572//5422 7483//5552
+f 7397//5421 7482//5423 7572//5422
+f 7402//5560 7486//5555 7484//5556
+f 7481//5553 7573//5425 7486//5555
+f 7399//5424 7485//5426 7573//5425
+f 7404//5563 7490//5558 7487//5559
+f 7484//5556 7574//5428 7490//5558
+f 7401//5427 7489//5429 7574//5428
+f 7407//5566 7493//5561 7491//5562
+f 7487//5559 7575//5431 7493//5561
+f 7403//5430 7492//5432 7575//5431
+f 7409//5569 7496//5564 7494//5565
+f 7491//5562 7576//5434 7496//5564
+f 7406//5433 7495//5435 7576//5434
+f 7411//5572 7498//5567 7497//5568
+f 7494//5565 7577//5437 7498//5567
+f 7408//5436 7499//5438 7577//5437
+f 7413//5575 7502//5570 7500//5571
+f 7497//5568 7578//5440 7502//5570
+f 7410//5439 7501//5441 7578//5440
+f 7415//5578 7505//5573 7503//5574
+f 7500//5571 7579//5443 7505//5573
+f 7412//5442 7504//5444 7579//5443
+f 7417//5581 7508//5576 7506//5577
+f 7503//5574 7580//5446 7508//5576
+f 7414//5445 7507//5447 7580//5446
+f 7419//5584 7510//5579 7509//5580
+f 7506//5577 7581//5449 7510//5579
+f 7416//5448 7511//5450 7581//5449
+f 7421//5587 7514//5582 7512//5583
+f 7509//5580 7582//5452 7514//5582
+f 7418//5451 7513//5453 7582//5452
+f 7423//5590 7517//5585 7515//5586
+f 7512//5583 7583//5455 7517//5585
+f 7420//5454 7516//5456 7583//5455
+f 7425//5591 7520//5588 7518//5589
+f 7515//5586 7584//5458 7520//5588
+f 7422//5457 7519//5459 7584//5458
+f 7362//5499 7552//5592 7426//5500
+f 7518//5589 7585//5494 7552//5592
+f 7424//5460 7553//5495 7585//5494
+usemtl Material.001
+f 7941//5593 7815//5326 7598//5156
+f 7942//5594 7818//5327 7605//5163
+f 7943//5595 7822//5328 7612//5329
+f 7944//5596 7824//5330 7619//5171
+f 7945//5597 7827//5331 7626//5332
+f 7946//5598 7830//5333 7633//5179
+f 7947//5599 7834//5334 7640//5191
+f 7948//5600 7836//5335 7647//5193
+f 7949//5601 7839//5336 7654//5337
+f 7950//5602 7842//5338 7661//5202
+f 7951//5603 7846//5339 7668//5210
+f 7952//5604 7848//5340 7675//5217
+f 7953//5605 7851//5341 7682//5342
+f 7954//5606 7854//5343 7689//5224
+f 7955//5607 7857//5344 7696//5232
+f 7956//5608 7860//5345 7703//5240
+f 7957//5609 7863//5346 7710//5347
+f 7958//5610 7866//5348 7717//5247
+f 7959//5611 7869//5349 7724//5350
+f 7960//5612 7872//5351 7731//5261
+f 7961//5613 7876//5352 7738//5269
+f 7962//5614 7879//5353 7746//5354
+f 7963//5615 7882//5355 7753//5277
+f 7964//5616 7886//5356 7760//5357
+f 7965//5617 7888//5358 7767//5285
+f 7966//5618 7891//5359 7774//5292
+f 7967//5619 7894//5360 7781//5306
+f 7968//5620 7898//5361 7788//5362
+f 7969//5621 7900//5363 7795//5309
+f 7970//5622 7903//5364 7802//5315
+f 7971//5623 7906//5365 7809//5366
+f 7740//5624 7908//5625 7909//5626
+f 7740//5624 7909//5626 7910//5627
+f 7740//5624 7910//5627 7911//5628
+f 7740//5624 7911//5628 7912//5629
+f 7740//5624 7912//5629 7913//5630
+f 7740//5624 7913//5630 7914//5631
+f 7740//5624 7914//5631 7915//5632
+f 7740//5624 7915//5632 7916//5633
+f 7740//5624 7916//5633 7917//5634
+f 7740//5624 7917//5634 7918//5635
+f 7740//5624 7918//5635 7919//5636
+f 7740//5624 7919//5636 7920//5637
+f 7740//5624 7920//5637 7921//5638
+f 7740//5624 7921//5638 7922//5639
+f 7740//5624 7922//5639 7923//5640
+f 7740//5624 7923//5640 7924//5641
+f 7740//5624 7924//5641 7925//5642
+f 7740//5624 7925//5642 7926//5643
+f 7740//5624 7926//5643 7927//5644
+f 7740//5624 7927//5644 7928//5645
+f 7740//5624 7928//5645 7875//5646
+f 7740//5624 7875//5646 7929//5647
+f 7740//5624 7929//5647 7930//5648
+f 7740//5624 7930//5648 7931//5649
+f 7740//5624 7931//5649 7932//5650
+f 7740//5624 7932//5650 7933//5651
+f 7740//5624 7933//5651 7934//5652
+f 7740//5624 7934//5652 7935//5653
+f 7740//5624 7935//5653 7936//5654
+f 7740//5624 7936//5654 7937//5655
+f 7740//5624 7937//5655 7938//5656
+f 7740//5624 7938//5656 7908//5625
+f 7972//5657 7940//5367 7591//5149
+f 7816//5658 7941//5593 7814//5659
+f 7592//5660 7813//5661 7816//5658
+f 7813//5661 7591//5149 7941//5593
+f 7819//5662 7942//5594 7817//5663
+f 7599//5664 7814//5659 7819//5662
+f 7814//5659 7598//5156 7942//5594
+f 7821//5665 7943//5595 7820//5666
+f 7606//5667 7817//5663 7821//5665
+f 7817//5663 7605//5163 7943//5595
+f 7825//5668 7944//5596 7823//5669
+f 7613//5670 7820//5666 7825//5668
+f 7820//5666 7612//5329 7944//5596
+f 7828//5671 7945//5597 7826//5672
+f 7620//5673 7823//5669 7828//5671
+f 7823//5669 7619//5171 7945//5597
+f 7831//5674 7946//5598 7829//5675
+f 7627//5676 7826//5672 7831//5674
+f 7826//5672 7626//5332 7946//5598
+f 7833//5677 7947//5599 7832//5678
+f 7634//5679 7829//5675 7833//5677
+f 7829//5675 7633//5179 7947//5599
+f 7837//5680 7948//5600 7835//5681
+f 7641//5682 7832//5678 7837//5680
+f 7832//5678 7640//5191 7948//5600
+f 7840//5683 7949//5601 7838//5684
+f 7648//5685 7835//5681 7840//5683
+f 7835//5681 7647//5193 7949//5601
+f 7843//5686 7950//5602 7841//5687
+f 7655//5688 7838//5684 7843//5686
+f 7838//5684 7654//5337 7950//5602
+f 7845//5689 7951//5603 7844//5690
+f 7662//5691 7841//5687 7845//5689
+f 7841//5687 7661//5202 7951//5603
+f 7849//5692 7952//5604 7847//5693
+f 7669//5694 7844//5690 7849//5692
+f 7844//5690 7668//5210 7952//5604
+f 7852//5695 7953//5605 7850//5696
+f 7676//5697 7847//5693 7852//5695
+f 7847//5693 7675//5217 7953//5605
+f 7855//5698 7954//5606 7853//5699
+f 7683//5700 7850//5696 7855//5698
+f 7850//5696 7682//5342 7954//5606
+f 7858//5701 7955//5607 7856//5702
+f 7690//5703 7853//5699 7858//5701
+f 7853//5699 7689//5224 7955//5607
+f 7861//5704 7956//5608 7859//5705
+f 7697//5706 7856//5702 7861//5704
+f 7856//5702 7696//5232 7956//5608
+f 7864//5707 7957//5609 7862//5708
+f 7704//5709 7859//5705 7864//5707
+f 7859//5705 7703//5240 7957//5609
+f 7867//5710 7958//5610 7865//5711
+f 7711//5712 7862//5708 7867//5710
+f 7862//5708 7710//5347 7958//5610
+f 7870//5713 7959//5611 7868//5714
+f 7718//5715 7865//5711 7870//5713
+f 7865//5711 7717//5247 7959//5611
+f 7873//5716 7960//5612 7871//5717
+f 7725//5718 7868//5714 7873//5716
+f 7868//5714 7724//5350 7960//5612
+f 7877//5719 7961//5613 7874//5720
+f 7732//5721 7871//5717 7877//5719
+f 7871//5717 7731//5261 7961//5613
+f 7880//5722 7962//5614 7878//5723
+f 7739//5724 7874//5720 7880//5722
+f 7874//5720 7738//5269 7962//5614
+f 7883//5725 7963//5615 7881//5726
+f 7747//5727 7878//5723 7883//5725
+f 7878//5723 7746//5354 7963//5615
+f 7885//5728 7964//5616 7884//5729
+f 7754//5730 7881//5726 7885//5728
+f 7881//5726 7753//5277 7964//5616
+f 7889//5731 7965//5617 7887//5732
+f 7761//5733 7884//5729 7889//5731
+f 7884//5729 7760//5357 7965//5617
+f 7892//5734 7966//5618 7890//5735
+f 7768//5736 7887//5732 7892//5734
+f 7887//5732 7767//5285 7966//5618
+f 7895//5737 7967//5619 7893//5738
+f 7775//5739 7890//5735 7895//5737
+f 7890//5735 7774//5292 7967//5619
+f 7897//5740 7968//5620 7896//5741
+f 7782//5742 7893//5738 7897//5740
+f 7893//5738 7781//5306 7968//5620
+f 7901//5743 7969//5621 7899//5744
+f 7789//5745 7896//5741 7901//5743
+f 7896//5741 7788//5362 7969//5621
+f 7904//5746 7970//5622 7902//5747
+f 7796//5748 7899//5744 7904//5746
+f 7899//5744 7795//5309 7970//5622
+f 7907//5749 7971//5623 7905//5750
+f 7803//5751 7902//5747 7907//5749
+f 7902//5747 7802//5315 7971//5623
+f 7909//5626 7816//5658 7599//5664
+f 7909//5626 7908//5625 7816//5658
+f 7908//5625 7592//5660 7816//5658
+f 7910//5627 7819//5662 7606//5667
+f 7910//5627 7909//5626 7819//5662
+f 7909//5626 7599//5664 7819//5662
+f 7911//5628 7821//5665 7613//5670
+f 7911//5628 7910//5627 7821//5665
+f 7910//5627 7606//5667 7821//5665
+f 7912//5629 7825//5668 7620//5673
+f 7912//5629 7911//5628 7825//5668
+f 7911//5628 7613//5670 7825//5668
+f 7913//5630 7828//5671 7627//5676
+f 7913//5630 7912//5629 7828//5671
+f 7912//5629 7620//5673 7828//5671
+f 7914//5631 7831//5674 7634//5679
+f 7914//5631 7913//5630 7831//5674
+f 7913//5630 7627//5676 7831//5674
+f 7915//5632 7833//5677 7641//5682
+f 7915//5632 7914//5631 7833//5677
+f 7914//5631 7634//5679 7833//5677
+f 7916//5633 7837//5680 7648//5685
+f 7916//5633 7915//5632 7837//5680
+f 7915//5632 7641//5682 7837//5680
+f 7917//5634 7840//5683 7655//5688
+f 7917//5634 7916//5633 7840//5683
+f 7916//5633 7648//5685 7840//5683
+f 7918//5635 7843//5686 7662//5691
+f 7918//5635 7917//5634 7843//5686
+f 7917//5634 7655//5688 7843//5686
+f 7919//5636 7845//5689 7669//5694
+f 7919//5636 7918//5635 7845//5689
+f 7918//5635 7662//5691 7845//5689
+f 7920//5637 7849//5692 7676//5697
+f 7920//5637 7919//5636 7849//5692
+f 7919//5636 7669//5694 7849//5692
+f 7921//5638 7852//5695 7683//5700
+f 7921//5638 7920//5637 7852//5695
+f 7920//5637 7676//5697 7852//5695
+f 7922//5639 7855//5698 7690//5703
+f 7922//5639 7921//5638 7855//5698
+f 7921//5638 7683//5700 7855//5698
+f 7923//5640 7858//5701 7697//5706
+f 7923//5640 7922//5639 7858//5701
+f 7922//5639 7690//5703 7858//5701
+f 7924//5641 7861//5704 7704//5709
+f 7924//5641 7923//5640 7861//5704
+f 7923//5640 7697//5706 7861//5704
+f 7925//5642 7864//5707 7711//5712
+f 7925//5642 7924//5641 7864//5707
+f 7924//5641 7704//5709 7864//5707
+f 7926//5643 7867//5710 7718//5715
+f 7926//5643 7925//5642 7867//5710
+f 7925//5642 7711//5712 7867//5710
+f 7927//5644 7870//5713 7725//5718
+f 7927//5644 7926//5643 7870//5713
+f 7926//5643 7718//5715 7870//5713
+f 7928//5645 7873//5716 7732//5721
+f 7928//5645 7927//5644 7873//5716
+f 7927//5644 7725//5718 7873//5716
+f 7875//5646 7877//5719 7739//5724
+f 7875//5646 7928//5645 7877//5719
+f 7928//5645 7732//5721 7877//5719
+f 7929//5647 7880//5722 7747//5727
+f 7929//5647 7875//5646 7880//5722
+f 7875//5646 7739//5724 7880//5722
+f 7930//5648 7883//5725 7754//5730
+f 7930//5648 7929//5647 7883//5725
+f 7929//5647 7747//5727 7883//5725
+f 7931//5649 7885//5728 7761//5733
+f 7931//5649 7930//5648 7885//5728
+f 7930//5648 7754//5730 7885//5728
+f 7932//5650 7889//5731 7768//5736
+f 7932//5650 7931//5649 7889//5731
+f 7931//5649 7761//5733 7889//5731
+f 7933//5651 7892//5734 7775//5739
+f 7933//5651 7932//5650 7892//5734
+f 7932//5650 7768//5736 7892//5734
+f 7934//5652 7895//5737 7782//5742
+f 7934//5652 7933//5651 7895//5737
+f 7933//5651 7775//5739 7895//5737
+f 7935//5653 7897//5740 7789//5745
+f 7935//5653 7934//5652 7897//5740
+f 7934//5652 7782//5742 7897//5740
+f 7936//5654 7901//5743 7796//5748
+f 7936//5654 7935//5653 7901//5743
+f 7935//5653 7789//5745 7901//5743
+f 7937//5655 7904//5746 7803//5751
+f 7937//5655 7936//5654 7904//5746
+f 7936//5654 7796//5748 7904//5746
+f 7938//5656 7907//5749 7810//5752
+f 7938//5656 7937//5655 7907//5749
+f 7937//5655 7803//5751 7907//5749
+f 7908//5625 7939//5753 7592//5660
+f 7908//5625 7938//5656 7939//5753
+f 7938//5656 7810//5752 7939//5753
+f 7939//5753 7972//5657 7813//5661
+f 7810//5752 7905//5750 7939//5753
+f 7905//5750 7809//5366 7972//5657
+f 7814//5659 7941//5593 7598//5156
+f 7817//5663 7942//5594 7605//5163
+f 7820//5666 7943//5595 7612//5329
+f 7823//5669 7944//5596 7619//5171
+f 7826//5672 7945//5597 7626//5332
+f 7829//5675 7946//5598 7633//5179
+f 7832//5678 7947//5599 7640//5191
+f 7835//5681 7948//5600 7647//5193
+f 7838//5684 7949//5601 7654//5337
+f 7841//5687 7950//5602 7661//5202
+f 7844//5690 7951//5603 7668//5210
+f 7847//5693 7952//5604 7675//5217
+f 7850//5696 7953//5605 7682//5342
+f 7853//5699 7954//5606 7689//5224
+f 7856//5702 7955//5607 7696//5232
+f 7859//5705 7956//5608 7703//5240
+f 7862//5708 7957//5609 7710//5347
+f 7865//5711 7958//5610 7717//5247
+f 7868//5714 7959//5611 7724//5350
+f 7871//5717 7960//5612 7731//5261
+f 7874//5720 7961//5613 7738//5269
+f 7878//5723 7962//5614 7746//5354
+f 7881//5726 7963//5615 7753//5277
+f 7884//5729 7964//5616 7760//5357
+f 7887//5732 7965//5617 7767//5285
+f 7890//5735 7966//5618 7774//5292
+f 7893//5738 7967//5619 7781//5306
+f 7896//5741 7968//5620 7788//5362
+f 7899//5744 7969//5621 7795//5309
+f 7902//5747 7970//5622 7802//5315
+f 7905//5750 7971//5623 7809//5366
+f 7813//5661 7972//5657 7591//5149
+f 7599//5664 7816//5658 7814//5659
+f 7813//5661 7941//5593 7816//5658
+f 7591//5149 7815//5326 7941//5593
+f 7606//5667 7819//5662 7817//5663
+f 7814//5659 7942//5594 7819//5662
+f 7598//5156 7818//5327 7942//5594
+f 7613//5670 7821//5665 7820//5666
+f 7817//5663 7943//5595 7821//5665
+f 7605//5163 7822//5328 7943//5595
+f 7620//5673 7825//5668 7823//5669
+f 7820//5666 7944//5596 7825//5668
+f 7612//5329 7824//5330 7944//5596
+f 7627//5676 7828//5671 7826//5672
+f 7823//5669 7945//5597 7828//5671
+f 7619//5171 7827//5331 7945//5597
+f 7634//5679 7831//5674 7829//5675
+f 7826//5672 7946//5598 7831//5674
+f 7626//5332 7830//5333 7946//5598
+f 7641//5682 7833//5677 7832//5678
+f 7829//5675 7947//5599 7833//5677
+f 7633//5179 7834//5334 7947//5599
+f 7648//5685 7837//5680 7835//5681
+f 7832//5678 7948//5600 7837//5680
+f 7640//5191 7836//5335 7948//5600
+f 7655//5688 7840//5683 7838//5684
+f 7835//5681 7949//5601 7840//5683
+f 7647//5193 7839//5336 7949//5601
+f 7662//5691 7843//5686 7841//5687
+f 7838//5684 7950//5602 7843//5686
+f 7654//5337 7842//5338 7950//5602
+f 7669//5694 7845//5689 7844//5690
+f 7841//5687 7951//5603 7845//5689
+f 7661//5202 7846//5339 7951//5603
+f 7676//5697 7849//5692 7847//5693
+f 7844//5690 7952//5604 7849//5692
+f 7668//5210 7848//5340 7952//5604
+f 7683//5700 7852//5695 7850//5696
+f 7847//5693 7953//5605 7852//5695
+f 7675//5217 7851//5341 7953//5605
+f 7690//5703 7855//5698 7853//5699
+f 7850//5696 7954//5606 7855//5698
+f 7682//5342 7854//5343 7954//5606
+f 7697//5706 7858//5701 7856//5702
+f 7853//5699 7955//5607 7858//5701
+f 7689//5224 7857//5344 7955//5607
+f 7704//5709 7861//5704 7859//5705
+f 7856//5702 7956//5608 7861//5704
+f 7696//5232 7860//5345 7956//5608
+f 7711//5712 7864//5707 7862//5708
+f 7859//5705 7957//5609 7864//5707
+f 7703//5240 7863//5346 7957//5609
+f 7718//5715 7867//5710 7865//5711
+f 7862//5708 7958//5610 7867//5710
+f 7710//5347 7866//5348 7958//5610
+f 7725//5718 7870//5713 7868//5714
+f 7865//5711 7959//5611 7870//5713
+f 7717//5247 7869//5349 7959//5611
+f 7732//5721 7873//5716 7871//5717
+f 7868//5714 7960//5612 7873//5716
+f 7724//5350 7872//5351 7960//5612
+f 7739//5724 7877//5719 7874//5720
+f 7871//5717 7961//5613 7877//5719
+f 7731//5261 7876//5352 7961//5613
+f 7747//5727 7880//5722 7878//5723
+f 7874//5720 7962//5614 7880//5722
+f 7738//5269 7879//5353 7962//5614
+f 7754//5730 7883//5725 7881//5726
+f 7878//5723 7963//5615 7883//5725
+f 7746//5354 7882//5355 7963//5615
+f 7761//5733 7885//5728 7884//5729
+f 7881//5726 7964//5616 7885//5728
+f 7753//5277 7886//5356 7964//5616
+f 7768//5736 7889//5731 7887//5732
+f 7884//5729 7965//5617 7889//5731
+f 7760//5357 7888//5358 7965//5617
+f 7775//5739 7892//5734 7890//5735
+f 7887//5732 7966//5618 7892//5734
+f 7767//5285 7891//5359 7966//5618
+f 7782//5742 7895//5737 7893//5738
+f 7890//5735 7967//5619 7895//5737
+f 7774//5292 7894//5360 7967//5619
+f 7789//5745 7897//5740 7896//5741
+f 7893//5738 7968//5620 7897//5740
+f 7781//5306 7898//5361 7968//5620
+f 7796//5748 7901//5743 7899//5744
+f 7896//5741 7969//5621 7901//5743
+f 7788//5362 7900//5363 7969//5621
+f 7803//5751 7904//5746 7902//5747
+f 7899//5744 7970//5622 7904//5746
+f 7795//5309 7903//5364 7970//5622
+f 7810//5752 7907//5749 7905//5750
+f 7902//5747 7971//5623 7907//5749
+f 7802//5315 7906//5365 7971//5623
+f 7592//5660 7939//5753 7813//5661
+f 7905//5750 7972//5657 7939//5753
+f 7809//5366 7940//5367 7972//5657
+l 7811 7812
+o Body_Sphere.002
+v 1.170026 0.251981 0.110623
+v 1.168350 0.409033 0.206367
+v 1.143010 0.551349 0.294090
+v 1.114024 0.673459 0.370420
+v 0.955484 0.770670 0.432424
+v 0.777509 0.839246 0.477720
+v 0.586939 0.876553 0.504566
+v -0.480150 0.831895 0.501455
+v -0.673737 0.803618 0.489056
+v -0.768059 0.743547 0.457369
+v -0.935192 0.653991 0.407613
+v -1.079141 0.538391 0.341698
+v -1.194375 0.401190 0.262159
+v -1.276466 0.247660 0.172051
+v -1.322257 0.083702 0.074839
+v 1.169478 0.268339 0.076058
+v 1.167277 0.441121 0.138565
+v 1.141450 0.597933 0.195657
+v 1.112040 0.732748 0.245138
+v 0.953150 0.840387 0.285108
+v 0.774916 0.916712 0.314031
+v 0.584186 0.958790 0.330795
+v -0.482956 0.915743 0.324280
+v -0.676490 0.885855 0.315285
+v -0.770652 0.821013 0.293681
+v -0.937526 0.723708 0.260297
+v -1.081126 0.597681 0.216416
+v -1.195935 0.447774 0.163726
+v -1.277540 0.279748 0.104249
+v -1.322805 0.100060 0.040274
+v 1.169391 0.277653 0.038965
+v 1.167106 0.459392 0.065805
+v 1.141203 0.624459 0.090026
+v 1.111725 0.766510 0.110696
+v 0.952780 0.880086 0.127021
+v 0.774505 0.960823 0.138373
+v 0.583750 1.005618 0.144318
+v -0.483401 0.963489 0.134150
+v -0.676926 0.932684 0.128808
+v -0.771063 0.865124 0.118023
+v -0.937896 0.763407 0.102209
+v -1.081441 0.631442 0.081974
+v -1.196182 0.474300 0.058095
+v -1.277710 0.298019 0.031490
+v -1.322891 0.109375 0.003181
+v 1.169769 0.279567 0.000770
+v 1.167847 0.463146 -0.009116
+v 1.142278 0.629908 -0.018743
+v 1.113093 0.773445 -0.027741
+v 0.954389 0.888242 -0.035764
+v 0.776292 0.969885 -0.042503
+v 0.585647 1.015238 -0.047700
+v -0.481466 0.973298 -0.061629
+v -0.675029 0.942304 -0.063209
+v -0.769276 0.874186 -0.062853
+v -0.936287 0.771563 -0.060576
+v -1.080073 0.638378 -0.056463
+v -1.195107 0.479749 -0.050675
+v -1.276970 0.301773 -0.043432
+v -1.322514 0.111288 -0.035014
+v 1.170596 0.274006 -0.037058
+v 1.169469 0.452237 -0.083320
+v 1.144634 0.614071 -0.126471
+v 1.116091 0.753289 -0.164852
+v 0.957914 0.864540 -0.196989
+v 0.780209 0.943549 -0.221647
+v 0.589806 0.987280 -0.237878
+v -0.477227 0.944792 -0.255534
+v -0.670871 0.914345 -0.253388
+v -0.765359 0.847849 -0.241998
+v -0.932762 0.747861 -0.221801
+v -1.077075 0.618221 -0.193574
+v -1.192752 0.463912 -0.158402
+v -1.275347 0.290864 -0.117636
+v -1.321687 0.105727 -0.072843
+v 1.171840 0.261183 -0.073068
+v 1.171911 0.427085 -0.153955
+v 1.148179 0.577556 -0.229017
+v 1.120603 0.706814 -0.295368
+v 0.963220 0.809891 -0.350460
+v 0.786105 0.882827 -0.392175
+v 0.594635 0.922509 -0.418819
+v -0.470858 0.879065 -0.440112
+v -0.664612 0.849883 -0.434419
+v -0.759463 0.787128 -0.412525
+v -0.927456 0.693212 -0.375272
+v -1.072562 0.571746 -0.324090
+v -1.189206 0.427397 -0.260948
+v -1.272905 0.265712 -0.188271
+v -1.320442 0.092905 -0.108852
+v 1.173456 0.241593 -0.105874
+v 1.175079 0.388657 -0.218306
+v 1.152778 0.521767 -0.322441
+v 1.126457 0.635808 -0.414274
+v 0.970103 0.726397 -0.490279
+v 0.793753 0.790052 -0.547533
+v 0.603244 0.824142 -0.583748
+v -0.141841 0.757556 -0.567727
+v -0.636989 0.753823 -0.599597
+v -0.753183 0.694974 -0.568368
+v -0.920573 0.609718 -0.515090
+v -1.066709 0.500740 -0.442996
+v -1.184607 0.371608 -0.354372
+v -1.269737 0.227284 -0.252622
+v -1.318827 0.073314 -0.141658
+v 1.175379 0.215987 -0.134216
+v 1.178851 0.338429 -0.273901
+v 1.158254 0.448847 -0.403152
+v 1.133427 0.542998 -0.517000
+v 0.978299 0.617264 -0.611071
+v 0.802860 0.668791 -0.681750
+v 0.613862 0.695602 -0.726323
+v -0.045623 0.621289 -0.682280
+v -0.501306 0.649655 -0.755550
+v -0.756130 0.580078 -0.708091
+v -0.912376 0.500585 -0.635882
+v -1.059739 0.407930 -0.545722
+v -1.179131 0.298688 -0.435083
+v -1.265965 0.177056 -0.308217
+v -1.316904 0.047708 -0.170000
+v 1.177536 0.185349 -0.157005
+v 1.183083 0.278331 -0.318603
+v 1.164397 0.361599 -0.468048
+v 1.141245 0.431952 -0.599598
+v 0.987493 0.486688 -0.708196
+v 0.813075 0.523703 -0.789670
+v 0.607618 0.536290 -0.831925
+v -0.016459 0.475452 -0.784209
+v -0.469195 0.511069 -0.903810
+v -0.816490 0.428845 -0.810804
+v -0.903183 0.370009 -0.733008
+v -1.051920 0.296884 -0.628320
+v -1.172988 0.211440 -0.499979
+v -1.261733 0.116958 -0.352918
+v -1.314747 0.017071 -0.192789
+v 1.179844 0.150858 -0.173364
+v 1.187611 0.210673 -0.350694
+v 1.170971 0.263375 -0.514637
+v 1.149612 0.306938 -0.658894
+v 0.997330 0.339686 -0.777921
+v 0.824003 0.360358 -0.867132
+v 0.466183 0.334358 -0.812978
+v -0.044104 0.313668 -0.867533
+v -0.488226 0.303455 -0.941785
+v -0.810803 0.264560 -0.887196
+v -0.893342 0.223005 -0.802724
+v -1.043554 0.171870 -0.687616
+v -1.166414 0.113216 -0.546568
+v -1.257206 0.049300 -0.385009
+v -1.312438 -0.017421 -0.209148
+v 1.182215 0.113837 -0.182667
+v 1.192261 0.138056 -0.368940
+v 1.177722 0.157951 -0.541127
+v 1.158205 0.172758 -0.692609
+v 1.007435 0.181908 -0.817567
+v 0.835030 0.184958 -0.910662
+v 0.450410 0.158526 -0.840500
+v -0.042604 0.136737 -0.867782
+v -0.553344 0.109950 -0.964634
+v -0.798504 0.088943 -0.927640
+v -0.883079 0.065187 -0.842022
+v -1.034961 0.037690 -0.721332
+v -1.159663 0.007792 -0.573058
+v -1.252555 -0.023317 -0.403256
+v -1.310068 -0.054441 -0.218451
+v 1.184557 0.075711 -0.184554
+v 1.196855 0.063269 -0.372642
+v 1.184392 0.049377 -0.546500
+v 1.166694 0.034570 -0.699448
+v 1.017383 0.019417 -0.825538
+v 0.844563 0.004561 -0.917578
+v 0.503968 -0.006608 -0.888890
+v 0.006670 -0.025496 -0.854412
+v -0.456641 -0.067888 -0.958529
+v -0.764428 -0.089275 -0.929270
+v -0.876402 -0.097433 -0.850188
+v -1.026453 -0.100495 -0.728142
+v -1.152993 -0.100782 -0.578431
+v -1.247961 -0.098104 -0.406957
+v -1.307725 -0.092567 -0.220337
+v 1.186780 0.037945 -0.178953
+v 1.201217 -0.010813 -0.361656
+v 1.190724 -0.058173 -0.530551
+v 1.174753 -0.102316 -0.679148
+v 1.026743 -0.141479 -0.801446
+v 0.851393 -0.172787 -0.887069
+v 0.532145 -0.182662 -0.887325
+v 0.058786 -0.176775 -0.830105
+v -0.369879 -0.239324 -0.908436
+v -0.680602 -0.263016 -0.898859
+v -0.871201 -0.260408 -0.830650
+v -1.021784 -0.238164 -0.710148
+v -1.146661 -0.208332 -0.562482
+v -1.243599 -0.172186 -0.395971
+v -1.305502 -0.130334 -0.214737
+v 1.188800 0.001989 -0.166080
+v 1.205178 -0.081343 -0.336404
+v 1.196475 -0.160567 -0.493891
+v 1.182072 -0.232639 -0.632490
+v 1.035221 -0.294568 -0.746381
+v 0.855982 -0.339241 -0.821388
+v 0.528492 -0.341555 -0.811172
+v 0.089816 -0.316378 -0.749180
+v -0.314099 -0.376406 -0.804710
+v -0.604131 -0.418183 -0.821949
+v -0.856762 -0.435491 -0.805552
+v -1.032427 -0.376249 -0.677646
+v -1.141438 -0.310852 -0.526033
+v -1.239638 -0.242716 -0.370719
+v -1.303483 -0.166290 -0.201864
+v 1.190538 -0.030775 -0.146429
+v 1.208587 -0.145612 -0.297857
+v 1.201423 -0.253870 -0.437930
+v 1.188371 -0.351391 -0.561265
+v 1.042584 -0.434072 -0.662626
+v 0.861424 -0.489870 -0.726461
+v 0.535224 -0.479332 -0.706059
+v 0.118240 -0.447841 -0.657629
+v -0.289889 -0.479721 -0.673794
+v -0.556585 -0.531586 -0.697052
+v -0.820025 -0.569757 -0.705469
+v -1.034142 -0.506114 -0.612872
+v -1.137452 -0.404445 -0.470328
+v -1.236230 -0.306984 -0.332173
+v -1.301745 -0.199053 -0.182213
+v 1.191927 -0.059087 -0.120755
+v 1.211312 -0.201148 -0.247497
+v 1.205380 -0.334496 -0.364818
+v 1.193406 -0.454009 -0.468211
+v 1.048613 -0.554800 -0.553429
+v 0.868724 -0.621876 -0.607199
+v 0.551781 -0.603082 -0.586171
+v 0.141882 -0.558404 -0.542041
+v -0.255361 -0.573527 -0.545677
+v -0.520518 -0.617642 -0.560960
+v -0.788935 -0.695637 -0.589723
+v -1.026482 -0.615123 -0.511853
+v -1.135105 -0.485933 -0.397545
+v -1.233504 -0.362521 -0.281813
+v -1.300355 -0.227366 -0.156539
+v 1.192914 -0.081860 -0.090046
+v 1.213249 -0.245818 -0.187258
+v 1.208191 -0.399347 -0.277365
+v 1.196985 -0.536548 -0.356905
+v 1.052972 -0.652048 -0.422758
+v 0.878573 -0.732351 -0.466904
+v 0.574862 -0.710197 -0.450470
+v 0.152302 -0.657719 -0.418195
+v -0.201642 -0.646087 -0.408551
+v -0.490517 -0.692532 -0.424318
+v -0.766150 -0.781431 -0.450915
+v -1.021193 -0.703857 -0.399212
+v -1.133385 -0.550988 -0.309953
+v -1.231568 -0.407191 -0.221574
+v -1.299368 -0.250138 -0.125830
+v 1.193462 -0.098218 -0.055481
+v 1.214323 -0.277905 -0.119456
+v 1.209751 -0.445931 -0.178932
+v 1.198969 -0.595838 -0.231623
+v 1.055364 -0.721857 -0.275500
+v 0.885055 -0.813473 -0.306814
+v 0.601112 -0.795985 -0.298868
+v 0.178243 -0.727458 -0.275527
+v -0.159195 -0.695518 -0.266070
+v -0.467766 -0.742134 -0.280394
+v -0.758102 -0.833252 -0.299626
+v -1.005275 -0.748882 -0.265650
+v -1.129849 -0.596890 -0.211123
+v -1.230493 -0.439278 -0.153772
+v -1.298820 -0.266496 -0.091265
+v 1.193549 -0.107533 -0.018388
+v 1.214493 -0.296177 -0.046697
+v 1.209998 -0.472457 -0.073302
+v 1.199284 -0.629600 -0.097181
+v 1.055739 -0.761566 -0.117416
+v 0.887365 -0.860117 -0.132756
+v 0.628538 -0.857493 -0.133145
+v 0.199313 -0.773585 -0.123536
+v -0.132514 -0.725518 -0.121035
+v -0.446784 -0.766974 -0.132601
+v -0.771414 -0.827424 -0.136850
+v -0.991911 -0.762915 -0.125202
+v -1.127415 -0.622549 -0.105222
+v -1.230323 -0.457550 -0.081012
+v -1.298734 -0.275811 -0.054172
+v 1.193171 -0.109446 0.019807
+v 1.213752 -0.299931 0.028225
+v 1.208923 -0.477907 0.035468
+v 1.197916 -0.636535 0.041256
+v 1.054131 -0.769721 0.045368
+v 0.886460 -0.870880 0.047565
+v 0.652570 -0.888116 0.044837
+v 0.216101 -0.789321 0.036283
+v -0.115915 -0.731150 0.027219
+v -0.429533 -0.764740 0.017879
+v -0.764277 -0.813153 0.014237
+v -0.991789 -0.766912 0.012182
+v -1.128355 -0.627948 0.003532
+v -1.231064 -0.461303 -0.006091
+v -1.299111 -0.277724 -0.015977
+v 1.192344 -0.103885 0.057636
+v 1.212130 -0.289022 0.102429
+v 1.206568 -0.462069 0.143195
+v 1.194918 -0.616378 0.178367
+v 1.050605 -0.746018 0.206594
+v 0.883054 -0.845665 0.226701
+v 0.663915 -0.876175 0.228465
+v 0.222684 -0.773574 0.198548
+v -0.112693 -0.712770 0.176470
+v -0.428049 -0.742911 0.168776
+v -0.757560 -0.792337 0.166993
+v -0.992496 -0.744249 0.148011
+v -1.130772 -0.612180 0.111253
+v -1.232686 -0.450395 0.068113
+v -1.299939 -0.272163 0.021851
+v 1.191099 -0.091063 0.093645
+v 1.209688 -0.263870 0.173064
+v 1.203023 -0.425554 0.245741
+v 1.190406 -0.569904 0.308883
+v 1.045299 -0.691370 0.360065
+v 0.877299 -0.785269 0.397311
+v 0.664523 -0.821507 0.406446
+v 0.217102 -0.727817 0.356521
+v -0.125261 -0.672088 0.322781
+v -0.447424 -0.713146 0.319925
+v -0.762455 -0.793627 0.325218
+v -1.001917 -0.706727 0.279637
+v -1.134504 -0.575787 0.213837
+v -1.235128 -0.425243 0.138748
+v -1.301183 -0.259341 0.057861
+v -1.329990 -0.084384 -0.025743
+v 1.189484 -0.071472 0.126451
+v 1.206520 -0.225441 0.237415
+v 1.198423 -0.369765 0.339164
+v 1.184552 -0.498897 0.427789
+v 1.038416 -0.607875 0.499883
+v 0.869659 -0.692513 0.552677
+v 0.660566 -0.730856 0.570304
+v 0.200657 -0.653684 0.504463
+v -0.149387 -0.609356 0.461289
+v -0.478713 -0.683345 0.478874
+v -0.789194 -0.747580 0.484899
+v -1.021586 -0.647070 0.405307
+v -1.139924 -0.520356 0.307494
+v -1.238296 -0.386814 0.203099
+v -1.302798 -0.239750 0.090667
+v 1.187561 -0.045866 0.154793
+v 1.202748 -0.175213 0.293010
+v 1.192947 -0.296845 0.419875
+v 1.177582 -0.406088 0.530515
+v 1.030220 -0.498743 0.620675
+v 0.860551 -0.571249 0.686893
+v 0.654934 -0.609524 0.714114
+v 0.176148 -0.551206 0.636425
+v -0.186749 -0.524303 0.590501
+v -0.515034 -0.613565 0.632753
+v -0.816389 -0.635426 0.617641
+v -1.033123 -0.550978 0.512622
+v -1.145560 -0.447451 0.388352
+v -1.242068 -0.336586 0.258694
+v -1.304721 -0.214144 0.119009
+v 1.185404 -0.015229 0.177582
+v 1.198516 -0.115116 0.337711
+v 1.186804 -0.209597 0.484772
+v 1.169764 -0.295042 0.613112
+v 1.021026 -0.368167 0.717800
+v 0.850337 -0.426162 0.794814
+v 0.648436 -0.461197 0.831559
+v 0.180867 -0.415546 0.736738
+v -0.236050 -0.423315 0.712625
+v -0.556370 -0.507463 0.775262
+v -0.851295 -0.506838 0.734483
+v -1.034265 -0.434724 0.591930
+v -1.150877 -0.359852 0.452968
+v -1.246300 -0.276489 0.303395
+v -1.306879 -0.183507 0.141797
+v 1.183095 0.019263 0.193941
+v 1.193989 -0.047458 0.369802
+v 1.180231 -0.111374 0.531361
+v 1.161397 -0.170027 0.672408
+v 1.011189 -0.221165 0.787525
+v 0.839405 -0.262822 0.872287
+v 0.644075 -0.291929 0.918848
+v 0.161990 -0.265251 0.802916
+v -0.307243 -0.298719 0.815489
+v -0.615181 -0.356512 0.876354
+v -0.878254 -0.344664 0.794119
+v -1.034928 -0.305863 0.645856
+v -1.157154 -0.261533 0.499429
+v -1.250827 -0.208831 0.335486
+v -1.309187 -0.149015 0.158157
+v 1.180725 0.056283 0.203243
+v 1.189338 0.025159 0.388049
+v 1.173479 -0.005949 0.557850
+v 1.152804 -0.035848 0.706124
+v 1.001085 -0.063387 0.827170
+v 0.828178 -0.087507 0.916338
+v 0.638413 -0.107237 0.969312
+v 0.130850 -0.107358 0.850958
+v -0.362991 -0.141709 0.872963
+v -0.672017 -0.177250 0.891682
+v -0.885841 -0.178825 0.799926
+v -1.040438 -0.170928 0.677456
+v -1.163906 -0.156109 0.525919
+v -1.255478 -0.136214 0.353733
+v -1.311558 -0.111995 0.167459
+v 1.178383 0.094409 0.205130
+v 1.184744 0.099946 0.391750
+v 1.166809 0.102624 0.563224
+v 1.144315 0.102340 0.712963
+v 0.991102 0.099105 0.835212
+v 0.817086 0.093044 0.925274
+v 0.628946 0.084388 0.979685
+v 0.100723 0.057570 0.856166
+v -0.401542 0.027638 0.895254
+v -0.728480 -0.002655 0.904905
+v -0.899573 -0.017574 0.810400
+v -1.048850 -0.032728 0.684241
+v -1.170576 -0.047535 0.531293
+v -1.260072 -0.061427 0.357434
+v -1.313900 -0.073869 0.169346
+v 1.176159 0.132176 0.199530
+v 1.180382 0.174028 0.380764
+v 1.160477 0.210174 0.547274
+v 1.136256 0.239226 0.692663
+v 0.981626 0.260066 0.811342
+v 0.806557 0.271894 0.898750
+v 0.617674 0.274235 0.951460
+v 0.063238 0.223971 0.839858
+v -0.455144 0.206294 0.901867
+v -0.740857 0.176476 0.879052
+v -0.909050 0.143387 0.786530
+v -1.056909 0.104158 0.663941
+v -1.176908 0.060015 0.515343
+v -1.264434 0.012655 0.346448
+v -1.316123 -0.036103 0.163745
+v 1.174140 0.168132 0.186656
+v 1.176421 0.244558 0.355512
+v 1.154727 0.312568 0.510615
+v 1.128937 0.369549 0.646004
+v 0.973019 0.413309 0.756477
+v 0.796993 0.442169 0.837788
+v 0.604243 0.454236 0.885228
+v 0.004683 0.393361 0.808195
+v -0.513573 0.399796 0.897164
+v -0.763628 0.349293 0.823998
+v -0.917657 0.296630 0.731665
+v -1.064229 0.234481 0.617282
+v -1.182659 0.162409 0.478684
+v -1.268395 0.083185 0.321196
+v -1.318143 -0.000147 0.150872
+v 1.200648 0.086226 0.010537
+v 1.172402 0.200896 0.167005
+v 1.173012 0.308826 0.316966
+v 1.149778 0.405871 0.454654
+v 1.122639 0.488301 0.574779
+v 0.965613 0.552947 0.672725
+v 0.788764 0.597326 0.744728
+v 0.588576 0.617843 0.785979
+v -0.127622 0.553786 0.736012
+v -0.626691 0.567583 0.801105
+v -0.794315 0.515991 0.743870
+v -0.925065 0.436268 0.647914
+v -1.070527 0.353233 0.546057
+v -1.187607 0.255712 0.422723
+v -1.271803 0.147454 0.282650
+v -1.319880 0.032617 0.131221
+v 1.171013 0.229208 0.141332
+v 1.170287 0.364363 0.266605
+v 1.145822 0.486498 0.381542
+v 1.117603 0.590918 0.481726
+v 0.959692 0.673613 0.563306
+v 0.782185 0.731402 0.623148
+v 0.589864 0.761636 0.658639
+v -0.473998 0.715069 0.658733
+v -0.664633 0.689706 0.643674
+v -0.766485 0.635908 0.602887
+v -0.930984 0.556934 0.538494
+v -1.075563 0.455851 0.453004
+v -1.191563 0.336338 0.349611
+v -1.274529 0.202990 0.232290
+v -1.321270 0.060929 0.105548
+vn -0.374462 0.791803 0.482437
+vn -0.096896 0.852321 0.513932
+vn -0.379284 0.870022 0.314890
+vn 0.830714 0.485824 0.271767
+vn 0.984283 0.160680 0.073092
+vn 0.983917 0.170660 0.052400
+vn -0.989471 0.112491 0.090701
+vn -0.942656 0.275948 0.187597
+vn -0.990051 0.129337 0.055086
+vn -0.555315 0.709464 0.433882
+vn 0.502792 0.746544 0.435713
+vn 0.829218 0.528428 0.181982
+vn -0.600574 0.679464 0.421430
+vn -0.602893 0.749321 0.273782
+vn 0.324931 0.814142 0.481185
+vn 0.322947 0.891842 0.316660
+vn -0.744346 0.564867 0.356120
+vn -0.746330 0.624409 0.230293
+vn 0.098239 0.853572 0.511582
+vn 0.095035 0.937407 0.335002
+vn 0.996216 0.082614 0.026032
+vn 0.996704 0.077548 0.023041
+vn 0.996643 0.079165 0.019532
+vn -0.859859 0.428663 0.277200
+vn -0.861446 0.475600 0.178014
+vn -0.099521 0.936430 0.336344
+vn 0.996155 0.084780 0.021546
+vn -0.943754 0.308451 0.118870
+vn -0.943937 0.326975 0.045106
+vn -0.379833 0.915098 0.135075
+vn 0.983856 0.176305 0.030091
+vn -0.990143 0.138951 0.016877
+vn -0.557329 0.779962 0.284555
+vn 0.500443 0.816401 0.288064
+vn 0.500076 0.856197 0.129612
+vn -0.603290 0.789117 0.115360
+vn 0.322520 0.936003 0.140812
+vn -0.746666 0.658315 0.095279
+vn 0.094607 0.984558 0.147191
+vn 0.996643 0.080111 0.015778
+vn -0.861690 0.502304 0.071566
+vn -0.099948 0.984161 0.146397
+vn 0.996124 0.086001 0.016663
+vn -0.860622 0.507797 -0.037996
+vn 0.096438 0.994263 -0.046205
+vn 0.984100 0.177313 0.007111
+vn -0.377453 0.924650 -0.050020
+vn 0.828974 0.552660 0.085604
+vn 0.830012 0.557543 -0.013642
+vn -0.943175 0.330790 -0.030793
+vn -0.557848 0.821162 0.120212
+vn -0.555620 0.829951 -0.048952
+vn -0.601672 0.797296 -0.047761
+vn 0.324320 0.945067 -0.040193
+vn -0.745293 0.665273 -0.043703
+vn 0.996185 0.086245 0.011658
+vn -0.742271 0.645039 -0.181402
+vn 0.100925 0.965789 -0.238838
+vn 0.996673 0.080325 0.011902
+vn 0.996307 0.085452 0.006714
+vn -0.858241 0.491836 -0.146519
+vn -0.098086 0.993957 -0.049196
+vn 0.984649 0.173711 -0.015534
+vn -0.941527 0.319742 -0.106021
+vn -0.372204 0.898251 -0.233528
+vn 0.832270 0.542924 -0.111881
+vn -0.989746 0.140904 -0.022431
+vn -0.988891 0.135197 -0.061403
+vn -0.550768 0.805994 -0.216742
+vn 0.501694 0.864376 -0.033509
+vn 0.505234 0.840602 -0.195105
+vn -0.598132 0.773522 -0.209357
+vn 0.327860 0.918729 -0.219977
+vn 0.510544 0.785852 -0.348918
+vn -0.592822 0.718772 -0.363170
+vn 0.332560 0.858425 -0.390484
+vn -0.737754 0.598376 -0.312479
+vn 0.105289 0.901059 -0.420698
+vn 0.996765 0.079806 0.008057
+vn 0.996460 0.083712 0.002045
+vn -0.093966 0.965453 -0.242958
+vn -0.099857 0.799524 -0.592242
+vn 0.985473 0.165624 -0.036927
+vn -0.854671 0.455061 -0.249855
+vn -0.340678 0.828852 -0.443709
+vn 0.835658 0.509384 -0.205298
+vn -0.987610 0.121982 -0.098483
+vn -0.536943 0.751122 -0.384014
+vn -0.038148 0.650563 -0.758476
+vn 0.840052 0.458266 -0.290262
+vn -0.939055 0.294229 -0.177618
+vn -0.985961 0.101779 -0.132298
+vn -0.264687 0.744194 -0.613239
+vn -0.588122 0.634327 -0.501694
+vn 0.517441 0.702170 -0.489059
+vn -0.731864 0.527055 -0.431898
+vn 0.340617 0.765465 -0.545885
+vn 0.996887 0.078555 0.004395
+vn 0.996673 0.081088 -0.002136
+vn -0.850032 0.398846 -0.343974
+vn 0.096255 0.797418 -0.595691
+vn 0.986541 0.153478 -0.056215
+vn -0.935850 0.255287 -0.242836
+vn -0.844508 0.325388 -0.425306
+vn 0.084933 0.645466 -0.759026
+vn 0.987793 0.137791 -0.072573
+vn -0.932035 0.204382 -0.299173
+vn -0.009064 0.612293 -0.790551
+vn 0.845302 0.391552 -0.363475
+vn -0.983978 0.075411 -0.161473
+vn -0.481857 0.692221 -0.537187
+vn -0.053896 0.769066 -0.636860
+vn 0.525651 0.592792 -0.610126
+vn -0.602557 0.519761 -0.605579
+vn 0.342418 0.638813 -0.688925
+vn 0.997040 0.076601 0.001007
+vn 0.996948 0.077700 -0.005737
+vn -0.724845 0.433851 -0.535081
+vn -0.677541 0.374004 -0.633259
+vn 0.103519 0.231452 -0.967315
+vn 0.997223 0.074038 -0.001923
+vn 0.997223 0.073672 -0.008576
+vn -0.838313 0.237465 -0.490707
+vn 0.989166 0.119327 -0.085421
+vn -0.927732 0.143468 -0.344493
+vn 0.019135 0.513871 -0.857631
+vn 0.851131 0.311930 -0.422163
+vn -0.981750 0.043855 -0.184973
+vn -0.442152 0.644002 -0.624256
+vn -0.569414 0.479659 -0.667562
+vn 0.534867 0.461898 -0.707450
+vn 0.266182 0.458602 -0.847804
+vn 0.544725 0.314585 -0.777337
+vn -0.695486 0.202673 -0.689322
+vn -0.717002 0.322336 -0.618030
+vn -0.708579 0.196783 -0.677602
+vn 0.011689 0.027253 -0.999542
+vn 0.997467 0.070956 -0.004334
+vn 0.997528 0.069185 -0.010559
+vn -0.831690 0.138493 -0.537645
+vn 0.099307 0.208991 -0.972839
+vn 0.990600 0.098788 -0.094302
+vn -0.923154 0.074892 -0.377026
+vn 0.002625 0.489303 -0.872066
+vn 0.020844 0.160680 -0.986755
+vn 0.857387 0.222449 -0.464064
+vn -0.979369 0.008332 -0.201819
+vn -0.506485 0.240120 -0.828120
+vn -0.025788 0.037629 -0.998932
+vn 0.863765 0.126591 -0.487655
+vn -0.976928 -0.029786 -0.211402
+vn -0.440474 0.059725 -0.895749
+vn 0.552660 0.154241 -0.818995
+vn -0.679556 0.067385 -0.730491
+vn 0.148991 0.335887 -0.930021
+vn -0.699423 0.061739 -0.712027
+vn -0.039399 0.206763 -0.977569
+vn 0.997681 0.067415 -0.006134
+vn 0.997833 0.064425 -0.011628
+vn 0.116916 0.000183 -0.993133
+vn 0.992096 0.077090 -0.098941
+vn -0.918424 0.001282 -0.395520
+vn -0.824885 0.032289 -0.564318
+vn -0.818140 -0.077120 -0.569781
+vn -0.047792 0.098483 -0.993988
+vn 0.993530 0.055025 -0.099277
+vn 0.067293 -0.084353 -0.994140
+vn 0.870022 0.028016 -0.492203
+vn -0.974517 -0.069063 -0.213324
+vn 0.064119 -0.114505 -0.991333
+vn -0.580645 -0.108310 -0.806909
+vn 0.149022 0.146641 -0.977874
+vn 0.184820 -0.040223 -0.981933
+vn -0.696280 -0.062716 -0.714988
+vn 0.997925 0.063601 -0.007202
+vn 0.998138 0.059572 -0.011719
+vn -0.697043 -0.116947 -0.707389
+vn 0.220588 -0.247017 -0.943541
+vn 0.998169 0.059633 -0.007477
+vn 0.998413 0.054811 -0.010895
+vn -0.828303 -0.157170 -0.537767
+vn -0.042360 -0.236274 -0.970733
+vn 0.994873 0.033479 -0.095340
+vn -0.913785 -0.074496 -0.399274
+vn -0.909360 -0.149571 -0.388134
+vn 0.041353 -0.322794 -0.945555
+vn 0.875729 -0.069643 -0.477706
+vn -0.972228 -0.107944 -0.207556
+vn -0.332499 -0.191137 -0.923521
+vn 0.103122 -0.396741 -0.912107
+vn 0.555406 -0.011780 -0.831446
+vn -0.162389 -0.368084 -0.915464
+vn -0.452315 -0.181341 -0.873196
+vn 0.038057 -0.573077 -0.818598
+vn 0.552324 -0.178899 -0.814173
+vn 0.210028 -0.430799 -0.877621
+vn -0.327464 -0.422651 -0.845027
+vn -0.081271 -0.515397 -0.853053
+vn 0.998413 0.055666 -0.006989
+vn 0.998688 0.050325 -0.009186
+vn -0.702872 -0.252235 -0.665059
+vn 0.996063 0.013184 -0.087405
+vn -0.905789 -0.220252 -0.361888
+vn 0.029267 -0.537767 -0.842555
+vn 0.880825 -0.162633 -0.444594
+vn -0.970153 -0.144993 -0.194311
+vn 0.134312 -0.645802 -0.751579
+vn 0.885372 -0.246895 -0.393811
+vn -0.968352 -0.178747 -0.174047
+vn 0.128208 -0.765648 -0.630299
+vn 0.549120 -0.333811 -0.766167
+vn 0.143864 -0.751610 -0.643696
+vn 0.549181 -0.482040 -0.682638
+vn -0.175512 -0.654378 -0.735496
+vn 0.187567 -0.594287 -0.782037
+vn 0.998627 0.051851 -0.005707
+vn 0.998901 0.046297 -0.006623
+vn -0.853938 -0.245888 -0.458571
+vn -0.670614 -0.441908 -0.595782
+vn -0.107700 -0.650716 -0.751610
+vn 0.997101 -0.005097 -0.075808
+vn -0.904141 -0.281625 -0.321207
+vn -0.011414 -0.662282 -0.749138
+vn -0.117283 -0.747246 -0.654073
+vn 0.997894 -0.020783 -0.060976
+vn -0.859615 -0.325175 -0.394055
+vn -0.854366 -0.394971 -0.337687
+vn -0.050935 -0.760033 -0.647847
+vn 0.889370 -0.319346 -0.327067
+vn -0.966918 -0.207923 -0.147618
+vn 0.099796 -0.824946 -0.556291
+vn 0.553301 -0.604297 -0.573229
+vn 0.204932 -0.808802 -0.551195
+vn -0.073000 -0.776666 -0.625629
+vn 0.180944 -0.718009 -0.672048
+vn 0.998810 0.048341 -0.003693
+vn 0.999054 0.042817 -0.003388
+vn -0.646107 -0.587115 -0.487625
+vn -0.019105 -0.898770 -0.437941
+vn 0.197272 -0.824274 -0.530686
+vn 0.998962 0.045289 -0.001007
+vn 0.999176 0.040010 0.000458
+vn -0.607379 -0.713370 -0.349498
+vn -0.115207 -0.834712 -0.538438
+vn 0.998474 -0.033357 -0.043519
+vn -0.903104 -0.336406 -0.266762
+vn -0.901120 -0.381298 -0.206275
+vn -0.082034 -0.850948 -0.518754
+vn 0.892331 -0.377514 -0.247353
+vn -0.965911 -0.231361 -0.115970
+vn 0.053468 -0.905911 -0.420026
+vn 0.568773 -0.696371 -0.437635
+vn 0.236244 -0.869198 -0.434339
+vn 0.231239 -0.933744 -0.273141
+vn 0.586627 -0.758263 -0.284341
+vn -0.017426 -0.984619 -0.173711
+vn 0.217109 -0.908811 -0.356212
+vn 0.999054 0.042848 0.002197
+vn 0.999237 0.038026 0.004761
+vn -0.853908 -0.457167 -0.248512
+vn -0.832453 -0.533799 -0.148473
+vn -0.106052 -0.912839 -0.394238
+vn 0.998810 -0.042390 -0.024049
+vn -0.128910 -0.931150 -0.341014
+vn 0.893887 -0.419416 -0.158147
+vn -0.897885 -0.417493 -0.139500
+vn 0.019929 -0.961455 -0.274148
+vn 0.894131 -0.443342 -0.062655
+vn -0.965331 -0.248207 -0.080386
+vn -0.965239 -0.257820 -0.042177
+vn -0.009186 -0.992706 -0.120182
+vn 0.596912 -0.793634 -0.117466
+vn 0.174871 -0.981048 -0.083041
+vn 0.245796 -0.955657 -0.162114
+vn -0.563860 -0.815821 -0.128208
+vn -0.516037 -0.856197 -0.024018
+vn 0.999115 0.041078 0.005860
+vn 0.999268 0.036866 0.009339
+vn -0.798791 -0.597980 -0.065584
+vn -0.085543 -0.968596 -0.233375
+vn 0.998840 -0.047578 -0.003204
+vn -0.165990 -0.971129 -0.171270
+vn -0.057222 -0.997742 -0.034883
+vn 0.999207 0.036622 0.014100
+vn -0.895840 -0.438978 -0.068789
+vn -0.785607 -0.618397 0.019715
+vn -0.195471 -0.980560 0.015503
+vn 0.998627 -0.048769 0.018189
+vn -0.965636 -0.259774 -0.002808
+vn -0.036744 -0.998199 0.047029
+vn 0.893124 -0.448347 0.035615
+vn -0.053377 -0.997528 0.045076
+vn 0.127384 -0.989074 0.074068
+vn 0.286538 -0.957549 0.030885
+vn -0.481368 -0.873867 0.067965
+vn 0.999146 0.040071 0.009827
+vn 0.999084 0.039888 0.013886
+vn -0.027955 -0.992798 0.116337
+vn -0.023347 -0.997650 0.063936
+vn 0.320963 -0.920042 0.224586
+vn 0.998993 0.040498 0.017914
+vn -0.787011 -0.604694 0.122166
+vn -0.038575 -0.981384 0.187994
+vn 0.999115 0.037263 0.018799
+vn -0.896512 -0.442946 0.006958
+vn -0.206641 -0.960448 0.186590
+vn 0.998138 -0.045900 0.039491
+vn -0.966491 -0.254067 0.036134
+vn -0.046693 -0.980499 0.190863
+vn 0.598987 -0.799341 0.046968
+vn 0.890927 -0.434187 0.133030
+vn 0.132786 -0.978179 0.159764
+vn -0.057192 -0.981994 0.179876
+vn 0.597552 -0.774041 0.209204
+vn 0.339274 -0.848323 0.406446
+vn -0.491562 -0.858241 0.147496
+vn 0.998871 0.041932 0.021729
+vn -0.565081 -0.786493 0.249062
+vn -0.021790 -0.920469 0.390179
+vn 0.998962 0.038789 0.023316
+vn -0.898312 -0.431593 0.082034
+vn -0.799982 -0.556658 0.223914
+vn -0.020203 -0.945341 0.325388
+vn 0.997436 -0.039033 0.059908
+vn -0.967772 -0.240852 0.073214
+vn 0.169836 -0.959868 0.223090
+vn 0.592792 -0.718802 0.363170
+vn -0.900967 -0.405744 0.153661
+vn -0.969451 -0.220679 0.106998
+vn 0.170904 -0.916013 0.362896
+vn 0.887600 -0.401379 0.225837
+vn 0.883297 -0.351177 0.310526
+vn -0.143468 -0.883145 0.446577
+vn 0.348155 -0.746879 0.566485
+vn -0.635243 -0.684622 0.357341
+vn 0.998688 0.044069 0.025178
+vn -0.824061 -0.487320 0.288766
+vn -0.203467 -0.917539 0.341594
+vn -0.189062 -0.843776 0.502243
+vn 0.998749 0.041169 0.027436
+vn -0.904904 -0.366100 0.217048
+vn 0.028748 -0.876370 0.480758
+vn 0.996460 -0.028382 0.078738
+vn 0.998505 0.044282 0.031068
+vn -0.838893 -0.393567 0.375927
+vn 0.070132 -0.790216 0.608753
+vn 0.995331 -0.014252 0.095279
+vn -0.971435 -0.194281 0.136204
+vn 0.132603 -0.823817 0.551073
+vn 0.585925 -0.635090 0.503311
+vn 0.577715 -0.525712 0.624378
+vn -0.249458 -0.730308 0.635884
+vn -0.677450 -0.511155 0.528886
+vn -0.000641 -0.823328 0.567522
+vn 0.354869 -0.618183 0.701315
+vn 0.998505 0.046815 0.028108
+vn -0.153081 -0.708701 0.688681
+vn 0.015046 -0.693136 0.720603
+vn 0.359874 -0.466201 0.808130
+vn 0.998260 0.050081 0.030427
+vn -0.712210 -0.368603 0.597339
+vn 0.015076 -0.534349 0.845119
+vn 0.998260 0.048097 0.034028
+vn -0.908902 -0.314097 0.274178
+vn -0.837275 -0.318339 0.444472
+vn 0.112522 -0.657094 0.745354
+vn 0.878140 -0.285440 0.383862
+vn 0.994049 0.002838 0.108890
+vn -0.973632 -0.162725 0.159673
+vn 0.079043 -0.651418 0.754570
+vn 0.872341 -0.206641 0.443007
+vn -0.379650 -0.543687 0.748466
+vn -0.475265 -0.251350 0.843135
+vn 0.568499 -0.394848 0.721702
+vn 0.558641 -0.247505 0.791589
+vn -0.732963 -0.233222 0.638997
+vn 0.366466 -0.297952 0.881405
+vn 0.998016 0.053743 0.032044
+vn -0.831690 -0.223701 0.508103
+vn -0.116092 -0.513871 0.849940
+vn -0.092380 -0.363811 0.926847
+vn 0.997955 0.052400 0.036225
+vn -0.912351 -0.254799 0.320383
+vn 0.122623 -0.418348 0.899960
+vn 0.992615 0.022370 0.118992
+vn -0.976012 -0.127201 0.176519
+vn -0.035859 -0.338450 0.940275
+vn -0.916684 -0.186743 0.353252
+vn -0.978454 -0.089053 0.186102
+vn -0.152043 -0.137059 0.978820
+vn 0.866146 -0.117771 0.485672
+vn 0.548509 -0.089358 0.831324
+vn -0.499710 -0.087191 0.861782
+vn -0.712699 -0.118076 0.691427
+vn 0.022614 -0.362712 0.931608
+vn 0.369549 -0.117771 0.921690
+vn 0.997772 0.057619 0.032899
+vn -0.083590 -0.177953 0.980468
+vn 0.997650 0.057070 0.037538
+vn -0.921384 -0.113132 0.371746
+vn 0.063601 -0.211982 0.975188
+vn 0.991150 0.043672 0.125126
+vn 0.997345 0.061953 0.037935
+vn -0.829279 -0.132756 0.542802
+vn -0.926054 -0.037324 0.375500
+vn 0.037690 -0.054811 0.997772
+vn 0.859767 -0.022187 0.510178
+vn 0.989685 0.065889 0.127018
+vn -0.980865 -0.049776 0.188055
+vn -0.245125 -0.018342 0.969298
+vn 0.538499 0.073458 0.839381
+vn -0.552080 -0.018647 0.833552
+vn 0.364238 0.066408 0.928922
+vn -0.711478 -0.011475 0.702597
+vn 0.031343 -0.158574 0.986847
+vn 0.997528 0.061586 0.033021
+vn -0.071932 0.012207 0.997314
+vn 0.029176 0.043703 0.998596
+vn 0.039552 0.239692 0.970031
+vn 0.997314 0.065462 0.032350
+vn -0.835902 -0.023438 0.548357
+vn -0.842280 0.084902 0.532273
+vn -0.048036 0.122135 0.991333
+vn 0.997040 0.066836 0.037324
+vn -0.930479 0.037751 0.364360
+vn -0.014863 0.022034 0.999634
+vn 0.853420 0.076388 0.515549
+vn 0.988281 0.088198 0.124454
+vn -0.983154 -0.010895 0.182287
+vn -0.287851 0.176611 0.941221
+vn 0.847407 0.174261 0.501480
+vn -0.576708 0.166082 0.799860
+vn 0.352794 0.248085 0.902188
+vn -0.722007 0.128758 0.679739
+vn -0.605853 0.304514 0.734947
+vn 0.529008 0.234779 0.815485
+vn 0.337230 0.419202 0.842891
+vn -0.729362 0.259651 0.632893
+vn 0.055849 0.427595 0.902219
+vn 0.997101 0.069124 0.030946
+vn -0.848079 0.188055 0.495346
+vn -0.022523 0.291757 0.956206
+vn 0.996765 0.071535 0.035768
+vn -0.934477 0.109226 0.338755
+vn -0.066775 0.265389 0.961821
+vn 0.986969 0.109684 0.117496
+vn -0.985260 0.026124 0.169042
+vn -0.423841 0.260079 0.867550
+vn 0.520371 0.388379 0.760491
+vn -0.987030 0.059877 0.148778
+vn -0.553056 0.497757 0.668050
+vn 0.841914 0.267617 0.468520
+vn 0.512955 0.528306 0.676534
+vn -0.643544 0.442030 0.624805
+vn 0.324656 0.574297 0.751488
+vn -0.735710 0.378918 0.561357
+vn 0.074831 0.583087 0.808924
+vn 0.996948 0.072420 0.028871
+vn -0.853053 0.282083 0.438978
+vn -0.013337 0.395398 0.918393
+vn 0.996551 0.075838 0.033326
+vn -0.937956 0.174383 0.299692
+vn -0.186468 0.593951 0.782556
+vn 0.985839 0.129490 0.106296
+vn -0.940703 0.230659 0.248634
+vn -0.325968 0.706595 0.628040
+vn 0.837184 0.352794 0.417859
+vn 0.984924 0.146733 0.091311
+vn -0.543962 0.651540 0.528703
+vn 0.507004 0.649251 0.566881
+vn 0.325358 0.705710 0.629353
+vn -0.599200 0.581439 0.550340
+vn 0.996796 0.075259 0.026185
+vn -0.857051 0.363323 0.365307
+vn -0.103153 0.562700 0.820154
+vn 0.996368 0.079592 0.030030
+vn -0.998047 -0.060671 -0.012879
+vn 0.998047 0.060671 0.012879
+vn -0.988464 0.089053 0.122349
+vn -0.740745 0.481979 0.467910
+vn 0.102420 0.732994 0.672445
+vn 0.833399 0.426496 0.351421
+usemtl Body
+s 1
+f 7981//5754 7980//5755 7996//5756
+f 7976//5757 7975//5758 7990//5759
+f 7987//5760 7986//5761 8002//5762
+f 7982//5763 7981//5754 7996//5756
+f 7977//5764 7976//5757 7991//5765
+f 7983//5766 7982//5763 7998//5767
+f 7978//5768 7977//5764 7993//5769
+f 7984//5770 7983//5766 7999//5771
+f 7979//5772 7978//5768 7994//5773
+f 7974//5774 7973//5775 7988//5776
+f 7985//5777 7984//5770 8000//5778
+f 7980//5755 7979//5772 7995//5779
+f 7975//5758 7974//5774 7989//5780
+f 7986//5761 7985//5777 8000//5778
+f 8001//5781 8000//5778 8016//5782
+f 7996//5756 7995//5779 8011//5783
+f 7991//5765 7990//5759 8005//5784
+f 8002//5762 8001//5781 8017//5785
+f 7997//5786 7996//5756 8011//5783
+f 7992//5787 7991//5765 8007//5788
+f 7998//5767 7997//5786 8013//5789
+f 7993//5769 7992//5787 8008//5790
+f 7999//5771 7998//5767 8014//5791
+f 7994//5773 7993//5769 8009//5792
+f 7989//5780 7988//5776 8003//5793
+f 8000//5778 7999//5771 8015//5794
+f 7995//5779 7994//5773 8010//5795
+f 7990//5759 7989//5780 8004//5796
+f 8015//5794 8014//5791 8030//5797
+f 8010//5795 8009//5792 8024//5798
+f 8005//5784 8004//5796 8020//5799
+f 8016//5782 8015//5794 8030//5797
+f 8011//5783 8010//5795 8026//5800
+f 8006//5801 8005//5784 8021//5802
+f 8017//5785 8016//5782 8031//5803
+f 8012//5804 8011//5783 8027//5805
+f 8007//5788 8006//5801 8021//5802
+f 8013//5789 8012//5804 8028//5806
+f 8008//5790 8007//5788 8023//5807
+f 8014//5791 8013//5789 8029//5808
+f 8009//5792 8008//5790 8024//5798
+f 8004//5796 8003//5793 8019//5809
+f 8029//5808 8028//5806 8044//5810
+f 8024//5798 8023//5807 8039//5811
+f 8019//5809 8018//5812 8034//5813
+f 8030//5797 8029//5808 8045//5814
+f 8025//5815 8024//5798 8039//5811
+f 8020//5799 8019//5809 8035//5816
+f 8031//5803 8030//5797 8046//5817
+f 8026//5800 8025//5815 8041//5818
+f 8021//5802 8020//5799 8036//5819
+f 8032//5820 8031//5803 8047//5821
+f 8027//5805 8026//5800 8042//5822
+f 8022//5823 8021//5802 8037//5824
+f 8028//5806 8027//5805 8043//5825
+f 8023//5807 8022//5823 8038//5826
+f 8037//5824 8036//5819 8052//5827
+f 8043//5825 8042//5822 8058//5828
+f 8038//5826 8037//5824 8053//5829
+f 8044//5810 8043//5825 8059//5830
+f 8039//5811 8038//5826 8054//5831
+f 8034//5813 8033//5832 8049//5833
+f 8045//5814 8044//5810 8059//5830
+f 8040//5834 8039//5811 8055//5835
+f 8035//5816 8034//5813 8050//5836
+f 8046//5817 8045//5814 8060//5837
+f 8041//5818 8040//5834 8056//5838
+f 8036//5819 8035//5816 8051//5839
+f 8047//5821 8046//5817 8062//5840
+f 8042//5822 8041//5818 8057//5841
+f 8056//5838 8055//5835 8070//5842
+f 8051//5839 8050//5836 8066//5843
+f 8062//5840 8061//5844 8077//5845
+f 8057//5841 8056//5838 8071//5846
+f 8052//5827 8051//5839 8066//5843
+f 8058//5828 8057//5841 8073//5847
+f 8053//5829 8052//5827 8067//5848
+f 8059//5830 8058//5828 8074//5849
+f 8054//5831 8053//5829 8068//5850
+f 8049//5833 8048//5851 8064//5852
+f 8060//5837 8059//5830 8075//5853
+f 8055//5835 8054//5831 8069//5854
+f 8050//5836 8049//5833 8065//5855
+f 8061//5844 8060//5837 8076//5856
+f 8075//5853 8074//5849 8090//5857
+f 8070//5842 8069//5854 8084//5858
+f 8065//5855 8064//5852 8080//5859
+f 8076//5856 8075//5853 8091//5860
+f 8071//5846 8070//5842 8085//5861
+f 8066//5843 8065//5855 8081//5862
+f 8077//5845 8076//5856 8092//5863
+f 8072//5864 8071//5846 8086//5865
+f 8067//5848 8066//5843 8082//5866
+f 8073//5847 8072//5864 8088//5867
+f 8068//5850 8067//5848 8083//5868
+f 8074//5849 8073//5847 8088//5867
+f 8069//5854 8068//5850 8083//5868
+f 8064//5852 8063//5869 8079//5870
+f 8089//5871 8088//5867 8103//5872
+f 8084//5858 8083//5868 8099//5873
+f 8079//5870 8078//5874 8094//5875
+f 8090//5857 8089//5871 8105//5876
+f 8085//5861 8084//5858 8099//5873
+f 8080//5859 8079//5870 8095//5877
+f 8091//5860 8090//5857 8106//5878
+f 8086//5865 8085//5861 8100//5879
+f 8081//5862 8080//5859 8096//5880
+f 8092//5863 8091//5860 8107//5881
+f 8087//5882 8086//5865 8102//5883
+f 8082//5866 8081//5862 8097//5884
+f 8088//5867 8087//5882 8103//5872
+f 8083//5868 8082//5866 8098//5885
+f 8097//5884 8096//5880 8112//5886
+f 8103//5872 8102//5883 8118//5887
+f 8098//5885 8097//5884 8112//5886
+f 8104//5888 8103//5872 8119//5889
+f 8099//5873 8098//5885 8114//5890
+f 8094//5875 8093//5891 8109//5892
+f 8105//5876 8104//5888 8120//5893
+f 8100//5879 8099//5873 8115//5894
+f 8095//5877 8094//5875 8110//5895
+f 8106//5878 8105//5876 8121//5896
+f 8101//5897 8100//5879 8116//5898
+f 8096//5880 8095//5877 8111//5899
+f 8107//5881 8106//5878 8122//5900
+f 8102//5883 8101//5897 8117//5901
+f 8116//5898 8115//5894 8131//5902
+f 8111//5899 8110//5895 8126//5903
+f 8122//5900 8121//5896 8137//5904
+f 8117//5901 8116//5898 8132//5905
+f 8112//5886 8111//5899 8127//5906
+f 8118//5887 8117//5901 8133//5907
+f 8113//5908 8112//5886 8127//5906
+f 8119//5889 8118//5887 8134//5909
+f 8114//5890 8113//5908 8129//5910
+f 8109//5892 8108//5911 8124//5912
+f 8120//5893 8119//5889 8134//5909
+f 8115//5894 8114//5890 8130//5913
+f 8110//5895 8109//5892 8125//5914
+f 8121//5896 8120//5893 8136//5915
+f 8135//5916 8134//5909 8150//5917
+f 8130//5913 8129//5910 8144//5918
+f 8125//5914 8124//5912 8140//5919
+f 8136//5915 8135//5916 8150//5917
+f 8131//5902 8130//5913 8145//5920
+f 8126//5903 8125//5914 8141//5921
+f 8137//5904 8136//5915 8152//5922
+f 8132//5905 8131//5902 8146//5923
+f 8127//5906 8126//5903 8141//5921
+f 8133//5907 8132//5905 8148//5924
+f 8128//5925 8127//5906 8143//5926
+f 8134//5909 8133//5907 8149//5927
+f 8129//5910 8128//5925 8143//5926
+f 8124//5912 8123//5928 8139//5929
+f 8149//5927 8148//5924 8164//5930
+f 8144//5918 8143//5926 8158//5931
+f 8139//5929 8138//5932 8154//5933
+f 8150//5917 8149//5927 8165//5934
+f 8145//5920 8144//5918 8159//5935
+f 8140//5919 8139//5929 8155//5936
+f 8151//5937 8150//5917 8166//5938
+f 8146//5923 8145//5920 8160//5939
+f 8141//5921 8140//5919 8156//5940
+f 8152//5922 8151//5937 8167//5941
+f 8147//5942 8146//5923 8161//5943
+f 8142//5944 8141//5921 8156//5940
+f 8148//5924 8147//5942 8162//5945
+f 8143//5926 8142//5944 8158//5931
+f 8163//5946 8162//5945 8177//5947
+f 8158//5931 8157//5948 8173//5949
+f 8164//5930 8163//5946 8178//5950
+f 8159//5935 8158//5931 8174//5951
+f 8154//5933 8153//5952 8169//5953
+f 8165//5934 8164//5930 8179//5954
+f 8160//5939 8159//5935 8174//5951
+f 8155//5936 8154//5933 8170//5955
+f 8166//5938 8165//5934 8181//5956
+f 8161//5943 8160//5939 8175//5957
+f 8156//5940 8155//5936 8171//5958
+f 8167//5941 8166//5938 8182//5959
+f 8162//5945 8161//5943 8176//5960
+f 8157//5948 8156//5940 8171//5958
+f 8171//5958 8170//5955 8186//5961
+f 8182//5959 8181//5956 8197//5962
+f 8177//5947 8176//5960 8191//5963
+f 8172//5964 8171//5958 8186//5961
+f 8178//5950 8177//5947 8192//5965
+f 8173//5949 8172//5964 8187//5966
+f 8179//5954 8178//5950 8193//5967
+f 8174//5951 8173//5949 8188//5968
+f 8169//5953 8168//5969 8184//5970
+f 8180//5971 8179//5954 8194//5972
+f 8175//5957 8174//5951 8189//5973
+f 8170//5955 8169//5953 8185//5974
+f 8181//5956 8180//5971 8196//5975
+f 8176//5960 8175//5957 8190//5976
+f 8190//5976 8189//5973 8204//5977
+f 8185//5974 8184//5970 8200//5978
+f 8196//5975 8195//5979 8210//5980
+f 8191//5963 8190//5976 8205//5981
+f 8186//5961 8185//5974 8201//5982
+f 8197//5962 8196//5975 8212//5983
+f 8192//5965 8191//5963 8206//5984
+f 8187//5966 8186//5961 8202//5985
+f 8193//5967 8192//5965 8207//5986
+f 8188//5968 8187//5966 8202//5985
+f 8194//5972 8193//5967 8208//5987
+f 8189//5973 8188//5968 8203//5988
+f 8184//5970 8183//5989 8199//5990
+f 8195//5979 8194//5972 8209//5991
+f 8209//5991 8208//5987 8223//5992
+f 8204//5977 8203//5988 8218//5993
+f 8199//5990 8198//5994 8214//5995
+f 8210//5980 8209//5991 8224//5996
+f 8205//5981 8204//5977 8219//5997
+f 8200//5978 8199//5990 8215//5998
+f 8211//5999 8210//5980 8226//6000
+f 8206//5984 8205//5981 8220//6001
+f 8201//5982 8200//5978 8216//6002
+f 8212//5983 8211//5999 8227//6003
+f 8207//5986 8206//5984 8221//6004
+f 8202//5985 8201//5982 8217//6005
+f 8208//5987 8207//5986 8222//6006
+f 8203//5988 8202//5985 8217//6005
+f 8223//5992 8222//6006 8237//6007
+f 8218//5993 8217//6005 8232//6008
+f 8224//5996 8223//5992 8238//6009
+f 8219//5997 8218//5993 8233//6010
+f 8214//5995 8213//6011 8229//6012
+f 8225//6013 8224//5996 8240//6014
+f 8220//6001 8219//5997 8234//6015
+f 8215//5998 8214//5995 8230//6016
+f 8226//6000 8225//6013 8240//6014
+f 8221//6004 8220//6001 8235//6017
+f 8216//6002 8215//5998 8231//6018
+f 8227//6003 8226//6000 8241//6019
+f 8222//6006 8221//6004 8236//6020
+f 8217//6005 8216//6002 8232//6008
+f 8231//6018 8230//6016 8246//6021
+f 8242//6022 8241//6019 8257//6023
+f 8237//6007 8236//6020 8251//6024
+f 8232//6008 8231//6018 8247//6025
+f 8238//6009 8237//6007 8252//6026
+f 8233//6010 8232//6008 8248//6027
+f 8239//6028 8238//6009 8254//6029
+f 8234//6015 8233//6010 8248//6027
+f 8229//6012 8228//6030 8244//6031
+f 8240//6014 8239//6028 8255//6032
+f 8235//6017 8234//6015 8249//6033
+f 8230//6016 8229//6012 8245//6034
+f 8241//6019 8240//6014 8255//6032
+f 8236//6020 8235//6017 8250//6035
+f 8250//6035 8249//6033 8264//6036
+f 8245//6034 8244//6031 8259//6037
+f 8256//6038 8255//6032 8270//6039
+f 8251//6024 8250//6035 8265//6040
+f 8246//6021 8245//6034 8260//6041
+f 8257//6023 8256//6038 8272//6042
+f 8252//6026 8251//6024 8266//6043
+f 8247//6025 8246//6021 8261//6044
+f 8253//6045 8252//6026 8267//6046
+f 8248//6027 8247//6025 8263//6047
+f 8254//6029 8253//6045 8269//6048
+f 8249//6033 8248//6027 8263//6047
+f 8244//6031 8243//6049 8258//6050
+f 8255//6032 8254//6029 8270//6039
+f 8269//6048 8268//6051 8283//6052
+f 8264//6036 8263//6047 8278//6053
+f 8259//6037 8258//6050 8273//6054
+f 8270//6039 8269//6048 8285//6055
+f 8265//6040 8264//6036 8279//6056
+f 8260//6041 8259//6037 8274//6057
+f 8271//6058 8270//6039 8285//6055
+f 8266//6043 8265//6040 8280//6059
+f 8261//6044 8260//6041 8275//6060
+f 8272//6042 8271//6058 8287//6061
+f 8267//6046 8266//6043 8281//6062
+f 8262//6063 8261//6044 8276//6064
+f 8268//6051 8267//6046 8282//6065
+f 8263//6047 8262//6063 8278//6053
+f 8283//6052 8282//6065 8298//6066
+f 8278//6053 8277//6067 8293//6068
+f 8284//6069 8283//6052 8298//6066
+f 8279//6056 8278//6053 8293//6068
+f 8274//6057 8273//6054 8288//6070
+f 8285//6055 8284//6069 8299//6071
+f 8280//6059 8279//6056 8294//6072
+f 8275//6060 8274//6057 8289//6073
+f 8286//6074 8285//6055 8300//6075
+f 8281//6062 8280//6059 8296//6076
+f 8276//6064 8275//6060 8290//6077
+f 8287//6061 8286//6074 8302//6078
+f 8282//6065 8281//6062 8297//6079
+f 8277//6067 8276//6064 8292//6080
+f 8302//6078 8301//6081 8318//6082
+f 8297//6079 8296//6076 8313//6083
+f 8292//6080 8291//6084 8307//6085
+f 8298//6066 8297//6079 8314//6086
+f 8293//6068 8292//6080 8309//6087
+f 8299//6071 8298//6066 8315//6088
+f 8294//6072 8293//6068 8309//6087
+f 8289//6073 8288//6070 8304//6089
+f 8300//6075 8299//6071 8316//6090
+f 8295//6091 8294//6072 8311//6092
+f 8290//6077 8289//6073 8305//6093
+f 8301//6081 8300//6075 8317//6094
+f 8296//6076 8295//6091 8312//6095
+f 8291//6084 8290//6077 8306//6096
+f 8306//6096 8305//6093 8320//6097
+f 8317//6094 8316//6090 8331//6098
+f 8312//6095 8311//6092 8327//6099
+f 8307//6085 8306//6096 8321//6100
+f 8318//6082 8317//6094 8333//6101
+f 8313//6083 8312//6095 8328//6102
+f 8308//6103 8307//6085 8323//6104
+f 8314//6086 8313//6083 8329//6105
+f 8309//6087 8308//6103 8323//6104
+f 8315//6088 8314//6086 8330//6106
+f 8310//6107 8309//6087 8324//6108
+f 8305//6093 8304//6089 8319//6109
+f 8316//6090 8315//6088 8331//6098
+f 8311//6092 8310//6107 8326//6110
+f 8325//6111 8324//6108 8339//6112
+f 8320//6097 8319//6109 8334//6113
+f 8331//6098 8330//6106 8345//6114
+f 8326//6110 8325//6111 8340//6115
+f 8321//6100 8320//6097 8335//6116
+f 8332//6117 8331//6098 8346//6118
+f 8327//6099 8326//6110 8342//6119
+f 8322//6120 8321//6100 8336//6121
+f 8333//6101 8332//6117 8348//6122
+f 8328//6102 8327//6099 8343//6123
+f 8323//6104 8322//6120 8337//6124
+f 8329//6105 8328//6102 8344//6125
+f 8324//6108 8323//6104 8339//6112
+f 8330//6106 8329//6105 8345//6114
+f 8344//6125 8343//6123 8359//6126
+f 8339//6112 8338//6127 8353//6128
+f 8345//6114 8344//6125 8360//6129
+f 8340//6115 8339//6112 8354//6130
+f 8335//6116 8334//6113 8349//6131
+f 8346//6118 8345//6114 8361//6132
+f 8341//6133 8340//6115 8356//6134
+f 8336//6121 8335//6116 8350//6135
+f 8347//6136 8346//6118 8361//6132
+f 8342//6119 8341//6133 8357//6137
+f 8337//6124 8336//6121 8351//6138
+f 8348//6122 8347//6136 8363//6139
+f 8343//6123 8342//6119 8358//6140
+f 8338//6127 8337//6124 8353//6128
+f 8363//6139 8362//6141 8378//6142
+f 8358//6140 8357//6137 8373//6143
+f 8353//6128 8352//6144 8368//6145
+f 8359//6126 8358//6140 8374//6146
+f 8354//6130 8353//6128 8368//6145
+f 8360//6129 8359//6126 8375//6147
+f 8355//6148 8354//6130 8369//6149
+f 8350//6135 8349//6131 8364//6150
+f 8361//6132 8360//6129 8375//6147
+f 8356//6134 8355//6148 8371//6151
+f 8351//6138 8350//6135 8365//6152
+f 8362//6141 8361//6132 8377//6153
+f 8357//6137 8356//6134 8372//6154
+f 8352//6144 8351//6138 8366//6155
+f 8366//6155 8365//6152 8380//6156
+f 8377//6153 8376//6157 8392//6158
+f 8372//6154 8371//6151 8387//6159
+f 8367//6160 8366//6155 8381//6161
+f 8378//6142 8377//6153 8393//6162
+f 8373//6143 8372//6154 8388//6163
+f 8368//6145 8367//6160 8383//6164
+f 8374//6146 8373//6143 8389//6165
+f 8369//6149 8368//6145 8384//6166
+f 8375//6147 8374//6146 8390//6167
+f 8370//6168 8369//6149 8384//6166
+f 8365//6152 8364//6150 8379//6169
+f 8376//6157 8375//6147 8390//6167
+f 8371//6151 8370//6168 8386//6170
+f 8385//6171 8384//6166 8400//6172
+f 8380//6156 8379//6169 8394//6173
+f 8391//6174 8390//6167 8406//6175
+f 8386//6170 8385//6171 8401//6176
+f 8381//6161 8380//6156 8395//6177
+f 8392//6158 8391//6174 8407//6178
+f 8387//6159 8386//6170 8402//6179
+f 8382//6180 8381//6161 8396//6181
+f 8393//6162 8392//6158 8408//6182
+f 8388//6163 8387//6159 8403//6183
+f 8383//6164 8382//6180 8397//6184
+f 8389//6165 8388//6163 8404//6185
+f 8384//6166 8383//6164 8399//6186
+f 8390//6167 8389//6165 8405//6187
+f 8404//6185 8403//6183 8419//6188
+f 8399//6186 8398//6189 8414//6190
+f 8405//6187 8404//6185 8420//6191
+f 8400//6172 8399//6186 8415//6192
+f 8395//6177 8394//6173 8409//6193
+f 8406//6175 8405//6187 8421//6194
+f 8401//6176 8400//6172 8416//6195
+f 8396//6181 8395//6177 8410//6196
+f 8407//6178 8406//6175 8422//6197
+f 8402//6179 8401//6176 8417//6198
+f 8397//6184 8396//6181 8411//6199
+f 8408//6182 8407//6178 8423//6200
+f 8403//6183 8402//6179 8418//6201
+f 8398//6189 8397//6184 8413//6202
+f 8423//6200 8422//6197 8439//6203
+f 8418//6201 8417//6198 8434//6204
+f 8413//6202 8412//6205 8429//6206
+f 8419//6188 8418//6201 8435//6207
+f 8414//6190 8413//6202 8430//6208
+f 8420//6191 8419//6188 8436//6209
+f 8415//6192 8414//6190 8431//6210
+f 8410//6196 8409//6193 8425//6211
+f 8421//6194 8420//6191 8437//6212
+f 8416//6195 8415//6192 8432//6213
+f 8411//6199 8410//6196 8426//6214
+f 8422//6197 8421//6194 8438//6215
+f 8417//6198 8416//6195 8433//6216
+f 8412//6205 8411//6199 8427//6217
+f 8438//6215 8437//6212 8453//6218
+f 8433//6216 8432//6213 8448//6219
+f 8428//6220 8427//6217 8442//6221
+f 8439//6203 8438//6215 8453//6218
+f 8434//6204 8433//6216 8449//6222
+f 8429//6206 8428//6220 8444//6223
+f 8435//6207 8434//6204 8449//6222
+f 8430//6208 8429//6206 8445//6224
+f 8436//6209 8435//6207 8450//6225
+f 8431//6210 8430//6208 8445//6224
+f 8426//6214 8425//6211 8440//6226
+f 8437//6212 8436//6209 8452//6227
+f 8432//6213 8431//6210 8447//6228
+f 8427//6217 8426//6214 8441//6229
+f 8303//6230 7987//5760 8002//5762
+f 7973//5775 8424//6231 7988//5776
+f 8303//6230 8002//5762 8017//5785
+f 7988//5776 8424//6231 8003//5793
+f 8303//6230 8017//5785 8032//5820
+f 8003//5793 8424//6231 8018//5812
+f 8018//5812 8424//6231 8033//5832
+f 8303//6230 8032//5820 8047//5821
+f 8303//6230 8047//5821 8062//5840
+f 8033//5832 8424//6231 8048//5851
+f 8303//6230 8062//5840 8077//5845
+f 8048//5851 8424//6231 8063//5869
+f 8303//6230 8077//5845 8092//5863
+f 8063//5869 8424//6231 8078//5874
+f 8078//5874 8424//6231 8093//5891
+f 8303//6230 8092//5863 8107//5881
+f 8303//6230 8107//5881 8122//5900
+f 8093//5891 8424//6231 8108//5911
+f 8303//6230 8122//5900 8137//5904
+f 8108//5911 8424//6231 8123//5928
+f 8303//6230 8137//5904 8152//5922
+f 8123//5928 8424//6231 8138//5932
+f 8303//6230 8152//5922 8167//5941
+f 8138//5932 8424//6231 8153//5952
+f 8303//6230 8167//5941 8182//5959
+f 8153//5952 8424//6231 8168//5969
+f 8303//6230 8182//5959 8197//5962
+f 8168//5969 8424//6231 8183//5989
+f 8303//6230 8197//5962 8212//5983
+f 8183//5989 8424//6231 8198//5994
+f 8303//6230 8212//5983 8227//6003
+f 8198//5994 8424//6231 8213//6011
+f 8303//6230 8227//6003 8242//6022
+f 8213//6011 8424//6231 8228//6030
+f 8303//6230 8242//6022 8257//6023
+f 8228//6030 8424//6231 8243//6049
+f 8303//6230 8257//6023 8272//6042
+f 8243//6049 8424//6231 8258//6050
+f 8303//6230 8272//6042 8287//6061
+f 8258//6050 8424//6231 8273//6054
+f 8303//6230 8287//6061 8302//6078
+f 8273//6054 8424//6231 8288//6070
+f 8303//6230 8302//6078 8318//6082
+f 8288//6070 8424//6231 8304//6089
+f 8303//6230 8318//6082 8333//6101
+f 8304//6089 8424//6231 8319//6109
+f 8303//6230 8333//6101 8348//6122
+f 8319//6109 8424//6231 8334//6113
+f 8334//6113 8424//6231 8349//6131
+f 8303//6230 8348//6122 8363//6139
+f 8303//6230 8363//6139 8378//6142
+f 8349//6131 8424//6231 8364//6150
+f 8303//6230 8378//6142 8393//6162
+f 8364//6150 8424//6231 8379//6169
+f 8303//6230 8393//6162 8408//6182
+f 8379//6169 8424//6231 8394//6173
+f 8394//6173 8424//6231 8409//6193
+f 8303//6230 8408//6182 8423//6200
+f 8303//6230 8423//6200 8439//6203
+f 8409//6193 8424//6231 8425//6211
+f 8303//6230 8439//6203 8454//6232
+f 8425//6211 8424//6231 8440//6226
+f 8441//6229 8440//6226 7973//5775
+f 8452//6227 8451//6233 7984//5770
+f 8447//6228 8446//6234 7979//5772
+f 8442//6221 8441//6229 7974//5774
+f 8453//6218 8452//6227 7985//5777
+f 8448//6219 8447//6228 7981//5754
+f 8443//6235 8442//6221 7975//5758
+f 8454//6232 8453//6218 7986//5761
+f 8449//6222 8448//6219 7981//5754
+f 8444//6223 8443//6235 7977//5764
+f 8303//6230 8454//6232 7987//5760
+f 8450//6225 8449//6222 7982//5763
+f 8445//6224 8444//6223 7978//5768
+f 8440//6226 8424//6231 7973//5775
+f 8451//6233 8450//6225 7983//5766
+f 8446//6234 8445//6224 7978//5768
+f 7980//5755 7995//5779 7996//5756
+f 7991//5765 7976//5757 7990//5759
+f 7986//5761 8001//5781 8002//5762
+f 7997//5786 7982//5763 7996//5756
+f 7992//5787 7977//5764 7991//5765
+f 7982//5763 7997//5786 7998//5767
+f 7977//5764 7992//5787 7993//5769
+f 7983//5766 7998//5767 7999//5771
+f 7978//5768 7993//5769 7994//5773
+f 7989//5780 7974//5774 7988//5776
+f 7984//5770 7999//5771 8000//5778
+f 7979//5772 7994//5773 7995//5779
+f 7990//5759 7975//5758 7989//5780
+f 8001//5781 7986//5761 8000//5778
+f 8000//5778 8015//5794 8016//5782
+f 7995//5779 8010//5795 8011//5783
+f 8006//5801 7991//5765 8005//5784
+f 8001//5781 8016//5782 8017//5785
+f 8012//5804 7997//5786 8011//5783
+f 7991//5765 8006//5801 8007//5788
+f 7997//5786 8012//5804 8013//5789
+f 7992//5787 8007//5788 8008//5790
+f 7998//5767 8013//5789 8014//5791
+f 7993//5769 8008//5790 8009//5792
+f 8004//5796 7989//5780 8003//5793
+f 7999//5771 8014//5791 8015//5794
+f 7994//5773 8009//5792 8010//5795
+f 8005//5784 7990//5759 8004//5796
+f 8014//5791 8029//5808 8030//5797
+f 8025//5815 8010//5795 8024//5798
+f 8004//5796 8019//5809 8020//5799
+f 8031//5803 8016//5782 8030//5797
+f 8010//5795 8025//5815 8026//5800
+f 8005//5784 8020//5799 8021//5802
+f 8032//5820 8017//5785 8031//5803
+f 8011//5783 8026//5800 8027//5805
+f 8022//5823 8007//5788 8021//5802
+f 8012//5804 8027//5805 8028//5806
+f 8007//5788 8022//5823 8023//5807
+f 8013//5789 8028//5806 8029//5808
+f 8008//5790 8023//5807 8024//5798
+f 8003//5793 8018//5812 8019//5809
+f 8028//5806 8043//5825 8044//5810
+f 8023//5807 8038//5826 8039//5811
+f 8018//5812 8033//5832 8034//5813
+f 8029//5808 8044//5810 8045//5814
+f 8040//5834 8025//5815 8039//5811
+f 8019//5809 8034//5813 8035//5816
+f 8030//5797 8045//5814 8046//5817
+f 8025//5815 8040//5834 8041//5818
+f 8020//5799 8035//5816 8036//5819
+f 8031//5803 8046//5817 8047//5821
+f 8026//5800 8041//5818 8042//5822
+f 8021//5802 8036//5819 8037//5824
+f 8027//5805 8042//5822 8043//5825
+f 8022//5823 8037//5824 8038//5826
+f 8036//5819 8051//5839 8052//5827
+f 8042//5822 8057//5841 8058//5828
+f 8037//5824 8052//5827 8053//5829
+f 8043//5825 8058//5828 8059//5830
+f 8038//5826 8053//5829 8054//5831
+f 8033//5832 8048//5851 8049//5833
+f 8060//5837 8045//5814 8059//5830
+f 8039//5811 8054//5831 8055//5835
+f 8034//5813 8049//5833 8050//5836
+f 8061//5844 8046//5817 8060//5837
+f 8040//5834 8055//5835 8056//5838
+f 8035//5816 8050//5836 8051//5839
+f 8046//5817 8061//5844 8062//5840
+f 8041//5818 8056//5838 8057//5841
+f 8071//5846 8056//5838 8070//5842
+f 8050//5836 8065//5855 8066//5843
+f 8061//5844 8076//5856 8077//5845
+f 8072//5864 8057//5841 8071//5846
+f 8067//5848 8052//5827 8066//5843
+f 8057//5841 8072//5864 8073//5847
+f 8068//5850 8053//5829 8067//5848
+f 8058//5828 8073//5847 8074//5849
+f 8069//5854 8054//5831 8068//5850
+f 8048//5851 8063//5869 8064//5852
+f 8059//5830 8074//5849 8075//5853
+f 8070//5842 8055//5835 8069//5854
+f 8049//5833 8064//5852 8065//5855
+f 8060//5837 8075//5853 8076//5856
+f 8074//5849 8089//5871 8090//5857
+f 8085//5861 8070//5842 8084//5858
+f 8064//5852 8079//5870 8080//5859
+f 8075//5853 8090//5857 8091//5860
+f 8086//5865 8071//5846 8085//5861
+f 8065//5855 8080//5859 8081//5862
+f 8076//5856 8091//5860 8092//5863
+f 8087//5882 8072//5864 8086//5865
+f 8066//5843 8081//5862 8082//5866
+f 8072//5864 8087//5882 8088//5867
+f 8067//5848 8082//5866 8083//5868
+f 8089//5871 8074//5849 8088//5867
+f 8084//5858 8069//5854 8083//5868
+f 8063//5869 8078//5874 8079//5870
+f 8104//5888 8089//5871 8103//5872
+f 8083//5868 8098//5885 8099//5873
+f 8078//5874 8093//5891 8094//5875
+f 8089//5871 8104//5888 8105//5876
+f 8100//5879 8085//5861 8099//5873
+f 8079//5870 8094//5875 8095//5877
+f 8090//5857 8105//5876 8106//5878
+f 8101//5897 8086//5865 8100//5879
+f 8080//5859 8095//5877 8096//5880
+f 8091//5860 8106//5878 8107//5881
+f 8086//5865 8101//5897 8102//5883
+f 8081//5862 8096//5880 8097//5884
+f 8087//5882 8102//5883 8103//5872
+f 8082//5866 8097//5884 8098//5885
+f 8096//5880 8111//5899 8112//5886
+f 8102//5883 8117//5901 8118//5887
+f 8113//5908 8098//5885 8112//5886
+f 8103//5872 8118//5887 8119//5889
+f 8098//5885 8113//5908 8114//5890
+f 8093//5891 8108//5911 8109//5892
+f 8104//5888 8119//5889 8120//5893
+f 8099//5873 8114//5890 8115//5894
+f 8094//5875 8109//5892 8110//5895
+f 8105//5876 8120//5893 8121//5896
+f 8100//5879 8115//5894 8116//5898
+f 8095//5877 8110//5895 8111//5899
+f 8106//5878 8121//5896 8122//5900
+f 8101//5897 8116//5898 8117//5901
+f 8115//5894 8130//5913 8131//5902
+f 8110//5895 8125//5914 8126//5903
+f 8121//5896 8136//5915 8137//5904
+f 8116//5898 8131//5902 8132//5905
+f 8111//5899 8126//5903 8127//5906
+f 8117//5901 8132//5905 8133//5907
+f 8128//5925 8113//5908 8127//5906
+f 8118//5887 8133//5907 8134//5909
+f 8113//5908 8128//5925 8129//5910
+f 8108//5911 8123//5928 8124//5912
+f 8135//5916 8120//5893 8134//5909
+f 8114//5890 8129//5910 8130//5913
+f 8109//5892 8124//5912 8125//5914
+f 8120//5893 8135//5916 8136//5915
+f 8134//5909 8149//5927 8150//5917
+f 8145//5920 8130//5913 8144//5918
+f 8124//5912 8139//5929 8140//5919
+f 8151//5937 8136//5915 8150//5917
+f 8146//5923 8131//5902 8145//5920
+f 8125//5914 8140//5919 8141//5921
+f 8136//5915 8151//5937 8152//5922
+f 8147//5942 8132//5905 8146//5923
+f 8142//5944 8127//5906 8141//5921
+f 8132//5905 8147//5942 8148//5924
+f 8127//5906 8142//5944 8143//5926
+f 8133//5907 8148//5924 8149//5927
+f 8144//5918 8129//5910 8143//5926
+f 8123//5928 8138//5932 8139//5929
+f 8148//5924 8163//5946 8164//5930
+f 8159//5935 8144//5918 8158//5931
+f 8138//5932 8153//5952 8154//5933
+f 8149//5927 8164//5930 8165//5934
+f 8160//5939 8145//5920 8159//5935
+f 8139//5929 8154//5933 8155//5936
+f 8150//5917 8165//5934 8166//5938
+f 8161//5943 8146//5923 8160//5939
+f 8140//5919 8155//5936 8156//5940
+f 8151//5937 8166//5938 8167//5941
+f 8162//5945 8147//5942 8161//5943
+f 8157//5948 8142//5944 8156//5940
+f 8163//5946 8148//5924 8162//5945
+f 8142//5944 8157//5948 8158//5931
+f 8178//5950 8163//5946 8177//5947
+f 8157//5948 8172//5964 8173//5949
+f 8179//5954 8164//5930 8178//5950
+f 8158//5931 8173//5949 8174//5951
+f 8153//5952 8168//5969 8169//5953
+f 8180//5971 8165//5934 8179//5954
+f 8175//5957 8160//5939 8174//5951
+f 8154//5933 8169//5953 8170//5955
+f 8165//5934 8180//5971 8181//5956
+f 8176//5960 8161//5943 8175//5957
+f 8155//5936 8170//5955 8171//5958
+f 8166//5938 8181//5956 8182//5959
+f 8177//5947 8162//5945 8176//5960
+f 8172//5964 8157//5948 8171//5958
+f 8170//5955 8185//5974 8186//5961
+f 8181//5956 8196//5975 8197//5962
+f 8192//5965 8177//5947 8191//5963
+f 8187//5966 8172//5964 8186//5961
+f 8193//5967 8178//5950 8192//5965
+f 8188//5968 8173//5949 8187//5966
+f 8194//5972 8179//5954 8193//5967
+f 8189//5973 8174//5951 8188//5968
+f 8168//5969 8183//5989 8184//5970
+f 8195//5979 8180//5971 8194//5972
+f 8190//5976 8175//5957 8189//5973
+f 8169//5953 8184//5970 8185//5974
+f 8180//5971 8195//5979 8196//5975
+f 8191//5963 8176//5960 8190//5976
+f 8205//5981 8190//5976 8204//5977
+f 8184//5970 8199//5990 8200//5978
+f 8211//5999 8196//5975 8210//5980
+f 8206//5984 8191//5963 8205//5981
+f 8185//5974 8200//5978 8201//5982
+f 8196//5975 8211//5999 8212//5983
+f 8207//5986 8192//5965 8206//5984
+f 8186//5961 8201//5982 8202//5985
+f 8208//5987 8193//5967 8207//5986
+f 8203//5988 8188//5968 8202//5985
+f 8209//5991 8194//5972 8208//5987
+f 8204//5977 8189//5973 8203//5988
+f 8183//5989 8198//5994 8199//5990
+f 8210//5980 8195//5979 8209//5991
+f 8224//5996 8209//5991 8223//5992
+f 8219//5997 8204//5977 8218//5993
+f 8198//5994 8213//6011 8214//5995
+f 8225//6013 8210//5980 8224//5996
+f 8220//6001 8205//5981 8219//5997
+f 8199//5990 8214//5995 8215//5998
+f 8210//5980 8225//6013 8226//6000
+f 8221//6004 8206//5984 8220//6001
+f 8200//5978 8215//5998 8216//6002
+f 8211//5999 8226//6000 8227//6003
+f 8222//6006 8207//5986 8221//6004
+f 8201//5982 8216//6002 8217//6005
+f 8223//5992 8208//5987 8222//6006
+f 8218//5993 8203//5988 8217//6005
+f 8238//6009 8223//5992 8237//6007
+f 8233//6010 8218//5993 8232//6008
+f 8239//6028 8224//5996 8238//6009
+f 8234//6015 8219//5997 8233//6010
+f 8213//6011 8228//6030 8229//6012
+f 8224//5996 8239//6028 8240//6014
+f 8235//6017 8220//6001 8234//6015
+f 8214//5995 8229//6012 8230//6016
+f 8241//6019 8226//6000 8240//6014
+f 8236//6020 8221//6004 8235//6017
+f 8215//5998 8230//6016 8231//6018
+f 8242//6022 8227//6003 8241//6019
+f 8237//6007 8222//6006 8236//6020
+f 8216//6002 8231//6018 8232//6008
+f 8230//6016 8245//6034 8246//6021
+f 8241//6019 8256//6038 8257//6023
+f 8252//6026 8237//6007 8251//6024
+f 8231//6018 8246//6021 8247//6025
+f 8253//6045 8238//6009 8252//6026
+f 8232//6008 8247//6025 8248//6027
+f 8238//6009 8253//6045 8254//6029
+f 8249//6033 8234//6015 8248//6027
+f 8228//6030 8243//6049 8244//6031
+f 8239//6028 8254//6029 8255//6032
+f 8250//6035 8235//6017 8249//6033
+f 8229//6012 8244//6031 8245//6034
+f 8256//6038 8241//6019 8255//6032
+f 8251//6024 8236//6020 8250//6035
+f 8265//6040 8250//6035 8264//6036
+f 8260//6041 8245//6034 8259//6037
+f 8271//6058 8256//6038 8270//6039
+f 8266//6043 8251//6024 8265//6040
+f 8261//6044 8246//6021 8260//6041
+f 8256//6038 8271//6058 8272//6042
+f 8267//6046 8252//6026 8266//6043
+f 8262//6063 8247//6025 8261//6044
+f 8268//6051 8253//6045 8267//6046
+f 8247//6025 8262//6063 8263//6047
+f 8253//6045 8268//6051 8269//6048
+f 8264//6036 8249//6033 8263//6047
+f 8259//6037 8244//6031 8258//6050
+f 8254//6029 8269//6048 8270//6039
+f 8284//6069 8269//6048 8283//6052
+f 8279//6056 8264//6036 8278//6053
+f 8274//6057 8259//6037 8273//6054
+f 8269//6048 8284//6069 8285//6055
+f 8280//6059 8265//6040 8279//6056
+f 8275//6060 8260//6041 8274//6057
+f 8286//6074 8271//6058 8285//6055
+f 8281//6062 8266//6043 8280//6059
+f 8276//6064 8261//6044 8275//6060
+f 8271//6058 8286//6074 8287//6061
+f 8282//6065 8267//6046 8281//6062
+f 8277//6067 8262//6063 8276//6064
+f 8283//6052 8268//6051 8282//6065
+f 8262//6063 8277//6067 8278//6053
+f 8282//6065 8297//6079 8298//6066
+f 8277//6067 8292//6080 8293//6068
+f 8299//6071 8284//6069 8298//6066
+f 8294//6072 8279//6056 8293//6068
+f 8289//6073 8274//6057 8288//6070
+f 8300//6075 8285//6055 8299//6071
+f 8295//6091 8280//6059 8294//6072
+f 8290//6077 8275//6060 8289//6073
+f 8301//6081 8286//6074 8300//6075
+f 8280//6059 8295//6091 8296//6076
+f 8291//6084 8276//6064 8290//6077
+f 8286//6074 8301//6081 8302//6078
+f 8281//6062 8296//6076 8297//6079
+f 8276//6064 8291//6084 8292//6080
+f 8301//6081 8317//6094 8318//6082
+f 8296//6076 8312//6095 8313//6083
+f 8308//6103 8292//6080 8307//6085
+f 8297//6079 8313//6083 8314//6086
+f 8292//6080 8308//6103 8309//6087
+f 8298//6066 8314//6086 8315//6088
+f 8310//6107 8294//6072 8309//6087
+f 8305//6093 8289//6073 8304//6089
+f 8299//6071 8315//6088 8316//6090
+f 8294//6072 8310//6107 8311//6092
+f 8306//6096 8290//6077 8305//6093
+f 8300//6075 8316//6090 8317//6094
+f 8295//6091 8311//6092 8312//6095
+f 8307//6085 8291//6084 8306//6096
+f 8321//6100 8306//6096 8320//6097
+f 8332//6117 8317//6094 8331//6098
+f 8311//6092 8326//6110 8327//6099
+f 8322//6120 8307//6085 8321//6100
+f 8317//6094 8332//6117 8333//6101
+f 8312//6095 8327//6099 8328//6102
+f 8307//6085 8322//6120 8323//6104
+f 8313//6083 8328//6102 8329//6105
+f 8324//6108 8309//6087 8323//6104
+f 8314//6086 8329//6105 8330//6106
+f 8325//6111 8310//6107 8324//6108
+f 8320//6097 8305//6093 8319//6109
+f 8315//6088 8330//6106 8331//6098
+f 8310//6107 8325//6111 8326//6110
+f 8340//6115 8325//6111 8339//6112
+f 8335//6116 8320//6097 8334//6113
+f 8346//6118 8331//6098 8345//6114
+f 8341//6133 8326//6110 8340//6115
+f 8336//6121 8321//6100 8335//6116
+f 8347//6136 8332//6117 8346//6118
+f 8326//6110 8341//6133 8342//6119
+f 8337//6124 8322//6120 8336//6121
+f 8332//6117 8347//6136 8348//6122
+f 8327//6099 8342//6119 8343//6123
+f 8338//6127 8323//6104 8337//6124
+f 8328//6102 8343//6123 8344//6125
+f 8323//6104 8338//6127 8339//6112
+f 8329//6105 8344//6125 8345//6114
+f 8343//6123 8358//6140 8359//6126
+f 8354//6130 8339//6112 8353//6128
+f 8344//6125 8359//6126 8360//6129
+f 8355//6148 8340//6115 8354//6130
+f 8350//6135 8335//6116 8349//6131
+f 8345//6114 8360//6129 8361//6132
+f 8340//6115 8355//6148 8356//6134
+f 8351//6138 8336//6121 8350//6135
+f 8362//6141 8347//6136 8361//6132
+f 8341//6133 8356//6134 8357//6137
+f 8352//6144 8337//6124 8351//6138
+f 8347//6136 8362//6141 8363//6139
+f 8342//6119 8357//6137 8358//6140
+f 8337//6124 8352//6144 8353//6128
+f 8362//6141 8377//6153 8378//6142
+f 8357//6137 8372//6154 8373//6143
+f 8352//6144 8367//6160 8368//6145
+f 8358//6140 8373//6143 8374//6146
+f 8369//6149 8354//6130 8368//6145
+f 8359//6126 8374//6146 8375//6147
+f 8370//6168 8355//6148 8369//6149
+f 8365//6152 8350//6135 8364//6150
+f 8376//6157 8361//6132 8375//6147
+f 8355//6148 8370//6168 8371//6151
+f 8366//6155 8351//6138 8365//6152
+f 8361//6132 8376//6157 8377//6153
+f 8356//6134 8371//6151 8372//6154
+f 8367//6160 8352//6144 8366//6155
+f 8381//6161 8366//6155 8380//6156
+f 8376//6157 8391//6174 8392//6158
+f 8371//6151 8386//6170 8387//6159
+f 8382//6180 8367//6160 8381//6161
+f 8377//6153 8392//6158 8393//6162
+f 8372//6154 8387//6159 8388//6163
+f 8367//6160 8382//6180 8383//6164
+f 8373//6143 8388//6163 8389//6165
+f 8368//6145 8383//6164 8384//6166
+f 8374//6146 8389//6165 8390//6167
+f 8385//6171 8370//6168 8384//6166
+f 8380//6156 8365//6152 8379//6169
+f 8391//6174 8376//6157 8390//6167
+f 8370//6168 8385//6171 8386//6170
+f 8384//6166 8399//6186 8400//6172
+f 8395//6177 8380//6156 8394//6173
+f 8390//6167 8405//6187 8406//6175
+f 8385//6171 8400//6172 8401//6176
+f 8396//6181 8381//6161 8395//6177
+f 8391//6174 8406//6175 8407//6178
+f 8386//6170 8401//6176 8402//6179
+f 8397//6184 8382//6180 8396//6181
+f 8392//6158 8407//6178 8408//6182
+f 8387//6159 8402//6179 8403//6183
+f 8398//6189 8383//6164 8397//6184
+f 8388//6163 8403//6183 8404//6185
+f 8383//6164 8398//6189 8399//6186
+f 8389//6165 8404//6185 8405//6187
+f 8403//6183 8418//6201 8419//6188
+f 8398//6189 8413//6202 8414//6190
+f 8404//6185 8419//6188 8420//6191
+f 8399//6186 8414//6190 8415//6192
+f 8410//6196 8395//6177 8409//6193
+f 8405//6187 8420//6191 8421//6194
+f 8400//6172 8415//6192 8416//6195
+f 8411//6199 8396//6181 8410//6196
+f 8406//6175 8421//6194 8422//6197
+f 8401//6176 8416//6195 8417//6198
+f 8412//6205 8397//6184 8411//6199
+f 8407//6178 8422//6197 8423//6200
+f 8402//6179 8417//6198 8418//6201
+f 8397//6184 8412//6205 8413//6202
+f 8422//6197 8438//6215 8439//6203
+f 8417//6198 8433//6216 8434//6204
+f 8412//6205 8428//6220 8429//6206
+f 8418//6201 8434//6204 8435//6207
+f 8413//6202 8429//6206 8430//6208
+f 8419//6188 8435//6207 8436//6209
+f 8414//6190 8430//6208 8431//6210
+f 8426//6214 8410//6196 8425//6211
+f 8420//6191 8436//6209 8437//6212
+f 8415//6192 8431//6210 8432//6213
+f 8427//6217 8411//6199 8426//6214
+f 8421//6194 8437//6212 8438//6215
+f 8416//6195 8432//6213 8433//6216
+f 8428//6220 8412//6205 8427//6217
+f 8437//6212 8452//6227 8453//6218
+f 8432//6213 8447//6228 8448//6219
+f 8443//6235 8428//6220 8442//6221
+f 8454//6232 8439//6203 8453//6218
+f 8433//6216 8448//6219 8449//6222
+f 8428//6220 8443//6235 8444//6223
+f 8450//6225 8435//6207 8449//6222
+f 8429//6206 8444//6223 8445//6224
+f 8451//6233 8436//6209 8450//6225
+f 8446//6234 8431//6210 8445//6224
+f 8441//6229 8426//6214 8440//6226
+f 8436//6209 8451//6233 8452//6227
+f 8431//6210 8446//6234 8447//6228
+f 8442//6221 8427//6217 8441//6229
+f 7974//5774 8441//6229 7973//5775
+f 7985//5777 8452//6227 7984//5770
+f 7980//5755 8447//6228 7979//5772
+f 7975//5758 8442//6221 7974//5774
+f 7986//5761 8453//6218 7985//5777
+f 8447//6228 7980//5755 7981//5754
+f 7976//5757 8443//6235 7975//5758
+f 7987//5760 8454//6232 7986//5761
+f 7982//5763 8449//6222 7981//5754
+f 8443//6235 7976//5757 7977//5764
+f 7983//5766 8450//6225 7982//5763
+f 8444//6223 7977//5764 7978//5768
+f 7984//5770 8451//6233 7983//5766
+f 7979//5772 8446//6234 7978//5768
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/gopher/wavefront.go b/Godeps/_workspace/src/github.com/obscuren/qml/examples/gopher/wavefront.go
new file mode 100644
index 000000000..964f8b830
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/gopher/wavefront.go
@@ -0,0 +1,280 @@
+package main
+
+import (
+ "bufio"
+ "fmt"
+ "os"
+ "path/filepath"
+ "strconv"
+ "strings"
+)
+
+type Object struct {
+ Name string
+ Groups []*Group
+}
+
+type Group struct {
+ Vertexes []float32
+ Normals []float32
+ Material *Material
+}
+
+type Material struct {
+ Name string
+ Ambient []float32
+ Diffuse []float32
+ Specular []float32
+ Shininess float32
+}
+
+func Read(filename string) (map[string]*Object, error) {
+ file, err := os.Open(filename)
+ if err != nil {
+ return nil, err
+ }
+ defer file.Close()
+
+ var materials map[string]*Material
+ var objects = make(map[string]*Object)
+ var object *Object
+ var group *Group
+ var vertex []float32
+ var normal []float32
+
+ lno := 0
+ line := ""
+ scanner := bufio.NewScanner(file)
+
+ fail := func(msg string) error {
+ return fmt.Errorf(msg+" at %s:%d: %s", filename, lno, line)
+ }
+
+ for scanner.Scan() {
+ lno++
+ line = scanner.Text()
+ if strings.HasPrefix(line, "#") {
+ continue
+ }
+
+ fields := strings.Fields(line)
+ if len(fields) == 0 {
+ continue
+ }
+
+ if fields[0] == "mtllib" {
+ if len(fields) != 2 {
+ return nil, fail("unsupported materials library line")
+ }
+ materials, err = readMaterials(filepath.Join(filepath.Dir(filename), fields[1]))
+ if err != nil {
+ return nil, err
+ }
+ continue
+ }
+
+ if fields[0] == "o" {
+ if len(fields) != 2 {
+ return nil, fail("unsupported object line")
+ }
+ object = &Object{Name: fields[1]}
+ objects[object.Name] = object
+ group = nil
+ continue
+ }
+
+ if object == nil {
+ return nil, fail("found data before object")
+ }
+
+ if fields[0] == "usemtl" {
+ group = &Group{}
+ object.Groups = append(object.Groups, group)
+ }
+
+ switch fields[0] {
+ case "usemtl":
+ if len(fields) != 2 {
+ return nil, fail("unsupported material usage line")
+ }
+ group.Material = materials[fields[1]]
+ if group.Material == nil {
+ return nil, fmt.Errorf("material %q not defined", fields[1])
+ }
+ case "v":
+ if len(fields) != 4 {
+ return nil, fail("unsupported vertex line")
+ }
+ for i := 0; i < 3; i++ {
+ f, err := strconv.ParseFloat(fields[i+1], 32)
+ if err != nil {
+ return nil, fail("cannot parse float")
+ }
+ vertex = append(vertex, float32(f))
+ }
+ case "vn":
+ if len(fields) != 4 {
+ return nil, fail("unsupported vertex normal line")
+ }
+ for i := 0; i < 3; i++ {
+ f, err := strconv.ParseFloat(fields[i+1], 32)
+ if err != nil {
+ return nil, fail("cannot parse float")
+ }
+ normal = append(normal, float32(f))
+ }
+ case "f":
+ if len(fields) != 4 {
+ return nil, fail("unsupported face line")
+ }
+ for i := 0; i < 3; i++ {
+ face := strings.Split(fields[i+1], "/")
+ if len(face) != 3 {
+ return nil, fail("unsupported face shape (not a triangle)")
+ }
+ vi, err := strconv.Atoi(face[0])
+ if err != nil {
+ return nil, fail("unsupported face vertex index")
+ }
+ ni, err := strconv.Atoi(face[2])
+ if err != nil {
+ return nil, fail("unsupported face normal index")
+ }
+ vi = (vi - 1) * 3
+ ni = (ni - 1) * 3
+ group.Vertexes = append(group.Vertexes, vertex[vi], vertex[vi+1], vertex[vi+2])
+ group.Normals = append(group.Normals, normal[ni], normal[ni+1], normal[ni+2])
+ }
+ }
+ }
+ if err := scanner.Err(); err != nil {
+ return nil, err
+ }
+ return objects, nil
+}
+
+func readMaterials(filename string) (map[string]*Material, error) {
+ file, err := os.Open(filename)
+ if err != nil {
+ return nil, fmt.Errorf("cannot read referenced material library: %v", err)
+ }
+ defer file.Close()
+
+ var materials = make(map[string]*Material)
+ var material *Material
+
+ lno := 0
+ line := ""
+ scanner := bufio.NewScanner(file)
+
+ fail := func(msg string) error {
+ return fmt.Errorf(msg+" at %s:%d: %s", filename, lno, line)
+ }
+
+ for scanner.Scan() {
+ lno++
+ line = scanner.Text()
+ if strings.HasPrefix(line, "#") {
+ continue
+ }
+
+ fields := strings.Fields(line)
+ if len(fields) == 0 {
+ continue
+ }
+
+ if fields[0] == "newmtl" {
+ if len(fields) != 2 {
+ return nil, fail("unsupported material definition")
+ }
+ material = &Material{Name: fields[1]}
+ material.Ambient = []float32{0.2, 0.2, 0.2, 1.0}
+ material.Diffuse = []float32{0.8, 0.8, 0.8, 1.0}
+ material.Specular = []float32{0.0, 0.0, 0.0, 1.0}
+ materials[material.Name] = material
+ continue
+ }
+
+ if material == nil {
+ return nil, fail("found data before material")
+ }
+
+ switch fields[0] {
+ case "Ka":
+ if len(fields) != 4 {
+ return nil, fail("unsupported ambient color line")
+ }
+ for i := 0; i < 3; i++ {
+ f, err := strconv.ParseFloat(fields[i+1], 32)
+ if err != nil {
+ return nil, fail("cannot parse float")
+ }
+ material.Ambient[i] = float32(f)
+ }
+ case "Kd":
+ if len(fields) != 4 {
+ return nil, fail("unsupported diffuse color line")
+ }
+ for i := 0; i < 3; i++ {
+ f, err := strconv.ParseFloat(fields[i+1], 32)
+ if err != nil {
+ return nil, fail("cannot parse float")
+ }
+ material.Diffuse[i] = float32(f)
+ }
+ case "Ks":
+ if len(fields) != 4 {
+ return nil, fail("unsupported specular color line")
+ }
+ for i := 0; i < 3; i++ {
+ f, err := strconv.ParseFloat(fields[i+1], 32)
+ if err != nil {
+ return nil, fail("cannot parse float")
+ }
+ material.Specular[i] = float32(f)
+ }
+ case "Ns":
+ if len(fields) != 2 {
+ return nil, fail("unsupported shininess line")
+ }
+ f, err := strconv.ParseFloat(fields[1], 32)
+ if err != nil {
+ return nil, fail("cannot parse float")
+ }
+ material.Shininess = float32(f / 1000 * 128)
+ case "d":
+ if len(fields) != 2 {
+ return nil, fail("unsupported transparency line")
+ }
+ f, err := strconv.ParseFloat(fields[1], 32)
+ if err != nil {
+ return nil, fail("cannot parse float")
+ }
+ material.Ambient[3] = float32(f)
+ material.Diffuse[3] = float32(f)
+ material.Specular[3] = float32(f)
+ }
+ }
+ if err := scanner.Err(); err != nil {
+ return nil, err
+ }
+
+ // Exporting from blender seems to show everything too dark in
+ // practice, so hack colors to look closer to what we see there.
+ // TODO This needs more real world checking.
+ for _, material := range materials {
+ if material.Ambient[0] == 0 && material.Ambient[1] == 0 && material.Ambient[2] == 0 && material.Ambient[3] == 1 {
+ material.Ambient[0] = material.Diffuse[0] * 0.7
+ material.Ambient[1] = material.Diffuse[1] * 0.7
+ material.Ambient[2] = material.Diffuse[2] * 0.7
+ }
+ for i := 0; i < 3; i++ {
+ material.Diffuse[i] *= 1.3
+ if material.Diffuse[i] > 1 {
+ material.Diffuse[i] = 1
+ }
+ }
+ }
+
+ return materials, nil
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/imgprovider/imgprovider.go b/Godeps/_workspace/src/github.com/obscuren/qml/examples/imgprovider/imgprovider.go
new file mode 100644
index 000000000..533a23b86
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/imgprovider/imgprovider.go
@@ -0,0 +1,43 @@
+package main
+
+import (
+ "fmt"
+ "gopkg.in/qml.v1"
+ "image"
+ "image/png"
+ "os"
+)
+
+func main() {
+ if err := qml.Run(run); err != nil {
+ fmt.Fprintf(os.Stderr, "error: %v\n", err)
+ os.Exit(1)
+ }
+}
+
+func run() error {
+ engine := qml.NewEngine()
+ engine.AddImageProvider("pwd", func(id string, width, height int) image.Image {
+ f, err := os.Open(id)
+ if err != nil {
+ panic(err)
+ }
+ defer f.Close()
+ image, err := png.Decode(f)
+ if err != nil {
+ panic(err)
+ }
+ return image
+ })
+
+ component, err := engine.LoadFile("imgprovider.qml")
+ if err != nil {
+ return err
+ }
+
+ win := component.CreateWindow(nil)
+ win.Show()
+ win.Wait()
+
+ return nil
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/imgprovider/imgprovider.qml b/Godeps/_workspace/src/github.com/obscuren/qml/examples/imgprovider/imgprovider.qml
new file mode 100644
index 000000000..0c5c747f0
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/imgprovider/imgprovider.qml
@@ -0,0 +1,5 @@
+import QtQuick 2.0
+
+Image {
+ source: "image://pwd/ubuntu-gopher.png"
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/imgprovider/ubuntu-gopher.png b/Godeps/_workspace/src/github.com/obscuren/qml/examples/imgprovider/ubuntu-gopher.png
new file mode 100644
index 000000000..3f51d3798
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/imgprovider/ubuntu-gopher.png
Binary files differ
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/modelview/delegate/delegate.go b/Godeps/_workspace/src/github.com/obscuren/qml/examples/modelview/delegate/delegate.go
new file mode 100644
index 000000000..440fd229a
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/modelview/delegate/delegate.go
@@ -0,0 +1,53 @@
+package main
+
+import (
+ "fmt"
+ "gopkg.in/qml.v1"
+ "image/color"
+ "math/rand"
+ "os"
+ "time"
+)
+
+func main() {
+ if err := qml.Run(run); err != nil {
+ fmt.Fprintf(os.Stderr, "error: %v\n", err)
+ os.Exit(1)
+ }
+}
+
+func run() error {
+ engine := qml.NewEngine()
+ colors := &Colors{}
+ engine.Context().SetVar("colors", colors)
+ component, err := engine.LoadFile("delegate.qml")
+ if err != nil {
+ return err
+ }
+ window := component.CreateWindow(nil)
+ window.Show()
+ go func() {
+ n := func() uint8 { return uint8(rand.Intn(256)) }
+ for i := 0; i < 100; i++ {
+ colors.Add(color.RGBA{n(), n(), n(), 0xff})
+ time.Sleep(1 * time.Second)
+ }
+ }()
+ window.Wait()
+ return nil
+}
+
+type Colors struct {
+ list []color.RGBA
+ Len int
+}
+
+func (colors *Colors) Add(c color.RGBA) {
+ colors.list = append(colors.list, c)
+ colors.Len = len(colors.list)
+ qml.Changed(colors, &colors.Len)
+}
+
+func (colors *Colors) Color(index int) color.RGBA {
+ return colors.list[index]
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/modelview/delegate/delegate.qml b/Godeps/_workspace/src/github.com/obscuren/qml/examples/modelview/delegate/delegate.qml
new file mode 100644
index 000000000..4b37d31f6
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/modelview/delegate/delegate.qml
@@ -0,0 +1,17 @@
+import QtQuick 2.0
+
+Item {
+ width: 320; height: 200
+
+ ListView {
+ width: 120;
+ model: colors.len
+ delegate: Text {
+ text: "I am color number: " + index
+ color: colors.color(index)
+ }
+ anchors.top: parent.top
+ anchors.bottom: parent.bottom
+ anchors.horizontalCenter: parent.horizontalCenter
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/painting-es2/painting.go b/Godeps/_workspace/src/github.com/obscuren/qml/examples/painting-es2/painting.go
new file mode 100644
index 000000000..71f2d89a2
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/painting-es2/painting.go
@@ -0,0 +1,115 @@
+package main
+
+import (
+ "fmt"
+ "os"
+
+ "gopkg.in/qml.v1"
+ "gopkg.in/qml.v1/gl/es2"
+)
+
+func main() {
+ if err := qml.Run(run); err != nil {
+ fmt.Fprintf(os.Stderr, "error: %v\n", err)
+ os.Exit(1)
+ }
+}
+
+func run() error {
+ qml.RegisterTypes("GoExtensions", 1, 0, []qml.TypeSpec{{
+ Init: func(r *GoRect, obj qml.Object) { r.Object = obj },
+ }})
+
+ engine := qml.NewEngine()
+ component, err := engine.LoadFile("painting.qml")
+ if err != nil {
+ return err
+ }
+
+ win := component.CreateWindow(nil)
+ win.Show()
+ win.Wait()
+ return nil
+}
+
+type GoRect struct {
+ qml.Object
+}
+
+var vertexShader = `
+#version 120
+
+attribute vec2 position;
+
+void main()
+{
+ gl_Position = vec4(position.x, position.y, 0.0, 1.0);
+}
+`
+
+var fragmentShader = `
+#version 120
+
+void main()
+{
+ gl_FragColor = vec4(1.0, 1.0, 1.0, 0.8);
+}
+`
+
+func (r *GoRect) Paint(p *qml.Painter) {
+ gl := GL.API(p)
+
+ vertices := []float32{
+ -1, -1,
+ +1, -1,
+ +1, +1,
+ -1, +1,
+ }
+
+ indices := []uint8{
+ 0, 1, 2, // first triangle
+ 2, 3, 0, // second triangle
+ }
+
+ buf := gl.GenBuffers(2)
+ gl.BindBuffer(GL.ARRAY_BUFFER, buf[0])
+ gl.BufferData(GL.ARRAY_BUFFER, 0, vertices, GL.STATIC_DRAW)
+ gl.BindBuffer(GL.ELEMENT_ARRAY_BUFFER, buf[1])
+ gl.BufferData(GL.ELEMENT_ARRAY_BUFFER, 0, indices, GL.STATIC_DRAW)
+
+ vshader := gl.CreateShader(GL.VERTEX_SHADER);
+ gl.ShaderSource(vshader, vertexShader)
+ gl.CompileShader(vshader)
+
+ var status [1]int32
+ gl.GetShaderiv(vshader, GL.COMPILE_STATUS, status[:])
+ if status[0] == 0 {
+ log := gl.GetShaderInfoLog(vshader)
+ panic("vertex shader compilation failed: " + string(log))
+ }
+
+ fshader := gl.CreateShader(GL.FRAGMENT_SHADER)
+ gl.ShaderSource(fshader, fragmentShader)
+ gl.CompileShader(fshader)
+
+ gl.GetShaderiv(fshader, GL.COMPILE_STATUS, status[:])
+ if status[0] == 0 {
+ log := gl.GetShaderInfoLog(fshader)
+ panic("fragment shader compilation failed: " + string(log))
+ }
+
+ program := gl.CreateProgram()
+ gl.AttachShader(program, vshader)
+ gl.AttachShader(program, fshader)
+ gl.LinkProgram(program)
+ gl.UseProgram(program)
+
+ position := gl.GetAttribLocation(program, "position")
+ gl.VertexAttribPointer(position, 2, GL.FLOAT, false, 0, 0)
+ gl.EnableVertexAttribArray(position)
+
+ gl.Enable(GL.BLEND)
+ gl.BlendFunc(GL.SRC_ALPHA, GL.ONE_MINUS_SRC_ALPHA)
+
+ gl.DrawElements(GL.TRIANGLES, 6, GL.UNSIGNED_BYTE, nil)
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/painting-es2/painting.qml b/Godeps/_workspace/src/github.com/obscuren/qml/examples/painting-es2/painting.qml
new file mode 100644
index 000000000..8c59fc351
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/painting-es2/painting.qml
@@ -0,0 +1,66 @@
+import QtQuick 2.0
+import GoExtensions 1.0
+
+Rectangle {
+ id: root
+
+ width: 640
+ height: 280
+ color: "black"
+
+ Rectangle {
+ x: 20; y: 20; width: 100; height: 100
+ color: "red"
+
+ SequentialAnimation on x {
+ loops: Animation.Infinite
+ NumberAnimation { from: 20; to: 120; duration: 4000; easing.type: Easing.InOutQuad }
+ NumberAnimation { from: 120; to: 20; duration: 4000; easing.type: Easing.InOutQuad }
+ }
+ }
+
+ Rectangle {
+ x: 40; y: 40; width: 100; height: 100
+ color: "yellow"
+ opacity: 0.7
+
+ SequentialAnimation on x {
+ loops: Animation.Infinite
+ NumberAnimation { from: 40; to: 220; duration: 4000; easing.type: Easing.InOutQuad }
+ NumberAnimation { from: 220; to: 40; duration: 4000; easing.type: Easing.InOutQuad }
+ }
+ }
+
+ GoRect {
+ x: 60; y: 60; width: 100; height: 100
+
+ SequentialAnimation on x {
+ loops: Animation.Infinite
+ NumberAnimation { from: 60; to: 320; duration: 4000; easing.type: Easing.InOutQuad }
+ NumberAnimation { from: 320; to: 60; duration: 4000; easing.type: Easing.InOutQuad }
+ }
+ }
+
+ Rectangle {
+ x: 80; y: 80; width: 100; height: 100
+ color: "yellow"
+ opacity: 0.7
+
+ SequentialAnimation on x {
+ loops: Animation.Infinite
+ NumberAnimation { from: 80; to: 420; duration: 4000; easing.type: Easing.InOutQuad }
+ NumberAnimation { from: 420; to: 80; duration: 4000; easing.type: Easing.InOutQuad }
+ }
+ }
+
+ Rectangle {
+ x: 100; y: 100; width: 100; height: 100
+ color: "red"
+
+ SequentialAnimation on x {
+ loops: Animation.Infinite
+ NumberAnimation { from: 100; to: 520; duration: 4000; easing.type: Easing.InOutQuad }
+ NumberAnimation { from: 520; to: 100; duration: 4000; easing.type: Easing.InOutQuad }
+ }
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/painting/painting.go b/Godeps/_workspace/src/github.com/obscuren/qml/examples/painting/painting.go
new file mode 100644
index 000000000..eda1e19f5
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/painting/painting.go
@@ -0,0 +1,64 @@
+package main
+
+import (
+ "fmt"
+ "os"
+
+ "gopkg.in/qml.v1"
+ "gopkg.in/qml.v1/gl/2.0"
+)
+
+func main() {
+ if err := qml.Run(run); err != nil {
+ fmt.Fprintf(os.Stderr, "error: %v\n", err)
+ os.Exit(1)
+ }
+}
+
+type GoRect struct {
+ qml.Object
+}
+
+func (r *GoRect) Paint(p *qml.Painter) {
+ gl := GL.API(p)
+
+ width := float32(r.Int("width"))
+ height := float32(r.Int("height"))
+
+ gl.Enable(GL.BLEND)
+ gl.BlendFunc(GL.SRC_ALPHA, GL.ONE_MINUS_SRC_ALPHA)
+ gl.Color4f(1.0, 1.0, 1.0, 0.8)
+ gl.Begin(GL.QUADS)
+ gl.Vertex2f(0, 0)
+ gl.Vertex2f(width, 0)
+ gl.Vertex2f(width, height)
+ gl.Vertex2f(0, height)
+ gl.End()
+
+ gl.LineWidth(2.5)
+ gl.Color4f(0.0, 0.0, 0.0, 1.0)
+ gl.Begin(GL.LINES)
+ gl.Vertex2f(0, 0)
+ gl.Vertex2f(width, height)
+ gl.Vertex2f(width, 0)
+ gl.Vertex2f(0, height)
+ gl.End()
+}
+
+func run() error {
+ qml.RegisterTypes("GoExtensions", 1, 0, []qml.TypeSpec{{
+ Init: func(r *GoRect, obj qml.Object) { r.Object = obj },
+ }})
+
+ engine := qml.NewEngine()
+ component, err := engine.LoadFile("painting.qml")
+ if err != nil {
+ return err
+ }
+
+ win := component.CreateWindow(nil)
+ win.Show()
+ win.Wait()
+
+ return nil
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/painting/painting.qml b/Godeps/_workspace/src/github.com/obscuren/qml/examples/painting/painting.qml
new file mode 100644
index 000000000..8c59fc351
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/painting/painting.qml
@@ -0,0 +1,66 @@
+import QtQuick 2.0
+import GoExtensions 1.0
+
+Rectangle {
+ id: root
+
+ width: 640
+ height: 280
+ color: "black"
+
+ Rectangle {
+ x: 20; y: 20; width: 100; height: 100
+ color: "red"
+
+ SequentialAnimation on x {
+ loops: Animation.Infinite
+ NumberAnimation { from: 20; to: 120; duration: 4000; easing.type: Easing.InOutQuad }
+ NumberAnimation { from: 120; to: 20; duration: 4000; easing.type: Easing.InOutQuad }
+ }
+ }
+
+ Rectangle {
+ x: 40; y: 40; width: 100; height: 100
+ color: "yellow"
+ opacity: 0.7
+
+ SequentialAnimation on x {
+ loops: Animation.Infinite
+ NumberAnimation { from: 40; to: 220; duration: 4000; easing.type: Easing.InOutQuad }
+ NumberAnimation { from: 220; to: 40; duration: 4000; easing.type: Easing.InOutQuad }
+ }
+ }
+
+ GoRect {
+ x: 60; y: 60; width: 100; height: 100
+
+ SequentialAnimation on x {
+ loops: Animation.Infinite
+ NumberAnimation { from: 60; to: 320; duration: 4000; easing.type: Easing.InOutQuad }
+ NumberAnimation { from: 320; to: 60; duration: 4000; easing.type: Easing.InOutQuad }
+ }
+ }
+
+ Rectangle {
+ x: 80; y: 80; width: 100; height: 100
+ color: "yellow"
+ opacity: 0.7
+
+ SequentialAnimation on x {
+ loops: Animation.Infinite
+ NumberAnimation { from: 80; to: 420; duration: 4000; easing.type: Easing.InOutQuad }
+ NumberAnimation { from: 420; to: 80; duration: 4000; easing.type: Easing.InOutQuad }
+ }
+ }
+
+ Rectangle {
+ x: 100; y: 100; width: 100; height: 100
+ color: "red"
+
+ SequentialAnimation on x {
+ loops: Animation.Infinite
+ NumberAnimation { from: 100; to: 520; duration: 4000; easing.type: Easing.InOutQuad }
+ NumberAnimation { from: 520; to: 100; duration: 4000; easing.type: Easing.InOutQuad }
+ }
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/particle/main.go b/Godeps/_workspace/src/github.com/obscuren/qml/examples/particle/main.go
new file mode 100644
index 000000000..2a7ab865b
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/particle/main.go
@@ -0,0 +1,84 @@
+package main
+
+import (
+ "fmt"
+ "math/rand"
+ "os"
+ "time"
+
+ "gopkg.in/qml.v1"
+)
+
+func main() {
+ if err := qml.Run(run); err != nil {
+ fmt.Fprintf(os.Stderr, "error: %v\n", err)
+ os.Exit(1)
+ }
+}
+
+func run() error {
+ engine := qml.NewEngine()
+ component, err := engine.LoadFile("particle.qml")
+ if err != nil {
+ return err
+ }
+
+ ctrl := Control{Message: "Hello from Go!"}
+
+ context := engine.Context()
+ context.SetVar("ctrl", &ctrl)
+
+ window := component.CreateWindow(nil)
+
+ ctrl.Root = window.Root()
+
+ rand.Seed(time.Now().Unix())
+
+ window.Show()
+ window.Wait()
+
+ return nil
+}
+
+type Control struct {
+ Root qml.Object
+ Message string
+}
+
+func (ctrl *Control) TextReleased(text qml.Object) {
+ x := text.Int("x")
+ y := text.Int("y")
+ width := text.Int("width")
+ height := text.Int("height")
+
+ ctrl.Emit(x+15, y+height/2)
+ ctrl.Emit(x+width/2, 1.0*y+height/2)
+ ctrl.Emit(x+width-15, 1.0*y+height/2)
+
+ go func() {
+ time.Sleep(500 * time.Millisecond)
+ messages := []string{"Hello", "Hello", "Hacks"}
+ ctrl.Message = messages[rand.Intn(len(messages))] + " from Go!"
+ qml.Changed(ctrl, &ctrl.Message)
+ }()
+}
+
+func (ctrl *Control) Emit(x, y int) {
+ component := ctrl.Root.Object("emitterComponent")
+ for i := 0; i < 8; i++ {
+ emitter := component.Create(nil)
+ emitter.Set("x", x)
+ emitter.Set("y", y)
+ emitter.Set("targetX", rand.Intn(240)-120+x)
+ emitter.Set("targetY", rand.Intn(240)-120+y)
+ emitter.Set("life", rand.Intn(2400)+200)
+ emitter.Set("emitRate", rand.Intn(32)+32)
+ emitter.ObjectByName("xAnim").Call("start")
+ emitter.ObjectByName("yAnim").Call("start")
+ emitter.Set("enabled", true)
+ }
+}
+
+func (ctrl *Control) Done(emitter qml.Object) {
+ emitter.Destroy()
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/particle/particle.png b/Godeps/_workspace/src/github.com/obscuren/qml/examples/particle/particle.png
new file mode 100644
index 000000000..5c83896d2
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/particle/particle.png
Binary files differ
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/particle/particle.qml b/Godeps/_workspace/src/github.com/obscuren/qml/examples/particle/particle.qml
new file mode 100644
index 000000000..1fd1f1c8b
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/particle/particle.qml
@@ -0,0 +1,89 @@
+import QtQuick 2.0
+import QtQuick.Particles 2.0
+import QtGraphicalEffects 1.0;
+
+Rectangle {
+ id: root
+
+ width: 640
+ height: 480
+
+ gradient: Gradient {
+ GradientStop { position: 0.0; color: "#3a2c32"; }
+ GradientStop { position: 0.8; color: "#875864"; }
+ GradientStop { position: 1.0; color: "#9b616c"; }
+ }
+
+ Text {
+ text: ctrl.message
+
+ Component.onCompleted: {
+ x = parent.width/2 - width/2
+ y = parent.height/2 - height/2
+ }
+
+ color: "white"
+ font.bold: true
+ font.pointSize: 20
+
+ MouseArea {
+ id: mouseArea
+ anchors.fill: parent
+ drag.target: parent
+ onReleased: ctrl.textReleased(parent)
+ }
+ }
+
+ ParticleSystem { id: sys }
+
+ ImageParticle {
+ system: sys
+ source: "particle.png"
+ color: "white"
+ colorVariation: 1.0
+ alpha: 0.1
+ }
+
+ property var emitterComponent: Component {
+ id: emitterComponent
+ Emitter {
+ id: container
+ system: sys
+ Emitter {
+ system: sys
+ emitRate: 128
+ lifeSpan: 600
+ size: 16
+ endSize: 8
+ velocity: AngleDirection { angleVariation:360; magnitude: 60 }
+ }
+
+ property int life: 2600
+ property real targetX: 0
+ property real targetY: 0
+ emitRate: 128
+ lifeSpan: 600
+ size: 24
+ endSize: 8
+ NumberAnimation on x {
+ objectName: "xAnim"
+ id: xAnim;
+ to: targetX
+ duration: life
+ running: false
+ }
+ NumberAnimation on y {
+ objectName: "yAnim"
+ id: yAnim;
+ to: targetY
+ duration: life
+ running: false
+ }
+ Timer {
+ interval: life
+ running: true
+ onTriggered: ctrl.done(container)
+ }
+ }
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/qmlscene/Cell.qml b/Godeps/_workspace/src/github.com/obscuren/qml/examples/qmlscene/Cell.qml
new file mode 100644
index 000000000..998a49242
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/qmlscene/Cell.qml
@@ -0,0 +1,20 @@
+import QtQuick 2.0
+
+Item {
+ id: container
+ property alias cellColor: rectangle.color
+ signal clicked(color cellColor)
+
+ width: 40; height: 25
+
+ Rectangle {
+ id: rectangle
+ border.color: "white"
+ anchors.fill: parent
+ }
+
+ MouseArea {
+ anchors.fill: parent
+ onClicked: container.clicked(container.cellColor)
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/qmlscene/qmlscene.go b/Godeps/_workspace/src/github.com/obscuren/qml/examples/qmlscene/qmlscene.go
new file mode 100644
index 000000000..6124ac568
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/qmlscene/qmlscene.go
@@ -0,0 +1,33 @@
+package main
+
+import (
+ "fmt"
+ "gopkg.in/qml.v1"
+ "os"
+)
+
+func main() {
+ if len(os.Args) != 2 {
+ fmt.Fprintf(os.Stderr, "usage: %s <qml file>\n", os.Args[0])
+ os.Exit(1)
+ }
+ if err := qml.Run(run); err != nil {
+ fmt.Fprintf(os.Stderr, "error: %v\n", err)
+ os.Exit(1)
+ }
+}
+
+func run() error {
+ engine := qml.NewEngine()
+
+ engine.On("quit", func() { os.Exit(0) })
+
+ component, err := engine.LoadFile(os.Args[1])
+ if err != nil {
+ return err
+ }
+ window := component.CreateWindow(nil)
+ window.Show()
+ window.Wait()
+ return nil
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/qmlscene/tutorial1.qml b/Godeps/_workspace/src/github.com/obscuren/qml/examples/qmlscene/tutorial1.qml
new file mode 100644
index 000000000..e42216e6a
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/qmlscene/tutorial1.qml
@@ -0,0 +1,17 @@
+// See http://qt-project.org/doc/qt-5.1/qtquick/qml-tutorial1.html
+
+import QtQuick 2.0
+
+Rectangle {
+ id: page
+ width: 320; height: 480
+ color: "lightgray"
+
+ Text {
+ id: helloText
+ text: "Hello world!"
+ y: 30
+ anchors.horizontalCenter: page.horizontalCenter
+ font.pointSize: 24; font.bold: true
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/qmlscene/tutorial2.qml b/Godeps/_workspace/src/github.com/obscuren/qml/examples/qmlscene/tutorial2.qml
new file mode 100644
index 000000000..aa64bc1aa
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/qmlscene/tutorial2.qml
@@ -0,0 +1,30 @@
+// See http://qt-project.org/doc/qt-5.1/qtquick/qml-tutorial2.html
+
+import QtQuick 2.0
+
+Rectangle {
+ id: page
+ width: 320; height: 480
+ color: "lightgray"
+
+ Text {
+ id: helloText
+ text: "Hello world!"
+ y: 30
+ anchors.horizontalCenter: page.horizontalCenter
+ font.pointSize: 24; font.bold: true
+ }
+
+ Grid {
+ id: colorPicker
+ x: 4; anchors.bottom: page.bottom; anchors.bottomMargin: 4
+ rows: 2; columns: 3; spacing: 3
+
+ Cell { cellColor: "red"; onClicked: helloText.color = cellColor }
+ Cell { cellColor: "green"; onClicked: helloText.color = cellColor }
+ Cell { cellColor: "blue"; onClicked: helloText.color = cellColor }
+ Cell { cellColor: "yellow"; onClicked: helloText.color = cellColor }
+ Cell { cellColor: "steelblue"; onClicked: helloText.color = cellColor }
+ Cell { cellColor: "black"; onClicked: helloText.color = cellColor }
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/qmlscene/tutorial3.qml b/Godeps/_workspace/src/github.com/obscuren/qml/examples/qmlscene/tutorial3.qml
new file mode 100644
index 000000000..e5eabab10
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/qmlscene/tutorial3.qml
@@ -0,0 +1,45 @@
+// See http://qt-project.org/doc/qt-5.1/qtquick/qml-tutorial3.html
+
+import QtQuick 2.0
+
+Rectangle {
+ id: page
+ width: 320; height: 480
+ color: "lightgray"
+
+ Text {
+ id: helloText
+ text: "Hello world!"
+ y: 30
+ anchors.horizontalCenter: page.horizontalCenter
+ font.pointSize: 24; font.bold: true
+
+ MouseArea { id: mouseArea; anchors.fill: parent }
+
+ states: State {
+ name: "down"; when: mouseArea.pressed == true
+ PropertyChanges { target: helloText; y: 160; rotation: 180; color: "red" }
+ }
+
+ transitions: Transition {
+ from: ""; to: "down"; reversible: true
+ ParallelAnimation {
+ NumberAnimation { properties: "y,rotation"; duration: 500; easing.type: Easing.InOutQuad }
+ ColorAnimation { duration: 500 }
+ }
+ }
+ }
+
+ Grid {
+ id: colorPicker
+ x: 4; anchors.bottom: page.bottom; anchors.bottomMargin: 4
+ rows: 2; columns: 3; spacing: 3
+
+ Cell { cellColor: "red"; onClicked: helloText.color = cellColor }
+ Cell { cellColor: "green"; onClicked: helloText.color = cellColor }
+ Cell { cellColor: "blue"; onClicked: helloText.color = cellColor }
+ Cell { cellColor: "yellow"; onClicked: helloText.color = cellColor }
+ Cell { cellColor: "steelblue"; onClicked: helloText.color = cellColor }
+ Cell { cellColor: "black"; onClicked: helloText.color = cellColor }
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/qrcpacking/assets/particle.png b/Godeps/_workspace/src/github.com/obscuren/qml/examples/qrcpacking/assets/particle.png
new file mode 100644
index 000000000..5c83896d2
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/qrcpacking/assets/particle.png
Binary files differ
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/qrcpacking/assets/particle.qml b/Godeps/_workspace/src/github.com/obscuren/qml/examples/qrcpacking/assets/particle.qml
new file mode 100644
index 000000000..2708a3dfc
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/qrcpacking/assets/particle.qml
@@ -0,0 +1,89 @@
+import QtQuick 2.0
+import QtQuick.Particles 2.0
+import QtGraphicalEffects 1.0;
+
+Rectangle {
+ id: root
+
+ width: 640
+ height: 480
+
+ gradient: Gradient {
+ GradientStop { position: 0.0; color: "#3a2c32"; }
+ GradientStop { position: 0.8; color: "#875864"; }
+ GradientStop { position: 1.0; color: "#9b616c"; }
+ }
+
+ Text {
+ text: ctrl.message
+
+ Component.onCompleted: {
+ x = parent.width/2 - width/2
+ y = parent.height/2 - height/2
+ }
+
+ color: "white"
+ font.bold: true
+ font.pointSize: 20
+
+ MouseArea {
+ id: mouseArea
+ anchors.fill: parent
+ drag.target: parent
+ onReleased: ctrl.textReleased(parent)
+ }
+ }
+
+ ParticleSystem { id: sys }
+
+ ImageParticle {
+ system: sys
+ source: "qrc:///assets/particle.png"
+ color: "white"
+ colorVariation: 1.0
+ alpha: 0.1
+ }
+
+ property var emitterComponent: Component {
+ id: emitterComponent
+ Emitter {
+ id: container
+ system: sys
+ Emitter {
+ system: sys
+ emitRate: 128
+ lifeSpan: 600
+ size: 16
+ endSize: 8
+ velocity: AngleDirection { angleVariation:360; magnitude: 60 }
+ }
+
+ property int life: 2600
+ property real targetX: 0
+ property real targetY: 0
+ emitRate: 128
+ lifeSpan: 600
+ size: 24
+ endSize: 8
+ NumberAnimation on x {
+ objectName: "xAnim"
+ id: xAnim;
+ to: targetX
+ duration: life
+ running: false
+ }
+ NumberAnimation on y {
+ objectName: "yAnim"
+ id: yAnim;
+ to: targetY
+ duration: life
+ running: false
+ }
+ Timer {
+ interval: life
+ running: true
+ onTriggered: ctrl.done(container)
+ }
+ }
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/qrcpacking/main.go b/Godeps/_workspace/src/github.com/obscuren/qml/examples/qrcpacking/main.go
new file mode 100644
index 000000000..a151cdb49
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/qrcpacking/main.go
@@ -0,0 +1,86 @@
+package main
+
+//go:generate genqrc assets
+
+import (
+ "fmt"
+ "math/rand"
+ "os"
+ "time"
+
+ "gopkg.in/qml.v1"
+)
+
+func main() {
+ if err := qml.Run(run); err != nil {
+ fmt.Fprintf(os.Stderr, "error: %v\n", err)
+ os.Exit(1)
+ }
+}
+
+func run() error {
+ engine := qml.NewEngine()
+ component, err := engine.LoadFile("qrc:///assets/particle.qml")
+ if err != nil {
+ return err
+ }
+
+ ctrl := Control{Message: "Hello from Go!"}
+
+ context := engine.Context()
+ context.SetVar("ctrl", &ctrl)
+
+ window := component.CreateWindow(nil)
+
+ ctrl.Root = window.Root()
+
+ rand.Seed(time.Now().Unix())
+
+ window.Show()
+ window.Wait()
+
+ return nil
+}
+
+type Control struct {
+ Root qml.Object
+ Message string
+}
+
+func (ctrl *Control) TextReleased(text qml.Object) {
+ x := text.Int("x")
+ y := text.Int("y")
+ width := text.Int("width")
+ height := text.Int("height")
+
+ ctrl.Emit(x+15, y+height/2)
+ ctrl.Emit(x+width/2, 1.0*y+height/2)
+ ctrl.Emit(x+width-15, 1.0*y+height/2)
+
+ go func() {
+ time.Sleep(500 * time.Millisecond)
+ messages := []string{"Hello", "Hello", "Hacks"}
+ ctrl.Message = messages[rand.Intn(len(messages))] + " from Go!"
+ qml.Changed(ctrl, &ctrl.Message)
+ }()
+}
+
+func (ctrl *Control) Emit(x, y int) {
+ component := ctrl.Root.Object("emitterComponent")
+ for i := 0; i < 8; i++ {
+ emitter := component.Create(nil)
+ emitter.Set("x", x)
+ emitter.Set("y", y)
+ emitter.Set("targetX", rand.Intn(240)-120+x)
+ emitter.Set("targetY", rand.Intn(240)-120+y)
+ emitter.Set("life", rand.Intn(2400)+200)
+ emitter.Set("emitRate", rand.Intn(32)+32)
+ emitter.ObjectByName("xAnim").Call("start")
+ emitter.ObjectByName("yAnim").Call("start")
+ emitter.Set("enabled", true)
+ }
+}
+
+func (ctrl *Control) Done(emitter qml.Object) {
+ emitter.Destroy()
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/qrcpacking/qrc.go b/Godeps/_workspace/src/github.com/obscuren/qml/examples/qrcpacking/qrc.go
new file mode 100644
index 000000000..7002e67f5
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/qrcpacking/qrc.go
@@ -0,0 +1,58 @@
+package main
+
+// This file is automatically generated by gopkg.in/qml.v1/cmd/genqrc
+
+import (
+ "io/ioutil"
+ "os"
+ "path/filepath"
+
+ "gopkg.in/qml.v1"
+)
+
+func init() {
+ var r *qml.Resources
+ var err error
+ if os.Getenv("QRC_REPACK") == "1" {
+ err = qrcRepackResources()
+ if err != nil {
+ panic("cannot repack qrc resources: " + err.Error())
+ }
+ r, err = qml.ParseResources(qrcResourcesRepacked)
+ } else {
+ r, err = qml.ParseResourcesString(qrcResourcesData)
+ }
+ if err != nil {
+ panic("cannot parse bundled resources data: " + err.Error())
+ }
+ qml.LoadResources(r)
+}
+
+func qrcRepackResources() error {
+ subdirs := []string{"assets"}
+ var rp qml.ResourcesPacker
+ for _, subdir := range subdirs {
+ err := filepath.Walk(subdir, func(path string, info os.FileInfo, err error) error {
+ if err != nil {
+ return err
+ }
+ if info.IsDir() {
+ return nil
+ }
+ data, err := ioutil.ReadFile(path)
+ if err != nil {
+ return err
+ }
+ rp.Add(filepath.ToSlash(path), data)
+ return nil
+ })
+ if err != nil {
+ return err
+ }
+ }
+ qrcResourcesRepacked = rp.Pack().Bytes()
+ return nil
+}
+
+var qrcResourcesRepacked []byte
+var qrcResourcesData = "qres\x00\x00\x00\x01\x00\x00\t\xeb\x00\x00\x00\x14\x00\x00\t\x9d\x00\x00\x03]\x89PNG\r\n\x1a\n\x00\x00\x00\rIHDR\x00\x00\x00 \x00\x00\x00 \b\x06\x00\x00\x00szz\xf4\x00\x00\x00\x19tEXtSoftware\x00Adobe ImageReadyq\xc9e<\x00\x00\x02\xffIDATxڔWM\x8f\xd40\fM\xd2t\x96\x0f\xed\xc2a\xf7\x00\a~\x01\xff\xff\x9fp\xe2\xc0\x05\x84\x84\x90X\x81\xc4\x0e\xdb6&\xae\x9c\xea\xcd\xc3閑\xacd\xda\xd4~v\x9e\x1d'\x87\xff\xf8\x89H\xaaC\x93hc\xd1W&:/1F9\xaa3\x9b\xe2\xbd5jh\xb0\xb5\x99\x9e\a3\x1c`^\xd5\xc9\\\xc7Ť\xaf8\xc6\v\x85=\x80W\xe6i\x00\xcf\x11\x84\x10\x90bϳ\x01\x98\xecY?\x02\x1d\xaf\xd5\xf0\b\x86Q\xdc\x1d\x82mXl\u07b6IA\xccG\x01\xe8G\xcf-\xec\tF\xde{6\x8e\\H\x06\"BĢ\x01\xd9\x05\x80\xc6\a\x02\xd18\x90H1\x86\xbe\x98\xa7\xed}!\x1e\bG\x82\x01\\\x81\xe1\f\xe3\b`\"\xf1\x80\xa3о\xe9\x85]\x10T&0#x<\xd8\xff\x11\xfe\xefeJp\xb6*:\xc63\x80\xdd\x00\xe8\xc2g\x90r͋\x93͙\xf9\t\x14F`y\x04\x0ed\xda\x1a\x01\xe7t\xfe\x88\x002(F\xef\xd9\xf3\x04{ޛ\x17\x00\x96\x81\x98\x02\xeb\xb6\"\xd6\x00\x8c\xf00\x01\xe1\xd8x\xa4T\x8c\x94~b\xdf,\xf0\xae9Q(3V\x00\xc9\xca+\xa7\xda@F\xd8x\xdaIS/:\x19\xb6\xb7\x8dj;採\xc1\xa9zhDS\xf5]\x95[c\xfb\xf7*\x9f\xab\xfc&\x1e\b\x01\xc7\xf3#\x06\nst\x1630\x95\x17U\xdeWym$Ue/\xab\xdcT\xf9P\xe5\x81·\xd4ѹ\xea\xcdNU\x8b\x0e\xeb\x11\xd8[3vm`\x16{\xae9\xff\xa6\xca'\xe2Fp\xf4\xfdC\xac^q\t\x8e\xa2W\x90\xa27\x96\xbe\xad~\\;\aT\xcf\xf8\xb6\x05\xd21\xea\xe5}\x006k\x1e\xff4\xcf'\xc8\xf7@\xa1\x96\x8e\xde\xf5}&/e'\x02M~X\xe8U\xf9\x1f3\xfa`r\x0f \x84\xb6\x82\x8fmi\x00\x8as\xa8`\xe1\xc0:\xaf\n\xbf\x1a\xe9f\x8b`\xb1h\xfc\xaa\xf2\xadcP\xbc\xc6E%\xc3\xc1\x80\v\x17\xe2\a\x82SO?V\xb93>Lf\\S\xf1\xdc1Th\xdc\xdegz\x89G*o\x0f\x16\x97\xb3\xe5\xfd\x17\xa7\x17\x10ꀚ\xbeB\xe7\xc2:\xa6ڗa\aS\x80d3\x9d\xe5\x05\xfa<\x9e\xb3\x0e!\xe33\x91t\xb1\x9ep;\v&\xaa\u05ed\x8dJ\xce\xe9\x17\bX\x8fh\xec\xc8\xe2Da\v\xb3\x17\x81؎L\xa74\xcbN\xca\x16\xe0\xd1#y/d\xebb\x9f\xcfV\xe3g'\rG:\xb2{-\x99P\x9d\xc0\bx\x1c\xb8\xe8\x88\xdaG'\xe8\xeb8\x9c\x83S\xd7y\r\x87\x9d\xe5\xa2/\xe4\x9ep2ţ-j\x8a\x13\x8c^\xe9\xe6L\xf0ȊϺMik\x95\xb0\x9bI\x0e\x00>\xf3\x99|\x9c\x15L\xc2\xdd{A\xe3\xc3\t.&\xec}\x82m\x92N\xd1\x11 \x12\xfd\xd0\xcd(\x00\x89F\xeaf\xc2\x13\xf7C&\x9bx\x17\x92#\x00\x02\x84n\xa0K\x898\x1c\xe8\x95\xde\xf2\xe4\xedXo\xa9G\x80h\x0fG\xc5)\x92\x81\x15@շ\x1c\xbd\x9e\xff\x15`\x00\xdfɄ\xff\xd7\x15\xb9\x95\x00\x00\x00\x00IEND\xaeB`\x82\x00\x00\x06$import QtQuick 2.0\nimport QtQuick.Particles 2.0\nimport QtGraphicalEffects 1.0;\n\nRectangle {\n\tid: root\n\n\twidth: 640\n\theight: 480\n\n\tgradient: Gradient {\n\t\tGradientStop { position: 0.0; color: \"#3a2c32\"; }\n\t\tGradientStop { position: 0.8; color: \"#875864\"; }\n\t\tGradientStop { position: 1.0; color: \"#9b616c\"; }\n\t}\n\n\tText {\n\t\ttext: ctrl.message\n\n\t\tComponent.onCompleted: {\n\t\t\tx = parent.width/2 - width/2\n\t\t\ty = parent.height/2 - height/2\n\t\t}\n\n\t\tcolor: \"white\"\n\t\tfont.bold: true\n\t\tfont.pointSize: 20\n\n\t\tMouseArea {\n\t\t id: mouseArea\n\t\t anchors.fill: parent\n\t\t drag.target: parent\n onReleased: ctrl.textReleased(parent)\n\t\t}\n\t}\n\n\tParticleSystem { id: sys }\n\n\tImageParticle {\n\t\tsystem: sys\n\t\tsource: \"qrc:///assets/particle.png\"\n\t\tcolor: \"white\"\n\t\tcolorVariation: 1.0\n\t\talpha: 0.1\n\t}\n\n\tproperty var emitterComponent: Component {\n\t\tid: emitterComponent\n\t\tEmitter {\n\t\t\tid: container\n\t\t\tsystem: sys\n\t\t\tEmitter {\n\t\t\t\tsystem: sys\n\t\t\t\temitRate: 128\n\t\t\t\tlifeSpan: 600\n\t\t\t\tsize: 16\n\t\t\t\tendSize: 8\n\t\t\t\tvelocity: AngleDirection { angleVariation:360; magnitude: 60 }\n\t\t\t}\n\n\t\t\tproperty int life: 2600\n\t\t\tproperty real targetX: 0\n\t\t\tproperty real targetY: 0\n\t\t\temitRate: 128\n\t\t\tlifeSpan: 600\n\t\t\tsize: 24\n\t\t\tendSize: 8\n\t\t\tNumberAnimation on x {\n\t\t\t\tobjectName: \"xAnim\"\n\t\t\t\tid: xAnim;\n\t\t\t\tto: targetX\n\t\t\t\tduration: life\n\t\t\t\trunning: false\n\t\t\t}\n\t\t\tNumberAnimation on y {\n\t\t\t\tobjectName: \"yAnim\"\n\t\t\t\tid: yAnim;\n\t\t\t\tto: targetY\n\t\t\t\tduration: life\n\t\t\t\trunning: false\n\t\t\t}\n\t\t\tTimer {\n\t\t\t\tinterval: life\n\t\t\t\trunning: true\n\t\t\t\tonTriggered: ctrl.done(container)\n\t\t\t}\n\t\t}\n\t}\n}\n\x00\x06\x06\x8a\x9c\xb3\x00a\x00s\x00s\x00e\x00t\x00s\x00\f\b\xf9b\xa7\x00p\x00a\x00r\x00t\x00i\x00c\x00l\x00e\x00.\x00p\x00n\x00g\x00\f\b\xf9e\xdc\x00p\x00a\x00r\x00t\x00i\x00c\x00l\x00e\x00.\x00q\x00m\x00l\x00\x00\x00\x00\x00\x02\x00\x00\x00\x01\x00\x00\x00\x01\x00\x00\x00\x00\x00\x02\x00\x00\x00\x02\x00\x00\x00\x02\x00\x00\x00\x12\x00\x00\x00\x00\x00\x01\x00\x00\x00\x00\x00\x00\x000\x00\x00\x00\x00\x00\x01\x00\x00\x03a"
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/reparent/base.qml b/Godeps/_workspace/src/github.com/obscuren/qml/examples/reparent/base.qml
new file mode 100644
index 000000000..a77243e37
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/reparent/base.qml
@@ -0,0 +1,7 @@
+import QtQuick 2.0
+
+Rectangle {
+ width: 640
+ height: 480
+ color: "black"
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/reparent/rect.qml b/Godeps/_workspace/src/github.com/obscuren/qml/examples/reparent/rect.qml
new file mode 100644
index 000000000..21eda2fea
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/reparent/rect.qml
@@ -0,0 +1,8 @@
+import QtQuick 2.0
+
+Rectangle {
+ anchors.centerIn: parent
+ width: 50
+ height: 50
+ color: "red"
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/reparent/reparent.go b/Godeps/_workspace/src/github.com/obscuren/qml/examples/reparent/reparent.go
new file mode 100644
index 000000000..c1399f88c
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/reparent/reparent.go
@@ -0,0 +1,37 @@
+package main
+
+import (
+ "fmt"
+ "gopkg.in/qml.v1"
+ "os"
+)
+
+func main() {
+ if err := qml.Run(run); err != nil {
+ fmt.Fprintf(os.Stderr, "error: %v\n", err)
+ os.Exit(1)
+ }
+}
+
+func run() error {
+ engine := qml.NewEngine()
+
+ base, err := engine.LoadFile("base.qml")
+ if err != nil {
+ return err
+ }
+ rect, err := engine.LoadFile("rect.qml")
+ if err != nil {
+ return err
+ }
+
+ win := base.CreateWindow(nil)
+ obj := rect.Create(nil)
+
+ obj.Set("parent", win.Root())
+
+ win.Show()
+ win.Wait()
+
+ return nil
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/examples/snapweb/snapweb.go b/Godeps/_workspace/src/github.com/obscuren/qml/examples/snapweb/snapweb.go
new file mode 100644
index 000000000..53d1d6210
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/examples/snapweb/snapweb.go
@@ -0,0 +1,70 @@
+package main
+
+import (
+ "fmt"
+ "gopkg.in/qml.v1"
+ "image/png"
+ "os"
+)
+
+const webview = `
+import QtQuick 2.0
+import QtWebKit 3.0
+
+WebView {
+ width: 1024
+ height: 768
+}
+`
+
+func main() {
+ if len(os.Args) != 3 {
+ fmt.Fprintf(os.Stderr, "usage: %s <url> <png path>\n", os.Args[0])
+ os.Exit(1)
+ }
+ if err := qml.Run(run); err != nil {
+ fmt.Fprintf(os.Stderr, "error: %v\n", err)
+ os.Exit(1)
+ }
+}
+
+func run() error {
+ engine := qml.NewEngine()
+ component, err := engine.LoadString("webview.qml", webview)
+ if err != nil {
+ return err
+ }
+ ctrl := &Control{
+ done: make(chan error),
+ win: component.CreateWindow(nil),
+ }
+ engine.Context().SetVar("ctrl", ctrl)
+ root := ctrl.win.Root()
+ root.On("loadingChanged", ctrl.Snapshot)
+ root.Set("url", os.Args[1])
+ ctrl.win.Show()
+ return <-ctrl.done
+}
+
+type Control struct {
+ win *qml.Window
+ done chan error
+}
+
+func (ctrl *Control) Snapshot(request qml.Object) {
+ if request.Int("status") != 2 {
+ return
+ }
+ f, err := os.Create(os.Args[2])
+ if err != nil {
+ ctrl.done <- err
+ return
+ }
+ defer f.Close()
+ img := ctrl.win.Snapshot()
+ err = png.Encode(f, img)
+ if err != nil {
+ os.Remove(os.Args[2])
+ }
+ ctrl.done <- err
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/1.0/funcs.cpp b/Godeps/_workspace/src/github.com/obscuren/qml/gl/1.0/funcs.cpp
new file mode 100644
index 000000000..d7d9cf657
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/1.0/funcs.cpp
@@ -0,0 +1,1848 @@
+
+// ** file automatically generated by glgen -- do not edit manually **
+
+#include <QOpenGLContext>
+#include <QtGui/qopenglfunctions_1_0.h>
+
+#include "funcs.h"
+
+void *gl1_0_funcs() {
+ QOpenGLFunctions_1_0* funcs = QOpenGLContext::currentContext()->versionFunctions<QOpenGLFunctions_1_0>();
+ if (!funcs) {
+ return 0;
+ }
+ funcs->initializeOpenGLFunctions();
+ return funcs;
+}
+
+
+void gl1_0_glViewport(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glViewport(x, y, width, height);
+}
+
+void gl1_0_glDepthRange(void *_glfuncs, GLdouble nearVal, GLdouble farVal)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glDepthRange(nearVal, farVal);
+}
+
+GLboolean gl1_0_glIsEnabled(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ return _qglfuncs->glIsEnabled(cap);
+}
+
+void gl1_0_glGetTexLevelParameteriv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glGetTexLevelParameteriv(target, level, pname, params);
+}
+
+void gl1_0_glGetTexLevelParameterfv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glGetTexLevelParameterfv(target, level, pname, params);
+}
+
+void gl1_0_glGetTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glGetTexParameteriv(target, pname, params);
+}
+
+void gl1_0_glGetTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glGetTexParameterfv(target, pname, params);
+}
+
+void gl1_0_glGetTexImage(void *_glfuncs, GLenum target, GLint level, GLenum format, GLenum gltype, GLvoid* pixels)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glGetTexImage(target, level, format, gltype, pixels);
+}
+
+void gl1_0_glGetIntegerv(void *_glfuncs, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glGetIntegerv(pname, params);
+}
+
+void gl1_0_glGetFloatv(void *_glfuncs, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glGetFloatv(pname, params);
+}
+
+GLenum gl1_0_glGetError(void *_glfuncs)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ return _qglfuncs->glGetError();
+}
+
+void gl1_0_glGetDoublev(void *_glfuncs, GLenum pname, GLdouble* params)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glGetDoublev(pname, params);
+}
+
+void gl1_0_glGetBooleanv(void *_glfuncs, GLenum pname, GLboolean* params)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glGetBooleanv(pname, params);
+}
+
+void gl1_0_glReadPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum gltype, GLvoid* pixels)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glReadPixels(x, y, width, height, format, gltype, pixels);
+}
+
+void gl1_0_glReadBuffer(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glReadBuffer(mode);
+}
+
+void gl1_0_glPixelStorei(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glPixelStorei(pname, param);
+}
+
+void gl1_0_glPixelStoref(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glPixelStoref(pname, param);
+}
+
+void gl1_0_glDepthFunc(void *_glfuncs, GLenum glfunc)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glDepthFunc(glfunc);
+}
+
+void gl1_0_glStencilOp(void *_glfuncs, GLenum fail, GLenum zfail, GLenum zpass)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glStencilOp(fail, zfail, zpass);
+}
+
+void gl1_0_glStencilFunc(void *_glfuncs, GLenum glfunc, GLint ref, GLuint mask)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glStencilFunc(glfunc, ref, mask);
+}
+
+void gl1_0_glLogicOp(void *_glfuncs, GLenum opcode)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glLogicOp(opcode);
+}
+
+void gl1_0_glBlendFunc(void *_glfuncs, GLenum sfactor, GLenum dfactor)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glBlendFunc(sfactor, dfactor);
+}
+
+void gl1_0_glFlush(void *_glfuncs)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glFlush();
+}
+
+void gl1_0_glFinish(void *_glfuncs)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glFinish();
+}
+
+void gl1_0_glEnable(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glEnable(cap);
+}
+
+void gl1_0_glDisable(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glDisable(cap);
+}
+
+void gl1_0_glDepthMask(void *_glfuncs, GLboolean flag)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glDepthMask(flag);
+}
+
+void gl1_0_glColorMask(void *_glfuncs, GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glColorMask(red, green, blue, alpha);
+}
+
+void gl1_0_glStencilMask(void *_glfuncs, GLuint mask)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glStencilMask(mask);
+}
+
+void gl1_0_glClearDepth(void *_glfuncs, GLdouble depth)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glClearDepth(depth);
+}
+
+void gl1_0_glClearStencil(void *_glfuncs, GLint s)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glClearStencil(s);
+}
+
+void gl1_0_glClearColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glClearColor(red, green, blue, alpha);
+}
+
+void gl1_0_glClear(void *_glfuncs, GLbitfield mask)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glClear(mask);
+}
+
+void gl1_0_glDrawBuffer(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glDrawBuffer(mode);
+}
+
+void gl1_0_glTexImage2D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glTexImage2D(target, level, internalFormat, width, height, border, format, gltype, pixels);
+}
+
+void gl1_0_glTexImage1D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glTexImage1D(target, level, internalFormat, width, border, format, gltype, pixels);
+}
+
+void gl1_0_glTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glTexParameteriv(target, pname, params);
+}
+
+void gl1_0_glTexParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glTexParameteri(target, pname, param);
+}
+
+void gl1_0_glTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glTexParameterfv(target, pname, params);
+}
+
+void gl1_0_glTexParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glTexParameterf(target, pname, param);
+}
+
+void gl1_0_glScissor(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glScissor(x, y, width, height);
+}
+
+void gl1_0_glPolygonMode(void *_glfuncs, GLenum face, GLenum mode)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glPolygonMode(face, mode);
+}
+
+void gl1_0_glPointSize(void *_glfuncs, GLfloat size)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glPointSize(size);
+}
+
+void gl1_0_glLineWidth(void *_glfuncs, GLfloat width)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glLineWidth(width);
+}
+
+void gl1_0_glHint(void *_glfuncs, GLenum target, GLenum mode)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glHint(target, mode);
+}
+
+void gl1_0_glFrontFace(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glFrontFace(mode);
+}
+
+void gl1_0_glCullFace(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glCullFace(mode);
+}
+
+void gl1_0_glTranslatef(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glTranslatef(x, y, z);
+}
+
+void gl1_0_glTranslated(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glTranslated(x, y, z);
+}
+
+void gl1_0_glScalef(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glScalef(x, y, z);
+}
+
+void gl1_0_glScaled(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glScaled(x, y, z);
+}
+
+void gl1_0_glRotatef(void *_glfuncs, GLfloat angle, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glRotatef(angle, x, y, z);
+}
+
+void gl1_0_glRotated(void *_glfuncs, GLdouble angle, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glRotated(angle, x, y, z);
+}
+
+void gl1_0_glPushMatrix(void *_glfuncs)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glPushMatrix();
+}
+
+void gl1_0_glPopMatrix(void *_glfuncs)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glPopMatrix();
+}
+
+void gl1_0_glOrtho(void *_glfuncs, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glOrtho(left, right, bottom, top, zNear, zFar);
+}
+
+void gl1_0_glMultMatrixd(void *_glfuncs, const GLdouble* m)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glMultMatrixd(m);
+}
+
+void gl1_0_glMultMatrixf(void *_glfuncs, const GLfloat* m)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glMultMatrixf(m);
+}
+
+void gl1_0_glMatrixMode(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glMatrixMode(mode);
+}
+
+void gl1_0_glLoadMatrixd(void *_glfuncs, const GLdouble* m)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glLoadMatrixd(m);
+}
+
+void gl1_0_glLoadMatrixf(void *_glfuncs, const GLfloat* m)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glLoadMatrixf(m);
+}
+
+void gl1_0_glLoadIdentity(void *_glfuncs)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glLoadIdentity();
+}
+
+void gl1_0_glFrustum(void *_glfuncs, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glFrustum(left, right, bottom, top, zNear, zFar);
+}
+
+GLboolean gl1_0_glIsList(void *_glfuncs, GLuint list)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ return _qglfuncs->glIsList(list);
+}
+
+void gl1_0_glGetTexGeniv(void *_glfuncs, GLenum coord, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glGetTexGeniv(coord, pname, params);
+}
+
+void gl1_0_glGetTexGenfv(void *_glfuncs, GLenum coord, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glGetTexGenfv(coord, pname, params);
+}
+
+void gl1_0_glGetTexGendv(void *_glfuncs, GLenum coord, GLenum pname, GLdouble* params)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glGetTexGendv(coord, pname, params);
+}
+
+void gl1_0_glGetTexEnviv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glGetTexEnviv(target, pname, params);
+}
+
+void gl1_0_glGetTexEnvfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glGetTexEnvfv(target, pname, params);
+}
+
+void gl1_0_glGetPolygonStipple(void *_glfuncs, GLubyte* mask)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glGetPolygonStipple(mask);
+}
+
+void gl1_0_glGetPixelMapusv(void *_glfuncs, GLenum glmap, GLushort* values)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glGetPixelMapusv(glmap, values);
+}
+
+void gl1_0_glGetPixelMapuiv(void *_glfuncs, GLenum glmap, GLuint* values)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glGetPixelMapuiv(glmap, values);
+}
+
+void gl1_0_glGetPixelMapfv(void *_glfuncs, GLenum glmap, GLfloat* values)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glGetPixelMapfv(glmap, values);
+}
+
+void gl1_0_glGetMaterialiv(void *_glfuncs, GLenum face, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glGetMaterialiv(face, pname, params);
+}
+
+void gl1_0_glGetMaterialfv(void *_glfuncs, GLenum face, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glGetMaterialfv(face, pname, params);
+}
+
+void gl1_0_glGetMapiv(void *_glfuncs, GLenum target, GLenum query, GLint* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glGetMapiv(target, query, v);
+}
+
+void gl1_0_glGetMapfv(void *_glfuncs, GLenum target, GLenum query, GLfloat* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glGetMapfv(target, query, v);
+}
+
+void gl1_0_glGetMapdv(void *_glfuncs, GLenum target, GLenum query, GLdouble* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glGetMapdv(target, query, v);
+}
+
+void gl1_0_glGetLightiv(void *_glfuncs, GLenum light, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glGetLightiv(light, pname, params);
+}
+
+void gl1_0_glGetLightfv(void *_glfuncs, GLenum light, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glGetLightfv(light, pname, params);
+}
+
+void gl1_0_glGetClipPlane(void *_glfuncs, GLenum plane, GLdouble* equation)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glGetClipPlane(plane, equation);
+}
+
+void gl1_0_glDrawPixels(void *_glfuncs, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glDrawPixels(width, height, format, gltype, pixels);
+}
+
+void gl1_0_glCopyPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum gltype)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glCopyPixels(x, y, width, height, gltype);
+}
+
+void gl1_0_glPixelMapusv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLushort* values)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glPixelMapusv(glmap, mapsize, values);
+}
+
+void gl1_0_glPixelMapuiv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLuint* values)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glPixelMapuiv(glmap, mapsize, values);
+}
+
+void gl1_0_glPixelMapfv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLfloat* values)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glPixelMapfv(glmap, mapsize, values);
+}
+
+void gl1_0_glPixelTransferi(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glPixelTransferi(pname, param);
+}
+
+void gl1_0_glPixelTransferf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glPixelTransferf(pname, param);
+}
+
+void gl1_0_glPixelZoom(void *_glfuncs, GLfloat xfactor, GLfloat yfactor)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glPixelZoom(xfactor, yfactor);
+}
+
+void gl1_0_glAlphaFunc(void *_glfuncs, GLenum glfunc, GLfloat ref)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glAlphaFunc(glfunc, ref);
+}
+
+void gl1_0_glEvalPoint2(void *_glfuncs, GLint i, GLint j)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glEvalPoint2(i, j);
+}
+
+void gl1_0_glEvalMesh2(void *_glfuncs, GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glEvalMesh2(mode, i1, i2, j1, j2);
+}
+
+void gl1_0_glEvalPoint1(void *_glfuncs, GLint i)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glEvalPoint1(i);
+}
+
+void gl1_0_glEvalMesh1(void *_glfuncs, GLenum mode, GLint i1, GLint i2)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glEvalMesh1(mode, i1, i2);
+}
+
+void gl1_0_glEvalCoord2fv(void *_glfuncs, const GLfloat* u)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glEvalCoord2fv(u);
+}
+
+void gl1_0_glEvalCoord2f(void *_glfuncs, GLfloat u, GLfloat v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glEvalCoord2f(u, v);
+}
+
+void gl1_0_glEvalCoord2dv(void *_glfuncs, const GLdouble* u)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glEvalCoord2dv(u);
+}
+
+void gl1_0_glEvalCoord2d(void *_glfuncs, GLdouble u, GLdouble v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glEvalCoord2d(u, v);
+}
+
+void gl1_0_glEvalCoord1fv(void *_glfuncs, const GLfloat* u)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glEvalCoord1fv(u);
+}
+
+void gl1_0_glEvalCoord1f(void *_glfuncs, GLfloat u)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glEvalCoord1f(u);
+}
+
+void gl1_0_glEvalCoord1dv(void *_glfuncs, const GLdouble* u)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glEvalCoord1dv(u);
+}
+
+void gl1_0_glEvalCoord1d(void *_glfuncs, GLdouble u)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glEvalCoord1d(u);
+}
+
+void gl1_0_glMapGrid2f(void *_glfuncs, GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glMapGrid2f(un, u1, u2, vn, v1, v2);
+}
+
+void gl1_0_glMapGrid2d(void *_glfuncs, GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glMapGrid2d(un, u1, u2, vn, v1, v2);
+}
+
+void gl1_0_glMapGrid1f(void *_glfuncs, GLint un, GLfloat u1, GLfloat u2)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glMapGrid1f(un, u1, u2);
+}
+
+void gl1_0_glMapGrid1d(void *_glfuncs, GLint un, GLdouble u1, GLdouble u2)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glMapGrid1d(un, u1, u2);
+}
+
+void gl1_0_glMap2f(void *_glfuncs, GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat* points)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glMap2f(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+void gl1_0_glMap2d(void *_glfuncs, GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble* points)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glMap2d(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+void gl1_0_glMap1f(void *_glfuncs, GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat* points)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glMap1f(target, u1, u2, stride, order, points);
+}
+
+void gl1_0_glMap1d(void *_glfuncs, GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble* points)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glMap1d(target, u1, u2, stride, order, points);
+}
+
+void gl1_0_glPushAttrib(void *_glfuncs, GLbitfield mask)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glPushAttrib(mask);
+}
+
+void gl1_0_glPopAttrib(void *_glfuncs)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glPopAttrib();
+}
+
+void gl1_0_glAccum(void *_glfuncs, GLenum op, GLfloat value)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glAccum(op, value);
+}
+
+void gl1_0_glIndexMask(void *_glfuncs, GLuint mask)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glIndexMask(mask);
+}
+
+void gl1_0_glClearIndex(void *_glfuncs, GLfloat c)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glClearIndex(c);
+}
+
+void gl1_0_glClearAccum(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glClearAccum(red, green, blue, alpha);
+}
+
+void gl1_0_glPushName(void *_glfuncs, GLuint name)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glPushName(name);
+}
+
+void gl1_0_glPopName(void *_glfuncs)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glPopName();
+}
+
+void gl1_0_glPassThrough(void *_glfuncs, GLfloat token)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glPassThrough(token);
+}
+
+void gl1_0_glLoadName(void *_glfuncs, GLuint name)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glLoadName(name);
+}
+
+void gl1_0_glInitNames(void *_glfuncs)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glInitNames();
+}
+
+GLint gl1_0_glRenderMode(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ return _qglfuncs->glRenderMode(mode);
+}
+
+void gl1_0_glSelectBuffer(void *_glfuncs, GLsizei size, GLuint* buffer)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glSelectBuffer(size, buffer);
+}
+
+void gl1_0_glFeedbackBuffer(void *_glfuncs, GLsizei size, GLenum gltype, GLfloat* buffer)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glFeedbackBuffer(size, gltype, buffer);
+}
+
+void gl1_0_glTexGeniv(void *_glfuncs, GLenum coord, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glTexGeniv(coord, pname, params);
+}
+
+void gl1_0_glTexGeni(void *_glfuncs, GLenum coord, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glTexGeni(coord, pname, param);
+}
+
+void gl1_0_glTexGenfv(void *_glfuncs, GLenum coord, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glTexGenfv(coord, pname, params);
+}
+
+void gl1_0_glTexGenf(void *_glfuncs, GLenum coord, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glTexGenf(coord, pname, param);
+}
+
+void gl1_0_glTexGendv(void *_glfuncs, GLenum coord, GLenum pname, const GLdouble* params)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glTexGendv(coord, pname, params);
+}
+
+void gl1_0_glTexGend(void *_glfuncs, GLenum coord, GLenum pname, GLdouble param)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glTexGend(coord, pname, param);
+}
+
+void gl1_0_glTexEnviv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glTexEnviv(target, pname, params);
+}
+
+void gl1_0_glTexEnvi(void *_glfuncs, GLenum target, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glTexEnvi(target, pname, param);
+}
+
+void gl1_0_glTexEnvfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glTexEnvfv(target, pname, params);
+}
+
+void gl1_0_glTexEnvf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glTexEnvf(target, pname, param);
+}
+
+void gl1_0_glShadeModel(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glShadeModel(mode);
+}
+
+void gl1_0_glPolygonStipple(void *_glfuncs, const GLubyte* mask)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glPolygonStipple(mask);
+}
+
+void gl1_0_glMaterialiv(void *_glfuncs, GLenum face, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glMaterialiv(face, pname, params);
+}
+
+void gl1_0_glMateriali(void *_glfuncs, GLenum face, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glMateriali(face, pname, param);
+}
+
+void gl1_0_glMaterialfv(void *_glfuncs, GLenum face, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glMaterialfv(face, pname, params);
+}
+
+void gl1_0_glMaterialf(void *_glfuncs, GLenum face, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glMaterialf(face, pname, param);
+}
+
+void gl1_0_glLineStipple(void *_glfuncs, GLint factor, GLushort pattern)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glLineStipple(factor, pattern);
+}
+
+void gl1_0_glLightModeliv(void *_glfuncs, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glLightModeliv(pname, params);
+}
+
+void gl1_0_glLightModeli(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glLightModeli(pname, param);
+}
+
+void gl1_0_glLightModelfv(void *_glfuncs, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glLightModelfv(pname, params);
+}
+
+void gl1_0_glLightModelf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glLightModelf(pname, param);
+}
+
+void gl1_0_glLightiv(void *_glfuncs, GLenum light, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glLightiv(light, pname, params);
+}
+
+void gl1_0_glLighti(void *_glfuncs, GLenum light, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glLighti(light, pname, param);
+}
+
+void gl1_0_glLightfv(void *_glfuncs, GLenum light, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glLightfv(light, pname, params);
+}
+
+void gl1_0_glLightf(void *_glfuncs, GLenum light, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glLightf(light, pname, param);
+}
+
+void gl1_0_glFogiv(void *_glfuncs, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glFogiv(pname, params);
+}
+
+void gl1_0_glFogi(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glFogi(pname, param);
+}
+
+void gl1_0_glFogfv(void *_glfuncs, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glFogfv(pname, params);
+}
+
+void gl1_0_glFogf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glFogf(pname, param);
+}
+
+void gl1_0_glColorMaterial(void *_glfuncs, GLenum face, GLenum mode)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glColorMaterial(face, mode);
+}
+
+void gl1_0_glClipPlane(void *_glfuncs, GLenum plane, const GLdouble* equation)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glClipPlane(plane, equation);
+}
+
+void gl1_0_glVertex4sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glVertex4sv(v);
+}
+
+void gl1_0_glVertex4s(void *_glfuncs, GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glVertex4s(x, y, z, w);
+}
+
+void gl1_0_glVertex4iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glVertex4iv(v);
+}
+
+void gl1_0_glVertex4i(void *_glfuncs, GLint x, GLint y, GLint z, GLint w)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glVertex4i(x, y, z, w);
+}
+
+void gl1_0_glVertex4fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glVertex4fv(v);
+}
+
+void gl1_0_glVertex4f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glVertex4f(x, y, z, w);
+}
+
+void gl1_0_glVertex4dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glVertex4dv(v);
+}
+
+void gl1_0_glVertex4d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glVertex4d(x, y, z, w);
+}
+
+void gl1_0_glVertex3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glVertex3sv(v);
+}
+
+void gl1_0_glVertex3s(void *_glfuncs, GLshort x, GLshort y, GLshort z)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glVertex3s(x, y, z);
+}
+
+void gl1_0_glVertex3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glVertex3iv(v);
+}
+
+void gl1_0_glVertex3i(void *_glfuncs, GLint x, GLint y, GLint z)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glVertex3i(x, y, z);
+}
+
+void gl1_0_glVertex3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glVertex3fv(v);
+}
+
+void gl1_0_glVertex3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glVertex3f(x, y, z);
+}
+
+void gl1_0_glVertex3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glVertex3dv(v);
+}
+
+void gl1_0_glVertex3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glVertex3d(x, y, z);
+}
+
+void gl1_0_glVertex2sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glVertex2sv(v);
+}
+
+void gl1_0_glVertex2s(void *_glfuncs, GLshort x, GLshort y)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glVertex2s(x, y);
+}
+
+void gl1_0_glVertex2iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glVertex2iv(v);
+}
+
+void gl1_0_glVertex2i(void *_glfuncs, GLint x, GLint y)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glVertex2i(x, y);
+}
+
+void gl1_0_glVertex2fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glVertex2fv(v);
+}
+
+void gl1_0_glVertex2f(void *_glfuncs, GLfloat x, GLfloat y)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glVertex2f(x, y);
+}
+
+void gl1_0_glVertex2dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glVertex2dv(v);
+}
+
+void gl1_0_glVertex2d(void *_glfuncs, GLdouble x, GLdouble y)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glVertex2d(x, y);
+}
+
+void gl1_0_glTexCoord4sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glTexCoord4sv(v);
+}
+
+void gl1_0_glTexCoord4s(void *_glfuncs, GLshort s, GLshort t, GLshort r, GLshort q)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glTexCoord4s(s, t, r, q);
+}
+
+void gl1_0_glTexCoord4iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glTexCoord4iv(v);
+}
+
+void gl1_0_glTexCoord4i(void *_glfuncs, GLint s, GLint t, GLint r, GLint q)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glTexCoord4i(s, t, r, q);
+}
+
+void gl1_0_glTexCoord4fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glTexCoord4fv(v);
+}
+
+void gl1_0_glTexCoord4f(void *_glfuncs, GLfloat s, GLfloat t, GLfloat r, GLfloat q)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glTexCoord4f(s, t, r, q);
+}
+
+void gl1_0_glTexCoord4dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glTexCoord4dv(v);
+}
+
+void gl1_0_glTexCoord4d(void *_glfuncs, GLdouble s, GLdouble t, GLdouble r, GLdouble q)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glTexCoord4d(s, t, r, q);
+}
+
+void gl1_0_glTexCoord3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glTexCoord3sv(v);
+}
+
+void gl1_0_glTexCoord3s(void *_glfuncs, GLshort s, GLshort t, GLshort r)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glTexCoord3s(s, t, r);
+}
+
+void gl1_0_glTexCoord3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glTexCoord3iv(v);
+}
+
+void gl1_0_glTexCoord3i(void *_glfuncs, GLint s, GLint t, GLint r)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glTexCoord3i(s, t, r);
+}
+
+void gl1_0_glTexCoord3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glTexCoord3fv(v);
+}
+
+void gl1_0_glTexCoord3f(void *_glfuncs, GLfloat s, GLfloat t, GLfloat r)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glTexCoord3f(s, t, r);
+}
+
+void gl1_0_glTexCoord3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glTexCoord3dv(v);
+}
+
+void gl1_0_glTexCoord3d(void *_glfuncs, GLdouble s, GLdouble t, GLdouble r)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glTexCoord3d(s, t, r);
+}
+
+void gl1_0_glTexCoord2sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glTexCoord2sv(v);
+}
+
+void gl1_0_glTexCoord2s(void *_glfuncs, GLshort s, GLshort t)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glTexCoord2s(s, t);
+}
+
+void gl1_0_glTexCoord2iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glTexCoord2iv(v);
+}
+
+void gl1_0_glTexCoord2i(void *_glfuncs, GLint s, GLint t)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glTexCoord2i(s, t);
+}
+
+void gl1_0_glTexCoord2fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glTexCoord2fv(v);
+}
+
+void gl1_0_glTexCoord2f(void *_glfuncs, GLfloat s, GLfloat t)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glTexCoord2f(s, t);
+}
+
+void gl1_0_glTexCoord2dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glTexCoord2dv(v);
+}
+
+void gl1_0_glTexCoord2d(void *_glfuncs, GLdouble s, GLdouble t)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glTexCoord2d(s, t);
+}
+
+void gl1_0_glTexCoord1sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glTexCoord1sv(v);
+}
+
+void gl1_0_glTexCoord1s(void *_glfuncs, GLshort s)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glTexCoord1s(s);
+}
+
+void gl1_0_glTexCoord1iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glTexCoord1iv(v);
+}
+
+void gl1_0_glTexCoord1i(void *_glfuncs, GLint s)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glTexCoord1i(s);
+}
+
+void gl1_0_glTexCoord1fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glTexCoord1fv(v);
+}
+
+void gl1_0_glTexCoord1f(void *_glfuncs, GLfloat s)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glTexCoord1f(s);
+}
+
+void gl1_0_glTexCoord1dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glTexCoord1dv(v);
+}
+
+void gl1_0_glTexCoord1d(void *_glfuncs, GLdouble s)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glTexCoord1d(s);
+}
+
+void gl1_0_glRectsv(void *_glfuncs, const GLshort* v1, const GLshort* v2)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glRectsv(v1, v2);
+}
+
+void gl1_0_glRects(void *_glfuncs, GLshort x1, GLshort y1, GLshort x2, GLshort y2)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glRects(x1, y1, x2, y2);
+}
+
+void gl1_0_glRectiv(void *_glfuncs, const GLint* v1, const GLint* v2)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glRectiv(v1, v2);
+}
+
+void gl1_0_glRecti(void *_glfuncs, GLint x1, GLint y1, GLint x2, GLint y2)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glRecti(x1, y1, x2, y2);
+}
+
+void gl1_0_glRectfv(void *_glfuncs, const GLfloat* v1, const GLfloat* v2)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glRectfv(v1, v2);
+}
+
+void gl1_0_glRectf(void *_glfuncs, GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glRectf(x1, y1, x2, y2);
+}
+
+void gl1_0_glRectdv(void *_glfuncs, const GLdouble* v1, const GLdouble* v2)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glRectdv(v1, v2);
+}
+
+void gl1_0_glRectd(void *_glfuncs, GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glRectd(x1, y1, x2, y2);
+}
+
+void gl1_0_glRasterPos4sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glRasterPos4sv(v);
+}
+
+void gl1_0_glRasterPos4s(void *_glfuncs, GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glRasterPos4s(x, y, z, w);
+}
+
+void gl1_0_glRasterPos4iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glRasterPos4iv(v);
+}
+
+void gl1_0_glRasterPos4i(void *_glfuncs, GLint x, GLint y, GLint z, GLint w)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glRasterPos4i(x, y, z, w);
+}
+
+void gl1_0_glRasterPos4fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glRasterPos4fv(v);
+}
+
+void gl1_0_glRasterPos4f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glRasterPos4f(x, y, z, w);
+}
+
+void gl1_0_glRasterPos4dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glRasterPos4dv(v);
+}
+
+void gl1_0_glRasterPos4d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glRasterPos4d(x, y, z, w);
+}
+
+void gl1_0_glRasterPos3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glRasterPos3sv(v);
+}
+
+void gl1_0_glRasterPos3s(void *_glfuncs, GLshort x, GLshort y, GLshort z)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glRasterPos3s(x, y, z);
+}
+
+void gl1_0_glRasterPos3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glRasterPos3iv(v);
+}
+
+void gl1_0_glRasterPos3i(void *_glfuncs, GLint x, GLint y, GLint z)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glRasterPos3i(x, y, z);
+}
+
+void gl1_0_glRasterPos3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glRasterPos3fv(v);
+}
+
+void gl1_0_glRasterPos3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glRasterPos3f(x, y, z);
+}
+
+void gl1_0_glRasterPos3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glRasterPos3dv(v);
+}
+
+void gl1_0_glRasterPos3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glRasterPos3d(x, y, z);
+}
+
+void gl1_0_glRasterPos2sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glRasterPos2sv(v);
+}
+
+void gl1_0_glRasterPos2s(void *_glfuncs, GLshort x, GLshort y)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glRasterPos2s(x, y);
+}
+
+void gl1_0_glRasterPos2iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glRasterPos2iv(v);
+}
+
+void gl1_0_glRasterPos2i(void *_glfuncs, GLint x, GLint y)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glRasterPos2i(x, y);
+}
+
+void gl1_0_glRasterPos2fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glRasterPos2fv(v);
+}
+
+void gl1_0_glRasterPos2f(void *_glfuncs, GLfloat x, GLfloat y)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glRasterPos2f(x, y);
+}
+
+void gl1_0_glRasterPos2dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glRasterPos2dv(v);
+}
+
+void gl1_0_glRasterPos2d(void *_glfuncs, GLdouble x, GLdouble y)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glRasterPos2d(x, y);
+}
+
+void gl1_0_glNormal3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glNormal3sv(v);
+}
+
+void gl1_0_glNormal3s(void *_glfuncs, GLshort nx, GLshort ny, GLshort nz)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glNormal3s(nx, ny, nz);
+}
+
+void gl1_0_glNormal3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glNormal3iv(v);
+}
+
+void gl1_0_glNormal3i(void *_glfuncs, GLint nx, GLint ny, GLint nz)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glNormal3i(nx, ny, nz);
+}
+
+void gl1_0_glNormal3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glNormal3fv(v);
+}
+
+void gl1_0_glNormal3f(void *_glfuncs, GLfloat nx, GLfloat ny, GLfloat nz)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glNormal3f(nx, ny, nz);
+}
+
+void gl1_0_glNormal3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glNormal3dv(v);
+}
+
+void gl1_0_glNormal3d(void *_glfuncs, GLdouble nx, GLdouble ny, GLdouble nz)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glNormal3d(nx, ny, nz);
+}
+
+void gl1_0_glNormal3bv(void *_glfuncs, const GLbyte* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glNormal3bv(v);
+}
+
+void gl1_0_glNormal3b(void *_glfuncs, GLbyte nx, GLbyte ny, GLbyte nz)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glNormal3b(nx, ny, nz);
+}
+
+void gl1_0_glIndexsv(void *_glfuncs, const GLshort* c)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glIndexsv(c);
+}
+
+void gl1_0_glIndexs(void *_glfuncs, GLshort c)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glIndexs(c);
+}
+
+void gl1_0_glIndexiv(void *_glfuncs, const GLint* c)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glIndexiv(c);
+}
+
+void gl1_0_glIndexi(void *_glfuncs, GLint c)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glIndexi(c);
+}
+
+void gl1_0_glIndexfv(void *_glfuncs, const GLfloat* c)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glIndexfv(c);
+}
+
+void gl1_0_glIndexf(void *_glfuncs, GLfloat c)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glIndexf(c);
+}
+
+void gl1_0_glIndexdv(void *_glfuncs, const GLdouble* c)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glIndexdv(c);
+}
+
+void gl1_0_glIndexd(void *_glfuncs, GLdouble c)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glIndexd(c);
+}
+
+void gl1_0_glEnd(void *_glfuncs)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glEnd();
+}
+
+void gl1_0_glEdgeFlagv(void *_glfuncs, const GLboolean* flag)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glEdgeFlagv(flag);
+}
+
+void gl1_0_glEdgeFlag(void *_glfuncs, GLboolean flag)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glEdgeFlag(flag);
+}
+
+void gl1_0_glColor4usv(void *_glfuncs, const GLushort* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glColor4usv(v);
+}
+
+void gl1_0_glColor4us(void *_glfuncs, GLushort red, GLushort green, GLushort blue, GLushort alpha)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glColor4us(red, green, blue, alpha);
+}
+
+void gl1_0_glColor4uiv(void *_glfuncs, const GLuint* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glColor4uiv(v);
+}
+
+void gl1_0_glColor4ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue, GLuint alpha)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glColor4ui(red, green, blue, alpha);
+}
+
+void gl1_0_glColor4ubv(void *_glfuncs, const GLubyte* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glColor4ubv(v);
+}
+
+void gl1_0_glColor4ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glColor4ub(red, green, blue, alpha);
+}
+
+void gl1_0_glColor4sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glColor4sv(v);
+}
+
+void gl1_0_glColor4s(void *_glfuncs, GLshort red, GLshort green, GLshort blue, GLshort alpha)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glColor4s(red, green, blue, alpha);
+}
+
+void gl1_0_glColor4iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glColor4iv(v);
+}
+
+void gl1_0_glColor4i(void *_glfuncs, GLint red, GLint green, GLint blue, GLint alpha)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glColor4i(red, green, blue, alpha);
+}
+
+void gl1_0_glColor4fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glColor4fv(v);
+}
+
+void gl1_0_glColor4f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glColor4f(red, green, blue, alpha);
+}
+
+void gl1_0_glColor4dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glColor4dv(v);
+}
+
+void gl1_0_glColor4d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glColor4d(red, green, blue, alpha);
+}
+
+void gl1_0_glColor4bv(void *_glfuncs, const GLbyte* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glColor4bv(v);
+}
+
+void gl1_0_glColor4b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glColor4b(red, green, blue, alpha);
+}
+
+void gl1_0_glColor3usv(void *_glfuncs, const GLushort* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glColor3usv(v);
+}
+
+void gl1_0_glColor3us(void *_glfuncs, GLushort red, GLushort green, GLushort blue)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glColor3us(red, green, blue);
+}
+
+void gl1_0_glColor3uiv(void *_glfuncs, const GLuint* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glColor3uiv(v);
+}
+
+void gl1_0_glColor3ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glColor3ui(red, green, blue);
+}
+
+void gl1_0_glColor3ubv(void *_glfuncs, const GLubyte* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glColor3ubv(v);
+}
+
+void gl1_0_glColor3ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glColor3ub(red, green, blue);
+}
+
+void gl1_0_glColor3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glColor3sv(v);
+}
+
+void gl1_0_glColor3s(void *_glfuncs, GLshort red, GLshort green, GLshort blue)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glColor3s(red, green, blue);
+}
+
+void gl1_0_glColor3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glColor3iv(v);
+}
+
+void gl1_0_glColor3i(void *_glfuncs, GLint red, GLint green, GLint blue)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glColor3i(red, green, blue);
+}
+
+void gl1_0_glColor3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glColor3fv(v);
+}
+
+void gl1_0_glColor3f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glColor3f(red, green, blue);
+}
+
+void gl1_0_glColor3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glColor3dv(v);
+}
+
+void gl1_0_glColor3d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glColor3d(red, green, blue);
+}
+
+void gl1_0_glColor3bv(void *_glfuncs, const GLbyte* v)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glColor3bv(v);
+}
+
+void gl1_0_glColor3b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glColor3b(red, green, blue);
+}
+
+void gl1_0_glBitmap(void *_glfuncs, GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte* bitmap)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glBitmap(width, height, xorig, yorig, xmove, ymove, bitmap);
+}
+
+void gl1_0_glBegin(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glBegin(mode);
+}
+
+void gl1_0_glListBase(void *_glfuncs, GLuint base)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glListBase(base);
+}
+
+GLuint gl1_0_glGenLists(void *_glfuncs, GLsizei range_)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ return _qglfuncs->glGenLists(range_);
+}
+
+void gl1_0_glDeleteLists(void *_glfuncs, GLuint list, GLsizei range_)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glDeleteLists(list, range_);
+}
+
+void gl1_0_glCallLists(void *_glfuncs, GLsizei n, GLenum gltype, const GLvoid* lists)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glCallLists(n, gltype, lists);
+}
+
+void gl1_0_glCallList(void *_glfuncs, GLuint list)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glCallList(list);
+}
+
+void gl1_0_glEndList(void *_glfuncs)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glEndList();
+}
+
+void gl1_0_glNewList(void *_glfuncs, GLuint list, GLenum mode)
+{
+ QOpenGLFunctions_1_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_0*>(_glfuncs);
+ _qglfuncs->glNewList(list, mode);
+}
+
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/1.0/funcs.h b/Godeps/_workspace/src/github.com/obscuren/qml/gl/1.0/funcs.h
new file mode 100644
index 000000000..c016eec7b
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/1.0/funcs.h
@@ -0,0 +1,347 @@
+
+// ** file automatically generated by glgen -- do not edit manually **
+
+#ifndef __cplusplus
+#include <inttypes.h>
+#include <stddef.h>
+typedef unsigned int GLenum;
+typedef unsigned char GLboolean;
+typedef unsigned int GLbitfield;
+typedef void GLvoid;
+typedef char GLchar;
+typedef signed char GLbyte; /* 1-byte signed */
+typedef short GLshort; /* 2-byte signed */
+typedef int GLint; /* 4-byte signed */
+typedef unsigned char GLubyte; /* 1-byte unsigned */
+typedef unsigned short GLushort; /* 2-byte unsigned */
+typedef unsigned int GLuint; /* 4-byte unsigned */
+typedef int GLsizei; /* 4-byte signed */
+typedef float GLfloat; /* single precision float */
+typedef float GLclampf; /* single precision float in [0,1] */
+typedef double GLdouble; /* double precision float */
+typedef double GLclampd; /* double precision float in [0,1] */
+typedef int64_t GLint64;
+typedef uint64_t GLuint64;
+typedef ptrdiff_t GLintptr;
+typedef ptrdiff_t GLsizeiptr;
+typedef ptrdiff_t GLintptrARB;
+typedef ptrdiff_t GLsizeiptrARB;
+typedef struct __GLsync *GLsync;
+#endif
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+void *gl1_0_funcs();
+
+void gl1_0_glViewport(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl1_0_glDepthRange(void *_glfuncs, GLdouble nearVal, GLdouble farVal);
+GLboolean gl1_0_glIsEnabled(void *_glfuncs, GLenum cap);
+void gl1_0_glGetTexLevelParameteriv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLint* params);
+void gl1_0_glGetTexLevelParameterfv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLfloat* params);
+void gl1_0_glGetTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl1_0_glGetTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl1_0_glGetTexImage(void *_glfuncs, GLenum target, GLint level, GLenum format, GLenum gltype, GLvoid* pixels);
+void gl1_0_glGetIntegerv(void *_glfuncs, GLenum pname, GLint* params);
+void gl1_0_glGetFloatv(void *_glfuncs, GLenum pname, GLfloat* params);
+GLenum gl1_0_glGetError(void *_glfuncs);
+void gl1_0_glGetDoublev(void *_glfuncs, GLenum pname, GLdouble* params);
+void gl1_0_glGetBooleanv(void *_glfuncs, GLenum pname, GLboolean* params);
+void gl1_0_glReadPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum gltype, GLvoid* pixels);
+void gl1_0_glReadBuffer(void *_glfuncs, GLenum mode);
+void gl1_0_glPixelStorei(void *_glfuncs, GLenum pname, GLint param);
+void gl1_0_glPixelStoref(void *_glfuncs, GLenum pname, GLfloat param);
+void gl1_0_glDepthFunc(void *_glfuncs, GLenum glfunc);
+void gl1_0_glStencilOp(void *_glfuncs, GLenum fail, GLenum zfail, GLenum zpass);
+void gl1_0_glStencilFunc(void *_glfuncs, GLenum glfunc, GLint ref, GLuint mask);
+void gl1_0_glLogicOp(void *_glfuncs, GLenum opcode);
+void gl1_0_glBlendFunc(void *_glfuncs, GLenum sfactor, GLenum dfactor);
+void gl1_0_glFlush(void *_glfuncs);
+void gl1_0_glFinish(void *_glfuncs);
+void gl1_0_glEnable(void *_glfuncs, GLenum cap);
+void gl1_0_glDisable(void *_glfuncs, GLenum cap);
+void gl1_0_glDepthMask(void *_glfuncs, GLboolean flag);
+void gl1_0_glColorMask(void *_glfuncs, GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha);
+void gl1_0_glStencilMask(void *_glfuncs, GLuint mask);
+void gl1_0_glClearDepth(void *_glfuncs, GLdouble depth);
+void gl1_0_glClearStencil(void *_glfuncs, GLint s);
+void gl1_0_glClearColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl1_0_glClear(void *_glfuncs, GLbitfield mask);
+void gl1_0_glDrawBuffer(void *_glfuncs, GLenum mode);
+void gl1_0_glTexImage2D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl1_0_glTexImage1D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl1_0_glTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl1_0_glTexParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint param);
+void gl1_0_glTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl1_0_glTexParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param);
+void gl1_0_glScissor(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl1_0_glPolygonMode(void *_glfuncs, GLenum face, GLenum mode);
+void gl1_0_glPointSize(void *_glfuncs, GLfloat size);
+void gl1_0_glLineWidth(void *_glfuncs, GLfloat width);
+void gl1_0_glHint(void *_glfuncs, GLenum target, GLenum mode);
+void gl1_0_glFrontFace(void *_glfuncs, GLenum mode);
+void gl1_0_glCullFace(void *_glfuncs, GLenum mode);
+void gl1_0_glTranslatef(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl1_0_glTranslated(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl1_0_glScalef(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl1_0_glScaled(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl1_0_glRotatef(void *_glfuncs, GLfloat angle, GLfloat x, GLfloat y, GLfloat z);
+void gl1_0_glRotated(void *_glfuncs, GLdouble angle, GLdouble x, GLdouble y, GLdouble z);
+void gl1_0_glPushMatrix(void *_glfuncs);
+void gl1_0_glPopMatrix(void *_glfuncs);
+void gl1_0_glOrtho(void *_glfuncs, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+void gl1_0_glMultMatrixd(void *_glfuncs, const GLdouble* m);
+void gl1_0_glMultMatrixf(void *_glfuncs, const GLfloat* m);
+void gl1_0_glMatrixMode(void *_glfuncs, GLenum mode);
+void gl1_0_glLoadMatrixd(void *_glfuncs, const GLdouble* m);
+void gl1_0_glLoadMatrixf(void *_glfuncs, const GLfloat* m);
+void gl1_0_glLoadIdentity(void *_glfuncs);
+void gl1_0_glFrustum(void *_glfuncs, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+GLboolean gl1_0_glIsList(void *_glfuncs, GLuint list);
+void gl1_0_glGetTexGeniv(void *_glfuncs, GLenum coord, GLenum pname, GLint* params);
+void gl1_0_glGetTexGenfv(void *_glfuncs, GLenum coord, GLenum pname, GLfloat* params);
+void gl1_0_glGetTexGendv(void *_glfuncs, GLenum coord, GLenum pname, GLdouble* params);
+void gl1_0_glGetTexEnviv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl1_0_glGetTexEnvfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl1_0_glGetPolygonStipple(void *_glfuncs, GLubyte* mask);
+void gl1_0_glGetPixelMapusv(void *_glfuncs, GLenum glmap, GLushort* values);
+void gl1_0_glGetPixelMapuiv(void *_glfuncs, GLenum glmap, GLuint* values);
+void gl1_0_glGetPixelMapfv(void *_glfuncs, GLenum glmap, GLfloat* values);
+void gl1_0_glGetMaterialiv(void *_glfuncs, GLenum face, GLenum pname, GLint* params);
+void gl1_0_glGetMaterialfv(void *_glfuncs, GLenum face, GLenum pname, GLfloat* params);
+void gl1_0_glGetMapiv(void *_glfuncs, GLenum target, GLenum query, GLint* v);
+void gl1_0_glGetMapfv(void *_glfuncs, GLenum target, GLenum query, GLfloat* v);
+void gl1_0_glGetMapdv(void *_glfuncs, GLenum target, GLenum query, GLdouble* v);
+void gl1_0_glGetLightiv(void *_glfuncs, GLenum light, GLenum pname, GLint* params);
+void gl1_0_glGetLightfv(void *_glfuncs, GLenum light, GLenum pname, GLfloat* params);
+void gl1_0_glGetClipPlane(void *_glfuncs, GLenum plane, GLdouble* equation);
+void gl1_0_glDrawPixels(void *_glfuncs, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl1_0_glCopyPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum gltype);
+void gl1_0_glPixelMapusv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLushort* values);
+void gl1_0_glPixelMapuiv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLuint* values);
+void gl1_0_glPixelMapfv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLfloat* values);
+void gl1_0_glPixelTransferi(void *_glfuncs, GLenum pname, GLint param);
+void gl1_0_glPixelTransferf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl1_0_glPixelZoom(void *_glfuncs, GLfloat xfactor, GLfloat yfactor);
+void gl1_0_glAlphaFunc(void *_glfuncs, GLenum glfunc, GLfloat ref);
+void gl1_0_glEvalPoint2(void *_glfuncs, GLint i, GLint j);
+void gl1_0_glEvalMesh2(void *_glfuncs, GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2);
+void gl1_0_glEvalPoint1(void *_glfuncs, GLint i);
+void gl1_0_glEvalMesh1(void *_glfuncs, GLenum mode, GLint i1, GLint i2);
+void gl1_0_glEvalCoord2fv(void *_glfuncs, const GLfloat* u);
+void gl1_0_glEvalCoord2f(void *_glfuncs, GLfloat u, GLfloat v);
+void gl1_0_glEvalCoord2dv(void *_glfuncs, const GLdouble* u);
+void gl1_0_glEvalCoord2d(void *_glfuncs, GLdouble u, GLdouble v);
+void gl1_0_glEvalCoord1fv(void *_glfuncs, const GLfloat* u);
+void gl1_0_glEvalCoord1f(void *_glfuncs, GLfloat u);
+void gl1_0_glEvalCoord1dv(void *_glfuncs, const GLdouble* u);
+void gl1_0_glEvalCoord1d(void *_glfuncs, GLdouble u);
+void gl1_0_glMapGrid2f(void *_glfuncs, GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2);
+void gl1_0_glMapGrid2d(void *_glfuncs, GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2);
+void gl1_0_glMapGrid1f(void *_glfuncs, GLint un, GLfloat u1, GLfloat u2);
+void gl1_0_glMapGrid1d(void *_glfuncs, GLint un, GLdouble u1, GLdouble u2);
+void gl1_0_glMap2f(void *_glfuncs, GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat* points);
+void gl1_0_glMap2d(void *_glfuncs, GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble* points);
+void gl1_0_glMap1f(void *_glfuncs, GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat* points);
+void gl1_0_glMap1d(void *_glfuncs, GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble* points);
+void gl1_0_glPushAttrib(void *_glfuncs, GLbitfield mask);
+void gl1_0_glPopAttrib(void *_glfuncs);
+void gl1_0_glAccum(void *_glfuncs, GLenum op, GLfloat value);
+void gl1_0_glIndexMask(void *_glfuncs, GLuint mask);
+void gl1_0_glClearIndex(void *_glfuncs, GLfloat c);
+void gl1_0_glClearAccum(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl1_0_glPushName(void *_glfuncs, GLuint name);
+void gl1_0_glPopName(void *_glfuncs);
+void gl1_0_glPassThrough(void *_glfuncs, GLfloat token);
+void gl1_0_glLoadName(void *_glfuncs, GLuint name);
+void gl1_0_glInitNames(void *_glfuncs);
+GLint gl1_0_glRenderMode(void *_glfuncs, GLenum mode);
+void gl1_0_glSelectBuffer(void *_glfuncs, GLsizei size, GLuint* buffer);
+void gl1_0_glFeedbackBuffer(void *_glfuncs, GLsizei size, GLenum gltype, GLfloat* buffer);
+void gl1_0_glTexGeniv(void *_glfuncs, GLenum coord, GLenum pname, const GLint* params);
+void gl1_0_glTexGeni(void *_glfuncs, GLenum coord, GLenum pname, GLint param);
+void gl1_0_glTexGenfv(void *_glfuncs, GLenum coord, GLenum pname, const GLfloat* params);
+void gl1_0_glTexGenf(void *_glfuncs, GLenum coord, GLenum pname, GLfloat param);
+void gl1_0_glTexGendv(void *_glfuncs, GLenum coord, GLenum pname, const GLdouble* params);
+void gl1_0_glTexGend(void *_glfuncs, GLenum coord, GLenum pname, GLdouble param);
+void gl1_0_glTexEnviv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl1_0_glTexEnvi(void *_glfuncs, GLenum target, GLenum pname, GLint param);
+void gl1_0_glTexEnvfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl1_0_glTexEnvf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param);
+void gl1_0_glShadeModel(void *_glfuncs, GLenum mode);
+void gl1_0_glPolygonStipple(void *_glfuncs, const GLubyte* mask);
+void gl1_0_glMaterialiv(void *_glfuncs, GLenum face, GLenum pname, const GLint* params);
+void gl1_0_glMateriali(void *_glfuncs, GLenum face, GLenum pname, GLint param);
+void gl1_0_glMaterialfv(void *_glfuncs, GLenum face, GLenum pname, const GLfloat* params);
+void gl1_0_glMaterialf(void *_glfuncs, GLenum face, GLenum pname, GLfloat param);
+void gl1_0_glLineStipple(void *_glfuncs, GLint factor, GLushort pattern);
+void gl1_0_glLightModeliv(void *_glfuncs, GLenum pname, const GLint* params);
+void gl1_0_glLightModeli(void *_glfuncs, GLenum pname, GLint param);
+void gl1_0_glLightModelfv(void *_glfuncs, GLenum pname, const GLfloat* params);
+void gl1_0_glLightModelf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl1_0_glLightiv(void *_glfuncs, GLenum light, GLenum pname, const GLint* params);
+void gl1_0_glLighti(void *_glfuncs, GLenum light, GLenum pname, GLint param);
+void gl1_0_glLightfv(void *_glfuncs, GLenum light, GLenum pname, const GLfloat* params);
+void gl1_0_glLightf(void *_glfuncs, GLenum light, GLenum pname, GLfloat param);
+void gl1_0_glFogiv(void *_glfuncs, GLenum pname, const GLint* params);
+void gl1_0_glFogi(void *_glfuncs, GLenum pname, GLint param);
+void gl1_0_glFogfv(void *_glfuncs, GLenum pname, const GLfloat* params);
+void gl1_0_glFogf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl1_0_glColorMaterial(void *_glfuncs, GLenum face, GLenum mode);
+void gl1_0_glClipPlane(void *_glfuncs, GLenum plane, const GLdouble* equation);
+void gl1_0_glVertex4sv(void *_glfuncs, const GLshort* v);
+void gl1_0_glVertex4s(void *_glfuncs, GLshort x, GLshort y, GLshort z, GLshort w);
+void gl1_0_glVertex4iv(void *_glfuncs, const GLint* v);
+void gl1_0_glVertex4i(void *_glfuncs, GLint x, GLint y, GLint z, GLint w);
+void gl1_0_glVertex4fv(void *_glfuncs, const GLfloat* v);
+void gl1_0_glVertex4f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+void gl1_0_glVertex4dv(void *_glfuncs, const GLdouble* v);
+void gl1_0_glVertex4d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+void gl1_0_glVertex3sv(void *_glfuncs, const GLshort* v);
+void gl1_0_glVertex3s(void *_glfuncs, GLshort x, GLshort y, GLshort z);
+void gl1_0_glVertex3iv(void *_glfuncs, const GLint* v);
+void gl1_0_glVertex3i(void *_glfuncs, GLint x, GLint y, GLint z);
+void gl1_0_glVertex3fv(void *_glfuncs, const GLfloat* v);
+void gl1_0_glVertex3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl1_0_glVertex3dv(void *_glfuncs, const GLdouble* v);
+void gl1_0_glVertex3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl1_0_glVertex2sv(void *_glfuncs, const GLshort* v);
+void gl1_0_glVertex2s(void *_glfuncs, GLshort x, GLshort y);
+void gl1_0_glVertex2iv(void *_glfuncs, const GLint* v);
+void gl1_0_glVertex2i(void *_glfuncs, GLint x, GLint y);
+void gl1_0_glVertex2fv(void *_glfuncs, const GLfloat* v);
+void gl1_0_glVertex2f(void *_glfuncs, GLfloat x, GLfloat y);
+void gl1_0_glVertex2dv(void *_glfuncs, const GLdouble* v);
+void gl1_0_glVertex2d(void *_glfuncs, GLdouble x, GLdouble y);
+void gl1_0_glTexCoord4sv(void *_glfuncs, const GLshort* v);
+void gl1_0_glTexCoord4s(void *_glfuncs, GLshort s, GLshort t, GLshort r, GLshort q);
+void gl1_0_glTexCoord4iv(void *_glfuncs, const GLint* v);
+void gl1_0_glTexCoord4i(void *_glfuncs, GLint s, GLint t, GLint r, GLint q);
+void gl1_0_glTexCoord4fv(void *_glfuncs, const GLfloat* v);
+void gl1_0_glTexCoord4f(void *_glfuncs, GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+void gl1_0_glTexCoord4dv(void *_glfuncs, const GLdouble* v);
+void gl1_0_glTexCoord4d(void *_glfuncs, GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+void gl1_0_glTexCoord3sv(void *_glfuncs, const GLshort* v);
+void gl1_0_glTexCoord3s(void *_glfuncs, GLshort s, GLshort t, GLshort r);
+void gl1_0_glTexCoord3iv(void *_glfuncs, const GLint* v);
+void gl1_0_glTexCoord3i(void *_glfuncs, GLint s, GLint t, GLint r);
+void gl1_0_glTexCoord3fv(void *_glfuncs, const GLfloat* v);
+void gl1_0_glTexCoord3f(void *_glfuncs, GLfloat s, GLfloat t, GLfloat r);
+void gl1_0_glTexCoord3dv(void *_glfuncs, const GLdouble* v);
+void gl1_0_glTexCoord3d(void *_glfuncs, GLdouble s, GLdouble t, GLdouble r);
+void gl1_0_glTexCoord2sv(void *_glfuncs, const GLshort* v);
+void gl1_0_glTexCoord2s(void *_glfuncs, GLshort s, GLshort t);
+void gl1_0_glTexCoord2iv(void *_glfuncs, const GLint* v);
+void gl1_0_glTexCoord2i(void *_glfuncs, GLint s, GLint t);
+void gl1_0_glTexCoord2fv(void *_glfuncs, const GLfloat* v);
+void gl1_0_glTexCoord2f(void *_glfuncs, GLfloat s, GLfloat t);
+void gl1_0_glTexCoord2dv(void *_glfuncs, const GLdouble* v);
+void gl1_0_glTexCoord2d(void *_glfuncs, GLdouble s, GLdouble t);
+void gl1_0_glTexCoord1sv(void *_glfuncs, const GLshort* v);
+void gl1_0_glTexCoord1s(void *_glfuncs, GLshort s);
+void gl1_0_glTexCoord1iv(void *_glfuncs, const GLint* v);
+void gl1_0_glTexCoord1i(void *_glfuncs, GLint s);
+void gl1_0_glTexCoord1fv(void *_glfuncs, const GLfloat* v);
+void gl1_0_glTexCoord1f(void *_glfuncs, GLfloat s);
+void gl1_0_glTexCoord1dv(void *_glfuncs, const GLdouble* v);
+void gl1_0_glTexCoord1d(void *_glfuncs, GLdouble s);
+void gl1_0_glRectsv(void *_glfuncs, const GLshort* v1, const GLshort* v2);
+void gl1_0_glRects(void *_glfuncs, GLshort x1, GLshort y1, GLshort x2, GLshort y2);
+void gl1_0_glRectiv(void *_glfuncs, const GLint* v1, const GLint* v2);
+void gl1_0_glRecti(void *_glfuncs, GLint x1, GLint y1, GLint x2, GLint y2);
+void gl1_0_glRectfv(void *_glfuncs, const GLfloat* v1, const GLfloat* v2);
+void gl1_0_glRectf(void *_glfuncs, GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2);
+void gl1_0_glRectdv(void *_glfuncs, const GLdouble* v1, const GLdouble* v2);
+void gl1_0_glRectd(void *_glfuncs, GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2);
+void gl1_0_glRasterPos4sv(void *_glfuncs, const GLshort* v);
+void gl1_0_glRasterPos4s(void *_glfuncs, GLshort x, GLshort y, GLshort z, GLshort w);
+void gl1_0_glRasterPos4iv(void *_glfuncs, const GLint* v);
+void gl1_0_glRasterPos4i(void *_glfuncs, GLint x, GLint y, GLint z, GLint w);
+void gl1_0_glRasterPos4fv(void *_glfuncs, const GLfloat* v);
+void gl1_0_glRasterPos4f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+void gl1_0_glRasterPos4dv(void *_glfuncs, const GLdouble* v);
+void gl1_0_glRasterPos4d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+void gl1_0_glRasterPos3sv(void *_glfuncs, const GLshort* v);
+void gl1_0_glRasterPos3s(void *_glfuncs, GLshort x, GLshort y, GLshort z);
+void gl1_0_glRasterPos3iv(void *_glfuncs, const GLint* v);
+void gl1_0_glRasterPos3i(void *_glfuncs, GLint x, GLint y, GLint z);
+void gl1_0_glRasterPos3fv(void *_glfuncs, const GLfloat* v);
+void gl1_0_glRasterPos3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl1_0_glRasterPos3dv(void *_glfuncs, const GLdouble* v);
+void gl1_0_glRasterPos3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl1_0_glRasterPos2sv(void *_glfuncs, const GLshort* v);
+void gl1_0_glRasterPos2s(void *_glfuncs, GLshort x, GLshort y);
+void gl1_0_glRasterPos2iv(void *_glfuncs, const GLint* v);
+void gl1_0_glRasterPos2i(void *_glfuncs, GLint x, GLint y);
+void gl1_0_glRasterPos2fv(void *_glfuncs, const GLfloat* v);
+void gl1_0_glRasterPos2f(void *_glfuncs, GLfloat x, GLfloat y);
+void gl1_0_glRasterPos2dv(void *_glfuncs, const GLdouble* v);
+void gl1_0_glRasterPos2d(void *_glfuncs, GLdouble x, GLdouble y);
+void gl1_0_glNormal3sv(void *_glfuncs, const GLshort* v);
+void gl1_0_glNormal3s(void *_glfuncs, GLshort nx, GLshort ny, GLshort nz);
+void gl1_0_glNormal3iv(void *_glfuncs, const GLint* v);
+void gl1_0_glNormal3i(void *_glfuncs, GLint nx, GLint ny, GLint nz);
+void gl1_0_glNormal3fv(void *_glfuncs, const GLfloat* v);
+void gl1_0_glNormal3f(void *_glfuncs, GLfloat nx, GLfloat ny, GLfloat nz);
+void gl1_0_glNormal3dv(void *_glfuncs, const GLdouble* v);
+void gl1_0_glNormal3d(void *_glfuncs, GLdouble nx, GLdouble ny, GLdouble nz);
+void gl1_0_glNormal3bv(void *_glfuncs, const GLbyte* v);
+void gl1_0_glNormal3b(void *_glfuncs, GLbyte nx, GLbyte ny, GLbyte nz);
+void gl1_0_glIndexsv(void *_glfuncs, const GLshort* c);
+void gl1_0_glIndexs(void *_glfuncs, GLshort c);
+void gl1_0_glIndexiv(void *_glfuncs, const GLint* c);
+void gl1_0_glIndexi(void *_glfuncs, GLint c);
+void gl1_0_glIndexfv(void *_glfuncs, const GLfloat* c);
+void gl1_0_glIndexf(void *_glfuncs, GLfloat c);
+void gl1_0_glIndexdv(void *_glfuncs, const GLdouble* c);
+void gl1_0_glIndexd(void *_glfuncs, GLdouble c);
+void gl1_0_glEnd(void *_glfuncs);
+void gl1_0_glEdgeFlagv(void *_glfuncs, const GLboolean* flag);
+void gl1_0_glEdgeFlag(void *_glfuncs, GLboolean flag);
+void gl1_0_glColor4usv(void *_glfuncs, const GLushort* v);
+void gl1_0_glColor4us(void *_glfuncs, GLushort red, GLushort green, GLushort blue, GLushort alpha);
+void gl1_0_glColor4uiv(void *_glfuncs, const GLuint* v);
+void gl1_0_glColor4ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue, GLuint alpha);
+void gl1_0_glColor4ubv(void *_glfuncs, const GLubyte* v);
+void gl1_0_glColor4ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha);
+void gl1_0_glColor4sv(void *_glfuncs, const GLshort* v);
+void gl1_0_glColor4s(void *_glfuncs, GLshort red, GLshort green, GLshort blue, GLshort alpha);
+void gl1_0_glColor4iv(void *_glfuncs, const GLint* v);
+void gl1_0_glColor4i(void *_glfuncs, GLint red, GLint green, GLint blue, GLint alpha);
+void gl1_0_glColor4fv(void *_glfuncs, const GLfloat* v);
+void gl1_0_glColor4f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl1_0_glColor4dv(void *_glfuncs, const GLdouble* v);
+void gl1_0_glColor4d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha);
+void gl1_0_glColor4bv(void *_glfuncs, const GLbyte* v);
+void gl1_0_glColor4b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha);
+void gl1_0_glColor3usv(void *_glfuncs, const GLushort* v);
+void gl1_0_glColor3us(void *_glfuncs, GLushort red, GLushort green, GLushort blue);
+void gl1_0_glColor3uiv(void *_glfuncs, const GLuint* v);
+void gl1_0_glColor3ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue);
+void gl1_0_glColor3ubv(void *_glfuncs, const GLubyte* v);
+void gl1_0_glColor3ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue);
+void gl1_0_glColor3sv(void *_glfuncs, const GLshort* v);
+void gl1_0_glColor3s(void *_glfuncs, GLshort red, GLshort green, GLshort blue);
+void gl1_0_glColor3iv(void *_glfuncs, const GLint* v);
+void gl1_0_glColor3i(void *_glfuncs, GLint red, GLint green, GLint blue);
+void gl1_0_glColor3fv(void *_glfuncs, const GLfloat* v);
+void gl1_0_glColor3f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue);
+void gl1_0_glColor3dv(void *_glfuncs, const GLdouble* v);
+void gl1_0_glColor3d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue);
+void gl1_0_glColor3bv(void *_glfuncs, const GLbyte* v);
+void gl1_0_glColor3b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue);
+void gl1_0_glBitmap(void *_glfuncs, GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte* bitmap);
+void gl1_0_glBegin(void *_glfuncs, GLenum mode);
+void gl1_0_glListBase(void *_glfuncs, GLuint base);
+GLuint gl1_0_glGenLists(void *_glfuncs, GLsizei range_);
+void gl1_0_glDeleteLists(void *_glfuncs, GLuint list, GLsizei range_);
+void gl1_0_glCallLists(void *_glfuncs, GLsizei n, GLenum gltype, const GLvoid* lists);
+void gl1_0_glCallList(void *_glfuncs, GLuint list);
+void gl1_0_glEndList(void *_glfuncs);
+void gl1_0_glNewList(void *_glfuncs, GLuint list, GLenum mode);
+
+
+#ifdef __cplusplus
+} // extern "C"
+#endif
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/1.0/gl.go b/Godeps/_workspace/src/github.com/obscuren/qml/gl/1.0/gl.go
new file mode 100644
index 000000000..ce6c47ce4
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/1.0/gl.go
@@ -0,0 +1,2528 @@
+// ** file automatically generated by glgen -- do not edit manually **
+
+package GL
+
+// #cgo CXXFLAGS: -std=c++0x -pedantic-errors -Wall -fno-strict-aliasing
+// #cgo LDFLAGS: -lstdc++
+// #cgo pkg-config: Qt5Core Qt5OpenGL
+//
+// #include "funcs.h"
+//
+// void free(void*);
+//
+import "C"
+
+import (
+ "fmt"
+ "reflect"
+ "unsafe"
+
+ "gopkg.in/qml.v1/gl/glbase"
+)
+
+// API returns a value that offers methods matching the OpenGL version 1.0 API.
+//
+// The returned API must not be used after the provided OpenGL context becomes invalid.
+func API(context glbase.Contexter) *GL {
+ gl := &GL{}
+ gl.funcs = C.gl1_0_funcs()
+ if gl.funcs == nil {
+ panic(fmt.Errorf("OpenGL version 1.0 is not available"))
+ }
+ return gl
+}
+
+// GL implements the OpenGL version 1.0 API. Values of this
+// type must be created via the API function, and it must not be used after
+// the associated OpenGL context becomes invalid.
+type GL struct {
+ funcs unsafe.Pointer
+}
+
+const (
+ FALSE = 0
+ TRUE = 1
+ NONE = 0
+
+ BYTE = 0x1400
+ UNSIGNED_BYTE = 0x1401
+ SHORT = 0x1402
+ UNSIGNED_SHORT = 0x1403
+ INT = 0x1404
+ UNSIGNED_INT = 0x1405
+ FLOAT = 0x1406
+ N2_BYTES = 0x1407
+ N3_BYTES = 0x1408
+ N4_BYTES = 0x1409
+ DOUBLE = 0x140A
+
+ ACCUM = 0x0100
+ LOAD = 0x0101
+ RETURN = 0x0102
+ MULT = 0x0103
+ ADD = 0x0104
+
+ ACCUM_BUFFER_BIT = 0x00000200
+ ALL_ATTRIB_BITS = 0xFFFFFFFF
+ COLOR_BUFFER_BIT = 0x00004000
+ CURRENT_BIT = 0x00000001
+ DEPTH_BUFFER_BIT = 0x00000100
+ ENABLE_BIT = 0x00002000
+ EVAL_BIT = 0x00010000
+ FOG_BIT = 0x00000080
+ HINT_BIT = 0x00008000
+ LIGHTING_BIT = 0x00000040
+ LINE_BIT = 0x00000004
+ LIST_BIT = 0x00020000
+ PIXEL_MODE_BIT = 0x00000020
+ POINT_BIT = 0x00000002
+ POLYGON_BIT = 0x00000008
+ POLYGON_STIPPLE_BIT = 0x00000010
+ SCISSOR_BIT = 0x00080000
+ STENCIL_BUFFER_BIT = 0x00000400
+ TEXTURE_BIT = 0x00040000
+ TRANSFORM_BIT = 0x00001000
+ VIEWPORT_BIT = 0x00000800
+
+ ALWAYS = 0x0207
+ EQUAL = 0x0202
+ GEQUAL = 0x0206
+ GREATER = 0x0204
+ LEQUAL = 0x0203
+ LESS = 0x0201
+ NEVER = 0x0200
+ NOTEQUAL = 0x0205
+
+ LOGIC_OP = 0x0BF1
+
+ DST_ALPHA = 0x0304
+ ONE = 1
+ ONE_MINUS_DST_ALPHA = 0x0305
+ ONE_MINUS_SRC_ALPHA = 0x0303
+ ONE_MINUS_SRC_COLOR = 0x0301
+ SRC_ALPHA = 0x0302
+ SRC_COLOR = 0x0300
+ ZERO = 0
+
+ DST_COLOR = 0x0306
+ ONE_MINUS_DST_COLOR = 0x0307
+ SRC_ALPHA_SATURATE = 0x0308
+
+ CLIENT_ALL_ATTRIB_BITS = 0xFFFFFFFF
+ CLIENT_PIXEL_STORE_BIT = 0x00000001
+ CLIENT_VERTEX_ARRAY_BIT = 0x00000002
+
+ CLIP_PLANE0 = 0x3000
+ CLIP_PLANE1 = 0x3001
+ CLIP_PLANE2 = 0x3002
+ CLIP_PLANE3 = 0x3003
+ CLIP_PLANE4 = 0x3004
+ CLIP_PLANE5 = 0x3005
+
+ BACK = 0x0405
+ FRONT = 0x0404
+ FRONT_AND_BACK = 0x0408
+
+ AMBIENT = 0x1200
+ AMBIENT_AND_DIFFUSE = 0x1602
+ DIFFUSE = 0x1201
+ EMISSION = 0x1600
+ SPECULAR = 0x1202
+
+ AUX0 = 0x0409
+ AUX1 = 0x040A
+ AUX2 = 0x040B
+ AUX3 = 0x040C
+ BACK_LEFT = 0x0402
+ BACK_RIGHT = 0x0403
+ FRONT_LEFT = 0x0400
+ FRONT_RIGHT = 0x0401
+ LEFT = 0x0406
+ RIGHT = 0x0407
+
+ ALPHA_TEST = 0x0BC0
+ AUTO_NORMAL = 0x0D80
+ BLEND = 0x0BE2
+ COLOR_ARRAY = 0x8076
+ COLOR_LOGIC_OP = 0x0BF2
+ COLOR_MATERIAL = 0x0B57
+ CULL_FACE = 0x0B44
+ DEPTH_TEST = 0x0B71
+ DITHER = 0x0BD0
+ EDGE_FLAG_ARRAY = 0x8079
+ FOG = 0x0B60
+ INDEX_ARRAY = 0x8077
+ INDEX_LOGIC_OP = 0x0BF1
+ LIGHT0 = 0x4000
+ LIGHT1 = 0x4001
+ LIGHT2 = 0x4002
+ LIGHT3 = 0x4003
+ LIGHT4 = 0x4004
+ LIGHT5 = 0x4005
+ LIGHT6 = 0x4006
+ LIGHT7 = 0x4007
+ LIGHTING = 0x0B50
+ LINE_SMOOTH = 0x0B20
+ LINE_STIPPLE = 0x0B24
+ MAP1_COLOR_4 = 0x0D90
+ MAP1_INDEX = 0x0D91
+ MAP1_NORMAL = 0x0D92
+ MAP1_TEXTURE_COORD_1 = 0x0D93
+ MAP1_TEXTURE_COORD_2 = 0x0D94
+ MAP1_TEXTURE_COORD_3 = 0x0D95
+ MAP1_TEXTURE_COORD_4 = 0x0D96
+ MAP1_VERTEX_3 = 0x0D97
+ MAP1_VERTEX_4 = 0x0D98
+ MAP2_COLOR_4 = 0x0DB0
+ MAP2_INDEX = 0x0DB1
+ MAP2_NORMAL = 0x0DB2
+ MAP2_TEXTURE_COORD_1 = 0x0DB3
+ MAP2_TEXTURE_COORD_2 = 0x0DB4
+ MAP2_TEXTURE_COORD_3 = 0x0DB5
+ MAP2_TEXTURE_COORD_4 = 0x0DB6
+ MAP2_VERTEX_3 = 0x0DB7
+ MAP2_VERTEX_4 = 0x0DB8
+ NORMALIZE = 0x0BA1
+ NORMAL_ARRAY = 0x8075
+ POINT_SMOOTH = 0x0B10
+ POLYGON_OFFSET_FILL = 0x8037
+ POLYGON_OFFSET_LINE = 0x2A02
+ POLYGON_OFFSET_POINT = 0x2A01
+ POLYGON_SMOOTH = 0x0B41
+ POLYGON_STIPPLE = 0x0B42
+ SCISSOR_TEST = 0x0C11
+ STENCIL_TEST = 0x0B90
+ TEXTURE_1D = 0x0DE0
+ TEXTURE_2D = 0x0DE1
+ TEXTURE_COORD_ARRAY = 0x8078
+ TEXTURE_GEN_Q = 0x0C63
+ TEXTURE_GEN_R = 0x0C62
+ TEXTURE_GEN_S = 0x0C60
+ TEXTURE_GEN_T = 0x0C61
+ VERTEX_ARRAY = 0x8074
+
+ INVALID_ENUM = 0x0500
+ INVALID_OPERATION = 0x0502
+ INVALID_VALUE = 0x0501
+ NO_ERROR = 0
+ OUT_OF_MEMORY = 0x0505
+ STACK_OVERFLOW = 0x0503
+ STACK_UNDERFLOW = 0x0504
+
+ N2D = 0x0600
+ N3D = 0x0601
+ N3D_COLOR = 0x0602
+ N3D_COLOR_TEXTURE = 0x0603
+ N4D_COLOR_TEXTURE = 0x0604
+
+ BITMAP_TOKEN = 0x0704
+ COPY_PIXEL_TOKEN = 0x0706
+ DRAW_PIXEL_TOKEN = 0x0705
+ LINE_RESET_TOKEN = 0x0707
+ LINE_TOKEN = 0x0702
+ PASS_THROUGH_TOKEN = 0x0700
+ POINT_TOKEN = 0x0701
+ POLYGON_TOKEN = 0x0703
+
+ EXP = 0x0800
+ EXP2 = 0x0801
+ LINEAR = 0x2601
+
+ FOG_COLOR = 0x0B66
+ FOG_DENSITY = 0x0B62
+ FOG_END = 0x0B64
+ FOG_INDEX = 0x0B61
+ FOG_MODE = 0x0B65
+ FOG_START = 0x0B63
+
+ CCW = 0x0901
+ CW = 0x0900
+
+ COEFF = 0x0A00
+ DOMAIN = 0x0A02
+ ORDER = 0x0A01
+
+ PIXEL_MAP_A_TO_A = 0x0C79
+ PIXEL_MAP_B_TO_B = 0x0C78
+ PIXEL_MAP_G_TO_G = 0x0C77
+ PIXEL_MAP_I_TO_A = 0x0C75
+ PIXEL_MAP_I_TO_B = 0x0C74
+ PIXEL_MAP_I_TO_G = 0x0C73
+ PIXEL_MAP_I_TO_I = 0x0C70
+ PIXEL_MAP_I_TO_R = 0x0C72
+ PIXEL_MAP_R_TO_R = 0x0C76
+ PIXEL_MAP_S_TO_S = 0x0C71
+
+ ACCUM_ALPHA_BITS = 0x0D5B
+ ACCUM_BLUE_BITS = 0x0D5A
+ ACCUM_CLEAR_VALUE = 0x0B80
+ ACCUM_GREEN_BITS = 0x0D59
+ ACCUM_RED_BITS = 0x0D58
+ ALPHA_BIAS = 0x0D1D
+ ALPHA_BITS = 0x0D55
+ ALPHA_SCALE = 0x0D1C
+ ALPHA_TEST_FUNC = 0x0BC1
+ ALPHA_TEST_REF = 0x0BC2
+ ATTRIB_STACK_DEPTH = 0x0BB0
+ AUX_BUFFERS = 0x0C00
+ BLEND_DST = 0x0BE0
+ BLEND_SRC = 0x0BE1
+ BLUE_BIAS = 0x0D1B
+ BLUE_BITS = 0x0D54
+ BLUE_SCALE = 0x0D1A
+ CLIENT_ATTRIB_STACK_DEPTH = 0x0BB1
+ COLOR_ARRAY_SIZE = 0x8081
+ COLOR_ARRAY_STRIDE = 0x8083
+ COLOR_ARRAY_TYPE = 0x8082
+ COLOR_CLEAR_VALUE = 0x0C22
+ COLOR_MATERIAL_FACE = 0x0B55
+ COLOR_MATERIAL_PARAMETER = 0x0B56
+ COLOR_WRITEMASK = 0x0C23
+ CULL_FACE_MODE = 0x0B45
+ CURRENT_COLOR = 0x0B00
+ CURRENT_INDEX = 0x0B01
+ CURRENT_NORMAL = 0x0B02
+ CURRENT_RASTER_COLOR = 0x0B04
+ CURRENT_RASTER_DISTANCE = 0x0B09
+ CURRENT_RASTER_INDEX = 0x0B05
+ CURRENT_RASTER_POSITION = 0x0B07
+ CURRENT_RASTER_POSITION_VALID = 0x0B08
+ CURRENT_RASTER_TEXTURE_COORDS = 0x0B06
+ CURRENT_TEXTURE_COORDS = 0x0B03
+ DEPTH_BIAS = 0x0D1F
+ DEPTH_BITS = 0x0D56
+ DEPTH_CLEAR_VALUE = 0x0B73
+ DEPTH_FUNC = 0x0B74
+ DEPTH_RANGE = 0x0B70
+ DEPTH_SCALE = 0x0D1E
+ DEPTH_WRITEMASK = 0x0B72
+ DOUBLEBUFFER = 0x0C32
+ DRAW_BUFFER = 0x0C01
+ EDGE_FLAG = 0x0B43
+ EDGE_FLAG_ARRAY_STRIDE = 0x808C
+ FEEDBACK_BUFFER_SIZE = 0x0DF1
+ FEEDBACK_BUFFER_TYPE = 0x0DF2
+ FOG_HINT = 0x0C54
+ FRONT_FACE = 0x0B46
+ GREEN_BIAS = 0x0D19
+ GREEN_BITS = 0x0D53
+ GREEN_SCALE = 0x0D18
+ INDEX_ARRAY_STRIDE = 0x8086
+ INDEX_ARRAY_TYPE = 0x8085
+ INDEX_BITS = 0x0D51
+ INDEX_CLEAR_VALUE = 0x0C20
+ INDEX_MODE = 0x0C30
+ INDEX_OFFSET = 0x0D13
+ INDEX_SHIFT = 0x0D12
+ INDEX_WRITEMASK = 0x0C21
+ LIGHT_MODEL_AMBIENT = 0x0B53
+ LIGHT_MODEL_LOCAL_VIEWER = 0x0B51
+ LIGHT_MODEL_TWO_SIDE = 0x0B52
+ LINE_SMOOTH_HINT = 0x0C52
+ LINE_STIPPLE_PATTERN = 0x0B25
+ LINE_STIPPLE_REPEAT = 0x0B26
+ LINE_WIDTH = 0x0B21
+ LINE_WIDTH_GRANULARITY = 0x0B23
+ LINE_WIDTH_RANGE = 0x0B22
+ LIST_BASE = 0x0B32
+ LIST_INDEX = 0x0B33
+ LIST_MODE = 0x0B30
+ LOGIC_OP_MODE = 0x0BF0
+ MAP1_GRID_DOMAIN = 0x0DD0
+ MAP1_GRID_SEGMENTS = 0x0DD1
+ MAP2_GRID_DOMAIN = 0x0DD2
+ MAP2_GRID_SEGMENTS = 0x0DD3
+ MAP_COLOR = 0x0D10
+ MAP_STENCIL = 0x0D11
+ MATRIX_MODE = 0x0BA0
+ MAX_ATTRIB_STACK_DEPTH = 0x0D35
+ MAX_CLIENT_ATTRIB_STACK_DEPTH = 0x0D3B
+ MAX_CLIP_PLANES = 0x0D32
+ MAX_EVAL_ORDER = 0x0D30
+ MAX_LIGHTS = 0x0D31
+ MAX_LIST_NESTING = 0x0B31
+ MAX_MODELVIEW_STACK_DEPTH = 0x0D36
+ MAX_NAME_STACK_DEPTH = 0x0D37
+ MAX_PIXEL_MAP_TABLE = 0x0D34
+ MAX_PROJECTION_STACK_DEPTH = 0x0D38
+ MAX_TEXTURE_SIZE = 0x0D33
+ MAX_TEXTURE_STACK_DEPTH = 0x0D39
+ MAX_VIEWPORT_DIMS = 0x0D3A
+ MODELVIEW_MATRIX = 0x0BA6
+ MODELVIEW_STACK_DEPTH = 0x0BA3
+ NAME_STACK_DEPTH = 0x0D70
+ NORMAL_ARRAY_STRIDE = 0x807F
+ NORMAL_ARRAY_TYPE = 0x807E
+ PACK_ALIGNMENT = 0x0D05
+ PACK_LSB_FIRST = 0x0D01
+ PACK_ROW_LENGTH = 0x0D02
+ PACK_SKIP_PIXELS = 0x0D04
+ PACK_SKIP_ROWS = 0x0D03
+ PACK_SWAP_BYTES = 0x0D00
+ PERSPECTIVE_CORRECTION_HINT = 0x0C50
+ PIXEL_MAP_A_TO_A_SIZE = 0x0CB9
+ PIXEL_MAP_B_TO_B_SIZE = 0x0CB8
+ PIXEL_MAP_G_TO_G_SIZE = 0x0CB7
+ PIXEL_MAP_I_TO_A_SIZE = 0x0CB5
+ PIXEL_MAP_I_TO_B_SIZE = 0x0CB4
+ PIXEL_MAP_I_TO_G_SIZE = 0x0CB3
+ PIXEL_MAP_I_TO_I_SIZE = 0x0CB0
+ PIXEL_MAP_I_TO_R_SIZE = 0x0CB2
+ PIXEL_MAP_R_TO_R_SIZE = 0x0CB6
+ PIXEL_MAP_S_TO_S_SIZE = 0x0CB1
+ POINT_SIZE = 0x0B11
+ POINT_SIZE_GRANULARITY = 0x0B13
+ POINT_SIZE_RANGE = 0x0B12
+ POINT_SMOOTH_HINT = 0x0C51
+ POLYGON_MODE = 0x0B40
+ POLYGON_OFFSET_FACTOR = 0x8038
+ POLYGON_OFFSET_UNITS = 0x2A00
+ POLYGON_SMOOTH_HINT = 0x0C53
+ PROJECTION_MATRIX = 0x0BA7
+ PROJECTION_STACK_DEPTH = 0x0BA4
+ READ_BUFFER = 0x0C02
+ RED_BIAS = 0x0D15
+ RED_BITS = 0x0D52
+ RED_SCALE = 0x0D14
+ RENDER_MODE = 0x0C40
+ RGBA_MODE = 0x0C31
+ SCISSOR_BOX = 0x0C10
+ SELECTION_BUFFER_SIZE = 0x0DF4
+ SHADE_MODEL = 0x0B54
+ STENCIL_BITS = 0x0D57
+ STENCIL_CLEAR_VALUE = 0x0B91
+ STENCIL_FAIL = 0x0B94
+ STENCIL_FUNC = 0x0B92
+ STENCIL_PASS_DEPTH_FAIL = 0x0B95
+ STENCIL_PASS_DEPTH_PASS = 0x0B96
+ STENCIL_REF = 0x0B97
+ STENCIL_VALUE_MASK = 0x0B93
+ STENCIL_WRITEMASK = 0x0B98
+ STEREO = 0x0C33
+ SUBPIXEL_BITS = 0x0D50
+ TEXTURE_BINDING_1D = 0x8068
+ TEXTURE_BINDING_2D = 0x8069
+ TEXTURE_COORD_ARRAY_SIZE = 0x8088
+ TEXTURE_COORD_ARRAY_STRIDE = 0x808A
+ TEXTURE_COORD_ARRAY_TYPE = 0x8089
+ TEXTURE_MATRIX = 0x0BA8
+ TEXTURE_STACK_DEPTH = 0x0BA5
+ UNPACK_ALIGNMENT = 0x0CF5
+ UNPACK_LSB_FIRST = 0x0CF1
+ UNPACK_ROW_LENGTH = 0x0CF2
+ UNPACK_SKIP_PIXELS = 0x0CF4
+ UNPACK_SKIP_ROWS = 0x0CF3
+ UNPACK_SWAP_BYTES = 0x0CF0
+ VERTEX_ARRAY_SIZE = 0x807A
+ VERTEX_ARRAY_STRIDE = 0x807C
+ VERTEX_ARRAY_TYPE = 0x807B
+ VIEWPORT = 0x0BA2
+ ZOOM_X = 0x0D16
+ ZOOM_Y = 0x0D17
+
+ COLOR_ARRAY_POINTER = 0x8090
+ EDGE_FLAG_ARRAY_POINTER = 0x8093
+ FEEDBACK_BUFFER_POINTER = 0x0DF0
+ INDEX_ARRAY_POINTER = 0x8091
+ NORMAL_ARRAY_POINTER = 0x808F
+ SELECTION_BUFFER_POINTER = 0x0DF3
+ TEXTURE_COORD_ARRAY_POINTER = 0x8092
+ VERTEX_ARRAY_POINTER = 0x808E
+
+ TEXTURE_ALPHA_SIZE = 0x805F
+ TEXTURE_BLUE_SIZE = 0x805E
+ TEXTURE_BORDER = 0x1005
+ TEXTURE_BORDER_COLOR = 0x1004
+ TEXTURE_COMPONENTS = 0x1003
+ TEXTURE_GREEN_SIZE = 0x805D
+ TEXTURE_HEIGHT = 0x1001
+ TEXTURE_INTENSITY_SIZE = 0x8061
+ TEXTURE_INTERNAL_FORMAT = 0x1003
+ TEXTURE_LUMINANCE_SIZE = 0x8060
+ TEXTURE_MAG_FILTER = 0x2800
+ TEXTURE_MIN_FILTER = 0x2801
+ TEXTURE_PRIORITY = 0x8066
+ TEXTURE_RED_SIZE = 0x805C
+ TEXTURE_RESIDENT = 0x8067
+ TEXTURE_WIDTH = 0x1000
+ TEXTURE_WRAP_S = 0x2802
+ TEXTURE_WRAP_T = 0x2803
+
+ DONT_CARE = 0x1100
+ FASTEST = 0x1101
+ NICEST = 0x1102
+
+ C3F_V3F = 0x2A24
+ C4F_N3F_V3F = 0x2A26
+ C4UB_V2F = 0x2A22
+ C4UB_V3F = 0x2A23
+ N3F_V3F = 0x2A25
+ T2F_C3F_V3F = 0x2A2A
+ T2F_C4F_N3F_V3F = 0x2A2C
+ T2F_C4UB_V3F = 0x2A29
+ T2F_N3F_V3F = 0x2A2B
+ T2F_V3F = 0x2A27
+ T4F_C4F_N3F_V4F = 0x2A2D
+ T4F_V4F = 0x2A28
+ V2F = 0x2A20
+ V3F = 0x2A21
+
+ MODULATE = 0x2100
+ REPLACE = 0x1E01
+
+ CONSTANT_ATTENUATION = 0x1207
+ LINEAR_ATTENUATION = 0x1208
+ POSITION = 0x1203
+ QUADRATIC_ATTENUATION = 0x1209
+ SPOT_CUTOFF = 0x1206
+ SPOT_DIRECTION = 0x1204
+ SPOT_EXPONENT = 0x1205
+
+ COMPILE = 0x1300
+ COMPILE_AND_EXECUTE = 0x1301
+
+ AND = 0x1501
+ AND_INVERTED = 0x1504
+ AND_REVERSE = 0x1502
+ CLEAR = 0x1500
+ COPY = 0x1503
+ COPY_INVERTED = 0x150C
+ EQUIV = 0x1509
+ INVERT = 0x150A
+ NAND = 0x150E
+ NOOP = 0x1505
+ NOR = 0x1508
+ OR = 0x1507
+ OR_INVERTED = 0x150D
+ OR_REVERSE = 0x150B
+ SET = 0x150F
+ XOR = 0x1506
+
+ COLOR_INDEXES = 0x1603
+ SHININESS = 0x1601
+
+ MODELVIEW = 0x1700
+ PROJECTION = 0x1701
+ TEXTURE = 0x1702
+
+ LINE = 0x1B01
+ POINT = 0x1B00
+
+ FILL = 0x1B02
+
+ COLOR = 0x1800
+ DEPTH = 0x1801
+ STENCIL = 0x1802
+
+ ALPHA = 0x1906
+ BLUE = 0x1905
+ COLOR_INDEX = 0x1900
+ DEPTH_COMPONENT = 0x1902
+ GREEN = 0x1904
+ LUMINANCE = 0x1909
+ LUMINANCE_ALPHA = 0x190A
+ RED = 0x1903
+ RGB = 0x1907
+ RGBA = 0x1908
+ STENCIL_INDEX = 0x1901
+
+ ALPHA12 = 0x803D
+ ALPHA16 = 0x803E
+ ALPHA4 = 0x803B
+ ALPHA8 = 0x803C
+ INTENSITY = 0x8049
+ INTENSITY12 = 0x804C
+ INTENSITY16 = 0x804D
+ INTENSITY4 = 0x804A
+ INTENSITY8 = 0x804B
+ LUMINANCE12 = 0x8041
+ LUMINANCE12_ALPHA12 = 0x8047
+ LUMINANCE12_ALPHA4 = 0x8046
+ LUMINANCE16 = 0x8042
+ LUMINANCE16_ALPHA16 = 0x8048
+ LUMINANCE4 = 0x803F
+ LUMINANCE4_ALPHA4 = 0x8043
+ LUMINANCE6_ALPHA2 = 0x8044
+ LUMINANCE8 = 0x8040
+ LUMINANCE8_ALPHA8 = 0x8045
+ R3_G3_B2 = 0x2A10
+ RGB10 = 0x8052
+ RGB10_A2 = 0x8059
+ RGB12 = 0x8053
+ RGB16 = 0x8054
+ RGB4 = 0x804F
+ RGB5 = 0x8050
+ RGB5_A1 = 0x8057
+ RGB8 = 0x8051
+ RGBA12 = 0x805A
+ RGBA16 = 0x805B
+ RGBA2 = 0x8055
+ RGBA4 = 0x8056
+ RGBA8 = 0x8058
+
+ BITMAP = 0x1A00
+
+ LINES = 0x0001
+ LINE_LOOP = 0x0002
+ LINE_STRIP = 0x0003
+ POINTS = 0x0000
+ POLYGON = 0x0009
+ QUADS = 0x0007
+ QUAD_STRIP = 0x0008
+ TRIANGLES = 0x0004
+ TRIANGLE_FAN = 0x0006
+ TRIANGLE_STRIP = 0x0005
+
+ FEEDBACK = 0x1C01
+ RENDER = 0x1C00
+ SELECT = 0x1C02
+
+ FLAT = 0x1D00
+ SMOOTH = 0x1D01
+
+ DECR = 0x1E03
+ INCR = 0x1E02
+ KEEP = 0x1E00
+
+ EXTENSIONS = 0x1F03
+ RENDERER = 0x1F01
+ VENDOR = 0x1F00
+ VERSION = 0x1F02
+
+ S = 0x2000
+ T = 0x2001
+ R = 0x2002
+ Q = 0x2003
+
+ DECAL = 0x2101
+
+ TEXTURE_ENV_COLOR = 0x2201
+ TEXTURE_ENV_MODE = 0x2200
+
+ TEXTURE_ENV = 0x2300
+
+ EYE_LINEAR = 0x2400
+ OBJECT_LINEAR = 0x2401
+ SPHERE_MAP = 0x2402
+
+ EYE_PLANE = 0x2502
+ OBJECT_PLANE = 0x2501
+ TEXTURE_GEN_MODE = 0x2500
+
+ NEAREST = 0x2600
+
+ LINEAR_MIPMAP_LINEAR = 0x2703
+ LINEAR_MIPMAP_NEAREST = 0x2701
+ NEAREST_MIPMAP_LINEAR = 0x2702
+ NEAREST_MIPMAP_NEAREST = 0x2700
+
+ PROXY_TEXTURE_1D = 0x8063
+ PROXY_TEXTURE_2D = 0x8064
+
+ CLAMP = 0x2900
+ REPEAT = 0x2901
+)
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glViewport.xml
+func (gl *GL) Viewport(x, y, width, height int) {
+ C.gl1_0_glViewport(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// DepthRange specifies the mapping of depth values from normalized device
+// coordinates to window coordinates.
+//
+// Parameter nearVal specifies the mapping of the near clipping plane to window
+// coordinates (defaults to 0), while farVal specifies the mapping of the far
+// clipping plane to window coordinates (defaults to 1).
+//
+// After clipping and division by w, depth coordinates range from -1 to 1,
+// corresponding to the near and far clipping planes. DepthRange specifies a
+// linear mapping of the normalized depth coordinates in this range to window
+// depth coordinates. Regardless of the actual depth buffer implementation,
+// window coordinate depth values are treated as though they range from 0 through 1
+// (like color components). Thus, the values accepted by DepthRange are both
+// clamped to this range before they are accepted.
+//
+// The default setting of (0, 1) maps the near plane to 0 and the far plane to 1.
+// With this mapping, the depth buffer range is fully utilized.
+//
+// It is not necessary that nearVal be less than farVal. Reverse mappings such as
+// nearVal 1, and farVal 0 are acceptable.
+//
+// GL.INVALID_OPERATION is generated if DepthRange is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) DepthRange(nearVal, farVal float64) {
+ C.gl1_0_glDepthRange(gl.funcs, C.GLdouble(nearVal), C.GLdouble(farVal))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIsEnabled.xml
+func (gl *GL) IsEnabled(cap glbase.Enum) bool {
+ glresult := C.gl1_0_glIsEnabled(gl.funcs, C.GLenum(cap))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexLevelParameteriv.xml
+func (gl *GL) GetTexLevelParameteriv(target glbase.Enum, level int, pname glbase.Enum, params []int32) {
+ C.gl1_0_glGetTexLevelParameteriv(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexLevelParameterfv.xml
+func (gl *GL) GetTexLevelParameterfv(target glbase.Enum, level int, pname glbase.Enum, params []float32) {
+ C.gl1_0_glGetTexLevelParameterfv(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexParameteriv.xml
+func (gl *GL) GetTexParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl1_0_glGetTexParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexParameterfv.xml
+func (gl *GL) GetTexParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl1_0_glGetTexParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexImage.xml
+func (gl *GL) GetTexImage(target glbase.Enum, level int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_0_glGetTexImage(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetIntegerv.xml
+func (gl *GL) GetIntegerv(pname glbase.Enum, params []int32) {
+ C.gl1_0_glGetIntegerv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetFloatv.xml
+func (gl *GL) GetFloatv(pname glbase.Enum, params []float32) {
+ C.gl1_0_glGetFloatv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetError.xml
+func (gl *GL) GetError() glbase.Enum {
+ glresult := C.gl1_0_glGetError(gl.funcs)
+ return glbase.Enum(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetDoublev.xml
+func (gl *GL) GetDoublev(pname glbase.Enum, params []float64) {
+ C.gl1_0_glGetDoublev(gl.funcs, C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetBooleanv.xml
+func (gl *GL) GetBooleanv(pname glbase.Enum, params []bool) {
+ C.gl1_0_glGetBooleanv(gl.funcs, C.GLenum(pname), (*C.GLboolean)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glReadPixels.xml
+func (gl *GL) ReadPixels(x, y, width, height int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_0_glReadPixels(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glReadBuffer.xml
+func (gl *GL) ReadBuffer(mode glbase.Enum) {
+ C.gl1_0_glReadBuffer(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelStorei.xml
+func (gl *GL) PixelStorei(pname glbase.Enum, param int32) {
+ C.gl1_0_glPixelStorei(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelStoref.xml
+func (gl *GL) PixelStoref(pname glbase.Enum, param float32) {
+ C.gl1_0_glPixelStoref(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDepthFunc.xml
+func (gl *GL) DepthFunc(glfunc glbase.Enum) {
+ C.gl1_0_glDepthFunc(gl.funcs, C.GLenum(glfunc))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glStencilOp.xml
+func (gl *GL) StencilOp(fail, zfail, zpass glbase.Enum) {
+ C.gl1_0_glStencilOp(gl.funcs, C.GLenum(fail), C.GLenum(zfail), C.GLenum(zpass))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glStencilFunc.xml
+func (gl *GL) StencilFunc(glfunc glbase.Enum, ref int32, mask uint32) {
+ C.gl1_0_glStencilFunc(gl.funcs, C.GLenum(glfunc), C.GLint(ref), C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLogicOp.xml
+func (gl *GL) LogicOp(opcode glbase.Enum) {
+ C.gl1_0_glLogicOp(gl.funcs, C.GLenum(opcode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBlendFunc.xml
+func (gl *GL) BlendFunc(sfactor, dfactor glbase.Enum) {
+ C.gl1_0_glBlendFunc(gl.funcs, C.GLenum(sfactor), C.GLenum(dfactor))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFlush.xml
+func (gl *GL) Flush() {
+ C.gl1_0_glFlush(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFinish.xml
+func (gl *GL) Finish() {
+ C.gl1_0_glFinish(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEnable.xml
+func (gl *GL) Enable(cap glbase.Enum) {
+ C.gl1_0_glEnable(gl.funcs, C.GLenum(cap))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDisable.xml
+func (gl *GL) Disable(cap glbase.Enum) {
+ C.gl1_0_glDisable(gl.funcs, C.GLenum(cap))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDepthMask.xml
+func (gl *GL) DepthMask(flag bool) {
+ C.gl1_0_glDepthMask(gl.funcs, *(*C.GLboolean)(unsafe.Pointer(&flag)))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColorMask.xml
+func (gl *GL) ColorMask(red, green, blue, alpha bool) {
+ C.gl1_0_glColorMask(gl.funcs, *(*C.GLboolean)(unsafe.Pointer(&red)), *(*C.GLboolean)(unsafe.Pointer(&green)), *(*C.GLboolean)(unsafe.Pointer(&blue)), *(*C.GLboolean)(unsafe.Pointer(&alpha)))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glStencilMask.xml
+func (gl *GL) StencilMask(mask uint32) {
+ C.gl1_0_glStencilMask(gl.funcs, C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClearDepth.xml
+func (gl *GL) ClearDepth(depth float64) {
+ C.gl1_0_glClearDepth(gl.funcs, C.GLdouble(depth))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClearStencil.xml
+func (gl *GL) ClearStencil(s int32) {
+ C.gl1_0_glClearStencil(gl.funcs, C.GLint(s))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClearColor.xml
+func (gl *GL) ClearColor(red, green, blue, alpha float32) {
+ C.gl1_0_glClearColor(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClear.xml
+func (gl *GL) Clear(mask glbase.Bitfield) {
+ C.gl1_0_glClear(gl.funcs, C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDrawBuffer.xml
+func (gl *GL) DrawBuffer(mode glbase.Enum) {
+ C.gl1_0_glDrawBuffer(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexImage2D.xml
+func (gl *GL) TexImage2D(target glbase.Enum, level int, internalFormat int32, width, height, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_0_glTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexImage1D.xml
+func (gl *GL) TexImage1D(target glbase.Enum, level int, internalFormat int32, width, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_0_glTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexParameteriv.xml
+func (gl *GL) TexParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl1_0_glTexParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexParameteri.xml
+func (gl *GL) TexParameteri(target, pname glbase.Enum, param int32) {
+ C.gl1_0_glTexParameteri(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexParameterfv.xml
+func (gl *GL) TexParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl1_0_glTexParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexParameterf.xml
+func (gl *GL) TexParameterf(target, pname glbase.Enum, param float32) {
+ C.gl1_0_glTexParameterf(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glScissor.xml
+func (gl *GL) Scissor(x, y, width, height int) {
+ C.gl1_0_glScissor(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPolygonMode.xml
+func (gl *GL) PolygonMode(face, mode glbase.Enum) {
+ C.gl1_0_glPolygonMode(gl.funcs, C.GLenum(face), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPointSize.xml
+func (gl *GL) PointSize(size float32) {
+ C.gl1_0_glPointSize(gl.funcs, C.GLfloat(size))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLineWidth.xml
+func (gl *GL) LineWidth(width float32) {
+ C.gl1_0_glLineWidth(gl.funcs, C.GLfloat(width))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glHint.xml
+func (gl *GL) Hint(target, mode glbase.Enum) {
+ C.gl1_0_glHint(gl.funcs, C.GLenum(target), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFrontFace.xml
+func (gl *GL) FrontFace(mode glbase.Enum) {
+ C.gl1_0_glFrontFace(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCullFace.xml
+func (gl *GL) CullFace(mode glbase.Enum) {
+ C.gl1_0_glCullFace(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTranslatef.xml
+func (gl *GL) Translatef(x, y, z float32) {
+ C.gl1_0_glTranslatef(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTranslated.xml
+func (gl *GL) Translated(x, y, z float64) {
+ C.gl1_0_glTranslated(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glScalef.xml
+func (gl *GL) Scalef(x, y, z float32) {
+ C.gl1_0_glScalef(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glScaled.xml
+func (gl *GL) Scaled(x, y, z float64) {
+ C.gl1_0_glScaled(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRotatef.xml
+func (gl *GL) Rotatef(angle, x, y, z float32) {
+ C.gl1_0_glRotatef(gl.funcs, C.GLfloat(angle), C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRotated.xml
+func (gl *GL) Rotated(angle, x, y, z float64) {
+ C.gl1_0_glRotated(gl.funcs, C.GLdouble(angle), C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPushMatrix.xml
+func (gl *GL) PushMatrix() {
+ C.gl1_0_glPushMatrix(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPopMatrix.xml
+func (gl *GL) PopMatrix() {
+ C.gl1_0_glPopMatrix(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glOrtho.xml
+func (gl *GL) Ortho(left, right, bottom, top, zNear, zFar float64) {
+ C.gl1_0_glOrtho(gl.funcs, C.GLdouble(left), C.GLdouble(right), C.GLdouble(bottom), C.GLdouble(top), C.GLdouble(zNear), C.GLdouble(zFar))
+}
+
+// MultMatrixd multiplies the current matrix with the provided matrix.
+//
+// The m parameter must hold 16 consecutive elements of a 4x4 column-major matrix.
+//
+// The current matrix is determined by the current matrix mode (see
+// MatrixMode). It is either the projection matrix, modelview matrix, or the
+// texture matrix.
+//
+// For example, if the current matrix is C and the coordinates to be transformed
+// are v = (v[0], v[1], v[2], v[3]), then the current transformation is C × v, or
+//
+// c[0] c[4] c[8] c[12] v[0]
+// c[1] c[5] c[9] c[13] v[1]
+// c[2] c[6] c[10] c[14] X v[2]
+// c[3] c[7] c[11] c[15] v[3]
+//
+// Calling MultMatrix with an argument of m = m[0], m[1], ..., m[15]
+// replaces the current transformation with (C X M) x v, or
+//
+// c[0] c[4] c[8] c[12] m[0] m[4] m[8] m[12] v[0]
+// c[1] c[5] c[9] c[13] m[1] m[5] m[9] m[13] v[1]
+// c[2] c[6] c[10] c[14] X m[2] m[6] m[10] m[14] X v[2]
+// c[3] c[7] c[11] c[15] m[3] m[7] m[11] m[15] v[3]
+//
+// Where 'X' denotes matrix multiplication, and v is represented as a 4x1 matrix.
+//
+// While the elements of the matrix may be specified with single or double
+// precision, the GL may store or operate on these values in less-than-single
+// precision.
+//
+// In many computer languages, 4×4 arrays are represented in row-major
+// order. The transformations just described represent these matrices in
+// column-major order. The order of the multiplication is important. For
+// example, if the current transformation is a rotation, and MultMatrix is
+// called with a translation matrix, the translation is done directly on the
+// coordinates to be transformed, while the rotation is done on the results
+// of that translation.
+//
+// GL.INVALID_OPERATION is generated if MultMatrix is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) MultMatrixd(m []float64) {
+ if len(m) != 16 {
+ panic("parameter m must have length 16 for the 4x4 matrix")
+ }
+ C.gl1_0_glMultMatrixd(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&m[0])))
+}
+
+// MultMatrixf multiplies the current matrix with the provided matrix.
+//
+// The m parameter must hold 16 consecutive elements of a 4x4 column-major matrix.
+//
+// The current matrix is determined by the current matrix mode (see
+// MatrixMode). It is either the projection matrix, modelview matrix, or the
+// texture matrix.
+//
+// For example, if the current matrix is C and the coordinates to be transformed
+// are v = (v[0], v[1], v[2], v[3]), then the current transformation is C × v, or
+//
+// c[0] c[4] c[8] c[12] v[0]
+// c[1] c[5] c[9] c[13] v[1]
+// c[2] c[6] c[10] c[14] X v[2]
+// c[3] c[7] c[11] c[15] v[3]
+//
+// Calling MultMatrix with an argument of m = m[0], m[1], ..., m[15]
+// replaces the current transformation with (C X M) x v, or
+//
+// c[0] c[4] c[8] c[12] m[0] m[4] m[8] m[12] v[0]
+// c[1] c[5] c[9] c[13] m[1] m[5] m[9] m[13] v[1]
+// c[2] c[6] c[10] c[14] X m[2] m[6] m[10] m[14] X v[2]
+// c[3] c[7] c[11] c[15] m[3] m[7] m[11] m[15] v[3]
+//
+// Where 'X' denotes matrix multiplication, and v is represented as a 4x1 matrix.
+//
+// While the elements of the matrix may be specified with single or double
+// precision, the GL may store or operate on these values in less-than-single
+// precision.
+//
+// In many computer languages, 4×4 arrays are represented in row-major
+// order. The transformations just described represent these matrices in
+// column-major order. The order of the multiplication is important. For
+// example, if the current transformation is a rotation, and MultMatrix is
+// called with a translation matrix, the translation is done directly on the
+// coordinates to be transformed, while the rotation is done on the results
+// of that translation.
+//
+// GL.INVALID_OPERATION is generated if MultMatrix is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) MultMatrixf(m []float32) {
+ if len(m) != 16 {
+ panic("parameter m must have length 16 for the 4x4 matrix")
+ }
+ C.gl1_0_glMultMatrixf(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMatrixMode.xml
+func (gl *GL) MatrixMode(mode glbase.Enum) {
+ C.gl1_0_glMatrixMode(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLoadMatrixd.xml
+func (gl *GL) LoadMatrixd(m []float64) {
+ C.gl1_0_glLoadMatrixd(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLoadMatrixf.xml
+func (gl *GL) LoadMatrixf(m []float32) {
+ C.gl1_0_glLoadMatrixf(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLoadIdentity.xml
+func (gl *GL) LoadIdentity() {
+ C.gl1_0_glLoadIdentity(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFrustum.xml
+func (gl *GL) Frustum(left, right, bottom, top, zNear, zFar float64) {
+ C.gl1_0_glFrustum(gl.funcs, C.GLdouble(left), C.GLdouble(right), C.GLdouble(bottom), C.GLdouble(top), C.GLdouble(zNear), C.GLdouble(zFar))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIsList.xml
+func (gl *GL) IsList(list uint32) bool {
+ glresult := C.gl1_0_glIsList(gl.funcs, C.GLuint(list))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexGeniv.xml
+func (gl *GL) GetTexGeniv(coord, pname glbase.Enum, params []int32) {
+ C.gl1_0_glGetTexGeniv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexGenfv.xml
+func (gl *GL) GetTexGenfv(coord, pname glbase.Enum, params []float32) {
+ C.gl1_0_glGetTexGenfv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexGendv.xml
+func (gl *GL) GetTexGendv(coord, pname glbase.Enum, params []float64) {
+ C.gl1_0_glGetTexGendv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexEnviv.xml
+func (gl *GL) GetTexEnviv(target, pname glbase.Enum, params []int32) {
+ C.gl1_0_glGetTexEnviv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexEnvfv.xml
+func (gl *GL) GetTexEnvfv(target, pname glbase.Enum, params []float32) {
+ C.gl1_0_glGetTexEnvfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetPolygonStipple.xml
+func (gl *GL) GetPolygonStipple(mask []uint8) {
+ C.gl1_0_glGetPolygonStipple(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&mask[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetPixelMapusv.xml
+func (gl *GL) GetPixelMapusv(glmap glbase.Enum, values []uint16) {
+ C.gl1_0_glGetPixelMapusv(gl.funcs, C.GLenum(glmap), (*C.GLushort)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetPixelMapuiv.xml
+func (gl *GL) GetPixelMapuiv(glmap glbase.Enum, values []uint32) {
+ C.gl1_0_glGetPixelMapuiv(gl.funcs, C.GLenum(glmap), (*C.GLuint)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetPixelMapfv.xml
+func (gl *GL) GetPixelMapfv(glmap glbase.Enum, values []float32) {
+ C.gl1_0_glGetPixelMapfv(gl.funcs, C.GLenum(glmap), (*C.GLfloat)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetMaterialiv.xml
+func (gl *GL) GetMaterialiv(face, pname glbase.Enum, params []int32) {
+ C.gl1_0_glGetMaterialiv(gl.funcs, C.GLenum(face), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetMaterialfv.xml
+func (gl *GL) GetMaterialfv(face, pname glbase.Enum, params []float32) {
+ C.gl1_0_glGetMaterialfv(gl.funcs, C.GLenum(face), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetMapiv.xml
+func (gl *GL) GetMapiv(target, query glbase.Enum, v []int32) {
+ C.gl1_0_glGetMapiv(gl.funcs, C.GLenum(target), C.GLenum(query), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetMapfv.xml
+func (gl *GL) GetMapfv(target, query glbase.Enum, v []float32) {
+ C.gl1_0_glGetMapfv(gl.funcs, C.GLenum(target), C.GLenum(query), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetMapdv.xml
+func (gl *GL) GetMapdv(target, query glbase.Enum, v []float64) {
+ C.gl1_0_glGetMapdv(gl.funcs, C.GLenum(target), C.GLenum(query), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetLightiv.xml
+func (gl *GL) GetLightiv(light, pname glbase.Enum, params []int32) {
+ C.gl1_0_glGetLightiv(gl.funcs, C.GLenum(light), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetLightfv.xml
+func (gl *GL) GetLightfv(light, pname glbase.Enum, params []float32) {
+ C.gl1_0_glGetLightfv(gl.funcs, C.GLenum(light), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetClipPlane.xml
+func (gl *GL) GetClipPlane(plane glbase.Enum, equation []float64) {
+ C.gl1_0_glGetClipPlane(gl.funcs, C.GLenum(plane), (*C.GLdouble)(unsafe.Pointer(&equation[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDrawPixels.xml
+func (gl *GL) DrawPixels(width, height int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_0_glDrawPixels(gl.funcs, C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyPixels.xml
+func (gl *GL) CopyPixels(x, y, width, height int, gltype glbase.Enum) {
+ C.gl1_0_glCopyPixels(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height), C.GLenum(gltype))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelMapusv.xml
+func (gl *GL) PixelMapusv(glmap glbase.Enum, mapsize int32, values []uint16) {
+ C.gl1_0_glPixelMapusv(gl.funcs, C.GLenum(glmap), C.GLint(mapsize), (*C.GLushort)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelMapuiv.xml
+func (gl *GL) PixelMapuiv(glmap glbase.Enum, mapsize int32, values []uint32) {
+ C.gl1_0_glPixelMapuiv(gl.funcs, C.GLenum(glmap), C.GLint(mapsize), (*C.GLuint)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelMapfv.xml
+func (gl *GL) PixelMapfv(glmap glbase.Enum, mapsize int32, values []float32) {
+ C.gl1_0_glPixelMapfv(gl.funcs, C.GLenum(glmap), C.GLint(mapsize), (*C.GLfloat)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelTransferi.xml
+func (gl *GL) PixelTransferi(pname glbase.Enum, param int32) {
+ C.gl1_0_glPixelTransferi(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelTransferf.xml
+func (gl *GL) PixelTransferf(pname glbase.Enum, param float32) {
+ C.gl1_0_glPixelTransferf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelZoom.xml
+func (gl *GL) PixelZoom(xfactor, yfactor float32) {
+ C.gl1_0_glPixelZoom(gl.funcs, C.GLfloat(xfactor), C.GLfloat(yfactor))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glAlphaFunc.xml
+func (gl *GL) AlphaFunc(glfunc glbase.Enum, ref float32) {
+ C.gl1_0_glAlphaFunc(gl.funcs, C.GLenum(glfunc), C.GLfloat(ref))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalPoint2.xml
+func (gl *GL) EvalPoint2(i, j int32) {
+ C.gl1_0_glEvalPoint2(gl.funcs, C.GLint(i), C.GLint(j))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalMesh2.xml
+func (gl *GL) EvalMesh2(mode glbase.Enum, i1, i2, j1, j2 int32) {
+ C.gl1_0_glEvalMesh2(gl.funcs, C.GLenum(mode), C.GLint(i1), C.GLint(i2), C.GLint(j1), C.GLint(j2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalPoint1.xml
+func (gl *GL) EvalPoint1(i int32) {
+ C.gl1_0_glEvalPoint1(gl.funcs, C.GLint(i))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalMesh1.xml
+func (gl *GL) EvalMesh1(mode glbase.Enum, i1, i2 int32) {
+ C.gl1_0_glEvalMesh1(gl.funcs, C.GLenum(mode), C.GLint(i1), C.GLint(i2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord2fv.xml
+func (gl *GL) EvalCoord2fv(u []float32) {
+ if len(u) != 2 {
+ panic("parameter u has incorrect length")
+ }
+ C.gl1_0_glEvalCoord2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&u[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord2f.xml
+func (gl *GL) EvalCoord2f(u, v float32) {
+ C.gl1_0_glEvalCoord2f(gl.funcs, C.GLfloat(u), C.GLfloat(v))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord2dv.xml
+func (gl *GL) EvalCoord2dv(u []float64) {
+ if len(u) != 2 {
+ panic("parameter u has incorrect length")
+ }
+ C.gl1_0_glEvalCoord2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&u[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord2d.xml
+func (gl *GL) EvalCoord2d(u, v float64) {
+ C.gl1_0_glEvalCoord2d(gl.funcs, C.GLdouble(u), C.GLdouble(v))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord1fv.xml
+func (gl *GL) EvalCoord1fv(u []float32) {
+ C.gl1_0_glEvalCoord1fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&u[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord1f.xml
+func (gl *GL) EvalCoord1f(u float32) {
+ C.gl1_0_glEvalCoord1f(gl.funcs, C.GLfloat(u))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord1dv.xml
+func (gl *GL) EvalCoord1dv(u []float64) {
+ C.gl1_0_glEvalCoord1dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&u[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord1d.xml
+func (gl *GL) EvalCoord1d(u float64) {
+ C.gl1_0_glEvalCoord1d(gl.funcs, C.GLdouble(u))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMapGrid2f.xml
+func (gl *GL) MapGrid2f(un int32, u1, u2 float32, vn int32, v1, v2 float32) {
+ C.gl1_0_glMapGrid2f(gl.funcs, C.GLint(un), C.GLfloat(u1), C.GLfloat(u2), C.GLint(vn), C.GLfloat(v1), C.GLfloat(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMapGrid2d.xml
+func (gl *GL) MapGrid2d(un int32, u1, u2 float64, vn int32, v1, v2 float64) {
+ C.gl1_0_glMapGrid2d(gl.funcs, C.GLint(un), C.GLdouble(u1), C.GLdouble(u2), C.GLint(vn), C.GLdouble(v1), C.GLdouble(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMapGrid1f.xml
+func (gl *GL) MapGrid1f(un int32, u1, u2 float32) {
+ C.gl1_0_glMapGrid1f(gl.funcs, C.GLint(un), C.GLfloat(u1), C.GLfloat(u2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMapGrid1d.xml
+func (gl *GL) MapGrid1d(un int32, u1, u2 float64) {
+ C.gl1_0_glMapGrid1d(gl.funcs, C.GLint(un), C.GLdouble(u1), C.GLdouble(u2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMap2f.xml
+func (gl *GL) Map2f(target glbase.Enum, u1, u2 float32, ustride, uorder int32, v1, v2 float32, vstride, vorder int32, points []float32) {
+ C.gl1_0_glMap2f(gl.funcs, C.GLenum(target), C.GLfloat(u1), C.GLfloat(u2), C.GLint(ustride), C.GLint(uorder), C.GLfloat(v1), C.GLfloat(v2), C.GLint(vstride), C.GLint(vorder), (*C.GLfloat)(unsafe.Pointer(&points[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMap2d.xml
+func (gl *GL) Map2d(target glbase.Enum, u1, u2 float64, ustride, uorder int32, v1, v2 float64, vstride, vorder int32, points []float64) {
+ C.gl1_0_glMap2d(gl.funcs, C.GLenum(target), C.GLdouble(u1), C.GLdouble(u2), C.GLint(ustride), C.GLint(uorder), C.GLdouble(v1), C.GLdouble(v2), C.GLint(vstride), C.GLint(vorder), (*C.GLdouble)(unsafe.Pointer(&points[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMap1f.xml
+func (gl *GL) Map1f(target glbase.Enum, u1, u2 float32, stride, order int, points []float32) {
+ C.gl1_0_glMap1f(gl.funcs, C.GLenum(target), C.GLfloat(u1), C.GLfloat(u2), C.GLint(stride), C.GLint(order), (*C.GLfloat)(unsafe.Pointer(&points[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMap1d.xml
+func (gl *GL) Map1d(target glbase.Enum, u1, u2 float64, stride, order int, points []float64) {
+ C.gl1_0_glMap1d(gl.funcs, C.GLenum(target), C.GLdouble(u1), C.GLdouble(u2), C.GLint(stride), C.GLint(order), (*C.GLdouble)(unsafe.Pointer(&points[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPushAttrib.xml
+func (gl *GL) PushAttrib(mask glbase.Bitfield) {
+ C.gl1_0_glPushAttrib(gl.funcs, C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPopAttrib.xml
+func (gl *GL) PopAttrib() {
+ C.gl1_0_glPopAttrib(gl.funcs)
+}
+
+// Accum executes an operation on the accumulation buffer.
+//
+// Parameter op defines the accumulation buffer operation (GL.ACCUM, GL.LOAD,
+// GL.ADD, GL.MULT, or GL.RETURN) and specifies how the value parameter is
+// used.
+//
+// The accumulation buffer is an extended-range color buffer. Images are not
+// rendered into it. Rather, images rendered into one of the color buffers
+// are added to the contents of the accumulation buffer after rendering.
+// Effects such as antialiasing (of points, lines, and polygons), motion
+// blur, and depth of field can be created by accumulating images generated
+// with different transformation matrices.
+//
+// Each pixel in the accumulation buffer consists of red, green, blue, and
+// alpha values. The number of bits per component in the accumulation buffer
+// depends on the implementation. You can examine this number by calling
+// GetIntegerv four times, with arguments GL.ACCUM_RED_BITS,
+// GL.ACCUM_GREEN_BITS, GL.ACCUM_BLUE_BITS, and GL.ACCUM_ALPHA_BITS.
+// Regardless of the number of bits per component, the range of values stored
+// by each component is (-1, 1). The accumulation buffer pixels are mapped
+// one-to-one with frame buffer pixels.
+//
+// All accumulation buffer operations are limited to the area of the current
+// scissor box and applied identically to the red, green, blue, and alpha
+// components of each pixel. If a Accum operation results in a value outside
+// the range (-1, 1), the contents of an accumulation buffer pixel component
+// are undefined.
+//
+// The operations are as follows:
+//
+// GL.ACCUM
+// Obtains R, G, B, and A values from the buffer currently selected for
+// reading (see ReadBuffer). Each component value is divided by 2 n -
+// 1 , where n is the number of bits allocated to each color component
+// in the currently selected buffer. The result is a floating-point
+// value in the range 0 1 , which is multiplied by value and added to
+// the corresponding pixel component in the accumulation buffer,
+// thereby updating the accumulation buffer.
+//
+// GL.LOAD
+// Similar to GL.ACCUM, except that the current value in the
+// accumulation buffer is not used in the calculation of the new value.
+// That is, the R, G, B, and A values from the currently selected
+// buffer are divided by 2 n - 1 , multiplied by value, and then stored
+// in the corresponding accumulation buffer cell, overwriting the
+// current value.
+//
+// GL.ADD
+// Adds value to each R, G, B, and A in the accumulation buffer.
+//
+// GL.MULT
+// Multiplies each R, G, B, and A in the accumulation buffer by value
+// and returns the scaled component to its corresponding accumulation
+// buffer location.
+//
+// GL.RETURN
+// Transfers accumulation buffer values to the color buffer or buffers
+// currently selected for writing. Each R, G, B, and A component is
+// multiplied by value, then multiplied by 2 n - 1 , clamped to the
+// range 0 2 n - 1 , and stored in the corresponding display buffer
+// cell. The only fragment operations that are applied to this transfer
+// are pixel ownership, scissor, dithering, and color writemasks.
+//
+// To clear the accumulation buffer, call ClearAccum with R, G, B, and A
+// values to set it to, then call Clear with the accumulation buffer
+// enabled.
+//
+// Error GL.INVALID_ENUM is generated if op is not an accepted value.
+// GL.INVALID_OPERATION is generated if there is no accumulation buffer.
+// GL.INVALID_OPERATION is generated if Accum is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) Accum(op glbase.Enum, value float32) {
+ C.gl1_0_glAccum(gl.funcs, C.GLenum(op), C.GLfloat(value))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexMask.xml
+func (gl *GL) IndexMask(mask uint32) {
+ C.gl1_0_glIndexMask(gl.funcs, C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClearIndex.xml
+func (gl *GL) ClearIndex(c float32) {
+ C.gl1_0_glClearIndex(gl.funcs, C.GLfloat(c))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClearAccum.xml
+func (gl *GL) ClearAccum(red, green, blue, alpha float32) {
+ C.gl1_0_glClearAccum(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPushName.xml
+func (gl *GL) PushName(name uint32) {
+ C.gl1_0_glPushName(gl.funcs, C.GLuint(name))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPopName.xml
+func (gl *GL) PopName() {
+ C.gl1_0_glPopName(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPassThrough.xml
+func (gl *GL) PassThrough(token float32) {
+ C.gl1_0_glPassThrough(gl.funcs, C.GLfloat(token))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLoadName.xml
+func (gl *GL) LoadName(name uint32) {
+ C.gl1_0_glLoadName(gl.funcs, C.GLuint(name))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glInitNames.xml
+func (gl *GL) InitNames() {
+ C.gl1_0_glInitNames(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRenderMode.xml
+func (gl *GL) RenderMode(mode glbase.Enum) int32 {
+ glresult := C.gl1_0_glRenderMode(gl.funcs, C.GLenum(mode))
+ return int32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSelectBuffer.xml
+func (gl *GL) SelectBuffer(size int, buffer []glbase.Buffer) {
+ C.gl1_0_glSelectBuffer(gl.funcs, C.GLsizei(size), (*C.GLuint)(unsafe.Pointer(&buffer[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFeedbackBuffer.xml
+func (gl *GL) FeedbackBuffer(size int, gltype glbase.Enum, buffer []float32) {
+ C.gl1_0_glFeedbackBuffer(gl.funcs, C.GLsizei(size), C.GLenum(gltype), (*C.GLfloat)(unsafe.Pointer(&buffer[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexGeniv.xml
+func (gl *GL) TexGeniv(coord, pname glbase.Enum, params []int32) {
+ C.gl1_0_glTexGeniv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexGeni.xml
+func (gl *GL) TexGeni(coord, pname glbase.Enum, param int32) {
+ C.gl1_0_glTexGeni(gl.funcs, C.GLenum(coord), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexGenfv.xml
+func (gl *GL) TexGenfv(coord, pname glbase.Enum, params []float32) {
+ C.gl1_0_glTexGenfv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexGenf.xml
+func (gl *GL) TexGenf(coord, pname glbase.Enum, param float32) {
+ C.gl1_0_glTexGenf(gl.funcs, C.GLenum(coord), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexGendv.xml
+func (gl *GL) TexGendv(coord, pname glbase.Enum, params []float64) {
+ C.gl1_0_glTexGendv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexGend.xml
+func (gl *GL) TexGend(coord, pname glbase.Enum, param float64) {
+ C.gl1_0_glTexGend(gl.funcs, C.GLenum(coord), C.GLenum(pname), C.GLdouble(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexEnviv.xml
+func (gl *GL) TexEnviv(target, pname glbase.Enum, params []int32) {
+ C.gl1_0_glTexEnviv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexEnvi.xml
+func (gl *GL) TexEnvi(target, pname glbase.Enum, param int32) {
+ C.gl1_0_glTexEnvi(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexEnvfv.xml
+func (gl *GL) TexEnvfv(target, pname glbase.Enum, params []float32) {
+ C.gl1_0_glTexEnvfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexEnvf.xml
+func (gl *GL) TexEnvf(target, pname glbase.Enum, param float32) {
+ C.gl1_0_glTexEnvf(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glShadeModel.xml
+func (gl *GL) ShadeModel(mode glbase.Enum) {
+ C.gl1_0_glShadeModel(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPolygonStipple.xml
+func (gl *GL) PolygonStipple(mask []uint8) {
+ C.gl1_0_glPolygonStipple(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&mask[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMaterialiv.xml
+func (gl *GL) Materialiv(face, pname glbase.Enum, params []int32) {
+ C.gl1_0_glMaterialiv(gl.funcs, C.GLenum(face), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMateriali.xml
+func (gl *GL) Materiali(face, pname glbase.Enum, param int32) {
+ C.gl1_0_glMateriali(gl.funcs, C.GLenum(face), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMaterialfv.xml
+func (gl *GL) Materialfv(face, pname glbase.Enum, params []float32) {
+ C.gl1_0_glMaterialfv(gl.funcs, C.GLenum(face), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMaterialf.xml
+func (gl *GL) Materialf(face, pname glbase.Enum, param float32) {
+ C.gl1_0_glMaterialf(gl.funcs, C.GLenum(face), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLineStipple.xml
+func (gl *GL) LineStipple(factor int32, pattern uint16) {
+ C.gl1_0_glLineStipple(gl.funcs, C.GLint(factor), C.GLushort(pattern))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLightModeliv.xml
+func (gl *GL) LightModeliv(pname glbase.Enum, params []int32) {
+ C.gl1_0_glLightModeliv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLightModeli.xml
+func (gl *GL) LightModeli(pname glbase.Enum, param int32) {
+ C.gl1_0_glLightModeli(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLightModelfv.xml
+func (gl *GL) LightModelfv(pname glbase.Enum, params []float32) {
+ C.gl1_0_glLightModelfv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLightModelf.xml
+func (gl *GL) LightModelf(pname glbase.Enum, param float32) {
+ C.gl1_0_glLightModelf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLightiv.xml
+func (gl *GL) Lightiv(light, pname glbase.Enum, params []int32) {
+ C.gl1_0_glLightiv(gl.funcs, C.GLenum(light), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLighti.xml
+func (gl *GL) Lighti(light, pname glbase.Enum, param int32) {
+ C.gl1_0_glLighti(gl.funcs, C.GLenum(light), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLightfv.xml
+func (gl *GL) Lightfv(light, pname glbase.Enum, params []float32) {
+ C.gl1_0_glLightfv(gl.funcs, C.GLenum(light), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLightf.xml
+func (gl *GL) Lightf(light, pname glbase.Enum, param float32) {
+ C.gl1_0_glLightf(gl.funcs, C.GLenum(light), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFogiv.xml
+func (gl *GL) Fogiv(pname glbase.Enum, params []int32) {
+ C.gl1_0_glFogiv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFogi.xml
+func (gl *GL) Fogi(pname glbase.Enum, param int32) {
+ C.gl1_0_glFogi(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFogfv.xml
+func (gl *GL) Fogfv(pname glbase.Enum, params []float32) {
+ C.gl1_0_glFogfv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFogf.xml
+func (gl *GL) Fogf(pname glbase.Enum, param float32) {
+ C.gl1_0_glFogf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColorMaterial.xml
+func (gl *GL) ColorMaterial(face, mode glbase.Enum) {
+ C.gl1_0_glColorMaterial(gl.funcs, C.GLenum(face), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClipPlane.xml
+func (gl *GL) ClipPlane(plane glbase.Enum, equation []float64) {
+ C.gl1_0_glClipPlane(gl.funcs, C.GLenum(plane), (*C.GLdouble)(unsafe.Pointer(&equation[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4sv.xml
+func (gl *GL) Vertex4sv(v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_0_glVertex4sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4s.xml
+func (gl *GL) Vertex4s(x, y, z, w int16) {
+ C.gl1_0_glVertex4s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z), C.GLshort(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4iv.xml
+func (gl *GL) Vertex4iv(v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_0_glVertex4iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4i.xml
+func (gl *GL) Vertex4i(x, y, z, w int) {
+ C.gl1_0_glVertex4i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z), C.GLint(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4fv.xml
+func (gl *GL) Vertex4fv(v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_0_glVertex4fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4f.xml
+func (gl *GL) Vertex4f(x, y, z, w float32) {
+ C.gl1_0_glVertex4f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z), C.GLfloat(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4dv.xml
+func (gl *GL) Vertex4dv(v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_0_glVertex4dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4d.xml
+func (gl *GL) Vertex4d(x, y, z, w float64) {
+ C.gl1_0_glVertex4d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z), C.GLdouble(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3sv.xml
+func (gl *GL) Vertex3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_0_glVertex3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3s.xml
+func (gl *GL) Vertex3s(x, y, z int16) {
+ C.gl1_0_glVertex3s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3iv.xml
+func (gl *GL) Vertex3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_0_glVertex3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3i.xml
+func (gl *GL) Vertex3i(x, y, z int) {
+ C.gl1_0_glVertex3i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3fv.xml
+func (gl *GL) Vertex3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_0_glVertex3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3f.xml
+func (gl *GL) Vertex3f(x, y, z float32) {
+ C.gl1_0_glVertex3f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3dv.xml
+func (gl *GL) Vertex3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_0_glVertex3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3d.xml
+func (gl *GL) Vertex3d(x, y, z float64) {
+ C.gl1_0_glVertex3d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2sv.xml
+func (gl *GL) Vertex2sv(v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_0_glVertex2sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2s.xml
+func (gl *GL) Vertex2s(x, y int16) {
+ C.gl1_0_glVertex2s(gl.funcs, C.GLshort(x), C.GLshort(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2iv.xml
+func (gl *GL) Vertex2iv(v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_0_glVertex2iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2i.xml
+func (gl *GL) Vertex2i(x, y int) {
+ C.gl1_0_glVertex2i(gl.funcs, C.GLint(x), C.GLint(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2fv.xml
+func (gl *GL) Vertex2fv(v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_0_glVertex2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2f.xml
+func (gl *GL) Vertex2f(x, y float32) {
+ C.gl1_0_glVertex2f(gl.funcs, C.GLfloat(x), C.GLfloat(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2dv.xml
+func (gl *GL) Vertex2dv(v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_0_glVertex2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2d.xml
+func (gl *GL) Vertex2d(x, y float64) {
+ C.gl1_0_glVertex2d(gl.funcs, C.GLdouble(x), C.GLdouble(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4sv.xml
+func (gl *GL) TexCoord4sv(v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_0_glTexCoord4sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4s.xml
+func (gl *GL) TexCoord4s(s, t, r, q int16) {
+ C.gl1_0_glTexCoord4s(gl.funcs, C.GLshort(s), C.GLshort(t), C.GLshort(r), C.GLshort(q))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4iv.xml
+func (gl *GL) TexCoord4iv(v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_0_glTexCoord4iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4i.xml
+func (gl *GL) TexCoord4i(s, t, r, q int32) {
+ C.gl1_0_glTexCoord4i(gl.funcs, C.GLint(s), C.GLint(t), C.GLint(r), C.GLint(q))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4fv.xml
+func (gl *GL) TexCoord4fv(v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_0_glTexCoord4fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4f.xml
+func (gl *GL) TexCoord4f(s, t, r, q float32) {
+ C.gl1_0_glTexCoord4f(gl.funcs, C.GLfloat(s), C.GLfloat(t), C.GLfloat(r), C.GLfloat(q))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4dv.xml
+func (gl *GL) TexCoord4dv(v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_0_glTexCoord4dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4d.xml
+func (gl *GL) TexCoord4d(s, t, r, q float64) {
+ C.gl1_0_glTexCoord4d(gl.funcs, C.GLdouble(s), C.GLdouble(t), C.GLdouble(r), C.GLdouble(q))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3sv.xml
+func (gl *GL) TexCoord3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_0_glTexCoord3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3s.xml
+func (gl *GL) TexCoord3s(s, t, r int16) {
+ C.gl1_0_glTexCoord3s(gl.funcs, C.GLshort(s), C.GLshort(t), C.GLshort(r))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3iv.xml
+func (gl *GL) TexCoord3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_0_glTexCoord3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3i.xml
+func (gl *GL) TexCoord3i(s, t, r int32) {
+ C.gl1_0_glTexCoord3i(gl.funcs, C.GLint(s), C.GLint(t), C.GLint(r))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3fv.xml
+func (gl *GL) TexCoord3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_0_glTexCoord3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3f.xml
+func (gl *GL) TexCoord3f(s, t, r float32) {
+ C.gl1_0_glTexCoord3f(gl.funcs, C.GLfloat(s), C.GLfloat(t), C.GLfloat(r))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3dv.xml
+func (gl *GL) TexCoord3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_0_glTexCoord3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3d.xml
+func (gl *GL) TexCoord3d(s, t, r float64) {
+ C.gl1_0_glTexCoord3d(gl.funcs, C.GLdouble(s), C.GLdouble(t), C.GLdouble(r))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2sv.xml
+func (gl *GL) TexCoord2sv(v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_0_glTexCoord2sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2s.xml
+func (gl *GL) TexCoord2s(s, t int16) {
+ C.gl1_0_glTexCoord2s(gl.funcs, C.GLshort(s), C.GLshort(t))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2iv.xml
+func (gl *GL) TexCoord2iv(v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_0_glTexCoord2iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2i.xml
+func (gl *GL) TexCoord2i(s, t int32) {
+ C.gl1_0_glTexCoord2i(gl.funcs, C.GLint(s), C.GLint(t))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2fv.xml
+func (gl *GL) TexCoord2fv(v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_0_glTexCoord2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2f.xml
+func (gl *GL) TexCoord2f(s, t float32) {
+ C.gl1_0_glTexCoord2f(gl.funcs, C.GLfloat(s), C.GLfloat(t))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2dv.xml
+func (gl *GL) TexCoord2dv(v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_0_glTexCoord2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2d.xml
+func (gl *GL) TexCoord2d(s, t float64) {
+ C.gl1_0_glTexCoord2d(gl.funcs, C.GLdouble(s), C.GLdouble(t))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1sv.xml
+func (gl *GL) TexCoord1sv(v []int16) {
+ C.gl1_0_glTexCoord1sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1s.xml
+func (gl *GL) TexCoord1s(s int16) {
+ C.gl1_0_glTexCoord1s(gl.funcs, C.GLshort(s))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1iv.xml
+func (gl *GL) TexCoord1iv(v []int32) {
+ C.gl1_0_glTexCoord1iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1i.xml
+func (gl *GL) TexCoord1i(s int32) {
+ C.gl1_0_glTexCoord1i(gl.funcs, C.GLint(s))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1fv.xml
+func (gl *GL) TexCoord1fv(v []float32) {
+ C.gl1_0_glTexCoord1fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1f.xml
+func (gl *GL) TexCoord1f(s float32) {
+ C.gl1_0_glTexCoord1f(gl.funcs, C.GLfloat(s))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1dv.xml
+func (gl *GL) TexCoord1dv(v []float64) {
+ C.gl1_0_glTexCoord1dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1d.xml
+func (gl *GL) TexCoord1d(s float64) {
+ C.gl1_0_glTexCoord1d(gl.funcs, C.GLdouble(s))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRectsv.xml
+func (gl *GL) Rectsv(v1, v2 []int16) {
+ C.gl1_0_glRectsv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v1[0])), (*C.GLshort)(unsafe.Pointer(&v2[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRects.xml
+func (gl *GL) Rects(x1, y1, x2, y2 int16) {
+ C.gl1_0_glRects(gl.funcs, C.GLshort(x1), C.GLshort(y1), C.GLshort(x2), C.GLshort(y2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRectiv.xml
+func (gl *GL) Rectiv(v1, v2 []int32) {
+ C.gl1_0_glRectiv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v1[0])), (*C.GLint)(unsafe.Pointer(&v2[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRecti.xml
+func (gl *GL) Recti(x1, y1, x2, y2 int32) {
+ C.gl1_0_glRecti(gl.funcs, C.GLint(x1), C.GLint(y1), C.GLint(x2), C.GLint(y2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRectfv.xml
+func (gl *GL) Rectfv(v1, v2 []float32) {
+ C.gl1_0_glRectfv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v1[0])), (*C.GLfloat)(unsafe.Pointer(&v2[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRectf.xml
+func (gl *GL) Rectf(x1, y1, x2, y2 float32) {
+ C.gl1_0_glRectf(gl.funcs, C.GLfloat(x1), C.GLfloat(y1), C.GLfloat(x2), C.GLfloat(y2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRectdv.xml
+func (gl *GL) Rectdv(v1, v2 []float64) {
+ C.gl1_0_glRectdv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v1[0])), (*C.GLdouble)(unsafe.Pointer(&v2[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRectd.xml
+func (gl *GL) Rectd(x1, y1, x2, y2 float64) {
+ C.gl1_0_glRectd(gl.funcs, C.GLdouble(x1), C.GLdouble(y1), C.GLdouble(x2), C.GLdouble(y2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4sv.xml
+func (gl *GL) RasterPos4sv(v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_0_glRasterPos4sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4s.xml
+func (gl *GL) RasterPos4s(x, y, z, w int16) {
+ C.gl1_0_glRasterPos4s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z), C.GLshort(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4iv.xml
+func (gl *GL) RasterPos4iv(v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_0_glRasterPos4iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4i.xml
+func (gl *GL) RasterPos4i(x, y, z, w int) {
+ C.gl1_0_glRasterPos4i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z), C.GLint(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4fv.xml
+func (gl *GL) RasterPos4fv(v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_0_glRasterPos4fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4f.xml
+func (gl *GL) RasterPos4f(x, y, z, w float32) {
+ C.gl1_0_glRasterPos4f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z), C.GLfloat(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4dv.xml
+func (gl *GL) RasterPos4dv(v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_0_glRasterPos4dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4d.xml
+func (gl *GL) RasterPos4d(x, y, z, w float64) {
+ C.gl1_0_glRasterPos4d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z), C.GLdouble(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3sv.xml
+func (gl *GL) RasterPos3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_0_glRasterPos3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3s.xml
+func (gl *GL) RasterPos3s(x, y, z int16) {
+ C.gl1_0_glRasterPos3s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3iv.xml
+func (gl *GL) RasterPos3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_0_glRasterPos3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3i.xml
+func (gl *GL) RasterPos3i(x, y, z int) {
+ C.gl1_0_glRasterPos3i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3fv.xml
+func (gl *GL) RasterPos3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_0_glRasterPos3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3f.xml
+func (gl *GL) RasterPos3f(x, y, z float32) {
+ C.gl1_0_glRasterPos3f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3dv.xml
+func (gl *GL) RasterPos3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_0_glRasterPos3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3d.xml
+func (gl *GL) RasterPos3d(x, y, z float64) {
+ C.gl1_0_glRasterPos3d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2sv.xml
+func (gl *GL) RasterPos2sv(v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_0_glRasterPos2sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2s.xml
+func (gl *GL) RasterPos2s(x, y int16) {
+ C.gl1_0_glRasterPos2s(gl.funcs, C.GLshort(x), C.GLshort(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2iv.xml
+func (gl *GL) RasterPos2iv(v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_0_glRasterPos2iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2i.xml
+func (gl *GL) RasterPos2i(x, y int) {
+ C.gl1_0_glRasterPos2i(gl.funcs, C.GLint(x), C.GLint(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2fv.xml
+func (gl *GL) RasterPos2fv(v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_0_glRasterPos2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2f.xml
+func (gl *GL) RasterPos2f(x, y float32) {
+ C.gl1_0_glRasterPos2f(gl.funcs, C.GLfloat(x), C.GLfloat(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2dv.xml
+func (gl *GL) RasterPos2dv(v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_0_glRasterPos2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2d.xml
+func (gl *GL) RasterPos2d(x, y float64) {
+ C.gl1_0_glRasterPos2d(gl.funcs, C.GLdouble(x), C.GLdouble(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3sv.xml
+func (gl *GL) Normal3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_0_glNormal3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3s.xml
+func (gl *GL) Normal3s(nx, ny, nz int16) {
+ C.gl1_0_glNormal3s(gl.funcs, C.GLshort(nx), C.GLshort(ny), C.GLshort(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3iv.xml
+func (gl *GL) Normal3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_0_glNormal3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3i.xml
+func (gl *GL) Normal3i(nx, ny, nz int32) {
+ C.gl1_0_glNormal3i(gl.funcs, C.GLint(nx), C.GLint(ny), C.GLint(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3fv.xml
+func (gl *GL) Normal3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_0_glNormal3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3f.xml
+func (gl *GL) Normal3f(nx, ny, nz float32) {
+ C.gl1_0_glNormal3f(gl.funcs, C.GLfloat(nx), C.GLfloat(ny), C.GLfloat(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3dv.xml
+func (gl *GL) Normal3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_0_glNormal3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3d.xml
+func (gl *GL) Normal3d(nx, ny, nz float64) {
+ C.gl1_0_glNormal3d(gl.funcs, C.GLdouble(nx), C.GLdouble(ny), C.GLdouble(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3bv.xml
+func (gl *GL) Normal3bv(v []byte) {
+ C.gl1_0_glNormal3bv(gl.funcs, (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3b.xml
+func (gl *GL) Normal3b(nx, ny, nz byte) {
+ C.gl1_0_glNormal3b(gl.funcs, C.GLbyte(nx), C.GLbyte(ny), C.GLbyte(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexsv.xml
+func (gl *GL) Indexsv(c []int16) {
+ C.gl1_0_glIndexsv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexs.xml
+func (gl *GL) Indexs(c int16) {
+ C.gl1_0_glIndexs(gl.funcs, C.GLshort(c))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexiv.xml
+func (gl *GL) Indexiv(c []int32) {
+ C.gl1_0_glIndexiv(gl.funcs, (*C.GLint)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexi.xml
+func (gl *GL) Indexi(c int32) {
+ C.gl1_0_glIndexi(gl.funcs, C.GLint(c))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexfv.xml
+func (gl *GL) Indexfv(c []float32) {
+ C.gl1_0_glIndexfv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexf.xml
+func (gl *GL) Indexf(c float32) {
+ C.gl1_0_glIndexf(gl.funcs, C.GLfloat(c))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexdv.xml
+func (gl *GL) Indexdv(c []float64) {
+ C.gl1_0_glIndexdv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexd.xml
+func (gl *GL) Indexd(c float64) {
+ C.gl1_0_glIndexd(gl.funcs, C.GLdouble(c))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEnd.xml
+func (gl *GL) End() {
+ C.gl1_0_glEnd(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEdgeFlagv.xml
+func (gl *GL) EdgeFlagv(flag []bool) {
+ C.gl1_0_glEdgeFlagv(gl.funcs, (*C.GLboolean)(unsafe.Pointer(&flag[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEdgeFlag.xml
+func (gl *GL) EdgeFlag(flag bool) {
+ C.gl1_0_glEdgeFlag(gl.funcs, *(*C.GLboolean)(unsafe.Pointer(&flag)))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4usv.xml
+func (gl *GL) Color4usv(v []uint16) {
+ C.gl1_0_glColor4usv(gl.funcs, (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4us.xml
+func (gl *GL) Color4us(red, green, blue, alpha uint16) {
+ C.gl1_0_glColor4us(gl.funcs, C.GLushort(red), C.GLushort(green), C.GLushort(blue), C.GLushort(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4uiv.xml
+func (gl *GL) Color4uiv(v []uint32) {
+ C.gl1_0_glColor4uiv(gl.funcs, (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4ui.xml
+func (gl *GL) Color4ui(red, green, blue, alpha uint32) {
+ C.gl1_0_glColor4ui(gl.funcs, C.GLuint(red), C.GLuint(green), C.GLuint(blue), C.GLuint(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4ubv.xml
+func (gl *GL) Color4ubv(v []uint8) {
+ C.gl1_0_glColor4ubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4ub.xml
+func (gl *GL) Color4ub(red, green, blue, alpha uint8) {
+ C.gl1_0_glColor4ub(gl.funcs, C.GLubyte(red), C.GLubyte(green), C.GLubyte(blue), C.GLubyte(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4sv.xml
+func (gl *GL) Color4sv(v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_0_glColor4sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4s.xml
+func (gl *GL) Color4s(red, green, blue, alpha int16) {
+ C.gl1_0_glColor4s(gl.funcs, C.GLshort(red), C.GLshort(green), C.GLshort(blue), C.GLshort(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4iv.xml
+func (gl *GL) Color4iv(v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_0_glColor4iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4i.xml
+func (gl *GL) Color4i(red, green, blue, alpha int32) {
+ C.gl1_0_glColor4i(gl.funcs, C.GLint(red), C.GLint(green), C.GLint(blue), C.GLint(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4fv.xml
+func (gl *GL) Color4fv(v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_0_glColor4fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4f.xml
+func (gl *GL) Color4f(red, green, blue, alpha float32) {
+ C.gl1_0_glColor4f(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4dv.xml
+func (gl *GL) Color4dv(v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_0_glColor4dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4d.xml
+func (gl *GL) Color4d(red, green, blue, alpha float64) {
+ C.gl1_0_glColor4d(gl.funcs, C.GLdouble(red), C.GLdouble(green), C.GLdouble(blue), C.GLdouble(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4bv.xml
+func (gl *GL) Color4bv(v []byte) {
+ C.gl1_0_glColor4bv(gl.funcs, (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4b.xml
+func (gl *GL) Color4b(red, green, blue, alpha byte) {
+ C.gl1_0_glColor4b(gl.funcs, C.GLbyte(red), C.GLbyte(green), C.GLbyte(blue), C.GLbyte(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3usv.xml
+func (gl *GL) Color3usv(v []uint16) {
+ C.gl1_0_glColor3usv(gl.funcs, (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3us.xml
+func (gl *GL) Color3us(red, green, blue uint16) {
+ C.gl1_0_glColor3us(gl.funcs, C.GLushort(red), C.GLushort(green), C.GLushort(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3uiv.xml
+func (gl *GL) Color3uiv(v []uint32) {
+ C.gl1_0_glColor3uiv(gl.funcs, (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3ui.xml
+func (gl *GL) Color3ui(red, green, blue uint32) {
+ C.gl1_0_glColor3ui(gl.funcs, C.GLuint(red), C.GLuint(green), C.GLuint(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3ubv.xml
+func (gl *GL) Color3ubv(v []uint8) {
+ C.gl1_0_glColor3ubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3ub.xml
+func (gl *GL) Color3ub(red, green, blue uint8) {
+ C.gl1_0_glColor3ub(gl.funcs, C.GLubyte(red), C.GLubyte(green), C.GLubyte(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3sv.xml
+func (gl *GL) Color3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_0_glColor3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3s.xml
+func (gl *GL) Color3s(red, green, blue int16) {
+ C.gl1_0_glColor3s(gl.funcs, C.GLshort(red), C.GLshort(green), C.GLshort(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3iv.xml
+func (gl *GL) Color3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_0_glColor3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3i.xml
+func (gl *GL) Color3i(red, green, blue int32) {
+ C.gl1_0_glColor3i(gl.funcs, C.GLint(red), C.GLint(green), C.GLint(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3fv.xml
+func (gl *GL) Color3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_0_glColor3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3f.xml
+func (gl *GL) Color3f(red, green, blue float32) {
+ C.gl1_0_glColor3f(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3dv.xml
+func (gl *GL) Color3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_0_glColor3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3d.xml
+func (gl *GL) Color3d(red, green, blue float64) {
+ C.gl1_0_glColor3d(gl.funcs, C.GLdouble(red), C.GLdouble(green), C.GLdouble(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3bv.xml
+func (gl *GL) Color3bv(v []byte) {
+ C.gl1_0_glColor3bv(gl.funcs, (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3b.xml
+func (gl *GL) Color3b(red, green, blue byte) {
+ C.gl1_0_glColor3b(gl.funcs, C.GLbyte(red), C.GLbyte(green), C.GLbyte(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBitmap.xml
+func (gl *GL) Bitmap(width, height int, xorig, yorig, xmove, ymove float32, bitmap []uint8) {
+ C.gl1_0_glBitmap(gl.funcs, C.GLsizei(width), C.GLsizei(height), C.GLfloat(xorig), C.GLfloat(yorig), C.GLfloat(xmove), C.GLfloat(ymove), (*C.GLubyte)(unsafe.Pointer(&bitmap[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBegin.xml
+func (gl *GL) Begin(mode glbase.Enum) {
+ C.gl1_0_glBegin(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glListBase.xml
+func (gl *GL) ListBase(base uint32) {
+ C.gl1_0_glListBase(gl.funcs, C.GLuint(base))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGenLists.xml
+func (gl *GL) GenLists(range_ int32) uint32 {
+ glresult := C.gl1_0_glGenLists(gl.funcs, C.GLsizei(range_))
+ return uint32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDeleteLists.xml
+func (gl *GL) DeleteLists(list uint32, range_ int32) {
+ C.gl1_0_glDeleteLists(gl.funcs, C.GLuint(list), C.GLsizei(range_))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCallLists.xml
+func (gl *GL) CallLists(n int, gltype glbase.Enum, lists interface{}) {
+ var lists_ptr unsafe.Pointer
+ var lists_v = reflect.ValueOf(lists)
+ if lists != nil && lists_v.Kind() != reflect.Slice {
+ panic("parameter lists must be a slice")
+ }
+ if lists != nil {
+ lists_ptr = unsafe.Pointer(lists_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_0_glCallLists(gl.funcs, C.GLsizei(n), C.GLenum(gltype), lists_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCallList.xml
+func (gl *GL) CallList(list uint32) {
+ C.gl1_0_glCallList(gl.funcs, C.GLuint(list))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEndList.xml
+func (gl *GL) EndList() {
+ C.gl1_0_glEndList(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNewList.xml
+func (gl *GL) NewList(list uint32, mode glbase.Enum) {
+ C.gl1_0_glNewList(gl.funcs, C.GLuint(list), C.GLenum(mode))
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/1.1/funcs.cpp b/Godeps/_workspace/src/github.com/obscuren/qml/gl/1.1/funcs.cpp
new file mode 100644
index 000000000..1c0f0adbd
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/1.1/funcs.cpp
@@ -0,0 +1,2022 @@
+
+// ** file automatically generated by glgen -- do not edit manually **
+
+#include <QOpenGLContext>
+#include <QtGui/qopenglfunctions_1_1.h>
+
+#include "funcs.h"
+
+void *gl1_1_funcs() {
+ QOpenGLFunctions_1_1* funcs = QOpenGLContext::currentContext()->versionFunctions<QOpenGLFunctions_1_1>();
+ if (!funcs) {
+ return 0;
+ }
+ funcs->initializeOpenGLFunctions();
+ return funcs;
+}
+
+
+void gl1_1_glViewport(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glViewport(x, y, width, height);
+}
+
+void gl1_1_glDepthRange(void *_glfuncs, GLdouble nearVal, GLdouble farVal)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glDepthRange(nearVal, farVal);
+}
+
+GLboolean gl1_1_glIsEnabled(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ return _qglfuncs->glIsEnabled(cap);
+}
+
+void gl1_1_glGetTexLevelParameteriv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glGetTexLevelParameteriv(target, level, pname, params);
+}
+
+void gl1_1_glGetTexLevelParameterfv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glGetTexLevelParameterfv(target, level, pname, params);
+}
+
+void gl1_1_glGetTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glGetTexParameteriv(target, pname, params);
+}
+
+void gl1_1_glGetTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glGetTexParameterfv(target, pname, params);
+}
+
+void gl1_1_glGetTexImage(void *_glfuncs, GLenum target, GLint level, GLenum format, GLenum gltype, GLvoid* pixels)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glGetTexImage(target, level, format, gltype, pixels);
+}
+
+void gl1_1_glGetIntegerv(void *_glfuncs, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glGetIntegerv(pname, params);
+}
+
+void gl1_1_glGetFloatv(void *_glfuncs, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glGetFloatv(pname, params);
+}
+
+GLenum gl1_1_glGetError(void *_glfuncs)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ return _qglfuncs->glGetError();
+}
+
+void gl1_1_glGetDoublev(void *_glfuncs, GLenum pname, GLdouble* params)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glGetDoublev(pname, params);
+}
+
+void gl1_1_glGetBooleanv(void *_glfuncs, GLenum pname, GLboolean* params)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glGetBooleanv(pname, params);
+}
+
+void gl1_1_glReadPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum gltype, GLvoid* pixels)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glReadPixels(x, y, width, height, format, gltype, pixels);
+}
+
+void gl1_1_glReadBuffer(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glReadBuffer(mode);
+}
+
+void gl1_1_glPixelStorei(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glPixelStorei(pname, param);
+}
+
+void gl1_1_glPixelStoref(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glPixelStoref(pname, param);
+}
+
+void gl1_1_glDepthFunc(void *_glfuncs, GLenum glfunc)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glDepthFunc(glfunc);
+}
+
+void gl1_1_glStencilOp(void *_glfuncs, GLenum fail, GLenum zfail, GLenum zpass)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glStencilOp(fail, zfail, zpass);
+}
+
+void gl1_1_glStencilFunc(void *_glfuncs, GLenum glfunc, GLint ref, GLuint mask)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glStencilFunc(glfunc, ref, mask);
+}
+
+void gl1_1_glLogicOp(void *_glfuncs, GLenum opcode)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glLogicOp(opcode);
+}
+
+void gl1_1_glBlendFunc(void *_glfuncs, GLenum sfactor, GLenum dfactor)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glBlendFunc(sfactor, dfactor);
+}
+
+void gl1_1_glFlush(void *_glfuncs)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glFlush();
+}
+
+void gl1_1_glFinish(void *_glfuncs)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glFinish();
+}
+
+void gl1_1_glEnable(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glEnable(cap);
+}
+
+void gl1_1_glDisable(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glDisable(cap);
+}
+
+void gl1_1_glDepthMask(void *_glfuncs, GLboolean flag)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glDepthMask(flag);
+}
+
+void gl1_1_glColorMask(void *_glfuncs, GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glColorMask(red, green, blue, alpha);
+}
+
+void gl1_1_glStencilMask(void *_glfuncs, GLuint mask)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glStencilMask(mask);
+}
+
+void gl1_1_glClearDepth(void *_glfuncs, GLdouble depth)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glClearDepth(depth);
+}
+
+void gl1_1_glClearStencil(void *_glfuncs, GLint s)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glClearStencil(s);
+}
+
+void gl1_1_glClearColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glClearColor(red, green, blue, alpha);
+}
+
+void gl1_1_glClear(void *_glfuncs, GLbitfield mask)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glClear(mask);
+}
+
+void gl1_1_glDrawBuffer(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glDrawBuffer(mode);
+}
+
+void gl1_1_glTexImage2D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glTexImage2D(target, level, internalFormat, width, height, border, format, gltype, pixels);
+}
+
+void gl1_1_glTexImage1D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glTexImage1D(target, level, internalFormat, width, border, format, gltype, pixels);
+}
+
+void gl1_1_glTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glTexParameteriv(target, pname, params);
+}
+
+void gl1_1_glTexParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glTexParameteri(target, pname, param);
+}
+
+void gl1_1_glTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glTexParameterfv(target, pname, params);
+}
+
+void gl1_1_glTexParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glTexParameterf(target, pname, param);
+}
+
+void gl1_1_glScissor(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glScissor(x, y, width, height);
+}
+
+void gl1_1_glPolygonMode(void *_glfuncs, GLenum face, GLenum mode)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glPolygonMode(face, mode);
+}
+
+void gl1_1_glPointSize(void *_glfuncs, GLfloat size)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glPointSize(size);
+}
+
+void gl1_1_glLineWidth(void *_glfuncs, GLfloat width)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glLineWidth(width);
+}
+
+void gl1_1_glHint(void *_glfuncs, GLenum target, GLenum mode)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glHint(target, mode);
+}
+
+void gl1_1_glFrontFace(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glFrontFace(mode);
+}
+
+void gl1_1_glCullFace(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glCullFace(mode);
+}
+
+void gl1_1_glIndexubv(void *_glfuncs, const GLubyte* c)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glIndexubv(c);
+}
+
+void gl1_1_glIndexub(void *_glfuncs, GLubyte c)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glIndexub(c);
+}
+
+GLboolean gl1_1_glIsTexture(void *_glfuncs, GLuint texture)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ return _qglfuncs->glIsTexture(texture);
+}
+
+void gl1_1_glGenTextures(void *_glfuncs, GLsizei n, GLuint* textures)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glGenTextures(n, textures);
+}
+
+void gl1_1_glDeleteTextures(void *_glfuncs, GLsizei n, const GLuint* textures)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glDeleteTextures(n, textures);
+}
+
+void gl1_1_glBindTexture(void *_glfuncs, GLenum target, GLuint texture)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glBindTexture(target, texture);
+}
+
+void gl1_1_glTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glTexSubImage2D(target, level, xoffset, yoffset, width, height, format, gltype, pixels);
+}
+
+void gl1_1_glTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glTexSubImage1D(target, level, xoffset, width, format, gltype, pixels);
+}
+
+void gl1_1_glCopyTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage2D(target, level, xoffset, yoffset, x, y, width, height);
+}
+
+void gl1_1_glCopyTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage1D(target, level, xoffset, x, y, width);
+}
+
+void gl1_1_glCopyTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glCopyTexImage2D(target, level, internalFormat, x, y, width, height, border);
+}
+
+void gl1_1_glCopyTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLint border)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glCopyTexImage1D(target, level, internalFormat, x, y, width, border);
+}
+
+void gl1_1_glPolygonOffset(void *_glfuncs, GLfloat factor, GLfloat units)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glPolygonOffset(factor, units);
+}
+
+void gl1_1_glDrawElements(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glDrawElements(mode, count, gltype, indices);
+}
+
+void gl1_1_glDrawArrays(void *_glfuncs, GLenum mode, GLint first, GLsizei count)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glDrawArrays(mode, first, count);
+}
+
+void gl1_1_glTranslatef(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glTranslatef(x, y, z);
+}
+
+void gl1_1_glTranslated(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glTranslated(x, y, z);
+}
+
+void gl1_1_glScalef(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glScalef(x, y, z);
+}
+
+void gl1_1_glScaled(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glScaled(x, y, z);
+}
+
+void gl1_1_glRotatef(void *_glfuncs, GLfloat angle, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glRotatef(angle, x, y, z);
+}
+
+void gl1_1_glRotated(void *_glfuncs, GLdouble angle, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glRotated(angle, x, y, z);
+}
+
+void gl1_1_glPushMatrix(void *_glfuncs)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glPushMatrix();
+}
+
+void gl1_1_glPopMatrix(void *_glfuncs)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glPopMatrix();
+}
+
+void gl1_1_glOrtho(void *_glfuncs, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glOrtho(left, right, bottom, top, zNear, zFar);
+}
+
+void gl1_1_glMultMatrixd(void *_glfuncs, const GLdouble* m)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glMultMatrixd(m);
+}
+
+void gl1_1_glMultMatrixf(void *_glfuncs, const GLfloat* m)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glMultMatrixf(m);
+}
+
+void gl1_1_glMatrixMode(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glMatrixMode(mode);
+}
+
+void gl1_1_glLoadMatrixd(void *_glfuncs, const GLdouble* m)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glLoadMatrixd(m);
+}
+
+void gl1_1_glLoadMatrixf(void *_glfuncs, const GLfloat* m)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glLoadMatrixf(m);
+}
+
+void gl1_1_glLoadIdentity(void *_glfuncs)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glLoadIdentity();
+}
+
+void gl1_1_glFrustum(void *_glfuncs, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glFrustum(left, right, bottom, top, zNear, zFar);
+}
+
+GLboolean gl1_1_glIsList(void *_glfuncs, GLuint list)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ return _qglfuncs->glIsList(list);
+}
+
+void gl1_1_glGetTexGeniv(void *_glfuncs, GLenum coord, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glGetTexGeniv(coord, pname, params);
+}
+
+void gl1_1_glGetTexGenfv(void *_glfuncs, GLenum coord, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glGetTexGenfv(coord, pname, params);
+}
+
+void gl1_1_glGetTexGendv(void *_glfuncs, GLenum coord, GLenum pname, GLdouble* params)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glGetTexGendv(coord, pname, params);
+}
+
+void gl1_1_glGetTexEnviv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glGetTexEnviv(target, pname, params);
+}
+
+void gl1_1_glGetTexEnvfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glGetTexEnvfv(target, pname, params);
+}
+
+void gl1_1_glGetPolygonStipple(void *_glfuncs, GLubyte* mask)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glGetPolygonStipple(mask);
+}
+
+void gl1_1_glGetPixelMapusv(void *_glfuncs, GLenum glmap, GLushort* values)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glGetPixelMapusv(glmap, values);
+}
+
+void gl1_1_glGetPixelMapuiv(void *_glfuncs, GLenum glmap, GLuint* values)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glGetPixelMapuiv(glmap, values);
+}
+
+void gl1_1_glGetPixelMapfv(void *_glfuncs, GLenum glmap, GLfloat* values)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glGetPixelMapfv(glmap, values);
+}
+
+void gl1_1_glGetMaterialiv(void *_glfuncs, GLenum face, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glGetMaterialiv(face, pname, params);
+}
+
+void gl1_1_glGetMaterialfv(void *_glfuncs, GLenum face, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glGetMaterialfv(face, pname, params);
+}
+
+void gl1_1_glGetMapiv(void *_glfuncs, GLenum target, GLenum query, GLint* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glGetMapiv(target, query, v);
+}
+
+void gl1_1_glGetMapfv(void *_glfuncs, GLenum target, GLenum query, GLfloat* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glGetMapfv(target, query, v);
+}
+
+void gl1_1_glGetMapdv(void *_glfuncs, GLenum target, GLenum query, GLdouble* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glGetMapdv(target, query, v);
+}
+
+void gl1_1_glGetLightiv(void *_glfuncs, GLenum light, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glGetLightiv(light, pname, params);
+}
+
+void gl1_1_glGetLightfv(void *_glfuncs, GLenum light, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glGetLightfv(light, pname, params);
+}
+
+void gl1_1_glGetClipPlane(void *_glfuncs, GLenum plane, GLdouble* equation)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glGetClipPlane(plane, equation);
+}
+
+void gl1_1_glDrawPixels(void *_glfuncs, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glDrawPixels(width, height, format, gltype, pixels);
+}
+
+void gl1_1_glCopyPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum gltype)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glCopyPixels(x, y, width, height, gltype);
+}
+
+void gl1_1_glPixelMapusv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLushort* values)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glPixelMapusv(glmap, mapsize, values);
+}
+
+void gl1_1_glPixelMapuiv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLuint* values)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glPixelMapuiv(glmap, mapsize, values);
+}
+
+void gl1_1_glPixelMapfv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLfloat* values)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glPixelMapfv(glmap, mapsize, values);
+}
+
+void gl1_1_glPixelTransferi(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glPixelTransferi(pname, param);
+}
+
+void gl1_1_glPixelTransferf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glPixelTransferf(pname, param);
+}
+
+void gl1_1_glPixelZoom(void *_glfuncs, GLfloat xfactor, GLfloat yfactor)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glPixelZoom(xfactor, yfactor);
+}
+
+void gl1_1_glAlphaFunc(void *_glfuncs, GLenum glfunc, GLfloat ref)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glAlphaFunc(glfunc, ref);
+}
+
+void gl1_1_glEvalPoint2(void *_glfuncs, GLint i, GLint j)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glEvalPoint2(i, j);
+}
+
+void gl1_1_glEvalMesh2(void *_glfuncs, GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glEvalMesh2(mode, i1, i2, j1, j2);
+}
+
+void gl1_1_glEvalPoint1(void *_glfuncs, GLint i)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glEvalPoint1(i);
+}
+
+void gl1_1_glEvalMesh1(void *_glfuncs, GLenum mode, GLint i1, GLint i2)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glEvalMesh1(mode, i1, i2);
+}
+
+void gl1_1_glEvalCoord2fv(void *_glfuncs, const GLfloat* u)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glEvalCoord2fv(u);
+}
+
+void gl1_1_glEvalCoord2f(void *_glfuncs, GLfloat u, GLfloat v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glEvalCoord2f(u, v);
+}
+
+void gl1_1_glEvalCoord2dv(void *_glfuncs, const GLdouble* u)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glEvalCoord2dv(u);
+}
+
+void gl1_1_glEvalCoord2d(void *_glfuncs, GLdouble u, GLdouble v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glEvalCoord2d(u, v);
+}
+
+void gl1_1_glEvalCoord1fv(void *_glfuncs, const GLfloat* u)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glEvalCoord1fv(u);
+}
+
+void gl1_1_glEvalCoord1f(void *_glfuncs, GLfloat u)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glEvalCoord1f(u);
+}
+
+void gl1_1_glEvalCoord1dv(void *_glfuncs, const GLdouble* u)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glEvalCoord1dv(u);
+}
+
+void gl1_1_glEvalCoord1d(void *_glfuncs, GLdouble u)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glEvalCoord1d(u);
+}
+
+void gl1_1_glMapGrid2f(void *_glfuncs, GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glMapGrid2f(un, u1, u2, vn, v1, v2);
+}
+
+void gl1_1_glMapGrid2d(void *_glfuncs, GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glMapGrid2d(un, u1, u2, vn, v1, v2);
+}
+
+void gl1_1_glMapGrid1f(void *_glfuncs, GLint un, GLfloat u1, GLfloat u2)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glMapGrid1f(un, u1, u2);
+}
+
+void gl1_1_glMapGrid1d(void *_glfuncs, GLint un, GLdouble u1, GLdouble u2)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glMapGrid1d(un, u1, u2);
+}
+
+void gl1_1_glMap2f(void *_glfuncs, GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat* points)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glMap2f(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+void gl1_1_glMap2d(void *_glfuncs, GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble* points)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glMap2d(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+void gl1_1_glMap1f(void *_glfuncs, GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat* points)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glMap1f(target, u1, u2, stride, order, points);
+}
+
+void gl1_1_glMap1d(void *_glfuncs, GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble* points)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glMap1d(target, u1, u2, stride, order, points);
+}
+
+void gl1_1_glPushAttrib(void *_glfuncs, GLbitfield mask)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glPushAttrib(mask);
+}
+
+void gl1_1_glPopAttrib(void *_glfuncs)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glPopAttrib();
+}
+
+void gl1_1_glAccum(void *_glfuncs, GLenum op, GLfloat value)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glAccum(op, value);
+}
+
+void gl1_1_glIndexMask(void *_glfuncs, GLuint mask)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glIndexMask(mask);
+}
+
+void gl1_1_glClearIndex(void *_glfuncs, GLfloat c)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glClearIndex(c);
+}
+
+void gl1_1_glClearAccum(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glClearAccum(red, green, blue, alpha);
+}
+
+void gl1_1_glPushName(void *_glfuncs, GLuint name)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glPushName(name);
+}
+
+void gl1_1_glPopName(void *_glfuncs)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glPopName();
+}
+
+void gl1_1_glPassThrough(void *_glfuncs, GLfloat token)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glPassThrough(token);
+}
+
+void gl1_1_glLoadName(void *_glfuncs, GLuint name)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glLoadName(name);
+}
+
+void gl1_1_glInitNames(void *_glfuncs)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glInitNames();
+}
+
+GLint gl1_1_glRenderMode(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ return _qglfuncs->glRenderMode(mode);
+}
+
+void gl1_1_glSelectBuffer(void *_glfuncs, GLsizei size, GLuint* buffer)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glSelectBuffer(size, buffer);
+}
+
+void gl1_1_glFeedbackBuffer(void *_glfuncs, GLsizei size, GLenum gltype, GLfloat* buffer)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glFeedbackBuffer(size, gltype, buffer);
+}
+
+void gl1_1_glTexGeniv(void *_glfuncs, GLenum coord, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glTexGeniv(coord, pname, params);
+}
+
+void gl1_1_glTexGeni(void *_glfuncs, GLenum coord, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glTexGeni(coord, pname, param);
+}
+
+void gl1_1_glTexGenfv(void *_glfuncs, GLenum coord, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glTexGenfv(coord, pname, params);
+}
+
+void gl1_1_glTexGenf(void *_glfuncs, GLenum coord, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glTexGenf(coord, pname, param);
+}
+
+void gl1_1_glTexGendv(void *_glfuncs, GLenum coord, GLenum pname, const GLdouble* params)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glTexGendv(coord, pname, params);
+}
+
+void gl1_1_glTexGend(void *_glfuncs, GLenum coord, GLenum pname, GLdouble param)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glTexGend(coord, pname, param);
+}
+
+void gl1_1_glTexEnviv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glTexEnviv(target, pname, params);
+}
+
+void gl1_1_glTexEnvi(void *_glfuncs, GLenum target, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glTexEnvi(target, pname, param);
+}
+
+void gl1_1_glTexEnvfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glTexEnvfv(target, pname, params);
+}
+
+void gl1_1_glTexEnvf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glTexEnvf(target, pname, param);
+}
+
+void gl1_1_glShadeModel(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glShadeModel(mode);
+}
+
+void gl1_1_glPolygonStipple(void *_glfuncs, const GLubyte* mask)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glPolygonStipple(mask);
+}
+
+void gl1_1_glMaterialiv(void *_glfuncs, GLenum face, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glMaterialiv(face, pname, params);
+}
+
+void gl1_1_glMateriali(void *_glfuncs, GLenum face, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glMateriali(face, pname, param);
+}
+
+void gl1_1_glMaterialfv(void *_glfuncs, GLenum face, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glMaterialfv(face, pname, params);
+}
+
+void gl1_1_glMaterialf(void *_glfuncs, GLenum face, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glMaterialf(face, pname, param);
+}
+
+void gl1_1_glLineStipple(void *_glfuncs, GLint factor, GLushort pattern)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glLineStipple(factor, pattern);
+}
+
+void gl1_1_glLightModeliv(void *_glfuncs, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glLightModeliv(pname, params);
+}
+
+void gl1_1_glLightModeli(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glLightModeli(pname, param);
+}
+
+void gl1_1_glLightModelfv(void *_glfuncs, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glLightModelfv(pname, params);
+}
+
+void gl1_1_glLightModelf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glLightModelf(pname, param);
+}
+
+void gl1_1_glLightiv(void *_glfuncs, GLenum light, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glLightiv(light, pname, params);
+}
+
+void gl1_1_glLighti(void *_glfuncs, GLenum light, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glLighti(light, pname, param);
+}
+
+void gl1_1_glLightfv(void *_glfuncs, GLenum light, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glLightfv(light, pname, params);
+}
+
+void gl1_1_glLightf(void *_glfuncs, GLenum light, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glLightf(light, pname, param);
+}
+
+void gl1_1_glFogiv(void *_glfuncs, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glFogiv(pname, params);
+}
+
+void gl1_1_glFogi(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glFogi(pname, param);
+}
+
+void gl1_1_glFogfv(void *_glfuncs, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glFogfv(pname, params);
+}
+
+void gl1_1_glFogf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glFogf(pname, param);
+}
+
+void gl1_1_glColorMaterial(void *_glfuncs, GLenum face, GLenum mode)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glColorMaterial(face, mode);
+}
+
+void gl1_1_glClipPlane(void *_glfuncs, GLenum plane, const GLdouble* equation)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glClipPlane(plane, equation);
+}
+
+void gl1_1_glVertex4sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glVertex4sv(v);
+}
+
+void gl1_1_glVertex4s(void *_glfuncs, GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glVertex4s(x, y, z, w);
+}
+
+void gl1_1_glVertex4iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glVertex4iv(v);
+}
+
+void gl1_1_glVertex4i(void *_glfuncs, GLint x, GLint y, GLint z, GLint w)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glVertex4i(x, y, z, w);
+}
+
+void gl1_1_glVertex4fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glVertex4fv(v);
+}
+
+void gl1_1_glVertex4f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glVertex4f(x, y, z, w);
+}
+
+void gl1_1_glVertex4dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glVertex4dv(v);
+}
+
+void gl1_1_glVertex4d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glVertex4d(x, y, z, w);
+}
+
+void gl1_1_glVertex3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glVertex3sv(v);
+}
+
+void gl1_1_glVertex3s(void *_glfuncs, GLshort x, GLshort y, GLshort z)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glVertex3s(x, y, z);
+}
+
+void gl1_1_glVertex3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glVertex3iv(v);
+}
+
+void gl1_1_glVertex3i(void *_glfuncs, GLint x, GLint y, GLint z)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glVertex3i(x, y, z);
+}
+
+void gl1_1_glVertex3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glVertex3fv(v);
+}
+
+void gl1_1_glVertex3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glVertex3f(x, y, z);
+}
+
+void gl1_1_glVertex3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glVertex3dv(v);
+}
+
+void gl1_1_glVertex3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glVertex3d(x, y, z);
+}
+
+void gl1_1_glVertex2sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glVertex2sv(v);
+}
+
+void gl1_1_glVertex2s(void *_glfuncs, GLshort x, GLshort y)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glVertex2s(x, y);
+}
+
+void gl1_1_glVertex2iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glVertex2iv(v);
+}
+
+void gl1_1_glVertex2i(void *_glfuncs, GLint x, GLint y)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glVertex2i(x, y);
+}
+
+void gl1_1_glVertex2fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glVertex2fv(v);
+}
+
+void gl1_1_glVertex2f(void *_glfuncs, GLfloat x, GLfloat y)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glVertex2f(x, y);
+}
+
+void gl1_1_glVertex2dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glVertex2dv(v);
+}
+
+void gl1_1_glVertex2d(void *_glfuncs, GLdouble x, GLdouble y)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glVertex2d(x, y);
+}
+
+void gl1_1_glTexCoord4sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glTexCoord4sv(v);
+}
+
+void gl1_1_glTexCoord4s(void *_glfuncs, GLshort s, GLshort t, GLshort r, GLshort q)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glTexCoord4s(s, t, r, q);
+}
+
+void gl1_1_glTexCoord4iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glTexCoord4iv(v);
+}
+
+void gl1_1_glTexCoord4i(void *_glfuncs, GLint s, GLint t, GLint r, GLint q)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glTexCoord4i(s, t, r, q);
+}
+
+void gl1_1_glTexCoord4fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glTexCoord4fv(v);
+}
+
+void gl1_1_glTexCoord4f(void *_glfuncs, GLfloat s, GLfloat t, GLfloat r, GLfloat q)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glTexCoord4f(s, t, r, q);
+}
+
+void gl1_1_glTexCoord4dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glTexCoord4dv(v);
+}
+
+void gl1_1_glTexCoord4d(void *_glfuncs, GLdouble s, GLdouble t, GLdouble r, GLdouble q)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glTexCoord4d(s, t, r, q);
+}
+
+void gl1_1_glTexCoord3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glTexCoord3sv(v);
+}
+
+void gl1_1_glTexCoord3s(void *_glfuncs, GLshort s, GLshort t, GLshort r)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glTexCoord3s(s, t, r);
+}
+
+void gl1_1_glTexCoord3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glTexCoord3iv(v);
+}
+
+void gl1_1_glTexCoord3i(void *_glfuncs, GLint s, GLint t, GLint r)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glTexCoord3i(s, t, r);
+}
+
+void gl1_1_glTexCoord3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glTexCoord3fv(v);
+}
+
+void gl1_1_glTexCoord3f(void *_glfuncs, GLfloat s, GLfloat t, GLfloat r)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glTexCoord3f(s, t, r);
+}
+
+void gl1_1_glTexCoord3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glTexCoord3dv(v);
+}
+
+void gl1_1_glTexCoord3d(void *_glfuncs, GLdouble s, GLdouble t, GLdouble r)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glTexCoord3d(s, t, r);
+}
+
+void gl1_1_glTexCoord2sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glTexCoord2sv(v);
+}
+
+void gl1_1_glTexCoord2s(void *_glfuncs, GLshort s, GLshort t)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glTexCoord2s(s, t);
+}
+
+void gl1_1_glTexCoord2iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glTexCoord2iv(v);
+}
+
+void gl1_1_glTexCoord2i(void *_glfuncs, GLint s, GLint t)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glTexCoord2i(s, t);
+}
+
+void gl1_1_glTexCoord2fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glTexCoord2fv(v);
+}
+
+void gl1_1_glTexCoord2f(void *_glfuncs, GLfloat s, GLfloat t)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glTexCoord2f(s, t);
+}
+
+void gl1_1_glTexCoord2dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glTexCoord2dv(v);
+}
+
+void gl1_1_glTexCoord2d(void *_glfuncs, GLdouble s, GLdouble t)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glTexCoord2d(s, t);
+}
+
+void gl1_1_glTexCoord1sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glTexCoord1sv(v);
+}
+
+void gl1_1_glTexCoord1s(void *_glfuncs, GLshort s)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glTexCoord1s(s);
+}
+
+void gl1_1_glTexCoord1iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glTexCoord1iv(v);
+}
+
+void gl1_1_glTexCoord1i(void *_glfuncs, GLint s)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glTexCoord1i(s);
+}
+
+void gl1_1_glTexCoord1fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glTexCoord1fv(v);
+}
+
+void gl1_1_glTexCoord1f(void *_glfuncs, GLfloat s)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glTexCoord1f(s);
+}
+
+void gl1_1_glTexCoord1dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glTexCoord1dv(v);
+}
+
+void gl1_1_glTexCoord1d(void *_glfuncs, GLdouble s)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glTexCoord1d(s);
+}
+
+void gl1_1_glRectsv(void *_glfuncs, const GLshort* v1, const GLshort* v2)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glRectsv(v1, v2);
+}
+
+void gl1_1_glRects(void *_glfuncs, GLshort x1, GLshort y1, GLshort x2, GLshort y2)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glRects(x1, y1, x2, y2);
+}
+
+void gl1_1_glRectiv(void *_glfuncs, const GLint* v1, const GLint* v2)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glRectiv(v1, v2);
+}
+
+void gl1_1_glRecti(void *_glfuncs, GLint x1, GLint y1, GLint x2, GLint y2)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glRecti(x1, y1, x2, y2);
+}
+
+void gl1_1_glRectfv(void *_glfuncs, const GLfloat* v1, const GLfloat* v2)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glRectfv(v1, v2);
+}
+
+void gl1_1_glRectf(void *_glfuncs, GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glRectf(x1, y1, x2, y2);
+}
+
+void gl1_1_glRectdv(void *_glfuncs, const GLdouble* v1, const GLdouble* v2)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glRectdv(v1, v2);
+}
+
+void gl1_1_glRectd(void *_glfuncs, GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glRectd(x1, y1, x2, y2);
+}
+
+void gl1_1_glRasterPos4sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glRasterPos4sv(v);
+}
+
+void gl1_1_glRasterPos4s(void *_glfuncs, GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glRasterPos4s(x, y, z, w);
+}
+
+void gl1_1_glRasterPos4iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glRasterPos4iv(v);
+}
+
+void gl1_1_glRasterPos4i(void *_glfuncs, GLint x, GLint y, GLint z, GLint w)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glRasterPos4i(x, y, z, w);
+}
+
+void gl1_1_glRasterPos4fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glRasterPos4fv(v);
+}
+
+void gl1_1_glRasterPos4f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glRasterPos4f(x, y, z, w);
+}
+
+void gl1_1_glRasterPos4dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glRasterPos4dv(v);
+}
+
+void gl1_1_glRasterPos4d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glRasterPos4d(x, y, z, w);
+}
+
+void gl1_1_glRasterPos3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glRasterPos3sv(v);
+}
+
+void gl1_1_glRasterPos3s(void *_glfuncs, GLshort x, GLshort y, GLshort z)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glRasterPos3s(x, y, z);
+}
+
+void gl1_1_glRasterPos3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glRasterPos3iv(v);
+}
+
+void gl1_1_glRasterPos3i(void *_glfuncs, GLint x, GLint y, GLint z)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glRasterPos3i(x, y, z);
+}
+
+void gl1_1_glRasterPos3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glRasterPos3fv(v);
+}
+
+void gl1_1_glRasterPos3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glRasterPos3f(x, y, z);
+}
+
+void gl1_1_glRasterPos3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glRasterPos3dv(v);
+}
+
+void gl1_1_glRasterPos3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glRasterPos3d(x, y, z);
+}
+
+void gl1_1_glRasterPos2sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glRasterPos2sv(v);
+}
+
+void gl1_1_glRasterPos2s(void *_glfuncs, GLshort x, GLshort y)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glRasterPos2s(x, y);
+}
+
+void gl1_1_glRasterPos2iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glRasterPos2iv(v);
+}
+
+void gl1_1_glRasterPos2i(void *_glfuncs, GLint x, GLint y)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glRasterPos2i(x, y);
+}
+
+void gl1_1_glRasterPos2fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glRasterPos2fv(v);
+}
+
+void gl1_1_glRasterPos2f(void *_glfuncs, GLfloat x, GLfloat y)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glRasterPos2f(x, y);
+}
+
+void gl1_1_glRasterPos2dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glRasterPos2dv(v);
+}
+
+void gl1_1_glRasterPos2d(void *_glfuncs, GLdouble x, GLdouble y)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glRasterPos2d(x, y);
+}
+
+void gl1_1_glNormal3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glNormal3sv(v);
+}
+
+void gl1_1_glNormal3s(void *_glfuncs, GLshort nx, GLshort ny, GLshort nz)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glNormal3s(nx, ny, nz);
+}
+
+void gl1_1_glNormal3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glNormal3iv(v);
+}
+
+void gl1_1_glNormal3i(void *_glfuncs, GLint nx, GLint ny, GLint nz)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glNormal3i(nx, ny, nz);
+}
+
+void gl1_1_glNormal3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glNormal3fv(v);
+}
+
+void gl1_1_glNormal3f(void *_glfuncs, GLfloat nx, GLfloat ny, GLfloat nz)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glNormal3f(nx, ny, nz);
+}
+
+void gl1_1_glNormal3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glNormal3dv(v);
+}
+
+void gl1_1_glNormal3d(void *_glfuncs, GLdouble nx, GLdouble ny, GLdouble nz)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glNormal3d(nx, ny, nz);
+}
+
+void gl1_1_glNormal3bv(void *_glfuncs, const GLbyte* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glNormal3bv(v);
+}
+
+void gl1_1_glNormal3b(void *_glfuncs, GLbyte nx, GLbyte ny, GLbyte nz)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glNormal3b(nx, ny, nz);
+}
+
+void gl1_1_glIndexsv(void *_glfuncs, const GLshort* c)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glIndexsv(c);
+}
+
+void gl1_1_glIndexs(void *_glfuncs, GLshort c)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glIndexs(c);
+}
+
+void gl1_1_glIndexiv(void *_glfuncs, const GLint* c)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glIndexiv(c);
+}
+
+void gl1_1_glIndexi(void *_glfuncs, GLint c)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glIndexi(c);
+}
+
+void gl1_1_glIndexfv(void *_glfuncs, const GLfloat* c)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glIndexfv(c);
+}
+
+void gl1_1_glIndexf(void *_glfuncs, GLfloat c)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glIndexf(c);
+}
+
+void gl1_1_glIndexdv(void *_glfuncs, const GLdouble* c)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glIndexdv(c);
+}
+
+void gl1_1_glIndexd(void *_glfuncs, GLdouble c)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glIndexd(c);
+}
+
+void gl1_1_glEnd(void *_glfuncs)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glEnd();
+}
+
+void gl1_1_glEdgeFlagv(void *_glfuncs, const GLboolean* flag)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glEdgeFlagv(flag);
+}
+
+void gl1_1_glEdgeFlag(void *_glfuncs, GLboolean flag)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glEdgeFlag(flag);
+}
+
+void gl1_1_glColor4usv(void *_glfuncs, const GLushort* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glColor4usv(v);
+}
+
+void gl1_1_glColor4us(void *_glfuncs, GLushort red, GLushort green, GLushort blue, GLushort alpha)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glColor4us(red, green, blue, alpha);
+}
+
+void gl1_1_glColor4uiv(void *_glfuncs, const GLuint* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glColor4uiv(v);
+}
+
+void gl1_1_glColor4ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue, GLuint alpha)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glColor4ui(red, green, blue, alpha);
+}
+
+void gl1_1_glColor4ubv(void *_glfuncs, const GLubyte* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glColor4ubv(v);
+}
+
+void gl1_1_glColor4ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glColor4ub(red, green, blue, alpha);
+}
+
+void gl1_1_glColor4sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glColor4sv(v);
+}
+
+void gl1_1_glColor4s(void *_glfuncs, GLshort red, GLshort green, GLshort blue, GLshort alpha)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glColor4s(red, green, blue, alpha);
+}
+
+void gl1_1_glColor4iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glColor4iv(v);
+}
+
+void gl1_1_glColor4i(void *_glfuncs, GLint red, GLint green, GLint blue, GLint alpha)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glColor4i(red, green, blue, alpha);
+}
+
+void gl1_1_glColor4fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glColor4fv(v);
+}
+
+void gl1_1_glColor4f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glColor4f(red, green, blue, alpha);
+}
+
+void gl1_1_glColor4dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glColor4dv(v);
+}
+
+void gl1_1_glColor4d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glColor4d(red, green, blue, alpha);
+}
+
+void gl1_1_glColor4bv(void *_glfuncs, const GLbyte* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glColor4bv(v);
+}
+
+void gl1_1_glColor4b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glColor4b(red, green, blue, alpha);
+}
+
+void gl1_1_glColor3usv(void *_glfuncs, const GLushort* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glColor3usv(v);
+}
+
+void gl1_1_glColor3us(void *_glfuncs, GLushort red, GLushort green, GLushort blue)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glColor3us(red, green, blue);
+}
+
+void gl1_1_glColor3uiv(void *_glfuncs, const GLuint* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glColor3uiv(v);
+}
+
+void gl1_1_glColor3ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glColor3ui(red, green, blue);
+}
+
+void gl1_1_glColor3ubv(void *_glfuncs, const GLubyte* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glColor3ubv(v);
+}
+
+void gl1_1_glColor3ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glColor3ub(red, green, blue);
+}
+
+void gl1_1_glColor3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glColor3sv(v);
+}
+
+void gl1_1_glColor3s(void *_glfuncs, GLshort red, GLshort green, GLshort blue)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glColor3s(red, green, blue);
+}
+
+void gl1_1_glColor3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glColor3iv(v);
+}
+
+void gl1_1_glColor3i(void *_glfuncs, GLint red, GLint green, GLint blue)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glColor3i(red, green, blue);
+}
+
+void gl1_1_glColor3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glColor3fv(v);
+}
+
+void gl1_1_glColor3f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glColor3f(red, green, blue);
+}
+
+void gl1_1_glColor3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glColor3dv(v);
+}
+
+void gl1_1_glColor3d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glColor3d(red, green, blue);
+}
+
+void gl1_1_glColor3bv(void *_glfuncs, const GLbyte* v)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glColor3bv(v);
+}
+
+void gl1_1_glColor3b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glColor3b(red, green, blue);
+}
+
+void gl1_1_glBitmap(void *_glfuncs, GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte* bitmap)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glBitmap(width, height, xorig, yorig, xmove, ymove, bitmap);
+}
+
+void gl1_1_glBegin(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glBegin(mode);
+}
+
+void gl1_1_glListBase(void *_glfuncs, GLuint base)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glListBase(base);
+}
+
+GLuint gl1_1_glGenLists(void *_glfuncs, GLsizei range_)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ return _qglfuncs->glGenLists(range_);
+}
+
+void gl1_1_glDeleteLists(void *_glfuncs, GLuint list, GLsizei range_)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glDeleteLists(list, range_);
+}
+
+void gl1_1_glCallLists(void *_glfuncs, GLsizei n, GLenum gltype, const GLvoid* lists)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glCallLists(n, gltype, lists);
+}
+
+void gl1_1_glCallList(void *_glfuncs, GLuint list)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glCallList(list);
+}
+
+void gl1_1_glEndList(void *_glfuncs)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glEndList();
+}
+
+void gl1_1_glNewList(void *_glfuncs, GLuint list, GLenum mode)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glNewList(list, mode);
+}
+
+void gl1_1_glPushClientAttrib(void *_glfuncs, GLbitfield mask)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glPushClientAttrib(mask);
+}
+
+void gl1_1_glPopClientAttrib(void *_glfuncs)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glPopClientAttrib();
+}
+
+void gl1_1_glPrioritizeTextures(void *_glfuncs, GLsizei n, const GLuint* textures, const GLfloat* priorities)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glPrioritizeTextures(n, textures, priorities);
+}
+
+GLboolean gl1_1_glAreTexturesResident(void *_glfuncs, GLsizei n, const GLuint* textures, GLboolean* residences)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ return _qglfuncs->glAreTexturesResident(n, textures, residences);
+}
+
+void gl1_1_glVertexPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glVertexPointer(size, gltype, stride, pointer);
+}
+
+void gl1_1_glTexCoordPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glTexCoordPointer(size, gltype, stride, pointer);
+}
+
+void gl1_1_glNormalPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glNormalPointer(gltype, stride, pointer);
+}
+
+void gl1_1_glInterleavedArrays(void *_glfuncs, GLenum format, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glInterleavedArrays(format, stride, pointer);
+}
+
+void gl1_1_glIndexPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glIndexPointer(gltype, stride, pointer);
+}
+
+void gl1_1_glEnableClientState(void *_glfuncs, GLenum array)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glEnableClientState(array);
+}
+
+void gl1_1_glEdgeFlagPointer(void *_glfuncs, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glEdgeFlagPointer(stride, pointer);
+}
+
+void gl1_1_glDisableClientState(void *_glfuncs, GLenum array)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glDisableClientState(array);
+}
+
+void gl1_1_glColorPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glColorPointer(size, gltype, stride, pointer);
+}
+
+void gl1_1_glArrayElement(void *_glfuncs, GLint i)
+{
+ QOpenGLFunctions_1_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_1*>(_glfuncs);
+ _qglfuncs->glArrayElement(i);
+}
+
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/1.1/funcs.h b/Godeps/_workspace/src/github.com/obscuren/qml/gl/1.1/funcs.h
new file mode 100644
index 000000000..f89c6a452
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/1.1/funcs.h
@@ -0,0 +1,376 @@
+
+// ** file automatically generated by glgen -- do not edit manually **
+
+#ifndef __cplusplus
+#include <inttypes.h>
+#include <stddef.h>
+typedef unsigned int GLenum;
+typedef unsigned char GLboolean;
+typedef unsigned int GLbitfield;
+typedef void GLvoid;
+typedef char GLchar;
+typedef signed char GLbyte; /* 1-byte signed */
+typedef short GLshort; /* 2-byte signed */
+typedef int GLint; /* 4-byte signed */
+typedef unsigned char GLubyte; /* 1-byte unsigned */
+typedef unsigned short GLushort; /* 2-byte unsigned */
+typedef unsigned int GLuint; /* 4-byte unsigned */
+typedef int GLsizei; /* 4-byte signed */
+typedef float GLfloat; /* single precision float */
+typedef float GLclampf; /* single precision float in [0,1] */
+typedef double GLdouble; /* double precision float */
+typedef double GLclampd; /* double precision float in [0,1] */
+typedef int64_t GLint64;
+typedef uint64_t GLuint64;
+typedef ptrdiff_t GLintptr;
+typedef ptrdiff_t GLsizeiptr;
+typedef ptrdiff_t GLintptrARB;
+typedef ptrdiff_t GLsizeiptrARB;
+typedef struct __GLsync *GLsync;
+#endif
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+void *gl1_1_funcs();
+
+void gl1_1_glViewport(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl1_1_glDepthRange(void *_glfuncs, GLdouble nearVal, GLdouble farVal);
+GLboolean gl1_1_glIsEnabled(void *_glfuncs, GLenum cap);
+void gl1_1_glGetTexLevelParameteriv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLint* params);
+void gl1_1_glGetTexLevelParameterfv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLfloat* params);
+void gl1_1_glGetTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl1_1_glGetTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl1_1_glGetTexImage(void *_glfuncs, GLenum target, GLint level, GLenum format, GLenum gltype, GLvoid* pixels);
+void gl1_1_glGetIntegerv(void *_glfuncs, GLenum pname, GLint* params);
+void gl1_1_glGetFloatv(void *_glfuncs, GLenum pname, GLfloat* params);
+GLenum gl1_1_glGetError(void *_glfuncs);
+void gl1_1_glGetDoublev(void *_glfuncs, GLenum pname, GLdouble* params);
+void gl1_1_glGetBooleanv(void *_glfuncs, GLenum pname, GLboolean* params);
+void gl1_1_glReadPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum gltype, GLvoid* pixels);
+void gl1_1_glReadBuffer(void *_glfuncs, GLenum mode);
+void gl1_1_glPixelStorei(void *_glfuncs, GLenum pname, GLint param);
+void gl1_1_glPixelStoref(void *_glfuncs, GLenum pname, GLfloat param);
+void gl1_1_glDepthFunc(void *_glfuncs, GLenum glfunc);
+void gl1_1_glStencilOp(void *_glfuncs, GLenum fail, GLenum zfail, GLenum zpass);
+void gl1_1_glStencilFunc(void *_glfuncs, GLenum glfunc, GLint ref, GLuint mask);
+void gl1_1_glLogicOp(void *_glfuncs, GLenum opcode);
+void gl1_1_glBlendFunc(void *_glfuncs, GLenum sfactor, GLenum dfactor);
+void gl1_1_glFlush(void *_glfuncs);
+void gl1_1_glFinish(void *_glfuncs);
+void gl1_1_glEnable(void *_glfuncs, GLenum cap);
+void gl1_1_glDisable(void *_glfuncs, GLenum cap);
+void gl1_1_glDepthMask(void *_glfuncs, GLboolean flag);
+void gl1_1_glColorMask(void *_glfuncs, GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha);
+void gl1_1_glStencilMask(void *_glfuncs, GLuint mask);
+void gl1_1_glClearDepth(void *_glfuncs, GLdouble depth);
+void gl1_1_glClearStencil(void *_glfuncs, GLint s);
+void gl1_1_glClearColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl1_1_glClear(void *_glfuncs, GLbitfield mask);
+void gl1_1_glDrawBuffer(void *_glfuncs, GLenum mode);
+void gl1_1_glTexImage2D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl1_1_glTexImage1D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl1_1_glTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl1_1_glTexParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint param);
+void gl1_1_glTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl1_1_glTexParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param);
+void gl1_1_glScissor(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl1_1_glPolygonMode(void *_glfuncs, GLenum face, GLenum mode);
+void gl1_1_glPointSize(void *_glfuncs, GLfloat size);
+void gl1_1_glLineWidth(void *_glfuncs, GLfloat width);
+void gl1_1_glHint(void *_glfuncs, GLenum target, GLenum mode);
+void gl1_1_glFrontFace(void *_glfuncs, GLenum mode);
+void gl1_1_glCullFace(void *_glfuncs, GLenum mode);
+void gl1_1_glIndexubv(void *_glfuncs, const GLubyte* c);
+void gl1_1_glIndexub(void *_glfuncs, GLubyte c);
+GLboolean gl1_1_glIsTexture(void *_glfuncs, GLuint texture);
+void gl1_1_glGenTextures(void *_glfuncs, GLsizei n, GLuint* textures);
+void gl1_1_glDeleteTextures(void *_glfuncs, GLsizei n, const GLuint* textures);
+void gl1_1_glBindTexture(void *_glfuncs, GLenum target, GLuint texture);
+void gl1_1_glTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl1_1_glTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl1_1_glCopyTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl1_1_glCopyTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width);
+void gl1_1_glCopyTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border);
+void gl1_1_glCopyTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLint border);
+void gl1_1_glPolygonOffset(void *_glfuncs, GLfloat factor, GLfloat units);
+void gl1_1_glDrawElements(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices);
+void gl1_1_glDrawArrays(void *_glfuncs, GLenum mode, GLint first, GLsizei count);
+void gl1_1_glTranslatef(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl1_1_glTranslated(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl1_1_glScalef(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl1_1_glScaled(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl1_1_glRotatef(void *_glfuncs, GLfloat angle, GLfloat x, GLfloat y, GLfloat z);
+void gl1_1_glRotated(void *_glfuncs, GLdouble angle, GLdouble x, GLdouble y, GLdouble z);
+void gl1_1_glPushMatrix(void *_glfuncs);
+void gl1_1_glPopMatrix(void *_glfuncs);
+void gl1_1_glOrtho(void *_glfuncs, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+void gl1_1_glMultMatrixd(void *_glfuncs, const GLdouble* m);
+void gl1_1_glMultMatrixf(void *_glfuncs, const GLfloat* m);
+void gl1_1_glMatrixMode(void *_glfuncs, GLenum mode);
+void gl1_1_glLoadMatrixd(void *_glfuncs, const GLdouble* m);
+void gl1_1_glLoadMatrixf(void *_glfuncs, const GLfloat* m);
+void gl1_1_glLoadIdentity(void *_glfuncs);
+void gl1_1_glFrustum(void *_glfuncs, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+GLboolean gl1_1_glIsList(void *_glfuncs, GLuint list);
+void gl1_1_glGetTexGeniv(void *_glfuncs, GLenum coord, GLenum pname, GLint* params);
+void gl1_1_glGetTexGenfv(void *_glfuncs, GLenum coord, GLenum pname, GLfloat* params);
+void gl1_1_glGetTexGendv(void *_glfuncs, GLenum coord, GLenum pname, GLdouble* params);
+void gl1_1_glGetTexEnviv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl1_1_glGetTexEnvfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl1_1_glGetPolygonStipple(void *_glfuncs, GLubyte* mask);
+void gl1_1_glGetPixelMapusv(void *_glfuncs, GLenum glmap, GLushort* values);
+void gl1_1_glGetPixelMapuiv(void *_glfuncs, GLenum glmap, GLuint* values);
+void gl1_1_glGetPixelMapfv(void *_glfuncs, GLenum glmap, GLfloat* values);
+void gl1_1_glGetMaterialiv(void *_glfuncs, GLenum face, GLenum pname, GLint* params);
+void gl1_1_glGetMaterialfv(void *_glfuncs, GLenum face, GLenum pname, GLfloat* params);
+void gl1_1_glGetMapiv(void *_glfuncs, GLenum target, GLenum query, GLint* v);
+void gl1_1_glGetMapfv(void *_glfuncs, GLenum target, GLenum query, GLfloat* v);
+void gl1_1_glGetMapdv(void *_glfuncs, GLenum target, GLenum query, GLdouble* v);
+void gl1_1_glGetLightiv(void *_glfuncs, GLenum light, GLenum pname, GLint* params);
+void gl1_1_glGetLightfv(void *_glfuncs, GLenum light, GLenum pname, GLfloat* params);
+void gl1_1_glGetClipPlane(void *_glfuncs, GLenum plane, GLdouble* equation);
+void gl1_1_glDrawPixels(void *_glfuncs, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl1_1_glCopyPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum gltype);
+void gl1_1_glPixelMapusv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLushort* values);
+void gl1_1_glPixelMapuiv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLuint* values);
+void gl1_1_glPixelMapfv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLfloat* values);
+void gl1_1_glPixelTransferi(void *_glfuncs, GLenum pname, GLint param);
+void gl1_1_glPixelTransferf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl1_1_glPixelZoom(void *_glfuncs, GLfloat xfactor, GLfloat yfactor);
+void gl1_1_glAlphaFunc(void *_glfuncs, GLenum glfunc, GLfloat ref);
+void gl1_1_glEvalPoint2(void *_glfuncs, GLint i, GLint j);
+void gl1_1_glEvalMesh2(void *_glfuncs, GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2);
+void gl1_1_glEvalPoint1(void *_glfuncs, GLint i);
+void gl1_1_glEvalMesh1(void *_glfuncs, GLenum mode, GLint i1, GLint i2);
+void gl1_1_glEvalCoord2fv(void *_glfuncs, const GLfloat* u);
+void gl1_1_glEvalCoord2f(void *_glfuncs, GLfloat u, GLfloat v);
+void gl1_1_glEvalCoord2dv(void *_glfuncs, const GLdouble* u);
+void gl1_1_glEvalCoord2d(void *_glfuncs, GLdouble u, GLdouble v);
+void gl1_1_glEvalCoord1fv(void *_glfuncs, const GLfloat* u);
+void gl1_1_glEvalCoord1f(void *_glfuncs, GLfloat u);
+void gl1_1_glEvalCoord1dv(void *_glfuncs, const GLdouble* u);
+void gl1_1_glEvalCoord1d(void *_glfuncs, GLdouble u);
+void gl1_1_glMapGrid2f(void *_glfuncs, GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2);
+void gl1_1_glMapGrid2d(void *_glfuncs, GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2);
+void gl1_1_glMapGrid1f(void *_glfuncs, GLint un, GLfloat u1, GLfloat u2);
+void gl1_1_glMapGrid1d(void *_glfuncs, GLint un, GLdouble u1, GLdouble u2);
+void gl1_1_glMap2f(void *_glfuncs, GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat* points);
+void gl1_1_glMap2d(void *_glfuncs, GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble* points);
+void gl1_1_glMap1f(void *_glfuncs, GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat* points);
+void gl1_1_glMap1d(void *_glfuncs, GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble* points);
+void gl1_1_glPushAttrib(void *_glfuncs, GLbitfield mask);
+void gl1_1_glPopAttrib(void *_glfuncs);
+void gl1_1_glAccum(void *_glfuncs, GLenum op, GLfloat value);
+void gl1_1_glIndexMask(void *_glfuncs, GLuint mask);
+void gl1_1_glClearIndex(void *_glfuncs, GLfloat c);
+void gl1_1_glClearAccum(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl1_1_glPushName(void *_glfuncs, GLuint name);
+void gl1_1_glPopName(void *_glfuncs);
+void gl1_1_glPassThrough(void *_glfuncs, GLfloat token);
+void gl1_1_glLoadName(void *_glfuncs, GLuint name);
+void gl1_1_glInitNames(void *_glfuncs);
+GLint gl1_1_glRenderMode(void *_glfuncs, GLenum mode);
+void gl1_1_glSelectBuffer(void *_glfuncs, GLsizei size, GLuint* buffer);
+void gl1_1_glFeedbackBuffer(void *_glfuncs, GLsizei size, GLenum gltype, GLfloat* buffer);
+void gl1_1_glTexGeniv(void *_glfuncs, GLenum coord, GLenum pname, const GLint* params);
+void gl1_1_glTexGeni(void *_glfuncs, GLenum coord, GLenum pname, GLint param);
+void gl1_1_glTexGenfv(void *_glfuncs, GLenum coord, GLenum pname, const GLfloat* params);
+void gl1_1_glTexGenf(void *_glfuncs, GLenum coord, GLenum pname, GLfloat param);
+void gl1_1_glTexGendv(void *_glfuncs, GLenum coord, GLenum pname, const GLdouble* params);
+void gl1_1_glTexGend(void *_glfuncs, GLenum coord, GLenum pname, GLdouble param);
+void gl1_1_glTexEnviv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl1_1_glTexEnvi(void *_glfuncs, GLenum target, GLenum pname, GLint param);
+void gl1_1_glTexEnvfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl1_1_glTexEnvf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param);
+void gl1_1_glShadeModel(void *_glfuncs, GLenum mode);
+void gl1_1_glPolygonStipple(void *_glfuncs, const GLubyte* mask);
+void gl1_1_glMaterialiv(void *_glfuncs, GLenum face, GLenum pname, const GLint* params);
+void gl1_1_glMateriali(void *_glfuncs, GLenum face, GLenum pname, GLint param);
+void gl1_1_glMaterialfv(void *_glfuncs, GLenum face, GLenum pname, const GLfloat* params);
+void gl1_1_glMaterialf(void *_glfuncs, GLenum face, GLenum pname, GLfloat param);
+void gl1_1_glLineStipple(void *_glfuncs, GLint factor, GLushort pattern);
+void gl1_1_glLightModeliv(void *_glfuncs, GLenum pname, const GLint* params);
+void gl1_1_glLightModeli(void *_glfuncs, GLenum pname, GLint param);
+void gl1_1_glLightModelfv(void *_glfuncs, GLenum pname, const GLfloat* params);
+void gl1_1_glLightModelf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl1_1_glLightiv(void *_glfuncs, GLenum light, GLenum pname, const GLint* params);
+void gl1_1_glLighti(void *_glfuncs, GLenum light, GLenum pname, GLint param);
+void gl1_1_glLightfv(void *_glfuncs, GLenum light, GLenum pname, const GLfloat* params);
+void gl1_1_glLightf(void *_glfuncs, GLenum light, GLenum pname, GLfloat param);
+void gl1_1_glFogiv(void *_glfuncs, GLenum pname, const GLint* params);
+void gl1_1_glFogi(void *_glfuncs, GLenum pname, GLint param);
+void gl1_1_glFogfv(void *_glfuncs, GLenum pname, const GLfloat* params);
+void gl1_1_glFogf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl1_1_glColorMaterial(void *_glfuncs, GLenum face, GLenum mode);
+void gl1_1_glClipPlane(void *_glfuncs, GLenum plane, const GLdouble* equation);
+void gl1_1_glVertex4sv(void *_glfuncs, const GLshort* v);
+void gl1_1_glVertex4s(void *_glfuncs, GLshort x, GLshort y, GLshort z, GLshort w);
+void gl1_1_glVertex4iv(void *_glfuncs, const GLint* v);
+void gl1_1_glVertex4i(void *_glfuncs, GLint x, GLint y, GLint z, GLint w);
+void gl1_1_glVertex4fv(void *_glfuncs, const GLfloat* v);
+void gl1_1_glVertex4f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+void gl1_1_glVertex4dv(void *_glfuncs, const GLdouble* v);
+void gl1_1_glVertex4d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+void gl1_1_glVertex3sv(void *_glfuncs, const GLshort* v);
+void gl1_1_glVertex3s(void *_glfuncs, GLshort x, GLshort y, GLshort z);
+void gl1_1_glVertex3iv(void *_glfuncs, const GLint* v);
+void gl1_1_glVertex3i(void *_glfuncs, GLint x, GLint y, GLint z);
+void gl1_1_glVertex3fv(void *_glfuncs, const GLfloat* v);
+void gl1_1_glVertex3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl1_1_glVertex3dv(void *_glfuncs, const GLdouble* v);
+void gl1_1_glVertex3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl1_1_glVertex2sv(void *_glfuncs, const GLshort* v);
+void gl1_1_glVertex2s(void *_glfuncs, GLshort x, GLshort y);
+void gl1_1_glVertex2iv(void *_glfuncs, const GLint* v);
+void gl1_1_glVertex2i(void *_glfuncs, GLint x, GLint y);
+void gl1_1_glVertex2fv(void *_glfuncs, const GLfloat* v);
+void gl1_1_glVertex2f(void *_glfuncs, GLfloat x, GLfloat y);
+void gl1_1_glVertex2dv(void *_glfuncs, const GLdouble* v);
+void gl1_1_glVertex2d(void *_glfuncs, GLdouble x, GLdouble y);
+void gl1_1_glTexCoord4sv(void *_glfuncs, const GLshort* v);
+void gl1_1_glTexCoord4s(void *_glfuncs, GLshort s, GLshort t, GLshort r, GLshort q);
+void gl1_1_glTexCoord4iv(void *_glfuncs, const GLint* v);
+void gl1_1_glTexCoord4i(void *_glfuncs, GLint s, GLint t, GLint r, GLint q);
+void gl1_1_glTexCoord4fv(void *_glfuncs, const GLfloat* v);
+void gl1_1_glTexCoord4f(void *_glfuncs, GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+void gl1_1_glTexCoord4dv(void *_glfuncs, const GLdouble* v);
+void gl1_1_glTexCoord4d(void *_glfuncs, GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+void gl1_1_glTexCoord3sv(void *_glfuncs, const GLshort* v);
+void gl1_1_glTexCoord3s(void *_glfuncs, GLshort s, GLshort t, GLshort r);
+void gl1_1_glTexCoord3iv(void *_glfuncs, const GLint* v);
+void gl1_1_glTexCoord3i(void *_glfuncs, GLint s, GLint t, GLint r);
+void gl1_1_glTexCoord3fv(void *_glfuncs, const GLfloat* v);
+void gl1_1_glTexCoord3f(void *_glfuncs, GLfloat s, GLfloat t, GLfloat r);
+void gl1_1_glTexCoord3dv(void *_glfuncs, const GLdouble* v);
+void gl1_1_glTexCoord3d(void *_glfuncs, GLdouble s, GLdouble t, GLdouble r);
+void gl1_1_glTexCoord2sv(void *_glfuncs, const GLshort* v);
+void gl1_1_glTexCoord2s(void *_glfuncs, GLshort s, GLshort t);
+void gl1_1_glTexCoord2iv(void *_glfuncs, const GLint* v);
+void gl1_1_glTexCoord2i(void *_glfuncs, GLint s, GLint t);
+void gl1_1_glTexCoord2fv(void *_glfuncs, const GLfloat* v);
+void gl1_1_glTexCoord2f(void *_glfuncs, GLfloat s, GLfloat t);
+void gl1_1_glTexCoord2dv(void *_glfuncs, const GLdouble* v);
+void gl1_1_glTexCoord2d(void *_glfuncs, GLdouble s, GLdouble t);
+void gl1_1_glTexCoord1sv(void *_glfuncs, const GLshort* v);
+void gl1_1_glTexCoord1s(void *_glfuncs, GLshort s);
+void gl1_1_glTexCoord1iv(void *_glfuncs, const GLint* v);
+void gl1_1_glTexCoord1i(void *_glfuncs, GLint s);
+void gl1_1_glTexCoord1fv(void *_glfuncs, const GLfloat* v);
+void gl1_1_glTexCoord1f(void *_glfuncs, GLfloat s);
+void gl1_1_glTexCoord1dv(void *_glfuncs, const GLdouble* v);
+void gl1_1_glTexCoord1d(void *_glfuncs, GLdouble s);
+void gl1_1_glRectsv(void *_glfuncs, const GLshort* v1, const GLshort* v2);
+void gl1_1_glRects(void *_glfuncs, GLshort x1, GLshort y1, GLshort x2, GLshort y2);
+void gl1_1_glRectiv(void *_glfuncs, const GLint* v1, const GLint* v2);
+void gl1_1_glRecti(void *_glfuncs, GLint x1, GLint y1, GLint x2, GLint y2);
+void gl1_1_glRectfv(void *_glfuncs, const GLfloat* v1, const GLfloat* v2);
+void gl1_1_glRectf(void *_glfuncs, GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2);
+void gl1_1_glRectdv(void *_glfuncs, const GLdouble* v1, const GLdouble* v2);
+void gl1_1_glRectd(void *_glfuncs, GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2);
+void gl1_1_glRasterPos4sv(void *_glfuncs, const GLshort* v);
+void gl1_1_glRasterPos4s(void *_glfuncs, GLshort x, GLshort y, GLshort z, GLshort w);
+void gl1_1_glRasterPos4iv(void *_glfuncs, const GLint* v);
+void gl1_1_glRasterPos4i(void *_glfuncs, GLint x, GLint y, GLint z, GLint w);
+void gl1_1_glRasterPos4fv(void *_glfuncs, const GLfloat* v);
+void gl1_1_glRasterPos4f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+void gl1_1_glRasterPos4dv(void *_glfuncs, const GLdouble* v);
+void gl1_1_glRasterPos4d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+void gl1_1_glRasterPos3sv(void *_glfuncs, const GLshort* v);
+void gl1_1_glRasterPos3s(void *_glfuncs, GLshort x, GLshort y, GLshort z);
+void gl1_1_glRasterPos3iv(void *_glfuncs, const GLint* v);
+void gl1_1_glRasterPos3i(void *_glfuncs, GLint x, GLint y, GLint z);
+void gl1_1_glRasterPos3fv(void *_glfuncs, const GLfloat* v);
+void gl1_1_glRasterPos3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl1_1_glRasterPos3dv(void *_glfuncs, const GLdouble* v);
+void gl1_1_glRasterPos3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl1_1_glRasterPos2sv(void *_glfuncs, const GLshort* v);
+void gl1_1_glRasterPos2s(void *_glfuncs, GLshort x, GLshort y);
+void gl1_1_glRasterPos2iv(void *_glfuncs, const GLint* v);
+void gl1_1_glRasterPos2i(void *_glfuncs, GLint x, GLint y);
+void gl1_1_glRasterPos2fv(void *_glfuncs, const GLfloat* v);
+void gl1_1_glRasterPos2f(void *_glfuncs, GLfloat x, GLfloat y);
+void gl1_1_glRasterPos2dv(void *_glfuncs, const GLdouble* v);
+void gl1_1_glRasterPos2d(void *_glfuncs, GLdouble x, GLdouble y);
+void gl1_1_glNormal3sv(void *_glfuncs, const GLshort* v);
+void gl1_1_glNormal3s(void *_glfuncs, GLshort nx, GLshort ny, GLshort nz);
+void gl1_1_glNormal3iv(void *_glfuncs, const GLint* v);
+void gl1_1_glNormal3i(void *_glfuncs, GLint nx, GLint ny, GLint nz);
+void gl1_1_glNormal3fv(void *_glfuncs, const GLfloat* v);
+void gl1_1_glNormal3f(void *_glfuncs, GLfloat nx, GLfloat ny, GLfloat nz);
+void gl1_1_glNormal3dv(void *_glfuncs, const GLdouble* v);
+void gl1_1_glNormal3d(void *_glfuncs, GLdouble nx, GLdouble ny, GLdouble nz);
+void gl1_1_glNormal3bv(void *_glfuncs, const GLbyte* v);
+void gl1_1_glNormal3b(void *_glfuncs, GLbyte nx, GLbyte ny, GLbyte nz);
+void gl1_1_glIndexsv(void *_glfuncs, const GLshort* c);
+void gl1_1_glIndexs(void *_glfuncs, GLshort c);
+void gl1_1_glIndexiv(void *_glfuncs, const GLint* c);
+void gl1_1_glIndexi(void *_glfuncs, GLint c);
+void gl1_1_glIndexfv(void *_glfuncs, const GLfloat* c);
+void gl1_1_glIndexf(void *_glfuncs, GLfloat c);
+void gl1_1_glIndexdv(void *_glfuncs, const GLdouble* c);
+void gl1_1_glIndexd(void *_glfuncs, GLdouble c);
+void gl1_1_glEnd(void *_glfuncs);
+void gl1_1_glEdgeFlagv(void *_glfuncs, const GLboolean* flag);
+void gl1_1_glEdgeFlag(void *_glfuncs, GLboolean flag);
+void gl1_1_glColor4usv(void *_glfuncs, const GLushort* v);
+void gl1_1_glColor4us(void *_glfuncs, GLushort red, GLushort green, GLushort blue, GLushort alpha);
+void gl1_1_glColor4uiv(void *_glfuncs, const GLuint* v);
+void gl1_1_glColor4ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue, GLuint alpha);
+void gl1_1_glColor4ubv(void *_glfuncs, const GLubyte* v);
+void gl1_1_glColor4ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha);
+void gl1_1_glColor4sv(void *_glfuncs, const GLshort* v);
+void gl1_1_glColor4s(void *_glfuncs, GLshort red, GLshort green, GLshort blue, GLshort alpha);
+void gl1_1_glColor4iv(void *_glfuncs, const GLint* v);
+void gl1_1_glColor4i(void *_glfuncs, GLint red, GLint green, GLint blue, GLint alpha);
+void gl1_1_glColor4fv(void *_glfuncs, const GLfloat* v);
+void gl1_1_glColor4f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl1_1_glColor4dv(void *_glfuncs, const GLdouble* v);
+void gl1_1_glColor4d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha);
+void gl1_1_glColor4bv(void *_glfuncs, const GLbyte* v);
+void gl1_1_glColor4b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha);
+void gl1_1_glColor3usv(void *_glfuncs, const GLushort* v);
+void gl1_1_glColor3us(void *_glfuncs, GLushort red, GLushort green, GLushort blue);
+void gl1_1_glColor3uiv(void *_glfuncs, const GLuint* v);
+void gl1_1_glColor3ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue);
+void gl1_1_glColor3ubv(void *_glfuncs, const GLubyte* v);
+void gl1_1_glColor3ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue);
+void gl1_1_glColor3sv(void *_glfuncs, const GLshort* v);
+void gl1_1_glColor3s(void *_glfuncs, GLshort red, GLshort green, GLshort blue);
+void gl1_1_glColor3iv(void *_glfuncs, const GLint* v);
+void gl1_1_glColor3i(void *_glfuncs, GLint red, GLint green, GLint blue);
+void gl1_1_glColor3fv(void *_glfuncs, const GLfloat* v);
+void gl1_1_glColor3f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue);
+void gl1_1_glColor3dv(void *_glfuncs, const GLdouble* v);
+void gl1_1_glColor3d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue);
+void gl1_1_glColor3bv(void *_glfuncs, const GLbyte* v);
+void gl1_1_glColor3b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue);
+void gl1_1_glBitmap(void *_glfuncs, GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte* bitmap);
+void gl1_1_glBegin(void *_glfuncs, GLenum mode);
+void gl1_1_glListBase(void *_glfuncs, GLuint base);
+GLuint gl1_1_glGenLists(void *_glfuncs, GLsizei range_);
+void gl1_1_glDeleteLists(void *_glfuncs, GLuint list, GLsizei range_);
+void gl1_1_glCallLists(void *_glfuncs, GLsizei n, GLenum gltype, const GLvoid* lists);
+void gl1_1_glCallList(void *_glfuncs, GLuint list);
+void gl1_1_glEndList(void *_glfuncs);
+void gl1_1_glNewList(void *_glfuncs, GLuint list, GLenum mode);
+void gl1_1_glPushClientAttrib(void *_glfuncs, GLbitfield mask);
+void gl1_1_glPopClientAttrib(void *_glfuncs);
+void gl1_1_glPrioritizeTextures(void *_glfuncs, GLsizei n, const GLuint* textures, const GLfloat* priorities);
+GLboolean gl1_1_glAreTexturesResident(void *_glfuncs, GLsizei n, const GLuint* textures, GLboolean* residences);
+void gl1_1_glVertexPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl1_1_glTexCoordPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl1_1_glNormalPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl1_1_glInterleavedArrays(void *_glfuncs, GLenum format, GLsizei stride, const GLvoid* pointer);
+void gl1_1_glIndexPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl1_1_glEnableClientState(void *_glfuncs, GLenum array);
+void gl1_1_glEdgeFlagPointer(void *_glfuncs, GLsizei stride, const GLvoid* pointer);
+void gl1_1_glDisableClientState(void *_glfuncs, GLenum array);
+void gl1_1_glColorPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl1_1_glArrayElement(void *_glfuncs, GLint i);
+
+
+#ifdef __cplusplus
+} // extern "C"
+#endif
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/1.1/gl.go b/Godeps/_workspace/src/github.com/obscuren/qml/gl/1.1/gl.go
new file mode 100644
index 000000000..268e1c083
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/1.1/gl.go
@@ -0,0 +1,2789 @@
+// ** file automatically generated by glgen -- do not edit manually **
+
+package GL
+
+// #cgo CXXFLAGS: -std=c++0x -pedantic-errors -Wall -fno-strict-aliasing
+// #cgo LDFLAGS: -lstdc++
+// #cgo pkg-config: Qt5Core Qt5OpenGL
+//
+// #include "funcs.h"
+//
+// void free(void*);
+//
+import "C"
+
+import (
+ "fmt"
+ "reflect"
+ "unsafe"
+
+ "gopkg.in/qml.v1/gl/glbase"
+)
+
+// API returns a value that offers methods matching the OpenGL version 1.1 API.
+//
+// The returned API must not be used after the provided OpenGL context becomes invalid.
+func API(context glbase.Contexter) *GL {
+ gl := &GL{}
+ gl.funcs = C.gl1_1_funcs()
+ if gl.funcs == nil {
+ panic(fmt.Errorf("OpenGL version 1.1 is not available"))
+ }
+ return gl
+}
+
+// GL implements the OpenGL version 1.1 API. Values of this
+// type must be created via the API function, and it must not be used after
+// the associated OpenGL context becomes invalid.
+type GL struct {
+ funcs unsafe.Pointer
+}
+
+const (
+ FALSE = 0
+ TRUE = 1
+ NONE = 0
+
+ BYTE = 0x1400
+ UNSIGNED_BYTE = 0x1401
+ SHORT = 0x1402
+ UNSIGNED_SHORT = 0x1403
+ INT = 0x1404
+ UNSIGNED_INT = 0x1405
+ FLOAT = 0x1406
+ N2_BYTES = 0x1407
+ N3_BYTES = 0x1408
+ N4_BYTES = 0x1409
+ DOUBLE = 0x140A
+
+ ACCUM = 0x0100
+ LOAD = 0x0101
+ RETURN = 0x0102
+ MULT = 0x0103
+ ADD = 0x0104
+
+ ACCUM_BUFFER_BIT = 0x00000200
+ ALL_ATTRIB_BITS = 0xFFFFFFFF
+ COLOR_BUFFER_BIT = 0x00004000
+ CURRENT_BIT = 0x00000001
+ DEPTH_BUFFER_BIT = 0x00000100
+ ENABLE_BIT = 0x00002000
+ EVAL_BIT = 0x00010000
+ FOG_BIT = 0x00000080
+ HINT_BIT = 0x00008000
+ LIGHTING_BIT = 0x00000040
+ LINE_BIT = 0x00000004
+ LIST_BIT = 0x00020000
+ PIXEL_MODE_BIT = 0x00000020
+ POINT_BIT = 0x00000002
+ POLYGON_BIT = 0x00000008
+ POLYGON_STIPPLE_BIT = 0x00000010
+ SCISSOR_BIT = 0x00080000
+ STENCIL_BUFFER_BIT = 0x00000400
+ TEXTURE_BIT = 0x00040000
+ TRANSFORM_BIT = 0x00001000
+ VIEWPORT_BIT = 0x00000800
+
+ ALWAYS = 0x0207
+ EQUAL = 0x0202
+ GEQUAL = 0x0206
+ GREATER = 0x0204
+ LEQUAL = 0x0203
+ LESS = 0x0201
+ NEVER = 0x0200
+ NOTEQUAL = 0x0205
+
+ LOGIC_OP = 0x0BF1
+
+ DST_ALPHA = 0x0304
+ ONE = 1
+ ONE_MINUS_DST_ALPHA = 0x0305
+ ONE_MINUS_SRC_ALPHA = 0x0303
+ ONE_MINUS_SRC_COLOR = 0x0301
+ SRC_ALPHA = 0x0302
+ SRC_COLOR = 0x0300
+ ZERO = 0
+
+ DST_COLOR = 0x0306
+ ONE_MINUS_DST_COLOR = 0x0307
+ SRC_ALPHA_SATURATE = 0x0308
+
+ CLIENT_ALL_ATTRIB_BITS = 0xFFFFFFFF
+ CLIENT_PIXEL_STORE_BIT = 0x00000001
+ CLIENT_VERTEX_ARRAY_BIT = 0x00000002
+
+ CLIP_PLANE0 = 0x3000
+ CLIP_PLANE1 = 0x3001
+ CLIP_PLANE2 = 0x3002
+ CLIP_PLANE3 = 0x3003
+ CLIP_PLANE4 = 0x3004
+ CLIP_PLANE5 = 0x3005
+
+ BACK = 0x0405
+ FRONT = 0x0404
+ FRONT_AND_BACK = 0x0408
+
+ AMBIENT = 0x1200
+ AMBIENT_AND_DIFFUSE = 0x1602
+ DIFFUSE = 0x1201
+ EMISSION = 0x1600
+ SPECULAR = 0x1202
+
+ AUX0 = 0x0409
+ AUX1 = 0x040A
+ AUX2 = 0x040B
+ AUX3 = 0x040C
+ BACK_LEFT = 0x0402
+ BACK_RIGHT = 0x0403
+ FRONT_LEFT = 0x0400
+ FRONT_RIGHT = 0x0401
+ LEFT = 0x0406
+ RIGHT = 0x0407
+
+ ALPHA_TEST = 0x0BC0
+ AUTO_NORMAL = 0x0D80
+ BLEND = 0x0BE2
+ COLOR_ARRAY = 0x8076
+ COLOR_LOGIC_OP = 0x0BF2
+ COLOR_MATERIAL = 0x0B57
+ CULL_FACE = 0x0B44
+ DEPTH_TEST = 0x0B71
+ DITHER = 0x0BD0
+ EDGE_FLAG_ARRAY = 0x8079
+ FOG = 0x0B60
+ INDEX_ARRAY = 0x8077
+ INDEX_LOGIC_OP = 0x0BF1
+ LIGHT0 = 0x4000
+ LIGHT1 = 0x4001
+ LIGHT2 = 0x4002
+ LIGHT3 = 0x4003
+ LIGHT4 = 0x4004
+ LIGHT5 = 0x4005
+ LIGHT6 = 0x4006
+ LIGHT7 = 0x4007
+ LIGHTING = 0x0B50
+ LINE_SMOOTH = 0x0B20
+ LINE_STIPPLE = 0x0B24
+ MAP1_COLOR_4 = 0x0D90
+ MAP1_INDEX = 0x0D91
+ MAP1_NORMAL = 0x0D92
+ MAP1_TEXTURE_COORD_1 = 0x0D93
+ MAP1_TEXTURE_COORD_2 = 0x0D94
+ MAP1_TEXTURE_COORD_3 = 0x0D95
+ MAP1_TEXTURE_COORD_4 = 0x0D96
+ MAP1_VERTEX_3 = 0x0D97
+ MAP1_VERTEX_4 = 0x0D98
+ MAP2_COLOR_4 = 0x0DB0
+ MAP2_INDEX = 0x0DB1
+ MAP2_NORMAL = 0x0DB2
+ MAP2_TEXTURE_COORD_1 = 0x0DB3
+ MAP2_TEXTURE_COORD_2 = 0x0DB4
+ MAP2_TEXTURE_COORD_3 = 0x0DB5
+ MAP2_TEXTURE_COORD_4 = 0x0DB6
+ MAP2_VERTEX_3 = 0x0DB7
+ MAP2_VERTEX_4 = 0x0DB8
+ NORMALIZE = 0x0BA1
+ NORMAL_ARRAY = 0x8075
+ POINT_SMOOTH = 0x0B10
+ POLYGON_OFFSET_FILL = 0x8037
+ POLYGON_OFFSET_LINE = 0x2A02
+ POLYGON_OFFSET_POINT = 0x2A01
+ POLYGON_SMOOTH = 0x0B41
+ POLYGON_STIPPLE = 0x0B42
+ SCISSOR_TEST = 0x0C11
+ STENCIL_TEST = 0x0B90
+ TEXTURE_1D = 0x0DE0
+ TEXTURE_2D = 0x0DE1
+ TEXTURE_COORD_ARRAY = 0x8078
+ TEXTURE_GEN_Q = 0x0C63
+ TEXTURE_GEN_R = 0x0C62
+ TEXTURE_GEN_S = 0x0C60
+ TEXTURE_GEN_T = 0x0C61
+ VERTEX_ARRAY = 0x8074
+
+ INVALID_ENUM = 0x0500
+ INVALID_OPERATION = 0x0502
+ INVALID_VALUE = 0x0501
+ NO_ERROR = 0
+ OUT_OF_MEMORY = 0x0505
+ STACK_OVERFLOW = 0x0503
+ STACK_UNDERFLOW = 0x0504
+
+ N2D = 0x0600
+ N3D = 0x0601
+ N3D_COLOR = 0x0602
+ N3D_COLOR_TEXTURE = 0x0603
+ N4D_COLOR_TEXTURE = 0x0604
+
+ BITMAP_TOKEN = 0x0704
+ COPY_PIXEL_TOKEN = 0x0706
+ DRAW_PIXEL_TOKEN = 0x0705
+ LINE_RESET_TOKEN = 0x0707
+ LINE_TOKEN = 0x0702
+ PASS_THROUGH_TOKEN = 0x0700
+ POINT_TOKEN = 0x0701
+ POLYGON_TOKEN = 0x0703
+
+ EXP = 0x0800
+ EXP2 = 0x0801
+ LINEAR = 0x2601
+
+ FOG_COLOR = 0x0B66
+ FOG_DENSITY = 0x0B62
+ FOG_END = 0x0B64
+ FOG_INDEX = 0x0B61
+ FOG_MODE = 0x0B65
+ FOG_START = 0x0B63
+
+ CCW = 0x0901
+ CW = 0x0900
+
+ COEFF = 0x0A00
+ DOMAIN = 0x0A02
+ ORDER = 0x0A01
+
+ PIXEL_MAP_A_TO_A = 0x0C79
+ PIXEL_MAP_B_TO_B = 0x0C78
+ PIXEL_MAP_G_TO_G = 0x0C77
+ PIXEL_MAP_I_TO_A = 0x0C75
+ PIXEL_MAP_I_TO_B = 0x0C74
+ PIXEL_MAP_I_TO_G = 0x0C73
+ PIXEL_MAP_I_TO_I = 0x0C70
+ PIXEL_MAP_I_TO_R = 0x0C72
+ PIXEL_MAP_R_TO_R = 0x0C76
+ PIXEL_MAP_S_TO_S = 0x0C71
+
+ ACCUM_ALPHA_BITS = 0x0D5B
+ ACCUM_BLUE_BITS = 0x0D5A
+ ACCUM_CLEAR_VALUE = 0x0B80
+ ACCUM_GREEN_BITS = 0x0D59
+ ACCUM_RED_BITS = 0x0D58
+ ALPHA_BIAS = 0x0D1D
+ ALPHA_BITS = 0x0D55
+ ALPHA_SCALE = 0x0D1C
+ ALPHA_TEST_FUNC = 0x0BC1
+ ALPHA_TEST_REF = 0x0BC2
+ ATTRIB_STACK_DEPTH = 0x0BB0
+ AUX_BUFFERS = 0x0C00
+ BLEND_DST = 0x0BE0
+ BLEND_SRC = 0x0BE1
+ BLUE_BIAS = 0x0D1B
+ BLUE_BITS = 0x0D54
+ BLUE_SCALE = 0x0D1A
+ CLIENT_ATTRIB_STACK_DEPTH = 0x0BB1
+ COLOR_ARRAY_SIZE = 0x8081
+ COLOR_ARRAY_STRIDE = 0x8083
+ COLOR_ARRAY_TYPE = 0x8082
+ COLOR_CLEAR_VALUE = 0x0C22
+ COLOR_MATERIAL_FACE = 0x0B55
+ COLOR_MATERIAL_PARAMETER = 0x0B56
+ COLOR_WRITEMASK = 0x0C23
+ CULL_FACE_MODE = 0x0B45
+ CURRENT_COLOR = 0x0B00
+ CURRENT_INDEX = 0x0B01
+ CURRENT_NORMAL = 0x0B02
+ CURRENT_RASTER_COLOR = 0x0B04
+ CURRENT_RASTER_DISTANCE = 0x0B09
+ CURRENT_RASTER_INDEX = 0x0B05
+ CURRENT_RASTER_POSITION = 0x0B07
+ CURRENT_RASTER_POSITION_VALID = 0x0B08
+ CURRENT_RASTER_TEXTURE_COORDS = 0x0B06
+ CURRENT_TEXTURE_COORDS = 0x0B03
+ DEPTH_BIAS = 0x0D1F
+ DEPTH_BITS = 0x0D56
+ DEPTH_CLEAR_VALUE = 0x0B73
+ DEPTH_FUNC = 0x0B74
+ DEPTH_RANGE = 0x0B70
+ DEPTH_SCALE = 0x0D1E
+ DEPTH_WRITEMASK = 0x0B72
+ DOUBLEBUFFER = 0x0C32
+ DRAW_BUFFER = 0x0C01
+ EDGE_FLAG = 0x0B43
+ EDGE_FLAG_ARRAY_STRIDE = 0x808C
+ FEEDBACK_BUFFER_SIZE = 0x0DF1
+ FEEDBACK_BUFFER_TYPE = 0x0DF2
+ FOG_HINT = 0x0C54
+ FRONT_FACE = 0x0B46
+ GREEN_BIAS = 0x0D19
+ GREEN_BITS = 0x0D53
+ GREEN_SCALE = 0x0D18
+ INDEX_ARRAY_STRIDE = 0x8086
+ INDEX_ARRAY_TYPE = 0x8085
+ INDEX_BITS = 0x0D51
+ INDEX_CLEAR_VALUE = 0x0C20
+ INDEX_MODE = 0x0C30
+ INDEX_OFFSET = 0x0D13
+ INDEX_SHIFT = 0x0D12
+ INDEX_WRITEMASK = 0x0C21
+ LIGHT_MODEL_AMBIENT = 0x0B53
+ LIGHT_MODEL_LOCAL_VIEWER = 0x0B51
+ LIGHT_MODEL_TWO_SIDE = 0x0B52
+ LINE_SMOOTH_HINT = 0x0C52
+ LINE_STIPPLE_PATTERN = 0x0B25
+ LINE_STIPPLE_REPEAT = 0x0B26
+ LINE_WIDTH = 0x0B21
+ LINE_WIDTH_GRANULARITY = 0x0B23
+ LINE_WIDTH_RANGE = 0x0B22
+ LIST_BASE = 0x0B32
+ LIST_INDEX = 0x0B33
+ LIST_MODE = 0x0B30
+ LOGIC_OP_MODE = 0x0BF0
+ MAP1_GRID_DOMAIN = 0x0DD0
+ MAP1_GRID_SEGMENTS = 0x0DD1
+ MAP2_GRID_DOMAIN = 0x0DD2
+ MAP2_GRID_SEGMENTS = 0x0DD3
+ MAP_COLOR = 0x0D10
+ MAP_STENCIL = 0x0D11
+ MATRIX_MODE = 0x0BA0
+ MAX_ATTRIB_STACK_DEPTH = 0x0D35
+ MAX_CLIENT_ATTRIB_STACK_DEPTH = 0x0D3B
+ MAX_CLIP_PLANES = 0x0D32
+ MAX_EVAL_ORDER = 0x0D30
+ MAX_LIGHTS = 0x0D31
+ MAX_LIST_NESTING = 0x0B31
+ MAX_MODELVIEW_STACK_DEPTH = 0x0D36
+ MAX_NAME_STACK_DEPTH = 0x0D37
+ MAX_PIXEL_MAP_TABLE = 0x0D34
+ MAX_PROJECTION_STACK_DEPTH = 0x0D38
+ MAX_TEXTURE_SIZE = 0x0D33
+ MAX_TEXTURE_STACK_DEPTH = 0x0D39
+ MAX_VIEWPORT_DIMS = 0x0D3A
+ MODELVIEW_MATRIX = 0x0BA6
+ MODELVIEW_STACK_DEPTH = 0x0BA3
+ NAME_STACK_DEPTH = 0x0D70
+ NORMAL_ARRAY_STRIDE = 0x807F
+ NORMAL_ARRAY_TYPE = 0x807E
+ PACK_ALIGNMENT = 0x0D05
+ PACK_LSB_FIRST = 0x0D01
+ PACK_ROW_LENGTH = 0x0D02
+ PACK_SKIP_PIXELS = 0x0D04
+ PACK_SKIP_ROWS = 0x0D03
+ PACK_SWAP_BYTES = 0x0D00
+ PERSPECTIVE_CORRECTION_HINT = 0x0C50
+ PIXEL_MAP_A_TO_A_SIZE = 0x0CB9
+ PIXEL_MAP_B_TO_B_SIZE = 0x0CB8
+ PIXEL_MAP_G_TO_G_SIZE = 0x0CB7
+ PIXEL_MAP_I_TO_A_SIZE = 0x0CB5
+ PIXEL_MAP_I_TO_B_SIZE = 0x0CB4
+ PIXEL_MAP_I_TO_G_SIZE = 0x0CB3
+ PIXEL_MAP_I_TO_I_SIZE = 0x0CB0
+ PIXEL_MAP_I_TO_R_SIZE = 0x0CB2
+ PIXEL_MAP_R_TO_R_SIZE = 0x0CB6
+ PIXEL_MAP_S_TO_S_SIZE = 0x0CB1
+ POINT_SIZE = 0x0B11
+ POINT_SIZE_GRANULARITY = 0x0B13
+ POINT_SIZE_RANGE = 0x0B12
+ POINT_SMOOTH_HINT = 0x0C51
+ POLYGON_MODE = 0x0B40
+ POLYGON_OFFSET_FACTOR = 0x8038
+ POLYGON_OFFSET_UNITS = 0x2A00
+ POLYGON_SMOOTH_HINT = 0x0C53
+ PROJECTION_MATRIX = 0x0BA7
+ PROJECTION_STACK_DEPTH = 0x0BA4
+ READ_BUFFER = 0x0C02
+ RED_BIAS = 0x0D15
+ RED_BITS = 0x0D52
+ RED_SCALE = 0x0D14
+ RENDER_MODE = 0x0C40
+ RGBA_MODE = 0x0C31
+ SCISSOR_BOX = 0x0C10
+ SELECTION_BUFFER_SIZE = 0x0DF4
+ SHADE_MODEL = 0x0B54
+ STENCIL_BITS = 0x0D57
+ STENCIL_CLEAR_VALUE = 0x0B91
+ STENCIL_FAIL = 0x0B94
+ STENCIL_FUNC = 0x0B92
+ STENCIL_PASS_DEPTH_FAIL = 0x0B95
+ STENCIL_PASS_DEPTH_PASS = 0x0B96
+ STENCIL_REF = 0x0B97
+ STENCIL_VALUE_MASK = 0x0B93
+ STENCIL_WRITEMASK = 0x0B98
+ STEREO = 0x0C33
+ SUBPIXEL_BITS = 0x0D50
+ TEXTURE_BINDING_1D = 0x8068
+ TEXTURE_BINDING_2D = 0x8069
+ TEXTURE_COORD_ARRAY_SIZE = 0x8088
+ TEXTURE_COORD_ARRAY_STRIDE = 0x808A
+ TEXTURE_COORD_ARRAY_TYPE = 0x8089
+ TEXTURE_MATRIX = 0x0BA8
+ TEXTURE_STACK_DEPTH = 0x0BA5
+ UNPACK_ALIGNMENT = 0x0CF5
+ UNPACK_LSB_FIRST = 0x0CF1
+ UNPACK_ROW_LENGTH = 0x0CF2
+ UNPACK_SKIP_PIXELS = 0x0CF4
+ UNPACK_SKIP_ROWS = 0x0CF3
+ UNPACK_SWAP_BYTES = 0x0CF0
+ VERTEX_ARRAY_SIZE = 0x807A
+ VERTEX_ARRAY_STRIDE = 0x807C
+ VERTEX_ARRAY_TYPE = 0x807B
+ VIEWPORT = 0x0BA2
+ ZOOM_X = 0x0D16
+ ZOOM_Y = 0x0D17
+
+ COLOR_ARRAY_POINTER = 0x8090
+ EDGE_FLAG_ARRAY_POINTER = 0x8093
+ FEEDBACK_BUFFER_POINTER = 0x0DF0
+ INDEX_ARRAY_POINTER = 0x8091
+ NORMAL_ARRAY_POINTER = 0x808F
+ SELECTION_BUFFER_POINTER = 0x0DF3
+ TEXTURE_COORD_ARRAY_POINTER = 0x8092
+ VERTEX_ARRAY_POINTER = 0x808E
+
+ TEXTURE_ALPHA_SIZE = 0x805F
+ TEXTURE_BLUE_SIZE = 0x805E
+ TEXTURE_BORDER = 0x1005
+ TEXTURE_BORDER_COLOR = 0x1004
+ TEXTURE_COMPONENTS = 0x1003
+ TEXTURE_GREEN_SIZE = 0x805D
+ TEXTURE_HEIGHT = 0x1001
+ TEXTURE_INTENSITY_SIZE = 0x8061
+ TEXTURE_INTERNAL_FORMAT = 0x1003
+ TEXTURE_LUMINANCE_SIZE = 0x8060
+ TEXTURE_MAG_FILTER = 0x2800
+ TEXTURE_MIN_FILTER = 0x2801
+ TEXTURE_PRIORITY = 0x8066
+ TEXTURE_RED_SIZE = 0x805C
+ TEXTURE_RESIDENT = 0x8067
+ TEXTURE_WIDTH = 0x1000
+ TEXTURE_WRAP_S = 0x2802
+ TEXTURE_WRAP_T = 0x2803
+
+ DONT_CARE = 0x1100
+ FASTEST = 0x1101
+ NICEST = 0x1102
+
+ C3F_V3F = 0x2A24
+ C4F_N3F_V3F = 0x2A26
+ C4UB_V2F = 0x2A22
+ C4UB_V3F = 0x2A23
+ N3F_V3F = 0x2A25
+ T2F_C3F_V3F = 0x2A2A
+ T2F_C4F_N3F_V3F = 0x2A2C
+ T2F_C4UB_V3F = 0x2A29
+ T2F_N3F_V3F = 0x2A2B
+ T2F_V3F = 0x2A27
+ T4F_C4F_N3F_V4F = 0x2A2D
+ T4F_V4F = 0x2A28
+ V2F = 0x2A20
+ V3F = 0x2A21
+
+ MODULATE = 0x2100
+ REPLACE = 0x1E01
+
+ CONSTANT_ATTENUATION = 0x1207
+ LINEAR_ATTENUATION = 0x1208
+ POSITION = 0x1203
+ QUADRATIC_ATTENUATION = 0x1209
+ SPOT_CUTOFF = 0x1206
+ SPOT_DIRECTION = 0x1204
+ SPOT_EXPONENT = 0x1205
+
+ COMPILE = 0x1300
+ COMPILE_AND_EXECUTE = 0x1301
+
+ AND = 0x1501
+ AND_INVERTED = 0x1504
+ AND_REVERSE = 0x1502
+ CLEAR = 0x1500
+ COPY = 0x1503
+ COPY_INVERTED = 0x150C
+ EQUIV = 0x1509
+ INVERT = 0x150A
+ NAND = 0x150E
+ NOOP = 0x1505
+ NOR = 0x1508
+ OR = 0x1507
+ OR_INVERTED = 0x150D
+ OR_REVERSE = 0x150B
+ SET = 0x150F
+ XOR = 0x1506
+
+ COLOR_INDEXES = 0x1603
+ SHININESS = 0x1601
+
+ MODELVIEW = 0x1700
+ PROJECTION = 0x1701
+ TEXTURE = 0x1702
+
+ LINE = 0x1B01
+ POINT = 0x1B00
+
+ FILL = 0x1B02
+
+ COLOR = 0x1800
+ DEPTH = 0x1801
+ STENCIL = 0x1802
+
+ ALPHA = 0x1906
+ BLUE = 0x1905
+ COLOR_INDEX = 0x1900
+ DEPTH_COMPONENT = 0x1902
+ GREEN = 0x1904
+ LUMINANCE = 0x1909
+ LUMINANCE_ALPHA = 0x190A
+ RED = 0x1903
+ RGB = 0x1907
+ RGBA = 0x1908
+ STENCIL_INDEX = 0x1901
+
+ ALPHA12 = 0x803D
+ ALPHA16 = 0x803E
+ ALPHA4 = 0x803B
+ ALPHA8 = 0x803C
+ INTENSITY = 0x8049
+ INTENSITY12 = 0x804C
+ INTENSITY16 = 0x804D
+ INTENSITY4 = 0x804A
+ INTENSITY8 = 0x804B
+ LUMINANCE12 = 0x8041
+ LUMINANCE12_ALPHA12 = 0x8047
+ LUMINANCE12_ALPHA4 = 0x8046
+ LUMINANCE16 = 0x8042
+ LUMINANCE16_ALPHA16 = 0x8048
+ LUMINANCE4 = 0x803F
+ LUMINANCE4_ALPHA4 = 0x8043
+ LUMINANCE6_ALPHA2 = 0x8044
+ LUMINANCE8 = 0x8040
+ LUMINANCE8_ALPHA8 = 0x8045
+ R3_G3_B2 = 0x2A10
+ RGB10 = 0x8052
+ RGB10_A2 = 0x8059
+ RGB12 = 0x8053
+ RGB16 = 0x8054
+ RGB4 = 0x804F
+ RGB5 = 0x8050
+ RGB5_A1 = 0x8057
+ RGB8 = 0x8051
+ RGBA12 = 0x805A
+ RGBA16 = 0x805B
+ RGBA2 = 0x8055
+ RGBA4 = 0x8056
+ RGBA8 = 0x8058
+
+ BITMAP = 0x1A00
+
+ LINES = 0x0001
+ LINE_LOOP = 0x0002
+ LINE_STRIP = 0x0003
+ POINTS = 0x0000
+ POLYGON = 0x0009
+ QUADS = 0x0007
+ QUAD_STRIP = 0x0008
+ TRIANGLES = 0x0004
+ TRIANGLE_FAN = 0x0006
+ TRIANGLE_STRIP = 0x0005
+
+ FEEDBACK = 0x1C01
+ RENDER = 0x1C00
+ SELECT = 0x1C02
+
+ FLAT = 0x1D00
+ SMOOTH = 0x1D01
+
+ DECR = 0x1E03
+ INCR = 0x1E02
+ KEEP = 0x1E00
+
+ EXTENSIONS = 0x1F03
+ RENDERER = 0x1F01
+ VENDOR = 0x1F00
+ VERSION = 0x1F02
+
+ S = 0x2000
+ T = 0x2001
+ R = 0x2002
+ Q = 0x2003
+
+ DECAL = 0x2101
+
+ TEXTURE_ENV_COLOR = 0x2201
+ TEXTURE_ENV_MODE = 0x2200
+
+ TEXTURE_ENV = 0x2300
+
+ EYE_LINEAR = 0x2400
+ OBJECT_LINEAR = 0x2401
+ SPHERE_MAP = 0x2402
+
+ EYE_PLANE = 0x2502
+ OBJECT_PLANE = 0x2501
+ TEXTURE_GEN_MODE = 0x2500
+
+ NEAREST = 0x2600
+
+ LINEAR_MIPMAP_LINEAR = 0x2703
+ LINEAR_MIPMAP_NEAREST = 0x2701
+ NEAREST_MIPMAP_LINEAR = 0x2702
+ NEAREST_MIPMAP_NEAREST = 0x2700
+
+ PROXY_TEXTURE_1D = 0x8063
+ PROXY_TEXTURE_2D = 0x8064
+
+ CLAMP = 0x2900
+ REPEAT = 0x2901
+)
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glViewport.xml
+func (gl *GL) Viewport(x, y, width, height int) {
+ C.gl1_1_glViewport(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// DepthRange specifies the mapping of depth values from normalized device
+// coordinates to window coordinates.
+//
+// Parameter nearVal specifies the mapping of the near clipping plane to window
+// coordinates (defaults to 0), while farVal specifies the mapping of the far
+// clipping plane to window coordinates (defaults to 1).
+//
+// After clipping and division by w, depth coordinates range from -1 to 1,
+// corresponding to the near and far clipping planes. DepthRange specifies a
+// linear mapping of the normalized depth coordinates in this range to window
+// depth coordinates. Regardless of the actual depth buffer implementation,
+// window coordinate depth values are treated as though they range from 0 through 1
+// (like color components). Thus, the values accepted by DepthRange are both
+// clamped to this range before they are accepted.
+//
+// The default setting of (0, 1) maps the near plane to 0 and the far plane to 1.
+// With this mapping, the depth buffer range is fully utilized.
+//
+// It is not necessary that nearVal be less than farVal. Reverse mappings such as
+// nearVal 1, and farVal 0 are acceptable.
+//
+// GL.INVALID_OPERATION is generated if DepthRange is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) DepthRange(nearVal, farVal float64) {
+ C.gl1_1_glDepthRange(gl.funcs, C.GLdouble(nearVal), C.GLdouble(farVal))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIsEnabled.xml
+func (gl *GL) IsEnabled(cap glbase.Enum) bool {
+ glresult := C.gl1_1_glIsEnabled(gl.funcs, C.GLenum(cap))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexLevelParameteriv.xml
+func (gl *GL) GetTexLevelParameteriv(target glbase.Enum, level int, pname glbase.Enum, params []int32) {
+ C.gl1_1_glGetTexLevelParameteriv(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexLevelParameterfv.xml
+func (gl *GL) GetTexLevelParameterfv(target glbase.Enum, level int, pname glbase.Enum, params []float32) {
+ C.gl1_1_glGetTexLevelParameterfv(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexParameteriv.xml
+func (gl *GL) GetTexParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl1_1_glGetTexParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexParameterfv.xml
+func (gl *GL) GetTexParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl1_1_glGetTexParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexImage.xml
+func (gl *GL) GetTexImage(target glbase.Enum, level int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_1_glGetTexImage(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetIntegerv.xml
+func (gl *GL) GetIntegerv(pname glbase.Enum, params []int32) {
+ C.gl1_1_glGetIntegerv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetFloatv.xml
+func (gl *GL) GetFloatv(pname glbase.Enum, params []float32) {
+ C.gl1_1_glGetFloatv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetError.xml
+func (gl *GL) GetError() glbase.Enum {
+ glresult := C.gl1_1_glGetError(gl.funcs)
+ return glbase.Enum(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetDoublev.xml
+func (gl *GL) GetDoublev(pname glbase.Enum, params []float64) {
+ C.gl1_1_glGetDoublev(gl.funcs, C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetBooleanv.xml
+func (gl *GL) GetBooleanv(pname glbase.Enum, params []bool) {
+ C.gl1_1_glGetBooleanv(gl.funcs, C.GLenum(pname), (*C.GLboolean)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glReadPixels.xml
+func (gl *GL) ReadPixels(x, y, width, height int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_1_glReadPixels(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glReadBuffer.xml
+func (gl *GL) ReadBuffer(mode glbase.Enum) {
+ C.gl1_1_glReadBuffer(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelStorei.xml
+func (gl *GL) PixelStorei(pname glbase.Enum, param int32) {
+ C.gl1_1_glPixelStorei(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelStoref.xml
+func (gl *GL) PixelStoref(pname glbase.Enum, param float32) {
+ C.gl1_1_glPixelStoref(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDepthFunc.xml
+func (gl *GL) DepthFunc(glfunc glbase.Enum) {
+ C.gl1_1_glDepthFunc(gl.funcs, C.GLenum(glfunc))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glStencilOp.xml
+func (gl *GL) StencilOp(fail, zfail, zpass glbase.Enum) {
+ C.gl1_1_glStencilOp(gl.funcs, C.GLenum(fail), C.GLenum(zfail), C.GLenum(zpass))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glStencilFunc.xml
+func (gl *GL) StencilFunc(glfunc glbase.Enum, ref int32, mask uint32) {
+ C.gl1_1_glStencilFunc(gl.funcs, C.GLenum(glfunc), C.GLint(ref), C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLogicOp.xml
+func (gl *GL) LogicOp(opcode glbase.Enum) {
+ C.gl1_1_glLogicOp(gl.funcs, C.GLenum(opcode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBlendFunc.xml
+func (gl *GL) BlendFunc(sfactor, dfactor glbase.Enum) {
+ C.gl1_1_glBlendFunc(gl.funcs, C.GLenum(sfactor), C.GLenum(dfactor))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFlush.xml
+func (gl *GL) Flush() {
+ C.gl1_1_glFlush(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFinish.xml
+func (gl *GL) Finish() {
+ C.gl1_1_glFinish(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEnable.xml
+func (gl *GL) Enable(cap glbase.Enum) {
+ C.gl1_1_glEnable(gl.funcs, C.GLenum(cap))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDisable.xml
+func (gl *GL) Disable(cap glbase.Enum) {
+ C.gl1_1_glDisable(gl.funcs, C.GLenum(cap))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDepthMask.xml
+func (gl *GL) DepthMask(flag bool) {
+ C.gl1_1_glDepthMask(gl.funcs, *(*C.GLboolean)(unsafe.Pointer(&flag)))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColorMask.xml
+func (gl *GL) ColorMask(red, green, blue, alpha bool) {
+ C.gl1_1_glColorMask(gl.funcs, *(*C.GLboolean)(unsafe.Pointer(&red)), *(*C.GLboolean)(unsafe.Pointer(&green)), *(*C.GLboolean)(unsafe.Pointer(&blue)), *(*C.GLboolean)(unsafe.Pointer(&alpha)))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glStencilMask.xml
+func (gl *GL) StencilMask(mask uint32) {
+ C.gl1_1_glStencilMask(gl.funcs, C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClearDepth.xml
+func (gl *GL) ClearDepth(depth float64) {
+ C.gl1_1_glClearDepth(gl.funcs, C.GLdouble(depth))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClearStencil.xml
+func (gl *GL) ClearStencil(s int32) {
+ C.gl1_1_glClearStencil(gl.funcs, C.GLint(s))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClearColor.xml
+func (gl *GL) ClearColor(red, green, blue, alpha float32) {
+ C.gl1_1_glClearColor(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClear.xml
+func (gl *GL) Clear(mask glbase.Bitfield) {
+ C.gl1_1_glClear(gl.funcs, C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDrawBuffer.xml
+func (gl *GL) DrawBuffer(mode glbase.Enum) {
+ C.gl1_1_glDrawBuffer(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexImage2D.xml
+func (gl *GL) TexImage2D(target glbase.Enum, level int, internalFormat int32, width, height, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_1_glTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexImage1D.xml
+func (gl *GL) TexImage1D(target glbase.Enum, level int, internalFormat int32, width, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_1_glTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexParameteriv.xml
+func (gl *GL) TexParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl1_1_glTexParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexParameteri.xml
+func (gl *GL) TexParameteri(target, pname glbase.Enum, param int32) {
+ C.gl1_1_glTexParameteri(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexParameterfv.xml
+func (gl *GL) TexParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl1_1_glTexParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexParameterf.xml
+func (gl *GL) TexParameterf(target, pname glbase.Enum, param float32) {
+ C.gl1_1_glTexParameterf(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glScissor.xml
+func (gl *GL) Scissor(x, y, width, height int) {
+ C.gl1_1_glScissor(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPolygonMode.xml
+func (gl *GL) PolygonMode(face, mode glbase.Enum) {
+ C.gl1_1_glPolygonMode(gl.funcs, C.GLenum(face), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPointSize.xml
+func (gl *GL) PointSize(size float32) {
+ C.gl1_1_glPointSize(gl.funcs, C.GLfloat(size))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLineWidth.xml
+func (gl *GL) LineWidth(width float32) {
+ C.gl1_1_glLineWidth(gl.funcs, C.GLfloat(width))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glHint.xml
+func (gl *GL) Hint(target, mode glbase.Enum) {
+ C.gl1_1_glHint(gl.funcs, C.GLenum(target), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFrontFace.xml
+func (gl *GL) FrontFace(mode glbase.Enum) {
+ C.gl1_1_glFrontFace(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCullFace.xml
+func (gl *GL) CullFace(mode glbase.Enum) {
+ C.gl1_1_glCullFace(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexubv.xml
+func (gl *GL) Indexubv(c []uint8) {
+ C.gl1_1_glIndexubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexub.xml
+func (gl *GL) Indexub(c uint8) {
+ C.gl1_1_glIndexub(gl.funcs, C.GLubyte(c))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIsTexture.xml
+func (gl *GL) IsTexture(texture glbase.Texture) bool {
+ glresult := C.gl1_1_glIsTexture(gl.funcs, C.GLuint(texture))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// GenTextures returns n texture names in textures. There is no guarantee
+// that the names form a contiguous set of integers; however, it is
+// guaranteed that none of the returned names was in use immediately before
+// the call to GenTextures.
+//
+// The generated textures have no dimensionality; they assume the
+// dimensionality of the texture target to which they are first bound (see
+// BindTexture).
+//
+// Texture names returned by a call to GenTextures are not returned by
+// subsequent calls, unless they are first deleted with DeleteTextures.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// GenTextures is available in GL version 2.0 or greater.
+func (gl *GL) GenTextures(n int) []glbase.Texture {
+ if n == 0 {
+ return nil
+ }
+ textures := make([]glbase.Texture, n)
+ C.gl1_1_glGenTextures(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])))
+ return textures
+}
+
+// DeleteTextures deletes the textures objects whose names are stored
+// in the textures slice. After a texture is deleted, it has no contents or
+// dimensionality, and its name is free for reuse (for example by
+// GenTextures). If a texture that is currently bound is deleted, the binding
+// reverts to 0 (the default texture).
+//
+// DeleteTextures silently ignores 0's and names that do not correspond to
+// existing textures.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// DeleteTextures is available in GL version 2.0 or greater.
+func (gl *GL) DeleteTextures(textures []glbase.Texture) {
+ n := len(textures)
+ if n == 0 {
+ return
+ }
+ C.gl1_1_glDeleteTextures(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBindTexture.xml
+func (gl *GL) BindTexture(target glbase.Enum, texture glbase.Texture) {
+ C.gl1_1_glBindTexture(gl.funcs, C.GLenum(target), C.GLuint(texture))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexSubImage2D.xml
+func (gl *GL) TexSubImage2D(target glbase.Enum, level, xoffset, yoffset, width, height int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_1_glTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexSubImage1D.xml
+func (gl *GL) TexSubImage1D(target glbase.Enum, level, xoffset, width int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_1_glTexSubImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLsizei(width), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyTexSubImage2D.xml
+func (gl *GL) CopyTexSubImage2D(target glbase.Enum, level, xoffset, yoffset, x, y, width, height int) {
+ C.gl1_1_glCopyTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyTexSubImage1D.xml
+func (gl *GL) CopyTexSubImage1D(target glbase.Enum, level, xoffset, x, y, width int) {
+ C.gl1_1_glCopyTexSubImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(x), C.GLint(y), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyTexImage2D.xml
+func (gl *GL) CopyTexImage2D(target glbase.Enum, level int, internalFormat glbase.Enum, x, y, width, height, border int) {
+ C.gl1_1_glCopyTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height), C.GLint(border))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyTexImage1D.xml
+func (gl *GL) CopyTexImage1D(target glbase.Enum, level int, internalFormat glbase.Enum, x, y, width, border int) {
+ C.gl1_1_glCopyTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLint(border))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPolygonOffset.xml
+func (gl *GL) PolygonOffset(factor, units float32) {
+ C.gl1_1_glPolygonOffset(gl.funcs, C.GLfloat(factor), C.GLfloat(units))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDrawElements.xml
+func (gl *GL) DrawElements(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_1_glDrawElements(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDrawArrays.xml
+func (gl *GL) DrawArrays(mode glbase.Enum, first, count int) {
+ C.gl1_1_glDrawArrays(gl.funcs, C.GLenum(mode), C.GLint(first), C.GLsizei(count))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTranslatef.xml
+func (gl *GL) Translatef(x, y, z float32) {
+ C.gl1_1_glTranslatef(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTranslated.xml
+func (gl *GL) Translated(x, y, z float64) {
+ C.gl1_1_glTranslated(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glScalef.xml
+func (gl *GL) Scalef(x, y, z float32) {
+ C.gl1_1_glScalef(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glScaled.xml
+func (gl *GL) Scaled(x, y, z float64) {
+ C.gl1_1_glScaled(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRotatef.xml
+func (gl *GL) Rotatef(angle, x, y, z float32) {
+ C.gl1_1_glRotatef(gl.funcs, C.GLfloat(angle), C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRotated.xml
+func (gl *GL) Rotated(angle, x, y, z float64) {
+ C.gl1_1_glRotated(gl.funcs, C.GLdouble(angle), C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPushMatrix.xml
+func (gl *GL) PushMatrix() {
+ C.gl1_1_glPushMatrix(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPopMatrix.xml
+func (gl *GL) PopMatrix() {
+ C.gl1_1_glPopMatrix(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glOrtho.xml
+func (gl *GL) Ortho(left, right, bottom, top, zNear, zFar float64) {
+ C.gl1_1_glOrtho(gl.funcs, C.GLdouble(left), C.GLdouble(right), C.GLdouble(bottom), C.GLdouble(top), C.GLdouble(zNear), C.GLdouble(zFar))
+}
+
+// MultMatrixd multiplies the current matrix with the provided matrix.
+//
+// The m parameter must hold 16 consecutive elements of a 4x4 column-major matrix.
+//
+// The current matrix is determined by the current matrix mode (see
+// MatrixMode). It is either the projection matrix, modelview matrix, or the
+// texture matrix.
+//
+// For example, if the current matrix is C and the coordinates to be transformed
+// are v = (v[0], v[1], v[2], v[3]), then the current transformation is C × v, or
+//
+// c[0] c[4] c[8] c[12] v[0]
+// c[1] c[5] c[9] c[13] v[1]
+// c[2] c[6] c[10] c[14] X v[2]
+// c[3] c[7] c[11] c[15] v[3]
+//
+// Calling MultMatrix with an argument of m = m[0], m[1], ..., m[15]
+// replaces the current transformation with (C X M) x v, or
+//
+// c[0] c[4] c[8] c[12] m[0] m[4] m[8] m[12] v[0]
+// c[1] c[5] c[9] c[13] m[1] m[5] m[9] m[13] v[1]
+// c[2] c[6] c[10] c[14] X m[2] m[6] m[10] m[14] X v[2]
+// c[3] c[7] c[11] c[15] m[3] m[7] m[11] m[15] v[3]
+//
+// Where 'X' denotes matrix multiplication, and v is represented as a 4x1 matrix.
+//
+// While the elements of the matrix may be specified with single or double
+// precision, the GL may store or operate on these values in less-than-single
+// precision.
+//
+// In many computer languages, 4×4 arrays are represented in row-major
+// order. The transformations just described represent these matrices in
+// column-major order. The order of the multiplication is important. For
+// example, if the current transformation is a rotation, and MultMatrix is
+// called with a translation matrix, the translation is done directly on the
+// coordinates to be transformed, while the rotation is done on the results
+// of that translation.
+//
+// GL.INVALID_OPERATION is generated if MultMatrix is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) MultMatrixd(m []float64) {
+ if len(m) != 16 {
+ panic("parameter m must have length 16 for the 4x4 matrix")
+ }
+ C.gl1_1_glMultMatrixd(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&m[0])))
+}
+
+// MultMatrixf multiplies the current matrix with the provided matrix.
+//
+// The m parameter must hold 16 consecutive elements of a 4x4 column-major matrix.
+//
+// The current matrix is determined by the current matrix mode (see
+// MatrixMode). It is either the projection matrix, modelview matrix, or the
+// texture matrix.
+//
+// For example, if the current matrix is C and the coordinates to be transformed
+// are v = (v[0], v[1], v[2], v[3]), then the current transformation is C × v, or
+//
+// c[0] c[4] c[8] c[12] v[0]
+// c[1] c[5] c[9] c[13] v[1]
+// c[2] c[6] c[10] c[14] X v[2]
+// c[3] c[7] c[11] c[15] v[3]
+//
+// Calling MultMatrix with an argument of m = m[0], m[1], ..., m[15]
+// replaces the current transformation with (C X M) x v, or
+//
+// c[0] c[4] c[8] c[12] m[0] m[4] m[8] m[12] v[0]
+// c[1] c[5] c[9] c[13] m[1] m[5] m[9] m[13] v[1]
+// c[2] c[6] c[10] c[14] X m[2] m[6] m[10] m[14] X v[2]
+// c[3] c[7] c[11] c[15] m[3] m[7] m[11] m[15] v[3]
+//
+// Where 'X' denotes matrix multiplication, and v is represented as a 4x1 matrix.
+//
+// While the elements of the matrix may be specified with single or double
+// precision, the GL may store or operate on these values in less-than-single
+// precision.
+//
+// In many computer languages, 4×4 arrays are represented in row-major
+// order. The transformations just described represent these matrices in
+// column-major order. The order of the multiplication is important. For
+// example, if the current transformation is a rotation, and MultMatrix is
+// called with a translation matrix, the translation is done directly on the
+// coordinates to be transformed, while the rotation is done on the results
+// of that translation.
+//
+// GL.INVALID_OPERATION is generated if MultMatrix is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) MultMatrixf(m []float32) {
+ if len(m) != 16 {
+ panic("parameter m must have length 16 for the 4x4 matrix")
+ }
+ C.gl1_1_glMultMatrixf(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMatrixMode.xml
+func (gl *GL) MatrixMode(mode glbase.Enum) {
+ C.gl1_1_glMatrixMode(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLoadMatrixd.xml
+func (gl *GL) LoadMatrixd(m []float64) {
+ C.gl1_1_glLoadMatrixd(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLoadMatrixf.xml
+func (gl *GL) LoadMatrixf(m []float32) {
+ C.gl1_1_glLoadMatrixf(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLoadIdentity.xml
+func (gl *GL) LoadIdentity() {
+ C.gl1_1_glLoadIdentity(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFrustum.xml
+func (gl *GL) Frustum(left, right, bottom, top, zNear, zFar float64) {
+ C.gl1_1_glFrustum(gl.funcs, C.GLdouble(left), C.GLdouble(right), C.GLdouble(bottom), C.GLdouble(top), C.GLdouble(zNear), C.GLdouble(zFar))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIsList.xml
+func (gl *GL) IsList(list uint32) bool {
+ glresult := C.gl1_1_glIsList(gl.funcs, C.GLuint(list))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexGeniv.xml
+func (gl *GL) GetTexGeniv(coord, pname glbase.Enum, params []int32) {
+ C.gl1_1_glGetTexGeniv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexGenfv.xml
+func (gl *GL) GetTexGenfv(coord, pname glbase.Enum, params []float32) {
+ C.gl1_1_glGetTexGenfv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexGendv.xml
+func (gl *GL) GetTexGendv(coord, pname glbase.Enum, params []float64) {
+ C.gl1_1_glGetTexGendv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexEnviv.xml
+func (gl *GL) GetTexEnviv(target, pname glbase.Enum, params []int32) {
+ C.gl1_1_glGetTexEnviv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexEnvfv.xml
+func (gl *GL) GetTexEnvfv(target, pname glbase.Enum, params []float32) {
+ C.gl1_1_glGetTexEnvfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetPolygonStipple.xml
+func (gl *GL) GetPolygonStipple(mask []uint8) {
+ C.gl1_1_glGetPolygonStipple(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&mask[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetPixelMapusv.xml
+func (gl *GL) GetPixelMapusv(glmap glbase.Enum, values []uint16) {
+ C.gl1_1_glGetPixelMapusv(gl.funcs, C.GLenum(glmap), (*C.GLushort)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetPixelMapuiv.xml
+func (gl *GL) GetPixelMapuiv(glmap glbase.Enum, values []uint32) {
+ C.gl1_1_glGetPixelMapuiv(gl.funcs, C.GLenum(glmap), (*C.GLuint)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetPixelMapfv.xml
+func (gl *GL) GetPixelMapfv(glmap glbase.Enum, values []float32) {
+ C.gl1_1_glGetPixelMapfv(gl.funcs, C.GLenum(glmap), (*C.GLfloat)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetMaterialiv.xml
+func (gl *GL) GetMaterialiv(face, pname glbase.Enum, params []int32) {
+ C.gl1_1_glGetMaterialiv(gl.funcs, C.GLenum(face), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetMaterialfv.xml
+func (gl *GL) GetMaterialfv(face, pname glbase.Enum, params []float32) {
+ C.gl1_1_glGetMaterialfv(gl.funcs, C.GLenum(face), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetMapiv.xml
+func (gl *GL) GetMapiv(target, query glbase.Enum, v []int32) {
+ C.gl1_1_glGetMapiv(gl.funcs, C.GLenum(target), C.GLenum(query), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetMapfv.xml
+func (gl *GL) GetMapfv(target, query glbase.Enum, v []float32) {
+ C.gl1_1_glGetMapfv(gl.funcs, C.GLenum(target), C.GLenum(query), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetMapdv.xml
+func (gl *GL) GetMapdv(target, query glbase.Enum, v []float64) {
+ C.gl1_1_glGetMapdv(gl.funcs, C.GLenum(target), C.GLenum(query), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetLightiv.xml
+func (gl *GL) GetLightiv(light, pname glbase.Enum, params []int32) {
+ C.gl1_1_glGetLightiv(gl.funcs, C.GLenum(light), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetLightfv.xml
+func (gl *GL) GetLightfv(light, pname glbase.Enum, params []float32) {
+ C.gl1_1_glGetLightfv(gl.funcs, C.GLenum(light), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetClipPlane.xml
+func (gl *GL) GetClipPlane(plane glbase.Enum, equation []float64) {
+ C.gl1_1_glGetClipPlane(gl.funcs, C.GLenum(plane), (*C.GLdouble)(unsafe.Pointer(&equation[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDrawPixels.xml
+func (gl *GL) DrawPixels(width, height int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_1_glDrawPixels(gl.funcs, C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyPixels.xml
+func (gl *GL) CopyPixels(x, y, width, height int, gltype glbase.Enum) {
+ C.gl1_1_glCopyPixels(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height), C.GLenum(gltype))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelMapusv.xml
+func (gl *GL) PixelMapusv(glmap glbase.Enum, mapsize int32, values []uint16) {
+ C.gl1_1_glPixelMapusv(gl.funcs, C.GLenum(glmap), C.GLint(mapsize), (*C.GLushort)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelMapuiv.xml
+func (gl *GL) PixelMapuiv(glmap glbase.Enum, mapsize int32, values []uint32) {
+ C.gl1_1_glPixelMapuiv(gl.funcs, C.GLenum(glmap), C.GLint(mapsize), (*C.GLuint)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelMapfv.xml
+func (gl *GL) PixelMapfv(glmap glbase.Enum, mapsize int32, values []float32) {
+ C.gl1_1_glPixelMapfv(gl.funcs, C.GLenum(glmap), C.GLint(mapsize), (*C.GLfloat)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelTransferi.xml
+func (gl *GL) PixelTransferi(pname glbase.Enum, param int32) {
+ C.gl1_1_glPixelTransferi(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelTransferf.xml
+func (gl *GL) PixelTransferf(pname glbase.Enum, param float32) {
+ C.gl1_1_glPixelTransferf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelZoom.xml
+func (gl *GL) PixelZoom(xfactor, yfactor float32) {
+ C.gl1_1_glPixelZoom(gl.funcs, C.GLfloat(xfactor), C.GLfloat(yfactor))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glAlphaFunc.xml
+func (gl *GL) AlphaFunc(glfunc glbase.Enum, ref float32) {
+ C.gl1_1_glAlphaFunc(gl.funcs, C.GLenum(glfunc), C.GLfloat(ref))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalPoint2.xml
+func (gl *GL) EvalPoint2(i, j int32) {
+ C.gl1_1_glEvalPoint2(gl.funcs, C.GLint(i), C.GLint(j))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalMesh2.xml
+func (gl *GL) EvalMesh2(mode glbase.Enum, i1, i2, j1, j2 int32) {
+ C.gl1_1_glEvalMesh2(gl.funcs, C.GLenum(mode), C.GLint(i1), C.GLint(i2), C.GLint(j1), C.GLint(j2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalPoint1.xml
+func (gl *GL) EvalPoint1(i int32) {
+ C.gl1_1_glEvalPoint1(gl.funcs, C.GLint(i))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalMesh1.xml
+func (gl *GL) EvalMesh1(mode glbase.Enum, i1, i2 int32) {
+ C.gl1_1_glEvalMesh1(gl.funcs, C.GLenum(mode), C.GLint(i1), C.GLint(i2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord2fv.xml
+func (gl *GL) EvalCoord2fv(u []float32) {
+ if len(u) != 2 {
+ panic("parameter u has incorrect length")
+ }
+ C.gl1_1_glEvalCoord2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&u[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord2f.xml
+func (gl *GL) EvalCoord2f(u, v float32) {
+ C.gl1_1_glEvalCoord2f(gl.funcs, C.GLfloat(u), C.GLfloat(v))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord2dv.xml
+func (gl *GL) EvalCoord2dv(u []float64) {
+ if len(u) != 2 {
+ panic("parameter u has incorrect length")
+ }
+ C.gl1_1_glEvalCoord2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&u[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord2d.xml
+func (gl *GL) EvalCoord2d(u, v float64) {
+ C.gl1_1_glEvalCoord2d(gl.funcs, C.GLdouble(u), C.GLdouble(v))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord1fv.xml
+func (gl *GL) EvalCoord1fv(u []float32) {
+ C.gl1_1_glEvalCoord1fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&u[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord1f.xml
+func (gl *GL) EvalCoord1f(u float32) {
+ C.gl1_1_glEvalCoord1f(gl.funcs, C.GLfloat(u))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord1dv.xml
+func (gl *GL) EvalCoord1dv(u []float64) {
+ C.gl1_1_glEvalCoord1dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&u[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord1d.xml
+func (gl *GL) EvalCoord1d(u float64) {
+ C.gl1_1_glEvalCoord1d(gl.funcs, C.GLdouble(u))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMapGrid2f.xml
+func (gl *GL) MapGrid2f(un int32, u1, u2 float32, vn int32, v1, v2 float32) {
+ C.gl1_1_glMapGrid2f(gl.funcs, C.GLint(un), C.GLfloat(u1), C.GLfloat(u2), C.GLint(vn), C.GLfloat(v1), C.GLfloat(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMapGrid2d.xml
+func (gl *GL) MapGrid2d(un int32, u1, u2 float64, vn int32, v1, v2 float64) {
+ C.gl1_1_glMapGrid2d(gl.funcs, C.GLint(un), C.GLdouble(u1), C.GLdouble(u2), C.GLint(vn), C.GLdouble(v1), C.GLdouble(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMapGrid1f.xml
+func (gl *GL) MapGrid1f(un int32, u1, u2 float32) {
+ C.gl1_1_glMapGrid1f(gl.funcs, C.GLint(un), C.GLfloat(u1), C.GLfloat(u2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMapGrid1d.xml
+func (gl *GL) MapGrid1d(un int32, u1, u2 float64) {
+ C.gl1_1_glMapGrid1d(gl.funcs, C.GLint(un), C.GLdouble(u1), C.GLdouble(u2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMap2f.xml
+func (gl *GL) Map2f(target glbase.Enum, u1, u2 float32, ustride, uorder int32, v1, v2 float32, vstride, vorder int32, points []float32) {
+ C.gl1_1_glMap2f(gl.funcs, C.GLenum(target), C.GLfloat(u1), C.GLfloat(u2), C.GLint(ustride), C.GLint(uorder), C.GLfloat(v1), C.GLfloat(v2), C.GLint(vstride), C.GLint(vorder), (*C.GLfloat)(unsafe.Pointer(&points[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMap2d.xml
+func (gl *GL) Map2d(target glbase.Enum, u1, u2 float64, ustride, uorder int32, v1, v2 float64, vstride, vorder int32, points []float64) {
+ C.gl1_1_glMap2d(gl.funcs, C.GLenum(target), C.GLdouble(u1), C.GLdouble(u2), C.GLint(ustride), C.GLint(uorder), C.GLdouble(v1), C.GLdouble(v2), C.GLint(vstride), C.GLint(vorder), (*C.GLdouble)(unsafe.Pointer(&points[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMap1f.xml
+func (gl *GL) Map1f(target glbase.Enum, u1, u2 float32, stride, order int, points []float32) {
+ C.gl1_1_glMap1f(gl.funcs, C.GLenum(target), C.GLfloat(u1), C.GLfloat(u2), C.GLint(stride), C.GLint(order), (*C.GLfloat)(unsafe.Pointer(&points[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMap1d.xml
+func (gl *GL) Map1d(target glbase.Enum, u1, u2 float64, stride, order int, points []float64) {
+ C.gl1_1_glMap1d(gl.funcs, C.GLenum(target), C.GLdouble(u1), C.GLdouble(u2), C.GLint(stride), C.GLint(order), (*C.GLdouble)(unsafe.Pointer(&points[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPushAttrib.xml
+func (gl *GL) PushAttrib(mask glbase.Bitfield) {
+ C.gl1_1_glPushAttrib(gl.funcs, C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPopAttrib.xml
+func (gl *GL) PopAttrib() {
+ C.gl1_1_glPopAttrib(gl.funcs)
+}
+
+// Accum executes an operation on the accumulation buffer.
+//
+// Parameter op defines the accumulation buffer operation (GL.ACCUM, GL.LOAD,
+// GL.ADD, GL.MULT, or GL.RETURN) and specifies how the value parameter is
+// used.
+//
+// The accumulation buffer is an extended-range color buffer. Images are not
+// rendered into it. Rather, images rendered into one of the color buffers
+// are added to the contents of the accumulation buffer after rendering.
+// Effects such as antialiasing (of points, lines, and polygons), motion
+// blur, and depth of field can be created by accumulating images generated
+// with different transformation matrices.
+//
+// Each pixel in the accumulation buffer consists of red, green, blue, and
+// alpha values. The number of bits per component in the accumulation buffer
+// depends on the implementation. You can examine this number by calling
+// GetIntegerv four times, with arguments GL.ACCUM_RED_BITS,
+// GL.ACCUM_GREEN_BITS, GL.ACCUM_BLUE_BITS, and GL.ACCUM_ALPHA_BITS.
+// Regardless of the number of bits per component, the range of values stored
+// by each component is (-1, 1). The accumulation buffer pixels are mapped
+// one-to-one with frame buffer pixels.
+//
+// All accumulation buffer operations are limited to the area of the current
+// scissor box and applied identically to the red, green, blue, and alpha
+// components of each pixel. If a Accum operation results in a value outside
+// the range (-1, 1), the contents of an accumulation buffer pixel component
+// are undefined.
+//
+// The operations are as follows:
+//
+// GL.ACCUM
+// Obtains R, G, B, and A values from the buffer currently selected for
+// reading (see ReadBuffer). Each component value is divided by 2 n -
+// 1 , where n is the number of bits allocated to each color component
+// in the currently selected buffer. The result is a floating-point
+// value in the range 0 1 , which is multiplied by value and added to
+// the corresponding pixel component in the accumulation buffer,
+// thereby updating the accumulation buffer.
+//
+// GL.LOAD
+// Similar to GL.ACCUM, except that the current value in the
+// accumulation buffer is not used in the calculation of the new value.
+// That is, the R, G, B, and A values from the currently selected
+// buffer are divided by 2 n - 1 , multiplied by value, and then stored
+// in the corresponding accumulation buffer cell, overwriting the
+// current value.
+//
+// GL.ADD
+// Adds value to each R, G, B, and A in the accumulation buffer.
+//
+// GL.MULT
+// Multiplies each R, G, B, and A in the accumulation buffer by value
+// and returns the scaled component to its corresponding accumulation
+// buffer location.
+//
+// GL.RETURN
+// Transfers accumulation buffer values to the color buffer or buffers
+// currently selected for writing. Each R, G, B, and A component is
+// multiplied by value, then multiplied by 2 n - 1 , clamped to the
+// range 0 2 n - 1 , and stored in the corresponding display buffer
+// cell. The only fragment operations that are applied to this transfer
+// are pixel ownership, scissor, dithering, and color writemasks.
+//
+// To clear the accumulation buffer, call ClearAccum with R, G, B, and A
+// values to set it to, then call Clear with the accumulation buffer
+// enabled.
+//
+// Error GL.INVALID_ENUM is generated if op is not an accepted value.
+// GL.INVALID_OPERATION is generated if there is no accumulation buffer.
+// GL.INVALID_OPERATION is generated if Accum is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) Accum(op glbase.Enum, value float32) {
+ C.gl1_1_glAccum(gl.funcs, C.GLenum(op), C.GLfloat(value))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexMask.xml
+func (gl *GL) IndexMask(mask uint32) {
+ C.gl1_1_glIndexMask(gl.funcs, C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClearIndex.xml
+func (gl *GL) ClearIndex(c float32) {
+ C.gl1_1_glClearIndex(gl.funcs, C.GLfloat(c))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClearAccum.xml
+func (gl *GL) ClearAccum(red, green, blue, alpha float32) {
+ C.gl1_1_glClearAccum(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPushName.xml
+func (gl *GL) PushName(name uint32) {
+ C.gl1_1_glPushName(gl.funcs, C.GLuint(name))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPopName.xml
+func (gl *GL) PopName() {
+ C.gl1_1_glPopName(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPassThrough.xml
+func (gl *GL) PassThrough(token float32) {
+ C.gl1_1_glPassThrough(gl.funcs, C.GLfloat(token))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLoadName.xml
+func (gl *GL) LoadName(name uint32) {
+ C.gl1_1_glLoadName(gl.funcs, C.GLuint(name))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glInitNames.xml
+func (gl *GL) InitNames() {
+ C.gl1_1_glInitNames(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRenderMode.xml
+func (gl *GL) RenderMode(mode glbase.Enum) int32 {
+ glresult := C.gl1_1_glRenderMode(gl.funcs, C.GLenum(mode))
+ return int32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSelectBuffer.xml
+func (gl *GL) SelectBuffer(size int, buffer []glbase.Buffer) {
+ C.gl1_1_glSelectBuffer(gl.funcs, C.GLsizei(size), (*C.GLuint)(unsafe.Pointer(&buffer[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFeedbackBuffer.xml
+func (gl *GL) FeedbackBuffer(size int, gltype glbase.Enum, buffer []float32) {
+ C.gl1_1_glFeedbackBuffer(gl.funcs, C.GLsizei(size), C.GLenum(gltype), (*C.GLfloat)(unsafe.Pointer(&buffer[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexGeniv.xml
+func (gl *GL) TexGeniv(coord, pname glbase.Enum, params []int32) {
+ C.gl1_1_glTexGeniv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexGeni.xml
+func (gl *GL) TexGeni(coord, pname glbase.Enum, param int32) {
+ C.gl1_1_glTexGeni(gl.funcs, C.GLenum(coord), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexGenfv.xml
+func (gl *GL) TexGenfv(coord, pname glbase.Enum, params []float32) {
+ C.gl1_1_glTexGenfv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexGenf.xml
+func (gl *GL) TexGenf(coord, pname glbase.Enum, param float32) {
+ C.gl1_1_glTexGenf(gl.funcs, C.GLenum(coord), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexGendv.xml
+func (gl *GL) TexGendv(coord, pname glbase.Enum, params []float64) {
+ C.gl1_1_glTexGendv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexGend.xml
+func (gl *GL) TexGend(coord, pname glbase.Enum, param float64) {
+ C.gl1_1_glTexGend(gl.funcs, C.GLenum(coord), C.GLenum(pname), C.GLdouble(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexEnviv.xml
+func (gl *GL) TexEnviv(target, pname glbase.Enum, params []int32) {
+ C.gl1_1_glTexEnviv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexEnvi.xml
+func (gl *GL) TexEnvi(target, pname glbase.Enum, param int32) {
+ C.gl1_1_glTexEnvi(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexEnvfv.xml
+func (gl *GL) TexEnvfv(target, pname glbase.Enum, params []float32) {
+ C.gl1_1_glTexEnvfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexEnvf.xml
+func (gl *GL) TexEnvf(target, pname glbase.Enum, param float32) {
+ C.gl1_1_glTexEnvf(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glShadeModel.xml
+func (gl *GL) ShadeModel(mode glbase.Enum) {
+ C.gl1_1_glShadeModel(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPolygonStipple.xml
+func (gl *GL) PolygonStipple(mask []uint8) {
+ C.gl1_1_glPolygonStipple(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&mask[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMaterialiv.xml
+func (gl *GL) Materialiv(face, pname glbase.Enum, params []int32) {
+ C.gl1_1_glMaterialiv(gl.funcs, C.GLenum(face), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMateriali.xml
+func (gl *GL) Materiali(face, pname glbase.Enum, param int32) {
+ C.gl1_1_glMateriali(gl.funcs, C.GLenum(face), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMaterialfv.xml
+func (gl *GL) Materialfv(face, pname glbase.Enum, params []float32) {
+ C.gl1_1_glMaterialfv(gl.funcs, C.GLenum(face), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMaterialf.xml
+func (gl *GL) Materialf(face, pname glbase.Enum, param float32) {
+ C.gl1_1_glMaterialf(gl.funcs, C.GLenum(face), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLineStipple.xml
+func (gl *GL) LineStipple(factor int32, pattern uint16) {
+ C.gl1_1_glLineStipple(gl.funcs, C.GLint(factor), C.GLushort(pattern))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLightModeliv.xml
+func (gl *GL) LightModeliv(pname glbase.Enum, params []int32) {
+ C.gl1_1_glLightModeliv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLightModeli.xml
+func (gl *GL) LightModeli(pname glbase.Enum, param int32) {
+ C.gl1_1_glLightModeli(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLightModelfv.xml
+func (gl *GL) LightModelfv(pname glbase.Enum, params []float32) {
+ C.gl1_1_glLightModelfv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLightModelf.xml
+func (gl *GL) LightModelf(pname glbase.Enum, param float32) {
+ C.gl1_1_glLightModelf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLightiv.xml
+func (gl *GL) Lightiv(light, pname glbase.Enum, params []int32) {
+ C.gl1_1_glLightiv(gl.funcs, C.GLenum(light), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLighti.xml
+func (gl *GL) Lighti(light, pname glbase.Enum, param int32) {
+ C.gl1_1_glLighti(gl.funcs, C.GLenum(light), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLightfv.xml
+func (gl *GL) Lightfv(light, pname glbase.Enum, params []float32) {
+ C.gl1_1_glLightfv(gl.funcs, C.GLenum(light), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLightf.xml
+func (gl *GL) Lightf(light, pname glbase.Enum, param float32) {
+ C.gl1_1_glLightf(gl.funcs, C.GLenum(light), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFogiv.xml
+func (gl *GL) Fogiv(pname glbase.Enum, params []int32) {
+ C.gl1_1_glFogiv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFogi.xml
+func (gl *GL) Fogi(pname glbase.Enum, param int32) {
+ C.gl1_1_glFogi(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFogfv.xml
+func (gl *GL) Fogfv(pname glbase.Enum, params []float32) {
+ C.gl1_1_glFogfv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFogf.xml
+func (gl *GL) Fogf(pname glbase.Enum, param float32) {
+ C.gl1_1_glFogf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColorMaterial.xml
+func (gl *GL) ColorMaterial(face, mode glbase.Enum) {
+ C.gl1_1_glColorMaterial(gl.funcs, C.GLenum(face), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClipPlane.xml
+func (gl *GL) ClipPlane(plane glbase.Enum, equation []float64) {
+ C.gl1_1_glClipPlane(gl.funcs, C.GLenum(plane), (*C.GLdouble)(unsafe.Pointer(&equation[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4sv.xml
+func (gl *GL) Vertex4sv(v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_1_glVertex4sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4s.xml
+func (gl *GL) Vertex4s(x, y, z, w int16) {
+ C.gl1_1_glVertex4s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z), C.GLshort(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4iv.xml
+func (gl *GL) Vertex4iv(v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_1_glVertex4iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4i.xml
+func (gl *GL) Vertex4i(x, y, z, w int) {
+ C.gl1_1_glVertex4i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z), C.GLint(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4fv.xml
+func (gl *GL) Vertex4fv(v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_1_glVertex4fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4f.xml
+func (gl *GL) Vertex4f(x, y, z, w float32) {
+ C.gl1_1_glVertex4f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z), C.GLfloat(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4dv.xml
+func (gl *GL) Vertex4dv(v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_1_glVertex4dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4d.xml
+func (gl *GL) Vertex4d(x, y, z, w float64) {
+ C.gl1_1_glVertex4d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z), C.GLdouble(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3sv.xml
+func (gl *GL) Vertex3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_1_glVertex3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3s.xml
+func (gl *GL) Vertex3s(x, y, z int16) {
+ C.gl1_1_glVertex3s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3iv.xml
+func (gl *GL) Vertex3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_1_glVertex3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3i.xml
+func (gl *GL) Vertex3i(x, y, z int) {
+ C.gl1_1_glVertex3i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3fv.xml
+func (gl *GL) Vertex3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_1_glVertex3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3f.xml
+func (gl *GL) Vertex3f(x, y, z float32) {
+ C.gl1_1_glVertex3f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3dv.xml
+func (gl *GL) Vertex3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_1_glVertex3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3d.xml
+func (gl *GL) Vertex3d(x, y, z float64) {
+ C.gl1_1_glVertex3d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2sv.xml
+func (gl *GL) Vertex2sv(v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_1_glVertex2sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2s.xml
+func (gl *GL) Vertex2s(x, y int16) {
+ C.gl1_1_glVertex2s(gl.funcs, C.GLshort(x), C.GLshort(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2iv.xml
+func (gl *GL) Vertex2iv(v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_1_glVertex2iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2i.xml
+func (gl *GL) Vertex2i(x, y int) {
+ C.gl1_1_glVertex2i(gl.funcs, C.GLint(x), C.GLint(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2fv.xml
+func (gl *GL) Vertex2fv(v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_1_glVertex2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2f.xml
+func (gl *GL) Vertex2f(x, y float32) {
+ C.gl1_1_glVertex2f(gl.funcs, C.GLfloat(x), C.GLfloat(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2dv.xml
+func (gl *GL) Vertex2dv(v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_1_glVertex2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2d.xml
+func (gl *GL) Vertex2d(x, y float64) {
+ C.gl1_1_glVertex2d(gl.funcs, C.GLdouble(x), C.GLdouble(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4sv.xml
+func (gl *GL) TexCoord4sv(v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_1_glTexCoord4sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4s.xml
+func (gl *GL) TexCoord4s(s, t, r, q int16) {
+ C.gl1_1_glTexCoord4s(gl.funcs, C.GLshort(s), C.GLshort(t), C.GLshort(r), C.GLshort(q))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4iv.xml
+func (gl *GL) TexCoord4iv(v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_1_glTexCoord4iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4i.xml
+func (gl *GL) TexCoord4i(s, t, r, q int32) {
+ C.gl1_1_glTexCoord4i(gl.funcs, C.GLint(s), C.GLint(t), C.GLint(r), C.GLint(q))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4fv.xml
+func (gl *GL) TexCoord4fv(v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_1_glTexCoord4fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4f.xml
+func (gl *GL) TexCoord4f(s, t, r, q float32) {
+ C.gl1_1_glTexCoord4f(gl.funcs, C.GLfloat(s), C.GLfloat(t), C.GLfloat(r), C.GLfloat(q))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4dv.xml
+func (gl *GL) TexCoord4dv(v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_1_glTexCoord4dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4d.xml
+func (gl *GL) TexCoord4d(s, t, r, q float64) {
+ C.gl1_1_glTexCoord4d(gl.funcs, C.GLdouble(s), C.GLdouble(t), C.GLdouble(r), C.GLdouble(q))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3sv.xml
+func (gl *GL) TexCoord3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_1_glTexCoord3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3s.xml
+func (gl *GL) TexCoord3s(s, t, r int16) {
+ C.gl1_1_glTexCoord3s(gl.funcs, C.GLshort(s), C.GLshort(t), C.GLshort(r))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3iv.xml
+func (gl *GL) TexCoord3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_1_glTexCoord3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3i.xml
+func (gl *GL) TexCoord3i(s, t, r int32) {
+ C.gl1_1_glTexCoord3i(gl.funcs, C.GLint(s), C.GLint(t), C.GLint(r))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3fv.xml
+func (gl *GL) TexCoord3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_1_glTexCoord3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3f.xml
+func (gl *GL) TexCoord3f(s, t, r float32) {
+ C.gl1_1_glTexCoord3f(gl.funcs, C.GLfloat(s), C.GLfloat(t), C.GLfloat(r))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3dv.xml
+func (gl *GL) TexCoord3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_1_glTexCoord3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3d.xml
+func (gl *GL) TexCoord3d(s, t, r float64) {
+ C.gl1_1_glTexCoord3d(gl.funcs, C.GLdouble(s), C.GLdouble(t), C.GLdouble(r))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2sv.xml
+func (gl *GL) TexCoord2sv(v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_1_glTexCoord2sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2s.xml
+func (gl *GL) TexCoord2s(s, t int16) {
+ C.gl1_1_glTexCoord2s(gl.funcs, C.GLshort(s), C.GLshort(t))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2iv.xml
+func (gl *GL) TexCoord2iv(v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_1_glTexCoord2iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2i.xml
+func (gl *GL) TexCoord2i(s, t int32) {
+ C.gl1_1_glTexCoord2i(gl.funcs, C.GLint(s), C.GLint(t))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2fv.xml
+func (gl *GL) TexCoord2fv(v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_1_glTexCoord2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2f.xml
+func (gl *GL) TexCoord2f(s, t float32) {
+ C.gl1_1_glTexCoord2f(gl.funcs, C.GLfloat(s), C.GLfloat(t))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2dv.xml
+func (gl *GL) TexCoord2dv(v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_1_glTexCoord2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2d.xml
+func (gl *GL) TexCoord2d(s, t float64) {
+ C.gl1_1_glTexCoord2d(gl.funcs, C.GLdouble(s), C.GLdouble(t))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1sv.xml
+func (gl *GL) TexCoord1sv(v []int16) {
+ C.gl1_1_glTexCoord1sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1s.xml
+func (gl *GL) TexCoord1s(s int16) {
+ C.gl1_1_glTexCoord1s(gl.funcs, C.GLshort(s))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1iv.xml
+func (gl *GL) TexCoord1iv(v []int32) {
+ C.gl1_1_glTexCoord1iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1i.xml
+func (gl *GL) TexCoord1i(s int32) {
+ C.gl1_1_glTexCoord1i(gl.funcs, C.GLint(s))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1fv.xml
+func (gl *GL) TexCoord1fv(v []float32) {
+ C.gl1_1_glTexCoord1fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1f.xml
+func (gl *GL) TexCoord1f(s float32) {
+ C.gl1_1_glTexCoord1f(gl.funcs, C.GLfloat(s))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1dv.xml
+func (gl *GL) TexCoord1dv(v []float64) {
+ C.gl1_1_glTexCoord1dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1d.xml
+func (gl *GL) TexCoord1d(s float64) {
+ C.gl1_1_glTexCoord1d(gl.funcs, C.GLdouble(s))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRectsv.xml
+func (gl *GL) Rectsv(v1, v2 []int16) {
+ C.gl1_1_glRectsv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v1[0])), (*C.GLshort)(unsafe.Pointer(&v2[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRects.xml
+func (gl *GL) Rects(x1, y1, x2, y2 int16) {
+ C.gl1_1_glRects(gl.funcs, C.GLshort(x1), C.GLshort(y1), C.GLshort(x2), C.GLshort(y2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRectiv.xml
+func (gl *GL) Rectiv(v1, v2 []int32) {
+ C.gl1_1_glRectiv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v1[0])), (*C.GLint)(unsafe.Pointer(&v2[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRecti.xml
+func (gl *GL) Recti(x1, y1, x2, y2 int32) {
+ C.gl1_1_glRecti(gl.funcs, C.GLint(x1), C.GLint(y1), C.GLint(x2), C.GLint(y2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRectfv.xml
+func (gl *GL) Rectfv(v1, v2 []float32) {
+ C.gl1_1_glRectfv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v1[0])), (*C.GLfloat)(unsafe.Pointer(&v2[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRectf.xml
+func (gl *GL) Rectf(x1, y1, x2, y2 float32) {
+ C.gl1_1_glRectf(gl.funcs, C.GLfloat(x1), C.GLfloat(y1), C.GLfloat(x2), C.GLfloat(y2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRectdv.xml
+func (gl *GL) Rectdv(v1, v2 []float64) {
+ C.gl1_1_glRectdv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v1[0])), (*C.GLdouble)(unsafe.Pointer(&v2[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRectd.xml
+func (gl *GL) Rectd(x1, y1, x2, y2 float64) {
+ C.gl1_1_glRectd(gl.funcs, C.GLdouble(x1), C.GLdouble(y1), C.GLdouble(x2), C.GLdouble(y2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4sv.xml
+func (gl *GL) RasterPos4sv(v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_1_glRasterPos4sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4s.xml
+func (gl *GL) RasterPos4s(x, y, z, w int16) {
+ C.gl1_1_glRasterPos4s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z), C.GLshort(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4iv.xml
+func (gl *GL) RasterPos4iv(v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_1_glRasterPos4iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4i.xml
+func (gl *GL) RasterPos4i(x, y, z, w int) {
+ C.gl1_1_glRasterPos4i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z), C.GLint(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4fv.xml
+func (gl *GL) RasterPos4fv(v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_1_glRasterPos4fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4f.xml
+func (gl *GL) RasterPos4f(x, y, z, w float32) {
+ C.gl1_1_glRasterPos4f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z), C.GLfloat(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4dv.xml
+func (gl *GL) RasterPos4dv(v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_1_glRasterPos4dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4d.xml
+func (gl *GL) RasterPos4d(x, y, z, w float64) {
+ C.gl1_1_glRasterPos4d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z), C.GLdouble(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3sv.xml
+func (gl *GL) RasterPos3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_1_glRasterPos3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3s.xml
+func (gl *GL) RasterPos3s(x, y, z int16) {
+ C.gl1_1_glRasterPos3s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3iv.xml
+func (gl *GL) RasterPos3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_1_glRasterPos3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3i.xml
+func (gl *GL) RasterPos3i(x, y, z int) {
+ C.gl1_1_glRasterPos3i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3fv.xml
+func (gl *GL) RasterPos3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_1_glRasterPos3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3f.xml
+func (gl *GL) RasterPos3f(x, y, z float32) {
+ C.gl1_1_glRasterPos3f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3dv.xml
+func (gl *GL) RasterPos3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_1_glRasterPos3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3d.xml
+func (gl *GL) RasterPos3d(x, y, z float64) {
+ C.gl1_1_glRasterPos3d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2sv.xml
+func (gl *GL) RasterPos2sv(v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_1_glRasterPos2sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2s.xml
+func (gl *GL) RasterPos2s(x, y int16) {
+ C.gl1_1_glRasterPos2s(gl.funcs, C.GLshort(x), C.GLshort(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2iv.xml
+func (gl *GL) RasterPos2iv(v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_1_glRasterPos2iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2i.xml
+func (gl *GL) RasterPos2i(x, y int) {
+ C.gl1_1_glRasterPos2i(gl.funcs, C.GLint(x), C.GLint(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2fv.xml
+func (gl *GL) RasterPos2fv(v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_1_glRasterPos2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2f.xml
+func (gl *GL) RasterPos2f(x, y float32) {
+ C.gl1_1_glRasterPos2f(gl.funcs, C.GLfloat(x), C.GLfloat(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2dv.xml
+func (gl *GL) RasterPos2dv(v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_1_glRasterPos2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2d.xml
+func (gl *GL) RasterPos2d(x, y float64) {
+ C.gl1_1_glRasterPos2d(gl.funcs, C.GLdouble(x), C.GLdouble(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3sv.xml
+func (gl *GL) Normal3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_1_glNormal3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3s.xml
+func (gl *GL) Normal3s(nx, ny, nz int16) {
+ C.gl1_1_glNormal3s(gl.funcs, C.GLshort(nx), C.GLshort(ny), C.GLshort(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3iv.xml
+func (gl *GL) Normal3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_1_glNormal3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3i.xml
+func (gl *GL) Normal3i(nx, ny, nz int32) {
+ C.gl1_1_glNormal3i(gl.funcs, C.GLint(nx), C.GLint(ny), C.GLint(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3fv.xml
+func (gl *GL) Normal3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_1_glNormal3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3f.xml
+func (gl *GL) Normal3f(nx, ny, nz float32) {
+ C.gl1_1_glNormal3f(gl.funcs, C.GLfloat(nx), C.GLfloat(ny), C.GLfloat(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3dv.xml
+func (gl *GL) Normal3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_1_glNormal3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3d.xml
+func (gl *GL) Normal3d(nx, ny, nz float64) {
+ C.gl1_1_glNormal3d(gl.funcs, C.GLdouble(nx), C.GLdouble(ny), C.GLdouble(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3bv.xml
+func (gl *GL) Normal3bv(v []byte) {
+ C.gl1_1_glNormal3bv(gl.funcs, (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3b.xml
+func (gl *GL) Normal3b(nx, ny, nz byte) {
+ C.gl1_1_glNormal3b(gl.funcs, C.GLbyte(nx), C.GLbyte(ny), C.GLbyte(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexsv.xml
+func (gl *GL) Indexsv(c []int16) {
+ C.gl1_1_glIndexsv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexs.xml
+func (gl *GL) Indexs(c int16) {
+ C.gl1_1_glIndexs(gl.funcs, C.GLshort(c))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexiv.xml
+func (gl *GL) Indexiv(c []int32) {
+ C.gl1_1_glIndexiv(gl.funcs, (*C.GLint)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexi.xml
+func (gl *GL) Indexi(c int32) {
+ C.gl1_1_glIndexi(gl.funcs, C.GLint(c))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexfv.xml
+func (gl *GL) Indexfv(c []float32) {
+ C.gl1_1_glIndexfv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexf.xml
+func (gl *GL) Indexf(c float32) {
+ C.gl1_1_glIndexf(gl.funcs, C.GLfloat(c))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexdv.xml
+func (gl *GL) Indexdv(c []float64) {
+ C.gl1_1_glIndexdv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexd.xml
+func (gl *GL) Indexd(c float64) {
+ C.gl1_1_glIndexd(gl.funcs, C.GLdouble(c))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEnd.xml
+func (gl *GL) End() {
+ C.gl1_1_glEnd(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEdgeFlagv.xml
+func (gl *GL) EdgeFlagv(flag []bool) {
+ C.gl1_1_glEdgeFlagv(gl.funcs, (*C.GLboolean)(unsafe.Pointer(&flag[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEdgeFlag.xml
+func (gl *GL) EdgeFlag(flag bool) {
+ C.gl1_1_glEdgeFlag(gl.funcs, *(*C.GLboolean)(unsafe.Pointer(&flag)))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4usv.xml
+func (gl *GL) Color4usv(v []uint16) {
+ C.gl1_1_glColor4usv(gl.funcs, (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4us.xml
+func (gl *GL) Color4us(red, green, blue, alpha uint16) {
+ C.gl1_1_glColor4us(gl.funcs, C.GLushort(red), C.GLushort(green), C.GLushort(blue), C.GLushort(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4uiv.xml
+func (gl *GL) Color4uiv(v []uint32) {
+ C.gl1_1_glColor4uiv(gl.funcs, (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4ui.xml
+func (gl *GL) Color4ui(red, green, blue, alpha uint32) {
+ C.gl1_1_glColor4ui(gl.funcs, C.GLuint(red), C.GLuint(green), C.GLuint(blue), C.GLuint(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4ubv.xml
+func (gl *GL) Color4ubv(v []uint8) {
+ C.gl1_1_glColor4ubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4ub.xml
+func (gl *GL) Color4ub(red, green, blue, alpha uint8) {
+ C.gl1_1_glColor4ub(gl.funcs, C.GLubyte(red), C.GLubyte(green), C.GLubyte(blue), C.GLubyte(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4sv.xml
+func (gl *GL) Color4sv(v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_1_glColor4sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4s.xml
+func (gl *GL) Color4s(red, green, blue, alpha int16) {
+ C.gl1_1_glColor4s(gl.funcs, C.GLshort(red), C.GLshort(green), C.GLshort(blue), C.GLshort(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4iv.xml
+func (gl *GL) Color4iv(v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_1_glColor4iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4i.xml
+func (gl *GL) Color4i(red, green, blue, alpha int32) {
+ C.gl1_1_glColor4i(gl.funcs, C.GLint(red), C.GLint(green), C.GLint(blue), C.GLint(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4fv.xml
+func (gl *GL) Color4fv(v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_1_glColor4fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4f.xml
+func (gl *GL) Color4f(red, green, blue, alpha float32) {
+ C.gl1_1_glColor4f(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4dv.xml
+func (gl *GL) Color4dv(v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_1_glColor4dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4d.xml
+func (gl *GL) Color4d(red, green, blue, alpha float64) {
+ C.gl1_1_glColor4d(gl.funcs, C.GLdouble(red), C.GLdouble(green), C.GLdouble(blue), C.GLdouble(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4bv.xml
+func (gl *GL) Color4bv(v []byte) {
+ C.gl1_1_glColor4bv(gl.funcs, (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4b.xml
+func (gl *GL) Color4b(red, green, blue, alpha byte) {
+ C.gl1_1_glColor4b(gl.funcs, C.GLbyte(red), C.GLbyte(green), C.GLbyte(blue), C.GLbyte(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3usv.xml
+func (gl *GL) Color3usv(v []uint16) {
+ C.gl1_1_glColor3usv(gl.funcs, (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3us.xml
+func (gl *GL) Color3us(red, green, blue uint16) {
+ C.gl1_1_glColor3us(gl.funcs, C.GLushort(red), C.GLushort(green), C.GLushort(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3uiv.xml
+func (gl *GL) Color3uiv(v []uint32) {
+ C.gl1_1_glColor3uiv(gl.funcs, (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3ui.xml
+func (gl *GL) Color3ui(red, green, blue uint32) {
+ C.gl1_1_glColor3ui(gl.funcs, C.GLuint(red), C.GLuint(green), C.GLuint(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3ubv.xml
+func (gl *GL) Color3ubv(v []uint8) {
+ C.gl1_1_glColor3ubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3ub.xml
+func (gl *GL) Color3ub(red, green, blue uint8) {
+ C.gl1_1_glColor3ub(gl.funcs, C.GLubyte(red), C.GLubyte(green), C.GLubyte(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3sv.xml
+func (gl *GL) Color3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_1_glColor3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3s.xml
+func (gl *GL) Color3s(red, green, blue int16) {
+ C.gl1_1_glColor3s(gl.funcs, C.GLshort(red), C.GLshort(green), C.GLshort(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3iv.xml
+func (gl *GL) Color3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_1_glColor3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3i.xml
+func (gl *GL) Color3i(red, green, blue int32) {
+ C.gl1_1_glColor3i(gl.funcs, C.GLint(red), C.GLint(green), C.GLint(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3fv.xml
+func (gl *GL) Color3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_1_glColor3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3f.xml
+func (gl *GL) Color3f(red, green, blue float32) {
+ C.gl1_1_glColor3f(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3dv.xml
+func (gl *GL) Color3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_1_glColor3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3d.xml
+func (gl *GL) Color3d(red, green, blue float64) {
+ C.gl1_1_glColor3d(gl.funcs, C.GLdouble(red), C.GLdouble(green), C.GLdouble(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3bv.xml
+func (gl *GL) Color3bv(v []byte) {
+ C.gl1_1_glColor3bv(gl.funcs, (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3b.xml
+func (gl *GL) Color3b(red, green, blue byte) {
+ C.gl1_1_glColor3b(gl.funcs, C.GLbyte(red), C.GLbyte(green), C.GLbyte(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBitmap.xml
+func (gl *GL) Bitmap(width, height int, xorig, yorig, xmove, ymove float32, bitmap []uint8) {
+ C.gl1_1_glBitmap(gl.funcs, C.GLsizei(width), C.GLsizei(height), C.GLfloat(xorig), C.GLfloat(yorig), C.GLfloat(xmove), C.GLfloat(ymove), (*C.GLubyte)(unsafe.Pointer(&bitmap[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBegin.xml
+func (gl *GL) Begin(mode glbase.Enum) {
+ C.gl1_1_glBegin(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glListBase.xml
+func (gl *GL) ListBase(base uint32) {
+ C.gl1_1_glListBase(gl.funcs, C.GLuint(base))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGenLists.xml
+func (gl *GL) GenLists(range_ int32) uint32 {
+ glresult := C.gl1_1_glGenLists(gl.funcs, C.GLsizei(range_))
+ return uint32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDeleteLists.xml
+func (gl *GL) DeleteLists(list uint32, range_ int32) {
+ C.gl1_1_glDeleteLists(gl.funcs, C.GLuint(list), C.GLsizei(range_))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCallLists.xml
+func (gl *GL) CallLists(n int, gltype glbase.Enum, lists interface{}) {
+ var lists_ptr unsafe.Pointer
+ var lists_v = reflect.ValueOf(lists)
+ if lists != nil && lists_v.Kind() != reflect.Slice {
+ panic("parameter lists must be a slice")
+ }
+ if lists != nil {
+ lists_ptr = unsafe.Pointer(lists_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_1_glCallLists(gl.funcs, C.GLsizei(n), C.GLenum(gltype), lists_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCallList.xml
+func (gl *GL) CallList(list uint32) {
+ C.gl1_1_glCallList(gl.funcs, C.GLuint(list))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEndList.xml
+func (gl *GL) EndList() {
+ C.gl1_1_glEndList(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNewList.xml
+func (gl *GL) NewList(list uint32, mode glbase.Enum) {
+ C.gl1_1_glNewList(gl.funcs, C.GLuint(list), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPushClientAttrib.xml
+func (gl *GL) PushClientAttrib(mask glbase.Bitfield) {
+ C.gl1_1_glPushClientAttrib(gl.funcs, C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPopClientAttrib.xml
+func (gl *GL) PopClientAttrib() {
+ C.gl1_1_glPopClientAttrib(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPrioritizeTextures.xml
+func (gl *GL) PrioritizeTextures(n int, textures []glbase.Texture, priorities []float32) {
+ C.gl1_1_glPrioritizeTextures(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])), (*C.GLfloat)(unsafe.Pointer(&priorities[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glAreTexturesResident.xml
+func (gl *GL) AreTexturesResident(n int, textures []glbase.Texture, residences []bool) bool {
+ glresult := C.gl1_1_glAreTexturesResident(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])), (*C.GLboolean)(unsafe.Pointer(&residences[0])))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexPointer.xml
+func (gl *GL) VertexPointer(size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_1_glVertexPointer(gl.funcs, C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoordPointer.xml
+func (gl *GL) TexCoordPointer(size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_1_glTexCoordPointer(gl.funcs, C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormalPointer.xml
+func (gl *GL) NormalPointer(gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_1_glNormalPointer(gl.funcs, C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glInterleavedArrays.xml
+func (gl *GL) InterleavedArrays(format glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_1_glInterleavedArrays(gl.funcs, C.GLenum(format), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexPointer.xml
+func (gl *GL) IndexPointer(gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_1_glIndexPointer(gl.funcs, C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEnableClientState.xml
+func (gl *GL) EnableClientState(array glbase.Enum) {
+ C.gl1_1_glEnableClientState(gl.funcs, C.GLenum(array))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEdgeFlagPointer.xml
+func (gl *GL) EdgeFlagPointer(stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_1_glEdgeFlagPointer(gl.funcs, C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDisableClientState.xml
+func (gl *GL) DisableClientState(array glbase.Enum) {
+ C.gl1_1_glDisableClientState(gl.funcs, C.GLenum(array))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColorPointer.xml
+func (gl *GL) ColorPointer(size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_1_glColorPointer(gl.funcs, C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glArrayElement.xml
+func (gl *GL) ArrayElement(i int32) {
+ C.gl1_1_glArrayElement(gl.funcs, C.GLint(i))
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/1.2/funcs.cpp b/Godeps/_workspace/src/github.com/obscuren/qml/gl/1.2/funcs.cpp
new file mode 100644
index 000000000..328f40f85
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/1.2/funcs.cpp
@@ -0,0 +1,2250 @@
+
+// ** file automatically generated by glgen -- do not edit manually **
+
+#include <QOpenGLContext>
+#include <QtGui/qopenglfunctions_1_2.h>
+
+#include "funcs.h"
+
+void *gl1_2_funcs() {
+ QOpenGLFunctions_1_2* funcs = QOpenGLContext::currentContext()->versionFunctions<QOpenGLFunctions_1_2>();
+ if (!funcs) {
+ return 0;
+ }
+ funcs->initializeOpenGLFunctions();
+ return funcs;
+}
+
+
+void gl1_2_glViewport(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glViewport(x, y, width, height);
+}
+
+void gl1_2_glDepthRange(void *_glfuncs, GLdouble nearVal, GLdouble farVal)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glDepthRange(nearVal, farVal);
+}
+
+GLboolean gl1_2_glIsEnabled(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ return _qglfuncs->glIsEnabled(cap);
+}
+
+void gl1_2_glGetTexLevelParameteriv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glGetTexLevelParameteriv(target, level, pname, params);
+}
+
+void gl1_2_glGetTexLevelParameterfv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glGetTexLevelParameterfv(target, level, pname, params);
+}
+
+void gl1_2_glGetTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glGetTexParameteriv(target, pname, params);
+}
+
+void gl1_2_glGetTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glGetTexParameterfv(target, pname, params);
+}
+
+void gl1_2_glGetTexImage(void *_glfuncs, GLenum target, GLint level, GLenum format, GLenum gltype, GLvoid* pixels)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glGetTexImage(target, level, format, gltype, pixels);
+}
+
+void gl1_2_glGetIntegerv(void *_glfuncs, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glGetIntegerv(pname, params);
+}
+
+void gl1_2_glGetFloatv(void *_glfuncs, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glGetFloatv(pname, params);
+}
+
+GLenum gl1_2_glGetError(void *_glfuncs)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ return _qglfuncs->glGetError();
+}
+
+void gl1_2_glGetDoublev(void *_glfuncs, GLenum pname, GLdouble* params)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glGetDoublev(pname, params);
+}
+
+void gl1_2_glGetBooleanv(void *_glfuncs, GLenum pname, GLboolean* params)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glGetBooleanv(pname, params);
+}
+
+void gl1_2_glReadPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum gltype, GLvoid* pixels)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glReadPixels(x, y, width, height, format, gltype, pixels);
+}
+
+void gl1_2_glReadBuffer(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glReadBuffer(mode);
+}
+
+void gl1_2_glPixelStorei(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glPixelStorei(pname, param);
+}
+
+void gl1_2_glPixelStoref(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glPixelStoref(pname, param);
+}
+
+void gl1_2_glDepthFunc(void *_glfuncs, GLenum glfunc)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glDepthFunc(glfunc);
+}
+
+void gl1_2_glStencilOp(void *_glfuncs, GLenum fail, GLenum zfail, GLenum zpass)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glStencilOp(fail, zfail, zpass);
+}
+
+void gl1_2_glStencilFunc(void *_glfuncs, GLenum glfunc, GLint ref, GLuint mask)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glStencilFunc(glfunc, ref, mask);
+}
+
+void gl1_2_glLogicOp(void *_glfuncs, GLenum opcode)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glLogicOp(opcode);
+}
+
+void gl1_2_glBlendFunc(void *_glfuncs, GLenum sfactor, GLenum dfactor)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glBlendFunc(sfactor, dfactor);
+}
+
+void gl1_2_glFlush(void *_glfuncs)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glFlush();
+}
+
+void gl1_2_glFinish(void *_glfuncs)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glFinish();
+}
+
+void gl1_2_glEnable(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glEnable(cap);
+}
+
+void gl1_2_glDisable(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glDisable(cap);
+}
+
+void gl1_2_glDepthMask(void *_glfuncs, GLboolean flag)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glDepthMask(flag);
+}
+
+void gl1_2_glColorMask(void *_glfuncs, GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glColorMask(red, green, blue, alpha);
+}
+
+void gl1_2_glStencilMask(void *_glfuncs, GLuint mask)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glStencilMask(mask);
+}
+
+void gl1_2_glClearDepth(void *_glfuncs, GLdouble depth)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glClearDepth(depth);
+}
+
+void gl1_2_glClearStencil(void *_glfuncs, GLint s)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glClearStencil(s);
+}
+
+void gl1_2_glClearColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glClearColor(red, green, blue, alpha);
+}
+
+void gl1_2_glClear(void *_glfuncs, GLbitfield mask)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glClear(mask);
+}
+
+void gl1_2_glDrawBuffer(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glDrawBuffer(mode);
+}
+
+void gl1_2_glTexImage2D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glTexImage2D(target, level, internalFormat, width, height, border, format, gltype, pixels);
+}
+
+void gl1_2_glTexImage1D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glTexImage1D(target, level, internalFormat, width, border, format, gltype, pixels);
+}
+
+void gl1_2_glTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glTexParameteriv(target, pname, params);
+}
+
+void gl1_2_glTexParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glTexParameteri(target, pname, param);
+}
+
+void gl1_2_glTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glTexParameterfv(target, pname, params);
+}
+
+void gl1_2_glTexParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glTexParameterf(target, pname, param);
+}
+
+void gl1_2_glScissor(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glScissor(x, y, width, height);
+}
+
+void gl1_2_glPolygonMode(void *_glfuncs, GLenum face, GLenum mode)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glPolygonMode(face, mode);
+}
+
+void gl1_2_glPointSize(void *_glfuncs, GLfloat size)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glPointSize(size);
+}
+
+void gl1_2_glLineWidth(void *_glfuncs, GLfloat width)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glLineWidth(width);
+}
+
+void gl1_2_glHint(void *_glfuncs, GLenum target, GLenum mode)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glHint(target, mode);
+}
+
+void gl1_2_glFrontFace(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glFrontFace(mode);
+}
+
+void gl1_2_glCullFace(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glCullFace(mode);
+}
+
+void gl1_2_glIndexubv(void *_glfuncs, const GLubyte* c)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glIndexubv(c);
+}
+
+void gl1_2_glIndexub(void *_glfuncs, GLubyte c)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glIndexub(c);
+}
+
+GLboolean gl1_2_glIsTexture(void *_glfuncs, GLuint texture)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ return _qglfuncs->glIsTexture(texture);
+}
+
+void gl1_2_glGenTextures(void *_glfuncs, GLsizei n, GLuint* textures)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glGenTextures(n, textures);
+}
+
+void gl1_2_glDeleteTextures(void *_glfuncs, GLsizei n, const GLuint* textures)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glDeleteTextures(n, textures);
+}
+
+void gl1_2_glBindTexture(void *_glfuncs, GLenum target, GLuint texture)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glBindTexture(target, texture);
+}
+
+void gl1_2_glTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glTexSubImage2D(target, level, xoffset, yoffset, width, height, format, gltype, pixels);
+}
+
+void gl1_2_glTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glTexSubImage1D(target, level, xoffset, width, format, gltype, pixels);
+}
+
+void gl1_2_glCopyTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage2D(target, level, xoffset, yoffset, x, y, width, height);
+}
+
+void gl1_2_glCopyTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage1D(target, level, xoffset, x, y, width);
+}
+
+void gl1_2_glCopyTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glCopyTexImage2D(target, level, internalFormat, x, y, width, height, border);
+}
+
+void gl1_2_glCopyTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLint border)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glCopyTexImage1D(target, level, internalFormat, x, y, width, border);
+}
+
+void gl1_2_glPolygonOffset(void *_glfuncs, GLfloat factor, GLfloat units)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glPolygonOffset(factor, units);
+}
+
+void gl1_2_glDrawElements(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glDrawElements(mode, count, gltype, indices);
+}
+
+void gl1_2_glDrawArrays(void *_glfuncs, GLenum mode, GLint first, GLsizei count)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glDrawArrays(mode, first, count);
+}
+
+void gl1_2_glCopyTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage3D(target, level, xoffset, yoffset, zoffset, x, y, width, height);
+}
+
+void gl1_2_glTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glTexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, gltype, pixels);
+}
+
+void gl1_2_glTexImage3D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glTexImage3D(target, level, internalFormat, width, height, depth, border, format, gltype, pixels);
+}
+
+void gl1_2_glDrawRangeElements(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glDrawRangeElements(mode, start, end, count, gltype, indices);
+}
+
+void gl1_2_glBlendEquation(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glBlendEquation(mode);
+}
+
+void gl1_2_glBlendColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glBlendColor(red, green, blue, alpha);
+}
+
+void gl1_2_glTranslatef(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glTranslatef(x, y, z);
+}
+
+void gl1_2_glTranslated(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glTranslated(x, y, z);
+}
+
+void gl1_2_glScalef(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glScalef(x, y, z);
+}
+
+void gl1_2_glScaled(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glScaled(x, y, z);
+}
+
+void gl1_2_glRotatef(void *_glfuncs, GLfloat angle, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glRotatef(angle, x, y, z);
+}
+
+void gl1_2_glRotated(void *_glfuncs, GLdouble angle, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glRotated(angle, x, y, z);
+}
+
+void gl1_2_glPushMatrix(void *_glfuncs)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glPushMatrix();
+}
+
+void gl1_2_glPopMatrix(void *_glfuncs)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glPopMatrix();
+}
+
+void gl1_2_glOrtho(void *_glfuncs, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glOrtho(left, right, bottom, top, zNear, zFar);
+}
+
+void gl1_2_glMultMatrixd(void *_glfuncs, const GLdouble* m)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glMultMatrixd(m);
+}
+
+void gl1_2_glMultMatrixf(void *_glfuncs, const GLfloat* m)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glMultMatrixf(m);
+}
+
+void gl1_2_glMatrixMode(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glMatrixMode(mode);
+}
+
+void gl1_2_glLoadMatrixd(void *_glfuncs, const GLdouble* m)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glLoadMatrixd(m);
+}
+
+void gl1_2_glLoadMatrixf(void *_glfuncs, const GLfloat* m)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glLoadMatrixf(m);
+}
+
+void gl1_2_glLoadIdentity(void *_glfuncs)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glLoadIdentity();
+}
+
+void gl1_2_glFrustum(void *_glfuncs, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glFrustum(left, right, bottom, top, zNear, zFar);
+}
+
+GLboolean gl1_2_glIsList(void *_glfuncs, GLuint list)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ return _qglfuncs->glIsList(list);
+}
+
+void gl1_2_glGetTexGeniv(void *_glfuncs, GLenum coord, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glGetTexGeniv(coord, pname, params);
+}
+
+void gl1_2_glGetTexGenfv(void *_glfuncs, GLenum coord, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glGetTexGenfv(coord, pname, params);
+}
+
+void gl1_2_glGetTexGendv(void *_glfuncs, GLenum coord, GLenum pname, GLdouble* params)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glGetTexGendv(coord, pname, params);
+}
+
+void gl1_2_glGetTexEnviv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glGetTexEnviv(target, pname, params);
+}
+
+void gl1_2_glGetTexEnvfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glGetTexEnvfv(target, pname, params);
+}
+
+void gl1_2_glGetPolygonStipple(void *_glfuncs, GLubyte* mask)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glGetPolygonStipple(mask);
+}
+
+void gl1_2_glGetPixelMapusv(void *_glfuncs, GLenum glmap, GLushort* values)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glGetPixelMapusv(glmap, values);
+}
+
+void gl1_2_glGetPixelMapuiv(void *_glfuncs, GLenum glmap, GLuint* values)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glGetPixelMapuiv(glmap, values);
+}
+
+void gl1_2_glGetPixelMapfv(void *_glfuncs, GLenum glmap, GLfloat* values)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glGetPixelMapfv(glmap, values);
+}
+
+void gl1_2_glGetMaterialiv(void *_glfuncs, GLenum face, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glGetMaterialiv(face, pname, params);
+}
+
+void gl1_2_glGetMaterialfv(void *_glfuncs, GLenum face, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glGetMaterialfv(face, pname, params);
+}
+
+void gl1_2_glGetMapiv(void *_glfuncs, GLenum target, GLenum query, GLint* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glGetMapiv(target, query, v);
+}
+
+void gl1_2_glGetMapfv(void *_glfuncs, GLenum target, GLenum query, GLfloat* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glGetMapfv(target, query, v);
+}
+
+void gl1_2_glGetMapdv(void *_glfuncs, GLenum target, GLenum query, GLdouble* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glGetMapdv(target, query, v);
+}
+
+void gl1_2_glGetLightiv(void *_glfuncs, GLenum light, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glGetLightiv(light, pname, params);
+}
+
+void gl1_2_glGetLightfv(void *_glfuncs, GLenum light, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glGetLightfv(light, pname, params);
+}
+
+void gl1_2_glGetClipPlane(void *_glfuncs, GLenum plane, GLdouble* equation)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glGetClipPlane(plane, equation);
+}
+
+void gl1_2_glDrawPixels(void *_glfuncs, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glDrawPixels(width, height, format, gltype, pixels);
+}
+
+void gl1_2_glCopyPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum gltype)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glCopyPixels(x, y, width, height, gltype);
+}
+
+void gl1_2_glPixelMapusv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLushort* values)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glPixelMapusv(glmap, mapsize, values);
+}
+
+void gl1_2_glPixelMapuiv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLuint* values)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glPixelMapuiv(glmap, mapsize, values);
+}
+
+void gl1_2_glPixelMapfv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLfloat* values)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glPixelMapfv(glmap, mapsize, values);
+}
+
+void gl1_2_glPixelTransferi(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glPixelTransferi(pname, param);
+}
+
+void gl1_2_glPixelTransferf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glPixelTransferf(pname, param);
+}
+
+void gl1_2_glPixelZoom(void *_glfuncs, GLfloat xfactor, GLfloat yfactor)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glPixelZoom(xfactor, yfactor);
+}
+
+void gl1_2_glAlphaFunc(void *_glfuncs, GLenum glfunc, GLfloat ref)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glAlphaFunc(glfunc, ref);
+}
+
+void gl1_2_glEvalPoint2(void *_glfuncs, GLint i, GLint j)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glEvalPoint2(i, j);
+}
+
+void gl1_2_glEvalMesh2(void *_glfuncs, GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glEvalMesh2(mode, i1, i2, j1, j2);
+}
+
+void gl1_2_glEvalPoint1(void *_glfuncs, GLint i)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glEvalPoint1(i);
+}
+
+void gl1_2_glEvalMesh1(void *_glfuncs, GLenum mode, GLint i1, GLint i2)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glEvalMesh1(mode, i1, i2);
+}
+
+void gl1_2_glEvalCoord2fv(void *_glfuncs, const GLfloat* u)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glEvalCoord2fv(u);
+}
+
+void gl1_2_glEvalCoord2f(void *_glfuncs, GLfloat u, GLfloat v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glEvalCoord2f(u, v);
+}
+
+void gl1_2_glEvalCoord2dv(void *_glfuncs, const GLdouble* u)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glEvalCoord2dv(u);
+}
+
+void gl1_2_glEvalCoord2d(void *_glfuncs, GLdouble u, GLdouble v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glEvalCoord2d(u, v);
+}
+
+void gl1_2_glEvalCoord1fv(void *_glfuncs, const GLfloat* u)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glEvalCoord1fv(u);
+}
+
+void gl1_2_glEvalCoord1f(void *_glfuncs, GLfloat u)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glEvalCoord1f(u);
+}
+
+void gl1_2_glEvalCoord1dv(void *_glfuncs, const GLdouble* u)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glEvalCoord1dv(u);
+}
+
+void gl1_2_glEvalCoord1d(void *_glfuncs, GLdouble u)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glEvalCoord1d(u);
+}
+
+void gl1_2_glMapGrid2f(void *_glfuncs, GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glMapGrid2f(un, u1, u2, vn, v1, v2);
+}
+
+void gl1_2_glMapGrid2d(void *_glfuncs, GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glMapGrid2d(un, u1, u2, vn, v1, v2);
+}
+
+void gl1_2_glMapGrid1f(void *_glfuncs, GLint un, GLfloat u1, GLfloat u2)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glMapGrid1f(un, u1, u2);
+}
+
+void gl1_2_glMapGrid1d(void *_glfuncs, GLint un, GLdouble u1, GLdouble u2)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glMapGrid1d(un, u1, u2);
+}
+
+void gl1_2_glMap2f(void *_glfuncs, GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat* points)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glMap2f(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+void gl1_2_glMap2d(void *_glfuncs, GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble* points)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glMap2d(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+void gl1_2_glMap1f(void *_glfuncs, GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat* points)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glMap1f(target, u1, u2, stride, order, points);
+}
+
+void gl1_2_glMap1d(void *_glfuncs, GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble* points)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glMap1d(target, u1, u2, stride, order, points);
+}
+
+void gl1_2_glPushAttrib(void *_glfuncs, GLbitfield mask)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glPushAttrib(mask);
+}
+
+void gl1_2_glPopAttrib(void *_glfuncs)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glPopAttrib();
+}
+
+void gl1_2_glAccum(void *_glfuncs, GLenum op, GLfloat value)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glAccum(op, value);
+}
+
+void gl1_2_glIndexMask(void *_glfuncs, GLuint mask)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glIndexMask(mask);
+}
+
+void gl1_2_glClearIndex(void *_glfuncs, GLfloat c)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glClearIndex(c);
+}
+
+void gl1_2_glClearAccum(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glClearAccum(red, green, blue, alpha);
+}
+
+void gl1_2_glPushName(void *_glfuncs, GLuint name)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glPushName(name);
+}
+
+void gl1_2_glPopName(void *_glfuncs)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glPopName();
+}
+
+void gl1_2_glPassThrough(void *_glfuncs, GLfloat token)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glPassThrough(token);
+}
+
+void gl1_2_glLoadName(void *_glfuncs, GLuint name)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glLoadName(name);
+}
+
+void gl1_2_glInitNames(void *_glfuncs)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glInitNames();
+}
+
+GLint gl1_2_glRenderMode(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ return _qglfuncs->glRenderMode(mode);
+}
+
+void gl1_2_glSelectBuffer(void *_glfuncs, GLsizei size, GLuint* buffer)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glSelectBuffer(size, buffer);
+}
+
+void gl1_2_glFeedbackBuffer(void *_glfuncs, GLsizei size, GLenum gltype, GLfloat* buffer)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glFeedbackBuffer(size, gltype, buffer);
+}
+
+void gl1_2_glTexGeniv(void *_glfuncs, GLenum coord, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glTexGeniv(coord, pname, params);
+}
+
+void gl1_2_glTexGeni(void *_glfuncs, GLenum coord, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glTexGeni(coord, pname, param);
+}
+
+void gl1_2_glTexGenfv(void *_glfuncs, GLenum coord, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glTexGenfv(coord, pname, params);
+}
+
+void gl1_2_glTexGenf(void *_glfuncs, GLenum coord, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glTexGenf(coord, pname, param);
+}
+
+void gl1_2_glTexGendv(void *_glfuncs, GLenum coord, GLenum pname, const GLdouble* params)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glTexGendv(coord, pname, params);
+}
+
+void gl1_2_glTexGend(void *_glfuncs, GLenum coord, GLenum pname, GLdouble param)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glTexGend(coord, pname, param);
+}
+
+void gl1_2_glTexEnviv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glTexEnviv(target, pname, params);
+}
+
+void gl1_2_glTexEnvi(void *_glfuncs, GLenum target, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glTexEnvi(target, pname, param);
+}
+
+void gl1_2_glTexEnvfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glTexEnvfv(target, pname, params);
+}
+
+void gl1_2_glTexEnvf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glTexEnvf(target, pname, param);
+}
+
+void gl1_2_glShadeModel(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glShadeModel(mode);
+}
+
+void gl1_2_glPolygonStipple(void *_glfuncs, const GLubyte* mask)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glPolygonStipple(mask);
+}
+
+void gl1_2_glMaterialiv(void *_glfuncs, GLenum face, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glMaterialiv(face, pname, params);
+}
+
+void gl1_2_glMateriali(void *_glfuncs, GLenum face, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glMateriali(face, pname, param);
+}
+
+void gl1_2_glMaterialfv(void *_glfuncs, GLenum face, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glMaterialfv(face, pname, params);
+}
+
+void gl1_2_glMaterialf(void *_glfuncs, GLenum face, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glMaterialf(face, pname, param);
+}
+
+void gl1_2_glLineStipple(void *_glfuncs, GLint factor, GLushort pattern)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glLineStipple(factor, pattern);
+}
+
+void gl1_2_glLightModeliv(void *_glfuncs, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glLightModeliv(pname, params);
+}
+
+void gl1_2_glLightModeli(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glLightModeli(pname, param);
+}
+
+void gl1_2_glLightModelfv(void *_glfuncs, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glLightModelfv(pname, params);
+}
+
+void gl1_2_glLightModelf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glLightModelf(pname, param);
+}
+
+void gl1_2_glLightiv(void *_glfuncs, GLenum light, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glLightiv(light, pname, params);
+}
+
+void gl1_2_glLighti(void *_glfuncs, GLenum light, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glLighti(light, pname, param);
+}
+
+void gl1_2_glLightfv(void *_glfuncs, GLenum light, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glLightfv(light, pname, params);
+}
+
+void gl1_2_glLightf(void *_glfuncs, GLenum light, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glLightf(light, pname, param);
+}
+
+void gl1_2_glFogiv(void *_glfuncs, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glFogiv(pname, params);
+}
+
+void gl1_2_glFogi(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glFogi(pname, param);
+}
+
+void gl1_2_glFogfv(void *_glfuncs, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glFogfv(pname, params);
+}
+
+void gl1_2_glFogf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glFogf(pname, param);
+}
+
+void gl1_2_glColorMaterial(void *_glfuncs, GLenum face, GLenum mode)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glColorMaterial(face, mode);
+}
+
+void gl1_2_glClipPlane(void *_glfuncs, GLenum plane, const GLdouble* equation)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glClipPlane(plane, equation);
+}
+
+void gl1_2_glVertex4sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glVertex4sv(v);
+}
+
+void gl1_2_glVertex4s(void *_glfuncs, GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glVertex4s(x, y, z, w);
+}
+
+void gl1_2_glVertex4iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glVertex4iv(v);
+}
+
+void gl1_2_glVertex4i(void *_glfuncs, GLint x, GLint y, GLint z, GLint w)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glVertex4i(x, y, z, w);
+}
+
+void gl1_2_glVertex4fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glVertex4fv(v);
+}
+
+void gl1_2_glVertex4f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glVertex4f(x, y, z, w);
+}
+
+void gl1_2_glVertex4dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glVertex4dv(v);
+}
+
+void gl1_2_glVertex4d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glVertex4d(x, y, z, w);
+}
+
+void gl1_2_glVertex3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glVertex3sv(v);
+}
+
+void gl1_2_glVertex3s(void *_glfuncs, GLshort x, GLshort y, GLshort z)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glVertex3s(x, y, z);
+}
+
+void gl1_2_glVertex3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glVertex3iv(v);
+}
+
+void gl1_2_glVertex3i(void *_glfuncs, GLint x, GLint y, GLint z)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glVertex3i(x, y, z);
+}
+
+void gl1_2_glVertex3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glVertex3fv(v);
+}
+
+void gl1_2_glVertex3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glVertex3f(x, y, z);
+}
+
+void gl1_2_glVertex3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glVertex3dv(v);
+}
+
+void gl1_2_glVertex3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glVertex3d(x, y, z);
+}
+
+void gl1_2_glVertex2sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glVertex2sv(v);
+}
+
+void gl1_2_glVertex2s(void *_glfuncs, GLshort x, GLshort y)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glVertex2s(x, y);
+}
+
+void gl1_2_glVertex2iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glVertex2iv(v);
+}
+
+void gl1_2_glVertex2i(void *_glfuncs, GLint x, GLint y)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glVertex2i(x, y);
+}
+
+void gl1_2_glVertex2fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glVertex2fv(v);
+}
+
+void gl1_2_glVertex2f(void *_glfuncs, GLfloat x, GLfloat y)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glVertex2f(x, y);
+}
+
+void gl1_2_glVertex2dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glVertex2dv(v);
+}
+
+void gl1_2_glVertex2d(void *_glfuncs, GLdouble x, GLdouble y)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glVertex2d(x, y);
+}
+
+void gl1_2_glTexCoord4sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glTexCoord4sv(v);
+}
+
+void gl1_2_glTexCoord4s(void *_glfuncs, GLshort s, GLshort t, GLshort r, GLshort q)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glTexCoord4s(s, t, r, q);
+}
+
+void gl1_2_glTexCoord4iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glTexCoord4iv(v);
+}
+
+void gl1_2_glTexCoord4i(void *_glfuncs, GLint s, GLint t, GLint r, GLint q)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glTexCoord4i(s, t, r, q);
+}
+
+void gl1_2_glTexCoord4fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glTexCoord4fv(v);
+}
+
+void gl1_2_glTexCoord4f(void *_glfuncs, GLfloat s, GLfloat t, GLfloat r, GLfloat q)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glTexCoord4f(s, t, r, q);
+}
+
+void gl1_2_glTexCoord4dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glTexCoord4dv(v);
+}
+
+void gl1_2_glTexCoord4d(void *_glfuncs, GLdouble s, GLdouble t, GLdouble r, GLdouble q)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glTexCoord4d(s, t, r, q);
+}
+
+void gl1_2_glTexCoord3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glTexCoord3sv(v);
+}
+
+void gl1_2_glTexCoord3s(void *_glfuncs, GLshort s, GLshort t, GLshort r)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glTexCoord3s(s, t, r);
+}
+
+void gl1_2_glTexCoord3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glTexCoord3iv(v);
+}
+
+void gl1_2_glTexCoord3i(void *_glfuncs, GLint s, GLint t, GLint r)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glTexCoord3i(s, t, r);
+}
+
+void gl1_2_glTexCoord3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glTexCoord3fv(v);
+}
+
+void gl1_2_glTexCoord3f(void *_glfuncs, GLfloat s, GLfloat t, GLfloat r)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glTexCoord3f(s, t, r);
+}
+
+void gl1_2_glTexCoord3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glTexCoord3dv(v);
+}
+
+void gl1_2_glTexCoord3d(void *_glfuncs, GLdouble s, GLdouble t, GLdouble r)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glTexCoord3d(s, t, r);
+}
+
+void gl1_2_glTexCoord2sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glTexCoord2sv(v);
+}
+
+void gl1_2_glTexCoord2s(void *_glfuncs, GLshort s, GLshort t)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glTexCoord2s(s, t);
+}
+
+void gl1_2_glTexCoord2iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glTexCoord2iv(v);
+}
+
+void gl1_2_glTexCoord2i(void *_glfuncs, GLint s, GLint t)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glTexCoord2i(s, t);
+}
+
+void gl1_2_glTexCoord2fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glTexCoord2fv(v);
+}
+
+void gl1_2_glTexCoord2f(void *_glfuncs, GLfloat s, GLfloat t)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glTexCoord2f(s, t);
+}
+
+void gl1_2_glTexCoord2dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glTexCoord2dv(v);
+}
+
+void gl1_2_glTexCoord2d(void *_glfuncs, GLdouble s, GLdouble t)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glTexCoord2d(s, t);
+}
+
+void gl1_2_glTexCoord1sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glTexCoord1sv(v);
+}
+
+void gl1_2_glTexCoord1s(void *_glfuncs, GLshort s)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glTexCoord1s(s);
+}
+
+void gl1_2_glTexCoord1iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glTexCoord1iv(v);
+}
+
+void gl1_2_glTexCoord1i(void *_glfuncs, GLint s)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glTexCoord1i(s);
+}
+
+void gl1_2_glTexCoord1fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glTexCoord1fv(v);
+}
+
+void gl1_2_glTexCoord1f(void *_glfuncs, GLfloat s)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glTexCoord1f(s);
+}
+
+void gl1_2_glTexCoord1dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glTexCoord1dv(v);
+}
+
+void gl1_2_glTexCoord1d(void *_glfuncs, GLdouble s)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glTexCoord1d(s);
+}
+
+void gl1_2_glRectsv(void *_glfuncs, const GLshort* v1, const GLshort* v2)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glRectsv(v1, v2);
+}
+
+void gl1_2_glRects(void *_glfuncs, GLshort x1, GLshort y1, GLshort x2, GLshort y2)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glRects(x1, y1, x2, y2);
+}
+
+void gl1_2_glRectiv(void *_glfuncs, const GLint* v1, const GLint* v2)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glRectiv(v1, v2);
+}
+
+void gl1_2_glRecti(void *_glfuncs, GLint x1, GLint y1, GLint x2, GLint y2)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glRecti(x1, y1, x2, y2);
+}
+
+void gl1_2_glRectfv(void *_glfuncs, const GLfloat* v1, const GLfloat* v2)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glRectfv(v1, v2);
+}
+
+void gl1_2_glRectf(void *_glfuncs, GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glRectf(x1, y1, x2, y2);
+}
+
+void gl1_2_glRectdv(void *_glfuncs, const GLdouble* v1, const GLdouble* v2)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glRectdv(v1, v2);
+}
+
+void gl1_2_glRectd(void *_glfuncs, GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glRectd(x1, y1, x2, y2);
+}
+
+void gl1_2_glRasterPos4sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glRasterPos4sv(v);
+}
+
+void gl1_2_glRasterPos4s(void *_glfuncs, GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glRasterPos4s(x, y, z, w);
+}
+
+void gl1_2_glRasterPos4iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glRasterPos4iv(v);
+}
+
+void gl1_2_glRasterPos4i(void *_glfuncs, GLint x, GLint y, GLint z, GLint w)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glRasterPos4i(x, y, z, w);
+}
+
+void gl1_2_glRasterPos4fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glRasterPos4fv(v);
+}
+
+void gl1_2_glRasterPos4f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glRasterPos4f(x, y, z, w);
+}
+
+void gl1_2_glRasterPos4dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glRasterPos4dv(v);
+}
+
+void gl1_2_glRasterPos4d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glRasterPos4d(x, y, z, w);
+}
+
+void gl1_2_glRasterPos3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glRasterPos3sv(v);
+}
+
+void gl1_2_glRasterPos3s(void *_glfuncs, GLshort x, GLshort y, GLshort z)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glRasterPos3s(x, y, z);
+}
+
+void gl1_2_glRasterPos3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glRasterPos3iv(v);
+}
+
+void gl1_2_glRasterPos3i(void *_glfuncs, GLint x, GLint y, GLint z)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glRasterPos3i(x, y, z);
+}
+
+void gl1_2_glRasterPos3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glRasterPos3fv(v);
+}
+
+void gl1_2_glRasterPos3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glRasterPos3f(x, y, z);
+}
+
+void gl1_2_glRasterPos3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glRasterPos3dv(v);
+}
+
+void gl1_2_glRasterPos3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glRasterPos3d(x, y, z);
+}
+
+void gl1_2_glRasterPos2sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glRasterPos2sv(v);
+}
+
+void gl1_2_glRasterPos2s(void *_glfuncs, GLshort x, GLshort y)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glRasterPos2s(x, y);
+}
+
+void gl1_2_glRasterPos2iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glRasterPos2iv(v);
+}
+
+void gl1_2_glRasterPos2i(void *_glfuncs, GLint x, GLint y)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glRasterPos2i(x, y);
+}
+
+void gl1_2_glRasterPos2fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glRasterPos2fv(v);
+}
+
+void gl1_2_glRasterPos2f(void *_glfuncs, GLfloat x, GLfloat y)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glRasterPos2f(x, y);
+}
+
+void gl1_2_glRasterPos2dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glRasterPos2dv(v);
+}
+
+void gl1_2_glRasterPos2d(void *_glfuncs, GLdouble x, GLdouble y)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glRasterPos2d(x, y);
+}
+
+void gl1_2_glNormal3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glNormal3sv(v);
+}
+
+void gl1_2_glNormal3s(void *_glfuncs, GLshort nx, GLshort ny, GLshort nz)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glNormal3s(nx, ny, nz);
+}
+
+void gl1_2_glNormal3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glNormal3iv(v);
+}
+
+void gl1_2_glNormal3i(void *_glfuncs, GLint nx, GLint ny, GLint nz)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glNormal3i(nx, ny, nz);
+}
+
+void gl1_2_glNormal3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glNormal3fv(v);
+}
+
+void gl1_2_glNormal3f(void *_glfuncs, GLfloat nx, GLfloat ny, GLfloat nz)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glNormal3f(nx, ny, nz);
+}
+
+void gl1_2_glNormal3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glNormal3dv(v);
+}
+
+void gl1_2_glNormal3d(void *_glfuncs, GLdouble nx, GLdouble ny, GLdouble nz)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glNormal3d(nx, ny, nz);
+}
+
+void gl1_2_glNormal3bv(void *_glfuncs, const GLbyte* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glNormal3bv(v);
+}
+
+void gl1_2_glNormal3b(void *_glfuncs, GLbyte nx, GLbyte ny, GLbyte nz)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glNormal3b(nx, ny, nz);
+}
+
+void gl1_2_glIndexsv(void *_glfuncs, const GLshort* c)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glIndexsv(c);
+}
+
+void gl1_2_glIndexs(void *_glfuncs, GLshort c)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glIndexs(c);
+}
+
+void gl1_2_glIndexiv(void *_glfuncs, const GLint* c)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glIndexiv(c);
+}
+
+void gl1_2_glIndexi(void *_glfuncs, GLint c)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glIndexi(c);
+}
+
+void gl1_2_glIndexfv(void *_glfuncs, const GLfloat* c)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glIndexfv(c);
+}
+
+void gl1_2_glIndexf(void *_glfuncs, GLfloat c)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glIndexf(c);
+}
+
+void gl1_2_glIndexdv(void *_glfuncs, const GLdouble* c)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glIndexdv(c);
+}
+
+void gl1_2_glIndexd(void *_glfuncs, GLdouble c)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glIndexd(c);
+}
+
+void gl1_2_glEnd(void *_glfuncs)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glEnd();
+}
+
+void gl1_2_glEdgeFlagv(void *_glfuncs, const GLboolean* flag)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glEdgeFlagv(flag);
+}
+
+void gl1_2_glEdgeFlag(void *_glfuncs, GLboolean flag)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glEdgeFlag(flag);
+}
+
+void gl1_2_glColor4usv(void *_glfuncs, const GLushort* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glColor4usv(v);
+}
+
+void gl1_2_glColor4us(void *_glfuncs, GLushort red, GLushort green, GLushort blue, GLushort alpha)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glColor4us(red, green, blue, alpha);
+}
+
+void gl1_2_glColor4uiv(void *_glfuncs, const GLuint* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glColor4uiv(v);
+}
+
+void gl1_2_glColor4ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue, GLuint alpha)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glColor4ui(red, green, blue, alpha);
+}
+
+void gl1_2_glColor4ubv(void *_glfuncs, const GLubyte* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glColor4ubv(v);
+}
+
+void gl1_2_glColor4ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glColor4ub(red, green, blue, alpha);
+}
+
+void gl1_2_glColor4sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glColor4sv(v);
+}
+
+void gl1_2_glColor4s(void *_glfuncs, GLshort red, GLshort green, GLshort blue, GLshort alpha)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glColor4s(red, green, blue, alpha);
+}
+
+void gl1_2_glColor4iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glColor4iv(v);
+}
+
+void gl1_2_glColor4i(void *_glfuncs, GLint red, GLint green, GLint blue, GLint alpha)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glColor4i(red, green, blue, alpha);
+}
+
+void gl1_2_glColor4fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glColor4fv(v);
+}
+
+void gl1_2_glColor4f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glColor4f(red, green, blue, alpha);
+}
+
+void gl1_2_glColor4dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glColor4dv(v);
+}
+
+void gl1_2_glColor4d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glColor4d(red, green, blue, alpha);
+}
+
+void gl1_2_glColor4bv(void *_glfuncs, const GLbyte* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glColor4bv(v);
+}
+
+void gl1_2_glColor4b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glColor4b(red, green, blue, alpha);
+}
+
+void gl1_2_glColor3usv(void *_glfuncs, const GLushort* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glColor3usv(v);
+}
+
+void gl1_2_glColor3us(void *_glfuncs, GLushort red, GLushort green, GLushort blue)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glColor3us(red, green, blue);
+}
+
+void gl1_2_glColor3uiv(void *_glfuncs, const GLuint* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glColor3uiv(v);
+}
+
+void gl1_2_glColor3ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glColor3ui(red, green, blue);
+}
+
+void gl1_2_glColor3ubv(void *_glfuncs, const GLubyte* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glColor3ubv(v);
+}
+
+void gl1_2_glColor3ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glColor3ub(red, green, blue);
+}
+
+void gl1_2_glColor3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glColor3sv(v);
+}
+
+void gl1_2_glColor3s(void *_glfuncs, GLshort red, GLshort green, GLshort blue)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glColor3s(red, green, blue);
+}
+
+void gl1_2_glColor3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glColor3iv(v);
+}
+
+void gl1_2_glColor3i(void *_glfuncs, GLint red, GLint green, GLint blue)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glColor3i(red, green, blue);
+}
+
+void gl1_2_glColor3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glColor3fv(v);
+}
+
+void gl1_2_glColor3f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glColor3f(red, green, blue);
+}
+
+void gl1_2_glColor3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glColor3dv(v);
+}
+
+void gl1_2_glColor3d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glColor3d(red, green, blue);
+}
+
+void gl1_2_glColor3bv(void *_glfuncs, const GLbyte* v)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glColor3bv(v);
+}
+
+void gl1_2_glColor3b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glColor3b(red, green, blue);
+}
+
+void gl1_2_glBitmap(void *_glfuncs, GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte* bitmap)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glBitmap(width, height, xorig, yorig, xmove, ymove, bitmap);
+}
+
+void gl1_2_glBegin(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glBegin(mode);
+}
+
+void gl1_2_glListBase(void *_glfuncs, GLuint base)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glListBase(base);
+}
+
+GLuint gl1_2_glGenLists(void *_glfuncs, GLsizei range_)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ return _qglfuncs->glGenLists(range_);
+}
+
+void gl1_2_glDeleteLists(void *_glfuncs, GLuint list, GLsizei range_)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glDeleteLists(list, range_);
+}
+
+void gl1_2_glCallLists(void *_glfuncs, GLsizei n, GLenum gltype, const GLvoid* lists)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glCallLists(n, gltype, lists);
+}
+
+void gl1_2_glCallList(void *_glfuncs, GLuint list)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glCallList(list);
+}
+
+void gl1_2_glEndList(void *_glfuncs)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glEndList();
+}
+
+void gl1_2_glNewList(void *_glfuncs, GLuint list, GLenum mode)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glNewList(list, mode);
+}
+
+void gl1_2_glPushClientAttrib(void *_glfuncs, GLbitfield mask)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glPushClientAttrib(mask);
+}
+
+void gl1_2_glPopClientAttrib(void *_glfuncs)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glPopClientAttrib();
+}
+
+void gl1_2_glPrioritizeTextures(void *_glfuncs, GLsizei n, const GLuint* textures, const GLfloat* priorities)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glPrioritizeTextures(n, textures, priorities);
+}
+
+GLboolean gl1_2_glAreTexturesResident(void *_glfuncs, GLsizei n, const GLuint* textures, GLboolean* residences)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ return _qglfuncs->glAreTexturesResident(n, textures, residences);
+}
+
+void gl1_2_glVertexPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glVertexPointer(size, gltype, stride, pointer);
+}
+
+void gl1_2_glTexCoordPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glTexCoordPointer(size, gltype, stride, pointer);
+}
+
+void gl1_2_glNormalPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glNormalPointer(gltype, stride, pointer);
+}
+
+void gl1_2_glInterleavedArrays(void *_glfuncs, GLenum format, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glInterleavedArrays(format, stride, pointer);
+}
+
+void gl1_2_glIndexPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glIndexPointer(gltype, stride, pointer);
+}
+
+void gl1_2_glEnableClientState(void *_glfuncs, GLenum array)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glEnableClientState(array);
+}
+
+void gl1_2_glEdgeFlagPointer(void *_glfuncs, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glEdgeFlagPointer(stride, pointer);
+}
+
+void gl1_2_glDisableClientState(void *_glfuncs, GLenum array)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glDisableClientState(array);
+}
+
+void gl1_2_glColorPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glColorPointer(size, gltype, stride, pointer);
+}
+
+void gl1_2_glArrayElement(void *_glfuncs, GLint i)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glArrayElement(i);
+}
+
+void gl1_2_glResetMinmax(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glResetMinmax(target);
+}
+
+void gl1_2_glResetHistogram(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glResetHistogram(target);
+}
+
+void gl1_2_glMinmax(void *_glfuncs, GLenum target, GLenum internalFormat, GLboolean sink)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glMinmax(target, internalFormat, sink);
+}
+
+void gl1_2_glHistogram(void *_glfuncs, GLenum target, GLsizei width, GLenum internalFormat, GLboolean sink)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glHistogram(target, width, internalFormat, sink);
+}
+
+void gl1_2_glGetMinmaxParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glGetMinmaxParameteriv(target, pname, params);
+}
+
+void gl1_2_glGetMinmaxParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glGetMinmaxParameterfv(target, pname, params);
+}
+
+void gl1_2_glGetMinmax(void *_glfuncs, GLenum target, GLboolean reset, GLenum format, GLenum gltype, GLvoid* values)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glGetMinmax(target, reset, format, gltype, values);
+}
+
+void gl1_2_glGetHistogramParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glGetHistogramParameteriv(target, pname, params);
+}
+
+void gl1_2_glGetHistogramParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glGetHistogramParameterfv(target, pname, params);
+}
+
+void gl1_2_glGetHistogram(void *_glfuncs, GLenum target, GLboolean reset, GLenum format, GLenum gltype, GLvoid* values)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glGetHistogram(target, reset, format, gltype, values);
+}
+
+void gl1_2_glSeparableFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* row, const GLvoid* column)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glSeparableFilter2D(target, internalFormat, width, height, format, gltype, row, column);
+}
+
+void gl1_2_glGetSeparableFilter(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* row, GLvoid* column, GLvoid* span)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glGetSeparableFilter(target, format, gltype, row, column, span);
+}
+
+void gl1_2_glGetConvolutionParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glGetConvolutionParameteriv(target, pname, params);
+}
+
+void gl1_2_glGetConvolutionParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glGetConvolutionParameterfv(target, pname, params);
+}
+
+void gl1_2_glGetConvolutionFilter(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* image)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glGetConvolutionFilter(target, format, gltype, image);
+}
+
+void gl1_2_glCopyConvolutionFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glCopyConvolutionFilter2D(target, internalFormat, x, y, width, height);
+}
+
+void gl1_2_glCopyConvolutionFilter1D(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glCopyConvolutionFilter1D(target, internalFormat, x, y, width);
+}
+
+void gl1_2_glConvolutionParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glConvolutionParameteriv(target, pname, params);
+}
+
+void gl1_2_glConvolutionParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint params)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glConvolutionParameteri(target, pname, params);
+}
+
+void gl1_2_glConvolutionParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glConvolutionParameterfv(target, pname, params);
+}
+
+void gl1_2_glConvolutionParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat params)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glConvolutionParameterf(target, pname, params);
+}
+
+void gl1_2_glConvolutionFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* image)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glConvolutionFilter2D(target, internalFormat, width, height, format, gltype, image);
+}
+
+void gl1_2_glConvolutionFilter1D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLenum format, GLenum gltype, const GLvoid* image)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glConvolutionFilter1D(target, internalFormat, width, format, gltype, image);
+}
+
+void gl1_2_glCopyColorSubTable(void *_glfuncs, GLenum target, GLsizei start, GLint x, GLint y, GLsizei width)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glCopyColorSubTable(target, start, x, y, width);
+}
+
+void gl1_2_glColorSubTable(void *_glfuncs, GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum gltype, const GLvoid* data)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glColorSubTable(target, start, count, format, gltype, data);
+}
+
+void gl1_2_glGetColorTableParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glGetColorTableParameteriv(target, pname, params);
+}
+
+void gl1_2_glGetColorTableParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glGetColorTableParameterfv(target, pname, params);
+}
+
+void gl1_2_glGetColorTable(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* table)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glGetColorTable(target, format, gltype, table);
+}
+
+void gl1_2_glCopyColorTable(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glCopyColorTable(target, internalFormat, x, y, width);
+}
+
+void gl1_2_glColorTableParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glColorTableParameteriv(target, pname, params);
+}
+
+void gl1_2_glColorTableParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glColorTableParameterfv(target, pname, params);
+}
+
+void gl1_2_glColorTable(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLenum format, GLenum gltype, const GLvoid* table)
+{
+ QOpenGLFunctions_1_2* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_2*>(_glfuncs);
+ _qglfuncs->glColorTable(target, internalFormat, width, format, gltype, table);
+}
+
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/1.2/funcs.h b/Godeps/_workspace/src/github.com/obscuren/qml/gl/1.2/funcs.h
new file mode 100644
index 000000000..958c34935
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/1.2/funcs.h
@@ -0,0 +1,414 @@
+
+// ** file automatically generated by glgen -- do not edit manually **
+
+#ifndef __cplusplus
+#include <inttypes.h>
+#include <stddef.h>
+typedef unsigned int GLenum;
+typedef unsigned char GLboolean;
+typedef unsigned int GLbitfield;
+typedef void GLvoid;
+typedef char GLchar;
+typedef signed char GLbyte; /* 1-byte signed */
+typedef short GLshort; /* 2-byte signed */
+typedef int GLint; /* 4-byte signed */
+typedef unsigned char GLubyte; /* 1-byte unsigned */
+typedef unsigned short GLushort; /* 2-byte unsigned */
+typedef unsigned int GLuint; /* 4-byte unsigned */
+typedef int GLsizei; /* 4-byte signed */
+typedef float GLfloat; /* single precision float */
+typedef float GLclampf; /* single precision float in [0,1] */
+typedef double GLdouble; /* double precision float */
+typedef double GLclampd; /* double precision float in [0,1] */
+typedef int64_t GLint64;
+typedef uint64_t GLuint64;
+typedef ptrdiff_t GLintptr;
+typedef ptrdiff_t GLsizeiptr;
+typedef ptrdiff_t GLintptrARB;
+typedef ptrdiff_t GLsizeiptrARB;
+typedef struct __GLsync *GLsync;
+#endif
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+void *gl1_2_funcs();
+
+void gl1_2_glViewport(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl1_2_glDepthRange(void *_glfuncs, GLdouble nearVal, GLdouble farVal);
+GLboolean gl1_2_glIsEnabled(void *_glfuncs, GLenum cap);
+void gl1_2_glGetTexLevelParameteriv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLint* params);
+void gl1_2_glGetTexLevelParameterfv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLfloat* params);
+void gl1_2_glGetTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl1_2_glGetTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl1_2_glGetTexImage(void *_glfuncs, GLenum target, GLint level, GLenum format, GLenum gltype, GLvoid* pixels);
+void gl1_2_glGetIntegerv(void *_glfuncs, GLenum pname, GLint* params);
+void gl1_2_glGetFloatv(void *_glfuncs, GLenum pname, GLfloat* params);
+GLenum gl1_2_glGetError(void *_glfuncs);
+void gl1_2_glGetDoublev(void *_glfuncs, GLenum pname, GLdouble* params);
+void gl1_2_glGetBooleanv(void *_glfuncs, GLenum pname, GLboolean* params);
+void gl1_2_glReadPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum gltype, GLvoid* pixels);
+void gl1_2_glReadBuffer(void *_glfuncs, GLenum mode);
+void gl1_2_glPixelStorei(void *_glfuncs, GLenum pname, GLint param);
+void gl1_2_glPixelStoref(void *_glfuncs, GLenum pname, GLfloat param);
+void gl1_2_glDepthFunc(void *_glfuncs, GLenum glfunc);
+void gl1_2_glStencilOp(void *_glfuncs, GLenum fail, GLenum zfail, GLenum zpass);
+void gl1_2_glStencilFunc(void *_glfuncs, GLenum glfunc, GLint ref, GLuint mask);
+void gl1_2_glLogicOp(void *_glfuncs, GLenum opcode);
+void gl1_2_glBlendFunc(void *_glfuncs, GLenum sfactor, GLenum dfactor);
+void gl1_2_glFlush(void *_glfuncs);
+void gl1_2_glFinish(void *_glfuncs);
+void gl1_2_glEnable(void *_glfuncs, GLenum cap);
+void gl1_2_glDisable(void *_glfuncs, GLenum cap);
+void gl1_2_glDepthMask(void *_glfuncs, GLboolean flag);
+void gl1_2_glColorMask(void *_glfuncs, GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha);
+void gl1_2_glStencilMask(void *_glfuncs, GLuint mask);
+void gl1_2_glClearDepth(void *_glfuncs, GLdouble depth);
+void gl1_2_glClearStencil(void *_glfuncs, GLint s);
+void gl1_2_glClearColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl1_2_glClear(void *_glfuncs, GLbitfield mask);
+void gl1_2_glDrawBuffer(void *_glfuncs, GLenum mode);
+void gl1_2_glTexImage2D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl1_2_glTexImage1D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl1_2_glTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl1_2_glTexParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint param);
+void gl1_2_glTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl1_2_glTexParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param);
+void gl1_2_glScissor(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl1_2_glPolygonMode(void *_glfuncs, GLenum face, GLenum mode);
+void gl1_2_glPointSize(void *_glfuncs, GLfloat size);
+void gl1_2_glLineWidth(void *_glfuncs, GLfloat width);
+void gl1_2_glHint(void *_glfuncs, GLenum target, GLenum mode);
+void gl1_2_glFrontFace(void *_glfuncs, GLenum mode);
+void gl1_2_glCullFace(void *_glfuncs, GLenum mode);
+void gl1_2_glIndexubv(void *_glfuncs, const GLubyte* c);
+void gl1_2_glIndexub(void *_glfuncs, GLubyte c);
+GLboolean gl1_2_glIsTexture(void *_glfuncs, GLuint texture);
+void gl1_2_glGenTextures(void *_glfuncs, GLsizei n, GLuint* textures);
+void gl1_2_glDeleteTextures(void *_glfuncs, GLsizei n, const GLuint* textures);
+void gl1_2_glBindTexture(void *_glfuncs, GLenum target, GLuint texture);
+void gl1_2_glTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl1_2_glTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl1_2_glCopyTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl1_2_glCopyTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width);
+void gl1_2_glCopyTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border);
+void gl1_2_glCopyTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLint border);
+void gl1_2_glPolygonOffset(void *_glfuncs, GLfloat factor, GLfloat units);
+void gl1_2_glDrawElements(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices);
+void gl1_2_glDrawArrays(void *_glfuncs, GLenum mode, GLint first, GLsizei count);
+void gl1_2_glCopyTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl1_2_glTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl1_2_glTexImage3D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl1_2_glDrawRangeElements(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices);
+void gl1_2_glBlendEquation(void *_glfuncs, GLenum mode);
+void gl1_2_glBlendColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl1_2_glTranslatef(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl1_2_glTranslated(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl1_2_glScalef(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl1_2_glScaled(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl1_2_glRotatef(void *_glfuncs, GLfloat angle, GLfloat x, GLfloat y, GLfloat z);
+void gl1_2_glRotated(void *_glfuncs, GLdouble angle, GLdouble x, GLdouble y, GLdouble z);
+void gl1_2_glPushMatrix(void *_glfuncs);
+void gl1_2_glPopMatrix(void *_glfuncs);
+void gl1_2_glOrtho(void *_glfuncs, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+void gl1_2_glMultMatrixd(void *_glfuncs, const GLdouble* m);
+void gl1_2_glMultMatrixf(void *_glfuncs, const GLfloat* m);
+void gl1_2_glMatrixMode(void *_glfuncs, GLenum mode);
+void gl1_2_glLoadMatrixd(void *_glfuncs, const GLdouble* m);
+void gl1_2_glLoadMatrixf(void *_glfuncs, const GLfloat* m);
+void gl1_2_glLoadIdentity(void *_glfuncs);
+void gl1_2_glFrustum(void *_glfuncs, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+GLboolean gl1_2_glIsList(void *_glfuncs, GLuint list);
+void gl1_2_glGetTexGeniv(void *_glfuncs, GLenum coord, GLenum pname, GLint* params);
+void gl1_2_glGetTexGenfv(void *_glfuncs, GLenum coord, GLenum pname, GLfloat* params);
+void gl1_2_glGetTexGendv(void *_glfuncs, GLenum coord, GLenum pname, GLdouble* params);
+void gl1_2_glGetTexEnviv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl1_2_glGetTexEnvfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl1_2_glGetPolygonStipple(void *_glfuncs, GLubyte* mask);
+void gl1_2_glGetPixelMapusv(void *_glfuncs, GLenum glmap, GLushort* values);
+void gl1_2_glGetPixelMapuiv(void *_glfuncs, GLenum glmap, GLuint* values);
+void gl1_2_glGetPixelMapfv(void *_glfuncs, GLenum glmap, GLfloat* values);
+void gl1_2_glGetMaterialiv(void *_glfuncs, GLenum face, GLenum pname, GLint* params);
+void gl1_2_glGetMaterialfv(void *_glfuncs, GLenum face, GLenum pname, GLfloat* params);
+void gl1_2_glGetMapiv(void *_glfuncs, GLenum target, GLenum query, GLint* v);
+void gl1_2_glGetMapfv(void *_glfuncs, GLenum target, GLenum query, GLfloat* v);
+void gl1_2_glGetMapdv(void *_glfuncs, GLenum target, GLenum query, GLdouble* v);
+void gl1_2_glGetLightiv(void *_glfuncs, GLenum light, GLenum pname, GLint* params);
+void gl1_2_glGetLightfv(void *_glfuncs, GLenum light, GLenum pname, GLfloat* params);
+void gl1_2_glGetClipPlane(void *_glfuncs, GLenum plane, GLdouble* equation);
+void gl1_2_glDrawPixels(void *_glfuncs, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl1_2_glCopyPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum gltype);
+void gl1_2_glPixelMapusv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLushort* values);
+void gl1_2_glPixelMapuiv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLuint* values);
+void gl1_2_glPixelMapfv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLfloat* values);
+void gl1_2_glPixelTransferi(void *_glfuncs, GLenum pname, GLint param);
+void gl1_2_glPixelTransferf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl1_2_glPixelZoom(void *_glfuncs, GLfloat xfactor, GLfloat yfactor);
+void gl1_2_glAlphaFunc(void *_glfuncs, GLenum glfunc, GLfloat ref);
+void gl1_2_glEvalPoint2(void *_glfuncs, GLint i, GLint j);
+void gl1_2_glEvalMesh2(void *_glfuncs, GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2);
+void gl1_2_glEvalPoint1(void *_glfuncs, GLint i);
+void gl1_2_glEvalMesh1(void *_glfuncs, GLenum mode, GLint i1, GLint i2);
+void gl1_2_glEvalCoord2fv(void *_glfuncs, const GLfloat* u);
+void gl1_2_glEvalCoord2f(void *_glfuncs, GLfloat u, GLfloat v);
+void gl1_2_glEvalCoord2dv(void *_glfuncs, const GLdouble* u);
+void gl1_2_glEvalCoord2d(void *_glfuncs, GLdouble u, GLdouble v);
+void gl1_2_glEvalCoord1fv(void *_glfuncs, const GLfloat* u);
+void gl1_2_glEvalCoord1f(void *_glfuncs, GLfloat u);
+void gl1_2_glEvalCoord1dv(void *_glfuncs, const GLdouble* u);
+void gl1_2_glEvalCoord1d(void *_glfuncs, GLdouble u);
+void gl1_2_glMapGrid2f(void *_glfuncs, GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2);
+void gl1_2_glMapGrid2d(void *_glfuncs, GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2);
+void gl1_2_glMapGrid1f(void *_glfuncs, GLint un, GLfloat u1, GLfloat u2);
+void gl1_2_glMapGrid1d(void *_glfuncs, GLint un, GLdouble u1, GLdouble u2);
+void gl1_2_glMap2f(void *_glfuncs, GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat* points);
+void gl1_2_glMap2d(void *_glfuncs, GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble* points);
+void gl1_2_glMap1f(void *_glfuncs, GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat* points);
+void gl1_2_glMap1d(void *_glfuncs, GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble* points);
+void gl1_2_glPushAttrib(void *_glfuncs, GLbitfield mask);
+void gl1_2_glPopAttrib(void *_glfuncs);
+void gl1_2_glAccum(void *_glfuncs, GLenum op, GLfloat value);
+void gl1_2_glIndexMask(void *_glfuncs, GLuint mask);
+void gl1_2_glClearIndex(void *_glfuncs, GLfloat c);
+void gl1_2_glClearAccum(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl1_2_glPushName(void *_glfuncs, GLuint name);
+void gl1_2_glPopName(void *_glfuncs);
+void gl1_2_glPassThrough(void *_glfuncs, GLfloat token);
+void gl1_2_glLoadName(void *_glfuncs, GLuint name);
+void gl1_2_glInitNames(void *_glfuncs);
+GLint gl1_2_glRenderMode(void *_glfuncs, GLenum mode);
+void gl1_2_glSelectBuffer(void *_glfuncs, GLsizei size, GLuint* buffer);
+void gl1_2_glFeedbackBuffer(void *_glfuncs, GLsizei size, GLenum gltype, GLfloat* buffer);
+void gl1_2_glTexGeniv(void *_glfuncs, GLenum coord, GLenum pname, const GLint* params);
+void gl1_2_glTexGeni(void *_glfuncs, GLenum coord, GLenum pname, GLint param);
+void gl1_2_glTexGenfv(void *_glfuncs, GLenum coord, GLenum pname, const GLfloat* params);
+void gl1_2_glTexGenf(void *_glfuncs, GLenum coord, GLenum pname, GLfloat param);
+void gl1_2_glTexGendv(void *_glfuncs, GLenum coord, GLenum pname, const GLdouble* params);
+void gl1_2_glTexGend(void *_glfuncs, GLenum coord, GLenum pname, GLdouble param);
+void gl1_2_glTexEnviv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl1_2_glTexEnvi(void *_glfuncs, GLenum target, GLenum pname, GLint param);
+void gl1_2_glTexEnvfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl1_2_glTexEnvf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param);
+void gl1_2_glShadeModel(void *_glfuncs, GLenum mode);
+void gl1_2_glPolygonStipple(void *_glfuncs, const GLubyte* mask);
+void gl1_2_glMaterialiv(void *_glfuncs, GLenum face, GLenum pname, const GLint* params);
+void gl1_2_glMateriali(void *_glfuncs, GLenum face, GLenum pname, GLint param);
+void gl1_2_glMaterialfv(void *_glfuncs, GLenum face, GLenum pname, const GLfloat* params);
+void gl1_2_glMaterialf(void *_glfuncs, GLenum face, GLenum pname, GLfloat param);
+void gl1_2_glLineStipple(void *_glfuncs, GLint factor, GLushort pattern);
+void gl1_2_glLightModeliv(void *_glfuncs, GLenum pname, const GLint* params);
+void gl1_2_glLightModeli(void *_glfuncs, GLenum pname, GLint param);
+void gl1_2_glLightModelfv(void *_glfuncs, GLenum pname, const GLfloat* params);
+void gl1_2_glLightModelf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl1_2_glLightiv(void *_glfuncs, GLenum light, GLenum pname, const GLint* params);
+void gl1_2_glLighti(void *_glfuncs, GLenum light, GLenum pname, GLint param);
+void gl1_2_glLightfv(void *_glfuncs, GLenum light, GLenum pname, const GLfloat* params);
+void gl1_2_glLightf(void *_glfuncs, GLenum light, GLenum pname, GLfloat param);
+void gl1_2_glFogiv(void *_glfuncs, GLenum pname, const GLint* params);
+void gl1_2_glFogi(void *_glfuncs, GLenum pname, GLint param);
+void gl1_2_glFogfv(void *_glfuncs, GLenum pname, const GLfloat* params);
+void gl1_2_glFogf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl1_2_glColorMaterial(void *_glfuncs, GLenum face, GLenum mode);
+void gl1_2_glClipPlane(void *_glfuncs, GLenum plane, const GLdouble* equation);
+void gl1_2_glVertex4sv(void *_glfuncs, const GLshort* v);
+void gl1_2_glVertex4s(void *_glfuncs, GLshort x, GLshort y, GLshort z, GLshort w);
+void gl1_2_glVertex4iv(void *_glfuncs, const GLint* v);
+void gl1_2_glVertex4i(void *_glfuncs, GLint x, GLint y, GLint z, GLint w);
+void gl1_2_glVertex4fv(void *_glfuncs, const GLfloat* v);
+void gl1_2_glVertex4f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+void gl1_2_glVertex4dv(void *_glfuncs, const GLdouble* v);
+void gl1_2_glVertex4d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+void gl1_2_glVertex3sv(void *_glfuncs, const GLshort* v);
+void gl1_2_glVertex3s(void *_glfuncs, GLshort x, GLshort y, GLshort z);
+void gl1_2_glVertex3iv(void *_glfuncs, const GLint* v);
+void gl1_2_glVertex3i(void *_glfuncs, GLint x, GLint y, GLint z);
+void gl1_2_glVertex3fv(void *_glfuncs, const GLfloat* v);
+void gl1_2_glVertex3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl1_2_glVertex3dv(void *_glfuncs, const GLdouble* v);
+void gl1_2_glVertex3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl1_2_glVertex2sv(void *_glfuncs, const GLshort* v);
+void gl1_2_glVertex2s(void *_glfuncs, GLshort x, GLshort y);
+void gl1_2_glVertex2iv(void *_glfuncs, const GLint* v);
+void gl1_2_glVertex2i(void *_glfuncs, GLint x, GLint y);
+void gl1_2_glVertex2fv(void *_glfuncs, const GLfloat* v);
+void gl1_2_glVertex2f(void *_glfuncs, GLfloat x, GLfloat y);
+void gl1_2_glVertex2dv(void *_glfuncs, const GLdouble* v);
+void gl1_2_glVertex2d(void *_glfuncs, GLdouble x, GLdouble y);
+void gl1_2_glTexCoord4sv(void *_glfuncs, const GLshort* v);
+void gl1_2_glTexCoord4s(void *_glfuncs, GLshort s, GLshort t, GLshort r, GLshort q);
+void gl1_2_glTexCoord4iv(void *_glfuncs, const GLint* v);
+void gl1_2_glTexCoord4i(void *_glfuncs, GLint s, GLint t, GLint r, GLint q);
+void gl1_2_glTexCoord4fv(void *_glfuncs, const GLfloat* v);
+void gl1_2_glTexCoord4f(void *_glfuncs, GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+void gl1_2_glTexCoord4dv(void *_glfuncs, const GLdouble* v);
+void gl1_2_glTexCoord4d(void *_glfuncs, GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+void gl1_2_glTexCoord3sv(void *_glfuncs, const GLshort* v);
+void gl1_2_glTexCoord3s(void *_glfuncs, GLshort s, GLshort t, GLshort r);
+void gl1_2_glTexCoord3iv(void *_glfuncs, const GLint* v);
+void gl1_2_glTexCoord3i(void *_glfuncs, GLint s, GLint t, GLint r);
+void gl1_2_glTexCoord3fv(void *_glfuncs, const GLfloat* v);
+void gl1_2_glTexCoord3f(void *_glfuncs, GLfloat s, GLfloat t, GLfloat r);
+void gl1_2_glTexCoord3dv(void *_glfuncs, const GLdouble* v);
+void gl1_2_glTexCoord3d(void *_glfuncs, GLdouble s, GLdouble t, GLdouble r);
+void gl1_2_glTexCoord2sv(void *_glfuncs, const GLshort* v);
+void gl1_2_glTexCoord2s(void *_glfuncs, GLshort s, GLshort t);
+void gl1_2_glTexCoord2iv(void *_glfuncs, const GLint* v);
+void gl1_2_glTexCoord2i(void *_glfuncs, GLint s, GLint t);
+void gl1_2_glTexCoord2fv(void *_glfuncs, const GLfloat* v);
+void gl1_2_glTexCoord2f(void *_glfuncs, GLfloat s, GLfloat t);
+void gl1_2_glTexCoord2dv(void *_glfuncs, const GLdouble* v);
+void gl1_2_glTexCoord2d(void *_glfuncs, GLdouble s, GLdouble t);
+void gl1_2_glTexCoord1sv(void *_glfuncs, const GLshort* v);
+void gl1_2_glTexCoord1s(void *_glfuncs, GLshort s);
+void gl1_2_glTexCoord1iv(void *_glfuncs, const GLint* v);
+void gl1_2_glTexCoord1i(void *_glfuncs, GLint s);
+void gl1_2_glTexCoord1fv(void *_glfuncs, const GLfloat* v);
+void gl1_2_glTexCoord1f(void *_glfuncs, GLfloat s);
+void gl1_2_glTexCoord1dv(void *_glfuncs, const GLdouble* v);
+void gl1_2_glTexCoord1d(void *_glfuncs, GLdouble s);
+void gl1_2_glRectsv(void *_glfuncs, const GLshort* v1, const GLshort* v2);
+void gl1_2_glRects(void *_glfuncs, GLshort x1, GLshort y1, GLshort x2, GLshort y2);
+void gl1_2_glRectiv(void *_glfuncs, const GLint* v1, const GLint* v2);
+void gl1_2_glRecti(void *_glfuncs, GLint x1, GLint y1, GLint x2, GLint y2);
+void gl1_2_glRectfv(void *_glfuncs, const GLfloat* v1, const GLfloat* v2);
+void gl1_2_glRectf(void *_glfuncs, GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2);
+void gl1_2_glRectdv(void *_glfuncs, const GLdouble* v1, const GLdouble* v2);
+void gl1_2_glRectd(void *_glfuncs, GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2);
+void gl1_2_glRasterPos4sv(void *_glfuncs, const GLshort* v);
+void gl1_2_glRasterPos4s(void *_glfuncs, GLshort x, GLshort y, GLshort z, GLshort w);
+void gl1_2_glRasterPos4iv(void *_glfuncs, const GLint* v);
+void gl1_2_glRasterPos4i(void *_glfuncs, GLint x, GLint y, GLint z, GLint w);
+void gl1_2_glRasterPos4fv(void *_glfuncs, const GLfloat* v);
+void gl1_2_glRasterPos4f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+void gl1_2_glRasterPos4dv(void *_glfuncs, const GLdouble* v);
+void gl1_2_glRasterPos4d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+void gl1_2_glRasterPos3sv(void *_glfuncs, const GLshort* v);
+void gl1_2_glRasterPos3s(void *_glfuncs, GLshort x, GLshort y, GLshort z);
+void gl1_2_glRasterPos3iv(void *_glfuncs, const GLint* v);
+void gl1_2_glRasterPos3i(void *_glfuncs, GLint x, GLint y, GLint z);
+void gl1_2_glRasterPos3fv(void *_glfuncs, const GLfloat* v);
+void gl1_2_glRasterPos3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl1_2_glRasterPos3dv(void *_glfuncs, const GLdouble* v);
+void gl1_2_glRasterPos3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl1_2_glRasterPos2sv(void *_glfuncs, const GLshort* v);
+void gl1_2_glRasterPos2s(void *_glfuncs, GLshort x, GLshort y);
+void gl1_2_glRasterPos2iv(void *_glfuncs, const GLint* v);
+void gl1_2_glRasterPos2i(void *_glfuncs, GLint x, GLint y);
+void gl1_2_glRasterPos2fv(void *_glfuncs, const GLfloat* v);
+void gl1_2_glRasterPos2f(void *_glfuncs, GLfloat x, GLfloat y);
+void gl1_2_glRasterPos2dv(void *_glfuncs, const GLdouble* v);
+void gl1_2_glRasterPos2d(void *_glfuncs, GLdouble x, GLdouble y);
+void gl1_2_glNormal3sv(void *_glfuncs, const GLshort* v);
+void gl1_2_glNormal3s(void *_glfuncs, GLshort nx, GLshort ny, GLshort nz);
+void gl1_2_glNormal3iv(void *_glfuncs, const GLint* v);
+void gl1_2_glNormal3i(void *_glfuncs, GLint nx, GLint ny, GLint nz);
+void gl1_2_glNormal3fv(void *_glfuncs, const GLfloat* v);
+void gl1_2_glNormal3f(void *_glfuncs, GLfloat nx, GLfloat ny, GLfloat nz);
+void gl1_2_glNormal3dv(void *_glfuncs, const GLdouble* v);
+void gl1_2_glNormal3d(void *_glfuncs, GLdouble nx, GLdouble ny, GLdouble nz);
+void gl1_2_glNormal3bv(void *_glfuncs, const GLbyte* v);
+void gl1_2_glNormal3b(void *_glfuncs, GLbyte nx, GLbyte ny, GLbyte nz);
+void gl1_2_glIndexsv(void *_glfuncs, const GLshort* c);
+void gl1_2_glIndexs(void *_glfuncs, GLshort c);
+void gl1_2_glIndexiv(void *_glfuncs, const GLint* c);
+void gl1_2_glIndexi(void *_glfuncs, GLint c);
+void gl1_2_glIndexfv(void *_glfuncs, const GLfloat* c);
+void gl1_2_glIndexf(void *_glfuncs, GLfloat c);
+void gl1_2_glIndexdv(void *_glfuncs, const GLdouble* c);
+void gl1_2_glIndexd(void *_glfuncs, GLdouble c);
+void gl1_2_glEnd(void *_glfuncs);
+void gl1_2_glEdgeFlagv(void *_glfuncs, const GLboolean* flag);
+void gl1_2_glEdgeFlag(void *_glfuncs, GLboolean flag);
+void gl1_2_glColor4usv(void *_glfuncs, const GLushort* v);
+void gl1_2_glColor4us(void *_glfuncs, GLushort red, GLushort green, GLushort blue, GLushort alpha);
+void gl1_2_glColor4uiv(void *_glfuncs, const GLuint* v);
+void gl1_2_glColor4ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue, GLuint alpha);
+void gl1_2_glColor4ubv(void *_glfuncs, const GLubyte* v);
+void gl1_2_glColor4ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha);
+void gl1_2_glColor4sv(void *_glfuncs, const GLshort* v);
+void gl1_2_glColor4s(void *_glfuncs, GLshort red, GLshort green, GLshort blue, GLshort alpha);
+void gl1_2_glColor4iv(void *_glfuncs, const GLint* v);
+void gl1_2_glColor4i(void *_glfuncs, GLint red, GLint green, GLint blue, GLint alpha);
+void gl1_2_glColor4fv(void *_glfuncs, const GLfloat* v);
+void gl1_2_glColor4f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl1_2_glColor4dv(void *_glfuncs, const GLdouble* v);
+void gl1_2_glColor4d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha);
+void gl1_2_glColor4bv(void *_glfuncs, const GLbyte* v);
+void gl1_2_glColor4b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha);
+void gl1_2_glColor3usv(void *_glfuncs, const GLushort* v);
+void gl1_2_glColor3us(void *_glfuncs, GLushort red, GLushort green, GLushort blue);
+void gl1_2_glColor3uiv(void *_glfuncs, const GLuint* v);
+void gl1_2_glColor3ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue);
+void gl1_2_glColor3ubv(void *_glfuncs, const GLubyte* v);
+void gl1_2_glColor3ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue);
+void gl1_2_glColor3sv(void *_glfuncs, const GLshort* v);
+void gl1_2_glColor3s(void *_glfuncs, GLshort red, GLshort green, GLshort blue);
+void gl1_2_glColor3iv(void *_glfuncs, const GLint* v);
+void gl1_2_glColor3i(void *_glfuncs, GLint red, GLint green, GLint blue);
+void gl1_2_glColor3fv(void *_glfuncs, const GLfloat* v);
+void gl1_2_glColor3f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue);
+void gl1_2_glColor3dv(void *_glfuncs, const GLdouble* v);
+void gl1_2_glColor3d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue);
+void gl1_2_glColor3bv(void *_glfuncs, const GLbyte* v);
+void gl1_2_glColor3b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue);
+void gl1_2_glBitmap(void *_glfuncs, GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte* bitmap);
+void gl1_2_glBegin(void *_glfuncs, GLenum mode);
+void gl1_2_glListBase(void *_glfuncs, GLuint base);
+GLuint gl1_2_glGenLists(void *_glfuncs, GLsizei range_);
+void gl1_2_glDeleteLists(void *_glfuncs, GLuint list, GLsizei range_);
+void gl1_2_glCallLists(void *_glfuncs, GLsizei n, GLenum gltype, const GLvoid* lists);
+void gl1_2_glCallList(void *_glfuncs, GLuint list);
+void gl1_2_glEndList(void *_glfuncs);
+void gl1_2_glNewList(void *_glfuncs, GLuint list, GLenum mode);
+void gl1_2_glPushClientAttrib(void *_glfuncs, GLbitfield mask);
+void gl1_2_glPopClientAttrib(void *_glfuncs);
+void gl1_2_glPrioritizeTextures(void *_glfuncs, GLsizei n, const GLuint* textures, const GLfloat* priorities);
+GLboolean gl1_2_glAreTexturesResident(void *_glfuncs, GLsizei n, const GLuint* textures, GLboolean* residences);
+void gl1_2_glVertexPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl1_2_glTexCoordPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl1_2_glNormalPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl1_2_glInterleavedArrays(void *_glfuncs, GLenum format, GLsizei stride, const GLvoid* pointer);
+void gl1_2_glIndexPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl1_2_glEnableClientState(void *_glfuncs, GLenum array);
+void gl1_2_glEdgeFlagPointer(void *_glfuncs, GLsizei stride, const GLvoid* pointer);
+void gl1_2_glDisableClientState(void *_glfuncs, GLenum array);
+void gl1_2_glColorPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl1_2_glArrayElement(void *_glfuncs, GLint i);
+void gl1_2_glResetMinmax(void *_glfuncs, GLenum target);
+void gl1_2_glResetHistogram(void *_glfuncs, GLenum target);
+void gl1_2_glMinmax(void *_glfuncs, GLenum target, GLenum internalFormat, GLboolean sink);
+void gl1_2_glHistogram(void *_glfuncs, GLenum target, GLsizei width, GLenum internalFormat, GLboolean sink);
+void gl1_2_glGetMinmaxParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl1_2_glGetMinmaxParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl1_2_glGetMinmax(void *_glfuncs, GLenum target, GLboolean reset, GLenum format, GLenum gltype, GLvoid* values);
+void gl1_2_glGetHistogramParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl1_2_glGetHistogramParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl1_2_glGetHistogram(void *_glfuncs, GLenum target, GLboolean reset, GLenum format, GLenum gltype, GLvoid* values);
+void gl1_2_glSeparableFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* row, const GLvoid* column);
+void gl1_2_glGetSeparableFilter(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* row, GLvoid* column, GLvoid* span);
+void gl1_2_glGetConvolutionParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl1_2_glGetConvolutionParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl1_2_glGetConvolutionFilter(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* image);
+void gl1_2_glCopyConvolutionFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl1_2_glCopyConvolutionFilter1D(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width);
+void gl1_2_glConvolutionParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl1_2_glConvolutionParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint params);
+void gl1_2_glConvolutionParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl1_2_glConvolutionParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat params);
+void gl1_2_glConvolutionFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* image);
+void gl1_2_glConvolutionFilter1D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLenum format, GLenum gltype, const GLvoid* image);
+void gl1_2_glCopyColorSubTable(void *_glfuncs, GLenum target, GLsizei start, GLint x, GLint y, GLsizei width);
+void gl1_2_glColorSubTable(void *_glfuncs, GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum gltype, const GLvoid* data);
+void gl1_2_glGetColorTableParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl1_2_glGetColorTableParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl1_2_glGetColorTable(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* table);
+void gl1_2_glCopyColorTable(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width);
+void gl1_2_glColorTableParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl1_2_glColorTableParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl1_2_glColorTable(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLenum format, GLenum gltype, const GLvoid* table);
+
+
+#ifdef __cplusplus
+} // extern "C"
+#endif
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/1.2/gl.go b/Godeps/_workspace/src/github.com/obscuren/qml/gl/1.2/gl.go
new file mode 100644
index 000000000..a3f089e74
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/1.2/gl.go
@@ -0,0 +1,3152 @@
+// ** file automatically generated by glgen -- do not edit manually **
+
+package GL
+
+// #cgo CXXFLAGS: -std=c++0x -pedantic-errors -Wall -fno-strict-aliasing
+// #cgo LDFLAGS: -lstdc++
+// #cgo pkg-config: Qt5Core Qt5OpenGL
+//
+// #include "funcs.h"
+//
+// void free(void*);
+//
+import "C"
+
+import (
+ "fmt"
+ "reflect"
+ "unsafe"
+
+ "gopkg.in/qml.v1/gl/glbase"
+)
+
+// API returns a value that offers methods matching the OpenGL version 1.2 API.
+//
+// The returned API must not be used after the provided OpenGL context becomes invalid.
+func API(context glbase.Contexter) *GL {
+ gl := &GL{}
+ gl.funcs = C.gl1_2_funcs()
+ if gl.funcs == nil {
+ panic(fmt.Errorf("OpenGL version 1.2 is not available"))
+ }
+ return gl
+}
+
+// GL implements the OpenGL version 1.2 API. Values of this
+// type must be created via the API function, and it must not be used after
+// the associated OpenGL context becomes invalid.
+type GL struct {
+ funcs unsafe.Pointer
+}
+
+const (
+ FALSE = 0
+ TRUE = 1
+ NONE = 0
+
+ BYTE = 0x1400
+ UNSIGNED_BYTE = 0x1401
+ SHORT = 0x1402
+ UNSIGNED_SHORT = 0x1403
+ INT = 0x1404
+ UNSIGNED_INT = 0x1405
+ FLOAT = 0x1406
+ N2_BYTES = 0x1407
+ N3_BYTES = 0x1408
+ N4_BYTES = 0x1409
+ DOUBLE = 0x140A
+
+ ACCUM = 0x0100
+ LOAD = 0x0101
+ RETURN = 0x0102
+ MULT = 0x0103
+ ADD = 0x0104
+
+ ACCUM_BUFFER_BIT = 0x00000200
+ ALL_ATTRIB_BITS = 0xFFFFFFFF
+ COLOR_BUFFER_BIT = 0x00004000
+ CURRENT_BIT = 0x00000001
+ DEPTH_BUFFER_BIT = 0x00000100
+ ENABLE_BIT = 0x00002000
+ EVAL_BIT = 0x00010000
+ FOG_BIT = 0x00000080
+ HINT_BIT = 0x00008000
+ LIGHTING_BIT = 0x00000040
+ LINE_BIT = 0x00000004
+ LIST_BIT = 0x00020000
+ PIXEL_MODE_BIT = 0x00000020
+ POINT_BIT = 0x00000002
+ POLYGON_BIT = 0x00000008
+ POLYGON_STIPPLE_BIT = 0x00000010
+ SCISSOR_BIT = 0x00080000
+ STENCIL_BUFFER_BIT = 0x00000400
+ TEXTURE_BIT = 0x00040000
+ TRANSFORM_BIT = 0x00001000
+ VIEWPORT_BIT = 0x00000800
+
+ ALWAYS = 0x0207
+ EQUAL = 0x0202
+ GEQUAL = 0x0206
+ GREATER = 0x0204
+ LEQUAL = 0x0203
+ LESS = 0x0201
+ NEVER = 0x0200
+ NOTEQUAL = 0x0205
+
+ LOGIC_OP = 0x0BF1
+
+ DST_ALPHA = 0x0304
+ ONE = 1
+ ONE_MINUS_DST_ALPHA = 0x0305
+ ONE_MINUS_SRC_ALPHA = 0x0303
+ ONE_MINUS_SRC_COLOR = 0x0301
+ SRC_ALPHA = 0x0302
+ SRC_COLOR = 0x0300
+ ZERO = 0
+
+ DST_COLOR = 0x0306
+ ONE_MINUS_DST_COLOR = 0x0307
+ SRC_ALPHA_SATURATE = 0x0308
+
+ CLIENT_ALL_ATTRIB_BITS = 0xFFFFFFFF
+ CLIENT_PIXEL_STORE_BIT = 0x00000001
+ CLIENT_VERTEX_ARRAY_BIT = 0x00000002
+
+ CLIP_PLANE0 = 0x3000
+ CLIP_PLANE1 = 0x3001
+ CLIP_PLANE2 = 0x3002
+ CLIP_PLANE3 = 0x3003
+ CLIP_PLANE4 = 0x3004
+ CLIP_PLANE5 = 0x3005
+
+ BACK = 0x0405
+ FRONT = 0x0404
+ FRONT_AND_BACK = 0x0408
+
+ AMBIENT = 0x1200
+ AMBIENT_AND_DIFFUSE = 0x1602
+ DIFFUSE = 0x1201
+ EMISSION = 0x1600
+ SPECULAR = 0x1202
+
+ AUX0 = 0x0409
+ AUX1 = 0x040A
+ AUX2 = 0x040B
+ AUX3 = 0x040C
+ BACK_LEFT = 0x0402
+ BACK_RIGHT = 0x0403
+ FRONT_LEFT = 0x0400
+ FRONT_RIGHT = 0x0401
+ LEFT = 0x0406
+ RIGHT = 0x0407
+
+ ALPHA_TEST = 0x0BC0
+ AUTO_NORMAL = 0x0D80
+ BLEND = 0x0BE2
+ COLOR_ARRAY = 0x8076
+ COLOR_LOGIC_OP = 0x0BF2
+ COLOR_MATERIAL = 0x0B57
+ CULL_FACE = 0x0B44
+ DEPTH_TEST = 0x0B71
+ DITHER = 0x0BD0
+ EDGE_FLAG_ARRAY = 0x8079
+ FOG = 0x0B60
+ INDEX_ARRAY = 0x8077
+ INDEX_LOGIC_OP = 0x0BF1
+ LIGHT0 = 0x4000
+ LIGHT1 = 0x4001
+ LIGHT2 = 0x4002
+ LIGHT3 = 0x4003
+ LIGHT4 = 0x4004
+ LIGHT5 = 0x4005
+ LIGHT6 = 0x4006
+ LIGHT7 = 0x4007
+ LIGHTING = 0x0B50
+ LINE_SMOOTH = 0x0B20
+ LINE_STIPPLE = 0x0B24
+ MAP1_COLOR_4 = 0x0D90
+ MAP1_INDEX = 0x0D91
+ MAP1_NORMAL = 0x0D92
+ MAP1_TEXTURE_COORD_1 = 0x0D93
+ MAP1_TEXTURE_COORD_2 = 0x0D94
+ MAP1_TEXTURE_COORD_3 = 0x0D95
+ MAP1_TEXTURE_COORD_4 = 0x0D96
+ MAP1_VERTEX_3 = 0x0D97
+ MAP1_VERTEX_4 = 0x0D98
+ MAP2_COLOR_4 = 0x0DB0
+ MAP2_INDEX = 0x0DB1
+ MAP2_NORMAL = 0x0DB2
+ MAP2_TEXTURE_COORD_1 = 0x0DB3
+ MAP2_TEXTURE_COORD_2 = 0x0DB4
+ MAP2_TEXTURE_COORD_3 = 0x0DB5
+ MAP2_TEXTURE_COORD_4 = 0x0DB6
+ MAP2_VERTEX_3 = 0x0DB7
+ MAP2_VERTEX_4 = 0x0DB8
+ NORMALIZE = 0x0BA1
+ NORMAL_ARRAY = 0x8075
+ POINT_SMOOTH = 0x0B10
+ POLYGON_OFFSET_FILL = 0x8037
+ POLYGON_OFFSET_LINE = 0x2A02
+ POLYGON_OFFSET_POINT = 0x2A01
+ POLYGON_SMOOTH = 0x0B41
+ POLYGON_STIPPLE = 0x0B42
+ SCISSOR_TEST = 0x0C11
+ STENCIL_TEST = 0x0B90
+ TEXTURE_1D = 0x0DE0
+ TEXTURE_2D = 0x0DE1
+ TEXTURE_COORD_ARRAY = 0x8078
+ TEXTURE_GEN_Q = 0x0C63
+ TEXTURE_GEN_R = 0x0C62
+ TEXTURE_GEN_S = 0x0C60
+ TEXTURE_GEN_T = 0x0C61
+ VERTEX_ARRAY = 0x8074
+
+ INVALID_ENUM = 0x0500
+ INVALID_OPERATION = 0x0502
+ INVALID_VALUE = 0x0501
+ NO_ERROR = 0
+ OUT_OF_MEMORY = 0x0505
+ STACK_OVERFLOW = 0x0503
+ STACK_UNDERFLOW = 0x0504
+
+ N2D = 0x0600
+ N3D = 0x0601
+ N3D_COLOR = 0x0602
+ N3D_COLOR_TEXTURE = 0x0603
+ N4D_COLOR_TEXTURE = 0x0604
+
+ BITMAP_TOKEN = 0x0704
+ COPY_PIXEL_TOKEN = 0x0706
+ DRAW_PIXEL_TOKEN = 0x0705
+ LINE_RESET_TOKEN = 0x0707
+ LINE_TOKEN = 0x0702
+ PASS_THROUGH_TOKEN = 0x0700
+ POINT_TOKEN = 0x0701
+ POLYGON_TOKEN = 0x0703
+
+ EXP = 0x0800
+ EXP2 = 0x0801
+ LINEAR = 0x2601
+
+ FOG_COLOR = 0x0B66
+ FOG_DENSITY = 0x0B62
+ FOG_END = 0x0B64
+ FOG_INDEX = 0x0B61
+ FOG_MODE = 0x0B65
+ FOG_START = 0x0B63
+
+ CCW = 0x0901
+ CW = 0x0900
+
+ COEFF = 0x0A00
+ DOMAIN = 0x0A02
+ ORDER = 0x0A01
+
+ PIXEL_MAP_A_TO_A = 0x0C79
+ PIXEL_MAP_B_TO_B = 0x0C78
+ PIXEL_MAP_G_TO_G = 0x0C77
+ PIXEL_MAP_I_TO_A = 0x0C75
+ PIXEL_MAP_I_TO_B = 0x0C74
+ PIXEL_MAP_I_TO_G = 0x0C73
+ PIXEL_MAP_I_TO_I = 0x0C70
+ PIXEL_MAP_I_TO_R = 0x0C72
+ PIXEL_MAP_R_TO_R = 0x0C76
+ PIXEL_MAP_S_TO_S = 0x0C71
+
+ ACCUM_ALPHA_BITS = 0x0D5B
+ ACCUM_BLUE_BITS = 0x0D5A
+ ACCUM_CLEAR_VALUE = 0x0B80
+ ACCUM_GREEN_BITS = 0x0D59
+ ACCUM_RED_BITS = 0x0D58
+ ALIASED_LINE_WIDTH_RANGE = 0x846E
+ ALIASED_POINT_SIZE_RANGE = 0x846D
+ ALPHA_BIAS = 0x0D1D
+ ALPHA_BITS = 0x0D55
+ ALPHA_SCALE = 0x0D1C
+ ALPHA_TEST_FUNC = 0x0BC1
+ ALPHA_TEST_REF = 0x0BC2
+ ATTRIB_STACK_DEPTH = 0x0BB0
+ AUX_BUFFERS = 0x0C00
+ BLEND_DST = 0x0BE0
+ BLEND_SRC = 0x0BE1
+ BLUE_BIAS = 0x0D1B
+ BLUE_BITS = 0x0D54
+ BLUE_SCALE = 0x0D1A
+ CLIENT_ATTRIB_STACK_DEPTH = 0x0BB1
+ COLOR_ARRAY_SIZE = 0x8081
+ COLOR_ARRAY_STRIDE = 0x8083
+ COLOR_ARRAY_TYPE = 0x8082
+ COLOR_CLEAR_VALUE = 0x0C22
+ COLOR_MATERIAL_FACE = 0x0B55
+ COLOR_MATERIAL_PARAMETER = 0x0B56
+ COLOR_WRITEMASK = 0x0C23
+ CULL_FACE_MODE = 0x0B45
+ CURRENT_COLOR = 0x0B00
+ CURRENT_INDEX = 0x0B01
+ CURRENT_NORMAL = 0x0B02
+ CURRENT_RASTER_COLOR = 0x0B04
+ CURRENT_RASTER_DISTANCE = 0x0B09
+ CURRENT_RASTER_INDEX = 0x0B05
+ CURRENT_RASTER_POSITION = 0x0B07
+ CURRENT_RASTER_POSITION_VALID = 0x0B08
+ CURRENT_RASTER_TEXTURE_COORDS = 0x0B06
+ CURRENT_TEXTURE_COORDS = 0x0B03
+ DEPTH_BIAS = 0x0D1F
+ DEPTH_BITS = 0x0D56
+ DEPTH_CLEAR_VALUE = 0x0B73
+ DEPTH_FUNC = 0x0B74
+ DEPTH_RANGE = 0x0B70
+ DEPTH_SCALE = 0x0D1E
+ DEPTH_WRITEMASK = 0x0B72
+ DOUBLEBUFFER = 0x0C32
+ DRAW_BUFFER = 0x0C01
+ EDGE_FLAG = 0x0B43
+ EDGE_FLAG_ARRAY_STRIDE = 0x808C
+ FEEDBACK_BUFFER_SIZE = 0x0DF1
+ FEEDBACK_BUFFER_TYPE = 0x0DF2
+ FOG_HINT = 0x0C54
+ FRONT_FACE = 0x0B46
+ GREEN_BIAS = 0x0D19
+ GREEN_BITS = 0x0D53
+ GREEN_SCALE = 0x0D18
+ INDEX_ARRAY_STRIDE = 0x8086
+ INDEX_ARRAY_TYPE = 0x8085
+ INDEX_BITS = 0x0D51
+ INDEX_CLEAR_VALUE = 0x0C20
+ INDEX_MODE = 0x0C30
+ INDEX_OFFSET = 0x0D13
+ INDEX_SHIFT = 0x0D12
+ INDEX_WRITEMASK = 0x0C21
+ LIGHT_MODEL_AMBIENT = 0x0B53
+ LIGHT_MODEL_COLOR_CONTROL = 0x81F8
+ LIGHT_MODEL_LOCAL_VIEWER = 0x0B51
+ LIGHT_MODEL_TWO_SIDE = 0x0B52
+ LINE_SMOOTH_HINT = 0x0C52
+ LINE_STIPPLE_PATTERN = 0x0B25
+ LINE_STIPPLE_REPEAT = 0x0B26
+ LINE_WIDTH = 0x0B21
+ LINE_WIDTH_GRANULARITY = 0x0B23
+ LINE_WIDTH_RANGE = 0x0B22
+ LIST_BASE = 0x0B32
+ LIST_INDEX = 0x0B33
+ LIST_MODE = 0x0B30
+ LOGIC_OP_MODE = 0x0BF0
+ MAP1_GRID_DOMAIN = 0x0DD0
+ MAP1_GRID_SEGMENTS = 0x0DD1
+ MAP2_GRID_DOMAIN = 0x0DD2
+ MAP2_GRID_SEGMENTS = 0x0DD3
+ MAP_COLOR = 0x0D10
+ MAP_STENCIL = 0x0D11
+ MATRIX_MODE = 0x0BA0
+ MAX_ATTRIB_STACK_DEPTH = 0x0D35
+ MAX_CLIENT_ATTRIB_STACK_DEPTH = 0x0D3B
+ MAX_CLIP_PLANES = 0x0D32
+ MAX_EVAL_ORDER = 0x0D30
+ MAX_LIGHTS = 0x0D31
+ MAX_LIST_NESTING = 0x0B31
+ MAX_MODELVIEW_STACK_DEPTH = 0x0D36
+ MAX_NAME_STACK_DEPTH = 0x0D37
+ MAX_PIXEL_MAP_TABLE = 0x0D34
+ MAX_PROJECTION_STACK_DEPTH = 0x0D38
+ MAX_TEXTURE_SIZE = 0x0D33
+ MAX_TEXTURE_STACK_DEPTH = 0x0D39
+ MAX_VIEWPORT_DIMS = 0x0D3A
+ MODELVIEW_MATRIX = 0x0BA6
+ MODELVIEW_STACK_DEPTH = 0x0BA3
+ NAME_STACK_DEPTH = 0x0D70
+ NORMAL_ARRAY_STRIDE = 0x807F
+ NORMAL_ARRAY_TYPE = 0x807E
+ PACK_ALIGNMENT = 0x0D05
+ PACK_LSB_FIRST = 0x0D01
+ PACK_ROW_LENGTH = 0x0D02
+ PACK_SKIP_PIXELS = 0x0D04
+ PACK_SKIP_ROWS = 0x0D03
+ PACK_SWAP_BYTES = 0x0D00
+ PERSPECTIVE_CORRECTION_HINT = 0x0C50
+ PIXEL_MAP_A_TO_A_SIZE = 0x0CB9
+ PIXEL_MAP_B_TO_B_SIZE = 0x0CB8
+ PIXEL_MAP_G_TO_G_SIZE = 0x0CB7
+ PIXEL_MAP_I_TO_A_SIZE = 0x0CB5
+ PIXEL_MAP_I_TO_B_SIZE = 0x0CB4
+ PIXEL_MAP_I_TO_G_SIZE = 0x0CB3
+ PIXEL_MAP_I_TO_I_SIZE = 0x0CB0
+ PIXEL_MAP_I_TO_R_SIZE = 0x0CB2
+ PIXEL_MAP_R_TO_R_SIZE = 0x0CB6
+ PIXEL_MAP_S_TO_S_SIZE = 0x0CB1
+ POINT_SIZE = 0x0B11
+ POINT_SIZE_GRANULARITY = 0x0B13
+ POINT_SIZE_RANGE = 0x0B12
+ POINT_SMOOTH_HINT = 0x0C51
+ POLYGON_MODE = 0x0B40
+ POLYGON_OFFSET_FACTOR = 0x8038
+ POLYGON_OFFSET_UNITS = 0x2A00
+ POLYGON_SMOOTH_HINT = 0x0C53
+ PROJECTION_MATRIX = 0x0BA7
+ PROJECTION_STACK_DEPTH = 0x0BA4
+ READ_BUFFER = 0x0C02
+ RED_BIAS = 0x0D15
+ RED_BITS = 0x0D52
+ RED_SCALE = 0x0D14
+ RENDER_MODE = 0x0C40
+ RGBA_MODE = 0x0C31
+ SCISSOR_BOX = 0x0C10
+ SELECTION_BUFFER_SIZE = 0x0DF4
+ SHADE_MODEL = 0x0B54
+ SMOOTH_LINE_WIDTH_GRANULARITY = 0x0B23
+ SMOOTH_LINE_WIDTH_RANGE = 0x0B22
+ SMOOTH_POINT_SIZE_GRANULARITY = 0x0B13
+ SMOOTH_POINT_SIZE_RANGE = 0x0B12
+ STENCIL_BITS = 0x0D57
+ STENCIL_CLEAR_VALUE = 0x0B91
+ STENCIL_FAIL = 0x0B94
+ STENCIL_FUNC = 0x0B92
+ STENCIL_PASS_DEPTH_FAIL = 0x0B95
+ STENCIL_PASS_DEPTH_PASS = 0x0B96
+ STENCIL_REF = 0x0B97
+ STENCIL_VALUE_MASK = 0x0B93
+ STENCIL_WRITEMASK = 0x0B98
+ STEREO = 0x0C33
+ SUBPIXEL_BITS = 0x0D50
+ TEXTURE_BINDING_1D = 0x8068
+ TEXTURE_BINDING_2D = 0x8069
+ TEXTURE_BINDING_3D = 0x806A
+ TEXTURE_COORD_ARRAY_SIZE = 0x8088
+ TEXTURE_COORD_ARRAY_STRIDE = 0x808A
+ TEXTURE_COORD_ARRAY_TYPE = 0x8089
+ TEXTURE_MATRIX = 0x0BA8
+ TEXTURE_STACK_DEPTH = 0x0BA5
+ UNPACK_ALIGNMENT = 0x0CF5
+ UNPACK_LSB_FIRST = 0x0CF1
+ UNPACK_ROW_LENGTH = 0x0CF2
+ UNPACK_SKIP_PIXELS = 0x0CF4
+ UNPACK_SKIP_ROWS = 0x0CF3
+ UNPACK_SWAP_BYTES = 0x0CF0
+ VERTEX_ARRAY_SIZE = 0x807A
+ VERTEX_ARRAY_STRIDE = 0x807C
+ VERTEX_ARRAY_TYPE = 0x807B
+ VIEWPORT = 0x0BA2
+ ZOOM_X = 0x0D16
+ ZOOM_Y = 0x0D17
+
+ COLOR_ARRAY_POINTER = 0x8090
+ EDGE_FLAG_ARRAY_POINTER = 0x8093
+ FEEDBACK_BUFFER_POINTER = 0x0DF0
+ INDEX_ARRAY_POINTER = 0x8091
+ NORMAL_ARRAY_POINTER = 0x808F
+ SELECTION_BUFFER_POINTER = 0x0DF3
+ TEXTURE_COORD_ARRAY_POINTER = 0x8092
+ VERTEX_ARRAY_POINTER = 0x808E
+
+ TEXTURE_ALPHA_SIZE = 0x805F
+ TEXTURE_BLUE_SIZE = 0x805E
+ TEXTURE_BORDER = 0x1005
+ TEXTURE_BORDER_COLOR = 0x1004
+ TEXTURE_COMPONENTS = 0x1003
+ TEXTURE_GREEN_SIZE = 0x805D
+ TEXTURE_HEIGHT = 0x1001
+ TEXTURE_INTENSITY_SIZE = 0x8061
+ TEXTURE_INTERNAL_FORMAT = 0x1003
+ TEXTURE_LUMINANCE_SIZE = 0x8060
+ TEXTURE_MAG_FILTER = 0x2800
+ TEXTURE_MIN_FILTER = 0x2801
+ TEXTURE_PRIORITY = 0x8066
+ TEXTURE_RED_SIZE = 0x805C
+ TEXTURE_RESIDENT = 0x8067
+ TEXTURE_WIDTH = 0x1000
+ TEXTURE_WRAP_S = 0x2802
+ TEXTURE_WRAP_T = 0x2803
+
+ DONT_CARE = 0x1100
+ FASTEST = 0x1101
+ NICEST = 0x1102
+
+ C3F_V3F = 0x2A24
+ C4F_N3F_V3F = 0x2A26
+ C4UB_V2F = 0x2A22
+ C4UB_V3F = 0x2A23
+ N3F_V3F = 0x2A25
+ T2F_C3F_V3F = 0x2A2A
+ T2F_C4F_N3F_V3F = 0x2A2C
+ T2F_C4UB_V3F = 0x2A29
+ T2F_N3F_V3F = 0x2A2B
+ T2F_V3F = 0x2A27
+ T4F_C4F_N3F_V4F = 0x2A2D
+ T4F_V4F = 0x2A28
+ V2F = 0x2A20
+ V3F = 0x2A21
+
+ MODULATE = 0x2100
+ REPLACE = 0x1E01
+
+ SEPARATE_SPECULAR_COLOR = 0x81FA
+ SINGLE_COLOR = 0x81F9
+
+ CONSTANT_ATTENUATION = 0x1207
+ LINEAR_ATTENUATION = 0x1208
+ POSITION = 0x1203
+ QUADRATIC_ATTENUATION = 0x1209
+ SPOT_CUTOFF = 0x1206
+ SPOT_DIRECTION = 0x1204
+ SPOT_EXPONENT = 0x1205
+
+ COMPILE = 0x1300
+ COMPILE_AND_EXECUTE = 0x1301
+
+ AND = 0x1501
+ AND_INVERTED = 0x1504
+ AND_REVERSE = 0x1502
+ CLEAR = 0x1500
+ COPY = 0x1503
+ COPY_INVERTED = 0x150C
+ EQUIV = 0x1509
+ INVERT = 0x150A
+ NAND = 0x150E
+ NOOP = 0x1505
+ NOR = 0x1508
+ OR = 0x1507
+ OR_INVERTED = 0x150D
+ OR_REVERSE = 0x150B
+ SET = 0x150F
+ XOR = 0x1506
+
+ COLOR_INDEXES = 0x1603
+ SHININESS = 0x1601
+
+ MODELVIEW = 0x1700
+ PROJECTION = 0x1701
+ TEXTURE = 0x1702
+
+ LINE = 0x1B01
+ POINT = 0x1B00
+
+ FILL = 0x1B02
+
+ COLOR = 0x1800
+ DEPTH = 0x1801
+ STENCIL = 0x1802
+
+ ALPHA = 0x1906
+ BLUE = 0x1905
+ COLOR_INDEX = 0x1900
+ DEPTH_COMPONENT = 0x1902
+ GREEN = 0x1904
+ LUMINANCE = 0x1909
+ LUMINANCE_ALPHA = 0x190A
+ RED = 0x1903
+ RGB = 0x1907
+ RGBA = 0x1908
+ STENCIL_INDEX = 0x1901
+
+ ALPHA12 = 0x803D
+ ALPHA16 = 0x803E
+ ALPHA4 = 0x803B
+ ALPHA8 = 0x803C
+ INTENSITY = 0x8049
+ INTENSITY12 = 0x804C
+ INTENSITY16 = 0x804D
+ INTENSITY4 = 0x804A
+ INTENSITY8 = 0x804B
+ LUMINANCE12 = 0x8041
+ LUMINANCE12_ALPHA12 = 0x8047
+ LUMINANCE12_ALPHA4 = 0x8046
+ LUMINANCE16 = 0x8042
+ LUMINANCE16_ALPHA16 = 0x8048
+ LUMINANCE4 = 0x803F
+ LUMINANCE4_ALPHA4 = 0x8043
+ LUMINANCE6_ALPHA2 = 0x8044
+ LUMINANCE8 = 0x8040
+ LUMINANCE8_ALPHA8 = 0x8045
+ R3_G3_B2 = 0x2A10
+ RGB10 = 0x8052
+ RGB10_A2 = 0x8059
+ RGB12 = 0x8053
+ RGB16 = 0x8054
+ RGB4 = 0x804F
+ RGB5 = 0x8050
+ RGB5_A1 = 0x8057
+ RGB8 = 0x8051
+ RGBA12 = 0x805A
+ RGBA16 = 0x805B
+ RGBA2 = 0x8055
+ RGBA4 = 0x8056
+ RGBA8 = 0x8058
+
+ PACK_IMAGE_HEIGHT = 0x806C
+ PACK_SKIP_IMAGES = 0x806B
+ UNPACK_IMAGE_HEIGHT = 0x806E
+ UNPACK_SKIP_IMAGES = 0x806D
+
+ BITMAP = 0x1A00
+ UNSIGNED_BYTE_3_3_2 = 0x8032
+ UNSIGNED_INT_10_10_10_2 = 0x8036
+ UNSIGNED_INT_8_8_8_8 = 0x8035
+ UNSIGNED_SHORT_4_4_4_4 = 0x8033
+ UNSIGNED_SHORT_5_5_5_1 = 0x8034
+
+ LINES = 0x0001
+ LINE_LOOP = 0x0002
+ LINE_STRIP = 0x0003
+ POINTS = 0x0000
+ POLYGON = 0x0009
+ QUADS = 0x0007
+ QUAD_STRIP = 0x0008
+ TRIANGLES = 0x0004
+ TRIANGLE_FAN = 0x0006
+ TRIANGLE_STRIP = 0x0005
+
+ FEEDBACK = 0x1C01
+ RENDER = 0x1C00
+ SELECT = 0x1C02
+
+ FLAT = 0x1D00
+ SMOOTH = 0x1D01
+
+ DECR = 0x1E03
+ INCR = 0x1E02
+ KEEP = 0x1E00
+
+ EXTENSIONS = 0x1F03
+ RENDERER = 0x1F01
+ VENDOR = 0x1F00
+ VERSION = 0x1F02
+
+ S = 0x2000
+ T = 0x2001
+ R = 0x2002
+ Q = 0x2003
+
+ DECAL = 0x2101
+
+ TEXTURE_ENV_COLOR = 0x2201
+ TEXTURE_ENV_MODE = 0x2200
+
+ TEXTURE_ENV = 0x2300
+
+ EYE_LINEAR = 0x2400
+ OBJECT_LINEAR = 0x2401
+ SPHERE_MAP = 0x2402
+
+ EYE_PLANE = 0x2502
+ OBJECT_PLANE = 0x2501
+ TEXTURE_GEN_MODE = 0x2500
+
+ NEAREST = 0x2600
+
+ LINEAR_MIPMAP_LINEAR = 0x2703
+ LINEAR_MIPMAP_NEAREST = 0x2701
+ NEAREST_MIPMAP_LINEAR = 0x2702
+ NEAREST_MIPMAP_NEAREST = 0x2700
+
+ TEXTURE_WRAP_R = 0x8072
+
+ PROXY_TEXTURE_1D = 0x8063
+ PROXY_TEXTURE_2D = 0x8064
+ PROXY_TEXTURE_3D = 0x8070
+ TEXTURE_3D = 0x806F
+ TEXTURE_BASE_LEVEL = 0x813C
+ TEXTURE_MAX_LEVEL = 0x813D
+ TEXTURE_MAX_LOD = 0x813B
+ TEXTURE_MIN_LOD = 0x813A
+
+ CLAMP = 0x2900
+ CLAMP_TO_EDGE = 0x812F
+ REPEAT = 0x2901
+
+ RESCALE_NORMAL = 0x803A
+ TEXTURE_DEPTH = 0x8071
+ MAX_3D_TEXTURE_SIZE = 0x8073
+ BGR = 0x80E0
+ BGRA = 0x80E1
+ MAX_ELEMENTS_VERTICES = 0x80E8
+ MAX_ELEMENTS_INDICES = 0x80E9
+ UNSIGNED_BYTE_2_3_3_REV = 0x8362
+ UNSIGNED_SHORT_5_6_5 = 0x8363
+ UNSIGNED_SHORT_5_6_5_REV = 0x8364
+ UNSIGNED_SHORT_4_4_4_4_REV = 0x8365
+ UNSIGNED_SHORT_1_5_5_5_REV = 0x8366
+ UNSIGNED_INT_8_8_8_8_REV = 0x8367
+ UNSIGNED_INT_2_10_10_10_REV = 0x8368
+)
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glViewport.xml
+func (gl *GL) Viewport(x, y, width, height int) {
+ C.gl1_2_glViewport(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// DepthRange specifies the mapping of depth values from normalized device
+// coordinates to window coordinates.
+//
+// Parameter nearVal specifies the mapping of the near clipping plane to window
+// coordinates (defaults to 0), while farVal specifies the mapping of the far
+// clipping plane to window coordinates (defaults to 1).
+//
+// After clipping and division by w, depth coordinates range from -1 to 1,
+// corresponding to the near and far clipping planes. DepthRange specifies a
+// linear mapping of the normalized depth coordinates in this range to window
+// depth coordinates. Regardless of the actual depth buffer implementation,
+// window coordinate depth values are treated as though they range from 0 through 1
+// (like color components). Thus, the values accepted by DepthRange are both
+// clamped to this range before they are accepted.
+//
+// The default setting of (0, 1) maps the near plane to 0 and the far plane to 1.
+// With this mapping, the depth buffer range is fully utilized.
+//
+// It is not necessary that nearVal be less than farVal. Reverse mappings such as
+// nearVal 1, and farVal 0 are acceptable.
+//
+// GL.INVALID_OPERATION is generated if DepthRange is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) DepthRange(nearVal, farVal float64) {
+ C.gl1_2_glDepthRange(gl.funcs, C.GLdouble(nearVal), C.GLdouble(farVal))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIsEnabled.xml
+func (gl *GL) IsEnabled(cap glbase.Enum) bool {
+ glresult := C.gl1_2_glIsEnabled(gl.funcs, C.GLenum(cap))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexLevelParameteriv.xml
+func (gl *GL) GetTexLevelParameteriv(target glbase.Enum, level int, pname glbase.Enum, params []int32) {
+ C.gl1_2_glGetTexLevelParameteriv(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexLevelParameterfv.xml
+func (gl *GL) GetTexLevelParameterfv(target glbase.Enum, level int, pname glbase.Enum, params []float32) {
+ C.gl1_2_glGetTexLevelParameterfv(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexParameteriv.xml
+func (gl *GL) GetTexParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl1_2_glGetTexParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexParameterfv.xml
+func (gl *GL) GetTexParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl1_2_glGetTexParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexImage.xml
+func (gl *GL) GetTexImage(target glbase.Enum, level int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_2_glGetTexImage(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetIntegerv.xml
+func (gl *GL) GetIntegerv(pname glbase.Enum, params []int32) {
+ C.gl1_2_glGetIntegerv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetFloatv.xml
+func (gl *GL) GetFloatv(pname glbase.Enum, params []float32) {
+ C.gl1_2_glGetFloatv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetError.xml
+func (gl *GL) GetError() glbase.Enum {
+ glresult := C.gl1_2_glGetError(gl.funcs)
+ return glbase.Enum(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetDoublev.xml
+func (gl *GL) GetDoublev(pname glbase.Enum, params []float64) {
+ C.gl1_2_glGetDoublev(gl.funcs, C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetBooleanv.xml
+func (gl *GL) GetBooleanv(pname glbase.Enum, params []bool) {
+ C.gl1_2_glGetBooleanv(gl.funcs, C.GLenum(pname), (*C.GLboolean)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glReadPixels.xml
+func (gl *GL) ReadPixels(x, y, width, height int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_2_glReadPixels(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glReadBuffer.xml
+func (gl *GL) ReadBuffer(mode glbase.Enum) {
+ C.gl1_2_glReadBuffer(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelStorei.xml
+func (gl *GL) PixelStorei(pname glbase.Enum, param int32) {
+ C.gl1_2_glPixelStorei(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelStoref.xml
+func (gl *GL) PixelStoref(pname glbase.Enum, param float32) {
+ C.gl1_2_glPixelStoref(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDepthFunc.xml
+func (gl *GL) DepthFunc(glfunc glbase.Enum) {
+ C.gl1_2_glDepthFunc(gl.funcs, C.GLenum(glfunc))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glStencilOp.xml
+func (gl *GL) StencilOp(fail, zfail, zpass glbase.Enum) {
+ C.gl1_2_glStencilOp(gl.funcs, C.GLenum(fail), C.GLenum(zfail), C.GLenum(zpass))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glStencilFunc.xml
+func (gl *GL) StencilFunc(glfunc glbase.Enum, ref int32, mask uint32) {
+ C.gl1_2_glStencilFunc(gl.funcs, C.GLenum(glfunc), C.GLint(ref), C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLogicOp.xml
+func (gl *GL) LogicOp(opcode glbase.Enum) {
+ C.gl1_2_glLogicOp(gl.funcs, C.GLenum(opcode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBlendFunc.xml
+func (gl *GL) BlendFunc(sfactor, dfactor glbase.Enum) {
+ C.gl1_2_glBlendFunc(gl.funcs, C.GLenum(sfactor), C.GLenum(dfactor))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFlush.xml
+func (gl *GL) Flush() {
+ C.gl1_2_glFlush(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFinish.xml
+func (gl *GL) Finish() {
+ C.gl1_2_glFinish(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEnable.xml
+func (gl *GL) Enable(cap glbase.Enum) {
+ C.gl1_2_glEnable(gl.funcs, C.GLenum(cap))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDisable.xml
+func (gl *GL) Disable(cap glbase.Enum) {
+ C.gl1_2_glDisable(gl.funcs, C.GLenum(cap))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDepthMask.xml
+func (gl *GL) DepthMask(flag bool) {
+ C.gl1_2_glDepthMask(gl.funcs, *(*C.GLboolean)(unsafe.Pointer(&flag)))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColorMask.xml
+func (gl *GL) ColorMask(red, green, blue, alpha bool) {
+ C.gl1_2_glColorMask(gl.funcs, *(*C.GLboolean)(unsafe.Pointer(&red)), *(*C.GLboolean)(unsafe.Pointer(&green)), *(*C.GLboolean)(unsafe.Pointer(&blue)), *(*C.GLboolean)(unsafe.Pointer(&alpha)))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glStencilMask.xml
+func (gl *GL) StencilMask(mask uint32) {
+ C.gl1_2_glStencilMask(gl.funcs, C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClearDepth.xml
+func (gl *GL) ClearDepth(depth float64) {
+ C.gl1_2_glClearDepth(gl.funcs, C.GLdouble(depth))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClearStencil.xml
+func (gl *GL) ClearStencil(s int32) {
+ C.gl1_2_glClearStencil(gl.funcs, C.GLint(s))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClearColor.xml
+func (gl *GL) ClearColor(red, green, blue, alpha float32) {
+ C.gl1_2_glClearColor(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClear.xml
+func (gl *GL) Clear(mask glbase.Bitfield) {
+ C.gl1_2_glClear(gl.funcs, C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDrawBuffer.xml
+func (gl *GL) DrawBuffer(mode glbase.Enum) {
+ C.gl1_2_glDrawBuffer(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexImage2D.xml
+func (gl *GL) TexImage2D(target glbase.Enum, level int, internalFormat int32, width, height, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_2_glTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexImage1D.xml
+func (gl *GL) TexImage1D(target glbase.Enum, level int, internalFormat int32, width, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_2_glTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexParameteriv.xml
+func (gl *GL) TexParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl1_2_glTexParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexParameteri.xml
+func (gl *GL) TexParameteri(target, pname glbase.Enum, param int32) {
+ C.gl1_2_glTexParameteri(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexParameterfv.xml
+func (gl *GL) TexParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl1_2_glTexParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexParameterf.xml
+func (gl *GL) TexParameterf(target, pname glbase.Enum, param float32) {
+ C.gl1_2_glTexParameterf(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glScissor.xml
+func (gl *GL) Scissor(x, y, width, height int) {
+ C.gl1_2_glScissor(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPolygonMode.xml
+func (gl *GL) PolygonMode(face, mode glbase.Enum) {
+ C.gl1_2_glPolygonMode(gl.funcs, C.GLenum(face), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPointSize.xml
+func (gl *GL) PointSize(size float32) {
+ C.gl1_2_glPointSize(gl.funcs, C.GLfloat(size))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLineWidth.xml
+func (gl *GL) LineWidth(width float32) {
+ C.gl1_2_glLineWidth(gl.funcs, C.GLfloat(width))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glHint.xml
+func (gl *GL) Hint(target, mode glbase.Enum) {
+ C.gl1_2_glHint(gl.funcs, C.GLenum(target), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFrontFace.xml
+func (gl *GL) FrontFace(mode glbase.Enum) {
+ C.gl1_2_glFrontFace(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCullFace.xml
+func (gl *GL) CullFace(mode glbase.Enum) {
+ C.gl1_2_glCullFace(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexubv.xml
+func (gl *GL) Indexubv(c []uint8) {
+ C.gl1_2_glIndexubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexub.xml
+func (gl *GL) Indexub(c uint8) {
+ C.gl1_2_glIndexub(gl.funcs, C.GLubyte(c))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIsTexture.xml
+func (gl *GL) IsTexture(texture glbase.Texture) bool {
+ glresult := C.gl1_2_glIsTexture(gl.funcs, C.GLuint(texture))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// GenTextures returns n texture names in textures. There is no guarantee
+// that the names form a contiguous set of integers; however, it is
+// guaranteed that none of the returned names was in use immediately before
+// the call to GenTextures.
+//
+// The generated textures have no dimensionality; they assume the
+// dimensionality of the texture target to which they are first bound (see
+// BindTexture).
+//
+// Texture names returned by a call to GenTextures are not returned by
+// subsequent calls, unless they are first deleted with DeleteTextures.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// GenTextures is available in GL version 2.0 or greater.
+func (gl *GL) GenTextures(n int) []glbase.Texture {
+ if n == 0 {
+ return nil
+ }
+ textures := make([]glbase.Texture, n)
+ C.gl1_2_glGenTextures(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])))
+ return textures
+}
+
+// DeleteTextures deletes the textures objects whose names are stored
+// in the textures slice. After a texture is deleted, it has no contents or
+// dimensionality, and its name is free for reuse (for example by
+// GenTextures). If a texture that is currently bound is deleted, the binding
+// reverts to 0 (the default texture).
+//
+// DeleteTextures silently ignores 0's and names that do not correspond to
+// existing textures.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// DeleteTextures is available in GL version 2.0 or greater.
+func (gl *GL) DeleteTextures(textures []glbase.Texture) {
+ n := len(textures)
+ if n == 0 {
+ return
+ }
+ C.gl1_2_glDeleteTextures(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBindTexture.xml
+func (gl *GL) BindTexture(target glbase.Enum, texture glbase.Texture) {
+ C.gl1_2_glBindTexture(gl.funcs, C.GLenum(target), C.GLuint(texture))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexSubImage2D.xml
+func (gl *GL) TexSubImage2D(target glbase.Enum, level, xoffset, yoffset, width, height int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_2_glTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexSubImage1D.xml
+func (gl *GL) TexSubImage1D(target glbase.Enum, level, xoffset, width int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_2_glTexSubImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLsizei(width), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyTexSubImage2D.xml
+func (gl *GL) CopyTexSubImage2D(target glbase.Enum, level, xoffset, yoffset, x, y, width, height int) {
+ C.gl1_2_glCopyTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyTexSubImage1D.xml
+func (gl *GL) CopyTexSubImage1D(target glbase.Enum, level, xoffset, x, y, width int) {
+ C.gl1_2_glCopyTexSubImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(x), C.GLint(y), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyTexImage2D.xml
+func (gl *GL) CopyTexImage2D(target glbase.Enum, level int, internalFormat glbase.Enum, x, y, width, height, border int) {
+ C.gl1_2_glCopyTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height), C.GLint(border))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyTexImage1D.xml
+func (gl *GL) CopyTexImage1D(target glbase.Enum, level int, internalFormat glbase.Enum, x, y, width, border int) {
+ C.gl1_2_glCopyTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLint(border))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPolygonOffset.xml
+func (gl *GL) PolygonOffset(factor, units float32) {
+ C.gl1_2_glPolygonOffset(gl.funcs, C.GLfloat(factor), C.GLfloat(units))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDrawElements.xml
+func (gl *GL) DrawElements(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_2_glDrawElements(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDrawArrays.xml
+func (gl *GL) DrawArrays(mode glbase.Enum, first, count int) {
+ C.gl1_2_glDrawArrays(gl.funcs, C.GLenum(mode), C.GLint(first), C.GLsizei(count))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyTexSubImage3D.xml
+func (gl *GL) CopyTexSubImage3D(target glbase.Enum, level, xoffset, yoffset int, zoffset int32, x, y, width, height int) {
+ C.gl1_2_glCopyTexSubImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(zoffset), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexSubImage3D.xml
+func (gl *GL) TexSubImage3D(target glbase.Enum, level, xoffset, yoffset int, zoffset int32, width, height int, depth int32, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_2_glTexSubImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(zoffset), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexImage3D.xml
+func (gl *GL) TexImage3D(target glbase.Enum, level int, internalFormat int32, width, height int, depth int32, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_2_glTexImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDrawRangeElements.xml
+func (gl *GL) DrawRangeElements(mode glbase.Enum, start, end uint32, count int, gltype glbase.Enum, indices interface{}) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_2_glDrawRangeElements(gl.funcs, C.GLenum(mode), C.GLuint(start), C.GLuint(end), C.GLsizei(count), C.GLenum(gltype), indices_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBlendEquation.xml
+func (gl *GL) BlendEquation(mode glbase.Enum) {
+ C.gl1_2_glBlendEquation(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBlendColor.xml
+func (gl *GL) BlendColor(red, green, blue, alpha float32) {
+ C.gl1_2_glBlendColor(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTranslatef.xml
+func (gl *GL) Translatef(x, y, z float32) {
+ C.gl1_2_glTranslatef(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTranslated.xml
+func (gl *GL) Translated(x, y, z float64) {
+ C.gl1_2_glTranslated(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glScalef.xml
+func (gl *GL) Scalef(x, y, z float32) {
+ C.gl1_2_glScalef(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glScaled.xml
+func (gl *GL) Scaled(x, y, z float64) {
+ C.gl1_2_glScaled(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRotatef.xml
+func (gl *GL) Rotatef(angle, x, y, z float32) {
+ C.gl1_2_glRotatef(gl.funcs, C.GLfloat(angle), C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRotated.xml
+func (gl *GL) Rotated(angle, x, y, z float64) {
+ C.gl1_2_glRotated(gl.funcs, C.GLdouble(angle), C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPushMatrix.xml
+func (gl *GL) PushMatrix() {
+ C.gl1_2_glPushMatrix(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPopMatrix.xml
+func (gl *GL) PopMatrix() {
+ C.gl1_2_glPopMatrix(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glOrtho.xml
+func (gl *GL) Ortho(left, right, bottom, top, zNear, zFar float64) {
+ C.gl1_2_glOrtho(gl.funcs, C.GLdouble(left), C.GLdouble(right), C.GLdouble(bottom), C.GLdouble(top), C.GLdouble(zNear), C.GLdouble(zFar))
+}
+
+// MultMatrixd multiplies the current matrix with the provided matrix.
+//
+// The m parameter must hold 16 consecutive elements of a 4x4 column-major matrix.
+//
+// The current matrix is determined by the current matrix mode (see
+// MatrixMode). It is either the projection matrix, modelview matrix, or the
+// texture matrix.
+//
+// For example, if the current matrix is C and the coordinates to be transformed
+// are v = (v[0], v[1], v[2], v[3]), then the current transformation is C × v, or
+//
+// c[0] c[4] c[8] c[12] v[0]
+// c[1] c[5] c[9] c[13] v[1]
+// c[2] c[6] c[10] c[14] X v[2]
+// c[3] c[7] c[11] c[15] v[3]
+//
+// Calling MultMatrix with an argument of m = m[0], m[1], ..., m[15]
+// replaces the current transformation with (C X M) x v, or
+//
+// c[0] c[4] c[8] c[12] m[0] m[4] m[8] m[12] v[0]
+// c[1] c[5] c[9] c[13] m[1] m[5] m[9] m[13] v[1]
+// c[2] c[6] c[10] c[14] X m[2] m[6] m[10] m[14] X v[2]
+// c[3] c[7] c[11] c[15] m[3] m[7] m[11] m[15] v[3]
+//
+// Where 'X' denotes matrix multiplication, and v is represented as a 4x1 matrix.
+//
+// While the elements of the matrix may be specified with single or double
+// precision, the GL may store or operate on these values in less-than-single
+// precision.
+//
+// In many computer languages, 4×4 arrays are represented in row-major
+// order. The transformations just described represent these matrices in
+// column-major order. The order of the multiplication is important. For
+// example, if the current transformation is a rotation, and MultMatrix is
+// called with a translation matrix, the translation is done directly on the
+// coordinates to be transformed, while the rotation is done on the results
+// of that translation.
+//
+// GL.INVALID_OPERATION is generated if MultMatrix is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) MultMatrixd(m []float64) {
+ if len(m) != 16 {
+ panic("parameter m must have length 16 for the 4x4 matrix")
+ }
+ C.gl1_2_glMultMatrixd(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&m[0])))
+}
+
+// MultMatrixf multiplies the current matrix with the provided matrix.
+//
+// The m parameter must hold 16 consecutive elements of a 4x4 column-major matrix.
+//
+// The current matrix is determined by the current matrix mode (see
+// MatrixMode). It is either the projection matrix, modelview matrix, or the
+// texture matrix.
+//
+// For example, if the current matrix is C and the coordinates to be transformed
+// are v = (v[0], v[1], v[2], v[3]), then the current transformation is C × v, or
+//
+// c[0] c[4] c[8] c[12] v[0]
+// c[1] c[5] c[9] c[13] v[1]
+// c[2] c[6] c[10] c[14] X v[2]
+// c[3] c[7] c[11] c[15] v[3]
+//
+// Calling MultMatrix with an argument of m = m[0], m[1], ..., m[15]
+// replaces the current transformation with (C X M) x v, or
+//
+// c[0] c[4] c[8] c[12] m[0] m[4] m[8] m[12] v[0]
+// c[1] c[5] c[9] c[13] m[1] m[5] m[9] m[13] v[1]
+// c[2] c[6] c[10] c[14] X m[2] m[6] m[10] m[14] X v[2]
+// c[3] c[7] c[11] c[15] m[3] m[7] m[11] m[15] v[3]
+//
+// Where 'X' denotes matrix multiplication, and v is represented as a 4x1 matrix.
+//
+// While the elements of the matrix may be specified with single or double
+// precision, the GL may store or operate on these values in less-than-single
+// precision.
+//
+// In many computer languages, 4×4 arrays are represented in row-major
+// order. The transformations just described represent these matrices in
+// column-major order. The order of the multiplication is important. For
+// example, if the current transformation is a rotation, and MultMatrix is
+// called with a translation matrix, the translation is done directly on the
+// coordinates to be transformed, while the rotation is done on the results
+// of that translation.
+//
+// GL.INVALID_OPERATION is generated if MultMatrix is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) MultMatrixf(m []float32) {
+ if len(m) != 16 {
+ panic("parameter m must have length 16 for the 4x4 matrix")
+ }
+ C.gl1_2_glMultMatrixf(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMatrixMode.xml
+func (gl *GL) MatrixMode(mode glbase.Enum) {
+ C.gl1_2_glMatrixMode(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLoadMatrixd.xml
+func (gl *GL) LoadMatrixd(m []float64) {
+ C.gl1_2_glLoadMatrixd(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLoadMatrixf.xml
+func (gl *GL) LoadMatrixf(m []float32) {
+ C.gl1_2_glLoadMatrixf(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLoadIdentity.xml
+func (gl *GL) LoadIdentity() {
+ C.gl1_2_glLoadIdentity(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFrustum.xml
+func (gl *GL) Frustum(left, right, bottom, top, zNear, zFar float64) {
+ C.gl1_2_glFrustum(gl.funcs, C.GLdouble(left), C.GLdouble(right), C.GLdouble(bottom), C.GLdouble(top), C.GLdouble(zNear), C.GLdouble(zFar))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIsList.xml
+func (gl *GL) IsList(list uint32) bool {
+ glresult := C.gl1_2_glIsList(gl.funcs, C.GLuint(list))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexGeniv.xml
+func (gl *GL) GetTexGeniv(coord, pname glbase.Enum, params []int32) {
+ C.gl1_2_glGetTexGeniv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexGenfv.xml
+func (gl *GL) GetTexGenfv(coord, pname glbase.Enum, params []float32) {
+ C.gl1_2_glGetTexGenfv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexGendv.xml
+func (gl *GL) GetTexGendv(coord, pname glbase.Enum, params []float64) {
+ C.gl1_2_glGetTexGendv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexEnviv.xml
+func (gl *GL) GetTexEnviv(target, pname glbase.Enum, params []int32) {
+ C.gl1_2_glGetTexEnviv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexEnvfv.xml
+func (gl *GL) GetTexEnvfv(target, pname glbase.Enum, params []float32) {
+ C.gl1_2_glGetTexEnvfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetPolygonStipple.xml
+func (gl *GL) GetPolygonStipple(mask []uint8) {
+ C.gl1_2_glGetPolygonStipple(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&mask[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetPixelMapusv.xml
+func (gl *GL) GetPixelMapusv(glmap glbase.Enum, values []uint16) {
+ C.gl1_2_glGetPixelMapusv(gl.funcs, C.GLenum(glmap), (*C.GLushort)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetPixelMapuiv.xml
+func (gl *GL) GetPixelMapuiv(glmap glbase.Enum, values []uint32) {
+ C.gl1_2_glGetPixelMapuiv(gl.funcs, C.GLenum(glmap), (*C.GLuint)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetPixelMapfv.xml
+func (gl *GL) GetPixelMapfv(glmap glbase.Enum, values []float32) {
+ C.gl1_2_glGetPixelMapfv(gl.funcs, C.GLenum(glmap), (*C.GLfloat)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetMaterialiv.xml
+func (gl *GL) GetMaterialiv(face, pname glbase.Enum, params []int32) {
+ C.gl1_2_glGetMaterialiv(gl.funcs, C.GLenum(face), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetMaterialfv.xml
+func (gl *GL) GetMaterialfv(face, pname glbase.Enum, params []float32) {
+ C.gl1_2_glGetMaterialfv(gl.funcs, C.GLenum(face), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetMapiv.xml
+func (gl *GL) GetMapiv(target, query glbase.Enum, v []int32) {
+ C.gl1_2_glGetMapiv(gl.funcs, C.GLenum(target), C.GLenum(query), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetMapfv.xml
+func (gl *GL) GetMapfv(target, query glbase.Enum, v []float32) {
+ C.gl1_2_glGetMapfv(gl.funcs, C.GLenum(target), C.GLenum(query), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetMapdv.xml
+func (gl *GL) GetMapdv(target, query glbase.Enum, v []float64) {
+ C.gl1_2_glGetMapdv(gl.funcs, C.GLenum(target), C.GLenum(query), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetLightiv.xml
+func (gl *GL) GetLightiv(light, pname glbase.Enum, params []int32) {
+ C.gl1_2_glGetLightiv(gl.funcs, C.GLenum(light), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetLightfv.xml
+func (gl *GL) GetLightfv(light, pname glbase.Enum, params []float32) {
+ C.gl1_2_glGetLightfv(gl.funcs, C.GLenum(light), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetClipPlane.xml
+func (gl *GL) GetClipPlane(plane glbase.Enum, equation []float64) {
+ C.gl1_2_glGetClipPlane(gl.funcs, C.GLenum(plane), (*C.GLdouble)(unsafe.Pointer(&equation[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDrawPixels.xml
+func (gl *GL) DrawPixels(width, height int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_2_glDrawPixels(gl.funcs, C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyPixels.xml
+func (gl *GL) CopyPixels(x, y, width, height int, gltype glbase.Enum) {
+ C.gl1_2_glCopyPixels(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height), C.GLenum(gltype))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelMapusv.xml
+func (gl *GL) PixelMapusv(glmap glbase.Enum, mapsize int32, values []uint16) {
+ C.gl1_2_glPixelMapusv(gl.funcs, C.GLenum(glmap), C.GLint(mapsize), (*C.GLushort)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelMapuiv.xml
+func (gl *GL) PixelMapuiv(glmap glbase.Enum, mapsize int32, values []uint32) {
+ C.gl1_2_glPixelMapuiv(gl.funcs, C.GLenum(glmap), C.GLint(mapsize), (*C.GLuint)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelMapfv.xml
+func (gl *GL) PixelMapfv(glmap glbase.Enum, mapsize int32, values []float32) {
+ C.gl1_2_glPixelMapfv(gl.funcs, C.GLenum(glmap), C.GLint(mapsize), (*C.GLfloat)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelTransferi.xml
+func (gl *GL) PixelTransferi(pname glbase.Enum, param int32) {
+ C.gl1_2_glPixelTransferi(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelTransferf.xml
+func (gl *GL) PixelTransferf(pname glbase.Enum, param float32) {
+ C.gl1_2_glPixelTransferf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelZoom.xml
+func (gl *GL) PixelZoom(xfactor, yfactor float32) {
+ C.gl1_2_glPixelZoom(gl.funcs, C.GLfloat(xfactor), C.GLfloat(yfactor))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glAlphaFunc.xml
+func (gl *GL) AlphaFunc(glfunc glbase.Enum, ref float32) {
+ C.gl1_2_glAlphaFunc(gl.funcs, C.GLenum(glfunc), C.GLfloat(ref))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalPoint2.xml
+func (gl *GL) EvalPoint2(i, j int32) {
+ C.gl1_2_glEvalPoint2(gl.funcs, C.GLint(i), C.GLint(j))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalMesh2.xml
+func (gl *GL) EvalMesh2(mode glbase.Enum, i1, i2, j1, j2 int32) {
+ C.gl1_2_glEvalMesh2(gl.funcs, C.GLenum(mode), C.GLint(i1), C.GLint(i2), C.GLint(j1), C.GLint(j2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalPoint1.xml
+func (gl *GL) EvalPoint1(i int32) {
+ C.gl1_2_glEvalPoint1(gl.funcs, C.GLint(i))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalMesh1.xml
+func (gl *GL) EvalMesh1(mode glbase.Enum, i1, i2 int32) {
+ C.gl1_2_glEvalMesh1(gl.funcs, C.GLenum(mode), C.GLint(i1), C.GLint(i2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord2fv.xml
+func (gl *GL) EvalCoord2fv(u []float32) {
+ if len(u) != 2 {
+ panic("parameter u has incorrect length")
+ }
+ C.gl1_2_glEvalCoord2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&u[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord2f.xml
+func (gl *GL) EvalCoord2f(u, v float32) {
+ C.gl1_2_glEvalCoord2f(gl.funcs, C.GLfloat(u), C.GLfloat(v))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord2dv.xml
+func (gl *GL) EvalCoord2dv(u []float64) {
+ if len(u) != 2 {
+ panic("parameter u has incorrect length")
+ }
+ C.gl1_2_glEvalCoord2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&u[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord2d.xml
+func (gl *GL) EvalCoord2d(u, v float64) {
+ C.gl1_2_glEvalCoord2d(gl.funcs, C.GLdouble(u), C.GLdouble(v))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord1fv.xml
+func (gl *GL) EvalCoord1fv(u []float32) {
+ C.gl1_2_glEvalCoord1fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&u[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord1f.xml
+func (gl *GL) EvalCoord1f(u float32) {
+ C.gl1_2_glEvalCoord1f(gl.funcs, C.GLfloat(u))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord1dv.xml
+func (gl *GL) EvalCoord1dv(u []float64) {
+ C.gl1_2_glEvalCoord1dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&u[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord1d.xml
+func (gl *GL) EvalCoord1d(u float64) {
+ C.gl1_2_glEvalCoord1d(gl.funcs, C.GLdouble(u))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMapGrid2f.xml
+func (gl *GL) MapGrid2f(un int32, u1, u2 float32, vn int32, v1, v2 float32) {
+ C.gl1_2_glMapGrid2f(gl.funcs, C.GLint(un), C.GLfloat(u1), C.GLfloat(u2), C.GLint(vn), C.GLfloat(v1), C.GLfloat(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMapGrid2d.xml
+func (gl *GL) MapGrid2d(un int32, u1, u2 float64, vn int32, v1, v2 float64) {
+ C.gl1_2_glMapGrid2d(gl.funcs, C.GLint(un), C.GLdouble(u1), C.GLdouble(u2), C.GLint(vn), C.GLdouble(v1), C.GLdouble(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMapGrid1f.xml
+func (gl *GL) MapGrid1f(un int32, u1, u2 float32) {
+ C.gl1_2_glMapGrid1f(gl.funcs, C.GLint(un), C.GLfloat(u1), C.GLfloat(u2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMapGrid1d.xml
+func (gl *GL) MapGrid1d(un int32, u1, u2 float64) {
+ C.gl1_2_glMapGrid1d(gl.funcs, C.GLint(un), C.GLdouble(u1), C.GLdouble(u2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMap2f.xml
+func (gl *GL) Map2f(target glbase.Enum, u1, u2 float32, ustride, uorder int32, v1, v2 float32, vstride, vorder int32, points []float32) {
+ C.gl1_2_glMap2f(gl.funcs, C.GLenum(target), C.GLfloat(u1), C.GLfloat(u2), C.GLint(ustride), C.GLint(uorder), C.GLfloat(v1), C.GLfloat(v2), C.GLint(vstride), C.GLint(vorder), (*C.GLfloat)(unsafe.Pointer(&points[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMap2d.xml
+func (gl *GL) Map2d(target glbase.Enum, u1, u2 float64, ustride, uorder int32, v1, v2 float64, vstride, vorder int32, points []float64) {
+ C.gl1_2_glMap2d(gl.funcs, C.GLenum(target), C.GLdouble(u1), C.GLdouble(u2), C.GLint(ustride), C.GLint(uorder), C.GLdouble(v1), C.GLdouble(v2), C.GLint(vstride), C.GLint(vorder), (*C.GLdouble)(unsafe.Pointer(&points[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMap1f.xml
+func (gl *GL) Map1f(target glbase.Enum, u1, u2 float32, stride, order int, points []float32) {
+ C.gl1_2_glMap1f(gl.funcs, C.GLenum(target), C.GLfloat(u1), C.GLfloat(u2), C.GLint(stride), C.GLint(order), (*C.GLfloat)(unsafe.Pointer(&points[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMap1d.xml
+func (gl *GL) Map1d(target glbase.Enum, u1, u2 float64, stride, order int, points []float64) {
+ C.gl1_2_glMap1d(gl.funcs, C.GLenum(target), C.GLdouble(u1), C.GLdouble(u2), C.GLint(stride), C.GLint(order), (*C.GLdouble)(unsafe.Pointer(&points[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPushAttrib.xml
+func (gl *GL) PushAttrib(mask glbase.Bitfield) {
+ C.gl1_2_glPushAttrib(gl.funcs, C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPopAttrib.xml
+func (gl *GL) PopAttrib() {
+ C.gl1_2_glPopAttrib(gl.funcs)
+}
+
+// Accum executes an operation on the accumulation buffer.
+//
+// Parameter op defines the accumulation buffer operation (GL.ACCUM, GL.LOAD,
+// GL.ADD, GL.MULT, or GL.RETURN) and specifies how the value parameter is
+// used.
+//
+// The accumulation buffer is an extended-range color buffer. Images are not
+// rendered into it. Rather, images rendered into one of the color buffers
+// are added to the contents of the accumulation buffer after rendering.
+// Effects such as antialiasing (of points, lines, and polygons), motion
+// blur, and depth of field can be created by accumulating images generated
+// with different transformation matrices.
+//
+// Each pixel in the accumulation buffer consists of red, green, blue, and
+// alpha values. The number of bits per component in the accumulation buffer
+// depends on the implementation. You can examine this number by calling
+// GetIntegerv four times, with arguments GL.ACCUM_RED_BITS,
+// GL.ACCUM_GREEN_BITS, GL.ACCUM_BLUE_BITS, and GL.ACCUM_ALPHA_BITS.
+// Regardless of the number of bits per component, the range of values stored
+// by each component is (-1, 1). The accumulation buffer pixels are mapped
+// one-to-one with frame buffer pixels.
+//
+// All accumulation buffer operations are limited to the area of the current
+// scissor box and applied identically to the red, green, blue, and alpha
+// components of each pixel. If a Accum operation results in a value outside
+// the range (-1, 1), the contents of an accumulation buffer pixel component
+// are undefined.
+//
+// The operations are as follows:
+//
+// GL.ACCUM
+// Obtains R, G, B, and A values from the buffer currently selected for
+// reading (see ReadBuffer). Each component value is divided by 2 n -
+// 1 , where n is the number of bits allocated to each color component
+// in the currently selected buffer. The result is a floating-point
+// value in the range 0 1 , which is multiplied by value and added to
+// the corresponding pixel component in the accumulation buffer,
+// thereby updating the accumulation buffer.
+//
+// GL.LOAD
+// Similar to GL.ACCUM, except that the current value in the
+// accumulation buffer is not used in the calculation of the new value.
+// That is, the R, G, B, and A values from the currently selected
+// buffer are divided by 2 n - 1 , multiplied by value, and then stored
+// in the corresponding accumulation buffer cell, overwriting the
+// current value.
+//
+// GL.ADD
+// Adds value to each R, G, B, and A in the accumulation buffer.
+//
+// GL.MULT
+// Multiplies each R, G, B, and A in the accumulation buffer by value
+// and returns the scaled component to its corresponding accumulation
+// buffer location.
+//
+// GL.RETURN
+// Transfers accumulation buffer values to the color buffer or buffers
+// currently selected for writing. Each R, G, B, and A component is
+// multiplied by value, then multiplied by 2 n - 1 , clamped to the
+// range 0 2 n - 1 , and stored in the corresponding display buffer
+// cell. The only fragment operations that are applied to this transfer
+// are pixel ownership, scissor, dithering, and color writemasks.
+//
+// To clear the accumulation buffer, call ClearAccum with R, G, B, and A
+// values to set it to, then call Clear with the accumulation buffer
+// enabled.
+//
+// Error GL.INVALID_ENUM is generated if op is not an accepted value.
+// GL.INVALID_OPERATION is generated if there is no accumulation buffer.
+// GL.INVALID_OPERATION is generated if Accum is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) Accum(op glbase.Enum, value float32) {
+ C.gl1_2_glAccum(gl.funcs, C.GLenum(op), C.GLfloat(value))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexMask.xml
+func (gl *GL) IndexMask(mask uint32) {
+ C.gl1_2_glIndexMask(gl.funcs, C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClearIndex.xml
+func (gl *GL) ClearIndex(c float32) {
+ C.gl1_2_glClearIndex(gl.funcs, C.GLfloat(c))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClearAccum.xml
+func (gl *GL) ClearAccum(red, green, blue, alpha float32) {
+ C.gl1_2_glClearAccum(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPushName.xml
+func (gl *GL) PushName(name uint32) {
+ C.gl1_2_glPushName(gl.funcs, C.GLuint(name))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPopName.xml
+func (gl *GL) PopName() {
+ C.gl1_2_glPopName(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPassThrough.xml
+func (gl *GL) PassThrough(token float32) {
+ C.gl1_2_glPassThrough(gl.funcs, C.GLfloat(token))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLoadName.xml
+func (gl *GL) LoadName(name uint32) {
+ C.gl1_2_glLoadName(gl.funcs, C.GLuint(name))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glInitNames.xml
+func (gl *GL) InitNames() {
+ C.gl1_2_glInitNames(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRenderMode.xml
+func (gl *GL) RenderMode(mode glbase.Enum) int32 {
+ glresult := C.gl1_2_glRenderMode(gl.funcs, C.GLenum(mode))
+ return int32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSelectBuffer.xml
+func (gl *GL) SelectBuffer(size int, buffer []glbase.Buffer) {
+ C.gl1_2_glSelectBuffer(gl.funcs, C.GLsizei(size), (*C.GLuint)(unsafe.Pointer(&buffer[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFeedbackBuffer.xml
+func (gl *GL) FeedbackBuffer(size int, gltype glbase.Enum, buffer []float32) {
+ C.gl1_2_glFeedbackBuffer(gl.funcs, C.GLsizei(size), C.GLenum(gltype), (*C.GLfloat)(unsafe.Pointer(&buffer[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexGeniv.xml
+func (gl *GL) TexGeniv(coord, pname glbase.Enum, params []int32) {
+ C.gl1_2_glTexGeniv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexGeni.xml
+func (gl *GL) TexGeni(coord, pname glbase.Enum, param int32) {
+ C.gl1_2_glTexGeni(gl.funcs, C.GLenum(coord), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexGenfv.xml
+func (gl *GL) TexGenfv(coord, pname glbase.Enum, params []float32) {
+ C.gl1_2_glTexGenfv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexGenf.xml
+func (gl *GL) TexGenf(coord, pname glbase.Enum, param float32) {
+ C.gl1_2_glTexGenf(gl.funcs, C.GLenum(coord), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexGendv.xml
+func (gl *GL) TexGendv(coord, pname glbase.Enum, params []float64) {
+ C.gl1_2_glTexGendv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexGend.xml
+func (gl *GL) TexGend(coord, pname glbase.Enum, param float64) {
+ C.gl1_2_glTexGend(gl.funcs, C.GLenum(coord), C.GLenum(pname), C.GLdouble(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexEnviv.xml
+func (gl *GL) TexEnviv(target, pname glbase.Enum, params []int32) {
+ C.gl1_2_glTexEnviv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexEnvi.xml
+func (gl *GL) TexEnvi(target, pname glbase.Enum, param int32) {
+ C.gl1_2_glTexEnvi(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexEnvfv.xml
+func (gl *GL) TexEnvfv(target, pname glbase.Enum, params []float32) {
+ C.gl1_2_glTexEnvfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexEnvf.xml
+func (gl *GL) TexEnvf(target, pname glbase.Enum, param float32) {
+ C.gl1_2_glTexEnvf(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glShadeModel.xml
+func (gl *GL) ShadeModel(mode glbase.Enum) {
+ C.gl1_2_glShadeModel(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPolygonStipple.xml
+func (gl *GL) PolygonStipple(mask []uint8) {
+ C.gl1_2_glPolygonStipple(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&mask[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMaterialiv.xml
+func (gl *GL) Materialiv(face, pname glbase.Enum, params []int32) {
+ C.gl1_2_glMaterialiv(gl.funcs, C.GLenum(face), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMateriali.xml
+func (gl *GL) Materiali(face, pname glbase.Enum, param int32) {
+ C.gl1_2_glMateriali(gl.funcs, C.GLenum(face), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMaterialfv.xml
+func (gl *GL) Materialfv(face, pname glbase.Enum, params []float32) {
+ C.gl1_2_glMaterialfv(gl.funcs, C.GLenum(face), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMaterialf.xml
+func (gl *GL) Materialf(face, pname glbase.Enum, param float32) {
+ C.gl1_2_glMaterialf(gl.funcs, C.GLenum(face), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLineStipple.xml
+func (gl *GL) LineStipple(factor int32, pattern uint16) {
+ C.gl1_2_glLineStipple(gl.funcs, C.GLint(factor), C.GLushort(pattern))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLightModeliv.xml
+func (gl *GL) LightModeliv(pname glbase.Enum, params []int32) {
+ C.gl1_2_glLightModeliv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLightModeli.xml
+func (gl *GL) LightModeli(pname glbase.Enum, param int32) {
+ C.gl1_2_glLightModeli(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLightModelfv.xml
+func (gl *GL) LightModelfv(pname glbase.Enum, params []float32) {
+ C.gl1_2_glLightModelfv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLightModelf.xml
+func (gl *GL) LightModelf(pname glbase.Enum, param float32) {
+ C.gl1_2_glLightModelf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLightiv.xml
+func (gl *GL) Lightiv(light, pname glbase.Enum, params []int32) {
+ C.gl1_2_glLightiv(gl.funcs, C.GLenum(light), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLighti.xml
+func (gl *GL) Lighti(light, pname glbase.Enum, param int32) {
+ C.gl1_2_glLighti(gl.funcs, C.GLenum(light), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLightfv.xml
+func (gl *GL) Lightfv(light, pname glbase.Enum, params []float32) {
+ C.gl1_2_glLightfv(gl.funcs, C.GLenum(light), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLightf.xml
+func (gl *GL) Lightf(light, pname glbase.Enum, param float32) {
+ C.gl1_2_glLightf(gl.funcs, C.GLenum(light), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFogiv.xml
+func (gl *GL) Fogiv(pname glbase.Enum, params []int32) {
+ C.gl1_2_glFogiv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFogi.xml
+func (gl *GL) Fogi(pname glbase.Enum, param int32) {
+ C.gl1_2_glFogi(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFogfv.xml
+func (gl *GL) Fogfv(pname glbase.Enum, params []float32) {
+ C.gl1_2_glFogfv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFogf.xml
+func (gl *GL) Fogf(pname glbase.Enum, param float32) {
+ C.gl1_2_glFogf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColorMaterial.xml
+func (gl *GL) ColorMaterial(face, mode glbase.Enum) {
+ C.gl1_2_glColorMaterial(gl.funcs, C.GLenum(face), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClipPlane.xml
+func (gl *GL) ClipPlane(plane glbase.Enum, equation []float64) {
+ C.gl1_2_glClipPlane(gl.funcs, C.GLenum(plane), (*C.GLdouble)(unsafe.Pointer(&equation[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4sv.xml
+func (gl *GL) Vertex4sv(v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_2_glVertex4sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4s.xml
+func (gl *GL) Vertex4s(x, y, z, w int16) {
+ C.gl1_2_glVertex4s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z), C.GLshort(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4iv.xml
+func (gl *GL) Vertex4iv(v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_2_glVertex4iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4i.xml
+func (gl *GL) Vertex4i(x, y, z, w int) {
+ C.gl1_2_glVertex4i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z), C.GLint(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4fv.xml
+func (gl *GL) Vertex4fv(v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_2_glVertex4fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4f.xml
+func (gl *GL) Vertex4f(x, y, z, w float32) {
+ C.gl1_2_glVertex4f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z), C.GLfloat(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4dv.xml
+func (gl *GL) Vertex4dv(v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_2_glVertex4dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4d.xml
+func (gl *GL) Vertex4d(x, y, z, w float64) {
+ C.gl1_2_glVertex4d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z), C.GLdouble(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3sv.xml
+func (gl *GL) Vertex3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_2_glVertex3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3s.xml
+func (gl *GL) Vertex3s(x, y, z int16) {
+ C.gl1_2_glVertex3s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3iv.xml
+func (gl *GL) Vertex3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_2_glVertex3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3i.xml
+func (gl *GL) Vertex3i(x, y, z int) {
+ C.gl1_2_glVertex3i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3fv.xml
+func (gl *GL) Vertex3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_2_glVertex3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3f.xml
+func (gl *GL) Vertex3f(x, y, z float32) {
+ C.gl1_2_glVertex3f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3dv.xml
+func (gl *GL) Vertex3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_2_glVertex3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3d.xml
+func (gl *GL) Vertex3d(x, y, z float64) {
+ C.gl1_2_glVertex3d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2sv.xml
+func (gl *GL) Vertex2sv(v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_2_glVertex2sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2s.xml
+func (gl *GL) Vertex2s(x, y int16) {
+ C.gl1_2_glVertex2s(gl.funcs, C.GLshort(x), C.GLshort(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2iv.xml
+func (gl *GL) Vertex2iv(v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_2_glVertex2iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2i.xml
+func (gl *GL) Vertex2i(x, y int) {
+ C.gl1_2_glVertex2i(gl.funcs, C.GLint(x), C.GLint(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2fv.xml
+func (gl *GL) Vertex2fv(v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_2_glVertex2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2f.xml
+func (gl *GL) Vertex2f(x, y float32) {
+ C.gl1_2_glVertex2f(gl.funcs, C.GLfloat(x), C.GLfloat(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2dv.xml
+func (gl *GL) Vertex2dv(v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_2_glVertex2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2d.xml
+func (gl *GL) Vertex2d(x, y float64) {
+ C.gl1_2_glVertex2d(gl.funcs, C.GLdouble(x), C.GLdouble(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4sv.xml
+func (gl *GL) TexCoord4sv(v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_2_glTexCoord4sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4s.xml
+func (gl *GL) TexCoord4s(s, t, r, q int16) {
+ C.gl1_2_glTexCoord4s(gl.funcs, C.GLshort(s), C.GLshort(t), C.GLshort(r), C.GLshort(q))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4iv.xml
+func (gl *GL) TexCoord4iv(v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_2_glTexCoord4iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4i.xml
+func (gl *GL) TexCoord4i(s, t, r, q int32) {
+ C.gl1_2_glTexCoord4i(gl.funcs, C.GLint(s), C.GLint(t), C.GLint(r), C.GLint(q))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4fv.xml
+func (gl *GL) TexCoord4fv(v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_2_glTexCoord4fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4f.xml
+func (gl *GL) TexCoord4f(s, t, r, q float32) {
+ C.gl1_2_glTexCoord4f(gl.funcs, C.GLfloat(s), C.GLfloat(t), C.GLfloat(r), C.GLfloat(q))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4dv.xml
+func (gl *GL) TexCoord4dv(v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_2_glTexCoord4dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4d.xml
+func (gl *GL) TexCoord4d(s, t, r, q float64) {
+ C.gl1_2_glTexCoord4d(gl.funcs, C.GLdouble(s), C.GLdouble(t), C.GLdouble(r), C.GLdouble(q))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3sv.xml
+func (gl *GL) TexCoord3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_2_glTexCoord3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3s.xml
+func (gl *GL) TexCoord3s(s, t, r int16) {
+ C.gl1_2_glTexCoord3s(gl.funcs, C.GLshort(s), C.GLshort(t), C.GLshort(r))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3iv.xml
+func (gl *GL) TexCoord3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_2_glTexCoord3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3i.xml
+func (gl *GL) TexCoord3i(s, t, r int32) {
+ C.gl1_2_glTexCoord3i(gl.funcs, C.GLint(s), C.GLint(t), C.GLint(r))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3fv.xml
+func (gl *GL) TexCoord3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_2_glTexCoord3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3f.xml
+func (gl *GL) TexCoord3f(s, t, r float32) {
+ C.gl1_2_glTexCoord3f(gl.funcs, C.GLfloat(s), C.GLfloat(t), C.GLfloat(r))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3dv.xml
+func (gl *GL) TexCoord3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_2_glTexCoord3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3d.xml
+func (gl *GL) TexCoord3d(s, t, r float64) {
+ C.gl1_2_glTexCoord3d(gl.funcs, C.GLdouble(s), C.GLdouble(t), C.GLdouble(r))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2sv.xml
+func (gl *GL) TexCoord2sv(v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_2_glTexCoord2sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2s.xml
+func (gl *GL) TexCoord2s(s, t int16) {
+ C.gl1_2_glTexCoord2s(gl.funcs, C.GLshort(s), C.GLshort(t))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2iv.xml
+func (gl *GL) TexCoord2iv(v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_2_glTexCoord2iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2i.xml
+func (gl *GL) TexCoord2i(s, t int32) {
+ C.gl1_2_glTexCoord2i(gl.funcs, C.GLint(s), C.GLint(t))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2fv.xml
+func (gl *GL) TexCoord2fv(v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_2_glTexCoord2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2f.xml
+func (gl *GL) TexCoord2f(s, t float32) {
+ C.gl1_2_glTexCoord2f(gl.funcs, C.GLfloat(s), C.GLfloat(t))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2dv.xml
+func (gl *GL) TexCoord2dv(v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_2_glTexCoord2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2d.xml
+func (gl *GL) TexCoord2d(s, t float64) {
+ C.gl1_2_glTexCoord2d(gl.funcs, C.GLdouble(s), C.GLdouble(t))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1sv.xml
+func (gl *GL) TexCoord1sv(v []int16) {
+ C.gl1_2_glTexCoord1sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1s.xml
+func (gl *GL) TexCoord1s(s int16) {
+ C.gl1_2_glTexCoord1s(gl.funcs, C.GLshort(s))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1iv.xml
+func (gl *GL) TexCoord1iv(v []int32) {
+ C.gl1_2_glTexCoord1iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1i.xml
+func (gl *GL) TexCoord1i(s int32) {
+ C.gl1_2_glTexCoord1i(gl.funcs, C.GLint(s))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1fv.xml
+func (gl *GL) TexCoord1fv(v []float32) {
+ C.gl1_2_glTexCoord1fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1f.xml
+func (gl *GL) TexCoord1f(s float32) {
+ C.gl1_2_glTexCoord1f(gl.funcs, C.GLfloat(s))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1dv.xml
+func (gl *GL) TexCoord1dv(v []float64) {
+ C.gl1_2_glTexCoord1dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1d.xml
+func (gl *GL) TexCoord1d(s float64) {
+ C.gl1_2_glTexCoord1d(gl.funcs, C.GLdouble(s))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRectsv.xml
+func (gl *GL) Rectsv(v1, v2 []int16) {
+ C.gl1_2_glRectsv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v1[0])), (*C.GLshort)(unsafe.Pointer(&v2[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRects.xml
+func (gl *GL) Rects(x1, y1, x2, y2 int16) {
+ C.gl1_2_glRects(gl.funcs, C.GLshort(x1), C.GLshort(y1), C.GLshort(x2), C.GLshort(y2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRectiv.xml
+func (gl *GL) Rectiv(v1, v2 []int32) {
+ C.gl1_2_glRectiv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v1[0])), (*C.GLint)(unsafe.Pointer(&v2[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRecti.xml
+func (gl *GL) Recti(x1, y1, x2, y2 int32) {
+ C.gl1_2_glRecti(gl.funcs, C.GLint(x1), C.GLint(y1), C.GLint(x2), C.GLint(y2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRectfv.xml
+func (gl *GL) Rectfv(v1, v2 []float32) {
+ C.gl1_2_glRectfv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v1[0])), (*C.GLfloat)(unsafe.Pointer(&v2[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRectf.xml
+func (gl *GL) Rectf(x1, y1, x2, y2 float32) {
+ C.gl1_2_glRectf(gl.funcs, C.GLfloat(x1), C.GLfloat(y1), C.GLfloat(x2), C.GLfloat(y2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRectdv.xml
+func (gl *GL) Rectdv(v1, v2 []float64) {
+ C.gl1_2_glRectdv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v1[0])), (*C.GLdouble)(unsafe.Pointer(&v2[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRectd.xml
+func (gl *GL) Rectd(x1, y1, x2, y2 float64) {
+ C.gl1_2_glRectd(gl.funcs, C.GLdouble(x1), C.GLdouble(y1), C.GLdouble(x2), C.GLdouble(y2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4sv.xml
+func (gl *GL) RasterPos4sv(v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_2_glRasterPos4sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4s.xml
+func (gl *GL) RasterPos4s(x, y, z, w int16) {
+ C.gl1_2_glRasterPos4s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z), C.GLshort(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4iv.xml
+func (gl *GL) RasterPos4iv(v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_2_glRasterPos4iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4i.xml
+func (gl *GL) RasterPos4i(x, y, z, w int) {
+ C.gl1_2_glRasterPos4i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z), C.GLint(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4fv.xml
+func (gl *GL) RasterPos4fv(v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_2_glRasterPos4fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4f.xml
+func (gl *GL) RasterPos4f(x, y, z, w float32) {
+ C.gl1_2_glRasterPos4f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z), C.GLfloat(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4dv.xml
+func (gl *GL) RasterPos4dv(v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_2_glRasterPos4dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4d.xml
+func (gl *GL) RasterPos4d(x, y, z, w float64) {
+ C.gl1_2_glRasterPos4d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z), C.GLdouble(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3sv.xml
+func (gl *GL) RasterPos3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_2_glRasterPos3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3s.xml
+func (gl *GL) RasterPos3s(x, y, z int16) {
+ C.gl1_2_glRasterPos3s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3iv.xml
+func (gl *GL) RasterPos3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_2_glRasterPos3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3i.xml
+func (gl *GL) RasterPos3i(x, y, z int) {
+ C.gl1_2_glRasterPos3i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3fv.xml
+func (gl *GL) RasterPos3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_2_glRasterPos3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3f.xml
+func (gl *GL) RasterPos3f(x, y, z float32) {
+ C.gl1_2_glRasterPos3f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3dv.xml
+func (gl *GL) RasterPos3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_2_glRasterPos3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3d.xml
+func (gl *GL) RasterPos3d(x, y, z float64) {
+ C.gl1_2_glRasterPos3d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2sv.xml
+func (gl *GL) RasterPos2sv(v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_2_glRasterPos2sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2s.xml
+func (gl *GL) RasterPos2s(x, y int16) {
+ C.gl1_2_glRasterPos2s(gl.funcs, C.GLshort(x), C.GLshort(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2iv.xml
+func (gl *GL) RasterPos2iv(v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_2_glRasterPos2iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2i.xml
+func (gl *GL) RasterPos2i(x, y int) {
+ C.gl1_2_glRasterPos2i(gl.funcs, C.GLint(x), C.GLint(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2fv.xml
+func (gl *GL) RasterPos2fv(v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_2_glRasterPos2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2f.xml
+func (gl *GL) RasterPos2f(x, y float32) {
+ C.gl1_2_glRasterPos2f(gl.funcs, C.GLfloat(x), C.GLfloat(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2dv.xml
+func (gl *GL) RasterPos2dv(v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_2_glRasterPos2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2d.xml
+func (gl *GL) RasterPos2d(x, y float64) {
+ C.gl1_2_glRasterPos2d(gl.funcs, C.GLdouble(x), C.GLdouble(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3sv.xml
+func (gl *GL) Normal3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_2_glNormal3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3s.xml
+func (gl *GL) Normal3s(nx, ny, nz int16) {
+ C.gl1_2_glNormal3s(gl.funcs, C.GLshort(nx), C.GLshort(ny), C.GLshort(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3iv.xml
+func (gl *GL) Normal3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_2_glNormal3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3i.xml
+func (gl *GL) Normal3i(nx, ny, nz int32) {
+ C.gl1_2_glNormal3i(gl.funcs, C.GLint(nx), C.GLint(ny), C.GLint(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3fv.xml
+func (gl *GL) Normal3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_2_glNormal3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3f.xml
+func (gl *GL) Normal3f(nx, ny, nz float32) {
+ C.gl1_2_glNormal3f(gl.funcs, C.GLfloat(nx), C.GLfloat(ny), C.GLfloat(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3dv.xml
+func (gl *GL) Normal3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_2_glNormal3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3d.xml
+func (gl *GL) Normal3d(nx, ny, nz float64) {
+ C.gl1_2_glNormal3d(gl.funcs, C.GLdouble(nx), C.GLdouble(ny), C.GLdouble(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3bv.xml
+func (gl *GL) Normal3bv(v []byte) {
+ C.gl1_2_glNormal3bv(gl.funcs, (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3b.xml
+func (gl *GL) Normal3b(nx, ny, nz byte) {
+ C.gl1_2_glNormal3b(gl.funcs, C.GLbyte(nx), C.GLbyte(ny), C.GLbyte(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexsv.xml
+func (gl *GL) Indexsv(c []int16) {
+ C.gl1_2_glIndexsv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexs.xml
+func (gl *GL) Indexs(c int16) {
+ C.gl1_2_glIndexs(gl.funcs, C.GLshort(c))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexiv.xml
+func (gl *GL) Indexiv(c []int32) {
+ C.gl1_2_glIndexiv(gl.funcs, (*C.GLint)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexi.xml
+func (gl *GL) Indexi(c int32) {
+ C.gl1_2_glIndexi(gl.funcs, C.GLint(c))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexfv.xml
+func (gl *GL) Indexfv(c []float32) {
+ C.gl1_2_glIndexfv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexf.xml
+func (gl *GL) Indexf(c float32) {
+ C.gl1_2_glIndexf(gl.funcs, C.GLfloat(c))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexdv.xml
+func (gl *GL) Indexdv(c []float64) {
+ C.gl1_2_glIndexdv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexd.xml
+func (gl *GL) Indexd(c float64) {
+ C.gl1_2_glIndexd(gl.funcs, C.GLdouble(c))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEnd.xml
+func (gl *GL) End() {
+ C.gl1_2_glEnd(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEdgeFlagv.xml
+func (gl *GL) EdgeFlagv(flag []bool) {
+ C.gl1_2_glEdgeFlagv(gl.funcs, (*C.GLboolean)(unsafe.Pointer(&flag[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEdgeFlag.xml
+func (gl *GL) EdgeFlag(flag bool) {
+ C.gl1_2_glEdgeFlag(gl.funcs, *(*C.GLboolean)(unsafe.Pointer(&flag)))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4usv.xml
+func (gl *GL) Color4usv(v []uint16) {
+ C.gl1_2_glColor4usv(gl.funcs, (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4us.xml
+func (gl *GL) Color4us(red, green, blue, alpha uint16) {
+ C.gl1_2_glColor4us(gl.funcs, C.GLushort(red), C.GLushort(green), C.GLushort(blue), C.GLushort(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4uiv.xml
+func (gl *GL) Color4uiv(v []uint32) {
+ C.gl1_2_glColor4uiv(gl.funcs, (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4ui.xml
+func (gl *GL) Color4ui(red, green, blue, alpha uint32) {
+ C.gl1_2_glColor4ui(gl.funcs, C.GLuint(red), C.GLuint(green), C.GLuint(blue), C.GLuint(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4ubv.xml
+func (gl *GL) Color4ubv(v []uint8) {
+ C.gl1_2_glColor4ubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4ub.xml
+func (gl *GL) Color4ub(red, green, blue, alpha uint8) {
+ C.gl1_2_glColor4ub(gl.funcs, C.GLubyte(red), C.GLubyte(green), C.GLubyte(blue), C.GLubyte(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4sv.xml
+func (gl *GL) Color4sv(v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_2_glColor4sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4s.xml
+func (gl *GL) Color4s(red, green, blue, alpha int16) {
+ C.gl1_2_glColor4s(gl.funcs, C.GLshort(red), C.GLshort(green), C.GLshort(blue), C.GLshort(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4iv.xml
+func (gl *GL) Color4iv(v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_2_glColor4iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4i.xml
+func (gl *GL) Color4i(red, green, blue, alpha int32) {
+ C.gl1_2_glColor4i(gl.funcs, C.GLint(red), C.GLint(green), C.GLint(blue), C.GLint(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4fv.xml
+func (gl *GL) Color4fv(v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_2_glColor4fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4f.xml
+func (gl *GL) Color4f(red, green, blue, alpha float32) {
+ C.gl1_2_glColor4f(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4dv.xml
+func (gl *GL) Color4dv(v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_2_glColor4dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4d.xml
+func (gl *GL) Color4d(red, green, blue, alpha float64) {
+ C.gl1_2_glColor4d(gl.funcs, C.GLdouble(red), C.GLdouble(green), C.GLdouble(blue), C.GLdouble(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4bv.xml
+func (gl *GL) Color4bv(v []byte) {
+ C.gl1_2_glColor4bv(gl.funcs, (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4b.xml
+func (gl *GL) Color4b(red, green, blue, alpha byte) {
+ C.gl1_2_glColor4b(gl.funcs, C.GLbyte(red), C.GLbyte(green), C.GLbyte(blue), C.GLbyte(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3usv.xml
+func (gl *GL) Color3usv(v []uint16) {
+ C.gl1_2_glColor3usv(gl.funcs, (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3us.xml
+func (gl *GL) Color3us(red, green, blue uint16) {
+ C.gl1_2_glColor3us(gl.funcs, C.GLushort(red), C.GLushort(green), C.GLushort(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3uiv.xml
+func (gl *GL) Color3uiv(v []uint32) {
+ C.gl1_2_glColor3uiv(gl.funcs, (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3ui.xml
+func (gl *GL) Color3ui(red, green, blue uint32) {
+ C.gl1_2_glColor3ui(gl.funcs, C.GLuint(red), C.GLuint(green), C.GLuint(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3ubv.xml
+func (gl *GL) Color3ubv(v []uint8) {
+ C.gl1_2_glColor3ubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3ub.xml
+func (gl *GL) Color3ub(red, green, blue uint8) {
+ C.gl1_2_glColor3ub(gl.funcs, C.GLubyte(red), C.GLubyte(green), C.GLubyte(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3sv.xml
+func (gl *GL) Color3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_2_glColor3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3s.xml
+func (gl *GL) Color3s(red, green, blue int16) {
+ C.gl1_2_glColor3s(gl.funcs, C.GLshort(red), C.GLshort(green), C.GLshort(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3iv.xml
+func (gl *GL) Color3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_2_glColor3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3i.xml
+func (gl *GL) Color3i(red, green, blue int32) {
+ C.gl1_2_glColor3i(gl.funcs, C.GLint(red), C.GLint(green), C.GLint(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3fv.xml
+func (gl *GL) Color3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_2_glColor3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3f.xml
+func (gl *GL) Color3f(red, green, blue float32) {
+ C.gl1_2_glColor3f(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3dv.xml
+func (gl *GL) Color3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_2_glColor3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3d.xml
+func (gl *GL) Color3d(red, green, blue float64) {
+ C.gl1_2_glColor3d(gl.funcs, C.GLdouble(red), C.GLdouble(green), C.GLdouble(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3bv.xml
+func (gl *GL) Color3bv(v []byte) {
+ C.gl1_2_glColor3bv(gl.funcs, (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3b.xml
+func (gl *GL) Color3b(red, green, blue byte) {
+ C.gl1_2_glColor3b(gl.funcs, C.GLbyte(red), C.GLbyte(green), C.GLbyte(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBitmap.xml
+func (gl *GL) Bitmap(width, height int, xorig, yorig, xmove, ymove float32, bitmap []uint8) {
+ C.gl1_2_glBitmap(gl.funcs, C.GLsizei(width), C.GLsizei(height), C.GLfloat(xorig), C.GLfloat(yorig), C.GLfloat(xmove), C.GLfloat(ymove), (*C.GLubyte)(unsafe.Pointer(&bitmap[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBegin.xml
+func (gl *GL) Begin(mode glbase.Enum) {
+ C.gl1_2_glBegin(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glListBase.xml
+func (gl *GL) ListBase(base uint32) {
+ C.gl1_2_glListBase(gl.funcs, C.GLuint(base))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGenLists.xml
+func (gl *GL) GenLists(range_ int32) uint32 {
+ glresult := C.gl1_2_glGenLists(gl.funcs, C.GLsizei(range_))
+ return uint32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDeleteLists.xml
+func (gl *GL) DeleteLists(list uint32, range_ int32) {
+ C.gl1_2_glDeleteLists(gl.funcs, C.GLuint(list), C.GLsizei(range_))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCallLists.xml
+func (gl *GL) CallLists(n int, gltype glbase.Enum, lists interface{}) {
+ var lists_ptr unsafe.Pointer
+ var lists_v = reflect.ValueOf(lists)
+ if lists != nil && lists_v.Kind() != reflect.Slice {
+ panic("parameter lists must be a slice")
+ }
+ if lists != nil {
+ lists_ptr = unsafe.Pointer(lists_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_2_glCallLists(gl.funcs, C.GLsizei(n), C.GLenum(gltype), lists_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCallList.xml
+func (gl *GL) CallList(list uint32) {
+ C.gl1_2_glCallList(gl.funcs, C.GLuint(list))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEndList.xml
+func (gl *GL) EndList() {
+ C.gl1_2_glEndList(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNewList.xml
+func (gl *GL) NewList(list uint32, mode glbase.Enum) {
+ C.gl1_2_glNewList(gl.funcs, C.GLuint(list), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPushClientAttrib.xml
+func (gl *GL) PushClientAttrib(mask glbase.Bitfield) {
+ C.gl1_2_glPushClientAttrib(gl.funcs, C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPopClientAttrib.xml
+func (gl *GL) PopClientAttrib() {
+ C.gl1_2_glPopClientAttrib(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPrioritizeTextures.xml
+func (gl *GL) PrioritizeTextures(n int, textures []glbase.Texture, priorities []float32) {
+ C.gl1_2_glPrioritizeTextures(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])), (*C.GLfloat)(unsafe.Pointer(&priorities[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glAreTexturesResident.xml
+func (gl *GL) AreTexturesResident(n int, textures []glbase.Texture, residences []bool) bool {
+ glresult := C.gl1_2_glAreTexturesResident(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])), (*C.GLboolean)(unsafe.Pointer(&residences[0])))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexPointer.xml
+func (gl *GL) VertexPointer(size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_2_glVertexPointer(gl.funcs, C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoordPointer.xml
+func (gl *GL) TexCoordPointer(size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_2_glTexCoordPointer(gl.funcs, C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormalPointer.xml
+func (gl *GL) NormalPointer(gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_2_glNormalPointer(gl.funcs, C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glInterleavedArrays.xml
+func (gl *GL) InterleavedArrays(format glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_2_glInterleavedArrays(gl.funcs, C.GLenum(format), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexPointer.xml
+func (gl *GL) IndexPointer(gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_2_glIndexPointer(gl.funcs, C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEnableClientState.xml
+func (gl *GL) EnableClientState(array glbase.Enum) {
+ C.gl1_2_glEnableClientState(gl.funcs, C.GLenum(array))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEdgeFlagPointer.xml
+func (gl *GL) EdgeFlagPointer(stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_2_glEdgeFlagPointer(gl.funcs, C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDisableClientState.xml
+func (gl *GL) DisableClientState(array glbase.Enum) {
+ C.gl1_2_glDisableClientState(gl.funcs, C.GLenum(array))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColorPointer.xml
+func (gl *GL) ColorPointer(size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_2_glColorPointer(gl.funcs, C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glArrayElement.xml
+func (gl *GL) ArrayElement(i int32) {
+ C.gl1_2_glArrayElement(gl.funcs, C.GLint(i))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glResetMinmax.xml
+func (gl *GL) ResetMinmax(target glbase.Enum) {
+ C.gl1_2_glResetMinmax(gl.funcs, C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glResetHistogram.xml
+func (gl *GL) ResetHistogram(target glbase.Enum) {
+ C.gl1_2_glResetHistogram(gl.funcs, C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMinmax.xml
+func (gl *GL) Minmax(target, internalFormat glbase.Enum, sink bool) {
+ C.gl1_2_glMinmax(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), *(*C.GLboolean)(unsafe.Pointer(&sink)))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glHistogram.xml
+func (gl *GL) Histogram(target glbase.Enum, width int, internalFormat glbase.Enum, sink bool) {
+ C.gl1_2_glHistogram(gl.funcs, C.GLenum(target), C.GLsizei(width), C.GLenum(internalFormat), *(*C.GLboolean)(unsafe.Pointer(&sink)))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetMinmaxParameteriv.xml
+func (gl *GL) GetMinmaxParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl1_2_glGetMinmaxParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetMinmaxParameterfv.xml
+func (gl *GL) GetMinmaxParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl1_2_glGetMinmaxParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetMinmax.xml
+func (gl *GL) GetMinmax(target glbase.Enum, reset bool, format, gltype glbase.Enum, values interface{}) {
+ var values_ptr unsafe.Pointer
+ var values_v = reflect.ValueOf(values)
+ if values != nil && values_v.Kind() != reflect.Slice {
+ panic("parameter values must be a slice")
+ }
+ if values != nil {
+ values_ptr = unsafe.Pointer(values_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_2_glGetMinmax(gl.funcs, C.GLenum(target), *(*C.GLboolean)(unsafe.Pointer(&reset)), C.GLenum(format), C.GLenum(gltype), values_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetHistogramParameteriv.xml
+func (gl *GL) GetHistogramParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl1_2_glGetHistogramParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetHistogramParameterfv.xml
+func (gl *GL) GetHistogramParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl1_2_glGetHistogramParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetHistogram.xml
+func (gl *GL) GetHistogram(target glbase.Enum, reset bool, format, gltype glbase.Enum, values interface{}) {
+ var values_ptr unsafe.Pointer
+ var values_v = reflect.ValueOf(values)
+ if values != nil && values_v.Kind() != reflect.Slice {
+ panic("parameter values must be a slice")
+ }
+ if values != nil {
+ values_ptr = unsafe.Pointer(values_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_2_glGetHistogram(gl.funcs, C.GLenum(target), *(*C.GLboolean)(unsafe.Pointer(&reset)), C.GLenum(format), C.GLenum(gltype), values_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSeparableFilter2D.xml
+func (gl *GL) SeparableFilter2D(target, internalFormat glbase.Enum, width, height int, format, gltype glbase.Enum, row, column interface{}) {
+ var row_ptr unsafe.Pointer
+ var row_v = reflect.ValueOf(row)
+ if row != nil && row_v.Kind() != reflect.Slice {
+ panic("parameter row must be a slice")
+ }
+ if row != nil {
+ row_ptr = unsafe.Pointer(row_v.Index(0).Addr().Pointer())
+ }
+ var column_ptr unsafe.Pointer
+ var column_v = reflect.ValueOf(column)
+ if column != nil && column_v.Kind() != reflect.Slice {
+ panic("parameter column must be a slice")
+ }
+ if column != nil {
+ column_ptr = unsafe.Pointer(column_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_2_glSeparableFilter2D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), row_ptr, column_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetSeparableFilter.xml
+func (gl *GL) GetSeparableFilter(target, format, gltype glbase.Enum, row, column, span interface{}) {
+ var row_ptr unsafe.Pointer
+ var row_v = reflect.ValueOf(row)
+ if row != nil && row_v.Kind() != reflect.Slice {
+ panic("parameter row must be a slice")
+ }
+ if row != nil {
+ row_ptr = unsafe.Pointer(row_v.Index(0).Addr().Pointer())
+ }
+ var column_ptr unsafe.Pointer
+ var column_v = reflect.ValueOf(column)
+ if column != nil && column_v.Kind() != reflect.Slice {
+ panic("parameter column must be a slice")
+ }
+ if column != nil {
+ column_ptr = unsafe.Pointer(column_v.Index(0).Addr().Pointer())
+ }
+ var span_ptr unsafe.Pointer
+ var span_v = reflect.ValueOf(span)
+ if span != nil && span_v.Kind() != reflect.Slice {
+ panic("parameter span must be a slice")
+ }
+ if span != nil {
+ span_ptr = unsafe.Pointer(span_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_2_glGetSeparableFilter(gl.funcs, C.GLenum(target), C.GLenum(format), C.GLenum(gltype), row_ptr, column_ptr, span_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetConvolutionParameteriv.xml
+func (gl *GL) GetConvolutionParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl1_2_glGetConvolutionParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetConvolutionParameterfv.xml
+func (gl *GL) GetConvolutionParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl1_2_glGetConvolutionParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetConvolutionFilter.xml
+func (gl *GL) GetConvolutionFilter(target, format, gltype glbase.Enum, image interface{}) {
+ var image_ptr unsafe.Pointer
+ var image_v = reflect.ValueOf(image)
+ if image != nil && image_v.Kind() != reflect.Slice {
+ panic("parameter image must be a slice")
+ }
+ if image != nil {
+ image_ptr = unsafe.Pointer(image_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_2_glGetConvolutionFilter(gl.funcs, C.GLenum(target), C.GLenum(format), C.GLenum(gltype), image_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyConvolutionFilter2D.xml
+func (gl *GL) CopyConvolutionFilter2D(target, internalFormat glbase.Enum, x, y, width, height int) {
+ C.gl1_2_glCopyConvolutionFilter2D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyConvolutionFilter1D.xml
+func (gl *GL) CopyConvolutionFilter1D(target, internalFormat glbase.Enum, x, y, width int) {
+ C.gl1_2_glCopyConvolutionFilter1D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glConvolutionParameteriv.xml
+func (gl *GL) ConvolutionParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl1_2_glConvolutionParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glConvolutionParameteri.xml
+func (gl *GL) ConvolutionParameteri(target, pname glbase.Enum, params int32) {
+ C.gl1_2_glConvolutionParameteri(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLint(params))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glConvolutionParameterfv.xml
+func (gl *GL) ConvolutionParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl1_2_glConvolutionParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glConvolutionParameterf.xml
+func (gl *GL) ConvolutionParameterf(target, pname glbase.Enum, params float32) {
+ C.gl1_2_glConvolutionParameterf(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLfloat(params))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glConvolutionFilter2D.xml
+func (gl *GL) ConvolutionFilter2D(target, internalFormat glbase.Enum, width, height int, format, gltype glbase.Enum, image interface{}) {
+ var image_ptr unsafe.Pointer
+ var image_v = reflect.ValueOf(image)
+ if image != nil && image_v.Kind() != reflect.Slice {
+ panic("parameter image must be a slice")
+ }
+ if image != nil {
+ image_ptr = unsafe.Pointer(image_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_2_glConvolutionFilter2D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), image_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glConvolutionFilter1D.xml
+func (gl *GL) ConvolutionFilter1D(target, internalFormat glbase.Enum, width int, format, gltype glbase.Enum, image interface{}) {
+ var image_ptr unsafe.Pointer
+ var image_v = reflect.ValueOf(image)
+ if image != nil && image_v.Kind() != reflect.Slice {
+ panic("parameter image must be a slice")
+ }
+ if image != nil {
+ image_ptr = unsafe.Pointer(image_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_2_glConvolutionFilter1D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLenum(format), C.GLenum(gltype), image_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyColorSubTable.xml
+func (gl *GL) CopyColorSubTable(target glbase.Enum, start int32, x, y, width int) {
+ C.gl1_2_glCopyColorSubTable(gl.funcs, C.GLenum(target), C.GLsizei(start), C.GLint(x), C.GLint(y), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColorSubTable.xml
+func (gl *GL) ColorSubTable(target glbase.Enum, start int32, count int, format, gltype glbase.Enum, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_2_glColorSubTable(gl.funcs, C.GLenum(target), C.GLsizei(start), C.GLsizei(count), C.GLenum(format), C.GLenum(gltype), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetColorTableParameteriv.xml
+func (gl *GL) GetColorTableParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl1_2_glGetColorTableParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetColorTableParameterfv.xml
+func (gl *GL) GetColorTableParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl1_2_glGetColorTableParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetColorTable.xml
+func (gl *GL) GetColorTable(target, format, gltype glbase.Enum, table interface{}) {
+ var table_ptr unsafe.Pointer
+ var table_v = reflect.ValueOf(table)
+ if table != nil && table_v.Kind() != reflect.Slice {
+ panic("parameter table must be a slice")
+ }
+ if table != nil {
+ table_ptr = unsafe.Pointer(table_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_2_glGetColorTable(gl.funcs, C.GLenum(target), C.GLenum(format), C.GLenum(gltype), table_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyColorTable.xml
+func (gl *GL) CopyColorTable(target, internalFormat glbase.Enum, x, y, width int) {
+ C.gl1_2_glCopyColorTable(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColorTableParameteriv.xml
+func (gl *GL) ColorTableParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl1_2_glColorTableParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColorTableParameterfv.xml
+func (gl *GL) ColorTableParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl1_2_glColorTableParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColorTable.xml
+func (gl *GL) ColorTable(target, internalFormat glbase.Enum, width int, format, gltype glbase.Enum, table interface{}) {
+ var table_ptr unsafe.Pointer
+ var table_v = reflect.ValueOf(table)
+ if table != nil && table_v.Kind() != reflect.Slice {
+ panic("parameter table must be a slice")
+ }
+ if table != nil {
+ table_ptr = unsafe.Pointer(table_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_2_glColorTable(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLenum(format), C.GLenum(gltype), table_ptr)
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/1.3/funcs.cpp b/Godeps/_workspace/src/github.com/obscuren/qml/gl/1.3/funcs.cpp
new file mode 100644
index 000000000..582d20907
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/1.3/funcs.cpp
@@ -0,0 +1,2526 @@
+
+// ** file automatically generated by glgen -- do not edit manually **
+
+#include <QOpenGLContext>
+#include <QtGui/qopenglfunctions_1_3.h>
+
+#include "funcs.h"
+
+void *gl1_3_funcs() {
+ QOpenGLFunctions_1_3* funcs = QOpenGLContext::currentContext()->versionFunctions<QOpenGLFunctions_1_3>();
+ if (!funcs) {
+ return 0;
+ }
+ funcs->initializeOpenGLFunctions();
+ return funcs;
+}
+
+
+void gl1_3_glViewport(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glViewport(x, y, width, height);
+}
+
+void gl1_3_glDepthRange(void *_glfuncs, GLdouble nearVal, GLdouble farVal)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glDepthRange(nearVal, farVal);
+}
+
+GLboolean gl1_3_glIsEnabled(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ return _qglfuncs->glIsEnabled(cap);
+}
+
+void gl1_3_glGetTexLevelParameteriv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glGetTexLevelParameteriv(target, level, pname, params);
+}
+
+void gl1_3_glGetTexLevelParameterfv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glGetTexLevelParameterfv(target, level, pname, params);
+}
+
+void gl1_3_glGetTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glGetTexParameteriv(target, pname, params);
+}
+
+void gl1_3_glGetTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glGetTexParameterfv(target, pname, params);
+}
+
+void gl1_3_glGetTexImage(void *_glfuncs, GLenum target, GLint level, GLenum format, GLenum gltype, GLvoid* pixels)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glGetTexImage(target, level, format, gltype, pixels);
+}
+
+void gl1_3_glGetIntegerv(void *_glfuncs, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glGetIntegerv(pname, params);
+}
+
+void gl1_3_glGetFloatv(void *_glfuncs, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glGetFloatv(pname, params);
+}
+
+GLenum gl1_3_glGetError(void *_glfuncs)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ return _qglfuncs->glGetError();
+}
+
+void gl1_3_glGetDoublev(void *_glfuncs, GLenum pname, GLdouble* params)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glGetDoublev(pname, params);
+}
+
+void gl1_3_glGetBooleanv(void *_glfuncs, GLenum pname, GLboolean* params)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glGetBooleanv(pname, params);
+}
+
+void gl1_3_glReadPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum gltype, GLvoid* pixels)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glReadPixels(x, y, width, height, format, gltype, pixels);
+}
+
+void gl1_3_glReadBuffer(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glReadBuffer(mode);
+}
+
+void gl1_3_glPixelStorei(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glPixelStorei(pname, param);
+}
+
+void gl1_3_glPixelStoref(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glPixelStoref(pname, param);
+}
+
+void gl1_3_glDepthFunc(void *_glfuncs, GLenum glfunc)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glDepthFunc(glfunc);
+}
+
+void gl1_3_glStencilOp(void *_glfuncs, GLenum fail, GLenum zfail, GLenum zpass)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glStencilOp(fail, zfail, zpass);
+}
+
+void gl1_3_glStencilFunc(void *_glfuncs, GLenum glfunc, GLint ref, GLuint mask)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glStencilFunc(glfunc, ref, mask);
+}
+
+void gl1_3_glLogicOp(void *_glfuncs, GLenum opcode)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glLogicOp(opcode);
+}
+
+void gl1_3_glBlendFunc(void *_glfuncs, GLenum sfactor, GLenum dfactor)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glBlendFunc(sfactor, dfactor);
+}
+
+void gl1_3_glFlush(void *_glfuncs)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glFlush();
+}
+
+void gl1_3_glFinish(void *_glfuncs)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glFinish();
+}
+
+void gl1_3_glEnable(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glEnable(cap);
+}
+
+void gl1_3_glDisable(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glDisable(cap);
+}
+
+void gl1_3_glDepthMask(void *_glfuncs, GLboolean flag)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glDepthMask(flag);
+}
+
+void gl1_3_glColorMask(void *_glfuncs, GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glColorMask(red, green, blue, alpha);
+}
+
+void gl1_3_glStencilMask(void *_glfuncs, GLuint mask)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glStencilMask(mask);
+}
+
+void gl1_3_glClearDepth(void *_glfuncs, GLdouble depth)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glClearDepth(depth);
+}
+
+void gl1_3_glClearStencil(void *_glfuncs, GLint s)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glClearStencil(s);
+}
+
+void gl1_3_glClearColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glClearColor(red, green, blue, alpha);
+}
+
+void gl1_3_glClear(void *_glfuncs, GLbitfield mask)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glClear(mask);
+}
+
+void gl1_3_glDrawBuffer(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glDrawBuffer(mode);
+}
+
+void gl1_3_glTexImage2D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glTexImage2D(target, level, internalFormat, width, height, border, format, gltype, pixels);
+}
+
+void gl1_3_glTexImage1D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glTexImage1D(target, level, internalFormat, width, border, format, gltype, pixels);
+}
+
+void gl1_3_glTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glTexParameteriv(target, pname, params);
+}
+
+void gl1_3_glTexParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glTexParameteri(target, pname, param);
+}
+
+void gl1_3_glTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glTexParameterfv(target, pname, params);
+}
+
+void gl1_3_glTexParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glTexParameterf(target, pname, param);
+}
+
+void gl1_3_glScissor(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glScissor(x, y, width, height);
+}
+
+void gl1_3_glPolygonMode(void *_glfuncs, GLenum face, GLenum mode)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glPolygonMode(face, mode);
+}
+
+void gl1_3_glPointSize(void *_glfuncs, GLfloat size)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glPointSize(size);
+}
+
+void gl1_3_glLineWidth(void *_glfuncs, GLfloat width)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glLineWidth(width);
+}
+
+void gl1_3_glHint(void *_glfuncs, GLenum target, GLenum mode)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glHint(target, mode);
+}
+
+void gl1_3_glFrontFace(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glFrontFace(mode);
+}
+
+void gl1_3_glCullFace(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glCullFace(mode);
+}
+
+void gl1_3_glIndexubv(void *_glfuncs, const GLubyte* c)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glIndexubv(c);
+}
+
+void gl1_3_glIndexub(void *_glfuncs, GLubyte c)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glIndexub(c);
+}
+
+GLboolean gl1_3_glIsTexture(void *_glfuncs, GLuint texture)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ return _qglfuncs->glIsTexture(texture);
+}
+
+void gl1_3_glGenTextures(void *_glfuncs, GLsizei n, GLuint* textures)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glGenTextures(n, textures);
+}
+
+void gl1_3_glDeleteTextures(void *_glfuncs, GLsizei n, const GLuint* textures)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glDeleteTextures(n, textures);
+}
+
+void gl1_3_glBindTexture(void *_glfuncs, GLenum target, GLuint texture)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glBindTexture(target, texture);
+}
+
+void gl1_3_glTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glTexSubImage2D(target, level, xoffset, yoffset, width, height, format, gltype, pixels);
+}
+
+void gl1_3_glTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glTexSubImage1D(target, level, xoffset, width, format, gltype, pixels);
+}
+
+void gl1_3_glCopyTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage2D(target, level, xoffset, yoffset, x, y, width, height);
+}
+
+void gl1_3_glCopyTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage1D(target, level, xoffset, x, y, width);
+}
+
+void gl1_3_glCopyTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glCopyTexImage2D(target, level, internalFormat, x, y, width, height, border);
+}
+
+void gl1_3_glCopyTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLint border)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glCopyTexImage1D(target, level, internalFormat, x, y, width, border);
+}
+
+void gl1_3_glPolygonOffset(void *_glfuncs, GLfloat factor, GLfloat units)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glPolygonOffset(factor, units);
+}
+
+void gl1_3_glDrawElements(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glDrawElements(mode, count, gltype, indices);
+}
+
+void gl1_3_glDrawArrays(void *_glfuncs, GLenum mode, GLint first, GLsizei count)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glDrawArrays(mode, first, count);
+}
+
+void gl1_3_glCopyTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage3D(target, level, xoffset, yoffset, zoffset, x, y, width, height);
+}
+
+void gl1_3_glTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glTexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, gltype, pixels);
+}
+
+void gl1_3_glTexImage3D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glTexImage3D(target, level, internalFormat, width, height, depth, border, format, gltype, pixels);
+}
+
+void gl1_3_glDrawRangeElements(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glDrawRangeElements(mode, start, end, count, gltype, indices);
+}
+
+void gl1_3_glBlendEquation(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glBlendEquation(mode);
+}
+
+void gl1_3_glBlendColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glBlendColor(red, green, blue, alpha);
+}
+
+void gl1_3_glGetCompressedTexImage(void *_glfuncs, GLenum target, GLint level, GLvoid* img)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glGetCompressedTexImage(target, level, img);
+}
+
+void gl1_3_glCompressedTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glCompressedTexSubImage1D(target, level, xoffset, width, format, imageSize, data);
+}
+
+void gl1_3_glCompressedTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glCompressedTexSubImage2D(target, level, xoffset, yoffset, width, height, format, imageSize, data);
+}
+
+void gl1_3_glCompressedTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glCompressedTexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, imageSize, data);
+}
+
+void gl1_3_glCompressedTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glCompressedTexImage1D(target, level, internalFormat, width, border, imageSize, data);
+}
+
+void gl1_3_glCompressedTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glCompressedTexImage2D(target, level, internalFormat, width, height, border, imageSize, data);
+}
+
+void gl1_3_glCompressedTexImage3D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glCompressedTexImage3D(target, level, internalFormat, width, height, depth, border, imageSize, data);
+}
+
+void gl1_3_glSampleCoverage(void *_glfuncs, GLfloat value, GLboolean invert)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glSampleCoverage(value, invert);
+}
+
+void gl1_3_glActiveTexture(void *_glfuncs, GLenum texture)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glActiveTexture(texture);
+}
+
+void gl1_3_glTranslatef(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glTranslatef(x, y, z);
+}
+
+void gl1_3_glTranslated(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glTranslated(x, y, z);
+}
+
+void gl1_3_glScalef(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glScalef(x, y, z);
+}
+
+void gl1_3_glScaled(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glScaled(x, y, z);
+}
+
+void gl1_3_glRotatef(void *_glfuncs, GLfloat angle, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glRotatef(angle, x, y, z);
+}
+
+void gl1_3_glRotated(void *_glfuncs, GLdouble angle, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glRotated(angle, x, y, z);
+}
+
+void gl1_3_glPushMatrix(void *_glfuncs)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glPushMatrix();
+}
+
+void gl1_3_glPopMatrix(void *_glfuncs)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glPopMatrix();
+}
+
+void gl1_3_glOrtho(void *_glfuncs, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glOrtho(left, right, bottom, top, zNear, zFar);
+}
+
+void gl1_3_glMultMatrixd(void *_glfuncs, const GLdouble* m)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glMultMatrixd(m);
+}
+
+void gl1_3_glMultMatrixf(void *_glfuncs, const GLfloat* m)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glMultMatrixf(m);
+}
+
+void gl1_3_glMatrixMode(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glMatrixMode(mode);
+}
+
+void gl1_3_glLoadMatrixd(void *_glfuncs, const GLdouble* m)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glLoadMatrixd(m);
+}
+
+void gl1_3_glLoadMatrixf(void *_glfuncs, const GLfloat* m)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glLoadMatrixf(m);
+}
+
+void gl1_3_glLoadIdentity(void *_glfuncs)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glLoadIdentity();
+}
+
+void gl1_3_glFrustum(void *_glfuncs, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glFrustum(left, right, bottom, top, zNear, zFar);
+}
+
+GLboolean gl1_3_glIsList(void *_glfuncs, GLuint list)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ return _qglfuncs->glIsList(list);
+}
+
+void gl1_3_glGetTexGeniv(void *_glfuncs, GLenum coord, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glGetTexGeniv(coord, pname, params);
+}
+
+void gl1_3_glGetTexGenfv(void *_glfuncs, GLenum coord, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glGetTexGenfv(coord, pname, params);
+}
+
+void gl1_3_glGetTexGendv(void *_glfuncs, GLenum coord, GLenum pname, GLdouble* params)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glGetTexGendv(coord, pname, params);
+}
+
+void gl1_3_glGetTexEnviv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glGetTexEnviv(target, pname, params);
+}
+
+void gl1_3_glGetTexEnvfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glGetTexEnvfv(target, pname, params);
+}
+
+void gl1_3_glGetPolygonStipple(void *_glfuncs, GLubyte* mask)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glGetPolygonStipple(mask);
+}
+
+void gl1_3_glGetPixelMapusv(void *_glfuncs, GLenum glmap, GLushort* values)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glGetPixelMapusv(glmap, values);
+}
+
+void gl1_3_glGetPixelMapuiv(void *_glfuncs, GLenum glmap, GLuint* values)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glGetPixelMapuiv(glmap, values);
+}
+
+void gl1_3_glGetPixelMapfv(void *_glfuncs, GLenum glmap, GLfloat* values)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glGetPixelMapfv(glmap, values);
+}
+
+void gl1_3_glGetMaterialiv(void *_glfuncs, GLenum face, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glGetMaterialiv(face, pname, params);
+}
+
+void gl1_3_glGetMaterialfv(void *_glfuncs, GLenum face, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glGetMaterialfv(face, pname, params);
+}
+
+void gl1_3_glGetMapiv(void *_glfuncs, GLenum target, GLenum query, GLint* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glGetMapiv(target, query, v);
+}
+
+void gl1_3_glGetMapfv(void *_glfuncs, GLenum target, GLenum query, GLfloat* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glGetMapfv(target, query, v);
+}
+
+void gl1_3_glGetMapdv(void *_glfuncs, GLenum target, GLenum query, GLdouble* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glGetMapdv(target, query, v);
+}
+
+void gl1_3_glGetLightiv(void *_glfuncs, GLenum light, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glGetLightiv(light, pname, params);
+}
+
+void gl1_3_glGetLightfv(void *_glfuncs, GLenum light, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glGetLightfv(light, pname, params);
+}
+
+void gl1_3_glGetClipPlane(void *_glfuncs, GLenum plane, GLdouble* equation)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glGetClipPlane(plane, equation);
+}
+
+void gl1_3_glDrawPixels(void *_glfuncs, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glDrawPixels(width, height, format, gltype, pixels);
+}
+
+void gl1_3_glCopyPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum gltype)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glCopyPixels(x, y, width, height, gltype);
+}
+
+void gl1_3_glPixelMapusv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLushort* values)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glPixelMapusv(glmap, mapsize, values);
+}
+
+void gl1_3_glPixelMapuiv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLuint* values)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glPixelMapuiv(glmap, mapsize, values);
+}
+
+void gl1_3_glPixelMapfv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLfloat* values)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glPixelMapfv(glmap, mapsize, values);
+}
+
+void gl1_3_glPixelTransferi(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glPixelTransferi(pname, param);
+}
+
+void gl1_3_glPixelTransferf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glPixelTransferf(pname, param);
+}
+
+void gl1_3_glPixelZoom(void *_glfuncs, GLfloat xfactor, GLfloat yfactor)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glPixelZoom(xfactor, yfactor);
+}
+
+void gl1_3_glAlphaFunc(void *_glfuncs, GLenum glfunc, GLfloat ref)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glAlphaFunc(glfunc, ref);
+}
+
+void gl1_3_glEvalPoint2(void *_glfuncs, GLint i, GLint j)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glEvalPoint2(i, j);
+}
+
+void gl1_3_glEvalMesh2(void *_glfuncs, GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glEvalMesh2(mode, i1, i2, j1, j2);
+}
+
+void gl1_3_glEvalPoint1(void *_glfuncs, GLint i)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glEvalPoint1(i);
+}
+
+void gl1_3_glEvalMesh1(void *_glfuncs, GLenum mode, GLint i1, GLint i2)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glEvalMesh1(mode, i1, i2);
+}
+
+void gl1_3_glEvalCoord2fv(void *_glfuncs, const GLfloat* u)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glEvalCoord2fv(u);
+}
+
+void gl1_3_glEvalCoord2f(void *_glfuncs, GLfloat u, GLfloat v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glEvalCoord2f(u, v);
+}
+
+void gl1_3_glEvalCoord2dv(void *_glfuncs, const GLdouble* u)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glEvalCoord2dv(u);
+}
+
+void gl1_3_glEvalCoord2d(void *_glfuncs, GLdouble u, GLdouble v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glEvalCoord2d(u, v);
+}
+
+void gl1_3_glEvalCoord1fv(void *_glfuncs, const GLfloat* u)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glEvalCoord1fv(u);
+}
+
+void gl1_3_glEvalCoord1f(void *_glfuncs, GLfloat u)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glEvalCoord1f(u);
+}
+
+void gl1_3_glEvalCoord1dv(void *_glfuncs, const GLdouble* u)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glEvalCoord1dv(u);
+}
+
+void gl1_3_glEvalCoord1d(void *_glfuncs, GLdouble u)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glEvalCoord1d(u);
+}
+
+void gl1_3_glMapGrid2f(void *_glfuncs, GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glMapGrid2f(un, u1, u2, vn, v1, v2);
+}
+
+void gl1_3_glMapGrid2d(void *_glfuncs, GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glMapGrid2d(un, u1, u2, vn, v1, v2);
+}
+
+void gl1_3_glMapGrid1f(void *_glfuncs, GLint un, GLfloat u1, GLfloat u2)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glMapGrid1f(un, u1, u2);
+}
+
+void gl1_3_glMapGrid1d(void *_glfuncs, GLint un, GLdouble u1, GLdouble u2)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glMapGrid1d(un, u1, u2);
+}
+
+void gl1_3_glMap2f(void *_glfuncs, GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat* points)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glMap2f(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+void gl1_3_glMap2d(void *_glfuncs, GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble* points)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glMap2d(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+void gl1_3_glMap1f(void *_glfuncs, GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat* points)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glMap1f(target, u1, u2, stride, order, points);
+}
+
+void gl1_3_glMap1d(void *_glfuncs, GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble* points)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glMap1d(target, u1, u2, stride, order, points);
+}
+
+void gl1_3_glPushAttrib(void *_glfuncs, GLbitfield mask)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glPushAttrib(mask);
+}
+
+void gl1_3_glPopAttrib(void *_glfuncs)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glPopAttrib();
+}
+
+void gl1_3_glAccum(void *_glfuncs, GLenum op, GLfloat value)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glAccum(op, value);
+}
+
+void gl1_3_glIndexMask(void *_glfuncs, GLuint mask)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glIndexMask(mask);
+}
+
+void gl1_3_glClearIndex(void *_glfuncs, GLfloat c)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glClearIndex(c);
+}
+
+void gl1_3_glClearAccum(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glClearAccum(red, green, blue, alpha);
+}
+
+void gl1_3_glPushName(void *_glfuncs, GLuint name)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glPushName(name);
+}
+
+void gl1_3_glPopName(void *_glfuncs)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glPopName();
+}
+
+void gl1_3_glPassThrough(void *_glfuncs, GLfloat token)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glPassThrough(token);
+}
+
+void gl1_3_glLoadName(void *_glfuncs, GLuint name)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glLoadName(name);
+}
+
+void gl1_3_glInitNames(void *_glfuncs)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glInitNames();
+}
+
+GLint gl1_3_glRenderMode(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ return _qglfuncs->glRenderMode(mode);
+}
+
+void gl1_3_glSelectBuffer(void *_glfuncs, GLsizei size, GLuint* buffer)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glSelectBuffer(size, buffer);
+}
+
+void gl1_3_glFeedbackBuffer(void *_glfuncs, GLsizei size, GLenum gltype, GLfloat* buffer)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glFeedbackBuffer(size, gltype, buffer);
+}
+
+void gl1_3_glTexGeniv(void *_glfuncs, GLenum coord, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glTexGeniv(coord, pname, params);
+}
+
+void gl1_3_glTexGeni(void *_glfuncs, GLenum coord, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glTexGeni(coord, pname, param);
+}
+
+void gl1_3_glTexGenfv(void *_glfuncs, GLenum coord, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glTexGenfv(coord, pname, params);
+}
+
+void gl1_3_glTexGenf(void *_glfuncs, GLenum coord, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glTexGenf(coord, pname, param);
+}
+
+void gl1_3_glTexGendv(void *_glfuncs, GLenum coord, GLenum pname, const GLdouble* params)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glTexGendv(coord, pname, params);
+}
+
+void gl1_3_glTexGend(void *_glfuncs, GLenum coord, GLenum pname, GLdouble param)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glTexGend(coord, pname, param);
+}
+
+void gl1_3_glTexEnviv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glTexEnviv(target, pname, params);
+}
+
+void gl1_3_glTexEnvi(void *_glfuncs, GLenum target, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glTexEnvi(target, pname, param);
+}
+
+void gl1_3_glTexEnvfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glTexEnvfv(target, pname, params);
+}
+
+void gl1_3_glTexEnvf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glTexEnvf(target, pname, param);
+}
+
+void gl1_3_glShadeModel(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glShadeModel(mode);
+}
+
+void gl1_3_glPolygonStipple(void *_glfuncs, const GLubyte* mask)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glPolygonStipple(mask);
+}
+
+void gl1_3_glMaterialiv(void *_glfuncs, GLenum face, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glMaterialiv(face, pname, params);
+}
+
+void gl1_3_glMateriali(void *_glfuncs, GLenum face, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glMateriali(face, pname, param);
+}
+
+void gl1_3_glMaterialfv(void *_glfuncs, GLenum face, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glMaterialfv(face, pname, params);
+}
+
+void gl1_3_glMaterialf(void *_glfuncs, GLenum face, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glMaterialf(face, pname, param);
+}
+
+void gl1_3_glLineStipple(void *_glfuncs, GLint factor, GLushort pattern)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glLineStipple(factor, pattern);
+}
+
+void gl1_3_glLightModeliv(void *_glfuncs, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glLightModeliv(pname, params);
+}
+
+void gl1_3_glLightModeli(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glLightModeli(pname, param);
+}
+
+void gl1_3_glLightModelfv(void *_glfuncs, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glLightModelfv(pname, params);
+}
+
+void gl1_3_glLightModelf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glLightModelf(pname, param);
+}
+
+void gl1_3_glLightiv(void *_glfuncs, GLenum light, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glLightiv(light, pname, params);
+}
+
+void gl1_3_glLighti(void *_glfuncs, GLenum light, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glLighti(light, pname, param);
+}
+
+void gl1_3_glLightfv(void *_glfuncs, GLenum light, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glLightfv(light, pname, params);
+}
+
+void gl1_3_glLightf(void *_glfuncs, GLenum light, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glLightf(light, pname, param);
+}
+
+void gl1_3_glFogiv(void *_glfuncs, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glFogiv(pname, params);
+}
+
+void gl1_3_glFogi(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glFogi(pname, param);
+}
+
+void gl1_3_glFogfv(void *_glfuncs, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glFogfv(pname, params);
+}
+
+void gl1_3_glFogf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glFogf(pname, param);
+}
+
+void gl1_3_glColorMaterial(void *_glfuncs, GLenum face, GLenum mode)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glColorMaterial(face, mode);
+}
+
+void gl1_3_glClipPlane(void *_glfuncs, GLenum plane, const GLdouble* equation)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glClipPlane(plane, equation);
+}
+
+void gl1_3_glVertex4sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glVertex4sv(v);
+}
+
+void gl1_3_glVertex4s(void *_glfuncs, GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glVertex4s(x, y, z, w);
+}
+
+void gl1_3_glVertex4iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glVertex4iv(v);
+}
+
+void gl1_3_glVertex4i(void *_glfuncs, GLint x, GLint y, GLint z, GLint w)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glVertex4i(x, y, z, w);
+}
+
+void gl1_3_glVertex4fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glVertex4fv(v);
+}
+
+void gl1_3_glVertex4f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glVertex4f(x, y, z, w);
+}
+
+void gl1_3_glVertex4dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glVertex4dv(v);
+}
+
+void gl1_3_glVertex4d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glVertex4d(x, y, z, w);
+}
+
+void gl1_3_glVertex3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glVertex3sv(v);
+}
+
+void gl1_3_glVertex3s(void *_glfuncs, GLshort x, GLshort y, GLshort z)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glVertex3s(x, y, z);
+}
+
+void gl1_3_glVertex3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glVertex3iv(v);
+}
+
+void gl1_3_glVertex3i(void *_glfuncs, GLint x, GLint y, GLint z)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glVertex3i(x, y, z);
+}
+
+void gl1_3_glVertex3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glVertex3fv(v);
+}
+
+void gl1_3_glVertex3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glVertex3f(x, y, z);
+}
+
+void gl1_3_glVertex3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glVertex3dv(v);
+}
+
+void gl1_3_glVertex3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glVertex3d(x, y, z);
+}
+
+void gl1_3_glVertex2sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glVertex2sv(v);
+}
+
+void gl1_3_glVertex2s(void *_glfuncs, GLshort x, GLshort y)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glVertex2s(x, y);
+}
+
+void gl1_3_glVertex2iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glVertex2iv(v);
+}
+
+void gl1_3_glVertex2i(void *_glfuncs, GLint x, GLint y)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glVertex2i(x, y);
+}
+
+void gl1_3_glVertex2fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glVertex2fv(v);
+}
+
+void gl1_3_glVertex2f(void *_glfuncs, GLfloat x, GLfloat y)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glVertex2f(x, y);
+}
+
+void gl1_3_glVertex2dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glVertex2dv(v);
+}
+
+void gl1_3_glVertex2d(void *_glfuncs, GLdouble x, GLdouble y)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glVertex2d(x, y);
+}
+
+void gl1_3_glTexCoord4sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glTexCoord4sv(v);
+}
+
+void gl1_3_glTexCoord4s(void *_glfuncs, GLshort s, GLshort t, GLshort r, GLshort q)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glTexCoord4s(s, t, r, q);
+}
+
+void gl1_3_glTexCoord4iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glTexCoord4iv(v);
+}
+
+void gl1_3_glTexCoord4i(void *_glfuncs, GLint s, GLint t, GLint r, GLint q)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glTexCoord4i(s, t, r, q);
+}
+
+void gl1_3_glTexCoord4fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glTexCoord4fv(v);
+}
+
+void gl1_3_glTexCoord4f(void *_glfuncs, GLfloat s, GLfloat t, GLfloat r, GLfloat q)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glTexCoord4f(s, t, r, q);
+}
+
+void gl1_3_glTexCoord4dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glTexCoord4dv(v);
+}
+
+void gl1_3_glTexCoord4d(void *_glfuncs, GLdouble s, GLdouble t, GLdouble r, GLdouble q)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glTexCoord4d(s, t, r, q);
+}
+
+void gl1_3_glTexCoord3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glTexCoord3sv(v);
+}
+
+void gl1_3_glTexCoord3s(void *_glfuncs, GLshort s, GLshort t, GLshort r)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glTexCoord3s(s, t, r);
+}
+
+void gl1_3_glTexCoord3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glTexCoord3iv(v);
+}
+
+void gl1_3_glTexCoord3i(void *_glfuncs, GLint s, GLint t, GLint r)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glTexCoord3i(s, t, r);
+}
+
+void gl1_3_glTexCoord3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glTexCoord3fv(v);
+}
+
+void gl1_3_glTexCoord3f(void *_glfuncs, GLfloat s, GLfloat t, GLfloat r)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glTexCoord3f(s, t, r);
+}
+
+void gl1_3_glTexCoord3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glTexCoord3dv(v);
+}
+
+void gl1_3_glTexCoord3d(void *_glfuncs, GLdouble s, GLdouble t, GLdouble r)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glTexCoord3d(s, t, r);
+}
+
+void gl1_3_glTexCoord2sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glTexCoord2sv(v);
+}
+
+void gl1_3_glTexCoord2s(void *_glfuncs, GLshort s, GLshort t)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glTexCoord2s(s, t);
+}
+
+void gl1_3_glTexCoord2iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glTexCoord2iv(v);
+}
+
+void gl1_3_glTexCoord2i(void *_glfuncs, GLint s, GLint t)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glTexCoord2i(s, t);
+}
+
+void gl1_3_glTexCoord2fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glTexCoord2fv(v);
+}
+
+void gl1_3_glTexCoord2f(void *_glfuncs, GLfloat s, GLfloat t)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glTexCoord2f(s, t);
+}
+
+void gl1_3_glTexCoord2dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glTexCoord2dv(v);
+}
+
+void gl1_3_glTexCoord2d(void *_glfuncs, GLdouble s, GLdouble t)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glTexCoord2d(s, t);
+}
+
+void gl1_3_glTexCoord1sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glTexCoord1sv(v);
+}
+
+void gl1_3_glTexCoord1s(void *_glfuncs, GLshort s)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glTexCoord1s(s);
+}
+
+void gl1_3_glTexCoord1iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glTexCoord1iv(v);
+}
+
+void gl1_3_glTexCoord1i(void *_glfuncs, GLint s)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glTexCoord1i(s);
+}
+
+void gl1_3_glTexCoord1fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glTexCoord1fv(v);
+}
+
+void gl1_3_glTexCoord1f(void *_glfuncs, GLfloat s)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glTexCoord1f(s);
+}
+
+void gl1_3_glTexCoord1dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glTexCoord1dv(v);
+}
+
+void gl1_3_glTexCoord1d(void *_glfuncs, GLdouble s)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glTexCoord1d(s);
+}
+
+void gl1_3_glRectsv(void *_glfuncs, const GLshort* v1, const GLshort* v2)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glRectsv(v1, v2);
+}
+
+void gl1_3_glRects(void *_glfuncs, GLshort x1, GLshort y1, GLshort x2, GLshort y2)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glRects(x1, y1, x2, y2);
+}
+
+void gl1_3_glRectiv(void *_glfuncs, const GLint* v1, const GLint* v2)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glRectiv(v1, v2);
+}
+
+void gl1_3_glRecti(void *_glfuncs, GLint x1, GLint y1, GLint x2, GLint y2)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glRecti(x1, y1, x2, y2);
+}
+
+void gl1_3_glRectfv(void *_glfuncs, const GLfloat* v1, const GLfloat* v2)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glRectfv(v1, v2);
+}
+
+void gl1_3_glRectf(void *_glfuncs, GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glRectf(x1, y1, x2, y2);
+}
+
+void gl1_3_glRectdv(void *_glfuncs, const GLdouble* v1, const GLdouble* v2)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glRectdv(v1, v2);
+}
+
+void gl1_3_glRectd(void *_glfuncs, GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glRectd(x1, y1, x2, y2);
+}
+
+void gl1_3_glRasterPos4sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glRasterPos4sv(v);
+}
+
+void gl1_3_glRasterPos4s(void *_glfuncs, GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glRasterPos4s(x, y, z, w);
+}
+
+void gl1_3_glRasterPos4iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glRasterPos4iv(v);
+}
+
+void gl1_3_glRasterPos4i(void *_glfuncs, GLint x, GLint y, GLint z, GLint w)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glRasterPos4i(x, y, z, w);
+}
+
+void gl1_3_glRasterPos4fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glRasterPos4fv(v);
+}
+
+void gl1_3_glRasterPos4f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glRasterPos4f(x, y, z, w);
+}
+
+void gl1_3_glRasterPos4dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glRasterPos4dv(v);
+}
+
+void gl1_3_glRasterPos4d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glRasterPos4d(x, y, z, w);
+}
+
+void gl1_3_glRasterPos3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glRasterPos3sv(v);
+}
+
+void gl1_3_glRasterPos3s(void *_glfuncs, GLshort x, GLshort y, GLshort z)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glRasterPos3s(x, y, z);
+}
+
+void gl1_3_glRasterPos3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glRasterPos3iv(v);
+}
+
+void gl1_3_glRasterPos3i(void *_glfuncs, GLint x, GLint y, GLint z)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glRasterPos3i(x, y, z);
+}
+
+void gl1_3_glRasterPos3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glRasterPos3fv(v);
+}
+
+void gl1_3_glRasterPos3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glRasterPos3f(x, y, z);
+}
+
+void gl1_3_glRasterPos3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glRasterPos3dv(v);
+}
+
+void gl1_3_glRasterPos3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glRasterPos3d(x, y, z);
+}
+
+void gl1_3_glRasterPos2sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glRasterPos2sv(v);
+}
+
+void gl1_3_glRasterPos2s(void *_glfuncs, GLshort x, GLshort y)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glRasterPos2s(x, y);
+}
+
+void gl1_3_glRasterPos2iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glRasterPos2iv(v);
+}
+
+void gl1_3_glRasterPos2i(void *_glfuncs, GLint x, GLint y)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glRasterPos2i(x, y);
+}
+
+void gl1_3_glRasterPos2fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glRasterPos2fv(v);
+}
+
+void gl1_3_glRasterPos2f(void *_glfuncs, GLfloat x, GLfloat y)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glRasterPos2f(x, y);
+}
+
+void gl1_3_glRasterPos2dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glRasterPos2dv(v);
+}
+
+void gl1_3_glRasterPos2d(void *_glfuncs, GLdouble x, GLdouble y)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glRasterPos2d(x, y);
+}
+
+void gl1_3_glNormal3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glNormal3sv(v);
+}
+
+void gl1_3_glNormal3s(void *_glfuncs, GLshort nx, GLshort ny, GLshort nz)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glNormal3s(nx, ny, nz);
+}
+
+void gl1_3_glNormal3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glNormal3iv(v);
+}
+
+void gl1_3_glNormal3i(void *_glfuncs, GLint nx, GLint ny, GLint nz)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glNormal3i(nx, ny, nz);
+}
+
+void gl1_3_glNormal3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glNormal3fv(v);
+}
+
+void gl1_3_glNormal3f(void *_glfuncs, GLfloat nx, GLfloat ny, GLfloat nz)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glNormal3f(nx, ny, nz);
+}
+
+void gl1_3_glNormal3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glNormal3dv(v);
+}
+
+void gl1_3_glNormal3d(void *_glfuncs, GLdouble nx, GLdouble ny, GLdouble nz)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glNormal3d(nx, ny, nz);
+}
+
+void gl1_3_glNormal3bv(void *_glfuncs, const GLbyte* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glNormal3bv(v);
+}
+
+void gl1_3_glNormal3b(void *_glfuncs, GLbyte nx, GLbyte ny, GLbyte nz)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glNormal3b(nx, ny, nz);
+}
+
+void gl1_3_glIndexsv(void *_glfuncs, const GLshort* c)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glIndexsv(c);
+}
+
+void gl1_3_glIndexs(void *_glfuncs, GLshort c)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glIndexs(c);
+}
+
+void gl1_3_glIndexiv(void *_glfuncs, const GLint* c)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glIndexiv(c);
+}
+
+void gl1_3_glIndexi(void *_glfuncs, GLint c)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glIndexi(c);
+}
+
+void gl1_3_glIndexfv(void *_glfuncs, const GLfloat* c)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glIndexfv(c);
+}
+
+void gl1_3_glIndexf(void *_glfuncs, GLfloat c)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glIndexf(c);
+}
+
+void gl1_3_glIndexdv(void *_glfuncs, const GLdouble* c)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glIndexdv(c);
+}
+
+void gl1_3_glIndexd(void *_glfuncs, GLdouble c)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glIndexd(c);
+}
+
+void gl1_3_glEnd(void *_glfuncs)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glEnd();
+}
+
+void gl1_3_glEdgeFlagv(void *_glfuncs, const GLboolean* flag)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glEdgeFlagv(flag);
+}
+
+void gl1_3_glEdgeFlag(void *_glfuncs, GLboolean flag)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glEdgeFlag(flag);
+}
+
+void gl1_3_glColor4usv(void *_glfuncs, const GLushort* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glColor4usv(v);
+}
+
+void gl1_3_glColor4us(void *_glfuncs, GLushort red, GLushort green, GLushort blue, GLushort alpha)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glColor4us(red, green, blue, alpha);
+}
+
+void gl1_3_glColor4uiv(void *_glfuncs, const GLuint* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glColor4uiv(v);
+}
+
+void gl1_3_glColor4ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue, GLuint alpha)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glColor4ui(red, green, blue, alpha);
+}
+
+void gl1_3_glColor4ubv(void *_glfuncs, const GLubyte* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glColor4ubv(v);
+}
+
+void gl1_3_glColor4ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glColor4ub(red, green, blue, alpha);
+}
+
+void gl1_3_glColor4sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glColor4sv(v);
+}
+
+void gl1_3_glColor4s(void *_glfuncs, GLshort red, GLshort green, GLshort blue, GLshort alpha)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glColor4s(red, green, blue, alpha);
+}
+
+void gl1_3_glColor4iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glColor4iv(v);
+}
+
+void gl1_3_glColor4i(void *_glfuncs, GLint red, GLint green, GLint blue, GLint alpha)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glColor4i(red, green, blue, alpha);
+}
+
+void gl1_3_glColor4fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glColor4fv(v);
+}
+
+void gl1_3_glColor4f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glColor4f(red, green, blue, alpha);
+}
+
+void gl1_3_glColor4dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glColor4dv(v);
+}
+
+void gl1_3_glColor4d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glColor4d(red, green, blue, alpha);
+}
+
+void gl1_3_glColor4bv(void *_glfuncs, const GLbyte* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glColor4bv(v);
+}
+
+void gl1_3_glColor4b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glColor4b(red, green, blue, alpha);
+}
+
+void gl1_3_glColor3usv(void *_glfuncs, const GLushort* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glColor3usv(v);
+}
+
+void gl1_3_glColor3us(void *_glfuncs, GLushort red, GLushort green, GLushort blue)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glColor3us(red, green, blue);
+}
+
+void gl1_3_glColor3uiv(void *_glfuncs, const GLuint* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glColor3uiv(v);
+}
+
+void gl1_3_glColor3ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glColor3ui(red, green, blue);
+}
+
+void gl1_3_glColor3ubv(void *_glfuncs, const GLubyte* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glColor3ubv(v);
+}
+
+void gl1_3_glColor3ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glColor3ub(red, green, blue);
+}
+
+void gl1_3_glColor3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glColor3sv(v);
+}
+
+void gl1_3_glColor3s(void *_glfuncs, GLshort red, GLshort green, GLshort blue)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glColor3s(red, green, blue);
+}
+
+void gl1_3_glColor3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glColor3iv(v);
+}
+
+void gl1_3_glColor3i(void *_glfuncs, GLint red, GLint green, GLint blue)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glColor3i(red, green, blue);
+}
+
+void gl1_3_glColor3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glColor3fv(v);
+}
+
+void gl1_3_glColor3f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glColor3f(red, green, blue);
+}
+
+void gl1_3_glColor3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glColor3dv(v);
+}
+
+void gl1_3_glColor3d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glColor3d(red, green, blue);
+}
+
+void gl1_3_glColor3bv(void *_glfuncs, const GLbyte* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glColor3bv(v);
+}
+
+void gl1_3_glColor3b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glColor3b(red, green, blue);
+}
+
+void gl1_3_glBitmap(void *_glfuncs, GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte* bitmap)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glBitmap(width, height, xorig, yorig, xmove, ymove, bitmap);
+}
+
+void gl1_3_glBegin(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glBegin(mode);
+}
+
+void gl1_3_glListBase(void *_glfuncs, GLuint base)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glListBase(base);
+}
+
+GLuint gl1_3_glGenLists(void *_glfuncs, GLsizei range_)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ return _qglfuncs->glGenLists(range_);
+}
+
+void gl1_3_glDeleteLists(void *_glfuncs, GLuint list, GLsizei range_)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glDeleteLists(list, range_);
+}
+
+void gl1_3_glCallLists(void *_glfuncs, GLsizei n, GLenum gltype, const GLvoid* lists)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glCallLists(n, gltype, lists);
+}
+
+void gl1_3_glCallList(void *_glfuncs, GLuint list)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glCallList(list);
+}
+
+void gl1_3_glEndList(void *_glfuncs)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glEndList();
+}
+
+void gl1_3_glNewList(void *_glfuncs, GLuint list, GLenum mode)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glNewList(list, mode);
+}
+
+void gl1_3_glPushClientAttrib(void *_glfuncs, GLbitfield mask)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glPushClientAttrib(mask);
+}
+
+void gl1_3_glPopClientAttrib(void *_glfuncs)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glPopClientAttrib();
+}
+
+void gl1_3_glPrioritizeTextures(void *_glfuncs, GLsizei n, const GLuint* textures, const GLfloat* priorities)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glPrioritizeTextures(n, textures, priorities);
+}
+
+GLboolean gl1_3_glAreTexturesResident(void *_glfuncs, GLsizei n, const GLuint* textures, GLboolean* residences)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ return _qglfuncs->glAreTexturesResident(n, textures, residences);
+}
+
+void gl1_3_glVertexPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glVertexPointer(size, gltype, stride, pointer);
+}
+
+void gl1_3_glTexCoordPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glTexCoordPointer(size, gltype, stride, pointer);
+}
+
+void gl1_3_glNormalPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glNormalPointer(gltype, stride, pointer);
+}
+
+void gl1_3_glInterleavedArrays(void *_glfuncs, GLenum format, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glInterleavedArrays(format, stride, pointer);
+}
+
+void gl1_3_glIndexPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glIndexPointer(gltype, stride, pointer);
+}
+
+void gl1_3_glEnableClientState(void *_glfuncs, GLenum array)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glEnableClientState(array);
+}
+
+void gl1_3_glEdgeFlagPointer(void *_glfuncs, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glEdgeFlagPointer(stride, pointer);
+}
+
+void gl1_3_glDisableClientState(void *_glfuncs, GLenum array)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glDisableClientState(array);
+}
+
+void gl1_3_glColorPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glColorPointer(size, gltype, stride, pointer);
+}
+
+void gl1_3_glArrayElement(void *_glfuncs, GLint i)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glArrayElement(i);
+}
+
+void gl1_3_glResetMinmax(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glResetMinmax(target);
+}
+
+void gl1_3_glResetHistogram(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glResetHistogram(target);
+}
+
+void gl1_3_glMinmax(void *_glfuncs, GLenum target, GLenum internalFormat, GLboolean sink)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glMinmax(target, internalFormat, sink);
+}
+
+void gl1_3_glHistogram(void *_glfuncs, GLenum target, GLsizei width, GLenum internalFormat, GLboolean sink)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glHistogram(target, width, internalFormat, sink);
+}
+
+void gl1_3_glGetMinmaxParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glGetMinmaxParameteriv(target, pname, params);
+}
+
+void gl1_3_glGetMinmaxParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glGetMinmaxParameterfv(target, pname, params);
+}
+
+void gl1_3_glGetMinmax(void *_glfuncs, GLenum target, GLboolean reset, GLenum format, GLenum gltype, GLvoid* values)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glGetMinmax(target, reset, format, gltype, values);
+}
+
+void gl1_3_glGetHistogramParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glGetHistogramParameteriv(target, pname, params);
+}
+
+void gl1_3_glGetHistogramParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glGetHistogramParameterfv(target, pname, params);
+}
+
+void gl1_3_glGetHistogram(void *_glfuncs, GLenum target, GLboolean reset, GLenum format, GLenum gltype, GLvoid* values)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glGetHistogram(target, reset, format, gltype, values);
+}
+
+void gl1_3_glSeparableFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* row, const GLvoid* column)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glSeparableFilter2D(target, internalFormat, width, height, format, gltype, row, column);
+}
+
+void gl1_3_glGetSeparableFilter(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* row, GLvoid* column, GLvoid* span)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glGetSeparableFilter(target, format, gltype, row, column, span);
+}
+
+void gl1_3_glGetConvolutionParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glGetConvolutionParameteriv(target, pname, params);
+}
+
+void gl1_3_glGetConvolutionParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glGetConvolutionParameterfv(target, pname, params);
+}
+
+void gl1_3_glGetConvolutionFilter(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* image)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glGetConvolutionFilter(target, format, gltype, image);
+}
+
+void gl1_3_glCopyConvolutionFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glCopyConvolutionFilter2D(target, internalFormat, x, y, width, height);
+}
+
+void gl1_3_glCopyConvolutionFilter1D(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glCopyConvolutionFilter1D(target, internalFormat, x, y, width);
+}
+
+void gl1_3_glConvolutionParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glConvolutionParameteriv(target, pname, params);
+}
+
+void gl1_3_glConvolutionParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint params)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glConvolutionParameteri(target, pname, params);
+}
+
+void gl1_3_glConvolutionParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glConvolutionParameterfv(target, pname, params);
+}
+
+void gl1_3_glConvolutionParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat params)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glConvolutionParameterf(target, pname, params);
+}
+
+void gl1_3_glConvolutionFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* image)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glConvolutionFilter2D(target, internalFormat, width, height, format, gltype, image);
+}
+
+void gl1_3_glConvolutionFilter1D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLenum format, GLenum gltype, const GLvoid* image)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glConvolutionFilter1D(target, internalFormat, width, format, gltype, image);
+}
+
+void gl1_3_glCopyColorSubTable(void *_glfuncs, GLenum target, GLsizei start, GLint x, GLint y, GLsizei width)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glCopyColorSubTable(target, start, x, y, width);
+}
+
+void gl1_3_glColorSubTable(void *_glfuncs, GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum gltype, const GLvoid* data)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glColorSubTable(target, start, count, format, gltype, data);
+}
+
+void gl1_3_glGetColorTableParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glGetColorTableParameteriv(target, pname, params);
+}
+
+void gl1_3_glGetColorTableParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glGetColorTableParameterfv(target, pname, params);
+}
+
+void gl1_3_glGetColorTable(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* table)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glGetColorTable(target, format, gltype, table);
+}
+
+void gl1_3_glCopyColorTable(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glCopyColorTable(target, internalFormat, x, y, width);
+}
+
+void gl1_3_glColorTableParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glColorTableParameteriv(target, pname, params);
+}
+
+void gl1_3_glColorTableParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glColorTableParameterfv(target, pname, params);
+}
+
+void gl1_3_glColorTable(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLenum format, GLenum gltype, const GLvoid* table)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glColorTable(target, internalFormat, width, format, gltype, table);
+}
+
+void gl1_3_glMultTransposeMatrixd(void *_glfuncs, const GLdouble* m)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glMultTransposeMatrixd(m);
+}
+
+void gl1_3_glMultTransposeMatrixf(void *_glfuncs, const GLfloat* m)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glMultTransposeMatrixf(m);
+}
+
+void gl1_3_glLoadTransposeMatrixd(void *_glfuncs, const GLdouble* m)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glLoadTransposeMatrixd(m);
+}
+
+void gl1_3_glLoadTransposeMatrixf(void *_glfuncs, const GLfloat* m)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glLoadTransposeMatrixf(m);
+}
+
+void gl1_3_glMultiTexCoord4sv(void *_glfuncs, GLenum target, const GLshort* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4sv(target, v);
+}
+
+void gl1_3_glMultiTexCoord4s(void *_glfuncs, GLenum target, GLshort s, GLshort t, GLshort r, GLshort q)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4s(target, s, t, r, q);
+}
+
+void gl1_3_glMultiTexCoord4iv(void *_glfuncs, GLenum target, const GLint* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4iv(target, v);
+}
+
+void gl1_3_glMultiTexCoord4i(void *_glfuncs, GLenum target, GLint s, GLint t, GLint r, GLint q)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4i(target, s, t, r, q);
+}
+
+void gl1_3_glMultiTexCoord4fv(void *_glfuncs, GLenum target, const GLfloat* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4fv(target, v);
+}
+
+void gl1_3_glMultiTexCoord4f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4f(target, s, t, r, q);
+}
+
+void gl1_3_glMultiTexCoord4dv(void *_glfuncs, GLenum target, const GLdouble* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4dv(target, v);
+}
+
+void gl1_3_glMultiTexCoord4d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4d(target, s, t, r, q);
+}
+
+void gl1_3_glMultiTexCoord3sv(void *_glfuncs, GLenum target, const GLshort* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3sv(target, v);
+}
+
+void gl1_3_glMultiTexCoord3s(void *_glfuncs, GLenum target, GLshort s, GLshort t, GLshort r)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3s(target, s, t, r);
+}
+
+void gl1_3_glMultiTexCoord3iv(void *_glfuncs, GLenum target, const GLint* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3iv(target, v);
+}
+
+void gl1_3_glMultiTexCoord3i(void *_glfuncs, GLenum target, GLint s, GLint t, GLint r)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3i(target, s, t, r);
+}
+
+void gl1_3_glMultiTexCoord3fv(void *_glfuncs, GLenum target, const GLfloat* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3fv(target, v);
+}
+
+void gl1_3_glMultiTexCoord3f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t, GLfloat r)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3f(target, s, t, r);
+}
+
+void gl1_3_glMultiTexCoord3dv(void *_glfuncs, GLenum target, const GLdouble* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3dv(target, v);
+}
+
+void gl1_3_glMultiTexCoord3d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t, GLdouble r)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3d(target, s, t, r);
+}
+
+void gl1_3_glMultiTexCoord2sv(void *_glfuncs, GLenum target, const GLshort* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2sv(target, v);
+}
+
+void gl1_3_glMultiTexCoord2s(void *_glfuncs, GLenum target, GLshort s, GLshort t)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2s(target, s, t);
+}
+
+void gl1_3_glMultiTexCoord2iv(void *_glfuncs, GLenum target, const GLint* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2iv(target, v);
+}
+
+void gl1_3_glMultiTexCoord2i(void *_glfuncs, GLenum target, GLint s, GLint t)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2i(target, s, t);
+}
+
+void gl1_3_glMultiTexCoord2fv(void *_glfuncs, GLenum target, const GLfloat* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2fv(target, v);
+}
+
+void gl1_3_glMultiTexCoord2f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2f(target, s, t);
+}
+
+void gl1_3_glMultiTexCoord2dv(void *_glfuncs, GLenum target, const GLdouble* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2dv(target, v);
+}
+
+void gl1_3_glMultiTexCoord2d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2d(target, s, t);
+}
+
+void gl1_3_glMultiTexCoord1sv(void *_glfuncs, GLenum target, const GLshort* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1sv(target, v);
+}
+
+void gl1_3_glMultiTexCoord1s(void *_glfuncs, GLenum target, GLshort s)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1s(target, s);
+}
+
+void gl1_3_glMultiTexCoord1iv(void *_glfuncs, GLenum target, const GLint* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1iv(target, v);
+}
+
+void gl1_3_glMultiTexCoord1i(void *_glfuncs, GLenum target, GLint s)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1i(target, s);
+}
+
+void gl1_3_glMultiTexCoord1fv(void *_glfuncs, GLenum target, const GLfloat* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1fv(target, v);
+}
+
+void gl1_3_glMultiTexCoord1f(void *_glfuncs, GLenum target, GLfloat s)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1f(target, s);
+}
+
+void gl1_3_glMultiTexCoord1dv(void *_glfuncs, GLenum target, const GLdouble* v)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1dv(target, v);
+}
+
+void gl1_3_glMultiTexCoord1d(void *_glfuncs, GLenum target, GLdouble s)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1d(target, s);
+}
+
+void gl1_3_glClientActiveTexture(void *_glfuncs, GLenum texture)
+{
+ QOpenGLFunctions_1_3* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_3*>(_glfuncs);
+ _qglfuncs->glClientActiveTexture(texture);
+}
+
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/1.3/funcs.h b/Godeps/_workspace/src/github.com/obscuren/qml/gl/1.3/funcs.h
new file mode 100644
index 000000000..9d3944383
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/1.3/funcs.h
@@ -0,0 +1,460 @@
+
+// ** file automatically generated by glgen -- do not edit manually **
+
+#ifndef __cplusplus
+#include <inttypes.h>
+#include <stddef.h>
+typedef unsigned int GLenum;
+typedef unsigned char GLboolean;
+typedef unsigned int GLbitfield;
+typedef void GLvoid;
+typedef char GLchar;
+typedef signed char GLbyte; /* 1-byte signed */
+typedef short GLshort; /* 2-byte signed */
+typedef int GLint; /* 4-byte signed */
+typedef unsigned char GLubyte; /* 1-byte unsigned */
+typedef unsigned short GLushort; /* 2-byte unsigned */
+typedef unsigned int GLuint; /* 4-byte unsigned */
+typedef int GLsizei; /* 4-byte signed */
+typedef float GLfloat; /* single precision float */
+typedef float GLclampf; /* single precision float in [0,1] */
+typedef double GLdouble; /* double precision float */
+typedef double GLclampd; /* double precision float in [0,1] */
+typedef int64_t GLint64;
+typedef uint64_t GLuint64;
+typedef ptrdiff_t GLintptr;
+typedef ptrdiff_t GLsizeiptr;
+typedef ptrdiff_t GLintptrARB;
+typedef ptrdiff_t GLsizeiptrARB;
+typedef struct __GLsync *GLsync;
+#endif
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+void *gl1_3_funcs();
+
+void gl1_3_glViewport(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl1_3_glDepthRange(void *_glfuncs, GLdouble nearVal, GLdouble farVal);
+GLboolean gl1_3_glIsEnabled(void *_glfuncs, GLenum cap);
+void gl1_3_glGetTexLevelParameteriv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLint* params);
+void gl1_3_glGetTexLevelParameterfv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLfloat* params);
+void gl1_3_glGetTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl1_3_glGetTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl1_3_glGetTexImage(void *_glfuncs, GLenum target, GLint level, GLenum format, GLenum gltype, GLvoid* pixels);
+void gl1_3_glGetIntegerv(void *_glfuncs, GLenum pname, GLint* params);
+void gl1_3_glGetFloatv(void *_glfuncs, GLenum pname, GLfloat* params);
+GLenum gl1_3_glGetError(void *_glfuncs);
+void gl1_3_glGetDoublev(void *_glfuncs, GLenum pname, GLdouble* params);
+void gl1_3_glGetBooleanv(void *_glfuncs, GLenum pname, GLboolean* params);
+void gl1_3_glReadPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum gltype, GLvoid* pixels);
+void gl1_3_glReadBuffer(void *_glfuncs, GLenum mode);
+void gl1_3_glPixelStorei(void *_glfuncs, GLenum pname, GLint param);
+void gl1_3_glPixelStoref(void *_glfuncs, GLenum pname, GLfloat param);
+void gl1_3_glDepthFunc(void *_glfuncs, GLenum glfunc);
+void gl1_3_glStencilOp(void *_glfuncs, GLenum fail, GLenum zfail, GLenum zpass);
+void gl1_3_glStencilFunc(void *_glfuncs, GLenum glfunc, GLint ref, GLuint mask);
+void gl1_3_glLogicOp(void *_glfuncs, GLenum opcode);
+void gl1_3_glBlendFunc(void *_glfuncs, GLenum sfactor, GLenum dfactor);
+void gl1_3_glFlush(void *_glfuncs);
+void gl1_3_glFinish(void *_glfuncs);
+void gl1_3_glEnable(void *_glfuncs, GLenum cap);
+void gl1_3_glDisable(void *_glfuncs, GLenum cap);
+void gl1_3_glDepthMask(void *_glfuncs, GLboolean flag);
+void gl1_3_glColorMask(void *_glfuncs, GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha);
+void gl1_3_glStencilMask(void *_glfuncs, GLuint mask);
+void gl1_3_glClearDepth(void *_glfuncs, GLdouble depth);
+void gl1_3_glClearStencil(void *_glfuncs, GLint s);
+void gl1_3_glClearColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl1_3_glClear(void *_glfuncs, GLbitfield mask);
+void gl1_3_glDrawBuffer(void *_glfuncs, GLenum mode);
+void gl1_3_glTexImage2D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl1_3_glTexImage1D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl1_3_glTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl1_3_glTexParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint param);
+void gl1_3_glTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl1_3_glTexParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param);
+void gl1_3_glScissor(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl1_3_glPolygonMode(void *_glfuncs, GLenum face, GLenum mode);
+void gl1_3_glPointSize(void *_glfuncs, GLfloat size);
+void gl1_3_glLineWidth(void *_glfuncs, GLfloat width);
+void gl1_3_glHint(void *_glfuncs, GLenum target, GLenum mode);
+void gl1_3_glFrontFace(void *_glfuncs, GLenum mode);
+void gl1_3_glCullFace(void *_glfuncs, GLenum mode);
+void gl1_3_glIndexubv(void *_glfuncs, const GLubyte* c);
+void gl1_3_glIndexub(void *_glfuncs, GLubyte c);
+GLboolean gl1_3_glIsTexture(void *_glfuncs, GLuint texture);
+void gl1_3_glGenTextures(void *_glfuncs, GLsizei n, GLuint* textures);
+void gl1_3_glDeleteTextures(void *_glfuncs, GLsizei n, const GLuint* textures);
+void gl1_3_glBindTexture(void *_glfuncs, GLenum target, GLuint texture);
+void gl1_3_glTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl1_3_glTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl1_3_glCopyTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl1_3_glCopyTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width);
+void gl1_3_glCopyTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border);
+void gl1_3_glCopyTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLint border);
+void gl1_3_glPolygonOffset(void *_glfuncs, GLfloat factor, GLfloat units);
+void gl1_3_glDrawElements(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices);
+void gl1_3_glDrawArrays(void *_glfuncs, GLenum mode, GLint first, GLsizei count);
+void gl1_3_glCopyTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl1_3_glTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl1_3_glTexImage3D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl1_3_glDrawRangeElements(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices);
+void gl1_3_glBlendEquation(void *_glfuncs, GLenum mode);
+void gl1_3_glBlendColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl1_3_glGetCompressedTexImage(void *_glfuncs, GLenum target, GLint level, GLvoid* img);
+void gl1_3_glCompressedTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid* data);
+void gl1_3_glCompressedTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid* data);
+void gl1_3_glCompressedTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid* data);
+void gl1_3_glCompressedTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid* data);
+void gl1_3_glCompressedTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid* data);
+void gl1_3_glCompressedTexImage3D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid* data);
+void gl1_3_glSampleCoverage(void *_glfuncs, GLfloat value, GLboolean invert);
+void gl1_3_glActiveTexture(void *_glfuncs, GLenum texture);
+void gl1_3_glTranslatef(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl1_3_glTranslated(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl1_3_glScalef(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl1_3_glScaled(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl1_3_glRotatef(void *_glfuncs, GLfloat angle, GLfloat x, GLfloat y, GLfloat z);
+void gl1_3_glRotated(void *_glfuncs, GLdouble angle, GLdouble x, GLdouble y, GLdouble z);
+void gl1_3_glPushMatrix(void *_glfuncs);
+void gl1_3_glPopMatrix(void *_glfuncs);
+void gl1_3_glOrtho(void *_glfuncs, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+void gl1_3_glMultMatrixd(void *_glfuncs, const GLdouble* m);
+void gl1_3_glMultMatrixf(void *_glfuncs, const GLfloat* m);
+void gl1_3_glMatrixMode(void *_glfuncs, GLenum mode);
+void gl1_3_glLoadMatrixd(void *_glfuncs, const GLdouble* m);
+void gl1_3_glLoadMatrixf(void *_glfuncs, const GLfloat* m);
+void gl1_3_glLoadIdentity(void *_glfuncs);
+void gl1_3_glFrustum(void *_glfuncs, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+GLboolean gl1_3_glIsList(void *_glfuncs, GLuint list);
+void gl1_3_glGetTexGeniv(void *_glfuncs, GLenum coord, GLenum pname, GLint* params);
+void gl1_3_glGetTexGenfv(void *_glfuncs, GLenum coord, GLenum pname, GLfloat* params);
+void gl1_3_glGetTexGendv(void *_glfuncs, GLenum coord, GLenum pname, GLdouble* params);
+void gl1_3_glGetTexEnviv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl1_3_glGetTexEnvfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl1_3_glGetPolygonStipple(void *_glfuncs, GLubyte* mask);
+void gl1_3_glGetPixelMapusv(void *_glfuncs, GLenum glmap, GLushort* values);
+void gl1_3_glGetPixelMapuiv(void *_glfuncs, GLenum glmap, GLuint* values);
+void gl1_3_glGetPixelMapfv(void *_glfuncs, GLenum glmap, GLfloat* values);
+void gl1_3_glGetMaterialiv(void *_glfuncs, GLenum face, GLenum pname, GLint* params);
+void gl1_3_glGetMaterialfv(void *_glfuncs, GLenum face, GLenum pname, GLfloat* params);
+void gl1_3_glGetMapiv(void *_glfuncs, GLenum target, GLenum query, GLint* v);
+void gl1_3_glGetMapfv(void *_glfuncs, GLenum target, GLenum query, GLfloat* v);
+void gl1_3_glGetMapdv(void *_glfuncs, GLenum target, GLenum query, GLdouble* v);
+void gl1_3_glGetLightiv(void *_glfuncs, GLenum light, GLenum pname, GLint* params);
+void gl1_3_glGetLightfv(void *_glfuncs, GLenum light, GLenum pname, GLfloat* params);
+void gl1_3_glGetClipPlane(void *_glfuncs, GLenum plane, GLdouble* equation);
+void gl1_3_glDrawPixels(void *_glfuncs, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl1_3_glCopyPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum gltype);
+void gl1_3_glPixelMapusv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLushort* values);
+void gl1_3_glPixelMapuiv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLuint* values);
+void gl1_3_glPixelMapfv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLfloat* values);
+void gl1_3_glPixelTransferi(void *_glfuncs, GLenum pname, GLint param);
+void gl1_3_glPixelTransferf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl1_3_glPixelZoom(void *_glfuncs, GLfloat xfactor, GLfloat yfactor);
+void gl1_3_glAlphaFunc(void *_glfuncs, GLenum glfunc, GLfloat ref);
+void gl1_3_glEvalPoint2(void *_glfuncs, GLint i, GLint j);
+void gl1_3_glEvalMesh2(void *_glfuncs, GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2);
+void gl1_3_glEvalPoint1(void *_glfuncs, GLint i);
+void gl1_3_glEvalMesh1(void *_glfuncs, GLenum mode, GLint i1, GLint i2);
+void gl1_3_glEvalCoord2fv(void *_glfuncs, const GLfloat* u);
+void gl1_3_glEvalCoord2f(void *_glfuncs, GLfloat u, GLfloat v);
+void gl1_3_glEvalCoord2dv(void *_glfuncs, const GLdouble* u);
+void gl1_3_glEvalCoord2d(void *_glfuncs, GLdouble u, GLdouble v);
+void gl1_3_glEvalCoord1fv(void *_glfuncs, const GLfloat* u);
+void gl1_3_glEvalCoord1f(void *_glfuncs, GLfloat u);
+void gl1_3_glEvalCoord1dv(void *_glfuncs, const GLdouble* u);
+void gl1_3_glEvalCoord1d(void *_glfuncs, GLdouble u);
+void gl1_3_glMapGrid2f(void *_glfuncs, GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2);
+void gl1_3_glMapGrid2d(void *_glfuncs, GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2);
+void gl1_3_glMapGrid1f(void *_glfuncs, GLint un, GLfloat u1, GLfloat u2);
+void gl1_3_glMapGrid1d(void *_glfuncs, GLint un, GLdouble u1, GLdouble u2);
+void gl1_3_glMap2f(void *_glfuncs, GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat* points);
+void gl1_3_glMap2d(void *_glfuncs, GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble* points);
+void gl1_3_glMap1f(void *_glfuncs, GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat* points);
+void gl1_3_glMap1d(void *_glfuncs, GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble* points);
+void gl1_3_glPushAttrib(void *_glfuncs, GLbitfield mask);
+void gl1_3_glPopAttrib(void *_glfuncs);
+void gl1_3_glAccum(void *_glfuncs, GLenum op, GLfloat value);
+void gl1_3_glIndexMask(void *_glfuncs, GLuint mask);
+void gl1_3_glClearIndex(void *_glfuncs, GLfloat c);
+void gl1_3_glClearAccum(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl1_3_glPushName(void *_glfuncs, GLuint name);
+void gl1_3_glPopName(void *_glfuncs);
+void gl1_3_glPassThrough(void *_glfuncs, GLfloat token);
+void gl1_3_glLoadName(void *_glfuncs, GLuint name);
+void gl1_3_glInitNames(void *_glfuncs);
+GLint gl1_3_glRenderMode(void *_glfuncs, GLenum mode);
+void gl1_3_glSelectBuffer(void *_glfuncs, GLsizei size, GLuint* buffer);
+void gl1_3_glFeedbackBuffer(void *_glfuncs, GLsizei size, GLenum gltype, GLfloat* buffer);
+void gl1_3_glTexGeniv(void *_glfuncs, GLenum coord, GLenum pname, const GLint* params);
+void gl1_3_glTexGeni(void *_glfuncs, GLenum coord, GLenum pname, GLint param);
+void gl1_3_glTexGenfv(void *_glfuncs, GLenum coord, GLenum pname, const GLfloat* params);
+void gl1_3_glTexGenf(void *_glfuncs, GLenum coord, GLenum pname, GLfloat param);
+void gl1_3_glTexGendv(void *_glfuncs, GLenum coord, GLenum pname, const GLdouble* params);
+void gl1_3_glTexGend(void *_glfuncs, GLenum coord, GLenum pname, GLdouble param);
+void gl1_3_glTexEnviv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl1_3_glTexEnvi(void *_glfuncs, GLenum target, GLenum pname, GLint param);
+void gl1_3_glTexEnvfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl1_3_glTexEnvf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param);
+void gl1_3_glShadeModel(void *_glfuncs, GLenum mode);
+void gl1_3_glPolygonStipple(void *_glfuncs, const GLubyte* mask);
+void gl1_3_glMaterialiv(void *_glfuncs, GLenum face, GLenum pname, const GLint* params);
+void gl1_3_glMateriali(void *_glfuncs, GLenum face, GLenum pname, GLint param);
+void gl1_3_glMaterialfv(void *_glfuncs, GLenum face, GLenum pname, const GLfloat* params);
+void gl1_3_glMaterialf(void *_glfuncs, GLenum face, GLenum pname, GLfloat param);
+void gl1_3_glLineStipple(void *_glfuncs, GLint factor, GLushort pattern);
+void gl1_3_glLightModeliv(void *_glfuncs, GLenum pname, const GLint* params);
+void gl1_3_glLightModeli(void *_glfuncs, GLenum pname, GLint param);
+void gl1_3_glLightModelfv(void *_glfuncs, GLenum pname, const GLfloat* params);
+void gl1_3_glLightModelf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl1_3_glLightiv(void *_glfuncs, GLenum light, GLenum pname, const GLint* params);
+void gl1_3_glLighti(void *_glfuncs, GLenum light, GLenum pname, GLint param);
+void gl1_3_glLightfv(void *_glfuncs, GLenum light, GLenum pname, const GLfloat* params);
+void gl1_3_glLightf(void *_glfuncs, GLenum light, GLenum pname, GLfloat param);
+void gl1_3_glFogiv(void *_glfuncs, GLenum pname, const GLint* params);
+void gl1_3_glFogi(void *_glfuncs, GLenum pname, GLint param);
+void gl1_3_glFogfv(void *_glfuncs, GLenum pname, const GLfloat* params);
+void gl1_3_glFogf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl1_3_glColorMaterial(void *_glfuncs, GLenum face, GLenum mode);
+void gl1_3_glClipPlane(void *_glfuncs, GLenum plane, const GLdouble* equation);
+void gl1_3_glVertex4sv(void *_glfuncs, const GLshort* v);
+void gl1_3_glVertex4s(void *_glfuncs, GLshort x, GLshort y, GLshort z, GLshort w);
+void gl1_3_glVertex4iv(void *_glfuncs, const GLint* v);
+void gl1_3_glVertex4i(void *_glfuncs, GLint x, GLint y, GLint z, GLint w);
+void gl1_3_glVertex4fv(void *_glfuncs, const GLfloat* v);
+void gl1_3_glVertex4f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+void gl1_3_glVertex4dv(void *_glfuncs, const GLdouble* v);
+void gl1_3_glVertex4d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+void gl1_3_glVertex3sv(void *_glfuncs, const GLshort* v);
+void gl1_3_glVertex3s(void *_glfuncs, GLshort x, GLshort y, GLshort z);
+void gl1_3_glVertex3iv(void *_glfuncs, const GLint* v);
+void gl1_3_glVertex3i(void *_glfuncs, GLint x, GLint y, GLint z);
+void gl1_3_glVertex3fv(void *_glfuncs, const GLfloat* v);
+void gl1_3_glVertex3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl1_3_glVertex3dv(void *_glfuncs, const GLdouble* v);
+void gl1_3_glVertex3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl1_3_glVertex2sv(void *_glfuncs, const GLshort* v);
+void gl1_3_glVertex2s(void *_glfuncs, GLshort x, GLshort y);
+void gl1_3_glVertex2iv(void *_glfuncs, const GLint* v);
+void gl1_3_glVertex2i(void *_glfuncs, GLint x, GLint y);
+void gl1_3_glVertex2fv(void *_glfuncs, const GLfloat* v);
+void gl1_3_glVertex2f(void *_glfuncs, GLfloat x, GLfloat y);
+void gl1_3_glVertex2dv(void *_glfuncs, const GLdouble* v);
+void gl1_3_glVertex2d(void *_glfuncs, GLdouble x, GLdouble y);
+void gl1_3_glTexCoord4sv(void *_glfuncs, const GLshort* v);
+void gl1_3_glTexCoord4s(void *_glfuncs, GLshort s, GLshort t, GLshort r, GLshort q);
+void gl1_3_glTexCoord4iv(void *_glfuncs, const GLint* v);
+void gl1_3_glTexCoord4i(void *_glfuncs, GLint s, GLint t, GLint r, GLint q);
+void gl1_3_glTexCoord4fv(void *_glfuncs, const GLfloat* v);
+void gl1_3_glTexCoord4f(void *_glfuncs, GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+void gl1_3_glTexCoord4dv(void *_glfuncs, const GLdouble* v);
+void gl1_3_glTexCoord4d(void *_glfuncs, GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+void gl1_3_glTexCoord3sv(void *_glfuncs, const GLshort* v);
+void gl1_3_glTexCoord3s(void *_glfuncs, GLshort s, GLshort t, GLshort r);
+void gl1_3_glTexCoord3iv(void *_glfuncs, const GLint* v);
+void gl1_3_glTexCoord3i(void *_glfuncs, GLint s, GLint t, GLint r);
+void gl1_3_glTexCoord3fv(void *_glfuncs, const GLfloat* v);
+void gl1_3_glTexCoord3f(void *_glfuncs, GLfloat s, GLfloat t, GLfloat r);
+void gl1_3_glTexCoord3dv(void *_glfuncs, const GLdouble* v);
+void gl1_3_glTexCoord3d(void *_glfuncs, GLdouble s, GLdouble t, GLdouble r);
+void gl1_3_glTexCoord2sv(void *_glfuncs, const GLshort* v);
+void gl1_3_glTexCoord2s(void *_glfuncs, GLshort s, GLshort t);
+void gl1_3_glTexCoord2iv(void *_glfuncs, const GLint* v);
+void gl1_3_glTexCoord2i(void *_glfuncs, GLint s, GLint t);
+void gl1_3_glTexCoord2fv(void *_glfuncs, const GLfloat* v);
+void gl1_3_glTexCoord2f(void *_glfuncs, GLfloat s, GLfloat t);
+void gl1_3_glTexCoord2dv(void *_glfuncs, const GLdouble* v);
+void gl1_3_glTexCoord2d(void *_glfuncs, GLdouble s, GLdouble t);
+void gl1_3_glTexCoord1sv(void *_glfuncs, const GLshort* v);
+void gl1_3_glTexCoord1s(void *_glfuncs, GLshort s);
+void gl1_3_glTexCoord1iv(void *_glfuncs, const GLint* v);
+void gl1_3_glTexCoord1i(void *_glfuncs, GLint s);
+void gl1_3_glTexCoord1fv(void *_glfuncs, const GLfloat* v);
+void gl1_3_glTexCoord1f(void *_glfuncs, GLfloat s);
+void gl1_3_glTexCoord1dv(void *_glfuncs, const GLdouble* v);
+void gl1_3_glTexCoord1d(void *_glfuncs, GLdouble s);
+void gl1_3_glRectsv(void *_glfuncs, const GLshort* v1, const GLshort* v2);
+void gl1_3_glRects(void *_glfuncs, GLshort x1, GLshort y1, GLshort x2, GLshort y2);
+void gl1_3_glRectiv(void *_glfuncs, const GLint* v1, const GLint* v2);
+void gl1_3_glRecti(void *_glfuncs, GLint x1, GLint y1, GLint x2, GLint y2);
+void gl1_3_glRectfv(void *_glfuncs, const GLfloat* v1, const GLfloat* v2);
+void gl1_3_glRectf(void *_glfuncs, GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2);
+void gl1_3_glRectdv(void *_glfuncs, const GLdouble* v1, const GLdouble* v2);
+void gl1_3_glRectd(void *_glfuncs, GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2);
+void gl1_3_glRasterPos4sv(void *_glfuncs, const GLshort* v);
+void gl1_3_glRasterPos4s(void *_glfuncs, GLshort x, GLshort y, GLshort z, GLshort w);
+void gl1_3_glRasterPos4iv(void *_glfuncs, const GLint* v);
+void gl1_3_glRasterPos4i(void *_glfuncs, GLint x, GLint y, GLint z, GLint w);
+void gl1_3_glRasterPos4fv(void *_glfuncs, const GLfloat* v);
+void gl1_3_glRasterPos4f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+void gl1_3_glRasterPos4dv(void *_glfuncs, const GLdouble* v);
+void gl1_3_glRasterPos4d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+void gl1_3_glRasterPos3sv(void *_glfuncs, const GLshort* v);
+void gl1_3_glRasterPos3s(void *_glfuncs, GLshort x, GLshort y, GLshort z);
+void gl1_3_glRasterPos3iv(void *_glfuncs, const GLint* v);
+void gl1_3_glRasterPos3i(void *_glfuncs, GLint x, GLint y, GLint z);
+void gl1_3_glRasterPos3fv(void *_glfuncs, const GLfloat* v);
+void gl1_3_glRasterPos3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl1_3_glRasterPos3dv(void *_glfuncs, const GLdouble* v);
+void gl1_3_glRasterPos3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl1_3_glRasterPos2sv(void *_glfuncs, const GLshort* v);
+void gl1_3_glRasterPos2s(void *_glfuncs, GLshort x, GLshort y);
+void gl1_3_glRasterPos2iv(void *_glfuncs, const GLint* v);
+void gl1_3_glRasterPos2i(void *_glfuncs, GLint x, GLint y);
+void gl1_3_glRasterPos2fv(void *_glfuncs, const GLfloat* v);
+void gl1_3_glRasterPos2f(void *_glfuncs, GLfloat x, GLfloat y);
+void gl1_3_glRasterPos2dv(void *_glfuncs, const GLdouble* v);
+void gl1_3_glRasterPos2d(void *_glfuncs, GLdouble x, GLdouble y);
+void gl1_3_glNormal3sv(void *_glfuncs, const GLshort* v);
+void gl1_3_glNormal3s(void *_glfuncs, GLshort nx, GLshort ny, GLshort nz);
+void gl1_3_glNormal3iv(void *_glfuncs, const GLint* v);
+void gl1_3_glNormal3i(void *_glfuncs, GLint nx, GLint ny, GLint nz);
+void gl1_3_glNormal3fv(void *_glfuncs, const GLfloat* v);
+void gl1_3_glNormal3f(void *_glfuncs, GLfloat nx, GLfloat ny, GLfloat nz);
+void gl1_3_glNormal3dv(void *_glfuncs, const GLdouble* v);
+void gl1_3_glNormal3d(void *_glfuncs, GLdouble nx, GLdouble ny, GLdouble nz);
+void gl1_3_glNormal3bv(void *_glfuncs, const GLbyte* v);
+void gl1_3_glNormal3b(void *_glfuncs, GLbyte nx, GLbyte ny, GLbyte nz);
+void gl1_3_glIndexsv(void *_glfuncs, const GLshort* c);
+void gl1_3_glIndexs(void *_glfuncs, GLshort c);
+void gl1_3_glIndexiv(void *_glfuncs, const GLint* c);
+void gl1_3_glIndexi(void *_glfuncs, GLint c);
+void gl1_3_glIndexfv(void *_glfuncs, const GLfloat* c);
+void gl1_3_glIndexf(void *_glfuncs, GLfloat c);
+void gl1_3_glIndexdv(void *_glfuncs, const GLdouble* c);
+void gl1_3_glIndexd(void *_glfuncs, GLdouble c);
+void gl1_3_glEnd(void *_glfuncs);
+void gl1_3_glEdgeFlagv(void *_glfuncs, const GLboolean* flag);
+void gl1_3_glEdgeFlag(void *_glfuncs, GLboolean flag);
+void gl1_3_glColor4usv(void *_glfuncs, const GLushort* v);
+void gl1_3_glColor4us(void *_glfuncs, GLushort red, GLushort green, GLushort blue, GLushort alpha);
+void gl1_3_glColor4uiv(void *_glfuncs, const GLuint* v);
+void gl1_3_glColor4ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue, GLuint alpha);
+void gl1_3_glColor4ubv(void *_glfuncs, const GLubyte* v);
+void gl1_3_glColor4ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha);
+void gl1_3_glColor4sv(void *_glfuncs, const GLshort* v);
+void gl1_3_glColor4s(void *_glfuncs, GLshort red, GLshort green, GLshort blue, GLshort alpha);
+void gl1_3_glColor4iv(void *_glfuncs, const GLint* v);
+void gl1_3_glColor4i(void *_glfuncs, GLint red, GLint green, GLint blue, GLint alpha);
+void gl1_3_glColor4fv(void *_glfuncs, const GLfloat* v);
+void gl1_3_glColor4f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl1_3_glColor4dv(void *_glfuncs, const GLdouble* v);
+void gl1_3_glColor4d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha);
+void gl1_3_glColor4bv(void *_glfuncs, const GLbyte* v);
+void gl1_3_glColor4b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha);
+void gl1_3_glColor3usv(void *_glfuncs, const GLushort* v);
+void gl1_3_glColor3us(void *_glfuncs, GLushort red, GLushort green, GLushort blue);
+void gl1_3_glColor3uiv(void *_glfuncs, const GLuint* v);
+void gl1_3_glColor3ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue);
+void gl1_3_glColor3ubv(void *_glfuncs, const GLubyte* v);
+void gl1_3_glColor3ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue);
+void gl1_3_glColor3sv(void *_glfuncs, const GLshort* v);
+void gl1_3_glColor3s(void *_glfuncs, GLshort red, GLshort green, GLshort blue);
+void gl1_3_glColor3iv(void *_glfuncs, const GLint* v);
+void gl1_3_glColor3i(void *_glfuncs, GLint red, GLint green, GLint blue);
+void gl1_3_glColor3fv(void *_glfuncs, const GLfloat* v);
+void gl1_3_glColor3f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue);
+void gl1_3_glColor3dv(void *_glfuncs, const GLdouble* v);
+void gl1_3_glColor3d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue);
+void gl1_3_glColor3bv(void *_glfuncs, const GLbyte* v);
+void gl1_3_glColor3b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue);
+void gl1_3_glBitmap(void *_glfuncs, GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte* bitmap);
+void gl1_3_glBegin(void *_glfuncs, GLenum mode);
+void gl1_3_glListBase(void *_glfuncs, GLuint base);
+GLuint gl1_3_glGenLists(void *_glfuncs, GLsizei range_);
+void gl1_3_glDeleteLists(void *_glfuncs, GLuint list, GLsizei range_);
+void gl1_3_glCallLists(void *_glfuncs, GLsizei n, GLenum gltype, const GLvoid* lists);
+void gl1_3_glCallList(void *_glfuncs, GLuint list);
+void gl1_3_glEndList(void *_glfuncs);
+void gl1_3_glNewList(void *_glfuncs, GLuint list, GLenum mode);
+void gl1_3_glPushClientAttrib(void *_glfuncs, GLbitfield mask);
+void gl1_3_glPopClientAttrib(void *_glfuncs);
+void gl1_3_glPrioritizeTextures(void *_glfuncs, GLsizei n, const GLuint* textures, const GLfloat* priorities);
+GLboolean gl1_3_glAreTexturesResident(void *_glfuncs, GLsizei n, const GLuint* textures, GLboolean* residences);
+void gl1_3_glVertexPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl1_3_glTexCoordPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl1_3_glNormalPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl1_3_glInterleavedArrays(void *_glfuncs, GLenum format, GLsizei stride, const GLvoid* pointer);
+void gl1_3_glIndexPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl1_3_glEnableClientState(void *_glfuncs, GLenum array);
+void gl1_3_glEdgeFlagPointer(void *_glfuncs, GLsizei stride, const GLvoid* pointer);
+void gl1_3_glDisableClientState(void *_glfuncs, GLenum array);
+void gl1_3_glColorPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl1_3_glArrayElement(void *_glfuncs, GLint i);
+void gl1_3_glResetMinmax(void *_glfuncs, GLenum target);
+void gl1_3_glResetHistogram(void *_glfuncs, GLenum target);
+void gl1_3_glMinmax(void *_glfuncs, GLenum target, GLenum internalFormat, GLboolean sink);
+void gl1_3_glHistogram(void *_glfuncs, GLenum target, GLsizei width, GLenum internalFormat, GLboolean sink);
+void gl1_3_glGetMinmaxParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl1_3_glGetMinmaxParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl1_3_glGetMinmax(void *_glfuncs, GLenum target, GLboolean reset, GLenum format, GLenum gltype, GLvoid* values);
+void gl1_3_glGetHistogramParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl1_3_glGetHistogramParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl1_3_glGetHistogram(void *_glfuncs, GLenum target, GLboolean reset, GLenum format, GLenum gltype, GLvoid* values);
+void gl1_3_glSeparableFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* row, const GLvoid* column);
+void gl1_3_glGetSeparableFilter(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* row, GLvoid* column, GLvoid* span);
+void gl1_3_glGetConvolutionParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl1_3_glGetConvolutionParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl1_3_glGetConvolutionFilter(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* image);
+void gl1_3_glCopyConvolutionFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl1_3_glCopyConvolutionFilter1D(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width);
+void gl1_3_glConvolutionParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl1_3_glConvolutionParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint params);
+void gl1_3_glConvolutionParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl1_3_glConvolutionParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat params);
+void gl1_3_glConvolutionFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* image);
+void gl1_3_glConvolutionFilter1D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLenum format, GLenum gltype, const GLvoid* image);
+void gl1_3_glCopyColorSubTable(void *_glfuncs, GLenum target, GLsizei start, GLint x, GLint y, GLsizei width);
+void gl1_3_glColorSubTable(void *_glfuncs, GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum gltype, const GLvoid* data);
+void gl1_3_glGetColorTableParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl1_3_glGetColorTableParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl1_3_glGetColorTable(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* table);
+void gl1_3_glCopyColorTable(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width);
+void gl1_3_glColorTableParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl1_3_glColorTableParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl1_3_glColorTable(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLenum format, GLenum gltype, const GLvoid* table);
+void gl1_3_glMultTransposeMatrixd(void *_glfuncs, const GLdouble* m);
+void gl1_3_glMultTransposeMatrixf(void *_glfuncs, const GLfloat* m);
+void gl1_3_glLoadTransposeMatrixd(void *_glfuncs, const GLdouble* m);
+void gl1_3_glLoadTransposeMatrixf(void *_glfuncs, const GLfloat* m);
+void gl1_3_glMultiTexCoord4sv(void *_glfuncs, GLenum target, const GLshort* v);
+void gl1_3_glMultiTexCoord4s(void *_glfuncs, GLenum target, GLshort s, GLshort t, GLshort r, GLshort q);
+void gl1_3_glMultiTexCoord4iv(void *_glfuncs, GLenum target, const GLint* v);
+void gl1_3_glMultiTexCoord4i(void *_glfuncs, GLenum target, GLint s, GLint t, GLint r, GLint q);
+void gl1_3_glMultiTexCoord4fv(void *_glfuncs, GLenum target, const GLfloat* v);
+void gl1_3_glMultiTexCoord4f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+void gl1_3_glMultiTexCoord4dv(void *_glfuncs, GLenum target, const GLdouble* v);
+void gl1_3_glMultiTexCoord4d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+void gl1_3_glMultiTexCoord3sv(void *_glfuncs, GLenum target, const GLshort* v);
+void gl1_3_glMultiTexCoord3s(void *_glfuncs, GLenum target, GLshort s, GLshort t, GLshort r);
+void gl1_3_glMultiTexCoord3iv(void *_glfuncs, GLenum target, const GLint* v);
+void gl1_3_glMultiTexCoord3i(void *_glfuncs, GLenum target, GLint s, GLint t, GLint r);
+void gl1_3_glMultiTexCoord3fv(void *_glfuncs, GLenum target, const GLfloat* v);
+void gl1_3_glMultiTexCoord3f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t, GLfloat r);
+void gl1_3_glMultiTexCoord3dv(void *_glfuncs, GLenum target, const GLdouble* v);
+void gl1_3_glMultiTexCoord3d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t, GLdouble r);
+void gl1_3_glMultiTexCoord2sv(void *_glfuncs, GLenum target, const GLshort* v);
+void gl1_3_glMultiTexCoord2s(void *_glfuncs, GLenum target, GLshort s, GLshort t);
+void gl1_3_glMultiTexCoord2iv(void *_glfuncs, GLenum target, const GLint* v);
+void gl1_3_glMultiTexCoord2i(void *_glfuncs, GLenum target, GLint s, GLint t);
+void gl1_3_glMultiTexCoord2fv(void *_glfuncs, GLenum target, const GLfloat* v);
+void gl1_3_glMultiTexCoord2f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t);
+void gl1_3_glMultiTexCoord2dv(void *_glfuncs, GLenum target, const GLdouble* v);
+void gl1_3_glMultiTexCoord2d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t);
+void gl1_3_glMultiTexCoord1sv(void *_glfuncs, GLenum target, const GLshort* v);
+void gl1_3_glMultiTexCoord1s(void *_glfuncs, GLenum target, GLshort s);
+void gl1_3_glMultiTexCoord1iv(void *_glfuncs, GLenum target, const GLint* v);
+void gl1_3_glMultiTexCoord1i(void *_glfuncs, GLenum target, GLint s);
+void gl1_3_glMultiTexCoord1fv(void *_glfuncs, GLenum target, const GLfloat* v);
+void gl1_3_glMultiTexCoord1f(void *_glfuncs, GLenum target, GLfloat s);
+void gl1_3_glMultiTexCoord1dv(void *_glfuncs, GLenum target, const GLdouble* v);
+void gl1_3_glMultiTexCoord1d(void *_glfuncs, GLenum target, GLdouble s);
+void gl1_3_glClientActiveTexture(void *_glfuncs, GLenum texture);
+
+
+#ifdef __cplusplus
+} // extern "C"
+#endif
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/1.3/gl.go b/Godeps/_workspace/src/github.com/obscuren/qml/gl/1.3/gl.go
new file mode 100644
index 000000000..6df8965a3
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/1.3/gl.go
@@ -0,0 +1,3571 @@
+// ** file automatically generated by glgen -- do not edit manually **
+
+package GL
+
+// #cgo CXXFLAGS: -std=c++0x -pedantic-errors -Wall -fno-strict-aliasing
+// #cgo LDFLAGS: -lstdc++
+// #cgo pkg-config: Qt5Core Qt5OpenGL
+//
+// #include "funcs.h"
+//
+// void free(void*);
+//
+import "C"
+
+import (
+ "fmt"
+ "reflect"
+ "unsafe"
+
+ "gopkg.in/qml.v1/gl/glbase"
+)
+
+// API returns a value that offers methods matching the OpenGL version 1.3 API.
+//
+// The returned API must not be used after the provided OpenGL context becomes invalid.
+func API(context glbase.Contexter) *GL {
+ gl := &GL{}
+ gl.funcs = C.gl1_3_funcs()
+ if gl.funcs == nil {
+ panic(fmt.Errorf("OpenGL version 1.3 is not available"))
+ }
+ return gl
+}
+
+// GL implements the OpenGL version 1.3 API. Values of this
+// type must be created via the API function, and it must not be used after
+// the associated OpenGL context becomes invalid.
+type GL struct {
+ funcs unsafe.Pointer
+}
+
+const (
+ FALSE = 0
+ TRUE = 1
+ NONE = 0
+
+ BYTE = 0x1400
+ UNSIGNED_BYTE = 0x1401
+ SHORT = 0x1402
+ UNSIGNED_SHORT = 0x1403
+ INT = 0x1404
+ UNSIGNED_INT = 0x1405
+ FLOAT = 0x1406
+ N2_BYTES = 0x1407
+ N3_BYTES = 0x1408
+ N4_BYTES = 0x1409
+ DOUBLE = 0x140A
+
+ ACCUM = 0x0100
+ LOAD = 0x0101
+ RETURN = 0x0102
+ MULT = 0x0103
+ ADD = 0x0104
+
+ ACCUM_BUFFER_BIT = 0x00000200
+ ALL_ATTRIB_BITS = 0xFFFFFFFF
+ COLOR_BUFFER_BIT = 0x00004000
+ CURRENT_BIT = 0x00000001
+ DEPTH_BUFFER_BIT = 0x00000100
+ ENABLE_BIT = 0x00002000
+ EVAL_BIT = 0x00010000
+ FOG_BIT = 0x00000080
+ HINT_BIT = 0x00008000
+ LIGHTING_BIT = 0x00000040
+ LINE_BIT = 0x00000004
+ LIST_BIT = 0x00020000
+ MULTISAMPLE_BIT = 0x20000000
+ PIXEL_MODE_BIT = 0x00000020
+ POINT_BIT = 0x00000002
+ POLYGON_BIT = 0x00000008
+ POLYGON_STIPPLE_BIT = 0x00000010
+ SCISSOR_BIT = 0x00080000
+ STENCIL_BUFFER_BIT = 0x00000400
+ TEXTURE_BIT = 0x00040000
+ TRANSFORM_BIT = 0x00001000
+ VIEWPORT_BIT = 0x00000800
+
+ ALWAYS = 0x0207
+ EQUAL = 0x0202
+ GEQUAL = 0x0206
+ GREATER = 0x0204
+ LEQUAL = 0x0203
+ LESS = 0x0201
+ NEVER = 0x0200
+ NOTEQUAL = 0x0205
+
+ LOGIC_OP = 0x0BF1
+
+ DST_ALPHA = 0x0304
+ ONE = 1
+ ONE_MINUS_DST_ALPHA = 0x0305
+ ONE_MINUS_SRC_ALPHA = 0x0303
+ ONE_MINUS_SRC_COLOR = 0x0301
+ SRC_ALPHA = 0x0302
+ SRC_COLOR = 0x0300
+ ZERO = 0
+
+ DST_COLOR = 0x0306
+ ONE_MINUS_DST_COLOR = 0x0307
+ SRC_ALPHA_SATURATE = 0x0308
+
+ CLIENT_ALL_ATTRIB_BITS = 0xFFFFFFFF
+ CLIENT_PIXEL_STORE_BIT = 0x00000001
+ CLIENT_VERTEX_ARRAY_BIT = 0x00000002
+
+ CLIP_PLANE0 = 0x3000
+ CLIP_PLANE1 = 0x3001
+ CLIP_PLANE2 = 0x3002
+ CLIP_PLANE3 = 0x3003
+ CLIP_PLANE4 = 0x3004
+ CLIP_PLANE5 = 0x3005
+
+ BACK = 0x0405
+ FRONT = 0x0404
+ FRONT_AND_BACK = 0x0408
+
+ AMBIENT = 0x1200
+ AMBIENT_AND_DIFFUSE = 0x1602
+ DIFFUSE = 0x1201
+ EMISSION = 0x1600
+ SPECULAR = 0x1202
+
+ AUX0 = 0x0409
+ AUX1 = 0x040A
+ AUX2 = 0x040B
+ AUX3 = 0x040C
+ BACK_LEFT = 0x0402
+ BACK_RIGHT = 0x0403
+ FRONT_LEFT = 0x0400
+ FRONT_RIGHT = 0x0401
+ LEFT = 0x0406
+ RIGHT = 0x0407
+
+ ALPHA_TEST = 0x0BC0
+ AUTO_NORMAL = 0x0D80
+ BLEND = 0x0BE2
+ COLOR_ARRAY = 0x8076
+ COLOR_LOGIC_OP = 0x0BF2
+ COLOR_MATERIAL = 0x0B57
+ CULL_FACE = 0x0B44
+ DEPTH_TEST = 0x0B71
+ DITHER = 0x0BD0
+ EDGE_FLAG_ARRAY = 0x8079
+ FOG = 0x0B60
+ INDEX_ARRAY = 0x8077
+ INDEX_LOGIC_OP = 0x0BF1
+ LIGHT0 = 0x4000
+ LIGHT1 = 0x4001
+ LIGHT2 = 0x4002
+ LIGHT3 = 0x4003
+ LIGHT4 = 0x4004
+ LIGHT5 = 0x4005
+ LIGHT6 = 0x4006
+ LIGHT7 = 0x4007
+ LIGHTING = 0x0B50
+ LINE_SMOOTH = 0x0B20
+ LINE_STIPPLE = 0x0B24
+ MAP1_COLOR_4 = 0x0D90
+ MAP1_INDEX = 0x0D91
+ MAP1_NORMAL = 0x0D92
+ MAP1_TEXTURE_COORD_1 = 0x0D93
+ MAP1_TEXTURE_COORD_2 = 0x0D94
+ MAP1_TEXTURE_COORD_3 = 0x0D95
+ MAP1_TEXTURE_COORD_4 = 0x0D96
+ MAP1_VERTEX_3 = 0x0D97
+ MAP1_VERTEX_4 = 0x0D98
+ MAP2_COLOR_4 = 0x0DB0
+ MAP2_INDEX = 0x0DB1
+ MAP2_NORMAL = 0x0DB2
+ MAP2_TEXTURE_COORD_1 = 0x0DB3
+ MAP2_TEXTURE_COORD_2 = 0x0DB4
+ MAP2_TEXTURE_COORD_3 = 0x0DB5
+ MAP2_TEXTURE_COORD_4 = 0x0DB6
+ MAP2_VERTEX_3 = 0x0DB7
+ MAP2_VERTEX_4 = 0x0DB8
+ NORMALIZE = 0x0BA1
+ NORMAL_ARRAY = 0x8075
+ POINT_SMOOTH = 0x0B10
+ POLYGON_OFFSET_FILL = 0x8037
+ POLYGON_OFFSET_LINE = 0x2A02
+ POLYGON_OFFSET_POINT = 0x2A01
+ POLYGON_SMOOTH = 0x0B41
+ POLYGON_STIPPLE = 0x0B42
+ SCISSOR_TEST = 0x0C11
+ STENCIL_TEST = 0x0B90
+ TEXTURE_1D = 0x0DE0
+ TEXTURE_2D = 0x0DE1
+ TEXTURE_COORD_ARRAY = 0x8078
+ TEXTURE_GEN_Q = 0x0C63
+ TEXTURE_GEN_R = 0x0C62
+ TEXTURE_GEN_S = 0x0C60
+ TEXTURE_GEN_T = 0x0C61
+ VERTEX_ARRAY = 0x8074
+
+ INVALID_ENUM = 0x0500
+ INVALID_OPERATION = 0x0502
+ INVALID_VALUE = 0x0501
+ NO_ERROR = 0
+ OUT_OF_MEMORY = 0x0505
+ STACK_OVERFLOW = 0x0503
+ STACK_UNDERFLOW = 0x0504
+
+ N2D = 0x0600
+ N3D = 0x0601
+ N3D_COLOR = 0x0602
+ N3D_COLOR_TEXTURE = 0x0603
+ N4D_COLOR_TEXTURE = 0x0604
+
+ BITMAP_TOKEN = 0x0704
+ COPY_PIXEL_TOKEN = 0x0706
+ DRAW_PIXEL_TOKEN = 0x0705
+ LINE_RESET_TOKEN = 0x0707
+ LINE_TOKEN = 0x0702
+ PASS_THROUGH_TOKEN = 0x0700
+ POINT_TOKEN = 0x0701
+ POLYGON_TOKEN = 0x0703
+
+ EXP = 0x0800
+ EXP2 = 0x0801
+ LINEAR = 0x2601
+
+ FOG_COLOR = 0x0B66
+ FOG_DENSITY = 0x0B62
+ FOG_END = 0x0B64
+ FOG_INDEX = 0x0B61
+ FOG_MODE = 0x0B65
+ FOG_START = 0x0B63
+
+ CCW = 0x0901
+ CW = 0x0900
+
+ COEFF = 0x0A00
+ DOMAIN = 0x0A02
+ ORDER = 0x0A01
+
+ PIXEL_MAP_A_TO_A = 0x0C79
+ PIXEL_MAP_B_TO_B = 0x0C78
+ PIXEL_MAP_G_TO_G = 0x0C77
+ PIXEL_MAP_I_TO_A = 0x0C75
+ PIXEL_MAP_I_TO_B = 0x0C74
+ PIXEL_MAP_I_TO_G = 0x0C73
+ PIXEL_MAP_I_TO_I = 0x0C70
+ PIXEL_MAP_I_TO_R = 0x0C72
+ PIXEL_MAP_R_TO_R = 0x0C76
+ PIXEL_MAP_S_TO_S = 0x0C71
+
+ ACCUM_ALPHA_BITS = 0x0D5B
+ ACCUM_BLUE_BITS = 0x0D5A
+ ACCUM_CLEAR_VALUE = 0x0B80
+ ACCUM_GREEN_BITS = 0x0D59
+ ACCUM_RED_BITS = 0x0D58
+ ALIASED_LINE_WIDTH_RANGE = 0x846E
+ ALIASED_POINT_SIZE_RANGE = 0x846D
+ ALPHA_BIAS = 0x0D1D
+ ALPHA_BITS = 0x0D55
+ ALPHA_SCALE = 0x0D1C
+ ALPHA_TEST_FUNC = 0x0BC1
+ ALPHA_TEST_REF = 0x0BC2
+ ATTRIB_STACK_DEPTH = 0x0BB0
+ AUX_BUFFERS = 0x0C00
+ BLEND_DST = 0x0BE0
+ BLEND_SRC = 0x0BE1
+ BLUE_BIAS = 0x0D1B
+ BLUE_BITS = 0x0D54
+ BLUE_SCALE = 0x0D1A
+ CLIENT_ATTRIB_STACK_DEPTH = 0x0BB1
+ COLOR_ARRAY_SIZE = 0x8081
+ COLOR_ARRAY_STRIDE = 0x8083
+ COLOR_ARRAY_TYPE = 0x8082
+ COLOR_CLEAR_VALUE = 0x0C22
+ COLOR_MATERIAL_FACE = 0x0B55
+ COLOR_MATERIAL_PARAMETER = 0x0B56
+ COLOR_WRITEMASK = 0x0C23
+ CULL_FACE_MODE = 0x0B45
+ CURRENT_COLOR = 0x0B00
+ CURRENT_INDEX = 0x0B01
+ CURRENT_NORMAL = 0x0B02
+ CURRENT_RASTER_COLOR = 0x0B04
+ CURRENT_RASTER_DISTANCE = 0x0B09
+ CURRENT_RASTER_INDEX = 0x0B05
+ CURRENT_RASTER_POSITION = 0x0B07
+ CURRENT_RASTER_POSITION_VALID = 0x0B08
+ CURRENT_RASTER_TEXTURE_COORDS = 0x0B06
+ CURRENT_TEXTURE_COORDS = 0x0B03
+ DEPTH_BIAS = 0x0D1F
+ DEPTH_BITS = 0x0D56
+ DEPTH_CLEAR_VALUE = 0x0B73
+ DEPTH_FUNC = 0x0B74
+ DEPTH_RANGE = 0x0B70
+ DEPTH_SCALE = 0x0D1E
+ DEPTH_WRITEMASK = 0x0B72
+ DOUBLEBUFFER = 0x0C32
+ DRAW_BUFFER = 0x0C01
+ EDGE_FLAG = 0x0B43
+ EDGE_FLAG_ARRAY_STRIDE = 0x808C
+ FEEDBACK_BUFFER_SIZE = 0x0DF1
+ FEEDBACK_BUFFER_TYPE = 0x0DF2
+ FOG_HINT = 0x0C54
+ FRONT_FACE = 0x0B46
+ GREEN_BIAS = 0x0D19
+ GREEN_BITS = 0x0D53
+ GREEN_SCALE = 0x0D18
+ INDEX_ARRAY_STRIDE = 0x8086
+ INDEX_ARRAY_TYPE = 0x8085
+ INDEX_BITS = 0x0D51
+ INDEX_CLEAR_VALUE = 0x0C20
+ INDEX_MODE = 0x0C30
+ INDEX_OFFSET = 0x0D13
+ INDEX_SHIFT = 0x0D12
+ INDEX_WRITEMASK = 0x0C21
+ LIGHT_MODEL_AMBIENT = 0x0B53
+ LIGHT_MODEL_COLOR_CONTROL = 0x81F8
+ LIGHT_MODEL_LOCAL_VIEWER = 0x0B51
+ LIGHT_MODEL_TWO_SIDE = 0x0B52
+ LINE_SMOOTH_HINT = 0x0C52
+ LINE_STIPPLE_PATTERN = 0x0B25
+ LINE_STIPPLE_REPEAT = 0x0B26
+ LINE_WIDTH = 0x0B21
+ LINE_WIDTH_GRANULARITY = 0x0B23
+ LINE_WIDTH_RANGE = 0x0B22
+ LIST_BASE = 0x0B32
+ LIST_INDEX = 0x0B33
+ LIST_MODE = 0x0B30
+ LOGIC_OP_MODE = 0x0BF0
+ MAP1_GRID_DOMAIN = 0x0DD0
+ MAP1_GRID_SEGMENTS = 0x0DD1
+ MAP2_GRID_DOMAIN = 0x0DD2
+ MAP2_GRID_SEGMENTS = 0x0DD3
+ MAP_COLOR = 0x0D10
+ MAP_STENCIL = 0x0D11
+ MATRIX_MODE = 0x0BA0
+ MAX_ATTRIB_STACK_DEPTH = 0x0D35
+ MAX_CLIENT_ATTRIB_STACK_DEPTH = 0x0D3B
+ MAX_CLIP_PLANES = 0x0D32
+ MAX_EVAL_ORDER = 0x0D30
+ MAX_LIGHTS = 0x0D31
+ MAX_LIST_NESTING = 0x0B31
+ MAX_MODELVIEW_STACK_DEPTH = 0x0D36
+ MAX_NAME_STACK_DEPTH = 0x0D37
+ MAX_PIXEL_MAP_TABLE = 0x0D34
+ MAX_PROJECTION_STACK_DEPTH = 0x0D38
+ MAX_TEXTURE_SIZE = 0x0D33
+ MAX_TEXTURE_STACK_DEPTH = 0x0D39
+ MAX_VIEWPORT_DIMS = 0x0D3A
+ MODELVIEW_MATRIX = 0x0BA6
+ MODELVIEW_STACK_DEPTH = 0x0BA3
+ NAME_STACK_DEPTH = 0x0D70
+ NORMAL_ARRAY_STRIDE = 0x807F
+ NORMAL_ARRAY_TYPE = 0x807E
+ PACK_ALIGNMENT = 0x0D05
+ PACK_LSB_FIRST = 0x0D01
+ PACK_ROW_LENGTH = 0x0D02
+ PACK_SKIP_PIXELS = 0x0D04
+ PACK_SKIP_ROWS = 0x0D03
+ PACK_SWAP_BYTES = 0x0D00
+ PERSPECTIVE_CORRECTION_HINT = 0x0C50
+ PIXEL_MAP_A_TO_A_SIZE = 0x0CB9
+ PIXEL_MAP_B_TO_B_SIZE = 0x0CB8
+ PIXEL_MAP_G_TO_G_SIZE = 0x0CB7
+ PIXEL_MAP_I_TO_A_SIZE = 0x0CB5
+ PIXEL_MAP_I_TO_B_SIZE = 0x0CB4
+ PIXEL_MAP_I_TO_G_SIZE = 0x0CB3
+ PIXEL_MAP_I_TO_I_SIZE = 0x0CB0
+ PIXEL_MAP_I_TO_R_SIZE = 0x0CB2
+ PIXEL_MAP_R_TO_R_SIZE = 0x0CB6
+ PIXEL_MAP_S_TO_S_SIZE = 0x0CB1
+ POINT_SIZE = 0x0B11
+ POINT_SIZE_GRANULARITY = 0x0B13
+ POINT_SIZE_RANGE = 0x0B12
+ POINT_SMOOTH_HINT = 0x0C51
+ POLYGON_MODE = 0x0B40
+ POLYGON_OFFSET_FACTOR = 0x8038
+ POLYGON_OFFSET_UNITS = 0x2A00
+ POLYGON_SMOOTH_HINT = 0x0C53
+ PROJECTION_MATRIX = 0x0BA7
+ PROJECTION_STACK_DEPTH = 0x0BA4
+ READ_BUFFER = 0x0C02
+ RED_BIAS = 0x0D15
+ RED_BITS = 0x0D52
+ RED_SCALE = 0x0D14
+ RENDER_MODE = 0x0C40
+ RGBA_MODE = 0x0C31
+ SCISSOR_BOX = 0x0C10
+ SELECTION_BUFFER_SIZE = 0x0DF4
+ SHADE_MODEL = 0x0B54
+ SMOOTH_LINE_WIDTH_GRANULARITY = 0x0B23
+ SMOOTH_LINE_WIDTH_RANGE = 0x0B22
+ SMOOTH_POINT_SIZE_GRANULARITY = 0x0B13
+ SMOOTH_POINT_SIZE_RANGE = 0x0B12
+ STENCIL_BITS = 0x0D57
+ STENCIL_CLEAR_VALUE = 0x0B91
+ STENCIL_FAIL = 0x0B94
+ STENCIL_FUNC = 0x0B92
+ STENCIL_PASS_DEPTH_FAIL = 0x0B95
+ STENCIL_PASS_DEPTH_PASS = 0x0B96
+ STENCIL_REF = 0x0B97
+ STENCIL_VALUE_MASK = 0x0B93
+ STENCIL_WRITEMASK = 0x0B98
+ STEREO = 0x0C33
+ SUBPIXEL_BITS = 0x0D50
+ TEXTURE_BINDING_1D = 0x8068
+ TEXTURE_BINDING_2D = 0x8069
+ TEXTURE_BINDING_3D = 0x806A
+ TEXTURE_COORD_ARRAY_SIZE = 0x8088
+ TEXTURE_COORD_ARRAY_STRIDE = 0x808A
+ TEXTURE_COORD_ARRAY_TYPE = 0x8089
+ TEXTURE_MATRIX = 0x0BA8
+ TEXTURE_STACK_DEPTH = 0x0BA5
+ UNPACK_ALIGNMENT = 0x0CF5
+ UNPACK_LSB_FIRST = 0x0CF1
+ UNPACK_ROW_LENGTH = 0x0CF2
+ UNPACK_SKIP_PIXELS = 0x0CF4
+ UNPACK_SKIP_ROWS = 0x0CF3
+ UNPACK_SWAP_BYTES = 0x0CF0
+ VERTEX_ARRAY_SIZE = 0x807A
+ VERTEX_ARRAY_STRIDE = 0x807C
+ VERTEX_ARRAY_TYPE = 0x807B
+ VIEWPORT = 0x0BA2
+ ZOOM_X = 0x0D16
+ ZOOM_Y = 0x0D17
+
+ COLOR_ARRAY_POINTER = 0x8090
+ EDGE_FLAG_ARRAY_POINTER = 0x8093
+ FEEDBACK_BUFFER_POINTER = 0x0DF0
+ INDEX_ARRAY_POINTER = 0x8091
+ NORMAL_ARRAY_POINTER = 0x808F
+ SELECTION_BUFFER_POINTER = 0x0DF3
+ TEXTURE_COORD_ARRAY_POINTER = 0x8092
+ VERTEX_ARRAY_POINTER = 0x808E
+
+ TEXTURE_ALPHA_SIZE = 0x805F
+ TEXTURE_BLUE_SIZE = 0x805E
+ TEXTURE_BORDER = 0x1005
+ TEXTURE_BORDER_COLOR = 0x1004
+ TEXTURE_COMPONENTS = 0x1003
+ TEXTURE_GREEN_SIZE = 0x805D
+ TEXTURE_HEIGHT = 0x1001
+ TEXTURE_INTENSITY_SIZE = 0x8061
+ TEXTURE_INTERNAL_FORMAT = 0x1003
+ TEXTURE_LUMINANCE_SIZE = 0x8060
+ TEXTURE_MAG_FILTER = 0x2800
+ TEXTURE_MIN_FILTER = 0x2801
+ TEXTURE_PRIORITY = 0x8066
+ TEXTURE_RED_SIZE = 0x805C
+ TEXTURE_RESIDENT = 0x8067
+ TEXTURE_WIDTH = 0x1000
+ TEXTURE_WRAP_S = 0x2802
+ TEXTURE_WRAP_T = 0x2803
+
+ DONT_CARE = 0x1100
+ FASTEST = 0x1101
+ NICEST = 0x1102
+
+ TEXTURE_COMPRESSION_HINT = 0x84EF
+
+ C3F_V3F = 0x2A24
+ C4F_N3F_V3F = 0x2A26
+ C4UB_V2F = 0x2A22
+ C4UB_V3F = 0x2A23
+ N3F_V3F = 0x2A25
+ T2F_C3F_V3F = 0x2A2A
+ T2F_C4F_N3F_V3F = 0x2A2C
+ T2F_C4UB_V3F = 0x2A29
+ T2F_N3F_V3F = 0x2A2B
+ T2F_V3F = 0x2A27
+ T4F_C4F_N3F_V4F = 0x2A2D
+ T4F_V4F = 0x2A28
+ V2F = 0x2A20
+ V3F = 0x2A21
+
+ MODULATE = 0x2100
+ REPLACE = 0x1E01
+
+ SEPARATE_SPECULAR_COLOR = 0x81FA
+ SINGLE_COLOR = 0x81F9
+
+ CONSTANT_ATTENUATION = 0x1207
+ LINEAR_ATTENUATION = 0x1208
+ POSITION = 0x1203
+ QUADRATIC_ATTENUATION = 0x1209
+ SPOT_CUTOFF = 0x1206
+ SPOT_DIRECTION = 0x1204
+ SPOT_EXPONENT = 0x1205
+
+ COMPILE = 0x1300
+ COMPILE_AND_EXECUTE = 0x1301
+
+ AND = 0x1501
+ AND_INVERTED = 0x1504
+ AND_REVERSE = 0x1502
+ CLEAR = 0x1500
+ COPY = 0x1503
+ COPY_INVERTED = 0x150C
+ EQUIV = 0x1509
+ INVERT = 0x150A
+ NAND = 0x150E
+ NOOP = 0x1505
+ NOR = 0x1508
+ OR = 0x1507
+ OR_INVERTED = 0x150D
+ OR_REVERSE = 0x150B
+ SET = 0x150F
+ XOR = 0x1506
+
+ COLOR_INDEXES = 0x1603
+ SHININESS = 0x1601
+
+ MODELVIEW = 0x1700
+ PROJECTION = 0x1701
+ TEXTURE = 0x1702
+
+ LINE = 0x1B01
+ POINT = 0x1B00
+
+ FILL = 0x1B02
+
+ COLOR = 0x1800
+ DEPTH = 0x1801
+ STENCIL = 0x1802
+
+ ALPHA = 0x1906
+ BLUE = 0x1905
+ COLOR_INDEX = 0x1900
+ DEPTH_COMPONENT = 0x1902
+ GREEN = 0x1904
+ LUMINANCE = 0x1909
+ LUMINANCE_ALPHA = 0x190A
+ RED = 0x1903
+ RGB = 0x1907
+ RGBA = 0x1908
+ STENCIL_INDEX = 0x1901
+
+ ALPHA12 = 0x803D
+ ALPHA16 = 0x803E
+ ALPHA4 = 0x803B
+ ALPHA8 = 0x803C
+ INTENSITY = 0x8049
+ INTENSITY12 = 0x804C
+ INTENSITY16 = 0x804D
+ INTENSITY4 = 0x804A
+ INTENSITY8 = 0x804B
+ LUMINANCE12 = 0x8041
+ LUMINANCE12_ALPHA12 = 0x8047
+ LUMINANCE12_ALPHA4 = 0x8046
+ LUMINANCE16 = 0x8042
+ LUMINANCE16_ALPHA16 = 0x8048
+ LUMINANCE4 = 0x803F
+ LUMINANCE4_ALPHA4 = 0x8043
+ LUMINANCE6_ALPHA2 = 0x8044
+ LUMINANCE8 = 0x8040
+ LUMINANCE8_ALPHA8 = 0x8045
+ R3_G3_B2 = 0x2A10
+ RGB10 = 0x8052
+ RGB10_A2 = 0x8059
+ RGB12 = 0x8053
+ RGB16 = 0x8054
+ RGB4 = 0x804F
+ RGB5 = 0x8050
+ RGB5_A1 = 0x8057
+ RGB8 = 0x8051
+ RGBA12 = 0x805A
+ RGBA16 = 0x805B
+ RGBA2 = 0x8055
+ RGBA4 = 0x8056
+ RGBA8 = 0x8058
+
+ PACK_IMAGE_HEIGHT = 0x806C
+ PACK_SKIP_IMAGES = 0x806B
+ UNPACK_IMAGE_HEIGHT = 0x806E
+ UNPACK_SKIP_IMAGES = 0x806D
+
+ BITMAP = 0x1A00
+ UNSIGNED_BYTE_3_3_2 = 0x8032
+ UNSIGNED_INT_10_10_10_2 = 0x8036
+ UNSIGNED_INT_8_8_8_8 = 0x8035
+ UNSIGNED_SHORT_4_4_4_4 = 0x8033
+ UNSIGNED_SHORT_5_5_5_1 = 0x8034
+
+ LINES = 0x0001
+ LINE_LOOP = 0x0002
+ LINE_STRIP = 0x0003
+ POINTS = 0x0000
+ POLYGON = 0x0009
+ QUADS = 0x0007
+ QUAD_STRIP = 0x0008
+ TRIANGLES = 0x0004
+ TRIANGLE_FAN = 0x0006
+ TRIANGLE_STRIP = 0x0005
+
+ FEEDBACK = 0x1C01
+ RENDER = 0x1C00
+ SELECT = 0x1C02
+
+ FLAT = 0x1D00
+ SMOOTH = 0x1D01
+
+ DECR = 0x1E03
+ INCR = 0x1E02
+ KEEP = 0x1E00
+
+ EXTENSIONS = 0x1F03
+ RENDERER = 0x1F01
+ VENDOR = 0x1F00
+ VERSION = 0x1F02
+
+ S = 0x2000
+ T = 0x2001
+ R = 0x2002
+ Q = 0x2003
+
+ DECAL = 0x2101
+
+ TEXTURE_ENV_COLOR = 0x2201
+ TEXTURE_ENV_MODE = 0x2200
+
+ TEXTURE_ENV = 0x2300
+
+ EYE_LINEAR = 0x2400
+ OBJECT_LINEAR = 0x2401
+ SPHERE_MAP = 0x2402
+
+ EYE_PLANE = 0x2502
+ OBJECT_PLANE = 0x2501
+ TEXTURE_GEN_MODE = 0x2500
+
+ NEAREST = 0x2600
+
+ LINEAR_MIPMAP_LINEAR = 0x2703
+ LINEAR_MIPMAP_NEAREST = 0x2701
+ NEAREST_MIPMAP_LINEAR = 0x2702
+ NEAREST_MIPMAP_NEAREST = 0x2700
+
+ TEXTURE_WRAP_R = 0x8072
+
+ PROXY_TEXTURE_1D = 0x8063
+ PROXY_TEXTURE_2D = 0x8064
+ PROXY_TEXTURE_3D = 0x8070
+ TEXTURE_3D = 0x806F
+ TEXTURE_BASE_LEVEL = 0x813C
+ TEXTURE_MAX_LEVEL = 0x813D
+ TEXTURE_MAX_LOD = 0x813B
+ TEXTURE_MIN_LOD = 0x813A
+
+ CLAMP = 0x2900
+ CLAMP_TO_BORDER = 0x812D
+ CLAMP_TO_EDGE = 0x812F
+ REPEAT = 0x2901
+
+ RESCALE_NORMAL = 0x803A
+ TEXTURE_DEPTH = 0x8071
+ MAX_3D_TEXTURE_SIZE = 0x8073
+ MULTISAMPLE = 0x809D
+ SAMPLE_ALPHA_TO_COVERAGE = 0x809E
+ SAMPLE_ALPHA_TO_ONE = 0x809F
+ SAMPLE_COVERAGE = 0x80A0
+ SAMPLE_BUFFERS = 0x80A8
+ SAMPLES = 0x80A9
+ SAMPLE_COVERAGE_VALUE = 0x80AA
+ SAMPLE_COVERAGE_INVERT = 0x80AB
+ BGR = 0x80E0
+ BGRA = 0x80E1
+ MAX_ELEMENTS_VERTICES = 0x80E8
+ MAX_ELEMENTS_INDICES = 0x80E9
+ UNSIGNED_BYTE_2_3_3_REV = 0x8362
+ UNSIGNED_SHORT_5_6_5 = 0x8363
+ UNSIGNED_SHORT_5_6_5_REV = 0x8364
+ UNSIGNED_SHORT_4_4_4_4_REV = 0x8365
+ UNSIGNED_SHORT_1_5_5_5_REV = 0x8366
+ UNSIGNED_INT_8_8_8_8_REV = 0x8367
+ UNSIGNED_INT_2_10_10_10_REV = 0x8368
+ TEXTURE0 = 0x84C0
+ TEXTURE1 = 0x84C1
+ TEXTURE2 = 0x84C2
+ TEXTURE3 = 0x84C3
+ TEXTURE4 = 0x84C4
+ TEXTURE5 = 0x84C5
+ TEXTURE6 = 0x84C6
+ TEXTURE7 = 0x84C7
+ TEXTURE8 = 0x84C8
+ TEXTURE9 = 0x84C9
+ TEXTURE10 = 0x84CA
+ TEXTURE11 = 0x84CB
+ TEXTURE12 = 0x84CC
+ TEXTURE13 = 0x84CD
+ TEXTURE14 = 0x84CE
+ TEXTURE15 = 0x84CF
+ TEXTURE16 = 0x84D0
+ TEXTURE17 = 0x84D1
+ TEXTURE18 = 0x84D2
+ TEXTURE19 = 0x84D3
+ TEXTURE20 = 0x84D4
+ TEXTURE21 = 0x84D5
+ TEXTURE22 = 0x84D6
+ TEXTURE23 = 0x84D7
+ TEXTURE24 = 0x84D8
+ TEXTURE25 = 0x84D9
+ TEXTURE26 = 0x84DA
+ TEXTURE27 = 0x84DB
+ TEXTURE28 = 0x84DC
+ TEXTURE29 = 0x84DD
+ TEXTURE30 = 0x84DE
+ TEXTURE31 = 0x84DF
+ ACTIVE_TEXTURE = 0x84E0
+ CLIENT_ACTIVE_TEXTURE = 0x84E1
+ MAX_TEXTURE_UNITS = 0x84E2
+ TRANSPOSE_MODELVIEW_MATRIX = 0x84E3
+ TRANSPOSE_PROJECTION_MATRIX = 0x84E4
+ TRANSPOSE_TEXTURE_MATRIX = 0x84E5
+ TRANSPOSE_COLOR_MATRIX = 0x84E6
+ SUBTRACT = 0x84E7
+ COMPRESSED_ALPHA = 0x84E9
+ COMPRESSED_LUMINANCE = 0x84EA
+ COMPRESSED_LUMINANCE_ALPHA = 0x84EB
+ COMPRESSED_INTENSITY = 0x84EC
+ COMPRESSED_RGB = 0x84ED
+ COMPRESSED_RGBA = 0x84EE
+ NORMAL_MAP = 0x8511
+ REFLECTION_MAP = 0x8512
+ TEXTURE_CUBE_MAP = 0x8513
+ TEXTURE_BINDING_CUBE_MAP = 0x8514
+ TEXTURE_CUBE_MAP_POSITIVE_X = 0x8515
+ TEXTURE_CUBE_MAP_NEGATIVE_X = 0x8516
+ TEXTURE_CUBE_MAP_POSITIVE_Y = 0x8517
+ TEXTURE_CUBE_MAP_NEGATIVE_Y = 0x8518
+ TEXTURE_CUBE_MAP_POSITIVE_Z = 0x8519
+ TEXTURE_CUBE_MAP_NEGATIVE_Z = 0x851A
+ PROXY_TEXTURE_CUBE_MAP = 0x851B
+ MAX_CUBE_MAP_TEXTURE_SIZE = 0x851C
+ COMBINE = 0x8570
+ COMBINE_RGB = 0x8571
+ COMBINE_ALPHA = 0x8572
+ RGB_SCALE = 0x8573
+ ADD_SIGNED = 0x8574
+ INTERPOLATE = 0x8575
+ CONSTANT = 0x8576
+ PRIMARY_COLOR = 0x8577
+ PREVIOUS = 0x8578
+ SOURCE0_RGB = 0x8580
+ SOURCE1_RGB = 0x8581
+ SOURCE2_RGB = 0x8582
+ SOURCE0_ALPHA = 0x8588
+ SOURCE1_ALPHA = 0x8589
+ SOURCE2_ALPHA = 0x858A
+ OPERAND0_RGB = 0x8590
+ OPERAND1_RGB = 0x8591
+ OPERAND2_RGB = 0x8592
+ OPERAND0_ALPHA = 0x8598
+ OPERAND1_ALPHA = 0x8599
+ OPERAND2_ALPHA = 0x859A
+ TEXTURE_COMPRESSED_IMAGE_SIZE = 0x86A0
+ TEXTURE_COMPRESSED = 0x86A1
+ NUM_COMPRESSED_TEXTURE_FORMATS = 0x86A2
+ COMPRESSED_TEXTURE_FORMATS = 0x86A3
+ DOT3_RGB = 0x86AE
+ DOT3_RGBA = 0x86AF
+)
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glViewport.xml
+func (gl *GL) Viewport(x, y, width, height int) {
+ C.gl1_3_glViewport(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// DepthRange specifies the mapping of depth values from normalized device
+// coordinates to window coordinates.
+//
+// Parameter nearVal specifies the mapping of the near clipping plane to window
+// coordinates (defaults to 0), while farVal specifies the mapping of the far
+// clipping plane to window coordinates (defaults to 1).
+//
+// After clipping and division by w, depth coordinates range from -1 to 1,
+// corresponding to the near and far clipping planes. DepthRange specifies a
+// linear mapping of the normalized depth coordinates in this range to window
+// depth coordinates. Regardless of the actual depth buffer implementation,
+// window coordinate depth values are treated as though they range from 0 through 1
+// (like color components). Thus, the values accepted by DepthRange are both
+// clamped to this range before they are accepted.
+//
+// The default setting of (0, 1) maps the near plane to 0 and the far plane to 1.
+// With this mapping, the depth buffer range is fully utilized.
+//
+// It is not necessary that nearVal be less than farVal. Reverse mappings such as
+// nearVal 1, and farVal 0 are acceptable.
+//
+// GL.INVALID_OPERATION is generated if DepthRange is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) DepthRange(nearVal, farVal float64) {
+ C.gl1_3_glDepthRange(gl.funcs, C.GLdouble(nearVal), C.GLdouble(farVal))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIsEnabled.xml
+func (gl *GL) IsEnabled(cap glbase.Enum) bool {
+ glresult := C.gl1_3_glIsEnabled(gl.funcs, C.GLenum(cap))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexLevelParameteriv.xml
+func (gl *GL) GetTexLevelParameteriv(target glbase.Enum, level int, pname glbase.Enum, params []int32) {
+ C.gl1_3_glGetTexLevelParameteriv(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexLevelParameterfv.xml
+func (gl *GL) GetTexLevelParameterfv(target glbase.Enum, level int, pname glbase.Enum, params []float32) {
+ C.gl1_3_glGetTexLevelParameterfv(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexParameteriv.xml
+func (gl *GL) GetTexParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl1_3_glGetTexParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexParameterfv.xml
+func (gl *GL) GetTexParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl1_3_glGetTexParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexImage.xml
+func (gl *GL) GetTexImage(target glbase.Enum, level int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_3_glGetTexImage(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetIntegerv.xml
+func (gl *GL) GetIntegerv(pname glbase.Enum, params []int32) {
+ C.gl1_3_glGetIntegerv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetFloatv.xml
+func (gl *GL) GetFloatv(pname glbase.Enum, params []float32) {
+ C.gl1_3_glGetFloatv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetError.xml
+func (gl *GL) GetError() glbase.Enum {
+ glresult := C.gl1_3_glGetError(gl.funcs)
+ return glbase.Enum(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetDoublev.xml
+func (gl *GL) GetDoublev(pname glbase.Enum, params []float64) {
+ C.gl1_3_glGetDoublev(gl.funcs, C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetBooleanv.xml
+func (gl *GL) GetBooleanv(pname glbase.Enum, params []bool) {
+ C.gl1_3_glGetBooleanv(gl.funcs, C.GLenum(pname), (*C.GLboolean)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glReadPixels.xml
+func (gl *GL) ReadPixels(x, y, width, height int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_3_glReadPixels(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glReadBuffer.xml
+func (gl *GL) ReadBuffer(mode glbase.Enum) {
+ C.gl1_3_glReadBuffer(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelStorei.xml
+func (gl *GL) PixelStorei(pname glbase.Enum, param int32) {
+ C.gl1_3_glPixelStorei(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelStoref.xml
+func (gl *GL) PixelStoref(pname glbase.Enum, param float32) {
+ C.gl1_3_glPixelStoref(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDepthFunc.xml
+func (gl *GL) DepthFunc(glfunc glbase.Enum) {
+ C.gl1_3_glDepthFunc(gl.funcs, C.GLenum(glfunc))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glStencilOp.xml
+func (gl *GL) StencilOp(fail, zfail, zpass glbase.Enum) {
+ C.gl1_3_glStencilOp(gl.funcs, C.GLenum(fail), C.GLenum(zfail), C.GLenum(zpass))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glStencilFunc.xml
+func (gl *GL) StencilFunc(glfunc glbase.Enum, ref int32, mask uint32) {
+ C.gl1_3_glStencilFunc(gl.funcs, C.GLenum(glfunc), C.GLint(ref), C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLogicOp.xml
+func (gl *GL) LogicOp(opcode glbase.Enum) {
+ C.gl1_3_glLogicOp(gl.funcs, C.GLenum(opcode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBlendFunc.xml
+func (gl *GL) BlendFunc(sfactor, dfactor glbase.Enum) {
+ C.gl1_3_glBlendFunc(gl.funcs, C.GLenum(sfactor), C.GLenum(dfactor))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFlush.xml
+func (gl *GL) Flush() {
+ C.gl1_3_glFlush(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFinish.xml
+func (gl *GL) Finish() {
+ C.gl1_3_glFinish(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEnable.xml
+func (gl *GL) Enable(cap glbase.Enum) {
+ C.gl1_3_glEnable(gl.funcs, C.GLenum(cap))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDisable.xml
+func (gl *GL) Disable(cap glbase.Enum) {
+ C.gl1_3_glDisable(gl.funcs, C.GLenum(cap))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDepthMask.xml
+func (gl *GL) DepthMask(flag bool) {
+ C.gl1_3_glDepthMask(gl.funcs, *(*C.GLboolean)(unsafe.Pointer(&flag)))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColorMask.xml
+func (gl *GL) ColorMask(red, green, blue, alpha bool) {
+ C.gl1_3_glColorMask(gl.funcs, *(*C.GLboolean)(unsafe.Pointer(&red)), *(*C.GLboolean)(unsafe.Pointer(&green)), *(*C.GLboolean)(unsafe.Pointer(&blue)), *(*C.GLboolean)(unsafe.Pointer(&alpha)))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glStencilMask.xml
+func (gl *GL) StencilMask(mask uint32) {
+ C.gl1_3_glStencilMask(gl.funcs, C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClearDepth.xml
+func (gl *GL) ClearDepth(depth float64) {
+ C.gl1_3_glClearDepth(gl.funcs, C.GLdouble(depth))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClearStencil.xml
+func (gl *GL) ClearStencil(s int32) {
+ C.gl1_3_glClearStencil(gl.funcs, C.GLint(s))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClearColor.xml
+func (gl *GL) ClearColor(red, green, blue, alpha float32) {
+ C.gl1_3_glClearColor(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClear.xml
+func (gl *GL) Clear(mask glbase.Bitfield) {
+ C.gl1_3_glClear(gl.funcs, C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDrawBuffer.xml
+func (gl *GL) DrawBuffer(mode glbase.Enum) {
+ C.gl1_3_glDrawBuffer(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexImage2D.xml
+func (gl *GL) TexImage2D(target glbase.Enum, level int, internalFormat int32, width, height, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_3_glTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexImage1D.xml
+func (gl *GL) TexImage1D(target glbase.Enum, level int, internalFormat int32, width, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_3_glTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexParameteriv.xml
+func (gl *GL) TexParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl1_3_glTexParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexParameteri.xml
+func (gl *GL) TexParameteri(target, pname glbase.Enum, param int32) {
+ C.gl1_3_glTexParameteri(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexParameterfv.xml
+func (gl *GL) TexParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl1_3_glTexParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexParameterf.xml
+func (gl *GL) TexParameterf(target, pname glbase.Enum, param float32) {
+ C.gl1_3_glTexParameterf(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glScissor.xml
+func (gl *GL) Scissor(x, y, width, height int) {
+ C.gl1_3_glScissor(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPolygonMode.xml
+func (gl *GL) PolygonMode(face, mode glbase.Enum) {
+ C.gl1_3_glPolygonMode(gl.funcs, C.GLenum(face), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPointSize.xml
+func (gl *GL) PointSize(size float32) {
+ C.gl1_3_glPointSize(gl.funcs, C.GLfloat(size))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLineWidth.xml
+func (gl *GL) LineWidth(width float32) {
+ C.gl1_3_glLineWidth(gl.funcs, C.GLfloat(width))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glHint.xml
+func (gl *GL) Hint(target, mode glbase.Enum) {
+ C.gl1_3_glHint(gl.funcs, C.GLenum(target), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFrontFace.xml
+func (gl *GL) FrontFace(mode glbase.Enum) {
+ C.gl1_3_glFrontFace(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCullFace.xml
+func (gl *GL) CullFace(mode glbase.Enum) {
+ C.gl1_3_glCullFace(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexubv.xml
+func (gl *GL) Indexubv(c []uint8) {
+ C.gl1_3_glIndexubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexub.xml
+func (gl *GL) Indexub(c uint8) {
+ C.gl1_3_glIndexub(gl.funcs, C.GLubyte(c))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIsTexture.xml
+func (gl *GL) IsTexture(texture glbase.Texture) bool {
+ glresult := C.gl1_3_glIsTexture(gl.funcs, C.GLuint(texture))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// GenTextures returns n texture names in textures. There is no guarantee
+// that the names form a contiguous set of integers; however, it is
+// guaranteed that none of the returned names was in use immediately before
+// the call to GenTextures.
+//
+// The generated textures have no dimensionality; they assume the
+// dimensionality of the texture target to which they are first bound (see
+// BindTexture).
+//
+// Texture names returned by a call to GenTextures are not returned by
+// subsequent calls, unless they are first deleted with DeleteTextures.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// GenTextures is available in GL version 2.0 or greater.
+func (gl *GL) GenTextures(n int) []glbase.Texture {
+ if n == 0 {
+ return nil
+ }
+ textures := make([]glbase.Texture, n)
+ C.gl1_3_glGenTextures(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])))
+ return textures
+}
+
+// DeleteTextures deletes the textures objects whose names are stored
+// in the textures slice. After a texture is deleted, it has no contents or
+// dimensionality, and its name is free for reuse (for example by
+// GenTextures). If a texture that is currently bound is deleted, the binding
+// reverts to 0 (the default texture).
+//
+// DeleteTextures silently ignores 0's and names that do not correspond to
+// existing textures.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// DeleteTextures is available in GL version 2.0 or greater.
+func (gl *GL) DeleteTextures(textures []glbase.Texture) {
+ n := len(textures)
+ if n == 0 {
+ return
+ }
+ C.gl1_3_glDeleteTextures(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBindTexture.xml
+func (gl *GL) BindTexture(target glbase.Enum, texture glbase.Texture) {
+ C.gl1_3_glBindTexture(gl.funcs, C.GLenum(target), C.GLuint(texture))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexSubImage2D.xml
+func (gl *GL) TexSubImage2D(target glbase.Enum, level, xoffset, yoffset, width, height int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_3_glTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexSubImage1D.xml
+func (gl *GL) TexSubImage1D(target glbase.Enum, level, xoffset, width int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_3_glTexSubImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLsizei(width), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyTexSubImage2D.xml
+func (gl *GL) CopyTexSubImage2D(target glbase.Enum, level, xoffset, yoffset, x, y, width, height int) {
+ C.gl1_3_glCopyTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyTexSubImage1D.xml
+func (gl *GL) CopyTexSubImage1D(target glbase.Enum, level, xoffset, x, y, width int) {
+ C.gl1_3_glCopyTexSubImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(x), C.GLint(y), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyTexImage2D.xml
+func (gl *GL) CopyTexImage2D(target glbase.Enum, level int, internalFormat glbase.Enum, x, y, width, height, border int) {
+ C.gl1_3_glCopyTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height), C.GLint(border))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyTexImage1D.xml
+func (gl *GL) CopyTexImage1D(target glbase.Enum, level int, internalFormat glbase.Enum, x, y, width, border int) {
+ C.gl1_3_glCopyTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLint(border))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPolygonOffset.xml
+func (gl *GL) PolygonOffset(factor, units float32) {
+ C.gl1_3_glPolygonOffset(gl.funcs, C.GLfloat(factor), C.GLfloat(units))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDrawElements.xml
+func (gl *GL) DrawElements(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_3_glDrawElements(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDrawArrays.xml
+func (gl *GL) DrawArrays(mode glbase.Enum, first, count int) {
+ C.gl1_3_glDrawArrays(gl.funcs, C.GLenum(mode), C.GLint(first), C.GLsizei(count))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyTexSubImage3D.xml
+func (gl *GL) CopyTexSubImage3D(target glbase.Enum, level, xoffset, yoffset int, zoffset int32, x, y, width, height int) {
+ C.gl1_3_glCopyTexSubImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(zoffset), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexSubImage3D.xml
+func (gl *GL) TexSubImage3D(target glbase.Enum, level, xoffset, yoffset int, zoffset int32, width, height int, depth int32, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_3_glTexSubImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(zoffset), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexImage3D.xml
+func (gl *GL) TexImage3D(target glbase.Enum, level int, internalFormat int32, width, height int, depth int32, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_3_glTexImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDrawRangeElements.xml
+func (gl *GL) DrawRangeElements(mode glbase.Enum, start, end uint32, count int, gltype glbase.Enum, indices interface{}) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_3_glDrawRangeElements(gl.funcs, C.GLenum(mode), C.GLuint(start), C.GLuint(end), C.GLsizei(count), C.GLenum(gltype), indices_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBlendEquation.xml
+func (gl *GL) BlendEquation(mode glbase.Enum) {
+ C.gl1_3_glBlendEquation(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBlendColor.xml
+func (gl *GL) BlendColor(red, green, blue, alpha float32) {
+ C.gl1_3_glBlendColor(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetCompressedTexImage.xml
+func (gl *GL) GetCompressedTexImage(target glbase.Enum, level int, img interface{}) {
+ var img_ptr unsafe.Pointer
+ var img_v = reflect.ValueOf(img)
+ if img != nil && img_v.Kind() != reflect.Slice {
+ panic("parameter img must be a slice")
+ }
+ if img != nil {
+ img_ptr = unsafe.Pointer(img_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_3_glGetCompressedTexImage(gl.funcs, C.GLenum(target), C.GLint(level), img_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCompressedTexSubImage1D.xml
+func (gl *GL) CompressedTexSubImage1D(target glbase.Enum, level, xoffset, width int, format glbase.Enum, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_3_glCompressedTexSubImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLsizei(width), C.GLenum(format), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCompressedTexSubImage2D.xml
+func (gl *GL) CompressedTexSubImage2D(target glbase.Enum, level, xoffset, yoffset, width, height int, format glbase.Enum, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_3_glCompressedTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCompressedTexSubImage3D.xml
+func (gl *GL) CompressedTexSubImage3D(target glbase.Enum, level, xoffset, yoffset int, zoffset int32, width, height int, depth int32, format glbase.Enum, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_3_glCompressedTexSubImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(zoffset), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLenum(format), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCompressedTexImage1D.xml
+func (gl *GL) CompressedTexImage1D(target glbase.Enum, level int, internalFormat glbase.Enum, width, border, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_3_glCompressedTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLsizei(width), C.GLint(border), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCompressedTexImage2D.xml
+func (gl *GL) CompressedTexImage2D(target glbase.Enum, level int, internalFormat glbase.Enum, width, height, border, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_3_glCompressedTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLint(border), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCompressedTexImage3D.xml
+func (gl *GL) CompressedTexImage3D(target glbase.Enum, level int, internalFormat glbase.Enum, width, height int, depth int32, border, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_3_glCompressedTexImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLint(border), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSampleCoverage.xml
+func (gl *GL) SampleCoverage(value float32, invert bool) {
+ C.gl1_3_glSampleCoverage(gl.funcs, C.GLfloat(value), *(*C.GLboolean)(unsafe.Pointer(&invert)))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glActiveTexture.xml
+func (gl *GL) ActiveTexture(texture glbase.Enum) {
+ C.gl1_3_glActiveTexture(gl.funcs, C.GLenum(texture))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTranslatef.xml
+func (gl *GL) Translatef(x, y, z float32) {
+ C.gl1_3_glTranslatef(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTranslated.xml
+func (gl *GL) Translated(x, y, z float64) {
+ C.gl1_3_glTranslated(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glScalef.xml
+func (gl *GL) Scalef(x, y, z float32) {
+ C.gl1_3_glScalef(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glScaled.xml
+func (gl *GL) Scaled(x, y, z float64) {
+ C.gl1_3_glScaled(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRotatef.xml
+func (gl *GL) Rotatef(angle, x, y, z float32) {
+ C.gl1_3_glRotatef(gl.funcs, C.GLfloat(angle), C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRotated.xml
+func (gl *GL) Rotated(angle, x, y, z float64) {
+ C.gl1_3_glRotated(gl.funcs, C.GLdouble(angle), C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPushMatrix.xml
+func (gl *GL) PushMatrix() {
+ C.gl1_3_glPushMatrix(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPopMatrix.xml
+func (gl *GL) PopMatrix() {
+ C.gl1_3_glPopMatrix(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glOrtho.xml
+func (gl *GL) Ortho(left, right, bottom, top, zNear, zFar float64) {
+ C.gl1_3_glOrtho(gl.funcs, C.GLdouble(left), C.GLdouble(right), C.GLdouble(bottom), C.GLdouble(top), C.GLdouble(zNear), C.GLdouble(zFar))
+}
+
+// MultMatrixd multiplies the current matrix with the provided matrix.
+//
+// The m parameter must hold 16 consecutive elements of a 4x4 column-major matrix.
+//
+// The current matrix is determined by the current matrix mode (see
+// MatrixMode). It is either the projection matrix, modelview matrix, or the
+// texture matrix.
+//
+// For example, if the current matrix is C and the coordinates to be transformed
+// are v = (v[0], v[1], v[2], v[3]), then the current transformation is C × v, or
+//
+// c[0] c[4] c[8] c[12] v[0]
+// c[1] c[5] c[9] c[13] v[1]
+// c[2] c[6] c[10] c[14] X v[2]
+// c[3] c[7] c[11] c[15] v[3]
+//
+// Calling MultMatrix with an argument of m = m[0], m[1], ..., m[15]
+// replaces the current transformation with (C X M) x v, or
+//
+// c[0] c[4] c[8] c[12] m[0] m[4] m[8] m[12] v[0]
+// c[1] c[5] c[9] c[13] m[1] m[5] m[9] m[13] v[1]
+// c[2] c[6] c[10] c[14] X m[2] m[6] m[10] m[14] X v[2]
+// c[3] c[7] c[11] c[15] m[3] m[7] m[11] m[15] v[3]
+//
+// Where 'X' denotes matrix multiplication, and v is represented as a 4x1 matrix.
+//
+// While the elements of the matrix may be specified with single or double
+// precision, the GL may store or operate on these values in less-than-single
+// precision.
+//
+// In many computer languages, 4×4 arrays are represented in row-major
+// order. The transformations just described represent these matrices in
+// column-major order. The order of the multiplication is important. For
+// example, if the current transformation is a rotation, and MultMatrix is
+// called with a translation matrix, the translation is done directly on the
+// coordinates to be transformed, while the rotation is done on the results
+// of that translation.
+//
+// GL.INVALID_OPERATION is generated if MultMatrix is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) MultMatrixd(m []float64) {
+ if len(m) != 16 {
+ panic("parameter m must have length 16 for the 4x4 matrix")
+ }
+ C.gl1_3_glMultMatrixd(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&m[0])))
+}
+
+// MultMatrixf multiplies the current matrix with the provided matrix.
+//
+// The m parameter must hold 16 consecutive elements of a 4x4 column-major matrix.
+//
+// The current matrix is determined by the current matrix mode (see
+// MatrixMode). It is either the projection matrix, modelview matrix, or the
+// texture matrix.
+//
+// For example, if the current matrix is C and the coordinates to be transformed
+// are v = (v[0], v[1], v[2], v[3]), then the current transformation is C × v, or
+//
+// c[0] c[4] c[8] c[12] v[0]
+// c[1] c[5] c[9] c[13] v[1]
+// c[2] c[6] c[10] c[14] X v[2]
+// c[3] c[7] c[11] c[15] v[3]
+//
+// Calling MultMatrix with an argument of m = m[0], m[1], ..., m[15]
+// replaces the current transformation with (C X M) x v, or
+//
+// c[0] c[4] c[8] c[12] m[0] m[4] m[8] m[12] v[0]
+// c[1] c[5] c[9] c[13] m[1] m[5] m[9] m[13] v[1]
+// c[2] c[6] c[10] c[14] X m[2] m[6] m[10] m[14] X v[2]
+// c[3] c[7] c[11] c[15] m[3] m[7] m[11] m[15] v[3]
+//
+// Where 'X' denotes matrix multiplication, and v is represented as a 4x1 matrix.
+//
+// While the elements of the matrix may be specified with single or double
+// precision, the GL may store or operate on these values in less-than-single
+// precision.
+//
+// In many computer languages, 4×4 arrays are represented in row-major
+// order. The transformations just described represent these matrices in
+// column-major order. The order of the multiplication is important. For
+// example, if the current transformation is a rotation, and MultMatrix is
+// called with a translation matrix, the translation is done directly on the
+// coordinates to be transformed, while the rotation is done on the results
+// of that translation.
+//
+// GL.INVALID_OPERATION is generated if MultMatrix is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) MultMatrixf(m []float32) {
+ if len(m) != 16 {
+ panic("parameter m must have length 16 for the 4x4 matrix")
+ }
+ C.gl1_3_glMultMatrixf(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMatrixMode.xml
+func (gl *GL) MatrixMode(mode glbase.Enum) {
+ C.gl1_3_glMatrixMode(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLoadMatrixd.xml
+func (gl *GL) LoadMatrixd(m []float64) {
+ C.gl1_3_glLoadMatrixd(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLoadMatrixf.xml
+func (gl *GL) LoadMatrixf(m []float32) {
+ C.gl1_3_glLoadMatrixf(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLoadIdentity.xml
+func (gl *GL) LoadIdentity() {
+ C.gl1_3_glLoadIdentity(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFrustum.xml
+func (gl *GL) Frustum(left, right, bottom, top, zNear, zFar float64) {
+ C.gl1_3_glFrustum(gl.funcs, C.GLdouble(left), C.GLdouble(right), C.GLdouble(bottom), C.GLdouble(top), C.GLdouble(zNear), C.GLdouble(zFar))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIsList.xml
+func (gl *GL) IsList(list uint32) bool {
+ glresult := C.gl1_3_glIsList(gl.funcs, C.GLuint(list))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexGeniv.xml
+func (gl *GL) GetTexGeniv(coord, pname glbase.Enum, params []int32) {
+ C.gl1_3_glGetTexGeniv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexGenfv.xml
+func (gl *GL) GetTexGenfv(coord, pname glbase.Enum, params []float32) {
+ C.gl1_3_glGetTexGenfv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexGendv.xml
+func (gl *GL) GetTexGendv(coord, pname glbase.Enum, params []float64) {
+ C.gl1_3_glGetTexGendv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexEnviv.xml
+func (gl *GL) GetTexEnviv(target, pname glbase.Enum, params []int32) {
+ C.gl1_3_glGetTexEnviv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexEnvfv.xml
+func (gl *GL) GetTexEnvfv(target, pname glbase.Enum, params []float32) {
+ C.gl1_3_glGetTexEnvfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetPolygonStipple.xml
+func (gl *GL) GetPolygonStipple(mask []uint8) {
+ C.gl1_3_glGetPolygonStipple(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&mask[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetPixelMapusv.xml
+func (gl *GL) GetPixelMapusv(glmap glbase.Enum, values []uint16) {
+ C.gl1_3_glGetPixelMapusv(gl.funcs, C.GLenum(glmap), (*C.GLushort)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetPixelMapuiv.xml
+func (gl *GL) GetPixelMapuiv(glmap glbase.Enum, values []uint32) {
+ C.gl1_3_glGetPixelMapuiv(gl.funcs, C.GLenum(glmap), (*C.GLuint)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetPixelMapfv.xml
+func (gl *GL) GetPixelMapfv(glmap glbase.Enum, values []float32) {
+ C.gl1_3_glGetPixelMapfv(gl.funcs, C.GLenum(glmap), (*C.GLfloat)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetMaterialiv.xml
+func (gl *GL) GetMaterialiv(face, pname glbase.Enum, params []int32) {
+ C.gl1_3_glGetMaterialiv(gl.funcs, C.GLenum(face), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetMaterialfv.xml
+func (gl *GL) GetMaterialfv(face, pname glbase.Enum, params []float32) {
+ C.gl1_3_glGetMaterialfv(gl.funcs, C.GLenum(face), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetMapiv.xml
+func (gl *GL) GetMapiv(target, query glbase.Enum, v []int32) {
+ C.gl1_3_glGetMapiv(gl.funcs, C.GLenum(target), C.GLenum(query), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetMapfv.xml
+func (gl *GL) GetMapfv(target, query glbase.Enum, v []float32) {
+ C.gl1_3_glGetMapfv(gl.funcs, C.GLenum(target), C.GLenum(query), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetMapdv.xml
+func (gl *GL) GetMapdv(target, query glbase.Enum, v []float64) {
+ C.gl1_3_glGetMapdv(gl.funcs, C.GLenum(target), C.GLenum(query), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetLightiv.xml
+func (gl *GL) GetLightiv(light, pname glbase.Enum, params []int32) {
+ C.gl1_3_glGetLightiv(gl.funcs, C.GLenum(light), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetLightfv.xml
+func (gl *GL) GetLightfv(light, pname glbase.Enum, params []float32) {
+ C.gl1_3_glGetLightfv(gl.funcs, C.GLenum(light), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetClipPlane.xml
+func (gl *GL) GetClipPlane(plane glbase.Enum, equation []float64) {
+ C.gl1_3_glGetClipPlane(gl.funcs, C.GLenum(plane), (*C.GLdouble)(unsafe.Pointer(&equation[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDrawPixels.xml
+func (gl *GL) DrawPixels(width, height int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_3_glDrawPixels(gl.funcs, C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyPixels.xml
+func (gl *GL) CopyPixels(x, y, width, height int, gltype glbase.Enum) {
+ C.gl1_3_glCopyPixels(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height), C.GLenum(gltype))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelMapusv.xml
+func (gl *GL) PixelMapusv(glmap glbase.Enum, mapsize int32, values []uint16) {
+ C.gl1_3_glPixelMapusv(gl.funcs, C.GLenum(glmap), C.GLint(mapsize), (*C.GLushort)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelMapuiv.xml
+func (gl *GL) PixelMapuiv(glmap glbase.Enum, mapsize int32, values []uint32) {
+ C.gl1_3_glPixelMapuiv(gl.funcs, C.GLenum(glmap), C.GLint(mapsize), (*C.GLuint)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelMapfv.xml
+func (gl *GL) PixelMapfv(glmap glbase.Enum, mapsize int32, values []float32) {
+ C.gl1_3_glPixelMapfv(gl.funcs, C.GLenum(glmap), C.GLint(mapsize), (*C.GLfloat)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelTransferi.xml
+func (gl *GL) PixelTransferi(pname glbase.Enum, param int32) {
+ C.gl1_3_glPixelTransferi(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelTransferf.xml
+func (gl *GL) PixelTransferf(pname glbase.Enum, param float32) {
+ C.gl1_3_glPixelTransferf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelZoom.xml
+func (gl *GL) PixelZoom(xfactor, yfactor float32) {
+ C.gl1_3_glPixelZoom(gl.funcs, C.GLfloat(xfactor), C.GLfloat(yfactor))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glAlphaFunc.xml
+func (gl *GL) AlphaFunc(glfunc glbase.Enum, ref float32) {
+ C.gl1_3_glAlphaFunc(gl.funcs, C.GLenum(glfunc), C.GLfloat(ref))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalPoint2.xml
+func (gl *GL) EvalPoint2(i, j int32) {
+ C.gl1_3_glEvalPoint2(gl.funcs, C.GLint(i), C.GLint(j))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalMesh2.xml
+func (gl *GL) EvalMesh2(mode glbase.Enum, i1, i2, j1, j2 int32) {
+ C.gl1_3_glEvalMesh2(gl.funcs, C.GLenum(mode), C.GLint(i1), C.GLint(i2), C.GLint(j1), C.GLint(j2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalPoint1.xml
+func (gl *GL) EvalPoint1(i int32) {
+ C.gl1_3_glEvalPoint1(gl.funcs, C.GLint(i))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalMesh1.xml
+func (gl *GL) EvalMesh1(mode glbase.Enum, i1, i2 int32) {
+ C.gl1_3_glEvalMesh1(gl.funcs, C.GLenum(mode), C.GLint(i1), C.GLint(i2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord2fv.xml
+func (gl *GL) EvalCoord2fv(u []float32) {
+ if len(u) != 2 {
+ panic("parameter u has incorrect length")
+ }
+ C.gl1_3_glEvalCoord2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&u[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord2f.xml
+func (gl *GL) EvalCoord2f(u, v float32) {
+ C.gl1_3_glEvalCoord2f(gl.funcs, C.GLfloat(u), C.GLfloat(v))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord2dv.xml
+func (gl *GL) EvalCoord2dv(u []float64) {
+ if len(u) != 2 {
+ panic("parameter u has incorrect length")
+ }
+ C.gl1_3_glEvalCoord2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&u[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord2d.xml
+func (gl *GL) EvalCoord2d(u, v float64) {
+ C.gl1_3_glEvalCoord2d(gl.funcs, C.GLdouble(u), C.GLdouble(v))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord1fv.xml
+func (gl *GL) EvalCoord1fv(u []float32) {
+ C.gl1_3_glEvalCoord1fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&u[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord1f.xml
+func (gl *GL) EvalCoord1f(u float32) {
+ C.gl1_3_glEvalCoord1f(gl.funcs, C.GLfloat(u))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord1dv.xml
+func (gl *GL) EvalCoord1dv(u []float64) {
+ C.gl1_3_glEvalCoord1dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&u[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord1d.xml
+func (gl *GL) EvalCoord1d(u float64) {
+ C.gl1_3_glEvalCoord1d(gl.funcs, C.GLdouble(u))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMapGrid2f.xml
+func (gl *GL) MapGrid2f(un int32, u1, u2 float32, vn int32, v1, v2 float32) {
+ C.gl1_3_glMapGrid2f(gl.funcs, C.GLint(un), C.GLfloat(u1), C.GLfloat(u2), C.GLint(vn), C.GLfloat(v1), C.GLfloat(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMapGrid2d.xml
+func (gl *GL) MapGrid2d(un int32, u1, u2 float64, vn int32, v1, v2 float64) {
+ C.gl1_3_glMapGrid2d(gl.funcs, C.GLint(un), C.GLdouble(u1), C.GLdouble(u2), C.GLint(vn), C.GLdouble(v1), C.GLdouble(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMapGrid1f.xml
+func (gl *GL) MapGrid1f(un int32, u1, u2 float32) {
+ C.gl1_3_glMapGrid1f(gl.funcs, C.GLint(un), C.GLfloat(u1), C.GLfloat(u2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMapGrid1d.xml
+func (gl *GL) MapGrid1d(un int32, u1, u2 float64) {
+ C.gl1_3_glMapGrid1d(gl.funcs, C.GLint(un), C.GLdouble(u1), C.GLdouble(u2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMap2f.xml
+func (gl *GL) Map2f(target glbase.Enum, u1, u2 float32, ustride, uorder int32, v1, v2 float32, vstride, vorder int32, points []float32) {
+ C.gl1_3_glMap2f(gl.funcs, C.GLenum(target), C.GLfloat(u1), C.GLfloat(u2), C.GLint(ustride), C.GLint(uorder), C.GLfloat(v1), C.GLfloat(v2), C.GLint(vstride), C.GLint(vorder), (*C.GLfloat)(unsafe.Pointer(&points[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMap2d.xml
+func (gl *GL) Map2d(target glbase.Enum, u1, u2 float64, ustride, uorder int32, v1, v2 float64, vstride, vorder int32, points []float64) {
+ C.gl1_3_glMap2d(gl.funcs, C.GLenum(target), C.GLdouble(u1), C.GLdouble(u2), C.GLint(ustride), C.GLint(uorder), C.GLdouble(v1), C.GLdouble(v2), C.GLint(vstride), C.GLint(vorder), (*C.GLdouble)(unsafe.Pointer(&points[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMap1f.xml
+func (gl *GL) Map1f(target glbase.Enum, u1, u2 float32, stride, order int, points []float32) {
+ C.gl1_3_glMap1f(gl.funcs, C.GLenum(target), C.GLfloat(u1), C.GLfloat(u2), C.GLint(stride), C.GLint(order), (*C.GLfloat)(unsafe.Pointer(&points[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMap1d.xml
+func (gl *GL) Map1d(target glbase.Enum, u1, u2 float64, stride, order int, points []float64) {
+ C.gl1_3_glMap1d(gl.funcs, C.GLenum(target), C.GLdouble(u1), C.GLdouble(u2), C.GLint(stride), C.GLint(order), (*C.GLdouble)(unsafe.Pointer(&points[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPushAttrib.xml
+func (gl *GL) PushAttrib(mask glbase.Bitfield) {
+ C.gl1_3_glPushAttrib(gl.funcs, C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPopAttrib.xml
+func (gl *GL) PopAttrib() {
+ C.gl1_3_glPopAttrib(gl.funcs)
+}
+
+// Accum executes an operation on the accumulation buffer.
+//
+// Parameter op defines the accumulation buffer operation (GL.ACCUM, GL.LOAD,
+// GL.ADD, GL.MULT, or GL.RETURN) and specifies how the value parameter is
+// used.
+//
+// The accumulation buffer is an extended-range color buffer. Images are not
+// rendered into it. Rather, images rendered into one of the color buffers
+// are added to the contents of the accumulation buffer after rendering.
+// Effects such as antialiasing (of points, lines, and polygons), motion
+// blur, and depth of field can be created by accumulating images generated
+// with different transformation matrices.
+//
+// Each pixel in the accumulation buffer consists of red, green, blue, and
+// alpha values. The number of bits per component in the accumulation buffer
+// depends on the implementation. You can examine this number by calling
+// GetIntegerv four times, with arguments GL.ACCUM_RED_BITS,
+// GL.ACCUM_GREEN_BITS, GL.ACCUM_BLUE_BITS, and GL.ACCUM_ALPHA_BITS.
+// Regardless of the number of bits per component, the range of values stored
+// by each component is (-1, 1). The accumulation buffer pixels are mapped
+// one-to-one with frame buffer pixels.
+//
+// All accumulation buffer operations are limited to the area of the current
+// scissor box and applied identically to the red, green, blue, and alpha
+// components of each pixel. If a Accum operation results in a value outside
+// the range (-1, 1), the contents of an accumulation buffer pixel component
+// are undefined.
+//
+// The operations are as follows:
+//
+// GL.ACCUM
+// Obtains R, G, B, and A values from the buffer currently selected for
+// reading (see ReadBuffer). Each component value is divided by 2 n -
+// 1 , where n is the number of bits allocated to each color component
+// in the currently selected buffer. The result is a floating-point
+// value in the range 0 1 , which is multiplied by value and added to
+// the corresponding pixel component in the accumulation buffer,
+// thereby updating the accumulation buffer.
+//
+// GL.LOAD
+// Similar to GL.ACCUM, except that the current value in the
+// accumulation buffer is not used in the calculation of the new value.
+// That is, the R, G, B, and A values from the currently selected
+// buffer are divided by 2 n - 1 , multiplied by value, and then stored
+// in the corresponding accumulation buffer cell, overwriting the
+// current value.
+//
+// GL.ADD
+// Adds value to each R, G, B, and A in the accumulation buffer.
+//
+// GL.MULT
+// Multiplies each R, G, B, and A in the accumulation buffer by value
+// and returns the scaled component to its corresponding accumulation
+// buffer location.
+//
+// GL.RETURN
+// Transfers accumulation buffer values to the color buffer or buffers
+// currently selected for writing. Each R, G, B, and A component is
+// multiplied by value, then multiplied by 2 n - 1 , clamped to the
+// range 0 2 n - 1 , and stored in the corresponding display buffer
+// cell. The only fragment operations that are applied to this transfer
+// are pixel ownership, scissor, dithering, and color writemasks.
+//
+// To clear the accumulation buffer, call ClearAccum with R, G, B, and A
+// values to set it to, then call Clear with the accumulation buffer
+// enabled.
+//
+// Error GL.INVALID_ENUM is generated if op is not an accepted value.
+// GL.INVALID_OPERATION is generated if there is no accumulation buffer.
+// GL.INVALID_OPERATION is generated if Accum is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) Accum(op glbase.Enum, value float32) {
+ C.gl1_3_glAccum(gl.funcs, C.GLenum(op), C.GLfloat(value))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexMask.xml
+func (gl *GL) IndexMask(mask uint32) {
+ C.gl1_3_glIndexMask(gl.funcs, C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClearIndex.xml
+func (gl *GL) ClearIndex(c float32) {
+ C.gl1_3_glClearIndex(gl.funcs, C.GLfloat(c))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClearAccum.xml
+func (gl *GL) ClearAccum(red, green, blue, alpha float32) {
+ C.gl1_3_glClearAccum(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPushName.xml
+func (gl *GL) PushName(name uint32) {
+ C.gl1_3_glPushName(gl.funcs, C.GLuint(name))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPopName.xml
+func (gl *GL) PopName() {
+ C.gl1_3_glPopName(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPassThrough.xml
+func (gl *GL) PassThrough(token float32) {
+ C.gl1_3_glPassThrough(gl.funcs, C.GLfloat(token))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLoadName.xml
+func (gl *GL) LoadName(name uint32) {
+ C.gl1_3_glLoadName(gl.funcs, C.GLuint(name))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glInitNames.xml
+func (gl *GL) InitNames() {
+ C.gl1_3_glInitNames(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRenderMode.xml
+func (gl *GL) RenderMode(mode glbase.Enum) int32 {
+ glresult := C.gl1_3_glRenderMode(gl.funcs, C.GLenum(mode))
+ return int32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSelectBuffer.xml
+func (gl *GL) SelectBuffer(size int, buffer []glbase.Buffer) {
+ C.gl1_3_glSelectBuffer(gl.funcs, C.GLsizei(size), (*C.GLuint)(unsafe.Pointer(&buffer[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFeedbackBuffer.xml
+func (gl *GL) FeedbackBuffer(size int, gltype glbase.Enum, buffer []float32) {
+ C.gl1_3_glFeedbackBuffer(gl.funcs, C.GLsizei(size), C.GLenum(gltype), (*C.GLfloat)(unsafe.Pointer(&buffer[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexGeniv.xml
+func (gl *GL) TexGeniv(coord, pname glbase.Enum, params []int32) {
+ C.gl1_3_glTexGeniv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexGeni.xml
+func (gl *GL) TexGeni(coord, pname glbase.Enum, param int32) {
+ C.gl1_3_glTexGeni(gl.funcs, C.GLenum(coord), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexGenfv.xml
+func (gl *GL) TexGenfv(coord, pname glbase.Enum, params []float32) {
+ C.gl1_3_glTexGenfv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexGenf.xml
+func (gl *GL) TexGenf(coord, pname glbase.Enum, param float32) {
+ C.gl1_3_glTexGenf(gl.funcs, C.GLenum(coord), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexGendv.xml
+func (gl *GL) TexGendv(coord, pname glbase.Enum, params []float64) {
+ C.gl1_3_glTexGendv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexGend.xml
+func (gl *GL) TexGend(coord, pname glbase.Enum, param float64) {
+ C.gl1_3_glTexGend(gl.funcs, C.GLenum(coord), C.GLenum(pname), C.GLdouble(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexEnviv.xml
+func (gl *GL) TexEnviv(target, pname glbase.Enum, params []int32) {
+ C.gl1_3_glTexEnviv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexEnvi.xml
+func (gl *GL) TexEnvi(target, pname glbase.Enum, param int32) {
+ C.gl1_3_glTexEnvi(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexEnvfv.xml
+func (gl *GL) TexEnvfv(target, pname glbase.Enum, params []float32) {
+ C.gl1_3_glTexEnvfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexEnvf.xml
+func (gl *GL) TexEnvf(target, pname glbase.Enum, param float32) {
+ C.gl1_3_glTexEnvf(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glShadeModel.xml
+func (gl *GL) ShadeModel(mode glbase.Enum) {
+ C.gl1_3_glShadeModel(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPolygonStipple.xml
+func (gl *GL) PolygonStipple(mask []uint8) {
+ C.gl1_3_glPolygonStipple(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&mask[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMaterialiv.xml
+func (gl *GL) Materialiv(face, pname glbase.Enum, params []int32) {
+ C.gl1_3_glMaterialiv(gl.funcs, C.GLenum(face), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMateriali.xml
+func (gl *GL) Materiali(face, pname glbase.Enum, param int32) {
+ C.gl1_3_glMateriali(gl.funcs, C.GLenum(face), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMaterialfv.xml
+func (gl *GL) Materialfv(face, pname glbase.Enum, params []float32) {
+ C.gl1_3_glMaterialfv(gl.funcs, C.GLenum(face), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMaterialf.xml
+func (gl *GL) Materialf(face, pname glbase.Enum, param float32) {
+ C.gl1_3_glMaterialf(gl.funcs, C.GLenum(face), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLineStipple.xml
+func (gl *GL) LineStipple(factor int32, pattern uint16) {
+ C.gl1_3_glLineStipple(gl.funcs, C.GLint(factor), C.GLushort(pattern))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLightModeliv.xml
+func (gl *GL) LightModeliv(pname glbase.Enum, params []int32) {
+ C.gl1_3_glLightModeliv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLightModeli.xml
+func (gl *GL) LightModeli(pname glbase.Enum, param int32) {
+ C.gl1_3_glLightModeli(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLightModelfv.xml
+func (gl *GL) LightModelfv(pname glbase.Enum, params []float32) {
+ C.gl1_3_glLightModelfv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLightModelf.xml
+func (gl *GL) LightModelf(pname glbase.Enum, param float32) {
+ C.gl1_3_glLightModelf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLightiv.xml
+func (gl *GL) Lightiv(light, pname glbase.Enum, params []int32) {
+ C.gl1_3_glLightiv(gl.funcs, C.GLenum(light), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLighti.xml
+func (gl *GL) Lighti(light, pname glbase.Enum, param int32) {
+ C.gl1_3_glLighti(gl.funcs, C.GLenum(light), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLightfv.xml
+func (gl *GL) Lightfv(light, pname glbase.Enum, params []float32) {
+ C.gl1_3_glLightfv(gl.funcs, C.GLenum(light), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLightf.xml
+func (gl *GL) Lightf(light, pname glbase.Enum, param float32) {
+ C.gl1_3_glLightf(gl.funcs, C.GLenum(light), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFogiv.xml
+func (gl *GL) Fogiv(pname glbase.Enum, params []int32) {
+ C.gl1_3_glFogiv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFogi.xml
+func (gl *GL) Fogi(pname glbase.Enum, param int32) {
+ C.gl1_3_glFogi(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFogfv.xml
+func (gl *GL) Fogfv(pname glbase.Enum, params []float32) {
+ C.gl1_3_glFogfv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFogf.xml
+func (gl *GL) Fogf(pname glbase.Enum, param float32) {
+ C.gl1_3_glFogf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColorMaterial.xml
+func (gl *GL) ColorMaterial(face, mode glbase.Enum) {
+ C.gl1_3_glColorMaterial(gl.funcs, C.GLenum(face), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClipPlane.xml
+func (gl *GL) ClipPlane(plane glbase.Enum, equation []float64) {
+ C.gl1_3_glClipPlane(gl.funcs, C.GLenum(plane), (*C.GLdouble)(unsafe.Pointer(&equation[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4sv.xml
+func (gl *GL) Vertex4sv(v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_3_glVertex4sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4s.xml
+func (gl *GL) Vertex4s(x, y, z, w int16) {
+ C.gl1_3_glVertex4s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z), C.GLshort(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4iv.xml
+func (gl *GL) Vertex4iv(v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_3_glVertex4iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4i.xml
+func (gl *GL) Vertex4i(x, y, z, w int) {
+ C.gl1_3_glVertex4i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z), C.GLint(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4fv.xml
+func (gl *GL) Vertex4fv(v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_3_glVertex4fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4f.xml
+func (gl *GL) Vertex4f(x, y, z, w float32) {
+ C.gl1_3_glVertex4f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z), C.GLfloat(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4dv.xml
+func (gl *GL) Vertex4dv(v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_3_glVertex4dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4d.xml
+func (gl *GL) Vertex4d(x, y, z, w float64) {
+ C.gl1_3_glVertex4d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z), C.GLdouble(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3sv.xml
+func (gl *GL) Vertex3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_3_glVertex3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3s.xml
+func (gl *GL) Vertex3s(x, y, z int16) {
+ C.gl1_3_glVertex3s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3iv.xml
+func (gl *GL) Vertex3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_3_glVertex3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3i.xml
+func (gl *GL) Vertex3i(x, y, z int) {
+ C.gl1_3_glVertex3i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3fv.xml
+func (gl *GL) Vertex3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_3_glVertex3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3f.xml
+func (gl *GL) Vertex3f(x, y, z float32) {
+ C.gl1_3_glVertex3f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3dv.xml
+func (gl *GL) Vertex3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_3_glVertex3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3d.xml
+func (gl *GL) Vertex3d(x, y, z float64) {
+ C.gl1_3_glVertex3d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2sv.xml
+func (gl *GL) Vertex2sv(v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_3_glVertex2sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2s.xml
+func (gl *GL) Vertex2s(x, y int16) {
+ C.gl1_3_glVertex2s(gl.funcs, C.GLshort(x), C.GLshort(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2iv.xml
+func (gl *GL) Vertex2iv(v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_3_glVertex2iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2i.xml
+func (gl *GL) Vertex2i(x, y int) {
+ C.gl1_3_glVertex2i(gl.funcs, C.GLint(x), C.GLint(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2fv.xml
+func (gl *GL) Vertex2fv(v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_3_glVertex2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2f.xml
+func (gl *GL) Vertex2f(x, y float32) {
+ C.gl1_3_glVertex2f(gl.funcs, C.GLfloat(x), C.GLfloat(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2dv.xml
+func (gl *GL) Vertex2dv(v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_3_glVertex2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2d.xml
+func (gl *GL) Vertex2d(x, y float64) {
+ C.gl1_3_glVertex2d(gl.funcs, C.GLdouble(x), C.GLdouble(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4sv.xml
+func (gl *GL) TexCoord4sv(v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_3_glTexCoord4sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4s.xml
+func (gl *GL) TexCoord4s(s, t, r, q int16) {
+ C.gl1_3_glTexCoord4s(gl.funcs, C.GLshort(s), C.GLshort(t), C.GLshort(r), C.GLshort(q))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4iv.xml
+func (gl *GL) TexCoord4iv(v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_3_glTexCoord4iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4i.xml
+func (gl *GL) TexCoord4i(s, t, r, q int32) {
+ C.gl1_3_glTexCoord4i(gl.funcs, C.GLint(s), C.GLint(t), C.GLint(r), C.GLint(q))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4fv.xml
+func (gl *GL) TexCoord4fv(v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_3_glTexCoord4fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4f.xml
+func (gl *GL) TexCoord4f(s, t, r, q float32) {
+ C.gl1_3_glTexCoord4f(gl.funcs, C.GLfloat(s), C.GLfloat(t), C.GLfloat(r), C.GLfloat(q))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4dv.xml
+func (gl *GL) TexCoord4dv(v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_3_glTexCoord4dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4d.xml
+func (gl *GL) TexCoord4d(s, t, r, q float64) {
+ C.gl1_3_glTexCoord4d(gl.funcs, C.GLdouble(s), C.GLdouble(t), C.GLdouble(r), C.GLdouble(q))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3sv.xml
+func (gl *GL) TexCoord3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_3_glTexCoord3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3s.xml
+func (gl *GL) TexCoord3s(s, t, r int16) {
+ C.gl1_3_glTexCoord3s(gl.funcs, C.GLshort(s), C.GLshort(t), C.GLshort(r))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3iv.xml
+func (gl *GL) TexCoord3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_3_glTexCoord3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3i.xml
+func (gl *GL) TexCoord3i(s, t, r int32) {
+ C.gl1_3_glTexCoord3i(gl.funcs, C.GLint(s), C.GLint(t), C.GLint(r))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3fv.xml
+func (gl *GL) TexCoord3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_3_glTexCoord3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3f.xml
+func (gl *GL) TexCoord3f(s, t, r float32) {
+ C.gl1_3_glTexCoord3f(gl.funcs, C.GLfloat(s), C.GLfloat(t), C.GLfloat(r))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3dv.xml
+func (gl *GL) TexCoord3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_3_glTexCoord3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3d.xml
+func (gl *GL) TexCoord3d(s, t, r float64) {
+ C.gl1_3_glTexCoord3d(gl.funcs, C.GLdouble(s), C.GLdouble(t), C.GLdouble(r))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2sv.xml
+func (gl *GL) TexCoord2sv(v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_3_glTexCoord2sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2s.xml
+func (gl *GL) TexCoord2s(s, t int16) {
+ C.gl1_3_glTexCoord2s(gl.funcs, C.GLshort(s), C.GLshort(t))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2iv.xml
+func (gl *GL) TexCoord2iv(v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_3_glTexCoord2iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2i.xml
+func (gl *GL) TexCoord2i(s, t int32) {
+ C.gl1_3_glTexCoord2i(gl.funcs, C.GLint(s), C.GLint(t))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2fv.xml
+func (gl *GL) TexCoord2fv(v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_3_glTexCoord2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2f.xml
+func (gl *GL) TexCoord2f(s, t float32) {
+ C.gl1_3_glTexCoord2f(gl.funcs, C.GLfloat(s), C.GLfloat(t))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2dv.xml
+func (gl *GL) TexCoord2dv(v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_3_glTexCoord2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2d.xml
+func (gl *GL) TexCoord2d(s, t float64) {
+ C.gl1_3_glTexCoord2d(gl.funcs, C.GLdouble(s), C.GLdouble(t))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1sv.xml
+func (gl *GL) TexCoord1sv(v []int16) {
+ C.gl1_3_glTexCoord1sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1s.xml
+func (gl *GL) TexCoord1s(s int16) {
+ C.gl1_3_glTexCoord1s(gl.funcs, C.GLshort(s))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1iv.xml
+func (gl *GL) TexCoord1iv(v []int32) {
+ C.gl1_3_glTexCoord1iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1i.xml
+func (gl *GL) TexCoord1i(s int32) {
+ C.gl1_3_glTexCoord1i(gl.funcs, C.GLint(s))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1fv.xml
+func (gl *GL) TexCoord1fv(v []float32) {
+ C.gl1_3_glTexCoord1fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1f.xml
+func (gl *GL) TexCoord1f(s float32) {
+ C.gl1_3_glTexCoord1f(gl.funcs, C.GLfloat(s))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1dv.xml
+func (gl *GL) TexCoord1dv(v []float64) {
+ C.gl1_3_glTexCoord1dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1d.xml
+func (gl *GL) TexCoord1d(s float64) {
+ C.gl1_3_glTexCoord1d(gl.funcs, C.GLdouble(s))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRectsv.xml
+func (gl *GL) Rectsv(v1, v2 []int16) {
+ C.gl1_3_glRectsv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v1[0])), (*C.GLshort)(unsafe.Pointer(&v2[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRects.xml
+func (gl *GL) Rects(x1, y1, x2, y2 int16) {
+ C.gl1_3_glRects(gl.funcs, C.GLshort(x1), C.GLshort(y1), C.GLshort(x2), C.GLshort(y2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRectiv.xml
+func (gl *GL) Rectiv(v1, v2 []int32) {
+ C.gl1_3_glRectiv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v1[0])), (*C.GLint)(unsafe.Pointer(&v2[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRecti.xml
+func (gl *GL) Recti(x1, y1, x2, y2 int32) {
+ C.gl1_3_glRecti(gl.funcs, C.GLint(x1), C.GLint(y1), C.GLint(x2), C.GLint(y2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRectfv.xml
+func (gl *GL) Rectfv(v1, v2 []float32) {
+ C.gl1_3_glRectfv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v1[0])), (*C.GLfloat)(unsafe.Pointer(&v2[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRectf.xml
+func (gl *GL) Rectf(x1, y1, x2, y2 float32) {
+ C.gl1_3_glRectf(gl.funcs, C.GLfloat(x1), C.GLfloat(y1), C.GLfloat(x2), C.GLfloat(y2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRectdv.xml
+func (gl *GL) Rectdv(v1, v2 []float64) {
+ C.gl1_3_glRectdv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v1[0])), (*C.GLdouble)(unsafe.Pointer(&v2[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRectd.xml
+func (gl *GL) Rectd(x1, y1, x2, y2 float64) {
+ C.gl1_3_glRectd(gl.funcs, C.GLdouble(x1), C.GLdouble(y1), C.GLdouble(x2), C.GLdouble(y2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4sv.xml
+func (gl *GL) RasterPos4sv(v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_3_glRasterPos4sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4s.xml
+func (gl *GL) RasterPos4s(x, y, z, w int16) {
+ C.gl1_3_glRasterPos4s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z), C.GLshort(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4iv.xml
+func (gl *GL) RasterPos4iv(v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_3_glRasterPos4iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4i.xml
+func (gl *GL) RasterPos4i(x, y, z, w int) {
+ C.gl1_3_glRasterPos4i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z), C.GLint(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4fv.xml
+func (gl *GL) RasterPos4fv(v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_3_glRasterPos4fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4f.xml
+func (gl *GL) RasterPos4f(x, y, z, w float32) {
+ C.gl1_3_glRasterPos4f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z), C.GLfloat(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4dv.xml
+func (gl *GL) RasterPos4dv(v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_3_glRasterPos4dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4d.xml
+func (gl *GL) RasterPos4d(x, y, z, w float64) {
+ C.gl1_3_glRasterPos4d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z), C.GLdouble(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3sv.xml
+func (gl *GL) RasterPos3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_3_glRasterPos3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3s.xml
+func (gl *GL) RasterPos3s(x, y, z int16) {
+ C.gl1_3_glRasterPos3s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3iv.xml
+func (gl *GL) RasterPos3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_3_glRasterPos3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3i.xml
+func (gl *GL) RasterPos3i(x, y, z int) {
+ C.gl1_3_glRasterPos3i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3fv.xml
+func (gl *GL) RasterPos3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_3_glRasterPos3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3f.xml
+func (gl *GL) RasterPos3f(x, y, z float32) {
+ C.gl1_3_glRasterPos3f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3dv.xml
+func (gl *GL) RasterPos3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_3_glRasterPos3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3d.xml
+func (gl *GL) RasterPos3d(x, y, z float64) {
+ C.gl1_3_glRasterPos3d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2sv.xml
+func (gl *GL) RasterPos2sv(v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_3_glRasterPos2sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2s.xml
+func (gl *GL) RasterPos2s(x, y int16) {
+ C.gl1_3_glRasterPos2s(gl.funcs, C.GLshort(x), C.GLshort(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2iv.xml
+func (gl *GL) RasterPos2iv(v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_3_glRasterPos2iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2i.xml
+func (gl *GL) RasterPos2i(x, y int) {
+ C.gl1_3_glRasterPos2i(gl.funcs, C.GLint(x), C.GLint(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2fv.xml
+func (gl *GL) RasterPos2fv(v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_3_glRasterPos2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2f.xml
+func (gl *GL) RasterPos2f(x, y float32) {
+ C.gl1_3_glRasterPos2f(gl.funcs, C.GLfloat(x), C.GLfloat(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2dv.xml
+func (gl *GL) RasterPos2dv(v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_3_glRasterPos2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2d.xml
+func (gl *GL) RasterPos2d(x, y float64) {
+ C.gl1_3_glRasterPos2d(gl.funcs, C.GLdouble(x), C.GLdouble(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3sv.xml
+func (gl *GL) Normal3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_3_glNormal3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3s.xml
+func (gl *GL) Normal3s(nx, ny, nz int16) {
+ C.gl1_3_glNormal3s(gl.funcs, C.GLshort(nx), C.GLshort(ny), C.GLshort(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3iv.xml
+func (gl *GL) Normal3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_3_glNormal3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3i.xml
+func (gl *GL) Normal3i(nx, ny, nz int32) {
+ C.gl1_3_glNormal3i(gl.funcs, C.GLint(nx), C.GLint(ny), C.GLint(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3fv.xml
+func (gl *GL) Normal3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_3_glNormal3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3f.xml
+func (gl *GL) Normal3f(nx, ny, nz float32) {
+ C.gl1_3_glNormal3f(gl.funcs, C.GLfloat(nx), C.GLfloat(ny), C.GLfloat(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3dv.xml
+func (gl *GL) Normal3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_3_glNormal3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3d.xml
+func (gl *GL) Normal3d(nx, ny, nz float64) {
+ C.gl1_3_glNormal3d(gl.funcs, C.GLdouble(nx), C.GLdouble(ny), C.GLdouble(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3bv.xml
+func (gl *GL) Normal3bv(v []byte) {
+ C.gl1_3_glNormal3bv(gl.funcs, (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3b.xml
+func (gl *GL) Normal3b(nx, ny, nz byte) {
+ C.gl1_3_glNormal3b(gl.funcs, C.GLbyte(nx), C.GLbyte(ny), C.GLbyte(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexsv.xml
+func (gl *GL) Indexsv(c []int16) {
+ C.gl1_3_glIndexsv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexs.xml
+func (gl *GL) Indexs(c int16) {
+ C.gl1_3_glIndexs(gl.funcs, C.GLshort(c))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexiv.xml
+func (gl *GL) Indexiv(c []int32) {
+ C.gl1_3_glIndexiv(gl.funcs, (*C.GLint)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexi.xml
+func (gl *GL) Indexi(c int32) {
+ C.gl1_3_glIndexi(gl.funcs, C.GLint(c))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexfv.xml
+func (gl *GL) Indexfv(c []float32) {
+ C.gl1_3_glIndexfv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexf.xml
+func (gl *GL) Indexf(c float32) {
+ C.gl1_3_glIndexf(gl.funcs, C.GLfloat(c))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexdv.xml
+func (gl *GL) Indexdv(c []float64) {
+ C.gl1_3_glIndexdv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexd.xml
+func (gl *GL) Indexd(c float64) {
+ C.gl1_3_glIndexd(gl.funcs, C.GLdouble(c))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEnd.xml
+func (gl *GL) End() {
+ C.gl1_3_glEnd(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEdgeFlagv.xml
+func (gl *GL) EdgeFlagv(flag []bool) {
+ C.gl1_3_glEdgeFlagv(gl.funcs, (*C.GLboolean)(unsafe.Pointer(&flag[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEdgeFlag.xml
+func (gl *GL) EdgeFlag(flag bool) {
+ C.gl1_3_glEdgeFlag(gl.funcs, *(*C.GLboolean)(unsafe.Pointer(&flag)))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4usv.xml
+func (gl *GL) Color4usv(v []uint16) {
+ C.gl1_3_glColor4usv(gl.funcs, (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4us.xml
+func (gl *GL) Color4us(red, green, blue, alpha uint16) {
+ C.gl1_3_glColor4us(gl.funcs, C.GLushort(red), C.GLushort(green), C.GLushort(blue), C.GLushort(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4uiv.xml
+func (gl *GL) Color4uiv(v []uint32) {
+ C.gl1_3_glColor4uiv(gl.funcs, (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4ui.xml
+func (gl *GL) Color4ui(red, green, blue, alpha uint32) {
+ C.gl1_3_glColor4ui(gl.funcs, C.GLuint(red), C.GLuint(green), C.GLuint(blue), C.GLuint(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4ubv.xml
+func (gl *GL) Color4ubv(v []uint8) {
+ C.gl1_3_glColor4ubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4ub.xml
+func (gl *GL) Color4ub(red, green, blue, alpha uint8) {
+ C.gl1_3_glColor4ub(gl.funcs, C.GLubyte(red), C.GLubyte(green), C.GLubyte(blue), C.GLubyte(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4sv.xml
+func (gl *GL) Color4sv(v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_3_glColor4sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4s.xml
+func (gl *GL) Color4s(red, green, blue, alpha int16) {
+ C.gl1_3_glColor4s(gl.funcs, C.GLshort(red), C.GLshort(green), C.GLshort(blue), C.GLshort(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4iv.xml
+func (gl *GL) Color4iv(v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_3_glColor4iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4i.xml
+func (gl *GL) Color4i(red, green, blue, alpha int32) {
+ C.gl1_3_glColor4i(gl.funcs, C.GLint(red), C.GLint(green), C.GLint(blue), C.GLint(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4fv.xml
+func (gl *GL) Color4fv(v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_3_glColor4fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4f.xml
+func (gl *GL) Color4f(red, green, blue, alpha float32) {
+ C.gl1_3_glColor4f(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4dv.xml
+func (gl *GL) Color4dv(v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_3_glColor4dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4d.xml
+func (gl *GL) Color4d(red, green, blue, alpha float64) {
+ C.gl1_3_glColor4d(gl.funcs, C.GLdouble(red), C.GLdouble(green), C.GLdouble(blue), C.GLdouble(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4bv.xml
+func (gl *GL) Color4bv(v []byte) {
+ C.gl1_3_glColor4bv(gl.funcs, (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4b.xml
+func (gl *GL) Color4b(red, green, blue, alpha byte) {
+ C.gl1_3_glColor4b(gl.funcs, C.GLbyte(red), C.GLbyte(green), C.GLbyte(blue), C.GLbyte(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3usv.xml
+func (gl *GL) Color3usv(v []uint16) {
+ C.gl1_3_glColor3usv(gl.funcs, (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3us.xml
+func (gl *GL) Color3us(red, green, blue uint16) {
+ C.gl1_3_glColor3us(gl.funcs, C.GLushort(red), C.GLushort(green), C.GLushort(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3uiv.xml
+func (gl *GL) Color3uiv(v []uint32) {
+ C.gl1_3_glColor3uiv(gl.funcs, (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3ui.xml
+func (gl *GL) Color3ui(red, green, blue uint32) {
+ C.gl1_3_glColor3ui(gl.funcs, C.GLuint(red), C.GLuint(green), C.GLuint(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3ubv.xml
+func (gl *GL) Color3ubv(v []uint8) {
+ C.gl1_3_glColor3ubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3ub.xml
+func (gl *GL) Color3ub(red, green, blue uint8) {
+ C.gl1_3_glColor3ub(gl.funcs, C.GLubyte(red), C.GLubyte(green), C.GLubyte(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3sv.xml
+func (gl *GL) Color3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_3_glColor3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3s.xml
+func (gl *GL) Color3s(red, green, blue int16) {
+ C.gl1_3_glColor3s(gl.funcs, C.GLshort(red), C.GLshort(green), C.GLshort(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3iv.xml
+func (gl *GL) Color3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_3_glColor3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3i.xml
+func (gl *GL) Color3i(red, green, blue int32) {
+ C.gl1_3_glColor3i(gl.funcs, C.GLint(red), C.GLint(green), C.GLint(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3fv.xml
+func (gl *GL) Color3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_3_glColor3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3f.xml
+func (gl *GL) Color3f(red, green, blue float32) {
+ C.gl1_3_glColor3f(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3dv.xml
+func (gl *GL) Color3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_3_glColor3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3d.xml
+func (gl *GL) Color3d(red, green, blue float64) {
+ C.gl1_3_glColor3d(gl.funcs, C.GLdouble(red), C.GLdouble(green), C.GLdouble(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3bv.xml
+func (gl *GL) Color3bv(v []byte) {
+ C.gl1_3_glColor3bv(gl.funcs, (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3b.xml
+func (gl *GL) Color3b(red, green, blue byte) {
+ C.gl1_3_glColor3b(gl.funcs, C.GLbyte(red), C.GLbyte(green), C.GLbyte(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBitmap.xml
+func (gl *GL) Bitmap(width, height int, xorig, yorig, xmove, ymove float32, bitmap []uint8) {
+ C.gl1_3_glBitmap(gl.funcs, C.GLsizei(width), C.GLsizei(height), C.GLfloat(xorig), C.GLfloat(yorig), C.GLfloat(xmove), C.GLfloat(ymove), (*C.GLubyte)(unsafe.Pointer(&bitmap[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBegin.xml
+func (gl *GL) Begin(mode glbase.Enum) {
+ C.gl1_3_glBegin(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glListBase.xml
+func (gl *GL) ListBase(base uint32) {
+ C.gl1_3_glListBase(gl.funcs, C.GLuint(base))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGenLists.xml
+func (gl *GL) GenLists(range_ int32) uint32 {
+ glresult := C.gl1_3_glGenLists(gl.funcs, C.GLsizei(range_))
+ return uint32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDeleteLists.xml
+func (gl *GL) DeleteLists(list uint32, range_ int32) {
+ C.gl1_3_glDeleteLists(gl.funcs, C.GLuint(list), C.GLsizei(range_))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCallLists.xml
+func (gl *GL) CallLists(n int, gltype glbase.Enum, lists interface{}) {
+ var lists_ptr unsafe.Pointer
+ var lists_v = reflect.ValueOf(lists)
+ if lists != nil && lists_v.Kind() != reflect.Slice {
+ panic("parameter lists must be a slice")
+ }
+ if lists != nil {
+ lists_ptr = unsafe.Pointer(lists_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_3_glCallLists(gl.funcs, C.GLsizei(n), C.GLenum(gltype), lists_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCallList.xml
+func (gl *GL) CallList(list uint32) {
+ C.gl1_3_glCallList(gl.funcs, C.GLuint(list))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEndList.xml
+func (gl *GL) EndList() {
+ C.gl1_3_glEndList(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNewList.xml
+func (gl *GL) NewList(list uint32, mode glbase.Enum) {
+ C.gl1_3_glNewList(gl.funcs, C.GLuint(list), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPushClientAttrib.xml
+func (gl *GL) PushClientAttrib(mask glbase.Bitfield) {
+ C.gl1_3_glPushClientAttrib(gl.funcs, C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPopClientAttrib.xml
+func (gl *GL) PopClientAttrib() {
+ C.gl1_3_glPopClientAttrib(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPrioritizeTextures.xml
+func (gl *GL) PrioritizeTextures(n int, textures []glbase.Texture, priorities []float32) {
+ C.gl1_3_glPrioritizeTextures(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])), (*C.GLfloat)(unsafe.Pointer(&priorities[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glAreTexturesResident.xml
+func (gl *GL) AreTexturesResident(n int, textures []glbase.Texture, residences []bool) bool {
+ glresult := C.gl1_3_glAreTexturesResident(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])), (*C.GLboolean)(unsafe.Pointer(&residences[0])))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexPointer.xml
+func (gl *GL) VertexPointer(size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_3_glVertexPointer(gl.funcs, C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoordPointer.xml
+func (gl *GL) TexCoordPointer(size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_3_glTexCoordPointer(gl.funcs, C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormalPointer.xml
+func (gl *GL) NormalPointer(gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_3_glNormalPointer(gl.funcs, C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glInterleavedArrays.xml
+func (gl *GL) InterleavedArrays(format glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_3_glInterleavedArrays(gl.funcs, C.GLenum(format), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexPointer.xml
+func (gl *GL) IndexPointer(gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_3_glIndexPointer(gl.funcs, C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEnableClientState.xml
+func (gl *GL) EnableClientState(array glbase.Enum) {
+ C.gl1_3_glEnableClientState(gl.funcs, C.GLenum(array))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEdgeFlagPointer.xml
+func (gl *GL) EdgeFlagPointer(stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_3_glEdgeFlagPointer(gl.funcs, C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDisableClientState.xml
+func (gl *GL) DisableClientState(array glbase.Enum) {
+ C.gl1_3_glDisableClientState(gl.funcs, C.GLenum(array))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColorPointer.xml
+func (gl *GL) ColorPointer(size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_3_glColorPointer(gl.funcs, C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glArrayElement.xml
+func (gl *GL) ArrayElement(i int32) {
+ C.gl1_3_glArrayElement(gl.funcs, C.GLint(i))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glResetMinmax.xml
+func (gl *GL) ResetMinmax(target glbase.Enum) {
+ C.gl1_3_glResetMinmax(gl.funcs, C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glResetHistogram.xml
+func (gl *GL) ResetHistogram(target glbase.Enum) {
+ C.gl1_3_glResetHistogram(gl.funcs, C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMinmax.xml
+func (gl *GL) Minmax(target, internalFormat glbase.Enum, sink bool) {
+ C.gl1_3_glMinmax(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), *(*C.GLboolean)(unsafe.Pointer(&sink)))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glHistogram.xml
+func (gl *GL) Histogram(target glbase.Enum, width int, internalFormat glbase.Enum, sink bool) {
+ C.gl1_3_glHistogram(gl.funcs, C.GLenum(target), C.GLsizei(width), C.GLenum(internalFormat), *(*C.GLboolean)(unsafe.Pointer(&sink)))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetMinmaxParameteriv.xml
+func (gl *GL) GetMinmaxParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl1_3_glGetMinmaxParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetMinmaxParameterfv.xml
+func (gl *GL) GetMinmaxParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl1_3_glGetMinmaxParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetMinmax.xml
+func (gl *GL) GetMinmax(target glbase.Enum, reset bool, format, gltype glbase.Enum, values interface{}) {
+ var values_ptr unsafe.Pointer
+ var values_v = reflect.ValueOf(values)
+ if values != nil && values_v.Kind() != reflect.Slice {
+ panic("parameter values must be a slice")
+ }
+ if values != nil {
+ values_ptr = unsafe.Pointer(values_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_3_glGetMinmax(gl.funcs, C.GLenum(target), *(*C.GLboolean)(unsafe.Pointer(&reset)), C.GLenum(format), C.GLenum(gltype), values_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetHistogramParameteriv.xml
+func (gl *GL) GetHistogramParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl1_3_glGetHistogramParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetHistogramParameterfv.xml
+func (gl *GL) GetHistogramParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl1_3_glGetHistogramParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetHistogram.xml
+func (gl *GL) GetHistogram(target glbase.Enum, reset bool, format, gltype glbase.Enum, values interface{}) {
+ var values_ptr unsafe.Pointer
+ var values_v = reflect.ValueOf(values)
+ if values != nil && values_v.Kind() != reflect.Slice {
+ panic("parameter values must be a slice")
+ }
+ if values != nil {
+ values_ptr = unsafe.Pointer(values_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_3_glGetHistogram(gl.funcs, C.GLenum(target), *(*C.GLboolean)(unsafe.Pointer(&reset)), C.GLenum(format), C.GLenum(gltype), values_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSeparableFilter2D.xml
+func (gl *GL) SeparableFilter2D(target, internalFormat glbase.Enum, width, height int, format, gltype glbase.Enum, row, column interface{}) {
+ var row_ptr unsafe.Pointer
+ var row_v = reflect.ValueOf(row)
+ if row != nil && row_v.Kind() != reflect.Slice {
+ panic("parameter row must be a slice")
+ }
+ if row != nil {
+ row_ptr = unsafe.Pointer(row_v.Index(0).Addr().Pointer())
+ }
+ var column_ptr unsafe.Pointer
+ var column_v = reflect.ValueOf(column)
+ if column != nil && column_v.Kind() != reflect.Slice {
+ panic("parameter column must be a slice")
+ }
+ if column != nil {
+ column_ptr = unsafe.Pointer(column_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_3_glSeparableFilter2D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), row_ptr, column_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetSeparableFilter.xml
+func (gl *GL) GetSeparableFilter(target, format, gltype glbase.Enum, row, column, span interface{}) {
+ var row_ptr unsafe.Pointer
+ var row_v = reflect.ValueOf(row)
+ if row != nil && row_v.Kind() != reflect.Slice {
+ panic("parameter row must be a slice")
+ }
+ if row != nil {
+ row_ptr = unsafe.Pointer(row_v.Index(0).Addr().Pointer())
+ }
+ var column_ptr unsafe.Pointer
+ var column_v = reflect.ValueOf(column)
+ if column != nil && column_v.Kind() != reflect.Slice {
+ panic("parameter column must be a slice")
+ }
+ if column != nil {
+ column_ptr = unsafe.Pointer(column_v.Index(0).Addr().Pointer())
+ }
+ var span_ptr unsafe.Pointer
+ var span_v = reflect.ValueOf(span)
+ if span != nil && span_v.Kind() != reflect.Slice {
+ panic("parameter span must be a slice")
+ }
+ if span != nil {
+ span_ptr = unsafe.Pointer(span_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_3_glGetSeparableFilter(gl.funcs, C.GLenum(target), C.GLenum(format), C.GLenum(gltype), row_ptr, column_ptr, span_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetConvolutionParameteriv.xml
+func (gl *GL) GetConvolutionParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl1_3_glGetConvolutionParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetConvolutionParameterfv.xml
+func (gl *GL) GetConvolutionParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl1_3_glGetConvolutionParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetConvolutionFilter.xml
+func (gl *GL) GetConvolutionFilter(target, format, gltype glbase.Enum, image interface{}) {
+ var image_ptr unsafe.Pointer
+ var image_v = reflect.ValueOf(image)
+ if image != nil && image_v.Kind() != reflect.Slice {
+ panic("parameter image must be a slice")
+ }
+ if image != nil {
+ image_ptr = unsafe.Pointer(image_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_3_glGetConvolutionFilter(gl.funcs, C.GLenum(target), C.GLenum(format), C.GLenum(gltype), image_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyConvolutionFilter2D.xml
+func (gl *GL) CopyConvolutionFilter2D(target, internalFormat glbase.Enum, x, y, width, height int) {
+ C.gl1_3_glCopyConvolutionFilter2D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyConvolutionFilter1D.xml
+func (gl *GL) CopyConvolutionFilter1D(target, internalFormat glbase.Enum, x, y, width int) {
+ C.gl1_3_glCopyConvolutionFilter1D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glConvolutionParameteriv.xml
+func (gl *GL) ConvolutionParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl1_3_glConvolutionParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glConvolutionParameteri.xml
+func (gl *GL) ConvolutionParameteri(target, pname glbase.Enum, params int32) {
+ C.gl1_3_glConvolutionParameteri(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLint(params))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glConvolutionParameterfv.xml
+func (gl *GL) ConvolutionParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl1_3_glConvolutionParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glConvolutionParameterf.xml
+func (gl *GL) ConvolutionParameterf(target, pname glbase.Enum, params float32) {
+ C.gl1_3_glConvolutionParameterf(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLfloat(params))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glConvolutionFilter2D.xml
+func (gl *GL) ConvolutionFilter2D(target, internalFormat glbase.Enum, width, height int, format, gltype glbase.Enum, image interface{}) {
+ var image_ptr unsafe.Pointer
+ var image_v = reflect.ValueOf(image)
+ if image != nil && image_v.Kind() != reflect.Slice {
+ panic("parameter image must be a slice")
+ }
+ if image != nil {
+ image_ptr = unsafe.Pointer(image_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_3_glConvolutionFilter2D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), image_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glConvolutionFilter1D.xml
+func (gl *GL) ConvolutionFilter1D(target, internalFormat glbase.Enum, width int, format, gltype glbase.Enum, image interface{}) {
+ var image_ptr unsafe.Pointer
+ var image_v = reflect.ValueOf(image)
+ if image != nil && image_v.Kind() != reflect.Slice {
+ panic("parameter image must be a slice")
+ }
+ if image != nil {
+ image_ptr = unsafe.Pointer(image_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_3_glConvolutionFilter1D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLenum(format), C.GLenum(gltype), image_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyColorSubTable.xml
+func (gl *GL) CopyColorSubTable(target glbase.Enum, start int32, x, y, width int) {
+ C.gl1_3_glCopyColorSubTable(gl.funcs, C.GLenum(target), C.GLsizei(start), C.GLint(x), C.GLint(y), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColorSubTable.xml
+func (gl *GL) ColorSubTable(target glbase.Enum, start int32, count int, format, gltype glbase.Enum, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_3_glColorSubTable(gl.funcs, C.GLenum(target), C.GLsizei(start), C.GLsizei(count), C.GLenum(format), C.GLenum(gltype), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetColorTableParameteriv.xml
+func (gl *GL) GetColorTableParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl1_3_glGetColorTableParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetColorTableParameterfv.xml
+func (gl *GL) GetColorTableParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl1_3_glGetColorTableParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetColorTable.xml
+func (gl *GL) GetColorTable(target, format, gltype glbase.Enum, table interface{}) {
+ var table_ptr unsafe.Pointer
+ var table_v = reflect.ValueOf(table)
+ if table != nil && table_v.Kind() != reflect.Slice {
+ panic("parameter table must be a slice")
+ }
+ if table != nil {
+ table_ptr = unsafe.Pointer(table_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_3_glGetColorTable(gl.funcs, C.GLenum(target), C.GLenum(format), C.GLenum(gltype), table_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyColorTable.xml
+func (gl *GL) CopyColorTable(target, internalFormat glbase.Enum, x, y, width int) {
+ C.gl1_3_glCopyColorTable(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColorTableParameteriv.xml
+func (gl *GL) ColorTableParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl1_3_glColorTableParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColorTableParameterfv.xml
+func (gl *GL) ColorTableParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl1_3_glColorTableParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColorTable.xml
+func (gl *GL) ColorTable(target, internalFormat glbase.Enum, width int, format, gltype glbase.Enum, table interface{}) {
+ var table_ptr unsafe.Pointer
+ var table_v = reflect.ValueOf(table)
+ if table != nil && table_v.Kind() != reflect.Slice {
+ panic("parameter table must be a slice")
+ }
+ if table != nil {
+ table_ptr = unsafe.Pointer(table_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_3_glColorTable(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLenum(format), C.GLenum(gltype), table_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultTransposeMatrixd.xml
+func (gl *GL) MultTransposeMatrixd(m []float64) {
+ C.gl1_3_glMultTransposeMatrixd(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultTransposeMatrixf.xml
+func (gl *GL) MultTransposeMatrixf(m []float32) {
+ C.gl1_3_glMultTransposeMatrixf(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLoadTransposeMatrixd.xml
+func (gl *GL) LoadTransposeMatrixd(m []float64) {
+ C.gl1_3_glLoadTransposeMatrixd(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLoadTransposeMatrixf.xml
+func (gl *GL) LoadTransposeMatrixf(m []float32) {
+ C.gl1_3_glLoadTransposeMatrixf(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord4sv.xml
+func (gl *GL) MultiTexCoord4sv(target glbase.Enum, v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_3_glMultiTexCoord4sv(gl.funcs, C.GLenum(target), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord4s.xml
+func (gl *GL) MultiTexCoord4s(target glbase.Enum, s, t, r, q int16) {
+ C.gl1_3_glMultiTexCoord4s(gl.funcs, C.GLenum(target), C.GLshort(s), C.GLshort(t), C.GLshort(r), C.GLshort(q))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord4iv.xml
+func (gl *GL) MultiTexCoord4iv(target glbase.Enum, v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_3_glMultiTexCoord4iv(gl.funcs, C.GLenum(target), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord4i.xml
+func (gl *GL) MultiTexCoord4i(target glbase.Enum, s, t, r, q int32) {
+ C.gl1_3_glMultiTexCoord4i(gl.funcs, C.GLenum(target), C.GLint(s), C.GLint(t), C.GLint(r), C.GLint(q))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord4fv.xml
+func (gl *GL) MultiTexCoord4fv(target glbase.Enum, v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_3_glMultiTexCoord4fv(gl.funcs, C.GLenum(target), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord4f.xml
+func (gl *GL) MultiTexCoord4f(target glbase.Enum, s, t, r, q float32) {
+ C.gl1_3_glMultiTexCoord4f(gl.funcs, C.GLenum(target), C.GLfloat(s), C.GLfloat(t), C.GLfloat(r), C.GLfloat(q))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord4dv.xml
+func (gl *GL) MultiTexCoord4dv(target glbase.Enum, v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_3_glMultiTexCoord4dv(gl.funcs, C.GLenum(target), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord4d.xml
+func (gl *GL) MultiTexCoord4d(target glbase.Enum, s, t, r, q float64) {
+ C.gl1_3_glMultiTexCoord4d(gl.funcs, C.GLenum(target), C.GLdouble(s), C.GLdouble(t), C.GLdouble(r), C.GLdouble(q))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord3sv.xml
+func (gl *GL) MultiTexCoord3sv(target glbase.Enum, v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_3_glMultiTexCoord3sv(gl.funcs, C.GLenum(target), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord3s.xml
+func (gl *GL) MultiTexCoord3s(target glbase.Enum, s, t, r int16) {
+ C.gl1_3_glMultiTexCoord3s(gl.funcs, C.GLenum(target), C.GLshort(s), C.GLshort(t), C.GLshort(r))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord3iv.xml
+func (gl *GL) MultiTexCoord3iv(target glbase.Enum, v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_3_glMultiTexCoord3iv(gl.funcs, C.GLenum(target), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord3i.xml
+func (gl *GL) MultiTexCoord3i(target glbase.Enum, s, t, r int32) {
+ C.gl1_3_glMultiTexCoord3i(gl.funcs, C.GLenum(target), C.GLint(s), C.GLint(t), C.GLint(r))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord3fv.xml
+func (gl *GL) MultiTexCoord3fv(target glbase.Enum, v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_3_glMultiTexCoord3fv(gl.funcs, C.GLenum(target), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord3f.xml
+func (gl *GL) MultiTexCoord3f(target glbase.Enum, s, t, r float32) {
+ C.gl1_3_glMultiTexCoord3f(gl.funcs, C.GLenum(target), C.GLfloat(s), C.GLfloat(t), C.GLfloat(r))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord3dv.xml
+func (gl *GL) MultiTexCoord3dv(target glbase.Enum, v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_3_glMultiTexCoord3dv(gl.funcs, C.GLenum(target), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord3d.xml
+func (gl *GL) MultiTexCoord3d(target glbase.Enum, s, t, r float64) {
+ C.gl1_3_glMultiTexCoord3d(gl.funcs, C.GLenum(target), C.GLdouble(s), C.GLdouble(t), C.GLdouble(r))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord2sv.xml
+func (gl *GL) MultiTexCoord2sv(target glbase.Enum, v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_3_glMultiTexCoord2sv(gl.funcs, C.GLenum(target), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord2s.xml
+func (gl *GL) MultiTexCoord2s(target glbase.Enum, s, t int16) {
+ C.gl1_3_glMultiTexCoord2s(gl.funcs, C.GLenum(target), C.GLshort(s), C.GLshort(t))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord2iv.xml
+func (gl *GL) MultiTexCoord2iv(target glbase.Enum, v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_3_glMultiTexCoord2iv(gl.funcs, C.GLenum(target), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord2i.xml
+func (gl *GL) MultiTexCoord2i(target glbase.Enum, s, t int32) {
+ C.gl1_3_glMultiTexCoord2i(gl.funcs, C.GLenum(target), C.GLint(s), C.GLint(t))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord2fv.xml
+func (gl *GL) MultiTexCoord2fv(target glbase.Enum, v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_3_glMultiTexCoord2fv(gl.funcs, C.GLenum(target), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord2f.xml
+func (gl *GL) MultiTexCoord2f(target glbase.Enum, s, t float32) {
+ C.gl1_3_glMultiTexCoord2f(gl.funcs, C.GLenum(target), C.GLfloat(s), C.GLfloat(t))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord2dv.xml
+func (gl *GL) MultiTexCoord2dv(target glbase.Enum, v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_3_glMultiTexCoord2dv(gl.funcs, C.GLenum(target), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord2d.xml
+func (gl *GL) MultiTexCoord2d(target glbase.Enum, s, t float64) {
+ C.gl1_3_glMultiTexCoord2d(gl.funcs, C.GLenum(target), C.GLdouble(s), C.GLdouble(t))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord1sv.xml
+func (gl *GL) MultiTexCoord1sv(target glbase.Enum, v []int16) {
+ C.gl1_3_glMultiTexCoord1sv(gl.funcs, C.GLenum(target), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord1s.xml
+func (gl *GL) MultiTexCoord1s(target glbase.Enum, s int16) {
+ C.gl1_3_glMultiTexCoord1s(gl.funcs, C.GLenum(target), C.GLshort(s))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord1iv.xml
+func (gl *GL) MultiTexCoord1iv(target glbase.Enum, v []int32) {
+ C.gl1_3_glMultiTexCoord1iv(gl.funcs, C.GLenum(target), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord1i.xml
+func (gl *GL) MultiTexCoord1i(target glbase.Enum, s int32) {
+ C.gl1_3_glMultiTexCoord1i(gl.funcs, C.GLenum(target), C.GLint(s))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord1fv.xml
+func (gl *GL) MultiTexCoord1fv(target glbase.Enum, v []float32) {
+ C.gl1_3_glMultiTexCoord1fv(gl.funcs, C.GLenum(target), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord1f.xml
+func (gl *GL) MultiTexCoord1f(target glbase.Enum, s float32) {
+ C.gl1_3_glMultiTexCoord1f(gl.funcs, C.GLenum(target), C.GLfloat(s))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord1dv.xml
+func (gl *GL) MultiTexCoord1dv(target glbase.Enum, v []float64) {
+ C.gl1_3_glMultiTexCoord1dv(gl.funcs, C.GLenum(target), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord1d.xml
+func (gl *GL) MultiTexCoord1d(target glbase.Enum, s float64) {
+ C.gl1_3_glMultiTexCoord1d(gl.funcs, C.GLenum(target), C.GLdouble(s))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClientActiveTexture.xml
+func (gl *GL) ClientActiveTexture(texture glbase.Enum) {
+ C.gl1_3_glClientActiveTexture(gl.funcs, C.GLenum(texture))
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/1.4/funcs.cpp b/Godeps/_workspace/src/github.com/obscuren/qml/gl/1.4/funcs.cpp
new file mode 100644
index 000000000..0aed105f5
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/1.4/funcs.cpp
@@ -0,0 +1,2790 @@
+
+// ** file automatically generated by glgen -- do not edit manually **
+
+#include <QOpenGLContext>
+#include <QtGui/qopenglfunctions_1_4.h>
+
+#include "funcs.h"
+
+void *gl1_4_funcs() {
+ QOpenGLFunctions_1_4* funcs = QOpenGLContext::currentContext()->versionFunctions<QOpenGLFunctions_1_4>();
+ if (!funcs) {
+ return 0;
+ }
+ funcs->initializeOpenGLFunctions();
+ return funcs;
+}
+
+
+void gl1_4_glViewport(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glViewport(x, y, width, height);
+}
+
+void gl1_4_glDepthRange(void *_glfuncs, GLdouble nearVal, GLdouble farVal)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glDepthRange(nearVal, farVal);
+}
+
+GLboolean gl1_4_glIsEnabled(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ return _qglfuncs->glIsEnabled(cap);
+}
+
+void gl1_4_glGetTexLevelParameteriv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glGetTexLevelParameteriv(target, level, pname, params);
+}
+
+void gl1_4_glGetTexLevelParameterfv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glGetTexLevelParameterfv(target, level, pname, params);
+}
+
+void gl1_4_glGetTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glGetTexParameteriv(target, pname, params);
+}
+
+void gl1_4_glGetTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glGetTexParameterfv(target, pname, params);
+}
+
+void gl1_4_glGetTexImage(void *_glfuncs, GLenum target, GLint level, GLenum format, GLenum gltype, GLvoid* pixels)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glGetTexImage(target, level, format, gltype, pixels);
+}
+
+void gl1_4_glGetIntegerv(void *_glfuncs, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glGetIntegerv(pname, params);
+}
+
+void gl1_4_glGetFloatv(void *_glfuncs, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glGetFloatv(pname, params);
+}
+
+GLenum gl1_4_glGetError(void *_glfuncs)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ return _qglfuncs->glGetError();
+}
+
+void gl1_4_glGetDoublev(void *_glfuncs, GLenum pname, GLdouble* params)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glGetDoublev(pname, params);
+}
+
+void gl1_4_glGetBooleanv(void *_glfuncs, GLenum pname, GLboolean* params)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glGetBooleanv(pname, params);
+}
+
+void gl1_4_glReadPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum gltype, GLvoid* pixels)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glReadPixels(x, y, width, height, format, gltype, pixels);
+}
+
+void gl1_4_glReadBuffer(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glReadBuffer(mode);
+}
+
+void gl1_4_glPixelStorei(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glPixelStorei(pname, param);
+}
+
+void gl1_4_glPixelStoref(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glPixelStoref(pname, param);
+}
+
+void gl1_4_glDepthFunc(void *_glfuncs, GLenum glfunc)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glDepthFunc(glfunc);
+}
+
+void gl1_4_glStencilOp(void *_glfuncs, GLenum fail, GLenum zfail, GLenum zpass)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glStencilOp(fail, zfail, zpass);
+}
+
+void gl1_4_glStencilFunc(void *_glfuncs, GLenum glfunc, GLint ref, GLuint mask)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glStencilFunc(glfunc, ref, mask);
+}
+
+void gl1_4_glLogicOp(void *_glfuncs, GLenum opcode)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glLogicOp(opcode);
+}
+
+void gl1_4_glBlendFunc(void *_glfuncs, GLenum sfactor, GLenum dfactor)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glBlendFunc(sfactor, dfactor);
+}
+
+void gl1_4_glFlush(void *_glfuncs)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glFlush();
+}
+
+void gl1_4_glFinish(void *_glfuncs)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glFinish();
+}
+
+void gl1_4_glEnable(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glEnable(cap);
+}
+
+void gl1_4_glDisable(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glDisable(cap);
+}
+
+void gl1_4_glDepthMask(void *_glfuncs, GLboolean flag)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glDepthMask(flag);
+}
+
+void gl1_4_glColorMask(void *_glfuncs, GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glColorMask(red, green, blue, alpha);
+}
+
+void gl1_4_glStencilMask(void *_glfuncs, GLuint mask)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glStencilMask(mask);
+}
+
+void gl1_4_glClearDepth(void *_glfuncs, GLdouble depth)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glClearDepth(depth);
+}
+
+void gl1_4_glClearStencil(void *_glfuncs, GLint s)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glClearStencil(s);
+}
+
+void gl1_4_glClearColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glClearColor(red, green, blue, alpha);
+}
+
+void gl1_4_glClear(void *_glfuncs, GLbitfield mask)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glClear(mask);
+}
+
+void gl1_4_glDrawBuffer(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glDrawBuffer(mode);
+}
+
+void gl1_4_glTexImage2D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glTexImage2D(target, level, internalFormat, width, height, border, format, gltype, pixels);
+}
+
+void gl1_4_glTexImage1D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glTexImage1D(target, level, internalFormat, width, border, format, gltype, pixels);
+}
+
+void gl1_4_glTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glTexParameteriv(target, pname, params);
+}
+
+void gl1_4_glTexParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glTexParameteri(target, pname, param);
+}
+
+void gl1_4_glTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glTexParameterfv(target, pname, params);
+}
+
+void gl1_4_glTexParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glTexParameterf(target, pname, param);
+}
+
+void gl1_4_glScissor(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glScissor(x, y, width, height);
+}
+
+void gl1_4_glPolygonMode(void *_glfuncs, GLenum face, GLenum mode)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glPolygonMode(face, mode);
+}
+
+void gl1_4_glPointSize(void *_glfuncs, GLfloat size)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glPointSize(size);
+}
+
+void gl1_4_glLineWidth(void *_glfuncs, GLfloat width)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glLineWidth(width);
+}
+
+void gl1_4_glHint(void *_glfuncs, GLenum target, GLenum mode)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glHint(target, mode);
+}
+
+void gl1_4_glFrontFace(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glFrontFace(mode);
+}
+
+void gl1_4_glCullFace(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glCullFace(mode);
+}
+
+void gl1_4_glIndexubv(void *_glfuncs, const GLubyte* c)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glIndexubv(c);
+}
+
+void gl1_4_glIndexub(void *_glfuncs, GLubyte c)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glIndexub(c);
+}
+
+GLboolean gl1_4_glIsTexture(void *_glfuncs, GLuint texture)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ return _qglfuncs->glIsTexture(texture);
+}
+
+void gl1_4_glGenTextures(void *_glfuncs, GLsizei n, GLuint* textures)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glGenTextures(n, textures);
+}
+
+void gl1_4_glDeleteTextures(void *_glfuncs, GLsizei n, const GLuint* textures)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glDeleteTextures(n, textures);
+}
+
+void gl1_4_glBindTexture(void *_glfuncs, GLenum target, GLuint texture)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glBindTexture(target, texture);
+}
+
+void gl1_4_glTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glTexSubImage2D(target, level, xoffset, yoffset, width, height, format, gltype, pixels);
+}
+
+void gl1_4_glTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glTexSubImage1D(target, level, xoffset, width, format, gltype, pixels);
+}
+
+void gl1_4_glCopyTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage2D(target, level, xoffset, yoffset, x, y, width, height);
+}
+
+void gl1_4_glCopyTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage1D(target, level, xoffset, x, y, width);
+}
+
+void gl1_4_glCopyTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glCopyTexImage2D(target, level, internalFormat, x, y, width, height, border);
+}
+
+void gl1_4_glCopyTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLint border)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glCopyTexImage1D(target, level, internalFormat, x, y, width, border);
+}
+
+void gl1_4_glPolygonOffset(void *_glfuncs, GLfloat factor, GLfloat units)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glPolygonOffset(factor, units);
+}
+
+void gl1_4_glDrawElements(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glDrawElements(mode, count, gltype, indices);
+}
+
+void gl1_4_glDrawArrays(void *_glfuncs, GLenum mode, GLint first, GLsizei count)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glDrawArrays(mode, first, count);
+}
+
+void gl1_4_glCopyTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage3D(target, level, xoffset, yoffset, zoffset, x, y, width, height);
+}
+
+void gl1_4_glTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glTexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, gltype, pixels);
+}
+
+void gl1_4_glTexImage3D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glTexImage3D(target, level, internalFormat, width, height, depth, border, format, gltype, pixels);
+}
+
+void gl1_4_glDrawRangeElements(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glDrawRangeElements(mode, start, end, count, gltype, indices);
+}
+
+void gl1_4_glBlendEquation(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glBlendEquation(mode);
+}
+
+void gl1_4_glBlendColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glBlendColor(red, green, blue, alpha);
+}
+
+void gl1_4_glGetCompressedTexImage(void *_glfuncs, GLenum target, GLint level, GLvoid* img)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glGetCompressedTexImage(target, level, img);
+}
+
+void gl1_4_glCompressedTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glCompressedTexSubImage1D(target, level, xoffset, width, format, imageSize, data);
+}
+
+void gl1_4_glCompressedTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glCompressedTexSubImage2D(target, level, xoffset, yoffset, width, height, format, imageSize, data);
+}
+
+void gl1_4_glCompressedTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glCompressedTexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, imageSize, data);
+}
+
+void gl1_4_glCompressedTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glCompressedTexImage1D(target, level, internalFormat, width, border, imageSize, data);
+}
+
+void gl1_4_glCompressedTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glCompressedTexImage2D(target, level, internalFormat, width, height, border, imageSize, data);
+}
+
+void gl1_4_glCompressedTexImage3D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glCompressedTexImage3D(target, level, internalFormat, width, height, depth, border, imageSize, data);
+}
+
+void gl1_4_glSampleCoverage(void *_glfuncs, GLfloat value, GLboolean invert)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glSampleCoverage(value, invert);
+}
+
+void gl1_4_glActiveTexture(void *_glfuncs, GLenum texture)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glActiveTexture(texture);
+}
+
+void gl1_4_glPointParameteriv(void *_glfuncs, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glPointParameteriv(pname, params);
+}
+
+void gl1_4_glPointParameteri(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glPointParameteri(pname, param);
+}
+
+void gl1_4_glPointParameterfv(void *_glfuncs, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glPointParameterfv(pname, params);
+}
+
+void gl1_4_glPointParameterf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glPointParameterf(pname, param);
+}
+
+void gl1_4_glMultiDrawArrays(void *_glfuncs, GLenum mode, const GLint* first, const GLsizei* count, GLsizei drawcount)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glMultiDrawArrays(mode, first, count, drawcount);
+}
+
+void gl1_4_glBlendFuncSeparate(void *_glfuncs, GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glBlendFuncSeparate(sfactorRGB, dfactorRGB, sfactorAlpha, dfactorAlpha);
+}
+
+void gl1_4_glTranslatef(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glTranslatef(x, y, z);
+}
+
+void gl1_4_glTranslated(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glTranslated(x, y, z);
+}
+
+void gl1_4_glScalef(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glScalef(x, y, z);
+}
+
+void gl1_4_glScaled(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glScaled(x, y, z);
+}
+
+void gl1_4_glRotatef(void *_glfuncs, GLfloat angle, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glRotatef(angle, x, y, z);
+}
+
+void gl1_4_glRotated(void *_glfuncs, GLdouble angle, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glRotated(angle, x, y, z);
+}
+
+void gl1_4_glPushMatrix(void *_glfuncs)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glPushMatrix();
+}
+
+void gl1_4_glPopMatrix(void *_glfuncs)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glPopMatrix();
+}
+
+void gl1_4_glOrtho(void *_glfuncs, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glOrtho(left, right, bottom, top, zNear, zFar);
+}
+
+void gl1_4_glMultMatrixd(void *_glfuncs, const GLdouble* m)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glMultMatrixd(m);
+}
+
+void gl1_4_glMultMatrixf(void *_glfuncs, const GLfloat* m)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glMultMatrixf(m);
+}
+
+void gl1_4_glMatrixMode(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glMatrixMode(mode);
+}
+
+void gl1_4_glLoadMatrixd(void *_glfuncs, const GLdouble* m)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glLoadMatrixd(m);
+}
+
+void gl1_4_glLoadMatrixf(void *_glfuncs, const GLfloat* m)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glLoadMatrixf(m);
+}
+
+void gl1_4_glLoadIdentity(void *_glfuncs)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glLoadIdentity();
+}
+
+void gl1_4_glFrustum(void *_glfuncs, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glFrustum(left, right, bottom, top, zNear, zFar);
+}
+
+GLboolean gl1_4_glIsList(void *_glfuncs, GLuint list)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ return _qglfuncs->glIsList(list);
+}
+
+void gl1_4_glGetTexGeniv(void *_glfuncs, GLenum coord, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glGetTexGeniv(coord, pname, params);
+}
+
+void gl1_4_glGetTexGenfv(void *_glfuncs, GLenum coord, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glGetTexGenfv(coord, pname, params);
+}
+
+void gl1_4_glGetTexGendv(void *_glfuncs, GLenum coord, GLenum pname, GLdouble* params)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glGetTexGendv(coord, pname, params);
+}
+
+void gl1_4_glGetTexEnviv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glGetTexEnviv(target, pname, params);
+}
+
+void gl1_4_glGetTexEnvfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glGetTexEnvfv(target, pname, params);
+}
+
+void gl1_4_glGetPolygonStipple(void *_glfuncs, GLubyte* mask)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glGetPolygonStipple(mask);
+}
+
+void gl1_4_glGetPixelMapusv(void *_glfuncs, GLenum glmap, GLushort* values)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glGetPixelMapusv(glmap, values);
+}
+
+void gl1_4_glGetPixelMapuiv(void *_glfuncs, GLenum glmap, GLuint* values)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glGetPixelMapuiv(glmap, values);
+}
+
+void gl1_4_glGetPixelMapfv(void *_glfuncs, GLenum glmap, GLfloat* values)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glGetPixelMapfv(glmap, values);
+}
+
+void gl1_4_glGetMaterialiv(void *_glfuncs, GLenum face, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glGetMaterialiv(face, pname, params);
+}
+
+void gl1_4_glGetMaterialfv(void *_glfuncs, GLenum face, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glGetMaterialfv(face, pname, params);
+}
+
+void gl1_4_glGetMapiv(void *_glfuncs, GLenum target, GLenum query, GLint* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glGetMapiv(target, query, v);
+}
+
+void gl1_4_glGetMapfv(void *_glfuncs, GLenum target, GLenum query, GLfloat* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glGetMapfv(target, query, v);
+}
+
+void gl1_4_glGetMapdv(void *_glfuncs, GLenum target, GLenum query, GLdouble* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glGetMapdv(target, query, v);
+}
+
+void gl1_4_glGetLightiv(void *_glfuncs, GLenum light, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glGetLightiv(light, pname, params);
+}
+
+void gl1_4_glGetLightfv(void *_glfuncs, GLenum light, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glGetLightfv(light, pname, params);
+}
+
+void gl1_4_glGetClipPlane(void *_glfuncs, GLenum plane, GLdouble* equation)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glGetClipPlane(plane, equation);
+}
+
+void gl1_4_glDrawPixels(void *_glfuncs, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glDrawPixels(width, height, format, gltype, pixels);
+}
+
+void gl1_4_glCopyPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum gltype)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glCopyPixels(x, y, width, height, gltype);
+}
+
+void gl1_4_glPixelMapusv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLushort* values)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glPixelMapusv(glmap, mapsize, values);
+}
+
+void gl1_4_glPixelMapuiv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLuint* values)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glPixelMapuiv(glmap, mapsize, values);
+}
+
+void gl1_4_glPixelMapfv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLfloat* values)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glPixelMapfv(glmap, mapsize, values);
+}
+
+void gl1_4_glPixelTransferi(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glPixelTransferi(pname, param);
+}
+
+void gl1_4_glPixelTransferf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glPixelTransferf(pname, param);
+}
+
+void gl1_4_glPixelZoom(void *_glfuncs, GLfloat xfactor, GLfloat yfactor)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glPixelZoom(xfactor, yfactor);
+}
+
+void gl1_4_glAlphaFunc(void *_glfuncs, GLenum glfunc, GLfloat ref)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glAlphaFunc(glfunc, ref);
+}
+
+void gl1_4_glEvalPoint2(void *_glfuncs, GLint i, GLint j)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glEvalPoint2(i, j);
+}
+
+void gl1_4_glEvalMesh2(void *_glfuncs, GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glEvalMesh2(mode, i1, i2, j1, j2);
+}
+
+void gl1_4_glEvalPoint1(void *_glfuncs, GLint i)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glEvalPoint1(i);
+}
+
+void gl1_4_glEvalMesh1(void *_glfuncs, GLenum mode, GLint i1, GLint i2)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glEvalMesh1(mode, i1, i2);
+}
+
+void gl1_4_glEvalCoord2fv(void *_glfuncs, const GLfloat* u)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glEvalCoord2fv(u);
+}
+
+void gl1_4_glEvalCoord2f(void *_glfuncs, GLfloat u, GLfloat v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glEvalCoord2f(u, v);
+}
+
+void gl1_4_glEvalCoord2dv(void *_glfuncs, const GLdouble* u)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glEvalCoord2dv(u);
+}
+
+void gl1_4_glEvalCoord2d(void *_glfuncs, GLdouble u, GLdouble v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glEvalCoord2d(u, v);
+}
+
+void gl1_4_glEvalCoord1fv(void *_glfuncs, const GLfloat* u)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glEvalCoord1fv(u);
+}
+
+void gl1_4_glEvalCoord1f(void *_glfuncs, GLfloat u)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glEvalCoord1f(u);
+}
+
+void gl1_4_glEvalCoord1dv(void *_glfuncs, const GLdouble* u)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glEvalCoord1dv(u);
+}
+
+void gl1_4_glEvalCoord1d(void *_glfuncs, GLdouble u)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glEvalCoord1d(u);
+}
+
+void gl1_4_glMapGrid2f(void *_glfuncs, GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glMapGrid2f(un, u1, u2, vn, v1, v2);
+}
+
+void gl1_4_glMapGrid2d(void *_glfuncs, GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glMapGrid2d(un, u1, u2, vn, v1, v2);
+}
+
+void gl1_4_glMapGrid1f(void *_glfuncs, GLint un, GLfloat u1, GLfloat u2)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glMapGrid1f(un, u1, u2);
+}
+
+void gl1_4_glMapGrid1d(void *_glfuncs, GLint un, GLdouble u1, GLdouble u2)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glMapGrid1d(un, u1, u2);
+}
+
+void gl1_4_glMap2f(void *_glfuncs, GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat* points)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glMap2f(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+void gl1_4_glMap2d(void *_glfuncs, GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble* points)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glMap2d(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+void gl1_4_glMap1f(void *_glfuncs, GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat* points)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glMap1f(target, u1, u2, stride, order, points);
+}
+
+void gl1_4_glMap1d(void *_glfuncs, GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble* points)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glMap1d(target, u1, u2, stride, order, points);
+}
+
+void gl1_4_glPushAttrib(void *_glfuncs, GLbitfield mask)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glPushAttrib(mask);
+}
+
+void gl1_4_glPopAttrib(void *_glfuncs)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glPopAttrib();
+}
+
+void gl1_4_glAccum(void *_glfuncs, GLenum op, GLfloat value)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glAccum(op, value);
+}
+
+void gl1_4_glIndexMask(void *_glfuncs, GLuint mask)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glIndexMask(mask);
+}
+
+void gl1_4_glClearIndex(void *_glfuncs, GLfloat c)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glClearIndex(c);
+}
+
+void gl1_4_glClearAccum(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glClearAccum(red, green, blue, alpha);
+}
+
+void gl1_4_glPushName(void *_glfuncs, GLuint name)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glPushName(name);
+}
+
+void gl1_4_glPopName(void *_glfuncs)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glPopName();
+}
+
+void gl1_4_glPassThrough(void *_glfuncs, GLfloat token)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glPassThrough(token);
+}
+
+void gl1_4_glLoadName(void *_glfuncs, GLuint name)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glLoadName(name);
+}
+
+void gl1_4_glInitNames(void *_glfuncs)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glInitNames();
+}
+
+GLint gl1_4_glRenderMode(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ return _qglfuncs->glRenderMode(mode);
+}
+
+void gl1_4_glSelectBuffer(void *_glfuncs, GLsizei size, GLuint* buffer)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glSelectBuffer(size, buffer);
+}
+
+void gl1_4_glFeedbackBuffer(void *_glfuncs, GLsizei size, GLenum gltype, GLfloat* buffer)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glFeedbackBuffer(size, gltype, buffer);
+}
+
+void gl1_4_glTexGeniv(void *_glfuncs, GLenum coord, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glTexGeniv(coord, pname, params);
+}
+
+void gl1_4_glTexGeni(void *_glfuncs, GLenum coord, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glTexGeni(coord, pname, param);
+}
+
+void gl1_4_glTexGenfv(void *_glfuncs, GLenum coord, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glTexGenfv(coord, pname, params);
+}
+
+void gl1_4_glTexGenf(void *_glfuncs, GLenum coord, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glTexGenf(coord, pname, param);
+}
+
+void gl1_4_glTexGendv(void *_glfuncs, GLenum coord, GLenum pname, const GLdouble* params)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glTexGendv(coord, pname, params);
+}
+
+void gl1_4_glTexGend(void *_glfuncs, GLenum coord, GLenum pname, GLdouble param)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glTexGend(coord, pname, param);
+}
+
+void gl1_4_glTexEnviv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glTexEnviv(target, pname, params);
+}
+
+void gl1_4_glTexEnvi(void *_glfuncs, GLenum target, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glTexEnvi(target, pname, param);
+}
+
+void gl1_4_glTexEnvfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glTexEnvfv(target, pname, params);
+}
+
+void gl1_4_glTexEnvf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glTexEnvf(target, pname, param);
+}
+
+void gl1_4_glShadeModel(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glShadeModel(mode);
+}
+
+void gl1_4_glPolygonStipple(void *_glfuncs, const GLubyte* mask)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glPolygonStipple(mask);
+}
+
+void gl1_4_glMaterialiv(void *_glfuncs, GLenum face, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glMaterialiv(face, pname, params);
+}
+
+void gl1_4_glMateriali(void *_glfuncs, GLenum face, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glMateriali(face, pname, param);
+}
+
+void gl1_4_glMaterialfv(void *_glfuncs, GLenum face, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glMaterialfv(face, pname, params);
+}
+
+void gl1_4_glMaterialf(void *_glfuncs, GLenum face, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glMaterialf(face, pname, param);
+}
+
+void gl1_4_glLineStipple(void *_glfuncs, GLint factor, GLushort pattern)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glLineStipple(factor, pattern);
+}
+
+void gl1_4_glLightModeliv(void *_glfuncs, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glLightModeliv(pname, params);
+}
+
+void gl1_4_glLightModeli(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glLightModeli(pname, param);
+}
+
+void gl1_4_glLightModelfv(void *_glfuncs, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glLightModelfv(pname, params);
+}
+
+void gl1_4_glLightModelf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glLightModelf(pname, param);
+}
+
+void gl1_4_glLightiv(void *_glfuncs, GLenum light, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glLightiv(light, pname, params);
+}
+
+void gl1_4_glLighti(void *_glfuncs, GLenum light, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glLighti(light, pname, param);
+}
+
+void gl1_4_glLightfv(void *_glfuncs, GLenum light, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glLightfv(light, pname, params);
+}
+
+void gl1_4_glLightf(void *_glfuncs, GLenum light, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glLightf(light, pname, param);
+}
+
+void gl1_4_glFogiv(void *_glfuncs, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glFogiv(pname, params);
+}
+
+void gl1_4_glFogi(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glFogi(pname, param);
+}
+
+void gl1_4_glFogfv(void *_glfuncs, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glFogfv(pname, params);
+}
+
+void gl1_4_glFogf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glFogf(pname, param);
+}
+
+void gl1_4_glColorMaterial(void *_glfuncs, GLenum face, GLenum mode)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glColorMaterial(face, mode);
+}
+
+void gl1_4_glClipPlane(void *_glfuncs, GLenum plane, const GLdouble* equation)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glClipPlane(plane, equation);
+}
+
+void gl1_4_glVertex4sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glVertex4sv(v);
+}
+
+void gl1_4_glVertex4s(void *_glfuncs, GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glVertex4s(x, y, z, w);
+}
+
+void gl1_4_glVertex4iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glVertex4iv(v);
+}
+
+void gl1_4_glVertex4i(void *_glfuncs, GLint x, GLint y, GLint z, GLint w)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glVertex4i(x, y, z, w);
+}
+
+void gl1_4_glVertex4fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glVertex4fv(v);
+}
+
+void gl1_4_glVertex4f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glVertex4f(x, y, z, w);
+}
+
+void gl1_4_glVertex4dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glVertex4dv(v);
+}
+
+void gl1_4_glVertex4d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glVertex4d(x, y, z, w);
+}
+
+void gl1_4_glVertex3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glVertex3sv(v);
+}
+
+void gl1_4_glVertex3s(void *_glfuncs, GLshort x, GLshort y, GLshort z)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glVertex3s(x, y, z);
+}
+
+void gl1_4_glVertex3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glVertex3iv(v);
+}
+
+void gl1_4_glVertex3i(void *_glfuncs, GLint x, GLint y, GLint z)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glVertex3i(x, y, z);
+}
+
+void gl1_4_glVertex3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glVertex3fv(v);
+}
+
+void gl1_4_glVertex3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glVertex3f(x, y, z);
+}
+
+void gl1_4_glVertex3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glVertex3dv(v);
+}
+
+void gl1_4_glVertex3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glVertex3d(x, y, z);
+}
+
+void gl1_4_glVertex2sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glVertex2sv(v);
+}
+
+void gl1_4_glVertex2s(void *_glfuncs, GLshort x, GLshort y)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glVertex2s(x, y);
+}
+
+void gl1_4_glVertex2iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glVertex2iv(v);
+}
+
+void gl1_4_glVertex2i(void *_glfuncs, GLint x, GLint y)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glVertex2i(x, y);
+}
+
+void gl1_4_glVertex2fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glVertex2fv(v);
+}
+
+void gl1_4_glVertex2f(void *_glfuncs, GLfloat x, GLfloat y)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glVertex2f(x, y);
+}
+
+void gl1_4_glVertex2dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glVertex2dv(v);
+}
+
+void gl1_4_glVertex2d(void *_glfuncs, GLdouble x, GLdouble y)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glVertex2d(x, y);
+}
+
+void gl1_4_glTexCoord4sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glTexCoord4sv(v);
+}
+
+void gl1_4_glTexCoord4s(void *_glfuncs, GLshort s, GLshort t, GLshort r, GLshort q)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glTexCoord4s(s, t, r, q);
+}
+
+void gl1_4_glTexCoord4iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glTexCoord4iv(v);
+}
+
+void gl1_4_glTexCoord4i(void *_glfuncs, GLint s, GLint t, GLint r, GLint q)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glTexCoord4i(s, t, r, q);
+}
+
+void gl1_4_glTexCoord4fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glTexCoord4fv(v);
+}
+
+void gl1_4_glTexCoord4f(void *_glfuncs, GLfloat s, GLfloat t, GLfloat r, GLfloat q)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glTexCoord4f(s, t, r, q);
+}
+
+void gl1_4_glTexCoord4dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glTexCoord4dv(v);
+}
+
+void gl1_4_glTexCoord4d(void *_glfuncs, GLdouble s, GLdouble t, GLdouble r, GLdouble q)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glTexCoord4d(s, t, r, q);
+}
+
+void gl1_4_glTexCoord3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glTexCoord3sv(v);
+}
+
+void gl1_4_glTexCoord3s(void *_glfuncs, GLshort s, GLshort t, GLshort r)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glTexCoord3s(s, t, r);
+}
+
+void gl1_4_glTexCoord3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glTexCoord3iv(v);
+}
+
+void gl1_4_glTexCoord3i(void *_glfuncs, GLint s, GLint t, GLint r)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glTexCoord3i(s, t, r);
+}
+
+void gl1_4_glTexCoord3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glTexCoord3fv(v);
+}
+
+void gl1_4_glTexCoord3f(void *_glfuncs, GLfloat s, GLfloat t, GLfloat r)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glTexCoord3f(s, t, r);
+}
+
+void gl1_4_glTexCoord3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glTexCoord3dv(v);
+}
+
+void gl1_4_glTexCoord3d(void *_glfuncs, GLdouble s, GLdouble t, GLdouble r)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glTexCoord3d(s, t, r);
+}
+
+void gl1_4_glTexCoord2sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glTexCoord2sv(v);
+}
+
+void gl1_4_glTexCoord2s(void *_glfuncs, GLshort s, GLshort t)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glTexCoord2s(s, t);
+}
+
+void gl1_4_glTexCoord2iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glTexCoord2iv(v);
+}
+
+void gl1_4_glTexCoord2i(void *_glfuncs, GLint s, GLint t)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glTexCoord2i(s, t);
+}
+
+void gl1_4_glTexCoord2fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glTexCoord2fv(v);
+}
+
+void gl1_4_glTexCoord2f(void *_glfuncs, GLfloat s, GLfloat t)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glTexCoord2f(s, t);
+}
+
+void gl1_4_glTexCoord2dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glTexCoord2dv(v);
+}
+
+void gl1_4_glTexCoord2d(void *_glfuncs, GLdouble s, GLdouble t)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glTexCoord2d(s, t);
+}
+
+void gl1_4_glTexCoord1sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glTexCoord1sv(v);
+}
+
+void gl1_4_glTexCoord1s(void *_glfuncs, GLshort s)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glTexCoord1s(s);
+}
+
+void gl1_4_glTexCoord1iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glTexCoord1iv(v);
+}
+
+void gl1_4_glTexCoord1i(void *_glfuncs, GLint s)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glTexCoord1i(s);
+}
+
+void gl1_4_glTexCoord1fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glTexCoord1fv(v);
+}
+
+void gl1_4_glTexCoord1f(void *_glfuncs, GLfloat s)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glTexCoord1f(s);
+}
+
+void gl1_4_glTexCoord1dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glTexCoord1dv(v);
+}
+
+void gl1_4_glTexCoord1d(void *_glfuncs, GLdouble s)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glTexCoord1d(s);
+}
+
+void gl1_4_glRectsv(void *_glfuncs, const GLshort* v1, const GLshort* v2)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glRectsv(v1, v2);
+}
+
+void gl1_4_glRects(void *_glfuncs, GLshort x1, GLshort y1, GLshort x2, GLshort y2)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glRects(x1, y1, x2, y2);
+}
+
+void gl1_4_glRectiv(void *_glfuncs, const GLint* v1, const GLint* v2)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glRectiv(v1, v2);
+}
+
+void gl1_4_glRecti(void *_glfuncs, GLint x1, GLint y1, GLint x2, GLint y2)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glRecti(x1, y1, x2, y2);
+}
+
+void gl1_4_glRectfv(void *_glfuncs, const GLfloat* v1, const GLfloat* v2)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glRectfv(v1, v2);
+}
+
+void gl1_4_glRectf(void *_glfuncs, GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glRectf(x1, y1, x2, y2);
+}
+
+void gl1_4_glRectdv(void *_glfuncs, const GLdouble* v1, const GLdouble* v2)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glRectdv(v1, v2);
+}
+
+void gl1_4_glRectd(void *_glfuncs, GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glRectd(x1, y1, x2, y2);
+}
+
+void gl1_4_glRasterPos4sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glRasterPos4sv(v);
+}
+
+void gl1_4_glRasterPos4s(void *_glfuncs, GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glRasterPos4s(x, y, z, w);
+}
+
+void gl1_4_glRasterPos4iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glRasterPos4iv(v);
+}
+
+void gl1_4_glRasterPos4i(void *_glfuncs, GLint x, GLint y, GLint z, GLint w)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glRasterPos4i(x, y, z, w);
+}
+
+void gl1_4_glRasterPos4fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glRasterPos4fv(v);
+}
+
+void gl1_4_glRasterPos4f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glRasterPos4f(x, y, z, w);
+}
+
+void gl1_4_glRasterPos4dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glRasterPos4dv(v);
+}
+
+void gl1_4_glRasterPos4d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glRasterPos4d(x, y, z, w);
+}
+
+void gl1_4_glRasterPos3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glRasterPos3sv(v);
+}
+
+void gl1_4_glRasterPos3s(void *_glfuncs, GLshort x, GLshort y, GLshort z)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glRasterPos3s(x, y, z);
+}
+
+void gl1_4_glRasterPos3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glRasterPos3iv(v);
+}
+
+void gl1_4_glRasterPos3i(void *_glfuncs, GLint x, GLint y, GLint z)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glRasterPos3i(x, y, z);
+}
+
+void gl1_4_glRasterPos3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glRasterPos3fv(v);
+}
+
+void gl1_4_glRasterPos3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glRasterPos3f(x, y, z);
+}
+
+void gl1_4_glRasterPos3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glRasterPos3dv(v);
+}
+
+void gl1_4_glRasterPos3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glRasterPos3d(x, y, z);
+}
+
+void gl1_4_glRasterPos2sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glRasterPos2sv(v);
+}
+
+void gl1_4_glRasterPos2s(void *_glfuncs, GLshort x, GLshort y)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glRasterPos2s(x, y);
+}
+
+void gl1_4_glRasterPos2iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glRasterPos2iv(v);
+}
+
+void gl1_4_glRasterPos2i(void *_glfuncs, GLint x, GLint y)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glRasterPos2i(x, y);
+}
+
+void gl1_4_glRasterPos2fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glRasterPos2fv(v);
+}
+
+void gl1_4_glRasterPos2f(void *_glfuncs, GLfloat x, GLfloat y)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glRasterPos2f(x, y);
+}
+
+void gl1_4_glRasterPos2dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glRasterPos2dv(v);
+}
+
+void gl1_4_glRasterPos2d(void *_glfuncs, GLdouble x, GLdouble y)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glRasterPos2d(x, y);
+}
+
+void gl1_4_glNormal3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glNormal3sv(v);
+}
+
+void gl1_4_glNormal3s(void *_glfuncs, GLshort nx, GLshort ny, GLshort nz)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glNormal3s(nx, ny, nz);
+}
+
+void gl1_4_glNormal3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glNormal3iv(v);
+}
+
+void gl1_4_glNormal3i(void *_glfuncs, GLint nx, GLint ny, GLint nz)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glNormal3i(nx, ny, nz);
+}
+
+void gl1_4_glNormal3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glNormal3fv(v);
+}
+
+void gl1_4_glNormal3f(void *_glfuncs, GLfloat nx, GLfloat ny, GLfloat nz)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glNormal3f(nx, ny, nz);
+}
+
+void gl1_4_glNormal3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glNormal3dv(v);
+}
+
+void gl1_4_glNormal3d(void *_glfuncs, GLdouble nx, GLdouble ny, GLdouble nz)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glNormal3d(nx, ny, nz);
+}
+
+void gl1_4_glNormal3bv(void *_glfuncs, const GLbyte* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glNormal3bv(v);
+}
+
+void gl1_4_glNormal3b(void *_glfuncs, GLbyte nx, GLbyte ny, GLbyte nz)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glNormal3b(nx, ny, nz);
+}
+
+void gl1_4_glIndexsv(void *_glfuncs, const GLshort* c)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glIndexsv(c);
+}
+
+void gl1_4_glIndexs(void *_glfuncs, GLshort c)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glIndexs(c);
+}
+
+void gl1_4_glIndexiv(void *_glfuncs, const GLint* c)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glIndexiv(c);
+}
+
+void gl1_4_glIndexi(void *_glfuncs, GLint c)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glIndexi(c);
+}
+
+void gl1_4_glIndexfv(void *_glfuncs, const GLfloat* c)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glIndexfv(c);
+}
+
+void gl1_4_glIndexf(void *_glfuncs, GLfloat c)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glIndexf(c);
+}
+
+void gl1_4_glIndexdv(void *_glfuncs, const GLdouble* c)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glIndexdv(c);
+}
+
+void gl1_4_glIndexd(void *_glfuncs, GLdouble c)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glIndexd(c);
+}
+
+void gl1_4_glEnd(void *_glfuncs)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glEnd();
+}
+
+void gl1_4_glEdgeFlagv(void *_glfuncs, const GLboolean* flag)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glEdgeFlagv(flag);
+}
+
+void gl1_4_glEdgeFlag(void *_glfuncs, GLboolean flag)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glEdgeFlag(flag);
+}
+
+void gl1_4_glColor4usv(void *_glfuncs, const GLushort* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glColor4usv(v);
+}
+
+void gl1_4_glColor4us(void *_glfuncs, GLushort red, GLushort green, GLushort blue, GLushort alpha)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glColor4us(red, green, blue, alpha);
+}
+
+void gl1_4_glColor4uiv(void *_glfuncs, const GLuint* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glColor4uiv(v);
+}
+
+void gl1_4_glColor4ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue, GLuint alpha)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glColor4ui(red, green, blue, alpha);
+}
+
+void gl1_4_glColor4ubv(void *_glfuncs, const GLubyte* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glColor4ubv(v);
+}
+
+void gl1_4_glColor4ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glColor4ub(red, green, blue, alpha);
+}
+
+void gl1_4_glColor4sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glColor4sv(v);
+}
+
+void gl1_4_glColor4s(void *_glfuncs, GLshort red, GLshort green, GLshort blue, GLshort alpha)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glColor4s(red, green, blue, alpha);
+}
+
+void gl1_4_glColor4iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glColor4iv(v);
+}
+
+void gl1_4_glColor4i(void *_glfuncs, GLint red, GLint green, GLint blue, GLint alpha)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glColor4i(red, green, blue, alpha);
+}
+
+void gl1_4_glColor4fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glColor4fv(v);
+}
+
+void gl1_4_glColor4f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glColor4f(red, green, blue, alpha);
+}
+
+void gl1_4_glColor4dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glColor4dv(v);
+}
+
+void gl1_4_glColor4d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glColor4d(red, green, blue, alpha);
+}
+
+void gl1_4_glColor4bv(void *_glfuncs, const GLbyte* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glColor4bv(v);
+}
+
+void gl1_4_glColor4b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glColor4b(red, green, blue, alpha);
+}
+
+void gl1_4_glColor3usv(void *_glfuncs, const GLushort* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glColor3usv(v);
+}
+
+void gl1_4_glColor3us(void *_glfuncs, GLushort red, GLushort green, GLushort blue)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glColor3us(red, green, blue);
+}
+
+void gl1_4_glColor3uiv(void *_glfuncs, const GLuint* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glColor3uiv(v);
+}
+
+void gl1_4_glColor3ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glColor3ui(red, green, blue);
+}
+
+void gl1_4_glColor3ubv(void *_glfuncs, const GLubyte* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glColor3ubv(v);
+}
+
+void gl1_4_glColor3ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glColor3ub(red, green, blue);
+}
+
+void gl1_4_glColor3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glColor3sv(v);
+}
+
+void gl1_4_glColor3s(void *_glfuncs, GLshort red, GLshort green, GLshort blue)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glColor3s(red, green, blue);
+}
+
+void gl1_4_glColor3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glColor3iv(v);
+}
+
+void gl1_4_glColor3i(void *_glfuncs, GLint red, GLint green, GLint blue)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glColor3i(red, green, blue);
+}
+
+void gl1_4_glColor3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glColor3fv(v);
+}
+
+void gl1_4_glColor3f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glColor3f(red, green, blue);
+}
+
+void gl1_4_glColor3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glColor3dv(v);
+}
+
+void gl1_4_glColor3d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glColor3d(red, green, blue);
+}
+
+void gl1_4_glColor3bv(void *_glfuncs, const GLbyte* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glColor3bv(v);
+}
+
+void gl1_4_glColor3b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glColor3b(red, green, blue);
+}
+
+void gl1_4_glBitmap(void *_glfuncs, GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte* bitmap)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glBitmap(width, height, xorig, yorig, xmove, ymove, bitmap);
+}
+
+void gl1_4_glBegin(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glBegin(mode);
+}
+
+void gl1_4_glListBase(void *_glfuncs, GLuint base)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glListBase(base);
+}
+
+GLuint gl1_4_glGenLists(void *_glfuncs, GLsizei range_)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ return _qglfuncs->glGenLists(range_);
+}
+
+void gl1_4_glDeleteLists(void *_glfuncs, GLuint list, GLsizei range_)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glDeleteLists(list, range_);
+}
+
+void gl1_4_glCallLists(void *_glfuncs, GLsizei n, GLenum gltype, const GLvoid* lists)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glCallLists(n, gltype, lists);
+}
+
+void gl1_4_glCallList(void *_glfuncs, GLuint list)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glCallList(list);
+}
+
+void gl1_4_glEndList(void *_glfuncs)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glEndList();
+}
+
+void gl1_4_glNewList(void *_glfuncs, GLuint list, GLenum mode)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glNewList(list, mode);
+}
+
+void gl1_4_glPushClientAttrib(void *_glfuncs, GLbitfield mask)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glPushClientAttrib(mask);
+}
+
+void gl1_4_glPopClientAttrib(void *_glfuncs)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glPopClientAttrib();
+}
+
+void gl1_4_glPrioritizeTextures(void *_glfuncs, GLsizei n, const GLuint* textures, const GLfloat* priorities)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glPrioritizeTextures(n, textures, priorities);
+}
+
+GLboolean gl1_4_glAreTexturesResident(void *_glfuncs, GLsizei n, const GLuint* textures, GLboolean* residences)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ return _qglfuncs->glAreTexturesResident(n, textures, residences);
+}
+
+void gl1_4_glVertexPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glVertexPointer(size, gltype, stride, pointer);
+}
+
+void gl1_4_glTexCoordPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glTexCoordPointer(size, gltype, stride, pointer);
+}
+
+void gl1_4_glNormalPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glNormalPointer(gltype, stride, pointer);
+}
+
+void gl1_4_glInterleavedArrays(void *_glfuncs, GLenum format, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glInterleavedArrays(format, stride, pointer);
+}
+
+void gl1_4_glIndexPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glIndexPointer(gltype, stride, pointer);
+}
+
+void gl1_4_glEnableClientState(void *_glfuncs, GLenum array)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glEnableClientState(array);
+}
+
+void gl1_4_glEdgeFlagPointer(void *_glfuncs, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glEdgeFlagPointer(stride, pointer);
+}
+
+void gl1_4_glDisableClientState(void *_glfuncs, GLenum array)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glDisableClientState(array);
+}
+
+void gl1_4_glColorPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glColorPointer(size, gltype, stride, pointer);
+}
+
+void gl1_4_glArrayElement(void *_glfuncs, GLint i)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glArrayElement(i);
+}
+
+void gl1_4_glResetMinmax(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glResetMinmax(target);
+}
+
+void gl1_4_glResetHistogram(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glResetHistogram(target);
+}
+
+void gl1_4_glMinmax(void *_glfuncs, GLenum target, GLenum internalFormat, GLboolean sink)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glMinmax(target, internalFormat, sink);
+}
+
+void gl1_4_glHistogram(void *_glfuncs, GLenum target, GLsizei width, GLenum internalFormat, GLboolean sink)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glHistogram(target, width, internalFormat, sink);
+}
+
+void gl1_4_glGetMinmaxParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glGetMinmaxParameteriv(target, pname, params);
+}
+
+void gl1_4_glGetMinmaxParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glGetMinmaxParameterfv(target, pname, params);
+}
+
+void gl1_4_glGetMinmax(void *_glfuncs, GLenum target, GLboolean reset, GLenum format, GLenum gltype, GLvoid* values)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glGetMinmax(target, reset, format, gltype, values);
+}
+
+void gl1_4_glGetHistogramParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glGetHistogramParameteriv(target, pname, params);
+}
+
+void gl1_4_glGetHistogramParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glGetHistogramParameterfv(target, pname, params);
+}
+
+void gl1_4_glGetHistogram(void *_glfuncs, GLenum target, GLboolean reset, GLenum format, GLenum gltype, GLvoid* values)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glGetHistogram(target, reset, format, gltype, values);
+}
+
+void gl1_4_glSeparableFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* row, const GLvoid* column)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glSeparableFilter2D(target, internalFormat, width, height, format, gltype, row, column);
+}
+
+void gl1_4_glGetSeparableFilter(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* row, GLvoid* column, GLvoid* span)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glGetSeparableFilter(target, format, gltype, row, column, span);
+}
+
+void gl1_4_glGetConvolutionParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glGetConvolutionParameteriv(target, pname, params);
+}
+
+void gl1_4_glGetConvolutionParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glGetConvolutionParameterfv(target, pname, params);
+}
+
+void gl1_4_glGetConvolutionFilter(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* image)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glGetConvolutionFilter(target, format, gltype, image);
+}
+
+void gl1_4_glCopyConvolutionFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glCopyConvolutionFilter2D(target, internalFormat, x, y, width, height);
+}
+
+void gl1_4_glCopyConvolutionFilter1D(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glCopyConvolutionFilter1D(target, internalFormat, x, y, width);
+}
+
+void gl1_4_glConvolutionParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glConvolutionParameteriv(target, pname, params);
+}
+
+void gl1_4_glConvolutionParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint params)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glConvolutionParameteri(target, pname, params);
+}
+
+void gl1_4_glConvolutionParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glConvolutionParameterfv(target, pname, params);
+}
+
+void gl1_4_glConvolutionParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat params)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glConvolutionParameterf(target, pname, params);
+}
+
+void gl1_4_glConvolutionFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* image)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glConvolutionFilter2D(target, internalFormat, width, height, format, gltype, image);
+}
+
+void gl1_4_glConvolutionFilter1D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLenum format, GLenum gltype, const GLvoid* image)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glConvolutionFilter1D(target, internalFormat, width, format, gltype, image);
+}
+
+void gl1_4_glCopyColorSubTable(void *_glfuncs, GLenum target, GLsizei start, GLint x, GLint y, GLsizei width)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glCopyColorSubTable(target, start, x, y, width);
+}
+
+void gl1_4_glColorSubTable(void *_glfuncs, GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum gltype, const GLvoid* data)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glColorSubTable(target, start, count, format, gltype, data);
+}
+
+void gl1_4_glGetColorTableParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glGetColorTableParameteriv(target, pname, params);
+}
+
+void gl1_4_glGetColorTableParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glGetColorTableParameterfv(target, pname, params);
+}
+
+void gl1_4_glGetColorTable(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* table)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glGetColorTable(target, format, gltype, table);
+}
+
+void gl1_4_glCopyColorTable(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glCopyColorTable(target, internalFormat, x, y, width);
+}
+
+void gl1_4_glColorTableParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glColorTableParameteriv(target, pname, params);
+}
+
+void gl1_4_glColorTableParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glColorTableParameterfv(target, pname, params);
+}
+
+void gl1_4_glColorTable(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLenum format, GLenum gltype, const GLvoid* table)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glColorTable(target, internalFormat, width, format, gltype, table);
+}
+
+void gl1_4_glMultTransposeMatrixd(void *_glfuncs, const GLdouble* m)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glMultTransposeMatrixd(m);
+}
+
+void gl1_4_glMultTransposeMatrixf(void *_glfuncs, const GLfloat* m)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glMultTransposeMatrixf(m);
+}
+
+void gl1_4_glLoadTransposeMatrixd(void *_glfuncs, const GLdouble* m)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glLoadTransposeMatrixd(m);
+}
+
+void gl1_4_glLoadTransposeMatrixf(void *_glfuncs, const GLfloat* m)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glLoadTransposeMatrixf(m);
+}
+
+void gl1_4_glMultiTexCoord4sv(void *_glfuncs, GLenum target, const GLshort* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4sv(target, v);
+}
+
+void gl1_4_glMultiTexCoord4s(void *_glfuncs, GLenum target, GLshort s, GLshort t, GLshort r, GLshort q)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4s(target, s, t, r, q);
+}
+
+void gl1_4_glMultiTexCoord4iv(void *_glfuncs, GLenum target, const GLint* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4iv(target, v);
+}
+
+void gl1_4_glMultiTexCoord4i(void *_glfuncs, GLenum target, GLint s, GLint t, GLint r, GLint q)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4i(target, s, t, r, q);
+}
+
+void gl1_4_glMultiTexCoord4fv(void *_glfuncs, GLenum target, const GLfloat* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4fv(target, v);
+}
+
+void gl1_4_glMultiTexCoord4f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4f(target, s, t, r, q);
+}
+
+void gl1_4_glMultiTexCoord4dv(void *_glfuncs, GLenum target, const GLdouble* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4dv(target, v);
+}
+
+void gl1_4_glMultiTexCoord4d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4d(target, s, t, r, q);
+}
+
+void gl1_4_glMultiTexCoord3sv(void *_glfuncs, GLenum target, const GLshort* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3sv(target, v);
+}
+
+void gl1_4_glMultiTexCoord3s(void *_glfuncs, GLenum target, GLshort s, GLshort t, GLshort r)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3s(target, s, t, r);
+}
+
+void gl1_4_glMultiTexCoord3iv(void *_glfuncs, GLenum target, const GLint* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3iv(target, v);
+}
+
+void gl1_4_glMultiTexCoord3i(void *_glfuncs, GLenum target, GLint s, GLint t, GLint r)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3i(target, s, t, r);
+}
+
+void gl1_4_glMultiTexCoord3fv(void *_glfuncs, GLenum target, const GLfloat* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3fv(target, v);
+}
+
+void gl1_4_glMultiTexCoord3f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t, GLfloat r)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3f(target, s, t, r);
+}
+
+void gl1_4_glMultiTexCoord3dv(void *_glfuncs, GLenum target, const GLdouble* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3dv(target, v);
+}
+
+void gl1_4_glMultiTexCoord3d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t, GLdouble r)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3d(target, s, t, r);
+}
+
+void gl1_4_glMultiTexCoord2sv(void *_glfuncs, GLenum target, const GLshort* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2sv(target, v);
+}
+
+void gl1_4_glMultiTexCoord2s(void *_glfuncs, GLenum target, GLshort s, GLshort t)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2s(target, s, t);
+}
+
+void gl1_4_glMultiTexCoord2iv(void *_glfuncs, GLenum target, const GLint* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2iv(target, v);
+}
+
+void gl1_4_glMultiTexCoord2i(void *_glfuncs, GLenum target, GLint s, GLint t)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2i(target, s, t);
+}
+
+void gl1_4_glMultiTexCoord2fv(void *_glfuncs, GLenum target, const GLfloat* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2fv(target, v);
+}
+
+void gl1_4_glMultiTexCoord2f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2f(target, s, t);
+}
+
+void gl1_4_glMultiTexCoord2dv(void *_glfuncs, GLenum target, const GLdouble* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2dv(target, v);
+}
+
+void gl1_4_glMultiTexCoord2d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2d(target, s, t);
+}
+
+void gl1_4_glMultiTexCoord1sv(void *_glfuncs, GLenum target, const GLshort* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1sv(target, v);
+}
+
+void gl1_4_glMultiTexCoord1s(void *_glfuncs, GLenum target, GLshort s)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1s(target, s);
+}
+
+void gl1_4_glMultiTexCoord1iv(void *_glfuncs, GLenum target, const GLint* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1iv(target, v);
+}
+
+void gl1_4_glMultiTexCoord1i(void *_glfuncs, GLenum target, GLint s)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1i(target, s);
+}
+
+void gl1_4_glMultiTexCoord1fv(void *_glfuncs, GLenum target, const GLfloat* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1fv(target, v);
+}
+
+void gl1_4_glMultiTexCoord1f(void *_glfuncs, GLenum target, GLfloat s)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1f(target, s);
+}
+
+void gl1_4_glMultiTexCoord1dv(void *_glfuncs, GLenum target, const GLdouble* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1dv(target, v);
+}
+
+void gl1_4_glMultiTexCoord1d(void *_glfuncs, GLenum target, GLdouble s)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1d(target, s);
+}
+
+void gl1_4_glClientActiveTexture(void *_glfuncs, GLenum texture)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glClientActiveTexture(texture);
+}
+
+void gl1_4_glWindowPos3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glWindowPos3sv(v);
+}
+
+void gl1_4_glWindowPos3s(void *_glfuncs, GLshort x, GLshort y, GLshort z)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glWindowPos3s(x, y, z);
+}
+
+void gl1_4_glWindowPos3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glWindowPos3iv(v);
+}
+
+void gl1_4_glWindowPos3i(void *_glfuncs, GLint x, GLint y, GLint z)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glWindowPos3i(x, y, z);
+}
+
+void gl1_4_glWindowPos3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glWindowPos3fv(v);
+}
+
+void gl1_4_glWindowPos3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glWindowPos3f(x, y, z);
+}
+
+void gl1_4_glWindowPos3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glWindowPos3dv(v);
+}
+
+void gl1_4_glWindowPos3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glWindowPos3d(x, y, z);
+}
+
+void gl1_4_glWindowPos2sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glWindowPos2sv(v);
+}
+
+void gl1_4_glWindowPos2s(void *_glfuncs, GLshort x, GLshort y)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glWindowPos2s(x, y);
+}
+
+void gl1_4_glWindowPos2iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glWindowPos2iv(v);
+}
+
+void gl1_4_glWindowPos2i(void *_glfuncs, GLint x, GLint y)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glWindowPos2i(x, y);
+}
+
+void gl1_4_glWindowPos2fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glWindowPos2fv(v);
+}
+
+void gl1_4_glWindowPos2f(void *_glfuncs, GLfloat x, GLfloat y)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glWindowPos2f(x, y);
+}
+
+void gl1_4_glWindowPos2dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glWindowPos2dv(v);
+}
+
+void gl1_4_glWindowPos2d(void *_glfuncs, GLdouble x, GLdouble y)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glWindowPos2d(x, y);
+}
+
+void gl1_4_glSecondaryColorPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glSecondaryColorPointer(size, gltype, stride, pointer);
+}
+
+void gl1_4_glSecondaryColor3usv(void *_glfuncs, const GLushort* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3usv(v);
+}
+
+void gl1_4_glSecondaryColor3us(void *_glfuncs, GLushort red, GLushort green, GLushort blue)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3us(red, green, blue);
+}
+
+void gl1_4_glSecondaryColor3uiv(void *_glfuncs, const GLuint* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3uiv(v);
+}
+
+void gl1_4_glSecondaryColor3ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3ui(red, green, blue);
+}
+
+void gl1_4_glSecondaryColor3ubv(void *_glfuncs, const GLubyte* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3ubv(v);
+}
+
+void gl1_4_glSecondaryColor3ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3ub(red, green, blue);
+}
+
+void gl1_4_glSecondaryColor3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3sv(v);
+}
+
+void gl1_4_glSecondaryColor3s(void *_glfuncs, GLshort red, GLshort green, GLshort blue)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3s(red, green, blue);
+}
+
+void gl1_4_glSecondaryColor3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3iv(v);
+}
+
+void gl1_4_glSecondaryColor3i(void *_glfuncs, GLint red, GLint green, GLint blue)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3i(red, green, blue);
+}
+
+void gl1_4_glSecondaryColor3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3fv(v);
+}
+
+void gl1_4_glSecondaryColor3f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3f(red, green, blue);
+}
+
+void gl1_4_glSecondaryColor3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3dv(v);
+}
+
+void gl1_4_glSecondaryColor3d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3d(red, green, blue);
+}
+
+void gl1_4_glSecondaryColor3bv(void *_glfuncs, const GLbyte* v)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3bv(v);
+}
+
+void gl1_4_glSecondaryColor3b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3b(red, green, blue);
+}
+
+void gl1_4_glFogCoordPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glFogCoordPointer(gltype, stride, pointer);
+}
+
+void gl1_4_glFogCoorddv(void *_glfuncs, const GLdouble* coord)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glFogCoorddv(coord);
+}
+
+void gl1_4_glFogCoordd(void *_glfuncs, GLdouble coord)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glFogCoordd(coord);
+}
+
+void gl1_4_glFogCoordfv(void *_glfuncs, const GLfloat* coord)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glFogCoordfv(coord);
+}
+
+void gl1_4_glFogCoordf(void *_glfuncs, GLfloat coord)
+{
+ QOpenGLFunctions_1_4* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_4*>(_glfuncs);
+ _qglfuncs->glFogCoordf(coord);
+}
+
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/1.4/funcs.h b/Godeps/_workspace/src/github.com/obscuren/qml/gl/1.4/funcs.h
new file mode 100644
index 000000000..ea657e080
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/1.4/funcs.h
@@ -0,0 +1,504 @@
+
+// ** file automatically generated by glgen -- do not edit manually **
+
+#ifndef __cplusplus
+#include <inttypes.h>
+#include <stddef.h>
+typedef unsigned int GLenum;
+typedef unsigned char GLboolean;
+typedef unsigned int GLbitfield;
+typedef void GLvoid;
+typedef char GLchar;
+typedef signed char GLbyte; /* 1-byte signed */
+typedef short GLshort; /* 2-byte signed */
+typedef int GLint; /* 4-byte signed */
+typedef unsigned char GLubyte; /* 1-byte unsigned */
+typedef unsigned short GLushort; /* 2-byte unsigned */
+typedef unsigned int GLuint; /* 4-byte unsigned */
+typedef int GLsizei; /* 4-byte signed */
+typedef float GLfloat; /* single precision float */
+typedef float GLclampf; /* single precision float in [0,1] */
+typedef double GLdouble; /* double precision float */
+typedef double GLclampd; /* double precision float in [0,1] */
+typedef int64_t GLint64;
+typedef uint64_t GLuint64;
+typedef ptrdiff_t GLintptr;
+typedef ptrdiff_t GLsizeiptr;
+typedef ptrdiff_t GLintptrARB;
+typedef ptrdiff_t GLsizeiptrARB;
+typedef struct __GLsync *GLsync;
+#endif
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+void *gl1_4_funcs();
+
+void gl1_4_glViewport(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl1_4_glDepthRange(void *_glfuncs, GLdouble nearVal, GLdouble farVal);
+GLboolean gl1_4_glIsEnabled(void *_glfuncs, GLenum cap);
+void gl1_4_glGetTexLevelParameteriv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLint* params);
+void gl1_4_glGetTexLevelParameterfv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLfloat* params);
+void gl1_4_glGetTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl1_4_glGetTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl1_4_glGetTexImage(void *_glfuncs, GLenum target, GLint level, GLenum format, GLenum gltype, GLvoid* pixels);
+void gl1_4_glGetIntegerv(void *_glfuncs, GLenum pname, GLint* params);
+void gl1_4_glGetFloatv(void *_glfuncs, GLenum pname, GLfloat* params);
+GLenum gl1_4_glGetError(void *_glfuncs);
+void gl1_4_glGetDoublev(void *_glfuncs, GLenum pname, GLdouble* params);
+void gl1_4_glGetBooleanv(void *_glfuncs, GLenum pname, GLboolean* params);
+void gl1_4_glReadPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum gltype, GLvoid* pixels);
+void gl1_4_glReadBuffer(void *_glfuncs, GLenum mode);
+void gl1_4_glPixelStorei(void *_glfuncs, GLenum pname, GLint param);
+void gl1_4_glPixelStoref(void *_glfuncs, GLenum pname, GLfloat param);
+void gl1_4_glDepthFunc(void *_glfuncs, GLenum glfunc);
+void gl1_4_glStencilOp(void *_glfuncs, GLenum fail, GLenum zfail, GLenum zpass);
+void gl1_4_glStencilFunc(void *_glfuncs, GLenum glfunc, GLint ref, GLuint mask);
+void gl1_4_glLogicOp(void *_glfuncs, GLenum opcode);
+void gl1_4_glBlendFunc(void *_glfuncs, GLenum sfactor, GLenum dfactor);
+void gl1_4_glFlush(void *_glfuncs);
+void gl1_4_glFinish(void *_glfuncs);
+void gl1_4_glEnable(void *_glfuncs, GLenum cap);
+void gl1_4_glDisable(void *_glfuncs, GLenum cap);
+void gl1_4_glDepthMask(void *_glfuncs, GLboolean flag);
+void gl1_4_glColorMask(void *_glfuncs, GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha);
+void gl1_4_glStencilMask(void *_glfuncs, GLuint mask);
+void gl1_4_glClearDepth(void *_glfuncs, GLdouble depth);
+void gl1_4_glClearStencil(void *_glfuncs, GLint s);
+void gl1_4_glClearColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl1_4_glClear(void *_glfuncs, GLbitfield mask);
+void gl1_4_glDrawBuffer(void *_glfuncs, GLenum mode);
+void gl1_4_glTexImage2D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl1_4_glTexImage1D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl1_4_glTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl1_4_glTexParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint param);
+void gl1_4_glTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl1_4_glTexParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param);
+void gl1_4_glScissor(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl1_4_glPolygonMode(void *_glfuncs, GLenum face, GLenum mode);
+void gl1_4_glPointSize(void *_glfuncs, GLfloat size);
+void gl1_4_glLineWidth(void *_glfuncs, GLfloat width);
+void gl1_4_glHint(void *_glfuncs, GLenum target, GLenum mode);
+void gl1_4_glFrontFace(void *_glfuncs, GLenum mode);
+void gl1_4_glCullFace(void *_glfuncs, GLenum mode);
+void gl1_4_glIndexubv(void *_glfuncs, const GLubyte* c);
+void gl1_4_glIndexub(void *_glfuncs, GLubyte c);
+GLboolean gl1_4_glIsTexture(void *_glfuncs, GLuint texture);
+void gl1_4_glGenTextures(void *_glfuncs, GLsizei n, GLuint* textures);
+void gl1_4_glDeleteTextures(void *_glfuncs, GLsizei n, const GLuint* textures);
+void gl1_4_glBindTexture(void *_glfuncs, GLenum target, GLuint texture);
+void gl1_4_glTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl1_4_glTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl1_4_glCopyTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl1_4_glCopyTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width);
+void gl1_4_glCopyTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border);
+void gl1_4_glCopyTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLint border);
+void gl1_4_glPolygonOffset(void *_glfuncs, GLfloat factor, GLfloat units);
+void gl1_4_glDrawElements(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices);
+void gl1_4_glDrawArrays(void *_glfuncs, GLenum mode, GLint first, GLsizei count);
+void gl1_4_glCopyTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl1_4_glTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl1_4_glTexImage3D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl1_4_glDrawRangeElements(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices);
+void gl1_4_glBlendEquation(void *_glfuncs, GLenum mode);
+void gl1_4_glBlendColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl1_4_glGetCompressedTexImage(void *_glfuncs, GLenum target, GLint level, GLvoid* img);
+void gl1_4_glCompressedTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid* data);
+void gl1_4_glCompressedTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid* data);
+void gl1_4_glCompressedTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid* data);
+void gl1_4_glCompressedTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid* data);
+void gl1_4_glCompressedTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid* data);
+void gl1_4_glCompressedTexImage3D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid* data);
+void gl1_4_glSampleCoverage(void *_glfuncs, GLfloat value, GLboolean invert);
+void gl1_4_glActiveTexture(void *_glfuncs, GLenum texture);
+void gl1_4_glPointParameteriv(void *_glfuncs, GLenum pname, const GLint* params);
+void gl1_4_glPointParameteri(void *_glfuncs, GLenum pname, GLint param);
+void gl1_4_glPointParameterfv(void *_glfuncs, GLenum pname, const GLfloat* params);
+void gl1_4_glPointParameterf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl1_4_glMultiDrawArrays(void *_glfuncs, GLenum mode, const GLint* first, const GLsizei* count, GLsizei drawcount);
+void gl1_4_glBlendFuncSeparate(void *_glfuncs, GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha);
+void gl1_4_glTranslatef(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl1_4_glTranslated(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl1_4_glScalef(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl1_4_glScaled(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl1_4_glRotatef(void *_glfuncs, GLfloat angle, GLfloat x, GLfloat y, GLfloat z);
+void gl1_4_glRotated(void *_glfuncs, GLdouble angle, GLdouble x, GLdouble y, GLdouble z);
+void gl1_4_glPushMatrix(void *_glfuncs);
+void gl1_4_glPopMatrix(void *_glfuncs);
+void gl1_4_glOrtho(void *_glfuncs, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+void gl1_4_glMultMatrixd(void *_glfuncs, const GLdouble* m);
+void gl1_4_glMultMatrixf(void *_glfuncs, const GLfloat* m);
+void gl1_4_glMatrixMode(void *_glfuncs, GLenum mode);
+void gl1_4_glLoadMatrixd(void *_glfuncs, const GLdouble* m);
+void gl1_4_glLoadMatrixf(void *_glfuncs, const GLfloat* m);
+void gl1_4_glLoadIdentity(void *_glfuncs);
+void gl1_4_glFrustum(void *_glfuncs, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+GLboolean gl1_4_glIsList(void *_glfuncs, GLuint list);
+void gl1_4_glGetTexGeniv(void *_glfuncs, GLenum coord, GLenum pname, GLint* params);
+void gl1_4_glGetTexGenfv(void *_glfuncs, GLenum coord, GLenum pname, GLfloat* params);
+void gl1_4_glGetTexGendv(void *_glfuncs, GLenum coord, GLenum pname, GLdouble* params);
+void gl1_4_glGetTexEnviv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl1_4_glGetTexEnvfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl1_4_glGetPolygonStipple(void *_glfuncs, GLubyte* mask);
+void gl1_4_glGetPixelMapusv(void *_glfuncs, GLenum glmap, GLushort* values);
+void gl1_4_glGetPixelMapuiv(void *_glfuncs, GLenum glmap, GLuint* values);
+void gl1_4_glGetPixelMapfv(void *_glfuncs, GLenum glmap, GLfloat* values);
+void gl1_4_glGetMaterialiv(void *_glfuncs, GLenum face, GLenum pname, GLint* params);
+void gl1_4_glGetMaterialfv(void *_glfuncs, GLenum face, GLenum pname, GLfloat* params);
+void gl1_4_glGetMapiv(void *_glfuncs, GLenum target, GLenum query, GLint* v);
+void gl1_4_glGetMapfv(void *_glfuncs, GLenum target, GLenum query, GLfloat* v);
+void gl1_4_glGetMapdv(void *_glfuncs, GLenum target, GLenum query, GLdouble* v);
+void gl1_4_glGetLightiv(void *_glfuncs, GLenum light, GLenum pname, GLint* params);
+void gl1_4_glGetLightfv(void *_glfuncs, GLenum light, GLenum pname, GLfloat* params);
+void gl1_4_glGetClipPlane(void *_glfuncs, GLenum plane, GLdouble* equation);
+void gl1_4_glDrawPixels(void *_glfuncs, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl1_4_glCopyPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum gltype);
+void gl1_4_glPixelMapusv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLushort* values);
+void gl1_4_glPixelMapuiv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLuint* values);
+void gl1_4_glPixelMapfv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLfloat* values);
+void gl1_4_glPixelTransferi(void *_glfuncs, GLenum pname, GLint param);
+void gl1_4_glPixelTransferf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl1_4_glPixelZoom(void *_glfuncs, GLfloat xfactor, GLfloat yfactor);
+void gl1_4_glAlphaFunc(void *_glfuncs, GLenum glfunc, GLfloat ref);
+void gl1_4_glEvalPoint2(void *_glfuncs, GLint i, GLint j);
+void gl1_4_glEvalMesh2(void *_glfuncs, GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2);
+void gl1_4_glEvalPoint1(void *_glfuncs, GLint i);
+void gl1_4_glEvalMesh1(void *_glfuncs, GLenum mode, GLint i1, GLint i2);
+void gl1_4_glEvalCoord2fv(void *_glfuncs, const GLfloat* u);
+void gl1_4_glEvalCoord2f(void *_glfuncs, GLfloat u, GLfloat v);
+void gl1_4_glEvalCoord2dv(void *_glfuncs, const GLdouble* u);
+void gl1_4_glEvalCoord2d(void *_glfuncs, GLdouble u, GLdouble v);
+void gl1_4_glEvalCoord1fv(void *_glfuncs, const GLfloat* u);
+void gl1_4_glEvalCoord1f(void *_glfuncs, GLfloat u);
+void gl1_4_glEvalCoord1dv(void *_glfuncs, const GLdouble* u);
+void gl1_4_glEvalCoord1d(void *_glfuncs, GLdouble u);
+void gl1_4_glMapGrid2f(void *_glfuncs, GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2);
+void gl1_4_glMapGrid2d(void *_glfuncs, GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2);
+void gl1_4_glMapGrid1f(void *_glfuncs, GLint un, GLfloat u1, GLfloat u2);
+void gl1_4_glMapGrid1d(void *_glfuncs, GLint un, GLdouble u1, GLdouble u2);
+void gl1_4_glMap2f(void *_glfuncs, GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat* points);
+void gl1_4_glMap2d(void *_glfuncs, GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble* points);
+void gl1_4_glMap1f(void *_glfuncs, GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat* points);
+void gl1_4_glMap1d(void *_glfuncs, GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble* points);
+void gl1_4_glPushAttrib(void *_glfuncs, GLbitfield mask);
+void gl1_4_glPopAttrib(void *_glfuncs);
+void gl1_4_glAccum(void *_glfuncs, GLenum op, GLfloat value);
+void gl1_4_glIndexMask(void *_glfuncs, GLuint mask);
+void gl1_4_glClearIndex(void *_glfuncs, GLfloat c);
+void gl1_4_glClearAccum(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl1_4_glPushName(void *_glfuncs, GLuint name);
+void gl1_4_glPopName(void *_glfuncs);
+void gl1_4_glPassThrough(void *_glfuncs, GLfloat token);
+void gl1_4_glLoadName(void *_glfuncs, GLuint name);
+void gl1_4_glInitNames(void *_glfuncs);
+GLint gl1_4_glRenderMode(void *_glfuncs, GLenum mode);
+void gl1_4_glSelectBuffer(void *_glfuncs, GLsizei size, GLuint* buffer);
+void gl1_4_glFeedbackBuffer(void *_glfuncs, GLsizei size, GLenum gltype, GLfloat* buffer);
+void gl1_4_glTexGeniv(void *_glfuncs, GLenum coord, GLenum pname, const GLint* params);
+void gl1_4_glTexGeni(void *_glfuncs, GLenum coord, GLenum pname, GLint param);
+void gl1_4_glTexGenfv(void *_glfuncs, GLenum coord, GLenum pname, const GLfloat* params);
+void gl1_4_glTexGenf(void *_glfuncs, GLenum coord, GLenum pname, GLfloat param);
+void gl1_4_glTexGendv(void *_glfuncs, GLenum coord, GLenum pname, const GLdouble* params);
+void gl1_4_glTexGend(void *_glfuncs, GLenum coord, GLenum pname, GLdouble param);
+void gl1_4_glTexEnviv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl1_4_glTexEnvi(void *_glfuncs, GLenum target, GLenum pname, GLint param);
+void gl1_4_glTexEnvfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl1_4_glTexEnvf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param);
+void gl1_4_glShadeModel(void *_glfuncs, GLenum mode);
+void gl1_4_glPolygonStipple(void *_glfuncs, const GLubyte* mask);
+void gl1_4_glMaterialiv(void *_glfuncs, GLenum face, GLenum pname, const GLint* params);
+void gl1_4_glMateriali(void *_glfuncs, GLenum face, GLenum pname, GLint param);
+void gl1_4_glMaterialfv(void *_glfuncs, GLenum face, GLenum pname, const GLfloat* params);
+void gl1_4_glMaterialf(void *_glfuncs, GLenum face, GLenum pname, GLfloat param);
+void gl1_4_glLineStipple(void *_glfuncs, GLint factor, GLushort pattern);
+void gl1_4_glLightModeliv(void *_glfuncs, GLenum pname, const GLint* params);
+void gl1_4_glLightModeli(void *_glfuncs, GLenum pname, GLint param);
+void gl1_4_glLightModelfv(void *_glfuncs, GLenum pname, const GLfloat* params);
+void gl1_4_glLightModelf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl1_4_glLightiv(void *_glfuncs, GLenum light, GLenum pname, const GLint* params);
+void gl1_4_glLighti(void *_glfuncs, GLenum light, GLenum pname, GLint param);
+void gl1_4_glLightfv(void *_glfuncs, GLenum light, GLenum pname, const GLfloat* params);
+void gl1_4_glLightf(void *_glfuncs, GLenum light, GLenum pname, GLfloat param);
+void gl1_4_glFogiv(void *_glfuncs, GLenum pname, const GLint* params);
+void gl1_4_glFogi(void *_glfuncs, GLenum pname, GLint param);
+void gl1_4_glFogfv(void *_glfuncs, GLenum pname, const GLfloat* params);
+void gl1_4_glFogf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl1_4_glColorMaterial(void *_glfuncs, GLenum face, GLenum mode);
+void gl1_4_glClipPlane(void *_glfuncs, GLenum plane, const GLdouble* equation);
+void gl1_4_glVertex4sv(void *_glfuncs, const GLshort* v);
+void gl1_4_glVertex4s(void *_glfuncs, GLshort x, GLshort y, GLshort z, GLshort w);
+void gl1_4_glVertex4iv(void *_glfuncs, const GLint* v);
+void gl1_4_glVertex4i(void *_glfuncs, GLint x, GLint y, GLint z, GLint w);
+void gl1_4_glVertex4fv(void *_glfuncs, const GLfloat* v);
+void gl1_4_glVertex4f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+void gl1_4_glVertex4dv(void *_glfuncs, const GLdouble* v);
+void gl1_4_glVertex4d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+void gl1_4_glVertex3sv(void *_glfuncs, const GLshort* v);
+void gl1_4_glVertex3s(void *_glfuncs, GLshort x, GLshort y, GLshort z);
+void gl1_4_glVertex3iv(void *_glfuncs, const GLint* v);
+void gl1_4_glVertex3i(void *_glfuncs, GLint x, GLint y, GLint z);
+void gl1_4_glVertex3fv(void *_glfuncs, const GLfloat* v);
+void gl1_4_glVertex3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl1_4_glVertex3dv(void *_glfuncs, const GLdouble* v);
+void gl1_4_glVertex3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl1_4_glVertex2sv(void *_glfuncs, const GLshort* v);
+void gl1_4_glVertex2s(void *_glfuncs, GLshort x, GLshort y);
+void gl1_4_glVertex2iv(void *_glfuncs, const GLint* v);
+void gl1_4_glVertex2i(void *_glfuncs, GLint x, GLint y);
+void gl1_4_glVertex2fv(void *_glfuncs, const GLfloat* v);
+void gl1_4_glVertex2f(void *_glfuncs, GLfloat x, GLfloat y);
+void gl1_4_glVertex2dv(void *_glfuncs, const GLdouble* v);
+void gl1_4_glVertex2d(void *_glfuncs, GLdouble x, GLdouble y);
+void gl1_4_glTexCoord4sv(void *_glfuncs, const GLshort* v);
+void gl1_4_glTexCoord4s(void *_glfuncs, GLshort s, GLshort t, GLshort r, GLshort q);
+void gl1_4_glTexCoord4iv(void *_glfuncs, const GLint* v);
+void gl1_4_glTexCoord4i(void *_glfuncs, GLint s, GLint t, GLint r, GLint q);
+void gl1_4_glTexCoord4fv(void *_glfuncs, const GLfloat* v);
+void gl1_4_glTexCoord4f(void *_glfuncs, GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+void gl1_4_glTexCoord4dv(void *_glfuncs, const GLdouble* v);
+void gl1_4_glTexCoord4d(void *_glfuncs, GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+void gl1_4_glTexCoord3sv(void *_glfuncs, const GLshort* v);
+void gl1_4_glTexCoord3s(void *_glfuncs, GLshort s, GLshort t, GLshort r);
+void gl1_4_glTexCoord3iv(void *_glfuncs, const GLint* v);
+void gl1_4_glTexCoord3i(void *_glfuncs, GLint s, GLint t, GLint r);
+void gl1_4_glTexCoord3fv(void *_glfuncs, const GLfloat* v);
+void gl1_4_glTexCoord3f(void *_glfuncs, GLfloat s, GLfloat t, GLfloat r);
+void gl1_4_glTexCoord3dv(void *_glfuncs, const GLdouble* v);
+void gl1_4_glTexCoord3d(void *_glfuncs, GLdouble s, GLdouble t, GLdouble r);
+void gl1_4_glTexCoord2sv(void *_glfuncs, const GLshort* v);
+void gl1_4_glTexCoord2s(void *_glfuncs, GLshort s, GLshort t);
+void gl1_4_glTexCoord2iv(void *_glfuncs, const GLint* v);
+void gl1_4_glTexCoord2i(void *_glfuncs, GLint s, GLint t);
+void gl1_4_glTexCoord2fv(void *_glfuncs, const GLfloat* v);
+void gl1_4_glTexCoord2f(void *_glfuncs, GLfloat s, GLfloat t);
+void gl1_4_glTexCoord2dv(void *_glfuncs, const GLdouble* v);
+void gl1_4_glTexCoord2d(void *_glfuncs, GLdouble s, GLdouble t);
+void gl1_4_glTexCoord1sv(void *_glfuncs, const GLshort* v);
+void gl1_4_glTexCoord1s(void *_glfuncs, GLshort s);
+void gl1_4_glTexCoord1iv(void *_glfuncs, const GLint* v);
+void gl1_4_glTexCoord1i(void *_glfuncs, GLint s);
+void gl1_4_glTexCoord1fv(void *_glfuncs, const GLfloat* v);
+void gl1_4_glTexCoord1f(void *_glfuncs, GLfloat s);
+void gl1_4_glTexCoord1dv(void *_glfuncs, const GLdouble* v);
+void gl1_4_glTexCoord1d(void *_glfuncs, GLdouble s);
+void gl1_4_glRectsv(void *_glfuncs, const GLshort* v1, const GLshort* v2);
+void gl1_4_glRects(void *_glfuncs, GLshort x1, GLshort y1, GLshort x2, GLshort y2);
+void gl1_4_glRectiv(void *_glfuncs, const GLint* v1, const GLint* v2);
+void gl1_4_glRecti(void *_glfuncs, GLint x1, GLint y1, GLint x2, GLint y2);
+void gl1_4_glRectfv(void *_glfuncs, const GLfloat* v1, const GLfloat* v2);
+void gl1_4_glRectf(void *_glfuncs, GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2);
+void gl1_4_glRectdv(void *_glfuncs, const GLdouble* v1, const GLdouble* v2);
+void gl1_4_glRectd(void *_glfuncs, GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2);
+void gl1_4_glRasterPos4sv(void *_glfuncs, const GLshort* v);
+void gl1_4_glRasterPos4s(void *_glfuncs, GLshort x, GLshort y, GLshort z, GLshort w);
+void gl1_4_glRasterPos4iv(void *_glfuncs, const GLint* v);
+void gl1_4_glRasterPos4i(void *_glfuncs, GLint x, GLint y, GLint z, GLint w);
+void gl1_4_glRasterPos4fv(void *_glfuncs, const GLfloat* v);
+void gl1_4_glRasterPos4f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+void gl1_4_glRasterPos4dv(void *_glfuncs, const GLdouble* v);
+void gl1_4_glRasterPos4d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+void gl1_4_glRasterPos3sv(void *_glfuncs, const GLshort* v);
+void gl1_4_glRasterPos3s(void *_glfuncs, GLshort x, GLshort y, GLshort z);
+void gl1_4_glRasterPos3iv(void *_glfuncs, const GLint* v);
+void gl1_4_glRasterPos3i(void *_glfuncs, GLint x, GLint y, GLint z);
+void gl1_4_glRasterPos3fv(void *_glfuncs, const GLfloat* v);
+void gl1_4_glRasterPos3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl1_4_glRasterPos3dv(void *_glfuncs, const GLdouble* v);
+void gl1_4_glRasterPos3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl1_4_glRasterPos2sv(void *_glfuncs, const GLshort* v);
+void gl1_4_glRasterPos2s(void *_glfuncs, GLshort x, GLshort y);
+void gl1_4_glRasterPos2iv(void *_glfuncs, const GLint* v);
+void gl1_4_glRasterPos2i(void *_glfuncs, GLint x, GLint y);
+void gl1_4_glRasterPos2fv(void *_glfuncs, const GLfloat* v);
+void gl1_4_glRasterPos2f(void *_glfuncs, GLfloat x, GLfloat y);
+void gl1_4_glRasterPos2dv(void *_glfuncs, const GLdouble* v);
+void gl1_4_glRasterPos2d(void *_glfuncs, GLdouble x, GLdouble y);
+void gl1_4_glNormal3sv(void *_glfuncs, const GLshort* v);
+void gl1_4_glNormal3s(void *_glfuncs, GLshort nx, GLshort ny, GLshort nz);
+void gl1_4_glNormal3iv(void *_glfuncs, const GLint* v);
+void gl1_4_glNormal3i(void *_glfuncs, GLint nx, GLint ny, GLint nz);
+void gl1_4_glNormal3fv(void *_glfuncs, const GLfloat* v);
+void gl1_4_glNormal3f(void *_glfuncs, GLfloat nx, GLfloat ny, GLfloat nz);
+void gl1_4_glNormal3dv(void *_glfuncs, const GLdouble* v);
+void gl1_4_glNormal3d(void *_glfuncs, GLdouble nx, GLdouble ny, GLdouble nz);
+void gl1_4_glNormal3bv(void *_glfuncs, const GLbyte* v);
+void gl1_4_glNormal3b(void *_glfuncs, GLbyte nx, GLbyte ny, GLbyte nz);
+void gl1_4_glIndexsv(void *_glfuncs, const GLshort* c);
+void gl1_4_glIndexs(void *_glfuncs, GLshort c);
+void gl1_4_glIndexiv(void *_glfuncs, const GLint* c);
+void gl1_4_glIndexi(void *_glfuncs, GLint c);
+void gl1_4_glIndexfv(void *_glfuncs, const GLfloat* c);
+void gl1_4_glIndexf(void *_glfuncs, GLfloat c);
+void gl1_4_glIndexdv(void *_glfuncs, const GLdouble* c);
+void gl1_4_glIndexd(void *_glfuncs, GLdouble c);
+void gl1_4_glEnd(void *_glfuncs);
+void gl1_4_glEdgeFlagv(void *_glfuncs, const GLboolean* flag);
+void gl1_4_glEdgeFlag(void *_glfuncs, GLboolean flag);
+void gl1_4_glColor4usv(void *_glfuncs, const GLushort* v);
+void gl1_4_glColor4us(void *_glfuncs, GLushort red, GLushort green, GLushort blue, GLushort alpha);
+void gl1_4_glColor4uiv(void *_glfuncs, const GLuint* v);
+void gl1_4_glColor4ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue, GLuint alpha);
+void gl1_4_glColor4ubv(void *_glfuncs, const GLubyte* v);
+void gl1_4_glColor4ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha);
+void gl1_4_glColor4sv(void *_glfuncs, const GLshort* v);
+void gl1_4_glColor4s(void *_glfuncs, GLshort red, GLshort green, GLshort blue, GLshort alpha);
+void gl1_4_glColor4iv(void *_glfuncs, const GLint* v);
+void gl1_4_glColor4i(void *_glfuncs, GLint red, GLint green, GLint blue, GLint alpha);
+void gl1_4_glColor4fv(void *_glfuncs, const GLfloat* v);
+void gl1_4_glColor4f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl1_4_glColor4dv(void *_glfuncs, const GLdouble* v);
+void gl1_4_glColor4d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha);
+void gl1_4_glColor4bv(void *_glfuncs, const GLbyte* v);
+void gl1_4_glColor4b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha);
+void gl1_4_glColor3usv(void *_glfuncs, const GLushort* v);
+void gl1_4_glColor3us(void *_glfuncs, GLushort red, GLushort green, GLushort blue);
+void gl1_4_glColor3uiv(void *_glfuncs, const GLuint* v);
+void gl1_4_glColor3ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue);
+void gl1_4_glColor3ubv(void *_glfuncs, const GLubyte* v);
+void gl1_4_glColor3ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue);
+void gl1_4_glColor3sv(void *_glfuncs, const GLshort* v);
+void gl1_4_glColor3s(void *_glfuncs, GLshort red, GLshort green, GLshort blue);
+void gl1_4_glColor3iv(void *_glfuncs, const GLint* v);
+void gl1_4_glColor3i(void *_glfuncs, GLint red, GLint green, GLint blue);
+void gl1_4_glColor3fv(void *_glfuncs, const GLfloat* v);
+void gl1_4_glColor3f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue);
+void gl1_4_glColor3dv(void *_glfuncs, const GLdouble* v);
+void gl1_4_glColor3d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue);
+void gl1_4_glColor3bv(void *_glfuncs, const GLbyte* v);
+void gl1_4_glColor3b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue);
+void gl1_4_glBitmap(void *_glfuncs, GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte* bitmap);
+void gl1_4_glBegin(void *_glfuncs, GLenum mode);
+void gl1_4_glListBase(void *_glfuncs, GLuint base);
+GLuint gl1_4_glGenLists(void *_glfuncs, GLsizei range_);
+void gl1_4_glDeleteLists(void *_glfuncs, GLuint list, GLsizei range_);
+void gl1_4_glCallLists(void *_glfuncs, GLsizei n, GLenum gltype, const GLvoid* lists);
+void gl1_4_glCallList(void *_glfuncs, GLuint list);
+void gl1_4_glEndList(void *_glfuncs);
+void gl1_4_glNewList(void *_glfuncs, GLuint list, GLenum mode);
+void gl1_4_glPushClientAttrib(void *_glfuncs, GLbitfield mask);
+void gl1_4_glPopClientAttrib(void *_glfuncs);
+void gl1_4_glPrioritizeTextures(void *_glfuncs, GLsizei n, const GLuint* textures, const GLfloat* priorities);
+GLboolean gl1_4_glAreTexturesResident(void *_glfuncs, GLsizei n, const GLuint* textures, GLboolean* residences);
+void gl1_4_glVertexPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl1_4_glTexCoordPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl1_4_glNormalPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl1_4_glInterleavedArrays(void *_glfuncs, GLenum format, GLsizei stride, const GLvoid* pointer);
+void gl1_4_glIndexPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl1_4_glEnableClientState(void *_glfuncs, GLenum array);
+void gl1_4_glEdgeFlagPointer(void *_glfuncs, GLsizei stride, const GLvoid* pointer);
+void gl1_4_glDisableClientState(void *_glfuncs, GLenum array);
+void gl1_4_glColorPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl1_4_glArrayElement(void *_glfuncs, GLint i);
+void gl1_4_glResetMinmax(void *_glfuncs, GLenum target);
+void gl1_4_glResetHistogram(void *_glfuncs, GLenum target);
+void gl1_4_glMinmax(void *_glfuncs, GLenum target, GLenum internalFormat, GLboolean sink);
+void gl1_4_glHistogram(void *_glfuncs, GLenum target, GLsizei width, GLenum internalFormat, GLboolean sink);
+void gl1_4_glGetMinmaxParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl1_4_glGetMinmaxParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl1_4_glGetMinmax(void *_glfuncs, GLenum target, GLboolean reset, GLenum format, GLenum gltype, GLvoid* values);
+void gl1_4_glGetHistogramParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl1_4_glGetHistogramParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl1_4_glGetHistogram(void *_glfuncs, GLenum target, GLboolean reset, GLenum format, GLenum gltype, GLvoid* values);
+void gl1_4_glSeparableFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* row, const GLvoid* column);
+void gl1_4_glGetSeparableFilter(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* row, GLvoid* column, GLvoid* span);
+void gl1_4_glGetConvolutionParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl1_4_glGetConvolutionParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl1_4_glGetConvolutionFilter(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* image);
+void gl1_4_glCopyConvolutionFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl1_4_glCopyConvolutionFilter1D(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width);
+void gl1_4_glConvolutionParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl1_4_glConvolutionParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint params);
+void gl1_4_glConvolutionParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl1_4_glConvolutionParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat params);
+void gl1_4_glConvolutionFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* image);
+void gl1_4_glConvolutionFilter1D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLenum format, GLenum gltype, const GLvoid* image);
+void gl1_4_glCopyColorSubTable(void *_glfuncs, GLenum target, GLsizei start, GLint x, GLint y, GLsizei width);
+void gl1_4_glColorSubTable(void *_glfuncs, GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum gltype, const GLvoid* data);
+void gl1_4_glGetColorTableParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl1_4_glGetColorTableParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl1_4_glGetColorTable(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* table);
+void gl1_4_glCopyColorTable(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width);
+void gl1_4_glColorTableParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl1_4_glColorTableParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl1_4_glColorTable(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLenum format, GLenum gltype, const GLvoid* table);
+void gl1_4_glMultTransposeMatrixd(void *_glfuncs, const GLdouble* m);
+void gl1_4_glMultTransposeMatrixf(void *_glfuncs, const GLfloat* m);
+void gl1_4_glLoadTransposeMatrixd(void *_glfuncs, const GLdouble* m);
+void gl1_4_glLoadTransposeMatrixf(void *_glfuncs, const GLfloat* m);
+void gl1_4_glMultiTexCoord4sv(void *_glfuncs, GLenum target, const GLshort* v);
+void gl1_4_glMultiTexCoord4s(void *_glfuncs, GLenum target, GLshort s, GLshort t, GLshort r, GLshort q);
+void gl1_4_glMultiTexCoord4iv(void *_glfuncs, GLenum target, const GLint* v);
+void gl1_4_glMultiTexCoord4i(void *_glfuncs, GLenum target, GLint s, GLint t, GLint r, GLint q);
+void gl1_4_glMultiTexCoord4fv(void *_glfuncs, GLenum target, const GLfloat* v);
+void gl1_4_glMultiTexCoord4f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+void gl1_4_glMultiTexCoord4dv(void *_glfuncs, GLenum target, const GLdouble* v);
+void gl1_4_glMultiTexCoord4d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+void gl1_4_glMultiTexCoord3sv(void *_glfuncs, GLenum target, const GLshort* v);
+void gl1_4_glMultiTexCoord3s(void *_glfuncs, GLenum target, GLshort s, GLshort t, GLshort r);
+void gl1_4_glMultiTexCoord3iv(void *_glfuncs, GLenum target, const GLint* v);
+void gl1_4_glMultiTexCoord3i(void *_glfuncs, GLenum target, GLint s, GLint t, GLint r);
+void gl1_4_glMultiTexCoord3fv(void *_glfuncs, GLenum target, const GLfloat* v);
+void gl1_4_glMultiTexCoord3f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t, GLfloat r);
+void gl1_4_glMultiTexCoord3dv(void *_glfuncs, GLenum target, const GLdouble* v);
+void gl1_4_glMultiTexCoord3d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t, GLdouble r);
+void gl1_4_glMultiTexCoord2sv(void *_glfuncs, GLenum target, const GLshort* v);
+void gl1_4_glMultiTexCoord2s(void *_glfuncs, GLenum target, GLshort s, GLshort t);
+void gl1_4_glMultiTexCoord2iv(void *_glfuncs, GLenum target, const GLint* v);
+void gl1_4_glMultiTexCoord2i(void *_glfuncs, GLenum target, GLint s, GLint t);
+void gl1_4_glMultiTexCoord2fv(void *_glfuncs, GLenum target, const GLfloat* v);
+void gl1_4_glMultiTexCoord2f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t);
+void gl1_4_glMultiTexCoord2dv(void *_glfuncs, GLenum target, const GLdouble* v);
+void gl1_4_glMultiTexCoord2d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t);
+void gl1_4_glMultiTexCoord1sv(void *_glfuncs, GLenum target, const GLshort* v);
+void gl1_4_glMultiTexCoord1s(void *_glfuncs, GLenum target, GLshort s);
+void gl1_4_glMultiTexCoord1iv(void *_glfuncs, GLenum target, const GLint* v);
+void gl1_4_glMultiTexCoord1i(void *_glfuncs, GLenum target, GLint s);
+void gl1_4_glMultiTexCoord1fv(void *_glfuncs, GLenum target, const GLfloat* v);
+void gl1_4_glMultiTexCoord1f(void *_glfuncs, GLenum target, GLfloat s);
+void gl1_4_glMultiTexCoord1dv(void *_glfuncs, GLenum target, const GLdouble* v);
+void gl1_4_glMultiTexCoord1d(void *_glfuncs, GLenum target, GLdouble s);
+void gl1_4_glClientActiveTexture(void *_glfuncs, GLenum texture);
+void gl1_4_glWindowPos3sv(void *_glfuncs, const GLshort* v);
+void gl1_4_glWindowPos3s(void *_glfuncs, GLshort x, GLshort y, GLshort z);
+void gl1_4_glWindowPos3iv(void *_glfuncs, const GLint* v);
+void gl1_4_glWindowPos3i(void *_glfuncs, GLint x, GLint y, GLint z);
+void gl1_4_glWindowPos3fv(void *_glfuncs, const GLfloat* v);
+void gl1_4_glWindowPos3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl1_4_glWindowPos3dv(void *_glfuncs, const GLdouble* v);
+void gl1_4_glWindowPos3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl1_4_glWindowPos2sv(void *_glfuncs, const GLshort* v);
+void gl1_4_glWindowPos2s(void *_glfuncs, GLshort x, GLshort y);
+void gl1_4_glWindowPos2iv(void *_glfuncs, const GLint* v);
+void gl1_4_glWindowPos2i(void *_glfuncs, GLint x, GLint y);
+void gl1_4_glWindowPos2fv(void *_glfuncs, const GLfloat* v);
+void gl1_4_glWindowPos2f(void *_glfuncs, GLfloat x, GLfloat y);
+void gl1_4_glWindowPos2dv(void *_glfuncs, const GLdouble* v);
+void gl1_4_glWindowPos2d(void *_glfuncs, GLdouble x, GLdouble y);
+void gl1_4_glSecondaryColorPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl1_4_glSecondaryColor3usv(void *_glfuncs, const GLushort* v);
+void gl1_4_glSecondaryColor3us(void *_glfuncs, GLushort red, GLushort green, GLushort blue);
+void gl1_4_glSecondaryColor3uiv(void *_glfuncs, const GLuint* v);
+void gl1_4_glSecondaryColor3ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue);
+void gl1_4_glSecondaryColor3ubv(void *_glfuncs, const GLubyte* v);
+void gl1_4_glSecondaryColor3ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue);
+void gl1_4_glSecondaryColor3sv(void *_glfuncs, const GLshort* v);
+void gl1_4_glSecondaryColor3s(void *_glfuncs, GLshort red, GLshort green, GLshort blue);
+void gl1_4_glSecondaryColor3iv(void *_glfuncs, const GLint* v);
+void gl1_4_glSecondaryColor3i(void *_glfuncs, GLint red, GLint green, GLint blue);
+void gl1_4_glSecondaryColor3fv(void *_glfuncs, const GLfloat* v);
+void gl1_4_glSecondaryColor3f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue);
+void gl1_4_glSecondaryColor3dv(void *_glfuncs, const GLdouble* v);
+void gl1_4_glSecondaryColor3d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue);
+void gl1_4_glSecondaryColor3bv(void *_glfuncs, const GLbyte* v);
+void gl1_4_glSecondaryColor3b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue);
+void gl1_4_glFogCoordPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl1_4_glFogCoorddv(void *_glfuncs, const GLdouble* coord);
+void gl1_4_glFogCoordd(void *_glfuncs, GLdouble coord);
+void gl1_4_glFogCoordfv(void *_glfuncs, const GLfloat* coord);
+void gl1_4_glFogCoordf(void *_glfuncs, GLfloat coord);
+
+
+#ifdef __cplusplus
+} // extern "C"
+#endif
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/1.4/gl.go b/Godeps/_workspace/src/github.com/obscuren/qml/gl/1.4/gl.go
new file mode 100644
index 000000000..6ddbc2441
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/1.4/gl.go
@@ -0,0 +1,3892 @@
+// ** file automatically generated by glgen -- do not edit manually **
+
+package GL
+
+// #cgo CXXFLAGS: -std=c++0x -pedantic-errors -Wall -fno-strict-aliasing
+// #cgo LDFLAGS: -lstdc++
+// #cgo pkg-config: Qt5Core Qt5OpenGL
+//
+// #include "funcs.h"
+//
+// void free(void*);
+//
+import "C"
+
+import (
+ "fmt"
+ "reflect"
+ "unsafe"
+
+ "gopkg.in/qml.v1/gl/glbase"
+)
+
+// API returns a value that offers methods matching the OpenGL version 1.4 API.
+//
+// The returned API must not be used after the provided OpenGL context becomes invalid.
+func API(context glbase.Contexter) *GL {
+ gl := &GL{}
+ gl.funcs = C.gl1_4_funcs()
+ if gl.funcs == nil {
+ panic(fmt.Errorf("OpenGL version 1.4 is not available"))
+ }
+ return gl
+}
+
+// GL implements the OpenGL version 1.4 API. Values of this
+// type must be created via the API function, and it must not be used after
+// the associated OpenGL context becomes invalid.
+type GL struct {
+ funcs unsafe.Pointer
+}
+
+const (
+ FALSE = 0
+ TRUE = 1
+ NONE = 0
+
+ BYTE = 0x1400
+ UNSIGNED_BYTE = 0x1401
+ SHORT = 0x1402
+ UNSIGNED_SHORT = 0x1403
+ INT = 0x1404
+ UNSIGNED_INT = 0x1405
+ FLOAT = 0x1406
+ N2_BYTES = 0x1407
+ N3_BYTES = 0x1408
+ N4_BYTES = 0x1409
+ DOUBLE = 0x140A
+
+ ACCUM = 0x0100
+ LOAD = 0x0101
+ RETURN = 0x0102
+ MULT = 0x0103
+ ADD = 0x0104
+
+ ACCUM_BUFFER_BIT = 0x00000200
+ ALL_ATTRIB_BITS = 0xFFFFFFFF
+ COLOR_BUFFER_BIT = 0x00004000
+ CURRENT_BIT = 0x00000001
+ DEPTH_BUFFER_BIT = 0x00000100
+ ENABLE_BIT = 0x00002000
+ EVAL_BIT = 0x00010000
+ FOG_BIT = 0x00000080
+ HINT_BIT = 0x00008000
+ LIGHTING_BIT = 0x00000040
+ LINE_BIT = 0x00000004
+ LIST_BIT = 0x00020000
+ MULTISAMPLE_BIT = 0x20000000
+ PIXEL_MODE_BIT = 0x00000020
+ POINT_BIT = 0x00000002
+ POLYGON_BIT = 0x00000008
+ POLYGON_STIPPLE_BIT = 0x00000010
+ SCISSOR_BIT = 0x00080000
+ STENCIL_BUFFER_BIT = 0x00000400
+ TEXTURE_BIT = 0x00040000
+ TRANSFORM_BIT = 0x00001000
+ VIEWPORT_BIT = 0x00000800
+
+ ALWAYS = 0x0207
+ EQUAL = 0x0202
+ GEQUAL = 0x0206
+ GREATER = 0x0204
+ LEQUAL = 0x0203
+ LESS = 0x0201
+ NEVER = 0x0200
+ NOTEQUAL = 0x0205
+
+ LOGIC_OP = 0x0BF1
+
+ DST_ALPHA = 0x0304
+ ONE = 1
+ ONE_MINUS_DST_ALPHA = 0x0305
+ ONE_MINUS_SRC_ALPHA = 0x0303
+ ONE_MINUS_SRC_COLOR = 0x0301
+ SRC_ALPHA = 0x0302
+ SRC_COLOR = 0x0300
+ ZERO = 0
+
+ DST_COLOR = 0x0306
+ ONE_MINUS_DST_COLOR = 0x0307
+ SRC_ALPHA_SATURATE = 0x0308
+
+ CLIENT_ALL_ATTRIB_BITS = 0xFFFFFFFF
+ CLIENT_PIXEL_STORE_BIT = 0x00000001
+ CLIENT_VERTEX_ARRAY_BIT = 0x00000002
+
+ CLIP_PLANE0 = 0x3000
+ CLIP_PLANE1 = 0x3001
+ CLIP_PLANE2 = 0x3002
+ CLIP_PLANE3 = 0x3003
+ CLIP_PLANE4 = 0x3004
+ CLIP_PLANE5 = 0x3005
+
+ BACK = 0x0405
+ FRONT = 0x0404
+ FRONT_AND_BACK = 0x0408
+
+ AMBIENT = 0x1200
+ AMBIENT_AND_DIFFUSE = 0x1602
+ DIFFUSE = 0x1201
+ EMISSION = 0x1600
+ SPECULAR = 0x1202
+
+ AUX0 = 0x0409
+ AUX1 = 0x040A
+ AUX2 = 0x040B
+ AUX3 = 0x040C
+ BACK_LEFT = 0x0402
+ BACK_RIGHT = 0x0403
+ FRONT_LEFT = 0x0400
+ FRONT_RIGHT = 0x0401
+ LEFT = 0x0406
+ RIGHT = 0x0407
+
+ ALPHA_TEST = 0x0BC0
+ AUTO_NORMAL = 0x0D80
+ BLEND = 0x0BE2
+ COLOR_ARRAY = 0x8076
+ COLOR_LOGIC_OP = 0x0BF2
+ COLOR_MATERIAL = 0x0B57
+ CULL_FACE = 0x0B44
+ DEPTH_TEST = 0x0B71
+ DITHER = 0x0BD0
+ EDGE_FLAG_ARRAY = 0x8079
+ FOG = 0x0B60
+ INDEX_ARRAY = 0x8077
+ INDEX_LOGIC_OP = 0x0BF1
+ LIGHT0 = 0x4000
+ LIGHT1 = 0x4001
+ LIGHT2 = 0x4002
+ LIGHT3 = 0x4003
+ LIGHT4 = 0x4004
+ LIGHT5 = 0x4005
+ LIGHT6 = 0x4006
+ LIGHT7 = 0x4007
+ LIGHTING = 0x0B50
+ LINE_SMOOTH = 0x0B20
+ LINE_STIPPLE = 0x0B24
+ MAP1_COLOR_4 = 0x0D90
+ MAP1_INDEX = 0x0D91
+ MAP1_NORMAL = 0x0D92
+ MAP1_TEXTURE_COORD_1 = 0x0D93
+ MAP1_TEXTURE_COORD_2 = 0x0D94
+ MAP1_TEXTURE_COORD_3 = 0x0D95
+ MAP1_TEXTURE_COORD_4 = 0x0D96
+ MAP1_VERTEX_3 = 0x0D97
+ MAP1_VERTEX_4 = 0x0D98
+ MAP2_COLOR_4 = 0x0DB0
+ MAP2_INDEX = 0x0DB1
+ MAP2_NORMAL = 0x0DB2
+ MAP2_TEXTURE_COORD_1 = 0x0DB3
+ MAP2_TEXTURE_COORD_2 = 0x0DB4
+ MAP2_TEXTURE_COORD_3 = 0x0DB5
+ MAP2_TEXTURE_COORD_4 = 0x0DB6
+ MAP2_VERTEX_3 = 0x0DB7
+ MAP2_VERTEX_4 = 0x0DB8
+ NORMALIZE = 0x0BA1
+ NORMAL_ARRAY = 0x8075
+ POINT_SMOOTH = 0x0B10
+ POLYGON_OFFSET_FILL = 0x8037
+ POLYGON_OFFSET_LINE = 0x2A02
+ POLYGON_OFFSET_POINT = 0x2A01
+ POLYGON_SMOOTH = 0x0B41
+ POLYGON_STIPPLE = 0x0B42
+ SCISSOR_TEST = 0x0C11
+ STENCIL_TEST = 0x0B90
+ TEXTURE_1D = 0x0DE0
+ TEXTURE_2D = 0x0DE1
+ TEXTURE_COORD_ARRAY = 0x8078
+ TEXTURE_GEN_Q = 0x0C63
+ TEXTURE_GEN_R = 0x0C62
+ TEXTURE_GEN_S = 0x0C60
+ TEXTURE_GEN_T = 0x0C61
+ VERTEX_ARRAY = 0x8074
+
+ INVALID_ENUM = 0x0500
+ INVALID_OPERATION = 0x0502
+ INVALID_VALUE = 0x0501
+ NO_ERROR = 0
+ OUT_OF_MEMORY = 0x0505
+ STACK_OVERFLOW = 0x0503
+ STACK_UNDERFLOW = 0x0504
+
+ N2D = 0x0600
+ N3D = 0x0601
+ N3D_COLOR = 0x0602
+ N3D_COLOR_TEXTURE = 0x0603
+ N4D_COLOR_TEXTURE = 0x0604
+
+ BITMAP_TOKEN = 0x0704
+ COPY_PIXEL_TOKEN = 0x0706
+ DRAW_PIXEL_TOKEN = 0x0705
+ LINE_RESET_TOKEN = 0x0707
+ LINE_TOKEN = 0x0702
+ PASS_THROUGH_TOKEN = 0x0700
+ POINT_TOKEN = 0x0701
+ POLYGON_TOKEN = 0x0703
+
+ EXP = 0x0800
+ EXP2 = 0x0801
+ LINEAR = 0x2601
+
+ FOG_COLOR = 0x0B66
+ FOG_DENSITY = 0x0B62
+ FOG_END = 0x0B64
+ FOG_INDEX = 0x0B61
+ FOG_MODE = 0x0B65
+ FOG_START = 0x0B63
+
+ CCW = 0x0901
+ CW = 0x0900
+
+ COEFF = 0x0A00
+ DOMAIN = 0x0A02
+ ORDER = 0x0A01
+
+ PIXEL_MAP_A_TO_A = 0x0C79
+ PIXEL_MAP_B_TO_B = 0x0C78
+ PIXEL_MAP_G_TO_G = 0x0C77
+ PIXEL_MAP_I_TO_A = 0x0C75
+ PIXEL_MAP_I_TO_B = 0x0C74
+ PIXEL_MAP_I_TO_G = 0x0C73
+ PIXEL_MAP_I_TO_I = 0x0C70
+ PIXEL_MAP_I_TO_R = 0x0C72
+ PIXEL_MAP_R_TO_R = 0x0C76
+ PIXEL_MAP_S_TO_S = 0x0C71
+
+ ACCUM_ALPHA_BITS = 0x0D5B
+ ACCUM_BLUE_BITS = 0x0D5A
+ ACCUM_CLEAR_VALUE = 0x0B80
+ ACCUM_GREEN_BITS = 0x0D59
+ ACCUM_RED_BITS = 0x0D58
+ ALIASED_LINE_WIDTH_RANGE = 0x846E
+ ALIASED_POINT_SIZE_RANGE = 0x846D
+ ALPHA_BIAS = 0x0D1D
+ ALPHA_BITS = 0x0D55
+ ALPHA_SCALE = 0x0D1C
+ ALPHA_TEST_FUNC = 0x0BC1
+ ALPHA_TEST_REF = 0x0BC2
+ ATTRIB_STACK_DEPTH = 0x0BB0
+ AUX_BUFFERS = 0x0C00
+ BLEND_DST = 0x0BE0
+ BLEND_SRC = 0x0BE1
+ BLUE_BIAS = 0x0D1B
+ BLUE_BITS = 0x0D54
+ BLUE_SCALE = 0x0D1A
+ CLIENT_ATTRIB_STACK_DEPTH = 0x0BB1
+ COLOR_ARRAY_SIZE = 0x8081
+ COLOR_ARRAY_STRIDE = 0x8083
+ COLOR_ARRAY_TYPE = 0x8082
+ COLOR_CLEAR_VALUE = 0x0C22
+ COLOR_MATERIAL_FACE = 0x0B55
+ COLOR_MATERIAL_PARAMETER = 0x0B56
+ COLOR_WRITEMASK = 0x0C23
+ CULL_FACE_MODE = 0x0B45
+ CURRENT_COLOR = 0x0B00
+ CURRENT_INDEX = 0x0B01
+ CURRENT_NORMAL = 0x0B02
+ CURRENT_RASTER_COLOR = 0x0B04
+ CURRENT_RASTER_DISTANCE = 0x0B09
+ CURRENT_RASTER_INDEX = 0x0B05
+ CURRENT_RASTER_POSITION = 0x0B07
+ CURRENT_RASTER_POSITION_VALID = 0x0B08
+ CURRENT_RASTER_TEXTURE_COORDS = 0x0B06
+ CURRENT_TEXTURE_COORDS = 0x0B03
+ DEPTH_BIAS = 0x0D1F
+ DEPTH_BITS = 0x0D56
+ DEPTH_CLEAR_VALUE = 0x0B73
+ DEPTH_FUNC = 0x0B74
+ DEPTH_RANGE = 0x0B70
+ DEPTH_SCALE = 0x0D1E
+ DEPTH_WRITEMASK = 0x0B72
+ DOUBLEBUFFER = 0x0C32
+ DRAW_BUFFER = 0x0C01
+ EDGE_FLAG = 0x0B43
+ EDGE_FLAG_ARRAY_STRIDE = 0x808C
+ FEEDBACK_BUFFER_SIZE = 0x0DF1
+ FEEDBACK_BUFFER_TYPE = 0x0DF2
+ FOG_HINT = 0x0C54
+ FRONT_FACE = 0x0B46
+ GREEN_BIAS = 0x0D19
+ GREEN_BITS = 0x0D53
+ GREEN_SCALE = 0x0D18
+ INDEX_ARRAY_STRIDE = 0x8086
+ INDEX_ARRAY_TYPE = 0x8085
+ INDEX_BITS = 0x0D51
+ INDEX_CLEAR_VALUE = 0x0C20
+ INDEX_MODE = 0x0C30
+ INDEX_OFFSET = 0x0D13
+ INDEX_SHIFT = 0x0D12
+ INDEX_WRITEMASK = 0x0C21
+ LIGHT_MODEL_AMBIENT = 0x0B53
+ LIGHT_MODEL_COLOR_CONTROL = 0x81F8
+ LIGHT_MODEL_LOCAL_VIEWER = 0x0B51
+ LIGHT_MODEL_TWO_SIDE = 0x0B52
+ LINE_SMOOTH_HINT = 0x0C52
+ LINE_STIPPLE_PATTERN = 0x0B25
+ LINE_STIPPLE_REPEAT = 0x0B26
+ LINE_WIDTH = 0x0B21
+ LINE_WIDTH_GRANULARITY = 0x0B23
+ LINE_WIDTH_RANGE = 0x0B22
+ LIST_BASE = 0x0B32
+ LIST_INDEX = 0x0B33
+ LIST_MODE = 0x0B30
+ LOGIC_OP_MODE = 0x0BF0
+ MAP1_GRID_DOMAIN = 0x0DD0
+ MAP1_GRID_SEGMENTS = 0x0DD1
+ MAP2_GRID_DOMAIN = 0x0DD2
+ MAP2_GRID_SEGMENTS = 0x0DD3
+ MAP_COLOR = 0x0D10
+ MAP_STENCIL = 0x0D11
+ MATRIX_MODE = 0x0BA0
+ MAX_ATTRIB_STACK_DEPTH = 0x0D35
+ MAX_CLIENT_ATTRIB_STACK_DEPTH = 0x0D3B
+ MAX_CLIP_PLANES = 0x0D32
+ MAX_EVAL_ORDER = 0x0D30
+ MAX_LIGHTS = 0x0D31
+ MAX_LIST_NESTING = 0x0B31
+ MAX_MODELVIEW_STACK_DEPTH = 0x0D36
+ MAX_NAME_STACK_DEPTH = 0x0D37
+ MAX_PIXEL_MAP_TABLE = 0x0D34
+ MAX_PROJECTION_STACK_DEPTH = 0x0D38
+ MAX_TEXTURE_SIZE = 0x0D33
+ MAX_TEXTURE_STACK_DEPTH = 0x0D39
+ MAX_VIEWPORT_DIMS = 0x0D3A
+ MODELVIEW_MATRIX = 0x0BA6
+ MODELVIEW_STACK_DEPTH = 0x0BA3
+ NAME_STACK_DEPTH = 0x0D70
+ NORMAL_ARRAY_STRIDE = 0x807F
+ NORMAL_ARRAY_TYPE = 0x807E
+ PACK_ALIGNMENT = 0x0D05
+ PACK_LSB_FIRST = 0x0D01
+ PACK_ROW_LENGTH = 0x0D02
+ PACK_SKIP_PIXELS = 0x0D04
+ PACK_SKIP_ROWS = 0x0D03
+ PACK_SWAP_BYTES = 0x0D00
+ PERSPECTIVE_CORRECTION_HINT = 0x0C50
+ PIXEL_MAP_A_TO_A_SIZE = 0x0CB9
+ PIXEL_MAP_B_TO_B_SIZE = 0x0CB8
+ PIXEL_MAP_G_TO_G_SIZE = 0x0CB7
+ PIXEL_MAP_I_TO_A_SIZE = 0x0CB5
+ PIXEL_MAP_I_TO_B_SIZE = 0x0CB4
+ PIXEL_MAP_I_TO_G_SIZE = 0x0CB3
+ PIXEL_MAP_I_TO_I_SIZE = 0x0CB0
+ PIXEL_MAP_I_TO_R_SIZE = 0x0CB2
+ PIXEL_MAP_R_TO_R_SIZE = 0x0CB6
+ PIXEL_MAP_S_TO_S_SIZE = 0x0CB1
+ POINT_SIZE = 0x0B11
+ POINT_SIZE_GRANULARITY = 0x0B13
+ POINT_SIZE_RANGE = 0x0B12
+ POINT_SMOOTH_HINT = 0x0C51
+ POLYGON_MODE = 0x0B40
+ POLYGON_OFFSET_FACTOR = 0x8038
+ POLYGON_OFFSET_UNITS = 0x2A00
+ POLYGON_SMOOTH_HINT = 0x0C53
+ PROJECTION_MATRIX = 0x0BA7
+ PROJECTION_STACK_DEPTH = 0x0BA4
+ READ_BUFFER = 0x0C02
+ RED_BIAS = 0x0D15
+ RED_BITS = 0x0D52
+ RED_SCALE = 0x0D14
+ RENDER_MODE = 0x0C40
+ RGBA_MODE = 0x0C31
+ SCISSOR_BOX = 0x0C10
+ SELECTION_BUFFER_SIZE = 0x0DF4
+ SHADE_MODEL = 0x0B54
+ SMOOTH_LINE_WIDTH_GRANULARITY = 0x0B23
+ SMOOTH_LINE_WIDTH_RANGE = 0x0B22
+ SMOOTH_POINT_SIZE_GRANULARITY = 0x0B13
+ SMOOTH_POINT_SIZE_RANGE = 0x0B12
+ STENCIL_BITS = 0x0D57
+ STENCIL_CLEAR_VALUE = 0x0B91
+ STENCIL_FAIL = 0x0B94
+ STENCIL_FUNC = 0x0B92
+ STENCIL_PASS_DEPTH_FAIL = 0x0B95
+ STENCIL_PASS_DEPTH_PASS = 0x0B96
+ STENCIL_REF = 0x0B97
+ STENCIL_VALUE_MASK = 0x0B93
+ STENCIL_WRITEMASK = 0x0B98
+ STEREO = 0x0C33
+ SUBPIXEL_BITS = 0x0D50
+ TEXTURE_BINDING_1D = 0x8068
+ TEXTURE_BINDING_2D = 0x8069
+ TEXTURE_BINDING_3D = 0x806A
+ TEXTURE_COORD_ARRAY_SIZE = 0x8088
+ TEXTURE_COORD_ARRAY_STRIDE = 0x808A
+ TEXTURE_COORD_ARRAY_TYPE = 0x8089
+ TEXTURE_MATRIX = 0x0BA8
+ TEXTURE_STACK_DEPTH = 0x0BA5
+ UNPACK_ALIGNMENT = 0x0CF5
+ UNPACK_LSB_FIRST = 0x0CF1
+ UNPACK_ROW_LENGTH = 0x0CF2
+ UNPACK_SKIP_PIXELS = 0x0CF4
+ UNPACK_SKIP_ROWS = 0x0CF3
+ UNPACK_SWAP_BYTES = 0x0CF0
+ VERTEX_ARRAY_SIZE = 0x807A
+ VERTEX_ARRAY_STRIDE = 0x807C
+ VERTEX_ARRAY_TYPE = 0x807B
+ VIEWPORT = 0x0BA2
+ ZOOM_X = 0x0D16
+ ZOOM_Y = 0x0D17
+
+ COLOR_ARRAY_POINTER = 0x8090
+ EDGE_FLAG_ARRAY_POINTER = 0x8093
+ FEEDBACK_BUFFER_POINTER = 0x0DF0
+ INDEX_ARRAY_POINTER = 0x8091
+ NORMAL_ARRAY_POINTER = 0x808F
+ SELECTION_BUFFER_POINTER = 0x0DF3
+ TEXTURE_COORD_ARRAY_POINTER = 0x8092
+ VERTEX_ARRAY_POINTER = 0x808E
+
+ TEXTURE_ALPHA_SIZE = 0x805F
+ TEXTURE_BLUE_SIZE = 0x805E
+ TEXTURE_BORDER = 0x1005
+ TEXTURE_BORDER_COLOR = 0x1004
+ TEXTURE_COMPONENTS = 0x1003
+ TEXTURE_GREEN_SIZE = 0x805D
+ TEXTURE_HEIGHT = 0x1001
+ TEXTURE_INTENSITY_SIZE = 0x8061
+ TEXTURE_INTERNAL_FORMAT = 0x1003
+ TEXTURE_LUMINANCE_SIZE = 0x8060
+ TEXTURE_MAG_FILTER = 0x2800
+ TEXTURE_MIN_FILTER = 0x2801
+ TEXTURE_PRIORITY = 0x8066
+ TEXTURE_RED_SIZE = 0x805C
+ TEXTURE_RESIDENT = 0x8067
+ TEXTURE_WIDTH = 0x1000
+ TEXTURE_WRAP_S = 0x2802
+ TEXTURE_WRAP_T = 0x2803
+
+ DONT_CARE = 0x1100
+ FASTEST = 0x1101
+ NICEST = 0x1102
+
+ GENERATE_MIPMAP_HINT = 0x8192
+ TEXTURE_COMPRESSION_HINT = 0x84EF
+
+ C3F_V3F = 0x2A24
+ C4F_N3F_V3F = 0x2A26
+ C4UB_V2F = 0x2A22
+ C4UB_V3F = 0x2A23
+ N3F_V3F = 0x2A25
+ T2F_C3F_V3F = 0x2A2A
+ T2F_C4F_N3F_V3F = 0x2A2C
+ T2F_C4UB_V3F = 0x2A29
+ T2F_N3F_V3F = 0x2A2B
+ T2F_V3F = 0x2A27
+ T4F_C4F_N3F_V4F = 0x2A2D
+ T4F_V4F = 0x2A28
+ V2F = 0x2A20
+ V3F = 0x2A21
+
+ MODULATE = 0x2100
+ REPLACE = 0x1E01
+
+ SEPARATE_SPECULAR_COLOR = 0x81FA
+ SINGLE_COLOR = 0x81F9
+
+ CONSTANT_ATTENUATION = 0x1207
+ LINEAR_ATTENUATION = 0x1208
+ POSITION = 0x1203
+ QUADRATIC_ATTENUATION = 0x1209
+ SPOT_CUTOFF = 0x1206
+ SPOT_DIRECTION = 0x1204
+ SPOT_EXPONENT = 0x1205
+
+ COMPILE = 0x1300
+ COMPILE_AND_EXECUTE = 0x1301
+
+ AND = 0x1501
+ AND_INVERTED = 0x1504
+ AND_REVERSE = 0x1502
+ CLEAR = 0x1500
+ COPY = 0x1503
+ COPY_INVERTED = 0x150C
+ EQUIV = 0x1509
+ INVERT = 0x150A
+ NAND = 0x150E
+ NOOP = 0x1505
+ NOR = 0x1508
+ OR = 0x1507
+ OR_INVERTED = 0x150D
+ OR_REVERSE = 0x150B
+ SET = 0x150F
+ XOR = 0x1506
+
+ COLOR_INDEXES = 0x1603
+ SHININESS = 0x1601
+
+ MODELVIEW = 0x1700
+ PROJECTION = 0x1701
+ TEXTURE = 0x1702
+
+ LINE = 0x1B01
+ POINT = 0x1B00
+
+ FILL = 0x1B02
+
+ COLOR = 0x1800
+ DEPTH = 0x1801
+ STENCIL = 0x1802
+
+ ALPHA = 0x1906
+ BLUE = 0x1905
+ COLOR_INDEX = 0x1900
+ DEPTH_COMPONENT = 0x1902
+ GREEN = 0x1904
+ LUMINANCE = 0x1909
+ LUMINANCE_ALPHA = 0x190A
+ RED = 0x1903
+ RGB = 0x1907
+ RGBA = 0x1908
+ STENCIL_INDEX = 0x1901
+
+ ALPHA12 = 0x803D
+ ALPHA16 = 0x803E
+ ALPHA4 = 0x803B
+ ALPHA8 = 0x803C
+ INTENSITY = 0x8049
+ INTENSITY12 = 0x804C
+ INTENSITY16 = 0x804D
+ INTENSITY4 = 0x804A
+ INTENSITY8 = 0x804B
+ LUMINANCE12 = 0x8041
+ LUMINANCE12_ALPHA12 = 0x8047
+ LUMINANCE12_ALPHA4 = 0x8046
+ LUMINANCE16 = 0x8042
+ LUMINANCE16_ALPHA16 = 0x8048
+ LUMINANCE4 = 0x803F
+ LUMINANCE4_ALPHA4 = 0x8043
+ LUMINANCE6_ALPHA2 = 0x8044
+ LUMINANCE8 = 0x8040
+ LUMINANCE8_ALPHA8 = 0x8045
+ R3_G3_B2 = 0x2A10
+ RGB10 = 0x8052
+ RGB10_A2 = 0x8059
+ RGB12 = 0x8053
+ RGB16 = 0x8054
+ RGB4 = 0x804F
+ RGB5 = 0x8050
+ RGB5_A1 = 0x8057
+ RGB8 = 0x8051
+ RGBA12 = 0x805A
+ RGBA16 = 0x805B
+ RGBA2 = 0x8055
+ RGBA4 = 0x8056
+ RGBA8 = 0x8058
+
+ PACK_IMAGE_HEIGHT = 0x806C
+ PACK_SKIP_IMAGES = 0x806B
+ UNPACK_IMAGE_HEIGHT = 0x806E
+ UNPACK_SKIP_IMAGES = 0x806D
+
+ BITMAP = 0x1A00
+ UNSIGNED_BYTE_3_3_2 = 0x8032
+ UNSIGNED_INT_10_10_10_2 = 0x8036
+ UNSIGNED_INT_8_8_8_8 = 0x8035
+ UNSIGNED_SHORT_4_4_4_4 = 0x8033
+ UNSIGNED_SHORT_5_5_5_1 = 0x8034
+
+ POINT_DISTANCE_ATTENUATION = 0x8129
+ POINT_FADE_THRESHOLD_SIZE = 0x8128
+ POINT_SIZE_MAX = 0x8127
+ POINT_SIZE_MIN = 0x8126
+
+ LINES = 0x0001
+ LINE_LOOP = 0x0002
+ LINE_STRIP = 0x0003
+ POINTS = 0x0000
+ POLYGON = 0x0009
+ QUADS = 0x0007
+ QUAD_STRIP = 0x0008
+ TRIANGLES = 0x0004
+ TRIANGLE_FAN = 0x0006
+ TRIANGLE_STRIP = 0x0005
+
+ FEEDBACK = 0x1C01
+ RENDER = 0x1C00
+ SELECT = 0x1C02
+
+ FLAT = 0x1D00
+ SMOOTH = 0x1D01
+
+ DECR = 0x1E03
+ INCR = 0x1E02
+ KEEP = 0x1E00
+
+ EXTENSIONS = 0x1F03
+ RENDERER = 0x1F01
+ VENDOR = 0x1F00
+ VERSION = 0x1F02
+
+ S = 0x2000
+ T = 0x2001
+ R = 0x2002
+ Q = 0x2003
+
+ DECAL = 0x2101
+
+ TEXTURE_ENV_COLOR = 0x2201
+ TEXTURE_ENV_MODE = 0x2200
+
+ TEXTURE_ENV = 0x2300
+
+ EYE_LINEAR = 0x2400
+ OBJECT_LINEAR = 0x2401
+ SPHERE_MAP = 0x2402
+
+ EYE_PLANE = 0x2502
+ OBJECT_PLANE = 0x2501
+ TEXTURE_GEN_MODE = 0x2500
+
+ NEAREST = 0x2600
+
+ LINEAR_MIPMAP_LINEAR = 0x2703
+ LINEAR_MIPMAP_NEAREST = 0x2701
+ NEAREST_MIPMAP_LINEAR = 0x2702
+ NEAREST_MIPMAP_NEAREST = 0x2700
+
+ GENERATE_MIPMAP = 0x8191
+ TEXTURE_WRAP_R = 0x8072
+
+ PROXY_TEXTURE_1D = 0x8063
+ PROXY_TEXTURE_2D = 0x8064
+ PROXY_TEXTURE_3D = 0x8070
+ TEXTURE_3D = 0x806F
+ TEXTURE_BASE_LEVEL = 0x813C
+ TEXTURE_MAX_LEVEL = 0x813D
+ TEXTURE_MAX_LOD = 0x813B
+ TEXTURE_MIN_LOD = 0x813A
+
+ CLAMP = 0x2900
+ CLAMP_TO_BORDER = 0x812D
+ CLAMP_TO_EDGE = 0x812F
+ REPEAT = 0x2901
+
+ CONSTANT_COLOR = 0x8001
+ ONE_MINUS_CONSTANT_COLOR = 0x8002
+ CONSTANT_ALPHA = 0x8003
+ ONE_MINUS_CONSTANT_ALPHA = 0x8004
+ FUNC_ADD = 0x8006
+ MIN = 0x8007
+ MAX = 0x8008
+ FUNC_SUBTRACT = 0x800A
+ FUNC_REVERSE_SUBTRACT = 0x800B
+ RESCALE_NORMAL = 0x803A
+ TEXTURE_DEPTH = 0x8071
+ MAX_3D_TEXTURE_SIZE = 0x8073
+ MULTISAMPLE = 0x809D
+ SAMPLE_ALPHA_TO_COVERAGE = 0x809E
+ SAMPLE_ALPHA_TO_ONE = 0x809F
+ SAMPLE_COVERAGE = 0x80A0
+ SAMPLE_BUFFERS = 0x80A8
+ SAMPLES = 0x80A9
+ SAMPLE_COVERAGE_VALUE = 0x80AA
+ SAMPLE_COVERAGE_INVERT = 0x80AB
+ BLEND_DST_RGB = 0x80C8
+ BLEND_SRC_RGB = 0x80C9
+ BLEND_DST_ALPHA = 0x80CA
+ BLEND_SRC_ALPHA = 0x80CB
+ BGR = 0x80E0
+ BGRA = 0x80E1
+ MAX_ELEMENTS_VERTICES = 0x80E8
+ MAX_ELEMENTS_INDICES = 0x80E9
+ DEPTH_COMPONENT16 = 0x81A5
+ DEPTH_COMPONENT24 = 0x81A6
+ DEPTH_COMPONENT32 = 0x81A7
+ UNSIGNED_BYTE_2_3_3_REV = 0x8362
+ UNSIGNED_SHORT_5_6_5 = 0x8363
+ UNSIGNED_SHORT_5_6_5_REV = 0x8364
+ UNSIGNED_SHORT_4_4_4_4_REV = 0x8365
+ UNSIGNED_SHORT_1_5_5_5_REV = 0x8366
+ UNSIGNED_INT_8_8_8_8_REV = 0x8367
+ UNSIGNED_INT_2_10_10_10_REV = 0x8368
+ MIRRORED_REPEAT = 0x8370
+ FOG_COORDINATE_SOURCE = 0x8450
+ FOG_COORDINATE = 0x8451
+ FRAGMENT_DEPTH = 0x8452
+ CURRENT_FOG_COORDINATE = 0x8453
+ FOG_COORDINATE_ARRAY_TYPE = 0x8454
+ FOG_COORDINATE_ARRAY_STRIDE = 0x8455
+ FOG_COORDINATE_ARRAY_POINTER = 0x8456
+ FOG_COORDINATE_ARRAY = 0x8457
+ COLOR_SUM = 0x8458
+ CURRENT_SECONDARY_COLOR = 0x8459
+ SECONDARY_COLOR_ARRAY_SIZE = 0x845A
+ SECONDARY_COLOR_ARRAY_TYPE = 0x845B
+ SECONDARY_COLOR_ARRAY_STRIDE = 0x845C
+ SECONDARY_COLOR_ARRAY_POINTER = 0x845D
+ SECONDARY_COLOR_ARRAY = 0x845E
+ TEXTURE0 = 0x84C0
+ TEXTURE1 = 0x84C1
+ TEXTURE2 = 0x84C2
+ TEXTURE3 = 0x84C3
+ TEXTURE4 = 0x84C4
+ TEXTURE5 = 0x84C5
+ TEXTURE6 = 0x84C6
+ TEXTURE7 = 0x84C7
+ TEXTURE8 = 0x84C8
+ TEXTURE9 = 0x84C9
+ TEXTURE10 = 0x84CA
+ TEXTURE11 = 0x84CB
+ TEXTURE12 = 0x84CC
+ TEXTURE13 = 0x84CD
+ TEXTURE14 = 0x84CE
+ TEXTURE15 = 0x84CF
+ TEXTURE16 = 0x84D0
+ TEXTURE17 = 0x84D1
+ TEXTURE18 = 0x84D2
+ TEXTURE19 = 0x84D3
+ TEXTURE20 = 0x84D4
+ TEXTURE21 = 0x84D5
+ TEXTURE22 = 0x84D6
+ TEXTURE23 = 0x84D7
+ TEXTURE24 = 0x84D8
+ TEXTURE25 = 0x84D9
+ TEXTURE26 = 0x84DA
+ TEXTURE27 = 0x84DB
+ TEXTURE28 = 0x84DC
+ TEXTURE29 = 0x84DD
+ TEXTURE30 = 0x84DE
+ TEXTURE31 = 0x84DF
+ ACTIVE_TEXTURE = 0x84E0
+ CLIENT_ACTIVE_TEXTURE = 0x84E1
+ MAX_TEXTURE_UNITS = 0x84E2
+ TRANSPOSE_MODELVIEW_MATRIX = 0x84E3
+ TRANSPOSE_PROJECTION_MATRIX = 0x84E4
+ TRANSPOSE_TEXTURE_MATRIX = 0x84E5
+ TRANSPOSE_COLOR_MATRIX = 0x84E6
+ SUBTRACT = 0x84E7
+ COMPRESSED_ALPHA = 0x84E9
+ COMPRESSED_LUMINANCE = 0x84EA
+ COMPRESSED_LUMINANCE_ALPHA = 0x84EB
+ COMPRESSED_INTENSITY = 0x84EC
+ COMPRESSED_RGB = 0x84ED
+ COMPRESSED_RGBA = 0x84EE
+ MAX_TEXTURE_LOD_BIAS = 0x84FD
+ TEXTURE_FILTER_CONTROL = 0x8500
+ TEXTURE_LOD_BIAS = 0x8501
+ INCR_WRAP = 0x8507
+ DECR_WRAP = 0x8508
+ NORMAL_MAP = 0x8511
+ REFLECTION_MAP = 0x8512
+ TEXTURE_CUBE_MAP = 0x8513
+ TEXTURE_BINDING_CUBE_MAP = 0x8514
+ TEXTURE_CUBE_MAP_POSITIVE_X = 0x8515
+ TEXTURE_CUBE_MAP_NEGATIVE_X = 0x8516
+ TEXTURE_CUBE_MAP_POSITIVE_Y = 0x8517
+ TEXTURE_CUBE_MAP_NEGATIVE_Y = 0x8518
+ TEXTURE_CUBE_MAP_POSITIVE_Z = 0x8519
+ TEXTURE_CUBE_MAP_NEGATIVE_Z = 0x851A
+ PROXY_TEXTURE_CUBE_MAP = 0x851B
+ MAX_CUBE_MAP_TEXTURE_SIZE = 0x851C
+ COMBINE = 0x8570
+ COMBINE_RGB = 0x8571
+ COMBINE_ALPHA = 0x8572
+ RGB_SCALE = 0x8573
+ ADD_SIGNED = 0x8574
+ INTERPOLATE = 0x8575
+ CONSTANT = 0x8576
+ PRIMARY_COLOR = 0x8577
+ PREVIOUS = 0x8578
+ SOURCE0_RGB = 0x8580
+ SOURCE1_RGB = 0x8581
+ SOURCE2_RGB = 0x8582
+ SOURCE0_ALPHA = 0x8588
+ SOURCE1_ALPHA = 0x8589
+ SOURCE2_ALPHA = 0x858A
+ OPERAND0_RGB = 0x8590
+ OPERAND1_RGB = 0x8591
+ OPERAND2_RGB = 0x8592
+ OPERAND0_ALPHA = 0x8598
+ OPERAND1_ALPHA = 0x8599
+ OPERAND2_ALPHA = 0x859A
+ TEXTURE_COMPRESSED_IMAGE_SIZE = 0x86A0
+ TEXTURE_COMPRESSED = 0x86A1
+ NUM_COMPRESSED_TEXTURE_FORMATS = 0x86A2
+ COMPRESSED_TEXTURE_FORMATS = 0x86A3
+ DOT3_RGB = 0x86AE
+ DOT3_RGBA = 0x86AF
+ TEXTURE_DEPTH_SIZE = 0x884A
+ DEPTH_TEXTURE_MODE = 0x884B
+ TEXTURE_COMPARE_MODE = 0x884C
+ TEXTURE_COMPARE_FUNC = 0x884D
+ COMPARE_R_TO_TEXTURE = 0x884E
+)
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glViewport.xml
+func (gl *GL) Viewport(x, y, width, height int) {
+ C.gl1_4_glViewport(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// DepthRange specifies the mapping of depth values from normalized device
+// coordinates to window coordinates.
+//
+// Parameter nearVal specifies the mapping of the near clipping plane to window
+// coordinates (defaults to 0), while farVal specifies the mapping of the far
+// clipping plane to window coordinates (defaults to 1).
+//
+// After clipping and division by w, depth coordinates range from -1 to 1,
+// corresponding to the near and far clipping planes. DepthRange specifies a
+// linear mapping of the normalized depth coordinates in this range to window
+// depth coordinates. Regardless of the actual depth buffer implementation,
+// window coordinate depth values are treated as though they range from 0 through 1
+// (like color components). Thus, the values accepted by DepthRange are both
+// clamped to this range before they are accepted.
+//
+// The default setting of (0, 1) maps the near plane to 0 and the far plane to 1.
+// With this mapping, the depth buffer range is fully utilized.
+//
+// It is not necessary that nearVal be less than farVal. Reverse mappings such as
+// nearVal 1, and farVal 0 are acceptable.
+//
+// GL.INVALID_OPERATION is generated if DepthRange is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) DepthRange(nearVal, farVal float64) {
+ C.gl1_4_glDepthRange(gl.funcs, C.GLdouble(nearVal), C.GLdouble(farVal))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIsEnabled.xml
+func (gl *GL) IsEnabled(cap glbase.Enum) bool {
+ glresult := C.gl1_4_glIsEnabled(gl.funcs, C.GLenum(cap))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexLevelParameteriv.xml
+func (gl *GL) GetTexLevelParameteriv(target glbase.Enum, level int, pname glbase.Enum, params []int32) {
+ C.gl1_4_glGetTexLevelParameteriv(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexLevelParameterfv.xml
+func (gl *GL) GetTexLevelParameterfv(target glbase.Enum, level int, pname glbase.Enum, params []float32) {
+ C.gl1_4_glGetTexLevelParameterfv(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexParameteriv.xml
+func (gl *GL) GetTexParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl1_4_glGetTexParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexParameterfv.xml
+func (gl *GL) GetTexParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl1_4_glGetTexParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexImage.xml
+func (gl *GL) GetTexImage(target glbase.Enum, level int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_4_glGetTexImage(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetIntegerv.xml
+func (gl *GL) GetIntegerv(pname glbase.Enum, params []int32) {
+ C.gl1_4_glGetIntegerv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetFloatv.xml
+func (gl *GL) GetFloatv(pname glbase.Enum, params []float32) {
+ C.gl1_4_glGetFloatv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetError.xml
+func (gl *GL) GetError() glbase.Enum {
+ glresult := C.gl1_4_glGetError(gl.funcs)
+ return glbase.Enum(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetDoublev.xml
+func (gl *GL) GetDoublev(pname glbase.Enum, params []float64) {
+ C.gl1_4_glGetDoublev(gl.funcs, C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetBooleanv.xml
+func (gl *GL) GetBooleanv(pname glbase.Enum, params []bool) {
+ C.gl1_4_glGetBooleanv(gl.funcs, C.GLenum(pname), (*C.GLboolean)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glReadPixels.xml
+func (gl *GL) ReadPixels(x, y, width, height int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_4_glReadPixels(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glReadBuffer.xml
+func (gl *GL) ReadBuffer(mode glbase.Enum) {
+ C.gl1_4_glReadBuffer(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelStorei.xml
+func (gl *GL) PixelStorei(pname glbase.Enum, param int32) {
+ C.gl1_4_glPixelStorei(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelStoref.xml
+func (gl *GL) PixelStoref(pname glbase.Enum, param float32) {
+ C.gl1_4_glPixelStoref(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDepthFunc.xml
+func (gl *GL) DepthFunc(glfunc glbase.Enum) {
+ C.gl1_4_glDepthFunc(gl.funcs, C.GLenum(glfunc))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glStencilOp.xml
+func (gl *GL) StencilOp(fail, zfail, zpass glbase.Enum) {
+ C.gl1_4_glStencilOp(gl.funcs, C.GLenum(fail), C.GLenum(zfail), C.GLenum(zpass))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glStencilFunc.xml
+func (gl *GL) StencilFunc(glfunc glbase.Enum, ref int32, mask uint32) {
+ C.gl1_4_glStencilFunc(gl.funcs, C.GLenum(glfunc), C.GLint(ref), C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLogicOp.xml
+func (gl *GL) LogicOp(opcode glbase.Enum) {
+ C.gl1_4_glLogicOp(gl.funcs, C.GLenum(opcode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBlendFunc.xml
+func (gl *GL) BlendFunc(sfactor, dfactor glbase.Enum) {
+ C.gl1_4_glBlendFunc(gl.funcs, C.GLenum(sfactor), C.GLenum(dfactor))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFlush.xml
+func (gl *GL) Flush() {
+ C.gl1_4_glFlush(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFinish.xml
+func (gl *GL) Finish() {
+ C.gl1_4_glFinish(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEnable.xml
+func (gl *GL) Enable(cap glbase.Enum) {
+ C.gl1_4_glEnable(gl.funcs, C.GLenum(cap))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDisable.xml
+func (gl *GL) Disable(cap glbase.Enum) {
+ C.gl1_4_glDisable(gl.funcs, C.GLenum(cap))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDepthMask.xml
+func (gl *GL) DepthMask(flag bool) {
+ C.gl1_4_glDepthMask(gl.funcs, *(*C.GLboolean)(unsafe.Pointer(&flag)))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColorMask.xml
+func (gl *GL) ColorMask(red, green, blue, alpha bool) {
+ C.gl1_4_glColorMask(gl.funcs, *(*C.GLboolean)(unsafe.Pointer(&red)), *(*C.GLboolean)(unsafe.Pointer(&green)), *(*C.GLboolean)(unsafe.Pointer(&blue)), *(*C.GLboolean)(unsafe.Pointer(&alpha)))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glStencilMask.xml
+func (gl *GL) StencilMask(mask uint32) {
+ C.gl1_4_glStencilMask(gl.funcs, C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClearDepth.xml
+func (gl *GL) ClearDepth(depth float64) {
+ C.gl1_4_glClearDepth(gl.funcs, C.GLdouble(depth))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClearStencil.xml
+func (gl *GL) ClearStencil(s int32) {
+ C.gl1_4_glClearStencil(gl.funcs, C.GLint(s))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClearColor.xml
+func (gl *GL) ClearColor(red, green, blue, alpha float32) {
+ C.gl1_4_glClearColor(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClear.xml
+func (gl *GL) Clear(mask glbase.Bitfield) {
+ C.gl1_4_glClear(gl.funcs, C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDrawBuffer.xml
+func (gl *GL) DrawBuffer(mode glbase.Enum) {
+ C.gl1_4_glDrawBuffer(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexImage2D.xml
+func (gl *GL) TexImage2D(target glbase.Enum, level int, internalFormat int32, width, height, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_4_glTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexImage1D.xml
+func (gl *GL) TexImage1D(target glbase.Enum, level int, internalFormat int32, width, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_4_glTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexParameteriv.xml
+func (gl *GL) TexParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl1_4_glTexParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexParameteri.xml
+func (gl *GL) TexParameteri(target, pname glbase.Enum, param int32) {
+ C.gl1_4_glTexParameteri(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexParameterfv.xml
+func (gl *GL) TexParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl1_4_glTexParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexParameterf.xml
+func (gl *GL) TexParameterf(target, pname glbase.Enum, param float32) {
+ C.gl1_4_glTexParameterf(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glScissor.xml
+func (gl *GL) Scissor(x, y, width, height int) {
+ C.gl1_4_glScissor(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPolygonMode.xml
+func (gl *GL) PolygonMode(face, mode glbase.Enum) {
+ C.gl1_4_glPolygonMode(gl.funcs, C.GLenum(face), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPointSize.xml
+func (gl *GL) PointSize(size float32) {
+ C.gl1_4_glPointSize(gl.funcs, C.GLfloat(size))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLineWidth.xml
+func (gl *GL) LineWidth(width float32) {
+ C.gl1_4_glLineWidth(gl.funcs, C.GLfloat(width))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glHint.xml
+func (gl *GL) Hint(target, mode glbase.Enum) {
+ C.gl1_4_glHint(gl.funcs, C.GLenum(target), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFrontFace.xml
+func (gl *GL) FrontFace(mode glbase.Enum) {
+ C.gl1_4_glFrontFace(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCullFace.xml
+func (gl *GL) CullFace(mode glbase.Enum) {
+ C.gl1_4_glCullFace(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexubv.xml
+func (gl *GL) Indexubv(c []uint8) {
+ C.gl1_4_glIndexubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexub.xml
+func (gl *GL) Indexub(c uint8) {
+ C.gl1_4_glIndexub(gl.funcs, C.GLubyte(c))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIsTexture.xml
+func (gl *GL) IsTexture(texture glbase.Texture) bool {
+ glresult := C.gl1_4_glIsTexture(gl.funcs, C.GLuint(texture))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// GenTextures returns n texture names in textures. There is no guarantee
+// that the names form a contiguous set of integers; however, it is
+// guaranteed that none of the returned names was in use immediately before
+// the call to GenTextures.
+//
+// The generated textures have no dimensionality; they assume the
+// dimensionality of the texture target to which they are first bound (see
+// BindTexture).
+//
+// Texture names returned by a call to GenTextures are not returned by
+// subsequent calls, unless they are first deleted with DeleteTextures.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// GenTextures is available in GL version 2.0 or greater.
+func (gl *GL) GenTextures(n int) []glbase.Texture {
+ if n == 0 {
+ return nil
+ }
+ textures := make([]glbase.Texture, n)
+ C.gl1_4_glGenTextures(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])))
+ return textures
+}
+
+// DeleteTextures deletes the textures objects whose names are stored
+// in the textures slice. After a texture is deleted, it has no contents or
+// dimensionality, and its name is free for reuse (for example by
+// GenTextures). If a texture that is currently bound is deleted, the binding
+// reverts to 0 (the default texture).
+//
+// DeleteTextures silently ignores 0's and names that do not correspond to
+// existing textures.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// DeleteTextures is available in GL version 2.0 or greater.
+func (gl *GL) DeleteTextures(textures []glbase.Texture) {
+ n := len(textures)
+ if n == 0 {
+ return
+ }
+ C.gl1_4_glDeleteTextures(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBindTexture.xml
+func (gl *GL) BindTexture(target glbase.Enum, texture glbase.Texture) {
+ C.gl1_4_glBindTexture(gl.funcs, C.GLenum(target), C.GLuint(texture))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexSubImage2D.xml
+func (gl *GL) TexSubImage2D(target glbase.Enum, level, xoffset, yoffset, width, height int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_4_glTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexSubImage1D.xml
+func (gl *GL) TexSubImage1D(target glbase.Enum, level, xoffset, width int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_4_glTexSubImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLsizei(width), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyTexSubImage2D.xml
+func (gl *GL) CopyTexSubImage2D(target glbase.Enum, level, xoffset, yoffset, x, y, width, height int) {
+ C.gl1_4_glCopyTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyTexSubImage1D.xml
+func (gl *GL) CopyTexSubImage1D(target glbase.Enum, level, xoffset, x, y, width int) {
+ C.gl1_4_glCopyTexSubImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(x), C.GLint(y), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyTexImage2D.xml
+func (gl *GL) CopyTexImage2D(target glbase.Enum, level int, internalFormat glbase.Enum, x, y, width, height, border int) {
+ C.gl1_4_glCopyTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height), C.GLint(border))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyTexImage1D.xml
+func (gl *GL) CopyTexImage1D(target glbase.Enum, level int, internalFormat glbase.Enum, x, y, width, border int) {
+ C.gl1_4_glCopyTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLint(border))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPolygonOffset.xml
+func (gl *GL) PolygonOffset(factor, units float32) {
+ C.gl1_4_glPolygonOffset(gl.funcs, C.GLfloat(factor), C.GLfloat(units))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDrawElements.xml
+func (gl *GL) DrawElements(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_4_glDrawElements(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDrawArrays.xml
+func (gl *GL) DrawArrays(mode glbase.Enum, first, count int) {
+ C.gl1_4_glDrawArrays(gl.funcs, C.GLenum(mode), C.GLint(first), C.GLsizei(count))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyTexSubImage3D.xml
+func (gl *GL) CopyTexSubImage3D(target glbase.Enum, level, xoffset, yoffset int, zoffset int32, x, y, width, height int) {
+ C.gl1_4_glCopyTexSubImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(zoffset), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexSubImage3D.xml
+func (gl *GL) TexSubImage3D(target glbase.Enum, level, xoffset, yoffset int, zoffset int32, width, height int, depth int32, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_4_glTexSubImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(zoffset), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexImage3D.xml
+func (gl *GL) TexImage3D(target glbase.Enum, level int, internalFormat int32, width, height int, depth int32, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_4_glTexImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDrawRangeElements.xml
+func (gl *GL) DrawRangeElements(mode glbase.Enum, start, end uint32, count int, gltype glbase.Enum, indices interface{}) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_4_glDrawRangeElements(gl.funcs, C.GLenum(mode), C.GLuint(start), C.GLuint(end), C.GLsizei(count), C.GLenum(gltype), indices_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBlendEquation.xml
+func (gl *GL) BlendEquation(mode glbase.Enum) {
+ C.gl1_4_glBlendEquation(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBlendColor.xml
+func (gl *GL) BlendColor(red, green, blue, alpha float32) {
+ C.gl1_4_glBlendColor(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetCompressedTexImage.xml
+func (gl *GL) GetCompressedTexImage(target glbase.Enum, level int, img interface{}) {
+ var img_ptr unsafe.Pointer
+ var img_v = reflect.ValueOf(img)
+ if img != nil && img_v.Kind() != reflect.Slice {
+ panic("parameter img must be a slice")
+ }
+ if img != nil {
+ img_ptr = unsafe.Pointer(img_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_4_glGetCompressedTexImage(gl.funcs, C.GLenum(target), C.GLint(level), img_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCompressedTexSubImage1D.xml
+func (gl *GL) CompressedTexSubImage1D(target glbase.Enum, level, xoffset, width int, format glbase.Enum, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_4_glCompressedTexSubImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLsizei(width), C.GLenum(format), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCompressedTexSubImage2D.xml
+func (gl *GL) CompressedTexSubImage2D(target glbase.Enum, level, xoffset, yoffset, width, height int, format glbase.Enum, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_4_glCompressedTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCompressedTexSubImage3D.xml
+func (gl *GL) CompressedTexSubImage3D(target glbase.Enum, level, xoffset, yoffset int, zoffset int32, width, height int, depth int32, format glbase.Enum, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_4_glCompressedTexSubImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(zoffset), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLenum(format), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCompressedTexImage1D.xml
+func (gl *GL) CompressedTexImage1D(target glbase.Enum, level int, internalFormat glbase.Enum, width, border, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_4_glCompressedTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLsizei(width), C.GLint(border), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCompressedTexImage2D.xml
+func (gl *GL) CompressedTexImage2D(target glbase.Enum, level int, internalFormat glbase.Enum, width, height, border, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_4_glCompressedTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLint(border), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCompressedTexImage3D.xml
+func (gl *GL) CompressedTexImage3D(target glbase.Enum, level int, internalFormat glbase.Enum, width, height int, depth int32, border, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_4_glCompressedTexImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLint(border), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSampleCoverage.xml
+func (gl *GL) SampleCoverage(value float32, invert bool) {
+ C.gl1_4_glSampleCoverage(gl.funcs, C.GLfloat(value), *(*C.GLboolean)(unsafe.Pointer(&invert)))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glActiveTexture.xml
+func (gl *GL) ActiveTexture(texture glbase.Enum) {
+ C.gl1_4_glActiveTexture(gl.funcs, C.GLenum(texture))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPointParameteriv.xml
+func (gl *GL) PointParameteriv(pname glbase.Enum, params []int32) {
+ C.gl1_4_glPointParameteriv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPointParameteri.xml
+func (gl *GL) PointParameteri(pname glbase.Enum, param int32) {
+ C.gl1_4_glPointParameteri(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPointParameterfv.xml
+func (gl *GL) PointParameterfv(pname glbase.Enum, params []float32) {
+ C.gl1_4_glPointParameterfv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPointParameterf.xml
+func (gl *GL) PointParameterf(pname glbase.Enum, param float32) {
+ C.gl1_4_glPointParameterf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiDrawArrays.xml
+func (gl *GL) MultiDrawArrays(mode glbase.Enum, first, count []int, drawcount int32) {
+ C.gl1_4_glMultiDrawArrays(gl.funcs, C.GLenum(mode), (*C.GLint)(unsafe.Pointer(&first[0])), (*C.GLsizei)(unsafe.Pointer(&count[0])), C.GLsizei(drawcount))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBlendFuncSeparate.xml
+func (gl *GL) BlendFuncSeparate(sfactorRGB, dfactorRGB, sfactorAlpha, dfactorAlpha glbase.Enum) {
+ C.gl1_4_glBlendFuncSeparate(gl.funcs, C.GLenum(sfactorRGB), C.GLenum(dfactorRGB), C.GLenum(sfactorAlpha), C.GLenum(dfactorAlpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTranslatef.xml
+func (gl *GL) Translatef(x, y, z float32) {
+ C.gl1_4_glTranslatef(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTranslated.xml
+func (gl *GL) Translated(x, y, z float64) {
+ C.gl1_4_glTranslated(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glScalef.xml
+func (gl *GL) Scalef(x, y, z float32) {
+ C.gl1_4_glScalef(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glScaled.xml
+func (gl *GL) Scaled(x, y, z float64) {
+ C.gl1_4_glScaled(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRotatef.xml
+func (gl *GL) Rotatef(angle, x, y, z float32) {
+ C.gl1_4_glRotatef(gl.funcs, C.GLfloat(angle), C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRotated.xml
+func (gl *GL) Rotated(angle, x, y, z float64) {
+ C.gl1_4_glRotated(gl.funcs, C.GLdouble(angle), C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPushMatrix.xml
+func (gl *GL) PushMatrix() {
+ C.gl1_4_glPushMatrix(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPopMatrix.xml
+func (gl *GL) PopMatrix() {
+ C.gl1_4_glPopMatrix(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glOrtho.xml
+func (gl *GL) Ortho(left, right, bottom, top, zNear, zFar float64) {
+ C.gl1_4_glOrtho(gl.funcs, C.GLdouble(left), C.GLdouble(right), C.GLdouble(bottom), C.GLdouble(top), C.GLdouble(zNear), C.GLdouble(zFar))
+}
+
+// MultMatrixd multiplies the current matrix with the provided matrix.
+//
+// The m parameter must hold 16 consecutive elements of a 4x4 column-major matrix.
+//
+// The current matrix is determined by the current matrix mode (see
+// MatrixMode). It is either the projection matrix, modelview matrix, or the
+// texture matrix.
+//
+// For example, if the current matrix is C and the coordinates to be transformed
+// are v = (v[0], v[1], v[2], v[3]), then the current transformation is C × v, or
+//
+// c[0] c[4] c[8] c[12] v[0]
+// c[1] c[5] c[9] c[13] v[1]
+// c[2] c[6] c[10] c[14] X v[2]
+// c[3] c[7] c[11] c[15] v[3]
+//
+// Calling MultMatrix with an argument of m = m[0], m[1], ..., m[15]
+// replaces the current transformation with (C X M) x v, or
+//
+// c[0] c[4] c[8] c[12] m[0] m[4] m[8] m[12] v[0]
+// c[1] c[5] c[9] c[13] m[1] m[5] m[9] m[13] v[1]
+// c[2] c[6] c[10] c[14] X m[2] m[6] m[10] m[14] X v[2]
+// c[3] c[7] c[11] c[15] m[3] m[7] m[11] m[15] v[3]
+//
+// Where 'X' denotes matrix multiplication, and v is represented as a 4x1 matrix.
+//
+// While the elements of the matrix may be specified with single or double
+// precision, the GL may store or operate on these values in less-than-single
+// precision.
+//
+// In many computer languages, 4×4 arrays are represented in row-major
+// order. The transformations just described represent these matrices in
+// column-major order. The order of the multiplication is important. For
+// example, if the current transformation is a rotation, and MultMatrix is
+// called with a translation matrix, the translation is done directly on the
+// coordinates to be transformed, while the rotation is done on the results
+// of that translation.
+//
+// GL.INVALID_OPERATION is generated if MultMatrix is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) MultMatrixd(m []float64) {
+ if len(m) != 16 {
+ panic("parameter m must have length 16 for the 4x4 matrix")
+ }
+ C.gl1_4_glMultMatrixd(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&m[0])))
+}
+
+// MultMatrixf multiplies the current matrix with the provided matrix.
+//
+// The m parameter must hold 16 consecutive elements of a 4x4 column-major matrix.
+//
+// The current matrix is determined by the current matrix mode (see
+// MatrixMode). It is either the projection matrix, modelview matrix, or the
+// texture matrix.
+//
+// For example, if the current matrix is C and the coordinates to be transformed
+// are v = (v[0], v[1], v[2], v[3]), then the current transformation is C × v, or
+//
+// c[0] c[4] c[8] c[12] v[0]
+// c[1] c[5] c[9] c[13] v[1]
+// c[2] c[6] c[10] c[14] X v[2]
+// c[3] c[7] c[11] c[15] v[3]
+//
+// Calling MultMatrix with an argument of m = m[0], m[1], ..., m[15]
+// replaces the current transformation with (C X M) x v, or
+//
+// c[0] c[4] c[8] c[12] m[0] m[4] m[8] m[12] v[0]
+// c[1] c[5] c[9] c[13] m[1] m[5] m[9] m[13] v[1]
+// c[2] c[6] c[10] c[14] X m[2] m[6] m[10] m[14] X v[2]
+// c[3] c[7] c[11] c[15] m[3] m[7] m[11] m[15] v[3]
+//
+// Where 'X' denotes matrix multiplication, and v is represented as a 4x1 matrix.
+//
+// While the elements of the matrix may be specified with single or double
+// precision, the GL may store or operate on these values in less-than-single
+// precision.
+//
+// In many computer languages, 4×4 arrays are represented in row-major
+// order. The transformations just described represent these matrices in
+// column-major order. The order of the multiplication is important. For
+// example, if the current transformation is a rotation, and MultMatrix is
+// called with a translation matrix, the translation is done directly on the
+// coordinates to be transformed, while the rotation is done on the results
+// of that translation.
+//
+// GL.INVALID_OPERATION is generated if MultMatrix is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) MultMatrixf(m []float32) {
+ if len(m) != 16 {
+ panic("parameter m must have length 16 for the 4x4 matrix")
+ }
+ C.gl1_4_glMultMatrixf(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMatrixMode.xml
+func (gl *GL) MatrixMode(mode glbase.Enum) {
+ C.gl1_4_glMatrixMode(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLoadMatrixd.xml
+func (gl *GL) LoadMatrixd(m []float64) {
+ C.gl1_4_glLoadMatrixd(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLoadMatrixf.xml
+func (gl *GL) LoadMatrixf(m []float32) {
+ C.gl1_4_glLoadMatrixf(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLoadIdentity.xml
+func (gl *GL) LoadIdentity() {
+ C.gl1_4_glLoadIdentity(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFrustum.xml
+func (gl *GL) Frustum(left, right, bottom, top, zNear, zFar float64) {
+ C.gl1_4_glFrustum(gl.funcs, C.GLdouble(left), C.GLdouble(right), C.GLdouble(bottom), C.GLdouble(top), C.GLdouble(zNear), C.GLdouble(zFar))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIsList.xml
+func (gl *GL) IsList(list uint32) bool {
+ glresult := C.gl1_4_glIsList(gl.funcs, C.GLuint(list))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexGeniv.xml
+func (gl *GL) GetTexGeniv(coord, pname glbase.Enum, params []int32) {
+ C.gl1_4_glGetTexGeniv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexGenfv.xml
+func (gl *GL) GetTexGenfv(coord, pname glbase.Enum, params []float32) {
+ C.gl1_4_glGetTexGenfv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexGendv.xml
+func (gl *GL) GetTexGendv(coord, pname glbase.Enum, params []float64) {
+ C.gl1_4_glGetTexGendv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexEnviv.xml
+func (gl *GL) GetTexEnviv(target, pname glbase.Enum, params []int32) {
+ C.gl1_4_glGetTexEnviv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexEnvfv.xml
+func (gl *GL) GetTexEnvfv(target, pname glbase.Enum, params []float32) {
+ C.gl1_4_glGetTexEnvfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetPolygonStipple.xml
+func (gl *GL) GetPolygonStipple(mask []uint8) {
+ C.gl1_4_glGetPolygonStipple(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&mask[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetPixelMapusv.xml
+func (gl *GL) GetPixelMapusv(glmap glbase.Enum, values []uint16) {
+ C.gl1_4_glGetPixelMapusv(gl.funcs, C.GLenum(glmap), (*C.GLushort)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetPixelMapuiv.xml
+func (gl *GL) GetPixelMapuiv(glmap glbase.Enum, values []uint32) {
+ C.gl1_4_glGetPixelMapuiv(gl.funcs, C.GLenum(glmap), (*C.GLuint)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetPixelMapfv.xml
+func (gl *GL) GetPixelMapfv(glmap glbase.Enum, values []float32) {
+ C.gl1_4_glGetPixelMapfv(gl.funcs, C.GLenum(glmap), (*C.GLfloat)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetMaterialiv.xml
+func (gl *GL) GetMaterialiv(face, pname glbase.Enum, params []int32) {
+ C.gl1_4_glGetMaterialiv(gl.funcs, C.GLenum(face), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetMaterialfv.xml
+func (gl *GL) GetMaterialfv(face, pname glbase.Enum, params []float32) {
+ C.gl1_4_glGetMaterialfv(gl.funcs, C.GLenum(face), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetMapiv.xml
+func (gl *GL) GetMapiv(target, query glbase.Enum, v []int32) {
+ C.gl1_4_glGetMapiv(gl.funcs, C.GLenum(target), C.GLenum(query), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetMapfv.xml
+func (gl *GL) GetMapfv(target, query glbase.Enum, v []float32) {
+ C.gl1_4_glGetMapfv(gl.funcs, C.GLenum(target), C.GLenum(query), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetMapdv.xml
+func (gl *GL) GetMapdv(target, query glbase.Enum, v []float64) {
+ C.gl1_4_glGetMapdv(gl.funcs, C.GLenum(target), C.GLenum(query), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetLightiv.xml
+func (gl *GL) GetLightiv(light, pname glbase.Enum, params []int32) {
+ C.gl1_4_glGetLightiv(gl.funcs, C.GLenum(light), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetLightfv.xml
+func (gl *GL) GetLightfv(light, pname glbase.Enum, params []float32) {
+ C.gl1_4_glGetLightfv(gl.funcs, C.GLenum(light), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetClipPlane.xml
+func (gl *GL) GetClipPlane(plane glbase.Enum, equation []float64) {
+ C.gl1_4_glGetClipPlane(gl.funcs, C.GLenum(plane), (*C.GLdouble)(unsafe.Pointer(&equation[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDrawPixels.xml
+func (gl *GL) DrawPixels(width, height int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_4_glDrawPixels(gl.funcs, C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyPixels.xml
+func (gl *GL) CopyPixels(x, y, width, height int, gltype glbase.Enum) {
+ C.gl1_4_glCopyPixels(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height), C.GLenum(gltype))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelMapusv.xml
+func (gl *GL) PixelMapusv(glmap glbase.Enum, mapsize int32, values []uint16) {
+ C.gl1_4_glPixelMapusv(gl.funcs, C.GLenum(glmap), C.GLint(mapsize), (*C.GLushort)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelMapuiv.xml
+func (gl *GL) PixelMapuiv(glmap glbase.Enum, mapsize int32, values []uint32) {
+ C.gl1_4_glPixelMapuiv(gl.funcs, C.GLenum(glmap), C.GLint(mapsize), (*C.GLuint)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelMapfv.xml
+func (gl *GL) PixelMapfv(glmap glbase.Enum, mapsize int32, values []float32) {
+ C.gl1_4_glPixelMapfv(gl.funcs, C.GLenum(glmap), C.GLint(mapsize), (*C.GLfloat)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelTransferi.xml
+func (gl *GL) PixelTransferi(pname glbase.Enum, param int32) {
+ C.gl1_4_glPixelTransferi(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelTransferf.xml
+func (gl *GL) PixelTransferf(pname glbase.Enum, param float32) {
+ C.gl1_4_glPixelTransferf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelZoom.xml
+func (gl *GL) PixelZoom(xfactor, yfactor float32) {
+ C.gl1_4_glPixelZoom(gl.funcs, C.GLfloat(xfactor), C.GLfloat(yfactor))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glAlphaFunc.xml
+func (gl *GL) AlphaFunc(glfunc glbase.Enum, ref float32) {
+ C.gl1_4_glAlphaFunc(gl.funcs, C.GLenum(glfunc), C.GLfloat(ref))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalPoint2.xml
+func (gl *GL) EvalPoint2(i, j int32) {
+ C.gl1_4_glEvalPoint2(gl.funcs, C.GLint(i), C.GLint(j))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalMesh2.xml
+func (gl *GL) EvalMesh2(mode glbase.Enum, i1, i2, j1, j2 int32) {
+ C.gl1_4_glEvalMesh2(gl.funcs, C.GLenum(mode), C.GLint(i1), C.GLint(i2), C.GLint(j1), C.GLint(j2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalPoint1.xml
+func (gl *GL) EvalPoint1(i int32) {
+ C.gl1_4_glEvalPoint1(gl.funcs, C.GLint(i))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalMesh1.xml
+func (gl *GL) EvalMesh1(mode glbase.Enum, i1, i2 int32) {
+ C.gl1_4_glEvalMesh1(gl.funcs, C.GLenum(mode), C.GLint(i1), C.GLint(i2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord2fv.xml
+func (gl *GL) EvalCoord2fv(u []float32) {
+ if len(u) != 2 {
+ panic("parameter u has incorrect length")
+ }
+ C.gl1_4_glEvalCoord2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&u[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord2f.xml
+func (gl *GL) EvalCoord2f(u, v float32) {
+ C.gl1_4_glEvalCoord2f(gl.funcs, C.GLfloat(u), C.GLfloat(v))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord2dv.xml
+func (gl *GL) EvalCoord2dv(u []float64) {
+ if len(u) != 2 {
+ panic("parameter u has incorrect length")
+ }
+ C.gl1_4_glEvalCoord2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&u[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord2d.xml
+func (gl *GL) EvalCoord2d(u, v float64) {
+ C.gl1_4_glEvalCoord2d(gl.funcs, C.GLdouble(u), C.GLdouble(v))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord1fv.xml
+func (gl *GL) EvalCoord1fv(u []float32) {
+ C.gl1_4_glEvalCoord1fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&u[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord1f.xml
+func (gl *GL) EvalCoord1f(u float32) {
+ C.gl1_4_glEvalCoord1f(gl.funcs, C.GLfloat(u))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord1dv.xml
+func (gl *GL) EvalCoord1dv(u []float64) {
+ C.gl1_4_glEvalCoord1dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&u[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord1d.xml
+func (gl *GL) EvalCoord1d(u float64) {
+ C.gl1_4_glEvalCoord1d(gl.funcs, C.GLdouble(u))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMapGrid2f.xml
+func (gl *GL) MapGrid2f(un int32, u1, u2 float32, vn int32, v1, v2 float32) {
+ C.gl1_4_glMapGrid2f(gl.funcs, C.GLint(un), C.GLfloat(u1), C.GLfloat(u2), C.GLint(vn), C.GLfloat(v1), C.GLfloat(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMapGrid2d.xml
+func (gl *GL) MapGrid2d(un int32, u1, u2 float64, vn int32, v1, v2 float64) {
+ C.gl1_4_glMapGrid2d(gl.funcs, C.GLint(un), C.GLdouble(u1), C.GLdouble(u2), C.GLint(vn), C.GLdouble(v1), C.GLdouble(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMapGrid1f.xml
+func (gl *GL) MapGrid1f(un int32, u1, u2 float32) {
+ C.gl1_4_glMapGrid1f(gl.funcs, C.GLint(un), C.GLfloat(u1), C.GLfloat(u2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMapGrid1d.xml
+func (gl *GL) MapGrid1d(un int32, u1, u2 float64) {
+ C.gl1_4_glMapGrid1d(gl.funcs, C.GLint(un), C.GLdouble(u1), C.GLdouble(u2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMap2f.xml
+func (gl *GL) Map2f(target glbase.Enum, u1, u2 float32, ustride, uorder int32, v1, v2 float32, vstride, vorder int32, points []float32) {
+ C.gl1_4_glMap2f(gl.funcs, C.GLenum(target), C.GLfloat(u1), C.GLfloat(u2), C.GLint(ustride), C.GLint(uorder), C.GLfloat(v1), C.GLfloat(v2), C.GLint(vstride), C.GLint(vorder), (*C.GLfloat)(unsafe.Pointer(&points[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMap2d.xml
+func (gl *GL) Map2d(target glbase.Enum, u1, u2 float64, ustride, uorder int32, v1, v2 float64, vstride, vorder int32, points []float64) {
+ C.gl1_4_glMap2d(gl.funcs, C.GLenum(target), C.GLdouble(u1), C.GLdouble(u2), C.GLint(ustride), C.GLint(uorder), C.GLdouble(v1), C.GLdouble(v2), C.GLint(vstride), C.GLint(vorder), (*C.GLdouble)(unsafe.Pointer(&points[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMap1f.xml
+func (gl *GL) Map1f(target glbase.Enum, u1, u2 float32, stride, order int, points []float32) {
+ C.gl1_4_glMap1f(gl.funcs, C.GLenum(target), C.GLfloat(u1), C.GLfloat(u2), C.GLint(stride), C.GLint(order), (*C.GLfloat)(unsafe.Pointer(&points[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMap1d.xml
+func (gl *GL) Map1d(target glbase.Enum, u1, u2 float64, stride, order int, points []float64) {
+ C.gl1_4_glMap1d(gl.funcs, C.GLenum(target), C.GLdouble(u1), C.GLdouble(u2), C.GLint(stride), C.GLint(order), (*C.GLdouble)(unsafe.Pointer(&points[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPushAttrib.xml
+func (gl *GL) PushAttrib(mask glbase.Bitfield) {
+ C.gl1_4_glPushAttrib(gl.funcs, C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPopAttrib.xml
+func (gl *GL) PopAttrib() {
+ C.gl1_4_glPopAttrib(gl.funcs)
+}
+
+// Accum executes an operation on the accumulation buffer.
+//
+// Parameter op defines the accumulation buffer operation (GL.ACCUM, GL.LOAD,
+// GL.ADD, GL.MULT, or GL.RETURN) and specifies how the value parameter is
+// used.
+//
+// The accumulation buffer is an extended-range color buffer. Images are not
+// rendered into it. Rather, images rendered into one of the color buffers
+// are added to the contents of the accumulation buffer after rendering.
+// Effects such as antialiasing (of points, lines, and polygons), motion
+// blur, and depth of field can be created by accumulating images generated
+// with different transformation matrices.
+//
+// Each pixel in the accumulation buffer consists of red, green, blue, and
+// alpha values. The number of bits per component in the accumulation buffer
+// depends on the implementation. You can examine this number by calling
+// GetIntegerv four times, with arguments GL.ACCUM_RED_BITS,
+// GL.ACCUM_GREEN_BITS, GL.ACCUM_BLUE_BITS, and GL.ACCUM_ALPHA_BITS.
+// Regardless of the number of bits per component, the range of values stored
+// by each component is (-1, 1). The accumulation buffer pixels are mapped
+// one-to-one with frame buffer pixels.
+//
+// All accumulation buffer operations are limited to the area of the current
+// scissor box and applied identically to the red, green, blue, and alpha
+// components of each pixel. If a Accum operation results in a value outside
+// the range (-1, 1), the contents of an accumulation buffer pixel component
+// are undefined.
+//
+// The operations are as follows:
+//
+// GL.ACCUM
+// Obtains R, G, B, and A values from the buffer currently selected for
+// reading (see ReadBuffer). Each component value is divided by 2 n -
+// 1 , where n is the number of bits allocated to each color component
+// in the currently selected buffer. The result is a floating-point
+// value in the range 0 1 , which is multiplied by value and added to
+// the corresponding pixel component in the accumulation buffer,
+// thereby updating the accumulation buffer.
+//
+// GL.LOAD
+// Similar to GL.ACCUM, except that the current value in the
+// accumulation buffer is not used in the calculation of the new value.
+// That is, the R, G, B, and A values from the currently selected
+// buffer are divided by 2 n - 1 , multiplied by value, and then stored
+// in the corresponding accumulation buffer cell, overwriting the
+// current value.
+//
+// GL.ADD
+// Adds value to each R, G, B, and A in the accumulation buffer.
+//
+// GL.MULT
+// Multiplies each R, G, B, and A in the accumulation buffer by value
+// and returns the scaled component to its corresponding accumulation
+// buffer location.
+//
+// GL.RETURN
+// Transfers accumulation buffer values to the color buffer or buffers
+// currently selected for writing. Each R, G, B, and A component is
+// multiplied by value, then multiplied by 2 n - 1 , clamped to the
+// range 0 2 n - 1 , and stored in the corresponding display buffer
+// cell. The only fragment operations that are applied to this transfer
+// are pixel ownership, scissor, dithering, and color writemasks.
+//
+// To clear the accumulation buffer, call ClearAccum with R, G, B, and A
+// values to set it to, then call Clear with the accumulation buffer
+// enabled.
+//
+// Error GL.INVALID_ENUM is generated if op is not an accepted value.
+// GL.INVALID_OPERATION is generated if there is no accumulation buffer.
+// GL.INVALID_OPERATION is generated if Accum is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) Accum(op glbase.Enum, value float32) {
+ C.gl1_4_glAccum(gl.funcs, C.GLenum(op), C.GLfloat(value))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexMask.xml
+func (gl *GL) IndexMask(mask uint32) {
+ C.gl1_4_glIndexMask(gl.funcs, C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClearIndex.xml
+func (gl *GL) ClearIndex(c float32) {
+ C.gl1_4_glClearIndex(gl.funcs, C.GLfloat(c))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClearAccum.xml
+func (gl *GL) ClearAccum(red, green, blue, alpha float32) {
+ C.gl1_4_glClearAccum(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPushName.xml
+func (gl *GL) PushName(name uint32) {
+ C.gl1_4_glPushName(gl.funcs, C.GLuint(name))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPopName.xml
+func (gl *GL) PopName() {
+ C.gl1_4_glPopName(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPassThrough.xml
+func (gl *GL) PassThrough(token float32) {
+ C.gl1_4_glPassThrough(gl.funcs, C.GLfloat(token))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLoadName.xml
+func (gl *GL) LoadName(name uint32) {
+ C.gl1_4_glLoadName(gl.funcs, C.GLuint(name))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glInitNames.xml
+func (gl *GL) InitNames() {
+ C.gl1_4_glInitNames(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRenderMode.xml
+func (gl *GL) RenderMode(mode glbase.Enum) int32 {
+ glresult := C.gl1_4_glRenderMode(gl.funcs, C.GLenum(mode))
+ return int32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSelectBuffer.xml
+func (gl *GL) SelectBuffer(size int, buffer []glbase.Buffer) {
+ C.gl1_4_glSelectBuffer(gl.funcs, C.GLsizei(size), (*C.GLuint)(unsafe.Pointer(&buffer[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFeedbackBuffer.xml
+func (gl *GL) FeedbackBuffer(size int, gltype glbase.Enum, buffer []float32) {
+ C.gl1_4_glFeedbackBuffer(gl.funcs, C.GLsizei(size), C.GLenum(gltype), (*C.GLfloat)(unsafe.Pointer(&buffer[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexGeniv.xml
+func (gl *GL) TexGeniv(coord, pname glbase.Enum, params []int32) {
+ C.gl1_4_glTexGeniv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexGeni.xml
+func (gl *GL) TexGeni(coord, pname glbase.Enum, param int32) {
+ C.gl1_4_glTexGeni(gl.funcs, C.GLenum(coord), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexGenfv.xml
+func (gl *GL) TexGenfv(coord, pname glbase.Enum, params []float32) {
+ C.gl1_4_glTexGenfv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexGenf.xml
+func (gl *GL) TexGenf(coord, pname glbase.Enum, param float32) {
+ C.gl1_4_glTexGenf(gl.funcs, C.GLenum(coord), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexGendv.xml
+func (gl *GL) TexGendv(coord, pname glbase.Enum, params []float64) {
+ C.gl1_4_glTexGendv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexGend.xml
+func (gl *GL) TexGend(coord, pname glbase.Enum, param float64) {
+ C.gl1_4_glTexGend(gl.funcs, C.GLenum(coord), C.GLenum(pname), C.GLdouble(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexEnviv.xml
+func (gl *GL) TexEnviv(target, pname glbase.Enum, params []int32) {
+ C.gl1_4_glTexEnviv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexEnvi.xml
+func (gl *GL) TexEnvi(target, pname glbase.Enum, param int32) {
+ C.gl1_4_glTexEnvi(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexEnvfv.xml
+func (gl *GL) TexEnvfv(target, pname glbase.Enum, params []float32) {
+ C.gl1_4_glTexEnvfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexEnvf.xml
+func (gl *GL) TexEnvf(target, pname glbase.Enum, param float32) {
+ C.gl1_4_glTexEnvf(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glShadeModel.xml
+func (gl *GL) ShadeModel(mode glbase.Enum) {
+ C.gl1_4_glShadeModel(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPolygonStipple.xml
+func (gl *GL) PolygonStipple(mask []uint8) {
+ C.gl1_4_glPolygonStipple(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&mask[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMaterialiv.xml
+func (gl *GL) Materialiv(face, pname glbase.Enum, params []int32) {
+ C.gl1_4_glMaterialiv(gl.funcs, C.GLenum(face), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMateriali.xml
+func (gl *GL) Materiali(face, pname glbase.Enum, param int32) {
+ C.gl1_4_glMateriali(gl.funcs, C.GLenum(face), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMaterialfv.xml
+func (gl *GL) Materialfv(face, pname glbase.Enum, params []float32) {
+ C.gl1_4_glMaterialfv(gl.funcs, C.GLenum(face), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMaterialf.xml
+func (gl *GL) Materialf(face, pname glbase.Enum, param float32) {
+ C.gl1_4_glMaterialf(gl.funcs, C.GLenum(face), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLineStipple.xml
+func (gl *GL) LineStipple(factor int32, pattern uint16) {
+ C.gl1_4_glLineStipple(gl.funcs, C.GLint(factor), C.GLushort(pattern))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLightModeliv.xml
+func (gl *GL) LightModeliv(pname glbase.Enum, params []int32) {
+ C.gl1_4_glLightModeliv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLightModeli.xml
+func (gl *GL) LightModeli(pname glbase.Enum, param int32) {
+ C.gl1_4_glLightModeli(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLightModelfv.xml
+func (gl *GL) LightModelfv(pname glbase.Enum, params []float32) {
+ C.gl1_4_glLightModelfv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLightModelf.xml
+func (gl *GL) LightModelf(pname glbase.Enum, param float32) {
+ C.gl1_4_glLightModelf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLightiv.xml
+func (gl *GL) Lightiv(light, pname glbase.Enum, params []int32) {
+ C.gl1_4_glLightiv(gl.funcs, C.GLenum(light), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLighti.xml
+func (gl *GL) Lighti(light, pname glbase.Enum, param int32) {
+ C.gl1_4_glLighti(gl.funcs, C.GLenum(light), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLightfv.xml
+func (gl *GL) Lightfv(light, pname glbase.Enum, params []float32) {
+ C.gl1_4_glLightfv(gl.funcs, C.GLenum(light), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLightf.xml
+func (gl *GL) Lightf(light, pname glbase.Enum, param float32) {
+ C.gl1_4_glLightf(gl.funcs, C.GLenum(light), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFogiv.xml
+func (gl *GL) Fogiv(pname glbase.Enum, params []int32) {
+ C.gl1_4_glFogiv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFogi.xml
+func (gl *GL) Fogi(pname glbase.Enum, param int32) {
+ C.gl1_4_glFogi(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFogfv.xml
+func (gl *GL) Fogfv(pname glbase.Enum, params []float32) {
+ C.gl1_4_glFogfv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFogf.xml
+func (gl *GL) Fogf(pname glbase.Enum, param float32) {
+ C.gl1_4_glFogf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColorMaterial.xml
+func (gl *GL) ColorMaterial(face, mode glbase.Enum) {
+ C.gl1_4_glColorMaterial(gl.funcs, C.GLenum(face), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClipPlane.xml
+func (gl *GL) ClipPlane(plane glbase.Enum, equation []float64) {
+ C.gl1_4_glClipPlane(gl.funcs, C.GLenum(plane), (*C.GLdouble)(unsafe.Pointer(&equation[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4sv.xml
+func (gl *GL) Vertex4sv(v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glVertex4sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4s.xml
+func (gl *GL) Vertex4s(x, y, z, w int16) {
+ C.gl1_4_glVertex4s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z), C.GLshort(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4iv.xml
+func (gl *GL) Vertex4iv(v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glVertex4iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4i.xml
+func (gl *GL) Vertex4i(x, y, z, w int) {
+ C.gl1_4_glVertex4i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z), C.GLint(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4fv.xml
+func (gl *GL) Vertex4fv(v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glVertex4fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4f.xml
+func (gl *GL) Vertex4f(x, y, z, w float32) {
+ C.gl1_4_glVertex4f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z), C.GLfloat(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4dv.xml
+func (gl *GL) Vertex4dv(v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glVertex4dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4d.xml
+func (gl *GL) Vertex4d(x, y, z, w float64) {
+ C.gl1_4_glVertex4d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z), C.GLdouble(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3sv.xml
+func (gl *GL) Vertex3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glVertex3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3s.xml
+func (gl *GL) Vertex3s(x, y, z int16) {
+ C.gl1_4_glVertex3s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3iv.xml
+func (gl *GL) Vertex3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glVertex3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3i.xml
+func (gl *GL) Vertex3i(x, y, z int) {
+ C.gl1_4_glVertex3i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3fv.xml
+func (gl *GL) Vertex3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glVertex3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3f.xml
+func (gl *GL) Vertex3f(x, y, z float32) {
+ C.gl1_4_glVertex3f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3dv.xml
+func (gl *GL) Vertex3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glVertex3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3d.xml
+func (gl *GL) Vertex3d(x, y, z float64) {
+ C.gl1_4_glVertex3d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2sv.xml
+func (gl *GL) Vertex2sv(v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glVertex2sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2s.xml
+func (gl *GL) Vertex2s(x, y int16) {
+ C.gl1_4_glVertex2s(gl.funcs, C.GLshort(x), C.GLshort(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2iv.xml
+func (gl *GL) Vertex2iv(v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glVertex2iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2i.xml
+func (gl *GL) Vertex2i(x, y int) {
+ C.gl1_4_glVertex2i(gl.funcs, C.GLint(x), C.GLint(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2fv.xml
+func (gl *GL) Vertex2fv(v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glVertex2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2f.xml
+func (gl *GL) Vertex2f(x, y float32) {
+ C.gl1_4_glVertex2f(gl.funcs, C.GLfloat(x), C.GLfloat(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2dv.xml
+func (gl *GL) Vertex2dv(v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glVertex2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2d.xml
+func (gl *GL) Vertex2d(x, y float64) {
+ C.gl1_4_glVertex2d(gl.funcs, C.GLdouble(x), C.GLdouble(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4sv.xml
+func (gl *GL) TexCoord4sv(v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glTexCoord4sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4s.xml
+func (gl *GL) TexCoord4s(s, t, r, q int16) {
+ C.gl1_4_glTexCoord4s(gl.funcs, C.GLshort(s), C.GLshort(t), C.GLshort(r), C.GLshort(q))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4iv.xml
+func (gl *GL) TexCoord4iv(v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glTexCoord4iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4i.xml
+func (gl *GL) TexCoord4i(s, t, r, q int32) {
+ C.gl1_4_glTexCoord4i(gl.funcs, C.GLint(s), C.GLint(t), C.GLint(r), C.GLint(q))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4fv.xml
+func (gl *GL) TexCoord4fv(v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glTexCoord4fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4f.xml
+func (gl *GL) TexCoord4f(s, t, r, q float32) {
+ C.gl1_4_glTexCoord4f(gl.funcs, C.GLfloat(s), C.GLfloat(t), C.GLfloat(r), C.GLfloat(q))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4dv.xml
+func (gl *GL) TexCoord4dv(v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glTexCoord4dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4d.xml
+func (gl *GL) TexCoord4d(s, t, r, q float64) {
+ C.gl1_4_glTexCoord4d(gl.funcs, C.GLdouble(s), C.GLdouble(t), C.GLdouble(r), C.GLdouble(q))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3sv.xml
+func (gl *GL) TexCoord3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glTexCoord3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3s.xml
+func (gl *GL) TexCoord3s(s, t, r int16) {
+ C.gl1_4_glTexCoord3s(gl.funcs, C.GLshort(s), C.GLshort(t), C.GLshort(r))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3iv.xml
+func (gl *GL) TexCoord3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glTexCoord3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3i.xml
+func (gl *GL) TexCoord3i(s, t, r int32) {
+ C.gl1_4_glTexCoord3i(gl.funcs, C.GLint(s), C.GLint(t), C.GLint(r))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3fv.xml
+func (gl *GL) TexCoord3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glTexCoord3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3f.xml
+func (gl *GL) TexCoord3f(s, t, r float32) {
+ C.gl1_4_glTexCoord3f(gl.funcs, C.GLfloat(s), C.GLfloat(t), C.GLfloat(r))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3dv.xml
+func (gl *GL) TexCoord3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glTexCoord3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3d.xml
+func (gl *GL) TexCoord3d(s, t, r float64) {
+ C.gl1_4_glTexCoord3d(gl.funcs, C.GLdouble(s), C.GLdouble(t), C.GLdouble(r))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2sv.xml
+func (gl *GL) TexCoord2sv(v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glTexCoord2sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2s.xml
+func (gl *GL) TexCoord2s(s, t int16) {
+ C.gl1_4_glTexCoord2s(gl.funcs, C.GLshort(s), C.GLshort(t))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2iv.xml
+func (gl *GL) TexCoord2iv(v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glTexCoord2iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2i.xml
+func (gl *GL) TexCoord2i(s, t int32) {
+ C.gl1_4_glTexCoord2i(gl.funcs, C.GLint(s), C.GLint(t))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2fv.xml
+func (gl *GL) TexCoord2fv(v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glTexCoord2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2f.xml
+func (gl *GL) TexCoord2f(s, t float32) {
+ C.gl1_4_glTexCoord2f(gl.funcs, C.GLfloat(s), C.GLfloat(t))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2dv.xml
+func (gl *GL) TexCoord2dv(v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glTexCoord2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2d.xml
+func (gl *GL) TexCoord2d(s, t float64) {
+ C.gl1_4_glTexCoord2d(gl.funcs, C.GLdouble(s), C.GLdouble(t))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1sv.xml
+func (gl *GL) TexCoord1sv(v []int16) {
+ C.gl1_4_glTexCoord1sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1s.xml
+func (gl *GL) TexCoord1s(s int16) {
+ C.gl1_4_glTexCoord1s(gl.funcs, C.GLshort(s))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1iv.xml
+func (gl *GL) TexCoord1iv(v []int32) {
+ C.gl1_4_glTexCoord1iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1i.xml
+func (gl *GL) TexCoord1i(s int32) {
+ C.gl1_4_glTexCoord1i(gl.funcs, C.GLint(s))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1fv.xml
+func (gl *GL) TexCoord1fv(v []float32) {
+ C.gl1_4_glTexCoord1fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1f.xml
+func (gl *GL) TexCoord1f(s float32) {
+ C.gl1_4_glTexCoord1f(gl.funcs, C.GLfloat(s))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1dv.xml
+func (gl *GL) TexCoord1dv(v []float64) {
+ C.gl1_4_glTexCoord1dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1d.xml
+func (gl *GL) TexCoord1d(s float64) {
+ C.gl1_4_glTexCoord1d(gl.funcs, C.GLdouble(s))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRectsv.xml
+func (gl *GL) Rectsv(v1, v2 []int16) {
+ C.gl1_4_glRectsv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v1[0])), (*C.GLshort)(unsafe.Pointer(&v2[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRects.xml
+func (gl *GL) Rects(x1, y1, x2, y2 int16) {
+ C.gl1_4_glRects(gl.funcs, C.GLshort(x1), C.GLshort(y1), C.GLshort(x2), C.GLshort(y2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRectiv.xml
+func (gl *GL) Rectiv(v1, v2 []int32) {
+ C.gl1_4_glRectiv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v1[0])), (*C.GLint)(unsafe.Pointer(&v2[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRecti.xml
+func (gl *GL) Recti(x1, y1, x2, y2 int32) {
+ C.gl1_4_glRecti(gl.funcs, C.GLint(x1), C.GLint(y1), C.GLint(x2), C.GLint(y2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRectfv.xml
+func (gl *GL) Rectfv(v1, v2 []float32) {
+ C.gl1_4_glRectfv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v1[0])), (*C.GLfloat)(unsafe.Pointer(&v2[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRectf.xml
+func (gl *GL) Rectf(x1, y1, x2, y2 float32) {
+ C.gl1_4_glRectf(gl.funcs, C.GLfloat(x1), C.GLfloat(y1), C.GLfloat(x2), C.GLfloat(y2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRectdv.xml
+func (gl *GL) Rectdv(v1, v2 []float64) {
+ C.gl1_4_glRectdv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v1[0])), (*C.GLdouble)(unsafe.Pointer(&v2[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRectd.xml
+func (gl *GL) Rectd(x1, y1, x2, y2 float64) {
+ C.gl1_4_glRectd(gl.funcs, C.GLdouble(x1), C.GLdouble(y1), C.GLdouble(x2), C.GLdouble(y2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4sv.xml
+func (gl *GL) RasterPos4sv(v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glRasterPos4sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4s.xml
+func (gl *GL) RasterPos4s(x, y, z, w int16) {
+ C.gl1_4_glRasterPos4s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z), C.GLshort(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4iv.xml
+func (gl *GL) RasterPos4iv(v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glRasterPos4iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4i.xml
+func (gl *GL) RasterPos4i(x, y, z, w int) {
+ C.gl1_4_glRasterPos4i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z), C.GLint(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4fv.xml
+func (gl *GL) RasterPos4fv(v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glRasterPos4fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4f.xml
+func (gl *GL) RasterPos4f(x, y, z, w float32) {
+ C.gl1_4_glRasterPos4f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z), C.GLfloat(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4dv.xml
+func (gl *GL) RasterPos4dv(v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glRasterPos4dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4d.xml
+func (gl *GL) RasterPos4d(x, y, z, w float64) {
+ C.gl1_4_glRasterPos4d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z), C.GLdouble(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3sv.xml
+func (gl *GL) RasterPos3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glRasterPos3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3s.xml
+func (gl *GL) RasterPos3s(x, y, z int16) {
+ C.gl1_4_glRasterPos3s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3iv.xml
+func (gl *GL) RasterPos3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glRasterPos3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3i.xml
+func (gl *GL) RasterPos3i(x, y, z int) {
+ C.gl1_4_glRasterPos3i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3fv.xml
+func (gl *GL) RasterPos3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glRasterPos3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3f.xml
+func (gl *GL) RasterPos3f(x, y, z float32) {
+ C.gl1_4_glRasterPos3f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3dv.xml
+func (gl *GL) RasterPos3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glRasterPos3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3d.xml
+func (gl *GL) RasterPos3d(x, y, z float64) {
+ C.gl1_4_glRasterPos3d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2sv.xml
+func (gl *GL) RasterPos2sv(v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glRasterPos2sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2s.xml
+func (gl *GL) RasterPos2s(x, y int16) {
+ C.gl1_4_glRasterPos2s(gl.funcs, C.GLshort(x), C.GLshort(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2iv.xml
+func (gl *GL) RasterPos2iv(v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glRasterPos2iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2i.xml
+func (gl *GL) RasterPos2i(x, y int) {
+ C.gl1_4_glRasterPos2i(gl.funcs, C.GLint(x), C.GLint(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2fv.xml
+func (gl *GL) RasterPos2fv(v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glRasterPos2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2f.xml
+func (gl *GL) RasterPos2f(x, y float32) {
+ C.gl1_4_glRasterPos2f(gl.funcs, C.GLfloat(x), C.GLfloat(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2dv.xml
+func (gl *GL) RasterPos2dv(v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glRasterPos2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2d.xml
+func (gl *GL) RasterPos2d(x, y float64) {
+ C.gl1_4_glRasterPos2d(gl.funcs, C.GLdouble(x), C.GLdouble(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3sv.xml
+func (gl *GL) Normal3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glNormal3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3s.xml
+func (gl *GL) Normal3s(nx, ny, nz int16) {
+ C.gl1_4_glNormal3s(gl.funcs, C.GLshort(nx), C.GLshort(ny), C.GLshort(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3iv.xml
+func (gl *GL) Normal3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glNormal3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3i.xml
+func (gl *GL) Normal3i(nx, ny, nz int32) {
+ C.gl1_4_glNormal3i(gl.funcs, C.GLint(nx), C.GLint(ny), C.GLint(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3fv.xml
+func (gl *GL) Normal3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glNormal3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3f.xml
+func (gl *GL) Normal3f(nx, ny, nz float32) {
+ C.gl1_4_glNormal3f(gl.funcs, C.GLfloat(nx), C.GLfloat(ny), C.GLfloat(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3dv.xml
+func (gl *GL) Normal3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glNormal3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3d.xml
+func (gl *GL) Normal3d(nx, ny, nz float64) {
+ C.gl1_4_glNormal3d(gl.funcs, C.GLdouble(nx), C.GLdouble(ny), C.GLdouble(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3bv.xml
+func (gl *GL) Normal3bv(v []byte) {
+ C.gl1_4_glNormal3bv(gl.funcs, (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3b.xml
+func (gl *GL) Normal3b(nx, ny, nz byte) {
+ C.gl1_4_glNormal3b(gl.funcs, C.GLbyte(nx), C.GLbyte(ny), C.GLbyte(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexsv.xml
+func (gl *GL) Indexsv(c []int16) {
+ C.gl1_4_glIndexsv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexs.xml
+func (gl *GL) Indexs(c int16) {
+ C.gl1_4_glIndexs(gl.funcs, C.GLshort(c))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexiv.xml
+func (gl *GL) Indexiv(c []int32) {
+ C.gl1_4_glIndexiv(gl.funcs, (*C.GLint)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexi.xml
+func (gl *GL) Indexi(c int32) {
+ C.gl1_4_glIndexi(gl.funcs, C.GLint(c))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexfv.xml
+func (gl *GL) Indexfv(c []float32) {
+ C.gl1_4_glIndexfv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexf.xml
+func (gl *GL) Indexf(c float32) {
+ C.gl1_4_glIndexf(gl.funcs, C.GLfloat(c))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexdv.xml
+func (gl *GL) Indexdv(c []float64) {
+ C.gl1_4_glIndexdv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexd.xml
+func (gl *GL) Indexd(c float64) {
+ C.gl1_4_glIndexd(gl.funcs, C.GLdouble(c))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEnd.xml
+func (gl *GL) End() {
+ C.gl1_4_glEnd(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEdgeFlagv.xml
+func (gl *GL) EdgeFlagv(flag []bool) {
+ C.gl1_4_glEdgeFlagv(gl.funcs, (*C.GLboolean)(unsafe.Pointer(&flag[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEdgeFlag.xml
+func (gl *GL) EdgeFlag(flag bool) {
+ C.gl1_4_glEdgeFlag(gl.funcs, *(*C.GLboolean)(unsafe.Pointer(&flag)))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4usv.xml
+func (gl *GL) Color4usv(v []uint16) {
+ C.gl1_4_glColor4usv(gl.funcs, (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4us.xml
+func (gl *GL) Color4us(red, green, blue, alpha uint16) {
+ C.gl1_4_glColor4us(gl.funcs, C.GLushort(red), C.GLushort(green), C.GLushort(blue), C.GLushort(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4uiv.xml
+func (gl *GL) Color4uiv(v []uint32) {
+ C.gl1_4_glColor4uiv(gl.funcs, (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4ui.xml
+func (gl *GL) Color4ui(red, green, blue, alpha uint32) {
+ C.gl1_4_glColor4ui(gl.funcs, C.GLuint(red), C.GLuint(green), C.GLuint(blue), C.GLuint(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4ubv.xml
+func (gl *GL) Color4ubv(v []uint8) {
+ C.gl1_4_glColor4ubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4ub.xml
+func (gl *GL) Color4ub(red, green, blue, alpha uint8) {
+ C.gl1_4_glColor4ub(gl.funcs, C.GLubyte(red), C.GLubyte(green), C.GLubyte(blue), C.GLubyte(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4sv.xml
+func (gl *GL) Color4sv(v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glColor4sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4s.xml
+func (gl *GL) Color4s(red, green, blue, alpha int16) {
+ C.gl1_4_glColor4s(gl.funcs, C.GLshort(red), C.GLshort(green), C.GLshort(blue), C.GLshort(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4iv.xml
+func (gl *GL) Color4iv(v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glColor4iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4i.xml
+func (gl *GL) Color4i(red, green, blue, alpha int32) {
+ C.gl1_4_glColor4i(gl.funcs, C.GLint(red), C.GLint(green), C.GLint(blue), C.GLint(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4fv.xml
+func (gl *GL) Color4fv(v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glColor4fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4f.xml
+func (gl *GL) Color4f(red, green, blue, alpha float32) {
+ C.gl1_4_glColor4f(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4dv.xml
+func (gl *GL) Color4dv(v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glColor4dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4d.xml
+func (gl *GL) Color4d(red, green, blue, alpha float64) {
+ C.gl1_4_glColor4d(gl.funcs, C.GLdouble(red), C.GLdouble(green), C.GLdouble(blue), C.GLdouble(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4bv.xml
+func (gl *GL) Color4bv(v []byte) {
+ C.gl1_4_glColor4bv(gl.funcs, (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4b.xml
+func (gl *GL) Color4b(red, green, blue, alpha byte) {
+ C.gl1_4_glColor4b(gl.funcs, C.GLbyte(red), C.GLbyte(green), C.GLbyte(blue), C.GLbyte(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3usv.xml
+func (gl *GL) Color3usv(v []uint16) {
+ C.gl1_4_glColor3usv(gl.funcs, (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3us.xml
+func (gl *GL) Color3us(red, green, blue uint16) {
+ C.gl1_4_glColor3us(gl.funcs, C.GLushort(red), C.GLushort(green), C.GLushort(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3uiv.xml
+func (gl *GL) Color3uiv(v []uint32) {
+ C.gl1_4_glColor3uiv(gl.funcs, (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3ui.xml
+func (gl *GL) Color3ui(red, green, blue uint32) {
+ C.gl1_4_glColor3ui(gl.funcs, C.GLuint(red), C.GLuint(green), C.GLuint(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3ubv.xml
+func (gl *GL) Color3ubv(v []uint8) {
+ C.gl1_4_glColor3ubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3ub.xml
+func (gl *GL) Color3ub(red, green, blue uint8) {
+ C.gl1_4_glColor3ub(gl.funcs, C.GLubyte(red), C.GLubyte(green), C.GLubyte(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3sv.xml
+func (gl *GL) Color3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glColor3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3s.xml
+func (gl *GL) Color3s(red, green, blue int16) {
+ C.gl1_4_glColor3s(gl.funcs, C.GLshort(red), C.GLshort(green), C.GLshort(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3iv.xml
+func (gl *GL) Color3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glColor3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3i.xml
+func (gl *GL) Color3i(red, green, blue int32) {
+ C.gl1_4_glColor3i(gl.funcs, C.GLint(red), C.GLint(green), C.GLint(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3fv.xml
+func (gl *GL) Color3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glColor3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3f.xml
+func (gl *GL) Color3f(red, green, blue float32) {
+ C.gl1_4_glColor3f(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3dv.xml
+func (gl *GL) Color3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glColor3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3d.xml
+func (gl *GL) Color3d(red, green, blue float64) {
+ C.gl1_4_glColor3d(gl.funcs, C.GLdouble(red), C.GLdouble(green), C.GLdouble(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3bv.xml
+func (gl *GL) Color3bv(v []byte) {
+ C.gl1_4_glColor3bv(gl.funcs, (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3b.xml
+func (gl *GL) Color3b(red, green, blue byte) {
+ C.gl1_4_glColor3b(gl.funcs, C.GLbyte(red), C.GLbyte(green), C.GLbyte(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBitmap.xml
+func (gl *GL) Bitmap(width, height int, xorig, yorig, xmove, ymove float32, bitmap []uint8) {
+ C.gl1_4_glBitmap(gl.funcs, C.GLsizei(width), C.GLsizei(height), C.GLfloat(xorig), C.GLfloat(yorig), C.GLfloat(xmove), C.GLfloat(ymove), (*C.GLubyte)(unsafe.Pointer(&bitmap[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBegin.xml
+func (gl *GL) Begin(mode glbase.Enum) {
+ C.gl1_4_glBegin(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glListBase.xml
+func (gl *GL) ListBase(base uint32) {
+ C.gl1_4_glListBase(gl.funcs, C.GLuint(base))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGenLists.xml
+func (gl *GL) GenLists(range_ int32) uint32 {
+ glresult := C.gl1_4_glGenLists(gl.funcs, C.GLsizei(range_))
+ return uint32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDeleteLists.xml
+func (gl *GL) DeleteLists(list uint32, range_ int32) {
+ C.gl1_4_glDeleteLists(gl.funcs, C.GLuint(list), C.GLsizei(range_))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCallLists.xml
+func (gl *GL) CallLists(n int, gltype glbase.Enum, lists interface{}) {
+ var lists_ptr unsafe.Pointer
+ var lists_v = reflect.ValueOf(lists)
+ if lists != nil && lists_v.Kind() != reflect.Slice {
+ panic("parameter lists must be a slice")
+ }
+ if lists != nil {
+ lists_ptr = unsafe.Pointer(lists_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_4_glCallLists(gl.funcs, C.GLsizei(n), C.GLenum(gltype), lists_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCallList.xml
+func (gl *GL) CallList(list uint32) {
+ C.gl1_4_glCallList(gl.funcs, C.GLuint(list))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEndList.xml
+func (gl *GL) EndList() {
+ C.gl1_4_glEndList(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNewList.xml
+func (gl *GL) NewList(list uint32, mode glbase.Enum) {
+ C.gl1_4_glNewList(gl.funcs, C.GLuint(list), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPushClientAttrib.xml
+func (gl *GL) PushClientAttrib(mask glbase.Bitfield) {
+ C.gl1_4_glPushClientAttrib(gl.funcs, C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPopClientAttrib.xml
+func (gl *GL) PopClientAttrib() {
+ C.gl1_4_glPopClientAttrib(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPrioritizeTextures.xml
+func (gl *GL) PrioritizeTextures(n int, textures []glbase.Texture, priorities []float32) {
+ C.gl1_4_glPrioritizeTextures(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])), (*C.GLfloat)(unsafe.Pointer(&priorities[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glAreTexturesResident.xml
+func (gl *GL) AreTexturesResident(n int, textures []glbase.Texture, residences []bool) bool {
+ glresult := C.gl1_4_glAreTexturesResident(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])), (*C.GLboolean)(unsafe.Pointer(&residences[0])))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexPointer.xml
+func (gl *GL) VertexPointer(size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_4_glVertexPointer(gl.funcs, C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoordPointer.xml
+func (gl *GL) TexCoordPointer(size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_4_glTexCoordPointer(gl.funcs, C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormalPointer.xml
+func (gl *GL) NormalPointer(gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_4_glNormalPointer(gl.funcs, C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glInterleavedArrays.xml
+func (gl *GL) InterleavedArrays(format glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_4_glInterleavedArrays(gl.funcs, C.GLenum(format), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexPointer.xml
+func (gl *GL) IndexPointer(gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_4_glIndexPointer(gl.funcs, C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEnableClientState.xml
+func (gl *GL) EnableClientState(array glbase.Enum) {
+ C.gl1_4_glEnableClientState(gl.funcs, C.GLenum(array))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEdgeFlagPointer.xml
+func (gl *GL) EdgeFlagPointer(stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_4_glEdgeFlagPointer(gl.funcs, C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDisableClientState.xml
+func (gl *GL) DisableClientState(array glbase.Enum) {
+ C.gl1_4_glDisableClientState(gl.funcs, C.GLenum(array))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColorPointer.xml
+func (gl *GL) ColorPointer(size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_4_glColorPointer(gl.funcs, C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glArrayElement.xml
+func (gl *GL) ArrayElement(i int32) {
+ C.gl1_4_glArrayElement(gl.funcs, C.GLint(i))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glResetMinmax.xml
+func (gl *GL) ResetMinmax(target glbase.Enum) {
+ C.gl1_4_glResetMinmax(gl.funcs, C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glResetHistogram.xml
+func (gl *GL) ResetHistogram(target glbase.Enum) {
+ C.gl1_4_glResetHistogram(gl.funcs, C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMinmax.xml
+func (gl *GL) Minmax(target, internalFormat glbase.Enum, sink bool) {
+ C.gl1_4_glMinmax(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), *(*C.GLboolean)(unsafe.Pointer(&sink)))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glHistogram.xml
+func (gl *GL) Histogram(target glbase.Enum, width int, internalFormat glbase.Enum, sink bool) {
+ C.gl1_4_glHistogram(gl.funcs, C.GLenum(target), C.GLsizei(width), C.GLenum(internalFormat), *(*C.GLboolean)(unsafe.Pointer(&sink)))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetMinmaxParameteriv.xml
+func (gl *GL) GetMinmaxParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl1_4_glGetMinmaxParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetMinmaxParameterfv.xml
+func (gl *GL) GetMinmaxParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl1_4_glGetMinmaxParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetMinmax.xml
+func (gl *GL) GetMinmax(target glbase.Enum, reset bool, format, gltype glbase.Enum, values interface{}) {
+ var values_ptr unsafe.Pointer
+ var values_v = reflect.ValueOf(values)
+ if values != nil && values_v.Kind() != reflect.Slice {
+ panic("parameter values must be a slice")
+ }
+ if values != nil {
+ values_ptr = unsafe.Pointer(values_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_4_glGetMinmax(gl.funcs, C.GLenum(target), *(*C.GLboolean)(unsafe.Pointer(&reset)), C.GLenum(format), C.GLenum(gltype), values_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetHistogramParameteriv.xml
+func (gl *GL) GetHistogramParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl1_4_glGetHistogramParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetHistogramParameterfv.xml
+func (gl *GL) GetHistogramParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl1_4_glGetHistogramParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetHistogram.xml
+func (gl *GL) GetHistogram(target glbase.Enum, reset bool, format, gltype glbase.Enum, values interface{}) {
+ var values_ptr unsafe.Pointer
+ var values_v = reflect.ValueOf(values)
+ if values != nil && values_v.Kind() != reflect.Slice {
+ panic("parameter values must be a slice")
+ }
+ if values != nil {
+ values_ptr = unsafe.Pointer(values_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_4_glGetHistogram(gl.funcs, C.GLenum(target), *(*C.GLboolean)(unsafe.Pointer(&reset)), C.GLenum(format), C.GLenum(gltype), values_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSeparableFilter2D.xml
+func (gl *GL) SeparableFilter2D(target, internalFormat glbase.Enum, width, height int, format, gltype glbase.Enum, row, column interface{}) {
+ var row_ptr unsafe.Pointer
+ var row_v = reflect.ValueOf(row)
+ if row != nil && row_v.Kind() != reflect.Slice {
+ panic("parameter row must be a slice")
+ }
+ if row != nil {
+ row_ptr = unsafe.Pointer(row_v.Index(0).Addr().Pointer())
+ }
+ var column_ptr unsafe.Pointer
+ var column_v = reflect.ValueOf(column)
+ if column != nil && column_v.Kind() != reflect.Slice {
+ panic("parameter column must be a slice")
+ }
+ if column != nil {
+ column_ptr = unsafe.Pointer(column_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_4_glSeparableFilter2D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), row_ptr, column_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetSeparableFilter.xml
+func (gl *GL) GetSeparableFilter(target, format, gltype glbase.Enum, row, column, span interface{}) {
+ var row_ptr unsafe.Pointer
+ var row_v = reflect.ValueOf(row)
+ if row != nil && row_v.Kind() != reflect.Slice {
+ panic("parameter row must be a slice")
+ }
+ if row != nil {
+ row_ptr = unsafe.Pointer(row_v.Index(0).Addr().Pointer())
+ }
+ var column_ptr unsafe.Pointer
+ var column_v = reflect.ValueOf(column)
+ if column != nil && column_v.Kind() != reflect.Slice {
+ panic("parameter column must be a slice")
+ }
+ if column != nil {
+ column_ptr = unsafe.Pointer(column_v.Index(0).Addr().Pointer())
+ }
+ var span_ptr unsafe.Pointer
+ var span_v = reflect.ValueOf(span)
+ if span != nil && span_v.Kind() != reflect.Slice {
+ panic("parameter span must be a slice")
+ }
+ if span != nil {
+ span_ptr = unsafe.Pointer(span_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_4_glGetSeparableFilter(gl.funcs, C.GLenum(target), C.GLenum(format), C.GLenum(gltype), row_ptr, column_ptr, span_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetConvolutionParameteriv.xml
+func (gl *GL) GetConvolutionParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl1_4_glGetConvolutionParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetConvolutionParameterfv.xml
+func (gl *GL) GetConvolutionParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl1_4_glGetConvolutionParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetConvolutionFilter.xml
+func (gl *GL) GetConvolutionFilter(target, format, gltype glbase.Enum, image interface{}) {
+ var image_ptr unsafe.Pointer
+ var image_v = reflect.ValueOf(image)
+ if image != nil && image_v.Kind() != reflect.Slice {
+ panic("parameter image must be a slice")
+ }
+ if image != nil {
+ image_ptr = unsafe.Pointer(image_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_4_glGetConvolutionFilter(gl.funcs, C.GLenum(target), C.GLenum(format), C.GLenum(gltype), image_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyConvolutionFilter2D.xml
+func (gl *GL) CopyConvolutionFilter2D(target, internalFormat glbase.Enum, x, y, width, height int) {
+ C.gl1_4_glCopyConvolutionFilter2D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyConvolutionFilter1D.xml
+func (gl *GL) CopyConvolutionFilter1D(target, internalFormat glbase.Enum, x, y, width int) {
+ C.gl1_4_glCopyConvolutionFilter1D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glConvolutionParameteriv.xml
+func (gl *GL) ConvolutionParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl1_4_glConvolutionParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glConvolutionParameteri.xml
+func (gl *GL) ConvolutionParameteri(target, pname glbase.Enum, params int32) {
+ C.gl1_4_glConvolutionParameteri(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLint(params))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glConvolutionParameterfv.xml
+func (gl *GL) ConvolutionParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl1_4_glConvolutionParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glConvolutionParameterf.xml
+func (gl *GL) ConvolutionParameterf(target, pname glbase.Enum, params float32) {
+ C.gl1_4_glConvolutionParameterf(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLfloat(params))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glConvolutionFilter2D.xml
+func (gl *GL) ConvolutionFilter2D(target, internalFormat glbase.Enum, width, height int, format, gltype glbase.Enum, image interface{}) {
+ var image_ptr unsafe.Pointer
+ var image_v = reflect.ValueOf(image)
+ if image != nil && image_v.Kind() != reflect.Slice {
+ panic("parameter image must be a slice")
+ }
+ if image != nil {
+ image_ptr = unsafe.Pointer(image_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_4_glConvolutionFilter2D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), image_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glConvolutionFilter1D.xml
+func (gl *GL) ConvolutionFilter1D(target, internalFormat glbase.Enum, width int, format, gltype glbase.Enum, image interface{}) {
+ var image_ptr unsafe.Pointer
+ var image_v = reflect.ValueOf(image)
+ if image != nil && image_v.Kind() != reflect.Slice {
+ panic("parameter image must be a slice")
+ }
+ if image != nil {
+ image_ptr = unsafe.Pointer(image_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_4_glConvolutionFilter1D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLenum(format), C.GLenum(gltype), image_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyColorSubTable.xml
+func (gl *GL) CopyColorSubTable(target glbase.Enum, start int32, x, y, width int) {
+ C.gl1_4_glCopyColorSubTable(gl.funcs, C.GLenum(target), C.GLsizei(start), C.GLint(x), C.GLint(y), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColorSubTable.xml
+func (gl *GL) ColorSubTable(target glbase.Enum, start int32, count int, format, gltype glbase.Enum, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_4_glColorSubTable(gl.funcs, C.GLenum(target), C.GLsizei(start), C.GLsizei(count), C.GLenum(format), C.GLenum(gltype), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetColorTableParameteriv.xml
+func (gl *GL) GetColorTableParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl1_4_glGetColorTableParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetColorTableParameterfv.xml
+func (gl *GL) GetColorTableParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl1_4_glGetColorTableParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetColorTable.xml
+func (gl *GL) GetColorTable(target, format, gltype glbase.Enum, table interface{}) {
+ var table_ptr unsafe.Pointer
+ var table_v = reflect.ValueOf(table)
+ if table != nil && table_v.Kind() != reflect.Slice {
+ panic("parameter table must be a slice")
+ }
+ if table != nil {
+ table_ptr = unsafe.Pointer(table_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_4_glGetColorTable(gl.funcs, C.GLenum(target), C.GLenum(format), C.GLenum(gltype), table_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyColorTable.xml
+func (gl *GL) CopyColorTable(target, internalFormat glbase.Enum, x, y, width int) {
+ C.gl1_4_glCopyColorTable(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColorTableParameteriv.xml
+func (gl *GL) ColorTableParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl1_4_glColorTableParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColorTableParameterfv.xml
+func (gl *GL) ColorTableParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl1_4_glColorTableParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColorTable.xml
+func (gl *GL) ColorTable(target, internalFormat glbase.Enum, width int, format, gltype glbase.Enum, table interface{}) {
+ var table_ptr unsafe.Pointer
+ var table_v = reflect.ValueOf(table)
+ if table != nil && table_v.Kind() != reflect.Slice {
+ panic("parameter table must be a slice")
+ }
+ if table != nil {
+ table_ptr = unsafe.Pointer(table_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_4_glColorTable(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLenum(format), C.GLenum(gltype), table_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultTransposeMatrixd.xml
+func (gl *GL) MultTransposeMatrixd(m []float64) {
+ C.gl1_4_glMultTransposeMatrixd(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultTransposeMatrixf.xml
+func (gl *GL) MultTransposeMatrixf(m []float32) {
+ C.gl1_4_glMultTransposeMatrixf(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLoadTransposeMatrixd.xml
+func (gl *GL) LoadTransposeMatrixd(m []float64) {
+ C.gl1_4_glLoadTransposeMatrixd(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLoadTransposeMatrixf.xml
+func (gl *GL) LoadTransposeMatrixf(m []float32) {
+ C.gl1_4_glLoadTransposeMatrixf(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord4sv.xml
+func (gl *GL) MultiTexCoord4sv(target glbase.Enum, v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glMultiTexCoord4sv(gl.funcs, C.GLenum(target), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord4s.xml
+func (gl *GL) MultiTexCoord4s(target glbase.Enum, s, t, r, q int16) {
+ C.gl1_4_glMultiTexCoord4s(gl.funcs, C.GLenum(target), C.GLshort(s), C.GLshort(t), C.GLshort(r), C.GLshort(q))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord4iv.xml
+func (gl *GL) MultiTexCoord4iv(target glbase.Enum, v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glMultiTexCoord4iv(gl.funcs, C.GLenum(target), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord4i.xml
+func (gl *GL) MultiTexCoord4i(target glbase.Enum, s, t, r, q int32) {
+ C.gl1_4_glMultiTexCoord4i(gl.funcs, C.GLenum(target), C.GLint(s), C.GLint(t), C.GLint(r), C.GLint(q))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord4fv.xml
+func (gl *GL) MultiTexCoord4fv(target glbase.Enum, v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glMultiTexCoord4fv(gl.funcs, C.GLenum(target), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord4f.xml
+func (gl *GL) MultiTexCoord4f(target glbase.Enum, s, t, r, q float32) {
+ C.gl1_4_glMultiTexCoord4f(gl.funcs, C.GLenum(target), C.GLfloat(s), C.GLfloat(t), C.GLfloat(r), C.GLfloat(q))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord4dv.xml
+func (gl *GL) MultiTexCoord4dv(target glbase.Enum, v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glMultiTexCoord4dv(gl.funcs, C.GLenum(target), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord4d.xml
+func (gl *GL) MultiTexCoord4d(target glbase.Enum, s, t, r, q float64) {
+ C.gl1_4_glMultiTexCoord4d(gl.funcs, C.GLenum(target), C.GLdouble(s), C.GLdouble(t), C.GLdouble(r), C.GLdouble(q))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord3sv.xml
+func (gl *GL) MultiTexCoord3sv(target glbase.Enum, v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glMultiTexCoord3sv(gl.funcs, C.GLenum(target), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord3s.xml
+func (gl *GL) MultiTexCoord3s(target glbase.Enum, s, t, r int16) {
+ C.gl1_4_glMultiTexCoord3s(gl.funcs, C.GLenum(target), C.GLshort(s), C.GLshort(t), C.GLshort(r))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord3iv.xml
+func (gl *GL) MultiTexCoord3iv(target glbase.Enum, v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glMultiTexCoord3iv(gl.funcs, C.GLenum(target), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord3i.xml
+func (gl *GL) MultiTexCoord3i(target glbase.Enum, s, t, r int32) {
+ C.gl1_4_glMultiTexCoord3i(gl.funcs, C.GLenum(target), C.GLint(s), C.GLint(t), C.GLint(r))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord3fv.xml
+func (gl *GL) MultiTexCoord3fv(target glbase.Enum, v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glMultiTexCoord3fv(gl.funcs, C.GLenum(target), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord3f.xml
+func (gl *GL) MultiTexCoord3f(target glbase.Enum, s, t, r float32) {
+ C.gl1_4_glMultiTexCoord3f(gl.funcs, C.GLenum(target), C.GLfloat(s), C.GLfloat(t), C.GLfloat(r))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord3dv.xml
+func (gl *GL) MultiTexCoord3dv(target glbase.Enum, v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glMultiTexCoord3dv(gl.funcs, C.GLenum(target), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord3d.xml
+func (gl *GL) MultiTexCoord3d(target glbase.Enum, s, t, r float64) {
+ C.gl1_4_glMultiTexCoord3d(gl.funcs, C.GLenum(target), C.GLdouble(s), C.GLdouble(t), C.GLdouble(r))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord2sv.xml
+func (gl *GL) MultiTexCoord2sv(target glbase.Enum, v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glMultiTexCoord2sv(gl.funcs, C.GLenum(target), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord2s.xml
+func (gl *GL) MultiTexCoord2s(target glbase.Enum, s, t int16) {
+ C.gl1_4_glMultiTexCoord2s(gl.funcs, C.GLenum(target), C.GLshort(s), C.GLshort(t))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord2iv.xml
+func (gl *GL) MultiTexCoord2iv(target glbase.Enum, v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glMultiTexCoord2iv(gl.funcs, C.GLenum(target), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord2i.xml
+func (gl *GL) MultiTexCoord2i(target glbase.Enum, s, t int32) {
+ C.gl1_4_glMultiTexCoord2i(gl.funcs, C.GLenum(target), C.GLint(s), C.GLint(t))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord2fv.xml
+func (gl *GL) MultiTexCoord2fv(target glbase.Enum, v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glMultiTexCoord2fv(gl.funcs, C.GLenum(target), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord2f.xml
+func (gl *GL) MultiTexCoord2f(target glbase.Enum, s, t float32) {
+ C.gl1_4_glMultiTexCoord2f(gl.funcs, C.GLenum(target), C.GLfloat(s), C.GLfloat(t))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord2dv.xml
+func (gl *GL) MultiTexCoord2dv(target glbase.Enum, v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glMultiTexCoord2dv(gl.funcs, C.GLenum(target), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord2d.xml
+func (gl *GL) MultiTexCoord2d(target glbase.Enum, s, t float64) {
+ C.gl1_4_glMultiTexCoord2d(gl.funcs, C.GLenum(target), C.GLdouble(s), C.GLdouble(t))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord1sv.xml
+func (gl *GL) MultiTexCoord1sv(target glbase.Enum, v []int16) {
+ C.gl1_4_glMultiTexCoord1sv(gl.funcs, C.GLenum(target), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord1s.xml
+func (gl *GL) MultiTexCoord1s(target glbase.Enum, s int16) {
+ C.gl1_4_glMultiTexCoord1s(gl.funcs, C.GLenum(target), C.GLshort(s))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord1iv.xml
+func (gl *GL) MultiTexCoord1iv(target glbase.Enum, v []int32) {
+ C.gl1_4_glMultiTexCoord1iv(gl.funcs, C.GLenum(target), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord1i.xml
+func (gl *GL) MultiTexCoord1i(target glbase.Enum, s int32) {
+ C.gl1_4_glMultiTexCoord1i(gl.funcs, C.GLenum(target), C.GLint(s))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord1fv.xml
+func (gl *GL) MultiTexCoord1fv(target glbase.Enum, v []float32) {
+ C.gl1_4_glMultiTexCoord1fv(gl.funcs, C.GLenum(target), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord1f.xml
+func (gl *GL) MultiTexCoord1f(target glbase.Enum, s float32) {
+ C.gl1_4_glMultiTexCoord1f(gl.funcs, C.GLenum(target), C.GLfloat(s))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord1dv.xml
+func (gl *GL) MultiTexCoord1dv(target glbase.Enum, v []float64) {
+ C.gl1_4_glMultiTexCoord1dv(gl.funcs, C.GLenum(target), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord1d.xml
+func (gl *GL) MultiTexCoord1d(target glbase.Enum, s float64) {
+ C.gl1_4_glMultiTexCoord1d(gl.funcs, C.GLenum(target), C.GLdouble(s))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClientActiveTexture.xml
+func (gl *GL) ClientActiveTexture(texture glbase.Enum) {
+ C.gl1_4_glClientActiveTexture(gl.funcs, C.GLenum(texture))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos3sv.xml
+func (gl *GL) WindowPos3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glWindowPos3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos3s.xml
+func (gl *GL) WindowPos3s(x, y, z int16) {
+ C.gl1_4_glWindowPos3s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos3iv.xml
+func (gl *GL) WindowPos3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glWindowPos3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos3i.xml
+func (gl *GL) WindowPos3i(x, y, z int) {
+ C.gl1_4_glWindowPos3i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos3fv.xml
+func (gl *GL) WindowPos3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glWindowPos3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos3f.xml
+func (gl *GL) WindowPos3f(x, y, z float32) {
+ C.gl1_4_glWindowPos3f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos3dv.xml
+func (gl *GL) WindowPos3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glWindowPos3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos3d.xml
+func (gl *GL) WindowPos3d(x, y, z float64) {
+ C.gl1_4_glWindowPos3d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos2sv.xml
+func (gl *GL) WindowPos2sv(v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glWindowPos2sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos2s.xml
+func (gl *GL) WindowPos2s(x, y int16) {
+ C.gl1_4_glWindowPos2s(gl.funcs, C.GLshort(x), C.GLshort(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos2iv.xml
+func (gl *GL) WindowPos2iv(v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glWindowPos2iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos2i.xml
+func (gl *GL) WindowPos2i(x, y int) {
+ C.gl1_4_glWindowPos2i(gl.funcs, C.GLint(x), C.GLint(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos2fv.xml
+func (gl *GL) WindowPos2fv(v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glWindowPos2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos2f.xml
+func (gl *GL) WindowPos2f(x, y float32) {
+ C.gl1_4_glWindowPos2f(gl.funcs, C.GLfloat(x), C.GLfloat(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos2dv.xml
+func (gl *GL) WindowPos2dv(v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glWindowPos2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos2d.xml
+func (gl *GL) WindowPos2d(x, y float64) {
+ C.gl1_4_glWindowPos2d(gl.funcs, C.GLdouble(x), C.GLdouble(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColorPointer.xml
+func (gl *GL) SecondaryColorPointer(size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_4_glSecondaryColorPointer(gl.funcs, C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3usv.xml
+func (gl *GL) SecondaryColor3usv(v []uint16) {
+ C.gl1_4_glSecondaryColor3usv(gl.funcs, (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3us.xml
+func (gl *GL) SecondaryColor3us(red, green, blue uint16) {
+ C.gl1_4_glSecondaryColor3us(gl.funcs, C.GLushort(red), C.GLushort(green), C.GLushort(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3uiv.xml
+func (gl *GL) SecondaryColor3uiv(v []uint32) {
+ C.gl1_4_glSecondaryColor3uiv(gl.funcs, (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3ui.xml
+func (gl *GL) SecondaryColor3ui(red, green, blue uint32) {
+ C.gl1_4_glSecondaryColor3ui(gl.funcs, C.GLuint(red), C.GLuint(green), C.GLuint(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3ubv.xml
+func (gl *GL) SecondaryColor3ubv(v []uint8) {
+ C.gl1_4_glSecondaryColor3ubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3ub.xml
+func (gl *GL) SecondaryColor3ub(red, green, blue uint8) {
+ C.gl1_4_glSecondaryColor3ub(gl.funcs, C.GLubyte(red), C.GLubyte(green), C.GLubyte(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3sv.xml
+func (gl *GL) SecondaryColor3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glSecondaryColor3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3s.xml
+func (gl *GL) SecondaryColor3s(red, green, blue int16) {
+ C.gl1_4_glSecondaryColor3s(gl.funcs, C.GLshort(red), C.GLshort(green), C.GLshort(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3iv.xml
+func (gl *GL) SecondaryColor3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glSecondaryColor3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3i.xml
+func (gl *GL) SecondaryColor3i(red, green, blue int32) {
+ C.gl1_4_glSecondaryColor3i(gl.funcs, C.GLint(red), C.GLint(green), C.GLint(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3fv.xml
+func (gl *GL) SecondaryColor3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glSecondaryColor3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3f.xml
+func (gl *GL) SecondaryColor3f(red, green, blue float32) {
+ C.gl1_4_glSecondaryColor3f(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3dv.xml
+func (gl *GL) SecondaryColor3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_4_glSecondaryColor3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3d.xml
+func (gl *GL) SecondaryColor3d(red, green, blue float64) {
+ C.gl1_4_glSecondaryColor3d(gl.funcs, C.GLdouble(red), C.GLdouble(green), C.GLdouble(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3bv.xml
+func (gl *GL) SecondaryColor3bv(v []byte) {
+ C.gl1_4_glSecondaryColor3bv(gl.funcs, (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3b.xml
+func (gl *GL) SecondaryColor3b(red, green, blue byte) {
+ C.gl1_4_glSecondaryColor3b(gl.funcs, C.GLbyte(red), C.GLbyte(green), C.GLbyte(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFogCoordPointer.xml
+func (gl *GL) FogCoordPointer(gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_4_glFogCoordPointer(gl.funcs, C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFogCoorddv.xml
+func (gl *GL) FogCoorddv(coord []float64) {
+ C.gl1_4_glFogCoorddv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&coord[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFogCoordd.xml
+func (gl *GL) FogCoordd(coord float64) {
+ C.gl1_4_glFogCoordd(gl.funcs, C.GLdouble(coord))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFogCoordfv.xml
+func (gl *GL) FogCoordfv(coord []float32) {
+ C.gl1_4_glFogCoordfv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&coord[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFogCoordf.xml
+func (gl *GL) FogCoordf(coord float32) {
+ C.gl1_4_glFogCoordf(gl.funcs, C.GLfloat(coord))
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/1.5/funcs.cpp b/Godeps/_workspace/src/github.com/obscuren/qml/gl/1.5/funcs.cpp
new file mode 100644
index 000000000..6158162fc
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/1.5/funcs.cpp
@@ -0,0 +1,2892 @@
+
+// ** file automatically generated by glgen -- do not edit manually **
+
+#include <QOpenGLContext>
+#include <QtGui/qopenglfunctions_1_5.h>
+
+#include "funcs.h"
+
+void *gl1_5_funcs() {
+ QOpenGLFunctions_1_5* funcs = QOpenGLContext::currentContext()->versionFunctions<QOpenGLFunctions_1_5>();
+ if (!funcs) {
+ return 0;
+ }
+ funcs->initializeOpenGLFunctions();
+ return funcs;
+}
+
+
+void gl1_5_glViewport(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glViewport(x, y, width, height);
+}
+
+void gl1_5_glDepthRange(void *_glfuncs, GLdouble nearVal, GLdouble farVal)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glDepthRange(nearVal, farVal);
+}
+
+GLboolean gl1_5_glIsEnabled(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ return _qglfuncs->glIsEnabled(cap);
+}
+
+void gl1_5_glGetTexLevelParameteriv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glGetTexLevelParameteriv(target, level, pname, params);
+}
+
+void gl1_5_glGetTexLevelParameterfv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glGetTexLevelParameterfv(target, level, pname, params);
+}
+
+void gl1_5_glGetTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glGetTexParameteriv(target, pname, params);
+}
+
+void gl1_5_glGetTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glGetTexParameterfv(target, pname, params);
+}
+
+void gl1_5_glGetTexImage(void *_glfuncs, GLenum target, GLint level, GLenum format, GLenum gltype, GLvoid* pixels)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glGetTexImage(target, level, format, gltype, pixels);
+}
+
+void gl1_5_glGetIntegerv(void *_glfuncs, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glGetIntegerv(pname, params);
+}
+
+void gl1_5_glGetFloatv(void *_glfuncs, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glGetFloatv(pname, params);
+}
+
+GLenum gl1_5_glGetError(void *_glfuncs)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ return _qglfuncs->glGetError();
+}
+
+void gl1_5_glGetDoublev(void *_glfuncs, GLenum pname, GLdouble* params)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glGetDoublev(pname, params);
+}
+
+void gl1_5_glGetBooleanv(void *_glfuncs, GLenum pname, GLboolean* params)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glGetBooleanv(pname, params);
+}
+
+void gl1_5_glReadPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum gltype, GLvoid* pixels)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glReadPixels(x, y, width, height, format, gltype, pixels);
+}
+
+void gl1_5_glReadBuffer(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glReadBuffer(mode);
+}
+
+void gl1_5_glPixelStorei(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glPixelStorei(pname, param);
+}
+
+void gl1_5_glPixelStoref(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glPixelStoref(pname, param);
+}
+
+void gl1_5_glDepthFunc(void *_glfuncs, GLenum glfunc)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glDepthFunc(glfunc);
+}
+
+void gl1_5_glStencilOp(void *_glfuncs, GLenum fail, GLenum zfail, GLenum zpass)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glStencilOp(fail, zfail, zpass);
+}
+
+void gl1_5_glStencilFunc(void *_glfuncs, GLenum glfunc, GLint ref, GLuint mask)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glStencilFunc(glfunc, ref, mask);
+}
+
+void gl1_5_glLogicOp(void *_glfuncs, GLenum opcode)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glLogicOp(opcode);
+}
+
+void gl1_5_glBlendFunc(void *_glfuncs, GLenum sfactor, GLenum dfactor)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glBlendFunc(sfactor, dfactor);
+}
+
+void gl1_5_glFlush(void *_glfuncs)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glFlush();
+}
+
+void gl1_5_glFinish(void *_glfuncs)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glFinish();
+}
+
+void gl1_5_glEnable(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glEnable(cap);
+}
+
+void gl1_5_glDisable(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glDisable(cap);
+}
+
+void gl1_5_glDepthMask(void *_glfuncs, GLboolean flag)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glDepthMask(flag);
+}
+
+void gl1_5_glColorMask(void *_glfuncs, GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glColorMask(red, green, blue, alpha);
+}
+
+void gl1_5_glStencilMask(void *_glfuncs, GLuint mask)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glStencilMask(mask);
+}
+
+void gl1_5_glClearDepth(void *_glfuncs, GLdouble depth)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glClearDepth(depth);
+}
+
+void gl1_5_glClearStencil(void *_glfuncs, GLint s)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glClearStencil(s);
+}
+
+void gl1_5_glClearColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glClearColor(red, green, blue, alpha);
+}
+
+void gl1_5_glClear(void *_glfuncs, GLbitfield mask)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glClear(mask);
+}
+
+void gl1_5_glDrawBuffer(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glDrawBuffer(mode);
+}
+
+void gl1_5_glTexImage2D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glTexImage2D(target, level, internalFormat, width, height, border, format, gltype, pixels);
+}
+
+void gl1_5_glTexImage1D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glTexImage1D(target, level, internalFormat, width, border, format, gltype, pixels);
+}
+
+void gl1_5_glTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glTexParameteriv(target, pname, params);
+}
+
+void gl1_5_glTexParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glTexParameteri(target, pname, param);
+}
+
+void gl1_5_glTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glTexParameterfv(target, pname, params);
+}
+
+void gl1_5_glTexParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glTexParameterf(target, pname, param);
+}
+
+void gl1_5_glScissor(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glScissor(x, y, width, height);
+}
+
+void gl1_5_glPolygonMode(void *_glfuncs, GLenum face, GLenum mode)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glPolygonMode(face, mode);
+}
+
+void gl1_5_glPointSize(void *_glfuncs, GLfloat size)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glPointSize(size);
+}
+
+void gl1_5_glLineWidth(void *_glfuncs, GLfloat width)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glLineWidth(width);
+}
+
+void gl1_5_glHint(void *_glfuncs, GLenum target, GLenum mode)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glHint(target, mode);
+}
+
+void gl1_5_glFrontFace(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glFrontFace(mode);
+}
+
+void gl1_5_glCullFace(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glCullFace(mode);
+}
+
+void gl1_5_glIndexubv(void *_glfuncs, const GLubyte* c)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glIndexubv(c);
+}
+
+void gl1_5_glIndexub(void *_glfuncs, GLubyte c)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glIndexub(c);
+}
+
+GLboolean gl1_5_glIsTexture(void *_glfuncs, GLuint texture)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ return _qglfuncs->glIsTexture(texture);
+}
+
+void gl1_5_glGenTextures(void *_glfuncs, GLsizei n, GLuint* textures)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glGenTextures(n, textures);
+}
+
+void gl1_5_glDeleteTextures(void *_glfuncs, GLsizei n, const GLuint* textures)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glDeleteTextures(n, textures);
+}
+
+void gl1_5_glBindTexture(void *_glfuncs, GLenum target, GLuint texture)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glBindTexture(target, texture);
+}
+
+void gl1_5_glTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glTexSubImage2D(target, level, xoffset, yoffset, width, height, format, gltype, pixels);
+}
+
+void gl1_5_glTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glTexSubImage1D(target, level, xoffset, width, format, gltype, pixels);
+}
+
+void gl1_5_glCopyTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage2D(target, level, xoffset, yoffset, x, y, width, height);
+}
+
+void gl1_5_glCopyTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage1D(target, level, xoffset, x, y, width);
+}
+
+void gl1_5_glCopyTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glCopyTexImage2D(target, level, internalFormat, x, y, width, height, border);
+}
+
+void gl1_5_glCopyTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLint border)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glCopyTexImage1D(target, level, internalFormat, x, y, width, border);
+}
+
+void gl1_5_glPolygonOffset(void *_glfuncs, GLfloat factor, GLfloat units)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glPolygonOffset(factor, units);
+}
+
+void gl1_5_glDrawElements(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glDrawElements(mode, count, gltype, indices);
+}
+
+void gl1_5_glDrawArrays(void *_glfuncs, GLenum mode, GLint first, GLsizei count)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glDrawArrays(mode, first, count);
+}
+
+void gl1_5_glCopyTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage3D(target, level, xoffset, yoffset, zoffset, x, y, width, height);
+}
+
+void gl1_5_glTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glTexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, gltype, pixels);
+}
+
+void gl1_5_glTexImage3D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glTexImage3D(target, level, internalFormat, width, height, depth, border, format, gltype, pixels);
+}
+
+void gl1_5_glDrawRangeElements(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glDrawRangeElements(mode, start, end, count, gltype, indices);
+}
+
+void gl1_5_glBlendEquation(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glBlendEquation(mode);
+}
+
+void gl1_5_glBlendColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glBlendColor(red, green, blue, alpha);
+}
+
+void gl1_5_glGetCompressedTexImage(void *_glfuncs, GLenum target, GLint level, GLvoid* img)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glGetCompressedTexImage(target, level, img);
+}
+
+void gl1_5_glCompressedTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glCompressedTexSubImage1D(target, level, xoffset, width, format, imageSize, data);
+}
+
+void gl1_5_glCompressedTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glCompressedTexSubImage2D(target, level, xoffset, yoffset, width, height, format, imageSize, data);
+}
+
+void gl1_5_glCompressedTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glCompressedTexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, imageSize, data);
+}
+
+void gl1_5_glCompressedTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glCompressedTexImage1D(target, level, internalFormat, width, border, imageSize, data);
+}
+
+void gl1_5_glCompressedTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glCompressedTexImage2D(target, level, internalFormat, width, height, border, imageSize, data);
+}
+
+void gl1_5_glCompressedTexImage3D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glCompressedTexImage3D(target, level, internalFormat, width, height, depth, border, imageSize, data);
+}
+
+void gl1_5_glSampleCoverage(void *_glfuncs, GLfloat value, GLboolean invert)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glSampleCoverage(value, invert);
+}
+
+void gl1_5_glActiveTexture(void *_glfuncs, GLenum texture)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glActiveTexture(texture);
+}
+
+void gl1_5_glPointParameteriv(void *_glfuncs, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glPointParameteriv(pname, params);
+}
+
+void gl1_5_glPointParameteri(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glPointParameteri(pname, param);
+}
+
+void gl1_5_glPointParameterfv(void *_glfuncs, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glPointParameterfv(pname, params);
+}
+
+void gl1_5_glPointParameterf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glPointParameterf(pname, param);
+}
+
+void gl1_5_glMultiDrawArrays(void *_glfuncs, GLenum mode, const GLint* first, const GLsizei* count, GLsizei drawcount)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glMultiDrawArrays(mode, first, count, drawcount);
+}
+
+void gl1_5_glBlendFuncSeparate(void *_glfuncs, GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glBlendFuncSeparate(sfactorRGB, dfactorRGB, sfactorAlpha, dfactorAlpha);
+}
+
+void gl1_5_glGetBufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glGetBufferParameteriv(target, pname, params);
+}
+
+GLboolean gl1_5_glUnmapBuffer(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ return _qglfuncs->glUnmapBuffer(target);
+}
+
+void gl1_5_glGetBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, GLvoid* data)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glGetBufferSubData(target, offset, size, data);
+}
+
+void gl1_5_glBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid* data)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glBufferSubData(target, offset, size, data);
+}
+
+void gl1_5_glBufferData(void *_glfuncs, GLenum target, GLsizeiptr size, const GLvoid* data, GLenum usage)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glBufferData(target, size, data, usage);
+}
+
+GLboolean gl1_5_glIsBuffer(void *_glfuncs, GLuint buffer)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ return _qglfuncs->glIsBuffer(buffer);
+}
+
+void gl1_5_glGenBuffers(void *_glfuncs, GLsizei n, GLuint* buffers)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glGenBuffers(n, buffers);
+}
+
+void gl1_5_glDeleteBuffers(void *_glfuncs, GLsizei n, const GLuint* buffers)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glDeleteBuffers(n, buffers);
+}
+
+void gl1_5_glBindBuffer(void *_glfuncs, GLenum target, GLuint buffer)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glBindBuffer(target, buffer);
+}
+
+void gl1_5_glGetQueryObjectuiv(void *_glfuncs, GLuint id, GLenum pname, GLuint* params)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glGetQueryObjectuiv(id, pname, params);
+}
+
+void gl1_5_glGetQueryObjectiv(void *_glfuncs, GLuint id, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glGetQueryObjectiv(id, pname, params);
+}
+
+void gl1_5_glGetQueryiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glGetQueryiv(target, pname, params);
+}
+
+void gl1_5_glEndQuery(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glEndQuery(target);
+}
+
+void gl1_5_glBeginQuery(void *_glfuncs, GLenum target, GLuint id)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glBeginQuery(target, id);
+}
+
+GLboolean gl1_5_glIsQuery(void *_glfuncs, GLuint id)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ return _qglfuncs->glIsQuery(id);
+}
+
+void gl1_5_glDeleteQueries(void *_glfuncs, GLsizei n, const GLuint* ids)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glDeleteQueries(n, ids);
+}
+
+void gl1_5_glGenQueries(void *_glfuncs, GLsizei n, GLuint* ids)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glGenQueries(n, ids);
+}
+
+void gl1_5_glTranslatef(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glTranslatef(x, y, z);
+}
+
+void gl1_5_glTranslated(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glTranslated(x, y, z);
+}
+
+void gl1_5_glScalef(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glScalef(x, y, z);
+}
+
+void gl1_5_glScaled(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glScaled(x, y, z);
+}
+
+void gl1_5_glRotatef(void *_glfuncs, GLfloat angle, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glRotatef(angle, x, y, z);
+}
+
+void gl1_5_glRotated(void *_glfuncs, GLdouble angle, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glRotated(angle, x, y, z);
+}
+
+void gl1_5_glPushMatrix(void *_glfuncs)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glPushMatrix();
+}
+
+void gl1_5_glPopMatrix(void *_glfuncs)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glPopMatrix();
+}
+
+void gl1_5_glOrtho(void *_glfuncs, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glOrtho(left, right, bottom, top, zNear, zFar);
+}
+
+void gl1_5_glMultMatrixd(void *_glfuncs, const GLdouble* m)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glMultMatrixd(m);
+}
+
+void gl1_5_glMultMatrixf(void *_glfuncs, const GLfloat* m)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glMultMatrixf(m);
+}
+
+void gl1_5_glMatrixMode(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glMatrixMode(mode);
+}
+
+void gl1_5_glLoadMatrixd(void *_glfuncs, const GLdouble* m)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glLoadMatrixd(m);
+}
+
+void gl1_5_glLoadMatrixf(void *_glfuncs, const GLfloat* m)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glLoadMatrixf(m);
+}
+
+void gl1_5_glLoadIdentity(void *_glfuncs)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glLoadIdentity();
+}
+
+void gl1_5_glFrustum(void *_glfuncs, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glFrustum(left, right, bottom, top, zNear, zFar);
+}
+
+GLboolean gl1_5_glIsList(void *_glfuncs, GLuint list)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ return _qglfuncs->glIsList(list);
+}
+
+void gl1_5_glGetTexGeniv(void *_glfuncs, GLenum coord, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glGetTexGeniv(coord, pname, params);
+}
+
+void gl1_5_glGetTexGenfv(void *_glfuncs, GLenum coord, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glGetTexGenfv(coord, pname, params);
+}
+
+void gl1_5_glGetTexGendv(void *_glfuncs, GLenum coord, GLenum pname, GLdouble* params)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glGetTexGendv(coord, pname, params);
+}
+
+void gl1_5_glGetTexEnviv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glGetTexEnviv(target, pname, params);
+}
+
+void gl1_5_glGetTexEnvfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glGetTexEnvfv(target, pname, params);
+}
+
+void gl1_5_glGetPolygonStipple(void *_glfuncs, GLubyte* mask)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glGetPolygonStipple(mask);
+}
+
+void gl1_5_glGetPixelMapusv(void *_glfuncs, GLenum glmap, GLushort* values)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glGetPixelMapusv(glmap, values);
+}
+
+void gl1_5_glGetPixelMapuiv(void *_glfuncs, GLenum glmap, GLuint* values)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glGetPixelMapuiv(glmap, values);
+}
+
+void gl1_5_glGetPixelMapfv(void *_glfuncs, GLenum glmap, GLfloat* values)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glGetPixelMapfv(glmap, values);
+}
+
+void gl1_5_glGetMaterialiv(void *_glfuncs, GLenum face, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glGetMaterialiv(face, pname, params);
+}
+
+void gl1_5_glGetMaterialfv(void *_glfuncs, GLenum face, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glGetMaterialfv(face, pname, params);
+}
+
+void gl1_5_glGetMapiv(void *_glfuncs, GLenum target, GLenum query, GLint* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glGetMapiv(target, query, v);
+}
+
+void gl1_5_glGetMapfv(void *_glfuncs, GLenum target, GLenum query, GLfloat* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glGetMapfv(target, query, v);
+}
+
+void gl1_5_glGetMapdv(void *_glfuncs, GLenum target, GLenum query, GLdouble* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glGetMapdv(target, query, v);
+}
+
+void gl1_5_glGetLightiv(void *_glfuncs, GLenum light, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glGetLightiv(light, pname, params);
+}
+
+void gl1_5_glGetLightfv(void *_glfuncs, GLenum light, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glGetLightfv(light, pname, params);
+}
+
+void gl1_5_glGetClipPlane(void *_glfuncs, GLenum plane, GLdouble* equation)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glGetClipPlane(plane, equation);
+}
+
+void gl1_5_glDrawPixels(void *_glfuncs, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glDrawPixels(width, height, format, gltype, pixels);
+}
+
+void gl1_5_glCopyPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum gltype)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glCopyPixels(x, y, width, height, gltype);
+}
+
+void gl1_5_glPixelMapusv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLushort* values)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glPixelMapusv(glmap, mapsize, values);
+}
+
+void gl1_5_glPixelMapuiv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLuint* values)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glPixelMapuiv(glmap, mapsize, values);
+}
+
+void gl1_5_glPixelMapfv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLfloat* values)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glPixelMapfv(glmap, mapsize, values);
+}
+
+void gl1_5_glPixelTransferi(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glPixelTransferi(pname, param);
+}
+
+void gl1_5_glPixelTransferf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glPixelTransferf(pname, param);
+}
+
+void gl1_5_glPixelZoom(void *_glfuncs, GLfloat xfactor, GLfloat yfactor)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glPixelZoom(xfactor, yfactor);
+}
+
+void gl1_5_glAlphaFunc(void *_glfuncs, GLenum glfunc, GLfloat ref)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glAlphaFunc(glfunc, ref);
+}
+
+void gl1_5_glEvalPoint2(void *_glfuncs, GLint i, GLint j)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glEvalPoint2(i, j);
+}
+
+void gl1_5_glEvalMesh2(void *_glfuncs, GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glEvalMesh2(mode, i1, i2, j1, j2);
+}
+
+void gl1_5_glEvalPoint1(void *_glfuncs, GLint i)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glEvalPoint1(i);
+}
+
+void gl1_5_glEvalMesh1(void *_glfuncs, GLenum mode, GLint i1, GLint i2)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glEvalMesh1(mode, i1, i2);
+}
+
+void gl1_5_glEvalCoord2fv(void *_glfuncs, const GLfloat* u)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glEvalCoord2fv(u);
+}
+
+void gl1_5_glEvalCoord2f(void *_glfuncs, GLfloat u, GLfloat v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glEvalCoord2f(u, v);
+}
+
+void gl1_5_glEvalCoord2dv(void *_glfuncs, const GLdouble* u)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glEvalCoord2dv(u);
+}
+
+void gl1_5_glEvalCoord2d(void *_glfuncs, GLdouble u, GLdouble v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glEvalCoord2d(u, v);
+}
+
+void gl1_5_glEvalCoord1fv(void *_glfuncs, const GLfloat* u)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glEvalCoord1fv(u);
+}
+
+void gl1_5_glEvalCoord1f(void *_glfuncs, GLfloat u)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glEvalCoord1f(u);
+}
+
+void gl1_5_glEvalCoord1dv(void *_glfuncs, const GLdouble* u)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glEvalCoord1dv(u);
+}
+
+void gl1_5_glEvalCoord1d(void *_glfuncs, GLdouble u)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glEvalCoord1d(u);
+}
+
+void gl1_5_glMapGrid2f(void *_glfuncs, GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glMapGrid2f(un, u1, u2, vn, v1, v2);
+}
+
+void gl1_5_glMapGrid2d(void *_glfuncs, GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glMapGrid2d(un, u1, u2, vn, v1, v2);
+}
+
+void gl1_5_glMapGrid1f(void *_glfuncs, GLint un, GLfloat u1, GLfloat u2)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glMapGrid1f(un, u1, u2);
+}
+
+void gl1_5_glMapGrid1d(void *_glfuncs, GLint un, GLdouble u1, GLdouble u2)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glMapGrid1d(un, u1, u2);
+}
+
+void gl1_5_glMap2f(void *_glfuncs, GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat* points)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glMap2f(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+void gl1_5_glMap2d(void *_glfuncs, GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble* points)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glMap2d(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+void gl1_5_glMap1f(void *_glfuncs, GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat* points)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glMap1f(target, u1, u2, stride, order, points);
+}
+
+void gl1_5_glMap1d(void *_glfuncs, GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble* points)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glMap1d(target, u1, u2, stride, order, points);
+}
+
+void gl1_5_glPushAttrib(void *_glfuncs, GLbitfield mask)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glPushAttrib(mask);
+}
+
+void gl1_5_glPopAttrib(void *_glfuncs)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glPopAttrib();
+}
+
+void gl1_5_glAccum(void *_glfuncs, GLenum op, GLfloat value)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glAccum(op, value);
+}
+
+void gl1_5_glIndexMask(void *_glfuncs, GLuint mask)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glIndexMask(mask);
+}
+
+void gl1_5_glClearIndex(void *_glfuncs, GLfloat c)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glClearIndex(c);
+}
+
+void gl1_5_glClearAccum(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glClearAccum(red, green, blue, alpha);
+}
+
+void gl1_5_glPushName(void *_glfuncs, GLuint name)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glPushName(name);
+}
+
+void gl1_5_glPopName(void *_glfuncs)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glPopName();
+}
+
+void gl1_5_glPassThrough(void *_glfuncs, GLfloat token)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glPassThrough(token);
+}
+
+void gl1_5_glLoadName(void *_glfuncs, GLuint name)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glLoadName(name);
+}
+
+void gl1_5_glInitNames(void *_glfuncs)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glInitNames();
+}
+
+GLint gl1_5_glRenderMode(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ return _qglfuncs->glRenderMode(mode);
+}
+
+void gl1_5_glSelectBuffer(void *_glfuncs, GLsizei size, GLuint* buffer)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glSelectBuffer(size, buffer);
+}
+
+void gl1_5_glFeedbackBuffer(void *_glfuncs, GLsizei size, GLenum gltype, GLfloat* buffer)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glFeedbackBuffer(size, gltype, buffer);
+}
+
+void gl1_5_glTexGeniv(void *_glfuncs, GLenum coord, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glTexGeniv(coord, pname, params);
+}
+
+void gl1_5_glTexGeni(void *_glfuncs, GLenum coord, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glTexGeni(coord, pname, param);
+}
+
+void gl1_5_glTexGenfv(void *_glfuncs, GLenum coord, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glTexGenfv(coord, pname, params);
+}
+
+void gl1_5_glTexGenf(void *_glfuncs, GLenum coord, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glTexGenf(coord, pname, param);
+}
+
+void gl1_5_glTexGendv(void *_glfuncs, GLenum coord, GLenum pname, const GLdouble* params)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glTexGendv(coord, pname, params);
+}
+
+void gl1_5_glTexGend(void *_glfuncs, GLenum coord, GLenum pname, GLdouble param)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glTexGend(coord, pname, param);
+}
+
+void gl1_5_glTexEnviv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glTexEnviv(target, pname, params);
+}
+
+void gl1_5_glTexEnvi(void *_glfuncs, GLenum target, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glTexEnvi(target, pname, param);
+}
+
+void gl1_5_glTexEnvfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glTexEnvfv(target, pname, params);
+}
+
+void gl1_5_glTexEnvf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glTexEnvf(target, pname, param);
+}
+
+void gl1_5_glShadeModel(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glShadeModel(mode);
+}
+
+void gl1_5_glPolygonStipple(void *_glfuncs, const GLubyte* mask)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glPolygonStipple(mask);
+}
+
+void gl1_5_glMaterialiv(void *_glfuncs, GLenum face, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glMaterialiv(face, pname, params);
+}
+
+void gl1_5_glMateriali(void *_glfuncs, GLenum face, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glMateriali(face, pname, param);
+}
+
+void gl1_5_glMaterialfv(void *_glfuncs, GLenum face, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glMaterialfv(face, pname, params);
+}
+
+void gl1_5_glMaterialf(void *_glfuncs, GLenum face, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glMaterialf(face, pname, param);
+}
+
+void gl1_5_glLineStipple(void *_glfuncs, GLint factor, GLushort pattern)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glLineStipple(factor, pattern);
+}
+
+void gl1_5_glLightModeliv(void *_glfuncs, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glLightModeliv(pname, params);
+}
+
+void gl1_5_glLightModeli(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glLightModeli(pname, param);
+}
+
+void gl1_5_glLightModelfv(void *_glfuncs, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glLightModelfv(pname, params);
+}
+
+void gl1_5_glLightModelf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glLightModelf(pname, param);
+}
+
+void gl1_5_glLightiv(void *_glfuncs, GLenum light, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glLightiv(light, pname, params);
+}
+
+void gl1_5_glLighti(void *_glfuncs, GLenum light, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glLighti(light, pname, param);
+}
+
+void gl1_5_glLightfv(void *_glfuncs, GLenum light, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glLightfv(light, pname, params);
+}
+
+void gl1_5_glLightf(void *_glfuncs, GLenum light, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glLightf(light, pname, param);
+}
+
+void gl1_5_glFogiv(void *_glfuncs, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glFogiv(pname, params);
+}
+
+void gl1_5_glFogi(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glFogi(pname, param);
+}
+
+void gl1_5_glFogfv(void *_glfuncs, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glFogfv(pname, params);
+}
+
+void gl1_5_glFogf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glFogf(pname, param);
+}
+
+void gl1_5_glColorMaterial(void *_glfuncs, GLenum face, GLenum mode)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glColorMaterial(face, mode);
+}
+
+void gl1_5_glClipPlane(void *_glfuncs, GLenum plane, const GLdouble* equation)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glClipPlane(plane, equation);
+}
+
+void gl1_5_glVertex4sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glVertex4sv(v);
+}
+
+void gl1_5_glVertex4s(void *_glfuncs, GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glVertex4s(x, y, z, w);
+}
+
+void gl1_5_glVertex4iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glVertex4iv(v);
+}
+
+void gl1_5_glVertex4i(void *_glfuncs, GLint x, GLint y, GLint z, GLint w)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glVertex4i(x, y, z, w);
+}
+
+void gl1_5_glVertex4fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glVertex4fv(v);
+}
+
+void gl1_5_glVertex4f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glVertex4f(x, y, z, w);
+}
+
+void gl1_5_glVertex4dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glVertex4dv(v);
+}
+
+void gl1_5_glVertex4d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glVertex4d(x, y, z, w);
+}
+
+void gl1_5_glVertex3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glVertex3sv(v);
+}
+
+void gl1_5_glVertex3s(void *_glfuncs, GLshort x, GLshort y, GLshort z)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glVertex3s(x, y, z);
+}
+
+void gl1_5_glVertex3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glVertex3iv(v);
+}
+
+void gl1_5_glVertex3i(void *_glfuncs, GLint x, GLint y, GLint z)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glVertex3i(x, y, z);
+}
+
+void gl1_5_glVertex3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glVertex3fv(v);
+}
+
+void gl1_5_glVertex3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glVertex3f(x, y, z);
+}
+
+void gl1_5_glVertex3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glVertex3dv(v);
+}
+
+void gl1_5_glVertex3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glVertex3d(x, y, z);
+}
+
+void gl1_5_glVertex2sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glVertex2sv(v);
+}
+
+void gl1_5_glVertex2s(void *_glfuncs, GLshort x, GLshort y)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glVertex2s(x, y);
+}
+
+void gl1_5_glVertex2iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glVertex2iv(v);
+}
+
+void gl1_5_glVertex2i(void *_glfuncs, GLint x, GLint y)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glVertex2i(x, y);
+}
+
+void gl1_5_glVertex2fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glVertex2fv(v);
+}
+
+void gl1_5_glVertex2f(void *_glfuncs, GLfloat x, GLfloat y)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glVertex2f(x, y);
+}
+
+void gl1_5_glVertex2dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glVertex2dv(v);
+}
+
+void gl1_5_glVertex2d(void *_glfuncs, GLdouble x, GLdouble y)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glVertex2d(x, y);
+}
+
+void gl1_5_glTexCoord4sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glTexCoord4sv(v);
+}
+
+void gl1_5_glTexCoord4s(void *_glfuncs, GLshort s, GLshort t, GLshort r, GLshort q)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glTexCoord4s(s, t, r, q);
+}
+
+void gl1_5_glTexCoord4iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glTexCoord4iv(v);
+}
+
+void gl1_5_glTexCoord4i(void *_glfuncs, GLint s, GLint t, GLint r, GLint q)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glTexCoord4i(s, t, r, q);
+}
+
+void gl1_5_glTexCoord4fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glTexCoord4fv(v);
+}
+
+void gl1_5_glTexCoord4f(void *_glfuncs, GLfloat s, GLfloat t, GLfloat r, GLfloat q)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glTexCoord4f(s, t, r, q);
+}
+
+void gl1_5_glTexCoord4dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glTexCoord4dv(v);
+}
+
+void gl1_5_glTexCoord4d(void *_glfuncs, GLdouble s, GLdouble t, GLdouble r, GLdouble q)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glTexCoord4d(s, t, r, q);
+}
+
+void gl1_5_glTexCoord3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glTexCoord3sv(v);
+}
+
+void gl1_5_glTexCoord3s(void *_glfuncs, GLshort s, GLshort t, GLshort r)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glTexCoord3s(s, t, r);
+}
+
+void gl1_5_glTexCoord3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glTexCoord3iv(v);
+}
+
+void gl1_5_glTexCoord3i(void *_glfuncs, GLint s, GLint t, GLint r)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glTexCoord3i(s, t, r);
+}
+
+void gl1_5_glTexCoord3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glTexCoord3fv(v);
+}
+
+void gl1_5_glTexCoord3f(void *_glfuncs, GLfloat s, GLfloat t, GLfloat r)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glTexCoord3f(s, t, r);
+}
+
+void gl1_5_glTexCoord3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glTexCoord3dv(v);
+}
+
+void gl1_5_glTexCoord3d(void *_glfuncs, GLdouble s, GLdouble t, GLdouble r)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glTexCoord3d(s, t, r);
+}
+
+void gl1_5_glTexCoord2sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glTexCoord2sv(v);
+}
+
+void gl1_5_glTexCoord2s(void *_glfuncs, GLshort s, GLshort t)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glTexCoord2s(s, t);
+}
+
+void gl1_5_glTexCoord2iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glTexCoord2iv(v);
+}
+
+void gl1_5_glTexCoord2i(void *_glfuncs, GLint s, GLint t)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glTexCoord2i(s, t);
+}
+
+void gl1_5_glTexCoord2fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glTexCoord2fv(v);
+}
+
+void gl1_5_glTexCoord2f(void *_glfuncs, GLfloat s, GLfloat t)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glTexCoord2f(s, t);
+}
+
+void gl1_5_glTexCoord2dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glTexCoord2dv(v);
+}
+
+void gl1_5_glTexCoord2d(void *_glfuncs, GLdouble s, GLdouble t)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glTexCoord2d(s, t);
+}
+
+void gl1_5_glTexCoord1sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glTexCoord1sv(v);
+}
+
+void gl1_5_glTexCoord1s(void *_glfuncs, GLshort s)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glTexCoord1s(s);
+}
+
+void gl1_5_glTexCoord1iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glTexCoord1iv(v);
+}
+
+void gl1_5_glTexCoord1i(void *_glfuncs, GLint s)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glTexCoord1i(s);
+}
+
+void gl1_5_glTexCoord1fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glTexCoord1fv(v);
+}
+
+void gl1_5_glTexCoord1f(void *_glfuncs, GLfloat s)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glTexCoord1f(s);
+}
+
+void gl1_5_glTexCoord1dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glTexCoord1dv(v);
+}
+
+void gl1_5_glTexCoord1d(void *_glfuncs, GLdouble s)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glTexCoord1d(s);
+}
+
+void gl1_5_glRectsv(void *_glfuncs, const GLshort* v1, const GLshort* v2)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glRectsv(v1, v2);
+}
+
+void gl1_5_glRects(void *_glfuncs, GLshort x1, GLshort y1, GLshort x2, GLshort y2)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glRects(x1, y1, x2, y2);
+}
+
+void gl1_5_glRectiv(void *_glfuncs, const GLint* v1, const GLint* v2)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glRectiv(v1, v2);
+}
+
+void gl1_5_glRecti(void *_glfuncs, GLint x1, GLint y1, GLint x2, GLint y2)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glRecti(x1, y1, x2, y2);
+}
+
+void gl1_5_glRectfv(void *_glfuncs, const GLfloat* v1, const GLfloat* v2)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glRectfv(v1, v2);
+}
+
+void gl1_5_glRectf(void *_glfuncs, GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glRectf(x1, y1, x2, y2);
+}
+
+void gl1_5_glRectdv(void *_glfuncs, const GLdouble* v1, const GLdouble* v2)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glRectdv(v1, v2);
+}
+
+void gl1_5_glRectd(void *_glfuncs, GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glRectd(x1, y1, x2, y2);
+}
+
+void gl1_5_glRasterPos4sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glRasterPos4sv(v);
+}
+
+void gl1_5_glRasterPos4s(void *_glfuncs, GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glRasterPos4s(x, y, z, w);
+}
+
+void gl1_5_glRasterPos4iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glRasterPos4iv(v);
+}
+
+void gl1_5_glRasterPos4i(void *_glfuncs, GLint x, GLint y, GLint z, GLint w)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glRasterPos4i(x, y, z, w);
+}
+
+void gl1_5_glRasterPos4fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glRasterPos4fv(v);
+}
+
+void gl1_5_glRasterPos4f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glRasterPos4f(x, y, z, w);
+}
+
+void gl1_5_glRasterPos4dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glRasterPos4dv(v);
+}
+
+void gl1_5_glRasterPos4d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glRasterPos4d(x, y, z, w);
+}
+
+void gl1_5_glRasterPos3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glRasterPos3sv(v);
+}
+
+void gl1_5_glRasterPos3s(void *_glfuncs, GLshort x, GLshort y, GLshort z)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glRasterPos3s(x, y, z);
+}
+
+void gl1_5_glRasterPos3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glRasterPos3iv(v);
+}
+
+void gl1_5_glRasterPos3i(void *_glfuncs, GLint x, GLint y, GLint z)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glRasterPos3i(x, y, z);
+}
+
+void gl1_5_glRasterPos3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glRasterPos3fv(v);
+}
+
+void gl1_5_glRasterPos3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glRasterPos3f(x, y, z);
+}
+
+void gl1_5_glRasterPos3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glRasterPos3dv(v);
+}
+
+void gl1_5_glRasterPos3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glRasterPos3d(x, y, z);
+}
+
+void gl1_5_glRasterPos2sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glRasterPos2sv(v);
+}
+
+void gl1_5_glRasterPos2s(void *_glfuncs, GLshort x, GLshort y)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glRasterPos2s(x, y);
+}
+
+void gl1_5_glRasterPos2iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glRasterPos2iv(v);
+}
+
+void gl1_5_glRasterPos2i(void *_glfuncs, GLint x, GLint y)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glRasterPos2i(x, y);
+}
+
+void gl1_5_glRasterPos2fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glRasterPos2fv(v);
+}
+
+void gl1_5_glRasterPos2f(void *_glfuncs, GLfloat x, GLfloat y)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glRasterPos2f(x, y);
+}
+
+void gl1_5_glRasterPos2dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glRasterPos2dv(v);
+}
+
+void gl1_5_glRasterPos2d(void *_glfuncs, GLdouble x, GLdouble y)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glRasterPos2d(x, y);
+}
+
+void gl1_5_glNormal3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glNormal3sv(v);
+}
+
+void gl1_5_glNormal3s(void *_glfuncs, GLshort nx, GLshort ny, GLshort nz)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glNormal3s(nx, ny, nz);
+}
+
+void gl1_5_glNormal3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glNormal3iv(v);
+}
+
+void gl1_5_glNormal3i(void *_glfuncs, GLint nx, GLint ny, GLint nz)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glNormal3i(nx, ny, nz);
+}
+
+void gl1_5_glNormal3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glNormal3fv(v);
+}
+
+void gl1_5_glNormal3f(void *_glfuncs, GLfloat nx, GLfloat ny, GLfloat nz)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glNormal3f(nx, ny, nz);
+}
+
+void gl1_5_glNormal3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glNormal3dv(v);
+}
+
+void gl1_5_glNormal3d(void *_glfuncs, GLdouble nx, GLdouble ny, GLdouble nz)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glNormal3d(nx, ny, nz);
+}
+
+void gl1_5_glNormal3bv(void *_glfuncs, const GLbyte* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glNormal3bv(v);
+}
+
+void gl1_5_glNormal3b(void *_glfuncs, GLbyte nx, GLbyte ny, GLbyte nz)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glNormal3b(nx, ny, nz);
+}
+
+void gl1_5_glIndexsv(void *_glfuncs, const GLshort* c)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glIndexsv(c);
+}
+
+void gl1_5_glIndexs(void *_glfuncs, GLshort c)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glIndexs(c);
+}
+
+void gl1_5_glIndexiv(void *_glfuncs, const GLint* c)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glIndexiv(c);
+}
+
+void gl1_5_glIndexi(void *_glfuncs, GLint c)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glIndexi(c);
+}
+
+void gl1_5_glIndexfv(void *_glfuncs, const GLfloat* c)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glIndexfv(c);
+}
+
+void gl1_5_glIndexf(void *_glfuncs, GLfloat c)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glIndexf(c);
+}
+
+void gl1_5_glIndexdv(void *_glfuncs, const GLdouble* c)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glIndexdv(c);
+}
+
+void gl1_5_glIndexd(void *_glfuncs, GLdouble c)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glIndexd(c);
+}
+
+void gl1_5_glEnd(void *_glfuncs)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glEnd();
+}
+
+void gl1_5_glEdgeFlagv(void *_glfuncs, const GLboolean* flag)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glEdgeFlagv(flag);
+}
+
+void gl1_5_glEdgeFlag(void *_glfuncs, GLboolean flag)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glEdgeFlag(flag);
+}
+
+void gl1_5_glColor4usv(void *_glfuncs, const GLushort* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glColor4usv(v);
+}
+
+void gl1_5_glColor4us(void *_glfuncs, GLushort red, GLushort green, GLushort blue, GLushort alpha)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glColor4us(red, green, blue, alpha);
+}
+
+void gl1_5_glColor4uiv(void *_glfuncs, const GLuint* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glColor4uiv(v);
+}
+
+void gl1_5_glColor4ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue, GLuint alpha)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glColor4ui(red, green, blue, alpha);
+}
+
+void gl1_5_glColor4ubv(void *_glfuncs, const GLubyte* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glColor4ubv(v);
+}
+
+void gl1_5_glColor4ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glColor4ub(red, green, blue, alpha);
+}
+
+void gl1_5_glColor4sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glColor4sv(v);
+}
+
+void gl1_5_glColor4s(void *_glfuncs, GLshort red, GLshort green, GLshort blue, GLshort alpha)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glColor4s(red, green, blue, alpha);
+}
+
+void gl1_5_glColor4iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glColor4iv(v);
+}
+
+void gl1_5_glColor4i(void *_glfuncs, GLint red, GLint green, GLint blue, GLint alpha)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glColor4i(red, green, blue, alpha);
+}
+
+void gl1_5_glColor4fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glColor4fv(v);
+}
+
+void gl1_5_glColor4f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glColor4f(red, green, blue, alpha);
+}
+
+void gl1_5_glColor4dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glColor4dv(v);
+}
+
+void gl1_5_glColor4d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glColor4d(red, green, blue, alpha);
+}
+
+void gl1_5_glColor4bv(void *_glfuncs, const GLbyte* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glColor4bv(v);
+}
+
+void gl1_5_glColor4b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glColor4b(red, green, blue, alpha);
+}
+
+void gl1_5_glColor3usv(void *_glfuncs, const GLushort* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glColor3usv(v);
+}
+
+void gl1_5_glColor3us(void *_glfuncs, GLushort red, GLushort green, GLushort blue)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glColor3us(red, green, blue);
+}
+
+void gl1_5_glColor3uiv(void *_glfuncs, const GLuint* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glColor3uiv(v);
+}
+
+void gl1_5_glColor3ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glColor3ui(red, green, blue);
+}
+
+void gl1_5_glColor3ubv(void *_glfuncs, const GLubyte* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glColor3ubv(v);
+}
+
+void gl1_5_glColor3ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glColor3ub(red, green, blue);
+}
+
+void gl1_5_glColor3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glColor3sv(v);
+}
+
+void gl1_5_glColor3s(void *_glfuncs, GLshort red, GLshort green, GLshort blue)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glColor3s(red, green, blue);
+}
+
+void gl1_5_glColor3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glColor3iv(v);
+}
+
+void gl1_5_glColor3i(void *_glfuncs, GLint red, GLint green, GLint blue)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glColor3i(red, green, blue);
+}
+
+void gl1_5_glColor3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glColor3fv(v);
+}
+
+void gl1_5_glColor3f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glColor3f(red, green, blue);
+}
+
+void gl1_5_glColor3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glColor3dv(v);
+}
+
+void gl1_5_glColor3d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glColor3d(red, green, blue);
+}
+
+void gl1_5_glColor3bv(void *_glfuncs, const GLbyte* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glColor3bv(v);
+}
+
+void gl1_5_glColor3b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glColor3b(red, green, blue);
+}
+
+void gl1_5_glBitmap(void *_glfuncs, GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte* bitmap)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glBitmap(width, height, xorig, yorig, xmove, ymove, bitmap);
+}
+
+void gl1_5_glBegin(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glBegin(mode);
+}
+
+void gl1_5_glListBase(void *_glfuncs, GLuint base)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glListBase(base);
+}
+
+GLuint gl1_5_glGenLists(void *_glfuncs, GLsizei range_)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ return _qglfuncs->glGenLists(range_);
+}
+
+void gl1_5_glDeleteLists(void *_glfuncs, GLuint list, GLsizei range_)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glDeleteLists(list, range_);
+}
+
+void gl1_5_glCallLists(void *_glfuncs, GLsizei n, GLenum gltype, const GLvoid* lists)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glCallLists(n, gltype, lists);
+}
+
+void gl1_5_glCallList(void *_glfuncs, GLuint list)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glCallList(list);
+}
+
+void gl1_5_glEndList(void *_glfuncs)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glEndList();
+}
+
+void gl1_5_glNewList(void *_glfuncs, GLuint list, GLenum mode)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glNewList(list, mode);
+}
+
+void gl1_5_glPushClientAttrib(void *_glfuncs, GLbitfield mask)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glPushClientAttrib(mask);
+}
+
+void gl1_5_glPopClientAttrib(void *_glfuncs)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glPopClientAttrib();
+}
+
+void gl1_5_glPrioritizeTextures(void *_glfuncs, GLsizei n, const GLuint* textures, const GLfloat* priorities)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glPrioritizeTextures(n, textures, priorities);
+}
+
+GLboolean gl1_5_glAreTexturesResident(void *_glfuncs, GLsizei n, const GLuint* textures, GLboolean* residences)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ return _qglfuncs->glAreTexturesResident(n, textures, residences);
+}
+
+void gl1_5_glVertexPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glVertexPointer(size, gltype, stride, pointer);
+}
+
+void gl1_5_glTexCoordPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glTexCoordPointer(size, gltype, stride, pointer);
+}
+
+void gl1_5_glNormalPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glNormalPointer(gltype, stride, pointer);
+}
+
+void gl1_5_glInterleavedArrays(void *_glfuncs, GLenum format, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glInterleavedArrays(format, stride, pointer);
+}
+
+void gl1_5_glIndexPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glIndexPointer(gltype, stride, pointer);
+}
+
+void gl1_5_glEnableClientState(void *_glfuncs, GLenum array)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glEnableClientState(array);
+}
+
+void gl1_5_glEdgeFlagPointer(void *_glfuncs, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glEdgeFlagPointer(stride, pointer);
+}
+
+void gl1_5_glDisableClientState(void *_glfuncs, GLenum array)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glDisableClientState(array);
+}
+
+void gl1_5_glColorPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glColorPointer(size, gltype, stride, pointer);
+}
+
+void gl1_5_glArrayElement(void *_glfuncs, GLint i)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glArrayElement(i);
+}
+
+void gl1_5_glResetMinmax(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glResetMinmax(target);
+}
+
+void gl1_5_glResetHistogram(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glResetHistogram(target);
+}
+
+void gl1_5_glMinmax(void *_glfuncs, GLenum target, GLenum internalFormat, GLboolean sink)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glMinmax(target, internalFormat, sink);
+}
+
+void gl1_5_glHistogram(void *_glfuncs, GLenum target, GLsizei width, GLenum internalFormat, GLboolean sink)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glHistogram(target, width, internalFormat, sink);
+}
+
+void gl1_5_glGetMinmaxParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glGetMinmaxParameteriv(target, pname, params);
+}
+
+void gl1_5_glGetMinmaxParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glGetMinmaxParameterfv(target, pname, params);
+}
+
+void gl1_5_glGetMinmax(void *_glfuncs, GLenum target, GLboolean reset, GLenum format, GLenum gltype, GLvoid* values)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glGetMinmax(target, reset, format, gltype, values);
+}
+
+void gl1_5_glGetHistogramParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glGetHistogramParameteriv(target, pname, params);
+}
+
+void gl1_5_glGetHistogramParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glGetHistogramParameterfv(target, pname, params);
+}
+
+void gl1_5_glGetHistogram(void *_glfuncs, GLenum target, GLboolean reset, GLenum format, GLenum gltype, GLvoid* values)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glGetHistogram(target, reset, format, gltype, values);
+}
+
+void gl1_5_glSeparableFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* row, const GLvoid* column)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glSeparableFilter2D(target, internalFormat, width, height, format, gltype, row, column);
+}
+
+void gl1_5_glGetSeparableFilter(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* row, GLvoid* column, GLvoid* span)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glGetSeparableFilter(target, format, gltype, row, column, span);
+}
+
+void gl1_5_glGetConvolutionParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glGetConvolutionParameteriv(target, pname, params);
+}
+
+void gl1_5_glGetConvolutionParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glGetConvolutionParameterfv(target, pname, params);
+}
+
+void gl1_5_glGetConvolutionFilter(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* image)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glGetConvolutionFilter(target, format, gltype, image);
+}
+
+void gl1_5_glCopyConvolutionFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glCopyConvolutionFilter2D(target, internalFormat, x, y, width, height);
+}
+
+void gl1_5_glCopyConvolutionFilter1D(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glCopyConvolutionFilter1D(target, internalFormat, x, y, width);
+}
+
+void gl1_5_glConvolutionParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glConvolutionParameteriv(target, pname, params);
+}
+
+void gl1_5_glConvolutionParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint params)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glConvolutionParameteri(target, pname, params);
+}
+
+void gl1_5_glConvolutionParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glConvolutionParameterfv(target, pname, params);
+}
+
+void gl1_5_glConvolutionParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat params)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glConvolutionParameterf(target, pname, params);
+}
+
+void gl1_5_glConvolutionFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* image)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glConvolutionFilter2D(target, internalFormat, width, height, format, gltype, image);
+}
+
+void gl1_5_glConvolutionFilter1D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLenum format, GLenum gltype, const GLvoid* image)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glConvolutionFilter1D(target, internalFormat, width, format, gltype, image);
+}
+
+void gl1_5_glCopyColorSubTable(void *_glfuncs, GLenum target, GLsizei start, GLint x, GLint y, GLsizei width)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glCopyColorSubTable(target, start, x, y, width);
+}
+
+void gl1_5_glColorSubTable(void *_glfuncs, GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum gltype, const GLvoid* data)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glColorSubTable(target, start, count, format, gltype, data);
+}
+
+void gl1_5_glGetColorTableParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glGetColorTableParameteriv(target, pname, params);
+}
+
+void gl1_5_glGetColorTableParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glGetColorTableParameterfv(target, pname, params);
+}
+
+void gl1_5_glGetColorTable(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* table)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glGetColorTable(target, format, gltype, table);
+}
+
+void gl1_5_glCopyColorTable(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glCopyColorTable(target, internalFormat, x, y, width);
+}
+
+void gl1_5_glColorTableParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glColorTableParameteriv(target, pname, params);
+}
+
+void gl1_5_glColorTableParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glColorTableParameterfv(target, pname, params);
+}
+
+void gl1_5_glColorTable(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLenum format, GLenum gltype, const GLvoid* table)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glColorTable(target, internalFormat, width, format, gltype, table);
+}
+
+void gl1_5_glMultTransposeMatrixd(void *_glfuncs, const GLdouble* m)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glMultTransposeMatrixd(m);
+}
+
+void gl1_5_glMultTransposeMatrixf(void *_glfuncs, const GLfloat* m)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glMultTransposeMatrixf(m);
+}
+
+void gl1_5_glLoadTransposeMatrixd(void *_glfuncs, const GLdouble* m)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glLoadTransposeMatrixd(m);
+}
+
+void gl1_5_glLoadTransposeMatrixf(void *_glfuncs, const GLfloat* m)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glLoadTransposeMatrixf(m);
+}
+
+void gl1_5_glMultiTexCoord4sv(void *_glfuncs, GLenum target, const GLshort* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4sv(target, v);
+}
+
+void gl1_5_glMultiTexCoord4s(void *_glfuncs, GLenum target, GLshort s, GLshort t, GLshort r, GLshort q)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4s(target, s, t, r, q);
+}
+
+void gl1_5_glMultiTexCoord4iv(void *_glfuncs, GLenum target, const GLint* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4iv(target, v);
+}
+
+void gl1_5_glMultiTexCoord4i(void *_glfuncs, GLenum target, GLint s, GLint t, GLint r, GLint q)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4i(target, s, t, r, q);
+}
+
+void gl1_5_glMultiTexCoord4fv(void *_glfuncs, GLenum target, const GLfloat* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4fv(target, v);
+}
+
+void gl1_5_glMultiTexCoord4f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4f(target, s, t, r, q);
+}
+
+void gl1_5_glMultiTexCoord4dv(void *_glfuncs, GLenum target, const GLdouble* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4dv(target, v);
+}
+
+void gl1_5_glMultiTexCoord4d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4d(target, s, t, r, q);
+}
+
+void gl1_5_glMultiTexCoord3sv(void *_glfuncs, GLenum target, const GLshort* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3sv(target, v);
+}
+
+void gl1_5_glMultiTexCoord3s(void *_glfuncs, GLenum target, GLshort s, GLshort t, GLshort r)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3s(target, s, t, r);
+}
+
+void gl1_5_glMultiTexCoord3iv(void *_glfuncs, GLenum target, const GLint* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3iv(target, v);
+}
+
+void gl1_5_glMultiTexCoord3i(void *_glfuncs, GLenum target, GLint s, GLint t, GLint r)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3i(target, s, t, r);
+}
+
+void gl1_5_glMultiTexCoord3fv(void *_glfuncs, GLenum target, const GLfloat* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3fv(target, v);
+}
+
+void gl1_5_glMultiTexCoord3f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t, GLfloat r)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3f(target, s, t, r);
+}
+
+void gl1_5_glMultiTexCoord3dv(void *_glfuncs, GLenum target, const GLdouble* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3dv(target, v);
+}
+
+void gl1_5_glMultiTexCoord3d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t, GLdouble r)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3d(target, s, t, r);
+}
+
+void gl1_5_glMultiTexCoord2sv(void *_glfuncs, GLenum target, const GLshort* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2sv(target, v);
+}
+
+void gl1_5_glMultiTexCoord2s(void *_glfuncs, GLenum target, GLshort s, GLshort t)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2s(target, s, t);
+}
+
+void gl1_5_glMultiTexCoord2iv(void *_glfuncs, GLenum target, const GLint* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2iv(target, v);
+}
+
+void gl1_5_glMultiTexCoord2i(void *_glfuncs, GLenum target, GLint s, GLint t)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2i(target, s, t);
+}
+
+void gl1_5_glMultiTexCoord2fv(void *_glfuncs, GLenum target, const GLfloat* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2fv(target, v);
+}
+
+void gl1_5_glMultiTexCoord2f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2f(target, s, t);
+}
+
+void gl1_5_glMultiTexCoord2dv(void *_glfuncs, GLenum target, const GLdouble* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2dv(target, v);
+}
+
+void gl1_5_glMultiTexCoord2d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2d(target, s, t);
+}
+
+void gl1_5_glMultiTexCoord1sv(void *_glfuncs, GLenum target, const GLshort* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1sv(target, v);
+}
+
+void gl1_5_glMultiTexCoord1s(void *_glfuncs, GLenum target, GLshort s)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1s(target, s);
+}
+
+void gl1_5_glMultiTexCoord1iv(void *_glfuncs, GLenum target, const GLint* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1iv(target, v);
+}
+
+void gl1_5_glMultiTexCoord1i(void *_glfuncs, GLenum target, GLint s)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1i(target, s);
+}
+
+void gl1_5_glMultiTexCoord1fv(void *_glfuncs, GLenum target, const GLfloat* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1fv(target, v);
+}
+
+void gl1_5_glMultiTexCoord1f(void *_glfuncs, GLenum target, GLfloat s)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1f(target, s);
+}
+
+void gl1_5_glMultiTexCoord1dv(void *_glfuncs, GLenum target, const GLdouble* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1dv(target, v);
+}
+
+void gl1_5_glMultiTexCoord1d(void *_glfuncs, GLenum target, GLdouble s)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1d(target, s);
+}
+
+void gl1_5_glClientActiveTexture(void *_glfuncs, GLenum texture)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glClientActiveTexture(texture);
+}
+
+void gl1_5_glWindowPos3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glWindowPos3sv(v);
+}
+
+void gl1_5_glWindowPos3s(void *_glfuncs, GLshort x, GLshort y, GLshort z)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glWindowPos3s(x, y, z);
+}
+
+void gl1_5_glWindowPos3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glWindowPos3iv(v);
+}
+
+void gl1_5_glWindowPos3i(void *_glfuncs, GLint x, GLint y, GLint z)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glWindowPos3i(x, y, z);
+}
+
+void gl1_5_glWindowPos3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glWindowPos3fv(v);
+}
+
+void gl1_5_glWindowPos3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glWindowPos3f(x, y, z);
+}
+
+void gl1_5_glWindowPos3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glWindowPos3dv(v);
+}
+
+void gl1_5_glWindowPos3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glWindowPos3d(x, y, z);
+}
+
+void gl1_5_glWindowPos2sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glWindowPos2sv(v);
+}
+
+void gl1_5_glWindowPos2s(void *_glfuncs, GLshort x, GLshort y)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glWindowPos2s(x, y);
+}
+
+void gl1_5_glWindowPos2iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glWindowPos2iv(v);
+}
+
+void gl1_5_glWindowPos2i(void *_glfuncs, GLint x, GLint y)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glWindowPos2i(x, y);
+}
+
+void gl1_5_glWindowPos2fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glWindowPos2fv(v);
+}
+
+void gl1_5_glWindowPos2f(void *_glfuncs, GLfloat x, GLfloat y)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glWindowPos2f(x, y);
+}
+
+void gl1_5_glWindowPos2dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glWindowPos2dv(v);
+}
+
+void gl1_5_glWindowPos2d(void *_glfuncs, GLdouble x, GLdouble y)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glWindowPos2d(x, y);
+}
+
+void gl1_5_glSecondaryColorPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glSecondaryColorPointer(size, gltype, stride, pointer);
+}
+
+void gl1_5_glSecondaryColor3usv(void *_glfuncs, const GLushort* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3usv(v);
+}
+
+void gl1_5_glSecondaryColor3us(void *_glfuncs, GLushort red, GLushort green, GLushort blue)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3us(red, green, blue);
+}
+
+void gl1_5_glSecondaryColor3uiv(void *_glfuncs, const GLuint* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3uiv(v);
+}
+
+void gl1_5_glSecondaryColor3ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3ui(red, green, blue);
+}
+
+void gl1_5_glSecondaryColor3ubv(void *_glfuncs, const GLubyte* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3ubv(v);
+}
+
+void gl1_5_glSecondaryColor3ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3ub(red, green, blue);
+}
+
+void gl1_5_glSecondaryColor3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3sv(v);
+}
+
+void gl1_5_glSecondaryColor3s(void *_glfuncs, GLshort red, GLshort green, GLshort blue)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3s(red, green, blue);
+}
+
+void gl1_5_glSecondaryColor3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3iv(v);
+}
+
+void gl1_5_glSecondaryColor3i(void *_glfuncs, GLint red, GLint green, GLint blue)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3i(red, green, blue);
+}
+
+void gl1_5_glSecondaryColor3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3fv(v);
+}
+
+void gl1_5_glSecondaryColor3f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3f(red, green, blue);
+}
+
+void gl1_5_glSecondaryColor3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3dv(v);
+}
+
+void gl1_5_glSecondaryColor3d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3d(red, green, blue);
+}
+
+void gl1_5_glSecondaryColor3bv(void *_glfuncs, const GLbyte* v)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3bv(v);
+}
+
+void gl1_5_glSecondaryColor3b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3b(red, green, blue);
+}
+
+void gl1_5_glFogCoordPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glFogCoordPointer(gltype, stride, pointer);
+}
+
+void gl1_5_glFogCoorddv(void *_glfuncs, const GLdouble* coord)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glFogCoorddv(coord);
+}
+
+void gl1_5_glFogCoordd(void *_glfuncs, GLdouble coord)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glFogCoordd(coord);
+}
+
+void gl1_5_glFogCoordfv(void *_glfuncs, const GLfloat* coord)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glFogCoordfv(coord);
+}
+
+void gl1_5_glFogCoordf(void *_glfuncs, GLfloat coord)
+{
+ QOpenGLFunctions_1_5* _qglfuncs = reinterpret_cast<QOpenGLFunctions_1_5*>(_glfuncs);
+ _qglfuncs->glFogCoordf(coord);
+}
+
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/1.5/funcs.h b/Godeps/_workspace/src/github.com/obscuren/qml/gl/1.5/funcs.h
new file mode 100644
index 000000000..d971f2dc3
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/1.5/funcs.h
@@ -0,0 +1,521 @@
+
+// ** file automatically generated by glgen -- do not edit manually **
+
+#ifndef __cplusplus
+#include <inttypes.h>
+#include <stddef.h>
+typedef unsigned int GLenum;
+typedef unsigned char GLboolean;
+typedef unsigned int GLbitfield;
+typedef void GLvoid;
+typedef char GLchar;
+typedef signed char GLbyte; /* 1-byte signed */
+typedef short GLshort; /* 2-byte signed */
+typedef int GLint; /* 4-byte signed */
+typedef unsigned char GLubyte; /* 1-byte unsigned */
+typedef unsigned short GLushort; /* 2-byte unsigned */
+typedef unsigned int GLuint; /* 4-byte unsigned */
+typedef int GLsizei; /* 4-byte signed */
+typedef float GLfloat; /* single precision float */
+typedef float GLclampf; /* single precision float in [0,1] */
+typedef double GLdouble; /* double precision float */
+typedef double GLclampd; /* double precision float in [0,1] */
+typedef int64_t GLint64;
+typedef uint64_t GLuint64;
+typedef ptrdiff_t GLintptr;
+typedef ptrdiff_t GLsizeiptr;
+typedef ptrdiff_t GLintptrARB;
+typedef ptrdiff_t GLsizeiptrARB;
+typedef struct __GLsync *GLsync;
+#endif
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+void *gl1_5_funcs();
+
+void gl1_5_glViewport(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl1_5_glDepthRange(void *_glfuncs, GLdouble nearVal, GLdouble farVal);
+GLboolean gl1_5_glIsEnabled(void *_glfuncs, GLenum cap);
+void gl1_5_glGetTexLevelParameteriv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLint* params);
+void gl1_5_glGetTexLevelParameterfv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLfloat* params);
+void gl1_5_glGetTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl1_5_glGetTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl1_5_glGetTexImage(void *_glfuncs, GLenum target, GLint level, GLenum format, GLenum gltype, GLvoid* pixels);
+void gl1_5_glGetIntegerv(void *_glfuncs, GLenum pname, GLint* params);
+void gl1_5_glGetFloatv(void *_glfuncs, GLenum pname, GLfloat* params);
+GLenum gl1_5_glGetError(void *_glfuncs);
+void gl1_5_glGetDoublev(void *_glfuncs, GLenum pname, GLdouble* params);
+void gl1_5_glGetBooleanv(void *_glfuncs, GLenum pname, GLboolean* params);
+void gl1_5_glReadPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum gltype, GLvoid* pixels);
+void gl1_5_glReadBuffer(void *_glfuncs, GLenum mode);
+void gl1_5_glPixelStorei(void *_glfuncs, GLenum pname, GLint param);
+void gl1_5_glPixelStoref(void *_glfuncs, GLenum pname, GLfloat param);
+void gl1_5_glDepthFunc(void *_glfuncs, GLenum glfunc);
+void gl1_5_glStencilOp(void *_glfuncs, GLenum fail, GLenum zfail, GLenum zpass);
+void gl1_5_glStencilFunc(void *_glfuncs, GLenum glfunc, GLint ref, GLuint mask);
+void gl1_5_glLogicOp(void *_glfuncs, GLenum opcode);
+void gl1_5_glBlendFunc(void *_glfuncs, GLenum sfactor, GLenum dfactor);
+void gl1_5_glFlush(void *_glfuncs);
+void gl1_5_glFinish(void *_glfuncs);
+void gl1_5_glEnable(void *_glfuncs, GLenum cap);
+void gl1_5_glDisable(void *_glfuncs, GLenum cap);
+void gl1_5_glDepthMask(void *_glfuncs, GLboolean flag);
+void gl1_5_glColorMask(void *_glfuncs, GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha);
+void gl1_5_glStencilMask(void *_glfuncs, GLuint mask);
+void gl1_5_glClearDepth(void *_glfuncs, GLdouble depth);
+void gl1_5_glClearStencil(void *_glfuncs, GLint s);
+void gl1_5_glClearColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl1_5_glClear(void *_glfuncs, GLbitfield mask);
+void gl1_5_glDrawBuffer(void *_glfuncs, GLenum mode);
+void gl1_5_glTexImage2D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl1_5_glTexImage1D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl1_5_glTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl1_5_glTexParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint param);
+void gl1_5_glTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl1_5_glTexParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param);
+void gl1_5_glScissor(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl1_5_glPolygonMode(void *_glfuncs, GLenum face, GLenum mode);
+void gl1_5_glPointSize(void *_glfuncs, GLfloat size);
+void gl1_5_glLineWidth(void *_glfuncs, GLfloat width);
+void gl1_5_glHint(void *_glfuncs, GLenum target, GLenum mode);
+void gl1_5_glFrontFace(void *_glfuncs, GLenum mode);
+void gl1_5_glCullFace(void *_glfuncs, GLenum mode);
+void gl1_5_glIndexubv(void *_glfuncs, const GLubyte* c);
+void gl1_5_glIndexub(void *_glfuncs, GLubyte c);
+GLboolean gl1_5_glIsTexture(void *_glfuncs, GLuint texture);
+void gl1_5_glGenTextures(void *_glfuncs, GLsizei n, GLuint* textures);
+void gl1_5_glDeleteTextures(void *_glfuncs, GLsizei n, const GLuint* textures);
+void gl1_5_glBindTexture(void *_glfuncs, GLenum target, GLuint texture);
+void gl1_5_glTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl1_5_glTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl1_5_glCopyTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl1_5_glCopyTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width);
+void gl1_5_glCopyTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border);
+void gl1_5_glCopyTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLint border);
+void gl1_5_glPolygonOffset(void *_glfuncs, GLfloat factor, GLfloat units);
+void gl1_5_glDrawElements(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices);
+void gl1_5_glDrawArrays(void *_glfuncs, GLenum mode, GLint first, GLsizei count);
+void gl1_5_glCopyTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl1_5_glTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl1_5_glTexImage3D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl1_5_glDrawRangeElements(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices);
+void gl1_5_glBlendEquation(void *_glfuncs, GLenum mode);
+void gl1_5_glBlendColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl1_5_glGetCompressedTexImage(void *_glfuncs, GLenum target, GLint level, GLvoid* img);
+void gl1_5_glCompressedTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid* data);
+void gl1_5_glCompressedTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid* data);
+void gl1_5_glCompressedTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid* data);
+void gl1_5_glCompressedTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid* data);
+void gl1_5_glCompressedTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid* data);
+void gl1_5_glCompressedTexImage3D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid* data);
+void gl1_5_glSampleCoverage(void *_glfuncs, GLfloat value, GLboolean invert);
+void gl1_5_glActiveTexture(void *_glfuncs, GLenum texture);
+void gl1_5_glPointParameteriv(void *_glfuncs, GLenum pname, const GLint* params);
+void gl1_5_glPointParameteri(void *_glfuncs, GLenum pname, GLint param);
+void gl1_5_glPointParameterfv(void *_glfuncs, GLenum pname, const GLfloat* params);
+void gl1_5_glPointParameterf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl1_5_glMultiDrawArrays(void *_glfuncs, GLenum mode, const GLint* first, const GLsizei* count, GLsizei drawcount);
+void gl1_5_glBlendFuncSeparate(void *_glfuncs, GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha);
+void gl1_5_glGetBufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+GLboolean gl1_5_glUnmapBuffer(void *_glfuncs, GLenum target);
+void gl1_5_glGetBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, GLvoid* data);
+void gl1_5_glBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid* data);
+void gl1_5_glBufferData(void *_glfuncs, GLenum target, GLsizeiptr size, const GLvoid* data, GLenum usage);
+GLboolean gl1_5_glIsBuffer(void *_glfuncs, GLuint buffer);
+void gl1_5_glGenBuffers(void *_glfuncs, GLsizei n, GLuint* buffers);
+void gl1_5_glDeleteBuffers(void *_glfuncs, GLsizei n, const GLuint* buffers);
+void gl1_5_glBindBuffer(void *_glfuncs, GLenum target, GLuint buffer);
+void gl1_5_glGetQueryObjectuiv(void *_glfuncs, GLuint id, GLenum pname, GLuint* params);
+void gl1_5_glGetQueryObjectiv(void *_glfuncs, GLuint id, GLenum pname, GLint* params);
+void gl1_5_glGetQueryiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl1_5_glEndQuery(void *_glfuncs, GLenum target);
+void gl1_5_glBeginQuery(void *_glfuncs, GLenum target, GLuint id);
+GLboolean gl1_5_glIsQuery(void *_glfuncs, GLuint id);
+void gl1_5_glDeleteQueries(void *_glfuncs, GLsizei n, const GLuint* ids);
+void gl1_5_glGenQueries(void *_glfuncs, GLsizei n, GLuint* ids);
+void gl1_5_glTranslatef(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl1_5_glTranslated(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl1_5_glScalef(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl1_5_glScaled(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl1_5_glRotatef(void *_glfuncs, GLfloat angle, GLfloat x, GLfloat y, GLfloat z);
+void gl1_5_glRotated(void *_glfuncs, GLdouble angle, GLdouble x, GLdouble y, GLdouble z);
+void gl1_5_glPushMatrix(void *_glfuncs);
+void gl1_5_glPopMatrix(void *_glfuncs);
+void gl1_5_glOrtho(void *_glfuncs, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+void gl1_5_glMultMatrixd(void *_glfuncs, const GLdouble* m);
+void gl1_5_glMultMatrixf(void *_glfuncs, const GLfloat* m);
+void gl1_5_glMatrixMode(void *_glfuncs, GLenum mode);
+void gl1_5_glLoadMatrixd(void *_glfuncs, const GLdouble* m);
+void gl1_5_glLoadMatrixf(void *_glfuncs, const GLfloat* m);
+void gl1_5_glLoadIdentity(void *_glfuncs);
+void gl1_5_glFrustum(void *_glfuncs, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+GLboolean gl1_5_glIsList(void *_glfuncs, GLuint list);
+void gl1_5_glGetTexGeniv(void *_glfuncs, GLenum coord, GLenum pname, GLint* params);
+void gl1_5_glGetTexGenfv(void *_glfuncs, GLenum coord, GLenum pname, GLfloat* params);
+void gl1_5_glGetTexGendv(void *_glfuncs, GLenum coord, GLenum pname, GLdouble* params);
+void gl1_5_glGetTexEnviv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl1_5_glGetTexEnvfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl1_5_glGetPolygonStipple(void *_glfuncs, GLubyte* mask);
+void gl1_5_glGetPixelMapusv(void *_glfuncs, GLenum glmap, GLushort* values);
+void gl1_5_glGetPixelMapuiv(void *_glfuncs, GLenum glmap, GLuint* values);
+void gl1_5_glGetPixelMapfv(void *_glfuncs, GLenum glmap, GLfloat* values);
+void gl1_5_glGetMaterialiv(void *_glfuncs, GLenum face, GLenum pname, GLint* params);
+void gl1_5_glGetMaterialfv(void *_glfuncs, GLenum face, GLenum pname, GLfloat* params);
+void gl1_5_glGetMapiv(void *_glfuncs, GLenum target, GLenum query, GLint* v);
+void gl1_5_glGetMapfv(void *_glfuncs, GLenum target, GLenum query, GLfloat* v);
+void gl1_5_glGetMapdv(void *_glfuncs, GLenum target, GLenum query, GLdouble* v);
+void gl1_5_glGetLightiv(void *_glfuncs, GLenum light, GLenum pname, GLint* params);
+void gl1_5_glGetLightfv(void *_glfuncs, GLenum light, GLenum pname, GLfloat* params);
+void gl1_5_glGetClipPlane(void *_glfuncs, GLenum plane, GLdouble* equation);
+void gl1_5_glDrawPixels(void *_glfuncs, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl1_5_glCopyPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum gltype);
+void gl1_5_glPixelMapusv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLushort* values);
+void gl1_5_glPixelMapuiv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLuint* values);
+void gl1_5_glPixelMapfv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLfloat* values);
+void gl1_5_glPixelTransferi(void *_glfuncs, GLenum pname, GLint param);
+void gl1_5_glPixelTransferf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl1_5_glPixelZoom(void *_glfuncs, GLfloat xfactor, GLfloat yfactor);
+void gl1_5_glAlphaFunc(void *_glfuncs, GLenum glfunc, GLfloat ref);
+void gl1_5_glEvalPoint2(void *_glfuncs, GLint i, GLint j);
+void gl1_5_glEvalMesh2(void *_glfuncs, GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2);
+void gl1_5_glEvalPoint1(void *_glfuncs, GLint i);
+void gl1_5_glEvalMesh1(void *_glfuncs, GLenum mode, GLint i1, GLint i2);
+void gl1_5_glEvalCoord2fv(void *_glfuncs, const GLfloat* u);
+void gl1_5_glEvalCoord2f(void *_glfuncs, GLfloat u, GLfloat v);
+void gl1_5_glEvalCoord2dv(void *_glfuncs, const GLdouble* u);
+void gl1_5_glEvalCoord2d(void *_glfuncs, GLdouble u, GLdouble v);
+void gl1_5_glEvalCoord1fv(void *_glfuncs, const GLfloat* u);
+void gl1_5_glEvalCoord1f(void *_glfuncs, GLfloat u);
+void gl1_5_glEvalCoord1dv(void *_glfuncs, const GLdouble* u);
+void gl1_5_glEvalCoord1d(void *_glfuncs, GLdouble u);
+void gl1_5_glMapGrid2f(void *_glfuncs, GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2);
+void gl1_5_glMapGrid2d(void *_glfuncs, GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2);
+void gl1_5_glMapGrid1f(void *_glfuncs, GLint un, GLfloat u1, GLfloat u2);
+void gl1_5_glMapGrid1d(void *_glfuncs, GLint un, GLdouble u1, GLdouble u2);
+void gl1_5_glMap2f(void *_glfuncs, GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat* points);
+void gl1_5_glMap2d(void *_glfuncs, GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble* points);
+void gl1_5_glMap1f(void *_glfuncs, GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat* points);
+void gl1_5_glMap1d(void *_glfuncs, GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble* points);
+void gl1_5_glPushAttrib(void *_glfuncs, GLbitfield mask);
+void gl1_5_glPopAttrib(void *_glfuncs);
+void gl1_5_glAccum(void *_glfuncs, GLenum op, GLfloat value);
+void gl1_5_glIndexMask(void *_glfuncs, GLuint mask);
+void gl1_5_glClearIndex(void *_glfuncs, GLfloat c);
+void gl1_5_glClearAccum(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl1_5_glPushName(void *_glfuncs, GLuint name);
+void gl1_5_glPopName(void *_glfuncs);
+void gl1_5_glPassThrough(void *_glfuncs, GLfloat token);
+void gl1_5_glLoadName(void *_glfuncs, GLuint name);
+void gl1_5_glInitNames(void *_glfuncs);
+GLint gl1_5_glRenderMode(void *_glfuncs, GLenum mode);
+void gl1_5_glSelectBuffer(void *_glfuncs, GLsizei size, GLuint* buffer);
+void gl1_5_glFeedbackBuffer(void *_glfuncs, GLsizei size, GLenum gltype, GLfloat* buffer);
+void gl1_5_glTexGeniv(void *_glfuncs, GLenum coord, GLenum pname, const GLint* params);
+void gl1_5_glTexGeni(void *_glfuncs, GLenum coord, GLenum pname, GLint param);
+void gl1_5_glTexGenfv(void *_glfuncs, GLenum coord, GLenum pname, const GLfloat* params);
+void gl1_5_glTexGenf(void *_glfuncs, GLenum coord, GLenum pname, GLfloat param);
+void gl1_5_glTexGendv(void *_glfuncs, GLenum coord, GLenum pname, const GLdouble* params);
+void gl1_5_glTexGend(void *_glfuncs, GLenum coord, GLenum pname, GLdouble param);
+void gl1_5_glTexEnviv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl1_5_glTexEnvi(void *_glfuncs, GLenum target, GLenum pname, GLint param);
+void gl1_5_glTexEnvfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl1_5_glTexEnvf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param);
+void gl1_5_glShadeModel(void *_glfuncs, GLenum mode);
+void gl1_5_glPolygonStipple(void *_glfuncs, const GLubyte* mask);
+void gl1_5_glMaterialiv(void *_glfuncs, GLenum face, GLenum pname, const GLint* params);
+void gl1_5_glMateriali(void *_glfuncs, GLenum face, GLenum pname, GLint param);
+void gl1_5_glMaterialfv(void *_glfuncs, GLenum face, GLenum pname, const GLfloat* params);
+void gl1_5_glMaterialf(void *_glfuncs, GLenum face, GLenum pname, GLfloat param);
+void gl1_5_glLineStipple(void *_glfuncs, GLint factor, GLushort pattern);
+void gl1_5_glLightModeliv(void *_glfuncs, GLenum pname, const GLint* params);
+void gl1_5_glLightModeli(void *_glfuncs, GLenum pname, GLint param);
+void gl1_5_glLightModelfv(void *_glfuncs, GLenum pname, const GLfloat* params);
+void gl1_5_glLightModelf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl1_5_glLightiv(void *_glfuncs, GLenum light, GLenum pname, const GLint* params);
+void gl1_5_glLighti(void *_glfuncs, GLenum light, GLenum pname, GLint param);
+void gl1_5_glLightfv(void *_glfuncs, GLenum light, GLenum pname, const GLfloat* params);
+void gl1_5_glLightf(void *_glfuncs, GLenum light, GLenum pname, GLfloat param);
+void gl1_5_glFogiv(void *_glfuncs, GLenum pname, const GLint* params);
+void gl1_5_glFogi(void *_glfuncs, GLenum pname, GLint param);
+void gl1_5_glFogfv(void *_glfuncs, GLenum pname, const GLfloat* params);
+void gl1_5_glFogf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl1_5_glColorMaterial(void *_glfuncs, GLenum face, GLenum mode);
+void gl1_5_glClipPlane(void *_glfuncs, GLenum plane, const GLdouble* equation);
+void gl1_5_glVertex4sv(void *_glfuncs, const GLshort* v);
+void gl1_5_glVertex4s(void *_glfuncs, GLshort x, GLshort y, GLshort z, GLshort w);
+void gl1_5_glVertex4iv(void *_glfuncs, const GLint* v);
+void gl1_5_glVertex4i(void *_glfuncs, GLint x, GLint y, GLint z, GLint w);
+void gl1_5_glVertex4fv(void *_glfuncs, const GLfloat* v);
+void gl1_5_glVertex4f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+void gl1_5_glVertex4dv(void *_glfuncs, const GLdouble* v);
+void gl1_5_glVertex4d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+void gl1_5_glVertex3sv(void *_glfuncs, const GLshort* v);
+void gl1_5_glVertex3s(void *_glfuncs, GLshort x, GLshort y, GLshort z);
+void gl1_5_glVertex3iv(void *_glfuncs, const GLint* v);
+void gl1_5_glVertex3i(void *_glfuncs, GLint x, GLint y, GLint z);
+void gl1_5_glVertex3fv(void *_glfuncs, const GLfloat* v);
+void gl1_5_glVertex3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl1_5_glVertex3dv(void *_glfuncs, const GLdouble* v);
+void gl1_5_glVertex3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl1_5_glVertex2sv(void *_glfuncs, const GLshort* v);
+void gl1_5_glVertex2s(void *_glfuncs, GLshort x, GLshort y);
+void gl1_5_glVertex2iv(void *_glfuncs, const GLint* v);
+void gl1_5_glVertex2i(void *_glfuncs, GLint x, GLint y);
+void gl1_5_glVertex2fv(void *_glfuncs, const GLfloat* v);
+void gl1_5_glVertex2f(void *_glfuncs, GLfloat x, GLfloat y);
+void gl1_5_glVertex2dv(void *_glfuncs, const GLdouble* v);
+void gl1_5_glVertex2d(void *_glfuncs, GLdouble x, GLdouble y);
+void gl1_5_glTexCoord4sv(void *_glfuncs, const GLshort* v);
+void gl1_5_glTexCoord4s(void *_glfuncs, GLshort s, GLshort t, GLshort r, GLshort q);
+void gl1_5_glTexCoord4iv(void *_glfuncs, const GLint* v);
+void gl1_5_glTexCoord4i(void *_glfuncs, GLint s, GLint t, GLint r, GLint q);
+void gl1_5_glTexCoord4fv(void *_glfuncs, const GLfloat* v);
+void gl1_5_glTexCoord4f(void *_glfuncs, GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+void gl1_5_glTexCoord4dv(void *_glfuncs, const GLdouble* v);
+void gl1_5_glTexCoord4d(void *_glfuncs, GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+void gl1_5_glTexCoord3sv(void *_glfuncs, const GLshort* v);
+void gl1_5_glTexCoord3s(void *_glfuncs, GLshort s, GLshort t, GLshort r);
+void gl1_5_glTexCoord3iv(void *_glfuncs, const GLint* v);
+void gl1_5_glTexCoord3i(void *_glfuncs, GLint s, GLint t, GLint r);
+void gl1_5_glTexCoord3fv(void *_glfuncs, const GLfloat* v);
+void gl1_5_glTexCoord3f(void *_glfuncs, GLfloat s, GLfloat t, GLfloat r);
+void gl1_5_glTexCoord3dv(void *_glfuncs, const GLdouble* v);
+void gl1_5_glTexCoord3d(void *_glfuncs, GLdouble s, GLdouble t, GLdouble r);
+void gl1_5_glTexCoord2sv(void *_glfuncs, const GLshort* v);
+void gl1_5_glTexCoord2s(void *_glfuncs, GLshort s, GLshort t);
+void gl1_5_glTexCoord2iv(void *_glfuncs, const GLint* v);
+void gl1_5_glTexCoord2i(void *_glfuncs, GLint s, GLint t);
+void gl1_5_glTexCoord2fv(void *_glfuncs, const GLfloat* v);
+void gl1_5_glTexCoord2f(void *_glfuncs, GLfloat s, GLfloat t);
+void gl1_5_glTexCoord2dv(void *_glfuncs, const GLdouble* v);
+void gl1_5_glTexCoord2d(void *_glfuncs, GLdouble s, GLdouble t);
+void gl1_5_glTexCoord1sv(void *_glfuncs, const GLshort* v);
+void gl1_5_glTexCoord1s(void *_glfuncs, GLshort s);
+void gl1_5_glTexCoord1iv(void *_glfuncs, const GLint* v);
+void gl1_5_glTexCoord1i(void *_glfuncs, GLint s);
+void gl1_5_glTexCoord1fv(void *_glfuncs, const GLfloat* v);
+void gl1_5_glTexCoord1f(void *_glfuncs, GLfloat s);
+void gl1_5_glTexCoord1dv(void *_glfuncs, const GLdouble* v);
+void gl1_5_glTexCoord1d(void *_glfuncs, GLdouble s);
+void gl1_5_glRectsv(void *_glfuncs, const GLshort* v1, const GLshort* v2);
+void gl1_5_glRects(void *_glfuncs, GLshort x1, GLshort y1, GLshort x2, GLshort y2);
+void gl1_5_glRectiv(void *_glfuncs, const GLint* v1, const GLint* v2);
+void gl1_5_glRecti(void *_glfuncs, GLint x1, GLint y1, GLint x2, GLint y2);
+void gl1_5_glRectfv(void *_glfuncs, const GLfloat* v1, const GLfloat* v2);
+void gl1_5_glRectf(void *_glfuncs, GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2);
+void gl1_5_glRectdv(void *_glfuncs, const GLdouble* v1, const GLdouble* v2);
+void gl1_5_glRectd(void *_glfuncs, GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2);
+void gl1_5_glRasterPos4sv(void *_glfuncs, const GLshort* v);
+void gl1_5_glRasterPos4s(void *_glfuncs, GLshort x, GLshort y, GLshort z, GLshort w);
+void gl1_5_glRasterPos4iv(void *_glfuncs, const GLint* v);
+void gl1_5_glRasterPos4i(void *_glfuncs, GLint x, GLint y, GLint z, GLint w);
+void gl1_5_glRasterPos4fv(void *_glfuncs, const GLfloat* v);
+void gl1_5_glRasterPos4f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+void gl1_5_glRasterPos4dv(void *_glfuncs, const GLdouble* v);
+void gl1_5_glRasterPos4d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+void gl1_5_glRasterPos3sv(void *_glfuncs, const GLshort* v);
+void gl1_5_glRasterPos3s(void *_glfuncs, GLshort x, GLshort y, GLshort z);
+void gl1_5_glRasterPos3iv(void *_glfuncs, const GLint* v);
+void gl1_5_glRasterPos3i(void *_glfuncs, GLint x, GLint y, GLint z);
+void gl1_5_glRasterPos3fv(void *_glfuncs, const GLfloat* v);
+void gl1_5_glRasterPos3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl1_5_glRasterPos3dv(void *_glfuncs, const GLdouble* v);
+void gl1_5_glRasterPos3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl1_5_glRasterPos2sv(void *_glfuncs, const GLshort* v);
+void gl1_5_glRasterPos2s(void *_glfuncs, GLshort x, GLshort y);
+void gl1_5_glRasterPos2iv(void *_glfuncs, const GLint* v);
+void gl1_5_glRasterPos2i(void *_glfuncs, GLint x, GLint y);
+void gl1_5_glRasterPos2fv(void *_glfuncs, const GLfloat* v);
+void gl1_5_glRasterPos2f(void *_glfuncs, GLfloat x, GLfloat y);
+void gl1_5_glRasterPos2dv(void *_glfuncs, const GLdouble* v);
+void gl1_5_glRasterPos2d(void *_glfuncs, GLdouble x, GLdouble y);
+void gl1_5_glNormal3sv(void *_glfuncs, const GLshort* v);
+void gl1_5_glNormal3s(void *_glfuncs, GLshort nx, GLshort ny, GLshort nz);
+void gl1_5_glNormal3iv(void *_glfuncs, const GLint* v);
+void gl1_5_glNormal3i(void *_glfuncs, GLint nx, GLint ny, GLint nz);
+void gl1_5_glNormal3fv(void *_glfuncs, const GLfloat* v);
+void gl1_5_glNormal3f(void *_glfuncs, GLfloat nx, GLfloat ny, GLfloat nz);
+void gl1_5_glNormal3dv(void *_glfuncs, const GLdouble* v);
+void gl1_5_glNormal3d(void *_glfuncs, GLdouble nx, GLdouble ny, GLdouble nz);
+void gl1_5_glNormal3bv(void *_glfuncs, const GLbyte* v);
+void gl1_5_glNormal3b(void *_glfuncs, GLbyte nx, GLbyte ny, GLbyte nz);
+void gl1_5_glIndexsv(void *_glfuncs, const GLshort* c);
+void gl1_5_glIndexs(void *_glfuncs, GLshort c);
+void gl1_5_glIndexiv(void *_glfuncs, const GLint* c);
+void gl1_5_glIndexi(void *_glfuncs, GLint c);
+void gl1_5_glIndexfv(void *_glfuncs, const GLfloat* c);
+void gl1_5_glIndexf(void *_glfuncs, GLfloat c);
+void gl1_5_glIndexdv(void *_glfuncs, const GLdouble* c);
+void gl1_5_glIndexd(void *_glfuncs, GLdouble c);
+void gl1_5_glEnd(void *_glfuncs);
+void gl1_5_glEdgeFlagv(void *_glfuncs, const GLboolean* flag);
+void gl1_5_glEdgeFlag(void *_glfuncs, GLboolean flag);
+void gl1_5_glColor4usv(void *_glfuncs, const GLushort* v);
+void gl1_5_glColor4us(void *_glfuncs, GLushort red, GLushort green, GLushort blue, GLushort alpha);
+void gl1_5_glColor4uiv(void *_glfuncs, const GLuint* v);
+void gl1_5_glColor4ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue, GLuint alpha);
+void gl1_5_glColor4ubv(void *_glfuncs, const GLubyte* v);
+void gl1_5_glColor4ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha);
+void gl1_5_glColor4sv(void *_glfuncs, const GLshort* v);
+void gl1_5_glColor4s(void *_glfuncs, GLshort red, GLshort green, GLshort blue, GLshort alpha);
+void gl1_5_glColor4iv(void *_glfuncs, const GLint* v);
+void gl1_5_glColor4i(void *_glfuncs, GLint red, GLint green, GLint blue, GLint alpha);
+void gl1_5_glColor4fv(void *_glfuncs, const GLfloat* v);
+void gl1_5_glColor4f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl1_5_glColor4dv(void *_glfuncs, const GLdouble* v);
+void gl1_5_glColor4d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha);
+void gl1_5_glColor4bv(void *_glfuncs, const GLbyte* v);
+void gl1_5_glColor4b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha);
+void gl1_5_glColor3usv(void *_glfuncs, const GLushort* v);
+void gl1_5_glColor3us(void *_glfuncs, GLushort red, GLushort green, GLushort blue);
+void gl1_5_glColor3uiv(void *_glfuncs, const GLuint* v);
+void gl1_5_glColor3ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue);
+void gl1_5_glColor3ubv(void *_glfuncs, const GLubyte* v);
+void gl1_5_glColor3ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue);
+void gl1_5_glColor3sv(void *_glfuncs, const GLshort* v);
+void gl1_5_glColor3s(void *_glfuncs, GLshort red, GLshort green, GLshort blue);
+void gl1_5_glColor3iv(void *_glfuncs, const GLint* v);
+void gl1_5_glColor3i(void *_glfuncs, GLint red, GLint green, GLint blue);
+void gl1_5_glColor3fv(void *_glfuncs, const GLfloat* v);
+void gl1_5_glColor3f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue);
+void gl1_5_glColor3dv(void *_glfuncs, const GLdouble* v);
+void gl1_5_glColor3d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue);
+void gl1_5_glColor3bv(void *_glfuncs, const GLbyte* v);
+void gl1_5_glColor3b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue);
+void gl1_5_glBitmap(void *_glfuncs, GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte* bitmap);
+void gl1_5_glBegin(void *_glfuncs, GLenum mode);
+void gl1_5_glListBase(void *_glfuncs, GLuint base);
+GLuint gl1_5_glGenLists(void *_glfuncs, GLsizei range_);
+void gl1_5_glDeleteLists(void *_glfuncs, GLuint list, GLsizei range_);
+void gl1_5_glCallLists(void *_glfuncs, GLsizei n, GLenum gltype, const GLvoid* lists);
+void gl1_5_glCallList(void *_glfuncs, GLuint list);
+void gl1_5_glEndList(void *_glfuncs);
+void gl1_5_glNewList(void *_glfuncs, GLuint list, GLenum mode);
+void gl1_5_glPushClientAttrib(void *_glfuncs, GLbitfield mask);
+void gl1_5_glPopClientAttrib(void *_glfuncs);
+void gl1_5_glPrioritizeTextures(void *_glfuncs, GLsizei n, const GLuint* textures, const GLfloat* priorities);
+GLboolean gl1_5_glAreTexturesResident(void *_glfuncs, GLsizei n, const GLuint* textures, GLboolean* residences);
+void gl1_5_glVertexPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl1_5_glTexCoordPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl1_5_glNormalPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl1_5_glInterleavedArrays(void *_glfuncs, GLenum format, GLsizei stride, const GLvoid* pointer);
+void gl1_5_glIndexPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl1_5_glEnableClientState(void *_glfuncs, GLenum array);
+void gl1_5_glEdgeFlagPointer(void *_glfuncs, GLsizei stride, const GLvoid* pointer);
+void gl1_5_glDisableClientState(void *_glfuncs, GLenum array);
+void gl1_5_glColorPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl1_5_glArrayElement(void *_glfuncs, GLint i);
+void gl1_5_glResetMinmax(void *_glfuncs, GLenum target);
+void gl1_5_glResetHistogram(void *_glfuncs, GLenum target);
+void gl1_5_glMinmax(void *_glfuncs, GLenum target, GLenum internalFormat, GLboolean sink);
+void gl1_5_glHistogram(void *_glfuncs, GLenum target, GLsizei width, GLenum internalFormat, GLboolean sink);
+void gl1_5_glGetMinmaxParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl1_5_glGetMinmaxParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl1_5_glGetMinmax(void *_glfuncs, GLenum target, GLboolean reset, GLenum format, GLenum gltype, GLvoid* values);
+void gl1_5_glGetHistogramParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl1_5_glGetHistogramParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl1_5_glGetHistogram(void *_glfuncs, GLenum target, GLboolean reset, GLenum format, GLenum gltype, GLvoid* values);
+void gl1_5_glSeparableFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* row, const GLvoid* column);
+void gl1_5_glGetSeparableFilter(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* row, GLvoid* column, GLvoid* span);
+void gl1_5_glGetConvolutionParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl1_5_glGetConvolutionParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl1_5_glGetConvolutionFilter(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* image);
+void gl1_5_glCopyConvolutionFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl1_5_glCopyConvolutionFilter1D(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width);
+void gl1_5_glConvolutionParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl1_5_glConvolutionParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint params);
+void gl1_5_glConvolutionParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl1_5_glConvolutionParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat params);
+void gl1_5_glConvolutionFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* image);
+void gl1_5_glConvolutionFilter1D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLenum format, GLenum gltype, const GLvoid* image);
+void gl1_5_glCopyColorSubTable(void *_glfuncs, GLenum target, GLsizei start, GLint x, GLint y, GLsizei width);
+void gl1_5_glColorSubTable(void *_glfuncs, GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum gltype, const GLvoid* data);
+void gl1_5_glGetColorTableParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl1_5_glGetColorTableParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl1_5_glGetColorTable(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* table);
+void gl1_5_glCopyColorTable(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width);
+void gl1_5_glColorTableParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl1_5_glColorTableParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl1_5_glColorTable(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLenum format, GLenum gltype, const GLvoid* table);
+void gl1_5_glMultTransposeMatrixd(void *_glfuncs, const GLdouble* m);
+void gl1_5_glMultTransposeMatrixf(void *_glfuncs, const GLfloat* m);
+void gl1_5_glLoadTransposeMatrixd(void *_glfuncs, const GLdouble* m);
+void gl1_5_glLoadTransposeMatrixf(void *_glfuncs, const GLfloat* m);
+void gl1_5_glMultiTexCoord4sv(void *_glfuncs, GLenum target, const GLshort* v);
+void gl1_5_glMultiTexCoord4s(void *_glfuncs, GLenum target, GLshort s, GLshort t, GLshort r, GLshort q);
+void gl1_5_glMultiTexCoord4iv(void *_glfuncs, GLenum target, const GLint* v);
+void gl1_5_glMultiTexCoord4i(void *_glfuncs, GLenum target, GLint s, GLint t, GLint r, GLint q);
+void gl1_5_glMultiTexCoord4fv(void *_glfuncs, GLenum target, const GLfloat* v);
+void gl1_5_glMultiTexCoord4f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+void gl1_5_glMultiTexCoord4dv(void *_glfuncs, GLenum target, const GLdouble* v);
+void gl1_5_glMultiTexCoord4d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+void gl1_5_glMultiTexCoord3sv(void *_glfuncs, GLenum target, const GLshort* v);
+void gl1_5_glMultiTexCoord3s(void *_glfuncs, GLenum target, GLshort s, GLshort t, GLshort r);
+void gl1_5_glMultiTexCoord3iv(void *_glfuncs, GLenum target, const GLint* v);
+void gl1_5_glMultiTexCoord3i(void *_glfuncs, GLenum target, GLint s, GLint t, GLint r);
+void gl1_5_glMultiTexCoord3fv(void *_glfuncs, GLenum target, const GLfloat* v);
+void gl1_5_glMultiTexCoord3f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t, GLfloat r);
+void gl1_5_glMultiTexCoord3dv(void *_glfuncs, GLenum target, const GLdouble* v);
+void gl1_5_glMultiTexCoord3d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t, GLdouble r);
+void gl1_5_glMultiTexCoord2sv(void *_glfuncs, GLenum target, const GLshort* v);
+void gl1_5_glMultiTexCoord2s(void *_glfuncs, GLenum target, GLshort s, GLshort t);
+void gl1_5_glMultiTexCoord2iv(void *_glfuncs, GLenum target, const GLint* v);
+void gl1_5_glMultiTexCoord2i(void *_glfuncs, GLenum target, GLint s, GLint t);
+void gl1_5_glMultiTexCoord2fv(void *_glfuncs, GLenum target, const GLfloat* v);
+void gl1_5_glMultiTexCoord2f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t);
+void gl1_5_glMultiTexCoord2dv(void *_glfuncs, GLenum target, const GLdouble* v);
+void gl1_5_glMultiTexCoord2d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t);
+void gl1_5_glMultiTexCoord1sv(void *_glfuncs, GLenum target, const GLshort* v);
+void gl1_5_glMultiTexCoord1s(void *_glfuncs, GLenum target, GLshort s);
+void gl1_5_glMultiTexCoord1iv(void *_glfuncs, GLenum target, const GLint* v);
+void gl1_5_glMultiTexCoord1i(void *_glfuncs, GLenum target, GLint s);
+void gl1_5_glMultiTexCoord1fv(void *_glfuncs, GLenum target, const GLfloat* v);
+void gl1_5_glMultiTexCoord1f(void *_glfuncs, GLenum target, GLfloat s);
+void gl1_5_glMultiTexCoord1dv(void *_glfuncs, GLenum target, const GLdouble* v);
+void gl1_5_glMultiTexCoord1d(void *_glfuncs, GLenum target, GLdouble s);
+void gl1_5_glClientActiveTexture(void *_glfuncs, GLenum texture);
+void gl1_5_glWindowPos3sv(void *_glfuncs, const GLshort* v);
+void gl1_5_glWindowPos3s(void *_glfuncs, GLshort x, GLshort y, GLshort z);
+void gl1_5_glWindowPos3iv(void *_glfuncs, const GLint* v);
+void gl1_5_glWindowPos3i(void *_glfuncs, GLint x, GLint y, GLint z);
+void gl1_5_glWindowPos3fv(void *_glfuncs, const GLfloat* v);
+void gl1_5_glWindowPos3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl1_5_glWindowPos3dv(void *_glfuncs, const GLdouble* v);
+void gl1_5_glWindowPos3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl1_5_glWindowPos2sv(void *_glfuncs, const GLshort* v);
+void gl1_5_glWindowPos2s(void *_glfuncs, GLshort x, GLshort y);
+void gl1_5_glWindowPos2iv(void *_glfuncs, const GLint* v);
+void gl1_5_glWindowPos2i(void *_glfuncs, GLint x, GLint y);
+void gl1_5_glWindowPos2fv(void *_glfuncs, const GLfloat* v);
+void gl1_5_glWindowPos2f(void *_glfuncs, GLfloat x, GLfloat y);
+void gl1_5_glWindowPos2dv(void *_glfuncs, const GLdouble* v);
+void gl1_5_glWindowPos2d(void *_glfuncs, GLdouble x, GLdouble y);
+void gl1_5_glSecondaryColorPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl1_5_glSecondaryColor3usv(void *_glfuncs, const GLushort* v);
+void gl1_5_glSecondaryColor3us(void *_glfuncs, GLushort red, GLushort green, GLushort blue);
+void gl1_5_glSecondaryColor3uiv(void *_glfuncs, const GLuint* v);
+void gl1_5_glSecondaryColor3ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue);
+void gl1_5_glSecondaryColor3ubv(void *_glfuncs, const GLubyte* v);
+void gl1_5_glSecondaryColor3ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue);
+void gl1_5_glSecondaryColor3sv(void *_glfuncs, const GLshort* v);
+void gl1_5_glSecondaryColor3s(void *_glfuncs, GLshort red, GLshort green, GLshort blue);
+void gl1_5_glSecondaryColor3iv(void *_glfuncs, const GLint* v);
+void gl1_5_glSecondaryColor3i(void *_glfuncs, GLint red, GLint green, GLint blue);
+void gl1_5_glSecondaryColor3fv(void *_glfuncs, const GLfloat* v);
+void gl1_5_glSecondaryColor3f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue);
+void gl1_5_glSecondaryColor3dv(void *_glfuncs, const GLdouble* v);
+void gl1_5_glSecondaryColor3d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue);
+void gl1_5_glSecondaryColor3bv(void *_glfuncs, const GLbyte* v);
+void gl1_5_glSecondaryColor3b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue);
+void gl1_5_glFogCoordPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl1_5_glFogCoorddv(void *_glfuncs, const GLdouble* coord);
+void gl1_5_glFogCoordd(void *_glfuncs, GLdouble coord);
+void gl1_5_glFogCoordfv(void *_glfuncs, const GLfloat* coord);
+void gl1_5_glFogCoordf(void *_glfuncs, GLfloat coord);
+
+
+#ifdef __cplusplus
+} // extern "C"
+#endif
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/1.5/gl.go b/Godeps/_workspace/src/github.com/obscuren/qml/gl/1.5/gl.go
new file mode 100644
index 000000000..463f66f40
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/1.5/gl.go
@@ -0,0 +1,4237 @@
+// ** file automatically generated by glgen -- do not edit manually **
+
+package GL
+
+// #cgo CXXFLAGS: -std=c++0x -pedantic-errors -Wall -fno-strict-aliasing
+// #cgo LDFLAGS: -lstdc++
+// #cgo pkg-config: Qt5Core Qt5OpenGL
+//
+// #include "funcs.h"
+//
+// void free(void*);
+//
+import "C"
+
+import (
+ "fmt"
+ "reflect"
+ "unsafe"
+
+ "gopkg.in/qml.v1/gl/glbase"
+)
+
+// API returns a value that offers methods matching the OpenGL version 1.5 API.
+//
+// The returned API must not be used after the provided OpenGL context becomes invalid.
+func API(context glbase.Contexter) *GL {
+ gl := &GL{}
+ gl.funcs = C.gl1_5_funcs()
+ if gl.funcs == nil {
+ panic(fmt.Errorf("OpenGL version 1.5 is not available"))
+ }
+ return gl
+}
+
+// GL implements the OpenGL version 1.5 API. Values of this
+// type must be created via the API function, and it must not be used after
+// the associated OpenGL context becomes invalid.
+type GL struct {
+ funcs unsafe.Pointer
+}
+
+const (
+ FALSE = 0
+ TRUE = 1
+ NONE = 0
+
+ BYTE = 0x1400
+ UNSIGNED_BYTE = 0x1401
+ SHORT = 0x1402
+ UNSIGNED_SHORT = 0x1403
+ INT = 0x1404
+ UNSIGNED_INT = 0x1405
+ FLOAT = 0x1406
+ N2_BYTES = 0x1407
+ N3_BYTES = 0x1408
+ N4_BYTES = 0x1409
+ DOUBLE = 0x140A
+
+ ACCUM = 0x0100
+ LOAD = 0x0101
+ RETURN = 0x0102
+ MULT = 0x0103
+ ADD = 0x0104
+
+ ACCUM_BUFFER_BIT = 0x00000200
+ ALL_ATTRIB_BITS = 0xFFFFFFFF
+ COLOR_BUFFER_BIT = 0x00004000
+ CURRENT_BIT = 0x00000001
+ DEPTH_BUFFER_BIT = 0x00000100
+ ENABLE_BIT = 0x00002000
+ EVAL_BIT = 0x00010000
+ FOG_BIT = 0x00000080
+ HINT_BIT = 0x00008000
+ LIGHTING_BIT = 0x00000040
+ LINE_BIT = 0x00000004
+ LIST_BIT = 0x00020000
+ MULTISAMPLE_BIT = 0x20000000
+ PIXEL_MODE_BIT = 0x00000020
+ POINT_BIT = 0x00000002
+ POLYGON_BIT = 0x00000008
+ POLYGON_STIPPLE_BIT = 0x00000010
+ SCISSOR_BIT = 0x00080000
+ STENCIL_BUFFER_BIT = 0x00000400
+ TEXTURE_BIT = 0x00040000
+ TRANSFORM_BIT = 0x00001000
+ VIEWPORT_BIT = 0x00000800
+
+ ALWAYS = 0x0207
+ EQUAL = 0x0202
+ GEQUAL = 0x0206
+ GREATER = 0x0204
+ LEQUAL = 0x0203
+ LESS = 0x0201
+ NEVER = 0x0200
+ NOTEQUAL = 0x0205
+
+ LOGIC_OP = 0x0BF1
+
+ DST_ALPHA = 0x0304
+ ONE = 1
+ ONE_MINUS_DST_ALPHA = 0x0305
+ ONE_MINUS_SRC_ALPHA = 0x0303
+ ONE_MINUS_SRC_COLOR = 0x0301
+ SRC_ALPHA = 0x0302
+ SRC_COLOR = 0x0300
+ ZERO = 0
+
+ DST_COLOR = 0x0306
+ ONE_MINUS_DST_COLOR = 0x0307
+ SRC_ALPHA_SATURATE = 0x0308
+
+ CLIENT_ALL_ATTRIB_BITS = 0xFFFFFFFF
+ CLIENT_PIXEL_STORE_BIT = 0x00000001
+ CLIENT_VERTEX_ARRAY_BIT = 0x00000002
+
+ CLIP_PLANE0 = 0x3000
+ CLIP_PLANE1 = 0x3001
+ CLIP_PLANE2 = 0x3002
+ CLIP_PLANE3 = 0x3003
+ CLIP_PLANE4 = 0x3004
+ CLIP_PLANE5 = 0x3005
+
+ BACK = 0x0405
+ FRONT = 0x0404
+ FRONT_AND_BACK = 0x0408
+
+ AMBIENT = 0x1200
+ AMBIENT_AND_DIFFUSE = 0x1602
+ DIFFUSE = 0x1201
+ EMISSION = 0x1600
+ SPECULAR = 0x1202
+
+ AUX0 = 0x0409
+ AUX1 = 0x040A
+ AUX2 = 0x040B
+ AUX3 = 0x040C
+ BACK_LEFT = 0x0402
+ BACK_RIGHT = 0x0403
+ FRONT_LEFT = 0x0400
+ FRONT_RIGHT = 0x0401
+ LEFT = 0x0406
+ RIGHT = 0x0407
+
+ ALPHA_TEST = 0x0BC0
+ AUTO_NORMAL = 0x0D80
+ BLEND = 0x0BE2
+ COLOR_ARRAY = 0x8076
+ COLOR_LOGIC_OP = 0x0BF2
+ COLOR_MATERIAL = 0x0B57
+ CULL_FACE = 0x0B44
+ DEPTH_TEST = 0x0B71
+ DITHER = 0x0BD0
+ EDGE_FLAG_ARRAY = 0x8079
+ FOG = 0x0B60
+ INDEX_ARRAY = 0x8077
+ INDEX_LOGIC_OP = 0x0BF1
+ LIGHT0 = 0x4000
+ LIGHT1 = 0x4001
+ LIGHT2 = 0x4002
+ LIGHT3 = 0x4003
+ LIGHT4 = 0x4004
+ LIGHT5 = 0x4005
+ LIGHT6 = 0x4006
+ LIGHT7 = 0x4007
+ LIGHTING = 0x0B50
+ LINE_SMOOTH = 0x0B20
+ LINE_STIPPLE = 0x0B24
+ MAP1_COLOR_4 = 0x0D90
+ MAP1_INDEX = 0x0D91
+ MAP1_NORMAL = 0x0D92
+ MAP1_TEXTURE_COORD_1 = 0x0D93
+ MAP1_TEXTURE_COORD_2 = 0x0D94
+ MAP1_TEXTURE_COORD_3 = 0x0D95
+ MAP1_TEXTURE_COORD_4 = 0x0D96
+ MAP1_VERTEX_3 = 0x0D97
+ MAP1_VERTEX_4 = 0x0D98
+ MAP2_COLOR_4 = 0x0DB0
+ MAP2_INDEX = 0x0DB1
+ MAP2_NORMAL = 0x0DB2
+ MAP2_TEXTURE_COORD_1 = 0x0DB3
+ MAP2_TEXTURE_COORD_2 = 0x0DB4
+ MAP2_TEXTURE_COORD_3 = 0x0DB5
+ MAP2_TEXTURE_COORD_4 = 0x0DB6
+ MAP2_VERTEX_3 = 0x0DB7
+ MAP2_VERTEX_4 = 0x0DB8
+ NORMALIZE = 0x0BA1
+ NORMAL_ARRAY = 0x8075
+ POINT_SMOOTH = 0x0B10
+ POLYGON_OFFSET_FILL = 0x8037
+ POLYGON_OFFSET_LINE = 0x2A02
+ POLYGON_OFFSET_POINT = 0x2A01
+ POLYGON_SMOOTH = 0x0B41
+ POLYGON_STIPPLE = 0x0B42
+ SCISSOR_TEST = 0x0C11
+ STENCIL_TEST = 0x0B90
+ TEXTURE_1D = 0x0DE0
+ TEXTURE_2D = 0x0DE1
+ TEXTURE_COORD_ARRAY = 0x8078
+ TEXTURE_GEN_Q = 0x0C63
+ TEXTURE_GEN_R = 0x0C62
+ TEXTURE_GEN_S = 0x0C60
+ TEXTURE_GEN_T = 0x0C61
+ VERTEX_ARRAY = 0x8074
+
+ INVALID_ENUM = 0x0500
+ INVALID_OPERATION = 0x0502
+ INVALID_VALUE = 0x0501
+ NO_ERROR = 0
+ OUT_OF_MEMORY = 0x0505
+ STACK_OVERFLOW = 0x0503
+ STACK_UNDERFLOW = 0x0504
+
+ N2D = 0x0600
+ N3D = 0x0601
+ N3D_COLOR = 0x0602
+ N3D_COLOR_TEXTURE = 0x0603
+ N4D_COLOR_TEXTURE = 0x0604
+
+ BITMAP_TOKEN = 0x0704
+ COPY_PIXEL_TOKEN = 0x0706
+ DRAW_PIXEL_TOKEN = 0x0705
+ LINE_RESET_TOKEN = 0x0707
+ LINE_TOKEN = 0x0702
+ PASS_THROUGH_TOKEN = 0x0700
+ POINT_TOKEN = 0x0701
+ POLYGON_TOKEN = 0x0703
+
+ EXP = 0x0800
+ EXP2 = 0x0801
+ LINEAR = 0x2601
+
+ FOG_COLOR = 0x0B66
+ FOG_DENSITY = 0x0B62
+ FOG_END = 0x0B64
+ FOG_INDEX = 0x0B61
+ FOG_MODE = 0x0B65
+ FOG_START = 0x0B63
+
+ CCW = 0x0901
+ CW = 0x0900
+
+ COEFF = 0x0A00
+ DOMAIN = 0x0A02
+ ORDER = 0x0A01
+
+ PIXEL_MAP_A_TO_A = 0x0C79
+ PIXEL_MAP_B_TO_B = 0x0C78
+ PIXEL_MAP_G_TO_G = 0x0C77
+ PIXEL_MAP_I_TO_A = 0x0C75
+ PIXEL_MAP_I_TO_B = 0x0C74
+ PIXEL_MAP_I_TO_G = 0x0C73
+ PIXEL_MAP_I_TO_I = 0x0C70
+ PIXEL_MAP_I_TO_R = 0x0C72
+ PIXEL_MAP_R_TO_R = 0x0C76
+ PIXEL_MAP_S_TO_S = 0x0C71
+
+ ACCUM_ALPHA_BITS = 0x0D5B
+ ACCUM_BLUE_BITS = 0x0D5A
+ ACCUM_CLEAR_VALUE = 0x0B80
+ ACCUM_GREEN_BITS = 0x0D59
+ ACCUM_RED_BITS = 0x0D58
+ ALIASED_LINE_WIDTH_RANGE = 0x846E
+ ALIASED_POINT_SIZE_RANGE = 0x846D
+ ALPHA_BIAS = 0x0D1D
+ ALPHA_BITS = 0x0D55
+ ALPHA_SCALE = 0x0D1C
+ ALPHA_TEST_FUNC = 0x0BC1
+ ALPHA_TEST_REF = 0x0BC2
+ ATTRIB_STACK_DEPTH = 0x0BB0
+ AUX_BUFFERS = 0x0C00
+ BLEND_DST = 0x0BE0
+ BLEND_SRC = 0x0BE1
+ BLUE_BIAS = 0x0D1B
+ BLUE_BITS = 0x0D54
+ BLUE_SCALE = 0x0D1A
+ CLIENT_ATTRIB_STACK_DEPTH = 0x0BB1
+ COLOR_ARRAY_SIZE = 0x8081
+ COLOR_ARRAY_STRIDE = 0x8083
+ COLOR_ARRAY_TYPE = 0x8082
+ COLOR_CLEAR_VALUE = 0x0C22
+ COLOR_MATERIAL_FACE = 0x0B55
+ COLOR_MATERIAL_PARAMETER = 0x0B56
+ COLOR_WRITEMASK = 0x0C23
+ CULL_FACE_MODE = 0x0B45
+ CURRENT_COLOR = 0x0B00
+ CURRENT_INDEX = 0x0B01
+ CURRENT_NORMAL = 0x0B02
+ CURRENT_RASTER_COLOR = 0x0B04
+ CURRENT_RASTER_DISTANCE = 0x0B09
+ CURRENT_RASTER_INDEX = 0x0B05
+ CURRENT_RASTER_POSITION = 0x0B07
+ CURRENT_RASTER_POSITION_VALID = 0x0B08
+ CURRENT_RASTER_TEXTURE_COORDS = 0x0B06
+ CURRENT_TEXTURE_COORDS = 0x0B03
+ DEPTH_BIAS = 0x0D1F
+ DEPTH_BITS = 0x0D56
+ DEPTH_CLEAR_VALUE = 0x0B73
+ DEPTH_FUNC = 0x0B74
+ DEPTH_RANGE = 0x0B70
+ DEPTH_SCALE = 0x0D1E
+ DEPTH_WRITEMASK = 0x0B72
+ DOUBLEBUFFER = 0x0C32
+ DRAW_BUFFER = 0x0C01
+ EDGE_FLAG = 0x0B43
+ EDGE_FLAG_ARRAY_STRIDE = 0x808C
+ FEEDBACK_BUFFER_SIZE = 0x0DF1
+ FEEDBACK_BUFFER_TYPE = 0x0DF2
+ FOG_HINT = 0x0C54
+ FRONT_FACE = 0x0B46
+ GREEN_BIAS = 0x0D19
+ GREEN_BITS = 0x0D53
+ GREEN_SCALE = 0x0D18
+ INDEX_ARRAY_STRIDE = 0x8086
+ INDEX_ARRAY_TYPE = 0x8085
+ INDEX_BITS = 0x0D51
+ INDEX_CLEAR_VALUE = 0x0C20
+ INDEX_MODE = 0x0C30
+ INDEX_OFFSET = 0x0D13
+ INDEX_SHIFT = 0x0D12
+ INDEX_WRITEMASK = 0x0C21
+ LIGHT_MODEL_AMBIENT = 0x0B53
+ LIGHT_MODEL_COLOR_CONTROL = 0x81F8
+ LIGHT_MODEL_LOCAL_VIEWER = 0x0B51
+ LIGHT_MODEL_TWO_SIDE = 0x0B52
+ LINE_SMOOTH_HINT = 0x0C52
+ LINE_STIPPLE_PATTERN = 0x0B25
+ LINE_STIPPLE_REPEAT = 0x0B26
+ LINE_WIDTH = 0x0B21
+ LINE_WIDTH_GRANULARITY = 0x0B23
+ LINE_WIDTH_RANGE = 0x0B22
+ LIST_BASE = 0x0B32
+ LIST_INDEX = 0x0B33
+ LIST_MODE = 0x0B30
+ LOGIC_OP_MODE = 0x0BF0
+ MAP1_GRID_DOMAIN = 0x0DD0
+ MAP1_GRID_SEGMENTS = 0x0DD1
+ MAP2_GRID_DOMAIN = 0x0DD2
+ MAP2_GRID_SEGMENTS = 0x0DD3
+ MAP_COLOR = 0x0D10
+ MAP_STENCIL = 0x0D11
+ MATRIX_MODE = 0x0BA0
+ MAX_ATTRIB_STACK_DEPTH = 0x0D35
+ MAX_CLIENT_ATTRIB_STACK_DEPTH = 0x0D3B
+ MAX_CLIP_PLANES = 0x0D32
+ MAX_EVAL_ORDER = 0x0D30
+ MAX_LIGHTS = 0x0D31
+ MAX_LIST_NESTING = 0x0B31
+ MAX_MODELVIEW_STACK_DEPTH = 0x0D36
+ MAX_NAME_STACK_DEPTH = 0x0D37
+ MAX_PIXEL_MAP_TABLE = 0x0D34
+ MAX_PROJECTION_STACK_DEPTH = 0x0D38
+ MAX_TEXTURE_SIZE = 0x0D33
+ MAX_TEXTURE_STACK_DEPTH = 0x0D39
+ MAX_VIEWPORT_DIMS = 0x0D3A
+ MODELVIEW_MATRIX = 0x0BA6
+ MODELVIEW_STACK_DEPTH = 0x0BA3
+ NAME_STACK_DEPTH = 0x0D70
+ NORMAL_ARRAY_STRIDE = 0x807F
+ NORMAL_ARRAY_TYPE = 0x807E
+ PACK_ALIGNMENT = 0x0D05
+ PACK_LSB_FIRST = 0x0D01
+ PACK_ROW_LENGTH = 0x0D02
+ PACK_SKIP_PIXELS = 0x0D04
+ PACK_SKIP_ROWS = 0x0D03
+ PACK_SWAP_BYTES = 0x0D00
+ PERSPECTIVE_CORRECTION_HINT = 0x0C50
+ PIXEL_MAP_A_TO_A_SIZE = 0x0CB9
+ PIXEL_MAP_B_TO_B_SIZE = 0x0CB8
+ PIXEL_MAP_G_TO_G_SIZE = 0x0CB7
+ PIXEL_MAP_I_TO_A_SIZE = 0x0CB5
+ PIXEL_MAP_I_TO_B_SIZE = 0x0CB4
+ PIXEL_MAP_I_TO_G_SIZE = 0x0CB3
+ PIXEL_MAP_I_TO_I_SIZE = 0x0CB0
+ PIXEL_MAP_I_TO_R_SIZE = 0x0CB2
+ PIXEL_MAP_R_TO_R_SIZE = 0x0CB6
+ PIXEL_MAP_S_TO_S_SIZE = 0x0CB1
+ POINT_SIZE = 0x0B11
+ POINT_SIZE_GRANULARITY = 0x0B13
+ POINT_SIZE_RANGE = 0x0B12
+ POINT_SMOOTH_HINT = 0x0C51
+ POLYGON_MODE = 0x0B40
+ POLYGON_OFFSET_FACTOR = 0x8038
+ POLYGON_OFFSET_UNITS = 0x2A00
+ POLYGON_SMOOTH_HINT = 0x0C53
+ PROJECTION_MATRIX = 0x0BA7
+ PROJECTION_STACK_DEPTH = 0x0BA4
+ READ_BUFFER = 0x0C02
+ RED_BIAS = 0x0D15
+ RED_BITS = 0x0D52
+ RED_SCALE = 0x0D14
+ RENDER_MODE = 0x0C40
+ RGBA_MODE = 0x0C31
+ SCISSOR_BOX = 0x0C10
+ SELECTION_BUFFER_SIZE = 0x0DF4
+ SHADE_MODEL = 0x0B54
+ SMOOTH_LINE_WIDTH_GRANULARITY = 0x0B23
+ SMOOTH_LINE_WIDTH_RANGE = 0x0B22
+ SMOOTH_POINT_SIZE_GRANULARITY = 0x0B13
+ SMOOTH_POINT_SIZE_RANGE = 0x0B12
+ STENCIL_BITS = 0x0D57
+ STENCIL_CLEAR_VALUE = 0x0B91
+ STENCIL_FAIL = 0x0B94
+ STENCIL_FUNC = 0x0B92
+ STENCIL_PASS_DEPTH_FAIL = 0x0B95
+ STENCIL_PASS_DEPTH_PASS = 0x0B96
+ STENCIL_REF = 0x0B97
+ STENCIL_VALUE_MASK = 0x0B93
+ STENCIL_WRITEMASK = 0x0B98
+ STEREO = 0x0C33
+ SUBPIXEL_BITS = 0x0D50
+ TEXTURE_BINDING_1D = 0x8068
+ TEXTURE_BINDING_2D = 0x8069
+ TEXTURE_BINDING_3D = 0x806A
+ TEXTURE_COORD_ARRAY_SIZE = 0x8088
+ TEXTURE_COORD_ARRAY_STRIDE = 0x808A
+ TEXTURE_COORD_ARRAY_TYPE = 0x8089
+ TEXTURE_MATRIX = 0x0BA8
+ TEXTURE_STACK_DEPTH = 0x0BA5
+ UNPACK_ALIGNMENT = 0x0CF5
+ UNPACK_LSB_FIRST = 0x0CF1
+ UNPACK_ROW_LENGTH = 0x0CF2
+ UNPACK_SKIP_PIXELS = 0x0CF4
+ UNPACK_SKIP_ROWS = 0x0CF3
+ UNPACK_SWAP_BYTES = 0x0CF0
+ VERTEX_ARRAY_SIZE = 0x807A
+ VERTEX_ARRAY_STRIDE = 0x807C
+ VERTEX_ARRAY_TYPE = 0x807B
+ VIEWPORT = 0x0BA2
+ ZOOM_X = 0x0D16
+ ZOOM_Y = 0x0D17
+
+ COLOR_ARRAY_POINTER = 0x8090
+ EDGE_FLAG_ARRAY_POINTER = 0x8093
+ FEEDBACK_BUFFER_POINTER = 0x0DF0
+ INDEX_ARRAY_POINTER = 0x8091
+ NORMAL_ARRAY_POINTER = 0x808F
+ SELECTION_BUFFER_POINTER = 0x0DF3
+ TEXTURE_COORD_ARRAY_POINTER = 0x8092
+ VERTEX_ARRAY_POINTER = 0x808E
+
+ TEXTURE_ALPHA_SIZE = 0x805F
+ TEXTURE_BLUE_SIZE = 0x805E
+ TEXTURE_BORDER = 0x1005
+ TEXTURE_BORDER_COLOR = 0x1004
+ TEXTURE_COMPONENTS = 0x1003
+ TEXTURE_GREEN_SIZE = 0x805D
+ TEXTURE_HEIGHT = 0x1001
+ TEXTURE_INTENSITY_SIZE = 0x8061
+ TEXTURE_INTERNAL_FORMAT = 0x1003
+ TEXTURE_LUMINANCE_SIZE = 0x8060
+ TEXTURE_MAG_FILTER = 0x2800
+ TEXTURE_MIN_FILTER = 0x2801
+ TEXTURE_PRIORITY = 0x8066
+ TEXTURE_RED_SIZE = 0x805C
+ TEXTURE_RESIDENT = 0x8067
+ TEXTURE_WIDTH = 0x1000
+ TEXTURE_WRAP_S = 0x2802
+ TEXTURE_WRAP_T = 0x2803
+
+ DONT_CARE = 0x1100
+ FASTEST = 0x1101
+ NICEST = 0x1102
+
+ GENERATE_MIPMAP_HINT = 0x8192
+ TEXTURE_COMPRESSION_HINT = 0x84EF
+
+ C3F_V3F = 0x2A24
+ C4F_N3F_V3F = 0x2A26
+ C4UB_V2F = 0x2A22
+ C4UB_V3F = 0x2A23
+ N3F_V3F = 0x2A25
+ T2F_C3F_V3F = 0x2A2A
+ T2F_C4F_N3F_V3F = 0x2A2C
+ T2F_C4UB_V3F = 0x2A29
+ T2F_N3F_V3F = 0x2A2B
+ T2F_V3F = 0x2A27
+ T4F_C4F_N3F_V4F = 0x2A2D
+ T4F_V4F = 0x2A28
+ V2F = 0x2A20
+ V3F = 0x2A21
+
+ MODULATE = 0x2100
+ REPLACE = 0x1E01
+
+ SEPARATE_SPECULAR_COLOR = 0x81FA
+ SINGLE_COLOR = 0x81F9
+
+ CONSTANT_ATTENUATION = 0x1207
+ LINEAR_ATTENUATION = 0x1208
+ POSITION = 0x1203
+ QUADRATIC_ATTENUATION = 0x1209
+ SPOT_CUTOFF = 0x1206
+ SPOT_DIRECTION = 0x1204
+ SPOT_EXPONENT = 0x1205
+
+ COMPILE = 0x1300
+ COMPILE_AND_EXECUTE = 0x1301
+
+ AND = 0x1501
+ AND_INVERTED = 0x1504
+ AND_REVERSE = 0x1502
+ CLEAR = 0x1500
+ COPY = 0x1503
+ COPY_INVERTED = 0x150C
+ EQUIV = 0x1509
+ INVERT = 0x150A
+ NAND = 0x150E
+ NOOP = 0x1505
+ NOR = 0x1508
+ OR = 0x1507
+ OR_INVERTED = 0x150D
+ OR_REVERSE = 0x150B
+ SET = 0x150F
+ XOR = 0x1506
+
+ COLOR_INDEXES = 0x1603
+ SHININESS = 0x1601
+
+ MODELVIEW = 0x1700
+ PROJECTION = 0x1701
+ TEXTURE = 0x1702
+
+ LINE = 0x1B01
+ POINT = 0x1B00
+
+ FILL = 0x1B02
+
+ COLOR = 0x1800
+ DEPTH = 0x1801
+ STENCIL = 0x1802
+
+ ALPHA = 0x1906
+ BLUE = 0x1905
+ COLOR_INDEX = 0x1900
+ DEPTH_COMPONENT = 0x1902
+ GREEN = 0x1904
+ LUMINANCE = 0x1909
+ LUMINANCE_ALPHA = 0x190A
+ RED = 0x1903
+ RGB = 0x1907
+ RGBA = 0x1908
+ STENCIL_INDEX = 0x1901
+
+ ALPHA12 = 0x803D
+ ALPHA16 = 0x803E
+ ALPHA4 = 0x803B
+ ALPHA8 = 0x803C
+ INTENSITY = 0x8049
+ INTENSITY12 = 0x804C
+ INTENSITY16 = 0x804D
+ INTENSITY4 = 0x804A
+ INTENSITY8 = 0x804B
+ LUMINANCE12 = 0x8041
+ LUMINANCE12_ALPHA12 = 0x8047
+ LUMINANCE12_ALPHA4 = 0x8046
+ LUMINANCE16 = 0x8042
+ LUMINANCE16_ALPHA16 = 0x8048
+ LUMINANCE4 = 0x803F
+ LUMINANCE4_ALPHA4 = 0x8043
+ LUMINANCE6_ALPHA2 = 0x8044
+ LUMINANCE8 = 0x8040
+ LUMINANCE8_ALPHA8 = 0x8045
+ R3_G3_B2 = 0x2A10
+ RGB10 = 0x8052
+ RGB10_A2 = 0x8059
+ RGB12 = 0x8053
+ RGB16 = 0x8054
+ RGB4 = 0x804F
+ RGB5 = 0x8050
+ RGB5_A1 = 0x8057
+ RGB8 = 0x8051
+ RGBA12 = 0x805A
+ RGBA16 = 0x805B
+ RGBA2 = 0x8055
+ RGBA4 = 0x8056
+ RGBA8 = 0x8058
+
+ PACK_IMAGE_HEIGHT = 0x806C
+ PACK_SKIP_IMAGES = 0x806B
+ UNPACK_IMAGE_HEIGHT = 0x806E
+ UNPACK_SKIP_IMAGES = 0x806D
+
+ BITMAP = 0x1A00
+ UNSIGNED_BYTE_3_3_2 = 0x8032
+ UNSIGNED_INT_10_10_10_2 = 0x8036
+ UNSIGNED_INT_8_8_8_8 = 0x8035
+ UNSIGNED_SHORT_4_4_4_4 = 0x8033
+ UNSIGNED_SHORT_5_5_5_1 = 0x8034
+
+ POINT_DISTANCE_ATTENUATION = 0x8129
+ POINT_FADE_THRESHOLD_SIZE = 0x8128
+ POINT_SIZE_MAX = 0x8127
+ POINT_SIZE_MIN = 0x8126
+
+ LINES = 0x0001
+ LINE_LOOP = 0x0002
+ LINE_STRIP = 0x0003
+ POINTS = 0x0000
+ POLYGON = 0x0009
+ QUADS = 0x0007
+ QUAD_STRIP = 0x0008
+ TRIANGLES = 0x0004
+ TRIANGLE_FAN = 0x0006
+ TRIANGLE_STRIP = 0x0005
+
+ FEEDBACK = 0x1C01
+ RENDER = 0x1C00
+ SELECT = 0x1C02
+
+ FLAT = 0x1D00
+ SMOOTH = 0x1D01
+
+ DECR = 0x1E03
+ INCR = 0x1E02
+ KEEP = 0x1E00
+
+ EXTENSIONS = 0x1F03
+ RENDERER = 0x1F01
+ VENDOR = 0x1F00
+ VERSION = 0x1F02
+
+ S = 0x2000
+ T = 0x2001
+ R = 0x2002
+ Q = 0x2003
+
+ DECAL = 0x2101
+
+ TEXTURE_ENV_COLOR = 0x2201
+ TEXTURE_ENV_MODE = 0x2200
+
+ TEXTURE_ENV = 0x2300
+
+ EYE_LINEAR = 0x2400
+ OBJECT_LINEAR = 0x2401
+ SPHERE_MAP = 0x2402
+
+ EYE_PLANE = 0x2502
+ OBJECT_PLANE = 0x2501
+ TEXTURE_GEN_MODE = 0x2500
+
+ NEAREST = 0x2600
+
+ LINEAR_MIPMAP_LINEAR = 0x2703
+ LINEAR_MIPMAP_NEAREST = 0x2701
+ NEAREST_MIPMAP_LINEAR = 0x2702
+ NEAREST_MIPMAP_NEAREST = 0x2700
+
+ GENERATE_MIPMAP = 0x8191
+ TEXTURE_WRAP_R = 0x8072
+
+ PROXY_TEXTURE_1D = 0x8063
+ PROXY_TEXTURE_2D = 0x8064
+ PROXY_TEXTURE_3D = 0x8070
+ TEXTURE_3D = 0x806F
+ TEXTURE_BASE_LEVEL = 0x813C
+ TEXTURE_MAX_LEVEL = 0x813D
+ TEXTURE_MAX_LOD = 0x813B
+ TEXTURE_MIN_LOD = 0x813A
+
+ CLAMP = 0x2900
+ CLAMP_TO_BORDER = 0x812D
+ CLAMP_TO_EDGE = 0x812F
+ REPEAT = 0x2901
+
+ CONSTANT_COLOR = 0x8001
+ ONE_MINUS_CONSTANT_COLOR = 0x8002
+ CONSTANT_ALPHA = 0x8003
+ ONE_MINUS_CONSTANT_ALPHA = 0x8004
+ FUNC_ADD = 0x8006
+ MIN = 0x8007
+ MAX = 0x8008
+ FUNC_SUBTRACT = 0x800A
+ FUNC_REVERSE_SUBTRACT = 0x800B
+ RESCALE_NORMAL = 0x803A
+ TEXTURE_DEPTH = 0x8071
+ MAX_3D_TEXTURE_SIZE = 0x8073
+ MULTISAMPLE = 0x809D
+ SAMPLE_ALPHA_TO_COVERAGE = 0x809E
+ SAMPLE_ALPHA_TO_ONE = 0x809F
+ SAMPLE_COVERAGE = 0x80A0
+ SAMPLE_BUFFERS = 0x80A8
+ SAMPLES = 0x80A9
+ SAMPLE_COVERAGE_VALUE = 0x80AA
+ SAMPLE_COVERAGE_INVERT = 0x80AB
+ BLEND_DST_RGB = 0x80C8
+ BLEND_SRC_RGB = 0x80C9
+ BLEND_DST_ALPHA = 0x80CA
+ BLEND_SRC_ALPHA = 0x80CB
+ BGR = 0x80E0
+ BGRA = 0x80E1
+ MAX_ELEMENTS_VERTICES = 0x80E8
+ MAX_ELEMENTS_INDICES = 0x80E9
+ DEPTH_COMPONENT16 = 0x81A5
+ DEPTH_COMPONENT24 = 0x81A6
+ DEPTH_COMPONENT32 = 0x81A7
+ UNSIGNED_BYTE_2_3_3_REV = 0x8362
+ UNSIGNED_SHORT_5_6_5 = 0x8363
+ UNSIGNED_SHORT_5_6_5_REV = 0x8364
+ UNSIGNED_SHORT_4_4_4_4_REV = 0x8365
+ UNSIGNED_SHORT_1_5_5_5_REV = 0x8366
+ UNSIGNED_INT_8_8_8_8_REV = 0x8367
+ UNSIGNED_INT_2_10_10_10_REV = 0x8368
+ MIRRORED_REPEAT = 0x8370
+ FOG_COORDINATE_SOURCE = 0x8450
+ FOG_COORD_SRC = 0x8450
+ FOG_COORDINATE = 0x8451
+ FOG_COORD = 0x8451
+ FRAGMENT_DEPTH = 0x8452
+ CURRENT_FOG_COORDINATE = 0x8453
+ CURRENT_FOG_COORD = 0x8453
+ FOG_COORDINATE_ARRAY_TYPE = 0x8454
+ FOG_COORD_ARRAY_TYPE = 0x8454
+ FOG_COORDINATE_ARRAY_STRIDE = 0x8455
+ FOG_COORD_ARRAY_STRIDE = 0x8455
+ FOG_COORDINATE_ARRAY_POINTER = 0x8456
+ FOG_COORD_ARRAY_POINTER = 0x8456
+ FOG_COORDINATE_ARRAY = 0x8457
+ FOG_COORD_ARRAY = 0x8457
+ COLOR_SUM = 0x8458
+ CURRENT_SECONDARY_COLOR = 0x8459
+ SECONDARY_COLOR_ARRAY_SIZE = 0x845A
+ SECONDARY_COLOR_ARRAY_TYPE = 0x845B
+ SECONDARY_COLOR_ARRAY_STRIDE = 0x845C
+ SECONDARY_COLOR_ARRAY_POINTER = 0x845D
+ SECONDARY_COLOR_ARRAY = 0x845E
+ TEXTURE0 = 0x84C0
+ TEXTURE1 = 0x84C1
+ TEXTURE2 = 0x84C2
+ TEXTURE3 = 0x84C3
+ TEXTURE4 = 0x84C4
+ TEXTURE5 = 0x84C5
+ TEXTURE6 = 0x84C6
+ TEXTURE7 = 0x84C7
+ TEXTURE8 = 0x84C8
+ TEXTURE9 = 0x84C9
+ TEXTURE10 = 0x84CA
+ TEXTURE11 = 0x84CB
+ TEXTURE12 = 0x84CC
+ TEXTURE13 = 0x84CD
+ TEXTURE14 = 0x84CE
+ TEXTURE15 = 0x84CF
+ TEXTURE16 = 0x84D0
+ TEXTURE17 = 0x84D1
+ TEXTURE18 = 0x84D2
+ TEXTURE19 = 0x84D3
+ TEXTURE20 = 0x84D4
+ TEXTURE21 = 0x84D5
+ TEXTURE22 = 0x84D6
+ TEXTURE23 = 0x84D7
+ TEXTURE24 = 0x84D8
+ TEXTURE25 = 0x84D9
+ TEXTURE26 = 0x84DA
+ TEXTURE27 = 0x84DB
+ TEXTURE28 = 0x84DC
+ TEXTURE29 = 0x84DD
+ TEXTURE30 = 0x84DE
+ TEXTURE31 = 0x84DF
+ ACTIVE_TEXTURE = 0x84E0
+ CLIENT_ACTIVE_TEXTURE = 0x84E1
+ MAX_TEXTURE_UNITS = 0x84E2
+ TRANSPOSE_MODELVIEW_MATRIX = 0x84E3
+ TRANSPOSE_PROJECTION_MATRIX = 0x84E4
+ TRANSPOSE_TEXTURE_MATRIX = 0x84E5
+ TRANSPOSE_COLOR_MATRIX = 0x84E6
+ SUBTRACT = 0x84E7
+ COMPRESSED_ALPHA = 0x84E9
+ COMPRESSED_LUMINANCE = 0x84EA
+ COMPRESSED_LUMINANCE_ALPHA = 0x84EB
+ COMPRESSED_INTENSITY = 0x84EC
+ COMPRESSED_RGB = 0x84ED
+ COMPRESSED_RGBA = 0x84EE
+ MAX_TEXTURE_LOD_BIAS = 0x84FD
+ TEXTURE_FILTER_CONTROL = 0x8500
+ TEXTURE_LOD_BIAS = 0x8501
+ INCR_WRAP = 0x8507
+ DECR_WRAP = 0x8508
+ NORMAL_MAP = 0x8511
+ REFLECTION_MAP = 0x8512
+ TEXTURE_CUBE_MAP = 0x8513
+ TEXTURE_BINDING_CUBE_MAP = 0x8514
+ TEXTURE_CUBE_MAP_POSITIVE_X = 0x8515
+ TEXTURE_CUBE_MAP_NEGATIVE_X = 0x8516
+ TEXTURE_CUBE_MAP_POSITIVE_Y = 0x8517
+ TEXTURE_CUBE_MAP_NEGATIVE_Y = 0x8518
+ TEXTURE_CUBE_MAP_POSITIVE_Z = 0x8519
+ TEXTURE_CUBE_MAP_NEGATIVE_Z = 0x851A
+ PROXY_TEXTURE_CUBE_MAP = 0x851B
+ MAX_CUBE_MAP_TEXTURE_SIZE = 0x851C
+ COMBINE = 0x8570
+ COMBINE_RGB = 0x8571
+ COMBINE_ALPHA = 0x8572
+ RGB_SCALE = 0x8573
+ ADD_SIGNED = 0x8574
+ INTERPOLATE = 0x8575
+ CONSTANT = 0x8576
+ PRIMARY_COLOR = 0x8577
+ PREVIOUS = 0x8578
+ SOURCE0_RGB = 0x8580
+ SRC0_RGB = 0x8580
+ SOURCE1_RGB = 0x8581
+ SRC1_RGB = 0x8581
+ SOURCE2_RGB = 0x8582
+ SRC2_RGB = 0x8582
+ SOURCE0_ALPHA = 0x8588
+ SRC0_ALPHA = 0x8588
+ SOURCE1_ALPHA = 0x8589
+ SRC1_ALPHA = 0x8589
+ SOURCE2_ALPHA = 0x858A
+ SRC2_ALPHA = 0x858A
+ OPERAND0_RGB = 0x8590
+ OPERAND1_RGB = 0x8591
+ OPERAND2_RGB = 0x8592
+ OPERAND0_ALPHA = 0x8598
+ OPERAND1_ALPHA = 0x8599
+ OPERAND2_ALPHA = 0x859A
+ TEXTURE_COMPRESSED_IMAGE_SIZE = 0x86A0
+ TEXTURE_COMPRESSED = 0x86A1
+ NUM_COMPRESSED_TEXTURE_FORMATS = 0x86A2
+ COMPRESSED_TEXTURE_FORMATS = 0x86A3
+ DOT3_RGB = 0x86AE
+ DOT3_RGBA = 0x86AF
+ BUFFER_SIZE = 0x8764
+ BUFFER_USAGE = 0x8765
+ TEXTURE_DEPTH_SIZE = 0x884A
+ DEPTH_TEXTURE_MODE = 0x884B
+ TEXTURE_COMPARE_MODE = 0x884C
+ TEXTURE_COMPARE_FUNC = 0x884D
+ COMPARE_R_TO_TEXTURE = 0x884E
+ QUERY_COUNTER_BITS = 0x8864
+ CURRENT_QUERY = 0x8865
+ QUERY_RESULT = 0x8866
+ QUERY_RESULT_AVAILABLE = 0x8867
+ ARRAY_BUFFER = 0x8892
+ ELEMENT_ARRAY_BUFFER = 0x8893
+ ARRAY_BUFFER_BINDING = 0x8894
+ ELEMENT_ARRAY_BUFFER_BINDING = 0x8895
+ VERTEX_ARRAY_BUFFER_BINDING = 0x8896
+ NORMAL_ARRAY_BUFFER_BINDING = 0x8897
+ COLOR_ARRAY_BUFFER_BINDING = 0x8898
+ INDEX_ARRAY_BUFFER_BINDING = 0x8899
+ TEXTURE_COORD_ARRAY_BUFFER_BINDING = 0x889A
+ EDGE_FLAG_ARRAY_BUFFER_BINDING = 0x889B
+ SECONDARY_COLOR_ARRAY_BUFFER_BINDING = 0x889C
+ FOG_COORDINATE_ARRAY_BUFFER_BINDING = 0x889D
+ FOG_COORD_ARRAY_BUFFER_BINDING = 0x889D
+ WEIGHT_ARRAY_BUFFER_BINDING = 0x889E
+ VERTEX_ATTRIB_ARRAY_BUFFER_BINDING = 0x889F
+ READ_ONLY = 0x88B8
+ WRITE_ONLY = 0x88B9
+ READ_WRITE = 0x88BA
+ BUFFER_ACCESS = 0x88BB
+ BUFFER_MAPPED = 0x88BC
+ BUFFER_MAP_POINTER = 0x88BD
+ STREAM_DRAW = 0x88E0
+ STREAM_READ = 0x88E1
+ STREAM_COPY = 0x88E2
+ STATIC_DRAW = 0x88E4
+ STATIC_READ = 0x88E5
+ STATIC_COPY = 0x88E6
+ DYNAMIC_DRAW = 0x88E8
+ DYNAMIC_READ = 0x88E9
+ DYNAMIC_COPY = 0x88EA
+ SAMPLES_PASSED = 0x8914
+)
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glViewport.xml
+func (gl *GL) Viewport(x, y, width, height int) {
+ C.gl1_5_glViewport(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// DepthRange specifies the mapping of depth values from normalized device
+// coordinates to window coordinates.
+//
+// Parameter nearVal specifies the mapping of the near clipping plane to window
+// coordinates (defaults to 0), while farVal specifies the mapping of the far
+// clipping plane to window coordinates (defaults to 1).
+//
+// After clipping and division by w, depth coordinates range from -1 to 1,
+// corresponding to the near and far clipping planes. DepthRange specifies a
+// linear mapping of the normalized depth coordinates in this range to window
+// depth coordinates. Regardless of the actual depth buffer implementation,
+// window coordinate depth values are treated as though they range from 0 through 1
+// (like color components). Thus, the values accepted by DepthRange are both
+// clamped to this range before they are accepted.
+//
+// The default setting of (0, 1) maps the near plane to 0 and the far plane to 1.
+// With this mapping, the depth buffer range is fully utilized.
+//
+// It is not necessary that nearVal be less than farVal. Reverse mappings such as
+// nearVal 1, and farVal 0 are acceptable.
+//
+// GL.INVALID_OPERATION is generated if DepthRange is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) DepthRange(nearVal, farVal float64) {
+ C.gl1_5_glDepthRange(gl.funcs, C.GLdouble(nearVal), C.GLdouble(farVal))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIsEnabled.xml
+func (gl *GL) IsEnabled(cap glbase.Enum) bool {
+ glresult := C.gl1_5_glIsEnabled(gl.funcs, C.GLenum(cap))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexLevelParameteriv.xml
+func (gl *GL) GetTexLevelParameteriv(target glbase.Enum, level int, pname glbase.Enum, params []int32) {
+ C.gl1_5_glGetTexLevelParameteriv(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexLevelParameterfv.xml
+func (gl *GL) GetTexLevelParameterfv(target glbase.Enum, level int, pname glbase.Enum, params []float32) {
+ C.gl1_5_glGetTexLevelParameterfv(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexParameteriv.xml
+func (gl *GL) GetTexParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl1_5_glGetTexParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexParameterfv.xml
+func (gl *GL) GetTexParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl1_5_glGetTexParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexImage.xml
+func (gl *GL) GetTexImage(target glbase.Enum, level int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_5_glGetTexImage(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetIntegerv.xml
+func (gl *GL) GetIntegerv(pname glbase.Enum, params []int32) {
+ C.gl1_5_glGetIntegerv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetFloatv.xml
+func (gl *GL) GetFloatv(pname glbase.Enum, params []float32) {
+ C.gl1_5_glGetFloatv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetError.xml
+func (gl *GL) GetError() glbase.Enum {
+ glresult := C.gl1_5_glGetError(gl.funcs)
+ return glbase.Enum(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetDoublev.xml
+func (gl *GL) GetDoublev(pname glbase.Enum, params []float64) {
+ C.gl1_5_glGetDoublev(gl.funcs, C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetBooleanv.xml
+func (gl *GL) GetBooleanv(pname glbase.Enum, params []bool) {
+ C.gl1_5_glGetBooleanv(gl.funcs, C.GLenum(pname), (*C.GLboolean)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glReadPixels.xml
+func (gl *GL) ReadPixels(x, y, width, height int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_5_glReadPixels(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glReadBuffer.xml
+func (gl *GL) ReadBuffer(mode glbase.Enum) {
+ C.gl1_5_glReadBuffer(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelStorei.xml
+func (gl *GL) PixelStorei(pname glbase.Enum, param int32) {
+ C.gl1_5_glPixelStorei(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelStoref.xml
+func (gl *GL) PixelStoref(pname glbase.Enum, param float32) {
+ C.gl1_5_glPixelStoref(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDepthFunc.xml
+func (gl *GL) DepthFunc(glfunc glbase.Enum) {
+ C.gl1_5_glDepthFunc(gl.funcs, C.GLenum(glfunc))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glStencilOp.xml
+func (gl *GL) StencilOp(fail, zfail, zpass glbase.Enum) {
+ C.gl1_5_glStencilOp(gl.funcs, C.GLenum(fail), C.GLenum(zfail), C.GLenum(zpass))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glStencilFunc.xml
+func (gl *GL) StencilFunc(glfunc glbase.Enum, ref int32, mask uint32) {
+ C.gl1_5_glStencilFunc(gl.funcs, C.GLenum(glfunc), C.GLint(ref), C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLogicOp.xml
+func (gl *GL) LogicOp(opcode glbase.Enum) {
+ C.gl1_5_glLogicOp(gl.funcs, C.GLenum(opcode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBlendFunc.xml
+func (gl *GL) BlendFunc(sfactor, dfactor glbase.Enum) {
+ C.gl1_5_glBlendFunc(gl.funcs, C.GLenum(sfactor), C.GLenum(dfactor))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFlush.xml
+func (gl *GL) Flush() {
+ C.gl1_5_glFlush(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFinish.xml
+func (gl *GL) Finish() {
+ C.gl1_5_glFinish(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEnable.xml
+func (gl *GL) Enable(cap glbase.Enum) {
+ C.gl1_5_glEnable(gl.funcs, C.GLenum(cap))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDisable.xml
+func (gl *GL) Disable(cap glbase.Enum) {
+ C.gl1_5_glDisable(gl.funcs, C.GLenum(cap))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDepthMask.xml
+func (gl *GL) DepthMask(flag bool) {
+ C.gl1_5_glDepthMask(gl.funcs, *(*C.GLboolean)(unsafe.Pointer(&flag)))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColorMask.xml
+func (gl *GL) ColorMask(red, green, blue, alpha bool) {
+ C.gl1_5_glColorMask(gl.funcs, *(*C.GLboolean)(unsafe.Pointer(&red)), *(*C.GLboolean)(unsafe.Pointer(&green)), *(*C.GLboolean)(unsafe.Pointer(&blue)), *(*C.GLboolean)(unsafe.Pointer(&alpha)))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glStencilMask.xml
+func (gl *GL) StencilMask(mask uint32) {
+ C.gl1_5_glStencilMask(gl.funcs, C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClearDepth.xml
+func (gl *GL) ClearDepth(depth float64) {
+ C.gl1_5_glClearDepth(gl.funcs, C.GLdouble(depth))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClearStencil.xml
+func (gl *GL) ClearStencil(s int32) {
+ C.gl1_5_glClearStencil(gl.funcs, C.GLint(s))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClearColor.xml
+func (gl *GL) ClearColor(red, green, blue, alpha float32) {
+ C.gl1_5_glClearColor(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClear.xml
+func (gl *GL) Clear(mask glbase.Bitfield) {
+ C.gl1_5_glClear(gl.funcs, C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDrawBuffer.xml
+func (gl *GL) DrawBuffer(mode glbase.Enum) {
+ C.gl1_5_glDrawBuffer(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexImage2D.xml
+func (gl *GL) TexImage2D(target glbase.Enum, level int, internalFormat int32, width, height, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_5_glTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexImage1D.xml
+func (gl *GL) TexImage1D(target glbase.Enum, level int, internalFormat int32, width, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_5_glTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexParameteriv.xml
+func (gl *GL) TexParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl1_5_glTexParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexParameteri.xml
+func (gl *GL) TexParameteri(target, pname glbase.Enum, param int32) {
+ C.gl1_5_glTexParameteri(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexParameterfv.xml
+func (gl *GL) TexParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl1_5_glTexParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexParameterf.xml
+func (gl *GL) TexParameterf(target, pname glbase.Enum, param float32) {
+ C.gl1_5_glTexParameterf(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glScissor.xml
+func (gl *GL) Scissor(x, y, width, height int) {
+ C.gl1_5_glScissor(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPolygonMode.xml
+func (gl *GL) PolygonMode(face, mode glbase.Enum) {
+ C.gl1_5_glPolygonMode(gl.funcs, C.GLenum(face), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPointSize.xml
+func (gl *GL) PointSize(size float32) {
+ C.gl1_5_glPointSize(gl.funcs, C.GLfloat(size))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLineWidth.xml
+func (gl *GL) LineWidth(width float32) {
+ C.gl1_5_glLineWidth(gl.funcs, C.GLfloat(width))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glHint.xml
+func (gl *GL) Hint(target, mode glbase.Enum) {
+ C.gl1_5_glHint(gl.funcs, C.GLenum(target), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFrontFace.xml
+func (gl *GL) FrontFace(mode glbase.Enum) {
+ C.gl1_5_glFrontFace(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCullFace.xml
+func (gl *GL) CullFace(mode glbase.Enum) {
+ C.gl1_5_glCullFace(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexubv.xml
+func (gl *GL) Indexubv(c []uint8) {
+ C.gl1_5_glIndexubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexub.xml
+func (gl *GL) Indexub(c uint8) {
+ C.gl1_5_glIndexub(gl.funcs, C.GLubyte(c))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIsTexture.xml
+func (gl *GL) IsTexture(texture glbase.Texture) bool {
+ glresult := C.gl1_5_glIsTexture(gl.funcs, C.GLuint(texture))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// GenTextures returns n texture names in textures. There is no guarantee
+// that the names form a contiguous set of integers; however, it is
+// guaranteed that none of the returned names was in use immediately before
+// the call to GenTextures.
+//
+// The generated textures have no dimensionality; they assume the
+// dimensionality of the texture target to which they are first bound (see
+// BindTexture).
+//
+// Texture names returned by a call to GenTextures are not returned by
+// subsequent calls, unless they are first deleted with DeleteTextures.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// GenTextures is available in GL version 2.0 or greater.
+func (gl *GL) GenTextures(n int) []glbase.Texture {
+ if n == 0 {
+ return nil
+ }
+ textures := make([]glbase.Texture, n)
+ C.gl1_5_glGenTextures(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])))
+ return textures
+}
+
+// DeleteTextures deletes the textures objects whose names are stored
+// in the textures slice. After a texture is deleted, it has no contents or
+// dimensionality, and its name is free for reuse (for example by
+// GenTextures). If a texture that is currently bound is deleted, the binding
+// reverts to 0 (the default texture).
+//
+// DeleteTextures silently ignores 0's and names that do not correspond to
+// existing textures.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// DeleteTextures is available in GL version 2.0 or greater.
+func (gl *GL) DeleteTextures(textures []glbase.Texture) {
+ n := len(textures)
+ if n == 0 {
+ return
+ }
+ C.gl1_5_glDeleteTextures(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBindTexture.xml
+func (gl *GL) BindTexture(target glbase.Enum, texture glbase.Texture) {
+ C.gl1_5_glBindTexture(gl.funcs, C.GLenum(target), C.GLuint(texture))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexSubImage2D.xml
+func (gl *GL) TexSubImage2D(target glbase.Enum, level, xoffset, yoffset, width, height int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_5_glTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexSubImage1D.xml
+func (gl *GL) TexSubImage1D(target glbase.Enum, level, xoffset, width int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_5_glTexSubImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLsizei(width), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyTexSubImage2D.xml
+func (gl *GL) CopyTexSubImage2D(target glbase.Enum, level, xoffset, yoffset, x, y, width, height int) {
+ C.gl1_5_glCopyTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyTexSubImage1D.xml
+func (gl *GL) CopyTexSubImage1D(target glbase.Enum, level, xoffset, x, y, width int) {
+ C.gl1_5_glCopyTexSubImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(x), C.GLint(y), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyTexImage2D.xml
+func (gl *GL) CopyTexImage2D(target glbase.Enum, level int, internalFormat glbase.Enum, x, y, width, height, border int) {
+ C.gl1_5_glCopyTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height), C.GLint(border))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyTexImage1D.xml
+func (gl *GL) CopyTexImage1D(target glbase.Enum, level int, internalFormat glbase.Enum, x, y, width, border int) {
+ C.gl1_5_glCopyTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLint(border))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPolygonOffset.xml
+func (gl *GL) PolygonOffset(factor, units float32) {
+ C.gl1_5_glPolygonOffset(gl.funcs, C.GLfloat(factor), C.GLfloat(units))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDrawElements.xml
+func (gl *GL) DrawElements(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_5_glDrawElements(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDrawArrays.xml
+func (gl *GL) DrawArrays(mode glbase.Enum, first, count int) {
+ C.gl1_5_glDrawArrays(gl.funcs, C.GLenum(mode), C.GLint(first), C.GLsizei(count))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyTexSubImage3D.xml
+func (gl *GL) CopyTexSubImage3D(target glbase.Enum, level, xoffset, yoffset int, zoffset int32, x, y, width, height int) {
+ C.gl1_5_glCopyTexSubImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(zoffset), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexSubImage3D.xml
+func (gl *GL) TexSubImage3D(target glbase.Enum, level, xoffset, yoffset int, zoffset int32, width, height int, depth int32, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_5_glTexSubImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(zoffset), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexImage3D.xml
+func (gl *GL) TexImage3D(target glbase.Enum, level int, internalFormat int32, width, height int, depth int32, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_5_glTexImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDrawRangeElements.xml
+func (gl *GL) DrawRangeElements(mode glbase.Enum, start, end uint32, count int, gltype glbase.Enum, indices interface{}) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_5_glDrawRangeElements(gl.funcs, C.GLenum(mode), C.GLuint(start), C.GLuint(end), C.GLsizei(count), C.GLenum(gltype), indices_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBlendEquation.xml
+func (gl *GL) BlendEquation(mode glbase.Enum) {
+ C.gl1_5_glBlendEquation(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBlendColor.xml
+func (gl *GL) BlendColor(red, green, blue, alpha float32) {
+ C.gl1_5_glBlendColor(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetCompressedTexImage.xml
+func (gl *GL) GetCompressedTexImage(target glbase.Enum, level int, img interface{}) {
+ var img_ptr unsafe.Pointer
+ var img_v = reflect.ValueOf(img)
+ if img != nil && img_v.Kind() != reflect.Slice {
+ panic("parameter img must be a slice")
+ }
+ if img != nil {
+ img_ptr = unsafe.Pointer(img_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_5_glGetCompressedTexImage(gl.funcs, C.GLenum(target), C.GLint(level), img_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCompressedTexSubImage1D.xml
+func (gl *GL) CompressedTexSubImage1D(target glbase.Enum, level, xoffset, width int, format glbase.Enum, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_5_glCompressedTexSubImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLsizei(width), C.GLenum(format), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCompressedTexSubImage2D.xml
+func (gl *GL) CompressedTexSubImage2D(target glbase.Enum, level, xoffset, yoffset, width, height int, format glbase.Enum, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_5_glCompressedTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCompressedTexSubImage3D.xml
+func (gl *GL) CompressedTexSubImage3D(target glbase.Enum, level, xoffset, yoffset int, zoffset int32, width, height int, depth int32, format glbase.Enum, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_5_glCompressedTexSubImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(zoffset), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLenum(format), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCompressedTexImage1D.xml
+func (gl *GL) CompressedTexImage1D(target glbase.Enum, level int, internalFormat glbase.Enum, width, border, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_5_glCompressedTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLsizei(width), C.GLint(border), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCompressedTexImage2D.xml
+func (gl *GL) CompressedTexImage2D(target glbase.Enum, level int, internalFormat glbase.Enum, width, height, border, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_5_glCompressedTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLint(border), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCompressedTexImage3D.xml
+func (gl *GL) CompressedTexImage3D(target glbase.Enum, level int, internalFormat glbase.Enum, width, height int, depth int32, border, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_5_glCompressedTexImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLint(border), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSampleCoverage.xml
+func (gl *GL) SampleCoverage(value float32, invert bool) {
+ C.gl1_5_glSampleCoverage(gl.funcs, C.GLfloat(value), *(*C.GLboolean)(unsafe.Pointer(&invert)))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glActiveTexture.xml
+func (gl *GL) ActiveTexture(texture glbase.Enum) {
+ C.gl1_5_glActiveTexture(gl.funcs, C.GLenum(texture))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPointParameteriv.xml
+func (gl *GL) PointParameteriv(pname glbase.Enum, params []int32) {
+ C.gl1_5_glPointParameteriv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPointParameteri.xml
+func (gl *GL) PointParameteri(pname glbase.Enum, param int32) {
+ C.gl1_5_glPointParameteri(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPointParameterfv.xml
+func (gl *GL) PointParameterfv(pname glbase.Enum, params []float32) {
+ C.gl1_5_glPointParameterfv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPointParameterf.xml
+func (gl *GL) PointParameterf(pname glbase.Enum, param float32) {
+ C.gl1_5_glPointParameterf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiDrawArrays.xml
+func (gl *GL) MultiDrawArrays(mode glbase.Enum, first, count []int, drawcount int32) {
+ C.gl1_5_glMultiDrawArrays(gl.funcs, C.GLenum(mode), (*C.GLint)(unsafe.Pointer(&first[0])), (*C.GLsizei)(unsafe.Pointer(&count[0])), C.GLsizei(drawcount))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBlendFuncSeparate.xml
+func (gl *GL) BlendFuncSeparate(sfactorRGB, dfactorRGB, sfactorAlpha, dfactorAlpha glbase.Enum) {
+ C.gl1_5_glBlendFuncSeparate(gl.funcs, C.GLenum(sfactorRGB), C.GLenum(dfactorRGB), C.GLenum(sfactorAlpha), C.GLenum(dfactorAlpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetBufferParameteriv.xml
+func (gl *GL) GetBufferParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl1_5_glGetBufferParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glUnmapBuffer.xml
+func (gl *GL) UnmapBuffer(target glbase.Enum) bool {
+ glresult := C.gl1_5_glUnmapBuffer(gl.funcs, C.GLenum(target))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetBufferSubData.xml
+func (gl *GL) GetBufferSubData(target glbase.Enum, offset, size int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_5_glGetBufferSubData(gl.funcs, C.GLenum(target), C.GLintptr(offset), C.GLsizeiptr(size), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBufferSubData.xml
+func (gl *GL) BufferSubData(target glbase.Enum, offset, size int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_5_glBufferSubData(gl.funcs, C.GLenum(target), C.GLintptr(offset), C.GLsizeiptr(size), data_ptr)
+}
+
+// BufferData creates a new data store for the buffer object currently
+// bound to target. Any pre-existing data store is deleted. The new data
+// store is created with the specified size in bytes and usage. If data is
+// not nil, it must be a slice that is used to initialize the data store.
+// In that case the size parameter is ignored and the store size will match
+// the slice data size.
+//
+// In its initial state, the new data store is not mapped, it has a NULL
+// mapped pointer, and its mapped access is GL.READ_WRITE.
+//
+// The target constant must be one of GL.ARRAY_BUFFER, GL.COPY_READ_BUFFER,
+// GL.COPY_WRITE_BUFFER, GL.ELEMENT_ARRAY_BUFFER, GL.PIXEL_PACK_BUFFER,
+// GL.PIXEL_UNPACK_BUFFER, GL.TEXTURE_BUFFER, GL.TRANSFORM_FEEDBACK_BUFFER,
+// or GL.UNIFORM_BUFFER.
+//
+// The usage parameter is a hint to the GL implementation as to how a buffer
+// object's data store will be accessed. This enables the GL implementation
+// to make more intelligent decisions that may significantly impact buffer
+// object performance. It does not, however, constrain the actual usage of
+// the data store. usage can be broken down into two parts: first, the
+// frequency of access (modification and usage), and second, the nature of
+// that access.
+//
+// A usage frequency of STREAM and nature of DRAW is specified via the
+// constant GL.STREAM_DRAW, for example.
+//
+// The usage frequency of access may be one of:
+//
+// STREAM
+// The data store contents will be modified once and used at most a few times.
+//
+// STATIC
+// The data store contents will be modified once and used many times.
+//
+// DYNAMIC
+// The data store contents will be modified repeatedly and used many times.
+//
+// The usage nature of access may be one of:
+//
+// DRAW
+// The data store contents are modified by the application, and used as
+// the source for GL drawing and image specification commands.
+//
+// READ
+// The data store contents are modified by reading data from the GL,
+// and used to return that data when queried by the application.
+//
+// COPY
+// The data store contents are modified by reading data from the GL,
+// and used as the source for GL drawing and image specification
+// commands.
+//
+// Clients must align data elements consistent with the requirements of the
+// client platform, with an additional base-level requirement that an offset
+// within a buffer to a datum comprising N bytes be a multiple of N.
+//
+// Error GL.INVALID_ENUM is generated if target is not one of the accepted
+// buffer targets. GL.INVALID_ENUM is generated if usage is not
+// GL.STREAM_DRAW, GL.STREAM_READ, GL.STREAM_COPY, GL.STATIC_DRAW,
+// GL.STATIC_READ, GL.STATIC_COPY, GL.DYNAMIC_DRAW, GL.DYNAMIC_READ, or
+// GL.DYNAMIC_COPY. GL.INVALID_VALUE is generated if size is negative.
+// GL.INVALID_OPERATION is generated if the reserved buffer object name 0 is
+// bound to target. GL.OUT_OF_MEMORY is generated if the GL is unable to
+// create a data store with the specified size.
+func (gl *GL) BufferData(target glbase.Enum, size int, data interface{}, usage glbase.Enum) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ if data != nil {
+ size = int(data_v.Type().Size()) * data_v.Len()
+ }
+ C.gl1_5_glBufferData(gl.funcs, C.GLenum(target), C.GLsizeiptr(size), data_ptr, C.GLenum(usage))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIsBuffer.xml
+func (gl *GL) IsBuffer(buffer glbase.Buffer) bool {
+ glresult := C.gl1_5_glIsBuffer(gl.funcs, C.GLuint(buffer))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// GenBuffers returns n buffer object names. There is no guarantee that
+// the names form a contiguous set of integers; however, it is guaranteed
+// that none of the returned names was in use immediately before the call to
+// GenBuffers.
+//
+// Buffer object names returned by a call to GenBuffers are not returned by
+// subsequent calls, unless they are first deleted with DeleteBuffers.
+//
+// No buffer objects are associated with the returned buffer object names
+// until they are first bound by calling BindBuffer.
+//
+// Error GL.INVALID_VALUE is generated if n is negative. GL.INVALID_OPERATION
+// is generated if GenBuffers is executed between the execution of Begin
+// and the corresponding execution of End.
+//
+// GenBuffers is available in GL version 1.5 or greater.
+func (gl *GL) GenBuffers(n int) []glbase.Buffer {
+ if n == 0 {
+ return nil
+ }
+ buffers := make([]glbase.Buffer, n)
+ C.gl1_5_glGenBuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&buffers[0])))
+ return buffers
+}
+
+// DeleteBuffers deletes the buffer objects whose names are stored in the
+// buffers slice.
+//
+// After a buffer object is deleted, it has no contents, and its name is free
+// for reuse (for example by GenBuffers). If a buffer object that is
+// currently bound is deleted, the binding reverts to 0 (the absence of any
+// buffer object, which reverts to client memory usage).
+//
+// DeleteBuffers silently ignores 0's and names that do not correspond to
+// existing buffer objects.
+//
+// Error GL.INVALID_VALUE is generated if n is negative. GL.INVALID_OPERATION
+// is generated if DeleteBuffers is executed between the execution of Begin
+// and the corresponding execution of End.
+//
+// DeleteBuffers is available in GL version 1.5 or greater.
+func (gl *GL) DeleteBuffers(buffers []glbase.Buffer) {
+ n := len(buffers)
+ if n == 0 {
+ return
+ }
+ C.gl1_5_glDeleteBuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&buffers[0])))
+}
+
+// BindBuffer creates or puts in use a named buffer object.
+// Calling BindBuffer with target set to GL.ARRAY_BUFFER,
+// GL.ELEMENT_ARRAY_BUFFER, GL.PIXEL_PACK_BUFFER or GL.PIXEL_UNPACK_BUFFER
+// and buffer set to the name of the new buffer object binds the buffer
+// object name to the target. When a buffer object is bound to a target, the
+// previous binding for that target is automatically broken.
+//
+// Buffer object names are unsigned integers. The value zero is reserved, but
+// there is no default buffer object for each buffer object target. Instead,
+// buffer set to zero effectively unbinds any buffer object previously bound,
+// and restores client memory usage for that buffer object target. Buffer
+// object names and the corresponding buffer object contents are local to the
+// shared display-list space (see XCreateContext) of the current GL rendering
+// context; two rendering contexts share buffer object names only if they
+// also share display lists.
+//
+// GenBuffers may be called to generate a set of new buffer object names.
+//
+// The state of a buffer object immediately after it is first bound is an
+// unmapped zero-sized memory buffer with GL.READ_WRITE access and
+// GL.STATIC_DRAW usage.
+//
+// While a non-zero buffer object name is bound, GL operations on the target
+// to which it is bound affect the bound buffer object, and queries of the
+// target to which it is bound return state from the bound buffer object.
+// While buffer object name zero is bound, as in the initial state, attempts
+// to modify or query state on the target to which it is bound generates an
+// GL.INVALID_OPERATION error.
+//
+// When vertex array pointer state is changed, for example by a call to
+// NormalPointer, the current buffer object binding (GL.ARRAY_BUFFER_BINDING)
+// is copied into the corresponding client state for the vertex array type
+// being changed, for example GL.NORMAL_ARRAY_BUFFER_BINDING. While a
+// non-zero buffer object is bound to the GL.ARRAY_BUFFER target, the vertex
+// array pointer parameter that is traditionally interpreted as a pointer to
+// client-side memory is instead interpreted as an offset within the buffer
+// object measured in basic machine units.
+//
+// While a non-zero buffer object is bound to the GL.ELEMENT_ARRAY_BUFFER
+// target, the indices parameter of DrawElements, DrawRangeElements, or
+// MultiDrawElements that is traditionally interpreted as a pointer to
+// client-side memory is instead interpreted as an offset within the buffer
+// object measured in basic machine units.
+//
+// While a non-zero buffer object is bound to the GL.PIXEL_PACK_BUFFER
+// target, the following commands are affected: GetCompressedTexImage,
+// GetConvolutionFilter, GetHistogram, GetMinmax, GetPixelMap,
+// GetPolygonStipple, GetSeparableFilter, GetTexImage, and ReadPixels. The
+// pointer parameter that is traditionally interpreted as a pointer to
+// client-side memory where the pixels are to be packed is instead
+// interpreted as an offset within the buffer object measured in basic
+// machine units.
+//
+// While a non-zero buffer object is bound to the GL.PIXEL_UNPACK_BUFFER
+// target, the following commands are affected: Bitmap, ColorSubTable,
+// ColorTable, CompressedTexImage1D, CompressedTexImage2D,
+// CompressedTexImage3D, CompressedTexSubImage1D, CompressedTexSubImage2D,
+// CompressedTexSubImage3D, ConvolutionFilter1D, ConvolutionFilter2D,
+// DrawPixels, PixelMap, PolygonStipple, SeparableFilter2D, TexImage1D,
+// TexImage2D, TexImage3D, TexSubImage1D, TexSubImage2D, and TexSubImage3D.
+// The pointer parameter that is traditionally interpreted as a pointer to
+// client-side memory from which the pixels are to be unpacked is instead
+// interpreted as an offset within the buffer object measured in basic
+// machine units.
+//
+// A buffer object binding created with BindBuffer remains active until a
+// different buffer object name is bound to the same target, or until the
+// bound buffer object is deleted with DeleteBuffers.
+//
+// Once created, a named buffer object may be re-bound to any target as often
+// as needed. However, the GL implementation may make choices about how to
+// optimize the storage of a buffer object based on its initial binding
+// target.
+//
+// Error GL.INVALID_ENUM is generated if target is not one of the allowable
+// values. GL.INVALID_OPERATION is generated if BindBuffer is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// BindBuffer is available in GL version 1.5 or greater.
+func (gl *GL) BindBuffer(target glbase.Enum, buffer glbase.Buffer) {
+ C.gl1_5_glBindBuffer(gl.funcs, C.GLenum(target), C.GLuint(buffer))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetQueryObjectuiv.xml
+func (gl *GL) GetQueryObjectuiv(id uint32, pname glbase.Enum, params []uint32) {
+ C.gl1_5_glGetQueryObjectuiv(gl.funcs, C.GLuint(id), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetQueryObjectiv.xml
+func (gl *GL) GetQueryObjectiv(id uint32, pname glbase.Enum, params []int32) {
+ C.gl1_5_glGetQueryObjectiv(gl.funcs, C.GLuint(id), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetQueryiv.xml
+func (gl *GL) GetQueryiv(target, pname glbase.Enum, params []int32) {
+ C.gl1_5_glGetQueryiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEndQuery.xml
+func (gl *GL) EndQuery(target glbase.Enum) {
+ C.gl1_5_glEndQuery(gl.funcs, C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBeginQuery.xml
+func (gl *GL) BeginQuery(target glbase.Enum, id uint32) {
+ C.gl1_5_glBeginQuery(gl.funcs, C.GLenum(target), C.GLuint(id))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIsQuery.xml
+func (gl *GL) IsQuery(id uint32) bool {
+ glresult := C.gl1_5_glIsQuery(gl.funcs, C.GLuint(id))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDeleteQueries.xml
+func (gl *GL) DeleteQueries(n int, ids []uint32) {
+ C.gl1_5_glDeleteQueries(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&ids[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGenQueries.xml
+func (gl *GL) GenQueries(n int, ids []uint32) {
+ C.gl1_5_glGenQueries(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&ids[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTranslatef.xml
+func (gl *GL) Translatef(x, y, z float32) {
+ C.gl1_5_glTranslatef(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTranslated.xml
+func (gl *GL) Translated(x, y, z float64) {
+ C.gl1_5_glTranslated(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glScalef.xml
+func (gl *GL) Scalef(x, y, z float32) {
+ C.gl1_5_glScalef(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glScaled.xml
+func (gl *GL) Scaled(x, y, z float64) {
+ C.gl1_5_glScaled(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRotatef.xml
+func (gl *GL) Rotatef(angle, x, y, z float32) {
+ C.gl1_5_glRotatef(gl.funcs, C.GLfloat(angle), C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRotated.xml
+func (gl *GL) Rotated(angle, x, y, z float64) {
+ C.gl1_5_glRotated(gl.funcs, C.GLdouble(angle), C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPushMatrix.xml
+func (gl *GL) PushMatrix() {
+ C.gl1_5_glPushMatrix(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPopMatrix.xml
+func (gl *GL) PopMatrix() {
+ C.gl1_5_glPopMatrix(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glOrtho.xml
+func (gl *GL) Ortho(left, right, bottom, top, zNear, zFar float64) {
+ C.gl1_5_glOrtho(gl.funcs, C.GLdouble(left), C.GLdouble(right), C.GLdouble(bottom), C.GLdouble(top), C.GLdouble(zNear), C.GLdouble(zFar))
+}
+
+// MultMatrixd multiplies the current matrix with the provided matrix.
+//
+// The m parameter must hold 16 consecutive elements of a 4x4 column-major matrix.
+//
+// The current matrix is determined by the current matrix mode (see
+// MatrixMode). It is either the projection matrix, modelview matrix, or the
+// texture matrix.
+//
+// For example, if the current matrix is C and the coordinates to be transformed
+// are v = (v[0], v[1], v[2], v[3]), then the current transformation is C × v, or
+//
+// c[0] c[4] c[8] c[12] v[0]
+// c[1] c[5] c[9] c[13] v[1]
+// c[2] c[6] c[10] c[14] X v[2]
+// c[3] c[7] c[11] c[15] v[3]
+//
+// Calling MultMatrix with an argument of m = m[0], m[1], ..., m[15]
+// replaces the current transformation with (C X M) x v, or
+//
+// c[0] c[4] c[8] c[12] m[0] m[4] m[8] m[12] v[0]
+// c[1] c[5] c[9] c[13] m[1] m[5] m[9] m[13] v[1]
+// c[2] c[6] c[10] c[14] X m[2] m[6] m[10] m[14] X v[2]
+// c[3] c[7] c[11] c[15] m[3] m[7] m[11] m[15] v[3]
+//
+// Where 'X' denotes matrix multiplication, and v is represented as a 4x1 matrix.
+//
+// While the elements of the matrix may be specified with single or double
+// precision, the GL may store or operate on these values in less-than-single
+// precision.
+//
+// In many computer languages, 4×4 arrays are represented in row-major
+// order. The transformations just described represent these matrices in
+// column-major order. The order of the multiplication is important. For
+// example, if the current transformation is a rotation, and MultMatrix is
+// called with a translation matrix, the translation is done directly on the
+// coordinates to be transformed, while the rotation is done on the results
+// of that translation.
+//
+// GL.INVALID_OPERATION is generated if MultMatrix is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) MultMatrixd(m []float64) {
+ if len(m) != 16 {
+ panic("parameter m must have length 16 for the 4x4 matrix")
+ }
+ C.gl1_5_glMultMatrixd(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&m[0])))
+}
+
+// MultMatrixf multiplies the current matrix with the provided matrix.
+//
+// The m parameter must hold 16 consecutive elements of a 4x4 column-major matrix.
+//
+// The current matrix is determined by the current matrix mode (see
+// MatrixMode). It is either the projection matrix, modelview matrix, or the
+// texture matrix.
+//
+// For example, if the current matrix is C and the coordinates to be transformed
+// are v = (v[0], v[1], v[2], v[3]), then the current transformation is C × v, or
+//
+// c[0] c[4] c[8] c[12] v[0]
+// c[1] c[5] c[9] c[13] v[1]
+// c[2] c[6] c[10] c[14] X v[2]
+// c[3] c[7] c[11] c[15] v[3]
+//
+// Calling MultMatrix with an argument of m = m[0], m[1], ..., m[15]
+// replaces the current transformation with (C X M) x v, or
+//
+// c[0] c[4] c[8] c[12] m[0] m[4] m[8] m[12] v[0]
+// c[1] c[5] c[9] c[13] m[1] m[5] m[9] m[13] v[1]
+// c[2] c[6] c[10] c[14] X m[2] m[6] m[10] m[14] X v[2]
+// c[3] c[7] c[11] c[15] m[3] m[7] m[11] m[15] v[3]
+//
+// Where 'X' denotes matrix multiplication, and v is represented as a 4x1 matrix.
+//
+// While the elements of the matrix may be specified with single or double
+// precision, the GL may store or operate on these values in less-than-single
+// precision.
+//
+// In many computer languages, 4×4 arrays are represented in row-major
+// order. The transformations just described represent these matrices in
+// column-major order. The order of the multiplication is important. For
+// example, if the current transformation is a rotation, and MultMatrix is
+// called with a translation matrix, the translation is done directly on the
+// coordinates to be transformed, while the rotation is done on the results
+// of that translation.
+//
+// GL.INVALID_OPERATION is generated if MultMatrix is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) MultMatrixf(m []float32) {
+ if len(m) != 16 {
+ panic("parameter m must have length 16 for the 4x4 matrix")
+ }
+ C.gl1_5_glMultMatrixf(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMatrixMode.xml
+func (gl *GL) MatrixMode(mode glbase.Enum) {
+ C.gl1_5_glMatrixMode(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLoadMatrixd.xml
+func (gl *GL) LoadMatrixd(m []float64) {
+ C.gl1_5_glLoadMatrixd(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLoadMatrixf.xml
+func (gl *GL) LoadMatrixf(m []float32) {
+ C.gl1_5_glLoadMatrixf(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLoadIdentity.xml
+func (gl *GL) LoadIdentity() {
+ C.gl1_5_glLoadIdentity(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFrustum.xml
+func (gl *GL) Frustum(left, right, bottom, top, zNear, zFar float64) {
+ C.gl1_5_glFrustum(gl.funcs, C.GLdouble(left), C.GLdouble(right), C.GLdouble(bottom), C.GLdouble(top), C.GLdouble(zNear), C.GLdouble(zFar))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIsList.xml
+func (gl *GL) IsList(list uint32) bool {
+ glresult := C.gl1_5_glIsList(gl.funcs, C.GLuint(list))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexGeniv.xml
+func (gl *GL) GetTexGeniv(coord, pname glbase.Enum, params []int32) {
+ C.gl1_5_glGetTexGeniv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexGenfv.xml
+func (gl *GL) GetTexGenfv(coord, pname glbase.Enum, params []float32) {
+ C.gl1_5_glGetTexGenfv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexGendv.xml
+func (gl *GL) GetTexGendv(coord, pname glbase.Enum, params []float64) {
+ C.gl1_5_glGetTexGendv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexEnviv.xml
+func (gl *GL) GetTexEnviv(target, pname glbase.Enum, params []int32) {
+ C.gl1_5_glGetTexEnviv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexEnvfv.xml
+func (gl *GL) GetTexEnvfv(target, pname glbase.Enum, params []float32) {
+ C.gl1_5_glGetTexEnvfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetPolygonStipple.xml
+func (gl *GL) GetPolygonStipple(mask []uint8) {
+ C.gl1_5_glGetPolygonStipple(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&mask[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetPixelMapusv.xml
+func (gl *GL) GetPixelMapusv(glmap glbase.Enum, values []uint16) {
+ C.gl1_5_glGetPixelMapusv(gl.funcs, C.GLenum(glmap), (*C.GLushort)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetPixelMapuiv.xml
+func (gl *GL) GetPixelMapuiv(glmap glbase.Enum, values []uint32) {
+ C.gl1_5_glGetPixelMapuiv(gl.funcs, C.GLenum(glmap), (*C.GLuint)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetPixelMapfv.xml
+func (gl *GL) GetPixelMapfv(glmap glbase.Enum, values []float32) {
+ C.gl1_5_glGetPixelMapfv(gl.funcs, C.GLenum(glmap), (*C.GLfloat)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetMaterialiv.xml
+func (gl *GL) GetMaterialiv(face, pname glbase.Enum, params []int32) {
+ C.gl1_5_glGetMaterialiv(gl.funcs, C.GLenum(face), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetMaterialfv.xml
+func (gl *GL) GetMaterialfv(face, pname glbase.Enum, params []float32) {
+ C.gl1_5_glGetMaterialfv(gl.funcs, C.GLenum(face), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetMapiv.xml
+func (gl *GL) GetMapiv(target, query glbase.Enum, v []int32) {
+ C.gl1_5_glGetMapiv(gl.funcs, C.GLenum(target), C.GLenum(query), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetMapfv.xml
+func (gl *GL) GetMapfv(target, query glbase.Enum, v []float32) {
+ C.gl1_5_glGetMapfv(gl.funcs, C.GLenum(target), C.GLenum(query), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetMapdv.xml
+func (gl *GL) GetMapdv(target, query glbase.Enum, v []float64) {
+ C.gl1_5_glGetMapdv(gl.funcs, C.GLenum(target), C.GLenum(query), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetLightiv.xml
+func (gl *GL) GetLightiv(light, pname glbase.Enum, params []int32) {
+ C.gl1_5_glGetLightiv(gl.funcs, C.GLenum(light), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetLightfv.xml
+func (gl *GL) GetLightfv(light, pname glbase.Enum, params []float32) {
+ C.gl1_5_glGetLightfv(gl.funcs, C.GLenum(light), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetClipPlane.xml
+func (gl *GL) GetClipPlane(plane glbase.Enum, equation []float64) {
+ C.gl1_5_glGetClipPlane(gl.funcs, C.GLenum(plane), (*C.GLdouble)(unsafe.Pointer(&equation[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDrawPixels.xml
+func (gl *GL) DrawPixels(width, height int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_5_glDrawPixels(gl.funcs, C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyPixels.xml
+func (gl *GL) CopyPixels(x, y, width, height int, gltype glbase.Enum) {
+ C.gl1_5_glCopyPixels(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height), C.GLenum(gltype))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelMapusv.xml
+func (gl *GL) PixelMapusv(glmap glbase.Enum, mapsize int32, values []uint16) {
+ C.gl1_5_glPixelMapusv(gl.funcs, C.GLenum(glmap), C.GLint(mapsize), (*C.GLushort)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelMapuiv.xml
+func (gl *GL) PixelMapuiv(glmap glbase.Enum, mapsize int32, values []uint32) {
+ C.gl1_5_glPixelMapuiv(gl.funcs, C.GLenum(glmap), C.GLint(mapsize), (*C.GLuint)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelMapfv.xml
+func (gl *GL) PixelMapfv(glmap glbase.Enum, mapsize int32, values []float32) {
+ C.gl1_5_glPixelMapfv(gl.funcs, C.GLenum(glmap), C.GLint(mapsize), (*C.GLfloat)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelTransferi.xml
+func (gl *GL) PixelTransferi(pname glbase.Enum, param int32) {
+ C.gl1_5_glPixelTransferi(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelTransferf.xml
+func (gl *GL) PixelTransferf(pname glbase.Enum, param float32) {
+ C.gl1_5_glPixelTransferf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelZoom.xml
+func (gl *GL) PixelZoom(xfactor, yfactor float32) {
+ C.gl1_5_glPixelZoom(gl.funcs, C.GLfloat(xfactor), C.GLfloat(yfactor))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glAlphaFunc.xml
+func (gl *GL) AlphaFunc(glfunc glbase.Enum, ref float32) {
+ C.gl1_5_glAlphaFunc(gl.funcs, C.GLenum(glfunc), C.GLfloat(ref))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalPoint2.xml
+func (gl *GL) EvalPoint2(i, j int32) {
+ C.gl1_5_glEvalPoint2(gl.funcs, C.GLint(i), C.GLint(j))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalMesh2.xml
+func (gl *GL) EvalMesh2(mode glbase.Enum, i1, i2, j1, j2 int32) {
+ C.gl1_5_glEvalMesh2(gl.funcs, C.GLenum(mode), C.GLint(i1), C.GLint(i2), C.GLint(j1), C.GLint(j2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalPoint1.xml
+func (gl *GL) EvalPoint1(i int32) {
+ C.gl1_5_glEvalPoint1(gl.funcs, C.GLint(i))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalMesh1.xml
+func (gl *GL) EvalMesh1(mode glbase.Enum, i1, i2 int32) {
+ C.gl1_5_glEvalMesh1(gl.funcs, C.GLenum(mode), C.GLint(i1), C.GLint(i2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord2fv.xml
+func (gl *GL) EvalCoord2fv(u []float32) {
+ if len(u) != 2 {
+ panic("parameter u has incorrect length")
+ }
+ C.gl1_5_glEvalCoord2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&u[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord2f.xml
+func (gl *GL) EvalCoord2f(u, v float32) {
+ C.gl1_5_glEvalCoord2f(gl.funcs, C.GLfloat(u), C.GLfloat(v))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord2dv.xml
+func (gl *GL) EvalCoord2dv(u []float64) {
+ if len(u) != 2 {
+ panic("parameter u has incorrect length")
+ }
+ C.gl1_5_glEvalCoord2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&u[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord2d.xml
+func (gl *GL) EvalCoord2d(u, v float64) {
+ C.gl1_5_glEvalCoord2d(gl.funcs, C.GLdouble(u), C.GLdouble(v))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord1fv.xml
+func (gl *GL) EvalCoord1fv(u []float32) {
+ C.gl1_5_glEvalCoord1fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&u[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord1f.xml
+func (gl *GL) EvalCoord1f(u float32) {
+ C.gl1_5_glEvalCoord1f(gl.funcs, C.GLfloat(u))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord1dv.xml
+func (gl *GL) EvalCoord1dv(u []float64) {
+ C.gl1_5_glEvalCoord1dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&u[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord1d.xml
+func (gl *GL) EvalCoord1d(u float64) {
+ C.gl1_5_glEvalCoord1d(gl.funcs, C.GLdouble(u))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMapGrid2f.xml
+func (gl *GL) MapGrid2f(un int32, u1, u2 float32, vn int32, v1, v2 float32) {
+ C.gl1_5_glMapGrid2f(gl.funcs, C.GLint(un), C.GLfloat(u1), C.GLfloat(u2), C.GLint(vn), C.GLfloat(v1), C.GLfloat(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMapGrid2d.xml
+func (gl *GL) MapGrid2d(un int32, u1, u2 float64, vn int32, v1, v2 float64) {
+ C.gl1_5_glMapGrid2d(gl.funcs, C.GLint(un), C.GLdouble(u1), C.GLdouble(u2), C.GLint(vn), C.GLdouble(v1), C.GLdouble(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMapGrid1f.xml
+func (gl *GL) MapGrid1f(un int32, u1, u2 float32) {
+ C.gl1_5_glMapGrid1f(gl.funcs, C.GLint(un), C.GLfloat(u1), C.GLfloat(u2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMapGrid1d.xml
+func (gl *GL) MapGrid1d(un int32, u1, u2 float64) {
+ C.gl1_5_glMapGrid1d(gl.funcs, C.GLint(un), C.GLdouble(u1), C.GLdouble(u2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMap2f.xml
+func (gl *GL) Map2f(target glbase.Enum, u1, u2 float32, ustride, uorder int32, v1, v2 float32, vstride, vorder int32, points []float32) {
+ C.gl1_5_glMap2f(gl.funcs, C.GLenum(target), C.GLfloat(u1), C.GLfloat(u2), C.GLint(ustride), C.GLint(uorder), C.GLfloat(v1), C.GLfloat(v2), C.GLint(vstride), C.GLint(vorder), (*C.GLfloat)(unsafe.Pointer(&points[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMap2d.xml
+func (gl *GL) Map2d(target glbase.Enum, u1, u2 float64, ustride, uorder int32, v1, v2 float64, vstride, vorder int32, points []float64) {
+ C.gl1_5_glMap2d(gl.funcs, C.GLenum(target), C.GLdouble(u1), C.GLdouble(u2), C.GLint(ustride), C.GLint(uorder), C.GLdouble(v1), C.GLdouble(v2), C.GLint(vstride), C.GLint(vorder), (*C.GLdouble)(unsafe.Pointer(&points[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMap1f.xml
+func (gl *GL) Map1f(target glbase.Enum, u1, u2 float32, stride, order int, points []float32) {
+ C.gl1_5_glMap1f(gl.funcs, C.GLenum(target), C.GLfloat(u1), C.GLfloat(u2), C.GLint(stride), C.GLint(order), (*C.GLfloat)(unsafe.Pointer(&points[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMap1d.xml
+func (gl *GL) Map1d(target glbase.Enum, u1, u2 float64, stride, order int, points []float64) {
+ C.gl1_5_glMap1d(gl.funcs, C.GLenum(target), C.GLdouble(u1), C.GLdouble(u2), C.GLint(stride), C.GLint(order), (*C.GLdouble)(unsafe.Pointer(&points[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPushAttrib.xml
+func (gl *GL) PushAttrib(mask glbase.Bitfield) {
+ C.gl1_5_glPushAttrib(gl.funcs, C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPopAttrib.xml
+func (gl *GL) PopAttrib() {
+ C.gl1_5_glPopAttrib(gl.funcs)
+}
+
+// Accum executes an operation on the accumulation buffer.
+//
+// Parameter op defines the accumulation buffer operation (GL.ACCUM, GL.LOAD,
+// GL.ADD, GL.MULT, or GL.RETURN) and specifies how the value parameter is
+// used.
+//
+// The accumulation buffer is an extended-range color buffer. Images are not
+// rendered into it. Rather, images rendered into one of the color buffers
+// are added to the contents of the accumulation buffer after rendering.
+// Effects such as antialiasing (of points, lines, and polygons), motion
+// blur, and depth of field can be created by accumulating images generated
+// with different transformation matrices.
+//
+// Each pixel in the accumulation buffer consists of red, green, blue, and
+// alpha values. The number of bits per component in the accumulation buffer
+// depends on the implementation. You can examine this number by calling
+// GetIntegerv four times, with arguments GL.ACCUM_RED_BITS,
+// GL.ACCUM_GREEN_BITS, GL.ACCUM_BLUE_BITS, and GL.ACCUM_ALPHA_BITS.
+// Regardless of the number of bits per component, the range of values stored
+// by each component is (-1, 1). The accumulation buffer pixels are mapped
+// one-to-one with frame buffer pixels.
+//
+// All accumulation buffer operations are limited to the area of the current
+// scissor box and applied identically to the red, green, blue, and alpha
+// components of each pixel. If a Accum operation results in a value outside
+// the range (-1, 1), the contents of an accumulation buffer pixel component
+// are undefined.
+//
+// The operations are as follows:
+//
+// GL.ACCUM
+// Obtains R, G, B, and A values from the buffer currently selected for
+// reading (see ReadBuffer). Each component value is divided by 2 n -
+// 1 , where n is the number of bits allocated to each color component
+// in the currently selected buffer. The result is a floating-point
+// value in the range 0 1 , which is multiplied by value and added to
+// the corresponding pixel component in the accumulation buffer,
+// thereby updating the accumulation buffer.
+//
+// GL.LOAD
+// Similar to GL.ACCUM, except that the current value in the
+// accumulation buffer is not used in the calculation of the new value.
+// That is, the R, G, B, and A values from the currently selected
+// buffer are divided by 2 n - 1 , multiplied by value, and then stored
+// in the corresponding accumulation buffer cell, overwriting the
+// current value.
+//
+// GL.ADD
+// Adds value to each R, G, B, and A in the accumulation buffer.
+//
+// GL.MULT
+// Multiplies each R, G, B, and A in the accumulation buffer by value
+// and returns the scaled component to its corresponding accumulation
+// buffer location.
+//
+// GL.RETURN
+// Transfers accumulation buffer values to the color buffer or buffers
+// currently selected for writing. Each R, G, B, and A component is
+// multiplied by value, then multiplied by 2 n - 1 , clamped to the
+// range 0 2 n - 1 , and stored in the corresponding display buffer
+// cell. The only fragment operations that are applied to this transfer
+// are pixel ownership, scissor, dithering, and color writemasks.
+//
+// To clear the accumulation buffer, call ClearAccum with R, G, B, and A
+// values to set it to, then call Clear with the accumulation buffer
+// enabled.
+//
+// Error GL.INVALID_ENUM is generated if op is not an accepted value.
+// GL.INVALID_OPERATION is generated if there is no accumulation buffer.
+// GL.INVALID_OPERATION is generated if Accum is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) Accum(op glbase.Enum, value float32) {
+ C.gl1_5_glAccum(gl.funcs, C.GLenum(op), C.GLfloat(value))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexMask.xml
+func (gl *GL) IndexMask(mask uint32) {
+ C.gl1_5_glIndexMask(gl.funcs, C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClearIndex.xml
+func (gl *GL) ClearIndex(c float32) {
+ C.gl1_5_glClearIndex(gl.funcs, C.GLfloat(c))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClearAccum.xml
+func (gl *GL) ClearAccum(red, green, blue, alpha float32) {
+ C.gl1_5_glClearAccum(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPushName.xml
+func (gl *GL) PushName(name uint32) {
+ C.gl1_5_glPushName(gl.funcs, C.GLuint(name))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPopName.xml
+func (gl *GL) PopName() {
+ C.gl1_5_glPopName(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPassThrough.xml
+func (gl *GL) PassThrough(token float32) {
+ C.gl1_5_glPassThrough(gl.funcs, C.GLfloat(token))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLoadName.xml
+func (gl *GL) LoadName(name uint32) {
+ C.gl1_5_glLoadName(gl.funcs, C.GLuint(name))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glInitNames.xml
+func (gl *GL) InitNames() {
+ C.gl1_5_glInitNames(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRenderMode.xml
+func (gl *GL) RenderMode(mode glbase.Enum) int32 {
+ glresult := C.gl1_5_glRenderMode(gl.funcs, C.GLenum(mode))
+ return int32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSelectBuffer.xml
+func (gl *GL) SelectBuffer(size int, buffer []glbase.Buffer) {
+ C.gl1_5_glSelectBuffer(gl.funcs, C.GLsizei(size), (*C.GLuint)(unsafe.Pointer(&buffer[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFeedbackBuffer.xml
+func (gl *GL) FeedbackBuffer(size int, gltype glbase.Enum, buffer []float32) {
+ C.gl1_5_glFeedbackBuffer(gl.funcs, C.GLsizei(size), C.GLenum(gltype), (*C.GLfloat)(unsafe.Pointer(&buffer[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexGeniv.xml
+func (gl *GL) TexGeniv(coord, pname glbase.Enum, params []int32) {
+ C.gl1_5_glTexGeniv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexGeni.xml
+func (gl *GL) TexGeni(coord, pname glbase.Enum, param int32) {
+ C.gl1_5_glTexGeni(gl.funcs, C.GLenum(coord), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexGenfv.xml
+func (gl *GL) TexGenfv(coord, pname glbase.Enum, params []float32) {
+ C.gl1_5_glTexGenfv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexGenf.xml
+func (gl *GL) TexGenf(coord, pname glbase.Enum, param float32) {
+ C.gl1_5_glTexGenf(gl.funcs, C.GLenum(coord), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexGendv.xml
+func (gl *GL) TexGendv(coord, pname glbase.Enum, params []float64) {
+ C.gl1_5_glTexGendv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexGend.xml
+func (gl *GL) TexGend(coord, pname glbase.Enum, param float64) {
+ C.gl1_5_glTexGend(gl.funcs, C.GLenum(coord), C.GLenum(pname), C.GLdouble(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexEnviv.xml
+func (gl *GL) TexEnviv(target, pname glbase.Enum, params []int32) {
+ C.gl1_5_glTexEnviv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexEnvi.xml
+func (gl *GL) TexEnvi(target, pname glbase.Enum, param int32) {
+ C.gl1_5_glTexEnvi(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexEnvfv.xml
+func (gl *GL) TexEnvfv(target, pname glbase.Enum, params []float32) {
+ C.gl1_5_glTexEnvfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexEnvf.xml
+func (gl *GL) TexEnvf(target, pname glbase.Enum, param float32) {
+ C.gl1_5_glTexEnvf(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glShadeModel.xml
+func (gl *GL) ShadeModel(mode glbase.Enum) {
+ C.gl1_5_glShadeModel(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPolygonStipple.xml
+func (gl *GL) PolygonStipple(mask []uint8) {
+ C.gl1_5_glPolygonStipple(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&mask[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMaterialiv.xml
+func (gl *GL) Materialiv(face, pname glbase.Enum, params []int32) {
+ C.gl1_5_glMaterialiv(gl.funcs, C.GLenum(face), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMateriali.xml
+func (gl *GL) Materiali(face, pname glbase.Enum, param int32) {
+ C.gl1_5_glMateriali(gl.funcs, C.GLenum(face), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMaterialfv.xml
+func (gl *GL) Materialfv(face, pname glbase.Enum, params []float32) {
+ C.gl1_5_glMaterialfv(gl.funcs, C.GLenum(face), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMaterialf.xml
+func (gl *GL) Materialf(face, pname glbase.Enum, param float32) {
+ C.gl1_5_glMaterialf(gl.funcs, C.GLenum(face), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLineStipple.xml
+func (gl *GL) LineStipple(factor int32, pattern uint16) {
+ C.gl1_5_glLineStipple(gl.funcs, C.GLint(factor), C.GLushort(pattern))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLightModeliv.xml
+func (gl *GL) LightModeliv(pname glbase.Enum, params []int32) {
+ C.gl1_5_glLightModeliv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLightModeli.xml
+func (gl *GL) LightModeli(pname glbase.Enum, param int32) {
+ C.gl1_5_glLightModeli(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLightModelfv.xml
+func (gl *GL) LightModelfv(pname glbase.Enum, params []float32) {
+ C.gl1_5_glLightModelfv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLightModelf.xml
+func (gl *GL) LightModelf(pname glbase.Enum, param float32) {
+ C.gl1_5_glLightModelf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLightiv.xml
+func (gl *GL) Lightiv(light, pname glbase.Enum, params []int32) {
+ C.gl1_5_glLightiv(gl.funcs, C.GLenum(light), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLighti.xml
+func (gl *GL) Lighti(light, pname glbase.Enum, param int32) {
+ C.gl1_5_glLighti(gl.funcs, C.GLenum(light), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLightfv.xml
+func (gl *GL) Lightfv(light, pname glbase.Enum, params []float32) {
+ C.gl1_5_glLightfv(gl.funcs, C.GLenum(light), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLightf.xml
+func (gl *GL) Lightf(light, pname glbase.Enum, param float32) {
+ C.gl1_5_glLightf(gl.funcs, C.GLenum(light), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFogiv.xml
+func (gl *GL) Fogiv(pname glbase.Enum, params []int32) {
+ C.gl1_5_glFogiv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFogi.xml
+func (gl *GL) Fogi(pname glbase.Enum, param int32) {
+ C.gl1_5_glFogi(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFogfv.xml
+func (gl *GL) Fogfv(pname glbase.Enum, params []float32) {
+ C.gl1_5_glFogfv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFogf.xml
+func (gl *GL) Fogf(pname glbase.Enum, param float32) {
+ C.gl1_5_glFogf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColorMaterial.xml
+func (gl *GL) ColorMaterial(face, mode glbase.Enum) {
+ C.gl1_5_glColorMaterial(gl.funcs, C.GLenum(face), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClipPlane.xml
+func (gl *GL) ClipPlane(plane glbase.Enum, equation []float64) {
+ C.gl1_5_glClipPlane(gl.funcs, C.GLenum(plane), (*C.GLdouble)(unsafe.Pointer(&equation[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4sv.xml
+func (gl *GL) Vertex4sv(v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glVertex4sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4s.xml
+func (gl *GL) Vertex4s(x, y, z, w int16) {
+ C.gl1_5_glVertex4s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z), C.GLshort(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4iv.xml
+func (gl *GL) Vertex4iv(v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glVertex4iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4i.xml
+func (gl *GL) Vertex4i(x, y, z, w int) {
+ C.gl1_5_glVertex4i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z), C.GLint(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4fv.xml
+func (gl *GL) Vertex4fv(v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glVertex4fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4f.xml
+func (gl *GL) Vertex4f(x, y, z, w float32) {
+ C.gl1_5_glVertex4f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z), C.GLfloat(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4dv.xml
+func (gl *GL) Vertex4dv(v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glVertex4dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4d.xml
+func (gl *GL) Vertex4d(x, y, z, w float64) {
+ C.gl1_5_glVertex4d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z), C.GLdouble(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3sv.xml
+func (gl *GL) Vertex3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glVertex3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3s.xml
+func (gl *GL) Vertex3s(x, y, z int16) {
+ C.gl1_5_glVertex3s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3iv.xml
+func (gl *GL) Vertex3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glVertex3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3i.xml
+func (gl *GL) Vertex3i(x, y, z int) {
+ C.gl1_5_glVertex3i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3fv.xml
+func (gl *GL) Vertex3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glVertex3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3f.xml
+func (gl *GL) Vertex3f(x, y, z float32) {
+ C.gl1_5_glVertex3f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3dv.xml
+func (gl *GL) Vertex3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glVertex3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3d.xml
+func (gl *GL) Vertex3d(x, y, z float64) {
+ C.gl1_5_glVertex3d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2sv.xml
+func (gl *GL) Vertex2sv(v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glVertex2sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2s.xml
+func (gl *GL) Vertex2s(x, y int16) {
+ C.gl1_5_glVertex2s(gl.funcs, C.GLshort(x), C.GLshort(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2iv.xml
+func (gl *GL) Vertex2iv(v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glVertex2iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2i.xml
+func (gl *GL) Vertex2i(x, y int) {
+ C.gl1_5_glVertex2i(gl.funcs, C.GLint(x), C.GLint(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2fv.xml
+func (gl *GL) Vertex2fv(v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glVertex2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2f.xml
+func (gl *GL) Vertex2f(x, y float32) {
+ C.gl1_5_glVertex2f(gl.funcs, C.GLfloat(x), C.GLfloat(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2dv.xml
+func (gl *GL) Vertex2dv(v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glVertex2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2d.xml
+func (gl *GL) Vertex2d(x, y float64) {
+ C.gl1_5_glVertex2d(gl.funcs, C.GLdouble(x), C.GLdouble(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4sv.xml
+func (gl *GL) TexCoord4sv(v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glTexCoord4sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4s.xml
+func (gl *GL) TexCoord4s(s, t, r, q int16) {
+ C.gl1_5_glTexCoord4s(gl.funcs, C.GLshort(s), C.GLshort(t), C.GLshort(r), C.GLshort(q))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4iv.xml
+func (gl *GL) TexCoord4iv(v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glTexCoord4iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4i.xml
+func (gl *GL) TexCoord4i(s, t, r, q int32) {
+ C.gl1_5_glTexCoord4i(gl.funcs, C.GLint(s), C.GLint(t), C.GLint(r), C.GLint(q))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4fv.xml
+func (gl *GL) TexCoord4fv(v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glTexCoord4fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4f.xml
+func (gl *GL) TexCoord4f(s, t, r, q float32) {
+ C.gl1_5_glTexCoord4f(gl.funcs, C.GLfloat(s), C.GLfloat(t), C.GLfloat(r), C.GLfloat(q))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4dv.xml
+func (gl *GL) TexCoord4dv(v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glTexCoord4dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4d.xml
+func (gl *GL) TexCoord4d(s, t, r, q float64) {
+ C.gl1_5_glTexCoord4d(gl.funcs, C.GLdouble(s), C.GLdouble(t), C.GLdouble(r), C.GLdouble(q))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3sv.xml
+func (gl *GL) TexCoord3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glTexCoord3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3s.xml
+func (gl *GL) TexCoord3s(s, t, r int16) {
+ C.gl1_5_glTexCoord3s(gl.funcs, C.GLshort(s), C.GLshort(t), C.GLshort(r))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3iv.xml
+func (gl *GL) TexCoord3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glTexCoord3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3i.xml
+func (gl *GL) TexCoord3i(s, t, r int32) {
+ C.gl1_5_glTexCoord3i(gl.funcs, C.GLint(s), C.GLint(t), C.GLint(r))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3fv.xml
+func (gl *GL) TexCoord3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glTexCoord3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3f.xml
+func (gl *GL) TexCoord3f(s, t, r float32) {
+ C.gl1_5_glTexCoord3f(gl.funcs, C.GLfloat(s), C.GLfloat(t), C.GLfloat(r))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3dv.xml
+func (gl *GL) TexCoord3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glTexCoord3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3d.xml
+func (gl *GL) TexCoord3d(s, t, r float64) {
+ C.gl1_5_glTexCoord3d(gl.funcs, C.GLdouble(s), C.GLdouble(t), C.GLdouble(r))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2sv.xml
+func (gl *GL) TexCoord2sv(v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glTexCoord2sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2s.xml
+func (gl *GL) TexCoord2s(s, t int16) {
+ C.gl1_5_glTexCoord2s(gl.funcs, C.GLshort(s), C.GLshort(t))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2iv.xml
+func (gl *GL) TexCoord2iv(v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glTexCoord2iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2i.xml
+func (gl *GL) TexCoord2i(s, t int32) {
+ C.gl1_5_glTexCoord2i(gl.funcs, C.GLint(s), C.GLint(t))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2fv.xml
+func (gl *GL) TexCoord2fv(v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glTexCoord2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2f.xml
+func (gl *GL) TexCoord2f(s, t float32) {
+ C.gl1_5_glTexCoord2f(gl.funcs, C.GLfloat(s), C.GLfloat(t))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2dv.xml
+func (gl *GL) TexCoord2dv(v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glTexCoord2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2d.xml
+func (gl *GL) TexCoord2d(s, t float64) {
+ C.gl1_5_glTexCoord2d(gl.funcs, C.GLdouble(s), C.GLdouble(t))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1sv.xml
+func (gl *GL) TexCoord1sv(v []int16) {
+ C.gl1_5_glTexCoord1sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1s.xml
+func (gl *GL) TexCoord1s(s int16) {
+ C.gl1_5_glTexCoord1s(gl.funcs, C.GLshort(s))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1iv.xml
+func (gl *GL) TexCoord1iv(v []int32) {
+ C.gl1_5_glTexCoord1iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1i.xml
+func (gl *GL) TexCoord1i(s int32) {
+ C.gl1_5_glTexCoord1i(gl.funcs, C.GLint(s))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1fv.xml
+func (gl *GL) TexCoord1fv(v []float32) {
+ C.gl1_5_glTexCoord1fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1f.xml
+func (gl *GL) TexCoord1f(s float32) {
+ C.gl1_5_glTexCoord1f(gl.funcs, C.GLfloat(s))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1dv.xml
+func (gl *GL) TexCoord1dv(v []float64) {
+ C.gl1_5_glTexCoord1dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1d.xml
+func (gl *GL) TexCoord1d(s float64) {
+ C.gl1_5_glTexCoord1d(gl.funcs, C.GLdouble(s))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRectsv.xml
+func (gl *GL) Rectsv(v1, v2 []int16) {
+ C.gl1_5_glRectsv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v1[0])), (*C.GLshort)(unsafe.Pointer(&v2[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRects.xml
+func (gl *GL) Rects(x1, y1, x2, y2 int16) {
+ C.gl1_5_glRects(gl.funcs, C.GLshort(x1), C.GLshort(y1), C.GLshort(x2), C.GLshort(y2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRectiv.xml
+func (gl *GL) Rectiv(v1, v2 []int32) {
+ C.gl1_5_glRectiv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v1[0])), (*C.GLint)(unsafe.Pointer(&v2[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRecti.xml
+func (gl *GL) Recti(x1, y1, x2, y2 int32) {
+ C.gl1_5_glRecti(gl.funcs, C.GLint(x1), C.GLint(y1), C.GLint(x2), C.GLint(y2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRectfv.xml
+func (gl *GL) Rectfv(v1, v2 []float32) {
+ C.gl1_5_glRectfv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v1[0])), (*C.GLfloat)(unsafe.Pointer(&v2[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRectf.xml
+func (gl *GL) Rectf(x1, y1, x2, y2 float32) {
+ C.gl1_5_glRectf(gl.funcs, C.GLfloat(x1), C.GLfloat(y1), C.GLfloat(x2), C.GLfloat(y2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRectdv.xml
+func (gl *GL) Rectdv(v1, v2 []float64) {
+ C.gl1_5_glRectdv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v1[0])), (*C.GLdouble)(unsafe.Pointer(&v2[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRectd.xml
+func (gl *GL) Rectd(x1, y1, x2, y2 float64) {
+ C.gl1_5_glRectd(gl.funcs, C.GLdouble(x1), C.GLdouble(y1), C.GLdouble(x2), C.GLdouble(y2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4sv.xml
+func (gl *GL) RasterPos4sv(v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glRasterPos4sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4s.xml
+func (gl *GL) RasterPos4s(x, y, z, w int16) {
+ C.gl1_5_glRasterPos4s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z), C.GLshort(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4iv.xml
+func (gl *GL) RasterPos4iv(v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glRasterPos4iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4i.xml
+func (gl *GL) RasterPos4i(x, y, z, w int) {
+ C.gl1_5_glRasterPos4i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z), C.GLint(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4fv.xml
+func (gl *GL) RasterPos4fv(v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glRasterPos4fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4f.xml
+func (gl *GL) RasterPos4f(x, y, z, w float32) {
+ C.gl1_5_glRasterPos4f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z), C.GLfloat(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4dv.xml
+func (gl *GL) RasterPos4dv(v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glRasterPos4dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4d.xml
+func (gl *GL) RasterPos4d(x, y, z, w float64) {
+ C.gl1_5_glRasterPos4d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z), C.GLdouble(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3sv.xml
+func (gl *GL) RasterPos3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glRasterPos3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3s.xml
+func (gl *GL) RasterPos3s(x, y, z int16) {
+ C.gl1_5_glRasterPos3s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3iv.xml
+func (gl *GL) RasterPos3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glRasterPos3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3i.xml
+func (gl *GL) RasterPos3i(x, y, z int) {
+ C.gl1_5_glRasterPos3i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3fv.xml
+func (gl *GL) RasterPos3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glRasterPos3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3f.xml
+func (gl *GL) RasterPos3f(x, y, z float32) {
+ C.gl1_5_glRasterPos3f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3dv.xml
+func (gl *GL) RasterPos3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glRasterPos3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3d.xml
+func (gl *GL) RasterPos3d(x, y, z float64) {
+ C.gl1_5_glRasterPos3d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2sv.xml
+func (gl *GL) RasterPos2sv(v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glRasterPos2sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2s.xml
+func (gl *GL) RasterPos2s(x, y int16) {
+ C.gl1_5_glRasterPos2s(gl.funcs, C.GLshort(x), C.GLshort(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2iv.xml
+func (gl *GL) RasterPos2iv(v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glRasterPos2iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2i.xml
+func (gl *GL) RasterPos2i(x, y int) {
+ C.gl1_5_glRasterPos2i(gl.funcs, C.GLint(x), C.GLint(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2fv.xml
+func (gl *GL) RasterPos2fv(v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glRasterPos2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2f.xml
+func (gl *GL) RasterPos2f(x, y float32) {
+ C.gl1_5_glRasterPos2f(gl.funcs, C.GLfloat(x), C.GLfloat(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2dv.xml
+func (gl *GL) RasterPos2dv(v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glRasterPos2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2d.xml
+func (gl *GL) RasterPos2d(x, y float64) {
+ C.gl1_5_glRasterPos2d(gl.funcs, C.GLdouble(x), C.GLdouble(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3sv.xml
+func (gl *GL) Normal3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glNormal3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3s.xml
+func (gl *GL) Normal3s(nx, ny, nz int16) {
+ C.gl1_5_glNormal3s(gl.funcs, C.GLshort(nx), C.GLshort(ny), C.GLshort(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3iv.xml
+func (gl *GL) Normal3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glNormal3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3i.xml
+func (gl *GL) Normal3i(nx, ny, nz int32) {
+ C.gl1_5_glNormal3i(gl.funcs, C.GLint(nx), C.GLint(ny), C.GLint(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3fv.xml
+func (gl *GL) Normal3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glNormal3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3f.xml
+func (gl *GL) Normal3f(nx, ny, nz float32) {
+ C.gl1_5_glNormal3f(gl.funcs, C.GLfloat(nx), C.GLfloat(ny), C.GLfloat(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3dv.xml
+func (gl *GL) Normal3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glNormal3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3d.xml
+func (gl *GL) Normal3d(nx, ny, nz float64) {
+ C.gl1_5_glNormal3d(gl.funcs, C.GLdouble(nx), C.GLdouble(ny), C.GLdouble(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3bv.xml
+func (gl *GL) Normal3bv(v []byte) {
+ C.gl1_5_glNormal3bv(gl.funcs, (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3b.xml
+func (gl *GL) Normal3b(nx, ny, nz byte) {
+ C.gl1_5_glNormal3b(gl.funcs, C.GLbyte(nx), C.GLbyte(ny), C.GLbyte(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexsv.xml
+func (gl *GL) Indexsv(c []int16) {
+ C.gl1_5_glIndexsv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexs.xml
+func (gl *GL) Indexs(c int16) {
+ C.gl1_5_glIndexs(gl.funcs, C.GLshort(c))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexiv.xml
+func (gl *GL) Indexiv(c []int32) {
+ C.gl1_5_glIndexiv(gl.funcs, (*C.GLint)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexi.xml
+func (gl *GL) Indexi(c int32) {
+ C.gl1_5_glIndexi(gl.funcs, C.GLint(c))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexfv.xml
+func (gl *GL) Indexfv(c []float32) {
+ C.gl1_5_glIndexfv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexf.xml
+func (gl *GL) Indexf(c float32) {
+ C.gl1_5_glIndexf(gl.funcs, C.GLfloat(c))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexdv.xml
+func (gl *GL) Indexdv(c []float64) {
+ C.gl1_5_glIndexdv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexd.xml
+func (gl *GL) Indexd(c float64) {
+ C.gl1_5_glIndexd(gl.funcs, C.GLdouble(c))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEnd.xml
+func (gl *GL) End() {
+ C.gl1_5_glEnd(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEdgeFlagv.xml
+func (gl *GL) EdgeFlagv(flag []bool) {
+ C.gl1_5_glEdgeFlagv(gl.funcs, (*C.GLboolean)(unsafe.Pointer(&flag[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEdgeFlag.xml
+func (gl *GL) EdgeFlag(flag bool) {
+ C.gl1_5_glEdgeFlag(gl.funcs, *(*C.GLboolean)(unsafe.Pointer(&flag)))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4usv.xml
+func (gl *GL) Color4usv(v []uint16) {
+ C.gl1_5_glColor4usv(gl.funcs, (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4us.xml
+func (gl *GL) Color4us(red, green, blue, alpha uint16) {
+ C.gl1_5_glColor4us(gl.funcs, C.GLushort(red), C.GLushort(green), C.GLushort(blue), C.GLushort(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4uiv.xml
+func (gl *GL) Color4uiv(v []uint32) {
+ C.gl1_5_glColor4uiv(gl.funcs, (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4ui.xml
+func (gl *GL) Color4ui(red, green, blue, alpha uint32) {
+ C.gl1_5_glColor4ui(gl.funcs, C.GLuint(red), C.GLuint(green), C.GLuint(blue), C.GLuint(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4ubv.xml
+func (gl *GL) Color4ubv(v []uint8) {
+ C.gl1_5_glColor4ubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4ub.xml
+func (gl *GL) Color4ub(red, green, blue, alpha uint8) {
+ C.gl1_5_glColor4ub(gl.funcs, C.GLubyte(red), C.GLubyte(green), C.GLubyte(blue), C.GLubyte(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4sv.xml
+func (gl *GL) Color4sv(v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glColor4sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4s.xml
+func (gl *GL) Color4s(red, green, blue, alpha int16) {
+ C.gl1_5_glColor4s(gl.funcs, C.GLshort(red), C.GLshort(green), C.GLshort(blue), C.GLshort(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4iv.xml
+func (gl *GL) Color4iv(v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glColor4iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4i.xml
+func (gl *GL) Color4i(red, green, blue, alpha int32) {
+ C.gl1_5_glColor4i(gl.funcs, C.GLint(red), C.GLint(green), C.GLint(blue), C.GLint(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4fv.xml
+func (gl *GL) Color4fv(v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glColor4fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4f.xml
+func (gl *GL) Color4f(red, green, blue, alpha float32) {
+ C.gl1_5_glColor4f(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4dv.xml
+func (gl *GL) Color4dv(v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glColor4dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4d.xml
+func (gl *GL) Color4d(red, green, blue, alpha float64) {
+ C.gl1_5_glColor4d(gl.funcs, C.GLdouble(red), C.GLdouble(green), C.GLdouble(blue), C.GLdouble(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4bv.xml
+func (gl *GL) Color4bv(v []byte) {
+ C.gl1_5_glColor4bv(gl.funcs, (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4b.xml
+func (gl *GL) Color4b(red, green, blue, alpha byte) {
+ C.gl1_5_glColor4b(gl.funcs, C.GLbyte(red), C.GLbyte(green), C.GLbyte(blue), C.GLbyte(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3usv.xml
+func (gl *GL) Color3usv(v []uint16) {
+ C.gl1_5_glColor3usv(gl.funcs, (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3us.xml
+func (gl *GL) Color3us(red, green, blue uint16) {
+ C.gl1_5_glColor3us(gl.funcs, C.GLushort(red), C.GLushort(green), C.GLushort(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3uiv.xml
+func (gl *GL) Color3uiv(v []uint32) {
+ C.gl1_5_glColor3uiv(gl.funcs, (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3ui.xml
+func (gl *GL) Color3ui(red, green, blue uint32) {
+ C.gl1_5_glColor3ui(gl.funcs, C.GLuint(red), C.GLuint(green), C.GLuint(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3ubv.xml
+func (gl *GL) Color3ubv(v []uint8) {
+ C.gl1_5_glColor3ubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3ub.xml
+func (gl *GL) Color3ub(red, green, blue uint8) {
+ C.gl1_5_glColor3ub(gl.funcs, C.GLubyte(red), C.GLubyte(green), C.GLubyte(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3sv.xml
+func (gl *GL) Color3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glColor3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3s.xml
+func (gl *GL) Color3s(red, green, blue int16) {
+ C.gl1_5_glColor3s(gl.funcs, C.GLshort(red), C.GLshort(green), C.GLshort(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3iv.xml
+func (gl *GL) Color3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glColor3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3i.xml
+func (gl *GL) Color3i(red, green, blue int32) {
+ C.gl1_5_glColor3i(gl.funcs, C.GLint(red), C.GLint(green), C.GLint(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3fv.xml
+func (gl *GL) Color3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glColor3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3f.xml
+func (gl *GL) Color3f(red, green, blue float32) {
+ C.gl1_5_glColor3f(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3dv.xml
+func (gl *GL) Color3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glColor3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3d.xml
+func (gl *GL) Color3d(red, green, blue float64) {
+ C.gl1_5_glColor3d(gl.funcs, C.GLdouble(red), C.GLdouble(green), C.GLdouble(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3bv.xml
+func (gl *GL) Color3bv(v []byte) {
+ C.gl1_5_glColor3bv(gl.funcs, (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3b.xml
+func (gl *GL) Color3b(red, green, blue byte) {
+ C.gl1_5_glColor3b(gl.funcs, C.GLbyte(red), C.GLbyte(green), C.GLbyte(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBitmap.xml
+func (gl *GL) Bitmap(width, height int, xorig, yorig, xmove, ymove float32, bitmap []uint8) {
+ C.gl1_5_glBitmap(gl.funcs, C.GLsizei(width), C.GLsizei(height), C.GLfloat(xorig), C.GLfloat(yorig), C.GLfloat(xmove), C.GLfloat(ymove), (*C.GLubyte)(unsafe.Pointer(&bitmap[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBegin.xml
+func (gl *GL) Begin(mode glbase.Enum) {
+ C.gl1_5_glBegin(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glListBase.xml
+func (gl *GL) ListBase(base uint32) {
+ C.gl1_5_glListBase(gl.funcs, C.GLuint(base))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGenLists.xml
+func (gl *GL) GenLists(range_ int32) uint32 {
+ glresult := C.gl1_5_glGenLists(gl.funcs, C.GLsizei(range_))
+ return uint32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDeleteLists.xml
+func (gl *GL) DeleteLists(list uint32, range_ int32) {
+ C.gl1_5_glDeleteLists(gl.funcs, C.GLuint(list), C.GLsizei(range_))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCallLists.xml
+func (gl *GL) CallLists(n int, gltype glbase.Enum, lists interface{}) {
+ var lists_ptr unsafe.Pointer
+ var lists_v = reflect.ValueOf(lists)
+ if lists != nil && lists_v.Kind() != reflect.Slice {
+ panic("parameter lists must be a slice")
+ }
+ if lists != nil {
+ lists_ptr = unsafe.Pointer(lists_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_5_glCallLists(gl.funcs, C.GLsizei(n), C.GLenum(gltype), lists_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCallList.xml
+func (gl *GL) CallList(list uint32) {
+ C.gl1_5_glCallList(gl.funcs, C.GLuint(list))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEndList.xml
+func (gl *GL) EndList() {
+ C.gl1_5_glEndList(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNewList.xml
+func (gl *GL) NewList(list uint32, mode glbase.Enum) {
+ C.gl1_5_glNewList(gl.funcs, C.GLuint(list), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPushClientAttrib.xml
+func (gl *GL) PushClientAttrib(mask glbase.Bitfield) {
+ C.gl1_5_glPushClientAttrib(gl.funcs, C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPopClientAttrib.xml
+func (gl *GL) PopClientAttrib() {
+ C.gl1_5_glPopClientAttrib(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPrioritizeTextures.xml
+func (gl *GL) PrioritizeTextures(n int, textures []glbase.Texture, priorities []float32) {
+ C.gl1_5_glPrioritizeTextures(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])), (*C.GLfloat)(unsafe.Pointer(&priorities[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glAreTexturesResident.xml
+func (gl *GL) AreTexturesResident(n int, textures []glbase.Texture, residences []bool) bool {
+ glresult := C.gl1_5_glAreTexturesResident(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])), (*C.GLboolean)(unsafe.Pointer(&residences[0])))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexPointer.xml
+func (gl *GL) VertexPointer(size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_5_glVertexPointer(gl.funcs, C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoordPointer.xml
+func (gl *GL) TexCoordPointer(size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_5_glTexCoordPointer(gl.funcs, C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormalPointer.xml
+func (gl *GL) NormalPointer(gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_5_glNormalPointer(gl.funcs, C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glInterleavedArrays.xml
+func (gl *GL) InterleavedArrays(format glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_5_glInterleavedArrays(gl.funcs, C.GLenum(format), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexPointer.xml
+func (gl *GL) IndexPointer(gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_5_glIndexPointer(gl.funcs, C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEnableClientState.xml
+func (gl *GL) EnableClientState(array glbase.Enum) {
+ C.gl1_5_glEnableClientState(gl.funcs, C.GLenum(array))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEdgeFlagPointer.xml
+func (gl *GL) EdgeFlagPointer(stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_5_glEdgeFlagPointer(gl.funcs, C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDisableClientState.xml
+func (gl *GL) DisableClientState(array glbase.Enum) {
+ C.gl1_5_glDisableClientState(gl.funcs, C.GLenum(array))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColorPointer.xml
+func (gl *GL) ColorPointer(size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_5_glColorPointer(gl.funcs, C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glArrayElement.xml
+func (gl *GL) ArrayElement(i int32) {
+ C.gl1_5_glArrayElement(gl.funcs, C.GLint(i))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glResetMinmax.xml
+func (gl *GL) ResetMinmax(target glbase.Enum) {
+ C.gl1_5_glResetMinmax(gl.funcs, C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glResetHistogram.xml
+func (gl *GL) ResetHistogram(target glbase.Enum) {
+ C.gl1_5_glResetHistogram(gl.funcs, C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMinmax.xml
+func (gl *GL) Minmax(target, internalFormat glbase.Enum, sink bool) {
+ C.gl1_5_glMinmax(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), *(*C.GLboolean)(unsafe.Pointer(&sink)))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glHistogram.xml
+func (gl *GL) Histogram(target glbase.Enum, width int, internalFormat glbase.Enum, sink bool) {
+ C.gl1_5_glHistogram(gl.funcs, C.GLenum(target), C.GLsizei(width), C.GLenum(internalFormat), *(*C.GLboolean)(unsafe.Pointer(&sink)))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetMinmaxParameteriv.xml
+func (gl *GL) GetMinmaxParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl1_5_glGetMinmaxParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetMinmaxParameterfv.xml
+func (gl *GL) GetMinmaxParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl1_5_glGetMinmaxParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetMinmax.xml
+func (gl *GL) GetMinmax(target glbase.Enum, reset bool, format, gltype glbase.Enum, values interface{}) {
+ var values_ptr unsafe.Pointer
+ var values_v = reflect.ValueOf(values)
+ if values != nil && values_v.Kind() != reflect.Slice {
+ panic("parameter values must be a slice")
+ }
+ if values != nil {
+ values_ptr = unsafe.Pointer(values_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_5_glGetMinmax(gl.funcs, C.GLenum(target), *(*C.GLboolean)(unsafe.Pointer(&reset)), C.GLenum(format), C.GLenum(gltype), values_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetHistogramParameteriv.xml
+func (gl *GL) GetHistogramParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl1_5_glGetHistogramParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetHistogramParameterfv.xml
+func (gl *GL) GetHistogramParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl1_5_glGetHistogramParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetHistogram.xml
+func (gl *GL) GetHistogram(target glbase.Enum, reset bool, format, gltype glbase.Enum, values interface{}) {
+ var values_ptr unsafe.Pointer
+ var values_v = reflect.ValueOf(values)
+ if values != nil && values_v.Kind() != reflect.Slice {
+ panic("parameter values must be a slice")
+ }
+ if values != nil {
+ values_ptr = unsafe.Pointer(values_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_5_glGetHistogram(gl.funcs, C.GLenum(target), *(*C.GLboolean)(unsafe.Pointer(&reset)), C.GLenum(format), C.GLenum(gltype), values_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSeparableFilter2D.xml
+func (gl *GL) SeparableFilter2D(target, internalFormat glbase.Enum, width, height int, format, gltype glbase.Enum, row, column interface{}) {
+ var row_ptr unsafe.Pointer
+ var row_v = reflect.ValueOf(row)
+ if row != nil && row_v.Kind() != reflect.Slice {
+ panic("parameter row must be a slice")
+ }
+ if row != nil {
+ row_ptr = unsafe.Pointer(row_v.Index(0).Addr().Pointer())
+ }
+ var column_ptr unsafe.Pointer
+ var column_v = reflect.ValueOf(column)
+ if column != nil && column_v.Kind() != reflect.Slice {
+ panic("parameter column must be a slice")
+ }
+ if column != nil {
+ column_ptr = unsafe.Pointer(column_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_5_glSeparableFilter2D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), row_ptr, column_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetSeparableFilter.xml
+func (gl *GL) GetSeparableFilter(target, format, gltype glbase.Enum, row, column, span interface{}) {
+ var row_ptr unsafe.Pointer
+ var row_v = reflect.ValueOf(row)
+ if row != nil && row_v.Kind() != reflect.Slice {
+ panic("parameter row must be a slice")
+ }
+ if row != nil {
+ row_ptr = unsafe.Pointer(row_v.Index(0).Addr().Pointer())
+ }
+ var column_ptr unsafe.Pointer
+ var column_v = reflect.ValueOf(column)
+ if column != nil && column_v.Kind() != reflect.Slice {
+ panic("parameter column must be a slice")
+ }
+ if column != nil {
+ column_ptr = unsafe.Pointer(column_v.Index(0).Addr().Pointer())
+ }
+ var span_ptr unsafe.Pointer
+ var span_v = reflect.ValueOf(span)
+ if span != nil && span_v.Kind() != reflect.Slice {
+ panic("parameter span must be a slice")
+ }
+ if span != nil {
+ span_ptr = unsafe.Pointer(span_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_5_glGetSeparableFilter(gl.funcs, C.GLenum(target), C.GLenum(format), C.GLenum(gltype), row_ptr, column_ptr, span_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetConvolutionParameteriv.xml
+func (gl *GL) GetConvolutionParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl1_5_glGetConvolutionParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetConvolutionParameterfv.xml
+func (gl *GL) GetConvolutionParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl1_5_glGetConvolutionParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetConvolutionFilter.xml
+func (gl *GL) GetConvolutionFilter(target, format, gltype glbase.Enum, image interface{}) {
+ var image_ptr unsafe.Pointer
+ var image_v = reflect.ValueOf(image)
+ if image != nil && image_v.Kind() != reflect.Slice {
+ panic("parameter image must be a slice")
+ }
+ if image != nil {
+ image_ptr = unsafe.Pointer(image_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_5_glGetConvolutionFilter(gl.funcs, C.GLenum(target), C.GLenum(format), C.GLenum(gltype), image_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyConvolutionFilter2D.xml
+func (gl *GL) CopyConvolutionFilter2D(target, internalFormat glbase.Enum, x, y, width, height int) {
+ C.gl1_5_glCopyConvolutionFilter2D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyConvolutionFilter1D.xml
+func (gl *GL) CopyConvolutionFilter1D(target, internalFormat glbase.Enum, x, y, width int) {
+ C.gl1_5_glCopyConvolutionFilter1D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glConvolutionParameteriv.xml
+func (gl *GL) ConvolutionParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl1_5_glConvolutionParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glConvolutionParameteri.xml
+func (gl *GL) ConvolutionParameteri(target, pname glbase.Enum, params int32) {
+ C.gl1_5_glConvolutionParameteri(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLint(params))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glConvolutionParameterfv.xml
+func (gl *GL) ConvolutionParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl1_5_glConvolutionParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glConvolutionParameterf.xml
+func (gl *GL) ConvolutionParameterf(target, pname glbase.Enum, params float32) {
+ C.gl1_5_glConvolutionParameterf(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLfloat(params))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glConvolutionFilter2D.xml
+func (gl *GL) ConvolutionFilter2D(target, internalFormat glbase.Enum, width, height int, format, gltype glbase.Enum, image interface{}) {
+ var image_ptr unsafe.Pointer
+ var image_v = reflect.ValueOf(image)
+ if image != nil && image_v.Kind() != reflect.Slice {
+ panic("parameter image must be a slice")
+ }
+ if image != nil {
+ image_ptr = unsafe.Pointer(image_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_5_glConvolutionFilter2D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), image_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glConvolutionFilter1D.xml
+func (gl *GL) ConvolutionFilter1D(target, internalFormat glbase.Enum, width int, format, gltype glbase.Enum, image interface{}) {
+ var image_ptr unsafe.Pointer
+ var image_v = reflect.ValueOf(image)
+ if image != nil && image_v.Kind() != reflect.Slice {
+ panic("parameter image must be a slice")
+ }
+ if image != nil {
+ image_ptr = unsafe.Pointer(image_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_5_glConvolutionFilter1D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLenum(format), C.GLenum(gltype), image_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyColorSubTable.xml
+func (gl *GL) CopyColorSubTable(target glbase.Enum, start int32, x, y, width int) {
+ C.gl1_5_glCopyColorSubTable(gl.funcs, C.GLenum(target), C.GLsizei(start), C.GLint(x), C.GLint(y), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColorSubTable.xml
+func (gl *GL) ColorSubTable(target glbase.Enum, start int32, count int, format, gltype glbase.Enum, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_5_glColorSubTable(gl.funcs, C.GLenum(target), C.GLsizei(start), C.GLsizei(count), C.GLenum(format), C.GLenum(gltype), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetColorTableParameteriv.xml
+func (gl *GL) GetColorTableParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl1_5_glGetColorTableParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetColorTableParameterfv.xml
+func (gl *GL) GetColorTableParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl1_5_glGetColorTableParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetColorTable.xml
+func (gl *GL) GetColorTable(target, format, gltype glbase.Enum, table interface{}) {
+ var table_ptr unsafe.Pointer
+ var table_v = reflect.ValueOf(table)
+ if table != nil && table_v.Kind() != reflect.Slice {
+ panic("parameter table must be a slice")
+ }
+ if table != nil {
+ table_ptr = unsafe.Pointer(table_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_5_glGetColorTable(gl.funcs, C.GLenum(target), C.GLenum(format), C.GLenum(gltype), table_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyColorTable.xml
+func (gl *GL) CopyColorTable(target, internalFormat glbase.Enum, x, y, width int) {
+ C.gl1_5_glCopyColorTable(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColorTableParameteriv.xml
+func (gl *GL) ColorTableParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl1_5_glColorTableParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColorTableParameterfv.xml
+func (gl *GL) ColorTableParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl1_5_glColorTableParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColorTable.xml
+func (gl *GL) ColorTable(target, internalFormat glbase.Enum, width int, format, gltype glbase.Enum, table interface{}) {
+ var table_ptr unsafe.Pointer
+ var table_v = reflect.ValueOf(table)
+ if table != nil && table_v.Kind() != reflect.Slice {
+ panic("parameter table must be a slice")
+ }
+ if table != nil {
+ table_ptr = unsafe.Pointer(table_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_5_glColorTable(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLenum(format), C.GLenum(gltype), table_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultTransposeMatrixd.xml
+func (gl *GL) MultTransposeMatrixd(m []float64) {
+ C.gl1_5_glMultTransposeMatrixd(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultTransposeMatrixf.xml
+func (gl *GL) MultTransposeMatrixf(m []float32) {
+ C.gl1_5_glMultTransposeMatrixf(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLoadTransposeMatrixd.xml
+func (gl *GL) LoadTransposeMatrixd(m []float64) {
+ C.gl1_5_glLoadTransposeMatrixd(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLoadTransposeMatrixf.xml
+func (gl *GL) LoadTransposeMatrixf(m []float32) {
+ C.gl1_5_glLoadTransposeMatrixf(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord4sv.xml
+func (gl *GL) MultiTexCoord4sv(target glbase.Enum, v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glMultiTexCoord4sv(gl.funcs, C.GLenum(target), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord4s.xml
+func (gl *GL) MultiTexCoord4s(target glbase.Enum, s, t, r, q int16) {
+ C.gl1_5_glMultiTexCoord4s(gl.funcs, C.GLenum(target), C.GLshort(s), C.GLshort(t), C.GLshort(r), C.GLshort(q))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord4iv.xml
+func (gl *GL) MultiTexCoord4iv(target glbase.Enum, v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glMultiTexCoord4iv(gl.funcs, C.GLenum(target), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord4i.xml
+func (gl *GL) MultiTexCoord4i(target glbase.Enum, s, t, r, q int32) {
+ C.gl1_5_glMultiTexCoord4i(gl.funcs, C.GLenum(target), C.GLint(s), C.GLint(t), C.GLint(r), C.GLint(q))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord4fv.xml
+func (gl *GL) MultiTexCoord4fv(target glbase.Enum, v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glMultiTexCoord4fv(gl.funcs, C.GLenum(target), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord4f.xml
+func (gl *GL) MultiTexCoord4f(target glbase.Enum, s, t, r, q float32) {
+ C.gl1_5_glMultiTexCoord4f(gl.funcs, C.GLenum(target), C.GLfloat(s), C.GLfloat(t), C.GLfloat(r), C.GLfloat(q))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord4dv.xml
+func (gl *GL) MultiTexCoord4dv(target glbase.Enum, v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glMultiTexCoord4dv(gl.funcs, C.GLenum(target), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord4d.xml
+func (gl *GL) MultiTexCoord4d(target glbase.Enum, s, t, r, q float64) {
+ C.gl1_5_glMultiTexCoord4d(gl.funcs, C.GLenum(target), C.GLdouble(s), C.GLdouble(t), C.GLdouble(r), C.GLdouble(q))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord3sv.xml
+func (gl *GL) MultiTexCoord3sv(target glbase.Enum, v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glMultiTexCoord3sv(gl.funcs, C.GLenum(target), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord3s.xml
+func (gl *GL) MultiTexCoord3s(target glbase.Enum, s, t, r int16) {
+ C.gl1_5_glMultiTexCoord3s(gl.funcs, C.GLenum(target), C.GLshort(s), C.GLshort(t), C.GLshort(r))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord3iv.xml
+func (gl *GL) MultiTexCoord3iv(target glbase.Enum, v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glMultiTexCoord3iv(gl.funcs, C.GLenum(target), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord3i.xml
+func (gl *GL) MultiTexCoord3i(target glbase.Enum, s, t, r int32) {
+ C.gl1_5_glMultiTexCoord3i(gl.funcs, C.GLenum(target), C.GLint(s), C.GLint(t), C.GLint(r))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord3fv.xml
+func (gl *GL) MultiTexCoord3fv(target glbase.Enum, v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glMultiTexCoord3fv(gl.funcs, C.GLenum(target), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord3f.xml
+func (gl *GL) MultiTexCoord3f(target glbase.Enum, s, t, r float32) {
+ C.gl1_5_glMultiTexCoord3f(gl.funcs, C.GLenum(target), C.GLfloat(s), C.GLfloat(t), C.GLfloat(r))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord3dv.xml
+func (gl *GL) MultiTexCoord3dv(target glbase.Enum, v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glMultiTexCoord3dv(gl.funcs, C.GLenum(target), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord3d.xml
+func (gl *GL) MultiTexCoord3d(target glbase.Enum, s, t, r float64) {
+ C.gl1_5_glMultiTexCoord3d(gl.funcs, C.GLenum(target), C.GLdouble(s), C.GLdouble(t), C.GLdouble(r))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord2sv.xml
+func (gl *GL) MultiTexCoord2sv(target glbase.Enum, v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glMultiTexCoord2sv(gl.funcs, C.GLenum(target), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord2s.xml
+func (gl *GL) MultiTexCoord2s(target glbase.Enum, s, t int16) {
+ C.gl1_5_glMultiTexCoord2s(gl.funcs, C.GLenum(target), C.GLshort(s), C.GLshort(t))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord2iv.xml
+func (gl *GL) MultiTexCoord2iv(target glbase.Enum, v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glMultiTexCoord2iv(gl.funcs, C.GLenum(target), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord2i.xml
+func (gl *GL) MultiTexCoord2i(target glbase.Enum, s, t int32) {
+ C.gl1_5_glMultiTexCoord2i(gl.funcs, C.GLenum(target), C.GLint(s), C.GLint(t))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord2fv.xml
+func (gl *GL) MultiTexCoord2fv(target glbase.Enum, v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glMultiTexCoord2fv(gl.funcs, C.GLenum(target), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord2f.xml
+func (gl *GL) MultiTexCoord2f(target glbase.Enum, s, t float32) {
+ C.gl1_5_glMultiTexCoord2f(gl.funcs, C.GLenum(target), C.GLfloat(s), C.GLfloat(t))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord2dv.xml
+func (gl *GL) MultiTexCoord2dv(target glbase.Enum, v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glMultiTexCoord2dv(gl.funcs, C.GLenum(target), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord2d.xml
+func (gl *GL) MultiTexCoord2d(target glbase.Enum, s, t float64) {
+ C.gl1_5_glMultiTexCoord2d(gl.funcs, C.GLenum(target), C.GLdouble(s), C.GLdouble(t))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord1sv.xml
+func (gl *GL) MultiTexCoord1sv(target glbase.Enum, v []int16) {
+ C.gl1_5_glMultiTexCoord1sv(gl.funcs, C.GLenum(target), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord1s.xml
+func (gl *GL) MultiTexCoord1s(target glbase.Enum, s int16) {
+ C.gl1_5_glMultiTexCoord1s(gl.funcs, C.GLenum(target), C.GLshort(s))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord1iv.xml
+func (gl *GL) MultiTexCoord1iv(target glbase.Enum, v []int32) {
+ C.gl1_5_glMultiTexCoord1iv(gl.funcs, C.GLenum(target), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord1i.xml
+func (gl *GL) MultiTexCoord1i(target glbase.Enum, s int32) {
+ C.gl1_5_glMultiTexCoord1i(gl.funcs, C.GLenum(target), C.GLint(s))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord1fv.xml
+func (gl *GL) MultiTexCoord1fv(target glbase.Enum, v []float32) {
+ C.gl1_5_glMultiTexCoord1fv(gl.funcs, C.GLenum(target), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord1f.xml
+func (gl *GL) MultiTexCoord1f(target glbase.Enum, s float32) {
+ C.gl1_5_glMultiTexCoord1f(gl.funcs, C.GLenum(target), C.GLfloat(s))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord1dv.xml
+func (gl *GL) MultiTexCoord1dv(target glbase.Enum, v []float64) {
+ C.gl1_5_glMultiTexCoord1dv(gl.funcs, C.GLenum(target), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord1d.xml
+func (gl *GL) MultiTexCoord1d(target glbase.Enum, s float64) {
+ C.gl1_5_glMultiTexCoord1d(gl.funcs, C.GLenum(target), C.GLdouble(s))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClientActiveTexture.xml
+func (gl *GL) ClientActiveTexture(texture glbase.Enum) {
+ C.gl1_5_glClientActiveTexture(gl.funcs, C.GLenum(texture))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos3sv.xml
+func (gl *GL) WindowPos3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glWindowPos3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos3s.xml
+func (gl *GL) WindowPos3s(x, y, z int16) {
+ C.gl1_5_glWindowPos3s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos3iv.xml
+func (gl *GL) WindowPos3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glWindowPos3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos3i.xml
+func (gl *GL) WindowPos3i(x, y, z int) {
+ C.gl1_5_glWindowPos3i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos3fv.xml
+func (gl *GL) WindowPos3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glWindowPos3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos3f.xml
+func (gl *GL) WindowPos3f(x, y, z float32) {
+ C.gl1_5_glWindowPos3f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos3dv.xml
+func (gl *GL) WindowPos3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glWindowPos3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos3d.xml
+func (gl *GL) WindowPos3d(x, y, z float64) {
+ C.gl1_5_glWindowPos3d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos2sv.xml
+func (gl *GL) WindowPos2sv(v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glWindowPos2sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos2s.xml
+func (gl *GL) WindowPos2s(x, y int16) {
+ C.gl1_5_glWindowPos2s(gl.funcs, C.GLshort(x), C.GLshort(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos2iv.xml
+func (gl *GL) WindowPos2iv(v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glWindowPos2iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos2i.xml
+func (gl *GL) WindowPos2i(x, y int) {
+ C.gl1_5_glWindowPos2i(gl.funcs, C.GLint(x), C.GLint(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos2fv.xml
+func (gl *GL) WindowPos2fv(v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glWindowPos2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos2f.xml
+func (gl *GL) WindowPos2f(x, y float32) {
+ C.gl1_5_glWindowPos2f(gl.funcs, C.GLfloat(x), C.GLfloat(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos2dv.xml
+func (gl *GL) WindowPos2dv(v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glWindowPos2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos2d.xml
+func (gl *GL) WindowPos2d(x, y float64) {
+ C.gl1_5_glWindowPos2d(gl.funcs, C.GLdouble(x), C.GLdouble(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColorPointer.xml
+func (gl *GL) SecondaryColorPointer(size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_5_glSecondaryColorPointer(gl.funcs, C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3usv.xml
+func (gl *GL) SecondaryColor3usv(v []uint16) {
+ C.gl1_5_glSecondaryColor3usv(gl.funcs, (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3us.xml
+func (gl *GL) SecondaryColor3us(red, green, blue uint16) {
+ C.gl1_5_glSecondaryColor3us(gl.funcs, C.GLushort(red), C.GLushort(green), C.GLushort(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3uiv.xml
+func (gl *GL) SecondaryColor3uiv(v []uint32) {
+ C.gl1_5_glSecondaryColor3uiv(gl.funcs, (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3ui.xml
+func (gl *GL) SecondaryColor3ui(red, green, blue uint32) {
+ C.gl1_5_glSecondaryColor3ui(gl.funcs, C.GLuint(red), C.GLuint(green), C.GLuint(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3ubv.xml
+func (gl *GL) SecondaryColor3ubv(v []uint8) {
+ C.gl1_5_glSecondaryColor3ubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3ub.xml
+func (gl *GL) SecondaryColor3ub(red, green, blue uint8) {
+ C.gl1_5_glSecondaryColor3ub(gl.funcs, C.GLubyte(red), C.GLubyte(green), C.GLubyte(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3sv.xml
+func (gl *GL) SecondaryColor3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glSecondaryColor3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3s.xml
+func (gl *GL) SecondaryColor3s(red, green, blue int16) {
+ C.gl1_5_glSecondaryColor3s(gl.funcs, C.GLshort(red), C.GLshort(green), C.GLshort(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3iv.xml
+func (gl *GL) SecondaryColor3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glSecondaryColor3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3i.xml
+func (gl *GL) SecondaryColor3i(red, green, blue int32) {
+ C.gl1_5_glSecondaryColor3i(gl.funcs, C.GLint(red), C.GLint(green), C.GLint(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3fv.xml
+func (gl *GL) SecondaryColor3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glSecondaryColor3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3f.xml
+func (gl *GL) SecondaryColor3f(red, green, blue float32) {
+ C.gl1_5_glSecondaryColor3f(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3dv.xml
+func (gl *GL) SecondaryColor3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl1_5_glSecondaryColor3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3d.xml
+func (gl *GL) SecondaryColor3d(red, green, blue float64) {
+ C.gl1_5_glSecondaryColor3d(gl.funcs, C.GLdouble(red), C.GLdouble(green), C.GLdouble(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3bv.xml
+func (gl *GL) SecondaryColor3bv(v []byte) {
+ C.gl1_5_glSecondaryColor3bv(gl.funcs, (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3b.xml
+func (gl *GL) SecondaryColor3b(red, green, blue byte) {
+ C.gl1_5_glSecondaryColor3b(gl.funcs, C.GLbyte(red), C.GLbyte(green), C.GLbyte(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFogCoordPointer.xml
+func (gl *GL) FogCoordPointer(gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl1_5_glFogCoordPointer(gl.funcs, C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFogCoorddv.xml
+func (gl *GL) FogCoorddv(coord []float64) {
+ C.gl1_5_glFogCoorddv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&coord[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFogCoordd.xml
+func (gl *GL) FogCoordd(coord float64) {
+ C.gl1_5_glFogCoordd(gl.funcs, C.GLdouble(coord))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFogCoordfv.xml
+func (gl *GL) FogCoordfv(coord []float32) {
+ C.gl1_5_glFogCoordfv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&coord[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFogCoordf.xml
+func (gl *GL) FogCoordf(coord float32) {
+ C.gl1_5_glFogCoordf(gl.funcs, C.GLfloat(coord))
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/2.0/funcs.cpp b/Godeps/_workspace/src/github.com/obscuren/qml/gl/2.0/funcs.cpp
new file mode 100644
index 000000000..622f59045
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/2.0/funcs.cpp
@@ -0,0 +1,3444 @@
+
+// ** file automatically generated by glgen -- do not edit manually **
+
+#include <QOpenGLContext>
+#include <QtGui/qopenglfunctions_2_0.h>
+
+#include "funcs.h"
+
+void *gl2_0_funcs() {
+ QOpenGLFunctions_2_0* funcs = QOpenGLContext::currentContext()->versionFunctions<QOpenGLFunctions_2_0>();
+ if (!funcs) {
+ return 0;
+ }
+ funcs->initializeOpenGLFunctions();
+ return funcs;
+}
+
+
+void gl2_0_glViewport(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glViewport(x, y, width, height);
+}
+
+void gl2_0_glDepthRange(void *_glfuncs, GLdouble nearVal, GLdouble farVal)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glDepthRange(nearVal, farVal);
+}
+
+GLboolean gl2_0_glIsEnabled(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ return _qglfuncs->glIsEnabled(cap);
+}
+
+void gl2_0_glGetTexLevelParameteriv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glGetTexLevelParameteriv(target, level, pname, params);
+}
+
+void gl2_0_glGetTexLevelParameterfv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glGetTexLevelParameterfv(target, level, pname, params);
+}
+
+void gl2_0_glGetTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glGetTexParameteriv(target, pname, params);
+}
+
+void gl2_0_glGetTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glGetTexParameterfv(target, pname, params);
+}
+
+void gl2_0_glGetTexImage(void *_glfuncs, GLenum target, GLint level, GLenum format, GLenum gltype, GLvoid* pixels)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glGetTexImage(target, level, format, gltype, pixels);
+}
+
+void gl2_0_glGetIntegerv(void *_glfuncs, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glGetIntegerv(pname, params);
+}
+
+void gl2_0_glGetFloatv(void *_glfuncs, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glGetFloatv(pname, params);
+}
+
+GLenum gl2_0_glGetError(void *_glfuncs)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ return _qglfuncs->glGetError();
+}
+
+void gl2_0_glGetDoublev(void *_glfuncs, GLenum pname, GLdouble* params)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glGetDoublev(pname, params);
+}
+
+void gl2_0_glGetBooleanv(void *_glfuncs, GLenum pname, GLboolean* params)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glGetBooleanv(pname, params);
+}
+
+void gl2_0_glReadPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum gltype, GLvoid* pixels)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glReadPixels(x, y, width, height, format, gltype, pixels);
+}
+
+void gl2_0_glReadBuffer(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glReadBuffer(mode);
+}
+
+void gl2_0_glPixelStorei(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glPixelStorei(pname, param);
+}
+
+void gl2_0_glPixelStoref(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glPixelStoref(pname, param);
+}
+
+void gl2_0_glDepthFunc(void *_glfuncs, GLenum glfunc)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glDepthFunc(glfunc);
+}
+
+void gl2_0_glStencilOp(void *_glfuncs, GLenum fail, GLenum zfail, GLenum zpass)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glStencilOp(fail, zfail, zpass);
+}
+
+void gl2_0_glStencilFunc(void *_glfuncs, GLenum glfunc, GLint ref, GLuint mask)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glStencilFunc(glfunc, ref, mask);
+}
+
+void gl2_0_glLogicOp(void *_glfuncs, GLenum opcode)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glLogicOp(opcode);
+}
+
+void gl2_0_glBlendFunc(void *_glfuncs, GLenum sfactor, GLenum dfactor)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glBlendFunc(sfactor, dfactor);
+}
+
+void gl2_0_glFlush(void *_glfuncs)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glFlush();
+}
+
+void gl2_0_glFinish(void *_glfuncs)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glFinish();
+}
+
+void gl2_0_glEnable(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glEnable(cap);
+}
+
+void gl2_0_glDisable(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glDisable(cap);
+}
+
+void gl2_0_glDepthMask(void *_glfuncs, GLboolean flag)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glDepthMask(flag);
+}
+
+void gl2_0_glColorMask(void *_glfuncs, GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glColorMask(red, green, blue, alpha);
+}
+
+void gl2_0_glStencilMask(void *_glfuncs, GLuint mask)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glStencilMask(mask);
+}
+
+void gl2_0_glClearDepth(void *_glfuncs, GLdouble depth)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glClearDepth(depth);
+}
+
+void gl2_0_glClearStencil(void *_glfuncs, GLint s)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glClearStencil(s);
+}
+
+void gl2_0_glClearColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glClearColor(red, green, blue, alpha);
+}
+
+void gl2_0_glClear(void *_glfuncs, GLbitfield mask)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glClear(mask);
+}
+
+void gl2_0_glDrawBuffer(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glDrawBuffer(mode);
+}
+
+void gl2_0_glTexImage2D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glTexImage2D(target, level, internalFormat, width, height, border, format, gltype, pixels);
+}
+
+void gl2_0_glTexImage1D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glTexImage1D(target, level, internalFormat, width, border, format, gltype, pixels);
+}
+
+void gl2_0_glTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glTexParameteriv(target, pname, params);
+}
+
+void gl2_0_glTexParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glTexParameteri(target, pname, param);
+}
+
+void gl2_0_glTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glTexParameterfv(target, pname, params);
+}
+
+void gl2_0_glTexParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glTexParameterf(target, pname, param);
+}
+
+void gl2_0_glScissor(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glScissor(x, y, width, height);
+}
+
+void gl2_0_glPolygonMode(void *_glfuncs, GLenum face, GLenum mode)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glPolygonMode(face, mode);
+}
+
+void gl2_0_glPointSize(void *_glfuncs, GLfloat size)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glPointSize(size);
+}
+
+void gl2_0_glLineWidth(void *_glfuncs, GLfloat width)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glLineWidth(width);
+}
+
+void gl2_0_glHint(void *_glfuncs, GLenum target, GLenum mode)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glHint(target, mode);
+}
+
+void gl2_0_glFrontFace(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glFrontFace(mode);
+}
+
+void gl2_0_glCullFace(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glCullFace(mode);
+}
+
+void gl2_0_glIndexubv(void *_glfuncs, const GLubyte* c)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glIndexubv(c);
+}
+
+void gl2_0_glIndexub(void *_glfuncs, GLubyte c)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glIndexub(c);
+}
+
+GLboolean gl2_0_glIsTexture(void *_glfuncs, GLuint texture)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ return _qglfuncs->glIsTexture(texture);
+}
+
+void gl2_0_glGenTextures(void *_glfuncs, GLsizei n, GLuint* textures)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glGenTextures(n, textures);
+}
+
+void gl2_0_glDeleteTextures(void *_glfuncs, GLsizei n, const GLuint* textures)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glDeleteTextures(n, textures);
+}
+
+void gl2_0_glBindTexture(void *_glfuncs, GLenum target, GLuint texture)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glBindTexture(target, texture);
+}
+
+void gl2_0_glTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glTexSubImage2D(target, level, xoffset, yoffset, width, height, format, gltype, pixels);
+}
+
+void gl2_0_glTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glTexSubImage1D(target, level, xoffset, width, format, gltype, pixels);
+}
+
+void gl2_0_glCopyTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage2D(target, level, xoffset, yoffset, x, y, width, height);
+}
+
+void gl2_0_glCopyTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage1D(target, level, xoffset, x, y, width);
+}
+
+void gl2_0_glCopyTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glCopyTexImage2D(target, level, internalFormat, x, y, width, height, border);
+}
+
+void gl2_0_glCopyTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLint border)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glCopyTexImage1D(target, level, internalFormat, x, y, width, border);
+}
+
+void gl2_0_glPolygonOffset(void *_glfuncs, GLfloat factor, GLfloat units)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glPolygonOffset(factor, units);
+}
+
+void gl2_0_glDrawElements(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glDrawElements(mode, count, gltype, indices);
+}
+
+void gl2_0_glDrawArrays(void *_glfuncs, GLenum mode, GLint first, GLsizei count)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glDrawArrays(mode, first, count);
+}
+
+void gl2_0_glCopyTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage3D(target, level, xoffset, yoffset, zoffset, x, y, width, height);
+}
+
+void gl2_0_glTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glTexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, gltype, pixels);
+}
+
+void gl2_0_glTexImage3D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glTexImage3D(target, level, internalFormat, width, height, depth, border, format, gltype, pixels);
+}
+
+void gl2_0_glDrawRangeElements(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glDrawRangeElements(mode, start, end, count, gltype, indices);
+}
+
+void gl2_0_glBlendEquation(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glBlendEquation(mode);
+}
+
+void gl2_0_glBlendColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glBlendColor(red, green, blue, alpha);
+}
+
+void gl2_0_glGetCompressedTexImage(void *_glfuncs, GLenum target, GLint level, GLvoid* img)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glGetCompressedTexImage(target, level, img);
+}
+
+void gl2_0_glCompressedTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glCompressedTexSubImage1D(target, level, xoffset, width, format, imageSize, data);
+}
+
+void gl2_0_glCompressedTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glCompressedTexSubImage2D(target, level, xoffset, yoffset, width, height, format, imageSize, data);
+}
+
+void gl2_0_glCompressedTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glCompressedTexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, imageSize, data);
+}
+
+void gl2_0_glCompressedTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glCompressedTexImage1D(target, level, internalFormat, width, border, imageSize, data);
+}
+
+void gl2_0_glCompressedTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glCompressedTexImage2D(target, level, internalFormat, width, height, border, imageSize, data);
+}
+
+void gl2_0_glCompressedTexImage3D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glCompressedTexImage3D(target, level, internalFormat, width, height, depth, border, imageSize, data);
+}
+
+void gl2_0_glSampleCoverage(void *_glfuncs, GLfloat value, GLboolean invert)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glSampleCoverage(value, invert);
+}
+
+void gl2_0_glActiveTexture(void *_glfuncs, GLenum texture)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glActiveTexture(texture);
+}
+
+void gl2_0_glPointParameteriv(void *_glfuncs, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glPointParameteriv(pname, params);
+}
+
+void gl2_0_glPointParameteri(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glPointParameteri(pname, param);
+}
+
+void gl2_0_glPointParameterfv(void *_glfuncs, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glPointParameterfv(pname, params);
+}
+
+void gl2_0_glPointParameterf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glPointParameterf(pname, param);
+}
+
+void gl2_0_glMultiDrawArrays(void *_glfuncs, GLenum mode, const GLint* first, const GLsizei* count, GLsizei drawcount)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glMultiDrawArrays(mode, first, count, drawcount);
+}
+
+void gl2_0_glBlendFuncSeparate(void *_glfuncs, GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glBlendFuncSeparate(sfactorRGB, dfactorRGB, sfactorAlpha, dfactorAlpha);
+}
+
+void gl2_0_glGetBufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glGetBufferParameteriv(target, pname, params);
+}
+
+GLboolean gl2_0_glUnmapBuffer(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ return _qglfuncs->glUnmapBuffer(target);
+}
+
+void gl2_0_glGetBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, GLvoid* data)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glGetBufferSubData(target, offset, size, data);
+}
+
+void gl2_0_glBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid* data)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glBufferSubData(target, offset, size, data);
+}
+
+void gl2_0_glBufferData(void *_glfuncs, GLenum target, GLsizeiptr size, const GLvoid* data, GLenum usage)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glBufferData(target, size, data, usage);
+}
+
+GLboolean gl2_0_glIsBuffer(void *_glfuncs, GLuint buffer)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ return _qglfuncs->glIsBuffer(buffer);
+}
+
+void gl2_0_glGenBuffers(void *_glfuncs, GLsizei n, GLuint* buffers)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glGenBuffers(n, buffers);
+}
+
+void gl2_0_glDeleteBuffers(void *_glfuncs, GLsizei n, const GLuint* buffers)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glDeleteBuffers(n, buffers);
+}
+
+void gl2_0_glBindBuffer(void *_glfuncs, GLenum target, GLuint buffer)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glBindBuffer(target, buffer);
+}
+
+void gl2_0_glGetQueryObjectuiv(void *_glfuncs, GLuint id, GLenum pname, GLuint* params)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glGetQueryObjectuiv(id, pname, params);
+}
+
+void gl2_0_glGetQueryObjectiv(void *_glfuncs, GLuint id, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glGetQueryObjectiv(id, pname, params);
+}
+
+void gl2_0_glGetQueryiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glGetQueryiv(target, pname, params);
+}
+
+void gl2_0_glEndQuery(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glEndQuery(target);
+}
+
+void gl2_0_glBeginQuery(void *_glfuncs, GLenum target, GLuint id)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glBeginQuery(target, id);
+}
+
+GLboolean gl2_0_glIsQuery(void *_glfuncs, GLuint id)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ return _qglfuncs->glIsQuery(id);
+}
+
+void gl2_0_glDeleteQueries(void *_glfuncs, GLsizei n, const GLuint* ids)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glDeleteQueries(n, ids);
+}
+
+void gl2_0_glGenQueries(void *_glfuncs, GLsizei n, GLuint* ids)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glGenQueries(n, ids);
+}
+
+void gl2_0_glVertexAttribPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLboolean normalized, GLsizei stride, const GLvoid* offset)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertexAttribPointer(index, size, gltype, normalized, stride, offset);
+}
+
+void gl2_0_glValidateProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glValidateProgram(program);
+}
+
+void gl2_0_glUniformMatrix4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4fv(location, count, transpose, value);
+}
+
+void gl2_0_glUniformMatrix3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3fv(location, count, transpose, value);
+}
+
+void gl2_0_glUniformMatrix2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2fv(location, count, transpose, value);
+}
+
+void gl2_0_glUniform4iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glUniform4iv(location, count, value);
+}
+
+void gl2_0_glUniform3iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glUniform3iv(location, count, value);
+}
+
+void gl2_0_glUniform2iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glUniform2iv(location, count, value);
+}
+
+void gl2_0_glUniform1iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glUniform1iv(location, count, value);
+}
+
+void gl2_0_glUniform4fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glUniform4fv(location, count, value);
+}
+
+void gl2_0_glUniform3fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glUniform3fv(location, count, value);
+}
+
+void gl2_0_glUniform2fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glUniform2fv(location, count, value);
+}
+
+void gl2_0_glUniform1fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glUniform1fv(location, count, value);
+}
+
+void gl2_0_glUniform4i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2, GLint v3)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glUniform4i(location, v0, v1, v2, v3);
+}
+
+void gl2_0_glUniform3i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glUniform3i(location, v0, v1, v2);
+}
+
+void gl2_0_glUniform2i(void *_glfuncs, GLint location, GLint v0, GLint v1)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glUniform2i(location, v0, v1);
+}
+
+void gl2_0_glUniform1i(void *_glfuncs, GLint location, GLint v0)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glUniform1i(location, v0);
+}
+
+void gl2_0_glUniform4f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glUniform4f(location, v0, v1, v2, v3);
+}
+
+void gl2_0_glUniform3f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glUniform3f(location, v0, v1, v2);
+}
+
+void gl2_0_glUniform2f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glUniform2f(location, v0, v1);
+}
+
+void gl2_0_glUniform1f(void *_glfuncs, GLint location, GLfloat v0)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glUniform1f(location, v0);
+}
+
+void gl2_0_glUseProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glUseProgram(program);
+}
+
+void gl2_0_glShaderSource(void *_glfuncs, GLuint shader, GLsizei count, const GLchar** source, const GLint* length)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glShaderSource(shader, count, source, length);
+}
+
+void gl2_0_glLinkProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glLinkProgram(program);
+}
+
+GLboolean gl2_0_glIsShader(void *_glfuncs, GLuint shader)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ return _qglfuncs->glIsShader(shader);
+}
+
+GLboolean gl2_0_glIsProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ return _qglfuncs->glIsProgram(program);
+}
+
+void gl2_0_glGetVertexAttribiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribiv(index, pname, params);
+}
+
+void gl2_0_glGetVertexAttribfv(void *_glfuncs, GLuint index, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribfv(index, pname, params);
+}
+
+void gl2_0_glGetVertexAttribdv(void *_glfuncs, GLuint index, GLenum pname, GLdouble* params)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribdv(index, pname, params);
+}
+
+void gl2_0_glGetUniformiv(void *_glfuncs, GLuint program, GLint location, GLint* params)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glGetUniformiv(program, location, params);
+}
+
+void gl2_0_glGetUniformfv(void *_glfuncs, GLuint program, GLint location, GLfloat* params)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glGetUniformfv(program, location, params);
+}
+
+GLint gl2_0_glGetUniformLocation(void *_glfuncs, GLuint program, const GLchar* name)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ return _qglfuncs->glGetUniformLocation(program, name);
+}
+
+void gl2_0_glGetShaderSource(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* source)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glGetShaderSource(shader, bufSize, length, source);
+}
+
+void gl2_0_glGetShaderInfoLog(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* infoLog)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glGetShaderInfoLog(shader, bufSize, length, infoLog);
+}
+
+void gl2_0_glGetShaderiv(void *_glfuncs, GLuint shader, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glGetShaderiv(shader, pname, params);
+}
+
+void gl2_0_glGetProgramInfoLog(void *_glfuncs, GLuint program, GLsizei bufSize, GLsizei* length, GLchar* infoLog)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glGetProgramInfoLog(program, bufSize, length, infoLog);
+}
+
+void gl2_0_glGetProgramiv(void *_glfuncs, GLuint program, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glGetProgramiv(program, pname, params);
+}
+
+GLint gl2_0_glGetAttribLocation(void *_glfuncs, GLuint program, const GLchar* name)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ return _qglfuncs->glGetAttribLocation(program, name);
+}
+
+void gl2_0_glGetAttachedShaders(void *_glfuncs, GLuint program, GLsizei maxCount, GLsizei* count, GLuint* obj)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glGetAttachedShaders(program, maxCount, count, obj);
+}
+
+void gl2_0_glGetActiveUniform(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glGetActiveUniform(program, index, bufSize, length, size, gltype, name);
+}
+
+void gl2_0_glGetActiveAttrib(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glGetActiveAttrib(program, index, bufSize, length, size, gltype, name);
+}
+
+void gl2_0_glEnableVertexAttribArray(void *_glfuncs, GLuint index)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glEnableVertexAttribArray(index);
+}
+
+void gl2_0_glDisableVertexAttribArray(void *_glfuncs, GLuint index)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glDisableVertexAttribArray(index);
+}
+
+void gl2_0_glDetachShader(void *_glfuncs, GLuint program, GLuint shader)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glDetachShader(program, shader);
+}
+
+void gl2_0_glDeleteShader(void *_glfuncs, GLuint shader)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glDeleteShader(shader);
+}
+
+void gl2_0_glDeleteProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glDeleteProgram(program);
+}
+
+GLuint gl2_0_glCreateShader(void *_glfuncs, GLenum gltype)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ return _qglfuncs->glCreateShader(gltype);
+}
+
+GLuint gl2_0_glCreateProgram(void *_glfuncs)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ return _qglfuncs->glCreateProgram();
+}
+
+void gl2_0_glCompileShader(void *_glfuncs, GLuint shader)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glCompileShader(shader);
+}
+
+void gl2_0_glBindAttribLocation(void *_glfuncs, GLuint program, GLuint index, const GLchar* name)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glBindAttribLocation(program, index, name);
+}
+
+void gl2_0_glAttachShader(void *_glfuncs, GLuint program, GLuint shader)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glAttachShader(program, shader);
+}
+
+void gl2_0_glStencilMaskSeparate(void *_glfuncs, GLenum face, GLuint mask)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glStencilMaskSeparate(face, mask);
+}
+
+void gl2_0_glStencilFuncSeparate(void *_glfuncs, GLenum face, GLenum glfunc, GLint ref, GLuint mask)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glStencilFuncSeparate(face, glfunc, ref, mask);
+}
+
+void gl2_0_glStencilOpSeparate(void *_glfuncs, GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glStencilOpSeparate(face, sfail, dpfail, dppass);
+}
+
+void gl2_0_glDrawBuffers(void *_glfuncs, GLsizei n, const GLenum* bufs)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glDrawBuffers(n, bufs);
+}
+
+void gl2_0_glBlendEquationSeparate(void *_glfuncs, GLenum modeRGB, GLenum modeAlpha)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glBlendEquationSeparate(modeRGB, modeAlpha);
+}
+
+void gl2_0_glTranslatef(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glTranslatef(x, y, z);
+}
+
+void gl2_0_glTranslated(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glTranslated(x, y, z);
+}
+
+void gl2_0_glScalef(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glScalef(x, y, z);
+}
+
+void gl2_0_glScaled(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glScaled(x, y, z);
+}
+
+void gl2_0_glRotatef(void *_glfuncs, GLfloat angle, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glRotatef(angle, x, y, z);
+}
+
+void gl2_0_glRotated(void *_glfuncs, GLdouble angle, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glRotated(angle, x, y, z);
+}
+
+void gl2_0_glPushMatrix(void *_glfuncs)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glPushMatrix();
+}
+
+void gl2_0_glPopMatrix(void *_glfuncs)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glPopMatrix();
+}
+
+void gl2_0_glOrtho(void *_glfuncs, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glOrtho(left, right, bottom, top, zNear, zFar);
+}
+
+void gl2_0_glMultMatrixd(void *_glfuncs, const GLdouble* m)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glMultMatrixd(m);
+}
+
+void gl2_0_glMultMatrixf(void *_glfuncs, const GLfloat* m)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glMultMatrixf(m);
+}
+
+void gl2_0_glMatrixMode(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glMatrixMode(mode);
+}
+
+void gl2_0_glLoadMatrixd(void *_glfuncs, const GLdouble* m)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glLoadMatrixd(m);
+}
+
+void gl2_0_glLoadMatrixf(void *_glfuncs, const GLfloat* m)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glLoadMatrixf(m);
+}
+
+void gl2_0_glLoadIdentity(void *_glfuncs)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glLoadIdentity();
+}
+
+void gl2_0_glFrustum(void *_glfuncs, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glFrustum(left, right, bottom, top, zNear, zFar);
+}
+
+GLboolean gl2_0_glIsList(void *_glfuncs, GLuint list)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ return _qglfuncs->glIsList(list);
+}
+
+void gl2_0_glGetTexGeniv(void *_glfuncs, GLenum coord, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glGetTexGeniv(coord, pname, params);
+}
+
+void gl2_0_glGetTexGenfv(void *_glfuncs, GLenum coord, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glGetTexGenfv(coord, pname, params);
+}
+
+void gl2_0_glGetTexGendv(void *_glfuncs, GLenum coord, GLenum pname, GLdouble* params)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glGetTexGendv(coord, pname, params);
+}
+
+void gl2_0_glGetTexEnviv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glGetTexEnviv(target, pname, params);
+}
+
+void gl2_0_glGetTexEnvfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glGetTexEnvfv(target, pname, params);
+}
+
+void gl2_0_glGetPolygonStipple(void *_glfuncs, GLubyte* mask)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glGetPolygonStipple(mask);
+}
+
+void gl2_0_glGetPixelMapusv(void *_glfuncs, GLenum glmap, GLushort* values)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glGetPixelMapusv(glmap, values);
+}
+
+void gl2_0_glGetPixelMapuiv(void *_glfuncs, GLenum glmap, GLuint* values)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glGetPixelMapuiv(glmap, values);
+}
+
+void gl2_0_glGetPixelMapfv(void *_glfuncs, GLenum glmap, GLfloat* values)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glGetPixelMapfv(glmap, values);
+}
+
+void gl2_0_glGetMaterialiv(void *_glfuncs, GLenum face, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glGetMaterialiv(face, pname, params);
+}
+
+void gl2_0_glGetMaterialfv(void *_glfuncs, GLenum face, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glGetMaterialfv(face, pname, params);
+}
+
+void gl2_0_glGetMapiv(void *_glfuncs, GLenum target, GLenum query, GLint* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glGetMapiv(target, query, v);
+}
+
+void gl2_0_glGetMapfv(void *_glfuncs, GLenum target, GLenum query, GLfloat* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glGetMapfv(target, query, v);
+}
+
+void gl2_0_glGetMapdv(void *_glfuncs, GLenum target, GLenum query, GLdouble* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glGetMapdv(target, query, v);
+}
+
+void gl2_0_glGetLightiv(void *_glfuncs, GLenum light, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glGetLightiv(light, pname, params);
+}
+
+void gl2_0_glGetLightfv(void *_glfuncs, GLenum light, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glGetLightfv(light, pname, params);
+}
+
+void gl2_0_glGetClipPlane(void *_glfuncs, GLenum plane, GLdouble* equation)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glGetClipPlane(plane, equation);
+}
+
+void gl2_0_glDrawPixels(void *_glfuncs, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glDrawPixels(width, height, format, gltype, pixels);
+}
+
+void gl2_0_glCopyPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum gltype)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glCopyPixels(x, y, width, height, gltype);
+}
+
+void gl2_0_glPixelMapusv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLushort* values)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glPixelMapusv(glmap, mapsize, values);
+}
+
+void gl2_0_glPixelMapuiv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLuint* values)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glPixelMapuiv(glmap, mapsize, values);
+}
+
+void gl2_0_glPixelMapfv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLfloat* values)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glPixelMapfv(glmap, mapsize, values);
+}
+
+void gl2_0_glPixelTransferi(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glPixelTransferi(pname, param);
+}
+
+void gl2_0_glPixelTransferf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glPixelTransferf(pname, param);
+}
+
+void gl2_0_glPixelZoom(void *_glfuncs, GLfloat xfactor, GLfloat yfactor)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glPixelZoom(xfactor, yfactor);
+}
+
+void gl2_0_glAlphaFunc(void *_glfuncs, GLenum glfunc, GLfloat ref)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glAlphaFunc(glfunc, ref);
+}
+
+void gl2_0_glEvalPoint2(void *_glfuncs, GLint i, GLint j)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glEvalPoint2(i, j);
+}
+
+void gl2_0_glEvalMesh2(void *_glfuncs, GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glEvalMesh2(mode, i1, i2, j1, j2);
+}
+
+void gl2_0_glEvalPoint1(void *_glfuncs, GLint i)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glEvalPoint1(i);
+}
+
+void gl2_0_glEvalMesh1(void *_glfuncs, GLenum mode, GLint i1, GLint i2)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glEvalMesh1(mode, i1, i2);
+}
+
+void gl2_0_glEvalCoord2fv(void *_glfuncs, const GLfloat* u)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glEvalCoord2fv(u);
+}
+
+void gl2_0_glEvalCoord2f(void *_glfuncs, GLfloat u, GLfloat v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glEvalCoord2f(u, v);
+}
+
+void gl2_0_glEvalCoord2dv(void *_glfuncs, const GLdouble* u)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glEvalCoord2dv(u);
+}
+
+void gl2_0_glEvalCoord2d(void *_glfuncs, GLdouble u, GLdouble v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glEvalCoord2d(u, v);
+}
+
+void gl2_0_glEvalCoord1fv(void *_glfuncs, const GLfloat* u)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glEvalCoord1fv(u);
+}
+
+void gl2_0_glEvalCoord1f(void *_glfuncs, GLfloat u)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glEvalCoord1f(u);
+}
+
+void gl2_0_glEvalCoord1dv(void *_glfuncs, const GLdouble* u)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glEvalCoord1dv(u);
+}
+
+void gl2_0_glEvalCoord1d(void *_glfuncs, GLdouble u)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glEvalCoord1d(u);
+}
+
+void gl2_0_glMapGrid2f(void *_glfuncs, GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glMapGrid2f(un, u1, u2, vn, v1, v2);
+}
+
+void gl2_0_glMapGrid2d(void *_glfuncs, GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glMapGrid2d(un, u1, u2, vn, v1, v2);
+}
+
+void gl2_0_glMapGrid1f(void *_glfuncs, GLint un, GLfloat u1, GLfloat u2)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glMapGrid1f(un, u1, u2);
+}
+
+void gl2_0_glMapGrid1d(void *_glfuncs, GLint un, GLdouble u1, GLdouble u2)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glMapGrid1d(un, u1, u2);
+}
+
+void gl2_0_glMap2f(void *_glfuncs, GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat* points)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glMap2f(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+void gl2_0_glMap2d(void *_glfuncs, GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble* points)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glMap2d(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+void gl2_0_glMap1f(void *_glfuncs, GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat* points)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glMap1f(target, u1, u2, stride, order, points);
+}
+
+void gl2_0_glMap1d(void *_glfuncs, GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble* points)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glMap1d(target, u1, u2, stride, order, points);
+}
+
+void gl2_0_glPushAttrib(void *_glfuncs, GLbitfield mask)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glPushAttrib(mask);
+}
+
+void gl2_0_glPopAttrib(void *_glfuncs)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glPopAttrib();
+}
+
+void gl2_0_glAccum(void *_glfuncs, GLenum op, GLfloat value)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glAccum(op, value);
+}
+
+void gl2_0_glIndexMask(void *_glfuncs, GLuint mask)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glIndexMask(mask);
+}
+
+void gl2_0_glClearIndex(void *_glfuncs, GLfloat c)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glClearIndex(c);
+}
+
+void gl2_0_glClearAccum(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glClearAccum(red, green, blue, alpha);
+}
+
+void gl2_0_glPushName(void *_glfuncs, GLuint name)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glPushName(name);
+}
+
+void gl2_0_glPopName(void *_glfuncs)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glPopName();
+}
+
+void gl2_0_glPassThrough(void *_glfuncs, GLfloat token)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glPassThrough(token);
+}
+
+void gl2_0_glLoadName(void *_glfuncs, GLuint name)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glLoadName(name);
+}
+
+void gl2_0_glInitNames(void *_glfuncs)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glInitNames();
+}
+
+GLint gl2_0_glRenderMode(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ return _qglfuncs->glRenderMode(mode);
+}
+
+void gl2_0_glSelectBuffer(void *_glfuncs, GLsizei size, GLuint* buffer)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glSelectBuffer(size, buffer);
+}
+
+void gl2_0_glFeedbackBuffer(void *_glfuncs, GLsizei size, GLenum gltype, GLfloat* buffer)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glFeedbackBuffer(size, gltype, buffer);
+}
+
+void gl2_0_glTexGeniv(void *_glfuncs, GLenum coord, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glTexGeniv(coord, pname, params);
+}
+
+void gl2_0_glTexGeni(void *_glfuncs, GLenum coord, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glTexGeni(coord, pname, param);
+}
+
+void gl2_0_glTexGenfv(void *_glfuncs, GLenum coord, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glTexGenfv(coord, pname, params);
+}
+
+void gl2_0_glTexGenf(void *_glfuncs, GLenum coord, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glTexGenf(coord, pname, param);
+}
+
+void gl2_0_glTexGendv(void *_glfuncs, GLenum coord, GLenum pname, const GLdouble* params)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glTexGendv(coord, pname, params);
+}
+
+void gl2_0_glTexGend(void *_glfuncs, GLenum coord, GLenum pname, GLdouble param)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glTexGend(coord, pname, param);
+}
+
+void gl2_0_glTexEnviv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glTexEnviv(target, pname, params);
+}
+
+void gl2_0_glTexEnvi(void *_glfuncs, GLenum target, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glTexEnvi(target, pname, param);
+}
+
+void gl2_0_glTexEnvfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glTexEnvfv(target, pname, params);
+}
+
+void gl2_0_glTexEnvf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glTexEnvf(target, pname, param);
+}
+
+void gl2_0_glShadeModel(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glShadeModel(mode);
+}
+
+void gl2_0_glPolygonStipple(void *_glfuncs, const GLubyte* mask)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glPolygonStipple(mask);
+}
+
+void gl2_0_glMaterialiv(void *_glfuncs, GLenum face, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glMaterialiv(face, pname, params);
+}
+
+void gl2_0_glMateriali(void *_glfuncs, GLenum face, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glMateriali(face, pname, param);
+}
+
+void gl2_0_glMaterialfv(void *_glfuncs, GLenum face, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glMaterialfv(face, pname, params);
+}
+
+void gl2_0_glMaterialf(void *_glfuncs, GLenum face, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glMaterialf(face, pname, param);
+}
+
+void gl2_0_glLineStipple(void *_glfuncs, GLint factor, GLushort pattern)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glLineStipple(factor, pattern);
+}
+
+void gl2_0_glLightModeliv(void *_glfuncs, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glLightModeliv(pname, params);
+}
+
+void gl2_0_glLightModeli(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glLightModeli(pname, param);
+}
+
+void gl2_0_glLightModelfv(void *_glfuncs, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glLightModelfv(pname, params);
+}
+
+void gl2_0_glLightModelf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glLightModelf(pname, param);
+}
+
+void gl2_0_glLightiv(void *_glfuncs, GLenum light, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glLightiv(light, pname, params);
+}
+
+void gl2_0_glLighti(void *_glfuncs, GLenum light, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glLighti(light, pname, param);
+}
+
+void gl2_0_glLightfv(void *_glfuncs, GLenum light, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glLightfv(light, pname, params);
+}
+
+void gl2_0_glLightf(void *_glfuncs, GLenum light, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glLightf(light, pname, param);
+}
+
+void gl2_0_glFogiv(void *_glfuncs, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glFogiv(pname, params);
+}
+
+void gl2_0_glFogi(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glFogi(pname, param);
+}
+
+void gl2_0_glFogfv(void *_glfuncs, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glFogfv(pname, params);
+}
+
+void gl2_0_glFogf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glFogf(pname, param);
+}
+
+void gl2_0_glColorMaterial(void *_glfuncs, GLenum face, GLenum mode)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glColorMaterial(face, mode);
+}
+
+void gl2_0_glClipPlane(void *_glfuncs, GLenum plane, const GLdouble* equation)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glClipPlane(plane, equation);
+}
+
+void gl2_0_glVertex4sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertex4sv(v);
+}
+
+void gl2_0_glVertex4s(void *_glfuncs, GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertex4s(x, y, z, w);
+}
+
+void gl2_0_glVertex4iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertex4iv(v);
+}
+
+void gl2_0_glVertex4i(void *_glfuncs, GLint x, GLint y, GLint z, GLint w)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertex4i(x, y, z, w);
+}
+
+void gl2_0_glVertex4fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertex4fv(v);
+}
+
+void gl2_0_glVertex4f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertex4f(x, y, z, w);
+}
+
+void gl2_0_glVertex4dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertex4dv(v);
+}
+
+void gl2_0_glVertex4d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertex4d(x, y, z, w);
+}
+
+void gl2_0_glVertex3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertex3sv(v);
+}
+
+void gl2_0_glVertex3s(void *_glfuncs, GLshort x, GLshort y, GLshort z)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertex3s(x, y, z);
+}
+
+void gl2_0_glVertex3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertex3iv(v);
+}
+
+void gl2_0_glVertex3i(void *_glfuncs, GLint x, GLint y, GLint z)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertex3i(x, y, z);
+}
+
+void gl2_0_glVertex3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertex3fv(v);
+}
+
+void gl2_0_glVertex3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertex3f(x, y, z);
+}
+
+void gl2_0_glVertex3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertex3dv(v);
+}
+
+void gl2_0_glVertex3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertex3d(x, y, z);
+}
+
+void gl2_0_glVertex2sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertex2sv(v);
+}
+
+void gl2_0_glVertex2s(void *_glfuncs, GLshort x, GLshort y)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertex2s(x, y);
+}
+
+void gl2_0_glVertex2iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertex2iv(v);
+}
+
+void gl2_0_glVertex2i(void *_glfuncs, GLint x, GLint y)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertex2i(x, y);
+}
+
+void gl2_0_glVertex2fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertex2fv(v);
+}
+
+void gl2_0_glVertex2f(void *_glfuncs, GLfloat x, GLfloat y)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertex2f(x, y);
+}
+
+void gl2_0_glVertex2dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertex2dv(v);
+}
+
+void gl2_0_glVertex2d(void *_glfuncs, GLdouble x, GLdouble y)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertex2d(x, y);
+}
+
+void gl2_0_glTexCoord4sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glTexCoord4sv(v);
+}
+
+void gl2_0_glTexCoord4s(void *_glfuncs, GLshort s, GLshort t, GLshort r, GLshort q)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glTexCoord4s(s, t, r, q);
+}
+
+void gl2_0_glTexCoord4iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glTexCoord4iv(v);
+}
+
+void gl2_0_glTexCoord4i(void *_glfuncs, GLint s, GLint t, GLint r, GLint q)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glTexCoord4i(s, t, r, q);
+}
+
+void gl2_0_glTexCoord4fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glTexCoord4fv(v);
+}
+
+void gl2_0_glTexCoord4f(void *_glfuncs, GLfloat s, GLfloat t, GLfloat r, GLfloat q)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glTexCoord4f(s, t, r, q);
+}
+
+void gl2_0_glTexCoord4dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glTexCoord4dv(v);
+}
+
+void gl2_0_glTexCoord4d(void *_glfuncs, GLdouble s, GLdouble t, GLdouble r, GLdouble q)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glTexCoord4d(s, t, r, q);
+}
+
+void gl2_0_glTexCoord3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glTexCoord3sv(v);
+}
+
+void gl2_0_glTexCoord3s(void *_glfuncs, GLshort s, GLshort t, GLshort r)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glTexCoord3s(s, t, r);
+}
+
+void gl2_0_glTexCoord3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glTexCoord3iv(v);
+}
+
+void gl2_0_glTexCoord3i(void *_glfuncs, GLint s, GLint t, GLint r)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glTexCoord3i(s, t, r);
+}
+
+void gl2_0_glTexCoord3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glTexCoord3fv(v);
+}
+
+void gl2_0_glTexCoord3f(void *_glfuncs, GLfloat s, GLfloat t, GLfloat r)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glTexCoord3f(s, t, r);
+}
+
+void gl2_0_glTexCoord3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glTexCoord3dv(v);
+}
+
+void gl2_0_glTexCoord3d(void *_glfuncs, GLdouble s, GLdouble t, GLdouble r)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glTexCoord3d(s, t, r);
+}
+
+void gl2_0_glTexCoord2sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glTexCoord2sv(v);
+}
+
+void gl2_0_glTexCoord2s(void *_glfuncs, GLshort s, GLshort t)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glTexCoord2s(s, t);
+}
+
+void gl2_0_glTexCoord2iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glTexCoord2iv(v);
+}
+
+void gl2_0_glTexCoord2i(void *_glfuncs, GLint s, GLint t)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glTexCoord2i(s, t);
+}
+
+void gl2_0_glTexCoord2fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glTexCoord2fv(v);
+}
+
+void gl2_0_glTexCoord2f(void *_glfuncs, GLfloat s, GLfloat t)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glTexCoord2f(s, t);
+}
+
+void gl2_0_glTexCoord2dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glTexCoord2dv(v);
+}
+
+void gl2_0_glTexCoord2d(void *_glfuncs, GLdouble s, GLdouble t)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glTexCoord2d(s, t);
+}
+
+void gl2_0_glTexCoord1sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glTexCoord1sv(v);
+}
+
+void gl2_0_glTexCoord1s(void *_glfuncs, GLshort s)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glTexCoord1s(s);
+}
+
+void gl2_0_glTexCoord1iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glTexCoord1iv(v);
+}
+
+void gl2_0_glTexCoord1i(void *_glfuncs, GLint s)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glTexCoord1i(s);
+}
+
+void gl2_0_glTexCoord1fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glTexCoord1fv(v);
+}
+
+void gl2_0_glTexCoord1f(void *_glfuncs, GLfloat s)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glTexCoord1f(s);
+}
+
+void gl2_0_glTexCoord1dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glTexCoord1dv(v);
+}
+
+void gl2_0_glTexCoord1d(void *_glfuncs, GLdouble s)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glTexCoord1d(s);
+}
+
+void gl2_0_glRectsv(void *_glfuncs, const GLshort* v1, const GLshort* v2)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glRectsv(v1, v2);
+}
+
+void gl2_0_glRects(void *_glfuncs, GLshort x1, GLshort y1, GLshort x2, GLshort y2)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glRects(x1, y1, x2, y2);
+}
+
+void gl2_0_glRectiv(void *_glfuncs, const GLint* v1, const GLint* v2)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glRectiv(v1, v2);
+}
+
+void gl2_0_glRecti(void *_glfuncs, GLint x1, GLint y1, GLint x2, GLint y2)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glRecti(x1, y1, x2, y2);
+}
+
+void gl2_0_glRectfv(void *_glfuncs, const GLfloat* v1, const GLfloat* v2)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glRectfv(v1, v2);
+}
+
+void gl2_0_glRectf(void *_glfuncs, GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glRectf(x1, y1, x2, y2);
+}
+
+void gl2_0_glRectdv(void *_glfuncs, const GLdouble* v1, const GLdouble* v2)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glRectdv(v1, v2);
+}
+
+void gl2_0_glRectd(void *_glfuncs, GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glRectd(x1, y1, x2, y2);
+}
+
+void gl2_0_glRasterPos4sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glRasterPos4sv(v);
+}
+
+void gl2_0_glRasterPos4s(void *_glfuncs, GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glRasterPos4s(x, y, z, w);
+}
+
+void gl2_0_glRasterPos4iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glRasterPos4iv(v);
+}
+
+void gl2_0_glRasterPos4i(void *_glfuncs, GLint x, GLint y, GLint z, GLint w)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glRasterPos4i(x, y, z, w);
+}
+
+void gl2_0_glRasterPos4fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glRasterPos4fv(v);
+}
+
+void gl2_0_glRasterPos4f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glRasterPos4f(x, y, z, w);
+}
+
+void gl2_0_glRasterPos4dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glRasterPos4dv(v);
+}
+
+void gl2_0_glRasterPos4d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glRasterPos4d(x, y, z, w);
+}
+
+void gl2_0_glRasterPos3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glRasterPos3sv(v);
+}
+
+void gl2_0_glRasterPos3s(void *_glfuncs, GLshort x, GLshort y, GLshort z)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glRasterPos3s(x, y, z);
+}
+
+void gl2_0_glRasterPos3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glRasterPos3iv(v);
+}
+
+void gl2_0_glRasterPos3i(void *_glfuncs, GLint x, GLint y, GLint z)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glRasterPos3i(x, y, z);
+}
+
+void gl2_0_glRasterPos3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glRasterPos3fv(v);
+}
+
+void gl2_0_glRasterPos3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glRasterPos3f(x, y, z);
+}
+
+void gl2_0_glRasterPos3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glRasterPos3dv(v);
+}
+
+void gl2_0_glRasterPos3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glRasterPos3d(x, y, z);
+}
+
+void gl2_0_glRasterPos2sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glRasterPos2sv(v);
+}
+
+void gl2_0_glRasterPos2s(void *_glfuncs, GLshort x, GLshort y)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glRasterPos2s(x, y);
+}
+
+void gl2_0_glRasterPos2iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glRasterPos2iv(v);
+}
+
+void gl2_0_glRasterPos2i(void *_glfuncs, GLint x, GLint y)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glRasterPos2i(x, y);
+}
+
+void gl2_0_glRasterPos2fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glRasterPos2fv(v);
+}
+
+void gl2_0_glRasterPos2f(void *_glfuncs, GLfloat x, GLfloat y)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glRasterPos2f(x, y);
+}
+
+void gl2_0_glRasterPos2dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glRasterPos2dv(v);
+}
+
+void gl2_0_glRasterPos2d(void *_glfuncs, GLdouble x, GLdouble y)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glRasterPos2d(x, y);
+}
+
+void gl2_0_glNormal3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glNormal3sv(v);
+}
+
+void gl2_0_glNormal3s(void *_glfuncs, GLshort nx, GLshort ny, GLshort nz)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glNormal3s(nx, ny, nz);
+}
+
+void gl2_0_glNormal3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glNormal3iv(v);
+}
+
+void gl2_0_glNormal3i(void *_glfuncs, GLint nx, GLint ny, GLint nz)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glNormal3i(nx, ny, nz);
+}
+
+void gl2_0_glNormal3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glNormal3fv(v);
+}
+
+void gl2_0_glNormal3f(void *_glfuncs, GLfloat nx, GLfloat ny, GLfloat nz)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glNormal3f(nx, ny, nz);
+}
+
+void gl2_0_glNormal3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glNormal3dv(v);
+}
+
+void gl2_0_glNormal3d(void *_glfuncs, GLdouble nx, GLdouble ny, GLdouble nz)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glNormal3d(nx, ny, nz);
+}
+
+void gl2_0_glNormal3bv(void *_glfuncs, const GLbyte* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glNormal3bv(v);
+}
+
+void gl2_0_glNormal3b(void *_glfuncs, GLbyte nx, GLbyte ny, GLbyte nz)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glNormal3b(nx, ny, nz);
+}
+
+void gl2_0_glIndexsv(void *_glfuncs, const GLshort* c)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glIndexsv(c);
+}
+
+void gl2_0_glIndexs(void *_glfuncs, GLshort c)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glIndexs(c);
+}
+
+void gl2_0_glIndexiv(void *_glfuncs, const GLint* c)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glIndexiv(c);
+}
+
+void gl2_0_glIndexi(void *_glfuncs, GLint c)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glIndexi(c);
+}
+
+void gl2_0_glIndexfv(void *_glfuncs, const GLfloat* c)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glIndexfv(c);
+}
+
+void gl2_0_glIndexf(void *_glfuncs, GLfloat c)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glIndexf(c);
+}
+
+void gl2_0_glIndexdv(void *_glfuncs, const GLdouble* c)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glIndexdv(c);
+}
+
+void gl2_0_glIndexd(void *_glfuncs, GLdouble c)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glIndexd(c);
+}
+
+void gl2_0_glEnd(void *_glfuncs)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glEnd();
+}
+
+void gl2_0_glEdgeFlagv(void *_glfuncs, const GLboolean* flag)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glEdgeFlagv(flag);
+}
+
+void gl2_0_glEdgeFlag(void *_glfuncs, GLboolean flag)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glEdgeFlag(flag);
+}
+
+void gl2_0_glColor4usv(void *_glfuncs, const GLushort* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glColor4usv(v);
+}
+
+void gl2_0_glColor4us(void *_glfuncs, GLushort red, GLushort green, GLushort blue, GLushort alpha)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glColor4us(red, green, blue, alpha);
+}
+
+void gl2_0_glColor4uiv(void *_glfuncs, const GLuint* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glColor4uiv(v);
+}
+
+void gl2_0_glColor4ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue, GLuint alpha)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glColor4ui(red, green, blue, alpha);
+}
+
+void gl2_0_glColor4ubv(void *_glfuncs, const GLubyte* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glColor4ubv(v);
+}
+
+void gl2_0_glColor4ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glColor4ub(red, green, blue, alpha);
+}
+
+void gl2_0_glColor4sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glColor4sv(v);
+}
+
+void gl2_0_glColor4s(void *_glfuncs, GLshort red, GLshort green, GLshort blue, GLshort alpha)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glColor4s(red, green, blue, alpha);
+}
+
+void gl2_0_glColor4iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glColor4iv(v);
+}
+
+void gl2_0_glColor4i(void *_glfuncs, GLint red, GLint green, GLint blue, GLint alpha)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glColor4i(red, green, blue, alpha);
+}
+
+void gl2_0_glColor4fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glColor4fv(v);
+}
+
+void gl2_0_glColor4f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glColor4f(red, green, blue, alpha);
+}
+
+void gl2_0_glColor4dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glColor4dv(v);
+}
+
+void gl2_0_glColor4d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glColor4d(red, green, blue, alpha);
+}
+
+void gl2_0_glColor4bv(void *_glfuncs, const GLbyte* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glColor4bv(v);
+}
+
+void gl2_0_glColor4b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glColor4b(red, green, blue, alpha);
+}
+
+void gl2_0_glColor3usv(void *_glfuncs, const GLushort* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glColor3usv(v);
+}
+
+void gl2_0_glColor3us(void *_glfuncs, GLushort red, GLushort green, GLushort blue)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glColor3us(red, green, blue);
+}
+
+void gl2_0_glColor3uiv(void *_glfuncs, const GLuint* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glColor3uiv(v);
+}
+
+void gl2_0_glColor3ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glColor3ui(red, green, blue);
+}
+
+void gl2_0_glColor3ubv(void *_glfuncs, const GLubyte* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glColor3ubv(v);
+}
+
+void gl2_0_glColor3ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glColor3ub(red, green, blue);
+}
+
+void gl2_0_glColor3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glColor3sv(v);
+}
+
+void gl2_0_glColor3s(void *_glfuncs, GLshort red, GLshort green, GLshort blue)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glColor3s(red, green, blue);
+}
+
+void gl2_0_glColor3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glColor3iv(v);
+}
+
+void gl2_0_glColor3i(void *_glfuncs, GLint red, GLint green, GLint blue)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glColor3i(red, green, blue);
+}
+
+void gl2_0_glColor3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glColor3fv(v);
+}
+
+void gl2_0_glColor3f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glColor3f(red, green, blue);
+}
+
+void gl2_0_glColor3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glColor3dv(v);
+}
+
+void gl2_0_glColor3d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glColor3d(red, green, blue);
+}
+
+void gl2_0_glColor3bv(void *_glfuncs, const GLbyte* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glColor3bv(v);
+}
+
+void gl2_0_glColor3b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glColor3b(red, green, blue);
+}
+
+void gl2_0_glBitmap(void *_glfuncs, GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte* bitmap)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glBitmap(width, height, xorig, yorig, xmove, ymove, bitmap);
+}
+
+void gl2_0_glBegin(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glBegin(mode);
+}
+
+void gl2_0_glListBase(void *_glfuncs, GLuint base)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glListBase(base);
+}
+
+GLuint gl2_0_glGenLists(void *_glfuncs, GLsizei range_)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ return _qglfuncs->glGenLists(range_);
+}
+
+void gl2_0_glDeleteLists(void *_glfuncs, GLuint list, GLsizei range_)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glDeleteLists(list, range_);
+}
+
+void gl2_0_glCallLists(void *_glfuncs, GLsizei n, GLenum gltype, const GLvoid* lists)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glCallLists(n, gltype, lists);
+}
+
+void gl2_0_glCallList(void *_glfuncs, GLuint list)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glCallList(list);
+}
+
+void gl2_0_glEndList(void *_glfuncs)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glEndList();
+}
+
+void gl2_0_glNewList(void *_glfuncs, GLuint list, GLenum mode)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glNewList(list, mode);
+}
+
+void gl2_0_glPushClientAttrib(void *_glfuncs, GLbitfield mask)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glPushClientAttrib(mask);
+}
+
+void gl2_0_glPopClientAttrib(void *_glfuncs)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glPopClientAttrib();
+}
+
+void gl2_0_glPrioritizeTextures(void *_glfuncs, GLsizei n, const GLuint* textures, const GLfloat* priorities)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glPrioritizeTextures(n, textures, priorities);
+}
+
+GLboolean gl2_0_glAreTexturesResident(void *_glfuncs, GLsizei n, const GLuint* textures, GLboolean* residences)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ return _qglfuncs->glAreTexturesResident(n, textures, residences);
+}
+
+void gl2_0_glVertexPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertexPointer(size, gltype, stride, pointer);
+}
+
+void gl2_0_glTexCoordPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glTexCoordPointer(size, gltype, stride, pointer);
+}
+
+void gl2_0_glNormalPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glNormalPointer(gltype, stride, pointer);
+}
+
+void gl2_0_glInterleavedArrays(void *_glfuncs, GLenum format, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glInterleavedArrays(format, stride, pointer);
+}
+
+void gl2_0_glIndexPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glIndexPointer(gltype, stride, pointer);
+}
+
+void gl2_0_glEnableClientState(void *_glfuncs, GLenum array)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glEnableClientState(array);
+}
+
+void gl2_0_glEdgeFlagPointer(void *_glfuncs, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glEdgeFlagPointer(stride, pointer);
+}
+
+void gl2_0_glDisableClientState(void *_glfuncs, GLenum array)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glDisableClientState(array);
+}
+
+void gl2_0_glColorPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glColorPointer(size, gltype, stride, pointer);
+}
+
+void gl2_0_glArrayElement(void *_glfuncs, GLint i)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glArrayElement(i);
+}
+
+void gl2_0_glResetMinmax(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glResetMinmax(target);
+}
+
+void gl2_0_glResetHistogram(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glResetHistogram(target);
+}
+
+void gl2_0_glMinmax(void *_glfuncs, GLenum target, GLenum internalFormat, GLboolean sink)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glMinmax(target, internalFormat, sink);
+}
+
+void gl2_0_glHistogram(void *_glfuncs, GLenum target, GLsizei width, GLenum internalFormat, GLboolean sink)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glHistogram(target, width, internalFormat, sink);
+}
+
+void gl2_0_glGetMinmaxParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glGetMinmaxParameteriv(target, pname, params);
+}
+
+void gl2_0_glGetMinmaxParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glGetMinmaxParameterfv(target, pname, params);
+}
+
+void gl2_0_glGetMinmax(void *_glfuncs, GLenum target, GLboolean reset, GLenum format, GLenum gltype, GLvoid* values)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glGetMinmax(target, reset, format, gltype, values);
+}
+
+void gl2_0_glGetHistogramParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glGetHistogramParameteriv(target, pname, params);
+}
+
+void gl2_0_glGetHistogramParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glGetHistogramParameterfv(target, pname, params);
+}
+
+void gl2_0_glGetHistogram(void *_glfuncs, GLenum target, GLboolean reset, GLenum format, GLenum gltype, GLvoid* values)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glGetHistogram(target, reset, format, gltype, values);
+}
+
+void gl2_0_glSeparableFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* row, const GLvoid* column)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glSeparableFilter2D(target, internalFormat, width, height, format, gltype, row, column);
+}
+
+void gl2_0_glGetSeparableFilter(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* row, GLvoid* column, GLvoid* span)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glGetSeparableFilter(target, format, gltype, row, column, span);
+}
+
+void gl2_0_glGetConvolutionParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glGetConvolutionParameteriv(target, pname, params);
+}
+
+void gl2_0_glGetConvolutionParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glGetConvolutionParameterfv(target, pname, params);
+}
+
+void gl2_0_glGetConvolutionFilter(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* image)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glGetConvolutionFilter(target, format, gltype, image);
+}
+
+void gl2_0_glCopyConvolutionFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glCopyConvolutionFilter2D(target, internalFormat, x, y, width, height);
+}
+
+void gl2_0_glCopyConvolutionFilter1D(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glCopyConvolutionFilter1D(target, internalFormat, x, y, width);
+}
+
+void gl2_0_glConvolutionParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glConvolutionParameteriv(target, pname, params);
+}
+
+void gl2_0_glConvolutionParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint params)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glConvolutionParameteri(target, pname, params);
+}
+
+void gl2_0_glConvolutionParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glConvolutionParameterfv(target, pname, params);
+}
+
+void gl2_0_glConvolutionParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat params)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glConvolutionParameterf(target, pname, params);
+}
+
+void gl2_0_glConvolutionFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* image)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glConvolutionFilter2D(target, internalFormat, width, height, format, gltype, image);
+}
+
+void gl2_0_glConvolutionFilter1D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLenum format, GLenum gltype, const GLvoid* image)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glConvolutionFilter1D(target, internalFormat, width, format, gltype, image);
+}
+
+void gl2_0_glCopyColorSubTable(void *_glfuncs, GLenum target, GLsizei start, GLint x, GLint y, GLsizei width)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glCopyColorSubTable(target, start, x, y, width);
+}
+
+void gl2_0_glColorSubTable(void *_glfuncs, GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum gltype, const GLvoid* data)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glColorSubTable(target, start, count, format, gltype, data);
+}
+
+void gl2_0_glGetColorTableParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glGetColorTableParameteriv(target, pname, params);
+}
+
+void gl2_0_glGetColorTableParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glGetColorTableParameterfv(target, pname, params);
+}
+
+void gl2_0_glGetColorTable(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* table)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glGetColorTable(target, format, gltype, table);
+}
+
+void gl2_0_glCopyColorTable(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glCopyColorTable(target, internalFormat, x, y, width);
+}
+
+void gl2_0_glColorTableParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glColorTableParameteriv(target, pname, params);
+}
+
+void gl2_0_glColorTableParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glColorTableParameterfv(target, pname, params);
+}
+
+void gl2_0_glColorTable(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLenum format, GLenum gltype, const GLvoid* table)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glColorTable(target, internalFormat, width, format, gltype, table);
+}
+
+void gl2_0_glMultTransposeMatrixd(void *_glfuncs, const GLdouble* m)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glMultTransposeMatrixd(m);
+}
+
+void gl2_0_glMultTransposeMatrixf(void *_glfuncs, const GLfloat* m)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glMultTransposeMatrixf(m);
+}
+
+void gl2_0_glLoadTransposeMatrixd(void *_glfuncs, const GLdouble* m)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glLoadTransposeMatrixd(m);
+}
+
+void gl2_0_glLoadTransposeMatrixf(void *_glfuncs, const GLfloat* m)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glLoadTransposeMatrixf(m);
+}
+
+void gl2_0_glMultiTexCoord4sv(void *_glfuncs, GLenum target, const GLshort* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4sv(target, v);
+}
+
+void gl2_0_glMultiTexCoord4s(void *_glfuncs, GLenum target, GLshort s, GLshort t, GLshort r, GLshort q)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4s(target, s, t, r, q);
+}
+
+void gl2_0_glMultiTexCoord4iv(void *_glfuncs, GLenum target, const GLint* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4iv(target, v);
+}
+
+void gl2_0_glMultiTexCoord4i(void *_glfuncs, GLenum target, GLint s, GLint t, GLint r, GLint q)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4i(target, s, t, r, q);
+}
+
+void gl2_0_glMultiTexCoord4fv(void *_glfuncs, GLenum target, const GLfloat* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4fv(target, v);
+}
+
+void gl2_0_glMultiTexCoord4f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4f(target, s, t, r, q);
+}
+
+void gl2_0_glMultiTexCoord4dv(void *_glfuncs, GLenum target, const GLdouble* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4dv(target, v);
+}
+
+void gl2_0_glMultiTexCoord4d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4d(target, s, t, r, q);
+}
+
+void gl2_0_glMultiTexCoord3sv(void *_glfuncs, GLenum target, const GLshort* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3sv(target, v);
+}
+
+void gl2_0_glMultiTexCoord3s(void *_glfuncs, GLenum target, GLshort s, GLshort t, GLshort r)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3s(target, s, t, r);
+}
+
+void gl2_0_glMultiTexCoord3iv(void *_glfuncs, GLenum target, const GLint* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3iv(target, v);
+}
+
+void gl2_0_glMultiTexCoord3i(void *_glfuncs, GLenum target, GLint s, GLint t, GLint r)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3i(target, s, t, r);
+}
+
+void gl2_0_glMultiTexCoord3fv(void *_glfuncs, GLenum target, const GLfloat* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3fv(target, v);
+}
+
+void gl2_0_glMultiTexCoord3f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t, GLfloat r)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3f(target, s, t, r);
+}
+
+void gl2_0_glMultiTexCoord3dv(void *_glfuncs, GLenum target, const GLdouble* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3dv(target, v);
+}
+
+void gl2_0_glMultiTexCoord3d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t, GLdouble r)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3d(target, s, t, r);
+}
+
+void gl2_0_glMultiTexCoord2sv(void *_glfuncs, GLenum target, const GLshort* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2sv(target, v);
+}
+
+void gl2_0_glMultiTexCoord2s(void *_glfuncs, GLenum target, GLshort s, GLshort t)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2s(target, s, t);
+}
+
+void gl2_0_glMultiTexCoord2iv(void *_glfuncs, GLenum target, const GLint* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2iv(target, v);
+}
+
+void gl2_0_glMultiTexCoord2i(void *_glfuncs, GLenum target, GLint s, GLint t)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2i(target, s, t);
+}
+
+void gl2_0_glMultiTexCoord2fv(void *_glfuncs, GLenum target, const GLfloat* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2fv(target, v);
+}
+
+void gl2_0_glMultiTexCoord2f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2f(target, s, t);
+}
+
+void gl2_0_glMultiTexCoord2dv(void *_glfuncs, GLenum target, const GLdouble* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2dv(target, v);
+}
+
+void gl2_0_glMultiTexCoord2d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2d(target, s, t);
+}
+
+void gl2_0_glMultiTexCoord1sv(void *_glfuncs, GLenum target, const GLshort* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1sv(target, v);
+}
+
+void gl2_0_glMultiTexCoord1s(void *_glfuncs, GLenum target, GLshort s)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1s(target, s);
+}
+
+void gl2_0_glMultiTexCoord1iv(void *_glfuncs, GLenum target, const GLint* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1iv(target, v);
+}
+
+void gl2_0_glMultiTexCoord1i(void *_glfuncs, GLenum target, GLint s)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1i(target, s);
+}
+
+void gl2_0_glMultiTexCoord1fv(void *_glfuncs, GLenum target, const GLfloat* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1fv(target, v);
+}
+
+void gl2_0_glMultiTexCoord1f(void *_glfuncs, GLenum target, GLfloat s)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1f(target, s);
+}
+
+void gl2_0_glMultiTexCoord1dv(void *_glfuncs, GLenum target, const GLdouble* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1dv(target, v);
+}
+
+void gl2_0_glMultiTexCoord1d(void *_glfuncs, GLenum target, GLdouble s)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1d(target, s);
+}
+
+void gl2_0_glClientActiveTexture(void *_glfuncs, GLenum texture)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glClientActiveTexture(texture);
+}
+
+void gl2_0_glWindowPos3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glWindowPos3sv(v);
+}
+
+void gl2_0_glWindowPos3s(void *_glfuncs, GLshort x, GLshort y, GLshort z)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glWindowPos3s(x, y, z);
+}
+
+void gl2_0_glWindowPos3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glWindowPos3iv(v);
+}
+
+void gl2_0_glWindowPos3i(void *_glfuncs, GLint x, GLint y, GLint z)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glWindowPos3i(x, y, z);
+}
+
+void gl2_0_glWindowPos3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glWindowPos3fv(v);
+}
+
+void gl2_0_glWindowPos3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glWindowPos3f(x, y, z);
+}
+
+void gl2_0_glWindowPos3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glWindowPos3dv(v);
+}
+
+void gl2_0_glWindowPos3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glWindowPos3d(x, y, z);
+}
+
+void gl2_0_glWindowPos2sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glWindowPos2sv(v);
+}
+
+void gl2_0_glWindowPos2s(void *_glfuncs, GLshort x, GLshort y)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glWindowPos2s(x, y);
+}
+
+void gl2_0_glWindowPos2iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glWindowPos2iv(v);
+}
+
+void gl2_0_glWindowPos2i(void *_glfuncs, GLint x, GLint y)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glWindowPos2i(x, y);
+}
+
+void gl2_0_glWindowPos2fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glWindowPos2fv(v);
+}
+
+void gl2_0_glWindowPos2f(void *_glfuncs, GLfloat x, GLfloat y)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glWindowPos2f(x, y);
+}
+
+void gl2_0_glWindowPos2dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glWindowPos2dv(v);
+}
+
+void gl2_0_glWindowPos2d(void *_glfuncs, GLdouble x, GLdouble y)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glWindowPos2d(x, y);
+}
+
+void gl2_0_glSecondaryColorPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glSecondaryColorPointer(size, gltype, stride, pointer);
+}
+
+void gl2_0_glSecondaryColor3usv(void *_glfuncs, const GLushort* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3usv(v);
+}
+
+void gl2_0_glSecondaryColor3us(void *_glfuncs, GLushort red, GLushort green, GLushort blue)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3us(red, green, blue);
+}
+
+void gl2_0_glSecondaryColor3uiv(void *_glfuncs, const GLuint* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3uiv(v);
+}
+
+void gl2_0_glSecondaryColor3ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3ui(red, green, blue);
+}
+
+void gl2_0_glSecondaryColor3ubv(void *_glfuncs, const GLubyte* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3ubv(v);
+}
+
+void gl2_0_glSecondaryColor3ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3ub(red, green, blue);
+}
+
+void gl2_0_glSecondaryColor3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3sv(v);
+}
+
+void gl2_0_glSecondaryColor3s(void *_glfuncs, GLshort red, GLshort green, GLshort blue)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3s(red, green, blue);
+}
+
+void gl2_0_glSecondaryColor3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3iv(v);
+}
+
+void gl2_0_glSecondaryColor3i(void *_glfuncs, GLint red, GLint green, GLint blue)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3i(red, green, blue);
+}
+
+void gl2_0_glSecondaryColor3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3fv(v);
+}
+
+void gl2_0_glSecondaryColor3f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3f(red, green, blue);
+}
+
+void gl2_0_glSecondaryColor3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3dv(v);
+}
+
+void gl2_0_glSecondaryColor3d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3d(red, green, blue);
+}
+
+void gl2_0_glSecondaryColor3bv(void *_glfuncs, const GLbyte* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3bv(v);
+}
+
+void gl2_0_glSecondaryColor3b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3b(red, green, blue);
+}
+
+void gl2_0_glFogCoordPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glFogCoordPointer(gltype, stride, pointer);
+}
+
+void gl2_0_glFogCoorddv(void *_glfuncs, const GLdouble* coord)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glFogCoorddv(coord);
+}
+
+void gl2_0_glFogCoordd(void *_glfuncs, GLdouble coord)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glFogCoordd(coord);
+}
+
+void gl2_0_glFogCoordfv(void *_glfuncs, const GLfloat* coord)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glFogCoordfv(coord);
+}
+
+void gl2_0_glFogCoordf(void *_glfuncs, GLfloat coord)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glFogCoordf(coord);
+}
+
+void gl2_0_glVertexAttrib4usv(void *_glfuncs, GLuint index, const GLushort* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4usv(index, v);
+}
+
+void gl2_0_glVertexAttrib4uiv(void *_glfuncs, GLuint index, const GLuint* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4uiv(index, v);
+}
+
+void gl2_0_glVertexAttrib4ubv(void *_glfuncs, GLuint index, const GLubyte* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4ubv(index, v);
+}
+
+void gl2_0_glVertexAttrib4sv(void *_glfuncs, GLuint index, const GLshort* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4sv(index, v);
+}
+
+void gl2_0_glVertexAttrib4s(void *_glfuncs, GLuint index, GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4s(index, x, y, z, w);
+}
+
+void gl2_0_glVertexAttrib4iv(void *_glfuncs, GLuint index, const GLint* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4iv(index, v);
+}
+
+void gl2_0_glVertexAttrib4fv(void *_glfuncs, GLuint index, const GLfloat* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4fv(index, v);
+}
+
+void gl2_0_glVertexAttrib4f(void *_glfuncs, GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4f(index, x, y, z, w);
+}
+
+void gl2_0_glVertexAttrib4dv(void *_glfuncs, GLuint index, const GLdouble* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4dv(index, v);
+}
+
+void gl2_0_glVertexAttrib4d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4d(index, x, y, z, w);
+}
+
+void gl2_0_glVertexAttrib4bv(void *_glfuncs, GLuint index, const GLbyte* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4bv(index, v);
+}
+
+void gl2_0_glVertexAttrib4Nusv(void *_glfuncs, GLuint index, const GLushort* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Nusv(index, v);
+}
+
+void gl2_0_glVertexAttrib4Nuiv(void *_glfuncs, GLuint index, const GLuint* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Nuiv(index, v);
+}
+
+void gl2_0_glVertexAttrib4Nubv(void *_glfuncs, GLuint index, const GLubyte* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Nubv(index, v);
+}
+
+void gl2_0_glVertexAttrib4Nub(void *_glfuncs, GLuint index, GLubyte x, GLubyte y, GLubyte z, GLubyte w)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Nub(index, x, y, z, w);
+}
+
+void gl2_0_glVertexAttrib4Nsv(void *_glfuncs, GLuint index, const GLshort* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Nsv(index, v);
+}
+
+void gl2_0_glVertexAttrib4Niv(void *_glfuncs, GLuint index, const GLint* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Niv(index, v);
+}
+
+void gl2_0_glVertexAttrib4Nbv(void *_glfuncs, GLuint index, const GLbyte* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Nbv(index, v);
+}
+
+void gl2_0_glVertexAttrib3sv(void *_glfuncs, GLuint index, const GLshort* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib3sv(index, v);
+}
+
+void gl2_0_glVertexAttrib3s(void *_glfuncs, GLuint index, GLshort x, GLshort y, GLshort z)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib3s(index, x, y, z);
+}
+
+void gl2_0_glVertexAttrib3fv(void *_glfuncs, GLuint index, const GLfloat* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib3fv(index, v);
+}
+
+void gl2_0_glVertexAttrib3f(void *_glfuncs, GLuint index, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib3f(index, x, y, z);
+}
+
+void gl2_0_glVertexAttrib3dv(void *_glfuncs, GLuint index, const GLdouble* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib3dv(index, v);
+}
+
+void gl2_0_glVertexAttrib3d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib3d(index, x, y, z);
+}
+
+void gl2_0_glVertexAttrib2sv(void *_glfuncs, GLuint index, const GLshort* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib2sv(index, v);
+}
+
+void gl2_0_glVertexAttrib2s(void *_glfuncs, GLuint index, GLshort x, GLshort y)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib2s(index, x, y);
+}
+
+void gl2_0_glVertexAttrib2fv(void *_glfuncs, GLuint index, const GLfloat* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib2fv(index, v);
+}
+
+void gl2_0_glVertexAttrib2f(void *_glfuncs, GLuint index, GLfloat x, GLfloat y)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib2f(index, x, y);
+}
+
+void gl2_0_glVertexAttrib2dv(void *_glfuncs, GLuint index, const GLdouble* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib2dv(index, v);
+}
+
+void gl2_0_glVertexAttrib2d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib2d(index, x, y);
+}
+
+void gl2_0_glVertexAttrib1sv(void *_glfuncs, GLuint index, const GLshort* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib1sv(index, v);
+}
+
+void gl2_0_glVertexAttrib1s(void *_glfuncs, GLuint index, GLshort x)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib1s(index, x);
+}
+
+void gl2_0_glVertexAttrib1fv(void *_glfuncs, GLuint index, const GLfloat* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib1fv(index, v);
+}
+
+void gl2_0_glVertexAttrib1f(void *_glfuncs, GLuint index, GLfloat x)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib1f(index, x);
+}
+
+void gl2_0_glVertexAttrib1dv(void *_glfuncs, GLuint index, const GLdouble* v)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib1dv(index, v);
+}
+
+void gl2_0_glVertexAttrib1d(void *_glfuncs, GLuint index, GLdouble x)
+{
+ QOpenGLFunctions_2_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib1d(index, x);
+}
+
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/2.0/funcs.h b/Godeps/_workspace/src/github.com/obscuren/qml/gl/2.0/funcs.h
new file mode 100644
index 000000000..ffa1a2a83
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/2.0/funcs.h
@@ -0,0 +1,613 @@
+
+// ** file automatically generated by glgen -- do not edit manually **
+
+#ifndef __cplusplus
+#include <inttypes.h>
+#include <stddef.h>
+typedef unsigned int GLenum;
+typedef unsigned char GLboolean;
+typedef unsigned int GLbitfield;
+typedef void GLvoid;
+typedef char GLchar;
+typedef signed char GLbyte; /* 1-byte signed */
+typedef short GLshort; /* 2-byte signed */
+typedef int GLint; /* 4-byte signed */
+typedef unsigned char GLubyte; /* 1-byte unsigned */
+typedef unsigned short GLushort; /* 2-byte unsigned */
+typedef unsigned int GLuint; /* 4-byte unsigned */
+typedef int GLsizei; /* 4-byte signed */
+typedef float GLfloat; /* single precision float */
+typedef float GLclampf; /* single precision float in [0,1] */
+typedef double GLdouble; /* double precision float */
+typedef double GLclampd; /* double precision float in [0,1] */
+typedef int64_t GLint64;
+typedef uint64_t GLuint64;
+typedef ptrdiff_t GLintptr;
+typedef ptrdiff_t GLsizeiptr;
+typedef ptrdiff_t GLintptrARB;
+typedef ptrdiff_t GLsizeiptrARB;
+typedef struct __GLsync *GLsync;
+#endif
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+void *gl2_0_funcs();
+
+void gl2_0_glViewport(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl2_0_glDepthRange(void *_glfuncs, GLdouble nearVal, GLdouble farVal);
+GLboolean gl2_0_glIsEnabled(void *_glfuncs, GLenum cap);
+void gl2_0_glGetTexLevelParameteriv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLint* params);
+void gl2_0_glGetTexLevelParameterfv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLfloat* params);
+void gl2_0_glGetTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl2_0_glGetTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl2_0_glGetTexImage(void *_glfuncs, GLenum target, GLint level, GLenum format, GLenum gltype, GLvoid* pixels);
+void gl2_0_glGetIntegerv(void *_glfuncs, GLenum pname, GLint* params);
+void gl2_0_glGetFloatv(void *_glfuncs, GLenum pname, GLfloat* params);
+GLenum gl2_0_glGetError(void *_glfuncs);
+void gl2_0_glGetDoublev(void *_glfuncs, GLenum pname, GLdouble* params);
+void gl2_0_glGetBooleanv(void *_glfuncs, GLenum pname, GLboolean* params);
+void gl2_0_glReadPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum gltype, GLvoid* pixels);
+void gl2_0_glReadBuffer(void *_glfuncs, GLenum mode);
+void gl2_0_glPixelStorei(void *_glfuncs, GLenum pname, GLint param);
+void gl2_0_glPixelStoref(void *_glfuncs, GLenum pname, GLfloat param);
+void gl2_0_glDepthFunc(void *_glfuncs, GLenum glfunc);
+void gl2_0_glStencilOp(void *_glfuncs, GLenum fail, GLenum zfail, GLenum zpass);
+void gl2_0_glStencilFunc(void *_glfuncs, GLenum glfunc, GLint ref, GLuint mask);
+void gl2_0_glLogicOp(void *_glfuncs, GLenum opcode);
+void gl2_0_glBlendFunc(void *_glfuncs, GLenum sfactor, GLenum dfactor);
+void gl2_0_glFlush(void *_glfuncs);
+void gl2_0_glFinish(void *_glfuncs);
+void gl2_0_glEnable(void *_glfuncs, GLenum cap);
+void gl2_0_glDisable(void *_glfuncs, GLenum cap);
+void gl2_0_glDepthMask(void *_glfuncs, GLboolean flag);
+void gl2_0_glColorMask(void *_glfuncs, GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha);
+void gl2_0_glStencilMask(void *_glfuncs, GLuint mask);
+void gl2_0_glClearDepth(void *_glfuncs, GLdouble depth);
+void gl2_0_glClearStencil(void *_glfuncs, GLint s);
+void gl2_0_glClearColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl2_0_glClear(void *_glfuncs, GLbitfield mask);
+void gl2_0_glDrawBuffer(void *_glfuncs, GLenum mode);
+void gl2_0_glTexImage2D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl2_0_glTexImage1D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl2_0_glTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl2_0_glTexParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint param);
+void gl2_0_glTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl2_0_glTexParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param);
+void gl2_0_glScissor(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl2_0_glPolygonMode(void *_glfuncs, GLenum face, GLenum mode);
+void gl2_0_glPointSize(void *_glfuncs, GLfloat size);
+void gl2_0_glLineWidth(void *_glfuncs, GLfloat width);
+void gl2_0_glHint(void *_glfuncs, GLenum target, GLenum mode);
+void gl2_0_glFrontFace(void *_glfuncs, GLenum mode);
+void gl2_0_glCullFace(void *_glfuncs, GLenum mode);
+void gl2_0_glIndexubv(void *_glfuncs, const GLubyte* c);
+void gl2_0_glIndexub(void *_glfuncs, GLubyte c);
+GLboolean gl2_0_glIsTexture(void *_glfuncs, GLuint texture);
+void gl2_0_glGenTextures(void *_glfuncs, GLsizei n, GLuint* textures);
+void gl2_0_glDeleteTextures(void *_glfuncs, GLsizei n, const GLuint* textures);
+void gl2_0_glBindTexture(void *_glfuncs, GLenum target, GLuint texture);
+void gl2_0_glTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl2_0_glTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl2_0_glCopyTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl2_0_glCopyTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width);
+void gl2_0_glCopyTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border);
+void gl2_0_glCopyTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLint border);
+void gl2_0_glPolygonOffset(void *_glfuncs, GLfloat factor, GLfloat units);
+void gl2_0_glDrawElements(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices);
+void gl2_0_glDrawArrays(void *_glfuncs, GLenum mode, GLint first, GLsizei count);
+void gl2_0_glCopyTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl2_0_glTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl2_0_glTexImage3D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl2_0_glDrawRangeElements(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices);
+void gl2_0_glBlendEquation(void *_glfuncs, GLenum mode);
+void gl2_0_glBlendColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl2_0_glGetCompressedTexImage(void *_glfuncs, GLenum target, GLint level, GLvoid* img);
+void gl2_0_glCompressedTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid* data);
+void gl2_0_glCompressedTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid* data);
+void gl2_0_glCompressedTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid* data);
+void gl2_0_glCompressedTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid* data);
+void gl2_0_glCompressedTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid* data);
+void gl2_0_glCompressedTexImage3D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid* data);
+void gl2_0_glSampleCoverage(void *_glfuncs, GLfloat value, GLboolean invert);
+void gl2_0_glActiveTexture(void *_glfuncs, GLenum texture);
+void gl2_0_glPointParameteriv(void *_glfuncs, GLenum pname, const GLint* params);
+void gl2_0_glPointParameteri(void *_glfuncs, GLenum pname, GLint param);
+void gl2_0_glPointParameterfv(void *_glfuncs, GLenum pname, const GLfloat* params);
+void gl2_0_glPointParameterf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl2_0_glMultiDrawArrays(void *_glfuncs, GLenum mode, const GLint* first, const GLsizei* count, GLsizei drawcount);
+void gl2_0_glBlendFuncSeparate(void *_glfuncs, GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha);
+void gl2_0_glGetBufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+GLboolean gl2_0_glUnmapBuffer(void *_glfuncs, GLenum target);
+void gl2_0_glGetBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, GLvoid* data);
+void gl2_0_glBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid* data);
+void gl2_0_glBufferData(void *_glfuncs, GLenum target, GLsizeiptr size, const GLvoid* data, GLenum usage);
+GLboolean gl2_0_glIsBuffer(void *_glfuncs, GLuint buffer);
+void gl2_0_glGenBuffers(void *_glfuncs, GLsizei n, GLuint* buffers);
+void gl2_0_glDeleteBuffers(void *_glfuncs, GLsizei n, const GLuint* buffers);
+void gl2_0_glBindBuffer(void *_glfuncs, GLenum target, GLuint buffer);
+void gl2_0_glGetQueryObjectuiv(void *_glfuncs, GLuint id, GLenum pname, GLuint* params);
+void gl2_0_glGetQueryObjectiv(void *_glfuncs, GLuint id, GLenum pname, GLint* params);
+void gl2_0_glGetQueryiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl2_0_glEndQuery(void *_glfuncs, GLenum target);
+void gl2_0_glBeginQuery(void *_glfuncs, GLenum target, GLuint id);
+GLboolean gl2_0_glIsQuery(void *_glfuncs, GLuint id);
+void gl2_0_glDeleteQueries(void *_glfuncs, GLsizei n, const GLuint* ids);
+void gl2_0_glGenQueries(void *_glfuncs, GLsizei n, GLuint* ids);
+void gl2_0_glVertexAttribPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLboolean normalized, GLsizei stride, const GLvoid* offset);
+void gl2_0_glValidateProgram(void *_glfuncs, GLuint program);
+void gl2_0_glUniformMatrix4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl2_0_glUniformMatrix3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl2_0_glUniformMatrix2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl2_0_glUniform4iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl2_0_glUniform3iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl2_0_glUniform2iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl2_0_glUniform1iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl2_0_glUniform4fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl2_0_glUniform3fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl2_0_glUniform2fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl2_0_glUniform1fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl2_0_glUniform4i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2, GLint v3);
+void gl2_0_glUniform3i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2);
+void gl2_0_glUniform2i(void *_glfuncs, GLint location, GLint v0, GLint v1);
+void gl2_0_glUniform1i(void *_glfuncs, GLint location, GLint v0);
+void gl2_0_glUniform4f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3);
+void gl2_0_glUniform3f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2);
+void gl2_0_glUniform2f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1);
+void gl2_0_glUniform1f(void *_glfuncs, GLint location, GLfloat v0);
+void gl2_0_glUseProgram(void *_glfuncs, GLuint program);
+void gl2_0_glShaderSource(void *_glfuncs, GLuint shader, GLsizei count, const GLchar** source, const GLint* length);
+void gl2_0_glLinkProgram(void *_glfuncs, GLuint program);
+GLboolean gl2_0_glIsShader(void *_glfuncs, GLuint shader);
+GLboolean gl2_0_glIsProgram(void *_glfuncs, GLuint program);
+void gl2_0_glGetVertexAttribiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params);
+void gl2_0_glGetVertexAttribfv(void *_glfuncs, GLuint index, GLenum pname, GLfloat* params);
+void gl2_0_glGetVertexAttribdv(void *_glfuncs, GLuint index, GLenum pname, GLdouble* params);
+void gl2_0_glGetUniformiv(void *_glfuncs, GLuint program, GLint location, GLint* params);
+void gl2_0_glGetUniformfv(void *_glfuncs, GLuint program, GLint location, GLfloat* params);
+GLint gl2_0_glGetUniformLocation(void *_glfuncs, GLuint program, const GLchar* name);
+void gl2_0_glGetShaderSource(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* source);
+void gl2_0_glGetShaderInfoLog(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* infoLog);
+void gl2_0_glGetShaderiv(void *_glfuncs, GLuint shader, GLenum pname, GLint* params);
+void gl2_0_glGetProgramInfoLog(void *_glfuncs, GLuint program, GLsizei bufSize, GLsizei* length, GLchar* infoLog);
+void gl2_0_glGetProgramiv(void *_glfuncs, GLuint program, GLenum pname, GLint* params);
+GLint gl2_0_glGetAttribLocation(void *_glfuncs, GLuint program, const GLchar* name);
+void gl2_0_glGetAttachedShaders(void *_glfuncs, GLuint program, GLsizei maxCount, GLsizei* count, GLuint* obj);
+void gl2_0_glGetActiveUniform(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name);
+void gl2_0_glGetActiveAttrib(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name);
+void gl2_0_glEnableVertexAttribArray(void *_glfuncs, GLuint index);
+void gl2_0_glDisableVertexAttribArray(void *_glfuncs, GLuint index);
+void gl2_0_glDetachShader(void *_glfuncs, GLuint program, GLuint shader);
+void gl2_0_glDeleteShader(void *_glfuncs, GLuint shader);
+void gl2_0_glDeleteProgram(void *_glfuncs, GLuint program);
+GLuint gl2_0_glCreateShader(void *_glfuncs, GLenum gltype);
+GLuint gl2_0_glCreateProgram(void *_glfuncs);
+void gl2_0_glCompileShader(void *_glfuncs, GLuint shader);
+void gl2_0_glBindAttribLocation(void *_glfuncs, GLuint program, GLuint index, const GLchar* name);
+void gl2_0_glAttachShader(void *_glfuncs, GLuint program, GLuint shader);
+void gl2_0_glStencilMaskSeparate(void *_glfuncs, GLenum face, GLuint mask);
+void gl2_0_glStencilFuncSeparate(void *_glfuncs, GLenum face, GLenum glfunc, GLint ref, GLuint mask);
+void gl2_0_glStencilOpSeparate(void *_glfuncs, GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass);
+void gl2_0_glDrawBuffers(void *_glfuncs, GLsizei n, const GLenum* bufs);
+void gl2_0_glBlendEquationSeparate(void *_glfuncs, GLenum modeRGB, GLenum modeAlpha);
+void gl2_0_glTranslatef(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl2_0_glTranslated(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl2_0_glScalef(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl2_0_glScaled(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl2_0_glRotatef(void *_glfuncs, GLfloat angle, GLfloat x, GLfloat y, GLfloat z);
+void gl2_0_glRotated(void *_glfuncs, GLdouble angle, GLdouble x, GLdouble y, GLdouble z);
+void gl2_0_glPushMatrix(void *_glfuncs);
+void gl2_0_glPopMatrix(void *_glfuncs);
+void gl2_0_glOrtho(void *_glfuncs, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+void gl2_0_glMultMatrixd(void *_glfuncs, const GLdouble* m);
+void gl2_0_glMultMatrixf(void *_glfuncs, const GLfloat* m);
+void gl2_0_glMatrixMode(void *_glfuncs, GLenum mode);
+void gl2_0_glLoadMatrixd(void *_glfuncs, const GLdouble* m);
+void gl2_0_glLoadMatrixf(void *_glfuncs, const GLfloat* m);
+void gl2_0_glLoadIdentity(void *_glfuncs);
+void gl2_0_glFrustum(void *_glfuncs, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+GLboolean gl2_0_glIsList(void *_glfuncs, GLuint list);
+void gl2_0_glGetTexGeniv(void *_glfuncs, GLenum coord, GLenum pname, GLint* params);
+void gl2_0_glGetTexGenfv(void *_glfuncs, GLenum coord, GLenum pname, GLfloat* params);
+void gl2_0_glGetTexGendv(void *_glfuncs, GLenum coord, GLenum pname, GLdouble* params);
+void gl2_0_glGetTexEnviv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl2_0_glGetTexEnvfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl2_0_glGetPolygonStipple(void *_glfuncs, GLubyte* mask);
+void gl2_0_glGetPixelMapusv(void *_glfuncs, GLenum glmap, GLushort* values);
+void gl2_0_glGetPixelMapuiv(void *_glfuncs, GLenum glmap, GLuint* values);
+void gl2_0_glGetPixelMapfv(void *_glfuncs, GLenum glmap, GLfloat* values);
+void gl2_0_glGetMaterialiv(void *_glfuncs, GLenum face, GLenum pname, GLint* params);
+void gl2_0_glGetMaterialfv(void *_glfuncs, GLenum face, GLenum pname, GLfloat* params);
+void gl2_0_glGetMapiv(void *_glfuncs, GLenum target, GLenum query, GLint* v);
+void gl2_0_glGetMapfv(void *_glfuncs, GLenum target, GLenum query, GLfloat* v);
+void gl2_0_glGetMapdv(void *_glfuncs, GLenum target, GLenum query, GLdouble* v);
+void gl2_0_glGetLightiv(void *_glfuncs, GLenum light, GLenum pname, GLint* params);
+void gl2_0_glGetLightfv(void *_glfuncs, GLenum light, GLenum pname, GLfloat* params);
+void gl2_0_glGetClipPlane(void *_glfuncs, GLenum plane, GLdouble* equation);
+void gl2_0_glDrawPixels(void *_glfuncs, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl2_0_glCopyPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum gltype);
+void gl2_0_glPixelMapusv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLushort* values);
+void gl2_0_glPixelMapuiv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLuint* values);
+void gl2_0_glPixelMapfv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLfloat* values);
+void gl2_0_glPixelTransferi(void *_glfuncs, GLenum pname, GLint param);
+void gl2_0_glPixelTransferf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl2_0_glPixelZoom(void *_glfuncs, GLfloat xfactor, GLfloat yfactor);
+void gl2_0_glAlphaFunc(void *_glfuncs, GLenum glfunc, GLfloat ref);
+void gl2_0_glEvalPoint2(void *_glfuncs, GLint i, GLint j);
+void gl2_0_glEvalMesh2(void *_glfuncs, GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2);
+void gl2_0_glEvalPoint1(void *_glfuncs, GLint i);
+void gl2_0_glEvalMesh1(void *_glfuncs, GLenum mode, GLint i1, GLint i2);
+void gl2_0_glEvalCoord2fv(void *_glfuncs, const GLfloat* u);
+void gl2_0_glEvalCoord2f(void *_glfuncs, GLfloat u, GLfloat v);
+void gl2_0_glEvalCoord2dv(void *_glfuncs, const GLdouble* u);
+void gl2_0_glEvalCoord2d(void *_glfuncs, GLdouble u, GLdouble v);
+void gl2_0_glEvalCoord1fv(void *_glfuncs, const GLfloat* u);
+void gl2_0_glEvalCoord1f(void *_glfuncs, GLfloat u);
+void gl2_0_glEvalCoord1dv(void *_glfuncs, const GLdouble* u);
+void gl2_0_glEvalCoord1d(void *_glfuncs, GLdouble u);
+void gl2_0_glMapGrid2f(void *_glfuncs, GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2);
+void gl2_0_glMapGrid2d(void *_glfuncs, GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2);
+void gl2_0_glMapGrid1f(void *_glfuncs, GLint un, GLfloat u1, GLfloat u2);
+void gl2_0_glMapGrid1d(void *_glfuncs, GLint un, GLdouble u1, GLdouble u2);
+void gl2_0_glMap2f(void *_glfuncs, GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat* points);
+void gl2_0_glMap2d(void *_glfuncs, GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble* points);
+void gl2_0_glMap1f(void *_glfuncs, GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat* points);
+void gl2_0_glMap1d(void *_glfuncs, GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble* points);
+void gl2_0_glPushAttrib(void *_glfuncs, GLbitfield mask);
+void gl2_0_glPopAttrib(void *_glfuncs);
+void gl2_0_glAccum(void *_glfuncs, GLenum op, GLfloat value);
+void gl2_0_glIndexMask(void *_glfuncs, GLuint mask);
+void gl2_0_glClearIndex(void *_glfuncs, GLfloat c);
+void gl2_0_glClearAccum(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl2_0_glPushName(void *_glfuncs, GLuint name);
+void gl2_0_glPopName(void *_glfuncs);
+void gl2_0_glPassThrough(void *_glfuncs, GLfloat token);
+void gl2_0_glLoadName(void *_glfuncs, GLuint name);
+void gl2_0_glInitNames(void *_glfuncs);
+GLint gl2_0_glRenderMode(void *_glfuncs, GLenum mode);
+void gl2_0_glSelectBuffer(void *_glfuncs, GLsizei size, GLuint* buffer);
+void gl2_0_glFeedbackBuffer(void *_glfuncs, GLsizei size, GLenum gltype, GLfloat* buffer);
+void gl2_0_glTexGeniv(void *_glfuncs, GLenum coord, GLenum pname, const GLint* params);
+void gl2_0_glTexGeni(void *_glfuncs, GLenum coord, GLenum pname, GLint param);
+void gl2_0_glTexGenfv(void *_glfuncs, GLenum coord, GLenum pname, const GLfloat* params);
+void gl2_0_glTexGenf(void *_glfuncs, GLenum coord, GLenum pname, GLfloat param);
+void gl2_0_glTexGendv(void *_glfuncs, GLenum coord, GLenum pname, const GLdouble* params);
+void gl2_0_glTexGend(void *_glfuncs, GLenum coord, GLenum pname, GLdouble param);
+void gl2_0_glTexEnviv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl2_0_glTexEnvi(void *_glfuncs, GLenum target, GLenum pname, GLint param);
+void gl2_0_glTexEnvfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl2_0_glTexEnvf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param);
+void gl2_0_glShadeModel(void *_glfuncs, GLenum mode);
+void gl2_0_glPolygonStipple(void *_glfuncs, const GLubyte* mask);
+void gl2_0_glMaterialiv(void *_glfuncs, GLenum face, GLenum pname, const GLint* params);
+void gl2_0_glMateriali(void *_glfuncs, GLenum face, GLenum pname, GLint param);
+void gl2_0_glMaterialfv(void *_glfuncs, GLenum face, GLenum pname, const GLfloat* params);
+void gl2_0_glMaterialf(void *_glfuncs, GLenum face, GLenum pname, GLfloat param);
+void gl2_0_glLineStipple(void *_glfuncs, GLint factor, GLushort pattern);
+void gl2_0_glLightModeliv(void *_glfuncs, GLenum pname, const GLint* params);
+void gl2_0_glLightModeli(void *_glfuncs, GLenum pname, GLint param);
+void gl2_0_glLightModelfv(void *_glfuncs, GLenum pname, const GLfloat* params);
+void gl2_0_glLightModelf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl2_0_glLightiv(void *_glfuncs, GLenum light, GLenum pname, const GLint* params);
+void gl2_0_glLighti(void *_glfuncs, GLenum light, GLenum pname, GLint param);
+void gl2_0_glLightfv(void *_glfuncs, GLenum light, GLenum pname, const GLfloat* params);
+void gl2_0_glLightf(void *_glfuncs, GLenum light, GLenum pname, GLfloat param);
+void gl2_0_glFogiv(void *_glfuncs, GLenum pname, const GLint* params);
+void gl2_0_glFogi(void *_glfuncs, GLenum pname, GLint param);
+void gl2_0_glFogfv(void *_glfuncs, GLenum pname, const GLfloat* params);
+void gl2_0_glFogf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl2_0_glColorMaterial(void *_glfuncs, GLenum face, GLenum mode);
+void gl2_0_glClipPlane(void *_glfuncs, GLenum plane, const GLdouble* equation);
+void gl2_0_glVertex4sv(void *_glfuncs, const GLshort* v);
+void gl2_0_glVertex4s(void *_glfuncs, GLshort x, GLshort y, GLshort z, GLshort w);
+void gl2_0_glVertex4iv(void *_glfuncs, const GLint* v);
+void gl2_0_glVertex4i(void *_glfuncs, GLint x, GLint y, GLint z, GLint w);
+void gl2_0_glVertex4fv(void *_glfuncs, const GLfloat* v);
+void gl2_0_glVertex4f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+void gl2_0_glVertex4dv(void *_glfuncs, const GLdouble* v);
+void gl2_0_glVertex4d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+void gl2_0_glVertex3sv(void *_glfuncs, const GLshort* v);
+void gl2_0_glVertex3s(void *_glfuncs, GLshort x, GLshort y, GLshort z);
+void gl2_0_glVertex3iv(void *_glfuncs, const GLint* v);
+void gl2_0_glVertex3i(void *_glfuncs, GLint x, GLint y, GLint z);
+void gl2_0_glVertex3fv(void *_glfuncs, const GLfloat* v);
+void gl2_0_glVertex3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl2_0_glVertex3dv(void *_glfuncs, const GLdouble* v);
+void gl2_0_glVertex3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl2_0_glVertex2sv(void *_glfuncs, const GLshort* v);
+void gl2_0_glVertex2s(void *_glfuncs, GLshort x, GLshort y);
+void gl2_0_glVertex2iv(void *_glfuncs, const GLint* v);
+void gl2_0_glVertex2i(void *_glfuncs, GLint x, GLint y);
+void gl2_0_glVertex2fv(void *_glfuncs, const GLfloat* v);
+void gl2_0_glVertex2f(void *_glfuncs, GLfloat x, GLfloat y);
+void gl2_0_glVertex2dv(void *_glfuncs, const GLdouble* v);
+void gl2_0_glVertex2d(void *_glfuncs, GLdouble x, GLdouble y);
+void gl2_0_glTexCoord4sv(void *_glfuncs, const GLshort* v);
+void gl2_0_glTexCoord4s(void *_glfuncs, GLshort s, GLshort t, GLshort r, GLshort q);
+void gl2_0_glTexCoord4iv(void *_glfuncs, const GLint* v);
+void gl2_0_glTexCoord4i(void *_glfuncs, GLint s, GLint t, GLint r, GLint q);
+void gl2_0_glTexCoord4fv(void *_glfuncs, const GLfloat* v);
+void gl2_0_glTexCoord4f(void *_glfuncs, GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+void gl2_0_glTexCoord4dv(void *_glfuncs, const GLdouble* v);
+void gl2_0_glTexCoord4d(void *_glfuncs, GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+void gl2_0_glTexCoord3sv(void *_glfuncs, const GLshort* v);
+void gl2_0_glTexCoord3s(void *_glfuncs, GLshort s, GLshort t, GLshort r);
+void gl2_0_glTexCoord3iv(void *_glfuncs, const GLint* v);
+void gl2_0_glTexCoord3i(void *_glfuncs, GLint s, GLint t, GLint r);
+void gl2_0_glTexCoord3fv(void *_glfuncs, const GLfloat* v);
+void gl2_0_glTexCoord3f(void *_glfuncs, GLfloat s, GLfloat t, GLfloat r);
+void gl2_0_glTexCoord3dv(void *_glfuncs, const GLdouble* v);
+void gl2_0_glTexCoord3d(void *_glfuncs, GLdouble s, GLdouble t, GLdouble r);
+void gl2_0_glTexCoord2sv(void *_glfuncs, const GLshort* v);
+void gl2_0_glTexCoord2s(void *_glfuncs, GLshort s, GLshort t);
+void gl2_0_glTexCoord2iv(void *_glfuncs, const GLint* v);
+void gl2_0_glTexCoord2i(void *_glfuncs, GLint s, GLint t);
+void gl2_0_glTexCoord2fv(void *_glfuncs, const GLfloat* v);
+void gl2_0_glTexCoord2f(void *_glfuncs, GLfloat s, GLfloat t);
+void gl2_0_glTexCoord2dv(void *_glfuncs, const GLdouble* v);
+void gl2_0_glTexCoord2d(void *_glfuncs, GLdouble s, GLdouble t);
+void gl2_0_glTexCoord1sv(void *_glfuncs, const GLshort* v);
+void gl2_0_glTexCoord1s(void *_glfuncs, GLshort s);
+void gl2_0_glTexCoord1iv(void *_glfuncs, const GLint* v);
+void gl2_0_glTexCoord1i(void *_glfuncs, GLint s);
+void gl2_0_glTexCoord1fv(void *_glfuncs, const GLfloat* v);
+void gl2_0_glTexCoord1f(void *_glfuncs, GLfloat s);
+void gl2_0_glTexCoord1dv(void *_glfuncs, const GLdouble* v);
+void gl2_0_glTexCoord1d(void *_glfuncs, GLdouble s);
+void gl2_0_glRectsv(void *_glfuncs, const GLshort* v1, const GLshort* v2);
+void gl2_0_glRects(void *_glfuncs, GLshort x1, GLshort y1, GLshort x2, GLshort y2);
+void gl2_0_glRectiv(void *_glfuncs, const GLint* v1, const GLint* v2);
+void gl2_0_glRecti(void *_glfuncs, GLint x1, GLint y1, GLint x2, GLint y2);
+void gl2_0_glRectfv(void *_glfuncs, const GLfloat* v1, const GLfloat* v2);
+void gl2_0_glRectf(void *_glfuncs, GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2);
+void gl2_0_glRectdv(void *_glfuncs, const GLdouble* v1, const GLdouble* v2);
+void gl2_0_glRectd(void *_glfuncs, GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2);
+void gl2_0_glRasterPos4sv(void *_glfuncs, const GLshort* v);
+void gl2_0_glRasterPos4s(void *_glfuncs, GLshort x, GLshort y, GLshort z, GLshort w);
+void gl2_0_glRasterPos4iv(void *_glfuncs, const GLint* v);
+void gl2_0_glRasterPos4i(void *_glfuncs, GLint x, GLint y, GLint z, GLint w);
+void gl2_0_glRasterPos4fv(void *_glfuncs, const GLfloat* v);
+void gl2_0_glRasterPos4f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+void gl2_0_glRasterPos4dv(void *_glfuncs, const GLdouble* v);
+void gl2_0_glRasterPos4d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+void gl2_0_glRasterPos3sv(void *_glfuncs, const GLshort* v);
+void gl2_0_glRasterPos3s(void *_glfuncs, GLshort x, GLshort y, GLshort z);
+void gl2_0_glRasterPos3iv(void *_glfuncs, const GLint* v);
+void gl2_0_glRasterPos3i(void *_glfuncs, GLint x, GLint y, GLint z);
+void gl2_0_glRasterPos3fv(void *_glfuncs, const GLfloat* v);
+void gl2_0_glRasterPos3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl2_0_glRasterPos3dv(void *_glfuncs, const GLdouble* v);
+void gl2_0_glRasterPos3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl2_0_glRasterPos2sv(void *_glfuncs, const GLshort* v);
+void gl2_0_glRasterPos2s(void *_glfuncs, GLshort x, GLshort y);
+void gl2_0_glRasterPos2iv(void *_glfuncs, const GLint* v);
+void gl2_0_glRasterPos2i(void *_glfuncs, GLint x, GLint y);
+void gl2_0_glRasterPos2fv(void *_glfuncs, const GLfloat* v);
+void gl2_0_glRasterPos2f(void *_glfuncs, GLfloat x, GLfloat y);
+void gl2_0_glRasterPos2dv(void *_glfuncs, const GLdouble* v);
+void gl2_0_glRasterPos2d(void *_glfuncs, GLdouble x, GLdouble y);
+void gl2_0_glNormal3sv(void *_glfuncs, const GLshort* v);
+void gl2_0_glNormal3s(void *_glfuncs, GLshort nx, GLshort ny, GLshort nz);
+void gl2_0_glNormal3iv(void *_glfuncs, const GLint* v);
+void gl2_0_glNormal3i(void *_glfuncs, GLint nx, GLint ny, GLint nz);
+void gl2_0_glNormal3fv(void *_glfuncs, const GLfloat* v);
+void gl2_0_glNormal3f(void *_glfuncs, GLfloat nx, GLfloat ny, GLfloat nz);
+void gl2_0_glNormal3dv(void *_glfuncs, const GLdouble* v);
+void gl2_0_glNormal3d(void *_glfuncs, GLdouble nx, GLdouble ny, GLdouble nz);
+void gl2_0_glNormal3bv(void *_glfuncs, const GLbyte* v);
+void gl2_0_glNormal3b(void *_glfuncs, GLbyte nx, GLbyte ny, GLbyte nz);
+void gl2_0_glIndexsv(void *_glfuncs, const GLshort* c);
+void gl2_0_glIndexs(void *_glfuncs, GLshort c);
+void gl2_0_glIndexiv(void *_glfuncs, const GLint* c);
+void gl2_0_glIndexi(void *_glfuncs, GLint c);
+void gl2_0_glIndexfv(void *_glfuncs, const GLfloat* c);
+void gl2_0_glIndexf(void *_glfuncs, GLfloat c);
+void gl2_0_glIndexdv(void *_glfuncs, const GLdouble* c);
+void gl2_0_glIndexd(void *_glfuncs, GLdouble c);
+void gl2_0_glEnd(void *_glfuncs);
+void gl2_0_glEdgeFlagv(void *_glfuncs, const GLboolean* flag);
+void gl2_0_glEdgeFlag(void *_glfuncs, GLboolean flag);
+void gl2_0_glColor4usv(void *_glfuncs, const GLushort* v);
+void gl2_0_glColor4us(void *_glfuncs, GLushort red, GLushort green, GLushort blue, GLushort alpha);
+void gl2_0_glColor4uiv(void *_glfuncs, const GLuint* v);
+void gl2_0_glColor4ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue, GLuint alpha);
+void gl2_0_glColor4ubv(void *_glfuncs, const GLubyte* v);
+void gl2_0_glColor4ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha);
+void gl2_0_glColor4sv(void *_glfuncs, const GLshort* v);
+void gl2_0_glColor4s(void *_glfuncs, GLshort red, GLshort green, GLshort blue, GLshort alpha);
+void gl2_0_glColor4iv(void *_glfuncs, const GLint* v);
+void gl2_0_glColor4i(void *_glfuncs, GLint red, GLint green, GLint blue, GLint alpha);
+void gl2_0_glColor4fv(void *_glfuncs, const GLfloat* v);
+void gl2_0_glColor4f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl2_0_glColor4dv(void *_glfuncs, const GLdouble* v);
+void gl2_0_glColor4d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha);
+void gl2_0_glColor4bv(void *_glfuncs, const GLbyte* v);
+void gl2_0_glColor4b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha);
+void gl2_0_glColor3usv(void *_glfuncs, const GLushort* v);
+void gl2_0_glColor3us(void *_glfuncs, GLushort red, GLushort green, GLushort blue);
+void gl2_0_glColor3uiv(void *_glfuncs, const GLuint* v);
+void gl2_0_glColor3ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue);
+void gl2_0_glColor3ubv(void *_glfuncs, const GLubyte* v);
+void gl2_0_glColor3ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue);
+void gl2_0_glColor3sv(void *_glfuncs, const GLshort* v);
+void gl2_0_glColor3s(void *_glfuncs, GLshort red, GLshort green, GLshort blue);
+void gl2_0_glColor3iv(void *_glfuncs, const GLint* v);
+void gl2_0_glColor3i(void *_glfuncs, GLint red, GLint green, GLint blue);
+void gl2_0_glColor3fv(void *_glfuncs, const GLfloat* v);
+void gl2_0_glColor3f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue);
+void gl2_0_glColor3dv(void *_glfuncs, const GLdouble* v);
+void gl2_0_glColor3d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue);
+void gl2_0_glColor3bv(void *_glfuncs, const GLbyte* v);
+void gl2_0_glColor3b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue);
+void gl2_0_glBitmap(void *_glfuncs, GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte* bitmap);
+void gl2_0_glBegin(void *_glfuncs, GLenum mode);
+void gl2_0_glListBase(void *_glfuncs, GLuint base);
+GLuint gl2_0_glGenLists(void *_glfuncs, GLsizei range_);
+void gl2_0_glDeleteLists(void *_glfuncs, GLuint list, GLsizei range_);
+void gl2_0_glCallLists(void *_glfuncs, GLsizei n, GLenum gltype, const GLvoid* lists);
+void gl2_0_glCallList(void *_glfuncs, GLuint list);
+void gl2_0_glEndList(void *_glfuncs);
+void gl2_0_glNewList(void *_glfuncs, GLuint list, GLenum mode);
+void gl2_0_glPushClientAttrib(void *_glfuncs, GLbitfield mask);
+void gl2_0_glPopClientAttrib(void *_glfuncs);
+void gl2_0_glPrioritizeTextures(void *_glfuncs, GLsizei n, const GLuint* textures, const GLfloat* priorities);
+GLboolean gl2_0_glAreTexturesResident(void *_glfuncs, GLsizei n, const GLuint* textures, GLboolean* residences);
+void gl2_0_glVertexPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl2_0_glTexCoordPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl2_0_glNormalPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl2_0_glInterleavedArrays(void *_glfuncs, GLenum format, GLsizei stride, const GLvoid* pointer);
+void gl2_0_glIndexPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl2_0_glEnableClientState(void *_glfuncs, GLenum array);
+void gl2_0_glEdgeFlagPointer(void *_glfuncs, GLsizei stride, const GLvoid* pointer);
+void gl2_0_glDisableClientState(void *_glfuncs, GLenum array);
+void gl2_0_glColorPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl2_0_glArrayElement(void *_glfuncs, GLint i);
+void gl2_0_glResetMinmax(void *_glfuncs, GLenum target);
+void gl2_0_glResetHistogram(void *_glfuncs, GLenum target);
+void gl2_0_glMinmax(void *_glfuncs, GLenum target, GLenum internalFormat, GLboolean sink);
+void gl2_0_glHistogram(void *_glfuncs, GLenum target, GLsizei width, GLenum internalFormat, GLboolean sink);
+void gl2_0_glGetMinmaxParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl2_0_glGetMinmaxParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl2_0_glGetMinmax(void *_glfuncs, GLenum target, GLboolean reset, GLenum format, GLenum gltype, GLvoid* values);
+void gl2_0_glGetHistogramParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl2_0_glGetHistogramParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl2_0_glGetHistogram(void *_glfuncs, GLenum target, GLboolean reset, GLenum format, GLenum gltype, GLvoid* values);
+void gl2_0_glSeparableFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* row, const GLvoid* column);
+void gl2_0_glGetSeparableFilter(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* row, GLvoid* column, GLvoid* span);
+void gl2_0_glGetConvolutionParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl2_0_glGetConvolutionParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl2_0_glGetConvolutionFilter(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* image);
+void gl2_0_glCopyConvolutionFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl2_0_glCopyConvolutionFilter1D(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width);
+void gl2_0_glConvolutionParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl2_0_glConvolutionParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint params);
+void gl2_0_glConvolutionParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl2_0_glConvolutionParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat params);
+void gl2_0_glConvolutionFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* image);
+void gl2_0_glConvolutionFilter1D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLenum format, GLenum gltype, const GLvoid* image);
+void gl2_0_glCopyColorSubTable(void *_glfuncs, GLenum target, GLsizei start, GLint x, GLint y, GLsizei width);
+void gl2_0_glColorSubTable(void *_glfuncs, GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum gltype, const GLvoid* data);
+void gl2_0_glGetColorTableParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl2_0_glGetColorTableParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl2_0_glGetColorTable(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* table);
+void gl2_0_glCopyColorTable(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width);
+void gl2_0_glColorTableParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl2_0_glColorTableParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl2_0_glColorTable(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLenum format, GLenum gltype, const GLvoid* table);
+void gl2_0_glMultTransposeMatrixd(void *_glfuncs, const GLdouble* m);
+void gl2_0_glMultTransposeMatrixf(void *_glfuncs, const GLfloat* m);
+void gl2_0_glLoadTransposeMatrixd(void *_glfuncs, const GLdouble* m);
+void gl2_0_glLoadTransposeMatrixf(void *_glfuncs, const GLfloat* m);
+void gl2_0_glMultiTexCoord4sv(void *_glfuncs, GLenum target, const GLshort* v);
+void gl2_0_glMultiTexCoord4s(void *_glfuncs, GLenum target, GLshort s, GLshort t, GLshort r, GLshort q);
+void gl2_0_glMultiTexCoord4iv(void *_glfuncs, GLenum target, const GLint* v);
+void gl2_0_glMultiTexCoord4i(void *_glfuncs, GLenum target, GLint s, GLint t, GLint r, GLint q);
+void gl2_0_glMultiTexCoord4fv(void *_glfuncs, GLenum target, const GLfloat* v);
+void gl2_0_glMultiTexCoord4f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+void gl2_0_glMultiTexCoord4dv(void *_glfuncs, GLenum target, const GLdouble* v);
+void gl2_0_glMultiTexCoord4d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+void gl2_0_glMultiTexCoord3sv(void *_glfuncs, GLenum target, const GLshort* v);
+void gl2_0_glMultiTexCoord3s(void *_glfuncs, GLenum target, GLshort s, GLshort t, GLshort r);
+void gl2_0_glMultiTexCoord3iv(void *_glfuncs, GLenum target, const GLint* v);
+void gl2_0_glMultiTexCoord3i(void *_glfuncs, GLenum target, GLint s, GLint t, GLint r);
+void gl2_0_glMultiTexCoord3fv(void *_glfuncs, GLenum target, const GLfloat* v);
+void gl2_0_glMultiTexCoord3f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t, GLfloat r);
+void gl2_0_glMultiTexCoord3dv(void *_glfuncs, GLenum target, const GLdouble* v);
+void gl2_0_glMultiTexCoord3d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t, GLdouble r);
+void gl2_0_glMultiTexCoord2sv(void *_glfuncs, GLenum target, const GLshort* v);
+void gl2_0_glMultiTexCoord2s(void *_glfuncs, GLenum target, GLshort s, GLshort t);
+void gl2_0_glMultiTexCoord2iv(void *_glfuncs, GLenum target, const GLint* v);
+void gl2_0_glMultiTexCoord2i(void *_glfuncs, GLenum target, GLint s, GLint t);
+void gl2_0_glMultiTexCoord2fv(void *_glfuncs, GLenum target, const GLfloat* v);
+void gl2_0_glMultiTexCoord2f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t);
+void gl2_0_glMultiTexCoord2dv(void *_glfuncs, GLenum target, const GLdouble* v);
+void gl2_0_glMultiTexCoord2d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t);
+void gl2_0_glMultiTexCoord1sv(void *_glfuncs, GLenum target, const GLshort* v);
+void gl2_0_glMultiTexCoord1s(void *_glfuncs, GLenum target, GLshort s);
+void gl2_0_glMultiTexCoord1iv(void *_glfuncs, GLenum target, const GLint* v);
+void gl2_0_glMultiTexCoord1i(void *_glfuncs, GLenum target, GLint s);
+void gl2_0_glMultiTexCoord1fv(void *_glfuncs, GLenum target, const GLfloat* v);
+void gl2_0_glMultiTexCoord1f(void *_glfuncs, GLenum target, GLfloat s);
+void gl2_0_glMultiTexCoord1dv(void *_glfuncs, GLenum target, const GLdouble* v);
+void gl2_0_glMultiTexCoord1d(void *_glfuncs, GLenum target, GLdouble s);
+void gl2_0_glClientActiveTexture(void *_glfuncs, GLenum texture);
+void gl2_0_glWindowPos3sv(void *_glfuncs, const GLshort* v);
+void gl2_0_glWindowPos3s(void *_glfuncs, GLshort x, GLshort y, GLshort z);
+void gl2_0_glWindowPos3iv(void *_glfuncs, const GLint* v);
+void gl2_0_glWindowPos3i(void *_glfuncs, GLint x, GLint y, GLint z);
+void gl2_0_glWindowPos3fv(void *_glfuncs, const GLfloat* v);
+void gl2_0_glWindowPos3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl2_0_glWindowPos3dv(void *_glfuncs, const GLdouble* v);
+void gl2_0_glWindowPos3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl2_0_glWindowPos2sv(void *_glfuncs, const GLshort* v);
+void gl2_0_glWindowPos2s(void *_glfuncs, GLshort x, GLshort y);
+void gl2_0_glWindowPos2iv(void *_glfuncs, const GLint* v);
+void gl2_0_glWindowPos2i(void *_glfuncs, GLint x, GLint y);
+void gl2_0_glWindowPos2fv(void *_glfuncs, const GLfloat* v);
+void gl2_0_glWindowPos2f(void *_glfuncs, GLfloat x, GLfloat y);
+void gl2_0_glWindowPos2dv(void *_glfuncs, const GLdouble* v);
+void gl2_0_glWindowPos2d(void *_glfuncs, GLdouble x, GLdouble y);
+void gl2_0_glSecondaryColorPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl2_0_glSecondaryColor3usv(void *_glfuncs, const GLushort* v);
+void gl2_0_glSecondaryColor3us(void *_glfuncs, GLushort red, GLushort green, GLushort blue);
+void gl2_0_glSecondaryColor3uiv(void *_glfuncs, const GLuint* v);
+void gl2_0_glSecondaryColor3ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue);
+void gl2_0_glSecondaryColor3ubv(void *_glfuncs, const GLubyte* v);
+void gl2_0_glSecondaryColor3ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue);
+void gl2_0_glSecondaryColor3sv(void *_glfuncs, const GLshort* v);
+void gl2_0_glSecondaryColor3s(void *_glfuncs, GLshort red, GLshort green, GLshort blue);
+void gl2_0_glSecondaryColor3iv(void *_glfuncs, const GLint* v);
+void gl2_0_glSecondaryColor3i(void *_glfuncs, GLint red, GLint green, GLint blue);
+void gl2_0_glSecondaryColor3fv(void *_glfuncs, const GLfloat* v);
+void gl2_0_glSecondaryColor3f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue);
+void gl2_0_glSecondaryColor3dv(void *_glfuncs, const GLdouble* v);
+void gl2_0_glSecondaryColor3d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue);
+void gl2_0_glSecondaryColor3bv(void *_glfuncs, const GLbyte* v);
+void gl2_0_glSecondaryColor3b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue);
+void gl2_0_glFogCoordPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl2_0_glFogCoorddv(void *_glfuncs, const GLdouble* coord);
+void gl2_0_glFogCoordd(void *_glfuncs, GLdouble coord);
+void gl2_0_glFogCoordfv(void *_glfuncs, const GLfloat* coord);
+void gl2_0_glFogCoordf(void *_glfuncs, GLfloat coord);
+void gl2_0_glVertexAttrib4usv(void *_glfuncs, GLuint index, const GLushort* v);
+void gl2_0_glVertexAttrib4uiv(void *_glfuncs, GLuint index, const GLuint* v);
+void gl2_0_glVertexAttrib4ubv(void *_glfuncs, GLuint index, const GLubyte* v);
+void gl2_0_glVertexAttrib4sv(void *_glfuncs, GLuint index, const GLshort* v);
+void gl2_0_glVertexAttrib4s(void *_glfuncs, GLuint index, GLshort x, GLshort y, GLshort z, GLshort w);
+void gl2_0_glVertexAttrib4iv(void *_glfuncs, GLuint index, const GLint* v);
+void gl2_0_glVertexAttrib4fv(void *_glfuncs, GLuint index, const GLfloat* v);
+void gl2_0_glVertexAttrib4f(void *_glfuncs, GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+void gl2_0_glVertexAttrib4dv(void *_glfuncs, GLuint index, const GLdouble* v);
+void gl2_0_glVertexAttrib4d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+void gl2_0_glVertexAttrib4bv(void *_glfuncs, GLuint index, const GLbyte* v);
+void gl2_0_glVertexAttrib4Nusv(void *_glfuncs, GLuint index, const GLushort* v);
+void gl2_0_glVertexAttrib4Nuiv(void *_glfuncs, GLuint index, const GLuint* v);
+void gl2_0_glVertexAttrib4Nubv(void *_glfuncs, GLuint index, const GLubyte* v);
+void gl2_0_glVertexAttrib4Nub(void *_glfuncs, GLuint index, GLubyte x, GLubyte y, GLubyte z, GLubyte w);
+void gl2_0_glVertexAttrib4Nsv(void *_glfuncs, GLuint index, const GLshort* v);
+void gl2_0_glVertexAttrib4Niv(void *_glfuncs, GLuint index, const GLint* v);
+void gl2_0_glVertexAttrib4Nbv(void *_glfuncs, GLuint index, const GLbyte* v);
+void gl2_0_glVertexAttrib3sv(void *_glfuncs, GLuint index, const GLshort* v);
+void gl2_0_glVertexAttrib3s(void *_glfuncs, GLuint index, GLshort x, GLshort y, GLshort z);
+void gl2_0_glVertexAttrib3fv(void *_glfuncs, GLuint index, const GLfloat* v);
+void gl2_0_glVertexAttrib3f(void *_glfuncs, GLuint index, GLfloat x, GLfloat y, GLfloat z);
+void gl2_0_glVertexAttrib3dv(void *_glfuncs, GLuint index, const GLdouble* v);
+void gl2_0_glVertexAttrib3d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y, GLdouble z);
+void gl2_0_glVertexAttrib2sv(void *_glfuncs, GLuint index, const GLshort* v);
+void gl2_0_glVertexAttrib2s(void *_glfuncs, GLuint index, GLshort x, GLshort y);
+void gl2_0_glVertexAttrib2fv(void *_glfuncs, GLuint index, const GLfloat* v);
+void gl2_0_glVertexAttrib2f(void *_glfuncs, GLuint index, GLfloat x, GLfloat y);
+void gl2_0_glVertexAttrib2dv(void *_glfuncs, GLuint index, const GLdouble* v);
+void gl2_0_glVertexAttrib2d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y);
+void gl2_0_glVertexAttrib1sv(void *_glfuncs, GLuint index, const GLshort* v);
+void gl2_0_glVertexAttrib1s(void *_glfuncs, GLuint index, GLshort x);
+void gl2_0_glVertexAttrib1fv(void *_glfuncs, GLuint index, const GLfloat* v);
+void gl2_0_glVertexAttrib1f(void *_glfuncs, GLuint index, GLfloat x);
+void gl2_0_glVertexAttrib1dv(void *_glfuncs, GLuint index, const GLdouble* v);
+void gl2_0_glVertexAttrib1d(void *_glfuncs, GLuint index, GLdouble x);
+
+
+#ifdef __cplusplus
+} // extern "C"
+#endif
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/2.0/gl.go b/Godeps/_workspace/src/github.com/obscuren/qml/gl/2.0/gl.go
new file mode 100644
index 000000000..7bd1e1b52
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/2.0/gl.go
@@ -0,0 +1,6407 @@
+// ** file automatically generated by glgen -- do not edit manually **
+
+package GL
+
+// #cgo CXXFLAGS: -std=c++0x -pedantic-errors -Wall -fno-strict-aliasing
+// #cgo LDFLAGS: -lstdc++
+// #cgo pkg-config: Qt5Core Qt5OpenGL
+//
+// #include "funcs.h"
+//
+// void free(void*);
+//
+import "C"
+
+import (
+ "fmt"
+ "reflect"
+ "unsafe"
+
+ "gopkg.in/qml.v1/gl/glbase"
+)
+
+// API returns a value that offers methods matching the OpenGL version 2.0 API.
+//
+// The returned API must not be used after the provided OpenGL context becomes invalid.
+func API(context glbase.Contexter) *GL {
+ gl := &GL{}
+ gl.funcs = C.gl2_0_funcs()
+ if gl.funcs == nil {
+ panic(fmt.Errorf("OpenGL version 2.0 is not available"))
+ }
+ return gl
+}
+
+// GL implements the OpenGL version 2.0 API. Values of this
+// type must be created via the API function, and it must not be used after
+// the associated OpenGL context becomes invalid.
+type GL struct {
+ funcs unsafe.Pointer
+}
+
+const (
+ FALSE = 0
+ TRUE = 1
+ NONE = 0
+
+ BYTE = 0x1400
+ UNSIGNED_BYTE = 0x1401
+ SHORT = 0x1402
+ UNSIGNED_SHORT = 0x1403
+ INT = 0x1404
+ UNSIGNED_INT = 0x1405
+ FLOAT = 0x1406
+ N2_BYTES = 0x1407
+ N3_BYTES = 0x1408
+ N4_BYTES = 0x1409
+ DOUBLE = 0x140A
+
+ ACCUM = 0x0100
+ LOAD = 0x0101
+ RETURN = 0x0102
+ MULT = 0x0103
+ ADD = 0x0104
+
+ ACCUM_BUFFER_BIT = 0x00000200
+ ALL_ATTRIB_BITS = 0xFFFFFFFF
+ COLOR_BUFFER_BIT = 0x00004000
+ CURRENT_BIT = 0x00000001
+ DEPTH_BUFFER_BIT = 0x00000100
+ ENABLE_BIT = 0x00002000
+ EVAL_BIT = 0x00010000
+ FOG_BIT = 0x00000080
+ HINT_BIT = 0x00008000
+ LIGHTING_BIT = 0x00000040
+ LINE_BIT = 0x00000004
+ LIST_BIT = 0x00020000
+ MULTISAMPLE_BIT = 0x20000000
+ PIXEL_MODE_BIT = 0x00000020
+ POINT_BIT = 0x00000002
+ POLYGON_BIT = 0x00000008
+ POLYGON_STIPPLE_BIT = 0x00000010
+ SCISSOR_BIT = 0x00080000
+ STENCIL_BUFFER_BIT = 0x00000400
+ TEXTURE_BIT = 0x00040000
+ TRANSFORM_BIT = 0x00001000
+ VIEWPORT_BIT = 0x00000800
+
+ ALWAYS = 0x0207
+ EQUAL = 0x0202
+ GEQUAL = 0x0206
+ GREATER = 0x0204
+ LEQUAL = 0x0203
+ LESS = 0x0201
+ NEVER = 0x0200
+ NOTEQUAL = 0x0205
+
+ LOGIC_OP = 0x0BF1
+
+ DST_ALPHA = 0x0304
+ ONE = 1
+ ONE_MINUS_DST_ALPHA = 0x0305
+ ONE_MINUS_SRC_ALPHA = 0x0303
+ ONE_MINUS_SRC_COLOR = 0x0301
+ SRC_ALPHA = 0x0302
+ SRC_COLOR = 0x0300
+ ZERO = 0
+
+ DST_COLOR = 0x0306
+ ONE_MINUS_DST_COLOR = 0x0307
+ SRC_ALPHA_SATURATE = 0x0308
+
+ CLIENT_ALL_ATTRIB_BITS = 0xFFFFFFFF
+ CLIENT_PIXEL_STORE_BIT = 0x00000001
+ CLIENT_VERTEX_ARRAY_BIT = 0x00000002
+
+ CLIP_PLANE0 = 0x3000
+ CLIP_PLANE1 = 0x3001
+ CLIP_PLANE2 = 0x3002
+ CLIP_PLANE3 = 0x3003
+ CLIP_PLANE4 = 0x3004
+ CLIP_PLANE5 = 0x3005
+
+ BACK = 0x0405
+ FRONT = 0x0404
+ FRONT_AND_BACK = 0x0408
+
+ AMBIENT = 0x1200
+ AMBIENT_AND_DIFFUSE = 0x1602
+ DIFFUSE = 0x1201
+ EMISSION = 0x1600
+ SPECULAR = 0x1202
+
+ AUX0 = 0x0409
+ AUX1 = 0x040A
+ AUX2 = 0x040B
+ AUX3 = 0x040C
+ BACK_LEFT = 0x0402
+ BACK_RIGHT = 0x0403
+ FRONT_LEFT = 0x0400
+ FRONT_RIGHT = 0x0401
+ LEFT = 0x0406
+ RIGHT = 0x0407
+
+ ALPHA_TEST = 0x0BC0
+ AUTO_NORMAL = 0x0D80
+ BLEND = 0x0BE2
+ COLOR_ARRAY = 0x8076
+ COLOR_LOGIC_OP = 0x0BF2
+ COLOR_MATERIAL = 0x0B57
+ CULL_FACE = 0x0B44
+ DEPTH_TEST = 0x0B71
+ DITHER = 0x0BD0
+ EDGE_FLAG_ARRAY = 0x8079
+ FOG = 0x0B60
+ INDEX_ARRAY = 0x8077
+ INDEX_LOGIC_OP = 0x0BF1
+ LIGHT0 = 0x4000
+ LIGHT1 = 0x4001
+ LIGHT2 = 0x4002
+ LIGHT3 = 0x4003
+ LIGHT4 = 0x4004
+ LIGHT5 = 0x4005
+ LIGHT6 = 0x4006
+ LIGHT7 = 0x4007
+ LIGHTING = 0x0B50
+ LINE_SMOOTH = 0x0B20
+ LINE_STIPPLE = 0x0B24
+ MAP1_COLOR_4 = 0x0D90
+ MAP1_INDEX = 0x0D91
+ MAP1_NORMAL = 0x0D92
+ MAP1_TEXTURE_COORD_1 = 0x0D93
+ MAP1_TEXTURE_COORD_2 = 0x0D94
+ MAP1_TEXTURE_COORD_3 = 0x0D95
+ MAP1_TEXTURE_COORD_4 = 0x0D96
+ MAP1_VERTEX_3 = 0x0D97
+ MAP1_VERTEX_4 = 0x0D98
+ MAP2_COLOR_4 = 0x0DB0
+ MAP2_INDEX = 0x0DB1
+ MAP2_NORMAL = 0x0DB2
+ MAP2_TEXTURE_COORD_1 = 0x0DB3
+ MAP2_TEXTURE_COORD_2 = 0x0DB4
+ MAP2_TEXTURE_COORD_3 = 0x0DB5
+ MAP2_TEXTURE_COORD_4 = 0x0DB6
+ MAP2_VERTEX_3 = 0x0DB7
+ MAP2_VERTEX_4 = 0x0DB8
+ NORMALIZE = 0x0BA1
+ NORMAL_ARRAY = 0x8075
+ POINT_SMOOTH = 0x0B10
+ POLYGON_OFFSET_FILL = 0x8037
+ POLYGON_OFFSET_LINE = 0x2A02
+ POLYGON_OFFSET_POINT = 0x2A01
+ POLYGON_SMOOTH = 0x0B41
+ POLYGON_STIPPLE = 0x0B42
+ SCISSOR_TEST = 0x0C11
+ STENCIL_TEST = 0x0B90
+ TEXTURE_1D = 0x0DE0
+ TEXTURE_2D = 0x0DE1
+ TEXTURE_COORD_ARRAY = 0x8078
+ TEXTURE_GEN_Q = 0x0C63
+ TEXTURE_GEN_R = 0x0C62
+ TEXTURE_GEN_S = 0x0C60
+ TEXTURE_GEN_T = 0x0C61
+ VERTEX_ARRAY = 0x8074
+
+ INVALID_ENUM = 0x0500
+ INVALID_OPERATION = 0x0502
+ INVALID_VALUE = 0x0501
+ NO_ERROR = 0
+ OUT_OF_MEMORY = 0x0505
+ STACK_OVERFLOW = 0x0503
+ STACK_UNDERFLOW = 0x0504
+
+ N2D = 0x0600
+ N3D = 0x0601
+ N3D_COLOR = 0x0602
+ N3D_COLOR_TEXTURE = 0x0603
+ N4D_COLOR_TEXTURE = 0x0604
+
+ BITMAP_TOKEN = 0x0704
+ COPY_PIXEL_TOKEN = 0x0706
+ DRAW_PIXEL_TOKEN = 0x0705
+ LINE_RESET_TOKEN = 0x0707
+ LINE_TOKEN = 0x0702
+ PASS_THROUGH_TOKEN = 0x0700
+ POINT_TOKEN = 0x0701
+ POLYGON_TOKEN = 0x0703
+
+ EXP = 0x0800
+ EXP2 = 0x0801
+ LINEAR = 0x2601
+
+ FOG_COLOR = 0x0B66
+ FOG_DENSITY = 0x0B62
+ FOG_END = 0x0B64
+ FOG_INDEX = 0x0B61
+ FOG_MODE = 0x0B65
+ FOG_START = 0x0B63
+
+ CCW = 0x0901
+ CW = 0x0900
+
+ COEFF = 0x0A00
+ DOMAIN = 0x0A02
+ ORDER = 0x0A01
+
+ PIXEL_MAP_A_TO_A = 0x0C79
+ PIXEL_MAP_B_TO_B = 0x0C78
+ PIXEL_MAP_G_TO_G = 0x0C77
+ PIXEL_MAP_I_TO_A = 0x0C75
+ PIXEL_MAP_I_TO_B = 0x0C74
+ PIXEL_MAP_I_TO_G = 0x0C73
+ PIXEL_MAP_I_TO_I = 0x0C70
+ PIXEL_MAP_I_TO_R = 0x0C72
+ PIXEL_MAP_R_TO_R = 0x0C76
+ PIXEL_MAP_S_TO_S = 0x0C71
+
+ ACCUM_ALPHA_BITS = 0x0D5B
+ ACCUM_BLUE_BITS = 0x0D5A
+ ACCUM_CLEAR_VALUE = 0x0B80
+ ACCUM_GREEN_BITS = 0x0D59
+ ACCUM_RED_BITS = 0x0D58
+ ALIASED_LINE_WIDTH_RANGE = 0x846E
+ ALIASED_POINT_SIZE_RANGE = 0x846D
+ ALPHA_BIAS = 0x0D1D
+ ALPHA_BITS = 0x0D55
+ ALPHA_SCALE = 0x0D1C
+ ALPHA_TEST_FUNC = 0x0BC1
+ ALPHA_TEST_REF = 0x0BC2
+ ATTRIB_STACK_DEPTH = 0x0BB0
+ AUX_BUFFERS = 0x0C00
+ BLEND_DST = 0x0BE0
+ BLEND_SRC = 0x0BE1
+ BLUE_BIAS = 0x0D1B
+ BLUE_BITS = 0x0D54
+ BLUE_SCALE = 0x0D1A
+ CLIENT_ATTRIB_STACK_DEPTH = 0x0BB1
+ COLOR_ARRAY_SIZE = 0x8081
+ COLOR_ARRAY_STRIDE = 0x8083
+ COLOR_ARRAY_TYPE = 0x8082
+ COLOR_CLEAR_VALUE = 0x0C22
+ COLOR_MATERIAL_FACE = 0x0B55
+ COLOR_MATERIAL_PARAMETER = 0x0B56
+ COLOR_WRITEMASK = 0x0C23
+ CULL_FACE_MODE = 0x0B45
+ CURRENT_COLOR = 0x0B00
+ CURRENT_INDEX = 0x0B01
+ CURRENT_NORMAL = 0x0B02
+ CURRENT_RASTER_COLOR = 0x0B04
+ CURRENT_RASTER_DISTANCE = 0x0B09
+ CURRENT_RASTER_INDEX = 0x0B05
+ CURRENT_RASTER_POSITION = 0x0B07
+ CURRENT_RASTER_POSITION_VALID = 0x0B08
+ CURRENT_RASTER_TEXTURE_COORDS = 0x0B06
+ CURRENT_TEXTURE_COORDS = 0x0B03
+ DEPTH_BIAS = 0x0D1F
+ DEPTH_BITS = 0x0D56
+ DEPTH_CLEAR_VALUE = 0x0B73
+ DEPTH_FUNC = 0x0B74
+ DEPTH_RANGE = 0x0B70
+ DEPTH_SCALE = 0x0D1E
+ DEPTH_WRITEMASK = 0x0B72
+ DOUBLEBUFFER = 0x0C32
+ DRAW_BUFFER = 0x0C01
+ EDGE_FLAG = 0x0B43
+ EDGE_FLAG_ARRAY_STRIDE = 0x808C
+ FEEDBACK_BUFFER_SIZE = 0x0DF1
+ FEEDBACK_BUFFER_TYPE = 0x0DF2
+ FOG_HINT = 0x0C54
+ FRONT_FACE = 0x0B46
+ GREEN_BIAS = 0x0D19
+ GREEN_BITS = 0x0D53
+ GREEN_SCALE = 0x0D18
+ INDEX_ARRAY_STRIDE = 0x8086
+ INDEX_ARRAY_TYPE = 0x8085
+ INDEX_BITS = 0x0D51
+ INDEX_CLEAR_VALUE = 0x0C20
+ INDEX_MODE = 0x0C30
+ INDEX_OFFSET = 0x0D13
+ INDEX_SHIFT = 0x0D12
+ INDEX_WRITEMASK = 0x0C21
+ LIGHT_MODEL_AMBIENT = 0x0B53
+ LIGHT_MODEL_COLOR_CONTROL = 0x81F8
+ LIGHT_MODEL_LOCAL_VIEWER = 0x0B51
+ LIGHT_MODEL_TWO_SIDE = 0x0B52
+ LINE_SMOOTH_HINT = 0x0C52
+ LINE_STIPPLE_PATTERN = 0x0B25
+ LINE_STIPPLE_REPEAT = 0x0B26
+ LINE_WIDTH = 0x0B21
+ LINE_WIDTH_GRANULARITY = 0x0B23
+ LINE_WIDTH_RANGE = 0x0B22
+ LIST_BASE = 0x0B32
+ LIST_INDEX = 0x0B33
+ LIST_MODE = 0x0B30
+ LOGIC_OP_MODE = 0x0BF0
+ MAP1_GRID_DOMAIN = 0x0DD0
+ MAP1_GRID_SEGMENTS = 0x0DD1
+ MAP2_GRID_DOMAIN = 0x0DD2
+ MAP2_GRID_SEGMENTS = 0x0DD3
+ MAP_COLOR = 0x0D10
+ MAP_STENCIL = 0x0D11
+ MATRIX_MODE = 0x0BA0
+ MAX_ATTRIB_STACK_DEPTH = 0x0D35
+ MAX_CLIENT_ATTRIB_STACK_DEPTH = 0x0D3B
+ MAX_CLIP_PLANES = 0x0D32
+ MAX_EVAL_ORDER = 0x0D30
+ MAX_LIGHTS = 0x0D31
+ MAX_LIST_NESTING = 0x0B31
+ MAX_MODELVIEW_STACK_DEPTH = 0x0D36
+ MAX_NAME_STACK_DEPTH = 0x0D37
+ MAX_PIXEL_MAP_TABLE = 0x0D34
+ MAX_PROJECTION_STACK_DEPTH = 0x0D38
+ MAX_TEXTURE_SIZE = 0x0D33
+ MAX_TEXTURE_STACK_DEPTH = 0x0D39
+ MAX_VIEWPORT_DIMS = 0x0D3A
+ MODELVIEW_MATRIX = 0x0BA6
+ MODELVIEW_STACK_DEPTH = 0x0BA3
+ NAME_STACK_DEPTH = 0x0D70
+ NORMAL_ARRAY_STRIDE = 0x807F
+ NORMAL_ARRAY_TYPE = 0x807E
+ PACK_ALIGNMENT = 0x0D05
+ PACK_LSB_FIRST = 0x0D01
+ PACK_ROW_LENGTH = 0x0D02
+ PACK_SKIP_PIXELS = 0x0D04
+ PACK_SKIP_ROWS = 0x0D03
+ PACK_SWAP_BYTES = 0x0D00
+ PERSPECTIVE_CORRECTION_HINT = 0x0C50
+ PIXEL_MAP_A_TO_A_SIZE = 0x0CB9
+ PIXEL_MAP_B_TO_B_SIZE = 0x0CB8
+ PIXEL_MAP_G_TO_G_SIZE = 0x0CB7
+ PIXEL_MAP_I_TO_A_SIZE = 0x0CB5
+ PIXEL_MAP_I_TO_B_SIZE = 0x0CB4
+ PIXEL_MAP_I_TO_G_SIZE = 0x0CB3
+ PIXEL_MAP_I_TO_I_SIZE = 0x0CB0
+ PIXEL_MAP_I_TO_R_SIZE = 0x0CB2
+ PIXEL_MAP_R_TO_R_SIZE = 0x0CB6
+ PIXEL_MAP_S_TO_S_SIZE = 0x0CB1
+ POINT_SIZE = 0x0B11
+ POINT_SIZE_GRANULARITY = 0x0B13
+ POINT_SIZE_RANGE = 0x0B12
+ POINT_SMOOTH_HINT = 0x0C51
+ POLYGON_MODE = 0x0B40
+ POLYGON_OFFSET_FACTOR = 0x8038
+ POLYGON_OFFSET_UNITS = 0x2A00
+ POLYGON_SMOOTH_HINT = 0x0C53
+ PROJECTION_MATRIX = 0x0BA7
+ PROJECTION_STACK_DEPTH = 0x0BA4
+ READ_BUFFER = 0x0C02
+ RED_BIAS = 0x0D15
+ RED_BITS = 0x0D52
+ RED_SCALE = 0x0D14
+ RENDER_MODE = 0x0C40
+ RGBA_MODE = 0x0C31
+ SCISSOR_BOX = 0x0C10
+ SELECTION_BUFFER_SIZE = 0x0DF4
+ SHADE_MODEL = 0x0B54
+ SMOOTH_LINE_WIDTH_GRANULARITY = 0x0B23
+ SMOOTH_LINE_WIDTH_RANGE = 0x0B22
+ SMOOTH_POINT_SIZE_GRANULARITY = 0x0B13
+ SMOOTH_POINT_SIZE_RANGE = 0x0B12
+ STENCIL_BITS = 0x0D57
+ STENCIL_CLEAR_VALUE = 0x0B91
+ STENCIL_FAIL = 0x0B94
+ STENCIL_FUNC = 0x0B92
+ STENCIL_PASS_DEPTH_FAIL = 0x0B95
+ STENCIL_PASS_DEPTH_PASS = 0x0B96
+ STENCIL_REF = 0x0B97
+ STENCIL_VALUE_MASK = 0x0B93
+ STENCIL_WRITEMASK = 0x0B98
+ STEREO = 0x0C33
+ SUBPIXEL_BITS = 0x0D50
+ TEXTURE_BINDING_1D = 0x8068
+ TEXTURE_BINDING_2D = 0x8069
+ TEXTURE_BINDING_3D = 0x806A
+ TEXTURE_COORD_ARRAY_SIZE = 0x8088
+ TEXTURE_COORD_ARRAY_STRIDE = 0x808A
+ TEXTURE_COORD_ARRAY_TYPE = 0x8089
+ TEXTURE_MATRIX = 0x0BA8
+ TEXTURE_STACK_DEPTH = 0x0BA5
+ UNPACK_ALIGNMENT = 0x0CF5
+ UNPACK_LSB_FIRST = 0x0CF1
+ UNPACK_ROW_LENGTH = 0x0CF2
+ UNPACK_SKIP_PIXELS = 0x0CF4
+ UNPACK_SKIP_ROWS = 0x0CF3
+ UNPACK_SWAP_BYTES = 0x0CF0
+ VERTEX_ARRAY_SIZE = 0x807A
+ VERTEX_ARRAY_STRIDE = 0x807C
+ VERTEX_ARRAY_TYPE = 0x807B
+ VIEWPORT = 0x0BA2
+ ZOOM_X = 0x0D16
+ ZOOM_Y = 0x0D17
+
+ COLOR_ARRAY_POINTER = 0x8090
+ EDGE_FLAG_ARRAY_POINTER = 0x8093
+ FEEDBACK_BUFFER_POINTER = 0x0DF0
+ INDEX_ARRAY_POINTER = 0x8091
+ NORMAL_ARRAY_POINTER = 0x808F
+ SELECTION_BUFFER_POINTER = 0x0DF3
+ TEXTURE_COORD_ARRAY_POINTER = 0x8092
+ VERTEX_ARRAY_POINTER = 0x808E
+
+ TEXTURE_ALPHA_SIZE = 0x805F
+ TEXTURE_BLUE_SIZE = 0x805E
+ TEXTURE_BORDER = 0x1005
+ TEXTURE_BORDER_COLOR = 0x1004
+ TEXTURE_COMPONENTS = 0x1003
+ TEXTURE_GREEN_SIZE = 0x805D
+ TEXTURE_HEIGHT = 0x1001
+ TEXTURE_INTENSITY_SIZE = 0x8061
+ TEXTURE_INTERNAL_FORMAT = 0x1003
+ TEXTURE_LUMINANCE_SIZE = 0x8060
+ TEXTURE_MAG_FILTER = 0x2800
+ TEXTURE_MIN_FILTER = 0x2801
+ TEXTURE_PRIORITY = 0x8066
+ TEXTURE_RED_SIZE = 0x805C
+ TEXTURE_RESIDENT = 0x8067
+ TEXTURE_WIDTH = 0x1000
+ TEXTURE_WRAP_S = 0x2802
+ TEXTURE_WRAP_T = 0x2803
+
+ DONT_CARE = 0x1100
+ FASTEST = 0x1101
+ NICEST = 0x1102
+
+ FRAGMENT_SHADER_DERIVATIVE_HINT = 0x8B8B
+ GENERATE_MIPMAP_HINT = 0x8192
+ TEXTURE_COMPRESSION_HINT = 0x84EF
+
+ C3F_V3F = 0x2A24
+ C4F_N3F_V3F = 0x2A26
+ C4UB_V2F = 0x2A22
+ C4UB_V3F = 0x2A23
+ N3F_V3F = 0x2A25
+ T2F_C3F_V3F = 0x2A2A
+ T2F_C4F_N3F_V3F = 0x2A2C
+ T2F_C4UB_V3F = 0x2A29
+ T2F_N3F_V3F = 0x2A2B
+ T2F_V3F = 0x2A27
+ T4F_C4F_N3F_V4F = 0x2A2D
+ T4F_V4F = 0x2A28
+ V2F = 0x2A20
+ V3F = 0x2A21
+
+ MODULATE = 0x2100
+ REPLACE = 0x1E01
+
+ SEPARATE_SPECULAR_COLOR = 0x81FA
+ SINGLE_COLOR = 0x81F9
+
+ CONSTANT_ATTENUATION = 0x1207
+ LINEAR_ATTENUATION = 0x1208
+ POSITION = 0x1203
+ QUADRATIC_ATTENUATION = 0x1209
+ SPOT_CUTOFF = 0x1206
+ SPOT_DIRECTION = 0x1204
+ SPOT_EXPONENT = 0x1205
+
+ COMPILE = 0x1300
+ COMPILE_AND_EXECUTE = 0x1301
+
+ AND = 0x1501
+ AND_INVERTED = 0x1504
+ AND_REVERSE = 0x1502
+ CLEAR = 0x1500
+ COPY = 0x1503
+ COPY_INVERTED = 0x150C
+ EQUIV = 0x1509
+ INVERT = 0x150A
+ NAND = 0x150E
+ NOOP = 0x1505
+ NOR = 0x1508
+ OR = 0x1507
+ OR_INVERTED = 0x150D
+ OR_REVERSE = 0x150B
+ SET = 0x150F
+ XOR = 0x1506
+
+ COLOR_INDEXES = 0x1603
+ SHININESS = 0x1601
+
+ MODELVIEW = 0x1700
+ PROJECTION = 0x1701
+ TEXTURE = 0x1702
+
+ LINE = 0x1B01
+ POINT = 0x1B00
+
+ FILL = 0x1B02
+
+ COLOR = 0x1800
+ DEPTH = 0x1801
+ STENCIL = 0x1802
+
+ ALPHA = 0x1906
+ BLUE = 0x1905
+ COLOR_INDEX = 0x1900
+ DEPTH_COMPONENT = 0x1902
+ GREEN = 0x1904
+ LUMINANCE = 0x1909
+ LUMINANCE_ALPHA = 0x190A
+ RED = 0x1903
+ RGB = 0x1907
+ RGBA = 0x1908
+ STENCIL_INDEX = 0x1901
+
+ ALPHA12 = 0x803D
+ ALPHA16 = 0x803E
+ ALPHA4 = 0x803B
+ ALPHA8 = 0x803C
+ INTENSITY = 0x8049
+ INTENSITY12 = 0x804C
+ INTENSITY16 = 0x804D
+ INTENSITY4 = 0x804A
+ INTENSITY8 = 0x804B
+ LUMINANCE12 = 0x8041
+ LUMINANCE12_ALPHA12 = 0x8047
+ LUMINANCE12_ALPHA4 = 0x8046
+ LUMINANCE16 = 0x8042
+ LUMINANCE16_ALPHA16 = 0x8048
+ LUMINANCE4 = 0x803F
+ LUMINANCE4_ALPHA4 = 0x8043
+ LUMINANCE6_ALPHA2 = 0x8044
+ LUMINANCE8 = 0x8040
+ LUMINANCE8_ALPHA8 = 0x8045
+ R3_G3_B2 = 0x2A10
+ RGB10 = 0x8052
+ RGB10_A2 = 0x8059
+ RGB12 = 0x8053
+ RGB16 = 0x8054
+ RGB4 = 0x804F
+ RGB5 = 0x8050
+ RGB5_A1 = 0x8057
+ RGB8 = 0x8051
+ RGBA12 = 0x805A
+ RGBA16 = 0x805B
+ RGBA2 = 0x8055
+ RGBA4 = 0x8056
+ RGBA8 = 0x8058
+
+ PACK_IMAGE_HEIGHT = 0x806C
+ PACK_SKIP_IMAGES = 0x806B
+ UNPACK_IMAGE_HEIGHT = 0x806E
+ UNPACK_SKIP_IMAGES = 0x806D
+
+ BITMAP = 0x1A00
+ UNSIGNED_BYTE_3_3_2 = 0x8032
+ UNSIGNED_INT_10_10_10_2 = 0x8036
+ UNSIGNED_INT_8_8_8_8 = 0x8035
+ UNSIGNED_SHORT_4_4_4_4 = 0x8033
+ UNSIGNED_SHORT_5_5_5_1 = 0x8034
+
+ POINT_DISTANCE_ATTENUATION = 0x8129
+ POINT_FADE_THRESHOLD_SIZE = 0x8128
+ POINT_SIZE_MAX = 0x8127
+ POINT_SIZE_MIN = 0x8126
+
+ LINES = 0x0001
+ LINE_LOOP = 0x0002
+ LINE_STRIP = 0x0003
+ POINTS = 0x0000
+ POLYGON = 0x0009
+ QUADS = 0x0007
+ QUAD_STRIP = 0x0008
+ TRIANGLES = 0x0004
+ TRIANGLE_FAN = 0x0006
+ TRIANGLE_STRIP = 0x0005
+
+ FEEDBACK = 0x1C01
+ RENDER = 0x1C00
+ SELECT = 0x1C02
+
+ FLAT = 0x1D00
+ SMOOTH = 0x1D01
+
+ DECR = 0x1E03
+ INCR = 0x1E02
+ KEEP = 0x1E00
+
+ EXTENSIONS = 0x1F03
+ RENDERER = 0x1F01
+ VENDOR = 0x1F00
+ VERSION = 0x1F02
+
+ S = 0x2000
+ T = 0x2001
+ R = 0x2002
+ Q = 0x2003
+
+ DECAL = 0x2101
+
+ TEXTURE_ENV_COLOR = 0x2201
+ TEXTURE_ENV_MODE = 0x2200
+
+ TEXTURE_ENV = 0x2300
+
+ EYE_LINEAR = 0x2400
+ OBJECT_LINEAR = 0x2401
+ SPHERE_MAP = 0x2402
+
+ EYE_PLANE = 0x2502
+ OBJECT_PLANE = 0x2501
+ TEXTURE_GEN_MODE = 0x2500
+
+ NEAREST = 0x2600
+
+ LINEAR_MIPMAP_LINEAR = 0x2703
+ LINEAR_MIPMAP_NEAREST = 0x2701
+ NEAREST_MIPMAP_LINEAR = 0x2702
+ NEAREST_MIPMAP_NEAREST = 0x2700
+
+ GENERATE_MIPMAP = 0x8191
+ TEXTURE_WRAP_R = 0x8072
+
+ PROXY_TEXTURE_1D = 0x8063
+ PROXY_TEXTURE_2D = 0x8064
+ PROXY_TEXTURE_3D = 0x8070
+ TEXTURE_3D = 0x806F
+ TEXTURE_BASE_LEVEL = 0x813C
+ TEXTURE_MAX_LEVEL = 0x813D
+ TEXTURE_MAX_LOD = 0x813B
+ TEXTURE_MIN_LOD = 0x813A
+
+ CLAMP = 0x2900
+ CLAMP_TO_BORDER = 0x812D
+ CLAMP_TO_EDGE = 0x812F
+ REPEAT = 0x2901
+
+ CONSTANT_COLOR = 0x8001
+ ONE_MINUS_CONSTANT_COLOR = 0x8002
+ CONSTANT_ALPHA = 0x8003
+ ONE_MINUS_CONSTANT_ALPHA = 0x8004
+ FUNC_ADD = 0x8006
+ MIN = 0x8007
+ MAX = 0x8008
+ BLEND_EQUATION_RGB = 0x8009
+ FUNC_SUBTRACT = 0x800A
+ FUNC_REVERSE_SUBTRACT = 0x800B
+ RESCALE_NORMAL = 0x803A
+ TEXTURE_DEPTH = 0x8071
+ MAX_3D_TEXTURE_SIZE = 0x8073
+ MULTISAMPLE = 0x809D
+ SAMPLE_ALPHA_TO_COVERAGE = 0x809E
+ SAMPLE_ALPHA_TO_ONE = 0x809F
+ SAMPLE_COVERAGE = 0x80A0
+ SAMPLE_BUFFERS = 0x80A8
+ SAMPLES = 0x80A9
+ SAMPLE_COVERAGE_VALUE = 0x80AA
+ SAMPLE_COVERAGE_INVERT = 0x80AB
+ BLEND_DST_RGB = 0x80C8
+ BLEND_SRC_RGB = 0x80C9
+ BLEND_DST_ALPHA = 0x80CA
+ BLEND_SRC_ALPHA = 0x80CB
+ BGR = 0x80E0
+ BGRA = 0x80E1
+ MAX_ELEMENTS_VERTICES = 0x80E8
+ MAX_ELEMENTS_INDICES = 0x80E9
+ DEPTH_COMPONENT16 = 0x81A5
+ DEPTH_COMPONENT24 = 0x81A6
+ DEPTH_COMPONENT32 = 0x81A7
+ UNSIGNED_BYTE_2_3_3_REV = 0x8362
+ UNSIGNED_SHORT_5_6_5 = 0x8363
+ UNSIGNED_SHORT_5_6_5_REV = 0x8364
+ UNSIGNED_SHORT_4_4_4_4_REV = 0x8365
+ UNSIGNED_SHORT_1_5_5_5_REV = 0x8366
+ UNSIGNED_INT_8_8_8_8_REV = 0x8367
+ UNSIGNED_INT_2_10_10_10_REV = 0x8368
+ MIRRORED_REPEAT = 0x8370
+ FOG_COORDINATE_SOURCE = 0x8450
+ FOG_COORD_SRC = 0x8450
+ FOG_COORDINATE = 0x8451
+ FOG_COORD = 0x8451
+ FRAGMENT_DEPTH = 0x8452
+ CURRENT_FOG_COORDINATE = 0x8453
+ CURRENT_FOG_COORD = 0x8453
+ FOG_COORDINATE_ARRAY_TYPE = 0x8454
+ FOG_COORD_ARRAY_TYPE = 0x8454
+ FOG_COORDINATE_ARRAY_STRIDE = 0x8455
+ FOG_COORD_ARRAY_STRIDE = 0x8455
+ FOG_COORDINATE_ARRAY_POINTER = 0x8456
+ FOG_COORD_ARRAY_POINTER = 0x8456
+ FOG_COORDINATE_ARRAY = 0x8457
+ FOG_COORD_ARRAY = 0x8457
+ COLOR_SUM = 0x8458
+ CURRENT_SECONDARY_COLOR = 0x8459
+ SECONDARY_COLOR_ARRAY_SIZE = 0x845A
+ SECONDARY_COLOR_ARRAY_TYPE = 0x845B
+ SECONDARY_COLOR_ARRAY_STRIDE = 0x845C
+ SECONDARY_COLOR_ARRAY_POINTER = 0x845D
+ SECONDARY_COLOR_ARRAY = 0x845E
+ TEXTURE0 = 0x84C0
+ TEXTURE1 = 0x84C1
+ TEXTURE2 = 0x84C2
+ TEXTURE3 = 0x84C3
+ TEXTURE4 = 0x84C4
+ TEXTURE5 = 0x84C5
+ TEXTURE6 = 0x84C6
+ TEXTURE7 = 0x84C7
+ TEXTURE8 = 0x84C8
+ TEXTURE9 = 0x84C9
+ TEXTURE10 = 0x84CA
+ TEXTURE11 = 0x84CB
+ TEXTURE12 = 0x84CC
+ TEXTURE13 = 0x84CD
+ TEXTURE14 = 0x84CE
+ TEXTURE15 = 0x84CF
+ TEXTURE16 = 0x84D0
+ TEXTURE17 = 0x84D1
+ TEXTURE18 = 0x84D2
+ TEXTURE19 = 0x84D3
+ TEXTURE20 = 0x84D4
+ TEXTURE21 = 0x84D5
+ TEXTURE22 = 0x84D6
+ TEXTURE23 = 0x84D7
+ TEXTURE24 = 0x84D8
+ TEXTURE25 = 0x84D9
+ TEXTURE26 = 0x84DA
+ TEXTURE27 = 0x84DB
+ TEXTURE28 = 0x84DC
+ TEXTURE29 = 0x84DD
+ TEXTURE30 = 0x84DE
+ TEXTURE31 = 0x84DF
+ ACTIVE_TEXTURE = 0x84E0
+ CLIENT_ACTIVE_TEXTURE = 0x84E1
+ MAX_TEXTURE_UNITS = 0x84E2
+ TRANSPOSE_MODELVIEW_MATRIX = 0x84E3
+ TRANSPOSE_PROJECTION_MATRIX = 0x84E4
+ TRANSPOSE_TEXTURE_MATRIX = 0x84E5
+ TRANSPOSE_COLOR_MATRIX = 0x84E6
+ SUBTRACT = 0x84E7
+ COMPRESSED_ALPHA = 0x84E9
+ COMPRESSED_LUMINANCE = 0x84EA
+ COMPRESSED_LUMINANCE_ALPHA = 0x84EB
+ COMPRESSED_INTENSITY = 0x84EC
+ COMPRESSED_RGB = 0x84ED
+ COMPRESSED_RGBA = 0x84EE
+ MAX_TEXTURE_LOD_BIAS = 0x84FD
+ TEXTURE_FILTER_CONTROL = 0x8500
+ TEXTURE_LOD_BIAS = 0x8501
+ INCR_WRAP = 0x8507
+ DECR_WRAP = 0x8508
+ NORMAL_MAP = 0x8511
+ REFLECTION_MAP = 0x8512
+ TEXTURE_CUBE_MAP = 0x8513
+ TEXTURE_BINDING_CUBE_MAP = 0x8514
+ TEXTURE_CUBE_MAP_POSITIVE_X = 0x8515
+ TEXTURE_CUBE_MAP_NEGATIVE_X = 0x8516
+ TEXTURE_CUBE_MAP_POSITIVE_Y = 0x8517
+ TEXTURE_CUBE_MAP_NEGATIVE_Y = 0x8518
+ TEXTURE_CUBE_MAP_POSITIVE_Z = 0x8519
+ TEXTURE_CUBE_MAP_NEGATIVE_Z = 0x851A
+ PROXY_TEXTURE_CUBE_MAP = 0x851B
+ MAX_CUBE_MAP_TEXTURE_SIZE = 0x851C
+ COMBINE = 0x8570
+ COMBINE_RGB = 0x8571
+ COMBINE_ALPHA = 0x8572
+ RGB_SCALE = 0x8573
+ ADD_SIGNED = 0x8574
+ INTERPOLATE = 0x8575
+ CONSTANT = 0x8576
+ PRIMARY_COLOR = 0x8577
+ PREVIOUS = 0x8578
+ SOURCE0_RGB = 0x8580
+ SRC0_RGB = 0x8580
+ SOURCE1_RGB = 0x8581
+ SRC1_RGB = 0x8581
+ SOURCE2_RGB = 0x8582
+ SRC2_RGB = 0x8582
+ SOURCE0_ALPHA = 0x8588
+ SRC0_ALPHA = 0x8588
+ SOURCE1_ALPHA = 0x8589
+ SRC1_ALPHA = 0x8589
+ SOURCE2_ALPHA = 0x858A
+ SRC2_ALPHA = 0x858A
+ OPERAND0_RGB = 0x8590
+ OPERAND1_RGB = 0x8591
+ OPERAND2_RGB = 0x8592
+ OPERAND0_ALPHA = 0x8598
+ OPERAND1_ALPHA = 0x8599
+ OPERAND2_ALPHA = 0x859A
+ VERTEX_ATTRIB_ARRAY_ENABLED = 0x8622
+ VERTEX_ATTRIB_ARRAY_SIZE = 0x8623
+ VERTEX_ATTRIB_ARRAY_STRIDE = 0x8624
+ VERTEX_ATTRIB_ARRAY_TYPE = 0x8625
+ CURRENT_VERTEX_ATTRIB = 0x8626
+ VERTEX_PROGRAM_POINT_SIZE = 0x8642
+ VERTEX_PROGRAM_TWO_SIDE = 0x8643
+ VERTEX_ATTRIB_ARRAY_POINTER = 0x8645
+ TEXTURE_COMPRESSED_IMAGE_SIZE = 0x86A0
+ TEXTURE_COMPRESSED = 0x86A1
+ NUM_COMPRESSED_TEXTURE_FORMATS = 0x86A2
+ COMPRESSED_TEXTURE_FORMATS = 0x86A3
+ DOT3_RGB = 0x86AE
+ DOT3_RGBA = 0x86AF
+ BUFFER_SIZE = 0x8764
+ BUFFER_USAGE = 0x8765
+ STENCIL_BACK_FUNC = 0x8800
+ STENCIL_BACK_FAIL = 0x8801
+ STENCIL_BACK_PASS_DEPTH_FAIL = 0x8802
+ STENCIL_BACK_PASS_DEPTH_PASS = 0x8803
+ MAX_DRAW_BUFFERS = 0x8824
+ DRAW_BUFFER0 = 0x8825
+ DRAW_BUFFER1 = 0x8826
+ DRAW_BUFFER2 = 0x8827
+ DRAW_BUFFER3 = 0x8828
+ DRAW_BUFFER4 = 0x8829
+ DRAW_BUFFER5 = 0x882A
+ DRAW_BUFFER6 = 0x882B
+ DRAW_BUFFER7 = 0x882C
+ DRAW_BUFFER8 = 0x882D
+ DRAW_BUFFER9 = 0x882E
+ DRAW_BUFFER10 = 0x882F
+ DRAW_BUFFER11 = 0x8830
+ DRAW_BUFFER12 = 0x8831
+ DRAW_BUFFER13 = 0x8832
+ DRAW_BUFFER14 = 0x8833
+ DRAW_BUFFER15 = 0x8834
+ BLEND_EQUATION_ALPHA = 0x883D
+ TEXTURE_DEPTH_SIZE = 0x884A
+ DEPTH_TEXTURE_MODE = 0x884B
+ TEXTURE_COMPARE_MODE = 0x884C
+ TEXTURE_COMPARE_FUNC = 0x884D
+ COMPARE_R_TO_TEXTURE = 0x884E
+ POINT_SPRITE = 0x8861
+ COORD_REPLACE = 0x8862
+ QUERY_COUNTER_BITS = 0x8864
+ CURRENT_QUERY = 0x8865
+ QUERY_RESULT = 0x8866
+ QUERY_RESULT_AVAILABLE = 0x8867
+ MAX_VERTEX_ATTRIBS = 0x8869
+ VERTEX_ATTRIB_ARRAY_NORMALIZED = 0x886A
+ MAX_TEXTURE_COORDS = 0x8871
+ MAX_TEXTURE_IMAGE_UNITS = 0x8872
+ ARRAY_BUFFER = 0x8892
+ ELEMENT_ARRAY_BUFFER = 0x8893
+ ARRAY_BUFFER_BINDING = 0x8894
+ ELEMENT_ARRAY_BUFFER_BINDING = 0x8895
+ VERTEX_ARRAY_BUFFER_BINDING = 0x8896
+ NORMAL_ARRAY_BUFFER_BINDING = 0x8897
+ COLOR_ARRAY_BUFFER_BINDING = 0x8898
+ INDEX_ARRAY_BUFFER_BINDING = 0x8899
+ TEXTURE_COORD_ARRAY_BUFFER_BINDING = 0x889A
+ EDGE_FLAG_ARRAY_BUFFER_BINDING = 0x889B
+ SECONDARY_COLOR_ARRAY_BUFFER_BINDING = 0x889C
+ FOG_COORDINATE_ARRAY_BUFFER_BINDING = 0x889D
+ FOG_COORD_ARRAY_BUFFER_BINDING = 0x889D
+ WEIGHT_ARRAY_BUFFER_BINDING = 0x889E
+ VERTEX_ATTRIB_ARRAY_BUFFER_BINDING = 0x889F
+ READ_ONLY = 0x88B8
+ WRITE_ONLY = 0x88B9
+ READ_WRITE = 0x88BA
+ BUFFER_ACCESS = 0x88BB
+ BUFFER_MAPPED = 0x88BC
+ BUFFER_MAP_POINTER = 0x88BD
+ STREAM_DRAW = 0x88E0
+ STREAM_READ = 0x88E1
+ STREAM_COPY = 0x88E2
+ STATIC_DRAW = 0x88E4
+ STATIC_READ = 0x88E5
+ STATIC_COPY = 0x88E6
+ DYNAMIC_DRAW = 0x88E8
+ DYNAMIC_READ = 0x88E9
+ DYNAMIC_COPY = 0x88EA
+ SAMPLES_PASSED = 0x8914
+ FRAGMENT_SHADER = 0x8B30
+ VERTEX_SHADER = 0x8B31
+ MAX_FRAGMENT_UNIFORM_COMPONENTS = 0x8B49
+ MAX_VERTEX_UNIFORM_COMPONENTS = 0x8B4A
+ MAX_VARYING_FLOATS = 0x8B4B
+ MAX_VERTEX_TEXTURE_IMAGE_UNITS = 0x8B4C
+ MAX_COMBINED_TEXTURE_IMAGE_UNITS = 0x8B4D
+ SHADER_TYPE = 0x8B4F
+ FLOAT_VEC2 = 0x8B50
+ FLOAT_VEC3 = 0x8B51
+ FLOAT_VEC4 = 0x8B52
+ INT_VEC2 = 0x8B53
+ INT_VEC3 = 0x8B54
+ INT_VEC4 = 0x8B55
+ BOOL = 0x8B56
+ BOOL_VEC2 = 0x8B57
+ BOOL_VEC3 = 0x8B58
+ BOOL_VEC4 = 0x8B59
+ FLOAT_MAT2 = 0x8B5A
+ FLOAT_MAT3 = 0x8B5B
+ FLOAT_MAT4 = 0x8B5C
+ SAMPLER_1D = 0x8B5D
+ SAMPLER_2D = 0x8B5E
+ SAMPLER_3D = 0x8B5F
+ SAMPLER_CUBE = 0x8B60
+ SAMPLER_1D_SHADOW = 0x8B61
+ SAMPLER_2D_SHADOW = 0x8B62
+ DELETE_STATUS = 0x8B80
+ COMPILE_STATUS = 0x8B81
+ LINK_STATUS = 0x8B82
+ VALIDATE_STATUS = 0x8B83
+ INFO_LOG_LENGTH = 0x8B84
+ ATTACHED_SHADERS = 0x8B85
+ ACTIVE_UNIFORMS = 0x8B86
+ ACTIVE_UNIFORM_MAX_LENGTH = 0x8B87
+ SHADER_SOURCE_LENGTH = 0x8B88
+ ACTIVE_ATTRIBUTES = 0x8B89
+ ACTIVE_ATTRIBUTE_MAX_LENGTH = 0x8B8A
+ SHADING_LANGUAGE_VERSION = 0x8B8C
+ CURRENT_PROGRAM = 0x8B8D
+ POINT_SPRITE_COORD_ORIGIN = 0x8CA0
+ LOWER_LEFT = 0x8CA1
+ UPPER_LEFT = 0x8CA2
+ STENCIL_BACK_REF = 0x8CA3
+ STENCIL_BACK_VALUE_MASK = 0x8CA4
+ STENCIL_BACK_WRITEMASK = 0x8CA5
+)
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glViewport.xml
+func (gl *GL) Viewport(x, y, width, height int) {
+ C.gl2_0_glViewport(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// DepthRange specifies the mapping of depth values from normalized device
+// coordinates to window coordinates.
+//
+// Parameter nearVal specifies the mapping of the near clipping plane to window
+// coordinates (defaults to 0), while farVal specifies the mapping of the far
+// clipping plane to window coordinates (defaults to 1).
+//
+// After clipping and division by w, depth coordinates range from -1 to 1,
+// corresponding to the near and far clipping planes. DepthRange specifies a
+// linear mapping of the normalized depth coordinates in this range to window
+// depth coordinates. Regardless of the actual depth buffer implementation,
+// window coordinate depth values are treated as though they range from 0 through 1
+// (like color components). Thus, the values accepted by DepthRange are both
+// clamped to this range before they are accepted.
+//
+// The default setting of (0, 1) maps the near plane to 0 and the far plane to 1.
+// With this mapping, the depth buffer range is fully utilized.
+//
+// It is not necessary that nearVal be less than farVal. Reverse mappings such as
+// nearVal 1, and farVal 0 are acceptable.
+//
+// GL.INVALID_OPERATION is generated if DepthRange is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) DepthRange(nearVal, farVal float64) {
+ C.gl2_0_glDepthRange(gl.funcs, C.GLdouble(nearVal), C.GLdouble(farVal))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIsEnabled.xml
+func (gl *GL) IsEnabled(cap glbase.Enum) bool {
+ glresult := C.gl2_0_glIsEnabled(gl.funcs, C.GLenum(cap))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexLevelParameteriv.xml
+func (gl *GL) GetTexLevelParameteriv(target glbase.Enum, level int, pname glbase.Enum, params []int32) {
+ C.gl2_0_glGetTexLevelParameteriv(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexLevelParameterfv.xml
+func (gl *GL) GetTexLevelParameterfv(target glbase.Enum, level int, pname glbase.Enum, params []float32) {
+ C.gl2_0_glGetTexLevelParameterfv(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexParameteriv.xml
+func (gl *GL) GetTexParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl2_0_glGetTexParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexParameterfv.xml
+func (gl *GL) GetTexParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl2_0_glGetTexParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexImage.xml
+func (gl *GL) GetTexImage(target glbase.Enum, level int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_0_glGetTexImage(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetIntegerv.xml
+func (gl *GL) GetIntegerv(pname glbase.Enum, params []int32) {
+ C.gl2_0_glGetIntegerv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetFloatv.xml
+func (gl *GL) GetFloatv(pname glbase.Enum, params []float32) {
+ C.gl2_0_glGetFloatv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetError.xml
+func (gl *GL) GetError() glbase.Enum {
+ glresult := C.gl2_0_glGetError(gl.funcs)
+ return glbase.Enum(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetDoublev.xml
+func (gl *GL) GetDoublev(pname glbase.Enum, params []float64) {
+ C.gl2_0_glGetDoublev(gl.funcs, C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetBooleanv.xml
+func (gl *GL) GetBooleanv(pname glbase.Enum, params []bool) {
+ C.gl2_0_glGetBooleanv(gl.funcs, C.GLenum(pname), (*C.GLboolean)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glReadPixels.xml
+func (gl *GL) ReadPixels(x, y, width, height int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_0_glReadPixels(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glReadBuffer.xml
+func (gl *GL) ReadBuffer(mode glbase.Enum) {
+ C.gl2_0_glReadBuffer(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelStorei.xml
+func (gl *GL) PixelStorei(pname glbase.Enum, param int32) {
+ C.gl2_0_glPixelStorei(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelStoref.xml
+func (gl *GL) PixelStoref(pname glbase.Enum, param float32) {
+ C.gl2_0_glPixelStoref(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDepthFunc.xml
+func (gl *GL) DepthFunc(glfunc glbase.Enum) {
+ C.gl2_0_glDepthFunc(gl.funcs, C.GLenum(glfunc))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glStencilOp.xml
+func (gl *GL) StencilOp(fail, zfail, zpass glbase.Enum) {
+ C.gl2_0_glStencilOp(gl.funcs, C.GLenum(fail), C.GLenum(zfail), C.GLenum(zpass))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glStencilFunc.xml
+func (gl *GL) StencilFunc(glfunc glbase.Enum, ref int32, mask uint32) {
+ C.gl2_0_glStencilFunc(gl.funcs, C.GLenum(glfunc), C.GLint(ref), C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLogicOp.xml
+func (gl *GL) LogicOp(opcode glbase.Enum) {
+ C.gl2_0_glLogicOp(gl.funcs, C.GLenum(opcode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBlendFunc.xml
+func (gl *GL) BlendFunc(sfactor, dfactor glbase.Enum) {
+ C.gl2_0_glBlendFunc(gl.funcs, C.GLenum(sfactor), C.GLenum(dfactor))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFlush.xml
+func (gl *GL) Flush() {
+ C.gl2_0_glFlush(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFinish.xml
+func (gl *GL) Finish() {
+ C.gl2_0_glFinish(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEnable.xml
+func (gl *GL) Enable(cap glbase.Enum) {
+ C.gl2_0_glEnable(gl.funcs, C.GLenum(cap))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDisable.xml
+func (gl *GL) Disable(cap glbase.Enum) {
+ C.gl2_0_glDisable(gl.funcs, C.GLenum(cap))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDepthMask.xml
+func (gl *GL) DepthMask(flag bool) {
+ C.gl2_0_glDepthMask(gl.funcs, *(*C.GLboolean)(unsafe.Pointer(&flag)))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColorMask.xml
+func (gl *GL) ColorMask(red, green, blue, alpha bool) {
+ C.gl2_0_glColorMask(gl.funcs, *(*C.GLboolean)(unsafe.Pointer(&red)), *(*C.GLboolean)(unsafe.Pointer(&green)), *(*C.GLboolean)(unsafe.Pointer(&blue)), *(*C.GLboolean)(unsafe.Pointer(&alpha)))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glStencilMask.xml
+func (gl *GL) StencilMask(mask uint32) {
+ C.gl2_0_glStencilMask(gl.funcs, C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClearDepth.xml
+func (gl *GL) ClearDepth(depth float64) {
+ C.gl2_0_glClearDepth(gl.funcs, C.GLdouble(depth))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClearStencil.xml
+func (gl *GL) ClearStencil(s int32) {
+ C.gl2_0_glClearStencil(gl.funcs, C.GLint(s))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClearColor.xml
+func (gl *GL) ClearColor(red, green, blue, alpha float32) {
+ C.gl2_0_glClearColor(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClear.xml
+func (gl *GL) Clear(mask glbase.Bitfield) {
+ C.gl2_0_glClear(gl.funcs, C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDrawBuffer.xml
+func (gl *GL) DrawBuffer(mode glbase.Enum) {
+ C.gl2_0_glDrawBuffer(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexImage2D.xml
+func (gl *GL) TexImage2D(target glbase.Enum, level int, internalFormat int32, width, height, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_0_glTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexImage1D.xml
+func (gl *GL) TexImage1D(target glbase.Enum, level int, internalFormat int32, width, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_0_glTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexParameteriv.xml
+func (gl *GL) TexParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl2_0_glTexParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexParameteri.xml
+func (gl *GL) TexParameteri(target, pname glbase.Enum, param int32) {
+ C.gl2_0_glTexParameteri(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexParameterfv.xml
+func (gl *GL) TexParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl2_0_glTexParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexParameterf.xml
+func (gl *GL) TexParameterf(target, pname glbase.Enum, param float32) {
+ C.gl2_0_glTexParameterf(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glScissor.xml
+func (gl *GL) Scissor(x, y, width, height int) {
+ C.gl2_0_glScissor(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPolygonMode.xml
+func (gl *GL) PolygonMode(face, mode glbase.Enum) {
+ C.gl2_0_glPolygonMode(gl.funcs, C.GLenum(face), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPointSize.xml
+func (gl *GL) PointSize(size float32) {
+ C.gl2_0_glPointSize(gl.funcs, C.GLfloat(size))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLineWidth.xml
+func (gl *GL) LineWidth(width float32) {
+ C.gl2_0_glLineWidth(gl.funcs, C.GLfloat(width))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glHint.xml
+func (gl *GL) Hint(target, mode glbase.Enum) {
+ C.gl2_0_glHint(gl.funcs, C.GLenum(target), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFrontFace.xml
+func (gl *GL) FrontFace(mode glbase.Enum) {
+ C.gl2_0_glFrontFace(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCullFace.xml
+func (gl *GL) CullFace(mode glbase.Enum) {
+ C.gl2_0_glCullFace(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexubv.xml
+func (gl *GL) Indexubv(c []uint8) {
+ C.gl2_0_glIndexubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexub.xml
+func (gl *GL) Indexub(c uint8) {
+ C.gl2_0_glIndexub(gl.funcs, C.GLubyte(c))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIsTexture.xml
+func (gl *GL) IsTexture(texture glbase.Texture) bool {
+ glresult := C.gl2_0_glIsTexture(gl.funcs, C.GLuint(texture))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// GenTextures returns n texture names in textures. There is no guarantee
+// that the names form a contiguous set of integers; however, it is
+// guaranteed that none of the returned names was in use immediately before
+// the call to GenTextures.
+//
+// The generated textures have no dimensionality; they assume the
+// dimensionality of the texture target to which they are first bound (see
+// BindTexture).
+//
+// Texture names returned by a call to GenTextures are not returned by
+// subsequent calls, unless they are first deleted with DeleteTextures.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// GenTextures is available in GL version 2.0 or greater.
+func (gl *GL) GenTextures(n int) []glbase.Texture {
+ if n == 0 {
+ return nil
+ }
+ textures := make([]glbase.Texture, n)
+ C.gl2_0_glGenTextures(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])))
+ return textures
+}
+
+// DeleteTextures deletes the textures objects whose names are stored
+// in the textures slice. After a texture is deleted, it has no contents or
+// dimensionality, and its name is free for reuse (for example by
+// GenTextures). If a texture that is currently bound is deleted, the binding
+// reverts to 0 (the default texture).
+//
+// DeleteTextures silently ignores 0's and names that do not correspond to
+// existing textures.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// DeleteTextures is available in GL version 2.0 or greater.
+func (gl *GL) DeleteTextures(textures []glbase.Texture) {
+ n := len(textures)
+ if n == 0 {
+ return
+ }
+ C.gl2_0_glDeleteTextures(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBindTexture.xml
+func (gl *GL) BindTexture(target glbase.Enum, texture glbase.Texture) {
+ C.gl2_0_glBindTexture(gl.funcs, C.GLenum(target), C.GLuint(texture))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexSubImage2D.xml
+func (gl *GL) TexSubImage2D(target glbase.Enum, level, xoffset, yoffset, width, height int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_0_glTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexSubImage1D.xml
+func (gl *GL) TexSubImage1D(target glbase.Enum, level, xoffset, width int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_0_glTexSubImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLsizei(width), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyTexSubImage2D.xml
+func (gl *GL) CopyTexSubImage2D(target glbase.Enum, level, xoffset, yoffset, x, y, width, height int) {
+ C.gl2_0_glCopyTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyTexSubImage1D.xml
+func (gl *GL) CopyTexSubImage1D(target glbase.Enum, level, xoffset, x, y, width int) {
+ C.gl2_0_glCopyTexSubImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(x), C.GLint(y), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyTexImage2D.xml
+func (gl *GL) CopyTexImage2D(target glbase.Enum, level int, internalFormat glbase.Enum, x, y, width, height, border int) {
+ C.gl2_0_glCopyTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height), C.GLint(border))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyTexImage1D.xml
+func (gl *GL) CopyTexImage1D(target glbase.Enum, level int, internalFormat glbase.Enum, x, y, width, border int) {
+ C.gl2_0_glCopyTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLint(border))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPolygonOffset.xml
+func (gl *GL) PolygonOffset(factor, units float32) {
+ C.gl2_0_glPolygonOffset(gl.funcs, C.GLfloat(factor), C.GLfloat(units))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDrawElements.xml
+func (gl *GL) DrawElements(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_0_glDrawElements(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDrawArrays.xml
+func (gl *GL) DrawArrays(mode glbase.Enum, first, count int) {
+ C.gl2_0_glDrawArrays(gl.funcs, C.GLenum(mode), C.GLint(first), C.GLsizei(count))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyTexSubImage3D.xml
+func (gl *GL) CopyTexSubImage3D(target glbase.Enum, level, xoffset, yoffset int, zoffset int32, x, y, width, height int) {
+ C.gl2_0_glCopyTexSubImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(zoffset), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexSubImage3D.xml
+func (gl *GL) TexSubImage3D(target glbase.Enum, level, xoffset, yoffset int, zoffset int32, width, height int, depth int32, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_0_glTexSubImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(zoffset), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexImage3D.xml
+func (gl *GL) TexImage3D(target glbase.Enum, level int, internalFormat int32, width, height int, depth int32, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_0_glTexImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDrawRangeElements.xml
+func (gl *GL) DrawRangeElements(mode glbase.Enum, start, end uint32, count int, gltype glbase.Enum, indices interface{}) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_0_glDrawRangeElements(gl.funcs, C.GLenum(mode), C.GLuint(start), C.GLuint(end), C.GLsizei(count), C.GLenum(gltype), indices_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBlendEquation.xml
+func (gl *GL) BlendEquation(mode glbase.Enum) {
+ C.gl2_0_glBlendEquation(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBlendColor.xml
+func (gl *GL) BlendColor(red, green, blue, alpha float32) {
+ C.gl2_0_glBlendColor(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetCompressedTexImage.xml
+func (gl *GL) GetCompressedTexImage(target glbase.Enum, level int, img interface{}) {
+ var img_ptr unsafe.Pointer
+ var img_v = reflect.ValueOf(img)
+ if img != nil && img_v.Kind() != reflect.Slice {
+ panic("parameter img must be a slice")
+ }
+ if img != nil {
+ img_ptr = unsafe.Pointer(img_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_0_glGetCompressedTexImage(gl.funcs, C.GLenum(target), C.GLint(level), img_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCompressedTexSubImage1D.xml
+func (gl *GL) CompressedTexSubImage1D(target glbase.Enum, level, xoffset, width int, format glbase.Enum, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_0_glCompressedTexSubImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLsizei(width), C.GLenum(format), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCompressedTexSubImage2D.xml
+func (gl *GL) CompressedTexSubImage2D(target glbase.Enum, level, xoffset, yoffset, width, height int, format glbase.Enum, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_0_glCompressedTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCompressedTexSubImage3D.xml
+func (gl *GL) CompressedTexSubImage3D(target glbase.Enum, level, xoffset, yoffset int, zoffset int32, width, height int, depth int32, format glbase.Enum, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_0_glCompressedTexSubImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(zoffset), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLenum(format), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCompressedTexImage1D.xml
+func (gl *GL) CompressedTexImage1D(target glbase.Enum, level int, internalFormat glbase.Enum, width, border, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_0_glCompressedTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLsizei(width), C.GLint(border), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCompressedTexImage2D.xml
+func (gl *GL) CompressedTexImage2D(target glbase.Enum, level int, internalFormat glbase.Enum, width, height, border, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_0_glCompressedTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLint(border), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCompressedTexImage3D.xml
+func (gl *GL) CompressedTexImage3D(target glbase.Enum, level int, internalFormat glbase.Enum, width, height int, depth int32, border, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_0_glCompressedTexImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLint(border), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSampleCoverage.xml
+func (gl *GL) SampleCoverage(value float32, invert bool) {
+ C.gl2_0_glSampleCoverage(gl.funcs, C.GLfloat(value), *(*C.GLboolean)(unsafe.Pointer(&invert)))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glActiveTexture.xml
+func (gl *GL) ActiveTexture(texture glbase.Enum) {
+ C.gl2_0_glActiveTexture(gl.funcs, C.GLenum(texture))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPointParameteriv.xml
+func (gl *GL) PointParameteriv(pname glbase.Enum, params []int32) {
+ C.gl2_0_glPointParameteriv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPointParameteri.xml
+func (gl *GL) PointParameteri(pname glbase.Enum, param int32) {
+ C.gl2_0_glPointParameteri(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPointParameterfv.xml
+func (gl *GL) PointParameterfv(pname glbase.Enum, params []float32) {
+ C.gl2_0_glPointParameterfv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPointParameterf.xml
+func (gl *GL) PointParameterf(pname glbase.Enum, param float32) {
+ C.gl2_0_glPointParameterf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiDrawArrays.xml
+func (gl *GL) MultiDrawArrays(mode glbase.Enum, first, count []int, drawcount int32) {
+ C.gl2_0_glMultiDrawArrays(gl.funcs, C.GLenum(mode), (*C.GLint)(unsafe.Pointer(&first[0])), (*C.GLsizei)(unsafe.Pointer(&count[0])), C.GLsizei(drawcount))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBlendFuncSeparate.xml
+func (gl *GL) BlendFuncSeparate(sfactorRGB, dfactorRGB, sfactorAlpha, dfactorAlpha glbase.Enum) {
+ C.gl2_0_glBlendFuncSeparate(gl.funcs, C.GLenum(sfactorRGB), C.GLenum(dfactorRGB), C.GLenum(sfactorAlpha), C.GLenum(dfactorAlpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetBufferParameteriv.xml
+func (gl *GL) GetBufferParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl2_0_glGetBufferParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glUnmapBuffer.xml
+func (gl *GL) UnmapBuffer(target glbase.Enum) bool {
+ glresult := C.gl2_0_glUnmapBuffer(gl.funcs, C.GLenum(target))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetBufferSubData.xml
+func (gl *GL) GetBufferSubData(target glbase.Enum, offset, size int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_0_glGetBufferSubData(gl.funcs, C.GLenum(target), C.GLintptr(offset), C.GLsizeiptr(size), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBufferSubData.xml
+func (gl *GL) BufferSubData(target glbase.Enum, offset, size int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_0_glBufferSubData(gl.funcs, C.GLenum(target), C.GLintptr(offset), C.GLsizeiptr(size), data_ptr)
+}
+
+// BufferData creates a new data store for the buffer object currently
+// bound to target. Any pre-existing data store is deleted. The new data
+// store is created with the specified size in bytes and usage. If data is
+// not nil, it must be a slice that is used to initialize the data store.
+// In that case the size parameter is ignored and the store size will match
+// the slice data size.
+//
+// In its initial state, the new data store is not mapped, it has a NULL
+// mapped pointer, and its mapped access is GL.READ_WRITE.
+//
+// The target constant must be one of GL.ARRAY_BUFFER, GL.COPY_READ_BUFFER,
+// GL.COPY_WRITE_BUFFER, GL.ELEMENT_ARRAY_BUFFER, GL.PIXEL_PACK_BUFFER,
+// GL.PIXEL_UNPACK_BUFFER, GL.TEXTURE_BUFFER, GL.TRANSFORM_FEEDBACK_BUFFER,
+// or GL.UNIFORM_BUFFER.
+//
+// The usage parameter is a hint to the GL implementation as to how a buffer
+// object's data store will be accessed. This enables the GL implementation
+// to make more intelligent decisions that may significantly impact buffer
+// object performance. It does not, however, constrain the actual usage of
+// the data store. usage can be broken down into two parts: first, the
+// frequency of access (modification and usage), and second, the nature of
+// that access.
+//
+// A usage frequency of STREAM and nature of DRAW is specified via the
+// constant GL.STREAM_DRAW, for example.
+//
+// The usage frequency of access may be one of:
+//
+// STREAM
+// The data store contents will be modified once and used at most a few times.
+//
+// STATIC
+// The data store contents will be modified once and used many times.
+//
+// DYNAMIC
+// The data store contents will be modified repeatedly and used many times.
+//
+// The usage nature of access may be one of:
+//
+// DRAW
+// The data store contents are modified by the application, and used as
+// the source for GL drawing and image specification commands.
+//
+// READ
+// The data store contents are modified by reading data from the GL,
+// and used to return that data when queried by the application.
+//
+// COPY
+// The data store contents are modified by reading data from the GL,
+// and used as the source for GL drawing and image specification
+// commands.
+//
+// Clients must align data elements consistent with the requirements of the
+// client platform, with an additional base-level requirement that an offset
+// within a buffer to a datum comprising N bytes be a multiple of N.
+//
+// Error GL.INVALID_ENUM is generated if target is not one of the accepted
+// buffer targets. GL.INVALID_ENUM is generated if usage is not
+// GL.STREAM_DRAW, GL.STREAM_READ, GL.STREAM_COPY, GL.STATIC_DRAW,
+// GL.STATIC_READ, GL.STATIC_COPY, GL.DYNAMIC_DRAW, GL.DYNAMIC_READ, or
+// GL.DYNAMIC_COPY. GL.INVALID_VALUE is generated if size is negative.
+// GL.INVALID_OPERATION is generated if the reserved buffer object name 0 is
+// bound to target. GL.OUT_OF_MEMORY is generated if the GL is unable to
+// create a data store with the specified size.
+func (gl *GL) BufferData(target glbase.Enum, size int, data interface{}, usage glbase.Enum) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ if data != nil {
+ size = int(data_v.Type().Size()) * data_v.Len()
+ }
+ C.gl2_0_glBufferData(gl.funcs, C.GLenum(target), C.GLsizeiptr(size), data_ptr, C.GLenum(usage))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIsBuffer.xml
+func (gl *GL) IsBuffer(buffer glbase.Buffer) bool {
+ glresult := C.gl2_0_glIsBuffer(gl.funcs, C.GLuint(buffer))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// GenBuffers returns n buffer object names. There is no guarantee that
+// the names form a contiguous set of integers; however, it is guaranteed
+// that none of the returned names was in use immediately before the call to
+// GenBuffers.
+//
+// Buffer object names returned by a call to GenBuffers are not returned by
+// subsequent calls, unless they are first deleted with DeleteBuffers.
+//
+// No buffer objects are associated with the returned buffer object names
+// until they are first bound by calling BindBuffer.
+//
+// Error GL.INVALID_VALUE is generated if n is negative. GL.INVALID_OPERATION
+// is generated if GenBuffers is executed between the execution of Begin
+// and the corresponding execution of End.
+//
+// GenBuffers is available in GL version 1.5 or greater.
+func (gl *GL) GenBuffers(n int) []glbase.Buffer {
+ if n == 0 {
+ return nil
+ }
+ buffers := make([]glbase.Buffer, n)
+ C.gl2_0_glGenBuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&buffers[0])))
+ return buffers
+}
+
+// DeleteBuffers deletes the buffer objects whose names are stored in the
+// buffers slice.
+//
+// After a buffer object is deleted, it has no contents, and its name is free
+// for reuse (for example by GenBuffers). If a buffer object that is
+// currently bound is deleted, the binding reverts to 0 (the absence of any
+// buffer object, which reverts to client memory usage).
+//
+// DeleteBuffers silently ignores 0's and names that do not correspond to
+// existing buffer objects.
+//
+// Error GL.INVALID_VALUE is generated if n is negative. GL.INVALID_OPERATION
+// is generated if DeleteBuffers is executed between the execution of Begin
+// and the corresponding execution of End.
+//
+// DeleteBuffers is available in GL version 1.5 or greater.
+func (gl *GL) DeleteBuffers(buffers []glbase.Buffer) {
+ n := len(buffers)
+ if n == 0 {
+ return
+ }
+ C.gl2_0_glDeleteBuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&buffers[0])))
+}
+
+// BindBuffer creates or puts in use a named buffer object.
+// Calling BindBuffer with target set to GL.ARRAY_BUFFER,
+// GL.ELEMENT_ARRAY_BUFFER, GL.PIXEL_PACK_BUFFER or GL.PIXEL_UNPACK_BUFFER
+// and buffer set to the name of the new buffer object binds the buffer
+// object name to the target. When a buffer object is bound to a target, the
+// previous binding for that target is automatically broken.
+//
+// Buffer object names are unsigned integers. The value zero is reserved, but
+// there is no default buffer object for each buffer object target. Instead,
+// buffer set to zero effectively unbinds any buffer object previously bound,
+// and restores client memory usage for that buffer object target. Buffer
+// object names and the corresponding buffer object contents are local to the
+// shared display-list space (see XCreateContext) of the current GL rendering
+// context; two rendering contexts share buffer object names only if they
+// also share display lists.
+//
+// GenBuffers may be called to generate a set of new buffer object names.
+//
+// The state of a buffer object immediately after it is first bound is an
+// unmapped zero-sized memory buffer with GL.READ_WRITE access and
+// GL.STATIC_DRAW usage.
+//
+// While a non-zero buffer object name is bound, GL operations on the target
+// to which it is bound affect the bound buffer object, and queries of the
+// target to which it is bound return state from the bound buffer object.
+// While buffer object name zero is bound, as in the initial state, attempts
+// to modify or query state on the target to which it is bound generates an
+// GL.INVALID_OPERATION error.
+//
+// When vertex array pointer state is changed, for example by a call to
+// NormalPointer, the current buffer object binding (GL.ARRAY_BUFFER_BINDING)
+// is copied into the corresponding client state for the vertex array type
+// being changed, for example GL.NORMAL_ARRAY_BUFFER_BINDING. While a
+// non-zero buffer object is bound to the GL.ARRAY_BUFFER target, the vertex
+// array pointer parameter that is traditionally interpreted as a pointer to
+// client-side memory is instead interpreted as an offset within the buffer
+// object measured in basic machine units.
+//
+// While a non-zero buffer object is bound to the GL.ELEMENT_ARRAY_BUFFER
+// target, the indices parameter of DrawElements, DrawRangeElements, or
+// MultiDrawElements that is traditionally interpreted as a pointer to
+// client-side memory is instead interpreted as an offset within the buffer
+// object measured in basic machine units.
+//
+// While a non-zero buffer object is bound to the GL.PIXEL_PACK_BUFFER
+// target, the following commands are affected: GetCompressedTexImage,
+// GetConvolutionFilter, GetHistogram, GetMinmax, GetPixelMap,
+// GetPolygonStipple, GetSeparableFilter, GetTexImage, and ReadPixels. The
+// pointer parameter that is traditionally interpreted as a pointer to
+// client-side memory where the pixels are to be packed is instead
+// interpreted as an offset within the buffer object measured in basic
+// machine units.
+//
+// While a non-zero buffer object is bound to the GL.PIXEL_UNPACK_BUFFER
+// target, the following commands are affected: Bitmap, ColorSubTable,
+// ColorTable, CompressedTexImage1D, CompressedTexImage2D,
+// CompressedTexImage3D, CompressedTexSubImage1D, CompressedTexSubImage2D,
+// CompressedTexSubImage3D, ConvolutionFilter1D, ConvolutionFilter2D,
+// DrawPixels, PixelMap, PolygonStipple, SeparableFilter2D, TexImage1D,
+// TexImage2D, TexImage3D, TexSubImage1D, TexSubImage2D, and TexSubImage3D.
+// The pointer parameter that is traditionally interpreted as a pointer to
+// client-side memory from which the pixels are to be unpacked is instead
+// interpreted as an offset within the buffer object measured in basic
+// machine units.
+//
+// A buffer object binding created with BindBuffer remains active until a
+// different buffer object name is bound to the same target, or until the
+// bound buffer object is deleted with DeleteBuffers.
+//
+// Once created, a named buffer object may be re-bound to any target as often
+// as needed. However, the GL implementation may make choices about how to
+// optimize the storage of a buffer object based on its initial binding
+// target.
+//
+// Error GL.INVALID_ENUM is generated if target is not one of the allowable
+// values. GL.INVALID_OPERATION is generated if BindBuffer is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// BindBuffer is available in GL version 1.5 or greater.
+func (gl *GL) BindBuffer(target glbase.Enum, buffer glbase.Buffer) {
+ C.gl2_0_glBindBuffer(gl.funcs, C.GLenum(target), C.GLuint(buffer))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetQueryObjectuiv.xml
+func (gl *GL) GetQueryObjectuiv(id uint32, pname glbase.Enum, params []uint32) {
+ C.gl2_0_glGetQueryObjectuiv(gl.funcs, C.GLuint(id), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetQueryObjectiv.xml
+func (gl *GL) GetQueryObjectiv(id uint32, pname glbase.Enum, params []int32) {
+ C.gl2_0_glGetQueryObjectiv(gl.funcs, C.GLuint(id), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetQueryiv.xml
+func (gl *GL) GetQueryiv(target, pname glbase.Enum, params []int32) {
+ C.gl2_0_glGetQueryiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEndQuery.xml
+func (gl *GL) EndQuery(target glbase.Enum) {
+ C.gl2_0_glEndQuery(gl.funcs, C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBeginQuery.xml
+func (gl *GL) BeginQuery(target glbase.Enum, id uint32) {
+ C.gl2_0_glBeginQuery(gl.funcs, C.GLenum(target), C.GLuint(id))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIsQuery.xml
+func (gl *GL) IsQuery(id uint32) bool {
+ glresult := C.gl2_0_glIsQuery(gl.funcs, C.GLuint(id))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDeleteQueries.xml
+func (gl *GL) DeleteQueries(n int, ids []uint32) {
+ C.gl2_0_glDeleteQueries(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&ids[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGenQueries.xml
+func (gl *GL) GenQueries(n int, ids []uint32) {
+ C.gl2_0_glGenQueries(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&ids[0])))
+}
+
+// VertexAttribPointer specifies the location and data format of the array
+// of generic vertex attributes at index to use when rendering. size
+// specifies the number of components per attribute and must be 1, 2, 3, or
+// 4. type specifies the data type of each component, and stride specifies
+// the byte stride from one attribute to the next, allowing vertices and
+// attributes to be packed into a single array or stored in separate arrays.
+// normalized indicates whether the values stored in an integer format are
+// to be mapped to the range [-1,1] (for signed values) or [0,1]
+// (for unsigned values) when they are accessed and converted to floating
+// point; otherwise, values will be converted to floats directly without
+// normalization. offset is a byte offset into the buffer object's data
+// store, which must be bound to the GL.ARRAY_BUFFER target with BindBuffer.
+//
+// The buffer object binding (GL.ARRAY_BUFFER_BINDING) is saved as
+// generic vertex attribute array client-side state
+// (GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING) for the provided index.
+//
+// To enable and disable a generic vertex attribute array, call
+// EnableVertexAttribArray and DisableVertexAttribArray with index. If
+// enabled, the generic vertex attribute array is used when DrawArrays or
+// DrawElements is called. Each generic vertex attribute array is initially
+// disabled.
+//
+// VertexAttribPointer is typically implemented on the client side.
+//
+// Error GL.INVALID_ENUM is generated if type is not an accepted value.
+// GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_VALUE is generated if size is not 1, 2,
+// 3, or 4. GL.INVALID_VALUE is generated if stride is negative.
+func (gl *GL) VertexAttribPointer(index glbase.Attrib, size int, gltype glbase.Enum, normalized bool, stride int, offset uintptr) {
+ offset_ptr := unsafe.Pointer(offset)
+ C.gl2_0_glVertexAttribPointer(gl.funcs, C.GLuint(index), C.GLint(size), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), C.GLsizei(stride), offset_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glValidateProgram.xml
+func (gl *GL) ValidateProgram(program glbase.Program) {
+ C.gl2_0_glValidateProgram(gl.funcs, C.GLuint(program))
+}
+
+// UniformMatrix4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix4fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(4*4) != 0 {
+ panic("invalid value length for UniformMatrix4fv")
+ }
+ count := len(value) / (4 * 4)
+ C.gl2_0_glUniformMatrix4fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix3fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(3*3) != 0 {
+ panic("invalid value length for UniformMatrix3fv")
+ }
+ count := len(value) / (3 * 3)
+ C.gl2_0_glUniformMatrix3fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix2fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(2*2) != 0 {
+ panic("invalid value length for UniformMatrix2fv")
+ }
+ count := len(value) / (2 * 2)
+ C.gl2_0_glUniformMatrix2fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform4iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%4 != 0 {
+ panic("invalid value length for Uniform4iv")
+ }
+ count := len(value) / 4
+ C.gl2_0_glUniform4iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform3iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform3iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%3 != 0 {
+ panic("invalid value length for Uniform3iv")
+ }
+ count := len(value) / 3
+ C.gl2_0_glUniform3iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform2iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform2iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%2 != 0 {
+ panic("invalid value length for Uniform2iv")
+ }
+ count := len(value) / 2
+ C.gl2_0_glUniform2iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform1iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform1iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ count := len(value)
+ C.gl2_0_glUniform1iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%4 != 0 {
+ panic("invalid value length for Uniform4fv")
+ }
+ count := len(value) / 4
+ C.gl2_0_glUniform4fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%3 != 0 {
+ panic("invalid value length for Uniform3fv")
+ }
+ count := len(value) / 3
+ C.gl2_0_glUniform3fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%2 != 0 {
+ panic("invalid value length for Uniform2fv")
+ }
+ count := len(value) / 2
+ C.gl2_0_glUniform2fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform1fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform1fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ count := len(value)
+ C.gl2_0_glUniform1fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform4i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4i(location glbase.Uniform, v0, v1, v2, v3 int32) {
+ C.gl2_0_glUniform4i(gl.funcs, C.GLint(location), C.GLint(v0), C.GLint(v1), C.GLint(v2), C.GLint(v3))
+}
+
+// Uniform3i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform3i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3i(location glbase.Uniform, v0, v1, v2 int32) {
+ C.gl2_0_glUniform3i(gl.funcs, C.GLint(location), C.GLint(v0), C.GLint(v1), C.GLint(v2))
+}
+
+// Uniform2i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform2i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2i(location glbase.Uniform, v0, v1 int32) {
+ C.gl2_0_glUniform2i(gl.funcs, C.GLint(location), C.GLint(v0), C.GLint(v1))
+}
+
+// Uniform1i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform1i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1i(location glbase.Uniform, v0 int32) {
+ C.gl2_0_glUniform1i(gl.funcs, C.GLint(location), C.GLint(v0))
+}
+
+// Uniform4f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform4f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4f(location glbase.Uniform, v0, v1, v2, v3 float32) {
+ C.gl2_0_glUniform4f(gl.funcs, C.GLint(location), C.GLfloat(v0), C.GLfloat(v1), C.GLfloat(v2), C.GLfloat(v3))
+}
+
+// Uniform3f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform3f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3f(location glbase.Uniform, v0, v1, v2 float32) {
+ C.gl2_0_glUniform3f(gl.funcs, C.GLint(location), C.GLfloat(v0), C.GLfloat(v1), C.GLfloat(v2))
+}
+
+// Uniform2f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform2f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2f(location glbase.Uniform, v0, v1 float32) {
+ C.gl2_0_glUniform2f(gl.funcs, C.GLint(location), C.GLfloat(v0), C.GLfloat(v1))
+}
+
+// Uniform1f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform1f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1f(location glbase.Uniform, v0 float32) {
+ C.gl2_0_glUniform1f(gl.funcs, C.GLint(location), C.GLfloat(v0))
+}
+
+// UseProgram installs the program object specified by program as part of
+// current rendering state. One or more executables are created in a program
+// object by successfully attaching shader objects to it with AttachShader,
+// successfully compiling the shader objects with CompileShader, and
+// successfully linking the program object with LinkProgram.
+//
+// A program object will contain an executable that will run on the vertex
+// processor if it contains one or more shader objects of type
+// GL.VERTEX_SHADER that have been successfully compiled and linked.
+// Similarly, a program object will contain an executable that will run on
+// the fragment processor if it contains one or more shader objects of type
+// GL.FRAGMENT_SHADER that have been successfully compiled and linked.
+//
+// Successfully installing an executable on a programmable processor will
+// cause the corresponding fixed functionality of OpenGL to be disabled.
+// Specifically, if an executable is installed on the vertex processor, the
+// OpenGL fixed functionality will be disabled as follows.
+//
+// - The modelview matrix is not applied to vertex coordinates.
+//
+// - The projection matrix is not applied to vertex coordinates.
+//
+// - The texture matrices are not applied to texture coordinates.
+//
+// - Normals are not transformed to eye coordinates.
+//
+// - Normals are not rescaled or normalized.
+//
+// - Normalization of GL.AUTO_NORMAL evaluated normals is not performed.
+//
+// - Texture coordinates are not generated automatically.
+//
+// - Per-vertex lighting is not performed.
+//
+// - Color material computations are not performed.
+//
+// - Color index lighting is not performed.
+//
+// - This list also applies when setting the current raster position.
+//
+// The executable that is installed on the vertex processor is expected to
+// implement any or all of the desired functionality from the preceding list.
+// Similarly, if an executable is installed on the fragment processor, the
+// OpenGL fixed functionality will be disabled as follows.
+//
+// - Texture environment and texture functions are not applied.
+//
+// - Texture application is not applied.
+//
+// - Color sum is not applied.
+//
+// - Fog is not applied.
+//
+// Again, the fragment shader that is installed is expected to implement any
+// or all of the desired functionality from the preceding list.
+//
+// While a program object is in use, applications are free to modify attached
+// shader objects, compile attached shader objects, attach additional shader
+// objects, and detach or delete shader objects. None of these operations
+// will affect the executables that are part of the current state. However,
+// relinking the program object that is currently in use will install the
+// program object as part of the current rendering state if the link
+// operation was successful (see LinkProgram). If the program object
+// currently in use is relinked unsuccessfully, its link status will be set
+// to GL.FALSE, but the executables and associated state will remain part of
+// the current state until a subsequent call to UseProgram removes it from
+// use. After it is removed from use, it cannot be made part of current state
+// until it has been successfully relinked.
+//
+// If program contains shader objects of type GL.VERTEX_SHADER but it does
+// not contain shader objects of type GL.FRAGMENT_SHADER, an executable will
+// be installed on the vertex processor, but fixed functionality will be used
+// for fragment processing. Similarly, if program contains shader objects of
+// type GL.FRAGMENT_SHADER but it does not contain shader objects of type
+// GL.VERTEX_SHADER, an executable will be installed on the fragment
+// processor, but fixed functionality will be used for vertex processing. If
+// program is 0, the programmable processors will be disabled, and fixed
+// functionality will be used for both vertex and fragment processing.
+//
+// While a program object is in use, the state that controls the disabled
+// fixed functionality may also be updated using the normal OpenGL calls.
+//
+// Like display lists and texture objects, the name space for program objects
+// may be shared across a set of contexts, as long as the server sides of the
+// contexts share the same address space. If the name space is shared across
+// contexts, any attached objects and the data associated with those attached
+// objects are shared as well.
+//
+// Applications are responsible for providing the synchronization across API
+// calls when objects are accessed from different execution threads.
+//
+// Error GL.INVALID_VALUE is generated if program is neither 0 nor a value
+// generated by OpenGL. GL.INVALID_OPERATION is generated if program is not
+// a program object. GL.INVALID_OPERATION is generated if program could not
+// be made part of current state. GL.INVALID_OPERATION is generated if
+// UseProgram is executed between the execution of Begin and the
+// corresponding execution of End.
+//
+// UseProgram is available in GL version 2.0 or greater.
+func (gl *GL) UseProgram(program glbase.Program) {
+ C.gl2_0_glUseProgram(gl.funcs, C.GLuint(program))
+}
+
+// ShaderSource sets the source code in shader to the provided source code. Any source
+// code previously stored in the shader object is completely replaced.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader is not a shader
+// object. GL.INVALID_VALUE is generated if count is less than 0.
+// GL.INVALID_OPERATION is generated if ShaderSource is executed between the
+// execution of Begin and the corresponding execution of End.
+//
+// ShaderSource is available in GL version 2.0 or greater.
+func (gl *GL) ShaderSource(shader glbase.Shader, source ...string) {
+ count := len(source)
+ length := make([]int32, count)
+ source_c := make([]unsafe.Pointer, count)
+ for i, src := range source {
+ length[i] = int32(len(src))
+ if len(src) > 0 {
+ source_c[i] = *(*unsafe.Pointer)(unsafe.Pointer(&src))
+ } else {
+ source_c[i] = unsafe.Pointer(uintptr(0))
+ }
+ }
+ C.gl2_0_glShaderSource(gl.funcs, C.GLuint(shader), C.GLsizei(count), (**C.GLchar)(unsafe.Pointer(&source_c[0])), (*C.GLint)(unsafe.Pointer(&length[0])))
+}
+
+// LinkProgram links the program object specified by program. If any shader
+// objects of type GL.VERTEX_SHADER are attached to program, they will be
+// used to create an executable that will run on the programmable vertex
+// processor. If any shader objects of type GL.FRAGMENT_SHADER are attached
+// to program, they will be used to create an executable that will run on the
+// programmable fragment processor.
+//
+// The status of the link operation will be stored as part of the program
+// object's state. This value will be set to GL.TRUE if the program object
+// was linked without errors and is ready for use, and GL.FALSE otherwise. It
+// can be queried by calling GetProgramiv with arguments program and
+// GL.LINK_STATUS.
+//
+// As a result of a successful link operation, all active user-defined
+// uniform variables belonging to program will be initialized to 0, and each
+// of the program object's active uniform variables will be assigned a
+// location that can be queried by calling GetUniformLocation. Also, any
+// active user-defined attribute variables that have not been bound to a
+// generic vertex attribute index will be bound to one at this time.
+//
+// Linking of a program object can fail for a number of reasons as specified
+// in the OpenGL Shading Language Specification. The following lists some of
+// the conditions that will cause a link error.
+//
+// - The number of active attribute variables supported by the
+// implementation has been exceeded.
+//
+// - The storage limit for uniform variables has been exceeded.
+//
+// - The number of active uniform variables supported by the implementation
+// has been exceeded.
+//
+// - The main function is missing for the vertex shader or the fragment
+// shader.
+//
+// - A varying variable actually used in the fragment shader is not
+// declared in the same way (or is not declared at all) in the vertex
+// shader.
+//
+// - A reference to a function or variable name is unresolved.
+//
+// - A shared global is declared with two different types or two different
+// initial values.
+//
+// - One or more of the attached shader objects has not been successfully
+// compiled.
+//
+// - Binding a generic attribute matrix caused some rows of the matrix to
+// fall outside the allowed maximum of GL.MAX_VERTEX_ATTRIBS.
+//
+// - Not enough contiguous vertex attribute slots could be found to bind
+// attribute matrices.
+//
+// When a program object has been successfully linked, the program object can
+// be made part of current state by calling UseProgram. Whether or not the
+// link operation was successful, the program object's information log will
+// be overwritten. The information log can be retrieved by calling
+// GetProgramInfoLog.
+//
+// LinkProgram will also install the generated executables as part of the
+// current rendering state if the link operation was successful and the
+// specified program object is already currently in use as a result of a
+// previous call to UseProgram. If the program object currently in use is
+// relinked unsuccessfully, its link status will be set to GL.FALSE , but the
+// executables and associated state will remain part of the current state
+// until a subsequent call to UseProgram removes it from use. After it is
+// removed from use, it cannot be made part of current state until it has
+// been successfully relinked.
+//
+// If program contains shader objects of type GL.VERTEX_SHADER but does not
+// contain shader objects of type GL.FRAGMENT_SHADER, the vertex shader will
+// be linked against the implicit interface for fixed functionality fragment
+// processing. Similarly, if program contains shader objects of type
+// GL.FRAGMENT_SHADER but it does not contain shader objects of type
+// GL.VERTEX_SHADER, the fragment shader will be linked against the implicit
+// interface for fixed functionality vertex processing.
+//
+// The program object's information log is updated and the program is
+// generated at the time of the link operation. After the link operation,
+// applications are free to modify attached shader objects, compile attached
+// shader objects, detach shader objects, delete shader objects, and attach
+// additional shader objects. None of these operations affects the
+// information log or the program that is part of the program object.
+//
+// If the link operation is unsuccessful, any information about a previous
+// link operation on program is lost (a failed link does not restore the
+// old state of program). Certain information can still be retrieved
+// from program even after an unsuccessful link operation. See for instance
+// GetActiveAttrib and GetActiveUniform.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program
+// object. GL.INVALID_OPERATION is generated if LinkProgram is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// LinkProgram is available in GL version 2.0 or greater.
+func (gl *GL) LinkProgram(program glbase.Program) {
+ C.gl2_0_glLinkProgram(gl.funcs, C.GLuint(program))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIsShader.xml
+func (gl *GL) IsShader(shader glbase.Shader) bool {
+ glresult := C.gl2_0_glIsShader(gl.funcs, C.GLuint(shader))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIsProgram.xml
+func (gl *GL) IsProgram(program glbase.Program) bool {
+ glresult := C.gl2_0_glIsProgram(gl.funcs, C.GLuint(program))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// GetVertexAttribiv returns in params the value of a generic vertex attribute
+// parameter. The generic vertex attribute to be queried is specified by
+// index, and the parameter to be queried is specified by pname.
+//
+// The accepted parameter names are as follows:
+//
+// GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING
+// params returns a single value, the name of the buffer object
+// currently bound to the binding point corresponding to generic vertex
+// attribute array index. If no buffer object is bound, 0 is returned.
+// The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_ENABLED
+// params returns a single value that is non-zero (true) if the vertex
+// attribute array for index is enabled and 0 (false) if it is
+// disabled. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_SIZE
+// params returns a single value, the size of the vertex attribute
+// array for index. The size is the number of values for each element
+// of the vertex attribute array, and it will be 1, 2, 3, or 4. The
+// initial value is 4.
+//
+// GL.VERTEX_ATTRIB_ARRAY_STRIDE
+// params returns a single value, the array stride for (number of bytes
+// between successive elements in) the vertex attribute array for
+// index. A value of 0 indicates that the array elements are stored
+// sequentially in memory. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_TYPE
+// params returns a single value, a symbolic constant indicating the
+// array type for the vertex attribute array for index. Possible values
+// are GL.BYTE, GL.UNSIGNED_BYTE, GL.SHORT, GL.UNSIGNED_SHORT, GL.INT,
+// GL.UNSIGNED_INT, GL.FLOAT, and GL.DOUBLE. The initial value is
+// GL.FLOAT.
+//
+// GL.VERTEX_ATTRIB_ARRAY_NORMALIZED
+// params returns a single value that is non-zero (true) if fixed-point
+// data types for the vertex attribute array indicated by index are
+// normalized when they are converted to floating point, and 0 (false)
+// otherwise. The initial value is 0.
+//
+// GL.CURRENT_VERTEX_ATTRIB
+// params returns four values that represent the current value for the
+// generic vertex attribute specified by index. Generic vertex
+// attribute 0 is unique in that it has no current state, so an error
+// will be generated if index is 0. The initial value for all other
+// generic vertex attributes is (0,0,0,1).
+//
+// All of the parameters except GL.CURRENT_VERTEX_ATTRIB represent
+// client-side state.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_ENUM is generated if pname is not an
+// accepted value. GL.INVALID_OPERATION is generated if index is 0 and pname
+// is GL.CURRENT_VERTEX_ATTRIB.
+//
+// GetVertexAttribiv is available in GL version 2.0 or greater.
+func (gl *GL) GetVertexAttribiv(index glbase.Attrib, pname glbase.Enum, params []int32) {
+ var params_c [4]int32
+ C.gl2_0_glGetVertexAttribiv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetVertexAttribfv returns in params the value of a generic vertex attribute
+// parameter. The generic vertex attribute to be queried is specified by
+// index, and the parameter to be queried is specified by pname.
+//
+// The accepted parameter names are as follows:
+//
+// GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING
+// params returns a single value, the name of the buffer object
+// currently bound to the binding point corresponding to generic vertex
+// attribute array index. If no buffer object is bound, 0 is returned.
+// The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_ENABLED
+// params returns a single value that is non-zero (true) if the vertex
+// attribute array for index is enabled and 0 (false) if it is
+// disabled. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_SIZE
+// params returns a single value, the size of the vertex attribute
+// array for index. The size is the number of values for each element
+// of the vertex attribute array, and it will be 1, 2, 3, or 4. The
+// initial value is 4.
+//
+// GL.VERTEX_ATTRIB_ARRAY_STRIDE
+// params returns a single value, the array stride for (number of bytes
+// between successive elements in) the vertex attribute array for
+// index. A value of 0 indicates that the array elements are stored
+// sequentially in memory. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_TYPE
+// params returns a single value, a symbolic constant indicating the
+// array type for the vertex attribute array for index. Possible values
+// are GL.BYTE, GL.UNSIGNED_BYTE, GL.SHORT, GL.UNSIGNED_SHORT, GL.INT,
+// GL.UNSIGNED_INT, GL.FLOAT, and GL.DOUBLE. The initial value is
+// GL.FLOAT.
+//
+// GL.VERTEX_ATTRIB_ARRAY_NORMALIZED
+// params returns a single value that is non-zero (true) if fixed-point
+// data types for the vertex attribute array indicated by index are
+// normalized when they are converted to floating point, and 0 (false)
+// otherwise. The initial value is 0.
+//
+// GL.CURRENT_VERTEX_ATTRIB
+// params returns four values that represent the current value for the
+// generic vertex attribute specified by index. Generic vertex
+// attribute 0 is unique in that it has no current state, so an error
+// will be generated if index is 0. The initial value for all other
+// generic vertex attributes is (0,0,0,1).
+//
+// All of the parameters except GL.CURRENT_VERTEX_ATTRIB represent
+// client-side state.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_ENUM is generated if pname is not an
+// accepted value. GL.INVALID_OPERATION is generated if index is 0 and pname
+// is GL.CURRENT_VERTEX_ATTRIB.
+//
+// GetVertexAttribfv is available in GL version 2.0 or greater.
+func (gl *GL) GetVertexAttribfv(index glbase.Attrib, pname glbase.Enum, params []float32) {
+ var params_c [4]float32
+ C.gl2_0_glGetVertexAttribfv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetVertexAttribdv returns in params the value of a generic vertex attribute
+// parameter. The generic vertex attribute to be queried is specified by
+// index, and the parameter to be queried is specified by pname.
+//
+// The accepted parameter names are as follows:
+//
+// GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING
+// params returns a single value, the name of the buffer object
+// currently bound to the binding point corresponding to generic vertex
+// attribute array index. If no buffer object is bound, 0 is returned.
+// The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_ENABLED
+// params returns a single value that is non-zero (true) if the vertex
+// attribute array for index is enabled and 0 (false) if it is
+// disabled. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_SIZE
+// params returns a single value, the size of the vertex attribute
+// array for index. The size is the number of values for each element
+// of the vertex attribute array, and it will be 1, 2, 3, or 4. The
+// initial value is 4.
+//
+// GL.VERTEX_ATTRIB_ARRAY_STRIDE
+// params returns a single value, the array stride for (number of bytes
+// between successive elements in) the vertex attribute array for
+// index. A value of 0 indicates that the array elements are stored
+// sequentially in memory. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_TYPE
+// params returns a single value, a symbolic constant indicating the
+// array type for the vertex attribute array for index. Possible values
+// are GL.BYTE, GL.UNSIGNED_BYTE, GL.SHORT, GL.UNSIGNED_SHORT, GL.INT,
+// GL.UNSIGNED_INT, GL.FLOAT, and GL.DOUBLE. The initial value is
+// GL.FLOAT.
+//
+// GL.VERTEX_ATTRIB_ARRAY_NORMALIZED
+// params returns a single value that is non-zero (true) if fixed-point
+// data types for the vertex attribute array indicated by index are
+// normalized when they are converted to floating point, and 0 (false)
+// otherwise. The initial value is 0.
+//
+// GL.CURRENT_VERTEX_ATTRIB
+// params returns four values that represent the current value for the
+// generic vertex attribute specified by index. Generic vertex
+// attribute 0 is unique in that it has no current state, so an error
+// will be generated if index is 0. The initial value for all other
+// generic vertex attributes is (0,0,0,1).
+//
+// All of the parameters except GL.CURRENT_VERTEX_ATTRIB represent
+// client-side state.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_ENUM is generated if pname is not an
+// accepted value. GL.INVALID_OPERATION is generated if index is 0 and pname
+// is GL.CURRENT_VERTEX_ATTRIB.
+//
+// GetVertexAttribdv is available in GL version 2.0 or greater.
+func (gl *GL) GetVertexAttribdv(index glbase.Attrib, pname glbase.Enum, params []float64) {
+ var params_c [4]float64
+ C.gl2_0_glGetVertexAttribdv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetUniformiv returns in params the value of the specified uniform
+// variable. The type of the uniform variable specified by location
+// determines the number of values returned. If the uniform variable is
+// defined in the shader as a boolean, int, or float, a single value will be
+// returned. If it is defined as a vec2, ivec2, or bvec2, two values will be
+// returned. If it is defined as a vec3, ivec3, or bvec3, three values will
+// be returned, and so on. To query values stored in uniform variables
+// declared as arrays, call GetUniformiv for each element of the array. To
+// query values stored in uniform variables declared as structures, call
+// GetUniformiv for each field in the structure. The values for uniform
+// variables declared as a matrix will be returned in column major order.
+//
+// The locations assigned to uniform variables are not known until the
+// program object is linked. After linking has occurred, the command
+// GetUniformLocation can be used to obtain the location of a uniform
+// variable. This location value can then be passed to GetUniformiv in order
+// to query the current value of the uniform variable. After a program object
+// has been linked successfully, the index values for uniform variables
+// remain fixed until the next link command occurs. The uniform variable
+// values can only be queried after a link if the link was successful.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program
+// object. GL.INVALID_OPERATION is generated if program has not been
+// successfully linked. GL.INVALID_OPERATION is generated if location does
+// not correspond to a valid uniform variable location for the specified
+// program object. GL.INVALID_OPERATION is generated if GetUniformiv is
+// executed between the execution of Begin and the corresponding execution of
+// End.
+//
+// GetUniformiv is available in GL version 2.0 or greater.
+func (gl *GL) GetUniformiv(program glbase.Program, location glbase.Uniform, params []int32) {
+ var params_c [4]int32
+ C.gl2_0_glGetUniformiv(gl.funcs, C.GLuint(program), C.GLint(location), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetUniformfv returns in params the value of the specified uniform
+// variable. The type of the uniform variable specified by location
+// determines the number of values returned. If the uniform variable is
+// defined in the shader as a boolean, int, or float, a single value will be
+// returned. If it is defined as a vec2, ivec2, or bvec2, two values will be
+// returned. If it is defined as a vec3, ivec3, or bvec3, three values will
+// be returned, and so on. To query values stored in uniform variables
+// declared as arrays, call GetUniformfv for each element of the array. To
+// query values stored in uniform variables declared as structures, call
+// GetUniformfv for each field in the structure. The values for uniform
+// variables declared as a matrix will be returned in column major order.
+//
+// The locations assigned to uniform variables are not known until the
+// program object is linked. After linking has occurred, the command
+// GetUniformLocation can be used to obtain the location of a uniform
+// variable. This location value can then be passed to GetUniformfv in order
+// to query the current value of the uniform variable. After a program object
+// has been linked successfully, the index values for uniform variables
+// remain fixed until the next link command occurs. The uniform variable
+// values can only be queried after a link if the link was successful.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program
+// object. GL.INVALID_OPERATION is generated if program has not been
+// successfully linked. GL.INVALID_OPERATION is generated if location does
+// not correspond to a valid uniform variable location for the specified
+// program object. GL.INVALID_OPERATION is generated if GetUniformfv is
+// executed between the execution of Begin and the corresponding execution of
+// End.
+//
+// GetUniformfv is available in GL version 2.0 or greater.
+func (gl *GL) GetUniformfv(program glbase.Program, location glbase.Uniform, params []float32) {
+ var params_c [4]float32
+ C.gl2_0_glGetUniformfv(gl.funcs, C.GLuint(program), C.GLint(location), (*C.GLfloat)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetUniformLocation returns an integer that represents the location of a
+// specific uniform variable within a program object. name must be an active
+// uniform variable name in program that is not a structure, an array of
+// structures, or a subcomponent of a vector or a matrix. This function
+// returns -1 if name does not correspond to an active uniform variable in
+// program or if name starts with the reserved prefix "gl_".
+//
+// Uniform variables that are structures or arrays of structures may be
+// queried by calling GetUniformLocation for each field within the
+// structure. The array element operator "[]" and the structure field
+// operator "." may be used in name in order to select elements within an
+// array or fields within a structure. The result of using these operators is
+// not allowed to be another structure, an array of structures, or a
+// subcomponent of a vector or a matrix. Except if the last part of name
+// indicates a uniform variable array, the location of the first element of
+// an array can be retrieved by using the name of the array, or by using the
+// name appended by "[0]".
+//
+// The actual locations assigned to uniform variables are not known until the
+// program object is linked successfully. After linking has occurred, the
+// command GetUniformLocation can be used to obtain the location of a
+// uniform variable. This location value can then be passed to Uniform to
+// set the value of the uniform variable or to GetUniform in order to query
+// the current value of the uniform variable. After a program object has been
+// linked successfully, the index values for uniform variables remain fixed
+// until the next link command occurs. Uniform variable locations and values
+// can only be queried after a link if the link was successful.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program object.
+// GL.INVALID_OPERATION is generated if program has not been successfully
+// linked. GL.INVALID_OPERATION is generated if GetUniformLocation is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// GetUniformLocation is available in GL version 2.0 or greater.
+func (gl *GL) GetUniformLocation(program glbase.Program, name string) glbase.Uniform {
+ name_cstr := C.CString(name)
+ glresult := C.gl2_0_glGetUniformLocation(gl.funcs, C.GLuint(program), (*C.GLchar)(name_cstr))
+ C.free(unsafe.Pointer(name_cstr))
+ return glbase.Uniform(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetShaderSource.xml
+func (gl *GL) GetShaderSource(shader glbase.Shader, bufSize int32, length []int32, source []byte) {
+ C.gl2_0_glGetShaderSource(gl.funcs, C.GLuint(shader), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&source[0])))
+}
+
+// GetShaderInfoLog returns the information log for the specified shader
+// object. The information log for a shader object is modified when the
+// shader is compiled.
+//
+// The information log for a shader object is a string that may contain
+// diagnostic messages, warning messages, and other information about the
+// last compile operation. When a shader object is created, its information
+// log will be a string of length 0, and the size of the current log can be
+// obtained by calling GetShaderiv with the value GL.INFO_LOG_LENGTH.
+//
+// The information log for a shader object is the OpenGL implementer's
+// primary mechanism for conveying information about the compilation process.
+// Therefore, the information log can be helpful to application developers
+// during the development process, even when compilation is successful.
+// Application developers should not expect different OpenGL implementations
+// to produce identical information logs.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader is not a shader
+// object. GL.INVALID_VALUE is generated if maxLength is less than 0.
+// GL.INVALID_OPERATION is generated if GetShaderInfoLog is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// GetShaderInfoLog is available in GL version 2.0 or greater.
+func (gl *GL) GetShaderInfoLog(shader glbase.Shader) []byte {
+ var params [1]int32
+ var length int32
+ gl.GetShaderiv(shader, INFO_LOG_LENGTH, params[:])
+ bufSize := params[0]
+ infoLog := make([]byte, int(bufSize))
+ C.gl2_0_glGetShaderInfoLog(gl.funcs, C.GLuint(shader), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length)), (*C.GLchar)(unsafe.Pointer(&infoLog[0])))
+ return infoLog
+}
+
+// GetShaderiv GetShader returns in params the value of a parameter for a specific
+// shader object. The following parameters are defined:
+//
+// GL.SHADER_TYPE
+// params returns GL.VERTEX_SHADER if shader is a vertex shader object,
+// and GL.FRAGMENT_SHADER if shader is a fragment shader object.
+//
+// GL.DELETE_STATUS
+// params returns GL.TRUE if shader is currently flagged for deletion,
+// and GL.FALSE otherwise.
+//
+// GL.COMPILE_STATUS
+// params returns GL.TRUE if the last compile operation on shader was
+// successful, and GL.FALSE otherwise.
+//
+// GL.INFO_LOG_LENGTH
+// params returns the number of characters in the information log for
+// shader including the null termination character (the size of the
+// character buffer required to store the information log). If shader has
+// no information log, a value of 0 is returned.
+//
+// GL.SHADER_SOURCE_LENGTH
+// params returns the length of the concatenation of the source strings
+// that make up the shader source for the shader, including the null
+// termination character. (the size of the character buffer
+// required to store the shader source). If no source code exists, 0 is
+// returned.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader does not refer to a
+// shader object. GL.INVALID_ENUM is generated if pname is not an accepted
+// value. GL.INVALID_OPERATION is generated if GetShader is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// GetShaderiv is available in GL version 2.0 or greater.
+func (gl *GL) GetShaderiv(shader glbase.Shader, pname glbase.Enum, params []int32) {
+ var params_c [4]int32
+ C.gl2_0_glGetShaderiv(gl.funcs, C.GLuint(shader), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetProgramInfoLog returns the information log for the specified program
+// object. The information log for a program object is modified when the
+// program object is linked or validated.
+//
+// The information log for a program object is either an empty string, or a
+// string containing information about the last link operation, or a string
+// containing information about the last validation operation. It may contain
+// diagnostic messages, warning messages, and other information. When a
+// program object is created, its information log will be a string of length
+// 0, and the size of the current log can be obtained by calling GetProgramiv
+// with the value GL.INFO_LOG_LENGTH.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated
+// by OpenGL. GL.INVALID_OPERATION is generated if program is not a
+// program object.
+func (gl *GL) GetProgramInfoLog(program glbase.Program) []byte {
+ var params [1]int32
+ var length int32
+ gl.GetProgramiv(program, INFO_LOG_LENGTH, params[:])
+ bufSize := params[0]
+ infoLog := make([]byte, int(bufSize))
+ C.gl2_0_glGetProgramInfoLog(gl.funcs, C.GLuint(program), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length)), (*C.GLchar)(unsafe.Pointer(&infoLog[0])))
+ return infoLog
+}
+
+// GetProgramiv returns in params the value of a parameter for a specific
+// program object. The following parameters are defined:
+//
+// GL.DELETE_STATUS
+// params returns GL.TRUE if program is currently flagged for deletion,
+// and GL.FALSE otherwise.
+//
+// GL.LINK_STATUS
+// params returns GL.TRUE if the last link operation on program was
+// successful, and GL.FALSE otherwise.
+//
+// GL.VALIDATE_STATUS
+// params returns GL.TRUE or if the last validation operation on
+// program was successful, and GL.FALSE otherwise.
+//
+// GL.INFO_LOG_LENGTH
+// params returns the number of characters in the information log for
+// program including the null termination character (the size of
+// the character buffer required to store the information log). If
+// program has no information log, a value of 0 is returned.
+//
+// GL.ATTACHED_SHADERS
+// params returns the number of shader objects attached to program.
+//
+// GL.ACTIVE_ATTRIBUTES
+// params returns the number of active attribute variables for program.
+//
+// GL.ACTIVE_ATTRIBUTE_MAX_LENGTH
+// params returns the length of the longest active attribute name for
+// program, including the null termination character (the size of
+// the character buffer required to store the longest attribute name).
+// If no active attributes exist, 0 is returned.
+//
+// GL.ACTIVE_UNIFORMS
+// params returns the number of active uniform variables for program.
+//
+// GL.ACTIVE_UNIFORM_MAX_LENGTH
+// params returns the length of the longest active uniform variable
+// name for program, including the null termination character (i.e.,
+// the size of the character buffer required to store the longest
+// uniform variable name). If no active uniform variables exist, 0 is
+// returned.
+//
+// GL.TRANSFORM_FEEDBACK_BUFFER_MODE
+// params returns a symbolic constant indicating the buffer mode used
+// when transform feedback is active. This may be GL.SEPARATE_ATTRIBS
+// or GL.INTERLEAVED_ATTRIBS.
+//
+// GL.TRANSFORM_FEEDBACK_VARYINGS
+// params returns the number of varying variables to capture in transform
+// feedback mode for the program.
+//
+// GL.TRANSFORM_FEEDBACK_VARYING_MAX_LENGTH
+// params returns the length of the longest variable name to be used for
+// transform feedback, including the null-terminator.
+//
+// GL.GEOMETRY_VERTICES_OUT
+// params returns the maximum number of vertices that the geometry shader in
+// program will output.
+//
+// GL.GEOMETRY_INPUT_TYPE
+// params returns a symbolic constant indicating the primitive type accepted
+// as input to the geometry shader contained in program.
+//
+// GL.GEOMETRY_OUTPUT_TYPE
+// params returns a symbolic constant indicating the primitive type that will
+// be output by the geometry shader contained in program.
+//
+// GL.ACTIVE_UNIFORM_BLOCKS and GL.ACTIVE_UNIFORM_BLOCK_MAX_NAME_LENGTH are
+// available only if the GL version 3.1 or greater.
+//
+// GL.GEOMETRY_VERTICES_OUT, GL.GEOMETRY_INPUT_TYPE and
+// GL.GEOMETRY_OUTPUT_TYPE are accepted only if the GL version is 3.2 or
+// greater.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program does not refer to a
+// program object. GL.INVALID_OPERATION is generated if pname is
+// GL.GEOMETRY_VERTICES_OUT, GL.GEOMETRY_INPUT_TYPE, or
+// GL.GEOMETRY_OUTPUT_TYPE, and program does not contain a geometry shader.
+// GL.INVALID_ENUM is generated if pname is not an accepted value.
+func (gl *GL) GetProgramiv(program glbase.Program, pname glbase.Enum, params []int32) {
+ var params_c [4]int32
+ C.gl2_0_glGetProgramiv(gl.funcs, C.GLuint(program), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetAttribLocation queries the previously linked program object specified
+// by program for the attribute variable specified by name and returns the
+// index of the generic vertex attribute that is bound to that attribute
+// variable. If name is a matrix attribute variable, the index of the first
+// column of the matrix is returned. If the named attribute variable is not
+// an active attribute in the specified program object or if name starts with
+// the reserved prefix "gl_", a value of -1 is returned.
+//
+// The association between an attribute variable name and a generic attribute
+// index can be specified at any time by calling BindAttribLocation.
+// Attribute bindings do not go into effect until LinkProgram is called.
+// After a program object has been linked successfully, the index values for
+// attribute variables remain fixed until the next link command occurs. The
+// attribute values can only be queried after a link if the link was
+// successful. GetAttribLocation returns the binding that actually went
+// into effect the last time LinkProgram was called for the specified
+// program object. Attribute bindings that have been specified since the last
+// link operation are not returned by GetAttribLocation.
+//
+// Error GL_INVALID_OPERATION is generated if program is not a value
+// generated by OpenGL. GL_INVALID_OPERATION is generated if program is not
+// a program object. GL_INVALID_OPERATION is generated if program has not
+// been successfully linked. GL_INVALID_OPERATION is generated if
+// GetAttribLocation is executed between the execution of Begin and the
+// corresponding execution of End.
+//
+// GetAttribLocation is available in GL version 2.0 or greater.
+func (gl *GL) GetAttribLocation(program glbase.Program, name string) glbase.Attrib {
+ name_cstr := C.CString(name)
+ glresult := C.gl2_0_glGetAttribLocation(gl.funcs, C.GLuint(program), (*C.GLchar)(name_cstr))
+ C.free(unsafe.Pointer(name_cstr))
+ return glbase.Attrib(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetAttachedShaders.xml
+func (gl *GL) GetAttachedShaders(program glbase.Program, maxCount int32, count []int, obj []uint32) {
+ C.gl2_0_glGetAttachedShaders(gl.funcs, C.GLuint(program), C.GLsizei(maxCount), (*C.GLsizei)(unsafe.Pointer(&count[0])), (*C.GLuint)(unsafe.Pointer(&obj[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetActiveUniform.xml
+func (gl *GL) GetActiveUniform(program glbase.Program, index uint32, bufSize int32, length []int32, size []int, gltype []glbase.Enum, name []byte) {
+ C.gl2_0_glGetActiveUniform(gl.funcs, C.GLuint(program), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLint)(unsafe.Pointer(&size[0])), (*C.GLenum)(unsafe.Pointer(&gltype[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetActiveAttrib.xml
+func (gl *GL) GetActiveAttrib(program glbase.Program, index glbase.Attrib, bufSize int32, length []int32, size []int, gltype []glbase.Enum, name []byte) {
+ C.gl2_0_glGetActiveAttrib(gl.funcs, C.GLuint(program), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLint)(unsafe.Pointer(&size[0])), (*C.GLenum)(unsafe.Pointer(&gltype[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEnableVertexAttribArray.xml
+func (gl *GL) EnableVertexAttribArray(index glbase.Attrib) {
+ C.gl2_0_glEnableVertexAttribArray(gl.funcs, C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDisableVertexAttribArray.xml
+func (gl *GL) DisableVertexAttribArray(index glbase.Attrib) {
+ C.gl2_0_glDisableVertexAttribArray(gl.funcs, C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDetachShader.xml
+func (gl *GL) DetachShader(program glbase.Program, shader glbase.Shader) {
+ C.gl2_0_glDetachShader(gl.funcs, C.GLuint(program), C.GLuint(shader))
+}
+
+// DeleteShader frees the memory and invalidates the name associated with
+// the shader object specified by shader. This command effectively undoes the
+// effects of a call to CreateShader.
+//
+// If a shader object to be deleted is attached to a program object, it will
+// be flagged for deletion, but it will not be deleted until it is no longer
+// attached to any program object, for any rendering context (it must
+// be detached from wherever it was attached before it will be deleted). A
+// value of 0 for shader will be silently ignored.
+//
+// To determine whether an object has been flagged for deletion, call
+// GetShader with arguments shader and GL.DELETE_STATUS.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL.
+//
+// DeleteShader is available in GL version 2.0 or greater.
+func (gl *GL) DeleteShader(shader glbase.Shader) {
+ C.gl2_0_glDeleteShader(gl.funcs, C.GLuint(shader))
+}
+
+// DeleteProgram frees the memory and invalidates the name associated with
+// the program object specified by program. This command effectively undoes
+// the effects of a call to CreateProgram.
+//
+// If a program object is in use as part of current rendering state, it will
+// be flagged for deletion, but it will not be deleted until it is no longer
+// part of current state for any rendering context. If a program object to be
+// deleted has shader objects attached to it, those shader objects will be
+// automatically detached but not deleted unless they have already been
+// flagged for deletion by a previous call to DeleteShader. A value of 0
+// for program will be silently ignored.
+//
+// To determine whether a program object has been flagged for deletion, call
+// GetProgram with arguments program and GL.DELETE_STATUS.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL.
+//
+// DeleteProgram is available in GL version 2.0 or greater.
+func (gl *GL) DeleteProgram(program glbase.Program) {
+ C.gl2_0_glDeleteProgram(gl.funcs, C.GLuint(program))
+}
+
+// CreateShader creates an empty shader object and returns a non-zero value
+// by which it can be referenced. A shader object is used to maintain the
+// source code strings that define a shader. shaderType indicates the type of
+// shader to be created.
+//
+// Two types of shaders are supported. A shader of type GL.VERTEX_SHADER is a
+// shader that is intended to run on the programmable vertex processor and
+// replace the fixed functionality vertex processing in OpenGL. A shader of
+// type GL.FRAGMENT_SHADER is a shader that is intended to run on the
+// programmable fragment processor and replace the fixed functionality
+// fragment processing in OpenGL.
+//
+// When created, a shader object's GL.SHADER_TYPE parameter is set to either
+// GL.VERTEX_SHADER or GL.FRAGMENT_SHADER, depending on the value of
+// shaderType.
+//
+// Like display lists and texture objects, the name space for shader objects
+// may be shared across a set of contexts, as long as the server sides of the
+// contexts share the same address space. If the name space is shared across
+// contexts, any attached objects and the data associated with those attached
+// objects are shared as well.
+//
+// This function returns 0 if an error occurs creating the shader object.
+//
+// Error GL.INVALID_ENUM is generated if shaderType is not an accepted value.
+// GL.INVALID_OPERATION is generated if CreateShader is executed between the
+// execution of Begin and the corresponding execution of End.
+//
+// CreateShader is available in GL version 2.0 or greater.
+func (gl *GL) CreateShader(gltype glbase.Enum) glbase.Shader {
+ glresult := C.gl2_0_glCreateShader(gl.funcs, C.GLenum(gltype))
+ return glbase.Shader(glresult)
+}
+
+// CreateProgram creates an empty program object and returns a non-zero
+// value by which it can be referenced. A program object is an object to
+// which shader objects can be attached. This provides a mechanism to specify
+// the shader objects that will be linked to create a program. It also
+// provides a means for checking the compatibility of the shaders that will
+// be used to create a program (for instance, checking the compatibility
+// between a vertex shader and a fragment shader). When no longer needed as
+// part of a program object, shader objects can be detached.
+//
+// One or more executables are created in a program object by successfully
+// attaching shader objects to it with AttachShader, successfully compiling
+// the shader objects with CompileShader, and successfully linking the
+// program object with LinkProgram. These executables are made part of
+// current state when UseProgram is called. Program objects can be deleted
+// by calling DeleteProgram. The memory associated with the program object
+// will be deleted when it is no longer part of current rendering state for
+// any context.
+//
+// Like display lists and texture objects, the name space for program objects
+// may be shared across a set of contexts, as long as the server sides of the
+// contexts share the same address space. If the name space is shared across
+// contexts, any attached objects and the data associated with those attached
+// objects are shared as well.
+//
+// Applications are responsible for providing the synchronization across API
+// calls when objects are accessed from different execution threads.
+//
+// This function returns 0 if an error occurs creating the program object.
+//
+// Error GL.INVALID_OPERATION is generated if CreateProgram is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// CreateProgram is available in GL version 2.0 or greater.
+func (gl *GL) CreateProgram() glbase.Program {
+ glresult := C.gl2_0_glCreateProgram(gl.funcs)
+ return glbase.Program(glresult)
+}
+
+// CompileShader compiles the source code strings that have been stored in
+// the shader object specified by shader.
+//
+// The compilation status will be stored as part of the shader object's
+// state. This value will be set to GL.TRUE if the shader was compiled without
+// errors and is ready for use, and GL.FALSE otherwise. It can be queried by
+// calling GetShaderiv with arguments shader and GL.COMPILE_STATUS.
+//
+// Compilation of a shader can fail for a number of reasons as specified by
+// the OpenGL Shading Language Specification. Whether or not the compilation
+// was successful, information about the compilation can be obtained from the
+// shader object's information log by calling GetShaderInfoLog.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader is not a shader
+// object. GL.INVALID_OPERATION is generated if CompileShader is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// CompileShader is available in GL version 2.0 or greater.
+func (gl *GL) CompileShader(shader glbase.Shader) {
+ C.gl2_0_glCompileShader(gl.funcs, C.GLuint(shader))
+}
+
+// BindAttribLocation associates a user-defined attribute variable in the program
+// object specified by program with a generic vertex attribute index. The name
+// parameter specifies the name of the vertex shader attribute variable to
+// which index is to be bound. When program is made part of the current state,
+// values provided via the generic vertex attribute index will modify the
+// value of the user-defined attribute variable specified by name.
+//
+// If name refers to a matrix attribute variable, index refers to the first
+// column of the matrix. Other matrix columns are then automatically bound to
+// locations index+1 for a matrix of type mat2; index+1 and index+2 for a
+// matrix of type mat3; and index+1, index+2, and index+3 for a matrix of
+// type mat4.
+//
+// This command makes it possible for vertex shaders to use descriptive names
+// for attribute variables rather than generic variables that are numbered
+// from 0 to GL.MAX_VERTEX_ATTRIBS-1. The values sent to each generic
+// attribute index are part of current state, just like standard vertex
+// attributes such as color, normal, and vertex position. If a different
+// program object is made current by calling UseProgram, the generic vertex
+// attributes are tracked in such a way that the same values will be observed
+// by attributes in the new program object that are also bound to index.
+//
+// Attribute variable name-to-generic attribute index bindings for a program
+// object can be explicitly assigned at any time by calling
+// BindAttribLocation. Attribute bindings do not go into effect until
+// LinkProgram is called. After a program object has been linked
+// successfully, the index values for generic attributes remain fixed (and
+// their values can be queried) until the next link command occurs.
+//
+// Applications are not allowed to bind any of the standard OpenGL vertex
+// attributes using this command, as they are bound automatically when
+// needed. Any attribute binding that occurs after the program object has
+// been linked will not take effect until the next time the program object is
+// linked.
+//
+// If name was bound previously, that information is lost. Thus you cannot
+// bind one user-defined attribute variable to multiple indices, but you can
+// bind multiple user-defined attribute variables to the same index.
+//
+// Applications are allowed to bind more than one user-defined attribute
+// variable to the same generic vertex attribute index. This is called
+// aliasing, and it is allowed only if just one of the aliased attributes is
+// active in the executable program, or if no path through the shader
+// consumes more than one attribute of a set of attributes aliased to the
+// same location. The compiler and linker are allowed to assume that no
+// aliasing is done and are free to employ optimizations that work only in
+// the absence of aliasing. OpenGL implementations are not required to do
+// error checking to detect aliasing. Because there is no way to bind
+// standard attributes, it is not possible to alias generic attributes with
+// conventional ones (except for generic attribute 0).
+//
+// BindAttribLocation can be called before any vertex shader objects are
+// bound to the specified program object. It is also permissible to bind a
+// generic attribute index to an attribute variable name that is never used
+// in a vertex shader.
+//
+// Active attributes that are not explicitly bound will be bound by the
+// linker when LinkProgram is called. The locations assigned can be queried
+// by calling GetAttribLocation.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS.
+// GL.INVALID_OPERATION is generated if name starts with the reserved prefix "gl_".
+// GL.INVALID_VALUE is generated if program is not a value generated by OpenGL.
+// GL.INVALID_OPERATION is generated if program is not a program object.
+// GL.INVALID_OPERATION is generated if BindAttribLocation is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// BindAttribLocation is available in GL version 2.0 or greater.
+func (gl *GL) BindAttribLocation(program glbase.Program, index glbase.Attrib, name string) {
+ name_cstr := C.CString(name)
+ C.gl2_0_glBindAttribLocation(gl.funcs, C.GLuint(program), C.GLuint(index), (*C.GLchar)(name_cstr))
+ C.free(unsafe.Pointer(name_cstr))
+}
+
+// AttachShader attaches a shader object to a program object.
+//
+// In order to create an executable, there must be a way to specify the list
+// of things that will be linked together. Program objects provide this
+// mechanism. Shaders that are to be linked together in a program object must
+// first be attached to that program object. This indicates that shader will
+// be included in link operations that will be performed on program.
+//
+// All operations that can be performed on a shader object are valid whether
+// or not the shader object is attached to a program object. It is
+// permissible to attach a shader object to a program object before source
+// code has been loaded into the shader object or before the shader object
+// has been compiled. It is permissible to attach multiple shader objects of
+// the same type because each may contain a portion of the complete shader.
+// It is also permissible to attach a shader object to more than one program
+// object. If a shader object is deleted while it is attached to a program
+// object, it will be flagged for deletion, and deletion will not occur until
+// DetachShader is called to detach it from all program objects to which it
+// is attached.
+//
+// Error GL.INVALID_VALUE is generated if either program or shader is not a
+// value generated by OpenGL. GL.INVALID_OPERATION is generated if program
+// is not a program object. GL.INVALID_OPERATION is generated if shader is
+// not a shader object. GL.INVALID_OPERATION is generated if shader is
+// already attached to program. GL.INVALID_OPERATION is generated if
+// AttachShader is executed between the execution of Begin and the
+// corresponding execution of End.
+//
+// AttachShader is available in GL version 2.0 or greater.
+func (gl *GL) AttachShader(program glbase.Program, shader glbase.Shader) {
+ C.gl2_0_glAttachShader(gl.funcs, C.GLuint(program), C.GLuint(shader))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glStencilMaskSeparate.xml
+func (gl *GL) StencilMaskSeparate(face glbase.Enum, mask uint32) {
+ C.gl2_0_glStencilMaskSeparate(gl.funcs, C.GLenum(face), C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glStencilFuncSeparate.xml
+func (gl *GL) StencilFuncSeparate(face, glfunc glbase.Enum, ref int32, mask uint32) {
+ C.gl2_0_glStencilFuncSeparate(gl.funcs, C.GLenum(face), C.GLenum(glfunc), C.GLint(ref), C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glStencilOpSeparate.xml
+func (gl *GL) StencilOpSeparate(face, sfail, dpfail, dppass glbase.Enum) {
+ C.gl2_0_glStencilOpSeparate(gl.funcs, C.GLenum(face), C.GLenum(sfail), C.GLenum(dpfail), C.GLenum(dppass))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDrawBuffers.xml
+func (gl *GL) DrawBuffers(n int, bufs []glbase.Enum) {
+ C.gl2_0_glDrawBuffers(gl.funcs, C.GLsizei(n), (*C.GLenum)(unsafe.Pointer(&bufs[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBlendEquationSeparate.xml
+func (gl *GL) BlendEquationSeparate(modeRGB, modeAlpha glbase.Enum) {
+ C.gl2_0_glBlendEquationSeparate(gl.funcs, C.GLenum(modeRGB), C.GLenum(modeAlpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTranslatef.xml
+func (gl *GL) Translatef(x, y, z float32) {
+ C.gl2_0_glTranslatef(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTranslated.xml
+func (gl *GL) Translated(x, y, z float64) {
+ C.gl2_0_glTranslated(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glScalef.xml
+func (gl *GL) Scalef(x, y, z float32) {
+ C.gl2_0_glScalef(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glScaled.xml
+func (gl *GL) Scaled(x, y, z float64) {
+ C.gl2_0_glScaled(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRotatef.xml
+func (gl *GL) Rotatef(angle, x, y, z float32) {
+ C.gl2_0_glRotatef(gl.funcs, C.GLfloat(angle), C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRotated.xml
+func (gl *GL) Rotated(angle, x, y, z float64) {
+ C.gl2_0_glRotated(gl.funcs, C.GLdouble(angle), C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPushMatrix.xml
+func (gl *GL) PushMatrix() {
+ C.gl2_0_glPushMatrix(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPopMatrix.xml
+func (gl *GL) PopMatrix() {
+ C.gl2_0_glPopMatrix(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glOrtho.xml
+func (gl *GL) Ortho(left, right, bottom, top, zNear, zFar float64) {
+ C.gl2_0_glOrtho(gl.funcs, C.GLdouble(left), C.GLdouble(right), C.GLdouble(bottom), C.GLdouble(top), C.GLdouble(zNear), C.GLdouble(zFar))
+}
+
+// MultMatrixd multiplies the current matrix with the provided matrix.
+//
+// The m parameter must hold 16 consecutive elements of a 4x4 column-major matrix.
+//
+// The current matrix is determined by the current matrix mode (see
+// MatrixMode). It is either the projection matrix, modelview matrix, or the
+// texture matrix.
+//
+// For example, if the current matrix is C and the coordinates to be transformed
+// are v = (v[0], v[1], v[2], v[3]), then the current transformation is C × v, or
+//
+// c[0] c[4] c[8] c[12] v[0]
+// c[1] c[5] c[9] c[13] v[1]
+// c[2] c[6] c[10] c[14] X v[2]
+// c[3] c[7] c[11] c[15] v[3]
+//
+// Calling MultMatrix with an argument of m = m[0], m[1], ..., m[15]
+// replaces the current transformation with (C X M) x v, or
+//
+// c[0] c[4] c[8] c[12] m[0] m[4] m[8] m[12] v[0]
+// c[1] c[5] c[9] c[13] m[1] m[5] m[9] m[13] v[1]
+// c[2] c[6] c[10] c[14] X m[2] m[6] m[10] m[14] X v[2]
+// c[3] c[7] c[11] c[15] m[3] m[7] m[11] m[15] v[3]
+//
+// Where 'X' denotes matrix multiplication, and v is represented as a 4x1 matrix.
+//
+// While the elements of the matrix may be specified with single or double
+// precision, the GL may store or operate on these values in less-than-single
+// precision.
+//
+// In many computer languages, 4×4 arrays are represented in row-major
+// order. The transformations just described represent these matrices in
+// column-major order. The order of the multiplication is important. For
+// example, if the current transformation is a rotation, and MultMatrix is
+// called with a translation matrix, the translation is done directly on the
+// coordinates to be transformed, while the rotation is done on the results
+// of that translation.
+//
+// GL.INVALID_OPERATION is generated if MultMatrix is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) MultMatrixd(m []float64) {
+ if len(m) != 16 {
+ panic("parameter m must have length 16 for the 4x4 matrix")
+ }
+ C.gl2_0_glMultMatrixd(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&m[0])))
+}
+
+// MultMatrixf multiplies the current matrix with the provided matrix.
+//
+// The m parameter must hold 16 consecutive elements of a 4x4 column-major matrix.
+//
+// The current matrix is determined by the current matrix mode (see
+// MatrixMode). It is either the projection matrix, modelview matrix, or the
+// texture matrix.
+//
+// For example, if the current matrix is C and the coordinates to be transformed
+// are v = (v[0], v[1], v[2], v[3]), then the current transformation is C × v, or
+//
+// c[0] c[4] c[8] c[12] v[0]
+// c[1] c[5] c[9] c[13] v[1]
+// c[2] c[6] c[10] c[14] X v[2]
+// c[3] c[7] c[11] c[15] v[3]
+//
+// Calling MultMatrix with an argument of m = m[0], m[1], ..., m[15]
+// replaces the current transformation with (C X M) x v, or
+//
+// c[0] c[4] c[8] c[12] m[0] m[4] m[8] m[12] v[0]
+// c[1] c[5] c[9] c[13] m[1] m[5] m[9] m[13] v[1]
+// c[2] c[6] c[10] c[14] X m[2] m[6] m[10] m[14] X v[2]
+// c[3] c[7] c[11] c[15] m[3] m[7] m[11] m[15] v[3]
+//
+// Where 'X' denotes matrix multiplication, and v is represented as a 4x1 matrix.
+//
+// While the elements of the matrix may be specified with single or double
+// precision, the GL may store or operate on these values in less-than-single
+// precision.
+//
+// In many computer languages, 4×4 arrays are represented in row-major
+// order. The transformations just described represent these matrices in
+// column-major order. The order of the multiplication is important. For
+// example, if the current transformation is a rotation, and MultMatrix is
+// called with a translation matrix, the translation is done directly on the
+// coordinates to be transformed, while the rotation is done on the results
+// of that translation.
+//
+// GL.INVALID_OPERATION is generated if MultMatrix is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) MultMatrixf(m []float32) {
+ if len(m) != 16 {
+ panic("parameter m must have length 16 for the 4x4 matrix")
+ }
+ C.gl2_0_glMultMatrixf(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMatrixMode.xml
+func (gl *GL) MatrixMode(mode glbase.Enum) {
+ C.gl2_0_glMatrixMode(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLoadMatrixd.xml
+func (gl *GL) LoadMatrixd(m []float64) {
+ C.gl2_0_glLoadMatrixd(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLoadMatrixf.xml
+func (gl *GL) LoadMatrixf(m []float32) {
+ C.gl2_0_glLoadMatrixf(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLoadIdentity.xml
+func (gl *GL) LoadIdentity() {
+ C.gl2_0_glLoadIdentity(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFrustum.xml
+func (gl *GL) Frustum(left, right, bottom, top, zNear, zFar float64) {
+ C.gl2_0_glFrustum(gl.funcs, C.GLdouble(left), C.GLdouble(right), C.GLdouble(bottom), C.GLdouble(top), C.GLdouble(zNear), C.GLdouble(zFar))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIsList.xml
+func (gl *GL) IsList(list uint32) bool {
+ glresult := C.gl2_0_glIsList(gl.funcs, C.GLuint(list))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexGeniv.xml
+func (gl *GL) GetTexGeniv(coord, pname glbase.Enum, params []int32) {
+ C.gl2_0_glGetTexGeniv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexGenfv.xml
+func (gl *GL) GetTexGenfv(coord, pname glbase.Enum, params []float32) {
+ C.gl2_0_glGetTexGenfv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexGendv.xml
+func (gl *GL) GetTexGendv(coord, pname glbase.Enum, params []float64) {
+ C.gl2_0_glGetTexGendv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexEnviv.xml
+func (gl *GL) GetTexEnviv(target, pname glbase.Enum, params []int32) {
+ C.gl2_0_glGetTexEnviv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexEnvfv.xml
+func (gl *GL) GetTexEnvfv(target, pname glbase.Enum, params []float32) {
+ C.gl2_0_glGetTexEnvfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetPolygonStipple.xml
+func (gl *GL) GetPolygonStipple(mask []uint8) {
+ C.gl2_0_glGetPolygonStipple(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&mask[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetPixelMapusv.xml
+func (gl *GL) GetPixelMapusv(glmap glbase.Enum, values []uint16) {
+ C.gl2_0_glGetPixelMapusv(gl.funcs, C.GLenum(glmap), (*C.GLushort)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetPixelMapuiv.xml
+func (gl *GL) GetPixelMapuiv(glmap glbase.Enum, values []uint32) {
+ C.gl2_0_glGetPixelMapuiv(gl.funcs, C.GLenum(glmap), (*C.GLuint)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetPixelMapfv.xml
+func (gl *GL) GetPixelMapfv(glmap glbase.Enum, values []float32) {
+ C.gl2_0_glGetPixelMapfv(gl.funcs, C.GLenum(glmap), (*C.GLfloat)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetMaterialiv.xml
+func (gl *GL) GetMaterialiv(face, pname glbase.Enum, params []int32) {
+ C.gl2_0_glGetMaterialiv(gl.funcs, C.GLenum(face), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetMaterialfv.xml
+func (gl *GL) GetMaterialfv(face, pname glbase.Enum, params []float32) {
+ C.gl2_0_glGetMaterialfv(gl.funcs, C.GLenum(face), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetMapiv.xml
+func (gl *GL) GetMapiv(target, query glbase.Enum, v []int32) {
+ C.gl2_0_glGetMapiv(gl.funcs, C.GLenum(target), C.GLenum(query), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetMapfv.xml
+func (gl *GL) GetMapfv(target, query glbase.Enum, v []float32) {
+ C.gl2_0_glGetMapfv(gl.funcs, C.GLenum(target), C.GLenum(query), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetMapdv.xml
+func (gl *GL) GetMapdv(target, query glbase.Enum, v []float64) {
+ C.gl2_0_glGetMapdv(gl.funcs, C.GLenum(target), C.GLenum(query), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetLightiv.xml
+func (gl *GL) GetLightiv(light, pname glbase.Enum, params []int32) {
+ C.gl2_0_glGetLightiv(gl.funcs, C.GLenum(light), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetLightfv.xml
+func (gl *GL) GetLightfv(light, pname glbase.Enum, params []float32) {
+ C.gl2_0_glGetLightfv(gl.funcs, C.GLenum(light), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetClipPlane.xml
+func (gl *GL) GetClipPlane(plane glbase.Enum, equation []float64) {
+ C.gl2_0_glGetClipPlane(gl.funcs, C.GLenum(plane), (*C.GLdouble)(unsafe.Pointer(&equation[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDrawPixels.xml
+func (gl *GL) DrawPixels(width, height int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_0_glDrawPixels(gl.funcs, C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyPixels.xml
+func (gl *GL) CopyPixels(x, y, width, height int, gltype glbase.Enum) {
+ C.gl2_0_glCopyPixels(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height), C.GLenum(gltype))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelMapusv.xml
+func (gl *GL) PixelMapusv(glmap glbase.Enum, mapsize int32, values []uint16) {
+ C.gl2_0_glPixelMapusv(gl.funcs, C.GLenum(glmap), C.GLint(mapsize), (*C.GLushort)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelMapuiv.xml
+func (gl *GL) PixelMapuiv(glmap glbase.Enum, mapsize int32, values []uint32) {
+ C.gl2_0_glPixelMapuiv(gl.funcs, C.GLenum(glmap), C.GLint(mapsize), (*C.GLuint)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelMapfv.xml
+func (gl *GL) PixelMapfv(glmap glbase.Enum, mapsize int32, values []float32) {
+ C.gl2_0_glPixelMapfv(gl.funcs, C.GLenum(glmap), C.GLint(mapsize), (*C.GLfloat)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelTransferi.xml
+func (gl *GL) PixelTransferi(pname glbase.Enum, param int32) {
+ C.gl2_0_glPixelTransferi(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelTransferf.xml
+func (gl *GL) PixelTransferf(pname glbase.Enum, param float32) {
+ C.gl2_0_glPixelTransferf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelZoom.xml
+func (gl *GL) PixelZoom(xfactor, yfactor float32) {
+ C.gl2_0_glPixelZoom(gl.funcs, C.GLfloat(xfactor), C.GLfloat(yfactor))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glAlphaFunc.xml
+func (gl *GL) AlphaFunc(glfunc glbase.Enum, ref float32) {
+ C.gl2_0_glAlphaFunc(gl.funcs, C.GLenum(glfunc), C.GLfloat(ref))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalPoint2.xml
+func (gl *GL) EvalPoint2(i, j int32) {
+ C.gl2_0_glEvalPoint2(gl.funcs, C.GLint(i), C.GLint(j))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalMesh2.xml
+func (gl *GL) EvalMesh2(mode glbase.Enum, i1, i2, j1, j2 int32) {
+ C.gl2_0_glEvalMesh2(gl.funcs, C.GLenum(mode), C.GLint(i1), C.GLint(i2), C.GLint(j1), C.GLint(j2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalPoint1.xml
+func (gl *GL) EvalPoint1(i int32) {
+ C.gl2_0_glEvalPoint1(gl.funcs, C.GLint(i))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalMesh1.xml
+func (gl *GL) EvalMesh1(mode glbase.Enum, i1, i2 int32) {
+ C.gl2_0_glEvalMesh1(gl.funcs, C.GLenum(mode), C.GLint(i1), C.GLint(i2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord2fv.xml
+func (gl *GL) EvalCoord2fv(u []float32) {
+ if len(u) != 2 {
+ panic("parameter u has incorrect length")
+ }
+ C.gl2_0_glEvalCoord2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&u[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord2f.xml
+func (gl *GL) EvalCoord2f(u, v float32) {
+ C.gl2_0_glEvalCoord2f(gl.funcs, C.GLfloat(u), C.GLfloat(v))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord2dv.xml
+func (gl *GL) EvalCoord2dv(u []float64) {
+ if len(u) != 2 {
+ panic("parameter u has incorrect length")
+ }
+ C.gl2_0_glEvalCoord2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&u[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord2d.xml
+func (gl *GL) EvalCoord2d(u, v float64) {
+ C.gl2_0_glEvalCoord2d(gl.funcs, C.GLdouble(u), C.GLdouble(v))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord1fv.xml
+func (gl *GL) EvalCoord1fv(u []float32) {
+ C.gl2_0_glEvalCoord1fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&u[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord1f.xml
+func (gl *GL) EvalCoord1f(u float32) {
+ C.gl2_0_glEvalCoord1f(gl.funcs, C.GLfloat(u))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord1dv.xml
+func (gl *GL) EvalCoord1dv(u []float64) {
+ C.gl2_0_glEvalCoord1dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&u[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord1d.xml
+func (gl *GL) EvalCoord1d(u float64) {
+ C.gl2_0_glEvalCoord1d(gl.funcs, C.GLdouble(u))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMapGrid2f.xml
+func (gl *GL) MapGrid2f(un int32, u1, u2 float32, vn int32, v1, v2 float32) {
+ C.gl2_0_glMapGrid2f(gl.funcs, C.GLint(un), C.GLfloat(u1), C.GLfloat(u2), C.GLint(vn), C.GLfloat(v1), C.GLfloat(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMapGrid2d.xml
+func (gl *GL) MapGrid2d(un int32, u1, u2 float64, vn int32, v1, v2 float64) {
+ C.gl2_0_glMapGrid2d(gl.funcs, C.GLint(un), C.GLdouble(u1), C.GLdouble(u2), C.GLint(vn), C.GLdouble(v1), C.GLdouble(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMapGrid1f.xml
+func (gl *GL) MapGrid1f(un int32, u1, u2 float32) {
+ C.gl2_0_glMapGrid1f(gl.funcs, C.GLint(un), C.GLfloat(u1), C.GLfloat(u2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMapGrid1d.xml
+func (gl *GL) MapGrid1d(un int32, u1, u2 float64) {
+ C.gl2_0_glMapGrid1d(gl.funcs, C.GLint(un), C.GLdouble(u1), C.GLdouble(u2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMap2f.xml
+func (gl *GL) Map2f(target glbase.Enum, u1, u2 float32, ustride, uorder int32, v1, v2 float32, vstride, vorder int32, points []float32) {
+ C.gl2_0_glMap2f(gl.funcs, C.GLenum(target), C.GLfloat(u1), C.GLfloat(u2), C.GLint(ustride), C.GLint(uorder), C.GLfloat(v1), C.GLfloat(v2), C.GLint(vstride), C.GLint(vorder), (*C.GLfloat)(unsafe.Pointer(&points[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMap2d.xml
+func (gl *GL) Map2d(target glbase.Enum, u1, u2 float64, ustride, uorder int32, v1, v2 float64, vstride, vorder int32, points []float64) {
+ C.gl2_0_glMap2d(gl.funcs, C.GLenum(target), C.GLdouble(u1), C.GLdouble(u2), C.GLint(ustride), C.GLint(uorder), C.GLdouble(v1), C.GLdouble(v2), C.GLint(vstride), C.GLint(vorder), (*C.GLdouble)(unsafe.Pointer(&points[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMap1f.xml
+func (gl *GL) Map1f(target glbase.Enum, u1, u2 float32, stride, order int, points []float32) {
+ C.gl2_0_glMap1f(gl.funcs, C.GLenum(target), C.GLfloat(u1), C.GLfloat(u2), C.GLint(stride), C.GLint(order), (*C.GLfloat)(unsafe.Pointer(&points[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMap1d.xml
+func (gl *GL) Map1d(target glbase.Enum, u1, u2 float64, stride, order int, points []float64) {
+ C.gl2_0_glMap1d(gl.funcs, C.GLenum(target), C.GLdouble(u1), C.GLdouble(u2), C.GLint(stride), C.GLint(order), (*C.GLdouble)(unsafe.Pointer(&points[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPushAttrib.xml
+func (gl *GL) PushAttrib(mask glbase.Bitfield) {
+ C.gl2_0_glPushAttrib(gl.funcs, C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPopAttrib.xml
+func (gl *GL) PopAttrib() {
+ C.gl2_0_glPopAttrib(gl.funcs)
+}
+
+// Accum executes an operation on the accumulation buffer.
+//
+// Parameter op defines the accumulation buffer operation (GL.ACCUM, GL.LOAD,
+// GL.ADD, GL.MULT, or GL.RETURN) and specifies how the value parameter is
+// used.
+//
+// The accumulation buffer is an extended-range color buffer. Images are not
+// rendered into it. Rather, images rendered into one of the color buffers
+// are added to the contents of the accumulation buffer after rendering.
+// Effects such as antialiasing (of points, lines, and polygons), motion
+// blur, and depth of field can be created by accumulating images generated
+// with different transformation matrices.
+//
+// Each pixel in the accumulation buffer consists of red, green, blue, and
+// alpha values. The number of bits per component in the accumulation buffer
+// depends on the implementation. You can examine this number by calling
+// GetIntegerv four times, with arguments GL.ACCUM_RED_BITS,
+// GL.ACCUM_GREEN_BITS, GL.ACCUM_BLUE_BITS, and GL.ACCUM_ALPHA_BITS.
+// Regardless of the number of bits per component, the range of values stored
+// by each component is (-1, 1). The accumulation buffer pixels are mapped
+// one-to-one with frame buffer pixels.
+//
+// All accumulation buffer operations are limited to the area of the current
+// scissor box and applied identically to the red, green, blue, and alpha
+// components of each pixel. If a Accum operation results in a value outside
+// the range (-1, 1), the contents of an accumulation buffer pixel component
+// are undefined.
+//
+// The operations are as follows:
+//
+// GL.ACCUM
+// Obtains R, G, B, and A values from the buffer currently selected for
+// reading (see ReadBuffer). Each component value is divided by 2 n -
+// 1 , where n is the number of bits allocated to each color component
+// in the currently selected buffer. The result is a floating-point
+// value in the range 0 1 , which is multiplied by value and added to
+// the corresponding pixel component in the accumulation buffer,
+// thereby updating the accumulation buffer.
+//
+// GL.LOAD
+// Similar to GL.ACCUM, except that the current value in the
+// accumulation buffer is not used in the calculation of the new value.
+// That is, the R, G, B, and A values from the currently selected
+// buffer are divided by 2 n - 1 , multiplied by value, and then stored
+// in the corresponding accumulation buffer cell, overwriting the
+// current value.
+//
+// GL.ADD
+// Adds value to each R, G, B, and A in the accumulation buffer.
+//
+// GL.MULT
+// Multiplies each R, G, B, and A in the accumulation buffer by value
+// and returns the scaled component to its corresponding accumulation
+// buffer location.
+//
+// GL.RETURN
+// Transfers accumulation buffer values to the color buffer or buffers
+// currently selected for writing. Each R, G, B, and A component is
+// multiplied by value, then multiplied by 2 n - 1 , clamped to the
+// range 0 2 n - 1 , and stored in the corresponding display buffer
+// cell. The only fragment operations that are applied to this transfer
+// are pixel ownership, scissor, dithering, and color writemasks.
+//
+// To clear the accumulation buffer, call ClearAccum with R, G, B, and A
+// values to set it to, then call Clear with the accumulation buffer
+// enabled.
+//
+// Error GL.INVALID_ENUM is generated if op is not an accepted value.
+// GL.INVALID_OPERATION is generated if there is no accumulation buffer.
+// GL.INVALID_OPERATION is generated if Accum is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) Accum(op glbase.Enum, value float32) {
+ C.gl2_0_glAccum(gl.funcs, C.GLenum(op), C.GLfloat(value))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexMask.xml
+func (gl *GL) IndexMask(mask uint32) {
+ C.gl2_0_glIndexMask(gl.funcs, C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClearIndex.xml
+func (gl *GL) ClearIndex(c float32) {
+ C.gl2_0_glClearIndex(gl.funcs, C.GLfloat(c))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClearAccum.xml
+func (gl *GL) ClearAccum(red, green, blue, alpha float32) {
+ C.gl2_0_glClearAccum(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPushName.xml
+func (gl *GL) PushName(name uint32) {
+ C.gl2_0_glPushName(gl.funcs, C.GLuint(name))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPopName.xml
+func (gl *GL) PopName() {
+ C.gl2_0_glPopName(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPassThrough.xml
+func (gl *GL) PassThrough(token float32) {
+ C.gl2_0_glPassThrough(gl.funcs, C.GLfloat(token))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLoadName.xml
+func (gl *GL) LoadName(name uint32) {
+ C.gl2_0_glLoadName(gl.funcs, C.GLuint(name))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glInitNames.xml
+func (gl *GL) InitNames() {
+ C.gl2_0_glInitNames(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRenderMode.xml
+func (gl *GL) RenderMode(mode glbase.Enum) int32 {
+ glresult := C.gl2_0_glRenderMode(gl.funcs, C.GLenum(mode))
+ return int32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSelectBuffer.xml
+func (gl *GL) SelectBuffer(size int, buffer []glbase.Buffer) {
+ C.gl2_0_glSelectBuffer(gl.funcs, C.GLsizei(size), (*C.GLuint)(unsafe.Pointer(&buffer[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFeedbackBuffer.xml
+func (gl *GL) FeedbackBuffer(size int, gltype glbase.Enum, buffer []float32) {
+ C.gl2_0_glFeedbackBuffer(gl.funcs, C.GLsizei(size), C.GLenum(gltype), (*C.GLfloat)(unsafe.Pointer(&buffer[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexGeniv.xml
+func (gl *GL) TexGeniv(coord, pname glbase.Enum, params []int32) {
+ C.gl2_0_glTexGeniv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexGeni.xml
+func (gl *GL) TexGeni(coord, pname glbase.Enum, param int32) {
+ C.gl2_0_glTexGeni(gl.funcs, C.GLenum(coord), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexGenfv.xml
+func (gl *GL) TexGenfv(coord, pname glbase.Enum, params []float32) {
+ C.gl2_0_glTexGenfv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexGenf.xml
+func (gl *GL) TexGenf(coord, pname glbase.Enum, param float32) {
+ C.gl2_0_glTexGenf(gl.funcs, C.GLenum(coord), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexGendv.xml
+func (gl *GL) TexGendv(coord, pname glbase.Enum, params []float64) {
+ C.gl2_0_glTexGendv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexGend.xml
+func (gl *GL) TexGend(coord, pname glbase.Enum, param float64) {
+ C.gl2_0_glTexGend(gl.funcs, C.GLenum(coord), C.GLenum(pname), C.GLdouble(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexEnviv.xml
+func (gl *GL) TexEnviv(target, pname glbase.Enum, params []int32) {
+ C.gl2_0_glTexEnviv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexEnvi.xml
+func (gl *GL) TexEnvi(target, pname glbase.Enum, param int32) {
+ C.gl2_0_glTexEnvi(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexEnvfv.xml
+func (gl *GL) TexEnvfv(target, pname glbase.Enum, params []float32) {
+ C.gl2_0_glTexEnvfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexEnvf.xml
+func (gl *GL) TexEnvf(target, pname glbase.Enum, param float32) {
+ C.gl2_0_glTexEnvf(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glShadeModel.xml
+func (gl *GL) ShadeModel(mode glbase.Enum) {
+ C.gl2_0_glShadeModel(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPolygonStipple.xml
+func (gl *GL) PolygonStipple(mask []uint8) {
+ C.gl2_0_glPolygonStipple(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&mask[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMaterialiv.xml
+func (gl *GL) Materialiv(face, pname glbase.Enum, params []int32) {
+ C.gl2_0_glMaterialiv(gl.funcs, C.GLenum(face), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMateriali.xml
+func (gl *GL) Materiali(face, pname glbase.Enum, param int32) {
+ C.gl2_0_glMateriali(gl.funcs, C.GLenum(face), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMaterialfv.xml
+func (gl *GL) Materialfv(face, pname glbase.Enum, params []float32) {
+ C.gl2_0_glMaterialfv(gl.funcs, C.GLenum(face), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMaterialf.xml
+func (gl *GL) Materialf(face, pname glbase.Enum, param float32) {
+ C.gl2_0_glMaterialf(gl.funcs, C.GLenum(face), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLineStipple.xml
+func (gl *GL) LineStipple(factor int32, pattern uint16) {
+ C.gl2_0_glLineStipple(gl.funcs, C.GLint(factor), C.GLushort(pattern))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLightModeliv.xml
+func (gl *GL) LightModeliv(pname glbase.Enum, params []int32) {
+ C.gl2_0_glLightModeliv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLightModeli.xml
+func (gl *GL) LightModeli(pname glbase.Enum, param int32) {
+ C.gl2_0_glLightModeli(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLightModelfv.xml
+func (gl *GL) LightModelfv(pname glbase.Enum, params []float32) {
+ C.gl2_0_glLightModelfv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLightModelf.xml
+func (gl *GL) LightModelf(pname glbase.Enum, param float32) {
+ C.gl2_0_glLightModelf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLightiv.xml
+func (gl *GL) Lightiv(light, pname glbase.Enum, params []int32) {
+ C.gl2_0_glLightiv(gl.funcs, C.GLenum(light), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLighti.xml
+func (gl *GL) Lighti(light, pname glbase.Enum, param int32) {
+ C.gl2_0_glLighti(gl.funcs, C.GLenum(light), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLightfv.xml
+func (gl *GL) Lightfv(light, pname glbase.Enum, params []float32) {
+ C.gl2_0_glLightfv(gl.funcs, C.GLenum(light), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLightf.xml
+func (gl *GL) Lightf(light, pname glbase.Enum, param float32) {
+ C.gl2_0_glLightf(gl.funcs, C.GLenum(light), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFogiv.xml
+func (gl *GL) Fogiv(pname glbase.Enum, params []int32) {
+ C.gl2_0_glFogiv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFogi.xml
+func (gl *GL) Fogi(pname glbase.Enum, param int32) {
+ C.gl2_0_glFogi(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFogfv.xml
+func (gl *GL) Fogfv(pname glbase.Enum, params []float32) {
+ C.gl2_0_glFogfv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFogf.xml
+func (gl *GL) Fogf(pname glbase.Enum, param float32) {
+ C.gl2_0_glFogf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColorMaterial.xml
+func (gl *GL) ColorMaterial(face, mode glbase.Enum) {
+ C.gl2_0_glColorMaterial(gl.funcs, C.GLenum(face), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClipPlane.xml
+func (gl *GL) ClipPlane(plane glbase.Enum, equation []float64) {
+ C.gl2_0_glClipPlane(gl.funcs, C.GLenum(plane), (*C.GLdouble)(unsafe.Pointer(&equation[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4sv.xml
+func (gl *GL) Vertex4sv(v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glVertex4sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4s.xml
+func (gl *GL) Vertex4s(x, y, z, w int16) {
+ C.gl2_0_glVertex4s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z), C.GLshort(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4iv.xml
+func (gl *GL) Vertex4iv(v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glVertex4iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4i.xml
+func (gl *GL) Vertex4i(x, y, z, w int) {
+ C.gl2_0_glVertex4i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z), C.GLint(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4fv.xml
+func (gl *GL) Vertex4fv(v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glVertex4fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4f.xml
+func (gl *GL) Vertex4f(x, y, z, w float32) {
+ C.gl2_0_glVertex4f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z), C.GLfloat(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4dv.xml
+func (gl *GL) Vertex4dv(v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glVertex4dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4d.xml
+func (gl *GL) Vertex4d(x, y, z, w float64) {
+ C.gl2_0_glVertex4d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z), C.GLdouble(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3sv.xml
+func (gl *GL) Vertex3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glVertex3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3s.xml
+func (gl *GL) Vertex3s(x, y, z int16) {
+ C.gl2_0_glVertex3s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3iv.xml
+func (gl *GL) Vertex3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glVertex3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3i.xml
+func (gl *GL) Vertex3i(x, y, z int) {
+ C.gl2_0_glVertex3i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3fv.xml
+func (gl *GL) Vertex3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glVertex3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3f.xml
+func (gl *GL) Vertex3f(x, y, z float32) {
+ C.gl2_0_glVertex3f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3dv.xml
+func (gl *GL) Vertex3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glVertex3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3d.xml
+func (gl *GL) Vertex3d(x, y, z float64) {
+ C.gl2_0_glVertex3d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2sv.xml
+func (gl *GL) Vertex2sv(v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glVertex2sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2s.xml
+func (gl *GL) Vertex2s(x, y int16) {
+ C.gl2_0_glVertex2s(gl.funcs, C.GLshort(x), C.GLshort(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2iv.xml
+func (gl *GL) Vertex2iv(v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glVertex2iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2i.xml
+func (gl *GL) Vertex2i(x, y int) {
+ C.gl2_0_glVertex2i(gl.funcs, C.GLint(x), C.GLint(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2fv.xml
+func (gl *GL) Vertex2fv(v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glVertex2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2f.xml
+func (gl *GL) Vertex2f(x, y float32) {
+ C.gl2_0_glVertex2f(gl.funcs, C.GLfloat(x), C.GLfloat(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2dv.xml
+func (gl *GL) Vertex2dv(v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glVertex2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2d.xml
+func (gl *GL) Vertex2d(x, y float64) {
+ C.gl2_0_glVertex2d(gl.funcs, C.GLdouble(x), C.GLdouble(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4sv.xml
+func (gl *GL) TexCoord4sv(v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glTexCoord4sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4s.xml
+func (gl *GL) TexCoord4s(s, t, r, q int16) {
+ C.gl2_0_glTexCoord4s(gl.funcs, C.GLshort(s), C.GLshort(t), C.GLshort(r), C.GLshort(q))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4iv.xml
+func (gl *GL) TexCoord4iv(v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glTexCoord4iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4i.xml
+func (gl *GL) TexCoord4i(s, t, r, q int32) {
+ C.gl2_0_glTexCoord4i(gl.funcs, C.GLint(s), C.GLint(t), C.GLint(r), C.GLint(q))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4fv.xml
+func (gl *GL) TexCoord4fv(v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glTexCoord4fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4f.xml
+func (gl *GL) TexCoord4f(s, t, r, q float32) {
+ C.gl2_0_glTexCoord4f(gl.funcs, C.GLfloat(s), C.GLfloat(t), C.GLfloat(r), C.GLfloat(q))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4dv.xml
+func (gl *GL) TexCoord4dv(v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glTexCoord4dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4d.xml
+func (gl *GL) TexCoord4d(s, t, r, q float64) {
+ C.gl2_0_glTexCoord4d(gl.funcs, C.GLdouble(s), C.GLdouble(t), C.GLdouble(r), C.GLdouble(q))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3sv.xml
+func (gl *GL) TexCoord3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glTexCoord3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3s.xml
+func (gl *GL) TexCoord3s(s, t, r int16) {
+ C.gl2_0_glTexCoord3s(gl.funcs, C.GLshort(s), C.GLshort(t), C.GLshort(r))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3iv.xml
+func (gl *GL) TexCoord3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glTexCoord3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3i.xml
+func (gl *GL) TexCoord3i(s, t, r int32) {
+ C.gl2_0_glTexCoord3i(gl.funcs, C.GLint(s), C.GLint(t), C.GLint(r))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3fv.xml
+func (gl *GL) TexCoord3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glTexCoord3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3f.xml
+func (gl *GL) TexCoord3f(s, t, r float32) {
+ C.gl2_0_glTexCoord3f(gl.funcs, C.GLfloat(s), C.GLfloat(t), C.GLfloat(r))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3dv.xml
+func (gl *GL) TexCoord3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glTexCoord3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3d.xml
+func (gl *GL) TexCoord3d(s, t, r float64) {
+ C.gl2_0_glTexCoord3d(gl.funcs, C.GLdouble(s), C.GLdouble(t), C.GLdouble(r))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2sv.xml
+func (gl *GL) TexCoord2sv(v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glTexCoord2sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2s.xml
+func (gl *GL) TexCoord2s(s, t int16) {
+ C.gl2_0_glTexCoord2s(gl.funcs, C.GLshort(s), C.GLshort(t))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2iv.xml
+func (gl *GL) TexCoord2iv(v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glTexCoord2iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2i.xml
+func (gl *GL) TexCoord2i(s, t int32) {
+ C.gl2_0_glTexCoord2i(gl.funcs, C.GLint(s), C.GLint(t))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2fv.xml
+func (gl *GL) TexCoord2fv(v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glTexCoord2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2f.xml
+func (gl *GL) TexCoord2f(s, t float32) {
+ C.gl2_0_glTexCoord2f(gl.funcs, C.GLfloat(s), C.GLfloat(t))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2dv.xml
+func (gl *GL) TexCoord2dv(v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glTexCoord2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2d.xml
+func (gl *GL) TexCoord2d(s, t float64) {
+ C.gl2_0_glTexCoord2d(gl.funcs, C.GLdouble(s), C.GLdouble(t))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1sv.xml
+func (gl *GL) TexCoord1sv(v []int16) {
+ C.gl2_0_glTexCoord1sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1s.xml
+func (gl *GL) TexCoord1s(s int16) {
+ C.gl2_0_glTexCoord1s(gl.funcs, C.GLshort(s))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1iv.xml
+func (gl *GL) TexCoord1iv(v []int32) {
+ C.gl2_0_glTexCoord1iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1i.xml
+func (gl *GL) TexCoord1i(s int32) {
+ C.gl2_0_glTexCoord1i(gl.funcs, C.GLint(s))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1fv.xml
+func (gl *GL) TexCoord1fv(v []float32) {
+ C.gl2_0_glTexCoord1fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1f.xml
+func (gl *GL) TexCoord1f(s float32) {
+ C.gl2_0_glTexCoord1f(gl.funcs, C.GLfloat(s))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1dv.xml
+func (gl *GL) TexCoord1dv(v []float64) {
+ C.gl2_0_glTexCoord1dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1d.xml
+func (gl *GL) TexCoord1d(s float64) {
+ C.gl2_0_glTexCoord1d(gl.funcs, C.GLdouble(s))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRectsv.xml
+func (gl *GL) Rectsv(v1, v2 []int16) {
+ C.gl2_0_glRectsv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v1[0])), (*C.GLshort)(unsafe.Pointer(&v2[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRects.xml
+func (gl *GL) Rects(x1, y1, x2, y2 int16) {
+ C.gl2_0_glRects(gl.funcs, C.GLshort(x1), C.GLshort(y1), C.GLshort(x2), C.GLshort(y2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRectiv.xml
+func (gl *GL) Rectiv(v1, v2 []int32) {
+ C.gl2_0_glRectiv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v1[0])), (*C.GLint)(unsafe.Pointer(&v2[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRecti.xml
+func (gl *GL) Recti(x1, y1, x2, y2 int32) {
+ C.gl2_0_glRecti(gl.funcs, C.GLint(x1), C.GLint(y1), C.GLint(x2), C.GLint(y2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRectfv.xml
+func (gl *GL) Rectfv(v1, v2 []float32) {
+ C.gl2_0_glRectfv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v1[0])), (*C.GLfloat)(unsafe.Pointer(&v2[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRectf.xml
+func (gl *GL) Rectf(x1, y1, x2, y2 float32) {
+ C.gl2_0_glRectf(gl.funcs, C.GLfloat(x1), C.GLfloat(y1), C.GLfloat(x2), C.GLfloat(y2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRectdv.xml
+func (gl *GL) Rectdv(v1, v2 []float64) {
+ C.gl2_0_glRectdv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v1[0])), (*C.GLdouble)(unsafe.Pointer(&v2[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRectd.xml
+func (gl *GL) Rectd(x1, y1, x2, y2 float64) {
+ C.gl2_0_glRectd(gl.funcs, C.GLdouble(x1), C.GLdouble(y1), C.GLdouble(x2), C.GLdouble(y2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4sv.xml
+func (gl *GL) RasterPos4sv(v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glRasterPos4sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4s.xml
+func (gl *GL) RasterPos4s(x, y, z, w int16) {
+ C.gl2_0_glRasterPos4s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z), C.GLshort(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4iv.xml
+func (gl *GL) RasterPos4iv(v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glRasterPos4iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4i.xml
+func (gl *GL) RasterPos4i(x, y, z, w int) {
+ C.gl2_0_glRasterPos4i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z), C.GLint(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4fv.xml
+func (gl *GL) RasterPos4fv(v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glRasterPos4fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4f.xml
+func (gl *GL) RasterPos4f(x, y, z, w float32) {
+ C.gl2_0_glRasterPos4f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z), C.GLfloat(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4dv.xml
+func (gl *GL) RasterPos4dv(v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glRasterPos4dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4d.xml
+func (gl *GL) RasterPos4d(x, y, z, w float64) {
+ C.gl2_0_glRasterPos4d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z), C.GLdouble(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3sv.xml
+func (gl *GL) RasterPos3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glRasterPos3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3s.xml
+func (gl *GL) RasterPos3s(x, y, z int16) {
+ C.gl2_0_glRasterPos3s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3iv.xml
+func (gl *GL) RasterPos3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glRasterPos3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3i.xml
+func (gl *GL) RasterPos3i(x, y, z int) {
+ C.gl2_0_glRasterPos3i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3fv.xml
+func (gl *GL) RasterPos3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glRasterPos3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3f.xml
+func (gl *GL) RasterPos3f(x, y, z float32) {
+ C.gl2_0_glRasterPos3f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3dv.xml
+func (gl *GL) RasterPos3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glRasterPos3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3d.xml
+func (gl *GL) RasterPos3d(x, y, z float64) {
+ C.gl2_0_glRasterPos3d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2sv.xml
+func (gl *GL) RasterPos2sv(v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glRasterPos2sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2s.xml
+func (gl *GL) RasterPos2s(x, y int16) {
+ C.gl2_0_glRasterPos2s(gl.funcs, C.GLshort(x), C.GLshort(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2iv.xml
+func (gl *GL) RasterPos2iv(v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glRasterPos2iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2i.xml
+func (gl *GL) RasterPos2i(x, y int) {
+ C.gl2_0_glRasterPos2i(gl.funcs, C.GLint(x), C.GLint(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2fv.xml
+func (gl *GL) RasterPos2fv(v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glRasterPos2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2f.xml
+func (gl *GL) RasterPos2f(x, y float32) {
+ C.gl2_0_glRasterPos2f(gl.funcs, C.GLfloat(x), C.GLfloat(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2dv.xml
+func (gl *GL) RasterPos2dv(v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glRasterPos2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2d.xml
+func (gl *GL) RasterPos2d(x, y float64) {
+ C.gl2_0_glRasterPos2d(gl.funcs, C.GLdouble(x), C.GLdouble(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3sv.xml
+func (gl *GL) Normal3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glNormal3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3s.xml
+func (gl *GL) Normal3s(nx, ny, nz int16) {
+ C.gl2_0_glNormal3s(gl.funcs, C.GLshort(nx), C.GLshort(ny), C.GLshort(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3iv.xml
+func (gl *GL) Normal3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glNormal3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3i.xml
+func (gl *GL) Normal3i(nx, ny, nz int32) {
+ C.gl2_0_glNormal3i(gl.funcs, C.GLint(nx), C.GLint(ny), C.GLint(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3fv.xml
+func (gl *GL) Normal3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glNormal3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3f.xml
+func (gl *GL) Normal3f(nx, ny, nz float32) {
+ C.gl2_0_glNormal3f(gl.funcs, C.GLfloat(nx), C.GLfloat(ny), C.GLfloat(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3dv.xml
+func (gl *GL) Normal3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glNormal3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3d.xml
+func (gl *GL) Normal3d(nx, ny, nz float64) {
+ C.gl2_0_glNormal3d(gl.funcs, C.GLdouble(nx), C.GLdouble(ny), C.GLdouble(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3bv.xml
+func (gl *GL) Normal3bv(v []byte) {
+ C.gl2_0_glNormal3bv(gl.funcs, (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3b.xml
+func (gl *GL) Normal3b(nx, ny, nz byte) {
+ C.gl2_0_glNormal3b(gl.funcs, C.GLbyte(nx), C.GLbyte(ny), C.GLbyte(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexsv.xml
+func (gl *GL) Indexsv(c []int16) {
+ C.gl2_0_glIndexsv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexs.xml
+func (gl *GL) Indexs(c int16) {
+ C.gl2_0_glIndexs(gl.funcs, C.GLshort(c))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexiv.xml
+func (gl *GL) Indexiv(c []int32) {
+ C.gl2_0_glIndexiv(gl.funcs, (*C.GLint)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexi.xml
+func (gl *GL) Indexi(c int32) {
+ C.gl2_0_glIndexi(gl.funcs, C.GLint(c))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexfv.xml
+func (gl *GL) Indexfv(c []float32) {
+ C.gl2_0_glIndexfv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexf.xml
+func (gl *GL) Indexf(c float32) {
+ C.gl2_0_glIndexf(gl.funcs, C.GLfloat(c))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexdv.xml
+func (gl *GL) Indexdv(c []float64) {
+ C.gl2_0_glIndexdv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexd.xml
+func (gl *GL) Indexd(c float64) {
+ C.gl2_0_glIndexd(gl.funcs, C.GLdouble(c))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEnd.xml
+func (gl *GL) End() {
+ C.gl2_0_glEnd(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEdgeFlagv.xml
+func (gl *GL) EdgeFlagv(flag []bool) {
+ C.gl2_0_glEdgeFlagv(gl.funcs, (*C.GLboolean)(unsafe.Pointer(&flag[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEdgeFlag.xml
+func (gl *GL) EdgeFlag(flag bool) {
+ C.gl2_0_glEdgeFlag(gl.funcs, *(*C.GLboolean)(unsafe.Pointer(&flag)))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4usv.xml
+func (gl *GL) Color4usv(v []uint16) {
+ C.gl2_0_glColor4usv(gl.funcs, (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4us.xml
+func (gl *GL) Color4us(red, green, blue, alpha uint16) {
+ C.gl2_0_glColor4us(gl.funcs, C.GLushort(red), C.GLushort(green), C.GLushort(blue), C.GLushort(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4uiv.xml
+func (gl *GL) Color4uiv(v []uint32) {
+ C.gl2_0_glColor4uiv(gl.funcs, (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4ui.xml
+func (gl *GL) Color4ui(red, green, blue, alpha uint32) {
+ C.gl2_0_glColor4ui(gl.funcs, C.GLuint(red), C.GLuint(green), C.GLuint(blue), C.GLuint(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4ubv.xml
+func (gl *GL) Color4ubv(v []uint8) {
+ C.gl2_0_glColor4ubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4ub.xml
+func (gl *GL) Color4ub(red, green, blue, alpha uint8) {
+ C.gl2_0_glColor4ub(gl.funcs, C.GLubyte(red), C.GLubyte(green), C.GLubyte(blue), C.GLubyte(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4sv.xml
+func (gl *GL) Color4sv(v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glColor4sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4s.xml
+func (gl *GL) Color4s(red, green, blue, alpha int16) {
+ C.gl2_0_glColor4s(gl.funcs, C.GLshort(red), C.GLshort(green), C.GLshort(blue), C.GLshort(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4iv.xml
+func (gl *GL) Color4iv(v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glColor4iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4i.xml
+func (gl *GL) Color4i(red, green, blue, alpha int32) {
+ C.gl2_0_glColor4i(gl.funcs, C.GLint(red), C.GLint(green), C.GLint(blue), C.GLint(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4fv.xml
+func (gl *GL) Color4fv(v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glColor4fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4f.xml
+func (gl *GL) Color4f(red, green, blue, alpha float32) {
+ C.gl2_0_glColor4f(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4dv.xml
+func (gl *GL) Color4dv(v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glColor4dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4d.xml
+func (gl *GL) Color4d(red, green, blue, alpha float64) {
+ C.gl2_0_glColor4d(gl.funcs, C.GLdouble(red), C.GLdouble(green), C.GLdouble(blue), C.GLdouble(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4bv.xml
+func (gl *GL) Color4bv(v []byte) {
+ C.gl2_0_glColor4bv(gl.funcs, (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4b.xml
+func (gl *GL) Color4b(red, green, blue, alpha byte) {
+ C.gl2_0_glColor4b(gl.funcs, C.GLbyte(red), C.GLbyte(green), C.GLbyte(blue), C.GLbyte(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3usv.xml
+func (gl *GL) Color3usv(v []uint16) {
+ C.gl2_0_glColor3usv(gl.funcs, (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3us.xml
+func (gl *GL) Color3us(red, green, blue uint16) {
+ C.gl2_0_glColor3us(gl.funcs, C.GLushort(red), C.GLushort(green), C.GLushort(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3uiv.xml
+func (gl *GL) Color3uiv(v []uint32) {
+ C.gl2_0_glColor3uiv(gl.funcs, (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3ui.xml
+func (gl *GL) Color3ui(red, green, blue uint32) {
+ C.gl2_0_glColor3ui(gl.funcs, C.GLuint(red), C.GLuint(green), C.GLuint(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3ubv.xml
+func (gl *GL) Color3ubv(v []uint8) {
+ C.gl2_0_glColor3ubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3ub.xml
+func (gl *GL) Color3ub(red, green, blue uint8) {
+ C.gl2_0_glColor3ub(gl.funcs, C.GLubyte(red), C.GLubyte(green), C.GLubyte(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3sv.xml
+func (gl *GL) Color3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glColor3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3s.xml
+func (gl *GL) Color3s(red, green, blue int16) {
+ C.gl2_0_glColor3s(gl.funcs, C.GLshort(red), C.GLshort(green), C.GLshort(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3iv.xml
+func (gl *GL) Color3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glColor3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3i.xml
+func (gl *GL) Color3i(red, green, blue int32) {
+ C.gl2_0_glColor3i(gl.funcs, C.GLint(red), C.GLint(green), C.GLint(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3fv.xml
+func (gl *GL) Color3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glColor3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3f.xml
+func (gl *GL) Color3f(red, green, blue float32) {
+ C.gl2_0_glColor3f(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3dv.xml
+func (gl *GL) Color3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glColor3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3d.xml
+func (gl *GL) Color3d(red, green, blue float64) {
+ C.gl2_0_glColor3d(gl.funcs, C.GLdouble(red), C.GLdouble(green), C.GLdouble(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3bv.xml
+func (gl *GL) Color3bv(v []byte) {
+ C.gl2_0_glColor3bv(gl.funcs, (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3b.xml
+func (gl *GL) Color3b(red, green, blue byte) {
+ C.gl2_0_glColor3b(gl.funcs, C.GLbyte(red), C.GLbyte(green), C.GLbyte(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBitmap.xml
+func (gl *GL) Bitmap(width, height int, xorig, yorig, xmove, ymove float32, bitmap []uint8) {
+ C.gl2_0_glBitmap(gl.funcs, C.GLsizei(width), C.GLsizei(height), C.GLfloat(xorig), C.GLfloat(yorig), C.GLfloat(xmove), C.GLfloat(ymove), (*C.GLubyte)(unsafe.Pointer(&bitmap[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBegin.xml
+func (gl *GL) Begin(mode glbase.Enum) {
+ C.gl2_0_glBegin(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glListBase.xml
+func (gl *GL) ListBase(base uint32) {
+ C.gl2_0_glListBase(gl.funcs, C.GLuint(base))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGenLists.xml
+func (gl *GL) GenLists(range_ int32) uint32 {
+ glresult := C.gl2_0_glGenLists(gl.funcs, C.GLsizei(range_))
+ return uint32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDeleteLists.xml
+func (gl *GL) DeleteLists(list uint32, range_ int32) {
+ C.gl2_0_glDeleteLists(gl.funcs, C.GLuint(list), C.GLsizei(range_))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCallLists.xml
+func (gl *GL) CallLists(n int, gltype glbase.Enum, lists interface{}) {
+ var lists_ptr unsafe.Pointer
+ var lists_v = reflect.ValueOf(lists)
+ if lists != nil && lists_v.Kind() != reflect.Slice {
+ panic("parameter lists must be a slice")
+ }
+ if lists != nil {
+ lists_ptr = unsafe.Pointer(lists_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_0_glCallLists(gl.funcs, C.GLsizei(n), C.GLenum(gltype), lists_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCallList.xml
+func (gl *GL) CallList(list uint32) {
+ C.gl2_0_glCallList(gl.funcs, C.GLuint(list))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEndList.xml
+func (gl *GL) EndList() {
+ C.gl2_0_glEndList(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNewList.xml
+func (gl *GL) NewList(list uint32, mode glbase.Enum) {
+ C.gl2_0_glNewList(gl.funcs, C.GLuint(list), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPushClientAttrib.xml
+func (gl *GL) PushClientAttrib(mask glbase.Bitfield) {
+ C.gl2_0_glPushClientAttrib(gl.funcs, C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPopClientAttrib.xml
+func (gl *GL) PopClientAttrib() {
+ C.gl2_0_glPopClientAttrib(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPrioritizeTextures.xml
+func (gl *GL) PrioritizeTextures(n int, textures []glbase.Texture, priorities []float32) {
+ C.gl2_0_glPrioritizeTextures(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])), (*C.GLfloat)(unsafe.Pointer(&priorities[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glAreTexturesResident.xml
+func (gl *GL) AreTexturesResident(n int, textures []glbase.Texture, residences []bool) bool {
+ glresult := C.gl2_0_glAreTexturesResident(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])), (*C.GLboolean)(unsafe.Pointer(&residences[0])))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexPointer.xml
+func (gl *GL) VertexPointer(size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_0_glVertexPointer(gl.funcs, C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoordPointer.xml
+func (gl *GL) TexCoordPointer(size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_0_glTexCoordPointer(gl.funcs, C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormalPointer.xml
+func (gl *GL) NormalPointer(gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_0_glNormalPointer(gl.funcs, C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glInterleavedArrays.xml
+func (gl *GL) InterleavedArrays(format glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_0_glInterleavedArrays(gl.funcs, C.GLenum(format), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexPointer.xml
+func (gl *GL) IndexPointer(gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_0_glIndexPointer(gl.funcs, C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEnableClientState.xml
+func (gl *GL) EnableClientState(array glbase.Enum) {
+ C.gl2_0_glEnableClientState(gl.funcs, C.GLenum(array))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEdgeFlagPointer.xml
+func (gl *GL) EdgeFlagPointer(stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_0_glEdgeFlagPointer(gl.funcs, C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDisableClientState.xml
+func (gl *GL) DisableClientState(array glbase.Enum) {
+ C.gl2_0_glDisableClientState(gl.funcs, C.GLenum(array))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColorPointer.xml
+func (gl *GL) ColorPointer(size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_0_glColorPointer(gl.funcs, C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glArrayElement.xml
+func (gl *GL) ArrayElement(i int32) {
+ C.gl2_0_glArrayElement(gl.funcs, C.GLint(i))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glResetMinmax.xml
+func (gl *GL) ResetMinmax(target glbase.Enum) {
+ C.gl2_0_glResetMinmax(gl.funcs, C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glResetHistogram.xml
+func (gl *GL) ResetHistogram(target glbase.Enum) {
+ C.gl2_0_glResetHistogram(gl.funcs, C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMinmax.xml
+func (gl *GL) Minmax(target, internalFormat glbase.Enum, sink bool) {
+ C.gl2_0_glMinmax(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), *(*C.GLboolean)(unsafe.Pointer(&sink)))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glHistogram.xml
+func (gl *GL) Histogram(target glbase.Enum, width int, internalFormat glbase.Enum, sink bool) {
+ C.gl2_0_glHistogram(gl.funcs, C.GLenum(target), C.GLsizei(width), C.GLenum(internalFormat), *(*C.GLboolean)(unsafe.Pointer(&sink)))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetMinmaxParameteriv.xml
+func (gl *GL) GetMinmaxParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl2_0_glGetMinmaxParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetMinmaxParameterfv.xml
+func (gl *GL) GetMinmaxParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl2_0_glGetMinmaxParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetMinmax.xml
+func (gl *GL) GetMinmax(target glbase.Enum, reset bool, format, gltype glbase.Enum, values interface{}) {
+ var values_ptr unsafe.Pointer
+ var values_v = reflect.ValueOf(values)
+ if values != nil && values_v.Kind() != reflect.Slice {
+ panic("parameter values must be a slice")
+ }
+ if values != nil {
+ values_ptr = unsafe.Pointer(values_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_0_glGetMinmax(gl.funcs, C.GLenum(target), *(*C.GLboolean)(unsafe.Pointer(&reset)), C.GLenum(format), C.GLenum(gltype), values_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetHistogramParameteriv.xml
+func (gl *GL) GetHistogramParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl2_0_glGetHistogramParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetHistogramParameterfv.xml
+func (gl *GL) GetHistogramParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl2_0_glGetHistogramParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetHistogram.xml
+func (gl *GL) GetHistogram(target glbase.Enum, reset bool, format, gltype glbase.Enum, values interface{}) {
+ var values_ptr unsafe.Pointer
+ var values_v = reflect.ValueOf(values)
+ if values != nil && values_v.Kind() != reflect.Slice {
+ panic("parameter values must be a slice")
+ }
+ if values != nil {
+ values_ptr = unsafe.Pointer(values_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_0_glGetHistogram(gl.funcs, C.GLenum(target), *(*C.GLboolean)(unsafe.Pointer(&reset)), C.GLenum(format), C.GLenum(gltype), values_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSeparableFilter2D.xml
+func (gl *GL) SeparableFilter2D(target, internalFormat glbase.Enum, width, height int, format, gltype glbase.Enum, row, column interface{}) {
+ var row_ptr unsafe.Pointer
+ var row_v = reflect.ValueOf(row)
+ if row != nil && row_v.Kind() != reflect.Slice {
+ panic("parameter row must be a slice")
+ }
+ if row != nil {
+ row_ptr = unsafe.Pointer(row_v.Index(0).Addr().Pointer())
+ }
+ var column_ptr unsafe.Pointer
+ var column_v = reflect.ValueOf(column)
+ if column != nil && column_v.Kind() != reflect.Slice {
+ panic("parameter column must be a slice")
+ }
+ if column != nil {
+ column_ptr = unsafe.Pointer(column_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_0_glSeparableFilter2D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), row_ptr, column_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetSeparableFilter.xml
+func (gl *GL) GetSeparableFilter(target, format, gltype glbase.Enum, row, column, span interface{}) {
+ var row_ptr unsafe.Pointer
+ var row_v = reflect.ValueOf(row)
+ if row != nil && row_v.Kind() != reflect.Slice {
+ panic("parameter row must be a slice")
+ }
+ if row != nil {
+ row_ptr = unsafe.Pointer(row_v.Index(0).Addr().Pointer())
+ }
+ var column_ptr unsafe.Pointer
+ var column_v = reflect.ValueOf(column)
+ if column != nil && column_v.Kind() != reflect.Slice {
+ panic("parameter column must be a slice")
+ }
+ if column != nil {
+ column_ptr = unsafe.Pointer(column_v.Index(0).Addr().Pointer())
+ }
+ var span_ptr unsafe.Pointer
+ var span_v = reflect.ValueOf(span)
+ if span != nil && span_v.Kind() != reflect.Slice {
+ panic("parameter span must be a slice")
+ }
+ if span != nil {
+ span_ptr = unsafe.Pointer(span_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_0_glGetSeparableFilter(gl.funcs, C.GLenum(target), C.GLenum(format), C.GLenum(gltype), row_ptr, column_ptr, span_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetConvolutionParameteriv.xml
+func (gl *GL) GetConvolutionParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl2_0_glGetConvolutionParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetConvolutionParameterfv.xml
+func (gl *GL) GetConvolutionParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl2_0_glGetConvolutionParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetConvolutionFilter.xml
+func (gl *GL) GetConvolutionFilter(target, format, gltype glbase.Enum, image interface{}) {
+ var image_ptr unsafe.Pointer
+ var image_v = reflect.ValueOf(image)
+ if image != nil && image_v.Kind() != reflect.Slice {
+ panic("parameter image must be a slice")
+ }
+ if image != nil {
+ image_ptr = unsafe.Pointer(image_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_0_glGetConvolutionFilter(gl.funcs, C.GLenum(target), C.GLenum(format), C.GLenum(gltype), image_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyConvolutionFilter2D.xml
+func (gl *GL) CopyConvolutionFilter2D(target, internalFormat glbase.Enum, x, y, width, height int) {
+ C.gl2_0_glCopyConvolutionFilter2D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyConvolutionFilter1D.xml
+func (gl *GL) CopyConvolutionFilter1D(target, internalFormat glbase.Enum, x, y, width int) {
+ C.gl2_0_glCopyConvolutionFilter1D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glConvolutionParameteriv.xml
+func (gl *GL) ConvolutionParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl2_0_glConvolutionParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glConvolutionParameteri.xml
+func (gl *GL) ConvolutionParameteri(target, pname glbase.Enum, params int32) {
+ C.gl2_0_glConvolutionParameteri(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLint(params))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glConvolutionParameterfv.xml
+func (gl *GL) ConvolutionParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl2_0_glConvolutionParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glConvolutionParameterf.xml
+func (gl *GL) ConvolutionParameterf(target, pname glbase.Enum, params float32) {
+ C.gl2_0_glConvolutionParameterf(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLfloat(params))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glConvolutionFilter2D.xml
+func (gl *GL) ConvolutionFilter2D(target, internalFormat glbase.Enum, width, height int, format, gltype glbase.Enum, image interface{}) {
+ var image_ptr unsafe.Pointer
+ var image_v = reflect.ValueOf(image)
+ if image != nil && image_v.Kind() != reflect.Slice {
+ panic("parameter image must be a slice")
+ }
+ if image != nil {
+ image_ptr = unsafe.Pointer(image_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_0_glConvolutionFilter2D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), image_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glConvolutionFilter1D.xml
+func (gl *GL) ConvolutionFilter1D(target, internalFormat glbase.Enum, width int, format, gltype glbase.Enum, image interface{}) {
+ var image_ptr unsafe.Pointer
+ var image_v = reflect.ValueOf(image)
+ if image != nil && image_v.Kind() != reflect.Slice {
+ panic("parameter image must be a slice")
+ }
+ if image != nil {
+ image_ptr = unsafe.Pointer(image_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_0_glConvolutionFilter1D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLenum(format), C.GLenum(gltype), image_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyColorSubTable.xml
+func (gl *GL) CopyColorSubTable(target glbase.Enum, start int32, x, y, width int) {
+ C.gl2_0_glCopyColorSubTable(gl.funcs, C.GLenum(target), C.GLsizei(start), C.GLint(x), C.GLint(y), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColorSubTable.xml
+func (gl *GL) ColorSubTable(target glbase.Enum, start int32, count int, format, gltype glbase.Enum, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_0_glColorSubTable(gl.funcs, C.GLenum(target), C.GLsizei(start), C.GLsizei(count), C.GLenum(format), C.GLenum(gltype), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetColorTableParameteriv.xml
+func (gl *GL) GetColorTableParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl2_0_glGetColorTableParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetColorTableParameterfv.xml
+func (gl *GL) GetColorTableParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl2_0_glGetColorTableParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetColorTable.xml
+func (gl *GL) GetColorTable(target, format, gltype glbase.Enum, table interface{}) {
+ var table_ptr unsafe.Pointer
+ var table_v = reflect.ValueOf(table)
+ if table != nil && table_v.Kind() != reflect.Slice {
+ panic("parameter table must be a slice")
+ }
+ if table != nil {
+ table_ptr = unsafe.Pointer(table_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_0_glGetColorTable(gl.funcs, C.GLenum(target), C.GLenum(format), C.GLenum(gltype), table_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyColorTable.xml
+func (gl *GL) CopyColorTable(target, internalFormat glbase.Enum, x, y, width int) {
+ C.gl2_0_glCopyColorTable(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColorTableParameteriv.xml
+func (gl *GL) ColorTableParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl2_0_glColorTableParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColorTableParameterfv.xml
+func (gl *GL) ColorTableParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl2_0_glColorTableParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColorTable.xml
+func (gl *GL) ColorTable(target, internalFormat glbase.Enum, width int, format, gltype glbase.Enum, table interface{}) {
+ var table_ptr unsafe.Pointer
+ var table_v = reflect.ValueOf(table)
+ if table != nil && table_v.Kind() != reflect.Slice {
+ panic("parameter table must be a slice")
+ }
+ if table != nil {
+ table_ptr = unsafe.Pointer(table_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_0_glColorTable(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLenum(format), C.GLenum(gltype), table_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultTransposeMatrixd.xml
+func (gl *GL) MultTransposeMatrixd(m []float64) {
+ C.gl2_0_glMultTransposeMatrixd(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultTransposeMatrixf.xml
+func (gl *GL) MultTransposeMatrixf(m []float32) {
+ C.gl2_0_glMultTransposeMatrixf(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLoadTransposeMatrixd.xml
+func (gl *GL) LoadTransposeMatrixd(m []float64) {
+ C.gl2_0_glLoadTransposeMatrixd(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLoadTransposeMatrixf.xml
+func (gl *GL) LoadTransposeMatrixf(m []float32) {
+ C.gl2_0_glLoadTransposeMatrixf(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord4sv.xml
+func (gl *GL) MultiTexCoord4sv(target glbase.Enum, v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glMultiTexCoord4sv(gl.funcs, C.GLenum(target), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord4s.xml
+func (gl *GL) MultiTexCoord4s(target glbase.Enum, s, t, r, q int16) {
+ C.gl2_0_glMultiTexCoord4s(gl.funcs, C.GLenum(target), C.GLshort(s), C.GLshort(t), C.GLshort(r), C.GLshort(q))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord4iv.xml
+func (gl *GL) MultiTexCoord4iv(target glbase.Enum, v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glMultiTexCoord4iv(gl.funcs, C.GLenum(target), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord4i.xml
+func (gl *GL) MultiTexCoord4i(target glbase.Enum, s, t, r, q int32) {
+ C.gl2_0_glMultiTexCoord4i(gl.funcs, C.GLenum(target), C.GLint(s), C.GLint(t), C.GLint(r), C.GLint(q))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord4fv.xml
+func (gl *GL) MultiTexCoord4fv(target glbase.Enum, v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glMultiTexCoord4fv(gl.funcs, C.GLenum(target), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord4f.xml
+func (gl *GL) MultiTexCoord4f(target glbase.Enum, s, t, r, q float32) {
+ C.gl2_0_glMultiTexCoord4f(gl.funcs, C.GLenum(target), C.GLfloat(s), C.GLfloat(t), C.GLfloat(r), C.GLfloat(q))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord4dv.xml
+func (gl *GL) MultiTexCoord4dv(target glbase.Enum, v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glMultiTexCoord4dv(gl.funcs, C.GLenum(target), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord4d.xml
+func (gl *GL) MultiTexCoord4d(target glbase.Enum, s, t, r, q float64) {
+ C.gl2_0_glMultiTexCoord4d(gl.funcs, C.GLenum(target), C.GLdouble(s), C.GLdouble(t), C.GLdouble(r), C.GLdouble(q))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord3sv.xml
+func (gl *GL) MultiTexCoord3sv(target glbase.Enum, v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glMultiTexCoord3sv(gl.funcs, C.GLenum(target), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord3s.xml
+func (gl *GL) MultiTexCoord3s(target glbase.Enum, s, t, r int16) {
+ C.gl2_0_glMultiTexCoord3s(gl.funcs, C.GLenum(target), C.GLshort(s), C.GLshort(t), C.GLshort(r))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord3iv.xml
+func (gl *GL) MultiTexCoord3iv(target glbase.Enum, v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glMultiTexCoord3iv(gl.funcs, C.GLenum(target), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord3i.xml
+func (gl *GL) MultiTexCoord3i(target glbase.Enum, s, t, r int32) {
+ C.gl2_0_glMultiTexCoord3i(gl.funcs, C.GLenum(target), C.GLint(s), C.GLint(t), C.GLint(r))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord3fv.xml
+func (gl *GL) MultiTexCoord3fv(target glbase.Enum, v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glMultiTexCoord3fv(gl.funcs, C.GLenum(target), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord3f.xml
+func (gl *GL) MultiTexCoord3f(target glbase.Enum, s, t, r float32) {
+ C.gl2_0_glMultiTexCoord3f(gl.funcs, C.GLenum(target), C.GLfloat(s), C.GLfloat(t), C.GLfloat(r))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord3dv.xml
+func (gl *GL) MultiTexCoord3dv(target glbase.Enum, v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glMultiTexCoord3dv(gl.funcs, C.GLenum(target), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord3d.xml
+func (gl *GL) MultiTexCoord3d(target glbase.Enum, s, t, r float64) {
+ C.gl2_0_glMultiTexCoord3d(gl.funcs, C.GLenum(target), C.GLdouble(s), C.GLdouble(t), C.GLdouble(r))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord2sv.xml
+func (gl *GL) MultiTexCoord2sv(target glbase.Enum, v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glMultiTexCoord2sv(gl.funcs, C.GLenum(target), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord2s.xml
+func (gl *GL) MultiTexCoord2s(target glbase.Enum, s, t int16) {
+ C.gl2_0_glMultiTexCoord2s(gl.funcs, C.GLenum(target), C.GLshort(s), C.GLshort(t))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord2iv.xml
+func (gl *GL) MultiTexCoord2iv(target glbase.Enum, v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glMultiTexCoord2iv(gl.funcs, C.GLenum(target), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord2i.xml
+func (gl *GL) MultiTexCoord2i(target glbase.Enum, s, t int32) {
+ C.gl2_0_glMultiTexCoord2i(gl.funcs, C.GLenum(target), C.GLint(s), C.GLint(t))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord2fv.xml
+func (gl *GL) MultiTexCoord2fv(target glbase.Enum, v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glMultiTexCoord2fv(gl.funcs, C.GLenum(target), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord2f.xml
+func (gl *GL) MultiTexCoord2f(target glbase.Enum, s, t float32) {
+ C.gl2_0_glMultiTexCoord2f(gl.funcs, C.GLenum(target), C.GLfloat(s), C.GLfloat(t))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord2dv.xml
+func (gl *GL) MultiTexCoord2dv(target glbase.Enum, v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glMultiTexCoord2dv(gl.funcs, C.GLenum(target), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord2d.xml
+func (gl *GL) MultiTexCoord2d(target glbase.Enum, s, t float64) {
+ C.gl2_0_glMultiTexCoord2d(gl.funcs, C.GLenum(target), C.GLdouble(s), C.GLdouble(t))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord1sv.xml
+func (gl *GL) MultiTexCoord1sv(target glbase.Enum, v []int16) {
+ C.gl2_0_glMultiTexCoord1sv(gl.funcs, C.GLenum(target), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord1s.xml
+func (gl *GL) MultiTexCoord1s(target glbase.Enum, s int16) {
+ C.gl2_0_glMultiTexCoord1s(gl.funcs, C.GLenum(target), C.GLshort(s))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord1iv.xml
+func (gl *GL) MultiTexCoord1iv(target glbase.Enum, v []int32) {
+ C.gl2_0_glMultiTexCoord1iv(gl.funcs, C.GLenum(target), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord1i.xml
+func (gl *GL) MultiTexCoord1i(target glbase.Enum, s int32) {
+ C.gl2_0_glMultiTexCoord1i(gl.funcs, C.GLenum(target), C.GLint(s))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord1fv.xml
+func (gl *GL) MultiTexCoord1fv(target glbase.Enum, v []float32) {
+ C.gl2_0_glMultiTexCoord1fv(gl.funcs, C.GLenum(target), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord1f.xml
+func (gl *GL) MultiTexCoord1f(target glbase.Enum, s float32) {
+ C.gl2_0_glMultiTexCoord1f(gl.funcs, C.GLenum(target), C.GLfloat(s))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord1dv.xml
+func (gl *GL) MultiTexCoord1dv(target glbase.Enum, v []float64) {
+ C.gl2_0_glMultiTexCoord1dv(gl.funcs, C.GLenum(target), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord1d.xml
+func (gl *GL) MultiTexCoord1d(target glbase.Enum, s float64) {
+ C.gl2_0_glMultiTexCoord1d(gl.funcs, C.GLenum(target), C.GLdouble(s))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClientActiveTexture.xml
+func (gl *GL) ClientActiveTexture(texture glbase.Enum) {
+ C.gl2_0_glClientActiveTexture(gl.funcs, C.GLenum(texture))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos3sv.xml
+func (gl *GL) WindowPos3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glWindowPos3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos3s.xml
+func (gl *GL) WindowPos3s(x, y, z int16) {
+ C.gl2_0_glWindowPos3s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos3iv.xml
+func (gl *GL) WindowPos3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glWindowPos3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos3i.xml
+func (gl *GL) WindowPos3i(x, y, z int) {
+ C.gl2_0_glWindowPos3i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos3fv.xml
+func (gl *GL) WindowPos3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glWindowPos3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos3f.xml
+func (gl *GL) WindowPos3f(x, y, z float32) {
+ C.gl2_0_glWindowPos3f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos3dv.xml
+func (gl *GL) WindowPos3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glWindowPos3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos3d.xml
+func (gl *GL) WindowPos3d(x, y, z float64) {
+ C.gl2_0_glWindowPos3d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos2sv.xml
+func (gl *GL) WindowPos2sv(v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glWindowPos2sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos2s.xml
+func (gl *GL) WindowPos2s(x, y int16) {
+ C.gl2_0_glWindowPos2s(gl.funcs, C.GLshort(x), C.GLshort(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos2iv.xml
+func (gl *GL) WindowPos2iv(v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glWindowPos2iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos2i.xml
+func (gl *GL) WindowPos2i(x, y int) {
+ C.gl2_0_glWindowPos2i(gl.funcs, C.GLint(x), C.GLint(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos2fv.xml
+func (gl *GL) WindowPos2fv(v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glWindowPos2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos2f.xml
+func (gl *GL) WindowPos2f(x, y float32) {
+ C.gl2_0_glWindowPos2f(gl.funcs, C.GLfloat(x), C.GLfloat(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos2dv.xml
+func (gl *GL) WindowPos2dv(v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glWindowPos2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos2d.xml
+func (gl *GL) WindowPos2d(x, y float64) {
+ C.gl2_0_glWindowPos2d(gl.funcs, C.GLdouble(x), C.GLdouble(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColorPointer.xml
+func (gl *GL) SecondaryColorPointer(size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_0_glSecondaryColorPointer(gl.funcs, C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3usv.xml
+func (gl *GL) SecondaryColor3usv(v []uint16) {
+ C.gl2_0_glSecondaryColor3usv(gl.funcs, (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3us.xml
+func (gl *GL) SecondaryColor3us(red, green, blue uint16) {
+ C.gl2_0_glSecondaryColor3us(gl.funcs, C.GLushort(red), C.GLushort(green), C.GLushort(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3uiv.xml
+func (gl *GL) SecondaryColor3uiv(v []uint32) {
+ C.gl2_0_glSecondaryColor3uiv(gl.funcs, (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3ui.xml
+func (gl *GL) SecondaryColor3ui(red, green, blue uint32) {
+ C.gl2_0_glSecondaryColor3ui(gl.funcs, C.GLuint(red), C.GLuint(green), C.GLuint(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3ubv.xml
+func (gl *GL) SecondaryColor3ubv(v []uint8) {
+ C.gl2_0_glSecondaryColor3ubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3ub.xml
+func (gl *GL) SecondaryColor3ub(red, green, blue uint8) {
+ C.gl2_0_glSecondaryColor3ub(gl.funcs, C.GLubyte(red), C.GLubyte(green), C.GLubyte(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3sv.xml
+func (gl *GL) SecondaryColor3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glSecondaryColor3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3s.xml
+func (gl *GL) SecondaryColor3s(red, green, blue int16) {
+ C.gl2_0_glSecondaryColor3s(gl.funcs, C.GLshort(red), C.GLshort(green), C.GLshort(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3iv.xml
+func (gl *GL) SecondaryColor3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glSecondaryColor3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3i.xml
+func (gl *GL) SecondaryColor3i(red, green, blue int32) {
+ C.gl2_0_glSecondaryColor3i(gl.funcs, C.GLint(red), C.GLint(green), C.GLint(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3fv.xml
+func (gl *GL) SecondaryColor3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glSecondaryColor3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3f.xml
+func (gl *GL) SecondaryColor3f(red, green, blue float32) {
+ C.gl2_0_glSecondaryColor3f(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3dv.xml
+func (gl *GL) SecondaryColor3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glSecondaryColor3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3d.xml
+func (gl *GL) SecondaryColor3d(red, green, blue float64) {
+ C.gl2_0_glSecondaryColor3d(gl.funcs, C.GLdouble(red), C.GLdouble(green), C.GLdouble(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3bv.xml
+func (gl *GL) SecondaryColor3bv(v []byte) {
+ C.gl2_0_glSecondaryColor3bv(gl.funcs, (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3b.xml
+func (gl *GL) SecondaryColor3b(red, green, blue byte) {
+ C.gl2_0_glSecondaryColor3b(gl.funcs, C.GLbyte(red), C.GLbyte(green), C.GLbyte(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFogCoordPointer.xml
+func (gl *GL) FogCoordPointer(gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_0_glFogCoordPointer(gl.funcs, C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFogCoorddv.xml
+func (gl *GL) FogCoorddv(coord []float64) {
+ C.gl2_0_glFogCoorddv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&coord[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFogCoordd.xml
+func (gl *GL) FogCoordd(coord float64) {
+ C.gl2_0_glFogCoordd(gl.funcs, C.GLdouble(coord))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFogCoordfv.xml
+func (gl *GL) FogCoordfv(coord []float32) {
+ C.gl2_0_glFogCoordfv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&coord[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFogCoordf.xml
+func (gl *GL) FogCoordf(coord float32) {
+ C.gl2_0_glFogCoordf(gl.funcs, C.GLfloat(coord))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib4usv.xml
+func (gl *GL) VertexAttrib4usv(index glbase.Attrib, v []uint16) {
+ C.gl2_0_glVertexAttrib4usv(gl.funcs, C.GLuint(index), (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib4uiv.xml
+func (gl *GL) VertexAttrib4uiv(index glbase.Attrib, v []uint32) {
+ C.gl2_0_glVertexAttrib4uiv(gl.funcs, C.GLuint(index), (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib4ubv.xml
+func (gl *GL) VertexAttrib4ubv(index glbase.Attrib, v []uint8) {
+ C.gl2_0_glVertexAttrib4ubv(gl.funcs, C.GLuint(index), (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib4sv.xml
+func (gl *GL) VertexAttrib4sv(index glbase.Attrib, v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glVertexAttrib4sv(gl.funcs, C.GLuint(index), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib4s.xml
+func (gl *GL) VertexAttrib4s(index glbase.Attrib, x, y, z, w int16) {
+ C.gl2_0_glVertexAttrib4s(gl.funcs, C.GLuint(index), C.GLshort(x), C.GLshort(y), C.GLshort(z), C.GLshort(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib4iv.xml
+func (gl *GL) VertexAttrib4iv(index glbase.Attrib, v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glVertexAttrib4iv(gl.funcs, C.GLuint(index), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib4fv.xml
+func (gl *GL) VertexAttrib4fv(index glbase.Attrib, v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glVertexAttrib4fv(gl.funcs, C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib4f.xml
+func (gl *GL) VertexAttrib4f(index glbase.Attrib, x, y, z, w float32) {
+ C.gl2_0_glVertexAttrib4f(gl.funcs, C.GLuint(index), C.GLfloat(x), C.GLfloat(y), C.GLfloat(z), C.GLfloat(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib4dv.xml
+func (gl *GL) VertexAttrib4dv(index glbase.Attrib, v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glVertexAttrib4dv(gl.funcs, C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib4d.xml
+func (gl *GL) VertexAttrib4d(index glbase.Attrib, x, y, z, w float64) {
+ C.gl2_0_glVertexAttrib4d(gl.funcs, C.GLuint(index), C.GLdouble(x), C.GLdouble(y), C.GLdouble(z), C.GLdouble(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib4bv.xml
+func (gl *GL) VertexAttrib4bv(index glbase.Attrib, v []byte) {
+ C.gl2_0_glVertexAttrib4bv(gl.funcs, C.GLuint(index), (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib4Nusv.xml
+func (gl *GL) VertexAttrib4Nusv(index glbase.Attrib, v []uint16) {
+ C.gl2_0_glVertexAttrib4Nusv(gl.funcs, C.GLuint(index), (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib4Nuiv.xml
+func (gl *GL) VertexAttrib4Nuiv(index glbase.Attrib, v []uint32) {
+ C.gl2_0_glVertexAttrib4Nuiv(gl.funcs, C.GLuint(index), (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib4Nubv.xml
+func (gl *GL) VertexAttrib4Nubv(index glbase.Attrib, v []uint8) {
+ C.gl2_0_glVertexAttrib4Nubv(gl.funcs, C.GLuint(index), (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib4Nub.xml
+func (gl *GL) VertexAttrib4Nub(index glbase.Attrib, x, y, z, w uint8) {
+ C.gl2_0_glVertexAttrib4Nub(gl.funcs, C.GLuint(index), C.GLubyte(x), C.GLubyte(y), C.GLubyte(z), C.GLubyte(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib4Nsv.xml
+func (gl *GL) VertexAttrib4Nsv(index glbase.Attrib, v []int16) {
+ C.gl2_0_glVertexAttrib4Nsv(gl.funcs, C.GLuint(index), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib4Niv.xml
+func (gl *GL) VertexAttrib4Niv(index glbase.Attrib, v []int32) {
+ C.gl2_0_glVertexAttrib4Niv(gl.funcs, C.GLuint(index), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib4Nbv.xml
+func (gl *GL) VertexAttrib4Nbv(index glbase.Attrib, v []byte) {
+ C.gl2_0_glVertexAttrib4Nbv(gl.funcs, C.GLuint(index), (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib3sv.xml
+func (gl *GL) VertexAttrib3sv(index glbase.Attrib, v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glVertexAttrib3sv(gl.funcs, C.GLuint(index), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib3s.xml
+func (gl *GL) VertexAttrib3s(index glbase.Attrib, x, y, z int16) {
+ C.gl2_0_glVertexAttrib3s(gl.funcs, C.GLuint(index), C.GLshort(x), C.GLshort(y), C.GLshort(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib3fv.xml
+func (gl *GL) VertexAttrib3fv(index glbase.Attrib, v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glVertexAttrib3fv(gl.funcs, C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib3f.xml
+func (gl *GL) VertexAttrib3f(index glbase.Attrib, x, y, z float32) {
+ C.gl2_0_glVertexAttrib3f(gl.funcs, C.GLuint(index), C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib3dv.xml
+func (gl *GL) VertexAttrib3dv(index glbase.Attrib, v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glVertexAttrib3dv(gl.funcs, C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib3d.xml
+func (gl *GL) VertexAttrib3d(index glbase.Attrib, x, y, z float64) {
+ C.gl2_0_glVertexAttrib3d(gl.funcs, C.GLuint(index), C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib2sv.xml
+func (gl *GL) VertexAttrib2sv(index glbase.Attrib, v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glVertexAttrib2sv(gl.funcs, C.GLuint(index), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib2s.xml
+func (gl *GL) VertexAttrib2s(index glbase.Attrib, x, y int16) {
+ C.gl2_0_glVertexAttrib2s(gl.funcs, C.GLuint(index), C.GLshort(x), C.GLshort(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib2fv.xml
+func (gl *GL) VertexAttrib2fv(index glbase.Attrib, v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glVertexAttrib2fv(gl.funcs, C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib2f.xml
+func (gl *GL) VertexAttrib2f(index glbase.Attrib, x, y float32) {
+ C.gl2_0_glVertexAttrib2f(gl.funcs, C.GLuint(index), C.GLfloat(x), C.GLfloat(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib2dv.xml
+func (gl *GL) VertexAttrib2dv(index glbase.Attrib, v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_0_glVertexAttrib2dv(gl.funcs, C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib2d.xml
+func (gl *GL) VertexAttrib2d(index glbase.Attrib, x, y float64) {
+ C.gl2_0_glVertexAttrib2d(gl.funcs, C.GLuint(index), C.GLdouble(x), C.GLdouble(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib1sv.xml
+func (gl *GL) VertexAttrib1sv(index glbase.Attrib, v []int16) {
+ C.gl2_0_glVertexAttrib1sv(gl.funcs, C.GLuint(index), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib1s.xml
+func (gl *GL) VertexAttrib1s(index glbase.Attrib, x int16) {
+ C.gl2_0_glVertexAttrib1s(gl.funcs, C.GLuint(index), C.GLshort(x))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib1fv.xml
+func (gl *GL) VertexAttrib1fv(index glbase.Attrib, v []float32) {
+ C.gl2_0_glVertexAttrib1fv(gl.funcs, C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib1f.xml
+func (gl *GL) VertexAttrib1f(index glbase.Attrib, x float32) {
+ C.gl2_0_glVertexAttrib1f(gl.funcs, C.GLuint(index), C.GLfloat(x))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib1dv.xml
+func (gl *GL) VertexAttrib1dv(index glbase.Attrib, v []float64) {
+ C.gl2_0_glVertexAttrib1dv(gl.funcs, C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib1d.xml
+func (gl *GL) VertexAttrib1d(index glbase.Attrib, x float64) {
+ C.gl2_0_glVertexAttrib1d(gl.funcs, C.GLuint(index), C.GLdouble(x))
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/2.1/funcs.cpp b/Godeps/_workspace/src/github.com/obscuren/qml/gl/2.1/funcs.cpp
new file mode 100644
index 000000000..6235d6e81
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/2.1/funcs.cpp
@@ -0,0 +1,3480 @@
+
+// ** file automatically generated by glgen -- do not edit manually **
+
+#include <QOpenGLContext>
+#include <QtGui/qopenglfunctions_2_1.h>
+
+#include "funcs.h"
+
+void *gl2_1_funcs() {
+ QOpenGLFunctions_2_1* funcs = QOpenGLContext::currentContext()->versionFunctions<QOpenGLFunctions_2_1>();
+ if (!funcs) {
+ return 0;
+ }
+ funcs->initializeOpenGLFunctions();
+ return funcs;
+}
+
+
+void gl2_1_glViewport(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glViewport(x, y, width, height);
+}
+
+void gl2_1_glDepthRange(void *_glfuncs, GLdouble nearVal, GLdouble farVal)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glDepthRange(nearVal, farVal);
+}
+
+GLboolean gl2_1_glIsEnabled(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ return _qglfuncs->glIsEnabled(cap);
+}
+
+void gl2_1_glGetTexLevelParameteriv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glGetTexLevelParameteriv(target, level, pname, params);
+}
+
+void gl2_1_glGetTexLevelParameterfv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glGetTexLevelParameterfv(target, level, pname, params);
+}
+
+void gl2_1_glGetTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glGetTexParameteriv(target, pname, params);
+}
+
+void gl2_1_glGetTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glGetTexParameterfv(target, pname, params);
+}
+
+void gl2_1_glGetTexImage(void *_glfuncs, GLenum target, GLint level, GLenum format, GLenum gltype, GLvoid* pixels)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glGetTexImage(target, level, format, gltype, pixels);
+}
+
+void gl2_1_glGetIntegerv(void *_glfuncs, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glGetIntegerv(pname, params);
+}
+
+void gl2_1_glGetFloatv(void *_glfuncs, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glGetFloatv(pname, params);
+}
+
+GLenum gl2_1_glGetError(void *_glfuncs)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ return _qglfuncs->glGetError();
+}
+
+void gl2_1_glGetDoublev(void *_glfuncs, GLenum pname, GLdouble* params)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glGetDoublev(pname, params);
+}
+
+void gl2_1_glGetBooleanv(void *_glfuncs, GLenum pname, GLboolean* params)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glGetBooleanv(pname, params);
+}
+
+void gl2_1_glReadPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum gltype, GLvoid* pixels)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glReadPixels(x, y, width, height, format, gltype, pixels);
+}
+
+void gl2_1_glReadBuffer(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glReadBuffer(mode);
+}
+
+void gl2_1_glPixelStorei(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glPixelStorei(pname, param);
+}
+
+void gl2_1_glPixelStoref(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glPixelStoref(pname, param);
+}
+
+void gl2_1_glDepthFunc(void *_glfuncs, GLenum glfunc)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glDepthFunc(glfunc);
+}
+
+void gl2_1_glStencilOp(void *_glfuncs, GLenum fail, GLenum zfail, GLenum zpass)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glStencilOp(fail, zfail, zpass);
+}
+
+void gl2_1_glStencilFunc(void *_glfuncs, GLenum glfunc, GLint ref, GLuint mask)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glStencilFunc(glfunc, ref, mask);
+}
+
+void gl2_1_glLogicOp(void *_glfuncs, GLenum opcode)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glLogicOp(opcode);
+}
+
+void gl2_1_glBlendFunc(void *_glfuncs, GLenum sfactor, GLenum dfactor)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glBlendFunc(sfactor, dfactor);
+}
+
+void gl2_1_glFlush(void *_glfuncs)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glFlush();
+}
+
+void gl2_1_glFinish(void *_glfuncs)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glFinish();
+}
+
+void gl2_1_glEnable(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glEnable(cap);
+}
+
+void gl2_1_glDisable(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glDisable(cap);
+}
+
+void gl2_1_glDepthMask(void *_glfuncs, GLboolean flag)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glDepthMask(flag);
+}
+
+void gl2_1_glColorMask(void *_glfuncs, GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glColorMask(red, green, blue, alpha);
+}
+
+void gl2_1_glStencilMask(void *_glfuncs, GLuint mask)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glStencilMask(mask);
+}
+
+void gl2_1_glClearDepth(void *_glfuncs, GLdouble depth)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glClearDepth(depth);
+}
+
+void gl2_1_glClearStencil(void *_glfuncs, GLint s)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glClearStencil(s);
+}
+
+void gl2_1_glClearColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glClearColor(red, green, blue, alpha);
+}
+
+void gl2_1_glClear(void *_glfuncs, GLbitfield mask)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glClear(mask);
+}
+
+void gl2_1_glDrawBuffer(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glDrawBuffer(mode);
+}
+
+void gl2_1_glTexImage2D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glTexImage2D(target, level, internalFormat, width, height, border, format, gltype, pixels);
+}
+
+void gl2_1_glTexImage1D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glTexImage1D(target, level, internalFormat, width, border, format, gltype, pixels);
+}
+
+void gl2_1_glTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glTexParameteriv(target, pname, params);
+}
+
+void gl2_1_glTexParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glTexParameteri(target, pname, param);
+}
+
+void gl2_1_glTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glTexParameterfv(target, pname, params);
+}
+
+void gl2_1_glTexParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glTexParameterf(target, pname, param);
+}
+
+void gl2_1_glScissor(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glScissor(x, y, width, height);
+}
+
+void gl2_1_glPolygonMode(void *_glfuncs, GLenum face, GLenum mode)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glPolygonMode(face, mode);
+}
+
+void gl2_1_glPointSize(void *_glfuncs, GLfloat size)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glPointSize(size);
+}
+
+void gl2_1_glLineWidth(void *_glfuncs, GLfloat width)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glLineWidth(width);
+}
+
+void gl2_1_glHint(void *_glfuncs, GLenum target, GLenum mode)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glHint(target, mode);
+}
+
+void gl2_1_glFrontFace(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glFrontFace(mode);
+}
+
+void gl2_1_glCullFace(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glCullFace(mode);
+}
+
+void gl2_1_glIndexubv(void *_glfuncs, const GLubyte* c)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glIndexubv(c);
+}
+
+void gl2_1_glIndexub(void *_glfuncs, GLubyte c)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glIndexub(c);
+}
+
+GLboolean gl2_1_glIsTexture(void *_glfuncs, GLuint texture)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ return _qglfuncs->glIsTexture(texture);
+}
+
+void gl2_1_glGenTextures(void *_glfuncs, GLsizei n, GLuint* textures)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glGenTextures(n, textures);
+}
+
+void gl2_1_glDeleteTextures(void *_glfuncs, GLsizei n, const GLuint* textures)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glDeleteTextures(n, textures);
+}
+
+void gl2_1_glBindTexture(void *_glfuncs, GLenum target, GLuint texture)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glBindTexture(target, texture);
+}
+
+void gl2_1_glTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glTexSubImage2D(target, level, xoffset, yoffset, width, height, format, gltype, pixels);
+}
+
+void gl2_1_glTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glTexSubImage1D(target, level, xoffset, width, format, gltype, pixels);
+}
+
+void gl2_1_glCopyTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage2D(target, level, xoffset, yoffset, x, y, width, height);
+}
+
+void gl2_1_glCopyTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage1D(target, level, xoffset, x, y, width);
+}
+
+void gl2_1_glCopyTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glCopyTexImage2D(target, level, internalFormat, x, y, width, height, border);
+}
+
+void gl2_1_glCopyTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLint border)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glCopyTexImage1D(target, level, internalFormat, x, y, width, border);
+}
+
+void gl2_1_glPolygonOffset(void *_glfuncs, GLfloat factor, GLfloat units)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glPolygonOffset(factor, units);
+}
+
+void gl2_1_glDrawElements(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glDrawElements(mode, count, gltype, indices);
+}
+
+void gl2_1_glDrawArrays(void *_glfuncs, GLenum mode, GLint first, GLsizei count)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glDrawArrays(mode, first, count);
+}
+
+void gl2_1_glCopyTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage3D(target, level, xoffset, yoffset, zoffset, x, y, width, height);
+}
+
+void gl2_1_glTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glTexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, gltype, pixels);
+}
+
+void gl2_1_glTexImage3D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glTexImage3D(target, level, internalFormat, width, height, depth, border, format, gltype, pixels);
+}
+
+void gl2_1_glDrawRangeElements(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glDrawRangeElements(mode, start, end, count, gltype, indices);
+}
+
+void gl2_1_glBlendEquation(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glBlendEquation(mode);
+}
+
+void gl2_1_glBlendColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glBlendColor(red, green, blue, alpha);
+}
+
+void gl2_1_glGetCompressedTexImage(void *_glfuncs, GLenum target, GLint level, GLvoid* img)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glGetCompressedTexImage(target, level, img);
+}
+
+void gl2_1_glCompressedTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glCompressedTexSubImage1D(target, level, xoffset, width, format, imageSize, data);
+}
+
+void gl2_1_glCompressedTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glCompressedTexSubImage2D(target, level, xoffset, yoffset, width, height, format, imageSize, data);
+}
+
+void gl2_1_glCompressedTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glCompressedTexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, imageSize, data);
+}
+
+void gl2_1_glCompressedTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glCompressedTexImage1D(target, level, internalFormat, width, border, imageSize, data);
+}
+
+void gl2_1_glCompressedTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glCompressedTexImage2D(target, level, internalFormat, width, height, border, imageSize, data);
+}
+
+void gl2_1_glCompressedTexImage3D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glCompressedTexImage3D(target, level, internalFormat, width, height, depth, border, imageSize, data);
+}
+
+void gl2_1_glSampleCoverage(void *_glfuncs, GLfloat value, GLboolean invert)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glSampleCoverage(value, invert);
+}
+
+void gl2_1_glActiveTexture(void *_glfuncs, GLenum texture)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glActiveTexture(texture);
+}
+
+void gl2_1_glPointParameteriv(void *_glfuncs, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glPointParameteriv(pname, params);
+}
+
+void gl2_1_glPointParameteri(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glPointParameteri(pname, param);
+}
+
+void gl2_1_glPointParameterfv(void *_glfuncs, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glPointParameterfv(pname, params);
+}
+
+void gl2_1_glPointParameterf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glPointParameterf(pname, param);
+}
+
+void gl2_1_glMultiDrawArrays(void *_glfuncs, GLenum mode, const GLint* first, const GLsizei* count, GLsizei drawcount)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glMultiDrawArrays(mode, first, count, drawcount);
+}
+
+void gl2_1_glBlendFuncSeparate(void *_glfuncs, GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glBlendFuncSeparate(sfactorRGB, dfactorRGB, sfactorAlpha, dfactorAlpha);
+}
+
+void gl2_1_glGetBufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glGetBufferParameteriv(target, pname, params);
+}
+
+GLboolean gl2_1_glUnmapBuffer(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ return _qglfuncs->glUnmapBuffer(target);
+}
+
+void gl2_1_glGetBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, GLvoid* data)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glGetBufferSubData(target, offset, size, data);
+}
+
+void gl2_1_glBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid* data)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glBufferSubData(target, offset, size, data);
+}
+
+void gl2_1_glBufferData(void *_glfuncs, GLenum target, GLsizeiptr size, const GLvoid* data, GLenum usage)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glBufferData(target, size, data, usage);
+}
+
+GLboolean gl2_1_glIsBuffer(void *_glfuncs, GLuint buffer)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ return _qglfuncs->glIsBuffer(buffer);
+}
+
+void gl2_1_glGenBuffers(void *_glfuncs, GLsizei n, GLuint* buffers)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glGenBuffers(n, buffers);
+}
+
+void gl2_1_glDeleteBuffers(void *_glfuncs, GLsizei n, const GLuint* buffers)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glDeleteBuffers(n, buffers);
+}
+
+void gl2_1_glBindBuffer(void *_glfuncs, GLenum target, GLuint buffer)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glBindBuffer(target, buffer);
+}
+
+void gl2_1_glGetQueryObjectuiv(void *_glfuncs, GLuint id, GLenum pname, GLuint* params)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glGetQueryObjectuiv(id, pname, params);
+}
+
+void gl2_1_glGetQueryObjectiv(void *_glfuncs, GLuint id, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glGetQueryObjectiv(id, pname, params);
+}
+
+void gl2_1_glGetQueryiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glGetQueryiv(target, pname, params);
+}
+
+void gl2_1_glEndQuery(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glEndQuery(target);
+}
+
+void gl2_1_glBeginQuery(void *_glfuncs, GLenum target, GLuint id)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glBeginQuery(target, id);
+}
+
+GLboolean gl2_1_glIsQuery(void *_glfuncs, GLuint id)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ return _qglfuncs->glIsQuery(id);
+}
+
+void gl2_1_glDeleteQueries(void *_glfuncs, GLsizei n, const GLuint* ids)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glDeleteQueries(n, ids);
+}
+
+void gl2_1_glGenQueries(void *_glfuncs, GLsizei n, GLuint* ids)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glGenQueries(n, ids);
+}
+
+void gl2_1_glVertexAttribPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLboolean normalized, GLsizei stride, const GLvoid* offset)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertexAttribPointer(index, size, gltype, normalized, stride, offset);
+}
+
+void gl2_1_glValidateProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glValidateProgram(program);
+}
+
+void gl2_1_glUniformMatrix4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4fv(location, count, transpose, value);
+}
+
+void gl2_1_glUniformMatrix3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3fv(location, count, transpose, value);
+}
+
+void gl2_1_glUniformMatrix2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2fv(location, count, transpose, value);
+}
+
+void gl2_1_glUniform4iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glUniform4iv(location, count, value);
+}
+
+void gl2_1_glUniform3iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glUniform3iv(location, count, value);
+}
+
+void gl2_1_glUniform2iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glUniform2iv(location, count, value);
+}
+
+void gl2_1_glUniform1iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glUniform1iv(location, count, value);
+}
+
+void gl2_1_glUniform4fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glUniform4fv(location, count, value);
+}
+
+void gl2_1_glUniform3fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glUniform3fv(location, count, value);
+}
+
+void gl2_1_glUniform2fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glUniform2fv(location, count, value);
+}
+
+void gl2_1_glUniform1fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glUniform1fv(location, count, value);
+}
+
+void gl2_1_glUniform4i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2, GLint v3)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glUniform4i(location, v0, v1, v2, v3);
+}
+
+void gl2_1_glUniform3i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glUniform3i(location, v0, v1, v2);
+}
+
+void gl2_1_glUniform2i(void *_glfuncs, GLint location, GLint v0, GLint v1)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glUniform2i(location, v0, v1);
+}
+
+void gl2_1_glUniform1i(void *_glfuncs, GLint location, GLint v0)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glUniform1i(location, v0);
+}
+
+void gl2_1_glUniform4f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glUniform4f(location, v0, v1, v2, v3);
+}
+
+void gl2_1_glUniform3f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glUniform3f(location, v0, v1, v2);
+}
+
+void gl2_1_glUniform2f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glUniform2f(location, v0, v1);
+}
+
+void gl2_1_glUniform1f(void *_glfuncs, GLint location, GLfloat v0)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glUniform1f(location, v0);
+}
+
+void gl2_1_glUseProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glUseProgram(program);
+}
+
+void gl2_1_glShaderSource(void *_glfuncs, GLuint shader, GLsizei count, const GLchar** source, const GLint* length)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glShaderSource(shader, count, source, length);
+}
+
+void gl2_1_glLinkProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glLinkProgram(program);
+}
+
+GLboolean gl2_1_glIsShader(void *_glfuncs, GLuint shader)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ return _qglfuncs->glIsShader(shader);
+}
+
+GLboolean gl2_1_glIsProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ return _qglfuncs->glIsProgram(program);
+}
+
+void gl2_1_glGetVertexAttribiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribiv(index, pname, params);
+}
+
+void gl2_1_glGetVertexAttribfv(void *_glfuncs, GLuint index, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribfv(index, pname, params);
+}
+
+void gl2_1_glGetVertexAttribdv(void *_glfuncs, GLuint index, GLenum pname, GLdouble* params)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribdv(index, pname, params);
+}
+
+void gl2_1_glGetUniformiv(void *_glfuncs, GLuint program, GLint location, GLint* params)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glGetUniformiv(program, location, params);
+}
+
+void gl2_1_glGetUniformfv(void *_glfuncs, GLuint program, GLint location, GLfloat* params)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glGetUniformfv(program, location, params);
+}
+
+GLint gl2_1_glGetUniformLocation(void *_glfuncs, GLuint program, const GLchar* name)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ return _qglfuncs->glGetUniformLocation(program, name);
+}
+
+void gl2_1_glGetShaderSource(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* source)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glGetShaderSource(shader, bufSize, length, source);
+}
+
+void gl2_1_glGetShaderInfoLog(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* infoLog)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glGetShaderInfoLog(shader, bufSize, length, infoLog);
+}
+
+void gl2_1_glGetShaderiv(void *_glfuncs, GLuint shader, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glGetShaderiv(shader, pname, params);
+}
+
+void gl2_1_glGetProgramInfoLog(void *_glfuncs, GLuint program, GLsizei bufSize, GLsizei* length, GLchar* infoLog)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glGetProgramInfoLog(program, bufSize, length, infoLog);
+}
+
+void gl2_1_glGetProgramiv(void *_glfuncs, GLuint program, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glGetProgramiv(program, pname, params);
+}
+
+GLint gl2_1_glGetAttribLocation(void *_glfuncs, GLuint program, const GLchar* name)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ return _qglfuncs->glGetAttribLocation(program, name);
+}
+
+void gl2_1_glGetAttachedShaders(void *_glfuncs, GLuint program, GLsizei maxCount, GLsizei* count, GLuint* obj)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glGetAttachedShaders(program, maxCount, count, obj);
+}
+
+void gl2_1_glGetActiveUniform(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glGetActiveUniform(program, index, bufSize, length, size, gltype, name);
+}
+
+void gl2_1_glGetActiveAttrib(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glGetActiveAttrib(program, index, bufSize, length, size, gltype, name);
+}
+
+void gl2_1_glEnableVertexAttribArray(void *_glfuncs, GLuint index)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glEnableVertexAttribArray(index);
+}
+
+void gl2_1_glDisableVertexAttribArray(void *_glfuncs, GLuint index)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glDisableVertexAttribArray(index);
+}
+
+void gl2_1_glDetachShader(void *_glfuncs, GLuint program, GLuint shader)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glDetachShader(program, shader);
+}
+
+void gl2_1_glDeleteShader(void *_glfuncs, GLuint shader)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glDeleteShader(shader);
+}
+
+void gl2_1_glDeleteProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glDeleteProgram(program);
+}
+
+GLuint gl2_1_glCreateShader(void *_glfuncs, GLenum gltype)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ return _qglfuncs->glCreateShader(gltype);
+}
+
+GLuint gl2_1_glCreateProgram(void *_glfuncs)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ return _qglfuncs->glCreateProgram();
+}
+
+void gl2_1_glCompileShader(void *_glfuncs, GLuint shader)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glCompileShader(shader);
+}
+
+void gl2_1_glBindAttribLocation(void *_glfuncs, GLuint program, GLuint index, const GLchar* name)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glBindAttribLocation(program, index, name);
+}
+
+void gl2_1_glAttachShader(void *_glfuncs, GLuint program, GLuint shader)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glAttachShader(program, shader);
+}
+
+void gl2_1_glStencilMaskSeparate(void *_glfuncs, GLenum face, GLuint mask)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glStencilMaskSeparate(face, mask);
+}
+
+void gl2_1_glStencilFuncSeparate(void *_glfuncs, GLenum face, GLenum glfunc, GLint ref, GLuint mask)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glStencilFuncSeparate(face, glfunc, ref, mask);
+}
+
+void gl2_1_glStencilOpSeparate(void *_glfuncs, GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glStencilOpSeparate(face, sfail, dpfail, dppass);
+}
+
+void gl2_1_glDrawBuffers(void *_glfuncs, GLsizei n, const GLenum* bufs)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glDrawBuffers(n, bufs);
+}
+
+void gl2_1_glBlendEquationSeparate(void *_glfuncs, GLenum modeRGB, GLenum modeAlpha)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glBlendEquationSeparate(modeRGB, modeAlpha);
+}
+
+void gl2_1_glUniformMatrix4x3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4x3fv(location, count, transpose, value);
+}
+
+void gl2_1_glUniformMatrix3x4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3x4fv(location, count, transpose, value);
+}
+
+void gl2_1_glUniformMatrix4x2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4x2fv(location, count, transpose, value);
+}
+
+void gl2_1_glUniformMatrix2x4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2x4fv(location, count, transpose, value);
+}
+
+void gl2_1_glUniformMatrix3x2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3x2fv(location, count, transpose, value);
+}
+
+void gl2_1_glUniformMatrix2x3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2x3fv(location, count, transpose, value);
+}
+
+void gl2_1_glTranslatef(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glTranslatef(x, y, z);
+}
+
+void gl2_1_glTranslated(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glTranslated(x, y, z);
+}
+
+void gl2_1_glScalef(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glScalef(x, y, z);
+}
+
+void gl2_1_glScaled(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glScaled(x, y, z);
+}
+
+void gl2_1_glRotatef(void *_glfuncs, GLfloat angle, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glRotatef(angle, x, y, z);
+}
+
+void gl2_1_glRotated(void *_glfuncs, GLdouble angle, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glRotated(angle, x, y, z);
+}
+
+void gl2_1_glPushMatrix(void *_glfuncs)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glPushMatrix();
+}
+
+void gl2_1_glPopMatrix(void *_glfuncs)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glPopMatrix();
+}
+
+void gl2_1_glOrtho(void *_glfuncs, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glOrtho(left, right, bottom, top, zNear, zFar);
+}
+
+void gl2_1_glMultMatrixd(void *_glfuncs, const GLdouble* m)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glMultMatrixd(m);
+}
+
+void gl2_1_glMultMatrixf(void *_glfuncs, const GLfloat* m)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glMultMatrixf(m);
+}
+
+void gl2_1_glMatrixMode(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glMatrixMode(mode);
+}
+
+void gl2_1_glLoadMatrixd(void *_glfuncs, const GLdouble* m)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glLoadMatrixd(m);
+}
+
+void gl2_1_glLoadMatrixf(void *_glfuncs, const GLfloat* m)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glLoadMatrixf(m);
+}
+
+void gl2_1_glLoadIdentity(void *_glfuncs)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glLoadIdentity();
+}
+
+void gl2_1_glFrustum(void *_glfuncs, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glFrustum(left, right, bottom, top, zNear, zFar);
+}
+
+GLboolean gl2_1_glIsList(void *_glfuncs, GLuint list)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ return _qglfuncs->glIsList(list);
+}
+
+void gl2_1_glGetTexGeniv(void *_glfuncs, GLenum coord, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glGetTexGeniv(coord, pname, params);
+}
+
+void gl2_1_glGetTexGenfv(void *_glfuncs, GLenum coord, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glGetTexGenfv(coord, pname, params);
+}
+
+void gl2_1_glGetTexGendv(void *_glfuncs, GLenum coord, GLenum pname, GLdouble* params)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glGetTexGendv(coord, pname, params);
+}
+
+void gl2_1_glGetTexEnviv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glGetTexEnviv(target, pname, params);
+}
+
+void gl2_1_glGetTexEnvfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glGetTexEnvfv(target, pname, params);
+}
+
+void gl2_1_glGetPolygonStipple(void *_glfuncs, GLubyte* mask)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glGetPolygonStipple(mask);
+}
+
+void gl2_1_glGetPixelMapusv(void *_glfuncs, GLenum glmap, GLushort* values)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glGetPixelMapusv(glmap, values);
+}
+
+void gl2_1_glGetPixelMapuiv(void *_glfuncs, GLenum glmap, GLuint* values)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glGetPixelMapuiv(glmap, values);
+}
+
+void gl2_1_glGetPixelMapfv(void *_glfuncs, GLenum glmap, GLfloat* values)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glGetPixelMapfv(glmap, values);
+}
+
+void gl2_1_glGetMaterialiv(void *_glfuncs, GLenum face, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glGetMaterialiv(face, pname, params);
+}
+
+void gl2_1_glGetMaterialfv(void *_glfuncs, GLenum face, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glGetMaterialfv(face, pname, params);
+}
+
+void gl2_1_glGetMapiv(void *_glfuncs, GLenum target, GLenum query, GLint* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glGetMapiv(target, query, v);
+}
+
+void gl2_1_glGetMapfv(void *_glfuncs, GLenum target, GLenum query, GLfloat* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glGetMapfv(target, query, v);
+}
+
+void gl2_1_glGetMapdv(void *_glfuncs, GLenum target, GLenum query, GLdouble* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glGetMapdv(target, query, v);
+}
+
+void gl2_1_glGetLightiv(void *_glfuncs, GLenum light, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glGetLightiv(light, pname, params);
+}
+
+void gl2_1_glGetLightfv(void *_glfuncs, GLenum light, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glGetLightfv(light, pname, params);
+}
+
+void gl2_1_glGetClipPlane(void *_glfuncs, GLenum plane, GLdouble* equation)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glGetClipPlane(plane, equation);
+}
+
+void gl2_1_glDrawPixels(void *_glfuncs, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glDrawPixels(width, height, format, gltype, pixels);
+}
+
+void gl2_1_glCopyPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum gltype)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glCopyPixels(x, y, width, height, gltype);
+}
+
+void gl2_1_glPixelMapusv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLushort* values)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glPixelMapusv(glmap, mapsize, values);
+}
+
+void gl2_1_glPixelMapuiv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLuint* values)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glPixelMapuiv(glmap, mapsize, values);
+}
+
+void gl2_1_glPixelMapfv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLfloat* values)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glPixelMapfv(glmap, mapsize, values);
+}
+
+void gl2_1_glPixelTransferi(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glPixelTransferi(pname, param);
+}
+
+void gl2_1_glPixelTransferf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glPixelTransferf(pname, param);
+}
+
+void gl2_1_glPixelZoom(void *_glfuncs, GLfloat xfactor, GLfloat yfactor)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glPixelZoom(xfactor, yfactor);
+}
+
+void gl2_1_glAlphaFunc(void *_glfuncs, GLenum glfunc, GLfloat ref)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glAlphaFunc(glfunc, ref);
+}
+
+void gl2_1_glEvalPoint2(void *_glfuncs, GLint i, GLint j)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glEvalPoint2(i, j);
+}
+
+void gl2_1_glEvalMesh2(void *_glfuncs, GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glEvalMesh2(mode, i1, i2, j1, j2);
+}
+
+void gl2_1_glEvalPoint1(void *_glfuncs, GLint i)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glEvalPoint1(i);
+}
+
+void gl2_1_glEvalMesh1(void *_glfuncs, GLenum mode, GLint i1, GLint i2)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glEvalMesh1(mode, i1, i2);
+}
+
+void gl2_1_glEvalCoord2fv(void *_glfuncs, const GLfloat* u)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glEvalCoord2fv(u);
+}
+
+void gl2_1_glEvalCoord2f(void *_glfuncs, GLfloat u, GLfloat v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glEvalCoord2f(u, v);
+}
+
+void gl2_1_glEvalCoord2dv(void *_glfuncs, const GLdouble* u)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glEvalCoord2dv(u);
+}
+
+void gl2_1_glEvalCoord2d(void *_glfuncs, GLdouble u, GLdouble v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glEvalCoord2d(u, v);
+}
+
+void gl2_1_glEvalCoord1fv(void *_glfuncs, const GLfloat* u)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glEvalCoord1fv(u);
+}
+
+void gl2_1_glEvalCoord1f(void *_glfuncs, GLfloat u)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glEvalCoord1f(u);
+}
+
+void gl2_1_glEvalCoord1dv(void *_glfuncs, const GLdouble* u)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glEvalCoord1dv(u);
+}
+
+void gl2_1_glEvalCoord1d(void *_glfuncs, GLdouble u)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glEvalCoord1d(u);
+}
+
+void gl2_1_glMapGrid2f(void *_glfuncs, GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glMapGrid2f(un, u1, u2, vn, v1, v2);
+}
+
+void gl2_1_glMapGrid2d(void *_glfuncs, GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glMapGrid2d(un, u1, u2, vn, v1, v2);
+}
+
+void gl2_1_glMapGrid1f(void *_glfuncs, GLint un, GLfloat u1, GLfloat u2)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glMapGrid1f(un, u1, u2);
+}
+
+void gl2_1_glMapGrid1d(void *_glfuncs, GLint un, GLdouble u1, GLdouble u2)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glMapGrid1d(un, u1, u2);
+}
+
+void gl2_1_glMap2f(void *_glfuncs, GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat* points)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glMap2f(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+void gl2_1_glMap2d(void *_glfuncs, GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble* points)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glMap2d(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+void gl2_1_glMap1f(void *_glfuncs, GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat* points)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glMap1f(target, u1, u2, stride, order, points);
+}
+
+void gl2_1_glMap1d(void *_glfuncs, GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble* points)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glMap1d(target, u1, u2, stride, order, points);
+}
+
+void gl2_1_glPushAttrib(void *_glfuncs, GLbitfield mask)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glPushAttrib(mask);
+}
+
+void gl2_1_glPopAttrib(void *_glfuncs)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glPopAttrib();
+}
+
+void gl2_1_glAccum(void *_glfuncs, GLenum op, GLfloat value)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glAccum(op, value);
+}
+
+void gl2_1_glIndexMask(void *_glfuncs, GLuint mask)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glIndexMask(mask);
+}
+
+void gl2_1_glClearIndex(void *_glfuncs, GLfloat c)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glClearIndex(c);
+}
+
+void gl2_1_glClearAccum(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glClearAccum(red, green, blue, alpha);
+}
+
+void gl2_1_glPushName(void *_glfuncs, GLuint name)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glPushName(name);
+}
+
+void gl2_1_glPopName(void *_glfuncs)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glPopName();
+}
+
+void gl2_1_glPassThrough(void *_glfuncs, GLfloat token)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glPassThrough(token);
+}
+
+void gl2_1_glLoadName(void *_glfuncs, GLuint name)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glLoadName(name);
+}
+
+void gl2_1_glInitNames(void *_glfuncs)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glInitNames();
+}
+
+GLint gl2_1_glRenderMode(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ return _qglfuncs->glRenderMode(mode);
+}
+
+void gl2_1_glSelectBuffer(void *_glfuncs, GLsizei size, GLuint* buffer)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glSelectBuffer(size, buffer);
+}
+
+void gl2_1_glFeedbackBuffer(void *_glfuncs, GLsizei size, GLenum gltype, GLfloat* buffer)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glFeedbackBuffer(size, gltype, buffer);
+}
+
+void gl2_1_glTexGeniv(void *_glfuncs, GLenum coord, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glTexGeniv(coord, pname, params);
+}
+
+void gl2_1_glTexGeni(void *_glfuncs, GLenum coord, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glTexGeni(coord, pname, param);
+}
+
+void gl2_1_glTexGenfv(void *_glfuncs, GLenum coord, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glTexGenfv(coord, pname, params);
+}
+
+void gl2_1_glTexGenf(void *_glfuncs, GLenum coord, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glTexGenf(coord, pname, param);
+}
+
+void gl2_1_glTexGendv(void *_glfuncs, GLenum coord, GLenum pname, const GLdouble* params)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glTexGendv(coord, pname, params);
+}
+
+void gl2_1_glTexGend(void *_glfuncs, GLenum coord, GLenum pname, GLdouble param)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glTexGend(coord, pname, param);
+}
+
+void gl2_1_glTexEnviv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glTexEnviv(target, pname, params);
+}
+
+void gl2_1_glTexEnvi(void *_glfuncs, GLenum target, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glTexEnvi(target, pname, param);
+}
+
+void gl2_1_glTexEnvfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glTexEnvfv(target, pname, params);
+}
+
+void gl2_1_glTexEnvf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glTexEnvf(target, pname, param);
+}
+
+void gl2_1_glShadeModel(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glShadeModel(mode);
+}
+
+void gl2_1_glPolygonStipple(void *_glfuncs, const GLubyte* mask)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glPolygonStipple(mask);
+}
+
+void gl2_1_glMaterialiv(void *_glfuncs, GLenum face, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glMaterialiv(face, pname, params);
+}
+
+void gl2_1_glMateriali(void *_glfuncs, GLenum face, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glMateriali(face, pname, param);
+}
+
+void gl2_1_glMaterialfv(void *_glfuncs, GLenum face, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glMaterialfv(face, pname, params);
+}
+
+void gl2_1_glMaterialf(void *_glfuncs, GLenum face, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glMaterialf(face, pname, param);
+}
+
+void gl2_1_glLineStipple(void *_glfuncs, GLint factor, GLushort pattern)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glLineStipple(factor, pattern);
+}
+
+void gl2_1_glLightModeliv(void *_glfuncs, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glLightModeliv(pname, params);
+}
+
+void gl2_1_glLightModeli(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glLightModeli(pname, param);
+}
+
+void gl2_1_glLightModelfv(void *_glfuncs, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glLightModelfv(pname, params);
+}
+
+void gl2_1_glLightModelf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glLightModelf(pname, param);
+}
+
+void gl2_1_glLightiv(void *_glfuncs, GLenum light, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glLightiv(light, pname, params);
+}
+
+void gl2_1_glLighti(void *_glfuncs, GLenum light, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glLighti(light, pname, param);
+}
+
+void gl2_1_glLightfv(void *_glfuncs, GLenum light, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glLightfv(light, pname, params);
+}
+
+void gl2_1_glLightf(void *_glfuncs, GLenum light, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glLightf(light, pname, param);
+}
+
+void gl2_1_glFogiv(void *_glfuncs, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glFogiv(pname, params);
+}
+
+void gl2_1_glFogi(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glFogi(pname, param);
+}
+
+void gl2_1_glFogfv(void *_glfuncs, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glFogfv(pname, params);
+}
+
+void gl2_1_glFogf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glFogf(pname, param);
+}
+
+void gl2_1_glColorMaterial(void *_glfuncs, GLenum face, GLenum mode)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glColorMaterial(face, mode);
+}
+
+void gl2_1_glClipPlane(void *_glfuncs, GLenum plane, const GLdouble* equation)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glClipPlane(plane, equation);
+}
+
+void gl2_1_glVertex4sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertex4sv(v);
+}
+
+void gl2_1_glVertex4s(void *_glfuncs, GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertex4s(x, y, z, w);
+}
+
+void gl2_1_glVertex4iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertex4iv(v);
+}
+
+void gl2_1_glVertex4i(void *_glfuncs, GLint x, GLint y, GLint z, GLint w)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertex4i(x, y, z, w);
+}
+
+void gl2_1_glVertex4fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertex4fv(v);
+}
+
+void gl2_1_glVertex4f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertex4f(x, y, z, w);
+}
+
+void gl2_1_glVertex4dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertex4dv(v);
+}
+
+void gl2_1_glVertex4d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertex4d(x, y, z, w);
+}
+
+void gl2_1_glVertex3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertex3sv(v);
+}
+
+void gl2_1_glVertex3s(void *_glfuncs, GLshort x, GLshort y, GLshort z)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertex3s(x, y, z);
+}
+
+void gl2_1_glVertex3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertex3iv(v);
+}
+
+void gl2_1_glVertex3i(void *_glfuncs, GLint x, GLint y, GLint z)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertex3i(x, y, z);
+}
+
+void gl2_1_glVertex3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertex3fv(v);
+}
+
+void gl2_1_glVertex3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertex3f(x, y, z);
+}
+
+void gl2_1_glVertex3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertex3dv(v);
+}
+
+void gl2_1_glVertex3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertex3d(x, y, z);
+}
+
+void gl2_1_glVertex2sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertex2sv(v);
+}
+
+void gl2_1_glVertex2s(void *_glfuncs, GLshort x, GLshort y)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertex2s(x, y);
+}
+
+void gl2_1_glVertex2iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertex2iv(v);
+}
+
+void gl2_1_glVertex2i(void *_glfuncs, GLint x, GLint y)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertex2i(x, y);
+}
+
+void gl2_1_glVertex2fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertex2fv(v);
+}
+
+void gl2_1_glVertex2f(void *_glfuncs, GLfloat x, GLfloat y)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertex2f(x, y);
+}
+
+void gl2_1_glVertex2dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertex2dv(v);
+}
+
+void gl2_1_glVertex2d(void *_glfuncs, GLdouble x, GLdouble y)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertex2d(x, y);
+}
+
+void gl2_1_glTexCoord4sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glTexCoord4sv(v);
+}
+
+void gl2_1_glTexCoord4s(void *_glfuncs, GLshort s, GLshort t, GLshort r, GLshort q)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glTexCoord4s(s, t, r, q);
+}
+
+void gl2_1_glTexCoord4iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glTexCoord4iv(v);
+}
+
+void gl2_1_glTexCoord4i(void *_glfuncs, GLint s, GLint t, GLint r, GLint q)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glTexCoord4i(s, t, r, q);
+}
+
+void gl2_1_glTexCoord4fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glTexCoord4fv(v);
+}
+
+void gl2_1_glTexCoord4f(void *_glfuncs, GLfloat s, GLfloat t, GLfloat r, GLfloat q)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glTexCoord4f(s, t, r, q);
+}
+
+void gl2_1_glTexCoord4dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glTexCoord4dv(v);
+}
+
+void gl2_1_glTexCoord4d(void *_glfuncs, GLdouble s, GLdouble t, GLdouble r, GLdouble q)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glTexCoord4d(s, t, r, q);
+}
+
+void gl2_1_glTexCoord3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glTexCoord3sv(v);
+}
+
+void gl2_1_glTexCoord3s(void *_glfuncs, GLshort s, GLshort t, GLshort r)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glTexCoord3s(s, t, r);
+}
+
+void gl2_1_glTexCoord3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glTexCoord3iv(v);
+}
+
+void gl2_1_glTexCoord3i(void *_glfuncs, GLint s, GLint t, GLint r)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glTexCoord3i(s, t, r);
+}
+
+void gl2_1_glTexCoord3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glTexCoord3fv(v);
+}
+
+void gl2_1_glTexCoord3f(void *_glfuncs, GLfloat s, GLfloat t, GLfloat r)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glTexCoord3f(s, t, r);
+}
+
+void gl2_1_glTexCoord3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glTexCoord3dv(v);
+}
+
+void gl2_1_glTexCoord3d(void *_glfuncs, GLdouble s, GLdouble t, GLdouble r)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glTexCoord3d(s, t, r);
+}
+
+void gl2_1_glTexCoord2sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glTexCoord2sv(v);
+}
+
+void gl2_1_glTexCoord2s(void *_glfuncs, GLshort s, GLshort t)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glTexCoord2s(s, t);
+}
+
+void gl2_1_glTexCoord2iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glTexCoord2iv(v);
+}
+
+void gl2_1_glTexCoord2i(void *_glfuncs, GLint s, GLint t)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glTexCoord2i(s, t);
+}
+
+void gl2_1_glTexCoord2fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glTexCoord2fv(v);
+}
+
+void gl2_1_glTexCoord2f(void *_glfuncs, GLfloat s, GLfloat t)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glTexCoord2f(s, t);
+}
+
+void gl2_1_glTexCoord2dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glTexCoord2dv(v);
+}
+
+void gl2_1_glTexCoord2d(void *_glfuncs, GLdouble s, GLdouble t)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glTexCoord2d(s, t);
+}
+
+void gl2_1_glTexCoord1sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glTexCoord1sv(v);
+}
+
+void gl2_1_glTexCoord1s(void *_glfuncs, GLshort s)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glTexCoord1s(s);
+}
+
+void gl2_1_glTexCoord1iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glTexCoord1iv(v);
+}
+
+void gl2_1_glTexCoord1i(void *_glfuncs, GLint s)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glTexCoord1i(s);
+}
+
+void gl2_1_glTexCoord1fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glTexCoord1fv(v);
+}
+
+void gl2_1_glTexCoord1f(void *_glfuncs, GLfloat s)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glTexCoord1f(s);
+}
+
+void gl2_1_glTexCoord1dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glTexCoord1dv(v);
+}
+
+void gl2_1_glTexCoord1d(void *_glfuncs, GLdouble s)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glTexCoord1d(s);
+}
+
+void gl2_1_glRectsv(void *_glfuncs, const GLshort* v1, const GLshort* v2)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glRectsv(v1, v2);
+}
+
+void gl2_1_glRects(void *_glfuncs, GLshort x1, GLshort y1, GLshort x2, GLshort y2)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glRects(x1, y1, x2, y2);
+}
+
+void gl2_1_glRectiv(void *_glfuncs, const GLint* v1, const GLint* v2)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glRectiv(v1, v2);
+}
+
+void gl2_1_glRecti(void *_glfuncs, GLint x1, GLint y1, GLint x2, GLint y2)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glRecti(x1, y1, x2, y2);
+}
+
+void gl2_1_glRectfv(void *_glfuncs, const GLfloat* v1, const GLfloat* v2)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glRectfv(v1, v2);
+}
+
+void gl2_1_glRectf(void *_glfuncs, GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glRectf(x1, y1, x2, y2);
+}
+
+void gl2_1_glRectdv(void *_glfuncs, const GLdouble* v1, const GLdouble* v2)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glRectdv(v1, v2);
+}
+
+void gl2_1_glRectd(void *_glfuncs, GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glRectd(x1, y1, x2, y2);
+}
+
+void gl2_1_glRasterPos4sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glRasterPos4sv(v);
+}
+
+void gl2_1_glRasterPos4s(void *_glfuncs, GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glRasterPos4s(x, y, z, w);
+}
+
+void gl2_1_glRasterPos4iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glRasterPos4iv(v);
+}
+
+void gl2_1_glRasterPos4i(void *_glfuncs, GLint x, GLint y, GLint z, GLint w)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glRasterPos4i(x, y, z, w);
+}
+
+void gl2_1_glRasterPos4fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glRasterPos4fv(v);
+}
+
+void gl2_1_glRasterPos4f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glRasterPos4f(x, y, z, w);
+}
+
+void gl2_1_glRasterPos4dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glRasterPos4dv(v);
+}
+
+void gl2_1_glRasterPos4d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glRasterPos4d(x, y, z, w);
+}
+
+void gl2_1_glRasterPos3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glRasterPos3sv(v);
+}
+
+void gl2_1_glRasterPos3s(void *_glfuncs, GLshort x, GLshort y, GLshort z)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glRasterPos3s(x, y, z);
+}
+
+void gl2_1_glRasterPos3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glRasterPos3iv(v);
+}
+
+void gl2_1_glRasterPos3i(void *_glfuncs, GLint x, GLint y, GLint z)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glRasterPos3i(x, y, z);
+}
+
+void gl2_1_glRasterPos3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glRasterPos3fv(v);
+}
+
+void gl2_1_glRasterPos3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glRasterPos3f(x, y, z);
+}
+
+void gl2_1_glRasterPos3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glRasterPos3dv(v);
+}
+
+void gl2_1_glRasterPos3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glRasterPos3d(x, y, z);
+}
+
+void gl2_1_glRasterPos2sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glRasterPos2sv(v);
+}
+
+void gl2_1_glRasterPos2s(void *_glfuncs, GLshort x, GLshort y)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glRasterPos2s(x, y);
+}
+
+void gl2_1_glRasterPos2iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glRasterPos2iv(v);
+}
+
+void gl2_1_glRasterPos2i(void *_glfuncs, GLint x, GLint y)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glRasterPos2i(x, y);
+}
+
+void gl2_1_glRasterPos2fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glRasterPos2fv(v);
+}
+
+void gl2_1_glRasterPos2f(void *_glfuncs, GLfloat x, GLfloat y)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glRasterPos2f(x, y);
+}
+
+void gl2_1_glRasterPos2dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glRasterPos2dv(v);
+}
+
+void gl2_1_glRasterPos2d(void *_glfuncs, GLdouble x, GLdouble y)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glRasterPos2d(x, y);
+}
+
+void gl2_1_glNormal3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glNormal3sv(v);
+}
+
+void gl2_1_glNormal3s(void *_glfuncs, GLshort nx, GLshort ny, GLshort nz)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glNormal3s(nx, ny, nz);
+}
+
+void gl2_1_glNormal3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glNormal3iv(v);
+}
+
+void gl2_1_glNormal3i(void *_glfuncs, GLint nx, GLint ny, GLint nz)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glNormal3i(nx, ny, nz);
+}
+
+void gl2_1_glNormal3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glNormal3fv(v);
+}
+
+void gl2_1_glNormal3f(void *_glfuncs, GLfloat nx, GLfloat ny, GLfloat nz)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glNormal3f(nx, ny, nz);
+}
+
+void gl2_1_glNormal3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glNormal3dv(v);
+}
+
+void gl2_1_glNormal3d(void *_glfuncs, GLdouble nx, GLdouble ny, GLdouble nz)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glNormal3d(nx, ny, nz);
+}
+
+void gl2_1_glNormal3bv(void *_glfuncs, const GLbyte* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glNormal3bv(v);
+}
+
+void gl2_1_glNormal3b(void *_glfuncs, GLbyte nx, GLbyte ny, GLbyte nz)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glNormal3b(nx, ny, nz);
+}
+
+void gl2_1_glIndexsv(void *_glfuncs, const GLshort* c)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glIndexsv(c);
+}
+
+void gl2_1_glIndexs(void *_glfuncs, GLshort c)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glIndexs(c);
+}
+
+void gl2_1_glIndexiv(void *_glfuncs, const GLint* c)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glIndexiv(c);
+}
+
+void gl2_1_glIndexi(void *_glfuncs, GLint c)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glIndexi(c);
+}
+
+void gl2_1_glIndexfv(void *_glfuncs, const GLfloat* c)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glIndexfv(c);
+}
+
+void gl2_1_glIndexf(void *_glfuncs, GLfloat c)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glIndexf(c);
+}
+
+void gl2_1_glIndexdv(void *_glfuncs, const GLdouble* c)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glIndexdv(c);
+}
+
+void gl2_1_glIndexd(void *_glfuncs, GLdouble c)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glIndexd(c);
+}
+
+void gl2_1_glEnd(void *_glfuncs)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glEnd();
+}
+
+void gl2_1_glEdgeFlagv(void *_glfuncs, const GLboolean* flag)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glEdgeFlagv(flag);
+}
+
+void gl2_1_glEdgeFlag(void *_glfuncs, GLboolean flag)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glEdgeFlag(flag);
+}
+
+void gl2_1_glColor4usv(void *_glfuncs, const GLushort* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glColor4usv(v);
+}
+
+void gl2_1_glColor4us(void *_glfuncs, GLushort red, GLushort green, GLushort blue, GLushort alpha)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glColor4us(red, green, blue, alpha);
+}
+
+void gl2_1_glColor4uiv(void *_glfuncs, const GLuint* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glColor4uiv(v);
+}
+
+void gl2_1_glColor4ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue, GLuint alpha)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glColor4ui(red, green, blue, alpha);
+}
+
+void gl2_1_glColor4ubv(void *_glfuncs, const GLubyte* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glColor4ubv(v);
+}
+
+void gl2_1_glColor4ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glColor4ub(red, green, blue, alpha);
+}
+
+void gl2_1_glColor4sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glColor4sv(v);
+}
+
+void gl2_1_glColor4s(void *_glfuncs, GLshort red, GLshort green, GLshort blue, GLshort alpha)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glColor4s(red, green, blue, alpha);
+}
+
+void gl2_1_glColor4iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glColor4iv(v);
+}
+
+void gl2_1_glColor4i(void *_glfuncs, GLint red, GLint green, GLint blue, GLint alpha)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glColor4i(red, green, blue, alpha);
+}
+
+void gl2_1_glColor4fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glColor4fv(v);
+}
+
+void gl2_1_glColor4f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glColor4f(red, green, blue, alpha);
+}
+
+void gl2_1_glColor4dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glColor4dv(v);
+}
+
+void gl2_1_glColor4d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glColor4d(red, green, blue, alpha);
+}
+
+void gl2_1_glColor4bv(void *_glfuncs, const GLbyte* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glColor4bv(v);
+}
+
+void gl2_1_glColor4b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glColor4b(red, green, blue, alpha);
+}
+
+void gl2_1_glColor3usv(void *_glfuncs, const GLushort* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glColor3usv(v);
+}
+
+void gl2_1_glColor3us(void *_glfuncs, GLushort red, GLushort green, GLushort blue)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glColor3us(red, green, blue);
+}
+
+void gl2_1_glColor3uiv(void *_glfuncs, const GLuint* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glColor3uiv(v);
+}
+
+void gl2_1_glColor3ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glColor3ui(red, green, blue);
+}
+
+void gl2_1_glColor3ubv(void *_glfuncs, const GLubyte* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glColor3ubv(v);
+}
+
+void gl2_1_glColor3ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glColor3ub(red, green, blue);
+}
+
+void gl2_1_glColor3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glColor3sv(v);
+}
+
+void gl2_1_glColor3s(void *_glfuncs, GLshort red, GLshort green, GLshort blue)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glColor3s(red, green, blue);
+}
+
+void gl2_1_glColor3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glColor3iv(v);
+}
+
+void gl2_1_glColor3i(void *_glfuncs, GLint red, GLint green, GLint blue)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glColor3i(red, green, blue);
+}
+
+void gl2_1_glColor3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glColor3fv(v);
+}
+
+void gl2_1_glColor3f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glColor3f(red, green, blue);
+}
+
+void gl2_1_glColor3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glColor3dv(v);
+}
+
+void gl2_1_glColor3d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glColor3d(red, green, blue);
+}
+
+void gl2_1_glColor3bv(void *_glfuncs, const GLbyte* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glColor3bv(v);
+}
+
+void gl2_1_glColor3b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glColor3b(red, green, blue);
+}
+
+void gl2_1_glBitmap(void *_glfuncs, GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte* bitmap)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glBitmap(width, height, xorig, yorig, xmove, ymove, bitmap);
+}
+
+void gl2_1_glBegin(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glBegin(mode);
+}
+
+void gl2_1_glListBase(void *_glfuncs, GLuint base)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glListBase(base);
+}
+
+GLuint gl2_1_glGenLists(void *_glfuncs, GLsizei range_)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ return _qglfuncs->glGenLists(range_);
+}
+
+void gl2_1_glDeleteLists(void *_glfuncs, GLuint list, GLsizei range_)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glDeleteLists(list, range_);
+}
+
+void gl2_1_glCallLists(void *_glfuncs, GLsizei n, GLenum gltype, const GLvoid* lists)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glCallLists(n, gltype, lists);
+}
+
+void gl2_1_glCallList(void *_glfuncs, GLuint list)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glCallList(list);
+}
+
+void gl2_1_glEndList(void *_glfuncs)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glEndList();
+}
+
+void gl2_1_glNewList(void *_glfuncs, GLuint list, GLenum mode)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glNewList(list, mode);
+}
+
+void gl2_1_glPushClientAttrib(void *_glfuncs, GLbitfield mask)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glPushClientAttrib(mask);
+}
+
+void gl2_1_glPopClientAttrib(void *_glfuncs)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glPopClientAttrib();
+}
+
+void gl2_1_glPrioritizeTextures(void *_glfuncs, GLsizei n, const GLuint* textures, const GLfloat* priorities)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glPrioritizeTextures(n, textures, priorities);
+}
+
+GLboolean gl2_1_glAreTexturesResident(void *_glfuncs, GLsizei n, const GLuint* textures, GLboolean* residences)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ return _qglfuncs->glAreTexturesResident(n, textures, residences);
+}
+
+void gl2_1_glVertexPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertexPointer(size, gltype, stride, pointer);
+}
+
+void gl2_1_glTexCoordPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glTexCoordPointer(size, gltype, stride, pointer);
+}
+
+void gl2_1_glNormalPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glNormalPointer(gltype, stride, pointer);
+}
+
+void gl2_1_glInterleavedArrays(void *_glfuncs, GLenum format, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glInterleavedArrays(format, stride, pointer);
+}
+
+void gl2_1_glIndexPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glIndexPointer(gltype, stride, pointer);
+}
+
+void gl2_1_glEnableClientState(void *_glfuncs, GLenum array)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glEnableClientState(array);
+}
+
+void gl2_1_glEdgeFlagPointer(void *_glfuncs, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glEdgeFlagPointer(stride, pointer);
+}
+
+void gl2_1_glDisableClientState(void *_glfuncs, GLenum array)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glDisableClientState(array);
+}
+
+void gl2_1_glColorPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glColorPointer(size, gltype, stride, pointer);
+}
+
+void gl2_1_glArrayElement(void *_glfuncs, GLint i)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glArrayElement(i);
+}
+
+void gl2_1_glResetMinmax(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glResetMinmax(target);
+}
+
+void gl2_1_glResetHistogram(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glResetHistogram(target);
+}
+
+void gl2_1_glMinmax(void *_glfuncs, GLenum target, GLenum internalFormat, GLboolean sink)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glMinmax(target, internalFormat, sink);
+}
+
+void gl2_1_glHistogram(void *_glfuncs, GLenum target, GLsizei width, GLenum internalFormat, GLboolean sink)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glHistogram(target, width, internalFormat, sink);
+}
+
+void gl2_1_glGetMinmaxParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glGetMinmaxParameteriv(target, pname, params);
+}
+
+void gl2_1_glGetMinmaxParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glGetMinmaxParameterfv(target, pname, params);
+}
+
+void gl2_1_glGetMinmax(void *_glfuncs, GLenum target, GLboolean reset, GLenum format, GLenum gltype, GLvoid* values)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glGetMinmax(target, reset, format, gltype, values);
+}
+
+void gl2_1_glGetHistogramParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glGetHistogramParameteriv(target, pname, params);
+}
+
+void gl2_1_glGetHistogramParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glGetHistogramParameterfv(target, pname, params);
+}
+
+void gl2_1_glGetHistogram(void *_glfuncs, GLenum target, GLboolean reset, GLenum format, GLenum gltype, GLvoid* values)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glGetHistogram(target, reset, format, gltype, values);
+}
+
+void gl2_1_glSeparableFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* row, const GLvoid* column)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glSeparableFilter2D(target, internalFormat, width, height, format, gltype, row, column);
+}
+
+void gl2_1_glGetSeparableFilter(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* row, GLvoid* column, GLvoid* span)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glGetSeparableFilter(target, format, gltype, row, column, span);
+}
+
+void gl2_1_glGetConvolutionParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glGetConvolutionParameteriv(target, pname, params);
+}
+
+void gl2_1_glGetConvolutionParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glGetConvolutionParameterfv(target, pname, params);
+}
+
+void gl2_1_glGetConvolutionFilter(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* image)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glGetConvolutionFilter(target, format, gltype, image);
+}
+
+void gl2_1_glCopyConvolutionFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glCopyConvolutionFilter2D(target, internalFormat, x, y, width, height);
+}
+
+void gl2_1_glCopyConvolutionFilter1D(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glCopyConvolutionFilter1D(target, internalFormat, x, y, width);
+}
+
+void gl2_1_glConvolutionParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glConvolutionParameteriv(target, pname, params);
+}
+
+void gl2_1_glConvolutionParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint params)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glConvolutionParameteri(target, pname, params);
+}
+
+void gl2_1_glConvolutionParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glConvolutionParameterfv(target, pname, params);
+}
+
+void gl2_1_glConvolutionParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat params)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glConvolutionParameterf(target, pname, params);
+}
+
+void gl2_1_glConvolutionFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* image)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glConvolutionFilter2D(target, internalFormat, width, height, format, gltype, image);
+}
+
+void gl2_1_glConvolutionFilter1D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLenum format, GLenum gltype, const GLvoid* image)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glConvolutionFilter1D(target, internalFormat, width, format, gltype, image);
+}
+
+void gl2_1_glCopyColorSubTable(void *_glfuncs, GLenum target, GLsizei start, GLint x, GLint y, GLsizei width)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glCopyColorSubTable(target, start, x, y, width);
+}
+
+void gl2_1_glColorSubTable(void *_glfuncs, GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum gltype, const GLvoid* data)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glColorSubTable(target, start, count, format, gltype, data);
+}
+
+void gl2_1_glGetColorTableParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glGetColorTableParameteriv(target, pname, params);
+}
+
+void gl2_1_glGetColorTableParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glGetColorTableParameterfv(target, pname, params);
+}
+
+void gl2_1_glGetColorTable(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* table)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glGetColorTable(target, format, gltype, table);
+}
+
+void gl2_1_glCopyColorTable(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glCopyColorTable(target, internalFormat, x, y, width);
+}
+
+void gl2_1_glColorTableParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glColorTableParameteriv(target, pname, params);
+}
+
+void gl2_1_glColorTableParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glColorTableParameterfv(target, pname, params);
+}
+
+void gl2_1_glColorTable(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLenum format, GLenum gltype, const GLvoid* table)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glColorTable(target, internalFormat, width, format, gltype, table);
+}
+
+void gl2_1_glMultTransposeMatrixd(void *_glfuncs, const GLdouble* m)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glMultTransposeMatrixd(m);
+}
+
+void gl2_1_glMultTransposeMatrixf(void *_glfuncs, const GLfloat* m)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glMultTransposeMatrixf(m);
+}
+
+void gl2_1_glLoadTransposeMatrixd(void *_glfuncs, const GLdouble* m)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glLoadTransposeMatrixd(m);
+}
+
+void gl2_1_glLoadTransposeMatrixf(void *_glfuncs, const GLfloat* m)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glLoadTransposeMatrixf(m);
+}
+
+void gl2_1_glMultiTexCoord4sv(void *_glfuncs, GLenum target, const GLshort* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4sv(target, v);
+}
+
+void gl2_1_glMultiTexCoord4s(void *_glfuncs, GLenum target, GLshort s, GLshort t, GLshort r, GLshort q)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4s(target, s, t, r, q);
+}
+
+void gl2_1_glMultiTexCoord4iv(void *_glfuncs, GLenum target, const GLint* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4iv(target, v);
+}
+
+void gl2_1_glMultiTexCoord4i(void *_glfuncs, GLenum target, GLint s, GLint t, GLint r, GLint q)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4i(target, s, t, r, q);
+}
+
+void gl2_1_glMultiTexCoord4fv(void *_glfuncs, GLenum target, const GLfloat* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4fv(target, v);
+}
+
+void gl2_1_glMultiTexCoord4f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4f(target, s, t, r, q);
+}
+
+void gl2_1_glMultiTexCoord4dv(void *_glfuncs, GLenum target, const GLdouble* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4dv(target, v);
+}
+
+void gl2_1_glMultiTexCoord4d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4d(target, s, t, r, q);
+}
+
+void gl2_1_glMultiTexCoord3sv(void *_glfuncs, GLenum target, const GLshort* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3sv(target, v);
+}
+
+void gl2_1_glMultiTexCoord3s(void *_glfuncs, GLenum target, GLshort s, GLshort t, GLshort r)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3s(target, s, t, r);
+}
+
+void gl2_1_glMultiTexCoord3iv(void *_glfuncs, GLenum target, const GLint* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3iv(target, v);
+}
+
+void gl2_1_glMultiTexCoord3i(void *_glfuncs, GLenum target, GLint s, GLint t, GLint r)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3i(target, s, t, r);
+}
+
+void gl2_1_glMultiTexCoord3fv(void *_glfuncs, GLenum target, const GLfloat* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3fv(target, v);
+}
+
+void gl2_1_glMultiTexCoord3f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t, GLfloat r)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3f(target, s, t, r);
+}
+
+void gl2_1_glMultiTexCoord3dv(void *_glfuncs, GLenum target, const GLdouble* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3dv(target, v);
+}
+
+void gl2_1_glMultiTexCoord3d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t, GLdouble r)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3d(target, s, t, r);
+}
+
+void gl2_1_glMultiTexCoord2sv(void *_glfuncs, GLenum target, const GLshort* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2sv(target, v);
+}
+
+void gl2_1_glMultiTexCoord2s(void *_glfuncs, GLenum target, GLshort s, GLshort t)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2s(target, s, t);
+}
+
+void gl2_1_glMultiTexCoord2iv(void *_glfuncs, GLenum target, const GLint* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2iv(target, v);
+}
+
+void gl2_1_glMultiTexCoord2i(void *_glfuncs, GLenum target, GLint s, GLint t)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2i(target, s, t);
+}
+
+void gl2_1_glMultiTexCoord2fv(void *_glfuncs, GLenum target, const GLfloat* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2fv(target, v);
+}
+
+void gl2_1_glMultiTexCoord2f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2f(target, s, t);
+}
+
+void gl2_1_glMultiTexCoord2dv(void *_glfuncs, GLenum target, const GLdouble* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2dv(target, v);
+}
+
+void gl2_1_glMultiTexCoord2d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2d(target, s, t);
+}
+
+void gl2_1_glMultiTexCoord1sv(void *_glfuncs, GLenum target, const GLshort* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1sv(target, v);
+}
+
+void gl2_1_glMultiTexCoord1s(void *_glfuncs, GLenum target, GLshort s)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1s(target, s);
+}
+
+void gl2_1_glMultiTexCoord1iv(void *_glfuncs, GLenum target, const GLint* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1iv(target, v);
+}
+
+void gl2_1_glMultiTexCoord1i(void *_glfuncs, GLenum target, GLint s)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1i(target, s);
+}
+
+void gl2_1_glMultiTexCoord1fv(void *_glfuncs, GLenum target, const GLfloat* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1fv(target, v);
+}
+
+void gl2_1_glMultiTexCoord1f(void *_glfuncs, GLenum target, GLfloat s)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1f(target, s);
+}
+
+void gl2_1_glMultiTexCoord1dv(void *_glfuncs, GLenum target, const GLdouble* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1dv(target, v);
+}
+
+void gl2_1_glMultiTexCoord1d(void *_glfuncs, GLenum target, GLdouble s)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1d(target, s);
+}
+
+void gl2_1_glClientActiveTexture(void *_glfuncs, GLenum texture)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glClientActiveTexture(texture);
+}
+
+void gl2_1_glWindowPos3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glWindowPos3sv(v);
+}
+
+void gl2_1_glWindowPos3s(void *_glfuncs, GLshort x, GLshort y, GLshort z)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glWindowPos3s(x, y, z);
+}
+
+void gl2_1_glWindowPos3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glWindowPos3iv(v);
+}
+
+void gl2_1_glWindowPos3i(void *_glfuncs, GLint x, GLint y, GLint z)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glWindowPos3i(x, y, z);
+}
+
+void gl2_1_glWindowPos3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glWindowPos3fv(v);
+}
+
+void gl2_1_glWindowPos3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glWindowPos3f(x, y, z);
+}
+
+void gl2_1_glWindowPos3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glWindowPos3dv(v);
+}
+
+void gl2_1_glWindowPos3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glWindowPos3d(x, y, z);
+}
+
+void gl2_1_glWindowPos2sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glWindowPos2sv(v);
+}
+
+void gl2_1_glWindowPos2s(void *_glfuncs, GLshort x, GLshort y)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glWindowPos2s(x, y);
+}
+
+void gl2_1_glWindowPos2iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glWindowPos2iv(v);
+}
+
+void gl2_1_glWindowPos2i(void *_glfuncs, GLint x, GLint y)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glWindowPos2i(x, y);
+}
+
+void gl2_1_glWindowPos2fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glWindowPos2fv(v);
+}
+
+void gl2_1_glWindowPos2f(void *_glfuncs, GLfloat x, GLfloat y)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glWindowPos2f(x, y);
+}
+
+void gl2_1_glWindowPos2dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glWindowPos2dv(v);
+}
+
+void gl2_1_glWindowPos2d(void *_glfuncs, GLdouble x, GLdouble y)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glWindowPos2d(x, y);
+}
+
+void gl2_1_glSecondaryColorPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glSecondaryColorPointer(size, gltype, stride, pointer);
+}
+
+void gl2_1_glSecondaryColor3usv(void *_glfuncs, const GLushort* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3usv(v);
+}
+
+void gl2_1_glSecondaryColor3us(void *_glfuncs, GLushort red, GLushort green, GLushort blue)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3us(red, green, blue);
+}
+
+void gl2_1_glSecondaryColor3uiv(void *_glfuncs, const GLuint* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3uiv(v);
+}
+
+void gl2_1_glSecondaryColor3ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3ui(red, green, blue);
+}
+
+void gl2_1_glSecondaryColor3ubv(void *_glfuncs, const GLubyte* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3ubv(v);
+}
+
+void gl2_1_glSecondaryColor3ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3ub(red, green, blue);
+}
+
+void gl2_1_glSecondaryColor3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3sv(v);
+}
+
+void gl2_1_glSecondaryColor3s(void *_glfuncs, GLshort red, GLshort green, GLshort blue)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3s(red, green, blue);
+}
+
+void gl2_1_glSecondaryColor3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3iv(v);
+}
+
+void gl2_1_glSecondaryColor3i(void *_glfuncs, GLint red, GLint green, GLint blue)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3i(red, green, blue);
+}
+
+void gl2_1_glSecondaryColor3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3fv(v);
+}
+
+void gl2_1_glSecondaryColor3f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3f(red, green, blue);
+}
+
+void gl2_1_glSecondaryColor3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3dv(v);
+}
+
+void gl2_1_glSecondaryColor3d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3d(red, green, blue);
+}
+
+void gl2_1_glSecondaryColor3bv(void *_glfuncs, const GLbyte* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3bv(v);
+}
+
+void gl2_1_glSecondaryColor3b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3b(red, green, blue);
+}
+
+void gl2_1_glFogCoordPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glFogCoordPointer(gltype, stride, pointer);
+}
+
+void gl2_1_glFogCoorddv(void *_glfuncs, const GLdouble* coord)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glFogCoorddv(coord);
+}
+
+void gl2_1_glFogCoordd(void *_glfuncs, GLdouble coord)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glFogCoordd(coord);
+}
+
+void gl2_1_glFogCoordfv(void *_glfuncs, const GLfloat* coord)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glFogCoordfv(coord);
+}
+
+void gl2_1_glFogCoordf(void *_glfuncs, GLfloat coord)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glFogCoordf(coord);
+}
+
+void gl2_1_glVertexAttrib4usv(void *_glfuncs, GLuint index, const GLushort* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4usv(index, v);
+}
+
+void gl2_1_glVertexAttrib4uiv(void *_glfuncs, GLuint index, const GLuint* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4uiv(index, v);
+}
+
+void gl2_1_glVertexAttrib4ubv(void *_glfuncs, GLuint index, const GLubyte* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4ubv(index, v);
+}
+
+void gl2_1_glVertexAttrib4sv(void *_glfuncs, GLuint index, const GLshort* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4sv(index, v);
+}
+
+void gl2_1_glVertexAttrib4s(void *_glfuncs, GLuint index, GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4s(index, x, y, z, w);
+}
+
+void gl2_1_glVertexAttrib4iv(void *_glfuncs, GLuint index, const GLint* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4iv(index, v);
+}
+
+void gl2_1_glVertexAttrib4fv(void *_glfuncs, GLuint index, const GLfloat* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4fv(index, v);
+}
+
+void gl2_1_glVertexAttrib4f(void *_glfuncs, GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4f(index, x, y, z, w);
+}
+
+void gl2_1_glVertexAttrib4dv(void *_glfuncs, GLuint index, const GLdouble* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4dv(index, v);
+}
+
+void gl2_1_glVertexAttrib4d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4d(index, x, y, z, w);
+}
+
+void gl2_1_glVertexAttrib4bv(void *_glfuncs, GLuint index, const GLbyte* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4bv(index, v);
+}
+
+void gl2_1_glVertexAttrib4Nusv(void *_glfuncs, GLuint index, const GLushort* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Nusv(index, v);
+}
+
+void gl2_1_glVertexAttrib4Nuiv(void *_glfuncs, GLuint index, const GLuint* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Nuiv(index, v);
+}
+
+void gl2_1_glVertexAttrib4Nubv(void *_glfuncs, GLuint index, const GLubyte* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Nubv(index, v);
+}
+
+void gl2_1_glVertexAttrib4Nub(void *_glfuncs, GLuint index, GLubyte x, GLubyte y, GLubyte z, GLubyte w)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Nub(index, x, y, z, w);
+}
+
+void gl2_1_glVertexAttrib4Nsv(void *_glfuncs, GLuint index, const GLshort* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Nsv(index, v);
+}
+
+void gl2_1_glVertexAttrib4Niv(void *_glfuncs, GLuint index, const GLint* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Niv(index, v);
+}
+
+void gl2_1_glVertexAttrib4Nbv(void *_glfuncs, GLuint index, const GLbyte* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Nbv(index, v);
+}
+
+void gl2_1_glVertexAttrib3sv(void *_glfuncs, GLuint index, const GLshort* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertexAttrib3sv(index, v);
+}
+
+void gl2_1_glVertexAttrib3s(void *_glfuncs, GLuint index, GLshort x, GLshort y, GLshort z)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertexAttrib3s(index, x, y, z);
+}
+
+void gl2_1_glVertexAttrib3fv(void *_glfuncs, GLuint index, const GLfloat* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertexAttrib3fv(index, v);
+}
+
+void gl2_1_glVertexAttrib3f(void *_glfuncs, GLuint index, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertexAttrib3f(index, x, y, z);
+}
+
+void gl2_1_glVertexAttrib3dv(void *_glfuncs, GLuint index, const GLdouble* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertexAttrib3dv(index, v);
+}
+
+void gl2_1_glVertexAttrib3d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertexAttrib3d(index, x, y, z);
+}
+
+void gl2_1_glVertexAttrib2sv(void *_glfuncs, GLuint index, const GLshort* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertexAttrib2sv(index, v);
+}
+
+void gl2_1_glVertexAttrib2s(void *_glfuncs, GLuint index, GLshort x, GLshort y)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertexAttrib2s(index, x, y);
+}
+
+void gl2_1_glVertexAttrib2fv(void *_glfuncs, GLuint index, const GLfloat* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertexAttrib2fv(index, v);
+}
+
+void gl2_1_glVertexAttrib2f(void *_glfuncs, GLuint index, GLfloat x, GLfloat y)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertexAttrib2f(index, x, y);
+}
+
+void gl2_1_glVertexAttrib2dv(void *_glfuncs, GLuint index, const GLdouble* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertexAttrib2dv(index, v);
+}
+
+void gl2_1_glVertexAttrib2d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertexAttrib2d(index, x, y);
+}
+
+void gl2_1_glVertexAttrib1sv(void *_glfuncs, GLuint index, const GLshort* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertexAttrib1sv(index, v);
+}
+
+void gl2_1_glVertexAttrib1s(void *_glfuncs, GLuint index, GLshort x)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertexAttrib1s(index, x);
+}
+
+void gl2_1_glVertexAttrib1fv(void *_glfuncs, GLuint index, const GLfloat* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertexAttrib1fv(index, v);
+}
+
+void gl2_1_glVertexAttrib1f(void *_glfuncs, GLuint index, GLfloat x)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertexAttrib1f(index, x);
+}
+
+void gl2_1_glVertexAttrib1dv(void *_glfuncs, GLuint index, const GLdouble* v)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertexAttrib1dv(index, v);
+}
+
+void gl2_1_glVertexAttrib1d(void *_glfuncs, GLuint index, GLdouble x)
+{
+ QOpenGLFunctions_2_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_2_1*>(_glfuncs);
+ _qglfuncs->glVertexAttrib1d(index, x);
+}
+
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/2.1/funcs.h b/Godeps/_workspace/src/github.com/obscuren/qml/gl/2.1/funcs.h
new file mode 100644
index 000000000..399784504
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/2.1/funcs.h
@@ -0,0 +1,619 @@
+
+// ** file automatically generated by glgen -- do not edit manually **
+
+#ifndef __cplusplus
+#include <inttypes.h>
+#include <stddef.h>
+typedef unsigned int GLenum;
+typedef unsigned char GLboolean;
+typedef unsigned int GLbitfield;
+typedef void GLvoid;
+typedef char GLchar;
+typedef signed char GLbyte; /* 1-byte signed */
+typedef short GLshort; /* 2-byte signed */
+typedef int GLint; /* 4-byte signed */
+typedef unsigned char GLubyte; /* 1-byte unsigned */
+typedef unsigned short GLushort; /* 2-byte unsigned */
+typedef unsigned int GLuint; /* 4-byte unsigned */
+typedef int GLsizei; /* 4-byte signed */
+typedef float GLfloat; /* single precision float */
+typedef float GLclampf; /* single precision float in [0,1] */
+typedef double GLdouble; /* double precision float */
+typedef double GLclampd; /* double precision float in [0,1] */
+typedef int64_t GLint64;
+typedef uint64_t GLuint64;
+typedef ptrdiff_t GLintptr;
+typedef ptrdiff_t GLsizeiptr;
+typedef ptrdiff_t GLintptrARB;
+typedef ptrdiff_t GLsizeiptrARB;
+typedef struct __GLsync *GLsync;
+#endif
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+void *gl2_1_funcs();
+
+void gl2_1_glViewport(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl2_1_glDepthRange(void *_glfuncs, GLdouble nearVal, GLdouble farVal);
+GLboolean gl2_1_glIsEnabled(void *_glfuncs, GLenum cap);
+void gl2_1_glGetTexLevelParameteriv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLint* params);
+void gl2_1_glGetTexLevelParameterfv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLfloat* params);
+void gl2_1_glGetTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl2_1_glGetTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl2_1_glGetTexImage(void *_glfuncs, GLenum target, GLint level, GLenum format, GLenum gltype, GLvoid* pixels);
+void gl2_1_glGetIntegerv(void *_glfuncs, GLenum pname, GLint* params);
+void gl2_1_glGetFloatv(void *_glfuncs, GLenum pname, GLfloat* params);
+GLenum gl2_1_glGetError(void *_glfuncs);
+void gl2_1_glGetDoublev(void *_glfuncs, GLenum pname, GLdouble* params);
+void gl2_1_glGetBooleanv(void *_glfuncs, GLenum pname, GLboolean* params);
+void gl2_1_glReadPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum gltype, GLvoid* pixels);
+void gl2_1_glReadBuffer(void *_glfuncs, GLenum mode);
+void gl2_1_glPixelStorei(void *_glfuncs, GLenum pname, GLint param);
+void gl2_1_glPixelStoref(void *_glfuncs, GLenum pname, GLfloat param);
+void gl2_1_glDepthFunc(void *_glfuncs, GLenum glfunc);
+void gl2_1_glStencilOp(void *_glfuncs, GLenum fail, GLenum zfail, GLenum zpass);
+void gl2_1_glStencilFunc(void *_glfuncs, GLenum glfunc, GLint ref, GLuint mask);
+void gl2_1_glLogicOp(void *_glfuncs, GLenum opcode);
+void gl2_1_glBlendFunc(void *_glfuncs, GLenum sfactor, GLenum dfactor);
+void gl2_1_glFlush(void *_glfuncs);
+void gl2_1_glFinish(void *_glfuncs);
+void gl2_1_glEnable(void *_glfuncs, GLenum cap);
+void gl2_1_glDisable(void *_glfuncs, GLenum cap);
+void gl2_1_glDepthMask(void *_glfuncs, GLboolean flag);
+void gl2_1_glColorMask(void *_glfuncs, GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha);
+void gl2_1_glStencilMask(void *_glfuncs, GLuint mask);
+void gl2_1_glClearDepth(void *_glfuncs, GLdouble depth);
+void gl2_1_glClearStencil(void *_glfuncs, GLint s);
+void gl2_1_glClearColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl2_1_glClear(void *_glfuncs, GLbitfield mask);
+void gl2_1_glDrawBuffer(void *_glfuncs, GLenum mode);
+void gl2_1_glTexImage2D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl2_1_glTexImage1D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl2_1_glTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl2_1_glTexParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint param);
+void gl2_1_glTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl2_1_glTexParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param);
+void gl2_1_glScissor(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl2_1_glPolygonMode(void *_glfuncs, GLenum face, GLenum mode);
+void gl2_1_glPointSize(void *_glfuncs, GLfloat size);
+void gl2_1_glLineWidth(void *_glfuncs, GLfloat width);
+void gl2_1_glHint(void *_glfuncs, GLenum target, GLenum mode);
+void gl2_1_glFrontFace(void *_glfuncs, GLenum mode);
+void gl2_1_glCullFace(void *_glfuncs, GLenum mode);
+void gl2_1_glIndexubv(void *_glfuncs, const GLubyte* c);
+void gl2_1_glIndexub(void *_glfuncs, GLubyte c);
+GLboolean gl2_1_glIsTexture(void *_glfuncs, GLuint texture);
+void gl2_1_glGenTextures(void *_glfuncs, GLsizei n, GLuint* textures);
+void gl2_1_glDeleteTextures(void *_glfuncs, GLsizei n, const GLuint* textures);
+void gl2_1_glBindTexture(void *_glfuncs, GLenum target, GLuint texture);
+void gl2_1_glTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl2_1_glTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl2_1_glCopyTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl2_1_glCopyTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width);
+void gl2_1_glCopyTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border);
+void gl2_1_glCopyTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLint border);
+void gl2_1_glPolygonOffset(void *_glfuncs, GLfloat factor, GLfloat units);
+void gl2_1_glDrawElements(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices);
+void gl2_1_glDrawArrays(void *_glfuncs, GLenum mode, GLint first, GLsizei count);
+void gl2_1_glCopyTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl2_1_glTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl2_1_glTexImage3D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl2_1_glDrawRangeElements(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices);
+void gl2_1_glBlendEquation(void *_glfuncs, GLenum mode);
+void gl2_1_glBlendColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl2_1_glGetCompressedTexImage(void *_glfuncs, GLenum target, GLint level, GLvoid* img);
+void gl2_1_glCompressedTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid* data);
+void gl2_1_glCompressedTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid* data);
+void gl2_1_glCompressedTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid* data);
+void gl2_1_glCompressedTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid* data);
+void gl2_1_glCompressedTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid* data);
+void gl2_1_glCompressedTexImage3D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid* data);
+void gl2_1_glSampleCoverage(void *_glfuncs, GLfloat value, GLboolean invert);
+void gl2_1_glActiveTexture(void *_glfuncs, GLenum texture);
+void gl2_1_glPointParameteriv(void *_glfuncs, GLenum pname, const GLint* params);
+void gl2_1_glPointParameteri(void *_glfuncs, GLenum pname, GLint param);
+void gl2_1_glPointParameterfv(void *_glfuncs, GLenum pname, const GLfloat* params);
+void gl2_1_glPointParameterf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl2_1_glMultiDrawArrays(void *_glfuncs, GLenum mode, const GLint* first, const GLsizei* count, GLsizei drawcount);
+void gl2_1_glBlendFuncSeparate(void *_glfuncs, GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha);
+void gl2_1_glGetBufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+GLboolean gl2_1_glUnmapBuffer(void *_glfuncs, GLenum target);
+void gl2_1_glGetBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, GLvoid* data);
+void gl2_1_glBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid* data);
+void gl2_1_glBufferData(void *_glfuncs, GLenum target, GLsizeiptr size, const GLvoid* data, GLenum usage);
+GLboolean gl2_1_glIsBuffer(void *_glfuncs, GLuint buffer);
+void gl2_1_glGenBuffers(void *_glfuncs, GLsizei n, GLuint* buffers);
+void gl2_1_glDeleteBuffers(void *_glfuncs, GLsizei n, const GLuint* buffers);
+void gl2_1_glBindBuffer(void *_glfuncs, GLenum target, GLuint buffer);
+void gl2_1_glGetQueryObjectuiv(void *_glfuncs, GLuint id, GLenum pname, GLuint* params);
+void gl2_1_glGetQueryObjectiv(void *_glfuncs, GLuint id, GLenum pname, GLint* params);
+void gl2_1_glGetQueryiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl2_1_glEndQuery(void *_glfuncs, GLenum target);
+void gl2_1_glBeginQuery(void *_glfuncs, GLenum target, GLuint id);
+GLboolean gl2_1_glIsQuery(void *_glfuncs, GLuint id);
+void gl2_1_glDeleteQueries(void *_glfuncs, GLsizei n, const GLuint* ids);
+void gl2_1_glGenQueries(void *_glfuncs, GLsizei n, GLuint* ids);
+void gl2_1_glVertexAttribPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLboolean normalized, GLsizei stride, const GLvoid* offset);
+void gl2_1_glValidateProgram(void *_glfuncs, GLuint program);
+void gl2_1_glUniformMatrix4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl2_1_glUniformMatrix3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl2_1_glUniformMatrix2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl2_1_glUniform4iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl2_1_glUniform3iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl2_1_glUniform2iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl2_1_glUniform1iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl2_1_glUniform4fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl2_1_glUniform3fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl2_1_glUniform2fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl2_1_glUniform1fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl2_1_glUniform4i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2, GLint v3);
+void gl2_1_glUniform3i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2);
+void gl2_1_glUniform2i(void *_glfuncs, GLint location, GLint v0, GLint v1);
+void gl2_1_glUniform1i(void *_glfuncs, GLint location, GLint v0);
+void gl2_1_glUniform4f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3);
+void gl2_1_glUniform3f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2);
+void gl2_1_glUniform2f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1);
+void gl2_1_glUniform1f(void *_glfuncs, GLint location, GLfloat v0);
+void gl2_1_glUseProgram(void *_glfuncs, GLuint program);
+void gl2_1_glShaderSource(void *_glfuncs, GLuint shader, GLsizei count, const GLchar** source, const GLint* length);
+void gl2_1_glLinkProgram(void *_glfuncs, GLuint program);
+GLboolean gl2_1_glIsShader(void *_glfuncs, GLuint shader);
+GLboolean gl2_1_glIsProgram(void *_glfuncs, GLuint program);
+void gl2_1_glGetVertexAttribiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params);
+void gl2_1_glGetVertexAttribfv(void *_glfuncs, GLuint index, GLenum pname, GLfloat* params);
+void gl2_1_glGetVertexAttribdv(void *_glfuncs, GLuint index, GLenum pname, GLdouble* params);
+void gl2_1_glGetUniformiv(void *_glfuncs, GLuint program, GLint location, GLint* params);
+void gl2_1_glGetUniformfv(void *_glfuncs, GLuint program, GLint location, GLfloat* params);
+GLint gl2_1_glGetUniformLocation(void *_glfuncs, GLuint program, const GLchar* name);
+void gl2_1_glGetShaderSource(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* source);
+void gl2_1_glGetShaderInfoLog(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* infoLog);
+void gl2_1_glGetShaderiv(void *_glfuncs, GLuint shader, GLenum pname, GLint* params);
+void gl2_1_glGetProgramInfoLog(void *_glfuncs, GLuint program, GLsizei bufSize, GLsizei* length, GLchar* infoLog);
+void gl2_1_glGetProgramiv(void *_glfuncs, GLuint program, GLenum pname, GLint* params);
+GLint gl2_1_glGetAttribLocation(void *_glfuncs, GLuint program, const GLchar* name);
+void gl2_1_glGetAttachedShaders(void *_glfuncs, GLuint program, GLsizei maxCount, GLsizei* count, GLuint* obj);
+void gl2_1_glGetActiveUniform(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name);
+void gl2_1_glGetActiveAttrib(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name);
+void gl2_1_glEnableVertexAttribArray(void *_glfuncs, GLuint index);
+void gl2_1_glDisableVertexAttribArray(void *_glfuncs, GLuint index);
+void gl2_1_glDetachShader(void *_glfuncs, GLuint program, GLuint shader);
+void gl2_1_glDeleteShader(void *_glfuncs, GLuint shader);
+void gl2_1_glDeleteProgram(void *_glfuncs, GLuint program);
+GLuint gl2_1_glCreateShader(void *_glfuncs, GLenum gltype);
+GLuint gl2_1_glCreateProgram(void *_glfuncs);
+void gl2_1_glCompileShader(void *_glfuncs, GLuint shader);
+void gl2_1_glBindAttribLocation(void *_glfuncs, GLuint program, GLuint index, const GLchar* name);
+void gl2_1_glAttachShader(void *_glfuncs, GLuint program, GLuint shader);
+void gl2_1_glStencilMaskSeparate(void *_glfuncs, GLenum face, GLuint mask);
+void gl2_1_glStencilFuncSeparate(void *_glfuncs, GLenum face, GLenum glfunc, GLint ref, GLuint mask);
+void gl2_1_glStencilOpSeparate(void *_glfuncs, GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass);
+void gl2_1_glDrawBuffers(void *_glfuncs, GLsizei n, const GLenum* bufs);
+void gl2_1_glBlendEquationSeparate(void *_glfuncs, GLenum modeRGB, GLenum modeAlpha);
+void gl2_1_glUniformMatrix4x3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl2_1_glUniformMatrix3x4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl2_1_glUniformMatrix4x2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl2_1_glUniformMatrix2x4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl2_1_glUniformMatrix3x2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl2_1_glUniformMatrix2x3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl2_1_glTranslatef(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl2_1_glTranslated(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl2_1_glScalef(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl2_1_glScaled(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl2_1_glRotatef(void *_glfuncs, GLfloat angle, GLfloat x, GLfloat y, GLfloat z);
+void gl2_1_glRotated(void *_glfuncs, GLdouble angle, GLdouble x, GLdouble y, GLdouble z);
+void gl2_1_glPushMatrix(void *_glfuncs);
+void gl2_1_glPopMatrix(void *_glfuncs);
+void gl2_1_glOrtho(void *_glfuncs, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+void gl2_1_glMultMatrixd(void *_glfuncs, const GLdouble* m);
+void gl2_1_glMultMatrixf(void *_glfuncs, const GLfloat* m);
+void gl2_1_glMatrixMode(void *_glfuncs, GLenum mode);
+void gl2_1_glLoadMatrixd(void *_glfuncs, const GLdouble* m);
+void gl2_1_glLoadMatrixf(void *_glfuncs, const GLfloat* m);
+void gl2_1_glLoadIdentity(void *_glfuncs);
+void gl2_1_glFrustum(void *_glfuncs, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+GLboolean gl2_1_glIsList(void *_glfuncs, GLuint list);
+void gl2_1_glGetTexGeniv(void *_glfuncs, GLenum coord, GLenum pname, GLint* params);
+void gl2_1_glGetTexGenfv(void *_glfuncs, GLenum coord, GLenum pname, GLfloat* params);
+void gl2_1_glGetTexGendv(void *_glfuncs, GLenum coord, GLenum pname, GLdouble* params);
+void gl2_1_glGetTexEnviv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl2_1_glGetTexEnvfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl2_1_glGetPolygonStipple(void *_glfuncs, GLubyte* mask);
+void gl2_1_glGetPixelMapusv(void *_glfuncs, GLenum glmap, GLushort* values);
+void gl2_1_glGetPixelMapuiv(void *_glfuncs, GLenum glmap, GLuint* values);
+void gl2_1_glGetPixelMapfv(void *_glfuncs, GLenum glmap, GLfloat* values);
+void gl2_1_glGetMaterialiv(void *_glfuncs, GLenum face, GLenum pname, GLint* params);
+void gl2_1_glGetMaterialfv(void *_glfuncs, GLenum face, GLenum pname, GLfloat* params);
+void gl2_1_glGetMapiv(void *_glfuncs, GLenum target, GLenum query, GLint* v);
+void gl2_1_glGetMapfv(void *_glfuncs, GLenum target, GLenum query, GLfloat* v);
+void gl2_1_glGetMapdv(void *_glfuncs, GLenum target, GLenum query, GLdouble* v);
+void gl2_1_glGetLightiv(void *_glfuncs, GLenum light, GLenum pname, GLint* params);
+void gl2_1_glGetLightfv(void *_glfuncs, GLenum light, GLenum pname, GLfloat* params);
+void gl2_1_glGetClipPlane(void *_glfuncs, GLenum plane, GLdouble* equation);
+void gl2_1_glDrawPixels(void *_glfuncs, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl2_1_glCopyPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum gltype);
+void gl2_1_glPixelMapusv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLushort* values);
+void gl2_1_glPixelMapuiv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLuint* values);
+void gl2_1_glPixelMapfv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLfloat* values);
+void gl2_1_glPixelTransferi(void *_glfuncs, GLenum pname, GLint param);
+void gl2_1_glPixelTransferf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl2_1_glPixelZoom(void *_glfuncs, GLfloat xfactor, GLfloat yfactor);
+void gl2_1_glAlphaFunc(void *_glfuncs, GLenum glfunc, GLfloat ref);
+void gl2_1_glEvalPoint2(void *_glfuncs, GLint i, GLint j);
+void gl2_1_glEvalMesh2(void *_glfuncs, GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2);
+void gl2_1_glEvalPoint1(void *_glfuncs, GLint i);
+void gl2_1_glEvalMesh1(void *_glfuncs, GLenum mode, GLint i1, GLint i2);
+void gl2_1_glEvalCoord2fv(void *_glfuncs, const GLfloat* u);
+void gl2_1_glEvalCoord2f(void *_glfuncs, GLfloat u, GLfloat v);
+void gl2_1_glEvalCoord2dv(void *_glfuncs, const GLdouble* u);
+void gl2_1_glEvalCoord2d(void *_glfuncs, GLdouble u, GLdouble v);
+void gl2_1_glEvalCoord1fv(void *_glfuncs, const GLfloat* u);
+void gl2_1_glEvalCoord1f(void *_glfuncs, GLfloat u);
+void gl2_1_glEvalCoord1dv(void *_glfuncs, const GLdouble* u);
+void gl2_1_glEvalCoord1d(void *_glfuncs, GLdouble u);
+void gl2_1_glMapGrid2f(void *_glfuncs, GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2);
+void gl2_1_glMapGrid2d(void *_glfuncs, GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2);
+void gl2_1_glMapGrid1f(void *_glfuncs, GLint un, GLfloat u1, GLfloat u2);
+void gl2_1_glMapGrid1d(void *_glfuncs, GLint un, GLdouble u1, GLdouble u2);
+void gl2_1_glMap2f(void *_glfuncs, GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat* points);
+void gl2_1_glMap2d(void *_glfuncs, GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble* points);
+void gl2_1_glMap1f(void *_glfuncs, GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat* points);
+void gl2_1_glMap1d(void *_glfuncs, GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble* points);
+void gl2_1_glPushAttrib(void *_glfuncs, GLbitfield mask);
+void gl2_1_glPopAttrib(void *_glfuncs);
+void gl2_1_glAccum(void *_glfuncs, GLenum op, GLfloat value);
+void gl2_1_glIndexMask(void *_glfuncs, GLuint mask);
+void gl2_1_glClearIndex(void *_glfuncs, GLfloat c);
+void gl2_1_glClearAccum(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl2_1_glPushName(void *_glfuncs, GLuint name);
+void gl2_1_glPopName(void *_glfuncs);
+void gl2_1_glPassThrough(void *_glfuncs, GLfloat token);
+void gl2_1_glLoadName(void *_glfuncs, GLuint name);
+void gl2_1_glInitNames(void *_glfuncs);
+GLint gl2_1_glRenderMode(void *_glfuncs, GLenum mode);
+void gl2_1_glSelectBuffer(void *_glfuncs, GLsizei size, GLuint* buffer);
+void gl2_1_glFeedbackBuffer(void *_glfuncs, GLsizei size, GLenum gltype, GLfloat* buffer);
+void gl2_1_glTexGeniv(void *_glfuncs, GLenum coord, GLenum pname, const GLint* params);
+void gl2_1_glTexGeni(void *_glfuncs, GLenum coord, GLenum pname, GLint param);
+void gl2_1_glTexGenfv(void *_glfuncs, GLenum coord, GLenum pname, const GLfloat* params);
+void gl2_1_glTexGenf(void *_glfuncs, GLenum coord, GLenum pname, GLfloat param);
+void gl2_1_glTexGendv(void *_glfuncs, GLenum coord, GLenum pname, const GLdouble* params);
+void gl2_1_glTexGend(void *_glfuncs, GLenum coord, GLenum pname, GLdouble param);
+void gl2_1_glTexEnviv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl2_1_glTexEnvi(void *_glfuncs, GLenum target, GLenum pname, GLint param);
+void gl2_1_glTexEnvfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl2_1_glTexEnvf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param);
+void gl2_1_glShadeModel(void *_glfuncs, GLenum mode);
+void gl2_1_glPolygonStipple(void *_glfuncs, const GLubyte* mask);
+void gl2_1_glMaterialiv(void *_glfuncs, GLenum face, GLenum pname, const GLint* params);
+void gl2_1_glMateriali(void *_glfuncs, GLenum face, GLenum pname, GLint param);
+void gl2_1_glMaterialfv(void *_glfuncs, GLenum face, GLenum pname, const GLfloat* params);
+void gl2_1_glMaterialf(void *_glfuncs, GLenum face, GLenum pname, GLfloat param);
+void gl2_1_glLineStipple(void *_glfuncs, GLint factor, GLushort pattern);
+void gl2_1_glLightModeliv(void *_glfuncs, GLenum pname, const GLint* params);
+void gl2_1_glLightModeli(void *_glfuncs, GLenum pname, GLint param);
+void gl2_1_glLightModelfv(void *_glfuncs, GLenum pname, const GLfloat* params);
+void gl2_1_glLightModelf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl2_1_glLightiv(void *_glfuncs, GLenum light, GLenum pname, const GLint* params);
+void gl2_1_glLighti(void *_glfuncs, GLenum light, GLenum pname, GLint param);
+void gl2_1_glLightfv(void *_glfuncs, GLenum light, GLenum pname, const GLfloat* params);
+void gl2_1_glLightf(void *_glfuncs, GLenum light, GLenum pname, GLfloat param);
+void gl2_1_glFogiv(void *_glfuncs, GLenum pname, const GLint* params);
+void gl2_1_glFogi(void *_glfuncs, GLenum pname, GLint param);
+void gl2_1_glFogfv(void *_glfuncs, GLenum pname, const GLfloat* params);
+void gl2_1_glFogf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl2_1_glColorMaterial(void *_glfuncs, GLenum face, GLenum mode);
+void gl2_1_glClipPlane(void *_glfuncs, GLenum plane, const GLdouble* equation);
+void gl2_1_glVertex4sv(void *_glfuncs, const GLshort* v);
+void gl2_1_glVertex4s(void *_glfuncs, GLshort x, GLshort y, GLshort z, GLshort w);
+void gl2_1_glVertex4iv(void *_glfuncs, const GLint* v);
+void gl2_1_glVertex4i(void *_glfuncs, GLint x, GLint y, GLint z, GLint w);
+void gl2_1_glVertex4fv(void *_glfuncs, const GLfloat* v);
+void gl2_1_glVertex4f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+void gl2_1_glVertex4dv(void *_glfuncs, const GLdouble* v);
+void gl2_1_glVertex4d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+void gl2_1_glVertex3sv(void *_glfuncs, const GLshort* v);
+void gl2_1_glVertex3s(void *_glfuncs, GLshort x, GLshort y, GLshort z);
+void gl2_1_glVertex3iv(void *_glfuncs, const GLint* v);
+void gl2_1_glVertex3i(void *_glfuncs, GLint x, GLint y, GLint z);
+void gl2_1_glVertex3fv(void *_glfuncs, const GLfloat* v);
+void gl2_1_glVertex3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl2_1_glVertex3dv(void *_glfuncs, const GLdouble* v);
+void gl2_1_glVertex3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl2_1_glVertex2sv(void *_glfuncs, const GLshort* v);
+void gl2_1_glVertex2s(void *_glfuncs, GLshort x, GLshort y);
+void gl2_1_glVertex2iv(void *_glfuncs, const GLint* v);
+void gl2_1_glVertex2i(void *_glfuncs, GLint x, GLint y);
+void gl2_1_glVertex2fv(void *_glfuncs, const GLfloat* v);
+void gl2_1_glVertex2f(void *_glfuncs, GLfloat x, GLfloat y);
+void gl2_1_glVertex2dv(void *_glfuncs, const GLdouble* v);
+void gl2_1_glVertex2d(void *_glfuncs, GLdouble x, GLdouble y);
+void gl2_1_glTexCoord4sv(void *_glfuncs, const GLshort* v);
+void gl2_1_glTexCoord4s(void *_glfuncs, GLshort s, GLshort t, GLshort r, GLshort q);
+void gl2_1_glTexCoord4iv(void *_glfuncs, const GLint* v);
+void gl2_1_glTexCoord4i(void *_glfuncs, GLint s, GLint t, GLint r, GLint q);
+void gl2_1_glTexCoord4fv(void *_glfuncs, const GLfloat* v);
+void gl2_1_glTexCoord4f(void *_glfuncs, GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+void gl2_1_glTexCoord4dv(void *_glfuncs, const GLdouble* v);
+void gl2_1_glTexCoord4d(void *_glfuncs, GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+void gl2_1_glTexCoord3sv(void *_glfuncs, const GLshort* v);
+void gl2_1_glTexCoord3s(void *_glfuncs, GLshort s, GLshort t, GLshort r);
+void gl2_1_glTexCoord3iv(void *_glfuncs, const GLint* v);
+void gl2_1_glTexCoord3i(void *_glfuncs, GLint s, GLint t, GLint r);
+void gl2_1_glTexCoord3fv(void *_glfuncs, const GLfloat* v);
+void gl2_1_glTexCoord3f(void *_glfuncs, GLfloat s, GLfloat t, GLfloat r);
+void gl2_1_glTexCoord3dv(void *_glfuncs, const GLdouble* v);
+void gl2_1_glTexCoord3d(void *_glfuncs, GLdouble s, GLdouble t, GLdouble r);
+void gl2_1_glTexCoord2sv(void *_glfuncs, const GLshort* v);
+void gl2_1_glTexCoord2s(void *_glfuncs, GLshort s, GLshort t);
+void gl2_1_glTexCoord2iv(void *_glfuncs, const GLint* v);
+void gl2_1_glTexCoord2i(void *_glfuncs, GLint s, GLint t);
+void gl2_1_glTexCoord2fv(void *_glfuncs, const GLfloat* v);
+void gl2_1_glTexCoord2f(void *_glfuncs, GLfloat s, GLfloat t);
+void gl2_1_glTexCoord2dv(void *_glfuncs, const GLdouble* v);
+void gl2_1_glTexCoord2d(void *_glfuncs, GLdouble s, GLdouble t);
+void gl2_1_glTexCoord1sv(void *_glfuncs, const GLshort* v);
+void gl2_1_glTexCoord1s(void *_glfuncs, GLshort s);
+void gl2_1_glTexCoord1iv(void *_glfuncs, const GLint* v);
+void gl2_1_glTexCoord1i(void *_glfuncs, GLint s);
+void gl2_1_glTexCoord1fv(void *_glfuncs, const GLfloat* v);
+void gl2_1_glTexCoord1f(void *_glfuncs, GLfloat s);
+void gl2_1_glTexCoord1dv(void *_glfuncs, const GLdouble* v);
+void gl2_1_glTexCoord1d(void *_glfuncs, GLdouble s);
+void gl2_1_glRectsv(void *_glfuncs, const GLshort* v1, const GLshort* v2);
+void gl2_1_glRects(void *_glfuncs, GLshort x1, GLshort y1, GLshort x2, GLshort y2);
+void gl2_1_glRectiv(void *_glfuncs, const GLint* v1, const GLint* v2);
+void gl2_1_glRecti(void *_glfuncs, GLint x1, GLint y1, GLint x2, GLint y2);
+void gl2_1_glRectfv(void *_glfuncs, const GLfloat* v1, const GLfloat* v2);
+void gl2_1_glRectf(void *_glfuncs, GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2);
+void gl2_1_glRectdv(void *_glfuncs, const GLdouble* v1, const GLdouble* v2);
+void gl2_1_glRectd(void *_glfuncs, GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2);
+void gl2_1_glRasterPos4sv(void *_glfuncs, const GLshort* v);
+void gl2_1_glRasterPos4s(void *_glfuncs, GLshort x, GLshort y, GLshort z, GLshort w);
+void gl2_1_glRasterPos4iv(void *_glfuncs, const GLint* v);
+void gl2_1_glRasterPos4i(void *_glfuncs, GLint x, GLint y, GLint z, GLint w);
+void gl2_1_glRasterPos4fv(void *_glfuncs, const GLfloat* v);
+void gl2_1_glRasterPos4f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+void gl2_1_glRasterPos4dv(void *_glfuncs, const GLdouble* v);
+void gl2_1_glRasterPos4d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+void gl2_1_glRasterPos3sv(void *_glfuncs, const GLshort* v);
+void gl2_1_glRasterPos3s(void *_glfuncs, GLshort x, GLshort y, GLshort z);
+void gl2_1_glRasterPos3iv(void *_glfuncs, const GLint* v);
+void gl2_1_glRasterPos3i(void *_glfuncs, GLint x, GLint y, GLint z);
+void gl2_1_glRasterPos3fv(void *_glfuncs, const GLfloat* v);
+void gl2_1_glRasterPos3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl2_1_glRasterPos3dv(void *_glfuncs, const GLdouble* v);
+void gl2_1_glRasterPos3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl2_1_glRasterPos2sv(void *_glfuncs, const GLshort* v);
+void gl2_1_glRasterPos2s(void *_glfuncs, GLshort x, GLshort y);
+void gl2_1_glRasterPos2iv(void *_glfuncs, const GLint* v);
+void gl2_1_glRasterPos2i(void *_glfuncs, GLint x, GLint y);
+void gl2_1_glRasterPos2fv(void *_glfuncs, const GLfloat* v);
+void gl2_1_glRasterPos2f(void *_glfuncs, GLfloat x, GLfloat y);
+void gl2_1_glRasterPos2dv(void *_glfuncs, const GLdouble* v);
+void gl2_1_glRasterPos2d(void *_glfuncs, GLdouble x, GLdouble y);
+void gl2_1_glNormal3sv(void *_glfuncs, const GLshort* v);
+void gl2_1_glNormal3s(void *_glfuncs, GLshort nx, GLshort ny, GLshort nz);
+void gl2_1_glNormal3iv(void *_glfuncs, const GLint* v);
+void gl2_1_glNormal3i(void *_glfuncs, GLint nx, GLint ny, GLint nz);
+void gl2_1_glNormal3fv(void *_glfuncs, const GLfloat* v);
+void gl2_1_glNormal3f(void *_glfuncs, GLfloat nx, GLfloat ny, GLfloat nz);
+void gl2_1_glNormal3dv(void *_glfuncs, const GLdouble* v);
+void gl2_1_glNormal3d(void *_glfuncs, GLdouble nx, GLdouble ny, GLdouble nz);
+void gl2_1_glNormal3bv(void *_glfuncs, const GLbyte* v);
+void gl2_1_glNormal3b(void *_glfuncs, GLbyte nx, GLbyte ny, GLbyte nz);
+void gl2_1_glIndexsv(void *_glfuncs, const GLshort* c);
+void gl2_1_glIndexs(void *_glfuncs, GLshort c);
+void gl2_1_glIndexiv(void *_glfuncs, const GLint* c);
+void gl2_1_glIndexi(void *_glfuncs, GLint c);
+void gl2_1_glIndexfv(void *_glfuncs, const GLfloat* c);
+void gl2_1_glIndexf(void *_glfuncs, GLfloat c);
+void gl2_1_glIndexdv(void *_glfuncs, const GLdouble* c);
+void gl2_1_glIndexd(void *_glfuncs, GLdouble c);
+void gl2_1_glEnd(void *_glfuncs);
+void gl2_1_glEdgeFlagv(void *_glfuncs, const GLboolean* flag);
+void gl2_1_glEdgeFlag(void *_glfuncs, GLboolean flag);
+void gl2_1_glColor4usv(void *_glfuncs, const GLushort* v);
+void gl2_1_glColor4us(void *_glfuncs, GLushort red, GLushort green, GLushort blue, GLushort alpha);
+void gl2_1_glColor4uiv(void *_glfuncs, const GLuint* v);
+void gl2_1_glColor4ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue, GLuint alpha);
+void gl2_1_glColor4ubv(void *_glfuncs, const GLubyte* v);
+void gl2_1_glColor4ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha);
+void gl2_1_glColor4sv(void *_glfuncs, const GLshort* v);
+void gl2_1_glColor4s(void *_glfuncs, GLshort red, GLshort green, GLshort blue, GLshort alpha);
+void gl2_1_glColor4iv(void *_glfuncs, const GLint* v);
+void gl2_1_glColor4i(void *_glfuncs, GLint red, GLint green, GLint blue, GLint alpha);
+void gl2_1_glColor4fv(void *_glfuncs, const GLfloat* v);
+void gl2_1_glColor4f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl2_1_glColor4dv(void *_glfuncs, const GLdouble* v);
+void gl2_1_glColor4d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha);
+void gl2_1_glColor4bv(void *_glfuncs, const GLbyte* v);
+void gl2_1_glColor4b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha);
+void gl2_1_glColor3usv(void *_glfuncs, const GLushort* v);
+void gl2_1_glColor3us(void *_glfuncs, GLushort red, GLushort green, GLushort blue);
+void gl2_1_glColor3uiv(void *_glfuncs, const GLuint* v);
+void gl2_1_glColor3ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue);
+void gl2_1_glColor3ubv(void *_glfuncs, const GLubyte* v);
+void gl2_1_glColor3ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue);
+void gl2_1_glColor3sv(void *_glfuncs, const GLshort* v);
+void gl2_1_glColor3s(void *_glfuncs, GLshort red, GLshort green, GLshort blue);
+void gl2_1_glColor3iv(void *_glfuncs, const GLint* v);
+void gl2_1_glColor3i(void *_glfuncs, GLint red, GLint green, GLint blue);
+void gl2_1_glColor3fv(void *_glfuncs, const GLfloat* v);
+void gl2_1_glColor3f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue);
+void gl2_1_glColor3dv(void *_glfuncs, const GLdouble* v);
+void gl2_1_glColor3d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue);
+void gl2_1_glColor3bv(void *_glfuncs, const GLbyte* v);
+void gl2_1_glColor3b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue);
+void gl2_1_glBitmap(void *_glfuncs, GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte* bitmap);
+void gl2_1_glBegin(void *_glfuncs, GLenum mode);
+void gl2_1_glListBase(void *_glfuncs, GLuint base);
+GLuint gl2_1_glGenLists(void *_glfuncs, GLsizei range_);
+void gl2_1_glDeleteLists(void *_glfuncs, GLuint list, GLsizei range_);
+void gl2_1_glCallLists(void *_glfuncs, GLsizei n, GLenum gltype, const GLvoid* lists);
+void gl2_1_glCallList(void *_glfuncs, GLuint list);
+void gl2_1_glEndList(void *_glfuncs);
+void gl2_1_glNewList(void *_glfuncs, GLuint list, GLenum mode);
+void gl2_1_glPushClientAttrib(void *_glfuncs, GLbitfield mask);
+void gl2_1_glPopClientAttrib(void *_glfuncs);
+void gl2_1_glPrioritizeTextures(void *_glfuncs, GLsizei n, const GLuint* textures, const GLfloat* priorities);
+GLboolean gl2_1_glAreTexturesResident(void *_glfuncs, GLsizei n, const GLuint* textures, GLboolean* residences);
+void gl2_1_glVertexPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl2_1_glTexCoordPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl2_1_glNormalPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl2_1_glInterleavedArrays(void *_glfuncs, GLenum format, GLsizei stride, const GLvoid* pointer);
+void gl2_1_glIndexPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl2_1_glEnableClientState(void *_glfuncs, GLenum array);
+void gl2_1_glEdgeFlagPointer(void *_glfuncs, GLsizei stride, const GLvoid* pointer);
+void gl2_1_glDisableClientState(void *_glfuncs, GLenum array);
+void gl2_1_glColorPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl2_1_glArrayElement(void *_glfuncs, GLint i);
+void gl2_1_glResetMinmax(void *_glfuncs, GLenum target);
+void gl2_1_glResetHistogram(void *_glfuncs, GLenum target);
+void gl2_1_glMinmax(void *_glfuncs, GLenum target, GLenum internalFormat, GLboolean sink);
+void gl2_1_glHistogram(void *_glfuncs, GLenum target, GLsizei width, GLenum internalFormat, GLboolean sink);
+void gl2_1_glGetMinmaxParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl2_1_glGetMinmaxParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl2_1_glGetMinmax(void *_glfuncs, GLenum target, GLboolean reset, GLenum format, GLenum gltype, GLvoid* values);
+void gl2_1_glGetHistogramParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl2_1_glGetHistogramParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl2_1_glGetHistogram(void *_glfuncs, GLenum target, GLboolean reset, GLenum format, GLenum gltype, GLvoid* values);
+void gl2_1_glSeparableFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* row, const GLvoid* column);
+void gl2_1_glGetSeparableFilter(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* row, GLvoid* column, GLvoid* span);
+void gl2_1_glGetConvolutionParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl2_1_glGetConvolutionParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl2_1_glGetConvolutionFilter(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* image);
+void gl2_1_glCopyConvolutionFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl2_1_glCopyConvolutionFilter1D(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width);
+void gl2_1_glConvolutionParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl2_1_glConvolutionParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint params);
+void gl2_1_glConvolutionParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl2_1_glConvolutionParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat params);
+void gl2_1_glConvolutionFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* image);
+void gl2_1_glConvolutionFilter1D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLenum format, GLenum gltype, const GLvoid* image);
+void gl2_1_glCopyColorSubTable(void *_glfuncs, GLenum target, GLsizei start, GLint x, GLint y, GLsizei width);
+void gl2_1_glColorSubTable(void *_glfuncs, GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum gltype, const GLvoid* data);
+void gl2_1_glGetColorTableParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl2_1_glGetColorTableParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl2_1_glGetColorTable(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* table);
+void gl2_1_glCopyColorTable(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width);
+void gl2_1_glColorTableParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl2_1_glColorTableParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl2_1_glColorTable(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLenum format, GLenum gltype, const GLvoid* table);
+void gl2_1_glMultTransposeMatrixd(void *_glfuncs, const GLdouble* m);
+void gl2_1_glMultTransposeMatrixf(void *_glfuncs, const GLfloat* m);
+void gl2_1_glLoadTransposeMatrixd(void *_glfuncs, const GLdouble* m);
+void gl2_1_glLoadTransposeMatrixf(void *_glfuncs, const GLfloat* m);
+void gl2_1_glMultiTexCoord4sv(void *_glfuncs, GLenum target, const GLshort* v);
+void gl2_1_glMultiTexCoord4s(void *_glfuncs, GLenum target, GLshort s, GLshort t, GLshort r, GLshort q);
+void gl2_1_glMultiTexCoord4iv(void *_glfuncs, GLenum target, const GLint* v);
+void gl2_1_glMultiTexCoord4i(void *_glfuncs, GLenum target, GLint s, GLint t, GLint r, GLint q);
+void gl2_1_glMultiTexCoord4fv(void *_glfuncs, GLenum target, const GLfloat* v);
+void gl2_1_glMultiTexCoord4f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+void gl2_1_glMultiTexCoord4dv(void *_glfuncs, GLenum target, const GLdouble* v);
+void gl2_1_glMultiTexCoord4d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+void gl2_1_glMultiTexCoord3sv(void *_glfuncs, GLenum target, const GLshort* v);
+void gl2_1_glMultiTexCoord3s(void *_glfuncs, GLenum target, GLshort s, GLshort t, GLshort r);
+void gl2_1_glMultiTexCoord3iv(void *_glfuncs, GLenum target, const GLint* v);
+void gl2_1_glMultiTexCoord3i(void *_glfuncs, GLenum target, GLint s, GLint t, GLint r);
+void gl2_1_glMultiTexCoord3fv(void *_glfuncs, GLenum target, const GLfloat* v);
+void gl2_1_glMultiTexCoord3f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t, GLfloat r);
+void gl2_1_glMultiTexCoord3dv(void *_glfuncs, GLenum target, const GLdouble* v);
+void gl2_1_glMultiTexCoord3d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t, GLdouble r);
+void gl2_1_glMultiTexCoord2sv(void *_glfuncs, GLenum target, const GLshort* v);
+void gl2_1_glMultiTexCoord2s(void *_glfuncs, GLenum target, GLshort s, GLshort t);
+void gl2_1_glMultiTexCoord2iv(void *_glfuncs, GLenum target, const GLint* v);
+void gl2_1_glMultiTexCoord2i(void *_glfuncs, GLenum target, GLint s, GLint t);
+void gl2_1_glMultiTexCoord2fv(void *_glfuncs, GLenum target, const GLfloat* v);
+void gl2_1_glMultiTexCoord2f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t);
+void gl2_1_glMultiTexCoord2dv(void *_glfuncs, GLenum target, const GLdouble* v);
+void gl2_1_glMultiTexCoord2d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t);
+void gl2_1_glMultiTexCoord1sv(void *_glfuncs, GLenum target, const GLshort* v);
+void gl2_1_glMultiTexCoord1s(void *_glfuncs, GLenum target, GLshort s);
+void gl2_1_glMultiTexCoord1iv(void *_glfuncs, GLenum target, const GLint* v);
+void gl2_1_glMultiTexCoord1i(void *_glfuncs, GLenum target, GLint s);
+void gl2_1_glMultiTexCoord1fv(void *_glfuncs, GLenum target, const GLfloat* v);
+void gl2_1_glMultiTexCoord1f(void *_glfuncs, GLenum target, GLfloat s);
+void gl2_1_glMultiTexCoord1dv(void *_glfuncs, GLenum target, const GLdouble* v);
+void gl2_1_glMultiTexCoord1d(void *_glfuncs, GLenum target, GLdouble s);
+void gl2_1_glClientActiveTexture(void *_glfuncs, GLenum texture);
+void gl2_1_glWindowPos3sv(void *_glfuncs, const GLshort* v);
+void gl2_1_glWindowPos3s(void *_glfuncs, GLshort x, GLshort y, GLshort z);
+void gl2_1_glWindowPos3iv(void *_glfuncs, const GLint* v);
+void gl2_1_glWindowPos3i(void *_glfuncs, GLint x, GLint y, GLint z);
+void gl2_1_glWindowPos3fv(void *_glfuncs, const GLfloat* v);
+void gl2_1_glWindowPos3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl2_1_glWindowPos3dv(void *_glfuncs, const GLdouble* v);
+void gl2_1_glWindowPos3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl2_1_glWindowPos2sv(void *_glfuncs, const GLshort* v);
+void gl2_1_glWindowPos2s(void *_glfuncs, GLshort x, GLshort y);
+void gl2_1_glWindowPos2iv(void *_glfuncs, const GLint* v);
+void gl2_1_glWindowPos2i(void *_glfuncs, GLint x, GLint y);
+void gl2_1_glWindowPos2fv(void *_glfuncs, const GLfloat* v);
+void gl2_1_glWindowPos2f(void *_glfuncs, GLfloat x, GLfloat y);
+void gl2_1_glWindowPos2dv(void *_glfuncs, const GLdouble* v);
+void gl2_1_glWindowPos2d(void *_glfuncs, GLdouble x, GLdouble y);
+void gl2_1_glSecondaryColorPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl2_1_glSecondaryColor3usv(void *_glfuncs, const GLushort* v);
+void gl2_1_glSecondaryColor3us(void *_glfuncs, GLushort red, GLushort green, GLushort blue);
+void gl2_1_glSecondaryColor3uiv(void *_glfuncs, const GLuint* v);
+void gl2_1_glSecondaryColor3ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue);
+void gl2_1_glSecondaryColor3ubv(void *_glfuncs, const GLubyte* v);
+void gl2_1_glSecondaryColor3ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue);
+void gl2_1_glSecondaryColor3sv(void *_glfuncs, const GLshort* v);
+void gl2_1_glSecondaryColor3s(void *_glfuncs, GLshort red, GLshort green, GLshort blue);
+void gl2_1_glSecondaryColor3iv(void *_glfuncs, const GLint* v);
+void gl2_1_glSecondaryColor3i(void *_glfuncs, GLint red, GLint green, GLint blue);
+void gl2_1_glSecondaryColor3fv(void *_glfuncs, const GLfloat* v);
+void gl2_1_glSecondaryColor3f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue);
+void gl2_1_glSecondaryColor3dv(void *_glfuncs, const GLdouble* v);
+void gl2_1_glSecondaryColor3d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue);
+void gl2_1_glSecondaryColor3bv(void *_glfuncs, const GLbyte* v);
+void gl2_1_glSecondaryColor3b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue);
+void gl2_1_glFogCoordPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl2_1_glFogCoorddv(void *_glfuncs, const GLdouble* coord);
+void gl2_1_glFogCoordd(void *_glfuncs, GLdouble coord);
+void gl2_1_glFogCoordfv(void *_glfuncs, const GLfloat* coord);
+void gl2_1_glFogCoordf(void *_glfuncs, GLfloat coord);
+void gl2_1_glVertexAttrib4usv(void *_glfuncs, GLuint index, const GLushort* v);
+void gl2_1_glVertexAttrib4uiv(void *_glfuncs, GLuint index, const GLuint* v);
+void gl2_1_glVertexAttrib4ubv(void *_glfuncs, GLuint index, const GLubyte* v);
+void gl2_1_glVertexAttrib4sv(void *_glfuncs, GLuint index, const GLshort* v);
+void gl2_1_glVertexAttrib4s(void *_glfuncs, GLuint index, GLshort x, GLshort y, GLshort z, GLshort w);
+void gl2_1_glVertexAttrib4iv(void *_glfuncs, GLuint index, const GLint* v);
+void gl2_1_glVertexAttrib4fv(void *_glfuncs, GLuint index, const GLfloat* v);
+void gl2_1_glVertexAttrib4f(void *_glfuncs, GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+void gl2_1_glVertexAttrib4dv(void *_glfuncs, GLuint index, const GLdouble* v);
+void gl2_1_glVertexAttrib4d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+void gl2_1_glVertexAttrib4bv(void *_glfuncs, GLuint index, const GLbyte* v);
+void gl2_1_glVertexAttrib4Nusv(void *_glfuncs, GLuint index, const GLushort* v);
+void gl2_1_glVertexAttrib4Nuiv(void *_glfuncs, GLuint index, const GLuint* v);
+void gl2_1_glVertexAttrib4Nubv(void *_glfuncs, GLuint index, const GLubyte* v);
+void gl2_1_glVertexAttrib4Nub(void *_glfuncs, GLuint index, GLubyte x, GLubyte y, GLubyte z, GLubyte w);
+void gl2_1_glVertexAttrib4Nsv(void *_glfuncs, GLuint index, const GLshort* v);
+void gl2_1_glVertexAttrib4Niv(void *_glfuncs, GLuint index, const GLint* v);
+void gl2_1_glVertexAttrib4Nbv(void *_glfuncs, GLuint index, const GLbyte* v);
+void gl2_1_glVertexAttrib3sv(void *_glfuncs, GLuint index, const GLshort* v);
+void gl2_1_glVertexAttrib3s(void *_glfuncs, GLuint index, GLshort x, GLshort y, GLshort z);
+void gl2_1_glVertexAttrib3fv(void *_glfuncs, GLuint index, const GLfloat* v);
+void gl2_1_glVertexAttrib3f(void *_glfuncs, GLuint index, GLfloat x, GLfloat y, GLfloat z);
+void gl2_1_glVertexAttrib3dv(void *_glfuncs, GLuint index, const GLdouble* v);
+void gl2_1_glVertexAttrib3d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y, GLdouble z);
+void gl2_1_glVertexAttrib2sv(void *_glfuncs, GLuint index, const GLshort* v);
+void gl2_1_glVertexAttrib2s(void *_glfuncs, GLuint index, GLshort x, GLshort y);
+void gl2_1_glVertexAttrib2fv(void *_glfuncs, GLuint index, const GLfloat* v);
+void gl2_1_glVertexAttrib2f(void *_glfuncs, GLuint index, GLfloat x, GLfloat y);
+void gl2_1_glVertexAttrib2dv(void *_glfuncs, GLuint index, const GLdouble* v);
+void gl2_1_glVertexAttrib2d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y);
+void gl2_1_glVertexAttrib1sv(void *_glfuncs, GLuint index, const GLshort* v);
+void gl2_1_glVertexAttrib1s(void *_glfuncs, GLuint index, GLshort x);
+void gl2_1_glVertexAttrib1fv(void *_glfuncs, GLuint index, const GLfloat* v);
+void gl2_1_glVertexAttrib1f(void *_glfuncs, GLuint index, GLfloat x);
+void gl2_1_glVertexAttrib1dv(void *_glfuncs, GLuint index, const GLdouble* v);
+void gl2_1_glVertexAttrib1d(void *_glfuncs, GLuint index, GLdouble x);
+
+
+#ifdef __cplusplus
+} // extern "C"
+#endif
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/2.1/gl.go b/Godeps/_workspace/src/github.com/obscuren/qml/gl/2.1/gl.go
new file mode 100644
index 000000000..718d258a3
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/2.1/gl.go
@@ -0,0 +1,6652 @@
+// ** file automatically generated by glgen -- do not edit manually **
+
+package GL
+
+// #cgo CXXFLAGS: -std=c++0x -pedantic-errors -Wall -fno-strict-aliasing
+// #cgo LDFLAGS: -lstdc++
+// #cgo pkg-config: Qt5Core Qt5OpenGL
+//
+// #include "funcs.h"
+//
+// void free(void*);
+//
+import "C"
+
+import (
+ "fmt"
+ "reflect"
+ "unsafe"
+
+ "gopkg.in/qml.v1/gl/glbase"
+)
+
+// API returns a value that offers methods matching the OpenGL version 2.1 API.
+//
+// The returned API must not be used after the provided OpenGL context becomes invalid.
+func API(context glbase.Contexter) *GL {
+ gl := &GL{}
+ gl.funcs = C.gl2_1_funcs()
+ if gl.funcs == nil {
+ panic(fmt.Errorf("OpenGL version 2.1 is not available"))
+ }
+ return gl
+}
+
+// GL implements the OpenGL version 2.1 API. Values of this
+// type must be created via the API function, and it must not be used after
+// the associated OpenGL context becomes invalid.
+type GL struct {
+ funcs unsafe.Pointer
+}
+
+const (
+ FALSE = 0
+ TRUE = 1
+ NONE = 0
+
+ BYTE = 0x1400
+ UNSIGNED_BYTE = 0x1401
+ SHORT = 0x1402
+ UNSIGNED_SHORT = 0x1403
+ INT = 0x1404
+ UNSIGNED_INT = 0x1405
+ FLOAT = 0x1406
+ N2_BYTES = 0x1407
+ N3_BYTES = 0x1408
+ N4_BYTES = 0x1409
+ DOUBLE = 0x140A
+
+ ACCUM = 0x0100
+ LOAD = 0x0101
+ RETURN = 0x0102
+ MULT = 0x0103
+ ADD = 0x0104
+
+ ACCUM_BUFFER_BIT = 0x00000200
+ ALL_ATTRIB_BITS = 0xFFFFFFFF
+ COLOR_BUFFER_BIT = 0x00004000
+ CURRENT_BIT = 0x00000001
+ DEPTH_BUFFER_BIT = 0x00000100
+ ENABLE_BIT = 0x00002000
+ EVAL_BIT = 0x00010000
+ FOG_BIT = 0x00000080
+ HINT_BIT = 0x00008000
+ LIGHTING_BIT = 0x00000040
+ LINE_BIT = 0x00000004
+ LIST_BIT = 0x00020000
+ MULTISAMPLE_BIT = 0x20000000
+ PIXEL_MODE_BIT = 0x00000020
+ POINT_BIT = 0x00000002
+ POLYGON_BIT = 0x00000008
+ POLYGON_STIPPLE_BIT = 0x00000010
+ SCISSOR_BIT = 0x00080000
+ STENCIL_BUFFER_BIT = 0x00000400
+ TEXTURE_BIT = 0x00040000
+ TRANSFORM_BIT = 0x00001000
+ VIEWPORT_BIT = 0x00000800
+
+ ALWAYS = 0x0207
+ EQUAL = 0x0202
+ GEQUAL = 0x0206
+ GREATER = 0x0204
+ LEQUAL = 0x0203
+ LESS = 0x0201
+ NEVER = 0x0200
+ NOTEQUAL = 0x0205
+
+ LOGIC_OP = 0x0BF1
+
+ DST_ALPHA = 0x0304
+ ONE = 1
+ ONE_MINUS_DST_ALPHA = 0x0305
+ ONE_MINUS_SRC_ALPHA = 0x0303
+ ONE_MINUS_SRC_COLOR = 0x0301
+ SRC_ALPHA = 0x0302
+ SRC_COLOR = 0x0300
+ ZERO = 0
+
+ DST_COLOR = 0x0306
+ ONE_MINUS_DST_COLOR = 0x0307
+ SRC_ALPHA_SATURATE = 0x0308
+
+ CLIENT_ALL_ATTRIB_BITS = 0xFFFFFFFF
+ CLIENT_PIXEL_STORE_BIT = 0x00000001
+ CLIENT_VERTEX_ARRAY_BIT = 0x00000002
+
+ CLIP_PLANE0 = 0x3000
+ CLIP_PLANE1 = 0x3001
+ CLIP_PLANE2 = 0x3002
+ CLIP_PLANE3 = 0x3003
+ CLIP_PLANE4 = 0x3004
+ CLIP_PLANE5 = 0x3005
+
+ BACK = 0x0405
+ FRONT = 0x0404
+ FRONT_AND_BACK = 0x0408
+
+ AMBIENT = 0x1200
+ AMBIENT_AND_DIFFUSE = 0x1602
+ DIFFUSE = 0x1201
+ EMISSION = 0x1600
+ SPECULAR = 0x1202
+
+ AUX0 = 0x0409
+ AUX1 = 0x040A
+ AUX2 = 0x040B
+ AUX3 = 0x040C
+ BACK_LEFT = 0x0402
+ BACK_RIGHT = 0x0403
+ FRONT_LEFT = 0x0400
+ FRONT_RIGHT = 0x0401
+ LEFT = 0x0406
+ RIGHT = 0x0407
+
+ ALPHA_TEST = 0x0BC0
+ AUTO_NORMAL = 0x0D80
+ BLEND = 0x0BE2
+ COLOR_ARRAY = 0x8076
+ COLOR_LOGIC_OP = 0x0BF2
+ COLOR_MATERIAL = 0x0B57
+ CULL_FACE = 0x0B44
+ DEPTH_TEST = 0x0B71
+ DITHER = 0x0BD0
+ EDGE_FLAG_ARRAY = 0x8079
+ FOG = 0x0B60
+ INDEX_ARRAY = 0x8077
+ INDEX_LOGIC_OP = 0x0BF1
+ LIGHT0 = 0x4000
+ LIGHT1 = 0x4001
+ LIGHT2 = 0x4002
+ LIGHT3 = 0x4003
+ LIGHT4 = 0x4004
+ LIGHT5 = 0x4005
+ LIGHT6 = 0x4006
+ LIGHT7 = 0x4007
+ LIGHTING = 0x0B50
+ LINE_SMOOTH = 0x0B20
+ LINE_STIPPLE = 0x0B24
+ MAP1_COLOR_4 = 0x0D90
+ MAP1_INDEX = 0x0D91
+ MAP1_NORMAL = 0x0D92
+ MAP1_TEXTURE_COORD_1 = 0x0D93
+ MAP1_TEXTURE_COORD_2 = 0x0D94
+ MAP1_TEXTURE_COORD_3 = 0x0D95
+ MAP1_TEXTURE_COORD_4 = 0x0D96
+ MAP1_VERTEX_3 = 0x0D97
+ MAP1_VERTEX_4 = 0x0D98
+ MAP2_COLOR_4 = 0x0DB0
+ MAP2_INDEX = 0x0DB1
+ MAP2_NORMAL = 0x0DB2
+ MAP2_TEXTURE_COORD_1 = 0x0DB3
+ MAP2_TEXTURE_COORD_2 = 0x0DB4
+ MAP2_TEXTURE_COORD_3 = 0x0DB5
+ MAP2_TEXTURE_COORD_4 = 0x0DB6
+ MAP2_VERTEX_3 = 0x0DB7
+ MAP2_VERTEX_4 = 0x0DB8
+ NORMALIZE = 0x0BA1
+ NORMAL_ARRAY = 0x8075
+ POINT_SMOOTH = 0x0B10
+ POLYGON_OFFSET_FILL = 0x8037
+ POLYGON_OFFSET_LINE = 0x2A02
+ POLYGON_OFFSET_POINT = 0x2A01
+ POLYGON_SMOOTH = 0x0B41
+ POLYGON_STIPPLE = 0x0B42
+ SCISSOR_TEST = 0x0C11
+ STENCIL_TEST = 0x0B90
+ TEXTURE_1D = 0x0DE0
+ TEXTURE_2D = 0x0DE1
+ TEXTURE_COORD_ARRAY = 0x8078
+ TEXTURE_GEN_Q = 0x0C63
+ TEXTURE_GEN_R = 0x0C62
+ TEXTURE_GEN_S = 0x0C60
+ TEXTURE_GEN_T = 0x0C61
+ VERTEX_ARRAY = 0x8074
+
+ INVALID_ENUM = 0x0500
+ INVALID_OPERATION = 0x0502
+ INVALID_VALUE = 0x0501
+ NO_ERROR = 0
+ OUT_OF_MEMORY = 0x0505
+ STACK_OVERFLOW = 0x0503
+ STACK_UNDERFLOW = 0x0504
+
+ N2D = 0x0600
+ N3D = 0x0601
+ N3D_COLOR = 0x0602
+ N3D_COLOR_TEXTURE = 0x0603
+ N4D_COLOR_TEXTURE = 0x0604
+
+ BITMAP_TOKEN = 0x0704
+ COPY_PIXEL_TOKEN = 0x0706
+ DRAW_PIXEL_TOKEN = 0x0705
+ LINE_RESET_TOKEN = 0x0707
+ LINE_TOKEN = 0x0702
+ PASS_THROUGH_TOKEN = 0x0700
+ POINT_TOKEN = 0x0701
+ POLYGON_TOKEN = 0x0703
+
+ EXP = 0x0800
+ EXP2 = 0x0801
+ LINEAR = 0x2601
+
+ FOG_COLOR = 0x0B66
+ FOG_DENSITY = 0x0B62
+ FOG_END = 0x0B64
+ FOG_INDEX = 0x0B61
+ FOG_MODE = 0x0B65
+ FOG_START = 0x0B63
+
+ CCW = 0x0901
+ CW = 0x0900
+
+ COEFF = 0x0A00
+ DOMAIN = 0x0A02
+ ORDER = 0x0A01
+
+ PIXEL_MAP_A_TO_A = 0x0C79
+ PIXEL_MAP_B_TO_B = 0x0C78
+ PIXEL_MAP_G_TO_G = 0x0C77
+ PIXEL_MAP_I_TO_A = 0x0C75
+ PIXEL_MAP_I_TO_B = 0x0C74
+ PIXEL_MAP_I_TO_G = 0x0C73
+ PIXEL_MAP_I_TO_I = 0x0C70
+ PIXEL_MAP_I_TO_R = 0x0C72
+ PIXEL_MAP_R_TO_R = 0x0C76
+ PIXEL_MAP_S_TO_S = 0x0C71
+
+ ACCUM_ALPHA_BITS = 0x0D5B
+ ACCUM_BLUE_BITS = 0x0D5A
+ ACCUM_CLEAR_VALUE = 0x0B80
+ ACCUM_GREEN_BITS = 0x0D59
+ ACCUM_RED_BITS = 0x0D58
+ ALIASED_LINE_WIDTH_RANGE = 0x846E
+ ALIASED_POINT_SIZE_RANGE = 0x846D
+ ALPHA_BIAS = 0x0D1D
+ ALPHA_BITS = 0x0D55
+ ALPHA_SCALE = 0x0D1C
+ ALPHA_TEST_FUNC = 0x0BC1
+ ALPHA_TEST_REF = 0x0BC2
+ ATTRIB_STACK_DEPTH = 0x0BB0
+ AUX_BUFFERS = 0x0C00
+ BLEND_DST = 0x0BE0
+ BLEND_SRC = 0x0BE1
+ BLUE_BIAS = 0x0D1B
+ BLUE_BITS = 0x0D54
+ BLUE_SCALE = 0x0D1A
+ CLIENT_ATTRIB_STACK_DEPTH = 0x0BB1
+ COLOR_ARRAY_SIZE = 0x8081
+ COLOR_ARRAY_STRIDE = 0x8083
+ COLOR_ARRAY_TYPE = 0x8082
+ COLOR_CLEAR_VALUE = 0x0C22
+ COLOR_MATERIAL_FACE = 0x0B55
+ COLOR_MATERIAL_PARAMETER = 0x0B56
+ COLOR_WRITEMASK = 0x0C23
+ CULL_FACE_MODE = 0x0B45
+ CURRENT_COLOR = 0x0B00
+ CURRENT_INDEX = 0x0B01
+ CURRENT_NORMAL = 0x0B02
+ CURRENT_RASTER_COLOR = 0x0B04
+ CURRENT_RASTER_DISTANCE = 0x0B09
+ CURRENT_RASTER_INDEX = 0x0B05
+ CURRENT_RASTER_POSITION = 0x0B07
+ CURRENT_RASTER_POSITION_VALID = 0x0B08
+ CURRENT_RASTER_TEXTURE_COORDS = 0x0B06
+ CURRENT_TEXTURE_COORDS = 0x0B03
+ DEPTH_BIAS = 0x0D1F
+ DEPTH_BITS = 0x0D56
+ DEPTH_CLEAR_VALUE = 0x0B73
+ DEPTH_FUNC = 0x0B74
+ DEPTH_RANGE = 0x0B70
+ DEPTH_SCALE = 0x0D1E
+ DEPTH_WRITEMASK = 0x0B72
+ DOUBLEBUFFER = 0x0C32
+ DRAW_BUFFER = 0x0C01
+ EDGE_FLAG = 0x0B43
+ EDGE_FLAG_ARRAY_STRIDE = 0x808C
+ FEEDBACK_BUFFER_SIZE = 0x0DF1
+ FEEDBACK_BUFFER_TYPE = 0x0DF2
+ FOG_HINT = 0x0C54
+ FRONT_FACE = 0x0B46
+ GREEN_BIAS = 0x0D19
+ GREEN_BITS = 0x0D53
+ GREEN_SCALE = 0x0D18
+ INDEX_ARRAY_STRIDE = 0x8086
+ INDEX_ARRAY_TYPE = 0x8085
+ INDEX_BITS = 0x0D51
+ INDEX_CLEAR_VALUE = 0x0C20
+ INDEX_MODE = 0x0C30
+ INDEX_OFFSET = 0x0D13
+ INDEX_SHIFT = 0x0D12
+ INDEX_WRITEMASK = 0x0C21
+ LIGHT_MODEL_AMBIENT = 0x0B53
+ LIGHT_MODEL_COLOR_CONTROL = 0x81F8
+ LIGHT_MODEL_LOCAL_VIEWER = 0x0B51
+ LIGHT_MODEL_TWO_SIDE = 0x0B52
+ LINE_SMOOTH_HINT = 0x0C52
+ LINE_STIPPLE_PATTERN = 0x0B25
+ LINE_STIPPLE_REPEAT = 0x0B26
+ LINE_WIDTH = 0x0B21
+ LINE_WIDTH_GRANULARITY = 0x0B23
+ LINE_WIDTH_RANGE = 0x0B22
+ LIST_BASE = 0x0B32
+ LIST_INDEX = 0x0B33
+ LIST_MODE = 0x0B30
+ LOGIC_OP_MODE = 0x0BF0
+ MAP1_GRID_DOMAIN = 0x0DD0
+ MAP1_GRID_SEGMENTS = 0x0DD1
+ MAP2_GRID_DOMAIN = 0x0DD2
+ MAP2_GRID_SEGMENTS = 0x0DD3
+ MAP_COLOR = 0x0D10
+ MAP_STENCIL = 0x0D11
+ MATRIX_MODE = 0x0BA0
+ MAX_ATTRIB_STACK_DEPTH = 0x0D35
+ MAX_CLIENT_ATTRIB_STACK_DEPTH = 0x0D3B
+ MAX_CLIP_PLANES = 0x0D32
+ MAX_EVAL_ORDER = 0x0D30
+ MAX_LIGHTS = 0x0D31
+ MAX_LIST_NESTING = 0x0B31
+ MAX_MODELVIEW_STACK_DEPTH = 0x0D36
+ MAX_NAME_STACK_DEPTH = 0x0D37
+ MAX_PIXEL_MAP_TABLE = 0x0D34
+ MAX_PROJECTION_STACK_DEPTH = 0x0D38
+ MAX_TEXTURE_SIZE = 0x0D33
+ MAX_TEXTURE_STACK_DEPTH = 0x0D39
+ MAX_VIEWPORT_DIMS = 0x0D3A
+ MODELVIEW_MATRIX = 0x0BA6
+ MODELVIEW_STACK_DEPTH = 0x0BA3
+ NAME_STACK_DEPTH = 0x0D70
+ NORMAL_ARRAY_STRIDE = 0x807F
+ NORMAL_ARRAY_TYPE = 0x807E
+ PACK_ALIGNMENT = 0x0D05
+ PACK_LSB_FIRST = 0x0D01
+ PACK_ROW_LENGTH = 0x0D02
+ PACK_SKIP_PIXELS = 0x0D04
+ PACK_SKIP_ROWS = 0x0D03
+ PACK_SWAP_BYTES = 0x0D00
+ PERSPECTIVE_CORRECTION_HINT = 0x0C50
+ PIXEL_MAP_A_TO_A_SIZE = 0x0CB9
+ PIXEL_MAP_B_TO_B_SIZE = 0x0CB8
+ PIXEL_MAP_G_TO_G_SIZE = 0x0CB7
+ PIXEL_MAP_I_TO_A_SIZE = 0x0CB5
+ PIXEL_MAP_I_TO_B_SIZE = 0x0CB4
+ PIXEL_MAP_I_TO_G_SIZE = 0x0CB3
+ PIXEL_MAP_I_TO_I_SIZE = 0x0CB0
+ PIXEL_MAP_I_TO_R_SIZE = 0x0CB2
+ PIXEL_MAP_R_TO_R_SIZE = 0x0CB6
+ PIXEL_MAP_S_TO_S_SIZE = 0x0CB1
+ POINT_SIZE = 0x0B11
+ POINT_SIZE_GRANULARITY = 0x0B13
+ POINT_SIZE_RANGE = 0x0B12
+ POINT_SMOOTH_HINT = 0x0C51
+ POLYGON_MODE = 0x0B40
+ POLYGON_OFFSET_FACTOR = 0x8038
+ POLYGON_OFFSET_UNITS = 0x2A00
+ POLYGON_SMOOTH_HINT = 0x0C53
+ PROJECTION_MATRIX = 0x0BA7
+ PROJECTION_STACK_DEPTH = 0x0BA4
+ READ_BUFFER = 0x0C02
+ RED_BIAS = 0x0D15
+ RED_BITS = 0x0D52
+ RED_SCALE = 0x0D14
+ RENDER_MODE = 0x0C40
+ RGBA_MODE = 0x0C31
+ SCISSOR_BOX = 0x0C10
+ SELECTION_BUFFER_SIZE = 0x0DF4
+ SHADE_MODEL = 0x0B54
+ SMOOTH_LINE_WIDTH_GRANULARITY = 0x0B23
+ SMOOTH_LINE_WIDTH_RANGE = 0x0B22
+ SMOOTH_POINT_SIZE_GRANULARITY = 0x0B13
+ SMOOTH_POINT_SIZE_RANGE = 0x0B12
+ STENCIL_BITS = 0x0D57
+ STENCIL_CLEAR_VALUE = 0x0B91
+ STENCIL_FAIL = 0x0B94
+ STENCIL_FUNC = 0x0B92
+ STENCIL_PASS_DEPTH_FAIL = 0x0B95
+ STENCIL_PASS_DEPTH_PASS = 0x0B96
+ STENCIL_REF = 0x0B97
+ STENCIL_VALUE_MASK = 0x0B93
+ STENCIL_WRITEMASK = 0x0B98
+ STEREO = 0x0C33
+ SUBPIXEL_BITS = 0x0D50
+ TEXTURE_BINDING_1D = 0x8068
+ TEXTURE_BINDING_2D = 0x8069
+ TEXTURE_BINDING_3D = 0x806A
+ TEXTURE_COORD_ARRAY_SIZE = 0x8088
+ TEXTURE_COORD_ARRAY_STRIDE = 0x808A
+ TEXTURE_COORD_ARRAY_TYPE = 0x8089
+ TEXTURE_MATRIX = 0x0BA8
+ TEXTURE_STACK_DEPTH = 0x0BA5
+ UNPACK_ALIGNMENT = 0x0CF5
+ UNPACK_LSB_FIRST = 0x0CF1
+ UNPACK_ROW_LENGTH = 0x0CF2
+ UNPACK_SKIP_PIXELS = 0x0CF4
+ UNPACK_SKIP_ROWS = 0x0CF3
+ UNPACK_SWAP_BYTES = 0x0CF0
+ VERTEX_ARRAY_SIZE = 0x807A
+ VERTEX_ARRAY_STRIDE = 0x807C
+ VERTEX_ARRAY_TYPE = 0x807B
+ VIEWPORT = 0x0BA2
+ ZOOM_X = 0x0D16
+ ZOOM_Y = 0x0D17
+
+ COLOR_ARRAY_POINTER = 0x8090
+ EDGE_FLAG_ARRAY_POINTER = 0x8093
+ FEEDBACK_BUFFER_POINTER = 0x0DF0
+ INDEX_ARRAY_POINTER = 0x8091
+ NORMAL_ARRAY_POINTER = 0x808F
+ SELECTION_BUFFER_POINTER = 0x0DF3
+ TEXTURE_COORD_ARRAY_POINTER = 0x8092
+ VERTEX_ARRAY_POINTER = 0x808E
+
+ TEXTURE_ALPHA_SIZE = 0x805F
+ TEXTURE_BLUE_SIZE = 0x805E
+ TEXTURE_BORDER = 0x1005
+ TEXTURE_BORDER_COLOR = 0x1004
+ TEXTURE_COMPONENTS = 0x1003
+ TEXTURE_GREEN_SIZE = 0x805D
+ TEXTURE_HEIGHT = 0x1001
+ TEXTURE_INTENSITY_SIZE = 0x8061
+ TEXTURE_INTERNAL_FORMAT = 0x1003
+ TEXTURE_LUMINANCE_SIZE = 0x8060
+ TEXTURE_MAG_FILTER = 0x2800
+ TEXTURE_MIN_FILTER = 0x2801
+ TEXTURE_PRIORITY = 0x8066
+ TEXTURE_RED_SIZE = 0x805C
+ TEXTURE_RESIDENT = 0x8067
+ TEXTURE_WIDTH = 0x1000
+ TEXTURE_WRAP_S = 0x2802
+ TEXTURE_WRAP_T = 0x2803
+
+ DONT_CARE = 0x1100
+ FASTEST = 0x1101
+ NICEST = 0x1102
+
+ FRAGMENT_SHADER_DERIVATIVE_HINT = 0x8B8B
+ GENERATE_MIPMAP_HINT = 0x8192
+ TEXTURE_COMPRESSION_HINT = 0x84EF
+
+ C3F_V3F = 0x2A24
+ C4F_N3F_V3F = 0x2A26
+ C4UB_V2F = 0x2A22
+ C4UB_V3F = 0x2A23
+ N3F_V3F = 0x2A25
+ T2F_C3F_V3F = 0x2A2A
+ T2F_C4F_N3F_V3F = 0x2A2C
+ T2F_C4UB_V3F = 0x2A29
+ T2F_N3F_V3F = 0x2A2B
+ T2F_V3F = 0x2A27
+ T4F_C4F_N3F_V4F = 0x2A2D
+ T4F_V4F = 0x2A28
+ V2F = 0x2A20
+ V3F = 0x2A21
+
+ MODULATE = 0x2100
+ REPLACE = 0x1E01
+
+ SEPARATE_SPECULAR_COLOR = 0x81FA
+ SINGLE_COLOR = 0x81F9
+
+ CONSTANT_ATTENUATION = 0x1207
+ LINEAR_ATTENUATION = 0x1208
+ POSITION = 0x1203
+ QUADRATIC_ATTENUATION = 0x1209
+ SPOT_CUTOFF = 0x1206
+ SPOT_DIRECTION = 0x1204
+ SPOT_EXPONENT = 0x1205
+
+ COMPILE = 0x1300
+ COMPILE_AND_EXECUTE = 0x1301
+
+ AND = 0x1501
+ AND_INVERTED = 0x1504
+ AND_REVERSE = 0x1502
+ CLEAR = 0x1500
+ COPY = 0x1503
+ COPY_INVERTED = 0x150C
+ EQUIV = 0x1509
+ INVERT = 0x150A
+ NAND = 0x150E
+ NOOP = 0x1505
+ NOR = 0x1508
+ OR = 0x1507
+ OR_INVERTED = 0x150D
+ OR_REVERSE = 0x150B
+ SET = 0x150F
+ XOR = 0x1506
+
+ COLOR_INDEXES = 0x1603
+ SHININESS = 0x1601
+
+ MODELVIEW = 0x1700
+ PROJECTION = 0x1701
+ TEXTURE = 0x1702
+
+ LINE = 0x1B01
+ POINT = 0x1B00
+
+ FILL = 0x1B02
+
+ COLOR = 0x1800
+ DEPTH = 0x1801
+ STENCIL = 0x1802
+
+ ALPHA = 0x1906
+ BLUE = 0x1905
+ COLOR_INDEX = 0x1900
+ DEPTH_COMPONENT = 0x1902
+ GREEN = 0x1904
+ LUMINANCE = 0x1909
+ LUMINANCE_ALPHA = 0x190A
+ RED = 0x1903
+ RGB = 0x1907
+ RGBA = 0x1908
+ STENCIL_INDEX = 0x1901
+
+ ALPHA12 = 0x803D
+ ALPHA16 = 0x803E
+ ALPHA4 = 0x803B
+ ALPHA8 = 0x803C
+ INTENSITY = 0x8049
+ INTENSITY12 = 0x804C
+ INTENSITY16 = 0x804D
+ INTENSITY4 = 0x804A
+ INTENSITY8 = 0x804B
+ LUMINANCE12 = 0x8041
+ LUMINANCE12_ALPHA12 = 0x8047
+ LUMINANCE12_ALPHA4 = 0x8046
+ LUMINANCE16 = 0x8042
+ LUMINANCE16_ALPHA16 = 0x8048
+ LUMINANCE4 = 0x803F
+ LUMINANCE4_ALPHA4 = 0x8043
+ LUMINANCE6_ALPHA2 = 0x8044
+ LUMINANCE8 = 0x8040
+ LUMINANCE8_ALPHA8 = 0x8045
+ R3_G3_B2 = 0x2A10
+ RGB10 = 0x8052
+ RGB10_A2 = 0x8059
+ RGB12 = 0x8053
+ RGB16 = 0x8054
+ RGB4 = 0x804F
+ RGB5 = 0x8050
+ RGB5_A1 = 0x8057
+ RGB8 = 0x8051
+ RGBA12 = 0x805A
+ RGBA16 = 0x805B
+ RGBA2 = 0x8055
+ RGBA4 = 0x8056
+ RGBA8 = 0x8058
+
+ PACK_IMAGE_HEIGHT = 0x806C
+ PACK_SKIP_IMAGES = 0x806B
+ UNPACK_IMAGE_HEIGHT = 0x806E
+ UNPACK_SKIP_IMAGES = 0x806D
+
+ BITMAP = 0x1A00
+ UNSIGNED_BYTE_3_3_2 = 0x8032
+ UNSIGNED_INT_10_10_10_2 = 0x8036
+ UNSIGNED_INT_8_8_8_8 = 0x8035
+ UNSIGNED_SHORT_4_4_4_4 = 0x8033
+ UNSIGNED_SHORT_5_5_5_1 = 0x8034
+
+ POINT_DISTANCE_ATTENUATION = 0x8129
+ POINT_FADE_THRESHOLD_SIZE = 0x8128
+ POINT_SIZE_MAX = 0x8127
+ POINT_SIZE_MIN = 0x8126
+
+ LINES = 0x0001
+ LINE_LOOP = 0x0002
+ LINE_STRIP = 0x0003
+ POINTS = 0x0000
+ POLYGON = 0x0009
+ QUADS = 0x0007
+ QUAD_STRIP = 0x0008
+ TRIANGLES = 0x0004
+ TRIANGLE_FAN = 0x0006
+ TRIANGLE_STRIP = 0x0005
+
+ FEEDBACK = 0x1C01
+ RENDER = 0x1C00
+ SELECT = 0x1C02
+
+ FLAT = 0x1D00
+ SMOOTH = 0x1D01
+
+ DECR = 0x1E03
+ INCR = 0x1E02
+ KEEP = 0x1E00
+
+ EXTENSIONS = 0x1F03
+ RENDERER = 0x1F01
+ VENDOR = 0x1F00
+ VERSION = 0x1F02
+
+ S = 0x2000
+ T = 0x2001
+ R = 0x2002
+ Q = 0x2003
+
+ DECAL = 0x2101
+
+ TEXTURE_ENV_COLOR = 0x2201
+ TEXTURE_ENV_MODE = 0x2200
+
+ TEXTURE_ENV = 0x2300
+
+ EYE_LINEAR = 0x2400
+ OBJECT_LINEAR = 0x2401
+ SPHERE_MAP = 0x2402
+
+ EYE_PLANE = 0x2502
+ OBJECT_PLANE = 0x2501
+ TEXTURE_GEN_MODE = 0x2500
+
+ NEAREST = 0x2600
+
+ LINEAR_MIPMAP_LINEAR = 0x2703
+ LINEAR_MIPMAP_NEAREST = 0x2701
+ NEAREST_MIPMAP_LINEAR = 0x2702
+ NEAREST_MIPMAP_NEAREST = 0x2700
+
+ GENERATE_MIPMAP = 0x8191
+ TEXTURE_WRAP_R = 0x8072
+
+ PROXY_TEXTURE_1D = 0x8063
+ PROXY_TEXTURE_2D = 0x8064
+ PROXY_TEXTURE_3D = 0x8070
+ TEXTURE_3D = 0x806F
+ TEXTURE_BASE_LEVEL = 0x813C
+ TEXTURE_MAX_LEVEL = 0x813D
+ TEXTURE_MAX_LOD = 0x813B
+ TEXTURE_MIN_LOD = 0x813A
+
+ CLAMP = 0x2900
+ CLAMP_TO_BORDER = 0x812D
+ CLAMP_TO_EDGE = 0x812F
+ REPEAT = 0x2901
+
+ CONSTANT_COLOR = 0x8001
+ ONE_MINUS_CONSTANT_COLOR = 0x8002
+ CONSTANT_ALPHA = 0x8003
+ ONE_MINUS_CONSTANT_ALPHA = 0x8004
+ FUNC_ADD = 0x8006
+ MIN = 0x8007
+ MAX = 0x8008
+ BLEND_EQUATION_RGB = 0x8009
+ FUNC_SUBTRACT = 0x800A
+ FUNC_REVERSE_SUBTRACT = 0x800B
+ RESCALE_NORMAL = 0x803A
+ TEXTURE_DEPTH = 0x8071
+ MAX_3D_TEXTURE_SIZE = 0x8073
+ MULTISAMPLE = 0x809D
+ SAMPLE_ALPHA_TO_COVERAGE = 0x809E
+ SAMPLE_ALPHA_TO_ONE = 0x809F
+ SAMPLE_COVERAGE = 0x80A0
+ SAMPLE_BUFFERS = 0x80A8
+ SAMPLES = 0x80A9
+ SAMPLE_COVERAGE_VALUE = 0x80AA
+ SAMPLE_COVERAGE_INVERT = 0x80AB
+ BLEND_DST_RGB = 0x80C8
+ BLEND_SRC_RGB = 0x80C9
+ BLEND_DST_ALPHA = 0x80CA
+ BLEND_SRC_ALPHA = 0x80CB
+ BGR = 0x80E0
+ BGRA = 0x80E1
+ MAX_ELEMENTS_VERTICES = 0x80E8
+ MAX_ELEMENTS_INDICES = 0x80E9
+ DEPTH_COMPONENT16 = 0x81A5
+ DEPTH_COMPONENT24 = 0x81A6
+ DEPTH_COMPONENT32 = 0x81A7
+ UNSIGNED_BYTE_2_3_3_REV = 0x8362
+ UNSIGNED_SHORT_5_6_5 = 0x8363
+ UNSIGNED_SHORT_5_6_5_REV = 0x8364
+ UNSIGNED_SHORT_4_4_4_4_REV = 0x8365
+ UNSIGNED_SHORT_1_5_5_5_REV = 0x8366
+ UNSIGNED_INT_8_8_8_8_REV = 0x8367
+ UNSIGNED_INT_2_10_10_10_REV = 0x8368
+ MIRRORED_REPEAT = 0x8370
+ FOG_COORDINATE_SOURCE = 0x8450
+ FOG_COORD_SRC = 0x8450
+ FOG_COORDINATE = 0x8451
+ FOG_COORD = 0x8451
+ FRAGMENT_DEPTH = 0x8452
+ CURRENT_FOG_COORDINATE = 0x8453
+ CURRENT_FOG_COORD = 0x8453
+ FOG_COORDINATE_ARRAY_TYPE = 0x8454
+ FOG_COORD_ARRAY_TYPE = 0x8454
+ FOG_COORDINATE_ARRAY_STRIDE = 0x8455
+ FOG_COORD_ARRAY_STRIDE = 0x8455
+ FOG_COORDINATE_ARRAY_POINTER = 0x8456
+ FOG_COORD_ARRAY_POINTER = 0x8456
+ FOG_COORDINATE_ARRAY = 0x8457
+ FOG_COORD_ARRAY = 0x8457
+ COLOR_SUM = 0x8458
+ CURRENT_SECONDARY_COLOR = 0x8459
+ SECONDARY_COLOR_ARRAY_SIZE = 0x845A
+ SECONDARY_COLOR_ARRAY_TYPE = 0x845B
+ SECONDARY_COLOR_ARRAY_STRIDE = 0x845C
+ SECONDARY_COLOR_ARRAY_POINTER = 0x845D
+ SECONDARY_COLOR_ARRAY = 0x845E
+ CURRENT_RASTER_SECONDARY_COLOR = 0x845F
+ TEXTURE0 = 0x84C0
+ TEXTURE1 = 0x84C1
+ TEXTURE2 = 0x84C2
+ TEXTURE3 = 0x84C3
+ TEXTURE4 = 0x84C4
+ TEXTURE5 = 0x84C5
+ TEXTURE6 = 0x84C6
+ TEXTURE7 = 0x84C7
+ TEXTURE8 = 0x84C8
+ TEXTURE9 = 0x84C9
+ TEXTURE10 = 0x84CA
+ TEXTURE11 = 0x84CB
+ TEXTURE12 = 0x84CC
+ TEXTURE13 = 0x84CD
+ TEXTURE14 = 0x84CE
+ TEXTURE15 = 0x84CF
+ TEXTURE16 = 0x84D0
+ TEXTURE17 = 0x84D1
+ TEXTURE18 = 0x84D2
+ TEXTURE19 = 0x84D3
+ TEXTURE20 = 0x84D4
+ TEXTURE21 = 0x84D5
+ TEXTURE22 = 0x84D6
+ TEXTURE23 = 0x84D7
+ TEXTURE24 = 0x84D8
+ TEXTURE25 = 0x84D9
+ TEXTURE26 = 0x84DA
+ TEXTURE27 = 0x84DB
+ TEXTURE28 = 0x84DC
+ TEXTURE29 = 0x84DD
+ TEXTURE30 = 0x84DE
+ TEXTURE31 = 0x84DF
+ ACTIVE_TEXTURE = 0x84E0
+ CLIENT_ACTIVE_TEXTURE = 0x84E1
+ MAX_TEXTURE_UNITS = 0x84E2
+ TRANSPOSE_MODELVIEW_MATRIX = 0x84E3
+ TRANSPOSE_PROJECTION_MATRIX = 0x84E4
+ TRANSPOSE_TEXTURE_MATRIX = 0x84E5
+ TRANSPOSE_COLOR_MATRIX = 0x84E6
+ SUBTRACT = 0x84E7
+ COMPRESSED_ALPHA = 0x84E9
+ COMPRESSED_LUMINANCE = 0x84EA
+ COMPRESSED_LUMINANCE_ALPHA = 0x84EB
+ COMPRESSED_INTENSITY = 0x84EC
+ COMPRESSED_RGB = 0x84ED
+ COMPRESSED_RGBA = 0x84EE
+ MAX_TEXTURE_LOD_BIAS = 0x84FD
+ TEXTURE_FILTER_CONTROL = 0x8500
+ TEXTURE_LOD_BIAS = 0x8501
+ INCR_WRAP = 0x8507
+ DECR_WRAP = 0x8508
+ NORMAL_MAP = 0x8511
+ REFLECTION_MAP = 0x8512
+ TEXTURE_CUBE_MAP = 0x8513
+ TEXTURE_BINDING_CUBE_MAP = 0x8514
+ TEXTURE_CUBE_MAP_POSITIVE_X = 0x8515
+ TEXTURE_CUBE_MAP_NEGATIVE_X = 0x8516
+ TEXTURE_CUBE_MAP_POSITIVE_Y = 0x8517
+ TEXTURE_CUBE_MAP_NEGATIVE_Y = 0x8518
+ TEXTURE_CUBE_MAP_POSITIVE_Z = 0x8519
+ TEXTURE_CUBE_MAP_NEGATIVE_Z = 0x851A
+ PROXY_TEXTURE_CUBE_MAP = 0x851B
+ MAX_CUBE_MAP_TEXTURE_SIZE = 0x851C
+ COMBINE = 0x8570
+ COMBINE_RGB = 0x8571
+ COMBINE_ALPHA = 0x8572
+ RGB_SCALE = 0x8573
+ ADD_SIGNED = 0x8574
+ INTERPOLATE = 0x8575
+ CONSTANT = 0x8576
+ PRIMARY_COLOR = 0x8577
+ PREVIOUS = 0x8578
+ SOURCE0_RGB = 0x8580
+ SRC0_RGB = 0x8580
+ SOURCE1_RGB = 0x8581
+ SRC1_RGB = 0x8581
+ SOURCE2_RGB = 0x8582
+ SRC2_RGB = 0x8582
+ SOURCE0_ALPHA = 0x8588
+ SRC0_ALPHA = 0x8588
+ SOURCE1_ALPHA = 0x8589
+ SRC1_ALPHA = 0x8589
+ SOURCE2_ALPHA = 0x858A
+ SRC2_ALPHA = 0x858A
+ OPERAND0_RGB = 0x8590
+ OPERAND1_RGB = 0x8591
+ OPERAND2_RGB = 0x8592
+ OPERAND0_ALPHA = 0x8598
+ OPERAND1_ALPHA = 0x8599
+ OPERAND2_ALPHA = 0x859A
+ VERTEX_ATTRIB_ARRAY_ENABLED = 0x8622
+ VERTEX_ATTRIB_ARRAY_SIZE = 0x8623
+ VERTEX_ATTRIB_ARRAY_STRIDE = 0x8624
+ VERTEX_ATTRIB_ARRAY_TYPE = 0x8625
+ CURRENT_VERTEX_ATTRIB = 0x8626
+ VERTEX_PROGRAM_POINT_SIZE = 0x8642
+ VERTEX_PROGRAM_TWO_SIDE = 0x8643
+ VERTEX_ATTRIB_ARRAY_POINTER = 0x8645
+ TEXTURE_COMPRESSED_IMAGE_SIZE = 0x86A0
+ TEXTURE_COMPRESSED = 0x86A1
+ NUM_COMPRESSED_TEXTURE_FORMATS = 0x86A2
+ COMPRESSED_TEXTURE_FORMATS = 0x86A3
+ DOT3_RGB = 0x86AE
+ DOT3_RGBA = 0x86AF
+ BUFFER_SIZE = 0x8764
+ BUFFER_USAGE = 0x8765
+ STENCIL_BACK_FUNC = 0x8800
+ STENCIL_BACK_FAIL = 0x8801
+ STENCIL_BACK_PASS_DEPTH_FAIL = 0x8802
+ STENCIL_BACK_PASS_DEPTH_PASS = 0x8803
+ MAX_DRAW_BUFFERS = 0x8824
+ DRAW_BUFFER0 = 0x8825
+ DRAW_BUFFER1 = 0x8826
+ DRAW_BUFFER2 = 0x8827
+ DRAW_BUFFER3 = 0x8828
+ DRAW_BUFFER4 = 0x8829
+ DRAW_BUFFER5 = 0x882A
+ DRAW_BUFFER6 = 0x882B
+ DRAW_BUFFER7 = 0x882C
+ DRAW_BUFFER8 = 0x882D
+ DRAW_BUFFER9 = 0x882E
+ DRAW_BUFFER10 = 0x882F
+ DRAW_BUFFER11 = 0x8830
+ DRAW_BUFFER12 = 0x8831
+ DRAW_BUFFER13 = 0x8832
+ DRAW_BUFFER14 = 0x8833
+ DRAW_BUFFER15 = 0x8834
+ BLEND_EQUATION_ALPHA = 0x883D
+ TEXTURE_DEPTH_SIZE = 0x884A
+ DEPTH_TEXTURE_MODE = 0x884B
+ TEXTURE_COMPARE_MODE = 0x884C
+ TEXTURE_COMPARE_FUNC = 0x884D
+ COMPARE_R_TO_TEXTURE = 0x884E
+ POINT_SPRITE = 0x8861
+ COORD_REPLACE = 0x8862
+ QUERY_COUNTER_BITS = 0x8864
+ CURRENT_QUERY = 0x8865
+ QUERY_RESULT = 0x8866
+ QUERY_RESULT_AVAILABLE = 0x8867
+ MAX_VERTEX_ATTRIBS = 0x8869
+ VERTEX_ATTRIB_ARRAY_NORMALIZED = 0x886A
+ MAX_TEXTURE_COORDS = 0x8871
+ MAX_TEXTURE_IMAGE_UNITS = 0x8872
+ ARRAY_BUFFER = 0x8892
+ ELEMENT_ARRAY_BUFFER = 0x8893
+ ARRAY_BUFFER_BINDING = 0x8894
+ ELEMENT_ARRAY_BUFFER_BINDING = 0x8895
+ VERTEX_ARRAY_BUFFER_BINDING = 0x8896
+ NORMAL_ARRAY_BUFFER_BINDING = 0x8897
+ COLOR_ARRAY_BUFFER_BINDING = 0x8898
+ INDEX_ARRAY_BUFFER_BINDING = 0x8899
+ TEXTURE_COORD_ARRAY_BUFFER_BINDING = 0x889A
+ EDGE_FLAG_ARRAY_BUFFER_BINDING = 0x889B
+ SECONDARY_COLOR_ARRAY_BUFFER_BINDING = 0x889C
+ FOG_COORDINATE_ARRAY_BUFFER_BINDING = 0x889D
+ FOG_COORD_ARRAY_BUFFER_BINDING = 0x889D
+ WEIGHT_ARRAY_BUFFER_BINDING = 0x889E
+ VERTEX_ATTRIB_ARRAY_BUFFER_BINDING = 0x889F
+ READ_ONLY = 0x88B8
+ WRITE_ONLY = 0x88B9
+ READ_WRITE = 0x88BA
+ BUFFER_ACCESS = 0x88BB
+ BUFFER_MAPPED = 0x88BC
+ BUFFER_MAP_POINTER = 0x88BD
+ STREAM_DRAW = 0x88E0
+ STREAM_READ = 0x88E1
+ STREAM_COPY = 0x88E2
+ STATIC_DRAW = 0x88E4
+ STATIC_READ = 0x88E5
+ STATIC_COPY = 0x88E6
+ DYNAMIC_DRAW = 0x88E8
+ DYNAMIC_READ = 0x88E9
+ DYNAMIC_COPY = 0x88EA
+ PIXEL_PACK_BUFFER = 0x88EB
+ PIXEL_UNPACK_BUFFER = 0x88EC
+ PIXEL_PACK_BUFFER_BINDING = 0x88ED
+ PIXEL_UNPACK_BUFFER_BINDING = 0x88EF
+ SAMPLES_PASSED = 0x8914
+ FRAGMENT_SHADER = 0x8B30
+ VERTEX_SHADER = 0x8B31
+ MAX_FRAGMENT_UNIFORM_COMPONENTS = 0x8B49
+ MAX_VERTEX_UNIFORM_COMPONENTS = 0x8B4A
+ MAX_VARYING_FLOATS = 0x8B4B
+ MAX_VERTEX_TEXTURE_IMAGE_UNITS = 0x8B4C
+ MAX_COMBINED_TEXTURE_IMAGE_UNITS = 0x8B4D
+ SHADER_TYPE = 0x8B4F
+ FLOAT_VEC2 = 0x8B50
+ FLOAT_VEC3 = 0x8B51
+ FLOAT_VEC4 = 0x8B52
+ INT_VEC2 = 0x8B53
+ INT_VEC3 = 0x8B54
+ INT_VEC4 = 0x8B55
+ BOOL = 0x8B56
+ BOOL_VEC2 = 0x8B57
+ BOOL_VEC3 = 0x8B58
+ BOOL_VEC4 = 0x8B59
+ FLOAT_MAT2 = 0x8B5A
+ FLOAT_MAT3 = 0x8B5B
+ FLOAT_MAT4 = 0x8B5C
+ SAMPLER_1D = 0x8B5D
+ SAMPLER_2D = 0x8B5E
+ SAMPLER_3D = 0x8B5F
+ SAMPLER_CUBE = 0x8B60
+ SAMPLER_1D_SHADOW = 0x8B61
+ SAMPLER_2D_SHADOW = 0x8B62
+ FLOAT_MAT2x3 = 0x8B65
+ FLOAT_MAT2x4 = 0x8B66
+ FLOAT_MAT3x2 = 0x8B67
+ FLOAT_MAT3x4 = 0x8B68
+ FLOAT_MAT4x2 = 0x8B69
+ FLOAT_MAT4x3 = 0x8B6A
+ DELETE_STATUS = 0x8B80
+ COMPILE_STATUS = 0x8B81
+ LINK_STATUS = 0x8B82
+ VALIDATE_STATUS = 0x8B83
+ INFO_LOG_LENGTH = 0x8B84
+ ATTACHED_SHADERS = 0x8B85
+ ACTIVE_UNIFORMS = 0x8B86
+ ACTIVE_UNIFORM_MAX_LENGTH = 0x8B87
+ SHADER_SOURCE_LENGTH = 0x8B88
+ ACTIVE_ATTRIBUTES = 0x8B89
+ ACTIVE_ATTRIBUTE_MAX_LENGTH = 0x8B8A
+ SHADING_LANGUAGE_VERSION = 0x8B8C
+ CURRENT_PROGRAM = 0x8B8D
+ SRGB = 0x8C40
+ SRGB8 = 0x8C41
+ SRGB_ALPHA = 0x8C42
+ SRGB8_ALPHA8 = 0x8C43
+ SLUMINANCE_ALPHA = 0x8C44
+ SLUMINANCE8_ALPHA8 = 0x8C45
+ SLUMINANCE = 0x8C46
+ SLUMINANCE8 = 0x8C47
+ COMPRESSED_SRGB = 0x8C48
+ COMPRESSED_SRGB_ALPHA = 0x8C49
+ COMPRESSED_SLUMINANCE = 0x8C4A
+ COMPRESSED_SLUMINANCE_ALPHA = 0x8C4B
+ POINT_SPRITE_COORD_ORIGIN = 0x8CA0
+ LOWER_LEFT = 0x8CA1
+ UPPER_LEFT = 0x8CA2
+ STENCIL_BACK_REF = 0x8CA3
+ STENCIL_BACK_VALUE_MASK = 0x8CA4
+ STENCIL_BACK_WRITEMASK = 0x8CA5
+)
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glViewport.xml
+func (gl *GL) Viewport(x, y, width, height int) {
+ C.gl2_1_glViewport(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// DepthRange specifies the mapping of depth values from normalized device
+// coordinates to window coordinates.
+//
+// Parameter nearVal specifies the mapping of the near clipping plane to window
+// coordinates (defaults to 0), while farVal specifies the mapping of the far
+// clipping plane to window coordinates (defaults to 1).
+//
+// After clipping and division by w, depth coordinates range from -1 to 1,
+// corresponding to the near and far clipping planes. DepthRange specifies a
+// linear mapping of the normalized depth coordinates in this range to window
+// depth coordinates. Regardless of the actual depth buffer implementation,
+// window coordinate depth values are treated as though they range from 0 through 1
+// (like color components). Thus, the values accepted by DepthRange are both
+// clamped to this range before they are accepted.
+//
+// The default setting of (0, 1) maps the near plane to 0 and the far plane to 1.
+// With this mapping, the depth buffer range is fully utilized.
+//
+// It is not necessary that nearVal be less than farVal. Reverse mappings such as
+// nearVal 1, and farVal 0 are acceptable.
+//
+// GL.INVALID_OPERATION is generated if DepthRange is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) DepthRange(nearVal, farVal float64) {
+ C.gl2_1_glDepthRange(gl.funcs, C.GLdouble(nearVal), C.GLdouble(farVal))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIsEnabled.xml
+func (gl *GL) IsEnabled(cap glbase.Enum) bool {
+ glresult := C.gl2_1_glIsEnabled(gl.funcs, C.GLenum(cap))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexLevelParameteriv.xml
+func (gl *GL) GetTexLevelParameteriv(target glbase.Enum, level int, pname glbase.Enum, params []int32) {
+ C.gl2_1_glGetTexLevelParameteriv(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexLevelParameterfv.xml
+func (gl *GL) GetTexLevelParameterfv(target glbase.Enum, level int, pname glbase.Enum, params []float32) {
+ C.gl2_1_glGetTexLevelParameterfv(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexParameteriv.xml
+func (gl *GL) GetTexParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl2_1_glGetTexParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexParameterfv.xml
+func (gl *GL) GetTexParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl2_1_glGetTexParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexImage.xml
+func (gl *GL) GetTexImage(target glbase.Enum, level int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_1_glGetTexImage(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetIntegerv.xml
+func (gl *GL) GetIntegerv(pname glbase.Enum, params []int32) {
+ C.gl2_1_glGetIntegerv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetFloatv.xml
+func (gl *GL) GetFloatv(pname glbase.Enum, params []float32) {
+ C.gl2_1_glGetFloatv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetError.xml
+func (gl *GL) GetError() glbase.Enum {
+ glresult := C.gl2_1_glGetError(gl.funcs)
+ return glbase.Enum(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetDoublev.xml
+func (gl *GL) GetDoublev(pname glbase.Enum, params []float64) {
+ C.gl2_1_glGetDoublev(gl.funcs, C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetBooleanv.xml
+func (gl *GL) GetBooleanv(pname glbase.Enum, params []bool) {
+ C.gl2_1_glGetBooleanv(gl.funcs, C.GLenum(pname), (*C.GLboolean)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glReadPixels.xml
+func (gl *GL) ReadPixels(x, y, width, height int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_1_glReadPixels(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glReadBuffer.xml
+func (gl *GL) ReadBuffer(mode glbase.Enum) {
+ C.gl2_1_glReadBuffer(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelStorei.xml
+func (gl *GL) PixelStorei(pname glbase.Enum, param int32) {
+ C.gl2_1_glPixelStorei(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelStoref.xml
+func (gl *GL) PixelStoref(pname glbase.Enum, param float32) {
+ C.gl2_1_glPixelStoref(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDepthFunc.xml
+func (gl *GL) DepthFunc(glfunc glbase.Enum) {
+ C.gl2_1_glDepthFunc(gl.funcs, C.GLenum(glfunc))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glStencilOp.xml
+func (gl *GL) StencilOp(fail, zfail, zpass glbase.Enum) {
+ C.gl2_1_glStencilOp(gl.funcs, C.GLenum(fail), C.GLenum(zfail), C.GLenum(zpass))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glStencilFunc.xml
+func (gl *GL) StencilFunc(glfunc glbase.Enum, ref int32, mask uint32) {
+ C.gl2_1_glStencilFunc(gl.funcs, C.GLenum(glfunc), C.GLint(ref), C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLogicOp.xml
+func (gl *GL) LogicOp(opcode glbase.Enum) {
+ C.gl2_1_glLogicOp(gl.funcs, C.GLenum(opcode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBlendFunc.xml
+func (gl *GL) BlendFunc(sfactor, dfactor glbase.Enum) {
+ C.gl2_1_glBlendFunc(gl.funcs, C.GLenum(sfactor), C.GLenum(dfactor))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFlush.xml
+func (gl *GL) Flush() {
+ C.gl2_1_glFlush(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFinish.xml
+func (gl *GL) Finish() {
+ C.gl2_1_glFinish(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEnable.xml
+func (gl *GL) Enable(cap glbase.Enum) {
+ C.gl2_1_glEnable(gl.funcs, C.GLenum(cap))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDisable.xml
+func (gl *GL) Disable(cap glbase.Enum) {
+ C.gl2_1_glDisable(gl.funcs, C.GLenum(cap))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDepthMask.xml
+func (gl *GL) DepthMask(flag bool) {
+ C.gl2_1_glDepthMask(gl.funcs, *(*C.GLboolean)(unsafe.Pointer(&flag)))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColorMask.xml
+func (gl *GL) ColorMask(red, green, blue, alpha bool) {
+ C.gl2_1_glColorMask(gl.funcs, *(*C.GLboolean)(unsafe.Pointer(&red)), *(*C.GLboolean)(unsafe.Pointer(&green)), *(*C.GLboolean)(unsafe.Pointer(&blue)), *(*C.GLboolean)(unsafe.Pointer(&alpha)))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glStencilMask.xml
+func (gl *GL) StencilMask(mask uint32) {
+ C.gl2_1_glStencilMask(gl.funcs, C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClearDepth.xml
+func (gl *GL) ClearDepth(depth float64) {
+ C.gl2_1_glClearDepth(gl.funcs, C.GLdouble(depth))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClearStencil.xml
+func (gl *GL) ClearStencil(s int32) {
+ C.gl2_1_glClearStencil(gl.funcs, C.GLint(s))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClearColor.xml
+func (gl *GL) ClearColor(red, green, blue, alpha float32) {
+ C.gl2_1_glClearColor(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClear.xml
+func (gl *GL) Clear(mask glbase.Bitfield) {
+ C.gl2_1_glClear(gl.funcs, C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDrawBuffer.xml
+func (gl *GL) DrawBuffer(mode glbase.Enum) {
+ C.gl2_1_glDrawBuffer(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexImage2D.xml
+func (gl *GL) TexImage2D(target glbase.Enum, level int, internalFormat int32, width, height, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_1_glTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexImage1D.xml
+func (gl *GL) TexImage1D(target glbase.Enum, level int, internalFormat int32, width, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_1_glTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexParameteriv.xml
+func (gl *GL) TexParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl2_1_glTexParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexParameteri.xml
+func (gl *GL) TexParameteri(target, pname glbase.Enum, param int32) {
+ C.gl2_1_glTexParameteri(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexParameterfv.xml
+func (gl *GL) TexParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl2_1_glTexParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexParameterf.xml
+func (gl *GL) TexParameterf(target, pname glbase.Enum, param float32) {
+ C.gl2_1_glTexParameterf(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glScissor.xml
+func (gl *GL) Scissor(x, y, width, height int) {
+ C.gl2_1_glScissor(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPolygonMode.xml
+func (gl *GL) PolygonMode(face, mode glbase.Enum) {
+ C.gl2_1_glPolygonMode(gl.funcs, C.GLenum(face), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPointSize.xml
+func (gl *GL) PointSize(size float32) {
+ C.gl2_1_glPointSize(gl.funcs, C.GLfloat(size))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLineWidth.xml
+func (gl *GL) LineWidth(width float32) {
+ C.gl2_1_glLineWidth(gl.funcs, C.GLfloat(width))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glHint.xml
+func (gl *GL) Hint(target, mode glbase.Enum) {
+ C.gl2_1_glHint(gl.funcs, C.GLenum(target), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFrontFace.xml
+func (gl *GL) FrontFace(mode glbase.Enum) {
+ C.gl2_1_glFrontFace(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCullFace.xml
+func (gl *GL) CullFace(mode glbase.Enum) {
+ C.gl2_1_glCullFace(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexubv.xml
+func (gl *GL) Indexubv(c []uint8) {
+ C.gl2_1_glIndexubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexub.xml
+func (gl *GL) Indexub(c uint8) {
+ C.gl2_1_glIndexub(gl.funcs, C.GLubyte(c))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIsTexture.xml
+func (gl *GL) IsTexture(texture glbase.Texture) bool {
+ glresult := C.gl2_1_glIsTexture(gl.funcs, C.GLuint(texture))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// GenTextures returns n texture names in textures. There is no guarantee
+// that the names form a contiguous set of integers; however, it is
+// guaranteed that none of the returned names was in use immediately before
+// the call to GenTextures.
+//
+// The generated textures have no dimensionality; they assume the
+// dimensionality of the texture target to which they are first bound (see
+// BindTexture).
+//
+// Texture names returned by a call to GenTextures are not returned by
+// subsequent calls, unless they are first deleted with DeleteTextures.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// GenTextures is available in GL version 2.0 or greater.
+func (gl *GL) GenTextures(n int) []glbase.Texture {
+ if n == 0 {
+ return nil
+ }
+ textures := make([]glbase.Texture, n)
+ C.gl2_1_glGenTextures(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])))
+ return textures
+}
+
+// DeleteTextures deletes the textures objects whose names are stored
+// in the textures slice. After a texture is deleted, it has no contents or
+// dimensionality, and its name is free for reuse (for example by
+// GenTextures). If a texture that is currently bound is deleted, the binding
+// reverts to 0 (the default texture).
+//
+// DeleteTextures silently ignores 0's and names that do not correspond to
+// existing textures.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// DeleteTextures is available in GL version 2.0 or greater.
+func (gl *GL) DeleteTextures(textures []glbase.Texture) {
+ n := len(textures)
+ if n == 0 {
+ return
+ }
+ C.gl2_1_glDeleteTextures(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBindTexture.xml
+func (gl *GL) BindTexture(target glbase.Enum, texture glbase.Texture) {
+ C.gl2_1_glBindTexture(gl.funcs, C.GLenum(target), C.GLuint(texture))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexSubImage2D.xml
+func (gl *GL) TexSubImage2D(target glbase.Enum, level, xoffset, yoffset, width, height int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_1_glTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexSubImage1D.xml
+func (gl *GL) TexSubImage1D(target glbase.Enum, level, xoffset, width int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_1_glTexSubImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLsizei(width), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyTexSubImage2D.xml
+func (gl *GL) CopyTexSubImage2D(target glbase.Enum, level, xoffset, yoffset, x, y, width, height int) {
+ C.gl2_1_glCopyTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyTexSubImage1D.xml
+func (gl *GL) CopyTexSubImage1D(target glbase.Enum, level, xoffset, x, y, width int) {
+ C.gl2_1_glCopyTexSubImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(x), C.GLint(y), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyTexImage2D.xml
+func (gl *GL) CopyTexImage2D(target glbase.Enum, level int, internalFormat glbase.Enum, x, y, width, height, border int) {
+ C.gl2_1_glCopyTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height), C.GLint(border))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyTexImage1D.xml
+func (gl *GL) CopyTexImage1D(target glbase.Enum, level int, internalFormat glbase.Enum, x, y, width, border int) {
+ C.gl2_1_glCopyTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLint(border))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPolygonOffset.xml
+func (gl *GL) PolygonOffset(factor, units float32) {
+ C.gl2_1_glPolygonOffset(gl.funcs, C.GLfloat(factor), C.GLfloat(units))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDrawElements.xml
+func (gl *GL) DrawElements(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_1_glDrawElements(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDrawArrays.xml
+func (gl *GL) DrawArrays(mode glbase.Enum, first, count int) {
+ C.gl2_1_glDrawArrays(gl.funcs, C.GLenum(mode), C.GLint(first), C.GLsizei(count))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyTexSubImage3D.xml
+func (gl *GL) CopyTexSubImage3D(target glbase.Enum, level, xoffset, yoffset int, zoffset int32, x, y, width, height int) {
+ C.gl2_1_glCopyTexSubImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(zoffset), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexSubImage3D.xml
+func (gl *GL) TexSubImage3D(target glbase.Enum, level, xoffset, yoffset int, zoffset int32, width, height int, depth int32, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_1_glTexSubImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(zoffset), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexImage3D.xml
+func (gl *GL) TexImage3D(target glbase.Enum, level int, internalFormat int32, width, height int, depth int32, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_1_glTexImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDrawRangeElements.xml
+func (gl *GL) DrawRangeElements(mode glbase.Enum, start, end uint32, count int, gltype glbase.Enum, indices interface{}) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_1_glDrawRangeElements(gl.funcs, C.GLenum(mode), C.GLuint(start), C.GLuint(end), C.GLsizei(count), C.GLenum(gltype), indices_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBlendEquation.xml
+func (gl *GL) BlendEquation(mode glbase.Enum) {
+ C.gl2_1_glBlendEquation(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBlendColor.xml
+func (gl *GL) BlendColor(red, green, blue, alpha float32) {
+ C.gl2_1_glBlendColor(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetCompressedTexImage.xml
+func (gl *GL) GetCompressedTexImage(target glbase.Enum, level int, img interface{}) {
+ var img_ptr unsafe.Pointer
+ var img_v = reflect.ValueOf(img)
+ if img != nil && img_v.Kind() != reflect.Slice {
+ panic("parameter img must be a slice")
+ }
+ if img != nil {
+ img_ptr = unsafe.Pointer(img_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_1_glGetCompressedTexImage(gl.funcs, C.GLenum(target), C.GLint(level), img_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCompressedTexSubImage1D.xml
+func (gl *GL) CompressedTexSubImage1D(target glbase.Enum, level, xoffset, width int, format glbase.Enum, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_1_glCompressedTexSubImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLsizei(width), C.GLenum(format), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCompressedTexSubImage2D.xml
+func (gl *GL) CompressedTexSubImage2D(target glbase.Enum, level, xoffset, yoffset, width, height int, format glbase.Enum, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_1_glCompressedTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCompressedTexSubImage3D.xml
+func (gl *GL) CompressedTexSubImage3D(target glbase.Enum, level, xoffset, yoffset int, zoffset int32, width, height int, depth int32, format glbase.Enum, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_1_glCompressedTexSubImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(zoffset), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLenum(format), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCompressedTexImage1D.xml
+func (gl *GL) CompressedTexImage1D(target glbase.Enum, level int, internalFormat glbase.Enum, width, border, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_1_glCompressedTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLsizei(width), C.GLint(border), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCompressedTexImage2D.xml
+func (gl *GL) CompressedTexImage2D(target glbase.Enum, level int, internalFormat glbase.Enum, width, height, border, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_1_glCompressedTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLint(border), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCompressedTexImage3D.xml
+func (gl *GL) CompressedTexImage3D(target glbase.Enum, level int, internalFormat glbase.Enum, width, height int, depth int32, border, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_1_glCompressedTexImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLint(border), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSampleCoverage.xml
+func (gl *GL) SampleCoverage(value float32, invert bool) {
+ C.gl2_1_glSampleCoverage(gl.funcs, C.GLfloat(value), *(*C.GLboolean)(unsafe.Pointer(&invert)))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glActiveTexture.xml
+func (gl *GL) ActiveTexture(texture glbase.Enum) {
+ C.gl2_1_glActiveTexture(gl.funcs, C.GLenum(texture))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPointParameteriv.xml
+func (gl *GL) PointParameteriv(pname glbase.Enum, params []int32) {
+ C.gl2_1_glPointParameteriv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPointParameteri.xml
+func (gl *GL) PointParameteri(pname glbase.Enum, param int32) {
+ C.gl2_1_glPointParameteri(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPointParameterfv.xml
+func (gl *GL) PointParameterfv(pname glbase.Enum, params []float32) {
+ C.gl2_1_glPointParameterfv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPointParameterf.xml
+func (gl *GL) PointParameterf(pname glbase.Enum, param float32) {
+ C.gl2_1_glPointParameterf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiDrawArrays.xml
+func (gl *GL) MultiDrawArrays(mode glbase.Enum, first, count []int, drawcount int32) {
+ C.gl2_1_glMultiDrawArrays(gl.funcs, C.GLenum(mode), (*C.GLint)(unsafe.Pointer(&first[0])), (*C.GLsizei)(unsafe.Pointer(&count[0])), C.GLsizei(drawcount))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBlendFuncSeparate.xml
+func (gl *GL) BlendFuncSeparate(sfactorRGB, dfactorRGB, sfactorAlpha, dfactorAlpha glbase.Enum) {
+ C.gl2_1_glBlendFuncSeparate(gl.funcs, C.GLenum(sfactorRGB), C.GLenum(dfactorRGB), C.GLenum(sfactorAlpha), C.GLenum(dfactorAlpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetBufferParameteriv.xml
+func (gl *GL) GetBufferParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl2_1_glGetBufferParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glUnmapBuffer.xml
+func (gl *GL) UnmapBuffer(target glbase.Enum) bool {
+ glresult := C.gl2_1_glUnmapBuffer(gl.funcs, C.GLenum(target))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetBufferSubData.xml
+func (gl *GL) GetBufferSubData(target glbase.Enum, offset, size int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_1_glGetBufferSubData(gl.funcs, C.GLenum(target), C.GLintptr(offset), C.GLsizeiptr(size), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBufferSubData.xml
+func (gl *GL) BufferSubData(target glbase.Enum, offset, size int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_1_glBufferSubData(gl.funcs, C.GLenum(target), C.GLintptr(offset), C.GLsizeiptr(size), data_ptr)
+}
+
+// BufferData creates a new data store for the buffer object currently
+// bound to target. Any pre-existing data store is deleted. The new data
+// store is created with the specified size in bytes and usage. If data is
+// not nil, it must be a slice that is used to initialize the data store.
+// In that case the size parameter is ignored and the store size will match
+// the slice data size.
+//
+// In its initial state, the new data store is not mapped, it has a NULL
+// mapped pointer, and its mapped access is GL.READ_WRITE.
+//
+// The target constant must be one of GL.ARRAY_BUFFER, GL.COPY_READ_BUFFER,
+// GL.COPY_WRITE_BUFFER, GL.ELEMENT_ARRAY_BUFFER, GL.PIXEL_PACK_BUFFER,
+// GL.PIXEL_UNPACK_BUFFER, GL.TEXTURE_BUFFER, GL.TRANSFORM_FEEDBACK_BUFFER,
+// or GL.UNIFORM_BUFFER.
+//
+// The usage parameter is a hint to the GL implementation as to how a buffer
+// object's data store will be accessed. This enables the GL implementation
+// to make more intelligent decisions that may significantly impact buffer
+// object performance. It does not, however, constrain the actual usage of
+// the data store. usage can be broken down into two parts: first, the
+// frequency of access (modification and usage), and second, the nature of
+// that access.
+//
+// A usage frequency of STREAM and nature of DRAW is specified via the
+// constant GL.STREAM_DRAW, for example.
+//
+// The usage frequency of access may be one of:
+//
+// STREAM
+// The data store contents will be modified once and used at most a few times.
+//
+// STATIC
+// The data store contents will be modified once and used many times.
+//
+// DYNAMIC
+// The data store contents will be modified repeatedly and used many times.
+//
+// The usage nature of access may be one of:
+//
+// DRAW
+// The data store contents are modified by the application, and used as
+// the source for GL drawing and image specification commands.
+//
+// READ
+// The data store contents are modified by reading data from the GL,
+// and used to return that data when queried by the application.
+//
+// COPY
+// The data store contents are modified by reading data from the GL,
+// and used as the source for GL drawing and image specification
+// commands.
+//
+// Clients must align data elements consistent with the requirements of the
+// client platform, with an additional base-level requirement that an offset
+// within a buffer to a datum comprising N bytes be a multiple of N.
+//
+// Error GL.INVALID_ENUM is generated if target is not one of the accepted
+// buffer targets. GL.INVALID_ENUM is generated if usage is not
+// GL.STREAM_DRAW, GL.STREAM_READ, GL.STREAM_COPY, GL.STATIC_DRAW,
+// GL.STATIC_READ, GL.STATIC_COPY, GL.DYNAMIC_DRAW, GL.DYNAMIC_READ, or
+// GL.DYNAMIC_COPY. GL.INVALID_VALUE is generated if size is negative.
+// GL.INVALID_OPERATION is generated if the reserved buffer object name 0 is
+// bound to target. GL.OUT_OF_MEMORY is generated if the GL is unable to
+// create a data store with the specified size.
+func (gl *GL) BufferData(target glbase.Enum, size int, data interface{}, usage glbase.Enum) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ if data != nil {
+ size = int(data_v.Type().Size()) * data_v.Len()
+ }
+ C.gl2_1_glBufferData(gl.funcs, C.GLenum(target), C.GLsizeiptr(size), data_ptr, C.GLenum(usage))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIsBuffer.xml
+func (gl *GL) IsBuffer(buffer glbase.Buffer) bool {
+ glresult := C.gl2_1_glIsBuffer(gl.funcs, C.GLuint(buffer))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// GenBuffers returns n buffer object names. There is no guarantee that
+// the names form a contiguous set of integers; however, it is guaranteed
+// that none of the returned names was in use immediately before the call to
+// GenBuffers.
+//
+// Buffer object names returned by a call to GenBuffers are not returned by
+// subsequent calls, unless they are first deleted with DeleteBuffers.
+//
+// No buffer objects are associated with the returned buffer object names
+// until they are first bound by calling BindBuffer.
+//
+// Error GL.INVALID_VALUE is generated if n is negative. GL.INVALID_OPERATION
+// is generated if GenBuffers is executed between the execution of Begin
+// and the corresponding execution of End.
+//
+// GenBuffers is available in GL version 1.5 or greater.
+func (gl *GL) GenBuffers(n int) []glbase.Buffer {
+ if n == 0 {
+ return nil
+ }
+ buffers := make([]glbase.Buffer, n)
+ C.gl2_1_glGenBuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&buffers[0])))
+ return buffers
+}
+
+// DeleteBuffers deletes the buffer objects whose names are stored in the
+// buffers slice.
+//
+// After a buffer object is deleted, it has no contents, and its name is free
+// for reuse (for example by GenBuffers). If a buffer object that is
+// currently bound is deleted, the binding reverts to 0 (the absence of any
+// buffer object, which reverts to client memory usage).
+//
+// DeleteBuffers silently ignores 0's and names that do not correspond to
+// existing buffer objects.
+//
+// Error GL.INVALID_VALUE is generated if n is negative. GL.INVALID_OPERATION
+// is generated if DeleteBuffers is executed between the execution of Begin
+// and the corresponding execution of End.
+//
+// DeleteBuffers is available in GL version 1.5 or greater.
+func (gl *GL) DeleteBuffers(buffers []glbase.Buffer) {
+ n := len(buffers)
+ if n == 0 {
+ return
+ }
+ C.gl2_1_glDeleteBuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&buffers[0])))
+}
+
+// BindBuffer creates or puts in use a named buffer object.
+// Calling BindBuffer with target set to GL.ARRAY_BUFFER,
+// GL.ELEMENT_ARRAY_BUFFER, GL.PIXEL_PACK_BUFFER or GL.PIXEL_UNPACK_BUFFER
+// and buffer set to the name of the new buffer object binds the buffer
+// object name to the target. When a buffer object is bound to a target, the
+// previous binding for that target is automatically broken.
+//
+// Buffer object names are unsigned integers. The value zero is reserved, but
+// there is no default buffer object for each buffer object target. Instead,
+// buffer set to zero effectively unbinds any buffer object previously bound,
+// and restores client memory usage for that buffer object target. Buffer
+// object names and the corresponding buffer object contents are local to the
+// shared display-list space (see XCreateContext) of the current GL rendering
+// context; two rendering contexts share buffer object names only if they
+// also share display lists.
+//
+// GenBuffers may be called to generate a set of new buffer object names.
+//
+// The state of a buffer object immediately after it is first bound is an
+// unmapped zero-sized memory buffer with GL.READ_WRITE access and
+// GL.STATIC_DRAW usage.
+//
+// While a non-zero buffer object name is bound, GL operations on the target
+// to which it is bound affect the bound buffer object, and queries of the
+// target to which it is bound return state from the bound buffer object.
+// While buffer object name zero is bound, as in the initial state, attempts
+// to modify or query state on the target to which it is bound generates an
+// GL.INVALID_OPERATION error.
+//
+// When vertex array pointer state is changed, for example by a call to
+// NormalPointer, the current buffer object binding (GL.ARRAY_BUFFER_BINDING)
+// is copied into the corresponding client state for the vertex array type
+// being changed, for example GL.NORMAL_ARRAY_BUFFER_BINDING. While a
+// non-zero buffer object is bound to the GL.ARRAY_BUFFER target, the vertex
+// array pointer parameter that is traditionally interpreted as a pointer to
+// client-side memory is instead interpreted as an offset within the buffer
+// object measured in basic machine units.
+//
+// While a non-zero buffer object is bound to the GL.ELEMENT_ARRAY_BUFFER
+// target, the indices parameter of DrawElements, DrawRangeElements, or
+// MultiDrawElements that is traditionally interpreted as a pointer to
+// client-side memory is instead interpreted as an offset within the buffer
+// object measured in basic machine units.
+//
+// While a non-zero buffer object is bound to the GL.PIXEL_PACK_BUFFER
+// target, the following commands are affected: GetCompressedTexImage,
+// GetConvolutionFilter, GetHistogram, GetMinmax, GetPixelMap,
+// GetPolygonStipple, GetSeparableFilter, GetTexImage, and ReadPixels. The
+// pointer parameter that is traditionally interpreted as a pointer to
+// client-side memory where the pixels are to be packed is instead
+// interpreted as an offset within the buffer object measured in basic
+// machine units.
+//
+// While a non-zero buffer object is bound to the GL.PIXEL_UNPACK_BUFFER
+// target, the following commands are affected: Bitmap, ColorSubTable,
+// ColorTable, CompressedTexImage1D, CompressedTexImage2D,
+// CompressedTexImage3D, CompressedTexSubImage1D, CompressedTexSubImage2D,
+// CompressedTexSubImage3D, ConvolutionFilter1D, ConvolutionFilter2D,
+// DrawPixels, PixelMap, PolygonStipple, SeparableFilter2D, TexImage1D,
+// TexImage2D, TexImage3D, TexSubImage1D, TexSubImage2D, and TexSubImage3D.
+// The pointer parameter that is traditionally interpreted as a pointer to
+// client-side memory from which the pixels are to be unpacked is instead
+// interpreted as an offset within the buffer object measured in basic
+// machine units.
+//
+// A buffer object binding created with BindBuffer remains active until a
+// different buffer object name is bound to the same target, or until the
+// bound buffer object is deleted with DeleteBuffers.
+//
+// Once created, a named buffer object may be re-bound to any target as often
+// as needed. However, the GL implementation may make choices about how to
+// optimize the storage of a buffer object based on its initial binding
+// target.
+//
+// Error GL.INVALID_ENUM is generated if target is not one of the allowable
+// values. GL.INVALID_OPERATION is generated if BindBuffer is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// BindBuffer is available in GL version 1.5 or greater.
+func (gl *GL) BindBuffer(target glbase.Enum, buffer glbase.Buffer) {
+ C.gl2_1_glBindBuffer(gl.funcs, C.GLenum(target), C.GLuint(buffer))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetQueryObjectuiv.xml
+func (gl *GL) GetQueryObjectuiv(id uint32, pname glbase.Enum, params []uint32) {
+ C.gl2_1_glGetQueryObjectuiv(gl.funcs, C.GLuint(id), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetQueryObjectiv.xml
+func (gl *GL) GetQueryObjectiv(id uint32, pname glbase.Enum, params []int32) {
+ C.gl2_1_glGetQueryObjectiv(gl.funcs, C.GLuint(id), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetQueryiv.xml
+func (gl *GL) GetQueryiv(target, pname glbase.Enum, params []int32) {
+ C.gl2_1_glGetQueryiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEndQuery.xml
+func (gl *GL) EndQuery(target glbase.Enum) {
+ C.gl2_1_glEndQuery(gl.funcs, C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBeginQuery.xml
+func (gl *GL) BeginQuery(target glbase.Enum, id uint32) {
+ C.gl2_1_glBeginQuery(gl.funcs, C.GLenum(target), C.GLuint(id))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIsQuery.xml
+func (gl *GL) IsQuery(id uint32) bool {
+ glresult := C.gl2_1_glIsQuery(gl.funcs, C.GLuint(id))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDeleteQueries.xml
+func (gl *GL) DeleteQueries(n int, ids []uint32) {
+ C.gl2_1_glDeleteQueries(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&ids[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGenQueries.xml
+func (gl *GL) GenQueries(n int, ids []uint32) {
+ C.gl2_1_glGenQueries(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&ids[0])))
+}
+
+// VertexAttribPointer specifies the location and data format of the array
+// of generic vertex attributes at index to use when rendering. size
+// specifies the number of components per attribute and must be 1, 2, 3, or
+// 4. type specifies the data type of each component, and stride specifies
+// the byte stride from one attribute to the next, allowing vertices and
+// attributes to be packed into a single array or stored in separate arrays.
+// normalized indicates whether the values stored in an integer format are
+// to be mapped to the range [-1,1] (for signed values) or [0,1]
+// (for unsigned values) when they are accessed and converted to floating
+// point; otherwise, values will be converted to floats directly without
+// normalization. offset is a byte offset into the buffer object's data
+// store, which must be bound to the GL.ARRAY_BUFFER target with BindBuffer.
+//
+// The buffer object binding (GL.ARRAY_BUFFER_BINDING) is saved as
+// generic vertex attribute array client-side state
+// (GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING) for the provided index.
+//
+// To enable and disable a generic vertex attribute array, call
+// EnableVertexAttribArray and DisableVertexAttribArray with index. If
+// enabled, the generic vertex attribute array is used when DrawArrays or
+// DrawElements is called. Each generic vertex attribute array is initially
+// disabled.
+//
+// VertexAttribPointer is typically implemented on the client side.
+//
+// Error GL.INVALID_ENUM is generated if type is not an accepted value.
+// GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_VALUE is generated if size is not 1, 2,
+// 3, or 4. GL.INVALID_VALUE is generated if stride is negative.
+func (gl *GL) VertexAttribPointer(index glbase.Attrib, size int, gltype glbase.Enum, normalized bool, stride int, offset uintptr) {
+ offset_ptr := unsafe.Pointer(offset)
+ C.gl2_1_glVertexAttribPointer(gl.funcs, C.GLuint(index), C.GLint(size), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), C.GLsizei(stride), offset_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glValidateProgram.xml
+func (gl *GL) ValidateProgram(program glbase.Program) {
+ C.gl2_1_glValidateProgram(gl.funcs, C.GLuint(program))
+}
+
+// UniformMatrix4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix4fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(4*4) != 0 {
+ panic("invalid value length for UniformMatrix4fv")
+ }
+ count := len(value) / (4 * 4)
+ C.gl2_1_glUniformMatrix4fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix3fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(3*3) != 0 {
+ panic("invalid value length for UniformMatrix3fv")
+ }
+ count := len(value) / (3 * 3)
+ C.gl2_1_glUniformMatrix3fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix2fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(2*2) != 0 {
+ panic("invalid value length for UniformMatrix2fv")
+ }
+ count := len(value) / (2 * 2)
+ C.gl2_1_glUniformMatrix2fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform4iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%4 != 0 {
+ panic("invalid value length for Uniform4iv")
+ }
+ count := len(value) / 4
+ C.gl2_1_glUniform4iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform3iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform3iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%3 != 0 {
+ panic("invalid value length for Uniform3iv")
+ }
+ count := len(value) / 3
+ C.gl2_1_glUniform3iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform2iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform2iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%2 != 0 {
+ panic("invalid value length for Uniform2iv")
+ }
+ count := len(value) / 2
+ C.gl2_1_glUniform2iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform1iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform1iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ count := len(value)
+ C.gl2_1_glUniform1iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%4 != 0 {
+ panic("invalid value length for Uniform4fv")
+ }
+ count := len(value) / 4
+ C.gl2_1_glUniform4fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%3 != 0 {
+ panic("invalid value length for Uniform3fv")
+ }
+ count := len(value) / 3
+ C.gl2_1_glUniform3fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%2 != 0 {
+ panic("invalid value length for Uniform2fv")
+ }
+ count := len(value) / 2
+ C.gl2_1_glUniform2fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform1fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform1fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ count := len(value)
+ C.gl2_1_glUniform1fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform4i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4i(location glbase.Uniform, v0, v1, v2, v3 int32) {
+ C.gl2_1_glUniform4i(gl.funcs, C.GLint(location), C.GLint(v0), C.GLint(v1), C.GLint(v2), C.GLint(v3))
+}
+
+// Uniform3i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform3i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3i(location glbase.Uniform, v0, v1, v2 int32) {
+ C.gl2_1_glUniform3i(gl.funcs, C.GLint(location), C.GLint(v0), C.GLint(v1), C.GLint(v2))
+}
+
+// Uniform2i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform2i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2i(location glbase.Uniform, v0, v1 int32) {
+ C.gl2_1_glUniform2i(gl.funcs, C.GLint(location), C.GLint(v0), C.GLint(v1))
+}
+
+// Uniform1i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform1i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1i(location glbase.Uniform, v0 int32) {
+ C.gl2_1_glUniform1i(gl.funcs, C.GLint(location), C.GLint(v0))
+}
+
+// Uniform4f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform4f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4f(location glbase.Uniform, v0, v1, v2, v3 float32) {
+ C.gl2_1_glUniform4f(gl.funcs, C.GLint(location), C.GLfloat(v0), C.GLfloat(v1), C.GLfloat(v2), C.GLfloat(v3))
+}
+
+// Uniform3f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform3f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3f(location glbase.Uniform, v0, v1, v2 float32) {
+ C.gl2_1_glUniform3f(gl.funcs, C.GLint(location), C.GLfloat(v0), C.GLfloat(v1), C.GLfloat(v2))
+}
+
+// Uniform2f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform2f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2f(location glbase.Uniform, v0, v1 float32) {
+ C.gl2_1_glUniform2f(gl.funcs, C.GLint(location), C.GLfloat(v0), C.GLfloat(v1))
+}
+
+// Uniform1f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform1f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1f(location glbase.Uniform, v0 float32) {
+ C.gl2_1_glUniform1f(gl.funcs, C.GLint(location), C.GLfloat(v0))
+}
+
+// UseProgram installs the program object specified by program as part of
+// current rendering state. One or more executables are created in a program
+// object by successfully attaching shader objects to it with AttachShader,
+// successfully compiling the shader objects with CompileShader, and
+// successfully linking the program object with LinkProgram.
+//
+// A program object will contain an executable that will run on the vertex
+// processor if it contains one or more shader objects of type
+// GL.VERTEX_SHADER that have been successfully compiled and linked.
+// Similarly, a program object will contain an executable that will run on
+// the fragment processor if it contains one or more shader objects of type
+// GL.FRAGMENT_SHADER that have been successfully compiled and linked.
+//
+// Successfully installing an executable on a programmable processor will
+// cause the corresponding fixed functionality of OpenGL to be disabled.
+// Specifically, if an executable is installed on the vertex processor, the
+// OpenGL fixed functionality will be disabled as follows.
+//
+// - The modelview matrix is not applied to vertex coordinates.
+//
+// - The projection matrix is not applied to vertex coordinates.
+//
+// - The texture matrices are not applied to texture coordinates.
+//
+// - Normals are not transformed to eye coordinates.
+//
+// - Normals are not rescaled or normalized.
+//
+// - Normalization of GL.AUTO_NORMAL evaluated normals is not performed.
+//
+// - Texture coordinates are not generated automatically.
+//
+// - Per-vertex lighting is not performed.
+//
+// - Color material computations are not performed.
+//
+// - Color index lighting is not performed.
+//
+// - This list also applies when setting the current raster position.
+//
+// The executable that is installed on the vertex processor is expected to
+// implement any or all of the desired functionality from the preceding list.
+// Similarly, if an executable is installed on the fragment processor, the
+// OpenGL fixed functionality will be disabled as follows.
+//
+// - Texture environment and texture functions are not applied.
+//
+// - Texture application is not applied.
+//
+// - Color sum is not applied.
+//
+// - Fog is not applied.
+//
+// Again, the fragment shader that is installed is expected to implement any
+// or all of the desired functionality from the preceding list.
+//
+// While a program object is in use, applications are free to modify attached
+// shader objects, compile attached shader objects, attach additional shader
+// objects, and detach or delete shader objects. None of these operations
+// will affect the executables that are part of the current state. However,
+// relinking the program object that is currently in use will install the
+// program object as part of the current rendering state if the link
+// operation was successful (see LinkProgram). If the program object
+// currently in use is relinked unsuccessfully, its link status will be set
+// to GL.FALSE, but the executables and associated state will remain part of
+// the current state until a subsequent call to UseProgram removes it from
+// use. After it is removed from use, it cannot be made part of current state
+// until it has been successfully relinked.
+//
+// If program contains shader objects of type GL.VERTEX_SHADER but it does
+// not contain shader objects of type GL.FRAGMENT_SHADER, an executable will
+// be installed on the vertex processor, but fixed functionality will be used
+// for fragment processing. Similarly, if program contains shader objects of
+// type GL.FRAGMENT_SHADER but it does not contain shader objects of type
+// GL.VERTEX_SHADER, an executable will be installed on the fragment
+// processor, but fixed functionality will be used for vertex processing. If
+// program is 0, the programmable processors will be disabled, and fixed
+// functionality will be used for both vertex and fragment processing.
+//
+// While a program object is in use, the state that controls the disabled
+// fixed functionality may also be updated using the normal OpenGL calls.
+//
+// Like display lists and texture objects, the name space for program objects
+// may be shared across a set of contexts, as long as the server sides of the
+// contexts share the same address space. If the name space is shared across
+// contexts, any attached objects and the data associated with those attached
+// objects are shared as well.
+//
+// Applications are responsible for providing the synchronization across API
+// calls when objects are accessed from different execution threads.
+//
+// Error GL.INVALID_VALUE is generated if program is neither 0 nor a value
+// generated by OpenGL. GL.INVALID_OPERATION is generated if program is not
+// a program object. GL.INVALID_OPERATION is generated if program could not
+// be made part of current state. GL.INVALID_OPERATION is generated if
+// UseProgram is executed between the execution of Begin and the
+// corresponding execution of End.
+//
+// UseProgram is available in GL version 2.0 or greater.
+func (gl *GL) UseProgram(program glbase.Program) {
+ C.gl2_1_glUseProgram(gl.funcs, C.GLuint(program))
+}
+
+// ShaderSource sets the source code in shader to the provided source code. Any source
+// code previously stored in the shader object is completely replaced.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader is not a shader
+// object. GL.INVALID_VALUE is generated if count is less than 0.
+// GL.INVALID_OPERATION is generated if ShaderSource is executed between the
+// execution of Begin and the corresponding execution of End.
+//
+// ShaderSource is available in GL version 2.0 or greater.
+func (gl *GL) ShaderSource(shader glbase.Shader, source ...string) {
+ count := len(source)
+ length := make([]int32, count)
+ source_c := make([]unsafe.Pointer, count)
+ for i, src := range source {
+ length[i] = int32(len(src))
+ if len(src) > 0 {
+ source_c[i] = *(*unsafe.Pointer)(unsafe.Pointer(&src))
+ } else {
+ source_c[i] = unsafe.Pointer(uintptr(0))
+ }
+ }
+ C.gl2_1_glShaderSource(gl.funcs, C.GLuint(shader), C.GLsizei(count), (**C.GLchar)(unsafe.Pointer(&source_c[0])), (*C.GLint)(unsafe.Pointer(&length[0])))
+}
+
+// LinkProgram links the program object specified by program. If any shader
+// objects of type GL.VERTEX_SHADER are attached to program, they will be
+// used to create an executable that will run on the programmable vertex
+// processor. If any shader objects of type GL.FRAGMENT_SHADER are attached
+// to program, they will be used to create an executable that will run on the
+// programmable fragment processor.
+//
+// The status of the link operation will be stored as part of the program
+// object's state. This value will be set to GL.TRUE if the program object
+// was linked without errors and is ready for use, and GL.FALSE otherwise. It
+// can be queried by calling GetProgramiv with arguments program and
+// GL.LINK_STATUS.
+//
+// As a result of a successful link operation, all active user-defined
+// uniform variables belonging to program will be initialized to 0, and each
+// of the program object's active uniform variables will be assigned a
+// location that can be queried by calling GetUniformLocation. Also, any
+// active user-defined attribute variables that have not been bound to a
+// generic vertex attribute index will be bound to one at this time.
+//
+// Linking of a program object can fail for a number of reasons as specified
+// in the OpenGL Shading Language Specification. The following lists some of
+// the conditions that will cause a link error.
+//
+// - The number of active attribute variables supported by the
+// implementation has been exceeded.
+//
+// - The storage limit for uniform variables has been exceeded.
+//
+// - The number of active uniform variables supported by the implementation
+// has been exceeded.
+//
+// - The main function is missing for the vertex shader or the fragment
+// shader.
+//
+// - A varying variable actually used in the fragment shader is not
+// declared in the same way (or is not declared at all) in the vertex
+// shader.
+//
+// - A reference to a function or variable name is unresolved.
+//
+// - A shared global is declared with two different types or two different
+// initial values.
+//
+// - One or more of the attached shader objects has not been successfully
+// compiled.
+//
+// - Binding a generic attribute matrix caused some rows of the matrix to
+// fall outside the allowed maximum of GL.MAX_VERTEX_ATTRIBS.
+//
+// - Not enough contiguous vertex attribute slots could be found to bind
+// attribute matrices.
+//
+// When a program object has been successfully linked, the program object can
+// be made part of current state by calling UseProgram. Whether or not the
+// link operation was successful, the program object's information log will
+// be overwritten. The information log can be retrieved by calling
+// GetProgramInfoLog.
+//
+// LinkProgram will also install the generated executables as part of the
+// current rendering state if the link operation was successful and the
+// specified program object is already currently in use as a result of a
+// previous call to UseProgram. If the program object currently in use is
+// relinked unsuccessfully, its link status will be set to GL.FALSE , but the
+// executables and associated state will remain part of the current state
+// until a subsequent call to UseProgram removes it from use. After it is
+// removed from use, it cannot be made part of current state until it has
+// been successfully relinked.
+//
+// If program contains shader objects of type GL.VERTEX_SHADER but does not
+// contain shader objects of type GL.FRAGMENT_SHADER, the vertex shader will
+// be linked against the implicit interface for fixed functionality fragment
+// processing. Similarly, if program contains shader objects of type
+// GL.FRAGMENT_SHADER but it does not contain shader objects of type
+// GL.VERTEX_SHADER, the fragment shader will be linked against the implicit
+// interface for fixed functionality vertex processing.
+//
+// The program object's information log is updated and the program is
+// generated at the time of the link operation. After the link operation,
+// applications are free to modify attached shader objects, compile attached
+// shader objects, detach shader objects, delete shader objects, and attach
+// additional shader objects. None of these operations affects the
+// information log or the program that is part of the program object.
+//
+// If the link operation is unsuccessful, any information about a previous
+// link operation on program is lost (a failed link does not restore the
+// old state of program). Certain information can still be retrieved
+// from program even after an unsuccessful link operation. See for instance
+// GetActiveAttrib and GetActiveUniform.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program
+// object. GL.INVALID_OPERATION is generated if LinkProgram is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// LinkProgram is available in GL version 2.0 or greater.
+func (gl *GL) LinkProgram(program glbase.Program) {
+ C.gl2_1_glLinkProgram(gl.funcs, C.GLuint(program))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIsShader.xml
+func (gl *GL) IsShader(shader glbase.Shader) bool {
+ glresult := C.gl2_1_glIsShader(gl.funcs, C.GLuint(shader))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIsProgram.xml
+func (gl *GL) IsProgram(program glbase.Program) bool {
+ glresult := C.gl2_1_glIsProgram(gl.funcs, C.GLuint(program))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// GetVertexAttribiv returns in params the value of a generic vertex attribute
+// parameter. The generic vertex attribute to be queried is specified by
+// index, and the parameter to be queried is specified by pname.
+//
+// The accepted parameter names are as follows:
+//
+// GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING
+// params returns a single value, the name of the buffer object
+// currently bound to the binding point corresponding to generic vertex
+// attribute array index. If no buffer object is bound, 0 is returned.
+// The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_ENABLED
+// params returns a single value that is non-zero (true) if the vertex
+// attribute array for index is enabled and 0 (false) if it is
+// disabled. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_SIZE
+// params returns a single value, the size of the vertex attribute
+// array for index. The size is the number of values for each element
+// of the vertex attribute array, and it will be 1, 2, 3, or 4. The
+// initial value is 4.
+//
+// GL.VERTEX_ATTRIB_ARRAY_STRIDE
+// params returns a single value, the array stride for (number of bytes
+// between successive elements in) the vertex attribute array for
+// index. A value of 0 indicates that the array elements are stored
+// sequentially in memory. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_TYPE
+// params returns a single value, a symbolic constant indicating the
+// array type for the vertex attribute array for index. Possible values
+// are GL.BYTE, GL.UNSIGNED_BYTE, GL.SHORT, GL.UNSIGNED_SHORT, GL.INT,
+// GL.UNSIGNED_INT, GL.FLOAT, and GL.DOUBLE. The initial value is
+// GL.FLOAT.
+//
+// GL.VERTEX_ATTRIB_ARRAY_NORMALIZED
+// params returns a single value that is non-zero (true) if fixed-point
+// data types for the vertex attribute array indicated by index are
+// normalized when they are converted to floating point, and 0 (false)
+// otherwise. The initial value is 0.
+//
+// GL.CURRENT_VERTEX_ATTRIB
+// params returns four values that represent the current value for the
+// generic vertex attribute specified by index. Generic vertex
+// attribute 0 is unique in that it has no current state, so an error
+// will be generated if index is 0. The initial value for all other
+// generic vertex attributes is (0,0,0,1).
+//
+// All of the parameters except GL.CURRENT_VERTEX_ATTRIB represent
+// client-side state.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_ENUM is generated if pname is not an
+// accepted value. GL.INVALID_OPERATION is generated if index is 0 and pname
+// is GL.CURRENT_VERTEX_ATTRIB.
+//
+// GetVertexAttribiv is available in GL version 2.0 or greater.
+func (gl *GL) GetVertexAttribiv(index glbase.Attrib, pname glbase.Enum, params []int32) {
+ var params_c [4]int32
+ C.gl2_1_glGetVertexAttribiv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetVertexAttribfv returns in params the value of a generic vertex attribute
+// parameter. The generic vertex attribute to be queried is specified by
+// index, and the parameter to be queried is specified by pname.
+//
+// The accepted parameter names are as follows:
+//
+// GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING
+// params returns a single value, the name of the buffer object
+// currently bound to the binding point corresponding to generic vertex
+// attribute array index. If no buffer object is bound, 0 is returned.
+// The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_ENABLED
+// params returns a single value that is non-zero (true) if the vertex
+// attribute array for index is enabled and 0 (false) if it is
+// disabled. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_SIZE
+// params returns a single value, the size of the vertex attribute
+// array for index. The size is the number of values for each element
+// of the vertex attribute array, and it will be 1, 2, 3, or 4. The
+// initial value is 4.
+//
+// GL.VERTEX_ATTRIB_ARRAY_STRIDE
+// params returns a single value, the array stride for (number of bytes
+// between successive elements in) the vertex attribute array for
+// index. A value of 0 indicates that the array elements are stored
+// sequentially in memory. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_TYPE
+// params returns a single value, a symbolic constant indicating the
+// array type for the vertex attribute array for index. Possible values
+// are GL.BYTE, GL.UNSIGNED_BYTE, GL.SHORT, GL.UNSIGNED_SHORT, GL.INT,
+// GL.UNSIGNED_INT, GL.FLOAT, and GL.DOUBLE. The initial value is
+// GL.FLOAT.
+//
+// GL.VERTEX_ATTRIB_ARRAY_NORMALIZED
+// params returns a single value that is non-zero (true) if fixed-point
+// data types for the vertex attribute array indicated by index are
+// normalized when they are converted to floating point, and 0 (false)
+// otherwise. The initial value is 0.
+//
+// GL.CURRENT_VERTEX_ATTRIB
+// params returns four values that represent the current value for the
+// generic vertex attribute specified by index. Generic vertex
+// attribute 0 is unique in that it has no current state, so an error
+// will be generated if index is 0. The initial value for all other
+// generic vertex attributes is (0,0,0,1).
+//
+// All of the parameters except GL.CURRENT_VERTEX_ATTRIB represent
+// client-side state.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_ENUM is generated if pname is not an
+// accepted value. GL.INVALID_OPERATION is generated if index is 0 and pname
+// is GL.CURRENT_VERTEX_ATTRIB.
+//
+// GetVertexAttribfv is available in GL version 2.0 or greater.
+func (gl *GL) GetVertexAttribfv(index glbase.Attrib, pname glbase.Enum, params []float32) {
+ var params_c [4]float32
+ C.gl2_1_glGetVertexAttribfv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetVertexAttribdv returns in params the value of a generic vertex attribute
+// parameter. The generic vertex attribute to be queried is specified by
+// index, and the parameter to be queried is specified by pname.
+//
+// The accepted parameter names are as follows:
+//
+// GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING
+// params returns a single value, the name of the buffer object
+// currently bound to the binding point corresponding to generic vertex
+// attribute array index. If no buffer object is bound, 0 is returned.
+// The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_ENABLED
+// params returns a single value that is non-zero (true) if the vertex
+// attribute array for index is enabled and 0 (false) if it is
+// disabled. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_SIZE
+// params returns a single value, the size of the vertex attribute
+// array for index. The size is the number of values for each element
+// of the vertex attribute array, and it will be 1, 2, 3, or 4. The
+// initial value is 4.
+//
+// GL.VERTEX_ATTRIB_ARRAY_STRIDE
+// params returns a single value, the array stride for (number of bytes
+// between successive elements in) the vertex attribute array for
+// index. A value of 0 indicates that the array elements are stored
+// sequentially in memory. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_TYPE
+// params returns a single value, a symbolic constant indicating the
+// array type for the vertex attribute array for index. Possible values
+// are GL.BYTE, GL.UNSIGNED_BYTE, GL.SHORT, GL.UNSIGNED_SHORT, GL.INT,
+// GL.UNSIGNED_INT, GL.FLOAT, and GL.DOUBLE. The initial value is
+// GL.FLOAT.
+//
+// GL.VERTEX_ATTRIB_ARRAY_NORMALIZED
+// params returns a single value that is non-zero (true) if fixed-point
+// data types for the vertex attribute array indicated by index are
+// normalized when they are converted to floating point, and 0 (false)
+// otherwise. The initial value is 0.
+//
+// GL.CURRENT_VERTEX_ATTRIB
+// params returns four values that represent the current value for the
+// generic vertex attribute specified by index. Generic vertex
+// attribute 0 is unique in that it has no current state, so an error
+// will be generated if index is 0. The initial value for all other
+// generic vertex attributes is (0,0,0,1).
+//
+// All of the parameters except GL.CURRENT_VERTEX_ATTRIB represent
+// client-side state.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_ENUM is generated if pname is not an
+// accepted value. GL.INVALID_OPERATION is generated if index is 0 and pname
+// is GL.CURRENT_VERTEX_ATTRIB.
+//
+// GetVertexAttribdv is available in GL version 2.0 or greater.
+func (gl *GL) GetVertexAttribdv(index glbase.Attrib, pname glbase.Enum, params []float64) {
+ var params_c [4]float64
+ C.gl2_1_glGetVertexAttribdv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetUniformiv returns in params the value of the specified uniform
+// variable. The type of the uniform variable specified by location
+// determines the number of values returned. If the uniform variable is
+// defined in the shader as a boolean, int, or float, a single value will be
+// returned. If it is defined as a vec2, ivec2, or bvec2, two values will be
+// returned. If it is defined as a vec3, ivec3, or bvec3, three values will
+// be returned, and so on. To query values stored in uniform variables
+// declared as arrays, call GetUniformiv for each element of the array. To
+// query values stored in uniform variables declared as structures, call
+// GetUniformiv for each field in the structure. The values for uniform
+// variables declared as a matrix will be returned in column major order.
+//
+// The locations assigned to uniform variables are not known until the
+// program object is linked. After linking has occurred, the command
+// GetUniformLocation can be used to obtain the location of a uniform
+// variable. This location value can then be passed to GetUniformiv in order
+// to query the current value of the uniform variable. After a program object
+// has been linked successfully, the index values for uniform variables
+// remain fixed until the next link command occurs. The uniform variable
+// values can only be queried after a link if the link was successful.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program
+// object. GL.INVALID_OPERATION is generated if program has not been
+// successfully linked. GL.INVALID_OPERATION is generated if location does
+// not correspond to a valid uniform variable location for the specified
+// program object. GL.INVALID_OPERATION is generated if GetUniformiv is
+// executed between the execution of Begin and the corresponding execution of
+// End.
+//
+// GetUniformiv is available in GL version 2.0 or greater.
+func (gl *GL) GetUniformiv(program glbase.Program, location glbase.Uniform, params []int32) {
+ var params_c [4]int32
+ C.gl2_1_glGetUniformiv(gl.funcs, C.GLuint(program), C.GLint(location), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetUniformfv returns in params the value of the specified uniform
+// variable. The type of the uniform variable specified by location
+// determines the number of values returned. If the uniform variable is
+// defined in the shader as a boolean, int, or float, a single value will be
+// returned. If it is defined as a vec2, ivec2, or bvec2, two values will be
+// returned. If it is defined as a vec3, ivec3, or bvec3, three values will
+// be returned, and so on. To query values stored in uniform variables
+// declared as arrays, call GetUniformfv for each element of the array. To
+// query values stored in uniform variables declared as structures, call
+// GetUniformfv for each field in the structure. The values for uniform
+// variables declared as a matrix will be returned in column major order.
+//
+// The locations assigned to uniform variables are not known until the
+// program object is linked. After linking has occurred, the command
+// GetUniformLocation can be used to obtain the location of a uniform
+// variable. This location value can then be passed to GetUniformfv in order
+// to query the current value of the uniform variable. After a program object
+// has been linked successfully, the index values for uniform variables
+// remain fixed until the next link command occurs. The uniform variable
+// values can only be queried after a link if the link was successful.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program
+// object. GL.INVALID_OPERATION is generated if program has not been
+// successfully linked. GL.INVALID_OPERATION is generated if location does
+// not correspond to a valid uniform variable location for the specified
+// program object. GL.INVALID_OPERATION is generated if GetUniformfv is
+// executed between the execution of Begin and the corresponding execution of
+// End.
+//
+// GetUniformfv is available in GL version 2.0 or greater.
+func (gl *GL) GetUniformfv(program glbase.Program, location glbase.Uniform, params []float32) {
+ var params_c [4]float32
+ C.gl2_1_glGetUniformfv(gl.funcs, C.GLuint(program), C.GLint(location), (*C.GLfloat)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetUniformLocation returns an integer that represents the location of a
+// specific uniform variable within a program object. name must be an active
+// uniform variable name in program that is not a structure, an array of
+// structures, or a subcomponent of a vector or a matrix. This function
+// returns -1 if name does not correspond to an active uniform variable in
+// program or if name starts with the reserved prefix "gl_".
+//
+// Uniform variables that are structures or arrays of structures may be
+// queried by calling GetUniformLocation for each field within the
+// structure. The array element operator "[]" and the structure field
+// operator "." may be used in name in order to select elements within an
+// array or fields within a structure. The result of using these operators is
+// not allowed to be another structure, an array of structures, or a
+// subcomponent of a vector or a matrix. Except if the last part of name
+// indicates a uniform variable array, the location of the first element of
+// an array can be retrieved by using the name of the array, or by using the
+// name appended by "[0]".
+//
+// The actual locations assigned to uniform variables are not known until the
+// program object is linked successfully. After linking has occurred, the
+// command GetUniformLocation can be used to obtain the location of a
+// uniform variable. This location value can then be passed to Uniform to
+// set the value of the uniform variable or to GetUniform in order to query
+// the current value of the uniform variable. After a program object has been
+// linked successfully, the index values for uniform variables remain fixed
+// until the next link command occurs. Uniform variable locations and values
+// can only be queried after a link if the link was successful.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program object.
+// GL.INVALID_OPERATION is generated if program has not been successfully
+// linked. GL.INVALID_OPERATION is generated if GetUniformLocation is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// GetUniformLocation is available in GL version 2.0 or greater.
+func (gl *GL) GetUniformLocation(program glbase.Program, name string) glbase.Uniform {
+ name_cstr := C.CString(name)
+ glresult := C.gl2_1_glGetUniformLocation(gl.funcs, C.GLuint(program), (*C.GLchar)(name_cstr))
+ C.free(unsafe.Pointer(name_cstr))
+ return glbase.Uniform(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetShaderSource.xml
+func (gl *GL) GetShaderSource(shader glbase.Shader, bufSize int32, length []int32, source []byte) {
+ C.gl2_1_glGetShaderSource(gl.funcs, C.GLuint(shader), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&source[0])))
+}
+
+// GetShaderInfoLog returns the information log for the specified shader
+// object. The information log for a shader object is modified when the
+// shader is compiled.
+//
+// The information log for a shader object is a string that may contain
+// diagnostic messages, warning messages, and other information about the
+// last compile operation. When a shader object is created, its information
+// log will be a string of length 0, and the size of the current log can be
+// obtained by calling GetShaderiv with the value GL.INFO_LOG_LENGTH.
+//
+// The information log for a shader object is the OpenGL implementer's
+// primary mechanism for conveying information about the compilation process.
+// Therefore, the information log can be helpful to application developers
+// during the development process, even when compilation is successful.
+// Application developers should not expect different OpenGL implementations
+// to produce identical information logs.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader is not a shader
+// object. GL.INVALID_VALUE is generated if maxLength is less than 0.
+// GL.INVALID_OPERATION is generated if GetShaderInfoLog is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// GetShaderInfoLog is available in GL version 2.0 or greater.
+func (gl *GL) GetShaderInfoLog(shader glbase.Shader) []byte {
+ var params [1]int32
+ var length int32
+ gl.GetShaderiv(shader, INFO_LOG_LENGTH, params[:])
+ bufSize := params[0]
+ infoLog := make([]byte, int(bufSize))
+ C.gl2_1_glGetShaderInfoLog(gl.funcs, C.GLuint(shader), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length)), (*C.GLchar)(unsafe.Pointer(&infoLog[0])))
+ return infoLog
+}
+
+// GetShaderiv GetShader returns in params the value of a parameter for a specific
+// shader object. The following parameters are defined:
+//
+// GL.SHADER_TYPE
+// params returns GL.VERTEX_SHADER if shader is a vertex shader object,
+// and GL.FRAGMENT_SHADER if shader is a fragment shader object.
+//
+// GL.DELETE_STATUS
+// params returns GL.TRUE if shader is currently flagged for deletion,
+// and GL.FALSE otherwise.
+//
+// GL.COMPILE_STATUS
+// params returns GL.TRUE if the last compile operation on shader was
+// successful, and GL.FALSE otherwise.
+//
+// GL.INFO_LOG_LENGTH
+// params returns the number of characters in the information log for
+// shader including the null termination character (the size of the
+// character buffer required to store the information log). If shader has
+// no information log, a value of 0 is returned.
+//
+// GL.SHADER_SOURCE_LENGTH
+// params returns the length of the concatenation of the source strings
+// that make up the shader source for the shader, including the null
+// termination character. (the size of the character buffer
+// required to store the shader source). If no source code exists, 0 is
+// returned.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader does not refer to a
+// shader object. GL.INVALID_ENUM is generated if pname is not an accepted
+// value. GL.INVALID_OPERATION is generated if GetShader is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// GetShaderiv is available in GL version 2.0 or greater.
+func (gl *GL) GetShaderiv(shader glbase.Shader, pname glbase.Enum, params []int32) {
+ var params_c [4]int32
+ C.gl2_1_glGetShaderiv(gl.funcs, C.GLuint(shader), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetProgramInfoLog returns the information log for the specified program
+// object. The information log for a program object is modified when the
+// program object is linked or validated.
+//
+// The information log for a program object is either an empty string, or a
+// string containing information about the last link operation, or a string
+// containing information about the last validation operation. It may contain
+// diagnostic messages, warning messages, and other information. When a
+// program object is created, its information log will be a string of length
+// 0, and the size of the current log can be obtained by calling GetProgramiv
+// with the value GL.INFO_LOG_LENGTH.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated
+// by OpenGL. GL.INVALID_OPERATION is generated if program is not a
+// program object.
+func (gl *GL) GetProgramInfoLog(program glbase.Program) []byte {
+ var params [1]int32
+ var length int32
+ gl.GetProgramiv(program, INFO_LOG_LENGTH, params[:])
+ bufSize := params[0]
+ infoLog := make([]byte, int(bufSize))
+ C.gl2_1_glGetProgramInfoLog(gl.funcs, C.GLuint(program), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length)), (*C.GLchar)(unsafe.Pointer(&infoLog[0])))
+ return infoLog
+}
+
+// GetProgramiv returns in params the value of a parameter for a specific
+// program object. The following parameters are defined:
+//
+// GL.DELETE_STATUS
+// params returns GL.TRUE if program is currently flagged for deletion,
+// and GL.FALSE otherwise.
+//
+// GL.LINK_STATUS
+// params returns GL.TRUE if the last link operation on program was
+// successful, and GL.FALSE otherwise.
+//
+// GL.VALIDATE_STATUS
+// params returns GL.TRUE or if the last validation operation on
+// program was successful, and GL.FALSE otherwise.
+//
+// GL.INFO_LOG_LENGTH
+// params returns the number of characters in the information log for
+// program including the null termination character (the size of
+// the character buffer required to store the information log). If
+// program has no information log, a value of 0 is returned.
+//
+// GL.ATTACHED_SHADERS
+// params returns the number of shader objects attached to program.
+//
+// GL.ACTIVE_ATTRIBUTES
+// params returns the number of active attribute variables for program.
+//
+// GL.ACTIVE_ATTRIBUTE_MAX_LENGTH
+// params returns the length of the longest active attribute name for
+// program, including the null termination character (the size of
+// the character buffer required to store the longest attribute name).
+// If no active attributes exist, 0 is returned.
+//
+// GL.ACTIVE_UNIFORMS
+// params returns the number of active uniform variables for program.
+//
+// GL.ACTIVE_UNIFORM_MAX_LENGTH
+// params returns the length of the longest active uniform variable
+// name for program, including the null termination character (i.e.,
+// the size of the character buffer required to store the longest
+// uniform variable name). If no active uniform variables exist, 0 is
+// returned.
+//
+// GL.TRANSFORM_FEEDBACK_BUFFER_MODE
+// params returns a symbolic constant indicating the buffer mode used
+// when transform feedback is active. This may be GL.SEPARATE_ATTRIBS
+// or GL.INTERLEAVED_ATTRIBS.
+//
+// GL.TRANSFORM_FEEDBACK_VARYINGS
+// params returns the number of varying variables to capture in transform
+// feedback mode for the program.
+//
+// GL.TRANSFORM_FEEDBACK_VARYING_MAX_LENGTH
+// params returns the length of the longest variable name to be used for
+// transform feedback, including the null-terminator.
+//
+// GL.GEOMETRY_VERTICES_OUT
+// params returns the maximum number of vertices that the geometry shader in
+// program will output.
+//
+// GL.GEOMETRY_INPUT_TYPE
+// params returns a symbolic constant indicating the primitive type accepted
+// as input to the geometry shader contained in program.
+//
+// GL.GEOMETRY_OUTPUT_TYPE
+// params returns a symbolic constant indicating the primitive type that will
+// be output by the geometry shader contained in program.
+//
+// GL.ACTIVE_UNIFORM_BLOCKS and GL.ACTIVE_UNIFORM_BLOCK_MAX_NAME_LENGTH are
+// available only if the GL version 3.1 or greater.
+//
+// GL.GEOMETRY_VERTICES_OUT, GL.GEOMETRY_INPUT_TYPE and
+// GL.GEOMETRY_OUTPUT_TYPE are accepted only if the GL version is 3.2 or
+// greater.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program does not refer to a
+// program object. GL.INVALID_OPERATION is generated if pname is
+// GL.GEOMETRY_VERTICES_OUT, GL.GEOMETRY_INPUT_TYPE, or
+// GL.GEOMETRY_OUTPUT_TYPE, and program does not contain a geometry shader.
+// GL.INVALID_ENUM is generated if pname is not an accepted value.
+func (gl *GL) GetProgramiv(program glbase.Program, pname glbase.Enum, params []int32) {
+ var params_c [4]int32
+ C.gl2_1_glGetProgramiv(gl.funcs, C.GLuint(program), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetAttribLocation queries the previously linked program object specified
+// by program for the attribute variable specified by name and returns the
+// index of the generic vertex attribute that is bound to that attribute
+// variable. If name is a matrix attribute variable, the index of the first
+// column of the matrix is returned. If the named attribute variable is not
+// an active attribute in the specified program object or if name starts with
+// the reserved prefix "gl_", a value of -1 is returned.
+//
+// The association between an attribute variable name and a generic attribute
+// index can be specified at any time by calling BindAttribLocation.
+// Attribute bindings do not go into effect until LinkProgram is called.
+// After a program object has been linked successfully, the index values for
+// attribute variables remain fixed until the next link command occurs. The
+// attribute values can only be queried after a link if the link was
+// successful. GetAttribLocation returns the binding that actually went
+// into effect the last time LinkProgram was called for the specified
+// program object. Attribute bindings that have been specified since the last
+// link operation are not returned by GetAttribLocation.
+//
+// Error GL_INVALID_OPERATION is generated if program is not a value
+// generated by OpenGL. GL_INVALID_OPERATION is generated if program is not
+// a program object. GL_INVALID_OPERATION is generated if program has not
+// been successfully linked. GL_INVALID_OPERATION is generated if
+// GetAttribLocation is executed between the execution of Begin and the
+// corresponding execution of End.
+//
+// GetAttribLocation is available in GL version 2.0 or greater.
+func (gl *GL) GetAttribLocation(program glbase.Program, name string) glbase.Attrib {
+ name_cstr := C.CString(name)
+ glresult := C.gl2_1_glGetAttribLocation(gl.funcs, C.GLuint(program), (*C.GLchar)(name_cstr))
+ C.free(unsafe.Pointer(name_cstr))
+ return glbase.Attrib(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetAttachedShaders.xml
+func (gl *GL) GetAttachedShaders(program glbase.Program, maxCount int32, count []int, obj []uint32) {
+ C.gl2_1_glGetAttachedShaders(gl.funcs, C.GLuint(program), C.GLsizei(maxCount), (*C.GLsizei)(unsafe.Pointer(&count[0])), (*C.GLuint)(unsafe.Pointer(&obj[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetActiveUniform.xml
+func (gl *GL) GetActiveUniform(program glbase.Program, index uint32, bufSize int32, length []int32, size []int, gltype []glbase.Enum, name []byte) {
+ C.gl2_1_glGetActiveUniform(gl.funcs, C.GLuint(program), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLint)(unsafe.Pointer(&size[0])), (*C.GLenum)(unsafe.Pointer(&gltype[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetActiveAttrib.xml
+func (gl *GL) GetActiveAttrib(program glbase.Program, index glbase.Attrib, bufSize int32, length []int32, size []int, gltype []glbase.Enum, name []byte) {
+ C.gl2_1_glGetActiveAttrib(gl.funcs, C.GLuint(program), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLint)(unsafe.Pointer(&size[0])), (*C.GLenum)(unsafe.Pointer(&gltype[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEnableVertexAttribArray.xml
+func (gl *GL) EnableVertexAttribArray(index glbase.Attrib) {
+ C.gl2_1_glEnableVertexAttribArray(gl.funcs, C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDisableVertexAttribArray.xml
+func (gl *GL) DisableVertexAttribArray(index glbase.Attrib) {
+ C.gl2_1_glDisableVertexAttribArray(gl.funcs, C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDetachShader.xml
+func (gl *GL) DetachShader(program glbase.Program, shader glbase.Shader) {
+ C.gl2_1_glDetachShader(gl.funcs, C.GLuint(program), C.GLuint(shader))
+}
+
+// DeleteShader frees the memory and invalidates the name associated with
+// the shader object specified by shader. This command effectively undoes the
+// effects of a call to CreateShader.
+//
+// If a shader object to be deleted is attached to a program object, it will
+// be flagged for deletion, but it will not be deleted until it is no longer
+// attached to any program object, for any rendering context (it must
+// be detached from wherever it was attached before it will be deleted). A
+// value of 0 for shader will be silently ignored.
+//
+// To determine whether an object has been flagged for deletion, call
+// GetShader with arguments shader and GL.DELETE_STATUS.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL.
+//
+// DeleteShader is available in GL version 2.0 or greater.
+func (gl *GL) DeleteShader(shader glbase.Shader) {
+ C.gl2_1_glDeleteShader(gl.funcs, C.GLuint(shader))
+}
+
+// DeleteProgram frees the memory and invalidates the name associated with
+// the program object specified by program. This command effectively undoes
+// the effects of a call to CreateProgram.
+//
+// If a program object is in use as part of current rendering state, it will
+// be flagged for deletion, but it will not be deleted until it is no longer
+// part of current state for any rendering context. If a program object to be
+// deleted has shader objects attached to it, those shader objects will be
+// automatically detached but not deleted unless they have already been
+// flagged for deletion by a previous call to DeleteShader. A value of 0
+// for program will be silently ignored.
+//
+// To determine whether a program object has been flagged for deletion, call
+// GetProgram with arguments program and GL.DELETE_STATUS.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL.
+//
+// DeleteProgram is available in GL version 2.0 or greater.
+func (gl *GL) DeleteProgram(program glbase.Program) {
+ C.gl2_1_glDeleteProgram(gl.funcs, C.GLuint(program))
+}
+
+// CreateShader creates an empty shader object and returns a non-zero value
+// by which it can be referenced. A shader object is used to maintain the
+// source code strings that define a shader. shaderType indicates the type of
+// shader to be created.
+//
+// Two types of shaders are supported. A shader of type GL.VERTEX_SHADER is a
+// shader that is intended to run on the programmable vertex processor and
+// replace the fixed functionality vertex processing in OpenGL. A shader of
+// type GL.FRAGMENT_SHADER is a shader that is intended to run on the
+// programmable fragment processor and replace the fixed functionality
+// fragment processing in OpenGL.
+//
+// When created, a shader object's GL.SHADER_TYPE parameter is set to either
+// GL.VERTEX_SHADER or GL.FRAGMENT_SHADER, depending on the value of
+// shaderType.
+//
+// Like display lists and texture objects, the name space for shader objects
+// may be shared across a set of contexts, as long as the server sides of the
+// contexts share the same address space. If the name space is shared across
+// contexts, any attached objects and the data associated with those attached
+// objects are shared as well.
+//
+// This function returns 0 if an error occurs creating the shader object.
+//
+// Error GL.INVALID_ENUM is generated if shaderType is not an accepted value.
+// GL.INVALID_OPERATION is generated if CreateShader is executed between the
+// execution of Begin and the corresponding execution of End.
+//
+// CreateShader is available in GL version 2.0 or greater.
+func (gl *GL) CreateShader(gltype glbase.Enum) glbase.Shader {
+ glresult := C.gl2_1_glCreateShader(gl.funcs, C.GLenum(gltype))
+ return glbase.Shader(glresult)
+}
+
+// CreateProgram creates an empty program object and returns a non-zero
+// value by which it can be referenced. A program object is an object to
+// which shader objects can be attached. This provides a mechanism to specify
+// the shader objects that will be linked to create a program. It also
+// provides a means for checking the compatibility of the shaders that will
+// be used to create a program (for instance, checking the compatibility
+// between a vertex shader and a fragment shader). When no longer needed as
+// part of a program object, shader objects can be detached.
+//
+// One or more executables are created in a program object by successfully
+// attaching shader objects to it with AttachShader, successfully compiling
+// the shader objects with CompileShader, and successfully linking the
+// program object with LinkProgram. These executables are made part of
+// current state when UseProgram is called. Program objects can be deleted
+// by calling DeleteProgram. The memory associated with the program object
+// will be deleted when it is no longer part of current rendering state for
+// any context.
+//
+// Like display lists and texture objects, the name space for program objects
+// may be shared across a set of contexts, as long as the server sides of the
+// contexts share the same address space. If the name space is shared across
+// contexts, any attached objects and the data associated with those attached
+// objects are shared as well.
+//
+// Applications are responsible for providing the synchronization across API
+// calls when objects are accessed from different execution threads.
+//
+// This function returns 0 if an error occurs creating the program object.
+//
+// Error GL.INVALID_OPERATION is generated if CreateProgram is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// CreateProgram is available in GL version 2.0 or greater.
+func (gl *GL) CreateProgram() glbase.Program {
+ glresult := C.gl2_1_glCreateProgram(gl.funcs)
+ return glbase.Program(glresult)
+}
+
+// CompileShader compiles the source code strings that have been stored in
+// the shader object specified by shader.
+//
+// The compilation status will be stored as part of the shader object's
+// state. This value will be set to GL.TRUE if the shader was compiled without
+// errors and is ready for use, and GL.FALSE otherwise. It can be queried by
+// calling GetShaderiv with arguments shader and GL.COMPILE_STATUS.
+//
+// Compilation of a shader can fail for a number of reasons as specified by
+// the OpenGL Shading Language Specification. Whether or not the compilation
+// was successful, information about the compilation can be obtained from the
+// shader object's information log by calling GetShaderInfoLog.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader is not a shader
+// object. GL.INVALID_OPERATION is generated if CompileShader is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// CompileShader is available in GL version 2.0 or greater.
+func (gl *GL) CompileShader(shader glbase.Shader) {
+ C.gl2_1_glCompileShader(gl.funcs, C.GLuint(shader))
+}
+
+// BindAttribLocation associates a user-defined attribute variable in the program
+// object specified by program with a generic vertex attribute index. The name
+// parameter specifies the name of the vertex shader attribute variable to
+// which index is to be bound. When program is made part of the current state,
+// values provided via the generic vertex attribute index will modify the
+// value of the user-defined attribute variable specified by name.
+//
+// If name refers to a matrix attribute variable, index refers to the first
+// column of the matrix. Other matrix columns are then automatically bound to
+// locations index+1 for a matrix of type mat2; index+1 and index+2 for a
+// matrix of type mat3; and index+1, index+2, and index+3 for a matrix of
+// type mat4.
+//
+// This command makes it possible for vertex shaders to use descriptive names
+// for attribute variables rather than generic variables that are numbered
+// from 0 to GL.MAX_VERTEX_ATTRIBS-1. The values sent to each generic
+// attribute index are part of current state, just like standard vertex
+// attributes such as color, normal, and vertex position. If a different
+// program object is made current by calling UseProgram, the generic vertex
+// attributes are tracked in such a way that the same values will be observed
+// by attributes in the new program object that are also bound to index.
+//
+// Attribute variable name-to-generic attribute index bindings for a program
+// object can be explicitly assigned at any time by calling
+// BindAttribLocation. Attribute bindings do not go into effect until
+// LinkProgram is called. After a program object has been linked
+// successfully, the index values for generic attributes remain fixed (and
+// their values can be queried) until the next link command occurs.
+//
+// Applications are not allowed to bind any of the standard OpenGL vertex
+// attributes using this command, as they are bound automatically when
+// needed. Any attribute binding that occurs after the program object has
+// been linked will not take effect until the next time the program object is
+// linked.
+//
+// If name was bound previously, that information is lost. Thus you cannot
+// bind one user-defined attribute variable to multiple indices, but you can
+// bind multiple user-defined attribute variables to the same index.
+//
+// Applications are allowed to bind more than one user-defined attribute
+// variable to the same generic vertex attribute index. This is called
+// aliasing, and it is allowed only if just one of the aliased attributes is
+// active in the executable program, or if no path through the shader
+// consumes more than one attribute of a set of attributes aliased to the
+// same location. The compiler and linker are allowed to assume that no
+// aliasing is done and are free to employ optimizations that work only in
+// the absence of aliasing. OpenGL implementations are not required to do
+// error checking to detect aliasing. Because there is no way to bind
+// standard attributes, it is not possible to alias generic attributes with
+// conventional ones (except for generic attribute 0).
+//
+// BindAttribLocation can be called before any vertex shader objects are
+// bound to the specified program object. It is also permissible to bind a
+// generic attribute index to an attribute variable name that is never used
+// in a vertex shader.
+//
+// Active attributes that are not explicitly bound will be bound by the
+// linker when LinkProgram is called. The locations assigned can be queried
+// by calling GetAttribLocation.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS.
+// GL.INVALID_OPERATION is generated if name starts with the reserved prefix "gl_".
+// GL.INVALID_VALUE is generated if program is not a value generated by OpenGL.
+// GL.INVALID_OPERATION is generated if program is not a program object.
+// GL.INVALID_OPERATION is generated if BindAttribLocation is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// BindAttribLocation is available in GL version 2.0 or greater.
+func (gl *GL) BindAttribLocation(program glbase.Program, index glbase.Attrib, name string) {
+ name_cstr := C.CString(name)
+ C.gl2_1_glBindAttribLocation(gl.funcs, C.GLuint(program), C.GLuint(index), (*C.GLchar)(name_cstr))
+ C.free(unsafe.Pointer(name_cstr))
+}
+
+// AttachShader attaches a shader object to a program object.
+//
+// In order to create an executable, there must be a way to specify the list
+// of things that will be linked together. Program objects provide this
+// mechanism. Shaders that are to be linked together in a program object must
+// first be attached to that program object. This indicates that shader will
+// be included in link operations that will be performed on program.
+//
+// All operations that can be performed on a shader object are valid whether
+// or not the shader object is attached to a program object. It is
+// permissible to attach a shader object to a program object before source
+// code has been loaded into the shader object or before the shader object
+// has been compiled. It is permissible to attach multiple shader objects of
+// the same type because each may contain a portion of the complete shader.
+// It is also permissible to attach a shader object to more than one program
+// object. If a shader object is deleted while it is attached to a program
+// object, it will be flagged for deletion, and deletion will not occur until
+// DetachShader is called to detach it from all program objects to which it
+// is attached.
+//
+// Error GL.INVALID_VALUE is generated if either program or shader is not a
+// value generated by OpenGL. GL.INVALID_OPERATION is generated if program
+// is not a program object. GL.INVALID_OPERATION is generated if shader is
+// not a shader object. GL.INVALID_OPERATION is generated if shader is
+// already attached to program. GL.INVALID_OPERATION is generated if
+// AttachShader is executed between the execution of Begin and the
+// corresponding execution of End.
+//
+// AttachShader is available in GL version 2.0 or greater.
+func (gl *GL) AttachShader(program glbase.Program, shader glbase.Shader) {
+ C.gl2_1_glAttachShader(gl.funcs, C.GLuint(program), C.GLuint(shader))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glStencilMaskSeparate.xml
+func (gl *GL) StencilMaskSeparate(face glbase.Enum, mask uint32) {
+ C.gl2_1_glStencilMaskSeparate(gl.funcs, C.GLenum(face), C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glStencilFuncSeparate.xml
+func (gl *GL) StencilFuncSeparate(face, glfunc glbase.Enum, ref int32, mask uint32) {
+ C.gl2_1_glStencilFuncSeparate(gl.funcs, C.GLenum(face), C.GLenum(glfunc), C.GLint(ref), C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glStencilOpSeparate.xml
+func (gl *GL) StencilOpSeparate(face, sfail, dpfail, dppass glbase.Enum) {
+ C.gl2_1_glStencilOpSeparate(gl.funcs, C.GLenum(face), C.GLenum(sfail), C.GLenum(dpfail), C.GLenum(dppass))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDrawBuffers.xml
+func (gl *GL) DrawBuffers(n int, bufs []glbase.Enum) {
+ C.gl2_1_glDrawBuffers(gl.funcs, C.GLsizei(n), (*C.GLenum)(unsafe.Pointer(&bufs[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBlendEquationSeparate.xml
+func (gl *GL) BlendEquationSeparate(modeRGB, modeAlpha glbase.Enum) {
+ C.gl2_1_glBlendEquationSeparate(gl.funcs, C.GLenum(modeRGB), C.GLenum(modeAlpha))
+}
+
+// UniformMatrix4x3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix4x3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix4x3fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(4*3) != 0 {
+ panic("invalid value length for UniformMatrix4x3fv")
+ }
+ count := len(value) / (4 * 3)
+ C.gl2_1_glUniformMatrix4x3fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix3x4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix3x4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix3x4fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(3*4) != 0 {
+ panic("invalid value length for UniformMatrix3x4fv")
+ }
+ count := len(value) / (3 * 4)
+ C.gl2_1_glUniformMatrix3x4fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix4x2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix4x2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix4x2fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(4*2) != 0 {
+ panic("invalid value length for UniformMatrix4x2fv")
+ }
+ count := len(value) / (4 * 2)
+ C.gl2_1_glUniformMatrix4x2fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix2x4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix2x4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix2x4fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(2*4) != 0 {
+ panic("invalid value length for UniformMatrix2x4fv")
+ }
+ count := len(value) / (2 * 4)
+ C.gl2_1_glUniformMatrix2x4fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix3x2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix3x2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix3x2fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(3*2) != 0 {
+ panic("invalid value length for UniformMatrix3x2fv")
+ }
+ count := len(value) / (3 * 2)
+ C.gl2_1_glUniformMatrix3x2fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix2x3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix2x3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix2x3fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(2*3) != 0 {
+ panic("invalid value length for UniformMatrix2x3fv")
+ }
+ count := len(value) / (2 * 3)
+ C.gl2_1_glUniformMatrix2x3fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTranslatef.xml
+func (gl *GL) Translatef(x, y, z float32) {
+ C.gl2_1_glTranslatef(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTranslated.xml
+func (gl *GL) Translated(x, y, z float64) {
+ C.gl2_1_glTranslated(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glScalef.xml
+func (gl *GL) Scalef(x, y, z float32) {
+ C.gl2_1_glScalef(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glScaled.xml
+func (gl *GL) Scaled(x, y, z float64) {
+ C.gl2_1_glScaled(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRotatef.xml
+func (gl *GL) Rotatef(angle, x, y, z float32) {
+ C.gl2_1_glRotatef(gl.funcs, C.GLfloat(angle), C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRotated.xml
+func (gl *GL) Rotated(angle, x, y, z float64) {
+ C.gl2_1_glRotated(gl.funcs, C.GLdouble(angle), C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPushMatrix.xml
+func (gl *GL) PushMatrix() {
+ C.gl2_1_glPushMatrix(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPopMatrix.xml
+func (gl *GL) PopMatrix() {
+ C.gl2_1_glPopMatrix(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glOrtho.xml
+func (gl *GL) Ortho(left, right, bottom, top, zNear, zFar float64) {
+ C.gl2_1_glOrtho(gl.funcs, C.GLdouble(left), C.GLdouble(right), C.GLdouble(bottom), C.GLdouble(top), C.GLdouble(zNear), C.GLdouble(zFar))
+}
+
+// MultMatrixd multiplies the current matrix with the provided matrix.
+//
+// The m parameter must hold 16 consecutive elements of a 4x4 column-major matrix.
+//
+// The current matrix is determined by the current matrix mode (see
+// MatrixMode). It is either the projection matrix, modelview matrix, or the
+// texture matrix.
+//
+// For example, if the current matrix is C and the coordinates to be transformed
+// are v = (v[0], v[1], v[2], v[3]), then the current transformation is C × v, or
+//
+// c[0] c[4] c[8] c[12] v[0]
+// c[1] c[5] c[9] c[13] v[1]
+// c[2] c[6] c[10] c[14] X v[2]
+// c[3] c[7] c[11] c[15] v[3]
+//
+// Calling MultMatrix with an argument of m = m[0], m[1], ..., m[15]
+// replaces the current transformation with (C X M) x v, or
+//
+// c[0] c[4] c[8] c[12] m[0] m[4] m[8] m[12] v[0]
+// c[1] c[5] c[9] c[13] m[1] m[5] m[9] m[13] v[1]
+// c[2] c[6] c[10] c[14] X m[2] m[6] m[10] m[14] X v[2]
+// c[3] c[7] c[11] c[15] m[3] m[7] m[11] m[15] v[3]
+//
+// Where 'X' denotes matrix multiplication, and v is represented as a 4x1 matrix.
+//
+// While the elements of the matrix may be specified with single or double
+// precision, the GL may store or operate on these values in less-than-single
+// precision.
+//
+// In many computer languages, 4×4 arrays are represented in row-major
+// order. The transformations just described represent these matrices in
+// column-major order. The order of the multiplication is important. For
+// example, if the current transformation is a rotation, and MultMatrix is
+// called with a translation matrix, the translation is done directly on the
+// coordinates to be transformed, while the rotation is done on the results
+// of that translation.
+//
+// GL.INVALID_OPERATION is generated if MultMatrix is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) MultMatrixd(m []float64) {
+ if len(m) != 16 {
+ panic("parameter m must have length 16 for the 4x4 matrix")
+ }
+ C.gl2_1_glMultMatrixd(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&m[0])))
+}
+
+// MultMatrixf multiplies the current matrix with the provided matrix.
+//
+// The m parameter must hold 16 consecutive elements of a 4x4 column-major matrix.
+//
+// The current matrix is determined by the current matrix mode (see
+// MatrixMode). It is either the projection matrix, modelview matrix, or the
+// texture matrix.
+//
+// For example, if the current matrix is C and the coordinates to be transformed
+// are v = (v[0], v[1], v[2], v[3]), then the current transformation is C × v, or
+//
+// c[0] c[4] c[8] c[12] v[0]
+// c[1] c[5] c[9] c[13] v[1]
+// c[2] c[6] c[10] c[14] X v[2]
+// c[3] c[7] c[11] c[15] v[3]
+//
+// Calling MultMatrix with an argument of m = m[0], m[1], ..., m[15]
+// replaces the current transformation with (C X M) x v, or
+//
+// c[0] c[4] c[8] c[12] m[0] m[4] m[8] m[12] v[0]
+// c[1] c[5] c[9] c[13] m[1] m[5] m[9] m[13] v[1]
+// c[2] c[6] c[10] c[14] X m[2] m[6] m[10] m[14] X v[2]
+// c[3] c[7] c[11] c[15] m[3] m[7] m[11] m[15] v[3]
+//
+// Where 'X' denotes matrix multiplication, and v is represented as a 4x1 matrix.
+//
+// While the elements of the matrix may be specified with single or double
+// precision, the GL may store or operate on these values in less-than-single
+// precision.
+//
+// In many computer languages, 4×4 arrays are represented in row-major
+// order. The transformations just described represent these matrices in
+// column-major order. The order of the multiplication is important. For
+// example, if the current transformation is a rotation, and MultMatrix is
+// called with a translation matrix, the translation is done directly on the
+// coordinates to be transformed, while the rotation is done on the results
+// of that translation.
+//
+// GL.INVALID_OPERATION is generated if MultMatrix is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) MultMatrixf(m []float32) {
+ if len(m) != 16 {
+ panic("parameter m must have length 16 for the 4x4 matrix")
+ }
+ C.gl2_1_glMultMatrixf(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMatrixMode.xml
+func (gl *GL) MatrixMode(mode glbase.Enum) {
+ C.gl2_1_glMatrixMode(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLoadMatrixd.xml
+func (gl *GL) LoadMatrixd(m []float64) {
+ C.gl2_1_glLoadMatrixd(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLoadMatrixf.xml
+func (gl *GL) LoadMatrixf(m []float32) {
+ C.gl2_1_glLoadMatrixf(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLoadIdentity.xml
+func (gl *GL) LoadIdentity() {
+ C.gl2_1_glLoadIdentity(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFrustum.xml
+func (gl *GL) Frustum(left, right, bottom, top, zNear, zFar float64) {
+ C.gl2_1_glFrustum(gl.funcs, C.GLdouble(left), C.GLdouble(right), C.GLdouble(bottom), C.GLdouble(top), C.GLdouble(zNear), C.GLdouble(zFar))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIsList.xml
+func (gl *GL) IsList(list uint32) bool {
+ glresult := C.gl2_1_glIsList(gl.funcs, C.GLuint(list))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexGeniv.xml
+func (gl *GL) GetTexGeniv(coord, pname glbase.Enum, params []int32) {
+ C.gl2_1_glGetTexGeniv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexGenfv.xml
+func (gl *GL) GetTexGenfv(coord, pname glbase.Enum, params []float32) {
+ C.gl2_1_glGetTexGenfv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexGendv.xml
+func (gl *GL) GetTexGendv(coord, pname glbase.Enum, params []float64) {
+ C.gl2_1_glGetTexGendv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexEnviv.xml
+func (gl *GL) GetTexEnviv(target, pname glbase.Enum, params []int32) {
+ C.gl2_1_glGetTexEnviv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexEnvfv.xml
+func (gl *GL) GetTexEnvfv(target, pname glbase.Enum, params []float32) {
+ C.gl2_1_glGetTexEnvfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetPolygonStipple.xml
+func (gl *GL) GetPolygonStipple(mask []uint8) {
+ C.gl2_1_glGetPolygonStipple(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&mask[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetPixelMapusv.xml
+func (gl *GL) GetPixelMapusv(glmap glbase.Enum, values []uint16) {
+ C.gl2_1_glGetPixelMapusv(gl.funcs, C.GLenum(glmap), (*C.GLushort)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetPixelMapuiv.xml
+func (gl *GL) GetPixelMapuiv(glmap glbase.Enum, values []uint32) {
+ C.gl2_1_glGetPixelMapuiv(gl.funcs, C.GLenum(glmap), (*C.GLuint)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetPixelMapfv.xml
+func (gl *GL) GetPixelMapfv(glmap glbase.Enum, values []float32) {
+ C.gl2_1_glGetPixelMapfv(gl.funcs, C.GLenum(glmap), (*C.GLfloat)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetMaterialiv.xml
+func (gl *GL) GetMaterialiv(face, pname glbase.Enum, params []int32) {
+ C.gl2_1_glGetMaterialiv(gl.funcs, C.GLenum(face), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetMaterialfv.xml
+func (gl *GL) GetMaterialfv(face, pname glbase.Enum, params []float32) {
+ C.gl2_1_glGetMaterialfv(gl.funcs, C.GLenum(face), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetMapiv.xml
+func (gl *GL) GetMapiv(target, query glbase.Enum, v []int32) {
+ C.gl2_1_glGetMapiv(gl.funcs, C.GLenum(target), C.GLenum(query), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetMapfv.xml
+func (gl *GL) GetMapfv(target, query glbase.Enum, v []float32) {
+ C.gl2_1_glGetMapfv(gl.funcs, C.GLenum(target), C.GLenum(query), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetMapdv.xml
+func (gl *GL) GetMapdv(target, query glbase.Enum, v []float64) {
+ C.gl2_1_glGetMapdv(gl.funcs, C.GLenum(target), C.GLenum(query), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetLightiv.xml
+func (gl *GL) GetLightiv(light, pname glbase.Enum, params []int32) {
+ C.gl2_1_glGetLightiv(gl.funcs, C.GLenum(light), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetLightfv.xml
+func (gl *GL) GetLightfv(light, pname glbase.Enum, params []float32) {
+ C.gl2_1_glGetLightfv(gl.funcs, C.GLenum(light), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetClipPlane.xml
+func (gl *GL) GetClipPlane(plane glbase.Enum, equation []float64) {
+ C.gl2_1_glGetClipPlane(gl.funcs, C.GLenum(plane), (*C.GLdouble)(unsafe.Pointer(&equation[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDrawPixels.xml
+func (gl *GL) DrawPixels(width, height int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_1_glDrawPixels(gl.funcs, C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyPixels.xml
+func (gl *GL) CopyPixels(x, y, width, height int, gltype glbase.Enum) {
+ C.gl2_1_glCopyPixels(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height), C.GLenum(gltype))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelMapusv.xml
+func (gl *GL) PixelMapusv(glmap glbase.Enum, mapsize int32, values []uint16) {
+ C.gl2_1_glPixelMapusv(gl.funcs, C.GLenum(glmap), C.GLint(mapsize), (*C.GLushort)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelMapuiv.xml
+func (gl *GL) PixelMapuiv(glmap glbase.Enum, mapsize int32, values []uint32) {
+ C.gl2_1_glPixelMapuiv(gl.funcs, C.GLenum(glmap), C.GLint(mapsize), (*C.GLuint)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelMapfv.xml
+func (gl *GL) PixelMapfv(glmap glbase.Enum, mapsize int32, values []float32) {
+ C.gl2_1_glPixelMapfv(gl.funcs, C.GLenum(glmap), C.GLint(mapsize), (*C.GLfloat)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelTransferi.xml
+func (gl *GL) PixelTransferi(pname glbase.Enum, param int32) {
+ C.gl2_1_glPixelTransferi(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelTransferf.xml
+func (gl *GL) PixelTransferf(pname glbase.Enum, param float32) {
+ C.gl2_1_glPixelTransferf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelZoom.xml
+func (gl *GL) PixelZoom(xfactor, yfactor float32) {
+ C.gl2_1_glPixelZoom(gl.funcs, C.GLfloat(xfactor), C.GLfloat(yfactor))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glAlphaFunc.xml
+func (gl *GL) AlphaFunc(glfunc glbase.Enum, ref float32) {
+ C.gl2_1_glAlphaFunc(gl.funcs, C.GLenum(glfunc), C.GLfloat(ref))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalPoint2.xml
+func (gl *GL) EvalPoint2(i, j int32) {
+ C.gl2_1_glEvalPoint2(gl.funcs, C.GLint(i), C.GLint(j))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalMesh2.xml
+func (gl *GL) EvalMesh2(mode glbase.Enum, i1, i2, j1, j2 int32) {
+ C.gl2_1_glEvalMesh2(gl.funcs, C.GLenum(mode), C.GLint(i1), C.GLint(i2), C.GLint(j1), C.GLint(j2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalPoint1.xml
+func (gl *GL) EvalPoint1(i int32) {
+ C.gl2_1_glEvalPoint1(gl.funcs, C.GLint(i))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalMesh1.xml
+func (gl *GL) EvalMesh1(mode glbase.Enum, i1, i2 int32) {
+ C.gl2_1_glEvalMesh1(gl.funcs, C.GLenum(mode), C.GLint(i1), C.GLint(i2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord2fv.xml
+func (gl *GL) EvalCoord2fv(u []float32) {
+ if len(u) != 2 {
+ panic("parameter u has incorrect length")
+ }
+ C.gl2_1_glEvalCoord2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&u[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord2f.xml
+func (gl *GL) EvalCoord2f(u, v float32) {
+ C.gl2_1_glEvalCoord2f(gl.funcs, C.GLfloat(u), C.GLfloat(v))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord2dv.xml
+func (gl *GL) EvalCoord2dv(u []float64) {
+ if len(u) != 2 {
+ panic("parameter u has incorrect length")
+ }
+ C.gl2_1_glEvalCoord2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&u[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord2d.xml
+func (gl *GL) EvalCoord2d(u, v float64) {
+ C.gl2_1_glEvalCoord2d(gl.funcs, C.GLdouble(u), C.GLdouble(v))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord1fv.xml
+func (gl *GL) EvalCoord1fv(u []float32) {
+ C.gl2_1_glEvalCoord1fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&u[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord1f.xml
+func (gl *GL) EvalCoord1f(u float32) {
+ C.gl2_1_glEvalCoord1f(gl.funcs, C.GLfloat(u))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord1dv.xml
+func (gl *GL) EvalCoord1dv(u []float64) {
+ C.gl2_1_glEvalCoord1dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&u[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEvalCoord1d.xml
+func (gl *GL) EvalCoord1d(u float64) {
+ C.gl2_1_glEvalCoord1d(gl.funcs, C.GLdouble(u))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMapGrid2f.xml
+func (gl *GL) MapGrid2f(un int32, u1, u2 float32, vn int32, v1, v2 float32) {
+ C.gl2_1_glMapGrid2f(gl.funcs, C.GLint(un), C.GLfloat(u1), C.GLfloat(u2), C.GLint(vn), C.GLfloat(v1), C.GLfloat(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMapGrid2d.xml
+func (gl *GL) MapGrid2d(un int32, u1, u2 float64, vn int32, v1, v2 float64) {
+ C.gl2_1_glMapGrid2d(gl.funcs, C.GLint(un), C.GLdouble(u1), C.GLdouble(u2), C.GLint(vn), C.GLdouble(v1), C.GLdouble(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMapGrid1f.xml
+func (gl *GL) MapGrid1f(un int32, u1, u2 float32) {
+ C.gl2_1_glMapGrid1f(gl.funcs, C.GLint(un), C.GLfloat(u1), C.GLfloat(u2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMapGrid1d.xml
+func (gl *GL) MapGrid1d(un int32, u1, u2 float64) {
+ C.gl2_1_glMapGrid1d(gl.funcs, C.GLint(un), C.GLdouble(u1), C.GLdouble(u2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMap2f.xml
+func (gl *GL) Map2f(target glbase.Enum, u1, u2 float32, ustride, uorder int32, v1, v2 float32, vstride, vorder int32, points []float32) {
+ C.gl2_1_glMap2f(gl.funcs, C.GLenum(target), C.GLfloat(u1), C.GLfloat(u2), C.GLint(ustride), C.GLint(uorder), C.GLfloat(v1), C.GLfloat(v2), C.GLint(vstride), C.GLint(vorder), (*C.GLfloat)(unsafe.Pointer(&points[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMap2d.xml
+func (gl *GL) Map2d(target glbase.Enum, u1, u2 float64, ustride, uorder int32, v1, v2 float64, vstride, vorder int32, points []float64) {
+ C.gl2_1_glMap2d(gl.funcs, C.GLenum(target), C.GLdouble(u1), C.GLdouble(u2), C.GLint(ustride), C.GLint(uorder), C.GLdouble(v1), C.GLdouble(v2), C.GLint(vstride), C.GLint(vorder), (*C.GLdouble)(unsafe.Pointer(&points[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMap1f.xml
+func (gl *GL) Map1f(target glbase.Enum, u1, u2 float32, stride, order int, points []float32) {
+ C.gl2_1_glMap1f(gl.funcs, C.GLenum(target), C.GLfloat(u1), C.GLfloat(u2), C.GLint(stride), C.GLint(order), (*C.GLfloat)(unsafe.Pointer(&points[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMap1d.xml
+func (gl *GL) Map1d(target glbase.Enum, u1, u2 float64, stride, order int, points []float64) {
+ C.gl2_1_glMap1d(gl.funcs, C.GLenum(target), C.GLdouble(u1), C.GLdouble(u2), C.GLint(stride), C.GLint(order), (*C.GLdouble)(unsafe.Pointer(&points[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPushAttrib.xml
+func (gl *GL) PushAttrib(mask glbase.Bitfield) {
+ C.gl2_1_glPushAttrib(gl.funcs, C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPopAttrib.xml
+func (gl *GL) PopAttrib() {
+ C.gl2_1_glPopAttrib(gl.funcs)
+}
+
+// Accum executes an operation on the accumulation buffer.
+//
+// Parameter op defines the accumulation buffer operation (GL.ACCUM, GL.LOAD,
+// GL.ADD, GL.MULT, or GL.RETURN) and specifies how the value parameter is
+// used.
+//
+// The accumulation buffer is an extended-range color buffer. Images are not
+// rendered into it. Rather, images rendered into one of the color buffers
+// are added to the contents of the accumulation buffer after rendering.
+// Effects such as antialiasing (of points, lines, and polygons), motion
+// blur, and depth of field can be created by accumulating images generated
+// with different transformation matrices.
+//
+// Each pixel in the accumulation buffer consists of red, green, blue, and
+// alpha values. The number of bits per component in the accumulation buffer
+// depends on the implementation. You can examine this number by calling
+// GetIntegerv four times, with arguments GL.ACCUM_RED_BITS,
+// GL.ACCUM_GREEN_BITS, GL.ACCUM_BLUE_BITS, and GL.ACCUM_ALPHA_BITS.
+// Regardless of the number of bits per component, the range of values stored
+// by each component is (-1, 1). The accumulation buffer pixels are mapped
+// one-to-one with frame buffer pixels.
+//
+// All accumulation buffer operations are limited to the area of the current
+// scissor box and applied identically to the red, green, blue, and alpha
+// components of each pixel. If a Accum operation results in a value outside
+// the range (-1, 1), the contents of an accumulation buffer pixel component
+// are undefined.
+//
+// The operations are as follows:
+//
+// GL.ACCUM
+// Obtains R, G, B, and A values from the buffer currently selected for
+// reading (see ReadBuffer). Each component value is divided by 2 n -
+// 1 , where n is the number of bits allocated to each color component
+// in the currently selected buffer. The result is a floating-point
+// value in the range 0 1 , which is multiplied by value and added to
+// the corresponding pixel component in the accumulation buffer,
+// thereby updating the accumulation buffer.
+//
+// GL.LOAD
+// Similar to GL.ACCUM, except that the current value in the
+// accumulation buffer is not used in the calculation of the new value.
+// That is, the R, G, B, and A values from the currently selected
+// buffer are divided by 2 n - 1 , multiplied by value, and then stored
+// in the corresponding accumulation buffer cell, overwriting the
+// current value.
+//
+// GL.ADD
+// Adds value to each R, G, B, and A in the accumulation buffer.
+//
+// GL.MULT
+// Multiplies each R, G, B, and A in the accumulation buffer by value
+// and returns the scaled component to its corresponding accumulation
+// buffer location.
+//
+// GL.RETURN
+// Transfers accumulation buffer values to the color buffer or buffers
+// currently selected for writing. Each R, G, B, and A component is
+// multiplied by value, then multiplied by 2 n - 1 , clamped to the
+// range 0 2 n - 1 , and stored in the corresponding display buffer
+// cell. The only fragment operations that are applied to this transfer
+// are pixel ownership, scissor, dithering, and color writemasks.
+//
+// To clear the accumulation buffer, call ClearAccum with R, G, B, and A
+// values to set it to, then call Clear with the accumulation buffer
+// enabled.
+//
+// Error GL.INVALID_ENUM is generated if op is not an accepted value.
+// GL.INVALID_OPERATION is generated if there is no accumulation buffer.
+// GL.INVALID_OPERATION is generated if Accum is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) Accum(op glbase.Enum, value float32) {
+ C.gl2_1_glAccum(gl.funcs, C.GLenum(op), C.GLfloat(value))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexMask.xml
+func (gl *GL) IndexMask(mask uint32) {
+ C.gl2_1_glIndexMask(gl.funcs, C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClearIndex.xml
+func (gl *GL) ClearIndex(c float32) {
+ C.gl2_1_glClearIndex(gl.funcs, C.GLfloat(c))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClearAccum.xml
+func (gl *GL) ClearAccum(red, green, blue, alpha float32) {
+ C.gl2_1_glClearAccum(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPushName.xml
+func (gl *GL) PushName(name uint32) {
+ C.gl2_1_glPushName(gl.funcs, C.GLuint(name))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPopName.xml
+func (gl *GL) PopName() {
+ C.gl2_1_glPopName(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPassThrough.xml
+func (gl *GL) PassThrough(token float32) {
+ C.gl2_1_glPassThrough(gl.funcs, C.GLfloat(token))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLoadName.xml
+func (gl *GL) LoadName(name uint32) {
+ C.gl2_1_glLoadName(gl.funcs, C.GLuint(name))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glInitNames.xml
+func (gl *GL) InitNames() {
+ C.gl2_1_glInitNames(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRenderMode.xml
+func (gl *GL) RenderMode(mode glbase.Enum) int32 {
+ glresult := C.gl2_1_glRenderMode(gl.funcs, C.GLenum(mode))
+ return int32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSelectBuffer.xml
+func (gl *GL) SelectBuffer(size int, buffer []glbase.Buffer) {
+ C.gl2_1_glSelectBuffer(gl.funcs, C.GLsizei(size), (*C.GLuint)(unsafe.Pointer(&buffer[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFeedbackBuffer.xml
+func (gl *GL) FeedbackBuffer(size int, gltype glbase.Enum, buffer []float32) {
+ C.gl2_1_glFeedbackBuffer(gl.funcs, C.GLsizei(size), C.GLenum(gltype), (*C.GLfloat)(unsafe.Pointer(&buffer[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexGeniv.xml
+func (gl *GL) TexGeniv(coord, pname glbase.Enum, params []int32) {
+ C.gl2_1_glTexGeniv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexGeni.xml
+func (gl *GL) TexGeni(coord, pname glbase.Enum, param int32) {
+ C.gl2_1_glTexGeni(gl.funcs, C.GLenum(coord), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexGenfv.xml
+func (gl *GL) TexGenfv(coord, pname glbase.Enum, params []float32) {
+ C.gl2_1_glTexGenfv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexGenf.xml
+func (gl *GL) TexGenf(coord, pname glbase.Enum, param float32) {
+ C.gl2_1_glTexGenf(gl.funcs, C.GLenum(coord), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexGendv.xml
+func (gl *GL) TexGendv(coord, pname glbase.Enum, params []float64) {
+ C.gl2_1_glTexGendv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexGend.xml
+func (gl *GL) TexGend(coord, pname glbase.Enum, param float64) {
+ C.gl2_1_glTexGend(gl.funcs, C.GLenum(coord), C.GLenum(pname), C.GLdouble(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexEnviv.xml
+func (gl *GL) TexEnviv(target, pname glbase.Enum, params []int32) {
+ C.gl2_1_glTexEnviv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexEnvi.xml
+func (gl *GL) TexEnvi(target, pname glbase.Enum, param int32) {
+ C.gl2_1_glTexEnvi(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexEnvfv.xml
+func (gl *GL) TexEnvfv(target, pname glbase.Enum, params []float32) {
+ C.gl2_1_glTexEnvfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexEnvf.xml
+func (gl *GL) TexEnvf(target, pname glbase.Enum, param float32) {
+ C.gl2_1_glTexEnvf(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glShadeModel.xml
+func (gl *GL) ShadeModel(mode glbase.Enum) {
+ C.gl2_1_glShadeModel(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPolygonStipple.xml
+func (gl *GL) PolygonStipple(mask []uint8) {
+ C.gl2_1_glPolygonStipple(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&mask[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMaterialiv.xml
+func (gl *GL) Materialiv(face, pname glbase.Enum, params []int32) {
+ C.gl2_1_glMaterialiv(gl.funcs, C.GLenum(face), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMateriali.xml
+func (gl *GL) Materiali(face, pname glbase.Enum, param int32) {
+ C.gl2_1_glMateriali(gl.funcs, C.GLenum(face), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMaterialfv.xml
+func (gl *GL) Materialfv(face, pname glbase.Enum, params []float32) {
+ C.gl2_1_glMaterialfv(gl.funcs, C.GLenum(face), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMaterialf.xml
+func (gl *GL) Materialf(face, pname glbase.Enum, param float32) {
+ C.gl2_1_glMaterialf(gl.funcs, C.GLenum(face), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLineStipple.xml
+func (gl *GL) LineStipple(factor int32, pattern uint16) {
+ C.gl2_1_glLineStipple(gl.funcs, C.GLint(factor), C.GLushort(pattern))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLightModeliv.xml
+func (gl *GL) LightModeliv(pname glbase.Enum, params []int32) {
+ C.gl2_1_glLightModeliv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLightModeli.xml
+func (gl *GL) LightModeli(pname glbase.Enum, param int32) {
+ C.gl2_1_glLightModeli(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLightModelfv.xml
+func (gl *GL) LightModelfv(pname glbase.Enum, params []float32) {
+ C.gl2_1_glLightModelfv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLightModelf.xml
+func (gl *GL) LightModelf(pname glbase.Enum, param float32) {
+ C.gl2_1_glLightModelf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLightiv.xml
+func (gl *GL) Lightiv(light, pname glbase.Enum, params []int32) {
+ C.gl2_1_glLightiv(gl.funcs, C.GLenum(light), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLighti.xml
+func (gl *GL) Lighti(light, pname glbase.Enum, param int32) {
+ C.gl2_1_glLighti(gl.funcs, C.GLenum(light), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLightfv.xml
+func (gl *GL) Lightfv(light, pname glbase.Enum, params []float32) {
+ C.gl2_1_glLightfv(gl.funcs, C.GLenum(light), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLightf.xml
+func (gl *GL) Lightf(light, pname glbase.Enum, param float32) {
+ C.gl2_1_glLightf(gl.funcs, C.GLenum(light), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFogiv.xml
+func (gl *GL) Fogiv(pname glbase.Enum, params []int32) {
+ C.gl2_1_glFogiv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFogi.xml
+func (gl *GL) Fogi(pname glbase.Enum, param int32) {
+ C.gl2_1_glFogi(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFogfv.xml
+func (gl *GL) Fogfv(pname glbase.Enum, params []float32) {
+ C.gl2_1_glFogfv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFogf.xml
+func (gl *GL) Fogf(pname glbase.Enum, param float32) {
+ C.gl2_1_glFogf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColorMaterial.xml
+func (gl *GL) ColorMaterial(face, mode glbase.Enum) {
+ C.gl2_1_glColorMaterial(gl.funcs, C.GLenum(face), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClipPlane.xml
+func (gl *GL) ClipPlane(plane glbase.Enum, equation []float64) {
+ C.gl2_1_glClipPlane(gl.funcs, C.GLenum(plane), (*C.GLdouble)(unsafe.Pointer(&equation[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4sv.xml
+func (gl *GL) Vertex4sv(v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glVertex4sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4s.xml
+func (gl *GL) Vertex4s(x, y, z, w int16) {
+ C.gl2_1_glVertex4s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z), C.GLshort(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4iv.xml
+func (gl *GL) Vertex4iv(v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glVertex4iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4i.xml
+func (gl *GL) Vertex4i(x, y, z, w int) {
+ C.gl2_1_glVertex4i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z), C.GLint(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4fv.xml
+func (gl *GL) Vertex4fv(v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glVertex4fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4f.xml
+func (gl *GL) Vertex4f(x, y, z, w float32) {
+ C.gl2_1_glVertex4f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z), C.GLfloat(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4dv.xml
+func (gl *GL) Vertex4dv(v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glVertex4dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex4d.xml
+func (gl *GL) Vertex4d(x, y, z, w float64) {
+ C.gl2_1_glVertex4d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z), C.GLdouble(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3sv.xml
+func (gl *GL) Vertex3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glVertex3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3s.xml
+func (gl *GL) Vertex3s(x, y, z int16) {
+ C.gl2_1_glVertex3s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3iv.xml
+func (gl *GL) Vertex3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glVertex3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3i.xml
+func (gl *GL) Vertex3i(x, y, z int) {
+ C.gl2_1_glVertex3i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3fv.xml
+func (gl *GL) Vertex3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glVertex3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3f.xml
+func (gl *GL) Vertex3f(x, y, z float32) {
+ C.gl2_1_glVertex3f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3dv.xml
+func (gl *GL) Vertex3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glVertex3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex3d.xml
+func (gl *GL) Vertex3d(x, y, z float64) {
+ C.gl2_1_glVertex3d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2sv.xml
+func (gl *GL) Vertex2sv(v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glVertex2sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2s.xml
+func (gl *GL) Vertex2s(x, y int16) {
+ C.gl2_1_glVertex2s(gl.funcs, C.GLshort(x), C.GLshort(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2iv.xml
+func (gl *GL) Vertex2iv(v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glVertex2iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2i.xml
+func (gl *GL) Vertex2i(x, y int) {
+ C.gl2_1_glVertex2i(gl.funcs, C.GLint(x), C.GLint(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2fv.xml
+func (gl *GL) Vertex2fv(v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glVertex2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2f.xml
+func (gl *GL) Vertex2f(x, y float32) {
+ C.gl2_1_glVertex2f(gl.funcs, C.GLfloat(x), C.GLfloat(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2dv.xml
+func (gl *GL) Vertex2dv(v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glVertex2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertex2d.xml
+func (gl *GL) Vertex2d(x, y float64) {
+ C.gl2_1_glVertex2d(gl.funcs, C.GLdouble(x), C.GLdouble(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4sv.xml
+func (gl *GL) TexCoord4sv(v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glTexCoord4sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4s.xml
+func (gl *GL) TexCoord4s(s, t, r, q int16) {
+ C.gl2_1_glTexCoord4s(gl.funcs, C.GLshort(s), C.GLshort(t), C.GLshort(r), C.GLshort(q))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4iv.xml
+func (gl *GL) TexCoord4iv(v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glTexCoord4iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4i.xml
+func (gl *GL) TexCoord4i(s, t, r, q int32) {
+ C.gl2_1_glTexCoord4i(gl.funcs, C.GLint(s), C.GLint(t), C.GLint(r), C.GLint(q))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4fv.xml
+func (gl *GL) TexCoord4fv(v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glTexCoord4fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4f.xml
+func (gl *GL) TexCoord4f(s, t, r, q float32) {
+ C.gl2_1_glTexCoord4f(gl.funcs, C.GLfloat(s), C.GLfloat(t), C.GLfloat(r), C.GLfloat(q))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4dv.xml
+func (gl *GL) TexCoord4dv(v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glTexCoord4dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord4d.xml
+func (gl *GL) TexCoord4d(s, t, r, q float64) {
+ C.gl2_1_glTexCoord4d(gl.funcs, C.GLdouble(s), C.GLdouble(t), C.GLdouble(r), C.GLdouble(q))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3sv.xml
+func (gl *GL) TexCoord3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glTexCoord3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3s.xml
+func (gl *GL) TexCoord3s(s, t, r int16) {
+ C.gl2_1_glTexCoord3s(gl.funcs, C.GLshort(s), C.GLshort(t), C.GLshort(r))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3iv.xml
+func (gl *GL) TexCoord3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glTexCoord3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3i.xml
+func (gl *GL) TexCoord3i(s, t, r int32) {
+ C.gl2_1_glTexCoord3i(gl.funcs, C.GLint(s), C.GLint(t), C.GLint(r))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3fv.xml
+func (gl *GL) TexCoord3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glTexCoord3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3f.xml
+func (gl *GL) TexCoord3f(s, t, r float32) {
+ C.gl2_1_glTexCoord3f(gl.funcs, C.GLfloat(s), C.GLfloat(t), C.GLfloat(r))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3dv.xml
+func (gl *GL) TexCoord3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glTexCoord3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord3d.xml
+func (gl *GL) TexCoord3d(s, t, r float64) {
+ C.gl2_1_glTexCoord3d(gl.funcs, C.GLdouble(s), C.GLdouble(t), C.GLdouble(r))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2sv.xml
+func (gl *GL) TexCoord2sv(v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glTexCoord2sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2s.xml
+func (gl *GL) TexCoord2s(s, t int16) {
+ C.gl2_1_glTexCoord2s(gl.funcs, C.GLshort(s), C.GLshort(t))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2iv.xml
+func (gl *GL) TexCoord2iv(v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glTexCoord2iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2i.xml
+func (gl *GL) TexCoord2i(s, t int32) {
+ C.gl2_1_glTexCoord2i(gl.funcs, C.GLint(s), C.GLint(t))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2fv.xml
+func (gl *GL) TexCoord2fv(v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glTexCoord2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2f.xml
+func (gl *GL) TexCoord2f(s, t float32) {
+ C.gl2_1_glTexCoord2f(gl.funcs, C.GLfloat(s), C.GLfloat(t))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2dv.xml
+func (gl *GL) TexCoord2dv(v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glTexCoord2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord2d.xml
+func (gl *GL) TexCoord2d(s, t float64) {
+ C.gl2_1_glTexCoord2d(gl.funcs, C.GLdouble(s), C.GLdouble(t))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1sv.xml
+func (gl *GL) TexCoord1sv(v []int16) {
+ C.gl2_1_glTexCoord1sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1s.xml
+func (gl *GL) TexCoord1s(s int16) {
+ C.gl2_1_glTexCoord1s(gl.funcs, C.GLshort(s))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1iv.xml
+func (gl *GL) TexCoord1iv(v []int32) {
+ C.gl2_1_glTexCoord1iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1i.xml
+func (gl *GL) TexCoord1i(s int32) {
+ C.gl2_1_glTexCoord1i(gl.funcs, C.GLint(s))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1fv.xml
+func (gl *GL) TexCoord1fv(v []float32) {
+ C.gl2_1_glTexCoord1fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1f.xml
+func (gl *GL) TexCoord1f(s float32) {
+ C.gl2_1_glTexCoord1f(gl.funcs, C.GLfloat(s))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1dv.xml
+func (gl *GL) TexCoord1dv(v []float64) {
+ C.gl2_1_glTexCoord1dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoord1d.xml
+func (gl *GL) TexCoord1d(s float64) {
+ C.gl2_1_glTexCoord1d(gl.funcs, C.GLdouble(s))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRectsv.xml
+func (gl *GL) Rectsv(v1, v2 []int16) {
+ C.gl2_1_glRectsv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v1[0])), (*C.GLshort)(unsafe.Pointer(&v2[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRects.xml
+func (gl *GL) Rects(x1, y1, x2, y2 int16) {
+ C.gl2_1_glRects(gl.funcs, C.GLshort(x1), C.GLshort(y1), C.GLshort(x2), C.GLshort(y2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRectiv.xml
+func (gl *GL) Rectiv(v1, v2 []int32) {
+ C.gl2_1_glRectiv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v1[0])), (*C.GLint)(unsafe.Pointer(&v2[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRecti.xml
+func (gl *GL) Recti(x1, y1, x2, y2 int32) {
+ C.gl2_1_glRecti(gl.funcs, C.GLint(x1), C.GLint(y1), C.GLint(x2), C.GLint(y2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRectfv.xml
+func (gl *GL) Rectfv(v1, v2 []float32) {
+ C.gl2_1_glRectfv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v1[0])), (*C.GLfloat)(unsafe.Pointer(&v2[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRectf.xml
+func (gl *GL) Rectf(x1, y1, x2, y2 float32) {
+ C.gl2_1_glRectf(gl.funcs, C.GLfloat(x1), C.GLfloat(y1), C.GLfloat(x2), C.GLfloat(y2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRectdv.xml
+func (gl *GL) Rectdv(v1, v2 []float64) {
+ C.gl2_1_glRectdv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v1[0])), (*C.GLdouble)(unsafe.Pointer(&v2[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRectd.xml
+func (gl *GL) Rectd(x1, y1, x2, y2 float64) {
+ C.gl2_1_glRectd(gl.funcs, C.GLdouble(x1), C.GLdouble(y1), C.GLdouble(x2), C.GLdouble(y2))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4sv.xml
+func (gl *GL) RasterPos4sv(v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glRasterPos4sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4s.xml
+func (gl *GL) RasterPos4s(x, y, z, w int16) {
+ C.gl2_1_glRasterPos4s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z), C.GLshort(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4iv.xml
+func (gl *GL) RasterPos4iv(v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glRasterPos4iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4i.xml
+func (gl *GL) RasterPos4i(x, y, z, w int) {
+ C.gl2_1_glRasterPos4i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z), C.GLint(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4fv.xml
+func (gl *GL) RasterPos4fv(v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glRasterPos4fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4f.xml
+func (gl *GL) RasterPos4f(x, y, z, w float32) {
+ C.gl2_1_glRasterPos4f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z), C.GLfloat(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4dv.xml
+func (gl *GL) RasterPos4dv(v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glRasterPos4dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos4d.xml
+func (gl *GL) RasterPos4d(x, y, z, w float64) {
+ C.gl2_1_glRasterPos4d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z), C.GLdouble(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3sv.xml
+func (gl *GL) RasterPos3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glRasterPos3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3s.xml
+func (gl *GL) RasterPos3s(x, y, z int16) {
+ C.gl2_1_glRasterPos3s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3iv.xml
+func (gl *GL) RasterPos3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glRasterPos3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3i.xml
+func (gl *GL) RasterPos3i(x, y, z int) {
+ C.gl2_1_glRasterPos3i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3fv.xml
+func (gl *GL) RasterPos3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glRasterPos3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3f.xml
+func (gl *GL) RasterPos3f(x, y, z float32) {
+ C.gl2_1_glRasterPos3f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3dv.xml
+func (gl *GL) RasterPos3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glRasterPos3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos3d.xml
+func (gl *GL) RasterPos3d(x, y, z float64) {
+ C.gl2_1_glRasterPos3d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2sv.xml
+func (gl *GL) RasterPos2sv(v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glRasterPos2sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2s.xml
+func (gl *GL) RasterPos2s(x, y int16) {
+ C.gl2_1_glRasterPos2s(gl.funcs, C.GLshort(x), C.GLshort(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2iv.xml
+func (gl *GL) RasterPos2iv(v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glRasterPos2iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2i.xml
+func (gl *GL) RasterPos2i(x, y int) {
+ C.gl2_1_glRasterPos2i(gl.funcs, C.GLint(x), C.GLint(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2fv.xml
+func (gl *GL) RasterPos2fv(v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glRasterPos2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2f.xml
+func (gl *GL) RasterPos2f(x, y float32) {
+ C.gl2_1_glRasterPos2f(gl.funcs, C.GLfloat(x), C.GLfloat(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2dv.xml
+func (gl *GL) RasterPos2dv(v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glRasterPos2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRasterPos2d.xml
+func (gl *GL) RasterPos2d(x, y float64) {
+ C.gl2_1_glRasterPos2d(gl.funcs, C.GLdouble(x), C.GLdouble(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3sv.xml
+func (gl *GL) Normal3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glNormal3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3s.xml
+func (gl *GL) Normal3s(nx, ny, nz int16) {
+ C.gl2_1_glNormal3s(gl.funcs, C.GLshort(nx), C.GLshort(ny), C.GLshort(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3iv.xml
+func (gl *GL) Normal3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glNormal3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3i.xml
+func (gl *GL) Normal3i(nx, ny, nz int32) {
+ C.gl2_1_glNormal3i(gl.funcs, C.GLint(nx), C.GLint(ny), C.GLint(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3fv.xml
+func (gl *GL) Normal3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glNormal3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3f.xml
+func (gl *GL) Normal3f(nx, ny, nz float32) {
+ C.gl2_1_glNormal3f(gl.funcs, C.GLfloat(nx), C.GLfloat(ny), C.GLfloat(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3dv.xml
+func (gl *GL) Normal3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glNormal3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3d.xml
+func (gl *GL) Normal3d(nx, ny, nz float64) {
+ C.gl2_1_glNormal3d(gl.funcs, C.GLdouble(nx), C.GLdouble(ny), C.GLdouble(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3bv.xml
+func (gl *GL) Normal3bv(v []byte) {
+ C.gl2_1_glNormal3bv(gl.funcs, (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormal3b.xml
+func (gl *GL) Normal3b(nx, ny, nz byte) {
+ C.gl2_1_glNormal3b(gl.funcs, C.GLbyte(nx), C.GLbyte(ny), C.GLbyte(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexsv.xml
+func (gl *GL) Indexsv(c []int16) {
+ C.gl2_1_glIndexsv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexs.xml
+func (gl *GL) Indexs(c int16) {
+ C.gl2_1_glIndexs(gl.funcs, C.GLshort(c))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexiv.xml
+func (gl *GL) Indexiv(c []int32) {
+ C.gl2_1_glIndexiv(gl.funcs, (*C.GLint)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexi.xml
+func (gl *GL) Indexi(c int32) {
+ C.gl2_1_glIndexi(gl.funcs, C.GLint(c))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexfv.xml
+func (gl *GL) Indexfv(c []float32) {
+ C.gl2_1_glIndexfv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexf.xml
+func (gl *GL) Indexf(c float32) {
+ C.gl2_1_glIndexf(gl.funcs, C.GLfloat(c))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexdv.xml
+func (gl *GL) Indexdv(c []float64) {
+ C.gl2_1_glIndexdv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexd.xml
+func (gl *GL) Indexd(c float64) {
+ C.gl2_1_glIndexd(gl.funcs, C.GLdouble(c))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEnd.xml
+func (gl *GL) End() {
+ C.gl2_1_glEnd(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEdgeFlagv.xml
+func (gl *GL) EdgeFlagv(flag []bool) {
+ C.gl2_1_glEdgeFlagv(gl.funcs, (*C.GLboolean)(unsafe.Pointer(&flag[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEdgeFlag.xml
+func (gl *GL) EdgeFlag(flag bool) {
+ C.gl2_1_glEdgeFlag(gl.funcs, *(*C.GLboolean)(unsafe.Pointer(&flag)))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4usv.xml
+func (gl *GL) Color4usv(v []uint16) {
+ C.gl2_1_glColor4usv(gl.funcs, (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4us.xml
+func (gl *GL) Color4us(red, green, blue, alpha uint16) {
+ C.gl2_1_glColor4us(gl.funcs, C.GLushort(red), C.GLushort(green), C.GLushort(blue), C.GLushort(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4uiv.xml
+func (gl *GL) Color4uiv(v []uint32) {
+ C.gl2_1_glColor4uiv(gl.funcs, (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4ui.xml
+func (gl *GL) Color4ui(red, green, blue, alpha uint32) {
+ C.gl2_1_glColor4ui(gl.funcs, C.GLuint(red), C.GLuint(green), C.GLuint(blue), C.GLuint(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4ubv.xml
+func (gl *GL) Color4ubv(v []uint8) {
+ C.gl2_1_glColor4ubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4ub.xml
+func (gl *GL) Color4ub(red, green, blue, alpha uint8) {
+ C.gl2_1_glColor4ub(gl.funcs, C.GLubyte(red), C.GLubyte(green), C.GLubyte(blue), C.GLubyte(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4sv.xml
+func (gl *GL) Color4sv(v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glColor4sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4s.xml
+func (gl *GL) Color4s(red, green, blue, alpha int16) {
+ C.gl2_1_glColor4s(gl.funcs, C.GLshort(red), C.GLshort(green), C.GLshort(blue), C.GLshort(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4iv.xml
+func (gl *GL) Color4iv(v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glColor4iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4i.xml
+func (gl *GL) Color4i(red, green, blue, alpha int32) {
+ C.gl2_1_glColor4i(gl.funcs, C.GLint(red), C.GLint(green), C.GLint(blue), C.GLint(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4fv.xml
+func (gl *GL) Color4fv(v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glColor4fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4f.xml
+func (gl *GL) Color4f(red, green, blue, alpha float32) {
+ C.gl2_1_glColor4f(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4dv.xml
+func (gl *GL) Color4dv(v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glColor4dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4d.xml
+func (gl *GL) Color4d(red, green, blue, alpha float64) {
+ C.gl2_1_glColor4d(gl.funcs, C.GLdouble(red), C.GLdouble(green), C.GLdouble(blue), C.GLdouble(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4bv.xml
+func (gl *GL) Color4bv(v []byte) {
+ C.gl2_1_glColor4bv(gl.funcs, (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor4b.xml
+func (gl *GL) Color4b(red, green, blue, alpha byte) {
+ C.gl2_1_glColor4b(gl.funcs, C.GLbyte(red), C.GLbyte(green), C.GLbyte(blue), C.GLbyte(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3usv.xml
+func (gl *GL) Color3usv(v []uint16) {
+ C.gl2_1_glColor3usv(gl.funcs, (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3us.xml
+func (gl *GL) Color3us(red, green, blue uint16) {
+ C.gl2_1_glColor3us(gl.funcs, C.GLushort(red), C.GLushort(green), C.GLushort(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3uiv.xml
+func (gl *GL) Color3uiv(v []uint32) {
+ C.gl2_1_glColor3uiv(gl.funcs, (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3ui.xml
+func (gl *GL) Color3ui(red, green, blue uint32) {
+ C.gl2_1_glColor3ui(gl.funcs, C.GLuint(red), C.GLuint(green), C.GLuint(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3ubv.xml
+func (gl *GL) Color3ubv(v []uint8) {
+ C.gl2_1_glColor3ubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3ub.xml
+func (gl *GL) Color3ub(red, green, blue uint8) {
+ C.gl2_1_glColor3ub(gl.funcs, C.GLubyte(red), C.GLubyte(green), C.GLubyte(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3sv.xml
+func (gl *GL) Color3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glColor3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3s.xml
+func (gl *GL) Color3s(red, green, blue int16) {
+ C.gl2_1_glColor3s(gl.funcs, C.GLshort(red), C.GLshort(green), C.GLshort(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3iv.xml
+func (gl *GL) Color3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glColor3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3i.xml
+func (gl *GL) Color3i(red, green, blue int32) {
+ C.gl2_1_glColor3i(gl.funcs, C.GLint(red), C.GLint(green), C.GLint(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3fv.xml
+func (gl *GL) Color3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glColor3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3f.xml
+func (gl *GL) Color3f(red, green, blue float32) {
+ C.gl2_1_glColor3f(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3dv.xml
+func (gl *GL) Color3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glColor3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3d.xml
+func (gl *GL) Color3d(red, green, blue float64) {
+ C.gl2_1_glColor3d(gl.funcs, C.GLdouble(red), C.GLdouble(green), C.GLdouble(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3bv.xml
+func (gl *GL) Color3bv(v []byte) {
+ C.gl2_1_glColor3bv(gl.funcs, (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColor3b.xml
+func (gl *GL) Color3b(red, green, blue byte) {
+ C.gl2_1_glColor3b(gl.funcs, C.GLbyte(red), C.GLbyte(green), C.GLbyte(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBitmap.xml
+func (gl *GL) Bitmap(width, height int, xorig, yorig, xmove, ymove float32, bitmap []uint8) {
+ C.gl2_1_glBitmap(gl.funcs, C.GLsizei(width), C.GLsizei(height), C.GLfloat(xorig), C.GLfloat(yorig), C.GLfloat(xmove), C.GLfloat(ymove), (*C.GLubyte)(unsafe.Pointer(&bitmap[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBegin.xml
+func (gl *GL) Begin(mode glbase.Enum) {
+ C.gl2_1_glBegin(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glListBase.xml
+func (gl *GL) ListBase(base uint32) {
+ C.gl2_1_glListBase(gl.funcs, C.GLuint(base))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGenLists.xml
+func (gl *GL) GenLists(range_ int32) uint32 {
+ glresult := C.gl2_1_glGenLists(gl.funcs, C.GLsizei(range_))
+ return uint32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDeleteLists.xml
+func (gl *GL) DeleteLists(list uint32, range_ int32) {
+ C.gl2_1_glDeleteLists(gl.funcs, C.GLuint(list), C.GLsizei(range_))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCallLists.xml
+func (gl *GL) CallLists(n int, gltype glbase.Enum, lists interface{}) {
+ var lists_ptr unsafe.Pointer
+ var lists_v = reflect.ValueOf(lists)
+ if lists != nil && lists_v.Kind() != reflect.Slice {
+ panic("parameter lists must be a slice")
+ }
+ if lists != nil {
+ lists_ptr = unsafe.Pointer(lists_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_1_glCallLists(gl.funcs, C.GLsizei(n), C.GLenum(gltype), lists_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCallList.xml
+func (gl *GL) CallList(list uint32) {
+ C.gl2_1_glCallList(gl.funcs, C.GLuint(list))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEndList.xml
+func (gl *GL) EndList() {
+ C.gl2_1_glEndList(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNewList.xml
+func (gl *GL) NewList(list uint32, mode glbase.Enum) {
+ C.gl2_1_glNewList(gl.funcs, C.GLuint(list), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPushClientAttrib.xml
+func (gl *GL) PushClientAttrib(mask glbase.Bitfield) {
+ C.gl2_1_glPushClientAttrib(gl.funcs, C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPopClientAttrib.xml
+func (gl *GL) PopClientAttrib() {
+ C.gl2_1_glPopClientAttrib(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPrioritizeTextures.xml
+func (gl *GL) PrioritizeTextures(n int, textures []glbase.Texture, priorities []float32) {
+ C.gl2_1_glPrioritizeTextures(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])), (*C.GLfloat)(unsafe.Pointer(&priorities[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glAreTexturesResident.xml
+func (gl *GL) AreTexturesResident(n int, textures []glbase.Texture, residences []bool) bool {
+ glresult := C.gl2_1_glAreTexturesResident(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])), (*C.GLboolean)(unsafe.Pointer(&residences[0])))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexPointer.xml
+func (gl *GL) VertexPointer(size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_1_glVertexPointer(gl.funcs, C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexCoordPointer.xml
+func (gl *GL) TexCoordPointer(size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_1_glTexCoordPointer(gl.funcs, C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glNormalPointer.xml
+func (gl *GL) NormalPointer(gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_1_glNormalPointer(gl.funcs, C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glInterleavedArrays.xml
+func (gl *GL) InterleavedArrays(format glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_1_glInterleavedArrays(gl.funcs, C.GLenum(format), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIndexPointer.xml
+func (gl *GL) IndexPointer(gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_1_glIndexPointer(gl.funcs, C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEnableClientState.xml
+func (gl *GL) EnableClientState(array glbase.Enum) {
+ C.gl2_1_glEnableClientState(gl.funcs, C.GLenum(array))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEdgeFlagPointer.xml
+func (gl *GL) EdgeFlagPointer(stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_1_glEdgeFlagPointer(gl.funcs, C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDisableClientState.xml
+func (gl *GL) DisableClientState(array glbase.Enum) {
+ C.gl2_1_glDisableClientState(gl.funcs, C.GLenum(array))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColorPointer.xml
+func (gl *GL) ColorPointer(size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_1_glColorPointer(gl.funcs, C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glArrayElement.xml
+func (gl *GL) ArrayElement(i int32) {
+ C.gl2_1_glArrayElement(gl.funcs, C.GLint(i))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glResetMinmax.xml
+func (gl *GL) ResetMinmax(target glbase.Enum) {
+ C.gl2_1_glResetMinmax(gl.funcs, C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glResetHistogram.xml
+func (gl *GL) ResetHistogram(target glbase.Enum) {
+ C.gl2_1_glResetHistogram(gl.funcs, C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMinmax.xml
+func (gl *GL) Minmax(target, internalFormat glbase.Enum, sink bool) {
+ C.gl2_1_glMinmax(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), *(*C.GLboolean)(unsafe.Pointer(&sink)))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glHistogram.xml
+func (gl *GL) Histogram(target glbase.Enum, width int, internalFormat glbase.Enum, sink bool) {
+ C.gl2_1_glHistogram(gl.funcs, C.GLenum(target), C.GLsizei(width), C.GLenum(internalFormat), *(*C.GLboolean)(unsafe.Pointer(&sink)))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetMinmaxParameteriv.xml
+func (gl *GL) GetMinmaxParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl2_1_glGetMinmaxParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetMinmaxParameterfv.xml
+func (gl *GL) GetMinmaxParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl2_1_glGetMinmaxParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetMinmax.xml
+func (gl *GL) GetMinmax(target glbase.Enum, reset bool, format, gltype glbase.Enum, values interface{}) {
+ var values_ptr unsafe.Pointer
+ var values_v = reflect.ValueOf(values)
+ if values != nil && values_v.Kind() != reflect.Slice {
+ panic("parameter values must be a slice")
+ }
+ if values != nil {
+ values_ptr = unsafe.Pointer(values_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_1_glGetMinmax(gl.funcs, C.GLenum(target), *(*C.GLboolean)(unsafe.Pointer(&reset)), C.GLenum(format), C.GLenum(gltype), values_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetHistogramParameteriv.xml
+func (gl *GL) GetHistogramParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl2_1_glGetHistogramParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetHistogramParameterfv.xml
+func (gl *GL) GetHistogramParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl2_1_glGetHistogramParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetHistogram.xml
+func (gl *GL) GetHistogram(target glbase.Enum, reset bool, format, gltype glbase.Enum, values interface{}) {
+ var values_ptr unsafe.Pointer
+ var values_v = reflect.ValueOf(values)
+ if values != nil && values_v.Kind() != reflect.Slice {
+ panic("parameter values must be a slice")
+ }
+ if values != nil {
+ values_ptr = unsafe.Pointer(values_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_1_glGetHistogram(gl.funcs, C.GLenum(target), *(*C.GLboolean)(unsafe.Pointer(&reset)), C.GLenum(format), C.GLenum(gltype), values_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSeparableFilter2D.xml
+func (gl *GL) SeparableFilter2D(target, internalFormat glbase.Enum, width, height int, format, gltype glbase.Enum, row, column interface{}) {
+ var row_ptr unsafe.Pointer
+ var row_v = reflect.ValueOf(row)
+ if row != nil && row_v.Kind() != reflect.Slice {
+ panic("parameter row must be a slice")
+ }
+ if row != nil {
+ row_ptr = unsafe.Pointer(row_v.Index(0).Addr().Pointer())
+ }
+ var column_ptr unsafe.Pointer
+ var column_v = reflect.ValueOf(column)
+ if column != nil && column_v.Kind() != reflect.Slice {
+ panic("parameter column must be a slice")
+ }
+ if column != nil {
+ column_ptr = unsafe.Pointer(column_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_1_glSeparableFilter2D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), row_ptr, column_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetSeparableFilter.xml
+func (gl *GL) GetSeparableFilter(target, format, gltype glbase.Enum, row, column, span interface{}) {
+ var row_ptr unsafe.Pointer
+ var row_v = reflect.ValueOf(row)
+ if row != nil && row_v.Kind() != reflect.Slice {
+ panic("parameter row must be a slice")
+ }
+ if row != nil {
+ row_ptr = unsafe.Pointer(row_v.Index(0).Addr().Pointer())
+ }
+ var column_ptr unsafe.Pointer
+ var column_v = reflect.ValueOf(column)
+ if column != nil && column_v.Kind() != reflect.Slice {
+ panic("parameter column must be a slice")
+ }
+ if column != nil {
+ column_ptr = unsafe.Pointer(column_v.Index(0).Addr().Pointer())
+ }
+ var span_ptr unsafe.Pointer
+ var span_v = reflect.ValueOf(span)
+ if span != nil && span_v.Kind() != reflect.Slice {
+ panic("parameter span must be a slice")
+ }
+ if span != nil {
+ span_ptr = unsafe.Pointer(span_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_1_glGetSeparableFilter(gl.funcs, C.GLenum(target), C.GLenum(format), C.GLenum(gltype), row_ptr, column_ptr, span_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetConvolutionParameteriv.xml
+func (gl *GL) GetConvolutionParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl2_1_glGetConvolutionParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetConvolutionParameterfv.xml
+func (gl *GL) GetConvolutionParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl2_1_glGetConvolutionParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetConvolutionFilter.xml
+func (gl *GL) GetConvolutionFilter(target, format, gltype glbase.Enum, image interface{}) {
+ var image_ptr unsafe.Pointer
+ var image_v = reflect.ValueOf(image)
+ if image != nil && image_v.Kind() != reflect.Slice {
+ panic("parameter image must be a slice")
+ }
+ if image != nil {
+ image_ptr = unsafe.Pointer(image_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_1_glGetConvolutionFilter(gl.funcs, C.GLenum(target), C.GLenum(format), C.GLenum(gltype), image_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyConvolutionFilter2D.xml
+func (gl *GL) CopyConvolutionFilter2D(target, internalFormat glbase.Enum, x, y, width, height int) {
+ C.gl2_1_glCopyConvolutionFilter2D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyConvolutionFilter1D.xml
+func (gl *GL) CopyConvolutionFilter1D(target, internalFormat glbase.Enum, x, y, width int) {
+ C.gl2_1_glCopyConvolutionFilter1D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glConvolutionParameteriv.xml
+func (gl *GL) ConvolutionParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl2_1_glConvolutionParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glConvolutionParameteri.xml
+func (gl *GL) ConvolutionParameteri(target, pname glbase.Enum, params int32) {
+ C.gl2_1_glConvolutionParameteri(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLint(params))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glConvolutionParameterfv.xml
+func (gl *GL) ConvolutionParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl2_1_glConvolutionParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glConvolutionParameterf.xml
+func (gl *GL) ConvolutionParameterf(target, pname glbase.Enum, params float32) {
+ C.gl2_1_glConvolutionParameterf(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLfloat(params))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glConvolutionFilter2D.xml
+func (gl *GL) ConvolutionFilter2D(target, internalFormat glbase.Enum, width, height int, format, gltype glbase.Enum, image interface{}) {
+ var image_ptr unsafe.Pointer
+ var image_v = reflect.ValueOf(image)
+ if image != nil && image_v.Kind() != reflect.Slice {
+ panic("parameter image must be a slice")
+ }
+ if image != nil {
+ image_ptr = unsafe.Pointer(image_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_1_glConvolutionFilter2D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), image_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glConvolutionFilter1D.xml
+func (gl *GL) ConvolutionFilter1D(target, internalFormat glbase.Enum, width int, format, gltype glbase.Enum, image interface{}) {
+ var image_ptr unsafe.Pointer
+ var image_v = reflect.ValueOf(image)
+ if image != nil && image_v.Kind() != reflect.Slice {
+ panic("parameter image must be a slice")
+ }
+ if image != nil {
+ image_ptr = unsafe.Pointer(image_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_1_glConvolutionFilter1D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLenum(format), C.GLenum(gltype), image_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyColorSubTable.xml
+func (gl *GL) CopyColorSubTable(target glbase.Enum, start int32, x, y, width int) {
+ C.gl2_1_glCopyColorSubTable(gl.funcs, C.GLenum(target), C.GLsizei(start), C.GLint(x), C.GLint(y), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColorSubTable.xml
+func (gl *GL) ColorSubTable(target glbase.Enum, start int32, count int, format, gltype glbase.Enum, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_1_glColorSubTable(gl.funcs, C.GLenum(target), C.GLsizei(start), C.GLsizei(count), C.GLenum(format), C.GLenum(gltype), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetColorTableParameteriv.xml
+func (gl *GL) GetColorTableParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl2_1_glGetColorTableParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetColorTableParameterfv.xml
+func (gl *GL) GetColorTableParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl2_1_glGetColorTableParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetColorTable.xml
+func (gl *GL) GetColorTable(target, format, gltype glbase.Enum, table interface{}) {
+ var table_ptr unsafe.Pointer
+ var table_v = reflect.ValueOf(table)
+ if table != nil && table_v.Kind() != reflect.Slice {
+ panic("parameter table must be a slice")
+ }
+ if table != nil {
+ table_ptr = unsafe.Pointer(table_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_1_glGetColorTable(gl.funcs, C.GLenum(target), C.GLenum(format), C.GLenum(gltype), table_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyColorTable.xml
+func (gl *GL) CopyColorTable(target, internalFormat glbase.Enum, x, y, width int) {
+ C.gl2_1_glCopyColorTable(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColorTableParameteriv.xml
+func (gl *GL) ColorTableParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl2_1_glColorTableParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColorTableParameterfv.xml
+func (gl *GL) ColorTableParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl2_1_glColorTableParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColorTable.xml
+func (gl *GL) ColorTable(target, internalFormat glbase.Enum, width int, format, gltype glbase.Enum, table interface{}) {
+ var table_ptr unsafe.Pointer
+ var table_v = reflect.ValueOf(table)
+ if table != nil && table_v.Kind() != reflect.Slice {
+ panic("parameter table must be a slice")
+ }
+ if table != nil {
+ table_ptr = unsafe.Pointer(table_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_1_glColorTable(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLenum(format), C.GLenum(gltype), table_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultTransposeMatrixd.xml
+func (gl *GL) MultTransposeMatrixd(m []float64) {
+ C.gl2_1_glMultTransposeMatrixd(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultTransposeMatrixf.xml
+func (gl *GL) MultTransposeMatrixf(m []float32) {
+ C.gl2_1_glMultTransposeMatrixf(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLoadTransposeMatrixd.xml
+func (gl *GL) LoadTransposeMatrixd(m []float64) {
+ C.gl2_1_glLoadTransposeMatrixd(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLoadTransposeMatrixf.xml
+func (gl *GL) LoadTransposeMatrixf(m []float32) {
+ C.gl2_1_glLoadTransposeMatrixf(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord4sv.xml
+func (gl *GL) MultiTexCoord4sv(target glbase.Enum, v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glMultiTexCoord4sv(gl.funcs, C.GLenum(target), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord4s.xml
+func (gl *GL) MultiTexCoord4s(target glbase.Enum, s, t, r, q int16) {
+ C.gl2_1_glMultiTexCoord4s(gl.funcs, C.GLenum(target), C.GLshort(s), C.GLshort(t), C.GLshort(r), C.GLshort(q))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord4iv.xml
+func (gl *GL) MultiTexCoord4iv(target glbase.Enum, v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glMultiTexCoord4iv(gl.funcs, C.GLenum(target), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord4i.xml
+func (gl *GL) MultiTexCoord4i(target glbase.Enum, s, t, r, q int32) {
+ C.gl2_1_glMultiTexCoord4i(gl.funcs, C.GLenum(target), C.GLint(s), C.GLint(t), C.GLint(r), C.GLint(q))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord4fv.xml
+func (gl *GL) MultiTexCoord4fv(target glbase.Enum, v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glMultiTexCoord4fv(gl.funcs, C.GLenum(target), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord4f.xml
+func (gl *GL) MultiTexCoord4f(target glbase.Enum, s, t, r, q float32) {
+ C.gl2_1_glMultiTexCoord4f(gl.funcs, C.GLenum(target), C.GLfloat(s), C.GLfloat(t), C.GLfloat(r), C.GLfloat(q))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord4dv.xml
+func (gl *GL) MultiTexCoord4dv(target glbase.Enum, v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glMultiTexCoord4dv(gl.funcs, C.GLenum(target), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord4d.xml
+func (gl *GL) MultiTexCoord4d(target glbase.Enum, s, t, r, q float64) {
+ C.gl2_1_glMultiTexCoord4d(gl.funcs, C.GLenum(target), C.GLdouble(s), C.GLdouble(t), C.GLdouble(r), C.GLdouble(q))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord3sv.xml
+func (gl *GL) MultiTexCoord3sv(target glbase.Enum, v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glMultiTexCoord3sv(gl.funcs, C.GLenum(target), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord3s.xml
+func (gl *GL) MultiTexCoord3s(target glbase.Enum, s, t, r int16) {
+ C.gl2_1_glMultiTexCoord3s(gl.funcs, C.GLenum(target), C.GLshort(s), C.GLshort(t), C.GLshort(r))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord3iv.xml
+func (gl *GL) MultiTexCoord3iv(target glbase.Enum, v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glMultiTexCoord3iv(gl.funcs, C.GLenum(target), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord3i.xml
+func (gl *GL) MultiTexCoord3i(target glbase.Enum, s, t, r int32) {
+ C.gl2_1_glMultiTexCoord3i(gl.funcs, C.GLenum(target), C.GLint(s), C.GLint(t), C.GLint(r))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord3fv.xml
+func (gl *GL) MultiTexCoord3fv(target glbase.Enum, v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glMultiTexCoord3fv(gl.funcs, C.GLenum(target), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord3f.xml
+func (gl *GL) MultiTexCoord3f(target glbase.Enum, s, t, r float32) {
+ C.gl2_1_glMultiTexCoord3f(gl.funcs, C.GLenum(target), C.GLfloat(s), C.GLfloat(t), C.GLfloat(r))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord3dv.xml
+func (gl *GL) MultiTexCoord3dv(target glbase.Enum, v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glMultiTexCoord3dv(gl.funcs, C.GLenum(target), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord3d.xml
+func (gl *GL) MultiTexCoord3d(target glbase.Enum, s, t, r float64) {
+ C.gl2_1_glMultiTexCoord3d(gl.funcs, C.GLenum(target), C.GLdouble(s), C.GLdouble(t), C.GLdouble(r))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord2sv.xml
+func (gl *GL) MultiTexCoord2sv(target glbase.Enum, v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glMultiTexCoord2sv(gl.funcs, C.GLenum(target), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord2s.xml
+func (gl *GL) MultiTexCoord2s(target glbase.Enum, s, t int16) {
+ C.gl2_1_glMultiTexCoord2s(gl.funcs, C.GLenum(target), C.GLshort(s), C.GLshort(t))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord2iv.xml
+func (gl *GL) MultiTexCoord2iv(target glbase.Enum, v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glMultiTexCoord2iv(gl.funcs, C.GLenum(target), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord2i.xml
+func (gl *GL) MultiTexCoord2i(target glbase.Enum, s, t int32) {
+ C.gl2_1_glMultiTexCoord2i(gl.funcs, C.GLenum(target), C.GLint(s), C.GLint(t))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord2fv.xml
+func (gl *GL) MultiTexCoord2fv(target glbase.Enum, v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glMultiTexCoord2fv(gl.funcs, C.GLenum(target), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord2f.xml
+func (gl *GL) MultiTexCoord2f(target glbase.Enum, s, t float32) {
+ C.gl2_1_glMultiTexCoord2f(gl.funcs, C.GLenum(target), C.GLfloat(s), C.GLfloat(t))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord2dv.xml
+func (gl *GL) MultiTexCoord2dv(target glbase.Enum, v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glMultiTexCoord2dv(gl.funcs, C.GLenum(target), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord2d.xml
+func (gl *GL) MultiTexCoord2d(target glbase.Enum, s, t float64) {
+ C.gl2_1_glMultiTexCoord2d(gl.funcs, C.GLenum(target), C.GLdouble(s), C.GLdouble(t))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord1sv.xml
+func (gl *GL) MultiTexCoord1sv(target glbase.Enum, v []int16) {
+ C.gl2_1_glMultiTexCoord1sv(gl.funcs, C.GLenum(target), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord1s.xml
+func (gl *GL) MultiTexCoord1s(target glbase.Enum, s int16) {
+ C.gl2_1_glMultiTexCoord1s(gl.funcs, C.GLenum(target), C.GLshort(s))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord1iv.xml
+func (gl *GL) MultiTexCoord1iv(target glbase.Enum, v []int32) {
+ C.gl2_1_glMultiTexCoord1iv(gl.funcs, C.GLenum(target), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord1i.xml
+func (gl *GL) MultiTexCoord1i(target glbase.Enum, s int32) {
+ C.gl2_1_glMultiTexCoord1i(gl.funcs, C.GLenum(target), C.GLint(s))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord1fv.xml
+func (gl *GL) MultiTexCoord1fv(target glbase.Enum, v []float32) {
+ C.gl2_1_glMultiTexCoord1fv(gl.funcs, C.GLenum(target), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord1f.xml
+func (gl *GL) MultiTexCoord1f(target glbase.Enum, s float32) {
+ C.gl2_1_glMultiTexCoord1f(gl.funcs, C.GLenum(target), C.GLfloat(s))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord1dv.xml
+func (gl *GL) MultiTexCoord1dv(target glbase.Enum, v []float64) {
+ C.gl2_1_glMultiTexCoord1dv(gl.funcs, C.GLenum(target), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glMultiTexCoord1d.xml
+func (gl *GL) MultiTexCoord1d(target glbase.Enum, s float64) {
+ C.gl2_1_glMultiTexCoord1d(gl.funcs, C.GLenum(target), C.GLdouble(s))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClientActiveTexture.xml
+func (gl *GL) ClientActiveTexture(texture glbase.Enum) {
+ C.gl2_1_glClientActiveTexture(gl.funcs, C.GLenum(texture))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos3sv.xml
+func (gl *GL) WindowPos3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glWindowPos3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos3s.xml
+func (gl *GL) WindowPos3s(x, y, z int16) {
+ C.gl2_1_glWindowPos3s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos3iv.xml
+func (gl *GL) WindowPos3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glWindowPos3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos3i.xml
+func (gl *GL) WindowPos3i(x, y, z int) {
+ C.gl2_1_glWindowPos3i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos3fv.xml
+func (gl *GL) WindowPos3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glWindowPos3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos3f.xml
+func (gl *GL) WindowPos3f(x, y, z float32) {
+ C.gl2_1_glWindowPos3f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos3dv.xml
+func (gl *GL) WindowPos3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glWindowPos3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos3d.xml
+func (gl *GL) WindowPos3d(x, y, z float64) {
+ C.gl2_1_glWindowPos3d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos2sv.xml
+func (gl *GL) WindowPos2sv(v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glWindowPos2sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos2s.xml
+func (gl *GL) WindowPos2s(x, y int16) {
+ C.gl2_1_glWindowPos2s(gl.funcs, C.GLshort(x), C.GLshort(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos2iv.xml
+func (gl *GL) WindowPos2iv(v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glWindowPos2iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos2i.xml
+func (gl *GL) WindowPos2i(x, y int) {
+ C.gl2_1_glWindowPos2i(gl.funcs, C.GLint(x), C.GLint(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos2fv.xml
+func (gl *GL) WindowPos2fv(v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glWindowPos2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos2f.xml
+func (gl *GL) WindowPos2f(x, y float32) {
+ C.gl2_1_glWindowPos2f(gl.funcs, C.GLfloat(x), C.GLfloat(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos2dv.xml
+func (gl *GL) WindowPos2dv(v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glWindowPos2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glWindowPos2d.xml
+func (gl *GL) WindowPos2d(x, y float64) {
+ C.gl2_1_glWindowPos2d(gl.funcs, C.GLdouble(x), C.GLdouble(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColorPointer.xml
+func (gl *GL) SecondaryColorPointer(size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_1_glSecondaryColorPointer(gl.funcs, C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3usv.xml
+func (gl *GL) SecondaryColor3usv(v []uint16) {
+ C.gl2_1_glSecondaryColor3usv(gl.funcs, (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3us.xml
+func (gl *GL) SecondaryColor3us(red, green, blue uint16) {
+ C.gl2_1_glSecondaryColor3us(gl.funcs, C.GLushort(red), C.GLushort(green), C.GLushort(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3uiv.xml
+func (gl *GL) SecondaryColor3uiv(v []uint32) {
+ C.gl2_1_glSecondaryColor3uiv(gl.funcs, (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3ui.xml
+func (gl *GL) SecondaryColor3ui(red, green, blue uint32) {
+ C.gl2_1_glSecondaryColor3ui(gl.funcs, C.GLuint(red), C.GLuint(green), C.GLuint(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3ubv.xml
+func (gl *GL) SecondaryColor3ubv(v []uint8) {
+ C.gl2_1_glSecondaryColor3ubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3ub.xml
+func (gl *GL) SecondaryColor3ub(red, green, blue uint8) {
+ C.gl2_1_glSecondaryColor3ub(gl.funcs, C.GLubyte(red), C.GLubyte(green), C.GLubyte(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3sv.xml
+func (gl *GL) SecondaryColor3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glSecondaryColor3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3s.xml
+func (gl *GL) SecondaryColor3s(red, green, blue int16) {
+ C.gl2_1_glSecondaryColor3s(gl.funcs, C.GLshort(red), C.GLshort(green), C.GLshort(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3iv.xml
+func (gl *GL) SecondaryColor3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glSecondaryColor3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3i.xml
+func (gl *GL) SecondaryColor3i(red, green, blue int32) {
+ C.gl2_1_glSecondaryColor3i(gl.funcs, C.GLint(red), C.GLint(green), C.GLint(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3fv.xml
+func (gl *GL) SecondaryColor3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glSecondaryColor3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3f.xml
+func (gl *GL) SecondaryColor3f(red, green, blue float32) {
+ C.gl2_1_glSecondaryColor3f(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3dv.xml
+func (gl *GL) SecondaryColor3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glSecondaryColor3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3d.xml
+func (gl *GL) SecondaryColor3d(red, green, blue float64) {
+ C.gl2_1_glSecondaryColor3d(gl.funcs, C.GLdouble(red), C.GLdouble(green), C.GLdouble(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3bv.xml
+func (gl *GL) SecondaryColor3bv(v []byte) {
+ C.gl2_1_glSecondaryColor3bv(gl.funcs, (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSecondaryColor3b.xml
+func (gl *GL) SecondaryColor3b(red, green, blue byte) {
+ C.gl2_1_glSecondaryColor3b(gl.funcs, C.GLbyte(red), C.GLbyte(green), C.GLbyte(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFogCoordPointer.xml
+func (gl *GL) FogCoordPointer(gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl2_1_glFogCoordPointer(gl.funcs, C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFogCoorddv.xml
+func (gl *GL) FogCoorddv(coord []float64) {
+ C.gl2_1_glFogCoorddv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&coord[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFogCoordd.xml
+func (gl *GL) FogCoordd(coord float64) {
+ C.gl2_1_glFogCoordd(gl.funcs, C.GLdouble(coord))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFogCoordfv.xml
+func (gl *GL) FogCoordfv(coord []float32) {
+ C.gl2_1_glFogCoordfv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&coord[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFogCoordf.xml
+func (gl *GL) FogCoordf(coord float32) {
+ C.gl2_1_glFogCoordf(gl.funcs, C.GLfloat(coord))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib4usv.xml
+func (gl *GL) VertexAttrib4usv(index glbase.Attrib, v []uint16) {
+ C.gl2_1_glVertexAttrib4usv(gl.funcs, C.GLuint(index), (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib4uiv.xml
+func (gl *GL) VertexAttrib4uiv(index glbase.Attrib, v []uint32) {
+ C.gl2_1_glVertexAttrib4uiv(gl.funcs, C.GLuint(index), (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib4ubv.xml
+func (gl *GL) VertexAttrib4ubv(index glbase.Attrib, v []uint8) {
+ C.gl2_1_glVertexAttrib4ubv(gl.funcs, C.GLuint(index), (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib4sv.xml
+func (gl *GL) VertexAttrib4sv(index glbase.Attrib, v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glVertexAttrib4sv(gl.funcs, C.GLuint(index), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib4s.xml
+func (gl *GL) VertexAttrib4s(index glbase.Attrib, x, y, z, w int16) {
+ C.gl2_1_glVertexAttrib4s(gl.funcs, C.GLuint(index), C.GLshort(x), C.GLshort(y), C.GLshort(z), C.GLshort(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib4iv.xml
+func (gl *GL) VertexAttrib4iv(index glbase.Attrib, v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glVertexAttrib4iv(gl.funcs, C.GLuint(index), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib4fv.xml
+func (gl *GL) VertexAttrib4fv(index glbase.Attrib, v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glVertexAttrib4fv(gl.funcs, C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib4f.xml
+func (gl *GL) VertexAttrib4f(index glbase.Attrib, x, y, z, w float32) {
+ C.gl2_1_glVertexAttrib4f(gl.funcs, C.GLuint(index), C.GLfloat(x), C.GLfloat(y), C.GLfloat(z), C.GLfloat(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib4dv.xml
+func (gl *GL) VertexAttrib4dv(index glbase.Attrib, v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glVertexAttrib4dv(gl.funcs, C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib4d.xml
+func (gl *GL) VertexAttrib4d(index glbase.Attrib, x, y, z, w float64) {
+ C.gl2_1_glVertexAttrib4d(gl.funcs, C.GLuint(index), C.GLdouble(x), C.GLdouble(y), C.GLdouble(z), C.GLdouble(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib4bv.xml
+func (gl *GL) VertexAttrib4bv(index glbase.Attrib, v []byte) {
+ C.gl2_1_glVertexAttrib4bv(gl.funcs, C.GLuint(index), (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib4Nusv.xml
+func (gl *GL) VertexAttrib4Nusv(index glbase.Attrib, v []uint16) {
+ C.gl2_1_glVertexAttrib4Nusv(gl.funcs, C.GLuint(index), (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib4Nuiv.xml
+func (gl *GL) VertexAttrib4Nuiv(index glbase.Attrib, v []uint32) {
+ C.gl2_1_glVertexAttrib4Nuiv(gl.funcs, C.GLuint(index), (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib4Nubv.xml
+func (gl *GL) VertexAttrib4Nubv(index glbase.Attrib, v []uint8) {
+ C.gl2_1_glVertexAttrib4Nubv(gl.funcs, C.GLuint(index), (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib4Nub.xml
+func (gl *GL) VertexAttrib4Nub(index glbase.Attrib, x, y, z, w uint8) {
+ C.gl2_1_glVertexAttrib4Nub(gl.funcs, C.GLuint(index), C.GLubyte(x), C.GLubyte(y), C.GLubyte(z), C.GLubyte(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib4Nsv.xml
+func (gl *GL) VertexAttrib4Nsv(index glbase.Attrib, v []int16) {
+ C.gl2_1_glVertexAttrib4Nsv(gl.funcs, C.GLuint(index), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib4Niv.xml
+func (gl *GL) VertexAttrib4Niv(index glbase.Attrib, v []int32) {
+ C.gl2_1_glVertexAttrib4Niv(gl.funcs, C.GLuint(index), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib4Nbv.xml
+func (gl *GL) VertexAttrib4Nbv(index glbase.Attrib, v []byte) {
+ C.gl2_1_glVertexAttrib4Nbv(gl.funcs, C.GLuint(index), (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib3sv.xml
+func (gl *GL) VertexAttrib3sv(index glbase.Attrib, v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glVertexAttrib3sv(gl.funcs, C.GLuint(index), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib3s.xml
+func (gl *GL) VertexAttrib3s(index glbase.Attrib, x, y, z int16) {
+ C.gl2_1_glVertexAttrib3s(gl.funcs, C.GLuint(index), C.GLshort(x), C.GLshort(y), C.GLshort(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib3fv.xml
+func (gl *GL) VertexAttrib3fv(index glbase.Attrib, v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glVertexAttrib3fv(gl.funcs, C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib3f.xml
+func (gl *GL) VertexAttrib3f(index glbase.Attrib, x, y, z float32) {
+ C.gl2_1_glVertexAttrib3f(gl.funcs, C.GLuint(index), C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib3dv.xml
+func (gl *GL) VertexAttrib3dv(index glbase.Attrib, v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glVertexAttrib3dv(gl.funcs, C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib3d.xml
+func (gl *GL) VertexAttrib3d(index glbase.Attrib, x, y, z float64) {
+ C.gl2_1_glVertexAttrib3d(gl.funcs, C.GLuint(index), C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib2sv.xml
+func (gl *GL) VertexAttrib2sv(index glbase.Attrib, v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glVertexAttrib2sv(gl.funcs, C.GLuint(index), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib2s.xml
+func (gl *GL) VertexAttrib2s(index glbase.Attrib, x, y int16) {
+ C.gl2_1_glVertexAttrib2s(gl.funcs, C.GLuint(index), C.GLshort(x), C.GLshort(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib2fv.xml
+func (gl *GL) VertexAttrib2fv(index glbase.Attrib, v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glVertexAttrib2fv(gl.funcs, C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib2f.xml
+func (gl *GL) VertexAttrib2f(index glbase.Attrib, x, y float32) {
+ C.gl2_1_glVertexAttrib2f(gl.funcs, C.GLuint(index), C.GLfloat(x), C.GLfloat(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib2dv.xml
+func (gl *GL) VertexAttrib2dv(index glbase.Attrib, v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl2_1_glVertexAttrib2dv(gl.funcs, C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib2d.xml
+func (gl *GL) VertexAttrib2d(index glbase.Attrib, x, y float64) {
+ C.gl2_1_glVertexAttrib2d(gl.funcs, C.GLuint(index), C.GLdouble(x), C.GLdouble(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib1sv.xml
+func (gl *GL) VertexAttrib1sv(index glbase.Attrib, v []int16) {
+ C.gl2_1_glVertexAttrib1sv(gl.funcs, C.GLuint(index), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib1s.xml
+func (gl *GL) VertexAttrib1s(index glbase.Attrib, x int16) {
+ C.gl2_1_glVertexAttrib1s(gl.funcs, C.GLuint(index), C.GLshort(x))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib1fv.xml
+func (gl *GL) VertexAttrib1fv(index glbase.Attrib, v []float32) {
+ C.gl2_1_glVertexAttrib1fv(gl.funcs, C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib1f.xml
+func (gl *GL) VertexAttrib1f(index glbase.Attrib, x float32) {
+ C.gl2_1_glVertexAttrib1f(gl.funcs, C.GLuint(index), C.GLfloat(x))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib1dv.xml
+func (gl *GL) VertexAttrib1dv(index glbase.Attrib, v []float64) {
+ C.gl2_1_glVertexAttrib1dv(gl.funcs, C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib1d.xml
+func (gl *GL) VertexAttrib1d(index glbase.Attrib, x float64) {
+ C.gl2_1_glVertexAttrib1d(gl.funcs, C.GLuint(index), C.GLdouble(x))
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/3.0/funcs.cpp b/Godeps/_workspace/src/github.com/obscuren/qml/gl/3.0/funcs.cpp
new file mode 100644
index 000000000..8d4262f9c
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/3.0/funcs.cpp
@@ -0,0 +1,3966 @@
+
+// ** file automatically generated by glgen -- do not edit manually **
+
+#include <QOpenGLContext>
+#include <QtGui/qopenglfunctions_3_0.h>
+
+#include "funcs.h"
+
+void *gl3_0_funcs() {
+ QOpenGLFunctions_3_0* funcs = QOpenGLContext::currentContext()->versionFunctions<QOpenGLFunctions_3_0>();
+ if (!funcs) {
+ return 0;
+ }
+ funcs->initializeOpenGLFunctions();
+ return funcs;
+}
+
+
+void gl3_0_glViewport(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glViewport(x, y, width, height);
+}
+
+void gl3_0_glDepthRange(void *_glfuncs, GLdouble nearVal, GLdouble farVal)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glDepthRange(nearVal, farVal);
+}
+
+GLboolean gl3_0_glIsEnabled(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ return _qglfuncs->glIsEnabled(cap);
+}
+
+void gl3_0_glGetTexLevelParameteriv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetTexLevelParameteriv(target, level, pname, params);
+}
+
+void gl3_0_glGetTexLevelParameterfv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetTexLevelParameterfv(target, level, pname, params);
+}
+
+void gl3_0_glGetTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetTexParameteriv(target, pname, params);
+}
+
+void gl3_0_glGetTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetTexParameterfv(target, pname, params);
+}
+
+void gl3_0_glGetTexImage(void *_glfuncs, GLenum target, GLint level, GLenum format, GLenum gltype, GLvoid* pixels)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetTexImage(target, level, format, gltype, pixels);
+}
+
+void gl3_0_glGetIntegerv(void *_glfuncs, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetIntegerv(pname, params);
+}
+
+void gl3_0_glGetFloatv(void *_glfuncs, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetFloatv(pname, params);
+}
+
+GLenum gl3_0_glGetError(void *_glfuncs)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ return _qglfuncs->glGetError();
+}
+
+void gl3_0_glGetDoublev(void *_glfuncs, GLenum pname, GLdouble* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetDoublev(pname, params);
+}
+
+void gl3_0_glGetBooleanv(void *_glfuncs, GLenum pname, GLboolean* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetBooleanv(pname, params);
+}
+
+void gl3_0_glReadPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum gltype, GLvoid* pixels)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glReadPixels(x, y, width, height, format, gltype, pixels);
+}
+
+void gl3_0_glReadBuffer(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glReadBuffer(mode);
+}
+
+void gl3_0_glPixelStorei(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glPixelStorei(pname, param);
+}
+
+void gl3_0_glPixelStoref(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glPixelStoref(pname, param);
+}
+
+void gl3_0_glDepthFunc(void *_glfuncs, GLenum glfunc)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glDepthFunc(glfunc);
+}
+
+void gl3_0_glStencilOp(void *_glfuncs, GLenum fail, GLenum zfail, GLenum zpass)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glStencilOp(fail, zfail, zpass);
+}
+
+void gl3_0_glStencilFunc(void *_glfuncs, GLenum glfunc, GLint ref, GLuint mask)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glStencilFunc(glfunc, ref, mask);
+}
+
+void gl3_0_glLogicOp(void *_glfuncs, GLenum opcode)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glLogicOp(opcode);
+}
+
+void gl3_0_glBlendFunc(void *_glfuncs, GLenum sfactor, GLenum dfactor)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glBlendFunc(sfactor, dfactor);
+}
+
+void gl3_0_glFlush(void *_glfuncs)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glFlush();
+}
+
+void gl3_0_glFinish(void *_glfuncs)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glFinish();
+}
+
+void gl3_0_glEnable(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glEnable(cap);
+}
+
+void gl3_0_glDisable(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glDisable(cap);
+}
+
+void gl3_0_glDepthMask(void *_glfuncs, GLboolean flag)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glDepthMask(flag);
+}
+
+void gl3_0_glColorMask(void *_glfuncs, GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glColorMask(red, green, blue, alpha);
+}
+
+void gl3_0_glStencilMask(void *_glfuncs, GLuint mask)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glStencilMask(mask);
+}
+
+void gl3_0_glClearDepth(void *_glfuncs, GLdouble depth)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glClearDepth(depth);
+}
+
+void gl3_0_glClearStencil(void *_glfuncs, GLint s)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glClearStencil(s);
+}
+
+void gl3_0_glClearColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glClearColor(red, green, blue, alpha);
+}
+
+void gl3_0_glClear(void *_glfuncs, GLbitfield mask)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glClear(mask);
+}
+
+void gl3_0_glDrawBuffer(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glDrawBuffer(mode);
+}
+
+void gl3_0_glTexImage2D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glTexImage2D(target, level, internalFormat, width, height, border, format, gltype, pixels);
+}
+
+void gl3_0_glTexImage1D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glTexImage1D(target, level, internalFormat, width, border, format, gltype, pixels);
+}
+
+void gl3_0_glTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glTexParameteriv(target, pname, params);
+}
+
+void gl3_0_glTexParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glTexParameteri(target, pname, param);
+}
+
+void gl3_0_glTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glTexParameterfv(target, pname, params);
+}
+
+void gl3_0_glTexParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glTexParameterf(target, pname, param);
+}
+
+void gl3_0_glScissor(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glScissor(x, y, width, height);
+}
+
+void gl3_0_glPolygonMode(void *_glfuncs, GLenum face, GLenum mode)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glPolygonMode(face, mode);
+}
+
+void gl3_0_glPointSize(void *_glfuncs, GLfloat size)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glPointSize(size);
+}
+
+void gl3_0_glLineWidth(void *_glfuncs, GLfloat width)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glLineWidth(width);
+}
+
+void gl3_0_glHint(void *_glfuncs, GLenum target, GLenum mode)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glHint(target, mode);
+}
+
+void gl3_0_glFrontFace(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glFrontFace(mode);
+}
+
+void gl3_0_glCullFace(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glCullFace(mode);
+}
+
+void gl3_0_glIndexubv(void *_glfuncs, const GLubyte* c)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glIndexubv(c);
+}
+
+void gl3_0_glIndexub(void *_glfuncs, GLubyte c)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glIndexub(c);
+}
+
+GLboolean gl3_0_glIsTexture(void *_glfuncs, GLuint texture)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ return _qglfuncs->glIsTexture(texture);
+}
+
+void gl3_0_glGenTextures(void *_glfuncs, GLsizei n, GLuint* textures)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGenTextures(n, textures);
+}
+
+void gl3_0_glDeleteTextures(void *_glfuncs, GLsizei n, const GLuint* textures)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glDeleteTextures(n, textures);
+}
+
+void gl3_0_glBindTexture(void *_glfuncs, GLenum target, GLuint texture)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glBindTexture(target, texture);
+}
+
+void gl3_0_glTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glTexSubImage2D(target, level, xoffset, yoffset, width, height, format, gltype, pixels);
+}
+
+void gl3_0_glTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glTexSubImage1D(target, level, xoffset, width, format, gltype, pixels);
+}
+
+void gl3_0_glCopyTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage2D(target, level, xoffset, yoffset, x, y, width, height);
+}
+
+void gl3_0_glCopyTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage1D(target, level, xoffset, x, y, width);
+}
+
+void gl3_0_glCopyTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glCopyTexImage2D(target, level, internalFormat, x, y, width, height, border);
+}
+
+void gl3_0_glCopyTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLint border)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glCopyTexImage1D(target, level, internalFormat, x, y, width, border);
+}
+
+void gl3_0_glPolygonOffset(void *_glfuncs, GLfloat factor, GLfloat units)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glPolygonOffset(factor, units);
+}
+
+void gl3_0_glDrawElements(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glDrawElements(mode, count, gltype, indices);
+}
+
+void gl3_0_glDrawArrays(void *_glfuncs, GLenum mode, GLint first, GLsizei count)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glDrawArrays(mode, first, count);
+}
+
+void gl3_0_glCopyTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage3D(target, level, xoffset, yoffset, zoffset, x, y, width, height);
+}
+
+void gl3_0_glTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glTexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, gltype, pixels);
+}
+
+void gl3_0_glTexImage3D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glTexImage3D(target, level, internalFormat, width, height, depth, border, format, gltype, pixels);
+}
+
+void gl3_0_glDrawRangeElements(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glDrawRangeElements(mode, start, end, count, gltype, indices);
+}
+
+void gl3_0_glBlendEquation(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glBlendEquation(mode);
+}
+
+void gl3_0_glBlendColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glBlendColor(red, green, blue, alpha);
+}
+
+void gl3_0_glGetCompressedTexImage(void *_glfuncs, GLenum target, GLint level, GLvoid* img)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetCompressedTexImage(target, level, img);
+}
+
+void gl3_0_glCompressedTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glCompressedTexSubImage1D(target, level, xoffset, width, format, imageSize, data);
+}
+
+void gl3_0_glCompressedTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glCompressedTexSubImage2D(target, level, xoffset, yoffset, width, height, format, imageSize, data);
+}
+
+void gl3_0_glCompressedTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glCompressedTexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, imageSize, data);
+}
+
+void gl3_0_glCompressedTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glCompressedTexImage1D(target, level, internalFormat, width, border, imageSize, data);
+}
+
+void gl3_0_glCompressedTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glCompressedTexImage2D(target, level, internalFormat, width, height, border, imageSize, data);
+}
+
+void gl3_0_glCompressedTexImage3D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glCompressedTexImage3D(target, level, internalFormat, width, height, depth, border, imageSize, data);
+}
+
+void gl3_0_glSampleCoverage(void *_glfuncs, GLfloat value, GLboolean invert)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glSampleCoverage(value, invert);
+}
+
+void gl3_0_glActiveTexture(void *_glfuncs, GLenum texture)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glActiveTexture(texture);
+}
+
+void gl3_0_glPointParameteriv(void *_glfuncs, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glPointParameteriv(pname, params);
+}
+
+void gl3_0_glPointParameteri(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glPointParameteri(pname, param);
+}
+
+void gl3_0_glPointParameterfv(void *_glfuncs, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glPointParameterfv(pname, params);
+}
+
+void gl3_0_glPointParameterf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glPointParameterf(pname, param);
+}
+
+void gl3_0_glMultiDrawArrays(void *_glfuncs, GLenum mode, const GLint* first, const GLsizei* count, GLsizei drawcount)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glMultiDrawArrays(mode, first, count, drawcount);
+}
+
+void gl3_0_glBlendFuncSeparate(void *_glfuncs, GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glBlendFuncSeparate(sfactorRGB, dfactorRGB, sfactorAlpha, dfactorAlpha);
+}
+
+void gl3_0_glGetBufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetBufferParameteriv(target, pname, params);
+}
+
+GLboolean gl3_0_glUnmapBuffer(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ return _qglfuncs->glUnmapBuffer(target);
+}
+
+void gl3_0_glGetBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, GLvoid* data)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetBufferSubData(target, offset, size, data);
+}
+
+void gl3_0_glBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid* data)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glBufferSubData(target, offset, size, data);
+}
+
+void gl3_0_glBufferData(void *_glfuncs, GLenum target, GLsizeiptr size, const GLvoid* data, GLenum usage)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glBufferData(target, size, data, usage);
+}
+
+GLboolean gl3_0_glIsBuffer(void *_glfuncs, GLuint buffer)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ return _qglfuncs->glIsBuffer(buffer);
+}
+
+void gl3_0_glGenBuffers(void *_glfuncs, GLsizei n, GLuint* buffers)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGenBuffers(n, buffers);
+}
+
+void gl3_0_glDeleteBuffers(void *_glfuncs, GLsizei n, const GLuint* buffers)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glDeleteBuffers(n, buffers);
+}
+
+void gl3_0_glBindBuffer(void *_glfuncs, GLenum target, GLuint buffer)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glBindBuffer(target, buffer);
+}
+
+void gl3_0_glGetQueryObjectuiv(void *_glfuncs, GLuint id, GLenum pname, GLuint* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetQueryObjectuiv(id, pname, params);
+}
+
+void gl3_0_glGetQueryObjectiv(void *_glfuncs, GLuint id, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetQueryObjectiv(id, pname, params);
+}
+
+void gl3_0_glGetQueryiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetQueryiv(target, pname, params);
+}
+
+void gl3_0_glEndQuery(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glEndQuery(target);
+}
+
+void gl3_0_glBeginQuery(void *_glfuncs, GLenum target, GLuint id)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glBeginQuery(target, id);
+}
+
+GLboolean gl3_0_glIsQuery(void *_glfuncs, GLuint id)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ return _qglfuncs->glIsQuery(id);
+}
+
+void gl3_0_glDeleteQueries(void *_glfuncs, GLsizei n, const GLuint* ids)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glDeleteQueries(n, ids);
+}
+
+void gl3_0_glGenQueries(void *_glfuncs, GLsizei n, GLuint* ids)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGenQueries(n, ids);
+}
+
+void gl3_0_glVertexAttribPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLboolean normalized, GLsizei stride, const GLvoid* offset)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertexAttribPointer(index, size, gltype, normalized, stride, offset);
+}
+
+void gl3_0_glValidateProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glValidateProgram(program);
+}
+
+void gl3_0_glUniformMatrix4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4fv(location, count, transpose, value);
+}
+
+void gl3_0_glUniformMatrix3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3fv(location, count, transpose, value);
+}
+
+void gl3_0_glUniformMatrix2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2fv(location, count, transpose, value);
+}
+
+void gl3_0_glUniform4iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glUniform4iv(location, count, value);
+}
+
+void gl3_0_glUniform3iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glUniform3iv(location, count, value);
+}
+
+void gl3_0_glUniform2iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glUniform2iv(location, count, value);
+}
+
+void gl3_0_glUniform1iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glUniform1iv(location, count, value);
+}
+
+void gl3_0_glUniform4fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glUniform4fv(location, count, value);
+}
+
+void gl3_0_glUniform3fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glUniform3fv(location, count, value);
+}
+
+void gl3_0_glUniform2fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glUniform2fv(location, count, value);
+}
+
+void gl3_0_glUniform1fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glUniform1fv(location, count, value);
+}
+
+void gl3_0_glUniform4i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2, GLint v3)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glUniform4i(location, v0, v1, v2, v3);
+}
+
+void gl3_0_glUniform3i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glUniform3i(location, v0, v1, v2);
+}
+
+void gl3_0_glUniform2i(void *_glfuncs, GLint location, GLint v0, GLint v1)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glUniform2i(location, v0, v1);
+}
+
+void gl3_0_glUniform1i(void *_glfuncs, GLint location, GLint v0)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glUniform1i(location, v0);
+}
+
+void gl3_0_glUniform4f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glUniform4f(location, v0, v1, v2, v3);
+}
+
+void gl3_0_glUniform3f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glUniform3f(location, v0, v1, v2);
+}
+
+void gl3_0_glUniform2f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glUniform2f(location, v0, v1);
+}
+
+void gl3_0_glUniform1f(void *_glfuncs, GLint location, GLfloat v0)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glUniform1f(location, v0);
+}
+
+void gl3_0_glUseProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glUseProgram(program);
+}
+
+void gl3_0_glShaderSource(void *_glfuncs, GLuint shader, GLsizei count, const GLchar** source, const GLint* length)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glShaderSource(shader, count, source, length);
+}
+
+void gl3_0_glLinkProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glLinkProgram(program);
+}
+
+GLboolean gl3_0_glIsShader(void *_glfuncs, GLuint shader)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ return _qglfuncs->glIsShader(shader);
+}
+
+GLboolean gl3_0_glIsProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ return _qglfuncs->glIsProgram(program);
+}
+
+void gl3_0_glGetVertexAttribiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribiv(index, pname, params);
+}
+
+void gl3_0_glGetVertexAttribfv(void *_glfuncs, GLuint index, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribfv(index, pname, params);
+}
+
+void gl3_0_glGetVertexAttribdv(void *_glfuncs, GLuint index, GLenum pname, GLdouble* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribdv(index, pname, params);
+}
+
+void gl3_0_glGetUniformiv(void *_glfuncs, GLuint program, GLint location, GLint* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetUniformiv(program, location, params);
+}
+
+void gl3_0_glGetUniformfv(void *_glfuncs, GLuint program, GLint location, GLfloat* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetUniformfv(program, location, params);
+}
+
+GLint gl3_0_glGetUniformLocation(void *_glfuncs, GLuint program, const GLchar* name)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ return _qglfuncs->glGetUniformLocation(program, name);
+}
+
+void gl3_0_glGetShaderSource(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* source)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetShaderSource(shader, bufSize, length, source);
+}
+
+void gl3_0_glGetShaderInfoLog(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* infoLog)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetShaderInfoLog(shader, bufSize, length, infoLog);
+}
+
+void gl3_0_glGetShaderiv(void *_glfuncs, GLuint shader, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetShaderiv(shader, pname, params);
+}
+
+void gl3_0_glGetProgramInfoLog(void *_glfuncs, GLuint program, GLsizei bufSize, GLsizei* length, GLchar* infoLog)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetProgramInfoLog(program, bufSize, length, infoLog);
+}
+
+void gl3_0_glGetProgramiv(void *_glfuncs, GLuint program, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetProgramiv(program, pname, params);
+}
+
+GLint gl3_0_glGetAttribLocation(void *_glfuncs, GLuint program, const GLchar* name)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ return _qglfuncs->glGetAttribLocation(program, name);
+}
+
+void gl3_0_glGetAttachedShaders(void *_glfuncs, GLuint program, GLsizei maxCount, GLsizei* count, GLuint* obj)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetAttachedShaders(program, maxCount, count, obj);
+}
+
+void gl3_0_glGetActiveUniform(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetActiveUniform(program, index, bufSize, length, size, gltype, name);
+}
+
+void gl3_0_glGetActiveAttrib(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetActiveAttrib(program, index, bufSize, length, size, gltype, name);
+}
+
+void gl3_0_glEnableVertexAttribArray(void *_glfuncs, GLuint index)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glEnableVertexAttribArray(index);
+}
+
+void gl3_0_glDisableVertexAttribArray(void *_glfuncs, GLuint index)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glDisableVertexAttribArray(index);
+}
+
+void gl3_0_glDetachShader(void *_glfuncs, GLuint program, GLuint shader)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glDetachShader(program, shader);
+}
+
+void gl3_0_glDeleteShader(void *_glfuncs, GLuint shader)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glDeleteShader(shader);
+}
+
+void gl3_0_glDeleteProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glDeleteProgram(program);
+}
+
+GLuint gl3_0_glCreateShader(void *_glfuncs, GLenum gltype)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ return _qglfuncs->glCreateShader(gltype);
+}
+
+GLuint gl3_0_glCreateProgram(void *_glfuncs)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ return _qglfuncs->glCreateProgram();
+}
+
+void gl3_0_glCompileShader(void *_glfuncs, GLuint shader)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glCompileShader(shader);
+}
+
+void gl3_0_glBindAttribLocation(void *_glfuncs, GLuint program, GLuint index, const GLchar* name)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glBindAttribLocation(program, index, name);
+}
+
+void gl3_0_glAttachShader(void *_glfuncs, GLuint program, GLuint shader)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glAttachShader(program, shader);
+}
+
+void gl3_0_glStencilMaskSeparate(void *_glfuncs, GLenum face, GLuint mask)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glStencilMaskSeparate(face, mask);
+}
+
+void gl3_0_glStencilFuncSeparate(void *_glfuncs, GLenum face, GLenum glfunc, GLint ref, GLuint mask)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glStencilFuncSeparate(face, glfunc, ref, mask);
+}
+
+void gl3_0_glStencilOpSeparate(void *_glfuncs, GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glStencilOpSeparate(face, sfail, dpfail, dppass);
+}
+
+void gl3_0_glDrawBuffers(void *_glfuncs, GLsizei n, const GLenum* bufs)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glDrawBuffers(n, bufs);
+}
+
+void gl3_0_glBlendEquationSeparate(void *_glfuncs, GLenum modeRGB, GLenum modeAlpha)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glBlendEquationSeparate(modeRGB, modeAlpha);
+}
+
+void gl3_0_glUniformMatrix4x3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4x3fv(location, count, transpose, value);
+}
+
+void gl3_0_glUniformMatrix3x4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3x4fv(location, count, transpose, value);
+}
+
+void gl3_0_glUniformMatrix4x2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4x2fv(location, count, transpose, value);
+}
+
+void gl3_0_glUniformMatrix2x4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2x4fv(location, count, transpose, value);
+}
+
+void gl3_0_glUniformMatrix3x2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3x2fv(location, count, transpose, value);
+}
+
+void gl3_0_glUniformMatrix2x3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2x3fv(location, count, transpose, value);
+}
+
+GLboolean gl3_0_glIsVertexArray(void *_glfuncs, GLuint array)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ return _qglfuncs->glIsVertexArray(array);
+}
+
+void gl3_0_glGenVertexArrays(void *_glfuncs, GLsizei n, GLuint* arrays)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGenVertexArrays(n, arrays);
+}
+
+void gl3_0_glDeleteVertexArrays(void *_glfuncs, GLsizei n, const GLuint* arrays)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glDeleteVertexArrays(n, arrays);
+}
+
+void gl3_0_glBindVertexArray(void *_glfuncs, GLuint array)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glBindVertexArray(array);
+}
+
+void gl3_0_glFlushMappedBufferRange(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr length)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glFlushMappedBufferRange(target, offset, length);
+}
+
+void gl3_0_glFramebufferTextureLayer(void *_glfuncs, GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glFramebufferTextureLayer(target, attachment, texture, level, layer);
+}
+
+void gl3_0_glRenderbufferStorageMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLenum internalFormat, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glRenderbufferStorageMultisample(target, samples, internalFormat, width, height);
+}
+
+void gl3_0_glBlitFramebuffer(void *_glfuncs, GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glBlitFramebuffer(srcX0, srcY0, srcX1, srcY1, dstX0, dstY0, dstX1, dstY1, mask, filter);
+}
+
+void gl3_0_glGenerateMipmap(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGenerateMipmap(target);
+}
+
+void gl3_0_glGetFramebufferAttachmentParameteriv(void *_glfuncs, GLenum target, GLenum attachment, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetFramebufferAttachmentParameteriv(target, attachment, pname, params);
+}
+
+void gl3_0_glFramebufferRenderbuffer(void *_glfuncs, GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glFramebufferRenderbuffer(target, attachment, renderbuffertarget, renderbuffer);
+}
+
+void gl3_0_glFramebufferTexture3D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glFramebufferTexture3D(target, attachment, textarget, texture, level, zoffset);
+}
+
+void gl3_0_glFramebufferTexture2D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glFramebufferTexture2D(target, attachment, textarget, texture, level);
+}
+
+void gl3_0_glFramebufferTexture1D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glFramebufferTexture1D(target, attachment, textarget, texture, level);
+}
+
+GLenum gl3_0_glCheckFramebufferStatus(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ return _qglfuncs->glCheckFramebufferStatus(target);
+}
+
+void gl3_0_glGenFramebuffers(void *_glfuncs, GLsizei n, GLuint* framebuffers)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGenFramebuffers(n, framebuffers);
+}
+
+void gl3_0_glDeleteFramebuffers(void *_glfuncs, GLsizei n, const GLuint* framebuffers)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glDeleteFramebuffers(n, framebuffers);
+}
+
+void gl3_0_glBindFramebuffer(void *_glfuncs, GLenum target, GLuint framebuffer)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glBindFramebuffer(target, framebuffer);
+}
+
+GLboolean gl3_0_glIsFramebuffer(void *_glfuncs, GLuint framebuffer)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ return _qglfuncs->glIsFramebuffer(framebuffer);
+}
+
+void gl3_0_glGetRenderbufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetRenderbufferParameteriv(target, pname, params);
+}
+
+void gl3_0_glRenderbufferStorage(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glRenderbufferStorage(target, internalFormat, width, height);
+}
+
+void gl3_0_glGenRenderbuffers(void *_glfuncs, GLsizei n, GLuint* renderbuffers)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGenRenderbuffers(n, renderbuffers);
+}
+
+void gl3_0_glDeleteRenderbuffers(void *_glfuncs, GLsizei n, const GLuint* renderbuffers)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glDeleteRenderbuffers(n, renderbuffers);
+}
+
+void gl3_0_glBindRenderbuffer(void *_glfuncs, GLenum target, GLuint renderbuffer)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glBindRenderbuffer(target, renderbuffer);
+}
+
+GLboolean gl3_0_glIsRenderbuffer(void *_glfuncs, GLuint renderbuffer)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ return _qglfuncs->glIsRenderbuffer(renderbuffer);
+}
+
+void gl3_0_glClearBufferfi(void *_glfuncs, GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glClearBufferfi(buffer, drawbuffer, depth, stencil);
+}
+
+void gl3_0_glClearBufferfv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLfloat* value)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glClearBufferfv(buffer, drawbuffer, value);
+}
+
+void gl3_0_glClearBufferuiv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLuint* value)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glClearBufferuiv(buffer, drawbuffer, value);
+}
+
+void gl3_0_glClearBufferiv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLint* value)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glClearBufferiv(buffer, drawbuffer, value);
+}
+
+void gl3_0_glGetTexParameterIuiv(void *_glfuncs, GLenum target, GLenum pname, GLuint* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetTexParameterIuiv(target, pname, params);
+}
+
+void gl3_0_glGetTexParameterIiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetTexParameterIiv(target, pname, params);
+}
+
+void gl3_0_glTexParameterIuiv(void *_glfuncs, GLenum target, GLenum pname, const GLuint* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glTexParameterIuiv(target, pname, params);
+}
+
+void gl3_0_glTexParameterIiv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glTexParameterIiv(target, pname, params);
+}
+
+void gl3_0_glUniform4uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glUniform4uiv(location, count, value);
+}
+
+void gl3_0_glUniform3uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glUniform3uiv(location, count, value);
+}
+
+void gl3_0_glUniform2uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glUniform2uiv(location, count, value);
+}
+
+void gl3_0_glUniform1uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glUniform1uiv(location, count, value);
+}
+
+void gl3_0_glUniform4ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glUniform4ui(location, v0, v1, v2, v3);
+}
+
+void gl3_0_glUniform3ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1, GLuint v2)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glUniform3ui(location, v0, v1, v2);
+}
+
+void gl3_0_glUniform2ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glUniform2ui(location, v0, v1);
+}
+
+void gl3_0_glUniform1ui(void *_glfuncs, GLint location, GLuint v0)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glUniform1ui(location, v0);
+}
+
+GLint gl3_0_glGetFragDataLocation(void *_glfuncs, GLuint program, const GLchar* name)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ return _qglfuncs->glGetFragDataLocation(program, name);
+}
+
+void gl3_0_glBindFragDataLocation(void *_glfuncs, GLuint program, GLuint color, const GLchar* name)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glBindFragDataLocation(program, color, name);
+}
+
+void gl3_0_glGetUniformuiv(void *_glfuncs, GLuint program, GLint location, GLuint* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetUniformuiv(program, location, params);
+}
+
+void gl3_0_glGetVertexAttribIuiv(void *_glfuncs, GLuint index, GLenum pname, GLuint* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribIuiv(index, pname, params);
+}
+
+void gl3_0_glGetVertexAttribIiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribIiv(index, pname, params);
+}
+
+void gl3_0_glVertexAttribIPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertexAttribIPointer(index, size, gltype, stride, pointer);
+}
+
+void gl3_0_glEndConditionalRender(void *_glfuncs)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glEndConditionalRender();
+}
+
+void gl3_0_glBeginConditionalRender(void *_glfuncs, GLuint id, GLenum mode)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glBeginConditionalRender(id, mode);
+}
+
+void gl3_0_glClampColor(void *_glfuncs, GLenum target, GLenum clamp)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glClampColor(target, clamp);
+}
+
+void gl3_0_glGetTransformFeedbackVarying(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLsizei* size, GLenum* gltype, GLchar* name)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetTransformFeedbackVarying(program, index, bufSize, length, size, gltype, name);
+}
+
+void gl3_0_glBindBufferBase(void *_glfuncs, GLenum target, GLuint index, GLuint buffer)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glBindBufferBase(target, index, buffer);
+}
+
+void gl3_0_glBindBufferRange(void *_glfuncs, GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glBindBufferRange(target, index, buffer, offset, size);
+}
+
+void gl3_0_glEndTransformFeedback(void *_glfuncs)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glEndTransformFeedback();
+}
+
+void gl3_0_glBeginTransformFeedback(void *_glfuncs, GLenum primitiveMode)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glBeginTransformFeedback(primitiveMode);
+}
+
+GLboolean gl3_0_glIsEnabledi(void *_glfuncs, GLenum target, GLuint index)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ return _qglfuncs->glIsEnabledi(target, index);
+}
+
+void gl3_0_glDisablei(void *_glfuncs, GLenum target, GLuint index)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glDisablei(target, index);
+}
+
+void gl3_0_glEnablei(void *_glfuncs, GLenum target, GLuint index)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glEnablei(target, index);
+}
+
+void gl3_0_glGetIntegeri_v(void *_glfuncs, GLenum target, GLuint index, GLint* data)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetIntegeri_v(target, index, data);
+}
+
+void gl3_0_glGetBooleani_v(void *_glfuncs, GLenum target, GLuint index, GLboolean* data)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetBooleani_v(target, index, data);
+}
+
+void gl3_0_glColorMaski(void *_glfuncs, GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glColorMaski(index, r, g, b, a);
+}
+
+void gl3_0_glTranslatef(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glTranslatef(x, y, z);
+}
+
+void gl3_0_glTranslated(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glTranslated(x, y, z);
+}
+
+void gl3_0_glScalef(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glScalef(x, y, z);
+}
+
+void gl3_0_glScaled(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glScaled(x, y, z);
+}
+
+void gl3_0_glRotatef(void *_glfuncs, GLfloat angle, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glRotatef(angle, x, y, z);
+}
+
+void gl3_0_glRotated(void *_glfuncs, GLdouble angle, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glRotated(angle, x, y, z);
+}
+
+void gl3_0_glPushMatrix(void *_glfuncs)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glPushMatrix();
+}
+
+void gl3_0_glPopMatrix(void *_glfuncs)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glPopMatrix();
+}
+
+void gl3_0_glOrtho(void *_glfuncs, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glOrtho(left, right, bottom, top, zNear, zFar);
+}
+
+void gl3_0_glMultMatrixd(void *_glfuncs, const GLdouble* m)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glMultMatrixd(m);
+}
+
+void gl3_0_glMultMatrixf(void *_glfuncs, const GLfloat* m)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glMultMatrixf(m);
+}
+
+void gl3_0_glMatrixMode(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glMatrixMode(mode);
+}
+
+void gl3_0_glLoadMatrixd(void *_glfuncs, const GLdouble* m)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glLoadMatrixd(m);
+}
+
+void gl3_0_glLoadMatrixf(void *_glfuncs, const GLfloat* m)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glLoadMatrixf(m);
+}
+
+void gl3_0_glLoadIdentity(void *_glfuncs)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glLoadIdentity();
+}
+
+void gl3_0_glFrustum(void *_glfuncs, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glFrustum(left, right, bottom, top, zNear, zFar);
+}
+
+GLboolean gl3_0_glIsList(void *_glfuncs, GLuint list)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ return _qglfuncs->glIsList(list);
+}
+
+void gl3_0_glGetTexGeniv(void *_glfuncs, GLenum coord, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetTexGeniv(coord, pname, params);
+}
+
+void gl3_0_glGetTexGenfv(void *_glfuncs, GLenum coord, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetTexGenfv(coord, pname, params);
+}
+
+void gl3_0_glGetTexGendv(void *_glfuncs, GLenum coord, GLenum pname, GLdouble* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetTexGendv(coord, pname, params);
+}
+
+void gl3_0_glGetTexEnviv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetTexEnviv(target, pname, params);
+}
+
+void gl3_0_glGetTexEnvfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetTexEnvfv(target, pname, params);
+}
+
+void gl3_0_glGetPolygonStipple(void *_glfuncs, GLubyte* mask)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetPolygonStipple(mask);
+}
+
+void gl3_0_glGetPixelMapusv(void *_glfuncs, GLenum glmap, GLushort* values)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetPixelMapusv(glmap, values);
+}
+
+void gl3_0_glGetPixelMapuiv(void *_glfuncs, GLenum glmap, GLuint* values)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetPixelMapuiv(glmap, values);
+}
+
+void gl3_0_glGetPixelMapfv(void *_glfuncs, GLenum glmap, GLfloat* values)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetPixelMapfv(glmap, values);
+}
+
+void gl3_0_glGetMaterialiv(void *_glfuncs, GLenum face, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetMaterialiv(face, pname, params);
+}
+
+void gl3_0_glGetMaterialfv(void *_glfuncs, GLenum face, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetMaterialfv(face, pname, params);
+}
+
+void gl3_0_glGetMapiv(void *_glfuncs, GLenum target, GLenum query, GLint* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetMapiv(target, query, v);
+}
+
+void gl3_0_glGetMapfv(void *_glfuncs, GLenum target, GLenum query, GLfloat* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetMapfv(target, query, v);
+}
+
+void gl3_0_glGetMapdv(void *_glfuncs, GLenum target, GLenum query, GLdouble* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetMapdv(target, query, v);
+}
+
+void gl3_0_glGetLightiv(void *_glfuncs, GLenum light, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetLightiv(light, pname, params);
+}
+
+void gl3_0_glGetLightfv(void *_glfuncs, GLenum light, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetLightfv(light, pname, params);
+}
+
+void gl3_0_glGetClipPlane(void *_glfuncs, GLenum plane, GLdouble* equation)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetClipPlane(plane, equation);
+}
+
+void gl3_0_glDrawPixels(void *_glfuncs, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glDrawPixels(width, height, format, gltype, pixels);
+}
+
+void gl3_0_glCopyPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum gltype)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glCopyPixels(x, y, width, height, gltype);
+}
+
+void gl3_0_glPixelMapusv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLushort* values)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glPixelMapusv(glmap, mapsize, values);
+}
+
+void gl3_0_glPixelMapuiv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLuint* values)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glPixelMapuiv(glmap, mapsize, values);
+}
+
+void gl3_0_glPixelMapfv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLfloat* values)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glPixelMapfv(glmap, mapsize, values);
+}
+
+void gl3_0_glPixelTransferi(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glPixelTransferi(pname, param);
+}
+
+void gl3_0_glPixelTransferf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glPixelTransferf(pname, param);
+}
+
+void gl3_0_glPixelZoom(void *_glfuncs, GLfloat xfactor, GLfloat yfactor)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glPixelZoom(xfactor, yfactor);
+}
+
+void gl3_0_glAlphaFunc(void *_glfuncs, GLenum glfunc, GLfloat ref)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glAlphaFunc(glfunc, ref);
+}
+
+void gl3_0_glEvalPoint2(void *_glfuncs, GLint i, GLint j)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glEvalPoint2(i, j);
+}
+
+void gl3_0_glEvalMesh2(void *_glfuncs, GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glEvalMesh2(mode, i1, i2, j1, j2);
+}
+
+void gl3_0_glEvalPoint1(void *_glfuncs, GLint i)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glEvalPoint1(i);
+}
+
+void gl3_0_glEvalMesh1(void *_glfuncs, GLenum mode, GLint i1, GLint i2)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glEvalMesh1(mode, i1, i2);
+}
+
+void gl3_0_glEvalCoord2fv(void *_glfuncs, const GLfloat* u)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glEvalCoord2fv(u);
+}
+
+void gl3_0_glEvalCoord2f(void *_glfuncs, GLfloat u, GLfloat v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glEvalCoord2f(u, v);
+}
+
+void gl3_0_glEvalCoord2dv(void *_glfuncs, const GLdouble* u)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glEvalCoord2dv(u);
+}
+
+void gl3_0_glEvalCoord2d(void *_glfuncs, GLdouble u, GLdouble v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glEvalCoord2d(u, v);
+}
+
+void gl3_0_glEvalCoord1fv(void *_glfuncs, const GLfloat* u)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glEvalCoord1fv(u);
+}
+
+void gl3_0_glEvalCoord1f(void *_glfuncs, GLfloat u)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glEvalCoord1f(u);
+}
+
+void gl3_0_glEvalCoord1dv(void *_glfuncs, const GLdouble* u)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glEvalCoord1dv(u);
+}
+
+void gl3_0_glEvalCoord1d(void *_glfuncs, GLdouble u)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glEvalCoord1d(u);
+}
+
+void gl3_0_glMapGrid2f(void *_glfuncs, GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glMapGrid2f(un, u1, u2, vn, v1, v2);
+}
+
+void gl3_0_glMapGrid2d(void *_glfuncs, GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glMapGrid2d(un, u1, u2, vn, v1, v2);
+}
+
+void gl3_0_glMapGrid1f(void *_glfuncs, GLint un, GLfloat u1, GLfloat u2)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glMapGrid1f(un, u1, u2);
+}
+
+void gl3_0_glMapGrid1d(void *_glfuncs, GLint un, GLdouble u1, GLdouble u2)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glMapGrid1d(un, u1, u2);
+}
+
+void gl3_0_glMap2f(void *_glfuncs, GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat* points)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glMap2f(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+void gl3_0_glMap2d(void *_glfuncs, GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble* points)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glMap2d(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+void gl3_0_glMap1f(void *_glfuncs, GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat* points)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glMap1f(target, u1, u2, stride, order, points);
+}
+
+void gl3_0_glMap1d(void *_glfuncs, GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble* points)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glMap1d(target, u1, u2, stride, order, points);
+}
+
+void gl3_0_glPushAttrib(void *_glfuncs, GLbitfield mask)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glPushAttrib(mask);
+}
+
+void gl3_0_glPopAttrib(void *_glfuncs)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glPopAttrib();
+}
+
+void gl3_0_glAccum(void *_glfuncs, GLenum op, GLfloat value)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glAccum(op, value);
+}
+
+void gl3_0_glIndexMask(void *_glfuncs, GLuint mask)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glIndexMask(mask);
+}
+
+void gl3_0_glClearIndex(void *_glfuncs, GLfloat c)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glClearIndex(c);
+}
+
+void gl3_0_glClearAccum(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glClearAccum(red, green, blue, alpha);
+}
+
+void gl3_0_glPushName(void *_glfuncs, GLuint name)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glPushName(name);
+}
+
+void gl3_0_glPopName(void *_glfuncs)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glPopName();
+}
+
+void gl3_0_glPassThrough(void *_glfuncs, GLfloat token)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glPassThrough(token);
+}
+
+void gl3_0_glLoadName(void *_glfuncs, GLuint name)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glLoadName(name);
+}
+
+void gl3_0_glInitNames(void *_glfuncs)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glInitNames();
+}
+
+GLint gl3_0_glRenderMode(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ return _qglfuncs->glRenderMode(mode);
+}
+
+void gl3_0_glSelectBuffer(void *_glfuncs, GLsizei size, GLuint* buffer)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glSelectBuffer(size, buffer);
+}
+
+void gl3_0_glFeedbackBuffer(void *_glfuncs, GLsizei size, GLenum gltype, GLfloat* buffer)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glFeedbackBuffer(size, gltype, buffer);
+}
+
+void gl3_0_glTexGeniv(void *_glfuncs, GLenum coord, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glTexGeniv(coord, pname, params);
+}
+
+void gl3_0_glTexGeni(void *_glfuncs, GLenum coord, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glTexGeni(coord, pname, param);
+}
+
+void gl3_0_glTexGenfv(void *_glfuncs, GLenum coord, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glTexGenfv(coord, pname, params);
+}
+
+void gl3_0_glTexGenf(void *_glfuncs, GLenum coord, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glTexGenf(coord, pname, param);
+}
+
+void gl3_0_glTexGendv(void *_glfuncs, GLenum coord, GLenum pname, const GLdouble* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glTexGendv(coord, pname, params);
+}
+
+void gl3_0_glTexGend(void *_glfuncs, GLenum coord, GLenum pname, GLdouble param)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glTexGend(coord, pname, param);
+}
+
+void gl3_0_glTexEnviv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glTexEnviv(target, pname, params);
+}
+
+void gl3_0_glTexEnvi(void *_glfuncs, GLenum target, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glTexEnvi(target, pname, param);
+}
+
+void gl3_0_glTexEnvfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glTexEnvfv(target, pname, params);
+}
+
+void gl3_0_glTexEnvf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glTexEnvf(target, pname, param);
+}
+
+void gl3_0_glShadeModel(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glShadeModel(mode);
+}
+
+void gl3_0_glPolygonStipple(void *_glfuncs, const GLubyte* mask)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glPolygonStipple(mask);
+}
+
+void gl3_0_glMaterialiv(void *_glfuncs, GLenum face, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glMaterialiv(face, pname, params);
+}
+
+void gl3_0_glMateriali(void *_glfuncs, GLenum face, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glMateriali(face, pname, param);
+}
+
+void gl3_0_glMaterialfv(void *_glfuncs, GLenum face, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glMaterialfv(face, pname, params);
+}
+
+void gl3_0_glMaterialf(void *_glfuncs, GLenum face, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glMaterialf(face, pname, param);
+}
+
+void gl3_0_glLineStipple(void *_glfuncs, GLint factor, GLushort pattern)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glLineStipple(factor, pattern);
+}
+
+void gl3_0_glLightModeliv(void *_glfuncs, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glLightModeliv(pname, params);
+}
+
+void gl3_0_glLightModeli(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glLightModeli(pname, param);
+}
+
+void gl3_0_glLightModelfv(void *_glfuncs, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glLightModelfv(pname, params);
+}
+
+void gl3_0_glLightModelf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glLightModelf(pname, param);
+}
+
+void gl3_0_glLightiv(void *_glfuncs, GLenum light, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glLightiv(light, pname, params);
+}
+
+void gl3_0_glLighti(void *_glfuncs, GLenum light, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glLighti(light, pname, param);
+}
+
+void gl3_0_glLightfv(void *_glfuncs, GLenum light, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glLightfv(light, pname, params);
+}
+
+void gl3_0_glLightf(void *_glfuncs, GLenum light, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glLightf(light, pname, param);
+}
+
+void gl3_0_glFogiv(void *_glfuncs, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glFogiv(pname, params);
+}
+
+void gl3_0_glFogi(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glFogi(pname, param);
+}
+
+void gl3_0_glFogfv(void *_glfuncs, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glFogfv(pname, params);
+}
+
+void gl3_0_glFogf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glFogf(pname, param);
+}
+
+void gl3_0_glColorMaterial(void *_glfuncs, GLenum face, GLenum mode)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glColorMaterial(face, mode);
+}
+
+void gl3_0_glClipPlane(void *_glfuncs, GLenum plane, const GLdouble* equation)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glClipPlane(plane, equation);
+}
+
+void gl3_0_glVertex4sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertex4sv(v);
+}
+
+void gl3_0_glVertex4s(void *_glfuncs, GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertex4s(x, y, z, w);
+}
+
+void gl3_0_glVertex4iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertex4iv(v);
+}
+
+void gl3_0_glVertex4i(void *_glfuncs, GLint x, GLint y, GLint z, GLint w)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertex4i(x, y, z, w);
+}
+
+void gl3_0_glVertex4fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertex4fv(v);
+}
+
+void gl3_0_glVertex4f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertex4f(x, y, z, w);
+}
+
+void gl3_0_glVertex4dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertex4dv(v);
+}
+
+void gl3_0_glVertex4d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertex4d(x, y, z, w);
+}
+
+void gl3_0_glVertex3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertex3sv(v);
+}
+
+void gl3_0_glVertex3s(void *_glfuncs, GLshort x, GLshort y, GLshort z)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertex3s(x, y, z);
+}
+
+void gl3_0_glVertex3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertex3iv(v);
+}
+
+void gl3_0_glVertex3i(void *_glfuncs, GLint x, GLint y, GLint z)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertex3i(x, y, z);
+}
+
+void gl3_0_glVertex3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertex3fv(v);
+}
+
+void gl3_0_glVertex3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertex3f(x, y, z);
+}
+
+void gl3_0_glVertex3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertex3dv(v);
+}
+
+void gl3_0_glVertex3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertex3d(x, y, z);
+}
+
+void gl3_0_glVertex2sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertex2sv(v);
+}
+
+void gl3_0_glVertex2s(void *_glfuncs, GLshort x, GLshort y)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertex2s(x, y);
+}
+
+void gl3_0_glVertex2iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertex2iv(v);
+}
+
+void gl3_0_glVertex2i(void *_glfuncs, GLint x, GLint y)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertex2i(x, y);
+}
+
+void gl3_0_glVertex2fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertex2fv(v);
+}
+
+void gl3_0_glVertex2f(void *_glfuncs, GLfloat x, GLfloat y)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertex2f(x, y);
+}
+
+void gl3_0_glVertex2dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertex2dv(v);
+}
+
+void gl3_0_glVertex2d(void *_glfuncs, GLdouble x, GLdouble y)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertex2d(x, y);
+}
+
+void gl3_0_glTexCoord4sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glTexCoord4sv(v);
+}
+
+void gl3_0_glTexCoord4s(void *_glfuncs, GLshort s, GLshort t, GLshort r, GLshort q)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glTexCoord4s(s, t, r, q);
+}
+
+void gl3_0_glTexCoord4iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glTexCoord4iv(v);
+}
+
+void gl3_0_glTexCoord4i(void *_glfuncs, GLint s, GLint t, GLint r, GLint q)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glTexCoord4i(s, t, r, q);
+}
+
+void gl3_0_glTexCoord4fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glTexCoord4fv(v);
+}
+
+void gl3_0_glTexCoord4f(void *_glfuncs, GLfloat s, GLfloat t, GLfloat r, GLfloat q)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glTexCoord4f(s, t, r, q);
+}
+
+void gl3_0_glTexCoord4dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glTexCoord4dv(v);
+}
+
+void gl3_0_glTexCoord4d(void *_glfuncs, GLdouble s, GLdouble t, GLdouble r, GLdouble q)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glTexCoord4d(s, t, r, q);
+}
+
+void gl3_0_glTexCoord3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glTexCoord3sv(v);
+}
+
+void gl3_0_glTexCoord3s(void *_glfuncs, GLshort s, GLshort t, GLshort r)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glTexCoord3s(s, t, r);
+}
+
+void gl3_0_glTexCoord3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glTexCoord3iv(v);
+}
+
+void gl3_0_glTexCoord3i(void *_glfuncs, GLint s, GLint t, GLint r)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glTexCoord3i(s, t, r);
+}
+
+void gl3_0_glTexCoord3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glTexCoord3fv(v);
+}
+
+void gl3_0_glTexCoord3f(void *_glfuncs, GLfloat s, GLfloat t, GLfloat r)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glTexCoord3f(s, t, r);
+}
+
+void gl3_0_glTexCoord3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glTexCoord3dv(v);
+}
+
+void gl3_0_glTexCoord3d(void *_glfuncs, GLdouble s, GLdouble t, GLdouble r)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glTexCoord3d(s, t, r);
+}
+
+void gl3_0_glTexCoord2sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glTexCoord2sv(v);
+}
+
+void gl3_0_glTexCoord2s(void *_glfuncs, GLshort s, GLshort t)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glTexCoord2s(s, t);
+}
+
+void gl3_0_glTexCoord2iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glTexCoord2iv(v);
+}
+
+void gl3_0_glTexCoord2i(void *_glfuncs, GLint s, GLint t)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glTexCoord2i(s, t);
+}
+
+void gl3_0_glTexCoord2fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glTexCoord2fv(v);
+}
+
+void gl3_0_glTexCoord2f(void *_glfuncs, GLfloat s, GLfloat t)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glTexCoord2f(s, t);
+}
+
+void gl3_0_glTexCoord2dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glTexCoord2dv(v);
+}
+
+void gl3_0_glTexCoord2d(void *_glfuncs, GLdouble s, GLdouble t)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glTexCoord2d(s, t);
+}
+
+void gl3_0_glTexCoord1sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glTexCoord1sv(v);
+}
+
+void gl3_0_glTexCoord1s(void *_glfuncs, GLshort s)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glTexCoord1s(s);
+}
+
+void gl3_0_glTexCoord1iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glTexCoord1iv(v);
+}
+
+void gl3_0_glTexCoord1i(void *_glfuncs, GLint s)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glTexCoord1i(s);
+}
+
+void gl3_0_glTexCoord1fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glTexCoord1fv(v);
+}
+
+void gl3_0_glTexCoord1f(void *_glfuncs, GLfloat s)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glTexCoord1f(s);
+}
+
+void gl3_0_glTexCoord1dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glTexCoord1dv(v);
+}
+
+void gl3_0_glTexCoord1d(void *_glfuncs, GLdouble s)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glTexCoord1d(s);
+}
+
+void gl3_0_glRectsv(void *_glfuncs, const GLshort* v1, const GLshort* v2)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glRectsv(v1, v2);
+}
+
+void gl3_0_glRects(void *_glfuncs, GLshort x1, GLshort y1, GLshort x2, GLshort y2)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glRects(x1, y1, x2, y2);
+}
+
+void gl3_0_glRectiv(void *_glfuncs, const GLint* v1, const GLint* v2)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glRectiv(v1, v2);
+}
+
+void gl3_0_glRecti(void *_glfuncs, GLint x1, GLint y1, GLint x2, GLint y2)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glRecti(x1, y1, x2, y2);
+}
+
+void gl3_0_glRectfv(void *_glfuncs, const GLfloat* v1, const GLfloat* v2)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glRectfv(v1, v2);
+}
+
+void gl3_0_glRectf(void *_glfuncs, GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glRectf(x1, y1, x2, y2);
+}
+
+void gl3_0_glRectdv(void *_glfuncs, const GLdouble* v1, const GLdouble* v2)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glRectdv(v1, v2);
+}
+
+void gl3_0_glRectd(void *_glfuncs, GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glRectd(x1, y1, x2, y2);
+}
+
+void gl3_0_glRasterPos4sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glRasterPos4sv(v);
+}
+
+void gl3_0_glRasterPos4s(void *_glfuncs, GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glRasterPos4s(x, y, z, w);
+}
+
+void gl3_0_glRasterPos4iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glRasterPos4iv(v);
+}
+
+void gl3_0_glRasterPos4i(void *_glfuncs, GLint x, GLint y, GLint z, GLint w)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glRasterPos4i(x, y, z, w);
+}
+
+void gl3_0_glRasterPos4fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glRasterPos4fv(v);
+}
+
+void gl3_0_glRasterPos4f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glRasterPos4f(x, y, z, w);
+}
+
+void gl3_0_glRasterPos4dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glRasterPos4dv(v);
+}
+
+void gl3_0_glRasterPos4d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glRasterPos4d(x, y, z, w);
+}
+
+void gl3_0_glRasterPos3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glRasterPos3sv(v);
+}
+
+void gl3_0_glRasterPos3s(void *_glfuncs, GLshort x, GLshort y, GLshort z)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glRasterPos3s(x, y, z);
+}
+
+void gl3_0_glRasterPos3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glRasterPos3iv(v);
+}
+
+void gl3_0_glRasterPos3i(void *_glfuncs, GLint x, GLint y, GLint z)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glRasterPos3i(x, y, z);
+}
+
+void gl3_0_glRasterPos3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glRasterPos3fv(v);
+}
+
+void gl3_0_glRasterPos3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glRasterPos3f(x, y, z);
+}
+
+void gl3_0_glRasterPos3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glRasterPos3dv(v);
+}
+
+void gl3_0_glRasterPos3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glRasterPos3d(x, y, z);
+}
+
+void gl3_0_glRasterPos2sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glRasterPos2sv(v);
+}
+
+void gl3_0_glRasterPos2s(void *_glfuncs, GLshort x, GLshort y)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glRasterPos2s(x, y);
+}
+
+void gl3_0_glRasterPos2iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glRasterPos2iv(v);
+}
+
+void gl3_0_glRasterPos2i(void *_glfuncs, GLint x, GLint y)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glRasterPos2i(x, y);
+}
+
+void gl3_0_glRasterPos2fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glRasterPos2fv(v);
+}
+
+void gl3_0_glRasterPos2f(void *_glfuncs, GLfloat x, GLfloat y)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glRasterPos2f(x, y);
+}
+
+void gl3_0_glRasterPos2dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glRasterPos2dv(v);
+}
+
+void gl3_0_glRasterPos2d(void *_glfuncs, GLdouble x, GLdouble y)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glRasterPos2d(x, y);
+}
+
+void gl3_0_glNormal3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glNormal3sv(v);
+}
+
+void gl3_0_glNormal3s(void *_glfuncs, GLshort nx, GLshort ny, GLshort nz)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glNormal3s(nx, ny, nz);
+}
+
+void gl3_0_glNormal3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glNormal3iv(v);
+}
+
+void gl3_0_glNormal3i(void *_glfuncs, GLint nx, GLint ny, GLint nz)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glNormal3i(nx, ny, nz);
+}
+
+void gl3_0_glNormal3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glNormal3fv(v);
+}
+
+void gl3_0_glNormal3f(void *_glfuncs, GLfloat nx, GLfloat ny, GLfloat nz)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glNormal3f(nx, ny, nz);
+}
+
+void gl3_0_glNormal3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glNormal3dv(v);
+}
+
+void gl3_0_glNormal3d(void *_glfuncs, GLdouble nx, GLdouble ny, GLdouble nz)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glNormal3d(nx, ny, nz);
+}
+
+void gl3_0_glNormal3bv(void *_glfuncs, const GLbyte* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glNormal3bv(v);
+}
+
+void gl3_0_glNormal3b(void *_glfuncs, GLbyte nx, GLbyte ny, GLbyte nz)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glNormal3b(nx, ny, nz);
+}
+
+void gl3_0_glIndexsv(void *_glfuncs, const GLshort* c)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glIndexsv(c);
+}
+
+void gl3_0_glIndexs(void *_glfuncs, GLshort c)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glIndexs(c);
+}
+
+void gl3_0_glIndexiv(void *_glfuncs, const GLint* c)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glIndexiv(c);
+}
+
+void gl3_0_glIndexi(void *_glfuncs, GLint c)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glIndexi(c);
+}
+
+void gl3_0_glIndexfv(void *_glfuncs, const GLfloat* c)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glIndexfv(c);
+}
+
+void gl3_0_glIndexf(void *_glfuncs, GLfloat c)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glIndexf(c);
+}
+
+void gl3_0_glIndexdv(void *_glfuncs, const GLdouble* c)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glIndexdv(c);
+}
+
+void gl3_0_glIndexd(void *_glfuncs, GLdouble c)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glIndexd(c);
+}
+
+void gl3_0_glEnd(void *_glfuncs)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glEnd();
+}
+
+void gl3_0_glEdgeFlagv(void *_glfuncs, const GLboolean* flag)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glEdgeFlagv(flag);
+}
+
+void gl3_0_glEdgeFlag(void *_glfuncs, GLboolean flag)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glEdgeFlag(flag);
+}
+
+void gl3_0_glColor4usv(void *_glfuncs, const GLushort* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glColor4usv(v);
+}
+
+void gl3_0_glColor4us(void *_glfuncs, GLushort red, GLushort green, GLushort blue, GLushort alpha)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glColor4us(red, green, blue, alpha);
+}
+
+void gl3_0_glColor4uiv(void *_glfuncs, const GLuint* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glColor4uiv(v);
+}
+
+void gl3_0_glColor4ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue, GLuint alpha)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glColor4ui(red, green, blue, alpha);
+}
+
+void gl3_0_glColor4ubv(void *_glfuncs, const GLubyte* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glColor4ubv(v);
+}
+
+void gl3_0_glColor4ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glColor4ub(red, green, blue, alpha);
+}
+
+void gl3_0_glColor4sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glColor4sv(v);
+}
+
+void gl3_0_glColor4s(void *_glfuncs, GLshort red, GLshort green, GLshort blue, GLshort alpha)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glColor4s(red, green, blue, alpha);
+}
+
+void gl3_0_glColor4iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glColor4iv(v);
+}
+
+void gl3_0_glColor4i(void *_glfuncs, GLint red, GLint green, GLint blue, GLint alpha)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glColor4i(red, green, blue, alpha);
+}
+
+void gl3_0_glColor4fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glColor4fv(v);
+}
+
+void gl3_0_glColor4f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glColor4f(red, green, blue, alpha);
+}
+
+void gl3_0_glColor4dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glColor4dv(v);
+}
+
+void gl3_0_glColor4d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glColor4d(red, green, blue, alpha);
+}
+
+void gl3_0_glColor4bv(void *_glfuncs, const GLbyte* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glColor4bv(v);
+}
+
+void gl3_0_glColor4b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glColor4b(red, green, blue, alpha);
+}
+
+void gl3_0_glColor3usv(void *_glfuncs, const GLushort* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glColor3usv(v);
+}
+
+void gl3_0_glColor3us(void *_glfuncs, GLushort red, GLushort green, GLushort blue)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glColor3us(red, green, blue);
+}
+
+void gl3_0_glColor3uiv(void *_glfuncs, const GLuint* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glColor3uiv(v);
+}
+
+void gl3_0_glColor3ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glColor3ui(red, green, blue);
+}
+
+void gl3_0_glColor3ubv(void *_glfuncs, const GLubyte* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glColor3ubv(v);
+}
+
+void gl3_0_glColor3ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glColor3ub(red, green, blue);
+}
+
+void gl3_0_glColor3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glColor3sv(v);
+}
+
+void gl3_0_glColor3s(void *_glfuncs, GLshort red, GLshort green, GLshort blue)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glColor3s(red, green, blue);
+}
+
+void gl3_0_glColor3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glColor3iv(v);
+}
+
+void gl3_0_glColor3i(void *_glfuncs, GLint red, GLint green, GLint blue)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glColor3i(red, green, blue);
+}
+
+void gl3_0_glColor3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glColor3fv(v);
+}
+
+void gl3_0_glColor3f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glColor3f(red, green, blue);
+}
+
+void gl3_0_glColor3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glColor3dv(v);
+}
+
+void gl3_0_glColor3d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glColor3d(red, green, blue);
+}
+
+void gl3_0_glColor3bv(void *_glfuncs, const GLbyte* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glColor3bv(v);
+}
+
+void gl3_0_glColor3b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glColor3b(red, green, blue);
+}
+
+void gl3_0_glBitmap(void *_glfuncs, GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte* bitmap)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glBitmap(width, height, xorig, yorig, xmove, ymove, bitmap);
+}
+
+void gl3_0_glBegin(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glBegin(mode);
+}
+
+void gl3_0_glListBase(void *_glfuncs, GLuint base)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glListBase(base);
+}
+
+GLuint gl3_0_glGenLists(void *_glfuncs, GLsizei range_)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ return _qglfuncs->glGenLists(range_);
+}
+
+void gl3_0_glDeleteLists(void *_glfuncs, GLuint list, GLsizei range_)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glDeleteLists(list, range_);
+}
+
+void gl3_0_glCallLists(void *_glfuncs, GLsizei n, GLenum gltype, const GLvoid* lists)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glCallLists(n, gltype, lists);
+}
+
+void gl3_0_glCallList(void *_glfuncs, GLuint list)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glCallList(list);
+}
+
+void gl3_0_glEndList(void *_glfuncs)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glEndList();
+}
+
+void gl3_0_glNewList(void *_glfuncs, GLuint list, GLenum mode)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glNewList(list, mode);
+}
+
+void gl3_0_glPushClientAttrib(void *_glfuncs, GLbitfield mask)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glPushClientAttrib(mask);
+}
+
+void gl3_0_glPopClientAttrib(void *_glfuncs)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glPopClientAttrib();
+}
+
+void gl3_0_glPrioritizeTextures(void *_glfuncs, GLsizei n, const GLuint* textures, const GLfloat* priorities)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glPrioritizeTextures(n, textures, priorities);
+}
+
+GLboolean gl3_0_glAreTexturesResident(void *_glfuncs, GLsizei n, const GLuint* textures, GLboolean* residences)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ return _qglfuncs->glAreTexturesResident(n, textures, residences);
+}
+
+void gl3_0_glVertexPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertexPointer(size, gltype, stride, pointer);
+}
+
+void gl3_0_glTexCoordPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glTexCoordPointer(size, gltype, stride, pointer);
+}
+
+void gl3_0_glNormalPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glNormalPointer(gltype, stride, pointer);
+}
+
+void gl3_0_glInterleavedArrays(void *_glfuncs, GLenum format, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glInterleavedArrays(format, stride, pointer);
+}
+
+void gl3_0_glIndexPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glIndexPointer(gltype, stride, pointer);
+}
+
+void gl3_0_glEnableClientState(void *_glfuncs, GLenum array)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glEnableClientState(array);
+}
+
+void gl3_0_glEdgeFlagPointer(void *_glfuncs, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glEdgeFlagPointer(stride, pointer);
+}
+
+void gl3_0_glDisableClientState(void *_glfuncs, GLenum array)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glDisableClientState(array);
+}
+
+void gl3_0_glColorPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glColorPointer(size, gltype, stride, pointer);
+}
+
+void gl3_0_glArrayElement(void *_glfuncs, GLint i)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glArrayElement(i);
+}
+
+void gl3_0_glResetMinmax(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glResetMinmax(target);
+}
+
+void gl3_0_glResetHistogram(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glResetHistogram(target);
+}
+
+void gl3_0_glMinmax(void *_glfuncs, GLenum target, GLenum internalFormat, GLboolean sink)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glMinmax(target, internalFormat, sink);
+}
+
+void gl3_0_glHistogram(void *_glfuncs, GLenum target, GLsizei width, GLenum internalFormat, GLboolean sink)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glHistogram(target, width, internalFormat, sink);
+}
+
+void gl3_0_glGetMinmaxParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetMinmaxParameteriv(target, pname, params);
+}
+
+void gl3_0_glGetMinmaxParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetMinmaxParameterfv(target, pname, params);
+}
+
+void gl3_0_glGetMinmax(void *_glfuncs, GLenum target, GLboolean reset, GLenum format, GLenum gltype, GLvoid* values)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetMinmax(target, reset, format, gltype, values);
+}
+
+void gl3_0_glGetHistogramParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetHistogramParameteriv(target, pname, params);
+}
+
+void gl3_0_glGetHistogramParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetHistogramParameterfv(target, pname, params);
+}
+
+void gl3_0_glGetHistogram(void *_glfuncs, GLenum target, GLboolean reset, GLenum format, GLenum gltype, GLvoid* values)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetHistogram(target, reset, format, gltype, values);
+}
+
+void gl3_0_glSeparableFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* row, const GLvoid* column)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glSeparableFilter2D(target, internalFormat, width, height, format, gltype, row, column);
+}
+
+void gl3_0_glGetSeparableFilter(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* row, GLvoid* column, GLvoid* span)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetSeparableFilter(target, format, gltype, row, column, span);
+}
+
+void gl3_0_glGetConvolutionParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetConvolutionParameteriv(target, pname, params);
+}
+
+void gl3_0_glGetConvolutionParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetConvolutionParameterfv(target, pname, params);
+}
+
+void gl3_0_glGetConvolutionFilter(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* image)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetConvolutionFilter(target, format, gltype, image);
+}
+
+void gl3_0_glCopyConvolutionFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glCopyConvolutionFilter2D(target, internalFormat, x, y, width, height);
+}
+
+void gl3_0_glCopyConvolutionFilter1D(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glCopyConvolutionFilter1D(target, internalFormat, x, y, width);
+}
+
+void gl3_0_glConvolutionParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glConvolutionParameteriv(target, pname, params);
+}
+
+void gl3_0_glConvolutionParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glConvolutionParameteri(target, pname, params);
+}
+
+void gl3_0_glConvolutionParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glConvolutionParameterfv(target, pname, params);
+}
+
+void gl3_0_glConvolutionParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glConvolutionParameterf(target, pname, params);
+}
+
+void gl3_0_glConvolutionFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* image)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glConvolutionFilter2D(target, internalFormat, width, height, format, gltype, image);
+}
+
+void gl3_0_glConvolutionFilter1D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLenum format, GLenum gltype, const GLvoid* image)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glConvolutionFilter1D(target, internalFormat, width, format, gltype, image);
+}
+
+void gl3_0_glCopyColorSubTable(void *_glfuncs, GLenum target, GLsizei start, GLint x, GLint y, GLsizei width)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glCopyColorSubTable(target, start, x, y, width);
+}
+
+void gl3_0_glColorSubTable(void *_glfuncs, GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum gltype, const GLvoid* data)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glColorSubTable(target, start, count, format, gltype, data);
+}
+
+void gl3_0_glGetColorTableParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetColorTableParameteriv(target, pname, params);
+}
+
+void gl3_0_glGetColorTableParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetColorTableParameterfv(target, pname, params);
+}
+
+void gl3_0_glGetColorTable(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* table)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glGetColorTable(target, format, gltype, table);
+}
+
+void gl3_0_glCopyColorTable(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glCopyColorTable(target, internalFormat, x, y, width);
+}
+
+void gl3_0_glColorTableParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glColorTableParameteriv(target, pname, params);
+}
+
+void gl3_0_glColorTableParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glColorTableParameterfv(target, pname, params);
+}
+
+void gl3_0_glColorTable(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLenum format, GLenum gltype, const GLvoid* table)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glColorTable(target, internalFormat, width, format, gltype, table);
+}
+
+void gl3_0_glMultTransposeMatrixd(void *_glfuncs, const GLdouble* m)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glMultTransposeMatrixd(m);
+}
+
+void gl3_0_glMultTransposeMatrixf(void *_glfuncs, const GLfloat* m)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glMultTransposeMatrixf(m);
+}
+
+void gl3_0_glLoadTransposeMatrixd(void *_glfuncs, const GLdouble* m)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glLoadTransposeMatrixd(m);
+}
+
+void gl3_0_glLoadTransposeMatrixf(void *_glfuncs, const GLfloat* m)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glLoadTransposeMatrixf(m);
+}
+
+void gl3_0_glMultiTexCoord4sv(void *_glfuncs, GLenum target, const GLshort* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4sv(target, v);
+}
+
+void gl3_0_glMultiTexCoord4s(void *_glfuncs, GLenum target, GLshort s, GLshort t, GLshort r, GLshort q)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4s(target, s, t, r, q);
+}
+
+void gl3_0_glMultiTexCoord4iv(void *_glfuncs, GLenum target, const GLint* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4iv(target, v);
+}
+
+void gl3_0_glMultiTexCoord4i(void *_glfuncs, GLenum target, GLint s, GLint t, GLint r, GLint q)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4i(target, s, t, r, q);
+}
+
+void gl3_0_glMultiTexCoord4fv(void *_glfuncs, GLenum target, const GLfloat* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4fv(target, v);
+}
+
+void gl3_0_glMultiTexCoord4f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4f(target, s, t, r, q);
+}
+
+void gl3_0_glMultiTexCoord4dv(void *_glfuncs, GLenum target, const GLdouble* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4dv(target, v);
+}
+
+void gl3_0_glMultiTexCoord4d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4d(target, s, t, r, q);
+}
+
+void gl3_0_glMultiTexCoord3sv(void *_glfuncs, GLenum target, const GLshort* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3sv(target, v);
+}
+
+void gl3_0_glMultiTexCoord3s(void *_glfuncs, GLenum target, GLshort s, GLshort t, GLshort r)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3s(target, s, t, r);
+}
+
+void gl3_0_glMultiTexCoord3iv(void *_glfuncs, GLenum target, const GLint* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3iv(target, v);
+}
+
+void gl3_0_glMultiTexCoord3i(void *_glfuncs, GLenum target, GLint s, GLint t, GLint r)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3i(target, s, t, r);
+}
+
+void gl3_0_glMultiTexCoord3fv(void *_glfuncs, GLenum target, const GLfloat* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3fv(target, v);
+}
+
+void gl3_0_glMultiTexCoord3f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t, GLfloat r)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3f(target, s, t, r);
+}
+
+void gl3_0_glMultiTexCoord3dv(void *_glfuncs, GLenum target, const GLdouble* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3dv(target, v);
+}
+
+void gl3_0_glMultiTexCoord3d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t, GLdouble r)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3d(target, s, t, r);
+}
+
+void gl3_0_glMultiTexCoord2sv(void *_glfuncs, GLenum target, const GLshort* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2sv(target, v);
+}
+
+void gl3_0_glMultiTexCoord2s(void *_glfuncs, GLenum target, GLshort s, GLshort t)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2s(target, s, t);
+}
+
+void gl3_0_glMultiTexCoord2iv(void *_glfuncs, GLenum target, const GLint* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2iv(target, v);
+}
+
+void gl3_0_glMultiTexCoord2i(void *_glfuncs, GLenum target, GLint s, GLint t)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2i(target, s, t);
+}
+
+void gl3_0_glMultiTexCoord2fv(void *_glfuncs, GLenum target, const GLfloat* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2fv(target, v);
+}
+
+void gl3_0_glMultiTexCoord2f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2f(target, s, t);
+}
+
+void gl3_0_glMultiTexCoord2dv(void *_glfuncs, GLenum target, const GLdouble* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2dv(target, v);
+}
+
+void gl3_0_glMultiTexCoord2d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2d(target, s, t);
+}
+
+void gl3_0_glMultiTexCoord1sv(void *_glfuncs, GLenum target, const GLshort* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1sv(target, v);
+}
+
+void gl3_0_glMultiTexCoord1s(void *_glfuncs, GLenum target, GLshort s)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1s(target, s);
+}
+
+void gl3_0_glMultiTexCoord1iv(void *_glfuncs, GLenum target, const GLint* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1iv(target, v);
+}
+
+void gl3_0_glMultiTexCoord1i(void *_glfuncs, GLenum target, GLint s)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1i(target, s);
+}
+
+void gl3_0_glMultiTexCoord1fv(void *_glfuncs, GLenum target, const GLfloat* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1fv(target, v);
+}
+
+void gl3_0_glMultiTexCoord1f(void *_glfuncs, GLenum target, GLfloat s)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1f(target, s);
+}
+
+void gl3_0_glMultiTexCoord1dv(void *_glfuncs, GLenum target, const GLdouble* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1dv(target, v);
+}
+
+void gl3_0_glMultiTexCoord1d(void *_glfuncs, GLenum target, GLdouble s)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1d(target, s);
+}
+
+void gl3_0_glClientActiveTexture(void *_glfuncs, GLenum texture)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glClientActiveTexture(texture);
+}
+
+void gl3_0_glWindowPos3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glWindowPos3sv(v);
+}
+
+void gl3_0_glWindowPos3s(void *_glfuncs, GLshort x, GLshort y, GLshort z)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glWindowPos3s(x, y, z);
+}
+
+void gl3_0_glWindowPos3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glWindowPos3iv(v);
+}
+
+void gl3_0_glWindowPos3i(void *_glfuncs, GLint x, GLint y, GLint z)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glWindowPos3i(x, y, z);
+}
+
+void gl3_0_glWindowPos3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glWindowPos3fv(v);
+}
+
+void gl3_0_glWindowPos3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glWindowPos3f(x, y, z);
+}
+
+void gl3_0_glWindowPos3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glWindowPos3dv(v);
+}
+
+void gl3_0_glWindowPos3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glWindowPos3d(x, y, z);
+}
+
+void gl3_0_glWindowPos2sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glWindowPos2sv(v);
+}
+
+void gl3_0_glWindowPos2s(void *_glfuncs, GLshort x, GLshort y)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glWindowPos2s(x, y);
+}
+
+void gl3_0_glWindowPos2iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glWindowPos2iv(v);
+}
+
+void gl3_0_glWindowPos2i(void *_glfuncs, GLint x, GLint y)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glWindowPos2i(x, y);
+}
+
+void gl3_0_glWindowPos2fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glWindowPos2fv(v);
+}
+
+void gl3_0_glWindowPos2f(void *_glfuncs, GLfloat x, GLfloat y)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glWindowPos2f(x, y);
+}
+
+void gl3_0_glWindowPos2dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glWindowPos2dv(v);
+}
+
+void gl3_0_glWindowPos2d(void *_glfuncs, GLdouble x, GLdouble y)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glWindowPos2d(x, y);
+}
+
+void gl3_0_glSecondaryColorPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glSecondaryColorPointer(size, gltype, stride, pointer);
+}
+
+void gl3_0_glSecondaryColor3usv(void *_glfuncs, const GLushort* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3usv(v);
+}
+
+void gl3_0_glSecondaryColor3us(void *_glfuncs, GLushort red, GLushort green, GLushort blue)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3us(red, green, blue);
+}
+
+void gl3_0_glSecondaryColor3uiv(void *_glfuncs, const GLuint* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3uiv(v);
+}
+
+void gl3_0_glSecondaryColor3ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3ui(red, green, blue);
+}
+
+void gl3_0_glSecondaryColor3ubv(void *_glfuncs, const GLubyte* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3ubv(v);
+}
+
+void gl3_0_glSecondaryColor3ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3ub(red, green, blue);
+}
+
+void gl3_0_glSecondaryColor3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3sv(v);
+}
+
+void gl3_0_glSecondaryColor3s(void *_glfuncs, GLshort red, GLshort green, GLshort blue)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3s(red, green, blue);
+}
+
+void gl3_0_glSecondaryColor3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3iv(v);
+}
+
+void gl3_0_glSecondaryColor3i(void *_glfuncs, GLint red, GLint green, GLint blue)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3i(red, green, blue);
+}
+
+void gl3_0_glSecondaryColor3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3fv(v);
+}
+
+void gl3_0_glSecondaryColor3f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3f(red, green, blue);
+}
+
+void gl3_0_glSecondaryColor3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3dv(v);
+}
+
+void gl3_0_glSecondaryColor3d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3d(red, green, blue);
+}
+
+void gl3_0_glSecondaryColor3bv(void *_glfuncs, const GLbyte* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3bv(v);
+}
+
+void gl3_0_glSecondaryColor3b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3b(red, green, blue);
+}
+
+void gl3_0_glFogCoordPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glFogCoordPointer(gltype, stride, pointer);
+}
+
+void gl3_0_glFogCoorddv(void *_glfuncs, const GLdouble* coord)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glFogCoorddv(coord);
+}
+
+void gl3_0_glFogCoordd(void *_glfuncs, GLdouble coord)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glFogCoordd(coord);
+}
+
+void gl3_0_glFogCoordfv(void *_glfuncs, const GLfloat* coord)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glFogCoordfv(coord);
+}
+
+void gl3_0_glFogCoordf(void *_glfuncs, GLfloat coord)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glFogCoordf(coord);
+}
+
+void gl3_0_glVertexAttrib4usv(void *_glfuncs, GLuint index, const GLushort* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4usv(index, v);
+}
+
+void gl3_0_glVertexAttrib4uiv(void *_glfuncs, GLuint index, const GLuint* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4uiv(index, v);
+}
+
+void gl3_0_glVertexAttrib4ubv(void *_glfuncs, GLuint index, const GLubyte* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4ubv(index, v);
+}
+
+void gl3_0_glVertexAttrib4sv(void *_glfuncs, GLuint index, const GLshort* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4sv(index, v);
+}
+
+void gl3_0_glVertexAttrib4s(void *_glfuncs, GLuint index, GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4s(index, x, y, z, w);
+}
+
+void gl3_0_glVertexAttrib4iv(void *_glfuncs, GLuint index, const GLint* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4iv(index, v);
+}
+
+void gl3_0_glVertexAttrib4fv(void *_glfuncs, GLuint index, const GLfloat* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4fv(index, v);
+}
+
+void gl3_0_glVertexAttrib4f(void *_glfuncs, GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4f(index, x, y, z, w);
+}
+
+void gl3_0_glVertexAttrib4dv(void *_glfuncs, GLuint index, const GLdouble* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4dv(index, v);
+}
+
+void gl3_0_glVertexAttrib4d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4d(index, x, y, z, w);
+}
+
+void gl3_0_glVertexAttrib4bv(void *_glfuncs, GLuint index, const GLbyte* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4bv(index, v);
+}
+
+void gl3_0_glVertexAttrib4Nusv(void *_glfuncs, GLuint index, const GLushort* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Nusv(index, v);
+}
+
+void gl3_0_glVertexAttrib4Nuiv(void *_glfuncs, GLuint index, const GLuint* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Nuiv(index, v);
+}
+
+void gl3_0_glVertexAttrib4Nubv(void *_glfuncs, GLuint index, const GLubyte* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Nubv(index, v);
+}
+
+void gl3_0_glVertexAttrib4Nub(void *_glfuncs, GLuint index, GLubyte x, GLubyte y, GLubyte z, GLubyte w)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Nub(index, x, y, z, w);
+}
+
+void gl3_0_glVertexAttrib4Nsv(void *_glfuncs, GLuint index, const GLshort* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Nsv(index, v);
+}
+
+void gl3_0_glVertexAttrib4Niv(void *_glfuncs, GLuint index, const GLint* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Niv(index, v);
+}
+
+void gl3_0_glVertexAttrib4Nbv(void *_glfuncs, GLuint index, const GLbyte* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Nbv(index, v);
+}
+
+void gl3_0_glVertexAttrib3sv(void *_glfuncs, GLuint index, const GLshort* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib3sv(index, v);
+}
+
+void gl3_0_glVertexAttrib3s(void *_glfuncs, GLuint index, GLshort x, GLshort y, GLshort z)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib3s(index, x, y, z);
+}
+
+void gl3_0_glVertexAttrib3fv(void *_glfuncs, GLuint index, const GLfloat* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib3fv(index, v);
+}
+
+void gl3_0_glVertexAttrib3f(void *_glfuncs, GLuint index, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib3f(index, x, y, z);
+}
+
+void gl3_0_glVertexAttrib3dv(void *_glfuncs, GLuint index, const GLdouble* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib3dv(index, v);
+}
+
+void gl3_0_glVertexAttrib3d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib3d(index, x, y, z);
+}
+
+void gl3_0_glVertexAttrib2sv(void *_glfuncs, GLuint index, const GLshort* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib2sv(index, v);
+}
+
+void gl3_0_glVertexAttrib2s(void *_glfuncs, GLuint index, GLshort x, GLshort y)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib2s(index, x, y);
+}
+
+void gl3_0_glVertexAttrib2fv(void *_glfuncs, GLuint index, const GLfloat* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib2fv(index, v);
+}
+
+void gl3_0_glVertexAttrib2f(void *_glfuncs, GLuint index, GLfloat x, GLfloat y)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib2f(index, x, y);
+}
+
+void gl3_0_glVertexAttrib2dv(void *_glfuncs, GLuint index, const GLdouble* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib2dv(index, v);
+}
+
+void gl3_0_glVertexAttrib2d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib2d(index, x, y);
+}
+
+void gl3_0_glVertexAttrib1sv(void *_glfuncs, GLuint index, const GLshort* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib1sv(index, v);
+}
+
+void gl3_0_glVertexAttrib1s(void *_glfuncs, GLuint index, GLshort x)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib1s(index, x);
+}
+
+void gl3_0_glVertexAttrib1fv(void *_glfuncs, GLuint index, const GLfloat* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib1fv(index, v);
+}
+
+void gl3_0_glVertexAttrib1f(void *_glfuncs, GLuint index, GLfloat x)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib1f(index, x);
+}
+
+void gl3_0_glVertexAttrib1dv(void *_glfuncs, GLuint index, const GLdouble* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib1dv(index, v);
+}
+
+void gl3_0_glVertexAttrib1d(void *_glfuncs, GLuint index, GLdouble x)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertexAttrib1d(index, x);
+}
+
+void gl3_0_glVertexAttribI4usv(void *_glfuncs, GLuint index, const GLushort* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertexAttribI4usv(index, v);
+}
+
+void gl3_0_glVertexAttribI4ubv(void *_glfuncs, GLuint index, const GLubyte* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertexAttribI4ubv(index, v);
+}
+
+void gl3_0_glVertexAttribI4sv(void *_glfuncs, GLuint index, const GLshort* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertexAttribI4sv(index, v);
+}
+
+void gl3_0_glVertexAttribI4bv(void *_glfuncs, GLuint index, const GLbyte* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertexAttribI4bv(index, v);
+}
+
+void gl3_0_glVertexAttribI4uiv(void *_glfuncs, GLuint index, const GLuint* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertexAttribI4uiv(index, v);
+}
+
+void gl3_0_glVertexAttribI3uiv(void *_glfuncs, GLuint index, const GLuint* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertexAttribI3uiv(index, v);
+}
+
+void gl3_0_glVertexAttribI2uiv(void *_glfuncs, GLuint index, const GLuint* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertexAttribI2uiv(index, v);
+}
+
+void gl3_0_glVertexAttribI1uiv(void *_glfuncs, GLuint index, const GLuint* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertexAttribI1uiv(index, v);
+}
+
+void gl3_0_glVertexAttribI4iv(void *_glfuncs, GLuint index, const GLint* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertexAttribI4iv(index, v);
+}
+
+void gl3_0_glVertexAttribI3iv(void *_glfuncs, GLuint index, const GLint* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertexAttribI3iv(index, v);
+}
+
+void gl3_0_glVertexAttribI2iv(void *_glfuncs, GLuint index, const GLint* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertexAttribI2iv(index, v);
+}
+
+void gl3_0_glVertexAttribI1iv(void *_glfuncs, GLuint index, const GLint* v)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertexAttribI1iv(index, v);
+}
+
+void gl3_0_glVertexAttribI4ui(void *_glfuncs, GLuint index, GLuint x, GLuint y, GLuint z, GLuint w)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertexAttribI4ui(index, x, y, z, w);
+}
+
+void gl3_0_glVertexAttribI3ui(void *_glfuncs, GLuint index, GLuint x, GLuint y, GLuint z)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertexAttribI3ui(index, x, y, z);
+}
+
+void gl3_0_glVertexAttribI2ui(void *_glfuncs, GLuint index, GLuint x, GLuint y)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertexAttribI2ui(index, x, y);
+}
+
+void gl3_0_glVertexAttribI1ui(void *_glfuncs, GLuint index, GLuint x)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertexAttribI1ui(index, x);
+}
+
+void gl3_0_glVertexAttribI4i(void *_glfuncs, GLuint index, GLint x, GLint y, GLint z, GLint w)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertexAttribI4i(index, x, y, z, w);
+}
+
+void gl3_0_glVertexAttribI3i(void *_glfuncs, GLuint index, GLint x, GLint y, GLint z)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertexAttribI3i(index, x, y, z);
+}
+
+void gl3_0_glVertexAttribI2i(void *_glfuncs, GLuint index, GLint x, GLint y)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertexAttribI2i(index, x, y);
+}
+
+void gl3_0_glVertexAttribI1i(void *_glfuncs, GLuint index, GLint x)
+{
+ QOpenGLFunctions_3_0* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_0*>(_glfuncs);
+ _qglfuncs->glVertexAttribI1i(index, x);
+}
+
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/3.0/funcs.h b/Godeps/_workspace/src/github.com/obscuren/qml/gl/3.0/funcs.h
new file mode 100644
index 000000000..81db33a9b
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/3.0/funcs.h
@@ -0,0 +1,700 @@
+
+// ** file automatically generated by glgen -- do not edit manually **
+
+#ifndef __cplusplus
+#include <inttypes.h>
+#include <stddef.h>
+typedef unsigned int GLenum;
+typedef unsigned char GLboolean;
+typedef unsigned int GLbitfield;
+typedef void GLvoid;
+typedef char GLchar;
+typedef signed char GLbyte; /* 1-byte signed */
+typedef short GLshort; /* 2-byte signed */
+typedef int GLint; /* 4-byte signed */
+typedef unsigned char GLubyte; /* 1-byte unsigned */
+typedef unsigned short GLushort; /* 2-byte unsigned */
+typedef unsigned int GLuint; /* 4-byte unsigned */
+typedef int GLsizei; /* 4-byte signed */
+typedef float GLfloat; /* single precision float */
+typedef float GLclampf; /* single precision float in [0,1] */
+typedef double GLdouble; /* double precision float */
+typedef double GLclampd; /* double precision float in [0,1] */
+typedef int64_t GLint64;
+typedef uint64_t GLuint64;
+typedef ptrdiff_t GLintptr;
+typedef ptrdiff_t GLsizeiptr;
+typedef ptrdiff_t GLintptrARB;
+typedef ptrdiff_t GLsizeiptrARB;
+typedef struct __GLsync *GLsync;
+#endif
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+void *gl3_0_funcs();
+
+void gl3_0_glViewport(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl3_0_glDepthRange(void *_glfuncs, GLdouble nearVal, GLdouble farVal);
+GLboolean gl3_0_glIsEnabled(void *_glfuncs, GLenum cap);
+void gl3_0_glGetTexLevelParameteriv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLint* params);
+void gl3_0_glGetTexLevelParameterfv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLfloat* params);
+void gl3_0_glGetTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl3_0_glGetTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl3_0_glGetTexImage(void *_glfuncs, GLenum target, GLint level, GLenum format, GLenum gltype, GLvoid* pixels);
+void gl3_0_glGetIntegerv(void *_glfuncs, GLenum pname, GLint* params);
+void gl3_0_glGetFloatv(void *_glfuncs, GLenum pname, GLfloat* params);
+GLenum gl3_0_glGetError(void *_glfuncs);
+void gl3_0_glGetDoublev(void *_glfuncs, GLenum pname, GLdouble* params);
+void gl3_0_glGetBooleanv(void *_glfuncs, GLenum pname, GLboolean* params);
+void gl3_0_glReadPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum gltype, GLvoid* pixels);
+void gl3_0_glReadBuffer(void *_glfuncs, GLenum mode);
+void gl3_0_glPixelStorei(void *_glfuncs, GLenum pname, GLint param);
+void gl3_0_glPixelStoref(void *_glfuncs, GLenum pname, GLfloat param);
+void gl3_0_glDepthFunc(void *_glfuncs, GLenum glfunc);
+void gl3_0_glStencilOp(void *_glfuncs, GLenum fail, GLenum zfail, GLenum zpass);
+void gl3_0_glStencilFunc(void *_glfuncs, GLenum glfunc, GLint ref, GLuint mask);
+void gl3_0_glLogicOp(void *_glfuncs, GLenum opcode);
+void gl3_0_glBlendFunc(void *_glfuncs, GLenum sfactor, GLenum dfactor);
+void gl3_0_glFlush(void *_glfuncs);
+void gl3_0_glFinish(void *_glfuncs);
+void gl3_0_glEnable(void *_glfuncs, GLenum cap);
+void gl3_0_glDisable(void *_glfuncs, GLenum cap);
+void gl3_0_glDepthMask(void *_glfuncs, GLboolean flag);
+void gl3_0_glColorMask(void *_glfuncs, GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha);
+void gl3_0_glStencilMask(void *_glfuncs, GLuint mask);
+void gl3_0_glClearDepth(void *_glfuncs, GLdouble depth);
+void gl3_0_glClearStencil(void *_glfuncs, GLint s);
+void gl3_0_glClearColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl3_0_glClear(void *_glfuncs, GLbitfield mask);
+void gl3_0_glDrawBuffer(void *_glfuncs, GLenum mode);
+void gl3_0_glTexImage2D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl3_0_glTexImage1D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl3_0_glTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl3_0_glTexParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint param);
+void gl3_0_glTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl3_0_glTexParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param);
+void gl3_0_glScissor(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl3_0_glPolygonMode(void *_glfuncs, GLenum face, GLenum mode);
+void gl3_0_glPointSize(void *_glfuncs, GLfloat size);
+void gl3_0_glLineWidth(void *_glfuncs, GLfloat width);
+void gl3_0_glHint(void *_glfuncs, GLenum target, GLenum mode);
+void gl3_0_glFrontFace(void *_glfuncs, GLenum mode);
+void gl3_0_glCullFace(void *_glfuncs, GLenum mode);
+void gl3_0_glIndexubv(void *_glfuncs, const GLubyte* c);
+void gl3_0_glIndexub(void *_glfuncs, GLubyte c);
+GLboolean gl3_0_glIsTexture(void *_glfuncs, GLuint texture);
+void gl3_0_glGenTextures(void *_glfuncs, GLsizei n, GLuint* textures);
+void gl3_0_glDeleteTextures(void *_glfuncs, GLsizei n, const GLuint* textures);
+void gl3_0_glBindTexture(void *_glfuncs, GLenum target, GLuint texture);
+void gl3_0_glTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl3_0_glTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl3_0_glCopyTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl3_0_glCopyTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width);
+void gl3_0_glCopyTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border);
+void gl3_0_glCopyTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLint border);
+void gl3_0_glPolygonOffset(void *_glfuncs, GLfloat factor, GLfloat units);
+void gl3_0_glDrawElements(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices);
+void gl3_0_glDrawArrays(void *_glfuncs, GLenum mode, GLint first, GLsizei count);
+void gl3_0_glCopyTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl3_0_glTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl3_0_glTexImage3D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl3_0_glDrawRangeElements(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices);
+void gl3_0_glBlendEquation(void *_glfuncs, GLenum mode);
+void gl3_0_glBlendColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl3_0_glGetCompressedTexImage(void *_glfuncs, GLenum target, GLint level, GLvoid* img);
+void gl3_0_glCompressedTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid* data);
+void gl3_0_glCompressedTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid* data);
+void gl3_0_glCompressedTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid* data);
+void gl3_0_glCompressedTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid* data);
+void gl3_0_glCompressedTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid* data);
+void gl3_0_glCompressedTexImage3D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid* data);
+void gl3_0_glSampleCoverage(void *_glfuncs, GLfloat value, GLboolean invert);
+void gl3_0_glActiveTexture(void *_glfuncs, GLenum texture);
+void gl3_0_glPointParameteriv(void *_glfuncs, GLenum pname, const GLint* params);
+void gl3_0_glPointParameteri(void *_glfuncs, GLenum pname, GLint param);
+void gl3_0_glPointParameterfv(void *_glfuncs, GLenum pname, const GLfloat* params);
+void gl3_0_glPointParameterf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl3_0_glMultiDrawArrays(void *_glfuncs, GLenum mode, const GLint* first, const GLsizei* count, GLsizei drawcount);
+void gl3_0_glBlendFuncSeparate(void *_glfuncs, GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha);
+void gl3_0_glGetBufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+GLboolean gl3_0_glUnmapBuffer(void *_glfuncs, GLenum target);
+void gl3_0_glGetBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, GLvoid* data);
+void gl3_0_glBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid* data);
+void gl3_0_glBufferData(void *_glfuncs, GLenum target, GLsizeiptr size, const GLvoid* data, GLenum usage);
+GLboolean gl3_0_glIsBuffer(void *_glfuncs, GLuint buffer);
+void gl3_0_glGenBuffers(void *_glfuncs, GLsizei n, GLuint* buffers);
+void gl3_0_glDeleteBuffers(void *_glfuncs, GLsizei n, const GLuint* buffers);
+void gl3_0_glBindBuffer(void *_glfuncs, GLenum target, GLuint buffer);
+void gl3_0_glGetQueryObjectuiv(void *_glfuncs, GLuint id, GLenum pname, GLuint* params);
+void gl3_0_glGetQueryObjectiv(void *_glfuncs, GLuint id, GLenum pname, GLint* params);
+void gl3_0_glGetQueryiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl3_0_glEndQuery(void *_glfuncs, GLenum target);
+void gl3_0_glBeginQuery(void *_glfuncs, GLenum target, GLuint id);
+GLboolean gl3_0_glIsQuery(void *_glfuncs, GLuint id);
+void gl3_0_glDeleteQueries(void *_glfuncs, GLsizei n, const GLuint* ids);
+void gl3_0_glGenQueries(void *_glfuncs, GLsizei n, GLuint* ids);
+void gl3_0_glVertexAttribPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLboolean normalized, GLsizei stride, const GLvoid* offset);
+void gl3_0_glValidateProgram(void *_glfuncs, GLuint program);
+void gl3_0_glUniformMatrix4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl3_0_glUniformMatrix3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl3_0_glUniformMatrix2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl3_0_glUniform4iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl3_0_glUniform3iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl3_0_glUniform2iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl3_0_glUniform1iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl3_0_glUniform4fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl3_0_glUniform3fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl3_0_glUniform2fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl3_0_glUniform1fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl3_0_glUniform4i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2, GLint v3);
+void gl3_0_glUniform3i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2);
+void gl3_0_glUniform2i(void *_glfuncs, GLint location, GLint v0, GLint v1);
+void gl3_0_glUniform1i(void *_glfuncs, GLint location, GLint v0);
+void gl3_0_glUniform4f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3);
+void gl3_0_glUniform3f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2);
+void gl3_0_glUniform2f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1);
+void gl3_0_glUniform1f(void *_glfuncs, GLint location, GLfloat v0);
+void gl3_0_glUseProgram(void *_glfuncs, GLuint program);
+void gl3_0_glShaderSource(void *_glfuncs, GLuint shader, GLsizei count, const GLchar** source, const GLint* length);
+void gl3_0_glLinkProgram(void *_glfuncs, GLuint program);
+GLboolean gl3_0_glIsShader(void *_glfuncs, GLuint shader);
+GLboolean gl3_0_glIsProgram(void *_glfuncs, GLuint program);
+void gl3_0_glGetVertexAttribiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params);
+void gl3_0_glGetVertexAttribfv(void *_glfuncs, GLuint index, GLenum pname, GLfloat* params);
+void gl3_0_glGetVertexAttribdv(void *_glfuncs, GLuint index, GLenum pname, GLdouble* params);
+void gl3_0_glGetUniformiv(void *_glfuncs, GLuint program, GLint location, GLint* params);
+void gl3_0_glGetUniformfv(void *_glfuncs, GLuint program, GLint location, GLfloat* params);
+GLint gl3_0_glGetUniformLocation(void *_glfuncs, GLuint program, const GLchar* name);
+void gl3_0_glGetShaderSource(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* source);
+void gl3_0_glGetShaderInfoLog(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* infoLog);
+void gl3_0_glGetShaderiv(void *_glfuncs, GLuint shader, GLenum pname, GLint* params);
+void gl3_0_glGetProgramInfoLog(void *_glfuncs, GLuint program, GLsizei bufSize, GLsizei* length, GLchar* infoLog);
+void gl3_0_glGetProgramiv(void *_glfuncs, GLuint program, GLenum pname, GLint* params);
+GLint gl3_0_glGetAttribLocation(void *_glfuncs, GLuint program, const GLchar* name);
+void gl3_0_glGetAttachedShaders(void *_glfuncs, GLuint program, GLsizei maxCount, GLsizei* count, GLuint* obj);
+void gl3_0_glGetActiveUniform(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name);
+void gl3_0_glGetActiveAttrib(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name);
+void gl3_0_glEnableVertexAttribArray(void *_glfuncs, GLuint index);
+void gl3_0_glDisableVertexAttribArray(void *_glfuncs, GLuint index);
+void gl3_0_glDetachShader(void *_glfuncs, GLuint program, GLuint shader);
+void gl3_0_glDeleteShader(void *_glfuncs, GLuint shader);
+void gl3_0_glDeleteProgram(void *_glfuncs, GLuint program);
+GLuint gl3_0_glCreateShader(void *_glfuncs, GLenum gltype);
+GLuint gl3_0_glCreateProgram(void *_glfuncs);
+void gl3_0_glCompileShader(void *_glfuncs, GLuint shader);
+void gl3_0_glBindAttribLocation(void *_glfuncs, GLuint program, GLuint index, const GLchar* name);
+void gl3_0_glAttachShader(void *_glfuncs, GLuint program, GLuint shader);
+void gl3_0_glStencilMaskSeparate(void *_glfuncs, GLenum face, GLuint mask);
+void gl3_0_glStencilFuncSeparate(void *_glfuncs, GLenum face, GLenum glfunc, GLint ref, GLuint mask);
+void gl3_0_glStencilOpSeparate(void *_glfuncs, GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass);
+void gl3_0_glDrawBuffers(void *_glfuncs, GLsizei n, const GLenum* bufs);
+void gl3_0_glBlendEquationSeparate(void *_glfuncs, GLenum modeRGB, GLenum modeAlpha);
+void gl3_0_glUniformMatrix4x3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl3_0_glUniformMatrix3x4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl3_0_glUniformMatrix4x2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl3_0_glUniformMatrix2x4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl3_0_glUniformMatrix3x2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl3_0_glUniformMatrix2x3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+GLboolean gl3_0_glIsVertexArray(void *_glfuncs, GLuint array);
+void gl3_0_glGenVertexArrays(void *_glfuncs, GLsizei n, GLuint* arrays);
+void gl3_0_glDeleteVertexArrays(void *_glfuncs, GLsizei n, const GLuint* arrays);
+void gl3_0_glBindVertexArray(void *_glfuncs, GLuint array);
+void gl3_0_glFlushMappedBufferRange(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr length);
+void gl3_0_glFramebufferTextureLayer(void *_glfuncs, GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer);
+void gl3_0_glRenderbufferStorageMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLenum internalFormat, GLsizei width, GLsizei height);
+void gl3_0_glBlitFramebuffer(void *_glfuncs, GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter);
+void gl3_0_glGenerateMipmap(void *_glfuncs, GLenum target);
+void gl3_0_glGetFramebufferAttachmentParameteriv(void *_glfuncs, GLenum target, GLenum attachment, GLenum pname, GLint* params);
+void gl3_0_glFramebufferRenderbuffer(void *_glfuncs, GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer);
+void gl3_0_glFramebufferTexture3D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset);
+void gl3_0_glFramebufferTexture2D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+void gl3_0_glFramebufferTexture1D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+GLenum gl3_0_glCheckFramebufferStatus(void *_glfuncs, GLenum target);
+void gl3_0_glGenFramebuffers(void *_glfuncs, GLsizei n, GLuint* framebuffers);
+void gl3_0_glDeleteFramebuffers(void *_glfuncs, GLsizei n, const GLuint* framebuffers);
+void gl3_0_glBindFramebuffer(void *_glfuncs, GLenum target, GLuint framebuffer);
+GLboolean gl3_0_glIsFramebuffer(void *_glfuncs, GLuint framebuffer);
+void gl3_0_glGetRenderbufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl3_0_glRenderbufferStorage(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height);
+void gl3_0_glGenRenderbuffers(void *_glfuncs, GLsizei n, GLuint* renderbuffers);
+void gl3_0_glDeleteRenderbuffers(void *_glfuncs, GLsizei n, const GLuint* renderbuffers);
+void gl3_0_glBindRenderbuffer(void *_glfuncs, GLenum target, GLuint renderbuffer);
+GLboolean gl3_0_glIsRenderbuffer(void *_glfuncs, GLuint renderbuffer);
+void gl3_0_glClearBufferfi(void *_glfuncs, GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil);
+void gl3_0_glClearBufferfv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLfloat* value);
+void gl3_0_glClearBufferuiv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLuint* value);
+void gl3_0_glClearBufferiv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLint* value);
+void gl3_0_glGetTexParameterIuiv(void *_glfuncs, GLenum target, GLenum pname, GLuint* params);
+void gl3_0_glGetTexParameterIiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl3_0_glTexParameterIuiv(void *_glfuncs, GLenum target, GLenum pname, const GLuint* params);
+void gl3_0_glTexParameterIiv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl3_0_glUniform4uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value);
+void gl3_0_glUniform3uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value);
+void gl3_0_glUniform2uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value);
+void gl3_0_glUniform1uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value);
+void gl3_0_glUniform4ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3);
+void gl3_0_glUniform3ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1, GLuint v2);
+void gl3_0_glUniform2ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1);
+void gl3_0_glUniform1ui(void *_glfuncs, GLint location, GLuint v0);
+GLint gl3_0_glGetFragDataLocation(void *_glfuncs, GLuint program, const GLchar* name);
+void gl3_0_glBindFragDataLocation(void *_glfuncs, GLuint program, GLuint color, const GLchar* name);
+void gl3_0_glGetUniformuiv(void *_glfuncs, GLuint program, GLint location, GLuint* params);
+void gl3_0_glGetVertexAttribIuiv(void *_glfuncs, GLuint index, GLenum pname, GLuint* params);
+void gl3_0_glGetVertexAttribIiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params);
+void gl3_0_glVertexAttribIPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl3_0_glEndConditionalRender(void *_glfuncs);
+void gl3_0_glBeginConditionalRender(void *_glfuncs, GLuint id, GLenum mode);
+void gl3_0_glClampColor(void *_glfuncs, GLenum target, GLenum clamp);
+void gl3_0_glGetTransformFeedbackVarying(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLsizei* size, GLenum* gltype, GLchar* name);
+void gl3_0_glBindBufferBase(void *_glfuncs, GLenum target, GLuint index, GLuint buffer);
+void gl3_0_glBindBufferRange(void *_glfuncs, GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size);
+void gl3_0_glEndTransformFeedback(void *_glfuncs);
+void gl3_0_glBeginTransformFeedback(void *_glfuncs, GLenum primitiveMode);
+GLboolean gl3_0_glIsEnabledi(void *_glfuncs, GLenum target, GLuint index);
+void gl3_0_glDisablei(void *_glfuncs, GLenum target, GLuint index);
+void gl3_0_glEnablei(void *_glfuncs, GLenum target, GLuint index);
+void gl3_0_glGetIntegeri_v(void *_glfuncs, GLenum target, GLuint index, GLint* data);
+void gl3_0_glGetBooleani_v(void *_glfuncs, GLenum target, GLuint index, GLboolean* data);
+void gl3_0_glColorMaski(void *_glfuncs, GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a);
+void gl3_0_glTranslatef(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl3_0_glTranslated(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl3_0_glScalef(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl3_0_glScaled(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl3_0_glRotatef(void *_glfuncs, GLfloat angle, GLfloat x, GLfloat y, GLfloat z);
+void gl3_0_glRotated(void *_glfuncs, GLdouble angle, GLdouble x, GLdouble y, GLdouble z);
+void gl3_0_glPushMatrix(void *_glfuncs);
+void gl3_0_glPopMatrix(void *_glfuncs);
+void gl3_0_glOrtho(void *_glfuncs, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+void gl3_0_glMultMatrixd(void *_glfuncs, const GLdouble* m);
+void gl3_0_glMultMatrixf(void *_glfuncs, const GLfloat* m);
+void gl3_0_glMatrixMode(void *_glfuncs, GLenum mode);
+void gl3_0_glLoadMatrixd(void *_glfuncs, const GLdouble* m);
+void gl3_0_glLoadMatrixf(void *_glfuncs, const GLfloat* m);
+void gl3_0_glLoadIdentity(void *_glfuncs);
+void gl3_0_glFrustum(void *_glfuncs, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+GLboolean gl3_0_glIsList(void *_glfuncs, GLuint list);
+void gl3_0_glGetTexGeniv(void *_glfuncs, GLenum coord, GLenum pname, GLint* params);
+void gl3_0_glGetTexGenfv(void *_glfuncs, GLenum coord, GLenum pname, GLfloat* params);
+void gl3_0_glGetTexGendv(void *_glfuncs, GLenum coord, GLenum pname, GLdouble* params);
+void gl3_0_glGetTexEnviv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl3_0_glGetTexEnvfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl3_0_glGetPolygonStipple(void *_glfuncs, GLubyte* mask);
+void gl3_0_glGetPixelMapusv(void *_glfuncs, GLenum glmap, GLushort* values);
+void gl3_0_glGetPixelMapuiv(void *_glfuncs, GLenum glmap, GLuint* values);
+void gl3_0_glGetPixelMapfv(void *_glfuncs, GLenum glmap, GLfloat* values);
+void gl3_0_glGetMaterialiv(void *_glfuncs, GLenum face, GLenum pname, GLint* params);
+void gl3_0_glGetMaterialfv(void *_glfuncs, GLenum face, GLenum pname, GLfloat* params);
+void gl3_0_glGetMapiv(void *_glfuncs, GLenum target, GLenum query, GLint* v);
+void gl3_0_glGetMapfv(void *_glfuncs, GLenum target, GLenum query, GLfloat* v);
+void gl3_0_glGetMapdv(void *_glfuncs, GLenum target, GLenum query, GLdouble* v);
+void gl3_0_glGetLightiv(void *_glfuncs, GLenum light, GLenum pname, GLint* params);
+void gl3_0_glGetLightfv(void *_glfuncs, GLenum light, GLenum pname, GLfloat* params);
+void gl3_0_glGetClipPlane(void *_glfuncs, GLenum plane, GLdouble* equation);
+void gl3_0_glDrawPixels(void *_glfuncs, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl3_0_glCopyPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum gltype);
+void gl3_0_glPixelMapusv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLushort* values);
+void gl3_0_glPixelMapuiv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLuint* values);
+void gl3_0_glPixelMapfv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLfloat* values);
+void gl3_0_glPixelTransferi(void *_glfuncs, GLenum pname, GLint param);
+void gl3_0_glPixelTransferf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl3_0_glPixelZoom(void *_glfuncs, GLfloat xfactor, GLfloat yfactor);
+void gl3_0_glAlphaFunc(void *_glfuncs, GLenum glfunc, GLfloat ref);
+void gl3_0_glEvalPoint2(void *_glfuncs, GLint i, GLint j);
+void gl3_0_glEvalMesh2(void *_glfuncs, GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2);
+void gl3_0_glEvalPoint1(void *_glfuncs, GLint i);
+void gl3_0_glEvalMesh1(void *_glfuncs, GLenum mode, GLint i1, GLint i2);
+void gl3_0_glEvalCoord2fv(void *_glfuncs, const GLfloat* u);
+void gl3_0_glEvalCoord2f(void *_glfuncs, GLfloat u, GLfloat v);
+void gl3_0_glEvalCoord2dv(void *_glfuncs, const GLdouble* u);
+void gl3_0_glEvalCoord2d(void *_glfuncs, GLdouble u, GLdouble v);
+void gl3_0_glEvalCoord1fv(void *_glfuncs, const GLfloat* u);
+void gl3_0_glEvalCoord1f(void *_glfuncs, GLfloat u);
+void gl3_0_glEvalCoord1dv(void *_glfuncs, const GLdouble* u);
+void gl3_0_glEvalCoord1d(void *_glfuncs, GLdouble u);
+void gl3_0_glMapGrid2f(void *_glfuncs, GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2);
+void gl3_0_glMapGrid2d(void *_glfuncs, GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2);
+void gl3_0_glMapGrid1f(void *_glfuncs, GLint un, GLfloat u1, GLfloat u2);
+void gl3_0_glMapGrid1d(void *_glfuncs, GLint un, GLdouble u1, GLdouble u2);
+void gl3_0_glMap2f(void *_glfuncs, GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat* points);
+void gl3_0_glMap2d(void *_glfuncs, GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble* points);
+void gl3_0_glMap1f(void *_glfuncs, GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat* points);
+void gl3_0_glMap1d(void *_glfuncs, GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble* points);
+void gl3_0_glPushAttrib(void *_glfuncs, GLbitfield mask);
+void gl3_0_glPopAttrib(void *_glfuncs);
+void gl3_0_glAccum(void *_glfuncs, GLenum op, GLfloat value);
+void gl3_0_glIndexMask(void *_glfuncs, GLuint mask);
+void gl3_0_glClearIndex(void *_glfuncs, GLfloat c);
+void gl3_0_glClearAccum(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl3_0_glPushName(void *_glfuncs, GLuint name);
+void gl3_0_glPopName(void *_glfuncs);
+void gl3_0_glPassThrough(void *_glfuncs, GLfloat token);
+void gl3_0_glLoadName(void *_glfuncs, GLuint name);
+void gl3_0_glInitNames(void *_glfuncs);
+GLint gl3_0_glRenderMode(void *_glfuncs, GLenum mode);
+void gl3_0_glSelectBuffer(void *_glfuncs, GLsizei size, GLuint* buffer);
+void gl3_0_glFeedbackBuffer(void *_glfuncs, GLsizei size, GLenum gltype, GLfloat* buffer);
+void gl3_0_glTexGeniv(void *_glfuncs, GLenum coord, GLenum pname, const GLint* params);
+void gl3_0_glTexGeni(void *_glfuncs, GLenum coord, GLenum pname, GLint param);
+void gl3_0_glTexGenfv(void *_glfuncs, GLenum coord, GLenum pname, const GLfloat* params);
+void gl3_0_glTexGenf(void *_glfuncs, GLenum coord, GLenum pname, GLfloat param);
+void gl3_0_glTexGendv(void *_glfuncs, GLenum coord, GLenum pname, const GLdouble* params);
+void gl3_0_glTexGend(void *_glfuncs, GLenum coord, GLenum pname, GLdouble param);
+void gl3_0_glTexEnviv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl3_0_glTexEnvi(void *_glfuncs, GLenum target, GLenum pname, GLint param);
+void gl3_0_glTexEnvfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl3_0_glTexEnvf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param);
+void gl3_0_glShadeModel(void *_glfuncs, GLenum mode);
+void gl3_0_glPolygonStipple(void *_glfuncs, const GLubyte* mask);
+void gl3_0_glMaterialiv(void *_glfuncs, GLenum face, GLenum pname, const GLint* params);
+void gl3_0_glMateriali(void *_glfuncs, GLenum face, GLenum pname, GLint param);
+void gl3_0_glMaterialfv(void *_glfuncs, GLenum face, GLenum pname, const GLfloat* params);
+void gl3_0_glMaterialf(void *_glfuncs, GLenum face, GLenum pname, GLfloat param);
+void gl3_0_glLineStipple(void *_glfuncs, GLint factor, GLushort pattern);
+void gl3_0_glLightModeliv(void *_glfuncs, GLenum pname, const GLint* params);
+void gl3_0_glLightModeli(void *_glfuncs, GLenum pname, GLint param);
+void gl3_0_glLightModelfv(void *_glfuncs, GLenum pname, const GLfloat* params);
+void gl3_0_glLightModelf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl3_0_glLightiv(void *_glfuncs, GLenum light, GLenum pname, const GLint* params);
+void gl3_0_glLighti(void *_glfuncs, GLenum light, GLenum pname, GLint param);
+void gl3_0_glLightfv(void *_glfuncs, GLenum light, GLenum pname, const GLfloat* params);
+void gl3_0_glLightf(void *_glfuncs, GLenum light, GLenum pname, GLfloat param);
+void gl3_0_glFogiv(void *_glfuncs, GLenum pname, const GLint* params);
+void gl3_0_glFogi(void *_glfuncs, GLenum pname, GLint param);
+void gl3_0_glFogfv(void *_glfuncs, GLenum pname, const GLfloat* params);
+void gl3_0_glFogf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl3_0_glColorMaterial(void *_glfuncs, GLenum face, GLenum mode);
+void gl3_0_glClipPlane(void *_glfuncs, GLenum plane, const GLdouble* equation);
+void gl3_0_glVertex4sv(void *_glfuncs, const GLshort* v);
+void gl3_0_glVertex4s(void *_glfuncs, GLshort x, GLshort y, GLshort z, GLshort w);
+void gl3_0_glVertex4iv(void *_glfuncs, const GLint* v);
+void gl3_0_glVertex4i(void *_glfuncs, GLint x, GLint y, GLint z, GLint w);
+void gl3_0_glVertex4fv(void *_glfuncs, const GLfloat* v);
+void gl3_0_glVertex4f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+void gl3_0_glVertex4dv(void *_glfuncs, const GLdouble* v);
+void gl3_0_glVertex4d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+void gl3_0_glVertex3sv(void *_glfuncs, const GLshort* v);
+void gl3_0_glVertex3s(void *_glfuncs, GLshort x, GLshort y, GLshort z);
+void gl3_0_glVertex3iv(void *_glfuncs, const GLint* v);
+void gl3_0_glVertex3i(void *_glfuncs, GLint x, GLint y, GLint z);
+void gl3_0_glVertex3fv(void *_glfuncs, const GLfloat* v);
+void gl3_0_glVertex3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl3_0_glVertex3dv(void *_glfuncs, const GLdouble* v);
+void gl3_0_glVertex3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl3_0_glVertex2sv(void *_glfuncs, const GLshort* v);
+void gl3_0_glVertex2s(void *_glfuncs, GLshort x, GLshort y);
+void gl3_0_glVertex2iv(void *_glfuncs, const GLint* v);
+void gl3_0_glVertex2i(void *_glfuncs, GLint x, GLint y);
+void gl3_0_glVertex2fv(void *_glfuncs, const GLfloat* v);
+void gl3_0_glVertex2f(void *_glfuncs, GLfloat x, GLfloat y);
+void gl3_0_glVertex2dv(void *_glfuncs, const GLdouble* v);
+void gl3_0_glVertex2d(void *_glfuncs, GLdouble x, GLdouble y);
+void gl3_0_glTexCoord4sv(void *_glfuncs, const GLshort* v);
+void gl3_0_glTexCoord4s(void *_glfuncs, GLshort s, GLshort t, GLshort r, GLshort q);
+void gl3_0_glTexCoord4iv(void *_glfuncs, const GLint* v);
+void gl3_0_glTexCoord4i(void *_glfuncs, GLint s, GLint t, GLint r, GLint q);
+void gl3_0_glTexCoord4fv(void *_glfuncs, const GLfloat* v);
+void gl3_0_glTexCoord4f(void *_glfuncs, GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+void gl3_0_glTexCoord4dv(void *_glfuncs, const GLdouble* v);
+void gl3_0_glTexCoord4d(void *_glfuncs, GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+void gl3_0_glTexCoord3sv(void *_glfuncs, const GLshort* v);
+void gl3_0_glTexCoord3s(void *_glfuncs, GLshort s, GLshort t, GLshort r);
+void gl3_0_glTexCoord3iv(void *_glfuncs, const GLint* v);
+void gl3_0_glTexCoord3i(void *_glfuncs, GLint s, GLint t, GLint r);
+void gl3_0_glTexCoord3fv(void *_glfuncs, const GLfloat* v);
+void gl3_0_glTexCoord3f(void *_glfuncs, GLfloat s, GLfloat t, GLfloat r);
+void gl3_0_glTexCoord3dv(void *_glfuncs, const GLdouble* v);
+void gl3_0_glTexCoord3d(void *_glfuncs, GLdouble s, GLdouble t, GLdouble r);
+void gl3_0_glTexCoord2sv(void *_glfuncs, const GLshort* v);
+void gl3_0_glTexCoord2s(void *_glfuncs, GLshort s, GLshort t);
+void gl3_0_glTexCoord2iv(void *_glfuncs, const GLint* v);
+void gl3_0_glTexCoord2i(void *_glfuncs, GLint s, GLint t);
+void gl3_0_glTexCoord2fv(void *_glfuncs, const GLfloat* v);
+void gl3_0_glTexCoord2f(void *_glfuncs, GLfloat s, GLfloat t);
+void gl3_0_glTexCoord2dv(void *_glfuncs, const GLdouble* v);
+void gl3_0_glTexCoord2d(void *_glfuncs, GLdouble s, GLdouble t);
+void gl3_0_glTexCoord1sv(void *_glfuncs, const GLshort* v);
+void gl3_0_glTexCoord1s(void *_glfuncs, GLshort s);
+void gl3_0_glTexCoord1iv(void *_glfuncs, const GLint* v);
+void gl3_0_glTexCoord1i(void *_glfuncs, GLint s);
+void gl3_0_glTexCoord1fv(void *_glfuncs, const GLfloat* v);
+void gl3_0_glTexCoord1f(void *_glfuncs, GLfloat s);
+void gl3_0_glTexCoord1dv(void *_glfuncs, const GLdouble* v);
+void gl3_0_glTexCoord1d(void *_glfuncs, GLdouble s);
+void gl3_0_glRectsv(void *_glfuncs, const GLshort* v1, const GLshort* v2);
+void gl3_0_glRects(void *_glfuncs, GLshort x1, GLshort y1, GLshort x2, GLshort y2);
+void gl3_0_glRectiv(void *_glfuncs, const GLint* v1, const GLint* v2);
+void gl3_0_glRecti(void *_glfuncs, GLint x1, GLint y1, GLint x2, GLint y2);
+void gl3_0_glRectfv(void *_glfuncs, const GLfloat* v1, const GLfloat* v2);
+void gl3_0_glRectf(void *_glfuncs, GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2);
+void gl3_0_glRectdv(void *_glfuncs, const GLdouble* v1, const GLdouble* v2);
+void gl3_0_glRectd(void *_glfuncs, GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2);
+void gl3_0_glRasterPos4sv(void *_glfuncs, const GLshort* v);
+void gl3_0_glRasterPos4s(void *_glfuncs, GLshort x, GLshort y, GLshort z, GLshort w);
+void gl3_0_glRasterPos4iv(void *_glfuncs, const GLint* v);
+void gl3_0_glRasterPos4i(void *_glfuncs, GLint x, GLint y, GLint z, GLint w);
+void gl3_0_glRasterPos4fv(void *_glfuncs, const GLfloat* v);
+void gl3_0_glRasterPos4f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+void gl3_0_glRasterPos4dv(void *_glfuncs, const GLdouble* v);
+void gl3_0_glRasterPos4d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+void gl3_0_glRasterPos3sv(void *_glfuncs, const GLshort* v);
+void gl3_0_glRasterPos3s(void *_glfuncs, GLshort x, GLshort y, GLshort z);
+void gl3_0_glRasterPos3iv(void *_glfuncs, const GLint* v);
+void gl3_0_glRasterPos3i(void *_glfuncs, GLint x, GLint y, GLint z);
+void gl3_0_glRasterPos3fv(void *_glfuncs, const GLfloat* v);
+void gl3_0_glRasterPos3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl3_0_glRasterPos3dv(void *_glfuncs, const GLdouble* v);
+void gl3_0_glRasterPos3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl3_0_glRasterPos2sv(void *_glfuncs, const GLshort* v);
+void gl3_0_glRasterPos2s(void *_glfuncs, GLshort x, GLshort y);
+void gl3_0_glRasterPos2iv(void *_glfuncs, const GLint* v);
+void gl3_0_glRasterPos2i(void *_glfuncs, GLint x, GLint y);
+void gl3_0_glRasterPos2fv(void *_glfuncs, const GLfloat* v);
+void gl3_0_glRasterPos2f(void *_glfuncs, GLfloat x, GLfloat y);
+void gl3_0_glRasterPos2dv(void *_glfuncs, const GLdouble* v);
+void gl3_0_glRasterPos2d(void *_glfuncs, GLdouble x, GLdouble y);
+void gl3_0_glNormal3sv(void *_glfuncs, const GLshort* v);
+void gl3_0_glNormal3s(void *_glfuncs, GLshort nx, GLshort ny, GLshort nz);
+void gl3_0_glNormal3iv(void *_glfuncs, const GLint* v);
+void gl3_0_glNormal3i(void *_glfuncs, GLint nx, GLint ny, GLint nz);
+void gl3_0_glNormal3fv(void *_glfuncs, const GLfloat* v);
+void gl3_0_glNormal3f(void *_glfuncs, GLfloat nx, GLfloat ny, GLfloat nz);
+void gl3_0_glNormal3dv(void *_glfuncs, const GLdouble* v);
+void gl3_0_glNormal3d(void *_glfuncs, GLdouble nx, GLdouble ny, GLdouble nz);
+void gl3_0_glNormal3bv(void *_glfuncs, const GLbyte* v);
+void gl3_0_glNormal3b(void *_glfuncs, GLbyte nx, GLbyte ny, GLbyte nz);
+void gl3_0_glIndexsv(void *_glfuncs, const GLshort* c);
+void gl3_0_glIndexs(void *_glfuncs, GLshort c);
+void gl3_0_glIndexiv(void *_glfuncs, const GLint* c);
+void gl3_0_glIndexi(void *_glfuncs, GLint c);
+void gl3_0_glIndexfv(void *_glfuncs, const GLfloat* c);
+void gl3_0_glIndexf(void *_glfuncs, GLfloat c);
+void gl3_0_glIndexdv(void *_glfuncs, const GLdouble* c);
+void gl3_0_glIndexd(void *_glfuncs, GLdouble c);
+void gl3_0_glEnd(void *_glfuncs);
+void gl3_0_glEdgeFlagv(void *_glfuncs, const GLboolean* flag);
+void gl3_0_glEdgeFlag(void *_glfuncs, GLboolean flag);
+void gl3_0_glColor4usv(void *_glfuncs, const GLushort* v);
+void gl3_0_glColor4us(void *_glfuncs, GLushort red, GLushort green, GLushort blue, GLushort alpha);
+void gl3_0_glColor4uiv(void *_glfuncs, const GLuint* v);
+void gl3_0_glColor4ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue, GLuint alpha);
+void gl3_0_glColor4ubv(void *_glfuncs, const GLubyte* v);
+void gl3_0_glColor4ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha);
+void gl3_0_glColor4sv(void *_glfuncs, const GLshort* v);
+void gl3_0_glColor4s(void *_glfuncs, GLshort red, GLshort green, GLshort blue, GLshort alpha);
+void gl3_0_glColor4iv(void *_glfuncs, const GLint* v);
+void gl3_0_glColor4i(void *_glfuncs, GLint red, GLint green, GLint blue, GLint alpha);
+void gl3_0_glColor4fv(void *_glfuncs, const GLfloat* v);
+void gl3_0_glColor4f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl3_0_glColor4dv(void *_glfuncs, const GLdouble* v);
+void gl3_0_glColor4d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha);
+void gl3_0_glColor4bv(void *_glfuncs, const GLbyte* v);
+void gl3_0_glColor4b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha);
+void gl3_0_glColor3usv(void *_glfuncs, const GLushort* v);
+void gl3_0_glColor3us(void *_glfuncs, GLushort red, GLushort green, GLushort blue);
+void gl3_0_glColor3uiv(void *_glfuncs, const GLuint* v);
+void gl3_0_glColor3ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue);
+void gl3_0_glColor3ubv(void *_glfuncs, const GLubyte* v);
+void gl3_0_glColor3ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue);
+void gl3_0_glColor3sv(void *_glfuncs, const GLshort* v);
+void gl3_0_glColor3s(void *_glfuncs, GLshort red, GLshort green, GLshort blue);
+void gl3_0_glColor3iv(void *_glfuncs, const GLint* v);
+void gl3_0_glColor3i(void *_glfuncs, GLint red, GLint green, GLint blue);
+void gl3_0_glColor3fv(void *_glfuncs, const GLfloat* v);
+void gl3_0_glColor3f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue);
+void gl3_0_glColor3dv(void *_glfuncs, const GLdouble* v);
+void gl3_0_glColor3d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue);
+void gl3_0_glColor3bv(void *_glfuncs, const GLbyte* v);
+void gl3_0_glColor3b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue);
+void gl3_0_glBitmap(void *_glfuncs, GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte* bitmap);
+void gl3_0_glBegin(void *_glfuncs, GLenum mode);
+void gl3_0_glListBase(void *_glfuncs, GLuint base);
+GLuint gl3_0_glGenLists(void *_glfuncs, GLsizei range_);
+void gl3_0_glDeleteLists(void *_glfuncs, GLuint list, GLsizei range_);
+void gl3_0_glCallLists(void *_glfuncs, GLsizei n, GLenum gltype, const GLvoid* lists);
+void gl3_0_glCallList(void *_glfuncs, GLuint list);
+void gl3_0_glEndList(void *_glfuncs);
+void gl3_0_glNewList(void *_glfuncs, GLuint list, GLenum mode);
+void gl3_0_glPushClientAttrib(void *_glfuncs, GLbitfield mask);
+void gl3_0_glPopClientAttrib(void *_glfuncs);
+void gl3_0_glPrioritizeTextures(void *_glfuncs, GLsizei n, const GLuint* textures, const GLfloat* priorities);
+GLboolean gl3_0_glAreTexturesResident(void *_glfuncs, GLsizei n, const GLuint* textures, GLboolean* residences);
+void gl3_0_glVertexPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl3_0_glTexCoordPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl3_0_glNormalPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl3_0_glInterleavedArrays(void *_glfuncs, GLenum format, GLsizei stride, const GLvoid* pointer);
+void gl3_0_glIndexPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl3_0_glEnableClientState(void *_glfuncs, GLenum array);
+void gl3_0_glEdgeFlagPointer(void *_glfuncs, GLsizei stride, const GLvoid* pointer);
+void gl3_0_glDisableClientState(void *_glfuncs, GLenum array);
+void gl3_0_glColorPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl3_0_glArrayElement(void *_glfuncs, GLint i);
+void gl3_0_glResetMinmax(void *_glfuncs, GLenum target);
+void gl3_0_glResetHistogram(void *_glfuncs, GLenum target);
+void gl3_0_glMinmax(void *_glfuncs, GLenum target, GLenum internalFormat, GLboolean sink);
+void gl3_0_glHistogram(void *_glfuncs, GLenum target, GLsizei width, GLenum internalFormat, GLboolean sink);
+void gl3_0_glGetMinmaxParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl3_0_glGetMinmaxParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl3_0_glGetMinmax(void *_glfuncs, GLenum target, GLboolean reset, GLenum format, GLenum gltype, GLvoid* values);
+void gl3_0_glGetHistogramParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl3_0_glGetHistogramParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl3_0_glGetHistogram(void *_glfuncs, GLenum target, GLboolean reset, GLenum format, GLenum gltype, GLvoid* values);
+void gl3_0_glSeparableFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* row, const GLvoid* column);
+void gl3_0_glGetSeparableFilter(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* row, GLvoid* column, GLvoid* span);
+void gl3_0_glGetConvolutionParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl3_0_glGetConvolutionParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl3_0_glGetConvolutionFilter(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* image);
+void gl3_0_glCopyConvolutionFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl3_0_glCopyConvolutionFilter1D(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width);
+void gl3_0_glConvolutionParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl3_0_glConvolutionParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint params);
+void gl3_0_glConvolutionParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl3_0_glConvolutionParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat params);
+void gl3_0_glConvolutionFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* image);
+void gl3_0_glConvolutionFilter1D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLenum format, GLenum gltype, const GLvoid* image);
+void gl3_0_glCopyColorSubTable(void *_glfuncs, GLenum target, GLsizei start, GLint x, GLint y, GLsizei width);
+void gl3_0_glColorSubTable(void *_glfuncs, GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum gltype, const GLvoid* data);
+void gl3_0_glGetColorTableParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl3_0_glGetColorTableParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl3_0_glGetColorTable(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* table);
+void gl3_0_glCopyColorTable(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width);
+void gl3_0_glColorTableParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl3_0_glColorTableParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl3_0_glColorTable(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLenum format, GLenum gltype, const GLvoid* table);
+void gl3_0_glMultTransposeMatrixd(void *_glfuncs, const GLdouble* m);
+void gl3_0_glMultTransposeMatrixf(void *_glfuncs, const GLfloat* m);
+void gl3_0_glLoadTransposeMatrixd(void *_glfuncs, const GLdouble* m);
+void gl3_0_glLoadTransposeMatrixf(void *_glfuncs, const GLfloat* m);
+void gl3_0_glMultiTexCoord4sv(void *_glfuncs, GLenum target, const GLshort* v);
+void gl3_0_glMultiTexCoord4s(void *_glfuncs, GLenum target, GLshort s, GLshort t, GLshort r, GLshort q);
+void gl3_0_glMultiTexCoord4iv(void *_glfuncs, GLenum target, const GLint* v);
+void gl3_0_glMultiTexCoord4i(void *_glfuncs, GLenum target, GLint s, GLint t, GLint r, GLint q);
+void gl3_0_glMultiTexCoord4fv(void *_glfuncs, GLenum target, const GLfloat* v);
+void gl3_0_glMultiTexCoord4f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+void gl3_0_glMultiTexCoord4dv(void *_glfuncs, GLenum target, const GLdouble* v);
+void gl3_0_glMultiTexCoord4d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+void gl3_0_glMultiTexCoord3sv(void *_glfuncs, GLenum target, const GLshort* v);
+void gl3_0_glMultiTexCoord3s(void *_glfuncs, GLenum target, GLshort s, GLshort t, GLshort r);
+void gl3_0_glMultiTexCoord3iv(void *_glfuncs, GLenum target, const GLint* v);
+void gl3_0_glMultiTexCoord3i(void *_glfuncs, GLenum target, GLint s, GLint t, GLint r);
+void gl3_0_glMultiTexCoord3fv(void *_glfuncs, GLenum target, const GLfloat* v);
+void gl3_0_glMultiTexCoord3f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t, GLfloat r);
+void gl3_0_glMultiTexCoord3dv(void *_glfuncs, GLenum target, const GLdouble* v);
+void gl3_0_glMultiTexCoord3d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t, GLdouble r);
+void gl3_0_glMultiTexCoord2sv(void *_glfuncs, GLenum target, const GLshort* v);
+void gl3_0_glMultiTexCoord2s(void *_glfuncs, GLenum target, GLshort s, GLshort t);
+void gl3_0_glMultiTexCoord2iv(void *_glfuncs, GLenum target, const GLint* v);
+void gl3_0_glMultiTexCoord2i(void *_glfuncs, GLenum target, GLint s, GLint t);
+void gl3_0_glMultiTexCoord2fv(void *_glfuncs, GLenum target, const GLfloat* v);
+void gl3_0_glMultiTexCoord2f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t);
+void gl3_0_glMultiTexCoord2dv(void *_glfuncs, GLenum target, const GLdouble* v);
+void gl3_0_glMultiTexCoord2d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t);
+void gl3_0_glMultiTexCoord1sv(void *_glfuncs, GLenum target, const GLshort* v);
+void gl3_0_glMultiTexCoord1s(void *_glfuncs, GLenum target, GLshort s);
+void gl3_0_glMultiTexCoord1iv(void *_glfuncs, GLenum target, const GLint* v);
+void gl3_0_glMultiTexCoord1i(void *_glfuncs, GLenum target, GLint s);
+void gl3_0_glMultiTexCoord1fv(void *_glfuncs, GLenum target, const GLfloat* v);
+void gl3_0_glMultiTexCoord1f(void *_glfuncs, GLenum target, GLfloat s);
+void gl3_0_glMultiTexCoord1dv(void *_glfuncs, GLenum target, const GLdouble* v);
+void gl3_0_glMultiTexCoord1d(void *_glfuncs, GLenum target, GLdouble s);
+void gl3_0_glClientActiveTexture(void *_glfuncs, GLenum texture);
+void gl3_0_glWindowPos3sv(void *_glfuncs, const GLshort* v);
+void gl3_0_glWindowPos3s(void *_glfuncs, GLshort x, GLshort y, GLshort z);
+void gl3_0_glWindowPos3iv(void *_glfuncs, const GLint* v);
+void gl3_0_glWindowPos3i(void *_glfuncs, GLint x, GLint y, GLint z);
+void gl3_0_glWindowPos3fv(void *_glfuncs, const GLfloat* v);
+void gl3_0_glWindowPos3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl3_0_glWindowPos3dv(void *_glfuncs, const GLdouble* v);
+void gl3_0_glWindowPos3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl3_0_glWindowPos2sv(void *_glfuncs, const GLshort* v);
+void gl3_0_glWindowPos2s(void *_glfuncs, GLshort x, GLshort y);
+void gl3_0_glWindowPos2iv(void *_glfuncs, const GLint* v);
+void gl3_0_glWindowPos2i(void *_glfuncs, GLint x, GLint y);
+void gl3_0_glWindowPos2fv(void *_glfuncs, const GLfloat* v);
+void gl3_0_glWindowPos2f(void *_glfuncs, GLfloat x, GLfloat y);
+void gl3_0_glWindowPos2dv(void *_glfuncs, const GLdouble* v);
+void gl3_0_glWindowPos2d(void *_glfuncs, GLdouble x, GLdouble y);
+void gl3_0_glSecondaryColorPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl3_0_glSecondaryColor3usv(void *_glfuncs, const GLushort* v);
+void gl3_0_glSecondaryColor3us(void *_glfuncs, GLushort red, GLushort green, GLushort blue);
+void gl3_0_glSecondaryColor3uiv(void *_glfuncs, const GLuint* v);
+void gl3_0_glSecondaryColor3ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue);
+void gl3_0_glSecondaryColor3ubv(void *_glfuncs, const GLubyte* v);
+void gl3_0_glSecondaryColor3ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue);
+void gl3_0_glSecondaryColor3sv(void *_glfuncs, const GLshort* v);
+void gl3_0_glSecondaryColor3s(void *_glfuncs, GLshort red, GLshort green, GLshort blue);
+void gl3_0_glSecondaryColor3iv(void *_glfuncs, const GLint* v);
+void gl3_0_glSecondaryColor3i(void *_glfuncs, GLint red, GLint green, GLint blue);
+void gl3_0_glSecondaryColor3fv(void *_glfuncs, const GLfloat* v);
+void gl3_0_glSecondaryColor3f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue);
+void gl3_0_glSecondaryColor3dv(void *_glfuncs, const GLdouble* v);
+void gl3_0_glSecondaryColor3d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue);
+void gl3_0_glSecondaryColor3bv(void *_glfuncs, const GLbyte* v);
+void gl3_0_glSecondaryColor3b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue);
+void gl3_0_glFogCoordPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl3_0_glFogCoorddv(void *_glfuncs, const GLdouble* coord);
+void gl3_0_glFogCoordd(void *_glfuncs, GLdouble coord);
+void gl3_0_glFogCoordfv(void *_glfuncs, const GLfloat* coord);
+void gl3_0_glFogCoordf(void *_glfuncs, GLfloat coord);
+void gl3_0_glVertexAttrib4usv(void *_glfuncs, GLuint index, const GLushort* v);
+void gl3_0_glVertexAttrib4uiv(void *_glfuncs, GLuint index, const GLuint* v);
+void gl3_0_glVertexAttrib4ubv(void *_glfuncs, GLuint index, const GLubyte* v);
+void gl3_0_glVertexAttrib4sv(void *_glfuncs, GLuint index, const GLshort* v);
+void gl3_0_glVertexAttrib4s(void *_glfuncs, GLuint index, GLshort x, GLshort y, GLshort z, GLshort w);
+void gl3_0_glVertexAttrib4iv(void *_glfuncs, GLuint index, const GLint* v);
+void gl3_0_glVertexAttrib4fv(void *_glfuncs, GLuint index, const GLfloat* v);
+void gl3_0_glVertexAttrib4f(void *_glfuncs, GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+void gl3_0_glVertexAttrib4dv(void *_glfuncs, GLuint index, const GLdouble* v);
+void gl3_0_glVertexAttrib4d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+void gl3_0_glVertexAttrib4bv(void *_glfuncs, GLuint index, const GLbyte* v);
+void gl3_0_glVertexAttrib4Nusv(void *_glfuncs, GLuint index, const GLushort* v);
+void gl3_0_glVertexAttrib4Nuiv(void *_glfuncs, GLuint index, const GLuint* v);
+void gl3_0_glVertexAttrib4Nubv(void *_glfuncs, GLuint index, const GLubyte* v);
+void gl3_0_glVertexAttrib4Nub(void *_glfuncs, GLuint index, GLubyte x, GLubyte y, GLubyte z, GLubyte w);
+void gl3_0_glVertexAttrib4Nsv(void *_glfuncs, GLuint index, const GLshort* v);
+void gl3_0_glVertexAttrib4Niv(void *_glfuncs, GLuint index, const GLint* v);
+void gl3_0_glVertexAttrib4Nbv(void *_glfuncs, GLuint index, const GLbyte* v);
+void gl3_0_glVertexAttrib3sv(void *_glfuncs, GLuint index, const GLshort* v);
+void gl3_0_glVertexAttrib3s(void *_glfuncs, GLuint index, GLshort x, GLshort y, GLshort z);
+void gl3_0_glVertexAttrib3fv(void *_glfuncs, GLuint index, const GLfloat* v);
+void gl3_0_glVertexAttrib3f(void *_glfuncs, GLuint index, GLfloat x, GLfloat y, GLfloat z);
+void gl3_0_glVertexAttrib3dv(void *_glfuncs, GLuint index, const GLdouble* v);
+void gl3_0_glVertexAttrib3d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y, GLdouble z);
+void gl3_0_glVertexAttrib2sv(void *_glfuncs, GLuint index, const GLshort* v);
+void gl3_0_glVertexAttrib2s(void *_glfuncs, GLuint index, GLshort x, GLshort y);
+void gl3_0_glVertexAttrib2fv(void *_glfuncs, GLuint index, const GLfloat* v);
+void gl3_0_glVertexAttrib2f(void *_glfuncs, GLuint index, GLfloat x, GLfloat y);
+void gl3_0_glVertexAttrib2dv(void *_glfuncs, GLuint index, const GLdouble* v);
+void gl3_0_glVertexAttrib2d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y);
+void gl3_0_glVertexAttrib1sv(void *_glfuncs, GLuint index, const GLshort* v);
+void gl3_0_glVertexAttrib1s(void *_glfuncs, GLuint index, GLshort x);
+void gl3_0_glVertexAttrib1fv(void *_glfuncs, GLuint index, const GLfloat* v);
+void gl3_0_glVertexAttrib1f(void *_glfuncs, GLuint index, GLfloat x);
+void gl3_0_glVertexAttrib1dv(void *_glfuncs, GLuint index, const GLdouble* v);
+void gl3_0_glVertexAttrib1d(void *_glfuncs, GLuint index, GLdouble x);
+void gl3_0_glVertexAttribI4usv(void *_glfuncs, GLuint index, const GLushort* v);
+void gl3_0_glVertexAttribI4ubv(void *_glfuncs, GLuint index, const GLubyte* v);
+void gl3_0_glVertexAttribI4sv(void *_glfuncs, GLuint index, const GLshort* v);
+void gl3_0_glVertexAttribI4bv(void *_glfuncs, GLuint index, const GLbyte* v);
+void gl3_0_glVertexAttribI4uiv(void *_glfuncs, GLuint index, const GLuint* v);
+void gl3_0_glVertexAttribI3uiv(void *_glfuncs, GLuint index, const GLuint* v);
+void gl3_0_glVertexAttribI2uiv(void *_glfuncs, GLuint index, const GLuint* v);
+void gl3_0_glVertexAttribI1uiv(void *_glfuncs, GLuint index, const GLuint* v);
+void gl3_0_glVertexAttribI4iv(void *_glfuncs, GLuint index, const GLint* v);
+void gl3_0_glVertexAttribI3iv(void *_glfuncs, GLuint index, const GLint* v);
+void gl3_0_glVertexAttribI2iv(void *_glfuncs, GLuint index, const GLint* v);
+void gl3_0_glVertexAttribI1iv(void *_glfuncs, GLuint index, const GLint* v);
+void gl3_0_glVertexAttribI4ui(void *_glfuncs, GLuint index, GLuint x, GLuint y, GLuint z, GLuint w);
+void gl3_0_glVertexAttribI3ui(void *_glfuncs, GLuint index, GLuint x, GLuint y, GLuint z);
+void gl3_0_glVertexAttribI2ui(void *_glfuncs, GLuint index, GLuint x, GLuint y);
+void gl3_0_glVertexAttribI1ui(void *_glfuncs, GLuint index, GLuint x);
+void gl3_0_glVertexAttribI4i(void *_glfuncs, GLuint index, GLint x, GLint y, GLint z, GLint w);
+void gl3_0_glVertexAttribI3i(void *_glfuncs, GLuint index, GLint x, GLint y, GLint z);
+void gl3_0_glVertexAttribI2i(void *_glfuncs, GLuint index, GLint x, GLint y);
+void gl3_0_glVertexAttribI1i(void *_glfuncs, GLuint index, GLint x);
+
+
+#ifdef __cplusplus
+} // extern "C"
+#endif
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/3.0/gl.go b/Godeps/_workspace/src/github.com/obscuren/qml/gl/3.0/gl.go
new file mode 100644
index 000000000..a8509aecd
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/3.0/gl.go
@@ -0,0 +1,7663 @@
+// ** file automatically generated by glgen -- do not edit manually **
+
+package GL
+
+// #cgo CXXFLAGS: -std=c++0x -pedantic-errors -Wall -fno-strict-aliasing
+// #cgo LDFLAGS: -lstdc++
+// #cgo pkg-config: Qt5Core Qt5OpenGL
+//
+// #include "funcs.h"
+//
+// void free(void*);
+//
+import "C"
+
+import (
+ "fmt"
+ "reflect"
+ "unsafe"
+
+ "gopkg.in/qml.v1/gl/glbase"
+)
+
+// API returns a value that offers methods matching the OpenGL version 3.0 API.
+//
+// The returned API must not be used after the provided OpenGL context becomes invalid.
+func API(context glbase.Contexter) *GL {
+ gl := &GL{}
+ gl.funcs = C.gl3_0_funcs()
+ if gl.funcs == nil {
+ panic(fmt.Errorf("OpenGL version 3.0 is not available"))
+ }
+ return gl
+}
+
+// GL implements the OpenGL version 3.0 API. Values of this
+// type must be created via the API function, and it must not be used after
+// the associated OpenGL context becomes invalid.
+type GL struct {
+ funcs unsafe.Pointer
+}
+
+const (
+ FALSE = 0
+ TRUE = 1
+ NONE = 0
+
+ BYTE = 0x1400
+ UNSIGNED_BYTE = 0x1401
+ SHORT = 0x1402
+ UNSIGNED_SHORT = 0x1403
+ INT = 0x1404
+ UNSIGNED_INT = 0x1405
+ FLOAT = 0x1406
+ N2_BYTES = 0x1407
+ N3_BYTES = 0x1408
+ N4_BYTES = 0x1409
+ DOUBLE = 0x140A
+ HALF_FLOAT = 0x140B
+
+ ACCUM = 0x0100
+ LOAD = 0x0101
+ RETURN = 0x0102
+ MULT = 0x0103
+ ADD = 0x0104
+
+ ACCUM_BUFFER_BIT = 0x00000200
+ ALL_ATTRIB_BITS = 0xFFFFFFFF
+ COLOR_BUFFER_BIT = 0x00004000
+ CURRENT_BIT = 0x00000001
+ DEPTH_BUFFER_BIT = 0x00000100
+ ENABLE_BIT = 0x00002000
+ EVAL_BIT = 0x00010000
+ FOG_BIT = 0x00000080
+ HINT_BIT = 0x00008000
+ LIGHTING_BIT = 0x00000040
+ LINE_BIT = 0x00000004
+ LIST_BIT = 0x00020000
+ MULTISAMPLE_BIT = 0x20000000
+ PIXEL_MODE_BIT = 0x00000020
+ POINT_BIT = 0x00000002
+ POLYGON_BIT = 0x00000008
+ POLYGON_STIPPLE_BIT = 0x00000010
+ SCISSOR_BIT = 0x00080000
+ STENCIL_BUFFER_BIT = 0x00000400
+ TEXTURE_BIT = 0x00040000
+ TRANSFORM_BIT = 0x00001000
+ VIEWPORT_BIT = 0x00000800
+
+ ALWAYS = 0x0207
+ EQUAL = 0x0202
+ GEQUAL = 0x0206
+ GREATER = 0x0204
+ LEQUAL = 0x0203
+ LESS = 0x0201
+ NEVER = 0x0200
+ NOTEQUAL = 0x0205
+
+ LOGIC_OP = 0x0BF1
+
+ DST_ALPHA = 0x0304
+ ONE = 1
+ ONE_MINUS_DST_ALPHA = 0x0305
+ ONE_MINUS_SRC_ALPHA = 0x0303
+ ONE_MINUS_SRC_COLOR = 0x0301
+ SRC_ALPHA = 0x0302
+ SRC_COLOR = 0x0300
+ ZERO = 0
+
+ DST_COLOR = 0x0306
+ ONE_MINUS_DST_COLOR = 0x0307
+ SRC_ALPHA_SATURATE = 0x0308
+
+ CLIENT_ALL_ATTRIB_BITS = 0xFFFFFFFF
+ CLIENT_PIXEL_STORE_BIT = 0x00000001
+ CLIENT_VERTEX_ARRAY_BIT = 0x00000002
+
+ CLIP_DISTANCE0 = 0x3000
+ CLIP_DISTANCE1 = 0x3001
+ CLIP_DISTANCE2 = 0x3002
+ CLIP_DISTANCE3 = 0x3003
+ CLIP_DISTANCE4 = 0x3004
+ CLIP_DISTANCE5 = 0x3005
+ CLIP_DISTANCE6 = 0x3006
+ CLIP_DISTANCE7 = 0x3007
+ CLIP_PLANE0 = 0x3000
+ CLIP_PLANE1 = 0x3001
+ CLIP_PLANE2 = 0x3002
+ CLIP_PLANE3 = 0x3003
+ CLIP_PLANE4 = 0x3004
+ CLIP_PLANE5 = 0x3005
+
+ BACK = 0x0405
+ FRONT = 0x0404
+ FRONT_AND_BACK = 0x0408
+
+ AMBIENT = 0x1200
+ AMBIENT_AND_DIFFUSE = 0x1602
+ DIFFUSE = 0x1201
+ EMISSION = 0x1600
+ SPECULAR = 0x1202
+
+ CONTEXT_FLAG_FORWARD_COMPATIBLE_BIT = 0x00000001
+
+ AUX0 = 0x0409
+ AUX1 = 0x040A
+ AUX2 = 0x040B
+ AUX3 = 0x040C
+ BACK_LEFT = 0x0402
+ BACK_RIGHT = 0x0403
+ FRONT_LEFT = 0x0400
+ FRONT_RIGHT = 0x0401
+ LEFT = 0x0406
+ RIGHT = 0x0407
+
+ ALPHA_TEST = 0x0BC0
+ AUTO_NORMAL = 0x0D80
+ BLEND = 0x0BE2
+ COLOR_ARRAY = 0x8076
+ COLOR_LOGIC_OP = 0x0BF2
+ COLOR_MATERIAL = 0x0B57
+ CULL_FACE = 0x0B44
+ DEPTH_TEST = 0x0B71
+ DITHER = 0x0BD0
+ EDGE_FLAG_ARRAY = 0x8079
+ FOG = 0x0B60
+ INDEX_ARRAY = 0x8077
+ INDEX_LOGIC_OP = 0x0BF1
+ LIGHT0 = 0x4000
+ LIGHT1 = 0x4001
+ LIGHT2 = 0x4002
+ LIGHT3 = 0x4003
+ LIGHT4 = 0x4004
+ LIGHT5 = 0x4005
+ LIGHT6 = 0x4006
+ LIGHT7 = 0x4007
+ LIGHTING = 0x0B50
+ LINE_SMOOTH = 0x0B20
+ LINE_STIPPLE = 0x0B24
+ MAP1_COLOR_4 = 0x0D90
+ MAP1_INDEX = 0x0D91
+ MAP1_NORMAL = 0x0D92
+ MAP1_TEXTURE_COORD_1 = 0x0D93
+ MAP1_TEXTURE_COORD_2 = 0x0D94
+ MAP1_TEXTURE_COORD_3 = 0x0D95
+ MAP1_TEXTURE_COORD_4 = 0x0D96
+ MAP1_VERTEX_3 = 0x0D97
+ MAP1_VERTEX_4 = 0x0D98
+ MAP2_COLOR_4 = 0x0DB0
+ MAP2_INDEX = 0x0DB1
+ MAP2_NORMAL = 0x0DB2
+ MAP2_TEXTURE_COORD_1 = 0x0DB3
+ MAP2_TEXTURE_COORD_2 = 0x0DB4
+ MAP2_TEXTURE_COORD_3 = 0x0DB5
+ MAP2_TEXTURE_COORD_4 = 0x0DB6
+ MAP2_VERTEX_3 = 0x0DB7
+ MAP2_VERTEX_4 = 0x0DB8
+ NORMALIZE = 0x0BA1
+ NORMAL_ARRAY = 0x8075
+ POINT_SMOOTH = 0x0B10
+ POLYGON_OFFSET_FILL = 0x8037
+ POLYGON_OFFSET_LINE = 0x2A02
+ POLYGON_OFFSET_POINT = 0x2A01
+ POLYGON_SMOOTH = 0x0B41
+ POLYGON_STIPPLE = 0x0B42
+ SCISSOR_TEST = 0x0C11
+ STENCIL_TEST = 0x0B90
+ TEXTURE_1D = 0x0DE0
+ TEXTURE_2D = 0x0DE1
+ TEXTURE_COORD_ARRAY = 0x8078
+ TEXTURE_GEN_Q = 0x0C63
+ TEXTURE_GEN_R = 0x0C62
+ TEXTURE_GEN_S = 0x0C60
+ TEXTURE_GEN_T = 0x0C61
+ VERTEX_ARRAY = 0x8074
+
+ INVALID_ENUM = 0x0500
+ INVALID_FRAMEBUFFER_OPERATION = 0x0506
+ INVALID_OPERATION = 0x0502
+ INVALID_VALUE = 0x0501
+ NO_ERROR = 0
+ OUT_OF_MEMORY = 0x0505
+ STACK_OVERFLOW = 0x0503
+ STACK_UNDERFLOW = 0x0504
+
+ N2D = 0x0600
+ N3D = 0x0601
+ N3D_COLOR = 0x0602
+ N3D_COLOR_TEXTURE = 0x0603
+ N4D_COLOR_TEXTURE = 0x0604
+
+ BITMAP_TOKEN = 0x0704
+ COPY_PIXEL_TOKEN = 0x0706
+ DRAW_PIXEL_TOKEN = 0x0705
+ LINE_RESET_TOKEN = 0x0707
+ LINE_TOKEN = 0x0702
+ PASS_THROUGH_TOKEN = 0x0700
+ POINT_TOKEN = 0x0701
+ POLYGON_TOKEN = 0x0703
+
+ EXP = 0x0800
+ EXP2 = 0x0801
+ LINEAR = 0x2601
+
+ FOG_COLOR = 0x0B66
+ FOG_DENSITY = 0x0B62
+ FOG_END = 0x0B64
+ FOG_INDEX = 0x0B61
+ FOG_MODE = 0x0B65
+ FOG_START = 0x0B63
+
+ CCW = 0x0901
+ CW = 0x0900
+
+ COEFF = 0x0A00
+ DOMAIN = 0x0A02
+ ORDER = 0x0A01
+
+ PIXEL_MAP_A_TO_A = 0x0C79
+ PIXEL_MAP_B_TO_B = 0x0C78
+ PIXEL_MAP_G_TO_G = 0x0C77
+ PIXEL_MAP_I_TO_A = 0x0C75
+ PIXEL_MAP_I_TO_B = 0x0C74
+ PIXEL_MAP_I_TO_G = 0x0C73
+ PIXEL_MAP_I_TO_I = 0x0C70
+ PIXEL_MAP_I_TO_R = 0x0C72
+ PIXEL_MAP_R_TO_R = 0x0C76
+ PIXEL_MAP_S_TO_S = 0x0C71
+
+ ACCUM_ALPHA_BITS = 0x0D5B
+ ACCUM_BLUE_BITS = 0x0D5A
+ ACCUM_CLEAR_VALUE = 0x0B80
+ ACCUM_GREEN_BITS = 0x0D59
+ ACCUM_RED_BITS = 0x0D58
+ ALIASED_LINE_WIDTH_RANGE = 0x846E
+ ALIASED_POINT_SIZE_RANGE = 0x846D
+ ALPHA_BIAS = 0x0D1D
+ ALPHA_BITS = 0x0D55
+ ALPHA_SCALE = 0x0D1C
+ ALPHA_TEST_FUNC = 0x0BC1
+ ALPHA_TEST_REF = 0x0BC2
+ ATTRIB_STACK_DEPTH = 0x0BB0
+ AUX_BUFFERS = 0x0C00
+ BLEND_DST = 0x0BE0
+ BLEND_SRC = 0x0BE1
+ BLUE_BIAS = 0x0D1B
+ BLUE_BITS = 0x0D54
+ BLUE_SCALE = 0x0D1A
+ CLIENT_ATTRIB_STACK_DEPTH = 0x0BB1
+ COLOR_ARRAY_SIZE = 0x8081
+ COLOR_ARRAY_STRIDE = 0x8083
+ COLOR_ARRAY_TYPE = 0x8082
+ COLOR_CLEAR_VALUE = 0x0C22
+ COLOR_MATERIAL_FACE = 0x0B55
+ COLOR_MATERIAL_PARAMETER = 0x0B56
+ COLOR_WRITEMASK = 0x0C23
+ CULL_FACE_MODE = 0x0B45
+ CURRENT_COLOR = 0x0B00
+ CURRENT_INDEX = 0x0B01
+ CURRENT_NORMAL = 0x0B02
+ CURRENT_RASTER_COLOR = 0x0B04
+ CURRENT_RASTER_DISTANCE = 0x0B09
+ CURRENT_RASTER_INDEX = 0x0B05
+ CURRENT_RASTER_POSITION = 0x0B07
+ CURRENT_RASTER_POSITION_VALID = 0x0B08
+ CURRENT_RASTER_TEXTURE_COORDS = 0x0B06
+ CURRENT_TEXTURE_COORDS = 0x0B03
+ DEPTH_BIAS = 0x0D1F
+ DEPTH_BITS = 0x0D56
+ DEPTH_CLEAR_VALUE = 0x0B73
+ DEPTH_FUNC = 0x0B74
+ DEPTH_RANGE = 0x0B70
+ DEPTH_SCALE = 0x0D1E
+ DEPTH_WRITEMASK = 0x0B72
+ DOUBLEBUFFER = 0x0C32
+ DRAW_BUFFER = 0x0C01
+ EDGE_FLAG = 0x0B43
+ EDGE_FLAG_ARRAY_STRIDE = 0x808C
+ FEEDBACK_BUFFER_SIZE = 0x0DF1
+ FEEDBACK_BUFFER_TYPE = 0x0DF2
+ FOG_HINT = 0x0C54
+ FRONT_FACE = 0x0B46
+ GREEN_BIAS = 0x0D19
+ GREEN_BITS = 0x0D53
+ GREEN_SCALE = 0x0D18
+ INDEX_ARRAY_STRIDE = 0x8086
+ INDEX_ARRAY_TYPE = 0x8085
+ INDEX_BITS = 0x0D51
+ INDEX_CLEAR_VALUE = 0x0C20
+ INDEX_MODE = 0x0C30
+ INDEX_OFFSET = 0x0D13
+ INDEX_SHIFT = 0x0D12
+ INDEX_WRITEMASK = 0x0C21
+ LIGHT_MODEL_AMBIENT = 0x0B53
+ LIGHT_MODEL_COLOR_CONTROL = 0x81F8
+ LIGHT_MODEL_LOCAL_VIEWER = 0x0B51
+ LIGHT_MODEL_TWO_SIDE = 0x0B52
+ LINE_SMOOTH_HINT = 0x0C52
+ LINE_STIPPLE_PATTERN = 0x0B25
+ LINE_STIPPLE_REPEAT = 0x0B26
+ LINE_WIDTH = 0x0B21
+ LINE_WIDTH_GRANULARITY = 0x0B23
+ LINE_WIDTH_RANGE = 0x0B22
+ LIST_BASE = 0x0B32
+ LIST_INDEX = 0x0B33
+ LIST_MODE = 0x0B30
+ LOGIC_OP_MODE = 0x0BF0
+ MAP1_GRID_DOMAIN = 0x0DD0
+ MAP1_GRID_SEGMENTS = 0x0DD1
+ MAP2_GRID_DOMAIN = 0x0DD2
+ MAP2_GRID_SEGMENTS = 0x0DD3
+ MAP_COLOR = 0x0D10
+ MAP_STENCIL = 0x0D11
+ MATRIX_MODE = 0x0BA0
+ MAX_ATTRIB_STACK_DEPTH = 0x0D35
+ MAX_CLIENT_ATTRIB_STACK_DEPTH = 0x0D3B
+ MAX_CLIP_DISTANCES = 0x0D32
+ MAX_CLIP_PLANES = 0x0D32
+ MAX_EVAL_ORDER = 0x0D30
+ MAX_LIGHTS = 0x0D31
+ MAX_LIST_NESTING = 0x0B31
+ MAX_MODELVIEW_STACK_DEPTH = 0x0D36
+ MAX_NAME_STACK_DEPTH = 0x0D37
+ MAX_PIXEL_MAP_TABLE = 0x0D34
+ MAX_PROJECTION_STACK_DEPTH = 0x0D38
+ MAX_TEXTURE_SIZE = 0x0D33
+ MAX_TEXTURE_STACK_DEPTH = 0x0D39
+ MAX_VIEWPORT_DIMS = 0x0D3A
+ MODELVIEW_MATRIX = 0x0BA6
+ MODELVIEW_STACK_DEPTH = 0x0BA3
+ NAME_STACK_DEPTH = 0x0D70
+ NORMAL_ARRAY_STRIDE = 0x807F
+ NORMAL_ARRAY_TYPE = 0x807E
+ PACK_ALIGNMENT = 0x0D05
+ PACK_LSB_FIRST = 0x0D01
+ PACK_ROW_LENGTH = 0x0D02
+ PACK_SKIP_PIXELS = 0x0D04
+ PACK_SKIP_ROWS = 0x0D03
+ PACK_SWAP_BYTES = 0x0D00
+ PERSPECTIVE_CORRECTION_HINT = 0x0C50
+ PIXEL_MAP_A_TO_A_SIZE = 0x0CB9
+ PIXEL_MAP_B_TO_B_SIZE = 0x0CB8
+ PIXEL_MAP_G_TO_G_SIZE = 0x0CB7
+ PIXEL_MAP_I_TO_A_SIZE = 0x0CB5
+ PIXEL_MAP_I_TO_B_SIZE = 0x0CB4
+ PIXEL_MAP_I_TO_G_SIZE = 0x0CB3
+ PIXEL_MAP_I_TO_I_SIZE = 0x0CB0
+ PIXEL_MAP_I_TO_R_SIZE = 0x0CB2
+ PIXEL_MAP_R_TO_R_SIZE = 0x0CB6
+ PIXEL_MAP_S_TO_S_SIZE = 0x0CB1
+ POINT_SIZE = 0x0B11
+ POINT_SIZE_GRANULARITY = 0x0B13
+ POINT_SIZE_RANGE = 0x0B12
+ POINT_SMOOTH_HINT = 0x0C51
+ POLYGON_MODE = 0x0B40
+ POLYGON_OFFSET_FACTOR = 0x8038
+ POLYGON_OFFSET_UNITS = 0x2A00
+ POLYGON_SMOOTH_HINT = 0x0C53
+ PROJECTION_MATRIX = 0x0BA7
+ PROJECTION_STACK_DEPTH = 0x0BA4
+ READ_BUFFER = 0x0C02
+ RED_BIAS = 0x0D15
+ RED_BITS = 0x0D52
+ RED_SCALE = 0x0D14
+ RENDER_MODE = 0x0C40
+ RGBA_MODE = 0x0C31
+ SCISSOR_BOX = 0x0C10
+ SELECTION_BUFFER_SIZE = 0x0DF4
+ SHADE_MODEL = 0x0B54
+ SMOOTH_LINE_WIDTH_GRANULARITY = 0x0B23
+ SMOOTH_LINE_WIDTH_RANGE = 0x0B22
+ SMOOTH_POINT_SIZE_GRANULARITY = 0x0B13
+ SMOOTH_POINT_SIZE_RANGE = 0x0B12
+ STENCIL_BITS = 0x0D57
+ STENCIL_CLEAR_VALUE = 0x0B91
+ STENCIL_FAIL = 0x0B94
+ STENCIL_FUNC = 0x0B92
+ STENCIL_PASS_DEPTH_FAIL = 0x0B95
+ STENCIL_PASS_DEPTH_PASS = 0x0B96
+ STENCIL_REF = 0x0B97
+ STENCIL_VALUE_MASK = 0x0B93
+ STENCIL_WRITEMASK = 0x0B98
+ STEREO = 0x0C33
+ SUBPIXEL_BITS = 0x0D50
+ TEXTURE_BINDING_1D = 0x8068
+ TEXTURE_BINDING_2D = 0x8069
+ TEXTURE_BINDING_3D = 0x806A
+ TEXTURE_COORD_ARRAY_SIZE = 0x8088
+ TEXTURE_COORD_ARRAY_STRIDE = 0x808A
+ TEXTURE_COORD_ARRAY_TYPE = 0x8089
+ TEXTURE_MATRIX = 0x0BA8
+ TEXTURE_STACK_DEPTH = 0x0BA5
+ UNPACK_ALIGNMENT = 0x0CF5
+ UNPACK_LSB_FIRST = 0x0CF1
+ UNPACK_ROW_LENGTH = 0x0CF2
+ UNPACK_SKIP_PIXELS = 0x0CF4
+ UNPACK_SKIP_ROWS = 0x0CF3
+ UNPACK_SWAP_BYTES = 0x0CF0
+ VERTEX_ARRAY_SIZE = 0x807A
+ VERTEX_ARRAY_STRIDE = 0x807C
+ VERTEX_ARRAY_TYPE = 0x807B
+ VIEWPORT = 0x0BA2
+ ZOOM_X = 0x0D16
+ ZOOM_Y = 0x0D17
+
+ COLOR_ARRAY_POINTER = 0x8090
+ EDGE_FLAG_ARRAY_POINTER = 0x8093
+ FEEDBACK_BUFFER_POINTER = 0x0DF0
+ INDEX_ARRAY_POINTER = 0x8091
+ NORMAL_ARRAY_POINTER = 0x808F
+ SELECTION_BUFFER_POINTER = 0x0DF3
+ TEXTURE_COORD_ARRAY_POINTER = 0x8092
+ VERTEX_ARRAY_POINTER = 0x808E
+
+ TEXTURE_ALPHA_SIZE = 0x805F
+ TEXTURE_BLUE_SIZE = 0x805E
+ TEXTURE_BORDER = 0x1005
+ TEXTURE_BORDER_COLOR = 0x1004
+ TEXTURE_COMPONENTS = 0x1003
+ TEXTURE_GREEN_SIZE = 0x805D
+ TEXTURE_HEIGHT = 0x1001
+ TEXTURE_INTENSITY_SIZE = 0x8061
+ TEXTURE_INTERNAL_FORMAT = 0x1003
+ TEXTURE_LUMINANCE_SIZE = 0x8060
+ TEXTURE_MAG_FILTER = 0x2800
+ TEXTURE_MIN_FILTER = 0x2801
+ TEXTURE_PRIORITY = 0x8066
+ TEXTURE_RED_SIZE = 0x805C
+ TEXTURE_RESIDENT = 0x8067
+ TEXTURE_WIDTH = 0x1000
+ TEXTURE_WRAP_S = 0x2802
+ TEXTURE_WRAP_T = 0x2803
+
+ DONT_CARE = 0x1100
+ FASTEST = 0x1101
+ NICEST = 0x1102
+
+ FRAGMENT_SHADER_DERIVATIVE_HINT = 0x8B8B
+ GENERATE_MIPMAP_HINT = 0x8192
+ TEXTURE_COMPRESSION_HINT = 0x84EF
+
+ C3F_V3F = 0x2A24
+ C4F_N3F_V3F = 0x2A26
+ C4UB_V2F = 0x2A22
+ C4UB_V3F = 0x2A23
+ N3F_V3F = 0x2A25
+ T2F_C3F_V3F = 0x2A2A
+ T2F_C4F_N3F_V3F = 0x2A2C
+ T2F_C4UB_V3F = 0x2A29
+ T2F_N3F_V3F = 0x2A2B
+ T2F_V3F = 0x2A27
+ T4F_C4F_N3F_V4F = 0x2A2D
+ T4F_V4F = 0x2A28
+ V2F = 0x2A20
+ V3F = 0x2A21
+
+ MODULATE = 0x2100
+ REPLACE = 0x1E01
+
+ SEPARATE_SPECULAR_COLOR = 0x81FA
+ SINGLE_COLOR = 0x81F9
+
+ CONSTANT_ATTENUATION = 0x1207
+ LINEAR_ATTENUATION = 0x1208
+ POSITION = 0x1203
+ QUADRATIC_ATTENUATION = 0x1209
+ SPOT_CUTOFF = 0x1206
+ SPOT_DIRECTION = 0x1204
+ SPOT_EXPONENT = 0x1205
+
+ COMPILE = 0x1300
+ COMPILE_AND_EXECUTE = 0x1301
+
+ AND = 0x1501
+ AND_INVERTED = 0x1504
+ AND_REVERSE = 0x1502
+ CLEAR = 0x1500
+ COPY = 0x1503
+ COPY_INVERTED = 0x150C
+ EQUIV = 0x1509
+ INVERT = 0x150A
+ NAND = 0x150E
+ NOOP = 0x1505
+ NOR = 0x1508
+ OR = 0x1507
+ OR_INVERTED = 0x150D
+ OR_REVERSE = 0x150B
+ SET = 0x150F
+ XOR = 0x1506
+
+ MAP_FLUSH_EXPLICIT_BIT = 0x0010
+ MAP_INVALIDATE_BUFFER_BIT = 0x0008
+ MAP_INVALIDATE_RANGE_BIT = 0x0004
+ MAP_READ_BIT = 0x0001
+ MAP_UNSYNCHRONIZED_BIT = 0x0020
+ MAP_WRITE_BIT = 0x0002
+
+ COLOR_INDEXES = 0x1603
+ SHININESS = 0x1601
+
+ MODELVIEW = 0x1700
+ PROJECTION = 0x1701
+ TEXTURE = 0x1702
+
+ LINE = 0x1B01
+ POINT = 0x1B00
+
+ FILL = 0x1B02
+
+ COLOR = 0x1800
+ DEPTH = 0x1801
+ STENCIL = 0x1802
+
+ ALPHA = 0x1906
+ BLUE = 0x1905
+ COLOR_INDEX = 0x1900
+ DEPTH_COMPONENT = 0x1902
+ GREEN = 0x1904
+ LUMINANCE = 0x1909
+ LUMINANCE_ALPHA = 0x190A
+ RED = 0x1903
+ RGB = 0x1907
+ RGBA = 0x1908
+ STENCIL_INDEX = 0x1901
+
+ ALPHA12 = 0x803D
+ ALPHA16 = 0x803E
+ ALPHA4 = 0x803B
+ ALPHA8 = 0x803C
+ INTENSITY = 0x8049
+ INTENSITY12 = 0x804C
+ INTENSITY16 = 0x804D
+ INTENSITY4 = 0x804A
+ INTENSITY8 = 0x804B
+ LUMINANCE12 = 0x8041
+ LUMINANCE12_ALPHA12 = 0x8047
+ LUMINANCE12_ALPHA4 = 0x8046
+ LUMINANCE16 = 0x8042
+ LUMINANCE16_ALPHA16 = 0x8048
+ LUMINANCE4 = 0x803F
+ LUMINANCE4_ALPHA4 = 0x8043
+ LUMINANCE6_ALPHA2 = 0x8044
+ LUMINANCE8 = 0x8040
+ LUMINANCE8_ALPHA8 = 0x8045
+ R3_G3_B2 = 0x2A10
+ RGB10 = 0x8052
+ RGB10_A2 = 0x8059
+ RGB12 = 0x8053
+ RGB16 = 0x8054
+ RGB4 = 0x804F
+ RGB5 = 0x8050
+ RGB5_A1 = 0x8057
+ RGB8 = 0x8051
+ RGBA12 = 0x805A
+ RGBA16 = 0x805B
+ RGBA2 = 0x8055
+ RGBA4 = 0x8056
+ RGBA8 = 0x8058
+
+ PACK_IMAGE_HEIGHT = 0x806C
+ PACK_SKIP_IMAGES = 0x806B
+ UNPACK_IMAGE_HEIGHT = 0x806E
+ UNPACK_SKIP_IMAGES = 0x806D
+
+ BITMAP = 0x1A00
+ UNSIGNED_BYTE_3_3_2 = 0x8032
+ UNSIGNED_INT_10_10_10_2 = 0x8036
+ UNSIGNED_INT_8_8_8_8 = 0x8035
+ UNSIGNED_SHORT_4_4_4_4 = 0x8033
+ UNSIGNED_SHORT_5_5_5_1 = 0x8034
+
+ POINT_DISTANCE_ATTENUATION = 0x8129
+ POINT_FADE_THRESHOLD_SIZE = 0x8128
+ POINT_SIZE_MAX = 0x8127
+ POINT_SIZE_MIN = 0x8126
+
+ LINES = 0x0001
+ LINE_LOOP = 0x0002
+ LINE_STRIP = 0x0003
+ POINTS = 0x0000
+ POLYGON = 0x0009
+ QUADS = 0x0007
+ QUAD_STRIP = 0x0008
+ TRIANGLES = 0x0004
+ TRIANGLE_FAN = 0x0006
+ TRIANGLE_STRIP = 0x0005
+
+ FEEDBACK = 0x1C01
+ RENDER = 0x1C00
+ SELECT = 0x1C02
+
+ FLAT = 0x1D00
+ SMOOTH = 0x1D01
+
+ DECR = 0x1E03
+ INCR = 0x1E02
+ KEEP = 0x1E00
+
+ EXTENSIONS = 0x1F03
+ RENDERER = 0x1F01
+ VENDOR = 0x1F00
+ VERSION = 0x1F02
+
+ S = 0x2000
+ T = 0x2001
+ R = 0x2002
+ Q = 0x2003
+
+ DECAL = 0x2101
+
+ TEXTURE_ENV_COLOR = 0x2201
+ TEXTURE_ENV_MODE = 0x2200
+
+ TEXTURE_ENV = 0x2300
+
+ EYE_LINEAR = 0x2400
+ OBJECT_LINEAR = 0x2401
+ SPHERE_MAP = 0x2402
+
+ EYE_PLANE = 0x2502
+ OBJECT_PLANE = 0x2501
+ TEXTURE_GEN_MODE = 0x2500
+
+ NEAREST = 0x2600
+
+ LINEAR_MIPMAP_LINEAR = 0x2703
+ LINEAR_MIPMAP_NEAREST = 0x2701
+ NEAREST_MIPMAP_LINEAR = 0x2702
+ NEAREST_MIPMAP_NEAREST = 0x2700
+
+ GENERATE_MIPMAP = 0x8191
+ TEXTURE_WRAP_R = 0x8072
+
+ PROXY_TEXTURE_1D = 0x8063
+ PROXY_TEXTURE_2D = 0x8064
+ PROXY_TEXTURE_3D = 0x8070
+ TEXTURE_3D = 0x806F
+ TEXTURE_BASE_LEVEL = 0x813C
+ TEXTURE_MAX_LEVEL = 0x813D
+ TEXTURE_MAX_LOD = 0x813B
+ TEXTURE_MIN_LOD = 0x813A
+
+ CLAMP = 0x2900
+ CLAMP_TO_BORDER = 0x812D
+ CLAMP_TO_EDGE = 0x812F
+ REPEAT = 0x2901
+
+ CONSTANT_COLOR = 0x8001
+ ONE_MINUS_CONSTANT_COLOR = 0x8002
+ CONSTANT_ALPHA = 0x8003
+ ONE_MINUS_CONSTANT_ALPHA = 0x8004
+ FUNC_ADD = 0x8006
+ MIN = 0x8007
+ MAX = 0x8008
+ BLEND_EQUATION_RGB = 0x8009
+ FUNC_SUBTRACT = 0x800A
+ FUNC_REVERSE_SUBTRACT = 0x800B
+ RESCALE_NORMAL = 0x803A
+ TEXTURE_DEPTH = 0x8071
+ MAX_3D_TEXTURE_SIZE = 0x8073
+ MULTISAMPLE = 0x809D
+ SAMPLE_ALPHA_TO_COVERAGE = 0x809E
+ SAMPLE_ALPHA_TO_ONE = 0x809F
+ SAMPLE_COVERAGE = 0x80A0
+ SAMPLE_BUFFERS = 0x80A8
+ SAMPLES = 0x80A9
+ SAMPLE_COVERAGE_VALUE = 0x80AA
+ SAMPLE_COVERAGE_INVERT = 0x80AB
+ BLEND_DST_RGB = 0x80C8
+ BLEND_SRC_RGB = 0x80C9
+ BLEND_DST_ALPHA = 0x80CA
+ BLEND_SRC_ALPHA = 0x80CB
+ BGR = 0x80E0
+ BGRA = 0x80E1
+ MAX_ELEMENTS_VERTICES = 0x80E8
+ MAX_ELEMENTS_INDICES = 0x80E9
+ DEPTH_COMPONENT16 = 0x81A5
+ DEPTH_COMPONENT24 = 0x81A6
+ DEPTH_COMPONENT32 = 0x81A7
+ FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING = 0x8210
+ FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE = 0x8211
+ FRAMEBUFFER_ATTACHMENT_RED_SIZE = 0x8212
+ FRAMEBUFFER_ATTACHMENT_GREEN_SIZE = 0x8213
+ FRAMEBUFFER_ATTACHMENT_BLUE_SIZE = 0x8214
+ FRAMEBUFFER_ATTACHMENT_ALPHA_SIZE = 0x8215
+ FRAMEBUFFER_ATTACHMENT_DEPTH_SIZE = 0x8216
+ FRAMEBUFFER_ATTACHMENT_STENCIL_SIZE = 0x8217
+ FRAMEBUFFER_DEFAULT = 0x8218
+ FRAMEBUFFER_UNDEFINED = 0x8219
+ DEPTH_STENCIL_ATTACHMENT = 0x821A
+ MAJOR_VERSION = 0x821B
+ MINOR_VERSION = 0x821C
+ NUM_EXTENSIONS = 0x821D
+ CONTEXT_FLAGS = 0x821E
+ COMPRESSED_RED = 0x8225
+ COMPRESSED_RG = 0x8226
+ RG = 0x8227
+ RG_INTEGER = 0x8228
+ R8 = 0x8229
+ R16 = 0x822A
+ RG8 = 0x822B
+ RG16 = 0x822C
+ R16F = 0x822D
+ R32F = 0x822E
+ RG16F = 0x822F
+ RG32F = 0x8230
+ R8I = 0x8231
+ R8UI = 0x8232
+ R16I = 0x8233
+ R16UI = 0x8234
+ R32I = 0x8235
+ R32UI = 0x8236
+ RG8I = 0x8237
+ RG8UI = 0x8238
+ RG16I = 0x8239
+ RG16UI = 0x823A
+ RG32I = 0x823B
+ RG32UI = 0x823C
+ UNSIGNED_BYTE_2_3_3_REV = 0x8362
+ UNSIGNED_SHORT_5_6_5 = 0x8363
+ UNSIGNED_SHORT_5_6_5_REV = 0x8364
+ UNSIGNED_SHORT_4_4_4_4_REV = 0x8365
+ UNSIGNED_SHORT_1_5_5_5_REV = 0x8366
+ UNSIGNED_INT_8_8_8_8_REV = 0x8367
+ UNSIGNED_INT_2_10_10_10_REV = 0x8368
+ MIRRORED_REPEAT = 0x8370
+ FOG_COORDINATE_SOURCE = 0x8450
+ FOG_COORD_SRC = 0x8450
+ FOG_COORDINATE = 0x8451
+ FOG_COORD = 0x8451
+ FRAGMENT_DEPTH = 0x8452
+ CURRENT_FOG_COORDINATE = 0x8453
+ CURRENT_FOG_COORD = 0x8453
+ FOG_COORDINATE_ARRAY_TYPE = 0x8454
+ FOG_COORD_ARRAY_TYPE = 0x8454
+ FOG_COORDINATE_ARRAY_STRIDE = 0x8455
+ FOG_COORD_ARRAY_STRIDE = 0x8455
+ FOG_COORDINATE_ARRAY_POINTER = 0x8456
+ FOG_COORD_ARRAY_POINTER = 0x8456
+ FOG_COORDINATE_ARRAY = 0x8457
+ FOG_COORD_ARRAY = 0x8457
+ COLOR_SUM = 0x8458
+ CURRENT_SECONDARY_COLOR = 0x8459
+ SECONDARY_COLOR_ARRAY_SIZE = 0x845A
+ SECONDARY_COLOR_ARRAY_TYPE = 0x845B
+ SECONDARY_COLOR_ARRAY_STRIDE = 0x845C
+ SECONDARY_COLOR_ARRAY_POINTER = 0x845D
+ SECONDARY_COLOR_ARRAY = 0x845E
+ CURRENT_RASTER_SECONDARY_COLOR = 0x845F
+ TEXTURE0 = 0x84C0
+ TEXTURE1 = 0x84C1
+ TEXTURE2 = 0x84C2
+ TEXTURE3 = 0x84C3
+ TEXTURE4 = 0x84C4
+ TEXTURE5 = 0x84C5
+ TEXTURE6 = 0x84C6
+ TEXTURE7 = 0x84C7
+ TEXTURE8 = 0x84C8
+ TEXTURE9 = 0x84C9
+ TEXTURE10 = 0x84CA
+ TEXTURE11 = 0x84CB
+ TEXTURE12 = 0x84CC
+ TEXTURE13 = 0x84CD
+ TEXTURE14 = 0x84CE
+ TEXTURE15 = 0x84CF
+ TEXTURE16 = 0x84D0
+ TEXTURE17 = 0x84D1
+ TEXTURE18 = 0x84D2
+ TEXTURE19 = 0x84D3
+ TEXTURE20 = 0x84D4
+ TEXTURE21 = 0x84D5
+ TEXTURE22 = 0x84D6
+ TEXTURE23 = 0x84D7
+ TEXTURE24 = 0x84D8
+ TEXTURE25 = 0x84D9
+ TEXTURE26 = 0x84DA
+ TEXTURE27 = 0x84DB
+ TEXTURE28 = 0x84DC
+ TEXTURE29 = 0x84DD
+ TEXTURE30 = 0x84DE
+ TEXTURE31 = 0x84DF
+ ACTIVE_TEXTURE = 0x84E0
+ CLIENT_ACTIVE_TEXTURE = 0x84E1
+ MAX_TEXTURE_UNITS = 0x84E2
+ TRANSPOSE_MODELVIEW_MATRIX = 0x84E3
+ TRANSPOSE_PROJECTION_MATRIX = 0x84E4
+ TRANSPOSE_TEXTURE_MATRIX = 0x84E5
+ TRANSPOSE_COLOR_MATRIX = 0x84E6
+ SUBTRACT = 0x84E7
+ MAX_RENDERBUFFER_SIZE = 0x84E8
+ COMPRESSED_ALPHA = 0x84E9
+ COMPRESSED_LUMINANCE = 0x84EA
+ COMPRESSED_LUMINANCE_ALPHA = 0x84EB
+ COMPRESSED_INTENSITY = 0x84EC
+ COMPRESSED_RGB = 0x84ED
+ COMPRESSED_RGBA = 0x84EE
+ DEPTH_STENCIL = 0x84F9
+ UNSIGNED_INT_24_8 = 0x84FA
+ MAX_TEXTURE_LOD_BIAS = 0x84FD
+ TEXTURE_FILTER_CONTROL = 0x8500
+ TEXTURE_LOD_BIAS = 0x8501
+ INCR_WRAP = 0x8507
+ DECR_WRAP = 0x8508
+ NORMAL_MAP = 0x8511
+ REFLECTION_MAP = 0x8512
+ TEXTURE_CUBE_MAP = 0x8513
+ TEXTURE_BINDING_CUBE_MAP = 0x8514
+ TEXTURE_CUBE_MAP_POSITIVE_X = 0x8515
+ TEXTURE_CUBE_MAP_NEGATIVE_X = 0x8516
+ TEXTURE_CUBE_MAP_POSITIVE_Y = 0x8517
+ TEXTURE_CUBE_MAP_NEGATIVE_Y = 0x8518
+ TEXTURE_CUBE_MAP_POSITIVE_Z = 0x8519
+ TEXTURE_CUBE_MAP_NEGATIVE_Z = 0x851A
+ PROXY_TEXTURE_CUBE_MAP = 0x851B
+ MAX_CUBE_MAP_TEXTURE_SIZE = 0x851C
+ COMBINE = 0x8570
+ COMBINE_RGB = 0x8571
+ COMBINE_ALPHA = 0x8572
+ RGB_SCALE = 0x8573
+ ADD_SIGNED = 0x8574
+ INTERPOLATE = 0x8575
+ CONSTANT = 0x8576
+ PRIMARY_COLOR = 0x8577
+ PREVIOUS = 0x8578
+ SOURCE0_RGB = 0x8580
+ SRC0_RGB = 0x8580
+ SOURCE1_RGB = 0x8581
+ SRC1_RGB = 0x8581
+ SOURCE2_RGB = 0x8582
+ SRC2_RGB = 0x8582
+ SOURCE0_ALPHA = 0x8588
+ SRC0_ALPHA = 0x8588
+ SOURCE1_ALPHA = 0x8589
+ SRC1_ALPHA = 0x8589
+ SOURCE2_ALPHA = 0x858A
+ SRC2_ALPHA = 0x858A
+ OPERAND0_RGB = 0x8590
+ OPERAND1_RGB = 0x8591
+ OPERAND2_RGB = 0x8592
+ OPERAND0_ALPHA = 0x8598
+ OPERAND1_ALPHA = 0x8599
+ OPERAND2_ALPHA = 0x859A
+ VERTEX_ARRAY_BINDING = 0x85B5
+ VERTEX_ATTRIB_ARRAY_ENABLED = 0x8622
+ VERTEX_ATTRIB_ARRAY_SIZE = 0x8623
+ VERTEX_ATTRIB_ARRAY_STRIDE = 0x8624
+ VERTEX_ATTRIB_ARRAY_TYPE = 0x8625
+ CURRENT_VERTEX_ATTRIB = 0x8626
+ VERTEX_PROGRAM_POINT_SIZE = 0x8642
+ VERTEX_PROGRAM_TWO_SIDE = 0x8643
+ VERTEX_ATTRIB_ARRAY_POINTER = 0x8645
+ TEXTURE_COMPRESSED_IMAGE_SIZE = 0x86A0
+ TEXTURE_COMPRESSED = 0x86A1
+ NUM_COMPRESSED_TEXTURE_FORMATS = 0x86A2
+ COMPRESSED_TEXTURE_FORMATS = 0x86A3
+ DOT3_RGB = 0x86AE
+ DOT3_RGBA = 0x86AF
+ BUFFER_SIZE = 0x8764
+ BUFFER_USAGE = 0x8765
+ STENCIL_BACK_FUNC = 0x8800
+ STENCIL_BACK_FAIL = 0x8801
+ STENCIL_BACK_PASS_DEPTH_FAIL = 0x8802
+ STENCIL_BACK_PASS_DEPTH_PASS = 0x8803
+ RGBA32F = 0x8814
+ RGB32F = 0x8815
+ RGBA16F = 0x881A
+ RGB16F = 0x881B
+ MAX_DRAW_BUFFERS = 0x8824
+ DRAW_BUFFER0 = 0x8825
+ DRAW_BUFFER1 = 0x8826
+ DRAW_BUFFER2 = 0x8827
+ DRAW_BUFFER3 = 0x8828
+ DRAW_BUFFER4 = 0x8829
+ DRAW_BUFFER5 = 0x882A
+ DRAW_BUFFER6 = 0x882B
+ DRAW_BUFFER7 = 0x882C
+ DRAW_BUFFER8 = 0x882D
+ DRAW_BUFFER9 = 0x882E
+ DRAW_BUFFER10 = 0x882F
+ DRAW_BUFFER11 = 0x8830
+ DRAW_BUFFER12 = 0x8831
+ DRAW_BUFFER13 = 0x8832
+ DRAW_BUFFER14 = 0x8833
+ DRAW_BUFFER15 = 0x8834
+ BLEND_EQUATION_ALPHA = 0x883D
+ TEXTURE_DEPTH_SIZE = 0x884A
+ DEPTH_TEXTURE_MODE = 0x884B
+ TEXTURE_COMPARE_MODE = 0x884C
+ TEXTURE_COMPARE_FUNC = 0x884D
+ COMPARE_R_TO_TEXTURE = 0x884E
+ COMPARE_REF_TO_TEXTURE = 0x884E
+ POINT_SPRITE = 0x8861
+ COORD_REPLACE = 0x8862
+ QUERY_COUNTER_BITS = 0x8864
+ CURRENT_QUERY = 0x8865
+ QUERY_RESULT = 0x8866
+ QUERY_RESULT_AVAILABLE = 0x8867
+ MAX_VERTEX_ATTRIBS = 0x8869
+ VERTEX_ATTRIB_ARRAY_NORMALIZED = 0x886A
+ MAX_TEXTURE_COORDS = 0x8871
+ MAX_TEXTURE_IMAGE_UNITS = 0x8872
+ ARRAY_BUFFER = 0x8892
+ ELEMENT_ARRAY_BUFFER = 0x8893
+ ARRAY_BUFFER_BINDING = 0x8894
+ ELEMENT_ARRAY_BUFFER_BINDING = 0x8895
+ VERTEX_ARRAY_BUFFER_BINDING = 0x8896
+ NORMAL_ARRAY_BUFFER_BINDING = 0x8897
+ COLOR_ARRAY_BUFFER_BINDING = 0x8898
+ INDEX_ARRAY_BUFFER_BINDING = 0x8899
+ TEXTURE_COORD_ARRAY_BUFFER_BINDING = 0x889A
+ EDGE_FLAG_ARRAY_BUFFER_BINDING = 0x889B
+ SECONDARY_COLOR_ARRAY_BUFFER_BINDING = 0x889C
+ FOG_COORDINATE_ARRAY_BUFFER_BINDING = 0x889D
+ FOG_COORD_ARRAY_BUFFER_BINDING = 0x889D
+ WEIGHT_ARRAY_BUFFER_BINDING = 0x889E
+ VERTEX_ATTRIB_ARRAY_BUFFER_BINDING = 0x889F
+ READ_ONLY = 0x88B8
+ WRITE_ONLY = 0x88B9
+ READ_WRITE = 0x88BA
+ BUFFER_ACCESS = 0x88BB
+ BUFFER_MAPPED = 0x88BC
+ BUFFER_MAP_POINTER = 0x88BD
+ STREAM_DRAW = 0x88E0
+ STREAM_READ = 0x88E1
+ STREAM_COPY = 0x88E2
+ STATIC_DRAW = 0x88E4
+ STATIC_READ = 0x88E5
+ STATIC_COPY = 0x88E6
+ DYNAMIC_DRAW = 0x88E8
+ DYNAMIC_READ = 0x88E9
+ DYNAMIC_COPY = 0x88EA
+ PIXEL_PACK_BUFFER = 0x88EB
+ PIXEL_UNPACK_BUFFER = 0x88EC
+ PIXEL_PACK_BUFFER_BINDING = 0x88ED
+ PIXEL_UNPACK_BUFFER_BINDING = 0x88EF
+ DEPTH24_STENCIL8 = 0x88F0
+ TEXTURE_STENCIL_SIZE = 0x88F1
+ VERTEX_ATTRIB_ARRAY_INTEGER = 0x88FD
+ MAX_ARRAY_TEXTURE_LAYERS = 0x88FF
+ MIN_PROGRAM_TEXEL_OFFSET = 0x8904
+ MAX_PROGRAM_TEXEL_OFFSET = 0x8905
+ SAMPLES_PASSED = 0x8914
+ CLAMP_VERTEX_COLOR = 0x891A
+ CLAMP_FRAGMENT_COLOR = 0x891B
+ CLAMP_READ_COLOR = 0x891C
+ FIXED_ONLY = 0x891D
+ FRAGMENT_SHADER = 0x8B30
+ VERTEX_SHADER = 0x8B31
+ MAX_FRAGMENT_UNIFORM_COMPONENTS = 0x8B49
+ MAX_VERTEX_UNIFORM_COMPONENTS = 0x8B4A
+ MAX_VARYING_FLOATS = 0x8B4B
+ MAX_VARYING_COMPONENTS = 0x8B4B
+ MAX_VERTEX_TEXTURE_IMAGE_UNITS = 0x8B4C
+ MAX_COMBINED_TEXTURE_IMAGE_UNITS = 0x8B4D
+ SHADER_TYPE = 0x8B4F
+ FLOAT_VEC2 = 0x8B50
+ FLOAT_VEC3 = 0x8B51
+ FLOAT_VEC4 = 0x8B52
+ INT_VEC2 = 0x8B53
+ INT_VEC3 = 0x8B54
+ INT_VEC4 = 0x8B55
+ BOOL = 0x8B56
+ BOOL_VEC2 = 0x8B57
+ BOOL_VEC3 = 0x8B58
+ BOOL_VEC4 = 0x8B59
+ FLOAT_MAT2 = 0x8B5A
+ FLOAT_MAT3 = 0x8B5B
+ FLOAT_MAT4 = 0x8B5C
+ SAMPLER_1D = 0x8B5D
+ SAMPLER_2D = 0x8B5E
+ SAMPLER_3D = 0x8B5F
+ SAMPLER_CUBE = 0x8B60
+ SAMPLER_1D_SHADOW = 0x8B61
+ SAMPLER_2D_SHADOW = 0x8B62
+ FLOAT_MAT2x3 = 0x8B65
+ FLOAT_MAT2x4 = 0x8B66
+ FLOAT_MAT3x2 = 0x8B67
+ FLOAT_MAT3x4 = 0x8B68
+ FLOAT_MAT4x2 = 0x8B69
+ FLOAT_MAT4x3 = 0x8B6A
+ DELETE_STATUS = 0x8B80
+ COMPILE_STATUS = 0x8B81
+ LINK_STATUS = 0x8B82
+ VALIDATE_STATUS = 0x8B83
+ INFO_LOG_LENGTH = 0x8B84
+ ATTACHED_SHADERS = 0x8B85
+ ACTIVE_UNIFORMS = 0x8B86
+ ACTIVE_UNIFORM_MAX_LENGTH = 0x8B87
+ SHADER_SOURCE_LENGTH = 0x8B88
+ ACTIVE_ATTRIBUTES = 0x8B89
+ ACTIVE_ATTRIBUTE_MAX_LENGTH = 0x8B8A
+ SHADING_LANGUAGE_VERSION = 0x8B8C
+ CURRENT_PROGRAM = 0x8B8D
+ TEXTURE_RED_TYPE = 0x8C10
+ TEXTURE_GREEN_TYPE = 0x8C11
+ TEXTURE_BLUE_TYPE = 0x8C12
+ TEXTURE_ALPHA_TYPE = 0x8C13
+ TEXTURE_DEPTH_TYPE = 0x8C16
+ UNSIGNED_NORMALIZED = 0x8C17
+ TEXTURE_1D_ARRAY = 0x8C18
+ PROXY_TEXTURE_1D_ARRAY = 0x8C19
+ TEXTURE_2D_ARRAY = 0x8C1A
+ PROXY_TEXTURE_2D_ARRAY = 0x8C1B
+ TEXTURE_BINDING_1D_ARRAY = 0x8C1C
+ TEXTURE_BINDING_2D_ARRAY = 0x8C1D
+ R11F_G11F_B10F = 0x8C3A
+ UNSIGNED_INT_10F_11F_11F_REV = 0x8C3B
+ RGB9_E5 = 0x8C3D
+ UNSIGNED_INT_5_9_9_9_REV = 0x8C3E
+ TEXTURE_SHARED_SIZE = 0x8C3F
+ SRGB = 0x8C40
+ SRGB8 = 0x8C41
+ SRGB_ALPHA = 0x8C42
+ SRGB8_ALPHA8 = 0x8C43
+ SLUMINANCE_ALPHA = 0x8C44
+ SLUMINANCE8_ALPHA8 = 0x8C45
+ SLUMINANCE = 0x8C46
+ SLUMINANCE8 = 0x8C47
+ COMPRESSED_SRGB = 0x8C48
+ COMPRESSED_SRGB_ALPHA = 0x8C49
+ COMPRESSED_SLUMINANCE = 0x8C4A
+ COMPRESSED_SLUMINANCE_ALPHA = 0x8C4B
+ TRANSFORM_FEEDBACK_VARYING_MAX_LENGTH = 0x8C76
+ TRANSFORM_FEEDBACK_BUFFER_MODE = 0x8C7F
+ MAX_TRANSFORM_FEEDBACK_SEPARATE_COMPONENTS = 0x8C80
+ TRANSFORM_FEEDBACK_VARYINGS = 0x8C83
+ TRANSFORM_FEEDBACK_BUFFER_START = 0x8C84
+ TRANSFORM_FEEDBACK_BUFFER_SIZE = 0x8C85
+ PRIMITIVES_GENERATED = 0x8C87
+ TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN = 0x8C88
+ RASTERIZER_DISCARD = 0x8C89
+ MAX_TRANSFORM_FEEDBACK_INTERLEAVED_COMPONENTS = 0x8C8A
+ MAX_TRANSFORM_FEEDBACK_SEPARATE_ATTRIBS = 0x8C8B
+ INTERLEAVED_ATTRIBS = 0x8C8C
+ SEPARATE_ATTRIBS = 0x8C8D
+ TRANSFORM_FEEDBACK_BUFFER = 0x8C8E
+ TRANSFORM_FEEDBACK_BUFFER_BINDING = 0x8C8F
+ POINT_SPRITE_COORD_ORIGIN = 0x8CA0
+ LOWER_LEFT = 0x8CA1
+ UPPER_LEFT = 0x8CA2
+ STENCIL_BACK_REF = 0x8CA3
+ STENCIL_BACK_VALUE_MASK = 0x8CA4
+ STENCIL_BACK_WRITEMASK = 0x8CA5
+ DRAW_FRAMEBUFFER_BINDING = 0x8CA6
+ FRAMEBUFFER_BINDING = 0x8CA6
+ RENDERBUFFER_BINDING = 0x8CA7
+ READ_FRAMEBUFFER = 0x8CA8
+ DRAW_FRAMEBUFFER = 0x8CA9
+ READ_FRAMEBUFFER_BINDING = 0x8CAA
+ RENDERBUFFER_SAMPLES = 0x8CAB
+ DEPTH_COMPONENT32F = 0x8CAC
+ DEPTH32F_STENCIL8 = 0x8CAD
+ FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE = 0x8CD0
+ FRAMEBUFFER_ATTACHMENT_OBJECT_NAME = 0x8CD1
+ FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL = 0x8CD2
+ FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE = 0x8CD3
+ FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER = 0x8CD4
+ FRAMEBUFFER_COMPLETE = 0x8CD5
+ FRAMEBUFFER_INCOMPLETE_ATTACHMENT = 0x8CD6
+ FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT = 0x8CD7
+ FRAMEBUFFER_INCOMPLETE_DRAW_BUFFER = 0x8CDB
+ FRAMEBUFFER_INCOMPLETE_READ_BUFFER = 0x8CDC
+ FRAMEBUFFER_UNSUPPORTED = 0x8CDD
+ MAX_COLOR_ATTACHMENTS = 0x8CDF
+ COLOR_ATTACHMENT0 = 0x8CE0
+ COLOR_ATTACHMENT1 = 0x8CE1
+ COLOR_ATTACHMENT2 = 0x8CE2
+ COLOR_ATTACHMENT3 = 0x8CE3
+ COLOR_ATTACHMENT4 = 0x8CE4
+ COLOR_ATTACHMENT5 = 0x8CE5
+ COLOR_ATTACHMENT6 = 0x8CE6
+ COLOR_ATTACHMENT7 = 0x8CE7
+ COLOR_ATTACHMENT8 = 0x8CE8
+ COLOR_ATTACHMENT9 = 0x8CE9
+ COLOR_ATTACHMENT10 = 0x8CEA
+ COLOR_ATTACHMENT11 = 0x8CEB
+ COLOR_ATTACHMENT12 = 0x8CEC
+ COLOR_ATTACHMENT13 = 0x8CED
+ COLOR_ATTACHMENT14 = 0x8CEE
+ COLOR_ATTACHMENT15 = 0x8CEF
+ DEPTH_ATTACHMENT = 0x8D00
+ STENCIL_ATTACHMENT = 0x8D20
+ FRAMEBUFFER = 0x8D40
+ RENDERBUFFER = 0x8D41
+ RENDERBUFFER_WIDTH = 0x8D42
+ RENDERBUFFER_HEIGHT = 0x8D43
+ RENDERBUFFER_INTERNAL_FORMAT = 0x8D44
+ STENCIL_INDEX1 = 0x8D46
+ STENCIL_INDEX4 = 0x8D47
+ STENCIL_INDEX8 = 0x8D48
+ STENCIL_INDEX16 = 0x8D49
+ RENDERBUFFER_RED_SIZE = 0x8D50
+ RENDERBUFFER_GREEN_SIZE = 0x8D51
+ RENDERBUFFER_BLUE_SIZE = 0x8D52
+ RENDERBUFFER_ALPHA_SIZE = 0x8D53
+ RENDERBUFFER_DEPTH_SIZE = 0x8D54
+ RENDERBUFFER_STENCIL_SIZE = 0x8D55
+ FRAMEBUFFER_INCOMPLETE_MULTISAMPLE = 0x8D56
+ MAX_SAMPLES = 0x8D57
+ RGBA32UI = 0x8D70
+ RGB32UI = 0x8D71
+ RGBA16UI = 0x8D76
+ RGB16UI = 0x8D77
+ RGBA8UI = 0x8D7C
+ RGB8UI = 0x8D7D
+ RGBA32I = 0x8D82
+ RGB32I = 0x8D83
+ RGBA16I = 0x8D88
+ RGB16I = 0x8D89
+ RGBA8I = 0x8D8E
+ RGB8I = 0x8D8F
+ RED_INTEGER = 0x8D94
+ GREEN_INTEGER = 0x8D95
+ BLUE_INTEGER = 0x8D96
+ ALPHA_INTEGER = 0x8D97
+ RGB_INTEGER = 0x8D98
+ RGBA_INTEGER = 0x8D99
+ BGR_INTEGER = 0x8D9A
+ BGRA_INTEGER = 0x8D9B
+ FLOAT_32_UNSIGNED_INT_24_8_REV = 0x8DAD
+ FRAMEBUFFER_SRGB = 0x8DB9
+ COMPRESSED_RED_RGTC1 = 0x8DBB
+ COMPRESSED_SIGNED_RED_RGTC1 = 0x8DBC
+ COMPRESSED_RG_RGTC2 = 0x8DBD
+ COMPRESSED_SIGNED_RG_RGTC2 = 0x8DBE
+ SAMPLER_1D_ARRAY = 0x8DC0
+ SAMPLER_2D_ARRAY = 0x8DC1
+ SAMPLER_1D_ARRAY_SHADOW = 0x8DC3
+ SAMPLER_2D_ARRAY_SHADOW = 0x8DC4
+ SAMPLER_CUBE_SHADOW = 0x8DC5
+ UNSIGNED_INT_VEC2 = 0x8DC6
+ UNSIGNED_INT_VEC3 = 0x8DC7
+ UNSIGNED_INT_VEC4 = 0x8DC8
+ INT_SAMPLER_1D = 0x8DC9
+ INT_SAMPLER_2D = 0x8DCA
+ INT_SAMPLER_3D = 0x8DCB
+ INT_SAMPLER_CUBE = 0x8DCC
+ INT_SAMPLER_1D_ARRAY = 0x8DCE
+ INT_SAMPLER_2D_ARRAY = 0x8DCF
+ UNSIGNED_INT_SAMPLER_1D = 0x8DD1
+ UNSIGNED_INT_SAMPLER_2D = 0x8DD2
+ UNSIGNED_INT_SAMPLER_3D = 0x8DD3
+ UNSIGNED_INT_SAMPLER_CUBE = 0x8DD4
+ UNSIGNED_INT_SAMPLER_1D_ARRAY = 0x8DD6
+ UNSIGNED_INT_SAMPLER_2D_ARRAY = 0x8DD7
+ QUERY_WAIT = 0x8E13
+ QUERY_NO_WAIT = 0x8E14
+ QUERY_BY_REGION_WAIT = 0x8E15
+ QUERY_BY_REGION_NO_WAIT = 0x8E16
+ BUFFER_ACCESS_FLAGS = 0x911F
+ BUFFER_MAP_LENGTH = 0x9120
+ BUFFER_MAP_OFFSET = 0x9121
+)
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glViewport.xml
+func (gl *GL) Viewport(x, y, width, height int) {
+ C.gl3_0_glViewport(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// DepthRange specifies the mapping of depth values from normalized device
+// coordinates to window coordinates.
+//
+// Parameter nearVal specifies the mapping of the near clipping plane to window
+// coordinates (defaults to 0), while farVal specifies the mapping of the far
+// clipping plane to window coordinates (defaults to 1).
+//
+// After clipping and division by w, depth coordinates range from -1 to 1,
+// corresponding to the near and far clipping planes. DepthRange specifies a
+// linear mapping of the normalized depth coordinates in this range to window
+// depth coordinates. Regardless of the actual depth buffer implementation,
+// window coordinate depth values are treated as though they range from 0 through 1
+// (like color components). Thus, the values accepted by DepthRange are both
+// clamped to this range before they are accepted.
+//
+// The default setting of (0, 1) maps the near plane to 0 and the far plane to 1.
+// With this mapping, the depth buffer range is fully utilized.
+//
+// It is not necessary that nearVal be less than farVal. Reverse mappings such as
+// nearVal 1, and farVal 0 are acceptable.
+//
+// GL.INVALID_OPERATION is generated if DepthRange is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) DepthRange(nearVal, farVal float64) {
+ C.gl3_0_glDepthRange(gl.funcs, C.GLdouble(nearVal), C.GLdouble(farVal))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsEnabled.xml
+func (gl *GL) IsEnabled(cap glbase.Enum) bool {
+ glresult := C.gl3_0_glIsEnabled(gl.funcs, C.GLenum(cap))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTexLevelParameteriv.xml
+func (gl *GL) GetTexLevelParameteriv(target glbase.Enum, level int, pname glbase.Enum, params []int32) {
+ C.gl3_0_glGetTexLevelParameteriv(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTexLevelParameterfv.xml
+func (gl *GL) GetTexLevelParameterfv(target glbase.Enum, level int, pname glbase.Enum, params []float32) {
+ C.gl3_0_glGetTexLevelParameterfv(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTexParameteriv.xml
+func (gl *GL) GetTexParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl3_0_glGetTexParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTexParameterfv.xml
+func (gl *GL) GetTexParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl3_0_glGetTexParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTexImage.xml
+func (gl *GL) GetTexImage(target glbase.Enum, level int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_0_glGetTexImage(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetIntegerv.xml
+func (gl *GL) GetIntegerv(pname glbase.Enum, params []int32) {
+ C.gl3_0_glGetIntegerv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetFloatv.xml
+func (gl *GL) GetFloatv(pname glbase.Enum, params []float32) {
+ C.gl3_0_glGetFloatv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetError.xml
+func (gl *GL) GetError() glbase.Enum {
+ glresult := C.gl3_0_glGetError(gl.funcs)
+ return glbase.Enum(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetDoublev.xml
+func (gl *GL) GetDoublev(pname glbase.Enum, params []float64) {
+ C.gl3_0_glGetDoublev(gl.funcs, C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetBooleanv.xml
+func (gl *GL) GetBooleanv(pname glbase.Enum, params []bool) {
+ C.gl3_0_glGetBooleanv(gl.funcs, C.GLenum(pname), (*C.GLboolean)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glReadPixels.xml
+func (gl *GL) ReadPixels(x, y, width, height int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_0_glReadPixels(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glReadBuffer.xml
+func (gl *GL) ReadBuffer(mode glbase.Enum) {
+ C.gl3_0_glReadBuffer(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPixelStorei.xml
+func (gl *GL) PixelStorei(pname glbase.Enum, param int32) {
+ C.gl3_0_glPixelStorei(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPixelStoref.xml
+func (gl *GL) PixelStoref(pname glbase.Enum, param float32) {
+ C.gl3_0_glPixelStoref(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDepthFunc.xml
+func (gl *GL) DepthFunc(glfunc glbase.Enum) {
+ C.gl3_0_glDepthFunc(gl.funcs, C.GLenum(glfunc))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glStencilOp.xml
+func (gl *GL) StencilOp(fail, zfail, zpass glbase.Enum) {
+ C.gl3_0_glStencilOp(gl.funcs, C.GLenum(fail), C.GLenum(zfail), C.GLenum(zpass))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glStencilFunc.xml
+func (gl *GL) StencilFunc(glfunc glbase.Enum, ref int32, mask uint32) {
+ C.gl3_0_glStencilFunc(gl.funcs, C.GLenum(glfunc), C.GLint(ref), C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glLogicOp.xml
+func (gl *GL) LogicOp(opcode glbase.Enum) {
+ C.gl3_0_glLogicOp(gl.funcs, C.GLenum(opcode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBlendFunc.xml
+func (gl *GL) BlendFunc(sfactor, dfactor glbase.Enum) {
+ C.gl3_0_glBlendFunc(gl.funcs, C.GLenum(sfactor), C.GLenum(dfactor))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFlush.xml
+func (gl *GL) Flush() {
+ C.gl3_0_glFlush(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFinish.xml
+func (gl *GL) Finish() {
+ C.gl3_0_glFinish(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEnable.xml
+func (gl *GL) Enable(cap glbase.Enum) {
+ C.gl3_0_glEnable(gl.funcs, C.GLenum(cap))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDisable.xml
+func (gl *GL) Disable(cap glbase.Enum) {
+ C.gl3_0_glDisable(gl.funcs, C.GLenum(cap))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDepthMask.xml
+func (gl *GL) DepthMask(flag bool) {
+ C.gl3_0_glDepthMask(gl.funcs, *(*C.GLboolean)(unsafe.Pointer(&flag)))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColorMask.xml
+func (gl *GL) ColorMask(red, green, blue, alpha bool) {
+ C.gl3_0_glColorMask(gl.funcs, *(*C.GLboolean)(unsafe.Pointer(&red)), *(*C.GLboolean)(unsafe.Pointer(&green)), *(*C.GLboolean)(unsafe.Pointer(&blue)), *(*C.GLboolean)(unsafe.Pointer(&alpha)))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glStencilMask.xml
+func (gl *GL) StencilMask(mask uint32) {
+ C.gl3_0_glStencilMask(gl.funcs, C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClearDepth.xml
+func (gl *GL) ClearDepth(depth float64) {
+ C.gl3_0_glClearDepth(gl.funcs, C.GLdouble(depth))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClearStencil.xml
+func (gl *GL) ClearStencil(s int32) {
+ C.gl3_0_glClearStencil(gl.funcs, C.GLint(s))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClearColor.xml
+func (gl *GL) ClearColor(red, green, blue, alpha float32) {
+ C.gl3_0_glClearColor(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClear.xml
+func (gl *GL) Clear(mask glbase.Bitfield) {
+ C.gl3_0_glClear(gl.funcs, C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDrawBuffer.xml
+func (gl *GL) DrawBuffer(mode glbase.Enum) {
+ C.gl3_0_glDrawBuffer(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexImage2D.xml
+func (gl *GL) TexImage2D(target glbase.Enum, level int, internalFormat int32, width, height, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_0_glTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexImage1D.xml
+func (gl *GL) TexImage1D(target glbase.Enum, level int, internalFormat int32, width, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_0_glTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexParameteriv.xml
+func (gl *GL) TexParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl3_0_glTexParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexParameteri.xml
+func (gl *GL) TexParameteri(target, pname glbase.Enum, param int32) {
+ C.gl3_0_glTexParameteri(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexParameterfv.xml
+func (gl *GL) TexParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl3_0_glTexParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexParameterf.xml
+func (gl *GL) TexParameterf(target, pname glbase.Enum, param float32) {
+ C.gl3_0_glTexParameterf(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glScissor.xml
+func (gl *GL) Scissor(x, y, width, height int) {
+ C.gl3_0_glScissor(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPolygonMode.xml
+func (gl *GL) PolygonMode(face, mode glbase.Enum) {
+ C.gl3_0_glPolygonMode(gl.funcs, C.GLenum(face), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPointSize.xml
+func (gl *GL) PointSize(size float32) {
+ C.gl3_0_glPointSize(gl.funcs, C.GLfloat(size))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glLineWidth.xml
+func (gl *GL) LineWidth(width float32) {
+ C.gl3_0_glLineWidth(gl.funcs, C.GLfloat(width))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glHint.xml
+func (gl *GL) Hint(target, mode glbase.Enum) {
+ C.gl3_0_glHint(gl.funcs, C.GLenum(target), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFrontFace.xml
+func (gl *GL) FrontFace(mode glbase.Enum) {
+ C.gl3_0_glFrontFace(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCullFace.xml
+func (gl *GL) CullFace(mode glbase.Enum) {
+ C.gl3_0_glCullFace(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIndexubv.xml
+func (gl *GL) Indexubv(c []uint8) {
+ C.gl3_0_glIndexubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIndexub.xml
+func (gl *GL) Indexub(c uint8) {
+ C.gl3_0_glIndexub(gl.funcs, C.GLubyte(c))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsTexture.xml
+func (gl *GL) IsTexture(texture glbase.Texture) bool {
+ glresult := C.gl3_0_glIsTexture(gl.funcs, C.GLuint(texture))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// GenTextures returns n texture names in textures. There is no guarantee
+// that the names form a contiguous set of integers; however, it is
+// guaranteed that none of the returned names was in use immediately before
+// the call to GenTextures.
+//
+// The generated textures have no dimensionality; they assume the
+// dimensionality of the texture target to which they are first bound (see
+// BindTexture).
+//
+// Texture names returned by a call to GenTextures are not returned by
+// subsequent calls, unless they are first deleted with DeleteTextures.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// GenTextures is available in GL version 2.0 or greater.
+func (gl *GL) GenTextures(n int) []glbase.Texture {
+ if n == 0 {
+ return nil
+ }
+ textures := make([]glbase.Texture, n)
+ C.gl3_0_glGenTextures(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])))
+ return textures
+}
+
+// DeleteTextures deletes the textures objects whose names are stored
+// in the textures slice. After a texture is deleted, it has no contents or
+// dimensionality, and its name is free for reuse (for example by
+// GenTextures). If a texture that is currently bound is deleted, the binding
+// reverts to 0 (the default texture).
+//
+// DeleteTextures silently ignores 0's and names that do not correspond to
+// existing textures.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// DeleteTextures is available in GL version 2.0 or greater.
+func (gl *GL) DeleteTextures(textures []glbase.Texture) {
+ n := len(textures)
+ if n == 0 {
+ return
+ }
+ C.gl3_0_glDeleteTextures(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBindTexture.xml
+func (gl *GL) BindTexture(target glbase.Enum, texture glbase.Texture) {
+ C.gl3_0_glBindTexture(gl.funcs, C.GLenum(target), C.GLuint(texture))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexSubImage2D.xml
+func (gl *GL) TexSubImage2D(target glbase.Enum, level, xoffset, yoffset, width, height int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_0_glTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexSubImage1D.xml
+func (gl *GL) TexSubImage1D(target glbase.Enum, level, xoffset, width int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_0_glTexSubImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLsizei(width), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCopyTexSubImage2D.xml
+func (gl *GL) CopyTexSubImage2D(target glbase.Enum, level, xoffset, yoffset, x, y, width, height int) {
+ C.gl3_0_glCopyTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCopyTexSubImage1D.xml
+func (gl *GL) CopyTexSubImage1D(target glbase.Enum, level, xoffset, x, y, width int) {
+ C.gl3_0_glCopyTexSubImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(x), C.GLint(y), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCopyTexImage2D.xml
+func (gl *GL) CopyTexImage2D(target glbase.Enum, level int, internalFormat glbase.Enum, x, y, width, height, border int) {
+ C.gl3_0_glCopyTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height), C.GLint(border))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCopyTexImage1D.xml
+func (gl *GL) CopyTexImage1D(target glbase.Enum, level int, internalFormat glbase.Enum, x, y, width, border int) {
+ C.gl3_0_glCopyTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLint(border))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPolygonOffset.xml
+func (gl *GL) PolygonOffset(factor, units float32) {
+ C.gl3_0_glPolygonOffset(gl.funcs, C.GLfloat(factor), C.GLfloat(units))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDrawElements.xml
+func (gl *GL) DrawElements(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_0_glDrawElements(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDrawArrays.xml
+func (gl *GL) DrawArrays(mode glbase.Enum, first, count int) {
+ C.gl3_0_glDrawArrays(gl.funcs, C.GLenum(mode), C.GLint(first), C.GLsizei(count))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCopyTexSubImage3D.xml
+func (gl *GL) CopyTexSubImage3D(target glbase.Enum, level, xoffset, yoffset int, zoffset int32, x, y, width, height int) {
+ C.gl3_0_glCopyTexSubImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(zoffset), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexSubImage3D.xml
+func (gl *GL) TexSubImage3D(target glbase.Enum, level, xoffset, yoffset int, zoffset int32, width, height int, depth int32, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_0_glTexSubImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(zoffset), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexImage3D.xml
+func (gl *GL) TexImage3D(target glbase.Enum, level int, internalFormat int32, width, height int, depth int32, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_0_glTexImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDrawRangeElements.xml
+func (gl *GL) DrawRangeElements(mode glbase.Enum, start, end uint32, count int, gltype glbase.Enum, indices interface{}) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_0_glDrawRangeElements(gl.funcs, C.GLenum(mode), C.GLuint(start), C.GLuint(end), C.GLsizei(count), C.GLenum(gltype), indices_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBlendEquation.xml
+func (gl *GL) BlendEquation(mode glbase.Enum) {
+ C.gl3_0_glBlendEquation(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBlendColor.xml
+func (gl *GL) BlendColor(red, green, blue, alpha float32) {
+ C.gl3_0_glBlendColor(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetCompressedTexImage.xml
+func (gl *GL) GetCompressedTexImage(target glbase.Enum, level int, img interface{}) {
+ var img_ptr unsafe.Pointer
+ var img_v = reflect.ValueOf(img)
+ if img != nil && img_v.Kind() != reflect.Slice {
+ panic("parameter img must be a slice")
+ }
+ if img != nil {
+ img_ptr = unsafe.Pointer(img_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_0_glGetCompressedTexImage(gl.funcs, C.GLenum(target), C.GLint(level), img_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCompressedTexSubImage1D.xml
+func (gl *GL) CompressedTexSubImage1D(target glbase.Enum, level, xoffset, width int, format glbase.Enum, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_0_glCompressedTexSubImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLsizei(width), C.GLenum(format), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCompressedTexSubImage2D.xml
+func (gl *GL) CompressedTexSubImage2D(target glbase.Enum, level, xoffset, yoffset, width, height int, format glbase.Enum, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_0_glCompressedTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCompressedTexSubImage3D.xml
+func (gl *GL) CompressedTexSubImage3D(target glbase.Enum, level, xoffset, yoffset int, zoffset int32, width, height int, depth int32, format glbase.Enum, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_0_glCompressedTexSubImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(zoffset), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLenum(format), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCompressedTexImage1D.xml
+func (gl *GL) CompressedTexImage1D(target glbase.Enum, level int, internalFormat glbase.Enum, width, border, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_0_glCompressedTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLsizei(width), C.GLint(border), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCompressedTexImage2D.xml
+func (gl *GL) CompressedTexImage2D(target glbase.Enum, level int, internalFormat glbase.Enum, width, height, border, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_0_glCompressedTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLint(border), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCompressedTexImage3D.xml
+func (gl *GL) CompressedTexImage3D(target glbase.Enum, level int, internalFormat glbase.Enum, width, height int, depth int32, border, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_0_glCompressedTexImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLint(border), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSampleCoverage.xml
+func (gl *GL) SampleCoverage(value float32, invert bool) {
+ C.gl3_0_glSampleCoverage(gl.funcs, C.GLfloat(value), *(*C.GLboolean)(unsafe.Pointer(&invert)))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glActiveTexture.xml
+func (gl *GL) ActiveTexture(texture glbase.Enum) {
+ C.gl3_0_glActiveTexture(gl.funcs, C.GLenum(texture))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPointParameteriv.xml
+func (gl *GL) PointParameteriv(pname glbase.Enum, params []int32) {
+ C.gl3_0_glPointParameteriv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPointParameteri.xml
+func (gl *GL) PointParameteri(pname glbase.Enum, param int32) {
+ C.gl3_0_glPointParameteri(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPointParameterfv.xml
+func (gl *GL) PointParameterfv(pname glbase.Enum, params []float32) {
+ C.gl3_0_glPointParameterfv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPointParameterf.xml
+func (gl *GL) PointParameterf(pname glbase.Enum, param float32) {
+ C.gl3_0_glPointParameterf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiDrawArrays.xml
+func (gl *GL) MultiDrawArrays(mode glbase.Enum, first, count []int, drawcount int32) {
+ C.gl3_0_glMultiDrawArrays(gl.funcs, C.GLenum(mode), (*C.GLint)(unsafe.Pointer(&first[0])), (*C.GLsizei)(unsafe.Pointer(&count[0])), C.GLsizei(drawcount))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBlendFuncSeparate.xml
+func (gl *GL) BlendFuncSeparate(sfactorRGB, dfactorRGB, sfactorAlpha, dfactorAlpha glbase.Enum) {
+ C.gl3_0_glBlendFuncSeparate(gl.funcs, C.GLenum(sfactorRGB), C.GLenum(dfactorRGB), C.GLenum(sfactorAlpha), C.GLenum(dfactorAlpha))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetBufferParameteriv.xml
+func (gl *GL) GetBufferParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl3_0_glGetBufferParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glUnmapBuffer.xml
+func (gl *GL) UnmapBuffer(target glbase.Enum) bool {
+ glresult := C.gl3_0_glUnmapBuffer(gl.funcs, C.GLenum(target))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetBufferSubData.xml
+func (gl *GL) GetBufferSubData(target glbase.Enum, offset, size int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_0_glGetBufferSubData(gl.funcs, C.GLenum(target), C.GLintptr(offset), C.GLsizeiptr(size), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBufferSubData.xml
+func (gl *GL) BufferSubData(target glbase.Enum, offset, size int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_0_glBufferSubData(gl.funcs, C.GLenum(target), C.GLintptr(offset), C.GLsizeiptr(size), data_ptr)
+}
+
+// BufferData creates a new data store for the buffer object currently
+// bound to target. Any pre-existing data store is deleted. The new data
+// store is created with the specified size in bytes and usage. If data is
+// not nil, it must be a slice that is used to initialize the data store.
+// In that case the size parameter is ignored and the store size will match
+// the slice data size.
+//
+// In its initial state, the new data store is not mapped, it has a NULL
+// mapped pointer, and its mapped access is GL.READ_WRITE.
+//
+// The target constant must be one of GL.ARRAY_BUFFER, GL.COPY_READ_BUFFER,
+// GL.COPY_WRITE_BUFFER, GL.ELEMENT_ARRAY_BUFFER, GL.PIXEL_PACK_BUFFER,
+// GL.PIXEL_UNPACK_BUFFER, GL.TEXTURE_BUFFER, GL.TRANSFORM_FEEDBACK_BUFFER,
+// or GL.UNIFORM_BUFFER.
+//
+// The usage parameter is a hint to the GL implementation as to how a buffer
+// object's data store will be accessed. This enables the GL implementation
+// to make more intelligent decisions that may significantly impact buffer
+// object performance. It does not, however, constrain the actual usage of
+// the data store. usage can be broken down into two parts: first, the
+// frequency of access (modification and usage), and second, the nature of
+// that access.
+//
+// A usage frequency of STREAM and nature of DRAW is specified via the
+// constant GL.STREAM_DRAW, for example.
+//
+// The usage frequency of access may be one of:
+//
+// STREAM
+// The data store contents will be modified once and used at most a few times.
+//
+// STATIC
+// The data store contents will be modified once and used many times.
+//
+// DYNAMIC
+// The data store contents will be modified repeatedly and used many times.
+//
+// The usage nature of access may be one of:
+//
+// DRAW
+// The data store contents are modified by the application, and used as
+// the source for GL drawing and image specification commands.
+//
+// READ
+// The data store contents are modified by reading data from the GL,
+// and used to return that data when queried by the application.
+//
+// COPY
+// The data store contents are modified by reading data from the GL,
+// and used as the source for GL drawing and image specification
+// commands.
+//
+// Clients must align data elements consistent with the requirements of the
+// client platform, with an additional base-level requirement that an offset
+// within a buffer to a datum comprising N bytes be a multiple of N.
+//
+// Error GL.INVALID_ENUM is generated if target is not one of the accepted
+// buffer targets. GL.INVALID_ENUM is generated if usage is not
+// GL.STREAM_DRAW, GL.STREAM_READ, GL.STREAM_COPY, GL.STATIC_DRAW,
+// GL.STATIC_READ, GL.STATIC_COPY, GL.DYNAMIC_DRAW, GL.DYNAMIC_READ, or
+// GL.DYNAMIC_COPY. GL.INVALID_VALUE is generated if size is negative.
+// GL.INVALID_OPERATION is generated if the reserved buffer object name 0 is
+// bound to target. GL.OUT_OF_MEMORY is generated if the GL is unable to
+// create a data store with the specified size.
+func (gl *GL) BufferData(target glbase.Enum, size int, data interface{}, usage glbase.Enum) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ if data != nil {
+ size = int(data_v.Type().Size()) * data_v.Len()
+ }
+ C.gl3_0_glBufferData(gl.funcs, C.GLenum(target), C.GLsizeiptr(size), data_ptr, C.GLenum(usage))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsBuffer.xml
+func (gl *GL) IsBuffer(buffer glbase.Buffer) bool {
+ glresult := C.gl3_0_glIsBuffer(gl.funcs, C.GLuint(buffer))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// GenBuffers returns n buffer object names. There is no guarantee that
+// the names form a contiguous set of integers; however, it is guaranteed
+// that none of the returned names was in use immediately before the call to
+// GenBuffers.
+//
+// Buffer object names returned by a call to GenBuffers are not returned by
+// subsequent calls, unless they are first deleted with DeleteBuffers.
+//
+// No buffer objects are associated with the returned buffer object names
+// until they are first bound by calling BindBuffer.
+//
+// Error GL.INVALID_VALUE is generated if n is negative. GL.INVALID_OPERATION
+// is generated if GenBuffers is executed between the execution of Begin
+// and the corresponding execution of End.
+//
+// GenBuffers is available in GL version 1.5 or greater.
+func (gl *GL) GenBuffers(n int) []glbase.Buffer {
+ if n == 0 {
+ return nil
+ }
+ buffers := make([]glbase.Buffer, n)
+ C.gl3_0_glGenBuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&buffers[0])))
+ return buffers
+}
+
+// DeleteBuffers deletes the buffer objects whose names are stored in the
+// buffers slice.
+//
+// After a buffer object is deleted, it has no contents, and its name is free
+// for reuse (for example by GenBuffers). If a buffer object that is
+// currently bound is deleted, the binding reverts to 0 (the absence of any
+// buffer object, which reverts to client memory usage).
+//
+// DeleteBuffers silently ignores 0's and names that do not correspond to
+// existing buffer objects.
+//
+// Error GL.INVALID_VALUE is generated if n is negative. GL.INVALID_OPERATION
+// is generated if DeleteBuffers is executed between the execution of Begin
+// and the corresponding execution of End.
+//
+// DeleteBuffers is available in GL version 1.5 or greater.
+func (gl *GL) DeleteBuffers(buffers []glbase.Buffer) {
+ n := len(buffers)
+ if n == 0 {
+ return
+ }
+ C.gl3_0_glDeleteBuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&buffers[0])))
+}
+
+// BindBuffer creates or puts in use a named buffer object.
+// Calling BindBuffer with target set to GL.ARRAY_BUFFER,
+// GL.ELEMENT_ARRAY_BUFFER, GL.PIXEL_PACK_BUFFER or GL.PIXEL_UNPACK_BUFFER
+// and buffer set to the name of the new buffer object binds the buffer
+// object name to the target. When a buffer object is bound to a target, the
+// previous binding for that target is automatically broken.
+//
+// Buffer object names are unsigned integers. The value zero is reserved, but
+// there is no default buffer object for each buffer object target. Instead,
+// buffer set to zero effectively unbinds any buffer object previously bound,
+// and restores client memory usage for that buffer object target. Buffer
+// object names and the corresponding buffer object contents are local to the
+// shared display-list space (see XCreateContext) of the current GL rendering
+// context; two rendering contexts share buffer object names only if they
+// also share display lists.
+//
+// GenBuffers may be called to generate a set of new buffer object names.
+//
+// The state of a buffer object immediately after it is first bound is an
+// unmapped zero-sized memory buffer with GL.READ_WRITE access and
+// GL.STATIC_DRAW usage.
+//
+// While a non-zero buffer object name is bound, GL operations on the target
+// to which it is bound affect the bound buffer object, and queries of the
+// target to which it is bound return state from the bound buffer object.
+// While buffer object name zero is bound, as in the initial state, attempts
+// to modify or query state on the target to which it is bound generates an
+// GL.INVALID_OPERATION error.
+//
+// When vertex array pointer state is changed, for example by a call to
+// NormalPointer, the current buffer object binding (GL.ARRAY_BUFFER_BINDING)
+// is copied into the corresponding client state for the vertex array type
+// being changed, for example GL.NORMAL_ARRAY_BUFFER_BINDING. While a
+// non-zero buffer object is bound to the GL.ARRAY_BUFFER target, the vertex
+// array pointer parameter that is traditionally interpreted as a pointer to
+// client-side memory is instead interpreted as an offset within the buffer
+// object measured in basic machine units.
+//
+// While a non-zero buffer object is bound to the GL.ELEMENT_ARRAY_BUFFER
+// target, the indices parameter of DrawElements, DrawRangeElements, or
+// MultiDrawElements that is traditionally interpreted as a pointer to
+// client-side memory is instead interpreted as an offset within the buffer
+// object measured in basic machine units.
+//
+// While a non-zero buffer object is bound to the GL.PIXEL_PACK_BUFFER
+// target, the following commands are affected: GetCompressedTexImage,
+// GetConvolutionFilter, GetHistogram, GetMinmax, GetPixelMap,
+// GetPolygonStipple, GetSeparableFilter, GetTexImage, and ReadPixels. The
+// pointer parameter that is traditionally interpreted as a pointer to
+// client-side memory where the pixels are to be packed is instead
+// interpreted as an offset within the buffer object measured in basic
+// machine units.
+//
+// While a non-zero buffer object is bound to the GL.PIXEL_UNPACK_BUFFER
+// target, the following commands are affected: Bitmap, ColorSubTable,
+// ColorTable, CompressedTexImage1D, CompressedTexImage2D,
+// CompressedTexImage3D, CompressedTexSubImage1D, CompressedTexSubImage2D,
+// CompressedTexSubImage3D, ConvolutionFilter1D, ConvolutionFilter2D,
+// DrawPixels, PixelMap, PolygonStipple, SeparableFilter2D, TexImage1D,
+// TexImage2D, TexImage3D, TexSubImage1D, TexSubImage2D, and TexSubImage3D.
+// The pointer parameter that is traditionally interpreted as a pointer to
+// client-side memory from which the pixels are to be unpacked is instead
+// interpreted as an offset within the buffer object measured in basic
+// machine units.
+//
+// A buffer object binding created with BindBuffer remains active until a
+// different buffer object name is bound to the same target, or until the
+// bound buffer object is deleted with DeleteBuffers.
+//
+// Once created, a named buffer object may be re-bound to any target as often
+// as needed. However, the GL implementation may make choices about how to
+// optimize the storage of a buffer object based on its initial binding
+// target.
+//
+// Error GL.INVALID_ENUM is generated if target is not one of the allowable
+// values. GL.INVALID_OPERATION is generated if BindBuffer is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// BindBuffer is available in GL version 1.5 or greater.
+func (gl *GL) BindBuffer(target glbase.Enum, buffer glbase.Buffer) {
+ C.gl3_0_glBindBuffer(gl.funcs, C.GLenum(target), C.GLuint(buffer))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetQueryObjectuiv.xml
+func (gl *GL) GetQueryObjectuiv(id uint32, pname glbase.Enum, params []uint32) {
+ C.gl3_0_glGetQueryObjectuiv(gl.funcs, C.GLuint(id), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetQueryObjectiv.xml
+func (gl *GL) GetQueryObjectiv(id uint32, pname glbase.Enum, params []int32) {
+ C.gl3_0_glGetQueryObjectiv(gl.funcs, C.GLuint(id), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetQueryiv.xml
+func (gl *GL) GetQueryiv(target, pname glbase.Enum, params []int32) {
+ C.gl3_0_glGetQueryiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEndQuery.xml
+func (gl *GL) EndQuery(target glbase.Enum) {
+ C.gl3_0_glEndQuery(gl.funcs, C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBeginQuery.xml
+func (gl *GL) BeginQuery(target glbase.Enum, id uint32) {
+ C.gl3_0_glBeginQuery(gl.funcs, C.GLenum(target), C.GLuint(id))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsQuery.xml
+func (gl *GL) IsQuery(id uint32) bool {
+ glresult := C.gl3_0_glIsQuery(gl.funcs, C.GLuint(id))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDeleteQueries.xml
+func (gl *GL) DeleteQueries(n int, ids []uint32) {
+ C.gl3_0_glDeleteQueries(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&ids[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGenQueries.xml
+func (gl *GL) GenQueries(n int, ids []uint32) {
+ C.gl3_0_glGenQueries(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&ids[0])))
+}
+
+// VertexAttribPointer specifies the location and data format of the array
+// of generic vertex attributes at index to use when rendering. size
+// specifies the number of components per attribute and must be 1, 2, 3, or
+// 4. type specifies the data type of each component, and stride specifies
+// the byte stride from one attribute to the next, allowing vertices and
+// attributes to be packed into a single array or stored in separate arrays.
+// normalized indicates whether the values stored in an integer format are
+// to be mapped to the range [-1,1] (for signed values) or [0,1]
+// (for unsigned values) when they are accessed and converted to floating
+// point; otherwise, values will be converted to floats directly without
+// normalization. offset is a byte offset into the buffer object's data
+// store, which must be bound to the GL.ARRAY_BUFFER target with BindBuffer.
+//
+// The buffer object binding (GL.ARRAY_BUFFER_BINDING) is saved as
+// generic vertex attribute array client-side state
+// (GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING) for the provided index.
+//
+// To enable and disable a generic vertex attribute array, call
+// EnableVertexAttribArray and DisableVertexAttribArray with index. If
+// enabled, the generic vertex attribute array is used when DrawArrays or
+// DrawElements is called. Each generic vertex attribute array is initially
+// disabled.
+//
+// VertexAttribPointer is typically implemented on the client side.
+//
+// Error GL.INVALID_ENUM is generated if type is not an accepted value.
+// GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_VALUE is generated if size is not 1, 2,
+// 3, or 4. GL.INVALID_VALUE is generated if stride is negative.
+func (gl *GL) VertexAttribPointer(index glbase.Attrib, size int, gltype glbase.Enum, normalized bool, stride int, offset uintptr) {
+ offset_ptr := unsafe.Pointer(offset)
+ C.gl3_0_glVertexAttribPointer(gl.funcs, C.GLuint(index), C.GLint(size), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), C.GLsizei(stride), offset_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glValidateProgram.xml
+func (gl *GL) ValidateProgram(program glbase.Program) {
+ C.gl3_0_glValidateProgram(gl.funcs, C.GLuint(program))
+}
+
+// UniformMatrix4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix4fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(4*4) != 0 {
+ panic("invalid value length for UniformMatrix4fv")
+ }
+ count := len(value) / (4 * 4)
+ C.gl3_0_glUniformMatrix4fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix3fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(3*3) != 0 {
+ panic("invalid value length for UniformMatrix3fv")
+ }
+ count := len(value) / (3 * 3)
+ C.gl3_0_glUniformMatrix3fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix2fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(2*2) != 0 {
+ panic("invalid value length for UniformMatrix2fv")
+ }
+ count := len(value) / (2 * 2)
+ C.gl3_0_glUniformMatrix2fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform4iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%4 != 0 {
+ panic("invalid value length for Uniform4iv")
+ }
+ count := len(value) / 4
+ C.gl3_0_glUniform4iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform3iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform3iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%3 != 0 {
+ panic("invalid value length for Uniform3iv")
+ }
+ count := len(value) / 3
+ C.gl3_0_glUniform3iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform2iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform2iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%2 != 0 {
+ panic("invalid value length for Uniform2iv")
+ }
+ count := len(value) / 2
+ C.gl3_0_glUniform2iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform1iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform1iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ count := len(value)
+ C.gl3_0_glUniform1iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%4 != 0 {
+ panic("invalid value length for Uniform4fv")
+ }
+ count := len(value) / 4
+ C.gl3_0_glUniform4fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%3 != 0 {
+ panic("invalid value length for Uniform3fv")
+ }
+ count := len(value) / 3
+ C.gl3_0_glUniform3fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%2 != 0 {
+ panic("invalid value length for Uniform2fv")
+ }
+ count := len(value) / 2
+ C.gl3_0_glUniform2fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform1fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform1fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ count := len(value)
+ C.gl3_0_glUniform1fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform4i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4i(location glbase.Uniform, v0, v1, v2, v3 int32) {
+ C.gl3_0_glUniform4i(gl.funcs, C.GLint(location), C.GLint(v0), C.GLint(v1), C.GLint(v2), C.GLint(v3))
+}
+
+// Uniform3i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform3i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3i(location glbase.Uniform, v0, v1, v2 int32) {
+ C.gl3_0_glUniform3i(gl.funcs, C.GLint(location), C.GLint(v0), C.GLint(v1), C.GLint(v2))
+}
+
+// Uniform2i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform2i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2i(location glbase.Uniform, v0, v1 int32) {
+ C.gl3_0_glUniform2i(gl.funcs, C.GLint(location), C.GLint(v0), C.GLint(v1))
+}
+
+// Uniform1i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform1i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1i(location glbase.Uniform, v0 int32) {
+ C.gl3_0_glUniform1i(gl.funcs, C.GLint(location), C.GLint(v0))
+}
+
+// Uniform4f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform4f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4f(location glbase.Uniform, v0, v1, v2, v3 float32) {
+ C.gl3_0_glUniform4f(gl.funcs, C.GLint(location), C.GLfloat(v0), C.GLfloat(v1), C.GLfloat(v2), C.GLfloat(v3))
+}
+
+// Uniform3f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform3f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3f(location glbase.Uniform, v0, v1, v2 float32) {
+ C.gl3_0_glUniform3f(gl.funcs, C.GLint(location), C.GLfloat(v0), C.GLfloat(v1), C.GLfloat(v2))
+}
+
+// Uniform2f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform2f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2f(location glbase.Uniform, v0, v1 float32) {
+ C.gl3_0_glUniform2f(gl.funcs, C.GLint(location), C.GLfloat(v0), C.GLfloat(v1))
+}
+
+// Uniform1f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform1f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1f(location glbase.Uniform, v0 float32) {
+ C.gl3_0_glUniform1f(gl.funcs, C.GLint(location), C.GLfloat(v0))
+}
+
+// UseProgram installs the program object specified by program as part of
+// current rendering state. One or more executables are created in a program
+// object by successfully attaching shader objects to it with AttachShader,
+// successfully compiling the shader objects with CompileShader, and
+// successfully linking the program object with LinkProgram.
+//
+// A program object will contain an executable that will run on the vertex
+// processor if it contains one or more shader objects of type
+// GL.VERTEX_SHADER that have been successfully compiled and linked.
+// Similarly, a program object will contain an executable that will run on
+// the fragment processor if it contains one or more shader objects of type
+// GL.FRAGMENT_SHADER that have been successfully compiled and linked.
+//
+// Successfully installing an executable on a programmable processor will
+// cause the corresponding fixed functionality of OpenGL to be disabled.
+// Specifically, if an executable is installed on the vertex processor, the
+// OpenGL fixed functionality will be disabled as follows.
+//
+// - The modelview matrix is not applied to vertex coordinates.
+//
+// - The projection matrix is not applied to vertex coordinates.
+//
+// - The texture matrices are not applied to texture coordinates.
+//
+// - Normals are not transformed to eye coordinates.
+//
+// - Normals are not rescaled or normalized.
+//
+// - Normalization of GL.AUTO_NORMAL evaluated normals is not performed.
+//
+// - Texture coordinates are not generated automatically.
+//
+// - Per-vertex lighting is not performed.
+//
+// - Color material computations are not performed.
+//
+// - Color index lighting is not performed.
+//
+// - This list also applies when setting the current raster position.
+//
+// The executable that is installed on the vertex processor is expected to
+// implement any or all of the desired functionality from the preceding list.
+// Similarly, if an executable is installed on the fragment processor, the
+// OpenGL fixed functionality will be disabled as follows.
+//
+// - Texture environment and texture functions are not applied.
+//
+// - Texture application is not applied.
+//
+// - Color sum is not applied.
+//
+// - Fog is not applied.
+//
+// Again, the fragment shader that is installed is expected to implement any
+// or all of the desired functionality from the preceding list.
+//
+// While a program object is in use, applications are free to modify attached
+// shader objects, compile attached shader objects, attach additional shader
+// objects, and detach or delete shader objects. None of these operations
+// will affect the executables that are part of the current state. However,
+// relinking the program object that is currently in use will install the
+// program object as part of the current rendering state if the link
+// operation was successful (see LinkProgram). If the program object
+// currently in use is relinked unsuccessfully, its link status will be set
+// to GL.FALSE, but the executables and associated state will remain part of
+// the current state until a subsequent call to UseProgram removes it from
+// use. After it is removed from use, it cannot be made part of current state
+// until it has been successfully relinked.
+//
+// If program contains shader objects of type GL.VERTEX_SHADER but it does
+// not contain shader objects of type GL.FRAGMENT_SHADER, an executable will
+// be installed on the vertex processor, but fixed functionality will be used
+// for fragment processing. Similarly, if program contains shader objects of
+// type GL.FRAGMENT_SHADER but it does not contain shader objects of type
+// GL.VERTEX_SHADER, an executable will be installed on the fragment
+// processor, but fixed functionality will be used for vertex processing. If
+// program is 0, the programmable processors will be disabled, and fixed
+// functionality will be used for both vertex and fragment processing.
+//
+// While a program object is in use, the state that controls the disabled
+// fixed functionality may also be updated using the normal OpenGL calls.
+//
+// Like display lists and texture objects, the name space for program objects
+// may be shared across a set of contexts, as long as the server sides of the
+// contexts share the same address space. If the name space is shared across
+// contexts, any attached objects and the data associated with those attached
+// objects are shared as well.
+//
+// Applications are responsible for providing the synchronization across API
+// calls when objects are accessed from different execution threads.
+//
+// Error GL.INVALID_VALUE is generated if program is neither 0 nor a value
+// generated by OpenGL. GL.INVALID_OPERATION is generated if program is not
+// a program object. GL.INVALID_OPERATION is generated if program could not
+// be made part of current state. GL.INVALID_OPERATION is generated if
+// UseProgram is executed between the execution of Begin and the
+// corresponding execution of End.
+//
+// UseProgram is available in GL version 2.0 or greater.
+func (gl *GL) UseProgram(program glbase.Program) {
+ C.gl3_0_glUseProgram(gl.funcs, C.GLuint(program))
+}
+
+// ShaderSource sets the source code in shader to the provided source code. Any source
+// code previously stored in the shader object is completely replaced.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader is not a shader
+// object. GL.INVALID_VALUE is generated if count is less than 0.
+// GL.INVALID_OPERATION is generated if ShaderSource is executed between the
+// execution of Begin and the corresponding execution of End.
+//
+// ShaderSource is available in GL version 2.0 or greater.
+func (gl *GL) ShaderSource(shader glbase.Shader, source ...string) {
+ count := len(source)
+ length := make([]int32, count)
+ source_c := make([]unsafe.Pointer, count)
+ for i, src := range source {
+ length[i] = int32(len(src))
+ if len(src) > 0 {
+ source_c[i] = *(*unsafe.Pointer)(unsafe.Pointer(&src))
+ } else {
+ source_c[i] = unsafe.Pointer(uintptr(0))
+ }
+ }
+ C.gl3_0_glShaderSource(gl.funcs, C.GLuint(shader), C.GLsizei(count), (**C.GLchar)(unsafe.Pointer(&source_c[0])), (*C.GLint)(unsafe.Pointer(&length[0])))
+}
+
+// LinkProgram links the program object specified by program. If any shader
+// objects of type GL.VERTEX_SHADER are attached to program, they will be
+// used to create an executable that will run on the programmable vertex
+// processor. If any shader objects of type GL.FRAGMENT_SHADER are attached
+// to program, they will be used to create an executable that will run on the
+// programmable fragment processor.
+//
+// The status of the link operation will be stored as part of the program
+// object's state. This value will be set to GL.TRUE if the program object
+// was linked without errors and is ready for use, and GL.FALSE otherwise. It
+// can be queried by calling GetProgramiv with arguments program and
+// GL.LINK_STATUS.
+//
+// As a result of a successful link operation, all active user-defined
+// uniform variables belonging to program will be initialized to 0, and each
+// of the program object's active uniform variables will be assigned a
+// location that can be queried by calling GetUniformLocation. Also, any
+// active user-defined attribute variables that have not been bound to a
+// generic vertex attribute index will be bound to one at this time.
+//
+// Linking of a program object can fail for a number of reasons as specified
+// in the OpenGL Shading Language Specification. The following lists some of
+// the conditions that will cause a link error.
+//
+// - The number of active attribute variables supported by the
+// implementation has been exceeded.
+//
+// - The storage limit for uniform variables has been exceeded.
+//
+// - The number of active uniform variables supported by the implementation
+// has been exceeded.
+//
+// - The main function is missing for the vertex shader or the fragment
+// shader.
+//
+// - A varying variable actually used in the fragment shader is not
+// declared in the same way (or is not declared at all) in the vertex
+// shader.
+//
+// - A reference to a function or variable name is unresolved.
+//
+// - A shared global is declared with two different types or two different
+// initial values.
+//
+// - One or more of the attached shader objects has not been successfully
+// compiled.
+//
+// - Binding a generic attribute matrix caused some rows of the matrix to
+// fall outside the allowed maximum of GL.MAX_VERTEX_ATTRIBS.
+//
+// - Not enough contiguous vertex attribute slots could be found to bind
+// attribute matrices.
+//
+// When a program object has been successfully linked, the program object can
+// be made part of current state by calling UseProgram. Whether or not the
+// link operation was successful, the program object's information log will
+// be overwritten. The information log can be retrieved by calling
+// GetProgramInfoLog.
+//
+// LinkProgram will also install the generated executables as part of the
+// current rendering state if the link operation was successful and the
+// specified program object is already currently in use as a result of a
+// previous call to UseProgram. If the program object currently in use is
+// relinked unsuccessfully, its link status will be set to GL.FALSE , but the
+// executables and associated state will remain part of the current state
+// until a subsequent call to UseProgram removes it from use. After it is
+// removed from use, it cannot be made part of current state until it has
+// been successfully relinked.
+//
+// If program contains shader objects of type GL.VERTEX_SHADER but does not
+// contain shader objects of type GL.FRAGMENT_SHADER, the vertex shader will
+// be linked against the implicit interface for fixed functionality fragment
+// processing. Similarly, if program contains shader objects of type
+// GL.FRAGMENT_SHADER but it does not contain shader objects of type
+// GL.VERTEX_SHADER, the fragment shader will be linked against the implicit
+// interface for fixed functionality vertex processing.
+//
+// The program object's information log is updated and the program is
+// generated at the time of the link operation. After the link operation,
+// applications are free to modify attached shader objects, compile attached
+// shader objects, detach shader objects, delete shader objects, and attach
+// additional shader objects. None of these operations affects the
+// information log or the program that is part of the program object.
+//
+// If the link operation is unsuccessful, any information about a previous
+// link operation on program is lost (a failed link does not restore the
+// old state of program). Certain information can still be retrieved
+// from program even after an unsuccessful link operation. See for instance
+// GetActiveAttrib and GetActiveUniform.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program
+// object. GL.INVALID_OPERATION is generated if LinkProgram is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// LinkProgram is available in GL version 2.0 or greater.
+func (gl *GL) LinkProgram(program glbase.Program) {
+ C.gl3_0_glLinkProgram(gl.funcs, C.GLuint(program))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsShader.xml
+func (gl *GL) IsShader(shader glbase.Shader) bool {
+ glresult := C.gl3_0_glIsShader(gl.funcs, C.GLuint(shader))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsProgram.xml
+func (gl *GL) IsProgram(program glbase.Program) bool {
+ glresult := C.gl3_0_glIsProgram(gl.funcs, C.GLuint(program))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// GetVertexAttribiv returns in params the value of a generic vertex attribute
+// parameter. The generic vertex attribute to be queried is specified by
+// index, and the parameter to be queried is specified by pname.
+//
+// The accepted parameter names are as follows:
+//
+// GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING
+// params returns a single value, the name of the buffer object
+// currently bound to the binding point corresponding to generic vertex
+// attribute array index. If no buffer object is bound, 0 is returned.
+// The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_ENABLED
+// params returns a single value that is non-zero (true) if the vertex
+// attribute array for index is enabled and 0 (false) if it is
+// disabled. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_SIZE
+// params returns a single value, the size of the vertex attribute
+// array for index. The size is the number of values for each element
+// of the vertex attribute array, and it will be 1, 2, 3, or 4. The
+// initial value is 4.
+//
+// GL.VERTEX_ATTRIB_ARRAY_STRIDE
+// params returns a single value, the array stride for (number of bytes
+// between successive elements in) the vertex attribute array for
+// index. A value of 0 indicates that the array elements are stored
+// sequentially in memory. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_TYPE
+// params returns a single value, a symbolic constant indicating the
+// array type for the vertex attribute array for index. Possible values
+// are GL.BYTE, GL.UNSIGNED_BYTE, GL.SHORT, GL.UNSIGNED_SHORT, GL.INT,
+// GL.UNSIGNED_INT, GL.FLOAT, and GL.DOUBLE. The initial value is
+// GL.FLOAT.
+//
+// GL.VERTEX_ATTRIB_ARRAY_NORMALIZED
+// params returns a single value that is non-zero (true) if fixed-point
+// data types for the vertex attribute array indicated by index are
+// normalized when they are converted to floating point, and 0 (false)
+// otherwise. The initial value is 0.
+//
+// GL.CURRENT_VERTEX_ATTRIB
+// params returns four values that represent the current value for the
+// generic vertex attribute specified by index. Generic vertex
+// attribute 0 is unique in that it has no current state, so an error
+// will be generated if index is 0. The initial value for all other
+// generic vertex attributes is (0,0,0,1).
+//
+// All of the parameters except GL.CURRENT_VERTEX_ATTRIB represent
+// client-side state.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_ENUM is generated if pname is not an
+// accepted value. GL.INVALID_OPERATION is generated if index is 0 and pname
+// is GL.CURRENT_VERTEX_ATTRIB.
+//
+// GetVertexAttribiv is available in GL version 2.0 or greater.
+func (gl *GL) GetVertexAttribiv(index glbase.Attrib, pname glbase.Enum, params []int32) {
+ var params_c [4]int32
+ C.gl3_0_glGetVertexAttribiv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetVertexAttribfv returns in params the value of a generic vertex attribute
+// parameter. The generic vertex attribute to be queried is specified by
+// index, and the parameter to be queried is specified by pname.
+//
+// The accepted parameter names are as follows:
+//
+// GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING
+// params returns a single value, the name of the buffer object
+// currently bound to the binding point corresponding to generic vertex
+// attribute array index. If no buffer object is bound, 0 is returned.
+// The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_ENABLED
+// params returns a single value that is non-zero (true) if the vertex
+// attribute array for index is enabled and 0 (false) if it is
+// disabled. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_SIZE
+// params returns a single value, the size of the vertex attribute
+// array for index. The size is the number of values for each element
+// of the vertex attribute array, and it will be 1, 2, 3, or 4. The
+// initial value is 4.
+//
+// GL.VERTEX_ATTRIB_ARRAY_STRIDE
+// params returns a single value, the array stride for (number of bytes
+// between successive elements in) the vertex attribute array for
+// index. A value of 0 indicates that the array elements are stored
+// sequentially in memory. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_TYPE
+// params returns a single value, a symbolic constant indicating the
+// array type for the vertex attribute array for index. Possible values
+// are GL.BYTE, GL.UNSIGNED_BYTE, GL.SHORT, GL.UNSIGNED_SHORT, GL.INT,
+// GL.UNSIGNED_INT, GL.FLOAT, and GL.DOUBLE. The initial value is
+// GL.FLOAT.
+//
+// GL.VERTEX_ATTRIB_ARRAY_NORMALIZED
+// params returns a single value that is non-zero (true) if fixed-point
+// data types for the vertex attribute array indicated by index are
+// normalized when they are converted to floating point, and 0 (false)
+// otherwise. The initial value is 0.
+//
+// GL.CURRENT_VERTEX_ATTRIB
+// params returns four values that represent the current value for the
+// generic vertex attribute specified by index. Generic vertex
+// attribute 0 is unique in that it has no current state, so an error
+// will be generated if index is 0. The initial value for all other
+// generic vertex attributes is (0,0,0,1).
+//
+// All of the parameters except GL.CURRENT_VERTEX_ATTRIB represent
+// client-side state.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_ENUM is generated if pname is not an
+// accepted value. GL.INVALID_OPERATION is generated if index is 0 and pname
+// is GL.CURRENT_VERTEX_ATTRIB.
+//
+// GetVertexAttribfv is available in GL version 2.0 or greater.
+func (gl *GL) GetVertexAttribfv(index glbase.Attrib, pname glbase.Enum, params []float32) {
+ var params_c [4]float32
+ C.gl3_0_glGetVertexAttribfv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetVertexAttribdv returns in params the value of a generic vertex attribute
+// parameter. The generic vertex attribute to be queried is specified by
+// index, and the parameter to be queried is specified by pname.
+//
+// The accepted parameter names are as follows:
+//
+// GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING
+// params returns a single value, the name of the buffer object
+// currently bound to the binding point corresponding to generic vertex
+// attribute array index. If no buffer object is bound, 0 is returned.
+// The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_ENABLED
+// params returns a single value that is non-zero (true) if the vertex
+// attribute array for index is enabled and 0 (false) if it is
+// disabled. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_SIZE
+// params returns a single value, the size of the vertex attribute
+// array for index. The size is the number of values for each element
+// of the vertex attribute array, and it will be 1, 2, 3, or 4. The
+// initial value is 4.
+//
+// GL.VERTEX_ATTRIB_ARRAY_STRIDE
+// params returns a single value, the array stride for (number of bytes
+// between successive elements in) the vertex attribute array for
+// index. A value of 0 indicates that the array elements are stored
+// sequentially in memory. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_TYPE
+// params returns a single value, a symbolic constant indicating the
+// array type for the vertex attribute array for index. Possible values
+// are GL.BYTE, GL.UNSIGNED_BYTE, GL.SHORT, GL.UNSIGNED_SHORT, GL.INT,
+// GL.UNSIGNED_INT, GL.FLOAT, and GL.DOUBLE. The initial value is
+// GL.FLOAT.
+//
+// GL.VERTEX_ATTRIB_ARRAY_NORMALIZED
+// params returns a single value that is non-zero (true) if fixed-point
+// data types for the vertex attribute array indicated by index are
+// normalized when they are converted to floating point, and 0 (false)
+// otherwise. The initial value is 0.
+//
+// GL.CURRENT_VERTEX_ATTRIB
+// params returns four values that represent the current value for the
+// generic vertex attribute specified by index. Generic vertex
+// attribute 0 is unique in that it has no current state, so an error
+// will be generated if index is 0. The initial value for all other
+// generic vertex attributes is (0,0,0,1).
+//
+// All of the parameters except GL.CURRENT_VERTEX_ATTRIB represent
+// client-side state.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_ENUM is generated if pname is not an
+// accepted value. GL.INVALID_OPERATION is generated if index is 0 and pname
+// is GL.CURRENT_VERTEX_ATTRIB.
+//
+// GetVertexAttribdv is available in GL version 2.0 or greater.
+func (gl *GL) GetVertexAttribdv(index glbase.Attrib, pname glbase.Enum, params []float64) {
+ var params_c [4]float64
+ C.gl3_0_glGetVertexAttribdv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetUniformiv returns in params the value of the specified uniform
+// variable. The type of the uniform variable specified by location
+// determines the number of values returned. If the uniform variable is
+// defined in the shader as a boolean, int, or float, a single value will be
+// returned. If it is defined as a vec2, ivec2, or bvec2, two values will be
+// returned. If it is defined as a vec3, ivec3, or bvec3, three values will
+// be returned, and so on. To query values stored in uniform variables
+// declared as arrays, call GetUniformiv for each element of the array. To
+// query values stored in uniform variables declared as structures, call
+// GetUniformiv for each field in the structure. The values for uniform
+// variables declared as a matrix will be returned in column major order.
+//
+// The locations assigned to uniform variables are not known until the
+// program object is linked. After linking has occurred, the command
+// GetUniformLocation can be used to obtain the location of a uniform
+// variable. This location value can then be passed to GetUniformiv in order
+// to query the current value of the uniform variable. After a program object
+// has been linked successfully, the index values for uniform variables
+// remain fixed until the next link command occurs. The uniform variable
+// values can only be queried after a link if the link was successful.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program
+// object. GL.INVALID_OPERATION is generated if program has not been
+// successfully linked. GL.INVALID_OPERATION is generated if location does
+// not correspond to a valid uniform variable location for the specified
+// program object. GL.INVALID_OPERATION is generated if GetUniformiv is
+// executed between the execution of Begin and the corresponding execution of
+// End.
+//
+// GetUniformiv is available in GL version 2.0 or greater.
+func (gl *GL) GetUniformiv(program glbase.Program, location glbase.Uniform, params []int32) {
+ var params_c [4]int32
+ C.gl3_0_glGetUniformiv(gl.funcs, C.GLuint(program), C.GLint(location), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetUniformfv returns in params the value of the specified uniform
+// variable. The type of the uniform variable specified by location
+// determines the number of values returned. If the uniform variable is
+// defined in the shader as a boolean, int, or float, a single value will be
+// returned. If it is defined as a vec2, ivec2, or bvec2, two values will be
+// returned. If it is defined as a vec3, ivec3, or bvec3, three values will
+// be returned, and so on. To query values stored in uniform variables
+// declared as arrays, call GetUniformfv for each element of the array. To
+// query values stored in uniform variables declared as structures, call
+// GetUniformfv for each field in the structure. The values for uniform
+// variables declared as a matrix will be returned in column major order.
+//
+// The locations assigned to uniform variables are not known until the
+// program object is linked. After linking has occurred, the command
+// GetUniformLocation can be used to obtain the location of a uniform
+// variable. This location value can then be passed to GetUniformfv in order
+// to query the current value of the uniform variable. After a program object
+// has been linked successfully, the index values for uniform variables
+// remain fixed until the next link command occurs. The uniform variable
+// values can only be queried after a link if the link was successful.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program
+// object. GL.INVALID_OPERATION is generated if program has not been
+// successfully linked. GL.INVALID_OPERATION is generated if location does
+// not correspond to a valid uniform variable location for the specified
+// program object. GL.INVALID_OPERATION is generated if GetUniformfv is
+// executed between the execution of Begin and the corresponding execution of
+// End.
+//
+// GetUniformfv is available in GL version 2.0 or greater.
+func (gl *GL) GetUniformfv(program glbase.Program, location glbase.Uniform, params []float32) {
+ var params_c [4]float32
+ C.gl3_0_glGetUniformfv(gl.funcs, C.GLuint(program), C.GLint(location), (*C.GLfloat)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetUniformLocation returns an integer that represents the location of a
+// specific uniform variable within a program object. name must be an active
+// uniform variable name in program that is not a structure, an array of
+// structures, or a subcomponent of a vector or a matrix. This function
+// returns -1 if name does not correspond to an active uniform variable in
+// program or if name starts with the reserved prefix "gl_".
+//
+// Uniform variables that are structures or arrays of structures may be
+// queried by calling GetUniformLocation for each field within the
+// structure. The array element operator "[]" and the structure field
+// operator "." may be used in name in order to select elements within an
+// array or fields within a structure. The result of using these operators is
+// not allowed to be another structure, an array of structures, or a
+// subcomponent of a vector or a matrix. Except if the last part of name
+// indicates a uniform variable array, the location of the first element of
+// an array can be retrieved by using the name of the array, or by using the
+// name appended by "[0]".
+//
+// The actual locations assigned to uniform variables are not known until the
+// program object is linked successfully. After linking has occurred, the
+// command GetUniformLocation can be used to obtain the location of a
+// uniform variable. This location value can then be passed to Uniform to
+// set the value of the uniform variable or to GetUniform in order to query
+// the current value of the uniform variable. After a program object has been
+// linked successfully, the index values for uniform variables remain fixed
+// until the next link command occurs. Uniform variable locations and values
+// can only be queried after a link if the link was successful.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program object.
+// GL.INVALID_OPERATION is generated if program has not been successfully
+// linked. GL.INVALID_OPERATION is generated if GetUniformLocation is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// GetUniformLocation is available in GL version 2.0 or greater.
+func (gl *GL) GetUniformLocation(program glbase.Program, name string) glbase.Uniform {
+ name_cstr := C.CString(name)
+ glresult := C.gl3_0_glGetUniformLocation(gl.funcs, C.GLuint(program), (*C.GLchar)(name_cstr))
+ C.free(unsafe.Pointer(name_cstr))
+ return glbase.Uniform(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetShaderSource.xml
+func (gl *GL) GetShaderSource(shader glbase.Shader, bufSize int32, length []int32, source []byte) {
+ C.gl3_0_glGetShaderSource(gl.funcs, C.GLuint(shader), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&source[0])))
+}
+
+// GetShaderInfoLog returns the information log for the specified shader
+// object. The information log for a shader object is modified when the
+// shader is compiled.
+//
+// The information log for a shader object is a string that may contain
+// diagnostic messages, warning messages, and other information about the
+// last compile operation. When a shader object is created, its information
+// log will be a string of length 0, and the size of the current log can be
+// obtained by calling GetShaderiv with the value GL.INFO_LOG_LENGTH.
+//
+// The information log for a shader object is the OpenGL implementer's
+// primary mechanism for conveying information about the compilation process.
+// Therefore, the information log can be helpful to application developers
+// during the development process, even when compilation is successful.
+// Application developers should not expect different OpenGL implementations
+// to produce identical information logs.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader is not a shader
+// object. GL.INVALID_VALUE is generated if maxLength is less than 0.
+// GL.INVALID_OPERATION is generated if GetShaderInfoLog is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// GetShaderInfoLog is available in GL version 2.0 or greater.
+func (gl *GL) GetShaderInfoLog(shader glbase.Shader) []byte {
+ var params [1]int32
+ var length int32
+ gl.GetShaderiv(shader, INFO_LOG_LENGTH, params[:])
+ bufSize := params[0]
+ infoLog := make([]byte, int(bufSize))
+ C.gl3_0_glGetShaderInfoLog(gl.funcs, C.GLuint(shader), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length)), (*C.GLchar)(unsafe.Pointer(&infoLog[0])))
+ return infoLog
+}
+
+// GetShaderiv GetShader returns in params the value of a parameter for a specific
+// shader object. The following parameters are defined:
+//
+// GL.SHADER_TYPE
+// params returns GL.VERTEX_SHADER if shader is a vertex shader object,
+// and GL.FRAGMENT_SHADER if shader is a fragment shader object.
+//
+// GL.DELETE_STATUS
+// params returns GL.TRUE if shader is currently flagged for deletion,
+// and GL.FALSE otherwise.
+//
+// GL.COMPILE_STATUS
+// params returns GL.TRUE if the last compile operation on shader was
+// successful, and GL.FALSE otherwise.
+//
+// GL.INFO_LOG_LENGTH
+// params returns the number of characters in the information log for
+// shader including the null termination character (the size of the
+// character buffer required to store the information log). If shader has
+// no information log, a value of 0 is returned.
+//
+// GL.SHADER_SOURCE_LENGTH
+// params returns the length of the concatenation of the source strings
+// that make up the shader source for the shader, including the null
+// termination character. (the size of the character buffer
+// required to store the shader source). If no source code exists, 0 is
+// returned.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader does not refer to a
+// shader object. GL.INVALID_ENUM is generated if pname is not an accepted
+// value. GL.INVALID_OPERATION is generated if GetShader is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// GetShaderiv is available in GL version 2.0 or greater.
+func (gl *GL) GetShaderiv(shader glbase.Shader, pname glbase.Enum, params []int32) {
+ var params_c [4]int32
+ C.gl3_0_glGetShaderiv(gl.funcs, C.GLuint(shader), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetProgramInfoLog returns the information log for the specified program
+// object. The information log for a program object is modified when the
+// program object is linked or validated.
+//
+// The information log for a program object is either an empty string, or a
+// string containing information about the last link operation, or a string
+// containing information about the last validation operation. It may contain
+// diagnostic messages, warning messages, and other information. When a
+// program object is created, its information log will be a string of length
+// 0, and the size of the current log can be obtained by calling GetProgramiv
+// with the value GL.INFO_LOG_LENGTH.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated
+// by OpenGL. GL.INVALID_OPERATION is generated if program is not a
+// program object.
+func (gl *GL) GetProgramInfoLog(program glbase.Program) []byte {
+ var params [1]int32
+ var length int32
+ gl.GetProgramiv(program, INFO_LOG_LENGTH, params[:])
+ bufSize := params[0]
+ infoLog := make([]byte, int(bufSize))
+ C.gl3_0_glGetProgramInfoLog(gl.funcs, C.GLuint(program), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length)), (*C.GLchar)(unsafe.Pointer(&infoLog[0])))
+ return infoLog
+}
+
+// GetProgramiv returns in params the value of a parameter for a specific
+// program object. The following parameters are defined:
+//
+// GL.DELETE_STATUS
+// params returns GL.TRUE if program is currently flagged for deletion,
+// and GL.FALSE otherwise.
+//
+// GL.LINK_STATUS
+// params returns GL.TRUE if the last link operation on program was
+// successful, and GL.FALSE otherwise.
+//
+// GL.VALIDATE_STATUS
+// params returns GL.TRUE or if the last validation operation on
+// program was successful, and GL.FALSE otherwise.
+//
+// GL.INFO_LOG_LENGTH
+// params returns the number of characters in the information log for
+// program including the null termination character (the size of
+// the character buffer required to store the information log). If
+// program has no information log, a value of 0 is returned.
+//
+// GL.ATTACHED_SHADERS
+// params returns the number of shader objects attached to program.
+//
+// GL.ACTIVE_ATTRIBUTES
+// params returns the number of active attribute variables for program.
+//
+// GL.ACTIVE_ATTRIBUTE_MAX_LENGTH
+// params returns the length of the longest active attribute name for
+// program, including the null termination character (the size of
+// the character buffer required to store the longest attribute name).
+// If no active attributes exist, 0 is returned.
+//
+// GL.ACTIVE_UNIFORMS
+// params returns the number of active uniform variables for program.
+//
+// GL.ACTIVE_UNIFORM_MAX_LENGTH
+// params returns the length of the longest active uniform variable
+// name for program, including the null termination character (i.e.,
+// the size of the character buffer required to store the longest
+// uniform variable name). If no active uniform variables exist, 0 is
+// returned.
+//
+// GL.TRANSFORM_FEEDBACK_BUFFER_MODE
+// params returns a symbolic constant indicating the buffer mode used
+// when transform feedback is active. This may be GL.SEPARATE_ATTRIBS
+// or GL.INTERLEAVED_ATTRIBS.
+//
+// GL.TRANSFORM_FEEDBACK_VARYINGS
+// params returns the number of varying variables to capture in transform
+// feedback mode for the program.
+//
+// GL.TRANSFORM_FEEDBACK_VARYING_MAX_LENGTH
+// params returns the length of the longest variable name to be used for
+// transform feedback, including the null-terminator.
+//
+// GL.GEOMETRY_VERTICES_OUT
+// params returns the maximum number of vertices that the geometry shader in
+// program will output.
+//
+// GL.GEOMETRY_INPUT_TYPE
+// params returns a symbolic constant indicating the primitive type accepted
+// as input to the geometry shader contained in program.
+//
+// GL.GEOMETRY_OUTPUT_TYPE
+// params returns a symbolic constant indicating the primitive type that will
+// be output by the geometry shader contained in program.
+//
+// GL.ACTIVE_UNIFORM_BLOCKS and GL.ACTIVE_UNIFORM_BLOCK_MAX_NAME_LENGTH are
+// available only if the GL version 3.1 or greater.
+//
+// GL.GEOMETRY_VERTICES_OUT, GL.GEOMETRY_INPUT_TYPE and
+// GL.GEOMETRY_OUTPUT_TYPE are accepted only if the GL version is 3.2 or
+// greater.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program does not refer to a
+// program object. GL.INVALID_OPERATION is generated if pname is
+// GL.GEOMETRY_VERTICES_OUT, GL.GEOMETRY_INPUT_TYPE, or
+// GL.GEOMETRY_OUTPUT_TYPE, and program does not contain a geometry shader.
+// GL.INVALID_ENUM is generated if pname is not an accepted value.
+func (gl *GL) GetProgramiv(program glbase.Program, pname glbase.Enum, params []int32) {
+ var params_c [4]int32
+ C.gl3_0_glGetProgramiv(gl.funcs, C.GLuint(program), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetAttribLocation queries the previously linked program object specified
+// by program for the attribute variable specified by name and returns the
+// index of the generic vertex attribute that is bound to that attribute
+// variable. If name is a matrix attribute variable, the index of the first
+// column of the matrix is returned. If the named attribute variable is not
+// an active attribute in the specified program object or if name starts with
+// the reserved prefix "gl_", a value of -1 is returned.
+//
+// The association between an attribute variable name and a generic attribute
+// index can be specified at any time by calling BindAttribLocation.
+// Attribute bindings do not go into effect until LinkProgram is called.
+// After a program object has been linked successfully, the index values for
+// attribute variables remain fixed until the next link command occurs. The
+// attribute values can only be queried after a link if the link was
+// successful. GetAttribLocation returns the binding that actually went
+// into effect the last time LinkProgram was called for the specified
+// program object. Attribute bindings that have been specified since the last
+// link operation are not returned by GetAttribLocation.
+//
+// Error GL_INVALID_OPERATION is generated if program is not a value
+// generated by OpenGL. GL_INVALID_OPERATION is generated if program is not
+// a program object. GL_INVALID_OPERATION is generated if program has not
+// been successfully linked. GL_INVALID_OPERATION is generated if
+// GetAttribLocation is executed between the execution of Begin and the
+// corresponding execution of End.
+//
+// GetAttribLocation is available in GL version 2.0 or greater.
+func (gl *GL) GetAttribLocation(program glbase.Program, name string) glbase.Attrib {
+ name_cstr := C.CString(name)
+ glresult := C.gl3_0_glGetAttribLocation(gl.funcs, C.GLuint(program), (*C.GLchar)(name_cstr))
+ C.free(unsafe.Pointer(name_cstr))
+ return glbase.Attrib(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetAttachedShaders.xml
+func (gl *GL) GetAttachedShaders(program glbase.Program, maxCount int32, count []int, obj []uint32) {
+ C.gl3_0_glGetAttachedShaders(gl.funcs, C.GLuint(program), C.GLsizei(maxCount), (*C.GLsizei)(unsafe.Pointer(&count[0])), (*C.GLuint)(unsafe.Pointer(&obj[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetActiveUniform.xml
+func (gl *GL) GetActiveUniform(program glbase.Program, index uint32, bufSize int32, length []int32, size []int, gltype []glbase.Enum, name []byte) {
+ C.gl3_0_glGetActiveUniform(gl.funcs, C.GLuint(program), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLint)(unsafe.Pointer(&size[0])), (*C.GLenum)(unsafe.Pointer(&gltype[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetActiveAttrib.xml
+func (gl *GL) GetActiveAttrib(program glbase.Program, index glbase.Attrib, bufSize int32, length []int32, size []int, gltype []glbase.Enum, name []byte) {
+ C.gl3_0_glGetActiveAttrib(gl.funcs, C.GLuint(program), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLint)(unsafe.Pointer(&size[0])), (*C.GLenum)(unsafe.Pointer(&gltype[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEnableVertexAttribArray.xml
+func (gl *GL) EnableVertexAttribArray(index glbase.Attrib) {
+ C.gl3_0_glEnableVertexAttribArray(gl.funcs, C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDisableVertexAttribArray.xml
+func (gl *GL) DisableVertexAttribArray(index glbase.Attrib) {
+ C.gl3_0_glDisableVertexAttribArray(gl.funcs, C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDetachShader.xml
+func (gl *GL) DetachShader(program glbase.Program, shader glbase.Shader) {
+ C.gl3_0_glDetachShader(gl.funcs, C.GLuint(program), C.GLuint(shader))
+}
+
+// DeleteShader frees the memory and invalidates the name associated with
+// the shader object specified by shader. This command effectively undoes the
+// effects of a call to CreateShader.
+//
+// If a shader object to be deleted is attached to a program object, it will
+// be flagged for deletion, but it will not be deleted until it is no longer
+// attached to any program object, for any rendering context (it must
+// be detached from wherever it was attached before it will be deleted). A
+// value of 0 for shader will be silently ignored.
+//
+// To determine whether an object has been flagged for deletion, call
+// GetShader with arguments shader and GL.DELETE_STATUS.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL.
+//
+// DeleteShader is available in GL version 2.0 or greater.
+func (gl *GL) DeleteShader(shader glbase.Shader) {
+ C.gl3_0_glDeleteShader(gl.funcs, C.GLuint(shader))
+}
+
+// DeleteProgram frees the memory and invalidates the name associated with
+// the program object specified by program. This command effectively undoes
+// the effects of a call to CreateProgram.
+//
+// If a program object is in use as part of current rendering state, it will
+// be flagged for deletion, but it will not be deleted until it is no longer
+// part of current state for any rendering context. If a program object to be
+// deleted has shader objects attached to it, those shader objects will be
+// automatically detached but not deleted unless they have already been
+// flagged for deletion by a previous call to DeleteShader. A value of 0
+// for program will be silently ignored.
+//
+// To determine whether a program object has been flagged for deletion, call
+// GetProgram with arguments program and GL.DELETE_STATUS.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL.
+//
+// DeleteProgram is available in GL version 2.0 or greater.
+func (gl *GL) DeleteProgram(program glbase.Program) {
+ C.gl3_0_glDeleteProgram(gl.funcs, C.GLuint(program))
+}
+
+// CreateShader creates an empty shader object and returns a non-zero value
+// by which it can be referenced. A shader object is used to maintain the
+// source code strings that define a shader. shaderType indicates the type of
+// shader to be created.
+//
+// Two types of shaders are supported. A shader of type GL.VERTEX_SHADER is a
+// shader that is intended to run on the programmable vertex processor and
+// replace the fixed functionality vertex processing in OpenGL. A shader of
+// type GL.FRAGMENT_SHADER is a shader that is intended to run on the
+// programmable fragment processor and replace the fixed functionality
+// fragment processing in OpenGL.
+//
+// When created, a shader object's GL.SHADER_TYPE parameter is set to either
+// GL.VERTEX_SHADER or GL.FRAGMENT_SHADER, depending on the value of
+// shaderType.
+//
+// Like display lists and texture objects, the name space for shader objects
+// may be shared across a set of contexts, as long as the server sides of the
+// contexts share the same address space. If the name space is shared across
+// contexts, any attached objects and the data associated with those attached
+// objects are shared as well.
+//
+// This function returns 0 if an error occurs creating the shader object.
+//
+// Error GL.INVALID_ENUM is generated if shaderType is not an accepted value.
+// GL.INVALID_OPERATION is generated if CreateShader is executed between the
+// execution of Begin and the corresponding execution of End.
+//
+// CreateShader is available in GL version 2.0 or greater.
+func (gl *GL) CreateShader(gltype glbase.Enum) glbase.Shader {
+ glresult := C.gl3_0_glCreateShader(gl.funcs, C.GLenum(gltype))
+ return glbase.Shader(glresult)
+}
+
+// CreateProgram creates an empty program object and returns a non-zero
+// value by which it can be referenced. A program object is an object to
+// which shader objects can be attached. This provides a mechanism to specify
+// the shader objects that will be linked to create a program. It also
+// provides a means for checking the compatibility of the shaders that will
+// be used to create a program (for instance, checking the compatibility
+// between a vertex shader and a fragment shader). When no longer needed as
+// part of a program object, shader objects can be detached.
+//
+// One or more executables are created in a program object by successfully
+// attaching shader objects to it with AttachShader, successfully compiling
+// the shader objects with CompileShader, and successfully linking the
+// program object with LinkProgram. These executables are made part of
+// current state when UseProgram is called. Program objects can be deleted
+// by calling DeleteProgram. The memory associated with the program object
+// will be deleted when it is no longer part of current rendering state for
+// any context.
+//
+// Like display lists and texture objects, the name space for program objects
+// may be shared across a set of contexts, as long as the server sides of the
+// contexts share the same address space. If the name space is shared across
+// contexts, any attached objects and the data associated with those attached
+// objects are shared as well.
+//
+// Applications are responsible for providing the synchronization across API
+// calls when objects are accessed from different execution threads.
+//
+// This function returns 0 if an error occurs creating the program object.
+//
+// Error GL.INVALID_OPERATION is generated if CreateProgram is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// CreateProgram is available in GL version 2.0 or greater.
+func (gl *GL) CreateProgram() glbase.Program {
+ glresult := C.gl3_0_glCreateProgram(gl.funcs)
+ return glbase.Program(glresult)
+}
+
+// CompileShader compiles the source code strings that have been stored in
+// the shader object specified by shader.
+//
+// The compilation status will be stored as part of the shader object's
+// state. This value will be set to GL.TRUE if the shader was compiled without
+// errors and is ready for use, and GL.FALSE otherwise. It can be queried by
+// calling GetShaderiv with arguments shader and GL.COMPILE_STATUS.
+//
+// Compilation of a shader can fail for a number of reasons as specified by
+// the OpenGL Shading Language Specification. Whether or not the compilation
+// was successful, information about the compilation can be obtained from the
+// shader object's information log by calling GetShaderInfoLog.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader is not a shader
+// object. GL.INVALID_OPERATION is generated if CompileShader is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// CompileShader is available in GL version 2.0 or greater.
+func (gl *GL) CompileShader(shader glbase.Shader) {
+ C.gl3_0_glCompileShader(gl.funcs, C.GLuint(shader))
+}
+
+// BindAttribLocation associates a user-defined attribute variable in the program
+// object specified by program with a generic vertex attribute index. The name
+// parameter specifies the name of the vertex shader attribute variable to
+// which index is to be bound. When program is made part of the current state,
+// values provided via the generic vertex attribute index will modify the
+// value of the user-defined attribute variable specified by name.
+//
+// If name refers to a matrix attribute variable, index refers to the first
+// column of the matrix. Other matrix columns are then automatically bound to
+// locations index+1 for a matrix of type mat2; index+1 and index+2 for a
+// matrix of type mat3; and index+1, index+2, and index+3 for a matrix of
+// type mat4.
+//
+// This command makes it possible for vertex shaders to use descriptive names
+// for attribute variables rather than generic variables that are numbered
+// from 0 to GL.MAX_VERTEX_ATTRIBS-1. The values sent to each generic
+// attribute index are part of current state, just like standard vertex
+// attributes such as color, normal, and vertex position. If a different
+// program object is made current by calling UseProgram, the generic vertex
+// attributes are tracked in such a way that the same values will be observed
+// by attributes in the new program object that are also bound to index.
+//
+// Attribute variable name-to-generic attribute index bindings for a program
+// object can be explicitly assigned at any time by calling
+// BindAttribLocation. Attribute bindings do not go into effect until
+// LinkProgram is called. After a program object has been linked
+// successfully, the index values for generic attributes remain fixed (and
+// their values can be queried) until the next link command occurs.
+//
+// Applications are not allowed to bind any of the standard OpenGL vertex
+// attributes using this command, as they are bound automatically when
+// needed. Any attribute binding that occurs after the program object has
+// been linked will not take effect until the next time the program object is
+// linked.
+//
+// If name was bound previously, that information is lost. Thus you cannot
+// bind one user-defined attribute variable to multiple indices, but you can
+// bind multiple user-defined attribute variables to the same index.
+//
+// Applications are allowed to bind more than one user-defined attribute
+// variable to the same generic vertex attribute index. This is called
+// aliasing, and it is allowed only if just one of the aliased attributes is
+// active in the executable program, or if no path through the shader
+// consumes more than one attribute of a set of attributes aliased to the
+// same location. The compiler and linker are allowed to assume that no
+// aliasing is done and are free to employ optimizations that work only in
+// the absence of aliasing. OpenGL implementations are not required to do
+// error checking to detect aliasing. Because there is no way to bind
+// standard attributes, it is not possible to alias generic attributes with
+// conventional ones (except for generic attribute 0).
+//
+// BindAttribLocation can be called before any vertex shader objects are
+// bound to the specified program object. It is also permissible to bind a
+// generic attribute index to an attribute variable name that is never used
+// in a vertex shader.
+//
+// Active attributes that are not explicitly bound will be bound by the
+// linker when LinkProgram is called. The locations assigned can be queried
+// by calling GetAttribLocation.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS.
+// GL.INVALID_OPERATION is generated if name starts with the reserved prefix "gl_".
+// GL.INVALID_VALUE is generated if program is not a value generated by OpenGL.
+// GL.INVALID_OPERATION is generated if program is not a program object.
+// GL.INVALID_OPERATION is generated if BindAttribLocation is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// BindAttribLocation is available in GL version 2.0 or greater.
+func (gl *GL) BindAttribLocation(program glbase.Program, index glbase.Attrib, name string) {
+ name_cstr := C.CString(name)
+ C.gl3_0_glBindAttribLocation(gl.funcs, C.GLuint(program), C.GLuint(index), (*C.GLchar)(name_cstr))
+ C.free(unsafe.Pointer(name_cstr))
+}
+
+// AttachShader attaches a shader object to a program object.
+//
+// In order to create an executable, there must be a way to specify the list
+// of things that will be linked together. Program objects provide this
+// mechanism. Shaders that are to be linked together in a program object must
+// first be attached to that program object. This indicates that shader will
+// be included in link operations that will be performed on program.
+//
+// All operations that can be performed on a shader object are valid whether
+// or not the shader object is attached to a program object. It is
+// permissible to attach a shader object to a program object before source
+// code has been loaded into the shader object or before the shader object
+// has been compiled. It is permissible to attach multiple shader objects of
+// the same type because each may contain a portion of the complete shader.
+// It is also permissible to attach a shader object to more than one program
+// object. If a shader object is deleted while it is attached to a program
+// object, it will be flagged for deletion, and deletion will not occur until
+// DetachShader is called to detach it from all program objects to which it
+// is attached.
+//
+// Error GL.INVALID_VALUE is generated if either program or shader is not a
+// value generated by OpenGL. GL.INVALID_OPERATION is generated if program
+// is not a program object. GL.INVALID_OPERATION is generated if shader is
+// not a shader object. GL.INVALID_OPERATION is generated if shader is
+// already attached to program. GL.INVALID_OPERATION is generated if
+// AttachShader is executed between the execution of Begin and the
+// corresponding execution of End.
+//
+// AttachShader is available in GL version 2.0 or greater.
+func (gl *GL) AttachShader(program glbase.Program, shader glbase.Shader) {
+ C.gl3_0_glAttachShader(gl.funcs, C.GLuint(program), C.GLuint(shader))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glStencilMaskSeparate.xml
+func (gl *GL) StencilMaskSeparate(face glbase.Enum, mask uint32) {
+ C.gl3_0_glStencilMaskSeparate(gl.funcs, C.GLenum(face), C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glStencilFuncSeparate.xml
+func (gl *GL) StencilFuncSeparate(face, glfunc glbase.Enum, ref int32, mask uint32) {
+ C.gl3_0_glStencilFuncSeparate(gl.funcs, C.GLenum(face), C.GLenum(glfunc), C.GLint(ref), C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glStencilOpSeparate.xml
+func (gl *GL) StencilOpSeparate(face, sfail, dpfail, dppass glbase.Enum) {
+ C.gl3_0_glStencilOpSeparate(gl.funcs, C.GLenum(face), C.GLenum(sfail), C.GLenum(dpfail), C.GLenum(dppass))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDrawBuffers.xml
+func (gl *GL) DrawBuffers(n int, bufs []glbase.Enum) {
+ C.gl3_0_glDrawBuffers(gl.funcs, C.GLsizei(n), (*C.GLenum)(unsafe.Pointer(&bufs[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBlendEquationSeparate.xml
+func (gl *GL) BlendEquationSeparate(modeRGB, modeAlpha glbase.Enum) {
+ C.gl3_0_glBlendEquationSeparate(gl.funcs, C.GLenum(modeRGB), C.GLenum(modeAlpha))
+}
+
+// UniformMatrix4x3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix4x3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix4x3fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(4*3) != 0 {
+ panic("invalid value length for UniformMatrix4x3fv")
+ }
+ count := len(value) / (4 * 3)
+ C.gl3_0_glUniformMatrix4x3fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix3x4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix3x4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix3x4fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(3*4) != 0 {
+ panic("invalid value length for UniformMatrix3x4fv")
+ }
+ count := len(value) / (3 * 4)
+ C.gl3_0_glUniformMatrix3x4fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix4x2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix4x2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix4x2fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(4*2) != 0 {
+ panic("invalid value length for UniformMatrix4x2fv")
+ }
+ count := len(value) / (4 * 2)
+ C.gl3_0_glUniformMatrix4x2fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix2x4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix2x4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix2x4fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(2*4) != 0 {
+ panic("invalid value length for UniformMatrix2x4fv")
+ }
+ count := len(value) / (2 * 4)
+ C.gl3_0_glUniformMatrix2x4fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix3x2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix3x2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix3x2fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(3*2) != 0 {
+ panic("invalid value length for UniformMatrix3x2fv")
+ }
+ count := len(value) / (3 * 2)
+ C.gl3_0_glUniformMatrix3x2fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix2x3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix2x3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix2x3fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(2*3) != 0 {
+ panic("invalid value length for UniformMatrix2x3fv")
+ }
+ count := len(value) / (2 * 3)
+ C.gl3_0_glUniformMatrix2x3fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsVertexArray.xml
+func (gl *GL) IsVertexArray(array uint32) bool {
+ glresult := C.gl3_0_glIsVertexArray(gl.funcs, C.GLuint(array))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGenVertexArrays.xml
+func (gl *GL) GenVertexArrays(n int, arrays []uint32) {
+ C.gl3_0_glGenVertexArrays(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&arrays[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDeleteVertexArrays.xml
+func (gl *GL) DeleteVertexArrays(n int, arrays []uint32) {
+ C.gl3_0_glDeleteVertexArrays(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&arrays[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBindVertexArray.xml
+func (gl *GL) BindVertexArray(array uint32) {
+ C.gl3_0_glBindVertexArray(gl.funcs, C.GLuint(array))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFlushMappedBufferRange.xml
+func (gl *GL) FlushMappedBufferRange(target glbase.Enum, offset, length int) {
+ C.gl3_0_glFlushMappedBufferRange(gl.funcs, C.GLenum(target), C.GLintptr(offset), C.GLsizeiptr(length))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFramebufferTextureLayer.xml
+func (gl *GL) FramebufferTextureLayer(target, attachment glbase.Enum, texture glbase.Texture, level int, layer int32) {
+ C.gl3_0_glFramebufferTextureLayer(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLuint(texture), C.GLint(level), C.GLint(layer))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRenderbufferStorageMultisample.xml
+func (gl *GL) RenderbufferStorageMultisample(target glbase.Enum, samples int32, internalFormat glbase.Enum, width, height int) {
+ C.gl3_0_glRenderbufferStorageMultisample(gl.funcs, C.GLenum(target), C.GLsizei(samples), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBlitFramebuffer.xml
+func (gl *GL) BlitFramebuffer(srcX0, srcY0, srcX1, srcY1, dstX0, dstY0, dstX1, dstY1 int32, mask glbase.Bitfield, filter glbase.Enum) {
+ C.gl3_0_glBlitFramebuffer(gl.funcs, C.GLint(srcX0), C.GLint(srcY0), C.GLint(srcX1), C.GLint(srcY1), C.GLint(dstX0), C.GLint(dstY0), C.GLint(dstX1), C.GLint(dstY1), C.GLbitfield(mask), C.GLenum(filter))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGenerateMipmap.xml
+func (gl *GL) GenerateMipmap(target glbase.Enum) {
+ C.gl3_0_glGenerateMipmap(gl.funcs, C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetFramebufferAttachmentParameteriv.xml
+func (gl *GL) GetFramebufferAttachmentParameteriv(target, attachment, pname glbase.Enum, params []int32) {
+ C.gl3_0_glGetFramebufferAttachmentParameteriv(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFramebufferRenderbuffer.xml
+func (gl *GL) FramebufferRenderbuffer(target, attachment, renderbuffertarget glbase.Enum, renderbuffer glbase.Renderbuffer) {
+ C.gl3_0_glFramebufferRenderbuffer(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(renderbuffertarget), C.GLuint(renderbuffer))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFramebufferTexture3D.xml
+func (gl *GL) FramebufferTexture3D(target, attachment, textarget glbase.Enum, texture glbase.Texture, level int, zoffset int32) {
+ C.gl3_0_glFramebufferTexture3D(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(textarget), C.GLuint(texture), C.GLint(level), C.GLint(zoffset))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFramebufferTexture2D.xml
+func (gl *GL) FramebufferTexture2D(target, attachment, textarget glbase.Enum, texture glbase.Texture, level int) {
+ C.gl3_0_glFramebufferTexture2D(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(textarget), C.GLuint(texture), C.GLint(level))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFramebufferTexture1D.xml
+func (gl *GL) FramebufferTexture1D(target, attachment, textarget glbase.Enum, texture glbase.Texture, level int) {
+ C.gl3_0_glFramebufferTexture1D(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(textarget), C.GLuint(texture), C.GLint(level))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCheckFramebufferStatus.xml
+func (gl *GL) CheckFramebufferStatus(target glbase.Enum) glbase.Enum {
+ glresult := C.gl3_0_glCheckFramebufferStatus(gl.funcs, C.GLenum(target))
+ return glbase.Enum(glresult)
+}
+
+// GenFramebuffers returns n framebuffer object names in ids. There is no
+// guarantee that the names form a contiguous set of integers; however, it is
+// guaranteed that none of the returned names was in use immediately before
+// the call to GenFramebuffers.
+//
+// Framebuffer object names returned by a call to GenFramebuffers are not
+// returned by subsequent calls, unless they are first deleted with
+// DeleteFramebuffers.
+//
+// The names returned in ids are marked as used, for the purposes of
+// GenFramebuffers only, but they acquire state and type only when they are
+// first bound.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+func (gl *GL) GenFramebuffers(n int) []glbase.Framebuffer {
+ if n == 0 {
+ return nil
+ }
+ framebuffers := make([]glbase.Framebuffer, n)
+ C.gl3_0_glGenFramebuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&framebuffers[0])))
+ return framebuffers
+}
+
+// DeleteFramebuffers deletes the framebuffer objects whose names are
+// stored in the framebuffers slice. The name zero is reserved by the GL and
+// is silently ignored, should it occur in framebuffers, as are other unused
+// names. Once a framebuffer object is deleted, its name is again unused and
+// it has no attachments. If a framebuffer that is currently bound to one or
+// more of the targets GL.DRAW_FRAMEBUFFER or GL.READ_FRAMEBUFFER is deleted,
+// it is as though BindFramebuffer had been executed with the corresponding
+// target and framebuffer zero.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// DeleteFramebuffers is available in GL version 3.0 or greater.
+func (gl *GL) DeleteFramebuffers(framebuffers []glbase.Framebuffer) {
+ n := len(framebuffers)
+ if n == 0 {
+ return
+ }
+ C.gl3_0_glDeleteFramebuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&framebuffers[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBindFramebuffer.xml
+func (gl *GL) BindFramebuffer(target glbase.Enum, framebuffer glbase.Framebuffer) {
+ C.gl3_0_glBindFramebuffer(gl.funcs, C.GLenum(target), C.GLuint(framebuffer))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsFramebuffer.xml
+func (gl *GL) IsFramebuffer(framebuffer glbase.Framebuffer) bool {
+ glresult := C.gl3_0_glIsFramebuffer(gl.funcs, C.GLuint(framebuffer))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetRenderbufferParameteriv.xml
+func (gl *GL) GetRenderbufferParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl3_0_glGetRenderbufferParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRenderbufferStorage.xml
+func (gl *GL) RenderbufferStorage(target, internalFormat glbase.Enum, width, height int) {
+ C.gl3_0_glRenderbufferStorage(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height))
+}
+
+// GenRenderbuffers returns n renderbuffer object names in renderbuffers.
+// There is no guarantee that the names form a contiguous set of integers;
+// however, it is guaranteed that none of the returned names was in use
+// immediately before the call to GenRenderbuffers.
+//
+// Renderbuffer object names returned by a call to GenRenderbuffers are not
+// returned by subsequent calls, unless they are first deleted with
+// DeleteRenderbuffers.
+//
+// The names returned in renderbuffers are marked as used, for the purposes
+// of GenRenderbuffers only, but they acquire state and type only when they
+// are first bound.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// GenRenderbuffers is available in GL version 3.0 or greater.
+func (gl *GL) GenRenderbuffers(n int) []glbase.Renderbuffer {
+ if n == 0 {
+ return nil
+ }
+ renderbuffers := make([]glbase.Renderbuffer, n)
+ C.gl3_0_glGenRenderbuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&renderbuffers[0])))
+ return renderbuffers
+}
+
+// DeleteRenderbuffers deletes the renderbuffer objects whose names are stored
+// in the renderbuffers slice. The name zero is reserved by the GL and
+// is silently ignored, should it occur in renderbuffers, as are other unused
+// names. Once a renderbuffer object is deleted, its name is again unused and
+// it has no contents. If a renderbuffer that is currently bound to the
+// target GL.RENDERBUFFER is deleted, it is as though BindRenderbuffer had
+// been executed with a target of GL.RENDERBUFFER and a name of zero.
+//
+// If a renderbuffer object is attached to one or more attachment points in
+// the currently bound framebuffer, then it as if FramebufferRenderbuffer
+// had been called, with a renderbuffer of zero for each attachment point to
+// which this image was attached in the currently bound framebuffer. In other
+// words, this renderbuffer object is first detached from all attachment
+// ponits in the currently bound framebuffer. Note that the renderbuffer
+// image is specifically not detached from any non-bound framebuffers.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// DeleteRenderbuffers is available in GL version 3.0 or greater.
+func (gl *GL) DeleteRenderbuffers(renderbuffers []glbase.Renderbuffer) {
+ n := len(renderbuffers)
+ if n == 0 {
+ return
+ }
+ C.gl3_0_glDeleteRenderbuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&renderbuffers[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBindRenderbuffer.xml
+func (gl *GL) BindRenderbuffer(target glbase.Enum, renderbuffer glbase.Renderbuffer) {
+ C.gl3_0_glBindRenderbuffer(gl.funcs, C.GLenum(target), C.GLuint(renderbuffer))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsRenderbuffer.xml
+func (gl *GL) IsRenderbuffer(renderbuffer glbase.Renderbuffer) bool {
+ glresult := C.gl3_0_glIsRenderbuffer(gl.funcs, C.GLuint(renderbuffer))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClearBufferfi.xml
+func (gl *GL) ClearBufferfi(buffer glbase.Enum, drawbuffer int32, depth float32, stencil int32) {
+ C.gl3_0_glClearBufferfi(gl.funcs, C.GLenum(buffer), C.GLint(drawbuffer), C.GLfloat(depth), C.GLint(stencil))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClearBufferfv.xml
+func (gl *GL) ClearBufferfv(buffer glbase.Enum, drawbuffer int32, value []float32) {
+ C.gl3_0_glClearBufferfv(gl.funcs, C.GLenum(buffer), C.GLint(drawbuffer), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClearBufferuiv.xml
+func (gl *GL) ClearBufferuiv(buffer glbase.Enum, drawbuffer int32, value []uint32) {
+ C.gl3_0_glClearBufferuiv(gl.funcs, C.GLenum(buffer), C.GLint(drawbuffer), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClearBufferiv.xml
+func (gl *GL) ClearBufferiv(buffer glbase.Enum, drawbuffer int32, value []int32) {
+ C.gl3_0_glClearBufferiv(gl.funcs, C.GLenum(buffer), C.GLint(drawbuffer), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTexParameterIuiv.xml
+func (gl *GL) GetTexParameterIuiv(target, pname glbase.Enum, params []uint32) {
+ C.gl3_0_glGetTexParameterIuiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTexParameterIiv.xml
+func (gl *GL) GetTexParameterIiv(target, pname glbase.Enum, params []int32) {
+ C.gl3_0_glGetTexParameterIiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexParameterIuiv.xml
+func (gl *GL) TexParameterIuiv(target, pname glbase.Enum, params []uint32) {
+ C.gl3_0_glTexParameterIuiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexParameterIiv.xml
+func (gl *GL) TexParameterIiv(target, pname glbase.Enum, params []int32) {
+ C.gl3_0_glTexParameterIiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// Uniform4uiv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform4uiv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4uiv(location glbase.Uniform, value []uint32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%4 != 0 {
+ panic("invalid value length for Uniform4uiv")
+ }
+ count := len(value) / 4
+ C.gl3_0_glUniform4uiv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform3uiv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform3uiv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3uiv(location glbase.Uniform, value []uint32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%3 != 0 {
+ panic("invalid value length for Uniform3uiv")
+ }
+ count := len(value) / 3
+ C.gl3_0_glUniform3uiv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform2uiv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform2uiv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2uiv(location glbase.Uniform, value []uint32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%2 != 0 {
+ panic("invalid value length for Uniform2uiv")
+ }
+ count := len(value) / 2
+ C.gl3_0_glUniform2uiv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform1uiv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform1uiv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1uiv(location glbase.Uniform, value []uint32) {
+ if len(value) == 0 {
+ return
+ }
+ count := len(value)
+ C.gl3_0_glUniform1uiv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4ui modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform4ui operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4ui(location glbase.Uniform, v0, v1, v2, v3 uint32) {
+ C.gl3_0_glUniform4ui(gl.funcs, C.GLint(location), C.GLuint(v0), C.GLuint(v1), C.GLuint(v2), C.GLuint(v3))
+}
+
+// Uniform3ui modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform3ui operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3ui(location glbase.Uniform, v0, v1, v2 uint32) {
+ C.gl3_0_glUniform3ui(gl.funcs, C.GLint(location), C.GLuint(v0), C.GLuint(v1), C.GLuint(v2))
+}
+
+// Uniform2ui modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform2ui operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2ui(location glbase.Uniform, v0, v1 uint32) {
+ C.gl3_0_glUniform2ui(gl.funcs, C.GLint(location), C.GLuint(v0), C.GLuint(v1))
+}
+
+// Uniform1ui modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform1ui operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1ui(location glbase.Uniform, v0 uint32) {
+ C.gl3_0_glUniform1ui(gl.funcs, C.GLint(location), C.GLuint(v0))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetFragDataLocation.xml
+func (gl *GL) GetFragDataLocation(program glbase.Program, name []byte) int32 {
+ glresult := C.gl3_0_glGetFragDataLocation(gl.funcs, C.GLuint(program), (*C.GLchar)(unsafe.Pointer(&name[0])))
+ return int32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBindFragDataLocation.xml
+func (gl *GL) BindFragDataLocation(program glbase.Program, color uint32, name []byte) {
+ C.gl3_0_glBindFragDataLocation(gl.funcs, C.GLuint(program), C.GLuint(color), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetUniformuiv.xml
+func (gl *GL) GetUniformuiv(program glbase.Program, location glbase.Uniform, params []uint32) {
+ C.gl3_0_glGetUniformuiv(gl.funcs, C.GLuint(program), C.GLint(location), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetVertexAttribIuiv.xml
+func (gl *GL) GetVertexAttribIuiv(index glbase.Attrib, pname glbase.Enum, params []uint32) {
+ C.gl3_0_glGetVertexAttribIuiv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetVertexAttribIiv.xml
+func (gl *GL) GetVertexAttribIiv(index glbase.Attrib, pname glbase.Enum, params []int32) {
+ C.gl3_0_glGetVertexAttribIiv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribIPointer.xml
+func (gl *GL) VertexAttribIPointer(index glbase.Attrib, size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_0_glVertexAttribIPointer(gl.funcs, C.GLuint(index), C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEndConditionalRender.xml
+func (gl *GL) EndConditionalRender() {
+ C.gl3_0_glEndConditionalRender(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBeginConditionalRender.xml
+func (gl *GL) BeginConditionalRender(id uint32, mode glbase.Enum) {
+ C.gl3_0_glBeginConditionalRender(gl.funcs, C.GLuint(id), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClampColor.xml
+func (gl *GL) ClampColor(target, clamp glbase.Enum) {
+ C.gl3_0_glClampColor(gl.funcs, C.GLenum(target), C.GLenum(clamp))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTransformFeedbackVarying.xml
+func (gl *GL) GetTransformFeedbackVarying(program glbase.Program, index uint32, bufSize int32, length []int32, size []int, gltype []glbase.Enum, name []byte) {
+ C.gl3_0_glGetTransformFeedbackVarying(gl.funcs, C.GLuint(program), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLsizei)(unsafe.Pointer(&size[0])), (*C.GLenum)(unsafe.Pointer(&gltype[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBindBufferBase.xml
+func (gl *GL) BindBufferBase(target glbase.Enum, index uint32, buffer glbase.Buffer) {
+ C.gl3_0_glBindBufferBase(gl.funcs, C.GLenum(target), C.GLuint(index), C.GLuint(buffer))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBindBufferRange.xml
+func (gl *GL) BindBufferRange(target glbase.Enum, index uint32, buffer glbase.Buffer, offset, size int) {
+ C.gl3_0_glBindBufferRange(gl.funcs, C.GLenum(target), C.GLuint(index), C.GLuint(buffer), C.GLintptr(offset), C.GLsizeiptr(size))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEndTransformFeedback.xml
+func (gl *GL) EndTransformFeedback() {
+ C.gl3_0_glEndTransformFeedback(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBeginTransformFeedback.xml
+func (gl *GL) BeginTransformFeedback(primitiveMode glbase.Enum) {
+ C.gl3_0_glBeginTransformFeedback(gl.funcs, C.GLenum(primitiveMode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsEnabledi.xml
+func (gl *GL) IsEnabledi(target glbase.Enum, index uint32) bool {
+ glresult := C.gl3_0_glIsEnabledi(gl.funcs, C.GLenum(target), C.GLuint(index))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDisablei.xml
+func (gl *GL) Disablei(target glbase.Enum, index uint32) {
+ C.gl3_0_glDisablei(gl.funcs, C.GLenum(target), C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEnablei.xml
+func (gl *GL) Enablei(target glbase.Enum, index uint32) {
+ C.gl3_0_glEnablei(gl.funcs, C.GLenum(target), C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetIntegeri_v.xml
+func (gl *GL) GetIntegeri_v(target glbase.Enum, index uint32, data []int32) {
+ C.gl3_0_glGetIntegeri_v(gl.funcs, C.GLenum(target), C.GLuint(index), (*C.GLint)(unsafe.Pointer(&data[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetBooleani_v.xml
+func (gl *GL) GetBooleani_v(target glbase.Enum, index uint32, data []bool) {
+ C.gl3_0_glGetBooleani_v(gl.funcs, C.GLenum(target), C.GLuint(index), (*C.GLboolean)(unsafe.Pointer(&data[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColorMaski.xml
+func (gl *GL) ColorMaski(index uint32, r, g, b, a bool) {
+ C.gl3_0_glColorMaski(gl.funcs, C.GLuint(index), *(*C.GLboolean)(unsafe.Pointer(&r)), *(*C.GLboolean)(unsafe.Pointer(&g)), *(*C.GLboolean)(unsafe.Pointer(&b)), *(*C.GLboolean)(unsafe.Pointer(&a)))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTranslatef.xml
+func (gl *GL) Translatef(x, y, z float32) {
+ C.gl3_0_glTranslatef(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTranslated.xml
+func (gl *GL) Translated(x, y, z float64) {
+ C.gl3_0_glTranslated(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glScalef.xml
+func (gl *GL) Scalef(x, y, z float32) {
+ C.gl3_0_glScalef(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glScaled.xml
+func (gl *GL) Scaled(x, y, z float64) {
+ C.gl3_0_glScaled(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRotatef.xml
+func (gl *GL) Rotatef(angle, x, y, z float32) {
+ C.gl3_0_glRotatef(gl.funcs, C.GLfloat(angle), C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRotated.xml
+func (gl *GL) Rotated(angle, x, y, z float64) {
+ C.gl3_0_glRotated(gl.funcs, C.GLdouble(angle), C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPushMatrix.xml
+func (gl *GL) PushMatrix() {
+ C.gl3_0_glPushMatrix(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPopMatrix.xml
+func (gl *GL) PopMatrix() {
+ C.gl3_0_glPopMatrix(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glOrtho.xml
+func (gl *GL) Ortho(left, right, bottom, top, zNear, zFar float64) {
+ C.gl3_0_glOrtho(gl.funcs, C.GLdouble(left), C.GLdouble(right), C.GLdouble(bottom), C.GLdouble(top), C.GLdouble(zNear), C.GLdouble(zFar))
+}
+
+// MultMatrixd multiplies the current matrix with the provided matrix.
+//
+// The m parameter must hold 16 consecutive elements of a 4x4 column-major matrix.
+//
+// The current matrix is determined by the current matrix mode (see
+// MatrixMode). It is either the projection matrix, modelview matrix, or the
+// texture matrix.
+//
+// For example, if the current matrix is C and the coordinates to be transformed
+// are v = (v[0], v[1], v[2], v[3]), then the current transformation is C × v, or
+//
+// c[0] c[4] c[8] c[12] v[0]
+// c[1] c[5] c[9] c[13] v[1]
+// c[2] c[6] c[10] c[14] X v[2]
+// c[3] c[7] c[11] c[15] v[3]
+//
+// Calling MultMatrix with an argument of m = m[0], m[1], ..., m[15]
+// replaces the current transformation with (C X M) x v, or
+//
+// c[0] c[4] c[8] c[12] m[0] m[4] m[8] m[12] v[0]
+// c[1] c[5] c[9] c[13] m[1] m[5] m[9] m[13] v[1]
+// c[2] c[6] c[10] c[14] X m[2] m[6] m[10] m[14] X v[2]
+// c[3] c[7] c[11] c[15] m[3] m[7] m[11] m[15] v[3]
+//
+// Where 'X' denotes matrix multiplication, and v is represented as a 4x1 matrix.
+//
+// While the elements of the matrix may be specified with single or double
+// precision, the GL may store or operate on these values in less-than-single
+// precision.
+//
+// In many computer languages, 4×4 arrays are represented in row-major
+// order. The transformations just described represent these matrices in
+// column-major order. The order of the multiplication is important. For
+// example, if the current transformation is a rotation, and MultMatrix is
+// called with a translation matrix, the translation is done directly on the
+// coordinates to be transformed, while the rotation is done on the results
+// of that translation.
+//
+// GL.INVALID_OPERATION is generated if MultMatrix is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) MultMatrixd(m []float64) {
+ if len(m) != 16 {
+ panic("parameter m must have length 16 for the 4x4 matrix")
+ }
+ C.gl3_0_glMultMatrixd(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&m[0])))
+}
+
+// MultMatrixf multiplies the current matrix with the provided matrix.
+//
+// The m parameter must hold 16 consecutive elements of a 4x4 column-major matrix.
+//
+// The current matrix is determined by the current matrix mode (see
+// MatrixMode). It is either the projection matrix, modelview matrix, or the
+// texture matrix.
+//
+// For example, if the current matrix is C and the coordinates to be transformed
+// are v = (v[0], v[1], v[2], v[3]), then the current transformation is C × v, or
+//
+// c[0] c[4] c[8] c[12] v[0]
+// c[1] c[5] c[9] c[13] v[1]
+// c[2] c[6] c[10] c[14] X v[2]
+// c[3] c[7] c[11] c[15] v[3]
+//
+// Calling MultMatrix with an argument of m = m[0], m[1], ..., m[15]
+// replaces the current transformation with (C X M) x v, or
+//
+// c[0] c[4] c[8] c[12] m[0] m[4] m[8] m[12] v[0]
+// c[1] c[5] c[9] c[13] m[1] m[5] m[9] m[13] v[1]
+// c[2] c[6] c[10] c[14] X m[2] m[6] m[10] m[14] X v[2]
+// c[3] c[7] c[11] c[15] m[3] m[7] m[11] m[15] v[3]
+//
+// Where 'X' denotes matrix multiplication, and v is represented as a 4x1 matrix.
+//
+// While the elements of the matrix may be specified with single or double
+// precision, the GL may store or operate on these values in less-than-single
+// precision.
+//
+// In many computer languages, 4×4 arrays are represented in row-major
+// order. The transformations just described represent these matrices in
+// column-major order. The order of the multiplication is important. For
+// example, if the current transformation is a rotation, and MultMatrix is
+// called with a translation matrix, the translation is done directly on the
+// coordinates to be transformed, while the rotation is done on the results
+// of that translation.
+//
+// GL.INVALID_OPERATION is generated if MultMatrix is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) MultMatrixf(m []float32) {
+ if len(m) != 16 {
+ panic("parameter m must have length 16 for the 4x4 matrix")
+ }
+ C.gl3_0_glMultMatrixf(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMatrixMode.xml
+func (gl *GL) MatrixMode(mode glbase.Enum) {
+ C.gl3_0_glMatrixMode(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glLoadMatrixd.xml
+func (gl *GL) LoadMatrixd(m []float64) {
+ C.gl3_0_glLoadMatrixd(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glLoadMatrixf.xml
+func (gl *GL) LoadMatrixf(m []float32) {
+ C.gl3_0_glLoadMatrixf(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glLoadIdentity.xml
+func (gl *GL) LoadIdentity() {
+ C.gl3_0_glLoadIdentity(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFrustum.xml
+func (gl *GL) Frustum(left, right, bottom, top, zNear, zFar float64) {
+ C.gl3_0_glFrustum(gl.funcs, C.GLdouble(left), C.GLdouble(right), C.GLdouble(bottom), C.GLdouble(top), C.GLdouble(zNear), C.GLdouble(zFar))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsList.xml
+func (gl *GL) IsList(list uint32) bool {
+ glresult := C.gl3_0_glIsList(gl.funcs, C.GLuint(list))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTexGeniv.xml
+func (gl *GL) GetTexGeniv(coord, pname glbase.Enum, params []int32) {
+ C.gl3_0_glGetTexGeniv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTexGenfv.xml
+func (gl *GL) GetTexGenfv(coord, pname glbase.Enum, params []float32) {
+ C.gl3_0_glGetTexGenfv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTexGendv.xml
+func (gl *GL) GetTexGendv(coord, pname glbase.Enum, params []float64) {
+ C.gl3_0_glGetTexGendv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTexEnviv.xml
+func (gl *GL) GetTexEnviv(target, pname glbase.Enum, params []int32) {
+ C.gl3_0_glGetTexEnviv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTexEnvfv.xml
+func (gl *GL) GetTexEnvfv(target, pname glbase.Enum, params []float32) {
+ C.gl3_0_glGetTexEnvfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetPolygonStipple.xml
+func (gl *GL) GetPolygonStipple(mask []uint8) {
+ C.gl3_0_glGetPolygonStipple(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&mask[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetPixelMapusv.xml
+func (gl *GL) GetPixelMapusv(glmap glbase.Enum, values []uint16) {
+ C.gl3_0_glGetPixelMapusv(gl.funcs, C.GLenum(glmap), (*C.GLushort)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetPixelMapuiv.xml
+func (gl *GL) GetPixelMapuiv(glmap glbase.Enum, values []uint32) {
+ C.gl3_0_glGetPixelMapuiv(gl.funcs, C.GLenum(glmap), (*C.GLuint)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetPixelMapfv.xml
+func (gl *GL) GetPixelMapfv(glmap glbase.Enum, values []float32) {
+ C.gl3_0_glGetPixelMapfv(gl.funcs, C.GLenum(glmap), (*C.GLfloat)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetMaterialiv.xml
+func (gl *GL) GetMaterialiv(face, pname glbase.Enum, params []int32) {
+ C.gl3_0_glGetMaterialiv(gl.funcs, C.GLenum(face), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetMaterialfv.xml
+func (gl *GL) GetMaterialfv(face, pname glbase.Enum, params []float32) {
+ C.gl3_0_glGetMaterialfv(gl.funcs, C.GLenum(face), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetMapiv.xml
+func (gl *GL) GetMapiv(target, query glbase.Enum, v []int32) {
+ C.gl3_0_glGetMapiv(gl.funcs, C.GLenum(target), C.GLenum(query), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetMapfv.xml
+func (gl *GL) GetMapfv(target, query glbase.Enum, v []float32) {
+ C.gl3_0_glGetMapfv(gl.funcs, C.GLenum(target), C.GLenum(query), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetMapdv.xml
+func (gl *GL) GetMapdv(target, query glbase.Enum, v []float64) {
+ C.gl3_0_glGetMapdv(gl.funcs, C.GLenum(target), C.GLenum(query), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetLightiv.xml
+func (gl *GL) GetLightiv(light, pname glbase.Enum, params []int32) {
+ C.gl3_0_glGetLightiv(gl.funcs, C.GLenum(light), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetLightfv.xml
+func (gl *GL) GetLightfv(light, pname glbase.Enum, params []float32) {
+ C.gl3_0_glGetLightfv(gl.funcs, C.GLenum(light), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetClipPlane.xml
+func (gl *GL) GetClipPlane(plane glbase.Enum, equation []float64) {
+ C.gl3_0_glGetClipPlane(gl.funcs, C.GLenum(plane), (*C.GLdouble)(unsafe.Pointer(&equation[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDrawPixels.xml
+func (gl *GL) DrawPixels(width, height int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_0_glDrawPixels(gl.funcs, C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCopyPixels.xml
+func (gl *GL) CopyPixels(x, y, width, height int, gltype glbase.Enum) {
+ C.gl3_0_glCopyPixels(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height), C.GLenum(gltype))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPixelMapusv.xml
+func (gl *GL) PixelMapusv(glmap glbase.Enum, mapsize int32, values []uint16) {
+ C.gl3_0_glPixelMapusv(gl.funcs, C.GLenum(glmap), C.GLint(mapsize), (*C.GLushort)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPixelMapuiv.xml
+func (gl *GL) PixelMapuiv(glmap glbase.Enum, mapsize int32, values []uint32) {
+ C.gl3_0_glPixelMapuiv(gl.funcs, C.GLenum(glmap), C.GLint(mapsize), (*C.GLuint)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPixelMapfv.xml
+func (gl *GL) PixelMapfv(glmap glbase.Enum, mapsize int32, values []float32) {
+ C.gl3_0_glPixelMapfv(gl.funcs, C.GLenum(glmap), C.GLint(mapsize), (*C.GLfloat)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPixelTransferi.xml
+func (gl *GL) PixelTransferi(pname glbase.Enum, param int32) {
+ C.gl3_0_glPixelTransferi(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPixelTransferf.xml
+func (gl *GL) PixelTransferf(pname glbase.Enum, param float32) {
+ C.gl3_0_glPixelTransferf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPixelZoom.xml
+func (gl *GL) PixelZoom(xfactor, yfactor float32) {
+ C.gl3_0_glPixelZoom(gl.funcs, C.GLfloat(xfactor), C.GLfloat(yfactor))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glAlphaFunc.xml
+func (gl *GL) AlphaFunc(glfunc glbase.Enum, ref float32) {
+ C.gl3_0_glAlphaFunc(gl.funcs, C.GLenum(glfunc), C.GLfloat(ref))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEvalPoint2.xml
+func (gl *GL) EvalPoint2(i, j int32) {
+ C.gl3_0_glEvalPoint2(gl.funcs, C.GLint(i), C.GLint(j))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEvalMesh2.xml
+func (gl *GL) EvalMesh2(mode glbase.Enum, i1, i2, j1, j2 int32) {
+ C.gl3_0_glEvalMesh2(gl.funcs, C.GLenum(mode), C.GLint(i1), C.GLint(i2), C.GLint(j1), C.GLint(j2))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEvalPoint1.xml
+func (gl *GL) EvalPoint1(i int32) {
+ C.gl3_0_glEvalPoint1(gl.funcs, C.GLint(i))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEvalMesh1.xml
+func (gl *GL) EvalMesh1(mode glbase.Enum, i1, i2 int32) {
+ C.gl3_0_glEvalMesh1(gl.funcs, C.GLenum(mode), C.GLint(i1), C.GLint(i2))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEvalCoord2fv.xml
+func (gl *GL) EvalCoord2fv(u []float32) {
+ if len(u) != 2 {
+ panic("parameter u has incorrect length")
+ }
+ C.gl3_0_glEvalCoord2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&u[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEvalCoord2f.xml
+func (gl *GL) EvalCoord2f(u, v float32) {
+ C.gl3_0_glEvalCoord2f(gl.funcs, C.GLfloat(u), C.GLfloat(v))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEvalCoord2dv.xml
+func (gl *GL) EvalCoord2dv(u []float64) {
+ if len(u) != 2 {
+ panic("parameter u has incorrect length")
+ }
+ C.gl3_0_glEvalCoord2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&u[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEvalCoord2d.xml
+func (gl *GL) EvalCoord2d(u, v float64) {
+ C.gl3_0_glEvalCoord2d(gl.funcs, C.GLdouble(u), C.GLdouble(v))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEvalCoord1fv.xml
+func (gl *GL) EvalCoord1fv(u []float32) {
+ C.gl3_0_glEvalCoord1fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&u[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEvalCoord1f.xml
+func (gl *GL) EvalCoord1f(u float32) {
+ C.gl3_0_glEvalCoord1f(gl.funcs, C.GLfloat(u))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEvalCoord1dv.xml
+func (gl *GL) EvalCoord1dv(u []float64) {
+ C.gl3_0_glEvalCoord1dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&u[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEvalCoord1d.xml
+func (gl *GL) EvalCoord1d(u float64) {
+ C.gl3_0_glEvalCoord1d(gl.funcs, C.GLdouble(u))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMapGrid2f.xml
+func (gl *GL) MapGrid2f(un int32, u1, u2 float32, vn int32, v1, v2 float32) {
+ C.gl3_0_glMapGrid2f(gl.funcs, C.GLint(un), C.GLfloat(u1), C.GLfloat(u2), C.GLint(vn), C.GLfloat(v1), C.GLfloat(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMapGrid2d.xml
+func (gl *GL) MapGrid2d(un int32, u1, u2 float64, vn int32, v1, v2 float64) {
+ C.gl3_0_glMapGrid2d(gl.funcs, C.GLint(un), C.GLdouble(u1), C.GLdouble(u2), C.GLint(vn), C.GLdouble(v1), C.GLdouble(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMapGrid1f.xml
+func (gl *GL) MapGrid1f(un int32, u1, u2 float32) {
+ C.gl3_0_glMapGrid1f(gl.funcs, C.GLint(un), C.GLfloat(u1), C.GLfloat(u2))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMapGrid1d.xml
+func (gl *GL) MapGrid1d(un int32, u1, u2 float64) {
+ C.gl3_0_glMapGrid1d(gl.funcs, C.GLint(un), C.GLdouble(u1), C.GLdouble(u2))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMap2f.xml
+func (gl *GL) Map2f(target glbase.Enum, u1, u2 float32, ustride, uorder int32, v1, v2 float32, vstride, vorder int32, points []float32) {
+ C.gl3_0_glMap2f(gl.funcs, C.GLenum(target), C.GLfloat(u1), C.GLfloat(u2), C.GLint(ustride), C.GLint(uorder), C.GLfloat(v1), C.GLfloat(v2), C.GLint(vstride), C.GLint(vorder), (*C.GLfloat)(unsafe.Pointer(&points[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMap2d.xml
+func (gl *GL) Map2d(target glbase.Enum, u1, u2 float64, ustride, uorder int32, v1, v2 float64, vstride, vorder int32, points []float64) {
+ C.gl3_0_glMap2d(gl.funcs, C.GLenum(target), C.GLdouble(u1), C.GLdouble(u2), C.GLint(ustride), C.GLint(uorder), C.GLdouble(v1), C.GLdouble(v2), C.GLint(vstride), C.GLint(vorder), (*C.GLdouble)(unsafe.Pointer(&points[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMap1f.xml
+func (gl *GL) Map1f(target glbase.Enum, u1, u2 float32, stride, order int, points []float32) {
+ C.gl3_0_glMap1f(gl.funcs, C.GLenum(target), C.GLfloat(u1), C.GLfloat(u2), C.GLint(stride), C.GLint(order), (*C.GLfloat)(unsafe.Pointer(&points[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMap1d.xml
+func (gl *GL) Map1d(target glbase.Enum, u1, u2 float64, stride, order int, points []float64) {
+ C.gl3_0_glMap1d(gl.funcs, C.GLenum(target), C.GLdouble(u1), C.GLdouble(u2), C.GLint(stride), C.GLint(order), (*C.GLdouble)(unsafe.Pointer(&points[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPushAttrib.xml
+func (gl *GL) PushAttrib(mask glbase.Bitfield) {
+ C.gl3_0_glPushAttrib(gl.funcs, C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPopAttrib.xml
+func (gl *GL) PopAttrib() {
+ C.gl3_0_glPopAttrib(gl.funcs)
+}
+
+// Accum executes an operation on the accumulation buffer.
+//
+// Parameter op defines the accumulation buffer operation (GL.ACCUM, GL.LOAD,
+// GL.ADD, GL.MULT, or GL.RETURN) and specifies how the value parameter is
+// used.
+//
+// The accumulation buffer is an extended-range color buffer. Images are not
+// rendered into it. Rather, images rendered into one of the color buffers
+// are added to the contents of the accumulation buffer after rendering.
+// Effects such as antialiasing (of points, lines, and polygons), motion
+// blur, and depth of field can be created by accumulating images generated
+// with different transformation matrices.
+//
+// Each pixel in the accumulation buffer consists of red, green, blue, and
+// alpha values. The number of bits per component in the accumulation buffer
+// depends on the implementation. You can examine this number by calling
+// GetIntegerv four times, with arguments GL.ACCUM_RED_BITS,
+// GL.ACCUM_GREEN_BITS, GL.ACCUM_BLUE_BITS, and GL.ACCUM_ALPHA_BITS.
+// Regardless of the number of bits per component, the range of values stored
+// by each component is (-1, 1). The accumulation buffer pixels are mapped
+// one-to-one with frame buffer pixels.
+//
+// All accumulation buffer operations are limited to the area of the current
+// scissor box and applied identically to the red, green, blue, and alpha
+// components of each pixel. If a Accum operation results in a value outside
+// the range (-1, 1), the contents of an accumulation buffer pixel component
+// are undefined.
+//
+// The operations are as follows:
+//
+// GL.ACCUM
+// Obtains R, G, B, and A values from the buffer currently selected for
+// reading (see ReadBuffer). Each component value is divided by 2 n -
+// 1 , where n is the number of bits allocated to each color component
+// in the currently selected buffer. The result is a floating-point
+// value in the range 0 1 , which is multiplied by value and added to
+// the corresponding pixel component in the accumulation buffer,
+// thereby updating the accumulation buffer.
+//
+// GL.LOAD
+// Similar to GL.ACCUM, except that the current value in the
+// accumulation buffer is not used in the calculation of the new value.
+// That is, the R, G, B, and A values from the currently selected
+// buffer are divided by 2 n - 1 , multiplied by value, and then stored
+// in the corresponding accumulation buffer cell, overwriting the
+// current value.
+//
+// GL.ADD
+// Adds value to each R, G, B, and A in the accumulation buffer.
+//
+// GL.MULT
+// Multiplies each R, G, B, and A in the accumulation buffer by value
+// and returns the scaled component to its corresponding accumulation
+// buffer location.
+//
+// GL.RETURN
+// Transfers accumulation buffer values to the color buffer or buffers
+// currently selected for writing. Each R, G, B, and A component is
+// multiplied by value, then multiplied by 2 n - 1 , clamped to the
+// range 0 2 n - 1 , and stored in the corresponding display buffer
+// cell. The only fragment operations that are applied to this transfer
+// are pixel ownership, scissor, dithering, and color writemasks.
+//
+// To clear the accumulation buffer, call ClearAccum with R, G, B, and A
+// values to set it to, then call Clear with the accumulation buffer
+// enabled.
+//
+// Error GL.INVALID_ENUM is generated if op is not an accepted value.
+// GL.INVALID_OPERATION is generated if there is no accumulation buffer.
+// GL.INVALID_OPERATION is generated if Accum is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) Accum(op glbase.Enum, value float32) {
+ C.gl3_0_glAccum(gl.funcs, C.GLenum(op), C.GLfloat(value))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIndexMask.xml
+func (gl *GL) IndexMask(mask uint32) {
+ C.gl3_0_glIndexMask(gl.funcs, C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClearIndex.xml
+func (gl *GL) ClearIndex(c float32) {
+ C.gl3_0_glClearIndex(gl.funcs, C.GLfloat(c))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClearAccum.xml
+func (gl *GL) ClearAccum(red, green, blue, alpha float32) {
+ C.gl3_0_glClearAccum(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPushName.xml
+func (gl *GL) PushName(name uint32) {
+ C.gl3_0_glPushName(gl.funcs, C.GLuint(name))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPopName.xml
+func (gl *GL) PopName() {
+ C.gl3_0_glPopName(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPassThrough.xml
+func (gl *GL) PassThrough(token float32) {
+ C.gl3_0_glPassThrough(gl.funcs, C.GLfloat(token))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glLoadName.xml
+func (gl *GL) LoadName(name uint32) {
+ C.gl3_0_glLoadName(gl.funcs, C.GLuint(name))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glInitNames.xml
+func (gl *GL) InitNames() {
+ C.gl3_0_glInitNames(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRenderMode.xml
+func (gl *GL) RenderMode(mode glbase.Enum) int32 {
+ glresult := C.gl3_0_glRenderMode(gl.funcs, C.GLenum(mode))
+ return int32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSelectBuffer.xml
+func (gl *GL) SelectBuffer(size int, buffer []glbase.Buffer) {
+ C.gl3_0_glSelectBuffer(gl.funcs, C.GLsizei(size), (*C.GLuint)(unsafe.Pointer(&buffer[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFeedbackBuffer.xml
+func (gl *GL) FeedbackBuffer(size int, gltype glbase.Enum, buffer []float32) {
+ C.gl3_0_glFeedbackBuffer(gl.funcs, C.GLsizei(size), C.GLenum(gltype), (*C.GLfloat)(unsafe.Pointer(&buffer[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexGeniv.xml
+func (gl *GL) TexGeniv(coord, pname glbase.Enum, params []int32) {
+ C.gl3_0_glTexGeniv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexGeni.xml
+func (gl *GL) TexGeni(coord, pname glbase.Enum, param int32) {
+ C.gl3_0_glTexGeni(gl.funcs, C.GLenum(coord), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexGenfv.xml
+func (gl *GL) TexGenfv(coord, pname glbase.Enum, params []float32) {
+ C.gl3_0_glTexGenfv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexGenf.xml
+func (gl *GL) TexGenf(coord, pname glbase.Enum, param float32) {
+ C.gl3_0_glTexGenf(gl.funcs, C.GLenum(coord), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexGendv.xml
+func (gl *GL) TexGendv(coord, pname glbase.Enum, params []float64) {
+ C.gl3_0_glTexGendv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexGend.xml
+func (gl *GL) TexGend(coord, pname glbase.Enum, param float64) {
+ C.gl3_0_glTexGend(gl.funcs, C.GLenum(coord), C.GLenum(pname), C.GLdouble(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexEnviv.xml
+func (gl *GL) TexEnviv(target, pname glbase.Enum, params []int32) {
+ C.gl3_0_glTexEnviv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexEnvi.xml
+func (gl *GL) TexEnvi(target, pname glbase.Enum, param int32) {
+ C.gl3_0_glTexEnvi(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexEnvfv.xml
+func (gl *GL) TexEnvfv(target, pname glbase.Enum, params []float32) {
+ C.gl3_0_glTexEnvfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexEnvf.xml
+func (gl *GL) TexEnvf(target, pname glbase.Enum, param float32) {
+ C.gl3_0_glTexEnvf(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glShadeModel.xml
+func (gl *GL) ShadeModel(mode glbase.Enum) {
+ C.gl3_0_glShadeModel(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPolygonStipple.xml
+func (gl *GL) PolygonStipple(mask []uint8) {
+ C.gl3_0_glPolygonStipple(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&mask[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMaterialiv.xml
+func (gl *GL) Materialiv(face, pname glbase.Enum, params []int32) {
+ C.gl3_0_glMaterialiv(gl.funcs, C.GLenum(face), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMateriali.xml
+func (gl *GL) Materiali(face, pname glbase.Enum, param int32) {
+ C.gl3_0_glMateriali(gl.funcs, C.GLenum(face), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMaterialfv.xml
+func (gl *GL) Materialfv(face, pname glbase.Enum, params []float32) {
+ C.gl3_0_glMaterialfv(gl.funcs, C.GLenum(face), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMaterialf.xml
+func (gl *GL) Materialf(face, pname glbase.Enum, param float32) {
+ C.gl3_0_glMaterialf(gl.funcs, C.GLenum(face), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glLineStipple.xml
+func (gl *GL) LineStipple(factor int32, pattern uint16) {
+ C.gl3_0_glLineStipple(gl.funcs, C.GLint(factor), C.GLushort(pattern))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glLightModeliv.xml
+func (gl *GL) LightModeliv(pname glbase.Enum, params []int32) {
+ C.gl3_0_glLightModeliv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glLightModeli.xml
+func (gl *GL) LightModeli(pname glbase.Enum, param int32) {
+ C.gl3_0_glLightModeli(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glLightModelfv.xml
+func (gl *GL) LightModelfv(pname glbase.Enum, params []float32) {
+ C.gl3_0_glLightModelfv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glLightModelf.xml
+func (gl *GL) LightModelf(pname glbase.Enum, param float32) {
+ C.gl3_0_glLightModelf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glLightiv.xml
+func (gl *GL) Lightiv(light, pname glbase.Enum, params []int32) {
+ C.gl3_0_glLightiv(gl.funcs, C.GLenum(light), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glLighti.xml
+func (gl *GL) Lighti(light, pname glbase.Enum, param int32) {
+ C.gl3_0_glLighti(gl.funcs, C.GLenum(light), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glLightfv.xml
+func (gl *GL) Lightfv(light, pname glbase.Enum, params []float32) {
+ C.gl3_0_glLightfv(gl.funcs, C.GLenum(light), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glLightf.xml
+func (gl *GL) Lightf(light, pname glbase.Enum, param float32) {
+ C.gl3_0_glLightf(gl.funcs, C.GLenum(light), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFogiv.xml
+func (gl *GL) Fogiv(pname glbase.Enum, params []int32) {
+ C.gl3_0_glFogiv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFogi.xml
+func (gl *GL) Fogi(pname glbase.Enum, param int32) {
+ C.gl3_0_glFogi(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFogfv.xml
+func (gl *GL) Fogfv(pname glbase.Enum, params []float32) {
+ C.gl3_0_glFogfv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFogf.xml
+func (gl *GL) Fogf(pname glbase.Enum, param float32) {
+ C.gl3_0_glFogf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColorMaterial.xml
+func (gl *GL) ColorMaterial(face, mode glbase.Enum) {
+ C.gl3_0_glColorMaterial(gl.funcs, C.GLenum(face), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClipPlane.xml
+func (gl *GL) ClipPlane(plane glbase.Enum, equation []float64) {
+ C.gl3_0_glClipPlane(gl.funcs, C.GLenum(plane), (*C.GLdouble)(unsafe.Pointer(&equation[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex4sv.xml
+func (gl *GL) Vertex4sv(v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glVertex4sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex4s.xml
+func (gl *GL) Vertex4s(x, y, z, w int16) {
+ C.gl3_0_glVertex4s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z), C.GLshort(w))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex4iv.xml
+func (gl *GL) Vertex4iv(v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glVertex4iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex4i.xml
+func (gl *GL) Vertex4i(x, y, z, w int) {
+ C.gl3_0_glVertex4i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z), C.GLint(w))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex4fv.xml
+func (gl *GL) Vertex4fv(v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glVertex4fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex4f.xml
+func (gl *GL) Vertex4f(x, y, z, w float32) {
+ C.gl3_0_glVertex4f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z), C.GLfloat(w))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex4dv.xml
+func (gl *GL) Vertex4dv(v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glVertex4dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex4d.xml
+func (gl *GL) Vertex4d(x, y, z, w float64) {
+ C.gl3_0_glVertex4d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z), C.GLdouble(w))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex3sv.xml
+func (gl *GL) Vertex3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glVertex3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex3s.xml
+func (gl *GL) Vertex3s(x, y, z int16) {
+ C.gl3_0_glVertex3s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex3iv.xml
+func (gl *GL) Vertex3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glVertex3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex3i.xml
+func (gl *GL) Vertex3i(x, y, z int) {
+ C.gl3_0_glVertex3i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex3fv.xml
+func (gl *GL) Vertex3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glVertex3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex3f.xml
+func (gl *GL) Vertex3f(x, y, z float32) {
+ C.gl3_0_glVertex3f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex3dv.xml
+func (gl *GL) Vertex3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glVertex3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex3d.xml
+func (gl *GL) Vertex3d(x, y, z float64) {
+ C.gl3_0_glVertex3d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex2sv.xml
+func (gl *GL) Vertex2sv(v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glVertex2sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex2s.xml
+func (gl *GL) Vertex2s(x, y int16) {
+ C.gl3_0_glVertex2s(gl.funcs, C.GLshort(x), C.GLshort(y))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex2iv.xml
+func (gl *GL) Vertex2iv(v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glVertex2iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex2i.xml
+func (gl *GL) Vertex2i(x, y int) {
+ C.gl3_0_glVertex2i(gl.funcs, C.GLint(x), C.GLint(y))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex2fv.xml
+func (gl *GL) Vertex2fv(v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glVertex2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex2f.xml
+func (gl *GL) Vertex2f(x, y float32) {
+ C.gl3_0_glVertex2f(gl.funcs, C.GLfloat(x), C.GLfloat(y))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex2dv.xml
+func (gl *GL) Vertex2dv(v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glVertex2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex2d.xml
+func (gl *GL) Vertex2d(x, y float64) {
+ C.gl3_0_glVertex2d(gl.funcs, C.GLdouble(x), C.GLdouble(y))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord4sv.xml
+func (gl *GL) TexCoord4sv(v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glTexCoord4sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord4s.xml
+func (gl *GL) TexCoord4s(s, t, r, q int16) {
+ C.gl3_0_glTexCoord4s(gl.funcs, C.GLshort(s), C.GLshort(t), C.GLshort(r), C.GLshort(q))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord4iv.xml
+func (gl *GL) TexCoord4iv(v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glTexCoord4iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord4i.xml
+func (gl *GL) TexCoord4i(s, t, r, q int32) {
+ C.gl3_0_glTexCoord4i(gl.funcs, C.GLint(s), C.GLint(t), C.GLint(r), C.GLint(q))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord4fv.xml
+func (gl *GL) TexCoord4fv(v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glTexCoord4fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord4f.xml
+func (gl *GL) TexCoord4f(s, t, r, q float32) {
+ C.gl3_0_glTexCoord4f(gl.funcs, C.GLfloat(s), C.GLfloat(t), C.GLfloat(r), C.GLfloat(q))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord4dv.xml
+func (gl *GL) TexCoord4dv(v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glTexCoord4dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord4d.xml
+func (gl *GL) TexCoord4d(s, t, r, q float64) {
+ C.gl3_0_glTexCoord4d(gl.funcs, C.GLdouble(s), C.GLdouble(t), C.GLdouble(r), C.GLdouble(q))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord3sv.xml
+func (gl *GL) TexCoord3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glTexCoord3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord3s.xml
+func (gl *GL) TexCoord3s(s, t, r int16) {
+ C.gl3_0_glTexCoord3s(gl.funcs, C.GLshort(s), C.GLshort(t), C.GLshort(r))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord3iv.xml
+func (gl *GL) TexCoord3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glTexCoord3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord3i.xml
+func (gl *GL) TexCoord3i(s, t, r int32) {
+ C.gl3_0_glTexCoord3i(gl.funcs, C.GLint(s), C.GLint(t), C.GLint(r))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord3fv.xml
+func (gl *GL) TexCoord3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glTexCoord3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord3f.xml
+func (gl *GL) TexCoord3f(s, t, r float32) {
+ C.gl3_0_glTexCoord3f(gl.funcs, C.GLfloat(s), C.GLfloat(t), C.GLfloat(r))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord3dv.xml
+func (gl *GL) TexCoord3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glTexCoord3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord3d.xml
+func (gl *GL) TexCoord3d(s, t, r float64) {
+ C.gl3_0_glTexCoord3d(gl.funcs, C.GLdouble(s), C.GLdouble(t), C.GLdouble(r))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord2sv.xml
+func (gl *GL) TexCoord2sv(v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glTexCoord2sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord2s.xml
+func (gl *GL) TexCoord2s(s, t int16) {
+ C.gl3_0_glTexCoord2s(gl.funcs, C.GLshort(s), C.GLshort(t))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord2iv.xml
+func (gl *GL) TexCoord2iv(v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glTexCoord2iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord2i.xml
+func (gl *GL) TexCoord2i(s, t int32) {
+ C.gl3_0_glTexCoord2i(gl.funcs, C.GLint(s), C.GLint(t))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord2fv.xml
+func (gl *GL) TexCoord2fv(v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glTexCoord2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord2f.xml
+func (gl *GL) TexCoord2f(s, t float32) {
+ C.gl3_0_glTexCoord2f(gl.funcs, C.GLfloat(s), C.GLfloat(t))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord2dv.xml
+func (gl *GL) TexCoord2dv(v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glTexCoord2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord2d.xml
+func (gl *GL) TexCoord2d(s, t float64) {
+ C.gl3_0_glTexCoord2d(gl.funcs, C.GLdouble(s), C.GLdouble(t))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord1sv.xml
+func (gl *GL) TexCoord1sv(v []int16) {
+ C.gl3_0_glTexCoord1sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord1s.xml
+func (gl *GL) TexCoord1s(s int16) {
+ C.gl3_0_glTexCoord1s(gl.funcs, C.GLshort(s))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord1iv.xml
+func (gl *GL) TexCoord1iv(v []int32) {
+ C.gl3_0_glTexCoord1iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord1i.xml
+func (gl *GL) TexCoord1i(s int32) {
+ C.gl3_0_glTexCoord1i(gl.funcs, C.GLint(s))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord1fv.xml
+func (gl *GL) TexCoord1fv(v []float32) {
+ C.gl3_0_glTexCoord1fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord1f.xml
+func (gl *GL) TexCoord1f(s float32) {
+ C.gl3_0_glTexCoord1f(gl.funcs, C.GLfloat(s))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord1dv.xml
+func (gl *GL) TexCoord1dv(v []float64) {
+ C.gl3_0_glTexCoord1dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord1d.xml
+func (gl *GL) TexCoord1d(s float64) {
+ C.gl3_0_glTexCoord1d(gl.funcs, C.GLdouble(s))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRectsv.xml
+func (gl *GL) Rectsv(v1, v2 []int16) {
+ C.gl3_0_glRectsv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v1[0])), (*C.GLshort)(unsafe.Pointer(&v2[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRects.xml
+func (gl *GL) Rects(x1, y1, x2, y2 int16) {
+ C.gl3_0_glRects(gl.funcs, C.GLshort(x1), C.GLshort(y1), C.GLshort(x2), C.GLshort(y2))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRectiv.xml
+func (gl *GL) Rectiv(v1, v2 []int32) {
+ C.gl3_0_glRectiv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v1[0])), (*C.GLint)(unsafe.Pointer(&v2[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRecti.xml
+func (gl *GL) Recti(x1, y1, x2, y2 int32) {
+ C.gl3_0_glRecti(gl.funcs, C.GLint(x1), C.GLint(y1), C.GLint(x2), C.GLint(y2))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRectfv.xml
+func (gl *GL) Rectfv(v1, v2 []float32) {
+ C.gl3_0_glRectfv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v1[0])), (*C.GLfloat)(unsafe.Pointer(&v2[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRectf.xml
+func (gl *GL) Rectf(x1, y1, x2, y2 float32) {
+ C.gl3_0_glRectf(gl.funcs, C.GLfloat(x1), C.GLfloat(y1), C.GLfloat(x2), C.GLfloat(y2))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRectdv.xml
+func (gl *GL) Rectdv(v1, v2 []float64) {
+ C.gl3_0_glRectdv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v1[0])), (*C.GLdouble)(unsafe.Pointer(&v2[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRectd.xml
+func (gl *GL) Rectd(x1, y1, x2, y2 float64) {
+ C.gl3_0_glRectd(gl.funcs, C.GLdouble(x1), C.GLdouble(y1), C.GLdouble(x2), C.GLdouble(y2))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos4sv.xml
+func (gl *GL) RasterPos4sv(v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glRasterPos4sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos4s.xml
+func (gl *GL) RasterPos4s(x, y, z, w int16) {
+ C.gl3_0_glRasterPos4s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z), C.GLshort(w))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos4iv.xml
+func (gl *GL) RasterPos4iv(v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glRasterPos4iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos4i.xml
+func (gl *GL) RasterPos4i(x, y, z, w int) {
+ C.gl3_0_glRasterPos4i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z), C.GLint(w))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos4fv.xml
+func (gl *GL) RasterPos4fv(v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glRasterPos4fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos4f.xml
+func (gl *GL) RasterPos4f(x, y, z, w float32) {
+ C.gl3_0_glRasterPos4f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z), C.GLfloat(w))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos4dv.xml
+func (gl *GL) RasterPos4dv(v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glRasterPos4dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos4d.xml
+func (gl *GL) RasterPos4d(x, y, z, w float64) {
+ C.gl3_0_glRasterPos4d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z), C.GLdouble(w))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos3sv.xml
+func (gl *GL) RasterPos3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glRasterPos3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos3s.xml
+func (gl *GL) RasterPos3s(x, y, z int16) {
+ C.gl3_0_glRasterPos3s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos3iv.xml
+func (gl *GL) RasterPos3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glRasterPos3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos3i.xml
+func (gl *GL) RasterPos3i(x, y, z int) {
+ C.gl3_0_glRasterPos3i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos3fv.xml
+func (gl *GL) RasterPos3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glRasterPos3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos3f.xml
+func (gl *GL) RasterPos3f(x, y, z float32) {
+ C.gl3_0_glRasterPos3f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos3dv.xml
+func (gl *GL) RasterPos3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glRasterPos3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos3d.xml
+func (gl *GL) RasterPos3d(x, y, z float64) {
+ C.gl3_0_glRasterPos3d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos2sv.xml
+func (gl *GL) RasterPos2sv(v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glRasterPos2sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos2s.xml
+func (gl *GL) RasterPos2s(x, y int16) {
+ C.gl3_0_glRasterPos2s(gl.funcs, C.GLshort(x), C.GLshort(y))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos2iv.xml
+func (gl *GL) RasterPos2iv(v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glRasterPos2iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos2i.xml
+func (gl *GL) RasterPos2i(x, y int) {
+ C.gl3_0_glRasterPos2i(gl.funcs, C.GLint(x), C.GLint(y))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos2fv.xml
+func (gl *GL) RasterPos2fv(v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glRasterPos2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos2f.xml
+func (gl *GL) RasterPos2f(x, y float32) {
+ C.gl3_0_glRasterPos2f(gl.funcs, C.GLfloat(x), C.GLfloat(y))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos2dv.xml
+func (gl *GL) RasterPos2dv(v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glRasterPos2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos2d.xml
+func (gl *GL) RasterPos2d(x, y float64) {
+ C.gl3_0_glRasterPos2d(gl.funcs, C.GLdouble(x), C.GLdouble(y))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glNormal3sv.xml
+func (gl *GL) Normal3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glNormal3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glNormal3s.xml
+func (gl *GL) Normal3s(nx, ny, nz int16) {
+ C.gl3_0_glNormal3s(gl.funcs, C.GLshort(nx), C.GLshort(ny), C.GLshort(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glNormal3iv.xml
+func (gl *GL) Normal3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glNormal3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glNormal3i.xml
+func (gl *GL) Normal3i(nx, ny, nz int32) {
+ C.gl3_0_glNormal3i(gl.funcs, C.GLint(nx), C.GLint(ny), C.GLint(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glNormal3fv.xml
+func (gl *GL) Normal3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glNormal3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glNormal3f.xml
+func (gl *GL) Normal3f(nx, ny, nz float32) {
+ C.gl3_0_glNormal3f(gl.funcs, C.GLfloat(nx), C.GLfloat(ny), C.GLfloat(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glNormal3dv.xml
+func (gl *GL) Normal3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glNormal3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glNormal3d.xml
+func (gl *GL) Normal3d(nx, ny, nz float64) {
+ C.gl3_0_glNormal3d(gl.funcs, C.GLdouble(nx), C.GLdouble(ny), C.GLdouble(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glNormal3bv.xml
+func (gl *GL) Normal3bv(v []byte) {
+ C.gl3_0_glNormal3bv(gl.funcs, (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glNormal3b.xml
+func (gl *GL) Normal3b(nx, ny, nz byte) {
+ C.gl3_0_glNormal3b(gl.funcs, C.GLbyte(nx), C.GLbyte(ny), C.GLbyte(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIndexsv.xml
+func (gl *GL) Indexsv(c []int16) {
+ C.gl3_0_glIndexsv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIndexs.xml
+func (gl *GL) Indexs(c int16) {
+ C.gl3_0_glIndexs(gl.funcs, C.GLshort(c))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIndexiv.xml
+func (gl *GL) Indexiv(c []int32) {
+ C.gl3_0_glIndexiv(gl.funcs, (*C.GLint)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIndexi.xml
+func (gl *GL) Indexi(c int32) {
+ C.gl3_0_glIndexi(gl.funcs, C.GLint(c))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIndexfv.xml
+func (gl *GL) Indexfv(c []float32) {
+ C.gl3_0_glIndexfv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIndexf.xml
+func (gl *GL) Indexf(c float32) {
+ C.gl3_0_glIndexf(gl.funcs, C.GLfloat(c))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIndexdv.xml
+func (gl *GL) Indexdv(c []float64) {
+ C.gl3_0_glIndexdv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIndexd.xml
+func (gl *GL) Indexd(c float64) {
+ C.gl3_0_glIndexd(gl.funcs, C.GLdouble(c))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEnd.xml
+func (gl *GL) End() {
+ C.gl3_0_glEnd(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEdgeFlagv.xml
+func (gl *GL) EdgeFlagv(flag []bool) {
+ C.gl3_0_glEdgeFlagv(gl.funcs, (*C.GLboolean)(unsafe.Pointer(&flag[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEdgeFlag.xml
+func (gl *GL) EdgeFlag(flag bool) {
+ C.gl3_0_glEdgeFlag(gl.funcs, *(*C.GLboolean)(unsafe.Pointer(&flag)))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor4usv.xml
+func (gl *GL) Color4usv(v []uint16) {
+ C.gl3_0_glColor4usv(gl.funcs, (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor4us.xml
+func (gl *GL) Color4us(red, green, blue, alpha uint16) {
+ C.gl3_0_glColor4us(gl.funcs, C.GLushort(red), C.GLushort(green), C.GLushort(blue), C.GLushort(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor4uiv.xml
+func (gl *GL) Color4uiv(v []uint32) {
+ C.gl3_0_glColor4uiv(gl.funcs, (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor4ui.xml
+func (gl *GL) Color4ui(red, green, blue, alpha uint32) {
+ C.gl3_0_glColor4ui(gl.funcs, C.GLuint(red), C.GLuint(green), C.GLuint(blue), C.GLuint(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor4ubv.xml
+func (gl *GL) Color4ubv(v []uint8) {
+ C.gl3_0_glColor4ubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor4ub.xml
+func (gl *GL) Color4ub(red, green, blue, alpha uint8) {
+ C.gl3_0_glColor4ub(gl.funcs, C.GLubyte(red), C.GLubyte(green), C.GLubyte(blue), C.GLubyte(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor4sv.xml
+func (gl *GL) Color4sv(v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glColor4sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor4s.xml
+func (gl *GL) Color4s(red, green, blue, alpha int16) {
+ C.gl3_0_glColor4s(gl.funcs, C.GLshort(red), C.GLshort(green), C.GLshort(blue), C.GLshort(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor4iv.xml
+func (gl *GL) Color4iv(v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glColor4iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor4i.xml
+func (gl *GL) Color4i(red, green, blue, alpha int32) {
+ C.gl3_0_glColor4i(gl.funcs, C.GLint(red), C.GLint(green), C.GLint(blue), C.GLint(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor4fv.xml
+func (gl *GL) Color4fv(v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glColor4fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor4f.xml
+func (gl *GL) Color4f(red, green, blue, alpha float32) {
+ C.gl3_0_glColor4f(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor4dv.xml
+func (gl *GL) Color4dv(v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glColor4dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor4d.xml
+func (gl *GL) Color4d(red, green, blue, alpha float64) {
+ C.gl3_0_glColor4d(gl.funcs, C.GLdouble(red), C.GLdouble(green), C.GLdouble(blue), C.GLdouble(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor4bv.xml
+func (gl *GL) Color4bv(v []byte) {
+ C.gl3_0_glColor4bv(gl.funcs, (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor4b.xml
+func (gl *GL) Color4b(red, green, blue, alpha byte) {
+ C.gl3_0_glColor4b(gl.funcs, C.GLbyte(red), C.GLbyte(green), C.GLbyte(blue), C.GLbyte(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor3usv.xml
+func (gl *GL) Color3usv(v []uint16) {
+ C.gl3_0_glColor3usv(gl.funcs, (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor3us.xml
+func (gl *GL) Color3us(red, green, blue uint16) {
+ C.gl3_0_glColor3us(gl.funcs, C.GLushort(red), C.GLushort(green), C.GLushort(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor3uiv.xml
+func (gl *GL) Color3uiv(v []uint32) {
+ C.gl3_0_glColor3uiv(gl.funcs, (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor3ui.xml
+func (gl *GL) Color3ui(red, green, blue uint32) {
+ C.gl3_0_glColor3ui(gl.funcs, C.GLuint(red), C.GLuint(green), C.GLuint(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor3ubv.xml
+func (gl *GL) Color3ubv(v []uint8) {
+ C.gl3_0_glColor3ubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor3ub.xml
+func (gl *GL) Color3ub(red, green, blue uint8) {
+ C.gl3_0_glColor3ub(gl.funcs, C.GLubyte(red), C.GLubyte(green), C.GLubyte(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor3sv.xml
+func (gl *GL) Color3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glColor3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor3s.xml
+func (gl *GL) Color3s(red, green, blue int16) {
+ C.gl3_0_glColor3s(gl.funcs, C.GLshort(red), C.GLshort(green), C.GLshort(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor3iv.xml
+func (gl *GL) Color3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glColor3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor3i.xml
+func (gl *GL) Color3i(red, green, blue int32) {
+ C.gl3_0_glColor3i(gl.funcs, C.GLint(red), C.GLint(green), C.GLint(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor3fv.xml
+func (gl *GL) Color3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glColor3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor3f.xml
+func (gl *GL) Color3f(red, green, blue float32) {
+ C.gl3_0_glColor3f(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor3dv.xml
+func (gl *GL) Color3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glColor3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor3d.xml
+func (gl *GL) Color3d(red, green, blue float64) {
+ C.gl3_0_glColor3d(gl.funcs, C.GLdouble(red), C.GLdouble(green), C.GLdouble(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor3bv.xml
+func (gl *GL) Color3bv(v []byte) {
+ C.gl3_0_glColor3bv(gl.funcs, (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor3b.xml
+func (gl *GL) Color3b(red, green, blue byte) {
+ C.gl3_0_glColor3b(gl.funcs, C.GLbyte(red), C.GLbyte(green), C.GLbyte(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBitmap.xml
+func (gl *GL) Bitmap(width, height int, xorig, yorig, xmove, ymove float32, bitmap []uint8) {
+ C.gl3_0_glBitmap(gl.funcs, C.GLsizei(width), C.GLsizei(height), C.GLfloat(xorig), C.GLfloat(yorig), C.GLfloat(xmove), C.GLfloat(ymove), (*C.GLubyte)(unsafe.Pointer(&bitmap[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBegin.xml
+func (gl *GL) Begin(mode glbase.Enum) {
+ C.gl3_0_glBegin(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glListBase.xml
+func (gl *GL) ListBase(base uint32) {
+ C.gl3_0_glListBase(gl.funcs, C.GLuint(base))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGenLists.xml
+func (gl *GL) GenLists(range_ int32) uint32 {
+ glresult := C.gl3_0_glGenLists(gl.funcs, C.GLsizei(range_))
+ return uint32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDeleteLists.xml
+func (gl *GL) DeleteLists(list uint32, range_ int32) {
+ C.gl3_0_glDeleteLists(gl.funcs, C.GLuint(list), C.GLsizei(range_))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCallLists.xml
+func (gl *GL) CallLists(n int, gltype glbase.Enum, lists interface{}) {
+ var lists_ptr unsafe.Pointer
+ var lists_v = reflect.ValueOf(lists)
+ if lists != nil && lists_v.Kind() != reflect.Slice {
+ panic("parameter lists must be a slice")
+ }
+ if lists != nil {
+ lists_ptr = unsafe.Pointer(lists_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_0_glCallLists(gl.funcs, C.GLsizei(n), C.GLenum(gltype), lists_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCallList.xml
+func (gl *GL) CallList(list uint32) {
+ C.gl3_0_glCallList(gl.funcs, C.GLuint(list))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEndList.xml
+func (gl *GL) EndList() {
+ C.gl3_0_glEndList(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glNewList.xml
+func (gl *GL) NewList(list uint32, mode glbase.Enum) {
+ C.gl3_0_glNewList(gl.funcs, C.GLuint(list), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPushClientAttrib.xml
+func (gl *GL) PushClientAttrib(mask glbase.Bitfield) {
+ C.gl3_0_glPushClientAttrib(gl.funcs, C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPopClientAttrib.xml
+func (gl *GL) PopClientAttrib() {
+ C.gl3_0_glPopClientAttrib(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPrioritizeTextures.xml
+func (gl *GL) PrioritizeTextures(n int, textures []glbase.Texture, priorities []float32) {
+ C.gl3_0_glPrioritizeTextures(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])), (*C.GLfloat)(unsafe.Pointer(&priorities[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glAreTexturesResident.xml
+func (gl *GL) AreTexturesResident(n int, textures []glbase.Texture, residences []bool) bool {
+ glresult := C.gl3_0_glAreTexturesResident(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])), (*C.GLboolean)(unsafe.Pointer(&residences[0])))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexPointer.xml
+func (gl *GL) VertexPointer(size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_0_glVertexPointer(gl.funcs, C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoordPointer.xml
+func (gl *GL) TexCoordPointer(size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_0_glTexCoordPointer(gl.funcs, C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glNormalPointer.xml
+func (gl *GL) NormalPointer(gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_0_glNormalPointer(gl.funcs, C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glInterleavedArrays.xml
+func (gl *GL) InterleavedArrays(format glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_0_glInterleavedArrays(gl.funcs, C.GLenum(format), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIndexPointer.xml
+func (gl *GL) IndexPointer(gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_0_glIndexPointer(gl.funcs, C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEnableClientState.xml
+func (gl *GL) EnableClientState(array glbase.Enum) {
+ C.gl3_0_glEnableClientState(gl.funcs, C.GLenum(array))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEdgeFlagPointer.xml
+func (gl *GL) EdgeFlagPointer(stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_0_glEdgeFlagPointer(gl.funcs, C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDisableClientState.xml
+func (gl *GL) DisableClientState(array glbase.Enum) {
+ C.gl3_0_glDisableClientState(gl.funcs, C.GLenum(array))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColorPointer.xml
+func (gl *GL) ColorPointer(size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_0_glColorPointer(gl.funcs, C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glArrayElement.xml
+func (gl *GL) ArrayElement(i int32) {
+ C.gl3_0_glArrayElement(gl.funcs, C.GLint(i))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glResetMinmax.xml
+func (gl *GL) ResetMinmax(target glbase.Enum) {
+ C.gl3_0_glResetMinmax(gl.funcs, C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glResetHistogram.xml
+func (gl *GL) ResetHistogram(target glbase.Enum) {
+ C.gl3_0_glResetHistogram(gl.funcs, C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMinmax.xml
+func (gl *GL) Minmax(target, internalFormat glbase.Enum, sink bool) {
+ C.gl3_0_glMinmax(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), *(*C.GLboolean)(unsafe.Pointer(&sink)))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glHistogram.xml
+func (gl *GL) Histogram(target glbase.Enum, width int, internalFormat glbase.Enum, sink bool) {
+ C.gl3_0_glHistogram(gl.funcs, C.GLenum(target), C.GLsizei(width), C.GLenum(internalFormat), *(*C.GLboolean)(unsafe.Pointer(&sink)))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetMinmaxParameteriv.xml
+func (gl *GL) GetMinmaxParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl3_0_glGetMinmaxParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetMinmaxParameterfv.xml
+func (gl *GL) GetMinmaxParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl3_0_glGetMinmaxParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetMinmax.xml
+func (gl *GL) GetMinmax(target glbase.Enum, reset bool, format, gltype glbase.Enum, values interface{}) {
+ var values_ptr unsafe.Pointer
+ var values_v = reflect.ValueOf(values)
+ if values != nil && values_v.Kind() != reflect.Slice {
+ panic("parameter values must be a slice")
+ }
+ if values != nil {
+ values_ptr = unsafe.Pointer(values_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_0_glGetMinmax(gl.funcs, C.GLenum(target), *(*C.GLboolean)(unsafe.Pointer(&reset)), C.GLenum(format), C.GLenum(gltype), values_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetHistogramParameteriv.xml
+func (gl *GL) GetHistogramParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl3_0_glGetHistogramParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetHistogramParameterfv.xml
+func (gl *GL) GetHistogramParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl3_0_glGetHistogramParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetHistogram.xml
+func (gl *GL) GetHistogram(target glbase.Enum, reset bool, format, gltype glbase.Enum, values interface{}) {
+ var values_ptr unsafe.Pointer
+ var values_v = reflect.ValueOf(values)
+ if values != nil && values_v.Kind() != reflect.Slice {
+ panic("parameter values must be a slice")
+ }
+ if values != nil {
+ values_ptr = unsafe.Pointer(values_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_0_glGetHistogram(gl.funcs, C.GLenum(target), *(*C.GLboolean)(unsafe.Pointer(&reset)), C.GLenum(format), C.GLenum(gltype), values_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSeparableFilter2D.xml
+func (gl *GL) SeparableFilter2D(target, internalFormat glbase.Enum, width, height int, format, gltype glbase.Enum, row, column interface{}) {
+ var row_ptr unsafe.Pointer
+ var row_v = reflect.ValueOf(row)
+ if row != nil && row_v.Kind() != reflect.Slice {
+ panic("parameter row must be a slice")
+ }
+ if row != nil {
+ row_ptr = unsafe.Pointer(row_v.Index(0).Addr().Pointer())
+ }
+ var column_ptr unsafe.Pointer
+ var column_v = reflect.ValueOf(column)
+ if column != nil && column_v.Kind() != reflect.Slice {
+ panic("parameter column must be a slice")
+ }
+ if column != nil {
+ column_ptr = unsafe.Pointer(column_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_0_glSeparableFilter2D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), row_ptr, column_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetSeparableFilter.xml
+func (gl *GL) GetSeparableFilter(target, format, gltype glbase.Enum, row, column, span interface{}) {
+ var row_ptr unsafe.Pointer
+ var row_v = reflect.ValueOf(row)
+ if row != nil && row_v.Kind() != reflect.Slice {
+ panic("parameter row must be a slice")
+ }
+ if row != nil {
+ row_ptr = unsafe.Pointer(row_v.Index(0).Addr().Pointer())
+ }
+ var column_ptr unsafe.Pointer
+ var column_v = reflect.ValueOf(column)
+ if column != nil && column_v.Kind() != reflect.Slice {
+ panic("parameter column must be a slice")
+ }
+ if column != nil {
+ column_ptr = unsafe.Pointer(column_v.Index(0).Addr().Pointer())
+ }
+ var span_ptr unsafe.Pointer
+ var span_v = reflect.ValueOf(span)
+ if span != nil && span_v.Kind() != reflect.Slice {
+ panic("parameter span must be a slice")
+ }
+ if span != nil {
+ span_ptr = unsafe.Pointer(span_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_0_glGetSeparableFilter(gl.funcs, C.GLenum(target), C.GLenum(format), C.GLenum(gltype), row_ptr, column_ptr, span_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetConvolutionParameteriv.xml
+func (gl *GL) GetConvolutionParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl3_0_glGetConvolutionParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetConvolutionParameterfv.xml
+func (gl *GL) GetConvolutionParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl3_0_glGetConvolutionParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetConvolutionFilter.xml
+func (gl *GL) GetConvolutionFilter(target, format, gltype glbase.Enum, image interface{}) {
+ var image_ptr unsafe.Pointer
+ var image_v = reflect.ValueOf(image)
+ if image != nil && image_v.Kind() != reflect.Slice {
+ panic("parameter image must be a slice")
+ }
+ if image != nil {
+ image_ptr = unsafe.Pointer(image_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_0_glGetConvolutionFilter(gl.funcs, C.GLenum(target), C.GLenum(format), C.GLenum(gltype), image_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCopyConvolutionFilter2D.xml
+func (gl *GL) CopyConvolutionFilter2D(target, internalFormat glbase.Enum, x, y, width, height int) {
+ C.gl3_0_glCopyConvolutionFilter2D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCopyConvolutionFilter1D.xml
+func (gl *GL) CopyConvolutionFilter1D(target, internalFormat glbase.Enum, x, y, width int) {
+ C.gl3_0_glCopyConvolutionFilter1D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glConvolutionParameteriv.xml
+func (gl *GL) ConvolutionParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl3_0_glConvolutionParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glConvolutionParameteri.xml
+func (gl *GL) ConvolutionParameteri(target, pname glbase.Enum, params int32) {
+ C.gl3_0_glConvolutionParameteri(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLint(params))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glConvolutionParameterfv.xml
+func (gl *GL) ConvolutionParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl3_0_glConvolutionParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glConvolutionParameterf.xml
+func (gl *GL) ConvolutionParameterf(target, pname glbase.Enum, params float32) {
+ C.gl3_0_glConvolutionParameterf(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLfloat(params))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glConvolutionFilter2D.xml
+func (gl *GL) ConvolutionFilter2D(target, internalFormat glbase.Enum, width, height int, format, gltype glbase.Enum, image interface{}) {
+ var image_ptr unsafe.Pointer
+ var image_v = reflect.ValueOf(image)
+ if image != nil && image_v.Kind() != reflect.Slice {
+ panic("parameter image must be a slice")
+ }
+ if image != nil {
+ image_ptr = unsafe.Pointer(image_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_0_glConvolutionFilter2D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), image_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glConvolutionFilter1D.xml
+func (gl *GL) ConvolutionFilter1D(target, internalFormat glbase.Enum, width int, format, gltype glbase.Enum, image interface{}) {
+ var image_ptr unsafe.Pointer
+ var image_v = reflect.ValueOf(image)
+ if image != nil && image_v.Kind() != reflect.Slice {
+ panic("parameter image must be a slice")
+ }
+ if image != nil {
+ image_ptr = unsafe.Pointer(image_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_0_glConvolutionFilter1D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLenum(format), C.GLenum(gltype), image_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCopyColorSubTable.xml
+func (gl *GL) CopyColorSubTable(target glbase.Enum, start int32, x, y, width int) {
+ C.gl3_0_glCopyColorSubTable(gl.funcs, C.GLenum(target), C.GLsizei(start), C.GLint(x), C.GLint(y), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColorSubTable.xml
+func (gl *GL) ColorSubTable(target glbase.Enum, start int32, count int, format, gltype glbase.Enum, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_0_glColorSubTable(gl.funcs, C.GLenum(target), C.GLsizei(start), C.GLsizei(count), C.GLenum(format), C.GLenum(gltype), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetColorTableParameteriv.xml
+func (gl *GL) GetColorTableParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl3_0_glGetColorTableParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetColorTableParameterfv.xml
+func (gl *GL) GetColorTableParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl3_0_glGetColorTableParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetColorTable.xml
+func (gl *GL) GetColorTable(target, format, gltype glbase.Enum, table interface{}) {
+ var table_ptr unsafe.Pointer
+ var table_v = reflect.ValueOf(table)
+ if table != nil && table_v.Kind() != reflect.Slice {
+ panic("parameter table must be a slice")
+ }
+ if table != nil {
+ table_ptr = unsafe.Pointer(table_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_0_glGetColorTable(gl.funcs, C.GLenum(target), C.GLenum(format), C.GLenum(gltype), table_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCopyColorTable.xml
+func (gl *GL) CopyColorTable(target, internalFormat glbase.Enum, x, y, width int) {
+ C.gl3_0_glCopyColorTable(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColorTableParameteriv.xml
+func (gl *GL) ColorTableParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl3_0_glColorTableParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColorTableParameterfv.xml
+func (gl *GL) ColorTableParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl3_0_glColorTableParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColorTable.xml
+func (gl *GL) ColorTable(target, internalFormat glbase.Enum, width int, format, gltype glbase.Enum, table interface{}) {
+ var table_ptr unsafe.Pointer
+ var table_v = reflect.ValueOf(table)
+ if table != nil && table_v.Kind() != reflect.Slice {
+ panic("parameter table must be a slice")
+ }
+ if table != nil {
+ table_ptr = unsafe.Pointer(table_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_0_glColorTable(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLenum(format), C.GLenum(gltype), table_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultTransposeMatrixd.xml
+func (gl *GL) MultTransposeMatrixd(m []float64) {
+ C.gl3_0_glMultTransposeMatrixd(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultTransposeMatrixf.xml
+func (gl *GL) MultTransposeMatrixf(m []float32) {
+ C.gl3_0_glMultTransposeMatrixf(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glLoadTransposeMatrixd.xml
+func (gl *GL) LoadTransposeMatrixd(m []float64) {
+ C.gl3_0_glLoadTransposeMatrixd(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glLoadTransposeMatrixf.xml
+func (gl *GL) LoadTransposeMatrixf(m []float32) {
+ C.gl3_0_glLoadTransposeMatrixf(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord4sv.xml
+func (gl *GL) MultiTexCoord4sv(target glbase.Enum, v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glMultiTexCoord4sv(gl.funcs, C.GLenum(target), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord4s.xml
+func (gl *GL) MultiTexCoord4s(target glbase.Enum, s, t, r, q int16) {
+ C.gl3_0_glMultiTexCoord4s(gl.funcs, C.GLenum(target), C.GLshort(s), C.GLshort(t), C.GLshort(r), C.GLshort(q))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord4iv.xml
+func (gl *GL) MultiTexCoord4iv(target glbase.Enum, v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glMultiTexCoord4iv(gl.funcs, C.GLenum(target), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord4i.xml
+func (gl *GL) MultiTexCoord4i(target glbase.Enum, s, t, r, q int32) {
+ C.gl3_0_glMultiTexCoord4i(gl.funcs, C.GLenum(target), C.GLint(s), C.GLint(t), C.GLint(r), C.GLint(q))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord4fv.xml
+func (gl *GL) MultiTexCoord4fv(target glbase.Enum, v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glMultiTexCoord4fv(gl.funcs, C.GLenum(target), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord4f.xml
+func (gl *GL) MultiTexCoord4f(target glbase.Enum, s, t, r, q float32) {
+ C.gl3_0_glMultiTexCoord4f(gl.funcs, C.GLenum(target), C.GLfloat(s), C.GLfloat(t), C.GLfloat(r), C.GLfloat(q))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord4dv.xml
+func (gl *GL) MultiTexCoord4dv(target glbase.Enum, v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glMultiTexCoord4dv(gl.funcs, C.GLenum(target), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord4d.xml
+func (gl *GL) MultiTexCoord4d(target glbase.Enum, s, t, r, q float64) {
+ C.gl3_0_glMultiTexCoord4d(gl.funcs, C.GLenum(target), C.GLdouble(s), C.GLdouble(t), C.GLdouble(r), C.GLdouble(q))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord3sv.xml
+func (gl *GL) MultiTexCoord3sv(target glbase.Enum, v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glMultiTexCoord3sv(gl.funcs, C.GLenum(target), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord3s.xml
+func (gl *GL) MultiTexCoord3s(target glbase.Enum, s, t, r int16) {
+ C.gl3_0_glMultiTexCoord3s(gl.funcs, C.GLenum(target), C.GLshort(s), C.GLshort(t), C.GLshort(r))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord3iv.xml
+func (gl *GL) MultiTexCoord3iv(target glbase.Enum, v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glMultiTexCoord3iv(gl.funcs, C.GLenum(target), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord3i.xml
+func (gl *GL) MultiTexCoord3i(target glbase.Enum, s, t, r int32) {
+ C.gl3_0_glMultiTexCoord3i(gl.funcs, C.GLenum(target), C.GLint(s), C.GLint(t), C.GLint(r))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord3fv.xml
+func (gl *GL) MultiTexCoord3fv(target glbase.Enum, v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glMultiTexCoord3fv(gl.funcs, C.GLenum(target), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord3f.xml
+func (gl *GL) MultiTexCoord3f(target glbase.Enum, s, t, r float32) {
+ C.gl3_0_glMultiTexCoord3f(gl.funcs, C.GLenum(target), C.GLfloat(s), C.GLfloat(t), C.GLfloat(r))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord3dv.xml
+func (gl *GL) MultiTexCoord3dv(target glbase.Enum, v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glMultiTexCoord3dv(gl.funcs, C.GLenum(target), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord3d.xml
+func (gl *GL) MultiTexCoord3d(target glbase.Enum, s, t, r float64) {
+ C.gl3_0_glMultiTexCoord3d(gl.funcs, C.GLenum(target), C.GLdouble(s), C.GLdouble(t), C.GLdouble(r))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord2sv.xml
+func (gl *GL) MultiTexCoord2sv(target glbase.Enum, v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glMultiTexCoord2sv(gl.funcs, C.GLenum(target), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord2s.xml
+func (gl *GL) MultiTexCoord2s(target glbase.Enum, s, t int16) {
+ C.gl3_0_glMultiTexCoord2s(gl.funcs, C.GLenum(target), C.GLshort(s), C.GLshort(t))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord2iv.xml
+func (gl *GL) MultiTexCoord2iv(target glbase.Enum, v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glMultiTexCoord2iv(gl.funcs, C.GLenum(target), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord2i.xml
+func (gl *GL) MultiTexCoord2i(target glbase.Enum, s, t int32) {
+ C.gl3_0_glMultiTexCoord2i(gl.funcs, C.GLenum(target), C.GLint(s), C.GLint(t))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord2fv.xml
+func (gl *GL) MultiTexCoord2fv(target glbase.Enum, v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glMultiTexCoord2fv(gl.funcs, C.GLenum(target), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord2f.xml
+func (gl *GL) MultiTexCoord2f(target glbase.Enum, s, t float32) {
+ C.gl3_0_glMultiTexCoord2f(gl.funcs, C.GLenum(target), C.GLfloat(s), C.GLfloat(t))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord2dv.xml
+func (gl *GL) MultiTexCoord2dv(target glbase.Enum, v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glMultiTexCoord2dv(gl.funcs, C.GLenum(target), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord2d.xml
+func (gl *GL) MultiTexCoord2d(target glbase.Enum, s, t float64) {
+ C.gl3_0_glMultiTexCoord2d(gl.funcs, C.GLenum(target), C.GLdouble(s), C.GLdouble(t))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord1sv.xml
+func (gl *GL) MultiTexCoord1sv(target glbase.Enum, v []int16) {
+ C.gl3_0_glMultiTexCoord1sv(gl.funcs, C.GLenum(target), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord1s.xml
+func (gl *GL) MultiTexCoord1s(target glbase.Enum, s int16) {
+ C.gl3_0_glMultiTexCoord1s(gl.funcs, C.GLenum(target), C.GLshort(s))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord1iv.xml
+func (gl *GL) MultiTexCoord1iv(target glbase.Enum, v []int32) {
+ C.gl3_0_glMultiTexCoord1iv(gl.funcs, C.GLenum(target), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord1i.xml
+func (gl *GL) MultiTexCoord1i(target glbase.Enum, s int32) {
+ C.gl3_0_glMultiTexCoord1i(gl.funcs, C.GLenum(target), C.GLint(s))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord1fv.xml
+func (gl *GL) MultiTexCoord1fv(target glbase.Enum, v []float32) {
+ C.gl3_0_glMultiTexCoord1fv(gl.funcs, C.GLenum(target), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord1f.xml
+func (gl *GL) MultiTexCoord1f(target glbase.Enum, s float32) {
+ C.gl3_0_glMultiTexCoord1f(gl.funcs, C.GLenum(target), C.GLfloat(s))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord1dv.xml
+func (gl *GL) MultiTexCoord1dv(target glbase.Enum, v []float64) {
+ C.gl3_0_glMultiTexCoord1dv(gl.funcs, C.GLenum(target), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord1d.xml
+func (gl *GL) MultiTexCoord1d(target glbase.Enum, s float64) {
+ C.gl3_0_glMultiTexCoord1d(gl.funcs, C.GLenum(target), C.GLdouble(s))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClientActiveTexture.xml
+func (gl *GL) ClientActiveTexture(texture glbase.Enum) {
+ C.gl3_0_glClientActiveTexture(gl.funcs, C.GLenum(texture))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glWindowPos3sv.xml
+func (gl *GL) WindowPos3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glWindowPos3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glWindowPos3s.xml
+func (gl *GL) WindowPos3s(x, y, z int16) {
+ C.gl3_0_glWindowPos3s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glWindowPos3iv.xml
+func (gl *GL) WindowPos3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glWindowPos3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glWindowPos3i.xml
+func (gl *GL) WindowPos3i(x, y, z int) {
+ C.gl3_0_glWindowPos3i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glWindowPos3fv.xml
+func (gl *GL) WindowPos3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glWindowPos3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glWindowPos3f.xml
+func (gl *GL) WindowPos3f(x, y, z float32) {
+ C.gl3_0_glWindowPos3f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glWindowPos3dv.xml
+func (gl *GL) WindowPos3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glWindowPos3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glWindowPos3d.xml
+func (gl *GL) WindowPos3d(x, y, z float64) {
+ C.gl3_0_glWindowPos3d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glWindowPos2sv.xml
+func (gl *GL) WindowPos2sv(v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glWindowPos2sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glWindowPos2s.xml
+func (gl *GL) WindowPos2s(x, y int16) {
+ C.gl3_0_glWindowPos2s(gl.funcs, C.GLshort(x), C.GLshort(y))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glWindowPos2iv.xml
+func (gl *GL) WindowPos2iv(v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glWindowPos2iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glWindowPos2i.xml
+func (gl *GL) WindowPos2i(x, y int) {
+ C.gl3_0_glWindowPos2i(gl.funcs, C.GLint(x), C.GLint(y))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glWindowPos2fv.xml
+func (gl *GL) WindowPos2fv(v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glWindowPos2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glWindowPos2f.xml
+func (gl *GL) WindowPos2f(x, y float32) {
+ C.gl3_0_glWindowPos2f(gl.funcs, C.GLfloat(x), C.GLfloat(y))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glWindowPos2dv.xml
+func (gl *GL) WindowPos2dv(v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glWindowPos2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glWindowPos2d.xml
+func (gl *GL) WindowPos2d(x, y float64) {
+ C.gl3_0_glWindowPos2d(gl.funcs, C.GLdouble(x), C.GLdouble(y))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSecondaryColorPointer.xml
+func (gl *GL) SecondaryColorPointer(size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_0_glSecondaryColorPointer(gl.funcs, C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSecondaryColor3usv.xml
+func (gl *GL) SecondaryColor3usv(v []uint16) {
+ C.gl3_0_glSecondaryColor3usv(gl.funcs, (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSecondaryColor3us.xml
+func (gl *GL) SecondaryColor3us(red, green, blue uint16) {
+ C.gl3_0_glSecondaryColor3us(gl.funcs, C.GLushort(red), C.GLushort(green), C.GLushort(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSecondaryColor3uiv.xml
+func (gl *GL) SecondaryColor3uiv(v []uint32) {
+ C.gl3_0_glSecondaryColor3uiv(gl.funcs, (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSecondaryColor3ui.xml
+func (gl *GL) SecondaryColor3ui(red, green, blue uint32) {
+ C.gl3_0_glSecondaryColor3ui(gl.funcs, C.GLuint(red), C.GLuint(green), C.GLuint(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSecondaryColor3ubv.xml
+func (gl *GL) SecondaryColor3ubv(v []uint8) {
+ C.gl3_0_glSecondaryColor3ubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSecondaryColor3ub.xml
+func (gl *GL) SecondaryColor3ub(red, green, blue uint8) {
+ C.gl3_0_glSecondaryColor3ub(gl.funcs, C.GLubyte(red), C.GLubyte(green), C.GLubyte(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSecondaryColor3sv.xml
+func (gl *GL) SecondaryColor3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glSecondaryColor3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSecondaryColor3s.xml
+func (gl *GL) SecondaryColor3s(red, green, blue int16) {
+ C.gl3_0_glSecondaryColor3s(gl.funcs, C.GLshort(red), C.GLshort(green), C.GLshort(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSecondaryColor3iv.xml
+func (gl *GL) SecondaryColor3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glSecondaryColor3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSecondaryColor3i.xml
+func (gl *GL) SecondaryColor3i(red, green, blue int32) {
+ C.gl3_0_glSecondaryColor3i(gl.funcs, C.GLint(red), C.GLint(green), C.GLint(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSecondaryColor3fv.xml
+func (gl *GL) SecondaryColor3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glSecondaryColor3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSecondaryColor3f.xml
+func (gl *GL) SecondaryColor3f(red, green, blue float32) {
+ C.gl3_0_glSecondaryColor3f(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSecondaryColor3dv.xml
+func (gl *GL) SecondaryColor3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glSecondaryColor3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSecondaryColor3d.xml
+func (gl *GL) SecondaryColor3d(red, green, blue float64) {
+ C.gl3_0_glSecondaryColor3d(gl.funcs, C.GLdouble(red), C.GLdouble(green), C.GLdouble(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSecondaryColor3bv.xml
+func (gl *GL) SecondaryColor3bv(v []byte) {
+ C.gl3_0_glSecondaryColor3bv(gl.funcs, (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSecondaryColor3b.xml
+func (gl *GL) SecondaryColor3b(red, green, blue byte) {
+ C.gl3_0_glSecondaryColor3b(gl.funcs, C.GLbyte(red), C.GLbyte(green), C.GLbyte(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFogCoordPointer.xml
+func (gl *GL) FogCoordPointer(gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_0_glFogCoordPointer(gl.funcs, C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFogCoorddv.xml
+func (gl *GL) FogCoorddv(coord []float64) {
+ C.gl3_0_glFogCoorddv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&coord[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFogCoordd.xml
+func (gl *GL) FogCoordd(coord float64) {
+ C.gl3_0_glFogCoordd(gl.funcs, C.GLdouble(coord))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFogCoordfv.xml
+func (gl *GL) FogCoordfv(coord []float32) {
+ C.gl3_0_glFogCoordfv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&coord[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFogCoordf.xml
+func (gl *GL) FogCoordf(coord float32) {
+ C.gl3_0_glFogCoordf(gl.funcs, C.GLfloat(coord))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib4usv.xml
+func (gl *GL) VertexAttrib4usv(index glbase.Attrib, v []uint16) {
+ C.gl3_0_glVertexAttrib4usv(gl.funcs, C.GLuint(index), (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib4uiv.xml
+func (gl *GL) VertexAttrib4uiv(index glbase.Attrib, v []uint32) {
+ C.gl3_0_glVertexAttrib4uiv(gl.funcs, C.GLuint(index), (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib4ubv.xml
+func (gl *GL) VertexAttrib4ubv(index glbase.Attrib, v []uint8) {
+ C.gl3_0_glVertexAttrib4ubv(gl.funcs, C.GLuint(index), (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib4sv.xml
+func (gl *GL) VertexAttrib4sv(index glbase.Attrib, v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glVertexAttrib4sv(gl.funcs, C.GLuint(index), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib4s.xml
+func (gl *GL) VertexAttrib4s(index glbase.Attrib, x, y, z, w int16) {
+ C.gl3_0_glVertexAttrib4s(gl.funcs, C.GLuint(index), C.GLshort(x), C.GLshort(y), C.GLshort(z), C.GLshort(w))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib4iv.xml
+func (gl *GL) VertexAttrib4iv(index glbase.Attrib, v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glVertexAttrib4iv(gl.funcs, C.GLuint(index), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib4fv.xml
+func (gl *GL) VertexAttrib4fv(index glbase.Attrib, v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glVertexAttrib4fv(gl.funcs, C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib4f.xml
+func (gl *GL) VertexAttrib4f(index glbase.Attrib, x, y, z, w float32) {
+ C.gl3_0_glVertexAttrib4f(gl.funcs, C.GLuint(index), C.GLfloat(x), C.GLfloat(y), C.GLfloat(z), C.GLfloat(w))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib4dv.xml
+func (gl *GL) VertexAttrib4dv(index glbase.Attrib, v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glVertexAttrib4dv(gl.funcs, C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib4d.xml
+func (gl *GL) VertexAttrib4d(index glbase.Attrib, x, y, z, w float64) {
+ C.gl3_0_glVertexAttrib4d(gl.funcs, C.GLuint(index), C.GLdouble(x), C.GLdouble(y), C.GLdouble(z), C.GLdouble(w))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib4bv.xml
+func (gl *GL) VertexAttrib4bv(index glbase.Attrib, v []byte) {
+ C.gl3_0_glVertexAttrib4bv(gl.funcs, C.GLuint(index), (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib4Nusv.xml
+func (gl *GL) VertexAttrib4Nusv(index glbase.Attrib, v []uint16) {
+ C.gl3_0_glVertexAttrib4Nusv(gl.funcs, C.GLuint(index), (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib4Nuiv.xml
+func (gl *GL) VertexAttrib4Nuiv(index glbase.Attrib, v []uint32) {
+ C.gl3_0_glVertexAttrib4Nuiv(gl.funcs, C.GLuint(index), (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib4Nubv.xml
+func (gl *GL) VertexAttrib4Nubv(index glbase.Attrib, v []uint8) {
+ C.gl3_0_glVertexAttrib4Nubv(gl.funcs, C.GLuint(index), (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib4Nub.xml
+func (gl *GL) VertexAttrib4Nub(index glbase.Attrib, x, y, z, w uint8) {
+ C.gl3_0_glVertexAttrib4Nub(gl.funcs, C.GLuint(index), C.GLubyte(x), C.GLubyte(y), C.GLubyte(z), C.GLubyte(w))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib4Nsv.xml
+func (gl *GL) VertexAttrib4Nsv(index glbase.Attrib, v []int16) {
+ C.gl3_0_glVertexAttrib4Nsv(gl.funcs, C.GLuint(index), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib4Niv.xml
+func (gl *GL) VertexAttrib4Niv(index glbase.Attrib, v []int32) {
+ C.gl3_0_glVertexAttrib4Niv(gl.funcs, C.GLuint(index), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib4Nbv.xml
+func (gl *GL) VertexAttrib4Nbv(index glbase.Attrib, v []byte) {
+ C.gl3_0_glVertexAttrib4Nbv(gl.funcs, C.GLuint(index), (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib3sv.xml
+func (gl *GL) VertexAttrib3sv(index glbase.Attrib, v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glVertexAttrib3sv(gl.funcs, C.GLuint(index), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib3s.xml
+func (gl *GL) VertexAttrib3s(index glbase.Attrib, x, y, z int16) {
+ C.gl3_0_glVertexAttrib3s(gl.funcs, C.GLuint(index), C.GLshort(x), C.GLshort(y), C.GLshort(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib3fv.xml
+func (gl *GL) VertexAttrib3fv(index glbase.Attrib, v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glVertexAttrib3fv(gl.funcs, C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib3f.xml
+func (gl *GL) VertexAttrib3f(index glbase.Attrib, x, y, z float32) {
+ C.gl3_0_glVertexAttrib3f(gl.funcs, C.GLuint(index), C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib3dv.xml
+func (gl *GL) VertexAttrib3dv(index glbase.Attrib, v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glVertexAttrib3dv(gl.funcs, C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib3d.xml
+func (gl *GL) VertexAttrib3d(index glbase.Attrib, x, y, z float64) {
+ C.gl3_0_glVertexAttrib3d(gl.funcs, C.GLuint(index), C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib2sv.xml
+func (gl *GL) VertexAttrib2sv(index glbase.Attrib, v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glVertexAttrib2sv(gl.funcs, C.GLuint(index), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib2s.xml
+func (gl *GL) VertexAttrib2s(index glbase.Attrib, x, y int16) {
+ C.gl3_0_glVertexAttrib2s(gl.funcs, C.GLuint(index), C.GLshort(x), C.GLshort(y))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib2fv.xml
+func (gl *GL) VertexAttrib2fv(index glbase.Attrib, v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glVertexAttrib2fv(gl.funcs, C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib2f.xml
+func (gl *GL) VertexAttrib2f(index glbase.Attrib, x, y float32) {
+ C.gl3_0_glVertexAttrib2f(gl.funcs, C.GLuint(index), C.GLfloat(x), C.GLfloat(y))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib2dv.xml
+func (gl *GL) VertexAttrib2dv(index glbase.Attrib, v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glVertexAttrib2dv(gl.funcs, C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib2d.xml
+func (gl *GL) VertexAttrib2d(index glbase.Attrib, x, y float64) {
+ C.gl3_0_glVertexAttrib2d(gl.funcs, C.GLuint(index), C.GLdouble(x), C.GLdouble(y))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib1sv.xml
+func (gl *GL) VertexAttrib1sv(index glbase.Attrib, v []int16) {
+ C.gl3_0_glVertexAttrib1sv(gl.funcs, C.GLuint(index), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib1s.xml
+func (gl *GL) VertexAttrib1s(index glbase.Attrib, x int16) {
+ C.gl3_0_glVertexAttrib1s(gl.funcs, C.GLuint(index), C.GLshort(x))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib1fv.xml
+func (gl *GL) VertexAttrib1fv(index glbase.Attrib, v []float32) {
+ C.gl3_0_glVertexAttrib1fv(gl.funcs, C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib1f.xml
+func (gl *GL) VertexAttrib1f(index glbase.Attrib, x float32) {
+ C.gl3_0_glVertexAttrib1f(gl.funcs, C.GLuint(index), C.GLfloat(x))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib1dv.xml
+func (gl *GL) VertexAttrib1dv(index glbase.Attrib, v []float64) {
+ C.gl3_0_glVertexAttrib1dv(gl.funcs, C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib1d.xml
+func (gl *GL) VertexAttrib1d(index glbase.Attrib, x float64) {
+ C.gl3_0_glVertexAttrib1d(gl.funcs, C.GLuint(index), C.GLdouble(x))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribI4usv.xml
+func (gl *GL) VertexAttribI4usv(index glbase.Attrib, v []uint16) {
+ C.gl3_0_glVertexAttribI4usv(gl.funcs, C.GLuint(index), (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribI4ubv.xml
+func (gl *GL) VertexAttribI4ubv(index glbase.Attrib, v []uint8) {
+ C.gl3_0_glVertexAttribI4ubv(gl.funcs, C.GLuint(index), (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribI4sv.xml
+func (gl *GL) VertexAttribI4sv(index glbase.Attrib, v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glVertexAttribI4sv(gl.funcs, C.GLuint(index), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribI4bv.xml
+func (gl *GL) VertexAttribI4bv(index glbase.Attrib, v []byte) {
+ C.gl3_0_glVertexAttribI4bv(gl.funcs, C.GLuint(index), (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribI4uiv.xml
+func (gl *GL) VertexAttribI4uiv(index glbase.Attrib, v []uint32) {
+ C.gl3_0_glVertexAttribI4uiv(gl.funcs, C.GLuint(index), (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribI3uiv.xml
+func (gl *GL) VertexAttribI3uiv(index glbase.Attrib, v []uint32) {
+ C.gl3_0_glVertexAttribI3uiv(gl.funcs, C.GLuint(index), (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribI2uiv.xml
+func (gl *GL) VertexAttribI2uiv(index glbase.Attrib, v []uint32) {
+ C.gl3_0_glVertexAttribI2uiv(gl.funcs, C.GLuint(index), (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribI1uiv.xml
+func (gl *GL) VertexAttribI1uiv(index glbase.Attrib, v []uint32) {
+ C.gl3_0_glVertexAttribI1uiv(gl.funcs, C.GLuint(index), (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribI4iv.xml
+func (gl *GL) VertexAttribI4iv(index glbase.Attrib, v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glVertexAttribI4iv(gl.funcs, C.GLuint(index), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribI3iv.xml
+func (gl *GL) VertexAttribI3iv(index glbase.Attrib, v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glVertexAttribI3iv(gl.funcs, C.GLuint(index), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribI2iv.xml
+func (gl *GL) VertexAttribI2iv(index glbase.Attrib, v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_0_glVertexAttribI2iv(gl.funcs, C.GLuint(index), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribI1iv.xml
+func (gl *GL) VertexAttribI1iv(index glbase.Attrib, v []int32) {
+ C.gl3_0_glVertexAttribI1iv(gl.funcs, C.GLuint(index), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribI4ui.xml
+func (gl *GL) VertexAttribI4ui(index glbase.Attrib, x, y, z, w uint32) {
+ C.gl3_0_glVertexAttribI4ui(gl.funcs, C.GLuint(index), C.GLuint(x), C.GLuint(y), C.GLuint(z), C.GLuint(w))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribI3ui.xml
+func (gl *GL) VertexAttribI3ui(index glbase.Attrib, x, y, z uint32) {
+ C.gl3_0_glVertexAttribI3ui(gl.funcs, C.GLuint(index), C.GLuint(x), C.GLuint(y), C.GLuint(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribI2ui.xml
+func (gl *GL) VertexAttribI2ui(index glbase.Attrib, x, y uint32) {
+ C.gl3_0_glVertexAttribI2ui(gl.funcs, C.GLuint(index), C.GLuint(x), C.GLuint(y))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribI1ui.xml
+func (gl *GL) VertexAttribI1ui(index glbase.Attrib, x uint32) {
+ C.gl3_0_glVertexAttribI1ui(gl.funcs, C.GLuint(index), C.GLuint(x))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribI4i.xml
+func (gl *GL) VertexAttribI4i(index glbase.Attrib, x, y, z, w int) {
+ C.gl3_0_glVertexAttribI4i(gl.funcs, C.GLuint(index), C.GLint(x), C.GLint(y), C.GLint(z), C.GLint(w))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribI3i.xml
+func (gl *GL) VertexAttribI3i(index glbase.Attrib, x, y, z int) {
+ C.gl3_0_glVertexAttribI3i(gl.funcs, C.GLuint(index), C.GLint(x), C.GLint(y), C.GLint(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribI2i.xml
+func (gl *GL) VertexAttribI2i(index glbase.Attrib, x, y int) {
+ C.gl3_0_glVertexAttribI2i(gl.funcs, C.GLuint(index), C.GLint(x), C.GLint(y))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribI1i.xml
+func (gl *GL) VertexAttribI1i(index glbase.Attrib, x int) {
+ C.gl3_0_glVertexAttribI1i(gl.funcs, C.GLuint(index), C.GLint(x))
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/3.1/funcs.cpp b/Godeps/_workspace/src/github.com/obscuren/qml/gl/3.1/funcs.cpp
new file mode 100644
index 000000000..7f9846760
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/3.1/funcs.cpp
@@ -0,0 +1,1422 @@
+
+// ** file automatically generated by glgen -- do not edit manually **
+
+#include <QOpenGLContext>
+#include <QtGui/qopenglfunctions_3_1.h>
+
+#include "funcs.h"
+
+void *gl3_1_funcs() {
+ QOpenGLFunctions_3_1* funcs = QOpenGLContext::currentContext()->versionFunctions<QOpenGLFunctions_3_1>();
+ if (!funcs) {
+ return 0;
+ }
+ funcs->initializeOpenGLFunctions();
+ return funcs;
+}
+
+
+void gl3_1_glViewport(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glViewport(x, y, width, height);
+}
+
+void gl3_1_glDepthRange(void *_glfuncs, GLdouble nearVal, GLdouble farVal)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glDepthRange(nearVal, farVal);
+}
+
+GLboolean gl3_1_glIsEnabled(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ return _qglfuncs->glIsEnabled(cap);
+}
+
+void gl3_1_glGetTexLevelParameteriv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glGetTexLevelParameteriv(target, level, pname, params);
+}
+
+void gl3_1_glGetTexLevelParameterfv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glGetTexLevelParameterfv(target, level, pname, params);
+}
+
+void gl3_1_glGetTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glGetTexParameteriv(target, pname, params);
+}
+
+void gl3_1_glGetTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glGetTexParameterfv(target, pname, params);
+}
+
+void gl3_1_glGetTexImage(void *_glfuncs, GLenum target, GLint level, GLenum format, GLenum gltype, GLvoid* pixels)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glGetTexImage(target, level, format, gltype, pixels);
+}
+
+void gl3_1_glGetIntegerv(void *_glfuncs, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glGetIntegerv(pname, params);
+}
+
+void gl3_1_glGetFloatv(void *_glfuncs, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glGetFloatv(pname, params);
+}
+
+GLenum gl3_1_glGetError(void *_glfuncs)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ return _qglfuncs->glGetError();
+}
+
+void gl3_1_glGetDoublev(void *_glfuncs, GLenum pname, GLdouble* params)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glGetDoublev(pname, params);
+}
+
+void gl3_1_glGetBooleanv(void *_glfuncs, GLenum pname, GLboolean* params)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glGetBooleanv(pname, params);
+}
+
+void gl3_1_glReadPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum gltype, GLvoid* pixels)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glReadPixels(x, y, width, height, format, gltype, pixels);
+}
+
+void gl3_1_glReadBuffer(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glReadBuffer(mode);
+}
+
+void gl3_1_glPixelStorei(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glPixelStorei(pname, param);
+}
+
+void gl3_1_glPixelStoref(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glPixelStoref(pname, param);
+}
+
+void gl3_1_glDepthFunc(void *_glfuncs, GLenum glfunc)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glDepthFunc(glfunc);
+}
+
+void gl3_1_glStencilOp(void *_glfuncs, GLenum fail, GLenum zfail, GLenum zpass)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glStencilOp(fail, zfail, zpass);
+}
+
+void gl3_1_glStencilFunc(void *_glfuncs, GLenum glfunc, GLint ref, GLuint mask)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glStencilFunc(glfunc, ref, mask);
+}
+
+void gl3_1_glLogicOp(void *_glfuncs, GLenum opcode)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glLogicOp(opcode);
+}
+
+void gl3_1_glBlendFunc(void *_glfuncs, GLenum sfactor, GLenum dfactor)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glBlendFunc(sfactor, dfactor);
+}
+
+void gl3_1_glFlush(void *_glfuncs)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glFlush();
+}
+
+void gl3_1_glFinish(void *_glfuncs)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glFinish();
+}
+
+void gl3_1_glEnable(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glEnable(cap);
+}
+
+void gl3_1_glDisable(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glDisable(cap);
+}
+
+void gl3_1_glDepthMask(void *_glfuncs, GLboolean flag)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glDepthMask(flag);
+}
+
+void gl3_1_glColorMask(void *_glfuncs, GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glColorMask(red, green, blue, alpha);
+}
+
+void gl3_1_glStencilMask(void *_glfuncs, GLuint mask)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glStencilMask(mask);
+}
+
+void gl3_1_glClearDepth(void *_glfuncs, GLdouble depth)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glClearDepth(depth);
+}
+
+void gl3_1_glClearStencil(void *_glfuncs, GLint s)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glClearStencil(s);
+}
+
+void gl3_1_glClearColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glClearColor(red, green, blue, alpha);
+}
+
+void gl3_1_glClear(void *_glfuncs, GLbitfield mask)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glClear(mask);
+}
+
+void gl3_1_glDrawBuffer(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glDrawBuffer(mode);
+}
+
+void gl3_1_glTexImage2D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glTexImage2D(target, level, internalFormat, width, height, border, format, gltype, pixels);
+}
+
+void gl3_1_glTexImage1D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glTexImage1D(target, level, internalFormat, width, border, format, gltype, pixels);
+}
+
+void gl3_1_glTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glTexParameteriv(target, pname, params);
+}
+
+void gl3_1_glTexParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glTexParameteri(target, pname, param);
+}
+
+void gl3_1_glTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glTexParameterfv(target, pname, params);
+}
+
+void gl3_1_glTexParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glTexParameterf(target, pname, param);
+}
+
+void gl3_1_glScissor(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glScissor(x, y, width, height);
+}
+
+void gl3_1_glPolygonMode(void *_glfuncs, GLenum face, GLenum mode)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glPolygonMode(face, mode);
+}
+
+void gl3_1_glPointSize(void *_glfuncs, GLfloat size)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glPointSize(size);
+}
+
+void gl3_1_glLineWidth(void *_glfuncs, GLfloat width)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glLineWidth(width);
+}
+
+void gl3_1_glHint(void *_glfuncs, GLenum target, GLenum mode)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glHint(target, mode);
+}
+
+void gl3_1_glFrontFace(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glFrontFace(mode);
+}
+
+void gl3_1_glCullFace(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glCullFace(mode);
+}
+
+void gl3_1_glIndexubv(void *_glfuncs, const GLubyte* c)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glIndexubv(c);
+}
+
+void gl3_1_glIndexub(void *_glfuncs, GLubyte c)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glIndexub(c);
+}
+
+GLboolean gl3_1_glIsTexture(void *_glfuncs, GLuint texture)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ return _qglfuncs->glIsTexture(texture);
+}
+
+void gl3_1_glGenTextures(void *_glfuncs, GLsizei n, GLuint* textures)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glGenTextures(n, textures);
+}
+
+void gl3_1_glDeleteTextures(void *_glfuncs, GLsizei n, const GLuint* textures)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glDeleteTextures(n, textures);
+}
+
+void gl3_1_glBindTexture(void *_glfuncs, GLenum target, GLuint texture)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glBindTexture(target, texture);
+}
+
+void gl3_1_glTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glTexSubImage2D(target, level, xoffset, yoffset, width, height, format, gltype, pixels);
+}
+
+void gl3_1_glTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glTexSubImage1D(target, level, xoffset, width, format, gltype, pixels);
+}
+
+void gl3_1_glCopyTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage2D(target, level, xoffset, yoffset, x, y, width, height);
+}
+
+void gl3_1_glCopyTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage1D(target, level, xoffset, x, y, width);
+}
+
+void gl3_1_glCopyTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glCopyTexImage2D(target, level, internalFormat, x, y, width, height, border);
+}
+
+void gl3_1_glCopyTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLint border)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glCopyTexImage1D(target, level, internalFormat, x, y, width, border);
+}
+
+void gl3_1_glPolygonOffset(void *_glfuncs, GLfloat factor, GLfloat units)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glPolygonOffset(factor, units);
+}
+
+void gl3_1_glDrawElements(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glDrawElements(mode, count, gltype, indices);
+}
+
+void gl3_1_glDrawArrays(void *_glfuncs, GLenum mode, GLint first, GLsizei count)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glDrawArrays(mode, first, count);
+}
+
+void gl3_1_glCopyTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage3D(target, level, xoffset, yoffset, zoffset, x, y, width, height);
+}
+
+void gl3_1_glTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glTexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, gltype, pixels);
+}
+
+void gl3_1_glTexImage3D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glTexImage3D(target, level, internalFormat, width, height, depth, border, format, gltype, pixels);
+}
+
+void gl3_1_glDrawRangeElements(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glDrawRangeElements(mode, start, end, count, gltype, indices);
+}
+
+void gl3_1_glBlendEquation(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glBlendEquation(mode);
+}
+
+void gl3_1_glBlendColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glBlendColor(red, green, blue, alpha);
+}
+
+void gl3_1_glGetCompressedTexImage(void *_glfuncs, GLenum target, GLint level, GLvoid* img)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glGetCompressedTexImage(target, level, img);
+}
+
+void gl3_1_glCompressedTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glCompressedTexSubImage1D(target, level, xoffset, width, format, imageSize, data);
+}
+
+void gl3_1_glCompressedTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glCompressedTexSubImage2D(target, level, xoffset, yoffset, width, height, format, imageSize, data);
+}
+
+void gl3_1_glCompressedTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glCompressedTexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, imageSize, data);
+}
+
+void gl3_1_glCompressedTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glCompressedTexImage1D(target, level, internalFormat, width, border, imageSize, data);
+}
+
+void gl3_1_glCompressedTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glCompressedTexImage2D(target, level, internalFormat, width, height, border, imageSize, data);
+}
+
+void gl3_1_glCompressedTexImage3D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glCompressedTexImage3D(target, level, internalFormat, width, height, depth, border, imageSize, data);
+}
+
+void gl3_1_glSampleCoverage(void *_glfuncs, GLfloat value, GLboolean invert)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glSampleCoverage(value, invert);
+}
+
+void gl3_1_glActiveTexture(void *_glfuncs, GLenum texture)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glActiveTexture(texture);
+}
+
+void gl3_1_glPointParameteriv(void *_glfuncs, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glPointParameteriv(pname, params);
+}
+
+void gl3_1_glPointParameteri(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glPointParameteri(pname, param);
+}
+
+void gl3_1_glPointParameterfv(void *_glfuncs, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glPointParameterfv(pname, params);
+}
+
+void gl3_1_glPointParameterf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glPointParameterf(pname, param);
+}
+
+void gl3_1_glMultiDrawArrays(void *_glfuncs, GLenum mode, const GLint* first, const GLsizei* count, GLsizei drawcount)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glMultiDrawArrays(mode, first, count, drawcount);
+}
+
+void gl3_1_glBlendFuncSeparate(void *_glfuncs, GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glBlendFuncSeparate(sfactorRGB, dfactorRGB, sfactorAlpha, dfactorAlpha);
+}
+
+void gl3_1_glGetBufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glGetBufferParameteriv(target, pname, params);
+}
+
+GLboolean gl3_1_glUnmapBuffer(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ return _qglfuncs->glUnmapBuffer(target);
+}
+
+void gl3_1_glGetBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, GLvoid* data)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glGetBufferSubData(target, offset, size, data);
+}
+
+void gl3_1_glBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid* data)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glBufferSubData(target, offset, size, data);
+}
+
+void gl3_1_glBufferData(void *_glfuncs, GLenum target, GLsizeiptr size, const GLvoid* data, GLenum usage)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glBufferData(target, size, data, usage);
+}
+
+GLboolean gl3_1_glIsBuffer(void *_glfuncs, GLuint buffer)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ return _qglfuncs->glIsBuffer(buffer);
+}
+
+void gl3_1_glGenBuffers(void *_glfuncs, GLsizei n, GLuint* buffers)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glGenBuffers(n, buffers);
+}
+
+void gl3_1_glDeleteBuffers(void *_glfuncs, GLsizei n, const GLuint* buffers)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glDeleteBuffers(n, buffers);
+}
+
+void gl3_1_glBindBuffer(void *_glfuncs, GLenum target, GLuint buffer)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glBindBuffer(target, buffer);
+}
+
+void gl3_1_glGetQueryObjectuiv(void *_glfuncs, GLuint id, GLenum pname, GLuint* params)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glGetQueryObjectuiv(id, pname, params);
+}
+
+void gl3_1_glGetQueryObjectiv(void *_glfuncs, GLuint id, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glGetQueryObjectiv(id, pname, params);
+}
+
+void gl3_1_glGetQueryiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glGetQueryiv(target, pname, params);
+}
+
+void gl3_1_glEndQuery(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glEndQuery(target);
+}
+
+void gl3_1_glBeginQuery(void *_glfuncs, GLenum target, GLuint id)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glBeginQuery(target, id);
+}
+
+GLboolean gl3_1_glIsQuery(void *_glfuncs, GLuint id)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ return _qglfuncs->glIsQuery(id);
+}
+
+void gl3_1_glDeleteQueries(void *_glfuncs, GLsizei n, const GLuint* ids)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glDeleteQueries(n, ids);
+}
+
+void gl3_1_glGenQueries(void *_glfuncs, GLsizei n, GLuint* ids)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glGenQueries(n, ids);
+}
+
+void gl3_1_glVertexAttribPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLboolean normalized, GLsizei stride, const GLvoid* offset)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glVertexAttribPointer(index, size, gltype, normalized, stride, offset);
+}
+
+void gl3_1_glValidateProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glValidateProgram(program);
+}
+
+void gl3_1_glUniformMatrix4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4fv(location, count, transpose, value);
+}
+
+void gl3_1_glUniformMatrix3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3fv(location, count, transpose, value);
+}
+
+void gl3_1_glUniformMatrix2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2fv(location, count, transpose, value);
+}
+
+void gl3_1_glUniform4iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glUniform4iv(location, count, value);
+}
+
+void gl3_1_glUniform3iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glUniform3iv(location, count, value);
+}
+
+void gl3_1_glUniform2iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glUniform2iv(location, count, value);
+}
+
+void gl3_1_glUniform1iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glUniform1iv(location, count, value);
+}
+
+void gl3_1_glUniform4fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glUniform4fv(location, count, value);
+}
+
+void gl3_1_glUniform3fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glUniform3fv(location, count, value);
+}
+
+void gl3_1_glUniform2fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glUniform2fv(location, count, value);
+}
+
+void gl3_1_glUniform1fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glUniform1fv(location, count, value);
+}
+
+void gl3_1_glUniform4i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2, GLint v3)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glUniform4i(location, v0, v1, v2, v3);
+}
+
+void gl3_1_glUniform3i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glUniform3i(location, v0, v1, v2);
+}
+
+void gl3_1_glUniform2i(void *_glfuncs, GLint location, GLint v0, GLint v1)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glUniform2i(location, v0, v1);
+}
+
+void gl3_1_glUniform1i(void *_glfuncs, GLint location, GLint v0)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glUniform1i(location, v0);
+}
+
+void gl3_1_glUniform4f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glUniform4f(location, v0, v1, v2, v3);
+}
+
+void gl3_1_glUniform3f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glUniform3f(location, v0, v1, v2);
+}
+
+void gl3_1_glUniform2f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glUniform2f(location, v0, v1);
+}
+
+void gl3_1_glUniform1f(void *_glfuncs, GLint location, GLfloat v0)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glUniform1f(location, v0);
+}
+
+void gl3_1_glUseProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glUseProgram(program);
+}
+
+void gl3_1_glShaderSource(void *_glfuncs, GLuint shader, GLsizei count, const GLchar** source, const GLint* length)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glShaderSource(shader, count, source, length);
+}
+
+void gl3_1_glLinkProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glLinkProgram(program);
+}
+
+GLboolean gl3_1_glIsShader(void *_glfuncs, GLuint shader)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ return _qglfuncs->glIsShader(shader);
+}
+
+GLboolean gl3_1_glIsProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ return _qglfuncs->glIsProgram(program);
+}
+
+void gl3_1_glGetVertexAttribiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribiv(index, pname, params);
+}
+
+void gl3_1_glGetVertexAttribfv(void *_glfuncs, GLuint index, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribfv(index, pname, params);
+}
+
+void gl3_1_glGetVertexAttribdv(void *_glfuncs, GLuint index, GLenum pname, GLdouble* params)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribdv(index, pname, params);
+}
+
+void gl3_1_glGetUniformiv(void *_glfuncs, GLuint program, GLint location, GLint* params)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glGetUniformiv(program, location, params);
+}
+
+void gl3_1_glGetUniformfv(void *_glfuncs, GLuint program, GLint location, GLfloat* params)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glGetUniformfv(program, location, params);
+}
+
+GLint gl3_1_glGetUniformLocation(void *_glfuncs, GLuint program, const GLchar* name)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ return _qglfuncs->glGetUniformLocation(program, name);
+}
+
+void gl3_1_glGetShaderSource(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* source)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glGetShaderSource(shader, bufSize, length, source);
+}
+
+void gl3_1_glGetShaderInfoLog(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* infoLog)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glGetShaderInfoLog(shader, bufSize, length, infoLog);
+}
+
+void gl3_1_glGetShaderiv(void *_glfuncs, GLuint shader, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glGetShaderiv(shader, pname, params);
+}
+
+void gl3_1_glGetProgramInfoLog(void *_glfuncs, GLuint program, GLsizei bufSize, GLsizei* length, GLchar* infoLog)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glGetProgramInfoLog(program, bufSize, length, infoLog);
+}
+
+void gl3_1_glGetProgramiv(void *_glfuncs, GLuint program, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glGetProgramiv(program, pname, params);
+}
+
+GLint gl3_1_glGetAttribLocation(void *_glfuncs, GLuint program, const GLchar* name)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ return _qglfuncs->glGetAttribLocation(program, name);
+}
+
+void gl3_1_glGetAttachedShaders(void *_glfuncs, GLuint program, GLsizei maxCount, GLsizei* count, GLuint* obj)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glGetAttachedShaders(program, maxCount, count, obj);
+}
+
+void gl3_1_glGetActiveUniform(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glGetActiveUniform(program, index, bufSize, length, size, gltype, name);
+}
+
+void gl3_1_glGetActiveAttrib(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glGetActiveAttrib(program, index, bufSize, length, size, gltype, name);
+}
+
+void gl3_1_glEnableVertexAttribArray(void *_glfuncs, GLuint index)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glEnableVertexAttribArray(index);
+}
+
+void gl3_1_glDisableVertexAttribArray(void *_glfuncs, GLuint index)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glDisableVertexAttribArray(index);
+}
+
+void gl3_1_glDetachShader(void *_glfuncs, GLuint program, GLuint shader)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glDetachShader(program, shader);
+}
+
+void gl3_1_glDeleteShader(void *_glfuncs, GLuint shader)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glDeleteShader(shader);
+}
+
+void gl3_1_glDeleteProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glDeleteProgram(program);
+}
+
+GLuint gl3_1_glCreateShader(void *_glfuncs, GLenum gltype)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ return _qglfuncs->glCreateShader(gltype);
+}
+
+GLuint gl3_1_glCreateProgram(void *_glfuncs)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ return _qglfuncs->glCreateProgram();
+}
+
+void gl3_1_glCompileShader(void *_glfuncs, GLuint shader)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glCompileShader(shader);
+}
+
+void gl3_1_glBindAttribLocation(void *_glfuncs, GLuint program, GLuint index, const GLchar* name)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glBindAttribLocation(program, index, name);
+}
+
+void gl3_1_glAttachShader(void *_glfuncs, GLuint program, GLuint shader)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glAttachShader(program, shader);
+}
+
+void gl3_1_glStencilMaskSeparate(void *_glfuncs, GLenum face, GLuint mask)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glStencilMaskSeparate(face, mask);
+}
+
+void gl3_1_glStencilFuncSeparate(void *_glfuncs, GLenum face, GLenum glfunc, GLint ref, GLuint mask)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glStencilFuncSeparate(face, glfunc, ref, mask);
+}
+
+void gl3_1_glStencilOpSeparate(void *_glfuncs, GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glStencilOpSeparate(face, sfail, dpfail, dppass);
+}
+
+void gl3_1_glDrawBuffers(void *_glfuncs, GLsizei n, const GLenum* bufs)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glDrawBuffers(n, bufs);
+}
+
+void gl3_1_glBlendEquationSeparate(void *_glfuncs, GLenum modeRGB, GLenum modeAlpha)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glBlendEquationSeparate(modeRGB, modeAlpha);
+}
+
+void gl3_1_glUniformMatrix4x3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4x3fv(location, count, transpose, value);
+}
+
+void gl3_1_glUniformMatrix3x4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3x4fv(location, count, transpose, value);
+}
+
+void gl3_1_glUniformMatrix4x2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4x2fv(location, count, transpose, value);
+}
+
+void gl3_1_glUniformMatrix2x4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2x4fv(location, count, transpose, value);
+}
+
+void gl3_1_glUniformMatrix3x2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3x2fv(location, count, transpose, value);
+}
+
+void gl3_1_glUniformMatrix2x3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2x3fv(location, count, transpose, value);
+}
+
+GLboolean gl3_1_glIsVertexArray(void *_glfuncs, GLuint array)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ return _qglfuncs->glIsVertexArray(array);
+}
+
+void gl3_1_glGenVertexArrays(void *_glfuncs, GLsizei n, GLuint* arrays)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glGenVertexArrays(n, arrays);
+}
+
+void gl3_1_glDeleteVertexArrays(void *_glfuncs, GLsizei n, const GLuint* arrays)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glDeleteVertexArrays(n, arrays);
+}
+
+void gl3_1_glBindVertexArray(void *_glfuncs, GLuint array)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glBindVertexArray(array);
+}
+
+void gl3_1_glFlushMappedBufferRange(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr length)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glFlushMappedBufferRange(target, offset, length);
+}
+
+void gl3_1_glFramebufferTextureLayer(void *_glfuncs, GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glFramebufferTextureLayer(target, attachment, texture, level, layer);
+}
+
+void gl3_1_glRenderbufferStorageMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLenum internalFormat, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glRenderbufferStorageMultisample(target, samples, internalFormat, width, height);
+}
+
+void gl3_1_glBlitFramebuffer(void *_glfuncs, GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glBlitFramebuffer(srcX0, srcY0, srcX1, srcY1, dstX0, dstY0, dstX1, dstY1, mask, filter);
+}
+
+void gl3_1_glGenerateMipmap(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glGenerateMipmap(target);
+}
+
+void gl3_1_glGetFramebufferAttachmentParameteriv(void *_glfuncs, GLenum target, GLenum attachment, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glGetFramebufferAttachmentParameteriv(target, attachment, pname, params);
+}
+
+void gl3_1_glFramebufferRenderbuffer(void *_glfuncs, GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glFramebufferRenderbuffer(target, attachment, renderbuffertarget, renderbuffer);
+}
+
+void gl3_1_glFramebufferTexture3D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glFramebufferTexture3D(target, attachment, textarget, texture, level, zoffset);
+}
+
+void gl3_1_glFramebufferTexture2D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glFramebufferTexture2D(target, attachment, textarget, texture, level);
+}
+
+void gl3_1_glFramebufferTexture1D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glFramebufferTexture1D(target, attachment, textarget, texture, level);
+}
+
+GLenum gl3_1_glCheckFramebufferStatus(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ return _qglfuncs->glCheckFramebufferStatus(target);
+}
+
+void gl3_1_glGenFramebuffers(void *_glfuncs, GLsizei n, GLuint* framebuffers)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glGenFramebuffers(n, framebuffers);
+}
+
+void gl3_1_glDeleteFramebuffers(void *_glfuncs, GLsizei n, const GLuint* framebuffers)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glDeleteFramebuffers(n, framebuffers);
+}
+
+void gl3_1_glBindFramebuffer(void *_glfuncs, GLenum target, GLuint framebuffer)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glBindFramebuffer(target, framebuffer);
+}
+
+GLboolean gl3_1_glIsFramebuffer(void *_glfuncs, GLuint framebuffer)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ return _qglfuncs->glIsFramebuffer(framebuffer);
+}
+
+void gl3_1_glGetRenderbufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glGetRenderbufferParameteriv(target, pname, params);
+}
+
+void gl3_1_glRenderbufferStorage(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glRenderbufferStorage(target, internalFormat, width, height);
+}
+
+void gl3_1_glGenRenderbuffers(void *_glfuncs, GLsizei n, GLuint* renderbuffers)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glGenRenderbuffers(n, renderbuffers);
+}
+
+void gl3_1_glDeleteRenderbuffers(void *_glfuncs, GLsizei n, const GLuint* renderbuffers)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glDeleteRenderbuffers(n, renderbuffers);
+}
+
+void gl3_1_glBindRenderbuffer(void *_glfuncs, GLenum target, GLuint renderbuffer)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glBindRenderbuffer(target, renderbuffer);
+}
+
+GLboolean gl3_1_glIsRenderbuffer(void *_glfuncs, GLuint renderbuffer)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ return _qglfuncs->glIsRenderbuffer(renderbuffer);
+}
+
+void gl3_1_glClearBufferfi(void *_glfuncs, GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glClearBufferfi(buffer, drawbuffer, depth, stencil);
+}
+
+void gl3_1_glClearBufferfv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLfloat* value)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glClearBufferfv(buffer, drawbuffer, value);
+}
+
+void gl3_1_glClearBufferuiv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLuint* value)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glClearBufferuiv(buffer, drawbuffer, value);
+}
+
+void gl3_1_glClearBufferiv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLint* value)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glClearBufferiv(buffer, drawbuffer, value);
+}
+
+void gl3_1_glGetTexParameterIuiv(void *_glfuncs, GLenum target, GLenum pname, GLuint* params)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glGetTexParameterIuiv(target, pname, params);
+}
+
+void gl3_1_glGetTexParameterIiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glGetTexParameterIiv(target, pname, params);
+}
+
+void gl3_1_glTexParameterIuiv(void *_glfuncs, GLenum target, GLenum pname, const GLuint* params)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glTexParameterIuiv(target, pname, params);
+}
+
+void gl3_1_glTexParameterIiv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glTexParameterIiv(target, pname, params);
+}
+
+void gl3_1_glUniform4uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glUniform4uiv(location, count, value);
+}
+
+void gl3_1_glUniform3uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glUniform3uiv(location, count, value);
+}
+
+void gl3_1_glUniform2uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glUniform2uiv(location, count, value);
+}
+
+void gl3_1_glUniform1uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glUniform1uiv(location, count, value);
+}
+
+void gl3_1_glUniform4ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glUniform4ui(location, v0, v1, v2, v3);
+}
+
+void gl3_1_glUniform3ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1, GLuint v2)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glUniform3ui(location, v0, v1, v2);
+}
+
+void gl3_1_glUniform2ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glUniform2ui(location, v0, v1);
+}
+
+void gl3_1_glUniform1ui(void *_glfuncs, GLint location, GLuint v0)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glUniform1ui(location, v0);
+}
+
+GLint gl3_1_glGetFragDataLocation(void *_glfuncs, GLuint program, const GLchar* name)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ return _qglfuncs->glGetFragDataLocation(program, name);
+}
+
+void gl3_1_glBindFragDataLocation(void *_glfuncs, GLuint program, GLuint color, const GLchar* name)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glBindFragDataLocation(program, color, name);
+}
+
+void gl3_1_glGetUniformuiv(void *_glfuncs, GLuint program, GLint location, GLuint* params)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glGetUniformuiv(program, location, params);
+}
+
+void gl3_1_glGetVertexAttribIuiv(void *_glfuncs, GLuint index, GLenum pname, GLuint* params)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribIuiv(index, pname, params);
+}
+
+void gl3_1_glGetVertexAttribIiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribIiv(index, pname, params);
+}
+
+void gl3_1_glVertexAttribIPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glVertexAttribIPointer(index, size, gltype, stride, pointer);
+}
+
+void gl3_1_glEndConditionalRender(void *_glfuncs)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glEndConditionalRender();
+}
+
+void gl3_1_glBeginConditionalRender(void *_glfuncs, GLuint id, GLenum mode)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glBeginConditionalRender(id, mode);
+}
+
+void gl3_1_glClampColor(void *_glfuncs, GLenum target, GLenum clamp)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glClampColor(target, clamp);
+}
+
+void gl3_1_glGetTransformFeedbackVarying(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLsizei* size, GLenum* gltype, GLchar* name)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glGetTransformFeedbackVarying(program, index, bufSize, length, size, gltype, name);
+}
+
+void gl3_1_glBindBufferBase(void *_glfuncs, GLenum target, GLuint index, GLuint buffer)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glBindBufferBase(target, index, buffer);
+}
+
+void gl3_1_glBindBufferRange(void *_glfuncs, GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glBindBufferRange(target, index, buffer, offset, size);
+}
+
+void gl3_1_glEndTransformFeedback(void *_glfuncs)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glEndTransformFeedback();
+}
+
+void gl3_1_glBeginTransformFeedback(void *_glfuncs, GLenum primitiveMode)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glBeginTransformFeedback(primitiveMode);
+}
+
+GLboolean gl3_1_glIsEnabledi(void *_glfuncs, GLenum target, GLuint index)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ return _qglfuncs->glIsEnabledi(target, index);
+}
+
+void gl3_1_glDisablei(void *_glfuncs, GLenum target, GLuint index)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glDisablei(target, index);
+}
+
+void gl3_1_glEnablei(void *_glfuncs, GLenum target, GLuint index)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glEnablei(target, index);
+}
+
+void gl3_1_glGetIntegeri_v(void *_glfuncs, GLenum target, GLuint index, GLint* data)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glGetIntegeri_v(target, index, data);
+}
+
+void gl3_1_glGetBooleani_v(void *_glfuncs, GLenum target, GLuint index, GLboolean* data)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glGetBooleani_v(target, index, data);
+}
+
+void gl3_1_glColorMaski(void *_glfuncs, GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glColorMaski(index, r, g, b, a);
+}
+
+void gl3_1_glCopyBufferSubData(void *_glfuncs, GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glCopyBufferSubData(readTarget, writeTarget, readOffset, writeOffset, size);
+}
+
+void gl3_1_glUniformBlockBinding(void *_glfuncs, GLuint program, GLuint v0, GLuint v1)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glUniformBlockBinding(program, v0, v1);
+}
+
+void gl3_1_glGetActiveUniformBlockName(void *_glfuncs, GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei* length, GLchar* uniformBlockName)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glGetActiveUniformBlockName(program, uniformBlockIndex, bufSize, length, uniformBlockName);
+}
+
+void gl3_1_glGetActiveUniformBlockiv(void *_glfuncs, GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glGetActiveUniformBlockiv(program, uniformBlockIndex, pname, params);
+}
+
+GLuint gl3_1_glGetUniformBlockIndex(void *_glfuncs, GLuint program, const GLchar* uniformBlockName)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ return _qglfuncs->glGetUniformBlockIndex(program, uniformBlockName);
+}
+
+void gl3_1_glGetActiveUniformName(void *_glfuncs, GLuint program, GLuint uniformIndex, GLsizei bufSize, GLsizei* length, GLchar* uniformName)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glGetActiveUniformName(program, uniformIndex, bufSize, length, uniformName);
+}
+
+void gl3_1_glGetActiveUniformsiv(void *_glfuncs, GLuint program, GLsizei uniformCount, const GLuint* uniformIndices, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glGetActiveUniformsiv(program, uniformCount, uniformIndices, pname, params);
+}
+
+void gl3_1_glPrimitiveRestartIndex(void *_glfuncs, GLuint index)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glPrimitiveRestartIndex(index);
+}
+
+void gl3_1_glTexBuffer(void *_glfuncs, GLenum target, GLenum internalFormat, GLuint buffer)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glTexBuffer(target, internalFormat, buffer);
+}
+
+void gl3_1_glDrawElementsInstanced(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glDrawElementsInstanced(mode, count, gltype, indices, instancecount);
+}
+
+void gl3_1_glDrawArraysInstanced(void *_glfuncs, GLenum mode, GLint first, GLsizei count, GLsizei instancecount)
+{
+ QOpenGLFunctions_3_1* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_1*>(_glfuncs);
+ _qglfuncs->glDrawArraysInstanced(mode, first, count, instancecount);
+}
+
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/3.1/funcs.h b/Godeps/_workspace/src/github.com/obscuren/qml/gl/3.1/funcs.h
new file mode 100644
index 000000000..b06680d6e
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/3.1/funcs.h
@@ -0,0 +1,276 @@
+
+// ** file automatically generated by glgen -- do not edit manually **
+
+#ifndef __cplusplus
+#include <inttypes.h>
+#include <stddef.h>
+typedef unsigned int GLenum;
+typedef unsigned char GLboolean;
+typedef unsigned int GLbitfield;
+typedef void GLvoid;
+typedef char GLchar;
+typedef signed char GLbyte; /* 1-byte signed */
+typedef short GLshort; /* 2-byte signed */
+typedef int GLint; /* 4-byte signed */
+typedef unsigned char GLubyte; /* 1-byte unsigned */
+typedef unsigned short GLushort; /* 2-byte unsigned */
+typedef unsigned int GLuint; /* 4-byte unsigned */
+typedef int GLsizei; /* 4-byte signed */
+typedef float GLfloat; /* single precision float */
+typedef float GLclampf; /* single precision float in [0,1] */
+typedef double GLdouble; /* double precision float */
+typedef double GLclampd; /* double precision float in [0,1] */
+typedef int64_t GLint64;
+typedef uint64_t GLuint64;
+typedef ptrdiff_t GLintptr;
+typedef ptrdiff_t GLsizeiptr;
+typedef ptrdiff_t GLintptrARB;
+typedef ptrdiff_t GLsizeiptrARB;
+typedef struct __GLsync *GLsync;
+#endif
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+void *gl3_1_funcs();
+
+void gl3_1_glViewport(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl3_1_glDepthRange(void *_glfuncs, GLdouble nearVal, GLdouble farVal);
+GLboolean gl3_1_glIsEnabled(void *_glfuncs, GLenum cap);
+void gl3_1_glGetTexLevelParameteriv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLint* params);
+void gl3_1_glGetTexLevelParameterfv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLfloat* params);
+void gl3_1_glGetTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl3_1_glGetTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl3_1_glGetTexImage(void *_glfuncs, GLenum target, GLint level, GLenum format, GLenum gltype, GLvoid* pixels);
+void gl3_1_glGetIntegerv(void *_glfuncs, GLenum pname, GLint* params);
+void gl3_1_glGetFloatv(void *_glfuncs, GLenum pname, GLfloat* params);
+GLenum gl3_1_glGetError(void *_glfuncs);
+void gl3_1_glGetDoublev(void *_glfuncs, GLenum pname, GLdouble* params);
+void gl3_1_glGetBooleanv(void *_glfuncs, GLenum pname, GLboolean* params);
+void gl3_1_glReadPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum gltype, GLvoid* pixels);
+void gl3_1_glReadBuffer(void *_glfuncs, GLenum mode);
+void gl3_1_glPixelStorei(void *_glfuncs, GLenum pname, GLint param);
+void gl3_1_glPixelStoref(void *_glfuncs, GLenum pname, GLfloat param);
+void gl3_1_glDepthFunc(void *_glfuncs, GLenum glfunc);
+void gl3_1_glStencilOp(void *_glfuncs, GLenum fail, GLenum zfail, GLenum zpass);
+void gl3_1_glStencilFunc(void *_glfuncs, GLenum glfunc, GLint ref, GLuint mask);
+void gl3_1_glLogicOp(void *_glfuncs, GLenum opcode);
+void gl3_1_glBlendFunc(void *_glfuncs, GLenum sfactor, GLenum dfactor);
+void gl3_1_glFlush(void *_glfuncs);
+void gl3_1_glFinish(void *_glfuncs);
+void gl3_1_glEnable(void *_glfuncs, GLenum cap);
+void gl3_1_glDisable(void *_glfuncs, GLenum cap);
+void gl3_1_glDepthMask(void *_glfuncs, GLboolean flag);
+void gl3_1_glColorMask(void *_glfuncs, GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha);
+void gl3_1_glStencilMask(void *_glfuncs, GLuint mask);
+void gl3_1_glClearDepth(void *_glfuncs, GLdouble depth);
+void gl3_1_glClearStencil(void *_glfuncs, GLint s);
+void gl3_1_glClearColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl3_1_glClear(void *_glfuncs, GLbitfield mask);
+void gl3_1_glDrawBuffer(void *_glfuncs, GLenum mode);
+void gl3_1_glTexImage2D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl3_1_glTexImage1D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl3_1_glTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl3_1_glTexParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint param);
+void gl3_1_glTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl3_1_glTexParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param);
+void gl3_1_glScissor(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl3_1_glPolygonMode(void *_glfuncs, GLenum face, GLenum mode);
+void gl3_1_glPointSize(void *_glfuncs, GLfloat size);
+void gl3_1_glLineWidth(void *_glfuncs, GLfloat width);
+void gl3_1_glHint(void *_glfuncs, GLenum target, GLenum mode);
+void gl3_1_glFrontFace(void *_glfuncs, GLenum mode);
+void gl3_1_glCullFace(void *_glfuncs, GLenum mode);
+void gl3_1_glIndexubv(void *_glfuncs, const GLubyte* c);
+void gl3_1_glIndexub(void *_glfuncs, GLubyte c);
+GLboolean gl3_1_glIsTexture(void *_glfuncs, GLuint texture);
+void gl3_1_glGenTextures(void *_glfuncs, GLsizei n, GLuint* textures);
+void gl3_1_glDeleteTextures(void *_glfuncs, GLsizei n, const GLuint* textures);
+void gl3_1_glBindTexture(void *_glfuncs, GLenum target, GLuint texture);
+void gl3_1_glTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl3_1_glTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl3_1_glCopyTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl3_1_glCopyTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width);
+void gl3_1_glCopyTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border);
+void gl3_1_glCopyTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLint border);
+void gl3_1_glPolygonOffset(void *_glfuncs, GLfloat factor, GLfloat units);
+void gl3_1_glDrawElements(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices);
+void gl3_1_glDrawArrays(void *_glfuncs, GLenum mode, GLint first, GLsizei count);
+void gl3_1_glCopyTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl3_1_glTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl3_1_glTexImage3D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl3_1_glDrawRangeElements(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices);
+void gl3_1_glBlendEquation(void *_glfuncs, GLenum mode);
+void gl3_1_glBlendColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl3_1_glGetCompressedTexImage(void *_glfuncs, GLenum target, GLint level, GLvoid* img);
+void gl3_1_glCompressedTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid* data);
+void gl3_1_glCompressedTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid* data);
+void gl3_1_glCompressedTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid* data);
+void gl3_1_glCompressedTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid* data);
+void gl3_1_glCompressedTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid* data);
+void gl3_1_glCompressedTexImage3D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid* data);
+void gl3_1_glSampleCoverage(void *_glfuncs, GLfloat value, GLboolean invert);
+void gl3_1_glActiveTexture(void *_glfuncs, GLenum texture);
+void gl3_1_glPointParameteriv(void *_glfuncs, GLenum pname, const GLint* params);
+void gl3_1_glPointParameteri(void *_glfuncs, GLenum pname, GLint param);
+void gl3_1_glPointParameterfv(void *_glfuncs, GLenum pname, const GLfloat* params);
+void gl3_1_glPointParameterf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl3_1_glMultiDrawArrays(void *_glfuncs, GLenum mode, const GLint* first, const GLsizei* count, GLsizei drawcount);
+void gl3_1_glBlendFuncSeparate(void *_glfuncs, GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha);
+void gl3_1_glGetBufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+GLboolean gl3_1_glUnmapBuffer(void *_glfuncs, GLenum target);
+void gl3_1_glGetBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, GLvoid* data);
+void gl3_1_glBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid* data);
+void gl3_1_glBufferData(void *_glfuncs, GLenum target, GLsizeiptr size, const GLvoid* data, GLenum usage);
+GLboolean gl3_1_glIsBuffer(void *_glfuncs, GLuint buffer);
+void gl3_1_glGenBuffers(void *_glfuncs, GLsizei n, GLuint* buffers);
+void gl3_1_glDeleteBuffers(void *_glfuncs, GLsizei n, const GLuint* buffers);
+void gl3_1_glBindBuffer(void *_glfuncs, GLenum target, GLuint buffer);
+void gl3_1_glGetQueryObjectuiv(void *_glfuncs, GLuint id, GLenum pname, GLuint* params);
+void gl3_1_glGetQueryObjectiv(void *_glfuncs, GLuint id, GLenum pname, GLint* params);
+void gl3_1_glGetQueryiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl3_1_glEndQuery(void *_glfuncs, GLenum target);
+void gl3_1_glBeginQuery(void *_glfuncs, GLenum target, GLuint id);
+GLboolean gl3_1_glIsQuery(void *_glfuncs, GLuint id);
+void gl3_1_glDeleteQueries(void *_glfuncs, GLsizei n, const GLuint* ids);
+void gl3_1_glGenQueries(void *_glfuncs, GLsizei n, GLuint* ids);
+void gl3_1_glVertexAttribPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLboolean normalized, GLsizei stride, const GLvoid* offset);
+void gl3_1_glValidateProgram(void *_glfuncs, GLuint program);
+void gl3_1_glUniformMatrix4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl3_1_glUniformMatrix3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl3_1_glUniformMatrix2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl3_1_glUniform4iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl3_1_glUniform3iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl3_1_glUniform2iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl3_1_glUniform1iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl3_1_glUniform4fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl3_1_glUniform3fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl3_1_glUniform2fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl3_1_glUniform1fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl3_1_glUniform4i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2, GLint v3);
+void gl3_1_glUniform3i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2);
+void gl3_1_glUniform2i(void *_glfuncs, GLint location, GLint v0, GLint v1);
+void gl3_1_glUniform1i(void *_glfuncs, GLint location, GLint v0);
+void gl3_1_glUniform4f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3);
+void gl3_1_glUniform3f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2);
+void gl3_1_glUniform2f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1);
+void gl3_1_glUniform1f(void *_glfuncs, GLint location, GLfloat v0);
+void gl3_1_glUseProgram(void *_glfuncs, GLuint program);
+void gl3_1_glShaderSource(void *_glfuncs, GLuint shader, GLsizei count, const GLchar** source, const GLint* length);
+void gl3_1_glLinkProgram(void *_glfuncs, GLuint program);
+GLboolean gl3_1_glIsShader(void *_glfuncs, GLuint shader);
+GLboolean gl3_1_glIsProgram(void *_glfuncs, GLuint program);
+void gl3_1_glGetVertexAttribiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params);
+void gl3_1_glGetVertexAttribfv(void *_glfuncs, GLuint index, GLenum pname, GLfloat* params);
+void gl3_1_glGetVertexAttribdv(void *_glfuncs, GLuint index, GLenum pname, GLdouble* params);
+void gl3_1_glGetUniformiv(void *_glfuncs, GLuint program, GLint location, GLint* params);
+void gl3_1_glGetUniformfv(void *_glfuncs, GLuint program, GLint location, GLfloat* params);
+GLint gl3_1_glGetUniformLocation(void *_glfuncs, GLuint program, const GLchar* name);
+void gl3_1_glGetShaderSource(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* source);
+void gl3_1_glGetShaderInfoLog(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* infoLog);
+void gl3_1_glGetShaderiv(void *_glfuncs, GLuint shader, GLenum pname, GLint* params);
+void gl3_1_glGetProgramInfoLog(void *_glfuncs, GLuint program, GLsizei bufSize, GLsizei* length, GLchar* infoLog);
+void gl3_1_glGetProgramiv(void *_glfuncs, GLuint program, GLenum pname, GLint* params);
+GLint gl3_1_glGetAttribLocation(void *_glfuncs, GLuint program, const GLchar* name);
+void gl3_1_glGetAttachedShaders(void *_glfuncs, GLuint program, GLsizei maxCount, GLsizei* count, GLuint* obj);
+void gl3_1_glGetActiveUniform(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name);
+void gl3_1_glGetActiveAttrib(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name);
+void gl3_1_glEnableVertexAttribArray(void *_glfuncs, GLuint index);
+void gl3_1_glDisableVertexAttribArray(void *_glfuncs, GLuint index);
+void gl3_1_glDetachShader(void *_glfuncs, GLuint program, GLuint shader);
+void gl3_1_glDeleteShader(void *_glfuncs, GLuint shader);
+void gl3_1_glDeleteProgram(void *_glfuncs, GLuint program);
+GLuint gl3_1_glCreateShader(void *_glfuncs, GLenum gltype);
+GLuint gl3_1_glCreateProgram(void *_glfuncs);
+void gl3_1_glCompileShader(void *_glfuncs, GLuint shader);
+void gl3_1_glBindAttribLocation(void *_glfuncs, GLuint program, GLuint index, const GLchar* name);
+void gl3_1_glAttachShader(void *_glfuncs, GLuint program, GLuint shader);
+void gl3_1_glStencilMaskSeparate(void *_glfuncs, GLenum face, GLuint mask);
+void gl3_1_glStencilFuncSeparate(void *_glfuncs, GLenum face, GLenum glfunc, GLint ref, GLuint mask);
+void gl3_1_glStencilOpSeparate(void *_glfuncs, GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass);
+void gl3_1_glDrawBuffers(void *_glfuncs, GLsizei n, const GLenum* bufs);
+void gl3_1_glBlendEquationSeparate(void *_glfuncs, GLenum modeRGB, GLenum modeAlpha);
+void gl3_1_glUniformMatrix4x3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl3_1_glUniformMatrix3x4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl3_1_glUniformMatrix4x2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl3_1_glUniformMatrix2x4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl3_1_glUniformMatrix3x2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl3_1_glUniformMatrix2x3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+GLboolean gl3_1_glIsVertexArray(void *_glfuncs, GLuint array);
+void gl3_1_glGenVertexArrays(void *_glfuncs, GLsizei n, GLuint* arrays);
+void gl3_1_glDeleteVertexArrays(void *_glfuncs, GLsizei n, const GLuint* arrays);
+void gl3_1_glBindVertexArray(void *_glfuncs, GLuint array);
+void gl3_1_glFlushMappedBufferRange(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr length);
+void gl3_1_glFramebufferTextureLayer(void *_glfuncs, GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer);
+void gl3_1_glRenderbufferStorageMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLenum internalFormat, GLsizei width, GLsizei height);
+void gl3_1_glBlitFramebuffer(void *_glfuncs, GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter);
+void gl3_1_glGenerateMipmap(void *_glfuncs, GLenum target);
+void gl3_1_glGetFramebufferAttachmentParameteriv(void *_glfuncs, GLenum target, GLenum attachment, GLenum pname, GLint* params);
+void gl3_1_glFramebufferRenderbuffer(void *_glfuncs, GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer);
+void gl3_1_glFramebufferTexture3D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset);
+void gl3_1_glFramebufferTexture2D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+void gl3_1_glFramebufferTexture1D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+GLenum gl3_1_glCheckFramebufferStatus(void *_glfuncs, GLenum target);
+void gl3_1_glGenFramebuffers(void *_glfuncs, GLsizei n, GLuint* framebuffers);
+void gl3_1_glDeleteFramebuffers(void *_glfuncs, GLsizei n, const GLuint* framebuffers);
+void gl3_1_glBindFramebuffer(void *_glfuncs, GLenum target, GLuint framebuffer);
+GLboolean gl3_1_glIsFramebuffer(void *_glfuncs, GLuint framebuffer);
+void gl3_1_glGetRenderbufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl3_1_glRenderbufferStorage(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height);
+void gl3_1_glGenRenderbuffers(void *_glfuncs, GLsizei n, GLuint* renderbuffers);
+void gl3_1_glDeleteRenderbuffers(void *_glfuncs, GLsizei n, const GLuint* renderbuffers);
+void gl3_1_glBindRenderbuffer(void *_glfuncs, GLenum target, GLuint renderbuffer);
+GLboolean gl3_1_glIsRenderbuffer(void *_glfuncs, GLuint renderbuffer);
+void gl3_1_glClearBufferfi(void *_glfuncs, GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil);
+void gl3_1_glClearBufferfv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLfloat* value);
+void gl3_1_glClearBufferuiv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLuint* value);
+void gl3_1_glClearBufferiv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLint* value);
+void gl3_1_glGetTexParameterIuiv(void *_glfuncs, GLenum target, GLenum pname, GLuint* params);
+void gl3_1_glGetTexParameterIiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl3_1_glTexParameterIuiv(void *_glfuncs, GLenum target, GLenum pname, const GLuint* params);
+void gl3_1_glTexParameterIiv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl3_1_glUniform4uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value);
+void gl3_1_glUniform3uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value);
+void gl3_1_glUniform2uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value);
+void gl3_1_glUniform1uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value);
+void gl3_1_glUniform4ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3);
+void gl3_1_glUniform3ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1, GLuint v2);
+void gl3_1_glUniform2ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1);
+void gl3_1_glUniform1ui(void *_glfuncs, GLint location, GLuint v0);
+GLint gl3_1_glGetFragDataLocation(void *_glfuncs, GLuint program, const GLchar* name);
+void gl3_1_glBindFragDataLocation(void *_glfuncs, GLuint program, GLuint color, const GLchar* name);
+void gl3_1_glGetUniformuiv(void *_glfuncs, GLuint program, GLint location, GLuint* params);
+void gl3_1_glGetVertexAttribIuiv(void *_glfuncs, GLuint index, GLenum pname, GLuint* params);
+void gl3_1_glGetVertexAttribIiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params);
+void gl3_1_glVertexAttribIPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl3_1_glEndConditionalRender(void *_glfuncs);
+void gl3_1_glBeginConditionalRender(void *_glfuncs, GLuint id, GLenum mode);
+void gl3_1_glClampColor(void *_glfuncs, GLenum target, GLenum clamp);
+void gl3_1_glGetTransformFeedbackVarying(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLsizei* size, GLenum* gltype, GLchar* name);
+void gl3_1_glBindBufferBase(void *_glfuncs, GLenum target, GLuint index, GLuint buffer);
+void gl3_1_glBindBufferRange(void *_glfuncs, GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size);
+void gl3_1_glEndTransformFeedback(void *_glfuncs);
+void gl3_1_glBeginTransformFeedback(void *_glfuncs, GLenum primitiveMode);
+GLboolean gl3_1_glIsEnabledi(void *_glfuncs, GLenum target, GLuint index);
+void gl3_1_glDisablei(void *_glfuncs, GLenum target, GLuint index);
+void gl3_1_glEnablei(void *_glfuncs, GLenum target, GLuint index);
+void gl3_1_glGetIntegeri_v(void *_glfuncs, GLenum target, GLuint index, GLint* data);
+void gl3_1_glGetBooleani_v(void *_glfuncs, GLenum target, GLuint index, GLboolean* data);
+void gl3_1_glColorMaski(void *_glfuncs, GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a);
+void gl3_1_glCopyBufferSubData(void *_glfuncs, GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size);
+void gl3_1_glUniformBlockBinding(void *_glfuncs, GLuint program, GLuint v0, GLuint v1);
+void gl3_1_glGetActiveUniformBlockName(void *_glfuncs, GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei* length, GLchar* uniformBlockName);
+void gl3_1_glGetActiveUniformBlockiv(void *_glfuncs, GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint* params);
+GLuint gl3_1_glGetUniformBlockIndex(void *_glfuncs, GLuint program, const GLchar* uniformBlockName);
+void gl3_1_glGetActiveUniformName(void *_glfuncs, GLuint program, GLuint uniformIndex, GLsizei bufSize, GLsizei* length, GLchar* uniformName);
+void gl3_1_glGetActiveUniformsiv(void *_glfuncs, GLuint program, GLsizei uniformCount, const GLuint* uniformIndices, GLenum pname, GLint* params);
+void gl3_1_glPrimitiveRestartIndex(void *_glfuncs, GLuint index);
+void gl3_1_glTexBuffer(void *_glfuncs, GLenum target, GLenum internalFormat, GLuint buffer);
+void gl3_1_glDrawElementsInstanced(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount);
+void gl3_1_glDrawArraysInstanced(void *_glfuncs, GLenum mode, GLint first, GLsizei count, GLsizei instancecount);
+
+
+#ifdef __cplusplus
+} // extern "C"
+#endif
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/3.1/gl.go b/Godeps/_workspace/src/github.com/obscuren/qml/gl/3.1/gl.go
new file mode 100644
index 000000000..495e07b3c
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/3.1/gl.go
@@ -0,0 +1,4999 @@
+// ** file automatically generated by glgen -- do not edit manually **
+
+package GL
+
+// #cgo CXXFLAGS: -std=c++0x -pedantic-errors -Wall -fno-strict-aliasing
+// #cgo LDFLAGS: -lstdc++
+// #cgo pkg-config: Qt5Core Qt5OpenGL
+//
+// #include "funcs.h"
+//
+// void free(void*);
+//
+import "C"
+
+import (
+ "fmt"
+ "reflect"
+ "unsafe"
+
+ "gopkg.in/qml.v1/gl/glbase"
+)
+
+// API returns a value that offers methods matching the OpenGL version 3.1 API.
+//
+// The returned API must not be used after the provided OpenGL context becomes invalid.
+func API(context glbase.Contexter) *GL {
+ gl := &GL{}
+ gl.funcs = C.gl3_1_funcs()
+ if gl.funcs == nil {
+ panic(fmt.Errorf("OpenGL version 3.1 is not available"))
+ }
+ return gl
+}
+
+// GL implements the OpenGL version 3.1 API. Values of this
+// type must be created via the API function, and it must not be used after
+// the associated OpenGL context becomes invalid.
+type GL struct {
+ funcs unsafe.Pointer
+}
+
+const (
+ FALSE = 0
+ TRUE = 1
+ NONE = 0
+
+ BYTE = 0x1400
+ UNSIGNED_BYTE = 0x1401
+ SHORT = 0x1402
+ UNSIGNED_SHORT = 0x1403
+ INT = 0x1404
+ UNSIGNED_INT = 0x1405
+ FLOAT = 0x1406
+ N2_BYTES = 0x1407
+ N3_BYTES = 0x1408
+ N4_BYTES = 0x1409
+ DOUBLE = 0x140A
+ HALF_FLOAT = 0x140B
+
+ ACCUM = 0x0100
+ LOAD = 0x0101
+ RETURN = 0x0102
+ MULT = 0x0103
+ ADD = 0x0104
+
+ ACCUM_BUFFER_BIT = 0x00000200
+ ALL_ATTRIB_BITS = 0xFFFFFFFF
+ COLOR_BUFFER_BIT = 0x00004000
+ CURRENT_BIT = 0x00000001
+ DEPTH_BUFFER_BIT = 0x00000100
+ ENABLE_BIT = 0x00002000
+ EVAL_BIT = 0x00010000
+ FOG_BIT = 0x00000080
+ HINT_BIT = 0x00008000
+ LIGHTING_BIT = 0x00000040
+ LINE_BIT = 0x00000004
+ LIST_BIT = 0x00020000
+ MULTISAMPLE_BIT = 0x20000000
+ PIXEL_MODE_BIT = 0x00000020
+ POINT_BIT = 0x00000002
+ POLYGON_BIT = 0x00000008
+ POLYGON_STIPPLE_BIT = 0x00000010
+ SCISSOR_BIT = 0x00080000
+ STENCIL_BUFFER_BIT = 0x00000400
+ TEXTURE_BIT = 0x00040000
+ TRANSFORM_BIT = 0x00001000
+ VIEWPORT_BIT = 0x00000800
+
+ ALWAYS = 0x0207
+ EQUAL = 0x0202
+ GEQUAL = 0x0206
+ GREATER = 0x0204
+ LEQUAL = 0x0203
+ LESS = 0x0201
+ NEVER = 0x0200
+ NOTEQUAL = 0x0205
+
+ LOGIC_OP = 0x0BF1
+
+ DST_ALPHA = 0x0304
+ ONE = 1
+ ONE_MINUS_DST_ALPHA = 0x0305
+ ONE_MINUS_SRC_ALPHA = 0x0303
+ ONE_MINUS_SRC_COLOR = 0x0301
+ SRC_ALPHA = 0x0302
+ SRC_COLOR = 0x0300
+ ZERO = 0
+
+ DST_COLOR = 0x0306
+ ONE_MINUS_DST_COLOR = 0x0307
+ SRC_ALPHA_SATURATE = 0x0308
+
+ CLIENT_ALL_ATTRIB_BITS = 0xFFFFFFFF
+ CLIENT_PIXEL_STORE_BIT = 0x00000001
+ CLIENT_VERTEX_ARRAY_BIT = 0x00000002
+
+ CLIP_DISTANCE0 = 0x3000
+ CLIP_DISTANCE1 = 0x3001
+ CLIP_DISTANCE2 = 0x3002
+ CLIP_DISTANCE3 = 0x3003
+ CLIP_DISTANCE4 = 0x3004
+ CLIP_DISTANCE5 = 0x3005
+ CLIP_DISTANCE6 = 0x3006
+ CLIP_DISTANCE7 = 0x3007
+ CLIP_PLANE0 = 0x3000
+ CLIP_PLANE1 = 0x3001
+ CLIP_PLANE2 = 0x3002
+ CLIP_PLANE3 = 0x3003
+ CLIP_PLANE4 = 0x3004
+ CLIP_PLANE5 = 0x3005
+
+ BACK = 0x0405
+ FRONT = 0x0404
+ FRONT_AND_BACK = 0x0408
+
+ AMBIENT = 0x1200
+ AMBIENT_AND_DIFFUSE = 0x1602
+ DIFFUSE = 0x1201
+ EMISSION = 0x1600
+ SPECULAR = 0x1202
+
+ CONTEXT_FLAG_FORWARD_COMPATIBLE_BIT = 0x00000001
+
+ AUX0 = 0x0409
+ AUX1 = 0x040A
+ AUX2 = 0x040B
+ AUX3 = 0x040C
+ BACK_LEFT = 0x0402
+ BACK_RIGHT = 0x0403
+ FRONT_LEFT = 0x0400
+ FRONT_RIGHT = 0x0401
+ LEFT = 0x0406
+ RIGHT = 0x0407
+
+ ALPHA_TEST = 0x0BC0
+ AUTO_NORMAL = 0x0D80
+ BLEND = 0x0BE2
+ COLOR_ARRAY = 0x8076
+ COLOR_LOGIC_OP = 0x0BF2
+ COLOR_MATERIAL = 0x0B57
+ CULL_FACE = 0x0B44
+ DEPTH_TEST = 0x0B71
+ DITHER = 0x0BD0
+ EDGE_FLAG_ARRAY = 0x8079
+ FOG = 0x0B60
+ INDEX_ARRAY = 0x8077
+ INDEX_LOGIC_OP = 0x0BF1
+ LIGHT0 = 0x4000
+ LIGHT1 = 0x4001
+ LIGHT2 = 0x4002
+ LIGHT3 = 0x4003
+ LIGHT4 = 0x4004
+ LIGHT5 = 0x4005
+ LIGHT6 = 0x4006
+ LIGHT7 = 0x4007
+ LIGHTING = 0x0B50
+ LINE_SMOOTH = 0x0B20
+ LINE_STIPPLE = 0x0B24
+ MAP1_COLOR_4 = 0x0D90
+ MAP1_INDEX = 0x0D91
+ MAP1_NORMAL = 0x0D92
+ MAP1_TEXTURE_COORD_1 = 0x0D93
+ MAP1_TEXTURE_COORD_2 = 0x0D94
+ MAP1_TEXTURE_COORD_3 = 0x0D95
+ MAP1_TEXTURE_COORD_4 = 0x0D96
+ MAP1_VERTEX_3 = 0x0D97
+ MAP1_VERTEX_4 = 0x0D98
+ MAP2_COLOR_4 = 0x0DB0
+ MAP2_INDEX = 0x0DB1
+ MAP2_NORMAL = 0x0DB2
+ MAP2_TEXTURE_COORD_1 = 0x0DB3
+ MAP2_TEXTURE_COORD_2 = 0x0DB4
+ MAP2_TEXTURE_COORD_3 = 0x0DB5
+ MAP2_TEXTURE_COORD_4 = 0x0DB6
+ MAP2_VERTEX_3 = 0x0DB7
+ MAP2_VERTEX_4 = 0x0DB8
+ NORMALIZE = 0x0BA1
+ NORMAL_ARRAY = 0x8075
+ POINT_SMOOTH = 0x0B10
+ POLYGON_OFFSET_FILL = 0x8037
+ POLYGON_OFFSET_LINE = 0x2A02
+ POLYGON_OFFSET_POINT = 0x2A01
+ POLYGON_SMOOTH = 0x0B41
+ POLYGON_STIPPLE = 0x0B42
+ SCISSOR_TEST = 0x0C11
+ STENCIL_TEST = 0x0B90
+ TEXTURE_1D = 0x0DE0
+ TEXTURE_2D = 0x0DE1
+ TEXTURE_COORD_ARRAY = 0x8078
+ TEXTURE_GEN_Q = 0x0C63
+ TEXTURE_GEN_R = 0x0C62
+ TEXTURE_GEN_S = 0x0C60
+ TEXTURE_GEN_T = 0x0C61
+ VERTEX_ARRAY = 0x8074
+
+ INVALID_ENUM = 0x0500
+ INVALID_FRAMEBUFFER_OPERATION = 0x0506
+ INVALID_OPERATION = 0x0502
+ INVALID_VALUE = 0x0501
+ NO_ERROR = 0
+ OUT_OF_MEMORY = 0x0505
+ STACK_OVERFLOW = 0x0503
+ STACK_UNDERFLOW = 0x0504
+
+ N2D = 0x0600
+ N3D = 0x0601
+ N3D_COLOR = 0x0602
+ N3D_COLOR_TEXTURE = 0x0603
+ N4D_COLOR_TEXTURE = 0x0604
+
+ BITMAP_TOKEN = 0x0704
+ COPY_PIXEL_TOKEN = 0x0706
+ DRAW_PIXEL_TOKEN = 0x0705
+ LINE_RESET_TOKEN = 0x0707
+ LINE_TOKEN = 0x0702
+ PASS_THROUGH_TOKEN = 0x0700
+ POINT_TOKEN = 0x0701
+ POLYGON_TOKEN = 0x0703
+
+ EXP = 0x0800
+ EXP2 = 0x0801
+ LINEAR = 0x2601
+
+ FOG_COLOR = 0x0B66
+ FOG_DENSITY = 0x0B62
+ FOG_END = 0x0B64
+ FOG_INDEX = 0x0B61
+ FOG_MODE = 0x0B65
+ FOG_START = 0x0B63
+
+ CCW = 0x0901
+ CW = 0x0900
+
+ COEFF = 0x0A00
+ DOMAIN = 0x0A02
+ ORDER = 0x0A01
+
+ PIXEL_MAP_A_TO_A = 0x0C79
+ PIXEL_MAP_B_TO_B = 0x0C78
+ PIXEL_MAP_G_TO_G = 0x0C77
+ PIXEL_MAP_I_TO_A = 0x0C75
+ PIXEL_MAP_I_TO_B = 0x0C74
+ PIXEL_MAP_I_TO_G = 0x0C73
+ PIXEL_MAP_I_TO_I = 0x0C70
+ PIXEL_MAP_I_TO_R = 0x0C72
+ PIXEL_MAP_R_TO_R = 0x0C76
+ PIXEL_MAP_S_TO_S = 0x0C71
+
+ ACCUM_ALPHA_BITS = 0x0D5B
+ ACCUM_BLUE_BITS = 0x0D5A
+ ACCUM_CLEAR_VALUE = 0x0B80
+ ACCUM_GREEN_BITS = 0x0D59
+ ACCUM_RED_BITS = 0x0D58
+ ALIASED_LINE_WIDTH_RANGE = 0x846E
+ ALIASED_POINT_SIZE_RANGE = 0x846D
+ ALPHA_BIAS = 0x0D1D
+ ALPHA_BITS = 0x0D55
+ ALPHA_SCALE = 0x0D1C
+ ALPHA_TEST_FUNC = 0x0BC1
+ ALPHA_TEST_REF = 0x0BC2
+ ATTRIB_STACK_DEPTH = 0x0BB0
+ AUX_BUFFERS = 0x0C00
+ BLEND_DST = 0x0BE0
+ BLEND_SRC = 0x0BE1
+ BLUE_BIAS = 0x0D1B
+ BLUE_BITS = 0x0D54
+ BLUE_SCALE = 0x0D1A
+ CLIENT_ATTRIB_STACK_DEPTH = 0x0BB1
+ COLOR_ARRAY_SIZE = 0x8081
+ COLOR_ARRAY_STRIDE = 0x8083
+ COLOR_ARRAY_TYPE = 0x8082
+ COLOR_CLEAR_VALUE = 0x0C22
+ COLOR_MATERIAL_FACE = 0x0B55
+ COLOR_MATERIAL_PARAMETER = 0x0B56
+ COLOR_WRITEMASK = 0x0C23
+ CULL_FACE_MODE = 0x0B45
+ CURRENT_COLOR = 0x0B00
+ CURRENT_INDEX = 0x0B01
+ CURRENT_NORMAL = 0x0B02
+ CURRENT_RASTER_COLOR = 0x0B04
+ CURRENT_RASTER_DISTANCE = 0x0B09
+ CURRENT_RASTER_INDEX = 0x0B05
+ CURRENT_RASTER_POSITION = 0x0B07
+ CURRENT_RASTER_POSITION_VALID = 0x0B08
+ CURRENT_RASTER_TEXTURE_COORDS = 0x0B06
+ CURRENT_TEXTURE_COORDS = 0x0B03
+ DEPTH_BIAS = 0x0D1F
+ DEPTH_BITS = 0x0D56
+ DEPTH_CLEAR_VALUE = 0x0B73
+ DEPTH_FUNC = 0x0B74
+ DEPTH_RANGE = 0x0B70
+ DEPTH_SCALE = 0x0D1E
+ DEPTH_WRITEMASK = 0x0B72
+ DOUBLEBUFFER = 0x0C32
+ DRAW_BUFFER = 0x0C01
+ EDGE_FLAG = 0x0B43
+ EDGE_FLAG_ARRAY_STRIDE = 0x808C
+ FEEDBACK_BUFFER_SIZE = 0x0DF1
+ FEEDBACK_BUFFER_TYPE = 0x0DF2
+ FOG_HINT = 0x0C54
+ FRONT_FACE = 0x0B46
+ GREEN_BIAS = 0x0D19
+ GREEN_BITS = 0x0D53
+ GREEN_SCALE = 0x0D18
+ INDEX_ARRAY_STRIDE = 0x8086
+ INDEX_ARRAY_TYPE = 0x8085
+ INDEX_BITS = 0x0D51
+ INDEX_CLEAR_VALUE = 0x0C20
+ INDEX_MODE = 0x0C30
+ INDEX_OFFSET = 0x0D13
+ INDEX_SHIFT = 0x0D12
+ INDEX_WRITEMASK = 0x0C21
+ LIGHT_MODEL_AMBIENT = 0x0B53
+ LIGHT_MODEL_COLOR_CONTROL = 0x81F8
+ LIGHT_MODEL_LOCAL_VIEWER = 0x0B51
+ LIGHT_MODEL_TWO_SIDE = 0x0B52
+ LINE_SMOOTH_HINT = 0x0C52
+ LINE_STIPPLE_PATTERN = 0x0B25
+ LINE_STIPPLE_REPEAT = 0x0B26
+ LINE_WIDTH = 0x0B21
+ LINE_WIDTH_GRANULARITY = 0x0B23
+ LINE_WIDTH_RANGE = 0x0B22
+ LIST_BASE = 0x0B32
+ LIST_INDEX = 0x0B33
+ LIST_MODE = 0x0B30
+ LOGIC_OP_MODE = 0x0BF0
+ MAP1_GRID_DOMAIN = 0x0DD0
+ MAP1_GRID_SEGMENTS = 0x0DD1
+ MAP2_GRID_DOMAIN = 0x0DD2
+ MAP2_GRID_SEGMENTS = 0x0DD3
+ MAP_COLOR = 0x0D10
+ MAP_STENCIL = 0x0D11
+ MATRIX_MODE = 0x0BA0
+ MAX_ATTRIB_STACK_DEPTH = 0x0D35
+ MAX_CLIENT_ATTRIB_STACK_DEPTH = 0x0D3B
+ MAX_CLIP_DISTANCES = 0x0D32
+ MAX_CLIP_PLANES = 0x0D32
+ MAX_EVAL_ORDER = 0x0D30
+ MAX_LIGHTS = 0x0D31
+ MAX_LIST_NESTING = 0x0B31
+ MAX_MODELVIEW_STACK_DEPTH = 0x0D36
+ MAX_NAME_STACK_DEPTH = 0x0D37
+ MAX_PIXEL_MAP_TABLE = 0x0D34
+ MAX_PROJECTION_STACK_DEPTH = 0x0D38
+ MAX_TEXTURE_SIZE = 0x0D33
+ MAX_TEXTURE_STACK_DEPTH = 0x0D39
+ MAX_VIEWPORT_DIMS = 0x0D3A
+ MODELVIEW_MATRIX = 0x0BA6
+ MODELVIEW_STACK_DEPTH = 0x0BA3
+ NAME_STACK_DEPTH = 0x0D70
+ NORMAL_ARRAY_STRIDE = 0x807F
+ NORMAL_ARRAY_TYPE = 0x807E
+ PACK_ALIGNMENT = 0x0D05
+ PACK_LSB_FIRST = 0x0D01
+ PACK_ROW_LENGTH = 0x0D02
+ PACK_SKIP_PIXELS = 0x0D04
+ PACK_SKIP_ROWS = 0x0D03
+ PACK_SWAP_BYTES = 0x0D00
+ PERSPECTIVE_CORRECTION_HINT = 0x0C50
+ PIXEL_MAP_A_TO_A_SIZE = 0x0CB9
+ PIXEL_MAP_B_TO_B_SIZE = 0x0CB8
+ PIXEL_MAP_G_TO_G_SIZE = 0x0CB7
+ PIXEL_MAP_I_TO_A_SIZE = 0x0CB5
+ PIXEL_MAP_I_TO_B_SIZE = 0x0CB4
+ PIXEL_MAP_I_TO_G_SIZE = 0x0CB3
+ PIXEL_MAP_I_TO_I_SIZE = 0x0CB0
+ PIXEL_MAP_I_TO_R_SIZE = 0x0CB2
+ PIXEL_MAP_R_TO_R_SIZE = 0x0CB6
+ PIXEL_MAP_S_TO_S_SIZE = 0x0CB1
+ POINT_SIZE = 0x0B11
+ POINT_SIZE_GRANULARITY = 0x0B13
+ POINT_SIZE_RANGE = 0x0B12
+ POINT_SMOOTH_HINT = 0x0C51
+ POLYGON_MODE = 0x0B40
+ POLYGON_OFFSET_FACTOR = 0x8038
+ POLYGON_OFFSET_UNITS = 0x2A00
+ POLYGON_SMOOTH_HINT = 0x0C53
+ PROJECTION_MATRIX = 0x0BA7
+ PROJECTION_STACK_DEPTH = 0x0BA4
+ READ_BUFFER = 0x0C02
+ RED_BIAS = 0x0D15
+ RED_BITS = 0x0D52
+ RED_SCALE = 0x0D14
+ RENDER_MODE = 0x0C40
+ RGBA_MODE = 0x0C31
+ SCISSOR_BOX = 0x0C10
+ SELECTION_BUFFER_SIZE = 0x0DF4
+ SHADE_MODEL = 0x0B54
+ SMOOTH_LINE_WIDTH_GRANULARITY = 0x0B23
+ SMOOTH_LINE_WIDTH_RANGE = 0x0B22
+ SMOOTH_POINT_SIZE_GRANULARITY = 0x0B13
+ SMOOTH_POINT_SIZE_RANGE = 0x0B12
+ STENCIL_BITS = 0x0D57
+ STENCIL_CLEAR_VALUE = 0x0B91
+ STENCIL_FAIL = 0x0B94
+ STENCIL_FUNC = 0x0B92
+ STENCIL_PASS_DEPTH_FAIL = 0x0B95
+ STENCIL_PASS_DEPTH_PASS = 0x0B96
+ STENCIL_REF = 0x0B97
+ STENCIL_VALUE_MASK = 0x0B93
+ STENCIL_WRITEMASK = 0x0B98
+ STEREO = 0x0C33
+ SUBPIXEL_BITS = 0x0D50
+ TEXTURE_BINDING_1D = 0x8068
+ TEXTURE_BINDING_2D = 0x8069
+ TEXTURE_BINDING_3D = 0x806A
+ TEXTURE_COORD_ARRAY_SIZE = 0x8088
+ TEXTURE_COORD_ARRAY_STRIDE = 0x808A
+ TEXTURE_COORD_ARRAY_TYPE = 0x8089
+ TEXTURE_MATRIX = 0x0BA8
+ TEXTURE_STACK_DEPTH = 0x0BA5
+ UNPACK_ALIGNMENT = 0x0CF5
+ UNPACK_LSB_FIRST = 0x0CF1
+ UNPACK_ROW_LENGTH = 0x0CF2
+ UNPACK_SKIP_PIXELS = 0x0CF4
+ UNPACK_SKIP_ROWS = 0x0CF3
+ UNPACK_SWAP_BYTES = 0x0CF0
+ VERTEX_ARRAY_SIZE = 0x807A
+ VERTEX_ARRAY_STRIDE = 0x807C
+ VERTEX_ARRAY_TYPE = 0x807B
+ VIEWPORT = 0x0BA2
+ ZOOM_X = 0x0D16
+ ZOOM_Y = 0x0D17
+
+ COLOR_ARRAY_POINTER = 0x8090
+ EDGE_FLAG_ARRAY_POINTER = 0x8093
+ FEEDBACK_BUFFER_POINTER = 0x0DF0
+ INDEX_ARRAY_POINTER = 0x8091
+ NORMAL_ARRAY_POINTER = 0x808F
+ SELECTION_BUFFER_POINTER = 0x0DF3
+ TEXTURE_COORD_ARRAY_POINTER = 0x8092
+ VERTEX_ARRAY_POINTER = 0x808E
+
+ TEXTURE_ALPHA_SIZE = 0x805F
+ TEXTURE_BLUE_SIZE = 0x805E
+ TEXTURE_BORDER = 0x1005
+ TEXTURE_BORDER_COLOR = 0x1004
+ TEXTURE_COMPONENTS = 0x1003
+ TEXTURE_GREEN_SIZE = 0x805D
+ TEXTURE_HEIGHT = 0x1001
+ TEXTURE_INTENSITY_SIZE = 0x8061
+ TEXTURE_INTERNAL_FORMAT = 0x1003
+ TEXTURE_LUMINANCE_SIZE = 0x8060
+ TEXTURE_MAG_FILTER = 0x2800
+ TEXTURE_MIN_FILTER = 0x2801
+ TEXTURE_PRIORITY = 0x8066
+ TEXTURE_RED_SIZE = 0x805C
+ TEXTURE_RESIDENT = 0x8067
+ TEXTURE_WIDTH = 0x1000
+ TEXTURE_WRAP_S = 0x2802
+ TEXTURE_WRAP_T = 0x2803
+
+ DONT_CARE = 0x1100
+ FASTEST = 0x1101
+ NICEST = 0x1102
+
+ FRAGMENT_SHADER_DERIVATIVE_HINT = 0x8B8B
+ GENERATE_MIPMAP_HINT = 0x8192
+ TEXTURE_COMPRESSION_HINT = 0x84EF
+
+ C3F_V3F = 0x2A24
+ C4F_N3F_V3F = 0x2A26
+ C4UB_V2F = 0x2A22
+ C4UB_V3F = 0x2A23
+ N3F_V3F = 0x2A25
+ T2F_C3F_V3F = 0x2A2A
+ T2F_C4F_N3F_V3F = 0x2A2C
+ T2F_C4UB_V3F = 0x2A29
+ T2F_N3F_V3F = 0x2A2B
+ T2F_V3F = 0x2A27
+ T4F_C4F_N3F_V4F = 0x2A2D
+ T4F_V4F = 0x2A28
+ V2F = 0x2A20
+ V3F = 0x2A21
+
+ MODULATE = 0x2100
+ REPLACE = 0x1E01
+
+ SEPARATE_SPECULAR_COLOR = 0x81FA
+ SINGLE_COLOR = 0x81F9
+
+ CONSTANT_ATTENUATION = 0x1207
+ LINEAR_ATTENUATION = 0x1208
+ POSITION = 0x1203
+ QUADRATIC_ATTENUATION = 0x1209
+ SPOT_CUTOFF = 0x1206
+ SPOT_DIRECTION = 0x1204
+ SPOT_EXPONENT = 0x1205
+
+ COMPILE = 0x1300
+ COMPILE_AND_EXECUTE = 0x1301
+
+ AND = 0x1501
+ AND_INVERTED = 0x1504
+ AND_REVERSE = 0x1502
+ CLEAR = 0x1500
+ COPY = 0x1503
+ COPY_INVERTED = 0x150C
+ EQUIV = 0x1509
+ INVERT = 0x150A
+ NAND = 0x150E
+ NOOP = 0x1505
+ NOR = 0x1508
+ OR = 0x1507
+ OR_INVERTED = 0x150D
+ OR_REVERSE = 0x150B
+ SET = 0x150F
+ XOR = 0x1506
+
+ MAP_FLUSH_EXPLICIT_BIT = 0x0010
+ MAP_INVALIDATE_BUFFER_BIT = 0x0008
+ MAP_INVALIDATE_RANGE_BIT = 0x0004
+ MAP_READ_BIT = 0x0001
+ MAP_UNSYNCHRONIZED_BIT = 0x0020
+ MAP_WRITE_BIT = 0x0002
+
+ COLOR_INDEXES = 0x1603
+ SHININESS = 0x1601
+
+ MODELVIEW = 0x1700
+ PROJECTION = 0x1701
+ TEXTURE = 0x1702
+
+ LINE = 0x1B01
+ POINT = 0x1B00
+
+ FILL = 0x1B02
+
+ COLOR = 0x1800
+ DEPTH = 0x1801
+ STENCIL = 0x1802
+
+ ALPHA = 0x1906
+ BLUE = 0x1905
+ COLOR_INDEX = 0x1900
+ DEPTH_COMPONENT = 0x1902
+ GREEN = 0x1904
+ LUMINANCE = 0x1909
+ LUMINANCE_ALPHA = 0x190A
+ RED = 0x1903
+ RGB = 0x1907
+ RGBA = 0x1908
+ STENCIL_INDEX = 0x1901
+
+ ALPHA12 = 0x803D
+ ALPHA16 = 0x803E
+ ALPHA4 = 0x803B
+ ALPHA8 = 0x803C
+ INTENSITY = 0x8049
+ INTENSITY12 = 0x804C
+ INTENSITY16 = 0x804D
+ INTENSITY4 = 0x804A
+ INTENSITY8 = 0x804B
+ LUMINANCE12 = 0x8041
+ LUMINANCE12_ALPHA12 = 0x8047
+ LUMINANCE12_ALPHA4 = 0x8046
+ LUMINANCE16 = 0x8042
+ LUMINANCE16_ALPHA16 = 0x8048
+ LUMINANCE4 = 0x803F
+ LUMINANCE4_ALPHA4 = 0x8043
+ LUMINANCE6_ALPHA2 = 0x8044
+ LUMINANCE8 = 0x8040
+ LUMINANCE8_ALPHA8 = 0x8045
+ R3_G3_B2 = 0x2A10
+ RGB10 = 0x8052
+ RGB10_A2 = 0x8059
+ RGB12 = 0x8053
+ RGB16 = 0x8054
+ RGB4 = 0x804F
+ RGB5 = 0x8050
+ RGB5_A1 = 0x8057
+ RGB8 = 0x8051
+ RGBA12 = 0x805A
+ RGBA16 = 0x805B
+ RGBA2 = 0x8055
+ RGBA4 = 0x8056
+ RGBA8 = 0x8058
+
+ PACK_IMAGE_HEIGHT = 0x806C
+ PACK_SKIP_IMAGES = 0x806B
+ UNPACK_IMAGE_HEIGHT = 0x806E
+ UNPACK_SKIP_IMAGES = 0x806D
+
+ BITMAP = 0x1A00
+ UNSIGNED_BYTE_3_3_2 = 0x8032
+ UNSIGNED_INT_10_10_10_2 = 0x8036
+ UNSIGNED_INT_8_8_8_8 = 0x8035
+ UNSIGNED_SHORT_4_4_4_4 = 0x8033
+ UNSIGNED_SHORT_5_5_5_1 = 0x8034
+
+ POINT_DISTANCE_ATTENUATION = 0x8129
+ POINT_FADE_THRESHOLD_SIZE = 0x8128
+ POINT_SIZE_MAX = 0x8127
+ POINT_SIZE_MIN = 0x8126
+
+ LINES = 0x0001
+ LINE_LOOP = 0x0002
+ LINE_STRIP = 0x0003
+ POINTS = 0x0000
+ POLYGON = 0x0009
+ QUADS = 0x0007
+ QUAD_STRIP = 0x0008
+ TRIANGLES = 0x0004
+ TRIANGLE_FAN = 0x0006
+ TRIANGLE_STRIP = 0x0005
+
+ FEEDBACK = 0x1C01
+ RENDER = 0x1C00
+ SELECT = 0x1C02
+
+ FLAT = 0x1D00
+ SMOOTH = 0x1D01
+
+ DECR = 0x1E03
+ INCR = 0x1E02
+ KEEP = 0x1E00
+
+ EXTENSIONS = 0x1F03
+ RENDERER = 0x1F01
+ VENDOR = 0x1F00
+ VERSION = 0x1F02
+
+ S = 0x2000
+ T = 0x2001
+ R = 0x2002
+ Q = 0x2003
+
+ DECAL = 0x2101
+
+ TEXTURE_ENV_COLOR = 0x2201
+ TEXTURE_ENV_MODE = 0x2200
+
+ TEXTURE_ENV = 0x2300
+
+ EYE_LINEAR = 0x2400
+ OBJECT_LINEAR = 0x2401
+ SPHERE_MAP = 0x2402
+
+ EYE_PLANE = 0x2502
+ OBJECT_PLANE = 0x2501
+ TEXTURE_GEN_MODE = 0x2500
+
+ NEAREST = 0x2600
+
+ LINEAR_MIPMAP_LINEAR = 0x2703
+ LINEAR_MIPMAP_NEAREST = 0x2701
+ NEAREST_MIPMAP_LINEAR = 0x2702
+ NEAREST_MIPMAP_NEAREST = 0x2700
+
+ GENERATE_MIPMAP = 0x8191
+ TEXTURE_WRAP_R = 0x8072
+
+ PROXY_TEXTURE_1D = 0x8063
+ PROXY_TEXTURE_2D = 0x8064
+ PROXY_TEXTURE_3D = 0x8070
+ TEXTURE_3D = 0x806F
+ TEXTURE_BASE_LEVEL = 0x813C
+ TEXTURE_MAX_LEVEL = 0x813D
+ TEXTURE_MAX_LOD = 0x813B
+ TEXTURE_MIN_LOD = 0x813A
+
+ CLAMP = 0x2900
+ CLAMP_TO_BORDER = 0x812D
+ CLAMP_TO_EDGE = 0x812F
+ REPEAT = 0x2901
+
+ INVALID_INDEX = 0xFFFFFFFF
+ CONSTANT_COLOR = 0x8001
+ ONE_MINUS_CONSTANT_COLOR = 0x8002
+ CONSTANT_ALPHA = 0x8003
+ ONE_MINUS_CONSTANT_ALPHA = 0x8004
+ FUNC_ADD = 0x8006
+ MIN = 0x8007
+ MAX = 0x8008
+ BLEND_EQUATION_RGB = 0x8009
+ FUNC_SUBTRACT = 0x800A
+ FUNC_REVERSE_SUBTRACT = 0x800B
+ RESCALE_NORMAL = 0x803A
+ TEXTURE_DEPTH = 0x8071
+ MAX_3D_TEXTURE_SIZE = 0x8073
+ MULTISAMPLE = 0x809D
+ SAMPLE_ALPHA_TO_COVERAGE = 0x809E
+ SAMPLE_ALPHA_TO_ONE = 0x809F
+ SAMPLE_COVERAGE = 0x80A0
+ SAMPLE_BUFFERS = 0x80A8
+ SAMPLES = 0x80A9
+ SAMPLE_COVERAGE_VALUE = 0x80AA
+ SAMPLE_COVERAGE_INVERT = 0x80AB
+ BLEND_DST_RGB = 0x80C8
+ BLEND_SRC_RGB = 0x80C9
+ BLEND_DST_ALPHA = 0x80CA
+ BLEND_SRC_ALPHA = 0x80CB
+ BGR = 0x80E0
+ BGRA = 0x80E1
+ MAX_ELEMENTS_VERTICES = 0x80E8
+ MAX_ELEMENTS_INDICES = 0x80E9
+ DEPTH_COMPONENT16 = 0x81A5
+ DEPTH_COMPONENT24 = 0x81A6
+ DEPTH_COMPONENT32 = 0x81A7
+ FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING = 0x8210
+ FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE = 0x8211
+ FRAMEBUFFER_ATTACHMENT_RED_SIZE = 0x8212
+ FRAMEBUFFER_ATTACHMENT_GREEN_SIZE = 0x8213
+ FRAMEBUFFER_ATTACHMENT_BLUE_SIZE = 0x8214
+ FRAMEBUFFER_ATTACHMENT_ALPHA_SIZE = 0x8215
+ FRAMEBUFFER_ATTACHMENT_DEPTH_SIZE = 0x8216
+ FRAMEBUFFER_ATTACHMENT_STENCIL_SIZE = 0x8217
+ FRAMEBUFFER_DEFAULT = 0x8218
+ FRAMEBUFFER_UNDEFINED = 0x8219
+ DEPTH_STENCIL_ATTACHMENT = 0x821A
+ MAJOR_VERSION = 0x821B
+ MINOR_VERSION = 0x821C
+ NUM_EXTENSIONS = 0x821D
+ CONTEXT_FLAGS = 0x821E
+ COMPRESSED_RED = 0x8225
+ COMPRESSED_RG = 0x8226
+ RG = 0x8227
+ RG_INTEGER = 0x8228
+ R8 = 0x8229
+ R16 = 0x822A
+ RG8 = 0x822B
+ RG16 = 0x822C
+ R16F = 0x822D
+ R32F = 0x822E
+ RG16F = 0x822F
+ RG32F = 0x8230
+ R8I = 0x8231
+ R8UI = 0x8232
+ R16I = 0x8233
+ R16UI = 0x8234
+ R32I = 0x8235
+ R32UI = 0x8236
+ RG8I = 0x8237
+ RG8UI = 0x8238
+ RG16I = 0x8239
+ RG16UI = 0x823A
+ RG32I = 0x823B
+ RG32UI = 0x823C
+ UNSIGNED_BYTE_2_3_3_REV = 0x8362
+ UNSIGNED_SHORT_5_6_5 = 0x8363
+ UNSIGNED_SHORT_5_6_5_REV = 0x8364
+ UNSIGNED_SHORT_4_4_4_4_REV = 0x8365
+ UNSIGNED_SHORT_1_5_5_5_REV = 0x8366
+ UNSIGNED_INT_8_8_8_8_REV = 0x8367
+ UNSIGNED_INT_2_10_10_10_REV = 0x8368
+ MIRRORED_REPEAT = 0x8370
+ FOG_COORDINATE_SOURCE = 0x8450
+ FOG_COORD_SRC = 0x8450
+ FOG_COORDINATE = 0x8451
+ FOG_COORD = 0x8451
+ FRAGMENT_DEPTH = 0x8452
+ CURRENT_FOG_COORDINATE = 0x8453
+ CURRENT_FOG_COORD = 0x8453
+ FOG_COORDINATE_ARRAY_TYPE = 0x8454
+ FOG_COORD_ARRAY_TYPE = 0x8454
+ FOG_COORDINATE_ARRAY_STRIDE = 0x8455
+ FOG_COORD_ARRAY_STRIDE = 0x8455
+ FOG_COORDINATE_ARRAY_POINTER = 0x8456
+ FOG_COORD_ARRAY_POINTER = 0x8456
+ FOG_COORDINATE_ARRAY = 0x8457
+ FOG_COORD_ARRAY = 0x8457
+ COLOR_SUM = 0x8458
+ CURRENT_SECONDARY_COLOR = 0x8459
+ SECONDARY_COLOR_ARRAY_SIZE = 0x845A
+ SECONDARY_COLOR_ARRAY_TYPE = 0x845B
+ SECONDARY_COLOR_ARRAY_STRIDE = 0x845C
+ SECONDARY_COLOR_ARRAY_POINTER = 0x845D
+ SECONDARY_COLOR_ARRAY = 0x845E
+ CURRENT_RASTER_SECONDARY_COLOR = 0x845F
+ TEXTURE0 = 0x84C0
+ TEXTURE1 = 0x84C1
+ TEXTURE2 = 0x84C2
+ TEXTURE3 = 0x84C3
+ TEXTURE4 = 0x84C4
+ TEXTURE5 = 0x84C5
+ TEXTURE6 = 0x84C6
+ TEXTURE7 = 0x84C7
+ TEXTURE8 = 0x84C8
+ TEXTURE9 = 0x84C9
+ TEXTURE10 = 0x84CA
+ TEXTURE11 = 0x84CB
+ TEXTURE12 = 0x84CC
+ TEXTURE13 = 0x84CD
+ TEXTURE14 = 0x84CE
+ TEXTURE15 = 0x84CF
+ TEXTURE16 = 0x84D0
+ TEXTURE17 = 0x84D1
+ TEXTURE18 = 0x84D2
+ TEXTURE19 = 0x84D3
+ TEXTURE20 = 0x84D4
+ TEXTURE21 = 0x84D5
+ TEXTURE22 = 0x84D6
+ TEXTURE23 = 0x84D7
+ TEXTURE24 = 0x84D8
+ TEXTURE25 = 0x84D9
+ TEXTURE26 = 0x84DA
+ TEXTURE27 = 0x84DB
+ TEXTURE28 = 0x84DC
+ TEXTURE29 = 0x84DD
+ TEXTURE30 = 0x84DE
+ TEXTURE31 = 0x84DF
+ ACTIVE_TEXTURE = 0x84E0
+ CLIENT_ACTIVE_TEXTURE = 0x84E1
+ MAX_TEXTURE_UNITS = 0x84E2
+ TRANSPOSE_MODELVIEW_MATRIX = 0x84E3
+ TRANSPOSE_PROJECTION_MATRIX = 0x84E4
+ TRANSPOSE_TEXTURE_MATRIX = 0x84E5
+ TRANSPOSE_COLOR_MATRIX = 0x84E6
+ SUBTRACT = 0x84E7
+ MAX_RENDERBUFFER_SIZE = 0x84E8
+ COMPRESSED_ALPHA = 0x84E9
+ COMPRESSED_LUMINANCE = 0x84EA
+ COMPRESSED_LUMINANCE_ALPHA = 0x84EB
+ COMPRESSED_INTENSITY = 0x84EC
+ COMPRESSED_RGB = 0x84ED
+ COMPRESSED_RGBA = 0x84EE
+ TEXTURE_RECTANGLE = 0x84F5
+ TEXTURE_BINDING_RECTANGLE = 0x84F6
+ PROXY_TEXTURE_RECTANGLE = 0x84F7
+ MAX_RECTANGLE_TEXTURE_SIZE = 0x84F8
+ DEPTH_STENCIL = 0x84F9
+ UNSIGNED_INT_24_8 = 0x84FA
+ MAX_TEXTURE_LOD_BIAS = 0x84FD
+ TEXTURE_FILTER_CONTROL = 0x8500
+ TEXTURE_LOD_BIAS = 0x8501
+ INCR_WRAP = 0x8507
+ DECR_WRAP = 0x8508
+ NORMAL_MAP = 0x8511
+ REFLECTION_MAP = 0x8512
+ TEXTURE_CUBE_MAP = 0x8513
+ TEXTURE_BINDING_CUBE_MAP = 0x8514
+ TEXTURE_CUBE_MAP_POSITIVE_X = 0x8515
+ TEXTURE_CUBE_MAP_NEGATIVE_X = 0x8516
+ TEXTURE_CUBE_MAP_POSITIVE_Y = 0x8517
+ TEXTURE_CUBE_MAP_NEGATIVE_Y = 0x8518
+ TEXTURE_CUBE_MAP_POSITIVE_Z = 0x8519
+ TEXTURE_CUBE_MAP_NEGATIVE_Z = 0x851A
+ PROXY_TEXTURE_CUBE_MAP = 0x851B
+ MAX_CUBE_MAP_TEXTURE_SIZE = 0x851C
+ COMBINE = 0x8570
+ COMBINE_RGB = 0x8571
+ COMBINE_ALPHA = 0x8572
+ RGB_SCALE = 0x8573
+ ADD_SIGNED = 0x8574
+ INTERPOLATE = 0x8575
+ CONSTANT = 0x8576
+ PRIMARY_COLOR = 0x8577
+ PREVIOUS = 0x8578
+ SOURCE0_RGB = 0x8580
+ SRC0_RGB = 0x8580
+ SOURCE1_RGB = 0x8581
+ SRC1_RGB = 0x8581
+ SOURCE2_RGB = 0x8582
+ SRC2_RGB = 0x8582
+ SOURCE0_ALPHA = 0x8588
+ SRC0_ALPHA = 0x8588
+ SOURCE1_ALPHA = 0x8589
+ SRC1_ALPHA = 0x8589
+ SOURCE2_ALPHA = 0x858A
+ SRC2_ALPHA = 0x858A
+ OPERAND0_RGB = 0x8590
+ OPERAND1_RGB = 0x8591
+ OPERAND2_RGB = 0x8592
+ OPERAND0_ALPHA = 0x8598
+ OPERAND1_ALPHA = 0x8599
+ OPERAND2_ALPHA = 0x859A
+ VERTEX_ARRAY_BINDING = 0x85B5
+ VERTEX_ATTRIB_ARRAY_ENABLED = 0x8622
+ VERTEX_ATTRIB_ARRAY_SIZE = 0x8623
+ VERTEX_ATTRIB_ARRAY_STRIDE = 0x8624
+ VERTEX_ATTRIB_ARRAY_TYPE = 0x8625
+ CURRENT_VERTEX_ATTRIB = 0x8626
+ VERTEX_PROGRAM_POINT_SIZE = 0x8642
+ VERTEX_PROGRAM_TWO_SIDE = 0x8643
+ VERTEX_ATTRIB_ARRAY_POINTER = 0x8645
+ TEXTURE_COMPRESSED_IMAGE_SIZE = 0x86A0
+ TEXTURE_COMPRESSED = 0x86A1
+ NUM_COMPRESSED_TEXTURE_FORMATS = 0x86A2
+ COMPRESSED_TEXTURE_FORMATS = 0x86A3
+ DOT3_RGB = 0x86AE
+ DOT3_RGBA = 0x86AF
+ BUFFER_SIZE = 0x8764
+ BUFFER_USAGE = 0x8765
+ STENCIL_BACK_FUNC = 0x8800
+ STENCIL_BACK_FAIL = 0x8801
+ STENCIL_BACK_PASS_DEPTH_FAIL = 0x8802
+ STENCIL_BACK_PASS_DEPTH_PASS = 0x8803
+ RGBA32F = 0x8814
+ RGB32F = 0x8815
+ RGBA16F = 0x881A
+ RGB16F = 0x881B
+ MAX_DRAW_BUFFERS = 0x8824
+ DRAW_BUFFER0 = 0x8825
+ DRAW_BUFFER1 = 0x8826
+ DRAW_BUFFER2 = 0x8827
+ DRAW_BUFFER3 = 0x8828
+ DRAW_BUFFER4 = 0x8829
+ DRAW_BUFFER5 = 0x882A
+ DRAW_BUFFER6 = 0x882B
+ DRAW_BUFFER7 = 0x882C
+ DRAW_BUFFER8 = 0x882D
+ DRAW_BUFFER9 = 0x882E
+ DRAW_BUFFER10 = 0x882F
+ DRAW_BUFFER11 = 0x8830
+ DRAW_BUFFER12 = 0x8831
+ DRAW_BUFFER13 = 0x8832
+ DRAW_BUFFER14 = 0x8833
+ DRAW_BUFFER15 = 0x8834
+ BLEND_EQUATION_ALPHA = 0x883D
+ TEXTURE_DEPTH_SIZE = 0x884A
+ DEPTH_TEXTURE_MODE = 0x884B
+ TEXTURE_COMPARE_MODE = 0x884C
+ TEXTURE_COMPARE_FUNC = 0x884D
+ COMPARE_R_TO_TEXTURE = 0x884E
+ COMPARE_REF_TO_TEXTURE = 0x884E
+ POINT_SPRITE = 0x8861
+ COORD_REPLACE = 0x8862
+ QUERY_COUNTER_BITS = 0x8864
+ CURRENT_QUERY = 0x8865
+ QUERY_RESULT = 0x8866
+ QUERY_RESULT_AVAILABLE = 0x8867
+ MAX_VERTEX_ATTRIBS = 0x8869
+ VERTEX_ATTRIB_ARRAY_NORMALIZED = 0x886A
+ MAX_TEXTURE_COORDS = 0x8871
+ MAX_TEXTURE_IMAGE_UNITS = 0x8872
+ ARRAY_BUFFER = 0x8892
+ ELEMENT_ARRAY_BUFFER = 0x8893
+ ARRAY_BUFFER_BINDING = 0x8894
+ ELEMENT_ARRAY_BUFFER_BINDING = 0x8895
+ VERTEX_ARRAY_BUFFER_BINDING = 0x8896
+ NORMAL_ARRAY_BUFFER_BINDING = 0x8897
+ COLOR_ARRAY_BUFFER_BINDING = 0x8898
+ INDEX_ARRAY_BUFFER_BINDING = 0x8899
+ TEXTURE_COORD_ARRAY_BUFFER_BINDING = 0x889A
+ EDGE_FLAG_ARRAY_BUFFER_BINDING = 0x889B
+ SECONDARY_COLOR_ARRAY_BUFFER_BINDING = 0x889C
+ FOG_COORDINATE_ARRAY_BUFFER_BINDING = 0x889D
+ FOG_COORD_ARRAY_BUFFER_BINDING = 0x889D
+ WEIGHT_ARRAY_BUFFER_BINDING = 0x889E
+ VERTEX_ATTRIB_ARRAY_BUFFER_BINDING = 0x889F
+ READ_ONLY = 0x88B8
+ WRITE_ONLY = 0x88B9
+ READ_WRITE = 0x88BA
+ BUFFER_ACCESS = 0x88BB
+ BUFFER_MAPPED = 0x88BC
+ BUFFER_MAP_POINTER = 0x88BD
+ STREAM_DRAW = 0x88E0
+ STREAM_READ = 0x88E1
+ STREAM_COPY = 0x88E2
+ STATIC_DRAW = 0x88E4
+ STATIC_READ = 0x88E5
+ STATIC_COPY = 0x88E6
+ DYNAMIC_DRAW = 0x88E8
+ DYNAMIC_READ = 0x88E9
+ DYNAMIC_COPY = 0x88EA
+ PIXEL_PACK_BUFFER = 0x88EB
+ PIXEL_UNPACK_BUFFER = 0x88EC
+ PIXEL_PACK_BUFFER_BINDING = 0x88ED
+ PIXEL_UNPACK_BUFFER_BINDING = 0x88EF
+ DEPTH24_STENCIL8 = 0x88F0
+ TEXTURE_STENCIL_SIZE = 0x88F1
+ VERTEX_ATTRIB_ARRAY_INTEGER = 0x88FD
+ MAX_ARRAY_TEXTURE_LAYERS = 0x88FF
+ MIN_PROGRAM_TEXEL_OFFSET = 0x8904
+ MAX_PROGRAM_TEXEL_OFFSET = 0x8905
+ SAMPLES_PASSED = 0x8914
+ CLAMP_VERTEX_COLOR = 0x891A
+ CLAMP_FRAGMENT_COLOR = 0x891B
+ CLAMP_READ_COLOR = 0x891C
+ FIXED_ONLY = 0x891D
+ UNIFORM_BUFFER = 0x8A11
+ UNIFORM_BUFFER_BINDING = 0x8A28
+ UNIFORM_BUFFER_START = 0x8A29
+ UNIFORM_BUFFER_SIZE = 0x8A2A
+ MAX_VERTEX_UNIFORM_BLOCKS = 0x8A2B
+ MAX_GEOMETRY_UNIFORM_BLOCKS = 0x8A2C
+ MAX_FRAGMENT_UNIFORM_BLOCKS = 0x8A2D
+ MAX_COMBINED_UNIFORM_BLOCKS = 0x8A2E
+ MAX_UNIFORM_BUFFER_BINDINGS = 0x8A2F
+ MAX_UNIFORM_BLOCK_SIZE = 0x8A30
+ MAX_COMBINED_VERTEX_UNIFORM_COMPONENTS = 0x8A31
+ MAX_COMBINED_GEOMETRY_UNIFORM_COMPONENTS = 0x8A32
+ MAX_COMBINED_FRAGMENT_UNIFORM_COMPONENTS = 0x8A33
+ UNIFORM_BUFFER_OFFSET_ALIGNMENT = 0x8A34
+ ACTIVE_UNIFORM_BLOCK_MAX_NAME_LENGTH = 0x8A35
+ ACTIVE_UNIFORM_BLOCKS = 0x8A36
+ UNIFORM_TYPE = 0x8A37
+ UNIFORM_SIZE = 0x8A38
+ UNIFORM_NAME_LENGTH = 0x8A39
+ UNIFORM_BLOCK_INDEX = 0x8A3A
+ UNIFORM_OFFSET = 0x8A3B
+ UNIFORM_ARRAY_STRIDE = 0x8A3C
+ UNIFORM_MATRIX_STRIDE = 0x8A3D
+ UNIFORM_IS_ROW_MAJOR = 0x8A3E
+ UNIFORM_BLOCK_BINDING = 0x8A3F
+ UNIFORM_BLOCK_DATA_SIZE = 0x8A40
+ UNIFORM_BLOCK_NAME_LENGTH = 0x8A41
+ UNIFORM_BLOCK_ACTIVE_UNIFORMS = 0x8A42
+ UNIFORM_BLOCK_ACTIVE_UNIFORM_INDICES = 0x8A43
+ UNIFORM_BLOCK_REFERENCED_BY_VERTEX_SHADER = 0x8A44
+ UNIFORM_BLOCK_REFERENCED_BY_GEOMETRY_SHADER = 0x8A45
+ UNIFORM_BLOCK_REFERENCED_BY_FRAGMENT_SHADER = 0x8A46
+ FRAGMENT_SHADER = 0x8B30
+ VERTEX_SHADER = 0x8B31
+ MAX_FRAGMENT_UNIFORM_COMPONENTS = 0x8B49
+ MAX_VERTEX_UNIFORM_COMPONENTS = 0x8B4A
+ MAX_VARYING_FLOATS = 0x8B4B
+ MAX_VARYING_COMPONENTS = 0x8B4B
+ MAX_VERTEX_TEXTURE_IMAGE_UNITS = 0x8B4C
+ MAX_COMBINED_TEXTURE_IMAGE_UNITS = 0x8B4D
+ SHADER_TYPE = 0x8B4F
+ FLOAT_VEC2 = 0x8B50
+ FLOAT_VEC3 = 0x8B51
+ FLOAT_VEC4 = 0x8B52
+ INT_VEC2 = 0x8B53
+ INT_VEC3 = 0x8B54
+ INT_VEC4 = 0x8B55
+ BOOL = 0x8B56
+ BOOL_VEC2 = 0x8B57
+ BOOL_VEC3 = 0x8B58
+ BOOL_VEC4 = 0x8B59
+ FLOAT_MAT2 = 0x8B5A
+ FLOAT_MAT3 = 0x8B5B
+ FLOAT_MAT4 = 0x8B5C
+ SAMPLER_1D = 0x8B5D
+ SAMPLER_2D = 0x8B5E
+ SAMPLER_3D = 0x8B5F
+ SAMPLER_CUBE = 0x8B60
+ SAMPLER_1D_SHADOW = 0x8B61
+ SAMPLER_2D_SHADOW = 0x8B62
+ SAMPLER_2D_RECT = 0x8B63
+ SAMPLER_2D_RECT_SHADOW = 0x8B64
+ FLOAT_MAT2x3 = 0x8B65
+ FLOAT_MAT2x4 = 0x8B66
+ FLOAT_MAT3x2 = 0x8B67
+ FLOAT_MAT3x4 = 0x8B68
+ FLOAT_MAT4x2 = 0x8B69
+ FLOAT_MAT4x3 = 0x8B6A
+ DELETE_STATUS = 0x8B80
+ COMPILE_STATUS = 0x8B81
+ LINK_STATUS = 0x8B82
+ VALIDATE_STATUS = 0x8B83
+ INFO_LOG_LENGTH = 0x8B84
+ ATTACHED_SHADERS = 0x8B85
+ ACTIVE_UNIFORMS = 0x8B86
+ ACTIVE_UNIFORM_MAX_LENGTH = 0x8B87
+ SHADER_SOURCE_LENGTH = 0x8B88
+ ACTIVE_ATTRIBUTES = 0x8B89
+ ACTIVE_ATTRIBUTE_MAX_LENGTH = 0x8B8A
+ SHADING_LANGUAGE_VERSION = 0x8B8C
+ CURRENT_PROGRAM = 0x8B8D
+ TEXTURE_RED_TYPE = 0x8C10
+ TEXTURE_GREEN_TYPE = 0x8C11
+ TEXTURE_BLUE_TYPE = 0x8C12
+ TEXTURE_ALPHA_TYPE = 0x8C13
+ TEXTURE_DEPTH_TYPE = 0x8C16
+ UNSIGNED_NORMALIZED = 0x8C17
+ TEXTURE_1D_ARRAY = 0x8C18
+ PROXY_TEXTURE_1D_ARRAY = 0x8C19
+ TEXTURE_2D_ARRAY = 0x8C1A
+ PROXY_TEXTURE_2D_ARRAY = 0x8C1B
+ TEXTURE_BINDING_1D_ARRAY = 0x8C1C
+ TEXTURE_BINDING_2D_ARRAY = 0x8C1D
+ TEXTURE_BUFFER = 0x8C2A
+ MAX_TEXTURE_BUFFER_SIZE = 0x8C2B
+ TEXTURE_BINDING_BUFFER = 0x8C2C
+ TEXTURE_BUFFER_DATA_STORE_BINDING = 0x8C2D
+ R11F_G11F_B10F = 0x8C3A
+ UNSIGNED_INT_10F_11F_11F_REV = 0x8C3B
+ RGB9_E5 = 0x8C3D
+ UNSIGNED_INT_5_9_9_9_REV = 0x8C3E
+ TEXTURE_SHARED_SIZE = 0x8C3F
+ SRGB = 0x8C40
+ SRGB8 = 0x8C41
+ SRGB_ALPHA = 0x8C42
+ SRGB8_ALPHA8 = 0x8C43
+ SLUMINANCE_ALPHA = 0x8C44
+ SLUMINANCE8_ALPHA8 = 0x8C45
+ SLUMINANCE = 0x8C46
+ SLUMINANCE8 = 0x8C47
+ COMPRESSED_SRGB = 0x8C48
+ COMPRESSED_SRGB_ALPHA = 0x8C49
+ COMPRESSED_SLUMINANCE = 0x8C4A
+ COMPRESSED_SLUMINANCE_ALPHA = 0x8C4B
+ TRANSFORM_FEEDBACK_VARYING_MAX_LENGTH = 0x8C76
+ TRANSFORM_FEEDBACK_BUFFER_MODE = 0x8C7F
+ MAX_TRANSFORM_FEEDBACK_SEPARATE_COMPONENTS = 0x8C80
+ TRANSFORM_FEEDBACK_VARYINGS = 0x8C83
+ TRANSFORM_FEEDBACK_BUFFER_START = 0x8C84
+ TRANSFORM_FEEDBACK_BUFFER_SIZE = 0x8C85
+ PRIMITIVES_GENERATED = 0x8C87
+ TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN = 0x8C88
+ RASTERIZER_DISCARD = 0x8C89
+ MAX_TRANSFORM_FEEDBACK_INTERLEAVED_COMPONENTS = 0x8C8A
+ MAX_TRANSFORM_FEEDBACK_SEPARATE_ATTRIBS = 0x8C8B
+ INTERLEAVED_ATTRIBS = 0x8C8C
+ SEPARATE_ATTRIBS = 0x8C8D
+ TRANSFORM_FEEDBACK_BUFFER = 0x8C8E
+ TRANSFORM_FEEDBACK_BUFFER_BINDING = 0x8C8F
+ POINT_SPRITE_COORD_ORIGIN = 0x8CA0
+ LOWER_LEFT = 0x8CA1
+ UPPER_LEFT = 0x8CA2
+ STENCIL_BACK_REF = 0x8CA3
+ STENCIL_BACK_VALUE_MASK = 0x8CA4
+ STENCIL_BACK_WRITEMASK = 0x8CA5
+ DRAW_FRAMEBUFFER_BINDING = 0x8CA6
+ FRAMEBUFFER_BINDING = 0x8CA6
+ RENDERBUFFER_BINDING = 0x8CA7
+ READ_FRAMEBUFFER = 0x8CA8
+ DRAW_FRAMEBUFFER = 0x8CA9
+ READ_FRAMEBUFFER_BINDING = 0x8CAA
+ RENDERBUFFER_SAMPLES = 0x8CAB
+ DEPTH_COMPONENT32F = 0x8CAC
+ DEPTH32F_STENCIL8 = 0x8CAD
+ FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE = 0x8CD0
+ FRAMEBUFFER_ATTACHMENT_OBJECT_NAME = 0x8CD1
+ FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL = 0x8CD2
+ FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE = 0x8CD3
+ FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER = 0x8CD4
+ FRAMEBUFFER_COMPLETE = 0x8CD5
+ FRAMEBUFFER_INCOMPLETE_ATTACHMENT = 0x8CD6
+ FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT = 0x8CD7
+ FRAMEBUFFER_INCOMPLETE_DRAW_BUFFER = 0x8CDB
+ FRAMEBUFFER_INCOMPLETE_READ_BUFFER = 0x8CDC
+ FRAMEBUFFER_UNSUPPORTED = 0x8CDD
+ MAX_COLOR_ATTACHMENTS = 0x8CDF
+ COLOR_ATTACHMENT0 = 0x8CE0
+ COLOR_ATTACHMENT1 = 0x8CE1
+ COLOR_ATTACHMENT2 = 0x8CE2
+ COLOR_ATTACHMENT3 = 0x8CE3
+ COLOR_ATTACHMENT4 = 0x8CE4
+ COLOR_ATTACHMENT5 = 0x8CE5
+ COLOR_ATTACHMENT6 = 0x8CE6
+ COLOR_ATTACHMENT7 = 0x8CE7
+ COLOR_ATTACHMENT8 = 0x8CE8
+ COLOR_ATTACHMENT9 = 0x8CE9
+ COLOR_ATTACHMENT10 = 0x8CEA
+ COLOR_ATTACHMENT11 = 0x8CEB
+ COLOR_ATTACHMENT12 = 0x8CEC
+ COLOR_ATTACHMENT13 = 0x8CED
+ COLOR_ATTACHMENT14 = 0x8CEE
+ COLOR_ATTACHMENT15 = 0x8CEF
+ DEPTH_ATTACHMENT = 0x8D00
+ STENCIL_ATTACHMENT = 0x8D20
+ FRAMEBUFFER = 0x8D40
+ RENDERBUFFER = 0x8D41
+ RENDERBUFFER_WIDTH = 0x8D42
+ RENDERBUFFER_HEIGHT = 0x8D43
+ RENDERBUFFER_INTERNAL_FORMAT = 0x8D44
+ STENCIL_INDEX1 = 0x8D46
+ STENCIL_INDEX4 = 0x8D47
+ STENCIL_INDEX8 = 0x8D48
+ STENCIL_INDEX16 = 0x8D49
+ RENDERBUFFER_RED_SIZE = 0x8D50
+ RENDERBUFFER_GREEN_SIZE = 0x8D51
+ RENDERBUFFER_BLUE_SIZE = 0x8D52
+ RENDERBUFFER_ALPHA_SIZE = 0x8D53
+ RENDERBUFFER_DEPTH_SIZE = 0x8D54
+ RENDERBUFFER_STENCIL_SIZE = 0x8D55
+ FRAMEBUFFER_INCOMPLETE_MULTISAMPLE = 0x8D56
+ MAX_SAMPLES = 0x8D57
+ RGBA32UI = 0x8D70
+ RGB32UI = 0x8D71
+ RGBA16UI = 0x8D76
+ RGB16UI = 0x8D77
+ RGBA8UI = 0x8D7C
+ RGB8UI = 0x8D7D
+ RGBA32I = 0x8D82
+ RGB32I = 0x8D83
+ RGBA16I = 0x8D88
+ RGB16I = 0x8D89
+ RGBA8I = 0x8D8E
+ RGB8I = 0x8D8F
+ RED_INTEGER = 0x8D94
+ GREEN_INTEGER = 0x8D95
+ BLUE_INTEGER = 0x8D96
+ ALPHA_INTEGER = 0x8D97
+ RGB_INTEGER = 0x8D98
+ RGBA_INTEGER = 0x8D99
+ BGR_INTEGER = 0x8D9A
+ BGRA_INTEGER = 0x8D9B
+ FLOAT_32_UNSIGNED_INT_24_8_REV = 0x8DAD
+ FRAMEBUFFER_SRGB = 0x8DB9
+ COMPRESSED_RED_RGTC1 = 0x8DBB
+ COMPRESSED_SIGNED_RED_RGTC1 = 0x8DBC
+ COMPRESSED_RG_RGTC2 = 0x8DBD
+ COMPRESSED_SIGNED_RG_RGTC2 = 0x8DBE
+ SAMPLER_1D_ARRAY = 0x8DC0
+ SAMPLER_2D_ARRAY = 0x8DC1
+ SAMPLER_BUFFER = 0x8DC2
+ SAMPLER_1D_ARRAY_SHADOW = 0x8DC3
+ SAMPLER_2D_ARRAY_SHADOW = 0x8DC4
+ SAMPLER_CUBE_SHADOW = 0x8DC5
+ UNSIGNED_INT_VEC2 = 0x8DC6
+ UNSIGNED_INT_VEC3 = 0x8DC7
+ UNSIGNED_INT_VEC4 = 0x8DC8
+ INT_SAMPLER_1D = 0x8DC9
+ INT_SAMPLER_2D = 0x8DCA
+ INT_SAMPLER_3D = 0x8DCB
+ INT_SAMPLER_CUBE = 0x8DCC
+ INT_SAMPLER_2D_RECT = 0x8DCD
+ INT_SAMPLER_1D_ARRAY = 0x8DCE
+ INT_SAMPLER_2D_ARRAY = 0x8DCF
+ INT_SAMPLER_BUFFER = 0x8DD0
+ UNSIGNED_INT_SAMPLER_1D = 0x8DD1
+ UNSIGNED_INT_SAMPLER_2D = 0x8DD2
+ UNSIGNED_INT_SAMPLER_3D = 0x8DD3
+ UNSIGNED_INT_SAMPLER_CUBE = 0x8DD4
+ UNSIGNED_INT_SAMPLER_2D_RECT = 0x8DD5
+ UNSIGNED_INT_SAMPLER_1D_ARRAY = 0x8DD6
+ UNSIGNED_INT_SAMPLER_2D_ARRAY = 0x8DD7
+ UNSIGNED_INT_SAMPLER_BUFFER = 0x8DD8
+ QUERY_WAIT = 0x8E13
+ QUERY_NO_WAIT = 0x8E14
+ QUERY_BY_REGION_WAIT = 0x8E15
+ QUERY_BY_REGION_NO_WAIT = 0x8E16
+ COPY_READ_BUFFER = 0x8F36
+ COPY_WRITE_BUFFER = 0x8F37
+ R8_SNORM = 0x8F94
+ RG8_SNORM = 0x8F95
+ RGB8_SNORM = 0x8F96
+ RGBA8_SNORM = 0x8F97
+ R16_SNORM = 0x8F98
+ RG16_SNORM = 0x8F99
+ RGB16_SNORM = 0x8F9A
+ RGBA16_SNORM = 0x8F9B
+ SIGNED_NORMALIZED = 0x8F9C
+ PRIMITIVE_RESTART = 0x8F9D
+ PRIMITIVE_RESTART_INDEX = 0x8F9E
+ BUFFER_ACCESS_FLAGS = 0x911F
+ BUFFER_MAP_LENGTH = 0x9120
+ BUFFER_MAP_OFFSET = 0x9121
+)
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glViewport.xml
+func (gl *GL) Viewport(x, y, width, height int) {
+ C.gl3_1_glViewport(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// DepthRange specifies the mapping of depth values from normalized device
+// coordinates to window coordinates.
+//
+// Parameter nearVal specifies the mapping of the near clipping plane to window
+// coordinates (defaults to 0), while farVal specifies the mapping of the far
+// clipping plane to window coordinates (defaults to 1).
+//
+// After clipping and division by w, depth coordinates range from -1 to 1,
+// corresponding to the near and far clipping planes. DepthRange specifies a
+// linear mapping of the normalized depth coordinates in this range to window
+// depth coordinates. Regardless of the actual depth buffer implementation,
+// window coordinate depth values are treated as though they range from 0 through 1
+// (like color components). Thus, the values accepted by DepthRange are both
+// clamped to this range before they are accepted.
+//
+// The default setting of (0, 1) maps the near plane to 0 and the far plane to 1.
+// With this mapping, the depth buffer range is fully utilized.
+//
+// It is not necessary that nearVal be less than farVal. Reverse mappings such as
+// nearVal 1, and farVal 0 are acceptable.
+//
+// GL.INVALID_OPERATION is generated if DepthRange is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) DepthRange(nearVal, farVal float64) {
+ C.gl3_1_glDepthRange(gl.funcs, C.GLdouble(nearVal), C.GLdouble(farVal))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsEnabled.xml
+func (gl *GL) IsEnabled(cap glbase.Enum) bool {
+ glresult := C.gl3_1_glIsEnabled(gl.funcs, C.GLenum(cap))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTexLevelParameteriv.xml
+func (gl *GL) GetTexLevelParameteriv(target glbase.Enum, level int, pname glbase.Enum, params []int32) {
+ C.gl3_1_glGetTexLevelParameteriv(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTexLevelParameterfv.xml
+func (gl *GL) GetTexLevelParameterfv(target glbase.Enum, level int, pname glbase.Enum, params []float32) {
+ C.gl3_1_glGetTexLevelParameterfv(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTexParameteriv.xml
+func (gl *GL) GetTexParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl3_1_glGetTexParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTexParameterfv.xml
+func (gl *GL) GetTexParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl3_1_glGetTexParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTexImage.xml
+func (gl *GL) GetTexImage(target glbase.Enum, level int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_1_glGetTexImage(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetIntegerv.xml
+func (gl *GL) GetIntegerv(pname glbase.Enum, params []int32) {
+ C.gl3_1_glGetIntegerv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetFloatv.xml
+func (gl *GL) GetFloatv(pname glbase.Enum, params []float32) {
+ C.gl3_1_glGetFloatv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetError.xml
+func (gl *GL) GetError() glbase.Enum {
+ glresult := C.gl3_1_glGetError(gl.funcs)
+ return glbase.Enum(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetDoublev.xml
+func (gl *GL) GetDoublev(pname glbase.Enum, params []float64) {
+ C.gl3_1_glGetDoublev(gl.funcs, C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetBooleanv.xml
+func (gl *GL) GetBooleanv(pname glbase.Enum, params []bool) {
+ C.gl3_1_glGetBooleanv(gl.funcs, C.GLenum(pname), (*C.GLboolean)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glReadPixels.xml
+func (gl *GL) ReadPixels(x, y, width, height int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_1_glReadPixels(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glReadBuffer.xml
+func (gl *GL) ReadBuffer(mode glbase.Enum) {
+ C.gl3_1_glReadBuffer(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPixelStorei.xml
+func (gl *GL) PixelStorei(pname glbase.Enum, param int32) {
+ C.gl3_1_glPixelStorei(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPixelStoref.xml
+func (gl *GL) PixelStoref(pname glbase.Enum, param float32) {
+ C.gl3_1_glPixelStoref(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDepthFunc.xml
+func (gl *GL) DepthFunc(glfunc glbase.Enum) {
+ C.gl3_1_glDepthFunc(gl.funcs, C.GLenum(glfunc))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glStencilOp.xml
+func (gl *GL) StencilOp(fail, zfail, zpass glbase.Enum) {
+ C.gl3_1_glStencilOp(gl.funcs, C.GLenum(fail), C.GLenum(zfail), C.GLenum(zpass))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glStencilFunc.xml
+func (gl *GL) StencilFunc(glfunc glbase.Enum, ref int32, mask uint32) {
+ C.gl3_1_glStencilFunc(gl.funcs, C.GLenum(glfunc), C.GLint(ref), C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glLogicOp.xml
+func (gl *GL) LogicOp(opcode glbase.Enum) {
+ C.gl3_1_glLogicOp(gl.funcs, C.GLenum(opcode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBlendFunc.xml
+func (gl *GL) BlendFunc(sfactor, dfactor glbase.Enum) {
+ C.gl3_1_glBlendFunc(gl.funcs, C.GLenum(sfactor), C.GLenum(dfactor))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFlush.xml
+func (gl *GL) Flush() {
+ C.gl3_1_glFlush(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFinish.xml
+func (gl *GL) Finish() {
+ C.gl3_1_glFinish(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEnable.xml
+func (gl *GL) Enable(cap glbase.Enum) {
+ C.gl3_1_glEnable(gl.funcs, C.GLenum(cap))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDisable.xml
+func (gl *GL) Disable(cap glbase.Enum) {
+ C.gl3_1_glDisable(gl.funcs, C.GLenum(cap))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDepthMask.xml
+func (gl *GL) DepthMask(flag bool) {
+ C.gl3_1_glDepthMask(gl.funcs, *(*C.GLboolean)(unsafe.Pointer(&flag)))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColorMask.xml
+func (gl *GL) ColorMask(red, green, blue, alpha bool) {
+ C.gl3_1_glColorMask(gl.funcs, *(*C.GLboolean)(unsafe.Pointer(&red)), *(*C.GLboolean)(unsafe.Pointer(&green)), *(*C.GLboolean)(unsafe.Pointer(&blue)), *(*C.GLboolean)(unsafe.Pointer(&alpha)))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glStencilMask.xml
+func (gl *GL) StencilMask(mask uint32) {
+ C.gl3_1_glStencilMask(gl.funcs, C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClearDepth.xml
+func (gl *GL) ClearDepth(depth float64) {
+ C.gl3_1_glClearDepth(gl.funcs, C.GLdouble(depth))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClearStencil.xml
+func (gl *GL) ClearStencil(s int32) {
+ C.gl3_1_glClearStencil(gl.funcs, C.GLint(s))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClearColor.xml
+func (gl *GL) ClearColor(red, green, blue, alpha float32) {
+ C.gl3_1_glClearColor(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClear.xml
+func (gl *GL) Clear(mask glbase.Bitfield) {
+ C.gl3_1_glClear(gl.funcs, C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDrawBuffer.xml
+func (gl *GL) DrawBuffer(mode glbase.Enum) {
+ C.gl3_1_glDrawBuffer(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexImage2D.xml
+func (gl *GL) TexImage2D(target glbase.Enum, level int, internalFormat int32, width, height, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_1_glTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexImage1D.xml
+func (gl *GL) TexImage1D(target glbase.Enum, level int, internalFormat int32, width, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_1_glTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexParameteriv.xml
+func (gl *GL) TexParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl3_1_glTexParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexParameteri.xml
+func (gl *GL) TexParameteri(target, pname glbase.Enum, param int32) {
+ C.gl3_1_glTexParameteri(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexParameterfv.xml
+func (gl *GL) TexParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl3_1_glTexParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexParameterf.xml
+func (gl *GL) TexParameterf(target, pname glbase.Enum, param float32) {
+ C.gl3_1_glTexParameterf(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glScissor.xml
+func (gl *GL) Scissor(x, y, width, height int) {
+ C.gl3_1_glScissor(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPolygonMode.xml
+func (gl *GL) PolygonMode(face, mode glbase.Enum) {
+ C.gl3_1_glPolygonMode(gl.funcs, C.GLenum(face), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPointSize.xml
+func (gl *GL) PointSize(size float32) {
+ C.gl3_1_glPointSize(gl.funcs, C.GLfloat(size))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glLineWidth.xml
+func (gl *GL) LineWidth(width float32) {
+ C.gl3_1_glLineWidth(gl.funcs, C.GLfloat(width))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glHint.xml
+func (gl *GL) Hint(target, mode glbase.Enum) {
+ C.gl3_1_glHint(gl.funcs, C.GLenum(target), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFrontFace.xml
+func (gl *GL) FrontFace(mode glbase.Enum) {
+ C.gl3_1_glFrontFace(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCullFace.xml
+func (gl *GL) CullFace(mode glbase.Enum) {
+ C.gl3_1_glCullFace(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIndexubv.xml
+func (gl *GL) Indexubv(c []uint8) {
+ C.gl3_1_glIndexubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIndexub.xml
+func (gl *GL) Indexub(c uint8) {
+ C.gl3_1_glIndexub(gl.funcs, C.GLubyte(c))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsTexture.xml
+func (gl *GL) IsTexture(texture glbase.Texture) bool {
+ glresult := C.gl3_1_glIsTexture(gl.funcs, C.GLuint(texture))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// GenTextures returns n texture names in textures. There is no guarantee
+// that the names form a contiguous set of integers; however, it is
+// guaranteed that none of the returned names was in use immediately before
+// the call to GenTextures.
+//
+// The generated textures have no dimensionality; they assume the
+// dimensionality of the texture target to which they are first bound (see
+// BindTexture).
+//
+// Texture names returned by a call to GenTextures are not returned by
+// subsequent calls, unless they are first deleted with DeleteTextures.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// GenTextures is available in GL version 2.0 or greater.
+func (gl *GL) GenTextures(n int) []glbase.Texture {
+ if n == 0 {
+ return nil
+ }
+ textures := make([]glbase.Texture, n)
+ C.gl3_1_glGenTextures(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])))
+ return textures
+}
+
+// DeleteTextures deletes the textures objects whose names are stored
+// in the textures slice. After a texture is deleted, it has no contents or
+// dimensionality, and its name is free for reuse (for example by
+// GenTextures). If a texture that is currently bound is deleted, the binding
+// reverts to 0 (the default texture).
+//
+// DeleteTextures silently ignores 0's and names that do not correspond to
+// existing textures.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// DeleteTextures is available in GL version 2.0 or greater.
+func (gl *GL) DeleteTextures(textures []glbase.Texture) {
+ n := len(textures)
+ if n == 0 {
+ return
+ }
+ C.gl3_1_glDeleteTextures(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBindTexture.xml
+func (gl *GL) BindTexture(target glbase.Enum, texture glbase.Texture) {
+ C.gl3_1_glBindTexture(gl.funcs, C.GLenum(target), C.GLuint(texture))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexSubImage2D.xml
+func (gl *GL) TexSubImage2D(target glbase.Enum, level, xoffset, yoffset, width, height int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_1_glTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexSubImage1D.xml
+func (gl *GL) TexSubImage1D(target glbase.Enum, level, xoffset, width int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_1_glTexSubImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLsizei(width), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCopyTexSubImage2D.xml
+func (gl *GL) CopyTexSubImage2D(target glbase.Enum, level, xoffset, yoffset, x, y, width, height int) {
+ C.gl3_1_glCopyTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCopyTexSubImage1D.xml
+func (gl *GL) CopyTexSubImage1D(target glbase.Enum, level, xoffset, x, y, width int) {
+ C.gl3_1_glCopyTexSubImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(x), C.GLint(y), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCopyTexImage2D.xml
+func (gl *GL) CopyTexImage2D(target glbase.Enum, level int, internalFormat glbase.Enum, x, y, width, height, border int) {
+ C.gl3_1_glCopyTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height), C.GLint(border))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCopyTexImage1D.xml
+func (gl *GL) CopyTexImage1D(target glbase.Enum, level int, internalFormat glbase.Enum, x, y, width, border int) {
+ C.gl3_1_glCopyTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLint(border))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPolygonOffset.xml
+func (gl *GL) PolygonOffset(factor, units float32) {
+ C.gl3_1_glPolygonOffset(gl.funcs, C.GLfloat(factor), C.GLfloat(units))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDrawElements.xml
+func (gl *GL) DrawElements(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_1_glDrawElements(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDrawArrays.xml
+func (gl *GL) DrawArrays(mode glbase.Enum, first, count int) {
+ C.gl3_1_glDrawArrays(gl.funcs, C.GLenum(mode), C.GLint(first), C.GLsizei(count))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCopyTexSubImage3D.xml
+func (gl *GL) CopyTexSubImage3D(target glbase.Enum, level, xoffset, yoffset int, zoffset int32, x, y, width, height int) {
+ C.gl3_1_glCopyTexSubImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(zoffset), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexSubImage3D.xml
+func (gl *GL) TexSubImage3D(target glbase.Enum, level, xoffset, yoffset int, zoffset int32, width, height int, depth int32, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_1_glTexSubImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(zoffset), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexImage3D.xml
+func (gl *GL) TexImage3D(target glbase.Enum, level int, internalFormat int32, width, height int, depth int32, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_1_glTexImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDrawRangeElements.xml
+func (gl *GL) DrawRangeElements(mode glbase.Enum, start, end uint32, count int, gltype glbase.Enum, indices interface{}) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_1_glDrawRangeElements(gl.funcs, C.GLenum(mode), C.GLuint(start), C.GLuint(end), C.GLsizei(count), C.GLenum(gltype), indices_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBlendEquation.xml
+func (gl *GL) BlendEquation(mode glbase.Enum) {
+ C.gl3_1_glBlendEquation(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBlendColor.xml
+func (gl *GL) BlendColor(red, green, blue, alpha float32) {
+ C.gl3_1_glBlendColor(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetCompressedTexImage.xml
+func (gl *GL) GetCompressedTexImage(target glbase.Enum, level int, img interface{}) {
+ var img_ptr unsafe.Pointer
+ var img_v = reflect.ValueOf(img)
+ if img != nil && img_v.Kind() != reflect.Slice {
+ panic("parameter img must be a slice")
+ }
+ if img != nil {
+ img_ptr = unsafe.Pointer(img_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_1_glGetCompressedTexImage(gl.funcs, C.GLenum(target), C.GLint(level), img_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCompressedTexSubImage1D.xml
+func (gl *GL) CompressedTexSubImage1D(target glbase.Enum, level, xoffset, width int, format glbase.Enum, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_1_glCompressedTexSubImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLsizei(width), C.GLenum(format), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCompressedTexSubImage2D.xml
+func (gl *GL) CompressedTexSubImage2D(target glbase.Enum, level, xoffset, yoffset, width, height int, format glbase.Enum, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_1_glCompressedTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCompressedTexSubImage3D.xml
+func (gl *GL) CompressedTexSubImage3D(target glbase.Enum, level, xoffset, yoffset int, zoffset int32, width, height int, depth int32, format glbase.Enum, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_1_glCompressedTexSubImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(zoffset), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLenum(format), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCompressedTexImage1D.xml
+func (gl *GL) CompressedTexImage1D(target glbase.Enum, level int, internalFormat glbase.Enum, width, border, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_1_glCompressedTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLsizei(width), C.GLint(border), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCompressedTexImage2D.xml
+func (gl *GL) CompressedTexImage2D(target glbase.Enum, level int, internalFormat glbase.Enum, width, height, border, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_1_glCompressedTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLint(border), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCompressedTexImage3D.xml
+func (gl *GL) CompressedTexImage3D(target glbase.Enum, level int, internalFormat glbase.Enum, width, height int, depth int32, border, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_1_glCompressedTexImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLint(border), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSampleCoverage.xml
+func (gl *GL) SampleCoverage(value float32, invert bool) {
+ C.gl3_1_glSampleCoverage(gl.funcs, C.GLfloat(value), *(*C.GLboolean)(unsafe.Pointer(&invert)))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glActiveTexture.xml
+func (gl *GL) ActiveTexture(texture glbase.Enum) {
+ C.gl3_1_glActiveTexture(gl.funcs, C.GLenum(texture))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPointParameteriv.xml
+func (gl *GL) PointParameteriv(pname glbase.Enum, params []int32) {
+ C.gl3_1_glPointParameteriv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPointParameteri.xml
+func (gl *GL) PointParameteri(pname glbase.Enum, param int32) {
+ C.gl3_1_glPointParameteri(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPointParameterfv.xml
+func (gl *GL) PointParameterfv(pname glbase.Enum, params []float32) {
+ C.gl3_1_glPointParameterfv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPointParameterf.xml
+func (gl *GL) PointParameterf(pname glbase.Enum, param float32) {
+ C.gl3_1_glPointParameterf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiDrawArrays.xml
+func (gl *GL) MultiDrawArrays(mode glbase.Enum, first, count []int, drawcount int32) {
+ C.gl3_1_glMultiDrawArrays(gl.funcs, C.GLenum(mode), (*C.GLint)(unsafe.Pointer(&first[0])), (*C.GLsizei)(unsafe.Pointer(&count[0])), C.GLsizei(drawcount))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBlendFuncSeparate.xml
+func (gl *GL) BlendFuncSeparate(sfactorRGB, dfactorRGB, sfactorAlpha, dfactorAlpha glbase.Enum) {
+ C.gl3_1_glBlendFuncSeparate(gl.funcs, C.GLenum(sfactorRGB), C.GLenum(dfactorRGB), C.GLenum(sfactorAlpha), C.GLenum(dfactorAlpha))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetBufferParameteriv.xml
+func (gl *GL) GetBufferParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl3_1_glGetBufferParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glUnmapBuffer.xml
+func (gl *GL) UnmapBuffer(target glbase.Enum) bool {
+ glresult := C.gl3_1_glUnmapBuffer(gl.funcs, C.GLenum(target))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetBufferSubData.xml
+func (gl *GL) GetBufferSubData(target glbase.Enum, offset, size int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_1_glGetBufferSubData(gl.funcs, C.GLenum(target), C.GLintptr(offset), C.GLsizeiptr(size), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBufferSubData.xml
+func (gl *GL) BufferSubData(target glbase.Enum, offset, size int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_1_glBufferSubData(gl.funcs, C.GLenum(target), C.GLintptr(offset), C.GLsizeiptr(size), data_ptr)
+}
+
+// BufferData creates a new data store for the buffer object currently
+// bound to target. Any pre-existing data store is deleted. The new data
+// store is created with the specified size in bytes and usage. If data is
+// not nil, it must be a slice that is used to initialize the data store.
+// In that case the size parameter is ignored and the store size will match
+// the slice data size.
+//
+// In its initial state, the new data store is not mapped, it has a NULL
+// mapped pointer, and its mapped access is GL.READ_WRITE.
+//
+// The target constant must be one of GL.ARRAY_BUFFER, GL.COPY_READ_BUFFER,
+// GL.COPY_WRITE_BUFFER, GL.ELEMENT_ARRAY_BUFFER, GL.PIXEL_PACK_BUFFER,
+// GL.PIXEL_UNPACK_BUFFER, GL.TEXTURE_BUFFER, GL.TRANSFORM_FEEDBACK_BUFFER,
+// or GL.UNIFORM_BUFFER.
+//
+// The usage parameter is a hint to the GL implementation as to how a buffer
+// object's data store will be accessed. This enables the GL implementation
+// to make more intelligent decisions that may significantly impact buffer
+// object performance. It does not, however, constrain the actual usage of
+// the data store. usage can be broken down into two parts: first, the
+// frequency of access (modification and usage), and second, the nature of
+// that access.
+//
+// A usage frequency of STREAM and nature of DRAW is specified via the
+// constant GL.STREAM_DRAW, for example.
+//
+// The usage frequency of access may be one of:
+//
+// STREAM
+// The data store contents will be modified once and used at most a few times.
+//
+// STATIC
+// The data store contents will be modified once and used many times.
+//
+// DYNAMIC
+// The data store contents will be modified repeatedly and used many times.
+//
+// The usage nature of access may be one of:
+//
+// DRAW
+// The data store contents are modified by the application, and used as
+// the source for GL drawing and image specification commands.
+//
+// READ
+// The data store contents are modified by reading data from the GL,
+// and used to return that data when queried by the application.
+//
+// COPY
+// The data store contents are modified by reading data from the GL,
+// and used as the source for GL drawing and image specification
+// commands.
+//
+// Clients must align data elements consistent with the requirements of the
+// client platform, with an additional base-level requirement that an offset
+// within a buffer to a datum comprising N bytes be a multiple of N.
+//
+// Error GL.INVALID_ENUM is generated if target is not one of the accepted
+// buffer targets. GL.INVALID_ENUM is generated if usage is not
+// GL.STREAM_DRAW, GL.STREAM_READ, GL.STREAM_COPY, GL.STATIC_DRAW,
+// GL.STATIC_READ, GL.STATIC_COPY, GL.DYNAMIC_DRAW, GL.DYNAMIC_READ, or
+// GL.DYNAMIC_COPY. GL.INVALID_VALUE is generated if size is negative.
+// GL.INVALID_OPERATION is generated if the reserved buffer object name 0 is
+// bound to target. GL.OUT_OF_MEMORY is generated if the GL is unable to
+// create a data store with the specified size.
+func (gl *GL) BufferData(target glbase.Enum, size int, data interface{}, usage glbase.Enum) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ if data != nil {
+ size = int(data_v.Type().Size()) * data_v.Len()
+ }
+ C.gl3_1_glBufferData(gl.funcs, C.GLenum(target), C.GLsizeiptr(size), data_ptr, C.GLenum(usage))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsBuffer.xml
+func (gl *GL) IsBuffer(buffer glbase.Buffer) bool {
+ glresult := C.gl3_1_glIsBuffer(gl.funcs, C.GLuint(buffer))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// GenBuffers returns n buffer object names. There is no guarantee that
+// the names form a contiguous set of integers; however, it is guaranteed
+// that none of the returned names was in use immediately before the call to
+// GenBuffers.
+//
+// Buffer object names returned by a call to GenBuffers are not returned by
+// subsequent calls, unless they are first deleted with DeleteBuffers.
+//
+// No buffer objects are associated with the returned buffer object names
+// until they are first bound by calling BindBuffer.
+//
+// Error GL.INVALID_VALUE is generated if n is negative. GL.INVALID_OPERATION
+// is generated if GenBuffers is executed between the execution of Begin
+// and the corresponding execution of End.
+//
+// GenBuffers is available in GL version 1.5 or greater.
+func (gl *GL) GenBuffers(n int) []glbase.Buffer {
+ if n == 0 {
+ return nil
+ }
+ buffers := make([]glbase.Buffer, n)
+ C.gl3_1_glGenBuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&buffers[0])))
+ return buffers
+}
+
+// DeleteBuffers deletes the buffer objects whose names are stored in the
+// buffers slice.
+//
+// After a buffer object is deleted, it has no contents, and its name is free
+// for reuse (for example by GenBuffers). If a buffer object that is
+// currently bound is deleted, the binding reverts to 0 (the absence of any
+// buffer object, which reverts to client memory usage).
+//
+// DeleteBuffers silently ignores 0's and names that do not correspond to
+// existing buffer objects.
+//
+// Error GL.INVALID_VALUE is generated if n is negative. GL.INVALID_OPERATION
+// is generated if DeleteBuffers is executed between the execution of Begin
+// and the corresponding execution of End.
+//
+// DeleteBuffers is available in GL version 1.5 or greater.
+func (gl *GL) DeleteBuffers(buffers []glbase.Buffer) {
+ n := len(buffers)
+ if n == 0 {
+ return
+ }
+ C.gl3_1_glDeleteBuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&buffers[0])))
+}
+
+// BindBuffer creates or puts in use a named buffer object.
+// Calling BindBuffer with target set to GL.ARRAY_BUFFER,
+// GL.ELEMENT_ARRAY_BUFFER, GL.PIXEL_PACK_BUFFER or GL.PIXEL_UNPACK_BUFFER
+// and buffer set to the name of the new buffer object binds the buffer
+// object name to the target. When a buffer object is bound to a target, the
+// previous binding for that target is automatically broken.
+//
+// Buffer object names are unsigned integers. The value zero is reserved, but
+// there is no default buffer object for each buffer object target. Instead,
+// buffer set to zero effectively unbinds any buffer object previously bound,
+// and restores client memory usage for that buffer object target. Buffer
+// object names and the corresponding buffer object contents are local to the
+// shared display-list space (see XCreateContext) of the current GL rendering
+// context; two rendering contexts share buffer object names only if they
+// also share display lists.
+//
+// GenBuffers may be called to generate a set of new buffer object names.
+//
+// The state of a buffer object immediately after it is first bound is an
+// unmapped zero-sized memory buffer with GL.READ_WRITE access and
+// GL.STATIC_DRAW usage.
+//
+// While a non-zero buffer object name is bound, GL operations on the target
+// to which it is bound affect the bound buffer object, and queries of the
+// target to which it is bound return state from the bound buffer object.
+// While buffer object name zero is bound, as in the initial state, attempts
+// to modify or query state on the target to which it is bound generates an
+// GL.INVALID_OPERATION error.
+//
+// When vertex array pointer state is changed, for example by a call to
+// NormalPointer, the current buffer object binding (GL.ARRAY_BUFFER_BINDING)
+// is copied into the corresponding client state for the vertex array type
+// being changed, for example GL.NORMAL_ARRAY_BUFFER_BINDING. While a
+// non-zero buffer object is bound to the GL.ARRAY_BUFFER target, the vertex
+// array pointer parameter that is traditionally interpreted as a pointer to
+// client-side memory is instead interpreted as an offset within the buffer
+// object measured in basic machine units.
+//
+// While a non-zero buffer object is bound to the GL.ELEMENT_ARRAY_BUFFER
+// target, the indices parameter of DrawElements, DrawRangeElements, or
+// MultiDrawElements that is traditionally interpreted as a pointer to
+// client-side memory is instead interpreted as an offset within the buffer
+// object measured in basic machine units.
+//
+// While a non-zero buffer object is bound to the GL.PIXEL_PACK_BUFFER
+// target, the following commands are affected: GetCompressedTexImage,
+// GetConvolutionFilter, GetHistogram, GetMinmax, GetPixelMap,
+// GetPolygonStipple, GetSeparableFilter, GetTexImage, and ReadPixels. The
+// pointer parameter that is traditionally interpreted as a pointer to
+// client-side memory where the pixels are to be packed is instead
+// interpreted as an offset within the buffer object measured in basic
+// machine units.
+//
+// While a non-zero buffer object is bound to the GL.PIXEL_UNPACK_BUFFER
+// target, the following commands are affected: Bitmap, ColorSubTable,
+// ColorTable, CompressedTexImage1D, CompressedTexImage2D,
+// CompressedTexImage3D, CompressedTexSubImage1D, CompressedTexSubImage2D,
+// CompressedTexSubImage3D, ConvolutionFilter1D, ConvolutionFilter2D,
+// DrawPixels, PixelMap, PolygonStipple, SeparableFilter2D, TexImage1D,
+// TexImage2D, TexImage3D, TexSubImage1D, TexSubImage2D, and TexSubImage3D.
+// The pointer parameter that is traditionally interpreted as a pointer to
+// client-side memory from which the pixels are to be unpacked is instead
+// interpreted as an offset within the buffer object measured in basic
+// machine units.
+//
+// A buffer object binding created with BindBuffer remains active until a
+// different buffer object name is bound to the same target, or until the
+// bound buffer object is deleted with DeleteBuffers.
+//
+// Once created, a named buffer object may be re-bound to any target as often
+// as needed. However, the GL implementation may make choices about how to
+// optimize the storage of a buffer object based on its initial binding
+// target.
+//
+// Error GL.INVALID_ENUM is generated if target is not one of the allowable
+// values. GL.INVALID_OPERATION is generated if BindBuffer is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// BindBuffer is available in GL version 1.5 or greater.
+func (gl *GL) BindBuffer(target glbase.Enum, buffer glbase.Buffer) {
+ C.gl3_1_glBindBuffer(gl.funcs, C.GLenum(target), C.GLuint(buffer))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetQueryObjectuiv.xml
+func (gl *GL) GetQueryObjectuiv(id uint32, pname glbase.Enum, params []uint32) {
+ C.gl3_1_glGetQueryObjectuiv(gl.funcs, C.GLuint(id), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetQueryObjectiv.xml
+func (gl *GL) GetQueryObjectiv(id uint32, pname glbase.Enum, params []int32) {
+ C.gl3_1_glGetQueryObjectiv(gl.funcs, C.GLuint(id), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetQueryiv.xml
+func (gl *GL) GetQueryiv(target, pname glbase.Enum, params []int32) {
+ C.gl3_1_glGetQueryiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEndQuery.xml
+func (gl *GL) EndQuery(target glbase.Enum) {
+ C.gl3_1_glEndQuery(gl.funcs, C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBeginQuery.xml
+func (gl *GL) BeginQuery(target glbase.Enum, id uint32) {
+ C.gl3_1_glBeginQuery(gl.funcs, C.GLenum(target), C.GLuint(id))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsQuery.xml
+func (gl *GL) IsQuery(id uint32) bool {
+ glresult := C.gl3_1_glIsQuery(gl.funcs, C.GLuint(id))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDeleteQueries.xml
+func (gl *GL) DeleteQueries(n int, ids []uint32) {
+ C.gl3_1_glDeleteQueries(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&ids[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGenQueries.xml
+func (gl *GL) GenQueries(n int, ids []uint32) {
+ C.gl3_1_glGenQueries(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&ids[0])))
+}
+
+// VertexAttribPointer specifies the location and data format of the array
+// of generic vertex attributes at index to use when rendering. size
+// specifies the number of components per attribute and must be 1, 2, 3, or
+// 4. type specifies the data type of each component, and stride specifies
+// the byte stride from one attribute to the next, allowing vertices and
+// attributes to be packed into a single array or stored in separate arrays.
+// normalized indicates whether the values stored in an integer format are
+// to be mapped to the range [-1,1] (for signed values) or [0,1]
+// (for unsigned values) when they are accessed and converted to floating
+// point; otherwise, values will be converted to floats directly without
+// normalization. offset is a byte offset into the buffer object's data
+// store, which must be bound to the GL.ARRAY_BUFFER target with BindBuffer.
+//
+// The buffer object binding (GL.ARRAY_BUFFER_BINDING) is saved as
+// generic vertex attribute array client-side state
+// (GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING) for the provided index.
+//
+// To enable and disable a generic vertex attribute array, call
+// EnableVertexAttribArray and DisableVertexAttribArray with index. If
+// enabled, the generic vertex attribute array is used when DrawArrays or
+// DrawElements is called. Each generic vertex attribute array is initially
+// disabled.
+//
+// VertexAttribPointer is typically implemented on the client side.
+//
+// Error GL.INVALID_ENUM is generated if type is not an accepted value.
+// GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_VALUE is generated if size is not 1, 2,
+// 3, or 4. GL.INVALID_VALUE is generated if stride is negative.
+func (gl *GL) VertexAttribPointer(index glbase.Attrib, size int, gltype glbase.Enum, normalized bool, stride int, offset uintptr) {
+ offset_ptr := unsafe.Pointer(offset)
+ C.gl3_1_glVertexAttribPointer(gl.funcs, C.GLuint(index), C.GLint(size), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), C.GLsizei(stride), offset_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glValidateProgram.xml
+func (gl *GL) ValidateProgram(program glbase.Program) {
+ C.gl3_1_glValidateProgram(gl.funcs, C.GLuint(program))
+}
+
+// UniformMatrix4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix4fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(4*4) != 0 {
+ panic("invalid value length for UniformMatrix4fv")
+ }
+ count := len(value) / (4 * 4)
+ C.gl3_1_glUniformMatrix4fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix3fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(3*3) != 0 {
+ panic("invalid value length for UniformMatrix3fv")
+ }
+ count := len(value) / (3 * 3)
+ C.gl3_1_glUniformMatrix3fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix2fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(2*2) != 0 {
+ panic("invalid value length for UniformMatrix2fv")
+ }
+ count := len(value) / (2 * 2)
+ C.gl3_1_glUniformMatrix2fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform4iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%4 != 0 {
+ panic("invalid value length for Uniform4iv")
+ }
+ count := len(value) / 4
+ C.gl3_1_glUniform4iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform3iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform3iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%3 != 0 {
+ panic("invalid value length for Uniform3iv")
+ }
+ count := len(value) / 3
+ C.gl3_1_glUniform3iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform2iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform2iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%2 != 0 {
+ panic("invalid value length for Uniform2iv")
+ }
+ count := len(value) / 2
+ C.gl3_1_glUniform2iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform1iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform1iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ count := len(value)
+ C.gl3_1_glUniform1iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%4 != 0 {
+ panic("invalid value length for Uniform4fv")
+ }
+ count := len(value) / 4
+ C.gl3_1_glUniform4fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%3 != 0 {
+ panic("invalid value length for Uniform3fv")
+ }
+ count := len(value) / 3
+ C.gl3_1_glUniform3fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%2 != 0 {
+ panic("invalid value length for Uniform2fv")
+ }
+ count := len(value) / 2
+ C.gl3_1_glUniform2fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform1fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform1fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ count := len(value)
+ C.gl3_1_glUniform1fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform4i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4i(location glbase.Uniform, v0, v1, v2, v3 int32) {
+ C.gl3_1_glUniform4i(gl.funcs, C.GLint(location), C.GLint(v0), C.GLint(v1), C.GLint(v2), C.GLint(v3))
+}
+
+// Uniform3i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform3i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3i(location glbase.Uniform, v0, v1, v2 int32) {
+ C.gl3_1_glUniform3i(gl.funcs, C.GLint(location), C.GLint(v0), C.GLint(v1), C.GLint(v2))
+}
+
+// Uniform2i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform2i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2i(location glbase.Uniform, v0, v1 int32) {
+ C.gl3_1_glUniform2i(gl.funcs, C.GLint(location), C.GLint(v0), C.GLint(v1))
+}
+
+// Uniform1i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform1i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1i(location glbase.Uniform, v0 int32) {
+ C.gl3_1_glUniform1i(gl.funcs, C.GLint(location), C.GLint(v0))
+}
+
+// Uniform4f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform4f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4f(location glbase.Uniform, v0, v1, v2, v3 float32) {
+ C.gl3_1_glUniform4f(gl.funcs, C.GLint(location), C.GLfloat(v0), C.GLfloat(v1), C.GLfloat(v2), C.GLfloat(v3))
+}
+
+// Uniform3f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform3f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3f(location glbase.Uniform, v0, v1, v2 float32) {
+ C.gl3_1_glUniform3f(gl.funcs, C.GLint(location), C.GLfloat(v0), C.GLfloat(v1), C.GLfloat(v2))
+}
+
+// Uniform2f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform2f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2f(location glbase.Uniform, v0, v1 float32) {
+ C.gl3_1_glUniform2f(gl.funcs, C.GLint(location), C.GLfloat(v0), C.GLfloat(v1))
+}
+
+// Uniform1f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform1f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1f(location glbase.Uniform, v0 float32) {
+ C.gl3_1_glUniform1f(gl.funcs, C.GLint(location), C.GLfloat(v0))
+}
+
+// UseProgram installs the program object specified by program as part of
+// current rendering state. One or more executables are created in a program
+// object by successfully attaching shader objects to it with AttachShader,
+// successfully compiling the shader objects with CompileShader, and
+// successfully linking the program object with LinkProgram.
+//
+// A program object will contain an executable that will run on the vertex
+// processor if it contains one or more shader objects of type
+// GL.VERTEX_SHADER that have been successfully compiled and linked.
+// Similarly, a program object will contain an executable that will run on
+// the fragment processor if it contains one or more shader objects of type
+// GL.FRAGMENT_SHADER that have been successfully compiled and linked.
+//
+// Successfully installing an executable on a programmable processor will
+// cause the corresponding fixed functionality of OpenGL to be disabled.
+// Specifically, if an executable is installed on the vertex processor, the
+// OpenGL fixed functionality will be disabled as follows.
+//
+// - The modelview matrix is not applied to vertex coordinates.
+//
+// - The projection matrix is not applied to vertex coordinates.
+//
+// - The texture matrices are not applied to texture coordinates.
+//
+// - Normals are not transformed to eye coordinates.
+//
+// - Normals are not rescaled or normalized.
+//
+// - Normalization of GL.AUTO_NORMAL evaluated normals is not performed.
+//
+// - Texture coordinates are not generated automatically.
+//
+// - Per-vertex lighting is not performed.
+//
+// - Color material computations are not performed.
+//
+// - Color index lighting is not performed.
+//
+// - This list also applies when setting the current raster position.
+//
+// The executable that is installed on the vertex processor is expected to
+// implement any or all of the desired functionality from the preceding list.
+// Similarly, if an executable is installed on the fragment processor, the
+// OpenGL fixed functionality will be disabled as follows.
+//
+// - Texture environment and texture functions are not applied.
+//
+// - Texture application is not applied.
+//
+// - Color sum is not applied.
+//
+// - Fog is not applied.
+//
+// Again, the fragment shader that is installed is expected to implement any
+// or all of the desired functionality from the preceding list.
+//
+// While a program object is in use, applications are free to modify attached
+// shader objects, compile attached shader objects, attach additional shader
+// objects, and detach or delete shader objects. None of these operations
+// will affect the executables that are part of the current state. However,
+// relinking the program object that is currently in use will install the
+// program object as part of the current rendering state if the link
+// operation was successful (see LinkProgram). If the program object
+// currently in use is relinked unsuccessfully, its link status will be set
+// to GL.FALSE, but the executables and associated state will remain part of
+// the current state until a subsequent call to UseProgram removes it from
+// use. After it is removed from use, it cannot be made part of current state
+// until it has been successfully relinked.
+//
+// If program contains shader objects of type GL.VERTEX_SHADER but it does
+// not contain shader objects of type GL.FRAGMENT_SHADER, an executable will
+// be installed on the vertex processor, but fixed functionality will be used
+// for fragment processing. Similarly, if program contains shader objects of
+// type GL.FRAGMENT_SHADER but it does not contain shader objects of type
+// GL.VERTEX_SHADER, an executable will be installed on the fragment
+// processor, but fixed functionality will be used for vertex processing. If
+// program is 0, the programmable processors will be disabled, and fixed
+// functionality will be used for both vertex and fragment processing.
+//
+// While a program object is in use, the state that controls the disabled
+// fixed functionality may also be updated using the normal OpenGL calls.
+//
+// Like display lists and texture objects, the name space for program objects
+// may be shared across a set of contexts, as long as the server sides of the
+// contexts share the same address space. If the name space is shared across
+// contexts, any attached objects and the data associated with those attached
+// objects are shared as well.
+//
+// Applications are responsible for providing the synchronization across API
+// calls when objects are accessed from different execution threads.
+//
+// Error GL.INVALID_VALUE is generated if program is neither 0 nor a value
+// generated by OpenGL. GL.INVALID_OPERATION is generated if program is not
+// a program object. GL.INVALID_OPERATION is generated if program could not
+// be made part of current state. GL.INVALID_OPERATION is generated if
+// UseProgram is executed between the execution of Begin and the
+// corresponding execution of End.
+//
+// UseProgram is available in GL version 2.0 or greater.
+func (gl *GL) UseProgram(program glbase.Program) {
+ C.gl3_1_glUseProgram(gl.funcs, C.GLuint(program))
+}
+
+// ShaderSource sets the source code in shader to the provided source code. Any source
+// code previously stored in the shader object is completely replaced.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader is not a shader
+// object. GL.INVALID_VALUE is generated if count is less than 0.
+// GL.INVALID_OPERATION is generated if ShaderSource is executed between the
+// execution of Begin and the corresponding execution of End.
+//
+// ShaderSource is available in GL version 2.0 or greater.
+func (gl *GL) ShaderSource(shader glbase.Shader, source ...string) {
+ count := len(source)
+ length := make([]int32, count)
+ source_c := make([]unsafe.Pointer, count)
+ for i, src := range source {
+ length[i] = int32(len(src))
+ if len(src) > 0 {
+ source_c[i] = *(*unsafe.Pointer)(unsafe.Pointer(&src))
+ } else {
+ source_c[i] = unsafe.Pointer(uintptr(0))
+ }
+ }
+ C.gl3_1_glShaderSource(gl.funcs, C.GLuint(shader), C.GLsizei(count), (**C.GLchar)(unsafe.Pointer(&source_c[0])), (*C.GLint)(unsafe.Pointer(&length[0])))
+}
+
+// LinkProgram links the program object specified by program. If any shader
+// objects of type GL.VERTEX_SHADER are attached to program, they will be
+// used to create an executable that will run on the programmable vertex
+// processor. If any shader objects of type GL.FRAGMENT_SHADER are attached
+// to program, they will be used to create an executable that will run on the
+// programmable fragment processor.
+//
+// The status of the link operation will be stored as part of the program
+// object's state. This value will be set to GL.TRUE if the program object
+// was linked without errors and is ready for use, and GL.FALSE otherwise. It
+// can be queried by calling GetProgramiv with arguments program and
+// GL.LINK_STATUS.
+//
+// As a result of a successful link operation, all active user-defined
+// uniform variables belonging to program will be initialized to 0, and each
+// of the program object's active uniform variables will be assigned a
+// location that can be queried by calling GetUniformLocation. Also, any
+// active user-defined attribute variables that have not been bound to a
+// generic vertex attribute index will be bound to one at this time.
+//
+// Linking of a program object can fail for a number of reasons as specified
+// in the OpenGL Shading Language Specification. The following lists some of
+// the conditions that will cause a link error.
+//
+// - The number of active attribute variables supported by the
+// implementation has been exceeded.
+//
+// - The storage limit for uniform variables has been exceeded.
+//
+// - The number of active uniform variables supported by the implementation
+// has been exceeded.
+//
+// - The main function is missing for the vertex shader or the fragment
+// shader.
+//
+// - A varying variable actually used in the fragment shader is not
+// declared in the same way (or is not declared at all) in the vertex
+// shader.
+//
+// - A reference to a function or variable name is unresolved.
+//
+// - A shared global is declared with two different types or two different
+// initial values.
+//
+// - One or more of the attached shader objects has not been successfully
+// compiled.
+//
+// - Binding a generic attribute matrix caused some rows of the matrix to
+// fall outside the allowed maximum of GL.MAX_VERTEX_ATTRIBS.
+//
+// - Not enough contiguous vertex attribute slots could be found to bind
+// attribute matrices.
+//
+// When a program object has been successfully linked, the program object can
+// be made part of current state by calling UseProgram. Whether or not the
+// link operation was successful, the program object's information log will
+// be overwritten. The information log can be retrieved by calling
+// GetProgramInfoLog.
+//
+// LinkProgram will also install the generated executables as part of the
+// current rendering state if the link operation was successful and the
+// specified program object is already currently in use as a result of a
+// previous call to UseProgram. If the program object currently in use is
+// relinked unsuccessfully, its link status will be set to GL.FALSE , but the
+// executables and associated state will remain part of the current state
+// until a subsequent call to UseProgram removes it from use. After it is
+// removed from use, it cannot be made part of current state until it has
+// been successfully relinked.
+//
+// If program contains shader objects of type GL.VERTEX_SHADER but does not
+// contain shader objects of type GL.FRAGMENT_SHADER, the vertex shader will
+// be linked against the implicit interface for fixed functionality fragment
+// processing. Similarly, if program contains shader objects of type
+// GL.FRAGMENT_SHADER but it does not contain shader objects of type
+// GL.VERTEX_SHADER, the fragment shader will be linked against the implicit
+// interface for fixed functionality vertex processing.
+//
+// The program object's information log is updated and the program is
+// generated at the time of the link operation. After the link operation,
+// applications are free to modify attached shader objects, compile attached
+// shader objects, detach shader objects, delete shader objects, and attach
+// additional shader objects. None of these operations affects the
+// information log or the program that is part of the program object.
+//
+// If the link operation is unsuccessful, any information about a previous
+// link operation on program is lost (a failed link does not restore the
+// old state of program). Certain information can still be retrieved
+// from program even after an unsuccessful link operation. See for instance
+// GetActiveAttrib and GetActiveUniform.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program
+// object. GL.INVALID_OPERATION is generated if LinkProgram is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// LinkProgram is available in GL version 2.0 or greater.
+func (gl *GL) LinkProgram(program glbase.Program) {
+ C.gl3_1_glLinkProgram(gl.funcs, C.GLuint(program))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsShader.xml
+func (gl *GL) IsShader(shader glbase.Shader) bool {
+ glresult := C.gl3_1_glIsShader(gl.funcs, C.GLuint(shader))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsProgram.xml
+func (gl *GL) IsProgram(program glbase.Program) bool {
+ glresult := C.gl3_1_glIsProgram(gl.funcs, C.GLuint(program))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// GetVertexAttribiv returns in params the value of a generic vertex attribute
+// parameter. The generic vertex attribute to be queried is specified by
+// index, and the parameter to be queried is specified by pname.
+//
+// The accepted parameter names are as follows:
+//
+// GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING
+// params returns a single value, the name of the buffer object
+// currently bound to the binding point corresponding to generic vertex
+// attribute array index. If no buffer object is bound, 0 is returned.
+// The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_ENABLED
+// params returns a single value that is non-zero (true) if the vertex
+// attribute array for index is enabled and 0 (false) if it is
+// disabled. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_SIZE
+// params returns a single value, the size of the vertex attribute
+// array for index. The size is the number of values for each element
+// of the vertex attribute array, and it will be 1, 2, 3, or 4. The
+// initial value is 4.
+//
+// GL.VERTEX_ATTRIB_ARRAY_STRIDE
+// params returns a single value, the array stride for (number of bytes
+// between successive elements in) the vertex attribute array for
+// index. A value of 0 indicates that the array elements are stored
+// sequentially in memory. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_TYPE
+// params returns a single value, a symbolic constant indicating the
+// array type for the vertex attribute array for index. Possible values
+// are GL.BYTE, GL.UNSIGNED_BYTE, GL.SHORT, GL.UNSIGNED_SHORT, GL.INT,
+// GL.UNSIGNED_INT, GL.FLOAT, and GL.DOUBLE. The initial value is
+// GL.FLOAT.
+//
+// GL.VERTEX_ATTRIB_ARRAY_NORMALIZED
+// params returns a single value that is non-zero (true) if fixed-point
+// data types for the vertex attribute array indicated by index are
+// normalized when they are converted to floating point, and 0 (false)
+// otherwise. The initial value is 0.
+//
+// GL.CURRENT_VERTEX_ATTRIB
+// params returns four values that represent the current value for the
+// generic vertex attribute specified by index. Generic vertex
+// attribute 0 is unique in that it has no current state, so an error
+// will be generated if index is 0. The initial value for all other
+// generic vertex attributes is (0,0,0,1).
+//
+// All of the parameters except GL.CURRENT_VERTEX_ATTRIB represent
+// client-side state.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_ENUM is generated if pname is not an
+// accepted value. GL.INVALID_OPERATION is generated if index is 0 and pname
+// is GL.CURRENT_VERTEX_ATTRIB.
+//
+// GetVertexAttribiv is available in GL version 2.0 or greater.
+func (gl *GL) GetVertexAttribiv(index glbase.Attrib, pname glbase.Enum, params []int32) {
+ var params_c [4]int32
+ C.gl3_1_glGetVertexAttribiv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetVertexAttribfv returns in params the value of a generic vertex attribute
+// parameter. The generic vertex attribute to be queried is specified by
+// index, and the parameter to be queried is specified by pname.
+//
+// The accepted parameter names are as follows:
+//
+// GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING
+// params returns a single value, the name of the buffer object
+// currently bound to the binding point corresponding to generic vertex
+// attribute array index. If no buffer object is bound, 0 is returned.
+// The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_ENABLED
+// params returns a single value that is non-zero (true) if the vertex
+// attribute array for index is enabled and 0 (false) if it is
+// disabled. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_SIZE
+// params returns a single value, the size of the vertex attribute
+// array for index. The size is the number of values for each element
+// of the vertex attribute array, and it will be 1, 2, 3, or 4. The
+// initial value is 4.
+//
+// GL.VERTEX_ATTRIB_ARRAY_STRIDE
+// params returns a single value, the array stride for (number of bytes
+// between successive elements in) the vertex attribute array for
+// index. A value of 0 indicates that the array elements are stored
+// sequentially in memory. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_TYPE
+// params returns a single value, a symbolic constant indicating the
+// array type for the vertex attribute array for index. Possible values
+// are GL.BYTE, GL.UNSIGNED_BYTE, GL.SHORT, GL.UNSIGNED_SHORT, GL.INT,
+// GL.UNSIGNED_INT, GL.FLOAT, and GL.DOUBLE. The initial value is
+// GL.FLOAT.
+//
+// GL.VERTEX_ATTRIB_ARRAY_NORMALIZED
+// params returns a single value that is non-zero (true) if fixed-point
+// data types for the vertex attribute array indicated by index are
+// normalized when they are converted to floating point, and 0 (false)
+// otherwise. The initial value is 0.
+//
+// GL.CURRENT_VERTEX_ATTRIB
+// params returns four values that represent the current value for the
+// generic vertex attribute specified by index. Generic vertex
+// attribute 0 is unique in that it has no current state, so an error
+// will be generated if index is 0. The initial value for all other
+// generic vertex attributes is (0,0,0,1).
+//
+// All of the parameters except GL.CURRENT_VERTEX_ATTRIB represent
+// client-side state.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_ENUM is generated if pname is not an
+// accepted value. GL.INVALID_OPERATION is generated if index is 0 and pname
+// is GL.CURRENT_VERTEX_ATTRIB.
+//
+// GetVertexAttribfv is available in GL version 2.0 or greater.
+func (gl *GL) GetVertexAttribfv(index glbase.Attrib, pname glbase.Enum, params []float32) {
+ var params_c [4]float32
+ C.gl3_1_glGetVertexAttribfv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetVertexAttribdv returns in params the value of a generic vertex attribute
+// parameter. The generic vertex attribute to be queried is specified by
+// index, and the parameter to be queried is specified by pname.
+//
+// The accepted parameter names are as follows:
+//
+// GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING
+// params returns a single value, the name of the buffer object
+// currently bound to the binding point corresponding to generic vertex
+// attribute array index. If no buffer object is bound, 0 is returned.
+// The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_ENABLED
+// params returns a single value that is non-zero (true) if the vertex
+// attribute array for index is enabled and 0 (false) if it is
+// disabled. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_SIZE
+// params returns a single value, the size of the vertex attribute
+// array for index. The size is the number of values for each element
+// of the vertex attribute array, and it will be 1, 2, 3, or 4. The
+// initial value is 4.
+//
+// GL.VERTEX_ATTRIB_ARRAY_STRIDE
+// params returns a single value, the array stride for (number of bytes
+// between successive elements in) the vertex attribute array for
+// index. A value of 0 indicates that the array elements are stored
+// sequentially in memory. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_TYPE
+// params returns a single value, a symbolic constant indicating the
+// array type for the vertex attribute array for index. Possible values
+// are GL.BYTE, GL.UNSIGNED_BYTE, GL.SHORT, GL.UNSIGNED_SHORT, GL.INT,
+// GL.UNSIGNED_INT, GL.FLOAT, and GL.DOUBLE. The initial value is
+// GL.FLOAT.
+//
+// GL.VERTEX_ATTRIB_ARRAY_NORMALIZED
+// params returns a single value that is non-zero (true) if fixed-point
+// data types for the vertex attribute array indicated by index are
+// normalized when they are converted to floating point, and 0 (false)
+// otherwise. The initial value is 0.
+//
+// GL.CURRENT_VERTEX_ATTRIB
+// params returns four values that represent the current value for the
+// generic vertex attribute specified by index. Generic vertex
+// attribute 0 is unique in that it has no current state, so an error
+// will be generated if index is 0. The initial value for all other
+// generic vertex attributes is (0,0,0,1).
+//
+// All of the parameters except GL.CURRENT_VERTEX_ATTRIB represent
+// client-side state.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_ENUM is generated if pname is not an
+// accepted value. GL.INVALID_OPERATION is generated if index is 0 and pname
+// is GL.CURRENT_VERTEX_ATTRIB.
+//
+// GetVertexAttribdv is available in GL version 2.0 or greater.
+func (gl *GL) GetVertexAttribdv(index glbase.Attrib, pname glbase.Enum, params []float64) {
+ var params_c [4]float64
+ C.gl3_1_glGetVertexAttribdv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetUniformiv returns in params the value of the specified uniform
+// variable. The type of the uniform variable specified by location
+// determines the number of values returned. If the uniform variable is
+// defined in the shader as a boolean, int, or float, a single value will be
+// returned. If it is defined as a vec2, ivec2, or bvec2, two values will be
+// returned. If it is defined as a vec3, ivec3, or bvec3, three values will
+// be returned, and so on. To query values stored in uniform variables
+// declared as arrays, call GetUniformiv for each element of the array. To
+// query values stored in uniform variables declared as structures, call
+// GetUniformiv for each field in the structure. The values for uniform
+// variables declared as a matrix will be returned in column major order.
+//
+// The locations assigned to uniform variables are not known until the
+// program object is linked. After linking has occurred, the command
+// GetUniformLocation can be used to obtain the location of a uniform
+// variable. This location value can then be passed to GetUniformiv in order
+// to query the current value of the uniform variable. After a program object
+// has been linked successfully, the index values for uniform variables
+// remain fixed until the next link command occurs. The uniform variable
+// values can only be queried after a link if the link was successful.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program
+// object. GL.INVALID_OPERATION is generated if program has not been
+// successfully linked. GL.INVALID_OPERATION is generated if location does
+// not correspond to a valid uniform variable location for the specified
+// program object. GL.INVALID_OPERATION is generated if GetUniformiv is
+// executed between the execution of Begin and the corresponding execution of
+// End.
+//
+// GetUniformiv is available in GL version 2.0 or greater.
+func (gl *GL) GetUniformiv(program glbase.Program, location glbase.Uniform, params []int32) {
+ var params_c [4]int32
+ C.gl3_1_glGetUniformiv(gl.funcs, C.GLuint(program), C.GLint(location), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetUniformfv returns in params the value of the specified uniform
+// variable. The type of the uniform variable specified by location
+// determines the number of values returned. If the uniform variable is
+// defined in the shader as a boolean, int, or float, a single value will be
+// returned. If it is defined as a vec2, ivec2, or bvec2, two values will be
+// returned. If it is defined as a vec3, ivec3, or bvec3, three values will
+// be returned, and so on. To query values stored in uniform variables
+// declared as arrays, call GetUniformfv for each element of the array. To
+// query values stored in uniform variables declared as structures, call
+// GetUniformfv for each field in the structure. The values for uniform
+// variables declared as a matrix will be returned in column major order.
+//
+// The locations assigned to uniform variables are not known until the
+// program object is linked. After linking has occurred, the command
+// GetUniformLocation can be used to obtain the location of a uniform
+// variable. This location value can then be passed to GetUniformfv in order
+// to query the current value of the uniform variable. After a program object
+// has been linked successfully, the index values for uniform variables
+// remain fixed until the next link command occurs. The uniform variable
+// values can only be queried after a link if the link was successful.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program
+// object. GL.INVALID_OPERATION is generated if program has not been
+// successfully linked. GL.INVALID_OPERATION is generated if location does
+// not correspond to a valid uniform variable location for the specified
+// program object. GL.INVALID_OPERATION is generated if GetUniformfv is
+// executed between the execution of Begin and the corresponding execution of
+// End.
+//
+// GetUniformfv is available in GL version 2.0 or greater.
+func (gl *GL) GetUniformfv(program glbase.Program, location glbase.Uniform, params []float32) {
+ var params_c [4]float32
+ C.gl3_1_glGetUniformfv(gl.funcs, C.GLuint(program), C.GLint(location), (*C.GLfloat)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetUniformLocation returns an integer that represents the location of a
+// specific uniform variable within a program object. name must be an active
+// uniform variable name in program that is not a structure, an array of
+// structures, or a subcomponent of a vector or a matrix. This function
+// returns -1 if name does not correspond to an active uniform variable in
+// program or if name starts with the reserved prefix "gl_".
+//
+// Uniform variables that are structures or arrays of structures may be
+// queried by calling GetUniformLocation for each field within the
+// structure. The array element operator "[]" and the structure field
+// operator "." may be used in name in order to select elements within an
+// array or fields within a structure. The result of using these operators is
+// not allowed to be another structure, an array of structures, or a
+// subcomponent of a vector or a matrix. Except if the last part of name
+// indicates a uniform variable array, the location of the first element of
+// an array can be retrieved by using the name of the array, or by using the
+// name appended by "[0]".
+//
+// The actual locations assigned to uniform variables are not known until the
+// program object is linked successfully. After linking has occurred, the
+// command GetUniformLocation can be used to obtain the location of a
+// uniform variable. This location value can then be passed to Uniform to
+// set the value of the uniform variable or to GetUniform in order to query
+// the current value of the uniform variable. After a program object has been
+// linked successfully, the index values for uniform variables remain fixed
+// until the next link command occurs. Uniform variable locations and values
+// can only be queried after a link if the link was successful.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program object.
+// GL.INVALID_OPERATION is generated if program has not been successfully
+// linked. GL.INVALID_OPERATION is generated if GetUniformLocation is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// GetUniformLocation is available in GL version 2.0 or greater.
+func (gl *GL) GetUniformLocation(program glbase.Program, name string) glbase.Uniform {
+ name_cstr := C.CString(name)
+ glresult := C.gl3_1_glGetUniformLocation(gl.funcs, C.GLuint(program), (*C.GLchar)(name_cstr))
+ C.free(unsafe.Pointer(name_cstr))
+ return glbase.Uniform(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetShaderSource.xml
+func (gl *GL) GetShaderSource(shader glbase.Shader, bufSize int32, length []int32, source []byte) {
+ C.gl3_1_glGetShaderSource(gl.funcs, C.GLuint(shader), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&source[0])))
+}
+
+// GetShaderInfoLog returns the information log for the specified shader
+// object. The information log for a shader object is modified when the
+// shader is compiled.
+//
+// The information log for a shader object is a string that may contain
+// diagnostic messages, warning messages, and other information about the
+// last compile operation. When a shader object is created, its information
+// log will be a string of length 0, and the size of the current log can be
+// obtained by calling GetShaderiv with the value GL.INFO_LOG_LENGTH.
+//
+// The information log for a shader object is the OpenGL implementer's
+// primary mechanism for conveying information about the compilation process.
+// Therefore, the information log can be helpful to application developers
+// during the development process, even when compilation is successful.
+// Application developers should not expect different OpenGL implementations
+// to produce identical information logs.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader is not a shader
+// object. GL.INVALID_VALUE is generated if maxLength is less than 0.
+// GL.INVALID_OPERATION is generated if GetShaderInfoLog is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// GetShaderInfoLog is available in GL version 2.0 or greater.
+func (gl *GL) GetShaderInfoLog(shader glbase.Shader) []byte {
+ var params [1]int32
+ var length int32
+ gl.GetShaderiv(shader, INFO_LOG_LENGTH, params[:])
+ bufSize := params[0]
+ infoLog := make([]byte, int(bufSize))
+ C.gl3_1_glGetShaderInfoLog(gl.funcs, C.GLuint(shader), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length)), (*C.GLchar)(unsafe.Pointer(&infoLog[0])))
+ return infoLog
+}
+
+// GetShaderiv GetShader returns in params the value of a parameter for a specific
+// shader object. The following parameters are defined:
+//
+// GL.SHADER_TYPE
+// params returns GL.VERTEX_SHADER if shader is a vertex shader object,
+// and GL.FRAGMENT_SHADER if shader is a fragment shader object.
+//
+// GL.DELETE_STATUS
+// params returns GL.TRUE if shader is currently flagged for deletion,
+// and GL.FALSE otherwise.
+//
+// GL.COMPILE_STATUS
+// params returns GL.TRUE if the last compile operation on shader was
+// successful, and GL.FALSE otherwise.
+//
+// GL.INFO_LOG_LENGTH
+// params returns the number of characters in the information log for
+// shader including the null termination character (the size of the
+// character buffer required to store the information log). If shader has
+// no information log, a value of 0 is returned.
+//
+// GL.SHADER_SOURCE_LENGTH
+// params returns the length of the concatenation of the source strings
+// that make up the shader source for the shader, including the null
+// termination character. (the size of the character buffer
+// required to store the shader source). If no source code exists, 0 is
+// returned.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader does not refer to a
+// shader object. GL.INVALID_ENUM is generated if pname is not an accepted
+// value. GL.INVALID_OPERATION is generated if GetShader is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// GetShaderiv is available in GL version 2.0 or greater.
+func (gl *GL) GetShaderiv(shader glbase.Shader, pname glbase.Enum, params []int32) {
+ var params_c [4]int32
+ C.gl3_1_glGetShaderiv(gl.funcs, C.GLuint(shader), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetProgramInfoLog returns the information log for the specified program
+// object. The information log for a program object is modified when the
+// program object is linked or validated.
+//
+// The information log for a program object is either an empty string, or a
+// string containing information about the last link operation, or a string
+// containing information about the last validation operation. It may contain
+// diagnostic messages, warning messages, and other information. When a
+// program object is created, its information log will be a string of length
+// 0, and the size of the current log can be obtained by calling GetProgramiv
+// with the value GL.INFO_LOG_LENGTH.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated
+// by OpenGL. GL.INVALID_OPERATION is generated if program is not a
+// program object.
+func (gl *GL) GetProgramInfoLog(program glbase.Program) []byte {
+ var params [1]int32
+ var length int32
+ gl.GetProgramiv(program, INFO_LOG_LENGTH, params[:])
+ bufSize := params[0]
+ infoLog := make([]byte, int(bufSize))
+ C.gl3_1_glGetProgramInfoLog(gl.funcs, C.GLuint(program), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length)), (*C.GLchar)(unsafe.Pointer(&infoLog[0])))
+ return infoLog
+}
+
+// GetProgramiv returns in params the value of a parameter for a specific
+// program object. The following parameters are defined:
+//
+// GL.DELETE_STATUS
+// params returns GL.TRUE if program is currently flagged for deletion,
+// and GL.FALSE otherwise.
+//
+// GL.LINK_STATUS
+// params returns GL.TRUE if the last link operation on program was
+// successful, and GL.FALSE otherwise.
+//
+// GL.VALIDATE_STATUS
+// params returns GL.TRUE or if the last validation operation on
+// program was successful, and GL.FALSE otherwise.
+//
+// GL.INFO_LOG_LENGTH
+// params returns the number of characters in the information log for
+// program including the null termination character (the size of
+// the character buffer required to store the information log). If
+// program has no information log, a value of 0 is returned.
+//
+// GL.ATTACHED_SHADERS
+// params returns the number of shader objects attached to program.
+//
+// GL.ACTIVE_ATTRIBUTES
+// params returns the number of active attribute variables for program.
+//
+// GL.ACTIVE_ATTRIBUTE_MAX_LENGTH
+// params returns the length of the longest active attribute name for
+// program, including the null termination character (the size of
+// the character buffer required to store the longest attribute name).
+// If no active attributes exist, 0 is returned.
+//
+// GL.ACTIVE_UNIFORMS
+// params returns the number of active uniform variables for program.
+//
+// GL.ACTIVE_UNIFORM_MAX_LENGTH
+// params returns the length of the longest active uniform variable
+// name for program, including the null termination character (i.e.,
+// the size of the character buffer required to store the longest
+// uniform variable name). If no active uniform variables exist, 0 is
+// returned.
+//
+// GL.TRANSFORM_FEEDBACK_BUFFER_MODE
+// params returns a symbolic constant indicating the buffer mode used
+// when transform feedback is active. This may be GL.SEPARATE_ATTRIBS
+// or GL.INTERLEAVED_ATTRIBS.
+//
+// GL.TRANSFORM_FEEDBACK_VARYINGS
+// params returns the number of varying variables to capture in transform
+// feedback mode for the program.
+//
+// GL.TRANSFORM_FEEDBACK_VARYING_MAX_LENGTH
+// params returns the length of the longest variable name to be used for
+// transform feedback, including the null-terminator.
+//
+// GL.GEOMETRY_VERTICES_OUT
+// params returns the maximum number of vertices that the geometry shader in
+// program will output.
+//
+// GL.GEOMETRY_INPUT_TYPE
+// params returns a symbolic constant indicating the primitive type accepted
+// as input to the geometry shader contained in program.
+//
+// GL.GEOMETRY_OUTPUT_TYPE
+// params returns a symbolic constant indicating the primitive type that will
+// be output by the geometry shader contained in program.
+//
+// GL.ACTIVE_UNIFORM_BLOCKS and GL.ACTIVE_UNIFORM_BLOCK_MAX_NAME_LENGTH are
+// available only if the GL version 3.1 or greater.
+//
+// GL.GEOMETRY_VERTICES_OUT, GL.GEOMETRY_INPUT_TYPE and
+// GL.GEOMETRY_OUTPUT_TYPE are accepted only if the GL version is 3.2 or
+// greater.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program does not refer to a
+// program object. GL.INVALID_OPERATION is generated if pname is
+// GL.GEOMETRY_VERTICES_OUT, GL.GEOMETRY_INPUT_TYPE, or
+// GL.GEOMETRY_OUTPUT_TYPE, and program does not contain a geometry shader.
+// GL.INVALID_ENUM is generated if pname is not an accepted value.
+func (gl *GL) GetProgramiv(program glbase.Program, pname glbase.Enum, params []int32) {
+ var params_c [4]int32
+ C.gl3_1_glGetProgramiv(gl.funcs, C.GLuint(program), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetAttribLocation queries the previously linked program object specified
+// by program for the attribute variable specified by name and returns the
+// index of the generic vertex attribute that is bound to that attribute
+// variable. If name is a matrix attribute variable, the index of the first
+// column of the matrix is returned. If the named attribute variable is not
+// an active attribute in the specified program object or if name starts with
+// the reserved prefix "gl_", a value of -1 is returned.
+//
+// The association between an attribute variable name and a generic attribute
+// index can be specified at any time by calling BindAttribLocation.
+// Attribute bindings do not go into effect until LinkProgram is called.
+// After a program object has been linked successfully, the index values for
+// attribute variables remain fixed until the next link command occurs. The
+// attribute values can only be queried after a link if the link was
+// successful. GetAttribLocation returns the binding that actually went
+// into effect the last time LinkProgram was called for the specified
+// program object. Attribute bindings that have been specified since the last
+// link operation are not returned by GetAttribLocation.
+//
+// Error GL_INVALID_OPERATION is generated if program is not a value
+// generated by OpenGL. GL_INVALID_OPERATION is generated if program is not
+// a program object. GL_INVALID_OPERATION is generated if program has not
+// been successfully linked. GL_INVALID_OPERATION is generated if
+// GetAttribLocation is executed between the execution of Begin and the
+// corresponding execution of End.
+//
+// GetAttribLocation is available in GL version 2.0 or greater.
+func (gl *GL) GetAttribLocation(program glbase.Program, name string) glbase.Attrib {
+ name_cstr := C.CString(name)
+ glresult := C.gl3_1_glGetAttribLocation(gl.funcs, C.GLuint(program), (*C.GLchar)(name_cstr))
+ C.free(unsafe.Pointer(name_cstr))
+ return glbase.Attrib(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetAttachedShaders.xml
+func (gl *GL) GetAttachedShaders(program glbase.Program, maxCount int32, count []int, obj []uint32) {
+ C.gl3_1_glGetAttachedShaders(gl.funcs, C.GLuint(program), C.GLsizei(maxCount), (*C.GLsizei)(unsafe.Pointer(&count[0])), (*C.GLuint)(unsafe.Pointer(&obj[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetActiveUniform.xml
+func (gl *GL) GetActiveUniform(program glbase.Program, index uint32, bufSize int32, length []int32, size []int, gltype []glbase.Enum, name []byte) {
+ C.gl3_1_glGetActiveUniform(gl.funcs, C.GLuint(program), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLint)(unsafe.Pointer(&size[0])), (*C.GLenum)(unsafe.Pointer(&gltype[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetActiveAttrib.xml
+func (gl *GL) GetActiveAttrib(program glbase.Program, index glbase.Attrib, bufSize int32, length []int32, size []int, gltype []glbase.Enum, name []byte) {
+ C.gl3_1_glGetActiveAttrib(gl.funcs, C.GLuint(program), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLint)(unsafe.Pointer(&size[0])), (*C.GLenum)(unsafe.Pointer(&gltype[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEnableVertexAttribArray.xml
+func (gl *GL) EnableVertexAttribArray(index glbase.Attrib) {
+ C.gl3_1_glEnableVertexAttribArray(gl.funcs, C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDisableVertexAttribArray.xml
+func (gl *GL) DisableVertexAttribArray(index glbase.Attrib) {
+ C.gl3_1_glDisableVertexAttribArray(gl.funcs, C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDetachShader.xml
+func (gl *GL) DetachShader(program glbase.Program, shader glbase.Shader) {
+ C.gl3_1_glDetachShader(gl.funcs, C.GLuint(program), C.GLuint(shader))
+}
+
+// DeleteShader frees the memory and invalidates the name associated with
+// the shader object specified by shader. This command effectively undoes the
+// effects of a call to CreateShader.
+//
+// If a shader object to be deleted is attached to a program object, it will
+// be flagged for deletion, but it will not be deleted until it is no longer
+// attached to any program object, for any rendering context (it must
+// be detached from wherever it was attached before it will be deleted). A
+// value of 0 for shader will be silently ignored.
+//
+// To determine whether an object has been flagged for deletion, call
+// GetShader with arguments shader and GL.DELETE_STATUS.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL.
+//
+// DeleteShader is available in GL version 2.0 or greater.
+func (gl *GL) DeleteShader(shader glbase.Shader) {
+ C.gl3_1_glDeleteShader(gl.funcs, C.GLuint(shader))
+}
+
+// DeleteProgram frees the memory and invalidates the name associated with
+// the program object specified by program. This command effectively undoes
+// the effects of a call to CreateProgram.
+//
+// If a program object is in use as part of current rendering state, it will
+// be flagged for deletion, but it will not be deleted until it is no longer
+// part of current state for any rendering context. If a program object to be
+// deleted has shader objects attached to it, those shader objects will be
+// automatically detached but not deleted unless they have already been
+// flagged for deletion by a previous call to DeleteShader. A value of 0
+// for program will be silently ignored.
+//
+// To determine whether a program object has been flagged for deletion, call
+// GetProgram with arguments program and GL.DELETE_STATUS.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL.
+//
+// DeleteProgram is available in GL version 2.0 or greater.
+func (gl *GL) DeleteProgram(program glbase.Program) {
+ C.gl3_1_glDeleteProgram(gl.funcs, C.GLuint(program))
+}
+
+// CreateShader creates an empty shader object and returns a non-zero value
+// by which it can be referenced. A shader object is used to maintain the
+// source code strings that define a shader. shaderType indicates the type of
+// shader to be created.
+//
+// Two types of shaders are supported. A shader of type GL.VERTEX_SHADER is a
+// shader that is intended to run on the programmable vertex processor and
+// replace the fixed functionality vertex processing in OpenGL. A shader of
+// type GL.FRAGMENT_SHADER is a shader that is intended to run on the
+// programmable fragment processor and replace the fixed functionality
+// fragment processing in OpenGL.
+//
+// When created, a shader object's GL.SHADER_TYPE parameter is set to either
+// GL.VERTEX_SHADER or GL.FRAGMENT_SHADER, depending on the value of
+// shaderType.
+//
+// Like display lists and texture objects, the name space for shader objects
+// may be shared across a set of contexts, as long as the server sides of the
+// contexts share the same address space. If the name space is shared across
+// contexts, any attached objects and the data associated with those attached
+// objects are shared as well.
+//
+// This function returns 0 if an error occurs creating the shader object.
+//
+// Error GL.INVALID_ENUM is generated if shaderType is not an accepted value.
+// GL.INVALID_OPERATION is generated if CreateShader is executed between the
+// execution of Begin and the corresponding execution of End.
+//
+// CreateShader is available in GL version 2.0 or greater.
+func (gl *GL) CreateShader(gltype glbase.Enum) glbase.Shader {
+ glresult := C.gl3_1_glCreateShader(gl.funcs, C.GLenum(gltype))
+ return glbase.Shader(glresult)
+}
+
+// CreateProgram creates an empty program object and returns a non-zero
+// value by which it can be referenced. A program object is an object to
+// which shader objects can be attached. This provides a mechanism to specify
+// the shader objects that will be linked to create a program. It also
+// provides a means for checking the compatibility of the shaders that will
+// be used to create a program (for instance, checking the compatibility
+// between a vertex shader and a fragment shader). When no longer needed as
+// part of a program object, shader objects can be detached.
+//
+// One or more executables are created in a program object by successfully
+// attaching shader objects to it with AttachShader, successfully compiling
+// the shader objects with CompileShader, and successfully linking the
+// program object with LinkProgram. These executables are made part of
+// current state when UseProgram is called. Program objects can be deleted
+// by calling DeleteProgram. The memory associated with the program object
+// will be deleted when it is no longer part of current rendering state for
+// any context.
+//
+// Like display lists and texture objects, the name space for program objects
+// may be shared across a set of contexts, as long as the server sides of the
+// contexts share the same address space. If the name space is shared across
+// contexts, any attached objects and the data associated with those attached
+// objects are shared as well.
+//
+// Applications are responsible for providing the synchronization across API
+// calls when objects are accessed from different execution threads.
+//
+// This function returns 0 if an error occurs creating the program object.
+//
+// Error GL.INVALID_OPERATION is generated if CreateProgram is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// CreateProgram is available in GL version 2.0 or greater.
+func (gl *GL) CreateProgram() glbase.Program {
+ glresult := C.gl3_1_glCreateProgram(gl.funcs)
+ return glbase.Program(glresult)
+}
+
+// CompileShader compiles the source code strings that have been stored in
+// the shader object specified by shader.
+//
+// The compilation status will be stored as part of the shader object's
+// state. This value will be set to GL.TRUE if the shader was compiled without
+// errors and is ready for use, and GL.FALSE otherwise. It can be queried by
+// calling GetShaderiv with arguments shader and GL.COMPILE_STATUS.
+//
+// Compilation of a shader can fail for a number of reasons as specified by
+// the OpenGL Shading Language Specification. Whether or not the compilation
+// was successful, information about the compilation can be obtained from the
+// shader object's information log by calling GetShaderInfoLog.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader is not a shader
+// object. GL.INVALID_OPERATION is generated if CompileShader is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// CompileShader is available in GL version 2.0 or greater.
+func (gl *GL) CompileShader(shader glbase.Shader) {
+ C.gl3_1_glCompileShader(gl.funcs, C.GLuint(shader))
+}
+
+// BindAttribLocation associates a user-defined attribute variable in the program
+// object specified by program with a generic vertex attribute index. The name
+// parameter specifies the name of the vertex shader attribute variable to
+// which index is to be bound. When program is made part of the current state,
+// values provided via the generic vertex attribute index will modify the
+// value of the user-defined attribute variable specified by name.
+//
+// If name refers to a matrix attribute variable, index refers to the first
+// column of the matrix. Other matrix columns are then automatically bound to
+// locations index+1 for a matrix of type mat2; index+1 and index+2 for a
+// matrix of type mat3; and index+1, index+2, and index+3 for a matrix of
+// type mat4.
+//
+// This command makes it possible for vertex shaders to use descriptive names
+// for attribute variables rather than generic variables that are numbered
+// from 0 to GL.MAX_VERTEX_ATTRIBS-1. The values sent to each generic
+// attribute index are part of current state, just like standard vertex
+// attributes such as color, normal, and vertex position. If a different
+// program object is made current by calling UseProgram, the generic vertex
+// attributes are tracked in such a way that the same values will be observed
+// by attributes in the new program object that are also bound to index.
+//
+// Attribute variable name-to-generic attribute index bindings for a program
+// object can be explicitly assigned at any time by calling
+// BindAttribLocation. Attribute bindings do not go into effect until
+// LinkProgram is called. After a program object has been linked
+// successfully, the index values for generic attributes remain fixed (and
+// their values can be queried) until the next link command occurs.
+//
+// Applications are not allowed to bind any of the standard OpenGL vertex
+// attributes using this command, as they are bound automatically when
+// needed. Any attribute binding that occurs after the program object has
+// been linked will not take effect until the next time the program object is
+// linked.
+//
+// If name was bound previously, that information is lost. Thus you cannot
+// bind one user-defined attribute variable to multiple indices, but you can
+// bind multiple user-defined attribute variables to the same index.
+//
+// Applications are allowed to bind more than one user-defined attribute
+// variable to the same generic vertex attribute index. This is called
+// aliasing, and it is allowed only if just one of the aliased attributes is
+// active in the executable program, or if no path through the shader
+// consumes more than one attribute of a set of attributes aliased to the
+// same location. The compiler and linker are allowed to assume that no
+// aliasing is done and are free to employ optimizations that work only in
+// the absence of aliasing. OpenGL implementations are not required to do
+// error checking to detect aliasing. Because there is no way to bind
+// standard attributes, it is not possible to alias generic attributes with
+// conventional ones (except for generic attribute 0).
+//
+// BindAttribLocation can be called before any vertex shader objects are
+// bound to the specified program object. It is also permissible to bind a
+// generic attribute index to an attribute variable name that is never used
+// in a vertex shader.
+//
+// Active attributes that are not explicitly bound will be bound by the
+// linker when LinkProgram is called. The locations assigned can be queried
+// by calling GetAttribLocation.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS.
+// GL.INVALID_OPERATION is generated if name starts with the reserved prefix "gl_".
+// GL.INVALID_VALUE is generated if program is not a value generated by OpenGL.
+// GL.INVALID_OPERATION is generated if program is not a program object.
+// GL.INVALID_OPERATION is generated if BindAttribLocation is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// BindAttribLocation is available in GL version 2.0 or greater.
+func (gl *GL) BindAttribLocation(program glbase.Program, index glbase.Attrib, name string) {
+ name_cstr := C.CString(name)
+ C.gl3_1_glBindAttribLocation(gl.funcs, C.GLuint(program), C.GLuint(index), (*C.GLchar)(name_cstr))
+ C.free(unsafe.Pointer(name_cstr))
+}
+
+// AttachShader attaches a shader object to a program object.
+//
+// In order to create an executable, there must be a way to specify the list
+// of things that will be linked together. Program objects provide this
+// mechanism. Shaders that are to be linked together in a program object must
+// first be attached to that program object. This indicates that shader will
+// be included in link operations that will be performed on program.
+//
+// All operations that can be performed on a shader object are valid whether
+// or not the shader object is attached to a program object. It is
+// permissible to attach a shader object to a program object before source
+// code has been loaded into the shader object or before the shader object
+// has been compiled. It is permissible to attach multiple shader objects of
+// the same type because each may contain a portion of the complete shader.
+// It is also permissible to attach a shader object to more than one program
+// object. If a shader object is deleted while it is attached to a program
+// object, it will be flagged for deletion, and deletion will not occur until
+// DetachShader is called to detach it from all program objects to which it
+// is attached.
+//
+// Error GL.INVALID_VALUE is generated if either program or shader is not a
+// value generated by OpenGL. GL.INVALID_OPERATION is generated if program
+// is not a program object. GL.INVALID_OPERATION is generated if shader is
+// not a shader object. GL.INVALID_OPERATION is generated if shader is
+// already attached to program. GL.INVALID_OPERATION is generated if
+// AttachShader is executed between the execution of Begin and the
+// corresponding execution of End.
+//
+// AttachShader is available in GL version 2.0 or greater.
+func (gl *GL) AttachShader(program glbase.Program, shader glbase.Shader) {
+ C.gl3_1_glAttachShader(gl.funcs, C.GLuint(program), C.GLuint(shader))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glStencilMaskSeparate.xml
+func (gl *GL) StencilMaskSeparate(face glbase.Enum, mask uint32) {
+ C.gl3_1_glStencilMaskSeparate(gl.funcs, C.GLenum(face), C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glStencilFuncSeparate.xml
+func (gl *GL) StencilFuncSeparate(face, glfunc glbase.Enum, ref int32, mask uint32) {
+ C.gl3_1_glStencilFuncSeparate(gl.funcs, C.GLenum(face), C.GLenum(glfunc), C.GLint(ref), C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glStencilOpSeparate.xml
+func (gl *GL) StencilOpSeparate(face, sfail, dpfail, dppass glbase.Enum) {
+ C.gl3_1_glStencilOpSeparate(gl.funcs, C.GLenum(face), C.GLenum(sfail), C.GLenum(dpfail), C.GLenum(dppass))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDrawBuffers.xml
+func (gl *GL) DrawBuffers(n int, bufs []glbase.Enum) {
+ C.gl3_1_glDrawBuffers(gl.funcs, C.GLsizei(n), (*C.GLenum)(unsafe.Pointer(&bufs[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBlendEquationSeparate.xml
+func (gl *GL) BlendEquationSeparate(modeRGB, modeAlpha glbase.Enum) {
+ C.gl3_1_glBlendEquationSeparate(gl.funcs, C.GLenum(modeRGB), C.GLenum(modeAlpha))
+}
+
+// UniformMatrix4x3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix4x3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix4x3fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(4*3) != 0 {
+ panic("invalid value length for UniformMatrix4x3fv")
+ }
+ count := len(value) / (4 * 3)
+ C.gl3_1_glUniformMatrix4x3fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix3x4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix3x4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix3x4fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(3*4) != 0 {
+ panic("invalid value length for UniformMatrix3x4fv")
+ }
+ count := len(value) / (3 * 4)
+ C.gl3_1_glUniformMatrix3x4fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix4x2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix4x2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix4x2fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(4*2) != 0 {
+ panic("invalid value length for UniformMatrix4x2fv")
+ }
+ count := len(value) / (4 * 2)
+ C.gl3_1_glUniformMatrix4x2fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix2x4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix2x4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix2x4fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(2*4) != 0 {
+ panic("invalid value length for UniformMatrix2x4fv")
+ }
+ count := len(value) / (2 * 4)
+ C.gl3_1_glUniformMatrix2x4fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix3x2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix3x2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix3x2fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(3*2) != 0 {
+ panic("invalid value length for UniformMatrix3x2fv")
+ }
+ count := len(value) / (3 * 2)
+ C.gl3_1_glUniformMatrix3x2fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix2x3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix2x3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix2x3fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(2*3) != 0 {
+ panic("invalid value length for UniformMatrix2x3fv")
+ }
+ count := len(value) / (2 * 3)
+ C.gl3_1_glUniformMatrix2x3fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsVertexArray.xml
+func (gl *GL) IsVertexArray(array uint32) bool {
+ glresult := C.gl3_1_glIsVertexArray(gl.funcs, C.GLuint(array))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGenVertexArrays.xml
+func (gl *GL) GenVertexArrays(n int, arrays []uint32) {
+ C.gl3_1_glGenVertexArrays(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&arrays[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDeleteVertexArrays.xml
+func (gl *GL) DeleteVertexArrays(n int, arrays []uint32) {
+ C.gl3_1_glDeleteVertexArrays(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&arrays[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBindVertexArray.xml
+func (gl *GL) BindVertexArray(array uint32) {
+ C.gl3_1_glBindVertexArray(gl.funcs, C.GLuint(array))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFlushMappedBufferRange.xml
+func (gl *GL) FlushMappedBufferRange(target glbase.Enum, offset, length int) {
+ C.gl3_1_glFlushMappedBufferRange(gl.funcs, C.GLenum(target), C.GLintptr(offset), C.GLsizeiptr(length))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFramebufferTextureLayer.xml
+func (gl *GL) FramebufferTextureLayer(target, attachment glbase.Enum, texture glbase.Texture, level int, layer int32) {
+ C.gl3_1_glFramebufferTextureLayer(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLuint(texture), C.GLint(level), C.GLint(layer))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRenderbufferStorageMultisample.xml
+func (gl *GL) RenderbufferStorageMultisample(target glbase.Enum, samples int32, internalFormat glbase.Enum, width, height int) {
+ C.gl3_1_glRenderbufferStorageMultisample(gl.funcs, C.GLenum(target), C.GLsizei(samples), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBlitFramebuffer.xml
+func (gl *GL) BlitFramebuffer(srcX0, srcY0, srcX1, srcY1, dstX0, dstY0, dstX1, dstY1 int32, mask glbase.Bitfield, filter glbase.Enum) {
+ C.gl3_1_glBlitFramebuffer(gl.funcs, C.GLint(srcX0), C.GLint(srcY0), C.GLint(srcX1), C.GLint(srcY1), C.GLint(dstX0), C.GLint(dstY0), C.GLint(dstX1), C.GLint(dstY1), C.GLbitfield(mask), C.GLenum(filter))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGenerateMipmap.xml
+func (gl *GL) GenerateMipmap(target glbase.Enum) {
+ C.gl3_1_glGenerateMipmap(gl.funcs, C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetFramebufferAttachmentParameteriv.xml
+func (gl *GL) GetFramebufferAttachmentParameteriv(target, attachment, pname glbase.Enum, params []int32) {
+ C.gl3_1_glGetFramebufferAttachmentParameteriv(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFramebufferRenderbuffer.xml
+func (gl *GL) FramebufferRenderbuffer(target, attachment, renderbuffertarget glbase.Enum, renderbuffer glbase.Renderbuffer) {
+ C.gl3_1_glFramebufferRenderbuffer(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(renderbuffertarget), C.GLuint(renderbuffer))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFramebufferTexture3D.xml
+func (gl *GL) FramebufferTexture3D(target, attachment, textarget glbase.Enum, texture glbase.Texture, level int, zoffset int32) {
+ C.gl3_1_glFramebufferTexture3D(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(textarget), C.GLuint(texture), C.GLint(level), C.GLint(zoffset))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFramebufferTexture2D.xml
+func (gl *GL) FramebufferTexture2D(target, attachment, textarget glbase.Enum, texture glbase.Texture, level int) {
+ C.gl3_1_glFramebufferTexture2D(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(textarget), C.GLuint(texture), C.GLint(level))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFramebufferTexture1D.xml
+func (gl *GL) FramebufferTexture1D(target, attachment, textarget glbase.Enum, texture glbase.Texture, level int) {
+ C.gl3_1_glFramebufferTexture1D(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(textarget), C.GLuint(texture), C.GLint(level))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCheckFramebufferStatus.xml
+func (gl *GL) CheckFramebufferStatus(target glbase.Enum) glbase.Enum {
+ glresult := C.gl3_1_glCheckFramebufferStatus(gl.funcs, C.GLenum(target))
+ return glbase.Enum(glresult)
+}
+
+// GenFramebuffers returns n framebuffer object names in ids. There is no
+// guarantee that the names form a contiguous set of integers; however, it is
+// guaranteed that none of the returned names was in use immediately before
+// the call to GenFramebuffers.
+//
+// Framebuffer object names returned by a call to GenFramebuffers are not
+// returned by subsequent calls, unless they are first deleted with
+// DeleteFramebuffers.
+//
+// The names returned in ids are marked as used, for the purposes of
+// GenFramebuffers only, but they acquire state and type only when they are
+// first bound.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+func (gl *GL) GenFramebuffers(n int) []glbase.Framebuffer {
+ if n == 0 {
+ return nil
+ }
+ framebuffers := make([]glbase.Framebuffer, n)
+ C.gl3_1_glGenFramebuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&framebuffers[0])))
+ return framebuffers
+}
+
+// DeleteFramebuffers deletes the framebuffer objects whose names are
+// stored in the framebuffers slice. The name zero is reserved by the GL and
+// is silently ignored, should it occur in framebuffers, as are other unused
+// names. Once a framebuffer object is deleted, its name is again unused and
+// it has no attachments. If a framebuffer that is currently bound to one or
+// more of the targets GL.DRAW_FRAMEBUFFER or GL.READ_FRAMEBUFFER is deleted,
+// it is as though BindFramebuffer had been executed with the corresponding
+// target and framebuffer zero.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// DeleteFramebuffers is available in GL version 3.0 or greater.
+func (gl *GL) DeleteFramebuffers(framebuffers []glbase.Framebuffer) {
+ n := len(framebuffers)
+ if n == 0 {
+ return
+ }
+ C.gl3_1_glDeleteFramebuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&framebuffers[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBindFramebuffer.xml
+func (gl *GL) BindFramebuffer(target glbase.Enum, framebuffer glbase.Framebuffer) {
+ C.gl3_1_glBindFramebuffer(gl.funcs, C.GLenum(target), C.GLuint(framebuffer))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsFramebuffer.xml
+func (gl *GL) IsFramebuffer(framebuffer glbase.Framebuffer) bool {
+ glresult := C.gl3_1_glIsFramebuffer(gl.funcs, C.GLuint(framebuffer))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetRenderbufferParameteriv.xml
+func (gl *GL) GetRenderbufferParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl3_1_glGetRenderbufferParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRenderbufferStorage.xml
+func (gl *GL) RenderbufferStorage(target, internalFormat glbase.Enum, width, height int) {
+ C.gl3_1_glRenderbufferStorage(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height))
+}
+
+// GenRenderbuffers returns n renderbuffer object names in renderbuffers.
+// There is no guarantee that the names form a contiguous set of integers;
+// however, it is guaranteed that none of the returned names was in use
+// immediately before the call to GenRenderbuffers.
+//
+// Renderbuffer object names returned by a call to GenRenderbuffers are not
+// returned by subsequent calls, unless they are first deleted with
+// DeleteRenderbuffers.
+//
+// The names returned in renderbuffers are marked as used, for the purposes
+// of GenRenderbuffers only, but they acquire state and type only when they
+// are first bound.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// GenRenderbuffers is available in GL version 3.0 or greater.
+func (gl *GL) GenRenderbuffers(n int) []glbase.Renderbuffer {
+ if n == 0 {
+ return nil
+ }
+ renderbuffers := make([]glbase.Renderbuffer, n)
+ C.gl3_1_glGenRenderbuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&renderbuffers[0])))
+ return renderbuffers
+}
+
+// DeleteRenderbuffers deletes the renderbuffer objects whose names are stored
+// in the renderbuffers slice. The name zero is reserved by the GL and
+// is silently ignored, should it occur in renderbuffers, as are other unused
+// names. Once a renderbuffer object is deleted, its name is again unused and
+// it has no contents. If a renderbuffer that is currently bound to the
+// target GL.RENDERBUFFER is deleted, it is as though BindRenderbuffer had
+// been executed with a target of GL.RENDERBUFFER and a name of zero.
+//
+// If a renderbuffer object is attached to one or more attachment points in
+// the currently bound framebuffer, then it as if FramebufferRenderbuffer
+// had been called, with a renderbuffer of zero for each attachment point to
+// which this image was attached in the currently bound framebuffer. In other
+// words, this renderbuffer object is first detached from all attachment
+// ponits in the currently bound framebuffer. Note that the renderbuffer
+// image is specifically not detached from any non-bound framebuffers.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// DeleteRenderbuffers is available in GL version 3.0 or greater.
+func (gl *GL) DeleteRenderbuffers(renderbuffers []glbase.Renderbuffer) {
+ n := len(renderbuffers)
+ if n == 0 {
+ return
+ }
+ C.gl3_1_glDeleteRenderbuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&renderbuffers[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBindRenderbuffer.xml
+func (gl *GL) BindRenderbuffer(target glbase.Enum, renderbuffer glbase.Renderbuffer) {
+ C.gl3_1_glBindRenderbuffer(gl.funcs, C.GLenum(target), C.GLuint(renderbuffer))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsRenderbuffer.xml
+func (gl *GL) IsRenderbuffer(renderbuffer glbase.Renderbuffer) bool {
+ glresult := C.gl3_1_glIsRenderbuffer(gl.funcs, C.GLuint(renderbuffer))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClearBufferfi.xml
+func (gl *GL) ClearBufferfi(buffer glbase.Enum, drawbuffer int32, depth float32, stencil int32) {
+ C.gl3_1_glClearBufferfi(gl.funcs, C.GLenum(buffer), C.GLint(drawbuffer), C.GLfloat(depth), C.GLint(stencil))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClearBufferfv.xml
+func (gl *GL) ClearBufferfv(buffer glbase.Enum, drawbuffer int32, value []float32) {
+ C.gl3_1_glClearBufferfv(gl.funcs, C.GLenum(buffer), C.GLint(drawbuffer), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClearBufferuiv.xml
+func (gl *GL) ClearBufferuiv(buffer glbase.Enum, drawbuffer int32, value []uint32) {
+ C.gl3_1_glClearBufferuiv(gl.funcs, C.GLenum(buffer), C.GLint(drawbuffer), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClearBufferiv.xml
+func (gl *GL) ClearBufferiv(buffer glbase.Enum, drawbuffer int32, value []int32) {
+ C.gl3_1_glClearBufferiv(gl.funcs, C.GLenum(buffer), C.GLint(drawbuffer), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTexParameterIuiv.xml
+func (gl *GL) GetTexParameterIuiv(target, pname glbase.Enum, params []uint32) {
+ C.gl3_1_glGetTexParameterIuiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTexParameterIiv.xml
+func (gl *GL) GetTexParameterIiv(target, pname glbase.Enum, params []int32) {
+ C.gl3_1_glGetTexParameterIiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexParameterIuiv.xml
+func (gl *GL) TexParameterIuiv(target, pname glbase.Enum, params []uint32) {
+ C.gl3_1_glTexParameterIuiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexParameterIiv.xml
+func (gl *GL) TexParameterIiv(target, pname glbase.Enum, params []int32) {
+ C.gl3_1_glTexParameterIiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// Uniform4uiv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform4uiv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4uiv(location glbase.Uniform, value []uint32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%4 != 0 {
+ panic("invalid value length for Uniform4uiv")
+ }
+ count := len(value) / 4
+ C.gl3_1_glUniform4uiv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform3uiv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform3uiv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3uiv(location glbase.Uniform, value []uint32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%3 != 0 {
+ panic("invalid value length for Uniform3uiv")
+ }
+ count := len(value) / 3
+ C.gl3_1_glUniform3uiv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform2uiv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform2uiv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2uiv(location glbase.Uniform, value []uint32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%2 != 0 {
+ panic("invalid value length for Uniform2uiv")
+ }
+ count := len(value) / 2
+ C.gl3_1_glUniform2uiv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform1uiv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform1uiv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1uiv(location glbase.Uniform, value []uint32) {
+ if len(value) == 0 {
+ return
+ }
+ count := len(value)
+ C.gl3_1_glUniform1uiv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4ui modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform4ui operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4ui(location glbase.Uniform, v0, v1, v2, v3 uint32) {
+ C.gl3_1_glUniform4ui(gl.funcs, C.GLint(location), C.GLuint(v0), C.GLuint(v1), C.GLuint(v2), C.GLuint(v3))
+}
+
+// Uniform3ui modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform3ui operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3ui(location glbase.Uniform, v0, v1, v2 uint32) {
+ C.gl3_1_glUniform3ui(gl.funcs, C.GLint(location), C.GLuint(v0), C.GLuint(v1), C.GLuint(v2))
+}
+
+// Uniform2ui modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform2ui operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2ui(location glbase.Uniform, v0, v1 uint32) {
+ C.gl3_1_glUniform2ui(gl.funcs, C.GLint(location), C.GLuint(v0), C.GLuint(v1))
+}
+
+// Uniform1ui modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform1ui operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1ui(location glbase.Uniform, v0 uint32) {
+ C.gl3_1_glUniform1ui(gl.funcs, C.GLint(location), C.GLuint(v0))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetFragDataLocation.xml
+func (gl *GL) GetFragDataLocation(program glbase.Program, name []byte) int32 {
+ glresult := C.gl3_1_glGetFragDataLocation(gl.funcs, C.GLuint(program), (*C.GLchar)(unsafe.Pointer(&name[0])))
+ return int32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBindFragDataLocation.xml
+func (gl *GL) BindFragDataLocation(program glbase.Program, color uint32, name []byte) {
+ C.gl3_1_glBindFragDataLocation(gl.funcs, C.GLuint(program), C.GLuint(color), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetUniformuiv.xml
+func (gl *GL) GetUniformuiv(program glbase.Program, location glbase.Uniform, params []uint32) {
+ C.gl3_1_glGetUniformuiv(gl.funcs, C.GLuint(program), C.GLint(location), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetVertexAttribIuiv.xml
+func (gl *GL) GetVertexAttribIuiv(index glbase.Attrib, pname glbase.Enum, params []uint32) {
+ C.gl3_1_glGetVertexAttribIuiv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetVertexAttribIiv.xml
+func (gl *GL) GetVertexAttribIiv(index glbase.Attrib, pname glbase.Enum, params []int32) {
+ C.gl3_1_glGetVertexAttribIiv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribIPointer.xml
+func (gl *GL) VertexAttribIPointer(index glbase.Attrib, size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_1_glVertexAttribIPointer(gl.funcs, C.GLuint(index), C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEndConditionalRender.xml
+func (gl *GL) EndConditionalRender() {
+ C.gl3_1_glEndConditionalRender(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBeginConditionalRender.xml
+func (gl *GL) BeginConditionalRender(id uint32, mode glbase.Enum) {
+ C.gl3_1_glBeginConditionalRender(gl.funcs, C.GLuint(id), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClampColor.xml
+func (gl *GL) ClampColor(target, clamp glbase.Enum) {
+ C.gl3_1_glClampColor(gl.funcs, C.GLenum(target), C.GLenum(clamp))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTransformFeedbackVarying.xml
+func (gl *GL) GetTransformFeedbackVarying(program glbase.Program, index uint32, bufSize int32, length []int32, size []int, gltype []glbase.Enum, name []byte) {
+ C.gl3_1_glGetTransformFeedbackVarying(gl.funcs, C.GLuint(program), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLsizei)(unsafe.Pointer(&size[0])), (*C.GLenum)(unsafe.Pointer(&gltype[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBindBufferBase.xml
+func (gl *GL) BindBufferBase(target glbase.Enum, index uint32, buffer glbase.Buffer) {
+ C.gl3_1_glBindBufferBase(gl.funcs, C.GLenum(target), C.GLuint(index), C.GLuint(buffer))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBindBufferRange.xml
+func (gl *GL) BindBufferRange(target glbase.Enum, index uint32, buffer glbase.Buffer, offset, size int) {
+ C.gl3_1_glBindBufferRange(gl.funcs, C.GLenum(target), C.GLuint(index), C.GLuint(buffer), C.GLintptr(offset), C.GLsizeiptr(size))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEndTransformFeedback.xml
+func (gl *GL) EndTransformFeedback() {
+ C.gl3_1_glEndTransformFeedback(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBeginTransformFeedback.xml
+func (gl *GL) BeginTransformFeedback(primitiveMode glbase.Enum) {
+ C.gl3_1_glBeginTransformFeedback(gl.funcs, C.GLenum(primitiveMode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsEnabledi.xml
+func (gl *GL) IsEnabledi(target glbase.Enum, index uint32) bool {
+ glresult := C.gl3_1_glIsEnabledi(gl.funcs, C.GLenum(target), C.GLuint(index))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDisablei.xml
+func (gl *GL) Disablei(target glbase.Enum, index uint32) {
+ C.gl3_1_glDisablei(gl.funcs, C.GLenum(target), C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEnablei.xml
+func (gl *GL) Enablei(target glbase.Enum, index uint32) {
+ C.gl3_1_glEnablei(gl.funcs, C.GLenum(target), C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetIntegeri_v.xml
+func (gl *GL) GetIntegeri_v(target glbase.Enum, index uint32, data []int32) {
+ C.gl3_1_glGetIntegeri_v(gl.funcs, C.GLenum(target), C.GLuint(index), (*C.GLint)(unsafe.Pointer(&data[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetBooleani_v.xml
+func (gl *GL) GetBooleani_v(target glbase.Enum, index uint32, data []bool) {
+ C.gl3_1_glGetBooleani_v(gl.funcs, C.GLenum(target), C.GLuint(index), (*C.GLboolean)(unsafe.Pointer(&data[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColorMaski.xml
+func (gl *GL) ColorMaski(index uint32, r, g, b, a bool) {
+ C.gl3_1_glColorMaski(gl.funcs, C.GLuint(index), *(*C.GLboolean)(unsafe.Pointer(&r)), *(*C.GLboolean)(unsafe.Pointer(&g)), *(*C.GLboolean)(unsafe.Pointer(&b)), *(*C.GLboolean)(unsafe.Pointer(&a)))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCopyBufferSubData.xml
+func (gl *GL) CopyBufferSubData(readTarget, writeTarget glbase.Enum, readOffset, writeOffset, size int) {
+ C.gl3_1_glCopyBufferSubData(gl.funcs, C.GLenum(readTarget), C.GLenum(writeTarget), C.GLintptr(readOffset), C.GLintptr(writeOffset), C.GLsizeiptr(size))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glUniformBlockBinding.xml
+func (gl *GL) UniformBlockBinding(program glbase.Program, v0, v1 uint32) {
+ C.gl3_1_glUniformBlockBinding(gl.funcs, C.GLuint(program), C.GLuint(v0), C.GLuint(v1))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetActiveUniformBlockName.xml
+func (gl *GL) GetActiveUniformBlockName(program glbase.Program, uniformBlockIndex uint32, bufSize int32, length []int32, uniformBlockName []byte) {
+ C.gl3_1_glGetActiveUniformBlockName(gl.funcs, C.GLuint(program), C.GLuint(uniformBlockIndex), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&uniformBlockName[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetActiveUniformBlockiv.xml
+func (gl *GL) GetActiveUniformBlockiv(program glbase.Program, uniformBlockIndex uint32, pname glbase.Enum, params []int32) {
+ C.gl3_1_glGetActiveUniformBlockiv(gl.funcs, C.GLuint(program), C.GLuint(uniformBlockIndex), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetUniformBlockIndex.xml
+func (gl *GL) GetUniformBlockIndex(program glbase.Program, uniformBlockName []byte) uint32 {
+ glresult := C.gl3_1_glGetUniformBlockIndex(gl.funcs, C.GLuint(program), (*C.GLchar)(unsafe.Pointer(&uniformBlockName[0])))
+ return uint32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetActiveUniformName.xml
+func (gl *GL) GetActiveUniformName(program glbase.Program, uniformIndex uint32, bufSize int32, length []int32, uniformName []byte) {
+ C.gl3_1_glGetActiveUniformName(gl.funcs, C.GLuint(program), C.GLuint(uniformIndex), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&uniformName[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetActiveUniformsiv.xml
+func (gl *GL) GetActiveUniformsiv(program glbase.Program, uniformCount int32, uniformIndices []uint32, pname glbase.Enum, params []int32) {
+ C.gl3_1_glGetActiveUniformsiv(gl.funcs, C.GLuint(program), C.GLsizei(uniformCount), (*C.GLuint)(unsafe.Pointer(&uniformIndices[0])), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPrimitiveRestartIndex.xml
+func (gl *GL) PrimitiveRestartIndex(index uint32) {
+ C.gl3_1_glPrimitiveRestartIndex(gl.funcs, C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexBuffer.xml
+func (gl *GL) TexBuffer(target, internalFormat glbase.Enum, buffer glbase.Buffer) {
+ C.gl3_1_glTexBuffer(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLuint(buffer))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDrawElementsInstanced.xml
+func (gl *GL) DrawElementsInstanced(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}, instancecount int32) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_1_glDrawElementsInstanced(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr, C.GLsizei(instancecount))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDrawArraysInstanced.xml
+func (gl *GL) DrawArraysInstanced(mode glbase.Enum, first, count int, instancecount int32) {
+ C.gl3_1_glDrawArraysInstanced(gl.funcs, C.GLenum(mode), C.GLint(first), C.GLsizei(count), C.GLsizei(instancecount))
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/3.2compat/funcs.cpp b/Godeps/_workspace/src/github.com/obscuren/qml/gl/3.2compat/funcs.cpp
new file mode 100644
index 000000000..c35066eba
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/3.2compat/funcs.cpp
@@ -0,0 +1,4140 @@
+
+// ** file automatically generated by glgen -- do not edit manually **
+
+#include <QOpenGLContext>
+#include <QtGui/qopenglfunctions_3_2_compatibility.h>
+
+#include "funcs.h"
+
+void *gl3_2compat_funcs() {
+ QOpenGLFunctions_3_2_Compatibility* funcs = QOpenGLContext::currentContext()->versionFunctions<QOpenGLFunctions_3_2_Compatibility>();
+ if (!funcs) {
+ return 0;
+ }
+ funcs->initializeOpenGLFunctions();
+ return funcs;
+}
+
+
+void gl3_2compat_glViewport(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glViewport(x, y, width, height);
+}
+
+void gl3_2compat_glDepthRange(void *_glfuncs, GLdouble nearVal, GLdouble farVal)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDepthRange(nearVal, farVal);
+}
+
+GLboolean gl3_2compat_glIsEnabled(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsEnabled(cap);
+}
+
+void gl3_2compat_glGetTexLevelParameteriv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexLevelParameteriv(target, level, pname, params);
+}
+
+void gl3_2compat_glGetTexLevelParameterfv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexLevelParameterfv(target, level, pname, params);
+}
+
+void gl3_2compat_glGetTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexParameteriv(target, pname, params);
+}
+
+void gl3_2compat_glGetTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexParameterfv(target, pname, params);
+}
+
+void gl3_2compat_glGetTexImage(void *_glfuncs, GLenum target, GLint level, GLenum format, GLenum gltype, GLvoid* pixels)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexImage(target, level, format, gltype, pixels);
+}
+
+void gl3_2compat_glGetIntegerv(void *_glfuncs, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetIntegerv(pname, params);
+}
+
+void gl3_2compat_glGetFloatv(void *_glfuncs, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetFloatv(pname, params);
+}
+
+GLenum gl3_2compat_glGetError(void *_glfuncs)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ return _qglfuncs->glGetError();
+}
+
+void gl3_2compat_glGetDoublev(void *_glfuncs, GLenum pname, GLdouble* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetDoublev(pname, params);
+}
+
+void gl3_2compat_glGetBooleanv(void *_glfuncs, GLenum pname, GLboolean* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetBooleanv(pname, params);
+}
+
+void gl3_2compat_glReadPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum gltype, GLvoid* pixels)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glReadPixels(x, y, width, height, format, gltype, pixels);
+}
+
+void gl3_2compat_glReadBuffer(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glReadBuffer(mode);
+}
+
+void gl3_2compat_glPixelStorei(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glPixelStorei(pname, param);
+}
+
+void gl3_2compat_glPixelStoref(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glPixelStoref(pname, param);
+}
+
+void gl3_2compat_glDepthFunc(void *_glfuncs, GLenum glfunc)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDepthFunc(glfunc);
+}
+
+void gl3_2compat_glStencilOp(void *_glfuncs, GLenum fail, GLenum zfail, GLenum zpass)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glStencilOp(fail, zfail, zpass);
+}
+
+void gl3_2compat_glStencilFunc(void *_glfuncs, GLenum glfunc, GLint ref, GLuint mask)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glStencilFunc(glfunc, ref, mask);
+}
+
+void gl3_2compat_glLogicOp(void *_glfuncs, GLenum opcode)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glLogicOp(opcode);
+}
+
+void gl3_2compat_glBlendFunc(void *_glfuncs, GLenum sfactor, GLenum dfactor)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glBlendFunc(sfactor, dfactor);
+}
+
+void gl3_2compat_glFlush(void *_glfuncs)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glFlush();
+}
+
+void gl3_2compat_glFinish(void *_glfuncs)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glFinish();
+}
+
+void gl3_2compat_glEnable(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glEnable(cap);
+}
+
+void gl3_2compat_glDisable(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDisable(cap);
+}
+
+void gl3_2compat_glDepthMask(void *_glfuncs, GLboolean flag)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDepthMask(flag);
+}
+
+void gl3_2compat_glColorMask(void *_glfuncs, GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorMask(red, green, blue, alpha);
+}
+
+void gl3_2compat_glStencilMask(void *_glfuncs, GLuint mask)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glStencilMask(mask);
+}
+
+void gl3_2compat_glClearDepth(void *_glfuncs, GLdouble depth)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glClearDepth(depth);
+}
+
+void gl3_2compat_glClearStencil(void *_glfuncs, GLint s)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glClearStencil(s);
+}
+
+void gl3_2compat_glClearColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glClearColor(red, green, blue, alpha);
+}
+
+void gl3_2compat_glClear(void *_glfuncs, GLbitfield mask)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glClear(mask);
+}
+
+void gl3_2compat_glDrawBuffer(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawBuffer(mode);
+}
+
+void gl3_2compat_glTexImage2D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexImage2D(target, level, internalFormat, width, height, border, format, gltype, pixels);
+}
+
+void gl3_2compat_glTexImage1D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexImage1D(target, level, internalFormat, width, border, format, gltype, pixels);
+}
+
+void gl3_2compat_glTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexParameteriv(target, pname, params);
+}
+
+void gl3_2compat_glTexParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexParameteri(target, pname, param);
+}
+
+void gl3_2compat_glTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexParameterfv(target, pname, params);
+}
+
+void gl3_2compat_glTexParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexParameterf(target, pname, param);
+}
+
+void gl3_2compat_glScissor(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glScissor(x, y, width, height);
+}
+
+void gl3_2compat_glPolygonMode(void *_glfuncs, GLenum face, GLenum mode)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glPolygonMode(face, mode);
+}
+
+void gl3_2compat_glPointSize(void *_glfuncs, GLfloat size)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glPointSize(size);
+}
+
+void gl3_2compat_glLineWidth(void *_glfuncs, GLfloat width)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glLineWidth(width);
+}
+
+void gl3_2compat_glHint(void *_glfuncs, GLenum target, GLenum mode)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glHint(target, mode);
+}
+
+void gl3_2compat_glFrontFace(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glFrontFace(mode);
+}
+
+void gl3_2compat_glCullFace(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glCullFace(mode);
+}
+
+void gl3_2compat_glIndexubv(void *_glfuncs, const GLubyte* c)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexubv(c);
+}
+
+void gl3_2compat_glIndexub(void *_glfuncs, GLubyte c)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexub(c);
+}
+
+GLboolean gl3_2compat_glIsTexture(void *_glfuncs, GLuint texture)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsTexture(texture);
+}
+
+void gl3_2compat_glGenTextures(void *_glfuncs, GLsizei n, GLuint* textures)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGenTextures(n, textures);
+}
+
+void gl3_2compat_glDeleteTextures(void *_glfuncs, GLsizei n, const GLuint* textures)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteTextures(n, textures);
+}
+
+void gl3_2compat_glBindTexture(void *_glfuncs, GLenum target, GLuint texture)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindTexture(target, texture);
+}
+
+void gl3_2compat_glTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexSubImage2D(target, level, xoffset, yoffset, width, height, format, gltype, pixels);
+}
+
+void gl3_2compat_glTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexSubImage1D(target, level, xoffset, width, format, gltype, pixels);
+}
+
+void gl3_2compat_glCopyTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage2D(target, level, xoffset, yoffset, x, y, width, height);
+}
+
+void gl3_2compat_glCopyTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage1D(target, level, xoffset, x, y, width);
+}
+
+void gl3_2compat_glCopyTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyTexImage2D(target, level, internalFormat, x, y, width, height, border);
+}
+
+void gl3_2compat_glCopyTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLint border)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyTexImage1D(target, level, internalFormat, x, y, width, border);
+}
+
+void gl3_2compat_glPolygonOffset(void *_glfuncs, GLfloat factor, GLfloat units)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glPolygonOffset(factor, units);
+}
+
+void gl3_2compat_glDrawElements(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawElements(mode, count, gltype, indices);
+}
+
+void gl3_2compat_glDrawArrays(void *_glfuncs, GLenum mode, GLint first, GLsizei count)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawArrays(mode, first, count);
+}
+
+void gl3_2compat_glCopyTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage3D(target, level, xoffset, yoffset, zoffset, x, y, width, height);
+}
+
+void gl3_2compat_glTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, gltype, pixels);
+}
+
+void gl3_2compat_glTexImage3D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexImage3D(target, level, internalFormat, width, height, depth, border, format, gltype, pixels);
+}
+
+void gl3_2compat_glDrawRangeElements(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawRangeElements(mode, start, end, count, gltype, indices);
+}
+
+void gl3_2compat_glBlendEquation(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glBlendEquation(mode);
+}
+
+void gl3_2compat_glBlendColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glBlendColor(red, green, blue, alpha);
+}
+
+void gl3_2compat_glGetCompressedTexImage(void *_glfuncs, GLenum target, GLint level, GLvoid* img)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetCompressedTexImage(target, level, img);
+}
+
+void gl3_2compat_glCompressedTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glCompressedTexSubImage1D(target, level, xoffset, width, format, imageSize, data);
+}
+
+void gl3_2compat_glCompressedTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glCompressedTexSubImage2D(target, level, xoffset, yoffset, width, height, format, imageSize, data);
+}
+
+void gl3_2compat_glCompressedTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glCompressedTexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, imageSize, data);
+}
+
+void gl3_2compat_glCompressedTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glCompressedTexImage1D(target, level, internalFormat, width, border, imageSize, data);
+}
+
+void gl3_2compat_glCompressedTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glCompressedTexImage2D(target, level, internalFormat, width, height, border, imageSize, data);
+}
+
+void gl3_2compat_glCompressedTexImage3D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glCompressedTexImage3D(target, level, internalFormat, width, height, depth, border, imageSize, data);
+}
+
+void gl3_2compat_glSampleCoverage(void *_glfuncs, GLfloat value, GLboolean invert)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glSampleCoverage(value, invert);
+}
+
+void gl3_2compat_glActiveTexture(void *_glfuncs, GLenum texture)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glActiveTexture(texture);
+}
+
+void gl3_2compat_glPointParameteriv(void *_glfuncs, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glPointParameteriv(pname, params);
+}
+
+void gl3_2compat_glPointParameteri(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glPointParameteri(pname, param);
+}
+
+void gl3_2compat_glPointParameterfv(void *_glfuncs, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glPointParameterfv(pname, params);
+}
+
+void gl3_2compat_glPointParameterf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glPointParameterf(pname, param);
+}
+
+void gl3_2compat_glMultiDrawArrays(void *_glfuncs, GLenum mode, const GLint* first, const GLsizei* count, GLsizei drawcount)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiDrawArrays(mode, first, count, drawcount);
+}
+
+void gl3_2compat_glBlendFuncSeparate(void *_glfuncs, GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glBlendFuncSeparate(sfactorRGB, dfactorRGB, sfactorAlpha, dfactorAlpha);
+}
+
+void gl3_2compat_glGetBufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetBufferParameteriv(target, pname, params);
+}
+
+GLboolean gl3_2compat_glUnmapBuffer(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ return _qglfuncs->glUnmapBuffer(target);
+}
+
+void gl3_2compat_glGetBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, GLvoid* data)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetBufferSubData(target, offset, size, data);
+}
+
+void gl3_2compat_glBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid* data)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glBufferSubData(target, offset, size, data);
+}
+
+void gl3_2compat_glBufferData(void *_glfuncs, GLenum target, GLsizeiptr size, const GLvoid* data, GLenum usage)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glBufferData(target, size, data, usage);
+}
+
+GLboolean gl3_2compat_glIsBuffer(void *_glfuncs, GLuint buffer)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsBuffer(buffer);
+}
+
+void gl3_2compat_glGenBuffers(void *_glfuncs, GLsizei n, GLuint* buffers)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGenBuffers(n, buffers);
+}
+
+void gl3_2compat_glDeleteBuffers(void *_glfuncs, GLsizei n, const GLuint* buffers)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteBuffers(n, buffers);
+}
+
+void gl3_2compat_glBindBuffer(void *_glfuncs, GLenum target, GLuint buffer)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindBuffer(target, buffer);
+}
+
+void gl3_2compat_glGetQueryObjectuiv(void *_glfuncs, GLuint id, GLenum pname, GLuint* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetQueryObjectuiv(id, pname, params);
+}
+
+void gl3_2compat_glGetQueryObjectiv(void *_glfuncs, GLuint id, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetQueryObjectiv(id, pname, params);
+}
+
+void gl3_2compat_glGetQueryiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetQueryiv(target, pname, params);
+}
+
+void gl3_2compat_glEndQuery(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glEndQuery(target);
+}
+
+void gl3_2compat_glBeginQuery(void *_glfuncs, GLenum target, GLuint id)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glBeginQuery(target, id);
+}
+
+GLboolean gl3_2compat_glIsQuery(void *_glfuncs, GLuint id)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsQuery(id);
+}
+
+void gl3_2compat_glDeleteQueries(void *_glfuncs, GLsizei n, const GLuint* ids)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteQueries(n, ids);
+}
+
+void gl3_2compat_glGenQueries(void *_glfuncs, GLsizei n, GLuint* ids)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGenQueries(n, ids);
+}
+
+void gl3_2compat_glVertexAttribPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLboolean normalized, GLsizei stride, const GLvoid* offset)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribPointer(index, size, gltype, normalized, stride, offset);
+}
+
+void gl3_2compat_glValidateProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glValidateProgram(program);
+}
+
+void gl3_2compat_glUniformMatrix4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4fv(location, count, transpose, value);
+}
+
+void gl3_2compat_glUniformMatrix3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3fv(location, count, transpose, value);
+}
+
+void gl3_2compat_glUniformMatrix2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2fv(location, count, transpose, value);
+}
+
+void gl3_2compat_glUniform4iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform4iv(location, count, value);
+}
+
+void gl3_2compat_glUniform3iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform3iv(location, count, value);
+}
+
+void gl3_2compat_glUniform2iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform2iv(location, count, value);
+}
+
+void gl3_2compat_glUniform1iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform1iv(location, count, value);
+}
+
+void gl3_2compat_glUniform4fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform4fv(location, count, value);
+}
+
+void gl3_2compat_glUniform3fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform3fv(location, count, value);
+}
+
+void gl3_2compat_glUniform2fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform2fv(location, count, value);
+}
+
+void gl3_2compat_glUniform1fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform1fv(location, count, value);
+}
+
+void gl3_2compat_glUniform4i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2, GLint v3)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform4i(location, v0, v1, v2, v3);
+}
+
+void gl3_2compat_glUniform3i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform3i(location, v0, v1, v2);
+}
+
+void gl3_2compat_glUniform2i(void *_glfuncs, GLint location, GLint v0, GLint v1)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform2i(location, v0, v1);
+}
+
+void gl3_2compat_glUniform1i(void *_glfuncs, GLint location, GLint v0)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform1i(location, v0);
+}
+
+void gl3_2compat_glUniform4f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform4f(location, v0, v1, v2, v3);
+}
+
+void gl3_2compat_glUniform3f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform3f(location, v0, v1, v2);
+}
+
+void gl3_2compat_glUniform2f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform2f(location, v0, v1);
+}
+
+void gl3_2compat_glUniform1f(void *_glfuncs, GLint location, GLfloat v0)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform1f(location, v0);
+}
+
+void gl3_2compat_glUseProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUseProgram(program);
+}
+
+void gl3_2compat_glShaderSource(void *_glfuncs, GLuint shader, GLsizei count, const GLchar** source, const GLint* length)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glShaderSource(shader, count, source, length);
+}
+
+void gl3_2compat_glLinkProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glLinkProgram(program);
+}
+
+GLboolean gl3_2compat_glIsShader(void *_glfuncs, GLuint shader)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsShader(shader);
+}
+
+GLboolean gl3_2compat_glIsProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsProgram(program);
+}
+
+void gl3_2compat_glGetVertexAttribiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribiv(index, pname, params);
+}
+
+void gl3_2compat_glGetVertexAttribfv(void *_glfuncs, GLuint index, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribfv(index, pname, params);
+}
+
+void gl3_2compat_glGetVertexAttribdv(void *_glfuncs, GLuint index, GLenum pname, GLdouble* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribdv(index, pname, params);
+}
+
+void gl3_2compat_glGetUniformiv(void *_glfuncs, GLuint program, GLint location, GLint* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetUniformiv(program, location, params);
+}
+
+void gl3_2compat_glGetUniformfv(void *_glfuncs, GLuint program, GLint location, GLfloat* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetUniformfv(program, location, params);
+}
+
+GLint gl3_2compat_glGetUniformLocation(void *_glfuncs, GLuint program, const GLchar* name)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ return _qglfuncs->glGetUniformLocation(program, name);
+}
+
+void gl3_2compat_glGetShaderSource(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* source)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetShaderSource(shader, bufSize, length, source);
+}
+
+void gl3_2compat_glGetShaderInfoLog(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* infoLog)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetShaderInfoLog(shader, bufSize, length, infoLog);
+}
+
+void gl3_2compat_glGetShaderiv(void *_glfuncs, GLuint shader, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetShaderiv(shader, pname, params);
+}
+
+void gl3_2compat_glGetProgramInfoLog(void *_glfuncs, GLuint program, GLsizei bufSize, GLsizei* length, GLchar* infoLog)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetProgramInfoLog(program, bufSize, length, infoLog);
+}
+
+void gl3_2compat_glGetProgramiv(void *_glfuncs, GLuint program, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetProgramiv(program, pname, params);
+}
+
+GLint gl3_2compat_glGetAttribLocation(void *_glfuncs, GLuint program, const GLchar* name)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ return _qglfuncs->glGetAttribLocation(program, name);
+}
+
+void gl3_2compat_glGetAttachedShaders(void *_glfuncs, GLuint program, GLsizei maxCount, GLsizei* count, GLuint* obj)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetAttachedShaders(program, maxCount, count, obj);
+}
+
+void gl3_2compat_glGetActiveUniform(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetActiveUniform(program, index, bufSize, length, size, gltype, name);
+}
+
+void gl3_2compat_glGetActiveAttrib(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetActiveAttrib(program, index, bufSize, length, size, gltype, name);
+}
+
+void gl3_2compat_glEnableVertexAttribArray(void *_glfuncs, GLuint index)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glEnableVertexAttribArray(index);
+}
+
+void gl3_2compat_glDisableVertexAttribArray(void *_glfuncs, GLuint index)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDisableVertexAttribArray(index);
+}
+
+void gl3_2compat_glDetachShader(void *_glfuncs, GLuint program, GLuint shader)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDetachShader(program, shader);
+}
+
+void gl3_2compat_glDeleteShader(void *_glfuncs, GLuint shader)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteShader(shader);
+}
+
+void gl3_2compat_glDeleteProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteProgram(program);
+}
+
+GLuint gl3_2compat_glCreateShader(void *_glfuncs, GLenum gltype)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ return _qglfuncs->glCreateShader(gltype);
+}
+
+GLuint gl3_2compat_glCreateProgram(void *_glfuncs)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ return _qglfuncs->glCreateProgram();
+}
+
+void gl3_2compat_glCompileShader(void *_glfuncs, GLuint shader)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glCompileShader(shader);
+}
+
+void gl3_2compat_glBindAttribLocation(void *_glfuncs, GLuint program, GLuint index, const GLchar* name)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindAttribLocation(program, index, name);
+}
+
+void gl3_2compat_glAttachShader(void *_glfuncs, GLuint program, GLuint shader)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glAttachShader(program, shader);
+}
+
+void gl3_2compat_glStencilMaskSeparate(void *_glfuncs, GLenum face, GLuint mask)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glStencilMaskSeparate(face, mask);
+}
+
+void gl3_2compat_glStencilFuncSeparate(void *_glfuncs, GLenum face, GLenum glfunc, GLint ref, GLuint mask)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glStencilFuncSeparate(face, glfunc, ref, mask);
+}
+
+void gl3_2compat_glStencilOpSeparate(void *_glfuncs, GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glStencilOpSeparate(face, sfail, dpfail, dppass);
+}
+
+void gl3_2compat_glDrawBuffers(void *_glfuncs, GLsizei n, const GLenum* bufs)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawBuffers(n, bufs);
+}
+
+void gl3_2compat_glBlendEquationSeparate(void *_glfuncs, GLenum modeRGB, GLenum modeAlpha)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glBlendEquationSeparate(modeRGB, modeAlpha);
+}
+
+void gl3_2compat_glUniformMatrix4x3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4x3fv(location, count, transpose, value);
+}
+
+void gl3_2compat_glUniformMatrix3x4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3x4fv(location, count, transpose, value);
+}
+
+void gl3_2compat_glUniformMatrix4x2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4x2fv(location, count, transpose, value);
+}
+
+void gl3_2compat_glUniformMatrix2x4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2x4fv(location, count, transpose, value);
+}
+
+void gl3_2compat_glUniformMatrix3x2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3x2fv(location, count, transpose, value);
+}
+
+void gl3_2compat_glUniformMatrix2x3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2x3fv(location, count, transpose, value);
+}
+
+GLboolean gl3_2compat_glIsVertexArray(void *_glfuncs, GLuint array)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsVertexArray(array);
+}
+
+void gl3_2compat_glGenVertexArrays(void *_glfuncs, GLsizei n, GLuint* arrays)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGenVertexArrays(n, arrays);
+}
+
+void gl3_2compat_glDeleteVertexArrays(void *_glfuncs, GLsizei n, const GLuint* arrays)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteVertexArrays(n, arrays);
+}
+
+void gl3_2compat_glBindVertexArray(void *_glfuncs, GLuint array)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindVertexArray(array);
+}
+
+void gl3_2compat_glFlushMappedBufferRange(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr length)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glFlushMappedBufferRange(target, offset, length);
+}
+
+void gl3_2compat_glFramebufferTextureLayer(void *_glfuncs, GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glFramebufferTextureLayer(target, attachment, texture, level, layer);
+}
+
+void gl3_2compat_glRenderbufferStorageMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLenum internalFormat, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRenderbufferStorageMultisample(target, samples, internalFormat, width, height);
+}
+
+void gl3_2compat_glBlitFramebuffer(void *_glfuncs, GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glBlitFramebuffer(srcX0, srcY0, srcX1, srcY1, dstX0, dstY0, dstX1, dstY1, mask, filter);
+}
+
+void gl3_2compat_glGenerateMipmap(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGenerateMipmap(target);
+}
+
+void gl3_2compat_glGetFramebufferAttachmentParameteriv(void *_glfuncs, GLenum target, GLenum attachment, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetFramebufferAttachmentParameteriv(target, attachment, pname, params);
+}
+
+void gl3_2compat_glFramebufferRenderbuffer(void *_glfuncs, GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glFramebufferRenderbuffer(target, attachment, renderbuffertarget, renderbuffer);
+}
+
+void gl3_2compat_glFramebufferTexture3D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glFramebufferTexture3D(target, attachment, textarget, texture, level, zoffset);
+}
+
+void gl3_2compat_glFramebufferTexture2D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glFramebufferTexture2D(target, attachment, textarget, texture, level);
+}
+
+void gl3_2compat_glFramebufferTexture1D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glFramebufferTexture1D(target, attachment, textarget, texture, level);
+}
+
+GLenum gl3_2compat_glCheckFramebufferStatus(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ return _qglfuncs->glCheckFramebufferStatus(target);
+}
+
+void gl3_2compat_glGenFramebuffers(void *_glfuncs, GLsizei n, GLuint* framebuffers)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGenFramebuffers(n, framebuffers);
+}
+
+void gl3_2compat_glDeleteFramebuffers(void *_glfuncs, GLsizei n, const GLuint* framebuffers)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteFramebuffers(n, framebuffers);
+}
+
+void gl3_2compat_glBindFramebuffer(void *_glfuncs, GLenum target, GLuint framebuffer)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindFramebuffer(target, framebuffer);
+}
+
+GLboolean gl3_2compat_glIsFramebuffer(void *_glfuncs, GLuint framebuffer)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsFramebuffer(framebuffer);
+}
+
+void gl3_2compat_glGetRenderbufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetRenderbufferParameteriv(target, pname, params);
+}
+
+void gl3_2compat_glRenderbufferStorage(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRenderbufferStorage(target, internalFormat, width, height);
+}
+
+void gl3_2compat_glGenRenderbuffers(void *_glfuncs, GLsizei n, GLuint* renderbuffers)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGenRenderbuffers(n, renderbuffers);
+}
+
+void gl3_2compat_glDeleteRenderbuffers(void *_glfuncs, GLsizei n, const GLuint* renderbuffers)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteRenderbuffers(n, renderbuffers);
+}
+
+void gl3_2compat_glBindRenderbuffer(void *_glfuncs, GLenum target, GLuint renderbuffer)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindRenderbuffer(target, renderbuffer);
+}
+
+GLboolean gl3_2compat_glIsRenderbuffer(void *_glfuncs, GLuint renderbuffer)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsRenderbuffer(renderbuffer);
+}
+
+void gl3_2compat_glClearBufferfi(void *_glfuncs, GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glClearBufferfi(buffer, drawbuffer, depth, stencil);
+}
+
+void gl3_2compat_glClearBufferfv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLfloat* value)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glClearBufferfv(buffer, drawbuffer, value);
+}
+
+void gl3_2compat_glClearBufferuiv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLuint* value)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glClearBufferuiv(buffer, drawbuffer, value);
+}
+
+void gl3_2compat_glClearBufferiv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLint* value)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glClearBufferiv(buffer, drawbuffer, value);
+}
+
+void gl3_2compat_glGetTexParameterIuiv(void *_glfuncs, GLenum target, GLenum pname, GLuint* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexParameterIuiv(target, pname, params);
+}
+
+void gl3_2compat_glGetTexParameterIiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexParameterIiv(target, pname, params);
+}
+
+void gl3_2compat_glTexParameterIuiv(void *_glfuncs, GLenum target, GLenum pname, const GLuint* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexParameterIuiv(target, pname, params);
+}
+
+void gl3_2compat_glTexParameterIiv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexParameterIiv(target, pname, params);
+}
+
+void gl3_2compat_glUniform4uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform4uiv(location, count, value);
+}
+
+void gl3_2compat_glUniform3uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform3uiv(location, count, value);
+}
+
+void gl3_2compat_glUniform2uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform2uiv(location, count, value);
+}
+
+void gl3_2compat_glUniform1uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform1uiv(location, count, value);
+}
+
+void gl3_2compat_glUniform4ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform4ui(location, v0, v1, v2, v3);
+}
+
+void gl3_2compat_glUniform3ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1, GLuint v2)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform3ui(location, v0, v1, v2);
+}
+
+void gl3_2compat_glUniform2ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform2ui(location, v0, v1);
+}
+
+void gl3_2compat_glUniform1ui(void *_glfuncs, GLint location, GLuint v0)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform1ui(location, v0);
+}
+
+GLint gl3_2compat_glGetFragDataLocation(void *_glfuncs, GLuint program, const GLchar* name)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ return _qglfuncs->glGetFragDataLocation(program, name);
+}
+
+void gl3_2compat_glBindFragDataLocation(void *_glfuncs, GLuint program, GLuint color, const GLchar* name)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindFragDataLocation(program, color, name);
+}
+
+void gl3_2compat_glGetUniformuiv(void *_glfuncs, GLuint program, GLint location, GLuint* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetUniformuiv(program, location, params);
+}
+
+void gl3_2compat_glGetVertexAttribIuiv(void *_glfuncs, GLuint index, GLenum pname, GLuint* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribIuiv(index, pname, params);
+}
+
+void gl3_2compat_glGetVertexAttribIiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribIiv(index, pname, params);
+}
+
+void gl3_2compat_glVertexAttribIPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribIPointer(index, size, gltype, stride, pointer);
+}
+
+void gl3_2compat_glEndConditionalRender(void *_glfuncs)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glEndConditionalRender();
+}
+
+void gl3_2compat_glBeginConditionalRender(void *_glfuncs, GLuint id, GLenum mode)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glBeginConditionalRender(id, mode);
+}
+
+void gl3_2compat_glClampColor(void *_glfuncs, GLenum target, GLenum clamp)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glClampColor(target, clamp);
+}
+
+void gl3_2compat_glGetTransformFeedbackVarying(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLsizei* size, GLenum* gltype, GLchar* name)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTransformFeedbackVarying(program, index, bufSize, length, size, gltype, name);
+}
+
+void gl3_2compat_glBindBufferBase(void *_glfuncs, GLenum target, GLuint index, GLuint buffer)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindBufferBase(target, index, buffer);
+}
+
+void gl3_2compat_glBindBufferRange(void *_glfuncs, GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindBufferRange(target, index, buffer, offset, size);
+}
+
+void gl3_2compat_glEndTransformFeedback(void *_glfuncs)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glEndTransformFeedback();
+}
+
+void gl3_2compat_glBeginTransformFeedback(void *_glfuncs, GLenum primitiveMode)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glBeginTransformFeedback(primitiveMode);
+}
+
+GLboolean gl3_2compat_glIsEnabledi(void *_glfuncs, GLenum target, GLuint index)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsEnabledi(target, index);
+}
+
+void gl3_2compat_glDisablei(void *_glfuncs, GLenum target, GLuint index)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDisablei(target, index);
+}
+
+void gl3_2compat_glEnablei(void *_glfuncs, GLenum target, GLuint index)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glEnablei(target, index);
+}
+
+void gl3_2compat_glGetIntegeri_v(void *_glfuncs, GLenum target, GLuint index, GLint* data)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetIntegeri_v(target, index, data);
+}
+
+void gl3_2compat_glGetBooleani_v(void *_glfuncs, GLenum target, GLuint index, GLboolean* data)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetBooleani_v(target, index, data);
+}
+
+void gl3_2compat_glColorMaski(void *_glfuncs, GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorMaski(index, r, g, b, a);
+}
+
+void gl3_2compat_glCopyBufferSubData(void *_glfuncs, GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyBufferSubData(readTarget, writeTarget, readOffset, writeOffset, size);
+}
+
+void gl3_2compat_glUniformBlockBinding(void *_glfuncs, GLuint program, GLuint v0, GLuint v1)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformBlockBinding(program, v0, v1);
+}
+
+void gl3_2compat_glGetActiveUniformBlockName(void *_glfuncs, GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei* length, GLchar* uniformBlockName)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetActiveUniformBlockName(program, uniformBlockIndex, bufSize, length, uniformBlockName);
+}
+
+void gl3_2compat_glGetActiveUniformBlockiv(void *_glfuncs, GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetActiveUniformBlockiv(program, uniformBlockIndex, pname, params);
+}
+
+GLuint gl3_2compat_glGetUniformBlockIndex(void *_glfuncs, GLuint program, const GLchar* uniformBlockName)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ return _qglfuncs->glGetUniformBlockIndex(program, uniformBlockName);
+}
+
+void gl3_2compat_glGetActiveUniformName(void *_glfuncs, GLuint program, GLuint uniformIndex, GLsizei bufSize, GLsizei* length, GLchar* uniformName)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetActiveUniformName(program, uniformIndex, bufSize, length, uniformName);
+}
+
+void gl3_2compat_glGetActiveUniformsiv(void *_glfuncs, GLuint program, GLsizei uniformCount, const GLuint* uniformIndices, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetActiveUniformsiv(program, uniformCount, uniformIndices, pname, params);
+}
+
+void gl3_2compat_glPrimitiveRestartIndex(void *_glfuncs, GLuint index)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glPrimitiveRestartIndex(index);
+}
+
+void gl3_2compat_glTexBuffer(void *_glfuncs, GLenum target, GLenum internalFormat, GLuint buffer)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexBuffer(target, internalFormat, buffer);
+}
+
+void gl3_2compat_glDrawElementsInstanced(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawElementsInstanced(mode, count, gltype, indices, instancecount);
+}
+
+void gl3_2compat_glDrawArraysInstanced(void *_glfuncs, GLenum mode, GLint first, GLsizei count, GLsizei instancecount)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawArraysInstanced(mode, first, count, instancecount);
+}
+
+void gl3_2compat_glSampleMaski(void *_glfuncs, GLuint index, GLbitfield mask)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glSampleMaski(index, mask);
+}
+
+void gl3_2compat_glGetMultisamplefv(void *_glfuncs, GLenum pname, GLuint index, GLfloat* val)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetMultisamplefv(pname, index, val);
+}
+
+void gl3_2compat_glTexImage3DMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexImage3DMultisample(target, samples, internalFormat, width, height, depth, fixedsamplelocations);
+}
+
+void gl3_2compat_glTexImage2DMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLint internalFormat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexImage2DMultisample(target, samples, internalFormat, width, height, fixedsamplelocations);
+}
+
+void gl3_2compat_glGetSynciv(void *_glfuncs, GLsync sync, GLenum pname, GLsizei bufSize, GLsizei* length, GLint* values)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetSynciv(sync, pname, bufSize, length, values);
+}
+
+void gl3_2compat_glGetInteger64v(void *_glfuncs, GLenum pname, GLint64* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetInteger64v(pname, params);
+}
+
+void gl3_2compat_glWaitSync(void *_glfuncs, GLsync sync, GLbitfield flags, GLuint64 timeout)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glWaitSync(sync, flags, timeout);
+}
+
+GLenum gl3_2compat_glClientWaitSync(void *_glfuncs, GLsync sync, GLbitfield flags, GLuint64 timeout)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ return _qglfuncs->glClientWaitSync(sync, flags, timeout);
+}
+
+void gl3_2compat_glDeleteSync(void *_glfuncs, GLsync sync)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteSync(sync);
+}
+
+GLboolean gl3_2compat_glIsSync(void *_glfuncs, GLsync sync)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsSync(sync);
+}
+
+GLsync gl3_2compat_glFenceSync(void *_glfuncs, GLenum condition, GLbitfield flags)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ return _qglfuncs->glFenceSync(condition, flags);
+}
+
+void gl3_2compat_glProvokingVertex(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glProvokingVertex(mode);
+}
+
+void gl3_2compat_glDrawElementsInstancedBaseVertex(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount, GLint basevertex)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawElementsInstancedBaseVertex(mode, count, gltype, indices, instancecount, basevertex);
+}
+
+void gl3_2compat_glDrawRangeElementsBaseVertex(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices, GLint basevertex)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawRangeElementsBaseVertex(mode, start, end, count, gltype, indices, basevertex);
+}
+
+void gl3_2compat_glDrawElementsBaseVertex(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLint basevertex)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawElementsBaseVertex(mode, count, gltype, indices, basevertex);
+}
+
+void gl3_2compat_glFramebufferTexture(void *_glfuncs, GLenum target, GLenum attachment, GLuint texture, GLint level)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glFramebufferTexture(target, attachment, texture, level);
+}
+
+void gl3_2compat_glGetBufferParameteri64v(void *_glfuncs, GLenum target, GLenum pname, GLint64* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetBufferParameteri64v(target, pname, params);
+}
+
+void gl3_2compat_glGetInteger64i_v(void *_glfuncs, GLenum target, GLuint index, GLint64* data)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetInteger64i_v(target, index, data);
+}
+
+void gl3_2compat_glTranslatef(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTranslatef(x, y, z);
+}
+
+void gl3_2compat_glTranslated(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTranslated(x, y, z);
+}
+
+void gl3_2compat_glScalef(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glScalef(x, y, z);
+}
+
+void gl3_2compat_glScaled(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glScaled(x, y, z);
+}
+
+void gl3_2compat_glRotatef(void *_glfuncs, GLfloat angle, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRotatef(angle, x, y, z);
+}
+
+void gl3_2compat_glRotated(void *_glfuncs, GLdouble angle, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRotated(angle, x, y, z);
+}
+
+void gl3_2compat_glPushMatrix(void *_glfuncs)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glPushMatrix();
+}
+
+void gl3_2compat_glPopMatrix(void *_glfuncs)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glPopMatrix();
+}
+
+void gl3_2compat_glOrtho(void *_glfuncs, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glOrtho(left, right, bottom, top, zNear, zFar);
+}
+
+void gl3_2compat_glMultMatrixd(void *_glfuncs, const GLdouble* m)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultMatrixd(m);
+}
+
+void gl3_2compat_glMultMatrixf(void *_glfuncs, const GLfloat* m)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultMatrixf(m);
+}
+
+void gl3_2compat_glMatrixMode(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMatrixMode(mode);
+}
+
+void gl3_2compat_glLoadMatrixd(void *_glfuncs, const GLdouble* m)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glLoadMatrixd(m);
+}
+
+void gl3_2compat_glLoadMatrixf(void *_glfuncs, const GLfloat* m)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glLoadMatrixf(m);
+}
+
+void gl3_2compat_glLoadIdentity(void *_glfuncs)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glLoadIdentity();
+}
+
+void gl3_2compat_glFrustum(void *_glfuncs, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glFrustum(left, right, bottom, top, zNear, zFar);
+}
+
+GLboolean gl3_2compat_glIsList(void *_glfuncs, GLuint list)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsList(list);
+}
+
+void gl3_2compat_glGetTexGeniv(void *_glfuncs, GLenum coord, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexGeniv(coord, pname, params);
+}
+
+void gl3_2compat_glGetTexGenfv(void *_glfuncs, GLenum coord, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexGenfv(coord, pname, params);
+}
+
+void gl3_2compat_glGetTexGendv(void *_glfuncs, GLenum coord, GLenum pname, GLdouble* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexGendv(coord, pname, params);
+}
+
+void gl3_2compat_glGetTexEnviv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexEnviv(target, pname, params);
+}
+
+void gl3_2compat_glGetTexEnvfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexEnvfv(target, pname, params);
+}
+
+void gl3_2compat_glGetPolygonStipple(void *_glfuncs, GLubyte* mask)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetPolygonStipple(mask);
+}
+
+void gl3_2compat_glGetPixelMapusv(void *_glfuncs, GLenum glmap, GLushort* values)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetPixelMapusv(glmap, values);
+}
+
+void gl3_2compat_glGetPixelMapuiv(void *_glfuncs, GLenum glmap, GLuint* values)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetPixelMapuiv(glmap, values);
+}
+
+void gl3_2compat_glGetPixelMapfv(void *_glfuncs, GLenum glmap, GLfloat* values)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetPixelMapfv(glmap, values);
+}
+
+void gl3_2compat_glGetMaterialiv(void *_glfuncs, GLenum face, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetMaterialiv(face, pname, params);
+}
+
+void gl3_2compat_glGetMaterialfv(void *_glfuncs, GLenum face, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetMaterialfv(face, pname, params);
+}
+
+void gl3_2compat_glGetMapiv(void *_glfuncs, GLenum target, GLenum query, GLint* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetMapiv(target, query, v);
+}
+
+void gl3_2compat_glGetMapfv(void *_glfuncs, GLenum target, GLenum query, GLfloat* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetMapfv(target, query, v);
+}
+
+void gl3_2compat_glGetMapdv(void *_glfuncs, GLenum target, GLenum query, GLdouble* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetMapdv(target, query, v);
+}
+
+void gl3_2compat_glGetLightiv(void *_glfuncs, GLenum light, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetLightiv(light, pname, params);
+}
+
+void gl3_2compat_glGetLightfv(void *_glfuncs, GLenum light, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetLightfv(light, pname, params);
+}
+
+void gl3_2compat_glGetClipPlane(void *_glfuncs, GLenum plane, GLdouble* equation)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetClipPlane(plane, equation);
+}
+
+void gl3_2compat_glDrawPixels(void *_glfuncs, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawPixels(width, height, format, gltype, pixels);
+}
+
+void gl3_2compat_glCopyPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum gltype)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyPixels(x, y, width, height, gltype);
+}
+
+void gl3_2compat_glPixelMapusv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLushort* values)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glPixelMapusv(glmap, mapsize, values);
+}
+
+void gl3_2compat_glPixelMapuiv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLuint* values)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glPixelMapuiv(glmap, mapsize, values);
+}
+
+void gl3_2compat_glPixelMapfv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLfloat* values)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glPixelMapfv(glmap, mapsize, values);
+}
+
+void gl3_2compat_glPixelTransferi(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glPixelTransferi(pname, param);
+}
+
+void gl3_2compat_glPixelTransferf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glPixelTransferf(pname, param);
+}
+
+void gl3_2compat_glPixelZoom(void *_glfuncs, GLfloat xfactor, GLfloat yfactor)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glPixelZoom(xfactor, yfactor);
+}
+
+void gl3_2compat_glAlphaFunc(void *_glfuncs, GLenum glfunc, GLfloat ref)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glAlphaFunc(glfunc, ref);
+}
+
+void gl3_2compat_glEvalPoint2(void *_glfuncs, GLint i, GLint j)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalPoint2(i, j);
+}
+
+void gl3_2compat_glEvalMesh2(void *_glfuncs, GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalMesh2(mode, i1, i2, j1, j2);
+}
+
+void gl3_2compat_glEvalPoint1(void *_glfuncs, GLint i)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalPoint1(i);
+}
+
+void gl3_2compat_glEvalMesh1(void *_glfuncs, GLenum mode, GLint i1, GLint i2)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalMesh1(mode, i1, i2);
+}
+
+void gl3_2compat_glEvalCoord2fv(void *_glfuncs, const GLfloat* u)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalCoord2fv(u);
+}
+
+void gl3_2compat_glEvalCoord2f(void *_glfuncs, GLfloat u, GLfloat v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalCoord2f(u, v);
+}
+
+void gl3_2compat_glEvalCoord2dv(void *_glfuncs, const GLdouble* u)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalCoord2dv(u);
+}
+
+void gl3_2compat_glEvalCoord2d(void *_glfuncs, GLdouble u, GLdouble v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalCoord2d(u, v);
+}
+
+void gl3_2compat_glEvalCoord1fv(void *_glfuncs, const GLfloat* u)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalCoord1fv(u);
+}
+
+void gl3_2compat_glEvalCoord1f(void *_glfuncs, GLfloat u)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalCoord1f(u);
+}
+
+void gl3_2compat_glEvalCoord1dv(void *_glfuncs, const GLdouble* u)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalCoord1dv(u);
+}
+
+void gl3_2compat_glEvalCoord1d(void *_glfuncs, GLdouble u)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalCoord1d(u);
+}
+
+void gl3_2compat_glMapGrid2f(void *_glfuncs, GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMapGrid2f(un, u1, u2, vn, v1, v2);
+}
+
+void gl3_2compat_glMapGrid2d(void *_glfuncs, GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMapGrid2d(un, u1, u2, vn, v1, v2);
+}
+
+void gl3_2compat_glMapGrid1f(void *_glfuncs, GLint un, GLfloat u1, GLfloat u2)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMapGrid1f(un, u1, u2);
+}
+
+void gl3_2compat_glMapGrid1d(void *_glfuncs, GLint un, GLdouble u1, GLdouble u2)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMapGrid1d(un, u1, u2);
+}
+
+void gl3_2compat_glMap2f(void *_glfuncs, GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat* points)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMap2f(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+void gl3_2compat_glMap2d(void *_glfuncs, GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble* points)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMap2d(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+void gl3_2compat_glMap1f(void *_glfuncs, GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat* points)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMap1f(target, u1, u2, stride, order, points);
+}
+
+void gl3_2compat_glMap1d(void *_glfuncs, GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble* points)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMap1d(target, u1, u2, stride, order, points);
+}
+
+void gl3_2compat_glPushAttrib(void *_glfuncs, GLbitfield mask)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glPushAttrib(mask);
+}
+
+void gl3_2compat_glPopAttrib(void *_glfuncs)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glPopAttrib();
+}
+
+void gl3_2compat_glAccum(void *_glfuncs, GLenum op, GLfloat value)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glAccum(op, value);
+}
+
+void gl3_2compat_glIndexMask(void *_glfuncs, GLuint mask)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexMask(mask);
+}
+
+void gl3_2compat_glClearIndex(void *_glfuncs, GLfloat c)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glClearIndex(c);
+}
+
+void gl3_2compat_glClearAccum(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glClearAccum(red, green, blue, alpha);
+}
+
+void gl3_2compat_glPushName(void *_glfuncs, GLuint name)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glPushName(name);
+}
+
+void gl3_2compat_glPopName(void *_glfuncs)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glPopName();
+}
+
+void gl3_2compat_glPassThrough(void *_glfuncs, GLfloat token)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glPassThrough(token);
+}
+
+void gl3_2compat_glLoadName(void *_glfuncs, GLuint name)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glLoadName(name);
+}
+
+void gl3_2compat_glInitNames(void *_glfuncs)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glInitNames();
+}
+
+GLint gl3_2compat_glRenderMode(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ return _qglfuncs->glRenderMode(mode);
+}
+
+void gl3_2compat_glSelectBuffer(void *_glfuncs, GLsizei size, GLuint* buffer)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glSelectBuffer(size, buffer);
+}
+
+void gl3_2compat_glFeedbackBuffer(void *_glfuncs, GLsizei size, GLenum gltype, GLfloat* buffer)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glFeedbackBuffer(size, gltype, buffer);
+}
+
+void gl3_2compat_glTexGeniv(void *_glfuncs, GLenum coord, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexGeniv(coord, pname, params);
+}
+
+void gl3_2compat_glTexGeni(void *_glfuncs, GLenum coord, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexGeni(coord, pname, param);
+}
+
+void gl3_2compat_glTexGenfv(void *_glfuncs, GLenum coord, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexGenfv(coord, pname, params);
+}
+
+void gl3_2compat_glTexGenf(void *_glfuncs, GLenum coord, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexGenf(coord, pname, param);
+}
+
+void gl3_2compat_glTexGendv(void *_glfuncs, GLenum coord, GLenum pname, const GLdouble* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexGendv(coord, pname, params);
+}
+
+void gl3_2compat_glTexGend(void *_glfuncs, GLenum coord, GLenum pname, GLdouble param)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexGend(coord, pname, param);
+}
+
+void gl3_2compat_glTexEnviv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexEnviv(target, pname, params);
+}
+
+void gl3_2compat_glTexEnvi(void *_glfuncs, GLenum target, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexEnvi(target, pname, param);
+}
+
+void gl3_2compat_glTexEnvfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexEnvfv(target, pname, params);
+}
+
+void gl3_2compat_glTexEnvf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexEnvf(target, pname, param);
+}
+
+void gl3_2compat_glShadeModel(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glShadeModel(mode);
+}
+
+void gl3_2compat_glPolygonStipple(void *_glfuncs, const GLubyte* mask)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glPolygonStipple(mask);
+}
+
+void gl3_2compat_glMaterialiv(void *_glfuncs, GLenum face, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMaterialiv(face, pname, params);
+}
+
+void gl3_2compat_glMateriali(void *_glfuncs, GLenum face, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMateriali(face, pname, param);
+}
+
+void gl3_2compat_glMaterialfv(void *_glfuncs, GLenum face, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMaterialfv(face, pname, params);
+}
+
+void gl3_2compat_glMaterialf(void *_glfuncs, GLenum face, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMaterialf(face, pname, param);
+}
+
+void gl3_2compat_glLineStipple(void *_glfuncs, GLint factor, GLushort pattern)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glLineStipple(factor, pattern);
+}
+
+void gl3_2compat_glLightModeliv(void *_glfuncs, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glLightModeliv(pname, params);
+}
+
+void gl3_2compat_glLightModeli(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glLightModeli(pname, param);
+}
+
+void gl3_2compat_glLightModelfv(void *_glfuncs, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glLightModelfv(pname, params);
+}
+
+void gl3_2compat_glLightModelf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glLightModelf(pname, param);
+}
+
+void gl3_2compat_glLightiv(void *_glfuncs, GLenum light, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glLightiv(light, pname, params);
+}
+
+void gl3_2compat_glLighti(void *_glfuncs, GLenum light, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glLighti(light, pname, param);
+}
+
+void gl3_2compat_glLightfv(void *_glfuncs, GLenum light, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glLightfv(light, pname, params);
+}
+
+void gl3_2compat_glLightf(void *_glfuncs, GLenum light, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glLightf(light, pname, param);
+}
+
+void gl3_2compat_glFogiv(void *_glfuncs, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glFogiv(pname, params);
+}
+
+void gl3_2compat_glFogi(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glFogi(pname, param);
+}
+
+void gl3_2compat_glFogfv(void *_glfuncs, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glFogfv(pname, params);
+}
+
+void gl3_2compat_glFogf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glFogf(pname, param);
+}
+
+void gl3_2compat_glColorMaterial(void *_glfuncs, GLenum face, GLenum mode)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorMaterial(face, mode);
+}
+
+void gl3_2compat_glClipPlane(void *_glfuncs, GLenum plane, const GLdouble* equation)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glClipPlane(plane, equation);
+}
+
+void gl3_2compat_glVertex4sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex4sv(v);
+}
+
+void gl3_2compat_glVertex4s(void *_glfuncs, GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex4s(x, y, z, w);
+}
+
+void gl3_2compat_glVertex4iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex4iv(v);
+}
+
+void gl3_2compat_glVertex4i(void *_glfuncs, GLint x, GLint y, GLint z, GLint w)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex4i(x, y, z, w);
+}
+
+void gl3_2compat_glVertex4fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex4fv(v);
+}
+
+void gl3_2compat_glVertex4f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex4f(x, y, z, w);
+}
+
+void gl3_2compat_glVertex4dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex4dv(v);
+}
+
+void gl3_2compat_glVertex4d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex4d(x, y, z, w);
+}
+
+void gl3_2compat_glVertex3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex3sv(v);
+}
+
+void gl3_2compat_glVertex3s(void *_glfuncs, GLshort x, GLshort y, GLshort z)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex3s(x, y, z);
+}
+
+void gl3_2compat_glVertex3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex3iv(v);
+}
+
+void gl3_2compat_glVertex3i(void *_glfuncs, GLint x, GLint y, GLint z)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex3i(x, y, z);
+}
+
+void gl3_2compat_glVertex3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex3fv(v);
+}
+
+void gl3_2compat_glVertex3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex3f(x, y, z);
+}
+
+void gl3_2compat_glVertex3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex3dv(v);
+}
+
+void gl3_2compat_glVertex3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex3d(x, y, z);
+}
+
+void gl3_2compat_glVertex2sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex2sv(v);
+}
+
+void gl3_2compat_glVertex2s(void *_glfuncs, GLshort x, GLshort y)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex2s(x, y);
+}
+
+void gl3_2compat_glVertex2iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex2iv(v);
+}
+
+void gl3_2compat_glVertex2i(void *_glfuncs, GLint x, GLint y)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex2i(x, y);
+}
+
+void gl3_2compat_glVertex2fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex2fv(v);
+}
+
+void gl3_2compat_glVertex2f(void *_glfuncs, GLfloat x, GLfloat y)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex2f(x, y);
+}
+
+void gl3_2compat_glVertex2dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex2dv(v);
+}
+
+void gl3_2compat_glVertex2d(void *_glfuncs, GLdouble x, GLdouble y)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex2d(x, y);
+}
+
+void gl3_2compat_glTexCoord4sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord4sv(v);
+}
+
+void gl3_2compat_glTexCoord4s(void *_glfuncs, GLshort s, GLshort t, GLshort r, GLshort q)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord4s(s, t, r, q);
+}
+
+void gl3_2compat_glTexCoord4iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord4iv(v);
+}
+
+void gl3_2compat_glTexCoord4i(void *_glfuncs, GLint s, GLint t, GLint r, GLint q)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord4i(s, t, r, q);
+}
+
+void gl3_2compat_glTexCoord4fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord4fv(v);
+}
+
+void gl3_2compat_glTexCoord4f(void *_glfuncs, GLfloat s, GLfloat t, GLfloat r, GLfloat q)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord4f(s, t, r, q);
+}
+
+void gl3_2compat_glTexCoord4dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord4dv(v);
+}
+
+void gl3_2compat_glTexCoord4d(void *_glfuncs, GLdouble s, GLdouble t, GLdouble r, GLdouble q)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord4d(s, t, r, q);
+}
+
+void gl3_2compat_glTexCoord3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord3sv(v);
+}
+
+void gl3_2compat_glTexCoord3s(void *_glfuncs, GLshort s, GLshort t, GLshort r)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord3s(s, t, r);
+}
+
+void gl3_2compat_glTexCoord3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord3iv(v);
+}
+
+void gl3_2compat_glTexCoord3i(void *_glfuncs, GLint s, GLint t, GLint r)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord3i(s, t, r);
+}
+
+void gl3_2compat_glTexCoord3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord3fv(v);
+}
+
+void gl3_2compat_glTexCoord3f(void *_glfuncs, GLfloat s, GLfloat t, GLfloat r)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord3f(s, t, r);
+}
+
+void gl3_2compat_glTexCoord3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord3dv(v);
+}
+
+void gl3_2compat_glTexCoord3d(void *_glfuncs, GLdouble s, GLdouble t, GLdouble r)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord3d(s, t, r);
+}
+
+void gl3_2compat_glTexCoord2sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord2sv(v);
+}
+
+void gl3_2compat_glTexCoord2s(void *_glfuncs, GLshort s, GLshort t)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord2s(s, t);
+}
+
+void gl3_2compat_glTexCoord2iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord2iv(v);
+}
+
+void gl3_2compat_glTexCoord2i(void *_glfuncs, GLint s, GLint t)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord2i(s, t);
+}
+
+void gl3_2compat_glTexCoord2fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord2fv(v);
+}
+
+void gl3_2compat_glTexCoord2f(void *_glfuncs, GLfloat s, GLfloat t)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord2f(s, t);
+}
+
+void gl3_2compat_glTexCoord2dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord2dv(v);
+}
+
+void gl3_2compat_glTexCoord2d(void *_glfuncs, GLdouble s, GLdouble t)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord2d(s, t);
+}
+
+void gl3_2compat_glTexCoord1sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord1sv(v);
+}
+
+void gl3_2compat_glTexCoord1s(void *_glfuncs, GLshort s)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord1s(s);
+}
+
+void gl3_2compat_glTexCoord1iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord1iv(v);
+}
+
+void gl3_2compat_glTexCoord1i(void *_glfuncs, GLint s)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord1i(s);
+}
+
+void gl3_2compat_glTexCoord1fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord1fv(v);
+}
+
+void gl3_2compat_glTexCoord1f(void *_glfuncs, GLfloat s)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord1f(s);
+}
+
+void gl3_2compat_glTexCoord1dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord1dv(v);
+}
+
+void gl3_2compat_glTexCoord1d(void *_glfuncs, GLdouble s)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord1d(s);
+}
+
+void gl3_2compat_glRectsv(void *_glfuncs, const GLshort* v1, const GLshort* v2)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRectsv(v1, v2);
+}
+
+void gl3_2compat_glRects(void *_glfuncs, GLshort x1, GLshort y1, GLshort x2, GLshort y2)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRects(x1, y1, x2, y2);
+}
+
+void gl3_2compat_glRectiv(void *_glfuncs, const GLint* v1, const GLint* v2)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRectiv(v1, v2);
+}
+
+void gl3_2compat_glRecti(void *_glfuncs, GLint x1, GLint y1, GLint x2, GLint y2)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRecti(x1, y1, x2, y2);
+}
+
+void gl3_2compat_glRectfv(void *_glfuncs, const GLfloat* v1, const GLfloat* v2)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRectfv(v1, v2);
+}
+
+void gl3_2compat_glRectf(void *_glfuncs, GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRectf(x1, y1, x2, y2);
+}
+
+void gl3_2compat_glRectdv(void *_glfuncs, const GLdouble* v1, const GLdouble* v2)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRectdv(v1, v2);
+}
+
+void gl3_2compat_glRectd(void *_glfuncs, GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRectd(x1, y1, x2, y2);
+}
+
+void gl3_2compat_glRasterPos4sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos4sv(v);
+}
+
+void gl3_2compat_glRasterPos4s(void *_glfuncs, GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos4s(x, y, z, w);
+}
+
+void gl3_2compat_glRasterPos4iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos4iv(v);
+}
+
+void gl3_2compat_glRasterPos4i(void *_glfuncs, GLint x, GLint y, GLint z, GLint w)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos4i(x, y, z, w);
+}
+
+void gl3_2compat_glRasterPos4fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos4fv(v);
+}
+
+void gl3_2compat_glRasterPos4f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos4f(x, y, z, w);
+}
+
+void gl3_2compat_glRasterPos4dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos4dv(v);
+}
+
+void gl3_2compat_glRasterPos4d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos4d(x, y, z, w);
+}
+
+void gl3_2compat_glRasterPos3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos3sv(v);
+}
+
+void gl3_2compat_glRasterPos3s(void *_glfuncs, GLshort x, GLshort y, GLshort z)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos3s(x, y, z);
+}
+
+void gl3_2compat_glRasterPos3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos3iv(v);
+}
+
+void gl3_2compat_glRasterPos3i(void *_glfuncs, GLint x, GLint y, GLint z)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos3i(x, y, z);
+}
+
+void gl3_2compat_glRasterPos3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos3fv(v);
+}
+
+void gl3_2compat_glRasterPos3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos3f(x, y, z);
+}
+
+void gl3_2compat_glRasterPos3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos3dv(v);
+}
+
+void gl3_2compat_glRasterPos3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos3d(x, y, z);
+}
+
+void gl3_2compat_glRasterPos2sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos2sv(v);
+}
+
+void gl3_2compat_glRasterPos2s(void *_glfuncs, GLshort x, GLshort y)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos2s(x, y);
+}
+
+void gl3_2compat_glRasterPos2iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos2iv(v);
+}
+
+void gl3_2compat_glRasterPos2i(void *_glfuncs, GLint x, GLint y)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos2i(x, y);
+}
+
+void gl3_2compat_glRasterPos2fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos2fv(v);
+}
+
+void gl3_2compat_glRasterPos2f(void *_glfuncs, GLfloat x, GLfloat y)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos2f(x, y);
+}
+
+void gl3_2compat_glRasterPos2dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos2dv(v);
+}
+
+void gl3_2compat_glRasterPos2d(void *_glfuncs, GLdouble x, GLdouble y)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos2d(x, y);
+}
+
+void gl3_2compat_glNormal3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormal3sv(v);
+}
+
+void gl3_2compat_glNormal3s(void *_glfuncs, GLshort nx, GLshort ny, GLshort nz)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormal3s(nx, ny, nz);
+}
+
+void gl3_2compat_glNormal3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormal3iv(v);
+}
+
+void gl3_2compat_glNormal3i(void *_glfuncs, GLint nx, GLint ny, GLint nz)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormal3i(nx, ny, nz);
+}
+
+void gl3_2compat_glNormal3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormal3fv(v);
+}
+
+void gl3_2compat_glNormal3f(void *_glfuncs, GLfloat nx, GLfloat ny, GLfloat nz)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormal3f(nx, ny, nz);
+}
+
+void gl3_2compat_glNormal3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormal3dv(v);
+}
+
+void gl3_2compat_glNormal3d(void *_glfuncs, GLdouble nx, GLdouble ny, GLdouble nz)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormal3d(nx, ny, nz);
+}
+
+void gl3_2compat_glNormal3bv(void *_glfuncs, const GLbyte* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormal3bv(v);
+}
+
+void gl3_2compat_glNormal3b(void *_glfuncs, GLbyte nx, GLbyte ny, GLbyte nz)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormal3b(nx, ny, nz);
+}
+
+void gl3_2compat_glIndexsv(void *_glfuncs, const GLshort* c)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexsv(c);
+}
+
+void gl3_2compat_glIndexs(void *_glfuncs, GLshort c)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexs(c);
+}
+
+void gl3_2compat_glIndexiv(void *_glfuncs, const GLint* c)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexiv(c);
+}
+
+void gl3_2compat_glIndexi(void *_glfuncs, GLint c)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexi(c);
+}
+
+void gl3_2compat_glIndexfv(void *_glfuncs, const GLfloat* c)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexfv(c);
+}
+
+void gl3_2compat_glIndexf(void *_glfuncs, GLfloat c)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexf(c);
+}
+
+void gl3_2compat_glIndexdv(void *_glfuncs, const GLdouble* c)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexdv(c);
+}
+
+void gl3_2compat_glIndexd(void *_glfuncs, GLdouble c)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexd(c);
+}
+
+void gl3_2compat_glEnd(void *_glfuncs)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glEnd();
+}
+
+void gl3_2compat_glEdgeFlagv(void *_glfuncs, const GLboolean* flag)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glEdgeFlagv(flag);
+}
+
+void gl3_2compat_glEdgeFlag(void *_glfuncs, GLboolean flag)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glEdgeFlag(flag);
+}
+
+void gl3_2compat_glColor4usv(void *_glfuncs, const GLushort* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4usv(v);
+}
+
+void gl3_2compat_glColor4us(void *_glfuncs, GLushort red, GLushort green, GLushort blue, GLushort alpha)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4us(red, green, blue, alpha);
+}
+
+void gl3_2compat_glColor4uiv(void *_glfuncs, const GLuint* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4uiv(v);
+}
+
+void gl3_2compat_glColor4ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue, GLuint alpha)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4ui(red, green, blue, alpha);
+}
+
+void gl3_2compat_glColor4ubv(void *_glfuncs, const GLubyte* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4ubv(v);
+}
+
+void gl3_2compat_glColor4ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4ub(red, green, blue, alpha);
+}
+
+void gl3_2compat_glColor4sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4sv(v);
+}
+
+void gl3_2compat_glColor4s(void *_glfuncs, GLshort red, GLshort green, GLshort blue, GLshort alpha)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4s(red, green, blue, alpha);
+}
+
+void gl3_2compat_glColor4iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4iv(v);
+}
+
+void gl3_2compat_glColor4i(void *_glfuncs, GLint red, GLint green, GLint blue, GLint alpha)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4i(red, green, blue, alpha);
+}
+
+void gl3_2compat_glColor4fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4fv(v);
+}
+
+void gl3_2compat_glColor4f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4f(red, green, blue, alpha);
+}
+
+void gl3_2compat_glColor4dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4dv(v);
+}
+
+void gl3_2compat_glColor4d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4d(red, green, blue, alpha);
+}
+
+void gl3_2compat_glColor4bv(void *_glfuncs, const GLbyte* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4bv(v);
+}
+
+void gl3_2compat_glColor4b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4b(red, green, blue, alpha);
+}
+
+void gl3_2compat_glColor3usv(void *_glfuncs, const GLushort* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3usv(v);
+}
+
+void gl3_2compat_glColor3us(void *_glfuncs, GLushort red, GLushort green, GLushort blue)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3us(red, green, blue);
+}
+
+void gl3_2compat_glColor3uiv(void *_glfuncs, const GLuint* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3uiv(v);
+}
+
+void gl3_2compat_glColor3ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3ui(red, green, blue);
+}
+
+void gl3_2compat_glColor3ubv(void *_glfuncs, const GLubyte* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3ubv(v);
+}
+
+void gl3_2compat_glColor3ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3ub(red, green, blue);
+}
+
+void gl3_2compat_glColor3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3sv(v);
+}
+
+void gl3_2compat_glColor3s(void *_glfuncs, GLshort red, GLshort green, GLshort blue)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3s(red, green, blue);
+}
+
+void gl3_2compat_glColor3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3iv(v);
+}
+
+void gl3_2compat_glColor3i(void *_glfuncs, GLint red, GLint green, GLint blue)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3i(red, green, blue);
+}
+
+void gl3_2compat_glColor3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3fv(v);
+}
+
+void gl3_2compat_glColor3f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3f(red, green, blue);
+}
+
+void gl3_2compat_glColor3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3dv(v);
+}
+
+void gl3_2compat_glColor3d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3d(red, green, blue);
+}
+
+void gl3_2compat_glColor3bv(void *_glfuncs, const GLbyte* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3bv(v);
+}
+
+void gl3_2compat_glColor3b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3b(red, green, blue);
+}
+
+void gl3_2compat_glBitmap(void *_glfuncs, GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte* bitmap)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glBitmap(width, height, xorig, yorig, xmove, ymove, bitmap);
+}
+
+void gl3_2compat_glBegin(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glBegin(mode);
+}
+
+void gl3_2compat_glListBase(void *_glfuncs, GLuint base)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glListBase(base);
+}
+
+GLuint gl3_2compat_glGenLists(void *_glfuncs, GLsizei range_)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ return _qglfuncs->glGenLists(range_);
+}
+
+void gl3_2compat_glDeleteLists(void *_glfuncs, GLuint list, GLsizei range_)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteLists(list, range_);
+}
+
+void gl3_2compat_glCallLists(void *_glfuncs, GLsizei n, GLenum gltype, const GLvoid* lists)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glCallLists(n, gltype, lists);
+}
+
+void gl3_2compat_glCallList(void *_glfuncs, GLuint list)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glCallList(list);
+}
+
+void gl3_2compat_glEndList(void *_glfuncs)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glEndList();
+}
+
+void gl3_2compat_glNewList(void *_glfuncs, GLuint list, GLenum mode)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glNewList(list, mode);
+}
+
+void gl3_2compat_glPushClientAttrib(void *_glfuncs, GLbitfield mask)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glPushClientAttrib(mask);
+}
+
+void gl3_2compat_glPopClientAttrib(void *_glfuncs)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glPopClientAttrib();
+}
+
+void gl3_2compat_glPrioritizeTextures(void *_glfuncs, GLsizei n, const GLuint* textures, const GLfloat* priorities)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glPrioritizeTextures(n, textures, priorities);
+}
+
+GLboolean gl3_2compat_glAreTexturesResident(void *_glfuncs, GLsizei n, const GLuint* textures, GLboolean* residences)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ return _qglfuncs->glAreTexturesResident(n, textures, residences);
+}
+
+void gl3_2compat_glVertexPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexPointer(size, gltype, stride, pointer);
+}
+
+void gl3_2compat_glTexCoordPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoordPointer(size, gltype, stride, pointer);
+}
+
+void gl3_2compat_glNormalPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormalPointer(gltype, stride, pointer);
+}
+
+void gl3_2compat_glInterleavedArrays(void *_glfuncs, GLenum format, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glInterleavedArrays(format, stride, pointer);
+}
+
+void gl3_2compat_glIndexPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexPointer(gltype, stride, pointer);
+}
+
+void gl3_2compat_glEnableClientState(void *_glfuncs, GLenum array)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glEnableClientState(array);
+}
+
+void gl3_2compat_glEdgeFlagPointer(void *_glfuncs, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glEdgeFlagPointer(stride, pointer);
+}
+
+void gl3_2compat_glDisableClientState(void *_glfuncs, GLenum array)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDisableClientState(array);
+}
+
+void gl3_2compat_glColorPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorPointer(size, gltype, stride, pointer);
+}
+
+void gl3_2compat_glArrayElement(void *_glfuncs, GLint i)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glArrayElement(i);
+}
+
+void gl3_2compat_glResetMinmax(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glResetMinmax(target);
+}
+
+void gl3_2compat_glResetHistogram(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glResetHistogram(target);
+}
+
+void gl3_2compat_glMinmax(void *_glfuncs, GLenum target, GLenum internalFormat, GLboolean sink)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMinmax(target, internalFormat, sink);
+}
+
+void gl3_2compat_glHistogram(void *_glfuncs, GLenum target, GLsizei width, GLenum internalFormat, GLboolean sink)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glHistogram(target, width, internalFormat, sink);
+}
+
+void gl3_2compat_glGetMinmaxParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetMinmaxParameteriv(target, pname, params);
+}
+
+void gl3_2compat_glGetMinmaxParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetMinmaxParameterfv(target, pname, params);
+}
+
+void gl3_2compat_glGetMinmax(void *_glfuncs, GLenum target, GLboolean reset, GLenum format, GLenum gltype, GLvoid* values)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetMinmax(target, reset, format, gltype, values);
+}
+
+void gl3_2compat_glGetHistogramParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetHistogramParameteriv(target, pname, params);
+}
+
+void gl3_2compat_glGetHistogramParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetHistogramParameterfv(target, pname, params);
+}
+
+void gl3_2compat_glGetHistogram(void *_glfuncs, GLenum target, GLboolean reset, GLenum format, GLenum gltype, GLvoid* values)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetHistogram(target, reset, format, gltype, values);
+}
+
+void gl3_2compat_glSeparableFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* row, const GLvoid* column)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glSeparableFilter2D(target, internalFormat, width, height, format, gltype, row, column);
+}
+
+void gl3_2compat_glGetSeparableFilter(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* row, GLvoid* column, GLvoid* span)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetSeparableFilter(target, format, gltype, row, column, span);
+}
+
+void gl3_2compat_glGetConvolutionParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetConvolutionParameteriv(target, pname, params);
+}
+
+void gl3_2compat_glGetConvolutionParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetConvolutionParameterfv(target, pname, params);
+}
+
+void gl3_2compat_glGetConvolutionFilter(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* image)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetConvolutionFilter(target, format, gltype, image);
+}
+
+void gl3_2compat_glCopyConvolutionFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyConvolutionFilter2D(target, internalFormat, x, y, width, height);
+}
+
+void gl3_2compat_glCopyConvolutionFilter1D(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyConvolutionFilter1D(target, internalFormat, x, y, width);
+}
+
+void gl3_2compat_glConvolutionParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glConvolutionParameteriv(target, pname, params);
+}
+
+void gl3_2compat_glConvolutionParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glConvolutionParameteri(target, pname, params);
+}
+
+void gl3_2compat_glConvolutionParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glConvolutionParameterfv(target, pname, params);
+}
+
+void gl3_2compat_glConvolutionParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glConvolutionParameterf(target, pname, params);
+}
+
+void gl3_2compat_glConvolutionFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* image)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glConvolutionFilter2D(target, internalFormat, width, height, format, gltype, image);
+}
+
+void gl3_2compat_glConvolutionFilter1D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLenum format, GLenum gltype, const GLvoid* image)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glConvolutionFilter1D(target, internalFormat, width, format, gltype, image);
+}
+
+void gl3_2compat_glCopyColorSubTable(void *_glfuncs, GLenum target, GLsizei start, GLint x, GLint y, GLsizei width)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyColorSubTable(target, start, x, y, width);
+}
+
+void gl3_2compat_glColorSubTable(void *_glfuncs, GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum gltype, const GLvoid* data)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorSubTable(target, start, count, format, gltype, data);
+}
+
+void gl3_2compat_glGetColorTableParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetColorTableParameteriv(target, pname, params);
+}
+
+void gl3_2compat_glGetColorTableParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetColorTableParameterfv(target, pname, params);
+}
+
+void gl3_2compat_glGetColorTable(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* table)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetColorTable(target, format, gltype, table);
+}
+
+void gl3_2compat_glCopyColorTable(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyColorTable(target, internalFormat, x, y, width);
+}
+
+void gl3_2compat_glColorTableParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorTableParameteriv(target, pname, params);
+}
+
+void gl3_2compat_glColorTableParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorTableParameterfv(target, pname, params);
+}
+
+void gl3_2compat_glColorTable(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLenum format, GLenum gltype, const GLvoid* table)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorTable(target, internalFormat, width, format, gltype, table);
+}
+
+void gl3_2compat_glMultTransposeMatrixd(void *_glfuncs, const GLdouble* m)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultTransposeMatrixd(m);
+}
+
+void gl3_2compat_glMultTransposeMatrixf(void *_glfuncs, const GLfloat* m)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultTransposeMatrixf(m);
+}
+
+void gl3_2compat_glLoadTransposeMatrixd(void *_glfuncs, const GLdouble* m)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glLoadTransposeMatrixd(m);
+}
+
+void gl3_2compat_glLoadTransposeMatrixf(void *_glfuncs, const GLfloat* m)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glLoadTransposeMatrixf(m);
+}
+
+void gl3_2compat_glMultiTexCoord4sv(void *_glfuncs, GLenum target, const GLshort* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4sv(target, v);
+}
+
+void gl3_2compat_glMultiTexCoord4s(void *_glfuncs, GLenum target, GLshort s, GLshort t, GLshort r, GLshort q)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4s(target, s, t, r, q);
+}
+
+void gl3_2compat_glMultiTexCoord4iv(void *_glfuncs, GLenum target, const GLint* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4iv(target, v);
+}
+
+void gl3_2compat_glMultiTexCoord4i(void *_glfuncs, GLenum target, GLint s, GLint t, GLint r, GLint q)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4i(target, s, t, r, q);
+}
+
+void gl3_2compat_glMultiTexCoord4fv(void *_glfuncs, GLenum target, const GLfloat* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4fv(target, v);
+}
+
+void gl3_2compat_glMultiTexCoord4f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4f(target, s, t, r, q);
+}
+
+void gl3_2compat_glMultiTexCoord4dv(void *_glfuncs, GLenum target, const GLdouble* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4dv(target, v);
+}
+
+void gl3_2compat_glMultiTexCoord4d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4d(target, s, t, r, q);
+}
+
+void gl3_2compat_glMultiTexCoord3sv(void *_glfuncs, GLenum target, const GLshort* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3sv(target, v);
+}
+
+void gl3_2compat_glMultiTexCoord3s(void *_glfuncs, GLenum target, GLshort s, GLshort t, GLshort r)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3s(target, s, t, r);
+}
+
+void gl3_2compat_glMultiTexCoord3iv(void *_glfuncs, GLenum target, const GLint* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3iv(target, v);
+}
+
+void gl3_2compat_glMultiTexCoord3i(void *_glfuncs, GLenum target, GLint s, GLint t, GLint r)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3i(target, s, t, r);
+}
+
+void gl3_2compat_glMultiTexCoord3fv(void *_glfuncs, GLenum target, const GLfloat* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3fv(target, v);
+}
+
+void gl3_2compat_glMultiTexCoord3f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t, GLfloat r)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3f(target, s, t, r);
+}
+
+void gl3_2compat_glMultiTexCoord3dv(void *_glfuncs, GLenum target, const GLdouble* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3dv(target, v);
+}
+
+void gl3_2compat_glMultiTexCoord3d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t, GLdouble r)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3d(target, s, t, r);
+}
+
+void gl3_2compat_glMultiTexCoord2sv(void *_glfuncs, GLenum target, const GLshort* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2sv(target, v);
+}
+
+void gl3_2compat_glMultiTexCoord2s(void *_glfuncs, GLenum target, GLshort s, GLshort t)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2s(target, s, t);
+}
+
+void gl3_2compat_glMultiTexCoord2iv(void *_glfuncs, GLenum target, const GLint* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2iv(target, v);
+}
+
+void gl3_2compat_glMultiTexCoord2i(void *_glfuncs, GLenum target, GLint s, GLint t)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2i(target, s, t);
+}
+
+void gl3_2compat_glMultiTexCoord2fv(void *_glfuncs, GLenum target, const GLfloat* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2fv(target, v);
+}
+
+void gl3_2compat_glMultiTexCoord2f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2f(target, s, t);
+}
+
+void gl3_2compat_glMultiTexCoord2dv(void *_glfuncs, GLenum target, const GLdouble* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2dv(target, v);
+}
+
+void gl3_2compat_glMultiTexCoord2d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2d(target, s, t);
+}
+
+void gl3_2compat_glMultiTexCoord1sv(void *_glfuncs, GLenum target, const GLshort* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1sv(target, v);
+}
+
+void gl3_2compat_glMultiTexCoord1s(void *_glfuncs, GLenum target, GLshort s)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1s(target, s);
+}
+
+void gl3_2compat_glMultiTexCoord1iv(void *_glfuncs, GLenum target, const GLint* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1iv(target, v);
+}
+
+void gl3_2compat_glMultiTexCoord1i(void *_glfuncs, GLenum target, GLint s)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1i(target, s);
+}
+
+void gl3_2compat_glMultiTexCoord1fv(void *_glfuncs, GLenum target, const GLfloat* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1fv(target, v);
+}
+
+void gl3_2compat_glMultiTexCoord1f(void *_glfuncs, GLenum target, GLfloat s)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1f(target, s);
+}
+
+void gl3_2compat_glMultiTexCoord1dv(void *_glfuncs, GLenum target, const GLdouble* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1dv(target, v);
+}
+
+void gl3_2compat_glMultiTexCoord1d(void *_glfuncs, GLenum target, GLdouble s)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1d(target, s);
+}
+
+void gl3_2compat_glClientActiveTexture(void *_glfuncs, GLenum texture)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glClientActiveTexture(texture);
+}
+
+void gl3_2compat_glWindowPos3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos3sv(v);
+}
+
+void gl3_2compat_glWindowPos3s(void *_glfuncs, GLshort x, GLshort y, GLshort z)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos3s(x, y, z);
+}
+
+void gl3_2compat_glWindowPos3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos3iv(v);
+}
+
+void gl3_2compat_glWindowPos3i(void *_glfuncs, GLint x, GLint y, GLint z)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos3i(x, y, z);
+}
+
+void gl3_2compat_glWindowPos3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos3fv(v);
+}
+
+void gl3_2compat_glWindowPos3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos3f(x, y, z);
+}
+
+void gl3_2compat_glWindowPos3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos3dv(v);
+}
+
+void gl3_2compat_glWindowPos3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos3d(x, y, z);
+}
+
+void gl3_2compat_glWindowPos2sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos2sv(v);
+}
+
+void gl3_2compat_glWindowPos2s(void *_glfuncs, GLshort x, GLshort y)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos2s(x, y);
+}
+
+void gl3_2compat_glWindowPos2iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos2iv(v);
+}
+
+void gl3_2compat_glWindowPos2i(void *_glfuncs, GLint x, GLint y)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos2i(x, y);
+}
+
+void gl3_2compat_glWindowPos2fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos2fv(v);
+}
+
+void gl3_2compat_glWindowPos2f(void *_glfuncs, GLfloat x, GLfloat y)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos2f(x, y);
+}
+
+void gl3_2compat_glWindowPos2dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos2dv(v);
+}
+
+void gl3_2compat_glWindowPos2d(void *_glfuncs, GLdouble x, GLdouble y)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos2d(x, y);
+}
+
+void gl3_2compat_glSecondaryColorPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColorPointer(size, gltype, stride, pointer);
+}
+
+void gl3_2compat_glSecondaryColor3usv(void *_glfuncs, const GLushort* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3usv(v);
+}
+
+void gl3_2compat_glSecondaryColor3us(void *_glfuncs, GLushort red, GLushort green, GLushort blue)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3us(red, green, blue);
+}
+
+void gl3_2compat_glSecondaryColor3uiv(void *_glfuncs, const GLuint* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3uiv(v);
+}
+
+void gl3_2compat_glSecondaryColor3ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3ui(red, green, blue);
+}
+
+void gl3_2compat_glSecondaryColor3ubv(void *_glfuncs, const GLubyte* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3ubv(v);
+}
+
+void gl3_2compat_glSecondaryColor3ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3ub(red, green, blue);
+}
+
+void gl3_2compat_glSecondaryColor3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3sv(v);
+}
+
+void gl3_2compat_glSecondaryColor3s(void *_glfuncs, GLshort red, GLshort green, GLshort blue)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3s(red, green, blue);
+}
+
+void gl3_2compat_glSecondaryColor3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3iv(v);
+}
+
+void gl3_2compat_glSecondaryColor3i(void *_glfuncs, GLint red, GLint green, GLint blue)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3i(red, green, blue);
+}
+
+void gl3_2compat_glSecondaryColor3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3fv(v);
+}
+
+void gl3_2compat_glSecondaryColor3f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3f(red, green, blue);
+}
+
+void gl3_2compat_glSecondaryColor3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3dv(v);
+}
+
+void gl3_2compat_glSecondaryColor3d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3d(red, green, blue);
+}
+
+void gl3_2compat_glSecondaryColor3bv(void *_glfuncs, const GLbyte* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3bv(v);
+}
+
+void gl3_2compat_glSecondaryColor3b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3b(red, green, blue);
+}
+
+void gl3_2compat_glFogCoordPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glFogCoordPointer(gltype, stride, pointer);
+}
+
+void gl3_2compat_glFogCoorddv(void *_glfuncs, const GLdouble* coord)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glFogCoorddv(coord);
+}
+
+void gl3_2compat_glFogCoordd(void *_glfuncs, GLdouble coord)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glFogCoordd(coord);
+}
+
+void gl3_2compat_glFogCoordfv(void *_glfuncs, const GLfloat* coord)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glFogCoordfv(coord);
+}
+
+void gl3_2compat_glFogCoordf(void *_glfuncs, GLfloat coord)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glFogCoordf(coord);
+}
+
+void gl3_2compat_glVertexAttrib4usv(void *_glfuncs, GLuint index, const GLushort* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4usv(index, v);
+}
+
+void gl3_2compat_glVertexAttrib4uiv(void *_glfuncs, GLuint index, const GLuint* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4uiv(index, v);
+}
+
+void gl3_2compat_glVertexAttrib4ubv(void *_glfuncs, GLuint index, const GLubyte* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4ubv(index, v);
+}
+
+void gl3_2compat_glVertexAttrib4sv(void *_glfuncs, GLuint index, const GLshort* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4sv(index, v);
+}
+
+void gl3_2compat_glVertexAttrib4s(void *_glfuncs, GLuint index, GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4s(index, x, y, z, w);
+}
+
+void gl3_2compat_glVertexAttrib4iv(void *_glfuncs, GLuint index, const GLint* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4iv(index, v);
+}
+
+void gl3_2compat_glVertexAttrib4fv(void *_glfuncs, GLuint index, const GLfloat* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4fv(index, v);
+}
+
+void gl3_2compat_glVertexAttrib4f(void *_glfuncs, GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4f(index, x, y, z, w);
+}
+
+void gl3_2compat_glVertexAttrib4dv(void *_glfuncs, GLuint index, const GLdouble* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4dv(index, v);
+}
+
+void gl3_2compat_glVertexAttrib4d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4d(index, x, y, z, w);
+}
+
+void gl3_2compat_glVertexAttrib4bv(void *_glfuncs, GLuint index, const GLbyte* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4bv(index, v);
+}
+
+void gl3_2compat_glVertexAttrib4Nusv(void *_glfuncs, GLuint index, const GLushort* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Nusv(index, v);
+}
+
+void gl3_2compat_glVertexAttrib4Nuiv(void *_glfuncs, GLuint index, const GLuint* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Nuiv(index, v);
+}
+
+void gl3_2compat_glVertexAttrib4Nubv(void *_glfuncs, GLuint index, const GLubyte* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Nubv(index, v);
+}
+
+void gl3_2compat_glVertexAttrib4Nub(void *_glfuncs, GLuint index, GLubyte x, GLubyte y, GLubyte z, GLubyte w)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Nub(index, x, y, z, w);
+}
+
+void gl3_2compat_glVertexAttrib4Nsv(void *_glfuncs, GLuint index, const GLshort* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Nsv(index, v);
+}
+
+void gl3_2compat_glVertexAttrib4Niv(void *_glfuncs, GLuint index, const GLint* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Niv(index, v);
+}
+
+void gl3_2compat_glVertexAttrib4Nbv(void *_glfuncs, GLuint index, const GLbyte* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Nbv(index, v);
+}
+
+void gl3_2compat_glVertexAttrib3sv(void *_glfuncs, GLuint index, const GLshort* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib3sv(index, v);
+}
+
+void gl3_2compat_glVertexAttrib3s(void *_glfuncs, GLuint index, GLshort x, GLshort y, GLshort z)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib3s(index, x, y, z);
+}
+
+void gl3_2compat_glVertexAttrib3fv(void *_glfuncs, GLuint index, const GLfloat* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib3fv(index, v);
+}
+
+void gl3_2compat_glVertexAttrib3f(void *_glfuncs, GLuint index, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib3f(index, x, y, z);
+}
+
+void gl3_2compat_glVertexAttrib3dv(void *_glfuncs, GLuint index, const GLdouble* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib3dv(index, v);
+}
+
+void gl3_2compat_glVertexAttrib3d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib3d(index, x, y, z);
+}
+
+void gl3_2compat_glVertexAttrib2sv(void *_glfuncs, GLuint index, const GLshort* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib2sv(index, v);
+}
+
+void gl3_2compat_glVertexAttrib2s(void *_glfuncs, GLuint index, GLshort x, GLshort y)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib2s(index, x, y);
+}
+
+void gl3_2compat_glVertexAttrib2fv(void *_glfuncs, GLuint index, const GLfloat* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib2fv(index, v);
+}
+
+void gl3_2compat_glVertexAttrib2f(void *_glfuncs, GLuint index, GLfloat x, GLfloat y)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib2f(index, x, y);
+}
+
+void gl3_2compat_glVertexAttrib2dv(void *_glfuncs, GLuint index, const GLdouble* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib2dv(index, v);
+}
+
+void gl3_2compat_glVertexAttrib2d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib2d(index, x, y);
+}
+
+void gl3_2compat_glVertexAttrib1sv(void *_glfuncs, GLuint index, const GLshort* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib1sv(index, v);
+}
+
+void gl3_2compat_glVertexAttrib1s(void *_glfuncs, GLuint index, GLshort x)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib1s(index, x);
+}
+
+void gl3_2compat_glVertexAttrib1fv(void *_glfuncs, GLuint index, const GLfloat* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib1fv(index, v);
+}
+
+void gl3_2compat_glVertexAttrib1f(void *_glfuncs, GLuint index, GLfloat x)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib1f(index, x);
+}
+
+void gl3_2compat_glVertexAttrib1dv(void *_glfuncs, GLuint index, const GLdouble* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib1dv(index, v);
+}
+
+void gl3_2compat_glVertexAttrib1d(void *_glfuncs, GLuint index, GLdouble x)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib1d(index, x);
+}
+
+void gl3_2compat_glVertexAttribI4usv(void *_glfuncs, GLuint index, const GLushort* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI4usv(index, v);
+}
+
+void gl3_2compat_glVertexAttribI4ubv(void *_glfuncs, GLuint index, const GLubyte* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI4ubv(index, v);
+}
+
+void gl3_2compat_glVertexAttribI4sv(void *_glfuncs, GLuint index, const GLshort* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI4sv(index, v);
+}
+
+void gl3_2compat_glVertexAttribI4bv(void *_glfuncs, GLuint index, const GLbyte* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI4bv(index, v);
+}
+
+void gl3_2compat_glVertexAttribI4uiv(void *_glfuncs, GLuint index, const GLuint* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI4uiv(index, v);
+}
+
+void gl3_2compat_glVertexAttribI3uiv(void *_glfuncs, GLuint index, const GLuint* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI3uiv(index, v);
+}
+
+void gl3_2compat_glVertexAttribI2uiv(void *_glfuncs, GLuint index, const GLuint* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI2uiv(index, v);
+}
+
+void gl3_2compat_glVertexAttribI1uiv(void *_glfuncs, GLuint index, const GLuint* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI1uiv(index, v);
+}
+
+void gl3_2compat_glVertexAttribI4iv(void *_glfuncs, GLuint index, const GLint* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI4iv(index, v);
+}
+
+void gl3_2compat_glVertexAttribI3iv(void *_glfuncs, GLuint index, const GLint* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI3iv(index, v);
+}
+
+void gl3_2compat_glVertexAttribI2iv(void *_glfuncs, GLuint index, const GLint* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI2iv(index, v);
+}
+
+void gl3_2compat_glVertexAttribI1iv(void *_glfuncs, GLuint index, const GLint* v)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI1iv(index, v);
+}
+
+void gl3_2compat_glVertexAttribI4ui(void *_glfuncs, GLuint index, GLuint x, GLuint y, GLuint z, GLuint w)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI4ui(index, x, y, z, w);
+}
+
+void gl3_2compat_glVertexAttribI3ui(void *_glfuncs, GLuint index, GLuint x, GLuint y, GLuint z)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI3ui(index, x, y, z);
+}
+
+void gl3_2compat_glVertexAttribI2ui(void *_glfuncs, GLuint index, GLuint x, GLuint y)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI2ui(index, x, y);
+}
+
+void gl3_2compat_glVertexAttribI1ui(void *_glfuncs, GLuint index, GLuint x)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI1ui(index, x);
+}
+
+void gl3_2compat_glVertexAttribI4i(void *_glfuncs, GLuint index, GLint x, GLint y, GLint z, GLint w)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI4i(index, x, y, z, w);
+}
+
+void gl3_2compat_glVertexAttribI3i(void *_glfuncs, GLuint index, GLint x, GLint y, GLint z)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI3i(index, x, y, z);
+}
+
+void gl3_2compat_glVertexAttribI2i(void *_glfuncs, GLuint index, GLint x, GLint y)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI2i(index, x, y);
+}
+
+void gl3_2compat_glVertexAttribI1i(void *_glfuncs, GLuint index, GLint x)
+{
+ QOpenGLFunctions_3_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI1i(index, x);
+}
+
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/3.2compat/funcs.h b/Godeps/_workspace/src/github.com/obscuren/qml/gl/3.2compat/funcs.h
new file mode 100644
index 000000000..17fa70e2e
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/3.2compat/funcs.h
@@ -0,0 +1,729 @@
+
+// ** file automatically generated by glgen -- do not edit manually **
+
+#ifndef __cplusplus
+#include <inttypes.h>
+#include <stddef.h>
+typedef unsigned int GLenum;
+typedef unsigned char GLboolean;
+typedef unsigned int GLbitfield;
+typedef void GLvoid;
+typedef char GLchar;
+typedef signed char GLbyte; /* 1-byte signed */
+typedef short GLshort; /* 2-byte signed */
+typedef int GLint; /* 4-byte signed */
+typedef unsigned char GLubyte; /* 1-byte unsigned */
+typedef unsigned short GLushort; /* 2-byte unsigned */
+typedef unsigned int GLuint; /* 4-byte unsigned */
+typedef int GLsizei; /* 4-byte signed */
+typedef float GLfloat; /* single precision float */
+typedef float GLclampf; /* single precision float in [0,1] */
+typedef double GLdouble; /* double precision float */
+typedef double GLclampd; /* double precision float in [0,1] */
+typedef int64_t GLint64;
+typedef uint64_t GLuint64;
+typedef ptrdiff_t GLintptr;
+typedef ptrdiff_t GLsizeiptr;
+typedef ptrdiff_t GLintptrARB;
+typedef ptrdiff_t GLsizeiptrARB;
+typedef struct __GLsync *GLsync;
+#endif
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+void *gl3_2compat_funcs();
+
+void gl3_2compat_glViewport(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl3_2compat_glDepthRange(void *_glfuncs, GLdouble nearVal, GLdouble farVal);
+GLboolean gl3_2compat_glIsEnabled(void *_glfuncs, GLenum cap);
+void gl3_2compat_glGetTexLevelParameteriv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLint* params);
+void gl3_2compat_glGetTexLevelParameterfv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLfloat* params);
+void gl3_2compat_glGetTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl3_2compat_glGetTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl3_2compat_glGetTexImage(void *_glfuncs, GLenum target, GLint level, GLenum format, GLenum gltype, GLvoid* pixels);
+void gl3_2compat_glGetIntegerv(void *_glfuncs, GLenum pname, GLint* params);
+void gl3_2compat_glGetFloatv(void *_glfuncs, GLenum pname, GLfloat* params);
+GLenum gl3_2compat_glGetError(void *_glfuncs);
+void gl3_2compat_glGetDoublev(void *_glfuncs, GLenum pname, GLdouble* params);
+void gl3_2compat_glGetBooleanv(void *_glfuncs, GLenum pname, GLboolean* params);
+void gl3_2compat_glReadPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum gltype, GLvoid* pixels);
+void gl3_2compat_glReadBuffer(void *_glfuncs, GLenum mode);
+void gl3_2compat_glPixelStorei(void *_glfuncs, GLenum pname, GLint param);
+void gl3_2compat_glPixelStoref(void *_glfuncs, GLenum pname, GLfloat param);
+void gl3_2compat_glDepthFunc(void *_glfuncs, GLenum glfunc);
+void gl3_2compat_glStencilOp(void *_glfuncs, GLenum fail, GLenum zfail, GLenum zpass);
+void gl3_2compat_glStencilFunc(void *_glfuncs, GLenum glfunc, GLint ref, GLuint mask);
+void gl3_2compat_glLogicOp(void *_glfuncs, GLenum opcode);
+void gl3_2compat_glBlendFunc(void *_glfuncs, GLenum sfactor, GLenum dfactor);
+void gl3_2compat_glFlush(void *_glfuncs);
+void gl3_2compat_glFinish(void *_glfuncs);
+void gl3_2compat_glEnable(void *_glfuncs, GLenum cap);
+void gl3_2compat_glDisable(void *_glfuncs, GLenum cap);
+void gl3_2compat_glDepthMask(void *_glfuncs, GLboolean flag);
+void gl3_2compat_glColorMask(void *_glfuncs, GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha);
+void gl3_2compat_glStencilMask(void *_glfuncs, GLuint mask);
+void gl3_2compat_glClearDepth(void *_glfuncs, GLdouble depth);
+void gl3_2compat_glClearStencil(void *_glfuncs, GLint s);
+void gl3_2compat_glClearColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl3_2compat_glClear(void *_glfuncs, GLbitfield mask);
+void gl3_2compat_glDrawBuffer(void *_glfuncs, GLenum mode);
+void gl3_2compat_glTexImage2D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl3_2compat_glTexImage1D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl3_2compat_glTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl3_2compat_glTexParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint param);
+void gl3_2compat_glTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl3_2compat_glTexParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param);
+void gl3_2compat_glScissor(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl3_2compat_glPolygonMode(void *_glfuncs, GLenum face, GLenum mode);
+void gl3_2compat_glPointSize(void *_glfuncs, GLfloat size);
+void gl3_2compat_glLineWidth(void *_glfuncs, GLfloat width);
+void gl3_2compat_glHint(void *_glfuncs, GLenum target, GLenum mode);
+void gl3_2compat_glFrontFace(void *_glfuncs, GLenum mode);
+void gl3_2compat_glCullFace(void *_glfuncs, GLenum mode);
+void gl3_2compat_glIndexubv(void *_glfuncs, const GLubyte* c);
+void gl3_2compat_glIndexub(void *_glfuncs, GLubyte c);
+GLboolean gl3_2compat_glIsTexture(void *_glfuncs, GLuint texture);
+void gl3_2compat_glGenTextures(void *_glfuncs, GLsizei n, GLuint* textures);
+void gl3_2compat_glDeleteTextures(void *_glfuncs, GLsizei n, const GLuint* textures);
+void gl3_2compat_glBindTexture(void *_glfuncs, GLenum target, GLuint texture);
+void gl3_2compat_glTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl3_2compat_glTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl3_2compat_glCopyTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl3_2compat_glCopyTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width);
+void gl3_2compat_glCopyTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border);
+void gl3_2compat_glCopyTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLint border);
+void gl3_2compat_glPolygonOffset(void *_glfuncs, GLfloat factor, GLfloat units);
+void gl3_2compat_glDrawElements(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices);
+void gl3_2compat_glDrawArrays(void *_glfuncs, GLenum mode, GLint first, GLsizei count);
+void gl3_2compat_glCopyTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl3_2compat_glTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl3_2compat_glTexImage3D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl3_2compat_glDrawRangeElements(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices);
+void gl3_2compat_glBlendEquation(void *_glfuncs, GLenum mode);
+void gl3_2compat_glBlendColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl3_2compat_glGetCompressedTexImage(void *_glfuncs, GLenum target, GLint level, GLvoid* img);
+void gl3_2compat_glCompressedTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid* data);
+void gl3_2compat_glCompressedTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid* data);
+void gl3_2compat_glCompressedTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid* data);
+void gl3_2compat_glCompressedTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid* data);
+void gl3_2compat_glCompressedTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid* data);
+void gl3_2compat_glCompressedTexImage3D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid* data);
+void gl3_2compat_glSampleCoverage(void *_glfuncs, GLfloat value, GLboolean invert);
+void gl3_2compat_glActiveTexture(void *_glfuncs, GLenum texture);
+void gl3_2compat_glPointParameteriv(void *_glfuncs, GLenum pname, const GLint* params);
+void gl3_2compat_glPointParameteri(void *_glfuncs, GLenum pname, GLint param);
+void gl3_2compat_glPointParameterfv(void *_glfuncs, GLenum pname, const GLfloat* params);
+void gl3_2compat_glPointParameterf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl3_2compat_glMultiDrawArrays(void *_glfuncs, GLenum mode, const GLint* first, const GLsizei* count, GLsizei drawcount);
+void gl3_2compat_glBlendFuncSeparate(void *_glfuncs, GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha);
+void gl3_2compat_glGetBufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+GLboolean gl3_2compat_glUnmapBuffer(void *_glfuncs, GLenum target);
+void gl3_2compat_glGetBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, GLvoid* data);
+void gl3_2compat_glBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid* data);
+void gl3_2compat_glBufferData(void *_glfuncs, GLenum target, GLsizeiptr size, const GLvoid* data, GLenum usage);
+GLboolean gl3_2compat_glIsBuffer(void *_glfuncs, GLuint buffer);
+void gl3_2compat_glGenBuffers(void *_glfuncs, GLsizei n, GLuint* buffers);
+void gl3_2compat_glDeleteBuffers(void *_glfuncs, GLsizei n, const GLuint* buffers);
+void gl3_2compat_glBindBuffer(void *_glfuncs, GLenum target, GLuint buffer);
+void gl3_2compat_glGetQueryObjectuiv(void *_glfuncs, GLuint id, GLenum pname, GLuint* params);
+void gl3_2compat_glGetQueryObjectiv(void *_glfuncs, GLuint id, GLenum pname, GLint* params);
+void gl3_2compat_glGetQueryiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl3_2compat_glEndQuery(void *_glfuncs, GLenum target);
+void gl3_2compat_glBeginQuery(void *_glfuncs, GLenum target, GLuint id);
+GLboolean gl3_2compat_glIsQuery(void *_glfuncs, GLuint id);
+void gl3_2compat_glDeleteQueries(void *_glfuncs, GLsizei n, const GLuint* ids);
+void gl3_2compat_glGenQueries(void *_glfuncs, GLsizei n, GLuint* ids);
+void gl3_2compat_glVertexAttribPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLboolean normalized, GLsizei stride, const GLvoid* offset);
+void gl3_2compat_glValidateProgram(void *_glfuncs, GLuint program);
+void gl3_2compat_glUniformMatrix4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl3_2compat_glUniformMatrix3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl3_2compat_glUniformMatrix2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl3_2compat_glUniform4iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl3_2compat_glUniform3iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl3_2compat_glUniform2iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl3_2compat_glUniform1iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl3_2compat_glUniform4fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl3_2compat_glUniform3fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl3_2compat_glUniform2fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl3_2compat_glUniform1fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl3_2compat_glUniform4i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2, GLint v3);
+void gl3_2compat_glUniform3i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2);
+void gl3_2compat_glUniform2i(void *_glfuncs, GLint location, GLint v0, GLint v1);
+void gl3_2compat_glUniform1i(void *_glfuncs, GLint location, GLint v0);
+void gl3_2compat_glUniform4f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3);
+void gl3_2compat_glUniform3f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2);
+void gl3_2compat_glUniform2f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1);
+void gl3_2compat_glUniform1f(void *_glfuncs, GLint location, GLfloat v0);
+void gl3_2compat_glUseProgram(void *_glfuncs, GLuint program);
+void gl3_2compat_glShaderSource(void *_glfuncs, GLuint shader, GLsizei count, const GLchar** source, const GLint* length);
+void gl3_2compat_glLinkProgram(void *_glfuncs, GLuint program);
+GLboolean gl3_2compat_glIsShader(void *_glfuncs, GLuint shader);
+GLboolean gl3_2compat_glIsProgram(void *_glfuncs, GLuint program);
+void gl3_2compat_glGetVertexAttribiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params);
+void gl3_2compat_glGetVertexAttribfv(void *_glfuncs, GLuint index, GLenum pname, GLfloat* params);
+void gl3_2compat_glGetVertexAttribdv(void *_glfuncs, GLuint index, GLenum pname, GLdouble* params);
+void gl3_2compat_glGetUniformiv(void *_glfuncs, GLuint program, GLint location, GLint* params);
+void gl3_2compat_glGetUniformfv(void *_glfuncs, GLuint program, GLint location, GLfloat* params);
+GLint gl3_2compat_glGetUniformLocation(void *_glfuncs, GLuint program, const GLchar* name);
+void gl3_2compat_glGetShaderSource(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* source);
+void gl3_2compat_glGetShaderInfoLog(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* infoLog);
+void gl3_2compat_glGetShaderiv(void *_glfuncs, GLuint shader, GLenum pname, GLint* params);
+void gl3_2compat_glGetProgramInfoLog(void *_glfuncs, GLuint program, GLsizei bufSize, GLsizei* length, GLchar* infoLog);
+void gl3_2compat_glGetProgramiv(void *_glfuncs, GLuint program, GLenum pname, GLint* params);
+GLint gl3_2compat_glGetAttribLocation(void *_glfuncs, GLuint program, const GLchar* name);
+void gl3_2compat_glGetAttachedShaders(void *_glfuncs, GLuint program, GLsizei maxCount, GLsizei* count, GLuint* obj);
+void gl3_2compat_glGetActiveUniform(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name);
+void gl3_2compat_glGetActiveAttrib(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name);
+void gl3_2compat_glEnableVertexAttribArray(void *_glfuncs, GLuint index);
+void gl3_2compat_glDisableVertexAttribArray(void *_glfuncs, GLuint index);
+void gl3_2compat_glDetachShader(void *_glfuncs, GLuint program, GLuint shader);
+void gl3_2compat_glDeleteShader(void *_glfuncs, GLuint shader);
+void gl3_2compat_glDeleteProgram(void *_glfuncs, GLuint program);
+GLuint gl3_2compat_glCreateShader(void *_glfuncs, GLenum gltype);
+GLuint gl3_2compat_glCreateProgram(void *_glfuncs);
+void gl3_2compat_glCompileShader(void *_glfuncs, GLuint shader);
+void gl3_2compat_glBindAttribLocation(void *_glfuncs, GLuint program, GLuint index, const GLchar* name);
+void gl3_2compat_glAttachShader(void *_glfuncs, GLuint program, GLuint shader);
+void gl3_2compat_glStencilMaskSeparate(void *_glfuncs, GLenum face, GLuint mask);
+void gl3_2compat_glStencilFuncSeparate(void *_glfuncs, GLenum face, GLenum glfunc, GLint ref, GLuint mask);
+void gl3_2compat_glStencilOpSeparate(void *_glfuncs, GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass);
+void gl3_2compat_glDrawBuffers(void *_glfuncs, GLsizei n, const GLenum* bufs);
+void gl3_2compat_glBlendEquationSeparate(void *_glfuncs, GLenum modeRGB, GLenum modeAlpha);
+void gl3_2compat_glUniformMatrix4x3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl3_2compat_glUniformMatrix3x4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl3_2compat_glUniformMatrix4x2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl3_2compat_glUniformMatrix2x4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl3_2compat_glUniformMatrix3x2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl3_2compat_glUniformMatrix2x3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+GLboolean gl3_2compat_glIsVertexArray(void *_glfuncs, GLuint array);
+void gl3_2compat_glGenVertexArrays(void *_glfuncs, GLsizei n, GLuint* arrays);
+void gl3_2compat_glDeleteVertexArrays(void *_glfuncs, GLsizei n, const GLuint* arrays);
+void gl3_2compat_glBindVertexArray(void *_glfuncs, GLuint array);
+void gl3_2compat_glFlushMappedBufferRange(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr length);
+void gl3_2compat_glFramebufferTextureLayer(void *_glfuncs, GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer);
+void gl3_2compat_glRenderbufferStorageMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLenum internalFormat, GLsizei width, GLsizei height);
+void gl3_2compat_glBlitFramebuffer(void *_glfuncs, GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter);
+void gl3_2compat_glGenerateMipmap(void *_glfuncs, GLenum target);
+void gl3_2compat_glGetFramebufferAttachmentParameteriv(void *_glfuncs, GLenum target, GLenum attachment, GLenum pname, GLint* params);
+void gl3_2compat_glFramebufferRenderbuffer(void *_glfuncs, GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer);
+void gl3_2compat_glFramebufferTexture3D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset);
+void gl3_2compat_glFramebufferTexture2D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+void gl3_2compat_glFramebufferTexture1D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+GLenum gl3_2compat_glCheckFramebufferStatus(void *_glfuncs, GLenum target);
+void gl3_2compat_glGenFramebuffers(void *_glfuncs, GLsizei n, GLuint* framebuffers);
+void gl3_2compat_glDeleteFramebuffers(void *_glfuncs, GLsizei n, const GLuint* framebuffers);
+void gl3_2compat_glBindFramebuffer(void *_glfuncs, GLenum target, GLuint framebuffer);
+GLboolean gl3_2compat_glIsFramebuffer(void *_glfuncs, GLuint framebuffer);
+void gl3_2compat_glGetRenderbufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl3_2compat_glRenderbufferStorage(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height);
+void gl3_2compat_glGenRenderbuffers(void *_glfuncs, GLsizei n, GLuint* renderbuffers);
+void gl3_2compat_glDeleteRenderbuffers(void *_glfuncs, GLsizei n, const GLuint* renderbuffers);
+void gl3_2compat_glBindRenderbuffer(void *_glfuncs, GLenum target, GLuint renderbuffer);
+GLboolean gl3_2compat_glIsRenderbuffer(void *_glfuncs, GLuint renderbuffer);
+void gl3_2compat_glClearBufferfi(void *_glfuncs, GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil);
+void gl3_2compat_glClearBufferfv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLfloat* value);
+void gl3_2compat_glClearBufferuiv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLuint* value);
+void gl3_2compat_glClearBufferiv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLint* value);
+void gl3_2compat_glGetTexParameterIuiv(void *_glfuncs, GLenum target, GLenum pname, GLuint* params);
+void gl3_2compat_glGetTexParameterIiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl3_2compat_glTexParameterIuiv(void *_glfuncs, GLenum target, GLenum pname, const GLuint* params);
+void gl3_2compat_glTexParameterIiv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl3_2compat_glUniform4uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value);
+void gl3_2compat_glUniform3uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value);
+void gl3_2compat_glUniform2uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value);
+void gl3_2compat_glUniform1uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value);
+void gl3_2compat_glUniform4ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3);
+void gl3_2compat_glUniform3ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1, GLuint v2);
+void gl3_2compat_glUniform2ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1);
+void gl3_2compat_glUniform1ui(void *_glfuncs, GLint location, GLuint v0);
+GLint gl3_2compat_glGetFragDataLocation(void *_glfuncs, GLuint program, const GLchar* name);
+void gl3_2compat_glBindFragDataLocation(void *_glfuncs, GLuint program, GLuint color, const GLchar* name);
+void gl3_2compat_glGetUniformuiv(void *_glfuncs, GLuint program, GLint location, GLuint* params);
+void gl3_2compat_glGetVertexAttribIuiv(void *_glfuncs, GLuint index, GLenum pname, GLuint* params);
+void gl3_2compat_glGetVertexAttribIiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params);
+void gl3_2compat_glVertexAttribIPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl3_2compat_glEndConditionalRender(void *_glfuncs);
+void gl3_2compat_glBeginConditionalRender(void *_glfuncs, GLuint id, GLenum mode);
+void gl3_2compat_glClampColor(void *_glfuncs, GLenum target, GLenum clamp);
+void gl3_2compat_glGetTransformFeedbackVarying(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLsizei* size, GLenum* gltype, GLchar* name);
+void gl3_2compat_glBindBufferBase(void *_glfuncs, GLenum target, GLuint index, GLuint buffer);
+void gl3_2compat_glBindBufferRange(void *_glfuncs, GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size);
+void gl3_2compat_glEndTransformFeedback(void *_glfuncs);
+void gl3_2compat_glBeginTransformFeedback(void *_glfuncs, GLenum primitiveMode);
+GLboolean gl3_2compat_glIsEnabledi(void *_glfuncs, GLenum target, GLuint index);
+void gl3_2compat_glDisablei(void *_glfuncs, GLenum target, GLuint index);
+void gl3_2compat_glEnablei(void *_glfuncs, GLenum target, GLuint index);
+void gl3_2compat_glGetIntegeri_v(void *_glfuncs, GLenum target, GLuint index, GLint* data);
+void gl3_2compat_glGetBooleani_v(void *_glfuncs, GLenum target, GLuint index, GLboolean* data);
+void gl3_2compat_glColorMaski(void *_glfuncs, GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a);
+void gl3_2compat_glCopyBufferSubData(void *_glfuncs, GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size);
+void gl3_2compat_glUniformBlockBinding(void *_glfuncs, GLuint program, GLuint v0, GLuint v1);
+void gl3_2compat_glGetActiveUniformBlockName(void *_glfuncs, GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei* length, GLchar* uniformBlockName);
+void gl3_2compat_glGetActiveUniformBlockiv(void *_glfuncs, GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint* params);
+GLuint gl3_2compat_glGetUniformBlockIndex(void *_glfuncs, GLuint program, const GLchar* uniformBlockName);
+void gl3_2compat_glGetActiveUniformName(void *_glfuncs, GLuint program, GLuint uniformIndex, GLsizei bufSize, GLsizei* length, GLchar* uniformName);
+void gl3_2compat_glGetActiveUniformsiv(void *_glfuncs, GLuint program, GLsizei uniformCount, const GLuint* uniformIndices, GLenum pname, GLint* params);
+void gl3_2compat_glPrimitiveRestartIndex(void *_glfuncs, GLuint index);
+void gl3_2compat_glTexBuffer(void *_glfuncs, GLenum target, GLenum internalFormat, GLuint buffer);
+void gl3_2compat_glDrawElementsInstanced(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount);
+void gl3_2compat_glDrawArraysInstanced(void *_glfuncs, GLenum mode, GLint first, GLsizei count, GLsizei instancecount);
+void gl3_2compat_glSampleMaski(void *_glfuncs, GLuint index, GLbitfield mask);
+void gl3_2compat_glGetMultisamplefv(void *_glfuncs, GLenum pname, GLuint index, GLfloat* val);
+void gl3_2compat_glTexImage3DMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations);
+void gl3_2compat_glTexImage2DMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLint internalFormat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations);
+void gl3_2compat_glGetSynciv(void *_glfuncs, GLsync sync, GLenum pname, GLsizei bufSize, GLsizei* length, GLint* values);
+void gl3_2compat_glGetInteger64v(void *_glfuncs, GLenum pname, GLint64* params);
+void gl3_2compat_glWaitSync(void *_glfuncs, GLsync sync, GLbitfield flags, GLuint64 timeout);
+GLenum gl3_2compat_glClientWaitSync(void *_glfuncs, GLsync sync, GLbitfield flags, GLuint64 timeout);
+void gl3_2compat_glDeleteSync(void *_glfuncs, GLsync sync);
+GLboolean gl3_2compat_glIsSync(void *_glfuncs, GLsync sync);
+GLsync gl3_2compat_glFenceSync(void *_glfuncs, GLenum condition, GLbitfield flags);
+void gl3_2compat_glProvokingVertex(void *_glfuncs, GLenum mode);
+void gl3_2compat_glDrawElementsInstancedBaseVertex(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount, GLint basevertex);
+void gl3_2compat_glDrawRangeElementsBaseVertex(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices, GLint basevertex);
+void gl3_2compat_glDrawElementsBaseVertex(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLint basevertex);
+void gl3_2compat_glFramebufferTexture(void *_glfuncs, GLenum target, GLenum attachment, GLuint texture, GLint level);
+void gl3_2compat_glGetBufferParameteri64v(void *_glfuncs, GLenum target, GLenum pname, GLint64* params);
+void gl3_2compat_glGetInteger64i_v(void *_glfuncs, GLenum target, GLuint index, GLint64* data);
+void gl3_2compat_glTranslatef(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl3_2compat_glTranslated(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl3_2compat_glScalef(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl3_2compat_glScaled(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl3_2compat_glRotatef(void *_glfuncs, GLfloat angle, GLfloat x, GLfloat y, GLfloat z);
+void gl3_2compat_glRotated(void *_glfuncs, GLdouble angle, GLdouble x, GLdouble y, GLdouble z);
+void gl3_2compat_glPushMatrix(void *_glfuncs);
+void gl3_2compat_glPopMatrix(void *_glfuncs);
+void gl3_2compat_glOrtho(void *_glfuncs, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+void gl3_2compat_glMultMatrixd(void *_glfuncs, const GLdouble* m);
+void gl3_2compat_glMultMatrixf(void *_glfuncs, const GLfloat* m);
+void gl3_2compat_glMatrixMode(void *_glfuncs, GLenum mode);
+void gl3_2compat_glLoadMatrixd(void *_glfuncs, const GLdouble* m);
+void gl3_2compat_glLoadMatrixf(void *_glfuncs, const GLfloat* m);
+void gl3_2compat_glLoadIdentity(void *_glfuncs);
+void gl3_2compat_glFrustum(void *_glfuncs, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+GLboolean gl3_2compat_glIsList(void *_glfuncs, GLuint list);
+void gl3_2compat_glGetTexGeniv(void *_glfuncs, GLenum coord, GLenum pname, GLint* params);
+void gl3_2compat_glGetTexGenfv(void *_glfuncs, GLenum coord, GLenum pname, GLfloat* params);
+void gl3_2compat_glGetTexGendv(void *_glfuncs, GLenum coord, GLenum pname, GLdouble* params);
+void gl3_2compat_glGetTexEnviv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl3_2compat_glGetTexEnvfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl3_2compat_glGetPolygonStipple(void *_glfuncs, GLubyte* mask);
+void gl3_2compat_glGetPixelMapusv(void *_glfuncs, GLenum glmap, GLushort* values);
+void gl3_2compat_glGetPixelMapuiv(void *_glfuncs, GLenum glmap, GLuint* values);
+void gl3_2compat_glGetPixelMapfv(void *_glfuncs, GLenum glmap, GLfloat* values);
+void gl3_2compat_glGetMaterialiv(void *_glfuncs, GLenum face, GLenum pname, GLint* params);
+void gl3_2compat_glGetMaterialfv(void *_glfuncs, GLenum face, GLenum pname, GLfloat* params);
+void gl3_2compat_glGetMapiv(void *_glfuncs, GLenum target, GLenum query, GLint* v);
+void gl3_2compat_glGetMapfv(void *_glfuncs, GLenum target, GLenum query, GLfloat* v);
+void gl3_2compat_glGetMapdv(void *_glfuncs, GLenum target, GLenum query, GLdouble* v);
+void gl3_2compat_glGetLightiv(void *_glfuncs, GLenum light, GLenum pname, GLint* params);
+void gl3_2compat_glGetLightfv(void *_glfuncs, GLenum light, GLenum pname, GLfloat* params);
+void gl3_2compat_glGetClipPlane(void *_glfuncs, GLenum plane, GLdouble* equation);
+void gl3_2compat_glDrawPixels(void *_glfuncs, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl3_2compat_glCopyPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum gltype);
+void gl3_2compat_glPixelMapusv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLushort* values);
+void gl3_2compat_glPixelMapuiv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLuint* values);
+void gl3_2compat_glPixelMapfv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLfloat* values);
+void gl3_2compat_glPixelTransferi(void *_glfuncs, GLenum pname, GLint param);
+void gl3_2compat_glPixelTransferf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl3_2compat_glPixelZoom(void *_glfuncs, GLfloat xfactor, GLfloat yfactor);
+void gl3_2compat_glAlphaFunc(void *_glfuncs, GLenum glfunc, GLfloat ref);
+void gl3_2compat_glEvalPoint2(void *_glfuncs, GLint i, GLint j);
+void gl3_2compat_glEvalMesh2(void *_glfuncs, GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2);
+void gl3_2compat_glEvalPoint1(void *_glfuncs, GLint i);
+void gl3_2compat_glEvalMesh1(void *_glfuncs, GLenum mode, GLint i1, GLint i2);
+void gl3_2compat_glEvalCoord2fv(void *_glfuncs, const GLfloat* u);
+void gl3_2compat_glEvalCoord2f(void *_glfuncs, GLfloat u, GLfloat v);
+void gl3_2compat_glEvalCoord2dv(void *_glfuncs, const GLdouble* u);
+void gl3_2compat_glEvalCoord2d(void *_glfuncs, GLdouble u, GLdouble v);
+void gl3_2compat_glEvalCoord1fv(void *_glfuncs, const GLfloat* u);
+void gl3_2compat_glEvalCoord1f(void *_glfuncs, GLfloat u);
+void gl3_2compat_glEvalCoord1dv(void *_glfuncs, const GLdouble* u);
+void gl3_2compat_glEvalCoord1d(void *_glfuncs, GLdouble u);
+void gl3_2compat_glMapGrid2f(void *_glfuncs, GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2);
+void gl3_2compat_glMapGrid2d(void *_glfuncs, GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2);
+void gl3_2compat_glMapGrid1f(void *_glfuncs, GLint un, GLfloat u1, GLfloat u2);
+void gl3_2compat_glMapGrid1d(void *_glfuncs, GLint un, GLdouble u1, GLdouble u2);
+void gl3_2compat_glMap2f(void *_glfuncs, GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat* points);
+void gl3_2compat_glMap2d(void *_glfuncs, GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble* points);
+void gl3_2compat_glMap1f(void *_glfuncs, GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat* points);
+void gl3_2compat_glMap1d(void *_glfuncs, GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble* points);
+void gl3_2compat_glPushAttrib(void *_glfuncs, GLbitfield mask);
+void gl3_2compat_glPopAttrib(void *_glfuncs);
+void gl3_2compat_glAccum(void *_glfuncs, GLenum op, GLfloat value);
+void gl3_2compat_glIndexMask(void *_glfuncs, GLuint mask);
+void gl3_2compat_glClearIndex(void *_glfuncs, GLfloat c);
+void gl3_2compat_glClearAccum(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl3_2compat_glPushName(void *_glfuncs, GLuint name);
+void gl3_2compat_glPopName(void *_glfuncs);
+void gl3_2compat_glPassThrough(void *_glfuncs, GLfloat token);
+void gl3_2compat_glLoadName(void *_glfuncs, GLuint name);
+void gl3_2compat_glInitNames(void *_glfuncs);
+GLint gl3_2compat_glRenderMode(void *_glfuncs, GLenum mode);
+void gl3_2compat_glSelectBuffer(void *_glfuncs, GLsizei size, GLuint* buffer);
+void gl3_2compat_glFeedbackBuffer(void *_glfuncs, GLsizei size, GLenum gltype, GLfloat* buffer);
+void gl3_2compat_glTexGeniv(void *_glfuncs, GLenum coord, GLenum pname, const GLint* params);
+void gl3_2compat_glTexGeni(void *_glfuncs, GLenum coord, GLenum pname, GLint param);
+void gl3_2compat_glTexGenfv(void *_glfuncs, GLenum coord, GLenum pname, const GLfloat* params);
+void gl3_2compat_glTexGenf(void *_glfuncs, GLenum coord, GLenum pname, GLfloat param);
+void gl3_2compat_glTexGendv(void *_glfuncs, GLenum coord, GLenum pname, const GLdouble* params);
+void gl3_2compat_glTexGend(void *_glfuncs, GLenum coord, GLenum pname, GLdouble param);
+void gl3_2compat_glTexEnviv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl3_2compat_glTexEnvi(void *_glfuncs, GLenum target, GLenum pname, GLint param);
+void gl3_2compat_glTexEnvfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl3_2compat_glTexEnvf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param);
+void gl3_2compat_glShadeModel(void *_glfuncs, GLenum mode);
+void gl3_2compat_glPolygonStipple(void *_glfuncs, const GLubyte* mask);
+void gl3_2compat_glMaterialiv(void *_glfuncs, GLenum face, GLenum pname, const GLint* params);
+void gl3_2compat_glMateriali(void *_glfuncs, GLenum face, GLenum pname, GLint param);
+void gl3_2compat_glMaterialfv(void *_glfuncs, GLenum face, GLenum pname, const GLfloat* params);
+void gl3_2compat_glMaterialf(void *_glfuncs, GLenum face, GLenum pname, GLfloat param);
+void gl3_2compat_glLineStipple(void *_glfuncs, GLint factor, GLushort pattern);
+void gl3_2compat_glLightModeliv(void *_glfuncs, GLenum pname, const GLint* params);
+void gl3_2compat_glLightModeli(void *_glfuncs, GLenum pname, GLint param);
+void gl3_2compat_glLightModelfv(void *_glfuncs, GLenum pname, const GLfloat* params);
+void gl3_2compat_glLightModelf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl3_2compat_glLightiv(void *_glfuncs, GLenum light, GLenum pname, const GLint* params);
+void gl3_2compat_glLighti(void *_glfuncs, GLenum light, GLenum pname, GLint param);
+void gl3_2compat_glLightfv(void *_glfuncs, GLenum light, GLenum pname, const GLfloat* params);
+void gl3_2compat_glLightf(void *_glfuncs, GLenum light, GLenum pname, GLfloat param);
+void gl3_2compat_glFogiv(void *_glfuncs, GLenum pname, const GLint* params);
+void gl3_2compat_glFogi(void *_glfuncs, GLenum pname, GLint param);
+void gl3_2compat_glFogfv(void *_glfuncs, GLenum pname, const GLfloat* params);
+void gl3_2compat_glFogf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl3_2compat_glColorMaterial(void *_glfuncs, GLenum face, GLenum mode);
+void gl3_2compat_glClipPlane(void *_glfuncs, GLenum plane, const GLdouble* equation);
+void gl3_2compat_glVertex4sv(void *_glfuncs, const GLshort* v);
+void gl3_2compat_glVertex4s(void *_glfuncs, GLshort x, GLshort y, GLshort z, GLshort w);
+void gl3_2compat_glVertex4iv(void *_glfuncs, const GLint* v);
+void gl3_2compat_glVertex4i(void *_glfuncs, GLint x, GLint y, GLint z, GLint w);
+void gl3_2compat_glVertex4fv(void *_glfuncs, const GLfloat* v);
+void gl3_2compat_glVertex4f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+void gl3_2compat_glVertex4dv(void *_glfuncs, const GLdouble* v);
+void gl3_2compat_glVertex4d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+void gl3_2compat_glVertex3sv(void *_glfuncs, const GLshort* v);
+void gl3_2compat_glVertex3s(void *_glfuncs, GLshort x, GLshort y, GLshort z);
+void gl3_2compat_glVertex3iv(void *_glfuncs, const GLint* v);
+void gl3_2compat_glVertex3i(void *_glfuncs, GLint x, GLint y, GLint z);
+void gl3_2compat_glVertex3fv(void *_glfuncs, const GLfloat* v);
+void gl3_2compat_glVertex3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl3_2compat_glVertex3dv(void *_glfuncs, const GLdouble* v);
+void gl3_2compat_glVertex3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl3_2compat_glVertex2sv(void *_glfuncs, const GLshort* v);
+void gl3_2compat_glVertex2s(void *_glfuncs, GLshort x, GLshort y);
+void gl3_2compat_glVertex2iv(void *_glfuncs, const GLint* v);
+void gl3_2compat_glVertex2i(void *_glfuncs, GLint x, GLint y);
+void gl3_2compat_glVertex2fv(void *_glfuncs, const GLfloat* v);
+void gl3_2compat_glVertex2f(void *_glfuncs, GLfloat x, GLfloat y);
+void gl3_2compat_glVertex2dv(void *_glfuncs, const GLdouble* v);
+void gl3_2compat_glVertex2d(void *_glfuncs, GLdouble x, GLdouble y);
+void gl3_2compat_glTexCoord4sv(void *_glfuncs, const GLshort* v);
+void gl3_2compat_glTexCoord4s(void *_glfuncs, GLshort s, GLshort t, GLshort r, GLshort q);
+void gl3_2compat_glTexCoord4iv(void *_glfuncs, const GLint* v);
+void gl3_2compat_glTexCoord4i(void *_glfuncs, GLint s, GLint t, GLint r, GLint q);
+void gl3_2compat_glTexCoord4fv(void *_glfuncs, const GLfloat* v);
+void gl3_2compat_glTexCoord4f(void *_glfuncs, GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+void gl3_2compat_glTexCoord4dv(void *_glfuncs, const GLdouble* v);
+void gl3_2compat_glTexCoord4d(void *_glfuncs, GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+void gl3_2compat_glTexCoord3sv(void *_glfuncs, const GLshort* v);
+void gl3_2compat_glTexCoord3s(void *_glfuncs, GLshort s, GLshort t, GLshort r);
+void gl3_2compat_glTexCoord3iv(void *_glfuncs, const GLint* v);
+void gl3_2compat_glTexCoord3i(void *_glfuncs, GLint s, GLint t, GLint r);
+void gl3_2compat_glTexCoord3fv(void *_glfuncs, const GLfloat* v);
+void gl3_2compat_glTexCoord3f(void *_glfuncs, GLfloat s, GLfloat t, GLfloat r);
+void gl3_2compat_glTexCoord3dv(void *_glfuncs, const GLdouble* v);
+void gl3_2compat_glTexCoord3d(void *_glfuncs, GLdouble s, GLdouble t, GLdouble r);
+void gl3_2compat_glTexCoord2sv(void *_glfuncs, const GLshort* v);
+void gl3_2compat_glTexCoord2s(void *_glfuncs, GLshort s, GLshort t);
+void gl3_2compat_glTexCoord2iv(void *_glfuncs, const GLint* v);
+void gl3_2compat_glTexCoord2i(void *_glfuncs, GLint s, GLint t);
+void gl3_2compat_glTexCoord2fv(void *_glfuncs, const GLfloat* v);
+void gl3_2compat_glTexCoord2f(void *_glfuncs, GLfloat s, GLfloat t);
+void gl3_2compat_glTexCoord2dv(void *_glfuncs, const GLdouble* v);
+void gl3_2compat_glTexCoord2d(void *_glfuncs, GLdouble s, GLdouble t);
+void gl3_2compat_glTexCoord1sv(void *_glfuncs, const GLshort* v);
+void gl3_2compat_glTexCoord1s(void *_glfuncs, GLshort s);
+void gl3_2compat_glTexCoord1iv(void *_glfuncs, const GLint* v);
+void gl3_2compat_glTexCoord1i(void *_glfuncs, GLint s);
+void gl3_2compat_glTexCoord1fv(void *_glfuncs, const GLfloat* v);
+void gl3_2compat_glTexCoord1f(void *_glfuncs, GLfloat s);
+void gl3_2compat_glTexCoord1dv(void *_glfuncs, const GLdouble* v);
+void gl3_2compat_glTexCoord1d(void *_glfuncs, GLdouble s);
+void gl3_2compat_glRectsv(void *_glfuncs, const GLshort* v1, const GLshort* v2);
+void gl3_2compat_glRects(void *_glfuncs, GLshort x1, GLshort y1, GLshort x2, GLshort y2);
+void gl3_2compat_glRectiv(void *_glfuncs, const GLint* v1, const GLint* v2);
+void gl3_2compat_glRecti(void *_glfuncs, GLint x1, GLint y1, GLint x2, GLint y2);
+void gl3_2compat_glRectfv(void *_glfuncs, const GLfloat* v1, const GLfloat* v2);
+void gl3_2compat_glRectf(void *_glfuncs, GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2);
+void gl3_2compat_glRectdv(void *_glfuncs, const GLdouble* v1, const GLdouble* v2);
+void gl3_2compat_glRectd(void *_glfuncs, GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2);
+void gl3_2compat_glRasterPos4sv(void *_glfuncs, const GLshort* v);
+void gl3_2compat_glRasterPos4s(void *_glfuncs, GLshort x, GLshort y, GLshort z, GLshort w);
+void gl3_2compat_glRasterPos4iv(void *_glfuncs, const GLint* v);
+void gl3_2compat_glRasterPos4i(void *_glfuncs, GLint x, GLint y, GLint z, GLint w);
+void gl3_2compat_glRasterPos4fv(void *_glfuncs, const GLfloat* v);
+void gl3_2compat_glRasterPos4f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+void gl3_2compat_glRasterPos4dv(void *_glfuncs, const GLdouble* v);
+void gl3_2compat_glRasterPos4d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+void gl3_2compat_glRasterPos3sv(void *_glfuncs, const GLshort* v);
+void gl3_2compat_glRasterPos3s(void *_glfuncs, GLshort x, GLshort y, GLshort z);
+void gl3_2compat_glRasterPos3iv(void *_glfuncs, const GLint* v);
+void gl3_2compat_glRasterPos3i(void *_glfuncs, GLint x, GLint y, GLint z);
+void gl3_2compat_glRasterPos3fv(void *_glfuncs, const GLfloat* v);
+void gl3_2compat_glRasterPos3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl3_2compat_glRasterPos3dv(void *_glfuncs, const GLdouble* v);
+void gl3_2compat_glRasterPos3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl3_2compat_glRasterPos2sv(void *_glfuncs, const GLshort* v);
+void gl3_2compat_glRasterPos2s(void *_glfuncs, GLshort x, GLshort y);
+void gl3_2compat_glRasterPos2iv(void *_glfuncs, const GLint* v);
+void gl3_2compat_glRasterPos2i(void *_glfuncs, GLint x, GLint y);
+void gl3_2compat_glRasterPos2fv(void *_glfuncs, const GLfloat* v);
+void gl3_2compat_glRasterPos2f(void *_glfuncs, GLfloat x, GLfloat y);
+void gl3_2compat_glRasterPos2dv(void *_glfuncs, const GLdouble* v);
+void gl3_2compat_glRasterPos2d(void *_glfuncs, GLdouble x, GLdouble y);
+void gl3_2compat_glNormal3sv(void *_glfuncs, const GLshort* v);
+void gl3_2compat_glNormal3s(void *_glfuncs, GLshort nx, GLshort ny, GLshort nz);
+void gl3_2compat_glNormal3iv(void *_glfuncs, const GLint* v);
+void gl3_2compat_glNormal3i(void *_glfuncs, GLint nx, GLint ny, GLint nz);
+void gl3_2compat_glNormal3fv(void *_glfuncs, const GLfloat* v);
+void gl3_2compat_glNormal3f(void *_glfuncs, GLfloat nx, GLfloat ny, GLfloat nz);
+void gl3_2compat_glNormal3dv(void *_glfuncs, const GLdouble* v);
+void gl3_2compat_glNormal3d(void *_glfuncs, GLdouble nx, GLdouble ny, GLdouble nz);
+void gl3_2compat_glNormal3bv(void *_glfuncs, const GLbyte* v);
+void gl3_2compat_glNormal3b(void *_glfuncs, GLbyte nx, GLbyte ny, GLbyte nz);
+void gl3_2compat_glIndexsv(void *_glfuncs, const GLshort* c);
+void gl3_2compat_glIndexs(void *_glfuncs, GLshort c);
+void gl3_2compat_glIndexiv(void *_glfuncs, const GLint* c);
+void gl3_2compat_glIndexi(void *_glfuncs, GLint c);
+void gl3_2compat_glIndexfv(void *_glfuncs, const GLfloat* c);
+void gl3_2compat_glIndexf(void *_glfuncs, GLfloat c);
+void gl3_2compat_glIndexdv(void *_glfuncs, const GLdouble* c);
+void gl3_2compat_glIndexd(void *_glfuncs, GLdouble c);
+void gl3_2compat_glEnd(void *_glfuncs);
+void gl3_2compat_glEdgeFlagv(void *_glfuncs, const GLboolean* flag);
+void gl3_2compat_glEdgeFlag(void *_glfuncs, GLboolean flag);
+void gl3_2compat_glColor4usv(void *_glfuncs, const GLushort* v);
+void gl3_2compat_glColor4us(void *_glfuncs, GLushort red, GLushort green, GLushort blue, GLushort alpha);
+void gl3_2compat_glColor4uiv(void *_glfuncs, const GLuint* v);
+void gl3_2compat_glColor4ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue, GLuint alpha);
+void gl3_2compat_glColor4ubv(void *_glfuncs, const GLubyte* v);
+void gl3_2compat_glColor4ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha);
+void gl3_2compat_glColor4sv(void *_glfuncs, const GLshort* v);
+void gl3_2compat_glColor4s(void *_glfuncs, GLshort red, GLshort green, GLshort blue, GLshort alpha);
+void gl3_2compat_glColor4iv(void *_glfuncs, const GLint* v);
+void gl3_2compat_glColor4i(void *_glfuncs, GLint red, GLint green, GLint blue, GLint alpha);
+void gl3_2compat_glColor4fv(void *_glfuncs, const GLfloat* v);
+void gl3_2compat_glColor4f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl3_2compat_glColor4dv(void *_glfuncs, const GLdouble* v);
+void gl3_2compat_glColor4d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha);
+void gl3_2compat_glColor4bv(void *_glfuncs, const GLbyte* v);
+void gl3_2compat_glColor4b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha);
+void gl3_2compat_glColor3usv(void *_glfuncs, const GLushort* v);
+void gl3_2compat_glColor3us(void *_glfuncs, GLushort red, GLushort green, GLushort blue);
+void gl3_2compat_glColor3uiv(void *_glfuncs, const GLuint* v);
+void gl3_2compat_glColor3ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue);
+void gl3_2compat_glColor3ubv(void *_glfuncs, const GLubyte* v);
+void gl3_2compat_glColor3ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue);
+void gl3_2compat_glColor3sv(void *_glfuncs, const GLshort* v);
+void gl3_2compat_glColor3s(void *_glfuncs, GLshort red, GLshort green, GLshort blue);
+void gl3_2compat_glColor3iv(void *_glfuncs, const GLint* v);
+void gl3_2compat_glColor3i(void *_glfuncs, GLint red, GLint green, GLint blue);
+void gl3_2compat_glColor3fv(void *_glfuncs, const GLfloat* v);
+void gl3_2compat_glColor3f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue);
+void gl3_2compat_glColor3dv(void *_glfuncs, const GLdouble* v);
+void gl3_2compat_glColor3d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue);
+void gl3_2compat_glColor3bv(void *_glfuncs, const GLbyte* v);
+void gl3_2compat_glColor3b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue);
+void gl3_2compat_glBitmap(void *_glfuncs, GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte* bitmap);
+void gl3_2compat_glBegin(void *_glfuncs, GLenum mode);
+void gl3_2compat_glListBase(void *_glfuncs, GLuint base);
+GLuint gl3_2compat_glGenLists(void *_glfuncs, GLsizei range_);
+void gl3_2compat_glDeleteLists(void *_glfuncs, GLuint list, GLsizei range_);
+void gl3_2compat_glCallLists(void *_glfuncs, GLsizei n, GLenum gltype, const GLvoid* lists);
+void gl3_2compat_glCallList(void *_glfuncs, GLuint list);
+void gl3_2compat_glEndList(void *_glfuncs);
+void gl3_2compat_glNewList(void *_glfuncs, GLuint list, GLenum mode);
+void gl3_2compat_glPushClientAttrib(void *_glfuncs, GLbitfield mask);
+void gl3_2compat_glPopClientAttrib(void *_glfuncs);
+void gl3_2compat_glPrioritizeTextures(void *_glfuncs, GLsizei n, const GLuint* textures, const GLfloat* priorities);
+GLboolean gl3_2compat_glAreTexturesResident(void *_glfuncs, GLsizei n, const GLuint* textures, GLboolean* residences);
+void gl3_2compat_glVertexPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl3_2compat_glTexCoordPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl3_2compat_glNormalPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl3_2compat_glInterleavedArrays(void *_glfuncs, GLenum format, GLsizei stride, const GLvoid* pointer);
+void gl3_2compat_glIndexPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl3_2compat_glEnableClientState(void *_glfuncs, GLenum array);
+void gl3_2compat_glEdgeFlagPointer(void *_glfuncs, GLsizei stride, const GLvoid* pointer);
+void gl3_2compat_glDisableClientState(void *_glfuncs, GLenum array);
+void gl3_2compat_glColorPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl3_2compat_glArrayElement(void *_glfuncs, GLint i);
+void gl3_2compat_glResetMinmax(void *_glfuncs, GLenum target);
+void gl3_2compat_glResetHistogram(void *_glfuncs, GLenum target);
+void gl3_2compat_glMinmax(void *_glfuncs, GLenum target, GLenum internalFormat, GLboolean sink);
+void gl3_2compat_glHistogram(void *_glfuncs, GLenum target, GLsizei width, GLenum internalFormat, GLboolean sink);
+void gl3_2compat_glGetMinmaxParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl3_2compat_glGetMinmaxParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl3_2compat_glGetMinmax(void *_glfuncs, GLenum target, GLboolean reset, GLenum format, GLenum gltype, GLvoid* values);
+void gl3_2compat_glGetHistogramParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl3_2compat_glGetHistogramParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl3_2compat_glGetHistogram(void *_glfuncs, GLenum target, GLboolean reset, GLenum format, GLenum gltype, GLvoid* values);
+void gl3_2compat_glSeparableFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* row, const GLvoid* column);
+void gl3_2compat_glGetSeparableFilter(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* row, GLvoid* column, GLvoid* span);
+void gl3_2compat_glGetConvolutionParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl3_2compat_glGetConvolutionParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl3_2compat_glGetConvolutionFilter(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* image);
+void gl3_2compat_glCopyConvolutionFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl3_2compat_glCopyConvolutionFilter1D(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width);
+void gl3_2compat_glConvolutionParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl3_2compat_glConvolutionParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint params);
+void gl3_2compat_glConvolutionParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl3_2compat_glConvolutionParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat params);
+void gl3_2compat_glConvolutionFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* image);
+void gl3_2compat_glConvolutionFilter1D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLenum format, GLenum gltype, const GLvoid* image);
+void gl3_2compat_glCopyColorSubTable(void *_glfuncs, GLenum target, GLsizei start, GLint x, GLint y, GLsizei width);
+void gl3_2compat_glColorSubTable(void *_glfuncs, GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum gltype, const GLvoid* data);
+void gl3_2compat_glGetColorTableParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl3_2compat_glGetColorTableParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl3_2compat_glGetColorTable(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* table);
+void gl3_2compat_glCopyColorTable(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width);
+void gl3_2compat_glColorTableParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl3_2compat_glColorTableParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl3_2compat_glColorTable(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLenum format, GLenum gltype, const GLvoid* table);
+void gl3_2compat_glMultTransposeMatrixd(void *_glfuncs, const GLdouble* m);
+void gl3_2compat_glMultTransposeMatrixf(void *_glfuncs, const GLfloat* m);
+void gl3_2compat_glLoadTransposeMatrixd(void *_glfuncs, const GLdouble* m);
+void gl3_2compat_glLoadTransposeMatrixf(void *_glfuncs, const GLfloat* m);
+void gl3_2compat_glMultiTexCoord4sv(void *_glfuncs, GLenum target, const GLshort* v);
+void gl3_2compat_glMultiTexCoord4s(void *_glfuncs, GLenum target, GLshort s, GLshort t, GLshort r, GLshort q);
+void gl3_2compat_glMultiTexCoord4iv(void *_glfuncs, GLenum target, const GLint* v);
+void gl3_2compat_glMultiTexCoord4i(void *_glfuncs, GLenum target, GLint s, GLint t, GLint r, GLint q);
+void gl3_2compat_glMultiTexCoord4fv(void *_glfuncs, GLenum target, const GLfloat* v);
+void gl3_2compat_glMultiTexCoord4f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+void gl3_2compat_glMultiTexCoord4dv(void *_glfuncs, GLenum target, const GLdouble* v);
+void gl3_2compat_glMultiTexCoord4d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+void gl3_2compat_glMultiTexCoord3sv(void *_glfuncs, GLenum target, const GLshort* v);
+void gl3_2compat_glMultiTexCoord3s(void *_glfuncs, GLenum target, GLshort s, GLshort t, GLshort r);
+void gl3_2compat_glMultiTexCoord3iv(void *_glfuncs, GLenum target, const GLint* v);
+void gl3_2compat_glMultiTexCoord3i(void *_glfuncs, GLenum target, GLint s, GLint t, GLint r);
+void gl3_2compat_glMultiTexCoord3fv(void *_glfuncs, GLenum target, const GLfloat* v);
+void gl3_2compat_glMultiTexCoord3f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t, GLfloat r);
+void gl3_2compat_glMultiTexCoord3dv(void *_glfuncs, GLenum target, const GLdouble* v);
+void gl3_2compat_glMultiTexCoord3d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t, GLdouble r);
+void gl3_2compat_glMultiTexCoord2sv(void *_glfuncs, GLenum target, const GLshort* v);
+void gl3_2compat_glMultiTexCoord2s(void *_glfuncs, GLenum target, GLshort s, GLshort t);
+void gl3_2compat_glMultiTexCoord2iv(void *_glfuncs, GLenum target, const GLint* v);
+void gl3_2compat_glMultiTexCoord2i(void *_glfuncs, GLenum target, GLint s, GLint t);
+void gl3_2compat_glMultiTexCoord2fv(void *_glfuncs, GLenum target, const GLfloat* v);
+void gl3_2compat_glMultiTexCoord2f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t);
+void gl3_2compat_glMultiTexCoord2dv(void *_glfuncs, GLenum target, const GLdouble* v);
+void gl3_2compat_glMultiTexCoord2d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t);
+void gl3_2compat_glMultiTexCoord1sv(void *_glfuncs, GLenum target, const GLshort* v);
+void gl3_2compat_glMultiTexCoord1s(void *_glfuncs, GLenum target, GLshort s);
+void gl3_2compat_glMultiTexCoord1iv(void *_glfuncs, GLenum target, const GLint* v);
+void gl3_2compat_glMultiTexCoord1i(void *_glfuncs, GLenum target, GLint s);
+void gl3_2compat_glMultiTexCoord1fv(void *_glfuncs, GLenum target, const GLfloat* v);
+void gl3_2compat_glMultiTexCoord1f(void *_glfuncs, GLenum target, GLfloat s);
+void gl3_2compat_glMultiTexCoord1dv(void *_glfuncs, GLenum target, const GLdouble* v);
+void gl3_2compat_glMultiTexCoord1d(void *_glfuncs, GLenum target, GLdouble s);
+void gl3_2compat_glClientActiveTexture(void *_glfuncs, GLenum texture);
+void gl3_2compat_glWindowPos3sv(void *_glfuncs, const GLshort* v);
+void gl3_2compat_glWindowPos3s(void *_glfuncs, GLshort x, GLshort y, GLshort z);
+void gl3_2compat_glWindowPos3iv(void *_glfuncs, const GLint* v);
+void gl3_2compat_glWindowPos3i(void *_glfuncs, GLint x, GLint y, GLint z);
+void gl3_2compat_glWindowPos3fv(void *_glfuncs, const GLfloat* v);
+void gl3_2compat_glWindowPos3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl3_2compat_glWindowPos3dv(void *_glfuncs, const GLdouble* v);
+void gl3_2compat_glWindowPos3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl3_2compat_glWindowPos2sv(void *_glfuncs, const GLshort* v);
+void gl3_2compat_glWindowPos2s(void *_glfuncs, GLshort x, GLshort y);
+void gl3_2compat_glWindowPos2iv(void *_glfuncs, const GLint* v);
+void gl3_2compat_glWindowPos2i(void *_glfuncs, GLint x, GLint y);
+void gl3_2compat_glWindowPos2fv(void *_glfuncs, const GLfloat* v);
+void gl3_2compat_glWindowPos2f(void *_glfuncs, GLfloat x, GLfloat y);
+void gl3_2compat_glWindowPos2dv(void *_glfuncs, const GLdouble* v);
+void gl3_2compat_glWindowPos2d(void *_glfuncs, GLdouble x, GLdouble y);
+void gl3_2compat_glSecondaryColorPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl3_2compat_glSecondaryColor3usv(void *_glfuncs, const GLushort* v);
+void gl3_2compat_glSecondaryColor3us(void *_glfuncs, GLushort red, GLushort green, GLushort blue);
+void gl3_2compat_glSecondaryColor3uiv(void *_glfuncs, const GLuint* v);
+void gl3_2compat_glSecondaryColor3ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue);
+void gl3_2compat_glSecondaryColor3ubv(void *_glfuncs, const GLubyte* v);
+void gl3_2compat_glSecondaryColor3ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue);
+void gl3_2compat_glSecondaryColor3sv(void *_glfuncs, const GLshort* v);
+void gl3_2compat_glSecondaryColor3s(void *_glfuncs, GLshort red, GLshort green, GLshort blue);
+void gl3_2compat_glSecondaryColor3iv(void *_glfuncs, const GLint* v);
+void gl3_2compat_glSecondaryColor3i(void *_glfuncs, GLint red, GLint green, GLint blue);
+void gl3_2compat_glSecondaryColor3fv(void *_glfuncs, const GLfloat* v);
+void gl3_2compat_glSecondaryColor3f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue);
+void gl3_2compat_glSecondaryColor3dv(void *_glfuncs, const GLdouble* v);
+void gl3_2compat_glSecondaryColor3d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue);
+void gl3_2compat_glSecondaryColor3bv(void *_glfuncs, const GLbyte* v);
+void gl3_2compat_glSecondaryColor3b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue);
+void gl3_2compat_glFogCoordPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl3_2compat_glFogCoorddv(void *_glfuncs, const GLdouble* coord);
+void gl3_2compat_glFogCoordd(void *_glfuncs, GLdouble coord);
+void gl3_2compat_glFogCoordfv(void *_glfuncs, const GLfloat* coord);
+void gl3_2compat_glFogCoordf(void *_glfuncs, GLfloat coord);
+void gl3_2compat_glVertexAttrib4usv(void *_glfuncs, GLuint index, const GLushort* v);
+void gl3_2compat_glVertexAttrib4uiv(void *_glfuncs, GLuint index, const GLuint* v);
+void gl3_2compat_glVertexAttrib4ubv(void *_glfuncs, GLuint index, const GLubyte* v);
+void gl3_2compat_glVertexAttrib4sv(void *_glfuncs, GLuint index, const GLshort* v);
+void gl3_2compat_glVertexAttrib4s(void *_glfuncs, GLuint index, GLshort x, GLshort y, GLshort z, GLshort w);
+void gl3_2compat_glVertexAttrib4iv(void *_glfuncs, GLuint index, const GLint* v);
+void gl3_2compat_glVertexAttrib4fv(void *_glfuncs, GLuint index, const GLfloat* v);
+void gl3_2compat_glVertexAttrib4f(void *_glfuncs, GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+void gl3_2compat_glVertexAttrib4dv(void *_glfuncs, GLuint index, const GLdouble* v);
+void gl3_2compat_glVertexAttrib4d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+void gl3_2compat_glVertexAttrib4bv(void *_glfuncs, GLuint index, const GLbyte* v);
+void gl3_2compat_glVertexAttrib4Nusv(void *_glfuncs, GLuint index, const GLushort* v);
+void gl3_2compat_glVertexAttrib4Nuiv(void *_glfuncs, GLuint index, const GLuint* v);
+void gl3_2compat_glVertexAttrib4Nubv(void *_glfuncs, GLuint index, const GLubyte* v);
+void gl3_2compat_glVertexAttrib4Nub(void *_glfuncs, GLuint index, GLubyte x, GLubyte y, GLubyte z, GLubyte w);
+void gl3_2compat_glVertexAttrib4Nsv(void *_glfuncs, GLuint index, const GLshort* v);
+void gl3_2compat_glVertexAttrib4Niv(void *_glfuncs, GLuint index, const GLint* v);
+void gl3_2compat_glVertexAttrib4Nbv(void *_glfuncs, GLuint index, const GLbyte* v);
+void gl3_2compat_glVertexAttrib3sv(void *_glfuncs, GLuint index, const GLshort* v);
+void gl3_2compat_glVertexAttrib3s(void *_glfuncs, GLuint index, GLshort x, GLshort y, GLshort z);
+void gl3_2compat_glVertexAttrib3fv(void *_glfuncs, GLuint index, const GLfloat* v);
+void gl3_2compat_glVertexAttrib3f(void *_glfuncs, GLuint index, GLfloat x, GLfloat y, GLfloat z);
+void gl3_2compat_glVertexAttrib3dv(void *_glfuncs, GLuint index, const GLdouble* v);
+void gl3_2compat_glVertexAttrib3d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y, GLdouble z);
+void gl3_2compat_glVertexAttrib2sv(void *_glfuncs, GLuint index, const GLshort* v);
+void gl3_2compat_glVertexAttrib2s(void *_glfuncs, GLuint index, GLshort x, GLshort y);
+void gl3_2compat_glVertexAttrib2fv(void *_glfuncs, GLuint index, const GLfloat* v);
+void gl3_2compat_glVertexAttrib2f(void *_glfuncs, GLuint index, GLfloat x, GLfloat y);
+void gl3_2compat_glVertexAttrib2dv(void *_glfuncs, GLuint index, const GLdouble* v);
+void gl3_2compat_glVertexAttrib2d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y);
+void gl3_2compat_glVertexAttrib1sv(void *_glfuncs, GLuint index, const GLshort* v);
+void gl3_2compat_glVertexAttrib1s(void *_glfuncs, GLuint index, GLshort x);
+void gl3_2compat_glVertexAttrib1fv(void *_glfuncs, GLuint index, const GLfloat* v);
+void gl3_2compat_glVertexAttrib1f(void *_glfuncs, GLuint index, GLfloat x);
+void gl3_2compat_glVertexAttrib1dv(void *_glfuncs, GLuint index, const GLdouble* v);
+void gl3_2compat_glVertexAttrib1d(void *_glfuncs, GLuint index, GLdouble x);
+void gl3_2compat_glVertexAttribI4usv(void *_glfuncs, GLuint index, const GLushort* v);
+void gl3_2compat_glVertexAttribI4ubv(void *_glfuncs, GLuint index, const GLubyte* v);
+void gl3_2compat_glVertexAttribI4sv(void *_glfuncs, GLuint index, const GLshort* v);
+void gl3_2compat_glVertexAttribI4bv(void *_glfuncs, GLuint index, const GLbyte* v);
+void gl3_2compat_glVertexAttribI4uiv(void *_glfuncs, GLuint index, const GLuint* v);
+void gl3_2compat_glVertexAttribI3uiv(void *_glfuncs, GLuint index, const GLuint* v);
+void gl3_2compat_glVertexAttribI2uiv(void *_glfuncs, GLuint index, const GLuint* v);
+void gl3_2compat_glVertexAttribI1uiv(void *_glfuncs, GLuint index, const GLuint* v);
+void gl3_2compat_glVertexAttribI4iv(void *_glfuncs, GLuint index, const GLint* v);
+void gl3_2compat_glVertexAttribI3iv(void *_glfuncs, GLuint index, const GLint* v);
+void gl3_2compat_glVertexAttribI2iv(void *_glfuncs, GLuint index, const GLint* v);
+void gl3_2compat_glVertexAttribI1iv(void *_glfuncs, GLuint index, const GLint* v);
+void gl3_2compat_glVertexAttribI4ui(void *_glfuncs, GLuint index, GLuint x, GLuint y, GLuint z, GLuint w);
+void gl3_2compat_glVertexAttribI3ui(void *_glfuncs, GLuint index, GLuint x, GLuint y, GLuint z);
+void gl3_2compat_glVertexAttribI2ui(void *_glfuncs, GLuint index, GLuint x, GLuint y);
+void gl3_2compat_glVertexAttribI1ui(void *_glfuncs, GLuint index, GLuint x);
+void gl3_2compat_glVertexAttribI4i(void *_glfuncs, GLuint index, GLint x, GLint y, GLint z, GLint w);
+void gl3_2compat_glVertexAttribI3i(void *_glfuncs, GLuint index, GLint x, GLint y, GLint z);
+void gl3_2compat_glVertexAttribI2i(void *_glfuncs, GLuint index, GLint x, GLint y);
+void gl3_2compat_glVertexAttribI1i(void *_glfuncs, GLuint index, GLint x);
+
+
+#ifdef __cplusplus
+} // extern "C"
+#endif
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/3.2compat/gl.go b/Godeps/_workspace/src/github.com/obscuren/qml/gl/3.2compat/gl.go
new file mode 100644
index 000000000..3cf74a01e
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/3.2compat/gl.go
@@ -0,0 +1,7973 @@
+// ** file automatically generated by glgen -- do not edit manually **
+
+package GL
+
+// #cgo CXXFLAGS: -std=c++0x -pedantic-errors -Wall -fno-strict-aliasing
+// #cgo LDFLAGS: -lstdc++
+// #cgo pkg-config: Qt5Core Qt5OpenGL
+//
+// #include "funcs.h"
+//
+// void free(void*);
+//
+import "C"
+
+import (
+ "fmt"
+ "reflect"
+ "unsafe"
+
+ "gopkg.in/qml.v1/gl/glbase"
+)
+
+// API returns a value that offers methods matching the OpenGL version 3.2 API.
+//
+// The returned API must not be used after the provided OpenGL context becomes invalid.
+func API(context glbase.Contexter) *GL {
+ gl := &GL{}
+ gl.funcs = C.gl3_2compat_funcs()
+ if gl.funcs == nil {
+ panic(fmt.Errorf("OpenGL version 3.2 is not available"))
+ }
+ return gl
+}
+
+// GL implements the OpenGL version 3.2 API. Values of this
+// type must be created via the API function, and it must not be used after
+// the associated OpenGL context becomes invalid.
+type GL struct {
+ funcs unsafe.Pointer
+}
+
+const (
+ FALSE = 0
+ TRUE = 1
+ NONE = 0
+
+ BYTE = 0x1400
+ UNSIGNED_BYTE = 0x1401
+ SHORT = 0x1402
+ UNSIGNED_SHORT = 0x1403
+ INT = 0x1404
+ UNSIGNED_INT = 0x1405
+ FLOAT = 0x1406
+ N2_BYTES = 0x1407
+ N3_BYTES = 0x1408
+ N4_BYTES = 0x1409
+ DOUBLE = 0x140A
+ HALF_FLOAT = 0x140B
+
+ ACCUM = 0x0100
+ LOAD = 0x0101
+ RETURN = 0x0102
+ MULT = 0x0103
+ ADD = 0x0104
+
+ ACCUM_BUFFER_BIT = 0x00000200
+ ALL_ATTRIB_BITS = 0xFFFFFFFF
+ COLOR_BUFFER_BIT = 0x00004000
+ CURRENT_BIT = 0x00000001
+ DEPTH_BUFFER_BIT = 0x00000100
+ ENABLE_BIT = 0x00002000
+ EVAL_BIT = 0x00010000
+ FOG_BIT = 0x00000080
+ HINT_BIT = 0x00008000
+ LIGHTING_BIT = 0x00000040
+ LINE_BIT = 0x00000004
+ LIST_BIT = 0x00020000
+ MULTISAMPLE_BIT = 0x20000000
+ PIXEL_MODE_BIT = 0x00000020
+ POINT_BIT = 0x00000002
+ POLYGON_BIT = 0x00000008
+ POLYGON_STIPPLE_BIT = 0x00000010
+ SCISSOR_BIT = 0x00080000
+ STENCIL_BUFFER_BIT = 0x00000400
+ TEXTURE_BIT = 0x00040000
+ TRANSFORM_BIT = 0x00001000
+ VIEWPORT_BIT = 0x00000800
+
+ ALWAYS = 0x0207
+ EQUAL = 0x0202
+ GEQUAL = 0x0206
+ GREATER = 0x0204
+ LEQUAL = 0x0203
+ LESS = 0x0201
+ NEVER = 0x0200
+ NOTEQUAL = 0x0205
+
+ LOGIC_OP = 0x0BF1
+
+ DST_ALPHA = 0x0304
+ ONE = 1
+ ONE_MINUS_DST_ALPHA = 0x0305
+ ONE_MINUS_SRC_ALPHA = 0x0303
+ ONE_MINUS_SRC_COLOR = 0x0301
+ SRC_ALPHA = 0x0302
+ SRC_COLOR = 0x0300
+ ZERO = 0
+
+ DST_COLOR = 0x0306
+ ONE_MINUS_DST_COLOR = 0x0307
+ SRC_ALPHA_SATURATE = 0x0308
+
+ CLIENT_ALL_ATTRIB_BITS = 0xFFFFFFFF
+ CLIENT_PIXEL_STORE_BIT = 0x00000001
+ CLIENT_VERTEX_ARRAY_BIT = 0x00000002
+
+ CLIP_DISTANCE0 = 0x3000
+ CLIP_DISTANCE1 = 0x3001
+ CLIP_DISTANCE2 = 0x3002
+ CLIP_DISTANCE3 = 0x3003
+ CLIP_DISTANCE4 = 0x3004
+ CLIP_DISTANCE5 = 0x3005
+ CLIP_DISTANCE6 = 0x3006
+ CLIP_DISTANCE7 = 0x3007
+ CLIP_PLANE0 = 0x3000
+ CLIP_PLANE1 = 0x3001
+ CLIP_PLANE2 = 0x3002
+ CLIP_PLANE3 = 0x3003
+ CLIP_PLANE4 = 0x3004
+ CLIP_PLANE5 = 0x3005
+
+ BACK = 0x0405
+ FRONT = 0x0404
+ FRONT_AND_BACK = 0x0408
+
+ AMBIENT = 0x1200
+ AMBIENT_AND_DIFFUSE = 0x1602
+ DIFFUSE = 0x1201
+ EMISSION = 0x1600
+ SPECULAR = 0x1202
+
+ CONTEXT_FLAG_FORWARD_COMPATIBLE_BIT = 0x00000001
+
+ CONTEXT_COMPATIBILITY_PROFILE_BIT = 0x00000002
+ CONTEXT_CORE_PROFILE_BIT = 0x00000001
+
+ AUX0 = 0x0409
+ AUX1 = 0x040A
+ AUX2 = 0x040B
+ AUX3 = 0x040C
+ BACK_LEFT = 0x0402
+ BACK_RIGHT = 0x0403
+ FRONT_LEFT = 0x0400
+ FRONT_RIGHT = 0x0401
+ LEFT = 0x0406
+ RIGHT = 0x0407
+
+ ALPHA_TEST = 0x0BC0
+ AUTO_NORMAL = 0x0D80
+ BLEND = 0x0BE2
+ COLOR_ARRAY = 0x8076
+ COLOR_LOGIC_OP = 0x0BF2
+ COLOR_MATERIAL = 0x0B57
+ CULL_FACE = 0x0B44
+ DEPTH_TEST = 0x0B71
+ DITHER = 0x0BD0
+ EDGE_FLAG_ARRAY = 0x8079
+ FOG = 0x0B60
+ INDEX_ARRAY = 0x8077
+ INDEX_LOGIC_OP = 0x0BF1
+ LIGHT0 = 0x4000
+ LIGHT1 = 0x4001
+ LIGHT2 = 0x4002
+ LIGHT3 = 0x4003
+ LIGHT4 = 0x4004
+ LIGHT5 = 0x4005
+ LIGHT6 = 0x4006
+ LIGHT7 = 0x4007
+ LIGHTING = 0x0B50
+ LINE_SMOOTH = 0x0B20
+ LINE_STIPPLE = 0x0B24
+ MAP1_COLOR_4 = 0x0D90
+ MAP1_INDEX = 0x0D91
+ MAP1_NORMAL = 0x0D92
+ MAP1_TEXTURE_COORD_1 = 0x0D93
+ MAP1_TEXTURE_COORD_2 = 0x0D94
+ MAP1_TEXTURE_COORD_3 = 0x0D95
+ MAP1_TEXTURE_COORD_4 = 0x0D96
+ MAP1_VERTEX_3 = 0x0D97
+ MAP1_VERTEX_4 = 0x0D98
+ MAP2_COLOR_4 = 0x0DB0
+ MAP2_INDEX = 0x0DB1
+ MAP2_NORMAL = 0x0DB2
+ MAP2_TEXTURE_COORD_1 = 0x0DB3
+ MAP2_TEXTURE_COORD_2 = 0x0DB4
+ MAP2_TEXTURE_COORD_3 = 0x0DB5
+ MAP2_TEXTURE_COORD_4 = 0x0DB6
+ MAP2_VERTEX_3 = 0x0DB7
+ MAP2_VERTEX_4 = 0x0DB8
+ NORMALIZE = 0x0BA1
+ NORMAL_ARRAY = 0x8075
+ POINT_SMOOTH = 0x0B10
+ POLYGON_OFFSET_FILL = 0x8037
+ POLYGON_OFFSET_LINE = 0x2A02
+ POLYGON_OFFSET_POINT = 0x2A01
+ POLYGON_SMOOTH = 0x0B41
+ POLYGON_STIPPLE = 0x0B42
+ SCISSOR_TEST = 0x0C11
+ STENCIL_TEST = 0x0B90
+ TEXTURE_1D = 0x0DE0
+ TEXTURE_2D = 0x0DE1
+ TEXTURE_COORD_ARRAY = 0x8078
+ TEXTURE_GEN_Q = 0x0C63
+ TEXTURE_GEN_R = 0x0C62
+ TEXTURE_GEN_S = 0x0C60
+ TEXTURE_GEN_T = 0x0C61
+ VERTEX_ARRAY = 0x8074
+
+ INVALID_ENUM = 0x0500
+ INVALID_FRAMEBUFFER_OPERATION = 0x0506
+ INVALID_OPERATION = 0x0502
+ INVALID_VALUE = 0x0501
+ NO_ERROR = 0
+ OUT_OF_MEMORY = 0x0505
+ STACK_OVERFLOW = 0x0503
+ STACK_UNDERFLOW = 0x0504
+
+ N2D = 0x0600
+ N3D = 0x0601
+ N3D_COLOR = 0x0602
+ N3D_COLOR_TEXTURE = 0x0603
+ N4D_COLOR_TEXTURE = 0x0604
+
+ BITMAP_TOKEN = 0x0704
+ COPY_PIXEL_TOKEN = 0x0706
+ DRAW_PIXEL_TOKEN = 0x0705
+ LINE_RESET_TOKEN = 0x0707
+ LINE_TOKEN = 0x0702
+ PASS_THROUGH_TOKEN = 0x0700
+ POINT_TOKEN = 0x0701
+ POLYGON_TOKEN = 0x0703
+
+ EXP = 0x0800
+ EXP2 = 0x0801
+ LINEAR = 0x2601
+
+ FOG_COLOR = 0x0B66
+ FOG_DENSITY = 0x0B62
+ FOG_END = 0x0B64
+ FOG_INDEX = 0x0B61
+ FOG_MODE = 0x0B65
+ FOG_START = 0x0B63
+
+ CCW = 0x0901
+ CW = 0x0900
+
+ COEFF = 0x0A00
+ DOMAIN = 0x0A02
+ ORDER = 0x0A01
+
+ PIXEL_MAP_A_TO_A = 0x0C79
+ PIXEL_MAP_B_TO_B = 0x0C78
+ PIXEL_MAP_G_TO_G = 0x0C77
+ PIXEL_MAP_I_TO_A = 0x0C75
+ PIXEL_MAP_I_TO_B = 0x0C74
+ PIXEL_MAP_I_TO_G = 0x0C73
+ PIXEL_MAP_I_TO_I = 0x0C70
+ PIXEL_MAP_I_TO_R = 0x0C72
+ PIXEL_MAP_R_TO_R = 0x0C76
+ PIXEL_MAP_S_TO_S = 0x0C71
+
+ ACCUM_ALPHA_BITS = 0x0D5B
+ ACCUM_BLUE_BITS = 0x0D5A
+ ACCUM_CLEAR_VALUE = 0x0B80
+ ACCUM_GREEN_BITS = 0x0D59
+ ACCUM_RED_BITS = 0x0D58
+ ALIASED_LINE_WIDTH_RANGE = 0x846E
+ ALIASED_POINT_SIZE_RANGE = 0x846D
+ ALPHA_BIAS = 0x0D1D
+ ALPHA_BITS = 0x0D55
+ ALPHA_SCALE = 0x0D1C
+ ALPHA_TEST_FUNC = 0x0BC1
+ ALPHA_TEST_REF = 0x0BC2
+ ATTRIB_STACK_DEPTH = 0x0BB0
+ AUX_BUFFERS = 0x0C00
+ BLEND_DST = 0x0BE0
+ BLEND_SRC = 0x0BE1
+ BLUE_BIAS = 0x0D1B
+ BLUE_BITS = 0x0D54
+ BLUE_SCALE = 0x0D1A
+ CLIENT_ATTRIB_STACK_DEPTH = 0x0BB1
+ COLOR_ARRAY_SIZE = 0x8081
+ COLOR_ARRAY_STRIDE = 0x8083
+ COLOR_ARRAY_TYPE = 0x8082
+ COLOR_CLEAR_VALUE = 0x0C22
+ COLOR_MATERIAL_FACE = 0x0B55
+ COLOR_MATERIAL_PARAMETER = 0x0B56
+ COLOR_WRITEMASK = 0x0C23
+ CULL_FACE_MODE = 0x0B45
+ CURRENT_COLOR = 0x0B00
+ CURRENT_INDEX = 0x0B01
+ CURRENT_NORMAL = 0x0B02
+ CURRENT_RASTER_COLOR = 0x0B04
+ CURRENT_RASTER_DISTANCE = 0x0B09
+ CURRENT_RASTER_INDEX = 0x0B05
+ CURRENT_RASTER_POSITION = 0x0B07
+ CURRENT_RASTER_POSITION_VALID = 0x0B08
+ CURRENT_RASTER_TEXTURE_COORDS = 0x0B06
+ CURRENT_TEXTURE_COORDS = 0x0B03
+ DEPTH_BIAS = 0x0D1F
+ DEPTH_BITS = 0x0D56
+ DEPTH_CLEAR_VALUE = 0x0B73
+ DEPTH_FUNC = 0x0B74
+ DEPTH_RANGE = 0x0B70
+ DEPTH_SCALE = 0x0D1E
+ DEPTH_WRITEMASK = 0x0B72
+ DOUBLEBUFFER = 0x0C32
+ DRAW_BUFFER = 0x0C01
+ EDGE_FLAG = 0x0B43
+ EDGE_FLAG_ARRAY_STRIDE = 0x808C
+ FEEDBACK_BUFFER_SIZE = 0x0DF1
+ FEEDBACK_BUFFER_TYPE = 0x0DF2
+ FOG_HINT = 0x0C54
+ FRONT_FACE = 0x0B46
+ GREEN_BIAS = 0x0D19
+ GREEN_BITS = 0x0D53
+ GREEN_SCALE = 0x0D18
+ INDEX_ARRAY_STRIDE = 0x8086
+ INDEX_ARRAY_TYPE = 0x8085
+ INDEX_BITS = 0x0D51
+ INDEX_CLEAR_VALUE = 0x0C20
+ INDEX_MODE = 0x0C30
+ INDEX_OFFSET = 0x0D13
+ INDEX_SHIFT = 0x0D12
+ INDEX_WRITEMASK = 0x0C21
+ LIGHT_MODEL_AMBIENT = 0x0B53
+ LIGHT_MODEL_COLOR_CONTROL = 0x81F8
+ LIGHT_MODEL_LOCAL_VIEWER = 0x0B51
+ LIGHT_MODEL_TWO_SIDE = 0x0B52
+ LINE_SMOOTH_HINT = 0x0C52
+ LINE_STIPPLE_PATTERN = 0x0B25
+ LINE_STIPPLE_REPEAT = 0x0B26
+ LINE_WIDTH = 0x0B21
+ LINE_WIDTH_GRANULARITY = 0x0B23
+ LINE_WIDTH_RANGE = 0x0B22
+ LIST_BASE = 0x0B32
+ LIST_INDEX = 0x0B33
+ LIST_MODE = 0x0B30
+ LOGIC_OP_MODE = 0x0BF0
+ MAP1_GRID_DOMAIN = 0x0DD0
+ MAP1_GRID_SEGMENTS = 0x0DD1
+ MAP2_GRID_DOMAIN = 0x0DD2
+ MAP2_GRID_SEGMENTS = 0x0DD3
+ MAP_COLOR = 0x0D10
+ MAP_STENCIL = 0x0D11
+ MATRIX_MODE = 0x0BA0
+ MAX_ATTRIB_STACK_DEPTH = 0x0D35
+ MAX_CLIENT_ATTRIB_STACK_DEPTH = 0x0D3B
+ MAX_CLIP_DISTANCES = 0x0D32
+ MAX_CLIP_PLANES = 0x0D32
+ MAX_EVAL_ORDER = 0x0D30
+ MAX_LIGHTS = 0x0D31
+ MAX_LIST_NESTING = 0x0B31
+ MAX_MODELVIEW_STACK_DEPTH = 0x0D36
+ MAX_NAME_STACK_DEPTH = 0x0D37
+ MAX_PIXEL_MAP_TABLE = 0x0D34
+ MAX_PROJECTION_STACK_DEPTH = 0x0D38
+ MAX_TEXTURE_SIZE = 0x0D33
+ MAX_TEXTURE_STACK_DEPTH = 0x0D39
+ MAX_VIEWPORT_DIMS = 0x0D3A
+ MODELVIEW_MATRIX = 0x0BA6
+ MODELVIEW_STACK_DEPTH = 0x0BA3
+ NAME_STACK_DEPTH = 0x0D70
+ NORMAL_ARRAY_STRIDE = 0x807F
+ NORMAL_ARRAY_TYPE = 0x807E
+ PACK_ALIGNMENT = 0x0D05
+ PACK_LSB_FIRST = 0x0D01
+ PACK_ROW_LENGTH = 0x0D02
+ PACK_SKIP_PIXELS = 0x0D04
+ PACK_SKIP_ROWS = 0x0D03
+ PACK_SWAP_BYTES = 0x0D00
+ PERSPECTIVE_CORRECTION_HINT = 0x0C50
+ PIXEL_MAP_A_TO_A_SIZE = 0x0CB9
+ PIXEL_MAP_B_TO_B_SIZE = 0x0CB8
+ PIXEL_MAP_G_TO_G_SIZE = 0x0CB7
+ PIXEL_MAP_I_TO_A_SIZE = 0x0CB5
+ PIXEL_MAP_I_TO_B_SIZE = 0x0CB4
+ PIXEL_MAP_I_TO_G_SIZE = 0x0CB3
+ PIXEL_MAP_I_TO_I_SIZE = 0x0CB0
+ PIXEL_MAP_I_TO_R_SIZE = 0x0CB2
+ PIXEL_MAP_R_TO_R_SIZE = 0x0CB6
+ PIXEL_MAP_S_TO_S_SIZE = 0x0CB1
+ POINT_SIZE = 0x0B11
+ POINT_SIZE_GRANULARITY = 0x0B13
+ POINT_SIZE_RANGE = 0x0B12
+ POINT_SMOOTH_HINT = 0x0C51
+ POLYGON_MODE = 0x0B40
+ POLYGON_OFFSET_FACTOR = 0x8038
+ POLYGON_OFFSET_UNITS = 0x2A00
+ POLYGON_SMOOTH_HINT = 0x0C53
+ PROJECTION_MATRIX = 0x0BA7
+ PROJECTION_STACK_DEPTH = 0x0BA4
+ READ_BUFFER = 0x0C02
+ RED_BIAS = 0x0D15
+ RED_BITS = 0x0D52
+ RED_SCALE = 0x0D14
+ RENDER_MODE = 0x0C40
+ RGBA_MODE = 0x0C31
+ SCISSOR_BOX = 0x0C10
+ SELECTION_BUFFER_SIZE = 0x0DF4
+ SHADE_MODEL = 0x0B54
+ SMOOTH_LINE_WIDTH_GRANULARITY = 0x0B23
+ SMOOTH_LINE_WIDTH_RANGE = 0x0B22
+ SMOOTH_POINT_SIZE_GRANULARITY = 0x0B13
+ SMOOTH_POINT_SIZE_RANGE = 0x0B12
+ STENCIL_BITS = 0x0D57
+ STENCIL_CLEAR_VALUE = 0x0B91
+ STENCIL_FAIL = 0x0B94
+ STENCIL_FUNC = 0x0B92
+ STENCIL_PASS_DEPTH_FAIL = 0x0B95
+ STENCIL_PASS_DEPTH_PASS = 0x0B96
+ STENCIL_REF = 0x0B97
+ STENCIL_VALUE_MASK = 0x0B93
+ STENCIL_WRITEMASK = 0x0B98
+ STEREO = 0x0C33
+ SUBPIXEL_BITS = 0x0D50
+ TEXTURE_BINDING_1D = 0x8068
+ TEXTURE_BINDING_2D = 0x8069
+ TEXTURE_BINDING_3D = 0x806A
+ TEXTURE_COORD_ARRAY_SIZE = 0x8088
+ TEXTURE_COORD_ARRAY_STRIDE = 0x808A
+ TEXTURE_COORD_ARRAY_TYPE = 0x8089
+ TEXTURE_MATRIX = 0x0BA8
+ TEXTURE_STACK_DEPTH = 0x0BA5
+ UNPACK_ALIGNMENT = 0x0CF5
+ UNPACK_LSB_FIRST = 0x0CF1
+ UNPACK_ROW_LENGTH = 0x0CF2
+ UNPACK_SKIP_PIXELS = 0x0CF4
+ UNPACK_SKIP_ROWS = 0x0CF3
+ UNPACK_SWAP_BYTES = 0x0CF0
+ VERTEX_ARRAY_SIZE = 0x807A
+ VERTEX_ARRAY_STRIDE = 0x807C
+ VERTEX_ARRAY_TYPE = 0x807B
+ VIEWPORT = 0x0BA2
+ ZOOM_X = 0x0D16
+ ZOOM_Y = 0x0D17
+
+ COLOR_ARRAY_POINTER = 0x8090
+ EDGE_FLAG_ARRAY_POINTER = 0x8093
+ FEEDBACK_BUFFER_POINTER = 0x0DF0
+ INDEX_ARRAY_POINTER = 0x8091
+ NORMAL_ARRAY_POINTER = 0x808F
+ SELECTION_BUFFER_POINTER = 0x0DF3
+ TEXTURE_COORD_ARRAY_POINTER = 0x8092
+ VERTEX_ARRAY_POINTER = 0x808E
+
+ TEXTURE_ALPHA_SIZE = 0x805F
+ TEXTURE_BLUE_SIZE = 0x805E
+ TEXTURE_BORDER = 0x1005
+ TEXTURE_BORDER_COLOR = 0x1004
+ TEXTURE_COMPONENTS = 0x1003
+ TEXTURE_GREEN_SIZE = 0x805D
+ TEXTURE_HEIGHT = 0x1001
+ TEXTURE_INTENSITY_SIZE = 0x8061
+ TEXTURE_INTERNAL_FORMAT = 0x1003
+ TEXTURE_LUMINANCE_SIZE = 0x8060
+ TEXTURE_MAG_FILTER = 0x2800
+ TEXTURE_MIN_FILTER = 0x2801
+ TEXTURE_PRIORITY = 0x8066
+ TEXTURE_RED_SIZE = 0x805C
+ TEXTURE_RESIDENT = 0x8067
+ TEXTURE_WIDTH = 0x1000
+ TEXTURE_WRAP_S = 0x2802
+ TEXTURE_WRAP_T = 0x2803
+
+ DONT_CARE = 0x1100
+ FASTEST = 0x1101
+ NICEST = 0x1102
+
+ FRAGMENT_SHADER_DERIVATIVE_HINT = 0x8B8B
+ GENERATE_MIPMAP_HINT = 0x8192
+ TEXTURE_COMPRESSION_HINT = 0x84EF
+
+ C3F_V3F = 0x2A24
+ C4F_N3F_V3F = 0x2A26
+ C4UB_V2F = 0x2A22
+ C4UB_V3F = 0x2A23
+ N3F_V3F = 0x2A25
+ T2F_C3F_V3F = 0x2A2A
+ T2F_C4F_N3F_V3F = 0x2A2C
+ T2F_C4UB_V3F = 0x2A29
+ T2F_N3F_V3F = 0x2A2B
+ T2F_V3F = 0x2A27
+ T4F_C4F_N3F_V4F = 0x2A2D
+ T4F_V4F = 0x2A28
+ V2F = 0x2A20
+ V3F = 0x2A21
+
+ MODULATE = 0x2100
+ REPLACE = 0x1E01
+
+ SEPARATE_SPECULAR_COLOR = 0x81FA
+ SINGLE_COLOR = 0x81F9
+
+ CONSTANT_ATTENUATION = 0x1207
+ LINEAR_ATTENUATION = 0x1208
+ POSITION = 0x1203
+ QUADRATIC_ATTENUATION = 0x1209
+ SPOT_CUTOFF = 0x1206
+ SPOT_DIRECTION = 0x1204
+ SPOT_EXPONENT = 0x1205
+
+ COMPILE = 0x1300
+ COMPILE_AND_EXECUTE = 0x1301
+
+ AND = 0x1501
+ AND_INVERTED = 0x1504
+ AND_REVERSE = 0x1502
+ CLEAR = 0x1500
+ COPY = 0x1503
+ COPY_INVERTED = 0x150C
+ EQUIV = 0x1509
+ INVERT = 0x150A
+ NAND = 0x150E
+ NOOP = 0x1505
+ NOR = 0x1508
+ OR = 0x1507
+ OR_INVERTED = 0x150D
+ OR_REVERSE = 0x150B
+ SET = 0x150F
+ XOR = 0x1506
+
+ MAP_FLUSH_EXPLICIT_BIT = 0x0010
+ MAP_INVALIDATE_BUFFER_BIT = 0x0008
+ MAP_INVALIDATE_RANGE_BIT = 0x0004
+ MAP_READ_BIT = 0x0001
+ MAP_UNSYNCHRONIZED_BIT = 0x0020
+ MAP_WRITE_BIT = 0x0002
+
+ COLOR_INDEXES = 0x1603
+ SHININESS = 0x1601
+
+ MODELVIEW = 0x1700
+ PROJECTION = 0x1701
+ TEXTURE = 0x1702
+
+ LINE = 0x1B01
+ POINT = 0x1B00
+
+ FILL = 0x1B02
+
+ COLOR = 0x1800
+ DEPTH = 0x1801
+ STENCIL = 0x1802
+
+ ALPHA = 0x1906
+ BLUE = 0x1905
+ COLOR_INDEX = 0x1900
+ DEPTH_COMPONENT = 0x1902
+ GREEN = 0x1904
+ LUMINANCE = 0x1909
+ LUMINANCE_ALPHA = 0x190A
+ RED = 0x1903
+ RGB = 0x1907
+ RGBA = 0x1908
+ STENCIL_INDEX = 0x1901
+
+ ALPHA12 = 0x803D
+ ALPHA16 = 0x803E
+ ALPHA4 = 0x803B
+ ALPHA8 = 0x803C
+ INTENSITY = 0x8049
+ INTENSITY12 = 0x804C
+ INTENSITY16 = 0x804D
+ INTENSITY4 = 0x804A
+ INTENSITY8 = 0x804B
+ LUMINANCE12 = 0x8041
+ LUMINANCE12_ALPHA12 = 0x8047
+ LUMINANCE12_ALPHA4 = 0x8046
+ LUMINANCE16 = 0x8042
+ LUMINANCE16_ALPHA16 = 0x8048
+ LUMINANCE4 = 0x803F
+ LUMINANCE4_ALPHA4 = 0x8043
+ LUMINANCE6_ALPHA2 = 0x8044
+ LUMINANCE8 = 0x8040
+ LUMINANCE8_ALPHA8 = 0x8045
+ R3_G3_B2 = 0x2A10
+ RGB10 = 0x8052
+ RGB10_A2 = 0x8059
+ RGB12 = 0x8053
+ RGB16 = 0x8054
+ RGB4 = 0x804F
+ RGB5 = 0x8050
+ RGB5_A1 = 0x8057
+ RGB8 = 0x8051
+ RGBA12 = 0x805A
+ RGBA16 = 0x805B
+ RGBA2 = 0x8055
+ RGBA4 = 0x8056
+ RGBA8 = 0x8058
+
+ PACK_IMAGE_HEIGHT = 0x806C
+ PACK_SKIP_IMAGES = 0x806B
+ UNPACK_IMAGE_HEIGHT = 0x806E
+ UNPACK_SKIP_IMAGES = 0x806D
+
+ BITMAP = 0x1A00
+ UNSIGNED_BYTE_3_3_2 = 0x8032
+ UNSIGNED_INT_10_10_10_2 = 0x8036
+ UNSIGNED_INT_8_8_8_8 = 0x8035
+ UNSIGNED_SHORT_4_4_4_4 = 0x8033
+ UNSIGNED_SHORT_5_5_5_1 = 0x8034
+
+ POINT_DISTANCE_ATTENUATION = 0x8129
+ POINT_FADE_THRESHOLD_SIZE = 0x8128
+ POINT_SIZE_MAX = 0x8127
+ POINT_SIZE_MIN = 0x8126
+
+ LINES = 0x0001
+ LINES_ADJACENCY = 0x000A
+ LINE_LOOP = 0x0002
+ LINE_STRIP = 0x0003
+ LINE_STRIP_ADJACENCY = 0x000B
+ POINTS = 0x0000
+ POLYGON = 0x0009
+ QUADS = 0x0007
+ QUAD_STRIP = 0x0008
+ TRIANGLES = 0x0004
+ TRIANGLES_ADJACENCY = 0x000C
+ TRIANGLE_FAN = 0x0006
+ TRIANGLE_STRIP = 0x0005
+ TRIANGLE_STRIP_ADJACENCY = 0x000D
+
+ FEEDBACK = 0x1C01
+ RENDER = 0x1C00
+ SELECT = 0x1C02
+
+ FLAT = 0x1D00
+ SMOOTH = 0x1D01
+
+ DECR = 0x1E03
+ INCR = 0x1E02
+ KEEP = 0x1E00
+
+ EXTENSIONS = 0x1F03
+ RENDERER = 0x1F01
+ VENDOR = 0x1F00
+ VERSION = 0x1F02
+
+ S = 0x2000
+ T = 0x2001
+ R = 0x2002
+ Q = 0x2003
+
+ DECAL = 0x2101
+
+ TEXTURE_ENV_COLOR = 0x2201
+ TEXTURE_ENV_MODE = 0x2200
+
+ TEXTURE_ENV = 0x2300
+
+ EYE_LINEAR = 0x2400
+ OBJECT_LINEAR = 0x2401
+ SPHERE_MAP = 0x2402
+
+ EYE_PLANE = 0x2502
+ OBJECT_PLANE = 0x2501
+ TEXTURE_GEN_MODE = 0x2500
+
+ NEAREST = 0x2600
+
+ LINEAR_MIPMAP_LINEAR = 0x2703
+ LINEAR_MIPMAP_NEAREST = 0x2701
+ NEAREST_MIPMAP_LINEAR = 0x2702
+ NEAREST_MIPMAP_NEAREST = 0x2700
+
+ GENERATE_MIPMAP = 0x8191
+ TEXTURE_WRAP_R = 0x8072
+
+ PROXY_TEXTURE_1D = 0x8063
+ PROXY_TEXTURE_2D = 0x8064
+ PROXY_TEXTURE_3D = 0x8070
+ TEXTURE_3D = 0x806F
+ TEXTURE_BASE_LEVEL = 0x813C
+ TEXTURE_MAX_LEVEL = 0x813D
+ TEXTURE_MAX_LOD = 0x813B
+ TEXTURE_MIN_LOD = 0x813A
+
+ CLAMP = 0x2900
+ CLAMP_TO_BORDER = 0x812D
+ CLAMP_TO_EDGE = 0x812F
+ REPEAT = 0x2901
+
+ SYNC_FLUSH_COMMANDS_BIT = 0x00000001
+ INVALID_INDEX = 0xFFFFFFFF
+ TIMEOUT_IGNORED = 0xFFFFFFFFFFFFFFFF
+ CONSTANT_COLOR = 0x8001
+ ONE_MINUS_CONSTANT_COLOR = 0x8002
+ CONSTANT_ALPHA = 0x8003
+ ONE_MINUS_CONSTANT_ALPHA = 0x8004
+ FUNC_ADD = 0x8006
+ MIN = 0x8007
+ MAX = 0x8008
+ BLEND_EQUATION_RGB = 0x8009
+ FUNC_SUBTRACT = 0x800A
+ FUNC_REVERSE_SUBTRACT = 0x800B
+ RESCALE_NORMAL = 0x803A
+ TEXTURE_DEPTH = 0x8071
+ MAX_3D_TEXTURE_SIZE = 0x8073
+ MULTISAMPLE = 0x809D
+ SAMPLE_ALPHA_TO_COVERAGE = 0x809E
+ SAMPLE_ALPHA_TO_ONE = 0x809F
+ SAMPLE_COVERAGE = 0x80A0
+ SAMPLE_BUFFERS = 0x80A8
+ SAMPLES = 0x80A9
+ SAMPLE_COVERAGE_VALUE = 0x80AA
+ SAMPLE_COVERAGE_INVERT = 0x80AB
+ BLEND_DST_RGB = 0x80C8
+ BLEND_SRC_RGB = 0x80C9
+ BLEND_DST_ALPHA = 0x80CA
+ BLEND_SRC_ALPHA = 0x80CB
+ BGR = 0x80E0
+ BGRA = 0x80E1
+ MAX_ELEMENTS_VERTICES = 0x80E8
+ MAX_ELEMENTS_INDICES = 0x80E9
+ DEPTH_COMPONENT16 = 0x81A5
+ DEPTH_COMPONENT24 = 0x81A6
+ DEPTH_COMPONENT32 = 0x81A7
+ FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING = 0x8210
+ FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE = 0x8211
+ FRAMEBUFFER_ATTACHMENT_RED_SIZE = 0x8212
+ FRAMEBUFFER_ATTACHMENT_GREEN_SIZE = 0x8213
+ FRAMEBUFFER_ATTACHMENT_BLUE_SIZE = 0x8214
+ FRAMEBUFFER_ATTACHMENT_ALPHA_SIZE = 0x8215
+ FRAMEBUFFER_ATTACHMENT_DEPTH_SIZE = 0x8216
+ FRAMEBUFFER_ATTACHMENT_STENCIL_SIZE = 0x8217
+ FRAMEBUFFER_DEFAULT = 0x8218
+ FRAMEBUFFER_UNDEFINED = 0x8219
+ DEPTH_STENCIL_ATTACHMENT = 0x821A
+ MAJOR_VERSION = 0x821B
+ MINOR_VERSION = 0x821C
+ NUM_EXTENSIONS = 0x821D
+ CONTEXT_FLAGS = 0x821E
+ INDEX = 0x8222
+ COMPRESSED_RED = 0x8225
+ COMPRESSED_RG = 0x8226
+ RG = 0x8227
+ RG_INTEGER = 0x8228
+ R8 = 0x8229
+ R16 = 0x822A
+ RG8 = 0x822B
+ RG16 = 0x822C
+ R16F = 0x822D
+ R32F = 0x822E
+ RG16F = 0x822F
+ RG32F = 0x8230
+ R8I = 0x8231
+ R8UI = 0x8232
+ R16I = 0x8233
+ R16UI = 0x8234
+ R32I = 0x8235
+ R32UI = 0x8236
+ RG8I = 0x8237
+ RG8UI = 0x8238
+ RG16I = 0x8239
+ RG16UI = 0x823A
+ RG32I = 0x823B
+ RG32UI = 0x823C
+ UNSIGNED_BYTE_2_3_3_REV = 0x8362
+ UNSIGNED_SHORT_5_6_5 = 0x8363
+ UNSIGNED_SHORT_5_6_5_REV = 0x8364
+ UNSIGNED_SHORT_4_4_4_4_REV = 0x8365
+ UNSIGNED_SHORT_1_5_5_5_REV = 0x8366
+ UNSIGNED_INT_8_8_8_8_REV = 0x8367
+ UNSIGNED_INT_2_10_10_10_REV = 0x8368
+ MIRRORED_REPEAT = 0x8370
+ FOG_COORDINATE_SOURCE = 0x8450
+ FOG_COORD_SRC = 0x8450
+ FOG_COORDINATE = 0x8451
+ FOG_COORD = 0x8451
+ FRAGMENT_DEPTH = 0x8452
+ CURRENT_FOG_COORDINATE = 0x8453
+ CURRENT_FOG_COORD = 0x8453
+ FOG_COORDINATE_ARRAY_TYPE = 0x8454
+ FOG_COORD_ARRAY_TYPE = 0x8454
+ FOG_COORDINATE_ARRAY_STRIDE = 0x8455
+ FOG_COORD_ARRAY_STRIDE = 0x8455
+ FOG_COORDINATE_ARRAY_POINTER = 0x8456
+ FOG_COORD_ARRAY_POINTER = 0x8456
+ FOG_COORDINATE_ARRAY = 0x8457
+ FOG_COORD_ARRAY = 0x8457
+ COLOR_SUM = 0x8458
+ CURRENT_SECONDARY_COLOR = 0x8459
+ SECONDARY_COLOR_ARRAY_SIZE = 0x845A
+ SECONDARY_COLOR_ARRAY_TYPE = 0x845B
+ SECONDARY_COLOR_ARRAY_STRIDE = 0x845C
+ SECONDARY_COLOR_ARRAY_POINTER = 0x845D
+ SECONDARY_COLOR_ARRAY = 0x845E
+ CURRENT_RASTER_SECONDARY_COLOR = 0x845F
+ TEXTURE0 = 0x84C0
+ TEXTURE1 = 0x84C1
+ TEXTURE2 = 0x84C2
+ TEXTURE3 = 0x84C3
+ TEXTURE4 = 0x84C4
+ TEXTURE5 = 0x84C5
+ TEXTURE6 = 0x84C6
+ TEXTURE7 = 0x84C7
+ TEXTURE8 = 0x84C8
+ TEXTURE9 = 0x84C9
+ TEXTURE10 = 0x84CA
+ TEXTURE11 = 0x84CB
+ TEXTURE12 = 0x84CC
+ TEXTURE13 = 0x84CD
+ TEXTURE14 = 0x84CE
+ TEXTURE15 = 0x84CF
+ TEXTURE16 = 0x84D0
+ TEXTURE17 = 0x84D1
+ TEXTURE18 = 0x84D2
+ TEXTURE19 = 0x84D3
+ TEXTURE20 = 0x84D4
+ TEXTURE21 = 0x84D5
+ TEXTURE22 = 0x84D6
+ TEXTURE23 = 0x84D7
+ TEXTURE24 = 0x84D8
+ TEXTURE25 = 0x84D9
+ TEXTURE26 = 0x84DA
+ TEXTURE27 = 0x84DB
+ TEXTURE28 = 0x84DC
+ TEXTURE29 = 0x84DD
+ TEXTURE30 = 0x84DE
+ TEXTURE31 = 0x84DF
+ ACTIVE_TEXTURE = 0x84E0
+ CLIENT_ACTIVE_TEXTURE = 0x84E1
+ MAX_TEXTURE_UNITS = 0x84E2
+ TRANSPOSE_MODELVIEW_MATRIX = 0x84E3
+ TRANSPOSE_PROJECTION_MATRIX = 0x84E4
+ TRANSPOSE_TEXTURE_MATRIX = 0x84E5
+ TRANSPOSE_COLOR_MATRIX = 0x84E6
+ SUBTRACT = 0x84E7
+ MAX_RENDERBUFFER_SIZE = 0x84E8
+ COMPRESSED_ALPHA = 0x84E9
+ COMPRESSED_LUMINANCE = 0x84EA
+ COMPRESSED_LUMINANCE_ALPHA = 0x84EB
+ COMPRESSED_INTENSITY = 0x84EC
+ COMPRESSED_RGB = 0x84ED
+ COMPRESSED_RGBA = 0x84EE
+ TEXTURE_RECTANGLE = 0x84F5
+ TEXTURE_BINDING_RECTANGLE = 0x84F6
+ PROXY_TEXTURE_RECTANGLE = 0x84F7
+ MAX_RECTANGLE_TEXTURE_SIZE = 0x84F8
+ DEPTH_STENCIL = 0x84F9
+ UNSIGNED_INT_24_8 = 0x84FA
+ MAX_TEXTURE_LOD_BIAS = 0x84FD
+ TEXTURE_FILTER_CONTROL = 0x8500
+ TEXTURE_LOD_BIAS = 0x8501
+ INCR_WRAP = 0x8507
+ DECR_WRAP = 0x8508
+ NORMAL_MAP = 0x8511
+ REFLECTION_MAP = 0x8512
+ TEXTURE_CUBE_MAP = 0x8513
+ TEXTURE_BINDING_CUBE_MAP = 0x8514
+ TEXTURE_CUBE_MAP_POSITIVE_X = 0x8515
+ TEXTURE_CUBE_MAP_NEGATIVE_X = 0x8516
+ TEXTURE_CUBE_MAP_POSITIVE_Y = 0x8517
+ TEXTURE_CUBE_MAP_NEGATIVE_Y = 0x8518
+ TEXTURE_CUBE_MAP_POSITIVE_Z = 0x8519
+ TEXTURE_CUBE_MAP_NEGATIVE_Z = 0x851A
+ PROXY_TEXTURE_CUBE_MAP = 0x851B
+ MAX_CUBE_MAP_TEXTURE_SIZE = 0x851C
+ COMBINE = 0x8570
+ COMBINE_RGB = 0x8571
+ COMBINE_ALPHA = 0x8572
+ RGB_SCALE = 0x8573
+ ADD_SIGNED = 0x8574
+ INTERPOLATE = 0x8575
+ CONSTANT = 0x8576
+ PRIMARY_COLOR = 0x8577
+ PREVIOUS = 0x8578
+ SOURCE0_RGB = 0x8580
+ SRC0_RGB = 0x8580
+ SOURCE1_RGB = 0x8581
+ SRC1_RGB = 0x8581
+ SOURCE2_RGB = 0x8582
+ SRC2_RGB = 0x8582
+ SOURCE0_ALPHA = 0x8588
+ SRC0_ALPHA = 0x8588
+ SOURCE1_ALPHA = 0x8589
+ SRC1_ALPHA = 0x8589
+ SOURCE2_ALPHA = 0x858A
+ SRC2_ALPHA = 0x858A
+ OPERAND0_RGB = 0x8590
+ OPERAND1_RGB = 0x8591
+ OPERAND2_RGB = 0x8592
+ OPERAND0_ALPHA = 0x8598
+ OPERAND1_ALPHA = 0x8599
+ OPERAND2_ALPHA = 0x859A
+ VERTEX_ARRAY_BINDING = 0x85B5
+ VERTEX_ATTRIB_ARRAY_ENABLED = 0x8622
+ VERTEX_ATTRIB_ARRAY_SIZE = 0x8623
+ VERTEX_ATTRIB_ARRAY_STRIDE = 0x8624
+ VERTEX_ATTRIB_ARRAY_TYPE = 0x8625
+ CURRENT_VERTEX_ATTRIB = 0x8626
+ VERTEX_PROGRAM_POINT_SIZE = 0x8642
+ PROGRAM_POINT_SIZE = 0x8642
+ VERTEX_PROGRAM_TWO_SIDE = 0x8643
+ VERTEX_ATTRIB_ARRAY_POINTER = 0x8645
+ DEPTH_CLAMP = 0x864F
+ TEXTURE_COMPRESSED_IMAGE_SIZE = 0x86A0
+ TEXTURE_COMPRESSED = 0x86A1
+ NUM_COMPRESSED_TEXTURE_FORMATS = 0x86A2
+ COMPRESSED_TEXTURE_FORMATS = 0x86A3
+ DOT3_RGB = 0x86AE
+ DOT3_RGBA = 0x86AF
+ BUFFER_SIZE = 0x8764
+ BUFFER_USAGE = 0x8765
+ STENCIL_BACK_FUNC = 0x8800
+ STENCIL_BACK_FAIL = 0x8801
+ STENCIL_BACK_PASS_DEPTH_FAIL = 0x8802
+ STENCIL_BACK_PASS_DEPTH_PASS = 0x8803
+ RGBA32F = 0x8814
+ RGB32F = 0x8815
+ RGBA16F = 0x881A
+ RGB16F = 0x881B
+ MAX_DRAW_BUFFERS = 0x8824
+ DRAW_BUFFER0 = 0x8825
+ DRAW_BUFFER1 = 0x8826
+ DRAW_BUFFER2 = 0x8827
+ DRAW_BUFFER3 = 0x8828
+ DRAW_BUFFER4 = 0x8829
+ DRAW_BUFFER5 = 0x882A
+ DRAW_BUFFER6 = 0x882B
+ DRAW_BUFFER7 = 0x882C
+ DRAW_BUFFER8 = 0x882D
+ DRAW_BUFFER9 = 0x882E
+ DRAW_BUFFER10 = 0x882F
+ DRAW_BUFFER11 = 0x8830
+ DRAW_BUFFER12 = 0x8831
+ DRAW_BUFFER13 = 0x8832
+ DRAW_BUFFER14 = 0x8833
+ DRAW_BUFFER15 = 0x8834
+ BLEND_EQUATION_ALPHA = 0x883D
+ TEXTURE_DEPTH_SIZE = 0x884A
+ DEPTH_TEXTURE_MODE = 0x884B
+ TEXTURE_COMPARE_MODE = 0x884C
+ TEXTURE_COMPARE_FUNC = 0x884D
+ COMPARE_R_TO_TEXTURE = 0x884E
+ COMPARE_REF_TO_TEXTURE = 0x884E
+ TEXTURE_CUBE_MAP_SEAMLESS = 0x884F
+ POINT_SPRITE = 0x8861
+ COORD_REPLACE = 0x8862
+ QUERY_COUNTER_BITS = 0x8864
+ CURRENT_QUERY = 0x8865
+ QUERY_RESULT = 0x8866
+ QUERY_RESULT_AVAILABLE = 0x8867
+ MAX_VERTEX_ATTRIBS = 0x8869
+ VERTEX_ATTRIB_ARRAY_NORMALIZED = 0x886A
+ MAX_TEXTURE_COORDS = 0x8871
+ MAX_TEXTURE_IMAGE_UNITS = 0x8872
+ ARRAY_BUFFER = 0x8892
+ ELEMENT_ARRAY_BUFFER = 0x8893
+ ARRAY_BUFFER_BINDING = 0x8894
+ ELEMENT_ARRAY_BUFFER_BINDING = 0x8895
+ VERTEX_ARRAY_BUFFER_BINDING = 0x8896
+ NORMAL_ARRAY_BUFFER_BINDING = 0x8897
+ COLOR_ARRAY_BUFFER_BINDING = 0x8898
+ INDEX_ARRAY_BUFFER_BINDING = 0x8899
+ TEXTURE_COORD_ARRAY_BUFFER_BINDING = 0x889A
+ EDGE_FLAG_ARRAY_BUFFER_BINDING = 0x889B
+ SECONDARY_COLOR_ARRAY_BUFFER_BINDING = 0x889C
+ FOG_COORDINATE_ARRAY_BUFFER_BINDING = 0x889D
+ FOG_COORD_ARRAY_BUFFER_BINDING = 0x889D
+ WEIGHT_ARRAY_BUFFER_BINDING = 0x889E
+ VERTEX_ATTRIB_ARRAY_BUFFER_BINDING = 0x889F
+ READ_ONLY = 0x88B8
+ WRITE_ONLY = 0x88B9
+ READ_WRITE = 0x88BA
+ BUFFER_ACCESS = 0x88BB
+ BUFFER_MAPPED = 0x88BC
+ BUFFER_MAP_POINTER = 0x88BD
+ STREAM_DRAW = 0x88E0
+ STREAM_READ = 0x88E1
+ STREAM_COPY = 0x88E2
+ STATIC_DRAW = 0x88E4
+ STATIC_READ = 0x88E5
+ STATIC_COPY = 0x88E6
+ DYNAMIC_DRAW = 0x88E8
+ DYNAMIC_READ = 0x88E9
+ DYNAMIC_COPY = 0x88EA
+ PIXEL_PACK_BUFFER = 0x88EB
+ PIXEL_UNPACK_BUFFER = 0x88EC
+ PIXEL_PACK_BUFFER_BINDING = 0x88ED
+ PIXEL_UNPACK_BUFFER_BINDING = 0x88EF
+ DEPTH24_STENCIL8 = 0x88F0
+ TEXTURE_STENCIL_SIZE = 0x88F1
+ VERTEX_ATTRIB_ARRAY_INTEGER = 0x88FD
+ MAX_ARRAY_TEXTURE_LAYERS = 0x88FF
+ MIN_PROGRAM_TEXEL_OFFSET = 0x8904
+ MAX_PROGRAM_TEXEL_OFFSET = 0x8905
+ SAMPLES_PASSED = 0x8914
+ GEOMETRY_VERTICES_OUT = 0x8916
+ GEOMETRY_INPUT_TYPE = 0x8917
+ GEOMETRY_OUTPUT_TYPE = 0x8918
+ CLAMP_VERTEX_COLOR = 0x891A
+ CLAMP_FRAGMENT_COLOR = 0x891B
+ CLAMP_READ_COLOR = 0x891C
+ FIXED_ONLY = 0x891D
+ UNIFORM_BUFFER = 0x8A11
+ UNIFORM_BUFFER_BINDING = 0x8A28
+ UNIFORM_BUFFER_START = 0x8A29
+ UNIFORM_BUFFER_SIZE = 0x8A2A
+ MAX_VERTEX_UNIFORM_BLOCKS = 0x8A2B
+ MAX_GEOMETRY_UNIFORM_BLOCKS = 0x8A2C
+ MAX_FRAGMENT_UNIFORM_BLOCKS = 0x8A2D
+ MAX_COMBINED_UNIFORM_BLOCKS = 0x8A2E
+ MAX_UNIFORM_BUFFER_BINDINGS = 0x8A2F
+ MAX_UNIFORM_BLOCK_SIZE = 0x8A30
+ MAX_COMBINED_VERTEX_UNIFORM_COMPONENTS = 0x8A31
+ MAX_COMBINED_GEOMETRY_UNIFORM_COMPONENTS = 0x8A32
+ MAX_COMBINED_FRAGMENT_UNIFORM_COMPONENTS = 0x8A33
+ UNIFORM_BUFFER_OFFSET_ALIGNMENT = 0x8A34
+ ACTIVE_UNIFORM_BLOCK_MAX_NAME_LENGTH = 0x8A35
+ ACTIVE_UNIFORM_BLOCKS = 0x8A36
+ UNIFORM_TYPE = 0x8A37
+ UNIFORM_SIZE = 0x8A38
+ UNIFORM_NAME_LENGTH = 0x8A39
+ UNIFORM_BLOCK_INDEX = 0x8A3A
+ UNIFORM_OFFSET = 0x8A3B
+ UNIFORM_ARRAY_STRIDE = 0x8A3C
+ UNIFORM_MATRIX_STRIDE = 0x8A3D
+ UNIFORM_IS_ROW_MAJOR = 0x8A3E
+ UNIFORM_BLOCK_BINDING = 0x8A3F
+ UNIFORM_BLOCK_DATA_SIZE = 0x8A40
+ UNIFORM_BLOCK_NAME_LENGTH = 0x8A41
+ UNIFORM_BLOCK_ACTIVE_UNIFORMS = 0x8A42
+ UNIFORM_BLOCK_ACTIVE_UNIFORM_INDICES = 0x8A43
+ UNIFORM_BLOCK_REFERENCED_BY_VERTEX_SHADER = 0x8A44
+ UNIFORM_BLOCK_REFERENCED_BY_GEOMETRY_SHADER = 0x8A45
+ UNIFORM_BLOCK_REFERENCED_BY_FRAGMENT_SHADER = 0x8A46
+ FRAGMENT_SHADER = 0x8B30
+ VERTEX_SHADER = 0x8B31
+ MAX_FRAGMENT_UNIFORM_COMPONENTS = 0x8B49
+ MAX_VERTEX_UNIFORM_COMPONENTS = 0x8B4A
+ MAX_VARYING_FLOATS = 0x8B4B
+ MAX_VARYING_COMPONENTS = 0x8B4B
+ MAX_VERTEX_TEXTURE_IMAGE_UNITS = 0x8B4C
+ MAX_COMBINED_TEXTURE_IMAGE_UNITS = 0x8B4D
+ SHADER_TYPE = 0x8B4F
+ FLOAT_VEC2 = 0x8B50
+ FLOAT_VEC3 = 0x8B51
+ FLOAT_VEC4 = 0x8B52
+ INT_VEC2 = 0x8B53
+ INT_VEC3 = 0x8B54
+ INT_VEC4 = 0x8B55
+ BOOL = 0x8B56
+ BOOL_VEC2 = 0x8B57
+ BOOL_VEC3 = 0x8B58
+ BOOL_VEC4 = 0x8B59
+ FLOAT_MAT2 = 0x8B5A
+ FLOAT_MAT3 = 0x8B5B
+ FLOAT_MAT4 = 0x8B5C
+ SAMPLER_1D = 0x8B5D
+ SAMPLER_2D = 0x8B5E
+ SAMPLER_3D = 0x8B5F
+ SAMPLER_CUBE = 0x8B60
+ SAMPLER_1D_SHADOW = 0x8B61
+ SAMPLER_2D_SHADOW = 0x8B62
+ SAMPLER_2D_RECT = 0x8B63
+ SAMPLER_2D_RECT_SHADOW = 0x8B64
+ FLOAT_MAT2x3 = 0x8B65
+ FLOAT_MAT2x4 = 0x8B66
+ FLOAT_MAT3x2 = 0x8B67
+ FLOAT_MAT3x4 = 0x8B68
+ FLOAT_MAT4x2 = 0x8B69
+ FLOAT_MAT4x3 = 0x8B6A
+ DELETE_STATUS = 0x8B80
+ COMPILE_STATUS = 0x8B81
+ LINK_STATUS = 0x8B82
+ VALIDATE_STATUS = 0x8B83
+ INFO_LOG_LENGTH = 0x8B84
+ ATTACHED_SHADERS = 0x8B85
+ ACTIVE_UNIFORMS = 0x8B86
+ ACTIVE_UNIFORM_MAX_LENGTH = 0x8B87
+ SHADER_SOURCE_LENGTH = 0x8B88
+ ACTIVE_ATTRIBUTES = 0x8B89
+ ACTIVE_ATTRIBUTE_MAX_LENGTH = 0x8B8A
+ SHADING_LANGUAGE_VERSION = 0x8B8C
+ CURRENT_PROGRAM = 0x8B8D
+ TEXTURE_RED_TYPE = 0x8C10
+ TEXTURE_GREEN_TYPE = 0x8C11
+ TEXTURE_BLUE_TYPE = 0x8C12
+ TEXTURE_ALPHA_TYPE = 0x8C13
+ TEXTURE_LUMINANCE_TYPE = 0x8C14
+ TEXTURE_INTENSITY_TYPE = 0x8C15
+ TEXTURE_DEPTH_TYPE = 0x8C16
+ UNSIGNED_NORMALIZED = 0x8C17
+ TEXTURE_1D_ARRAY = 0x8C18
+ PROXY_TEXTURE_1D_ARRAY = 0x8C19
+ TEXTURE_2D_ARRAY = 0x8C1A
+ PROXY_TEXTURE_2D_ARRAY = 0x8C1B
+ TEXTURE_BINDING_1D_ARRAY = 0x8C1C
+ TEXTURE_BINDING_2D_ARRAY = 0x8C1D
+ MAX_GEOMETRY_TEXTURE_IMAGE_UNITS = 0x8C29
+ TEXTURE_BUFFER = 0x8C2A
+ MAX_TEXTURE_BUFFER_SIZE = 0x8C2B
+ TEXTURE_BINDING_BUFFER = 0x8C2C
+ TEXTURE_BUFFER_DATA_STORE_BINDING = 0x8C2D
+ R11F_G11F_B10F = 0x8C3A
+ UNSIGNED_INT_10F_11F_11F_REV = 0x8C3B
+ RGB9_E5 = 0x8C3D
+ UNSIGNED_INT_5_9_9_9_REV = 0x8C3E
+ TEXTURE_SHARED_SIZE = 0x8C3F
+ SRGB = 0x8C40
+ SRGB8 = 0x8C41
+ SRGB_ALPHA = 0x8C42
+ SRGB8_ALPHA8 = 0x8C43
+ SLUMINANCE_ALPHA = 0x8C44
+ SLUMINANCE8_ALPHA8 = 0x8C45
+ SLUMINANCE = 0x8C46
+ SLUMINANCE8 = 0x8C47
+ COMPRESSED_SRGB = 0x8C48
+ COMPRESSED_SRGB_ALPHA = 0x8C49
+ COMPRESSED_SLUMINANCE = 0x8C4A
+ COMPRESSED_SLUMINANCE_ALPHA = 0x8C4B
+ TRANSFORM_FEEDBACK_VARYING_MAX_LENGTH = 0x8C76
+ TRANSFORM_FEEDBACK_BUFFER_MODE = 0x8C7F
+ MAX_TRANSFORM_FEEDBACK_SEPARATE_COMPONENTS = 0x8C80
+ TRANSFORM_FEEDBACK_VARYINGS = 0x8C83
+ TRANSFORM_FEEDBACK_BUFFER_START = 0x8C84
+ TRANSFORM_FEEDBACK_BUFFER_SIZE = 0x8C85
+ PRIMITIVES_GENERATED = 0x8C87
+ TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN = 0x8C88
+ RASTERIZER_DISCARD = 0x8C89
+ MAX_TRANSFORM_FEEDBACK_INTERLEAVED_COMPONENTS = 0x8C8A
+ MAX_TRANSFORM_FEEDBACK_SEPARATE_ATTRIBS = 0x8C8B
+ INTERLEAVED_ATTRIBS = 0x8C8C
+ SEPARATE_ATTRIBS = 0x8C8D
+ TRANSFORM_FEEDBACK_BUFFER = 0x8C8E
+ TRANSFORM_FEEDBACK_BUFFER_BINDING = 0x8C8F
+ POINT_SPRITE_COORD_ORIGIN = 0x8CA0
+ LOWER_LEFT = 0x8CA1
+ UPPER_LEFT = 0x8CA2
+ STENCIL_BACK_REF = 0x8CA3
+ STENCIL_BACK_VALUE_MASK = 0x8CA4
+ STENCIL_BACK_WRITEMASK = 0x8CA5
+ DRAW_FRAMEBUFFER_BINDING = 0x8CA6
+ FRAMEBUFFER_BINDING = 0x8CA6
+ RENDERBUFFER_BINDING = 0x8CA7
+ READ_FRAMEBUFFER = 0x8CA8
+ DRAW_FRAMEBUFFER = 0x8CA9
+ READ_FRAMEBUFFER_BINDING = 0x8CAA
+ RENDERBUFFER_SAMPLES = 0x8CAB
+ DEPTH_COMPONENT32F = 0x8CAC
+ DEPTH32F_STENCIL8 = 0x8CAD
+ FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE = 0x8CD0
+ FRAMEBUFFER_ATTACHMENT_OBJECT_NAME = 0x8CD1
+ FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL = 0x8CD2
+ FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE = 0x8CD3
+ FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER = 0x8CD4
+ FRAMEBUFFER_COMPLETE = 0x8CD5
+ FRAMEBUFFER_INCOMPLETE_ATTACHMENT = 0x8CD6
+ FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT = 0x8CD7
+ FRAMEBUFFER_INCOMPLETE_DRAW_BUFFER = 0x8CDB
+ FRAMEBUFFER_INCOMPLETE_READ_BUFFER = 0x8CDC
+ FRAMEBUFFER_UNSUPPORTED = 0x8CDD
+ MAX_COLOR_ATTACHMENTS = 0x8CDF
+ COLOR_ATTACHMENT0 = 0x8CE0
+ COLOR_ATTACHMENT1 = 0x8CE1
+ COLOR_ATTACHMENT2 = 0x8CE2
+ COLOR_ATTACHMENT3 = 0x8CE3
+ COLOR_ATTACHMENT4 = 0x8CE4
+ COLOR_ATTACHMENT5 = 0x8CE5
+ COLOR_ATTACHMENT6 = 0x8CE6
+ COLOR_ATTACHMENT7 = 0x8CE7
+ COLOR_ATTACHMENT8 = 0x8CE8
+ COLOR_ATTACHMENT9 = 0x8CE9
+ COLOR_ATTACHMENT10 = 0x8CEA
+ COLOR_ATTACHMENT11 = 0x8CEB
+ COLOR_ATTACHMENT12 = 0x8CEC
+ COLOR_ATTACHMENT13 = 0x8CED
+ COLOR_ATTACHMENT14 = 0x8CEE
+ COLOR_ATTACHMENT15 = 0x8CEF
+ DEPTH_ATTACHMENT = 0x8D00
+ STENCIL_ATTACHMENT = 0x8D20
+ FRAMEBUFFER = 0x8D40
+ RENDERBUFFER = 0x8D41
+ RENDERBUFFER_WIDTH = 0x8D42
+ RENDERBUFFER_HEIGHT = 0x8D43
+ RENDERBUFFER_INTERNAL_FORMAT = 0x8D44
+ STENCIL_INDEX1 = 0x8D46
+ STENCIL_INDEX4 = 0x8D47
+ STENCIL_INDEX8 = 0x8D48
+ STENCIL_INDEX16 = 0x8D49
+ RENDERBUFFER_RED_SIZE = 0x8D50
+ RENDERBUFFER_GREEN_SIZE = 0x8D51
+ RENDERBUFFER_BLUE_SIZE = 0x8D52
+ RENDERBUFFER_ALPHA_SIZE = 0x8D53
+ RENDERBUFFER_DEPTH_SIZE = 0x8D54
+ RENDERBUFFER_STENCIL_SIZE = 0x8D55
+ FRAMEBUFFER_INCOMPLETE_MULTISAMPLE = 0x8D56
+ MAX_SAMPLES = 0x8D57
+ RGBA32UI = 0x8D70
+ RGB32UI = 0x8D71
+ RGBA16UI = 0x8D76
+ RGB16UI = 0x8D77
+ RGBA8UI = 0x8D7C
+ RGB8UI = 0x8D7D
+ RGBA32I = 0x8D82
+ RGB32I = 0x8D83
+ RGBA16I = 0x8D88
+ RGB16I = 0x8D89
+ RGBA8I = 0x8D8E
+ RGB8I = 0x8D8F
+ RED_INTEGER = 0x8D94
+ GREEN_INTEGER = 0x8D95
+ BLUE_INTEGER = 0x8D96
+ ALPHA_INTEGER = 0x8D97
+ RGB_INTEGER = 0x8D98
+ RGBA_INTEGER = 0x8D99
+ BGR_INTEGER = 0x8D9A
+ BGRA_INTEGER = 0x8D9B
+ FRAMEBUFFER_ATTACHMENT_LAYERED = 0x8DA7
+ FRAMEBUFFER_INCOMPLETE_LAYER_TARGETS = 0x8DA8
+ FLOAT_32_UNSIGNED_INT_24_8_REV = 0x8DAD
+ FRAMEBUFFER_SRGB = 0x8DB9
+ COMPRESSED_RED_RGTC1 = 0x8DBB
+ COMPRESSED_SIGNED_RED_RGTC1 = 0x8DBC
+ COMPRESSED_RG_RGTC2 = 0x8DBD
+ COMPRESSED_SIGNED_RG_RGTC2 = 0x8DBE
+ SAMPLER_1D_ARRAY = 0x8DC0
+ SAMPLER_2D_ARRAY = 0x8DC1
+ SAMPLER_BUFFER = 0x8DC2
+ SAMPLER_1D_ARRAY_SHADOW = 0x8DC3
+ SAMPLER_2D_ARRAY_SHADOW = 0x8DC4
+ SAMPLER_CUBE_SHADOW = 0x8DC5
+ UNSIGNED_INT_VEC2 = 0x8DC6
+ UNSIGNED_INT_VEC3 = 0x8DC7
+ UNSIGNED_INT_VEC4 = 0x8DC8
+ INT_SAMPLER_1D = 0x8DC9
+ INT_SAMPLER_2D = 0x8DCA
+ INT_SAMPLER_3D = 0x8DCB
+ INT_SAMPLER_CUBE = 0x8DCC
+ INT_SAMPLER_2D_RECT = 0x8DCD
+ INT_SAMPLER_1D_ARRAY = 0x8DCE
+ INT_SAMPLER_2D_ARRAY = 0x8DCF
+ INT_SAMPLER_BUFFER = 0x8DD0
+ UNSIGNED_INT_SAMPLER_1D = 0x8DD1
+ UNSIGNED_INT_SAMPLER_2D = 0x8DD2
+ UNSIGNED_INT_SAMPLER_3D = 0x8DD3
+ UNSIGNED_INT_SAMPLER_CUBE = 0x8DD4
+ UNSIGNED_INT_SAMPLER_2D_RECT = 0x8DD5
+ UNSIGNED_INT_SAMPLER_1D_ARRAY = 0x8DD6
+ UNSIGNED_INT_SAMPLER_2D_ARRAY = 0x8DD7
+ UNSIGNED_INT_SAMPLER_BUFFER = 0x8DD8
+ GEOMETRY_SHADER = 0x8DD9
+ MAX_GEOMETRY_UNIFORM_COMPONENTS = 0x8DDF
+ MAX_GEOMETRY_OUTPUT_VERTICES = 0x8DE0
+ MAX_GEOMETRY_TOTAL_OUTPUT_COMPONENTS = 0x8DE1
+ QUERY_WAIT = 0x8E13
+ QUERY_NO_WAIT = 0x8E14
+ QUERY_BY_REGION_WAIT = 0x8E15
+ QUERY_BY_REGION_NO_WAIT = 0x8E16
+ QUADS_FOLLOW_PROVOKING_VERTEX_CONVENTION = 0x8E4C
+ FIRST_VERTEX_CONVENTION = 0x8E4D
+ LAST_VERTEX_CONVENTION = 0x8E4E
+ PROVOKING_VERTEX = 0x8E4F
+ SAMPLE_POSITION = 0x8E50
+ SAMPLE_MASK = 0x8E51
+ SAMPLE_MASK_VALUE = 0x8E52
+ MAX_SAMPLE_MASK_WORDS = 0x8E59
+ COPY_READ_BUFFER = 0x8F36
+ COPY_WRITE_BUFFER = 0x8F37
+ R8_SNORM = 0x8F94
+ RG8_SNORM = 0x8F95
+ RGB8_SNORM = 0x8F96
+ RGBA8_SNORM = 0x8F97
+ R16_SNORM = 0x8F98
+ RG16_SNORM = 0x8F99
+ RGB16_SNORM = 0x8F9A
+ RGBA16_SNORM = 0x8F9B
+ SIGNED_NORMALIZED = 0x8F9C
+ PRIMITIVE_RESTART = 0x8F9D
+ PRIMITIVE_RESTART_INDEX = 0x8F9E
+ TEXTURE_2D_MULTISAMPLE = 0x9100
+ PROXY_TEXTURE_2D_MULTISAMPLE = 0x9101
+ TEXTURE_2D_MULTISAMPLE_ARRAY = 0x9102
+ PROXY_TEXTURE_2D_MULTISAMPLE_ARRAY = 0x9103
+ TEXTURE_BINDING_2D_MULTISAMPLE = 0x9104
+ TEXTURE_BINDING_2D_MULTISAMPLE_ARRAY = 0x9105
+ TEXTURE_SAMPLES = 0x9106
+ TEXTURE_FIXED_SAMPLE_LOCATIONS = 0x9107
+ SAMPLER_2D_MULTISAMPLE = 0x9108
+ INT_SAMPLER_2D_MULTISAMPLE = 0x9109
+ UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE = 0x910A
+ SAMPLER_2D_MULTISAMPLE_ARRAY = 0x910B
+ INT_SAMPLER_2D_MULTISAMPLE_ARRAY = 0x910C
+ UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE_ARRAY = 0x910D
+ MAX_COLOR_TEXTURE_SAMPLES = 0x910E
+ MAX_DEPTH_TEXTURE_SAMPLES = 0x910F
+ MAX_INTEGER_SAMPLES = 0x9110
+ MAX_SERVER_WAIT_TIMEOUT = 0x9111
+ OBJECT_TYPE = 0x9112
+ SYNC_CONDITION = 0x9113
+ SYNC_STATUS = 0x9114
+ SYNC_FLAGS = 0x9115
+ SYNC_FENCE = 0x9116
+ SYNC_GPU_COMMANDS_COMPLETE = 0x9117
+ UNSIGNALED = 0x9118
+ SIGNALED = 0x9119
+ ALREADY_SIGNALED = 0x911A
+ TIMEOUT_EXPIRED = 0x911B
+ CONDITION_SATISFIED = 0x911C
+ WAIT_FAILED = 0x911D
+ BUFFER_ACCESS_FLAGS = 0x911F
+ BUFFER_MAP_LENGTH = 0x9120
+ BUFFER_MAP_OFFSET = 0x9121
+ MAX_VERTEX_OUTPUT_COMPONENTS = 0x9122
+ MAX_GEOMETRY_INPUT_COMPONENTS = 0x9123
+ MAX_GEOMETRY_OUTPUT_COMPONENTS = 0x9124
+ MAX_FRAGMENT_INPUT_COMPONENTS = 0x9125
+ CONTEXT_PROFILE_MASK = 0x9126
+)
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glViewport.xml
+func (gl *GL) Viewport(x, y, width, height int) {
+ C.gl3_2compat_glViewport(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// DepthRange specifies the mapping of depth values from normalized device
+// coordinates to window coordinates.
+//
+// Parameter nearVal specifies the mapping of the near clipping plane to window
+// coordinates (defaults to 0), while farVal specifies the mapping of the far
+// clipping plane to window coordinates (defaults to 1).
+//
+// After clipping and division by w, depth coordinates range from -1 to 1,
+// corresponding to the near and far clipping planes. DepthRange specifies a
+// linear mapping of the normalized depth coordinates in this range to window
+// depth coordinates. Regardless of the actual depth buffer implementation,
+// window coordinate depth values are treated as though they range from 0 through 1
+// (like color components). Thus, the values accepted by DepthRange are both
+// clamped to this range before they are accepted.
+//
+// The default setting of (0, 1) maps the near plane to 0 and the far plane to 1.
+// With this mapping, the depth buffer range is fully utilized.
+//
+// It is not necessary that nearVal be less than farVal. Reverse mappings such as
+// nearVal 1, and farVal 0 are acceptable.
+//
+// GL.INVALID_OPERATION is generated if DepthRange is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) DepthRange(nearVal, farVal float64) {
+ C.gl3_2compat_glDepthRange(gl.funcs, C.GLdouble(nearVal), C.GLdouble(farVal))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsEnabled.xml
+func (gl *GL) IsEnabled(cap glbase.Enum) bool {
+ glresult := C.gl3_2compat_glIsEnabled(gl.funcs, C.GLenum(cap))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTexLevelParameteriv.xml
+func (gl *GL) GetTexLevelParameteriv(target glbase.Enum, level int, pname glbase.Enum, params []int32) {
+ C.gl3_2compat_glGetTexLevelParameteriv(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTexLevelParameterfv.xml
+func (gl *GL) GetTexLevelParameterfv(target glbase.Enum, level int, pname glbase.Enum, params []float32) {
+ C.gl3_2compat_glGetTexLevelParameterfv(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTexParameteriv.xml
+func (gl *GL) GetTexParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl3_2compat_glGetTexParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTexParameterfv.xml
+func (gl *GL) GetTexParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl3_2compat_glGetTexParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTexImage.xml
+func (gl *GL) GetTexImage(target glbase.Enum, level int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2compat_glGetTexImage(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetIntegerv.xml
+func (gl *GL) GetIntegerv(pname glbase.Enum, params []int32) {
+ C.gl3_2compat_glGetIntegerv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetFloatv.xml
+func (gl *GL) GetFloatv(pname glbase.Enum, params []float32) {
+ C.gl3_2compat_glGetFloatv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetError.xml
+func (gl *GL) GetError() glbase.Enum {
+ glresult := C.gl3_2compat_glGetError(gl.funcs)
+ return glbase.Enum(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetDoublev.xml
+func (gl *GL) GetDoublev(pname glbase.Enum, params []float64) {
+ C.gl3_2compat_glGetDoublev(gl.funcs, C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetBooleanv.xml
+func (gl *GL) GetBooleanv(pname glbase.Enum, params []bool) {
+ C.gl3_2compat_glGetBooleanv(gl.funcs, C.GLenum(pname), (*C.GLboolean)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glReadPixels.xml
+func (gl *GL) ReadPixels(x, y, width, height int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2compat_glReadPixels(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glReadBuffer.xml
+func (gl *GL) ReadBuffer(mode glbase.Enum) {
+ C.gl3_2compat_glReadBuffer(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPixelStorei.xml
+func (gl *GL) PixelStorei(pname glbase.Enum, param int32) {
+ C.gl3_2compat_glPixelStorei(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPixelStoref.xml
+func (gl *GL) PixelStoref(pname glbase.Enum, param float32) {
+ C.gl3_2compat_glPixelStoref(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDepthFunc.xml
+func (gl *GL) DepthFunc(glfunc glbase.Enum) {
+ C.gl3_2compat_glDepthFunc(gl.funcs, C.GLenum(glfunc))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glStencilOp.xml
+func (gl *GL) StencilOp(fail, zfail, zpass glbase.Enum) {
+ C.gl3_2compat_glStencilOp(gl.funcs, C.GLenum(fail), C.GLenum(zfail), C.GLenum(zpass))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glStencilFunc.xml
+func (gl *GL) StencilFunc(glfunc glbase.Enum, ref int32, mask uint32) {
+ C.gl3_2compat_glStencilFunc(gl.funcs, C.GLenum(glfunc), C.GLint(ref), C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glLogicOp.xml
+func (gl *GL) LogicOp(opcode glbase.Enum) {
+ C.gl3_2compat_glLogicOp(gl.funcs, C.GLenum(opcode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBlendFunc.xml
+func (gl *GL) BlendFunc(sfactor, dfactor glbase.Enum) {
+ C.gl3_2compat_glBlendFunc(gl.funcs, C.GLenum(sfactor), C.GLenum(dfactor))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFlush.xml
+func (gl *GL) Flush() {
+ C.gl3_2compat_glFlush(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFinish.xml
+func (gl *GL) Finish() {
+ C.gl3_2compat_glFinish(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEnable.xml
+func (gl *GL) Enable(cap glbase.Enum) {
+ C.gl3_2compat_glEnable(gl.funcs, C.GLenum(cap))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDisable.xml
+func (gl *GL) Disable(cap glbase.Enum) {
+ C.gl3_2compat_glDisable(gl.funcs, C.GLenum(cap))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDepthMask.xml
+func (gl *GL) DepthMask(flag bool) {
+ C.gl3_2compat_glDepthMask(gl.funcs, *(*C.GLboolean)(unsafe.Pointer(&flag)))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColorMask.xml
+func (gl *GL) ColorMask(red, green, blue, alpha bool) {
+ C.gl3_2compat_glColorMask(gl.funcs, *(*C.GLboolean)(unsafe.Pointer(&red)), *(*C.GLboolean)(unsafe.Pointer(&green)), *(*C.GLboolean)(unsafe.Pointer(&blue)), *(*C.GLboolean)(unsafe.Pointer(&alpha)))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glStencilMask.xml
+func (gl *GL) StencilMask(mask uint32) {
+ C.gl3_2compat_glStencilMask(gl.funcs, C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClearDepth.xml
+func (gl *GL) ClearDepth(depth float64) {
+ C.gl3_2compat_glClearDepth(gl.funcs, C.GLdouble(depth))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClearStencil.xml
+func (gl *GL) ClearStencil(s int32) {
+ C.gl3_2compat_glClearStencil(gl.funcs, C.GLint(s))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClearColor.xml
+func (gl *GL) ClearColor(red, green, blue, alpha float32) {
+ C.gl3_2compat_glClearColor(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClear.xml
+func (gl *GL) Clear(mask glbase.Bitfield) {
+ C.gl3_2compat_glClear(gl.funcs, C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDrawBuffer.xml
+func (gl *GL) DrawBuffer(mode glbase.Enum) {
+ C.gl3_2compat_glDrawBuffer(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexImage2D.xml
+func (gl *GL) TexImage2D(target glbase.Enum, level int, internalFormat int32, width, height, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2compat_glTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexImage1D.xml
+func (gl *GL) TexImage1D(target glbase.Enum, level int, internalFormat int32, width, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2compat_glTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexParameteriv.xml
+func (gl *GL) TexParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl3_2compat_glTexParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexParameteri.xml
+func (gl *GL) TexParameteri(target, pname glbase.Enum, param int32) {
+ C.gl3_2compat_glTexParameteri(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexParameterfv.xml
+func (gl *GL) TexParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl3_2compat_glTexParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexParameterf.xml
+func (gl *GL) TexParameterf(target, pname glbase.Enum, param float32) {
+ C.gl3_2compat_glTexParameterf(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glScissor.xml
+func (gl *GL) Scissor(x, y, width, height int) {
+ C.gl3_2compat_glScissor(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPolygonMode.xml
+func (gl *GL) PolygonMode(face, mode glbase.Enum) {
+ C.gl3_2compat_glPolygonMode(gl.funcs, C.GLenum(face), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPointSize.xml
+func (gl *GL) PointSize(size float32) {
+ C.gl3_2compat_glPointSize(gl.funcs, C.GLfloat(size))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glLineWidth.xml
+func (gl *GL) LineWidth(width float32) {
+ C.gl3_2compat_glLineWidth(gl.funcs, C.GLfloat(width))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glHint.xml
+func (gl *GL) Hint(target, mode glbase.Enum) {
+ C.gl3_2compat_glHint(gl.funcs, C.GLenum(target), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFrontFace.xml
+func (gl *GL) FrontFace(mode glbase.Enum) {
+ C.gl3_2compat_glFrontFace(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCullFace.xml
+func (gl *GL) CullFace(mode glbase.Enum) {
+ C.gl3_2compat_glCullFace(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIndexubv.xml
+func (gl *GL) Indexubv(c []uint8) {
+ C.gl3_2compat_glIndexubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIndexub.xml
+func (gl *GL) Indexub(c uint8) {
+ C.gl3_2compat_glIndexub(gl.funcs, C.GLubyte(c))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsTexture.xml
+func (gl *GL) IsTexture(texture glbase.Texture) bool {
+ glresult := C.gl3_2compat_glIsTexture(gl.funcs, C.GLuint(texture))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// GenTextures returns n texture names in textures. There is no guarantee
+// that the names form a contiguous set of integers; however, it is
+// guaranteed that none of the returned names was in use immediately before
+// the call to GenTextures.
+//
+// The generated textures have no dimensionality; they assume the
+// dimensionality of the texture target to which they are first bound (see
+// BindTexture).
+//
+// Texture names returned by a call to GenTextures are not returned by
+// subsequent calls, unless they are first deleted with DeleteTextures.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// GenTextures is available in GL version 2.0 or greater.
+func (gl *GL) GenTextures(n int) []glbase.Texture {
+ if n == 0 {
+ return nil
+ }
+ textures := make([]glbase.Texture, n)
+ C.gl3_2compat_glGenTextures(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])))
+ return textures
+}
+
+// DeleteTextures deletes the textures objects whose names are stored
+// in the textures slice. After a texture is deleted, it has no contents or
+// dimensionality, and its name is free for reuse (for example by
+// GenTextures). If a texture that is currently bound is deleted, the binding
+// reverts to 0 (the default texture).
+//
+// DeleteTextures silently ignores 0's and names that do not correspond to
+// existing textures.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// DeleteTextures is available in GL version 2.0 or greater.
+func (gl *GL) DeleteTextures(textures []glbase.Texture) {
+ n := len(textures)
+ if n == 0 {
+ return
+ }
+ C.gl3_2compat_glDeleteTextures(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBindTexture.xml
+func (gl *GL) BindTexture(target glbase.Enum, texture glbase.Texture) {
+ C.gl3_2compat_glBindTexture(gl.funcs, C.GLenum(target), C.GLuint(texture))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexSubImage2D.xml
+func (gl *GL) TexSubImage2D(target glbase.Enum, level, xoffset, yoffset, width, height int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2compat_glTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexSubImage1D.xml
+func (gl *GL) TexSubImage1D(target glbase.Enum, level, xoffset, width int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2compat_glTexSubImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLsizei(width), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCopyTexSubImage2D.xml
+func (gl *GL) CopyTexSubImage2D(target glbase.Enum, level, xoffset, yoffset, x, y, width, height int) {
+ C.gl3_2compat_glCopyTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCopyTexSubImage1D.xml
+func (gl *GL) CopyTexSubImage1D(target glbase.Enum, level, xoffset, x, y, width int) {
+ C.gl3_2compat_glCopyTexSubImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(x), C.GLint(y), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCopyTexImage2D.xml
+func (gl *GL) CopyTexImage2D(target glbase.Enum, level int, internalFormat glbase.Enum, x, y, width, height, border int) {
+ C.gl3_2compat_glCopyTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height), C.GLint(border))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCopyTexImage1D.xml
+func (gl *GL) CopyTexImage1D(target glbase.Enum, level int, internalFormat glbase.Enum, x, y, width, border int) {
+ C.gl3_2compat_glCopyTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLint(border))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPolygonOffset.xml
+func (gl *GL) PolygonOffset(factor, units float32) {
+ C.gl3_2compat_glPolygonOffset(gl.funcs, C.GLfloat(factor), C.GLfloat(units))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDrawElements.xml
+func (gl *GL) DrawElements(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2compat_glDrawElements(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDrawArrays.xml
+func (gl *GL) DrawArrays(mode glbase.Enum, first, count int) {
+ C.gl3_2compat_glDrawArrays(gl.funcs, C.GLenum(mode), C.GLint(first), C.GLsizei(count))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCopyTexSubImage3D.xml
+func (gl *GL) CopyTexSubImage3D(target glbase.Enum, level, xoffset, yoffset int, zoffset int32, x, y, width, height int) {
+ C.gl3_2compat_glCopyTexSubImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(zoffset), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexSubImage3D.xml
+func (gl *GL) TexSubImage3D(target glbase.Enum, level, xoffset, yoffset int, zoffset int32, width, height int, depth int32, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2compat_glTexSubImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(zoffset), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexImage3D.xml
+func (gl *GL) TexImage3D(target glbase.Enum, level int, internalFormat int32, width, height int, depth int32, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2compat_glTexImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDrawRangeElements.xml
+func (gl *GL) DrawRangeElements(mode glbase.Enum, start, end uint32, count int, gltype glbase.Enum, indices interface{}) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2compat_glDrawRangeElements(gl.funcs, C.GLenum(mode), C.GLuint(start), C.GLuint(end), C.GLsizei(count), C.GLenum(gltype), indices_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBlendEquation.xml
+func (gl *GL) BlendEquation(mode glbase.Enum) {
+ C.gl3_2compat_glBlendEquation(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBlendColor.xml
+func (gl *GL) BlendColor(red, green, blue, alpha float32) {
+ C.gl3_2compat_glBlendColor(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetCompressedTexImage.xml
+func (gl *GL) GetCompressedTexImage(target glbase.Enum, level int, img interface{}) {
+ var img_ptr unsafe.Pointer
+ var img_v = reflect.ValueOf(img)
+ if img != nil && img_v.Kind() != reflect.Slice {
+ panic("parameter img must be a slice")
+ }
+ if img != nil {
+ img_ptr = unsafe.Pointer(img_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2compat_glGetCompressedTexImage(gl.funcs, C.GLenum(target), C.GLint(level), img_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCompressedTexSubImage1D.xml
+func (gl *GL) CompressedTexSubImage1D(target glbase.Enum, level, xoffset, width int, format glbase.Enum, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2compat_glCompressedTexSubImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLsizei(width), C.GLenum(format), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCompressedTexSubImage2D.xml
+func (gl *GL) CompressedTexSubImage2D(target glbase.Enum, level, xoffset, yoffset, width, height int, format glbase.Enum, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2compat_glCompressedTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCompressedTexSubImage3D.xml
+func (gl *GL) CompressedTexSubImage3D(target glbase.Enum, level, xoffset, yoffset int, zoffset int32, width, height int, depth int32, format glbase.Enum, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2compat_glCompressedTexSubImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(zoffset), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLenum(format), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCompressedTexImage1D.xml
+func (gl *GL) CompressedTexImage1D(target glbase.Enum, level int, internalFormat glbase.Enum, width, border, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2compat_glCompressedTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLsizei(width), C.GLint(border), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCompressedTexImage2D.xml
+func (gl *GL) CompressedTexImage2D(target glbase.Enum, level int, internalFormat glbase.Enum, width, height, border, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2compat_glCompressedTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLint(border), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCompressedTexImage3D.xml
+func (gl *GL) CompressedTexImage3D(target glbase.Enum, level int, internalFormat glbase.Enum, width, height int, depth int32, border, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2compat_glCompressedTexImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLint(border), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSampleCoverage.xml
+func (gl *GL) SampleCoverage(value float32, invert bool) {
+ C.gl3_2compat_glSampleCoverage(gl.funcs, C.GLfloat(value), *(*C.GLboolean)(unsafe.Pointer(&invert)))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glActiveTexture.xml
+func (gl *GL) ActiveTexture(texture glbase.Enum) {
+ C.gl3_2compat_glActiveTexture(gl.funcs, C.GLenum(texture))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPointParameteriv.xml
+func (gl *GL) PointParameteriv(pname glbase.Enum, params []int32) {
+ C.gl3_2compat_glPointParameteriv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPointParameteri.xml
+func (gl *GL) PointParameteri(pname glbase.Enum, param int32) {
+ C.gl3_2compat_glPointParameteri(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPointParameterfv.xml
+func (gl *GL) PointParameterfv(pname glbase.Enum, params []float32) {
+ C.gl3_2compat_glPointParameterfv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPointParameterf.xml
+func (gl *GL) PointParameterf(pname glbase.Enum, param float32) {
+ C.gl3_2compat_glPointParameterf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiDrawArrays.xml
+func (gl *GL) MultiDrawArrays(mode glbase.Enum, first, count []int, drawcount int32) {
+ C.gl3_2compat_glMultiDrawArrays(gl.funcs, C.GLenum(mode), (*C.GLint)(unsafe.Pointer(&first[0])), (*C.GLsizei)(unsafe.Pointer(&count[0])), C.GLsizei(drawcount))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBlendFuncSeparate.xml
+func (gl *GL) BlendFuncSeparate(sfactorRGB, dfactorRGB, sfactorAlpha, dfactorAlpha glbase.Enum) {
+ C.gl3_2compat_glBlendFuncSeparate(gl.funcs, C.GLenum(sfactorRGB), C.GLenum(dfactorRGB), C.GLenum(sfactorAlpha), C.GLenum(dfactorAlpha))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetBufferParameteriv.xml
+func (gl *GL) GetBufferParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl3_2compat_glGetBufferParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glUnmapBuffer.xml
+func (gl *GL) UnmapBuffer(target glbase.Enum) bool {
+ glresult := C.gl3_2compat_glUnmapBuffer(gl.funcs, C.GLenum(target))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetBufferSubData.xml
+func (gl *GL) GetBufferSubData(target glbase.Enum, offset, size int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2compat_glGetBufferSubData(gl.funcs, C.GLenum(target), C.GLintptr(offset), C.GLsizeiptr(size), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBufferSubData.xml
+func (gl *GL) BufferSubData(target glbase.Enum, offset, size int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2compat_glBufferSubData(gl.funcs, C.GLenum(target), C.GLintptr(offset), C.GLsizeiptr(size), data_ptr)
+}
+
+// BufferData creates a new data store for the buffer object currently
+// bound to target. Any pre-existing data store is deleted. The new data
+// store is created with the specified size in bytes and usage. If data is
+// not nil, it must be a slice that is used to initialize the data store.
+// In that case the size parameter is ignored and the store size will match
+// the slice data size.
+//
+// In its initial state, the new data store is not mapped, it has a NULL
+// mapped pointer, and its mapped access is GL.READ_WRITE.
+//
+// The target constant must be one of GL.ARRAY_BUFFER, GL.COPY_READ_BUFFER,
+// GL.COPY_WRITE_BUFFER, GL.ELEMENT_ARRAY_BUFFER, GL.PIXEL_PACK_BUFFER,
+// GL.PIXEL_UNPACK_BUFFER, GL.TEXTURE_BUFFER, GL.TRANSFORM_FEEDBACK_BUFFER,
+// or GL.UNIFORM_BUFFER.
+//
+// The usage parameter is a hint to the GL implementation as to how a buffer
+// object's data store will be accessed. This enables the GL implementation
+// to make more intelligent decisions that may significantly impact buffer
+// object performance. It does not, however, constrain the actual usage of
+// the data store. usage can be broken down into two parts: first, the
+// frequency of access (modification and usage), and second, the nature of
+// that access.
+//
+// A usage frequency of STREAM and nature of DRAW is specified via the
+// constant GL.STREAM_DRAW, for example.
+//
+// The usage frequency of access may be one of:
+//
+// STREAM
+// The data store contents will be modified once and used at most a few times.
+//
+// STATIC
+// The data store contents will be modified once and used many times.
+//
+// DYNAMIC
+// The data store contents will be modified repeatedly and used many times.
+//
+// The usage nature of access may be one of:
+//
+// DRAW
+// The data store contents are modified by the application, and used as
+// the source for GL drawing and image specification commands.
+//
+// READ
+// The data store contents are modified by reading data from the GL,
+// and used to return that data when queried by the application.
+//
+// COPY
+// The data store contents are modified by reading data from the GL,
+// and used as the source for GL drawing and image specification
+// commands.
+//
+// Clients must align data elements consistent with the requirements of the
+// client platform, with an additional base-level requirement that an offset
+// within a buffer to a datum comprising N bytes be a multiple of N.
+//
+// Error GL.INVALID_ENUM is generated if target is not one of the accepted
+// buffer targets. GL.INVALID_ENUM is generated if usage is not
+// GL.STREAM_DRAW, GL.STREAM_READ, GL.STREAM_COPY, GL.STATIC_DRAW,
+// GL.STATIC_READ, GL.STATIC_COPY, GL.DYNAMIC_DRAW, GL.DYNAMIC_READ, or
+// GL.DYNAMIC_COPY. GL.INVALID_VALUE is generated if size is negative.
+// GL.INVALID_OPERATION is generated if the reserved buffer object name 0 is
+// bound to target. GL.OUT_OF_MEMORY is generated if the GL is unable to
+// create a data store with the specified size.
+func (gl *GL) BufferData(target glbase.Enum, size int, data interface{}, usage glbase.Enum) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ if data != nil {
+ size = int(data_v.Type().Size()) * data_v.Len()
+ }
+ C.gl3_2compat_glBufferData(gl.funcs, C.GLenum(target), C.GLsizeiptr(size), data_ptr, C.GLenum(usage))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsBuffer.xml
+func (gl *GL) IsBuffer(buffer glbase.Buffer) bool {
+ glresult := C.gl3_2compat_glIsBuffer(gl.funcs, C.GLuint(buffer))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// GenBuffers returns n buffer object names. There is no guarantee that
+// the names form a contiguous set of integers; however, it is guaranteed
+// that none of the returned names was in use immediately before the call to
+// GenBuffers.
+//
+// Buffer object names returned by a call to GenBuffers are not returned by
+// subsequent calls, unless they are first deleted with DeleteBuffers.
+//
+// No buffer objects are associated with the returned buffer object names
+// until they are first bound by calling BindBuffer.
+//
+// Error GL.INVALID_VALUE is generated if n is negative. GL.INVALID_OPERATION
+// is generated if GenBuffers is executed between the execution of Begin
+// and the corresponding execution of End.
+//
+// GenBuffers is available in GL version 1.5 or greater.
+func (gl *GL) GenBuffers(n int) []glbase.Buffer {
+ if n == 0 {
+ return nil
+ }
+ buffers := make([]glbase.Buffer, n)
+ C.gl3_2compat_glGenBuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&buffers[0])))
+ return buffers
+}
+
+// DeleteBuffers deletes the buffer objects whose names are stored in the
+// buffers slice.
+//
+// After a buffer object is deleted, it has no contents, and its name is free
+// for reuse (for example by GenBuffers). If a buffer object that is
+// currently bound is deleted, the binding reverts to 0 (the absence of any
+// buffer object, which reverts to client memory usage).
+//
+// DeleteBuffers silently ignores 0's and names that do not correspond to
+// existing buffer objects.
+//
+// Error GL.INVALID_VALUE is generated if n is negative. GL.INVALID_OPERATION
+// is generated if DeleteBuffers is executed between the execution of Begin
+// and the corresponding execution of End.
+//
+// DeleteBuffers is available in GL version 1.5 or greater.
+func (gl *GL) DeleteBuffers(buffers []glbase.Buffer) {
+ n := len(buffers)
+ if n == 0 {
+ return
+ }
+ C.gl3_2compat_glDeleteBuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&buffers[0])))
+}
+
+// BindBuffer creates or puts in use a named buffer object.
+// Calling BindBuffer with target set to GL.ARRAY_BUFFER,
+// GL.ELEMENT_ARRAY_BUFFER, GL.PIXEL_PACK_BUFFER or GL.PIXEL_UNPACK_BUFFER
+// and buffer set to the name of the new buffer object binds the buffer
+// object name to the target. When a buffer object is bound to a target, the
+// previous binding for that target is automatically broken.
+//
+// Buffer object names are unsigned integers. The value zero is reserved, but
+// there is no default buffer object for each buffer object target. Instead,
+// buffer set to zero effectively unbinds any buffer object previously bound,
+// and restores client memory usage for that buffer object target. Buffer
+// object names and the corresponding buffer object contents are local to the
+// shared display-list space (see XCreateContext) of the current GL rendering
+// context; two rendering contexts share buffer object names only if they
+// also share display lists.
+//
+// GenBuffers may be called to generate a set of new buffer object names.
+//
+// The state of a buffer object immediately after it is first bound is an
+// unmapped zero-sized memory buffer with GL.READ_WRITE access and
+// GL.STATIC_DRAW usage.
+//
+// While a non-zero buffer object name is bound, GL operations on the target
+// to which it is bound affect the bound buffer object, and queries of the
+// target to which it is bound return state from the bound buffer object.
+// While buffer object name zero is bound, as in the initial state, attempts
+// to modify or query state on the target to which it is bound generates an
+// GL.INVALID_OPERATION error.
+//
+// When vertex array pointer state is changed, for example by a call to
+// NormalPointer, the current buffer object binding (GL.ARRAY_BUFFER_BINDING)
+// is copied into the corresponding client state for the vertex array type
+// being changed, for example GL.NORMAL_ARRAY_BUFFER_BINDING. While a
+// non-zero buffer object is bound to the GL.ARRAY_BUFFER target, the vertex
+// array pointer parameter that is traditionally interpreted as a pointer to
+// client-side memory is instead interpreted as an offset within the buffer
+// object measured in basic machine units.
+//
+// While a non-zero buffer object is bound to the GL.ELEMENT_ARRAY_BUFFER
+// target, the indices parameter of DrawElements, DrawRangeElements, or
+// MultiDrawElements that is traditionally interpreted as a pointer to
+// client-side memory is instead interpreted as an offset within the buffer
+// object measured in basic machine units.
+//
+// While a non-zero buffer object is bound to the GL.PIXEL_PACK_BUFFER
+// target, the following commands are affected: GetCompressedTexImage,
+// GetConvolutionFilter, GetHistogram, GetMinmax, GetPixelMap,
+// GetPolygonStipple, GetSeparableFilter, GetTexImage, and ReadPixels. The
+// pointer parameter that is traditionally interpreted as a pointer to
+// client-side memory where the pixels are to be packed is instead
+// interpreted as an offset within the buffer object measured in basic
+// machine units.
+//
+// While a non-zero buffer object is bound to the GL.PIXEL_UNPACK_BUFFER
+// target, the following commands are affected: Bitmap, ColorSubTable,
+// ColorTable, CompressedTexImage1D, CompressedTexImage2D,
+// CompressedTexImage3D, CompressedTexSubImage1D, CompressedTexSubImage2D,
+// CompressedTexSubImage3D, ConvolutionFilter1D, ConvolutionFilter2D,
+// DrawPixels, PixelMap, PolygonStipple, SeparableFilter2D, TexImage1D,
+// TexImage2D, TexImage3D, TexSubImage1D, TexSubImage2D, and TexSubImage3D.
+// The pointer parameter that is traditionally interpreted as a pointer to
+// client-side memory from which the pixels are to be unpacked is instead
+// interpreted as an offset within the buffer object measured in basic
+// machine units.
+//
+// A buffer object binding created with BindBuffer remains active until a
+// different buffer object name is bound to the same target, or until the
+// bound buffer object is deleted with DeleteBuffers.
+//
+// Once created, a named buffer object may be re-bound to any target as often
+// as needed. However, the GL implementation may make choices about how to
+// optimize the storage of a buffer object based on its initial binding
+// target.
+//
+// Error GL.INVALID_ENUM is generated if target is not one of the allowable
+// values. GL.INVALID_OPERATION is generated if BindBuffer is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// BindBuffer is available in GL version 1.5 or greater.
+func (gl *GL) BindBuffer(target glbase.Enum, buffer glbase.Buffer) {
+ C.gl3_2compat_glBindBuffer(gl.funcs, C.GLenum(target), C.GLuint(buffer))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetQueryObjectuiv.xml
+func (gl *GL) GetQueryObjectuiv(id uint32, pname glbase.Enum, params []uint32) {
+ C.gl3_2compat_glGetQueryObjectuiv(gl.funcs, C.GLuint(id), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetQueryObjectiv.xml
+func (gl *GL) GetQueryObjectiv(id uint32, pname glbase.Enum, params []int32) {
+ C.gl3_2compat_glGetQueryObjectiv(gl.funcs, C.GLuint(id), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetQueryiv.xml
+func (gl *GL) GetQueryiv(target, pname glbase.Enum, params []int32) {
+ C.gl3_2compat_glGetQueryiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEndQuery.xml
+func (gl *GL) EndQuery(target glbase.Enum) {
+ C.gl3_2compat_glEndQuery(gl.funcs, C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBeginQuery.xml
+func (gl *GL) BeginQuery(target glbase.Enum, id uint32) {
+ C.gl3_2compat_glBeginQuery(gl.funcs, C.GLenum(target), C.GLuint(id))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsQuery.xml
+func (gl *GL) IsQuery(id uint32) bool {
+ glresult := C.gl3_2compat_glIsQuery(gl.funcs, C.GLuint(id))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDeleteQueries.xml
+func (gl *GL) DeleteQueries(n int, ids []uint32) {
+ C.gl3_2compat_glDeleteQueries(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&ids[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGenQueries.xml
+func (gl *GL) GenQueries(n int, ids []uint32) {
+ C.gl3_2compat_glGenQueries(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&ids[0])))
+}
+
+// VertexAttribPointer specifies the location and data format of the array
+// of generic vertex attributes at index to use when rendering. size
+// specifies the number of components per attribute and must be 1, 2, 3, or
+// 4. type specifies the data type of each component, and stride specifies
+// the byte stride from one attribute to the next, allowing vertices and
+// attributes to be packed into a single array or stored in separate arrays.
+// normalized indicates whether the values stored in an integer format are
+// to be mapped to the range [-1,1] (for signed values) or [0,1]
+// (for unsigned values) when they are accessed and converted to floating
+// point; otherwise, values will be converted to floats directly without
+// normalization. offset is a byte offset into the buffer object's data
+// store, which must be bound to the GL.ARRAY_BUFFER target with BindBuffer.
+//
+// The buffer object binding (GL.ARRAY_BUFFER_BINDING) is saved as
+// generic vertex attribute array client-side state
+// (GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING) for the provided index.
+//
+// To enable and disable a generic vertex attribute array, call
+// EnableVertexAttribArray and DisableVertexAttribArray with index. If
+// enabled, the generic vertex attribute array is used when DrawArrays or
+// DrawElements is called. Each generic vertex attribute array is initially
+// disabled.
+//
+// VertexAttribPointer is typically implemented on the client side.
+//
+// Error GL.INVALID_ENUM is generated if type is not an accepted value.
+// GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_VALUE is generated if size is not 1, 2,
+// 3, or 4. GL.INVALID_VALUE is generated if stride is negative.
+func (gl *GL) VertexAttribPointer(index glbase.Attrib, size int, gltype glbase.Enum, normalized bool, stride int, offset uintptr) {
+ offset_ptr := unsafe.Pointer(offset)
+ C.gl3_2compat_glVertexAttribPointer(gl.funcs, C.GLuint(index), C.GLint(size), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), C.GLsizei(stride), offset_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glValidateProgram.xml
+func (gl *GL) ValidateProgram(program glbase.Program) {
+ C.gl3_2compat_glValidateProgram(gl.funcs, C.GLuint(program))
+}
+
+// UniformMatrix4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix4fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(4*4) != 0 {
+ panic("invalid value length for UniformMatrix4fv")
+ }
+ count := len(value) / (4 * 4)
+ C.gl3_2compat_glUniformMatrix4fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix3fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(3*3) != 0 {
+ panic("invalid value length for UniformMatrix3fv")
+ }
+ count := len(value) / (3 * 3)
+ C.gl3_2compat_glUniformMatrix3fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix2fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(2*2) != 0 {
+ panic("invalid value length for UniformMatrix2fv")
+ }
+ count := len(value) / (2 * 2)
+ C.gl3_2compat_glUniformMatrix2fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform4iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%4 != 0 {
+ panic("invalid value length for Uniform4iv")
+ }
+ count := len(value) / 4
+ C.gl3_2compat_glUniform4iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform3iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform3iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%3 != 0 {
+ panic("invalid value length for Uniform3iv")
+ }
+ count := len(value) / 3
+ C.gl3_2compat_glUniform3iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform2iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform2iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%2 != 0 {
+ panic("invalid value length for Uniform2iv")
+ }
+ count := len(value) / 2
+ C.gl3_2compat_glUniform2iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform1iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform1iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ count := len(value)
+ C.gl3_2compat_glUniform1iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%4 != 0 {
+ panic("invalid value length for Uniform4fv")
+ }
+ count := len(value) / 4
+ C.gl3_2compat_glUniform4fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%3 != 0 {
+ panic("invalid value length for Uniform3fv")
+ }
+ count := len(value) / 3
+ C.gl3_2compat_glUniform3fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%2 != 0 {
+ panic("invalid value length for Uniform2fv")
+ }
+ count := len(value) / 2
+ C.gl3_2compat_glUniform2fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform1fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform1fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ count := len(value)
+ C.gl3_2compat_glUniform1fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform4i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4i(location glbase.Uniform, v0, v1, v2, v3 int32) {
+ C.gl3_2compat_glUniform4i(gl.funcs, C.GLint(location), C.GLint(v0), C.GLint(v1), C.GLint(v2), C.GLint(v3))
+}
+
+// Uniform3i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform3i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3i(location glbase.Uniform, v0, v1, v2 int32) {
+ C.gl3_2compat_glUniform3i(gl.funcs, C.GLint(location), C.GLint(v0), C.GLint(v1), C.GLint(v2))
+}
+
+// Uniform2i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform2i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2i(location glbase.Uniform, v0, v1 int32) {
+ C.gl3_2compat_glUniform2i(gl.funcs, C.GLint(location), C.GLint(v0), C.GLint(v1))
+}
+
+// Uniform1i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform1i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1i(location glbase.Uniform, v0 int32) {
+ C.gl3_2compat_glUniform1i(gl.funcs, C.GLint(location), C.GLint(v0))
+}
+
+// Uniform4f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform4f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4f(location glbase.Uniform, v0, v1, v2, v3 float32) {
+ C.gl3_2compat_glUniform4f(gl.funcs, C.GLint(location), C.GLfloat(v0), C.GLfloat(v1), C.GLfloat(v2), C.GLfloat(v3))
+}
+
+// Uniform3f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform3f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3f(location glbase.Uniform, v0, v1, v2 float32) {
+ C.gl3_2compat_glUniform3f(gl.funcs, C.GLint(location), C.GLfloat(v0), C.GLfloat(v1), C.GLfloat(v2))
+}
+
+// Uniform2f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform2f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2f(location glbase.Uniform, v0, v1 float32) {
+ C.gl3_2compat_glUniform2f(gl.funcs, C.GLint(location), C.GLfloat(v0), C.GLfloat(v1))
+}
+
+// Uniform1f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform1f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1f(location glbase.Uniform, v0 float32) {
+ C.gl3_2compat_glUniform1f(gl.funcs, C.GLint(location), C.GLfloat(v0))
+}
+
+// UseProgram installs the program object specified by program as part of
+// current rendering state. One or more executables are created in a program
+// object by successfully attaching shader objects to it with AttachShader,
+// successfully compiling the shader objects with CompileShader, and
+// successfully linking the program object with LinkProgram.
+//
+// A program object will contain an executable that will run on the vertex
+// processor if it contains one or more shader objects of type
+// GL.VERTEX_SHADER that have been successfully compiled and linked.
+// Similarly, a program object will contain an executable that will run on
+// the fragment processor if it contains one or more shader objects of type
+// GL.FRAGMENT_SHADER that have been successfully compiled and linked.
+//
+// Successfully installing an executable on a programmable processor will
+// cause the corresponding fixed functionality of OpenGL to be disabled.
+// Specifically, if an executable is installed on the vertex processor, the
+// OpenGL fixed functionality will be disabled as follows.
+//
+// - The modelview matrix is not applied to vertex coordinates.
+//
+// - The projection matrix is not applied to vertex coordinates.
+//
+// - The texture matrices are not applied to texture coordinates.
+//
+// - Normals are not transformed to eye coordinates.
+//
+// - Normals are not rescaled or normalized.
+//
+// - Normalization of GL.AUTO_NORMAL evaluated normals is not performed.
+//
+// - Texture coordinates are not generated automatically.
+//
+// - Per-vertex lighting is not performed.
+//
+// - Color material computations are not performed.
+//
+// - Color index lighting is not performed.
+//
+// - This list also applies when setting the current raster position.
+//
+// The executable that is installed on the vertex processor is expected to
+// implement any or all of the desired functionality from the preceding list.
+// Similarly, if an executable is installed on the fragment processor, the
+// OpenGL fixed functionality will be disabled as follows.
+//
+// - Texture environment and texture functions are not applied.
+//
+// - Texture application is not applied.
+//
+// - Color sum is not applied.
+//
+// - Fog is not applied.
+//
+// Again, the fragment shader that is installed is expected to implement any
+// or all of the desired functionality from the preceding list.
+//
+// While a program object is in use, applications are free to modify attached
+// shader objects, compile attached shader objects, attach additional shader
+// objects, and detach or delete shader objects. None of these operations
+// will affect the executables that are part of the current state. However,
+// relinking the program object that is currently in use will install the
+// program object as part of the current rendering state if the link
+// operation was successful (see LinkProgram). If the program object
+// currently in use is relinked unsuccessfully, its link status will be set
+// to GL.FALSE, but the executables and associated state will remain part of
+// the current state until a subsequent call to UseProgram removes it from
+// use. After it is removed from use, it cannot be made part of current state
+// until it has been successfully relinked.
+//
+// If program contains shader objects of type GL.VERTEX_SHADER but it does
+// not contain shader objects of type GL.FRAGMENT_SHADER, an executable will
+// be installed on the vertex processor, but fixed functionality will be used
+// for fragment processing. Similarly, if program contains shader objects of
+// type GL.FRAGMENT_SHADER but it does not contain shader objects of type
+// GL.VERTEX_SHADER, an executable will be installed on the fragment
+// processor, but fixed functionality will be used for vertex processing. If
+// program is 0, the programmable processors will be disabled, and fixed
+// functionality will be used for both vertex and fragment processing.
+//
+// While a program object is in use, the state that controls the disabled
+// fixed functionality may also be updated using the normal OpenGL calls.
+//
+// Like display lists and texture objects, the name space for program objects
+// may be shared across a set of contexts, as long as the server sides of the
+// contexts share the same address space. If the name space is shared across
+// contexts, any attached objects and the data associated with those attached
+// objects are shared as well.
+//
+// Applications are responsible for providing the synchronization across API
+// calls when objects are accessed from different execution threads.
+//
+// Error GL.INVALID_VALUE is generated if program is neither 0 nor a value
+// generated by OpenGL. GL.INVALID_OPERATION is generated if program is not
+// a program object. GL.INVALID_OPERATION is generated if program could not
+// be made part of current state. GL.INVALID_OPERATION is generated if
+// UseProgram is executed between the execution of Begin and the
+// corresponding execution of End.
+//
+// UseProgram is available in GL version 2.0 or greater.
+func (gl *GL) UseProgram(program glbase.Program) {
+ C.gl3_2compat_glUseProgram(gl.funcs, C.GLuint(program))
+}
+
+// ShaderSource sets the source code in shader to the provided source code. Any source
+// code previously stored in the shader object is completely replaced.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader is not a shader
+// object. GL.INVALID_VALUE is generated if count is less than 0.
+// GL.INVALID_OPERATION is generated if ShaderSource is executed between the
+// execution of Begin and the corresponding execution of End.
+//
+// ShaderSource is available in GL version 2.0 or greater.
+func (gl *GL) ShaderSource(shader glbase.Shader, source ...string) {
+ count := len(source)
+ length := make([]int32, count)
+ source_c := make([]unsafe.Pointer, count)
+ for i, src := range source {
+ length[i] = int32(len(src))
+ if len(src) > 0 {
+ source_c[i] = *(*unsafe.Pointer)(unsafe.Pointer(&src))
+ } else {
+ source_c[i] = unsafe.Pointer(uintptr(0))
+ }
+ }
+ C.gl3_2compat_glShaderSource(gl.funcs, C.GLuint(shader), C.GLsizei(count), (**C.GLchar)(unsafe.Pointer(&source_c[0])), (*C.GLint)(unsafe.Pointer(&length[0])))
+}
+
+// LinkProgram links the program object specified by program. If any shader
+// objects of type GL.VERTEX_SHADER are attached to program, they will be
+// used to create an executable that will run on the programmable vertex
+// processor. If any shader objects of type GL.FRAGMENT_SHADER are attached
+// to program, they will be used to create an executable that will run on the
+// programmable fragment processor.
+//
+// The status of the link operation will be stored as part of the program
+// object's state. This value will be set to GL.TRUE if the program object
+// was linked without errors and is ready for use, and GL.FALSE otherwise. It
+// can be queried by calling GetProgramiv with arguments program and
+// GL.LINK_STATUS.
+//
+// As a result of a successful link operation, all active user-defined
+// uniform variables belonging to program will be initialized to 0, and each
+// of the program object's active uniform variables will be assigned a
+// location that can be queried by calling GetUniformLocation. Also, any
+// active user-defined attribute variables that have not been bound to a
+// generic vertex attribute index will be bound to one at this time.
+//
+// Linking of a program object can fail for a number of reasons as specified
+// in the OpenGL Shading Language Specification. The following lists some of
+// the conditions that will cause a link error.
+//
+// - The number of active attribute variables supported by the
+// implementation has been exceeded.
+//
+// - The storage limit for uniform variables has been exceeded.
+//
+// - The number of active uniform variables supported by the implementation
+// has been exceeded.
+//
+// - The main function is missing for the vertex shader or the fragment
+// shader.
+//
+// - A varying variable actually used in the fragment shader is not
+// declared in the same way (or is not declared at all) in the vertex
+// shader.
+//
+// - A reference to a function or variable name is unresolved.
+//
+// - A shared global is declared with two different types or two different
+// initial values.
+//
+// - One or more of the attached shader objects has not been successfully
+// compiled.
+//
+// - Binding a generic attribute matrix caused some rows of the matrix to
+// fall outside the allowed maximum of GL.MAX_VERTEX_ATTRIBS.
+//
+// - Not enough contiguous vertex attribute slots could be found to bind
+// attribute matrices.
+//
+// When a program object has been successfully linked, the program object can
+// be made part of current state by calling UseProgram. Whether or not the
+// link operation was successful, the program object's information log will
+// be overwritten. The information log can be retrieved by calling
+// GetProgramInfoLog.
+//
+// LinkProgram will also install the generated executables as part of the
+// current rendering state if the link operation was successful and the
+// specified program object is already currently in use as a result of a
+// previous call to UseProgram. If the program object currently in use is
+// relinked unsuccessfully, its link status will be set to GL.FALSE , but the
+// executables and associated state will remain part of the current state
+// until a subsequent call to UseProgram removes it from use. After it is
+// removed from use, it cannot be made part of current state until it has
+// been successfully relinked.
+//
+// If program contains shader objects of type GL.VERTEX_SHADER but does not
+// contain shader objects of type GL.FRAGMENT_SHADER, the vertex shader will
+// be linked against the implicit interface for fixed functionality fragment
+// processing. Similarly, if program contains shader objects of type
+// GL.FRAGMENT_SHADER but it does not contain shader objects of type
+// GL.VERTEX_SHADER, the fragment shader will be linked against the implicit
+// interface for fixed functionality vertex processing.
+//
+// The program object's information log is updated and the program is
+// generated at the time of the link operation. After the link operation,
+// applications are free to modify attached shader objects, compile attached
+// shader objects, detach shader objects, delete shader objects, and attach
+// additional shader objects. None of these operations affects the
+// information log or the program that is part of the program object.
+//
+// If the link operation is unsuccessful, any information about a previous
+// link operation on program is lost (a failed link does not restore the
+// old state of program). Certain information can still be retrieved
+// from program even after an unsuccessful link operation. See for instance
+// GetActiveAttrib and GetActiveUniform.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program
+// object. GL.INVALID_OPERATION is generated if LinkProgram is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// LinkProgram is available in GL version 2.0 or greater.
+func (gl *GL) LinkProgram(program glbase.Program) {
+ C.gl3_2compat_glLinkProgram(gl.funcs, C.GLuint(program))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsShader.xml
+func (gl *GL) IsShader(shader glbase.Shader) bool {
+ glresult := C.gl3_2compat_glIsShader(gl.funcs, C.GLuint(shader))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsProgram.xml
+func (gl *GL) IsProgram(program glbase.Program) bool {
+ glresult := C.gl3_2compat_glIsProgram(gl.funcs, C.GLuint(program))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// GetVertexAttribiv returns in params the value of a generic vertex attribute
+// parameter. The generic vertex attribute to be queried is specified by
+// index, and the parameter to be queried is specified by pname.
+//
+// The accepted parameter names are as follows:
+//
+// GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING
+// params returns a single value, the name of the buffer object
+// currently bound to the binding point corresponding to generic vertex
+// attribute array index. If no buffer object is bound, 0 is returned.
+// The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_ENABLED
+// params returns a single value that is non-zero (true) if the vertex
+// attribute array for index is enabled and 0 (false) if it is
+// disabled. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_SIZE
+// params returns a single value, the size of the vertex attribute
+// array for index. The size is the number of values for each element
+// of the vertex attribute array, and it will be 1, 2, 3, or 4. The
+// initial value is 4.
+//
+// GL.VERTEX_ATTRIB_ARRAY_STRIDE
+// params returns a single value, the array stride for (number of bytes
+// between successive elements in) the vertex attribute array for
+// index. A value of 0 indicates that the array elements are stored
+// sequentially in memory. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_TYPE
+// params returns a single value, a symbolic constant indicating the
+// array type for the vertex attribute array for index. Possible values
+// are GL.BYTE, GL.UNSIGNED_BYTE, GL.SHORT, GL.UNSIGNED_SHORT, GL.INT,
+// GL.UNSIGNED_INT, GL.FLOAT, and GL.DOUBLE. The initial value is
+// GL.FLOAT.
+//
+// GL.VERTEX_ATTRIB_ARRAY_NORMALIZED
+// params returns a single value that is non-zero (true) if fixed-point
+// data types for the vertex attribute array indicated by index are
+// normalized when they are converted to floating point, and 0 (false)
+// otherwise. The initial value is 0.
+//
+// GL.CURRENT_VERTEX_ATTRIB
+// params returns four values that represent the current value for the
+// generic vertex attribute specified by index. Generic vertex
+// attribute 0 is unique in that it has no current state, so an error
+// will be generated if index is 0. The initial value for all other
+// generic vertex attributes is (0,0,0,1).
+//
+// All of the parameters except GL.CURRENT_VERTEX_ATTRIB represent
+// client-side state.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_ENUM is generated if pname is not an
+// accepted value. GL.INVALID_OPERATION is generated if index is 0 and pname
+// is GL.CURRENT_VERTEX_ATTRIB.
+//
+// GetVertexAttribiv is available in GL version 2.0 or greater.
+func (gl *GL) GetVertexAttribiv(index glbase.Attrib, pname glbase.Enum, params []int32) {
+ var params_c [4]int32
+ C.gl3_2compat_glGetVertexAttribiv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetVertexAttribfv returns in params the value of a generic vertex attribute
+// parameter. The generic vertex attribute to be queried is specified by
+// index, and the parameter to be queried is specified by pname.
+//
+// The accepted parameter names are as follows:
+//
+// GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING
+// params returns a single value, the name of the buffer object
+// currently bound to the binding point corresponding to generic vertex
+// attribute array index. If no buffer object is bound, 0 is returned.
+// The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_ENABLED
+// params returns a single value that is non-zero (true) if the vertex
+// attribute array for index is enabled and 0 (false) if it is
+// disabled. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_SIZE
+// params returns a single value, the size of the vertex attribute
+// array for index. The size is the number of values for each element
+// of the vertex attribute array, and it will be 1, 2, 3, or 4. The
+// initial value is 4.
+//
+// GL.VERTEX_ATTRIB_ARRAY_STRIDE
+// params returns a single value, the array stride for (number of bytes
+// between successive elements in) the vertex attribute array for
+// index. A value of 0 indicates that the array elements are stored
+// sequentially in memory. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_TYPE
+// params returns a single value, a symbolic constant indicating the
+// array type for the vertex attribute array for index. Possible values
+// are GL.BYTE, GL.UNSIGNED_BYTE, GL.SHORT, GL.UNSIGNED_SHORT, GL.INT,
+// GL.UNSIGNED_INT, GL.FLOAT, and GL.DOUBLE. The initial value is
+// GL.FLOAT.
+//
+// GL.VERTEX_ATTRIB_ARRAY_NORMALIZED
+// params returns a single value that is non-zero (true) if fixed-point
+// data types for the vertex attribute array indicated by index are
+// normalized when they are converted to floating point, and 0 (false)
+// otherwise. The initial value is 0.
+//
+// GL.CURRENT_VERTEX_ATTRIB
+// params returns four values that represent the current value for the
+// generic vertex attribute specified by index. Generic vertex
+// attribute 0 is unique in that it has no current state, so an error
+// will be generated if index is 0. The initial value for all other
+// generic vertex attributes is (0,0,0,1).
+//
+// All of the parameters except GL.CURRENT_VERTEX_ATTRIB represent
+// client-side state.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_ENUM is generated if pname is not an
+// accepted value. GL.INVALID_OPERATION is generated if index is 0 and pname
+// is GL.CURRENT_VERTEX_ATTRIB.
+//
+// GetVertexAttribfv is available in GL version 2.0 or greater.
+func (gl *GL) GetVertexAttribfv(index glbase.Attrib, pname glbase.Enum, params []float32) {
+ var params_c [4]float32
+ C.gl3_2compat_glGetVertexAttribfv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetVertexAttribdv returns in params the value of a generic vertex attribute
+// parameter. The generic vertex attribute to be queried is specified by
+// index, and the parameter to be queried is specified by pname.
+//
+// The accepted parameter names are as follows:
+//
+// GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING
+// params returns a single value, the name of the buffer object
+// currently bound to the binding point corresponding to generic vertex
+// attribute array index. If no buffer object is bound, 0 is returned.
+// The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_ENABLED
+// params returns a single value that is non-zero (true) if the vertex
+// attribute array for index is enabled and 0 (false) if it is
+// disabled. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_SIZE
+// params returns a single value, the size of the vertex attribute
+// array for index. The size is the number of values for each element
+// of the vertex attribute array, and it will be 1, 2, 3, or 4. The
+// initial value is 4.
+//
+// GL.VERTEX_ATTRIB_ARRAY_STRIDE
+// params returns a single value, the array stride for (number of bytes
+// between successive elements in) the vertex attribute array for
+// index. A value of 0 indicates that the array elements are stored
+// sequentially in memory. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_TYPE
+// params returns a single value, a symbolic constant indicating the
+// array type for the vertex attribute array for index. Possible values
+// are GL.BYTE, GL.UNSIGNED_BYTE, GL.SHORT, GL.UNSIGNED_SHORT, GL.INT,
+// GL.UNSIGNED_INT, GL.FLOAT, and GL.DOUBLE. The initial value is
+// GL.FLOAT.
+//
+// GL.VERTEX_ATTRIB_ARRAY_NORMALIZED
+// params returns a single value that is non-zero (true) if fixed-point
+// data types for the vertex attribute array indicated by index are
+// normalized when they are converted to floating point, and 0 (false)
+// otherwise. The initial value is 0.
+//
+// GL.CURRENT_VERTEX_ATTRIB
+// params returns four values that represent the current value for the
+// generic vertex attribute specified by index. Generic vertex
+// attribute 0 is unique in that it has no current state, so an error
+// will be generated if index is 0. The initial value for all other
+// generic vertex attributes is (0,0,0,1).
+//
+// All of the parameters except GL.CURRENT_VERTEX_ATTRIB represent
+// client-side state.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_ENUM is generated if pname is not an
+// accepted value. GL.INVALID_OPERATION is generated if index is 0 and pname
+// is GL.CURRENT_VERTEX_ATTRIB.
+//
+// GetVertexAttribdv is available in GL version 2.0 or greater.
+func (gl *GL) GetVertexAttribdv(index glbase.Attrib, pname glbase.Enum, params []float64) {
+ var params_c [4]float64
+ C.gl3_2compat_glGetVertexAttribdv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetUniformiv returns in params the value of the specified uniform
+// variable. The type of the uniform variable specified by location
+// determines the number of values returned. If the uniform variable is
+// defined in the shader as a boolean, int, or float, a single value will be
+// returned. If it is defined as a vec2, ivec2, or bvec2, two values will be
+// returned. If it is defined as a vec3, ivec3, or bvec3, three values will
+// be returned, and so on. To query values stored in uniform variables
+// declared as arrays, call GetUniformiv for each element of the array. To
+// query values stored in uniform variables declared as structures, call
+// GetUniformiv for each field in the structure. The values for uniform
+// variables declared as a matrix will be returned in column major order.
+//
+// The locations assigned to uniform variables are not known until the
+// program object is linked. After linking has occurred, the command
+// GetUniformLocation can be used to obtain the location of a uniform
+// variable. This location value can then be passed to GetUniformiv in order
+// to query the current value of the uniform variable. After a program object
+// has been linked successfully, the index values for uniform variables
+// remain fixed until the next link command occurs. The uniform variable
+// values can only be queried after a link if the link was successful.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program
+// object. GL.INVALID_OPERATION is generated if program has not been
+// successfully linked. GL.INVALID_OPERATION is generated if location does
+// not correspond to a valid uniform variable location for the specified
+// program object. GL.INVALID_OPERATION is generated if GetUniformiv is
+// executed between the execution of Begin and the corresponding execution of
+// End.
+//
+// GetUniformiv is available in GL version 2.0 or greater.
+func (gl *GL) GetUniformiv(program glbase.Program, location glbase.Uniform, params []int32) {
+ var params_c [4]int32
+ C.gl3_2compat_glGetUniformiv(gl.funcs, C.GLuint(program), C.GLint(location), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetUniformfv returns in params the value of the specified uniform
+// variable. The type of the uniform variable specified by location
+// determines the number of values returned. If the uniform variable is
+// defined in the shader as a boolean, int, or float, a single value will be
+// returned. If it is defined as a vec2, ivec2, or bvec2, two values will be
+// returned. If it is defined as a vec3, ivec3, or bvec3, three values will
+// be returned, and so on. To query values stored in uniform variables
+// declared as arrays, call GetUniformfv for each element of the array. To
+// query values stored in uniform variables declared as structures, call
+// GetUniformfv for each field in the structure. The values for uniform
+// variables declared as a matrix will be returned in column major order.
+//
+// The locations assigned to uniform variables are not known until the
+// program object is linked. After linking has occurred, the command
+// GetUniformLocation can be used to obtain the location of a uniform
+// variable. This location value can then be passed to GetUniformfv in order
+// to query the current value of the uniform variable. After a program object
+// has been linked successfully, the index values for uniform variables
+// remain fixed until the next link command occurs. The uniform variable
+// values can only be queried after a link if the link was successful.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program
+// object. GL.INVALID_OPERATION is generated if program has not been
+// successfully linked. GL.INVALID_OPERATION is generated if location does
+// not correspond to a valid uniform variable location for the specified
+// program object. GL.INVALID_OPERATION is generated if GetUniformfv is
+// executed between the execution of Begin and the corresponding execution of
+// End.
+//
+// GetUniformfv is available in GL version 2.0 or greater.
+func (gl *GL) GetUniformfv(program glbase.Program, location glbase.Uniform, params []float32) {
+ var params_c [4]float32
+ C.gl3_2compat_glGetUniformfv(gl.funcs, C.GLuint(program), C.GLint(location), (*C.GLfloat)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetUniformLocation returns an integer that represents the location of a
+// specific uniform variable within a program object. name must be an active
+// uniform variable name in program that is not a structure, an array of
+// structures, or a subcomponent of a vector or a matrix. This function
+// returns -1 if name does not correspond to an active uniform variable in
+// program or if name starts with the reserved prefix "gl_".
+//
+// Uniform variables that are structures or arrays of structures may be
+// queried by calling GetUniformLocation for each field within the
+// structure. The array element operator "[]" and the structure field
+// operator "." may be used in name in order to select elements within an
+// array or fields within a structure. The result of using these operators is
+// not allowed to be another structure, an array of structures, or a
+// subcomponent of a vector or a matrix. Except if the last part of name
+// indicates a uniform variable array, the location of the first element of
+// an array can be retrieved by using the name of the array, or by using the
+// name appended by "[0]".
+//
+// The actual locations assigned to uniform variables are not known until the
+// program object is linked successfully. After linking has occurred, the
+// command GetUniformLocation can be used to obtain the location of a
+// uniform variable. This location value can then be passed to Uniform to
+// set the value of the uniform variable or to GetUniform in order to query
+// the current value of the uniform variable. After a program object has been
+// linked successfully, the index values for uniform variables remain fixed
+// until the next link command occurs. Uniform variable locations and values
+// can only be queried after a link if the link was successful.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program object.
+// GL.INVALID_OPERATION is generated if program has not been successfully
+// linked. GL.INVALID_OPERATION is generated if GetUniformLocation is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// GetUniformLocation is available in GL version 2.0 or greater.
+func (gl *GL) GetUniformLocation(program glbase.Program, name string) glbase.Uniform {
+ name_cstr := C.CString(name)
+ glresult := C.gl3_2compat_glGetUniformLocation(gl.funcs, C.GLuint(program), (*C.GLchar)(name_cstr))
+ C.free(unsafe.Pointer(name_cstr))
+ return glbase.Uniform(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetShaderSource.xml
+func (gl *GL) GetShaderSource(shader glbase.Shader, bufSize int32, length []int32, source []byte) {
+ C.gl3_2compat_glGetShaderSource(gl.funcs, C.GLuint(shader), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&source[0])))
+}
+
+// GetShaderInfoLog returns the information log for the specified shader
+// object. The information log for a shader object is modified when the
+// shader is compiled.
+//
+// The information log for a shader object is a string that may contain
+// diagnostic messages, warning messages, and other information about the
+// last compile operation. When a shader object is created, its information
+// log will be a string of length 0, and the size of the current log can be
+// obtained by calling GetShaderiv with the value GL.INFO_LOG_LENGTH.
+//
+// The information log for a shader object is the OpenGL implementer's
+// primary mechanism for conveying information about the compilation process.
+// Therefore, the information log can be helpful to application developers
+// during the development process, even when compilation is successful.
+// Application developers should not expect different OpenGL implementations
+// to produce identical information logs.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader is not a shader
+// object. GL.INVALID_VALUE is generated if maxLength is less than 0.
+// GL.INVALID_OPERATION is generated if GetShaderInfoLog is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// GetShaderInfoLog is available in GL version 2.0 or greater.
+func (gl *GL) GetShaderInfoLog(shader glbase.Shader) []byte {
+ var params [1]int32
+ var length int32
+ gl.GetShaderiv(shader, INFO_LOG_LENGTH, params[:])
+ bufSize := params[0]
+ infoLog := make([]byte, int(bufSize))
+ C.gl3_2compat_glGetShaderInfoLog(gl.funcs, C.GLuint(shader), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length)), (*C.GLchar)(unsafe.Pointer(&infoLog[0])))
+ return infoLog
+}
+
+// GetShaderiv GetShader returns in params the value of a parameter for a specific
+// shader object. The following parameters are defined:
+//
+// GL.SHADER_TYPE
+// params returns GL.VERTEX_SHADER if shader is a vertex shader object,
+// and GL.FRAGMENT_SHADER if shader is a fragment shader object.
+//
+// GL.DELETE_STATUS
+// params returns GL.TRUE if shader is currently flagged for deletion,
+// and GL.FALSE otherwise.
+//
+// GL.COMPILE_STATUS
+// params returns GL.TRUE if the last compile operation on shader was
+// successful, and GL.FALSE otherwise.
+//
+// GL.INFO_LOG_LENGTH
+// params returns the number of characters in the information log for
+// shader including the null termination character (the size of the
+// character buffer required to store the information log). If shader has
+// no information log, a value of 0 is returned.
+//
+// GL.SHADER_SOURCE_LENGTH
+// params returns the length of the concatenation of the source strings
+// that make up the shader source for the shader, including the null
+// termination character. (the size of the character buffer
+// required to store the shader source). If no source code exists, 0 is
+// returned.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader does not refer to a
+// shader object. GL.INVALID_ENUM is generated if pname is not an accepted
+// value. GL.INVALID_OPERATION is generated if GetShader is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// GetShaderiv is available in GL version 2.0 or greater.
+func (gl *GL) GetShaderiv(shader glbase.Shader, pname glbase.Enum, params []int32) {
+ var params_c [4]int32
+ C.gl3_2compat_glGetShaderiv(gl.funcs, C.GLuint(shader), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetProgramInfoLog returns the information log for the specified program
+// object. The information log for a program object is modified when the
+// program object is linked or validated.
+//
+// The information log for a program object is either an empty string, or a
+// string containing information about the last link operation, or a string
+// containing information about the last validation operation. It may contain
+// diagnostic messages, warning messages, and other information. When a
+// program object is created, its information log will be a string of length
+// 0, and the size of the current log can be obtained by calling GetProgramiv
+// with the value GL.INFO_LOG_LENGTH.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated
+// by OpenGL. GL.INVALID_OPERATION is generated if program is not a
+// program object.
+func (gl *GL) GetProgramInfoLog(program glbase.Program) []byte {
+ var params [1]int32
+ var length int32
+ gl.GetProgramiv(program, INFO_LOG_LENGTH, params[:])
+ bufSize := params[0]
+ infoLog := make([]byte, int(bufSize))
+ C.gl3_2compat_glGetProgramInfoLog(gl.funcs, C.GLuint(program), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length)), (*C.GLchar)(unsafe.Pointer(&infoLog[0])))
+ return infoLog
+}
+
+// GetProgramiv returns in params the value of a parameter for a specific
+// program object. The following parameters are defined:
+//
+// GL.DELETE_STATUS
+// params returns GL.TRUE if program is currently flagged for deletion,
+// and GL.FALSE otherwise.
+//
+// GL.LINK_STATUS
+// params returns GL.TRUE if the last link operation on program was
+// successful, and GL.FALSE otherwise.
+//
+// GL.VALIDATE_STATUS
+// params returns GL.TRUE or if the last validation operation on
+// program was successful, and GL.FALSE otherwise.
+//
+// GL.INFO_LOG_LENGTH
+// params returns the number of characters in the information log for
+// program including the null termination character (the size of
+// the character buffer required to store the information log). If
+// program has no information log, a value of 0 is returned.
+//
+// GL.ATTACHED_SHADERS
+// params returns the number of shader objects attached to program.
+//
+// GL.ACTIVE_ATTRIBUTES
+// params returns the number of active attribute variables for program.
+//
+// GL.ACTIVE_ATTRIBUTE_MAX_LENGTH
+// params returns the length of the longest active attribute name for
+// program, including the null termination character (the size of
+// the character buffer required to store the longest attribute name).
+// If no active attributes exist, 0 is returned.
+//
+// GL.ACTIVE_UNIFORMS
+// params returns the number of active uniform variables for program.
+//
+// GL.ACTIVE_UNIFORM_MAX_LENGTH
+// params returns the length of the longest active uniform variable
+// name for program, including the null termination character (i.e.,
+// the size of the character buffer required to store the longest
+// uniform variable name). If no active uniform variables exist, 0 is
+// returned.
+//
+// GL.TRANSFORM_FEEDBACK_BUFFER_MODE
+// params returns a symbolic constant indicating the buffer mode used
+// when transform feedback is active. This may be GL.SEPARATE_ATTRIBS
+// or GL.INTERLEAVED_ATTRIBS.
+//
+// GL.TRANSFORM_FEEDBACK_VARYINGS
+// params returns the number of varying variables to capture in transform
+// feedback mode for the program.
+//
+// GL.TRANSFORM_FEEDBACK_VARYING_MAX_LENGTH
+// params returns the length of the longest variable name to be used for
+// transform feedback, including the null-terminator.
+//
+// GL.GEOMETRY_VERTICES_OUT
+// params returns the maximum number of vertices that the geometry shader in
+// program will output.
+//
+// GL.GEOMETRY_INPUT_TYPE
+// params returns a symbolic constant indicating the primitive type accepted
+// as input to the geometry shader contained in program.
+//
+// GL.GEOMETRY_OUTPUT_TYPE
+// params returns a symbolic constant indicating the primitive type that will
+// be output by the geometry shader contained in program.
+//
+// GL.ACTIVE_UNIFORM_BLOCKS and GL.ACTIVE_UNIFORM_BLOCK_MAX_NAME_LENGTH are
+// available only if the GL version 3.1 or greater.
+//
+// GL.GEOMETRY_VERTICES_OUT, GL.GEOMETRY_INPUT_TYPE and
+// GL.GEOMETRY_OUTPUT_TYPE are accepted only if the GL version is 3.2 or
+// greater.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program does not refer to a
+// program object. GL.INVALID_OPERATION is generated if pname is
+// GL.GEOMETRY_VERTICES_OUT, GL.GEOMETRY_INPUT_TYPE, or
+// GL.GEOMETRY_OUTPUT_TYPE, and program does not contain a geometry shader.
+// GL.INVALID_ENUM is generated if pname is not an accepted value.
+func (gl *GL) GetProgramiv(program glbase.Program, pname glbase.Enum, params []int32) {
+ var params_c [4]int32
+ C.gl3_2compat_glGetProgramiv(gl.funcs, C.GLuint(program), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetAttribLocation queries the previously linked program object specified
+// by program for the attribute variable specified by name and returns the
+// index of the generic vertex attribute that is bound to that attribute
+// variable. If name is a matrix attribute variable, the index of the first
+// column of the matrix is returned. If the named attribute variable is not
+// an active attribute in the specified program object or if name starts with
+// the reserved prefix "gl_", a value of -1 is returned.
+//
+// The association between an attribute variable name and a generic attribute
+// index can be specified at any time by calling BindAttribLocation.
+// Attribute bindings do not go into effect until LinkProgram is called.
+// After a program object has been linked successfully, the index values for
+// attribute variables remain fixed until the next link command occurs. The
+// attribute values can only be queried after a link if the link was
+// successful. GetAttribLocation returns the binding that actually went
+// into effect the last time LinkProgram was called for the specified
+// program object. Attribute bindings that have been specified since the last
+// link operation are not returned by GetAttribLocation.
+//
+// Error GL_INVALID_OPERATION is generated if program is not a value
+// generated by OpenGL. GL_INVALID_OPERATION is generated if program is not
+// a program object. GL_INVALID_OPERATION is generated if program has not
+// been successfully linked. GL_INVALID_OPERATION is generated if
+// GetAttribLocation is executed between the execution of Begin and the
+// corresponding execution of End.
+//
+// GetAttribLocation is available in GL version 2.0 or greater.
+func (gl *GL) GetAttribLocation(program glbase.Program, name string) glbase.Attrib {
+ name_cstr := C.CString(name)
+ glresult := C.gl3_2compat_glGetAttribLocation(gl.funcs, C.GLuint(program), (*C.GLchar)(name_cstr))
+ C.free(unsafe.Pointer(name_cstr))
+ return glbase.Attrib(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetAttachedShaders.xml
+func (gl *GL) GetAttachedShaders(program glbase.Program, maxCount int32, count []int, obj []uint32) {
+ C.gl3_2compat_glGetAttachedShaders(gl.funcs, C.GLuint(program), C.GLsizei(maxCount), (*C.GLsizei)(unsafe.Pointer(&count[0])), (*C.GLuint)(unsafe.Pointer(&obj[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetActiveUniform.xml
+func (gl *GL) GetActiveUniform(program glbase.Program, index uint32, bufSize int32, length []int32, size []int, gltype []glbase.Enum, name []byte) {
+ C.gl3_2compat_glGetActiveUniform(gl.funcs, C.GLuint(program), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLint)(unsafe.Pointer(&size[0])), (*C.GLenum)(unsafe.Pointer(&gltype[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetActiveAttrib.xml
+func (gl *GL) GetActiveAttrib(program glbase.Program, index glbase.Attrib, bufSize int32, length []int32, size []int, gltype []glbase.Enum, name []byte) {
+ C.gl3_2compat_glGetActiveAttrib(gl.funcs, C.GLuint(program), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLint)(unsafe.Pointer(&size[0])), (*C.GLenum)(unsafe.Pointer(&gltype[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEnableVertexAttribArray.xml
+func (gl *GL) EnableVertexAttribArray(index glbase.Attrib) {
+ C.gl3_2compat_glEnableVertexAttribArray(gl.funcs, C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDisableVertexAttribArray.xml
+func (gl *GL) DisableVertexAttribArray(index glbase.Attrib) {
+ C.gl3_2compat_glDisableVertexAttribArray(gl.funcs, C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDetachShader.xml
+func (gl *GL) DetachShader(program glbase.Program, shader glbase.Shader) {
+ C.gl3_2compat_glDetachShader(gl.funcs, C.GLuint(program), C.GLuint(shader))
+}
+
+// DeleteShader frees the memory and invalidates the name associated with
+// the shader object specified by shader. This command effectively undoes the
+// effects of a call to CreateShader.
+//
+// If a shader object to be deleted is attached to a program object, it will
+// be flagged for deletion, but it will not be deleted until it is no longer
+// attached to any program object, for any rendering context (it must
+// be detached from wherever it was attached before it will be deleted). A
+// value of 0 for shader will be silently ignored.
+//
+// To determine whether an object has been flagged for deletion, call
+// GetShader with arguments shader and GL.DELETE_STATUS.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL.
+//
+// DeleteShader is available in GL version 2.0 or greater.
+func (gl *GL) DeleteShader(shader glbase.Shader) {
+ C.gl3_2compat_glDeleteShader(gl.funcs, C.GLuint(shader))
+}
+
+// DeleteProgram frees the memory and invalidates the name associated with
+// the program object specified by program. This command effectively undoes
+// the effects of a call to CreateProgram.
+//
+// If a program object is in use as part of current rendering state, it will
+// be flagged for deletion, but it will not be deleted until it is no longer
+// part of current state for any rendering context. If a program object to be
+// deleted has shader objects attached to it, those shader objects will be
+// automatically detached but not deleted unless they have already been
+// flagged for deletion by a previous call to DeleteShader. A value of 0
+// for program will be silently ignored.
+//
+// To determine whether a program object has been flagged for deletion, call
+// GetProgram with arguments program and GL.DELETE_STATUS.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL.
+//
+// DeleteProgram is available in GL version 2.0 or greater.
+func (gl *GL) DeleteProgram(program glbase.Program) {
+ C.gl3_2compat_glDeleteProgram(gl.funcs, C.GLuint(program))
+}
+
+// CreateShader creates an empty shader object and returns a non-zero value
+// by which it can be referenced. A shader object is used to maintain the
+// source code strings that define a shader. shaderType indicates the type of
+// shader to be created.
+//
+// Two types of shaders are supported. A shader of type GL.VERTEX_SHADER is a
+// shader that is intended to run on the programmable vertex processor and
+// replace the fixed functionality vertex processing in OpenGL. A shader of
+// type GL.FRAGMENT_SHADER is a shader that is intended to run on the
+// programmable fragment processor and replace the fixed functionality
+// fragment processing in OpenGL.
+//
+// When created, a shader object's GL.SHADER_TYPE parameter is set to either
+// GL.VERTEX_SHADER or GL.FRAGMENT_SHADER, depending on the value of
+// shaderType.
+//
+// Like display lists and texture objects, the name space for shader objects
+// may be shared across a set of contexts, as long as the server sides of the
+// contexts share the same address space. If the name space is shared across
+// contexts, any attached objects and the data associated with those attached
+// objects are shared as well.
+//
+// This function returns 0 if an error occurs creating the shader object.
+//
+// Error GL.INVALID_ENUM is generated if shaderType is not an accepted value.
+// GL.INVALID_OPERATION is generated if CreateShader is executed between the
+// execution of Begin and the corresponding execution of End.
+//
+// CreateShader is available in GL version 2.0 or greater.
+func (gl *GL) CreateShader(gltype glbase.Enum) glbase.Shader {
+ glresult := C.gl3_2compat_glCreateShader(gl.funcs, C.GLenum(gltype))
+ return glbase.Shader(glresult)
+}
+
+// CreateProgram creates an empty program object and returns a non-zero
+// value by which it can be referenced. A program object is an object to
+// which shader objects can be attached. This provides a mechanism to specify
+// the shader objects that will be linked to create a program. It also
+// provides a means for checking the compatibility of the shaders that will
+// be used to create a program (for instance, checking the compatibility
+// between a vertex shader and a fragment shader). When no longer needed as
+// part of a program object, shader objects can be detached.
+//
+// One or more executables are created in a program object by successfully
+// attaching shader objects to it with AttachShader, successfully compiling
+// the shader objects with CompileShader, and successfully linking the
+// program object with LinkProgram. These executables are made part of
+// current state when UseProgram is called. Program objects can be deleted
+// by calling DeleteProgram. The memory associated with the program object
+// will be deleted when it is no longer part of current rendering state for
+// any context.
+//
+// Like display lists and texture objects, the name space for program objects
+// may be shared across a set of contexts, as long as the server sides of the
+// contexts share the same address space. If the name space is shared across
+// contexts, any attached objects and the data associated with those attached
+// objects are shared as well.
+//
+// Applications are responsible for providing the synchronization across API
+// calls when objects are accessed from different execution threads.
+//
+// This function returns 0 if an error occurs creating the program object.
+//
+// Error GL.INVALID_OPERATION is generated if CreateProgram is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// CreateProgram is available in GL version 2.0 or greater.
+func (gl *GL) CreateProgram() glbase.Program {
+ glresult := C.gl3_2compat_glCreateProgram(gl.funcs)
+ return glbase.Program(glresult)
+}
+
+// CompileShader compiles the source code strings that have been stored in
+// the shader object specified by shader.
+//
+// The compilation status will be stored as part of the shader object's
+// state. This value will be set to GL.TRUE if the shader was compiled without
+// errors and is ready for use, and GL.FALSE otherwise. It can be queried by
+// calling GetShaderiv with arguments shader and GL.COMPILE_STATUS.
+//
+// Compilation of a shader can fail for a number of reasons as specified by
+// the OpenGL Shading Language Specification. Whether or not the compilation
+// was successful, information about the compilation can be obtained from the
+// shader object's information log by calling GetShaderInfoLog.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader is not a shader
+// object. GL.INVALID_OPERATION is generated if CompileShader is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// CompileShader is available in GL version 2.0 or greater.
+func (gl *GL) CompileShader(shader glbase.Shader) {
+ C.gl3_2compat_glCompileShader(gl.funcs, C.GLuint(shader))
+}
+
+// BindAttribLocation associates a user-defined attribute variable in the program
+// object specified by program with a generic vertex attribute index. The name
+// parameter specifies the name of the vertex shader attribute variable to
+// which index is to be bound. When program is made part of the current state,
+// values provided via the generic vertex attribute index will modify the
+// value of the user-defined attribute variable specified by name.
+//
+// If name refers to a matrix attribute variable, index refers to the first
+// column of the matrix. Other matrix columns are then automatically bound to
+// locations index+1 for a matrix of type mat2; index+1 and index+2 for a
+// matrix of type mat3; and index+1, index+2, and index+3 for a matrix of
+// type mat4.
+//
+// This command makes it possible for vertex shaders to use descriptive names
+// for attribute variables rather than generic variables that are numbered
+// from 0 to GL.MAX_VERTEX_ATTRIBS-1. The values sent to each generic
+// attribute index are part of current state, just like standard vertex
+// attributes such as color, normal, and vertex position. If a different
+// program object is made current by calling UseProgram, the generic vertex
+// attributes are tracked in such a way that the same values will be observed
+// by attributes in the new program object that are also bound to index.
+//
+// Attribute variable name-to-generic attribute index bindings for a program
+// object can be explicitly assigned at any time by calling
+// BindAttribLocation. Attribute bindings do not go into effect until
+// LinkProgram is called. After a program object has been linked
+// successfully, the index values for generic attributes remain fixed (and
+// their values can be queried) until the next link command occurs.
+//
+// Applications are not allowed to bind any of the standard OpenGL vertex
+// attributes using this command, as they are bound automatically when
+// needed. Any attribute binding that occurs after the program object has
+// been linked will not take effect until the next time the program object is
+// linked.
+//
+// If name was bound previously, that information is lost. Thus you cannot
+// bind one user-defined attribute variable to multiple indices, but you can
+// bind multiple user-defined attribute variables to the same index.
+//
+// Applications are allowed to bind more than one user-defined attribute
+// variable to the same generic vertex attribute index. This is called
+// aliasing, and it is allowed only if just one of the aliased attributes is
+// active in the executable program, or if no path through the shader
+// consumes more than one attribute of a set of attributes aliased to the
+// same location. The compiler and linker are allowed to assume that no
+// aliasing is done and are free to employ optimizations that work only in
+// the absence of aliasing. OpenGL implementations are not required to do
+// error checking to detect aliasing. Because there is no way to bind
+// standard attributes, it is not possible to alias generic attributes with
+// conventional ones (except for generic attribute 0).
+//
+// BindAttribLocation can be called before any vertex shader objects are
+// bound to the specified program object. It is also permissible to bind a
+// generic attribute index to an attribute variable name that is never used
+// in a vertex shader.
+//
+// Active attributes that are not explicitly bound will be bound by the
+// linker when LinkProgram is called. The locations assigned can be queried
+// by calling GetAttribLocation.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS.
+// GL.INVALID_OPERATION is generated if name starts with the reserved prefix "gl_".
+// GL.INVALID_VALUE is generated if program is not a value generated by OpenGL.
+// GL.INVALID_OPERATION is generated if program is not a program object.
+// GL.INVALID_OPERATION is generated if BindAttribLocation is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// BindAttribLocation is available in GL version 2.0 or greater.
+func (gl *GL) BindAttribLocation(program glbase.Program, index glbase.Attrib, name string) {
+ name_cstr := C.CString(name)
+ C.gl3_2compat_glBindAttribLocation(gl.funcs, C.GLuint(program), C.GLuint(index), (*C.GLchar)(name_cstr))
+ C.free(unsafe.Pointer(name_cstr))
+}
+
+// AttachShader attaches a shader object to a program object.
+//
+// In order to create an executable, there must be a way to specify the list
+// of things that will be linked together. Program objects provide this
+// mechanism. Shaders that are to be linked together in a program object must
+// first be attached to that program object. This indicates that shader will
+// be included in link operations that will be performed on program.
+//
+// All operations that can be performed on a shader object are valid whether
+// or not the shader object is attached to a program object. It is
+// permissible to attach a shader object to a program object before source
+// code has been loaded into the shader object or before the shader object
+// has been compiled. It is permissible to attach multiple shader objects of
+// the same type because each may contain a portion of the complete shader.
+// It is also permissible to attach a shader object to more than one program
+// object. If a shader object is deleted while it is attached to a program
+// object, it will be flagged for deletion, and deletion will not occur until
+// DetachShader is called to detach it from all program objects to which it
+// is attached.
+//
+// Error GL.INVALID_VALUE is generated if either program or shader is not a
+// value generated by OpenGL. GL.INVALID_OPERATION is generated if program
+// is not a program object. GL.INVALID_OPERATION is generated if shader is
+// not a shader object. GL.INVALID_OPERATION is generated if shader is
+// already attached to program. GL.INVALID_OPERATION is generated if
+// AttachShader is executed between the execution of Begin and the
+// corresponding execution of End.
+//
+// AttachShader is available in GL version 2.0 or greater.
+func (gl *GL) AttachShader(program glbase.Program, shader glbase.Shader) {
+ C.gl3_2compat_glAttachShader(gl.funcs, C.GLuint(program), C.GLuint(shader))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glStencilMaskSeparate.xml
+func (gl *GL) StencilMaskSeparate(face glbase.Enum, mask uint32) {
+ C.gl3_2compat_glStencilMaskSeparate(gl.funcs, C.GLenum(face), C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glStencilFuncSeparate.xml
+func (gl *GL) StencilFuncSeparate(face, glfunc glbase.Enum, ref int32, mask uint32) {
+ C.gl3_2compat_glStencilFuncSeparate(gl.funcs, C.GLenum(face), C.GLenum(glfunc), C.GLint(ref), C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glStencilOpSeparate.xml
+func (gl *GL) StencilOpSeparate(face, sfail, dpfail, dppass glbase.Enum) {
+ C.gl3_2compat_glStencilOpSeparate(gl.funcs, C.GLenum(face), C.GLenum(sfail), C.GLenum(dpfail), C.GLenum(dppass))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDrawBuffers.xml
+func (gl *GL) DrawBuffers(n int, bufs []glbase.Enum) {
+ C.gl3_2compat_glDrawBuffers(gl.funcs, C.GLsizei(n), (*C.GLenum)(unsafe.Pointer(&bufs[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBlendEquationSeparate.xml
+func (gl *GL) BlendEquationSeparate(modeRGB, modeAlpha glbase.Enum) {
+ C.gl3_2compat_glBlendEquationSeparate(gl.funcs, C.GLenum(modeRGB), C.GLenum(modeAlpha))
+}
+
+// UniformMatrix4x3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix4x3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix4x3fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(4*3) != 0 {
+ panic("invalid value length for UniformMatrix4x3fv")
+ }
+ count := len(value) / (4 * 3)
+ C.gl3_2compat_glUniformMatrix4x3fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix3x4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix3x4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix3x4fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(3*4) != 0 {
+ panic("invalid value length for UniformMatrix3x4fv")
+ }
+ count := len(value) / (3 * 4)
+ C.gl3_2compat_glUniformMatrix3x4fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix4x2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix4x2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix4x2fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(4*2) != 0 {
+ panic("invalid value length for UniformMatrix4x2fv")
+ }
+ count := len(value) / (4 * 2)
+ C.gl3_2compat_glUniformMatrix4x2fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix2x4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix2x4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix2x4fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(2*4) != 0 {
+ panic("invalid value length for UniformMatrix2x4fv")
+ }
+ count := len(value) / (2 * 4)
+ C.gl3_2compat_glUniformMatrix2x4fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix3x2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix3x2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix3x2fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(3*2) != 0 {
+ panic("invalid value length for UniformMatrix3x2fv")
+ }
+ count := len(value) / (3 * 2)
+ C.gl3_2compat_glUniformMatrix3x2fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix2x3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix2x3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix2x3fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(2*3) != 0 {
+ panic("invalid value length for UniformMatrix2x3fv")
+ }
+ count := len(value) / (2 * 3)
+ C.gl3_2compat_glUniformMatrix2x3fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsVertexArray.xml
+func (gl *GL) IsVertexArray(array uint32) bool {
+ glresult := C.gl3_2compat_glIsVertexArray(gl.funcs, C.GLuint(array))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGenVertexArrays.xml
+func (gl *GL) GenVertexArrays(n int, arrays []uint32) {
+ C.gl3_2compat_glGenVertexArrays(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&arrays[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDeleteVertexArrays.xml
+func (gl *GL) DeleteVertexArrays(n int, arrays []uint32) {
+ C.gl3_2compat_glDeleteVertexArrays(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&arrays[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBindVertexArray.xml
+func (gl *GL) BindVertexArray(array uint32) {
+ C.gl3_2compat_glBindVertexArray(gl.funcs, C.GLuint(array))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFlushMappedBufferRange.xml
+func (gl *GL) FlushMappedBufferRange(target glbase.Enum, offset, length int) {
+ C.gl3_2compat_glFlushMappedBufferRange(gl.funcs, C.GLenum(target), C.GLintptr(offset), C.GLsizeiptr(length))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFramebufferTextureLayer.xml
+func (gl *GL) FramebufferTextureLayer(target, attachment glbase.Enum, texture glbase.Texture, level int, layer int32) {
+ C.gl3_2compat_glFramebufferTextureLayer(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLuint(texture), C.GLint(level), C.GLint(layer))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRenderbufferStorageMultisample.xml
+func (gl *GL) RenderbufferStorageMultisample(target glbase.Enum, samples int32, internalFormat glbase.Enum, width, height int) {
+ C.gl3_2compat_glRenderbufferStorageMultisample(gl.funcs, C.GLenum(target), C.GLsizei(samples), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBlitFramebuffer.xml
+func (gl *GL) BlitFramebuffer(srcX0, srcY0, srcX1, srcY1, dstX0, dstY0, dstX1, dstY1 int32, mask glbase.Bitfield, filter glbase.Enum) {
+ C.gl3_2compat_glBlitFramebuffer(gl.funcs, C.GLint(srcX0), C.GLint(srcY0), C.GLint(srcX1), C.GLint(srcY1), C.GLint(dstX0), C.GLint(dstY0), C.GLint(dstX1), C.GLint(dstY1), C.GLbitfield(mask), C.GLenum(filter))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGenerateMipmap.xml
+func (gl *GL) GenerateMipmap(target glbase.Enum) {
+ C.gl3_2compat_glGenerateMipmap(gl.funcs, C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetFramebufferAttachmentParameteriv.xml
+func (gl *GL) GetFramebufferAttachmentParameteriv(target, attachment, pname glbase.Enum, params []int32) {
+ C.gl3_2compat_glGetFramebufferAttachmentParameteriv(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFramebufferRenderbuffer.xml
+func (gl *GL) FramebufferRenderbuffer(target, attachment, renderbuffertarget glbase.Enum, renderbuffer glbase.Renderbuffer) {
+ C.gl3_2compat_glFramebufferRenderbuffer(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(renderbuffertarget), C.GLuint(renderbuffer))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFramebufferTexture3D.xml
+func (gl *GL) FramebufferTexture3D(target, attachment, textarget glbase.Enum, texture glbase.Texture, level int, zoffset int32) {
+ C.gl3_2compat_glFramebufferTexture3D(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(textarget), C.GLuint(texture), C.GLint(level), C.GLint(zoffset))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFramebufferTexture2D.xml
+func (gl *GL) FramebufferTexture2D(target, attachment, textarget glbase.Enum, texture glbase.Texture, level int) {
+ C.gl3_2compat_glFramebufferTexture2D(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(textarget), C.GLuint(texture), C.GLint(level))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFramebufferTexture1D.xml
+func (gl *GL) FramebufferTexture1D(target, attachment, textarget glbase.Enum, texture glbase.Texture, level int) {
+ C.gl3_2compat_glFramebufferTexture1D(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(textarget), C.GLuint(texture), C.GLint(level))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCheckFramebufferStatus.xml
+func (gl *GL) CheckFramebufferStatus(target glbase.Enum) glbase.Enum {
+ glresult := C.gl3_2compat_glCheckFramebufferStatus(gl.funcs, C.GLenum(target))
+ return glbase.Enum(glresult)
+}
+
+// GenFramebuffers returns n framebuffer object names in ids. There is no
+// guarantee that the names form a contiguous set of integers; however, it is
+// guaranteed that none of the returned names was in use immediately before
+// the call to GenFramebuffers.
+//
+// Framebuffer object names returned by a call to GenFramebuffers are not
+// returned by subsequent calls, unless they are first deleted with
+// DeleteFramebuffers.
+//
+// The names returned in ids are marked as used, for the purposes of
+// GenFramebuffers only, but they acquire state and type only when they are
+// first bound.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+func (gl *GL) GenFramebuffers(n int) []glbase.Framebuffer {
+ if n == 0 {
+ return nil
+ }
+ framebuffers := make([]glbase.Framebuffer, n)
+ C.gl3_2compat_glGenFramebuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&framebuffers[0])))
+ return framebuffers
+}
+
+// DeleteFramebuffers deletes the framebuffer objects whose names are
+// stored in the framebuffers slice. The name zero is reserved by the GL and
+// is silently ignored, should it occur in framebuffers, as are other unused
+// names. Once a framebuffer object is deleted, its name is again unused and
+// it has no attachments. If a framebuffer that is currently bound to one or
+// more of the targets GL.DRAW_FRAMEBUFFER or GL.READ_FRAMEBUFFER is deleted,
+// it is as though BindFramebuffer had been executed with the corresponding
+// target and framebuffer zero.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// DeleteFramebuffers is available in GL version 3.0 or greater.
+func (gl *GL) DeleteFramebuffers(framebuffers []glbase.Framebuffer) {
+ n := len(framebuffers)
+ if n == 0 {
+ return
+ }
+ C.gl3_2compat_glDeleteFramebuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&framebuffers[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBindFramebuffer.xml
+func (gl *GL) BindFramebuffer(target glbase.Enum, framebuffer glbase.Framebuffer) {
+ C.gl3_2compat_glBindFramebuffer(gl.funcs, C.GLenum(target), C.GLuint(framebuffer))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsFramebuffer.xml
+func (gl *GL) IsFramebuffer(framebuffer glbase.Framebuffer) bool {
+ glresult := C.gl3_2compat_glIsFramebuffer(gl.funcs, C.GLuint(framebuffer))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetRenderbufferParameteriv.xml
+func (gl *GL) GetRenderbufferParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl3_2compat_glGetRenderbufferParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRenderbufferStorage.xml
+func (gl *GL) RenderbufferStorage(target, internalFormat glbase.Enum, width, height int) {
+ C.gl3_2compat_glRenderbufferStorage(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height))
+}
+
+// GenRenderbuffers returns n renderbuffer object names in renderbuffers.
+// There is no guarantee that the names form a contiguous set of integers;
+// however, it is guaranteed that none of the returned names was in use
+// immediately before the call to GenRenderbuffers.
+//
+// Renderbuffer object names returned by a call to GenRenderbuffers are not
+// returned by subsequent calls, unless they are first deleted with
+// DeleteRenderbuffers.
+//
+// The names returned in renderbuffers are marked as used, for the purposes
+// of GenRenderbuffers only, but they acquire state and type only when they
+// are first bound.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// GenRenderbuffers is available in GL version 3.0 or greater.
+func (gl *GL) GenRenderbuffers(n int) []glbase.Renderbuffer {
+ if n == 0 {
+ return nil
+ }
+ renderbuffers := make([]glbase.Renderbuffer, n)
+ C.gl3_2compat_glGenRenderbuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&renderbuffers[0])))
+ return renderbuffers
+}
+
+// DeleteRenderbuffers deletes the renderbuffer objects whose names are stored
+// in the renderbuffers slice. The name zero is reserved by the GL and
+// is silently ignored, should it occur in renderbuffers, as are other unused
+// names. Once a renderbuffer object is deleted, its name is again unused and
+// it has no contents. If a renderbuffer that is currently bound to the
+// target GL.RENDERBUFFER is deleted, it is as though BindRenderbuffer had
+// been executed with a target of GL.RENDERBUFFER and a name of zero.
+//
+// If a renderbuffer object is attached to one or more attachment points in
+// the currently bound framebuffer, then it as if FramebufferRenderbuffer
+// had been called, with a renderbuffer of zero for each attachment point to
+// which this image was attached in the currently bound framebuffer. In other
+// words, this renderbuffer object is first detached from all attachment
+// ponits in the currently bound framebuffer. Note that the renderbuffer
+// image is specifically not detached from any non-bound framebuffers.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// DeleteRenderbuffers is available in GL version 3.0 or greater.
+func (gl *GL) DeleteRenderbuffers(renderbuffers []glbase.Renderbuffer) {
+ n := len(renderbuffers)
+ if n == 0 {
+ return
+ }
+ C.gl3_2compat_glDeleteRenderbuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&renderbuffers[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBindRenderbuffer.xml
+func (gl *GL) BindRenderbuffer(target glbase.Enum, renderbuffer glbase.Renderbuffer) {
+ C.gl3_2compat_glBindRenderbuffer(gl.funcs, C.GLenum(target), C.GLuint(renderbuffer))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsRenderbuffer.xml
+func (gl *GL) IsRenderbuffer(renderbuffer glbase.Renderbuffer) bool {
+ glresult := C.gl3_2compat_glIsRenderbuffer(gl.funcs, C.GLuint(renderbuffer))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClearBufferfi.xml
+func (gl *GL) ClearBufferfi(buffer glbase.Enum, drawbuffer int32, depth float32, stencil int32) {
+ C.gl3_2compat_glClearBufferfi(gl.funcs, C.GLenum(buffer), C.GLint(drawbuffer), C.GLfloat(depth), C.GLint(stencil))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClearBufferfv.xml
+func (gl *GL) ClearBufferfv(buffer glbase.Enum, drawbuffer int32, value []float32) {
+ C.gl3_2compat_glClearBufferfv(gl.funcs, C.GLenum(buffer), C.GLint(drawbuffer), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClearBufferuiv.xml
+func (gl *GL) ClearBufferuiv(buffer glbase.Enum, drawbuffer int32, value []uint32) {
+ C.gl3_2compat_glClearBufferuiv(gl.funcs, C.GLenum(buffer), C.GLint(drawbuffer), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClearBufferiv.xml
+func (gl *GL) ClearBufferiv(buffer glbase.Enum, drawbuffer int32, value []int32) {
+ C.gl3_2compat_glClearBufferiv(gl.funcs, C.GLenum(buffer), C.GLint(drawbuffer), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTexParameterIuiv.xml
+func (gl *GL) GetTexParameterIuiv(target, pname glbase.Enum, params []uint32) {
+ C.gl3_2compat_glGetTexParameterIuiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTexParameterIiv.xml
+func (gl *GL) GetTexParameterIiv(target, pname glbase.Enum, params []int32) {
+ C.gl3_2compat_glGetTexParameterIiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexParameterIuiv.xml
+func (gl *GL) TexParameterIuiv(target, pname glbase.Enum, params []uint32) {
+ C.gl3_2compat_glTexParameterIuiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexParameterIiv.xml
+func (gl *GL) TexParameterIiv(target, pname glbase.Enum, params []int32) {
+ C.gl3_2compat_glTexParameterIiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// Uniform4uiv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform4uiv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4uiv(location glbase.Uniform, value []uint32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%4 != 0 {
+ panic("invalid value length for Uniform4uiv")
+ }
+ count := len(value) / 4
+ C.gl3_2compat_glUniform4uiv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform3uiv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform3uiv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3uiv(location glbase.Uniform, value []uint32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%3 != 0 {
+ panic("invalid value length for Uniform3uiv")
+ }
+ count := len(value) / 3
+ C.gl3_2compat_glUniform3uiv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform2uiv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform2uiv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2uiv(location glbase.Uniform, value []uint32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%2 != 0 {
+ panic("invalid value length for Uniform2uiv")
+ }
+ count := len(value) / 2
+ C.gl3_2compat_glUniform2uiv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform1uiv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform1uiv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1uiv(location glbase.Uniform, value []uint32) {
+ if len(value) == 0 {
+ return
+ }
+ count := len(value)
+ C.gl3_2compat_glUniform1uiv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4ui modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform4ui operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4ui(location glbase.Uniform, v0, v1, v2, v3 uint32) {
+ C.gl3_2compat_glUniform4ui(gl.funcs, C.GLint(location), C.GLuint(v0), C.GLuint(v1), C.GLuint(v2), C.GLuint(v3))
+}
+
+// Uniform3ui modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform3ui operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3ui(location glbase.Uniform, v0, v1, v2 uint32) {
+ C.gl3_2compat_glUniform3ui(gl.funcs, C.GLint(location), C.GLuint(v0), C.GLuint(v1), C.GLuint(v2))
+}
+
+// Uniform2ui modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform2ui operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2ui(location glbase.Uniform, v0, v1 uint32) {
+ C.gl3_2compat_glUniform2ui(gl.funcs, C.GLint(location), C.GLuint(v0), C.GLuint(v1))
+}
+
+// Uniform1ui modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform1ui operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1ui(location glbase.Uniform, v0 uint32) {
+ C.gl3_2compat_glUniform1ui(gl.funcs, C.GLint(location), C.GLuint(v0))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetFragDataLocation.xml
+func (gl *GL) GetFragDataLocation(program glbase.Program, name []byte) int32 {
+ glresult := C.gl3_2compat_glGetFragDataLocation(gl.funcs, C.GLuint(program), (*C.GLchar)(unsafe.Pointer(&name[0])))
+ return int32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBindFragDataLocation.xml
+func (gl *GL) BindFragDataLocation(program glbase.Program, color uint32, name []byte) {
+ C.gl3_2compat_glBindFragDataLocation(gl.funcs, C.GLuint(program), C.GLuint(color), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetUniformuiv.xml
+func (gl *GL) GetUniformuiv(program glbase.Program, location glbase.Uniform, params []uint32) {
+ C.gl3_2compat_glGetUniformuiv(gl.funcs, C.GLuint(program), C.GLint(location), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetVertexAttribIuiv.xml
+func (gl *GL) GetVertexAttribIuiv(index glbase.Attrib, pname glbase.Enum, params []uint32) {
+ C.gl3_2compat_glGetVertexAttribIuiv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetVertexAttribIiv.xml
+func (gl *GL) GetVertexAttribIiv(index glbase.Attrib, pname glbase.Enum, params []int32) {
+ C.gl3_2compat_glGetVertexAttribIiv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribIPointer.xml
+func (gl *GL) VertexAttribIPointer(index glbase.Attrib, size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2compat_glVertexAttribIPointer(gl.funcs, C.GLuint(index), C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEndConditionalRender.xml
+func (gl *GL) EndConditionalRender() {
+ C.gl3_2compat_glEndConditionalRender(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBeginConditionalRender.xml
+func (gl *GL) BeginConditionalRender(id uint32, mode glbase.Enum) {
+ C.gl3_2compat_glBeginConditionalRender(gl.funcs, C.GLuint(id), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClampColor.xml
+func (gl *GL) ClampColor(target, clamp glbase.Enum) {
+ C.gl3_2compat_glClampColor(gl.funcs, C.GLenum(target), C.GLenum(clamp))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTransformFeedbackVarying.xml
+func (gl *GL) GetTransformFeedbackVarying(program glbase.Program, index uint32, bufSize int32, length []int32, size []int, gltype []glbase.Enum, name []byte) {
+ C.gl3_2compat_glGetTransformFeedbackVarying(gl.funcs, C.GLuint(program), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLsizei)(unsafe.Pointer(&size[0])), (*C.GLenum)(unsafe.Pointer(&gltype[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBindBufferBase.xml
+func (gl *GL) BindBufferBase(target glbase.Enum, index uint32, buffer glbase.Buffer) {
+ C.gl3_2compat_glBindBufferBase(gl.funcs, C.GLenum(target), C.GLuint(index), C.GLuint(buffer))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBindBufferRange.xml
+func (gl *GL) BindBufferRange(target glbase.Enum, index uint32, buffer glbase.Buffer, offset, size int) {
+ C.gl3_2compat_glBindBufferRange(gl.funcs, C.GLenum(target), C.GLuint(index), C.GLuint(buffer), C.GLintptr(offset), C.GLsizeiptr(size))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEndTransformFeedback.xml
+func (gl *GL) EndTransformFeedback() {
+ C.gl3_2compat_glEndTransformFeedback(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBeginTransformFeedback.xml
+func (gl *GL) BeginTransformFeedback(primitiveMode glbase.Enum) {
+ C.gl3_2compat_glBeginTransformFeedback(gl.funcs, C.GLenum(primitiveMode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsEnabledi.xml
+func (gl *GL) IsEnabledi(target glbase.Enum, index uint32) bool {
+ glresult := C.gl3_2compat_glIsEnabledi(gl.funcs, C.GLenum(target), C.GLuint(index))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDisablei.xml
+func (gl *GL) Disablei(target glbase.Enum, index uint32) {
+ C.gl3_2compat_glDisablei(gl.funcs, C.GLenum(target), C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEnablei.xml
+func (gl *GL) Enablei(target glbase.Enum, index uint32) {
+ C.gl3_2compat_glEnablei(gl.funcs, C.GLenum(target), C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetIntegeri_v.xml
+func (gl *GL) GetIntegeri_v(target glbase.Enum, index uint32, data []int32) {
+ C.gl3_2compat_glGetIntegeri_v(gl.funcs, C.GLenum(target), C.GLuint(index), (*C.GLint)(unsafe.Pointer(&data[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetBooleani_v.xml
+func (gl *GL) GetBooleani_v(target glbase.Enum, index uint32, data []bool) {
+ C.gl3_2compat_glGetBooleani_v(gl.funcs, C.GLenum(target), C.GLuint(index), (*C.GLboolean)(unsafe.Pointer(&data[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColorMaski.xml
+func (gl *GL) ColorMaski(index uint32, r, g, b, a bool) {
+ C.gl3_2compat_glColorMaski(gl.funcs, C.GLuint(index), *(*C.GLboolean)(unsafe.Pointer(&r)), *(*C.GLboolean)(unsafe.Pointer(&g)), *(*C.GLboolean)(unsafe.Pointer(&b)), *(*C.GLboolean)(unsafe.Pointer(&a)))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCopyBufferSubData.xml
+func (gl *GL) CopyBufferSubData(readTarget, writeTarget glbase.Enum, readOffset, writeOffset, size int) {
+ C.gl3_2compat_glCopyBufferSubData(gl.funcs, C.GLenum(readTarget), C.GLenum(writeTarget), C.GLintptr(readOffset), C.GLintptr(writeOffset), C.GLsizeiptr(size))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glUniformBlockBinding.xml
+func (gl *GL) UniformBlockBinding(program glbase.Program, v0, v1 uint32) {
+ C.gl3_2compat_glUniformBlockBinding(gl.funcs, C.GLuint(program), C.GLuint(v0), C.GLuint(v1))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetActiveUniformBlockName.xml
+func (gl *GL) GetActiveUniformBlockName(program glbase.Program, uniformBlockIndex uint32, bufSize int32, length []int32, uniformBlockName []byte) {
+ C.gl3_2compat_glGetActiveUniformBlockName(gl.funcs, C.GLuint(program), C.GLuint(uniformBlockIndex), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&uniformBlockName[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetActiveUniformBlockiv.xml
+func (gl *GL) GetActiveUniformBlockiv(program glbase.Program, uniformBlockIndex uint32, pname glbase.Enum, params []int32) {
+ C.gl3_2compat_glGetActiveUniformBlockiv(gl.funcs, C.GLuint(program), C.GLuint(uniformBlockIndex), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetUniformBlockIndex.xml
+func (gl *GL) GetUniformBlockIndex(program glbase.Program, uniformBlockName []byte) uint32 {
+ glresult := C.gl3_2compat_glGetUniformBlockIndex(gl.funcs, C.GLuint(program), (*C.GLchar)(unsafe.Pointer(&uniformBlockName[0])))
+ return uint32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetActiveUniformName.xml
+func (gl *GL) GetActiveUniformName(program glbase.Program, uniformIndex uint32, bufSize int32, length []int32, uniformName []byte) {
+ C.gl3_2compat_glGetActiveUniformName(gl.funcs, C.GLuint(program), C.GLuint(uniformIndex), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&uniformName[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetActiveUniformsiv.xml
+func (gl *GL) GetActiveUniformsiv(program glbase.Program, uniformCount int32, uniformIndices []uint32, pname glbase.Enum, params []int32) {
+ C.gl3_2compat_glGetActiveUniformsiv(gl.funcs, C.GLuint(program), C.GLsizei(uniformCount), (*C.GLuint)(unsafe.Pointer(&uniformIndices[0])), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPrimitiveRestartIndex.xml
+func (gl *GL) PrimitiveRestartIndex(index uint32) {
+ C.gl3_2compat_glPrimitiveRestartIndex(gl.funcs, C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexBuffer.xml
+func (gl *GL) TexBuffer(target, internalFormat glbase.Enum, buffer glbase.Buffer) {
+ C.gl3_2compat_glTexBuffer(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLuint(buffer))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDrawElementsInstanced.xml
+func (gl *GL) DrawElementsInstanced(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}, instancecount int32) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2compat_glDrawElementsInstanced(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr, C.GLsizei(instancecount))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDrawArraysInstanced.xml
+func (gl *GL) DrawArraysInstanced(mode glbase.Enum, first, count int, instancecount int32) {
+ C.gl3_2compat_glDrawArraysInstanced(gl.funcs, C.GLenum(mode), C.GLint(first), C.GLsizei(count), C.GLsizei(instancecount))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSampleMaski.xml
+func (gl *GL) SampleMaski(index uint32, mask glbase.Bitfield) {
+ C.gl3_2compat_glSampleMaski(gl.funcs, C.GLuint(index), C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetMultisamplefv.xml
+func (gl *GL) GetMultisamplefv(pname glbase.Enum, index uint32, val []float32) {
+ C.gl3_2compat_glGetMultisamplefv(gl.funcs, C.GLenum(pname), C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&val[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexImage3DMultisample.xml
+func (gl *GL) TexImage3DMultisample(target glbase.Enum, samples, internalFormat int32, width, height int, depth int32, fixedsamplelocations bool) {
+ C.gl3_2compat_glTexImage3DMultisample(gl.funcs, C.GLenum(target), C.GLsizei(samples), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), *(*C.GLboolean)(unsafe.Pointer(&fixedsamplelocations)))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexImage2DMultisample.xml
+func (gl *GL) TexImage2DMultisample(target glbase.Enum, samples, internalFormat int32, width, height int, fixedsamplelocations bool) {
+ C.gl3_2compat_glTexImage2DMultisample(gl.funcs, C.GLenum(target), C.GLsizei(samples), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), *(*C.GLboolean)(unsafe.Pointer(&fixedsamplelocations)))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetSynciv.xml
+func (gl *GL) GetSynciv(sync glbase.Sync, pname glbase.Enum, bufSize int32, length, values []int32) {
+ C.gl3_2compat_glGetSynciv(gl.funcs, C.GLsync(unsafe.Pointer(sync)), C.GLenum(pname), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLint)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetInteger64v.xml
+func (gl *GL) GetInteger64v(pname glbase.Enum, params []int64) {
+ C.gl3_2compat_glGetInteger64v(gl.funcs, C.GLenum(pname), (*C.GLint64)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glWaitSync.xml
+func (gl *GL) WaitSync(sync glbase.Sync, flags glbase.Bitfield, timeout uint64) {
+ C.gl3_2compat_glWaitSync(gl.funcs, C.GLsync(unsafe.Pointer(sync)), C.GLbitfield(flags), C.GLuint64(timeout))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClientWaitSync.xml
+func (gl *GL) ClientWaitSync(sync glbase.Sync, flags glbase.Bitfield, timeout uint64) glbase.Enum {
+ glresult := C.gl3_2compat_glClientWaitSync(gl.funcs, C.GLsync(unsafe.Pointer(sync)), C.GLbitfield(flags), C.GLuint64(timeout))
+ return glbase.Enum(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDeleteSync.xml
+func (gl *GL) DeleteSync(sync glbase.Sync) {
+ C.gl3_2compat_glDeleteSync(gl.funcs, C.GLsync(unsafe.Pointer(sync)))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsSync.xml
+func (gl *GL) IsSync(sync glbase.Sync) bool {
+ glresult := C.gl3_2compat_glIsSync(gl.funcs, C.GLsync(unsafe.Pointer(sync)))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFenceSync.xml
+func (gl *GL) FenceSync(condition glbase.Enum, flags glbase.Bitfield) glbase.Sync {
+ glresult := C.gl3_2compat_glFenceSync(gl.funcs, C.GLenum(condition), C.GLbitfield(flags))
+ return glbase.Sync(unsafe.Pointer(glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glProvokingVertex.xml
+func (gl *GL) ProvokingVertex(mode glbase.Enum) {
+ C.gl3_2compat_glProvokingVertex(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDrawElementsInstancedBaseVertex.xml
+func (gl *GL) DrawElementsInstancedBaseVertex(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}, instancecount, basevertex int32) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2compat_glDrawElementsInstancedBaseVertex(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr, C.GLsizei(instancecount), C.GLint(basevertex))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDrawRangeElementsBaseVertex.xml
+func (gl *GL) DrawRangeElementsBaseVertex(mode glbase.Enum, start, end uint32, count int, gltype glbase.Enum, indices interface{}, basevertex int32) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2compat_glDrawRangeElementsBaseVertex(gl.funcs, C.GLenum(mode), C.GLuint(start), C.GLuint(end), C.GLsizei(count), C.GLenum(gltype), indices_ptr, C.GLint(basevertex))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDrawElementsBaseVertex.xml
+func (gl *GL) DrawElementsBaseVertex(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}, basevertex int32) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2compat_glDrawElementsBaseVertex(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr, C.GLint(basevertex))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFramebufferTexture.xml
+func (gl *GL) FramebufferTexture(target, attachment glbase.Enum, texture glbase.Texture, level int) {
+ C.gl3_2compat_glFramebufferTexture(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLuint(texture), C.GLint(level))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetBufferParameteri64v.xml
+func (gl *GL) GetBufferParameteri64v(target, pname glbase.Enum, params []int64) {
+ C.gl3_2compat_glGetBufferParameteri64v(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint64)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetInteger64i_v.xml
+func (gl *GL) GetInteger64i_v(target glbase.Enum, index uint32, data []int64) {
+ C.gl3_2compat_glGetInteger64i_v(gl.funcs, C.GLenum(target), C.GLuint(index), (*C.GLint64)(unsafe.Pointer(&data[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTranslatef.xml
+func (gl *GL) Translatef(x, y, z float32) {
+ C.gl3_2compat_glTranslatef(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTranslated.xml
+func (gl *GL) Translated(x, y, z float64) {
+ C.gl3_2compat_glTranslated(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glScalef.xml
+func (gl *GL) Scalef(x, y, z float32) {
+ C.gl3_2compat_glScalef(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glScaled.xml
+func (gl *GL) Scaled(x, y, z float64) {
+ C.gl3_2compat_glScaled(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRotatef.xml
+func (gl *GL) Rotatef(angle, x, y, z float32) {
+ C.gl3_2compat_glRotatef(gl.funcs, C.GLfloat(angle), C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRotated.xml
+func (gl *GL) Rotated(angle, x, y, z float64) {
+ C.gl3_2compat_glRotated(gl.funcs, C.GLdouble(angle), C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPushMatrix.xml
+func (gl *GL) PushMatrix() {
+ C.gl3_2compat_glPushMatrix(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPopMatrix.xml
+func (gl *GL) PopMatrix() {
+ C.gl3_2compat_glPopMatrix(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glOrtho.xml
+func (gl *GL) Ortho(left, right, bottom, top, zNear, zFar float64) {
+ C.gl3_2compat_glOrtho(gl.funcs, C.GLdouble(left), C.GLdouble(right), C.GLdouble(bottom), C.GLdouble(top), C.GLdouble(zNear), C.GLdouble(zFar))
+}
+
+// MultMatrixd multiplies the current matrix with the provided matrix.
+//
+// The m parameter must hold 16 consecutive elements of a 4x4 column-major matrix.
+//
+// The current matrix is determined by the current matrix mode (see
+// MatrixMode). It is either the projection matrix, modelview matrix, or the
+// texture matrix.
+//
+// For example, if the current matrix is C and the coordinates to be transformed
+// are v = (v[0], v[1], v[2], v[3]), then the current transformation is C × v, or
+//
+// c[0] c[4] c[8] c[12] v[0]
+// c[1] c[5] c[9] c[13] v[1]
+// c[2] c[6] c[10] c[14] X v[2]
+// c[3] c[7] c[11] c[15] v[3]
+//
+// Calling MultMatrix with an argument of m = m[0], m[1], ..., m[15]
+// replaces the current transformation with (C X M) x v, or
+//
+// c[0] c[4] c[8] c[12] m[0] m[4] m[8] m[12] v[0]
+// c[1] c[5] c[9] c[13] m[1] m[5] m[9] m[13] v[1]
+// c[2] c[6] c[10] c[14] X m[2] m[6] m[10] m[14] X v[2]
+// c[3] c[7] c[11] c[15] m[3] m[7] m[11] m[15] v[3]
+//
+// Where 'X' denotes matrix multiplication, and v is represented as a 4x1 matrix.
+//
+// While the elements of the matrix may be specified with single or double
+// precision, the GL may store or operate on these values in less-than-single
+// precision.
+//
+// In many computer languages, 4×4 arrays are represented in row-major
+// order. The transformations just described represent these matrices in
+// column-major order. The order of the multiplication is important. For
+// example, if the current transformation is a rotation, and MultMatrix is
+// called with a translation matrix, the translation is done directly on the
+// coordinates to be transformed, while the rotation is done on the results
+// of that translation.
+//
+// GL.INVALID_OPERATION is generated if MultMatrix is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) MultMatrixd(m []float64) {
+ if len(m) != 16 {
+ panic("parameter m must have length 16 for the 4x4 matrix")
+ }
+ C.gl3_2compat_glMultMatrixd(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&m[0])))
+}
+
+// MultMatrixf multiplies the current matrix with the provided matrix.
+//
+// The m parameter must hold 16 consecutive elements of a 4x4 column-major matrix.
+//
+// The current matrix is determined by the current matrix mode (see
+// MatrixMode). It is either the projection matrix, modelview matrix, or the
+// texture matrix.
+//
+// For example, if the current matrix is C and the coordinates to be transformed
+// are v = (v[0], v[1], v[2], v[3]), then the current transformation is C × v, or
+//
+// c[0] c[4] c[8] c[12] v[0]
+// c[1] c[5] c[9] c[13] v[1]
+// c[2] c[6] c[10] c[14] X v[2]
+// c[3] c[7] c[11] c[15] v[3]
+//
+// Calling MultMatrix with an argument of m = m[0], m[1], ..., m[15]
+// replaces the current transformation with (C X M) x v, or
+//
+// c[0] c[4] c[8] c[12] m[0] m[4] m[8] m[12] v[0]
+// c[1] c[5] c[9] c[13] m[1] m[5] m[9] m[13] v[1]
+// c[2] c[6] c[10] c[14] X m[2] m[6] m[10] m[14] X v[2]
+// c[3] c[7] c[11] c[15] m[3] m[7] m[11] m[15] v[3]
+//
+// Where 'X' denotes matrix multiplication, and v is represented as a 4x1 matrix.
+//
+// While the elements of the matrix may be specified with single or double
+// precision, the GL may store or operate on these values in less-than-single
+// precision.
+//
+// In many computer languages, 4×4 arrays are represented in row-major
+// order. The transformations just described represent these matrices in
+// column-major order. The order of the multiplication is important. For
+// example, if the current transformation is a rotation, and MultMatrix is
+// called with a translation matrix, the translation is done directly on the
+// coordinates to be transformed, while the rotation is done on the results
+// of that translation.
+//
+// GL.INVALID_OPERATION is generated if MultMatrix is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) MultMatrixf(m []float32) {
+ if len(m) != 16 {
+ panic("parameter m must have length 16 for the 4x4 matrix")
+ }
+ C.gl3_2compat_glMultMatrixf(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMatrixMode.xml
+func (gl *GL) MatrixMode(mode glbase.Enum) {
+ C.gl3_2compat_glMatrixMode(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glLoadMatrixd.xml
+func (gl *GL) LoadMatrixd(m []float64) {
+ C.gl3_2compat_glLoadMatrixd(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glLoadMatrixf.xml
+func (gl *GL) LoadMatrixf(m []float32) {
+ C.gl3_2compat_glLoadMatrixf(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glLoadIdentity.xml
+func (gl *GL) LoadIdentity() {
+ C.gl3_2compat_glLoadIdentity(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFrustum.xml
+func (gl *GL) Frustum(left, right, bottom, top, zNear, zFar float64) {
+ C.gl3_2compat_glFrustum(gl.funcs, C.GLdouble(left), C.GLdouble(right), C.GLdouble(bottom), C.GLdouble(top), C.GLdouble(zNear), C.GLdouble(zFar))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsList.xml
+func (gl *GL) IsList(list uint32) bool {
+ glresult := C.gl3_2compat_glIsList(gl.funcs, C.GLuint(list))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTexGeniv.xml
+func (gl *GL) GetTexGeniv(coord, pname glbase.Enum, params []int32) {
+ C.gl3_2compat_glGetTexGeniv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTexGenfv.xml
+func (gl *GL) GetTexGenfv(coord, pname glbase.Enum, params []float32) {
+ C.gl3_2compat_glGetTexGenfv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTexGendv.xml
+func (gl *GL) GetTexGendv(coord, pname glbase.Enum, params []float64) {
+ C.gl3_2compat_glGetTexGendv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTexEnviv.xml
+func (gl *GL) GetTexEnviv(target, pname glbase.Enum, params []int32) {
+ C.gl3_2compat_glGetTexEnviv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTexEnvfv.xml
+func (gl *GL) GetTexEnvfv(target, pname glbase.Enum, params []float32) {
+ C.gl3_2compat_glGetTexEnvfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetPolygonStipple.xml
+func (gl *GL) GetPolygonStipple(mask []uint8) {
+ C.gl3_2compat_glGetPolygonStipple(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&mask[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetPixelMapusv.xml
+func (gl *GL) GetPixelMapusv(glmap glbase.Enum, values []uint16) {
+ C.gl3_2compat_glGetPixelMapusv(gl.funcs, C.GLenum(glmap), (*C.GLushort)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetPixelMapuiv.xml
+func (gl *GL) GetPixelMapuiv(glmap glbase.Enum, values []uint32) {
+ C.gl3_2compat_glGetPixelMapuiv(gl.funcs, C.GLenum(glmap), (*C.GLuint)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetPixelMapfv.xml
+func (gl *GL) GetPixelMapfv(glmap glbase.Enum, values []float32) {
+ C.gl3_2compat_glGetPixelMapfv(gl.funcs, C.GLenum(glmap), (*C.GLfloat)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetMaterialiv.xml
+func (gl *GL) GetMaterialiv(face, pname glbase.Enum, params []int32) {
+ C.gl3_2compat_glGetMaterialiv(gl.funcs, C.GLenum(face), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetMaterialfv.xml
+func (gl *GL) GetMaterialfv(face, pname glbase.Enum, params []float32) {
+ C.gl3_2compat_glGetMaterialfv(gl.funcs, C.GLenum(face), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetMapiv.xml
+func (gl *GL) GetMapiv(target, query glbase.Enum, v []int32) {
+ C.gl3_2compat_glGetMapiv(gl.funcs, C.GLenum(target), C.GLenum(query), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetMapfv.xml
+func (gl *GL) GetMapfv(target, query glbase.Enum, v []float32) {
+ C.gl3_2compat_glGetMapfv(gl.funcs, C.GLenum(target), C.GLenum(query), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetMapdv.xml
+func (gl *GL) GetMapdv(target, query glbase.Enum, v []float64) {
+ C.gl3_2compat_glGetMapdv(gl.funcs, C.GLenum(target), C.GLenum(query), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetLightiv.xml
+func (gl *GL) GetLightiv(light, pname glbase.Enum, params []int32) {
+ C.gl3_2compat_glGetLightiv(gl.funcs, C.GLenum(light), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetLightfv.xml
+func (gl *GL) GetLightfv(light, pname glbase.Enum, params []float32) {
+ C.gl3_2compat_glGetLightfv(gl.funcs, C.GLenum(light), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetClipPlane.xml
+func (gl *GL) GetClipPlane(plane glbase.Enum, equation []float64) {
+ C.gl3_2compat_glGetClipPlane(gl.funcs, C.GLenum(plane), (*C.GLdouble)(unsafe.Pointer(&equation[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDrawPixels.xml
+func (gl *GL) DrawPixels(width, height int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2compat_glDrawPixels(gl.funcs, C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCopyPixels.xml
+func (gl *GL) CopyPixels(x, y, width, height int, gltype glbase.Enum) {
+ C.gl3_2compat_glCopyPixels(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height), C.GLenum(gltype))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPixelMapusv.xml
+func (gl *GL) PixelMapusv(glmap glbase.Enum, mapsize int32, values []uint16) {
+ C.gl3_2compat_glPixelMapusv(gl.funcs, C.GLenum(glmap), C.GLint(mapsize), (*C.GLushort)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPixelMapuiv.xml
+func (gl *GL) PixelMapuiv(glmap glbase.Enum, mapsize int32, values []uint32) {
+ C.gl3_2compat_glPixelMapuiv(gl.funcs, C.GLenum(glmap), C.GLint(mapsize), (*C.GLuint)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPixelMapfv.xml
+func (gl *GL) PixelMapfv(glmap glbase.Enum, mapsize int32, values []float32) {
+ C.gl3_2compat_glPixelMapfv(gl.funcs, C.GLenum(glmap), C.GLint(mapsize), (*C.GLfloat)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPixelTransferi.xml
+func (gl *GL) PixelTransferi(pname glbase.Enum, param int32) {
+ C.gl3_2compat_glPixelTransferi(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPixelTransferf.xml
+func (gl *GL) PixelTransferf(pname glbase.Enum, param float32) {
+ C.gl3_2compat_glPixelTransferf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPixelZoom.xml
+func (gl *GL) PixelZoom(xfactor, yfactor float32) {
+ C.gl3_2compat_glPixelZoom(gl.funcs, C.GLfloat(xfactor), C.GLfloat(yfactor))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glAlphaFunc.xml
+func (gl *GL) AlphaFunc(glfunc glbase.Enum, ref float32) {
+ C.gl3_2compat_glAlphaFunc(gl.funcs, C.GLenum(glfunc), C.GLfloat(ref))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEvalPoint2.xml
+func (gl *GL) EvalPoint2(i, j int32) {
+ C.gl3_2compat_glEvalPoint2(gl.funcs, C.GLint(i), C.GLint(j))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEvalMesh2.xml
+func (gl *GL) EvalMesh2(mode glbase.Enum, i1, i2, j1, j2 int32) {
+ C.gl3_2compat_glEvalMesh2(gl.funcs, C.GLenum(mode), C.GLint(i1), C.GLint(i2), C.GLint(j1), C.GLint(j2))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEvalPoint1.xml
+func (gl *GL) EvalPoint1(i int32) {
+ C.gl3_2compat_glEvalPoint1(gl.funcs, C.GLint(i))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEvalMesh1.xml
+func (gl *GL) EvalMesh1(mode glbase.Enum, i1, i2 int32) {
+ C.gl3_2compat_glEvalMesh1(gl.funcs, C.GLenum(mode), C.GLint(i1), C.GLint(i2))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEvalCoord2fv.xml
+func (gl *GL) EvalCoord2fv(u []float32) {
+ if len(u) != 2 {
+ panic("parameter u has incorrect length")
+ }
+ C.gl3_2compat_glEvalCoord2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&u[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEvalCoord2f.xml
+func (gl *GL) EvalCoord2f(u, v float32) {
+ C.gl3_2compat_glEvalCoord2f(gl.funcs, C.GLfloat(u), C.GLfloat(v))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEvalCoord2dv.xml
+func (gl *GL) EvalCoord2dv(u []float64) {
+ if len(u) != 2 {
+ panic("parameter u has incorrect length")
+ }
+ C.gl3_2compat_glEvalCoord2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&u[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEvalCoord2d.xml
+func (gl *GL) EvalCoord2d(u, v float64) {
+ C.gl3_2compat_glEvalCoord2d(gl.funcs, C.GLdouble(u), C.GLdouble(v))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEvalCoord1fv.xml
+func (gl *GL) EvalCoord1fv(u []float32) {
+ C.gl3_2compat_glEvalCoord1fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&u[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEvalCoord1f.xml
+func (gl *GL) EvalCoord1f(u float32) {
+ C.gl3_2compat_glEvalCoord1f(gl.funcs, C.GLfloat(u))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEvalCoord1dv.xml
+func (gl *GL) EvalCoord1dv(u []float64) {
+ C.gl3_2compat_glEvalCoord1dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&u[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEvalCoord1d.xml
+func (gl *GL) EvalCoord1d(u float64) {
+ C.gl3_2compat_glEvalCoord1d(gl.funcs, C.GLdouble(u))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMapGrid2f.xml
+func (gl *GL) MapGrid2f(un int32, u1, u2 float32, vn int32, v1, v2 float32) {
+ C.gl3_2compat_glMapGrid2f(gl.funcs, C.GLint(un), C.GLfloat(u1), C.GLfloat(u2), C.GLint(vn), C.GLfloat(v1), C.GLfloat(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMapGrid2d.xml
+func (gl *GL) MapGrid2d(un int32, u1, u2 float64, vn int32, v1, v2 float64) {
+ C.gl3_2compat_glMapGrid2d(gl.funcs, C.GLint(un), C.GLdouble(u1), C.GLdouble(u2), C.GLint(vn), C.GLdouble(v1), C.GLdouble(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMapGrid1f.xml
+func (gl *GL) MapGrid1f(un int32, u1, u2 float32) {
+ C.gl3_2compat_glMapGrid1f(gl.funcs, C.GLint(un), C.GLfloat(u1), C.GLfloat(u2))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMapGrid1d.xml
+func (gl *GL) MapGrid1d(un int32, u1, u2 float64) {
+ C.gl3_2compat_glMapGrid1d(gl.funcs, C.GLint(un), C.GLdouble(u1), C.GLdouble(u2))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMap2f.xml
+func (gl *GL) Map2f(target glbase.Enum, u1, u2 float32, ustride, uorder int32, v1, v2 float32, vstride, vorder int32, points []float32) {
+ C.gl3_2compat_glMap2f(gl.funcs, C.GLenum(target), C.GLfloat(u1), C.GLfloat(u2), C.GLint(ustride), C.GLint(uorder), C.GLfloat(v1), C.GLfloat(v2), C.GLint(vstride), C.GLint(vorder), (*C.GLfloat)(unsafe.Pointer(&points[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMap2d.xml
+func (gl *GL) Map2d(target glbase.Enum, u1, u2 float64, ustride, uorder int32, v1, v2 float64, vstride, vorder int32, points []float64) {
+ C.gl3_2compat_glMap2d(gl.funcs, C.GLenum(target), C.GLdouble(u1), C.GLdouble(u2), C.GLint(ustride), C.GLint(uorder), C.GLdouble(v1), C.GLdouble(v2), C.GLint(vstride), C.GLint(vorder), (*C.GLdouble)(unsafe.Pointer(&points[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMap1f.xml
+func (gl *GL) Map1f(target glbase.Enum, u1, u2 float32, stride, order int, points []float32) {
+ C.gl3_2compat_glMap1f(gl.funcs, C.GLenum(target), C.GLfloat(u1), C.GLfloat(u2), C.GLint(stride), C.GLint(order), (*C.GLfloat)(unsafe.Pointer(&points[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMap1d.xml
+func (gl *GL) Map1d(target glbase.Enum, u1, u2 float64, stride, order int, points []float64) {
+ C.gl3_2compat_glMap1d(gl.funcs, C.GLenum(target), C.GLdouble(u1), C.GLdouble(u2), C.GLint(stride), C.GLint(order), (*C.GLdouble)(unsafe.Pointer(&points[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPushAttrib.xml
+func (gl *GL) PushAttrib(mask glbase.Bitfield) {
+ C.gl3_2compat_glPushAttrib(gl.funcs, C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPopAttrib.xml
+func (gl *GL) PopAttrib() {
+ C.gl3_2compat_glPopAttrib(gl.funcs)
+}
+
+// Accum executes an operation on the accumulation buffer.
+//
+// Parameter op defines the accumulation buffer operation (GL.ACCUM, GL.LOAD,
+// GL.ADD, GL.MULT, or GL.RETURN) and specifies how the value parameter is
+// used.
+//
+// The accumulation buffer is an extended-range color buffer. Images are not
+// rendered into it. Rather, images rendered into one of the color buffers
+// are added to the contents of the accumulation buffer after rendering.
+// Effects such as antialiasing (of points, lines, and polygons), motion
+// blur, and depth of field can be created by accumulating images generated
+// with different transformation matrices.
+//
+// Each pixel in the accumulation buffer consists of red, green, blue, and
+// alpha values. The number of bits per component in the accumulation buffer
+// depends on the implementation. You can examine this number by calling
+// GetIntegerv four times, with arguments GL.ACCUM_RED_BITS,
+// GL.ACCUM_GREEN_BITS, GL.ACCUM_BLUE_BITS, and GL.ACCUM_ALPHA_BITS.
+// Regardless of the number of bits per component, the range of values stored
+// by each component is (-1, 1). The accumulation buffer pixels are mapped
+// one-to-one with frame buffer pixels.
+//
+// All accumulation buffer operations are limited to the area of the current
+// scissor box and applied identically to the red, green, blue, and alpha
+// components of each pixel. If a Accum operation results in a value outside
+// the range (-1, 1), the contents of an accumulation buffer pixel component
+// are undefined.
+//
+// The operations are as follows:
+//
+// GL.ACCUM
+// Obtains R, G, B, and A values from the buffer currently selected for
+// reading (see ReadBuffer). Each component value is divided by 2 n -
+// 1 , where n is the number of bits allocated to each color component
+// in the currently selected buffer. The result is a floating-point
+// value in the range 0 1 , which is multiplied by value and added to
+// the corresponding pixel component in the accumulation buffer,
+// thereby updating the accumulation buffer.
+//
+// GL.LOAD
+// Similar to GL.ACCUM, except that the current value in the
+// accumulation buffer is not used in the calculation of the new value.
+// That is, the R, G, B, and A values from the currently selected
+// buffer are divided by 2 n - 1 , multiplied by value, and then stored
+// in the corresponding accumulation buffer cell, overwriting the
+// current value.
+//
+// GL.ADD
+// Adds value to each R, G, B, and A in the accumulation buffer.
+//
+// GL.MULT
+// Multiplies each R, G, B, and A in the accumulation buffer by value
+// and returns the scaled component to its corresponding accumulation
+// buffer location.
+//
+// GL.RETURN
+// Transfers accumulation buffer values to the color buffer or buffers
+// currently selected for writing. Each R, G, B, and A component is
+// multiplied by value, then multiplied by 2 n - 1 , clamped to the
+// range 0 2 n - 1 , and stored in the corresponding display buffer
+// cell. The only fragment operations that are applied to this transfer
+// are pixel ownership, scissor, dithering, and color writemasks.
+//
+// To clear the accumulation buffer, call ClearAccum with R, G, B, and A
+// values to set it to, then call Clear with the accumulation buffer
+// enabled.
+//
+// Error GL.INVALID_ENUM is generated if op is not an accepted value.
+// GL.INVALID_OPERATION is generated if there is no accumulation buffer.
+// GL.INVALID_OPERATION is generated if Accum is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) Accum(op glbase.Enum, value float32) {
+ C.gl3_2compat_glAccum(gl.funcs, C.GLenum(op), C.GLfloat(value))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIndexMask.xml
+func (gl *GL) IndexMask(mask uint32) {
+ C.gl3_2compat_glIndexMask(gl.funcs, C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClearIndex.xml
+func (gl *GL) ClearIndex(c float32) {
+ C.gl3_2compat_glClearIndex(gl.funcs, C.GLfloat(c))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClearAccum.xml
+func (gl *GL) ClearAccum(red, green, blue, alpha float32) {
+ C.gl3_2compat_glClearAccum(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPushName.xml
+func (gl *GL) PushName(name uint32) {
+ C.gl3_2compat_glPushName(gl.funcs, C.GLuint(name))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPopName.xml
+func (gl *GL) PopName() {
+ C.gl3_2compat_glPopName(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPassThrough.xml
+func (gl *GL) PassThrough(token float32) {
+ C.gl3_2compat_glPassThrough(gl.funcs, C.GLfloat(token))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glLoadName.xml
+func (gl *GL) LoadName(name uint32) {
+ C.gl3_2compat_glLoadName(gl.funcs, C.GLuint(name))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glInitNames.xml
+func (gl *GL) InitNames() {
+ C.gl3_2compat_glInitNames(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRenderMode.xml
+func (gl *GL) RenderMode(mode glbase.Enum) int32 {
+ glresult := C.gl3_2compat_glRenderMode(gl.funcs, C.GLenum(mode))
+ return int32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSelectBuffer.xml
+func (gl *GL) SelectBuffer(size int, buffer []glbase.Buffer) {
+ C.gl3_2compat_glSelectBuffer(gl.funcs, C.GLsizei(size), (*C.GLuint)(unsafe.Pointer(&buffer[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFeedbackBuffer.xml
+func (gl *GL) FeedbackBuffer(size int, gltype glbase.Enum, buffer []float32) {
+ C.gl3_2compat_glFeedbackBuffer(gl.funcs, C.GLsizei(size), C.GLenum(gltype), (*C.GLfloat)(unsafe.Pointer(&buffer[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexGeniv.xml
+func (gl *GL) TexGeniv(coord, pname glbase.Enum, params []int32) {
+ C.gl3_2compat_glTexGeniv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexGeni.xml
+func (gl *GL) TexGeni(coord, pname glbase.Enum, param int32) {
+ C.gl3_2compat_glTexGeni(gl.funcs, C.GLenum(coord), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexGenfv.xml
+func (gl *GL) TexGenfv(coord, pname glbase.Enum, params []float32) {
+ C.gl3_2compat_glTexGenfv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexGenf.xml
+func (gl *GL) TexGenf(coord, pname glbase.Enum, param float32) {
+ C.gl3_2compat_glTexGenf(gl.funcs, C.GLenum(coord), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexGendv.xml
+func (gl *GL) TexGendv(coord, pname glbase.Enum, params []float64) {
+ C.gl3_2compat_glTexGendv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexGend.xml
+func (gl *GL) TexGend(coord, pname glbase.Enum, param float64) {
+ C.gl3_2compat_glTexGend(gl.funcs, C.GLenum(coord), C.GLenum(pname), C.GLdouble(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexEnviv.xml
+func (gl *GL) TexEnviv(target, pname glbase.Enum, params []int32) {
+ C.gl3_2compat_glTexEnviv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexEnvi.xml
+func (gl *GL) TexEnvi(target, pname glbase.Enum, param int32) {
+ C.gl3_2compat_glTexEnvi(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexEnvfv.xml
+func (gl *GL) TexEnvfv(target, pname glbase.Enum, params []float32) {
+ C.gl3_2compat_glTexEnvfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexEnvf.xml
+func (gl *GL) TexEnvf(target, pname glbase.Enum, param float32) {
+ C.gl3_2compat_glTexEnvf(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glShadeModel.xml
+func (gl *GL) ShadeModel(mode glbase.Enum) {
+ C.gl3_2compat_glShadeModel(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPolygonStipple.xml
+func (gl *GL) PolygonStipple(mask []uint8) {
+ C.gl3_2compat_glPolygonStipple(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&mask[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMaterialiv.xml
+func (gl *GL) Materialiv(face, pname glbase.Enum, params []int32) {
+ C.gl3_2compat_glMaterialiv(gl.funcs, C.GLenum(face), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMateriali.xml
+func (gl *GL) Materiali(face, pname glbase.Enum, param int32) {
+ C.gl3_2compat_glMateriali(gl.funcs, C.GLenum(face), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMaterialfv.xml
+func (gl *GL) Materialfv(face, pname glbase.Enum, params []float32) {
+ C.gl3_2compat_glMaterialfv(gl.funcs, C.GLenum(face), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMaterialf.xml
+func (gl *GL) Materialf(face, pname glbase.Enum, param float32) {
+ C.gl3_2compat_glMaterialf(gl.funcs, C.GLenum(face), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glLineStipple.xml
+func (gl *GL) LineStipple(factor int32, pattern uint16) {
+ C.gl3_2compat_glLineStipple(gl.funcs, C.GLint(factor), C.GLushort(pattern))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glLightModeliv.xml
+func (gl *GL) LightModeliv(pname glbase.Enum, params []int32) {
+ C.gl3_2compat_glLightModeliv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glLightModeli.xml
+func (gl *GL) LightModeli(pname glbase.Enum, param int32) {
+ C.gl3_2compat_glLightModeli(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glLightModelfv.xml
+func (gl *GL) LightModelfv(pname glbase.Enum, params []float32) {
+ C.gl3_2compat_glLightModelfv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glLightModelf.xml
+func (gl *GL) LightModelf(pname glbase.Enum, param float32) {
+ C.gl3_2compat_glLightModelf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glLightiv.xml
+func (gl *GL) Lightiv(light, pname glbase.Enum, params []int32) {
+ C.gl3_2compat_glLightiv(gl.funcs, C.GLenum(light), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glLighti.xml
+func (gl *GL) Lighti(light, pname glbase.Enum, param int32) {
+ C.gl3_2compat_glLighti(gl.funcs, C.GLenum(light), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glLightfv.xml
+func (gl *GL) Lightfv(light, pname glbase.Enum, params []float32) {
+ C.gl3_2compat_glLightfv(gl.funcs, C.GLenum(light), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glLightf.xml
+func (gl *GL) Lightf(light, pname glbase.Enum, param float32) {
+ C.gl3_2compat_glLightf(gl.funcs, C.GLenum(light), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFogiv.xml
+func (gl *GL) Fogiv(pname glbase.Enum, params []int32) {
+ C.gl3_2compat_glFogiv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFogi.xml
+func (gl *GL) Fogi(pname glbase.Enum, param int32) {
+ C.gl3_2compat_glFogi(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFogfv.xml
+func (gl *GL) Fogfv(pname glbase.Enum, params []float32) {
+ C.gl3_2compat_glFogfv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFogf.xml
+func (gl *GL) Fogf(pname glbase.Enum, param float32) {
+ C.gl3_2compat_glFogf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColorMaterial.xml
+func (gl *GL) ColorMaterial(face, mode glbase.Enum) {
+ C.gl3_2compat_glColorMaterial(gl.funcs, C.GLenum(face), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClipPlane.xml
+func (gl *GL) ClipPlane(plane glbase.Enum, equation []float64) {
+ C.gl3_2compat_glClipPlane(gl.funcs, C.GLenum(plane), (*C.GLdouble)(unsafe.Pointer(&equation[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex4sv.xml
+func (gl *GL) Vertex4sv(v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glVertex4sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex4s.xml
+func (gl *GL) Vertex4s(x, y, z, w int16) {
+ C.gl3_2compat_glVertex4s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z), C.GLshort(w))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex4iv.xml
+func (gl *GL) Vertex4iv(v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glVertex4iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex4i.xml
+func (gl *GL) Vertex4i(x, y, z, w int) {
+ C.gl3_2compat_glVertex4i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z), C.GLint(w))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex4fv.xml
+func (gl *GL) Vertex4fv(v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glVertex4fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex4f.xml
+func (gl *GL) Vertex4f(x, y, z, w float32) {
+ C.gl3_2compat_glVertex4f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z), C.GLfloat(w))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex4dv.xml
+func (gl *GL) Vertex4dv(v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glVertex4dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex4d.xml
+func (gl *GL) Vertex4d(x, y, z, w float64) {
+ C.gl3_2compat_glVertex4d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z), C.GLdouble(w))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex3sv.xml
+func (gl *GL) Vertex3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glVertex3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex3s.xml
+func (gl *GL) Vertex3s(x, y, z int16) {
+ C.gl3_2compat_glVertex3s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex3iv.xml
+func (gl *GL) Vertex3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glVertex3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex3i.xml
+func (gl *GL) Vertex3i(x, y, z int) {
+ C.gl3_2compat_glVertex3i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex3fv.xml
+func (gl *GL) Vertex3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glVertex3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex3f.xml
+func (gl *GL) Vertex3f(x, y, z float32) {
+ C.gl3_2compat_glVertex3f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex3dv.xml
+func (gl *GL) Vertex3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glVertex3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex3d.xml
+func (gl *GL) Vertex3d(x, y, z float64) {
+ C.gl3_2compat_glVertex3d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex2sv.xml
+func (gl *GL) Vertex2sv(v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glVertex2sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex2s.xml
+func (gl *GL) Vertex2s(x, y int16) {
+ C.gl3_2compat_glVertex2s(gl.funcs, C.GLshort(x), C.GLshort(y))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex2iv.xml
+func (gl *GL) Vertex2iv(v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glVertex2iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex2i.xml
+func (gl *GL) Vertex2i(x, y int) {
+ C.gl3_2compat_glVertex2i(gl.funcs, C.GLint(x), C.GLint(y))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex2fv.xml
+func (gl *GL) Vertex2fv(v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glVertex2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex2f.xml
+func (gl *GL) Vertex2f(x, y float32) {
+ C.gl3_2compat_glVertex2f(gl.funcs, C.GLfloat(x), C.GLfloat(y))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex2dv.xml
+func (gl *GL) Vertex2dv(v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glVertex2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex2d.xml
+func (gl *GL) Vertex2d(x, y float64) {
+ C.gl3_2compat_glVertex2d(gl.funcs, C.GLdouble(x), C.GLdouble(y))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord4sv.xml
+func (gl *GL) TexCoord4sv(v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glTexCoord4sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord4s.xml
+func (gl *GL) TexCoord4s(s, t, r, q int16) {
+ C.gl3_2compat_glTexCoord4s(gl.funcs, C.GLshort(s), C.GLshort(t), C.GLshort(r), C.GLshort(q))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord4iv.xml
+func (gl *GL) TexCoord4iv(v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glTexCoord4iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord4i.xml
+func (gl *GL) TexCoord4i(s, t, r, q int32) {
+ C.gl3_2compat_glTexCoord4i(gl.funcs, C.GLint(s), C.GLint(t), C.GLint(r), C.GLint(q))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord4fv.xml
+func (gl *GL) TexCoord4fv(v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glTexCoord4fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord4f.xml
+func (gl *GL) TexCoord4f(s, t, r, q float32) {
+ C.gl3_2compat_glTexCoord4f(gl.funcs, C.GLfloat(s), C.GLfloat(t), C.GLfloat(r), C.GLfloat(q))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord4dv.xml
+func (gl *GL) TexCoord4dv(v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glTexCoord4dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord4d.xml
+func (gl *GL) TexCoord4d(s, t, r, q float64) {
+ C.gl3_2compat_glTexCoord4d(gl.funcs, C.GLdouble(s), C.GLdouble(t), C.GLdouble(r), C.GLdouble(q))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord3sv.xml
+func (gl *GL) TexCoord3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glTexCoord3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord3s.xml
+func (gl *GL) TexCoord3s(s, t, r int16) {
+ C.gl3_2compat_glTexCoord3s(gl.funcs, C.GLshort(s), C.GLshort(t), C.GLshort(r))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord3iv.xml
+func (gl *GL) TexCoord3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glTexCoord3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord3i.xml
+func (gl *GL) TexCoord3i(s, t, r int32) {
+ C.gl3_2compat_glTexCoord3i(gl.funcs, C.GLint(s), C.GLint(t), C.GLint(r))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord3fv.xml
+func (gl *GL) TexCoord3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glTexCoord3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord3f.xml
+func (gl *GL) TexCoord3f(s, t, r float32) {
+ C.gl3_2compat_glTexCoord3f(gl.funcs, C.GLfloat(s), C.GLfloat(t), C.GLfloat(r))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord3dv.xml
+func (gl *GL) TexCoord3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glTexCoord3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord3d.xml
+func (gl *GL) TexCoord3d(s, t, r float64) {
+ C.gl3_2compat_glTexCoord3d(gl.funcs, C.GLdouble(s), C.GLdouble(t), C.GLdouble(r))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord2sv.xml
+func (gl *GL) TexCoord2sv(v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glTexCoord2sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord2s.xml
+func (gl *GL) TexCoord2s(s, t int16) {
+ C.gl3_2compat_glTexCoord2s(gl.funcs, C.GLshort(s), C.GLshort(t))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord2iv.xml
+func (gl *GL) TexCoord2iv(v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glTexCoord2iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord2i.xml
+func (gl *GL) TexCoord2i(s, t int32) {
+ C.gl3_2compat_glTexCoord2i(gl.funcs, C.GLint(s), C.GLint(t))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord2fv.xml
+func (gl *GL) TexCoord2fv(v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glTexCoord2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord2f.xml
+func (gl *GL) TexCoord2f(s, t float32) {
+ C.gl3_2compat_glTexCoord2f(gl.funcs, C.GLfloat(s), C.GLfloat(t))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord2dv.xml
+func (gl *GL) TexCoord2dv(v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glTexCoord2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord2d.xml
+func (gl *GL) TexCoord2d(s, t float64) {
+ C.gl3_2compat_glTexCoord2d(gl.funcs, C.GLdouble(s), C.GLdouble(t))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord1sv.xml
+func (gl *GL) TexCoord1sv(v []int16) {
+ C.gl3_2compat_glTexCoord1sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord1s.xml
+func (gl *GL) TexCoord1s(s int16) {
+ C.gl3_2compat_glTexCoord1s(gl.funcs, C.GLshort(s))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord1iv.xml
+func (gl *GL) TexCoord1iv(v []int32) {
+ C.gl3_2compat_glTexCoord1iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord1i.xml
+func (gl *GL) TexCoord1i(s int32) {
+ C.gl3_2compat_glTexCoord1i(gl.funcs, C.GLint(s))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord1fv.xml
+func (gl *GL) TexCoord1fv(v []float32) {
+ C.gl3_2compat_glTexCoord1fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord1f.xml
+func (gl *GL) TexCoord1f(s float32) {
+ C.gl3_2compat_glTexCoord1f(gl.funcs, C.GLfloat(s))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord1dv.xml
+func (gl *GL) TexCoord1dv(v []float64) {
+ C.gl3_2compat_glTexCoord1dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord1d.xml
+func (gl *GL) TexCoord1d(s float64) {
+ C.gl3_2compat_glTexCoord1d(gl.funcs, C.GLdouble(s))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRectsv.xml
+func (gl *GL) Rectsv(v1, v2 []int16) {
+ C.gl3_2compat_glRectsv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v1[0])), (*C.GLshort)(unsafe.Pointer(&v2[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRects.xml
+func (gl *GL) Rects(x1, y1, x2, y2 int16) {
+ C.gl3_2compat_glRects(gl.funcs, C.GLshort(x1), C.GLshort(y1), C.GLshort(x2), C.GLshort(y2))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRectiv.xml
+func (gl *GL) Rectiv(v1, v2 []int32) {
+ C.gl3_2compat_glRectiv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v1[0])), (*C.GLint)(unsafe.Pointer(&v2[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRecti.xml
+func (gl *GL) Recti(x1, y1, x2, y2 int32) {
+ C.gl3_2compat_glRecti(gl.funcs, C.GLint(x1), C.GLint(y1), C.GLint(x2), C.GLint(y2))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRectfv.xml
+func (gl *GL) Rectfv(v1, v2 []float32) {
+ C.gl3_2compat_glRectfv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v1[0])), (*C.GLfloat)(unsafe.Pointer(&v2[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRectf.xml
+func (gl *GL) Rectf(x1, y1, x2, y2 float32) {
+ C.gl3_2compat_glRectf(gl.funcs, C.GLfloat(x1), C.GLfloat(y1), C.GLfloat(x2), C.GLfloat(y2))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRectdv.xml
+func (gl *GL) Rectdv(v1, v2 []float64) {
+ C.gl3_2compat_glRectdv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v1[0])), (*C.GLdouble)(unsafe.Pointer(&v2[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRectd.xml
+func (gl *GL) Rectd(x1, y1, x2, y2 float64) {
+ C.gl3_2compat_glRectd(gl.funcs, C.GLdouble(x1), C.GLdouble(y1), C.GLdouble(x2), C.GLdouble(y2))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos4sv.xml
+func (gl *GL) RasterPos4sv(v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glRasterPos4sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos4s.xml
+func (gl *GL) RasterPos4s(x, y, z, w int16) {
+ C.gl3_2compat_glRasterPos4s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z), C.GLshort(w))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos4iv.xml
+func (gl *GL) RasterPos4iv(v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glRasterPos4iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos4i.xml
+func (gl *GL) RasterPos4i(x, y, z, w int) {
+ C.gl3_2compat_glRasterPos4i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z), C.GLint(w))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos4fv.xml
+func (gl *GL) RasterPos4fv(v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glRasterPos4fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos4f.xml
+func (gl *GL) RasterPos4f(x, y, z, w float32) {
+ C.gl3_2compat_glRasterPos4f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z), C.GLfloat(w))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos4dv.xml
+func (gl *GL) RasterPos4dv(v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glRasterPos4dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos4d.xml
+func (gl *GL) RasterPos4d(x, y, z, w float64) {
+ C.gl3_2compat_glRasterPos4d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z), C.GLdouble(w))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos3sv.xml
+func (gl *GL) RasterPos3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glRasterPos3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos3s.xml
+func (gl *GL) RasterPos3s(x, y, z int16) {
+ C.gl3_2compat_glRasterPos3s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos3iv.xml
+func (gl *GL) RasterPos3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glRasterPos3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos3i.xml
+func (gl *GL) RasterPos3i(x, y, z int) {
+ C.gl3_2compat_glRasterPos3i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos3fv.xml
+func (gl *GL) RasterPos3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glRasterPos3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos3f.xml
+func (gl *GL) RasterPos3f(x, y, z float32) {
+ C.gl3_2compat_glRasterPos3f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos3dv.xml
+func (gl *GL) RasterPos3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glRasterPos3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos3d.xml
+func (gl *GL) RasterPos3d(x, y, z float64) {
+ C.gl3_2compat_glRasterPos3d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos2sv.xml
+func (gl *GL) RasterPos2sv(v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glRasterPos2sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos2s.xml
+func (gl *GL) RasterPos2s(x, y int16) {
+ C.gl3_2compat_glRasterPos2s(gl.funcs, C.GLshort(x), C.GLshort(y))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos2iv.xml
+func (gl *GL) RasterPos2iv(v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glRasterPos2iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos2i.xml
+func (gl *GL) RasterPos2i(x, y int) {
+ C.gl3_2compat_glRasterPos2i(gl.funcs, C.GLint(x), C.GLint(y))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos2fv.xml
+func (gl *GL) RasterPos2fv(v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glRasterPos2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos2f.xml
+func (gl *GL) RasterPos2f(x, y float32) {
+ C.gl3_2compat_glRasterPos2f(gl.funcs, C.GLfloat(x), C.GLfloat(y))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos2dv.xml
+func (gl *GL) RasterPos2dv(v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glRasterPos2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos2d.xml
+func (gl *GL) RasterPos2d(x, y float64) {
+ C.gl3_2compat_glRasterPos2d(gl.funcs, C.GLdouble(x), C.GLdouble(y))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glNormal3sv.xml
+func (gl *GL) Normal3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glNormal3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glNormal3s.xml
+func (gl *GL) Normal3s(nx, ny, nz int16) {
+ C.gl3_2compat_glNormal3s(gl.funcs, C.GLshort(nx), C.GLshort(ny), C.GLshort(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glNormal3iv.xml
+func (gl *GL) Normal3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glNormal3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glNormal3i.xml
+func (gl *GL) Normal3i(nx, ny, nz int32) {
+ C.gl3_2compat_glNormal3i(gl.funcs, C.GLint(nx), C.GLint(ny), C.GLint(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glNormal3fv.xml
+func (gl *GL) Normal3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glNormal3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glNormal3f.xml
+func (gl *GL) Normal3f(nx, ny, nz float32) {
+ C.gl3_2compat_glNormal3f(gl.funcs, C.GLfloat(nx), C.GLfloat(ny), C.GLfloat(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glNormal3dv.xml
+func (gl *GL) Normal3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glNormal3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glNormal3d.xml
+func (gl *GL) Normal3d(nx, ny, nz float64) {
+ C.gl3_2compat_glNormal3d(gl.funcs, C.GLdouble(nx), C.GLdouble(ny), C.GLdouble(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glNormal3bv.xml
+func (gl *GL) Normal3bv(v []byte) {
+ C.gl3_2compat_glNormal3bv(gl.funcs, (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glNormal3b.xml
+func (gl *GL) Normal3b(nx, ny, nz byte) {
+ C.gl3_2compat_glNormal3b(gl.funcs, C.GLbyte(nx), C.GLbyte(ny), C.GLbyte(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIndexsv.xml
+func (gl *GL) Indexsv(c []int16) {
+ C.gl3_2compat_glIndexsv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIndexs.xml
+func (gl *GL) Indexs(c int16) {
+ C.gl3_2compat_glIndexs(gl.funcs, C.GLshort(c))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIndexiv.xml
+func (gl *GL) Indexiv(c []int32) {
+ C.gl3_2compat_glIndexiv(gl.funcs, (*C.GLint)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIndexi.xml
+func (gl *GL) Indexi(c int32) {
+ C.gl3_2compat_glIndexi(gl.funcs, C.GLint(c))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIndexfv.xml
+func (gl *GL) Indexfv(c []float32) {
+ C.gl3_2compat_glIndexfv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIndexf.xml
+func (gl *GL) Indexf(c float32) {
+ C.gl3_2compat_glIndexf(gl.funcs, C.GLfloat(c))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIndexdv.xml
+func (gl *GL) Indexdv(c []float64) {
+ C.gl3_2compat_glIndexdv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIndexd.xml
+func (gl *GL) Indexd(c float64) {
+ C.gl3_2compat_glIndexd(gl.funcs, C.GLdouble(c))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEnd.xml
+func (gl *GL) End() {
+ C.gl3_2compat_glEnd(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEdgeFlagv.xml
+func (gl *GL) EdgeFlagv(flag []bool) {
+ C.gl3_2compat_glEdgeFlagv(gl.funcs, (*C.GLboolean)(unsafe.Pointer(&flag[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEdgeFlag.xml
+func (gl *GL) EdgeFlag(flag bool) {
+ C.gl3_2compat_glEdgeFlag(gl.funcs, *(*C.GLboolean)(unsafe.Pointer(&flag)))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor4usv.xml
+func (gl *GL) Color4usv(v []uint16) {
+ C.gl3_2compat_glColor4usv(gl.funcs, (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor4us.xml
+func (gl *GL) Color4us(red, green, blue, alpha uint16) {
+ C.gl3_2compat_glColor4us(gl.funcs, C.GLushort(red), C.GLushort(green), C.GLushort(blue), C.GLushort(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor4uiv.xml
+func (gl *GL) Color4uiv(v []uint32) {
+ C.gl3_2compat_glColor4uiv(gl.funcs, (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor4ui.xml
+func (gl *GL) Color4ui(red, green, blue, alpha uint32) {
+ C.gl3_2compat_glColor4ui(gl.funcs, C.GLuint(red), C.GLuint(green), C.GLuint(blue), C.GLuint(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor4ubv.xml
+func (gl *GL) Color4ubv(v []uint8) {
+ C.gl3_2compat_glColor4ubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor4ub.xml
+func (gl *GL) Color4ub(red, green, blue, alpha uint8) {
+ C.gl3_2compat_glColor4ub(gl.funcs, C.GLubyte(red), C.GLubyte(green), C.GLubyte(blue), C.GLubyte(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor4sv.xml
+func (gl *GL) Color4sv(v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glColor4sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor4s.xml
+func (gl *GL) Color4s(red, green, blue, alpha int16) {
+ C.gl3_2compat_glColor4s(gl.funcs, C.GLshort(red), C.GLshort(green), C.GLshort(blue), C.GLshort(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor4iv.xml
+func (gl *GL) Color4iv(v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glColor4iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor4i.xml
+func (gl *GL) Color4i(red, green, blue, alpha int32) {
+ C.gl3_2compat_glColor4i(gl.funcs, C.GLint(red), C.GLint(green), C.GLint(blue), C.GLint(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor4fv.xml
+func (gl *GL) Color4fv(v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glColor4fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor4f.xml
+func (gl *GL) Color4f(red, green, blue, alpha float32) {
+ C.gl3_2compat_glColor4f(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor4dv.xml
+func (gl *GL) Color4dv(v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glColor4dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor4d.xml
+func (gl *GL) Color4d(red, green, blue, alpha float64) {
+ C.gl3_2compat_glColor4d(gl.funcs, C.GLdouble(red), C.GLdouble(green), C.GLdouble(blue), C.GLdouble(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor4bv.xml
+func (gl *GL) Color4bv(v []byte) {
+ C.gl3_2compat_glColor4bv(gl.funcs, (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor4b.xml
+func (gl *GL) Color4b(red, green, blue, alpha byte) {
+ C.gl3_2compat_glColor4b(gl.funcs, C.GLbyte(red), C.GLbyte(green), C.GLbyte(blue), C.GLbyte(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor3usv.xml
+func (gl *GL) Color3usv(v []uint16) {
+ C.gl3_2compat_glColor3usv(gl.funcs, (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor3us.xml
+func (gl *GL) Color3us(red, green, blue uint16) {
+ C.gl3_2compat_glColor3us(gl.funcs, C.GLushort(red), C.GLushort(green), C.GLushort(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor3uiv.xml
+func (gl *GL) Color3uiv(v []uint32) {
+ C.gl3_2compat_glColor3uiv(gl.funcs, (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor3ui.xml
+func (gl *GL) Color3ui(red, green, blue uint32) {
+ C.gl3_2compat_glColor3ui(gl.funcs, C.GLuint(red), C.GLuint(green), C.GLuint(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor3ubv.xml
+func (gl *GL) Color3ubv(v []uint8) {
+ C.gl3_2compat_glColor3ubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor3ub.xml
+func (gl *GL) Color3ub(red, green, blue uint8) {
+ C.gl3_2compat_glColor3ub(gl.funcs, C.GLubyte(red), C.GLubyte(green), C.GLubyte(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor3sv.xml
+func (gl *GL) Color3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glColor3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor3s.xml
+func (gl *GL) Color3s(red, green, blue int16) {
+ C.gl3_2compat_glColor3s(gl.funcs, C.GLshort(red), C.GLshort(green), C.GLshort(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor3iv.xml
+func (gl *GL) Color3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glColor3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor3i.xml
+func (gl *GL) Color3i(red, green, blue int32) {
+ C.gl3_2compat_glColor3i(gl.funcs, C.GLint(red), C.GLint(green), C.GLint(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor3fv.xml
+func (gl *GL) Color3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glColor3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor3f.xml
+func (gl *GL) Color3f(red, green, blue float32) {
+ C.gl3_2compat_glColor3f(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor3dv.xml
+func (gl *GL) Color3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glColor3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor3d.xml
+func (gl *GL) Color3d(red, green, blue float64) {
+ C.gl3_2compat_glColor3d(gl.funcs, C.GLdouble(red), C.GLdouble(green), C.GLdouble(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor3bv.xml
+func (gl *GL) Color3bv(v []byte) {
+ C.gl3_2compat_glColor3bv(gl.funcs, (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor3b.xml
+func (gl *GL) Color3b(red, green, blue byte) {
+ C.gl3_2compat_glColor3b(gl.funcs, C.GLbyte(red), C.GLbyte(green), C.GLbyte(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBitmap.xml
+func (gl *GL) Bitmap(width, height int, xorig, yorig, xmove, ymove float32, bitmap []uint8) {
+ C.gl3_2compat_glBitmap(gl.funcs, C.GLsizei(width), C.GLsizei(height), C.GLfloat(xorig), C.GLfloat(yorig), C.GLfloat(xmove), C.GLfloat(ymove), (*C.GLubyte)(unsafe.Pointer(&bitmap[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBegin.xml
+func (gl *GL) Begin(mode glbase.Enum) {
+ C.gl3_2compat_glBegin(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glListBase.xml
+func (gl *GL) ListBase(base uint32) {
+ C.gl3_2compat_glListBase(gl.funcs, C.GLuint(base))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGenLists.xml
+func (gl *GL) GenLists(range_ int32) uint32 {
+ glresult := C.gl3_2compat_glGenLists(gl.funcs, C.GLsizei(range_))
+ return uint32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDeleteLists.xml
+func (gl *GL) DeleteLists(list uint32, range_ int32) {
+ C.gl3_2compat_glDeleteLists(gl.funcs, C.GLuint(list), C.GLsizei(range_))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCallLists.xml
+func (gl *GL) CallLists(n int, gltype glbase.Enum, lists interface{}) {
+ var lists_ptr unsafe.Pointer
+ var lists_v = reflect.ValueOf(lists)
+ if lists != nil && lists_v.Kind() != reflect.Slice {
+ panic("parameter lists must be a slice")
+ }
+ if lists != nil {
+ lists_ptr = unsafe.Pointer(lists_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2compat_glCallLists(gl.funcs, C.GLsizei(n), C.GLenum(gltype), lists_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCallList.xml
+func (gl *GL) CallList(list uint32) {
+ C.gl3_2compat_glCallList(gl.funcs, C.GLuint(list))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEndList.xml
+func (gl *GL) EndList() {
+ C.gl3_2compat_glEndList(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glNewList.xml
+func (gl *GL) NewList(list uint32, mode glbase.Enum) {
+ C.gl3_2compat_glNewList(gl.funcs, C.GLuint(list), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPushClientAttrib.xml
+func (gl *GL) PushClientAttrib(mask glbase.Bitfield) {
+ C.gl3_2compat_glPushClientAttrib(gl.funcs, C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPopClientAttrib.xml
+func (gl *GL) PopClientAttrib() {
+ C.gl3_2compat_glPopClientAttrib(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPrioritizeTextures.xml
+func (gl *GL) PrioritizeTextures(n int, textures []glbase.Texture, priorities []float32) {
+ C.gl3_2compat_glPrioritizeTextures(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])), (*C.GLfloat)(unsafe.Pointer(&priorities[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glAreTexturesResident.xml
+func (gl *GL) AreTexturesResident(n int, textures []glbase.Texture, residences []bool) bool {
+ glresult := C.gl3_2compat_glAreTexturesResident(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])), (*C.GLboolean)(unsafe.Pointer(&residences[0])))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexPointer.xml
+func (gl *GL) VertexPointer(size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2compat_glVertexPointer(gl.funcs, C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoordPointer.xml
+func (gl *GL) TexCoordPointer(size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2compat_glTexCoordPointer(gl.funcs, C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glNormalPointer.xml
+func (gl *GL) NormalPointer(gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2compat_glNormalPointer(gl.funcs, C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glInterleavedArrays.xml
+func (gl *GL) InterleavedArrays(format glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2compat_glInterleavedArrays(gl.funcs, C.GLenum(format), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIndexPointer.xml
+func (gl *GL) IndexPointer(gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2compat_glIndexPointer(gl.funcs, C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEnableClientState.xml
+func (gl *GL) EnableClientState(array glbase.Enum) {
+ C.gl3_2compat_glEnableClientState(gl.funcs, C.GLenum(array))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEdgeFlagPointer.xml
+func (gl *GL) EdgeFlagPointer(stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2compat_glEdgeFlagPointer(gl.funcs, C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDisableClientState.xml
+func (gl *GL) DisableClientState(array glbase.Enum) {
+ C.gl3_2compat_glDisableClientState(gl.funcs, C.GLenum(array))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColorPointer.xml
+func (gl *GL) ColorPointer(size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2compat_glColorPointer(gl.funcs, C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glArrayElement.xml
+func (gl *GL) ArrayElement(i int32) {
+ C.gl3_2compat_glArrayElement(gl.funcs, C.GLint(i))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glResetMinmax.xml
+func (gl *GL) ResetMinmax(target glbase.Enum) {
+ C.gl3_2compat_glResetMinmax(gl.funcs, C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glResetHistogram.xml
+func (gl *GL) ResetHistogram(target glbase.Enum) {
+ C.gl3_2compat_glResetHistogram(gl.funcs, C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMinmax.xml
+func (gl *GL) Minmax(target, internalFormat glbase.Enum, sink bool) {
+ C.gl3_2compat_glMinmax(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), *(*C.GLboolean)(unsafe.Pointer(&sink)))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glHistogram.xml
+func (gl *GL) Histogram(target glbase.Enum, width int, internalFormat glbase.Enum, sink bool) {
+ C.gl3_2compat_glHistogram(gl.funcs, C.GLenum(target), C.GLsizei(width), C.GLenum(internalFormat), *(*C.GLboolean)(unsafe.Pointer(&sink)))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetMinmaxParameteriv.xml
+func (gl *GL) GetMinmaxParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl3_2compat_glGetMinmaxParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetMinmaxParameterfv.xml
+func (gl *GL) GetMinmaxParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl3_2compat_glGetMinmaxParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetMinmax.xml
+func (gl *GL) GetMinmax(target glbase.Enum, reset bool, format, gltype glbase.Enum, values interface{}) {
+ var values_ptr unsafe.Pointer
+ var values_v = reflect.ValueOf(values)
+ if values != nil && values_v.Kind() != reflect.Slice {
+ panic("parameter values must be a slice")
+ }
+ if values != nil {
+ values_ptr = unsafe.Pointer(values_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2compat_glGetMinmax(gl.funcs, C.GLenum(target), *(*C.GLboolean)(unsafe.Pointer(&reset)), C.GLenum(format), C.GLenum(gltype), values_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetHistogramParameteriv.xml
+func (gl *GL) GetHistogramParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl3_2compat_glGetHistogramParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetHistogramParameterfv.xml
+func (gl *GL) GetHistogramParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl3_2compat_glGetHistogramParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetHistogram.xml
+func (gl *GL) GetHistogram(target glbase.Enum, reset bool, format, gltype glbase.Enum, values interface{}) {
+ var values_ptr unsafe.Pointer
+ var values_v = reflect.ValueOf(values)
+ if values != nil && values_v.Kind() != reflect.Slice {
+ panic("parameter values must be a slice")
+ }
+ if values != nil {
+ values_ptr = unsafe.Pointer(values_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2compat_glGetHistogram(gl.funcs, C.GLenum(target), *(*C.GLboolean)(unsafe.Pointer(&reset)), C.GLenum(format), C.GLenum(gltype), values_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSeparableFilter2D.xml
+func (gl *GL) SeparableFilter2D(target, internalFormat glbase.Enum, width, height int, format, gltype glbase.Enum, row, column interface{}) {
+ var row_ptr unsafe.Pointer
+ var row_v = reflect.ValueOf(row)
+ if row != nil && row_v.Kind() != reflect.Slice {
+ panic("parameter row must be a slice")
+ }
+ if row != nil {
+ row_ptr = unsafe.Pointer(row_v.Index(0).Addr().Pointer())
+ }
+ var column_ptr unsafe.Pointer
+ var column_v = reflect.ValueOf(column)
+ if column != nil && column_v.Kind() != reflect.Slice {
+ panic("parameter column must be a slice")
+ }
+ if column != nil {
+ column_ptr = unsafe.Pointer(column_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2compat_glSeparableFilter2D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), row_ptr, column_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetSeparableFilter.xml
+func (gl *GL) GetSeparableFilter(target, format, gltype glbase.Enum, row, column, span interface{}) {
+ var row_ptr unsafe.Pointer
+ var row_v = reflect.ValueOf(row)
+ if row != nil && row_v.Kind() != reflect.Slice {
+ panic("parameter row must be a slice")
+ }
+ if row != nil {
+ row_ptr = unsafe.Pointer(row_v.Index(0).Addr().Pointer())
+ }
+ var column_ptr unsafe.Pointer
+ var column_v = reflect.ValueOf(column)
+ if column != nil && column_v.Kind() != reflect.Slice {
+ panic("parameter column must be a slice")
+ }
+ if column != nil {
+ column_ptr = unsafe.Pointer(column_v.Index(0).Addr().Pointer())
+ }
+ var span_ptr unsafe.Pointer
+ var span_v = reflect.ValueOf(span)
+ if span != nil && span_v.Kind() != reflect.Slice {
+ panic("parameter span must be a slice")
+ }
+ if span != nil {
+ span_ptr = unsafe.Pointer(span_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2compat_glGetSeparableFilter(gl.funcs, C.GLenum(target), C.GLenum(format), C.GLenum(gltype), row_ptr, column_ptr, span_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetConvolutionParameteriv.xml
+func (gl *GL) GetConvolutionParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl3_2compat_glGetConvolutionParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetConvolutionParameterfv.xml
+func (gl *GL) GetConvolutionParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl3_2compat_glGetConvolutionParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetConvolutionFilter.xml
+func (gl *GL) GetConvolutionFilter(target, format, gltype glbase.Enum, image interface{}) {
+ var image_ptr unsafe.Pointer
+ var image_v = reflect.ValueOf(image)
+ if image != nil && image_v.Kind() != reflect.Slice {
+ panic("parameter image must be a slice")
+ }
+ if image != nil {
+ image_ptr = unsafe.Pointer(image_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2compat_glGetConvolutionFilter(gl.funcs, C.GLenum(target), C.GLenum(format), C.GLenum(gltype), image_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCopyConvolutionFilter2D.xml
+func (gl *GL) CopyConvolutionFilter2D(target, internalFormat glbase.Enum, x, y, width, height int) {
+ C.gl3_2compat_glCopyConvolutionFilter2D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCopyConvolutionFilter1D.xml
+func (gl *GL) CopyConvolutionFilter1D(target, internalFormat glbase.Enum, x, y, width int) {
+ C.gl3_2compat_glCopyConvolutionFilter1D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glConvolutionParameteriv.xml
+func (gl *GL) ConvolutionParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl3_2compat_glConvolutionParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glConvolutionParameteri.xml
+func (gl *GL) ConvolutionParameteri(target, pname glbase.Enum, params int32) {
+ C.gl3_2compat_glConvolutionParameteri(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLint(params))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glConvolutionParameterfv.xml
+func (gl *GL) ConvolutionParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl3_2compat_glConvolutionParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glConvolutionParameterf.xml
+func (gl *GL) ConvolutionParameterf(target, pname glbase.Enum, params float32) {
+ C.gl3_2compat_glConvolutionParameterf(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLfloat(params))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glConvolutionFilter2D.xml
+func (gl *GL) ConvolutionFilter2D(target, internalFormat glbase.Enum, width, height int, format, gltype glbase.Enum, image interface{}) {
+ var image_ptr unsafe.Pointer
+ var image_v = reflect.ValueOf(image)
+ if image != nil && image_v.Kind() != reflect.Slice {
+ panic("parameter image must be a slice")
+ }
+ if image != nil {
+ image_ptr = unsafe.Pointer(image_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2compat_glConvolutionFilter2D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), image_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glConvolutionFilter1D.xml
+func (gl *GL) ConvolutionFilter1D(target, internalFormat glbase.Enum, width int, format, gltype glbase.Enum, image interface{}) {
+ var image_ptr unsafe.Pointer
+ var image_v = reflect.ValueOf(image)
+ if image != nil && image_v.Kind() != reflect.Slice {
+ panic("parameter image must be a slice")
+ }
+ if image != nil {
+ image_ptr = unsafe.Pointer(image_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2compat_glConvolutionFilter1D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLenum(format), C.GLenum(gltype), image_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCopyColorSubTable.xml
+func (gl *GL) CopyColorSubTable(target glbase.Enum, start int32, x, y, width int) {
+ C.gl3_2compat_glCopyColorSubTable(gl.funcs, C.GLenum(target), C.GLsizei(start), C.GLint(x), C.GLint(y), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColorSubTable.xml
+func (gl *GL) ColorSubTable(target glbase.Enum, start int32, count int, format, gltype glbase.Enum, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2compat_glColorSubTable(gl.funcs, C.GLenum(target), C.GLsizei(start), C.GLsizei(count), C.GLenum(format), C.GLenum(gltype), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetColorTableParameteriv.xml
+func (gl *GL) GetColorTableParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl3_2compat_glGetColorTableParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetColorTableParameterfv.xml
+func (gl *GL) GetColorTableParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl3_2compat_glGetColorTableParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetColorTable.xml
+func (gl *GL) GetColorTable(target, format, gltype glbase.Enum, table interface{}) {
+ var table_ptr unsafe.Pointer
+ var table_v = reflect.ValueOf(table)
+ if table != nil && table_v.Kind() != reflect.Slice {
+ panic("parameter table must be a slice")
+ }
+ if table != nil {
+ table_ptr = unsafe.Pointer(table_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2compat_glGetColorTable(gl.funcs, C.GLenum(target), C.GLenum(format), C.GLenum(gltype), table_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCopyColorTable.xml
+func (gl *GL) CopyColorTable(target, internalFormat glbase.Enum, x, y, width int) {
+ C.gl3_2compat_glCopyColorTable(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColorTableParameteriv.xml
+func (gl *GL) ColorTableParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl3_2compat_glColorTableParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColorTableParameterfv.xml
+func (gl *GL) ColorTableParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl3_2compat_glColorTableParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColorTable.xml
+func (gl *GL) ColorTable(target, internalFormat glbase.Enum, width int, format, gltype glbase.Enum, table interface{}) {
+ var table_ptr unsafe.Pointer
+ var table_v = reflect.ValueOf(table)
+ if table != nil && table_v.Kind() != reflect.Slice {
+ panic("parameter table must be a slice")
+ }
+ if table != nil {
+ table_ptr = unsafe.Pointer(table_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2compat_glColorTable(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLenum(format), C.GLenum(gltype), table_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultTransposeMatrixd.xml
+func (gl *GL) MultTransposeMatrixd(m []float64) {
+ C.gl3_2compat_glMultTransposeMatrixd(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultTransposeMatrixf.xml
+func (gl *GL) MultTransposeMatrixf(m []float32) {
+ C.gl3_2compat_glMultTransposeMatrixf(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glLoadTransposeMatrixd.xml
+func (gl *GL) LoadTransposeMatrixd(m []float64) {
+ C.gl3_2compat_glLoadTransposeMatrixd(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glLoadTransposeMatrixf.xml
+func (gl *GL) LoadTransposeMatrixf(m []float32) {
+ C.gl3_2compat_glLoadTransposeMatrixf(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord4sv.xml
+func (gl *GL) MultiTexCoord4sv(target glbase.Enum, v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glMultiTexCoord4sv(gl.funcs, C.GLenum(target), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord4s.xml
+func (gl *GL) MultiTexCoord4s(target glbase.Enum, s, t, r, q int16) {
+ C.gl3_2compat_glMultiTexCoord4s(gl.funcs, C.GLenum(target), C.GLshort(s), C.GLshort(t), C.GLshort(r), C.GLshort(q))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord4iv.xml
+func (gl *GL) MultiTexCoord4iv(target glbase.Enum, v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glMultiTexCoord4iv(gl.funcs, C.GLenum(target), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord4i.xml
+func (gl *GL) MultiTexCoord4i(target glbase.Enum, s, t, r, q int32) {
+ C.gl3_2compat_glMultiTexCoord4i(gl.funcs, C.GLenum(target), C.GLint(s), C.GLint(t), C.GLint(r), C.GLint(q))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord4fv.xml
+func (gl *GL) MultiTexCoord4fv(target glbase.Enum, v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glMultiTexCoord4fv(gl.funcs, C.GLenum(target), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord4f.xml
+func (gl *GL) MultiTexCoord4f(target glbase.Enum, s, t, r, q float32) {
+ C.gl3_2compat_glMultiTexCoord4f(gl.funcs, C.GLenum(target), C.GLfloat(s), C.GLfloat(t), C.GLfloat(r), C.GLfloat(q))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord4dv.xml
+func (gl *GL) MultiTexCoord4dv(target glbase.Enum, v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glMultiTexCoord4dv(gl.funcs, C.GLenum(target), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord4d.xml
+func (gl *GL) MultiTexCoord4d(target glbase.Enum, s, t, r, q float64) {
+ C.gl3_2compat_glMultiTexCoord4d(gl.funcs, C.GLenum(target), C.GLdouble(s), C.GLdouble(t), C.GLdouble(r), C.GLdouble(q))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord3sv.xml
+func (gl *GL) MultiTexCoord3sv(target glbase.Enum, v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glMultiTexCoord3sv(gl.funcs, C.GLenum(target), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord3s.xml
+func (gl *GL) MultiTexCoord3s(target glbase.Enum, s, t, r int16) {
+ C.gl3_2compat_glMultiTexCoord3s(gl.funcs, C.GLenum(target), C.GLshort(s), C.GLshort(t), C.GLshort(r))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord3iv.xml
+func (gl *GL) MultiTexCoord3iv(target glbase.Enum, v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glMultiTexCoord3iv(gl.funcs, C.GLenum(target), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord3i.xml
+func (gl *GL) MultiTexCoord3i(target glbase.Enum, s, t, r int32) {
+ C.gl3_2compat_glMultiTexCoord3i(gl.funcs, C.GLenum(target), C.GLint(s), C.GLint(t), C.GLint(r))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord3fv.xml
+func (gl *GL) MultiTexCoord3fv(target glbase.Enum, v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glMultiTexCoord3fv(gl.funcs, C.GLenum(target), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord3f.xml
+func (gl *GL) MultiTexCoord3f(target glbase.Enum, s, t, r float32) {
+ C.gl3_2compat_glMultiTexCoord3f(gl.funcs, C.GLenum(target), C.GLfloat(s), C.GLfloat(t), C.GLfloat(r))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord3dv.xml
+func (gl *GL) MultiTexCoord3dv(target glbase.Enum, v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glMultiTexCoord3dv(gl.funcs, C.GLenum(target), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord3d.xml
+func (gl *GL) MultiTexCoord3d(target glbase.Enum, s, t, r float64) {
+ C.gl3_2compat_glMultiTexCoord3d(gl.funcs, C.GLenum(target), C.GLdouble(s), C.GLdouble(t), C.GLdouble(r))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord2sv.xml
+func (gl *GL) MultiTexCoord2sv(target glbase.Enum, v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glMultiTexCoord2sv(gl.funcs, C.GLenum(target), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord2s.xml
+func (gl *GL) MultiTexCoord2s(target glbase.Enum, s, t int16) {
+ C.gl3_2compat_glMultiTexCoord2s(gl.funcs, C.GLenum(target), C.GLshort(s), C.GLshort(t))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord2iv.xml
+func (gl *GL) MultiTexCoord2iv(target glbase.Enum, v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glMultiTexCoord2iv(gl.funcs, C.GLenum(target), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord2i.xml
+func (gl *GL) MultiTexCoord2i(target glbase.Enum, s, t int32) {
+ C.gl3_2compat_glMultiTexCoord2i(gl.funcs, C.GLenum(target), C.GLint(s), C.GLint(t))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord2fv.xml
+func (gl *GL) MultiTexCoord2fv(target glbase.Enum, v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glMultiTexCoord2fv(gl.funcs, C.GLenum(target), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord2f.xml
+func (gl *GL) MultiTexCoord2f(target glbase.Enum, s, t float32) {
+ C.gl3_2compat_glMultiTexCoord2f(gl.funcs, C.GLenum(target), C.GLfloat(s), C.GLfloat(t))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord2dv.xml
+func (gl *GL) MultiTexCoord2dv(target glbase.Enum, v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glMultiTexCoord2dv(gl.funcs, C.GLenum(target), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord2d.xml
+func (gl *GL) MultiTexCoord2d(target glbase.Enum, s, t float64) {
+ C.gl3_2compat_glMultiTexCoord2d(gl.funcs, C.GLenum(target), C.GLdouble(s), C.GLdouble(t))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord1sv.xml
+func (gl *GL) MultiTexCoord1sv(target glbase.Enum, v []int16) {
+ C.gl3_2compat_glMultiTexCoord1sv(gl.funcs, C.GLenum(target), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord1s.xml
+func (gl *GL) MultiTexCoord1s(target glbase.Enum, s int16) {
+ C.gl3_2compat_glMultiTexCoord1s(gl.funcs, C.GLenum(target), C.GLshort(s))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord1iv.xml
+func (gl *GL) MultiTexCoord1iv(target glbase.Enum, v []int32) {
+ C.gl3_2compat_glMultiTexCoord1iv(gl.funcs, C.GLenum(target), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord1i.xml
+func (gl *GL) MultiTexCoord1i(target glbase.Enum, s int32) {
+ C.gl3_2compat_glMultiTexCoord1i(gl.funcs, C.GLenum(target), C.GLint(s))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord1fv.xml
+func (gl *GL) MultiTexCoord1fv(target glbase.Enum, v []float32) {
+ C.gl3_2compat_glMultiTexCoord1fv(gl.funcs, C.GLenum(target), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord1f.xml
+func (gl *GL) MultiTexCoord1f(target glbase.Enum, s float32) {
+ C.gl3_2compat_glMultiTexCoord1f(gl.funcs, C.GLenum(target), C.GLfloat(s))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord1dv.xml
+func (gl *GL) MultiTexCoord1dv(target glbase.Enum, v []float64) {
+ C.gl3_2compat_glMultiTexCoord1dv(gl.funcs, C.GLenum(target), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord1d.xml
+func (gl *GL) MultiTexCoord1d(target glbase.Enum, s float64) {
+ C.gl3_2compat_glMultiTexCoord1d(gl.funcs, C.GLenum(target), C.GLdouble(s))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClientActiveTexture.xml
+func (gl *GL) ClientActiveTexture(texture glbase.Enum) {
+ C.gl3_2compat_glClientActiveTexture(gl.funcs, C.GLenum(texture))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glWindowPos3sv.xml
+func (gl *GL) WindowPos3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glWindowPos3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glWindowPos3s.xml
+func (gl *GL) WindowPos3s(x, y, z int16) {
+ C.gl3_2compat_glWindowPos3s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glWindowPos3iv.xml
+func (gl *GL) WindowPos3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glWindowPos3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glWindowPos3i.xml
+func (gl *GL) WindowPos3i(x, y, z int) {
+ C.gl3_2compat_glWindowPos3i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glWindowPos3fv.xml
+func (gl *GL) WindowPos3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glWindowPos3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glWindowPos3f.xml
+func (gl *GL) WindowPos3f(x, y, z float32) {
+ C.gl3_2compat_glWindowPos3f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glWindowPos3dv.xml
+func (gl *GL) WindowPos3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glWindowPos3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glWindowPos3d.xml
+func (gl *GL) WindowPos3d(x, y, z float64) {
+ C.gl3_2compat_glWindowPos3d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glWindowPos2sv.xml
+func (gl *GL) WindowPos2sv(v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glWindowPos2sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glWindowPos2s.xml
+func (gl *GL) WindowPos2s(x, y int16) {
+ C.gl3_2compat_glWindowPos2s(gl.funcs, C.GLshort(x), C.GLshort(y))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glWindowPos2iv.xml
+func (gl *GL) WindowPos2iv(v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glWindowPos2iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glWindowPos2i.xml
+func (gl *GL) WindowPos2i(x, y int) {
+ C.gl3_2compat_glWindowPos2i(gl.funcs, C.GLint(x), C.GLint(y))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glWindowPos2fv.xml
+func (gl *GL) WindowPos2fv(v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glWindowPos2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glWindowPos2f.xml
+func (gl *GL) WindowPos2f(x, y float32) {
+ C.gl3_2compat_glWindowPos2f(gl.funcs, C.GLfloat(x), C.GLfloat(y))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glWindowPos2dv.xml
+func (gl *GL) WindowPos2dv(v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glWindowPos2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glWindowPos2d.xml
+func (gl *GL) WindowPos2d(x, y float64) {
+ C.gl3_2compat_glWindowPos2d(gl.funcs, C.GLdouble(x), C.GLdouble(y))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSecondaryColorPointer.xml
+func (gl *GL) SecondaryColorPointer(size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2compat_glSecondaryColorPointer(gl.funcs, C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSecondaryColor3usv.xml
+func (gl *GL) SecondaryColor3usv(v []uint16) {
+ C.gl3_2compat_glSecondaryColor3usv(gl.funcs, (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSecondaryColor3us.xml
+func (gl *GL) SecondaryColor3us(red, green, blue uint16) {
+ C.gl3_2compat_glSecondaryColor3us(gl.funcs, C.GLushort(red), C.GLushort(green), C.GLushort(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSecondaryColor3uiv.xml
+func (gl *GL) SecondaryColor3uiv(v []uint32) {
+ C.gl3_2compat_glSecondaryColor3uiv(gl.funcs, (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSecondaryColor3ui.xml
+func (gl *GL) SecondaryColor3ui(red, green, blue uint32) {
+ C.gl3_2compat_glSecondaryColor3ui(gl.funcs, C.GLuint(red), C.GLuint(green), C.GLuint(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSecondaryColor3ubv.xml
+func (gl *GL) SecondaryColor3ubv(v []uint8) {
+ C.gl3_2compat_glSecondaryColor3ubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSecondaryColor3ub.xml
+func (gl *GL) SecondaryColor3ub(red, green, blue uint8) {
+ C.gl3_2compat_glSecondaryColor3ub(gl.funcs, C.GLubyte(red), C.GLubyte(green), C.GLubyte(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSecondaryColor3sv.xml
+func (gl *GL) SecondaryColor3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glSecondaryColor3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSecondaryColor3s.xml
+func (gl *GL) SecondaryColor3s(red, green, blue int16) {
+ C.gl3_2compat_glSecondaryColor3s(gl.funcs, C.GLshort(red), C.GLshort(green), C.GLshort(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSecondaryColor3iv.xml
+func (gl *GL) SecondaryColor3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glSecondaryColor3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSecondaryColor3i.xml
+func (gl *GL) SecondaryColor3i(red, green, blue int32) {
+ C.gl3_2compat_glSecondaryColor3i(gl.funcs, C.GLint(red), C.GLint(green), C.GLint(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSecondaryColor3fv.xml
+func (gl *GL) SecondaryColor3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glSecondaryColor3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSecondaryColor3f.xml
+func (gl *GL) SecondaryColor3f(red, green, blue float32) {
+ C.gl3_2compat_glSecondaryColor3f(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSecondaryColor3dv.xml
+func (gl *GL) SecondaryColor3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glSecondaryColor3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSecondaryColor3d.xml
+func (gl *GL) SecondaryColor3d(red, green, blue float64) {
+ C.gl3_2compat_glSecondaryColor3d(gl.funcs, C.GLdouble(red), C.GLdouble(green), C.GLdouble(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSecondaryColor3bv.xml
+func (gl *GL) SecondaryColor3bv(v []byte) {
+ C.gl3_2compat_glSecondaryColor3bv(gl.funcs, (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSecondaryColor3b.xml
+func (gl *GL) SecondaryColor3b(red, green, blue byte) {
+ C.gl3_2compat_glSecondaryColor3b(gl.funcs, C.GLbyte(red), C.GLbyte(green), C.GLbyte(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFogCoordPointer.xml
+func (gl *GL) FogCoordPointer(gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2compat_glFogCoordPointer(gl.funcs, C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFogCoorddv.xml
+func (gl *GL) FogCoorddv(coord []float64) {
+ C.gl3_2compat_glFogCoorddv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&coord[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFogCoordd.xml
+func (gl *GL) FogCoordd(coord float64) {
+ C.gl3_2compat_glFogCoordd(gl.funcs, C.GLdouble(coord))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFogCoordfv.xml
+func (gl *GL) FogCoordfv(coord []float32) {
+ C.gl3_2compat_glFogCoordfv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&coord[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFogCoordf.xml
+func (gl *GL) FogCoordf(coord float32) {
+ C.gl3_2compat_glFogCoordf(gl.funcs, C.GLfloat(coord))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib4usv.xml
+func (gl *GL) VertexAttrib4usv(index glbase.Attrib, v []uint16) {
+ C.gl3_2compat_glVertexAttrib4usv(gl.funcs, C.GLuint(index), (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib4uiv.xml
+func (gl *GL) VertexAttrib4uiv(index glbase.Attrib, v []uint32) {
+ C.gl3_2compat_glVertexAttrib4uiv(gl.funcs, C.GLuint(index), (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib4ubv.xml
+func (gl *GL) VertexAttrib4ubv(index glbase.Attrib, v []uint8) {
+ C.gl3_2compat_glVertexAttrib4ubv(gl.funcs, C.GLuint(index), (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib4sv.xml
+func (gl *GL) VertexAttrib4sv(index glbase.Attrib, v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glVertexAttrib4sv(gl.funcs, C.GLuint(index), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib4s.xml
+func (gl *GL) VertexAttrib4s(index glbase.Attrib, x, y, z, w int16) {
+ C.gl3_2compat_glVertexAttrib4s(gl.funcs, C.GLuint(index), C.GLshort(x), C.GLshort(y), C.GLshort(z), C.GLshort(w))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib4iv.xml
+func (gl *GL) VertexAttrib4iv(index glbase.Attrib, v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glVertexAttrib4iv(gl.funcs, C.GLuint(index), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib4fv.xml
+func (gl *GL) VertexAttrib4fv(index glbase.Attrib, v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glVertexAttrib4fv(gl.funcs, C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib4f.xml
+func (gl *GL) VertexAttrib4f(index glbase.Attrib, x, y, z, w float32) {
+ C.gl3_2compat_glVertexAttrib4f(gl.funcs, C.GLuint(index), C.GLfloat(x), C.GLfloat(y), C.GLfloat(z), C.GLfloat(w))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib4dv.xml
+func (gl *GL) VertexAttrib4dv(index glbase.Attrib, v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glVertexAttrib4dv(gl.funcs, C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib4d.xml
+func (gl *GL) VertexAttrib4d(index glbase.Attrib, x, y, z, w float64) {
+ C.gl3_2compat_glVertexAttrib4d(gl.funcs, C.GLuint(index), C.GLdouble(x), C.GLdouble(y), C.GLdouble(z), C.GLdouble(w))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib4bv.xml
+func (gl *GL) VertexAttrib4bv(index glbase.Attrib, v []byte) {
+ C.gl3_2compat_glVertexAttrib4bv(gl.funcs, C.GLuint(index), (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib4Nusv.xml
+func (gl *GL) VertexAttrib4Nusv(index glbase.Attrib, v []uint16) {
+ C.gl3_2compat_glVertexAttrib4Nusv(gl.funcs, C.GLuint(index), (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib4Nuiv.xml
+func (gl *GL) VertexAttrib4Nuiv(index glbase.Attrib, v []uint32) {
+ C.gl3_2compat_glVertexAttrib4Nuiv(gl.funcs, C.GLuint(index), (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib4Nubv.xml
+func (gl *GL) VertexAttrib4Nubv(index glbase.Attrib, v []uint8) {
+ C.gl3_2compat_glVertexAttrib4Nubv(gl.funcs, C.GLuint(index), (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib4Nub.xml
+func (gl *GL) VertexAttrib4Nub(index glbase.Attrib, x, y, z, w uint8) {
+ C.gl3_2compat_glVertexAttrib4Nub(gl.funcs, C.GLuint(index), C.GLubyte(x), C.GLubyte(y), C.GLubyte(z), C.GLubyte(w))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib4Nsv.xml
+func (gl *GL) VertexAttrib4Nsv(index glbase.Attrib, v []int16) {
+ C.gl3_2compat_glVertexAttrib4Nsv(gl.funcs, C.GLuint(index), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib4Niv.xml
+func (gl *GL) VertexAttrib4Niv(index glbase.Attrib, v []int32) {
+ C.gl3_2compat_glVertexAttrib4Niv(gl.funcs, C.GLuint(index), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib4Nbv.xml
+func (gl *GL) VertexAttrib4Nbv(index glbase.Attrib, v []byte) {
+ C.gl3_2compat_glVertexAttrib4Nbv(gl.funcs, C.GLuint(index), (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib3sv.xml
+func (gl *GL) VertexAttrib3sv(index glbase.Attrib, v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glVertexAttrib3sv(gl.funcs, C.GLuint(index), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib3s.xml
+func (gl *GL) VertexAttrib3s(index glbase.Attrib, x, y, z int16) {
+ C.gl3_2compat_glVertexAttrib3s(gl.funcs, C.GLuint(index), C.GLshort(x), C.GLshort(y), C.GLshort(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib3fv.xml
+func (gl *GL) VertexAttrib3fv(index glbase.Attrib, v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glVertexAttrib3fv(gl.funcs, C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib3f.xml
+func (gl *GL) VertexAttrib3f(index glbase.Attrib, x, y, z float32) {
+ C.gl3_2compat_glVertexAttrib3f(gl.funcs, C.GLuint(index), C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib3dv.xml
+func (gl *GL) VertexAttrib3dv(index glbase.Attrib, v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glVertexAttrib3dv(gl.funcs, C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib3d.xml
+func (gl *GL) VertexAttrib3d(index glbase.Attrib, x, y, z float64) {
+ C.gl3_2compat_glVertexAttrib3d(gl.funcs, C.GLuint(index), C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib2sv.xml
+func (gl *GL) VertexAttrib2sv(index glbase.Attrib, v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glVertexAttrib2sv(gl.funcs, C.GLuint(index), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib2s.xml
+func (gl *GL) VertexAttrib2s(index glbase.Attrib, x, y int16) {
+ C.gl3_2compat_glVertexAttrib2s(gl.funcs, C.GLuint(index), C.GLshort(x), C.GLshort(y))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib2fv.xml
+func (gl *GL) VertexAttrib2fv(index glbase.Attrib, v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glVertexAttrib2fv(gl.funcs, C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib2f.xml
+func (gl *GL) VertexAttrib2f(index glbase.Attrib, x, y float32) {
+ C.gl3_2compat_glVertexAttrib2f(gl.funcs, C.GLuint(index), C.GLfloat(x), C.GLfloat(y))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib2dv.xml
+func (gl *GL) VertexAttrib2dv(index glbase.Attrib, v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glVertexAttrib2dv(gl.funcs, C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib2d.xml
+func (gl *GL) VertexAttrib2d(index glbase.Attrib, x, y float64) {
+ C.gl3_2compat_glVertexAttrib2d(gl.funcs, C.GLuint(index), C.GLdouble(x), C.GLdouble(y))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib1sv.xml
+func (gl *GL) VertexAttrib1sv(index glbase.Attrib, v []int16) {
+ C.gl3_2compat_glVertexAttrib1sv(gl.funcs, C.GLuint(index), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib1s.xml
+func (gl *GL) VertexAttrib1s(index glbase.Attrib, x int16) {
+ C.gl3_2compat_glVertexAttrib1s(gl.funcs, C.GLuint(index), C.GLshort(x))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib1fv.xml
+func (gl *GL) VertexAttrib1fv(index glbase.Attrib, v []float32) {
+ C.gl3_2compat_glVertexAttrib1fv(gl.funcs, C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib1f.xml
+func (gl *GL) VertexAttrib1f(index glbase.Attrib, x float32) {
+ C.gl3_2compat_glVertexAttrib1f(gl.funcs, C.GLuint(index), C.GLfloat(x))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib1dv.xml
+func (gl *GL) VertexAttrib1dv(index glbase.Attrib, v []float64) {
+ C.gl3_2compat_glVertexAttrib1dv(gl.funcs, C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib1d.xml
+func (gl *GL) VertexAttrib1d(index glbase.Attrib, x float64) {
+ C.gl3_2compat_glVertexAttrib1d(gl.funcs, C.GLuint(index), C.GLdouble(x))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribI4usv.xml
+func (gl *GL) VertexAttribI4usv(index glbase.Attrib, v []uint16) {
+ C.gl3_2compat_glVertexAttribI4usv(gl.funcs, C.GLuint(index), (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribI4ubv.xml
+func (gl *GL) VertexAttribI4ubv(index glbase.Attrib, v []uint8) {
+ C.gl3_2compat_glVertexAttribI4ubv(gl.funcs, C.GLuint(index), (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribI4sv.xml
+func (gl *GL) VertexAttribI4sv(index glbase.Attrib, v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glVertexAttribI4sv(gl.funcs, C.GLuint(index), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribI4bv.xml
+func (gl *GL) VertexAttribI4bv(index glbase.Attrib, v []byte) {
+ C.gl3_2compat_glVertexAttribI4bv(gl.funcs, C.GLuint(index), (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribI4uiv.xml
+func (gl *GL) VertexAttribI4uiv(index glbase.Attrib, v []uint32) {
+ C.gl3_2compat_glVertexAttribI4uiv(gl.funcs, C.GLuint(index), (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribI3uiv.xml
+func (gl *GL) VertexAttribI3uiv(index glbase.Attrib, v []uint32) {
+ C.gl3_2compat_glVertexAttribI3uiv(gl.funcs, C.GLuint(index), (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribI2uiv.xml
+func (gl *GL) VertexAttribI2uiv(index glbase.Attrib, v []uint32) {
+ C.gl3_2compat_glVertexAttribI2uiv(gl.funcs, C.GLuint(index), (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribI1uiv.xml
+func (gl *GL) VertexAttribI1uiv(index glbase.Attrib, v []uint32) {
+ C.gl3_2compat_glVertexAttribI1uiv(gl.funcs, C.GLuint(index), (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribI4iv.xml
+func (gl *GL) VertexAttribI4iv(index glbase.Attrib, v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glVertexAttribI4iv(gl.funcs, C.GLuint(index), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribI3iv.xml
+func (gl *GL) VertexAttribI3iv(index glbase.Attrib, v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glVertexAttribI3iv(gl.funcs, C.GLuint(index), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribI2iv.xml
+func (gl *GL) VertexAttribI2iv(index glbase.Attrib, v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_2compat_glVertexAttribI2iv(gl.funcs, C.GLuint(index), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribI1iv.xml
+func (gl *GL) VertexAttribI1iv(index glbase.Attrib, v []int32) {
+ C.gl3_2compat_glVertexAttribI1iv(gl.funcs, C.GLuint(index), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribI4ui.xml
+func (gl *GL) VertexAttribI4ui(index glbase.Attrib, x, y, z, w uint32) {
+ C.gl3_2compat_glVertexAttribI4ui(gl.funcs, C.GLuint(index), C.GLuint(x), C.GLuint(y), C.GLuint(z), C.GLuint(w))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribI3ui.xml
+func (gl *GL) VertexAttribI3ui(index glbase.Attrib, x, y, z uint32) {
+ C.gl3_2compat_glVertexAttribI3ui(gl.funcs, C.GLuint(index), C.GLuint(x), C.GLuint(y), C.GLuint(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribI2ui.xml
+func (gl *GL) VertexAttribI2ui(index glbase.Attrib, x, y uint32) {
+ C.gl3_2compat_glVertexAttribI2ui(gl.funcs, C.GLuint(index), C.GLuint(x), C.GLuint(y))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribI1ui.xml
+func (gl *GL) VertexAttribI1ui(index glbase.Attrib, x uint32) {
+ C.gl3_2compat_glVertexAttribI1ui(gl.funcs, C.GLuint(index), C.GLuint(x))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribI4i.xml
+func (gl *GL) VertexAttribI4i(index glbase.Attrib, x, y, z, w int) {
+ C.gl3_2compat_glVertexAttribI4i(gl.funcs, C.GLuint(index), C.GLint(x), C.GLint(y), C.GLint(z), C.GLint(w))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribI3i.xml
+func (gl *GL) VertexAttribI3i(index glbase.Attrib, x, y, z int) {
+ C.gl3_2compat_glVertexAttribI3i(gl.funcs, C.GLuint(index), C.GLint(x), C.GLint(y), C.GLint(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribI2i.xml
+func (gl *GL) VertexAttribI2i(index glbase.Attrib, x, y int) {
+ C.gl3_2compat_glVertexAttribI2i(gl.funcs, C.GLuint(index), C.GLint(x), C.GLint(y))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribI1i.xml
+func (gl *GL) VertexAttribI1i(index glbase.Attrib, x int) {
+ C.gl3_2compat_glVertexAttribI1i(gl.funcs, C.GLuint(index), C.GLint(x))
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/3.2core/funcs.cpp b/Godeps/_workspace/src/github.com/obscuren/qml/gl/3.2core/funcs.cpp
new file mode 100644
index 000000000..adacb68e1
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/3.2core/funcs.cpp
@@ -0,0 +1,1530 @@
+
+// ** file automatically generated by glgen -- do not edit manually **
+
+#include <QOpenGLContext>
+#include <QtGui/qopenglfunctions_3_2_core.h>
+
+#include "funcs.h"
+
+void *gl3_2core_funcs() {
+ QOpenGLFunctions_3_2_Core* funcs = QOpenGLContext::currentContext()->versionFunctions<QOpenGLFunctions_3_2_Core>();
+ if (!funcs) {
+ return 0;
+ }
+ funcs->initializeOpenGLFunctions();
+ return funcs;
+}
+
+
+void gl3_2core_glViewport(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glViewport(x, y, width, height);
+}
+
+void gl3_2core_glDepthRange(void *_glfuncs, GLdouble nearVal, GLdouble farVal)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glDepthRange(nearVal, farVal);
+}
+
+GLboolean gl3_2core_glIsEnabled(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ return _qglfuncs->glIsEnabled(cap);
+}
+
+void gl3_2core_glGetTexLevelParameteriv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glGetTexLevelParameteriv(target, level, pname, params);
+}
+
+void gl3_2core_glGetTexLevelParameterfv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glGetTexLevelParameterfv(target, level, pname, params);
+}
+
+void gl3_2core_glGetTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glGetTexParameteriv(target, pname, params);
+}
+
+void gl3_2core_glGetTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glGetTexParameterfv(target, pname, params);
+}
+
+void gl3_2core_glGetTexImage(void *_glfuncs, GLenum target, GLint level, GLenum format, GLenum gltype, GLvoid* pixels)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glGetTexImage(target, level, format, gltype, pixels);
+}
+
+void gl3_2core_glGetIntegerv(void *_glfuncs, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glGetIntegerv(pname, params);
+}
+
+void gl3_2core_glGetFloatv(void *_glfuncs, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glGetFloatv(pname, params);
+}
+
+GLenum gl3_2core_glGetError(void *_glfuncs)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ return _qglfuncs->glGetError();
+}
+
+void gl3_2core_glGetDoublev(void *_glfuncs, GLenum pname, GLdouble* params)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glGetDoublev(pname, params);
+}
+
+void gl3_2core_glGetBooleanv(void *_glfuncs, GLenum pname, GLboolean* params)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glGetBooleanv(pname, params);
+}
+
+void gl3_2core_glReadPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum gltype, GLvoid* pixels)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glReadPixels(x, y, width, height, format, gltype, pixels);
+}
+
+void gl3_2core_glReadBuffer(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glReadBuffer(mode);
+}
+
+void gl3_2core_glPixelStorei(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glPixelStorei(pname, param);
+}
+
+void gl3_2core_glPixelStoref(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glPixelStoref(pname, param);
+}
+
+void gl3_2core_glDepthFunc(void *_glfuncs, GLenum glfunc)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glDepthFunc(glfunc);
+}
+
+void gl3_2core_glStencilOp(void *_glfuncs, GLenum fail, GLenum zfail, GLenum zpass)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glStencilOp(fail, zfail, zpass);
+}
+
+void gl3_2core_glStencilFunc(void *_glfuncs, GLenum glfunc, GLint ref, GLuint mask)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glStencilFunc(glfunc, ref, mask);
+}
+
+void gl3_2core_glLogicOp(void *_glfuncs, GLenum opcode)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glLogicOp(opcode);
+}
+
+void gl3_2core_glBlendFunc(void *_glfuncs, GLenum sfactor, GLenum dfactor)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glBlendFunc(sfactor, dfactor);
+}
+
+void gl3_2core_glFlush(void *_glfuncs)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glFlush();
+}
+
+void gl3_2core_glFinish(void *_glfuncs)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glFinish();
+}
+
+void gl3_2core_glEnable(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glEnable(cap);
+}
+
+void gl3_2core_glDisable(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glDisable(cap);
+}
+
+void gl3_2core_glDepthMask(void *_glfuncs, GLboolean flag)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glDepthMask(flag);
+}
+
+void gl3_2core_glColorMask(void *_glfuncs, GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glColorMask(red, green, blue, alpha);
+}
+
+void gl3_2core_glStencilMask(void *_glfuncs, GLuint mask)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glStencilMask(mask);
+}
+
+void gl3_2core_glClearDepth(void *_glfuncs, GLdouble depth)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glClearDepth(depth);
+}
+
+void gl3_2core_glClearStencil(void *_glfuncs, GLint s)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glClearStencil(s);
+}
+
+void gl3_2core_glClearColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glClearColor(red, green, blue, alpha);
+}
+
+void gl3_2core_glClear(void *_glfuncs, GLbitfield mask)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glClear(mask);
+}
+
+void gl3_2core_glDrawBuffer(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glDrawBuffer(mode);
+}
+
+void gl3_2core_glTexImage2D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glTexImage2D(target, level, internalFormat, width, height, border, format, gltype, pixels);
+}
+
+void gl3_2core_glTexImage1D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glTexImage1D(target, level, internalFormat, width, border, format, gltype, pixels);
+}
+
+void gl3_2core_glTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glTexParameteriv(target, pname, params);
+}
+
+void gl3_2core_glTexParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glTexParameteri(target, pname, param);
+}
+
+void gl3_2core_glTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glTexParameterfv(target, pname, params);
+}
+
+void gl3_2core_glTexParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glTexParameterf(target, pname, param);
+}
+
+void gl3_2core_glScissor(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glScissor(x, y, width, height);
+}
+
+void gl3_2core_glPolygonMode(void *_glfuncs, GLenum face, GLenum mode)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glPolygonMode(face, mode);
+}
+
+void gl3_2core_glPointSize(void *_glfuncs, GLfloat size)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glPointSize(size);
+}
+
+void gl3_2core_glLineWidth(void *_glfuncs, GLfloat width)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glLineWidth(width);
+}
+
+void gl3_2core_glHint(void *_glfuncs, GLenum target, GLenum mode)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glHint(target, mode);
+}
+
+void gl3_2core_glFrontFace(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glFrontFace(mode);
+}
+
+void gl3_2core_glCullFace(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glCullFace(mode);
+}
+
+void gl3_2core_glIndexubv(void *_glfuncs, const GLubyte* c)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glIndexubv(c);
+}
+
+void gl3_2core_glIndexub(void *_glfuncs, GLubyte c)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glIndexub(c);
+}
+
+GLboolean gl3_2core_glIsTexture(void *_glfuncs, GLuint texture)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ return _qglfuncs->glIsTexture(texture);
+}
+
+void gl3_2core_glGenTextures(void *_glfuncs, GLsizei n, GLuint* textures)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glGenTextures(n, textures);
+}
+
+void gl3_2core_glDeleteTextures(void *_glfuncs, GLsizei n, const GLuint* textures)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glDeleteTextures(n, textures);
+}
+
+void gl3_2core_glBindTexture(void *_glfuncs, GLenum target, GLuint texture)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glBindTexture(target, texture);
+}
+
+void gl3_2core_glTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glTexSubImage2D(target, level, xoffset, yoffset, width, height, format, gltype, pixels);
+}
+
+void gl3_2core_glTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glTexSubImage1D(target, level, xoffset, width, format, gltype, pixels);
+}
+
+void gl3_2core_glCopyTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage2D(target, level, xoffset, yoffset, x, y, width, height);
+}
+
+void gl3_2core_glCopyTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage1D(target, level, xoffset, x, y, width);
+}
+
+void gl3_2core_glCopyTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glCopyTexImage2D(target, level, internalFormat, x, y, width, height, border);
+}
+
+void gl3_2core_glCopyTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLint border)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glCopyTexImage1D(target, level, internalFormat, x, y, width, border);
+}
+
+void gl3_2core_glPolygonOffset(void *_glfuncs, GLfloat factor, GLfloat units)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glPolygonOffset(factor, units);
+}
+
+void gl3_2core_glDrawElements(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glDrawElements(mode, count, gltype, indices);
+}
+
+void gl3_2core_glDrawArrays(void *_glfuncs, GLenum mode, GLint first, GLsizei count)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glDrawArrays(mode, first, count);
+}
+
+void gl3_2core_glCopyTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage3D(target, level, xoffset, yoffset, zoffset, x, y, width, height);
+}
+
+void gl3_2core_glTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glTexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, gltype, pixels);
+}
+
+void gl3_2core_glTexImage3D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glTexImage3D(target, level, internalFormat, width, height, depth, border, format, gltype, pixels);
+}
+
+void gl3_2core_glDrawRangeElements(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glDrawRangeElements(mode, start, end, count, gltype, indices);
+}
+
+void gl3_2core_glBlendEquation(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glBlendEquation(mode);
+}
+
+void gl3_2core_glBlendColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glBlendColor(red, green, blue, alpha);
+}
+
+void gl3_2core_glGetCompressedTexImage(void *_glfuncs, GLenum target, GLint level, GLvoid* img)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glGetCompressedTexImage(target, level, img);
+}
+
+void gl3_2core_glCompressedTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glCompressedTexSubImage1D(target, level, xoffset, width, format, imageSize, data);
+}
+
+void gl3_2core_glCompressedTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glCompressedTexSubImage2D(target, level, xoffset, yoffset, width, height, format, imageSize, data);
+}
+
+void gl3_2core_glCompressedTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glCompressedTexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, imageSize, data);
+}
+
+void gl3_2core_glCompressedTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glCompressedTexImage1D(target, level, internalFormat, width, border, imageSize, data);
+}
+
+void gl3_2core_glCompressedTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glCompressedTexImage2D(target, level, internalFormat, width, height, border, imageSize, data);
+}
+
+void gl3_2core_glCompressedTexImage3D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glCompressedTexImage3D(target, level, internalFormat, width, height, depth, border, imageSize, data);
+}
+
+void gl3_2core_glSampleCoverage(void *_glfuncs, GLfloat value, GLboolean invert)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glSampleCoverage(value, invert);
+}
+
+void gl3_2core_glActiveTexture(void *_glfuncs, GLenum texture)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glActiveTexture(texture);
+}
+
+void gl3_2core_glPointParameteriv(void *_glfuncs, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glPointParameteriv(pname, params);
+}
+
+void gl3_2core_glPointParameteri(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glPointParameteri(pname, param);
+}
+
+void gl3_2core_glPointParameterfv(void *_glfuncs, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glPointParameterfv(pname, params);
+}
+
+void gl3_2core_glPointParameterf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glPointParameterf(pname, param);
+}
+
+void gl3_2core_glMultiDrawArrays(void *_glfuncs, GLenum mode, const GLint* first, const GLsizei* count, GLsizei drawcount)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glMultiDrawArrays(mode, first, count, drawcount);
+}
+
+void gl3_2core_glBlendFuncSeparate(void *_glfuncs, GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glBlendFuncSeparate(sfactorRGB, dfactorRGB, sfactorAlpha, dfactorAlpha);
+}
+
+void gl3_2core_glGetBufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glGetBufferParameteriv(target, pname, params);
+}
+
+GLboolean gl3_2core_glUnmapBuffer(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ return _qglfuncs->glUnmapBuffer(target);
+}
+
+void gl3_2core_glGetBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, GLvoid* data)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glGetBufferSubData(target, offset, size, data);
+}
+
+void gl3_2core_glBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid* data)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glBufferSubData(target, offset, size, data);
+}
+
+void gl3_2core_glBufferData(void *_glfuncs, GLenum target, GLsizeiptr size, const GLvoid* data, GLenum usage)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glBufferData(target, size, data, usage);
+}
+
+GLboolean gl3_2core_glIsBuffer(void *_glfuncs, GLuint buffer)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ return _qglfuncs->glIsBuffer(buffer);
+}
+
+void gl3_2core_glGenBuffers(void *_glfuncs, GLsizei n, GLuint* buffers)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glGenBuffers(n, buffers);
+}
+
+void gl3_2core_glDeleteBuffers(void *_glfuncs, GLsizei n, const GLuint* buffers)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glDeleteBuffers(n, buffers);
+}
+
+void gl3_2core_glBindBuffer(void *_glfuncs, GLenum target, GLuint buffer)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glBindBuffer(target, buffer);
+}
+
+void gl3_2core_glGetQueryObjectuiv(void *_glfuncs, GLuint id, GLenum pname, GLuint* params)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glGetQueryObjectuiv(id, pname, params);
+}
+
+void gl3_2core_glGetQueryObjectiv(void *_glfuncs, GLuint id, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glGetQueryObjectiv(id, pname, params);
+}
+
+void gl3_2core_glGetQueryiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glGetQueryiv(target, pname, params);
+}
+
+void gl3_2core_glEndQuery(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glEndQuery(target);
+}
+
+void gl3_2core_glBeginQuery(void *_glfuncs, GLenum target, GLuint id)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glBeginQuery(target, id);
+}
+
+GLboolean gl3_2core_glIsQuery(void *_glfuncs, GLuint id)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ return _qglfuncs->glIsQuery(id);
+}
+
+void gl3_2core_glDeleteQueries(void *_glfuncs, GLsizei n, const GLuint* ids)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glDeleteQueries(n, ids);
+}
+
+void gl3_2core_glGenQueries(void *_glfuncs, GLsizei n, GLuint* ids)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glGenQueries(n, ids);
+}
+
+void gl3_2core_glVertexAttribPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLboolean normalized, GLsizei stride, const GLvoid* offset)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribPointer(index, size, gltype, normalized, stride, offset);
+}
+
+void gl3_2core_glValidateProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glValidateProgram(program);
+}
+
+void gl3_2core_glUniformMatrix4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4fv(location, count, transpose, value);
+}
+
+void gl3_2core_glUniformMatrix3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3fv(location, count, transpose, value);
+}
+
+void gl3_2core_glUniformMatrix2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2fv(location, count, transpose, value);
+}
+
+void gl3_2core_glUniform4iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glUniform4iv(location, count, value);
+}
+
+void gl3_2core_glUniform3iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glUniform3iv(location, count, value);
+}
+
+void gl3_2core_glUniform2iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glUniform2iv(location, count, value);
+}
+
+void gl3_2core_glUniform1iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glUniform1iv(location, count, value);
+}
+
+void gl3_2core_glUniform4fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glUniform4fv(location, count, value);
+}
+
+void gl3_2core_glUniform3fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glUniform3fv(location, count, value);
+}
+
+void gl3_2core_glUniform2fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glUniform2fv(location, count, value);
+}
+
+void gl3_2core_glUniform1fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glUniform1fv(location, count, value);
+}
+
+void gl3_2core_glUniform4i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2, GLint v3)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glUniform4i(location, v0, v1, v2, v3);
+}
+
+void gl3_2core_glUniform3i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glUniform3i(location, v0, v1, v2);
+}
+
+void gl3_2core_glUniform2i(void *_glfuncs, GLint location, GLint v0, GLint v1)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glUniform2i(location, v0, v1);
+}
+
+void gl3_2core_glUniform1i(void *_glfuncs, GLint location, GLint v0)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glUniform1i(location, v0);
+}
+
+void gl3_2core_glUniform4f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glUniform4f(location, v0, v1, v2, v3);
+}
+
+void gl3_2core_glUniform3f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glUniform3f(location, v0, v1, v2);
+}
+
+void gl3_2core_glUniform2f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glUniform2f(location, v0, v1);
+}
+
+void gl3_2core_glUniform1f(void *_glfuncs, GLint location, GLfloat v0)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glUniform1f(location, v0);
+}
+
+void gl3_2core_glUseProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glUseProgram(program);
+}
+
+void gl3_2core_glShaderSource(void *_glfuncs, GLuint shader, GLsizei count, const GLchar** source, const GLint* length)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glShaderSource(shader, count, source, length);
+}
+
+void gl3_2core_glLinkProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glLinkProgram(program);
+}
+
+GLboolean gl3_2core_glIsShader(void *_glfuncs, GLuint shader)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ return _qglfuncs->glIsShader(shader);
+}
+
+GLboolean gl3_2core_glIsProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ return _qglfuncs->glIsProgram(program);
+}
+
+void gl3_2core_glGetVertexAttribiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribiv(index, pname, params);
+}
+
+void gl3_2core_glGetVertexAttribfv(void *_glfuncs, GLuint index, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribfv(index, pname, params);
+}
+
+void gl3_2core_glGetVertexAttribdv(void *_glfuncs, GLuint index, GLenum pname, GLdouble* params)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribdv(index, pname, params);
+}
+
+void gl3_2core_glGetUniformiv(void *_glfuncs, GLuint program, GLint location, GLint* params)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glGetUniformiv(program, location, params);
+}
+
+void gl3_2core_glGetUniformfv(void *_glfuncs, GLuint program, GLint location, GLfloat* params)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glGetUniformfv(program, location, params);
+}
+
+GLint gl3_2core_glGetUniformLocation(void *_glfuncs, GLuint program, const GLchar* name)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ return _qglfuncs->glGetUniformLocation(program, name);
+}
+
+void gl3_2core_glGetShaderSource(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* source)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glGetShaderSource(shader, bufSize, length, source);
+}
+
+void gl3_2core_glGetShaderInfoLog(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* infoLog)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glGetShaderInfoLog(shader, bufSize, length, infoLog);
+}
+
+void gl3_2core_glGetShaderiv(void *_glfuncs, GLuint shader, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glGetShaderiv(shader, pname, params);
+}
+
+void gl3_2core_glGetProgramInfoLog(void *_glfuncs, GLuint program, GLsizei bufSize, GLsizei* length, GLchar* infoLog)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glGetProgramInfoLog(program, bufSize, length, infoLog);
+}
+
+void gl3_2core_glGetProgramiv(void *_glfuncs, GLuint program, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glGetProgramiv(program, pname, params);
+}
+
+GLint gl3_2core_glGetAttribLocation(void *_glfuncs, GLuint program, const GLchar* name)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ return _qglfuncs->glGetAttribLocation(program, name);
+}
+
+void gl3_2core_glGetAttachedShaders(void *_glfuncs, GLuint program, GLsizei maxCount, GLsizei* count, GLuint* obj)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glGetAttachedShaders(program, maxCount, count, obj);
+}
+
+void gl3_2core_glGetActiveUniform(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glGetActiveUniform(program, index, bufSize, length, size, gltype, name);
+}
+
+void gl3_2core_glGetActiveAttrib(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glGetActiveAttrib(program, index, bufSize, length, size, gltype, name);
+}
+
+void gl3_2core_glEnableVertexAttribArray(void *_glfuncs, GLuint index)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glEnableVertexAttribArray(index);
+}
+
+void gl3_2core_glDisableVertexAttribArray(void *_glfuncs, GLuint index)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glDisableVertexAttribArray(index);
+}
+
+void gl3_2core_glDetachShader(void *_glfuncs, GLuint program, GLuint shader)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glDetachShader(program, shader);
+}
+
+void gl3_2core_glDeleteShader(void *_glfuncs, GLuint shader)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glDeleteShader(shader);
+}
+
+void gl3_2core_glDeleteProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glDeleteProgram(program);
+}
+
+GLuint gl3_2core_glCreateShader(void *_glfuncs, GLenum gltype)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ return _qglfuncs->glCreateShader(gltype);
+}
+
+GLuint gl3_2core_glCreateProgram(void *_glfuncs)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ return _qglfuncs->glCreateProgram();
+}
+
+void gl3_2core_glCompileShader(void *_glfuncs, GLuint shader)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glCompileShader(shader);
+}
+
+void gl3_2core_glBindAttribLocation(void *_glfuncs, GLuint program, GLuint index, const GLchar* name)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glBindAttribLocation(program, index, name);
+}
+
+void gl3_2core_glAttachShader(void *_glfuncs, GLuint program, GLuint shader)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glAttachShader(program, shader);
+}
+
+void gl3_2core_glStencilMaskSeparate(void *_glfuncs, GLenum face, GLuint mask)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glStencilMaskSeparate(face, mask);
+}
+
+void gl3_2core_glStencilFuncSeparate(void *_glfuncs, GLenum face, GLenum glfunc, GLint ref, GLuint mask)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glStencilFuncSeparate(face, glfunc, ref, mask);
+}
+
+void gl3_2core_glStencilOpSeparate(void *_glfuncs, GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glStencilOpSeparate(face, sfail, dpfail, dppass);
+}
+
+void gl3_2core_glDrawBuffers(void *_glfuncs, GLsizei n, const GLenum* bufs)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glDrawBuffers(n, bufs);
+}
+
+void gl3_2core_glBlendEquationSeparate(void *_glfuncs, GLenum modeRGB, GLenum modeAlpha)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glBlendEquationSeparate(modeRGB, modeAlpha);
+}
+
+void gl3_2core_glUniformMatrix4x3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4x3fv(location, count, transpose, value);
+}
+
+void gl3_2core_glUniformMatrix3x4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3x4fv(location, count, transpose, value);
+}
+
+void gl3_2core_glUniformMatrix4x2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4x2fv(location, count, transpose, value);
+}
+
+void gl3_2core_glUniformMatrix2x4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2x4fv(location, count, transpose, value);
+}
+
+void gl3_2core_glUniformMatrix3x2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3x2fv(location, count, transpose, value);
+}
+
+void gl3_2core_glUniformMatrix2x3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2x3fv(location, count, transpose, value);
+}
+
+GLboolean gl3_2core_glIsVertexArray(void *_glfuncs, GLuint array)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ return _qglfuncs->glIsVertexArray(array);
+}
+
+void gl3_2core_glGenVertexArrays(void *_glfuncs, GLsizei n, GLuint* arrays)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glGenVertexArrays(n, arrays);
+}
+
+void gl3_2core_glDeleteVertexArrays(void *_glfuncs, GLsizei n, const GLuint* arrays)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glDeleteVertexArrays(n, arrays);
+}
+
+void gl3_2core_glBindVertexArray(void *_glfuncs, GLuint array)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glBindVertexArray(array);
+}
+
+void gl3_2core_glFlushMappedBufferRange(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr length)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glFlushMappedBufferRange(target, offset, length);
+}
+
+void gl3_2core_glFramebufferTextureLayer(void *_glfuncs, GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glFramebufferTextureLayer(target, attachment, texture, level, layer);
+}
+
+void gl3_2core_glRenderbufferStorageMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLenum internalFormat, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glRenderbufferStorageMultisample(target, samples, internalFormat, width, height);
+}
+
+void gl3_2core_glBlitFramebuffer(void *_glfuncs, GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glBlitFramebuffer(srcX0, srcY0, srcX1, srcY1, dstX0, dstY0, dstX1, dstY1, mask, filter);
+}
+
+void gl3_2core_glGenerateMipmap(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glGenerateMipmap(target);
+}
+
+void gl3_2core_glGetFramebufferAttachmentParameteriv(void *_glfuncs, GLenum target, GLenum attachment, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glGetFramebufferAttachmentParameteriv(target, attachment, pname, params);
+}
+
+void gl3_2core_glFramebufferRenderbuffer(void *_glfuncs, GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glFramebufferRenderbuffer(target, attachment, renderbuffertarget, renderbuffer);
+}
+
+void gl3_2core_glFramebufferTexture3D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glFramebufferTexture3D(target, attachment, textarget, texture, level, zoffset);
+}
+
+void gl3_2core_glFramebufferTexture2D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glFramebufferTexture2D(target, attachment, textarget, texture, level);
+}
+
+void gl3_2core_glFramebufferTexture1D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glFramebufferTexture1D(target, attachment, textarget, texture, level);
+}
+
+GLenum gl3_2core_glCheckFramebufferStatus(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ return _qglfuncs->glCheckFramebufferStatus(target);
+}
+
+void gl3_2core_glGenFramebuffers(void *_glfuncs, GLsizei n, GLuint* framebuffers)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glGenFramebuffers(n, framebuffers);
+}
+
+void gl3_2core_glDeleteFramebuffers(void *_glfuncs, GLsizei n, const GLuint* framebuffers)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glDeleteFramebuffers(n, framebuffers);
+}
+
+void gl3_2core_glBindFramebuffer(void *_glfuncs, GLenum target, GLuint framebuffer)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glBindFramebuffer(target, framebuffer);
+}
+
+GLboolean gl3_2core_glIsFramebuffer(void *_glfuncs, GLuint framebuffer)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ return _qglfuncs->glIsFramebuffer(framebuffer);
+}
+
+void gl3_2core_glGetRenderbufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glGetRenderbufferParameteriv(target, pname, params);
+}
+
+void gl3_2core_glRenderbufferStorage(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glRenderbufferStorage(target, internalFormat, width, height);
+}
+
+void gl3_2core_glGenRenderbuffers(void *_glfuncs, GLsizei n, GLuint* renderbuffers)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glGenRenderbuffers(n, renderbuffers);
+}
+
+void gl3_2core_glDeleteRenderbuffers(void *_glfuncs, GLsizei n, const GLuint* renderbuffers)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glDeleteRenderbuffers(n, renderbuffers);
+}
+
+void gl3_2core_glBindRenderbuffer(void *_glfuncs, GLenum target, GLuint renderbuffer)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glBindRenderbuffer(target, renderbuffer);
+}
+
+GLboolean gl3_2core_glIsRenderbuffer(void *_glfuncs, GLuint renderbuffer)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ return _qglfuncs->glIsRenderbuffer(renderbuffer);
+}
+
+void gl3_2core_glClearBufferfi(void *_glfuncs, GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glClearBufferfi(buffer, drawbuffer, depth, stencil);
+}
+
+void gl3_2core_glClearBufferfv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLfloat* value)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glClearBufferfv(buffer, drawbuffer, value);
+}
+
+void gl3_2core_glClearBufferuiv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLuint* value)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glClearBufferuiv(buffer, drawbuffer, value);
+}
+
+void gl3_2core_glClearBufferiv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLint* value)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glClearBufferiv(buffer, drawbuffer, value);
+}
+
+void gl3_2core_glGetTexParameterIuiv(void *_glfuncs, GLenum target, GLenum pname, GLuint* params)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glGetTexParameterIuiv(target, pname, params);
+}
+
+void gl3_2core_glGetTexParameterIiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glGetTexParameterIiv(target, pname, params);
+}
+
+void gl3_2core_glTexParameterIuiv(void *_glfuncs, GLenum target, GLenum pname, const GLuint* params)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glTexParameterIuiv(target, pname, params);
+}
+
+void gl3_2core_glTexParameterIiv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glTexParameterIiv(target, pname, params);
+}
+
+void gl3_2core_glUniform4uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glUniform4uiv(location, count, value);
+}
+
+void gl3_2core_glUniform3uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glUniform3uiv(location, count, value);
+}
+
+void gl3_2core_glUniform2uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glUniform2uiv(location, count, value);
+}
+
+void gl3_2core_glUniform1uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glUniform1uiv(location, count, value);
+}
+
+void gl3_2core_glUniform4ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glUniform4ui(location, v0, v1, v2, v3);
+}
+
+void gl3_2core_glUniform3ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1, GLuint v2)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glUniform3ui(location, v0, v1, v2);
+}
+
+void gl3_2core_glUniform2ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glUniform2ui(location, v0, v1);
+}
+
+void gl3_2core_glUniform1ui(void *_glfuncs, GLint location, GLuint v0)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glUniform1ui(location, v0);
+}
+
+GLint gl3_2core_glGetFragDataLocation(void *_glfuncs, GLuint program, const GLchar* name)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ return _qglfuncs->glGetFragDataLocation(program, name);
+}
+
+void gl3_2core_glBindFragDataLocation(void *_glfuncs, GLuint program, GLuint color, const GLchar* name)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glBindFragDataLocation(program, color, name);
+}
+
+void gl3_2core_glGetUniformuiv(void *_glfuncs, GLuint program, GLint location, GLuint* params)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glGetUniformuiv(program, location, params);
+}
+
+void gl3_2core_glGetVertexAttribIuiv(void *_glfuncs, GLuint index, GLenum pname, GLuint* params)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribIuiv(index, pname, params);
+}
+
+void gl3_2core_glGetVertexAttribIiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribIiv(index, pname, params);
+}
+
+void gl3_2core_glVertexAttribIPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribIPointer(index, size, gltype, stride, pointer);
+}
+
+void gl3_2core_glEndConditionalRender(void *_glfuncs)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glEndConditionalRender();
+}
+
+void gl3_2core_glBeginConditionalRender(void *_glfuncs, GLuint id, GLenum mode)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glBeginConditionalRender(id, mode);
+}
+
+void gl3_2core_glClampColor(void *_glfuncs, GLenum target, GLenum clamp)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glClampColor(target, clamp);
+}
+
+void gl3_2core_glGetTransformFeedbackVarying(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLsizei* size, GLenum* gltype, GLchar* name)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glGetTransformFeedbackVarying(program, index, bufSize, length, size, gltype, name);
+}
+
+void gl3_2core_glBindBufferBase(void *_glfuncs, GLenum target, GLuint index, GLuint buffer)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glBindBufferBase(target, index, buffer);
+}
+
+void gl3_2core_glBindBufferRange(void *_glfuncs, GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glBindBufferRange(target, index, buffer, offset, size);
+}
+
+void gl3_2core_glEndTransformFeedback(void *_glfuncs)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glEndTransformFeedback();
+}
+
+void gl3_2core_glBeginTransformFeedback(void *_glfuncs, GLenum primitiveMode)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glBeginTransformFeedback(primitiveMode);
+}
+
+GLboolean gl3_2core_glIsEnabledi(void *_glfuncs, GLenum target, GLuint index)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ return _qglfuncs->glIsEnabledi(target, index);
+}
+
+void gl3_2core_glDisablei(void *_glfuncs, GLenum target, GLuint index)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glDisablei(target, index);
+}
+
+void gl3_2core_glEnablei(void *_glfuncs, GLenum target, GLuint index)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glEnablei(target, index);
+}
+
+void gl3_2core_glGetIntegeri_v(void *_glfuncs, GLenum target, GLuint index, GLint* data)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glGetIntegeri_v(target, index, data);
+}
+
+void gl3_2core_glGetBooleani_v(void *_glfuncs, GLenum target, GLuint index, GLboolean* data)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glGetBooleani_v(target, index, data);
+}
+
+void gl3_2core_glColorMaski(void *_glfuncs, GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glColorMaski(index, r, g, b, a);
+}
+
+void gl3_2core_glCopyBufferSubData(void *_glfuncs, GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glCopyBufferSubData(readTarget, writeTarget, readOffset, writeOffset, size);
+}
+
+void gl3_2core_glUniformBlockBinding(void *_glfuncs, GLuint program, GLuint v0, GLuint v1)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glUniformBlockBinding(program, v0, v1);
+}
+
+void gl3_2core_glGetActiveUniformBlockName(void *_glfuncs, GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei* length, GLchar* uniformBlockName)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glGetActiveUniformBlockName(program, uniformBlockIndex, bufSize, length, uniformBlockName);
+}
+
+void gl3_2core_glGetActiveUniformBlockiv(void *_glfuncs, GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glGetActiveUniformBlockiv(program, uniformBlockIndex, pname, params);
+}
+
+GLuint gl3_2core_glGetUniformBlockIndex(void *_glfuncs, GLuint program, const GLchar* uniformBlockName)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ return _qglfuncs->glGetUniformBlockIndex(program, uniformBlockName);
+}
+
+void gl3_2core_glGetActiveUniformName(void *_glfuncs, GLuint program, GLuint uniformIndex, GLsizei bufSize, GLsizei* length, GLchar* uniformName)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glGetActiveUniformName(program, uniformIndex, bufSize, length, uniformName);
+}
+
+void gl3_2core_glGetActiveUniformsiv(void *_glfuncs, GLuint program, GLsizei uniformCount, const GLuint* uniformIndices, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glGetActiveUniformsiv(program, uniformCount, uniformIndices, pname, params);
+}
+
+void gl3_2core_glPrimitiveRestartIndex(void *_glfuncs, GLuint index)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glPrimitiveRestartIndex(index);
+}
+
+void gl3_2core_glTexBuffer(void *_glfuncs, GLenum target, GLenum internalFormat, GLuint buffer)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glTexBuffer(target, internalFormat, buffer);
+}
+
+void gl3_2core_glDrawElementsInstanced(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glDrawElementsInstanced(mode, count, gltype, indices, instancecount);
+}
+
+void gl3_2core_glDrawArraysInstanced(void *_glfuncs, GLenum mode, GLint first, GLsizei count, GLsizei instancecount)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glDrawArraysInstanced(mode, first, count, instancecount);
+}
+
+void gl3_2core_glSampleMaski(void *_glfuncs, GLuint index, GLbitfield mask)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glSampleMaski(index, mask);
+}
+
+void gl3_2core_glGetMultisamplefv(void *_glfuncs, GLenum pname, GLuint index, GLfloat* val)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glGetMultisamplefv(pname, index, val);
+}
+
+void gl3_2core_glTexImage3DMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glTexImage3DMultisample(target, samples, internalFormat, width, height, depth, fixedsamplelocations);
+}
+
+void gl3_2core_glTexImage2DMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLint internalFormat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glTexImage2DMultisample(target, samples, internalFormat, width, height, fixedsamplelocations);
+}
+
+void gl3_2core_glGetSynciv(void *_glfuncs, GLsync sync, GLenum pname, GLsizei bufSize, GLsizei* length, GLint* values)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glGetSynciv(sync, pname, bufSize, length, values);
+}
+
+void gl3_2core_glGetInteger64v(void *_glfuncs, GLenum pname, GLint64* params)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glGetInteger64v(pname, params);
+}
+
+void gl3_2core_glWaitSync(void *_glfuncs, GLsync sync, GLbitfield flags, GLuint64 timeout)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glWaitSync(sync, flags, timeout);
+}
+
+GLenum gl3_2core_glClientWaitSync(void *_glfuncs, GLsync sync, GLbitfield flags, GLuint64 timeout)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ return _qglfuncs->glClientWaitSync(sync, flags, timeout);
+}
+
+void gl3_2core_glDeleteSync(void *_glfuncs, GLsync sync)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glDeleteSync(sync);
+}
+
+GLboolean gl3_2core_glIsSync(void *_glfuncs, GLsync sync)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ return _qglfuncs->glIsSync(sync);
+}
+
+GLsync gl3_2core_glFenceSync(void *_glfuncs, GLenum condition, GLbitfield flags)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ return _qglfuncs->glFenceSync(condition, flags);
+}
+
+void gl3_2core_glProvokingVertex(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glProvokingVertex(mode);
+}
+
+void gl3_2core_glDrawElementsInstancedBaseVertex(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount, GLint basevertex)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glDrawElementsInstancedBaseVertex(mode, count, gltype, indices, instancecount, basevertex);
+}
+
+void gl3_2core_glDrawRangeElementsBaseVertex(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices, GLint basevertex)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glDrawRangeElementsBaseVertex(mode, start, end, count, gltype, indices, basevertex);
+}
+
+void gl3_2core_glDrawElementsBaseVertex(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLint basevertex)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glDrawElementsBaseVertex(mode, count, gltype, indices, basevertex);
+}
+
+void gl3_2core_glFramebufferTexture(void *_glfuncs, GLenum target, GLenum attachment, GLuint texture, GLint level)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glFramebufferTexture(target, attachment, texture, level);
+}
+
+void gl3_2core_glGetBufferParameteri64v(void *_glfuncs, GLenum target, GLenum pname, GLint64* params)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glGetBufferParameteri64v(target, pname, params);
+}
+
+void gl3_2core_glGetInteger64i_v(void *_glfuncs, GLenum target, GLuint index, GLint64* data)
+{
+ QOpenGLFunctions_3_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_2_Core*>(_glfuncs);
+ _qglfuncs->glGetInteger64i_v(target, index, data);
+}
+
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/3.2core/funcs.h b/Godeps/_workspace/src/github.com/obscuren/qml/gl/3.2core/funcs.h
new file mode 100644
index 000000000..b0a5c4da4
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/3.2core/funcs.h
@@ -0,0 +1,294 @@
+
+// ** file automatically generated by glgen -- do not edit manually **
+
+#ifndef __cplusplus
+#include <inttypes.h>
+#include <stddef.h>
+typedef unsigned int GLenum;
+typedef unsigned char GLboolean;
+typedef unsigned int GLbitfield;
+typedef void GLvoid;
+typedef char GLchar;
+typedef signed char GLbyte; /* 1-byte signed */
+typedef short GLshort; /* 2-byte signed */
+typedef int GLint; /* 4-byte signed */
+typedef unsigned char GLubyte; /* 1-byte unsigned */
+typedef unsigned short GLushort; /* 2-byte unsigned */
+typedef unsigned int GLuint; /* 4-byte unsigned */
+typedef int GLsizei; /* 4-byte signed */
+typedef float GLfloat; /* single precision float */
+typedef float GLclampf; /* single precision float in [0,1] */
+typedef double GLdouble; /* double precision float */
+typedef double GLclampd; /* double precision float in [0,1] */
+typedef int64_t GLint64;
+typedef uint64_t GLuint64;
+typedef ptrdiff_t GLintptr;
+typedef ptrdiff_t GLsizeiptr;
+typedef ptrdiff_t GLintptrARB;
+typedef ptrdiff_t GLsizeiptrARB;
+typedef struct __GLsync *GLsync;
+#endif
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+void *gl3_2core_funcs();
+
+void gl3_2core_glViewport(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl3_2core_glDepthRange(void *_glfuncs, GLdouble nearVal, GLdouble farVal);
+GLboolean gl3_2core_glIsEnabled(void *_glfuncs, GLenum cap);
+void gl3_2core_glGetTexLevelParameteriv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLint* params);
+void gl3_2core_glGetTexLevelParameterfv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLfloat* params);
+void gl3_2core_glGetTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl3_2core_glGetTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl3_2core_glGetTexImage(void *_glfuncs, GLenum target, GLint level, GLenum format, GLenum gltype, GLvoid* pixels);
+void gl3_2core_glGetIntegerv(void *_glfuncs, GLenum pname, GLint* params);
+void gl3_2core_glGetFloatv(void *_glfuncs, GLenum pname, GLfloat* params);
+GLenum gl3_2core_glGetError(void *_glfuncs);
+void gl3_2core_glGetDoublev(void *_glfuncs, GLenum pname, GLdouble* params);
+void gl3_2core_glGetBooleanv(void *_glfuncs, GLenum pname, GLboolean* params);
+void gl3_2core_glReadPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum gltype, GLvoid* pixels);
+void gl3_2core_glReadBuffer(void *_glfuncs, GLenum mode);
+void gl3_2core_glPixelStorei(void *_glfuncs, GLenum pname, GLint param);
+void gl3_2core_glPixelStoref(void *_glfuncs, GLenum pname, GLfloat param);
+void gl3_2core_glDepthFunc(void *_glfuncs, GLenum glfunc);
+void gl3_2core_glStencilOp(void *_glfuncs, GLenum fail, GLenum zfail, GLenum zpass);
+void gl3_2core_glStencilFunc(void *_glfuncs, GLenum glfunc, GLint ref, GLuint mask);
+void gl3_2core_glLogicOp(void *_glfuncs, GLenum opcode);
+void gl3_2core_glBlendFunc(void *_glfuncs, GLenum sfactor, GLenum dfactor);
+void gl3_2core_glFlush(void *_glfuncs);
+void gl3_2core_glFinish(void *_glfuncs);
+void gl3_2core_glEnable(void *_glfuncs, GLenum cap);
+void gl3_2core_glDisable(void *_glfuncs, GLenum cap);
+void gl3_2core_glDepthMask(void *_glfuncs, GLboolean flag);
+void gl3_2core_glColorMask(void *_glfuncs, GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha);
+void gl3_2core_glStencilMask(void *_glfuncs, GLuint mask);
+void gl3_2core_glClearDepth(void *_glfuncs, GLdouble depth);
+void gl3_2core_glClearStencil(void *_glfuncs, GLint s);
+void gl3_2core_glClearColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl3_2core_glClear(void *_glfuncs, GLbitfield mask);
+void gl3_2core_glDrawBuffer(void *_glfuncs, GLenum mode);
+void gl3_2core_glTexImage2D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl3_2core_glTexImage1D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl3_2core_glTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl3_2core_glTexParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint param);
+void gl3_2core_glTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl3_2core_glTexParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param);
+void gl3_2core_glScissor(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl3_2core_glPolygonMode(void *_glfuncs, GLenum face, GLenum mode);
+void gl3_2core_glPointSize(void *_glfuncs, GLfloat size);
+void gl3_2core_glLineWidth(void *_glfuncs, GLfloat width);
+void gl3_2core_glHint(void *_glfuncs, GLenum target, GLenum mode);
+void gl3_2core_glFrontFace(void *_glfuncs, GLenum mode);
+void gl3_2core_glCullFace(void *_glfuncs, GLenum mode);
+void gl3_2core_glIndexubv(void *_glfuncs, const GLubyte* c);
+void gl3_2core_glIndexub(void *_glfuncs, GLubyte c);
+GLboolean gl3_2core_glIsTexture(void *_glfuncs, GLuint texture);
+void gl3_2core_glGenTextures(void *_glfuncs, GLsizei n, GLuint* textures);
+void gl3_2core_glDeleteTextures(void *_glfuncs, GLsizei n, const GLuint* textures);
+void gl3_2core_glBindTexture(void *_glfuncs, GLenum target, GLuint texture);
+void gl3_2core_glTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl3_2core_glTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl3_2core_glCopyTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl3_2core_glCopyTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width);
+void gl3_2core_glCopyTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border);
+void gl3_2core_glCopyTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLint border);
+void gl3_2core_glPolygonOffset(void *_glfuncs, GLfloat factor, GLfloat units);
+void gl3_2core_glDrawElements(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices);
+void gl3_2core_glDrawArrays(void *_glfuncs, GLenum mode, GLint first, GLsizei count);
+void gl3_2core_glCopyTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl3_2core_glTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl3_2core_glTexImage3D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl3_2core_glDrawRangeElements(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices);
+void gl3_2core_glBlendEquation(void *_glfuncs, GLenum mode);
+void gl3_2core_glBlendColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl3_2core_glGetCompressedTexImage(void *_glfuncs, GLenum target, GLint level, GLvoid* img);
+void gl3_2core_glCompressedTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid* data);
+void gl3_2core_glCompressedTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid* data);
+void gl3_2core_glCompressedTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid* data);
+void gl3_2core_glCompressedTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid* data);
+void gl3_2core_glCompressedTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid* data);
+void gl3_2core_glCompressedTexImage3D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid* data);
+void gl3_2core_glSampleCoverage(void *_glfuncs, GLfloat value, GLboolean invert);
+void gl3_2core_glActiveTexture(void *_glfuncs, GLenum texture);
+void gl3_2core_glPointParameteriv(void *_glfuncs, GLenum pname, const GLint* params);
+void gl3_2core_glPointParameteri(void *_glfuncs, GLenum pname, GLint param);
+void gl3_2core_glPointParameterfv(void *_glfuncs, GLenum pname, const GLfloat* params);
+void gl3_2core_glPointParameterf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl3_2core_glMultiDrawArrays(void *_glfuncs, GLenum mode, const GLint* first, const GLsizei* count, GLsizei drawcount);
+void gl3_2core_glBlendFuncSeparate(void *_glfuncs, GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha);
+void gl3_2core_glGetBufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+GLboolean gl3_2core_glUnmapBuffer(void *_glfuncs, GLenum target);
+void gl3_2core_glGetBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, GLvoid* data);
+void gl3_2core_glBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid* data);
+void gl3_2core_glBufferData(void *_glfuncs, GLenum target, GLsizeiptr size, const GLvoid* data, GLenum usage);
+GLboolean gl3_2core_glIsBuffer(void *_glfuncs, GLuint buffer);
+void gl3_2core_glGenBuffers(void *_glfuncs, GLsizei n, GLuint* buffers);
+void gl3_2core_glDeleteBuffers(void *_glfuncs, GLsizei n, const GLuint* buffers);
+void gl3_2core_glBindBuffer(void *_glfuncs, GLenum target, GLuint buffer);
+void gl3_2core_glGetQueryObjectuiv(void *_glfuncs, GLuint id, GLenum pname, GLuint* params);
+void gl3_2core_glGetQueryObjectiv(void *_glfuncs, GLuint id, GLenum pname, GLint* params);
+void gl3_2core_glGetQueryiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl3_2core_glEndQuery(void *_glfuncs, GLenum target);
+void gl3_2core_glBeginQuery(void *_glfuncs, GLenum target, GLuint id);
+GLboolean gl3_2core_glIsQuery(void *_glfuncs, GLuint id);
+void gl3_2core_glDeleteQueries(void *_glfuncs, GLsizei n, const GLuint* ids);
+void gl3_2core_glGenQueries(void *_glfuncs, GLsizei n, GLuint* ids);
+void gl3_2core_glVertexAttribPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLboolean normalized, GLsizei stride, const GLvoid* offset);
+void gl3_2core_glValidateProgram(void *_glfuncs, GLuint program);
+void gl3_2core_glUniformMatrix4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl3_2core_glUniformMatrix3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl3_2core_glUniformMatrix2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl3_2core_glUniform4iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl3_2core_glUniform3iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl3_2core_glUniform2iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl3_2core_glUniform1iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl3_2core_glUniform4fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl3_2core_glUniform3fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl3_2core_glUniform2fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl3_2core_glUniform1fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl3_2core_glUniform4i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2, GLint v3);
+void gl3_2core_glUniform3i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2);
+void gl3_2core_glUniform2i(void *_glfuncs, GLint location, GLint v0, GLint v1);
+void gl3_2core_glUniform1i(void *_glfuncs, GLint location, GLint v0);
+void gl3_2core_glUniform4f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3);
+void gl3_2core_glUniform3f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2);
+void gl3_2core_glUniform2f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1);
+void gl3_2core_glUniform1f(void *_glfuncs, GLint location, GLfloat v0);
+void gl3_2core_glUseProgram(void *_glfuncs, GLuint program);
+void gl3_2core_glShaderSource(void *_glfuncs, GLuint shader, GLsizei count, const GLchar** source, const GLint* length);
+void gl3_2core_glLinkProgram(void *_glfuncs, GLuint program);
+GLboolean gl3_2core_glIsShader(void *_glfuncs, GLuint shader);
+GLboolean gl3_2core_glIsProgram(void *_glfuncs, GLuint program);
+void gl3_2core_glGetVertexAttribiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params);
+void gl3_2core_glGetVertexAttribfv(void *_glfuncs, GLuint index, GLenum pname, GLfloat* params);
+void gl3_2core_glGetVertexAttribdv(void *_glfuncs, GLuint index, GLenum pname, GLdouble* params);
+void gl3_2core_glGetUniformiv(void *_glfuncs, GLuint program, GLint location, GLint* params);
+void gl3_2core_glGetUniformfv(void *_glfuncs, GLuint program, GLint location, GLfloat* params);
+GLint gl3_2core_glGetUniformLocation(void *_glfuncs, GLuint program, const GLchar* name);
+void gl3_2core_glGetShaderSource(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* source);
+void gl3_2core_glGetShaderInfoLog(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* infoLog);
+void gl3_2core_glGetShaderiv(void *_glfuncs, GLuint shader, GLenum pname, GLint* params);
+void gl3_2core_glGetProgramInfoLog(void *_glfuncs, GLuint program, GLsizei bufSize, GLsizei* length, GLchar* infoLog);
+void gl3_2core_glGetProgramiv(void *_glfuncs, GLuint program, GLenum pname, GLint* params);
+GLint gl3_2core_glGetAttribLocation(void *_glfuncs, GLuint program, const GLchar* name);
+void gl3_2core_glGetAttachedShaders(void *_glfuncs, GLuint program, GLsizei maxCount, GLsizei* count, GLuint* obj);
+void gl3_2core_glGetActiveUniform(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name);
+void gl3_2core_glGetActiveAttrib(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name);
+void gl3_2core_glEnableVertexAttribArray(void *_glfuncs, GLuint index);
+void gl3_2core_glDisableVertexAttribArray(void *_glfuncs, GLuint index);
+void gl3_2core_glDetachShader(void *_glfuncs, GLuint program, GLuint shader);
+void gl3_2core_glDeleteShader(void *_glfuncs, GLuint shader);
+void gl3_2core_glDeleteProgram(void *_glfuncs, GLuint program);
+GLuint gl3_2core_glCreateShader(void *_glfuncs, GLenum gltype);
+GLuint gl3_2core_glCreateProgram(void *_glfuncs);
+void gl3_2core_glCompileShader(void *_glfuncs, GLuint shader);
+void gl3_2core_glBindAttribLocation(void *_glfuncs, GLuint program, GLuint index, const GLchar* name);
+void gl3_2core_glAttachShader(void *_glfuncs, GLuint program, GLuint shader);
+void gl3_2core_glStencilMaskSeparate(void *_glfuncs, GLenum face, GLuint mask);
+void gl3_2core_glStencilFuncSeparate(void *_glfuncs, GLenum face, GLenum glfunc, GLint ref, GLuint mask);
+void gl3_2core_glStencilOpSeparate(void *_glfuncs, GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass);
+void gl3_2core_glDrawBuffers(void *_glfuncs, GLsizei n, const GLenum* bufs);
+void gl3_2core_glBlendEquationSeparate(void *_glfuncs, GLenum modeRGB, GLenum modeAlpha);
+void gl3_2core_glUniformMatrix4x3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl3_2core_glUniformMatrix3x4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl3_2core_glUniformMatrix4x2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl3_2core_glUniformMatrix2x4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl3_2core_glUniformMatrix3x2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl3_2core_glUniformMatrix2x3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+GLboolean gl3_2core_glIsVertexArray(void *_glfuncs, GLuint array);
+void gl3_2core_glGenVertexArrays(void *_glfuncs, GLsizei n, GLuint* arrays);
+void gl3_2core_glDeleteVertexArrays(void *_glfuncs, GLsizei n, const GLuint* arrays);
+void gl3_2core_glBindVertexArray(void *_glfuncs, GLuint array);
+void gl3_2core_glFlushMappedBufferRange(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr length);
+void gl3_2core_glFramebufferTextureLayer(void *_glfuncs, GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer);
+void gl3_2core_glRenderbufferStorageMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLenum internalFormat, GLsizei width, GLsizei height);
+void gl3_2core_glBlitFramebuffer(void *_glfuncs, GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter);
+void gl3_2core_glGenerateMipmap(void *_glfuncs, GLenum target);
+void gl3_2core_glGetFramebufferAttachmentParameteriv(void *_glfuncs, GLenum target, GLenum attachment, GLenum pname, GLint* params);
+void gl3_2core_glFramebufferRenderbuffer(void *_glfuncs, GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer);
+void gl3_2core_glFramebufferTexture3D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset);
+void gl3_2core_glFramebufferTexture2D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+void gl3_2core_glFramebufferTexture1D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+GLenum gl3_2core_glCheckFramebufferStatus(void *_glfuncs, GLenum target);
+void gl3_2core_glGenFramebuffers(void *_glfuncs, GLsizei n, GLuint* framebuffers);
+void gl3_2core_glDeleteFramebuffers(void *_glfuncs, GLsizei n, const GLuint* framebuffers);
+void gl3_2core_glBindFramebuffer(void *_glfuncs, GLenum target, GLuint framebuffer);
+GLboolean gl3_2core_glIsFramebuffer(void *_glfuncs, GLuint framebuffer);
+void gl3_2core_glGetRenderbufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl3_2core_glRenderbufferStorage(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height);
+void gl3_2core_glGenRenderbuffers(void *_glfuncs, GLsizei n, GLuint* renderbuffers);
+void gl3_2core_glDeleteRenderbuffers(void *_glfuncs, GLsizei n, const GLuint* renderbuffers);
+void gl3_2core_glBindRenderbuffer(void *_glfuncs, GLenum target, GLuint renderbuffer);
+GLboolean gl3_2core_glIsRenderbuffer(void *_glfuncs, GLuint renderbuffer);
+void gl3_2core_glClearBufferfi(void *_glfuncs, GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil);
+void gl3_2core_glClearBufferfv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLfloat* value);
+void gl3_2core_glClearBufferuiv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLuint* value);
+void gl3_2core_glClearBufferiv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLint* value);
+void gl3_2core_glGetTexParameterIuiv(void *_glfuncs, GLenum target, GLenum pname, GLuint* params);
+void gl3_2core_glGetTexParameterIiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl3_2core_glTexParameterIuiv(void *_glfuncs, GLenum target, GLenum pname, const GLuint* params);
+void gl3_2core_glTexParameterIiv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl3_2core_glUniform4uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value);
+void gl3_2core_glUniform3uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value);
+void gl3_2core_glUniform2uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value);
+void gl3_2core_glUniform1uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value);
+void gl3_2core_glUniform4ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3);
+void gl3_2core_glUniform3ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1, GLuint v2);
+void gl3_2core_glUniform2ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1);
+void gl3_2core_glUniform1ui(void *_glfuncs, GLint location, GLuint v0);
+GLint gl3_2core_glGetFragDataLocation(void *_glfuncs, GLuint program, const GLchar* name);
+void gl3_2core_glBindFragDataLocation(void *_glfuncs, GLuint program, GLuint color, const GLchar* name);
+void gl3_2core_glGetUniformuiv(void *_glfuncs, GLuint program, GLint location, GLuint* params);
+void gl3_2core_glGetVertexAttribIuiv(void *_glfuncs, GLuint index, GLenum pname, GLuint* params);
+void gl3_2core_glGetVertexAttribIiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params);
+void gl3_2core_glVertexAttribIPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl3_2core_glEndConditionalRender(void *_glfuncs);
+void gl3_2core_glBeginConditionalRender(void *_glfuncs, GLuint id, GLenum mode);
+void gl3_2core_glClampColor(void *_glfuncs, GLenum target, GLenum clamp);
+void gl3_2core_glGetTransformFeedbackVarying(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLsizei* size, GLenum* gltype, GLchar* name);
+void gl3_2core_glBindBufferBase(void *_glfuncs, GLenum target, GLuint index, GLuint buffer);
+void gl3_2core_glBindBufferRange(void *_glfuncs, GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size);
+void gl3_2core_glEndTransformFeedback(void *_glfuncs);
+void gl3_2core_glBeginTransformFeedback(void *_glfuncs, GLenum primitiveMode);
+GLboolean gl3_2core_glIsEnabledi(void *_glfuncs, GLenum target, GLuint index);
+void gl3_2core_glDisablei(void *_glfuncs, GLenum target, GLuint index);
+void gl3_2core_glEnablei(void *_glfuncs, GLenum target, GLuint index);
+void gl3_2core_glGetIntegeri_v(void *_glfuncs, GLenum target, GLuint index, GLint* data);
+void gl3_2core_glGetBooleani_v(void *_glfuncs, GLenum target, GLuint index, GLboolean* data);
+void gl3_2core_glColorMaski(void *_glfuncs, GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a);
+void gl3_2core_glCopyBufferSubData(void *_glfuncs, GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size);
+void gl3_2core_glUniformBlockBinding(void *_glfuncs, GLuint program, GLuint v0, GLuint v1);
+void gl3_2core_glGetActiveUniformBlockName(void *_glfuncs, GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei* length, GLchar* uniformBlockName);
+void gl3_2core_glGetActiveUniformBlockiv(void *_glfuncs, GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint* params);
+GLuint gl3_2core_glGetUniformBlockIndex(void *_glfuncs, GLuint program, const GLchar* uniformBlockName);
+void gl3_2core_glGetActiveUniformName(void *_glfuncs, GLuint program, GLuint uniformIndex, GLsizei bufSize, GLsizei* length, GLchar* uniformName);
+void gl3_2core_glGetActiveUniformsiv(void *_glfuncs, GLuint program, GLsizei uniformCount, const GLuint* uniformIndices, GLenum pname, GLint* params);
+void gl3_2core_glPrimitiveRestartIndex(void *_glfuncs, GLuint index);
+void gl3_2core_glTexBuffer(void *_glfuncs, GLenum target, GLenum internalFormat, GLuint buffer);
+void gl3_2core_glDrawElementsInstanced(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount);
+void gl3_2core_glDrawArraysInstanced(void *_glfuncs, GLenum mode, GLint first, GLsizei count, GLsizei instancecount);
+void gl3_2core_glSampleMaski(void *_glfuncs, GLuint index, GLbitfield mask);
+void gl3_2core_glGetMultisamplefv(void *_glfuncs, GLenum pname, GLuint index, GLfloat* val);
+void gl3_2core_glTexImage3DMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations);
+void gl3_2core_glTexImage2DMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLint internalFormat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations);
+void gl3_2core_glGetSynciv(void *_glfuncs, GLsync sync, GLenum pname, GLsizei bufSize, GLsizei* length, GLint* values);
+void gl3_2core_glGetInteger64v(void *_glfuncs, GLenum pname, GLint64* params);
+void gl3_2core_glWaitSync(void *_glfuncs, GLsync sync, GLbitfield flags, GLuint64 timeout);
+GLenum gl3_2core_glClientWaitSync(void *_glfuncs, GLsync sync, GLbitfield flags, GLuint64 timeout);
+void gl3_2core_glDeleteSync(void *_glfuncs, GLsync sync);
+GLboolean gl3_2core_glIsSync(void *_glfuncs, GLsync sync);
+GLsync gl3_2core_glFenceSync(void *_glfuncs, GLenum condition, GLbitfield flags);
+void gl3_2core_glProvokingVertex(void *_glfuncs, GLenum mode);
+void gl3_2core_glDrawElementsInstancedBaseVertex(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount, GLint basevertex);
+void gl3_2core_glDrawRangeElementsBaseVertex(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices, GLint basevertex);
+void gl3_2core_glDrawElementsBaseVertex(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLint basevertex);
+void gl3_2core_glFramebufferTexture(void *_glfuncs, GLenum target, GLenum attachment, GLuint texture, GLint level);
+void gl3_2core_glGetBufferParameteri64v(void *_glfuncs, GLenum target, GLenum pname, GLint64* params);
+void gl3_2core_glGetInteger64i_v(void *_glfuncs, GLenum target, GLuint index, GLint64* data);
+
+
+#ifdef __cplusplus
+} // extern "C"
+#endif
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/3.2core/gl.go b/Godeps/_workspace/src/github.com/obscuren/qml/gl/3.2core/gl.go
new file mode 100644
index 000000000..80805299a
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/3.2core/gl.go
@@ -0,0 +1,4729 @@
+// ** file automatically generated by glgen -- do not edit manually **
+
+package GL
+
+// #cgo CXXFLAGS: -std=c++0x -pedantic-errors -Wall -fno-strict-aliasing
+// #cgo LDFLAGS: -lstdc++
+// #cgo pkg-config: Qt5Core Qt5OpenGL
+//
+// #include "funcs.h"
+//
+// void free(void*);
+//
+import "C"
+
+import (
+ "fmt"
+ "reflect"
+ "unsafe"
+
+ "gopkg.in/qml.v1/gl/glbase"
+)
+
+// API returns a value that offers methods matching the OpenGL version 3.2 API.
+//
+// The returned API must not be used after the provided OpenGL context becomes invalid.
+func API(context glbase.Contexter) *GL {
+ gl := &GL{}
+ gl.funcs = C.gl3_2core_funcs()
+ if gl.funcs == nil {
+ panic(fmt.Errorf("OpenGL version 3.2 is not available"))
+ }
+ return gl
+}
+
+// GL implements the OpenGL version 3.2 API. Values of this
+// type must be created via the API function, and it must not be used after
+// the associated OpenGL context becomes invalid.
+type GL struct {
+ funcs unsafe.Pointer
+}
+
+const (
+ FALSE = 0
+ TRUE = 1
+ NONE = 0
+
+ BYTE = 0x1400
+ UNSIGNED_BYTE = 0x1401
+ SHORT = 0x1402
+ UNSIGNED_SHORT = 0x1403
+ INT = 0x1404
+ UNSIGNED_INT = 0x1405
+ FLOAT = 0x1406
+ DOUBLE = 0x140A
+ HALF_FLOAT = 0x140B
+
+ COLOR_BUFFER_BIT = 0x00004000
+ DEPTH_BUFFER_BIT = 0x00000100
+ STENCIL_BUFFER_BIT = 0x00000400
+
+ ALWAYS = 0x0207
+ EQUAL = 0x0202
+ GEQUAL = 0x0206
+ GREATER = 0x0204
+ LEQUAL = 0x0203
+ LESS = 0x0201
+ NEVER = 0x0200
+ NOTEQUAL = 0x0205
+
+ DST_ALPHA = 0x0304
+ ONE = 1
+ ONE_MINUS_DST_ALPHA = 0x0305
+ ONE_MINUS_SRC_ALPHA = 0x0303
+ ONE_MINUS_SRC_COLOR = 0x0301
+ SRC_ALPHA = 0x0302
+ SRC_COLOR = 0x0300
+ ZERO = 0
+
+ DST_COLOR = 0x0306
+ ONE_MINUS_DST_COLOR = 0x0307
+ SRC_ALPHA_SATURATE = 0x0308
+
+ CLIP_DISTANCE0 = 0x3000
+ CLIP_DISTANCE1 = 0x3001
+ CLIP_DISTANCE2 = 0x3002
+ CLIP_DISTANCE3 = 0x3003
+ CLIP_DISTANCE4 = 0x3004
+ CLIP_DISTANCE5 = 0x3005
+ CLIP_DISTANCE6 = 0x3006
+ CLIP_DISTANCE7 = 0x3007
+
+ BACK = 0x0405
+ FRONT = 0x0404
+ FRONT_AND_BACK = 0x0408
+
+ CONTEXT_FLAG_FORWARD_COMPATIBLE_BIT = 0x00000001
+
+ CONTEXT_COMPATIBILITY_PROFILE_BIT = 0x00000002
+ CONTEXT_CORE_PROFILE_BIT = 0x00000001
+
+ BACK_LEFT = 0x0402
+ BACK_RIGHT = 0x0403
+ FRONT_LEFT = 0x0400
+ FRONT_RIGHT = 0x0401
+ LEFT = 0x0406
+ RIGHT = 0x0407
+
+ BLEND = 0x0BE2
+ COLOR_LOGIC_OP = 0x0BF2
+ CULL_FACE = 0x0B44
+ DEPTH_TEST = 0x0B71
+ DITHER = 0x0BD0
+ LINE_SMOOTH = 0x0B20
+ POLYGON_OFFSET_FILL = 0x8037
+ POLYGON_OFFSET_LINE = 0x2A02
+ POLYGON_OFFSET_POINT = 0x2A01
+ POLYGON_SMOOTH = 0x0B41
+ SCISSOR_TEST = 0x0C11
+ STENCIL_TEST = 0x0B90
+ TEXTURE_1D = 0x0DE0
+ TEXTURE_2D = 0x0DE1
+
+ INVALID_ENUM = 0x0500
+ INVALID_FRAMEBUFFER_OPERATION = 0x0506
+ INVALID_OPERATION = 0x0502
+ INVALID_VALUE = 0x0501
+ NO_ERROR = 0
+ OUT_OF_MEMORY = 0x0505
+
+ LINEAR = 0x2601
+
+ CCW = 0x0901
+ CW = 0x0900
+
+ ALIASED_LINE_WIDTH_RANGE = 0x846E
+ BLEND_DST = 0x0BE0
+ BLEND_SRC = 0x0BE1
+ COLOR_CLEAR_VALUE = 0x0C22
+ COLOR_WRITEMASK = 0x0C23
+ CULL_FACE_MODE = 0x0B45
+ DEPTH_CLEAR_VALUE = 0x0B73
+ DEPTH_FUNC = 0x0B74
+ DEPTH_RANGE = 0x0B70
+ DEPTH_WRITEMASK = 0x0B72
+ DOUBLEBUFFER = 0x0C32
+ DRAW_BUFFER = 0x0C01
+ FRONT_FACE = 0x0B46
+ LINE_SMOOTH_HINT = 0x0C52
+ LINE_WIDTH = 0x0B21
+ LINE_WIDTH_GRANULARITY = 0x0B23
+ LINE_WIDTH_RANGE = 0x0B22
+ LOGIC_OP_MODE = 0x0BF0
+ MAX_CLIP_DISTANCES = 0x0D32
+ MAX_TEXTURE_SIZE = 0x0D33
+ MAX_VIEWPORT_DIMS = 0x0D3A
+ PACK_ALIGNMENT = 0x0D05
+ PACK_LSB_FIRST = 0x0D01
+ PACK_ROW_LENGTH = 0x0D02
+ PACK_SKIP_PIXELS = 0x0D04
+ PACK_SKIP_ROWS = 0x0D03
+ PACK_SWAP_BYTES = 0x0D00
+ POINT_SIZE = 0x0B11
+ POINT_SIZE_GRANULARITY = 0x0B13
+ POINT_SIZE_RANGE = 0x0B12
+ POLYGON_MODE = 0x0B40
+ POLYGON_OFFSET_FACTOR = 0x8038
+ POLYGON_OFFSET_UNITS = 0x2A00
+ POLYGON_SMOOTH_HINT = 0x0C53
+ READ_BUFFER = 0x0C02
+ SCISSOR_BOX = 0x0C10
+ SMOOTH_LINE_WIDTH_GRANULARITY = 0x0B23
+ SMOOTH_LINE_WIDTH_RANGE = 0x0B22
+ SMOOTH_POINT_SIZE_GRANULARITY = 0x0B13
+ SMOOTH_POINT_SIZE_RANGE = 0x0B12
+ STENCIL_CLEAR_VALUE = 0x0B91
+ STENCIL_FAIL = 0x0B94
+ STENCIL_FUNC = 0x0B92
+ STENCIL_PASS_DEPTH_FAIL = 0x0B95
+ STENCIL_PASS_DEPTH_PASS = 0x0B96
+ STENCIL_REF = 0x0B97
+ STENCIL_VALUE_MASK = 0x0B93
+ STENCIL_WRITEMASK = 0x0B98
+ STEREO = 0x0C33
+ SUBPIXEL_BITS = 0x0D50
+ TEXTURE_BINDING_1D = 0x8068
+ TEXTURE_BINDING_2D = 0x8069
+ TEXTURE_BINDING_3D = 0x806A
+ UNPACK_ALIGNMENT = 0x0CF5
+ UNPACK_LSB_FIRST = 0x0CF1
+ UNPACK_ROW_LENGTH = 0x0CF2
+ UNPACK_SKIP_PIXELS = 0x0CF4
+ UNPACK_SKIP_ROWS = 0x0CF3
+ UNPACK_SWAP_BYTES = 0x0CF0
+ VIEWPORT = 0x0BA2
+
+ TEXTURE_ALPHA_SIZE = 0x805F
+ TEXTURE_BLUE_SIZE = 0x805E
+ TEXTURE_BORDER_COLOR = 0x1004
+ TEXTURE_GREEN_SIZE = 0x805D
+ TEXTURE_HEIGHT = 0x1001
+ TEXTURE_INTERNAL_FORMAT = 0x1003
+ TEXTURE_MAG_FILTER = 0x2800
+ TEXTURE_MIN_FILTER = 0x2801
+ TEXTURE_RED_SIZE = 0x805C
+ TEXTURE_WIDTH = 0x1000
+ TEXTURE_WRAP_S = 0x2802
+ TEXTURE_WRAP_T = 0x2803
+
+ DONT_CARE = 0x1100
+ FASTEST = 0x1101
+ NICEST = 0x1102
+
+ FRAGMENT_SHADER_DERIVATIVE_HINT = 0x8B8B
+ TEXTURE_COMPRESSION_HINT = 0x84EF
+
+ REPLACE = 0x1E01
+
+ AND = 0x1501
+ AND_INVERTED = 0x1504
+ AND_REVERSE = 0x1502
+ CLEAR = 0x1500
+ COPY = 0x1503
+ COPY_INVERTED = 0x150C
+ EQUIV = 0x1509
+ INVERT = 0x150A
+ NAND = 0x150E
+ NOOP = 0x1505
+ NOR = 0x1508
+ OR = 0x1507
+ OR_INVERTED = 0x150D
+ OR_REVERSE = 0x150B
+ SET = 0x150F
+ XOR = 0x1506
+
+ MAP_FLUSH_EXPLICIT_BIT = 0x0010
+ MAP_INVALIDATE_BUFFER_BIT = 0x0008
+ MAP_INVALIDATE_RANGE_BIT = 0x0004
+ MAP_READ_BIT = 0x0001
+ MAP_UNSYNCHRONIZED_BIT = 0x0020
+ MAP_WRITE_BIT = 0x0002
+
+ TEXTURE = 0x1702
+
+ LINE = 0x1B01
+ POINT = 0x1B00
+
+ FILL = 0x1B02
+
+ COLOR = 0x1800
+ DEPTH = 0x1801
+ STENCIL = 0x1802
+
+ ALPHA = 0x1906
+ BLUE = 0x1905
+ DEPTH_COMPONENT = 0x1902
+ GREEN = 0x1904
+ RED = 0x1903
+ RGB = 0x1907
+ RGBA = 0x1908
+ STENCIL_INDEX = 0x1901
+
+ R3_G3_B2 = 0x2A10
+ RGB10 = 0x8052
+ RGB10_A2 = 0x8059
+ RGB12 = 0x8053
+ RGB16 = 0x8054
+ RGB4 = 0x804F
+ RGB5 = 0x8050
+ RGB5_A1 = 0x8057
+ RGB8 = 0x8051
+ RGBA12 = 0x805A
+ RGBA16 = 0x805B
+ RGBA2 = 0x8055
+ RGBA4 = 0x8056
+ RGBA8 = 0x8058
+
+ PACK_IMAGE_HEIGHT = 0x806C
+ PACK_SKIP_IMAGES = 0x806B
+ UNPACK_IMAGE_HEIGHT = 0x806E
+ UNPACK_SKIP_IMAGES = 0x806D
+
+ UNSIGNED_BYTE_3_3_2 = 0x8032
+ UNSIGNED_INT_10_10_10_2 = 0x8036
+ UNSIGNED_INT_8_8_8_8 = 0x8035
+ UNSIGNED_SHORT_4_4_4_4 = 0x8033
+ UNSIGNED_SHORT_5_5_5_1 = 0x8034
+
+ POINT_FADE_THRESHOLD_SIZE = 0x8128
+
+ LINES = 0x0001
+ LINES_ADJACENCY = 0x000A
+ LINE_LOOP = 0x0002
+ LINE_STRIP = 0x0003
+ LINE_STRIP_ADJACENCY = 0x000B
+ POINTS = 0x0000
+ TRIANGLES = 0x0004
+ TRIANGLES_ADJACENCY = 0x000C
+ TRIANGLE_FAN = 0x0006
+ TRIANGLE_STRIP = 0x0005
+ TRIANGLE_STRIP_ADJACENCY = 0x000D
+
+ DECR = 0x1E03
+ INCR = 0x1E02
+ KEEP = 0x1E00
+
+ EXTENSIONS = 0x1F03
+ RENDERER = 0x1F01
+ VENDOR = 0x1F00
+ VERSION = 0x1F02
+
+ NEAREST = 0x2600
+
+ LINEAR_MIPMAP_LINEAR = 0x2703
+ LINEAR_MIPMAP_NEAREST = 0x2701
+ NEAREST_MIPMAP_LINEAR = 0x2702
+ NEAREST_MIPMAP_NEAREST = 0x2700
+
+ TEXTURE_WRAP_R = 0x8072
+
+ PROXY_TEXTURE_1D = 0x8063
+ PROXY_TEXTURE_2D = 0x8064
+ PROXY_TEXTURE_3D = 0x8070
+ TEXTURE_3D = 0x806F
+ TEXTURE_BASE_LEVEL = 0x813C
+ TEXTURE_MAX_LEVEL = 0x813D
+ TEXTURE_MAX_LOD = 0x813B
+ TEXTURE_MIN_LOD = 0x813A
+
+ CLAMP_TO_BORDER = 0x812D
+ CLAMP_TO_EDGE = 0x812F
+ REPEAT = 0x2901
+
+ SYNC_FLUSH_COMMANDS_BIT = 0x00000001
+ INVALID_INDEX = 0xFFFFFFFF
+ TIMEOUT_IGNORED = 0xFFFFFFFFFFFFFFFF
+ CONSTANT_COLOR = 0x8001
+ ONE_MINUS_CONSTANT_COLOR = 0x8002
+ CONSTANT_ALPHA = 0x8003
+ ONE_MINUS_CONSTANT_ALPHA = 0x8004
+ FUNC_ADD = 0x8006
+ MIN = 0x8007
+ MAX = 0x8008
+ BLEND_EQUATION_RGB = 0x8009
+ FUNC_SUBTRACT = 0x800A
+ FUNC_REVERSE_SUBTRACT = 0x800B
+ TEXTURE_DEPTH = 0x8071
+ MAX_3D_TEXTURE_SIZE = 0x8073
+ MULTISAMPLE = 0x809D
+ SAMPLE_ALPHA_TO_COVERAGE = 0x809E
+ SAMPLE_ALPHA_TO_ONE = 0x809F
+ SAMPLE_COVERAGE = 0x80A0
+ SAMPLE_BUFFERS = 0x80A8
+ SAMPLES = 0x80A9
+ SAMPLE_COVERAGE_VALUE = 0x80AA
+ SAMPLE_COVERAGE_INVERT = 0x80AB
+ BLEND_DST_RGB = 0x80C8
+ BLEND_SRC_RGB = 0x80C9
+ BLEND_DST_ALPHA = 0x80CA
+ BLEND_SRC_ALPHA = 0x80CB
+ BGR = 0x80E0
+ BGRA = 0x80E1
+ MAX_ELEMENTS_VERTICES = 0x80E8
+ MAX_ELEMENTS_INDICES = 0x80E9
+ DEPTH_COMPONENT16 = 0x81A5
+ DEPTH_COMPONENT24 = 0x81A6
+ DEPTH_COMPONENT32 = 0x81A7
+ FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING = 0x8210
+ FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE = 0x8211
+ FRAMEBUFFER_ATTACHMENT_RED_SIZE = 0x8212
+ FRAMEBUFFER_ATTACHMENT_GREEN_SIZE = 0x8213
+ FRAMEBUFFER_ATTACHMENT_BLUE_SIZE = 0x8214
+ FRAMEBUFFER_ATTACHMENT_ALPHA_SIZE = 0x8215
+ FRAMEBUFFER_ATTACHMENT_DEPTH_SIZE = 0x8216
+ FRAMEBUFFER_ATTACHMENT_STENCIL_SIZE = 0x8217
+ FRAMEBUFFER_DEFAULT = 0x8218
+ FRAMEBUFFER_UNDEFINED = 0x8219
+ DEPTH_STENCIL_ATTACHMENT = 0x821A
+ MAJOR_VERSION = 0x821B
+ MINOR_VERSION = 0x821C
+ NUM_EXTENSIONS = 0x821D
+ CONTEXT_FLAGS = 0x821E
+ COMPRESSED_RED = 0x8225
+ COMPRESSED_RG = 0x8226
+ RG = 0x8227
+ RG_INTEGER = 0x8228
+ R8 = 0x8229
+ R16 = 0x822A
+ RG8 = 0x822B
+ RG16 = 0x822C
+ R16F = 0x822D
+ R32F = 0x822E
+ RG16F = 0x822F
+ RG32F = 0x8230
+ R8I = 0x8231
+ R8UI = 0x8232
+ R16I = 0x8233
+ R16UI = 0x8234
+ R32I = 0x8235
+ R32UI = 0x8236
+ RG8I = 0x8237
+ RG8UI = 0x8238
+ RG16I = 0x8239
+ RG16UI = 0x823A
+ RG32I = 0x823B
+ RG32UI = 0x823C
+ UNSIGNED_BYTE_2_3_3_REV = 0x8362
+ UNSIGNED_SHORT_5_6_5 = 0x8363
+ UNSIGNED_SHORT_5_6_5_REV = 0x8364
+ UNSIGNED_SHORT_4_4_4_4_REV = 0x8365
+ UNSIGNED_SHORT_1_5_5_5_REV = 0x8366
+ UNSIGNED_INT_8_8_8_8_REV = 0x8367
+ UNSIGNED_INT_2_10_10_10_REV = 0x8368
+ MIRRORED_REPEAT = 0x8370
+ TEXTURE0 = 0x84C0
+ TEXTURE1 = 0x84C1
+ TEXTURE2 = 0x84C2
+ TEXTURE3 = 0x84C3
+ TEXTURE4 = 0x84C4
+ TEXTURE5 = 0x84C5
+ TEXTURE6 = 0x84C6
+ TEXTURE7 = 0x84C7
+ TEXTURE8 = 0x84C8
+ TEXTURE9 = 0x84C9
+ TEXTURE10 = 0x84CA
+ TEXTURE11 = 0x84CB
+ TEXTURE12 = 0x84CC
+ TEXTURE13 = 0x84CD
+ TEXTURE14 = 0x84CE
+ TEXTURE15 = 0x84CF
+ TEXTURE16 = 0x84D0
+ TEXTURE17 = 0x84D1
+ TEXTURE18 = 0x84D2
+ TEXTURE19 = 0x84D3
+ TEXTURE20 = 0x84D4
+ TEXTURE21 = 0x84D5
+ TEXTURE22 = 0x84D6
+ TEXTURE23 = 0x84D7
+ TEXTURE24 = 0x84D8
+ TEXTURE25 = 0x84D9
+ TEXTURE26 = 0x84DA
+ TEXTURE27 = 0x84DB
+ TEXTURE28 = 0x84DC
+ TEXTURE29 = 0x84DD
+ TEXTURE30 = 0x84DE
+ TEXTURE31 = 0x84DF
+ ACTIVE_TEXTURE = 0x84E0
+ MAX_RENDERBUFFER_SIZE = 0x84E8
+ COMPRESSED_RGB = 0x84ED
+ COMPRESSED_RGBA = 0x84EE
+ TEXTURE_RECTANGLE = 0x84F5
+ TEXTURE_BINDING_RECTANGLE = 0x84F6
+ PROXY_TEXTURE_RECTANGLE = 0x84F7
+ MAX_RECTANGLE_TEXTURE_SIZE = 0x84F8
+ DEPTH_STENCIL = 0x84F9
+ UNSIGNED_INT_24_8 = 0x84FA
+ MAX_TEXTURE_LOD_BIAS = 0x84FD
+ TEXTURE_LOD_BIAS = 0x8501
+ INCR_WRAP = 0x8507
+ DECR_WRAP = 0x8508
+ TEXTURE_CUBE_MAP = 0x8513
+ TEXTURE_BINDING_CUBE_MAP = 0x8514
+ TEXTURE_CUBE_MAP_POSITIVE_X = 0x8515
+ TEXTURE_CUBE_MAP_NEGATIVE_X = 0x8516
+ TEXTURE_CUBE_MAP_POSITIVE_Y = 0x8517
+ TEXTURE_CUBE_MAP_NEGATIVE_Y = 0x8518
+ TEXTURE_CUBE_MAP_POSITIVE_Z = 0x8519
+ TEXTURE_CUBE_MAP_NEGATIVE_Z = 0x851A
+ PROXY_TEXTURE_CUBE_MAP = 0x851B
+ MAX_CUBE_MAP_TEXTURE_SIZE = 0x851C
+ SRC1_ALPHA = 0x8589
+ VERTEX_ARRAY_BINDING = 0x85B5
+ VERTEX_ATTRIB_ARRAY_ENABLED = 0x8622
+ VERTEX_ATTRIB_ARRAY_SIZE = 0x8623
+ VERTEX_ATTRIB_ARRAY_STRIDE = 0x8624
+ VERTEX_ATTRIB_ARRAY_TYPE = 0x8625
+ CURRENT_VERTEX_ATTRIB = 0x8626
+ VERTEX_PROGRAM_POINT_SIZE = 0x8642
+ PROGRAM_POINT_SIZE = 0x8642
+ VERTEX_ATTRIB_ARRAY_POINTER = 0x8645
+ DEPTH_CLAMP = 0x864F
+ TEXTURE_COMPRESSED_IMAGE_SIZE = 0x86A0
+ TEXTURE_COMPRESSED = 0x86A1
+ NUM_COMPRESSED_TEXTURE_FORMATS = 0x86A2
+ COMPRESSED_TEXTURE_FORMATS = 0x86A3
+ BUFFER_SIZE = 0x8764
+ BUFFER_USAGE = 0x8765
+ STENCIL_BACK_FUNC = 0x8800
+ STENCIL_BACK_FAIL = 0x8801
+ STENCIL_BACK_PASS_DEPTH_FAIL = 0x8802
+ STENCIL_BACK_PASS_DEPTH_PASS = 0x8803
+ RGBA32F = 0x8814
+ RGB32F = 0x8815
+ RGBA16F = 0x881A
+ RGB16F = 0x881B
+ MAX_DRAW_BUFFERS = 0x8824
+ DRAW_BUFFER0 = 0x8825
+ DRAW_BUFFER1 = 0x8826
+ DRAW_BUFFER2 = 0x8827
+ DRAW_BUFFER3 = 0x8828
+ DRAW_BUFFER4 = 0x8829
+ DRAW_BUFFER5 = 0x882A
+ DRAW_BUFFER6 = 0x882B
+ DRAW_BUFFER7 = 0x882C
+ DRAW_BUFFER8 = 0x882D
+ DRAW_BUFFER9 = 0x882E
+ DRAW_BUFFER10 = 0x882F
+ DRAW_BUFFER11 = 0x8830
+ DRAW_BUFFER12 = 0x8831
+ DRAW_BUFFER13 = 0x8832
+ DRAW_BUFFER14 = 0x8833
+ DRAW_BUFFER15 = 0x8834
+ BLEND_EQUATION_ALPHA = 0x883D
+ TEXTURE_DEPTH_SIZE = 0x884A
+ TEXTURE_COMPARE_MODE = 0x884C
+ TEXTURE_COMPARE_FUNC = 0x884D
+ COMPARE_REF_TO_TEXTURE = 0x884E
+ TEXTURE_CUBE_MAP_SEAMLESS = 0x884F
+ QUERY_COUNTER_BITS = 0x8864
+ CURRENT_QUERY = 0x8865
+ QUERY_RESULT = 0x8866
+ QUERY_RESULT_AVAILABLE = 0x8867
+ MAX_VERTEX_ATTRIBS = 0x8869
+ VERTEX_ATTRIB_ARRAY_NORMALIZED = 0x886A
+ MAX_TEXTURE_IMAGE_UNITS = 0x8872
+ ARRAY_BUFFER = 0x8892
+ ELEMENT_ARRAY_BUFFER = 0x8893
+ ARRAY_BUFFER_BINDING = 0x8894
+ ELEMENT_ARRAY_BUFFER_BINDING = 0x8895
+ VERTEX_ATTRIB_ARRAY_BUFFER_BINDING = 0x889F
+ READ_ONLY = 0x88B8
+ WRITE_ONLY = 0x88B9
+ READ_WRITE = 0x88BA
+ BUFFER_ACCESS = 0x88BB
+ BUFFER_MAPPED = 0x88BC
+ BUFFER_MAP_POINTER = 0x88BD
+ STREAM_DRAW = 0x88E0
+ STREAM_READ = 0x88E1
+ STREAM_COPY = 0x88E2
+ STATIC_DRAW = 0x88E4
+ STATIC_READ = 0x88E5
+ STATIC_COPY = 0x88E6
+ DYNAMIC_DRAW = 0x88E8
+ DYNAMIC_READ = 0x88E9
+ DYNAMIC_COPY = 0x88EA
+ PIXEL_PACK_BUFFER = 0x88EB
+ PIXEL_UNPACK_BUFFER = 0x88EC
+ PIXEL_PACK_BUFFER_BINDING = 0x88ED
+ PIXEL_UNPACK_BUFFER_BINDING = 0x88EF
+ DEPTH24_STENCIL8 = 0x88F0
+ TEXTURE_STENCIL_SIZE = 0x88F1
+ VERTEX_ATTRIB_ARRAY_INTEGER = 0x88FD
+ MAX_ARRAY_TEXTURE_LAYERS = 0x88FF
+ MIN_PROGRAM_TEXEL_OFFSET = 0x8904
+ MAX_PROGRAM_TEXEL_OFFSET = 0x8905
+ SAMPLES_PASSED = 0x8914
+ GEOMETRY_VERTICES_OUT = 0x8916
+ GEOMETRY_INPUT_TYPE = 0x8917
+ GEOMETRY_OUTPUT_TYPE = 0x8918
+ CLAMP_READ_COLOR = 0x891C
+ FIXED_ONLY = 0x891D
+ UNIFORM_BUFFER = 0x8A11
+ UNIFORM_BUFFER_BINDING = 0x8A28
+ UNIFORM_BUFFER_START = 0x8A29
+ UNIFORM_BUFFER_SIZE = 0x8A2A
+ MAX_VERTEX_UNIFORM_BLOCKS = 0x8A2B
+ MAX_GEOMETRY_UNIFORM_BLOCKS = 0x8A2C
+ MAX_FRAGMENT_UNIFORM_BLOCKS = 0x8A2D
+ MAX_COMBINED_UNIFORM_BLOCKS = 0x8A2E
+ MAX_UNIFORM_BUFFER_BINDINGS = 0x8A2F
+ MAX_UNIFORM_BLOCK_SIZE = 0x8A30
+ MAX_COMBINED_VERTEX_UNIFORM_COMPONENTS = 0x8A31
+ MAX_COMBINED_GEOMETRY_UNIFORM_COMPONENTS = 0x8A32
+ MAX_COMBINED_FRAGMENT_UNIFORM_COMPONENTS = 0x8A33
+ UNIFORM_BUFFER_OFFSET_ALIGNMENT = 0x8A34
+ ACTIVE_UNIFORM_BLOCK_MAX_NAME_LENGTH = 0x8A35
+ ACTIVE_UNIFORM_BLOCKS = 0x8A36
+ UNIFORM_TYPE = 0x8A37
+ UNIFORM_SIZE = 0x8A38
+ UNIFORM_NAME_LENGTH = 0x8A39
+ UNIFORM_BLOCK_INDEX = 0x8A3A
+ UNIFORM_OFFSET = 0x8A3B
+ UNIFORM_ARRAY_STRIDE = 0x8A3C
+ UNIFORM_MATRIX_STRIDE = 0x8A3D
+ UNIFORM_IS_ROW_MAJOR = 0x8A3E
+ UNIFORM_BLOCK_BINDING = 0x8A3F
+ UNIFORM_BLOCK_DATA_SIZE = 0x8A40
+ UNIFORM_BLOCK_NAME_LENGTH = 0x8A41
+ UNIFORM_BLOCK_ACTIVE_UNIFORMS = 0x8A42
+ UNIFORM_BLOCK_ACTIVE_UNIFORM_INDICES = 0x8A43
+ UNIFORM_BLOCK_REFERENCED_BY_VERTEX_SHADER = 0x8A44
+ UNIFORM_BLOCK_REFERENCED_BY_GEOMETRY_SHADER = 0x8A45
+ UNIFORM_BLOCK_REFERENCED_BY_FRAGMENT_SHADER = 0x8A46
+ FRAGMENT_SHADER = 0x8B30
+ VERTEX_SHADER = 0x8B31
+ MAX_FRAGMENT_UNIFORM_COMPONENTS = 0x8B49
+ MAX_VERTEX_UNIFORM_COMPONENTS = 0x8B4A
+ MAX_VARYING_FLOATS = 0x8B4B
+ MAX_VARYING_COMPONENTS = 0x8B4B
+ MAX_VERTEX_TEXTURE_IMAGE_UNITS = 0x8B4C
+ MAX_COMBINED_TEXTURE_IMAGE_UNITS = 0x8B4D
+ SHADER_TYPE = 0x8B4F
+ FLOAT_VEC2 = 0x8B50
+ FLOAT_VEC3 = 0x8B51
+ FLOAT_VEC4 = 0x8B52
+ INT_VEC2 = 0x8B53
+ INT_VEC3 = 0x8B54
+ INT_VEC4 = 0x8B55
+ BOOL = 0x8B56
+ BOOL_VEC2 = 0x8B57
+ BOOL_VEC3 = 0x8B58
+ BOOL_VEC4 = 0x8B59
+ FLOAT_MAT2 = 0x8B5A
+ FLOAT_MAT3 = 0x8B5B
+ FLOAT_MAT4 = 0x8B5C
+ SAMPLER_1D = 0x8B5D
+ SAMPLER_2D = 0x8B5E
+ SAMPLER_3D = 0x8B5F
+ SAMPLER_CUBE = 0x8B60
+ SAMPLER_1D_SHADOW = 0x8B61
+ SAMPLER_2D_SHADOW = 0x8B62
+ SAMPLER_2D_RECT = 0x8B63
+ SAMPLER_2D_RECT_SHADOW = 0x8B64
+ FLOAT_MAT2x3 = 0x8B65
+ FLOAT_MAT2x4 = 0x8B66
+ FLOAT_MAT3x2 = 0x8B67
+ FLOAT_MAT3x4 = 0x8B68
+ FLOAT_MAT4x2 = 0x8B69
+ FLOAT_MAT4x3 = 0x8B6A
+ DELETE_STATUS = 0x8B80
+ COMPILE_STATUS = 0x8B81
+ LINK_STATUS = 0x8B82
+ VALIDATE_STATUS = 0x8B83
+ INFO_LOG_LENGTH = 0x8B84
+ ATTACHED_SHADERS = 0x8B85
+ ACTIVE_UNIFORMS = 0x8B86
+ ACTIVE_UNIFORM_MAX_LENGTH = 0x8B87
+ SHADER_SOURCE_LENGTH = 0x8B88
+ ACTIVE_ATTRIBUTES = 0x8B89
+ ACTIVE_ATTRIBUTE_MAX_LENGTH = 0x8B8A
+ SHADING_LANGUAGE_VERSION = 0x8B8C
+ CURRENT_PROGRAM = 0x8B8D
+ TEXTURE_RED_TYPE = 0x8C10
+ TEXTURE_GREEN_TYPE = 0x8C11
+ TEXTURE_BLUE_TYPE = 0x8C12
+ TEXTURE_ALPHA_TYPE = 0x8C13
+ TEXTURE_DEPTH_TYPE = 0x8C16
+ UNSIGNED_NORMALIZED = 0x8C17
+ TEXTURE_1D_ARRAY = 0x8C18
+ PROXY_TEXTURE_1D_ARRAY = 0x8C19
+ TEXTURE_2D_ARRAY = 0x8C1A
+ PROXY_TEXTURE_2D_ARRAY = 0x8C1B
+ TEXTURE_BINDING_1D_ARRAY = 0x8C1C
+ TEXTURE_BINDING_2D_ARRAY = 0x8C1D
+ MAX_GEOMETRY_TEXTURE_IMAGE_UNITS = 0x8C29
+ TEXTURE_BUFFER = 0x8C2A
+ MAX_TEXTURE_BUFFER_SIZE = 0x8C2B
+ TEXTURE_BINDING_BUFFER = 0x8C2C
+ TEXTURE_BUFFER_DATA_STORE_BINDING = 0x8C2D
+ R11F_G11F_B10F = 0x8C3A
+ UNSIGNED_INT_10F_11F_11F_REV = 0x8C3B
+ RGB9_E5 = 0x8C3D
+ UNSIGNED_INT_5_9_9_9_REV = 0x8C3E
+ TEXTURE_SHARED_SIZE = 0x8C3F
+ SRGB = 0x8C40
+ SRGB8 = 0x8C41
+ SRGB_ALPHA = 0x8C42
+ SRGB8_ALPHA8 = 0x8C43
+ COMPRESSED_SRGB = 0x8C48
+ COMPRESSED_SRGB_ALPHA = 0x8C49
+ TRANSFORM_FEEDBACK_VARYING_MAX_LENGTH = 0x8C76
+ TRANSFORM_FEEDBACK_BUFFER_MODE = 0x8C7F
+ MAX_TRANSFORM_FEEDBACK_SEPARATE_COMPONENTS = 0x8C80
+ TRANSFORM_FEEDBACK_VARYINGS = 0x8C83
+ TRANSFORM_FEEDBACK_BUFFER_START = 0x8C84
+ TRANSFORM_FEEDBACK_BUFFER_SIZE = 0x8C85
+ PRIMITIVES_GENERATED = 0x8C87
+ TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN = 0x8C88
+ RASTERIZER_DISCARD = 0x8C89
+ MAX_TRANSFORM_FEEDBACK_INTERLEAVED_COMPONENTS = 0x8C8A
+ MAX_TRANSFORM_FEEDBACK_SEPARATE_ATTRIBS = 0x8C8B
+ INTERLEAVED_ATTRIBS = 0x8C8C
+ SEPARATE_ATTRIBS = 0x8C8D
+ TRANSFORM_FEEDBACK_BUFFER = 0x8C8E
+ TRANSFORM_FEEDBACK_BUFFER_BINDING = 0x8C8F
+ POINT_SPRITE_COORD_ORIGIN = 0x8CA0
+ LOWER_LEFT = 0x8CA1
+ UPPER_LEFT = 0x8CA2
+ STENCIL_BACK_REF = 0x8CA3
+ STENCIL_BACK_VALUE_MASK = 0x8CA4
+ STENCIL_BACK_WRITEMASK = 0x8CA5
+ DRAW_FRAMEBUFFER_BINDING = 0x8CA6
+ FRAMEBUFFER_BINDING = 0x8CA6
+ RENDERBUFFER_BINDING = 0x8CA7
+ READ_FRAMEBUFFER = 0x8CA8
+ DRAW_FRAMEBUFFER = 0x8CA9
+ READ_FRAMEBUFFER_BINDING = 0x8CAA
+ RENDERBUFFER_SAMPLES = 0x8CAB
+ DEPTH_COMPONENT32F = 0x8CAC
+ DEPTH32F_STENCIL8 = 0x8CAD
+ FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE = 0x8CD0
+ FRAMEBUFFER_ATTACHMENT_OBJECT_NAME = 0x8CD1
+ FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL = 0x8CD2
+ FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE = 0x8CD3
+ FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER = 0x8CD4
+ FRAMEBUFFER_COMPLETE = 0x8CD5
+ FRAMEBUFFER_INCOMPLETE_ATTACHMENT = 0x8CD6
+ FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT = 0x8CD7
+ FRAMEBUFFER_INCOMPLETE_DRAW_BUFFER = 0x8CDB
+ FRAMEBUFFER_INCOMPLETE_READ_BUFFER = 0x8CDC
+ FRAMEBUFFER_UNSUPPORTED = 0x8CDD
+ MAX_COLOR_ATTACHMENTS = 0x8CDF
+ COLOR_ATTACHMENT0 = 0x8CE0
+ COLOR_ATTACHMENT1 = 0x8CE1
+ COLOR_ATTACHMENT2 = 0x8CE2
+ COLOR_ATTACHMENT3 = 0x8CE3
+ COLOR_ATTACHMENT4 = 0x8CE4
+ COLOR_ATTACHMENT5 = 0x8CE5
+ COLOR_ATTACHMENT6 = 0x8CE6
+ COLOR_ATTACHMENT7 = 0x8CE7
+ COLOR_ATTACHMENT8 = 0x8CE8
+ COLOR_ATTACHMENT9 = 0x8CE9
+ COLOR_ATTACHMENT10 = 0x8CEA
+ COLOR_ATTACHMENT11 = 0x8CEB
+ COLOR_ATTACHMENT12 = 0x8CEC
+ COLOR_ATTACHMENT13 = 0x8CED
+ COLOR_ATTACHMENT14 = 0x8CEE
+ COLOR_ATTACHMENT15 = 0x8CEF
+ DEPTH_ATTACHMENT = 0x8D00
+ STENCIL_ATTACHMENT = 0x8D20
+ FRAMEBUFFER = 0x8D40
+ RENDERBUFFER = 0x8D41
+ RENDERBUFFER_WIDTH = 0x8D42
+ RENDERBUFFER_HEIGHT = 0x8D43
+ RENDERBUFFER_INTERNAL_FORMAT = 0x8D44
+ STENCIL_INDEX1 = 0x8D46
+ STENCIL_INDEX4 = 0x8D47
+ STENCIL_INDEX8 = 0x8D48
+ STENCIL_INDEX16 = 0x8D49
+ RENDERBUFFER_RED_SIZE = 0x8D50
+ RENDERBUFFER_GREEN_SIZE = 0x8D51
+ RENDERBUFFER_BLUE_SIZE = 0x8D52
+ RENDERBUFFER_ALPHA_SIZE = 0x8D53
+ RENDERBUFFER_DEPTH_SIZE = 0x8D54
+ RENDERBUFFER_STENCIL_SIZE = 0x8D55
+ FRAMEBUFFER_INCOMPLETE_MULTISAMPLE = 0x8D56
+ MAX_SAMPLES = 0x8D57
+ RGBA32UI = 0x8D70
+ RGB32UI = 0x8D71
+ RGBA16UI = 0x8D76
+ RGB16UI = 0x8D77
+ RGBA8UI = 0x8D7C
+ RGB8UI = 0x8D7D
+ RGBA32I = 0x8D82
+ RGB32I = 0x8D83
+ RGBA16I = 0x8D88
+ RGB16I = 0x8D89
+ RGBA8I = 0x8D8E
+ RGB8I = 0x8D8F
+ RED_INTEGER = 0x8D94
+ GREEN_INTEGER = 0x8D95
+ BLUE_INTEGER = 0x8D96
+ RGB_INTEGER = 0x8D98
+ RGBA_INTEGER = 0x8D99
+ BGR_INTEGER = 0x8D9A
+ BGRA_INTEGER = 0x8D9B
+ FRAMEBUFFER_ATTACHMENT_LAYERED = 0x8DA7
+ FRAMEBUFFER_INCOMPLETE_LAYER_TARGETS = 0x8DA8
+ FLOAT_32_UNSIGNED_INT_24_8_REV = 0x8DAD
+ FRAMEBUFFER_SRGB = 0x8DB9
+ COMPRESSED_RED_RGTC1 = 0x8DBB
+ COMPRESSED_SIGNED_RED_RGTC1 = 0x8DBC
+ COMPRESSED_RG_RGTC2 = 0x8DBD
+ COMPRESSED_SIGNED_RG_RGTC2 = 0x8DBE
+ SAMPLER_1D_ARRAY = 0x8DC0
+ SAMPLER_2D_ARRAY = 0x8DC1
+ SAMPLER_BUFFER = 0x8DC2
+ SAMPLER_1D_ARRAY_SHADOW = 0x8DC3
+ SAMPLER_2D_ARRAY_SHADOW = 0x8DC4
+ SAMPLER_CUBE_SHADOW = 0x8DC5
+ UNSIGNED_INT_VEC2 = 0x8DC6
+ UNSIGNED_INT_VEC3 = 0x8DC7
+ UNSIGNED_INT_VEC4 = 0x8DC8
+ INT_SAMPLER_1D = 0x8DC9
+ INT_SAMPLER_2D = 0x8DCA
+ INT_SAMPLER_3D = 0x8DCB
+ INT_SAMPLER_CUBE = 0x8DCC
+ INT_SAMPLER_2D_RECT = 0x8DCD
+ INT_SAMPLER_1D_ARRAY = 0x8DCE
+ INT_SAMPLER_2D_ARRAY = 0x8DCF
+ INT_SAMPLER_BUFFER = 0x8DD0
+ UNSIGNED_INT_SAMPLER_1D = 0x8DD1
+ UNSIGNED_INT_SAMPLER_2D = 0x8DD2
+ UNSIGNED_INT_SAMPLER_3D = 0x8DD3
+ UNSIGNED_INT_SAMPLER_CUBE = 0x8DD4
+ UNSIGNED_INT_SAMPLER_2D_RECT = 0x8DD5
+ UNSIGNED_INT_SAMPLER_1D_ARRAY = 0x8DD6
+ UNSIGNED_INT_SAMPLER_2D_ARRAY = 0x8DD7
+ UNSIGNED_INT_SAMPLER_BUFFER = 0x8DD8
+ GEOMETRY_SHADER = 0x8DD9
+ MAX_GEOMETRY_UNIFORM_COMPONENTS = 0x8DDF
+ MAX_GEOMETRY_OUTPUT_VERTICES = 0x8DE0
+ MAX_GEOMETRY_TOTAL_OUTPUT_COMPONENTS = 0x8DE1
+ QUERY_WAIT = 0x8E13
+ QUERY_NO_WAIT = 0x8E14
+ QUERY_BY_REGION_WAIT = 0x8E15
+ QUERY_BY_REGION_NO_WAIT = 0x8E16
+ QUADS_FOLLOW_PROVOKING_VERTEX_CONVENTION = 0x8E4C
+ FIRST_VERTEX_CONVENTION = 0x8E4D
+ LAST_VERTEX_CONVENTION = 0x8E4E
+ PROVOKING_VERTEX = 0x8E4F
+ SAMPLE_POSITION = 0x8E50
+ SAMPLE_MASK = 0x8E51
+ SAMPLE_MASK_VALUE = 0x8E52
+ MAX_SAMPLE_MASK_WORDS = 0x8E59
+ COPY_READ_BUFFER = 0x8F36
+ COPY_WRITE_BUFFER = 0x8F37
+ R8_SNORM = 0x8F94
+ RG8_SNORM = 0x8F95
+ RGB8_SNORM = 0x8F96
+ RGBA8_SNORM = 0x8F97
+ R16_SNORM = 0x8F98
+ RG16_SNORM = 0x8F99
+ RGB16_SNORM = 0x8F9A
+ RGBA16_SNORM = 0x8F9B
+ SIGNED_NORMALIZED = 0x8F9C
+ PRIMITIVE_RESTART = 0x8F9D
+ PRIMITIVE_RESTART_INDEX = 0x8F9E
+ TEXTURE_2D_MULTISAMPLE = 0x9100
+ PROXY_TEXTURE_2D_MULTISAMPLE = 0x9101
+ TEXTURE_2D_MULTISAMPLE_ARRAY = 0x9102
+ PROXY_TEXTURE_2D_MULTISAMPLE_ARRAY = 0x9103
+ TEXTURE_BINDING_2D_MULTISAMPLE = 0x9104
+ TEXTURE_BINDING_2D_MULTISAMPLE_ARRAY = 0x9105
+ TEXTURE_SAMPLES = 0x9106
+ TEXTURE_FIXED_SAMPLE_LOCATIONS = 0x9107
+ SAMPLER_2D_MULTISAMPLE = 0x9108
+ INT_SAMPLER_2D_MULTISAMPLE = 0x9109
+ UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE = 0x910A
+ SAMPLER_2D_MULTISAMPLE_ARRAY = 0x910B
+ INT_SAMPLER_2D_MULTISAMPLE_ARRAY = 0x910C
+ UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE_ARRAY = 0x910D
+ MAX_COLOR_TEXTURE_SAMPLES = 0x910E
+ MAX_DEPTH_TEXTURE_SAMPLES = 0x910F
+ MAX_INTEGER_SAMPLES = 0x9110
+ MAX_SERVER_WAIT_TIMEOUT = 0x9111
+ OBJECT_TYPE = 0x9112
+ SYNC_CONDITION = 0x9113
+ SYNC_STATUS = 0x9114
+ SYNC_FLAGS = 0x9115
+ SYNC_FENCE = 0x9116
+ SYNC_GPU_COMMANDS_COMPLETE = 0x9117
+ UNSIGNALED = 0x9118
+ SIGNALED = 0x9119
+ ALREADY_SIGNALED = 0x911A
+ TIMEOUT_EXPIRED = 0x911B
+ CONDITION_SATISFIED = 0x911C
+ WAIT_FAILED = 0x911D
+ BUFFER_ACCESS_FLAGS = 0x911F
+ BUFFER_MAP_LENGTH = 0x9120
+ BUFFER_MAP_OFFSET = 0x9121
+ MAX_VERTEX_OUTPUT_COMPONENTS = 0x9122
+ MAX_GEOMETRY_INPUT_COMPONENTS = 0x9123
+ MAX_GEOMETRY_OUTPUT_COMPONENTS = 0x9124
+ MAX_FRAGMENT_INPUT_COMPONENTS = 0x9125
+ CONTEXT_PROFILE_MASK = 0x9126
+)
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glViewport.xml
+func (gl *GL) Viewport(x, y, width, height int) {
+ C.gl3_2core_glViewport(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// DepthRange specifies the mapping of depth values from normalized device
+// coordinates to window coordinates.
+//
+// Parameter nearVal specifies the mapping of the near clipping plane to window
+// coordinates (defaults to 0), while farVal specifies the mapping of the far
+// clipping plane to window coordinates (defaults to 1).
+//
+// After clipping and division by w, depth coordinates range from -1 to 1,
+// corresponding to the near and far clipping planes. DepthRange specifies a
+// linear mapping of the normalized depth coordinates in this range to window
+// depth coordinates. Regardless of the actual depth buffer implementation,
+// window coordinate depth values are treated as though they range from 0 through 1
+// (like color components). Thus, the values accepted by DepthRange are both
+// clamped to this range before they are accepted.
+//
+// The default setting of (0, 1) maps the near plane to 0 and the far plane to 1.
+// With this mapping, the depth buffer range is fully utilized.
+//
+// It is not necessary that nearVal be less than farVal. Reverse mappings such as
+// nearVal 1, and farVal 0 are acceptable.
+//
+// GL.INVALID_OPERATION is generated if DepthRange is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) DepthRange(nearVal, farVal float64) {
+ C.gl3_2core_glDepthRange(gl.funcs, C.GLdouble(nearVal), C.GLdouble(farVal))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsEnabled.xml
+func (gl *GL) IsEnabled(cap glbase.Enum) bool {
+ glresult := C.gl3_2core_glIsEnabled(gl.funcs, C.GLenum(cap))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTexLevelParameteriv.xml
+func (gl *GL) GetTexLevelParameteriv(target glbase.Enum, level int, pname glbase.Enum, params []int32) {
+ C.gl3_2core_glGetTexLevelParameteriv(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTexLevelParameterfv.xml
+func (gl *GL) GetTexLevelParameterfv(target glbase.Enum, level int, pname glbase.Enum, params []float32) {
+ C.gl3_2core_glGetTexLevelParameterfv(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTexParameteriv.xml
+func (gl *GL) GetTexParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl3_2core_glGetTexParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTexParameterfv.xml
+func (gl *GL) GetTexParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl3_2core_glGetTexParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTexImage.xml
+func (gl *GL) GetTexImage(target glbase.Enum, level int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2core_glGetTexImage(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetIntegerv.xml
+func (gl *GL) GetIntegerv(pname glbase.Enum, params []int32) {
+ C.gl3_2core_glGetIntegerv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetFloatv.xml
+func (gl *GL) GetFloatv(pname glbase.Enum, params []float32) {
+ C.gl3_2core_glGetFloatv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetError.xml
+func (gl *GL) GetError() glbase.Enum {
+ glresult := C.gl3_2core_glGetError(gl.funcs)
+ return glbase.Enum(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetDoublev.xml
+func (gl *GL) GetDoublev(pname glbase.Enum, params []float64) {
+ C.gl3_2core_glGetDoublev(gl.funcs, C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetBooleanv.xml
+func (gl *GL) GetBooleanv(pname glbase.Enum, params []bool) {
+ C.gl3_2core_glGetBooleanv(gl.funcs, C.GLenum(pname), (*C.GLboolean)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glReadPixels.xml
+func (gl *GL) ReadPixels(x, y, width, height int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2core_glReadPixels(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glReadBuffer.xml
+func (gl *GL) ReadBuffer(mode glbase.Enum) {
+ C.gl3_2core_glReadBuffer(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPixelStorei.xml
+func (gl *GL) PixelStorei(pname glbase.Enum, param int32) {
+ C.gl3_2core_glPixelStorei(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPixelStoref.xml
+func (gl *GL) PixelStoref(pname glbase.Enum, param float32) {
+ C.gl3_2core_glPixelStoref(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDepthFunc.xml
+func (gl *GL) DepthFunc(glfunc glbase.Enum) {
+ C.gl3_2core_glDepthFunc(gl.funcs, C.GLenum(glfunc))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glStencilOp.xml
+func (gl *GL) StencilOp(fail, zfail, zpass glbase.Enum) {
+ C.gl3_2core_glStencilOp(gl.funcs, C.GLenum(fail), C.GLenum(zfail), C.GLenum(zpass))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glStencilFunc.xml
+func (gl *GL) StencilFunc(glfunc glbase.Enum, ref int32, mask uint32) {
+ C.gl3_2core_glStencilFunc(gl.funcs, C.GLenum(glfunc), C.GLint(ref), C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glLogicOp.xml
+func (gl *GL) LogicOp(opcode glbase.Enum) {
+ C.gl3_2core_glLogicOp(gl.funcs, C.GLenum(opcode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBlendFunc.xml
+func (gl *GL) BlendFunc(sfactor, dfactor glbase.Enum) {
+ C.gl3_2core_glBlendFunc(gl.funcs, C.GLenum(sfactor), C.GLenum(dfactor))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFlush.xml
+func (gl *GL) Flush() {
+ C.gl3_2core_glFlush(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFinish.xml
+func (gl *GL) Finish() {
+ C.gl3_2core_glFinish(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEnable.xml
+func (gl *GL) Enable(cap glbase.Enum) {
+ C.gl3_2core_glEnable(gl.funcs, C.GLenum(cap))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDisable.xml
+func (gl *GL) Disable(cap glbase.Enum) {
+ C.gl3_2core_glDisable(gl.funcs, C.GLenum(cap))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDepthMask.xml
+func (gl *GL) DepthMask(flag bool) {
+ C.gl3_2core_glDepthMask(gl.funcs, *(*C.GLboolean)(unsafe.Pointer(&flag)))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColorMask.xml
+func (gl *GL) ColorMask(red, green, blue, alpha bool) {
+ C.gl3_2core_glColorMask(gl.funcs, *(*C.GLboolean)(unsafe.Pointer(&red)), *(*C.GLboolean)(unsafe.Pointer(&green)), *(*C.GLboolean)(unsafe.Pointer(&blue)), *(*C.GLboolean)(unsafe.Pointer(&alpha)))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glStencilMask.xml
+func (gl *GL) StencilMask(mask uint32) {
+ C.gl3_2core_glStencilMask(gl.funcs, C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClearDepth.xml
+func (gl *GL) ClearDepth(depth float64) {
+ C.gl3_2core_glClearDepth(gl.funcs, C.GLdouble(depth))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClearStencil.xml
+func (gl *GL) ClearStencil(s int32) {
+ C.gl3_2core_glClearStencil(gl.funcs, C.GLint(s))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClearColor.xml
+func (gl *GL) ClearColor(red, green, blue, alpha float32) {
+ C.gl3_2core_glClearColor(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClear.xml
+func (gl *GL) Clear(mask glbase.Bitfield) {
+ C.gl3_2core_glClear(gl.funcs, C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDrawBuffer.xml
+func (gl *GL) DrawBuffer(mode glbase.Enum) {
+ C.gl3_2core_glDrawBuffer(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexImage2D.xml
+func (gl *GL) TexImage2D(target glbase.Enum, level int, internalFormat int32, width, height, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2core_glTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexImage1D.xml
+func (gl *GL) TexImage1D(target glbase.Enum, level int, internalFormat int32, width, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2core_glTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexParameteriv.xml
+func (gl *GL) TexParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl3_2core_glTexParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexParameteri.xml
+func (gl *GL) TexParameteri(target, pname glbase.Enum, param int32) {
+ C.gl3_2core_glTexParameteri(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexParameterfv.xml
+func (gl *GL) TexParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl3_2core_glTexParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexParameterf.xml
+func (gl *GL) TexParameterf(target, pname glbase.Enum, param float32) {
+ C.gl3_2core_glTexParameterf(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glScissor.xml
+func (gl *GL) Scissor(x, y, width, height int) {
+ C.gl3_2core_glScissor(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPolygonMode.xml
+func (gl *GL) PolygonMode(face, mode glbase.Enum) {
+ C.gl3_2core_glPolygonMode(gl.funcs, C.GLenum(face), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPointSize.xml
+func (gl *GL) PointSize(size float32) {
+ C.gl3_2core_glPointSize(gl.funcs, C.GLfloat(size))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glLineWidth.xml
+func (gl *GL) LineWidth(width float32) {
+ C.gl3_2core_glLineWidth(gl.funcs, C.GLfloat(width))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glHint.xml
+func (gl *GL) Hint(target, mode glbase.Enum) {
+ C.gl3_2core_glHint(gl.funcs, C.GLenum(target), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFrontFace.xml
+func (gl *GL) FrontFace(mode glbase.Enum) {
+ C.gl3_2core_glFrontFace(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCullFace.xml
+func (gl *GL) CullFace(mode glbase.Enum) {
+ C.gl3_2core_glCullFace(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIndexubv.xml
+func (gl *GL) Indexubv(c []uint8) {
+ C.gl3_2core_glIndexubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIndexub.xml
+func (gl *GL) Indexub(c uint8) {
+ C.gl3_2core_glIndexub(gl.funcs, C.GLubyte(c))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsTexture.xml
+func (gl *GL) IsTexture(texture glbase.Texture) bool {
+ glresult := C.gl3_2core_glIsTexture(gl.funcs, C.GLuint(texture))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// GenTextures returns n texture names in textures. There is no guarantee
+// that the names form a contiguous set of integers; however, it is
+// guaranteed that none of the returned names was in use immediately before
+// the call to GenTextures.
+//
+// The generated textures have no dimensionality; they assume the
+// dimensionality of the texture target to which they are first bound (see
+// BindTexture).
+//
+// Texture names returned by a call to GenTextures are not returned by
+// subsequent calls, unless they are first deleted with DeleteTextures.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// GenTextures is available in GL version 2.0 or greater.
+func (gl *GL) GenTextures(n int) []glbase.Texture {
+ if n == 0 {
+ return nil
+ }
+ textures := make([]glbase.Texture, n)
+ C.gl3_2core_glGenTextures(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])))
+ return textures
+}
+
+// DeleteTextures deletes the textures objects whose names are stored
+// in the textures slice. After a texture is deleted, it has no contents or
+// dimensionality, and its name is free for reuse (for example by
+// GenTextures). If a texture that is currently bound is deleted, the binding
+// reverts to 0 (the default texture).
+//
+// DeleteTextures silently ignores 0's and names that do not correspond to
+// existing textures.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// DeleteTextures is available in GL version 2.0 or greater.
+func (gl *GL) DeleteTextures(textures []glbase.Texture) {
+ n := len(textures)
+ if n == 0 {
+ return
+ }
+ C.gl3_2core_glDeleteTextures(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBindTexture.xml
+func (gl *GL) BindTexture(target glbase.Enum, texture glbase.Texture) {
+ C.gl3_2core_glBindTexture(gl.funcs, C.GLenum(target), C.GLuint(texture))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexSubImage2D.xml
+func (gl *GL) TexSubImage2D(target glbase.Enum, level, xoffset, yoffset, width, height int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2core_glTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexSubImage1D.xml
+func (gl *GL) TexSubImage1D(target glbase.Enum, level, xoffset, width int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2core_glTexSubImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLsizei(width), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCopyTexSubImage2D.xml
+func (gl *GL) CopyTexSubImage2D(target glbase.Enum, level, xoffset, yoffset, x, y, width, height int) {
+ C.gl3_2core_glCopyTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCopyTexSubImage1D.xml
+func (gl *GL) CopyTexSubImage1D(target glbase.Enum, level, xoffset, x, y, width int) {
+ C.gl3_2core_glCopyTexSubImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(x), C.GLint(y), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCopyTexImage2D.xml
+func (gl *GL) CopyTexImage2D(target glbase.Enum, level int, internalFormat glbase.Enum, x, y, width, height, border int) {
+ C.gl3_2core_glCopyTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height), C.GLint(border))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCopyTexImage1D.xml
+func (gl *GL) CopyTexImage1D(target glbase.Enum, level int, internalFormat glbase.Enum, x, y, width, border int) {
+ C.gl3_2core_glCopyTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLint(border))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPolygonOffset.xml
+func (gl *GL) PolygonOffset(factor, units float32) {
+ C.gl3_2core_glPolygonOffset(gl.funcs, C.GLfloat(factor), C.GLfloat(units))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDrawElements.xml
+func (gl *GL) DrawElements(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2core_glDrawElements(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDrawArrays.xml
+func (gl *GL) DrawArrays(mode glbase.Enum, first, count int) {
+ C.gl3_2core_glDrawArrays(gl.funcs, C.GLenum(mode), C.GLint(first), C.GLsizei(count))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCopyTexSubImage3D.xml
+func (gl *GL) CopyTexSubImage3D(target glbase.Enum, level, xoffset, yoffset int, zoffset int32, x, y, width, height int) {
+ C.gl3_2core_glCopyTexSubImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(zoffset), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexSubImage3D.xml
+func (gl *GL) TexSubImage3D(target glbase.Enum, level, xoffset, yoffset int, zoffset int32, width, height int, depth int32, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2core_glTexSubImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(zoffset), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexImage3D.xml
+func (gl *GL) TexImage3D(target glbase.Enum, level int, internalFormat int32, width, height int, depth int32, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2core_glTexImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDrawRangeElements.xml
+func (gl *GL) DrawRangeElements(mode glbase.Enum, start, end uint32, count int, gltype glbase.Enum, indices interface{}) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2core_glDrawRangeElements(gl.funcs, C.GLenum(mode), C.GLuint(start), C.GLuint(end), C.GLsizei(count), C.GLenum(gltype), indices_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBlendEquation.xml
+func (gl *GL) BlendEquation(mode glbase.Enum) {
+ C.gl3_2core_glBlendEquation(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBlendColor.xml
+func (gl *GL) BlendColor(red, green, blue, alpha float32) {
+ C.gl3_2core_glBlendColor(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetCompressedTexImage.xml
+func (gl *GL) GetCompressedTexImage(target glbase.Enum, level int, img interface{}) {
+ var img_ptr unsafe.Pointer
+ var img_v = reflect.ValueOf(img)
+ if img != nil && img_v.Kind() != reflect.Slice {
+ panic("parameter img must be a slice")
+ }
+ if img != nil {
+ img_ptr = unsafe.Pointer(img_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2core_glGetCompressedTexImage(gl.funcs, C.GLenum(target), C.GLint(level), img_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCompressedTexSubImage1D.xml
+func (gl *GL) CompressedTexSubImage1D(target glbase.Enum, level, xoffset, width int, format glbase.Enum, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2core_glCompressedTexSubImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLsizei(width), C.GLenum(format), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCompressedTexSubImage2D.xml
+func (gl *GL) CompressedTexSubImage2D(target glbase.Enum, level, xoffset, yoffset, width, height int, format glbase.Enum, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2core_glCompressedTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCompressedTexSubImage3D.xml
+func (gl *GL) CompressedTexSubImage3D(target glbase.Enum, level, xoffset, yoffset int, zoffset int32, width, height int, depth int32, format glbase.Enum, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2core_glCompressedTexSubImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(zoffset), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLenum(format), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCompressedTexImage1D.xml
+func (gl *GL) CompressedTexImage1D(target glbase.Enum, level int, internalFormat glbase.Enum, width, border, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2core_glCompressedTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLsizei(width), C.GLint(border), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCompressedTexImage2D.xml
+func (gl *GL) CompressedTexImage2D(target glbase.Enum, level int, internalFormat glbase.Enum, width, height, border, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2core_glCompressedTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLint(border), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCompressedTexImage3D.xml
+func (gl *GL) CompressedTexImage3D(target glbase.Enum, level int, internalFormat glbase.Enum, width, height int, depth int32, border, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2core_glCompressedTexImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLint(border), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSampleCoverage.xml
+func (gl *GL) SampleCoverage(value float32, invert bool) {
+ C.gl3_2core_glSampleCoverage(gl.funcs, C.GLfloat(value), *(*C.GLboolean)(unsafe.Pointer(&invert)))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glActiveTexture.xml
+func (gl *GL) ActiveTexture(texture glbase.Enum) {
+ C.gl3_2core_glActiveTexture(gl.funcs, C.GLenum(texture))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPointParameteriv.xml
+func (gl *GL) PointParameteriv(pname glbase.Enum, params []int32) {
+ C.gl3_2core_glPointParameteriv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPointParameteri.xml
+func (gl *GL) PointParameteri(pname glbase.Enum, param int32) {
+ C.gl3_2core_glPointParameteri(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPointParameterfv.xml
+func (gl *GL) PointParameterfv(pname glbase.Enum, params []float32) {
+ C.gl3_2core_glPointParameterfv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPointParameterf.xml
+func (gl *GL) PointParameterf(pname glbase.Enum, param float32) {
+ C.gl3_2core_glPointParameterf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiDrawArrays.xml
+func (gl *GL) MultiDrawArrays(mode glbase.Enum, first, count []int, drawcount int32) {
+ C.gl3_2core_glMultiDrawArrays(gl.funcs, C.GLenum(mode), (*C.GLint)(unsafe.Pointer(&first[0])), (*C.GLsizei)(unsafe.Pointer(&count[0])), C.GLsizei(drawcount))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBlendFuncSeparate.xml
+func (gl *GL) BlendFuncSeparate(sfactorRGB, dfactorRGB, sfactorAlpha, dfactorAlpha glbase.Enum) {
+ C.gl3_2core_glBlendFuncSeparate(gl.funcs, C.GLenum(sfactorRGB), C.GLenum(dfactorRGB), C.GLenum(sfactorAlpha), C.GLenum(dfactorAlpha))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetBufferParameteriv.xml
+func (gl *GL) GetBufferParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl3_2core_glGetBufferParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glUnmapBuffer.xml
+func (gl *GL) UnmapBuffer(target glbase.Enum) bool {
+ glresult := C.gl3_2core_glUnmapBuffer(gl.funcs, C.GLenum(target))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetBufferSubData.xml
+func (gl *GL) GetBufferSubData(target glbase.Enum, offset, size int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2core_glGetBufferSubData(gl.funcs, C.GLenum(target), C.GLintptr(offset), C.GLsizeiptr(size), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBufferSubData.xml
+func (gl *GL) BufferSubData(target glbase.Enum, offset, size int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2core_glBufferSubData(gl.funcs, C.GLenum(target), C.GLintptr(offset), C.GLsizeiptr(size), data_ptr)
+}
+
+// BufferData creates a new data store for the buffer object currently
+// bound to target. Any pre-existing data store is deleted. The new data
+// store is created with the specified size in bytes and usage. If data is
+// not nil, it must be a slice that is used to initialize the data store.
+// In that case the size parameter is ignored and the store size will match
+// the slice data size.
+//
+// In its initial state, the new data store is not mapped, it has a NULL
+// mapped pointer, and its mapped access is GL.READ_WRITE.
+//
+// The target constant must be one of GL.ARRAY_BUFFER, GL.COPY_READ_BUFFER,
+// GL.COPY_WRITE_BUFFER, GL.ELEMENT_ARRAY_BUFFER, GL.PIXEL_PACK_BUFFER,
+// GL.PIXEL_UNPACK_BUFFER, GL.TEXTURE_BUFFER, GL.TRANSFORM_FEEDBACK_BUFFER,
+// or GL.UNIFORM_BUFFER.
+//
+// The usage parameter is a hint to the GL implementation as to how a buffer
+// object's data store will be accessed. This enables the GL implementation
+// to make more intelligent decisions that may significantly impact buffer
+// object performance. It does not, however, constrain the actual usage of
+// the data store. usage can be broken down into two parts: first, the
+// frequency of access (modification and usage), and second, the nature of
+// that access.
+//
+// A usage frequency of STREAM and nature of DRAW is specified via the
+// constant GL.STREAM_DRAW, for example.
+//
+// The usage frequency of access may be one of:
+//
+// STREAM
+// The data store contents will be modified once and used at most a few times.
+//
+// STATIC
+// The data store contents will be modified once and used many times.
+//
+// DYNAMIC
+// The data store contents will be modified repeatedly and used many times.
+//
+// The usage nature of access may be one of:
+//
+// DRAW
+// The data store contents are modified by the application, and used as
+// the source for GL drawing and image specification commands.
+//
+// READ
+// The data store contents are modified by reading data from the GL,
+// and used to return that data when queried by the application.
+//
+// COPY
+// The data store contents are modified by reading data from the GL,
+// and used as the source for GL drawing and image specification
+// commands.
+//
+// Clients must align data elements consistent with the requirements of the
+// client platform, with an additional base-level requirement that an offset
+// within a buffer to a datum comprising N bytes be a multiple of N.
+//
+// Error GL.INVALID_ENUM is generated if target is not one of the accepted
+// buffer targets. GL.INVALID_ENUM is generated if usage is not
+// GL.STREAM_DRAW, GL.STREAM_READ, GL.STREAM_COPY, GL.STATIC_DRAW,
+// GL.STATIC_READ, GL.STATIC_COPY, GL.DYNAMIC_DRAW, GL.DYNAMIC_READ, or
+// GL.DYNAMIC_COPY. GL.INVALID_VALUE is generated if size is negative.
+// GL.INVALID_OPERATION is generated if the reserved buffer object name 0 is
+// bound to target. GL.OUT_OF_MEMORY is generated if the GL is unable to
+// create a data store with the specified size.
+func (gl *GL) BufferData(target glbase.Enum, size int, data interface{}, usage glbase.Enum) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ if data != nil {
+ size = int(data_v.Type().Size()) * data_v.Len()
+ }
+ C.gl3_2core_glBufferData(gl.funcs, C.GLenum(target), C.GLsizeiptr(size), data_ptr, C.GLenum(usage))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsBuffer.xml
+func (gl *GL) IsBuffer(buffer glbase.Buffer) bool {
+ glresult := C.gl3_2core_glIsBuffer(gl.funcs, C.GLuint(buffer))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// GenBuffers returns n buffer object names. There is no guarantee that
+// the names form a contiguous set of integers; however, it is guaranteed
+// that none of the returned names was in use immediately before the call to
+// GenBuffers.
+//
+// Buffer object names returned by a call to GenBuffers are not returned by
+// subsequent calls, unless they are first deleted with DeleteBuffers.
+//
+// No buffer objects are associated with the returned buffer object names
+// until they are first bound by calling BindBuffer.
+//
+// Error GL.INVALID_VALUE is generated if n is negative. GL.INVALID_OPERATION
+// is generated if GenBuffers is executed between the execution of Begin
+// and the corresponding execution of End.
+//
+// GenBuffers is available in GL version 1.5 or greater.
+func (gl *GL) GenBuffers(n int) []glbase.Buffer {
+ if n == 0 {
+ return nil
+ }
+ buffers := make([]glbase.Buffer, n)
+ C.gl3_2core_glGenBuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&buffers[0])))
+ return buffers
+}
+
+// DeleteBuffers deletes the buffer objects whose names are stored in the
+// buffers slice.
+//
+// After a buffer object is deleted, it has no contents, and its name is free
+// for reuse (for example by GenBuffers). If a buffer object that is
+// currently bound is deleted, the binding reverts to 0 (the absence of any
+// buffer object, which reverts to client memory usage).
+//
+// DeleteBuffers silently ignores 0's and names that do not correspond to
+// existing buffer objects.
+//
+// Error GL.INVALID_VALUE is generated if n is negative. GL.INVALID_OPERATION
+// is generated if DeleteBuffers is executed between the execution of Begin
+// and the corresponding execution of End.
+//
+// DeleteBuffers is available in GL version 1.5 or greater.
+func (gl *GL) DeleteBuffers(buffers []glbase.Buffer) {
+ n := len(buffers)
+ if n == 0 {
+ return
+ }
+ C.gl3_2core_glDeleteBuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&buffers[0])))
+}
+
+// BindBuffer creates or puts in use a named buffer object.
+// Calling BindBuffer with target set to GL.ARRAY_BUFFER,
+// GL.ELEMENT_ARRAY_BUFFER, GL.PIXEL_PACK_BUFFER or GL.PIXEL_UNPACK_BUFFER
+// and buffer set to the name of the new buffer object binds the buffer
+// object name to the target. When a buffer object is bound to a target, the
+// previous binding for that target is automatically broken.
+//
+// Buffer object names are unsigned integers. The value zero is reserved, but
+// there is no default buffer object for each buffer object target. Instead,
+// buffer set to zero effectively unbinds any buffer object previously bound,
+// and restores client memory usage for that buffer object target. Buffer
+// object names and the corresponding buffer object contents are local to the
+// shared display-list space (see XCreateContext) of the current GL rendering
+// context; two rendering contexts share buffer object names only if they
+// also share display lists.
+//
+// GenBuffers may be called to generate a set of new buffer object names.
+//
+// The state of a buffer object immediately after it is first bound is an
+// unmapped zero-sized memory buffer with GL.READ_WRITE access and
+// GL.STATIC_DRAW usage.
+//
+// While a non-zero buffer object name is bound, GL operations on the target
+// to which it is bound affect the bound buffer object, and queries of the
+// target to which it is bound return state from the bound buffer object.
+// While buffer object name zero is bound, as in the initial state, attempts
+// to modify or query state on the target to which it is bound generates an
+// GL.INVALID_OPERATION error.
+//
+// When vertex array pointer state is changed, for example by a call to
+// NormalPointer, the current buffer object binding (GL.ARRAY_BUFFER_BINDING)
+// is copied into the corresponding client state for the vertex array type
+// being changed, for example GL.NORMAL_ARRAY_BUFFER_BINDING. While a
+// non-zero buffer object is bound to the GL.ARRAY_BUFFER target, the vertex
+// array pointer parameter that is traditionally interpreted as a pointer to
+// client-side memory is instead interpreted as an offset within the buffer
+// object measured in basic machine units.
+//
+// While a non-zero buffer object is bound to the GL.ELEMENT_ARRAY_BUFFER
+// target, the indices parameter of DrawElements, DrawRangeElements, or
+// MultiDrawElements that is traditionally interpreted as a pointer to
+// client-side memory is instead interpreted as an offset within the buffer
+// object measured in basic machine units.
+//
+// While a non-zero buffer object is bound to the GL.PIXEL_PACK_BUFFER
+// target, the following commands are affected: GetCompressedTexImage,
+// GetConvolutionFilter, GetHistogram, GetMinmax, GetPixelMap,
+// GetPolygonStipple, GetSeparableFilter, GetTexImage, and ReadPixels. The
+// pointer parameter that is traditionally interpreted as a pointer to
+// client-side memory where the pixels are to be packed is instead
+// interpreted as an offset within the buffer object measured in basic
+// machine units.
+//
+// While a non-zero buffer object is bound to the GL.PIXEL_UNPACK_BUFFER
+// target, the following commands are affected: Bitmap, ColorSubTable,
+// ColorTable, CompressedTexImage1D, CompressedTexImage2D,
+// CompressedTexImage3D, CompressedTexSubImage1D, CompressedTexSubImage2D,
+// CompressedTexSubImage3D, ConvolutionFilter1D, ConvolutionFilter2D,
+// DrawPixels, PixelMap, PolygonStipple, SeparableFilter2D, TexImage1D,
+// TexImage2D, TexImage3D, TexSubImage1D, TexSubImage2D, and TexSubImage3D.
+// The pointer parameter that is traditionally interpreted as a pointer to
+// client-side memory from which the pixels are to be unpacked is instead
+// interpreted as an offset within the buffer object measured in basic
+// machine units.
+//
+// A buffer object binding created with BindBuffer remains active until a
+// different buffer object name is bound to the same target, or until the
+// bound buffer object is deleted with DeleteBuffers.
+//
+// Once created, a named buffer object may be re-bound to any target as often
+// as needed. However, the GL implementation may make choices about how to
+// optimize the storage of a buffer object based on its initial binding
+// target.
+//
+// Error GL.INVALID_ENUM is generated if target is not one of the allowable
+// values. GL.INVALID_OPERATION is generated if BindBuffer is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// BindBuffer is available in GL version 1.5 or greater.
+func (gl *GL) BindBuffer(target glbase.Enum, buffer glbase.Buffer) {
+ C.gl3_2core_glBindBuffer(gl.funcs, C.GLenum(target), C.GLuint(buffer))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetQueryObjectuiv.xml
+func (gl *GL) GetQueryObjectuiv(id uint32, pname glbase.Enum, params []uint32) {
+ C.gl3_2core_glGetQueryObjectuiv(gl.funcs, C.GLuint(id), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetQueryObjectiv.xml
+func (gl *GL) GetQueryObjectiv(id uint32, pname glbase.Enum, params []int32) {
+ C.gl3_2core_glGetQueryObjectiv(gl.funcs, C.GLuint(id), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetQueryiv.xml
+func (gl *GL) GetQueryiv(target, pname glbase.Enum, params []int32) {
+ C.gl3_2core_glGetQueryiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEndQuery.xml
+func (gl *GL) EndQuery(target glbase.Enum) {
+ C.gl3_2core_glEndQuery(gl.funcs, C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBeginQuery.xml
+func (gl *GL) BeginQuery(target glbase.Enum, id uint32) {
+ C.gl3_2core_glBeginQuery(gl.funcs, C.GLenum(target), C.GLuint(id))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsQuery.xml
+func (gl *GL) IsQuery(id uint32) bool {
+ glresult := C.gl3_2core_glIsQuery(gl.funcs, C.GLuint(id))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDeleteQueries.xml
+func (gl *GL) DeleteQueries(n int, ids []uint32) {
+ C.gl3_2core_glDeleteQueries(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&ids[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGenQueries.xml
+func (gl *GL) GenQueries(n int, ids []uint32) {
+ C.gl3_2core_glGenQueries(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&ids[0])))
+}
+
+// VertexAttribPointer specifies the location and data format of the array
+// of generic vertex attributes at index to use when rendering. size
+// specifies the number of components per attribute and must be 1, 2, 3, or
+// 4. type specifies the data type of each component, and stride specifies
+// the byte stride from one attribute to the next, allowing vertices and
+// attributes to be packed into a single array or stored in separate arrays.
+// normalized indicates whether the values stored in an integer format are
+// to be mapped to the range [-1,1] (for signed values) or [0,1]
+// (for unsigned values) when they are accessed and converted to floating
+// point; otherwise, values will be converted to floats directly without
+// normalization. offset is a byte offset into the buffer object's data
+// store, which must be bound to the GL.ARRAY_BUFFER target with BindBuffer.
+//
+// The buffer object binding (GL.ARRAY_BUFFER_BINDING) is saved as
+// generic vertex attribute array client-side state
+// (GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING) for the provided index.
+//
+// To enable and disable a generic vertex attribute array, call
+// EnableVertexAttribArray and DisableVertexAttribArray with index. If
+// enabled, the generic vertex attribute array is used when DrawArrays or
+// DrawElements is called. Each generic vertex attribute array is initially
+// disabled.
+//
+// VertexAttribPointer is typically implemented on the client side.
+//
+// Error GL.INVALID_ENUM is generated if type is not an accepted value.
+// GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_VALUE is generated if size is not 1, 2,
+// 3, or 4. GL.INVALID_VALUE is generated if stride is negative.
+func (gl *GL) VertexAttribPointer(index glbase.Attrib, size int, gltype glbase.Enum, normalized bool, stride int, offset uintptr) {
+ offset_ptr := unsafe.Pointer(offset)
+ C.gl3_2core_glVertexAttribPointer(gl.funcs, C.GLuint(index), C.GLint(size), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), C.GLsizei(stride), offset_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glValidateProgram.xml
+func (gl *GL) ValidateProgram(program glbase.Program) {
+ C.gl3_2core_glValidateProgram(gl.funcs, C.GLuint(program))
+}
+
+// UniformMatrix4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix4fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(4*4) != 0 {
+ panic("invalid value length for UniformMatrix4fv")
+ }
+ count := len(value) / (4 * 4)
+ C.gl3_2core_glUniformMatrix4fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix3fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(3*3) != 0 {
+ panic("invalid value length for UniformMatrix3fv")
+ }
+ count := len(value) / (3 * 3)
+ C.gl3_2core_glUniformMatrix3fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix2fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(2*2) != 0 {
+ panic("invalid value length for UniformMatrix2fv")
+ }
+ count := len(value) / (2 * 2)
+ C.gl3_2core_glUniformMatrix2fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform4iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%4 != 0 {
+ panic("invalid value length for Uniform4iv")
+ }
+ count := len(value) / 4
+ C.gl3_2core_glUniform4iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform3iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform3iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%3 != 0 {
+ panic("invalid value length for Uniform3iv")
+ }
+ count := len(value) / 3
+ C.gl3_2core_glUniform3iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform2iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform2iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%2 != 0 {
+ panic("invalid value length for Uniform2iv")
+ }
+ count := len(value) / 2
+ C.gl3_2core_glUniform2iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform1iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform1iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ count := len(value)
+ C.gl3_2core_glUniform1iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%4 != 0 {
+ panic("invalid value length for Uniform4fv")
+ }
+ count := len(value) / 4
+ C.gl3_2core_glUniform4fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%3 != 0 {
+ panic("invalid value length for Uniform3fv")
+ }
+ count := len(value) / 3
+ C.gl3_2core_glUniform3fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%2 != 0 {
+ panic("invalid value length for Uniform2fv")
+ }
+ count := len(value) / 2
+ C.gl3_2core_glUniform2fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform1fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform1fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ count := len(value)
+ C.gl3_2core_glUniform1fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform4i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4i(location glbase.Uniform, v0, v1, v2, v3 int32) {
+ C.gl3_2core_glUniform4i(gl.funcs, C.GLint(location), C.GLint(v0), C.GLint(v1), C.GLint(v2), C.GLint(v3))
+}
+
+// Uniform3i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform3i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3i(location glbase.Uniform, v0, v1, v2 int32) {
+ C.gl3_2core_glUniform3i(gl.funcs, C.GLint(location), C.GLint(v0), C.GLint(v1), C.GLint(v2))
+}
+
+// Uniform2i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform2i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2i(location glbase.Uniform, v0, v1 int32) {
+ C.gl3_2core_glUniform2i(gl.funcs, C.GLint(location), C.GLint(v0), C.GLint(v1))
+}
+
+// Uniform1i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform1i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1i(location glbase.Uniform, v0 int32) {
+ C.gl3_2core_glUniform1i(gl.funcs, C.GLint(location), C.GLint(v0))
+}
+
+// Uniform4f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform4f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4f(location glbase.Uniform, v0, v1, v2, v3 float32) {
+ C.gl3_2core_glUniform4f(gl.funcs, C.GLint(location), C.GLfloat(v0), C.GLfloat(v1), C.GLfloat(v2), C.GLfloat(v3))
+}
+
+// Uniform3f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform3f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3f(location glbase.Uniform, v0, v1, v2 float32) {
+ C.gl3_2core_glUniform3f(gl.funcs, C.GLint(location), C.GLfloat(v0), C.GLfloat(v1), C.GLfloat(v2))
+}
+
+// Uniform2f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform2f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2f(location glbase.Uniform, v0, v1 float32) {
+ C.gl3_2core_glUniform2f(gl.funcs, C.GLint(location), C.GLfloat(v0), C.GLfloat(v1))
+}
+
+// Uniform1f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform1f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1f(location glbase.Uniform, v0 float32) {
+ C.gl3_2core_glUniform1f(gl.funcs, C.GLint(location), C.GLfloat(v0))
+}
+
+// UseProgram installs the program object specified by program as part of
+// current rendering state. One or more executables are created in a program
+// object by successfully attaching shader objects to it with AttachShader,
+// successfully compiling the shader objects with CompileShader, and
+// successfully linking the program object with LinkProgram.
+//
+// A program object will contain an executable that will run on the vertex
+// processor if it contains one or more shader objects of type
+// GL.VERTEX_SHADER that have been successfully compiled and linked.
+// Similarly, a program object will contain an executable that will run on
+// the fragment processor if it contains one or more shader objects of type
+// GL.FRAGMENT_SHADER that have been successfully compiled and linked.
+//
+// Successfully installing an executable on a programmable processor will
+// cause the corresponding fixed functionality of OpenGL to be disabled.
+// Specifically, if an executable is installed on the vertex processor, the
+// OpenGL fixed functionality will be disabled as follows.
+//
+// - The modelview matrix is not applied to vertex coordinates.
+//
+// - The projection matrix is not applied to vertex coordinates.
+//
+// - The texture matrices are not applied to texture coordinates.
+//
+// - Normals are not transformed to eye coordinates.
+//
+// - Normals are not rescaled or normalized.
+//
+// - Normalization of GL.AUTO_NORMAL evaluated normals is not performed.
+//
+// - Texture coordinates are not generated automatically.
+//
+// - Per-vertex lighting is not performed.
+//
+// - Color material computations are not performed.
+//
+// - Color index lighting is not performed.
+//
+// - This list also applies when setting the current raster position.
+//
+// The executable that is installed on the vertex processor is expected to
+// implement any or all of the desired functionality from the preceding list.
+// Similarly, if an executable is installed on the fragment processor, the
+// OpenGL fixed functionality will be disabled as follows.
+//
+// - Texture environment and texture functions are not applied.
+//
+// - Texture application is not applied.
+//
+// - Color sum is not applied.
+//
+// - Fog is not applied.
+//
+// Again, the fragment shader that is installed is expected to implement any
+// or all of the desired functionality from the preceding list.
+//
+// While a program object is in use, applications are free to modify attached
+// shader objects, compile attached shader objects, attach additional shader
+// objects, and detach or delete shader objects. None of these operations
+// will affect the executables that are part of the current state. However,
+// relinking the program object that is currently in use will install the
+// program object as part of the current rendering state if the link
+// operation was successful (see LinkProgram). If the program object
+// currently in use is relinked unsuccessfully, its link status will be set
+// to GL.FALSE, but the executables and associated state will remain part of
+// the current state until a subsequent call to UseProgram removes it from
+// use. After it is removed from use, it cannot be made part of current state
+// until it has been successfully relinked.
+//
+// If program contains shader objects of type GL.VERTEX_SHADER but it does
+// not contain shader objects of type GL.FRAGMENT_SHADER, an executable will
+// be installed on the vertex processor, but fixed functionality will be used
+// for fragment processing. Similarly, if program contains shader objects of
+// type GL.FRAGMENT_SHADER but it does not contain shader objects of type
+// GL.VERTEX_SHADER, an executable will be installed on the fragment
+// processor, but fixed functionality will be used for vertex processing. If
+// program is 0, the programmable processors will be disabled, and fixed
+// functionality will be used for both vertex and fragment processing.
+//
+// While a program object is in use, the state that controls the disabled
+// fixed functionality may also be updated using the normal OpenGL calls.
+//
+// Like display lists and texture objects, the name space for program objects
+// may be shared across a set of contexts, as long as the server sides of the
+// contexts share the same address space. If the name space is shared across
+// contexts, any attached objects and the data associated with those attached
+// objects are shared as well.
+//
+// Applications are responsible for providing the synchronization across API
+// calls when objects are accessed from different execution threads.
+//
+// Error GL.INVALID_VALUE is generated if program is neither 0 nor a value
+// generated by OpenGL. GL.INVALID_OPERATION is generated if program is not
+// a program object. GL.INVALID_OPERATION is generated if program could not
+// be made part of current state. GL.INVALID_OPERATION is generated if
+// UseProgram is executed between the execution of Begin and the
+// corresponding execution of End.
+//
+// UseProgram is available in GL version 2.0 or greater.
+func (gl *GL) UseProgram(program glbase.Program) {
+ C.gl3_2core_glUseProgram(gl.funcs, C.GLuint(program))
+}
+
+// ShaderSource sets the source code in shader to the provided source code. Any source
+// code previously stored in the shader object is completely replaced.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader is not a shader
+// object. GL.INVALID_VALUE is generated if count is less than 0.
+// GL.INVALID_OPERATION is generated if ShaderSource is executed between the
+// execution of Begin and the corresponding execution of End.
+//
+// ShaderSource is available in GL version 2.0 or greater.
+func (gl *GL) ShaderSource(shader glbase.Shader, source ...string) {
+ count := len(source)
+ length := make([]int32, count)
+ source_c := make([]unsafe.Pointer, count)
+ for i, src := range source {
+ length[i] = int32(len(src))
+ if len(src) > 0 {
+ source_c[i] = *(*unsafe.Pointer)(unsafe.Pointer(&src))
+ } else {
+ source_c[i] = unsafe.Pointer(uintptr(0))
+ }
+ }
+ C.gl3_2core_glShaderSource(gl.funcs, C.GLuint(shader), C.GLsizei(count), (**C.GLchar)(unsafe.Pointer(&source_c[0])), (*C.GLint)(unsafe.Pointer(&length[0])))
+}
+
+// LinkProgram links the program object specified by program. If any shader
+// objects of type GL.VERTEX_SHADER are attached to program, they will be
+// used to create an executable that will run on the programmable vertex
+// processor. If any shader objects of type GL.FRAGMENT_SHADER are attached
+// to program, they will be used to create an executable that will run on the
+// programmable fragment processor.
+//
+// The status of the link operation will be stored as part of the program
+// object's state. This value will be set to GL.TRUE if the program object
+// was linked without errors and is ready for use, and GL.FALSE otherwise. It
+// can be queried by calling GetProgramiv with arguments program and
+// GL.LINK_STATUS.
+//
+// As a result of a successful link operation, all active user-defined
+// uniform variables belonging to program will be initialized to 0, and each
+// of the program object's active uniform variables will be assigned a
+// location that can be queried by calling GetUniformLocation. Also, any
+// active user-defined attribute variables that have not been bound to a
+// generic vertex attribute index will be bound to one at this time.
+//
+// Linking of a program object can fail for a number of reasons as specified
+// in the OpenGL Shading Language Specification. The following lists some of
+// the conditions that will cause a link error.
+//
+// - The number of active attribute variables supported by the
+// implementation has been exceeded.
+//
+// - The storage limit for uniform variables has been exceeded.
+//
+// - The number of active uniform variables supported by the implementation
+// has been exceeded.
+//
+// - The main function is missing for the vertex shader or the fragment
+// shader.
+//
+// - A varying variable actually used in the fragment shader is not
+// declared in the same way (or is not declared at all) in the vertex
+// shader.
+//
+// - A reference to a function or variable name is unresolved.
+//
+// - A shared global is declared with two different types or two different
+// initial values.
+//
+// - One or more of the attached shader objects has not been successfully
+// compiled.
+//
+// - Binding a generic attribute matrix caused some rows of the matrix to
+// fall outside the allowed maximum of GL.MAX_VERTEX_ATTRIBS.
+//
+// - Not enough contiguous vertex attribute slots could be found to bind
+// attribute matrices.
+//
+// When a program object has been successfully linked, the program object can
+// be made part of current state by calling UseProgram. Whether or not the
+// link operation was successful, the program object's information log will
+// be overwritten. The information log can be retrieved by calling
+// GetProgramInfoLog.
+//
+// LinkProgram will also install the generated executables as part of the
+// current rendering state if the link operation was successful and the
+// specified program object is already currently in use as a result of a
+// previous call to UseProgram. If the program object currently in use is
+// relinked unsuccessfully, its link status will be set to GL.FALSE , but the
+// executables and associated state will remain part of the current state
+// until a subsequent call to UseProgram removes it from use. After it is
+// removed from use, it cannot be made part of current state until it has
+// been successfully relinked.
+//
+// If program contains shader objects of type GL.VERTEX_SHADER but does not
+// contain shader objects of type GL.FRAGMENT_SHADER, the vertex shader will
+// be linked against the implicit interface for fixed functionality fragment
+// processing. Similarly, if program contains shader objects of type
+// GL.FRAGMENT_SHADER but it does not contain shader objects of type
+// GL.VERTEX_SHADER, the fragment shader will be linked against the implicit
+// interface for fixed functionality vertex processing.
+//
+// The program object's information log is updated and the program is
+// generated at the time of the link operation. After the link operation,
+// applications are free to modify attached shader objects, compile attached
+// shader objects, detach shader objects, delete shader objects, and attach
+// additional shader objects. None of these operations affects the
+// information log or the program that is part of the program object.
+//
+// If the link operation is unsuccessful, any information about a previous
+// link operation on program is lost (a failed link does not restore the
+// old state of program). Certain information can still be retrieved
+// from program even after an unsuccessful link operation. See for instance
+// GetActiveAttrib and GetActiveUniform.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program
+// object. GL.INVALID_OPERATION is generated if LinkProgram is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// LinkProgram is available in GL version 2.0 or greater.
+func (gl *GL) LinkProgram(program glbase.Program) {
+ C.gl3_2core_glLinkProgram(gl.funcs, C.GLuint(program))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsShader.xml
+func (gl *GL) IsShader(shader glbase.Shader) bool {
+ glresult := C.gl3_2core_glIsShader(gl.funcs, C.GLuint(shader))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsProgram.xml
+func (gl *GL) IsProgram(program glbase.Program) bool {
+ glresult := C.gl3_2core_glIsProgram(gl.funcs, C.GLuint(program))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// GetVertexAttribiv returns in params the value of a generic vertex attribute
+// parameter. The generic vertex attribute to be queried is specified by
+// index, and the parameter to be queried is specified by pname.
+//
+// The accepted parameter names are as follows:
+//
+// GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING
+// params returns a single value, the name of the buffer object
+// currently bound to the binding point corresponding to generic vertex
+// attribute array index. If no buffer object is bound, 0 is returned.
+// The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_ENABLED
+// params returns a single value that is non-zero (true) if the vertex
+// attribute array for index is enabled and 0 (false) if it is
+// disabled. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_SIZE
+// params returns a single value, the size of the vertex attribute
+// array for index. The size is the number of values for each element
+// of the vertex attribute array, and it will be 1, 2, 3, or 4. The
+// initial value is 4.
+//
+// GL.VERTEX_ATTRIB_ARRAY_STRIDE
+// params returns a single value, the array stride for (number of bytes
+// between successive elements in) the vertex attribute array for
+// index. A value of 0 indicates that the array elements are stored
+// sequentially in memory. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_TYPE
+// params returns a single value, a symbolic constant indicating the
+// array type for the vertex attribute array for index. Possible values
+// are GL.BYTE, GL.UNSIGNED_BYTE, GL.SHORT, GL.UNSIGNED_SHORT, GL.INT,
+// GL.UNSIGNED_INT, GL.FLOAT, and GL.DOUBLE. The initial value is
+// GL.FLOAT.
+//
+// GL.VERTEX_ATTRIB_ARRAY_NORMALIZED
+// params returns a single value that is non-zero (true) if fixed-point
+// data types for the vertex attribute array indicated by index are
+// normalized when they are converted to floating point, and 0 (false)
+// otherwise. The initial value is 0.
+//
+// GL.CURRENT_VERTEX_ATTRIB
+// params returns four values that represent the current value for the
+// generic vertex attribute specified by index. Generic vertex
+// attribute 0 is unique in that it has no current state, so an error
+// will be generated if index is 0. The initial value for all other
+// generic vertex attributes is (0,0,0,1).
+//
+// All of the parameters except GL.CURRENT_VERTEX_ATTRIB represent
+// client-side state.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_ENUM is generated if pname is not an
+// accepted value. GL.INVALID_OPERATION is generated if index is 0 and pname
+// is GL.CURRENT_VERTEX_ATTRIB.
+//
+// GetVertexAttribiv is available in GL version 2.0 or greater.
+func (gl *GL) GetVertexAttribiv(index glbase.Attrib, pname glbase.Enum, params []int32) {
+ var params_c [4]int32
+ C.gl3_2core_glGetVertexAttribiv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetVertexAttribfv returns in params the value of a generic vertex attribute
+// parameter. The generic vertex attribute to be queried is specified by
+// index, and the parameter to be queried is specified by pname.
+//
+// The accepted parameter names are as follows:
+//
+// GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING
+// params returns a single value, the name of the buffer object
+// currently bound to the binding point corresponding to generic vertex
+// attribute array index. If no buffer object is bound, 0 is returned.
+// The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_ENABLED
+// params returns a single value that is non-zero (true) if the vertex
+// attribute array for index is enabled and 0 (false) if it is
+// disabled. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_SIZE
+// params returns a single value, the size of the vertex attribute
+// array for index. The size is the number of values for each element
+// of the vertex attribute array, and it will be 1, 2, 3, or 4. The
+// initial value is 4.
+//
+// GL.VERTEX_ATTRIB_ARRAY_STRIDE
+// params returns a single value, the array stride for (number of bytes
+// between successive elements in) the vertex attribute array for
+// index. A value of 0 indicates that the array elements are stored
+// sequentially in memory. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_TYPE
+// params returns a single value, a symbolic constant indicating the
+// array type for the vertex attribute array for index. Possible values
+// are GL.BYTE, GL.UNSIGNED_BYTE, GL.SHORT, GL.UNSIGNED_SHORT, GL.INT,
+// GL.UNSIGNED_INT, GL.FLOAT, and GL.DOUBLE. The initial value is
+// GL.FLOAT.
+//
+// GL.VERTEX_ATTRIB_ARRAY_NORMALIZED
+// params returns a single value that is non-zero (true) if fixed-point
+// data types for the vertex attribute array indicated by index are
+// normalized when they are converted to floating point, and 0 (false)
+// otherwise. The initial value is 0.
+//
+// GL.CURRENT_VERTEX_ATTRIB
+// params returns four values that represent the current value for the
+// generic vertex attribute specified by index. Generic vertex
+// attribute 0 is unique in that it has no current state, so an error
+// will be generated if index is 0. The initial value for all other
+// generic vertex attributes is (0,0,0,1).
+//
+// All of the parameters except GL.CURRENT_VERTEX_ATTRIB represent
+// client-side state.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_ENUM is generated if pname is not an
+// accepted value. GL.INVALID_OPERATION is generated if index is 0 and pname
+// is GL.CURRENT_VERTEX_ATTRIB.
+//
+// GetVertexAttribfv is available in GL version 2.0 or greater.
+func (gl *GL) GetVertexAttribfv(index glbase.Attrib, pname glbase.Enum, params []float32) {
+ var params_c [4]float32
+ C.gl3_2core_glGetVertexAttribfv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetVertexAttribdv returns in params the value of a generic vertex attribute
+// parameter. The generic vertex attribute to be queried is specified by
+// index, and the parameter to be queried is specified by pname.
+//
+// The accepted parameter names are as follows:
+//
+// GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING
+// params returns a single value, the name of the buffer object
+// currently bound to the binding point corresponding to generic vertex
+// attribute array index. If no buffer object is bound, 0 is returned.
+// The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_ENABLED
+// params returns a single value that is non-zero (true) if the vertex
+// attribute array for index is enabled and 0 (false) if it is
+// disabled. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_SIZE
+// params returns a single value, the size of the vertex attribute
+// array for index. The size is the number of values for each element
+// of the vertex attribute array, and it will be 1, 2, 3, or 4. The
+// initial value is 4.
+//
+// GL.VERTEX_ATTRIB_ARRAY_STRIDE
+// params returns a single value, the array stride for (number of bytes
+// between successive elements in) the vertex attribute array for
+// index. A value of 0 indicates that the array elements are stored
+// sequentially in memory. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_TYPE
+// params returns a single value, a symbolic constant indicating the
+// array type for the vertex attribute array for index. Possible values
+// are GL.BYTE, GL.UNSIGNED_BYTE, GL.SHORT, GL.UNSIGNED_SHORT, GL.INT,
+// GL.UNSIGNED_INT, GL.FLOAT, and GL.DOUBLE. The initial value is
+// GL.FLOAT.
+//
+// GL.VERTEX_ATTRIB_ARRAY_NORMALIZED
+// params returns a single value that is non-zero (true) if fixed-point
+// data types for the vertex attribute array indicated by index are
+// normalized when they are converted to floating point, and 0 (false)
+// otherwise. The initial value is 0.
+//
+// GL.CURRENT_VERTEX_ATTRIB
+// params returns four values that represent the current value for the
+// generic vertex attribute specified by index. Generic vertex
+// attribute 0 is unique in that it has no current state, so an error
+// will be generated if index is 0. The initial value for all other
+// generic vertex attributes is (0,0,0,1).
+//
+// All of the parameters except GL.CURRENT_VERTEX_ATTRIB represent
+// client-side state.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_ENUM is generated if pname is not an
+// accepted value. GL.INVALID_OPERATION is generated if index is 0 and pname
+// is GL.CURRENT_VERTEX_ATTRIB.
+//
+// GetVertexAttribdv is available in GL version 2.0 or greater.
+func (gl *GL) GetVertexAttribdv(index glbase.Attrib, pname glbase.Enum, params []float64) {
+ var params_c [4]float64
+ C.gl3_2core_glGetVertexAttribdv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetUniformiv returns in params the value of the specified uniform
+// variable. The type of the uniform variable specified by location
+// determines the number of values returned. If the uniform variable is
+// defined in the shader as a boolean, int, or float, a single value will be
+// returned. If it is defined as a vec2, ivec2, or bvec2, two values will be
+// returned. If it is defined as a vec3, ivec3, or bvec3, three values will
+// be returned, and so on. To query values stored in uniform variables
+// declared as arrays, call GetUniformiv for each element of the array. To
+// query values stored in uniform variables declared as structures, call
+// GetUniformiv for each field in the structure. The values for uniform
+// variables declared as a matrix will be returned in column major order.
+//
+// The locations assigned to uniform variables are not known until the
+// program object is linked. After linking has occurred, the command
+// GetUniformLocation can be used to obtain the location of a uniform
+// variable. This location value can then be passed to GetUniformiv in order
+// to query the current value of the uniform variable. After a program object
+// has been linked successfully, the index values for uniform variables
+// remain fixed until the next link command occurs. The uniform variable
+// values can only be queried after a link if the link was successful.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program
+// object. GL.INVALID_OPERATION is generated if program has not been
+// successfully linked. GL.INVALID_OPERATION is generated if location does
+// not correspond to a valid uniform variable location for the specified
+// program object. GL.INVALID_OPERATION is generated if GetUniformiv is
+// executed between the execution of Begin and the corresponding execution of
+// End.
+//
+// GetUniformiv is available in GL version 2.0 or greater.
+func (gl *GL) GetUniformiv(program glbase.Program, location glbase.Uniform, params []int32) {
+ var params_c [4]int32
+ C.gl3_2core_glGetUniformiv(gl.funcs, C.GLuint(program), C.GLint(location), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetUniformfv returns in params the value of the specified uniform
+// variable. The type of the uniform variable specified by location
+// determines the number of values returned. If the uniform variable is
+// defined in the shader as a boolean, int, or float, a single value will be
+// returned. If it is defined as a vec2, ivec2, or bvec2, two values will be
+// returned. If it is defined as a vec3, ivec3, or bvec3, three values will
+// be returned, and so on. To query values stored in uniform variables
+// declared as arrays, call GetUniformfv for each element of the array. To
+// query values stored in uniform variables declared as structures, call
+// GetUniformfv for each field in the structure. The values for uniform
+// variables declared as a matrix will be returned in column major order.
+//
+// The locations assigned to uniform variables are not known until the
+// program object is linked. After linking has occurred, the command
+// GetUniformLocation can be used to obtain the location of a uniform
+// variable. This location value can then be passed to GetUniformfv in order
+// to query the current value of the uniform variable. After a program object
+// has been linked successfully, the index values for uniform variables
+// remain fixed until the next link command occurs. The uniform variable
+// values can only be queried after a link if the link was successful.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program
+// object. GL.INVALID_OPERATION is generated if program has not been
+// successfully linked. GL.INVALID_OPERATION is generated if location does
+// not correspond to a valid uniform variable location for the specified
+// program object. GL.INVALID_OPERATION is generated if GetUniformfv is
+// executed between the execution of Begin and the corresponding execution of
+// End.
+//
+// GetUniformfv is available in GL version 2.0 or greater.
+func (gl *GL) GetUniformfv(program glbase.Program, location glbase.Uniform, params []float32) {
+ var params_c [4]float32
+ C.gl3_2core_glGetUniformfv(gl.funcs, C.GLuint(program), C.GLint(location), (*C.GLfloat)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetUniformLocation returns an integer that represents the location of a
+// specific uniform variable within a program object. name must be an active
+// uniform variable name in program that is not a structure, an array of
+// structures, or a subcomponent of a vector or a matrix. This function
+// returns -1 if name does not correspond to an active uniform variable in
+// program or if name starts with the reserved prefix "gl_".
+//
+// Uniform variables that are structures or arrays of structures may be
+// queried by calling GetUniformLocation for each field within the
+// structure. The array element operator "[]" and the structure field
+// operator "." may be used in name in order to select elements within an
+// array or fields within a structure. The result of using these operators is
+// not allowed to be another structure, an array of structures, or a
+// subcomponent of a vector or a matrix. Except if the last part of name
+// indicates a uniform variable array, the location of the first element of
+// an array can be retrieved by using the name of the array, or by using the
+// name appended by "[0]".
+//
+// The actual locations assigned to uniform variables are not known until the
+// program object is linked successfully. After linking has occurred, the
+// command GetUniformLocation can be used to obtain the location of a
+// uniform variable. This location value can then be passed to Uniform to
+// set the value of the uniform variable or to GetUniform in order to query
+// the current value of the uniform variable. After a program object has been
+// linked successfully, the index values for uniform variables remain fixed
+// until the next link command occurs. Uniform variable locations and values
+// can only be queried after a link if the link was successful.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program object.
+// GL.INVALID_OPERATION is generated if program has not been successfully
+// linked. GL.INVALID_OPERATION is generated if GetUniformLocation is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// GetUniformLocation is available in GL version 2.0 or greater.
+func (gl *GL) GetUniformLocation(program glbase.Program, name string) glbase.Uniform {
+ name_cstr := C.CString(name)
+ glresult := C.gl3_2core_glGetUniformLocation(gl.funcs, C.GLuint(program), (*C.GLchar)(name_cstr))
+ C.free(unsafe.Pointer(name_cstr))
+ return glbase.Uniform(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetShaderSource.xml
+func (gl *GL) GetShaderSource(shader glbase.Shader, bufSize int32, length []int32, source []byte) {
+ C.gl3_2core_glGetShaderSource(gl.funcs, C.GLuint(shader), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&source[0])))
+}
+
+// GetShaderInfoLog returns the information log for the specified shader
+// object. The information log for a shader object is modified when the
+// shader is compiled.
+//
+// The information log for a shader object is a string that may contain
+// diagnostic messages, warning messages, and other information about the
+// last compile operation. When a shader object is created, its information
+// log will be a string of length 0, and the size of the current log can be
+// obtained by calling GetShaderiv with the value GL.INFO_LOG_LENGTH.
+//
+// The information log for a shader object is the OpenGL implementer's
+// primary mechanism for conveying information about the compilation process.
+// Therefore, the information log can be helpful to application developers
+// during the development process, even when compilation is successful.
+// Application developers should not expect different OpenGL implementations
+// to produce identical information logs.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader is not a shader
+// object. GL.INVALID_VALUE is generated if maxLength is less than 0.
+// GL.INVALID_OPERATION is generated if GetShaderInfoLog is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// GetShaderInfoLog is available in GL version 2.0 or greater.
+func (gl *GL) GetShaderInfoLog(shader glbase.Shader) []byte {
+ var params [1]int32
+ var length int32
+ gl.GetShaderiv(shader, INFO_LOG_LENGTH, params[:])
+ bufSize := params[0]
+ infoLog := make([]byte, int(bufSize))
+ C.gl3_2core_glGetShaderInfoLog(gl.funcs, C.GLuint(shader), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length)), (*C.GLchar)(unsafe.Pointer(&infoLog[0])))
+ return infoLog
+}
+
+// GetShaderiv GetShader returns in params the value of a parameter for a specific
+// shader object. The following parameters are defined:
+//
+// GL.SHADER_TYPE
+// params returns GL.VERTEX_SHADER if shader is a vertex shader object,
+// and GL.FRAGMENT_SHADER if shader is a fragment shader object.
+//
+// GL.DELETE_STATUS
+// params returns GL.TRUE if shader is currently flagged for deletion,
+// and GL.FALSE otherwise.
+//
+// GL.COMPILE_STATUS
+// params returns GL.TRUE if the last compile operation on shader was
+// successful, and GL.FALSE otherwise.
+//
+// GL.INFO_LOG_LENGTH
+// params returns the number of characters in the information log for
+// shader including the null termination character (the size of the
+// character buffer required to store the information log). If shader has
+// no information log, a value of 0 is returned.
+//
+// GL.SHADER_SOURCE_LENGTH
+// params returns the length of the concatenation of the source strings
+// that make up the shader source for the shader, including the null
+// termination character. (the size of the character buffer
+// required to store the shader source). If no source code exists, 0 is
+// returned.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader does not refer to a
+// shader object. GL.INVALID_ENUM is generated if pname is not an accepted
+// value. GL.INVALID_OPERATION is generated if GetShader is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// GetShaderiv is available in GL version 2.0 or greater.
+func (gl *GL) GetShaderiv(shader glbase.Shader, pname glbase.Enum, params []int32) {
+ var params_c [4]int32
+ C.gl3_2core_glGetShaderiv(gl.funcs, C.GLuint(shader), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetProgramInfoLog returns the information log for the specified program
+// object. The information log for a program object is modified when the
+// program object is linked or validated.
+//
+// The information log for a program object is either an empty string, or a
+// string containing information about the last link operation, or a string
+// containing information about the last validation operation. It may contain
+// diagnostic messages, warning messages, and other information. When a
+// program object is created, its information log will be a string of length
+// 0, and the size of the current log can be obtained by calling GetProgramiv
+// with the value GL.INFO_LOG_LENGTH.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated
+// by OpenGL. GL.INVALID_OPERATION is generated if program is not a
+// program object.
+func (gl *GL) GetProgramInfoLog(program glbase.Program) []byte {
+ var params [1]int32
+ var length int32
+ gl.GetProgramiv(program, INFO_LOG_LENGTH, params[:])
+ bufSize := params[0]
+ infoLog := make([]byte, int(bufSize))
+ C.gl3_2core_glGetProgramInfoLog(gl.funcs, C.GLuint(program), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length)), (*C.GLchar)(unsafe.Pointer(&infoLog[0])))
+ return infoLog
+}
+
+// GetProgramiv returns in params the value of a parameter for a specific
+// program object. The following parameters are defined:
+//
+// GL.DELETE_STATUS
+// params returns GL.TRUE if program is currently flagged for deletion,
+// and GL.FALSE otherwise.
+//
+// GL.LINK_STATUS
+// params returns GL.TRUE if the last link operation on program was
+// successful, and GL.FALSE otherwise.
+//
+// GL.VALIDATE_STATUS
+// params returns GL.TRUE or if the last validation operation on
+// program was successful, and GL.FALSE otherwise.
+//
+// GL.INFO_LOG_LENGTH
+// params returns the number of characters in the information log for
+// program including the null termination character (the size of
+// the character buffer required to store the information log). If
+// program has no information log, a value of 0 is returned.
+//
+// GL.ATTACHED_SHADERS
+// params returns the number of shader objects attached to program.
+//
+// GL.ACTIVE_ATTRIBUTES
+// params returns the number of active attribute variables for program.
+//
+// GL.ACTIVE_ATTRIBUTE_MAX_LENGTH
+// params returns the length of the longest active attribute name for
+// program, including the null termination character (the size of
+// the character buffer required to store the longest attribute name).
+// If no active attributes exist, 0 is returned.
+//
+// GL.ACTIVE_UNIFORMS
+// params returns the number of active uniform variables for program.
+//
+// GL.ACTIVE_UNIFORM_MAX_LENGTH
+// params returns the length of the longest active uniform variable
+// name for program, including the null termination character (i.e.,
+// the size of the character buffer required to store the longest
+// uniform variable name). If no active uniform variables exist, 0 is
+// returned.
+//
+// GL.TRANSFORM_FEEDBACK_BUFFER_MODE
+// params returns a symbolic constant indicating the buffer mode used
+// when transform feedback is active. This may be GL.SEPARATE_ATTRIBS
+// or GL.INTERLEAVED_ATTRIBS.
+//
+// GL.TRANSFORM_FEEDBACK_VARYINGS
+// params returns the number of varying variables to capture in transform
+// feedback mode for the program.
+//
+// GL.TRANSFORM_FEEDBACK_VARYING_MAX_LENGTH
+// params returns the length of the longest variable name to be used for
+// transform feedback, including the null-terminator.
+//
+// GL.GEOMETRY_VERTICES_OUT
+// params returns the maximum number of vertices that the geometry shader in
+// program will output.
+//
+// GL.GEOMETRY_INPUT_TYPE
+// params returns a symbolic constant indicating the primitive type accepted
+// as input to the geometry shader contained in program.
+//
+// GL.GEOMETRY_OUTPUT_TYPE
+// params returns a symbolic constant indicating the primitive type that will
+// be output by the geometry shader contained in program.
+//
+// GL.ACTIVE_UNIFORM_BLOCKS and GL.ACTIVE_UNIFORM_BLOCK_MAX_NAME_LENGTH are
+// available only if the GL version 3.1 or greater.
+//
+// GL.GEOMETRY_VERTICES_OUT, GL.GEOMETRY_INPUT_TYPE and
+// GL.GEOMETRY_OUTPUT_TYPE are accepted only if the GL version is 3.2 or
+// greater.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program does not refer to a
+// program object. GL.INVALID_OPERATION is generated if pname is
+// GL.GEOMETRY_VERTICES_OUT, GL.GEOMETRY_INPUT_TYPE, or
+// GL.GEOMETRY_OUTPUT_TYPE, and program does not contain a geometry shader.
+// GL.INVALID_ENUM is generated if pname is not an accepted value.
+func (gl *GL) GetProgramiv(program glbase.Program, pname glbase.Enum, params []int32) {
+ var params_c [4]int32
+ C.gl3_2core_glGetProgramiv(gl.funcs, C.GLuint(program), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetAttribLocation queries the previously linked program object specified
+// by program for the attribute variable specified by name and returns the
+// index of the generic vertex attribute that is bound to that attribute
+// variable. If name is a matrix attribute variable, the index of the first
+// column of the matrix is returned. If the named attribute variable is not
+// an active attribute in the specified program object or if name starts with
+// the reserved prefix "gl_", a value of -1 is returned.
+//
+// The association between an attribute variable name and a generic attribute
+// index can be specified at any time by calling BindAttribLocation.
+// Attribute bindings do not go into effect until LinkProgram is called.
+// After a program object has been linked successfully, the index values for
+// attribute variables remain fixed until the next link command occurs. The
+// attribute values can only be queried after a link if the link was
+// successful. GetAttribLocation returns the binding that actually went
+// into effect the last time LinkProgram was called for the specified
+// program object. Attribute bindings that have been specified since the last
+// link operation are not returned by GetAttribLocation.
+//
+// Error GL_INVALID_OPERATION is generated if program is not a value
+// generated by OpenGL. GL_INVALID_OPERATION is generated if program is not
+// a program object. GL_INVALID_OPERATION is generated if program has not
+// been successfully linked. GL_INVALID_OPERATION is generated if
+// GetAttribLocation is executed between the execution of Begin and the
+// corresponding execution of End.
+//
+// GetAttribLocation is available in GL version 2.0 or greater.
+func (gl *GL) GetAttribLocation(program glbase.Program, name string) glbase.Attrib {
+ name_cstr := C.CString(name)
+ glresult := C.gl3_2core_glGetAttribLocation(gl.funcs, C.GLuint(program), (*C.GLchar)(name_cstr))
+ C.free(unsafe.Pointer(name_cstr))
+ return glbase.Attrib(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetAttachedShaders.xml
+func (gl *GL) GetAttachedShaders(program glbase.Program, maxCount int32, count []int, obj []uint32) {
+ C.gl3_2core_glGetAttachedShaders(gl.funcs, C.GLuint(program), C.GLsizei(maxCount), (*C.GLsizei)(unsafe.Pointer(&count[0])), (*C.GLuint)(unsafe.Pointer(&obj[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetActiveUniform.xml
+func (gl *GL) GetActiveUniform(program glbase.Program, index uint32, bufSize int32, length []int32, size []int, gltype []glbase.Enum, name []byte) {
+ C.gl3_2core_glGetActiveUniform(gl.funcs, C.GLuint(program), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLint)(unsafe.Pointer(&size[0])), (*C.GLenum)(unsafe.Pointer(&gltype[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetActiveAttrib.xml
+func (gl *GL) GetActiveAttrib(program glbase.Program, index glbase.Attrib, bufSize int32, length []int32, size []int, gltype []glbase.Enum, name []byte) {
+ C.gl3_2core_glGetActiveAttrib(gl.funcs, C.GLuint(program), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLint)(unsafe.Pointer(&size[0])), (*C.GLenum)(unsafe.Pointer(&gltype[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEnableVertexAttribArray.xml
+func (gl *GL) EnableVertexAttribArray(index glbase.Attrib) {
+ C.gl3_2core_glEnableVertexAttribArray(gl.funcs, C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDisableVertexAttribArray.xml
+func (gl *GL) DisableVertexAttribArray(index glbase.Attrib) {
+ C.gl3_2core_glDisableVertexAttribArray(gl.funcs, C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDetachShader.xml
+func (gl *GL) DetachShader(program glbase.Program, shader glbase.Shader) {
+ C.gl3_2core_glDetachShader(gl.funcs, C.GLuint(program), C.GLuint(shader))
+}
+
+// DeleteShader frees the memory and invalidates the name associated with
+// the shader object specified by shader. This command effectively undoes the
+// effects of a call to CreateShader.
+//
+// If a shader object to be deleted is attached to a program object, it will
+// be flagged for deletion, but it will not be deleted until it is no longer
+// attached to any program object, for any rendering context (it must
+// be detached from wherever it was attached before it will be deleted). A
+// value of 0 for shader will be silently ignored.
+//
+// To determine whether an object has been flagged for deletion, call
+// GetShader with arguments shader and GL.DELETE_STATUS.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL.
+//
+// DeleteShader is available in GL version 2.0 or greater.
+func (gl *GL) DeleteShader(shader glbase.Shader) {
+ C.gl3_2core_glDeleteShader(gl.funcs, C.GLuint(shader))
+}
+
+// DeleteProgram frees the memory and invalidates the name associated with
+// the program object specified by program. This command effectively undoes
+// the effects of a call to CreateProgram.
+//
+// If a program object is in use as part of current rendering state, it will
+// be flagged for deletion, but it will not be deleted until it is no longer
+// part of current state for any rendering context. If a program object to be
+// deleted has shader objects attached to it, those shader objects will be
+// automatically detached but not deleted unless they have already been
+// flagged for deletion by a previous call to DeleteShader. A value of 0
+// for program will be silently ignored.
+//
+// To determine whether a program object has been flagged for deletion, call
+// GetProgram with arguments program and GL.DELETE_STATUS.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL.
+//
+// DeleteProgram is available in GL version 2.0 or greater.
+func (gl *GL) DeleteProgram(program glbase.Program) {
+ C.gl3_2core_glDeleteProgram(gl.funcs, C.GLuint(program))
+}
+
+// CreateShader creates an empty shader object and returns a non-zero value
+// by which it can be referenced. A shader object is used to maintain the
+// source code strings that define a shader. shaderType indicates the type of
+// shader to be created.
+//
+// Two types of shaders are supported. A shader of type GL.VERTEX_SHADER is a
+// shader that is intended to run on the programmable vertex processor and
+// replace the fixed functionality vertex processing in OpenGL. A shader of
+// type GL.FRAGMENT_SHADER is a shader that is intended to run on the
+// programmable fragment processor and replace the fixed functionality
+// fragment processing in OpenGL.
+//
+// When created, a shader object's GL.SHADER_TYPE parameter is set to either
+// GL.VERTEX_SHADER or GL.FRAGMENT_SHADER, depending on the value of
+// shaderType.
+//
+// Like display lists and texture objects, the name space for shader objects
+// may be shared across a set of contexts, as long as the server sides of the
+// contexts share the same address space. If the name space is shared across
+// contexts, any attached objects and the data associated with those attached
+// objects are shared as well.
+//
+// This function returns 0 if an error occurs creating the shader object.
+//
+// Error GL.INVALID_ENUM is generated if shaderType is not an accepted value.
+// GL.INVALID_OPERATION is generated if CreateShader is executed between the
+// execution of Begin and the corresponding execution of End.
+//
+// CreateShader is available in GL version 2.0 or greater.
+func (gl *GL) CreateShader(gltype glbase.Enum) glbase.Shader {
+ glresult := C.gl3_2core_glCreateShader(gl.funcs, C.GLenum(gltype))
+ return glbase.Shader(glresult)
+}
+
+// CreateProgram creates an empty program object and returns a non-zero
+// value by which it can be referenced. A program object is an object to
+// which shader objects can be attached. This provides a mechanism to specify
+// the shader objects that will be linked to create a program. It also
+// provides a means for checking the compatibility of the shaders that will
+// be used to create a program (for instance, checking the compatibility
+// between a vertex shader and a fragment shader). When no longer needed as
+// part of a program object, shader objects can be detached.
+//
+// One or more executables are created in a program object by successfully
+// attaching shader objects to it with AttachShader, successfully compiling
+// the shader objects with CompileShader, and successfully linking the
+// program object with LinkProgram. These executables are made part of
+// current state when UseProgram is called. Program objects can be deleted
+// by calling DeleteProgram. The memory associated with the program object
+// will be deleted when it is no longer part of current rendering state for
+// any context.
+//
+// Like display lists and texture objects, the name space for program objects
+// may be shared across a set of contexts, as long as the server sides of the
+// contexts share the same address space. If the name space is shared across
+// contexts, any attached objects and the data associated with those attached
+// objects are shared as well.
+//
+// Applications are responsible for providing the synchronization across API
+// calls when objects are accessed from different execution threads.
+//
+// This function returns 0 if an error occurs creating the program object.
+//
+// Error GL.INVALID_OPERATION is generated if CreateProgram is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// CreateProgram is available in GL version 2.0 or greater.
+func (gl *GL) CreateProgram() glbase.Program {
+ glresult := C.gl3_2core_glCreateProgram(gl.funcs)
+ return glbase.Program(glresult)
+}
+
+// CompileShader compiles the source code strings that have been stored in
+// the shader object specified by shader.
+//
+// The compilation status will be stored as part of the shader object's
+// state. This value will be set to GL.TRUE if the shader was compiled without
+// errors and is ready for use, and GL.FALSE otherwise. It can be queried by
+// calling GetShaderiv with arguments shader and GL.COMPILE_STATUS.
+//
+// Compilation of a shader can fail for a number of reasons as specified by
+// the OpenGL Shading Language Specification. Whether or not the compilation
+// was successful, information about the compilation can be obtained from the
+// shader object's information log by calling GetShaderInfoLog.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader is not a shader
+// object. GL.INVALID_OPERATION is generated if CompileShader is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// CompileShader is available in GL version 2.0 or greater.
+func (gl *GL) CompileShader(shader glbase.Shader) {
+ C.gl3_2core_glCompileShader(gl.funcs, C.GLuint(shader))
+}
+
+// BindAttribLocation associates a user-defined attribute variable in the program
+// object specified by program with a generic vertex attribute index. The name
+// parameter specifies the name of the vertex shader attribute variable to
+// which index is to be bound. When program is made part of the current state,
+// values provided via the generic vertex attribute index will modify the
+// value of the user-defined attribute variable specified by name.
+//
+// If name refers to a matrix attribute variable, index refers to the first
+// column of the matrix. Other matrix columns are then automatically bound to
+// locations index+1 for a matrix of type mat2; index+1 and index+2 for a
+// matrix of type mat3; and index+1, index+2, and index+3 for a matrix of
+// type mat4.
+//
+// This command makes it possible for vertex shaders to use descriptive names
+// for attribute variables rather than generic variables that are numbered
+// from 0 to GL.MAX_VERTEX_ATTRIBS-1. The values sent to each generic
+// attribute index are part of current state, just like standard vertex
+// attributes such as color, normal, and vertex position. If a different
+// program object is made current by calling UseProgram, the generic vertex
+// attributes are tracked in such a way that the same values will be observed
+// by attributes in the new program object that are also bound to index.
+//
+// Attribute variable name-to-generic attribute index bindings for a program
+// object can be explicitly assigned at any time by calling
+// BindAttribLocation. Attribute bindings do not go into effect until
+// LinkProgram is called. After a program object has been linked
+// successfully, the index values for generic attributes remain fixed (and
+// their values can be queried) until the next link command occurs.
+//
+// Applications are not allowed to bind any of the standard OpenGL vertex
+// attributes using this command, as they are bound automatically when
+// needed. Any attribute binding that occurs after the program object has
+// been linked will not take effect until the next time the program object is
+// linked.
+//
+// If name was bound previously, that information is lost. Thus you cannot
+// bind one user-defined attribute variable to multiple indices, but you can
+// bind multiple user-defined attribute variables to the same index.
+//
+// Applications are allowed to bind more than one user-defined attribute
+// variable to the same generic vertex attribute index. This is called
+// aliasing, and it is allowed only if just one of the aliased attributes is
+// active in the executable program, or if no path through the shader
+// consumes more than one attribute of a set of attributes aliased to the
+// same location. The compiler and linker are allowed to assume that no
+// aliasing is done and are free to employ optimizations that work only in
+// the absence of aliasing. OpenGL implementations are not required to do
+// error checking to detect aliasing. Because there is no way to bind
+// standard attributes, it is not possible to alias generic attributes with
+// conventional ones (except for generic attribute 0).
+//
+// BindAttribLocation can be called before any vertex shader objects are
+// bound to the specified program object. It is also permissible to bind a
+// generic attribute index to an attribute variable name that is never used
+// in a vertex shader.
+//
+// Active attributes that are not explicitly bound will be bound by the
+// linker when LinkProgram is called. The locations assigned can be queried
+// by calling GetAttribLocation.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS.
+// GL.INVALID_OPERATION is generated if name starts with the reserved prefix "gl_".
+// GL.INVALID_VALUE is generated if program is not a value generated by OpenGL.
+// GL.INVALID_OPERATION is generated if program is not a program object.
+// GL.INVALID_OPERATION is generated if BindAttribLocation is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// BindAttribLocation is available in GL version 2.0 or greater.
+func (gl *GL) BindAttribLocation(program glbase.Program, index glbase.Attrib, name string) {
+ name_cstr := C.CString(name)
+ C.gl3_2core_glBindAttribLocation(gl.funcs, C.GLuint(program), C.GLuint(index), (*C.GLchar)(name_cstr))
+ C.free(unsafe.Pointer(name_cstr))
+}
+
+// AttachShader attaches a shader object to a program object.
+//
+// In order to create an executable, there must be a way to specify the list
+// of things that will be linked together. Program objects provide this
+// mechanism. Shaders that are to be linked together in a program object must
+// first be attached to that program object. This indicates that shader will
+// be included in link operations that will be performed on program.
+//
+// All operations that can be performed on a shader object are valid whether
+// or not the shader object is attached to a program object. It is
+// permissible to attach a shader object to a program object before source
+// code has been loaded into the shader object or before the shader object
+// has been compiled. It is permissible to attach multiple shader objects of
+// the same type because each may contain a portion of the complete shader.
+// It is also permissible to attach a shader object to more than one program
+// object. If a shader object is deleted while it is attached to a program
+// object, it will be flagged for deletion, and deletion will not occur until
+// DetachShader is called to detach it from all program objects to which it
+// is attached.
+//
+// Error GL.INVALID_VALUE is generated if either program or shader is not a
+// value generated by OpenGL. GL.INVALID_OPERATION is generated if program
+// is not a program object. GL.INVALID_OPERATION is generated if shader is
+// not a shader object. GL.INVALID_OPERATION is generated if shader is
+// already attached to program. GL.INVALID_OPERATION is generated if
+// AttachShader is executed between the execution of Begin and the
+// corresponding execution of End.
+//
+// AttachShader is available in GL version 2.0 or greater.
+func (gl *GL) AttachShader(program glbase.Program, shader glbase.Shader) {
+ C.gl3_2core_glAttachShader(gl.funcs, C.GLuint(program), C.GLuint(shader))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glStencilMaskSeparate.xml
+func (gl *GL) StencilMaskSeparate(face glbase.Enum, mask uint32) {
+ C.gl3_2core_glStencilMaskSeparate(gl.funcs, C.GLenum(face), C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glStencilFuncSeparate.xml
+func (gl *GL) StencilFuncSeparate(face, glfunc glbase.Enum, ref int32, mask uint32) {
+ C.gl3_2core_glStencilFuncSeparate(gl.funcs, C.GLenum(face), C.GLenum(glfunc), C.GLint(ref), C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glStencilOpSeparate.xml
+func (gl *GL) StencilOpSeparate(face, sfail, dpfail, dppass glbase.Enum) {
+ C.gl3_2core_glStencilOpSeparate(gl.funcs, C.GLenum(face), C.GLenum(sfail), C.GLenum(dpfail), C.GLenum(dppass))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDrawBuffers.xml
+func (gl *GL) DrawBuffers(n int, bufs []glbase.Enum) {
+ C.gl3_2core_glDrawBuffers(gl.funcs, C.GLsizei(n), (*C.GLenum)(unsafe.Pointer(&bufs[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBlendEquationSeparate.xml
+func (gl *GL) BlendEquationSeparate(modeRGB, modeAlpha glbase.Enum) {
+ C.gl3_2core_glBlendEquationSeparate(gl.funcs, C.GLenum(modeRGB), C.GLenum(modeAlpha))
+}
+
+// UniformMatrix4x3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix4x3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix4x3fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(4*3) != 0 {
+ panic("invalid value length for UniformMatrix4x3fv")
+ }
+ count := len(value) / (4 * 3)
+ C.gl3_2core_glUniformMatrix4x3fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix3x4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix3x4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix3x4fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(3*4) != 0 {
+ panic("invalid value length for UniformMatrix3x4fv")
+ }
+ count := len(value) / (3 * 4)
+ C.gl3_2core_glUniformMatrix3x4fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix4x2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix4x2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix4x2fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(4*2) != 0 {
+ panic("invalid value length for UniformMatrix4x2fv")
+ }
+ count := len(value) / (4 * 2)
+ C.gl3_2core_glUniformMatrix4x2fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix2x4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix2x4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix2x4fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(2*4) != 0 {
+ panic("invalid value length for UniformMatrix2x4fv")
+ }
+ count := len(value) / (2 * 4)
+ C.gl3_2core_glUniformMatrix2x4fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix3x2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix3x2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix3x2fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(3*2) != 0 {
+ panic("invalid value length for UniformMatrix3x2fv")
+ }
+ count := len(value) / (3 * 2)
+ C.gl3_2core_glUniformMatrix3x2fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix2x3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix2x3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix2x3fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(2*3) != 0 {
+ panic("invalid value length for UniformMatrix2x3fv")
+ }
+ count := len(value) / (2 * 3)
+ C.gl3_2core_glUniformMatrix2x3fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsVertexArray.xml
+func (gl *GL) IsVertexArray(array uint32) bool {
+ glresult := C.gl3_2core_glIsVertexArray(gl.funcs, C.GLuint(array))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGenVertexArrays.xml
+func (gl *GL) GenVertexArrays(n int, arrays []uint32) {
+ C.gl3_2core_glGenVertexArrays(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&arrays[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDeleteVertexArrays.xml
+func (gl *GL) DeleteVertexArrays(n int, arrays []uint32) {
+ C.gl3_2core_glDeleteVertexArrays(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&arrays[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBindVertexArray.xml
+func (gl *GL) BindVertexArray(array uint32) {
+ C.gl3_2core_glBindVertexArray(gl.funcs, C.GLuint(array))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFlushMappedBufferRange.xml
+func (gl *GL) FlushMappedBufferRange(target glbase.Enum, offset, length int) {
+ C.gl3_2core_glFlushMappedBufferRange(gl.funcs, C.GLenum(target), C.GLintptr(offset), C.GLsizeiptr(length))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFramebufferTextureLayer.xml
+func (gl *GL) FramebufferTextureLayer(target, attachment glbase.Enum, texture glbase.Texture, level int, layer int32) {
+ C.gl3_2core_glFramebufferTextureLayer(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLuint(texture), C.GLint(level), C.GLint(layer))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRenderbufferStorageMultisample.xml
+func (gl *GL) RenderbufferStorageMultisample(target glbase.Enum, samples int32, internalFormat glbase.Enum, width, height int) {
+ C.gl3_2core_glRenderbufferStorageMultisample(gl.funcs, C.GLenum(target), C.GLsizei(samples), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBlitFramebuffer.xml
+func (gl *GL) BlitFramebuffer(srcX0, srcY0, srcX1, srcY1, dstX0, dstY0, dstX1, dstY1 int32, mask glbase.Bitfield, filter glbase.Enum) {
+ C.gl3_2core_glBlitFramebuffer(gl.funcs, C.GLint(srcX0), C.GLint(srcY0), C.GLint(srcX1), C.GLint(srcY1), C.GLint(dstX0), C.GLint(dstY0), C.GLint(dstX1), C.GLint(dstY1), C.GLbitfield(mask), C.GLenum(filter))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGenerateMipmap.xml
+func (gl *GL) GenerateMipmap(target glbase.Enum) {
+ C.gl3_2core_glGenerateMipmap(gl.funcs, C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetFramebufferAttachmentParameteriv.xml
+func (gl *GL) GetFramebufferAttachmentParameteriv(target, attachment, pname glbase.Enum, params []int32) {
+ C.gl3_2core_glGetFramebufferAttachmentParameteriv(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFramebufferRenderbuffer.xml
+func (gl *GL) FramebufferRenderbuffer(target, attachment, renderbuffertarget glbase.Enum, renderbuffer glbase.Renderbuffer) {
+ C.gl3_2core_glFramebufferRenderbuffer(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(renderbuffertarget), C.GLuint(renderbuffer))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFramebufferTexture3D.xml
+func (gl *GL) FramebufferTexture3D(target, attachment, textarget glbase.Enum, texture glbase.Texture, level int, zoffset int32) {
+ C.gl3_2core_glFramebufferTexture3D(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(textarget), C.GLuint(texture), C.GLint(level), C.GLint(zoffset))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFramebufferTexture2D.xml
+func (gl *GL) FramebufferTexture2D(target, attachment, textarget glbase.Enum, texture glbase.Texture, level int) {
+ C.gl3_2core_glFramebufferTexture2D(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(textarget), C.GLuint(texture), C.GLint(level))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFramebufferTexture1D.xml
+func (gl *GL) FramebufferTexture1D(target, attachment, textarget glbase.Enum, texture glbase.Texture, level int) {
+ C.gl3_2core_glFramebufferTexture1D(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(textarget), C.GLuint(texture), C.GLint(level))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCheckFramebufferStatus.xml
+func (gl *GL) CheckFramebufferStatus(target glbase.Enum) glbase.Enum {
+ glresult := C.gl3_2core_glCheckFramebufferStatus(gl.funcs, C.GLenum(target))
+ return glbase.Enum(glresult)
+}
+
+// GenFramebuffers returns n framebuffer object names in ids. There is no
+// guarantee that the names form a contiguous set of integers; however, it is
+// guaranteed that none of the returned names was in use immediately before
+// the call to GenFramebuffers.
+//
+// Framebuffer object names returned by a call to GenFramebuffers are not
+// returned by subsequent calls, unless they are first deleted with
+// DeleteFramebuffers.
+//
+// The names returned in ids are marked as used, for the purposes of
+// GenFramebuffers only, but they acquire state and type only when they are
+// first bound.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+func (gl *GL) GenFramebuffers(n int) []glbase.Framebuffer {
+ if n == 0 {
+ return nil
+ }
+ framebuffers := make([]glbase.Framebuffer, n)
+ C.gl3_2core_glGenFramebuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&framebuffers[0])))
+ return framebuffers
+}
+
+// DeleteFramebuffers deletes the framebuffer objects whose names are
+// stored in the framebuffers slice. The name zero is reserved by the GL and
+// is silently ignored, should it occur in framebuffers, as are other unused
+// names. Once a framebuffer object is deleted, its name is again unused and
+// it has no attachments. If a framebuffer that is currently bound to one or
+// more of the targets GL.DRAW_FRAMEBUFFER or GL.READ_FRAMEBUFFER is deleted,
+// it is as though BindFramebuffer had been executed with the corresponding
+// target and framebuffer zero.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// DeleteFramebuffers is available in GL version 3.0 or greater.
+func (gl *GL) DeleteFramebuffers(framebuffers []glbase.Framebuffer) {
+ n := len(framebuffers)
+ if n == 0 {
+ return
+ }
+ C.gl3_2core_glDeleteFramebuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&framebuffers[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBindFramebuffer.xml
+func (gl *GL) BindFramebuffer(target glbase.Enum, framebuffer glbase.Framebuffer) {
+ C.gl3_2core_glBindFramebuffer(gl.funcs, C.GLenum(target), C.GLuint(framebuffer))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsFramebuffer.xml
+func (gl *GL) IsFramebuffer(framebuffer glbase.Framebuffer) bool {
+ glresult := C.gl3_2core_glIsFramebuffer(gl.funcs, C.GLuint(framebuffer))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetRenderbufferParameteriv.xml
+func (gl *GL) GetRenderbufferParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl3_2core_glGetRenderbufferParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRenderbufferStorage.xml
+func (gl *GL) RenderbufferStorage(target, internalFormat glbase.Enum, width, height int) {
+ C.gl3_2core_glRenderbufferStorage(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height))
+}
+
+// GenRenderbuffers returns n renderbuffer object names in renderbuffers.
+// There is no guarantee that the names form a contiguous set of integers;
+// however, it is guaranteed that none of the returned names was in use
+// immediately before the call to GenRenderbuffers.
+//
+// Renderbuffer object names returned by a call to GenRenderbuffers are not
+// returned by subsequent calls, unless they are first deleted with
+// DeleteRenderbuffers.
+//
+// The names returned in renderbuffers are marked as used, for the purposes
+// of GenRenderbuffers only, but they acquire state and type only when they
+// are first bound.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// GenRenderbuffers is available in GL version 3.0 or greater.
+func (gl *GL) GenRenderbuffers(n int) []glbase.Renderbuffer {
+ if n == 0 {
+ return nil
+ }
+ renderbuffers := make([]glbase.Renderbuffer, n)
+ C.gl3_2core_glGenRenderbuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&renderbuffers[0])))
+ return renderbuffers
+}
+
+// DeleteRenderbuffers deletes the renderbuffer objects whose names are stored
+// in the renderbuffers slice. The name zero is reserved by the GL and
+// is silently ignored, should it occur in renderbuffers, as are other unused
+// names. Once a renderbuffer object is deleted, its name is again unused and
+// it has no contents. If a renderbuffer that is currently bound to the
+// target GL.RENDERBUFFER is deleted, it is as though BindRenderbuffer had
+// been executed with a target of GL.RENDERBUFFER and a name of zero.
+//
+// If a renderbuffer object is attached to one or more attachment points in
+// the currently bound framebuffer, then it as if FramebufferRenderbuffer
+// had been called, with a renderbuffer of zero for each attachment point to
+// which this image was attached in the currently bound framebuffer. In other
+// words, this renderbuffer object is first detached from all attachment
+// ponits in the currently bound framebuffer. Note that the renderbuffer
+// image is specifically not detached from any non-bound framebuffers.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// DeleteRenderbuffers is available in GL version 3.0 or greater.
+func (gl *GL) DeleteRenderbuffers(renderbuffers []glbase.Renderbuffer) {
+ n := len(renderbuffers)
+ if n == 0 {
+ return
+ }
+ C.gl3_2core_glDeleteRenderbuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&renderbuffers[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBindRenderbuffer.xml
+func (gl *GL) BindRenderbuffer(target glbase.Enum, renderbuffer glbase.Renderbuffer) {
+ C.gl3_2core_glBindRenderbuffer(gl.funcs, C.GLenum(target), C.GLuint(renderbuffer))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsRenderbuffer.xml
+func (gl *GL) IsRenderbuffer(renderbuffer glbase.Renderbuffer) bool {
+ glresult := C.gl3_2core_glIsRenderbuffer(gl.funcs, C.GLuint(renderbuffer))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClearBufferfi.xml
+func (gl *GL) ClearBufferfi(buffer glbase.Enum, drawbuffer int32, depth float32, stencil int32) {
+ C.gl3_2core_glClearBufferfi(gl.funcs, C.GLenum(buffer), C.GLint(drawbuffer), C.GLfloat(depth), C.GLint(stencil))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClearBufferfv.xml
+func (gl *GL) ClearBufferfv(buffer glbase.Enum, drawbuffer int32, value []float32) {
+ C.gl3_2core_glClearBufferfv(gl.funcs, C.GLenum(buffer), C.GLint(drawbuffer), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClearBufferuiv.xml
+func (gl *GL) ClearBufferuiv(buffer glbase.Enum, drawbuffer int32, value []uint32) {
+ C.gl3_2core_glClearBufferuiv(gl.funcs, C.GLenum(buffer), C.GLint(drawbuffer), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClearBufferiv.xml
+func (gl *GL) ClearBufferiv(buffer glbase.Enum, drawbuffer int32, value []int32) {
+ C.gl3_2core_glClearBufferiv(gl.funcs, C.GLenum(buffer), C.GLint(drawbuffer), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTexParameterIuiv.xml
+func (gl *GL) GetTexParameterIuiv(target, pname glbase.Enum, params []uint32) {
+ C.gl3_2core_glGetTexParameterIuiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTexParameterIiv.xml
+func (gl *GL) GetTexParameterIiv(target, pname glbase.Enum, params []int32) {
+ C.gl3_2core_glGetTexParameterIiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexParameterIuiv.xml
+func (gl *GL) TexParameterIuiv(target, pname glbase.Enum, params []uint32) {
+ C.gl3_2core_glTexParameterIuiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexParameterIiv.xml
+func (gl *GL) TexParameterIiv(target, pname glbase.Enum, params []int32) {
+ C.gl3_2core_glTexParameterIiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// Uniform4uiv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform4uiv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4uiv(location glbase.Uniform, value []uint32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%4 != 0 {
+ panic("invalid value length for Uniform4uiv")
+ }
+ count := len(value) / 4
+ C.gl3_2core_glUniform4uiv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform3uiv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform3uiv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3uiv(location glbase.Uniform, value []uint32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%3 != 0 {
+ panic("invalid value length for Uniform3uiv")
+ }
+ count := len(value) / 3
+ C.gl3_2core_glUniform3uiv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform2uiv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform2uiv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2uiv(location glbase.Uniform, value []uint32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%2 != 0 {
+ panic("invalid value length for Uniform2uiv")
+ }
+ count := len(value) / 2
+ C.gl3_2core_glUniform2uiv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform1uiv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform1uiv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1uiv(location glbase.Uniform, value []uint32) {
+ if len(value) == 0 {
+ return
+ }
+ count := len(value)
+ C.gl3_2core_glUniform1uiv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4ui modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform4ui operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4ui(location glbase.Uniform, v0, v1, v2, v3 uint32) {
+ C.gl3_2core_glUniform4ui(gl.funcs, C.GLint(location), C.GLuint(v0), C.GLuint(v1), C.GLuint(v2), C.GLuint(v3))
+}
+
+// Uniform3ui modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform3ui operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3ui(location glbase.Uniform, v0, v1, v2 uint32) {
+ C.gl3_2core_glUniform3ui(gl.funcs, C.GLint(location), C.GLuint(v0), C.GLuint(v1), C.GLuint(v2))
+}
+
+// Uniform2ui modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform2ui operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2ui(location glbase.Uniform, v0, v1 uint32) {
+ C.gl3_2core_glUniform2ui(gl.funcs, C.GLint(location), C.GLuint(v0), C.GLuint(v1))
+}
+
+// Uniform1ui modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform1ui operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1ui(location glbase.Uniform, v0 uint32) {
+ C.gl3_2core_glUniform1ui(gl.funcs, C.GLint(location), C.GLuint(v0))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetFragDataLocation.xml
+func (gl *GL) GetFragDataLocation(program glbase.Program, name []byte) int32 {
+ glresult := C.gl3_2core_glGetFragDataLocation(gl.funcs, C.GLuint(program), (*C.GLchar)(unsafe.Pointer(&name[0])))
+ return int32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBindFragDataLocation.xml
+func (gl *GL) BindFragDataLocation(program glbase.Program, color uint32, name []byte) {
+ C.gl3_2core_glBindFragDataLocation(gl.funcs, C.GLuint(program), C.GLuint(color), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetUniformuiv.xml
+func (gl *GL) GetUniformuiv(program glbase.Program, location glbase.Uniform, params []uint32) {
+ C.gl3_2core_glGetUniformuiv(gl.funcs, C.GLuint(program), C.GLint(location), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetVertexAttribIuiv.xml
+func (gl *GL) GetVertexAttribIuiv(index glbase.Attrib, pname glbase.Enum, params []uint32) {
+ C.gl3_2core_glGetVertexAttribIuiv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetVertexAttribIiv.xml
+func (gl *GL) GetVertexAttribIiv(index glbase.Attrib, pname glbase.Enum, params []int32) {
+ C.gl3_2core_glGetVertexAttribIiv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribIPointer.xml
+func (gl *GL) VertexAttribIPointer(index glbase.Attrib, size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2core_glVertexAttribIPointer(gl.funcs, C.GLuint(index), C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEndConditionalRender.xml
+func (gl *GL) EndConditionalRender() {
+ C.gl3_2core_glEndConditionalRender(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBeginConditionalRender.xml
+func (gl *GL) BeginConditionalRender(id uint32, mode glbase.Enum) {
+ C.gl3_2core_glBeginConditionalRender(gl.funcs, C.GLuint(id), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClampColor.xml
+func (gl *GL) ClampColor(target, clamp glbase.Enum) {
+ C.gl3_2core_glClampColor(gl.funcs, C.GLenum(target), C.GLenum(clamp))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTransformFeedbackVarying.xml
+func (gl *GL) GetTransformFeedbackVarying(program glbase.Program, index uint32, bufSize int32, length []int32, size []int, gltype []glbase.Enum, name []byte) {
+ C.gl3_2core_glGetTransformFeedbackVarying(gl.funcs, C.GLuint(program), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLsizei)(unsafe.Pointer(&size[0])), (*C.GLenum)(unsafe.Pointer(&gltype[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBindBufferBase.xml
+func (gl *GL) BindBufferBase(target glbase.Enum, index uint32, buffer glbase.Buffer) {
+ C.gl3_2core_glBindBufferBase(gl.funcs, C.GLenum(target), C.GLuint(index), C.GLuint(buffer))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBindBufferRange.xml
+func (gl *GL) BindBufferRange(target glbase.Enum, index uint32, buffer glbase.Buffer, offset, size int) {
+ C.gl3_2core_glBindBufferRange(gl.funcs, C.GLenum(target), C.GLuint(index), C.GLuint(buffer), C.GLintptr(offset), C.GLsizeiptr(size))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEndTransformFeedback.xml
+func (gl *GL) EndTransformFeedback() {
+ C.gl3_2core_glEndTransformFeedback(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBeginTransformFeedback.xml
+func (gl *GL) BeginTransformFeedback(primitiveMode glbase.Enum) {
+ C.gl3_2core_glBeginTransformFeedback(gl.funcs, C.GLenum(primitiveMode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsEnabledi.xml
+func (gl *GL) IsEnabledi(target glbase.Enum, index uint32) bool {
+ glresult := C.gl3_2core_glIsEnabledi(gl.funcs, C.GLenum(target), C.GLuint(index))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDisablei.xml
+func (gl *GL) Disablei(target glbase.Enum, index uint32) {
+ C.gl3_2core_glDisablei(gl.funcs, C.GLenum(target), C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEnablei.xml
+func (gl *GL) Enablei(target glbase.Enum, index uint32) {
+ C.gl3_2core_glEnablei(gl.funcs, C.GLenum(target), C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetIntegeri_v.xml
+func (gl *GL) GetIntegeri_v(target glbase.Enum, index uint32, data []int32) {
+ C.gl3_2core_glGetIntegeri_v(gl.funcs, C.GLenum(target), C.GLuint(index), (*C.GLint)(unsafe.Pointer(&data[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetBooleani_v.xml
+func (gl *GL) GetBooleani_v(target glbase.Enum, index uint32, data []bool) {
+ C.gl3_2core_glGetBooleani_v(gl.funcs, C.GLenum(target), C.GLuint(index), (*C.GLboolean)(unsafe.Pointer(&data[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColorMaski.xml
+func (gl *GL) ColorMaski(index uint32, r, g, b, a bool) {
+ C.gl3_2core_glColorMaski(gl.funcs, C.GLuint(index), *(*C.GLboolean)(unsafe.Pointer(&r)), *(*C.GLboolean)(unsafe.Pointer(&g)), *(*C.GLboolean)(unsafe.Pointer(&b)), *(*C.GLboolean)(unsafe.Pointer(&a)))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCopyBufferSubData.xml
+func (gl *GL) CopyBufferSubData(readTarget, writeTarget glbase.Enum, readOffset, writeOffset, size int) {
+ C.gl3_2core_glCopyBufferSubData(gl.funcs, C.GLenum(readTarget), C.GLenum(writeTarget), C.GLintptr(readOffset), C.GLintptr(writeOffset), C.GLsizeiptr(size))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glUniformBlockBinding.xml
+func (gl *GL) UniformBlockBinding(program glbase.Program, v0, v1 uint32) {
+ C.gl3_2core_glUniformBlockBinding(gl.funcs, C.GLuint(program), C.GLuint(v0), C.GLuint(v1))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetActiveUniformBlockName.xml
+func (gl *GL) GetActiveUniformBlockName(program glbase.Program, uniformBlockIndex uint32, bufSize int32, length []int32, uniformBlockName []byte) {
+ C.gl3_2core_glGetActiveUniformBlockName(gl.funcs, C.GLuint(program), C.GLuint(uniformBlockIndex), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&uniformBlockName[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetActiveUniformBlockiv.xml
+func (gl *GL) GetActiveUniformBlockiv(program glbase.Program, uniformBlockIndex uint32, pname glbase.Enum, params []int32) {
+ C.gl3_2core_glGetActiveUniformBlockiv(gl.funcs, C.GLuint(program), C.GLuint(uniformBlockIndex), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetUniformBlockIndex.xml
+func (gl *GL) GetUniformBlockIndex(program glbase.Program, uniformBlockName []byte) uint32 {
+ glresult := C.gl3_2core_glGetUniformBlockIndex(gl.funcs, C.GLuint(program), (*C.GLchar)(unsafe.Pointer(&uniformBlockName[0])))
+ return uint32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetActiveUniformName.xml
+func (gl *GL) GetActiveUniformName(program glbase.Program, uniformIndex uint32, bufSize int32, length []int32, uniformName []byte) {
+ C.gl3_2core_glGetActiveUniformName(gl.funcs, C.GLuint(program), C.GLuint(uniformIndex), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&uniformName[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetActiveUniformsiv.xml
+func (gl *GL) GetActiveUniformsiv(program glbase.Program, uniformCount int32, uniformIndices []uint32, pname glbase.Enum, params []int32) {
+ C.gl3_2core_glGetActiveUniformsiv(gl.funcs, C.GLuint(program), C.GLsizei(uniformCount), (*C.GLuint)(unsafe.Pointer(&uniformIndices[0])), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPrimitiveRestartIndex.xml
+func (gl *GL) PrimitiveRestartIndex(index uint32) {
+ C.gl3_2core_glPrimitiveRestartIndex(gl.funcs, C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexBuffer.xml
+func (gl *GL) TexBuffer(target, internalFormat glbase.Enum, buffer glbase.Buffer) {
+ C.gl3_2core_glTexBuffer(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLuint(buffer))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDrawElementsInstanced.xml
+func (gl *GL) DrawElementsInstanced(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}, instancecount int32) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2core_glDrawElementsInstanced(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr, C.GLsizei(instancecount))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDrawArraysInstanced.xml
+func (gl *GL) DrawArraysInstanced(mode glbase.Enum, first, count int, instancecount int32) {
+ C.gl3_2core_glDrawArraysInstanced(gl.funcs, C.GLenum(mode), C.GLint(first), C.GLsizei(count), C.GLsizei(instancecount))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSampleMaski.xml
+func (gl *GL) SampleMaski(index uint32, mask glbase.Bitfield) {
+ C.gl3_2core_glSampleMaski(gl.funcs, C.GLuint(index), C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetMultisamplefv.xml
+func (gl *GL) GetMultisamplefv(pname glbase.Enum, index uint32, val []float32) {
+ C.gl3_2core_glGetMultisamplefv(gl.funcs, C.GLenum(pname), C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&val[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexImage3DMultisample.xml
+func (gl *GL) TexImage3DMultisample(target glbase.Enum, samples, internalFormat int32, width, height int, depth int32, fixedsamplelocations bool) {
+ C.gl3_2core_glTexImage3DMultisample(gl.funcs, C.GLenum(target), C.GLsizei(samples), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), *(*C.GLboolean)(unsafe.Pointer(&fixedsamplelocations)))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexImage2DMultisample.xml
+func (gl *GL) TexImage2DMultisample(target glbase.Enum, samples, internalFormat int32, width, height int, fixedsamplelocations bool) {
+ C.gl3_2core_glTexImage2DMultisample(gl.funcs, C.GLenum(target), C.GLsizei(samples), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), *(*C.GLboolean)(unsafe.Pointer(&fixedsamplelocations)))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetSynciv.xml
+func (gl *GL) GetSynciv(sync glbase.Sync, pname glbase.Enum, bufSize int32, length, values []int32) {
+ C.gl3_2core_glGetSynciv(gl.funcs, C.GLsync(unsafe.Pointer(sync)), C.GLenum(pname), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLint)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetInteger64v.xml
+func (gl *GL) GetInteger64v(pname glbase.Enum, params []int64) {
+ C.gl3_2core_glGetInteger64v(gl.funcs, C.GLenum(pname), (*C.GLint64)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glWaitSync.xml
+func (gl *GL) WaitSync(sync glbase.Sync, flags glbase.Bitfield, timeout uint64) {
+ C.gl3_2core_glWaitSync(gl.funcs, C.GLsync(unsafe.Pointer(sync)), C.GLbitfield(flags), C.GLuint64(timeout))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClientWaitSync.xml
+func (gl *GL) ClientWaitSync(sync glbase.Sync, flags glbase.Bitfield, timeout uint64) glbase.Enum {
+ glresult := C.gl3_2core_glClientWaitSync(gl.funcs, C.GLsync(unsafe.Pointer(sync)), C.GLbitfield(flags), C.GLuint64(timeout))
+ return glbase.Enum(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDeleteSync.xml
+func (gl *GL) DeleteSync(sync glbase.Sync) {
+ C.gl3_2core_glDeleteSync(gl.funcs, C.GLsync(unsafe.Pointer(sync)))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsSync.xml
+func (gl *GL) IsSync(sync glbase.Sync) bool {
+ glresult := C.gl3_2core_glIsSync(gl.funcs, C.GLsync(unsafe.Pointer(sync)))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFenceSync.xml
+func (gl *GL) FenceSync(condition glbase.Enum, flags glbase.Bitfield) glbase.Sync {
+ glresult := C.gl3_2core_glFenceSync(gl.funcs, C.GLenum(condition), C.GLbitfield(flags))
+ return glbase.Sync(unsafe.Pointer(glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glProvokingVertex.xml
+func (gl *GL) ProvokingVertex(mode glbase.Enum) {
+ C.gl3_2core_glProvokingVertex(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDrawElementsInstancedBaseVertex.xml
+func (gl *GL) DrawElementsInstancedBaseVertex(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}, instancecount, basevertex int32) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2core_glDrawElementsInstancedBaseVertex(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr, C.GLsizei(instancecount), C.GLint(basevertex))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDrawRangeElementsBaseVertex.xml
+func (gl *GL) DrawRangeElementsBaseVertex(mode glbase.Enum, start, end uint32, count int, gltype glbase.Enum, indices interface{}, basevertex int32) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2core_glDrawRangeElementsBaseVertex(gl.funcs, C.GLenum(mode), C.GLuint(start), C.GLuint(end), C.GLsizei(count), C.GLenum(gltype), indices_ptr, C.GLint(basevertex))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDrawElementsBaseVertex.xml
+func (gl *GL) DrawElementsBaseVertex(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}, basevertex int32) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_2core_glDrawElementsBaseVertex(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr, C.GLint(basevertex))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFramebufferTexture.xml
+func (gl *GL) FramebufferTexture(target, attachment glbase.Enum, texture glbase.Texture, level int) {
+ C.gl3_2core_glFramebufferTexture(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLuint(texture), C.GLint(level))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetBufferParameteri64v.xml
+func (gl *GL) GetBufferParameteri64v(target, pname glbase.Enum, params []int64) {
+ C.gl3_2core_glGetBufferParameteri64v(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint64)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetInteger64i_v.xml
+func (gl *GL) GetInteger64i_v(target glbase.Enum, index uint32, data []int64) {
+ C.gl3_2core_glGetInteger64i_v(gl.funcs, C.GLenum(target), C.GLuint(index), (*C.GLint64)(unsafe.Pointer(&data[0])))
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/3.3compat/funcs.cpp b/Godeps/_workspace/src/github.com/obscuren/qml/gl/3.3compat/funcs.cpp
new file mode 100644
index 000000000..65c02b7de
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/3.3compat/funcs.cpp
@@ -0,0 +1,4488 @@
+
+// ** file automatically generated by glgen -- do not edit manually **
+
+#include <QOpenGLContext>
+#include <QtGui/qopenglfunctions_3_3_compatibility.h>
+
+#include "funcs.h"
+
+void *gl3_3compat_funcs() {
+ QOpenGLFunctions_3_3_Compatibility* funcs = QOpenGLContext::currentContext()->versionFunctions<QOpenGLFunctions_3_3_Compatibility>();
+ if (!funcs) {
+ return 0;
+ }
+ funcs->initializeOpenGLFunctions();
+ return funcs;
+}
+
+
+void gl3_3compat_glViewport(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glViewport(x, y, width, height);
+}
+
+void gl3_3compat_glDepthRange(void *_glfuncs, GLdouble nearVal, GLdouble farVal)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDepthRange(nearVal, farVal);
+}
+
+GLboolean gl3_3compat_glIsEnabled(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsEnabled(cap);
+}
+
+void gl3_3compat_glGetTexLevelParameteriv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexLevelParameteriv(target, level, pname, params);
+}
+
+void gl3_3compat_glGetTexLevelParameterfv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexLevelParameterfv(target, level, pname, params);
+}
+
+void gl3_3compat_glGetTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexParameteriv(target, pname, params);
+}
+
+void gl3_3compat_glGetTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexParameterfv(target, pname, params);
+}
+
+void gl3_3compat_glGetTexImage(void *_glfuncs, GLenum target, GLint level, GLenum format, GLenum gltype, GLvoid* pixels)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexImage(target, level, format, gltype, pixels);
+}
+
+void gl3_3compat_glGetIntegerv(void *_glfuncs, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetIntegerv(pname, params);
+}
+
+void gl3_3compat_glGetFloatv(void *_glfuncs, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetFloatv(pname, params);
+}
+
+GLenum gl3_3compat_glGetError(void *_glfuncs)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glGetError();
+}
+
+void gl3_3compat_glGetDoublev(void *_glfuncs, GLenum pname, GLdouble* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetDoublev(pname, params);
+}
+
+void gl3_3compat_glGetBooleanv(void *_glfuncs, GLenum pname, GLboolean* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetBooleanv(pname, params);
+}
+
+void gl3_3compat_glReadPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum gltype, GLvoid* pixels)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glReadPixels(x, y, width, height, format, gltype, pixels);
+}
+
+void gl3_3compat_glReadBuffer(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glReadBuffer(mode);
+}
+
+void gl3_3compat_glPixelStorei(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glPixelStorei(pname, param);
+}
+
+void gl3_3compat_glPixelStoref(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glPixelStoref(pname, param);
+}
+
+void gl3_3compat_glDepthFunc(void *_glfuncs, GLenum glfunc)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDepthFunc(glfunc);
+}
+
+void gl3_3compat_glStencilOp(void *_glfuncs, GLenum fail, GLenum zfail, GLenum zpass)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glStencilOp(fail, zfail, zpass);
+}
+
+void gl3_3compat_glStencilFunc(void *_glfuncs, GLenum glfunc, GLint ref, GLuint mask)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glStencilFunc(glfunc, ref, mask);
+}
+
+void gl3_3compat_glLogicOp(void *_glfuncs, GLenum opcode)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glLogicOp(opcode);
+}
+
+void gl3_3compat_glBlendFunc(void *_glfuncs, GLenum sfactor, GLenum dfactor)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glBlendFunc(sfactor, dfactor);
+}
+
+void gl3_3compat_glFlush(void *_glfuncs)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glFlush();
+}
+
+void gl3_3compat_glFinish(void *_glfuncs)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glFinish();
+}
+
+void gl3_3compat_glEnable(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glEnable(cap);
+}
+
+void gl3_3compat_glDisable(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDisable(cap);
+}
+
+void gl3_3compat_glDepthMask(void *_glfuncs, GLboolean flag)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDepthMask(flag);
+}
+
+void gl3_3compat_glColorMask(void *_glfuncs, GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorMask(red, green, blue, alpha);
+}
+
+void gl3_3compat_glStencilMask(void *_glfuncs, GLuint mask)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glStencilMask(mask);
+}
+
+void gl3_3compat_glClearDepth(void *_glfuncs, GLdouble depth)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glClearDepth(depth);
+}
+
+void gl3_3compat_glClearStencil(void *_glfuncs, GLint s)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glClearStencil(s);
+}
+
+void gl3_3compat_glClearColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glClearColor(red, green, blue, alpha);
+}
+
+void gl3_3compat_glClear(void *_glfuncs, GLbitfield mask)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glClear(mask);
+}
+
+void gl3_3compat_glDrawBuffer(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawBuffer(mode);
+}
+
+void gl3_3compat_glTexImage2D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexImage2D(target, level, internalFormat, width, height, border, format, gltype, pixels);
+}
+
+void gl3_3compat_glTexImage1D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexImage1D(target, level, internalFormat, width, border, format, gltype, pixels);
+}
+
+void gl3_3compat_glTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexParameteriv(target, pname, params);
+}
+
+void gl3_3compat_glTexParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexParameteri(target, pname, param);
+}
+
+void gl3_3compat_glTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexParameterfv(target, pname, params);
+}
+
+void gl3_3compat_glTexParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexParameterf(target, pname, param);
+}
+
+void gl3_3compat_glScissor(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glScissor(x, y, width, height);
+}
+
+void gl3_3compat_glPolygonMode(void *_glfuncs, GLenum face, GLenum mode)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glPolygonMode(face, mode);
+}
+
+void gl3_3compat_glPointSize(void *_glfuncs, GLfloat size)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glPointSize(size);
+}
+
+void gl3_3compat_glLineWidth(void *_glfuncs, GLfloat width)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glLineWidth(width);
+}
+
+void gl3_3compat_glHint(void *_glfuncs, GLenum target, GLenum mode)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glHint(target, mode);
+}
+
+void gl3_3compat_glFrontFace(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glFrontFace(mode);
+}
+
+void gl3_3compat_glCullFace(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glCullFace(mode);
+}
+
+void gl3_3compat_glIndexubv(void *_glfuncs, const GLubyte* c)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexubv(c);
+}
+
+void gl3_3compat_glIndexub(void *_glfuncs, GLubyte c)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexub(c);
+}
+
+GLboolean gl3_3compat_glIsTexture(void *_glfuncs, GLuint texture)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsTexture(texture);
+}
+
+void gl3_3compat_glGenTextures(void *_glfuncs, GLsizei n, GLuint* textures)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGenTextures(n, textures);
+}
+
+void gl3_3compat_glDeleteTextures(void *_glfuncs, GLsizei n, const GLuint* textures)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteTextures(n, textures);
+}
+
+void gl3_3compat_glBindTexture(void *_glfuncs, GLenum target, GLuint texture)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindTexture(target, texture);
+}
+
+void gl3_3compat_glTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexSubImage2D(target, level, xoffset, yoffset, width, height, format, gltype, pixels);
+}
+
+void gl3_3compat_glTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexSubImage1D(target, level, xoffset, width, format, gltype, pixels);
+}
+
+void gl3_3compat_glCopyTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage2D(target, level, xoffset, yoffset, x, y, width, height);
+}
+
+void gl3_3compat_glCopyTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage1D(target, level, xoffset, x, y, width);
+}
+
+void gl3_3compat_glCopyTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyTexImage2D(target, level, internalFormat, x, y, width, height, border);
+}
+
+void gl3_3compat_glCopyTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLint border)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyTexImage1D(target, level, internalFormat, x, y, width, border);
+}
+
+void gl3_3compat_glPolygonOffset(void *_glfuncs, GLfloat factor, GLfloat units)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glPolygonOffset(factor, units);
+}
+
+void gl3_3compat_glDrawElements(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawElements(mode, count, gltype, indices);
+}
+
+void gl3_3compat_glDrawArrays(void *_glfuncs, GLenum mode, GLint first, GLsizei count)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawArrays(mode, first, count);
+}
+
+void gl3_3compat_glCopyTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage3D(target, level, xoffset, yoffset, zoffset, x, y, width, height);
+}
+
+void gl3_3compat_glTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, gltype, pixels);
+}
+
+void gl3_3compat_glTexImage3D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexImage3D(target, level, internalFormat, width, height, depth, border, format, gltype, pixels);
+}
+
+void gl3_3compat_glDrawRangeElements(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawRangeElements(mode, start, end, count, gltype, indices);
+}
+
+void gl3_3compat_glBlendEquation(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glBlendEquation(mode);
+}
+
+void gl3_3compat_glBlendColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glBlendColor(red, green, blue, alpha);
+}
+
+void gl3_3compat_glGetCompressedTexImage(void *_glfuncs, GLenum target, GLint level, GLvoid* img)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetCompressedTexImage(target, level, img);
+}
+
+void gl3_3compat_glCompressedTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glCompressedTexSubImage1D(target, level, xoffset, width, format, imageSize, data);
+}
+
+void gl3_3compat_glCompressedTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glCompressedTexSubImage2D(target, level, xoffset, yoffset, width, height, format, imageSize, data);
+}
+
+void gl3_3compat_glCompressedTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glCompressedTexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, imageSize, data);
+}
+
+void gl3_3compat_glCompressedTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glCompressedTexImage1D(target, level, internalFormat, width, border, imageSize, data);
+}
+
+void gl3_3compat_glCompressedTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glCompressedTexImage2D(target, level, internalFormat, width, height, border, imageSize, data);
+}
+
+void gl3_3compat_glCompressedTexImage3D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glCompressedTexImage3D(target, level, internalFormat, width, height, depth, border, imageSize, data);
+}
+
+void gl3_3compat_glSampleCoverage(void *_glfuncs, GLfloat value, GLboolean invert)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glSampleCoverage(value, invert);
+}
+
+void gl3_3compat_glActiveTexture(void *_glfuncs, GLenum texture)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glActiveTexture(texture);
+}
+
+void gl3_3compat_glPointParameteriv(void *_glfuncs, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glPointParameteriv(pname, params);
+}
+
+void gl3_3compat_glPointParameteri(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glPointParameteri(pname, param);
+}
+
+void gl3_3compat_glPointParameterfv(void *_glfuncs, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glPointParameterfv(pname, params);
+}
+
+void gl3_3compat_glPointParameterf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glPointParameterf(pname, param);
+}
+
+void gl3_3compat_glMultiDrawArrays(void *_glfuncs, GLenum mode, const GLint* first, const GLsizei* count, GLsizei drawcount)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiDrawArrays(mode, first, count, drawcount);
+}
+
+void gl3_3compat_glBlendFuncSeparate(void *_glfuncs, GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glBlendFuncSeparate(sfactorRGB, dfactorRGB, sfactorAlpha, dfactorAlpha);
+}
+
+void gl3_3compat_glGetBufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetBufferParameteriv(target, pname, params);
+}
+
+GLboolean gl3_3compat_glUnmapBuffer(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glUnmapBuffer(target);
+}
+
+void gl3_3compat_glGetBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, GLvoid* data)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetBufferSubData(target, offset, size, data);
+}
+
+void gl3_3compat_glBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid* data)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glBufferSubData(target, offset, size, data);
+}
+
+void gl3_3compat_glBufferData(void *_glfuncs, GLenum target, GLsizeiptr size, const GLvoid* data, GLenum usage)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glBufferData(target, size, data, usage);
+}
+
+GLboolean gl3_3compat_glIsBuffer(void *_glfuncs, GLuint buffer)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsBuffer(buffer);
+}
+
+void gl3_3compat_glGenBuffers(void *_glfuncs, GLsizei n, GLuint* buffers)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGenBuffers(n, buffers);
+}
+
+void gl3_3compat_glDeleteBuffers(void *_glfuncs, GLsizei n, const GLuint* buffers)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteBuffers(n, buffers);
+}
+
+void gl3_3compat_glBindBuffer(void *_glfuncs, GLenum target, GLuint buffer)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindBuffer(target, buffer);
+}
+
+void gl3_3compat_glGetQueryObjectuiv(void *_glfuncs, GLuint id, GLenum pname, GLuint* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetQueryObjectuiv(id, pname, params);
+}
+
+void gl3_3compat_glGetQueryObjectiv(void *_glfuncs, GLuint id, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetQueryObjectiv(id, pname, params);
+}
+
+void gl3_3compat_glGetQueryiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetQueryiv(target, pname, params);
+}
+
+void gl3_3compat_glEndQuery(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glEndQuery(target);
+}
+
+void gl3_3compat_glBeginQuery(void *_glfuncs, GLenum target, GLuint id)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glBeginQuery(target, id);
+}
+
+GLboolean gl3_3compat_glIsQuery(void *_glfuncs, GLuint id)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsQuery(id);
+}
+
+void gl3_3compat_glDeleteQueries(void *_glfuncs, GLsizei n, const GLuint* ids)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteQueries(n, ids);
+}
+
+void gl3_3compat_glGenQueries(void *_glfuncs, GLsizei n, GLuint* ids)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGenQueries(n, ids);
+}
+
+void gl3_3compat_glVertexAttribPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLboolean normalized, GLsizei stride, const GLvoid* offset)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribPointer(index, size, gltype, normalized, stride, offset);
+}
+
+void gl3_3compat_glValidateProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glValidateProgram(program);
+}
+
+void gl3_3compat_glUniformMatrix4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4fv(location, count, transpose, value);
+}
+
+void gl3_3compat_glUniformMatrix3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3fv(location, count, transpose, value);
+}
+
+void gl3_3compat_glUniformMatrix2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2fv(location, count, transpose, value);
+}
+
+void gl3_3compat_glUniform4iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform4iv(location, count, value);
+}
+
+void gl3_3compat_glUniform3iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform3iv(location, count, value);
+}
+
+void gl3_3compat_glUniform2iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform2iv(location, count, value);
+}
+
+void gl3_3compat_glUniform1iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform1iv(location, count, value);
+}
+
+void gl3_3compat_glUniform4fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform4fv(location, count, value);
+}
+
+void gl3_3compat_glUniform3fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform3fv(location, count, value);
+}
+
+void gl3_3compat_glUniform2fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform2fv(location, count, value);
+}
+
+void gl3_3compat_glUniform1fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform1fv(location, count, value);
+}
+
+void gl3_3compat_glUniform4i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2, GLint v3)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform4i(location, v0, v1, v2, v3);
+}
+
+void gl3_3compat_glUniform3i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform3i(location, v0, v1, v2);
+}
+
+void gl3_3compat_glUniform2i(void *_glfuncs, GLint location, GLint v0, GLint v1)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform2i(location, v0, v1);
+}
+
+void gl3_3compat_glUniform1i(void *_glfuncs, GLint location, GLint v0)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform1i(location, v0);
+}
+
+void gl3_3compat_glUniform4f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform4f(location, v0, v1, v2, v3);
+}
+
+void gl3_3compat_glUniform3f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform3f(location, v0, v1, v2);
+}
+
+void gl3_3compat_glUniform2f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform2f(location, v0, v1);
+}
+
+void gl3_3compat_glUniform1f(void *_glfuncs, GLint location, GLfloat v0)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform1f(location, v0);
+}
+
+void gl3_3compat_glUseProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUseProgram(program);
+}
+
+void gl3_3compat_glShaderSource(void *_glfuncs, GLuint shader, GLsizei count, const GLchar** source, const GLint* length)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glShaderSource(shader, count, source, length);
+}
+
+void gl3_3compat_glLinkProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glLinkProgram(program);
+}
+
+GLboolean gl3_3compat_glIsShader(void *_glfuncs, GLuint shader)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsShader(shader);
+}
+
+GLboolean gl3_3compat_glIsProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsProgram(program);
+}
+
+void gl3_3compat_glGetVertexAttribiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribiv(index, pname, params);
+}
+
+void gl3_3compat_glGetVertexAttribfv(void *_glfuncs, GLuint index, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribfv(index, pname, params);
+}
+
+void gl3_3compat_glGetVertexAttribdv(void *_glfuncs, GLuint index, GLenum pname, GLdouble* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribdv(index, pname, params);
+}
+
+void gl3_3compat_glGetUniformiv(void *_glfuncs, GLuint program, GLint location, GLint* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetUniformiv(program, location, params);
+}
+
+void gl3_3compat_glGetUniformfv(void *_glfuncs, GLuint program, GLint location, GLfloat* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetUniformfv(program, location, params);
+}
+
+GLint gl3_3compat_glGetUniformLocation(void *_glfuncs, GLuint program, const GLchar* name)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glGetUniformLocation(program, name);
+}
+
+void gl3_3compat_glGetShaderSource(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* source)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetShaderSource(shader, bufSize, length, source);
+}
+
+void gl3_3compat_glGetShaderInfoLog(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* infoLog)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetShaderInfoLog(shader, bufSize, length, infoLog);
+}
+
+void gl3_3compat_glGetShaderiv(void *_glfuncs, GLuint shader, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetShaderiv(shader, pname, params);
+}
+
+void gl3_3compat_glGetProgramInfoLog(void *_glfuncs, GLuint program, GLsizei bufSize, GLsizei* length, GLchar* infoLog)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetProgramInfoLog(program, bufSize, length, infoLog);
+}
+
+void gl3_3compat_glGetProgramiv(void *_glfuncs, GLuint program, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetProgramiv(program, pname, params);
+}
+
+GLint gl3_3compat_glGetAttribLocation(void *_glfuncs, GLuint program, const GLchar* name)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glGetAttribLocation(program, name);
+}
+
+void gl3_3compat_glGetAttachedShaders(void *_glfuncs, GLuint program, GLsizei maxCount, GLsizei* count, GLuint* obj)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetAttachedShaders(program, maxCount, count, obj);
+}
+
+void gl3_3compat_glGetActiveUniform(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetActiveUniform(program, index, bufSize, length, size, gltype, name);
+}
+
+void gl3_3compat_glGetActiveAttrib(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetActiveAttrib(program, index, bufSize, length, size, gltype, name);
+}
+
+void gl3_3compat_glEnableVertexAttribArray(void *_glfuncs, GLuint index)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glEnableVertexAttribArray(index);
+}
+
+void gl3_3compat_glDisableVertexAttribArray(void *_glfuncs, GLuint index)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDisableVertexAttribArray(index);
+}
+
+void gl3_3compat_glDetachShader(void *_glfuncs, GLuint program, GLuint shader)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDetachShader(program, shader);
+}
+
+void gl3_3compat_glDeleteShader(void *_glfuncs, GLuint shader)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteShader(shader);
+}
+
+void gl3_3compat_glDeleteProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteProgram(program);
+}
+
+GLuint gl3_3compat_glCreateShader(void *_glfuncs, GLenum gltype)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glCreateShader(gltype);
+}
+
+GLuint gl3_3compat_glCreateProgram(void *_glfuncs)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glCreateProgram();
+}
+
+void gl3_3compat_glCompileShader(void *_glfuncs, GLuint shader)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glCompileShader(shader);
+}
+
+void gl3_3compat_glBindAttribLocation(void *_glfuncs, GLuint program, GLuint index, const GLchar* name)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindAttribLocation(program, index, name);
+}
+
+void gl3_3compat_glAttachShader(void *_glfuncs, GLuint program, GLuint shader)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glAttachShader(program, shader);
+}
+
+void gl3_3compat_glStencilMaskSeparate(void *_glfuncs, GLenum face, GLuint mask)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glStencilMaskSeparate(face, mask);
+}
+
+void gl3_3compat_glStencilFuncSeparate(void *_glfuncs, GLenum face, GLenum glfunc, GLint ref, GLuint mask)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glStencilFuncSeparate(face, glfunc, ref, mask);
+}
+
+void gl3_3compat_glStencilOpSeparate(void *_glfuncs, GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glStencilOpSeparate(face, sfail, dpfail, dppass);
+}
+
+void gl3_3compat_glDrawBuffers(void *_glfuncs, GLsizei n, const GLenum* bufs)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawBuffers(n, bufs);
+}
+
+void gl3_3compat_glBlendEquationSeparate(void *_glfuncs, GLenum modeRGB, GLenum modeAlpha)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glBlendEquationSeparate(modeRGB, modeAlpha);
+}
+
+void gl3_3compat_glUniformMatrix4x3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4x3fv(location, count, transpose, value);
+}
+
+void gl3_3compat_glUniformMatrix3x4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3x4fv(location, count, transpose, value);
+}
+
+void gl3_3compat_glUniformMatrix4x2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4x2fv(location, count, transpose, value);
+}
+
+void gl3_3compat_glUniformMatrix2x4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2x4fv(location, count, transpose, value);
+}
+
+void gl3_3compat_glUniformMatrix3x2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3x2fv(location, count, transpose, value);
+}
+
+void gl3_3compat_glUniformMatrix2x3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2x3fv(location, count, transpose, value);
+}
+
+GLboolean gl3_3compat_glIsVertexArray(void *_glfuncs, GLuint array)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsVertexArray(array);
+}
+
+void gl3_3compat_glGenVertexArrays(void *_glfuncs, GLsizei n, GLuint* arrays)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGenVertexArrays(n, arrays);
+}
+
+void gl3_3compat_glDeleteVertexArrays(void *_glfuncs, GLsizei n, const GLuint* arrays)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteVertexArrays(n, arrays);
+}
+
+void gl3_3compat_glBindVertexArray(void *_glfuncs, GLuint array)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindVertexArray(array);
+}
+
+void gl3_3compat_glFlushMappedBufferRange(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr length)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glFlushMappedBufferRange(target, offset, length);
+}
+
+void gl3_3compat_glFramebufferTextureLayer(void *_glfuncs, GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glFramebufferTextureLayer(target, attachment, texture, level, layer);
+}
+
+void gl3_3compat_glRenderbufferStorageMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLenum internalFormat, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRenderbufferStorageMultisample(target, samples, internalFormat, width, height);
+}
+
+void gl3_3compat_glBlitFramebuffer(void *_glfuncs, GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glBlitFramebuffer(srcX0, srcY0, srcX1, srcY1, dstX0, dstY0, dstX1, dstY1, mask, filter);
+}
+
+void gl3_3compat_glGenerateMipmap(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGenerateMipmap(target);
+}
+
+void gl3_3compat_glGetFramebufferAttachmentParameteriv(void *_glfuncs, GLenum target, GLenum attachment, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetFramebufferAttachmentParameteriv(target, attachment, pname, params);
+}
+
+void gl3_3compat_glFramebufferRenderbuffer(void *_glfuncs, GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glFramebufferRenderbuffer(target, attachment, renderbuffertarget, renderbuffer);
+}
+
+void gl3_3compat_glFramebufferTexture3D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glFramebufferTexture3D(target, attachment, textarget, texture, level, zoffset);
+}
+
+void gl3_3compat_glFramebufferTexture2D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glFramebufferTexture2D(target, attachment, textarget, texture, level);
+}
+
+void gl3_3compat_glFramebufferTexture1D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glFramebufferTexture1D(target, attachment, textarget, texture, level);
+}
+
+GLenum gl3_3compat_glCheckFramebufferStatus(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glCheckFramebufferStatus(target);
+}
+
+void gl3_3compat_glGenFramebuffers(void *_glfuncs, GLsizei n, GLuint* framebuffers)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGenFramebuffers(n, framebuffers);
+}
+
+void gl3_3compat_glDeleteFramebuffers(void *_glfuncs, GLsizei n, const GLuint* framebuffers)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteFramebuffers(n, framebuffers);
+}
+
+void gl3_3compat_glBindFramebuffer(void *_glfuncs, GLenum target, GLuint framebuffer)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindFramebuffer(target, framebuffer);
+}
+
+GLboolean gl3_3compat_glIsFramebuffer(void *_glfuncs, GLuint framebuffer)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsFramebuffer(framebuffer);
+}
+
+void gl3_3compat_glGetRenderbufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetRenderbufferParameteriv(target, pname, params);
+}
+
+void gl3_3compat_glRenderbufferStorage(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRenderbufferStorage(target, internalFormat, width, height);
+}
+
+void gl3_3compat_glGenRenderbuffers(void *_glfuncs, GLsizei n, GLuint* renderbuffers)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGenRenderbuffers(n, renderbuffers);
+}
+
+void gl3_3compat_glDeleteRenderbuffers(void *_glfuncs, GLsizei n, const GLuint* renderbuffers)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteRenderbuffers(n, renderbuffers);
+}
+
+void gl3_3compat_glBindRenderbuffer(void *_glfuncs, GLenum target, GLuint renderbuffer)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindRenderbuffer(target, renderbuffer);
+}
+
+GLboolean gl3_3compat_glIsRenderbuffer(void *_glfuncs, GLuint renderbuffer)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsRenderbuffer(renderbuffer);
+}
+
+void gl3_3compat_glClearBufferfi(void *_glfuncs, GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glClearBufferfi(buffer, drawbuffer, depth, stencil);
+}
+
+void gl3_3compat_glClearBufferfv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLfloat* value)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glClearBufferfv(buffer, drawbuffer, value);
+}
+
+void gl3_3compat_glClearBufferuiv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLuint* value)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glClearBufferuiv(buffer, drawbuffer, value);
+}
+
+void gl3_3compat_glClearBufferiv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLint* value)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glClearBufferiv(buffer, drawbuffer, value);
+}
+
+void gl3_3compat_glGetTexParameterIuiv(void *_glfuncs, GLenum target, GLenum pname, GLuint* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexParameterIuiv(target, pname, params);
+}
+
+void gl3_3compat_glGetTexParameterIiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexParameterIiv(target, pname, params);
+}
+
+void gl3_3compat_glTexParameterIuiv(void *_glfuncs, GLenum target, GLenum pname, const GLuint* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexParameterIuiv(target, pname, params);
+}
+
+void gl3_3compat_glTexParameterIiv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexParameterIiv(target, pname, params);
+}
+
+void gl3_3compat_glUniform4uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform4uiv(location, count, value);
+}
+
+void gl3_3compat_glUniform3uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform3uiv(location, count, value);
+}
+
+void gl3_3compat_glUniform2uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform2uiv(location, count, value);
+}
+
+void gl3_3compat_glUniform1uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform1uiv(location, count, value);
+}
+
+void gl3_3compat_glUniform4ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform4ui(location, v0, v1, v2, v3);
+}
+
+void gl3_3compat_glUniform3ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1, GLuint v2)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform3ui(location, v0, v1, v2);
+}
+
+void gl3_3compat_glUniform2ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform2ui(location, v0, v1);
+}
+
+void gl3_3compat_glUniform1ui(void *_glfuncs, GLint location, GLuint v0)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform1ui(location, v0);
+}
+
+GLint gl3_3compat_glGetFragDataLocation(void *_glfuncs, GLuint program, const GLchar* name)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glGetFragDataLocation(program, name);
+}
+
+void gl3_3compat_glBindFragDataLocation(void *_glfuncs, GLuint program, GLuint color, const GLchar* name)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindFragDataLocation(program, color, name);
+}
+
+void gl3_3compat_glGetUniformuiv(void *_glfuncs, GLuint program, GLint location, GLuint* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetUniformuiv(program, location, params);
+}
+
+void gl3_3compat_glGetVertexAttribIuiv(void *_glfuncs, GLuint index, GLenum pname, GLuint* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribIuiv(index, pname, params);
+}
+
+void gl3_3compat_glGetVertexAttribIiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribIiv(index, pname, params);
+}
+
+void gl3_3compat_glVertexAttribIPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribIPointer(index, size, gltype, stride, pointer);
+}
+
+void gl3_3compat_glEndConditionalRender(void *_glfuncs)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glEndConditionalRender();
+}
+
+void gl3_3compat_glBeginConditionalRender(void *_glfuncs, GLuint id, GLenum mode)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glBeginConditionalRender(id, mode);
+}
+
+void gl3_3compat_glClampColor(void *_glfuncs, GLenum target, GLenum clamp)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glClampColor(target, clamp);
+}
+
+void gl3_3compat_glGetTransformFeedbackVarying(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLsizei* size, GLenum* gltype, GLchar* name)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTransformFeedbackVarying(program, index, bufSize, length, size, gltype, name);
+}
+
+void gl3_3compat_glBindBufferBase(void *_glfuncs, GLenum target, GLuint index, GLuint buffer)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindBufferBase(target, index, buffer);
+}
+
+void gl3_3compat_glBindBufferRange(void *_glfuncs, GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindBufferRange(target, index, buffer, offset, size);
+}
+
+void gl3_3compat_glEndTransformFeedback(void *_glfuncs)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glEndTransformFeedback();
+}
+
+void gl3_3compat_glBeginTransformFeedback(void *_glfuncs, GLenum primitiveMode)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glBeginTransformFeedback(primitiveMode);
+}
+
+GLboolean gl3_3compat_glIsEnabledi(void *_glfuncs, GLenum target, GLuint index)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsEnabledi(target, index);
+}
+
+void gl3_3compat_glDisablei(void *_glfuncs, GLenum target, GLuint index)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDisablei(target, index);
+}
+
+void gl3_3compat_glEnablei(void *_glfuncs, GLenum target, GLuint index)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glEnablei(target, index);
+}
+
+void gl3_3compat_glGetIntegeri_v(void *_glfuncs, GLenum target, GLuint index, GLint* data)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetIntegeri_v(target, index, data);
+}
+
+void gl3_3compat_glGetBooleani_v(void *_glfuncs, GLenum target, GLuint index, GLboolean* data)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetBooleani_v(target, index, data);
+}
+
+void gl3_3compat_glColorMaski(void *_glfuncs, GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorMaski(index, r, g, b, a);
+}
+
+void gl3_3compat_glCopyBufferSubData(void *_glfuncs, GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyBufferSubData(readTarget, writeTarget, readOffset, writeOffset, size);
+}
+
+void gl3_3compat_glUniformBlockBinding(void *_glfuncs, GLuint program, GLuint v0, GLuint v1)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformBlockBinding(program, v0, v1);
+}
+
+void gl3_3compat_glGetActiveUniformBlockName(void *_glfuncs, GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei* length, GLchar* uniformBlockName)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetActiveUniformBlockName(program, uniformBlockIndex, bufSize, length, uniformBlockName);
+}
+
+void gl3_3compat_glGetActiveUniformBlockiv(void *_glfuncs, GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetActiveUniformBlockiv(program, uniformBlockIndex, pname, params);
+}
+
+GLuint gl3_3compat_glGetUniformBlockIndex(void *_glfuncs, GLuint program, const GLchar* uniformBlockName)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glGetUniformBlockIndex(program, uniformBlockName);
+}
+
+void gl3_3compat_glGetActiveUniformName(void *_glfuncs, GLuint program, GLuint uniformIndex, GLsizei bufSize, GLsizei* length, GLchar* uniformName)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetActiveUniformName(program, uniformIndex, bufSize, length, uniformName);
+}
+
+void gl3_3compat_glGetActiveUniformsiv(void *_glfuncs, GLuint program, GLsizei uniformCount, const GLuint* uniformIndices, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetActiveUniformsiv(program, uniformCount, uniformIndices, pname, params);
+}
+
+void gl3_3compat_glPrimitiveRestartIndex(void *_glfuncs, GLuint index)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glPrimitiveRestartIndex(index);
+}
+
+void gl3_3compat_glTexBuffer(void *_glfuncs, GLenum target, GLenum internalFormat, GLuint buffer)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexBuffer(target, internalFormat, buffer);
+}
+
+void gl3_3compat_glDrawElementsInstanced(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawElementsInstanced(mode, count, gltype, indices, instancecount);
+}
+
+void gl3_3compat_glDrawArraysInstanced(void *_glfuncs, GLenum mode, GLint first, GLsizei count, GLsizei instancecount)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawArraysInstanced(mode, first, count, instancecount);
+}
+
+void gl3_3compat_glSampleMaski(void *_glfuncs, GLuint index, GLbitfield mask)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glSampleMaski(index, mask);
+}
+
+void gl3_3compat_glGetMultisamplefv(void *_glfuncs, GLenum pname, GLuint index, GLfloat* val)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetMultisamplefv(pname, index, val);
+}
+
+void gl3_3compat_glTexImage3DMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexImage3DMultisample(target, samples, internalFormat, width, height, depth, fixedsamplelocations);
+}
+
+void gl3_3compat_glTexImage2DMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLint internalFormat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexImage2DMultisample(target, samples, internalFormat, width, height, fixedsamplelocations);
+}
+
+void gl3_3compat_glGetSynciv(void *_glfuncs, GLsync sync, GLenum pname, GLsizei bufSize, GLsizei* length, GLint* values)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetSynciv(sync, pname, bufSize, length, values);
+}
+
+void gl3_3compat_glGetInteger64v(void *_glfuncs, GLenum pname, GLint64* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetInteger64v(pname, params);
+}
+
+void gl3_3compat_glWaitSync(void *_glfuncs, GLsync sync, GLbitfield flags, GLuint64 timeout)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glWaitSync(sync, flags, timeout);
+}
+
+GLenum gl3_3compat_glClientWaitSync(void *_glfuncs, GLsync sync, GLbitfield flags, GLuint64 timeout)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glClientWaitSync(sync, flags, timeout);
+}
+
+void gl3_3compat_glDeleteSync(void *_glfuncs, GLsync sync)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteSync(sync);
+}
+
+GLboolean gl3_3compat_glIsSync(void *_glfuncs, GLsync sync)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsSync(sync);
+}
+
+GLsync gl3_3compat_glFenceSync(void *_glfuncs, GLenum condition, GLbitfield flags)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glFenceSync(condition, flags);
+}
+
+void gl3_3compat_glProvokingVertex(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glProvokingVertex(mode);
+}
+
+void gl3_3compat_glDrawElementsInstancedBaseVertex(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount, GLint basevertex)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawElementsInstancedBaseVertex(mode, count, gltype, indices, instancecount, basevertex);
+}
+
+void gl3_3compat_glDrawRangeElementsBaseVertex(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices, GLint basevertex)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawRangeElementsBaseVertex(mode, start, end, count, gltype, indices, basevertex);
+}
+
+void gl3_3compat_glDrawElementsBaseVertex(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLint basevertex)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawElementsBaseVertex(mode, count, gltype, indices, basevertex);
+}
+
+void gl3_3compat_glFramebufferTexture(void *_glfuncs, GLenum target, GLenum attachment, GLuint texture, GLint level)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glFramebufferTexture(target, attachment, texture, level);
+}
+
+void gl3_3compat_glGetBufferParameteri64v(void *_glfuncs, GLenum target, GLenum pname, GLint64* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetBufferParameteri64v(target, pname, params);
+}
+
+void gl3_3compat_glGetInteger64i_v(void *_glfuncs, GLenum target, GLuint index, GLint64* data)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetInteger64i_v(target, index, data);
+}
+
+void gl3_3compat_glVertexAttribP4uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribP4uiv(index, gltype, normalized, value);
+}
+
+void gl3_3compat_glVertexAttribP4ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribP4ui(index, gltype, normalized, value);
+}
+
+void gl3_3compat_glVertexAttribP3uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribP3uiv(index, gltype, normalized, value);
+}
+
+void gl3_3compat_glVertexAttribP3ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribP3ui(index, gltype, normalized, value);
+}
+
+void gl3_3compat_glVertexAttribP2uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribP2uiv(index, gltype, normalized, value);
+}
+
+void gl3_3compat_glVertexAttribP2ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribP2ui(index, gltype, normalized, value);
+}
+
+void gl3_3compat_glVertexAttribP1uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribP1uiv(index, gltype, normalized, value);
+}
+
+void gl3_3compat_glVertexAttribP1ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribP1ui(index, gltype, normalized, value);
+}
+
+void gl3_3compat_glSecondaryColorP3uiv(void *_glfuncs, GLenum gltype, const GLuint* color)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColorP3uiv(gltype, color);
+}
+
+void gl3_3compat_glSecondaryColorP3ui(void *_glfuncs, GLenum gltype, GLuint color)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColorP3ui(gltype, color);
+}
+
+void gl3_3compat_glColorP4uiv(void *_glfuncs, GLenum gltype, const GLuint* color)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorP4uiv(gltype, color);
+}
+
+void gl3_3compat_glColorP4ui(void *_glfuncs, GLenum gltype, GLuint color)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorP4ui(gltype, color);
+}
+
+void gl3_3compat_glColorP3uiv(void *_glfuncs, GLenum gltype, const GLuint* color)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorP3uiv(gltype, color);
+}
+
+void gl3_3compat_glColorP3ui(void *_glfuncs, GLenum gltype, GLuint color)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorP3ui(gltype, color);
+}
+
+void gl3_3compat_glNormalP3uiv(void *_glfuncs, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormalP3uiv(gltype, coords);
+}
+
+void gl3_3compat_glNormalP3ui(void *_glfuncs, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormalP3ui(gltype, coords);
+}
+
+void gl3_3compat_glMultiTexCoordP4uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP4uiv(texture, gltype, coords);
+}
+
+void gl3_3compat_glMultiTexCoordP4ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP4ui(texture, gltype, coords);
+}
+
+void gl3_3compat_glMultiTexCoordP3uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP3uiv(texture, gltype, coords);
+}
+
+void gl3_3compat_glMultiTexCoordP3ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP3ui(texture, gltype, coords);
+}
+
+void gl3_3compat_glMultiTexCoordP2uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP2uiv(texture, gltype, coords);
+}
+
+void gl3_3compat_glMultiTexCoordP2ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP2ui(texture, gltype, coords);
+}
+
+void gl3_3compat_glMultiTexCoordP1uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP1uiv(texture, gltype, coords);
+}
+
+void gl3_3compat_glMultiTexCoordP1ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP1ui(texture, gltype, coords);
+}
+
+void gl3_3compat_glTexCoordP4uiv(void *_glfuncs, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoordP4uiv(gltype, coords);
+}
+
+void gl3_3compat_glTexCoordP4ui(void *_glfuncs, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoordP4ui(gltype, coords);
+}
+
+void gl3_3compat_glTexCoordP3uiv(void *_glfuncs, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoordP3uiv(gltype, coords);
+}
+
+void gl3_3compat_glTexCoordP3ui(void *_glfuncs, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoordP3ui(gltype, coords);
+}
+
+void gl3_3compat_glTexCoordP2uiv(void *_glfuncs, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoordP2uiv(gltype, coords);
+}
+
+void gl3_3compat_glTexCoordP2ui(void *_glfuncs, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoordP2ui(gltype, coords);
+}
+
+void gl3_3compat_glTexCoordP1uiv(void *_glfuncs, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoordP1uiv(gltype, coords);
+}
+
+void gl3_3compat_glTexCoordP1ui(void *_glfuncs, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoordP1ui(gltype, coords);
+}
+
+void gl3_3compat_glVertexP4uiv(void *_glfuncs, GLenum gltype, const GLuint* value)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexP4uiv(gltype, value);
+}
+
+void gl3_3compat_glVertexP4ui(void *_glfuncs, GLenum gltype, GLuint value)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexP4ui(gltype, value);
+}
+
+void gl3_3compat_glVertexP3uiv(void *_glfuncs, GLenum gltype, const GLuint* value)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexP3uiv(gltype, value);
+}
+
+void gl3_3compat_glVertexP3ui(void *_glfuncs, GLenum gltype, GLuint value)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexP3ui(gltype, value);
+}
+
+void gl3_3compat_glVertexP2uiv(void *_glfuncs, GLenum gltype, const GLuint* value)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexP2uiv(gltype, value);
+}
+
+void gl3_3compat_glVertexP2ui(void *_glfuncs, GLenum gltype, GLuint value)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexP2ui(gltype, value);
+}
+
+void gl3_3compat_glGetQueryObjectui64v(void *_glfuncs, GLuint id, GLenum pname, GLuint64* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetQueryObjectui64v(id, pname, params);
+}
+
+void gl3_3compat_glGetQueryObjecti64v(void *_glfuncs, GLuint id, GLenum pname, GLint64* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetQueryObjecti64v(id, pname, params);
+}
+
+void gl3_3compat_glQueryCounter(void *_glfuncs, GLuint id, GLenum target)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glQueryCounter(id, target);
+}
+
+void gl3_3compat_glGetSamplerParameterIuiv(void *_glfuncs, GLuint sampler, GLenum pname, GLuint* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetSamplerParameterIuiv(sampler, pname, params);
+}
+
+void gl3_3compat_glGetSamplerParameterfv(void *_glfuncs, GLuint sampler, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetSamplerParameterfv(sampler, pname, params);
+}
+
+void gl3_3compat_glGetSamplerParameterIiv(void *_glfuncs, GLuint sampler, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetSamplerParameterIiv(sampler, pname, params);
+}
+
+void gl3_3compat_glGetSamplerParameteriv(void *_glfuncs, GLuint sampler, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetSamplerParameteriv(sampler, pname, params);
+}
+
+void gl3_3compat_glSamplerParameterIuiv(void *_glfuncs, GLuint sampler, GLenum pname, const GLuint* param)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glSamplerParameterIuiv(sampler, pname, param);
+}
+
+void gl3_3compat_glSamplerParameterIiv(void *_glfuncs, GLuint sampler, GLenum pname, const GLint* param)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glSamplerParameterIiv(sampler, pname, param);
+}
+
+void gl3_3compat_glSamplerParameterfv(void *_glfuncs, GLuint sampler, GLenum pname, const GLfloat* param)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glSamplerParameterfv(sampler, pname, param);
+}
+
+void gl3_3compat_glSamplerParameterf(void *_glfuncs, GLuint sampler, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glSamplerParameterf(sampler, pname, param);
+}
+
+void gl3_3compat_glSamplerParameteriv(void *_glfuncs, GLuint sampler, GLenum pname, const GLint* param)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glSamplerParameteriv(sampler, pname, param);
+}
+
+void gl3_3compat_glSamplerParameteri(void *_glfuncs, GLuint sampler, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glSamplerParameteri(sampler, pname, param);
+}
+
+void gl3_3compat_glBindSampler(void *_glfuncs, GLuint unit, GLuint sampler)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindSampler(unit, sampler);
+}
+
+GLboolean gl3_3compat_glIsSampler(void *_glfuncs, GLuint sampler)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsSampler(sampler);
+}
+
+void gl3_3compat_glDeleteSamplers(void *_glfuncs, GLsizei count, const GLuint* samplers)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteSamplers(count, samplers);
+}
+
+void gl3_3compat_glGenSamplers(void *_glfuncs, GLsizei count, GLuint* samplers)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGenSamplers(count, samplers);
+}
+
+GLint gl3_3compat_glGetFragDataIndex(void *_glfuncs, GLuint program, const GLchar* name)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glGetFragDataIndex(program, name);
+}
+
+void gl3_3compat_glBindFragDataLocationIndexed(void *_glfuncs, GLuint program, GLuint colorNumber, GLuint index, const GLchar* name)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindFragDataLocationIndexed(program, colorNumber, index, name);
+}
+
+void gl3_3compat_glVertexAttribDivisor(void *_glfuncs, GLuint index, GLuint divisor)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribDivisor(index, divisor);
+}
+
+void gl3_3compat_glTranslatef(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTranslatef(x, y, z);
+}
+
+void gl3_3compat_glTranslated(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTranslated(x, y, z);
+}
+
+void gl3_3compat_glScalef(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glScalef(x, y, z);
+}
+
+void gl3_3compat_glScaled(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glScaled(x, y, z);
+}
+
+void gl3_3compat_glRotatef(void *_glfuncs, GLfloat angle, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRotatef(angle, x, y, z);
+}
+
+void gl3_3compat_glRotated(void *_glfuncs, GLdouble angle, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRotated(angle, x, y, z);
+}
+
+void gl3_3compat_glPushMatrix(void *_glfuncs)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glPushMatrix();
+}
+
+void gl3_3compat_glPopMatrix(void *_glfuncs)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glPopMatrix();
+}
+
+void gl3_3compat_glOrtho(void *_glfuncs, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glOrtho(left, right, bottom, top, zNear, zFar);
+}
+
+void gl3_3compat_glMultMatrixd(void *_glfuncs, const GLdouble* m)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultMatrixd(m);
+}
+
+void gl3_3compat_glMultMatrixf(void *_glfuncs, const GLfloat* m)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultMatrixf(m);
+}
+
+void gl3_3compat_glMatrixMode(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMatrixMode(mode);
+}
+
+void gl3_3compat_glLoadMatrixd(void *_glfuncs, const GLdouble* m)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glLoadMatrixd(m);
+}
+
+void gl3_3compat_glLoadMatrixf(void *_glfuncs, const GLfloat* m)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glLoadMatrixf(m);
+}
+
+void gl3_3compat_glLoadIdentity(void *_glfuncs)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glLoadIdentity();
+}
+
+void gl3_3compat_glFrustum(void *_glfuncs, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glFrustum(left, right, bottom, top, zNear, zFar);
+}
+
+GLboolean gl3_3compat_glIsList(void *_glfuncs, GLuint list)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsList(list);
+}
+
+void gl3_3compat_glGetTexGeniv(void *_glfuncs, GLenum coord, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexGeniv(coord, pname, params);
+}
+
+void gl3_3compat_glGetTexGenfv(void *_glfuncs, GLenum coord, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexGenfv(coord, pname, params);
+}
+
+void gl3_3compat_glGetTexGendv(void *_glfuncs, GLenum coord, GLenum pname, GLdouble* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexGendv(coord, pname, params);
+}
+
+void gl3_3compat_glGetTexEnviv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexEnviv(target, pname, params);
+}
+
+void gl3_3compat_glGetTexEnvfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexEnvfv(target, pname, params);
+}
+
+void gl3_3compat_glGetPolygonStipple(void *_glfuncs, GLubyte* mask)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetPolygonStipple(mask);
+}
+
+void gl3_3compat_glGetPixelMapusv(void *_glfuncs, GLenum glmap, GLushort* values)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetPixelMapusv(glmap, values);
+}
+
+void gl3_3compat_glGetPixelMapuiv(void *_glfuncs, GLenum glmap, GLuint* values)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetPixelMapuiv(glmap, values);
+}
+
+void gl3_3compat_glGetPixelMapfv(void *_glfuncs, GLenum glmap, GLfloat* values)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetPixelMapfv(glmap, values);
+}
+
+void gl3_3compat_glGetMaterialiv(void *_glfuncs, GLenum face, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetMaterialiv(face, pname, params);
+}
+
+void gl3_3compat_glGetMaterialfv(void *_glfuncs, GLenum face, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetMaterialfv(face, pname, params);
+}
+
+void gl3_3compat_glGetMapiv(void *_glfuncs, GLenum target, GLenum query, GLint* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetMapiv(target, query, v);
+}
+
+void gl3_3compat_glGetMapfv(void *_glfuncs, GLenum target, GLenum query, GLfloat* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetMapfv(target, query, v);
+}
+
+void gl3_3compat_glGetMapdv(void *_glfuncs, GLenum target, GLenum query, GLdouble* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetMapdv(target, query, v);
+}
+
+void gl3_3compat_glGetLightiv(void *_glfuncs, GLenum light, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetLightiv(light, pname, params);
+}
+
+void gl3_3compat_glGetLightfv(void *_glfuncs, GLenum light, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetLightfv(light, pname, params);
+}
+
+void gl3_3compat_glGetClipPlane(void *_glfuncs, GLenum plane, GLdouble* equation)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetClipPlane(plane, equation);
+}
+
+void gl3_3compat_glDrawPixels(void *_glfuncs, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawPixels(width, height, format, gltype, pixels);
+}
+
+void gl3_3compat_glCopyPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum gltype)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyPixels(x, y, width, height, gltype);
+}
+
+void gl3_3compat_glPixelMapusv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLushort* values)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glPixelMapusv(glmap, mapsize, values);
+}
+
+void gl3_3compat_glPixelMapuiv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLuint* values)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glPixelMapuiv(glmap, mapsize, values);
+}
+
+void gl3_3compat_glPixelMapfv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLfloat* values)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glPixelMapfv(glmap, mapsize, values);
+}
+
+void gl3_3compat_glPixelTransferi(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glPixelTransferi(pname, param);
+}
+
+void gl3_3compat_glPixelTransferf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glPixelTransferf(pname, param);
+}
+
+void gl3_3compat_glPixelZoom(void *_glfuncs, GLfloat xfactor, GLfloat yfactor)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glPixelZoom(xfactor, yfactor);
+}
+
+void gl3_3compat_glAlphaFunc(void *_glfuncs, GLenum glfunc, GLfloat ref)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glAlphaFunc(glfunc, ref);
+}
+
+void gl3_3compat_glEvalPoint2(void *_glfuncs, GLint i, GLint j)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalPoint2(i, j);
+}
+
+void gl3_3compat_glEvalMesh2(void *_glfuncs, GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalMesh2(mode, i1, i2, j1, j2);
+}
+
+void gl3_3compat_glEvalPoint1(void *_glfuncs, GLint i)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalPoint1(i);
+}
+
+void gl3_3compat_glEvalMesh1(void *_glfuncs, GLenum mode, GLint i1, GLint i2)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalMesh1(mode, i1, i2);
+}
+
+void gl3_3compat_glEvalCoord2fv(void *_glfuncs, const GLfloat* u)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalCoord2fv(u);
+}
+
+void gl3_3compat_glEvalCoord2f(void *_glfuncs, GLfloat u, GLfloat v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalCoord2f(u, v);
+}
+
+void gl3_3compat_glEvalCoord2dv(void *_glfuncs, const GLdouble* u)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalCoord2dv(u);
+}
+
+void gl3_3compat_glEvalCoord2d(void *_glfuncs, GLdouble u, GLdouble v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalCoord2d(u, v);
+}
+
+void gl3_3compat_glEvalCoord1fv(void *_glfuncs, const GLfloat* u)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalCoord1fv(u);
+}
+
+void gl3_3compat_glEvalCoord1f(void *_glfuncs, GLfloat u)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalCoord1f(u);
+}
+
+void gl3_3compat_glEvalCoord1dv(void *_glfuncs, const GLdouble* u)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalCoord1dv(u);
+}
+
+void gl3_3compat_glEvalCoord1d(void *_glfuncs, GLdouble u)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalCoord1d(u);
+}
+
+void gl3_3compat_glMapGrid2f(void *_glfuncs, GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMapGrid2f(un, u1, u2, vn, v1, v2);
+}
+
+void gl3_3compat_glMapGrid2d(void *_glfuncs, GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMapGrid2d(un, u1, u2, vn, v1, v2);
+}
+
+void gl3_3compat_glMapGrid1f(void *_glfuncs, GLint un, GLfloat u1, GLfloat u2)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMapGrid1f(un, u1, u2);
+}
+
+void gl3_3compat_glMapGrid1d(void *_glfuncs, GLint un, GLdouble u1, GLdouble u2)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMapGrid1d(un, u1, u2);
+}
+
+void gl3_3compat_glMap2f(void *_glfuncs, GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat* points)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMap2f(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+void gl3_3compat_glMap2d(void *_glfuncs, GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble* points)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMap2d(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+void gl3_3compat_glMap1f(void *_glfuncs, GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat* points)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMap1f(target, u1, u2, stride, order, points);
+}
+
+void gl3_3compat_glMap1d(void *_glfuncs, GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble* points)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMap1d(target, u1, u2, stride, order, points);
+}
+
+void gl3_3compat_glPushAttrib(void *_glfuncs, GLbitfield mask)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glPushAttrib(mask);
+}
+
+void gl3_3compat_glPopAttrib(void *_glfuncs)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glPopAttrib();
+}
+
+void gl3_3compat_glAccum(void *_glfuncs, GLenum op, GLfloat value)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glAccum(op, value);
+}
+
+void gl3_3compat_glIndexMask(void *_glfuncs, GLuint mask)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexMask(mask);
+}
+
+void gl3_3compat_glClearIndex(void *_glfuncs, GLfloat c)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glClearIndex(c);
+}
+
+void gl3_3compat_glClearAccum(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glClearAccum(red, green, blue, alpha);
+}
+
+void gl3_3compat_glPushName(void *_glfuncs, GLuint name)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glPushName(name);
+}
+
+void gl3_3compat_glPopName(void *_glfuncs)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glPopName();
+}
+
+void gl3_3compat_glPassThrough(void *_glfuncs, GLfloat token)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glPassThrough(token);
+}
+
+void gl3_3compat_glLoadName(void *_glfuncs, GLuint name)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glLoadName(name);
+}
+
+void gl3_3compat_glInitNames(void *_glfuncs)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glInitNames();
+}
+
+GLint gl3_3compat_glRenderMode(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glRenderMode(mode);
+}
+
+void gl3_3compat_glSelectBuffer(void *_glfuncs, GLsizei size, GLuint* buffer)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glSelectBuffer(size, buffer);
+}
+
+void gl3_3compat_glFeedbackBuffer(void *_glfuncs, GLsizei size, GLenum gltype, GLfloat* buffer)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glFeedbackBuffer(size, gltype, buffer);
+}
+
+void gl3_3compat_glTexGeniv(void *_glfuncs, GLenum coord, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexGeniv(coord, pname, params);
+}
+
+void gl3_3compat_glTexGeni(void *_glfuncs, GLenum coord, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexGeni(coord, pname, param);
+}
+
+void gl3_3compat_glTexGenfv(void *_glfuncs, GLenum coord, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexGenfv(coord, pname, params);
+}
+
+void gl3_3compat_glTexGenf(void *_glfuncs, GLenum coord, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexGenf(coord, pname, param);
+}
+
+void gl3_3compat_glTexGendv(void *_glfuncs, GLenum coord, GLenum pname, const GLdouble* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexGendv(coord, pname, params);
+}
+
+void gl3_3compat_glTexGend(void *_glfuncs, GLenum coord, GLenum pname, GLdouble param)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexGend(coord, pname, param);
+}
+
+void gl3_3compat_glTexEnviv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexEnviv(target, pname, params);
+}
+
+void gl3_3compat_glTexEnvi(void *_glfuncs, GLenum target, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexEnvi(target, pname, param);
+}
+
+void gl3_3compat_glTexEnvfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexEnvfv(target, pname, params);
+}
+
+void gl3_3compat_glTexEnvf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexEnvf(target, pname, param);
+}
+
+void gl3_3compat_glShadeModel(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glShadeModel(mode);
+}
+
+void gl3_3compat_glPolygonStipple(void *_glfuncs, const GLubyte* mask)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glPolygonStipple(mask);
+}
+
+void gl3_3compat_glMaterialiv(void *_glfuncs, GLenum face, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMaterialiv(face, pname, params);
+}
+
+void gl3_3compat_glMateriali(void *_glfuncs, GLenum face, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMateriali(face, pname, param);
+}
+
+void gl3_3compat_glMaterialfv(void *_glfuncs, GLenum face, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMaterialfv(face, pname, params);
+}
+
+void gl3_3compat_glMaterialf(void *_glfuncs, GLenum face, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMaterialf(face, pname, param);
+}
+
+void gl3_3compat_glLineStipple(void *_glfuncs, GLint factor, GLushort pattern)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glLineStipple(factor, pattern);
+}
+
+void gl3_3compat_glLightModeliv(void *_glfuncs, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glLightModeliv(pname, params);
+}
+
+void gl3_3compat_glLightModeli(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glLightModeli(pname, param);
+}
+
+void gl3_3compat_glLightModelfv(void *_glfuncs, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glLightModelfv(pname, params);
+}
+
+void gl3_3compat_glLightModelf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glLightModelf(pname, param);
+}
+
+void gl3_3compat_glLightiv(void *_glfuncs, GLenum light, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glLightiv(light, pname, params);
+}
+
+void gl3_3compat_glLighti(void *_glfuncs, GLenum light, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glLighti(light, pname, param);
+}
+
+void gl3_3compat_glLightfv(void *_glfuncs, GLenum light, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glLightfv(light, pname, params);
+}
+
+void gl3_3compat_glLightf(void *_glfuncs, GLenum light, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glLightf(light, pname, param);
+}
+
+void gl3_3compat_glFogiv(void *_glfuncs, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glFogiv(pname, params);
+}
+
+void gl3_3compat_glFogi(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glFogi(pname, param);
+}
+
+void gl3_3compat_glFogfv(void *_glfuncs, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glFogfv(pname, params);
+}
+
+void gl3_3compat_glFogf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glFogf(pname, param);
+}
+
+void gl3_3compat_glColorMaterial(void *_glfuncs, GLenum face, GLenum mode)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorMaterial(face, mode);
+}
+
+void gl3_3compat_glClipPlane(void *_glfuncs, GLenum plane, const GLdouble* equation)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glClipPlane(plane, equation);
+}
+
+void gl3_3compat_glVertex4sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex4sv(v);
+}
+
+void gl3_3compat_glVertex4s(void *_glfuncs, GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex4s(x, y, z, w);
+}
+
+void gl3_3compat_glVertex4iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex4iv(v);
+}
+
+void gl3_3compat_glVertex4i(void *_glfuncs, GLint x, GLint y, GLint z, GLint w)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex4i(x, y, z, w);
+}
+
+void gl3_3compat_glVertex4fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex4fv(v);
+}
+
+void gl3_3compat_glVertex4f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex4f(x, y, z, w);
+}
+
+void gl3_3compat_glVertex4dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex4dv(v);
+}
+
+void gl3_3compat_glVertex4d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex4d(x, y, z, w);
+}
+
+void gl3_3compat_glVertex3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex3sv(v);
+}
+
+void gl3_3compat_glVertex3s(void *_glfuncs, GLshort x, GLshort y, GLshort z)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex3s(x, y, z);
+}
+
+void gl3_3compat_glVertex3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex3iv(v);
+}
+
+void gl3_3compat_glVertex3i(void *_glfuncs, GLint x, GLint y, GLint z)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex3i(x, y, z);
+}
+
+void gl3_3compat_glVertex3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex3fv(v);
+}
+
+void gl3_3compat_glVertex3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex3f(x, y, z);
+}
+
+void gl3_3compat_glVertex3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex3dv(v);
+}
+
+void gl3_3compat_glVertex3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex3d(x, y, z);
+}
+
+void gl3_3compat_glVertex2sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex2sv(v);
+}
+
+void gl3_3compat_glVertex2s(void *_glfuncs, GLshort x, GLshort y)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex2s(x, y);
+}
+
+void gl3_3compat_glVertex2iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex2iv(v);
+}
+
+void gl3_3compat_glVertex2i(void *_glfuncs, GLint x, GLint y)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex2i(x, y);
+}
+
+void gl3_3compat_glVertex2fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex2fv(v);
+}
+
+void gl3_3compat_glVertex2f(void *_glfuncs, GLfloat x, GLfloat y)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex2f(x, y);
+}
+
+void gl3_3compat_glVertex2dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex2dv(v);
+}
+
+void gl3_3compat_glVertex2d(void *_glfuncs, GLdouble x, GLdouble y)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex2d(x, y);
+}
+
+void gl3_3compat_glTexCoord4sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord4sv(v);
+}
+
+void gl3_3compat_glTexCoord4s(void *_glfuncs, GLshort s, GLshort t, GLshort r, GLshort q)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord4s(s, t, r, q);
+}
+
+void gl3_3compat_glTexCoord4iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord4iv(v);
+}
+
+void gl3_3compat_glTexCoord4i(void *_glfuncs, GLint s, GLint t, GLint r, GLint q)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord4i(s, t, r, q);
+}
+
+void gl3_3compat_glTexCoord4fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord4fv(v);
+}
+
+void gl3_3compat_glTexCoord4f(void *_glfuncs, GLfloat s, GLfloat t, GLfloat r, GLfloat q)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord4f(s, t, r, q);
+}
+
+void gl3_3compat_glTexCoord4dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord4dv(v);
+}
+
+void gl3_3compat_glTexCoord4d(void *_glfuncs, GLdouble s, GLdouble t, GLdouble r, GLdouble q)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord4d(s, t, r, q);
+}
+
+void gl3_3compat_glTexCoord3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord3sv(v);
+}
+
+void gl3_3compat_glTexCoord3s(void *_glfuncs, GLshort s, GLshort t, GLshort r)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord3s(s, t, r);
+}
+
+void gl3_3compat_glTexCoord3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord3iv(v);
+}
+
+void gl3_3compat_glTexCoord3i(void *_glfuncs, GLint s, GLint t, GLint r)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord3i(s, t, r);
+}
+
+void gl3_3compat_glTexCoord3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord3fv(v);
+}
+
+void gl3_3compat_glTexCoord3f(void *_glfuncs, GLfloat s, GLfloat t, GLfloat r)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord3f(s, t, r);
+}
+
+void gl3_3compat_glTexCoord3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord3dv(v);
+}
+
+void gl3_3compat_glTexCoord3d(void *_glfuncs, GLdouble s, GLdouble t, GLdouble r)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord3d(s, t, r);
+}
+
+void gl3_3compat_glTexCoord2sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord2sv(v);
+}
+
+void gl3_3compat_glTexCoord2s(void *_glfuncs, GLshort s, GLshort t)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord2s(s, t);
+}
+
+void gl3_3compat_glTexCoord2iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord2iv(v);
+}
+
+void gl3_3compat_glTexCoord2i(void *_glfuncs, GLint s, GLint t)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord2i(s, t);
+}
+
+void gl3_3compat_glTexCoord2fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord2fv(v);
+}
+
+void gl3_3compat_glTexCoord2f(void *_glfuncs, GLfloat s, GLfloat t)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord2f(s, t);
+}
+
+void gl3_3compat_glTexCoord2dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord2dv(v);
+}
+
+void gl3_3compat_glTexCoord2d(void *_glfuncs, GLdouble s, GLdouble t)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord2d(s, t);
+}
+
+void gl3_3compat_glTexCoord1sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord1sv(v);
+}
+
+void gl3_3compat_glTexCoord1s(void *_glfuncs, GLshort s)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord1s(s);
+}
+
+void gl3_3compat_glTexCoord1iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord1iv(v);
+}
+
+void gl3_3compat_glTexCoord1i(void *_glfuncs, GLint s)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord1i(s);
+}
+
+void gl3_3compat_glTexCoord1fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord1fv(v);
+}
+
+void gl3_3compat_glTexCoord1f(void *_glfuncs, GLfloat s)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord1f(s);
+}
+
+void gl3_3compat_glTexCoord1dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord1dv(v);
+}
+
+void gl3_3compat_glTexCoord1d(void *_glfuncs, GLdouble s)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord1d(s);
+}
+
+void gl3_3compat_glRectsv(void *_glfuncs, const GLshort* v1, const GLshort* v2)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRectsv(v1, v2);
+}
+
+void gl3_3compat_glRects(void *_glfuncs, GLshort x1, GLshort y1, GLshort x2, GLshort y2)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRects(x1, y1, x2, y2);
+}
+
+void gl3_3compat_glRectiv(void *_glfuncs, const GLint* v1, const GLint* v2)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRectiv(v1, v2);
+}
+
+void gl3_3compat_glRecti(void *_glfuncs, GLint x1, GLint y1, GLint x2, GLint y2)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRecti(x1, y1, x2, y2);
+}
+
+void gl3_3compat_glRectfv(void *_glfuncs, const GLfloat* v1, const GLfloat* v2)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRectfv(v1, v2);
+}
+
+void gl3_3compat_glRectf(void *_glfuncs, GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRectf(x1, y1, x2, y2);
+}
+
+void gl3_3compat_glRectdv(void *_glfuncs, const GLdouble* v1, const GLdouble* v2)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRectdv(v1, v2);
+}
+
+void gl3_3compat_glRectd(void *_glfuncs, GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRectd(x1, y1, x2, y2);
+}
+
+void gl3_3compat_glRasterPos4sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos4sv(v);
+}
+
+void gl3_3compat_glRasterPos4s(void *_glfuncs, GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos4s(x, y, z, w);
+}
+
+void gl3_3compat_glRasterPos4iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos4iv(v);
+}
+
+void gl3_3compat_glRasterPos4i(void *_glfuncs, GLint x, GLint y, GLint z, GLint w)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos4i(x, y, z, w);
+}
+
+void gl3_3compat_glRasterPos4fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos4fv(v);
+}
+
+void gl3_3compat_glRasterPos4f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos4f(x, y, z, w);
+}
+
+void gl3_3compat_glRasterPos4dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos4dv(v);
+}
+
+void gl3_3compat_glRasterPos4d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos4d(x, y, z, w);
+}
+
+void gl3_3compat_glRasterPos3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos3sv(v);
+}
+
+void gl3_3compat_glRasterPos3s(void *_glfuncs, GLshort x, GLshort y, GLshort z)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos3s(x, y, z);
+}
+
+void gl3_3compat_glRasterPos3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos3iv(v);
+}
+
+void gl3_3compat_glRasterPos3i(void *_glfuncs, GLint x, GLint y, GLint z)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos3i(x, y, z);
+}
+
+void gl3_3compat_glRasterPos3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos3fv(v);
+}
+
+void gl3_3compat_glRasterPos3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos3f(x, y, z);
+}
+
+void gl3_3compat_glRasterPos3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos3dv(v);
+}
+
+void gl3_3compat_glRasterPos3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos3d(x, y, z);
+}
+
+void gl3_3compat_glRasterPos2sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos2sv(v);
+}
+
+void gl3_3compat_glRasterPos2s(void *_glfuncs, GLshort x, GLshort y)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos2s(x, y);
+}
+
+void gl3_3compat_glRasterPos2iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos2iv(v);
+}
+
+void gl3_3compat_glRasterPos2i(void *_glfuncs, GLint x, GLint y)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos2i(x, y);
+}
+
+void gl3_3compat_glRasterPos2fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos2fv(v);
+}
+
+void gl3_3compat_glRasterPos2f(void *_glfuncs, GLfloat x, GLfloat y)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos2f(x, y);
+}
+
+void gl3_3compat_glRasterPos2dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos2dv(v);
+}
+
+void gl3_3compat_glRasterPos2d(void *_glfuncs, GLdouble x, GLdouble y)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos2d(x, y);
+}
+
+void gl3_3compat_glNormal3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormal3sv(v);
+}
+
+void gl3_3compat_glNormal3s(void *_glfuncs, GLshort nx, GLshort ny, GLshort nz)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormal3s(nx, ny, nz);
+}
+
+void gl3_3compat_glNormal3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormal3iv(v);
+}
+
+void gl3_3compat_glNormal3i(void *_glfuncs, GLint nx, GLint ny, GLint nz)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormal3i(nx, ny, nz);
+}
+
+void gl3_3compat_glNormal3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormal3fv(v);
+}
+
+void gl3_3compat_glNormal3f(void *_glfuncs, GLfloat nx, GLfloat ny, GLfloat nz)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormal3f(nx, ny, nz);
+}
+
+void gl3_3compat_glNormal3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormal3dv(v);
+}
+
+void gl3_3compat_glNormal3d(void *_glfuncs, GLdouble nx, GLdouble ny, GLdouble nz)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormal3d(nx, ny, nz);
+}
+
+void gl3_3compat_glNormal3bv(void *_glfuncs, const GLbyte* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormal3bv(v);
+}
+
+void gl3_3compat_glNormal3b(void *_glfuncs, GLbyte nx, GLbyte ny, GLbyte nz)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormal3b(nx, ny, nz);
+}
+
+void gl3_3compat_glIndexsv(void *_glfuncs, const GLshort* c)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexsv(c);
+}
+
+void gl3_3compat_glIndexs(void *_glfuncs, GLshort c)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexs(c);
+}
+
+void gl3_3compat_glIndexiv(void *_glfuncs, const GLint* c)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexiv(c);
+}
+
+void gl3_3compat_glIndexi(void *_glfuncs, GLint c)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexi(c);
+}
+
+void gl3_3compat_glIndexfv(void *_glfuncs, const GLfloat* c)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexfv(c);
+}
+
+void gl3_3compat_glIndexf(void *_glfuncs, GLfloat c)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexf(c);
+}
+
+void gl3_3compat_glIndexdv(void *_glfuncs, const GLdouble* c)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexdv(c);
+}
+
+void gl3_3compat_glIndexd(void *_glfuncs, GLdouble c)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexd(c);
+}
+
+void gl3_3compat_glEnd(void *_glfuncs)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glEnd();
+}
+
+void gl3_3compat_glEdgeFlagv(void *_glfuncs, const GLboolean* flag)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glEdgeFlagv(flag);
+}
+
+void gl3_3compat_glEdgeFlag(void *_glfuncs, GLboolean flag)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glEdgeFlag(flag);
+}
+
+void gl3_3compat_glColor4usv(void *_glfuncs, const GLushort* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4usv(v);
+}
+
+void gl3_3compat_glColor4us(void *_glfuncs, GLushort red, GLushort green, GLushort blue, GLushort alpha)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4us(red, green, blue, alpha);
+}
+
+void gl3_3compat_glColor4uiv(void *_glfuncs, const GLuint* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4uiv(v);
+}
+
+void gl3_3compat_glColor4ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue, GLuint alpha)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4ui(red, green, blue, alpha);
+}
+
+void gl3_3compat_glColor4ubv(void *_glfuncs, const GLubyte* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4ubv(v);
+}
+
+void gl3_3compat_glColor4ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4ub(red, green, blue, alpha);
+}
+
+void gl3_3compat_glColor4sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4sv(v);
+}
+
+void gl3_3compat_glColor4s(void *_glfuncs, GLshort red, GLshort green, GLshort blue, GLshort alpha)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4s(red, green, blue, alpha);
+}
+
+void gl3_3compat_glColor4iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4iv(v);
+}
+
+void gl3_3compat_glColor4i(void *_glfuncs, GLint red, GLint green, GLint blue, GLint alpha)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4i(red, green, blue, alpha);
+}
+
+void gl3_3compat_glColor4fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4fv(v);
+}
+
+void gl3_3compat_glColor4f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4f(red, green, blue, alpha);
+}
+
+void gl3_3compat_glColor4dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4dv(v);
+}
+
+void gl3_3compat_glColor4d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4d(red, green, blue, alpha);
+}
+
+void gl3_3compat_glColor4bv(void *_glfuncs, const GLbyte* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4bv(v);
+}
+
+void gl3_3compat_glColor4b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4b(red, green, blue, alpha);
+}
+
+void gl3_3compat_glColor3usv(void *_glfuncs, const GLushort* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3usv(v);
+}
+
+void gl3_3compat_glColor3us(void *_glfuncs, GLushort red, GLushort green, GLushort blue)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3us(red, green, blue);
+}
+
+void gl3_3compat_glColor3uiv(void *_glfuncs, const GLuint* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3uiv(v);
+}
+
+void gl3_3compat_glColor3ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3ui(red, green, blue);
+}
+
+void gl3_3compat_glColor3ubv(void *_glfuncs, const GLubyte* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3ubv(v);
+}
+
+void gl3_3compat_glColor3ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3ub(red, green, blue);
+}
+
+void gl3_3compat_glColor3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3sv(v);
+}
+
+void gl3_3compat_glColor3s(void *_glfuncs, GLshort red, GLshort green, GLshort blue)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3s(red, green, blue);
+}
+
+void gl3_3compat_glColor3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3iv(v);
+}
+
+void gl3_3compat_glColor3i(void *_glfuncs, GLint red, GLint green, GLint blue)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3i(red, green, blue);
+}
+
+void gl3_3compat_glColor3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3fv(v);
+}
+
+void gl3_3compat_glColor3f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3f(red, green, blue);
+}
+
+void gl3_3compat_glColor3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3dv(v);
+}
+
+void gl3_3compat_glColor3d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3d(red, green, blue);
+}
+
+void gl3_3compat_glColor3bv(void *_glfuncs, const GLbyte* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3bv(v);
+}
+
+void gl3_3compat_glColor3b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3b(red, green, blue);
+}
+
+void gl3_3compat_glBitmap(void *_glfuncs, GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte* bitmap)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glBitmap(width, height, xorig, yorig, xmove, ymove, bitmap);
+}
+
+void gl3_3compat_glBegin(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glBegin(mode);
+}
+
+void gl3_3compat_glListBase(void *_glfuncs, GLuint base)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glListBase(base);
+}
+
+GLuint gl3_3compat_glGenLists(void *_glfuncs, GLsizei range_)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glGenLists(range_);
+}
+
+void gl3_3compat_glDeleteLists(void *_glfuncs, GLuint list, GLsizei range_)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteLists(list, range_);
+}
+
+void gl3_3compat_glCallLists(void *_glfuncs, GLsizei n, GLenum gltype, const GLvoid* lists)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glCallLists(n, gltype, lists);
+}
+
+void gl3_3compat_glCallList(void *_glfuncs, GLuint list)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glCallList(list);
+}
+
+void gl3_3compat_glEndList(void *_glfuncs)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glEndList();
+}
+
+void gl3_3compat_glNewList(void *_glfuncs, GLuint list, GLenum mode)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glNewList(list, mode);
+}
+
+void gl3_3compat_glPushClientAttrib(void *_glfuncs, GLbitfield mask)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glPushClientAttrib(mask);
+}
+
+void gl3_3compat_glPopClientAttrib(void *_glfuncs)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glPopClientAttrib();
+}
+
+void gl3_3compat_glPrioritizeTextures(void *_glfuncs, GLsizei n, const GLuint* textures, const GLfloat* priorities)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glPrioritizeTextures(n, textures, priorities);
+}
+
+GLboolean gl3_3compat_glAreTexturesResident(void *_glfuncs, GLsizei n, const GLuint* textures, GLboolean* residences)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glAreTexturesResident(n, textures, residences);
+}
+
+void gl3_3compat_glVertexPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexPointer(size, gltype, stride, pointer);
+}
+
+void gl3_3compat_glTexCoordPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoordPointer(size, gltype, stride, pointer);
+}
+
+void gl3_3compat_glNormalPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormalPointer(gltype, stride, pointer);
+}
+
+void gl3_3compat_glInterleavedArrays(void *_glfuncs, GLenum format, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glInterleavedArrays(format, stride, pointer);
+}
+
+void gl3_3compat_glIndexPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexPointer(gltype, stride, pointer);
+}
+
+void gl3_3compat_glEnableClientState(void *_glfuncs, GLenum array)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glEnableClientState(array);
+}
+
+void gl3_3compat_glEdgeFlagPointer(void *_glfuncs, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glEdgeFlagPointer(stride, pointer);
+}
+
+void gl3_3compat_glDisableClientState(void *_glfuncs, GLenum array)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDisableClientState(array);
+}
+
+void gl3_3compat_glColorPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorPointer(size, gltype, stride, pointer);
+}
+
+void gl3_3compat_glArrayElement(void *_glfuncs, GLint i)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glArrayElement(i);
+}
+
+void gl3_3compat_glResetMinmax(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glResetMinmax(target);
+}
+
+void gl3_3compat_glResetHistogram(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glResetHistogram(target);
+}
+
+void gl3_3compat_glMinmax(void *_glfuncs, GLenum target, GLenum internalFormat, GLboolean sink)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMinmax(target, internalFormat, sink);
+}
+
+void gl3_3compat_glHistogram(void *_glfuncs, GLenum target, GLsizei width, GLenum internalFormat, GLboolean sink)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glHistogram(target, width, internalFormat, sink);
+}
+
+void gl3_3compat_glGetMinmaxParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetMinmaxParameteriv(target, pname, params);
+}
+
+void gl3_3compat_glGetMinmaxParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetMinmaxParameterfv(target, pname, params);
+}
+
+void gl3_3compat_glGetMinmax(void *_glfuncs, GLenum target, GLboolean reset, GLenum format, GLenum gltype, GLvoid* values)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetMinmax(target, reset, format, gltype, values);
+}
+
+void gl3_3compat_glGetHistogramParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetHistogramParameteriv(target, pname, params);
+}
+
+void gl3_3compat_glGetHistogramParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetHistogramParameterfv(target, pname, params);
+}
+
+void gl3_3compat_glGetHistogram(void *_glfuncs, GLenum target, GLboolean reset, GLenum format, GLenum gltype, GLvoid* values)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetHistogram(target, reset, format, gltype, values);
+}
+
+void gl3_3compat_glSeparableFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* row, const GLvoid* column)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glSeparableFilter2D(target, internalFormat, width, height, format, gltype, row, column);
+}
+
+void gl3_3compat_glGetSeparableFilter(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* row, GLvoid* column, GLvoid* span)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetSeparableFilter(target, format, gltype, row, column, span);
+}
+
+void gl3_3compat_glGetConvolutionParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetConvolutionParameteriv(target, pname, params);
+}
+
+void gl3_3compat_glGetConvolutionParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetConvolutionParameterfv(target, pname, params);
+}
+
+void gl3_3compat_glGetConvolutionFilter(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* image)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetConvolutionFilter(target, format, gltype, image);
+}
+
+void gl3_3compat_glCopyConvolutionFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyConvolutionFilter2D(target, internalFormat, x, y, width, height);
+}
+
+void gl3_3compat_glCopyConvolutionFilter1D(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyConvolutionFilter1D(target, internalFormat, x, y, width);
+}
+
+void gl3_3compat_glConvolutionParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glConvolutionParameteriv(target, pname, params);
+}
+
+void gl3_3compat_glConvolutionParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glConvolutionParameteri(target, pname, params);
+}
+
+void gl3_3compat_glConvolutionParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glConvolutionParameterfv(target, pname, params);
+}
+
+void gl3_3compat_glConvolutionParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glConvolutionParameterf(target, pname, params);
+}
+
+void gl3_3compat_glConvolutionFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* image)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glConvolutionFilter2D(target, internalFormat, width, height, format, gltype, image);
+}
+
+void gl3_3compat_glConvolutionFilter1D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLenum format, GLenum gltype, const GLvoid* image)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glConvolutionFilter1D(target, internalFormat, width, format, gltype, image);
+}
+
+void gl3_3compat_glCopyColorSubTable(void *_glfuncs, GLenum target, GLsizei start, GLint x, GLint y, GLsizei width)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyColorSubTable(target, start, x, y, width);
+}
+
+void gl3_3compat_glColorSubTable(void *_glfuncs, GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum gltype, const GLvoid* data)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorSubTable(target, start, count, format, gltype, data);
+}
+
+void gl3_3compat_glGetColorTableParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetColorTableParameteriv(target, pname, params);
+}
+
+void gl3_3compat_glGetColorTableParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetColorTableParameterfv(target, pname, params);
+}
+
+void gl3_3compat_glGetColorTable(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* table)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetColorTable(target, format, gltype, table);
+}
+
+void gl3_3compat_glCopyColorTable(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyColorTable(target, internalFormat, x, y, width);
+}
+
+void gl3_3compat_glColorTableParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorTableParameteriv(target, pname, params);
+}
+
+void gl3_3compat_glColorTableParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorTableParameterfv(target, pname, params);
+}
+
+void gl3_3compat_glColorTable(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLenum format, GLenum gltype, const GLvoid* table)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorTable(target, internalFormat, width, format, gltype, table);
+}
+
+void gl3_3compat_glMultTransposeMatrixd(void *_glfuncs, const GLdouble* m)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultTransposeMatrixd(m);
+}
+
+void gl3_3compat_glMultTransposeMatrixf(void *_glfuncs, const GLfloat* m)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultTransposeMatrixf(m);
+}
+
+void gl3_3compat_glLoadTransposeMatrixd(void *_glfuncs, const GLdouble* m)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glLoadTransposeMatrixd(m);
+}
+
+void gl3_3compat_glLoadTransposeMatrixf(void *_glfuncs, const GLfloat* m)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glLoadTransposeMatrixf(m);
+}
+
+void gl3_3compat_glMultiTexCoord4sv(void *_glfuncs, GLenum target, const GLshort* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4sv(target, v);
+}
+
+void gl3_3compat_glMultiTexCoord4s(void *_glfuncs, GLenum target, GLshort s, GLshort t, GLshort r, GLshort q)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4s(target, s, t, r, q);
+}
+
+void gl3_3compat_glMultiTexCoord4iv(void *_glfuncs, GLenum target, const GLint* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4iv(target, v);
+}
+
+void gl3_3compat_glMultiTexCoord4i(void *_glfuncs, GLenum target, GLint s, GLint t, GLint r, GLint q)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4i(target, s, t, r, q);
+}
+
+void gl3_3compat_glMultiTexCoord4fv(void *_glfuncs, GLenum target, const GLfloat* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4fv(target, v);
+}
+
+void gl3_3compat_glMultiTexCoord4f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4f(target, s, t, r, q);
+}
+
+void gl3_3compat_glMultiTexCoord4dv(void *_glfuncs, GLenum target, const GLdouble* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4dv(target, v);
+}
+
+void gl3_3compat_glMultiTexCoord4d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4d(target, s, t, r, q);
+}
+
+void gl3_3compat_glMultiTexCoord3sv(void *_glfuncs, GLenum target, const GLshort* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3sv(target, v);
+}
+
+void gl3_3compat_glMultiTexCoord3s(void *_glfuncs, GLenum target, GLshort s, GLshort t, GLshort r)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3s(target, s, t, r);
+}
+
+void gl3_3compat_glMultiTexCoord3iv(void *_glfuncs, GLenum target, const GLint* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3iv(target, v);
+}
+
+void gl3_3compat_glMultiTexCoord3i(void *_glfuncs, GLenum target, GLint s, GLint t, GLint r)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3i(target, s, t, r);
+}
+
+void gl3_3compat_glMultiTexCoord3fv(void *_glfuncs, GLenum target, const GLfloat* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3fv(target, v);
+}
+
+void gl3_3compat_glMultiTexCoord3f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t, GLfloat r)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3f(target, s, t, r);
+}
+
+void gl3_3compat_glMultiTexCoord3dv(void *_glfuncs, GLenum target, const GLdouble* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3dv(target, v);
+}
+
+void gl3_3compat_glMultiTexCoord3d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t, GLdouble r)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3d(target, s, t, r);
+}
+
+void gl3_3compat_glMultiTexCoord2sv(void *_glfuncs, GLenum target, const GLshort* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2sv(target, v);
+}
+
+void gl3_3compat_glMultiTexCoord2s(void *_glfuncs, GLenum target, GLshort s, GLshort t)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2s(target, s, t);
+}
+
+void gl3_3compat_glMultiTexCoord2iv(void *_glfuncs, GLenum target, const GLint* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2iv(target, v);
+}
+
+void gl3_3compat_glMultiTexCoord2i(void *_glfuncs, GLenum target, GLint s, GLint t)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2i(target, s, t);
+}
+
+void gl3_3compat_glMultiTexCoord2fv(void *_glfuncs, GLenum target, const GLfloat* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2fv(target, v);
+}
+
+void gl3_3compat_glMultiTexCoord2f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2f(target, s, t);
+}
+
+void gl3_3compat_glMultiTexCoord2dv(void *_glfuncs, GLenum target, const GLdouble* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2dv(target, v);
+}
+
+void gl3_3compat_glMultiTexCoord2d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2d(target, s, t);
+}
+
+void gl3_3compat_glMultiTexCoord1sv(void *_glfuncs, GLenum target, const GLshort* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1sv(target, v);
+}
+
+void gl3_3compat_glMultiTexCoord1s(void *_glfuncs, GLenum target, GLshort s)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1s(target, s);
+}
+
+void gl3_3compat_glMultiTexCoord1iv(void *_glfuncs, GLenum target, const GLint* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1iv(target, v);
+}
+
+void gl3_3compat_glMultiTexCoord1i(void *_glfuncs, GLenum target, GLint s)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1i(target, s);
+}
+
+void gl3_3compat_glMultiTexCoord1fv(void *_glfuncs, GLenum target, const GLfloat* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1fv(target, v);
+}
+
+void gl3_3compat_glMultiTexCoord1f(void *_glfuncs, GLenum target, GLfloat s)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1f(target, s);
+}
+
+void gl3_3compat_glMultiTexCoord1dv(void *_glfuncs, GLenum target, const GLdouble* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1dv(target, v);
+}
+
+void gl3_3compat_glMultiTexCoord1d(void *_glfuncs, GLenum target, GLdouble s)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1d(target, s);
+}
+
+void gl3_3compat_glClientActiveTexture(void *_glfuncs, GLenum texture)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glClientActiveTexture(texture);
+}
+
+void gl3_3compat_glWindowPos3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos3sv(v);
+}
+
+void gl3_3compat_glWindowPos3s(void *_glfuncs, GLshort x, GLshort y, GLshort z)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos3s(x, y, z);
+}
+
+void gl3_3compat_glWindowPos3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos3iv(v);
+}
+
+void gl3_3compat_glWindowPos3i(void *_glfuncs, GLint x, GLint y, GLint z)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos3i(x, y, z);
+}
+
+void gl3_3compat_glWindowPos3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos3fv(v);
+}
+
+void gl3_3compat_glWindowPos3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos3f(x, y, z);
+}
+
+void gl3_3compat_glWindowPos3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos3dv(v);
+}
+
+void gl3_3compat_glWindowPos3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos3d(x, y, z);
+}
+
+void gl3_3compat_glWindowPos2sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos2sv(v);
+}
+
+void gl3_3compat_glWindowPos2s(void *_glfuncs, GLshort x, GLshort y)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos2s(x, y);
+}
+
+void gl3_3compat_glWindowPos2iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos2iv(v);
+}
+
+void gl3_3compat_glWindowPos2i(void *_glfuncs, GLint x, GLint y)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos2i(x, y);
+}
+
+void gl3_3compat_glWindowPos2fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos2fv(v);
+}
+
+void gl3_3compat_glWindowPos2f(void *_glfuncs, GLfloat x, GLfloat y)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos2f(x, y);
+}
+
+void gl3_3compat_glWindowPos2dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos2dv(v);
+}
+
+void gl3_3compat_glWindowPos2d(void *_glfuncs, GLdouble x, GLdouble y)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos2d(x, y);
+}
+
+void gl3_3compat_glSecondaryColorPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColorPointer(size, gltype, stride, pointer);
+}
+
+void gl3_3compat_glSecondaryColor3usv(void *_glfuncs, const GLushort* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3usv(v);
+}
+
+void gl3_3compat_glSecondaryColor3us(void *_glfuncs, GLushort red, GLushort green, GLushort blue)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3us(red, green, blue);
+}
+
+void gl3_3compat_glSecondaryColor3uiv(void *_glfuncs, const GLuint* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3uiv(v);
+}
+
+void gl3_3compat_glSecondaryColor3ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3ui(red, green, blue);
+}
+
+void gl3_3compat_glSecondaryColor3ubv(void *_glfuncs, const GLubyte* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3ubv(v);
+}
+
+void gl3_3compat_glSecondaryColor3ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3ub(red, green, blue);
+}
+
+void gl3_3compat_glSecondaryColor3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3sv(v);
+}
+
+void gl3_3compat_glSecondaryColor3s(void *_glfuncs, GLshort red, GLshort green, GLshort blue)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3s(red, green, blue);
+}
+
+void gl3_3compat_glSecondaryColor3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3iv(v);
+}
+
+void gl3_3compat_glSecondaryColor3i(void *_glfuncs, GLint red, GLint green, GLint blue)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3i(red, green, blue);
+}
+
+void gl3_3compat_glSecondaryColor3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3fv(v);
+}
+
+void gl3_3compat_glSecondaryColor3f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3f(red, green, blue);
+}
+
+void gl3_3compat_glSecondaryColor3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3dv(v);
+}
+
+void gl3_3compat_glSecondaryColor3d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3d(red, green, blue);
+}
+
+void gl3_3compat_glSecondaryColor3bv(void *_glfuncs, const GLbyte* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3bv(v);
+}
+
+void gl3_3compat_glSecondaryColor3b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3b(red, green, blue);
+}
+
+void gl3_3compat_glFogCoordPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glFogCoordPointer(gltype, stride, pointer);
+}
+
+void gl3_3compat_glFogCoorddv(void *_glfuncs, const GLdouble* coord)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glFogCoorddv(coord);
+}
+
+void gl3_3compat_glFogCoordd(void *_glfuncs, GLdouble coord)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glFogCoordd(coord);
+}
+
+void gl3_3compat_glFogCoordfv(void *_glfuncs, const GLfloat* coord)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glFogCoordfv(coord);
+}
+
+void gl3_3compat_glFogCoordf(void *_glfuncs, GLfloat coord)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glFogCoordf(coord);
+}
+
+void gl3_3compat_glVertexAttrib4usv(void *_glfuncs, GLuint index, const GLushort* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4usv(index, v);
+}
+
+void gl3_3compat_glVertexAttrib4uiv(void *_glfuncs, GLuint index, const GLuint* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4uiv(index, v);
+}
+
+void gl3_3compat_glVertexAttrib4ubv(void *_glfuncs, GLuint index, const GLubyte* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4ubv(index, v);
+}
+
+void gl3_3compat_glVertexAttrib4sv(void *_glfuncs, GLuint index, const GLshort* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4sv(index, v);
+}
+
+void gl3_3compat_glVertexAttrib4s(void *_glfuncs, GLuint index, GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4s(index, x, y, z, w);
+}
+
+void gl3_3compat_glVertexAttrib4iv(void *_glfuncs, GLuint index, const GLint* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4iv(index, v);
+}
+
+void gl3_3compat_glVertexAttrib4fv(void *_glfuncs, GLuint index, const GLfloat* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4fv(index, v);
+}
+
+void gl3_3compat_glVertexAttrib4f(void *_glfuncs, GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4f(index, x, y, z, w);
+}
+
+void gl3_3compat_glVertexAttrib4dv(void *_glfuncs, GLuint index, const GLdouble* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4dv(index, v);
+}
+
+void gl3_3compat_glVertexAttrib4d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4d(index, x, y, z, w);
+}
+
+void gl3_3compat_glVertexAttrib4bv(void *_glfuncs, GLuint index, const GLbyte* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4bv(index, v);
+}
+
+void gl3_3compat_glVertexAttrib4Nusv(void *_glfuncs, GLuint index, const GLushort* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Nusv(index, v);
+}
+
+void gl3_3compat_glVertexAttrib4Nuiv(void *_glfuncs, GLuint index, const GLuint* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Nuiv(index, v);
+}
+
+void gl3_3compat_glVertexAttrib4Nubv(void *_glfuncs, GLuint index, const GLubyte* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Nubv(index, v);
+}
+
+void gl3_3compat_glVertexAttrib4Nub(void *_glfuncs, GLuint index, GLubyte x, GLubyte y, GLubyte z, GLubyte w)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Nub(index, x, y, z, w);
+}
+
+void gl3_3compat_glVertexAttrib4Nsv(void *_glfuncs, GLuint index, const GLshort* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Nsv(index, v);
+}
+
+void gl3_3compat_glVertexAttrib4Niv(void *_glfuncs, GLuint index, const GLint* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Niv(index, v);
+}
+
+void gl3_3compat_glVertexAttrib4Nbv(void *_glfuncs, GLuint index, const GLbyte* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Nbv(index, v);
+}
+
+void gl3_3compat_glVertexAttrib3sv(void *_glfuncs, GLuint index, const GLshort* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib3sv(index, v);
+}
+
+void gl3_3compat_glVertexAttrib3s(void *_glfuncs, GLuint index, GLshort x, GLshort y, GLshort z)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib3s(index, x, y, z);
+}
+
+void gl3_3compat_glVertexAttrib3fv(void *_glfuncs, GLuint index, const GLfloat* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib3fv(index, v);
+}
+
+void gl3_3compat_glVertexAttrib3f(void *_glfuncs, GLuint index, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib3f(index, x, y, z);
+}
+
+void gl3_3compat_glVertexAttrib3dv(void *_glfuncs, GLuint index, const GLdouble* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib3dv(index, v);
+}
+
+void gl3_3compat_glVertexAttrib3d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib3d(index, x, y, z);
+}
+
+void gl3_3compat_glVertexAttrib2sv(void *_glfuncs, GLuint index, const GLshort* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib2sv(index, v);
+}
+
+void gl3_3compat_glVertexAttrib2s(void *_glfuncs, GLuint index, GLshort x, GLshort y)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib2s(index, x, y);
+}
+
+void gl3_3compat_glVertexAttrib2fv(void *_glfuncs, GLuint index, const GLfloat* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib2fv(index, v);
+}
+
+void gl3_3compat_glVertexAttrib2f(void *_glfuncs, GLuint index, GLfloat x, GLfloat y)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib2f(index, x, y);
+}
+
+void gl3_3compat_glVertexAttrib2dv(void *_glfuncs, GLuint index, const GLdouble* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib2dv(index, v);
+}
+
+void gl3_3compat_glVertexAttrib2d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib2d(index, x, y);
+}
+
+void gl3_3compat_glVertexAttrib1sv(void *_glfuncs, GLuint index, const GLshort* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib1sv(index, v);
+}
+
+void gl3_3compat_glVertexAttrib1s(void *_glfuncs, GLuint index, GLshort x)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib1s(index, x);
+}
+
+void gl3_3compat_glVertexAttrib1fv(void *_glfuncs, GLuint index, const GLfloat* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib1fv(index, v);
+}
+
+void gl3_3compat_glVertexAttrib1f(void *_glfuncs, GLuint index, GLfloat x)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib1f(index, x);
+}
+
+void gl3_3compat_glVertexAttrib1dv(void *_glfuncs, GLuint index, const GLdouble* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib1dv(index, v);
+}
+
+void gl3_3compat_glVertexAttrib1d(void *_glfuncs, GLuint index, GLdouble x)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib1d(index, x);
+}
+
+void gl3_3compat_glVertexAttribI4usv(void *_glfuncs, GLuint index, const GLushort* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI4usv(index, v);
+}
+
+void gl3_3compat_glVertexAttribI4ubv(void *_glfuncs, GLuint index, const GLubyte* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI4ubv(index, v);
+}
+
+void gl3_3compat_glVertexAttribI4sv(void *_glfuncs, GLuint index, const GLshort* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI4sv(index, v);
+}
+
+void gl3_3compat_glVertexAttribI4bv(void *_glfuncs, GLuint index, const GLbyte* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI4bv(index, v);
+}
+
+void gl3_3compat_glVertexAttribI4uiv(void *_glfuncs, GLuint index, const GLuint* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI4uiv(index, v);
+}
+
+void gl3_3compat_glVertexAttribI3uiv(void *_glfuncs, GLuint index, const GLuint* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI3uiv(index, v);
+}
+
+void gl3_3compat_glVertexAttribI2uiv(void *_glfuncs, GLuint index, const GLuint* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI2uiv(index, v);
+}
+
+void gl3_3compat_glVertexAttribI1uiv(void *_glfuncs, GLuint index, const GLuint* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI1uiv(index, v);
+}
+
+void gl3_3compat_glVertexAttribI4iv(void *_glfuncs, GLuint index, const GLint* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI4iv(index, v);
+}
+
+void gl3_3compat_glVertexAttribI3iv(void *_glfuncs, GLuint index, const GLint* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI3iv(index, v);
+}
+
+void gl3_3compat_glVertexAttribI2iv(void *_glfuncs, GLuint index, const GLint* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI2iv(index, v);
+}
+
+void gl3_3compat_glVertexAttribI1iv(void *_glfuncs, GLuint index, const GLint* v)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI1iv(index, v);
+}
+
+void gl3_3compat_glVertexAttribI4ui(void *_glfuncs, GLuint index, GLuint x, GLuint y, GLuint z, GLuint w)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI4ui(index, x, y, z, w);
+}
+
+void gl3_3compat_glVertexAttribI3ui(void *_glfuncs, GLuint index, GLuint x, GLuint y, GLuint z)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI3ui(index, x, y, z);
+}
+
+void gl3_3compat_glVertexAttribI2ui(void *_glfuncs, GLuint index, GLuint x, GLuint y)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI2ui(index, x, y);
+}
+
+void gl3_3compat_glVertexAttribI1ui(void *_glfuncs, GLuint index, GLuint x)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI1ui(index, x);
+}
+
+void gl3_3compat_glVertexAttribI4i(void *_glfuncs, GLuint index, GLint x, GLint y, GLint z, GLint w)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI4i(index, x, y, z, w);
+}
+
+void gl3_3compat_glVertexAttribI3i(void *_glfuncs, GLuint index, GLint x, GLint y, GLint z)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI3i(index, x, y, z);
+}
+
+void gl3_3compat_glVertexAttribI2i(void *_glfuncs, GLuint index, GLint x, GLint y)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI2i(index, x, y);
+}
+
+void gl3_3compat_glVertexAttribI1i(void *_glfuncs, GLuint index, GLint x)
+{
+ QOpenGLFunctions_3_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI1i(index, x);
+}
+
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/3.3compat/funcs.h b/Godeps/_workspace/src/github.com/obscuren/qml/gl/3.3compat/funcs.h
new file mode 100644
index 000000000..bd7747532
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/3.3compat/funcs.h
@@ -0,0 +1,787 @@
+
+// ** file automatically generated by glgen -- do not edit manually **
+
+#ifndef __cplusplus
+#include <inttypes.h>
+#include <stddef.h>
+typedef unsigned int GLenum;
+typedef unsigned char GLboolean;
+typedef unsigned int GLbitfield;
+typedef void GLvoid;
+typedef char GLchar;
+typedef signed char GLbyte; /* 1-byte signed */
+typedef short GLshort; /* 2-byte signed */
+typedef int GLint; /* 4-byte signed */
+typedef unsigned char GLubyte; /* 1-byte unsigned */
+typedef unsigned short GLushort; /* 2-byte unsigned */
+typedef unsigned int GLuint; /* 4-byte unsigned */
+typedef int GLsizei; /* 4-byte signed */
+typedef float GLfloat; /* single precision float */
+typedef float GLclampf; /* single precision float in [0,1] */
+typedef double GLdouble; /* double precision float */
+typedef double GLclampd; /* double precision float in [0,1] */
+typedef int64_t GLint64;
+typedef uint64_t GLuint64;
+typedef ptrdiff_t GLintptr;
+typedef ptrdiff_t GLsizeiptr;
+typedef ptrdiff_t GLintptrARB;
+typedef ptrdiff_t GLsizeiptrARB;
+typedef struct __GLsync *GLsync;
+#endif
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+void *gl3_3compat_funcs();
+
+void gl3_3compat_glViewport(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl3_3compat_glDepthRange(void *_glfuncs, GLdouble nearVal, GLdouble farVal);
+GLboolean gl3_3compat_glIsEnabled(void *_glfuncs, GLenum cap);
+void gl3_3compat_glGetTexLevelParameteriv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLint* params);
+void gl3_3compat_glGetTexLevelParameterfv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLfloat* params);
+void gl3_3compat_glGetTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl3_3compat_glGetTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl3_3compat_glGetTexImage(void *_glfuncs, GLenum target, GLint level, GLenum format, GLenum gltype, GLvoid* pixels);
+void gl3_3compat_glGetIntegerv(void *_glfuncs, GLenum pname, GLint* params);
+void gl3_3compat_glGetFloatv(void *_glfuncs, GLenum pname, GLfloat* params);
+GLenum gl3_3compat_glGetError(void *_glfuncs);
+void gl3_3compat_glGetDoublev(void *_glfuncs, GLenum pname, GLdouble* params);
+void gl3_3compat_glGetBooleanv(void *_glfuncs, GLenum pname, GLboolean* params);
+void gl3_3compat_glReadPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum gltype, GLvoid* pixels);
+void gl3_3compat_glReadBuffer(void *_glfuncs, GLenum mode);
+void gl3_3compat_glPixelStorei(void *_glfuncs, GLenum pname, GLint param);
+void gl3_3compat_glPixelStoref(void *_glfuncs, GLenum pname, GLfloat param);
+void gl3_3compat_glDepthFunc(void *_glfuncs, GLenum glfunc);
+void gl3_3compat_glStencilOp(void *_glfuncs, GLenum fail, GLenum zfail, GLenum zpass);
+void gl3_3compat_glStencilFunc(void *_glfuncs, GLenum glfunc, GLint ref, GLuint mask);
+void gl3_3compat_glLogicOp(void *_glfuncs, GLenum opcode);
+void gl3_3compat_glBlendFunc(void *_glfuncs, GLenum sfactor, GLenum dfactor);
+void gl3_3compat_glFlush(void *_glfuncs);
+void gl3_3compat_glFinish(void *_glfuncs);
+void gl3_3compat_glEnable(void *_glfuncs, GLenum cap);
+void gl3_3compat_glDisable(void *_glfuncs, GLenum cap);
+void gl3_3compat_glDepthMask(void *_glfuncs, GLboolean flag);
+void gl3_3compat_glColorMask(void *_glfuncs, GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha);
+void gl3_3compat_glStencilMask(void *_glfuncs, GLuint mask);
+void gl3_3compat_glClearDepth(void *_glfuncs, GLdouble depth);
+void gl3_3compat_glClearStencil(void *_glfuncs, GLint s);
+void gl3_3compat_glClearColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl3_3compat_glClear(void *_glfuncs, GLbitfield mask);
+void gl3_3compat_glDrawBuffer(void *_glfuncs, GLenum mode);
+void gl3_3compat_glTexImage2D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl3_3compat_glTexImage1D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl3_3compat_glTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl3_3compat_glTexParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint param);
+void gl3_3compat_glTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl3_3compat_glTexParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param);
+void gl3_3compat_glScissor(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl3_3compat_glPolygonMode(void *_glfuncs, GLenum face, GLenum mode);
+void gl3_3compat_glPointSize(void *_glfuncs, GLfloat size);
+void gl3_3compat_glLineWidth(void *_glfuncs, GLfloat width);
+void gl3_3compat_glHint(void *_glfuncs, GLenum target, GLenum mode);
+void gl3_3compat_glFrontFace(void *_glfuncs, GLenum mode);
+void gl3_3compat_glCullFace(void *_glfuncs, GLenum mode);
+void gl3_3compat_glIndexubv(void *_glfuncs, const GLubyte* c);
+void gl3_3compat_glIndexub(void *_glfuncs, GLubyte c);
+GLboolean gl3_3compat_glIsTexture(void *_glfuncs, GLuint texture);
+void gl3_3compat_glGenTextures(void *_glfuncs, GLsizei n, GLuint* textures);
+void gl3_3compat_glDeleteTextures(void *_glfuncs, GLsizei n, const GLuint* textures);
+void gl3_3compat_glBindTexture(void *_glfuncs, GLenum target, GLuint texture);
+void gl3_3compat_glTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl3_3compat_glTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl3_3compat_glCopyTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl3_3compat_glCopyTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width);
+void gl3_3compat_glCopyTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border);
+void gl3_3compat_glCopyTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLint border);
+void gl3_3compat_glPolygonOffset(void *_glfuncs, GLfloat factor, GLfloat units);
+void gl3_3compat_glDrawElements(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices);
+void gl3_3compat_glDrawArrays(void *_glfuncs, GLenum mode, GLint first, GLsizei count);
+void gl3_3compat_glCopyTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl3_3compat_glTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl3_3compat_glTexImage3D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl3_3compat_glDrawRangeElements(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices);
+void gl3_3compat_glBlendEquation(void *_glfuncs, GLenum mode);
+void gl3_3compat_glBlendColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl3_3compat_glGetCompressedTexImage(void *_glfuncs, GLenum target, GLint level, GLvoid* img);
+void gl3_3compat_glCompressedTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid* data);
+void gl3_3compat_glCompressedTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid* data);
+void gl3_3compat_glCompressedTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid* data);
+void gl3_3compat_glCompressedTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid* data);
+void gl3_3compat_glCompressedTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid* data);
+void gl3_3compat_glCompressedTexImage3D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid* data);
+void gl3_3compat_glSampleCoverage(void *_glfuncs, GLfloat value, GLboolean invert);
+void gl3_3compat_glActiveTexture(void *_glfuncs, GLenum texture);
+void gl3_3compat_glPointParameteriv(void *_glfuncs, GLenum pname, const GLint* params);
+void gl3_3compat_glPointParameteri(void *_glfuncs, GLenum pname, GLint param);
+void gl3_3compat_glPointParameterfv(void *_glfuncs, GLenum pname, const GLfloat* params);
+void gl3_3compat_glPointParameterf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl3_3compat_glMultiDrawArrays(void *_glfuncs, GLenum mode, const GLint* first, const GLsizei* count, GLsizei drawcount);
+void gl3_3compat_glBlendFuncSeparate(void *_glfuncs, GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha);
+void gl3_3compat_glGetBufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+GLboolean gl3_3compat_glUnmapBuffer(void *_glfuncs, GLenum target);
+void gl3_3compat_glGetBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, GLvoid* data);
+void gl3_3compat_glBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid* data);
+void gl3_3compat_glBufferData(void *_glfuncs, GLenum target, GLsizeiptr size, const GLvoid* data, GLenum usage);
+GLboolean gl3_3compat_glIsBuffer(void *_glfuncs, GLuint buffer);
+void gl3_3compat_glGenBuffers(void *_glfuncs, GLsizei n, GLuint* buffers);
+void gl3_3compat_glDeleteBuffers(void *_glfuncs, GLsizei n, const GLuint* buffers);
+void gl3_3compat_glBindBuffer(void *_glfuncs, GLenum target, GLuint buffer);
+void gl3_3compat_glGetQueryObjectuiv(void *_glfuncs, GLuint id, GLenum pname, GLuint* params);
+void gl3_3compat_glGetQueryObjectiv(void *_glfuncs, GLuint id, GLenum pname, GLint* params);
+void gl3_3compat_glGetQueryiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl3_3compat_glEndQuery(void *_glfuncs, GLenum target);
+void gl3_3compat_glBeginQuery(void *_glfuncs, GLenum target, GLuint id);
+GLboolean gl3_3compat_glIsQuery(void *_glfuncs, GLuint id);
+void gl3_3compat_glDeleteQueries(void *_glfuncs, GLsizei n, const GLuint* ids);
+void gl3_3compat_glGenQueries(void *_glfuncs, GLsizei n, GLuint* ids);
+void gl3_3compat_glVertexAttribPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLboolean normalized, GLsizei stride, const GLvoid* offset);
+void gl3_3compat_glValidateProgram(void *_glfuncs, GLuint program);
+void gl3_3compat_glUniformMatrix4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl3_3compat_glUniformMatrix3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl3_3compat_glUniformMatrix2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl3_3compat_glUniform4iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl3_3compat_glUniform3iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl3_3compat_glUniform2iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl3_3compat_glUniform1iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl3_3compat_glUniform4fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl3_3compat_glUniform3fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl3_3compat_glUniform2fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl3_3compat_glUniform1fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl3_3compat_glUniform4i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2, GLint v3);
+void gl3_3compat_glUniform3i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2);
+void gl3_3compat_glUniform2i(void *_glfuncs, GLint location, GLint v0, GLint v1);
+void gl3_3compat_glUniform1i(void *_glfuncs, GLint location, GLint v0);
+void gl3_3compat_glUniform4f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3);
+void gl3_3compat_glUniform3f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2);
+void gl3_3compat_glUniform2f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1);
+void gl3_3compat_glUniform1f(void *_glfuncs, GLint location, GLfloat v0);
+void gl3_3compat_glUseProgram(void *_glfuncs, GLuint program);
+void gl3_3compat_glShaderSource(void *_glfuncs, GLuint shader, GLsizei count, const GLchar** source, const GLint* length);
+void gl3_3compat_glLinkProgram(void *_glfuncs, GLuint program);
+GLboolean gl3_3compat_glIsShader(void *_glfuncs, GLuint shader);
+GLboolean gl3_3compat_glIsProgram(void *_glfuncs, GLuint program);
+void gl3_3compat_glGetVertexAttribiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params);
+void gl3_3compat_glGetVertexAttribfv(void *_glfuncs, GLuint index, GLenum pname, GLfloat* params);
+void gl3_3compat_glGetVertexAttribdv(void *_glfuncs, GLuint index, GLenum pname, GLdouble* params);
+void gl3_3compat_glGetUniformiv(void *_glfuncs, GLuint program, GLint location, GLint* params);
+void gl3_3compat_glGetUniformfv(void *_glfuncs, GLuint program, GLint location, GLfloat* params);
+GLint gl3_3compat_glGetUniformLocation(void *_glfuncs, GLuint program, const GLchar* name);
+void gl3_3compat_glGetShaderSource(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* source);
+void gl3_3compat_glGetShaderInfoLog(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* infoLog);
+void gl3_3compat_glGetShaderiv(void *_glfuncs, GLuint shader, GLenum pname, GLint* params);
+void gl3_3compat_glGetProgramInfoLog(void *_glfuncs, GLuint program, GLsizei bufSize, GLsizei* length, GLchar* infoLog);
+void gl3_3compat_glGetProgramiv(void *_glfuncs, GLuint program, GLenum pname, GLint* params);
+GLint gl3_3compat_glGetAttribLocation(void *_glfuncs, GLuint program, const GLchar* name);
+void gl3_3compat_glGetAttachedShaders(void *_glfuncs, GLuint program, GLsizei maxCount, GLsizei* count, GLuint* obj);
+void gl3_3compat_glGetActiveUniform(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name);
+void gl3_3compat_glGetActiveAttrib(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name);
+void gl3_3compat_glEnableVertexAttribArray(void *_glfuncs, GLuint index);
+void gl3_3compat_glDisableVertexAttribArray(void *_glfuncs, GLuint index);
+void gl3_3compat_glDetachShader(void *_glfuncs, GLuint program, GLuint shader);
+void gl3_3compat_glDeleteShader(void *_glfuncs, GLuint shader);
+void gl3_3compat_glDeleteProgram(void *_glfuncs, GLuint program);
+GLuint gl3_3compat_glCreateShader(void *_glfuncs, GLenum gltype);
+GLuint gl3_3compat_glCreateProgram(void *_glfuncs);
+void gl3_3compat_glCompileShader(void *_glfuncs, GLuint shader);
+void gl3_3compat_glBindAttribLocation(void *_glfuncs, GLuint program, GLuint index, const GLchar* name);
+void gl3_3compat_glAttachShader(void *_glfuncs, GLuint program, GLuint shader);
+void gl3_3compat_glStencilMaskSeparate(void *_glfuncs, GLenum face, GLuint mask);
+void gl3_3compat_glStencilFuncSeparate(void *_glfuncs, GLenum face, GLenum glfunc, GLint ref, GLuint mask);
+void gl3_3compat_glStencilOpSeparate(void *_glfuncs, GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass);
+void gl3_3compat_glDrawBuffers(void *_glfuncs, GLsizei n, const GLenum* bufs);
+void gl3_3compat_glBlendEquationSeparate(void *_glfuncs, GLenum modeRGB, GLenum modeAlpha);
+void gl3_3compat_glUniformMatrix4x3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl3_3compat_glUniformMatrix3x4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl3_3compat_glUniformMatrix4x2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl3_3compat_glUniformMatrix2x4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl3_3compat_glUniformMatrix3x2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl3_3compat_glUniformMatrix2x3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+GLboolean gl3_3compat_glIsVertexArray(void *_glfuncs, GLuint array);
+void gl3_3compat_glGenVertexArrays(void *_glfuncs, GLsizei n, GLuint* arrays);
+void gl3_3compat_glDeleteVertexArrays(void *_glfuncs, GLsizei n, const GLuint* arrays);
+void gl3_3compat_glBindVertexArray(void *_glfuncs, GLuint array);
+void gl3_3compat_glFlushMappedBufferRange(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr length);
+void gl3_3compat_glFramebufferTextureLayer(void *_glfuncs, GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer);
+void gl3_3compat_glRenderbufferStorageMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLenum internalFormat, GLsizei width, GLsizei height);
+void gl3_3compat_glBlitFramebuffer(void *_glfuncs, GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter);
+void gl3_3compat_glGenerateMipmap(void *_glfuncs, GLenum target);
+void gl3_3compat_glGetFramebufferAttachmentParameteriv(void *_glfuncs, GLenum target, GLenum attachment, GLenum pname, GLint* params);
+void gl3_3compat_glFramebufferRenderbuffer(void *_glfuncs, GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer);
+void gl3_3compat_glFramebufferTexture3D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset);
+void gl3_3compat_glFramebufferTexture2D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+void gl3_3compat_glFramebufferTexture1D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+GLenum gl3_3compat_glCheckFramebufferStatus(void *_glfuncs, GLenum target);
+void gl3_3compat_glGenFramebuffers(void *_glfuncs, GLsizei n, GLuint* framebuffers);
+void gl3_3compat_glDeleteFramebuffers(void *_glfuncs, GLsizei n, const GLuint* framebuffers);
+void gl3_3compat_glBindFramebuffer(void *_glfuncs, GLenum target, GLuint framebuffer);
+GLboolean gl3_3compat_glIsFramebuffer(void *_glfuncs, GLuint framebuffer);
+void gl3_3compat_glGetRenderbufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl3_3compat_glRenderbufferStorage(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height);
+void gl3_3compat_glGenRenderbuffers(void *_glfuncs, GLsizei n, GLuint* renderbuffers);
+void gl3_3compat_glDeleteRenderbuffers(void *_glfuncs, GLsizei n, const GLuint* renderbuffers);
+void gl3_3compat_glBindRenderbuffer(void *_glfuncs, GLenum target, GLuint renderbuffer);
+GLboolean gl3_3compat_glIsRenderbuffer(void *_glfuncs, GLuint renderbuffer);
+void gl3_3compat_glClearBufferfi(void *_glfuncs, GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil);
+void gl3_3compat_glClearBufferfv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLfloat* value);
+void gl3_3compat_glClearBufferuiv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLuint* value);
+void gl3_3compat_glClearBufferiv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLint* value);
+void gl3_3compat_glGetTexParameterIuiv(void *_glfuncs, GLenum target, GLenum pname, GLuint* params);
+void gl3_3compat_glGetTexParameterIiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl3_3compat_glTexParameterIuiv(void *_glfuncs, GLenum target, GLenum pname, const GLuint* params);
+void gl3_3compat_glTexParameterIiv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl3_3compat_glUniform4uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value);
+void gl3_3compat_glUniform3uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value);
+void gl3_3compat_glUniform2uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value);
+void gl3_3compat_glUniform1uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value);
+void gl3_3compat_glUniform4ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3);
+void gl3_3compat_glUniform3ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1, GLuint v2);
+void gl3_3compat_glUniform2ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1);
+void gl3_3compat_glUniform1ui(void *_glfuncs, GLint location, GLuint v0);
+GLint gl3_3compat_glGetFragDataLocation(void *_glfuncs, GLuint program, const GLchar* name);
+void gl3_3compat_glBindFragDataLocation(void *_glfuncs, GLuint program, GLuint color, const GLchar* name);
+void gl3_3compat_glGetUniformuiv(void *_glfuncs, GLuint program, GLint location, GLuint* params);
+void gl3_3compat_glGetVertexAttribIuiv(void *_glfuncs, GLuint index, GLenum pname, GLuint* params);
+void gl3_3compat_glGetVertexAttribIiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params);
+void gl3_3compat_glVertexAttribIPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl3_3compat_glEndConditionalRender(void *_glfuncs);
+void gl3_3compat_glBeginConditionalRender(void *_glfuncs, GLuint id, GLenum mode);
+void gl3_3compat_glClampColor(void *_glfuncs, GLenum target, GLenum clamp);
+void gl3_3compat_glGetTransformFeedbackVarying(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLsizei* size, GLenum* gltype, GLchar* name);
+void gl3_3compat_glBindBufferBase(void *_glfuncs, GLenum target, GLuint index, GLuint buffer);
+void gl3_3compat_glBindBufferRange(void *_glfuncs, GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size);
+void gl3_3compat_glEndTransformFeedback(void *_glfuncs);
+void gl3_3compat_glBeginTransformFeedback(void *_glfuncs, GLenum primitiveMode);
+GLboolean gl3_3compat_glIsEnabledi(void *_glfuncs, GLenum target, GLuint index);
+void gl3_3compat_glDisablei(void *_glfuncs, GLenum target, GLuint index);
+void gl3_3compat_glEnablei(void *_glfuncs, GLenum target, GLuint index);
+void gl3_3compat_glGetIntegeri_v(void *_glfuncs, GLenum target, GLuint index, GLint* data);
+void gl3_3compat_glGetBooleani_v(void *_glfuncs, GLenum target, GLuint index, GLboolean* data);
+void gl3_3compat_glColorMaski(void *_glfuncs, GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a);
+void gl3_3compat_glCopyBufferSubData(void *_glfuncs, GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size);
+void gl3_3compat_glUniformBlockBinding(void *_glfuncs, GLuint program, GLuint v0, GLuint v1);
+void gl3_3compat_glGetActiveUniformBlockName(void *_glfuncs, GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei* length, GLchar* uniformBlockName);
+void gl3_3compat_glGetActiveUniformBlockiv(void *_glfuncs, GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint* params);
+GLuint gl3_3compat_glGetUniformBlockIndex(void *_glfuncs, GLuint program, const GLchar* uniformBlockName);
+void gl3_3compat_glGetActiveUniformName(void *_glfuncs, GLuint program, GLuint uniformIndex, GLsizei bufSize, GLsizei* length, GLchar* uniformName);
+void gl3_3compat_glGetActiveUniformsiv(void *_glfuncs, GLuint program, GLsizei uniformCount, const GLuint* uniformIndices, GLenum pname, GLint* params);
+void gl3_3compat_glPrimitiveRestartIndex(void *_glfuncs, GLuint index);
+void gl3_3compat_glTexBuffer(void *_glfuncs, GLenum target, GLenum internalFormat, GLuint buffer);
+void gl3_3compat_glDrawElementsInstanced(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount);
+void gl3_3compat_glDrawArraysInstanced(void *_glfuncs, GLenum mode, GLint first, GLsizei count, GLsizei instancecount);
+void gl3_3compat_glSampleMaski(void *_glfuncs, GLuint index, GLbitfield mask);
+void gl3_3compat_glGetMultisamplefv(void *_glfuncs, GLenum pname, GLuint index, GLfloat* val);
+void gl3_3compat_glTexImage3DMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations);
+void gl3_3compat_glTexImage2DMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLint internalFormat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations);
+void gl3_3compat_glGetSynciv(void *_glfuncs, GLsync sync, GLenum pname, GLsizei bufSize, GLsizei* length, GLint* values);
+void gl3_3compat_glGetInteger64v(void *_glfuncs, GLenum pname, GLint64* params);
+void gl3_3compat_glWaitSync(void *_glfuncs, GLsync sync, GLbitfield flags, GLuint64 timeout);
+GLenum gl3_3compat_glClientWaitSync(void *_glfuncs, GLsync sync, GLbitfield flags, GLuint64 timeout);
+void gl3_3compat_glDeleteSync(void *_glfuncs, GLsync sync);
+GLboolean gl3_3compat_glIsSync(void *_glfuncs, GLsync sync);
+GLsync gl3_3compat_glFenceSync(void *_glfuncs, GLenum condition, GLbitfield flags);
+void gl3_3compat_glProvokingVertex(void *_glfuncs, GLenum mode);
+void gl3_3compat_glDrawElementsInstancedBaseVertex(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount, GLint basevertex);
+void gl3_3compat_glDrawRangeElementsBaseVertex(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices, GLint basevertex);
+void gl3_3compat_glDrawElementsBaseVertex(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLint basevertex);
+void gl3_3compat_glFramebufferTexture(void *_glfuncs, GLenum target, GLenum attachment, GLuint texture, GLint level);
+void gl3_3compat_glGetBufferParameteri64v(void *_glfuncs, GLenum target, GLenum pname, GLint64* params);
+void gl3_3compat_glGetInteger64i_v(void *_glfuncs, GLenum target, GLuint index, GLint64* data);
+void gl3_3compat_glVertexAttribP4uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value);
+void gl3_3compat_glVertexAttribP4ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value);
+void gl3_3compat_glVertexAttribP3uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value);
+void gl3_3compat_glVertexAttribP3ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value);
+void gl3_3compat_glVertexAttribP2uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value);
+void gl3_3compat_glVertexAttribP2ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value);
+void gl3_3compat_glVertexAttribP1uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value);
+void gl3_3compat_glVertexAttribP1ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value);
+void gl3_3compat_glSecondaryColorP3uiv(void *_glfuncs, GLenum gltype, const GLuint* color);
+void gl3_3compat_glSecondaryColorP3ui(void *_glfuncs, GLenum gltype, GLuint color);
+void gl3_3compat_glColorP4uiv(void *_glfuncs, GLenum gltype, const GLuint* color);
+void gl3_3compat_glColorP4ui(void *_glfuncs, GLenum gltype, GLuint color);
+void gl3_3compat_glColorP3uiv(void *_glfuncs, GLenum gltype, const GLuint* color);
+void gl3_3compat_glColorP3ui(void *_glfuncs, GLenum gltype, GLuint color);
+void gl3_3compat_glNormalP3uiv(void *_glfuncs, GLenum gltype, const GLuint* coords);
+void gl3_3compat_glNormalP3ui(void *_glfuncs, GLenum gltype, GLuint coords);
+void gl3_3compat_glMultiTexCoordP4uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords);
+void gl3_3compat_glMultiTexCoordP4ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords);
+void gl3_3compat_glMultiTexCoordP3uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords);
+void gl3_3compat_glMultiTexCoordP3ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords);
+void gl3_3compat_glMultiTexCoordP2uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords);
+void gl3_3compat_glMultiTexCoordP2ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords);
+void gl3_3compat_glMultiTexCoordP1uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords);
+void gl3_3compat_glMultiTexCoordP1ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords);
+void gl3_3compat_glTexCoordP4uiv(void *_glfuncs, GLenum gltype, const GLuint* coords);
+void gl3_3compat_glTexCoordP4ui(void *_glfuncs, GLenum gltype, GLuint coords);
+void gl3_3compat_glTexCoordP3uiv(void *_glfuncs, GLenum gltype, const GLuint* coords);
+void gl3_3compat_glTexCoordP3ui(void *_glfuncs, GLenum gltype, GLuint coords);
+void gl3_3compat_glTexCoordP2uiv(void *_glfuncs, GLenum gltype, const GLuint* coords);
+void gl3_3compat_glTexCoordP2ui(void *_glfuncs, GLenum gltype, GLuint coords);
+void gl3_3compat_glTexCoordP1uiv(void *_glfuncs, GLenum gltype, const GLuint* coords);
+void gl3_3compat_glTexCoordP1ui(void *_glfuncs, GLenum gltype, GLuint coords);
+void gl3_3compat_glVertexP4uiv(void *_glfuncs, GLenum gltype, const GLuint* value);
+void gl3_3compat_glVertexP4ui(void *_glfuncs, GLenum gltype, GLuint value);
+void gl3_3compat_glVertexP3uiv(void *_glfuncs, GLenum gltype, const GLuint* value);
+void gl3_3compat_glVertexP3ui(void *_glfuncs, GLenum gltype, GLuint value);
+void gl3_3compat_glVertexP2uiv(void *_glfuncs, GLenum gltype, const GLuint* value);
+void gl3_3compat_glVertexP2ui(void *_glfuncs, GLenum gltype, GLuint value);
+void gl3_3compat_glGetQueryObjectui64v(void *_glfuncs, GLuint id, GLenum pname, GLuint64* params);
+void gl3_3compat_glGetQueryObjecti64v(void *_glfuncs, GLuint id, GLenum pname, GLint64* params);
+void gl3_3compat_glQueryCounter(void *_glfuncs, GLuint id, GLenum target);
+void gl3_3compat_glGetSamplerParameterIuiv(void *_glfuncs, GLuint sampler, GLenum pname, GLuint* params);
+void gl3_3compat_glGetSamplerParameterfv(void *_glfuncs, GLuint sampler, GLenum pname, GLfloat* params);
+void gl3_3compat_glGetSamplerParameterIiv(void *_glfuncs, GLuint sampler, GLenum pname, GLint* params);
+void gl3_3compat_glGetSamplerParameteriv(void *_glfuncs, GLuint sampler, GLenum pname, GLint* params);
+void gl3_3compat_glSamplerParameterIuiv(void *_glfuncs, GLuint sampler, GLenum pname, const GLuint* param);
+void gl3_3compat_glSamplerParameterIiv(void *_glfuncs, GLuint sampler, GLenum pname, const GLint* param);
+void gl3_3compat_glSamplerParameterfv(void *_glfuncs, GLuint sampler, GLenum pname, const GLfloat* param);
+void gl3_3compat_glSamplerParameterf(void *_glfuncs, GLuint sampler, GLenum pname, GLfloat param);
+void gl3_3compat_glSamplerParameteriv(void *_glfuncs, GLuint sampler, GLenum pname, const GLint* param);
+void gl3_3compat_glSamplerParameteri(void *_glfuncs, GLuint sampler, GLenum pname, GLint param);
+void gl3_3compat_glBindSampler(void *_glfuncs, GLuint unit, GLuint sampler);
+GLboolean gl3_3compat_glIsSampler(void *_glfuncs, GLuint sampler);
+void gl3_3compat_glDeleteSamplers(void *_glfuncs, GLsizei count, const GLuint* samplers);
+void gl3_3compat_glGenSamplers(void *_glfuncs, GLsizei count, GLuint* samplers);
+GLint gl3_3compat_glGetFragDataIndex(void *_glfuncs, GLuint program, const GLchar* name);
+void gl3_3compat_glBindFragDataLocationIndexed(void *_glfuncs, GLuint program, GLuint colorNumber, GLuint index, const GLchar* name);
+void gl3_3compat_glVertexAttribDivisor(void *_glfuncs, GLuint index, GLuint divisor);
+void gl3_3compat_glTranslatef(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl3_3compat_glTranslated(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl3_3compat_glScalef(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl3_3compat_glScaled(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl3_3compat_glRotatef(void *_glfuncs, GLfloat angle, GLfloat x, GLfloat y, GLfloat z);
+void gl3_3compat_glRotated(void *_glfuncs, GLdouble angle, GLdouble x, GLdouble y, GLdouble z);
+void gl3_3compat_glPushMatrix(void *_glfuncs);
+void gl3_3compat_glPopMatrix(void *_glfuncs);
+void gl3_3compat_glOrtho(void *_glfuncs, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+void gl3_3compat_glMultMatrixd(void *_glfuncs, const GLdouble* m);
+void gl3_3compat_glMultMatrixf(void *_glfuncs, const GLfloat* m);
+void gl3_3compat_glMatrixMode(void *_glfuncs, GLenum mode);
+void gl3_3compat_glLoadMatrixd(void *_glfuncs, const GLdouble* m);
+void gl3_3compat_glLoadMatrixf(void *_glfuncs, const GLfloat* m);
+void gl3_3compat_glLoadIdentity(void *_glfuncs);
+void gl3_3compat_glFrustum(void *_glfuncs, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+GLboolean gl3_3compat_glIsList(void *_glfuncs, GLuint list);
+void gl3_3compat_glGetTexGeniv(void *_glfuncs, GLenum coord, GLenum pname, GLint* params);
+void gl3_3compat_glGetTexGenfv(void *_glfuncs, GLenum coord, GLenum pname, GLfloat* params);
+void gl3_3compat_glGetTexGendv(void *_glfuncs, GLenum coord, GLenum pname, GLdouble* params);
+void gl3_3compat_glGetTexEnviv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl3_3compat_glGetTexEnvfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl3_3compat_glGetPolygonStipple(void *_glfuncs, GLubyte* mask);
+void gl3_3compat_glGetPixelMapusv(void *_glfuncs, GLenum glmap, GLushort* values);
+void gl3_3compat_glGetPixelMapuiv(void *_glfuncs, GLenum glmap, GLuint* values);
+void gl3_3compat_glGetPixelMapfv(void *_glfuncs, GLenum glmap, GLfloat* values);
+void gl3_3compat_glGetMaterialiv(void *_glfuncs, GLenum face, GLenum pname, GLint* params);
+void gl3_3compat_glGetMaterialfv(void *_glfuncs, GLenum face, GLenum pname, GLfloat* params);
+void gl3_3compat_glGetMapiv(void *_glfuncs, GLenum target, GLenum query, GLint* v);
+void gl3_3compat_glGetMapfv(void *_glfuncs, GLenum target, GLenum query, GLfloat* v);
+void gl3_3compat_glGetMapdv(void *_glfuncs, GLenum target, GLenum query, GLdouble* v);
+void gl3_3compat_glGetLightiv(void *_glfuncs, GLenum light, GLenum pname, GLint* params);
+void gl3_3compat_glGetLightfv(void *_glfuncs, GLenum light, GLenum pname, GLfloat* params);
+void gl3_3compat_glGetClipPlane(void *_glfuncs, GLenum plane, GLdouble* equation);
+void gl3_3compat_glDrawPixels(void *_glfuncs, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl3_3compat_glCopyPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum gltype);
+void gl3_3compat_glPixelMapusv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLushort* values);
+void gl3_3compat_glPixelMapuiv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLuint* values);
+void gl3_3compat_glPixelMapfv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLfloat* values);
+void gl3_3compat_glPixelTransferi(void *_glfuncs, GLenum pname, GLint param);
+void gl3_3compat_glPixelTransferf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl3_3compat_glPixelZoom(void *_glfuncs, GLfloat xfactor, GLfloat yfactor);
+void gl3_3compat_glAlphaFunc(void *_glfuncs, GLenum glfunc, GLfloat ref);
+void gl3_3compat_glEvalPoint2(void *_glfuncs, GLint i, GLint j);
+void gl3_3compat_glEvalMesh2(void *_glfuncs, GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2);
+void gl3_3compat_glEvalPoint1(void *_glfuncs, GLint i);
+void gl3_3compat_glEvalMesh1(void *_glfuncs, GLenum mode, GLint i1, GLint i2);
+void gl3_3compat_glEvalCoord2fv(void *_glfuncs, const GLfloat* u);
+void gl3_3compat_glEvalCoord2f(void *_glfuncs, GLfloat u, GLfloat v);
+void gl3_3compat_glEvalCoord2dv(void *_glfuncs, const GLdouble* u);
+void gl3_3compat_glEvalCoord2d(void *_glfuncs, GLdouble u, GLdouble v);
+void gl3_3compat_glEvalCoord1fv(void *_glfuncs, const GLfloat* u);
+void gl3_3compat_glEvalCoord1f(void *_glfuncs, GLfloat u);
+void gl3_3compat_glEvalCoord1dv(void *_glfuncs, const GLdouble* u);
+void gl3_3compat_glEvalCoord1d(void *_glfuncs, GLdouble u);
+void gl3_3compat_glMapGrid2f(void *_glfuncs, GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2);
+void gl3_3compat_glMapGrid2d(void *_glfuncs, GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2);
+void gl3_3compat_glMapGrid1f(void *_glfuncs, GLint un, GLfloat u1, GLfloat u2);
+void gl3_3compat_glMapGrid1d(void *_glfuncs, GLint un, GLdouble u1, GLdouble u2);
+void gl3_3compat_glMap2f(void *_glfuncs, GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat* points);
+void gl3_3compat_glMap2d(void *_glfuncs, GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble* points);
+void gl3_3compat_glMap1f(void *_glfuncs, GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat* points);
+void gl3_3compat_glMap1d(void *_glfuncs, GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble* points);
+void gl3_3compat_glPushAttrib(void *_glfuncs, GLbitfield mask);
+void gl3_3compat_glPopAttrib(void *_glfuncs);
+void gl3_3compat_glAccum(void *_glfuncs, GLenum op, GLfloat value);
+void gl3_3compat_glIndexMask(void *_glfuncs, GLuint mask);
+void gl3_3compat_glClearIndex(void *_glfuncs, GLfloat c);
+void gl3_3compat_glClearAccum(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl3_3compat_glPushName(void *_glfuncs, GLuint name);
+void gl3_3compat_glPopName(void *_glfuncs);
+void gl3_3compat_glPassThrough(void *_glfuncs, GLfloat token);
+void gl3_3compat_glLoadName(void *_glfuncs, GLuint name);
+void gl3_3compat_glInitNames(void *_glfuncs);
+GLint gl3_3compat_glRenderMode(void *_glfuncs, GLenum mode);
+void gl3_3compat_glSelectBuffer(void *_glfuncs, GLsizei size, GLuint* buffer);
+void gl3_3compat_glFeedbackBuffer(void *_glfuncs, GLsizei size, GLenum gltype, GLfloat* buffer);
+void gl3_3compat_glTexGeniv(void *_glfuncs, GLenum coord, GLenum pname, const GLint* params);
+void gl3_3compat_glTexGeni(void *_glfuncs, GLenum coord, GLenum pname, GLint param);
+void gl3_3compat_glTexGenfv(void *_glfuncs, GLenum coord, GLenum pname, const GLfloat* params);
+void gl3_3compat_glTexGenf(void *_glfuncs, GLenum coord, GLenum pname, GLfloat param);
+void gl3_3compat_glTexGendv(void *_glfuncs, GLenum coord, GLenum pname, const GLdouble* params);
+void gl3_3compat_glTexGend(void *_glfuncs, GLenum coord, GLenum pname, GLdouble param);
+void gl3_3compat_glTexEnviv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl3_3compat_glTexEnvi(void *_glfuncs, GLenum target, GLenum pname, GLint param);
+void gl3_3compat_glTexEnvfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl3_3compat_glTexEnvf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param);
+void gl3_3compat_glShadeModel(void *_glfuncs, GLenum mode);
+void gl3_3compat_glPolygonStipple(void *_glfuncs, const GLubyte* mask);
+void gl3_3compat_glMaterialiv(void *_glfuncs, GLenum face, GLenum pname, const GLint* params);
+void gl3_3compat_glMateriali(void *_glfuncs, GLenum face, GLenum pname, GLint param);
+void gl3_3compat_glMaterialfv(void *_glfuncs, GLenum face, GLenum pname, const GLfloat* params);
+void gl3_3compat_glMaterialf(void *_glfuncs, GLenum face, GLenum pname, GLfloat param);
+void gl3_3compat_glLineStipple(void *_glfuncs, GLint factor, GLushort pattern);
+void gl3_3compat_glLightModeliv(void *_glfuncs, GLenum pname, const GLint* params);
+void gl3_3compat_glLightModeli(void *_glfuncs, GLenum pname, GLint param);
+void gl3_3compat_glLightModelfv(void *_glfuncs, GLenum pname, const GLfloat* params);
+void gl3_3compat_glLightModelf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl3_3compat_glLightiv(void *_glfuncs, GLenum light, GLenum pname, const GLint* params);
+void gl3_3compat_glLighti(void *_glfuncs, GLenum light, GLenum pname, GLint param);
+void gl3_3compat_glLightfv(void *_glfuncs, GLenum light, GLenum pname, const GLfloat* params);
+void gl3_3compat_glLightf(void *_glfuncs, GLenum light, GLenum pname, GLfloat param);
+void gl3_3compat_glFogiv(void *_glfuncs, GLenum pname, const GLint* params);
+void gl3_3compat_glFogi(void *_glfuncs, GLenum pname, GLint param);
+void gl3_3compat_glFogfv(void *_glfuncs, GLenum pname, const GLfloat* params);
+void gl3_3compat_glFogf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl3_3compat_glColorMaterial(void *_glfuncs, GLenum face, GLenum mode);
+void gl3_3compat_glClipPlane(void *_glfuncs, GLenum plane, const GLdouble* equation);
+void gl3_3compat_glVertex4sv(void *_glfuncs, const GLshort* v);
+void gl3_3compat_glVertex4s(void *_glfuncs, GLshort x, GLshort y, GLshort z, GLshort w);
+void gl3_3compat_glVertex4iv(void *_glfuncs, const GLint* v);
+void gl3_3compat_glVertex4i(void *_glfuncs, GLint x, GLint y, GLint z, GLint w);
+void gl3_3compat_glVertex4fv(void *_glfuncs, const GLfloat* v);
+void gl3_3compat_glVertex4f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+void gl3_3compat_glVertex4dv(void *_glfuncs, const GLdouble* v);
+void gl3_3compat_glVertex4d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+void gl3_3compat_glVertex3sv(void *_glfuncs, const GLshort* v);
+void gl3_3compat_glVertex3s(void *_glfuncs, GLshort x, GLshort y, GLshort z);
+void gl3_3compat_glVertex3iv(void *_glfuncs, const GLint* v);
+void gl3_3compat_glVertex3i(void *_glfuncs, GLint x, GLint y, GLint z);
+void gl3_3compat_glVertex3fv(void *_glfuncs, const GLfloat* v);
+void gl3_3compat_glVertex3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl3_3compat_glVertex3dv(void *_glfuncs, const GLdouble* v);
+void gl3_3compat_glVertex3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl3_3compat_glVertex2sv(void *_glfuncs, const GLshort* v);
+void gl3_3compat_glVertex2s(void *_glfuncs, GLshort x, GLshort y);
+void gl3_3compat_glVertex2iv(void *_glfuncs, const GLint* v);
+void gl3_3compat_glVertex2i(void *_glfuncs, GLint x, GLint y);
+void gl3_3compat_glVertex2fv(void *_glfuncs, const GLfloat* v);
+void gl3_3compat_glVertex2f(void *_glfuncs, GLfloat x, GLfloat y);
+void gl3_3compat_glVertex2dv(void *_glfuncs, const GLdouble* v);
+void gl3_3compat_glVertex2d(void *_glfuncs, GLdouble x, GLdouble y);
+void gl3_3compat_glTexCoord4sv(void *_glfuncs, const GLshort* v);
+void gl3_3compat_glTexCoord4s(void *_glfuncs, GLshort s, GLshort t, GLshort r, GLshort q);
+void gl3_3compat_glTexCoord4iv(void *_glfuncs, const GLint* v);
+void gl3_3compat_glTexCoord4i(void *_glfuncs, GLint s, GLint t, GLint r, GLint q);
+void gl3_3compat_glTexCoord4fv(void *_glfuncs, const GLfloat* v);
+void gl3_3compat_glTexCoord4f(void *_glfuncs, GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+void gl3_3compat_glTexCoord4dv(void *_glfuncs, const GLdouble* v);
+void gl3_3compat_glTexCoord4d(void *_glfuncs, GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+void gl3_3compat_glTexCoord3sv(void *_glfuncs, const GLshort* v);
+void gl3_3compat_glTexCoord3s(void *_glfuncs, GLshort s, GLshort t, GLshort r);
+void gl3_3compat_glTexCoord3iv(void *_glfuncs, const GLint* v);
+void gl3_3compat_glTexCoord3i(void *_glfuncs, GLint s, GLint t, GLint r);
+void gl3_3compat_glTexCoord3fv(void *_glfuncs, const GLfloat* v);
+void gl3_3compat_glTexCoord3f(void *_glfuncs, GLfloat s, GLfloat t, GLfloat r);
+void gl3_3compat_glTexCoord3dv(void *_glfuncs, const GLdouble* v);
+void gl3_3compat_glTexCoord3d(void *_glfuncs, GLdouble s, GLdouble t, GLdouble r);
+void gl3_3compat_glTexCoord2sv(void *_glfuncs, const GLshort* v);
+void gl3_3compat_glTexCoord2s(void *_glfuncs, GLshort s, GLshort t);
+void gl3_3compat_glTexCoord2iv(void *_glfuncs, const GLint* v);
+void gl3_3compat_glTexCoord2i(void *_glfuncs, GLint s, GLint t);
+void gl3_3compat_glTexCoord2fv(void *_glfuncs, const GLfloat* v);
+void gl3_3compat_glTexCoord2f(void *_glfuncs, GLfloat s, GLfloat t);
+void gl3_3compat_glTexCoord2dv(void *_glfuncs, const GLdouble* v);
+void gl3_3compat_glTexCoord2d(void *_glfuncs, GLdouble s, GLdouble t);
+void gl3_3compat_glTexCoord1sv(void *_glfuncs, const GLshort* v);
+void gl3_3compat_glTexCoord1s(void *_glfuncs, GLshort s);
+void gl3_3compat_glTexCoord1iv(void *_glfuncs, const GLint* v);
+void gl3_3compat_glTexCoord1i(void *_glfuncs, GLint s);
+void gl3_3compat_glTexCoord1fv(void *_glfuncs, const GLfloat* v);
+void gl3_3compat_glTexCoord1f(void *_glfuncs, GLfloat s);
+void gl3_3compat_glTexCoord1dv(void *_glfuncs, const GLdouble* v);
+void gl3_3compat_glTexCoord1d(void *_glfuncs, GLdouble s);
+void gl3_3compat_glRectsv(void *_glfuncs, const GLshort* v1, const GLshort* v2);
+void gl3_3compat_glRects(void *_glfuncs, GLshort x1, GLshort y1, GLshort x2, GLshort y2);
+void gl3_3compat_glRectiv(void *_glfuncs, const GLint* v1, const GLint* v2);
+void gl3_3compat_glRecti(void *_glfuncs, GLint x1, GLint y1, GLint x2, GLint y2);
+void gl3_3compat_glRectfv(void *_glfuncs, const GLfloat* v1, const GLfloat* v2);
+void gl3_3compat_glRectf(void *_glfuncs, GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2);
+void gl3_3compat_glRectdv(void *_glfuncs, const GLdouble* v1, const GLdouble* v2);
+void gl3_3compat_glRectd(void *_glfuncs, GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2);
+void gl3_3compat_glRasterPos4sv(void *_glfuncs, const GLshort* v);
+void gl3_3compat_glRasterPos4s(void *_glfuncs, GLshort x, GLshort y, GLshort z, GLshort w);
+void gl3_3compat_glRasterPos4iv(void *_glfuncs, const GLint* v);
+void gl3_3compat_glRasterPos4i(void *_glfuncs, GLint x, GLint y, GLint z, GLint w);
+void gl3_3compat_glRasterPos4fv(void *_glfuncs, const GLfloat* v);
+void gl3_3compat_glRasterPos4f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+void gl3_3compat_glRasterPos4dv(void *_glfuncs, const GLdouble* v);
+void gl3_3compat_glRasterPos4d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+void gl3_3compat_glRasterPos3sv(void *_glfuncs, const GLshort* v);
+void gl3_3compat_glRasterPos3s(void *_glfuncs, GLshort x, GLshort y, GLshort z);
+void gl3_3compat_glRasterPos3iv(void *_glfuncs, const GLint* v);
+void gl3_3compat_glRasterPos3i(void *_glfuncs, GLint x, GLint y, GLint z);
+void gl3_3compat_glRasterPos3fv(void *_glfuncs, const GLfloat* v);
+void gl3_3compat_glRasterPos3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl3_3compat_glRasterPos3dv(void *_glfuncs, const GLdouble* v);
+void gl3_3compat_glRasterPos3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl3_3compat_glRasterPos2sv(void *_glfuncs, const GLshort* v);
+void gl3_3compat_glRasterPos2s(void *_glfuncs, GLshort x, GLshort y);
+void gl3_3compat_glRasterPos2iv(void *_glfuncs, const GLint* v);
+void gl3_3compat_glRasterPos2i(void *_glfuncs, GLint x, GLint y);
+void gl3_3compat_glRasterPos2fv(void *_glfuncs, const GLfloat* v);
+void gl3_3compat_glRasterPos2f(void *_glfuncs, GLfloat x, GLfloat y);
+void gl3_3compat_glRasterPos2dv(void *_glfuncs, const GLdouble* v);
+void gl3_3compat_glRasterPos2d(void *_glfuncs, GLdouble x, GLdouble y);
+void gl3_3compat_glNormal3sv(void *_glfuncs, const GLshort* v);
+void gl3_3compat_glNormal3s(void *_glfuncs, GLshort nx, GLshort ny, GLshort nz);
+void gl3_3compat_glNormal3iv(void *_glfuncs, const GLint* v);
+void gl3_3compat_glNormal3i(void *_glfuncs, GLint nx, GLint ny, GLint nz);
+void gl3_3compat_glNormal3fv(void *_glfuncs, const GLfloat* v);
+void gl3_3compat_glNormal3f(void *_glfuncs, GLfloat nx, GLfloat ny, GLfloat nz);
+void gl3_3compat_glNormal3dv(void *_glfuncs, const GLdouble* v);
+void gl3_3compat_glNormal3d(void *_glfuncs, GLdouble nx, GLdouble ny, GLdouble nz);
+void gl3_3compat_glNormal3bv(void *_glfuncs, const GLbyte* v);
+void gl3_3compat_glNormal3b(void *_glfuncs, GLbyte nx, GLbyte ny, GLbyte nz);
+void gl3_3compat_glIndexsv(void *_glfuncs, const GLshort* c);
+void gl3_3compat_glIndexs(void *_glfuncs, GLshort c);
+void gl3_3compat_glIndexiv(void *_glfuncs, const GLint* c);
+void gl3_3compat_glIndexi(void *_glfuncs, GLint c);
+void gl3_3compat_glIndexfv(void *_glfuncs, const GLfloat* c);
+void gl3_3compat_glIndexf(void *_glfuncs, GLfloat c);
+void gl3_3compat_glIndexdv(void *_glfuncs, const GLdouble* c);
+void gl3_3compat_glIndexd(void *_glfuncs, GLdouble c);
+void gl3_3compat_glEnd(void *_glfuncs);
+void gl3_3compat_glEdgeFlagv(void *_glfuncs, const GLboolean* flag);
+void gl3_3compat_glEdgeFlag(void *_glfuncs, GLboolean flag);
+void gl3_3compat_glColor4usv(void *_glfuncs, const GLushort* v);
+void gl3_3compat_glColor4us(void *_glfuncs, GLushort red, GLushort green, GLushort blue, GLushort alpha);
+void gl3_3compat_glColor4uiv(void *_glfuncs, const GLuint* v);
+void gl3_3compat_glColor4ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue, GLuint alpha);
+void gl3_3compat_glColor4ubv(void *_glfuncs, const GLubyte* v);
+void gl3_3compat_glColor4ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha);
+void gl3_3compat_glColor4sv(void *_glfuncs, const GLshort* v);
+void gl3_3compat_glColor4s(void *_glfuncs, GLshort red, GLshort green, GLshort blue, GLshort alpha);
+void gl3_3compat_glColor4iv(void *_glfuncs, const GLint* v);
+void gl3_3compat_glColor4i(void *_glfuncs, GLint red, GLint green, GLint blue, GLint alpha);
+void gl3_3compat_glColor4fv(void *_glfuncs, const GLfloat* v);
+void gl3_3compat_glColor4f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl3_3compat_glColor4dv(void *_glfuncs, const GLdouble* v);
+void gl3_3compat_glColor4d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha);
+void gl3_3compat_glColor4bv(void *_glfuncs, const GLbyte* v);
+void gl3_3compat_glColor4b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha);
+void gl3_3compat_glColor3usv(void *_glfuncs, const GLushort* v);
+void gl3_3compat_glColor3us(void *_glfuncs, GLushort red, GLushort green, GLushort blue);
+void gl3_3compat_glColor3uiv(void *_glfuncs, const GLuint* v);
+void gl3_3compat_glColor3ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue);
+void gl3_3compat_glColor3ubv(void *_glfuncs, const GLubyte* v);
+void gl3_3compat_glColor3ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue);
+void gl3_3compat_glColor3sv(void *_glfuncs, const GLshort* v);
+void gl3_3compat_glColor3s(void *_glfuncs, GLshort red, GLshort green, GLshort blue);
+void gl3_3compat_glColor3iv(void *_glfuncs, const GLint* v);
+void gl3_3compat_glColor3i(void *_glfuncs, GLint red, GLint green, GLint blue);
+void gl3_3compat_glColor3fv(void *_glfuncs, const GLfloat* v);
+void gl3_3compat_glColor3f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue);
+void gl3_3compat_glColor3dv(void *_glfuncs, const GLdouble* v);
+void gl3_3compat_glColor3d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue);
+void gl3_3compat_glColor3bv(void *_glfuncs, const GLbyte* v);
+void gl3_3compat_glColor3b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue);
+void gl3_3compat_glBitmap(void *_glfuncs, GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte* bitmap);
+void gl3_3compat_glBegin(void *_glfuncs, GLenum mode);
+void gl3_3compat_glListBase(void *_glfuncs, GLuint base);
+GLuint gl3_3compat_glGenLists(void *_glfuncs, GLsizei range_);
+void gl3_3compat_glDeleteLists(void *_glfuncs, GLuint list, GLsizei range_);
+void gl3_3compat_glCallLists(void *_glfuncs, GLsizei n, GLenum gltype, const GLvoid* lists);
+void gl3_3compat_glCallList(void *_glfuncs, GLuint list);
+void gl3_3compat_glEndList(void *_glfuncs);
+void gl3_3compat_glNewList(void *_glfuncs, GLuint list, GLenum mode);
+void gl3_3compat_glPushClientAttrib(void *_glfuncs, GLbitfield mask);
+void gl3_3compat_glPopClientAttrib(void *_glfuncs);
+void gl3_3compat_glPrioritizeTextures(void *_glfuncs, GLsizei n, const GLuint* textures, const GLfloat* priorities);
+GLboolean gl3_3compat_glAreTexturesResident(void *_glfuncs, GLsizei n, const GLuint* textures, GLboolean* residences);
+void gl3_3compat_glVertexPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl3_3compat_glTexCoordPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl3_3compat_glNormalPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl3_3compat_glInterleavedArrays(void *_glfuncs, GLenum format, GLsizei stride, const GLvoid* pointer);
+void gl3_3compat_glIndexPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl3_3compat_glEnableClientState(void *_glfuncs, GLenum array);
+void gl3_3compat_glEdgeFlagPointer(void *_glfuncs, GLsizei stride, const GLvoid* pointer);
+void gl3_3compat_glDisableClientState(void *_glfuncs, GLenum array);
+void gl3_3compat_glColorPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl3_3compat_glArrayElement(void *_glfuncs, GLint i);
+void gl3_3compat_glResetMinmax(void *_glfuncs, GLenum target);
+void gl3_3compat_glResetHistogram(void *_glfuncs, GLenum target);
+void gl3_3compat_glMinmax(void *_glfuncs, GLenum target, GLenum internalFormat, GLboolean sink);
+void gl3_3compat_glHistogram(void *_glfuncs, GLenum target, GLsizei width, GLenum internalFormat, GLboolean sink);
+void gl3_3compat_glGetMinmaxParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl3_3compat_glGetMinmaxParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl3_3compat_glGetMinmax(void *_glfuncs, GLenum target, GLboolean reset, GLenum format, GLenum gltype, GLvoid* values);
+void gl3_3compat_glGetHistogramParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl3_3compat_glGetHistogramParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl3_3compat_glGetHistogram(void *_glfuncs, GLenum target, GLboolean reset, GLenum format, GLenum gltype, GLvoid* values);
+void gl3_3compat_glSeparableFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* row, const GLvoid* column);
+void gl3_3compat_glGetSeparableFilter(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* row, GLvoid* column, GLvoid* span);
+void gl3_3compat_glGetConvolutionParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl3_3compat_glGetConvolutionParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl3_3compat_glGetConvolutionFilter(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* image);
+void gl3_3compat_glCopyConvolutionFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl3_3compat_glCopyConvolutionFilter1D(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width);
+void gl3_3compat_glConvolutionParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl3_3compat_glConvolutionParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint params);
+void gl3_3compat_glConvolutionParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl3_3compat_glConvolutionParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat params);
+void gl3_3compat_glConvolutionFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* image);
+void gl3_3compat_glConvolutionFilter1D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLenum format, GLenum gltype, const GLvoid* image);
+void gl3_3compat_glCopyColorSubTable(void *_glfuncs, GLenum target, GLsizei start, GLint x, GLint y, GLsizei width);
+void gl3_3compat_glColorSubTable(void *_glfuncs, GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum gltype, const GLvoid* data);
+void gl3_3compat_glGetColorTableParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl3_3compat_glGetColorTableParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl3_3compat_glGetColorTable(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* table);
+void gl3_3compat_glCopyColorTable(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width);
+void gl3_3compat_glColorTableParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl3_3compat_glColorTableParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl3_3compat_glColorTable(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLenum format, GLenum gltype, const GLvoid* table);
+void gl3_3compat_glMultTransposeMatrixd(void *_glfuncs, const GLdouble* m);
+void gl3_3compat_glMultTransposeMatrixf(void *_glfuncs, const GLfloat* m);
+void gl3_3compat_glLoadTransposeMatrixd(void *_glfuncs, const GLdouble* m);
+void gl3_3compat_glLoadTransposeMatrixf(void *_glfuncs, const GLfloat* m);
+void gl3_3compat_glMultiTexCoord4sv(void *_glfuncs, GLenum target, const GLshort* v);
+void gl3_3compat_glMultiTexCoord4s(void *_glfuncs, GLenum target, GLshort s, GLshort t, GLshort r, GLshort q);
+void gl3_3compat_glMultiTexCoord4iv(void *_glfuncs, GLenum target, const GLint* v);
+void gl3_3compat_glMultiTexCoord4i(void *_glfuncs, GLenum target, GLint s, GLint t, GLint r, GLint q);
+void gl3_3compat_glMultiTexCoord4fv(void *_glfuncs, GLenum target, const GLfloat* v);
+void gl3_3compat_glMultiTexCoord4f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+void gl3_3compat_glMultiTexCoord4dv(void *_glfuncs, GLenum target, const GLdouble* v);
+void gl3_3compat_glMultiTexCoord4d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+void gl3_3compat_glMultiTexCoord3sv(void *_glfuncs, GLenum target, const GLshort* v);
+void gl3_3compat_glMultiTexCoord3s(void *_glfuncs, GLenum target, GLshort s, GLshort t, GLshort r);
+void gl3_3compat_glMultiTexCoord3iv(void *_glfuncs, GLenum target, const GLint* v);
+void gl3_3compat_glMultiTexCoord3i(void *_glfuncs, GLenum target, GLint s, GLint t, GLint r);
+void gl3_3compat_glMultiTexCoord3fv(void *_glfuncs, GLenum target, const GLfloat* v);
+void gl3_3compat_glMultiTexCoord3f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t, GLfloat r);
+void gl3_3compat_glMultiTexCoord3dv(void *_glfuncs, GLenum target, const GLdouble* v);
+void gl3_3compat_glMultiTexCoord3d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t, GLdouble r);
+void gl3_3compat_glMultiTexCoord2sv(void *_glfuncs, GLenum target, const GLshort* v);
+void gl3_3compat_glMultiTexCoord2s(void *_glfuncs, GLenum target, GLshort s, GLshort t);
+void gl3_3compat_glMultiTexCoord2iv(void *_glfuncs, GLenum target, const GLint* v);
+void gl3_3compat_glMultiTexCoord2i(void *_glfuncs, GLenum target, GLint s, GLint t);
+void gl3_3compat_glMultiTexCoord2fv(void *_glfuncs, GLenum target, const GLfloat* v);
+void gl3_3compat_glMultiTexCoord2f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t);
+void gl3_3compat_glMultiTexCoord2dv(void *_glfuncs, GLenum target, const GLdouble* v);
+void gl3_3compat_glMultiTexCoord2d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t);
+void gl3_3compat_glMultiTexCoord1sv(void *_glfuncs, GLenum target, const GLshort* v);
+void gl3_3compat_glMultiTexCoord1s(void *_glfuncs, GLenum target, GLshort s);
+void gl3_3compat_glMultiTexCoord1iv(void *_glfuncs, GLenum target, const GLint* v);
+void gl3_3compat_glMultiTexCoord1i(void *_glfuncs, GLenum target, GLint s);
+void gl3_3compat_glMultiTexCoord1fv(void *_glfuncs, GLenum target, const GLfloat* v);
+void gl3_3compat_glMultiTexCoord1f(void *_glfuncs, GLenum target, GLfloat s);
+void gl3_3compat_glMultiTexCoord1dv(void *_glfuncs, GLenum target, const GLdouble* v);
+void gl3_3compat_glMultiTexCoord1d(void *_glfuncs, GLenum target, GLdouble s);
+void gl3_3compat_glClientActiveTexture(void *_glfuncs, GLenum texture);
+void gl3_3compat_glWindowPos3sv(void *_glfuncs, const GLshort* v);
+void gl3_3compat_glWindowPos3s(void *_glfuncs, GLshort x, GLshort y, GLshort z);
+void gl3_3compat_glWindowPos3iv(void *_glfuncs, const GLint* v);
+void gl3_3compat_glWindowPos3i(void *_glfuncs, GLint x, GLint y, GLint z);
+void gl3_3compat_glWindowPos3fv(void *_glfuncs, const GLfloat* v);
+void gl3_3compat_glWindowPos3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl3_3compat_glWindowPos3dv(void *_glfuncs, const GLdouble* v);
+void gl3_3compat_glWindowPos3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl3_3compat_glWindowPos2sv(void *_glfuncs, const GLshort* v);
+void gl3_3compat_glWindowPos2s(void *_glfuncs, GLshort x, GLshort y);
+void gl3_3compat_glWindowPos2iv(void *_glfuncs, const GLint* v);
+void gl3_3compat_glWindowPos2i(void *_glfuncs, GLint x, GLint y);
+void gl3_3compat_glWindowPos2fv(void *_glfuncs, const GLfloat* v);
+void gl3_3compat_glWindowPos2f(void *_glfuncs, GLfloat x, GLfloat y);
+void gl3_3compat_glWindowPos2dv(void *_glfuncs, const GLdouble* v);
+void gl3_3compat_glWindowPos2d(void *_glfuncs, GLdouble x, GLdouble y);
+void gl3_3compat_glSecondaryColorPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl3_3compat_glSecondaryColor3usv(void *_glfuncs, const GLushort* v);
+void gl3_3compat_glSecondaryColor3us(void *_glfuncs, GLushort red, GLushort green, GLushort blue);
+void gl3_3compat_glSecondaryColor3uiv(void *_glfuncs, const GLuint* v);
+void gl3_3compat_glSecondaryColor3ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue);
+void gl3_3compat_glSecondaryColor3ubv(void *_glfuncs, const GLubyte* v);
+void gl3_3compat_glSecondaryColor3ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue);
+void gl3_3compat_glSecondaryColor3sv(void *_glfuncs, const GLshort* v);
+void gl3_3compat_glSecondaryColor3s(void *_glfuncs, GLshort red, GLshort green, GLshort blue);
+void gl3_3compat_glSecondaryColor3iv(void *_glfuncs, const GLint* v);
+void gl3_3compat_glSecondaryColor3i(void *_glfuncs, GLint red, GLint green, GLint blue);
+void gl3_3compat_glSecondaryColor3fv(void *_glfuncs, const GLfloat* v);
+void gl3_3compat_glSecondaryColor3f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue);
+void gl3_3compat_glSecondaryColor3dv(void *_glfuncs, const GLdouble* v);
+void gl3_3compat_glSecondaryColor3d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue);
+void gl3_3compat_glSecondaryColor3bv(void *_glfuncs, const GLbyte* v);
+void gl3_3compat_glSecondaryColor3b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue);
+void gl3_3compat_glFogCoordPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl3_3compat_glFogCoorddv(void *_glfuncs, const GLdouble* coord);
+void gl3_3compat_glFogCoordd(void *_glfuncs, GLdouble coord);
+void gl3_3compat_glFogCoordfv(void *_glfuncs, const GLfloat* coord);
+void gl3_3compat_glFogCoordf(void *_glfuncs, GLfloat coord);
+void gl3_3compat_glVertexAttrib4usv(void *_glfuncs, GLuint index, const GLushort* v);
+void gl3_3compat_glVertexAttrib4uiv(void *_glfuncs, GLuint index, const GLuint* v);
+void gl3_3compat_glVertexAttrib4ubv(void *_glfuncs, GLuint index, const GLubyte* v);
+void gl3_3compat_glVertexAttrib4sv(void *_glfuncs, GLuint index, const GLshort* v);
+void gl3_3compat_glVertexAttrib4s(void *_glfuncs, GLuint index, GLshort x, GLshort y, GLshort z, GLshort w);
+void gl3_3compat_glVertexAttrib4iv(void *_glfuncs, GLuint index, const GLint* v);
+void gl3_3compat_glVertexAttrib4fv(void *_glfuncs, GLuint index, const GLfloat* v);
+void gl3_3compat_glVertexAttrib4f(void *_glfuncs, GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+void gl3_3compat_glVertexAttrib4dv(void *_glfuncs, GLuint index, const GLdouble* v);
+void gl3_3compat_glVertexAttrib4d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+void gl3_3compat_glVertexAttrib4bv(void *_glfuncs, GLuint index, const GLbyte* v);
+void gl3_3compat_glVertexAttrib4Nusv(void *_glfuncs, GLuint index, const GLushort* v);
+void gl3_3compat_glVertexAttrib4Nuiv(void *_glfuncs, GLuint index, const GLuint* v);
+void gl3_3compat_glVertexAttrib4Nubv(void *_glfuncs, GLuint index, const GLubyte* v);
+void gl3_3compat_glVertexAttrib4Nub(void *_glfuncs, GLuint index, GLubyte x, GLubyte y, GLubyte z, GLubyte w);
+void gl3_3compat_glVertexAttrib4Nsv(void *_glfuncs, GLuint index, const GLshort* v);
+void gl3_3compat_glVertexAttrib4Niv(void *_glfuncs, GLuint index, const GLint* v);
+void gl3_3compat_glVertexAttrib4Nbv(void *_glfuncs, GLuint index, const GLbyte* v);
+void gl3_3compat_glVertexAttrib3sv(void *_glfuncs, GLuint index, const GLshort* v);
+void gl3_3compat_glVertexAttrib3s(void *_glfuncs, GLuint index, GLshort x, GLshort y, GLshort z);
+void gl3_3compat_glVertexAttrib3fv(void *_glfuncs, GLuint index, const GLfloat* v);
+void gl3_3compat_glVertexAttrib3f(void *_glfuncs, GLuint index, GLfloat x, GLfloat y, GLfloat z);
+void gl3_3compat_glVertexAttrib3dv(void *_glfuncs, GLuint index, const GLdouble* v);
+void gl3_3compat_glVertexAttrib3d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y, GLdouble z);
+void gl3_3compat_glVertexAttrib2sv(void *_glfuncs, GLuint index, const GLshort* v);
+void gl3_3compat_glVertexAttrib2s(void *_glfuncs, GLuint index, GLshort x, GLshort y);
+void gl3_3compat_glVertexAttrib2fv(void *_glfuncs, GLuint index, const GLfloat* v);
+void gl3_3compat_glVertexAttrib2f(void *_glfuncs, GLuint index, GLfloat x, GLfloat y);
+void gl3_3compat_glVertexAttrib2dv(void *_glfuncs, GLuint index, const GLdouble* v);
+void gl3_3compat_glVertexAttrib2d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y);
+void gl3_3compat_glVertexAttrib1sv(void *_glfuncs, GLuint index, const GLshort* v);
+void gl3_3compat_glVertexAttrib1s(void *_glfuncs, GLuint index, GLshort x);
+void gl3_3compat_glVertexAttrib1fv(void *_glfuncs, GLuint index, const GLfloat* v);
+void gl3_3compat_glVertexAttrib1f(void *_glfuncs, GLuint index, GLfloat x);
+void gl3_3compat_glVertexAttrib1dv(void *_glfuncs, GLuint index, const GLdouble* v);
+void gl3_3compat_glVertexAttrib1d(void *_glfuncs, GLuint index, GLdouble x);
+void gl3_3compat_glVertexAttribI4usv(void *_glfuncs, GLuint index, const GLushort* v);
+void gl3_3compat_glVertexAttribI4ubv(void *_glfuncs, GLuint index, const GLubyte* v);
+void gl3_3compat_glVertexAttribI4sv(void *_glfuncs, GLuint index, const GLshort* v);
+void gl3_3compat_glVertexAttribI4bv(void *_glfuncs, GLuint index, const GLbyte* v);
+void gl3_3compat_glVertexAttribI4uiv(void *_glfuncs, GLuint index, const GLuint* v);
+void gl3_3compat_glVertexAttribI3uiv(void *_glfuncs, GLuint index, const GLuint* v);
+void gl3_3compat_glVertexAttribI2uiv(void *_glfuncs, GLuint index, const GLuint* v);
+void gl3_3compat_glVertexAttribI1uiv(void *_glfuncs, GLuint index, const GLuint* v);
+void gl3_3compat_glVertexAttribI4iv(void *_glfuncs, GLuint index, const GLint* v);
+void gl3_3compat_glVertexAttribI3iv(void *_glfuncs, GLuint index, const GLint* v);
+void gl3_3compat_glVertexAttribI2iv(void *_glfuncs, GLuint index, const GLint* v);
+void gl3_3compat_glVertexAttribI1iv(void *_glfuncs, GLuint index, const GLint* v);
+void gl3_3compat_glVertexAttribI4ui(void *_glfuncs, GLuint index, GLuint x, GLuint y, GLuint z, GLuint w);
+void gl3_3compat_glVertexAttribI3ui(void *_glfuncs, GLuint index, GLuint x, GLuint y, GLuint z);
+void gl3_3compat_glVertexAttribI2ui(void *_glfuncs, GLuint index, GLuint x, GLuint y);
+void gl3_3compat_glVertexAttribI1ui(void *_glfuncs, GLuint index, GLuint x);
+void gl3_3compat_glVertexAttribI4i(void *_glfuncs, GLuint index, GLint x, GLint y, GLint z, GLint w);
+void gl3_3compat_glVertexAttribI3i(void *_glfuncs, GLuint index, GLint x, GLint y, GLint z);
+void gl3_3compat_glVertexAttribI2i(void *_glfuncs, GLuint index, GLint x, GLint y);
+void gl3_3compat_glVertexAttribI1i(void *_glfuncs, GLuint index, GLint x);
+
+
+#ifdef __cplusplus
+} // extern "C"
+#endif
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/3.3compat/gl.go b/Godeps/_workspace/src/github.com/obscuren/qml/gl/3.3compat/gl.go
new file mode 100644
index 000000000..8772aa9bc
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/3.3compat/gl.go
@@ -0,0 +1,8281 @@
+// ** file automatically generated by glgen -- do not edit manually **
+
+package GL
+
+// #cgo CXXFLAGS: -std=c++0x -pedantic-errors -Wall -fno-strict-aliasing
+// #cgo LDFLAGS: -lstdc++
+// #cgo pkg-config: Qt5Core Qt5OpenGL
+//
+// #include "funcs.h"
+//
+// void free(void*);
+//
+import "C"
+
+import (
+ "fmt"
+ "reflect"
+ "unsafe"
+
+ "gopkg.in/qml.v1/gl/glbase"
+)
+
+// API returns a value that offers methods matching the OpenGL version 3.3 API.
+//
+// The returned API must not be used after the provided OpenGL context becomes invalid.
+func API(context glbase.Contexter) *GL {
+ gl := &GL{}
+ gl.funcs = C.gl3_3compat_funcs()
+ if gl.funcs == nil {
+ panic(fmt.Errorf("OpenGL version 3.3 is not available"))
+ }
+ return gl
+}
+
+// GL implements the OpenGL version 3.3 API. Values of this
+// type must be created via the API function, and it must not be used after
+// the associated OpenGL context becomes invalid.
+type GL struct {
+ funcs unsafe.Pointer
+}
+
+const (
+ FALSE = 0
+ TRUE = 1
+ NONE = 0
+
+ BYTE = 0x1400
+ UNSIGNED_BYTE = 0x1401
+ SHORT = 0x1402
+ UNSIGNED_SHORT = 0x1403
+ INT = 0x1404
+ UNSIGNED_INT = 0x1405
+ FLOAT = 0x1406
+ N2_BYTES = 0x1407
+ N3_BYTES = 0x1408
+ N4_BYTES = 0x1409
+ DOUBLE = 0x140A
+ HALF_FLOAT = 0x140B
+
+ ACCUM = 0x0100
+ LOAD = 0x0101
+ RETURN = 0x0102
+ MULT = 0x0103
+ ADD = 0x0104
+
+ ACCUM_BUFFER_BIT = 0x00000200
+ ALL_ATTRIB_BITS = 0xFFFFFFFF
+ COLOR_BUFFER_BIT = 0x00004000
+ CURRENT_BIT = 0x00000001
+ DEPTH_BUFFER_BIT = 0x00000100
+ ENABLE_BIT = 0x00002000
+ EVAL_BIT = 0x00010000
+ FOG_BIT = 0x00000080
+ HINT_BIT = 0x00008000
+ LIGHTING_BIT = 0x00000040
+ LINE_BIT = 0x00000004
+ LIST_BIT = 0x00020000
+ MULTISAMPLE_BIT = 0x20000000
+ PIXEL_MODE_BIT = 0x00000020
+ POINT_BIT = 0x00000002
+ POLYGON_BIT = 0x00000008
+ POLYGON_STIPPLE_BIT = 0x00000010
+ SCISSOR_BIT = 0x00080000
+ STENCIL_BUFFER_BIT = 0x00000400
+ TEXTURE_BIT = 0x00040000
+ TRANSFORM_BIT = 0x00001000
+ VIEWPORT_BIT = 0x00000800
+
+ ALWAYS = 0x0207
+ EQUAL = 0x0202
+ GEQUAL = 0x0206
+ GREATER = 0x0204
+ LEQUAL = 0x0203
+ LESS = 0x0201
+ NEVER = 0x0200
+ NOTEQUAL = 0x0205
+
+ LOGIC_OP = 0x0BF1
+
+ DST_ALPHA = 0x0304
+ ONE = 1
+ ONE_MINUS_DST_ALPHA = 0x0305
+ ONE_MINUS_SRC_ALPHA = 0x0303
+ ONE_MINUS_SRC_COLOR = 0x0301
+ SRC_ALPHA = 0x0302
+ SRC_COLOR = 0x0300
+ ZERO = 0
+
+ DST_COLOR = 0x0306
+ ONE_MINUS_DST_COLOR = 0x0307
+ SRC_ALPHA_SATURATE = 0x0308
+
+ CLIENT_ALL_ATTRIB_BITS = 0xFFFFFFFF
+ CLIENT_PIXEL_STORE_BIT = 0x00000001
+ CLIENT_VERTEX_ARRAY_BIT = 0x00000002
+
+ CLIP_DISTANCE0 = 0x3000
+ CLIP_DISTANCE1 = 0x3001
+ CLIP_DISTANCE2 = 0x3002
+ CLIP_DISTANCE3 = 0x3003
+ CLIP_DISTANCE4 = 0x3004
+ CLIP_DISTANCE5 = 0x3005
+ CLIP_DISTANCE6 = 0x3006
+ CLIP_DISTANCE7 = 0x3007
+ CLIP_PLANE0 = 0x3000
+ CLIP_PLANE1 = 0x3001
+ CLIP_PLANE2 = 0x3002
+ CLIP_PLANE3 = 0x3003
+ CLIP_PLANE4 = 0x3004
+ CLIP_PLANE5 = 0x3005
+
+ BACK = 0x0405
+ FRONT = 0x0404
+ FRONT_AND_BACK = 0x0408
+
+ AMBIENT = 0x1200
+ AMBIENT_AND_DIFFUSE = 0x1602
+ DIFFUSE = 0x1201
+ EMISSION = 0x1600
+ SPECULAR = 0x1202
+
+ CONTEXT_FLAG_FORWARD_COMPATIBLE_BIT = 0x00000001
+
+ CONTEXT_COMPATIBILITY_PROFILE_BIT = 0x00000002
+ CONTEXT_CORE_PROFILE_BIT = 0x00000001
+
+ AUX0 = 0x0409
+ AUX1 = 0x040A
+ AUX2 = 0x040B
+ AUX3 = 0x040C
+ BACK_LEFT = 0x0402
+ BACK_RIGHT = 0x0403
+ FRONT_LEFT = 0x0400
+ FRONT_RIGHT = 0x0401
+ LEFT = 0x0406
+ RIGHT = 0x0407
+
+ ALPHA_TEST = 0x0BC0
+ AUTO_NORMAL = 0x0D80
+ BLEND = 0x0BE2
+ COLOR_ARRAY = 0x8076
+ COLOR_LOGIC_OP = 0x0BF2
+ COLOR_MATERIAL = 0x0B57
+ CULL_FACE = 0x0B44
+ DEPTH_TEST = 0x0B71
+ DITHER = 0x0BD0
+ EDGE_FLAG_ARRAY = 0x8079
+ FOG = 0x0B60
+ INDEX_ARRAY = 0x8077
+ INDEX_LOGIC_OP = 0x0BF1
+ LIGHT0 = 0x4000
+ LIGHT1 = 0x4001
+ LIGHT2 = 0x4002
+ LIGHT3 = 0x4003
+ LIGHT4 = 0x4004
+ LIGHT5 = 0x4005
+ LIGHT6 = 0x4006
+ LIGHT7 = 0x4007
+ LIGHTING = 0x0B50
+ LINE_SMOOTH = 0x0B20
+ LINE_STIPPLE = 0x0B24
+ MAP1_COLOR_4 = 0x0D90
+ MAP1_INDEX = 0x0D91
+ MAP1_NORMAL = 0x0D92
+ MAP1_TEXTURE_COORD_1 = 0x0D93
+ MAP1_TEXTURE_COORD_2 = 0x0D94
+ MAP1_TEXTURE_COORD_3 = 0x0D95
+ MAP1_TEXTURE_COORD_4 = 0x0D96
+ MAP1_VERTEX_3 = 0x0D97
+ MAP1_VERTEX_4 = 0x0D98
+ MAP2_COLOR_4 = 0x0DB0
+ MAP2_INDEX = 0x0DB1
+ MAP2_NORMAL = 0x0DB2
+ MAP2_TEXTURE_COORD_1 = 0x0DB3
+ MAP2_TEXTURE_COORD_2 = 0x0DB4
+ MAP2_TEXTURE_COORD_3 = 0x0DB5
+ MAP2_TEXTURE_COORD_4 = 0x0DB6
+ MAP2_VERTEX_3 = 0x0DB7
+ MAP2_VERTEX_4 = 0x0DB8
+ NORMALIZE = 0x0BA1
+ NORMAL_ARRAY = 0x8075
+ POINT_SMOOTH = 0x0B10
+ POLYGON_OFFSET_FILL = 0x8037
+ POLYGON_OFFSET_LINE = 0x2A02
+ POLYGON_OFFSET_POINT = 0x2A01
+ POLYGON_SMOOTH = 0x0B41
+ POLYGON_STIPPLE = 0x0B42
+ SCISSOR_TEST = 0x0C11
+ STENCIL_TEST = 0x0B90
+ TEXTURE_1D = 0x0DE0
+ TEXTURE_2D = 0x0DE1
+ TEXTURE_COORD_ARRAY = 0x8078
+ TEXTURE_GEN_Q = 0x0C63
+ TEXTURE_GEN_R = 0x0C62
+ TEXTURE_GEN_S = 0x0C60
+ TEXTURE_GEN_T = 0x0C61
+ VERTEX_ARRAY = 0x8074
+
+ INVALID_ENUM = 0x0500
+ INVALID_FRAMEBUFFER_OPERATION = 0x0506
+ INVALID_OPERATION = 0x0502
+ INVALID_VALUE = 0x0501
+ NO_ERROR = 0
+ OUT_OF_MEMORY = 0x0505
+ STACK_OVERFLOW = 0x0503
+ STACK_UNDERFLOW = 0x0504
+
+ N2D = 0x0600
+ N3D = 0x0601
+ N3D_COLOR = 0x0602
+ N3D_COLOR_TEXTURE = 0x0603
+ N4D_COLOR_TEXTURE = 0x0604
+
+ BITMAP_TOKEN = 0x0704
+ COPY_PIXEL_TOKEN = 0x0706
+ DRAW_PIXEL_TOKEN = 0x0705
+ LINE_RESET_TOKEN = 0x0707
+ LINE_TOKEN = 0x0702
+ PASS_THROUGH_TOKEN = 0x0700
+ POINT_TOKEN = 0x0701
+ POLYGON_TOKEN = 0x0703
+
+ EXP = 0x0800
+ EXP2 = 0x0801
+ LINEAR = 0x2601
+
+ FOG_COLOR = 0x0B66
+ FOG_DENSITY = 0x0B62
+ FOG_END = 0x0B64
+ FOG_INDEX = 0x0B61
+ FOG_MODE = 0x0B65
+ FOG_START = 0x0B63
+
+ CCW = 0x0901
+ CW = 0x0900
+
+ COEFF = 0x0A00
+ DOMAIN = 0x0A02
+ ORDER = 0x0A01
+
+ PIXEL_MAP_A_TO_A = 0x0C79
+ PIXEL_MAP_B_TO_B = 0x0C78
+ PIXEL_MAP_G_TO_G = 0x0C77
+ PIXEL_MAP_I_TO_A = 0x0C75
+ PIXEL_MAP_I_TO_B = 0x0C74
+ PIXEL_MAP_I_TO_G = 0x0C73
+ PIXEL_MAP_I_TO_I = 0x0C70
+ PIXEL_MAP_I_TO_R = 0x0C72
+ PIXEL_MAP_R_TO_R = 0x0C76
+ PIXEL_MAP_S_TO_S = 0x0C71
+
+ ACCUM_ALPHA_BITS = 0x0D5B
+ ACCUM_BLUE_BITS = 0x0D5A
+ ACCUM_CLEAR_VALUE = 0x0B80
+ ACCUM_GREEN_BITS = 0x0D59
+ ACCUM_RED_BITS = 0x0D58
+ ALIASED_LINE_WIDTH_RANGE = 0x846E
+ ALIASED_POINT_SIZE_RANGE = 0x846D
+ ALPHA_BIAS = 0x0D1D
+ ALPHA_BITS = 0x0D55
+ ALPHA_SCALE = 0x0D1C
+ ALPHA_TEST_FUNC = 0x0BC1
+ ALPHA_TEST_REF = 0x0BC2
+ ATTRIB_STACK_DEPTH = 0x0BB0
+ AUX_BUFFERS = 0x0C00
+ BLEND_DST = 0x0BE0
+ BLEND_SRC = 0x0BE1
+ BLUE_BIAS = 0x0D1B
+ BLUE_BITS = 0x0D54
+ BLUE_SCALE = 0x0D1A
+ CLIENT_ATTRIB_STACK_DEPTH = 0x0BB1
+ COLOR_ARRAY_SIZE = 0x8081
+ COLOR_ARRAY_STRIDE = 0x8083
+ COLOR_ARRAY_TYPE = 0x8082
+ COLOR_CLEAR_VALUE = 0x0C22
+ COLOR_MATERIAL_FACE = 0x0B55
+ COLOR_MATERIAL_PARAMETER = 0x0B56
+ COLOR_WRITEMASK = 0x0C23
+ CULL_FACE_MODE = 0x0B45
+ CURRENT_COLOR = 0x0B00
+ CURRENT_INDEX = 0x0B01
+ CURRENT_NORMAL = 0x0B02
+ CURRENT_RASTER_COLOR = 0x0B04
+ CURRENT_RASTER_DISTANCE = 0x0B09
+ CURRENT_RASTER_INDEX = 0x0B05
+ CURRENT_RASTER_POSITION = 0x0B07
+ CURRENT_RASTER_POSITION_VALID = 0x0B08
+ CURRENT_RASTER_TEXTURE_COORDS = 0x0B06
+ CURRENT_TEXTURE_COORDS = 0x0B03
+ DEPTH_BIAS = 0x0D1F
+ DEPTH_BITS = 0x0D56
+ DEPTH_CLEAR_VALUE = 0x0B73
+ DEPTH_FUNC = 0x0B74
+ DEPTH_RANGE = 0x0B70
+ DEPTH_SCALE = 0x0D1E
+ DEPTH_WRITEMASK = 0x0B72
+ DOUBLEBUFFER = 0x0C32
+ DRAW_BUFFER = 0x0C01
+ EDGE_FLAG = 0x0B43
+ EDGE_FLAG_ARRAY_STRIDE = 0x808C
+ FEEDBACK_BUFFER_SIZE = 0x0DF1
+ FEEDBACK_BUFFER_TYPE = 0x0DF2
+ FOG_HINT = 0x0C54
+ FRONT_FACE = 0x0B46
+ GREEN_BIAS = 0x0D19
+ GREEN_BITS = 0x0D53
+ GREEN_SCALE = 0x0D18
+ INDEX_ARRAY_STRIDE = 0x8086
+ INDEX_ARRAY_TYPE = 0x8085
+ INDEX_BITS = 0x0D51
+ INDEX_CLEAR_VALUE = 0x0C20
+ INDEX_MODE = 0x0C30
+ INDEX_OFFSET = 0x0D13
+ INDEX_SHIFT = 0x0D12
+ INDEX_WRITEMASK = 0x0C21
+ LIGHT_MODEL_AMBIENT = 0x0B53
+ LIGHT_MODEL_COLOR_CONTROL = 0x81F8
+ LIGHT_MODEL_LOCAL_VIEWER = 0x0B51
+ LIGHT_MODEL_TWO_SIDE = 0x0B52
+ LINE_SMOOTH_HINT = 0x0C52
+ LINE_STIPPLE_PATTERN = 0x0B25
+ LINE_STIPPLE_REPEAT = 0x0B26
+ LINE_WIDTH = 0x0B21
+ LINE_WIDTH_GRANULARITY = 0x0B23
+ LINE_WIDTH_RANGE = 0x0B22
+ LIST_BASE = 0x0B32
+ LIST_INDEX = 0x0B33
+ LIST_MODE = 0x0B30
+ LOGIC_OP_MODE = 0x0BF0
+ MAP1_GRID_DOMAIN = 0x0DD0
+ MAP1_GRID_SEGMENTS = 0x0DD1
+ MAP2_GRID_DOMAIN = 0x0DD2
+ MAP2_GRID_SEGMENTS = 0x0DD3
+ MAP_COLOR = 0x0D10
+ MAP_STENCIL = 0x0D11
+ MATRIX_MODE = 0x0BA0
+ MAX_ATTRIB_STACK_DEPTH = 0x0D35
+ MAX_CLIENT_ATTRIB_STACK_DEPTH = 0x0D3B
+ MAX_CLIP_DISTANCES = 0x0D32
+ MAX_CLIP_PLANES = 0x0D32
+ MAX_EVAL_ORDER = 0x0D30
+ MAX_LIGHTS = 0x0D31
+ MAX_LIST_NESTING = 0x0B31
+ MAX_MODELVIEW_STACK_DEPTH = 0x0D36
+ MAX_NAME_STACK_DEPTH = 0x0D37
+ MAX_PIXEL_MAP_TABLE = 0x0D34
+ MAX_PROJECTION_STACK_DEPTH = 0x0D38
+ MAX_TEXTURE_SIZE = 0x0D33
+ MAX_TEXTURE_STACK_DEPTH = 0x0D39
+ MAX_VIEWPORT_DIMS = 0x0D3A
+ MODELVIEW_MATRIX = 0x0BA6
+ MODELVIEW_STACK_DEPTH = 0x0BA3
+ NAME_STACK_DEPTH = 0x0D70
+ NORMAL_ARRAY_STRIDE = 0x807F
+ NORMAL_ARRAY_TYPE = 0x807E
+ PACK_ALIGNMENT = 0x0D05
+ PACK_LSB_FIRST = 0x0D01
+ PACK_ROW_LENGTH = 0x0D02
+ PACK_SKIP_PIXELS = 0x0D04
+ PACK_SKIP_ROWS = 0x0D03
+ PACK_SWAP_BYTES = 0x0D00
+ PERSPECTIVE_CORRECTION_HINT = 0x0C50
+ PIXEL_MAP_A_TO_A_SIZE = 0x0CB9
+ PIXEL_MAP_B_TO_B_SIZE = 0x0CB8
+ PIXEL_MAP_G_TO_G_SIZE = 0x0CB7
+ PIXEL_MAP_I_TO_A_SIZE = 0x0CB5
+ PIXEL_MAP_I_TO_B_SIZE = 0x0CB4
+ PIXEL_MAP_I_TO_G_SIZE = 0x0CB3
+ PIXEL_MAP_I_TO_I_SIZE = 0x0CB0
+ PIXEL_MAP_I_TO_R_SIZE = 0x0CB2
+ PIXEL_MAP_R_TO_R_SIZE = 0x0CB6
+ PIXEL_MAP_S_TO_S_SIZE = 0x0CB1
+ POINT_SIZE = 0x0B11
+ POINT_SIZE_GRANULARITY = 0x0B13
+ POINT_SIZE_RANGE = 0x0B12
+ POINT_SMOOTH_HINT = 0x0C51
+ POLYGON_MODE = 0x0B40
+ POLYGON_OFFSET_FACTOR = 0x8038
+ POLYGON_OFFSET_UNITS = 0x2A00
+ POLYGON_SMOOTH_HINT = 0x0C53
+ PROJECTION_MATRIX = 0x0BA7
+ PROJECTION_STACK_DEPTH = 0x0BA4
+ READ_BUFFER = 0x0C02
+ RED_BIAS = 0x0D15
+ RED_BITS = 0x0D52
+ RED_SCALE = 0x0D14
+ RENDER_MODE = 0x0C40
+ RGBA_MODE = 0x0C31
+ SCISSOR_BOX = 0x0C10
+ SELECTION_BUFFER_SIZE = 0x0DF4
+ SHADE_MODEL = 0x0B54
+ SMOOTH_LINE_WIDTH_GRANULARITY = 0x0B23
+ SMOOTH_LINE_WIDTH_RANGE = 0x0B22
+ SMOOTH_POINT_SIZE_GRANULARITY = 0x0B13
+ SMOOTH_POINT_SIZE_RANGE = 0x0B12
+ STENCIL_BITS = 0x0D57
+ STENCIL_CLEAR_VALUE = 0x0B91
+ STENCIL_FAIL = 0x0B94
+ STENCIL_FUNC = 0x0B92
+ STENCIL_PASS_DEPTH_FAIL = 0x0B95
+ STENCIL_PASS_DEPTH_PASS = 0x0B96
+ STENCIL_REF = 0x0B97
+ STENCIL_VALUE_MASK = 0x0B93
+ STENCIL_WRITEMASK = 0x0B98
+ STEREO = 0x0C33
+ SUBPIXEL_BITS = 0x0D50
+ TEXTURE_BINDING_1D = 0x8068
+ TEXTURE_BINDING_2D = 0x8069
+ TEXTURE_BINDING_3D = 0x806A
+ TEXTURE_COORD_ARRAY_SIZE = 0x8088
+ TEXTURE_COORD_ARRAY_STRIDE = 0x808A
+ TEXTURE_COORD_ARRAY_TYPE = 0x8089
+ TEXTURE_MATRIX = 0x0BA8
+ TEXTURE_STACK_DEPTH = 0x0BA5
+ UNPACK_ALIGNMENT = 0x0CF5
+ UNPACK_LSB_FIRST = 0x0CF1
+ UNPACK_ROW_LENGTH = 0x0CF2
+ UNPACK_SKIP_PIXELS = 0x0CF4
+ UNPACK_SKIP_ROWS = 0x0CF3
+ UNPACK_SWAP_BYTES = 0x0CF0
+ VERTEX_ARRAY_SIZE = 0x807A
+ VERTEX_ARRAY_STRIDE = 0x807C
+ VERTEX_ARRAY_TYPE = 0x807B
+ VIEWPORT = 0x0BA2
+ ZOOM_X = 0x0D16
+ ZOOM_Y = 0x0D17
+
+ COLOR_ARRAY_POINTER = 0x8090
+ EDGE_FLAG_ARRAY_POINTER = 0x8093
+ FEEDBACK_BUFFER_POINTER = 0x0DF0
+ INDEX_ARRAY_POINTER = 0x8091
+ NORMAL_ARRAY_POINTER = 0x808F
+ SELECTION_BUFFER_POINTER = 0x0DF3
+ TEXTURE_COORD_ARRAY_POINTER = 0x8092
+ VERTEX_ARRAY_POINTER = 0x808E
+
+ TEXTURE_ALPHA_SIZE = 0x805F
+ TEXTURE_BLUE_SIZE = 0x805E
+ TEXTURE_BORDER = 0x1005
+ TEXTURE_BORDER_COLOR = 0x1004
+ TEXTURE_COMPONENTS = 0x1003
+ TEXTURE_GREEN_SIZE = 0x805D
+ TEXTURE_HEIGHT = 0x1001
+ TEXTURE_INTENSITY_SIZE = 0x8061
+ TEXTURE_INTERNAL_FORMAT = 0x1003
+ TEXTURE_LUMINANCE_SIZE = 0x8060
+ TEXTURE_MAG_FILTER = 0x2800
+ TEXTURE_MIN_FILTER = 0x2801
+ TEXTURE_PRIORITY = 0x8066
+ TEXTURE_RED_SIZE = 0x805C
+ TEXTURE_RESIDENT = 0x8067
+ TEXTURE_WIDTH = 0x1000
+ TEXTURE_WRAP_S = 0x2802
+ TEXTURE_WRAP_T = 0x2803
+
+ DONT_CARE = 0x1100
+ FASTEST = 0x1101
+ NICEST = 0x1102
+
+ FRAGMENT_SHADER_DERIVATIVE_HINT = 0x8B8B
+ GENERATE_MIPMAP_HINT = 0x8192
+ TEXTURE_COMPRESSION_HINT = 0x84EF
+
+ C3F_V3F = 0x2A24
+ C4F_N3F_V3F = 0x2A26
+ C4UB_V2F = 0x2A22
+ C4UB_V3F = 0x2A23
+ N3F_V3F = 0x2A25
+ T2F_C3F_V3F = 0x2A2A
+ T2F_C4F_N3F_V3F = 0x2A2C
+ T2F_C4UB_V3F = 0x2A29
+ T2F_N3F_V3F = 0x2A2B
+ T2F_V3F = 0x2A27
+ T4F_C4F_N3F_V4F = 0x2A2D
+ T4F_V4F = 0x2A28
+ V2F = 0x2A20
+ V3F = 0x2A21
+
+ MODULATE = 0x2100
+ REPLACE = 0x1E01
+
+ SEPARATE_SPECULAR_COLOR = 0x81FA
+ SINGLE_COLOR = 0x81F9
+
+ CONSTANT_ATTENUATION = 0x1207
+ LINEAR_ATTENUATION = 0x1208
+ POSITION = 0x1203
+ QUADRATIC_ATTENUATION = 0x1209
+ SPOT_CUTOFF = 0x1206
+ SPOT_DIRECTION = 0x1204
+ SPOT_EXPONENT = 0x1205
+
+ COMPILE = 0x1300
+ COMPILE_AND_EXECUTE = 0x1301
+
+ AND = 0x1501
+ AND_INVERTED = 0x1504
+ AND_REVERSE = 0x1502
+ CLEAR = 0x1500
+ COPY = 0x1503
+ COPY_INVERTED = 0x150C
+ EQUIV = 0x1509
+ INVERT = 0x150A
+ NAND = 0x150E
+ NOOP = 0x1505
+ NOR = 0x1508
+ OR = 0x1507
+ OR_INVERTED = 0x150D
+ OR_REVERSE = 0x150B
+ SET = 0x150F
+ XOR = 0x1506
+
+ MAP_FLUSH_EXPLICIT_BIT = 0x0010
+ MAP_INVALIDATE_BUFFER_BIT = 0x0008
+ MAP_INVALIDATE_RANGE_BIT = 0x0004
+ MAP_READ_BIT = 0x0001
+ MAP_UNSYNCHRONIZED_BIT = 0x0020
+ MAP_WRITE_BIT = 0x0002
+
+ COLOR_INDEXES = 0x1603
+ SHININESS = 0x1601
+
+ MODELVIEW = 0x1700
+ PROJECTION = 0x1701
+ TEXTURE = 0x1702
+
+ LINE = 0x1B01
+ POINT = 0x1B00
+
+ FILL = 0x1B02
+
+ COLOR = 0x1800
+ DEPTH = 0x1801
+ STENCIL = 0x1802
+
+ ALPHA = 0x1906
+ BLUE = 0x1905
+ COLOR_INDEX = 0x1900
+ DEPTH_COMPONENT = 0x1902
+ GREEN = 0x1904
+ LUMINANCE = 0x1909
+ LUMINANCE_ALPHA = 0x190A
+ RED = 0x1903
+ RGB = 0x1907
+ RGBA = 0x1908
+ STENCIL_INDEX = 0x1901
+
+ ALPHA12 = 0x803D
+ ALPHA16 = 0x803E
+ ALPHA4 = 0x803B
+ ALPHA8 = 0x803C
+ INTENSITY = 0x8049
+ INTENSITY12 = 0x804C
+ INTENSITY16 = 0x804D
+ INTENSITY4 = 0x804A
+ INTENSITY8 = 0x804B
+ LUMINANCE12 = 0x8041
+ LUMINANCE12_ALPHA12 = 0x8047
+ LUMINANCE12_ALPHA4 = 0x8046
+ LUMINANCE16 = 0x8042
+ LUMINANCE16_ALPHA16 = 0x8048
+ LUMINANCE4 = 0x803F
+ LUMINANCE4_ALPHA4 = 0x8043
+ LUMINANCE6_ALPHA2 = 0x8044
+ LUMINANCE8 = 0x8040
+ LUMINANCE8_ALPHA8 = 0x8045
+ R3_G3_B2 = 0x2A10
+ RGB10 = 0x8052
+ RGB10_A2 = 0x8059
+ RGB12 = 0x8053
+ RGB16 = 0x8054
+ RGB4 = 0x804F
+ RGB5 = 0x8050
+ RGB5_A1 = 0x8057
+ RGB8 = 0x8051
+ RGBA12 = 0x805A
+ RGBA16 = 0x805B
+ RGBA2 = 0x8055
+ RGBA4 = 0x8056
+ RGBA8 = 0x8058
+
+ PACK_IMAGE_HEIGHT = 0x806C
+ PACK_SKIP_IMAGES = 0x806B
+ UNPACK_IMAGE_HEIGHT = 0x806E
+ UNPACK_SKIP_IMAGES = 0x806D
+
+ BITMAP = 0x1A00
+ UNSIGNED_BYTE_3_3_2 = 0x8032
+ UNSIGNED_INT_10_10_10_2 = 0x8036
+ UNSIGNED_INT_8_8_8_8 = 0x8035
+ UNSIGNED_SHORT_4_4_4_4 = 0x8033
+ UNSIGNED_SHORT_5_5_5_1 = 0x8034
+
+ POINT_DISTANCE_ATTENUATION = 0x8129
+ POINT_FADE_THRESHOLD_SIZE = 0x8128
+ POINT_SIZE_MAX = 0x8127
+ POINT_SIZE_MIN = 0x8126
+
+ LINES = 0x0001
+ LINES_ADJACENCY = 0x000A
+ LINE_LOOP = 0x0002
+ LINE_STRIP = 0x0003
+ LINE_STRIP_ADJACENCY = 0x000B
+ POINTS = 0x0000
+ POLYGON = 0x0009
+ QUADS = 0x0007
+ QUAD_STRIP = 0x0008
+ TRIANGLES = 0x0004
+ TRIANGLES_ADJACENCY = 0x000C
+ TRIANGLE_FAN = 0x0006
+ TRIANGLE_STRIP = 0x0005
+ TRIANGLE_STRIP_ADJACENCY = 0x000D
+
+ FEEDBACK = 0x1C01
+ RENDER = 0x1C00
+ SELECT = 0x1C02
+
+ FLAT = 0x1D00
+ SMOOTH = 0x1D01
+
+ DECR = 0x1E03
+ INCR = 0x1E02
+ KEEP = 0x1E00
+
+ EXTENSIONS = 0x1F03
+ RENDERER = 0x1F01
+ VENDOR = 0x1F00
+ VERSION = 0x1F02
+
+ S = 0x2000
+ T = 0x2001
+ R = 0x2002
+ Q = 0x2003
+
+ DECAL = 0x2101
+
+ TEXTURE_ENV_COLOR = 0x2201
+ TEXTURE_ENV_MODE = 0x2200
+
+ TEXTURE_ENV = 0x2300
+
+ EYE_LINEAR = 0x2400
+ OBJECT_LINEAR = 0x2401
+ SPHERE_MAP = 0x2402
+
+ EYE_PLANE = 0x2502
+ OBJECT_PLANE = 0x2501
+ TEXTURE_GEN_MODE = 0x2500
+
+ NEAREST = 0x2600
+
+ LINEAR_MIPMAP_LINEAR = 0x2703
+ LINEAR_MIPMAP_NEAREST = 0x2701
+ NEAREST_MIPMAP_LINEAR = 0x2702
+ NEAREST_MIPMAP_NEAREST = 0x2700
+
+ GENERATE_MIPMAP = 0x8191
+ TEXTURE_WRAP_R = 0x8072
+
+ PROXY_TEXTURE_1D = 0x8063
+ PROXY_TEXTURE_2D = 0x8064
+ PROXY_TEXTURE_3D = 0x8070
+ TEXTURE_3D = 0x806F
+ TEXTURE_BASE_LEVEL = 0x813C
+ TEXTURE_MAX_LEVEL = 0x813D
+ TEXTURE_MAX_LOD = 0x813B
+ TEXTURE_MIN_LOD = 0x813A
+
+ CLAMP = 0x2900
+ CLAMP_TO_BORDER = 0x812D
+ CLAMP_TO_EDGE = 0x812F
+ REPEAT = 0x2901
+
+ SYNC_FLUSH_COMMANDS_BIT = 0x00000001
+ INVALID_INDEX = 0xFFFFFFFF
+ TIMEOUT_IGNORED = 0xFFFFFFFFFFFFFFFF
+ CONSTANT_COLOR = 0x8001
+ ONE_MINUS_CONSTANT_COLOR = 0x8002
+ CONSTANT_ALPHA = 0x8003
+ ONE_MINUS_CONSTANT_ALPHA = 0x8004
+ FUNC_ADD = 0x8006
+ MIN = 0x8007
+ MAX = 0x8008
+ BLEND_EQUATION_RGB = 0x8009
+ FUNC_SUBTRACT = 0x800A
+ FUNC_REVERSE_SUBTRACT = 0x800B
+ RESCALE_NORMAL = 0x803A
+ TEXTURE_DEPTH = 0x8071
+ MAX_3D_TEXTURE_SIZE = 0x8073
+ MULTISAMPLE = 0x809D
+ SAMPLE_ALPHA_TO_COVERAGE = 0x809E
+ SAMPLE_ALPHA_TO_ONE = 0x809F
+ SAMPLE_COVERAGE = 0x80A0
+ SAMPLE_BUFFERS = 0x80A8
+ SAMPLES = 0x80A9
+ SAMPLE_COVERAGE_VALUE = 0x80AA
+ SAMPLE_COVERAGE_INVERT = 0x80AB
+ BLEND_DST_RGB = 0x80C8
+ BLEND_SRC_RGB = 0x80C9
+ BLEND_DST_ALPHA = 0x80CA
+ BLEND_SRC_ALPHA = 0x80CB
+ BGR = 0x80E0
+ BGRA = 0x80E1
+ MAX_ELEMENTS_VERTICES = 0x80E8
+ MAX_ELEMENTS_INDICES = 0x80E9
+ DEPTH_COMPONENT16 = 0x81A5
+ DEPTH_COMPONENT24 = 0x81A6
+ DEPTH_COMPONENT32 = 0x81A7
+ FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING = 0x8210
+ FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE = 0x8211
+ FRAMEBUFFER_ATTACHMENT_RED_SIZE = 0x8212
+ FRAMEBUFFER_ATTACHMENT_GREEN_SIZE = 0x8213
+ FRAMEBUFFER_ATTACHMENT_BLUE_SIZE = 0x8214
+ FRAMEBUFFER_ATTACHMENT_ALPHA_SIZE = 0x8215
+ FRAMEBUFFER_ATTACHMENT_DEPTH_SIZE = 0x8216
+ FRAMEBUFFER_ATTACHMENT_STENCIL_SIZE = 0x8217
+ FRAMEBUFFER_DEFAULT = 0x8218
+ FRAMEBUFFER_UNDEFINED = 0x8219
+ DEPTH_STENCIL_ATTACHMENT = 0x821A
+ MAJOR_VERSION = 0x821B
+ MINOR_VERSION = 0x821C
+ NUM_EXTENSIONS = 0x821D
+ CONTEXT_FLAGS = 0x821E
+ INDEX = 0x8222
+ COMPRESSED_RED = 0x8225
+ COMPRESSED_RG = 0x8226
+ RG = 0x8227
+ RG_INTEGER = 0x8228
+ R8 = 0x8229
+ R16 = 0x822A
+ RG8 = 0x822B
+ RG16 = 0x822C
+ R16F = 0x822D
+ R32F = 0x822E
+ RG16F = 0x822F
+ RG32F = 0x8230
+ R8I = 0x8231
+ R8UI = 0x8232
+ R16I = 0x8233
+ R16UI = 0x8234
+ R32I = 0x8235
+ R32UI = 0x8236
+ RG8I = 0x8237
+ RG8UI = 0x8238
+ RG16I = 0x8239
+ RG16UI = 0x823A
+ RG32I = 0x823B
+ RG32UI = 0x823C
+ UNSIGNED_BYTE_2_3_3_REV = 0x8362
+ UNSIGNED_SHORT_5_6_5 = 0x8363
+ UNSIGNED_SHORT_5_6_5_REV = 0x8364
+ UNSIGNED_SHORT_4_4_4_4_REV = 0x8365
+ UNSIGNED_SHORT_1_5_5_5_REV = 0x8366
+ UNSIGNED_INT_8_8_8_8_REV = 0x8367
+ UNSIGNED_INT_2_10_10_10_REV = 0x8368
+ MIRRORED_REPEAT = 0x8370
+ FOG_COORDINATE_SOURCE = 0x8450
+ FOG_COORD_SRC = 0x8450
+ FOG_COORDINATE = 0x8451
+ FOG_COORD = 0x8451
+ FRAGMENT_DEPTH = 0x8452
+ CURRENT_FOG_COORDINATE = 0x8453
+ CURRENT_FOG_COORD = 0x8453
+ FOG_COORDINATE_ARRAY_TYPE = 0x8454
+ FOG_COORD_ARRAY_TYPE = 0x8454
+ FOG_COORDINATE_ARRAY_STRIDE = 0x8455
+ FOG_COORD_ARRAY_STRIDE = 0x8455
+ FOG_COORDINATE_ARRAY_POINTER = 0x8456
+ FOG_COORD_ARRAY_POINTER = 0x8456
+ FOG_COORDINATE_ARRAY = 0x8457
+ FOG_COORD_ARRAY = 0x8457
+ COLOR_SUM = 0x8458
+ CURRENT_SECONDARY_COLOR = 0x8459
+ SECONDARY_COLOR_ARRAY_SIZE = 0x845A
+ SECONDARY_COLOR_ARRAY_TYPE = 0x845B
+ SECONDARY_COLOR_ARRAY_STRIDE = 0x845C
+ SECONDARY_COLOR_ARRAY_POINTER = 0x845D
+ SECONDARY_COLOR_ARRAY = 0x845E
+ CURRENT_RASTER_SECONDARY_COLOR = 0x845F
+ TEXTURE0 = 0x84C0
+ TEXTURE1 = 0x84C1
+ TEXTURE2 = 0x84C2
+ TEXTURE3 = 0x84C3
+ TEXTURE4 = 0x84C4
+ TEXTURE5 = 0x84C5
+ TEXTURE6 = 0x84C6
+ TEXTURE7 = 0x84C7
+ TEXTURE8 = 0x84C8
+ TEXTURE9 = 0x84C9
+ TEXTURE10 = 0x84CA
+ TEXTURE11 = 0x84CB
+ TEXTURE12 = 0x84CC
+ TEXTURE13 = 0x84CD
+ TEXTURE14 = 0x84CE
+ TEXTURE15 = 0x84CF
+ TEXTURE16 = 0x84D0
+ TEXTURE17 = 0x84D1
+ TEXTURE18 = 0x84D2
+ TEXTURE19 = 0x84D3
+ TEXTURE20 = 0x84D4
+ TEXTURE21 = 0x84D5
+ TEXTURE22 = 0x84D6
+ TEXTURE23 = 0x84D7
+ TEXTURE24 = 0x84D8
+ TEXTURE25 = 0x84D9
+ TEXTURE26 = 0x84DA
+ TEXTURE27 = 0x84DB
+ TEXTURE28 = 0x84DC
+ TEXTURE29 = 0x84DD
+ TEXTURE30 = 0x84DE
+ TEXTURE31 = 0x84DF
+ ACTIVE_TEXTURE = 0x84E0
+ CLIENT_ACTIVE_TEXTURE = 0x84E1
+ MAX_TEXTURE_UNITS = 0x84E2
+ TRANSPOSE_MODELVIEW_MATRIX = 0x84E3
+ TRANSPOSE_PROJECTION_MATRIX = 0x84E4
+ TRANSPOSE_TEXTURE_MATRIX = 0x84E5
+ TRANSPOSE_COLOR_MATRIX = 0x84E6
+ SUBTRACT = 0x84E7
+ MAX_RENDERBUFFER_SIZE = 0x84E8
+ COMPRESSED_ALPHA = 0x84E9
+ COMPRESSED_LUMINANCE = 0x84EA
+ COMPRESSED_LUMINANCE_ALPHA = 0x84EB
+ COMPRESSED_INTENSITY = 0x84EC
+ COMPRESSED_RGB = 0x84ED
+ COMPRESSED_RGBA = 0x84EE
+ TEXTURE_RECTANGLE = 0x84F5
+ TEXTURE_BINDING_RECTANGLE = 0x84F6
+ PROXY_TEXTURE_RECTANGLE = 0x84F7
+ MAX_RECTANGLE_TEXTURE_SIZE = 0x84F8
+ DEPTH_STENCIL = 0x84F9
+ UNSIGNED_INT_24_8 = 0x84FA
+ MAX_TEXTURE_LOD_BIAS = 0x84FD
+ TEXTURE_FILTER_CONTROL = 0x8500
+ TEXTURE_LOD_BIAS = 0x8501
+ INCR_WRAP = 0x8507
+ DECR_WRAP = 0x8508
+ NORMAL_MAP = 0x8511
+ REFLECTION_MAP = 0x8512
+ TEXTURE_CUBE_MAP = 0x8513
+ TEXTURE_BINDING_CUBE_MAP = 0x8514
+ TEXTURE_CUBE_MAP_POSITIVE_X = 0x8515
+ TEXTURE_CUBE_MAP_NEGATIVE_X = 0x8516
+ TEXTURE_CUBE_MAP_POSITIVE_Y = 0x8517
+ TEXTURE_CUBE_MAP_NEGATIVE_Y = 0x8518
+ TEXTURE_CUBE_MAP_POSITIVE_Z = 0x8519
+ TEXTURE_CUBE_MAP_NEGATIVE_Z = 0x851A
+ PROXY_TEXTURE_CUBE_MAP = 0x851B
+ MAX_CUBE_MAP_TEXTURE_SIZE = 0x851C
+ COMBINE = 0x8570
+ COMBINE_RGB = 0x8571
+ COMBINE_ALPHA = 0x8572
+ RGB_SCALE = 0x8573
+ ADD_SIGNED = 0x8574
+ INTERPOLATE = 0x8575
+ CONSTANT = 0x8576
+ PRIMARY_COLOR = 0x8577
+ PREVIOUS = 0x8578
+ SOURCE0_RGB = 0x8580
+ SRC0_RGB = 0x8580
+ SOURCE1_RGB = 0x8581
+ SRC1_RGB = 0x8581
+ SOURCE2_RGB = 0x8582
+ SRC2_RGB = 0x8582
+ SOURCE0_ALPHA = 0x8588
+ SRC0_ALPHA = 0x8588
+ SOURCE1_ALPHA = 0x8589
+ SRC1_ALPHA = 0x8589
+ SOURCE2_ALPHA = 0x858A
+ SRC2_ALPHA = 0x858A
+ OPERAND0_RGB = 0x8590
+ OPERAND1_RGB = 0x8591
+ OPERAND2_RGB = 0x8592
+ OPERAND0_ALPHA = 0x8598
+ OPERAND1_ALPHA = 0x8599
+ OPERAND2_ALPHA = 0x859A
+ VERTEX_ARRAY_BINDING = 0x85B5
+ VERTEX_ATTRIB_ARRAY_ENABLED = 0x8622
+ VERTEX_ATTRIB_ARRAY_SIZE = 0x8623
+ VERTEX_ATTRIB_ARRAY_STRIDE = 0x8624
+ VERTEX_ATTRIB_ARRAY_TYPE = 0x8625
+ CURRENT_VERTEX_ATTRIB = 0x8626
+ VERTEX_PROGRAM_POINT_SIZE = 0x8642
+ PROGRAM_POINT_SIZE = 0x8642
+ VERTEX_PROGRAM_TWO_SIDE = 0x8643
+ VERTEX_ATTRIB_ARRAY_POINTER = 0x8645
+ DEPTH_CLAMP = 0x864F
+ TEXTURE_COMPRESSED_IMAGE_SIZE = 0x86A0
+ TEXTURE_COMPRESSED = 0x86A1
+ NUM_COMPRESSED_TEXTURE_FORMATS = 0x86A2
+ COMPRESSED_TEXTURE_FORMATS = 0x86A3
+ DOT3_RGB = 0x86AE
+ DOT3_RGBA = 0x86AF
+ BUFFER_SIZE = 0x8764
+ BUFFER_USAGE = 0x8765
+ STENCIL_BACK_FUNC = 0x8800
+ STENCIL_BACK_FAIL = 0x8801
+ STENCIL_BACK_PASS_DEPTH_FAIL = 0x8802
+ STENCIL_BACK_PASS_DEPTH_PASS = 0x8803
+ RGBA32F = 0x8814
+ RGB32F = 0x8815
+ RGBA16F = 0x881A
+ RGB16F = 0x881B
+ MAX_DRAW_BUFFERS = 0x8824
+ DRAW_BUFFER0 = 0x8825
+ DRAW_BUFFER1 = 0x8826
+ DRAW_BUFFER2 = 0x8827
+ DRAW_BUFFER3 = 0x8828
+ DRAW_BUFFER4 = 0x8829
+ DRAW_BUFFER5 = 0x882A
+ DRAW_BUFFER6 = 0x882B
+ DRAW_BUFFER7 = 0x882C
+ DRAW_BUFFER8 = 0x882D
+ DRAW_BUFFER9 = 0x882E
+ DRAW_BUFFER10 = 0x882F
+ DRAW_BUFFER11 = 0x8830
+ DRAW_BUFFER12 = 0x8831
+ DRAW_BUFFER13 = 0x8832
+ DRAW_BUFFER14 = 0x8833
+ DRAW_BUFFER15 = 0x8834
+ BLEND_EQUATION_ALPHA = 0x883D
+ TEXTURE_DEPTH_SIZE = 0x884A
+ DEPTH_TEXTURE_MODE = 0x884B
+ TEXTURE_COMPARE_MODE = 0x884C
+ TEXTURE_COMPARE_FUNC = 0x884D
+ COMPARE_R_TO_TEXTURE = 0x884E
+ COMPARE_REF_TO_TEXTURE = 0x884E
+ TEXTURE_CUBE_MAP_SEAMLESS = 0x884F
+ POINT_SPRITE = 0x8861
+ COORD_REPLACE = 0x8862
+ QUERY_COUNTER_BITS = 0x8864
+ CURRENT_QUERY = 0x8865
+ QUERY_RESULT = 0x8866
+ QUERY_RESULT_AVAILABLE = 0x8867
+ MAX_VERTEX_ATTRIBS = 0x8869
+ VERTEX_ATTRIB_ARRAY_NORMALIZED = 0x886A
+ MAX_TEXTURE_COORDS = 0x8871
+ MAX_TEXTURE_IMAGE_UNITS = 0x8872
+ ARRAY_BUFFER = 0x8892
+ ELEMENT_ARRAY_BUFFER = 0x8893
+ ARRAY_BUFFER_BINDING = 0x8894
+ ELEMENT_ARRAY_BUFFER_BINDING = 0x8895
+ VERTEX_ARRAY_BUFFER_BINDING = 0x8896
+ NORMAL_ARRAY_BUFFER_BINDING = 0x8897
+ COLOR_ARRAY_BUFFER_BINDING = 0x8898
+ INDEX_ARRAY_BUFFER_BINDING = 0x8899
+ TEXTURE_COORD_ARRAY_BUFFER_BINDING = 0x889A
+ EDGE_FLAG_ARRAY_BUFFER_BINDING = 0x889B
+ SECONDARY_COLOR_ARRAY_BUFFER_BINDING = 0x889C
+ FOG_COORDINATE_ARRAY_BUFFER_BINDING = 0x889D
+ FOG_COORD_ARRAY_BUFFER_BINDING = 0x889D
+ WEIGHT_ARRAY_BUFFER_BINDING = 0x889E
+ VERTEX_ATTRIB_ARRAY_BUFFER_BINDING = 0x889F
+ READ_ONLY = 0x88B8
+ WRITE_ONLY = 0x88B9
+ READ_WRITE = 0x88BA
+ BUFFER_ACCESS = 0x88BB
+ BUFFER_MAPPED = 0x88BC
+ BUFFER_MAP_POINTER = 0x88BD
+ TIME_ELAPSED = 0x88BF
+ STREAM_DRAW = 0x88E0
+ STREAM_READ = 0x88E1
+ STREAM_COPY = 0x88E2
+ STATIC_DRAW = 0x88E4
+ STATIC_READ = 0x88E5
+ STATIC_COPY = 0x88E6
+ DYNAMIC_DRAW = 0x88E8
+ DYNAMIC_READ = 0x88E9
+ DYNAMIC_COPY = 0x88EA
+ PIXEL_PACK_BUFFER = 0x88EB
+ PIXEL_UNPACK_BUFFER = 0x88EC
+ PIXEL_PACK_BUFFER_BINDING = 0x88ED
+ PIXEL_UNPACK_BUFFER_BINDING = 0x88EF
+ DEPTH24_STENCIL8 = 0x88F0
+ TEXTURE_STENCIL_SIZE = 0x88F1
+ SRC1_COLOR = 0x88F9
+ ONE_MINUS_SRC1_COLOR = 0x88FA
+ ONE_MINUS_SRC1_ALPHA = 0x88FB
+ MAX_DUAL_SOURCE_DRAW_BUFFERS = 0x88FC
+ VERTEX_ATTRIB_ARRAY_INTEGER = 0x88FD
+ VERTEX_ATTRIB_ARRAY_DIVISOR = 0x88FE
+ MAX_ARRAY_TEXTURE_LAYERS = 0x88FF
+ MIN_PROGRAM_TEXEL_OFFSET = 0x8904
+ MAX_PROGRAM_TEXEL_OFFSET = 0x8905
+ SAMPLES_PASSED = 0x8914
+ GEOMETRY_VERTICES_OUT = 0x8916
+ GEOMETRY_INPUT_TYPE = 0x8917
+ GEOMETRY_OUTPUT_TYPE = 0x8918
+ SAMPLER_BINDING = 0x8919
+ CLAMP_VERTEX_COLOR = 0x891A
+ CLAMP_FRAGMENT_COLOR = 0x891B
+ CLAMP_READ_COLOR = 0x891C
+ FIXED_ONLY = 0x891D
+ UNIFORM_BUFFER = 0x8A11
+ UNIFORM_BUFFER_BINDING = 0x8A28
+ UNIFORM_BUFFER_START = 0x8A29
+ UNIFORM_BUFFER_SIZE = 0x8A2A
+ MAX_VERTEX_UNIFORM_BLOCKS = 0x8A2B
+ MAX_GEOMETRY_UNIFORM_BLOCKS = 0x8A2C
+ MAX_FRAGMENT_UNIFORM_BLOCKS = 0x8A2D
+ MAX_COMBINED_UNIFORM_BLOCKS = 0x8A2E
+ MAX_UNIFORM_BUFFER_BINDINGS = 0x8A2F
+ MAX_UNIFORM_BLOCK_SIZE = 0x8A30
+ MAX_COMBINED_VERTEX_UNIFORM_COMPONENTS = 0x8A31
+ MAX_COMBINED_GEOMETRY_UNIFORM_COMPONENTS = 0x8A32
+ MAX_COMBINED_FRAGMENT_UNIFORM_COMPONENTS = 0x8A33
+ UNIFORM_BUFFER_OFFSET_ALIGNMENT = 0x8A34
+ ACTIVE_UNIFORM_BLOCK_MAX_NAME_LENGTH = 0x8A35
+ ACTIVE_UNIFORM_BLOCKS = 0x8A36
+ UNIFORM_TYPE = 0x8A37
+ UNIFORM_SIZE = 0x8A38
+ UNIFORM_NAME_LENGTH = 0x8A39
+ UNIFORM_BLOCK_INDEX = 0x8A3A
+ UNIFORM_OFFSET = 0x8A3B
+ UNIFORM_ARRAY_STRIDE = 0x8A3C
+ UNIFORM_MATRIX_STRIDE = 0x8A3D
+ UNIFORM_IS_ROW_MAJOR = 0x8A3E
+ UNIFORM_BLOCK_BINDING = 0x8A3F
+ UNIFORM_BLOCK_DATA_SIZE = 0x8A40
+ UNIFORM_BLOCK_NAME_LENGTH = 0x8A41
+ UNIFORM_BLOCK_ACTIVE_UNIFORMS = 0x8A42
+ UNIFORM_BLOCK_ACTIVE_UNIFORM_INDICES = 0x8A43
+ UNIFORM_BLOCK_REFERENCED_BY_VERTEX_SHADER = 0x8A44
+ UNIFORM_BLOCK_REFERENCED_BY_GEOMETRY_SHADER = 0x8A45
+ UNIFORM_BLOCK_REFERENCED_BY_FRAGMENT_SHADER = 0x8A46
+ FRAGMENT_SHADER = 0x8B30
+ VERTEX_SHADER = 0x8B31
+ MAX_FRAGMENT_UNIFORM_COMPONENTS = 0x8B49
+ MAX_VERTEX_UNIFORM_COMPONENTS = 0x8B4A
+ MAX_VARYING_FLOATS = 0x8B4B
+ MAX_VARYING_COMPONENTS = 0x8B4B
+ MAX_VERTEX_TEXTURE_IMAGE_UNITS = 0x8B4C
+ MAX_COMBINED_TEXTURE_IMAGE_UNITS = 0x8B4D
+ SHADER_TYPE = 0x8B4F
+ FLOAT_VEC2 = 0x8B50
+ FLOAT_VEC3 = 0x8B51
+ FLOAT_VEC4 = 0x8B52
+ INT_VEC2 = 0x8B53
+ INT_VEC3 = 0x8B54
+ INT_VEC4 = 0x8B55
+ BOOL = 0x8B56
+ BOOL_VEC2 = 0x8B57
+ BOOL_VEC3 = 0x8B58
+ BOOL_VEC4 = 0x8B59
+ FLOAT_MAT2 = 0x8B5A
+ FLOAT_MAT3 = 0x8B5B
+ FLOAT_MAT4 = 0x8B5C
+ SAMPLER_1D = 0x8B5D
+ SAMPLER_2D = 0x8B5E
+ SAMPLER_3D = 0x8B5F
+ SAMPLER_CUBE = 0x8B60
+ SAMPLER_1D_SHADOW = 0x8B61
+ SAMPLER_2D_SHADOW = 0x8B62
+ SAMPLER_2D_RECT = 0x8B63
+ SAMPLER_2D_RECT_SHADOW = 0x8B64
+ FLOAT_MAT2x3 = 0x8B65
+ FLOAT_MAT2x4 = 0x8B66
+ FLOAT_MAT3x2 = 0x8B67
+ FLOAT_MAT3x4 = 0x8B68
+ FLOAT_MAT4x2 = 0x8B69
+ FLOAT_MAT4x3 = 0x8B6A
+ DELETE_STATUS = 0x8B80
+ COMPILE_STATUS = 0x8B81
+ LINK_STATUS = 0x8B82
+ VALIDATE_STATUS = 0x8B83
+ INFO_LOG_LENGTH = 0x8B84
+ ATTACHED_SHADERS = 0x8B85
+ ACTIVE_UNIFORMS = 0x8B86
+ ACTIVE_UNIFORM_MAX_LENGTH = 0x8B87
+ SHADER_SOURCE_LENGTH = 0x8B88
+ ACTIVE_ATTRIBUTES = 0x8B89
+ ACTIVE_ATTRIBUTE_MAX_LENGTH = 0x8B8A
+ SHADING_LANGUAGE_VERSION = 0x8B8C
+ CURRENT_PROGRAM = 0x8B8D
+ TEXTURE_RED_TYPE = 0x8C10
+ TEXTURE_GREEN_TYPE = 0x8C11
+ TEXTURE_BLUE_TYPE = 0x8C12
+ TEXTURE_ALPHA_TYPE = 0x8C13
+ TEXTURE_LUMINANCE_TYPE = 0x8C14
+ TEXTURE_INTENSITY_TYPE = 0x8C15
+ TEXTURE_DEPTH_TYPE = 0x8C16
+ UNSIGNED_NORMALIZED = 0x8C17
+ TEXTURE_1D_ARRAY = 0x8C18
+ PROXY_TEXTURE_1D_ARRAY = 0x8C19
+ TEXTURE_2D_ARRAY = 0x8C1A
+ PROXY_TEXTURE_2D_ARRAY = 0x8C1B
+ TEXTURE_BINDING_1D_ARRAY = 0x8C1C
+ TEXTURE_BINDING_2D_ARRAY = 0x8C1D
+ MAX_GEOMETRY_TEXTURE_IMAGE_UNITS = 0x8C29
+ TEXTURE_BUFFER = 0x8C2A
+ MAX_TEXTURE_BUFFER_SIZE = 0x8C2B
+ TEXTURE_BINDING_BUFFER = 0x8C2C
+ TEXTURE_BUFFER_DATA_STORE_BINDING = 0x8C2D
+ ANY_SAMPLES_PASSED = 0x8C2F
+ R11F_G11F_B10F = 0x8C3A
+ UNSIGNED_INT_10F_11F_11F_REV = 0x8C3B
+ RGB9_E5 = 0x8C3D
+ UNSIGNED_INT_5_9_9_9_REV = 0x8C3E
+ TEXTURE_SHARED_SIZE = 0x8C3F
+ SRGB = 0x8C40
+ SRGB8 = 0x8C41
+ SRGB_ALPHA = 0x8C42
+ SRGB8_ALPHA8 = 0x8C43
+ SLUMINANCE_ALPHA = 0x8C44
+ SLUMINANCE8_ALPHA8 = 0x8C45
+ SLUMINANCE = 0x8C46
+ SLUMINANCE8 = 0x8C47
+ COMPRESSED_SRGB = 0x8C48
+ COMPRESSED_SRGB_ALPHA = 0x8C49
+ COMPRESSED_SLUMINANCE = 0x8C4A
+ COMPRESSED_SLUMINANCE_ALPHA = 0x8C4B
+ TRANSFORM_FEEDBACK_VARYING_MAX_LENGTH = 0x8C76
+ TRANSFORM_FEEDBACK_BUFFER_MODE = 0x8C7F
+ MAX_TRANSFORM_FEEDBACK_SEPARATE_COMPONENTS = 0x8C80
+ TRANSFORM_FEEDBACK_VARYINGS = 0x8C83
+ TRANSFORM_FEEDBACK_BUFFER_START = 0x8C84
+ TRANSFORM_FEEDBACK_BUFFER_SIZE = 0x8C85
+ PRIMITIVES_GENERATED = 0x8C87
+ TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN = 0x8C88
+ RASTERIZER_DISCARD = 0x8C89
+ MAX_TRANSFORM_FEEDBACK_INTERLEAVED_COMPONENTS = 0x8C8A
+ MAX_TRANSFORM_FEEDBACK_SEPARATE_ATTRIBS = 0x8C8B
+ INTERLEAVED_ATTRIBS = 0x8C8C
+ SEPARATE_ATTRIBS = 0x8C8D
+ TRANSFORM_FEEDBACK_BUFFER = 0x8C8E
+ TRANSFORM_FEEDBACK_BUFFER_BINDING = 0x8C8F
+ POINT_SPRITE_COORD_ORIGIN = 0x8CA0
+ LOWER_LEFT = 0x8CA1
+ UPPER_LEFT = 0x8CA2
+ STENCIL_BACK_REF = 0x8CA3
+ STENCIL_BACK_VALUE_MASK = 0x8CA4
+ STENCIL_BACK_WRITEMASK = 0x8CA5
+ DRAW_FRAMEBUFFER_BINDING = 0x8CA6
+ FRAMEBUFFER_BINDING = 0x8CA6
+ RENDERBUFFER_BINDING = 0x8CA7
+ READ_FRAMEBUFFER = 0x8CA8
+ DRAW_FRAMEBUFFER = 0x8CA9
+ READ_FRAMEBUFFER_BINDING = 0x8CAA
+ RENDERBUFFER_SAMPLES = 0x8CAB
+ DEPTH_COMPONENT32F = 0x8CAC
+ DEPTH32F_STENCIL8 = 0x8CAD
+ FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE = 0x8CD0
+ FRAMEBUFFER_ATTACHMENT_OBJECT_NAME = 0x8CD1
+ FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL = 0x8CD2
+ FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE = 0x8CD3
+ FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER = 0x8CD4
+ FRAMEBUFFER_COMPLETE = 0x8CD5
+ FRAMEBUFFER_INCOMPLETE_ATTACHMENT = 0x8CD6
+ FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT = 0x8CD7
+ FRAMEBUFFER_INCOMPLETE_DRAW_BUFFER = 0x8CDB
+ FRAMEBUFFER_INCOMPLETE_READ_BUFFER = 0x8CDC
+ FRAMEBUFFER_UNSUPPORTED = 0x8CDD
+ MAX_COLOR_ATTACHMENTS = 0x8CDF
+ COLOR_ATTACHMENT0 = 0x8CE0
+ COLOR_ATTACHMENT1 = 0x8CE1
+ COLOR_ATTACHMENT2 = 0x8CE2
+ COLOR_ATTACHMENT3 = 0x8CE3
+ COLOR_ATTACHMENT4 = 0x8CE4
+ COLOR_ATTACHMENT5 = 0x8CE5
+ COLOR_ATTACHMENT6 = 0x8CE6
+ COLOR_ATTACHMENT7 = 0x8CE7
+ COLOR_ATTACHMENT8 = 0x8CE8
+ COLOR_ATTACHMENT9 = 0x8CE9
+ COLOR_ATTACHMENT10 = 0x8CEA
+ COLOR_ATTACHMENT11 = 0x8CEB
+ COLOR_ATTACHMENT12 = 0x8CEC
+ COLOR_ATTACHMENT13 = 0x8CED
+ COLOR_ATTACHMENT14 = 0x8CEE
+ COLOR_ATTACHMENT15 = 0x8CEF
+ DEPTH_ATTACHMENT = 0x8D00
+ STENCIL_ATTACHMENT = 0x8D20
+ FRAMEBUFFER = 0x8D40
+ RENDERBUFFER = 0x8D41
+ RENDERBUFFER_WIDTH = 0x8D42
+ RENDERBUFFER_HEIGHT = 0x8D43
+ RENDERBUFFER_INTERNAL_FORMAT = 0x8D44
+ STENCIL_INDEX1 = 0x8D46
+ STENCIL_INDEX4 = 0x8D47
+ STENCIL_INDEX8 = 0x8D48
+ STENCIL_INDEX16 = 0x8D49
+ RENDERBUFFER_RED_SIZE = 0x8D50
+ RENDERBUFFER_GREEN_SIZE = 0x8D51
+ RENDERBUFFER_BLUE_SIZE = 0x8D52
+ RENDERBUFFER_ALPHA_SIZE = 0x8D53
+ RENDERBUFFER_DEPTH_SIZE = 0x8D54
+ RENDERBUFFER_STENCIL_SIZE = 0x8D55
+ FRAMEBUFFER_INCOMPLETE_MULTISAMPLE = 0x8D56
+ MAX_SAMPLES = 0x8D57
+ RGBA32UI = 0x8D70
+ RGB32UI = 0x8D71
+ RGBA16UI = 0x8D76
+ RGB16UI = 0x8D77
+ RGBA8UI = 0x8D7C
+ RGB8UI = 0x8D7D
+ RGBA32I = 0x8D82
+ RGB32I = 0x8D83
+ RGBA16I = 0x8D88
+ RGB16I = 0x8D89
+ RGBA8I = 0x8D8E
+ RGB8I = 0x8D8F
+ RED_INTEGER = 0x8D94
+ GREEN_INTEGER = 0x8D95
+ BLUE_INTEGER = 0x8D96
+ ALPHA_INTEGER = 0x8D97
+ RGB_INTEGER = 0x8D98
+ RGBA_INTEGER = 0x8D99
+ BGR_INTEGER = 0x8D9A
+ BGRA_INTEGER = 0x8D9B
+ INT_2_10_10_10_REV = 0x8D9F
+ FRAMEBUFFER_ATTACHMENT_LAYERED = 0x8DA7
+ FRAMEBUFFER_INCOMPLETE_LAYER_TARGETS = 0x8DA8
+ FLOAT_32_UNSIGNED_INT_24_8_REV = 0x8DAD
+ FRAMEBUFFER_SRGB = 0x8DB9
+ COMPRESSED_RED_RGTC1 = 0x8DBB
+ COMPRESSED_SIGNED_RED_RGTC1 = 0x8DBC
+ COMPRESSED_RG_RGTC2 = 0x8DBD
+ COMPRESSED_SIGNED_RG_RGTC2 = 0x8DBE
+ SAMPLER_1D_ARRAY = 0x8DC0
+ SAMPLER_2D_ARRAY = 0x8DC1
+ SAMPLER_BUFFER = 0x8DC2
+ SAMPLER_1D_ARRAY_SHADOW = 0x8DC3
+ SAMPLER_2D_ARRAY_SHADOW = 0x8DC4
+ SAMPLER_CUBE_SHADOW = 0x8DC5
+ UNSIGNED_INT_VEC2 = 0x8DC6
+ UNSIGNED_INT_VEC3 = 0x8DC7
+ UNSIGNED_INT_VEC4 = 0x8DC8
+ INT_SAMPLER_1D = 0x8DC9
+ INT_SAMPLER_2D = 0x8DCA
+ INT_SAMPLER_3D = 0x8DCB
+ INT_SAMPLER_CUBE = 0x8DCC
+ INT_SAMPLER_2D_RECT = 0x8DCD
+ INT_SAMPLER_1D_ARRAY = 0x8DCE
+ INT_SAMPLER_2D_ARRAY = 0x8DCF
+ INT_SAMPLER_BUFFER = 0x8DD0
+ UNSIGNED_INT_SAMPLER_1D = 0x8DD1
+ UNSIGNED_INT_SAMPLER_2D = 0x8DD2
+ UNSIGNED_INT_SAMPLER_3D = 0x8DD3
+ UNSIGNED_INT_SAMPLER_CUBE = 0x8DD4
+ UNSIGNED_INT_SAMPLER_2D_RECT = 0x8DD5
+ UNSIGNED_INT_SAMPLER_1D_ARRAY = 0x8DD6
+ UNSIGNED_INT_SAMPLER_2D_ARRAY = 0x8DD7
+ UNSIGNED_INT_SAMPLER_BUFFER = 0x8DD8
+ GEOMETRY_SHADER = 0x8DD9
+ MAX_GEOMETRY_UNIFORM_COMPONENTS = 0x8DDF
+ MAX_GEOMETRY_OUTPUT_VERTICES = 0x8DE0
+ MAX_GEOMETRY_TOTAL_OUTPUT_COMPONENTS = 0x8DE1
+ QUERY_WAIT = 0x8E13
+ QUERY_NO_WAIT = 0x8E14
+ QUERY_BY_REGION_WAIT = 0x8E15
+ QUERY_BY_REGION_NO_WAIT = 0x8E16
+ TIMESTAMP = 0x8E28
+ TEXTURE_SWIZZLE_R = 0x8E42
+ TEXTURE_SWIZZLE_G = 0x8E43
+ TEXTURE_SWIZZLE_B = 0x8E44
+ TEXTURE_SWIZZLE_A = 0x8E45
+ TEXTURE_SWIZZLE_RGBA = 0x8E46
+ QUADS_FOLLOW_PROVOKING_VERTEX_CONVENTION = 0x8E4C
+ FIRST_VERTEX_CONVENTION = 0x8E4D
+ LAST_VERTEX_CONVENTION = 0x8E4E
+ PROVOKING_VERTEX = 0x8E4F
+ SAMPLE_POSITION = 0x8E50
+ SAMPLE_MASK = 0x8E51
+ SAMPLE_MASK_VALUE = 0x8E52
+ MAX_SAMPLE_MASK_WORDS = 0x8E59
+ COPY_READ_BUFFER = 0x8F36
+ COPY_WRITE_BUFFER = 0x8F37
+ R8_SNORM = 0x8F94
+ RG8_SNORM = 0x8F95
+ RGB8_SNORM = 0x8F96
+ RGBA8_SNORM = 0x8F97
+ R16_SNORM = 0x8F98
+ RG16_SNORM = 0x8F99
+ RGB16_SNORM = 0x8F9A
+ RGBA16_SNORM = 0x8F9B
+ SIGNED_NORMALIZED = 0x8F9C
+ PRIMITIVE_RESTART = 0x8F9D
+ PRIMITIVE_RESTART_INDEX = 0x8F9E
+ RGB10_A2UI = 0x906F
+ TEXTURE_2D_MULTISAMPLE = 0x9100
+ PROXY_TEXTURE_2D_MULTISAMPLE = 0x9101
+ TEXTURE_2D_MULTISAMPLE_ARRAY = 0x9102
+ PROXY_TEXTURE_2D_MULTISAMPLE_ARRAY = 0x9103
+ TEXTURE_BINDING_2D_MULTISAMPLE = 0x9104
+ TEXTURE_BINDING_2D_MULTISAMPLE_ARRAY = 0x9105
+ TEXTURE_SAMPLES = 0x9106
+ TEXTURE_FIXED_SAMPLE_LOCATIONS = 0x9107
+ SAMPLER_2D_MULTISAMPLE = 0x9108
+ INT_SAMPLER_2D_MULTISAMPLE = 0x9109
+ UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE = 0x910A
+ SAMPLER_2D_MULTISAMPLE_ARRAY = 0x910B
+ INT_SAMPLER_2D_MULTISAMPLE_ARRAY = 0x910C
+ UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE_ARRAY = 0x910D
+ MAX_COLOR_TEXTURE_SAMPLES = 0x910E
+ MAX_DEPTH_TEXTURE_SAMPLES = 0x910F
+ MAX_INTEGER_SAMPLES = 0x9110
+ MAX_SERVER_WAIT_TIMEOUT = 0x9111
+ OBJECT_TYPE = 0x9112
+ SYNC_CONDITION = 0x9113
+ SYNC_STATUS = 0x9114
+ SYNC_FLAGS = 0x9115
+ SYNC_FENCE = 0x9116
+ SYNC_GPU_COMMANDS_COMPLETE = 0x9117
+ UNSIGNALED = 0x9118
+ SIGNALED = 0x9119
+ ALREADY_SIGNALED = 0x911A
+ TIMEOUT_EXPIRED = 0x911B
+ CONDITION_SATISFIED = 0x911C
+ WAIT_FAILED = 0x911D
+ BUFFER_ACCESS_FLAGS = 0x911F
+ BUFFER_MAP_LENGTH = 0x9120
+ BUFFER_MAP_OFFSET = 0x9121
+ MAX_VERTEX_OUTPUT_COMPONENTS = 0x9122
+ MAX_GEOMETRY_INPUT_COMPONENTS = 0x9123
+ MAX_GEOMETRY_OUTPUT_COMPONENTS = 0x9124
+ MAX_FRAGMENT_INPUT_COMPONENTS = 0x9125
+ CONTEXT_PROFILE_MASK = 0x9126
+)
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glViewport.xml
+func (gl *GL) Viewport(x, y, width, height int) {
+ C.gl3_3compat_glViewport(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// DepthRange specifies the mapping of depth values from normalized device
+// coordinates to window coordinates.
+//
+// Parameter nearVal specifies the mapping of the near clipping plane to window
+// coordinates (defaults to 0), while farVal specifies the mapping of the far
+// clipping plane to window coordinates (defaults to 1).
+//
+// After clipping and division by w, depth coordinates range from -1 to 1,
+// corresponding to the near and far clipping planes. DepthRange specifies a
+// linear mapping of the normalized depth coordinates in this range to window
+// depth coordinates. Regardless of the actual depth buffer implementation,
+// window coordinate depth values are treated as though they range from 0 through 1
+// (like color components). Thus, the values accepted by DepthRange are both
+// clamped to this range before they are accepted.
+//
+// The default setting of (0, 1) maps the near plane to 0 and the far plane to 1.
+// With this mapping, the depth buffer range is fully utilized.
+//
+// It is not necessary that nearVal be less than farVal. Reverse mappings such as
+// nearVal 1, and farVal 0 are acceptable.
+//
+// GL.INVALID_OPERATION is generated if DepthRange is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) DepthRange(nearVal, farVal float64) {
+ C.gl3_3compat_glDepthRange(gl.funcs, C.GLdouble(nearVal), C.GLdouble(farVal))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsEnabled.xml
+func (gl *GL) IsEnabled(cap glbase.Enum) bool {
+ glresult := C.gl3_3compat_glIsEnabled(gl.funcs, C.GLenum(cap))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTexLevelParameteriv.xml
+func (gl *GL) GetTexLevelParameteriv(target glbase.Enum, level int, pname glbase.Enum, params []int32) {
+ C.gl3_3compat_glGetTexLevelParameteriv(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTexLevelParameterfv.xml
+func (gl *GL) GetTexLevelParameterfv(target glbase.Enum, level int, pname glbase.Enum, params []float32) {
+ C.gl3_3compat_glGetTexLevelParameterfv(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTexParameteriv.xml
+func (gl *GL) GetTexParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl3_3compat_glGetTexParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTexParameterfv.xml
+func (gl *GL) GetTexParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl3_3compat_glGetTexParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTexImage.xml
+func (gl *GL) GetTexImage(target glbase.Enum, level int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3compat_glGetTexImage(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetIntegerv.xml
+func (gl *GL) GetIntegerv(pname glbase.Enum, params []int32) {
+ C.gl3_3compat_glGetIntegerv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetFloatv.xml
+func (gl *GL) GetFloatv(pname glbase.Enum, params []float32) {
+ C.gl3_3compat_glGetFloatv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetError.xml
+func (gl *GL) GetError() glbase.Enum {
+ glresult := C.gl3_3compat_glGetError(gl.funcs)
+ return glbase.Enum(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetDoublev.xml
+func (gl *GL) GetDoublev(pname glbase.Enum, params []float64) {
+ C.gl3_3compat_glGetDoublev(gl.funcs, C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetBooleanv.xml
+func (gl *GL) GetBooleanv(pname glbase.Enum, params []bool) {
+ C.gl3_3compat_glGetBooleanv(gl.funcs, C.GLenum(pname), (*C.GLboolean)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glReadPixels.xml
+func (gl *GL) ReadPixels(x, y, width, height int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3compat_glReadPixels(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glReadBuffer.xml
+func (gl *GL) ReadBuffer(mode glbase.Enum) {
+ C.gl3_3compat_glReadBuffer(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPixelStorei.xml
+func (gl *GL) PixelStorei(pname glbase.Enum, param int32) {
+ C.gl3_3compat_glPixelStorei(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPixelStoref.xml
+func (gl *GL) PixelStoref(pname glbase.Enum, param float32) {
+ C.gl3_3compat_glPixelStoref(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDepthFunc.xml
+func (gl *GL) DepthFunc(glfunc glbase.Enum) {
+ C.gl3_3compat_glDepthFunc(gl.funcs, C.GLenum(glfunc))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glStencilOp.xml
+func (gl *GL) StencilOp(fail, zfail, zpass glbase.Enum) {
+ C.gl3_3compat_glStencilOp(gl.funcs, C.GLenum(fail), C.GLenum(zfail), C.GLenum(zpass))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glStencilFunc.xml
+func (gl *GL) StencilFunc(glfunc glbase.Enum, ref int32, mask uint32) {
+ C.gl3_3compat_glStencilFunc(gl.funcs, C.GLenum(glfunc), C.GLint(ref), C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glLogicOp.xml
+func (gl *GL) LogicOp(opcode glbase.Enum) {
+ C.gl3_3compat_glLogicOp(gl.funcs, C.GLenum(opcode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBlendFunc.xml
+func (gl *GL) BlendFunc(sfactor, dfactor glbase.Enum) {
+ C.gl3_3compat_glBlendFunc(gl.funcs, C.GLenum(sfactor), C.GLenum(dfactor))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFlush.xml
+func (gl *GL) Flush() {
+ C.gl3_3compat_glFlush(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFinish.xml
+func (gl *GL) Finish() {
+ C.gl3_3compat_glFinish(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEnable.xml
+func (gl *GL) Enable(cap glbase.Enum) {
+ C.gl3_3compat_glEnable(gl.funcs, C.GLenum(cap))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDisable.xml
+func (gl *GL) Disable(cap glbase.Enum) {
+ C.gl3_3compat_glDisable(gl.funcs, C.GLenum(cap))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDepthMask.xml
+func (gl *GL) DepthMask(flag bool) {
+ C.gl3_3compat_glDepthMask(gl.funcs, *(*C.GLboolean)(unsafe.Pointer(&flag)))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColorMask.xml
+func (gl *GL) ColorMask(red, green, blue, alpha bool) {
+ C.gl3_3compat_glColorMask(gl.funcs, *(*C.GLboolean)(unsafe.Pointer(&red)), *(*C.GLboolean)(unsafe.Pointer(&green)), *(*C.GLboolean)(unsafe.Pointer(&blue)), *(*C.GLboolean)(unsafe.Pointer(&alpha)))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glStencilMask.xml
+func (gl *GL) StencilMask(mask uint32) {
+ C.gl3_3compat_glStencilMask(gl.funcs, C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClearDepth.xml
+func (gl *GL) ClearDepth(depth float64) {
+ C.gl3_3compat_glClearDepth(gl.funcs, C.GLdouble(depth))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClearStencil.xml
+func (gl *GL) ClearStencil(s int32) {
+ C.gl3_3compat_glClearStencil(gl.funcs, C.GLint(s))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClearColor.xml
+func (gl *GL) ClearColor(red, green, blue, alpha float32) {
+ C.gl3_3compat_glClearColor(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClear.xml
+func (gl *GL) Clear(mask glbase.Bitfield) {
+ C.gl3_3compat_glClear(gl.funcs, C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDrawBuffer.xml
+func (gl *GL) DrawBuffer(mode glbase.Enum) {
+ C.gl3_3compat_glDrawBuffer(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexImage2D.xml
+func (gl *GL) TexImage2D(target glbase.Enum, level int, internalFormat int32, width, height, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3compat_glTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexImage1D.xml
+func (gl *GL) TexImage1D(target glbase.Enum, level int, internalFormat int32, width, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3compat_glTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexParameteriv.xml
+func (gl *GL) TexParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl3_3compat_glTexParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexParameteri.xml
+func (gl *GL) TexParameteri(target, pname glbase.Enum, param int32) {
+ C.gl3_3compat_glTexParameteri(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexParameterfv.xml
+func (gl *GL) TexParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl3_3compat_glTexParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexParameterf.xml
+func (gl *GL) TexParameterf(target, pname glbase.Enum, param float32) {
+ C.gl3_3compat_glTexParameterf(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glScissor.xml
+func (gl *GL) Scissor(x, y, width, height int) {
+ C.gl3_3compat_glScissor(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPolygonMode.xml
+func (gl *GL) PolygonMode(face, mode glbase.Enum) {
+ C.gl3_3compat_glPolygonMode(gl.funcs, C.GLenum(face), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPointSize.xml
+func (gl *GL) PointSize(size float32) {
+ C.gl3_3compat_glPointSize(gl.funcs, C.GLfloat(size))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glLineWidth.xml
+func (gl *GL) LineWidth(width float32) {
+ C.gl3_3compat_glLineWidth(gl.funcs, C.GLfloat(width))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glHint.xml
+func (gl *GL) Hint(target, mode glbase.Enum) {
+ C.gl3_3compat_glHint(gl.funcs, C.GLenum(target), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFrontFace.xml
+func (gl *GL) FrontFace(mode glbase.Enum) {
+ C.gl3_3compat_glFrontFace(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCullFace.xml
+func (gl *GL) CullFace(mode glbase.Enum) {
+ C.gl3_3compat_glCullFace(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIndexubv.xml
+func (gl *GL) Indexubv(c []uint8) {
+ C.gl3_3compat_glIndexubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIndexub.xml
+func (gl *GL) Indexub(c uint8) {
+ C.gl3_3compat_glIndexub(gl.funcs, C.GLubyte(c))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsTexture.xml
+func (gl *GL) IsTexture(texture glbase.Texture) bool {
+ glresult := C.gl3_3compat_glIsTexture(gl.funcs, C.GLuint(texture))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// GenTextures returns n texture names in textures. There is no guarantee
+// that the names form a contiguous set of integers; however, it is
+// guaranteed that none of the returned names was in use immediately before
+// the call to GenTextures.
+//
+// The generated textures have no dimensionality; they assume the
+// dimensionality of the texture target to which they are first bound (see
+// BindTexture).
+//
+// Texture names returned by a call to GenTextures are not returned by
+// subsequent calls, unless they are first deleted with DeleteTextures.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// GenTextures is available in GL version 2.0 or greater.
+func (gl *GL) GenTextures(n int) []glbase.Texture {
+ if n == 0 {
+ return nil
+ }
+ textures := make([]glbase.Texture, n)
+ C.gl3_3compat_glGenTextures(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])))
+ return textures
+}
+
+// DeleteTextures deletes the textures objects whose names are stored
+// in the textures slice. After a texture is deleted, it has no contents or
+// dimensionality, and its name is free for reuse (for example by
+// GenTextures). If a texture that is currently bound is deleted, the binding
+// reverts to 0 (the default texture).
+//
+// DeleteTextures silently ignores 0's and names that do not correspond to
+// existing textures.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// DeleteTextures is available in GL version 2.0 or greater.
+func (gl *GL) DeleteTextures(textures []glbase.Texture) {
+ n := len(textures)
+ if n == 0 {
+ return
+ }
+ C.gl3_3compat_glDeleteTextures(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBindTexture.xml
+func (gl *GL) BindTexture(target glbase.Enum, texture glbase.Texture) {
+ C.gl3_3compat_glBindTexture(gl.funcs, C.GLenum(target), C.GLuint(texture))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexSubImage2D.xml
+func (gl *GL) TexSubImage2D(target glbase.Enum, level, xoffset, yoffset, width, height int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3compat_glTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexSubImage1D.xml
+func (gl *GL) TexSubImage1D(target glbase.Enum, level, xoffset, width int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3compat_glTexSubImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLsizei(width), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCopyTexSubImage2D.xml
+func (gl *GL) CopyTexSubImage2D(target glbase.Enum, level, xoffset, yoffset, x, y, width, height int) {
+ C.gl3_3compat_glCopyTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCopyTexSubImage1D.xml
+func (gl *GL) CopyTexSubImage1D(target glbase.Enum, level, xoffset, x, y, width int) {
+ C.gl3_3compat_glCopyTexSubImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(x), C.GLint(y), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCopyTexImage2D.xml
+func (gl *GL) CopyTexImage2D(target glbase.Enum, level int, internalFormat glbase.Enum, x, y, width, height, border int) {
+ C.gl3_3compat_glCopyTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height), C.GLint(border))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCopyTexImage1D.xml
+func (gl *GL) CopyTexImage1D(target glbase.Enum, level int, internalFormat glbase.Enum, x, y, width, border int) {
+ C.gl3_3compat_glCopyTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLint(border))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPolygonOffset.xml
+func (gl *GL) PolygonOffset(factor, units float32) {
+ C.gl3_3compat_glPolygonOffset(gl.funcs, C.GLfloat(factor), C.GLfloat(units))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDrawElements.xml
+func (gl *GL) DrawElements(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3compat_glDrawElements(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDrawArrays.xml
+func (gl *GL) DrawArrays(mode glbase.Enum, first, count int) {
+ C.gl3_3compat_glDrawArrays(gl.funcs, C.GLenum(mode), C.GLint(first), C.GLsizei(count))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCopyTexSubImage3D.xml
+func (gl *GL) CopyTexSubImage3D(target glbase.Enum, level, xoffset, yoffset int, zoffset int32, x, y, width, height int) {
+ C.gl3_3compat_glCopyTexSubImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(zoffset), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexSubImage3D.xml
+func (gl *GL) TexSubImage3D(target glbase.Enum, level, xoffset, yoffset int, zoffset int32, width, height int, depth int32, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3compat_glTexSubImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(zoffset), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexImage3D.xml
+func (gl *GL) TexImage3D(target glbase.Enum, level int, internalFormat int32, width, height int, depth int32, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3compat_glTexImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDrawRangeElements.xml
+func (gl *GL) DrawRangeElements(mode glbase.Enum, start, end uint32, count int, gltype glbase.Enum, indices interface{}) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3compat_glDrawRangeElements(gl.funcs, C.GLenum(mode), C.GLuint(start), C.GLuint(end), C.GLsizei(count), C.GLenum(gltype), indices_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBlendEquation.xml
+func (gl *GL) BlendEquation(mode glbase.Enum) {
+ C.gl3_3compat_glBlendEquation(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBlendColor.xml
+func (gl *GL) BlendColor(red, green, blue, alpha float32) {
+ C.gl3_3compat_glBlendColor(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetCompressedTexImage.xml
+func (gl *GL) GetCompressedTexImage(target glbase.Enum, level int, img interface{}) {
+ var img_ptr unsafe.Pointer
+ var img_v = reflect.ValueOf(img)
+ if img != nil && img_v.Kind() != reflect.Slice {
+ panic("parameter img must be a slice")
+ }
+ if img != nil {
+ img_ptr = unsafe.Pointer(img_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3compat_glGetCompressedTexImage(gl.funcs, C.GLenum(target), C.GLint(level), img_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCompressedTexSubImage1D.xml
+func (gl *GL) CompressedTexSubImage1D(target glbase.Enum, level, xoffset, width int, format glbase.Enum, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3compat_glCompressedTexSubImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLsizei(width), C.GLenum(format), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCompressedTexSubImage2D.xml
+func (gl *GL) CompressedTexSubImage2D(target glbase.Enum, level, xoffset, yoffset, width, height int, format glbase.Enum, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3compat_glCompressedTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCompressedTexSubImage3D.xml
+func (gl *GL) CompressedTexSubImage3D(target glbase.Enum, level, xoffset, yoffset int, zoffset int32, width, height int, depth int32, format glbase.Enum, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3compat_glCompressedTexSubImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(zoffset), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLenum(format), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCompressedTexImage1D.xml
+func (gl *GL) CompressedTexImage1D(target glbase.Enum, level int, internalFormat glbase.Enum, width, border, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3compat_glCompressedTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLsizei(width), C.GLint(border), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCompressedTexImage2D.xml
+func (gl *GL) CompressedTexImage2D(target glbase.Enum, level int, internalFormat glbase.Enum, width, height, border, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3compat_glCompressedTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLint(border), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCompressedTexImage3D.xml
+func (gl *GL) CompressedTexImage3D(target glbase.Enum, level int, internalFormat glbase.Enum, width, height int, depth int32, border, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3compat_glCompressedTexImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLint(border), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSampleCoverage.xml
+func (gl *GL) SampleCoverage(value float32, invert bool) {
+ C.gl3_3compat_glSampleCoverage(gl.funcs, C.GLfloat(value), *(*C.GLboolean)(unsafe.Pointer(&invert)))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glActiveTexture.xml
+func (gl *GL) ActiveTexture(texture glbase.Enum) {
+ C.gl3_3compat_glActiveTexture(gl.funcs, C.GLenum(texture))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPointParameteriv.xml
+func (gl *GL) PointParameteriv(pname glbase.Enum, params []int32) {
+ C.gl3_3compat_glPointParameteriv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPointParameteri.xml
+func (gl *GL) PointParameteri(pname glbase.Enum, param int32) {
+ C.gl3_3compat_glPointParameteri(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPointParameterfv.xml
+func (gl *GL) PointParameterfv(pname glbase.Enum, params []float32) {
+ C.gl3_3compat_glPointParameterfv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPointParameterf.xml
+func (gl *GL) PointParameterf(pname glbase.Enum, param float32) {
+ C.gl3_3compat_glPointParameterf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiDrawArrays.xml
+func (gl *GL) MultiDrawArrays(mode glbase.Enum, first, count []int, drawcount int32) {
+ C.gl3_3compat_glMultiDrawArrays(gl.funcs, C.GLenum(mode), (*C.GLint)(unsafe.Pointer(&first[0])), (*C.GLsizei)(unsafe.Pointer(&count[0])), C.GLsizei(drawcount))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBlendFuncSeparate.xml
+func (gl *GL) BlendFuncSeparate(sfactorRGB, dfactorRGB, sfactorAlpha, dfactorAlpha glbase.Enum) {
+ C.gl3_3compat_glBlendFuncSeparate(gl.funcs, C.GLenum(sfactorRGB), C.GLenum(dfactorRGB), C.GLenum(sfactorAlpha), C.GLenum(dfactorAlpha))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetBufferParameteriv.xml
+func (gl *GL) GetBufferParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl3_3compat_glGetBufferParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glUnmapBuffer.xml
+func (gl *GL) UnmapBuffer(target glbase.Enum) bool {
+ glresult := C.gl3_3compat_glUnmapBuffer(gl.funcs, C.GLenum(target))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetBufferSubData.xml
+func (gl *GL) GetBufferSubData(target glbase.Enum, offset, size int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3compat_glGetBufferSubData(gl.funcs, C.GLenum(target), C.GLintptr(offset), C.GLsizeiptr(size), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBufferSubData.xml
+func (gl *GL) BufferSubData(target glbase.Enum, offset, size int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3compat_glBufferSubData(gl.funcs, C.GLenum(target), C.GLintptr(offset), C.GLsizeiptr(size), data_ptr)
+}
+
+// BufferData creates a new data store for the buffer object currently
+// bound to target. Any pre-existing data store is deleted. The new data
+// store is created with the specified size in bytes and usage. If data is
+// not nil, it must be a slice that is used to initialize the data store.
+// In that case the size parameter is ignored and the store size will match
+// the slice data size.
+//
+// In its initial state, the new data store is not mapped, it has a NULL
+// mapped pointer, and its mapped access is GL.READ_WRITE.
+//
+// The target constant must be one of GL.ARRAY_BUFFER, GL.COPY_READ_BUFFER,
+// GL.COPY_WRITE_BUFFER, GL.ELEMENT_ARRAY_BUFFER, GL.PIXEL_PACK_BUFFER,
+// GL.PIXEL_UNPACK_BUFFER, GL.TEXTURE_BUFFER, GL.TRANSFORM_FEEDBACK_BUFFER,
+// or GL.UNIFORM_BUFFER.
+//
+// The usage parameter is a hint to the GL implementation as to how a buffer
+// object's data store will be accessed. This enables the GL implementation
+// to make more intelligent decisions that may significantly impact buffer
+// object performance. It does not, however, constrain the actual usage of
+// the data store. usage can be broken down into two parts: first, the
+// frequency of access (modification and usage), and second, the nature of
+// that access.
+//
+// A usage frequency of STREAM and nature of DRAW is specified via the
+// constant GL.STREAM_DRAW, for example.
+//
+// The usage frequency of access may be one of:
+//
+// STREAM
+// The data store contents will be modified once and used at most a few times.
+//
+// STATIC
+// The data store contents will be modified once and used many times.
+//
+// DYNAMIC
+// The data store contents will be modified repeatedly and used many times.
+//
+// The usage nature of access may be one of:
+//
+// DRAW
+// The data store contents are modified by the application, and used as
+// the source for GL drawing and image specification commands.
+//
+// READ
+// The data store contents are modified by reading data from the GL,
+// and used to return that data when queried by the application.
+//
+// COPY
+// The data store contents are modified by reading data from the GL,
+// and used as the source for GL drawing and image specification
+// commands.
+//
+// Clients must align data elements consistent with the requirements of the
+// client platform, with an additional base-level requirement that an offset
+// within a buffer to a datum comprising N bytes be a multiple of N.
+//
+// Error GL.INVALID_ENUM is generated if target is not one of the accepted
+// buffer targets. GL.INVALID_ENUM is generated if usage is not
+// GL.STREAM_DRAW, GL.STREAM_READ, GL.STREAM_COPY, GL.STATIC_DRAW,
+// GL.STATIC_READ, GL.STATIC_COPY, GL.DYNAMIC_DRAW, GL.DYNAMIC_READ, or
+// GL.DYNAMIC_COPY. GL.INVALID_VALUE is generated if size is negative.
+// GL.INVALID_OPERATION is generated if the reserved buffer object name 0 is
+// bound to target. GL.OUT_OF_MEMORY is generated if the GL is unable to
+// create a data store with the specified size.
+func (gl *GL) BufferData(target glbase.Enum, size int, data interface{}, usage glbase.Enum) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ if data != nil {
+ size = int(data_v.Type().Size()) * data_v.Len()
+ }
+ C.gl3_3compat_glBufferData(gl.funcs, C.GLenum(target), C.GLsizeiptr(size), data_ptr, C.GLenum(usage))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsBuffer.xml
+func (gl *GL) IsBuffer(buffer glbase.Buffer) bool {
+ glresult := C.gl3_3compat_glIsBuffer(gl.funcs, C.GLuint(buffer))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// GenBuffers returns n buffer object names. There is no guarantee that
+// the names form a contiguous set of integers; however, it is guaranteed
+// that none of the returned names was in use immediately before the call to
+// GenBuffers.
+//
+// Buffer object names returned by a call to GenBuffers are not returned by
+// subsequent calls, unless they are first deleted with DeleteBuffers.
+//
+// No buffer objects are associated with the returned buffer object names
+// until they are first bound by calling BindBuffer.
+//
+// Error GL.INVALID_VALUE is generated if n is negative. GL.INVALID_OPERATION
+// is generated if GenBuffers is executed between the execution of Begin
+// and the corresponding execution of End.
+//
+// GenBuffers is available in GL version 1.5 or greater.
+func (gl *GL) GenBuffers(n int) []glbase.Buffer {
+ if n == 0 {
+ return nil
+ }
+ buffers := make([]glbase.Buffer, n)
+ C.gl3_3compat_glGenBuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&buffers[0])))
+ return buffers
+}
+
+// DeleteBuffers deletes the buffer objects whose names are stored in the
+// buffers slice.
+//
+// After a buffer object is deleted, it has no contents, and its name is free
+// for reuse (for example by GenBuffers). If a buffer object that is
+// currently bound is deleted, the binding reverts to 0 (the absence of any
+// buffer object, which reverts to client memory usage).
+//
+// DeleteBuffers silently ignores 0's and names that do not correspond to
+// existing buffer objects.
+//
+// Error GL.INVALID_VALUE is generated if n is negative. GL.INVALID_OPERATION
+// is generated if DeleteBuffers is executed between the execution of Begin
+// and the corresponding execution of End.
+//
+// DeleteBuffers is available in GL version 1.5 or greater.
+func (gl *GL) DeleteBuffers(buffers []glbase.Buffer) {
+ n := len(buffers)
+ if n == 0 {
+ return
+ }
+ C.gl3_3compat_glDeleteBuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&buffers[0])))
+}
+
+// BindBuffer creates or puts in use a named buffer object.
+// Calling BindBuffer with target set to GL.ARRAY_BUFFER,
+// GL.ELEMENT_ARRAY_BUFFER, GL.PIXEL_PACK_BUFFER or GL.PIXEL_UNPACK_BUFFER
+// and buffer set to the name of the new buffer object binds the buffer
+// object name to the target. When a buffer object is bound to a target, the
+// previous binding for that target is automatically broken.
+//
+// Buffer object names are unsigned integers. The value zero is reserved, but
+// there is no default buffer object for each buffer object target. Instead,
+// buffer set to zero effectively unbinds any buffer object previously bound,
+// and restores client memory usage for that buffer object target. Buffer
+// object names and the corresponding buffer object contents are local to the
+// shared display-list space (see XCreateContext) of the current GL rendering
+// context; two rendering contexts share buffer object names only if they
+// also share display lists.
+//
+// GenBuffers may be called to generate a set of new buffer object names.
+//
+// The state of a buffer object immediately after it is first bound is an
+// unmapped zero-sized memory buffer with GL.READ_WRITE access and
+// GL.STATIC_DRAW usage.
+//
+// While a non-zero buffer object name is bound, GL operations on the target
+// to which it is bound affect the bound buffer object, and queries of the
+// target to which it is bound return state from the bound buffer object.
+// While buffer object name zero is bound, as in the initial state, attempts
+// to modify or query state on the target to which it is bound generates an
+// GL.INVALID_OPERATION error.
+//
+// When vertex array pointer state is changed, for example by a call to
+// NormalPointer, the current buffer object binding (GL.ARRAY_BUFFER_BINDING)
+// is copied into the corresponding client state for the vertex array type
+// being changed, for example GL.NORMAL_ARRAY_BUFFER_BINDING. While a
+// non-zero buffer object is bound to the GL.ARRAY_BUFFER target, the vertex
+// array pointer parameter that is traditionally interpreted as a pointer to
+// client-side memory is instead interpreted as an offset within the buffer
+// object measured in basic machine units.
+//
+// While a non-zero buffer object is bound to the GL.ELEMENT_ARRAY_BUFFER
+// target, the indices parameter of DrawElements, DrawRangeElements, or
+// MultiDrawElements that is traditionally interpreted as a pointer to
+// client-side memory is instead interpreted as an offset within the buffer
+// object measured in basic machine units.
+//
+// While a non-zero buffer object is bound to the GL.PIXEL_PACK_BUFFER
+// target, the following commands are affected: GetCompressedTexImage,
+// GetConvolutionFilter, GetHistogram, GetMinmax, GetPixelMap,
+// GetPolygonStipple, GetSeparableFilter, GetTexImage, and ReadPixels. The
+// pointer parameter that is traditionally interpreted as a pointer to
+// client-side memory where the pixels are to be packed is instead
+// interpreted as an offset within the buffer object measured in basic
+// machine units.
+//
+// While a non-zero buffer object is bound to the GL.PIXEL_UNPACK_BUFFER
+// target, the following commands are affected: Bitmap, ColorSubTable,
+// ColorTable, CompressedTexImage1D, CompressedTexImage2D,
+// CompressedTexImage3D, CompressedTexSubImage1D, CompressedTexSubImage2D,
+// CompressedTexSubImage3D, ConvolutionFilter1D, ConvolutionFilter2D,
+// DrawPixels, PixelMap, PolygonStipple, SeparableFilter2D, TexImage1D,
+// TexImage2D, TexImage3D, TexSubImage1D, TexSubImage2D, and TexSubImage3D.
+// The pointer parameter that is traditionally interpreted as a pointer to
+// client-side memory from which the pixels are to be unpacked is instead
+// interpreted as an offset within the buffer object measured in basic
+// machine units.
+//
+// A buffer object binding created with BindBuffer remains active until a
+// different buffer object name is bound to the same target, or until the
+// bound buffer object is deleted with DeleteBuffers.
+//
+// Once created, a named buffer object may be re-bound to any target as often
+// as needed. However, the GL implementation may make choices about how to
+// optimize the storage of a buffer object based on its initial binding
+// target.
+//
+// Error GL.INVALID_ENUM is generated if target is not one of the allowable
+// values. GL.INVALID_OPERATION is generated if BindBuffer is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// BindBuffer is available in GL version 1.5 or greater.
+func (gl *GL) BindBuffer(target glbase.Enum, buffer glbase.Buffer) {
+ C.gl3_3compat_glBindBuffer(gl.funcs, C.GLenum(target), C.GLuint(buffer))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetQueryObjectuiv.xml
+func (gl *GL) GetQueryObjectuiv(id uint32, pname glbase.Enum, params []uint32) {
+ C.gl3_3compat_glGetQueryObjectuiv(gl.funcs, C.GLuint(id), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetQueryObjectiv.xml
+func (gl *GL) GetQueryObjectiv(id uint32, pname glbase.Enum, params []int32) {
+ C.gl3_3compat_glGetQueryObjectiv(gl.funcs, C.GLuint(id), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetQueryiv.xml
+func (gl *GL) GetQueryiv(target, pname glbase.Enum, params []int32) {
+ C.gl3_3compat_glGetQueryiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEndQuery.xml
+func (gl *GL) EndQuery(target glbase.Enum) {
+ C.gl3_3compat_glEndQuery(gl.funcs, C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBeginQuery.xml
+func (gl *GL) BeginQuery(target glbase.Enum, id uint32) {
+ C.gl3_3compat_glBeginQuery(gl.funcs, C.GLenum(target), C.GLuint(id))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsQuery.xml
+func (gl *GL) IsQuery(id uint32) bool {
+ glresult := C.gl3_3compat_glIsQuery(gl.funcs, C.GLuint(id))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDeleteQueries.xml
+func (gl *GL) DeleteQueries(n int, ids []uint32) {
+ C.gl3_3compat_glDeleteQueries(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&ids[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGenQueries.xml
+func (gl *GL) GenQueries(n int, ids []uint32) {
+ C.gl3_3compat_glGenQueries(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&ids[0])))
+}
+
+// VertexAttribPointer specifies the location and data format of the array
+// of generic vertex attributes at index to use when rendering. size
+// specifies the number of components per attribute and must be 1, 2, 3, or
+// 4. type specifies the data type of each component, and stride specifies
+// the byte stride from one attribute to the next, allowing vertices and
+// attributes to be packed into a single array or stored in separate arrays.
+// normalized indicates whether the values stored in an integer format are
+// to be mapped to the range [-1,1] (for signed values) or [0,1]
+// (for unsigned values) when they are accessed and converted to floating
+// point; otherwise, values will be converted to floats directly without
+// normalization. offset is a byte offset into the buffer object's data
+// store, which must be bound to the GL.ARRAY_BUFFER target with BindBuffer.
+//
+// The buffer object binding (GL.ARRAY_BUFFER_BINDING) is saved as
+// generic vertex attribute array client-side state
+// (GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING) for the provided index.
+//
+// To enable and disable a generic vertex attribute array, call
+// EnableVertexAttribArray and DisableVertexAttribArray with index. If
+// enabled, the generic vertex attribute array is used when DrawArrays or
+// DrawElements is called. Each generic vertex attribute array is initially
+// disabled.
+//
+// VertexAttribPointer is typically implemented on the client side.
+//
+// Error GL.INVALID_ENUM is generated if type is not an accepted value.
+// GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_VALUE is generated if size is not 1, 2,
+// 3, or 4. GL.INVALID_VALUE is generated if stride is negative.
+func (gl *GL) VertexAttribPointer(index glbase.Attrib, size int, gltype glbase.Enum, normalized bool, stride int, offset uintptr) {
+ offset_ptr := unsafe.Pointer(offset)
+ C.gl3_3compat_glVertexAttribPointer(gl.funcs, C.GLuint(index), C.GLint(size), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), C.GLsizei(stride), offset_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glValidateProgram.xml
+func (gl *GL) ValidateProgram(program glbase.Program) {
+ C.gl3_3compat_glValidateProgram(gl.funcs, C.GLuint(program))
+}
+
+// UniformMatrix4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix4fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(4*4) != 0 {
+ panic("invalid value length for UniformMatrix4fv")
+ }
+ count := len(value) / (4 * 4)
+ C.gl3_3compat_glUniformMatrix4fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix3fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(3*3) != 0 {
+ panic("invalid value length for UniformMatrix3fv")
+ }
+ count := len(value) / (3 * 3)
+ C.gl3_3compat_glUniformMatrix3fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix2fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(2*2) != 0 {
+ panic("invalid value length for UniformMatrix2fv")
+ }
+ count := len(value) / (2 * 2)
+ C.gl3_3compat_glUniformMatrix2fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform4iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%4 != 0 {
+ panic("invalid value length for Uniform4iv")
+ }
+ count := len(value) / 4
+ C.gl3_3compat_glUniform4iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform3iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform3iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%3 != 0 {
+ panic("invalid value length for Uniform3iv")
+ }
+ count := len(value) / 3
+ C.gl3_3compat_glUniform3iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform2iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform2iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%2 != 0 {
+ panic("invalid value length for Uniform2iv")
+ }
+ count := len(value) / 2
+ C.gl3_3compat_glUniform2iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform1iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform1iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ count := len(value)
+ C.gl3_3compat_glUniform1iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%4 != 0 {
+ panic("invalid value length for Uniform4fv")
+ }
+ count := len(value) / 4
+ C.gl3_3compat_glUniform4fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%3 != 0 {
+ panic("invalid value length for Uniform3fv")
+ }
+ count := len(value) / 3
+ C.gl3_3compat_glUniform3fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%2 != 0 {
+ panic("invalid value length for Uniform2fv")
+ }
+ count := len(value) / 2
+ C.gl3_3compat_glUniform2fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform1fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform1fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ count := len(value)
+ C.gl3_3compat_glUniform1fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform4i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4i(location glbase.Uniform, v0, v1, v2, v3 int32) {
+ C.gl3_3compat_glUniform4i(gl.funcs, C.GLint(location), C.GLint(v0), C.GLint(v1), C.GLint(v2), C.GLint(v3))
+}
+
+// Uniform3i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform3i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3i(location glbase.Uniform, v0, v1, v2 int32) {
+ C.gl3_3compat_glUniform3i(gl.funcs, C.GLint(location), C.GLint(v0), C.GLint(v1), C.GLint(v2))
+}
+
+// Uniform2i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform2i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2i(location glbase.Uniform, v0, v1 int32) {
+ C.gl3_3compat_glUniform2i(gl.funcs, C.GLint(location), C.GLint(v0), C.GLint(v1))
+}
+
+// Uniform1i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform1i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1i(location glbase.Uniform, v0 int32) {
+ C.gl3_3compat_glUniform1i(gl.funcs, C.GLint(location), C.GLint(v0))
+}
+
+// Uniform4f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform4f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4f(location glbase.Uniform, v0, v1, v2, v3 float32) {
+ C.gl3_3compat_glUniform4f(gl.funcs, C.GLint(location), C.GLfloat(v0), C.GLfloat(v1), C.GLfloat(v2), C.GLfloat(v3))
+}
+
+// Uniform3f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform3f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3f(location glbase.Uniform, v0, v1, v2 float32) {
+ C.gl3_3compat_glUniform3f(gl.funcs, C.GLint(location), C.GLfloat(v0), C.GLfloat(v1), C.GLfloat(v2))
+}
+
+// Uniform2f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform2f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2f(location glbase.Uniform, v0, v1 float32) {
+ C.gl3_3compat_glUniform2f(gl.funcs, C.GLint(location), C.GLfloat(v0), C.GLfloat(v1))
+}
+
+// Uniform1f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform1f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1f(location glbase.Uniform, v0 float32) {
+ C.gl3_3compat_glUniform1f(gl.funcs, C.GLint(location), C.GLfloat(v0))
+}
+
+// UseProgram installs the program object specified by program as part of
+// current rendering state. One or more executables are created in a program
+// object by successfully attaching shader objects to it with AttachShader,
+// successfully compiling the shader objects with CompileShader, and
+// successfully linking the program object with LinkProgram.
+//
+// A program object will contain an executable that will run on the vertex
+// processor if it contains one or more shader objects of type
+// GL.VERTEX_SHADER that have been successfully compiled and linked.
+// Similarly, a program object will contain an executable that will run on
+// the fragment processor if it contains one or more shader objects of type
+// GL.FRAGMENT_SHADER that have been successfully compiled and linked.
+//
+// Successfully installing an executable on a programmable processor will
+// cause the corresponding fixed functionality of OpenGL to be disabled.
+// Specifically, if an executable is installed on the vertex processor, the
+// OpenGL fixed functionality will be disabled as follows.
+//
+// - The modelview matrix is not applied to vertex coordinates.
+//
+// - The projection matrix is not applied to vertex coordinates.
+//
+// - The texture matrices are not applied to texture coordinates.
+//
+// - Normals are not transformed to eye coordinates.
+//
+// - Normals are not rescaled or normalized.
+//
+// - Normalization of GL.AUTO_NORMAL evaluated normals is not performed.
+//
+// - Texture coordinates are not generated automatically.
+//
+// - Per-vertex lighting is not performed.
+//
+// - Color material computations are not performed.
+//
+// - Color index lighting is not performed.
+//
+// - This list also applies when setting the current raster position.
+//
+// The executable that is installed on the vertex processor is expected to
+// implement any or all of the desired functionality from the preceding list.
+// Similarly, if an executable is installed on the fragment processor, the
+// OpenGL fixed functionality will be disabled as follows.
+//
+// - Texture environment and texture functions are not applied.
+//
+// - Texture application is not applied.
+//
+// - Color sum is not applied.
+//
+// - Fog is not applied.
+//
+// Again, the fragment shader that is installed is expected to implement any
+// or all of the desired functionality from the preceding list.
+//
+// While a program object is in use, applications are free to modify attached
+// shader objects, compile attached shader objects, attach additional shader
+// objects, and detach or delete shader objects. None of these operations
+// will affect the executables that are part of the current state. However,
+// relinking the program object that is currently in use will install the
+// program object as part of the current rendering state if the link
+// operation was successful (see LinkProgram). If the program object
+// currently in use is relinked unsuccessfully, its link status will be set
+// to GL.FALSE, but the executables and associated state will remain part of
+// the current state until a subsequent call to UseProgram removes it from
+// use. After it is removed from use, it cannot be made part of current state
+// until it has been successfully relinked.
+//
+// If program contains shader objects of type GL.VERTEX_SHADER but it does
+// not contain shader objects of type GL.FRAGMENT_SHADER, an executable will
+// be installed on the vertex processor, but fixed functionality will be used
+// for fragment processing. Similarly, if program contains shader objects of
+// type GL.FRAGMENT_SHADER but it does not contain shader objects of type
+// GL.VERTEX_SHADER, an executable will be installed on the fragment
+// processor, but fixed functionality will be used for vertex processing. If
+// program is 0, the programmable processors will be disabled, and fixed
+// functionality will be used for both vertex and fragment processing.
+//
+// While a program object is in use, the state that controls the disabled
+// fixed functionality may also be updated using the normal OpenGL calls.
+//
+// Like display lists and texture objects, the name space for program objects
+// may be shared across a set of contexts, as long as the server sides of the
+// contexts share the same address space. If the name space is shared across
+// contexts, any attached objects and the data associated with those attached
+// objects are shared as well.
+//
+// Applications are responsible for providing the synchronization across API
+// calls when objects are accessed from different execution threads.
+//
+// Error GL.INVALID_VALUE is generated if program is neither 0 nor a value
+// generated by OpenGL. GL.INVALID_OPERATION is generated if program is not
+// a program object. GL.INVALID_OPERATION is generated if program could not
+// be made part of current state. GL.INVALID_OPERATION is generated if
+// UseProgram is executed between the execution of Begin and the
+// corresponding execution of End.
+//
+// UseProgram is available in GL version 2.0 or greater.
+func (gl *GL) UseProgram(program glbase.Program) {
+ C.gl3_3compat_glUseProgram(gl.funcs, C.GLuint(program))
+}
+
+// ShaderSource sets the source code in shader to the provided source code. Any source
+// code previously stored in the shader object is completely replaced.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader is not a shader
+// object. GL.INVALID_VALUE is generated if count is less than 0.
+// GL.INVALID_OPERATION is generated if ShaderSource is executed between the
+// execution of Begin and the corresponding execution of End.
+//
+// ShaderSource is available in GL version 2.0 or greater.
+func (gl *GL) ShaderSource(shader glbase.Shader, source ...string) {
+ count := len(source)
+ length := make([]int32, count)
+ source_c := make([]unsafe.Pointer, count)
+ for i, src := range source {
+ length[i] = int32(len(src))
+ if len(src) > 0 {
+ source_c[i] = *(*unsafe.Pointer)(unsafe.Pointer(&src))
+ } else {
+ source_c[i] = unsafe.Pointer(uintptr(0))
+ }
+ }
+ C.gl3_3compat_glShaderSource(gl.funcs, C.GLuint(shader), C.GLsizei(count), (**C.GLchar)(unsafe.Pointer(&source_c[0])), (*C.GLint)(unsafe.Pointer(&length[0])))
+}
+
+// LinkProgram links the program object specified by program. If any shader
+// objects of type GL.VERTEX_SHADER are attached to program, they will be
+// used to create an executable that will run on the programmable vertex
+// processor. If any shader objects of type GL.FRAGMENT_SHADER are attached
+// to program, they will be used to create an executable that will run on the
+// programmable fragment processor.
+//
+// The status of the link operation will be stored as part of the program
+// object's state. This value will be set to GL.TRUE if the program object
+// was linked without errors and is ready for use, and GL.FALSE otherwise. It
+// can be queried by calling GetProgramiv with arguments program and
+// GL.LINK_STATUS.
+//
+// As a result of a successful link operation, all active user-defined
+// uniform variables belonging to program will be initialized to 0, and each
+// of the program object's active uniform variables will be assigned a
+// location that can be queried by calling GetUniformLocation. Also, any
+// active user-defined attribute variables that have not been bound to a
+// generic vertex attribute index will be bound to one at this time.
+//
+// Linking of a program object can fail for a number of reasons as specified
+// in the OpenGL Shading Language Specification. The following lists some of
+// the conditions that will cause a link error.
+//
+// - The number of active attribute variables supported by the
+// implementation has been exceeded.
+//
+// - The storage limit for uniform variables has been exceeded.
+//
+// - The number of active uniform variables supported by the implementation
+// has been exceeded.
+//
+// - The main function is missing for the vertex shader or the fragment
+// shader.
+//
+// - A varying variable actually used in the fragment shader is not
+// declared in the same way (or is not declared at all) in the vertex
+// shader.
+//
+// - A reference to a function or variable name is unresolved.
+//
+// - A shared global is declared with two different types or two different
+// initial values.
+//
+// - One or more of the attached shader objects has not been successfully
+// compiled.
+//
+// - Binding a generic attribute matrix caused some rows of the matrix to
+// fall outside the allowed maximum of GL.MAX_VERTEX_ATTRIBS.
+//
+// - Not enough contiguous vertex attribute slots could be found to bind
+// attribute matrices.
+//
+// When a program object has been successfully linked, the program object can
+// be made part of current state by calling UseProgram. Whether or not the
+// link operation was successful, the program object's information log will
+// be overwritten. The information log can be retrieved by calling
+// GetProgramInfoLog.
+//
+// LinkProgram will also install the generated executables as part of the
+// current rendering state if the link operation was successful and the
+// specified program object is already currently in use as a result of a
+// previous call to UseProgram. If the program object currently in use is
+// relinked unsuccessfully, its link status will be set to GL.FALSE , but the
+// executables and associated state will remain part of the current state
+// until a subsequent call to UseProgram removes it from use. After it is
+// removed from use, it cannot be made part of current state until it has
+// been successfully relinked.
+//
+// If program contains shader objects of type GL.VERTEX_SHADER but does not
+// contain shader objects of type GL.FRAGMENT_SHADER, the vertex shader will
+// be linked against the implicit interface for fixed functionality fragment
+// processing. Similarly, if program contains shader objects of type
+// GL.FRAGMENT_SHADER but it does not contain shader objects of type
+// GL.VERTEX_SHADER, the fragment shader will be linked against the implicit
+// interface for fixed functionality vertex processing.
+//
+// The program object's information log is updated and the program is
+// generated at the time of the link operation. After the link operation,
+// applications are free to modify attached shader objects, compile attached
+// shader objects, detach shader objects, delete shader objects, and attach
+// additional shader objects. None of these operations affects the
+// information log or the program that is part of the program object.
+//
+// If the link operation is unsuccessful, any information about a previous
+// link operation on program is lost (a failed link does not restore the
+// old state of program). Certain information can still be retrieved
+// from program even after an unsuccessful link operation. See for instance
+// GetActiveAttrib and GetActiveUniform.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program
+// object. GL.INVALID_OPERATION is generated if LinkProgram is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// LinkProgram is available in GL version 2.0 or greater.
+func (gl *GL) LinkProgram(program glbase.Program) {
+ C.gl3_3compat_glLinkProgram(gl.funcs, C.GLuint(program))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsShader.xml
+func (gl *GL) IsShader(shader glbase.Shader) bool {
+ glresult := C.gl3_3compat_glIsShader(gl.funcs, C.GLuint(shader))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsProgram.xml
+func (gl *GL) IsProgram(program glbase.Program) bool {
+ glresult := C.gl3_3compat_glIsProgram(gl.funcs, C.GLuint(program))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// GetVertexAttribiv returns in params the value of a generic vertex attribute
+// parameter. The generic vertex attribute to be queried is specified by
+// index, and the parameter to be queried is specified by pname.
+//
+// The accepted parameter names are as follows:
+//
+// GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING
+// params returns a single value, the name of the buffer object
+// currently bound to the binding point corresponding to generic vertex
+// attribute array index. If no buffer object is bound, 0 is returned.
+// The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_ENABLED
+// params returns a single value that is non-zero (true) if the vertex
+// attribute array for index is enabled and 0 (false) if it is
+// disabled. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_SIZE
+// params returns a single value, the size of the vertex attribute
+// array for index. The size is the number of values for each element
+// of the vertex attribute array, and it will be 1, 2, 3, or 4. The
+// initial value is 4.
+//
+// GL.VERTEX_ATTRIB_ARRAY_STRIDE
+// params returns a single value, the array stride for (number of bytes
+// between successive elements in) the vertex attribute array for
+// index. A value of 0 indicates that the array elements are stored
+// sequentially in memory. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_TYPE
+// params returns a single value, a symbolic constant indicating the
+// array type for the vertex attribute array for index. Possible values
+// are GL.BYTE, GL.UNSIGNED_BYTE, GL.SHORT, GL.UNSIGNED_SHORT, GL.INT,
+// GL.UNSIGNED_INT, GL.FLOAT, and GL.DOUBLE. The initial value is
+// GL.FLOAT.
+//
+// GL.VERTEX_ATTRIB_ARRAY_NORMALIZED
+// params returns a single value that is non-zero (true) if fixed-point
+// data types for the vertex attribute array indicated by index are
+// normalized when they are converted to floating point, and 0 (false)
+// otherwise. The initial value is 0.
+//
+// GL.CURRENT_VERTEX_ATTRIB
+// params returns four values that represent the current value for the
+// generic vertex attribute specified by index. Generic vertex
+// attribute 0 is unique in that it has no current state, so an error
+// will be generated if index is 0. The initial value for all other
+// generic vertex attributes is (0,0,0,1).
+//
+// All of the parameters except GL.CURRENT_VERTEX_ATTRIB represent
+// client-side state.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_ENUM is generated if pname is not an
+// accepted value. GL.INVALID_OPERATION is generated if index is 0 and pname
+// is GL.CURRENT_VERTEX_ATTRIB.
+//
+// GetVertexAttribiv is available in GL version 2.0 or greater.
+func (gl *GL) GetVertexAttribiv(index glbase.Attrib, pname glbase.Enum, params []int32) {
+ var params_c [4]int32
+ C.gl3_3compat_glGetVertexAttribiv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetVertexAttribfv returns in params the value of a generic vertex attribute
+// parameter. The generic vertex attribute to be queried is specified by
+// index, and the parameter to be queried is specified by pname.
+//
+// The accepted parameter names are as follows:
+//
+// GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING
+// params returns a single value, the name of the buffer object
+// currently bound to the binding point corresponding to generic vertex
+// attribute array index. If no buffer object is bound, 0 is returned.
+// The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_ENABLED
+// params returns a single value that is non-zero (true) if the vertex
+// attribute array for index is enabled and 0 (false) if it is
+// disabled. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_SIZE
+// params returns a single value, the size of the vertex attribute
+// array for index. The size is the number of values for each element
+// of the vertex attribute array, and it will be 1, 2, 3, or 4. The
+// initial value is 4.
+//
+// GL.VERTEX_ATTRIB_ARRAY_STRIDE
+// params returns a single value, the array stride for (number of bytes
+// between successive elements in) the vertex attribute array for
+// index. A value of 0 indicates that the array elements are stored
+// sequentially in memory. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_TYPE
+// params returns a single value, a symbolic constant indicating the
+// array type for the vertex attribute array for index. Possible values
+// are GL.BYTE, GL.UNSIGNED_BYTE, GL.SHORT, GL.UNSIGNED_SHORT, GL.INT,
+// GL.UNSIGNED_INT, GL.FLOAT, and GL.DOUBLE. The initial value is
+// GL.FLOAT.
+//
+// GL.VERTEX_ATTRIB_ARRAY_NORMALIZED
+// params returns a single value that is non-zero (true) if fixed-point
+// data types for the vertex attribute array indicated by index are
+// normalized when they are converted to floating point, and 0 (false)
+// otherwise. The initial value is 0.
+//
+// GL.CURRENT_VERTEX_ATTRIB
+// params returns four values that represent the current value for the
+// generic vertex attribute specified by index. Generic vertex
+// attribute 0 is unique in that it has no current state, so an error
+// will be generated if index is 0. The initial value for all other
+// generic vertex attributes is (0,0,0,1).
+//
+// All of the parameters except GL.CURRENT_VERTEX_ATTRIB represent
+// client-side state.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_ENUM is generated if pname is not an
+// accepted value. GL.INVALID_OPERATION is generated if index is 0 and pname
+// is GL.CURRENT_VERTEX_ATTRIB.
+//
+// GetVertexAttribfv is available in GL version 2.0 or greater.
+func (gl *GL) GetVertexAttribfv(index glbase.Attrib, pname glbase.Enum, params []float32) {
+ var params_c [4]float32
+ C.gl3_3compat_glGetVertexAttribfv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetVertexAttribdv returns in params the value of a generic vertex attribute
+// parameter. The generic vertex attribute to be queried is specified by
+// index, and the parameter to be queried is specified by pname.
+//
+// The accepted parameter names are as follows:
+//
+// GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING
+// params returns a single value, the name of the buffer object
+// currently bound to the binding point corresponding to generic vertex
+// attribute array index. If no buffer object is bound, 0 is returned.
+// The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_ENABLED
+// params returns a single value that is non-zero (true) if the vertex
+// attribute array for index is enabled and 0 (false) if it is
+// disabled. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_SIZE
+// params returns a single value, the size of the vertex attribute
+// array for index. The size is the number of values for each element
+// of the vertex attribute array, and it will be 1, 2, 3, or 4. The
+// initial value is 4.
+//
+// GL.VERTEX_ATTRIB_ARRAY_STRIDE
+// params returns a single value, the array stride for (number of bytes
+// between successive elements in) the vertex attribute array for
+// index. A value of 0 indicates that the array elements are stored
+// sequentially in memory. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_TYPE
+// params returns a single value, a symbolic constant indicating the
+// array type for the vertex attribute array for index. Possible values
+// are GL.BYTE, GL.UNSIGNED_BYTE, GL.SHORT, GL.UNSIGNED_SHORT, GL.INT,
+// GL.UNSIGNED_INT, GL.FLOAT, and GL.DOUBLE. The initial value is
+// GL.FLOAT.
+//
+// GL.VERTEX_ATTRIB_ARRAY_NORMALIZED
+// params returns a single value that is non-zero (true) if fixed-point
+// data types for the vertex attribute array indicated by index are
+// normalized when they are converted to floating point, and 0 (false)
+// otherwise. The initial value is 0.
+//
+// GL.CURRENT_VERTEX_ATTRIB
+// params returns four values that represent the current value for the
+// generic vertex attribute specified by index. Generic vertex
+// attribute 0 is unique in that it has no current state, so an error
+// will be generated if index is 0. The initial value for all other
+// generic vertex attributes is (0,0,0,1).
+//
+// All of the parameters except GL.CURRENT_VERTEX_ATTRIB represent
+// client-side state.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_ENUM is generated if pname is not an
+// accepted value. GL.INVALID_OPERATION is generated if index is 0 and pname
+// is GL.CURRENT_VERTEX_ATTRIB.
+//
+// GetVertexAttribdv is available in GL version 2.0 or greater.
+func (gl *GL) GetVertexAttribdv(index glbase.Attrib, pname glbase.Enum, params []float64) {
+ var params_c [4]float64
+ C.gl3_3compat_glGetVertexAttribdv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetUniformiv returns in params the value of the specified uniform
+// variable. The type of the uniform variable specified by location
+// determines the number of values returned. If the uniform variable is
+// defined in the shader as a boolean, int, or float, a single value will be
+// returned. If it is defined as a vec2, ivec2, or bvec2, two values will be
+// returned. If it is defined as a vec3, ivec3, or bvec3, three values will
+// be returned, and so on. To query values stored in uniform variables
+// declared as arrays, call GetUniformiv for each element of the array. To
+// query values stored in uniform variables declared as structures, call
+// GetUniformiv for each field in the structure. The values for uniform
+// variables declared as a matrix will be returned in column major order.
+//
+// The locations assigned to uniform variables are not known until the
+// program object is linked. After linking has occurred, the command
+// GetUniformLocation can be used to obtain the location of a uniform
+// variable. This location value can then be passed to GetUniformiv in order
+// to query the current value of the uniform variable. After a program object
+// has been linked successfully, the index values for uniform variables
+// remain fixed until the next link command occurs. The uniform variable
+// values can only be queried after a link if the link was successful.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program
+// object. GL.INVALID_OPERATION is generated if program has not been
+// successfully linked. GL.INVALID_OPERATION is generated if location does
+// not correspond to a valid uniform variable location for the specified
+// program object. GL.INVALID_OPERATION is generated if GetUniformiv is
+// executed between the execution of Begin and the corresponding execution of
+// End.
+//
+// GetUniformiv is available in GL version 2.0 or greater.
+func (gl *GL) GetUniformiv(program glbase.Program, location glbase.Uniform, params []int32) {
+ var params_c [4]int32
+ C.gl3_3compat_glGetUniformiv(gl.funcs, C.GLuint(program), C.GLint(location), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetUniformfv returns in params the value of the specified uniform
+// variable. The type of the uniform variable specified by location
+// determines the number of values returned. If the uniform variable is
+// defined in the shader as a boolean, int, or float, a single value will be
+// returned. If it is defined as a vec2, ivec2, or bvec2, two values will be
+// returned. If it is defined as a vec3, ivec3, or bvec3, three values will
+// be returned, and so on. To query values stored in uniform variables
+// declared as arrays, call GetUniformfv for each element of the array. To
+// query values stored in uniform variables declared as structures, call
+// GetUniformfv for each field in the structure. The values for uniform
+// variables declared as a matrix will be returned in column major order.
+//
+// The locations assigned to uniform variables are not known until the
+// program object is linked. After linking has occurred, the command
+// GetUniformLocation can be used to obtain the location of a uniform
+// variable. This location value can then be passed to GetUniformfv in order
+// to query the current value of the uniform variable. After a program object
+// has been linked successfully, the index values for uniform variables
+// remain fixed until the next link command occurs. The uniform variable
+// values can only be queried after a link if the link was successful.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program
+// object. GL.INVALID_OPERATION is generated if program has not been
+// successfully linked. GL.INVALID_OPERATION is generated if location does
+// not correspond to a valid uniform variable location for the specified
+// program object. GL.INVALID_OPERATION is generated if GetUniformfv is
+// executed between the execution of Begin and the corresponding execution of
+// End.
+//
+// GetUniformfv is available in GL version 2.0 or greater.
+func (gl *GL) GetUniformfv(program glbase.Program, location glbase.Uniform, params []float32) {
+ var params_c [4]float32
+ C.gl3_3compat_glGetUniformfv(gl.funcs, C.GLuint(program), C.GLint(location), (*C.GLfloat)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetUniformLocation returns an integer that represents the location of a
+// specific uniform variable within a program object. name must be an active
+// uniform variable name in program that is not a structure, an array of
+// structures, or a subcomponent of a vector or a matrix. This function
+// returns -1 if name does not correspond to an active uniform variable in
+// program or if name starts with the reserved prefix "gl_".
+//
+// Uniform variables that are structures or arrays of structures may be
+// queried by calling GetUniformLocation for each field within the
+// structure. The array element operator "[]" and the structure field
+// operator "." may be used in name in order to select elements within an
+// array or fields within a structure. The result of using these operators is
+// not allowed to be another structure, an array of structures, or a
+// subcomponent of a vector or a matrix. Except if the last part of name
+// indicates a uniform variable array, the location of the first element of
+// an array can be retrieved by using the name of the array, or by using the
+// name appended by "[0]".
+//
+// The actual locations assigned to uniform variables are not known until the
+// program object is linked successfully. After linking has occurred, the
+// command GetUniformLocation can be used to obtain the location of a
+// uniform variable. This location value can then be passed to Uniform to
+// set the value of the uniform variable or to GetUniform in order to query
+// the current value of the uniform variable. After a program object has been
+// linked successfully, the index values for uniform variables remain fixed
+// until the next link command occurs. Uniform variable locations and values
+// can only be queried after a link if the link was successful.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program object.
+// GL.INVALID_OPERATION is generated if program has not been successfully
+// linked. GL.INVALID_OPERATION is generated if GetUniformLocation is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// GetUniformLocation is available in GL version 2.0 or greater.
+func (gl *GL) GetUniformLocation(program glbase.Program, name string) glbase.Uniform {
+ name_cstr := C.CString(name)
+ glresult := C.gl3_3compat_glGetUniformLocation(gl.funcs, C.GLuint(program), (*C.GLchar)(name_cstr))
+ C.free(unsafe.Pointer(name_cstr))
+ return glbase.Uniform(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetShaderSource.xml
+func (gl *GL) GetShaderSource(shader glbase.Shader, bufSize int32, length []int32, source []byte) {
+ C.gl3_3compat_glGetShaderSource(gl.funcs, C.GLuint(shader), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&source[0])))
+}
+
+// GetShaderInfoLog returns the information log for the specified shader
+// object. The information log for a shader object is modified when the
+// shader is compiled.
+//
+// The information log for a shader object is a string that may contain
+// diagnostic messages, warning messages, and other information about the
+// last compile operation. When a shader object is created, its information
+// log will be a string of length 0, and the size of the current log can be
+// obtained by calling GetShaderiv with the value GL.INFO_LOG_LENGTH.
+//
+// The information log for a shader object is the OpenGL implementer's
+// primary mechanism for conveying information about the compilation process.
+// Therefore, the information log can be helpful to application developers
+// during the development process, even when compilation is successful.
+// Application developers should not expect different OpenGL implementations
+// to produce identical information logs.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader is not a shader
+// object. GL.INVALID_VALUE is generated if maxLength is less than 0.
+// GL.INVALID_OPERATION is generated if GetShaderInfoLog is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// GetShaderInfoLog is available in GL version 2.0 or greater.
+func (gl *GL) GetShaderInfoLog(shader glbase.Shader) []byte {
+ var params [1]int32
+ var length int32
+ gl.GetShaderiv(shader, INFO_LOG_LENGTH, params[:])
+ bufSize := params[0]
+ infoLog := make([]byte, int(bufSize))
+ C.gl3_3compat_glGetShaderInfoLog(gl.funcs, C.GLuint(shader), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length)), (*C.GLchar)(unsafe.Pointer(&infoLog[0])))
+ return infoLog
+}
+
+// GetShaderiv GetShader returns in params the value of a parameter for a specific
+// shader object. The following parameters are defined:
+//
+// GL.SHADER_TYPE
+// params returns GL.VERTEX_SHADER if shader is a vertex shader object,
+// and GL.FRAGMENT_SHADER if shader is a fragment shader object.
+//
+// GL.DELETE_STATUS
+// params returns GL.TRUE if shader is currently flagged for deletion,
+// and GL.FALSE otherwise.
+//
+// GL.COMPILE_STATUS
+// params returns GL.TRUE if the last compile operation on shader was
+// successful, and GL.FALSE otherwise.
+//
+// GL.INFO_LOG_LENGTH
+// params returns the number of characters in the information log for
+// shader including the null termination character (the size of the
+// character buffer required to store the information log). If shader has
+// no information log, a value of 0 is returned.
+//
+// GL.SHADER_SOURCE_LENGTH
+// params returns the length of the concatenation of the source strings
+// that make up the shader source for the shader, including the null
+// termination character. (the size of the character buffer
+// required to store the shader source). If no source code exists, 0 is
+// returned.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader does not refer to a
+// shader object. GL.INVALID_ENUM is generated if pname is not an accepted
+// value. GL.INVALID_OPERATION is generated if GetShader is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// GetShaderiv is available in GL version 2.0 or greater.
+func (gl *GL) GetShaderiv(shader glbase.Shader, pname glbase.Enum, params []int32) {
+ var params_c [4]int32
+ C.gl3_3compat_glGetShaderiv(gl.funcs, C.GLuint(shader), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetProgramInfoLog returns the information log for the specified program
+// object. The information log for a program object is modified when the
+// program object is linked or validated.
+//
+// The information log for a program object is either an empty string, or a
+// string containing information about the last link operation, or a string
+// containing information about the last validation operation. It may contain
+// diagnostic messages, warning messages, and other information. When a
+// program object is created, its information log will be a string of length
+// 0, and the size of the current log can be obtained by calling GetProgramiv
+// with the value GL.INFO_LOG_LENGTH.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated
+// by OpenGL. GL.INVALID_OPERATION is generated if program is not a
+// program object.
+func (gl *GL) GetProgramInfoLog(program glbase.Program) []byte {
+ var params [1]int32
+ var length int32
+ gl.GetProgramiv(program, INFO_LOG_LENGTH, params[:])
+ bufSize := params[0]
+ infoLog := make([]byte, int(bufSize))
+ C.gl3_3compat_glGetProgramInfoLog(gl.funcs, C.GLuint(program), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length)), (*C.GLchar)(unsafe.Pointer(&infoLog[0])))
+ return infoLog
+}
+
+// GetProgramiv returns in params the value of a parameter for a specific
+// program object. The following parameters are defined:
+//
+// GL.DELETE_STATUS
+// params returns GL.TRUE if program is currently flagged for deletion,
+// and GL.FALSE otherwise.
+//
+// GL.LINK_STATUS
+// params returns GL.TRUE if the last link operation on program was
+// successful, and GL.FALSE otherwise.
+//
+// GL.VALIDATE_STATUS
+// params returns GL.TRUE or if the last validation operation on
+// program was successful, and GL.FALSE otherwise.
+//
+// GL.INFO_LOG_LENGTH
+// params returns the number of characters in the information log for
+// program including the null termination character (the size of
+// the character buffer required to store the information log). If
+// program has no information log, a value of 0 is returned.
+//
+// GL.ATTACHED_SHADERS
+// params returns the number of shader objects attached to program.
+//
+// GL.ACTIVE_ATTRIBUTES
+// params returns the number of active attribute variables for program.
+//
+// GL.ACTIVE_ATTRIBUTE_MAX_LENGTH
+// params returns the length of the longest active attribute name for
+// program, including the null termination character (the size of
+// the character buffer required to store the longest attribute name).
+// If no active attributes exist, 0 is returned.
+//
+// GL.ACTIVE_UNIFORMS
+// params returns the number of active uniform variables for program.
+//
+// GL.ACTIVE_UNIFORM_MAX_LENGTH
+// params returns the length of the longest active uniform variable
+// name for program, including the null termination character (i.e.,
+// the size of the character buffer required to store the longest
+// uniform variable name). If no active uniform variables exist, 0 is
+// returned.
+//
+// GL.TRANSFORM_FEEDBACK_BUFFER_MODE
+// params returns a symbolic constant indicating the buffer mode used
+// when transform feedback is active. This may be GL.SEPARATE_ATTRIBS
+// or GL.INTERLEAVED_ATTRIBS.
+//
+// GL.TRANSFORM_FEEDBACK_VARYINGS
+// params returns the number of varying variables to capture in transform
+// feedback mode for the program.
+//
+// GL.TRANSFORM_FEEDBACK_VARYING_MAX_LENGTH
+// params returns the length of the longest variable name to be used for
+// transform feedback, including the null-terminator.
+//
+// GL.GEOMETRY_VERTICES_OUT
+// params returns the maximum number of vertices that the geometry shader in
+// program will output.
+//
+// GL.GEOMETRY_INPUT_TYPE
+// params returns a symbolic constant indicating the primitive type accepted
+// as input to the geometry shader contained in program.
+//
+// GL.GEOMETRY_OUTPUT_TYPE
+// params returns a symbolic constant indicating the primitive type that will
+// be output by the geometry shader contained in program.
+//
+// GL.ACTIVE_UNIFORM_BLOCKS and GL.ACTIVE_UNIFORM_BLOCK_MAX_NAME_LENGTH are
+// available only if the GL version 3.1 or greater.
+//
+// GL.GEOMETRY_VERTICES_OUT, GL.GEOMETRY_INPUT_TYPE and
+// GL.GEOMETRY_OUTPUT_TYPE are accepted only if the GL version is 3.2 or
+// greater.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program does not refer to a
+// program object. GL.INVALID_OPERATION is generated if pname is
+// GL.GEOMETRY_VERTICES_OUT, GL.GEOMETRY_INPUT_TYPE, or
+// GL.GEOMETRY_OUTPUT_TYPE, and program does not contain a geometry shader.
+// GL.INVALID_ENUM is generated if pname is not an accepted value.
+func (gl *GL) GetProgramiv(program glbase.Program, pname glbase.Enum, params []int32) {
+ var params_c [4]int32
+ C.gl3_3compat_glGetProgramiv(gl.funcs, C.GLuint(program), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetAttribLocation queries the previously linked program object specified
+// by program for the attribute variable specified by name and returns the
+// index of the generic vertex attribute that is bound to that attribute
+// variable. If name is a matrix attribute variable, the index of the first
+// column of the matrix is returned. If the named attribute variable is not
+// an active attribute in the specified program object or if name starts with
+// the reserved prefix "gl_", a value of -1 is returned.
+//
+// The association between an attribute variable name and a generic attribute
+// index can be specified at any time by calling BindAttribLocation.
+// Attribute bindings do not go into effect until LinkProgram is called.
+// After a program object has been linked successfully, the index values for
+// attribute variables remain fixed until the next link command occurs. The
+// attribute values can only be queried after a link if the link was
+// successful. GetAttribLocation returns the binding that actually went
+// into effect the last time LinkProgram was called for the specified
+// program object. Attribute bindings that have been specified since the last
+// link operation are not returned by GetAttribLocation.
+//
+// Error GL_INVALID_OPERATION is generated if program is not a value
+// generated by OpenGL. GL_INVALID_OPERATION is generated if program is not
+// a program object. GL_INVALID_OPERATION is generated if program has not
+// been successfully linked. GL_INVALID_OPERATION is generated if
+// GetAttribLocation is executed between the execution of Begin and the
+// corresponding execution of End.
+//
+// GetAttribLocation is available in GL version 2.0 or greater.
+func (gl *GL) GetAttribLocation(program glbase.Program, name string) glbase.Attrib {
+ name_cstr := C.CString(name)
+ glresult := C.gl3_3compat_glGetAttribLocation(gl.funcs, C.GLuint(program), (*C.GLchar)(name_cstr))
+ C.free(unsafe.Pointer(name_cstr))
+ return glbase.Attrib(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetAttachedShaders.xml
+func (gl *GL) GetAttachedShaders(program glbase.Program, maxCount int32, count []int, obj []uint32) {
+ C.gl3_3compat_glGetAttachedShaders(gl.funcs, C.GLuint(program), C.GLsizei(maxCount), (*C.GLsizei)(unsafe.Pointer(&count[0])), (*C.GLuint)(unsafe.Pointer(&obj[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetActiveUniform.xml
+func (gl *GL) GetActiveUniform(program glbase.Program, index uint32, bufSize int32, length []int32, size []int, gltype []glbase.Enum, name []byte) {
+ C.gl3_3compat_glGetActiveUniform(gl.funcs, C.GLuint(program), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLint)(unsafe.Pointer(&size[0])), (*C.GLenum)(unsafe.Pointer(&gltype[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetActiveAttrib.xml
+func (gl *GL) GetActiveAttrib(program glbase.Program, index glbase.Attrib, bufSize int32, length []int32, size []int, gltype []glbase.Enum, name []byte) {
+ C.gl3_3compat_glGetActiveAttrib(gl.funcs, C.GLuint(program), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLint)(unsafe.Pointer(&size[0])), (*C.GLenum)(unsafe.Pointer(&gltype[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEnableVertexAttribArray.xml
+func (gl *GL) EnableVertexAttribArray(index glbase.Attrib) {
+ C.gl3_3compat_glEnableVertexAttribArray(gl.funcs, C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDisableVertexAttribArray.xml
+func (gl *GL) DisableVertexAttribArray(index glbase.Attrib) {
+ C.gl3_3compat_glDisableVertexAttribArray(gl.funcs, C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDetachShader.xml
+func (gl *GL) DetachShader(program glbase.Program, shader glbase.Shader) {
+ C.gl3_3compat_glDetachShader(gl.funcs, C.GLuint(program), C.GLuint(shader))
+}
+
+// DeleteShader frees the memory and invalidates the name associated with
+// the shader object specified by shader. This command effectively undoes the
+// effects of a call to CreateShader.
+//
+// If a shader object to be deleted is attached to a program object, it will
+// be flagged for deletion, but it will not be deleted until it is no longer
+// attached to any program object, for any rendering context (it must
+// be detached from wherever it was attached before it will be deleted). A
+// value of 0 for shader will be silently ignored.
+//
+// To determine whether an object has been flagged for deletion, call
+// GetShader with arguments shader and GL.DELETE_STATUS.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL.
+//
+// DeleteShader is available in GL version 2.0 or greater.
+func (gl *GL) DeleteShader(shader glbase.Shader) {
+ C.gl3_3compat_glDeleteShader(gl.funcs, C.GLuint(shader))
+}
+
+// DeleteProgram frees the memory and invalidates the name associated with
+// the program object specified by program. This command effectively undoes
+// the effects of a call to CreateProgram.
+//
+// If a program object is in use as part of current rendering state, it will
+// be flagged for deletion, but it will not be deleted until it is no longer
+// part of current state for any rendering context. If a program object to be
+// deleted has shader objects attached to it, those shader objects will be
+// automatically detached but not deleted unless they have already been
+// flagged for deletion by a previous call to DeleteShader. A value of 0
+// for program will be silently ignored.
+//
+// To determine whether a program object has been flagged for deletion, call
+// GetProgram with arguments program and GL.DELETE_STATUS.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL.
+//
+// DeleteProgram is available in GL version 2.0 or greater.
+func (gl *GL) DeleteProgram(program glbase.Program) {
+ C.gl3_3compat_glDeleteProgram(gl.funcs, C.GLuint(program))
+}
+
+// CreateShader creates an empty shader object and returns a non-zero value
+// by which it can be referenced. A shader object is used to maintain the
+// source code strings that define a shader. shaderType indicates the type of
+// shader to be created.
+//
+// Two types of shaders are supported. A shader of type GL.VERTEX_SHADER is a
+// shader that is intended to run on the programmable vertex processor and
+// replace the fixed functionality vertex processing in OpenGL. A shader of
+// type GL.FRAGMENT_SHADER is a shader that is intended to run on the
+// programmable fragment processor and replace the fixed functionality
+// fragment processing in OpenGL.
+//
+// When created, a shader object's GL.SHADER_TYPE parameter is set to either
+// GL.VERTEX_SHADER or GL.FRAGMENT_SHADER, depending on the value of
+// shaderType.
+//
+// Like display lists and texture objects, the name space for shader objects
+// may be shared across a set of contexts, as long as the server sides of the
+// contexts share the same address space. If the name space is shared across
+// contexts, any attached objects and the data associated with those attached
+// objects are shared as well.
+//
+// This function returns 0 if an error occurs creating the shader object.
+//
+// Error GL.INVALID_ENUM is generated if shaderType is not an accepted value.
+// GL.INVALID_OPERATION is generated if CreateShader is executed between the
+// execution of Begin and the corresponding execution of End.
+//
+// CreateShader is available in GL version 2.0 or greater.
+func (gl *GL) CreateShader(gltype glbase.Enum) glbase.Shader {
+ glresult := C.gl3_3compat_glCreateShader(gl.funcs, C.GLenum(gltype))
+ return glbase.Shader(glresult)
+}
+
+// CreateProgram creates an empty program object and returns a non-zero
+// value by which it can be referenced. A program object is an object to
+// which shader objects can be attached. This provides a mechanism to specify
+// the shader objects that will be linked to create a program. It also
+// provides a means for checking the compatibility of the shaders that will
+// be used to create a program (for instance, checking the compatibility
+// between a vertex shader and a fragment shader). When no longer needed as
+// part of a program object, shader objects can be detached.
+//
+// One or more executables are created in a program object by successfully
+// attaching shader objects to it with AttachShader, successfully compiling
+// the shader objects with CompileShader, and successfully linking the
+// program object with LinkProgram. These executables are made part of
+// current state when UseProgram is called. Program objects can be deleted
+// by calling DeleteProgram. The memory associated with the program object
+// will be deleted when it is no longer part of current rendering state for
+// any context.
+//
+// Like display lists and texture objects, the name space for program objects
+// may be shared across a set of contexts, as long as the server sides of the
+// contexts share the same address space. If the name space is shared across
+// contexts, any attached objects and the data associated with those attached
+// objects are shared as well.
+//
+// Applications are responsible for providing the synchronization across API
+// calls when objects are accessed from different execution threads.
+//
+// This function returns 0 if an error occurs creating the program object.
+//
+// Error GL.INVALID_OPERATION is generated if CreateProgram is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// CreateProgram is available in GL version 2.0 or greater.
+func (gl *GL) CreateProgram() glbase.Program {
+ glresult := C.gl3_3compat_glCreateProgram(gl.funcs)
+ return glbase.Program(glresult)
+}
+
+// CompileShader compiles the source code strings that have been stored in
+// the shader object specified by shader.
+//
+// The compilation status will be stored as part of the shader object's
+// state. This value will be set to GL.TRUE if the shader was compiled without
+// errors and is ready for use, and GL.FALSE otherwise. It can be queried by
+// calling GetShaderiv with arguments shader and GL.COMPILE_STATUS.
+//
+// Compilation of a shader can fail for a number of reasons as specified by
+// the OpenGL Shading Language Specification. Whether or not the compilation
+// was successful, information about the compilation can be obtained from the
+// shader object's information log by calling GetShaderInfoLog.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader is not a shader
+// object. GL.INVALID_OPERATION is generated if CompileShader is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// CompileShader is available in GL version 2.0 or greater.
+func (gl *GL) CompileShader(shader glbase.Shader) {
+ C.gl3_3compat_glCompileShader(gl.funcs, C.GLuint(shader))
+}
+
+// BindAttribLocation associates a user-defined attribute variable in the program
+// object specified by program with a generic vertex attribute index. The name
+// parameter specifies the name of the vertex shader attribute variable to
+// which index is to be bound. When program is made part of the current state,
+// values provided via the generic vertex attribute index will modify the
+// value of the user-defined attribute variable specified by name.
+//
+// If name refers to a matrix attribute variable, index refers to the first
+// column of the matrix. Other matrix columns are then automatically bound to
+// locations index+1 for a matrix of type mat2; index+1 and index+2 for a
+// matrix of type mat3; and index+1, index+2, and index+3 for a matrix of
+// type mat4.
+//
+// This command makes it possible for vertex shaders to use descriptive names
+// for attribute variables rather than generic variables that are numbered
+// from 0 to GL.MAX_VERTEX_ATTRIBS-1. The values sent to each generic
+// attribute index are part of current state, just like standard vertex
+// attributes such as color, normal, and vertex position. If a different
+// program object is made current by calling UseProgram, the generic vertex
+// attributes are tracked in such a way that the same values will be observed
+// by attributes in the new program object that are also bound to index.
+//
+// Attribute variable name-to-generic attribute index bindings for a program
+// object can be explicitly assigned at any time by calling
+// BindAttribLocation. Attribute bindings do not go into effect until
+// LinkProgram is called. After a program object has been linked
+// successfully, the index values for generic attributes remain fixed (and
+// their values can be queried) until the next link command occurs.
+//
+// Applications are not allowed to bind any of the standard OpenGL vertex
+// attributes using this command, as they are bound automatically when
+// needed. Any attribute binding that occurs after the program object has
+// been linked will not take effect until the next time the program object is
+// linked.
+//
+// If name was bound previously, that information is lost. Thus you cannot
+// bind one user-defined attribute variable to multiple indices, but you can
+// bind multiple user-defined attribute variables to the same index.
+//
+// Applications are allowed to bind more than one user-defined attribute
+// variable to the same generic vertex attribute index. This is called
+// aliasing, and it is allowed only if just one of the aliased attributes is
+// active in the executable program, or if no path through the shader
+// consumes more than one attribute of a set of attributes aliased to the
+// same location. The compiler and linker are allowed to assume that no
+// aliasing is done and are free to employ optimizations that work only in
+// the absence of aliasing. OpenGL implementations are not required to do
+// error checking to detect aliasing. Because there is no way to bind
+// standard attributes, it is not possible to alias generic attributes with
+// conventional ones (except for generic attribute 0).
+//
+// BindAttribLocation can be called before any vertex shader objects are
+// bound to the specified program object. It is also permissible to bind a
+// generic attribute index to an attribute variable name that is never used
+// in a vertex shader.
+//
+// Active attributes that are not explicitly bound will be bound by the
+// linker when LinkProgram is called. The locations assigned can be queried
+// by calling GetAttribLocation.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS.
+// GL.INVALID_OPERATION is generated if name starts with the reserved prefix "gl_".
+// GL.INVALID_VALUE is generated if program is not a value generated by OpenGL.
+// GL.INVALID_OPERATION is generated if program is not a program object.
+// GL.INVALID_OPERATION is generated if BindAttribLocation is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// BindAttribLocation is available in GL version 2.0 or greater.
+func (gl *GL) BindAttribLocation(program glbase.Program, index glbase.Attrib, name string) {
+ name_cstr := C.CString(name)
+ C.gl3_3compat_glBindAttribLocation(gl.funcs, C.GLuint(program), C.GLuint(index), (*C.GLchar)(name_cstr))
+ C.free(unsafe.Pointer(name_cstr))
+}
+
+// AttachShader attaches a shader object to a program object.
+//
+// In order to create an executable, there must be a way to specify the list
+// of things that will be linked together. Program objects provide this
+// mechanism. Shaders that are to be linked together in a program object must
+// first be attached to that program object. This indicates that shader will
+// be included in link operations that will be performed on program.
+//
+// All operations that can be performed on a shader object are valid whether
+// or not the shader object is attached to a program object. It is
+// permissible to attach a shader object to a program object before source
+// code has been loaded into the shader object or before the shader object
+// has been compiled. It is permissible to attach multiple shader objects of
+// the same type because each may contain a portion of the complete shader.
+// It is also permissible to attach a shader object to more than one program
+// object. If a shader object is deleted while it is attached to a program
+// object, it will be flagged for deletion, and deletion will not occur until
+// DetachShader is called to detach it from all program objects to which it
+// is attached.
+//
+// Error GL.INVALID_VALUE is generated if either program or shader is not a
+// value generated by OpenGL. GL.INVALID_OPERATION is generated if program
+// is not a program object. GL.INVALID_OPERATION is generated if shader is
+// not a shader object. GL.INVALID_OPERATION is generated if shader is
+// already attached to program. GL.INVALID_OPERATION is generated if
+// AttachShader is executed between the execution of Begin and the
+// corresponding execution of End.
+//
+// AttachShader is available in GL version 2.0 or greater.
+func (gl *GL) AttachShader(program glbase.Program, shader glbase.Shader) {
+ C.gl3_3compat_glAttachShader(gl.funcs, C.GLuint(program), C.GLuint(shader))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glStencilMaskSeparate.xml
+func (gl *GL) StencilMaskSeparate(face glbase.Enum, mask uint32) {
+ C.gl3_3compat_glStencilMaskSeparate(gl.funcs, C.GLenum(face), C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glStencilFuncSeparate.xml
+func (gl *GL) StencilFuncSeparate(face, glfunc glbase.Enum, ref int32, mask uint32) {
+ C.gl3_3compat_glStencilFuncSeparate(gl.funcs, C.GLenum(face), C.GLenum(glfunc), C.GLint(ref), C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glStencilOpSeparate.xml
+func (gl *GL) StencilOpSeparate(face, sfail, dpfail, dppass glbase.Enum) {
+ C.gl3_3compat_glStencilOpSeparate(gl.funcs, C.GLenum(face), C.GLenum(sfail), C.GLenum(dpfail), C.GLenum(dppass))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDrawBuffers.xml
+func (gl *GL) DrawBuffers(n int, bufs []glbase.Enum) {
+ C.gl3_3compat_glDrawBuffers(gl.funcs, C.GLsizei(n), (*C.GLenum)(unsafe.Pointer(&bufs[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBlendEquationSeparate.xml
+func (gl *GL) BlendEquationSeparate(modeRGB, modeAlpha glbase.Enum) {
+ C.gl3_3compat_glBlendEquationSeparate(gl.funcs, C.GLenum(modeRGB), C.GLenum(modeAlpha))
+}
+
+// UniformMatrix4x3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix4x3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix4x3fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(4*3) != 0 {
+ panic("invalid value length for UniformMatrix4x3fv")
+ }
+ count := len(value) / (4 * 3)
+ C.gl3_3compat_glUniformMatrix4x3fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix3x4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix3x4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix3x4fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(3*4) != 0 {
+ panic("invalid value length for UniformMatrix3x4fv")
+ }
+ count := len(value) / (3 * 4)
+ C.gl3_3compat_glUniformMatrix3x4fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix4x2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix4x2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix4x2fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(4*2) != 0 {
+ panic("invalid value length for UniformMatrix4x2fv")
+ }
+ count := len(value) / (4 * 2)
+ C.gl3_3compat_glUniformMatrix4x2fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix2x4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix2x4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix2x4fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(2*4) != 0 {
+ panic("invalid value length for UniformMatrix2x4fv")
+ }
+ count := len(value) / (2 * 4)
+ C.gl3_3compat_glUniformMatrix2x4fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix3x2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix3x2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix3x2fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(3*2) != 0 {
+ panic("invalid value length for UniformMatrix3x2fv")
+ }
+ count := len(value) / (3 * 2)
+ C.gl3_3compat_glUniformMatrix3x2fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix2x3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix2x3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix2x3fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(2*3) != 0 {
+ panic("invalid value length for UniformMatrix2x3fv")
+ }
+ count := len(value) / (2 * 3)
+ C.gl3_3compat_glUniformMatrix2x3fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsVertexArray.xml
+func (gl *GL) IsVertexArray(array uint32) bool {
+ glresult := C.gl3_3compat_glIsVertexArray(gl.funcs, C.GLuint(array))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGenVertexArrays.xml
+func (gl *GL) GenVertexArrays(n int, arrays []uint32) {
+ C.gl3_3compat_glGenVertexArrays(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&arrays[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDeleteVertexArrays.xml
+func (gl *GL) DeleteVertexArrays(n int, arrays []uint32) {
+ C.gl3_3compat_glDeleteVertexArrays(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&arrays[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBindVertexArray.xml
+func (gl *GL) BindVertexArray(array uint32) {
+ C.gl3_3compat_glBindVertexArray(gl.funcs, C.GLuint(array))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFlushMappedBufferRange.xml
+func (gl *GL) FlushMappedBufferRange(target glbase.Enum, offset, length int) {
+ C.gl3_3compat_glFlushMappedBufferRange(gl.funcs, C.GLenum(target), C.GLintptr(offset), C.GLsizeiptr(length))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFramebufferTextureLayer.xml
+func (gl *GL) FramebufferTextureLayer(target, attachment glbase.Enum, texture glbase.Texture, level int, layer int32) {
+ C.gl3_3compat_glFramebufferTextureLayer(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLuint(texture), C.GLint(level), C.GLint(layer))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRenderbufferStorageMultisample.xml
+func (gl *GL) RenderbufferStorageMultisample(target glbase.Enum, samples int32, internalFormat glbase.Enum, width, height int) {
+ C.gl3_3compat_glRenderbufferStorageMultisample(gl.funcs, C.GLenum(target), C.GLsizei(samples), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBlitFramebuffer.xml
+func (gl *GL) BlitFramebuffer(srcX0, srcY0, srcX1, srcY1, dstX0, dstY0, dstX1, dstY1 int32, mask glbase.Bitfield, filter glbase.Enum) {
+ C.gl3_3compat_glBlitFramebuffer(gl.funcs, C.GLint(srcX0), C.GLint(srcY0), C.GLint(srcX1), C.GLint(srcY1), C.GLint(dstX0), C.GLint(dstY0), C.GLint(dstX1), C.GLint(dstY1), C.GLbitfield(mask), C.GLenum(filter))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGenerateMipmap.xml
+func (gl *GL) GenerateMipmap(target glbase.Enum) {
+ C.gl3_3compat_glGenerateMipmap(gl.funcs, C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetFramebufferAttachmentParameteriv.xml
+func (gl *GL) GetFramebufferAttachmentParameteriv(target, attachment, pname glbase.Enum, params []int32) {
+ C.gl3_3compat_glGetFramebufferAttachmentParameteriv(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFramebufferRenderbuffer.xml
+func (gl *GL) FramebufferRenderbuffer(target, attachment, renderbuffertarget glbase.Enum, renderbuffer glbase.Renderbuffer) {
+ C.gl3_3compat_glFramebufferRenderbuffer(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(renderbuffertarget), C.GLuint(renderbuffer))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFramebufferTexture3D.xml
+func (gl *GL) FramebufferTexture3D(target, attachment, textarget glbase.Enum, texture glbase.Texture, level int, zoffset int32) {
+ C.gl3_3compat_glFramebufferTexture3D(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(textarget), C.GLuint(texture), C.GLint(level), C.GLint(zoffset))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFramebufferTexture2D.xml
+func (gl *GL) FramebufferTexture2D(target, attachment, textarget glbase.Enum, texture glbase.Texture, level int) {
+ C.gl3_3compat_glFramebufferTexture2D(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(textarget), C.GLuint(texture), C.GLint(level))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFramebufferTexture1D.xml
+func (gl *GL) FramebufferTexture1D(target, attachment, textarget glbase.Enum, texture glbase.Texture, level int) {
+ C.gl3_3compat_glFramebufferTexture1D(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(textarget), C.GLuint(texture), C.GLint(level))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCheckFramebufferStatus.xml
+func (gl *GL) CheckFramebufferStatus(target glbase.Enum) glbase.Enum {
+ glresult := C.gl3_3compat_glCheckFramebufferStatus(gl.funcs, C.GLenum(target))
+ return glbase.Enum(glresult)
+}
+
+// GenFramebuffers returns n framebuffer object names in ids. There is no
+// guarantee that the names form a contiguous set of integers; however, it is
+// guaranteed that none of the returned names was in use immediately before
+// the call to GenFramebuffers.
+//
+// Framebuffer object names returned by a call to GenFramebuffers are not
+// returned by subsequent calls, unless they are first deleted with
+// DeleteFramebuffers.
+//
+// The names returned in ids are marked as used, for the purposes of
+// GenFramebuffers only, but they acquire state and type only when they are
+// first bound.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+func (gl *GL) GenFramebuffers(n int) []glbase.Framebuffer {
+ if n == 0 {
+ return nil
+ }
+ framebuffers := make([]glbase.Framebuffer, n)
+ C.gl3_3compat_glGenFramebuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&framebuffers[0])))
+ return framebuffers
+}
+
+// DeleteFramebuffers deletes the framebuffer objects whose names are
+// stored in the framebuffers slice. The name zero is reserved by the GL and
+// is silently ignored, should it occur in framebuffers, as are other unused
+// names. Once a framebuffer object is deleted, its name is again unused and
+// it has no attachments. If a framebuffer that is currently bound to one or
+// more of the targets GL.DRAW_FRAMEBUFFER or GL.READ_FRAMEBUFFER is deleted,
+// it is as though BindFramebuffer had been executed with the corresponding
+// target and framebuffer zero.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// DeleteFramebuffers is available in GL version 3.0 or greater.
+func (gl *GL) DeleteFramebuffers(framebuffers []glbase.Framebuffer) {
+ n := len(framebuffers)
+ if n == 0 {
+ return
+ }
+ C.gl3_3compat_glDeleteFramebuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&framebuffers[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBindFramebuffer.xml
+func (gl *GL) BindFramebuffer(target glbase.Enum, framebuffer glbase.Framebuffer) {
+ C.gl3_3compat_glBindFramebuffer(gl.funcs, C.GLenum(target), C.GLuint(framebuffer))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsFramebuffer.xml
+func (gl *GL) IsFramebuffer(framebuffer glbase.Framebuffer) bool {
+ glresult := C.gl3_3compat_glIsFramebuffer(gl.funcs, C.GLuint(framebuffer))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetRenderbufferParameteriv.xml
+func (gl *GL) GetRenderbufferParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl3_3compat_glGetRenderbufferParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRenderbufferStorage.xml
+func (gl *GL) RenderbufferStorage(target, internalFormat glbase.Enum, width, height int) {
+ C.gl3_3compat_glRenderbufferStorage(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height))
+}
+
+// GenRenderbuffers returns n renderbuffer object names in renderbuffers.
+// There is no guarantee that the names form a contiguous set of integers;
+// however, it is guaranteed that none of the returned names was in use
+// immediately before the call to GenRenderbuffers.
+//
+// Renderbuffer object names returned by a call to GenRenderbuffers are not
+// returned by subsequent calls, unless they are first deleted with
+// DeleteRenderbuffers.
+//
+// The names returned in renderbuffers are marked as used, for the purposes
+// of GenRenderbuffers only, but they acquire state and type only when they
+// are first bound.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// GenRenderbuffers is available in GL version 3.0 or greater.
+func (gl *GL) GenRenderbuffers(n int) []glbase.Renderbuffer {
+ if n == 0 {
+ return nil
+ }
+ renderbuffers := make([]glbase.Renderbuffer, n)
+ C.gl3_3compat_glGenRenderbuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&renderbuffers[0])))
+ return renderbuffers
+}
+
+// DeleteRenderbuffers deletes the renderbuffer objects whose names are stored
+// in the renderbuffers slice. The name zero is reserved by the GL and
+// is silently ignored, should it occur in renderbuffers, as are other unused
+// names. Once a renderbuffer object is deleted, its name is again unused and
+// it has no contents. If a renderbuffer that is currently bound to the
+// target GL.RENDERBUFFER is deleted, it is as though BindRenderbuffer had
+// been executed with a target of GL.RENDERBUFFER and a name of zero.
+//
+// If a renderbuffer object is attached to one or more attachment points in
+// the currently bound framebuffer, then it as if FramebufferRenderbuffer
+// had been called, with a renderbuffer of zero for each attachment point to
+// which this image was attached in the currently bound framebuffer. In other
+// words, this renderbuffer object is first detached from all attachment
+// ponits in the currently bound framebuffer. Note that the renderbuffer
+// image is specifically not detached from any non-bound framebuffers.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// DeleteRenderbuffers is available in GL version 3.0 or greater.
+func (gl *GL) DeleteRenderbuffers(renderbuffers []glbase.Renderbuffer) {
+ n := len(renderbuffers)
+ if n == 0 {
+ return
+ }
+ C.gl3_3compat_glDeleteRenderbuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&renderbuffers[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBindRenderbuffer.xml
+func (gl *GL) BindRenderbuffer(target glbase.Enum, renderbuffer glbase.Renderbuffer) {
+ C.gl3_3compat_glBindRenderbuffer(gl.funcs, C.GLenum(target), C.GLuint(renderbuffer))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsRenderbuffer.xml
+func (gl *GL) IsRenderbuffer(renderbuffer glbase.Renderbuffer) bool {
+ glresult := C.gl3_3compat_glIsRenderbuffer(gl.funcs, C.GLuint(renderbuffer))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClearBufferfi.xml
+func (gl *GL) ClearBufferfi(buffer glbase.Enum, drawbuffer int32, depth float32, stencil int32) {
+ C.gl3_3compat_glClearBufferfi(gl.funcs, C.GLenum(buffer), C.GLint(drawbuffer), C.GLfloat(depth), C.GLint(stencil))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClearBufferfv.xml
+func (gl *GL) ClearBufferfv(buffer glbase.Enum, drawbuffer int32, value []float32) {
+ C.gl3_3compat_glClearBufferfv(gl.funcs, C.GLenum(buffer), C.GLint(drawbuffer), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClearBufferuiv.xml
+func (gl *GL) ClearBufferuiv(buffer glbase.Enum, drawbuffer int32, value []uint32) {
+ C.gl3_3compat_glClearBufferuiv(gl.funcs, C.GLenum(buffer), C.GLint(drawbuffer), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClearBufferiv.xml
+func (gl *GL) ClearBufferiv(buffer glbase.Enum, drawbuffer int32, value []int32) {
+ C.gl3_3compat_glClearBufferiv(gl.funcs, C.GLenum(buffer), C.GLint(drawbuffer), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTexParameterIuiv.xml
+func (gl *GL) GetTexParameterIuiv(target, pname glbase.Enum, params []uint32) {
+ C.gl3_3compat_glGetTexParameterIuiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTexParameterIiv.xml
+func (gl *GL) GetTexParameterIiv(target, pname glbase.Enum, params []int32) {
+ C.gl3_3compat_glGetTexParameterIiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexParameterIuiv.xml
+func (gl *GL) TexParameterIuiv(target, pname glbase.Enum, params []uint32) {
+ C.gl3_3compat_glTexParameterIuiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexParameterIiv.xml
+func (gl *GL) TexParameterIiv(target, pname glbase.Enum, params []int32) {
+ C.gl3_3compat_glTexParameterIiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// Uniform4uiv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform4uiv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4uiv(location glbase.Uniform, value []uint32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%4 != 0 {
+ panic("invalid value length for Uniform4uiv")
+ }
+ count := len(value) / 4
+ C.gl3_3compat_glUniform4uiv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform3uiv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform3uiv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3uiv(location glbase.Uniform, value []uint32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%3 != 0 {
+ panic("invalid value length for Uniform3uiv")
+ }
+ count := len(value) / 3
+ C.gl3_3compat_glUniform3uiv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform2uiv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform2uiv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2uiv(location glbase.Uniform, value []uint32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%2 != 0 {
+ panic("invalid value length for Uniform2uiv")
+ }
+ count := len(value) / 2
+ C.gl3_3compat_glUniform2uiv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform1uiv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform1uiv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1uiv(location glbase.Uniform, value []uint32) {
+ if len(value) == 0 {
+ return
+ }
+ count := len(value)
+ C.gl3_3compat_glUniform1uiv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4ui modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform4ui operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4ui(location glbase.Uniform, v0, v1, v2, v3 uint32) {
+ C.gl3_3compat_glUniform4ui(gl.funcs, C.GLint(location), C.GLuint(v0), C.GLuint(v1), C.GLuint(v2), C.GLuint(v3))
+}
+
+// Uniform3ui modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform3ui operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3ui(location glbase.Uniform, v0, v1, v2 uint32) {
+ C.gl3_3compat_glUniform3ui(gl.funcs, C.GLint(location), C.GLuint(v0), C.GLuint(v1), C.GLuint(v2))
+}
+
+// Uniform2ui modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform2ui operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2ui(location glbase.Uniform, v0, v1 uint32) {
+ C.gl3_3compat_glUniform2ui(gl.funcs, C.GLint(location), C.GLuint(v0), C.GLuint(v1))
+}
+
+// Uniform1ui modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform1ui operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1ui(location glbase.Uniform, v0 uint32) {
+ C.gl3_3compat_glUniform1ui(gl.funcs, C.GLint(location), C.GLuint(v0))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetFragDataLocation.xml
+func (gl *GL) GetFragDataLocation(program glbase.Program, name []byte) int32 {
+ glresult := C.gl3_3compat_glGetFragDataLocation(gl.funcs, C.GLuint(program), (*C.GLchar)(unsafe.Pointer(&name[0])))
+ return int32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBindFragDataLocation.xml
+func (gl *GL) BindFragDataLocation(program glbase.Program, color uint32, name []byte) {
+ C.gl3_3compat_glBindFragDataLocation(gl.funcs, C.GLuint(program), C.GLuint(color), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetUniformuiv.xml
+func (gl *GL) GetUniformuiv(program glbase.Program, location glbase.Uniform, params []uint32) {
+ C.gl3_3compat_glGetUniformuiv(gl.funcs, C.GLuint(program), C.GLint(location), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetVertexAttribIuiv.xml
+func (gl *GL) GetVertexAttribIuiv(index glbase.Attrib, pname glbase.Enum, params []uint32) {
+ C.gl3_3compat_glGetVertexAttribIuiv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetVertexAttribIiv.xml
+func (gl *GL) GetVertexAttribIiv(index glbase.Attrib, pname glbase.Enum, params []int32) {
+ C.gl3_3compat_glGetVertexAttribIiv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribIPointer.xml
+func (gl *GL) VertexAttribIPointer(index glbase.Attrib, size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3compat_glVertexAttribIPointer(gl.funcs, C.GLuint(index), C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEndConditionalRender.xml
+func (gl *GL) EndConditionalRender() {
+ C.gl3_3compat_glEndConditionalRender(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBeginConditionalRender.xml
+func (gl *GL) BeginConditionalRender(id uint32, mode glbase.Enum) {
+ C.gl3_3compat_glBeginConditionalRender(gl.funcs, C.GLuint(id), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClampColor.xml
+func (gl *GL) ClampColor(target, clamp glbase.Enum) {
+ C.gl3_3compat_glClampColor(gl.funcs, C.GLenum(target), C.GLenum(clamp))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTransformFeedbackVarying.xml
+func (gl *GL) GetTransformFeedbackVarying(program glbase.Program, index uint32, bufSize int32, length []int32, size []int, gltype []glbase.Enum, name []byte) {
+ C.gl3_3compat_glGetTransformFeedbackVarying(gl.funcs, C.GLuint(program), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLsizei)(unsafe.Pointer(&size[0])), (*C.GLenum)(unsafe.Pointer(&gltype[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBindBufferBase.xml
+func (gl *GL) BindBufferBase(target glbase.Enum, index uint32, buffer glbase.Buffer) {
+ C.gl3_3compat_glBindBufferBase(gl.funcs, C.GLenum(target), C.GLuint(index), C.GLuint(buffer))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBindBufferRange.xml
+func (gl *GL) BindBufferRange(target glbase.Enum, index uint32, buffer glbase.Buffer, offset, size int) {
+ C.gl3_3compat_glBindBufferRange(gl.funcs, C.GLenum(target), C.GLuint(index), C.GLuint(buffer), C.GLintptr(offset), C.GLsizeiptr(size))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEndTransformFeedback.xml
+func (gl *GL) EndTransformFeedback() {
+ C.gl3_3compat_glEndTransformFeedback(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBeginTransformFeedback.xml
+func (gl *GL) BeginTransformFeedback(primitiveMode glbase.Enum) {
+ C.gl3_3compat_glBeginTransformFeedback(gl.funcs, C.GLenum(primitiveMode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsEnabledi.xml
+func (gl *GL) IsEnabledi(target glbase.Enum, index uint32) bool {
+ glresult := C.gl3_3compat_glIsEnabledi(gl.funcs, C.GLenum(target), C.GLuint(index))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDisablei.xml
+func (gl *GL) Disablei(target glbase.Enum, index uint32) {
+ C.gl3_3compat_glDisablei(gl.funcs, C.GLenum(target), C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEnablei.xml
+func (gl *GL) Enablei(target glbase.Enum, index uint32) {
+ C.gl3_3compat_glEnablei(gl.funcs, C.GLenum(target), C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetIntegeri_v.xml
+func (gl *GL) GetIntegeri_v(target glbase.Enum, index uint32, data []int32) {
+ C.gl3_3compat_glGetIntegeri_v(gl.funcs, C.GLenum(target), C.GLuint(index), (*C.GLint)(unsafe.Pointer(&data[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetBooleani_v.xml
+func (gl *GL) GetBooleani_v(target glbase.Enum, index uint32, data []bool) {
+ C.gl3_3compat_glGetBooleani_v(gl.funcs, C.GLenum(target), C.GLuint(index), (*C.GLboolean)(unsafe.Pointer(&data[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColorMaski.xml
+func (gl *GL) ColorMaski(index uint32, r, g, b, a bool) {
+ C.gl3_3compat_glColorMaski(gl.funcs, C.GLuint(index), *(*C.GLboolean)(unsafe.Pointer(&r)), *(*C.GLboolean)(unsafe.Pointer(&g)), *(*C.GLboolean)(unsafe.Pointer(&b)), *(*C.GLboolean)(unsafe.Pointer(&a)))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCopyBufferSubData.xml
+func (gl *GL) CopyBufferSubData(readTarget, writeTarget glbase.Enum, readOffset, writeOffset, size int) {
+ C.gl3_3compat_glCopyBufferSubData(gl.funcs, C.GLenum(readTarget), C.GLenum(writeTarget), C.GLintptr(readOffset), C.GLintptr(writeOffset), C.GLsizeiptr(size))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glUniformBlockBinding.xml
+func (gl *GL) UniformBlockBinding(program glbase.Program, v0, v1 uint32) {
+ C.gl3_3compat_glUniformBlockBinding(gl.funcs, C.GLuint(program), C.GLuint(v0), C.GLuint(v1))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetActiveUniformBlockName.xml
+func (gl *GL) GetActiveUniformBlockName(program glbase.Program, uniformBlockIndex uint32, bufSize int32, length []int32, uniformBlockName []byte) {
+ C.gl3_3compat_glGetActiveUniformBlockName(gl.funcs, C.GLuint(program), C.GLuint(uniformBlockIndex), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&uniformBlockName[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetActiveUniformBlockiv.xml
+func (gl *GL) GetActiveUniformBlockiv(program glbase.Program, uniformBlockIndex uint32, pname glbase.Enum, params []int32) {
+ C.gl3_3compat_glGetActiveUniformBlockiv(gl.funcs, C.GLuint(program), C.GLuint(uniformBlockIndex), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetUniformBlockIndex.xml
+func (gl *GL) GetUniformBlockIndex(program glbase.Program, uniformBlockName []byte) uint32 {
+ glresult := C.gl3_3compat_glGetUniformBlockIndex(gl.funcs, C.GLuint(program), (*C.GLchar)(unsafe.Pointer(&uniformBlockName[0])))
+ return uint32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetActiveUniformName.xml
+func (gl *GL) GetActiveUniformName(program glbase.Program, uniformIndex uint32, bufSize int32, length []int32, uniformName []byte) {
+ C.gl3_3compat_glGetActiveUniformName(gl.funcs, C.GLuint(program), C.GLuint(uniformIndex), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&uniformName[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetActiveUniformsiv.xml
+func (gl *GL) GetActiveUniformsiv(program glbase.Program, uniformCount int32, uniformIndices []uint32, pname glbase.Enum, params []int32) {
+ C.gl3_3compat_glGetActiveUniformsiv(gl.funcs, C.GLuint(program), C.GLsizei(uniformCount), (*C.GLuint)(unsafe.Pointer(&uniformIndices[0])), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPrimitiveRestartIndex.xml
+func (gl *GL) PrimitiveRestartIndex(index uint32) {
+ C.gl3_3compat_glPrimitiveRestartIndex(gl.funcs, C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexBuffer.xml
+func (gl *GL) TexBuffer(target, internalFormat glbase.Enum, buffer glbase.Buffer) {
+ C.gl3_3compat_glTexBuffer(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLuint(buffer))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDrawElementsInstanced.xml
+func (gl *GL) DrawElementsInstanced(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}, instancecount int32) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3compat_glDrawElementsInstanced(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr, C.GLsizei(instancecount))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDrawArraysInstanced.xml
+func (gl *GL) DrawArraysInstanced(mode glbase.Enum, first, count int, instancecount int32) {
+ C.gl3_3compat_glDrawArraysInstanced(gl.funcs, C.GLenum(mode), C.GLint(first), C.GLsizei(count), C.GLsizei(instancecount))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSampleMaski.xml
+func (gl *GL) SampleMaski(index uint32, mask glbase.Bitfield) {
+ C.gl3_3compat_glSampleMaski(gl.funcs, C.GLuint(index), C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetMultisamplefv.xml
+func (gl *GL) GetMultisamplefv(pname glbase.Enum, index uint32, val []float32) {
+ C.gl3_3compat_glGetMultisamplefv(gl.funcs, C.GLenum(pname), C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&val[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexImage3DMultisample.xml
+func (gl *GL) TexImage3DMultisample(target glbase.Enum, samples, internalFormat int32, width, height int, depth int32, fixedsamplelocations bool) {
+ C.gl3_3compat_glTexImage3DMultisample(gl.funcs, C.GLenum(target), C.GLsizei(samples), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), *(*C.GLboolean)(unsafe.Pointer(&fixedsamplelocations)))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexImage2DMultisample.xml
+func (gl *GL) TexImage2DMultisample(target glbase.Enum, samples, internalFormat int32, width, height int, fixedsamplelocations bool) {
+ C.gl3_3compat_glTexImage2DMultisample(gl.funcs, C.GLenum(target), C.GLsizei(samples), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), *(*C.GLboolean)(unsafe.Pointer(&fixedsamplelocations)))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetSynciv.xml
+func (gl *GL) GetSynciv(sync glbase.Sync, pname glbase.Enum, bufSize int32, length, values []int32) {
+ C.gl3_3compat_glGetSynciv(gl.funcs, C.GLsync(unsafe.Pointer(sync)), C.GLenum(pname), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLint)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetInteger64v.xml
+func (gl *GL) GetInteger64v(pname glbase.Enum, params []int64) {
+ C.gl3_3compat_glGetInteger64v(gl.funcs, C.GLenum(pname), (*C.GLint64)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glWaitSync.xml
+func (gl *GL) WaitSync(sync glbase.Sync, flags glbase.Bitfield, timeout uint64) {
+ C.gl3_3compat_glWaitSync(gl.funcs, C.GLsync(unsafe.Pointer(sync)), C.GLbitfield(flags), C.GLuint64(timeout))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClientWaitSync.xml
+func (gl *GL) ClientWaitSync(sync glbase.Sync, flags glbase.Bitfield, timeout uint64) glbase.Enum {
+ glresult := C.gl3_3compat_glClientWaitSync(gl.funcs, C.GLsync(unsafe.Pointer(sync)), C.GLbitfield(flags), C.GLuint64(timeout))
+ return glbase.Enum(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDeleteSync.xml
+func (gl *GL) DeleteSync(sync glbase.Sync) {
+ C.gl3_3compat_glDeleteSync(gl.funcs, C.GLsync(unsafe.Pointer(sync)))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsSync.xml
+func (gl *GL) IsSync(sync glbase.Sync) bool {
+ glresult := C.gl3_3compat_glIsSync(gl.funcs, C.GLsync(unsafe.Pointer(sync)))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFenceSync.xml
+func (gl *GL) FenceSync(condition glbase.Enum, flags glbase.Bitfield) glbase.Sync {
+ glresult := C.gl3_3compat_glFenceSync(gl.funcs, C.GLenum(condition), C.GLbitfield(flags))
+ return glbase.Sync(unsafe.Pointer(glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glProvokingVertex.xml
+func (gl *GL) ProvokingVertex(mode glbase.Enum) {
+ C.gl3_3compat_glProvokingVertex(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDrawElementsInstancedBaseVertex.xml
+func (gl *GL) DrawElementsInstancedBaseVertex(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}, instancecount, basevertex int32) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3compat_glDrawElementsInstancedBaseVertex(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr, C.GLsizei(instancecount), C.GLint(basevertex))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDrawRangeElementsBaseVertex.xml
+func (gl *GL) DrawRangeElementsBaseVertex(mode glbase.Enum, start, end uint32, count int, gltype glbase.Enum, indices interface{}, basevertex int32) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3compat_glDrawRangeElementsBaseVertex(gl.funcs, C.GLenum(mode), C.GLuint(start), C.GLuint(end), C.GLsizei(count), C.GLenum(gltype), indices_ptr, C.GLint(basevertex))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDrawElementsBaseVertex.xml
+func (gl *GL) DrawElementsBaseVertex(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}, basevertex int32) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3compat_glDrawElementsBaseVertex(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr, C.GLint(basevertex))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFramebufferTexture.xml
+func (gl *GL) FramebufferTexture(target, attachment glbase.Enum, texture glbase.Texture, level int) {
+ C.gl3_3compat_glFramebufferTexture(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLuint(texture), C.GLint(level))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetBufferParameteri64v.xml
+func (gl *GL) GetBufferParameteri64v(target, pname glbase.Enum, params []int64) {
+ C.gl3_3compat_glGetBufferParameteri64v(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint64)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetInteger64i_v.xml
+func (gl *GL) GetInteger64i_v(target glbase.Enum, index uint32, data []int64) {
+ C.gl3_3compat_glGetInteger64i_v(gl.funcs, C.GLenum(target), C.GLuint(index), (*C.GLint64)(unsafe.Pointer(&data[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribP4uiv.xml
+func (gl *GL) VertexAttribP4uiv(index glbase.Attrib, gltype glbase.Enum, normalized bool, value []uint32) {
+ C.gl3_3compat_glVertexAttribP4uiv(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribP4ui.xml
+func (gl *GL) VertexAttribP4ui(index glbase.Attrib, gltype glbase.Enum, normalized bool, value uint32) {
+ C.gl3_3compat_glVertexAttribP4ui(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribP3uiv.xml
+func (gl *GL) VertexAttribP3uiv(index glbase.Attrib, gltype glbase.Enum, normalized bool, value []uint32) {
+ C.gl3_3compat_glVertexAttribP3uiv(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribP3ui.xml
+func (gl *GL) VertexAttribP3ui(index glbase.Attrib, gltype glbase.Enum, normalized bool, value uint32) {
+ C.gl3_3compat_glVertexAttribP3ui(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribP2uiv.xml
+func (gl *GL) VertexAttribP2uiv(index glbase.Attrib, gltype glbase.Enum, normalized bool, value []uint32) {
+ C.gl3_3compat_glVertexAttribP2uiv(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribP2ui.xml
+func (gl *GL) VertexAttribP2ui(index glbase.Attrib, gltype glbase.Enum, normalized bool, value uint32) {
+ C.gl3_3compat_glVertexAttribP2ui(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribP1uiv.xml
+func (gl *GL) VertexAttribP1uiv(index glbase.Attrib, gltype glbase.Enum, normalized bool, value []uint32) {
+ C.gl3_3compat_glVertexAttribP1uiv(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribP1ui.xml
+func (gl *GL) VertexAttribP1ui(index glbase.Attrib, gltype glbase.Enum, normalized bool, value uint32) {
+ C.gl3_3compat_glVertexAttribP1ui(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSecondaryColorP3uiv.xml
+func (gl *GL) SecondaryColorP3uiv(gltype glbase.Enum, color []uint32) {
+ C.gl3_3compat_glSecondaryColorP3uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&color[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSecondaryColorP3ui.xml
+func (gl *GL) SecondaryColorP3ui(gltype glbase.Enum, color uint32) {
+ C.gl3_3compat_glSecondaryColorP3ui(gl.funcs, C.GLenum(gltype), C.GLuint(color))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColorP4uiv.xml
+func (gl *GL) ColorP4uiv(gltype glbase.Enum, color []uint32) {
+ C.gl3_3compat_glColorP4uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&color[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColorP4ui.xml
+func (gl *GL) ColorP4ui(gltype glbase.Enum, color uint32) {
+ C.gl3_3compat_glColorP4ui(gl.funcs, C.GLenum(gltype), C.GLuint(color))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColorP3uiv.xml
+func (gl *GL) ColorP3uiv(gltype glbase.Enum, color []uint32) {
+ C.gl3_3compat_glColorP3uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&color[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColorP3ui.xml
+func (gl *GL) ColorP3ui(gltype glbase.Enum, color uint32) {
+ C.gl3_3compat_glColorP3ui(gl.funcs, C.GLenum(gltype), C.GLuint(color))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glNormalP3uiv.xml
+func (gl *GL) NormalP3uiv(gltype glbase.Enum, coords []uint32) {
+ C.gl3_3compat_glNormalP3uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glNormalP3ui.xml
+func (gl *GL) NormalP3ui(gltype glbase.Enum, coords uint32) {
+ C.gl3_3compat_glNormalP3ui(gl.funcs, C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoordP4uiv.xml
+func (gl *GL) MultiTexCoordP4uiv(texture, gltype glbase.Enum, coords []uint32) {
+ C.gl3_3compat_glMultiTexCoordP4uiv(gl.funcs, C.GLenum(texture), C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoordP4ui.xml
+func (gl *GL) MultiTexCoordP4ui(texture, gltype glbase.Enum, coords uint32) {
+ C.gl3_3compat_glMultiTexCoordP4ui(gl.funcs, C.GLenum(texture), C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoordP3uiv.xml
+func (gl *GL) MultiTexCoordP3uiv(texture, gltype glbase.Enum, coords []uint32) {
+ C.gl3_3compat_glMultiTexCoordP3uiv(gl.funcs, C.GLenum(texture), C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoordP3ui.xml
+func (gl *GL) MultiTexCoordP3ui(texture, gltype glbase.Enum, coords uint32) {
+ C.gl3_3compat_glMultiTexCoordP3ui(gl.funcs, C.GLenum(texture), C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoordP2uiv.xml
+func (gl *GL) MultiTexCoordP2uiv(texture, gltype glbase.Enum, coords []uint32) {
+ C.gl3_3compat_glMultiTexCoordP2uiv(gl.funcs, C.GLenum(texture), C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoordP2ui.xml
+func (gl *GL) MultiTexCoordP2ui(texture, gltype glbase.Enum, coords uint32) {
+ C.gl3_3compat_glMultiTexCoordP2ui(gl.funcs, C.GLenum(texture), C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoordP1uiv.xml
+func (gl *GL) MultiTexCoordP1uiv(texture, gltype glbase.Enum, coords []uint32) {
+ C.gl3_3compat_glMultiTexCoordP1uiv(gl.funcs, C.GLenum(texture), C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoordP1ui.xml
+func (gl *GL) MultiTexCoordP1ui(texture, gltype glbase.Enum, coords uint32) {
+ C.gl3_3compat_glMultiTexCoordP1ui(gl.funcs, C.GLenum(texture), C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoordP4uiv.xml
+func (gl *GL) TexCoordP4uiv(gltype glbase.Enum, coords []uint32) {
+ C.gl3_3compat_glTexCoordP4uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoordP4ui.xml
+func (gl *GL) TexCoordP4ui(gltype glbase.Enum, coords uint32) {
+ C.gl3_3compat_glTexCoordP4ui(gl.funcs, C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoordP3uiv.xml
+func (gl *GL) TexCoordP3uiv(gltype glbase.Enum, coords []uint32) {
+ C.gl3_3compat_glTexCoordP3uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoordP3ui.xml
+func (gl *GL) TexCoordP3ui(gltype glbase.Enum, coords uint32) {
+ C.gl3_3compat_glTexCoordP3ui(gl.funcs, C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoordP2uiv.xml
+func (gl *GL) TexCoordP2uiv(gltype glbase.Enum, coords []uint32) {
+ C.gl3_3compat_glTexCoordP2uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoordP2ui.xml
+func (gl *GL) TexCoordP2ui(gltype glbase.Enum, coords uint32) {
+ C.gl3_3compat_glTexCoordP2ui(gl.funcs, C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoordP1uiv.xml
+func (gl *GL) TexCoordP1uiv(gltype glbase.Enum, coords []uint32) {
+ C.gl3_3compat_glTexCoordP1uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoordP1ui.xml
+func (gl *GL) TexCoordP1ui(gltype glbase.Enum, coords uint32) {
+ C.gl3_3compat_glTexCoordP1ui(gl.funcs, C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexP4uiv.xml
+func (gl *GL) VertexP4uiv(gltype glbase.Enum, value []uint32) {
+ C.gl3_3compat_glVertexP4uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexP4ui.xml
+func (gl *GL) VertexP4ui(gltype glbase.Enum, value uint32) {
+ C.gl3_3compat_glVertexP4ui(gl.funcs, C.GLenum(gltype), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexP3uiv.xml
+func (gl *GL) VertexP3uiv(gltype glbase.Enum, value []uint32) {
+ C.gl3_3compat_glVertexP3uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexP3ui.xml
+func (gl *GL) VertexP3ui(gltype glbase.Enum, value uint32) {
+ C.gl3_3compat_glVertexP3ui(gl.funcs, C.GLenum(gltype), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexP2uiv.xml
+func (gl *GL) VertexP2uiv(gltype glbase.Enum, value []uint32) {
+ C.gl3_3compat_glVertexP2uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexP2ui.xml
+func (gl *GL) VertexP2ui(gltype glbase.Enum, value uint32) {
+ C.gl3_3compat_glVertexP2ui(gl.funcs, C.GLenum(gltype), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetQueryObjectui64v.xml
+func (gl *GL) GetQueryObjectui64v(id uint32, pname glbase.Enum, params []uint64) {
+ C.gl3_3compat_glGetQueryObjectui64v(gl.funcs, C.GLuint(id), C.GLenum(pname), (*C.GLuint64)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetQueryObjecti64v.xml
+func (gl *GL) GetQueryObjecti64v(id uint32, pname glbase.Enum, params []int64) {
+ C.gl3_3compat_glGetQueryObjecti64v(gl.funcs, C.GLuint(id), C.GLenum(pname), (*C.GLint64)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glQueryCounter.xml
+func (gl *GL) QueryCounter(id uint32, target glbase.Enum) {
+ C.gl3_3compat_glQueryCounter(gl.funcs, C.GLuint(id), C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetSamplerParameterIuiv.xml
+func (gl *GL) GetSamplerParameterIuiv(sampler uint32, pname glbase.Enum, params []uint32) {
+ C.gl3_3compat_glGetSamplerParameterIuiv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetSamplerParameterfv.xml
+func (gl *GL) GetSamplerParameterfv(sampler uint32, pname glbase.Enum, params []float32) {
+ C.gl3_3compat_glGetSamplerParameterfv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetSamplerParameterIiv.xml
+func (gl *GL) GetSamplerParameterIiv(sampler uint32, pname glbase.Enum, params []int32) {
+ C.gl3_3compat_glGetSamplerParameterIiv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetSamplerParameteriv.xml
+func (gl *GL) GetSamplerParameteriv(sampler uint32, pname glbase.Enum, params []int32) {
+ C.gl3_3compat_glGetSamplerParameteriv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSamplerParameterIuiv.xml
+func (gl *GL) SamplerParameterIuiv(sampler uint32, pname glbase.Enum, param []uint32) {
+ C.gl3_3compat_glSamplerParameterIuiv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&param[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSamplerParameterIiv.xml
+func (gl *GL) SamplerParameterIiv(sampler uint32, pname glbase.Enum, param []int32) {
+ C.gl3_3compat_glSamplerParameterIiv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&param[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSamplerParameterfv.xml
+func (gl *GL) SamplerParameterfv(sampler uint32, pname glbase.Enum, param []float32) {
+ C.gl3_3compat_glSamplerParameterfv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&param[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSamplerParameterf.xml
+func (gl *GL) SamplerParameterf(sampler uint32, pname glbase.Enum, param float32) {
+ C.gl3_3compat_glSamplerParameterf(gl.funcs, C.GLuint(sampler), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSamplerParameteriv.xml
+func (gl *GL) SamplerParameteriv(sampler uint32, pname glbase.Enum, param []int32) {
+ C.gl3_3compat_glSamplerParameteriv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&param[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSamplerParameteri.xml
+func (gl *GL) SamplerParameteri(sampler uint32, pname glbase.Enum, param int32) {
+ C.gl3_3compat_glSamplerParameteri(gl.funcs, C.GLuint(sampler), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBindSampler.xml
+func (gl *GL) BindSampler(unit, sampler uint32) {
+ C.gl3_3compat_glBindSampler(gl.funcs, C.GLuint(unit), C.GLuint(sampler))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsSampler.xml
+func (gl *GL) IsSampler(sampler uint32) bool {
+ glresult := C.gl3_3compat_glIsSampler(gl.funcs, C.GLuint(sampler))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDeleteSamplers.xml
+func (gl *GL) DeleteSamplers(count int, samplers []uint32) {
+ C.gl3_3compat_glDeleteSamplers(gl.funcs, C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&samplers[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGenSamplers.xml
+func (gl *GL) GenSamplers(count int, samplers []uint32) {
+ C.gl3_3compat_glGenSamplers(gl.funcs, C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&samplers[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetFragDataIndex.xml
+func (gl *GL) GetFragDataIndex(program glbase.Program, name []byte) int32 {
+ glresult := C.gl3_3compat_glGetFragDataIndex(gl.funcs, C.GLuint(program), (*C.GLchar)(unsafe.Pointer(&name[0])))
+ return int32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBindFragDataLocationIndexed.xml
+func (gl *GL) BindFragDataLocationIndexed(program glbase.Program, colorNumber, index uint32, name []byte) {
+ C.gl3_3compat_glBindFragDataLocationIndexed(gl.funcs, C.GLuint(program), C.GLuint(colorNumber), C.GLuint(index), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribDivisor.xml
+func (gl *GL) VertexAttribDivisor(index glbase.Attrib, divisor uint32) {
+ C.gl3_3compat_glVertexAttribDivisor(gl.funcs, C.GLuint(index), C.GLuint(divisor))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTranslatef.xml
+func (gl *GL) Translatef(x, y, z float32) {
+ C.gl3_3compat_glTranslatef(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTranslated.xml
+func (gl *GL) Translated(x, y, z float64) {
+ C.gl3_3compat_glTranslated(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glScalef.xml
+func (gl *GL) Scalef(x, y, z float32) {
+ C.gl3_3compat_glScalef(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glScaled.xml
+func (gl *GL) Scaled(x, y, z float64) {
+ C.gl3_3compat_glScaled(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRotatef.xml
+func (gl *GL) Rotatef(angle, x, y, z float32) {
+ C.gl3_3compat_glRotatef(gl.funcs, C.GLfloat(angle), C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRotated.xml
+func (gl *GL) Rotated(angle, x, y, z float64) {
+ C.gl3_3compat_glRotated(gl.funcs, C.GLdouble(angle), C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPushMatrix.xml
+func (gl *GL) PushMatrix() {
+ C.gl3_3compat_glPushMatrix(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPopMatrix.xml
+func (gl *GL) PopMatrix() {
+ C.gl3_3compat_glPopMatrix(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glOrtho.xml
+func (gl *GL) Ortho(left, right, bottom, top, zNear, zFar float64) {
+ C.gl3_3compat_glOrtho(gl.funcs, C.GLdouble(left), C.GLdouble(right), C.GLdouble(bottom), C.GLdouble(top), C.GLdouble(zNear), C.GLdouble(zFar))
+}
+
+// MultMatrixd multiplies the current matrix with the provided matrix.
+//
+// The m parameter must hold 16 consecutive elements of a 4x4 column-major matrix.
+//
+// The current matrix is determined by the current matrix mode (see
+// MatrixMode). It is either the projection matrix, modelview matrix, or the
+// texture matrix.
+//
+// For example, if the current matrix is C and the coordinates to be transformed
+// are v = (v[0], v[1], v[2], v[3]), then the current transformation is C × v, or
+//
+// c[0] c[4] c[8] c[12] v[0]
+// c[1] c[5] c[9] c[13] v[1]
+// c[2] c[6] c[10] c[14] X v[2]
+// c[3] c[7] c[11] c[15] v[3]
+//
+// Calling MultMatrix with an argument of m = m[0], m[1], ..., m[15]
+// replaces the current transformation with (C X M) x v, or
+//
+// c[0] c[4] c[8] c[12] m[0] m[4] m[8] m[12] v[0]
+// c[1] c[5] c[9] c[13] m[1] m[5] m[9] m[13] v[1]
+// c[2] c[6] c[10] c[14] X m[2] m[6] m[10] m[14] X v[2]
+// c[3] c[7] c[11] c[15] m[3] m[7] m[11] m[15] v[3]
+//
+// Where 'X' denotes matrix multiplication, and v is represented as a 4x1 matrix.
+//
+// While the elements of the matrix may be specified with single or double
+// precision, the GL may store or operate on these values in less-than-single
+// precision.
+//
+// In many computer languages, 4×4 arrays are represented in row-major
+// order. The transformations just described represent these matrices in
+// column-major order. The order of the multiplication is important. For
+// example, if the current transformation is a rotation, and MultMatrix is
+// called with a translation matrix, the translation is done directly on the
+// coordinates to be transformed, while the rotation is done on the results
+// of that translation.
+//
+// GL.INVALID_OPERATION is generated if MultMatrix is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) MultMatrixd(m []float64) {
+ if len(m) != 16 {
+ panic("parameter m must have length 16 for the 4x4 matrix")
+ }
+ C.gl3_3compat_glMultMatrixd(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&m[0])))
+}
+
+// MultMatrixf multiplies the current matrix with the provided matrix.
+//
+// The m parameter must hold 16 consecutive elements of a 4x4 column-major matrix.
+//
+// The current matrix is determined by the current matrix mode (see
+// MatrixMode). It is either the projection matrix, modelview matrix, or the
+// texture matrix.
+//
+// For example, if the current matrix is C and the coordinates to be transformed
+// are v = (v[0], v[1], v[2], v[3]), then the current transformation is C × v, or
+//
+// c[0] c[4] c[8] c[12] v[0]
+// c[1] c[5] c[9] c[13] v[1]
+// c[2] c[6] c[10] c[14] X v[2]
+// c[3] c[7] c[11] c[15] v[3]
+//
+// Calling MultMatrix with an argument of m = m[0], m[1], ..., m[15]
+// replaces the current transformation with (C X M) x v, or
+//
+// c[0] c[4] c[8] c[12] m[0] m[4] m[8] m[12] v[0]
+// c[1] c[5] c[9] c[13] m[1] m[5] m[9] m[13] v[1]
+// c[2] c[6] c[10] c[14] X m[2] m[6] m[10] m[14] X v[2]
+// c[3] c[7] c[11] c[15] m[3] m[7] m[11] m[15] v[3]
+//
+// Where 'X' denotes matrix multiplication, and v is represented as a 4x1 matrix.
+//
+// While the elements of the matrix may be specified with single or double
+// precision, the GL may store or operate on these values in less-than-single
+// precision.
+//
+// In many computer languages, 4×4 arrays are represented in row-major
+// order. The transformations just described represent these matrices in
+// column-major order. The order of the multiplication is important. For
+// example, if the current transformation is a rotation, and MultMatrix is
+// called with a translation matrix, the translation is done directly on the
+// coordinates to be transformed, while the rotation is done on the results
+// of that translation.
+//
+// GL.INVALID_OPERATION is generated if MultMatrix is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) MultMatrixf(m []float32) {
+ if len(m) != 16 {
+ panic("parameter m must have length 16 for the 4x4 matrix")
+ }
+ C.gl3_3compat_glMultMatrixf(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMatrixMode.xml
+func (gl *GL) MatrixMode(mode glbase.Enum) {
+ C.gl3_3compat_glMatrixMode(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glLoadMatrixd.xml
+func (gl *GL) LoadMatrixd(m []float64) {
+ C.gl3_3compat_glLoadMatrixd(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glLoadMatrixf.xml
+func (gl *GL) LoadMatrixf(m []float32) {
+ C.gl3_3compat_glLoadMatrixf(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glLoadIdentity.xml
+func (gl *GL) LoadIdentity() {
+ C.gl3_3compat_glLoadIdentity(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFrustum.xml
+func (gl *GL) Frustum(left, right, bottom, top, zNear, zFar float64) {
+ C.gl3_3compat_glFrustum(gl.funcs, C.GLdouble(left), C.GLdouble(right), C.GLdouble(bottom), C.GLdouble(top), C.GLdouble(zNear), C.GLdouble(zFar))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsList.xml
+func (gl *GL) IsList(list uint32) bool {
+ glresult := C.gl3_3compat_glIsList(gl.funcs, C.GLuint(list))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTexGeniv.xml
+func (gl *GL) GetTexGeniv(coord, pname glbase.Enum, params []int32) {
+ C.gl3_3compat_glGetTexGeniv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTexGenfv.xml
+func (gl *GL) GetTexGenfv(coord, pname glbase.Enum, params []float32) {
+ C.gl3_3compat_glGetTexGenfv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTexGendv.xml
+func (gl *GL) GetTexGendv(coord, pname glbase.Enum, params []float64) {
+ C.gl3_3compat_glGetTexGendv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTexEnviv.xml
+func (gl *GL) GetTexEnviv(target, pname glbase.Enum, params []int32) {
+ C.gl3_3compat_glGetTexEnviv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTexEnvfv.xml
+func (gl *GL) GetTexEnvfv(target, pname glbase.Enum, params []float32) {
+ C.gl3_3compat_glGetTexEnvfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetPolygonStipple.xml
+func (gl *GL) GetPolygonStipple(mask []uint8) {
+ C.gl3_3compat_glGetPolygonStipple(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&mask[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetPixelMapusv.xml
+func (gl *GL) GetPixelMapusv(glmap glbase.Enum, values []uint16) {
+ C.gl3_3compat_glGetPixelMapusv(gl.funcs, C.GLenum(glmap), (*C.GLushort)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetPixelMapuiv.xml
+func (gl *GL) GetPixelMapuiv(glmap glbase.Enum, values []uint32) {
+ C.gl3_3compat_glGetPixelMapuiv(gl.funcs, C.GLenum(glmap), (*C.GLuint)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetPixelMapfv.xml
+func (gl *GL) GetPixelMapfv(glmap glbase.Enum, values []float32) {
+ C.gl3_3compat_glGetPixelMapfv(gl.funcs, C.GLenum(glmap), (*C.GLfloat)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetMaterialiv.xml
+func (gl *GL) GetMaterialiv(face, pname glbase.Enum, params []int32) {
+ C.gl3_3compat_glGetMaterialiv(gl.funcs, C.GLenum(face), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetMaterialfv.xml
+func (gl *GL) GetMaterialfv(face, pname glbase.Enum, params []float32) {
+ C.gl3_3compat_glGetMaterialfv(gl.funcs, C.GLenum(face), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetMapiv.xml
+func (gl *GL) GetMapiv(target, query glbase.Enum, v []int32) {
+ C.gl3_3compat_glGetMapiv(gl.funcs, C.GLenum(target), C.GLenum(query), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetMapfv.xml
+func (gl *GL) GetMapfv(target, query glbase.Enum, v []float32) {
+ C.gl3_3compat_glGetMapfv(gl.funcs, C.GLenum(target), C.GLenum(query), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetMapdv.xml
+func (gl *GL) GetMapdv(target, query glbase.Enum, v []float64) {
+ C.gl3_3compat_glGetMapdv(gl.funcs, C.GLenum(target), C.GLenum(query), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetLightiv.xml
+func (gl *GL) GetLightiv(light, pname glbase.Enum, params []int32) {
+ C.gl3_3compat_glGetLightiv(gl.funcs, C.GLenum(light), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetLightfv.xml
+func (gl *GL) GetLightfv(light, pname glbase.Enum, params []float32) {
+ C.gl3_3compat_glGetLightfv(gl.funcs, C.GLenum(light), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetClipPlane.xml
+func (gl *GL) GetClipPlane(plane glbase.Enum, equation []float64) {
+ C.gl3_3compat_glGetClipPlane(gl.funcs, C.GLenum(plane), (*C.GLdouble)(unsafe.Pointer(&equation[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDrawPixels.xml
+func (gl *GL) DrawPixels(width, height int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3compat_glDrawPixels(gl.funcs, C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCopyPixels.xml
+func (gl *GL) CopyPixels(x, y, width, height int, gltype glbase.Enum) {
+ C.gl3_3compat_glCopyPixels(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height), C.GLenum(gltype))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPixelMapusv.xml
+func (gl *GL) PixelMapusv(glmap glbase.Enum, mapsize int32, values []uint16) {
+ C.gl3_3compat_glPixelMapusv(gl.funcs, C.GLenum(glmap), C.GLint(mapsize), (*C.GLushort)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPixelMapuiv.xml
+func (gl *GL) PixelMapuiv(glmap glbase.Enum, mapsize int32, values []uint32) {
+ C.gl3_3compat_glPixelMapuiv(gl.funcs, C.GLenum(glmap), C.GLint(mapsize), (*C.GLuint)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPixelMapfv.xml
+func (gl *GL) PixelMapfv(glmap glbase.Enum, mapsize int32, values []float32) {
+ C.gl3_3compat_glPixelMapfv(gl.funcs, C.GLenum(glmap), C.GLint(mapsize), (*C.GLfloat)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPixelTransferi.xml
+func (gl *GL) PixelTransferi(pname glbase.Enum, param int32) {
+ C.gl3_3compat_glPixelTransferi(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPixelTransferf.xml
+func (gl *GL) PixelTransferf(pname glbase.Enum, param float32) {
+ C.gl3_3compat_glPixelTransferf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPixelZoom.xml
+func (gl *GL) PixelZoom(xfactor, yfactor float32) {
+ C.gl3_3compat_glPixelZoom(gl.funcs, C.GLfloat(xfactor), C.GLfloat(yfactor))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glAlphaFunc.xml
+func (gl *GL) AlphaFunc(glfunc glbase.Enum, ref float32) {
+ C.gl3_3compat_glAlphaFunc(gl.funcs, C.GLenum(glfunc), C.GLfloat(ref))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEvalPoint2.xml
+func (gl *GL) EvalPoint2(i, j int32) {
+ C.gl3_3compat_glEvalPoint2(gl.funcs, C.GLint(i), C.GLint(j))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEvalMesh2.xml
+func (gl *GL) EvalMesh2(mode glbase.Enum, i1, i2, j1, j2 int32) {
+ C.gl3_3compat_glEvalMesh2(gl.funcs, C.GLenum(mode), C.GLint(i1), C.GLint(i2), C.GLint(j1), C.GLint(j2))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEvalPoint1.xml
+func (gl *GL) EvalPoint1(i int32) {
+ C.gl3_3compat_glEvalPoint1(gl.funcs, C.GLint(i))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEvalMesh1.xml
+func (gl *GL) EvalMesh1(mode glbase.Enum, i1, i2 int32) {
+ C.gl3_3compat_glEvalMesh1(gl.funcs, C.GLenum(mode), C.GLint(i1), C.GLint(i2))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEvalCoord2fv.xml
+func (gl *GL) EvalCoord2fv(u []float32) {
+ if len(u) != 2 {
+ panic("parameter u has incorrect length")
+ }
+ C.gl3_3compat_glEvalCoord2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&u[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEvalCoord2f.xml
+func (gl *GL) EvalCoord2f(u, v float32) {
+ C.gl3_3compat_glEvalCoord2f(gl.funcs, C.GLfloat(u), C.GLfloat(v))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEvalCoord2dv.xml
+func (gl *GL) EvalCoord2dv(u []float64) {
+ if len(u) != 2 {
+ panic("parameter u has incorrect length")
+ }
+ C.gl3_3compat_glEvalCoord2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&u[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEvalCoord2d.xml
+func (gl *GL) EvalCoord2d(u, v float64) {
+ C.gl3_3compat_glEvalCoord2d(gl.funcs, C.GLdouble(u), C.GLdouble(v))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEvalCoord1fv.xml
+func (gl *GL) EvalCoord1fv(u []float32) {
+ C.gl3_3compat_glEvalCoord1fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&u[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEvalCoord1f.xml
+func (gl *GL) EvalCoord1f(u float32) {
+ C.gl3_3compat_glEvalCoord1f(gl.funcs, C.GLfloat(u))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEvalCoord1dv.xml
+func (gl *GL) EvalCoord1dv(u []float64) {
+ C.gl3_3compat_glEvalCoord1dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&u[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEvalCoord1d.xml
+func (gl *GL) EvalCoord1d(u float64) {
+ C.gl3_3compat_glEvalCoord1d(gl.funcs, C.GLdouble(u))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMapGrid2f.xml
+func (gl *GL) MapGrid2f(un int32, u1, u2 float32, vn int32, v1, v2 float32) {
+ C.gl3_3compat_glMapGrid2f(gl.funcs, C.GLint(un), C.GLfloat(u1), C.GLfloat(u2), C.GLint(vn), C.GLfloat(v1), C.GLfloat(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMapGrid2d.xml
+func (gl *GL) MapGrid2d(un int32, u1, u2 float64, vn int32, v1, v2 float64) {
+ C.gl3_3compat_glMapGrid2d(gl.funcs, C.GLint(un), C.GLdouble(u1), C.GLdouble(u2), C.GLint(vn), C.GLdouble(v1), C.GLdouble(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMapGrid1f.xml
+func (gl *GL) MapGrid1f(un int32, u1, u2 float32) {
+ C.gl3_3compat_glMapGrid1f(gl.funcs, C.GLint(un), C.GLfloat(u1), C.GLfloat(u2))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMapGrid1d.xml
+func (gl *GL) MapGrid1d(un int32, u1, u2 float64) {
+ C.gl3_3compat_glMapGrid1d(gl.funcs, C.GLint(un), C.GLdouble(u1), C.GLdouble(u2))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMap2f.xml
+func (gl *GL) Map2f(target glbase.Enum, u1, u2 float32, ustride, uorder int32, v1, v2 float32, vstride, vorder int32, points []float32) {
+ C.gl3_3compat_glMap2f(gl.funcs, C.GLenum(target), C.GLfloat(u1), C.GLfloat(u2), C.GLint(ustride), C.GLint(uorder), C.GLfloat(v1), C.GLfloat(v2), C.GLint(vstride), C.GLint(vorder), (*C.GLfloat)(unsafe.Pointer(&points[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMap2d.xml
+func (gl *GL) Map2d(target glbase.Enum, u1, u2 float64, ustride, uorder int32, v1, v2 float64, vstride, vorder int32, points []float64) {
+ C.gl3_3compat_glMap2d(gl.funcs, C.GLenum(target), C.GLdouble(u1), C.GLdouble(u2), C.GLint(ustride), C.GLint(uorder), C.GLdouble(v1), C.GLdouble(v2), C.GLint(vstride), C.GLint(vorder), (*C.GLdouble)(unsafe.Pointer(&points[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMap1f.xml
+func (gl *GL) Map1f(target glbase.Enum, u1, u2 float32, stride, order int, points []float32) {
+ C.gl3_3compat_glMap1f(gl.funcs, C.GLenum(target), C.GLfloat(u1), C.GLfloat(u2), C.GLint(stride), C.GLint(order), (*C.GLfloat)(unsafe.Pointer(&points[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMap1d.xml
+func (gl *GL) Map1d(target glbase.Enum, u1, u2 float64, stride, order int, points []float64) {
+ C.gl3_3compat_glMap1d(gl.funcs, C.GLenum(target), C.GLdouble(u1), C.GLdouble(u2), C.GLint(stride), C.GLint(order), (*C.GLdouble)(unsafe.Pointer(&points[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPushAttrib.xml
+func (gl *GL) PushAttrib(mask glbase.Bitfield) {
+ C.gl3_3compat_glPushAttrib(gl.funcs, C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPopAttrib.xml
+func (gl *GL) PopAttrib() {
+ C.gl3_3compat_glPopAttrib(gl.funcs)
+}
+
+// Accum executes an operation on the accumulation buffer.
+//
+// Parameter op defines the accumulation buffer operation (GL.ACCUM, GL.LOAD,
+// GL.ADD, GL.MULT, or GL.RETURN) and specifies how the value parameter is
+// used.
+//
+// The accumulation buffer is an extended-range color buffer. Images are not
+// rendered into it. Rather, images rendered into one of the color buffers
+// are added to the contents of the accumulation buffer after rendering.
+// Effects such as antialiasing (of points, lines, and polygons), motion
+// blur, and depth of field can be created by accumulating images generated
+// with different transformation matrices.
+//
+// Each pixel in the accumulation buffer consists of red, green, blue, and
+// alpha values. The number of bits per component in the accumulation buffer
+// depends on the implementation. You can examine this number by calling
+// GetIntegerv four times, with arguments GL.ACCUM_RED_BITS,
+// GL.ACCUM_GREEN_BITS, GL.ACCUM_BLUE_BITS, and GL.ACCUM_ALPHA_BITS.
+// Regardless of the number of bits per component, the range of values stored
+// by each component is (-1, 1). The accumulation buffer pixels are mapped
+// one-to-one with frame buffer pixels.
+//
+// All accumulation buffer operations are limited to the area of the current
+// scissor box and applied identically to the red, green, blue, and alpha
+// components of each pixel. If a Accum operation results in a value outside
+// the range (-1, 1), the contents of an accumulation buffer pixel component
+// are undefined.
+//
+// The operations are as follows:
+//
+// GL.ACCUM
+// Obtains R, G, B, and A values from the buffer currently selected for
+// reading (see ReadBuffer). Each component value is divided by 2 n -
+// 1 , where n is the number of bits allocated to each color component
+// in the currently selected buffer. The result is a floating-point
+// value in the range 0 1 , which is multiplied by value and added to
+// the corresponding pixel component in the accumulation buffer,
+// thereby updating the accumulation buffer.
+//
+// GL.LOAD
+// Similar to GL.ACCUM, except that the current value in the
+// accumulation buffer is not used in the calculation of the new value.
+// That is, the R, G, B, and A values from the currently selected
+// buffer are divided by 2 n - 1 , multiplied by value, and then stored
+// in the corresponding accumulation buffer cell, overwriting the
+// current value.
+//
+// GL.ADD
+// Adds value to each R, G, B, and A in the accumulation buffer.
+//
+// GL.MULT
+// Multiplies each R, G, B, and A in the accumulation buffer by value
+// and returns the scaled component to its corresponding accumulation
+// buffer location.
+//
+// GL.RETURN
+// Transfers accumulation buffer values to the color buffer or buffers
+// currently selected for writing. Each R, G, B, and A component is
+// multiplied by value, then multiplied by 2 n - 1 , clamped to the
+// range 0 2 n - 1 , and stored in the corresponding display buffer
+// cell. The only fragment operations that are applied to this transfer
+// are pixel ownership, scissor, dithering, and color writemasks.
+//
+// To clear the accumulation buffer, call ClearAccum with R, G, B, and A
+// values to set it to, then call Clear with the accumulation buffer
+// enabled.
+//
+// Error GL.INVALID_ENUM is generated if op is not an accepted value.
+// GL.INVALID_OPERATION is generated if there is no accumulation buffer.
+// GL.INVALID_OPERATION is generated if Accum is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) Accum(op glbase.Enum, value float32) {
+ C.gl3_3compat_glAccum(gl.funcs, C.GLenum(op), C.GLfloat(value))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIndexMask.xml
+func (gl *GL) IndexMask(mask uint32) {
+ C.gl3_3compat_glIndexMask(gl.funcs, C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClearIndex.xml
+func (gl *GL) ClearIndex(c float32) {
+ C.gl3_3compat_glClearIndex(gl.funcs, C.GLfloat(c))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClearAccum.xml
+func (gl *GL) ClearAccum(red, green, blue, alpha float32) {
+ C.gl3_3compat_glClearAccum(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPushName.xml
+func (gl *GL) PushName(name uint32) {
+ C.gl3_3compat_glPushName(gl.funcs, C.GLuint(name))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPopName.xml
+func (gl *GL) PopName() {
+ C.gl3_3compat_glPopName(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPassThrough.xml
+func (gl *GL) PassThrough(token float32) {
+ C.gl3_3compat_glPassThrough(gl.funcs, C.GLfloat(token))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glLoadName.xml
+func (gl *GL) LoadName(name uint32) {
+ C.gl3_3compat_glLoadName(gl.funcs, C.GLuint(name))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glInitNames.xml
+func (gl *GL) InitNames() {
+ C.gl3_3compat_glInitNames(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRenderMode.xml
+func (gl *GL) RenderMode(mode glbase.Enum) int32 {
+ glresult := C.gl3_3compat_glRenderMode(gl.funcs, C.GLenum(mode))
+ return int32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSelectBuffer.xml
+func (gl *GL) SelectBuffer(size int, buffer []glbase.Buffer) {
+ C.gl3_3compat_glSelectBuffer(gl.funcs, C.GLsizei(size), (*C.GLuint)(unsafe.Pointer(&buffer[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFeedbackBuffer.xml
+func (gl *GL) FeedbackBuffer(size int, gltype glbase.Enum, buffer []float32) {
+ C.gl3_3compat_glFeedbackBuffer(gl.funcs, C.GLsizei(size), C.GLenum(gltype), (*C.GLfloat)(unsafe.Pointer(&buffer[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexGeniv.xml
+func (gl *GL) TexGeniv(coord, pname glbase.Enum, params []int32) {
+ C.gl3_3compat_glTexGeniv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexGeni.xml
+func (gl *GL) TexGeni(coord, pname glbase.Enum, param int32) {
+ C.gl3_3compat_glTexGeni(gl.funcs, C.GLenum(coord), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexGenfv.xml
+func (gl *GL) TexGenfv(coord, pname glbase.Enum, params []float32) {
+ C.gl3_3compat_glTexGenfv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexGenf.xml
+func (gl *GL) TexGenf(coord, pname glbase.Enum, param float32) {
+ C.gl3_3compat_glTexGenf(gl.funcs, C.GLenum(coord), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexGendv.xml
+func (gl *GL) TexGendv(coord, pname glbase.Enum, params []float64) {
+ C.gl3_3compat_glTexGendv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexGend.xml
+func (gl *GL) TexGend(coord, pname glbase.Enum, param float64) {
+ C.gl3_3compat_glTexGend(gl.funcs, C.GLenum(coord), C.GLenum(pname), C.GLdouble(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexEnviv.xml
+func (gl *GL) TexEnviv(target, pname glbase.Enum, params []int32) {
+ C.gl3_3compat_glTexEnviv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexEnvi.xml
+func (gl *GL) TexEnvi(target, pname glbase.Enum, param int32) {
+ C.gl3_3compat_glTexEnvi(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexEnvfv.xml
+func (gl *GL) TexEnvfv(target, pname glbase.Enum, params []float32) {
+ C.gl3_3compat_glTexEnvfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexEnvf.xml
+func (gl *GL) TexEnvf(target, pname glbase.Enum, param float32) {
+ C.gl3_3compat_glTexEnvf(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glShadeModel.xml
+func (gl *GL) ShadeModel(mode glbase.Enum) {
+ C.gl3_3compat_glShadeModel(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPolygonStipple.xml
+func (gl *GL) PolygonStipple(mask []uint8) {
+ C.gl3_3compat_glPolygonStipple(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&mask[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMaterialiv.xml
+func (gl *GL) Materialiv(face, pname glbase.Enum, params []int32) {
+ C.gl3_3compat_glMaterialiv(gl.funcs, C.GLenum(face), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMateriali.xml
+func (gl *GL) Materiali(face, pname glbase.Enum, param int32) {
+ C.gl3_3compat_glMateriali(gl.funcs, C.GLenum(face), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMaterialfv.xml
+func (gl *GL) Materialfv(face, pname glbase.Enum, params []float32) {
+ C.gl3_3compat_glMaterialfv(gl.funcs, C.GLenum(face), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMaterialf.xml
+func (gl *GL) Materialf(face, pname glbase.Enum, param float32) {
+ C.gl3_3compat_glMaterialf(gl.funcs, C.GLenum(face), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glLineStipple.xml
+func (gl *GL) LineStipple(factor int32, pattern uint16) {
+ C.gl3_3compat_glLineStipple(gl.funcs, C.GLint(factor), C.GLushort(pattern))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glLightModeliv.xml
+func (gl *GL) LightModeliv(pname glbase.Enum, params []int32) {
+ C.gl3_3compat_glLightModeliv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glLightModeli.xml
+func (gl *GL) LightModeli(pname glbase.Enum, param int32) {
+ C.gl3_3compat_glLightModeli(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glLightModelfv.xml
+func (gl *GL) LightModelfv(pname glbase.Enum, params []float32) {
+ C.gl3_3compat_glLightModelfv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glLightModelf.xml
+func (gl *GL) LightModelf(pname glbase.Enum, param float32) {
+ C.gl3_3compat_glLightModelf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glLightiv.xml
+func (gl *GL) Lightiv(light, pname glbase.Enum, params []int32) {
+ C.gl3_3compat_glLightiv(gl.funcs, C.GLenum(light), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glLighti.xml
+func (gl *GL) Lighti(light, pname glbase.Enum, param int32) {
+ C.gl3_3compat_glLighti(gl.funcs, C.GLenum(light), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glLightfv.xml
+func (gl *GL) Lightfv(light, pname glbase.Enum, params []float32) {
+ C.gl3_3compat_glLightfv(gl.funcs, C.GLenum(light), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glLightf.xml
+func (gl *GL) Lightf(light, pname glbase.Enum, param float32) {
+ C.gl3_3compat_glLightf(gl.funcs, C.GLenum(light), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFogiv.xml
+func (gl *GL) Fogiv(pname glbase.Enum, params []int32) {
+ C.gl3_3compat_glFogiv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFogi.xml
+func (gl *GL) Fogi(pname glbase.Enum, param int32) {
+ C.gl3_3compat_glFogi(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFogfv.xml
+func (gl *GL) Fogfv(pname glbase.Enum, params []float32) {
+ C.gl3_3compat_glFogfv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFogf.xml
+func (gl *GL) Fogf(pname glbase.Enum, param float32) {
+ C.gl3_3compat_glFogf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColorMaterial.xml
+func (gl *GL) ColorMaterial(face, mode glbase.Enum) {
+ C.gl3_3compat_glColorMaterial(gl.funcs, C.GLenum(face), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClipPlane.xml
+func (gl *GL) ClipPlane(plane glbase.Enum, equation []float64) {
+ C.gl3_3compat_glClipPlane(gl.funcs, C.GLenum(plane), (*C.GLdouble)(unsafe.Pointer(&equation[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex4sv.xml
+func (gl *GL) Vertex4sv(v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glVertex4sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex4s.xml
+func (gl *GL) Vertex4s(x, y, z, w int16) {
+ C.gl3_3compat_glVertex4s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z), C.GLshort(w))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex4iv.xml
+func (gl *GL) Vertex4iv(v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glVertex4iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex4i.xml
+func (gl *GL) Vertex4i(x, y, z, w int) {
+ C.gl3_3compat_glVertex4i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z), C.GLint(w))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex4fv.xml
+func (gl *GL) Vertex4fv(v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glVertex4fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex4f.xml
+func (gl *GL) Vertex4f(x, y, z, w float32) {
+ C.gl3_3compat_glVertex4f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z), C.GLfloat(w))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex4dv.xml
+func (gl *GL) Vertex4dv(v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glVertex4dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex4d.xml
+func (gl *GL) Vertex4d(x, y, z, w float64) {
+ C.gl3_3compat_glVertex4d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z), C.GLdouble(w))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex3sv.xml
+func (gl *GL) Vertex3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glVertex3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex3s.xml
+func (gl *GL) Vertex3s(x, y, z int16) {
+ C.gl3_3compat_glVertex3s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex3iv.xml
+func (gl *GL) Vertex3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glVertex3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex3i.xml
+func (gl *GL) Vertex3i(x, y, z int) {
+ C.gl3_3compat_glVertex3i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex3fv.xml
+func (gl *GL) Vertex3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glVertex3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex3f.xml
+func (gl *GL) Vertex3f(x, y, z float32) {
+ C.gl3_3compat_glVertex3f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex3dv.xml
+func (gl *GL) Vertex3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glVertex3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex3d.xml
+func (gl *GL) Vertex3d(x, y, z float64) {
+ C.gl3_3compat_glVertex3d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex2sv.xml
+func (gl *GL) Vertex2sv(v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glVertex2sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex2s.xml
+func (gl *GL) Vertex2s(x, y int16) {
+ C.gl3_3compat_glVertex2s(gl.funcs, C.GLshort(x), C.GLshort(y))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex2iv.xml
+func (gl *GL) Vertex2iv(v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glVertex2iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex2i.xml
+func (gl *GL) Vertex2i(x, y int) {
+ C.gl3_3compat_glVertex2i(gl.funcs, C.GLint(x), C.GLint(y))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex2fv.xml
+func (gl *GL) Vertex2fv(v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glVertex2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex2f.xml
+func (gl *GL) Vertex2f(x, y float32) {
+ C.gl3_3compat_glVertex2f(gl.funcs, C.GLfloat(x), C.GLfloat(y))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex2dv.xml
+func (gl *GL) Vertex2dv(v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glVertex2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertex2d.xml
+func (gl *GL) Vertex2d(x, y float64) {
+ C.gl3_3compat_glVertex2d(gl.funcs, C.GLdouble(x), C.GLdouble(y))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord4sv.xml
+func (gl *GL) TexCoord4sv(v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glTexCoord4sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord4s.xml
+func (gl *GL) TexCoord4s(s, t, r, q int16) {
+ C.gl3_3compat_glTexCoord4s(gl.funcs, C.GLshort(s), C.GLshort(t), C.GLshort(r), C.GLshort(q))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord4iv.xml
+func (gl *GL) TexCoord4iv(v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glTexCoord4iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord4i.xml
+func (gl *GL) TexCoord4i(s, t, r, q int32) {
+ C.gl3_3compat_glTexCoord4i(gl.funcs, C.GLint(s), C.GLint(t), C.GLint(r), C.GLint(q))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord4fv.xml
+func (gl *GL) TexCoord4fv(v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glTexCoord4fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord4f.xml
+func (gl *GL) TexCoord4f(s, t, r, q float32) {
+ C.gl3_3compat_glTexCoord4f(gl.funcs, C.GLfloat(s), C.GLfloat(t), C.GLfloat(r), C.GLfloat(q))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord4dv.xml
+func (gl *GL) TexCoord4dv(v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glTexCoord4dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord4d.xml
+func (gl *GL) TexCoord4d(s, t, r, q float64) {
+ C.gl3_3compat_glTexCoord4d(gl.funcs, C.GLdouble(s), C.GLdouble(t), C.GLdouble(r), C.GLdouble(q))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord3sv.xml
+func (gl *GL) TexCoord3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glTexCoord3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord3s.xml
+func (gl *GL) TexCoord3s(s, t, r int16) {
+ C.gl3_3compat_glTexCoord3s(gl.funcs, C.GLshort(s), C.GLshort(t), C.GLshort(r))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord3iv.xml
+func (gl *GL) TexCoord3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glTexCoord3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord3i.xml
+func (gl *GL) TexCoord3i(s, t, r int32) {
+ C.gl3_3compat_glTexCoord3i(gl.funcs, C.GLint(s), C.GLint(t), C.GLint(r))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord3fv.xml
+func (gl *GL) TexCoord3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glTexCoord3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord3f.xml
+func (gl *GL) TexCoord3f(s, t, r float32) {
+ C.gl3_3compat_glTexCoord3f(gl.funcs, C.GLfloat(s), C.GLfloat(t), C.GLfloat(r))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord3dv.xml
+func (gl *GL) TexCoord3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glTexCoord3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord3d.xml
+func (gl *GL) TexCoord3d(s, t, r float64) {
+ C.gl3_3compat_glTexCoord3d(gl.funcs, C.GLdouble(s), C.GLdouble(t), C.GLdouble(r))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord2sv.xml
+func (gl *GL) TexCoord2sv(v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glTexCoord2sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord2s.xml
+func (gl *GL) TexCoord2s(s, t int16) {
+ C.gl3_3compat_glTexCoord2s(gl.funcs, C.GLshort(s), C.GLshort(t))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord2iv.xml
+func (gl *GL) TexCoord2iv(v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glTexCoord2iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord2i.xml
+func (gl *GL) TexCoord2i(s, t int32) {
+ C.gl3_3compat_glTexCoord2i(gl.funcs, C.GLint(s), C.GLint(t))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord2fv.xml
+func (gl *GL) TexCoord2fv(v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glTexCoord2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord2f.xml
+func (gl *GL) TexCoord2f(s, t float32) {
+ C.gl3_3compat_glTexCoord2f(gl.funcs, C.GLfloat(s), C.GLfloat(t))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord2dv.xml
+func (gl *GL) TexCoord2dv(v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glTexCoord2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord2d.xml
+func (gl *GL) TexCoord2d(s, t float64) {
+ C.gl3_3compat_glTexCoord2d(gl.funcs, C.GLdouble(s), C.GLdouble(t))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord1sv.xml
+func (gl *GL) TexCoord1sv(v []int16) {
+ C.gl3_3compat_glTexCoord1sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord1s.xml
+func (gl *GL) TexCoord1s(s int16) {
+ C.gl3_3compat_glTexCoord1s(gl.funcs, C.GLshort(s))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord1iv.xml
+func (gl *GL) TexCoord1iv(v []int32) {
+ C.gl3_3compat_glTexCoord1iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord1i.xml
+func (gl *GL) TexCoord1i(s int32) {
+ C.gl3_3compat_glTexCoord1i(gl.funcs, C.GLint(s))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord1fv.xml
+func (gl *GL) TexCoord1fv(v []float32) {
+ C.gl3_3compat_glTexCoord1fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord1f.xml
+func (gl *GL) TexCoord1f(s float32) {
+ C.gl3_3compat_glTexCoord1f(gl.funcs, C.GLfloat(s))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord1dv.xml
+func (gl *GL) TexCoord1dv(v []float64) {
+ C.gl3_3compat_glTexCoord1dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoord1d.xml
+func (gl *GL) TexCoord1d(s float64) {
+ C.gl3_3compat_glTexCoord1d(gl.funcs, C.GLdouble(s))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRectsv.xml
+func (gl *GL) Rectsv(v1, v2 []int16) {
+ C.gl3_3compat_glRectsv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v1[0])), (*C.GLshort)(unsafe.Pointer(&v2[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRects.xml
+func (gl *GL) Rects(x1, y1, x2, y2 int16) {
+ C.gl3_3compat_glRects(gl.funcs, C.GLshort(x1), C.GLshort(y1), C.GLshort(x2), C.GLshort(y2))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRectiv.xml
+func (gl *GL) Rectiv(v1, v2 []int32) {
+ C.gl3_3compat_glRectiv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v1[0])), (*C.GLint)(unsafe.Pointer(&v2[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRecti.xml
+func (gl *GL) Recti(x1, y1, x2, y2 int32) {
+ C.gl3_3compat_glRecti(gl.funcs, C.GLint(x1), C.GLint(y1), C.GLint(x2), C.GLint(y2))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRectfv.xml
+func (gl *GL) Rectfv(v1, v2 []float32) {
+ C.gl3_3compat_glRectfv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v1[0])), (*C.GLfloat)(unsafe.Pointer(&v2[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRectf.xml
+func (gl *GL) Rectf(x1, y1, x2, y2 float32) {
+ C.gl3_3compat_glRectf(gl.funcs, C.GLfloat(x1), C.GLfloat(y1), C.GLfloat(x2), C.GLfloat(y2))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRectdv.xml
+func (gl *GL) Rectdv(v1, v2 []float64) {
+ C.gl3_3compat_glRectdv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v1[0])), (*C.GLdouble)(unsafe.Pointer(&v2[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRectd.xml
+func (gl *GL) Rectd(x1, y1, x2, y2 float64) {
+ C.gl3_3compat_glRectd(gl.funcs, C.GLdouble(x1), C.GLdouble(y1), C.GLdouble(x2), C.GLdouble(y2))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos4sv.xml
+func (gl *GL) RasterPos4sv(v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glRasterPos4sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos4s.xml
+func (gl *GL) RasterPos4s(x, y, z, w int16) {
+ C.gl3_3compat_glRasterPos4s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z), C.GLshort(w))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos4iv.xml
+func (gl *GL) RasterPos4iv(v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glRasterPos4iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos4i.xml
+func (gl *GL) RasterPos4i(x, y, z, w int) {
+ C.gl3_3compat_glRasterPos4i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z), C.GLint(w))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos4fv.xml
+func (gl *GL) RasterPos4fv(v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glRasterPos4fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos4f.xml
+func (gl *GL) RasterPos4f(x, y, z, w float32) {
+ C.gl3_3compat_glRasterPos4f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z), C.GLfloat(w))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos4dv.xml
+func (gl *GL) RasterPos4dv(v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glRasterPos4dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos4d.xml
+func (gl *GL) RasterPos4d(x, y, z, w float64) {
+ C.gl3_3compat_glRasterPos4d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z), C.GLdouble(w))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos3sv.xml
+func (gl *GL) RasterPos3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glRasterPos3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos3s.xml
+func (gl *GL) RasterPos3s(x, y, z int16) {
+ C.gl3_3compat_glRasterPos3s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos3iv.xml
+func (gl *GL) RasterPos3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glRasterPos3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos3i.xml
+func (gl *GL) RasterPos3i(x, y, z int) {
+ C.gl3_3compat_glRasterPos3i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos3fv.xml
+func (gl *GL) RasterPos3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glRasterPos3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos3f.xml
+func (gl *GL) RasterPos3f(x, y, z float32) {
+ C.gl3_3compat_glRasterPos3f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos3dv.xml
+func (gl *GL) RasterPos3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glRasterPos3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos3d.xml
+func (gl *GL) RasterPos3d(x, y, z float64) {
+ C.gl3_3compat_glRasterPos3d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos2sv.xml
+func (gl *GL) RasterPos2sv(v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glRasterPos2sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos2s.xml
+func (gl *GL) RasterPos2s(x, y int16) {
+ C.gl3_3compat_glRasterPos2s(gl.funcs, C.GLshort(x), C.GLshort(y))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos2iv.xml
+func (gl *GL) RasterPos2iv(v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glRasterPos2iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos2i.xml
+func (gl *GL) RasterPos2i(x, y int) {
+ C.gl3_3compat_glRasterPos2i(gl.funcs, C.GLint(x), C.GLint(y))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos2fv.xml
+func (gl *GL) RasterPos2fv(v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glRasterPos2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos2f.xml
+func (gl *GL) RasterPos2f(x, y float32) {
+ C.gl3_3compat_glRasterPos2f(gl.funcs, C.GLfloat(x), C.GLfloat(y))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos2dv.xml
+func (gl *GL) RasterPos2dv(v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glRasterPos2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRasterPos2d.xml
+func (gl *GL) RasterPos2d(x, y float64) {
+ C.gl3_3compat_glRasterPos2d(gl.funcs, C.GLdouble(x), C.GLdouble(y))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glNormal3sv.xml
+func (gl *GL) Normal3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glNormal3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glNormal3s.xml
+func (gl *GL) Normal3s(nx, ny, nz int16) {
+ C.gl3_3compat_glNormal3s(gl.funcs, C.GLshort(nx), C.GLshort(ny), C.GLshort(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glNormal3iv.xml
+func (gl *GL) Normal3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glNormal3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glNormal3i.xml
+func (gl *GL) Normal3i(nx, ny, nz int32) {
+ C.gl3_3compat_glNormal3i(gl.funcs, C.GLint(nx), C.GLint(ny), C.GLint(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glNormal3fv.xml
+func (gl *GL) Normal3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glNormal3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glNormal3f.xml
+func (gl *GL) Normal3f(nx, ny, nz float32) {
+ C.gl3_3compat_glNormal3f(gl.funcs, C.GLfloat(nx), C.GLfloat(ny), C.GLfloat(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glNormal3dv.xml
+func (gl *GL) Normal3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glNormal3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glNormal3d.xml
+func (gl *GL) Normal3d(nx, ny, nz float64) {
+ C.gl3_3compat_glNormal3d(gl.funcs, C.GLdouble(nx), C.GLdouble(ny), C.GLdouble(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glNormal3bv.xml
+func (gl *GL) Normal3bv(v []byte) {
+ C.gl3_3compat_glNormal3bv(gl.funcs, (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glNormal3b.xml
+func (gl *GL) Normal3b(nx, ny, nz byte) {
+ C.gl3_3compat_glNormal3b(gl.funcs, C.GLbyte(nx), C.GLbyte(ny), C.GLbyte(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIndexsv.xml
+func (gl *GL) Indexsv(c []int16) {
+ C.gl3_3compat_glIndexsv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIndexs.xml
+func (gl *GL) Indexs(c int16) {
+ C.gl3_3compat_glIndexs(gl.funcs, C.GLshort(c))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIndexiv.xml
+func (gl *GL) Indexiv(c []int32) {
+ C.gl3_3compat_glIndexiv(gl.funcs, (*C.GLint)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIndexi.xml
+func (gl *GL) Indexi(c int32) {
+ C.gl3_3compat_glIndexi(gl.funcs, C.GLint(c))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIndexfv.xml
+func (gl *GL) Indexfv(c []float32) {
+ C.gl3_3compat_glIndexfv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIndexf.xml
+func (gl *GL) Indexf(c float32) {
+ C.gl3_3compat_glIndexf(gl.funcs, C.GLfloat(c))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIndexdv.xml
+func (gl *GL) Indexdv(c []float64) {
+ C.gl3_3compat_glIndexdv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIndexd.xml
+func (gl *GL) Indexd(c float64) {
+ C.gl3_3compat_glIndexd(gl.funcs, C.GLdouble(c))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEnd.xml
+func (gl *GL) End() {
+ C.gl3_3compat_glEnd(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEdgeFlagv.xml
+func (gl *GL) EdgeFlagv(flag []bool) {
+ C.gl3_3compat_glEdgeFlagv(gl.funcs, (*C.GLboolean)(unsafe.Pointer(&flag[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEdgeFlag.xml
+func (gl *GL) EdgeFlag(flag bool) {
+ C.gl3_3compat_glEdgeFlag(gl.funcs, *(*C.GLboolean)(unsafe.Pointer(&flag)))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor4usv.xml
+func (gl *GL) Color4usv(v []uint16) {
+ C.gl3_3compat_glColor4usv(gl.funcs, (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor4us.xml
+func (gl *GL) Color4us(red, green, blue, alpha uint16) {
+ C.gl3_3compat_glColor4us(gl.funcs, C.GLushort(red), C.GLushort(green), C.GLushort(blue), C.GLushort(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor4uiv.xml
+func (gl *GL) Color4uiv(v []uint32) {
+ C.gl3_3compat_glColor4uiv(gl.funcs, (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor4ui.xml
+func (gl *GL) Color4ui(red, green, blue, alpha uint32) {
+ C.gl3_3compat_glColor4ui(gl.funcs, C.GLuint(red), C.GLuint(green), C.GLuint(blue), C.GLuint(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor4ubv.xml
+func (gl *GL) Color4ubv(v []uint8) {
+ C.gl3_3compat_glColor4ubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor4ub.xml
+func (gl *GL) Color4ub(red, green, blue, alpha uint8) {
+ C.gl3_3compat_glColor4ub(gl.funcs, C.GLubyte(red), C.GLubyte(green), C.GLubyte(blue), C.GLubyte(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor4sv.xml
+func (gl *GL) Color4sv(v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glColor4sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor4s.xml
+func (gl *GL) Color4s(red, green, blue, alpha int16) {
+ C.gl3_3compat_glColor4s(gl.funcs, C.GLshort(red), C.GLshort(green), C.GLshort(blue), C.GLshort(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor4iv.xml
+func (gl *GL) Color4iv(v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glColor4iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor4i.xml
+func (gl *GL) Color4i(red, green, blue, alpha int32) {
+ C.gl3_3compat_glColor4i(gl.funcs, C.GLint(red), C.GLint(green), C.GLint(blue), C.GLint(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor4fv.xml
+func (gl *GL) Color4fv(v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glColor4fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor4f.xml
+func (gl *GL) Color4f(red, green, blue, alpha float32) {
+ C.gl3_3compat_glColor4f(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor4dv.xml
+func (gl *GL) Color4dv(v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glColor4dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor4d.xml
+func (gl *GL) Color4d(red, green, blue, alpha float64) {
+ C.gl3_3compat_glColor4d(gl.funcs, C.GLdouble(red), C.GLdouble(green), C.GLdouble(blue), C.GLdouble(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor4bv.xml
+func (gl *GL) Color4bv(v []byte) {
+ C.gl3_3compat_glColor4bv(gl.funcs, (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor4b.xml
+func (gl *GL) Color4b(red, green, blue, alpha byte) {
+ C.gl3_3compat_glColor4b(gl.funcs, C.GLbyte(red), C.GLbyte(green), C.GLbyte(blue), C.GLbyte(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor3usv.xml
+func (gl *GL) Color3usv(v []uint16) {
+ C.gl3_3compat_glColor3usv(gl.funcs, (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor3us.xml
+func (gl *GL) Color3us(red, green, blue uint16) {
+ C.gl3_3compat_glColor3us(gl.funcs, C.GLushort(red), C.GLushort(green), C.GLushort(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor3uiv.xml
+func (gl *GL) Color3uiv(v []uint32) {
+ C.gl3_3compat_glColor3uiv(gl.funcs, (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor3ui.xml
+func (gl *GL) Color3ui(red, green, blue uint32) {
+ C.gl3_3compat_glColor3ui(gl.funcs, C.GLuint(red), C.GLuint(green), C.GLuint(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor3ubv.xml
+func (gl *GL) Color3ubv(v []uint8) {
+ C.gl3_3compat_glColor3ubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor3ub.xml
+func (gl *GL) Color3ub(red, green, blue uint8) {
+ C.gl3_3compat_glColor3ub(gl.funcs, C.GLubyte(red), C.GLubyte(green), C.GLubyte(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor3sv.xml
+func (gl *GL) Color3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glColor3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor3s.xml
+func (gl *GL) Color3s(red, green, blue int16) {
+ C.gl3_3compat_glColor3s(gl.funcs, C.GLshort(red), C.GLshort(green), C.GLshort(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor3iv.xml
+func (gl *GL) Color3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glColor3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor3i.xml
+func (gl *GL) Color3i(red, green, blue int32) {
+ C.gl3_3compat_glColor3i(gl.funcs, C.GLint(red), C.GLint(green), C.GLint(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor3fv.xml
+func (gl *GL) Color3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glColor3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor3f.xml
+func (gl *GL) Color3f(red, green, blue float32) {
+ C.gl3_3compat_glColor3f(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor3dv.xml
+func (gl *GL) Color3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glColor3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor3d.xml
+func (gl *GL) Color3d(red, green, blue float64) {
+ C.gl3_3compat_glColor3d(gl.funcs, C.GLdouble(red), C.GLdouble(green), C.GLdouble(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor3bv.xml
+func (gl *GL) Color3bv(v []byte) {
+ C.gl3_3compat_glColor3bv(gl.funcs, (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColor3b.xml
+func (gl *GL) Color3b(red, green, blue byte) {
+ C.gl3_3compat_glColor3b(gl.funcs, C.GLbyte(red), C.GLbyte(green), C.GLbyte(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBitmap.xml
+func (gl *GL) Bitmap(width, height int, xorig, yorig, xmove, ymove float32, bitmap []uint8) {
+ C.gl3_3compat_glBitmap(gl.funcs, C.GLsizei(width), C.GLsizei(height), C.GLfloat(xorig), C.GLfloat(yorig), C.GLfloat(xmove), C.GLfloat(ymove), (*C.GLubyte)(unsafe.Pointer(&bitmap[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBegin.xml
+func (gl *GL) Begin(mode glbase.Enum) {
+ C.gl3_3compat_glBegin(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glListBase.xml
+func (gl *GL) ListBase(base uint32) {
+ C.gl3_3compat_glListBase(gl.funcs, C.GLuint(base))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGenLists.xml
+func (gl *GL) GenLists(range_ int32) uint32 {
+ glresult := C.gl3_3compat_glGenLists(gl.funcs, C.GLsizei(range_))
+ return uint32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDeleteLists.xml
+func (gl *GL) DeleteLists(list uint32, range_ int32) {
+ C.gl3_3compat_glDeleteLists(gl.funcs, C.GLuint(list), C.GLsizei(range_))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCallLists.xml
+func (gl *GL) CallLists(n int, gltype glbase.Enum, lists interface{}) {
+ var lists_ptr unsafe.Pointer
+ var lists_v = reflect.ValueOf(lists)
+ if lists != nil && lists_v.Kind() != reflect.Slice {
+ panic("parameter lists must be a slice")
+ }
+ if lists != nil {
+ lists_ptr = unsafe.Pointer(lists_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3compat_glCallLists(gl.funcs, C.GLsizei(n), C.GLenum(gltype), lists_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCallList.xml
+func (gl *GL) CallList(list uint32) {
+ C.gl3_3compat_glCallList(gl.funcs, C.GLuint(list))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEndList.xml
+func (gl *GL) EndList() {
+ C.gl3_3compat_glEndList(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glNewList.xml
+func (gl *GL) NewList(list uint32, mode glbase.Enum) {
+ C.gl3_3compat_glNewList(gl.funcs, C.GLuint(list), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPushClientAttrib.xml
+func (gl *GL) PushClientAttrib(mask glbase.Bitfield) {
+ C.gl3_3compat_glPushClientAttrib(gl.funcs, C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPopClientAttrib.xml
+func (gl *GL) PopClientAttrib() {
+ C.gl3_3compat_glPopClientAttrib(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPrioritizeTextures.xml
+func (gl *GL) PrioritizeTextures(n int, textures []glbase.Texture, priorities []float32) {
+ C.gl3_3compat_glPrioritizeTextures(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])), (*C.GLfloat)(unsafe.Pointer(&priorities[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glAreTexturesResident.xml
+func (gl *GL) AreTexturesResident(n int, textures []glbase.Texture, residences []bool) bool {
+ glresult := C.gl3_3compat_glAreTexturesResident(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])), (*C.GLboolean)(unsafe.Pointer(&residences[0])))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexPointer.xml
+func (gl *GL) VertexPointer(size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3compat_glVertexPointer(gl.funcs, C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoordPointer.xml
+func (gl *GL) TexCoordPointer(size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3compat_glTexCoordPointer(gl.funcs, C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glNormalPointer.xml
+func (gl *GL) NormalPointer(gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3compat_glNormalPointer(gl.funcs, C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glInterleavedArrays.xml
+func (gl *GL) InterleavedArrays(format glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3compat_glInterleavedArrays(gl.funcs, C.GLenum(format), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIndexPointer.xml
+func (gl *GL) IndexPointer(gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3compat_glIndexPointer(gl.funcs, C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEnableClientState.xml
+func (gl *GL) EnableClientState(array glbase.Enum) {
+ C.gl3_3compat_glEnableClientState(gl.funcs, C.GLenum(array))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEdgeFlagPointer.xml
+func (gl *GL) EdgeFlagPointer(stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3compat_glEdgeFlagPointer(gl.funcs, C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDisableClientState.xml
+func (gl *GL) DisableClientState(array glbase.Enum) {
+ C.gl3_3compat_glDisableClientState(gl.funcs, C.GLenum(array))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColorPointer.xml
+func (gl *GL) ColorPointer(size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3compat_glColorPointer(gl.funcs, C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glArrayElement.xml
+func (gl *GL) ArrayElement(i int32) {
+ C.gl3_3compat_glArrayElement(gl.funcs, C.GLint(i))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glResetMinmax.xml
+func (gl *GL) ResetMinmax(target glbase.Enum) {
+ C.gl3_3compat_glResetMinmax(gl.funcs, C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glResetHistogram.xml
+func (gl *GL) ResetHistogram(target glbase.Enum) {
+ C.gl3_3compat_glResetHistogram(gl.funcs, C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMinmax.xml
+func (gl *GL) Minmax(target, internalFormat glbase.Enum, sink bool) {
+ C.gl3_3compat_glMinmax(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), *(*C.GLboolean)(unsafe.Pointer(&sink)))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glHistogram.xml
+func (gl *GL) Histogram(target glbase.Enum, width int, internalFormat glbase.Enum, sink bool) {
+ C.gl3_3compat_glHistogram(gl.funcs, C.GLenum(target), C.GLsizei(width), C.GLenum(internalFormat), *(*C.GLboolean)(unsafe.Pointer(&sink)))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetMinmaxParameteriv.xml
+func (gl *GL) GetMinmaxParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl3_3compat_glGetMinmaxParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetMinmaxParameterfv.xml
+func (gl *GL) GetMinmaxParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl3_3compat_glGetMinmaxParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetMinmax.xml
+func (gl *GL) GetMinmax(target glbase.Enum, reset bool, format, gltype glbase.Enum, values interface{}) {
+ var values_ptr unsafe.Pointer
+ var values_v = reflect.ValueOf(values)
+ if values != nil && values_v.Kind() != reflect.Slice {
+ panic("parameter values must be a slice")
+ }
+ if values != nil {
+ values_ptr = unsafe.Pointer(values_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3compat_glGetMinmax(gl.funcs, C.GLenum(target), *(*C.GLboolean)(unsafe.Pointer(&reset)), C.GLenum(format), C.GLenum(gltype), values_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetHistogramParameteriv.xml
+func (gl *GL) GetHistogramParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl3_3compat_glGetHistogramParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetHistogramParameterfv.xml
+func (gl *GL) GetHistogramParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl3_3compat_glGetHistogramParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetHistogram.xml
+func (gl *GL) GetHistogram(target glbase.Enum, reset bool, format, gltype glbase.Enum, values interface{}) {
+ var values_ptr unsafe.Pointer
+ var values_v = reflect.ValueOf(values)
+ if values != nil && values_v.Kind() != reflect.Slice {
+ panic("parameter values must be a slice")
+ }
+ if values != nil {
+ values_ptr = unsafe.Pointer(values_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3compat_glGetHistogram(gl.funcs, C.GLenum(target), *(*C.GLboolean)(unsafe.Pointer(&reset)), C.GLenum(format), C.GLenum(gltype), values_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSeparableFilter2D.xml
+func (gl *GL) SeparableFilter2D(target, internalFormat glbase.Enum, width, height int, format, gltype glbase.Enum, row, column interface{}) {
+ var row_ptr unsafe.Pointer
+ var row_v = reflect.ValueOf(row)
+ if row != nil && row_v.Kind() != reflect.Slice {
+ panic("parameter row must be a slice")
+ }
+ if row != nil {
+ row_ptr = unsafe.Pointer(row_v.Index(0).Addr().Pointer())
+ }
+ var column_ptr unsafe.Pointer
+ var column_v = reflect.ValueOf(column)
+ if column != nil && column_v.Kind() != reflect.Slice {
+ panic("parameter column must be a slice")
+ }
+ if column != nil {
+ column_ptr = unsafe.Pointer(column_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3compat_glSeparableFilter2D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), row_ptr, column_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetSeparableFilter.xml
+func (gl *GL) GetSeparableFilter(target, format, gltype glbase.Enum, row, column, span interface{}) {
+ var row_ptr unsafe.Pointer
+ var row_v = reflect.ValueOf(row)
+ if row != nil && row_v.Kind() != reflect.Slice {
+ panic("parameter row must be a slice")
+ }
+ if row != nil {
+ row_ptr = unsafe.Pointer(row_v.Index(0).Addr().Pointer())
+ }
+ var column_ptr unsafe.Pointer
+ var column_v = reflect.ValueOf(column)
+ if column != nil && column_v.Kind() != reflect.Slice {
+ panic("parameter column must be a slice")
+ }
+ if column != nil {
+ column_ptr = unsafe.Pointer(column_v.Index(0).Addr().Pointer())
+ }
+ var span_ptr unsafe.Pointer
+ var span_v = reflect.ValueOf(span)
+ if span != nil && span_v.Kind() != reflect.Slice {
+ panic("parameter span must be a slice")
+ }
+ if span != nil {
+ span_ptr = unsafe.Pointer(span_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3compat_glGetSeparableFilter(gl.funcs, C.GLenum(target), C.GLenum(format), C.GLenum(gltype), row_ptr, column_ptr, span_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetConvolutionParameteriv.xml
+func (gl *GL) GetConvolutionParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl3_3compat_glGetConvolutionParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetConvolutionParameterfv.xml
+func (gl *GL) GetConvolutionParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl3_3compat_glGetConvolutionParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetConvolutionFilter.xml
+func (gl *GL) GetConvolutionFilter(target, format, gltype glbase.Enum, image interface{}) {
+ var image_ptr unsafe.Pointer
+ var image_v = reflect.ValueOf(image)
+ if image != nil && image_v.Kind() != reflect.Slice {
+ panic("parameter image must be a slice")
+ }
+ if image != nil {
+ image_ptr = unsafe.Pointer(image_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3compat_glGetConvolutionFilter(gl.funcs, C.GLenum(target), C.GLenum(format), C.GLenum(gltype), image_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCopyConvolutionFilter2D.xml
+func (gl *GL) CopyConvolutionFilter2D(target, internalFormat glbase.Enum, x, y, width, height int) {
+ C.gl3_3compat_glCopyConvolutionFilter2D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCopyConvolutionFilter1D.xml
+func (gl *GL) CopyConvolutionFilter1D(target, internalFormat glbase.Enum, x, y, width int) {
+ C.gl3_3compat_glCopyConvolutionFilter1D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glConvolutionParameteriv.xml
+func (gl *GL) ConvolutionParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl3_3compat_glConvolutionParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glConvolutionParameteri.xml
+func (gl *GL) ConvolutionParameteri(target, pname glbase.Enum, params int32) {
+ C.gl3_3compat_glConvolutionParameteri(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLint(params))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glConvolutionParameterfv.xml
+func (gl *GL) ConvolutionParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl3_3compat_glConvolutionParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glConvolutionParameterf.xml
+func (gl *GL) ConvolutionParameterf(target, pname glbase.Enum, params float32) {
+ C.gl3_3compat_glConvolutionParameterf(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLfloat(params))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glConvolutionFilter2D.xml
+func (gl *GL) ConvolutionFilter2D(target, internalFormat glbase.Enum, width, height int, format, gltype glbase.Enum, image interface{}) {
+ var image_ptr unsafe.Pointer
+ var image_v = reflect.ValueOf(image)
+ if image != nil && image_v.Kind() != reflect.Slice {
+ panic("parameter image must be a slice")
+ }
+ if image != nil {
+ image_ptr = unsafe.Pointer(image_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3compat_glConvolutionFilter2D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), image_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glConvolutionFilter1D.xml
+func (gl *GL) ConvolutionFilter1D(target, internalFormat glbase.Enum, width int, format, gltype glbase.Enum, image interface{}) {
+ var image_ptr unsafe.Pointer
+ var image_v = reflect.ValueOf(image)
+ if image != nil && image_v.Kind() != reflect.Slice {
+ panic("parameter image must be a slice")
+ }
+ if image != nil {
+ image_ptr = unsafe.Pointer(image_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3compat_glConvolutionFilter1D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLenum(format), C.GLenum(gltype), image_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCopyColorSubTable.xml
+func (gl *GL) CopyColorSubTable(target glbase.Enum, start int32, x, y, width int) {
+ C.gl3_3compat_glCopyColorSubTable(gl.funcs, C.GLenum(target), C.GLsizei(start), C.GLint(x), C.GLint(y), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColorSubTable.xml
+func (gl *GL) ColorSubTable(target glbase.Enum, start int32, count int, format, gltype glbase.Enum, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3compat_glColorSubTable(gl.funcs, C.GLenum(target), C.GLsizei(start), C.GLsizei(count), C.GLenum(format), C.GLenum(gltype), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetColorTableParameteriv.xml
+func (gl *GL) GetColorTableParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl3_3compat_glGetColorTableParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetColorTableParameterfv.xml
+func (gl *GL) GetColorTableParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl3_3compat_glGetColorTableParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetColorTable.xml
+func (gl *GL) GetColorTable(target, format, gltype glbase.Enum, table interface{}) {
+ var table_ptr unsafe.Pointer
+ var table_v = reflect.ValueOf(table)
+ if table != nil && table_v.Kind() != reflect.Slice {
+ panic("parameter table must be a slice")
+ }
+ if table != nil {
+ table_ptr = unsafe.Pointer(table_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3compat_glGetColorTable(gl.funcs, C.GLenum(target), C.GLenum(format), C.GLenum(gltype), table_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCopyColorTable.xml
+func (gl *GL) CopyColorTable(target, internalFormat glbase.Enum, x, y, width int) {
+ C.gl3_3compat_glCopyColorTable(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColorTableParameteriv.xml
+func (gl *GL) ColorTableParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl3_3compat_glColorTableParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColorTableParameterfv.xml
+func (gl *GL) ColorTableParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl3_3compat_glColorTableParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColorTable.xml
+func (gl *GL) ColorTable(target, internalFormat glbase.Enum, width int, format, gltype glbase.Enum, table interface{}) {
+ var table_ptr unsafe.Pointer
+ var table_v = reflect.ValueOf(table)
+ if table != nil && table_v.Kind() != reflect.Slice {
+ panic("parameter table must be a slice")
+ }
+ if table != nil {
+ table_ptr = unsafe.Pointer(table_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3compat_glColorTable(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLenum(format), C.GLenum(gltype), table_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultTransposeMatrixd.xml
+func (gl *GL) MultTransposeMatrixd(m []float64) {
+ C.gl3_3compat_glMultTransposeMatrixd(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultTransposeMatrixf.xml
+func (gl *GL) MultTransposeMatrixf(m []float32) {
+ C.gl3_3compat_glMultTransposeMatrixf(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glLoadTransposeMatrixd.xml
+func (gl *GL) LoadTransposeMatrixd(m []float64) {
+ C.gl3_3compat_glLoadTransposeMatrixd(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glLoadTransposeMatrixf.xml
+func (gl *GL) LoadTransposeMatrixf(m []float32) {
+ C.gl3_3compat_glLoadTransposeMatrixf(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord4sv.xml
+func (gl *GL) MultiTexCoord4sv(target glbase.Enum, v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glMultiTexCoord4sv(gl.funcs, C.GLenum(target), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord4s.xml
+func (gl *GL) MultiTexCoord4s(target glbase.Enum, s, t, r, q int16) {
+ C.gl3_3compat_glMultiTexCoord4s(gl.funcs, C.GLenum(target), C.GLshort(s), C.GLshort(t), C.GLshort(r), C.GLshort(q))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord4iv.xml
+func (gl *GL) MultiTexCoord4iv(target glbase.Enum, v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glMultiTexCoord4iv(gl.funcs, C.GLenum(target), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord4i.xml
+func (gl *GL) MultiTexCoord4i(target glbase.Enum, s, t, r, q int32) {
+ C.gl3_3compat_glMultiTexCoord4i(gl.funcs, C.GLenum(target), C.GLint(s), C.GLint(t), C.GLint(r), C.GLint(q))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord4fv.xml
+func (gl *GL) MultiTexCoord4fv(target glbase.Enum, v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glMultiTexCoord4fv(gl.funcs, C.GLenum(target), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord4f.xml
+func (gl *GL) MultiTexCoord4f(target glbase.Enum, s, t, r, q float32) {
+ C.gl3_3compat_glMultiTexCoord4f(gl.funcs, C.GLenum(target), C.GLfloat(s), C.GLfloat(t), C.GLfloat(r), C.GLfloat(q))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord4dv.xml
+func (gl *GL) MultiTexCoord4dv(target glbase.Enum, v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glMultiTexCoord4dv(gl.funcs, C.GLenum(target), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord4d.xml
+func (gl *GL) MultiTexCoord4d(target glbase.Enum, s, t, r, q float64) {
+ C.gl3_3compat_glMultiTexCoord4d(gl.funcs, C.GLenum(target), C.GLdouble(s), C.GLdouble(t), C.GLdouble(r), C.GLdouble(q))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord3sv.xml
+func (gl *GL) MultiTexCoord3sv(target glbase.Enum, v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glMultiTexCoord3sv(gl.funcs, C.GLenum(target), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord3s.xml
+func (gl *GL) MultiTexCoord3s(target glbase.Enum, s, t, r int16) {
+ C.gl3_3compat_glMultiTexCoord3s(gl.funcs, C.GLenum(target), C.GLshort(s), C.GLshort(t), C.GLshort(r))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord3iv.xml
+func (gl *GL) MultiTexCoord3iv(target glbase.Enum, v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glMultiTexCoord3iv(gl.funcs, C.GLenum(target), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord3i.xml
+func (gl *GL) MultiTexCoord3i(target glbase.Enum, s, t, r int32) {
+ C.gl3_3compat_glMultiTexCoord3i(gl.funcs, C.GLenum(target), C.GLint(s), C.GLint(t), C.GLint(r))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord3fv.xml
+func (gl *GL) MultiTexCoord3fv(target glbase.Enum, v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glMultiTexCoord3fv(gl.funcs, C.GLenum(target), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord3f.xml
+func (gl *GL) MultiTexCoord3f(target glbase.Enum, s, t, r float32) {
+ C.gl3_3compat_glMultiTexCoord3f(gl.funcs, C.GLenum(target), C.GLfloat(s), C.GLfloat(t), C.GLfloat(r))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord3dv.xml
+func (gl *GL) MultiTexCoord3dv(target glbase.Enum, v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glMultiTexCoord3dv(gl.funcs, C.GLenum(target), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord3d.xml
+func (gl *GL) MultiTexCoord3d(target glbase.Enum, s, t, r float64) {
+ C.gl3_3compat_glMultiTexCoord3d(gl.funcs, C.GLenum(target), C.GLdouble(s), C.GLdouble(t), C.GLdouble(r))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord2sv.xml
+func (gl *GL) MultiTexCoord2sv(target glbase.Enum, v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glMultiTexCoord2sv(gl.funcs, C.GLenum(target), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord2s.xml
+func (gl *GL) MultiTexCoord2s(target glbase.Enum, s, t int16) {
+ C.gl3_3compat_glMultiTexCoord2s(gl.funcs, C.GLenum(target), C.GLshort(s), C.GLshort(t))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord2iv.xml
+func (gl *GL) MultiTexCoord2iv(target glbase.Enum, v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glMultiTexCoord2iv(gl.funcs, C.GLenum(target), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord2i.xml
+func (gl *GL) MultiTexCoord2i(target glbase.Enum, s, t int32) {
+ C.gl3_3compat_glMultiTexCoord2i(gl.funcs, C.GLenum(target), C.GLint(s), C.GLint(t))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord2fv.xml
+func (gl *GL) MultiTexCoord2fv(target glbase.Enum, v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glMultiTexCoord2fv(gl.funcs, C.GLenum(target), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord2f.xml
+func (gl *GL) MultiTexCoord2f(target glbase.Enum, s, t float32) {
+ C.gl3_3compat_glMultiTexCoord2f(gl.funcs, C.GLenum(target), C.GLfloat(s), C.GLfloat(t))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord2dv.xml
+func (gl *GL) MultiTexCoord2dv(target glbase.Enum, v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glMultiTexCoord2dv(gl.funcs, C.GLenum(target), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord2d.xml
+func (gl *GL) MultiTexCoord2d(target glbase.Enum, s, t float64) {
+ C.gl3_3compat_glMultiTexCoord2d(gl.funcs, C.GLenum(target), C.GLdouble(s), C.GLdouble(t))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord1sv.xml
+func (gl *GL) MultiTexCoord1sv(target glbase.Enum, v []int16) {
+ C.gl3_3compat_glMultiTexCoord1sv(gl.funcs, C.GLenum(target), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord1s.xml
+func (gl *GL) MultiTexCoord1s(target glbase.Enum, s int16) {
+ C.gl3_3compat_glMultiTexCoord1s(gl.funcs, C.GLenum(target), C.GLshort(s))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord1iv.xml
+func (gl *GL) MultiTexCoord1iv(target glbase.Enum, v []int32) {
+ C.gl3_3compat_glMultiTexCoord1iv(gl.funcs, C.GLenum(target), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord1i.xml
+func (gl *GL) MultiTexCoord1i(target glbase.Enum, s int32) {
+ C.gl3_3compat_glMultiTexCoord1i(gl.funcs, C.GLenum(target), C.GLint(s))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord1fv.xml
+func (gl *GL) MultiTexCoord1fv(target glbase.Enum, v []float32) {
+ C.gl3_3compat_glMultiTexCoord1fv(gl.funcs, C.GLenum(target), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord1f.xml
+func (gl *GL) MultiTexCoord1f(target glbase.Enum, s float32) {
+ C.gl3_3compat_glMultiTexCoord1f(gl.funcs, C.GLenum(target), C.GLfloat(s))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord1dv.xml
+func (gl *GL) MultiTexCoord1dv(target glbase.Enum, v []float64) {
+ C.gl3_3compat_glMultiTexCoord1dv(gl.funcs, C.GLenum(target), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoord1d.xml
+func (gl *GL) MultiTexCoord1d(target glbase.Enum, s float64) {
+ C.gl3_3compat_glMultiTexCoord1d(gl.funcs, C.GLenum(target), C.GLdouble(s))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClientActiveTexture.xml
+func (gl *GL) ClientActiveTexture(texture glbase.Enum) {
+ C.gl3_3compat_glClientActiveTexture(gl.funcs, C.GLenum(texture))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glWindowPos3sv.xml
+func (gl *GL) WindowPos3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glWindowPos3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glWindowPos3s.xml
+func (gl *GL) WindowPos3s(x, y, z int16) {
+ C.gl3_3compat_glWindowPos3s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glWindowPos3iv.xml
+func (gl *GL) WindowPos3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glWindowPos3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glWindowPos3i.xml
+func (gl *GL) WindowPos3i(x, y, z int) {
+ C.gl3_3compat_glWindowPos3i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glWindowPos3fv.xml
+func (gl *GL) WindowPos3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glWindowPos3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glWindowPos3f.xml
+func (gl *GL) WindowPos3f(x, y, z float32) {
+ C.gl3_3compat_glWindowPos3f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glWindowPos3dv.xml
+func (gl *GL) WindowPos3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glWindowPos3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glWindowPos3d.xml
+func (gl *GL) WindowPos3d(x, y, z float64) {
+ C.gl3_3compat_glWindowPos3d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glWindowPos2sv.xml
+func (gl *GL) WindowPos2sv(v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glWindowPos2sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glWindowPos2s.xml
+func (gl *GL) WindowPos2s(x, y int16) {
+ C.gl3_3compat_glWindowPos2s(gl.funcs, C.GLshort(x), C.GLshort(y))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glWindowPos2iv.xml
+func (gl *GL) WindowPos2iv(v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glWindowPos2iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glWindowPos2i.xml
+func (gl *GL) WindowPos2i(x, y int) {
+ C.gl3_3compat_glWindowPos2i(gl.funcs, C.GLint(x), C.GLint(y))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glWindowPos2fv.xml
+func (gl *GL) WindowPos2fv(v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glWindowPos2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glWindowPos2f.xml
+func (gl *GL) WindowPos2f(x, y float32) {
+ C.gl3_3compat_glWindowPos2f(gl.funcs, C.GLfloat(x), C.GLfloat(y))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glWindowPos2dv.xml
+func (gl *GL) WindowPos2dv(v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glWindowPos2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glWindowPos2d.xml
+func (gl *GL) WindowPos2d(x, y float64) {
+ C.gl3_3compat_glWindowPos2d(gl.funcs, C.GLdouble(x), C.GLdouble(y))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSecondaryColorPointer.xml
+func (gl *GL) SecondaryColorPointer(size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3compat_glSecondaryColorPointer(gl.funcs, C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSecondaryColor3usv.xml
+func (gl *GL) SecondaryColor3usv(v []uint16) {
+ C.gl3_3compat_glSecondaryColor3usv(gl.funcs, (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSecondaryColor3us.xml
+func (gl *GL) SecondaryColor3us(red, green, blue uint16) {
+ C.gl3_3compat_glSecondaryColor3us(gl.funcs, C.GLushort(red), C.GLushort(green), C.GLushort(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSecondaryColor3uiv.xml
+func (gl *GL) SecondaryColor3uiv(v []uint32) {
+ C.gl3_3compat_glSecondaryColor3uiv(gl.funcs, (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSecondaryColor3ui.xml
+func (gl *GL) SecondaryColor3ui(red, green, blue uint32) {
+ C.gl3_3compat_glSecondaryColor3ui(gl.funcs, C.GLuint(red), C.GLuint(green), C.GLuint(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSecondaryColor3ubv.xml
+func (gl *GL) SecondaryColor3ubv(v []uint8) {
+ C.gl3_3compat_glSecondaryColor3ubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSecondaryColor3ub.xml
+func (gl *GL) SecondaryColor3ub(red, green, blue uint8) {
+ C.gl3_3compat_glSecondaryColor3ub(gl.funcs, C.GLubyte(red), C.GLubyte(green), C.GLubyte(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSecondaryColor3sv.xml
+func (gl *GL) SecondaryColor3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glSecondaryColor3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSecondaryColor3s.xml
+func (gl *GL) SecondaryColor3s(red, green, blue int16) {
+ C.gl3_3compat_glSecondaryColor3s(gl.funcs, C.GLshort(red), C.GLshort(green), C.GLshort(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSecondaryColor3iv.xml
+func (gl *GL) SecondaryColor3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glSecondaryColor3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSecondaryColor3i.xml
+func (gl *GL) SecondaryColor3i(red, green, blue int32) {
+ C.gl3_3compat_glSecondaryColor3i(gl.funcs, C.GLint(red), C.GLint(green), C.GLint(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSecondaryColor3fv.xml
+func (gl *GL) SecondaryColor3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glSecondaryColor3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSecondaryColor3f.xml
+func (gl *GL) SecondaryColor3f(red, green, blue float32) {
+ C.gl3_3compat_glSecondaryColor3f(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSecondaryColor3dv.xml
+func (gl *GL) SecondaryColor3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glSecondaryColor3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSecondaryColor3d.xml
+func (gl *GL) SecondaryColor3d(red, green, blue float64) {
+ C.gl3_3compat_glSecondaryColor3d(gl.funcs, C.GLdouble(red), C.GLdouble(green), C.GLdouble(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSecondaryColor3bv.xml
+func (gl *GL) SecondaryColor3bv(v []byte) {
+ C.gl3_3compat_glSecondaryColor3bv(gl.funcs, (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSecondaryColor3b.xml
+func (gl *GL) SecondaryColor3b(red, green, blue byte) {
+ C.gl3_3compat_glSecondaryColor3b(gl.funcs, C.GLbyte(red), C.GLbyte(green), C.GLbyte(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFogCoordPointer.xml
+func (gl *GL) FogCoordPointer(gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3compat_glFogCoordPointer(gl.funcs, C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFogCoorddv.xml
+func (gl *GL) FogCoorddv(coord []float64) {
+ C.gl3_3compat_glFogCoorddv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&coord[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFogCoordd.xml
+func (gl *GL) FogCoordd(coord float64) {
+ C.gl3_3compat_glFogCoordd(gl.funcs, C.GLdouble(coord))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFogCoordfv.xml
+func (gl *GL) FogCoordfv(coord []float32) {
+ C.gl3_3compat_glFogCoordfv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&coord[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFogCoordf.xml
+func (gl *GL) FogCoordf(coord float32) {
+ C.gl3_3compat_glFogCoordf(gl.funcs, C.GLfloat(coord))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib4usv.xml
+func (gl *GL) VertexAttrib4usv(index glbase.Attrib, v []uint16) {
+ C.gl3_3compat_glVertexAttrib4usv(gl.funcs, C.GLuint(index), (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib4uiv.xml
+func (gl *GL) VertexAttrib4uiv(index glbase.Attrib, v []uint32) {
+ C.gl3_3compat_glVertexAttrib4uiv(gl.funcs, C.GLuint(index), (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib4ubv.xml
+func (gl *GL) VertexAttrib4ubv(index glbase.Attrib, v []uint8) {
+ C.gl3_3compat_glVertexAttrib4ubv(gl.funcs, C.GLuint(index), (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib4sv.xml
+func (gl *GL) VertexAttrib4sv(index glbase.Attrib, v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glVertexAttrib4sv(gl.funcs, C.GLuint(index), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib4s.xml
+func (gl *GL) VertexAttrib4s(index glbase.Attrib, x, y, z, w int16) {
+ C.gl3_3compat_glVertexAttrib4s(gl.funcs, C.GLuint(index), C.GLshort(x), C.GLshort(y), C.GLshort(z), C.GLshort(w))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib4iv.xml
+func (gl *GL) VertexAttrib4iv(index glbase.Attrib, v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glVertexAttrib4iv(gl.funcs, C.GLuint(index), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib4fv.xml
+func (gl *GL) VertexAttrib4fv(index glbase.Attrib, v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glVertexAttrib4fv(gl.funcs, C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib4f.xml
+func (gl *GL) VertexAttrib4f(index glbase.Attrib, x, y, z, w float32) {
+ C.gl3_3compat_glVertexAttrib4f(gl.funcs, C.GLuint(index), C.GLfloat(x), C.GLfloat(y), C.GLfloat(z), C.GLfloat(w))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib4dv.xml
+func (gl *GL) VertexAttrib4dv(index glbase.Attrib, v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glVertexAttrib4dv(gl.funcs, C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib4d.xml
+func (gl *GL) VertexAttrib4d(index glbase.Attrib, x, y, z, w float64) {
+ C.gl3_3compat_glVertexAttrib4d(gl.funcs, C.GLuint(index), C.GLdouble(x), C.GLdouble(y), C.GLdouble(z), C.GLdouble(w))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib4bv.xml
+func (gl *GL) VertexAttrib4bv(index glbase.Attrib, v []byte) {
+ C.gl3_3compat_glVertexAttrib4bv(gl.funcs, C.GLuint(index), (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib4Nusv.xml
+func (gl *GL) VertexAttrib4Nusv(index glbase.Attrib, v []uint16) {
+ C.gl3_3compat_glVertexAttrib4Nusv(gl.funcs, C.GLuint(index), (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib4Nuiv.xml
+func (gl *GL) VertexAttrib4Nuiv(index glbase.Attrib, v []uint32) {
+ C.gl3_3compat_glVertexAttrib4Nuiv(gl.funcs, C.GLuint(index), (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib4Nubv.xml
+func (gl *GL) VertexAttrib4Nubv(index glbase.Attrib, v []uint8) {
+ C.gl3_3compat_glVertexAttrib4Nubv(gl.funcs, C.GLuint(index), (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib4Nub.xml
+func (gl *GL) VertexAttrib4Nub(index glbase.Attrib, x, y, z, w uint8) {
+ C.gl3_3compat_glVertexAttrib4Nub(gl.funcs, C.GLuint(index), C.GLubyte(x), C.GLubyte(y), C.GLubyte(z), C.GLubyte(w))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib4Nsv.xml
+func (gl *GL) VertexAttrib4Nsv(index glbase.Attrib, v []int16) {
+ C.gl3_3compat_glVertexAttrib4Nsv(gl.funcs, C.GLuint(index), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib4Niv.xml
+func (gl *GL) VertexAttrib4Niv(index glbase.Attrib, v []int32) {
+ C.gl3_3compat_glVertexAttrib4Niv(gl.funcs, C.GLuint(index), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib4Nbv.xml
+func (gl *GL) VertexAttrib4Nbv(index glbase.Attrib, v []byte) {
+ C.gl3_3compat_glVertexAttrib4Nbv(gl.funcs, C.GLuint(index), (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib3sv.xml
+func (gl *GL) VertexAttrib3sv(index glbase.Attrib, v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glVertexAttrib3sv(gl.funcs, C.GLuint(index), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib3s.xml
+func (gl *GL) VertexAttrib3s(index glbase.Attrib, x, y, z int16) {
+ C.gl3_3compat_glVertexAttrib3s(gl.funcs, C.GLuint(index), C.GLshort(x), C.GLshort(y), C.GLshort(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib3fv.xml
+func (gl *GL) VertexAttrib3fv(index glbase.Attrib, v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glVertexAttrib3fv(gl.funcs, C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib3f.xml
+func (gl *GL) VertexAttrib3f(index glbase.Attrib, x, y, z float32) {
+ C.gl3_3compat_glVertexAttrib3f(gl.funcs, C.GLuint(index), C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib3dv.xml
+func (gl *GL) VertexAttrib3dv(index glbase.Attrib, v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glVertexAttrib3dv(gl.funcs, C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib3d.xml
+func (gl *GL) VertexAttrib3d(index glbase.Attrib, x, y, z float64) {
+ C.gl3_3compat_glVertexAttrib3d(gl.funcs, C.GLuint(index), C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib2sv.xml
+func (gl *GL) VertexAttrib2sv(index glbase.Attrib, v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glVertexAttrib2sv(gl.funcs, C.GLuint(index), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib2s.xml
+func (gl *GL) VertexAttrib2s(index glbase.Attrib, x, y int16) {
+ C.gl3_3compat_glVertexAttrib2s(gl.funcs, C.GLuint(index), C.GLshort(x), C.GLshort(y))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib2fv.xml
+func (gl *GL) VertexAttrib2fv(index glbase.Attrib, v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glVertexAttrib2fv(gl.funcs, C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib2f.xml
+func (gl *GL) VertexAttrib2f(index glbase.Attrib, x, y float32) {
+ C.gl3_3compat_glVertexAttrib2f(gl.funcs, C.GLuint(index), C.GLfloat(x), C.GLfloat(y))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib2dv.xml
+func (gl *GL) VertexAttrib2dv(index glbase.Attrib, v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glVertexAttrib2dv(gl.funcs, C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib2d.xml
+func (gl *GL) VertexAttrib2d(index glbase.Attrib, x, y float64) {
+ C.gl3_3compat_glVertexAttrib2d(gl.funcs, C.GLuint(index), C.GLdouble(x), C.GLdouble(y))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib1sv.xml
+func (gl *GL) VertexAttrib1sv(index glbase.Attrib, v []int16) {
+ C.gl3_3compat_glVertexAttrib1sv(gl.funcs, C.GLuint(index), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib1s.xml
+func (gl *GL) VertexAttrib1s(index glbase.Attrib, x int16) {
+ C.gl3_3compat_glVertexAttrib1s(gl.funcs, C.GLuint(index), C.GLshort(x))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib1fv.xml
+func (gl *GL) VertexAttrib1fv(index glbase.Attrib, v []float32) {
+ C.gl3_3compat_glVertexAttrib1fv(gl.funcs, C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib1f.xml
+func (gl *GL) VertexAttrib1f(index glbase.Attrib, x float32) {
+ C.gl3_3compat_glVertexAttrib1f(gl.funcs, C.GLuint(index), C.GLfloat(x))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib1dv.xml
+func (gl *GL) VertexAttrib1dv(index glbase.Attrib, v []float64) {
+ C.gl3_3compat_glVertexAttrib1dv(gl.funcs, C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttrib1d.xml
+func (gl *GL) VertexAttrib1d(index glbase.Attrib, x float64) {
+ C.gl3_3compat_glVertexAttrib1d(gl.funcs, C.GLuint(index), C.GLdouble(x))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribI4usv.xml
+func (gl *GL) VertexAttribI4usv(index glbase.Attrib, v []uint16) {
+ C.gl3_3compat_glVertexAttribI4usv(gl.funcs, C.GLuint(index), (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribI4ubv.xml
+func (gl *GL) VertexAttribI4ubv(index glbase.Attrib, v []uint8) {
+ C.gl3_3compat_glVertexAttribI4ubv(gl.funcs, C.GLuint(index), (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribI4sv.xml
+func (gl *GL) VertexAttribI4sv(index glbase.Attrib, v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glVertexAttribI4sv(gl.funcs, C.GLuint(index), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribI4bv.xml
+func (gl *GL) VertexAttribI4bv(index glbase.Attrib, v []byte) {
+ C.gl3_3compat_glVertexAttribI4bv(gl.funcs, C.GLuint(index), (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribI4uiv.xml
+func (gl *GL) VertexAttribI4uiv(index glbase.Attrib, v []uint32) {
+ C.gl3_3compat_glVertexAttribI4uiv(gl.funcs, C.GLuint(index), (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribI3uiv.xml
+func (gl *GL) VertexAttribI3uiv(index glbase.Attrib, v []uint32) {
+ C.gl3_3compat_glVertexAttribI3uiv(gl.funcs, C.GLuint(index), (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribI2uiv.xml
+func (gl *GL) VertexAttribI2uiv(index glbase.Attrib, v []uint32) {
+ C.gl3_3compat_glVertexAttribI2uiv(gl.funcs, C.GLuint(index), (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribI1uiv.xml
+func (gl *GL) VertexAttribI1uiv(index glbase.Attrib, v []uint32) {
+ C.gl3_3compat_glVertexAttribI1uiv(gl.funcs, C.GLuint(index), (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribI4iv.xml
+func (gl *GL) VertexAttribI4iv(index glbase.Attrib, v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glVertexAttribI4iv(gl.funcs, C.GLuint(index), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribI3iv.xml
+func (gl *GL) VertexAttribI3iv(index glbase.Attrib, v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glVertexAttribI3iv(gl.funcs, C.GLuint(index), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribI2iv.xml
+func (gl *GL) VertexAttribI2iv(index glbase.Attrib, v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl3_3compat_glVertexAttribI2iv(gl.funcs, C.GLuint(index), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribI1iv.xml
+func (gl *GL) VertexAttribI1iv(index glbase.Attrib, v []int32) {
+ C.gl3_3compat_glVertexAttribI1iv(gl.funcs, C.GLuint(index), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribI4ui.xml
+func (gl *GL) VertexAttribI4ui(index glbase.Attrib, x, y, z, w uint32) {
+ C.gl3_3compat_glVertexAttribI4ui(gl.funcs, C.GLuint(index), C.GLuint(x), C.GLuint(y), C.GLuint(z), C.GLuint(w))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribI3ui.xml
+func (gl *GL) VertexAttribI3ui(index glbase.Attrib, x, y, z uint32) {
+ C.gl3_3compat_glVertexAttribI3ui(gl.funcs, C.GLuint(index), C.GLuint(x), C.GLuint(y), C.GLuint(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribI2ui.xml
+func (gl *GL) VertexAttribI2ui(index glbase.Attrib, x, y uint32) {
+ C.gl3_3compat_glVertexAttribI2ui(gl.funcs, C.GLuint(index), C.GLuint(x), C.GLuint(y))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribI1ui.xml
+func (gl *GL) VertexAttribI1ui(index glbase.Attrib, x uint32) {
+ C.gl3_3compat_glVertexAttribI1ui(gl.funcs, C.GLuint(index), C.GLuint(x))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribI4i.xml
+func (gl *GL) VertexAttribI4i(index glbase.Attrib, x, y, z, w int) {
+ C.gl3_3compat_glVertexAttribI4i(gl.funcs, C.GLuint(index), C.GLint(x), C.GLint(y), C.GLint(z), C.GLint(w))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribI3i.xml
+func (gl *GL) VertexAttribI3i(index glbase.Attrib, x, y, z int) {
+ C.gl3_3compat_glVertexAttribI3i(gl.funcs, C.GLuint(index), C.GLint(x), C.GLint(y), C.GLint(z))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribI2i.xml
+func (gl *GL) VertexAttribI2i(index glbase.Attrib, x, y int) {
+ C.gl3_3compat_glVertexAttribI2i(gl.funcs, C.GLuint(index), C.GLint(x), C.GLint(y))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribI1i.xml
+func (gl *GL) VertexAttribI1i(index glbase.Attrib, x int) {
+ C.gl3_3compat_glVertexAttribI1i(gl.funcs, C.GLuint(index), C.GLint(x))
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/3.3core/funcs.cpp b/Godeps/_workspace/src/github.com/obscuren/qml/gl/3.3core/funcs.cpp
new file mode 100644
index 000000000..b03b94ac9
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/3.3core/funcs.cpp
@@ -0,0 +1,1878 @@
+
+// ** file automatically generated by glgen -- do not edit manually **
+
+#include <QOpenGLContext>
+#include <QtGui/qopenglfunctions_3_3_core.h>
+
+#include "funcs.h"
+
+void *gl3_3core_funcs() {
+ QOpenGLFunctions_3_3_Core* funcs = QOpenGLContext::currentContext()->versionFunctions<QOpenGLFunctions_3_3_Core>();
+ if (!funcs) {
+ return 0;
+ }
+ funcs->initializeOpenGLFunctions();
+ return funcs;
+}
+
+
+void gl3_3core_glViewport(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glViewport(x, y, width, height);
+}
+
+void gl3_3core_glDepthRange(void *_glfuncs, GLdouble nearVal, GLdouble farVal)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glDepthRange(nearVal, farVal);
+}
+
+GLboolean gl3_3core_glIsEnabled(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ return _qglfuncs->glIsEnabled(cap);
+}
+
+void gl3_3core_glGetTexLevelParameteriv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glGetTexLevelParameteriv(target, level, pname, params);
+}
+
+void gl3_3core_glGetTexLevelParameterfv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glGetTexLevelParameterfv(target, level, pname, params);
+}
+
+void gl3_3core_glGetTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glGetTexParameteriv(target, pname, params);
+}
+
+void gl3_3core_glGetTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glGetTexParameterfv(target, pname, params);
+}
+
+void gl3_3core_glGetTexImage(void *_glfuncs, GLenum target, GLint level, GLenum format, GLenum gltype, GLvoid* pixels)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glGetTexImage(target, level, format, gltype, pixels);
+}
+
+void gl3_3core_glGetIntegerv(void *_glfuncs, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glGetIntegerv(pname, params);
+}
+
+void gl3_3core_glGetFloatv(void *_glfuncs, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glGetFloatv(pname, params);
+}
+
+GLenum gl3_3core_glGetError(void *_glfuncs)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ return _qglfuncs->glGetError();
+}
+
+void gl3_3core_glGetDoublev(void *_glfuncs, GLenum pname, GLdouble* params)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glGetDoublev(pname, params);
+}
+
+void gl3_3core_glGetBooleanv(void *_glfuncs, GLenum pname, GLboolean* params)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glGetBooleanv(pname, params);
+}
+
+void gl3_3core_glReadPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum gltype, GLvoid* pixels)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glReadPixels(x, y, width, height, format, gltype, pixels);
+}
+
+void gl3_3core_glReadBuffer(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glReadBuffer(mode);
+}
+
+void gl3_3core_glPixelStorei(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glPixelStorei(pname, param);
+}
+
+void gl3_3core_glPixelStoref(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glPixelStoref(pname, param);
+}
+
+void gl3_3core_glDepthFunc(void *_glfuncs, GLenum glfunc)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glDepthFunc(glfunc);
+}
+
+void gl3_3core_glStencilOp(void *_glfuncs, GLenum fail, GLenum zfail, GLenum zpass)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glStencilOp(fail, zfail, zpass);
+}
+
+void gl3_3core_glStencilFunc(void *_glfuncs, GLenum glfunc, GLint ref, GLuint mask)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glStencilFunc(glfunc, ref, mask);
+}
+
+void gl3_3core_glLogicOp(void *_glfuncs, GLenum opcode)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glLogicOp(opcode);
+}
+
+void gl3_3core_glBlendFunc(void *_glfuncs, GLenum sfactor, GLenum dfactor)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glBlendFunc(sfactor, dfactor);
+}
+
+void gl3_3core_glFlush(void *_glfuncs)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glFlush();
+}
+
+void gl3_3core_glFinish(void *_glfuncs)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glFinish();
+}
+
+void gl3_3core_glEnable(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glEnable(cap);
+}
+
+void gl3_3core_glDisable(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glDisable(cap);
+}
+
+void gl3_3core_glDepthMask(void *_glfuncs, GLboolean flag)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glDepthMask(flag);
+}
+
+void gl3_3core_glColorMask(void *_glfuncs, GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glColorMask(red, green, blue, alpha);
+}
+
+void gl3_3core_glStencilMask(void *_glfuncs, GLuint mask)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glStencilMask(mask);
+}
+
+void gl3_3core_glClearDepth(void *_glfuncs, GLdouble depth)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glClearDepth(depth);
+}
+
+void gl3_3core_glClearStencil(void *_glfuncs, GLint s)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glClearStencil(s);
+}
+
+void gl3_3core_glClearColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glClearColor(red, green, blue, alpha);
+}
+
+void gl3_3core_glClear(void *_glfuncs, GLbitfield mask)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glClear(mask);
+}
+
+void gl3_3core_glDrawBuffer(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glDrawBuffer(mode);
+}
+
+void gl3_3core_glTexImage2D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glTexImage2D(target, level, internalFormat, width, height, border, format, gltype, pixels);
+}
+
+void gl3_3core_glTexImage1D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glTexImage1D(target, level, internalFormat, width, border, format, gltype, pixels);
+}
+
+void gl3_3core_glTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glTexParameteriv(target, pname, params);
+}
+
+void gl3_3core_glTexParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glTexParameteri(target, pname, param);
+}
+
+void gl3_3core_glTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glTexParameterfv(target, pname, params);
+}
+
+void gl3_3core_glTexParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glTexParameterf(target, pname, param);
+}
+
+void gl3_3core_glScissor(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glScissor(x, y, width, height);
+}
+
+void gl3_3core_glPolygonMode(void *_glfuncs, GLenum face, GLenum mode)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glPolygonMode(face, mode);
+}
+
+void gl3_3core_glPointSize(void *_glfuncs, GLfloat size)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glPointSize(size);
+}
+
+void gl3_3core_glLineWidth(void *_glfuncs, GLfloat width)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glLineWidth(width);
+}
+
+void gl3_3core_glHint(void *_glfuncs, GLenum target, GLenum mode)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glHint(target, mode);
+}
+
+void gl3_3core_glFrontFace(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glFrontFace(mode);
+}
+
+void gl3_3core_glCullFace(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glCullFace(mode);
+}
+
+void gl3_3core_glIndexubv(void *_glfuncs, const GLubyte* c)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glIndexubv(c);
+}
+
+void gl3_3core_glIndexub(void *_glfuncs, GLubyte c)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glIndexub(c);
+}
+
+GLboolean gl3_3core_glIsTexture(void *_glfuncs, GLuint texture)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ return _qglfuncs->glIsTexture(texture);
+}
+
+void gl3_3core_glGenTextures(void *_glfuncs, GLsizei n, GLuint* textures)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glGenTextures(n, textures);
+}
+
+void gl3_3core_glDeleteTextures(void *_glfuncs, GLsizei n, const GLuint* textures)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glDeleteTextures(n, textures);
+}
+
+void gl3_3core_glBindTexture(void *_glfuncs, GLenum target, GLuint texture)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glBindTexture(target, texture);
+}
+
+void gl3_3core_glTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glTexSubImage2D(target, level, xoffset, yoffset, width, height, format, gltype, pixels);
+}
+
+void gl3_3core_glTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glTexSubImage1D(target, level, xoffset, width, format, gltype, pixels);
+}
+
+void gl3_3core_glCopyTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage2D(target, level, xoffset, yoffset, x, y, width, height);
+}
+
+void gl3_3core_glCopyTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage1D(target, level, xoffset, x, y, width);
+}
+
+void gl3_3core_glCopyTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glCopyTexImage2D(target, level, internalFormat, x, y, width, height, border);
+}
+
+void gl3_3core_glCopyTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLint border)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glCopyTexImage1D(target, level, internalFormat, x, y, width, border);
+}
+
+void gl3_3core_glPolygonOffset(void *_glfuncs, GLfloat factor, GLfloat units)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glPolygonOffset(factor, units);
+}
+
+void gl3_3core_glDrawElements(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glDrawElements(mode, count, gltype, indices);
+}
+
+void gl3_3core_glDrawArrays(void *_glfuncs, GLenum mode, GLint first, GLsizei count)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glDrawArrays(mode, first, count);
+}
+
+void gl3_3core_glCopyTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage3D(target, level, xoffset, yoffset, zoffset, x, y, width, height);
+}
+
+void gl3_3core_glTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glTexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, gltype, pixels);
+}
+
+void gl3_3core_glTexImage3D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glTexImage3D(target, level, internalFormat, width, height, depth, border, format, gltype, pixels);
+}
+
+void gl3_3core_glDrawRangeElements(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glDrawRangeElements(mode, start, end, count, gltype, indices);
+}
+
+void gl3_3core_glBlendEquation(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glBlendEquation(mode);
+}
+
+void gl3_3core_glBlendColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glBlendColor(red, green, blue, alpha);
+}
+
+void gl3_3core_glGetCompressedTexImage(void *_glfuncs, GLenum target, GLint level, GLvoid* img)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glGetCompressedTexImage(target, level, img);
+}
+
+void gl3_3core_glCompressedTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glCompressedTexSubImage1D(target, level, xoffset, width, format, imageSize, data);
+}
+
+void gl3_3core_glCompressedTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glCompressedTexSubImage2D(target, level, xoffset, yoffset, width, height, format, imageSize, data);
+}
+
+void gl3_3core_glCompressedTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glCompressedTexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, imageSize, data);
+}
+
+void gl3_3core_glCompressedTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glCompressedTexImage1D(target, level, internalFormat, width, border, imageSize, data);
+}
+
+void gl3_3core_glCompressedTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glCompressedTexImage2D(target, level, internalFormat, width, height, border, imageSize, data);
+}
+
+void gl3_3core_glCompressedTexImage3D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glCompressedTexImage3D(target, level, internalFormat, width, height, depth, border, imageSize, data);
+}
+
+void gl3_3core_glSampleCoverage(void *_glfuncs, GLfloat value, GLboolean invert)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glSampleCoverage(value, invert);
+}
+
+void gl3_3core_glActiveTexture(void *_glfuncs, GLenum texture)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glActiveTexture(texture);
+}
+
+void gl3_3core_glPointParameteriv(void *_glfuncs, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glPointParameteriv(pname, params);
+}
+
+void gl3_3core_glPointParameteri(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glPointParameteri(pname, param);
+}
+
+void gl3_3core_glPointParameterfv(void *_glfuncs, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glPointParameterfv(pname, params);
+}
+
+void gl3_3core_glPointParameterf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glPointParameterf(pname, param);
+}
+
+void gl3_3core_glMultiDrawArrays(void *_glfuncs, GLenum mode, const GLint* first, const GLsizei* count, GLsizei drawcount)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glMultiDrawArrays(mode, first, count, drawcount);
+}
+
+void gl3_3core_glBlendFuncSeparate(void *_glfuncs, GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glBlendFuncSeparate(sfactorRGB, dfactorRGB, sfactorAlpha, dfactorAlpha);
+}
+
+void gl3_3core_glGetBufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glGetBufferParameteriv(target, pname, params);
+}
+
+GLboolean gl3_3core_glUnmapBuffer(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ return _qglfuncs->glUnmapBuffer(target);
+}
+
+void gl3_3core_glGetBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, GLvoid* data)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glGetBufferSubData(target, offset, size, data);
+}
+
+void gl3_3core_glBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid* data)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glBufferSubData(target, offset, size, data);
+}
+
+void gl3_3core_glBufferData(void *_glfuncs, GLenum target, GLsizeiptr size, const GLvoid* data, GLenum usage)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glBufferData(target, size, data, usage);
+}
+
+GLboolean gl3_3core_glIsBuffer(void *_glfuncs, GLuint buffer)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ return _qglfuncs->glIsBuffer(buffer);
+}
+
+void gl3_3core_glGenBuffers(void *_glfuncs, GLsizei n, GLuint* buffers)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glGenBuffers(n, buffers);
+}
+
+void gl3_3core_glDeleteBuffers(void *_glfuncs, GLsizei n, const GLuint* buffers)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glDeleteBuffers(n, buffers);
+}
+
+void gl3_3core_glBindBuffer(void *_glfuncs, GLenum target, GLuint buffer)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glBindBuffer(target, buffer);
+}
+
+void gl3_3core_glGetQueryObjectuiv(void *_glfuncs, GLuint id, GLenum pname, GLuint* params)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glGetQueryObjectuiv(id, pname, params);
+}
+
+void gl3_3core_glGetQueryObjectiv(void *_glfuncs, GLuint id, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glGetQueryObjectiv(id, pname, params);
+}
+
+void gl3_3core_glGetQueryiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glGetQueryiv(target, pname, params);
+}
+
+void gl3_3core_glEndQuery(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glEndQuery(target);
+}
+
+void gl3_3core_glBeginQuery(void *_glfuncs, GLenum target, GLuint id)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glBeginQuery(target, id);
+}
+
+GLboolean gl3_3core_glIsQuery(void *_glfuncs, GLuint id)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ return _qglfuncs->glIsQuery(id);
+}
+
+void gl3_3core_glDeleteQueries(void *_glfuncs, GLsizei n, const GLuint* ids)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glDeleteQueries(n, ids);
+}
+
+void gl3_3core_glGenQueries(void *_glfuncs, GLsizei n, GLuint* ids)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glGenQueries(n, ids);
+}
+
+void gl3_3core_glVertexAttribPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLboolean normalized, GLsizei stride, const GLvoid* offset)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribPointer(index, size, gltype, normalized, stride, offset);
+}
+
+void gl3_3core_glValidateProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glValidateProgram(program);
+}
+
+void gl3_3core_glUniformMatrix4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4fv(location, count, transpose, value);
+}
+
+void gl3_3core_glUniformMatrix3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3fv(location, count, transpose, value);
+}
+
+void gl3_3core_glUniformMatrix2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2fv(location, count, transpose, value);
+}
+
+void gl3_3core_glUniform4iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glUniform4iv(location, count, value);
+}
+
+void gl3_3core_glUniform3iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glUniform3iv(location, count, value);
+}
+
+void gl3_3core_glUniform2iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glUniform2iv(location, count, value);
+}
+
+void gl3_3core_glUniform1iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glUniform1iv(location, count, value);
+}
+
+void gl3_3core_glUniform4fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glUniform4fv(location, count, value);
+}
+
+void gl3_3core_glUniform3fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glUniform3fv(location, count, value);
+}
+
+void gl3_3core_glUniform2fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glUniform2fv(location, count, value);
+}
+
+void gl3_3core_glUniform1fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glUniform1fv(location, count, value);
+}
+
+void gl3_3core_glUniform4i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2, GLint v3)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glUniform4i(location, v0, v1, v2, v3);
+}
+
+void gl3_3core_glUniform3i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glUniform3i(location, v0, v1, v2);
+}
+
+void gl3_3core_glUniform2i(void *_glfuncs, GLint location, GLint v0, GLint v1)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glUniform2i(location, v0, v1);
+}
+
+void gl3_3core_glUniform1i(void *_glfuncs, GLint location, GLint v0)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glUniform1i(location, v0);
+}
+
+void gl3_3core_glUniform4f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glUniform4f(location, v0, v1, v2, v3);
+}
+
+void gl3_3core_glUniform3f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glUniform3f(location, v0, v1, v2);
+}
+
+void gl3_3core_glUniform2f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glUniform2f(location, v0, v1);
+}
+
+void gl3_3core_glUniform1f(void *_glfuncs, GLint location, GLfloat v0)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glUniform1f(location, v0);
+}
+
+void gl3_3core_glUseProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glUseProgram(program);
+}
+
+void gl3_3core_glShaderSource(void *_glfuncs, GLuint shader, GLsizei count, const GLchar** source, const GLint* length)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glShaderSource(shader, count, source, length);
+}
+
+void gl3_3core_glLinkProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glLinkProgram(program);
+}
+
+GLboolean gl3_3core_glIsShader(void *_glfuncs, GLuint shader)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ return _qglfuncs->glIsShader(shader);
+}
+
+GLboolean gl3_3core_glIsProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ return _qglfuncs->glIsProgram(program);
+}
+
+void gl3_3core_glGetVertexAttribiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribiv(index, pname, params);
+}
+
+void gl3_3core_glGetVertexAttribfv(void *_glfuncs, GLuint index, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribfv(index, pname, params);
+}
+
+void gl3_3core_glGetVertexAttribdv(void *_glfuncs, GLuint index, GLenum pname, GLdouble* params)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribdv(index, pname, params);
+}
+
+void gl3_3core_glGetUniformiv(void *_glfuncs, GLuint program, GLint location, GLint* params)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glGetUniformiv(program, location, params);
+}
+
+void gl3_3core_glGetUniformfv(void *_glfuncs, GLuint program, GLint location, GLfloat* params)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glGetUniformfv(program, location, params);
+}
+
+GLint gl3_3core_glGetUniformLocation(void *_glfuncs, GLuint program, const GLchar* name)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ return _qglfuncs->glGetUniformLocation(program, name);
+}
+
+void gl3_3core_glGetShaderSource(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* source)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glGetShaderSource(shader, bufSize, length, source);
+}
+
+void gl3_3core_glGetShaderInfoLog(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* infoLog)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glGetShaderInfoLog(shader, bufSize, length, infoLog);
+}
+
+void gl3_3core_glGetShaderiv(void *_glfuncs, GLuint shader, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glGetShaderiv(shader, pname, params);
+}
+
+void gl3_3core_glGetProgramInfoLog(void *_glfuncs, GLuint program, GLsizei bufSize, GLsizei* length, GLchar* infoLog)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glGetProgramInfoLog(program, bufSize, length, infoLog);
+}
+
+void gl3_3core_glGetProgramiv(void *_glfuncs, GLuint program, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glGetProgramiv(program, pname, params);
+}
+
+GLint gl3_3core_glGetAttribLocation(void *_glfuncs, GLuint program, const GLchar* name)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ return _qglfuncs->glGetAttribLocation(program, name);
+}
+
+void gl3_3core_glGetAttachedShaders(void *_glfuncs, GLuint program, GLsizei maxCount, GLsizei* count, GLuint* obj)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glGetAttachedShaders(program, maxCount, count, obj);
+}
+
+void gl3_3core_glGetActiveUniform(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glGetActiveUniform(program, index, bufSize, length, size, gltype, name);
+}
+
+void gl3_3core_glGetActiveAttrib(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glGetActiveAttrib(program, index, bufSize, length, size, gltype, name);
+}
+
+void gl3_3core_glEnableVertexAttribArray(void *_glfuncs, GLuint index)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glEnableVertexAttribArray(index);
+}
+
+void gl3_3core_glDisableVertexAttribArray(void *_glfuncs, GLuint index)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glDisableVertexAttribArray(index);
+}
+
+void gl3_3core_glDetachShader(void *_glfuncs, GLuint program, GLuint shader)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glDetachShader(program, shader);
+}
+
+void gl3_3core_glDeleteShader(void *_glfuncs, GLuint shader)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glDeleteShader(shader);
+}
+
+void gl3_3core_glDeleteProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glDeleteProgram(program);
+}
+
+GLuint gl3_3core_glCreateShader(void *_glfuncs, GLenum gltype)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ return _qglfuncs->glCreateShader(gltype);
+}
+
+GLuint gl3_3core_glCreateProgram(void *_glfuncs)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ return _qglfuncs->glCreateProgram();
+}
+
+void gl3_3core_glCompileShader(void *_glfuncs, GLuint shader)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glCompileShader(shader);
+}
+
+void gl3_3core_glBindAttribLocation(void *_glfuncs, GLuint program, GLuint index, const GLchar* name)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glBindAttribLocation(program, index, name);
+}
+
+void gl3_3core_glAttachShader(void *_glfuncs, GLuint program, GLuint shader)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glAttachShader(program, shader);
+}
+
+void gl3_3core_glStencilMaskSeparate(void *_glfuncs, GLenum face, GLuint mask)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glStencilMaskSeparate(face, mask);
+}
+
+void gl3_3core_glStencilFuncSeparate(void *_glfuncs, GLenum face, GLenum glfunc, GLint ref, GLuint mask)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glStencilFuncSeparate(face, glfunc, ref, mask);
+}
+
+void gl3_3core_glStencilOpSeparate(void *_glfuncs, GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glStencilOpSeparate(face, sfail, dpfail, dppass);
+}
+
+void gl3_3core_glDrawBuffers(void *_glfuncs, GLsizei n, const GLenum* bufs)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glDrawBuffers(n, bufs);
+}
+
+void gl3_3core_glBlendEquationSeparate(void *_glfuncs, GLenum modeRGB, GLenum modeAlpha)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glBlendEquationSeparate(modeRGB, modeAlpha);
+}
+
+void gl3_3core_glUniformMatrix4x3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4x3fv(location, count, transpose, value);
+}
+
+void gl3_3core_glUniformMatrix3x4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3x4fv(location, count, transpose, value);
+}
+
+void gl3_3core_glUniformMatrix4x2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4x2fv(location, count, transpose, value);
+}
+
+void gl3_3core_glUniformMatrix2x4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2x4fv(location, count, transpose, value);
+}
+
+void gl3_3core_glUniformMatrix3x2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3x2fv(location, count, transpose, value);
+}
+
+void gl3_3core_glUniformMatrix2x3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2x3fv(location, count, transpose, value);
+}
+
+GLboolean gl3_3core_glIsVertexArray(void *_glfuncs, GLuint array)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ return _qglfuncs->glIsVertexArray(array);
+}
+
+void gl3_3core_glGenVertexArrays(void *_glfuncs, GLsizei n, GLuint* arrays)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glGenVertexArrays(n, arrays);
+}
+
+void gl3_3core_glDeleteVertexArrays(void *_glfuncs, GLsizei n, const GLuint* arrays)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glDeleteVertexArrays(n, arrays);
+}
+
+void gl3_3core_glBindVertexArray(void *_glfuncs, GLuint array)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glBindVertexArray(array);
+}
+
+void gl3_3core_glFlushMappedBufferRange(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr length)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glFlushMappedBufferRange(target, offset, length);
+}
+
+void gl3_3core_glFramebufferTextureLayer(void *_glfuncs, GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glFramebufferTextureLayer(target, attachment, texture, level, layer);
+}
+
+void gl3_3core_glRenderbufferStorageMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLenum internalFormat, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glRenderbufferStorageMultisample(target, samples, internalFormat, width, height);
+}
+
+void gl3_3core_glBlitFramebuffer(void *_glfuncs, GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glBlitFramebuffer(srcX0, srcY0, srcX1, srcY1, dstX0, dstY0, dstX1, dstY1, mask, filter);
+}
+
+void gl3_3core_glGenerateMipmap(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glGenerateMipmap(target);
+}
+
+void gl3_3core_glGetFramebufferAttachmentParameteriv(void *_glfuncs, GLenum target, GLenum attachment, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glGetFramebufferAttachmentParameteriv(target, attachment, pname, params);
+}
+
+void gl3_3core_glFramebufferRenderbuffer(void *_glfuncs, GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glFramebufferRenderbuffer(target, attachment, renderbuffertarget, renderbuffer);
+}
+
+void gl3_3core_glFramebufferTexture3D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glFramebufferTexture3D(target, attachment, textarget, texture, level, zoffset);
+}
+
+void gl3_3core_glFramebufferTexture2D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glFramebufferTexture2D(target, attachment, textarget, texture, level);
+}
+
+void gl3_3core_glFramebufferTexture1D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glFramebufferTexture1D(target, attachment, textarget, texture, level);
+}
+
+GLenum gl3_3core_glCheckFramebufferStatus(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ return _qglfuncs->glCheckFramebufferStatus(target);
+}
+
+void gl3_3core_glGenFramebuffers(void *_glfuncs, GLsizei n, GLuint* framebuffers)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glGenFramebuffers(n, framebuffers);
+}
+
+void gl3_3core_glDeleteFramebuffers(void *_glfuncs, GLsizei n, const GLuint* framebuffers)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glDeleteFramebuffers(n, framebuffers);
+}
+
+void gl3_3core_glBindFramebuffer(void *_glfuncs, GLenum target, GLuint framebuffer)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glBindFramebuffer(target, framebuffer);
+}
+
+GLboolean gl3_3core_glIsFramebuffer(void *_glfuncs, GLuint framebuffer)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ return _qglfuncs->glIsFramebuffer(framebuffer);
+}
+
+void gl3_3core_glGetRenderbufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glGetRenderbufferParameteriv(target, pname, params);
+}
+
+void gl3_3core_glRenderbufferStorage(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glRenderbufferStorage(target, internalFormat, width, height);
+}
+
+void gl3_3core_glGenRenderbuffers(void *_glfuncs, GLsizei n, GLuint* renderbuffers)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glGenRenderbuffers(n, renderbuffers);
+}
+
+void gl3_3core_glDeleteRenderbuffers(void *_glfuncs, GLsizei n, const GLuint* renderbuffers)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glDeleteRenderbuffers(n, renderbuffers);
+}
+
+void gl3_3core_glBindRenderbuffer(void *_glfuncs, GLenum target, GLuint renderbuffer)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glBindRenderbuffer(target, renderbuffer);
+}
+
+GLboolean gl3_3core_glIsRenderbuffer(void *_glfuncs, GLuint renderbuffer)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ return _qglfuncs->glIsRenderbuffer(renderbuffer);
+}
+
+void gl3_3core_glClearBufferfi(void *_glfuncs, GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glClearBufferfi(buffer, drawbuffer, depth, stencil);
+}
+
+void gl3_3core_glClearBufferfv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLfloat* value)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glClearBufferfv(buffer, drawbuffer, value);
+}
+
+void gl3_3core_glClearBufferuiv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLuint* value)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glClearBufferuiv(buffer, drawbuffer, value);
+}
+
+void gl3_3core_glClearBufferiv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLint* value)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glClearBufferiv(buffer, drawbuffer, value);
+}
+
+void gl3_3core_glGetTexParameterIuiv(void *_glfuncs, GLenum target, GLenum pname, GLuint* params)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glGetTexParameterIuiv(target, pname, params);
+}
+
+void gl3_3core_glGetTexParameterIiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glGetTexParameterIiv(target, pname, params);
+}
+
+void gl3_3core_glTexParameterIuiv(void *_glfuncs, GLenum target, GLenum pname, const GLuint* params)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glTexParameterIuiv(target, pname, params);
+}
+
+void gl3_3core_glTexParameterIiv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glTexParameterIiv(target, pname, params);
+}
+
+void gl3_3core_glUniform4uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glUniform4uiv(location, count, value);
+}
+
+void gl3_3core_glUniform3uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glUniform3uiv(location, count, value);
+}
+
+void gl3_3core_glUniform2uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glUniform2uiv(location, count, value);
+}
+
+void gl3_3core_glUniform1uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glUniform1uiv(location, count, value);
+}
+
+void gl3_3core_glUniform4ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glUniform4ui(location, v0, v1, v2, v3);
+}
+
+void gl3_3core_glUniform3ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1, GLuint v2)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glUniform3ui(location, v0, v1, v2);
+}
+
+void gl3_3core_glUniform2ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glUniform2ui(location, v0, v1);
+}
+
+void gl3_3core_glUniform1ui(void *_glfuncs, GLint location, GLuint v0)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glUniform1ui(location, v0);
+}
+
+GLint gl3_3core_glGetFragDataLocation(void *_glfuncs, GLuint program, const GLchar* name)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ return _qglfuncs->glGetFragDataLocation(program, name);
+}
+
+void gl3_3core_glBindFragDataLocation(void *_glfuncs, GLuint program, GLuint color, const GLchar* name)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glBindFragDataLocation(program, color, name);
+}
+
+void gl3_3core_glGetUniformuiv(void *_glfuncs, GLuint program, GLint location, GLuint* params)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glGetUniformuiv(program, location, params);
+}
+
+void gl3_3core_glGetVertexAttribIuiv(void *_glfuncs, GLuint index, GLenum pname, GLuint* params)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribIuiv(index, pname, params);
+}
+
+void gl3_3core_glGetVertexAttribIiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribIiv(index, pname, params);
+}
+
+void gl3_3core_glVertexAttribIPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribIPointer(index, size, gltype, stride, pointer);
+}
+
+void gl3_3core_glEndConditionalRender(void *_glfuncs)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glEndConditionalRender();
+}
+
+void gl3_3core_glBeginConditionalRender(void *_glfuncs, GLuint id, GLenum mode)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glBeginConditionalRender(id, mode);
+}
+
+void gl3_3core_glClampColor(void *_glfuncs, GLenum target, GLenum clamp)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glClampColor(target, clamp);
+}
+
+void gl3_3core_glGetTransformFeedbackVarying(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLsizei* size, GLenum* gltype, GLchar* name)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glGetTransformFeedbackVarying(program, index, bufSize, length, size, gltype, name);
+}
+
+void gl3_3core_glBindBufferBase(void *_glfuncs, GLenum target, GLuint index, GLuint buffer)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glBindBufferBase(target, index, buffer);
+}
+
+void gl3_3core_glBindBufferRange(void *_glfuncs, GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glBindBufferRange(target, index, buffer, offset, size);
+}
+
+void gl3_3core_glEndTransformFeedback(void *_glfuncs)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glEndTransformFeedback();
+}
+
+void gl3_3core_glBeginTransformFeedback(void *_glfuncs, GLenum primitiveMode)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glBeginTransformFeedback(primitiveMode);
+}
+
+GLboolean gl3_3core_glIsEnabledi(void *_glfuncs, GLenum target, GLuint index)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ return _qglfuncs->glIsEnabledi(target, index);
+}
+
+void gl3_3core_glDisablei(void *_glfuncs, GLenum target, GLuint index)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glDisablei(target, index);
+}
+
+void gl3_3core_glEnablei(void *_glfuncs, GLenum target, GLuint index)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glEnablei(target, index);
+}
+
+void gl3_3core_glGetIntegeri_v(void *_glfuncs, GLenum target, GLuint index, GLint* data)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glGetIntegeri_v(target, index, data);
+}
+
+void gl3_3core_glGetBooleani_v(void *_glfuncs, GLenum target, GLuint index, GLboolean* data)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glGetBooleani_v(target, index, data);
+}
+
+void gl3_3core_glColorMaski(void *_glfuncs, GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glColorMaski(index, r, g, b, a);
+}
+
+void gl3_3core_glCopyBufferSubData(void *_glfuncs, GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glCopyBufferSubData(readTarget, writeTarget, readOffset, writeOffset, size);
+}
+
+void gl3_3core_glUniformBlockBinding(void *_glfuncs, GLuint program, GLuint v0, GLuint v1)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glUniformBlockBinding(program, v0, v1);
+}
+
+void gl3_3core_glGetActiveUniformBlockName(void *_glfuncs, GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei* length, GLchar* uniformBlockName)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glGetActiveUniformBlockName(program, uniformBlockIndex, bufSize, length, uniformBlockName);
+}
+
+void gl3_3core_glGetActiveUniformBlockiv(void *_glfuncs, GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glGetActiveUniformBlockiv(program, uniformBlockIndex, pname, params);
+}
+
+GLuint gl3_3core_glGetUniformBlockIndex(void *_glfuncs, GLuint program, const GLchar* uniformBlockName)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ return _qglfuncs->glGetUniformBlockIndex(program, uniformBlockName);
+}
+
+void gl3_3core_glGetActiveUniformName(void *_glfuncs, GLuint program, GLuint uniformIndex, GLsizei bufSize, GLsizei* length, GLchar* uniformName)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glGetActiveUniformName(program, uniformIndex, bufSize, length, uniformName);
+}
+
+void gl3_3core_glGetActiveUniformsiv(void *_glfuncs, GLuint program, GLsizei uniformCount, const GLuint* uniformIndices, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glGetActiveUniformsiv(program, uniformCount, uniformIndices, pname, params);
+}
+
+void gl3_3core_glPrimitiveRestartIndex(void *_glfuncs, GLuint index)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glPrimitiveRestartIndex(index);
+}
+
+void gl3_3core_glTexBuffer(void *_glfuncs, GLenum target, GLenum internalFormat, GLuint buffer)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glTexBuffer(target, internalFormat, buffer);
+}
+
+void gl3_3core_glDrawElementsInstanced(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glDrawElementsInstanced(mode, count, gltype, indices, instancecount);
+}
+
+void gl3_3core_glDrawArraysInstanced(void *_glfuncs, GLenum mode, GLint first, GLsizei count, GLsizei instancecount)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glDrawArraysInstanced(mode, first, count, instancecount);
+}
+
+void gl3_3core_glSampleMaski(void *_glfuncs, GLuint index, GLbitfield mask)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glSampleMaski(index, mask);
+}
+
+void gl3_3core_glGetMultisamplefv(void *_glfuncs, GLenum pname, GLuint index, GLfloat* val)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glGetMultisamplefv(pname, index, val);
+}
+
+void gl3_3core_glTexImage3DMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glTexImage3DMultisample(target, samples, internalFormat, width, height, depth, fixedsamplelocations);
+}
+
+void gl3_3core_glTexImage2DMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLint internalFormat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glTexImage2DMultisample(target, samples, internalFormat, width, height, fixedsamplelocations);
+}
+
+void gl3_3core_glGetSynciv(void *_glfuncs, GLsync sync, GLenum pname, GLsizei bufSize, GLsizei* length, GLint* values)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glGetSynciv(sync, pname, bufSize, length, values);
+}
+
+void gl3_3core_glGetInteger64v(void *_glfuncs, GLenum pname, GLint64* params)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glGetInteger64v(pname, params);
+}
+
+void gl3_3core_glWaitSync(void *_glfuncs, GLsync sync, GLbitfield flags, GLuint64 timeout)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glWaitSync(sync, flags, timeout);
+}
+
+GLenum gl3_3core_glClientWaitSync(void *_glfuncs, GLsync sync, GLbitfield flags, GLuint64 timeout)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ return _qglfuncs->glClientWaitSync(sync, flags, timeout);
+}
+
+void gl3_3core_glDeleteSync(void *_glfuncs, GLsync sync)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glDeleteSync(sync);
+}
+
+GLboolean gl3_3core_glIsSync(void *_glfuncs, GLsync sync)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ return _qglfuncs->glIsSync(sync);
+}
+
+GLsync gl3_3core_glFenceSync(void *_glfuncs, GLenum condition, GLbitfield flags)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ return _qglfuncs->glFenceSync(condition, flags);
+}
+
+void gl3_3core_glProvokingVertex(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glProvokingVertex(mode);
+}
+
+void gl3_3core_glDrawElementsInstancedBaseVertex(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount, GLint basevertex)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glDrawElementsInstancedBaseVertex(mode, count, gltype, indices, instancecount, basevertex);
+}
+
+void gl3_3core_glDrawRangeElementsBaseVertex(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices, GLint basevertex)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glDrawRangeElementsBaseVertex(mode, start, end, count, gltype, indices, basevertex);
+}
+
+void gl3_3core_glDrawElementsBaseVertex(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLint basevertex)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glDrawElementsBaseVertex(mode, count, gltype, indices, basevertex);
+}
+
+void gl3_3core_glFramebufferTexture(void *_glfuncs, GLenum target, GLenum attachment, GLuint texture, GLint level)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glFramebufferTexture(target, attachment, texture, level);
+}
+
+void gl3_3core_glGetBufferParameteri64v(void *_glfuncs, GLenum target, GLenum pname, GLint64* params)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glGetBufferParameteri64v(target, pname, params);
+}
+
+void gl3_3core_glGetInteger64i_v(void *_glfuncs, GLenum target, GLuint index, GLint64* data)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glGetInteger64i_v(target, index, data);
+}
+
+void gl3_3core_glVertexAttribP4uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribP4uiv(index, gltype, normalized, value);
+}
+
+void gl3_3core_glVertexAttribP4ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribP4ui(index, gltype, normalized, value);
+}
+
+void gl3_3core_glVertexAttribP3uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribP3uiv(index, gltype, normalized, value);
+}
+
+void gl3_3core_glVertexAttribP3ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribP3ui(index, gltype, normalized, value);
+}
+
+void gl3_3core_glVertexAttribP2uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribP2uiv(index, gltype, normalized, value);
+}
+
+void gl3_3core_glVertexAttribP2ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribP2ui(index, gltype, normalized, value);
+}
+
+void gl3_3core_glVertexAttribP1uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribP1uiv(index, gltype, normalized, value);
+}
+
+void gl3_3core_glVertexAttribP1ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribP1ui(index, gltype, normalized, value);
+}
+
+void gl3_3core_glSecondaryColorP3uiv(void *_glfuncs, GLenum gltype, const GLuint* color)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glSecondaryColorP3uiv(gltype, color);
+}
+
+void gl3_3core_glSecondaryColorP3ui(void *_glfuncs, GLenum gltype, GLuint color)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glSecondaryColorP3ui(gltype, color);
+}
+
+void gl3_3core_glColorP4uiv(void *_glfuncs, GLenum gltype, const GLuint* color)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glColorP4uiv(gltype, color);
+}
+
+void gl3_3core_glColorP4ui(void *_glfuncs, GLenum gltype, GLuint color)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glColorP4ui(gltype, color);
+}
+
+void gl3_3core_glColorP3uiv(void *_glfuncs, GLenum gltype, const GLuint* color)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glColorP3uiv(gltype, color);
+}
+
+void gl3_3core_glColorP3ui(void *_glfuncs, GLenum gltype, GLuint color)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glColorP3ui(gltype, color);
+}
+
+void gl3_3core_glNormalP3uiv(void *_glfuncs, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glNormalP3uiv(gltype, coords);
+}
+
+void gl3_3core_glNormalP3ui(void *_glfuncs, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glNormalP3ui(gltype, coords);
+}
+
+void gl3_3core_glMultiTexCoordP4uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP4uiv(texture, gltype, coords);
+}
+
+void gl3_3core_glMultiTexCoordP4ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP4ui(texture, gltype, coords);
+}
+
+void gl3_3core_glMultiTexCoordP3uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP3uiv(texture, gltype, coords);
+}
+
+void gl3_3core_glMultiTexCoordP3ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP3ui(texture, gltype, coords);
+}
+
+void gl3_3core_glMultiTexCoordP2uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP2uiv(texture, gltype, coords);
+}
+
+void gl3_3core_glMultiTexCoordP2ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP2ui(texture, gltype, coords);
+}
+
+void gl3_3core_glMultiTexCoordP1uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP1uiv(texture, gltype, coords);
+}
+
+void gl3_3core_glMultiTexCoordP1ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP1ui(texture, gltype, coords);
+}
+
+void gl3_3core_glTexCoordP4uiv(void *_glfuncs, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glTexCoordP4uiv(gltype, coords);
+}
+
+void gl3_3core_glTexCoordP4ui(void *_glfuncs, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glTexCoordP4ui(gltype, coords);
+}
+
+void gl3_3core_glTexCoordP3uiv(void *_glfuncs, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glTexCoordP3uiv(gltype, coords);
+}
+
+void gl3_3core_glTexCoordP3ui(void *_glfuncs, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glTexCoordP3ui(gltype, coords);
+}
+
+void gl3_3core_glTexCoordP2uiv(void *_glfuncs, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glTexCoordP2uiv(gltype, coords);
+}
+
+void gl3_3core_glTexCoordP2ui(void *_glfuncs, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glTexCoordP2ui(gltype, coords);
+}
+
+void gl3_3core_glTexCoordP1uiv(void *_glfuncs, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glTexCoordP1uiv(gltype, coords);
+}
+
+void gl3_3core_glTexCoordP1ui(void *_glfuncs, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glTexCoordP1ui(gltype, coords);
+}
+
+void gl3_3core_glVertexP4uiv(void *_glfuncs, GLenum gltype, const GLuint* value)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glVertexP4uiv(gltype, value);
+}
+
+void gl3_3core_glVertexP4ui(void *_glfuncs, GLenum gltype, GLuint value)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glVertexP4ui(gltype, value);
+}
+
+void gl3_3core_glVertexP3uiv(void *_glfuncs, GLenum gltype, const GLuint* value)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glVertexP3uiv(gltype, value);
+}
+
+void gl3_3core_glVertexP3ui(void *_glfuncs, GLenum gltype, GLuint value)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glVertexP3ui(gltype, value);
+}
+
+void gl3_3core_glVertexP2uiv(void *_glfuncs, GLenum gltype, const GLuint* value)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glVertexP2uiv(gltype, value);
+}
+
+void gl3_3core_glVertexP2ui(void *_glfuncs, GLenum gltype, GLuint value)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glVertexP2ui(gltype, value);
+}
+
+void gl3_3core_glGetQueryObjectui64v(void *_glfuncs, GLuint id, GLenum pname, GLuint64* params)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glGetQueryObjectui64v(id, pname, params);
+}
+
+void gl3_3core_glGetQueryObjecti64v(void *_glfuncs, GLuint id, GLenum pname, GLint64* params)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glGetQueryObjecti64v(id, pname, params);
+}
+
+void gl3_3core_glQueryCounter(void *_glfuncs, GLuint id, GLenum target)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glQueryCounter(id, target);
+}
+
+void gl3_3core_glGetSamplerParameterIuiv(void *_glfuncs, GLuint sampler, GLenum pname, GLuint* params)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glGetSamplerParameterIuiv(sampler, pname, params);
+}
+
+void gl3_3core_glGetSamplerParameterfv(void *_glfuncs, GLuint sampler, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glGetSamplerParameterfv(sampler, pname, params);
+}
+
+void gl3_3core_glGetSamplerParameterIiv(void *_glfuncs, GLuint sampler, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glGetSamplerParameterIiv(sampler, pname, params);
+}
+
+void gl3_3core_glGetSamplerParameteriv(void *_glfuncs, GLuint sampler, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glGetSamplerParameteriv(sampler, pname, params);
+}
+
+void gl3_3core_glSamplerParameterIuiv(void *_glfuncs, GLuint sampler, GLenum pname, const GLuint* param)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glSamplerParameterIuiv(sampler, pname, param);
+}
+
+void gl3_3core_glSamplerParameterIiv(void *_glfuncs, GLuint sampler, GLenum pname, const GLint* param)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glSamplerParameterIiv(sampler, pname, param);
+}
+
+void gl3_3core_glSamplerParameterfv(void *_glfuncs, GLuint sampler, GLenum pname, const GLfloat* param)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glSamplerParameterfv(sampler, pname, param);
+}
+
+void gl3_3core_glSamplerParameterf(void *_glfuncs, GLuint sampler, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glSamplerParameterf(sampler, pname, param);
+}
+
+void gl3_3core_glSamplerParameteriv(void *_glfuncs, GLuint sampler, GLenum pname, const GLint* param)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glSamplerParameteriv(sampler, pname, param);
+}
+
+void gl3_3core_glSamplerParameteri(void *_glfuncs, GLuint sampler, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glSamplerParameteri(sampler, pname, param);
+}
+
+void gl3_3core_glBindSampler(void *_glfuncs, GLuint unit, GLuint sampler)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glBindSampler(unit, sampler);
+}
+
+GLboolean gl3_3core_glIsSampler(void *_glfuncs, GLuint sampler)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ return _qglfuncs->glIsSampler(sampler);
+}
+
+void gl3_3core_glDeleteSamplers(void *_glfuncs, GLsizei count, const GLuint* samplers)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glDeleteSamplers(count, samplers);
+}
+
+void gl3_3core_glGenSamplers(void *_glfuncs, GLsizei count, GLuint* samplers)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glGenSamplers(count, samplers);
+}
+
+GLint gl3_3core_glGetFragDataIndex(void *_glfuncs, GLuint program, const GLchar* name)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ return _qglfuncs->glGetFragDataIndex(program, name);
+}
+
+void gl3_3core_glBindFragDataLocationIndexed(void *_glfuncs, GLuint program, GLuint colorNumber, GLuint index, const GLchar* name)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glBindFragDataLocationIndexed(program, colorNumber, index, name);
+}
+
+void gl3_3core_glVertexAttribDivisor(void *_glfuncs, GLuint index, GLuint divisor)
+{
+ QOpenGLFunctions_3_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_3_3_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribDivisor(index, divisor);
+}
+
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/3.3core/funcs.h b/Godeps/_workspace/src/github.com/obscuren/qml/gl/3.3core/funcs.h
new file mode 100644
index 000000000..77017a8c7
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/3.3core/funcs.h
@@ -0,0 +1,352 @@
+
+// ** file automatically generated by glgen -- do not edit manually **
+
+#ifndef __cplusplus
+#include <inttypes.h>
+#include <stddef.h>
+typedef unsigned int GLenum;
+typedef unsigned char GLboolean;
+typedef unsigned int GLbitfield;
+typedef void GLvoid;
+typedef char GLchar;
+typedef signed char GLbyte; /* 1-byte signed */
+typedef short GLshort; /* 2-byte signed */
+typedef int GLint; /* 4-byte signed */
+typedef unsigned char GLubyte; /* 1-byte unsigned */
+typedef unsigned short GLushort; /* 2-byte unsigned */
+typedef unsigned int GLuint; /* 4-byte unsigned */
+typedef int GLsizei; /* 4-byte signed */
+typedef float GLfloat; /* single precision float */
+typedef float GLclampf; /* single precision float in [0,1] */
+typedef double GLdouble; /* double precision float */
+typedef double GLclampd; /* double precision float in [0,1] */
+typedef int64_t GLint64;
+typedef uint64_t GLuint64;
+typedef ptrdiff_t GLintptr;
+typedef ptrdiff_t GLsizeiptr;
+typedef ptrdiff_t GLintptrARB;
+typedef ptrdiff_t GLsizeiptrARB;
+typedef struct __GLsync *GLsync;
+#endif
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+void *gl3_3core_funcs();
+
+void gl3_3core_glViewport(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl3_3core_glDepthRange(void *_glfuncs, GLdouble nearVal, GLdouble farVal);
+GLboolean gl3_3core_glIsEnabled(void *_glfuncs, GLenum cap);
+void gl3_3core_glGetTexLevelParameteriv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLint* params);
+void gl3_3core_glGetTexLevelParameterfv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLfloat* params);
+void gl3_3core_glGetTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl3_3core_glGetTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl3_3core_glGetTexImage(void *_glfuncs, GLenum target, GLint level, GLenum format, GLenum gltype, GLvoid* pixels);
+void gl3_3core_glGetIntegerv(void *_glfuncs, GLenum pname, GLint* params);
+void gl3_3core_glGetFloatv(void *_glfuncs, GLenum pname, GLfloat* params);
+GLenum gl3_3core_glGetError(void *_glfuncs);
+void gl3_3core_glGetDoublev(void *_glfuncs, GLenum pname, GLdouble* params);
+void gl3_3core_glGetBooleanv(void *_glfuncs, GLenum pname, GLboolean* params);
+void gl3_3core_glReadPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum gltype, GLvoid* pixels);
+void gl3_3core_glReadBuffer(void *_glfuncs, GLenum mode);
+void gl3_3core_glPixelStorei(void *_glfuncs, GLenum pname, GLint param);
+void gl3_3core_glPixelStoref(void *_glfuncs, GLenum pname, GLfloat param);
+void gl3_3core_glDepthFunc(void *_glfuncs, GLenum glfunc);
+void gl3_3core_glStencilOp(void *_glfuncs, GLenum fail, GLenum zfail, GLenum zpass);
+void gl3_3core_glStencilFunc(void *_glfuncs, GLenum glfunc, GLint ref, GLuint mask);
+void gl3_3core_glLogicOp(void *_glfuncs, GLenum opcode);
+void gl3_3core_glBlendFunc(void *_glfuncs, GLenum sfactor, GLenum dfactor);
+void gl3_3core_glFlush(void *_glfuncs);
+void gl3_3core_glFinish(void *_glfuncs);
+void gl3_3core_glEnable(void *_glfuncs, GLenum cap);
+void gl3_3core_glDisable(void *_glfuncs, GLenum cap);
+void gl3_3core_glDepthMask(void *_glfuncs, GLboolean flag);
+void gl3_3core_glColorMask(void *_glfuncs, GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha);
+void gl3_3core_glStencilMask(void *_glfuncs, GLuint mask);
+void gl3_3core_glClearDepth(void *_glfuncs, GLdouble depth);
+void gl3_3core_glClearStencil(void *_glfuncs, GLint s);
+void gl3_3core_glClearColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl3_3core_glClear(void *_glfuncs, GLbitfield mask);
+void gl3_3core_glDrawBuffer(void *_glfuncs, GLenum mode);
+void gl3_3core_glTexImage2D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl3_3core_glTexImage1D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl3_3core_glTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl3_3core_glTexParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint param);
+void gl3_3core_glTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl3_3core_glTexParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param);
+void gl3_3core_glScissor(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl3_3core_glPolygonMode(void *_glfuncs, GLenum face, GLenum mode);
+void gl3_3core_glPointSize(void *_glfuncs, GLfloat size);
+void gl3_3core_glLineWidth(void *_glfuncs, GLfloat width);
+void gl3_3core_glHint(void *_glfuncs, GLenum target, GLenum mode);
+void gl3_3core_glFrontFace(void *_glfuncs, GLenum mode);
+void gl3_3core_glCullFace(void *_glfuncs, GLenum mode);
+void gl3_3core_glIndexubv(void *_glfuncs, const GLubyte* c);
+void gl3_3core_glIndexub(void *_glfuncs, GLubyte c);
+GLboolean gl3_3core_glIsTexture(void *_glfuncs, GLuint texture);
+void gl3_3core_glGenTextures(void *_glfuncs, GLsizei n, GLuint* textures);
+void gl3_3core_glDeleteTextures(void *_glfuncs, GLsizei n, const GLuint* textures);
+void gl3_3core_glBindTexture(void *_glfuncs, GLenum target, GLuint texture);
+void gl3_3core_glTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl3_3core_glTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl3_3core_glCopyTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl3_3core_glCopyTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width);
+void gl3_3core_glCopyTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border);
+void gl3_3core_glCopyTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLint border);
+void gl3_3core_glPolygonOffset(void *_glfuncs, GLfloat factor, GLfloat units);
+void gl3_3core_glDrawElements(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices);
+void gl3_3core_glDrawArrays(void *_glfuncs, GLenum mode, GLint first, GLsizei count);
+void gl3_3core_glCopyTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl3_3core_glTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl3_3core_glTexImage3D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl3_3core_glDrawRangeElements(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices);
+void gl3_3core_glBlendEquation(void *_glfuncs, GLenum mode);
+void gl3_3core_glBlendColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl3_3core_glGetCompressedTexImage(void *_glfuncs, GLenum target, GLint level, GLvoid* img);
+void gl3_3core_glCompressedTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid* data);
+void gl3_3core_glCompressedTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid* data);
+void gl3_3core_glCompressedTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid* data);
+void gl3_3core_glCompressedTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid* data);
+void gl3_3core_glCompressedTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid* data);
+void gl3_3core_glCompressedTexImage3D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid* data);
+void gl3_3core_glSampleCoverage(void *_glfuncs, GLfloat value, GLboolean invert);
+void gl3_3core_glActiveTexture(void *_glfuncs, GLenum texture);
+void gl3_3core_glPointParameteriv(void *_glfuncs, GLenum pname, const GLint* params);
+void gl3_3core_glPointParameteri(void *_glfuncs, GLenum pname, GLint param);
+void gl3_3core_glPointParameterfv(void *_glfuncs, GLenum pname, const GLfloat* params);
+void gl3_3core_glPointParameterf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl3_3core_glMultiDrawArrays(void *_glfuncs, GLenum mode, const GLint* first, const GLsizei* count, GLsizei drawcount);
+void gl3_3core_glBlendFuncSeparate(void *_glfuncs, GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha);
+void gl3_3core_glGetBufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+GLboolean gl3_3core_glUnmapBuffer(void *_glfuncs, GLenum target);
+void gl3_3core_glGetBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, GLvoid* data);
+void gl3_3core_glBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid* data);
+void gl3_3core_glBufferData(void *_glfuncs, GLenum target, GLsizeiptr size, const GLvoid* data, GLenum usage);
+GLboolean gl3_3core_glIsBuffer(void *_glfuncs, GLuint buffer);
+void gl3_3core_glGenBuffers(void *_glfuncs, GLsizei n, GLuint* buffers);
+void gl3_3core_glDeleteBuffers(void *_glfuncs, GLsizei n, const GLuint* buffers);
+void gl3_3core_glBindBuffer(void *_glfuncs, GLenum target, GLuint buffer);
+void gl3_3core_glGetQueryObjectuiv(void *_glfuncs, GLuint id, GLenum pname, GLuint* params);
+void gl3_3core_glGetQueryObjectiv(void *_glfuncs, GLuint id, GLenum pname, GLint* params);
+void gl3_3core_glGetQueryiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl3_3core_glEndQuery(void *_glfuncs, GLenum target);
+void gl3_3core_glBeginQuery(void *_glfuncs, GLenum target, GLuint id);
+GLboolean gl3_3core_glIsQuery(void *_glfuncs, GLuint id);
+void gl3_3core_glDeleteQueries(void *_glfuncs, GLsizei n, const GLuint* ids);
+void gl3_3core_glGenQueries(void *_glfuncs, GLsizei n, GLuint* ids);
+void gl3_3core_glVertexAttribPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLboolean normalized, GLsizei stride, const GLvoid* offset);
+void gl3_3core_glValidateProgram(void *_glfuncs, GLuint program);
+void gl3_3core_glUniformMatrix4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl3_3core_glUniformMatrix3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl3_3core_glUniformMatrix2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl3_3core_glUniform4iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl3_3core_glUniform3iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl3_3core_glUniform2iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl3_3core_glUniform1iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl3_3core_glUniform4fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl3_3core_glUniform3fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl3_3core_glUniform2fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl3_3core_glUniform1fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl3_3core_glUniform4i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2, GLint v3);
+void gl3_3core_glUniform3i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2);
+void gl3_3core_glUniform2i(void *_glfuncs, GLint location, GLint v0, GLint v1);
+void gl3_3core_glUniform1i(void *_glfuncs, GLint location, GLint v0);
+void gl3_3core_glUniform4f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3);
+void gl3_3core_glUniform3f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2);
+void gl3_3core_glUniform2f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1);
+void gl3_3core_glUniform1f(void *_glfuncs, GLint location, GLfloat v0);
+void gl3_3core_glUseProgram(void *_glfuncs, GLuint program);
+void gl3_3core_glShaderSource(void *_glfuncs, GLuint shader, GLsizei count, const GLchar** source, const GLint* length);
+void gl3_3core_glLinkProgram(void *_glfuncs, GLuint program);
+GLboolean gl3_3core_glIsShader(void *_glfuncs, GLuint shader);
+GLboolean gl3_3core_glIsProgram(void *_glfuncs, GLuint program);
+void gl3_3core_glGetVertexAttribiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params);
+void gl3_3core_glGetVertexAttribfv(void *_glfuncs, GLuint index, GLenum pname, GLfloat* params);
+void gl3_3core_glGetVertexAttribdv(void *_glfuncs, GLuint index, GLenum pname, GLdouble* params);
+void gl3_3core_glGetUniformiv(void *_glfuncs, GLuint program, GLint location, GLint* params);
+void gl3_3core_glGetUniformfv(void *_glfuncs, GLuint program, GLint location, GLfloat* params);
+GLint gl3_3core_glGetUniformLocation(void *_glfuncs, GLuint program, const GLchar* name);
+void gl3_3core_glGetShaderSource(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* source);
+void gl3_3core_glGetShaderInfoLog(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* infoLog);
+void gl3_3core_glGetShaderiv(void *_glfuncs, GLuint shader, GLenum pname, GLint* params);
+void gl3_3core_glGetProgramInfoLog(void *_glfuncs, GLuint program, GLsizei bufSize, GLsizei* length, GLchar* infoLog);
+void gl3_3core_glGetProgramiv(void *_glfuncs, GLuint program, GLenum pname, GLint* params);
+GLint gl3_3core_glGetAttribLocation(void *_glfuncs, GLuint program, const GLchar* name);
+void gl3_3core_glGetAttachedShaders(void *_glfuncs, GLuint program, GLsizei maxCount, GLsizei* count, GLuint* obj);
+void gl3_3core_glGetActiveUniform(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name);
+void gl3_3core_glGetActiveAttrib(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name);
+void gl3_3core_glEnableVertexAttribArray(void *_glfuncs, GLuint index);
+void gl3_3core_glDisableVertexAttribArray(void *_glfuncs, GLuint index);
+void gl3_3core_glDetachShader(void *_glfuncs, GLuint program, GLuint shader);
+void gl3_3core_glDeleteShader(void *_glfuncs, GLuint shader);
+void gl3_3core_glDeleteProgram(void *_glfuncs, GLuint program);
+GLuint gl3_3core_glCreateShader(void *_glfuncs, GLenum gltype);
+GLuint gl3_3core_glCreateProgram(void *_glfuncs);
+void gl3_3core_glCompileShader(void *_glfuncs, GLuint shader);
+void gl3_3core_glBindAttribLocation(void *_glfuncs, GLuint program, GLuint index, const GLchar* name);
+void gl3_3core_glAttachShader(void *_glfuncs, GLuint program, GLuint shader);
+void gl3_3core_glStencilMaskSeparate(void *_glfuncs, GLenum face, GLuint mask);
+void gl3_3core_glStencilFuncSeparate(void *_glfuncs, GLenum face, GLenum glfunc, GLint ref, GLuint mask);
+void gl3_3core_glStencilOpSeparate(void *_glfuncs, GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass);
+void gl3_3core_glDrawBuffers(void *_glfuncs, GLsizei n, const GLenum* bufs);
+void gl3_3core_glBlendEquationSeparate(void *_glfuncs, GLenum modeRGB, GLenum modeAlpha);
+void gl3_3core_glUniformMatrix4x3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl3_3core_glUniformMatrix3x4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl3_3core_glUniformMatrix4x2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl3_3core_glUniformMatrix2x4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl3_3core_glUniformMatrix3x2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl3_3core_glUniformMatrix2x3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+GLboolean gl3_3core_glIsVertexArray(void *_glfuncs, GLuint array);
+void gl3_3core_glGenVertexArrays(void *_glfuncs, GLsizei n, GLuint* arrays);
+void gl3_3core_glDeleteVertexArrays(void *_glfuncs, GLsizei n, const GLuint* arrays);
+void gl3_3core_glBindVertexArray(void *_glfuncs, GLuint array);
+void gl3_3core_glFlushMappedBufferRange(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr length);
+void gl3_3core_glFramebufferTextureLayer(void *_glfuncs, GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer);
+void gl3_3core_glRenderbufferStorageMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLenum internalFormat, GLsizei width, GLsizei height);
+void gl3_3core_glBlitFramebuffer(void *_glfuncs, GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter);
+void gl3_3core_glGenerateMipmap(void *_glfuncs, GLenum target);
+void gl3_3core_glGetFramebufferAttachmentParameteriv(void *_glfuncs, GLenum target, GLenum attachment, GLenum pname, GLint* params);
+void gl3_3core_glFramebufferRenderbuffer(void *_glfuncs, GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer);
+void gl3_3core_glFramebufferTexture3D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset);
+void gl3_3core_glFramebufferTexture2D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+void gl3_3core_glFramebufferTexture1D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+GLenum gl3_3core_glCheckFramebufferStatus(void *_glfuncs, GLenum target);
+void gl3_3core_glGenFramebuffers(void *_glfuncs, GLsizei n, GLuint* framebuffers);
+void gl3_3core_glDeleteFramebuffers(void *_glfuncs, GLsizei n, const GLuint* framebuffers);
+void gl3_3core_glBindFramebuffer(void *_glfuncs, GLenum target, GLuint framebuffer);
+GLboolean gl3_3core_glIsFramebuffer(void *_glfuncs, GLuint framebuffer);
+void gl3_3core_glGetRenderbufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl3_3core_glRenderbufferStorage(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height);
+void gl3_3core_glGenRenderbuffers(void *_glfuncs, GLsizei n, GLuint* renderbuffers);
+void gl3_3core_glDeleteRenderbuffers(void *_glfuncs, GLsizei n, const GLuint* renderbuffers);
+void gl3_3core_glBindRenderbuffer(void *_glfuncs, GLenum target, GLuint renderbuffer);
+GLboolean gl3_3core_glIsRenderbuffer(void *_glfuncs, GLuint renderbuffer);
+void gl3_3core_glClearBufferfi(void *_glfuncs, GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil);
+void gl3_3core_glClearBufferfv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLfloat* value);
+void gl3_3core_glClearBufferuiv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLuint* value);
+void gl3_3core_glClearBufferiv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLint* value);
+void gl3_3core_glGetTexParameterIuiv(void *_glfuncs, GLenum target, GLenum pname, GLuint* params);
+void gl3_3core_glGetTexParameterIiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl3_3core_glTexParameterIuiv(void *_glfuncs, GLenum target, GLenum pname, const GLuint* params);
+void gl3_3core_glTexParameterIiv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl3_3core_glUniform4uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value);
+void gl3_3core_glUniform3uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value);
+void gl3_3core_glUniform2uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value);
+void gl3_3core_glUniform1uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value);
+void gl3_3core_glUniform4ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3);
+void gl3_3core_glUniform3ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1, GLuint v2);
+void gl3_3core_glUniform2ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1);
+void gl3_3core_glUniform1ui(void *_glfuncs, GLint location, GLuint v0);
+GLint gl3_3core_glGetFragDataLocation(void *_glfuncs, GLuint program, const GLchar* name);
+void gl3_3core_glBindFragDataLocation(void *_glfuncs, GLuint program, GLuint color, const GLchar* name);
+void gl3_3core_glGetUniformuiv(void *_glfuncs, GLuint program, GLint location, GLuint* params);
+void gl3_3core_glGetVertexAttribIuiv(void *_glfuncs, GLuint index, GLenum pname, GLuint* params);
+void gl3_3core_glGetVertexAttribIiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params);
+void gl3_3core_glVertexAttribIPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl3_3core_glEndConditionalRender(void *_glfuncs);
+void gl3_3core_glBeginConditionalRender(void *_glfuncs, GLuint id, GLenum mode);
+void gl3_3core_glClampColor(void *_glfuncs, GLenum target, GLenum clamp);
+void gl3_3core_glGetTransformFeedbackVarying(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLsizei* size, GLenum* gltype, GLchar* name);
+void gl3_3core_glBindBufferBase(void *_glfuncs, GLenum target, GLuint index, GLuint buffer);
+void gl3_3core_glBindBufferRange(void *_glfuncs, GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size);
+void gl3_3core_glEndTransformFeedback(void *_glfuncs);
+void gl3_3core_glBeginTransformFeedback(void *_glfuncs, GLenum primitiveMode);
+GLboolean gl3_3core_glIsEnabledi(void *_glfuncs, GLenum target, GLuint index);
+void gl3_3core_glDisablei(void *_glfuncs, GLenum target, GLuint index);
+void gl3_3core_glEnablei(void *_glfuncs, GLenum target, GLuint index);
+void gl3_3core_glGetIntegeri_v(void *_glfuncs, GLenum target, GLuint index, GLint* data);
+void gl3_3core_glGetBooleani_v(void *_glfuncs, GLenum target, GLuint index, GLboolean* data);
+void gl3_3core_glColorMaski(void *_glfuncs, GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a);
+void gl3_3core_glCopyBufferSubData(void *_glfuncs, GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size);
+void gl3_3core_glUniformBlockBinding(void *_glfuncs, GLuint program, GLuint v0, GLuint v1);
+void gl3_3core_glGetActiveUniformBlockName(void *_glfuncs, GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei* length, GLchar* uniformBlockName);
+void gl3_3core_glGetActiveUniformBlockiv(void *_glfuncs, GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint* params);
+GLuint gl3_3core_glGetUniformBlockIndex(void *_glfuncs, GLuint program, const GLchar* uniformBlockName);
+void gl3_3core_glGetActiveUniformName(void *_glfuncs, GLuint program, GLuint uniformIndex, GLsizei bufSize, GLsizei* length, GLchar* uniformName);
+void gl3_3core_glGetActiveUniformsiv(void *_glfuncs, GLuint program, GLsizei uniformCount, const GLuint* uniformIndices, GLenum pname, GLint* params);
+void gl3_3core_glPrimitiveRestartIndex(void *_glfuncs, GLuint index);
+void gl3_3core_glTexBuffer(void *_glfuncs, GLenum target, GLenum internalFormat, GLuint buffer);
+void gl3_3core_glDrawElementsInstanced(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount);
+void gl3_3core_glDrawArraysInstanced(void *_glfuncs, GLenum mode, GLint first, GLsizei count, GLsizei instancecount);
+void gl3_3core_glSampleMaski(void *_glfuncs, GLuint index, GLbitfield mask);
+void gl3_3core_glGetMultisamplefv(void *_glfuncs, GLenum pname, GLuint index, GLfloat* val);
+void gl3_3core_glTexImage3DMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations);
+void gl3_3core_glTexImage2DMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLint internalFormat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations);
+void gl3_3core_glGetSynciv(void *_glfuncs, GLsync sync, GLenum pname, GLsizei bufSize, GLsizei* length, GLint* values);
+void gl3_3core_glGetInteger64v(void *_glfuncs, GLenum pname, GLint64* params);
+void gl3_3core_glWaitSync(void *_glfuncs, GLsync sync, GLbitfield flags, GLuint64 timeout);
+GLenum gl3_3core_glClientWaitSync(void *_glfuncs, GLsync sync, GLbitfield flags, GLuint64 timeout);
+void gl3_3core_glDeleteSync(void *_glfuncs, GLsync sync);
+GLboolean gl3_3core_glIsSync(void *_glfuncs, GLsync sync);
+GLsync gl3_3core_glFenceSync(void *_glfuncs, GLenum condition, GLbitfield flags);
+void gl3_3core_glProvokingVertex(void *_glfuncs, GLenum mode);
+void gl3_3core_glDrawElementsInstancedBaseVertex(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount, GLint basevertex);
+void gl3_3core_glDrawRangeElementsBaseVertex(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices, GLint basevertex);
+void gl3_3core_glDrawElementsBaseVertex(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLint basevertex);
+void gl3_3core_glFramebufferTexture(void *_glfuncs, GLenum target, GLenum attachment, GLuint texture, GLint level);
+void gl3_3core_glGetBufferParameteri64v(void *_glfuncs, GLenum target, GLenum pname, GLint64* params);
+void gl3_3core_glGetInteger64i_v(void *_glfuncs, GLenum target, GLuint index, GLint64* data);
+void gl3_3core_glVertexAttribP4uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value);
+void gl3_3core_glVertexAttribP4ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value);
+void gl3_3core_glVertexAttribP3uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value);
+void gl3_3core_glVertexAttribP3ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value);
+void gl3_3core_glVertexAttribP2uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value);
+void gl3_3core_glVertexAttribP2ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value);
+void gl3_3core_glVertexAttribP1uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value);
+void gl3_3core_glVertexAttribP1ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value);
+void gl3_3core_glSecondaryColorP3uiv(void *_glfuncs, GLenum gltype, const GLuint* color);
+void gl3_3core_glSecondaryColorP3ui(void *_glfuncs, GLenum gltype, GLuint color);
+void gl3_3core_glColorP4uiv(void *_glfuncs, GLenum gltype, const GLuint* color);
+void gl3_3core_glColorP4ui(void *_glfuncs, GLenum gltype, GLuint color);
+void gl3_3core_glColorP3uiv(void *_glfuncs, GLenum gltype, const GLuint* color);
+void gl3_3core_glColorP3ui(void *_glfuncs, GLenum gltype, GLuint color);
+void gl3_3core_glNormalP3uiv(void *_glfuncs, GLenum gltype, const GLuint* coords);
+void gl3_3core_glNormalP3ui(void *_glfuncs, GLenum gltype, GLuint coords);
+void gl3_3core_glMultiTexCoordP4uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords);
+void gl3_3core_glMultiTexCoordP4ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords);
+void gl3_3core_glMultiTexCoordP3uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords);
+void gl3_3core_glMultiTexCoordP3ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords);
+void gl3_3core_glMultiTexCoordP2uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords);
+void gl3_3core_glMultiTexCoordP2ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords);
+void gl3_3core_glMultiTexCoordP1uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords);
+void gl3_3core_glMultiTexCoordP1ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords);
+void gl3_3core_glTexCoordP4uiv(void *_glfuncs, GLenum gltype, const GLuint* coords);
+void gl3_3core_glTexCoordP4ui(void *_glfuncs, GLenum gltype, GLuint coords);
+void gl3_3core_glTexCoordP3uiv(void *_glfuncs, GLenum gltype, const GLuint* coords);
+void gl3_3core_glTexCoordP3ui(void *_glfuncs, GLenum gltype, GLuint coords);
+void gl3_3core_glTexCoordP2uiv(void *_glfuncs, GLenum gltype, const GLuint* coords);
+void gl3_3core_glTexCoordP2ui(void *_glfuncs, GLenum gltype, GLuint coords);
+void gl3_3core_glTexCoordP1uiv(void *_glfuncs, GLenum gltype, const GLuint* coords);
+void gl3_3core_glTexCoordP1ui(void *_glfuncs, GLenum gltype, GLuint coords);
+void gl3_3core_glVertexP4uiv(void *_glfuncs, GLenum gltype, const GLuint* value);
+void gl3_3core_glVertexP4ui(void *_glfuncs, GLenum gltype, GLuint value);
+void gl3_3core_glVertexP3uiv(void *_glfuncs, GLenum gltype, const GLuint* value);
+void gl3_3core_glVertexP3ui(void *_glfuncs, GLenum gltype, GLuint value);
+void gl3_3core_glVertexP2uiv(void *_glfuncs, GLenum gltype, const GLuint* value);
+void gl3_3core_glVertexP2ui(void *_glfuncs, GLenum gltype, GLuint value);
+void gl3_3core_glGetQueryObjectui64v(void *_glfuncs, GLuint id, GLenum pname, GLuint64* params);
+void gl3_3core_glGetQueryObjecti64v(void *_glfuncs, GLuint id, GLenum pname, GLint64* params);
+void gl3_3core_glQueryCounter(void *_glfuncs, GLuint id, GLenum target);
+void gl3_3core_glGetSamplerParameterIuiv(void *_glfuncs, GLuint sampler, GLenum pname, GLuint* params);
+void gl3_3core_glGetSamplerParameterfv(void *_glfuncs, GLuint sampler, GLenum pname, GLfloat* params);
+void gl3_3core_glGetSamplerParameterIiv(void *_glfuncs, GLuint sampler, GLenum pname, GLint* params);
+void gl3_3core_glGetSamplerParameteriv(void *_glfuncs, GLuint sampler, GLenum pname, GLint* params);
+void gl3_3core_glSamplerParameterIuiv(void *_glfuncs, GLuint sampler, GLenum pname, const GLuint* param);
+void gl3_3core_glSamplerParameterIiv(void *_glfuncs, GLuint sampler, GLenum pname, const GLint* param);
+void gl3_3core_glSamplerParameterfv(void *_glfuncs, GLuint sampler, GLenum pname, const GLfloat* param);
+void gl3_3core_glSamplerParameterf(void *_glfuncs, GLuint sampler, GLenum pname, GLfloat param);
+void gl3_3core_glSamplerParameteriv(void *_glfuncs, GLuint sampler, GLenum pname, const GLint* param);
+void gl3_3core_glSamplerParameteri(void *_glfuncs, GLuint sampler, GLenum pname, GLint param);
+void gl3_3core_glBindSampler(void *_glfuncs, GLuint unit, GLuint sampler);
+GLboolean gl3_3core_glIsSampler(void *_glfuncs, GLuint sampler);
+void gl3_3core_glDeleteSamplers(void *_glfuncs, GLsizei count, const GLuint* samplers);
+void gl3_3core_glGenSamplers(void *_glfuncs, GLsizei count, GLuint* samplers);
+GLint gl3_3core_glGetFragDataIndex(void *_glfuncs, GLuint program, const GLchar* name);
+void gl3_3core_glBindFragDataLocationIndexed(void *_glfuncs, GLuint program, GLuint colorNumber, GLuint index, const GLchar* name);
+void gl3_3core_glVertexAttribDivisor(void *_glfuncs, GLuint index, GLuint divisor);
+
+
+#ifdef __cplusplus
+} // extern "C"
+#endif
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/3.3core/gl.go b/Godeps/_workspace/src/github.com/obscuren/qml/gl/3.3core/gl.go
new file mode 100644
index 000000000..13e2a4a94
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/3.3core/gl.go
@@ -0,0 +1,5489 @@
+// ** file automatically generated by glgen -- do not edit manually **
+
+package GL
+
+// #cgo CXXFLAGS: -std=c++0x -pedantic-errors -Wall -fno-strict-aliasing
+// #cgo LDFLAGS: -lstdc++
+// #cgo pkg-config: Qt5Core Qt5OpenGL
+//
+// #include "funcs.h"
+//
+// void free(void*);
+//
+import "C"
+
+import (
+ "fmt"
+ "reflect"
+ "unsafe"
+
+ "gopkg.in/qml.v1/gl/glbase"
+)
+
+// API returns a value that offers methods matching the OpenGL version 3.3 API.
+//
+// The returned API must not be used after the provided OpenGL context becomes invalid.
+func API(context glbase.Contexter) *GL {
+ gl := &GL{}
+ gl.funcs = C.gl3_3core_funcs()
+ if gl.funcs == nil {
+ panic(fmt.Errorf("OpenGL version 3.3 is not available"))
+ }
+ return gl
+}
+
+// GL implements the OpenGL version 3.3 API. Values of this
+// type must be created via the API function, and it must not be used after
+// the associated OpenGL context becomes invalid.
+type GL struct {
+ funcs unsafe.Pointer
+}
+
+const (
+ FALSE = 0
+ TRUE = 1
+ NONE = 0
+
+ BYTE = 0x1400
+ UNSIGNED_BYTE = 0x1401
+ SHORT = 0x1402
+ UNSIGNED_SHORT = 0x1403
+ INT = 0x1404
+ UNSIGNED_INT = 0x1405
+ FLOAT = 0x1406
+ N2_BYTES = 0x1407
+ N3_BYTES = 0x1408
+ N4_BYTES = 0x1409
+ DOUBLE = 0x140A
+ HALF_FLOAT = 0x140B
+
+ ACCUM = 0x0100
+ LOAD = 0x0101
+ RETURN = 0x0102
+ MULT = 0x0103
+ ADD = 0x0104
+
+ ACCUM_BUFFER_BIT = 0x00000200
+ ALL_ATTRIB_BITS = 0xFFFFFFFF
+ COLOR_BUFFER_BIT = 0x00004000
+ CURRENT_BIT = 0x00000001
+ DEPTH_BUFFER_BIT = 0x00000100
+ ENABLE_BIT = 0x00002000
+ EVAL_BIT = 0x00010000
+ FOG_BIT = 0x00000080
+ HINT_BIT = 0x00008000
+ LIGHTING_BIT = 0x00000040
+ LINE_BIT = 0x00000004
+ LIST_BIT = 0x00020000
+ MULTISAMPLE_BIT = 0x20000000
+ PIXEL_MODE_BIT = 0x00000020
+ POINT_BIT = 0x00000002
+ POLYGON_BIT = 0x00000008
+ POLYGON_STIPPLE_BIT = 0x00000010
+ SCISSOR_BIT = 0x00080000
+ STENCIL_BUFFER_BIT = 0x00000400
+ TEXTURE_BIT = 0x00040000
+ TRANSFORM_BIT = 0x00001000
+ VIEWPORT_BIT = 0x00000800
+
+ ALWAYS = 0x0207
+ EQUAL = 0x0202
+ GEQUAL = 0x0206
+ GREATER = 0x0204
+ LEQUAL = 0x0203
+ LESS = 0x0201
+ NEVER = 0x0200
+ NOTEQUAL = 0x0205
+
+ LOGIC_OP = 0x0BF1
+
+ DST_ALPHA = 0x0304
+ ONE = 1
+ ONE_MINUS_DST_ALPHA = 0x0305
+ ONE_MINUS_SRC_ALPHA = 0x0303
+ ONE_MINUS_SRC_COLOR = 0x0301
+ SRC_ALPHA = 0x0302
+ SRC_COLOR = 0x0300
+ ZERO = 0
+
+ DST_COLOR = 0x0306
+ ONE_MINUS_DST_COLOR = 0x0307
+ SRC_ALPHA_SATURATE = 0x0308
+
+ CLIENT_ALL_ATTRIB_BITS = 0xFFFFFFFF
+ CLIENT_PIXEL_STORE_BIT = 0x00000001
+ CLIENT_VERTEX_ARRAY_BIT = 0x00000002
+
+ CLIP_DISTANCE0 = 0x3000
+ CLIP_DISTANCE1 = 0x3001
+ CLIP_DISTANCE2 = 0x3002
+ CLIP_DISTANCE3 = 0x3003
+ CLIP_DISTANCE4 = 0x3004
+ CLIP_DISTANCE5 = 0x3005
+ CLIP_DISTANCE6 = 0x3006
+ CLIP_DISTANCE7 = 0x3007
+ CLIP_PLANE0 = 0x3000
+ CLIP_PLANE1 = 0x3001
+ CLIP_PLANE2 = 0x3002
+ CLIP_PLANE3 = 0x3003
+ CLIP_PLANE4 = 0x3004
+ CLIP_PLANE5 = 0x3005
+
+ BACK = 0x0405
+ FRONT = 0x0404
+ FRONT_AND_BACK = 0x0408
+
+ AMBIENT = 0x1200
+ AMBIENT_AND_DIFFUSE = 0x1602
+ DIFFUSE = 0x1201
+ EMISSION = 0x1600
+ SPECULAR = 0x1202
+
+ CONTEXT_FLAG_FORWARD_COMPATIBLE_BIT = 0x00000001
+
+ CONTEXT_COMPATIBILITY_PROFILE_BIT = 0x00000002
+ CONTEXT_CORE_PROFILE_BIT = 0x00000001
+
+ AUX0 = 0x0409
+ AUX1 = 0x040A
+ AUX2 = 0x040B
+ AUX3 = 0x040C
+ BACK_LEFT = 0x0402
+ BACK_RIGHT = 0x0403
+ FRONT_LEFT = 0x0400
+ FRONT_RIGHT = 0x0401
+ LEFT = 0x0406
+ RIGHT = 0x0407
+
+ ALPHA_TEST = 0x0BC0
+ AUTO_NORMAL = 0x0D80
+ BLEND = 0x0BE2
+ COLOR_ARRAY = 0x8076
+ COLOR_LOGIC_OP = 0x0BF2
+ COLOR_MATERIAL = 0x0B57
+ CULL_FACE = 0x0B44
+ DEPTH_TEST = 0x0B71
+ DITHER = 0x0BD0
+ EDGE_FLAG_ARRAY = 0x8079
+ FOG = 0x0B60
+ INDEX_ARRAY = 0x8077
+ INDEX_LOGIC_OP = 0x0BF1
+ LIGHT0 = 0x4000
+ LIGHT1 = 0x4001
+ LIGHT2 = 0x4002
+ LIGHT3 = 0x4003
+ LIGHT4 = 0x4004
+ LIGHT5 = 0x4005
+ LIGHT6 = 0x4006
+ LIGHT7 = 0x4007
+ LIGHTING = 0x0B50
+ LINE_SMOOTH = 0x0B20
+ LINE_STIPPLE = 0x0B24
+ MAP1_COLOR_4 = 0x0D90
+ MAP1_INDEX = 0x0D91
+ MAP1_NORMAL = 0x0D92
+ MAP1_TEXTURE_COORD_1 = 0x0D93
+ MAP1_TEXTURE_COORD_2 = 0x0D94
+ MAP1_TEXTURE_COORD_3 = 0x0D95
+ MAP1_TEXTURE_COORD_4 = 0x0D96
+ MAP1_VERTEX_3 = 0x0D97
+ MAP1_VERTEX_4 = 0x0D98
+ MAP2_COLOR_4 = 0x0DB0
+ MAP2_INDEX = 0x0DB1
+ MAP2_NORMAL = 0x0DB2
+ MAP2_TEXTURE_COORD_1 = 0x0DB3
+ MAP2_TEXTURE_COORD_2 = 0x0DB4
+ MAP2_TEXTURE_COORD_3 = 0x0DB5
+ MAP2_TEXTURE_COORD_4 = 0x0DB6
+ MAP2_VERTEX_3 = 0x0DB7
+ MAP2_VERTEX_4 = 0x0DB8
+ NORMALIZE = 0x0BA1
+ NORMAL_ARRAY = 0x8075
+ POINT_SMOOTH = 0x0B10
+ POLYGON_OFFSET_FILL = 0x8037
+ POLYGON_OFFSET_LINE = 0x2A02
+ POLYGON_OFFSET_POINT = 0x2A01
+ POLYGON_SMOOTH = 0x0B41
+ POLYGON_STIPPLE = 0x0B42
+ SCISSOR_TEST = 0x0C11
+ STENCIL_TEST = 0x0B90
+ TEXTURE_1D = 0x0DE0
+ TEXTURE_2D = 0x0DE1
+ TEXTURE_COORD_ARRAY = 0x8078
+ TEXTURE_GEN_Q = 0x0C63
+ TEXTURE_GEN_R = 0x0C62
+ TEXTURE_GEN_S = 0x0C60
+ TEXTURE_GEN_T = 0x0C61
+ VERTEX_ARRAY = 0x8074
+
+ INVALID_ENUM = 0x0500
+ INVALID_FRAMEBUFFER_OPERATION = 0x0506
+ INVALID_OPERATION = 0x0502
+ INVALID_VALUE = 0x0501
+ NO_ERROR = 0
+ OUT_OF_MEMORY = 0x0505
+ STACK_OVERFLOW = 0x0503
+ STACK_UNDERFLOW = 0x0504
+
+ N2D = 0x0600
+ N3D = 0x0601
+ N3D_COLOR = 0x0602
+ N3D_COLOR_TEXTURE = 0x0603
+ N4D_COLOR_TEXTURE = 0x0604
+
+ BITMAP_TOKEN = 0x0704
+ COPY_PIXEL_TOKEN = 0x0706
+ DRAW_PIXEL_TOKEN = 0x0705
+ LINE_RESET_TOKEN = 0x0707
+ LINE_TOKEN = 0x0702
+ PASS_THROUGH_TOKEN = 0x0700
+ POINT_TOKEN = 0x0701
+ POLYGON_TOKEN = 0x0703
+
+ EXP = 0x0800
+ EXP2 = 0x0801
+ LINEAR = 0x2601
+
+ FOG_COLOR = 0x0B66
+ FOG_DENSITY = 0x0B62
+ FOG_END = 0x0B64
+ FOG_INDEX = 0x0B61
+ FOG_MODE = 0x0B65
+ FOG_START = 0x0B63
+
+ CCW = 0x0901
+ CW = 0x0900
+
+ COEFF = 0x0A00
+ DOMAIN = 0x0A02
+ ORDER = 0x0A01
+
+ PIXEL_MAP_A_TO_A = 0x0C79
+ PIXEL_MAP_B_TO_B = 0x0C78
+ PIXEL_MAP_G_TO_G = 0x0C77
+ PIXEL_MAP_I_TO_A = 0x0C75
+ PIXEL_MAP_I_TO_B = 0x0C74
+ PIXEL_MAP_I_TO_G = 0x0C73
+ PIXEL_MAP_I_TO_I = 0x0C70
+ PIXEL_MAP_I_TO_R = 0x0C72
+ PIXEL_MAP_R_TO_R = 0x0C76
+ PIXEL_MAP_S_TO_S = 0x0C71
+
+ ACCUM_ALPHA_BITS = 0x0D5B
+ ACCUM_BLUE_BITS = 0x0D5A
+ ACCUM_CLEAR_VALUE = 0x0B80
+ ACCUM_GREEN_BITS = 0x0D59
+ ACCUM_RED_BITS = 0x0D58
+ ALIASED_LINE_WIDTH_RANGE = 0x846E
+ ALIASED_POINT_SIZE_RANGE = 0x846D
+ ALPHA_BIAS = 0x0D1D
+ ALPHA_BITS = 0x0D55
+ ALPHA_SCALE = 0x0D1C
+ ALPHA_TEST_FUNC = 0x0BC1
+ ALPHA_TEST_REF = 0x0BC2
+ ATTRIB_STACK_DEPTH = 0x0BB0
+ AUX_BUFFERS = 0x0C00
+ BLEND_DST = 0x0BE0
+ BLEND_SRC = 0x0BE1
+ BLUE_BIAS = 0x0D1B
+ BLUE_BITS = 0x0D54
+ BLUE_SCALE = 0x0D1A
+ CLIENT_ATTRIB_STACK_DEPTH = 0x0BB1
+ COLOR_ARRAY_SIZE = 0x8081
+ COLOR_ARRAY_STRIDE = 0x8083
+ COLOR_ARRAY_TYPE = 0x8082
+ COLOR_CLEAR_VALUE = 0x0C22
+ COLOR_MATERIAL_FACE = 0x0B55
+ COLOR_MATERIAL_PARAMETER = 0x0B56
+ COLOR_WRITEMASK = 0x0C23
+ CULL_FACE_MODE = 0x0B45
+ CURRENT_COLOR = 0x0B00
+ CURRENT_INDEX = 0x0B01
+ CURRENT_NORMAL = 0x0B02
+ CURRENT_RASTER_COLOR = 0x0B04
+ CURRENT_RASTER_DISTANCE = 0x0B09
+ CURRENT_RASTER_INDEX = 0x0B05
+ CURRENT_RASTER_POSITION = 0x0B07
+ CURRENT_RASTER_POSITION_VALID = 0x0B08
+ CURRENT_RASTER_TEXTURE_COORDS = 0x0B06
+ CURRENT_TEXTURE_COORDS = 0x0B03
+ DEPTH_BIAS = 0x0D1F
+ DEPTH_BITS = 0x0D56
+ DEPTH_CLEAR_VALUE = 0x0B73
+ DEPTH_FUNC = 0x0B74
+ DEPTH_RANGE = 0x0B70
+ DEPTH_SCALE = 0x0D1E
+ DEPTH_WRITEMASK = 0x0B72
+ DOUBLEBUFFER = 0x0C32
+ DRAW_BUFFER = 0x0C01
+ EDGE_FLAG = 0x0B43
+ EDGE_FLAG_ARRAY_STRIDE = 0x808C
+ FEEDBACK_BUFFER_SIZE = 0x0DF1
+ FEEDBACK_BUFFER_TYPE = 0x0DF2
+ FOG_HINT = 0x0C54
+ FRONT_FACE = 0x0B46
+ GREEN_BIAS = 0x0D19
+ GREEN_BITS = 0x0D53
+ GREEN_SCALE = 0x0D18
+ INDEX_ARRAY_STRIDE = 0x8086
+ INDEX_ARRAY_TYPE = 0x8085
+ INDEX_BITS = 0x0D51
+ INDEX_CLEAR_VALUE = 0x0C20
+ INDEX_MODE = 0x0C30
+ INDEX_OFFSET = 0x0D13
+ INDEX_SHIFT = 0x0D12
+ INDEX_WRITEMASK = 0x0C21
+ LIGHT_MODEL_AMBIENT = 0x0B53
+ LIGHT_MODEL_COLOR_CONTROL = 0x81F8
+ LIGHT_MODEL_LOCAL_VIEWER = 0x0B51
+ LIGHT_MODEL_TWO_SIDE = 0x0B52
+ LINE_SMOOTH_HINT = 0x0C52
+ LINE_STIPPLE_PATTERN = 0x0B25
+ LINE_STIPPLE_REPEAT = 0x0B26
+ LINE_WIDTH = 0x0B21
+ LINE_WIDTH_GRANULARITY = 0x0B23
+ LINE_WIDTH_RANGE = 0x0B22
+ LIST_BASE = 0x0B32
+ LIST_INDEX = 0x0B33
+ LIST_MODE = 0x0B30
+ LOGIC_OP_MODE = 0x0BF0
+ MAP1_GRID_DOMAIN = 0x0DD0
+ MAP1_GRID_SEGMENTS = 0x0DD1
+ MAP2_GRID_DOMAIN = 0x0DD2
+ MAP2_GRID_SEGMENTS = 0x0DD3
+ MAP_COLOR = 0x0D10
+ MAP_STENCIL = 0x0D11
+ MATRIX_MODE = 0x0BA0
+ MAX_ATTRIB_STACK_DEPTH = 0x0D35
+ MAX_CLIENT_ATTRIB_STACK_DEPTH = 0x0D3B
+ MAX_CLIP_DISTANCES = 0x0D32
+ MAX_CLIP_PLANES = 0x0D32
+ MAX_EVAL_ORDER = 0x0D30
+ MAX_LIGHTS = 0x0D31
+ MAX_LIST_NESTING = 0x0B31
+ MAX_MODELVIEW_STACK_DEPTH = 0x0D36
+ MAX_NAME_STACK_DEPTH = 0x0D37
+ MAX_PIXEL_MAP_TABLE = 0x0D34
+ MAX_PROJECTION_STACK_DEPTH = 0x0D38
+ MAX_TEXTURE_SIZE = 0x0D33
+ MAX_TEXTURE_STACK_DEPTH = 0x0D39
+ MAX_VIEWPORT_DIMS = 0x0D3A
+ MODELVIEW_MATRIX = 0x0BA6
+ MODELVIEW_STACK_DEPTH = 0x0BA3
+ NAME_STACK_DEPTH = 0x0D70
+ NORMAL_ARRAY_STRIDE = 0x807F
+ NORMAL_ARRAY_TYPE = 0x807E
+ PACK_ALIGNMENT = 0x0D05
+ PACK_LSB_FIRST = 0x0D01
+ PACK_ROW_LENGTH = 0x0D02
+ PACK_SKIP_PIXELS = 0x0D04
+ PACK_SKIP_ROWS = 0x0D03
+ PACK_SWAP_BYTES = 0x0D00
+ PERSPECTIVE_CORRECTION_HINT = 0x0C50
+ PIXEL_MAP_A_TO_A_SIZE = 0x0CB9
+ PIXEL_MAP_B_TO_B_SIZE = 0x0CB8
+ PIXEL_MAP_G_TO_G_SIZE = 0x0CB7
+ PIXEL_MAP_I_TO_A_SIZE = 0x0CB5
+ PIXEL_MAP_I_TO_B_SIZE = 0x0CB4
+ PIXEL_MAP_I_TO_G_SIZE = 0x0CB3
+ PIXEL_MAP_I_TO_I_SIZE = 0x0CB0
+ PIXEL_MAP_I_TO_R_SIZE = 0x0CB2
+ PIXEL_MAP_R_TO_R_SIZE = 0x0CB6
+ PIXEL_MAP_S_TO_S_SIZE = 0x0CB1
+ POINT_SIZE = 0x0B11
+ POINT_SIZE_GRANULARITY = 0x0B13
+ POINT_SIZE_RANGE = 0x0B12
+ POINT_SMOOTH_HINT = 0x0C51
+ POLYGON_MODE = 0x0B40
+ POLYGON_OFFSET_FACTOR = 0x8038
+ POLYGON_OFFSET_UNITS = 0x2A00
+ POLYGON_SMOOTH_HINT = 0x0C53
+ PROJECTION_MATRIX = 0x0BA7
+ PROJECTION_STACK_DEPTH = 0x0BA4
+ READ_BUFFER = 0x0C02
+ RED_BIAS = 0x0D15
+ RED_BITS = 0x0D52
+ RED_SCALE = 0x0D14
+ RENDER_MODE = 0x0C40
+ RGBA_MODE = 0x0C31
+ SCISSOR_BOX = 0x0C10
+ SELECTION_BUFFER_SIZE = 0x0DF4
+ SHADE_MODEL = 0x0B54
+ SMOOTH_LINE_WIDTH_GRANULARITY = 0x0B23
+ SMOOTH_LINE_WIDTH_RANGE = 0x0B22
+ SMOOTH_POINT_SIZE_GRANULARITY = 0x0B13
+ SMOOTH_POINT_SIZE_RANGE = 0x0B12
+ STENCIL_BITS = 0x0D57
+ STENCIL_CLEAR_VALUE = 0x0B91
+ STENCIL_FAIL = 0x0B94
+ STENCIL_FUNC = 0x0B92
+ STENCIL_PASS_DEPTH_FAIL = 0x0B95
+ STENCIL_PASS_DEPTH_PASS = 0x0B96
+ STENCIL_REF = 0x0B97
+ STENCIL_VALUE_MASK = 0x0B93
+ STENCIL_WRITEMASK = 0x0B98
+ STEREO = 0x0C33
+ SUBPIXEL_BITS = 0x0D50
+ TEXTURE_BINDING_1D = 0x8068
+ TEXTURE_BINDING_2D = 0x8069
+ TEXTURE_BINDING_3D = 0x806A
+ TEXTURE_COORD_ARRAY_SIZE = 0x8088
+ TEXTURE_COORD_ARRAY_STRIDE = 0x808A
+ TEXTURE_COORD_ARRAY_TYPE = 0x8089
+ TEXTURE_MATRIX = 0x0BA8
+ TEXTURE_STACK_DEPTH = 0x0BA5
+ UNPACK_ALIGNMENT = 0x0CF5
+ UNPACK_LSB_FIRST = 0x0CF1
+ UNPACK_ROW_LENGTH = 0x0CF2
+ UNPACK_SKIP_PIXELS = 0x0CF4
+ UNPACK_SKIP_ROWS = 0x0CF3
+ UNPACK_SWAP_BYTES = 0x0CF0
+ VERTEX_ARRAY_SIZE = 0x807A
+ VERTEX_ARRAY_STRIDE = 0x807C
+ VERTEX_ARRAY_TYPE = 0x807B
+ VIEWPORT = 0x0BA2
+ ZOOM_X = 0x0D16
+ ZOOM_Y = 0x0D17
+
+ COLOR_ARRAY_POINTER = 0x8090
+ EDGE_FLAG_ARRAY_POINTER = 0x8093
+ FEEDBACK_BUFFER_POINTER = 0x0DF0
+ INDEX_ARRAY_POINTER = 0x8091
+ NORMAL_ARRAY_POINTER = 0x808F
+ SELECTION_BUFFER_POINTER = 0x0DF3
+ TEXTURE_COORD_ARRAY_POINTER = 0x8092
+ VERTEX_ARRAY_POINTER = 0x808E
+
+ TEXTURE_ALPHA_SIZE = 0x805F
+ TEXTURE_BLUE_SIZE = 0x805E
+ TEXTURE_BORDER = 0x1005
+ TEXTURE_BORDER_COLOR = 0x1004
+ TEXTURE_COMPONENTS = 0x1003
+ TEXTURE_GREEN_SIZE = 0x805D
+ TEXTURE_HEIGHT = 0x1001
+ TEXTURE_INTENSITY_SIZE = 0x8061
+ TEXTURE_INTERNAL_FORMAT = 0x1003
+ TEXTURE_LUMINANCE_SIZE = 0x8060
+ TEXTURE_MAG_FILTER = 0x2800
+ TEXTURE_MIN_FILTER = 0x2801
+ TEXTURE_PRIORITY = 0x8066
+ TEXTURE_RED_SIZE = 0x805C
+ TEXTURE_RESIDENT = 0x8067
+ TEXTURE_WIDTH = 0x1000
+ TEXTURE_WRAP_S = 0x2802
+ TEXTURE_WRAP_T = 0x2803
+
+ DONT_CARE = 0x1100
+ FASTEST = 0x1101
+ NICEST = 0x1102
+
+ FRAGMENT_SHADER_DERIVATIVE_HINT = 0x8B8B
+ GENERATE_MIPMAP_HINT = 0x8192
+ TEXTURE_COMPRESSION_HINT = 0x84EF
+
+ C3F_V3F = 0x2A24
+ C4F_N3F_V3F = 0x2A26
+ C4UB_V2F = 0x2A22
+ C4UB_V3F = 0x2A23
+ N3F_V3F = 0x2A25
+ T2F_C3F_V3F = 0x2A2A
+ T2F_C4F_N3F_V3F = 0x2A2C
+ T2F_C4UB_V3F = 0x2A29
+ T2F_N3F_V3F = 0x2A2B
+ T2F_V3F = 0x2A27
+ T4F_C4F_N3F_V4F = 0x2A2D
+ T4F_V4F = 0x2A28
+ V2F = 0x2A20
+ V3F = 0x2A21
+
+ MODULATE = 0x2100
+ REPLACE = 0x1E01
+
+ SEPARATE_SPECULAR_COLOR = 0x81FA
+ SINGLE_COLOR = 0x81F9
+
+ CONSTANT_ATTENUATION = 0x1207
+ LINEAR_ATTENUATION = 0x1208
+ POSITION = 0x1203
+ QUADRATIC_ATTENUATION = 0x1209
+ SPOT_CUTOFF = 0x1206
+ SPOT_DIRECTION = 0x1204
+ SPOT_EXPONENT = 0x1205
+
+ COMPILE = 0x1300
+ COMPILE_AND_EXECUTE = 0x1301
+
+ AND = 0x1501
+ AND_INVERTED = 0x1504
+ AND_REVERSE = 0x1502
+ CLEAR = 0x1500
+ COPY = 0x1503
+ COPY_INVERTED = 0x150C
+ EQUIV = 0x1509
+ INVERT = 0x150A
+ NAND = 0x150E
+ NOOP = 0x1505
+ NOR = 0x1508
+ OR = 0x1507
+ OR_INVERTED = 0x150D
+ OR_REVERSE = 0x150B
+ SET = 0x150F
+ XOR = 0x1506
+
+ MAP_FLUSH_EXPLICIT_BIT = 0x0010
+ MAP_INVALIDATE_BUFFER_BIT = 0x0008
+ MAP_INVALIDATE_RANGE_BIT = 0x0004
+ MAP_READ_BIT = 0x0001
+ MAP_UNSYNCHRONIZED_BIT = 0x0020
+ MAP_WRITE_BIT = 0x0002
+
+ COLOR_INDEXES = 0x1603
+ SHININESS = 0x1601
+
+ MODELVIEW = 0x1700
+ PROJECTION = 0x1701
+ TEXTURE = 0x1702
+
+ LINE = 0x1B01
+ POINT = 0x1B00
+
+ FILL = 0x1B02
+
+ COLOR = 0x1800
+ DEPTH = 0x1801
+ STENCIL = 0x1802
+
+ ALPHA = 0x1906
+ BLUE = 0x1905
+ COLOR_INDEX = 0x1900
+ DEPTH_COMPONENT = 0x1902
+ GREEN = 0x1904
+ LUMINANCE = 0x1909
+ LUMINANCE_ALPHA = 0x190A
+ RED = 0x1903
+ RGB = 0x1907
+ RGBA = 0x1908
+ STENCIL_INDEX = 0x1901
+
+ ALPHA12 = 0x803D
+ ALPHA16 = 0x803E
+ ALPHA4 = 0x803B
+ ALPHA8 = 0x803C
+ INTENSITY = 0x8049
+ INTENSITY12 = 0x804C
+ INTENSITY16 = 0x804D
+ INTENSITY4 = 0x804A
+ INTENSITY8 = 0x804B
+ LUMINANCE12 = 0x8041
+ LUMINANCE12_ALPHA12 = 0x8047
+ LUMINANCE12_ALPHA4 = 0x8046
+ LUMINANCE16 = 0x8042
+ LUMINANCE16_ALPHA16 = 0x8048
+ LUMINANCE4 = 0x803F
+ LUMINANCE4_ALPHA4 = 0x8043
+ LUMINANCE6_ALPHA2 = 0x8044
+ LUMINANCE8 = 0x8040
+ LUMINANCE8_ALPHA8 = 0x8045
+ R3_G3_B2 = 0x2A10
+ RGB10 = 0x8052
+ RGB10_A2 = 0x8059
+ RGB12 = 0x8053
+ RGB16 = 0x8054
+ RGB4 = 0x804F
+ RGB5 = 0x8050
+ RGB5_A1 = 0x8057
+ RGB8 = 0x8051
+ RGBA12 = 0x805A
+ RGBA16 = 0x805B
+ RGBA2 = 0x8055
+ RGBA4 = 0x8056
+ RGBA8 = 0x8058
+
+ PACK_IMAGE_HEIGHT = 0x806C
+ PACK_SKIP_IMAGES = 0x806B
+ UNPACK_IMAGE_HEIGHT = 0x806E
+ UNPACK_SKIP_IMAGES = 0x806D
+
+ BITMAP = 0x1A00
+ UNSIGNED_BYTE_3_3_2 = 0x8032
+ UNSIGNED_INT_10_10_10_2 = 0x8036
+ UNSIGNED_INT_8_8_8_8 = 0x8035
+ UNSIGNED_SHORT_4_4_4_4 = 0x8033
+ UNSIGNED_SHORT_5_5_5_1 = 0x8034
+
+ POINT_DISTANCE_ATTENUATION = 0x8129
+ POINT_FADE_THRESHOLD_SIZE = 0x8128
+ POINT_SIZE_MAX = 0x8127
+ POINT_SIZE_MIN = 0x8126
+
+ LINES = 0x0001
+ LINES_ADJACENCY = 0x000A
+ LINE_LOOP = 0x0002
+ LINE_STRIP = 0x0003
+ LINE_STRIP_ADJACENCY = 0x000B
+ POINTS = 0x0000
+ POLYGON = 0x0009
+ QUADS = 0x0007
+ QUAD_STRIP = 0x0008
+ TRIANGLES = 0x0004
+ TRIANGLES_ADJACENCY = 0x000C
+ TRIANGLE_FAN = 0x0006
+ TRIANGLE_STRIP = 0x0005
+ TRIANGLE_STRIP_ADJACENCY = 0x000D
+
+ FEEDBACK = 0x1C01
+ RENDER = 0x1C00
+ SELECT = 0x1C02
+
+ FLAT = 0x1D00
+ SMOOTH = 0x1D01
+
+ DECR = 0x1E03
+ INCR = 0x1E02
+ KEEP = 0x1E00
+
+ EXTENSIONS = 0x1F03
+ RENDERER = 0x1F01
+ VENDOR = 0x1F00
+ VERSION = 0x1F02
+
+ S = 0x2000
+ T = 0x2001
+ R = 0x2002
+ Q = 0x2003
+
+ DECAL = 0x2101
+
+ TEXTURE_ENV_COLOR = 0x2201
+ TEXTURE_ENV_MODE = 0x2200
+
+ TEXTURE_ENV = 0x2300
+
+ EYE_LINEAR = 0x2400
+ OBJECT_LINEAR = 0x2401
+ SPHERE_MAP = 0x2402
+
+ EYE_PLANE = 0x2502
+ OBJECT_PLANE = 0x2501
+ TEXTURE_GEN_MODE = 0x2500
+
+ NEAREST = 0x2600
+
+ LINEAR_MIPMAP_LINEAR = 0x2703
+ LINEAR_MIPMAP_NEAREST = 0x2701
+ NEAREST_MIPMAP_LINEAR = 0x2702
+ NEAREST_MIPMAP_NEAREST = 0x2700
+
+ GENERATE_MIPMAP = 0x8191
+ TEXTURE_WRAP_R = 0x8072
+
+ PROXY_TEXTURE_1D = 0x8063
+ PROXY_TEXTURE_2D = 0x8064
+ PROXY_TEXTURE_3D = 0x8070
+ TEXTURE_3D = 0x806F
+ TEXTURE_BASE_LEVEL = 0x813C
+ TEXTURE_MAX_LEVEL = 0x813D
+ TEXTURE_MAX_LOD = 0x813B
+ TEXTURE_MIN_LOD = 0x813A
+
+ CLAMP = 0x2900
+ CLAMP_TO_BORDER = 0x812D
+ CLAMP_TO_EDGE = 0x812F
+ REPEAT = 0x2901
+
+ SYNC_FLUSH_COMMANDS_BIT = 0x00000001
+ INVALID_INDEX = 0xFFFFFFFF
+ TIMEOUT_IGNORED = 0xFFFFFFFFFFFFFFFF
+ CONSTANT_COLOR = 0x8001
+ ONE_MINUS_CONSTANT_COLOR = 0x8002
+ CONSTANT_ALPHA = 0x8003
+ ONE_MINUS_CONSTANT_ALPHA = 0x8004
+ FUNC_ADD = 0x8006
+ MIN = 0x8007
+ MAX = 0x8008
+ BLEND_EQUATION_RGB = 0x8009
+ FUNC_SUBTRACT = 0x800A
+ FUNC_REVERSE_SUBTRACT = 0x800B
+ RESCALE_NORMAL = 0x803A
+ TEXTURE_DEPTH = 0x8071
+ MAX_3D_TEXTURE_SIZE = 0x8073
+ MULTISAMPLE = 0x809D
+ SAMPLE_ALPHA_TO_COVERAGE = 0x809E
+ SAMPLE_ALPHA_TO_ONE = 0x809F
+ SAMPLE_COVERAGE = 0x80A0
+ SAMPLE_BUFFERS = 0x80A8
+ SAMPLES = 0x80A9
+ SAMPLE_COVERAGE_VALUE = 0x80AA
+ SAMPLE_COVERAGE_INVERT = 0x80AB
+ BLEND_DST_RGB = 0x80C8
+ BLEND_SRC_RGB = 0x80C9
+ BLEND_DST_ALPHA = 0x80CA
+ BLEND_SRC_ALPHA = 0x80CB
+ BGR = 0x80E0
+ BGRA = 0x80E1
+ MAX_ELEMENTS_VERTICES = 0x80E8
+ MAX_ELEMENTS_INDICES = 0x80E9
+ DEPTH_COMPONENT16 = 0x81A5
+ DEPTH_COMPONENT24 = 0x81A6
+ DEPTH_COMPONENT32 = 0x81A7
+ FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING = 0x8210
+ FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE = 0x8211
+ FRAMEBUFFER_ATTACHMENT_RED_SIZE = 0x8212
+ FRAMEBUFFER_ATTACHMENT_GREEN_SIZE = 0x8213
+ FRAMEBUFFER_ATTACHMENT_BLUE_SIZE = 0x8214
+ FRAMEBUFFER_ATTACHMENT_ALPHA_SIZE = 0x8215
+ FRAMEBUFFER_ATTACHMENT_DEPTH_SIZE = 0x8216
+ FRAMEBUFFER_ATTACHMENT_STENCIL_SIZE = 0x8217
+ FRAMEBUFFER_DEFAULT = 0x8218
+ FRAMEBUFFER_UNDEFINED = 0x8219
+ DEPTH_STENCIL_ATTACHMENT = 0x821A
+ MAJOR_VERSION = 0x821B
+ MINOR_VERSION = 0x821C
+ NUM_EXTENSIONS = 0x821D
+ CONTEXT_FLAGS = 0x821E
+ COMPRESSED_RED = 0x8225
+ COMPRESSED_RG = 0x8226
+ RG = 0x8227
+ RG_INTEGER = 0x8228
+ R8 = 0x8229
+ R16 = 0x822A
+ RG8 = 0x822B
+ RG16 = 0x822C
+ R16F = 0x822D
+ R32F = 0x822E
+ RG16F = 0x822F
+ RG32F = 0x8230
+ R8I = 0x8231
+ R8UI = 0x8232
+ R16I = 0x8233
+ R16UI = 0x8234
+ R32I = 0x8235
+ R32UI = 0x8236
+ RG8I = 0x8237
+ RG8UI = 0x8238
+ RG16I = 0x8239
+ RG16UI = 0x823A
+ RG32I = 0x823B
+ RG32UI = 0x823C
+ UNSIGNED_BYTE_2_3_3_REV = 0x8362
+ UNSIGNED_SHORT_5_6_5 = 0x8363
+ UNSIGNED_SHORT_5_6_5_REV = 0x8364
+ UNSIGNED_SHORT_4_4_4_4_REV = 0x8365
+ UNSIGNED_SHORT_1_5_5_5_REV = 0x8366
+ UNSIGNED_INT_8_8_8_8_REV = 0x8367
+ UNSIGNED_INT_2_10_10_10_REV = 0x8368
+ MIRRORED_REPEAT = 0x8370
+ FOG_COORDINATE_SOURCE = 0x8450
+ FOG_COORD_SRC = 0x8450
+ FOG_COORDINATE = 0x8451
+ FOG_COORD = 0x8451
+ FRAGMENT_DEPTH = 0x8452
+ CURRENT_FOG_COORDINATE = 0x8453
+ CURRENT_FOG_COORD = 0x8453
+ FOG_COORDINATE_ARRAY_TYPE = 0x8454
+ FOG_COORD_ARRAY_TYPE = 0x8454
+ FOG_COORDINATE_ARRAY_STRIDE = 0x8455
+ FOG_COORD_ARRAY_STRIDE = 0x8455
+ FOG_COORDINATE_ARRAY_POINTER = 0x8456
+ FOG_COORD_ARRAY_POINTER = 0x8456
+ FOG_COORDINATE_ARRAY = 0x8457
+ FOG_COORD_ARRAY = 0x8457
+ COLOR_SUM = 0x8458
+ CURRENT_SECONDARY_COLOR = 0x8459
+ SECONDARY_COLOR_ARRAY_SIZE = 0x845A
+ SECONDARY_COLOR_ARRAY_TYPE = 0x845B
+ SECONDARY_COLOR_ARRAY_STRIDE = 0x845C
+ SECONDARY_COLOR_ARRAY_POINTER = 0x845D
+ SECONDARY_COLOR_ARRAY = 0x845E
+ CURRENT_RASTER_SECONDARY_COLOR = 0x845F
+ TEXTURE0 = 0x84C0
+ TEXTURE1 = 0x84C1
+ TEXTURE2 = 0x84C2
+ TEXTURE3 = 0x84C3
+ TEXTURE4 = 0x84C4
+ TEXTURE5 = 0x84C5
+ TEXTURE6 = 0x84C6
+ TEXTURE7 = 0x84C7
+ TEXTURE8 = 0x84C8
+ TEXTURE9 = 0x84C9
+ TEXTURE10 = 0x84CA
+ TEXTURE11 = 0x84CB
+ TEXTURE12 = 0x84CC
+ TEXTURE13 = 0x84CD
+ TEXTURE14 = 0x84CE
+ TEXTURE15 = 0x84CF
+ TEXTURE16 = 0x84D0
+ TEXTURE17 = 0x84D1
+ TEXTURE18 = 0x84D2
+ TEXTURE19 = 0x84D3
+ TEXTURE20 = 0x84D4
+ TEXTURE21 = 0x84D5
+ TEXTURE22 = 0x84D6
+ TEXTURE23 = 0x84D7
+ TEXTURE24 = 0x84D8
+ TEXTURE25 = 0x84D9
+ TEXTURE26 = 0x84DA
+ TEXTURE27 = 0x84DB
+ TEXTURE28 = 0x84DC
+ TEXTURE29 = 0x84DD
+ TEXTURE30 = 0x84DE
+ TEXTURE31 = 0x84DF
+ ACTIVE_TEXTURE = 0x84E0
+ CLIENT_ACTIVE_TEXTURE = 0x84E1
+ MAX_TEXTURE_UNITS = 0x84E2
+ TRANSPOSE_MODELVIEW_MATRIX = 0x84E3
+ TRANSPOSE_PROJECTION_MATRIX = 0x84E4
+ TRANSPOSE_TEXTURE_MATRIX = 0x84E5
+ TRANSPOSE_COLOR_MATRIX = 0x84E6
+ SUBTRACT = 0x84E7
+ MAX_RENDERBUFFER_SIZE = 0x84E8
+ COMPRESSED_ALPHA = 0x84E9
+ COMPRESSED_LUMINANCE = 0x84EA
+ COMPRESSED_LUMINANCE_ALPHA = 0x84EB
+ COMPRESSED_INTENSITY = 0x84EC
+ COMPRESSED_RGB = 0x84ED
+ COMPRESSED_RGBA = 0x84EE
+ TEXTURE_RECTANGLE = 0x84F5
+ TEXTURE_BINDING_RECTANGLE = 0x84F6
+ PROXY_TEXTURE_RECTANGLE = 0x84F7
+ MAX_RECTANGLE_TEXTURE_SIZE = 0x84F8
+ DEPTH_STENCIL = 0x84F9
+ UNSIGNED_INT_24_8 = 0x84FA
+ MAX_TEXTURE_LOD_BIAS = 0x84FD
+ TEXTURE_FILTER_CONTROL = 0x8500
+ TEXTURE_LOD_BIAS = 0x8501
+ INCR_WRAP = 0x8507
+ DECR_WRAP = 0x8508
+ NORMAL_MAP = 0x8511
+ REFLECTION_MAP = 0x8512
+ TEXTURE_CUBE_MAP = 0x8513
+ TEXTURE_BINDING_CUBE_MAP = 0x8514
+ TEXTURE_CUBE_MAP_POSITIVE_X = 0x8515
+ TEXTURE_CUBE_MAP_NEGATIVE_X = 0x8516
+ TEXTURE_CUBE_MAP_POSITIVE_Y = 0x8517
+ TEXTURE_CUBE_MAP_NEGATIVE_Y = 0x8518
+ TEXTURE_CUBE_MAP_POSITIVE_Z = 0x8519
+ TEXTURE_CUBE_MAP_NEGATIVE_Z = 0x851A
+ PROXY_TEXTURE_CUBE_MAP = 0x851B
+ MAX_CUBE_MAP_TEXTURE_SIZE = 0x851C
+ COMBINE = 0x8570
+ COMBINE_RGB = 0x8571
+ COMBINE_ALPHA = 0x8572
+ RGB_SCALE = 0x8573
+ ADD_SIGNED = 0x8574
+ INTERPOLATE = 0x8575
+ CONSTANT = 0x8576
+ PRIMARY_COLOR = 0x8577
+ PREVIOUS = 0x8578
+ SOURCE0_RGB = 0x8580
+ SRC0_RGB = 0x8580
+ SOURCE1_RGB = 0x8581
+ SRC1_RGB = 0x8581
+ SOURCE2_RGB = 0x8582
+ SRC2_RGB = 0x8582
+ SOURCE0_ALPHA = 0x8588
+ SRC0_ALPHA = 0x8588
+ SOURCE1_ALPHA = 0x8589
+ SRC1_ALPHA = 0x8589
+ SOURCE2_ALPHA = 0x858A
+ SRC2_ALPHA = 0x858A
+ OPERAND0_RGB = 0x8590
+ OPERAND1_RGB = 0x8591
+ OPERAND2_RGB = 0x8592
+ OPERAND0_ALPHA = 0x8598
+ OPERAND1_ALPHA = 0x8599
+ OPERAND2_ALPHA = 0x859A
+ VERTEX_ARRAY_BINDING = 0x85B5
+ VERTEX_ATTRIB_ARRAY_ENABLED = 0x8622
+ VERTEX_ATTRIB_ARRAY_SIZE = 0x8623
+ VERTEX_ATTRIB_ARRAY_STRIDE = 0x8624
+ VERTEX_ATTRIB_ARRAY_TYPE = 0x8625
+ CURRENT_VERTEX_ATTRIB = 0x8626
+ VERTEX_PROGRAM_POINT_SIZE = 0x8642
+ PROGRAM_POINT_SIZE = 0x8642
+ VERTEX_PROGRAM_TWO_SIDE = 0x8643
+ VERTEX_ATTRIB_ARRAY_POINTER = 0x8645
+ DEPTH_CLAMP = 0x864F
+ TEXTURE_COMPRESSED_IMAGE_SIZE = 0x86A0
+ TEXTURE_COMPRESSED = 0x86A1
+ NUM_COMPRESSED_TEXTURE_FORMATS = 0x86A2
+ COMPRESSED_TEXTURE_FORMATS = 0x86A3
+ DOT3_RGB = 0x86AE
+ DOT3_RGBA = 0x86AF
+ BUFFER_SIZE = 0x8764
+ BUFFER_USAGE = 0x8765
+ STENCIL_BACK_FUNC = 0x8800
+ STENCIL_BACK_FAIL = 0x8801
+ STENCIL_BACK_PASS_DEPTH_FAIL = 0x8802
+ STENCIL_BACK_PASS_DEPTH_PASS = 0x8803
+ RGBA32F = 0x8814
+ RGB32F = 0x8815
+ RGBA16F = 0x881A
+ RGB16F = 0x881B
+ MAX_DRAW_BUFFERS = 0x8824
+ DRAW_BUFFER0 = 0x8825
+ DRAW_BUFFER1 = 0x8826
+ DRAW_BUFFER2 = 0x8827
+ DRAW_BUFFER3 = 0x8828
+ DRAW_BUFFER4 = 0x8829
+ DRAW_BUFFER5 = 0x882A
+ DRAW_BUFFER6 = 0x882B
+ DRAW_BUFFER7 = 0x882C
+ DRAW_BUFFER8 = 0x882D
+ DRAW_BUFFER9 = 0x882E
+ DRAW_BUFFER10 = 0x882F
+ DRAW_BUFFER11 = 0x8830
+ DRAW_BUFFER12 = 0x8831
+ DRAW_BUFFER13 = 0x8832
+ DRAW_BUFFER14 = 0x8833
+ DRAW_BUFFER15 = 0x8834
+ BLEND_EQUATION_ALPHA = 0x883D
+ TEXTURE_DEPTH_SIZE = 0x884A
+ DEPTH_TEXTURE_MODE = 0x884B
+ TEXTURE_COMPARE_MODE = 0x884C
+ TEXTURE_COMPARE_FUNC = 0x884D
+ COMPARE_R_TO_TEXTURE = 0x884E
+ COMPARE_REF_TO_TEXTURE = 0x884E
+ TEXTURE_CUBE_MAP_SEAMLESS = 0x884F
+ POINT_SPRITE = 0x8861
+ COORD_REPLACE = 0x8862
+ QUERY_COUNTER_BITS = 0x8864
+ CURRENT_QUERY = 0x8865
+ QUERY_RESULT = 0x8866
+ QUERY_RESULT_AVAILABLE = 0x8867
+ MAX_VERTEX_ATTRIBS = 0x8869
+ VERTEX_ATTRIB_ARRAY_NORMALIZED = 0x886A
+ MAX_TEXTURE_COORDS = 0x8871
+ MAX_TEXTURE_IMAGE_UNITS = 0x8872
+ ARRAY_BUFFER = 0x8892
+ ELEMENT_ARRAY_BUFFER = 0x8893
+ ARRAY_BUFFER_BINDING = 0x8894
+ ELEMENT_ARRAY_BUFFER_BINDING = 0x8895
+ VERTEX_ARRAY_BUFFER_BINDING = 0x8896
+ NORMAL_ARRAY_BUFFER_BINDING = 0x8897
+ COLOR_ARRAY_BUFFER_BINDING = 0x8898
+ INDEX_ARRAY_BUFFER_BINDING = 0x8899
+ TEXTURE_COORD_ARRAY_BUFFER_BINDING = 0x889A
+ EDGE_FLAG_ARRAY_BUFFER_BINDING = 0x889B
+ SECONDARY_COLOR_ARRAY_BUFFER_BINDING = 0x889C
+ FOG_COORDINATE_ARRAY_BUFFER_BINDING = 0x889D
+ FOG_COORD_ARRAY_BUFFER_BINDING = 0x889D
+ WEIGHT_ARRAY_BUFFER_BINDING = 0x889E
+ VERTEX_ATTRIB_ARRAY_BUFFER_BINDING = 0x889F
+ READ_ONLY = 0x88B8
+ WRITE_ONLY = 0x88B9
+ READ_WRITE = 0x88BA
+ BUFFER_ACCESS = 0x88BB
+ BUFFER_MAPPED = 0x88BC
+ BUFFER_MAP_POINTER = 0x88BD
+ TIME_ELAPSED = 0x88BF
+ STREAM_DRAW = 0x88E0
+ STREAM_READ = 0x88E1
+ STREAM_COPY = 0x88E2
+ STATIC_DRAW = 0x88E4
+ STATIC_READ = 0x88E5
+ STATIC_COPY = 0x88E6
+ DYNAMIC_DRAW = 0x88E8
+ DYNAMIC_READ = 0x88E9
+ DYNAMIC_COPY = 0x88EA
+ PIXEL_PACK_BUFFER = 0x88EB
+ PIXEL_UNPACK_BUFFER = 0x88EC
+ PIXEL_PACK_BUFFER_BINDING = 0x88ED
+ PIXEL_UNPACK_BUFFER_BINDING = 0x88EF
+ DEPTH24_STENCIL8 = 0x88F0
+ TEXTURE_STENCIL_SIZE = 0x88F1
+ SRC1_COLOR = 0x88F9
+ ONE_MINUS_SRC1_COLOR = 0x88FA
+ ONE_MINUS_SRC1_ALPHA = 0x88FB
+ MAX_DUAL_SOURCE_DRAW_BUFFERS = 0x88FC
+ VERTEX_ATTRIB_ARRAY_INTEGER = 0x88FD
+ VERTEX_ATTRIB_ARRAY_DIVISOR = 0x88FE
+ MAX_ARRAY_TEXTURE_LAYERS = 0x88FF
+ MIN_PROGRAM_TEXEL_OFFSET = 0x8904
+ MAX_PROGRAM_TEXEL_OFFSET = 0x8905
+ SAMPLES_PASSED = 0x8914
+ GEOMETRY_VERTICES_OUT = 0x8916
+ GEOMETRY_INPUT_TYPE = 0x8917
+ GEOMETRY_OUTPUT_TYPE = 0x8918
+ SAMPLER_BINDING = 0x8919
+ CLAMP_VERTEX_COLOR = 0x891A
+ CLAMP_FRAGMENT_COLOR = 0x891B
+ CLAMP_READ_COLOR = 0x891C
+ FIXED_ONLY = 0x891D
+ UNIFORM_BUFFER = 0x8A11
+ UNIFORM_BUFFER_BINDING = 0x8A28
+ UNIFORM_BUFFER_START = 0x8A29
+ UNIFORM_BUFFER_SIZE = 0x8A2A
+ MAX_VERTEX_UNIFORM_BLOCKS = 0x8A2B
+ MAX_GEOMETRY_UNIFORM_BLOCKS = 0x8A2C
+ MAX_FRAGMENT_UNIFORM_BLOCKS = 0x8A2D
+ MAX_COMBINED_UNIFORM_BLOCKS = 0x8A2E
+ MAX_UNIFORM_BUFFER_BINDINGS = 0x8A2F
+ MAX_UNIFORM_BLOCK_SIZE = 0x8A30
+ MAX_COMBINED_VERTEX_UNIFORM_COMPONENTS = 0x8A31
+ MAX_COMBINED_GEOMETRY_UNIFORM_COMPONENTS = 0x8A32
+ MAX_COMBINED_FRAGMENT_UNIFORM_COMPONENTS = 0x8A33
+ UNIFORM_BUFFER_OFFSET_ALIGNMENT = 0x8A34
+ ACTIVE_UNIFORM_BLOCK_MAX_NAME_LENGTH = 0x8A35
+ ACTIVE_UNIFORM_BLOCKS = 0x8A36
+ UNIFORM_TYPE = 0x8A37
+ UNIFORM_SIZE = 0x8A38
+ UNIFORM_NAME_LENGTH = 0x8A39
+ UNIFORM_BLOCK_INDEX = 0x8A3A
+ UNIFORM_OFFSET = 0x8A3B
+ UNIFORM_ARRAY_STRIDE = 0x8A3C
+ UNIFORM_MATRIX_STRIDE = 0x8A3D
+ UNIFORM_IS_ROW_MAJOR = 0x8A3E
+ UNIFORM_BLOCK_BINDING = 0x8A3F
+ UNIFORM_BLOCK_DATA_SIZE = 0x8A40
+ UNIFORM_BLOCK_NAME_LENGTH = 0x8A41
+ UNIFORM_BLOCK_ACTIVE_UNIFORMS = 0x8A42
+ UNIFORM_BLOCK_ACTIVE_UNIFORM_INDICES = 0x8A43
+ UNIFORM_BLOCK_REFERENCED_BY_VERTEX_SHADER = 0x8A44
+ UNIFORM_BLOCK_REFERENCED_BY_GEOMETRY_SHADER = 0x8A45
+ UNIFORM_BLOCK_REFERENCED_BY_FRAGMENT_SHADER = 0x8A46
+ FRAGMENT_SHADER = 0x8B30
+ VERTEX_SHADER = 0x8B31
+ MAX_FRAGMENT_UNIFORM_COMPONENTS = 0x8B49
+ MAX_VERTEX_UNIFORM_COMPONENTS = 0x8B4A
+ MAX_VARYING_FLOATS = 0x8B4B
+ MAX_VARYING_COMPONENTS = 0x8B4B
+ MAX_VERTEX_TEXTURE_IMAGE_UNITS = 0x8B4C
+ MAX_COMBINED_TEXTURE_IMAGE_UNITS = 0x8B4D
+ SHADER_TYPE = 0x8B4F
+ FLOAT_VEC2 = 0x8B50
+ FLOAT_VEC3 = 0x8B51
+ FLOAT_VEC4 = 0x8B52
+ INT_VEC2 = 0x8B53
+ INT_VEC3 = 0x8B54
+ INT_VEC4 = 0x8B55
+ BOOL = 0x8B56
+ BOOL_VEC2 = 0x8B57
+ BOOL_VEC3 = 0x8B58
+ BOOL_VEC4 = 0x8B59
+ FLOAT_MAT2 = 0x8B5A
+ FLOAT_MAT3 = 0x8B5B
+ FLOAT_MAT4 = 0x8B5C
+ SAMPLER_1D = 0x8B5D
+ SAMPLER_2D = 0x8B5E
+ SAMPLER_3D = 0x8B5F
+ SAMPLER_CUBE = 0x8B60
+ SAMPLER_1D_SHADOW = 0x8B61
+ SAMPLER_2D_SHADOW = 0x8B62
+ SAMPLER_2D_RECT = 0x8B63
+ SAMPLER_2D_RECT_SHADOW = 0x8B64
+ FLOAT_MAT2x3 = 0x8B65
+ FLOAT_MAT2x4 = 0x8B66
+ FLOAT_MAT3x2 = 0x8B67
+ FLOAT_MAT3x4 = 0x8B68
+ FLOAT_MAT4x2 = 0x8B69
+ FLOAT_MAT4x3 = 0x8B6A
+ DELETE_STATUS = 0x8B80
+ COMPILE_STATUS = 0x8B81
+ LINK_STATUS = 0x8B82
+ VALIDATE_STATUS = 0x8B83
+ INFO_LOG_LENGTH = 0x8B84
+ ATTACHED_SHADERS = 0x8B85
+ ACTIVE_UNIFORMS = 0x8B86
+ ACTIVE_UNIFORM_MAX_LENGTH = 0x8B87
+ SHADER_SOURCE_LENGTH = 0x8B88
+ ACTIVE_ATTRIBUTES = 0x8B89
+ ACTIVE_ATTRIBUTE_MAX_LENGTH = 0x8B8A
+ SHADING_LANGUAGE_VERSION = 0x8B8C
+ CURRENT_PROGRAM = 0x8B8D
+ TEXTURE_RED_TYPE = 0x8C10
+ TEXTURE_GREEN_TYPE = 0x8C11
+ TEXTURE_BLUE_TYPE = 0x8C12
+ TEXTURE_ALPHA_TYPE = 0x8C13
+ TEXTURE_DEPTH_TYPE = 0x8C16
+ UNSIGNED_NORMALIZED = 0x8C17
+ TEXTURE_1D_ARRAY = 0x8C18
+ PROXY_TEXTURE_1D_ARRAY = 0x8C19
+ TEXTURE_2D_ARRAY = 0x8C1A
+ PROXY_TEXTURE_2D_ARRAY = 0x8C1B
+ TEXTURE_BINDING_1D_ARRAY = 0x8C1C
+ TEXTURE_BINDING_2D_ARRAY = 0x8C1D
+ MAX_GEOMETRY_TEXTURE_IMAGE_UNITS = 0x8C29
+ TEXTURE_BUFFER = 0x8C2A
+ MAX_TEXTURE_BUFFER_SIZE = 0x8C2B
+ TEXTURE_BINDING_BUFFER = 0x8C2C
+ TEXTURE_BUFFER_DATA_STORE_BINDING = 0x8C2D
+ ANY_SAMPLES_PASSED = 0x8C2F
+ R11F_G11F_B10F = 0x8C3A
+ UNSIGNED_INT_10F_11F_11F_REV = 0x8C3B
+ RGB9_E5 = 0x8C3D
+ UNSIGNED_INT_5_9_9_9_REV = 0x8C3E
+ TEXTURE_SHARED_SIZE = 0x8C3F
+ SRGB = 0x8C40
+ SRGB8 = 0x8C41
+ SRGB_ALPHA = 0x8C42
+ SRGB8_ALPHA8 = 0x8C43
+ SLUMINANCE_ALPHA = 0x8C44
+ SLUMINANCE8_ALPHA8 = 0x8C45
+ SLUMINANCE = 0x8C46
+ SLUMINANCE8 = 0x8C47
+ COMPRESSED_SRGB = 0x8C48
+ COMPRESSED_SRGB_ALPHA = 0x8C49
+ COMPRESSED_SLUMINANCE = 0x8C4A
+ COMPRESSED_SLUMINANCE_ALPHA = 0x8C4B
+ TRANSFORM_FEEDBACK_VARYING_MAX_LENGTH = 0x8C76
+ TRANSFORM_FEEDBACK_BUFFER_MODE = 0x8C7F
+ MAX_TRANSFORM_FEEDBACK_SEPARATE_COMPONENTS = 0x8C80
+ TRANSFORM_FEEDBACK_VARYINGS = 0x8C83
+ TRANSFORM_FEEDBACK_BUFFER_START = 0x8C84
+ TRANSFORM_FEEDBACK_BUFFER_SIZE = 0x8C85
+ PRIMITIVES_GENERATED = 0x8C87
+ TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN = 0x8C88
+ RASTERIZER_DISCARD = 0x8C89
+ MAX_TRANSFORM_FEEDBACK_INTERLEAVED_COMPONENTS = 0x8C8A
+ MAX_TRANSFORM_FEEDBACK_SEPARATE_ATTRIBS = 0x8C8B
+ INTERLEAVED_ATTRIBS = 0x8C8C
+ SEPARATE_ATTRIBS = 0x8C8D
+ TRANSFORM_FEEDBACK_BUFFER = 0x8C8E
+ TRANSFORM_FEEDBACK_BUFFER_BINDING = 0x8C8F
+ POINT_SPRITE_COORD_ORIGIN = 0x8CA0
+ LOWER_LEFT = 0x8CA1
+ UPPER_LEFT = 0x8CA2
+ STENCIL_BACK_REF = 0x8CA3
+ STENCIL_BACK_VALUE_MASK = 0x8CA4
+ STENCIL_BACK_WRITEMASK = 0x8CA5
+ DRAW_FRAMEBUFFER_BINDING = 0x8CA6
+ FRAMEBUFFER_BINDING = 0x8CA6
+ RENDERBUFFER_BINDING = 0x8CA7
+ READ_FRAMEBUFFER = 0x8CA8
+ DRAW_FRAMEBUFFER = 0x8CA9
+ READ_FRAMEBUFFER_BINDING = 0x8CAA
+ RENDERBUFFER_SAMPLES = 0x8CAB
+ DEPTH_COMPONENT32F = 0x8CAC
+ DEPTH32F_STENCIL8 = 0x8CAD
+ FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE = 0x8CD0
+ FRAMEBUFFER_ATTACHMENT_OBJECT_NAME = 0x8CD1
+ FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL = 0x8CD2
+ FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE = 0x8CD3
+ FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER = 0x8CD4
+ FRAMEBUFFER_COMPLETE = 0x8CD5
+ FRAMEBUFFER_INCOMPLETE_ATTACHMENT = 0x8CD6
+ FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT = 0x8CD7
+ FRAMEBUFFER_INCOMPLETE_DRAW_BUFFER = 0x8CDB
+ FRAMEBUFFER_INCOMPLETE_READ_BUFFER = 0x8CDC
+ FRAMEBUFFER_UNSUPPORTED = 0x8CDD
+ MAX_COLOR_ATTACHMENTS = 0x8CDF
+ COLOR_ATTACHMENT0 = 0x8CE0
+ COLOR_ATTACHMENT1 = 0x8CE1
+ COLOR_ATTACHMENT2 = 0x8CE2
+ COLOR_ATTACHMENT3 = 0x8CE3
+ COLOR_ATTACHMENT4 = 0x8CE4
+ COLOR_ATTACHMENT5 = 0x8CE5
+ COLOR_ATTACHMENT6 = 0x8CE6
+ COLOR_ATTACHMENT7 = 0x8CE7
+ COLOR_ATTACHMENT8 = 0x8CE8
+ COLOR_ATTACHMENT9 = 0x8CE9
+ COLOR_ATTACHMENT10 = 0x8CEA
+ COLOR_ATTACHMENT11 = 0x8CEB
+ COLOR_ATTACHMENT12 = 0x8CEC
+ COLOR_ATTACHMENT13 = 0x8CED
+ COLOR_ATTACHMENT14 = 0x8CEE
+ COLOR_ATTACHMENT15 = 0x8CEF
+ DEPTH_ATTACHMENT = 0x8D00
+ STENCIL_ATTACHMENT = 0x8D20
+ FRAMEBUFFER = 0x8D40
+ RENDERBUFFER = 0x8D41
+ RENDERBUFFER_WIDTH = 0x8D42
+ RENDERBUFFER_HEIGHT = 0x8D43
+ RENDERBUFFER_INTERNAL_FORMAT = 0x8D44
+ STENCIL_INDEX1 = 0x8D46
+ STENCIL_INDEX4 = 0x8D47
+ STENCIL_INDEX8 = 0x8D48
+ STENCIL_INDEX16 = 0x8D49
+ RENDERBUFFER_RED_SIZE = 0x8D50
+ RENDERBUFFER_GREEN_SIZE = 0x8D51
+ RENDERBUFFER_BLUE_SIZE = 0x8D52
+ RENDERBUFFER_ALPHA_SIZE = 0x8D53
+ RENDERBUFFER_DEPTH_SIZE = 0x8D54
+ RENDERBUFFER_STENCIL_SIZE = 0x8D55
+ FRAMEBUFFER_INCOMPLETE_MULTISAMPLE = 0x8D56
+ MAX_SAMPLES = 0x8D57
+ RGBA32UI = 0x8D70
+ RGB32UI = 0x8D71
+ RGBA16UI = 0x8D76
+ RGB16UI = 0x8D77
+ RGBA8UI = 0x8D7C
+ RGB8UI = 0x8D7D
+ RGBA32I = 0x8D82
+ RGB32I = 0x8D83
+ RGBA16I = 0x8D88
+ RGB16I = 0x8D89
+ RGBA8I = 0x8D8E
+ RGB8I = 0x8D8F
+ RED_INTEGER = 0x8D94
+ GREEN_INTEGER = 0x8D95
+ BLUE_INTEGER = 0x8D96
+ ALPHA_INTEGER = 0x8D97
+ RGB_INTEGER = 0x8D98
+ RGBA_INTEGER = 0x8D99
+ BGR_INTEGER = 0x8D9A
+ BGRA_INTEGER = 0x8D9B
+ INT_2_10_10_10_REV = 0x8D9F
+ FRAMEBUFFER_ATTACHMENT_LAYERED = 0x8DA7
+ FRAMEBUFFER_INCOMPLETE_LAYER_TARGETS = 0x8DA8
+ FLOAT_32_UNSIGNED_INT_24_8_REV = 0x8DAD
+ FRAMEBUFFER_SRGB = 0x8DB9
+ COMPRESSED_RED_RGTC1 = 0x8DBB
+ COMPRESSED_SIGNED_RED_RGTC1 = 0x8DBC
+ COMPRESSED_RG_RGTC2 = 0x8DBD
+ COMPRESSED_SIGNED_RG_RGTC2 = 0x8DBE
+ SAMPLER_1D_ARRAY = 0x8DC0
+ SAMPLER_2D_ARRAY = 0x8DC1
+ SAMPLER_BUFFER = 0x8DC2
+ SAMPLER_1D_ARRAY_SHADOW = 0x8DC3
+ SAMPLER_2D_ARRAY_SHADOW = 0x8DC4
+ SAMPLER_CUBE_SHADOW = 0x8DC5
+ UNSIGNED_INT_VEC2 = 0x8DC6
+ UNSIGNED_INT_VEC3 = 0x8DC7
+ UNSIGNED_INT_VEC4 = 0x8DC8
+ INT_SAMPLER_1D = 0x8DC9
+ INT_SAMPLER_2D = 0x8DCA
+ INT_SAMPLER_3D = 0x8DCB
+ INT_SAMPLER_CUBE = 0x8DCC
+ INT_SAMPLER_2D_RECT = 0x8DCD
+ INT_SAMPLER_1D_ARRAY = 0x8DCE
+ INT_SAMPLER_2D_ARRAY = 0x8DCF
+ INT_SAMPLER_BUFFER = 0x8DD0
+ UNSIGNED_INT_SAMPLER_1D = 0x8DD1
+ UNSIGNED_INT_SAMPLER_2D = 0x8DD2
+ UNSIGNED_INT_SAMPLER_3D = 0x8DD3
+ UNSIGNED_INT_SAMPLER_CUBE = 0x8DD4
+ UNSIGNED_INT_SAMPLER_2D_RECT = 0x8DD5
+ UNSIGNED_INT_SAMPLER_1D_ARRAY = 0x8DD6
+ UNSIGNED_INT_SAMPLER_2D_ARRAY = 0x8DD7
+ UNSIGNED_INT_SAMPLER_BUFFER = 0x8DD8
+ GEOMETRY_SHADER = 0x8DD9
+ MAX_GEOMETRY_UNIFORM_COMPONENTS = 0x8DDF
+ MAX_GEOMETRY_OUTPUT_VERTICES = 0x8DE0
+ MAX_GEOMETRY_TOTAL_OUTPUT_COMPONENTS = 0x8DE1
+ QUERY_WAIT = 0x8E13
+ QUERY_NO_WAIT = 0x8E14
+ QUERY_BY_REGION_WAIT = 0x8E15
+ QUERY_BY_REGION_NO_WAIT = 0x8E16
+ TIMESTAMP = 0x8E28
+ TEXTURE_SWIZZLE_R = 0x8E42
+ TEXTURE_SWIZZLE_G = 0x8E43
+ TEXTURE_SWIZZLE_B = 0x8E44
+ TEXTURE_SWIZZLE_A = 0x8E45
+ TEXTURE_SWIZZLE_RGBA = 0x8E46
+ QUADS_FOLLOW_PROVOKING_VERTEX_CONVENTION = 0x8E4C
+ FIRST_VERTEX_CONVENTION = 0x8E4D
+ LAST_VERTEX_CONVENTION = 0x8E4E
+ PROVOKING_VERTEX = 0x8E4F
+ SAMPLE_POSITION = 0x8E50
+ SAMPLE_MASK = 0x8E51
+ SAMPLE_MASK_VALUE = 0x8E52
+ MAX_SAMPLE_MASK_WORDS = 0x8E59
+ COPY_READ_BUFFER = 0x8F36
+ COPY_WRITE_BUFFER = 0x8F37
+ R8_SNORM = 0x8F94
+ RG8_SNORM = 0x8F95
+ RGB8_SNORM = 0x8F96
+ RGBA8_SNORM = 0x8F97
+ R16_SNORM = 0x8F98
+ RG16_SNORM = 0x8F99
+ RGB16_SNORM = 0x8F9A
+ RGBA16_SNORM = 0x8F9B
+ SIGNED_NORMALIZED = 0x8F9C
+ PRIMITIVE_RESTART = 0x8F9D
+ PRIMITIVE_RESTART_INDEX = 0x8F9E
+ RGB10_A2UI = 0x906F
+ TEXTURE_2D_MULTISAMPLE = 0x9100
+ PROXY_TEXTURE_2D_MULTISAMPLE = 0x9101
+ TEXTURE_2D_MULTISAMPLE_ARRAY = 0x9102
+ PROXY_TEXTURE_2D_MULTISAMPLE_ARRAY = 0x9103
+ TEXTURE_BINDING_2D_MULTISAMPLE = 0x9104
+ TEXTURE_BINDING_2D_MULTISAMPLE_ARRAY = 0x9105
+ TEXTURE_SAMPLES = 0x9106
+ TEXTURE_FIXED_SAMPLE_LOCATIONS = 0x9107
+ SAMPLER_2D_MULTISAMPLE = 0x9108
+ INT_SAMPLER_2D_MULTISAMPLE = 0x9109
+ UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE = 0x910A
+ SAMPLER_2D_MULTISAMPLE_ARRAY = 0x910B
+ INT_SAMPLER_2D_MULTISAMPLE_ARRAY = 0x910C
+ UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE_ARRAY = 0x910D
+ MAX_COLOR_TEXTURE_SAMPLES = 0x910E
+ MAX_DEPTH_TEXTURE_SAMPLES = 0x910F
+ MAX_INTEGER_SAMPLES = 0x9110
+ MAX_SERVER_WAIT_TIMEOUT = 0x9111
+ OBJECT_TYPE = 0x9112
+ SYNC_CONDITION = 0x9113
+ SYNC_STATUS = 0x9114
+ SYNC_FLAGS = 0x9115
+ SYNC_FENCE = 0x9116
+ SYNC_GPU_COMMANDS_COMPLETE = 0x9117
+ UNSIGNALED = 0x9118
+ SIGNALED = 0x9119
+ ALREADY_SIGNALED = 0x911A
+ TIMEOUT_EXPIRED = 0x911B
+ CONDITION_SATISFIED = 0x911C
+ WAIT_FAILED = 0x911D
+ BUFFER_ACCESS_FLAGS = 0x911F
+ BUFFER_MAP_LENGTH = 0x9120
+ BUFFER_MAP_OFFSET = 0x9121
+ MAX_VERTEX_OUTPUT_COMPONENTS = 0x9122
+ MAX_GEOMETRY_INPUT_COMPONENTS = 0x9123
+ MAX_GEOMETRY_OUTPUT_COMPONENTS = 0x9124
+ MAX_FRAGMENT_INPUT_COMPONENTS = 0x9125
+ CONTEXT_PROFILE_MASK = 0x9126
+)
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glViewport.xml
+func (gl *GL) Viewport(x, y, width, height int) {
+ C.gl3_3core_glViewport(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// DepthRange specifies the mapping of depth values from normalized device
+// coordinates to window coordinates.
+//
+// Parameter nearVal specifies the mapping of the near clipping plane to window
+// coordinates (defaults to 0), while farVal specifies the mapping of the far
+// clipping plane to window coordinates (defaults to 1).
+//
+// After clipping and division by w, depth coordinates range from -1 to 1,
+// corresponding to the near and far clipping planes. DepthRange specifies a
+// linear mapping of the normalized depth coordinates in this range to window
+// depth coordinates. Regardless of the actual depth buffer implementation,
+// window coordinate depth values are treated as though they range from 0 through 1
+// (like color components). Thus, the values accepted by DepthRange are both
+// clamped to this range before they are accepted.
+//
+// The default setting of (0, 1) maps the near plane to 0 and the far plane to 1.
+// With this mapping, the depth buffer range is fully utilized.
+//
+// It is not necessary that nearVal be less than farVal. Reverse mappings such as
+// nearVal 1, and farVal 0 are acceptable.
+//
+// GL.INVALID_OPERATION is generated if DepthRange is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) DepthRange(nearVal, farVal float64) {
+ C.gl3_3core_glDepthRange(gl.funcs, C.GLdouble(nearVal), C.GLdouble(farVal))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsEnabled.xml
+func (gl *GL) IsEnabled(cap glbase.Enum) bool {
+ glresult := C.gl3_3core_glIsEnabled(gl.funcs, C.GLenum(cap))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTexLevelParameteriv.xml
+func (gl *GL) GetTexLevelParameteriv(target glbase.Enum, level int, pname glbase.Enum, params []int32) {
+ C.gl3_3core_glGetTexLevelParameteriv(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTexLevelParameterfv.xml
+func (gl *GL) GetTexLevelParameterfv(target glbase.Enum, level int, pname glbase.Enum, params []float32) {
+ C.gl3_3core_glGetTexLevelParameterfv(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTexParameteriv.xml
+func (gl *GL) GetTexParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl3_3core_glGetTexParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTexParameterfv.xml
+func (gl *GL) GetTexParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl3_3core_glGetTexParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTexImage.xml
+func (gl *GL) GetTexImage(target glbase.Enum, level int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3core_glGetTexImage(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetIntegerv.xml
+func (gl *GL) GetIntegerv(pname glbase.Enum, params []int32) {
+ C.gl3_3core_glGetIntegerv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetFloatv.xml
+func (gl *GL) GetFloatv(pname glbase.Enum, params []float32) {
+ C.gl3_3core_glGetFloatv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetError.xml
+func (gl *GL) GetError() glbase.Enum {
+ glresult := C.gl3_3core_glGetError(gl.funcs)
+ return glbase.Enum(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetDoublev.xml
+func (gl *GL) GetDoublev(pname glbase.Enum, params []float64) {
+ C.gl3_3core_glGetDoublev(gl.funcs, C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetBooleanv.xml
+func (gl *GL) GetBooleanv(pname glbase.Enum, params []bool) {
+ C.gl3_3core_glGetBooleanv(gl.funcs, C.GLenum(pname), (*C.GLboolean)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glReadPixels.xml
+func (gl *GL) ReadPixels(x, y, width, height int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3core_glReadPixels(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glReadBuffer.xml
+func (gl *GL) ReadBuffer(mode glbase.Enum) {
+ C.gl3_3core_glReadBuffer(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPixelStorei.xml
+func (gl *GL) PixelStorei(pname glbase.Enum, param int32) {
+ C.gl3_3core_glPixelStorei(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPixelStoref.xml
+func (gl *GL) PixelStoref(pname glbase.Enum, param float32) {
+ C.gl3_3core_glPixelStoref(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDepthFunc.xml
+func (gl *GL) DepthFunc(glfunc glbase.Enum) {
+ C.gl3_3core_glDepthFunc(gl.funcs, C.GLenum(glfunc))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glStencilOp.xml
+func (gl *GL) StencilOp(fail, zfail, zpass glbase.Enum) {
+ C.gl3_3core_glStencilOp(gl.funcs, C.GLenum(fail), C.GLenum(zfail), C.GLenum(zpass))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glStencilFunc.xml
+func (gl *GL) StencilFunc(glfunc glbase.Enum, ref int32, mask uint32) {
+ C.gl3_3core_glStencilFunc(gl.funcs, C.GLenum(glfunc), C.GLint(ref), C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glLogicOp.xml
+func (gl *GL) LogicOp(opcode glbase.Enum) {
+ C.gl3_3core_glLogicOp(gl.funcs, C.GLenum(opcode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBlendFunc.xml
+func (gl *GL) BlendFunc(sfactor, dfactor glbase.Enum) {
+ C.gl3_3core_glBlendFunc(gl.funcs, C.GLenum(sfactor), C.GLenum(dfactor))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFlush.xml
+func (gl *GL) Flush() {
+ C.gl3_3core_glFlush(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFinish.xml
+func (gl *GL) Finish() {
+ C.gl3_3core_glFinish(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEnable.xml
+func (gl *GL) Enable(cap glbase.Enum) {
+ C.gl3_3core_glEnable(gl.funcs, C.GLenum(cap))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDisable.xml
+func (gl *GL) Disable(cap glbase.Enum) {
+ C.gl3_3core_glDisable(gl.funcs, C.GLenum(cap))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDepthMask.xml
+func (gl *GL) DepthMask(flag bool) {
+ C.gl3_3core_glDepthMask(gl.funcs, *(*C.GLboolean)(unsafe.Pointer(&flag)))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColorMask.xml
+func (gl *GL) ColorMask(red, green, blue, alpha bool) {
+ C.gl3_3core_glColorMask(gl.funcs, *(*C.GLboolean)(unsafe.Pointer(&red)), *(*C.GLboolean)(unsafe.Pointer(&green)), *(*C.GLboolean)(unsafe.Pointer(&blue)), *(*C.GLboolean)(unsafe.Pointer(&alpha)))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glStencilMask.xml
+func (gl *GL) StencilMask(mask uint32) {
+ C.gl3_3core_glStencilMask(gl.funcs, C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClearDepth.xml
+func (gl *GL) ClearDepth(depth float64) {
+ C.gl3_3core_glClearDepth(gl.funcs, C.GLdouble(depth))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClearStencil.xml
+func (gl *GL) ClearStencil(s int32) {
+ C.gl3_3core_glClearStencil(gl.funcs, C.GLint(s))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClearColor.xml
+func (gl *GL) ClearColor(red, green, blue, alpha float32) {
+ C.gl3_3core_glClearColor(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClear.xml
+func (gl *GL) Clear(mask glbase.Bitfield) {
+ C.gl3_3core_glClear(gl.funcs, C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDrawBuffer.xml
+func (gl *GL) DrawBuffer(mode glbase.Enum) {
+ C.gl3_3core_glDrawBuffer(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexImage2D.xml
+func (gl *GL) TexImage2D(target glbase.Enum, level int, internalFormat int32, width, height, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3core_glTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexImage1D.xml
+func (gl *GL) TexImage1D(target glbase.Enum, level int, internalFormat int32, width, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3core_glTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexParameteriv.xml
+func (gl *GL) TexParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl3_3core_glTexParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexParameteri.xml
+func (gl *GL) TexParameteri(target, pname glbase.Enum, param int32) {
+ C.gl3_3core_glTexParameteri(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexParameterfv.xml
+func (gl *GL) TexParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl3_3core_glTexParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexParameterf.xml
+func (gl *GL) TexParameterf(target, pname glbase.Enum, param float32) {
+ C.gl3_3core_glTexParameterf(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glScissor.xml
+func (gl *GL) Scissor(x, y, width, height int) {
+ C.gl3_3core_glScissor(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPolygonMode.xml
+func (gl *GL) PolygonMode(face, mode glbase.Enum) {
+ C.gl3_3core_glPolygonMode(gl.funcs, C.GLenum(face), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPointSize.xml
+func (gl *GL) PointSize(size float32) {
+ C.gl3_3core_glPointSize(gl.funcs, C.GLfloat(size))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glLineWidth.xml
+func (gl *GL) LineWidth(width float32) {
+ C.gl3_3core_glLineWidth(gl.funcs, C.GLfloat(width))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glHint.xml
+func (gl *GL) Hint(target, mode glbase.Enum) {
+ C.gl3_3core_glHint(gl.funcs, C.GLenum(target), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFrontFace.xml
+func (gl *GL) FrontFace(mode glbase.Enum) {
+ C.gl3_3core_glFrontFace(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCullFace.xml
+func (gl *GL) CullFace(mode glbase.Enum) {
+ C.gl3_3core_glCullFace(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIndexubv.xml
+func (gl *GL) Indexubv(c []uint8) {
+ C.gl3_3core_glIndexubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIndexub.xml
+func (gl *GL) Indexub(c uint8) {
+ C.gl3_3core_glIndexub(gl.funcs, C.GLubyte(c))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsTexture.xml
+func (gl *GL) IsTexture(texture glbase.Texture) bool {
+ glresult := C.gl3_3core_glIsTexture(gl.funcs, C.GLuint(texture))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// GenTextures returns n texture names in textures. There is no guarantee
+// that the names form a contiguous set of integers; however, it is
+// guaranteed that none of the returned names was in use immediately before
+// the call to GenTextures.
+//
+// The generated textures have no dimensionality; they assume the
+// dimensionality of the texture target to which they are first bound (see
+// BindTexture).
+//
+// Texture names returned by a call to GenTextures are not returned by
+// subsequent calls, unless they are first deleted with DeleteTextures.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// GenTextures is available in GL version 2.0 or greater.
+func (gl *GL) GenTextures(n int) []glbase.Texture {
+ if n == 0 {
+ return nil
+ }
+ textures := make([]glbase.Texture, n)
+ C.gl3_3core_glGenTextures(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])))
+ return textures
+}
+
+// DeleteTextures deletes the textures objects whose names are stored
+// in the textures slice. After a texture is deleted, it has no contents or
+// dimensionality, and its name is free for reuse (for example by
+// GenTextures). If a texture that is currently bound is deleted, the binding
+// reverts to 0 (the default texture).
+//
+// DeleteTextures silently ignores 0's and names that do not correspond to
+// existing textures.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// DeleteTextures is available in GL version 2.0 or greater.
+func (gl *GL) DeleteTextures(textures []glbase.Texture) {
+ n := len(textures)
+ if n == 0 {
+ return
+ }
+ C.gl3_3core_glDeleteTextures(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBindTexture.xml
+func (gl *GL) BindTexture(target glbase.Enum, texture glbase.Texture) {
+ C.gl3_3core_glBindTexture(gl.funcs, C.GLenum(target), C.GLuint(texture))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexSubImage2D.xml
+func (gl *GL) TexSubImage2D(target glbase.Enum, level, xoffset, yoffset, width, height int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3core_glTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexSubImage1D.xml
+func (gl *GL) TexSubImage1D(target glbase.Enum, level, xoffset, width int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3core_glTexSubImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLsizei(width), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCopyTexSubImage2D.xml
+func (gl *GL) CopyTexSubImage2D(target glbase.Enum, level, xoffset, yoffset, x, y, width, height int) {
+ C.gl3_3core_glCopyTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCopyTexSubImage1D.xml
+func (gl *GL) CopyTexSubImage1D(target glbase.Enum, level, xoffset, x, y, width int) {
+ C.gl3_3core_glCopyTexSubImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(x), C.GLint(y), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCopyTexImage2D.xml
+func (gl *GL) CopyTexImage2D(target glbase.Enum, level int, internalFormat glbase.Enum, x, y, width, height, border int) {
+ C.gl3_3core_glCopyTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height), C.GLint(border))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCopyTexImage1D.xml
+func (gl *GL) CopyTexImage1D(target glbase.Enum, level int, internalFormat glbase.Enum, x, y, width, border int) {
+ C.gl3_3core_glCopyTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLint(border))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPolygonOffset.xml
+func (gl *GL) PolygonOffset(factor, units float32) {
+ C.gl3_3core_glPolygonOffset(gl.funcs, C.GLfloat(factor), C.GLfloat(units))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDrawElements.xml
+func (gl *GL) DrawElements(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3core_glDrawElements(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDrawArrays.xml
+func (gl *GL) DrawArrays(mode glbase.Enum, first, count int) {
+ C.gl3_3core_glDrawArrays(gl.funcs, C.GLenum(mode), C.GLint(first), C.GLsizei(count))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCopyTexSubImage3D.xml
+func (gl *GL) CopyTexSubImage3D(target glbase.Enum, level, xoffset, yoffset int, zoffset int32, x, y, width, height int) {
+ C.gl3_3core_glCopyTexSubImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(zoffset), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexSubImage3D.xml
+func (gl *GL) TexSubImage3D(target glbase.Enum, level, xoffset, yoffset int, zoffset int32, width, height int, depth int32, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3core_glTexSubImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(zoffset), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexImage3D.xml
+func (gl *GL) TexImage3D(target glbase.Enum, level int, internalFormat int32, width, height int, depth int32, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3core_glTexImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDrawRangeElements.xml
+func (gl *GL) DrawRangeElements(mode glbase.Enum, start, end uint32, count int, gltype glbase.Enum, indices interface{}) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3core_glDrawRangeElements(gl.funcs, C.GLenum(mode), C.GLuint(start), C.GLuint(end), C.GLsizei(count), C.GLenum(gltype), indices_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBlendEquation.xml
+func (gl *GL) BlendEquation(mode glbase.Enum) {
+ C.gl3_3core_glBlendEquation(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBlendColor.xml
+func (gl *GL) BlendColor(red, green, blue, alpha float32) {
+ C.gl3_3core_glBlendColor(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetCompressedTexImage.xml
+func (gl *GL) GetCompressedTexImage(target glbase.Enum, level int, img interface{}) {
+ var img_ptr unsafe.Pointer
+ var img_v = reflect.ValueOf(img)
+ if img != nil && img_v.Kind() != reflect.Slice {
+ panic("parameter img must be a slice")
+ }
+ if img != nil {
+ img_ptr = unsafe.Pointer(img_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3core_glGetCompressedTexImage(gl.funcs, C.GLenum(target), C.GLint(level), img_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCompressedTexSubImage1D.xml
+func (gl *GL) CompressedTexSubImage1D(target glbase.Enum, level, xoffset, width int, format glbase.Enum, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3core_glCompressedTexSubImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLsizei(width), C.GLenum(format), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCompressedTexSubImage2D.xml
+func (gl *GL) CompressedTexSubImage2D(target glbase.Enum, level, xoffset, yoffset, width, height int, format glbase.Enum, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3core_glCompressedTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCompressedTexSubImage3D.xml
+func (gl *GL) CompressedTexSubImage3D(target glbase.Enum, level, xoffset, yoffset int, zoffset int32, width, height int, depth int32, format glbase.Enum, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3core_glCompressedTexSubImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(zoffset), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLenum(format), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCompressedTexImage1D.xml
+func (gl *GL) CompressedTexImage1D(target glbase.Enum, level int, internalFormat glbase.Enum, width, border, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3core_glCompressedTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLsizei(width), C.GLint(border), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCompressedTexImage2D.xml
+func (gl *GL) CompressedTexImage2D(target glbase.Enum, level int, internalFormat glbase.Enum, width, height, border, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3core_glCompressedTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLint(border), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCompressedTexImage3D.xml
+func (gl *GL) CompressedTexImage3D(target glbase.Enum, level int, internalFormat glbase.Enum, width, height int, depth int32, border, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3core_glCompressedTexImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLint(border), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSampleCoverage.xml
+func (gl *GL) SampleCoverage(value float32, invert bool) {
+ C.gl3_3core_glSampleCoverage(gl.funcs, C.GLfloat(value), *(*C.GLboolean)(unsafe.Pointer(&invert)))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glActiveTexture.xml
+func (gl *GL) ActiveTexture(texture glbase.Enum) {
+ C.gl3_3core_glActiveTexture(gl.funcs, C.GLenum(texture))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPointParameteriv.xml
+func (gl *GL) PointParameteriv(pname glbase.Enum, params []int32) {
+ C.gl3_3core_glPointParameteriv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPointParameteri.xml
+func (gl *GL) PointParameteri(pname glbase.Enum, param int32) {
+ C.gl3_3core_glPointParameteri(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPointParameterfv.xml
+func (gl *GL) PointParameterfv(pname glbase.Enum, params []float32) {
+ C.gl3_3core_glPointParameterfv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPointParameterf.xml
+func (gl *GL) PointParameterf(pname glbase.Enum, param float32) {
+ C.gl3_3core_glPointParameterf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiDrawArrays.xml
+func (gl *GL) MultiDrawArrays(mode glbase.Enum, first, count []int, drawcount int32) {
+ C.gl3_3core_glMultiDrawArrays(gl.funcs, C.GLenum(mode), (*C.GLint)(unsafe.Pointer(&first[0])), (*C.GLsizei)(unsafe.Pointer(&count[0])), C.GLsizei(drawcount))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBlendFuncSeparate.xml
+func (gl *GL) BlendFuncSeparate(sfactorRGB, dfactorRGB, sfactorAlpha, dfactorAlpha glbase.Enum) {
+ C.gl3_3core_glBlendFuncSeparate(gl.funcs, C.GLenum(sfactorRGB), C.GLenum(dfactorRGB), C.GLenum(sfactorAlpha), C.GLenum(dfactorAlpha))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetBufferParameteriv.xml
+func (gl *GL) GetBufferParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl3_3core_glGetBufferParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glUnmapBuffer.xml
+func (gl *GL) UnmapBuffer(target glbase.Enum) bool {
+ glresult := C.gl3_3core_glUnmapBuffer(gl.funcs, C.GLenum(target))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetBufferSubData.xml
+func (gl *GL) GetBufferSubData(target glbase.Enum, offset, size int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3core_glGetBufferSubData(gl.funcs, C.GLenum(target), C.GLintptr(offset), C.GLsizeiptr(size), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBufferSubData.xml
+func (gl *GL) BufferSubData(target glbase.Enum, offset, size int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3core_glBufferSubData(gl.funcs, C.GLenum(target), C.GLintptr(offset), C.GLsizeiptr(size), data_ptr)
+}
+
+// BufferData creates a new data store for the buffer object currently
+// bound to target. Any pre-existing data store is deleted. The new data
+// store is created with the specified size in bytes and usage. If data is
+// not nil, it must be a slice that is used to initialize the data store.
+// In that case the size parameter is ignored and the store size will match
+// the slice data size.
+//
+// In its initial state, the new data store is not mapped, it has a NULL
+// mapped pointer, and its mapped access is GL.READ_WRITE.
+//
+// The target constant must be one of GL.ARRAY_BUFFER, GL.COPY_READ_BUFFER,
+// GL.COPY_WRITE_BUFFER, GL.ELEMENT_ARRAY_BUFFER, GL.PIXEL_PACK_BUFFER,
+// GL.PIXEL_UNPACK_BUFFER, GL.TEXTURE_BUFFER, GL.TRANSFORM_FEEDBACK_BUFFER,
+// or GL.UNIFORM_BUFFER.
+//
+// The usage parameter is a hint to the GL implementation as to how a buffer
+// object's data store will be accessed. This enables the GL implementation
+// to make more intelligent decisions that may significantly impact buffer
+// object performance. It does not, however, constrain the actual usage of
+// the data store. usage can be broken down into two parts: first, the
+// frequency of access (modification and usage), and second, the nature of
+// that access.
+//
+// A usage frequency of STREAM and nature of DRAW is specified via the
+// constant GL.STREAM_DRAW, for example.
+//
+// The usage frequency of access may be one of:
+//
+// STREAM
+// The data store contents will be modified once and used at most a few times.
+//
+// STATIC
+// The data store contents will be modified once and used many times.
+//
+// DYNAMIC
+// The data store contents will be modified repeatedly and used many times.
+//
+// The usage nature of access may be one of:
+//
+// DRAW
+// The data store contents are modified by the application, and used as
+// the source for GL drawing and image specification commands.
+//
+// READ
+// The data store contents are modified by reading data from the GL,
+// and used to return that data when queried by the application.
+//
+// COPY
+// The data store contents are modified by reading data from the GL,
+// and used as the source for GL drawing and image specification
+// commands.
+//
+// Clients must align data elements consistent with the requirements of the
+// client platform, with an additional base-level requirement that an offset
+// within a buffer to a datum comprising N bytes be a multiple of N.
+//
+// Error GL.INVALID_ENUM is generated if target is not one of the accepted
+// buffer targets. GL.INVALID_ENUM is generated if usage is not
+// GL.STREAM_DRAW, GL.STREAM_READ, GL.STREAM_COPY, GL.STATIC_DRAW,
+// GL.STATIC_READ, GL.STATIC_COPY, GL.DYNAMIC_DRAW, GL.DYNAMIC_READ, or
+// GL.DYNAMIC_COPY. GL.INVALID_VALUE is generated if size is negative.
+// GL.INVALID_OPERATION is generated if the reserved buffer object name 0 is
+// bound to target. GL.OUT_OF_MEMORY is generated if the GL is unable to
+// create a data store with the specified size.
+func (gl *GL) BufferData(target glbase.Enum, size int, data interface{}, usage glbase.Enum) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ if data != nil {
+ size = int(data_v.Type().Size()) * data_v.Len()
+ }
+ C.gl3_3core_glBufferData(gl.funcs, C.GLenum(target), C.GLsizeiptr(size), data_ptr, C.GLenum(usage))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsBuffer.xml
+func (gl *GL) IsBuffer(buffer glbase.Buffer) bool {
+ glresult := C.gl3_3core_glIsBuffer(gl.funcs, C.GLuint(buffer))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// GenBuffers returns n buffer object names. There is no guarantee that
+// the names form a contiguous set of integers; however, it is guaranteed
+// that none of the returned names was in use immediately before the call to
+// GenBuffers.
+//
+// Buffer object names returned by a call to GenBuffers are not returned by
+// subsequent calls, unless they are first deleted with DeleteBuffers.
+//
+// No buffer objects are associated with the returned buffer object names
+// until they are first bound by calling BindBuffer.
+//
+// Error GL.INVALID_VALUE is generated if n is negative. GL.INVALID_OPERATION
+// is generated if GenBuffers is executed between the execution of Begin
+// and the corresponding execution of End.
+//
+// GenBuffers is available in GL version 1.5 or greater.
+func (gl *GL) GenBuffers(n int) []glbase.Buffer {
+ if n == 0 {
+ return nil
+ }
+ buffers := make([]glbase.Buffer, n)
+ C.gl3_3core_glGenBuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&buffers[0])))
+ return buffers
+}
+
+// DeleteBuffers deletes the buffer objects whose names are stored in the
+// buffers slice.
+//
+// After a buffer object is deleted, it has no contents, and its name is free
+// for reuse (for example by GenBuffers). If a buffer object that is
+// currently bound is deleted, the binding reverts to 0 (the absence of any
+// buffer object, which reverts to client memory usage).
+//
+// DeleteBuffers silently ignores 0's and names that do not correspond to
+// existing buffer objects.
+//
+// Error GL.INVALID_VALUE is generated if n is negative. GL.INVALID_OPERATION
+// is generated if DeleteBuffers is executed between the execution of Begin
+// and the corresponding execution of End.
+//
+// DeleteBuffers is available in GL version 1.5 or greater.
+func (gl *GL) DeleteBuffers(buffers []glbase.Buffer) {
+ n := len(buffers)
+ if n == 0 {
+ return
+ }
+ C.gl3_3core_glDeleteBuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&buffers[0])))
+}
+
+// BindBuffer creates or puts in use a named buffer object.
+// Calling BindBuffer with target set to GL.ARRAY_BUFFER,
+// GL.ELEMENT_ARRAY_BUFFER, GL.PIXEL_PACK_BUFFER or GL.PIXEL_UNPACK_BUFFER
+// and buffer set to the name of the new buffer object binds the buffer
+// object name to the target. When a buffer object is bound to a target, the
+// previous binding for that target is automatically broken.
+//
+// Buffer object names are unsigned integers. The value zero is reserved, but
+// there is no default buffer object for each buffer object target. Instead,
+// buffer set to zero effectively unbinds any buffer object previously bound,
+// and restores client memory usage for that buffer object target. Buffer
+// object names and the corresponding buffer object contents are local to the
+// shared display-list space (see XCreateContext) of the current GL rendering
+// context; two rendering contexts share buffer object names only if they
+// also share display lists.
+//
+// GenBuffers may be called to generate a set of new buffer object names.
+//
+// The state of a buffer object immediately after it is first bound is an
+// unmapped zero-sized memory buffer with GL.READ_WRITE access and
+// GL.STATIC_DRAW usage.
+//
+// While a non-zero buffer object name is bound, GL operations on the target
+// to which it is bound affect the bound buffer object, and queries of the
+// target to which it is bound return state from the bound buffer object.
+// While buffer object name zero is bound, as in the initial state, attempts
+// to modify or query state on the target to which it is bound generates an
+// GL.INVALID_OPERATION error.
+//
+// When vertex array pointer state is changed, for example by a call to
+// NormalPointer, the current buffer object binding (GL.ARRAY_BUFFER_BINDING)
+// is copied into the corresponding client state for the vertex array type
+// being changed, for example GL.NORMAL_ARRAY_BUFFER_BINDING. While a
+// non-zero buffer object is bound to the GL.ARRAY_BUFFER target, the vertex
+// array pointer parameter that is traditionally interpreted as a pointer to
+// client-side memory is instead interpreted as an offset within the buffer
+// object measured in basic machine units.
+//
+// While a non-zero buffer object is bound to the GL.ELEMENT_ARRAY_BUFFER
+// target, the indices parameter of DrawElements, DrawRangeElements, or
+// MultiDrawElements that is traditionally interpreted as a pointer to
+// client-side memory is instead interpreted as an offset within the buffer
+// object measured in basic machine units.
+//
+// While a non-zero buffer object is bound to the GL.PIXEL_PACK_BUFFER
+// target, the following commands are affected: GetCompressedTexImage,
+// GetConvolutionFilter, GetHistogram, GetMinmax, GetPixelMap,
+// GetPolygonStipple, GetSeparableFilter, GetTexImage, and ReadPixels. The
+// pointer parameter that is traditionally interpreted as a pointer to
+// client-side memory where the pixels are to be packed is instead
+// interpreted as an offset within the buffer object measured in basic
+// machine units.
+//
+// While a non-zero buffer object is bound to the GL.PIXEL_UNPACK_BUFFER
+// target, the following commands are affected: Bitmap, ColorSubTable,
+// ColorTable, CompressedTexImage1D, CompressedTexImage2D,
+// CompressedTexImage3D, CompressedTexSubImage1D, CompressedTexSubImage2D,
+// CompressedTexSubImage3D, ConvolutionFilter1D, ConvolutionFilter2D,
+// DrawPixels, PixelMap, PolygonStipple, SeparableFilter2D, TexImage1D,
+// TexImage2D, TexImage3D, TexSubImage1D, TexSubImage2D, and TexSubImage3D.
+// The pointer parameter that is traditionally interpreted as a pointer to
+// client-side memory from which the pixels are to be unpacked is instead
+// interpreted as an offset within the buffer object measured in basic
+// machine units.
+//
+// A buffer object binding created with BindBuffer remains active until a
+// different buffer object name is bound to the same target, or until the
+// bound buffer object is deleted with DeleteBuffers.
+//
+// Once created, a named buffer object may be re-bound to any target as often
+// as needed. However, the GL implementation may make choices about how to
+// optimize the storage of a buffer object based on its initial binding
+// target.
+//
+// Error GL.INVALID_ENUM is generated if target is not one of the allowable
+// values. GL.INVALID_OPERATION is generated if BindBuffer is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// BindBuffer is available in GL version 1.5 or greater.
+func (gl *GL) BindBuffer(target glbase.Enum, buffer glbase.Buffer) {
+ C.gl3_3core_glBindBuffer(gl.funcs, C.GLenum(target), C.GLuint(buffer))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetQueryObjectuiv.xml
+func (gl *GL) GetQueryObjectuiv(id uint32, pname glbase.Enum, params []uint32) {
+ C.gl3_3core_glGetQueryObjectuiv(gl.funcs, C.GLuint(id), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetQueryObjectiv.xml
+func (gl *GL) GetQueryObjectiv(id uint32, pname glbase.Enum, params []int32) {
+ C.gl3_3core_glGetQueryObjectiv(gl.funcs, C.GLuint(id), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetQueryiv.xml
+func (gl *GL) GetQueryiv(target, pname glbase.Enum, params []int32) {
+ C.gl3_3core_glGetQueryiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEndQuery.xml
+func (gl *GL) EndQuery(target glbase.Enum) {
+ C.gl3_3core_glEndQuery(gl.funcs, C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBeginQuery.xml
+func (gl *GL) BeginQuery(target glbase.Enum, id uint32) {
+ C.gl3_3core_glBeginQuery(gl.funcs, C.GLenum(target), C.GLuint(id))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsQuery.xml
+func (gl *GL) IsQuery(id uint32) bool {
+ glresult := C.gl3_3core_glIsQuery(gl.funcs, C.GLuint(id))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDeleteQueries.xml
+func (gl *GL) DeleteQueries(n int, ids []uint32) {
+ C.gl3_3core_glDeleteQueries(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&ids[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGenQueries.xml
+func (gl *GL) GenQueries(n int, ids []uint32) {
+ C.gl3_3core_glGenQueries(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&ids[0])))
+}
+
+// VertexAttribPointer specifies the location and data format of the array
+// of generic vertex attributes at index to use when rendering. size
+// specifies the number of components per attribute and must be 1, 2, 3, or
+// 4. type specifies the data type of each component, and stride specifies
+// the byte stride from one attribute to the next, allowing vertices and
+// attributes to be packed into a single array or stored in separate arrays.
+// normalized indicates whether the values stored in an integer format are
+// to be mapped to the range [-1,1] (for signed values) or [0,1]
+// (for unsigned values) when they are accessed and converted to floating
+// point; otherwise, values will be converted to floats directly without
+// normalization. offset is a byte offset into the buffer object's data
+// store, which must be bound to the GL.ARRAY_BUFFER target with BindBuffer.
+//
+// The buffer object binding (GL.ARRAY_BUFFER_BINDING) is saved as
+// generic vertex attribute array client-side state
+// (GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING) for the provided index.
+//
+// To enable and disable a generic vertex attribute array, call
+// EnableVertexAttribArray and DisableVertexAttribArray with index. If
+// enabled, the generic vertex attribute array is used when DrawArrays or
+// DrawElements is called. Each generic vertex attribute array is initially
+// disabled.
+//
+// VertexAttribPointer is typically implemented on the client side.
+//
+// Error GL.INVALID_ENUM is generated if type is not an accepted value.
+// GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_VALUE is generated if size is not 1, 2,
+// 3, or 4. GL.INVALID_VALUE is generated if stride is negative.
+func (gl *GL) VertexAttribPointer(index glbase.Attrib, size int, gltype glbase.Enum, normalized bool, stride int, offset uintptr) {
+ offset_ptr := unsafe.Pointer(offset)
+ C.gl3_3core_glVertexAttribPointer(gl.funcs, C.GLuint(index), C.GLint(size), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), C.GLsizei(stride), offset_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glValidateProgram.xml
+func (gl *GL) ValidateProgram(program glbase.Program) {
+ C.gl3_3core_glValidateProgram(gl.funcs, C.GLuint(program))
+}
+
+// UniformMatrix4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix4fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(4*4) != 0 {
+ panic("invalid value length for UniformMatrix4fv")
+ }
+ count := len(value) / (4 * 4)
+ C.gl3_3core_glUniformMatrix4fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix3fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(3*3) != 0 {
+ panic("invalid value length for UniformMatrix3fv")
+ }
+ count := len(value) / (3 * 3)
+ C.gl3_3core_glUniformMatrix3fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix2fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(2*2) != 0 {
+ panic("invalid value length for UniformMatrix2fv")
+ }
+ count := len(value) / (2 * 2)
+ C.gl3_3core_glUniformMatrix2fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform4iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%4 != 0 {
+ panic("invalid value length for Uniform4iv")
+ }
+ count := len(value) / 4
+ C.gl3_3core_glUniform4iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform3iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform3iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%3 != 0 {
+ panic("invalid value length for Uniform3iv")
+ }
+ count := len(value) / 3
+ C.gl3_3core_glUniform3iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform2iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform2iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%2 != 0 {
+ panic("invalid value length for Uniform2iv")
+ }
+ count := len(value) / 2
+ C.gl3_3core_glUniform2iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform1iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform1iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ count := len(value)
+ C.gl3_3core_glUniform1iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%4 != 0 {
+ panic("invalid value length for Uniform4fv")
+ }
+ count := len(value) / 4
+ C.gl3_3core_glUniform4fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%3 != 0 {
+ panic("invalid value length for Uniform3fv")
+ }
+ count := len(value) / 3
+ C.gl3_3core_glUniform3fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%2 != 0 {
+ panic("invalid value length for Uniform2fv")
+ }
+ count := len(value) / 2
+ C.gl3_3core_glUniform2fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform1fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform1fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ count := len(value)
+ C.gl3_3core_glUniform1fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform4i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4i(location glbase.Uniform, v0, v1, v2, v3 int32) {
+ C.gl3_3core_glUniform4i(gl.funcs, C.GLint(location), C.GLint(v0), C.GLint(v1), C.GLint(v2), C.GLint(v3))
+}
+
+// Uniform3i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform3i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3i(location glbase.Uniform, v0, v1, v2 int32) {
+ C.gl3_3core_glUniform3i(gl.funcs, C.GLint(location), C.GLint(v0), C.GLint(v1), C.GLint(v2))
+}
+
+// Uniform2i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform2i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2i(location glbase.Uniform, v0, v1 int32) {
+ C.gl3_3core_glUniform2i(gl.funcs, C.GLint(location), C.GLint(v0), C.GLint(v1))
+}
+
+// Uniform1i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform1i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1i(location glbase.Uniform, v0 int32) {
+ C.gl3_3core_glUniform1i(gl.funcs, C.GLint(location), C.GLint(v0))
+}
+
+// Uniform4f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform4f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4f(location glbase.Uniform, v0, v1, v2, v3 float32) {
+ C.gl3_3core_glUniform4f(gl.funcs, C.GLint(location), C.GLfloat(v0), C.GLfloat(v1), C.GLfloat(v2), C.GLfloat(v3))
+}
+
+// Uniform3f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform3f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3f(location glbase.Uniform, v0, v1, v2 float32) {
+ C.gl3_3core_glUniform3f(gl.funcs, C.GLint(location), C.GLfloat(v0), C.GLfloat(v1), C.GLfloat(v2))
+}
+
+// Uniform2f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform2f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2f(location glbase.Uniform, v0, v1 float32) {
+ C.gl3_3core_glUniform2f(gl.funcs, C.GLint(location), C.GLfloat(v0), C.GLfloat(v1))
+}
+
+// Uniform1f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform1f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1f(location glbase.Uniform, v0 float32) {
+ C.gl3_3core_glUniform1f(gl.funcs, C.GLint(location), C.GLfloat(v0))
+}
+
+// UseProgram installs the program object specified by program as part of
+// current rendering state. One or more executables are created in a program
+// object by successfully attaching shader objects to it with AttachShader,
+// successfully compiling the shader objects with CompileShader, and
+// successfully linking the program object with LinkProgram.
+//
+// A program object will contain an executable that will run on the vertex
+// processor if it contains one or more shader objects of type
+// GL.VERTEX_SHADER that have been successfully compiled and linked.
+// Similarly, a program object will contain an executable that will run on
+// the fragment processor if it contains one or more shader objects of type
+// GL.FRAGMENT_SHADER that have been successfully compiled and linked.
+//
+// Successfully installing an executable on a programmable processor will
+// cause the corresponding fixed functionality of OpenGL to be disabled.
+// Specifically, if an executable is installed on the vertex processor, the
+// OpenGL fixed functionality will be disabled as follows.
+//
+// - The modelview matrix is not applied to vertex coordinates.
+//
+// - The projection matrix is not applied to vertex coordinates.
+//
+// - The texture matrices are not applied to texture coordinates.
+//
+// - Normals are not transformed to eye coordinates.
+//
+// - Normals are not rescaled or normalized.
+//
+// - Normalization of GL.AUTO_NORMAL evaluated normals is not performed.
+//
+// - Texture coordinates are not generated automatically.
+//
+// - Per-vertex lighting is not performed.
+//
+// - Color material computations are not performed.
+//
+// - Color index lighting is not performed.
+//
+// - This list also applies when setting the current raster position.
+//
+// The executable that is installed on the vertex processor is expected to
+// implement any or all of the desired functionality from the preceding list.
+// Similarly, if an executable is installed on the fragment processor, the
+// OpenGL fixed functionality will be disabled as follows.
+//
+// - Texture environment and texture functions are not applied.
+//
+// - Texture application is not applied.
+//
+// - Color sum is not applied.
+//
+// - Fog is not applied.
+//
+// Again, the fragment shader that is installed is expected to implement any
+// or all of the desired functionality from the preceding list.
+//
+// While a program object is in use, applications are free to modify attached
+// shader objects, compile attached shader objects, attach additional shader
+// objects, and detach or delete shader objects. None of these operations
+// will affect the executables that are part of the current state. However,
+// relinking the program object that is currently in use will install the
+// program object as part of the current rendering state if the link
+// operation was successful (see LinkProgram). If the program object
+// currently in use is relinked unsuccessfully, its link status will be set
+// to GL.FALSE, but the executables and associated state will remain part of
+// the current state until a subsequent call to UseProgram removes it from
+// use. After it is removed from use, it cannot be made part of current state
+// until it has been successfully relinked.
+//
+// If program contains shader objects of type GL.VERTEX_SHADER but it does
+// not contain shader objects of type GL.FRAGMENT_SHADER, an executable will
+// be installed on the vertex processor, but fixed functionality will be used
+// for fragment processing. Similarly, if program contains shader objects of
+// type GL.FRAGMENT_SHADER but it does not contain shader objects of type
+// GL.VERTEX_SHADER, an executable will be installed on the fragment
+// processor, but fixed functionality will be used for vertex processing. If
+// program is 0, the programmable processors will be disabled, and fixed
+// functionality will be used for both vertex and fragment processing.
+//
+// While a program object is in use, the state that controls the disabled
+// fixed functionality may also be updated using the normal OpenGL calls.
+//
+// Like display lists and texture objects, the name space for program objects
+// may be shared across a set of contexts, as long as the server sides of the
+// contexts share the same address space. If the name space is shared across
+// contexts, any attached objects and the data associated with those attached
+// objects are shared as well.
+//
+// Applications are responsible for providing the synchronization across API
+// calls when objects are accessed from different execution threads.
+//
+// Error GL.INVALID_VALUE is generated if program is neither 0 nor a value
+// generated by OpenGL. GL.INVALID_OPERATION is generated if program is not
+// a program object. GL.INVALID_OPERATION is generated if program could not
+// be made part of current state. GL.INVALID_OPERATION is generated if
+// UseProgram is executed between the execution of Begin and the
+// corresponding execution of End.
+//
+// UseProgram is available in GL version 2.0 or greater.
+func (gl *GL) UseProgram(program glbase.Program) {
+ C.gl3_3core_glUseProgram(gl.funcs, C.GLuint(program))
+}
+
+// ShaderSource sets the source code in shader to the provided source code. Any source
+// code previously stored in the shader object is completely replaced.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader is not a shader
+// object. GL.INVALID_VALUE is generated if count is less than 0.
+// GL.INVALID_OPERATION is generated if ShaderSource is executed between the
+// execution of Begin and the corresponding execution of End.
+//
+// ShaderSource is available in GL version 2.0 or greater.
+func (gl *GL) ShaderSource(shader glbase.Shader, source ...string) {
+ count := len(source)
+ length := make([]int32, count)
+ source_c := make([]unsafe.Pointer, count)
+ for i, src := range source {
+ length[i] = int32(len(src))
+ if len(src) > 0 {
+ source_c[i] = *(*unsafe.Pointer)(unsafe.Pointer(&src))
+ } else {
+ source_c[i] = unsafe.Pointer(uintptr(0))
+ }
+ }
+ C.gl3_3core_glShaderSource(gl.funcs, C.GLuint(shader), C.GLsizei(count), (**C.GLchar)(unsafe.Pointer(&source_c[0])), (*C.GLint)(unsafe.Pointer(&length[0])))
+}
+
+// LinkProgram links the program object specified by program. If any shader
+// objects of type GL.VERTEX_SHADER are attached to program, they will be
+// used to create an executable that will run on the programmable vertex
+// processor. If any shader objects of type GL.FRAGMENT_SHADER are attached
+// to program, they will be used to create an executable that will run on the
+// programmable fragment processor.
+//
+// The status of the link operation will be stored as part of the program
+// object's state. This value will be set to GL.TRUE if the program object
+// was linked without errors and is ready for use, and GL.FALSE otherwise. It
+// can be queried by calling GetProgramiv with arguments program and
+// GL.LINK_STATUS.
+//
+// As a result of a successful link operation, all active user-defined
+// uniform variables belonging to program will be initialized to 0, and each
+// of the program object's active uniform variables will be assigned a
+// location that can be queried by calling GetUniformLocation. Also, any
+// active user-defined attribute variables that have not been bound to a
+// generic vertex attribute index will be bound to one at this time.
+//
+// Linking of a program object can fail for a number of reasons as specified
+// in the OpenGL Shading Language Specification. The following lists some of
+// the conditions that will cause a link error.
+//
+// - The number of active attribute variables supported by the
+// implementation has been exceeded.
+//
+// - The storage limit for uniform variables has been exceeded.
+//
+// - The number of active uniform variables supported by the implementation
+// has been exceeded.
+//
+// - The main function is missing for the vertex shader or the fragment
+// shader.
+//
+// - A varying variable actually used in the fragment shader is not
+// declared in the same way (or is not declared at all) in the vertex
+// shader.
+//
+// - A reference to a function or variable name is unresolved.
+//
+// - A shared global is declared with two different types or two different
+// initial values.
+//
+// - One or more of the attached shader objects has not been successfully
+// compiled.
+//
+// - Binding a generic attribute matrix caused some rows of the matrix to
+// fall outside the allowed maximum of GL.MAX_VERTEX_ATTRIBS.
+//
+// - Not enough contiguous vertex attribute slots could be found to bind
+// attribute matrices.
+//
+// When a program object has been successfully linked, the program object can
+// be made part of current state by calling UseProgram. Whether or not the
+// link operation was successful, the program object's information log will
+// be overwritten. The information log can be retrieved by calling
+// GetProgramInfoLog.
+//
+// LinkProgram will also install the generated executables as part of the
+// current rendering state if the link operation was successful and the
+// specified program object is already currently in use as a result of a
+// previous call to UseProgram. If the program object currently in use is
+// relinked unsuccessfully, its link status will be set to GL.FALSE , but the
+// executables and associated state will remain part of the current state
+// until a subsequent call to UseProgram removes it from use. After it is
+// removed from use, it cannot be made part of current state until it has
+// been successfully relinked.
+//
+// If program contains shader objects of type GL.VERTEX_SHADER but does not
+// contain shader objects of type GL.FRAGMENT_SHADER, the vertex shader will
+// be linked against the implicit interface for fixed functionality fragment
+// processing. Similarly, if program contains shader objects of type
+// GL.FRAGMENT_SHADER but it does not contain shader objects of type
+// GL.VERTEX_SHADER, the fragment shader will be linked against the implicit
+// interface for fixed functionality vertex processing.
+//
+// The program object's information log is updated and the program is
+// generated at the time of the link operation. After the link operation,
+// applications are free to modify attached shader objects, compile attached
+// shader objects, detach shader objects, delete shader objects, and attach
+// additional shader objects. None of these operations affects the
+// information log or the program that is part of the program object.
+//
+// If the link operation is unsuccessful, any information about a previous
+// link operation on program is lost (a failed link does not restore the
+// old state of program). Certain information can still be retrieved
+// from program even after an unsuccessful link operation. See for instance
+// GetActiveAttrib and GetActiveUniform.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program
+// object. GL.INVALID_OPERATION is generated if LinkProgram is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// LinkProgram is available in GL version 2.0 or greater.
+func (gl *GL) LinkProgram(program glbase.Program) {
+ C.gl3_3core_glLinkProgram(gl.funcs, C.GLuint(program))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsShader.xml
+func (gl *GL) IsShader(shader glbase.Shader) bool {
+ glresult := C.gl3_3core_glIsShader(gl.funcs, C.GLuint(shader))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsProgram.xml
+func (gl *GL) IsProgram(program glbase.Program) bool {
+ glresult := C.gl3_3core_glIsProgram(gl.funcs, C.GLuint(program))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// GetVertexAttribiv returns in params the value of a generic vertex attribute
+// parameter. The generic vertex attribute to be queried is specified by
+// index, and the parameter to be queried is specified by pname.
+//
+// The accepted parameter names are as follows:
+//
+// GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING
+// params returns a single value, the name of the buffer object
+// currently bound to the binding point corresponding to generic vertex
+// attribute array index. If no buffer object is bound, 0 is returned.
+// The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_ENABLED
+// params returns a single value that is non-zero (true) if the vertex
+// attribute array for index is enabled and 0 (false) if it is
+// disabled. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_SIZE
+// params returns a single value, the size of the vertex attribute
+// array for index. The size is the number of values for each element
+// of the vertex attribute array, and it will be 1, 2, 3, or 4. The
+// initial value is 4.
+//
+// GL.VERTEX_ATTRIB_ARRAY_STRIDE
+// params returns a single value, the array stride for (number of bytes
+// between successive elements in) the vertex attribute array for
+// index. A value of 0 indicates that the array elements are stored
+// sequentially in memory. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_TYPE
+// params returns a single value, a symbolic constant indicating the
+// array type for the vertex attribute array for index. Possible values
+// are GL.BYTE, GL.UNSIGNED_BYTE, GL.SHORT, GL.UNSIGNED_SHORT, GL.INT,
+// GL.UNSIGNED_INT, GL.FLOAT, and GL.DOUBLE. The initial value is
+// GL.FLOAT.
+//
+// GL.VERTEX_ATTRIB_ARRAY_NORMALIZED
+// params returns a single value that is non-zero (true) if fixed-point
+// data types for the vertex attribute array indicated by index are
+// normalized when they are converted to floating point, and 0 (false)
+// otherwise. The initial value is 0.
+//
+// GL.CURRENT_VERTEX_ATTRIB
+// params returns four values that represent the current value for the
+// generic vertex attribute specified by index. Generic vertex
+// attribute 0 is unique in that it has no current state, so an error
+// will be generated if index is 0. The initial value for all other
+// generic vertex attributes is (0,0,0,1).
+//
+// All of the parameters except GL.CURRENT_VERTEX_ATTRIB represent
+// client-side state.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_ENUM is generated if pname is not an
+// accepted value. GL.INVALID_OPERATION is generated if index is 0 and pname
+// is GL.CURRENT_VERTEX_ATTRIB.
+//
+// GetVertexAttribiv is available in GL version 2.0 or greater.
+func (gl *GL) GetVertexAttribiv(index glbase.Attrib, pname glbase.Enum, params []int32) {
+ var params_c [4]int32
+ C.gl3_3core_glGetVertexAttribiv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetVertexAttribfv returns in params the value of a generic vertex attribute
+// parameter. The generic vertex attribute to be queried is specified by
+// index, and the parameter to be queried is specified by pname.
+//
+// The accepted parameter names are as follows:
+//
+// GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING
+// params returns a single value, the name of the buffer object
+// currently bound to the binding point corresponding to generic vertex
+// attribute array index. If no buffer object is bound, 0 is returned.
+// The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_ENABLED
+// params returns a single value that is non-zero (true) if the vertex
+// attribute array for index is enabled and 0 (false) if it is
+// disabled. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_SIZE
+// params returns a single value, the size of the vertex attribute
+// array for index. The size is the number of values for each element
+// of the vertex attribute array, and it will be 1, 2, 3, or 4. The
+// initial value is 4.
+//
+// GL.VERTEX_ATTRIB_ARRAY_STRIDE
+// params returns a single value, the array stride for (number of bytes
+// between successive elements in) the vertex attribute array for
+// index. A value of 0 indicates that the array elements are stored
+// sequentially in memory. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_TYPE
+// params returns a single value, a symbolic constant indicating the
+// array type for the vertex attribute array for index. Possible values
+// are GL.BYTE, GL.UNSIGNED_BYTE, GL.SHORT, GL.UNSIGNED_SHORT, GL.INT,
+// GL.UNSIGNED_INT, GL.FLOAT, and GL.DOUBLE. The initial value is
+// GL.FLOAT.
+//
+// GL.VERTEX_ATTRIB_ARRAY_NORMALIZED
+// params returns a single value that is non-zero (true) if fixed-point
+// data types for the vertex attribute array indicated by index are
+// normalized when they are converted to floating point, and 0 (false)
+// otherwise. The initial value is 0.
+//
+// GL.CURRENT_VERTEX_ATTRIB
+// params returns four values that represent the current value for the
+// generic vertex attribute specified by index. Generic vertex
+// attribute 0 is unique in that it has no current state, so an error
+// will be generated if index is 0. The initial value for all other
+// generic vertex attributes is (0,0,0,1).
+//
+// All of the parameters except GL.CURRENT_VERTEX_ATTRIB represent
+// client-side state.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_ENUM is generated if pname is not an
+// accepted value. GL.INVALID_OPERATION is generated if index is 0 and pname
+// is GL.CURRENT_VERTEX_ATTRIB.
+//
+// GetVertexAttribfv is available in GL version 2.0 or greater.
+func (gl *GL) GetVertexAttribfv(index glbase.Attrib, pname glbase.Enum, params []float32) {
+ var params_c [4]float32
+ C.gl3_3core_glGetVertexAttribfv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetVertexAttribdv returns in params the value of a generic vertex attribute
+// parameter. The generic vertex attribute to be queried is specified by
+// index, and the parameter to be queried is specified by pname.
+//
+// The accepted parameter names are as follows:
+//
+// GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING
+// params returns a single value, the name of the buffer object
+// currently bound to the binding point corresponding to generic vertex
+// attribute array index. If no buffer object is bound, 0 is returned.
+// The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_ENABLED
+// params returns a single value that is non-zero (true) if the vertex
+// attribute array for index is enabled and 0 (false) if it is
+// disabled. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_SIZE
+// params returns a single value, the size of the vertex attribute
+// array for index. The size is the number of values for each element
+// of the vertex attribute array, and it will be 1, 2, 3, or 4. The
+// initial value is 4.
+//
+// GL.VERTEX_ATTRIB_ARRAY_STRIDE
+// params returns a single value, the array stride for (number of bytes
+// between successive elements in) the vertex attribute array for
+// index. A value of 0 indicates that the array elements are stored
+// sequentially in memory. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_TYPE
+// params returns a single value, a symbolic constant indicating the
+// array type for the vertex attribute array for index. Possible values
+// are GL.BYTE, GL.UNSIGNED_BYTE, GL.SHORT, GL.UNSIGNED_SHORT, GL.INT,
+// GL.UNSIGNED_INT, GL.FLOAT, and GL.DOUBLE. The initial value is
+// GL.FLOAT.
+//
+// GL.VERTEX_ATTRIB_ARRAY_NORMALIZED
+// params returns a single value that is non-zero (true) if fixed-point
+// data types for the vertex attribute array indicated by index are
+// normalized when they are converted to floating point, and 0 (false)
+// otherwise. The initial value is 0.
+//
+// GL.CURRENT_VERTEX_ATTRIB
+// params returns four values that represent the current value for the
+// generic vertex attribute specified by index. Generic vertex
+// attribute 0 is unique in that it has no current state, so an error
+// will be generated if index is 0. The initial value for all other
+// generic vertex attributes is (0,0,0,1).
+//
+// All of the parameters except GL.CURRENT_VERTEX_ATTRIB represent
+// client-side state.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_ENUM is generated if pname is not an
+// accepted value. GL.INVALID_OPERATION is generated if index is 0 and pname
+// is GL.CURRENT_VERTEX_ATTRIB.
+//
+// GetVertexAttribdv is available in GL version 2.0 or greater.
+func (gl *GL) GetVertexAttribdv(index glbase.Attrib, pname glbase.Enum, params []float64) {
+ var params_c [4]float64
+ C.gl3_3core_glGetVertexAttribdv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetUniformiv returns in params the value of the specified uniform
+// variable. The type of the uniform variable specified by location
+// determines the number of values returned. If the uniform variable is
+// defined in the shader as a boolean, int, or float, a single value will be
+// returned. If it is defined as a vec2, ivec2, or bvec2, two values will be
+// returned. If it is defined as a vec3, ivec3, or bvec3, three values will
+// be returned, and so on. To query values stored in uniform variables
+// declared as arrays, call GetUniformiv for each element of the array. To
+// query values stored in uniform variables declared as structures, call
+// GetUniformiv for each field in the structure. The values for uniform
+// variables declared as a matrix will be returned in column major order.
+//
+// The locations assigned to uniform variables are not known until the
+// program object is linked. After linking has occurred, the command
+// GetUniformLocation can be used to obtain the location of a uniform
+// variable. This location value can then be passed to GetUniformiv in order
+// to query the current value of the uniform variable. After a program object
+// has been linked successfully, the index values for uniform variables
+// remain fixed until the next link command occurs. The uniform variable
+// values can only be queried after a link if the link was successful.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program
+// object. GL.INVALID_OPERATION is generated if program has not been
+// successfully linked. GL.INVALID_OPERATION is generated if location does
+// not correspond to a valid uniform variable location for the specified
+// program object. GL.INVALID_OPERATION is generated if GetUniformiv is
+// executed between the execution of Begin and the corresponding execution of
+// End.
+//
+// GetUniformiv is available in GL version 2.0 or greater.
+func (gl *GL) GetUniformiv(program glbase.Program, location glbase.Uniform, params []int32) {
+ var params_c [4]int32
+ C.gl3_3core_glGetUniformiv(gl.funcs, C.GLuint(program), C.GLint(location), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetUniformfv returns in params the value of the specified uniform
+// variable. The type of the uniform variable specified by location
+// determines the number of values returned. If the uniform variable is
+// defined in the shader as a boolean, int, or float, a single value will be
+// returned. If it is defined as a vec2, ivec2, or bvec2, two values will be
+// returned. If it is defined as a vec3, ivec3, or bvec3, three values will
+// be returned, and so on. To query values stored in uniform variables
+// declared as arrays, call GetUniformfv for each element of the array. To
+// query values stored in uniform variables declared as structures, call
+// GetUniformfv for each field in the structure. The values for uniform
+// variables declared as a matrix will be returned in column major order.
+//
+// The locations assigned to uniform variables are not known until the
+// program object is linked. After linking has occurred, the command
+// GetUniformLocation can be used to obtain the location of a uniform
+// variable. This location value can then be passed to GetUniformfv in order
+// to query the current value of the uniform variable. After a program object
+// has been linked successfully, the index values for uniform variables
+// remain fixed until the next link command occurs. The uniform variable
+// values can only be queried after a link if the link was successful.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program
+// object. GL.INVALID_OPERATION is generated if program has not been
+// successfully linked. GL.INVALID_OPERATION is generated if location does
+// not correspond to a valid uniform variable location for the specified
+// program object. GL.INVALID_OPERATION is generated if GetUniformfv is
+// executed between the execution of Begin and the corresponding execution of
+// End.
+//
+// GetUniformfv is available in GL version 2.0 or greater.
+func (gl *GL) GetUniformfv(program glbase.Program, location glbase.Uniform, params []float32) {
+ var params_c [4]float32
+ C.gl3_3core_glGetUniformfv(gl.funcs, C.GLuint(program), C.GLint(location), (*C.GLfloat)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetUniformLocation returns an integer that represents the location of a
+// specific uniform variable within a program object. name must be an active
+// uniform variable name in program that is not a structure, an array of
+// structures, or a subcomponent of a vector or a matrix. This function
+// returns -1 if name does not correspond to an active uniform variable in
+// program or if name starts with the reserved prefix "gl_".
+//
+// Uniform variables that are structures or arrays of structures may be
+// queried by calling GetUniformLocation for each field within the
+// structure. The array element operator "[]" and the structure field
+// operator "." may be used in name in order to select elements within an
+// array or fields within a structure. The result of using these operators is
+// not allowed to be another structure, an array of structures, or a
+// subcomponent of a vector or a matrix. Except if the last part of name
+// indicates a uniform variable array, the location of the first element of
+// an array can be retrieved by using the name of the array, or by using the
+// name appended by "[0]".
+//
+// The actual locations assigned to uniform variables are not known until the
+// program object is linked successfully. After linking has occurred, the
+// command GetUniformLocation can be used to obtain the location of a
+// uniform variable. This location value can then be passed to Uniform to
+// set the value of the uniform variable or to GetUniform in order to query
+// the current value of the uniform variable. After a program object has been
+// linked successfully, the index values for uniform variables remain fixed
+// until the next link command occurs. Uniform variable locations and values
+// can only be queried after a link if the link was successful.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program object.
+// GL.INVALID_OPERATION is generated if program has not been successfully
+// linked. GL.INVALID_OPERATION is generated if GetUniformLocation is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// GetUniformLocation is available in GL version 2.0 or greater.
+func (gl *GL) GetUniformLocation(program glbase.Program, name string) glbase.Uniform {
+ name_cstr := C.CString(name)
+ glresult := C.gl3_3core_glGetUniformLocation(gl.funcs, C.GLuint(program), (*C.GLchar)(name_cstr))
+ C.free(unsafe.Pointer(name_cstr))
+ return glbase.Uniform(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetShaderSource.xml
+func (gl *GL) GetShaderSource(shader glbase.Shader, bufSize int32, length []int32, source []byte) {
+ C.gl3_3core_glGetShaderSource(gl.funcs, C.GLuint(shader), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&source[0])))
+}
+
+// GetShaderInfoLog returns the information log for the specified shader
+// object. The information log for a shader object is modified when the
+// shader is compiled.
+//
+// The information log for a shader object is a string that may contain
+// diagnostic messages, warning messages, and other information about the
+// last compile operation. When a shader object is created, its information
+// log will be a string of length 0, and the size of the current log can be
+// obtained by calling GetShaderiv with the value GL.INFO_LOG_LENGTH.
+//
+// The information log for a shader object is the OpenGL implementer's
+// primary mechanism for conveying information about the compilation process.
+// Therefore, the information log can be helpful to application developers
+// during the development process, even when compilation is successful.
+// Application developers should not expect different OpenGL implementations
+// to produce identical information logs.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader is not a shader
+// object. GL.INVALID_VALUE is generated if maxLength is less than 0.
+// GL.INVALID_OPERATION is generated if GetShaderInfoLog is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// GetShaderInfoLog is available in GL version 2.0 or greater.
+func (gl *GL) GetShaderInfoLog(shader glbase.Shader) []byte {
+ var params [1]int32
+ var length int32
+ gl.GetShaderiv(shader, INFO_LOG_LENGTH, params[:])
+ bufSize := params[0]
+ infoLog := make([]byte, int(bufSize))
+ C.gl3_3core_glGetShaderInfoLog(gl.funcs, C.GLuint(shader), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length)), (*C.GLchar)(unsafe.Pointer(&infoLog[0])))
+ return infoLog
+}
+
+// GetShaderiv GetShader returns in params the value of a parameter for a specific
+// shader object. The following parameters are defined:
+//
+// GL.SHADER_TYPE
+// params returns GL.VERTEX_SHADER if shader is a vertex shader object,
+// and GL.FRAGMENT_SHADER if shader is a fragment shader object.
+//
+// GL.DELETE_STATUS
+// params returns GL.TRUE if shader is currently flagged for deletion,
+// and GL.FALSE otherwise.
+//
+// GL.COMPILE_STATUS
+// params returns GL.TRUE if the last compile operation on shader was
+// successful, and GL.FALSE otherwise.
+//
+// GL.INFO_LOG_LENGTH
+// params returns the number of characters in the information log for
+// shader including the null termination character (the size of the
+// character buffer required to store the information log). If shader has
+// no information log, a value of 0 is returned.
+//
+// GL.SHADER_SOURCE_LENGTH
+// params returns the length of the concatenation of the source strings
+// that make up the shader source for the shader, including the null
+// termination character. (the size of the character buffer
+// required to store the shader source). If no source code exists, 0 is
+// returned.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader does not refer to a
+// shader object. GL.INVALID_ENUM is generated if pname is not an accepted
+// value. GL.INVALID_OPERATION is generated if GetShader is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// GetShaderiv is available in GL version 2.0 or greater.
+func (gl *GL) GetShaderiv(shader glbase.Shader, pname glbase.Enum, params []int32) {
+ var params_c [4]int32
+ C.gl3_3core_glGetShaderiv(gl.funcs, C.GLuint(shader), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetProgramInfoLog returns the information log for the specified program
+// object. The information log for a program object is modified when the
+// program object is linked or validated.
+//
+// The information log for a program object is either an empty string, or a
+// string containing information about the last link operation, or a string
+// containing information about the last validation operation. It may contain
+// diagnostic messages, warning messages, and other information. When a
+// program object is created, its information log will be a string of length
+// 0, and the size of the current log can be obtained by calling GetProgramiv
+// with the value GL.INFO_LOG_LENGTH.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated
+// by OpenGL. GL.INVALID_OPERATION is generated if program is not a
+// program object.
+func (gl *GL) GetProgramInfoLog(program glbase.Program) []byte {
+ var params [1]int32
+ var length int32
+ gl.GetProgramiv(program, INFO_LOG_LENGTH, params[:])
+ bufSize := params[0]
+ infoLog := make([]byte, int(bufSize))
+ C.gl3_3core_glGetProgramInfoLog(gl.funcs, C.GLuint(program), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length)), (*C.GLchar)(unsafe.Pointer(&infoLog[0])))
+ return infoLog
+}
+
+// GetProgramiv returns in params the value of a parameter for a specific
+// program object. The following parameters are defined:
+//
+// GL.DELETE_STATUS
+// params returns GL.TRUE if program is currently flagged for deletion,
+// and GL.FALSE otherwise.
+//
+// GL.LINK_STATUS
+// params returns GL.TRUE if the last link operation on program was
+// successful, and GL.FALSE otherwise.
+//
+// GL.VALIDATE_STATUS
+// params returns GL.TRUE or if the last validation operation on
+// program was successful, and GL.FALSE otherwise.
+//
+// GL.INFO_LOG_LENGTH
+// params returns the number of characters in the information log for
+// program including the null termination character (the size of
+// the character buffer required to store the information log). If
+// program has no information log, a value of 0 is returned.
+//
+// GL.ATTACHED_SHADERS
+// params returns the number of shader objects attached to program.
+//
+// GL.ACTIVE_ATTRIBUTES
+// params returns the number of active attribute variables for program.
+//
+// GL.ACTIVE_ATTRIBUTE_MAX_LENGTH
+// params returns the length of the longest active attribute name for
+// program, including the null termination character (the size of
+// the character buffer required to store the longest attribute name).
+// If no active attributes exist, 0 is returned.
+//
+// GL.ACTIVE_UNIFORMS
+// params returns the number of active uniform variables for program.
+//
+// GL.ACTIVE_UNIFORM_MAX_LENGTH
+// params returns the length of the longest active uniform variable
+// name for program, including the null termination character (i.e.,
+// the size of the character buffer required to store the longest
+// uniform variable name). If no active uniform variables exist, 0 is
+// returned.
+//
+// GL.TRANSFORM_FEEDBACK_BUFFER_MODE
+// params returns a symbolic constant indicating the buffer mode used
+// when transform feedback is active. This may be GL.SEPARATE_ATTRIBS
+// or GL.INTERLEAVED_ATTRIBS.
+//
+// GL.TRANSFORM_FEEDBACK_VARYINGS
+// params returns the number of varying variables to capture in transform
+// feedback mode for the program.
+//
+// GL.TRANSFORM_FEEDBACK_VARYING_MAX_LENGTH
+// params returns the length of the longest variable name to be used for
+// transform feedback, including the null-terminator.
+//
+// GL.GEOMETRY_VERTICES_OUT
+// params returns the maximum number of vertices that the geometry shader in
+// program will output.
+//
+// GL.GEOMETRY_INPUT_TYPE
+// params returns a symbolic constant indicating the primitive type accepted
+// as input to the geometry shader contained in program.
+//
+// GL.GEOMETRY_OUTPUT_TYPE
+// params returns a symbolic constant indicating the primitive type that will
+// be output by the geometry shader contained in program.
+//
+// GL.ACTIVE_UNIFORM_BLOCKS and GL.ACTIVE_UNIFORM_BLOCK_MAX_NAME_LENGTH are
+// available only if the GL version 3.1 or greater.
+//
+// GL.GEOMETRY_VERTICES_OUT, GL.GEOMETRY_INPUT_TYPE and
+// GL.GEOMETRY_OUTPUT_TYPE are accepted only if the GL version is 3.2 or
+// greater.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program does not refer to a
+// program object. GL.INVALID_OPERATION is generated if pname is
+// GL.GEOMETRY_VERTICES_OUT, GL.GEOMETRY_INPUT_TYPE, or
+// GL.GEOMETRY_OUTPUT_TYPE, and program does not contain a geometry shader.
+// GL.INVALID_ENUM is generated if pname is not an accepted value.
+func (gl *GL) GetProgramiv(program glbase.Program, pname glbase.Enum, params []int32) {
+ var params_c [4]int32
+ C.gl3_3core_glGetProgramiv(gl.funcs, C.GLuint(program), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetAttribLocation queries the previously linked program object specified
+// by program for the attribute variable specified by name and returns the
+// index of the generic vertex attribute that is bound to that attribute
+// variable. If name is a matrix attribute variable, the index of the first
+// column of the matrix is returned. If the named attribute variable is not
+// an active attribute in the specified program object or if name starts with
+// the reserved prefix "gl_", a value of -1 is returned.
+//
+// The association between an attribute variable name and a generic attribute
+// index can be specified at any time by calling BindAttribLocation.
+// Attribute bindings do not go into effect until LinkProgram is called.
+// After a program object has been linked successfully, the index values for
+// attribute variables remain fixed until the next link command occurs. The
+// attribute values can only be queried after a link if the link was
+// successful. GetAttribLocation returns the binding that actually went
+// into effect the last time LinkProgram was called for the specified
+// program object. Attribute bindings that have been specified since the last
+// link operation are not returned by GetAttribLocation.
+//
+// Error GL_INVALID_OPERATION is generated if program is not a value
+// generated by OpenGL. GL_INVALID_OPERATION is generated if program is not
+// a program object. GL_INVALID_OPERATION is generated if program has not
+// been successfully linked. GL_INVALID_OPERATION is generated if
+// GetAttribLocation is executed between the execution of Begin and the
+// corresponding execution of End.
+//
+// GetAttribLocation is available in GL version 2.0 or greater.
+func (gl *GL) GetAttribLocation(program glbase.Program, name string) glbase.Attrib {
+ name_cstr := C.CString(name)
+ glresult := C.gl3_3core_glGetAttribLocation(gl.funcs, C.GLuint(program), (*C.GLchar)(name_cstr))
+ C.free(unsafe.Pointer(name_cstr))
+ return glbase.Attrib(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetAttachedShaders.xml
+func (gl *GL) GetAttachedShaders(program glbase.Program, maxCount int32, count []int, obj []uint32) {
+ C.gl3_3core_glGetAttachedShaders(gl.funcs, C.GLuint(program), C.GLsizei(maxCount), (*C.GLsizei)(unsafe.Pointer(&count[0])), (*C.GLuint)(unsafe.Pointer(&obj[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetActiveUniform.xml
+func (gl *GL) GetActiveUniform(program glbase.Program, index uint32, bufSize int32, length []int32, size []int, gltype []glbase.Enum, name []byte) {
+ C.gl3_3core_glGetActiveUniform(gl.funcs, C.GLuint(program), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLint)(unsafe.Pointer(&size[0])), (*C.GLenum)(unsafe.Pointer(&gltype[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetActiveAttrib.xml
+func (gl *GL) GetActiveAttrib(program glbase.Program, index glbase.Attrib, bufSize int32, length []int32, size []int, gltype []glbase.Enum, name []byte) {
+ C.gl3_3core_glGetActiveAttrib(gl.funcs, C.GLuint(program), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLint)(unsafe.Pointer(&size[0])), (*C.GLenum)(unsafe.Pointer(&gltype[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEnableVertexAttribArray.xml
+func (gl *GL) EnableVertexAttribArray(index glbase.Attrib) {
+ C.gl3_3core_glEnableVertexAttribArray(gl.funcs, C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDisableVertexAttribArray.xml
+func (gl *GL) DisableVertexAttribArray(index glbase.Attrib) {
+ C.gl3_3core_glDisableVertexAttribArray(gl.funcs, C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDetachShader.xml
+func (gl *GL) DetachShader(program glbase.Program, shader glbase.Shader) {
+ C.gl3_3core_glDetachShader(gl.funcs, C.GLuint(program), C.GLuint(shader))
+}
+
+// DeleteShader frees the memory and invalidates the name associated with
+// the shader object specified by shader. This command effectively undoes the
+// effects of a call to CreateShader.
+//
+// If a shader object to be deleted is attached to a program object, it will
+// be flagged for deletion, but it will not be deleted until it is no longer
+// attached to any program object, for any rendering context (it must
+// be detached from wherever it was attached before it will be deleted). A
+// value of 0 for shader will be silently ignored.
+//
+// To determine whether an object has been flagged for deletion, call
+// GetShader with arguments shader and GL.DELETE_STATUS.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL.
+//
+// DeleteShader is available in GL version 2.0 or greater.
+func (gl *GL) DeleteShader(shader glbase.Shader) {
+ C.gl3_3core_glDeleteShader(gl.funcs, C.GLuint(shader))
+}
+
+// DeleteProgram frees the memory and invalidates the name associated with
+// the program object specified by program. This command effectively undoes
+// the effects of a call to CreateProgram.
+//
+// If a program object is in use as part of current rendering state, it will
+// be flagged for deletion, but it will not be deleted until it is no longer
+// part of current state for any rendering context. If a program object to be
+// deleted has shader objects attached to it, those shader objects will be
+// automatically detached but not deleted unless they have already been
+// flagged for deletion by a previous call to DeleteShader. A value of 0
+// for program will be silently ignored.
+//
+// To determine whether a program object has been flagged for deletion, call
+// GetProgram with arguments program and GL.DELETE_STATUS.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL.
+//
+// DeleteProgram is available in GL version 2.0 or greater.
+func (gl *GL) DeleteProgram(program glbase.Program) {
+ C.gl3_3core_glDeleteProgram(gl.funcs, C.GLuint(program))
+}
+
+// CreateShader creates an empty shader object and returns a non-zero value
+// by which it can be referenced. A shader object is used to maintain the
+// source code strings that define a shader. shaderType indicates the type of
+// shader to be created.
+//
+// Two types of shaders are supported. A shader of type GL.VERTEX_SHADER is a
+// shader that is intended to run on the programmable vertex processor and
+// replace the fixed functionality vertex processing in OpenGL. A shader of
+// type GL.FRAGMENT_SHADER is a shader that is intended to run on the
+// programmable fragment processor and replace the fixed functionality
+// fragment processing in OpenGL.
+//
+// When created, a shader object's GL.SHADER_TYPE parameter is set to either
+// GL.VERTEX_SHADER or GL.FRAGMENT_SHADER, depending on the value of
+// shaderType.
+//
+// Like display lists and texture objects, the name space for shader objects
+// may be shared across a set of contexts, as long as the server sides of the
+// contexts share the same address space. If the name space is shared across
+// contexts, any attached objects and the data associated with those attached
+// objects are shared as well.
+//
+// This function returns 0 if an error occurs creating the shader object.
+//
+// Error GL.INVALID_ENUM is generated if shaderType is not an accepted value.
+// GL.INVALID_OPERATION is generated if CreateShader is executed between the
+// execution of Begin and the corresponding execution of End.
+//
+// CreateShader is available in GL version 2.0 or greater.
+func (gl *GL) CreateShader(gltype glbase.Enum) glbase.Shader {
+ glresult := C.gl3_3core_glCreateShader(gl.funcs, C.GLenum(gltype))
+ return glbase.Shader(glresult)
+}
+
+// CreateProgram creates an empty program object and returns a non-zero
+// value by which it can be referenced. A program object is an object to
+// which shader objects can be attached. This provides a mechanism to specify
+// the shader objects that will be linked to create a program. It also
+// provides a means for checking the compatibility of the shaders that will
+// be used to create a program (for instance, checking the compatibility
+// between a vertex shader and a fragment shader). When no longer needed as
+// part of a program object, shader objects can be detached.
+//
+// One or more executables are created in a program object by successfully
+// attaching shader objects to it with AttachShader, successfully compiling
+// the shader objects with CompileShader, and successfully linking the
+// program object with LinkProgram. These executables are made part of
+// current state when UseProgram is called. Program objects can be deleted
+// by calling DeleteProgram. The memory associated with the program object
+// will be deleted when it is no longer part of current rendering state for
+// any context.
+//
+// Like display lists and texture objects, the name space for program objects
+// may be shared across a set of contexts, as long as the server sides of the
+// contexts share the same address space. If the name space is shared across
+// contexts, any attached objects and the data associated with those attached
+// objects are shared as well.
+//
+// Applications are responsible for providing the synchronization across API
+// calls when objects are accessed from different execution threads.
+//
+// This function returns 0 if an error occurs creating the program object.
+//
+// Error GL.INVALID_OPERATION is generated if CreateProgram is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// CreateProgram is available in GL version 2.0 or greater.
+func (gl *GL) CreateProgram() glbase.Program {
+ glresult := C.gl3_3core_glCreateProgram(gl.funcs)
+ return glbase.Program(glresult)
+}
+
+// CompileShader compiles the source code strings that have been stored in
+// the shader object specified by shader.
+//
+// The compilation status will be stored as part of the shader object's
+// state. This value will be set to GL.TRUE if the shader was compiled without
+// errors and is ready for use, and GL.FALSE otherwise. It can be queried by
+// calling GetShaderiv with arguments shader and GL.COMPILE_STATUS.
+//
+// Compilation of a shader can fail for a number of reasons as specified by
+// the OpenGL Shading Language Specification. Whether or not the compilation
+// was successful, information about the compilation can be obtained from the
+// shader object's information log by calling GetShaderInfoLog.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader is not a shader
+// object. GL.INVALID_OPERATION is generated if CompileShader is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// CompileShader is available in GL version 2.0 or greater.
+func (gl *GL) CompileShader(shader glbase.Shader) {
+ C.gl3_3core_glCompileShader(gl.funcs, C.GLuint(shader))
+}
+
+// BindAttribLocation associates a user-defined attribute variable in the program
+// object specified by program with a generic vertex attribute index. The name
+// parameter specifies the name of the vertex shader attribute variable to
+// which index is to be bound. When program is made part of the current state,
+// values provided via the generic vertex attribute index will modify the
+// value of the user-defined attribute variable specified by name.
+//
+// If name refers to a matrix attribute variable, index refers to the first
+// column of the matrix. Other matrix columns are then automatically bound to
+// locations index+1 for a matrix of type mat2; index+1 and index+2 for a
+// matrix of type mat3; and index+1, index+2, and index+3 for a matrix of
+// type mat4.
+//
+// This command makes it possible for vertex shaders to use descriptive names
+// for attribute variables rather than generic variables that are numbered
+// from 0 to GL.MAX_VERTEX_ATTRIBS-1. The values sent to each generic
+// attribute index are part of current state, just like standard vertex
+// attributes such as color, normal, and vertex position. If a different
+// program object is made current by calling UseProgram, the generic vertex
+// attributes are tracked in such a way that the same values will be observed
+// by attributes in the new program object that are also bound to index.
+//
+// Attribute variable name-to-generic attribute index bindings for a program
+// object can be explicitly assigned at any time by calling
+// BindAttribLocation. Attribute bindings do not go into effect until
+// LinkProgram is called. After a program object has been linked
+// successfully, the index values for generic attributes remain fixed (and
+// their values can be queried) until the next link command occurs.
+//
+// Applications are not allowed to bind any of the standard OpenGL vertex
+// attributes using this command, as they are bound automatically when
+// needed. Any attribute binding that occurs after the program object has
+// been linked will not take effect until the next time the program object is
+// linked.
+//
+// If name was bound previously, that information is lost. Thus you cannot
+// bind one user-defined attribute variable to multiple indices, but you can
+// bind multiple user-defined attribute variables to the same index.
+//
+// Applications are allowed to bind more than one user-defined attribute
+// variable to the same generic vertex attribute index. This is called
+// aliasing, and it is allowed only if just one of the aliased attributes is
+// active in the executable program, or if no path through the shader
+// consumes more than one attribute of a set of attributes aliased to the
+// same location. The compiler and linker are allowed to assume that no
+// aliasing is done and are free to employ optimizations that work only in
+// the absence of aliasing. OpenGL implementations are not required to do
+// error checking to detect aliasing. Because there is no way to bind
+// standard attributes, it is not possible to alias generic attributes with
+// conventional ones (except for generic attribute 0).
+//
+// BindAttribLocation can be called before any vertex shader objects are
+// bound to the specified program object. It is also permissible to bind a
+// generic attribute index to an attribute variable name that is never used
+// in a vertex shader.
+//
+// Active attributes that are not explicitly bound will be bound by the
+// linker when LinkProgram is called. The locations assigned can be queried
+// by calling GetAttribLocation.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS.
+// GL.INVALID_OPERATION is generated if name starts with the reserved prefix "gl_".
+// GL.INVALID_VALUE is generated if program is not a value generated by OpenGL.
+// GL.INVALID_OPERATION is generated if program is not a program object.
+// GL.INVALID_OPERATION is generated if BindAttribLocation is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// BindAttribLocation is available in GL version 2.0 or greater.
+func (gl *GL) BindAttribLocation(program glbase.Program, index glbase.Attrib, name string) {
+ name_cstr := C.CString(name)
+ C.gl3_3core_glBindAttribLocation(gl.funcs, C.GLuint(program), C.GLuint(index), (*C.GLchar)(name_cstr))
+ C.free(unsafe.Pointer(name_cstr))
+}
+
+// AttachShader attaches a shader object to a program object.
+//
+// In order to create an executable, there must be a way to specify the list
+// of things that will be linked together. Program objects provide this
+// mechanism. Shaders that are to be linked together in a program object must
+// first be attached to that program object. This indicates that shader will
+// be included in link operations that will be performed on program.
+//
+// All operations that can be performed on a shader object are valid whether
+// or not the shader object is attached to a program object. It is
+// permissible to attach a shader object to a program object before source
+// code has been loaded into the shader object or before the shader object
+// has been compiled. It is permissible to attach multiple shader objects of
+// the same type because each may contain a portion of the complete shader.
+// It is also permissible to attach a shader object to more than one program
+// object. If a shader object is deleted while it is attached to a program
+// object, it will be flagged for deletion, and deletion will not occur until
+// DetachShader is called to detach it from all program objects to which it
+// is attached.
+//
+// Error GL.INVALID_VALUE is generated if either program or shader is not a
+// value generated by OpenGL. GL.INVALID_OPERATION is generated if program
+// is not a program object. GL.INVALID_OPERATION is generated if shader is
+// not a shader object. GL.INVALID_OPERATION is generated if shader is
+// already attached to program. GL.INVALID_OPERATION is generated if
+// AttachShader is executed between the execution of Begin and the
+// corresponding execution of End.
+//
+// AttachShader is available in GL version 2.0 or greater.
+func (gl *GL) AttachShader(program glbase.Program, shader glbase.Shader) {
+ C.gl3_3core_glAttachShader(gl.funcs, C.GLuint(program), C.GLuint(shader))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glStencilMaskSeparate.xml
+func (gl *GL) StencilMaskSeparate(face glbase.Enum, mask uint32) {
+ C.gl3_3core_glStencilMaskSeparate(gl.funcs, C.GLenum(face), C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glStencilFuncSeparate.xml
+func (gl *GL) StencilFuncSeparate(face, glfunc glbase.Enum, ref int32, mask uint32) {
+ C.gl3_3core_glStencilFuncSeparate(gl.funcs, C.GLenum(face), C.GLenum(glfunc), C.GLint(ref), C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glStencilOpSeparate.xml
+func (gl *GL) StencilOpSeparate(face, sfail, dpfail, dppass glbase.Enum) {
+ C.gl3_3core_glStencilOpSeparate(gl.funcs, C.GLenum(face), C.GLenum(sfail), C.GLenum(dpfail), C.GLenum(dppass))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDrawBuffers.xml
+func (gl *GL) DrawBuffers(n int, bufs []glbase.Enum) {
+ C.gl3_3core_glDrawBuffers(gl.funcs, C.GLsizei(n), (*C.GLenum)(unsafe.Pointer(&bufs[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBlendEquationSeparate.xml
+func (gl *GL) BlendEquationSeparate(modeRGB, modeAlpha glbase.Enum) {
+ C.gl3_3core_glBlendEquationSeparate(gl.funcs, C.GLenum(modeRGB), C.GLenum(modeAlpha))
+}
+
+// UniformMatrix4x3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix4x3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix4x3fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(4*3) != 0 {
+ panic("invalid value length for UniformMatrix4x3fv")
+ }
+ count := len(value) / (4 * 3)
+ C.gl3_3core_glUniformMatrix4x3fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix3x4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix3x4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix3x4fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(3*4) != 0 {
+ panic("invalid value length for UniformMatrix3x4fv")
+ }
+ count := len(value) / (3 * 4)
+ C.gl3_3core_glUniformMatrix3x4fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix4x2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix4x2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix4x2fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(4*2) != 0 {
+ panic("invalid value length for UniformMatrix4x2fv")
+ }
+ count := len(value) / (4 * 2)
+ C.gl3_3core_glUniformMatrix4x2fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix2x4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix2x4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix2x4fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(2*4) != 0 {
+ panic("invalid value length for UniformMatrix2x4fv")
+ }
+ count := len(value) / (2 * 4)
+ C.gl3_3core_glUniformMatrix2x4fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix3x2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix3x2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix3x2fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(3*2) != 0 {
+ panic("invalid value length for UniformMatrix3x2fv")
+ }
+ count := len(value) / (3 * 2)
+ C.gl3_3core_glUniformMatrix3x2fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix2x3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix2x3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix2x3fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(2*3) != 0 {
+ panic("invalid value length for UniformMatrix2x3fv")
+ }
+ count := len(value) / (2 * 3)
+ C.gl3_3core_glUniformMatrix2x3fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsVertexArray.xml
+func (gl *GL) IsVertexArray(array uint32) bool {
+ glresult := C.gl3_3core_glIsVertexArray(gl.funcs, C.GLuint(array))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGenVertexArrays.xml
+func (gl *GL) GenVertexArrays(n int, arrays []uint32) {
+ C.gl3_3core_glGenVertexArrays(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&arrays[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDeleteVertexArrays.xml
+func (gl *GL) DeleteVertexArrays(n int, arrays []uint32) {
+ C.gl3_3core_glDeleteVertexArrays(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&arrays[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBindVertexArray.xml
+func (gl *GL) BindVertexArray(array uint32) {
+ C.gl3_3core_glBindVertexArray(gl.funcs, C.GLuint(array))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFlushMappedBufferRange.xml
+func (gl *GL) FlushMappedBufferRange(target glbase.Enum, offset, length int) {
+ C.gl3_3core_glFlushMappedBufferRange(gl.funcs, C.GLenum(target), C.GLintptr(offset), C.GLsizeiptr(length))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFramebufferTextureLayer.xml
+func (gl *GL) FramebufferTextureLayer(target, attachment glbase.Enum, texture glbase.Texture, level int, layer int32) {
+ C.gl3_3core_glFramebufferTextureLayer(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLuint(texture), C.GLint(level), C.GLint(layer))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRenderbufferStorageMultisample.xml
+func (gl *GL) RenderbufferStorageMultisample(target glbase.Enum, samples int32, internalFormat glbase.Enum, width, height int) {
+ C.gl3_3core_glRenderbufferStorageMultisample(gl.funcs, C.GLenum(target), C.GLsizei(samples), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBlitFramebuffer.xml
+func (gl *GL) BlitFramebuffer(srcX0, srcY0, srcX1, srcY1, dstX0, dstY0, dstX1, dstY1 int32, mask glbase.Bitfield, filter glbase.Enum) {
+ C.gl3_3core_glBlitFramebuffer(gl.funcs, C.GLint(srcX0), C.GLint(srcY0), C.GLint(srcX1), C.GLint(srcY1), C.GLint(dstX0), C.GLint(dstY0), C.GLint(dstX1), C.GLint(dstY1), C.GLbitfield(mask), C.GLenum(filter))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGenerateMipmap.xml
+func (gl *GL) GenerateMipmap(target glbase.Enum) {
+ C.gl3_3core_glGenerateMipmap(gl.funcs, C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetFramebufferAttachmentParameteriv.xml
+func (gl *GL) GetFramebufferAttachmentParameteriv(target, attachment, pname glbase.Enum, params []int32) {
+ C.gl3_3core_glGetFramebufferAttachmentParameteriv(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFramebufferRenderbuffer.xml
+func (gl *GL) FramebufferRenderbuffer(target, attachment, renderbuffertarget glbase.Enum, renderbuffer glbase.Renderbuffer) {
+ C.gl3_3core_glFramebufferRenderbuffer(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(renderbuffertarget), C.GLuint(renderbuffer))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFramebufferTexture3D.xml
+func (gl *GL) FramebufferTexture3D(target, attachment, textarget glbase.Enum, texture glbase.Texture, level int, zoffset int32) {
+ C.gl3_3core_glFramebufferTexture3D(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(textarget), C.GLuint(texture), C.GLint(level), C.GLint(zoffset))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFramebufferTexture2D.xml
+func (gl *GL) FramebufferTexture2D(target, attachment, textarget glbase.Enum, texture glbase.Texture, level int) {
+ C.gl3_3core_glFramebufferTexture2D(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(textarget), C.GLuint(texture), C.GLint(level))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFramebufferTexture1D.xml
+func (gl *GL) FramebufferTexture1D(target, attachment, textarget glbase.Enum, texture glbase.Texture, level int) {
+ C.gl3_3core_glFramebufferTexture1D(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(textarget), C.GLuint(texture), C.GLint(level))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCheckFramebufferStatus.xml
+func (gl *GL) CheckFramebufferStatus(target glbase.Enum) glbase.Enum {
+ glresult := C.gl3_3core_glCheckFramebufferStatus(gl.funcs, C.GLenum(target))
+ return glbase.Enum(glresult)
+}
+
+// GenFramebuffers returns n framebuffer object names in ids. There is no
+// guarantee that the names form a contiguous set of integers; however, it is
+// guaranteed that none of the returned names was in use immediately before
+// the call to GenFramebuffers.
+//
+// Framebuffer object names returned by a call to GenFramebuffers are not
+// returned by subsequent calls, unless they are first deleted with
+// DeleteFramebuffers.
+//
+// The names returned in ids are marked as used, for the purposes of
+// GenFramebuffers only, but they acquire state and type only when they are
+// first bound.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+func (gl *GL) GenFramebuffers(n int) []glbase.Framebuffer {
+ if n == 0 {
+ return nil
+ }
+ framebuffers := make([]glbase.Framebuffer, n)
+ C.gl3_3core_glGenFramebuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&framebuffers[0])))
+ return framebuffers
+}
+
+// DeleteFramebuffers deletes the framebuffer objects whose names are
+// stored in the framebuffers slice. The name zero is reserved by the GL and
+// is silently ignored, should it occur in framebuffers, as are other unused
+// names. Once a framebuffer object is deleted, its name is again unused and
+// it has no attachments. If a framebuffer that is currently bound to one or
+// more of the targets GL.DRAW_FRAMEBUFFER or GL.READ_FRAMEBUFFER is deleted,
+// it is as though BindFramebuffer had been executed with the corresponding
+// target and framebuffer zero.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// DeleteFramebuffers is available in GL version 3.0 or greater.
+func (gl *GL) DeleteFramebuffers(framebuffers []glbase.Framebuffer) {
+ n := len(framebuffers)
+ if n == 0 {
+ return
+ }
+ C.gl3_3core_glDeleteFramebuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&framebuffers[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBindFramebuffer.xml
+func (gl *GL) BindFramebuffer(target glbase.Enum, framebuffer glbase.Framebuffer) {
+ C.gl3_3core_glBindFramebuffer(gl.funcs, C.GLenum(target), C.GLuint(framebuffer))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsFramebuffer.xml
+func (gl *GL) IsFramebuffer(framebuffer glbase.Framebuffer) bool {
+ glresult := C.gl3_3core_glIsFramebuffer(gl.funcs, C.GLuint(framebuffer))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetRenderbufferParameteriv.xml
+func (gl *GL) GetRenderbufferParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl3_3core_glGetRenderbufferParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glRenderbufferStorage.xml
+func (gl *GL) RenderbufferStorage(target, internalFormat glbase.Enum, width, height int) {
+ C.gl3_3core_glRenderbufferStorage(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height))
+}
+
+// GenRenderbuffers returns n renderbuffer object names in renderbuffers.
+// There is no guarantee that the names form a contiguous set of integers;
+// however, it is guaranteed that none of the returned names was in use
+// immediately before the call to GenRenderbuffers.
+//
+// Renderbuffer object names returned by a call to GenRenderbuffers are not
+// returned by subsequent calls, unless they are first deleted with
+// DeleteRenderbuffers.
+//
+// The names returned in renderbuffers are marked as used, for the purposes
+// of GenRenderbuffers only, but they acquire state and type only when they
+// are first bound.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// GenRenderbuffers is available in GL version 3.0 or greater.
+func (gl *GL) GenRenderbuffers(n int) []glbase.Renderbuffer {
+ if n == 0 {
+ return nil
+ }
+ renderbuffers := make([]glbase.Renderbuffer, n)
+ C.gl3_3core_glGenRenderbuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&renderbuffers[0])))
+ return renderbuffers
+}
+
+// DeleteRenderbuffers deletes the renderbuffer objects whose names are stored
+// in the renderbuffers slice. The name zero is reserved by the GL and
+// is silently ignored, should it occur in renderbuffers, as are other unused
+// names. Once a renderbuffer object is deleted, its name is again unused and
+// it has no contents. If a renderbuffer that is currently bound to the
+// target GL.RENDERBUFFER is deleted, it is as though BindRenderbuffer had
+// been executed with a target of GL.RENDERBUFFER and a name of zero.
+//
+// If a renderbuffer object is attached to one or more attachment points in
+// the currently bound framebuffer, then it as if FramebufferRenderbuffer
+// had been called, with a renderbuffer of zero for each attachment point to
+// which this image was attached in the currently bound framebuffer. In other
+// words, this renderbuffer object is first detached from all attachment
+// ponits in the currently bound framebuffer. Note that the renderbuffer
+// image is specifically not detached from any non-bound framebuffers.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// DeleteRenderbuffers is available in GL version 3.0 or greater.
+func (gl *GL) DeleteRenderbuffers(renderbuffers []glbase.Renderbuffer) {
+ n := len(renderbuffers)
+ if n == 0 {
+ return
+ }
+ C.gl3_3core_glDeleteRenderbuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&renderbuffers[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBindRenderbuffer.xml
+func (gl *GL) BindRenderbuffer(target glbase.Enum, renderbuffer glbase.Renderbuffer) {
+ C.gl3_3core_glBindRenderbuffer(gl.funcs, C.GLenum(target), C.GLuint(renderbuffer))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsRenderbuffer.xml
+func (gl *GL) IsRenderbuffer(renderbuffer glbase.Renderbuffer) bool {
+ glresult := C.gl3_3core_glIsRenderbuffer(gl.funcs, C.GLuint(renderbuffer))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClearBufferfi.xml
+func (gl *GL) ClearBufferfi(buffer glbase.Enum, drawbuffer int32, depth float32, stencil int32) {
+ C.gl3_3core_glClearBufferfi(gl.funcs, C.GLenum(buffer), C.GLint(drawbuffer), C.GLfloat(depth), C.GLint(stencil))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClearBufferfv.xml
+func (gl *GL) ClearBufferfv(buffer glbase.Enum, drawbuffer int32, value []float32) {
+ C.gl3_3core_glClearBufferfv(gl.funcs, C.GLenum(buffer), C.GLint(drawbuffer), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClearBufferuiv.xml
+func (gl *GL) ClearBufferuiv(buffer glbase.Enum, drawbuffer int32, value []uint32) {
+ C.gl3_3core_glClearBufferuiv(gl.funcs, C.GLenum(buffer), C.GLint(drawbuffer), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClearBufferiv.xml
+func (gl *GL) ClearBufferiv(buffer glbase.Enum, drawbuffer int32, value []int32) {
+ C.gl3_3core_glClearBufferiv(gl.funcs, C.GLenum(buffer), C.GLint(drawbuffer), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTexParameterIuiv.xml
+func (gl *GL) GetTexParameterIuiv(target, pname glbase.Enum, params []uint32) {
+ C.gl3_3core_glGetTexParameterIuiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTexParameterIiv.xml
+func (gl *GL) GetTexParameterIiv(target, pname glbase.Enum, params []int32) {
+ C.gl3_3core_glGetTexParameterIiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexParameterIuiv.xml
+func (gl *GL) TexParameterIuiv(target, pname glbase.Enum, params []uint32) {
+ C.gl3_3core_glTexParameterIuiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexParameterIiv.xml
+func (gl *GL) TexParameterIiv(target, pname glbase.Enum, params []int32) {
+ C.gl3_3core_glTexParameterIiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// Uniform4uiv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform4uiv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4uiv(location glbase.Uniform, value []uint32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%4 != 0 {
+ panic("invalid value length for Uniform4uiv")
+ }
+ count := len(value) / 4
+ C.gl3_3core_glUniform4uiv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform3uiv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform3uiv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3uiv(location glbase.Uniform, value []uint32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%3 != 0 {
+ panic("invalid value length for Uniform3uiv")
+ }
+ count := len(value) / 3
+ C.gl3_3core_glUniform3uiv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform2uiv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform2uiv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2uiv(location glbase.Uniform, value []uint32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%2 != 0 {
+ panic("invalid value length for Uniform2uiv")
+ }
+ count := len(value) / 2
+ C.gl3_3core_glUniform2uiv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform1uiv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform1uiv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1uiv(location glbase.Uniform, value []uint32) {
+ if len(value) == 0 {
+ return
+ }
+ count := len(value)
+ C.gl3_3core_glUniform1uiv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4ui modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform4ui operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4ui(location glbase.Uniform, v0, v1, v2, v3 uint32) {
+ C.gl3_3core_glUniform4ui(gl.funcs, C.GLint(location), C.GLuint(v0), C.GLuint(v1), C.GLuint(v2), C.GLuint(v3))
+}
+
+// Uniform3ui modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform3ui operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3ui(location glbase.Uniform, v0, v1, v2 uint32) {
+ C.gl3_3core_glUniform3ui(gl.funcs, C.GLint(location), C.GLuint(v0), C.GLuint(v1), C.GLuint(v2))
+}
+
+// Uniform2ui modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform2ui operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2ui(location glbase.Uniform, v0, v1 uint32) {
+ C.gl3_3core_glUniform2ui(gl.funcs, C.GLint(location), C.GLuint(v0), C.GLuint(v1))
+}
+
+// Uniform1ui modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform1ui operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1ui(location glbase.Uniform, v0 uint32) {
+ C.gl3_3core_glUniform1ui(gl.funcs, C.GLint(location), C.GLuint(v0))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetFragDataLocation.xml
+func (gl *GL) GetFragDataLocation(program glbase.Program, name []byte) int32 {
+ glresult := C.gl3_3core_glGetFragDataLocation(gl.funcs, C.GLuint(program), (*C.GLchar)(unsafe.Pointer(&name[0])))
+ return int32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBindFragDataLocation.xml
+func (gl *GL) BindFragDataLocation(program glbase.Program, color uint32, name []byte) {
+ C.gl3_3core_glBindFragDataLocation(gl.funcs, C.GLuint(program), C.GLuint(color), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetUniformuiv.xml
+func (gl *GL) GetUniformuiv(program glbase.Program, location glbase.Uniform, params []uint32) {
+ C.gl3_3core_glGetUniformuiv(gl.funcs, C.GLuint(program), C.GLint(location), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetVertexAttribIuiv.xml
+func (gl *GL) GetVertexAttribIuiv(index glbase.Attrib, pname glbase.Enum, params []uint32) {
+ C.gl3_3core_glGetVertexAttribIuiv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetVertexAttribIiv.xml
+func (gl *GL) GetVertexAttribIiv(index glbase.Attrib, pname glbase.Enum, params []int32) {
+ C.gl3_3core_glGetVertexAttribIiv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribIPointer.xml
+func (gl *GL) VertexAttribIPointer(index glbase.Attrib, size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3core_glVertexAttribIPointer(gl.funcs, C.GLuint(index), C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEndConditionalRender.xml
+func (gl *GL) EndConditionalRender() {
+ C.gl3_3core_glEndConditionalRender(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBeginConditionalRender.xml
+func (gl *GL) BeginConditionalRender(id uint32, mode glbase.Enum) {
+ C.gl3_3core_glBeginConditionalRender(gl.funcs, C.GLuint(id), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClampColor.xml
+func (gl *GL) ClampColor(target, clamp glbase.Enum) {
+ C.gl3_3core_glClampColor(gl.funcs, C.GLenum(target), C.GLenum(clamp))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetTransformFeedbackVarying.xml
+func (gl *GL) GetTransformFeedbackVarying(program glbase.Program, index uint32, bufSize int32, length []int32, size []int, gltype []glbase.Enum, name []byte) {
+ C.gl3_3core_glGetTransformFeedbackVarying(gl.funcs, C.GLuint(program), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLsizei)(unsafe.Pointer(&size[0])), (*C.GLenum)(unsafe.Pointer(&gltype[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBindBufferBase.xml
+func (gl *GL) BindBufferBase(target glbase.Enum, index uint32, buffer glbase.Buffer) {
+ C.gl3_3core_glBindBufferBase(gl.funcs, C.GLenum(target), C.GLuint(index), C.GLuint(buffer))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBindBufferRange.xml
+func (gl *GL) BindBufferRange(target glbase.Enum, index uint32, buffer glbase.Buffer, offset, size int) {
+ C.gl3_3core_glBindBufferRange(gl.funcs, C.GLenum(target), C.GLuint(index), C.GLuint(buffer), C.GLintptr(offset), C.GLsizeiptr(size))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEndTransformFeedback.xml
+func (gl *GL) EndTransformFeedback() {
+ C.gl3_3core_glEndTransformFeedback(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBeginTransformFeedback.xml
+func (gl *GL) BeginTransformFeedback(primitiveMode glbase.Enum) {
+ C.gl3_3core_glBeginTransformFeedback(gl.funcs, C.GLenum(primitiveMode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsEnabledi.xml
+func (gl *GL) IsEnabledi(target glbase.Enum, index uint32) bool {
+ glresult := C.gl3_3core_glIsEnabledi(gl.funcs, C.GLenum(target), C.GLuint(index))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDisablei.xml
+func (gl *GL) Disablei(target glbase.Enum, index uint32) {
+ C.gl3_3core_glDisablei(gl.funcs, C.GLenum(target), C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glEnablei.xml
+func (gl *GL) Enablei(target glbase.Enum, index uint32) {
+ C.gl3_3core_glEnablei(gl.funcs, C.GLenum(target), C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetIntegeri_v.xml
+func (gl *GL) GetIntegeri_v(target glbase.Enum, index uint32, data []int32) {
+ C.gl3_3core_glGetIntegeri_v(gl.funcs, C.GLenum(target), C.GLuint(index), (*C.GLint)(unsafe.Pointer(&data[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetBooleani_v.xml
+func (gl *GL) GetBooleani_v(target glbase.Enum, index uint32, data []bool) {
+ C.gl3_3core_glGetBooleani_v(gl.funcs, C.GLenum(target), C.GLuint(index), (*C.GLboolean)(unsafe.Pointer(&data[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColorMaski.xml
+func (gl *GL) ColorMaski(index uint32, r, g, b, a bool) {
+ C.gl3_3core_glColorMaski(gl.funcs, C.GLuint(index), *(*C.GLboolean)(unsafe.Pointer(&r)), *(*C.GLboolean)(unsafe.Pointer(&g)), *(*C.GLboolean)(unsafe.Pointer(&b)), *(*C.GLboolean)(unsafe.Pointer(&a)))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glCopyBufferSubData.xml
+func (gl *GL) CopyBufferSubData(readTarget, writeTarget glbase.Enum, readOffset, writeOffset, size int) {
+ C.gl3_3core_glCopyBufferSubData(gl.funcs, C.GLenum(readTarget), C.GLenum(writeTarget), C.GLintptr(readOffset), C.GLintptr(writeOffset), C.GLsizeiptr(size))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glUniformBlockBinding.xml
+func (gl *GL) UniformBlockBinding(program glbase.Program, v0, v1 uint32) {
+ C.gl3_3core_glUniformBlockBinding(gl.funcs, C.GLuint(program), C.GLuint(v0), C.GLuint(v1))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetActiveUniformBlockName.xml
+func (gl *GL) GetActiveUniformBlockName(program glbase.Program, uniformBlockIndex uint32, bufSize int32, length []int32, uniformBlockName []byte) {
+ C.gl3_3core_glGetActiveUniformBlockName(gl.funcs, C.GLuint(program), C.GLuint(uniformBlockIndex), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&uniformBlockName[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetActiveUniformBlockiv.xml
+func (gl *GL) GetActiveUniformBlockiv(program glbase.Program, uniformBlockIndex uint32, pname glbase.Enum, params []int32) {
+ C.gl3_3core_glGetActiveUniformBlockiv(gl.funcs, C.GLuint(program), C.GLuint(uniformBlockIndex), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetUniformBlockIndex.xml
+func (gl *GL) GetUniformBlockIndex(program glbase.Program, uniformBlockName []byte) uint32 {
+ glresult := C.gl3_3core_glGetUniformBlockIndex(gl.funcs, C.GLuint(program), (*C.GLchar)(unsafe.Pointer(&uniformBlockName[0])))
+ return uint32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetActiveUniformName.xml
+func (gl *GL) GetActiveUniformName(program glbase.Program, uniformIndex uint32, bufSize int32, length []int32, uniformName []byte) {
+ C.gl3_3core_glGetActiveUniformName(gl.funcs, C.GLuint(program), C.GLuint(uniformIndex), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&uniformName[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetActiveUniformsiv.xml
+func (gl *GL) GetActiveUniformsiv(program glbase.Program, uniformCount int32, uniformIndices []uint32, pname glbase.Enum, params []int32) {
+ C.gl3_3core_glGetActiveUniformsiv(gl.funcs, C.GLuint(program), C.GLsizei(uniformCount), (*C.GLuint)(unsafe.Pointer(&uniformIndices[0])), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glPrimitiveRestartIndex.xml
+func (gl *GL) PrimitiveRestartIndex(index uint32) {
+ C.gl3_3core_glPrimitiveRestartIndex(gl.funcs, C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexBuffer.xml
+func (gl *GL) TexBuffer(target, internalFormat glbase.Enum, buffer glbase.Buffer) {
+ C.gl3_3core_glTexBuffer(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLuint(buffer))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDrawElementsInstanced.xml
+func (gl *GL) DrawElementsInstanced(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}, instancecount int32) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3core_glDrawElementsInstanced(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr, C.GLsizei(instancecount))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDrawArraysInstanced.xml
+func (gl *GL) DrawArraysInstanced(mode glbase.Enum, first, count int, instancecount int32) {
+ C.gl3_3core_glDrawArraysInstanced(gl.funcs, C.GLenum(mode), C.GLint(first), C.GLsizei(count), C.GLsizei(instancecount))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSampleMaski.xml
+func (gl *GL) SampleMaski(index uint32, mask glbase.Bitfield) {
+ C.gl3_3core_glSampleMaski(gl.funcs, C.GLuint(index), C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetMultisamplefv.xml
+func (gl *GL) GetMultisamplefv(pname glbase.Enum, index uint32, val []float32) {
+ C.gl3_3core_glGetMultisamplefv(gl.funcs, C.GLenum(pname), C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&val[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexImage3DMultisample.xml
+func (gl *GL) TexImage3DMultisample(target glbase.Enum, samples, internalFormat int32, width, height int, depth int32, fixedsamplelocations bool) {
+ C.gl3_3core_glTexImage3DMultisample(gl.funcs, C.GLenum(target), C.GLsizei(samples), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), *(*C.GLboolean)(unsafe.Pointer(&fixedsamplelocations)))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexImage2DMultisample.xml
+func (gl *GL) TexImage2DMultisample(target glbase.Enum, samples, internalFormat int32, width, height int, fixedsamplelocations bool) {
+ C.gl3_3core_glTexImage2DMultisample(gl.funcs, C.GLenum(target), C.GLsizei(samples), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), *(*C.GLboolean)(unsafe.Pointer(&fixedsamplelocations)))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetSynciv.xml
+func (gl *GL) GetSynciv(sync glbase.Sync, pname glbase.Enum, bufSize int32, length, values []int32) {
+ C.gl3_3core_glGetSynciv(gl.funcs, C.GLsync(unsafe.Pointer(sync)), C.GLenum(pname), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLint)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetInteger64v.xml
+func (gl *GL) GetInteger64v(pname glbase.Enum, params []int64) {
+ C.gl3_3core_glGetInteger64v(gl.funcs, C.GLenum(pname), (*C.GLint64)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glWaitSync.xml
+func (gl *GL) WaitSync(sync glbase.Sync, flags glbase.Bitfield, timeout uint64) {
+ C.gl3_3core_glWaitSync(gl.funcs, C.GLsync(unsafe.Pointer(sync)), C.GLbitfield(flags), C.GLuint64(timeout))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glClientWaitSync.xml
+func (gl *GL) ClientWaitSync(sync glbase.Sync, flags glbase.Bitfield, timeout uint64) glbase.Enum {
+ glresult := C.gl3_3core_glClientWaitSync(gl.funcs, C.GLsync(unsafe.Pointer(sync)), C.GLbitfield(flags), C.GLuint64(timeout))
+ return glbase.Enum(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDeleteSync.xml
+func (gl *GL) DeleteSync(sync glbase.Sync) {
+ C.gl3_3core_glDeleteSync(gl.funcs, C.GLsync(unsafe.Pointer(sync)))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsSync.xml
+func (gl *GL) IsSync(sync glbase.Sync) bool {
+ glresult := C.gl3_3core_glIsSync(gl.funcs, C.GLsync(unsafe.Pointer(sync)))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFenceSync.xml
+func (gl *GL) FenceSync(condition glbase.Enum, flags glbase.Bitfield) glbase.Sync {
+ glresult := C.gl3_3core_glFenceSync(gl.funcs, C.GLenum(condition), C.GLbitfield(flags))
+ return glbase.Sync(unsafe.Pointer(glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glProvokingVertex.xml
+func (gl *GL) ProvokingVertex(mode glbase.Enum) {
+ C.gl3_3core_glProvokingVertex(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDrawElementsInstancedBaseVertex.xml
+func (gl *GL) DrawElementsInstancedBaseVertex(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}, instancecount, basevertex int32) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3core_glDrawElementsInstancedBaseVertex(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr, C.GLsizei(instancecount), C.GLint(basevertex))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDrawRangeElementsBaseVertex.xml
+func (gl *GL) DrawRangeElementsBaseVertex(mode glbase.Enum, start, end uint32, count int, gltype glbase.Enum, indices interface{}, basevertex int32) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3core_glDrawRangeElementsBaseVertex(gl.funcs, C.GLenum(mode), C.GLuint(start), C.GLuint(end), C.GLsizei(count), C.GLenum(gltype), indices_ptr, C.GLint(basevertex))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDrawElementsBaseVertex.xml
+func (gl *GL) DrawElementsBaseVertex(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}, basevertex int32) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl3_3core_glDrawElementsBaseVertex(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr, C.GLint(basevertex))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glFramebufferTexture.xml
+func (gl *GL) FramebufferTexture(target, attachment glbase.Enum, texture glbase.Texture, level int) {
+ C.gl3_3core_glFramebufferTexture(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLuint(texture), C.GLint(level))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetBufferParameteri64v.xml
+func (gl *GL) GetBufferParameteri64v(target, pname glbase.Enum, params []int64) {
+ C.gl3_3core_glGetBufferParameteri64v(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint64)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetInteger64i_v.xml
+func (gl *GL) GetInteger64i_v(target glbase.Enum, index uint32, data []int64) {
+ C.gl3_3core_glGetInteger64i_v(gl.funcs, C.GLenum(target), C.GLuint(index), (*C.GLint64)(unsafe.Pointer(&data[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribP4uiv.xml
+func (gl *GL) VertexAttribP4uiv(index glbase.Attrib, gltype glbase.Enum, normalized bool, value []uint32) {
+ C.gl3_3core_glVertexAttribP4uiv(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribP4ui.xml
+func (gl *GL) VertexAttribP4ui(index glbase.Attrib, gltype glbase.Enum, normalized bool, value uint32) {
+ C.gl3_3core_glVertexAttribP4ui(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribP3uiv.xml
+func (gl *GL) VertexAttribP3uiv(index glbase.Attrib, gltype glbase.Enum, normalized bool, value []uint32) {
+ C.gl3_3core_glVertexAttribP3uiv(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribP3ui.xml
+func (gl *GL) VertexAttribP3ui(index glbase.Attrib, gltype glbase.Enum, normalized bool, value uint32) {
+ C.gl3_3core_glVertexAttribP3ui(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribP2uiv.xml
+func (gl *GL) VertexAttribP2uiv(index glbase.Attrib, gltype glbase.Enum, normalized bool, value []uint32) {
+ C.gl3_3core_glVertexAttribP2uiv(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribP2ui.xml
+func (gl *GL) VertexAttribP2ui(index glbase.Attrib, gltype glbase.Enum, normalized bool, value uint32) {
+ C.gl3_3core_glVertexAttribP2ui(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribP1uiv.xml
+func (gl *GL) VertexAttribP1uiv(index glbase.Attrib, gltype glbase.Enum, normalized bool, value []uint32) {
+ C.gl3_3core_glVertexAttribP1uiv(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribP1ui.xml
+func (gl *GL) VertexAttribP1ui(index glbase.Attrib, gltype glbase.Enum, normalized bool, value uint32) {
+ C.gl3_3core_glVertexAttribP1ui(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSecondaryColorP3uiv.xml
+func (gl *GL) SecondaryColorP3uiv(gltype glbase.Enum, color []uint32) {
+ C.gl3_3core_glSecondaryColorP3uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&color[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSecondaryColorP3ui.xml
+func (gl *GL) SecondaryColorP3ui(gltype glbase.Enum, color uint32) {
+ C.gl3_3core_glSecondaryColorP3ui(gl.funcs, C.GLenum(gltype), C.GLuint(color))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColorP4uiv.xml
+func (gl *GL) ColorP4uiv(gltype glbase.Enum, color []uint32) {
+ C.gl3_3core_glColorP4uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&color[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColorP4ui.xml
+func (gl *GL) ColorP4ui(gltype glbase.Enum, color uint32) {
+ C.gl3_3core_glColorP4ui(gl.funcs, C.GLenum(gltype), C.GLuint(color))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColorP3uiv.xml
+func (gl *GL) ColorP3uiv(gltype glbase.Enum, color []uint32) {
+ C.gl3_3core_glColorP3uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&color[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glColorP3ui.xml
+func (gl *GL) ColorP3ui(gltype glbase.Enum, color uint32) {
+ C.gl3_3core_glColorP3ui(gl.funcs, C.GLenum(gltype), C.GLuint(color))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glNormalP3uiv.xml
+func (gl *GL) NormalP3uiv(gltype glbase.Enum, coords []uint32) {
+ C.gl3_3core_glNormalP3uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glNormalP3ui.xml
+func (gl *GL) NormalP3ui(gltype glbase.Enum, coords uint32) {
+ C.gl3_3core_glNormalP3ui(gl.funcs, C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoordP4uiv.xml
+func (gl *GL) MultiTexCoordP4uiv(texture, gltype glbase.Enum, coords []uint32) {
+ C.gl3_3core_glMultiTexCoordP4uiv(gl.funcs, C.GLenum(texture), C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoordP4ui.xml
+func (gl *GL) MultiTexCoordP4ui(texture, gltype glbase.Enum, coords uint32) {
+ C.gl3_3core_glMultiTexCoordP4ui(gl.funcs, C.GLenum(texture), C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoordP3uiv.xml
+func (gl *GL) MultiTexCoordP3uiv(texture, gltype glbase.Enum, coords []uint32) {
+ C.gl3_3core_glMultiTexCoordP3uiv(gl.funcs, C.GLenum(texture), C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoordP3ui.xml
+func (gl *GL) MultiTexCoordP3ui(texture, gltype glbase.Enum, coords uint32) {
+ C.gl3_3core_glMultiTexCoordP3ui(gl.funcs, C.GLenum(texture), C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoordP2uiv.xml
+func (gl *GL) MultiTexCoordP2uiv(texture, gltype glbase.Enum, coords []uint32) {
+ C.gl3_3core_glMultiTexCoordP2uiv(gl.funcs, C.GLenum(texture), C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoordP2ui.xml
+func (gl *GL) MultiTexCoordP2ui(texture, gltype glbase.Enum, coords uint32) {
+ C.gl3_3core_glMultiTexCoordP2ui(gl.funcs, C.GLenum(texture), C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoordP1uiv.xml
+func (gl *GL) MultiTexCoordP1uiv(texture, gltype glbase.Enum, coords []uint32) {
+ C.gl3_3core_glMultiTexCoordP1uiv(gl.funcs, C.GLenum(texture), C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glMultiTexCoordP1ui.xml
+func (gl *GL) MultiTexCoordP1ui(texture, gltype glbase.Enum, coords uint32) {
+ C.gl3_3core_glMultiTexCoordP1ui(gl.funcs, C.GLenum(texture), C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoordP4uiv.xml
+func (gl *GL) TexCoordP4uiv(gltype glbase.Enum, coords []uint32) {
+ C.gl3_3core_glTexCoordP4uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoordP4ui.xml
+func (gl *GL) TexCoordP4ui(gltype glbase.Enum, coords uint32) {
+ C.gl3_3core_glTexCoordP4ui(gl.funcs, C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoordP3uiv.xml
+func (gl *GL) TexCoordP3uiv(gltype glbase.Enum, coords []uint32) {
+ C.gl3_3core_glTexCoordP3uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoordP3ui.xml
+func (gl *GL) TexCoordP3ui(gltype glbase.Enum, coords uint32) {
+ C.gl3_3core_glTexCoordP3ui(gl.funcs, C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoordP2uiv.xml
+func (gl *GL) TexCoordP2uiv(gltype glbase.Enum, coords []uint32) {
+ C.gl3_3core_glTexCoordP2uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoordP2ui.xml
+func (gl *GL) TexCoordP2ui(gltype glbase.Enum, coords uint32) {
+ C.gl3_3core_glTexCoordP2ui(gl.funcs, C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoordP1uiv.xml
+func (gl *GL) TexCoordP1uiv(gltype glbase.Enum, coords []uint32) {
+ C.gl3_3core_glTexCoordP1uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glTexCoordP1ui.xml
+func (gl *GL) TexCoordP1ui(gltype glbase.Enum, coords uint32) {
+ C.gl3_3core_glTexCoordP1ui(gl.funcs, C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexP4uiv.xml
+func (gl *GL) VertexP4uiv(gltype glbase.Enum, value []uint32) {
+ C.gl3_3core_glVertexP4uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexP4ui.xml
+func (gl *GL) VertexP4ui(gltype glbase.Enum, value uint32) {
+ C.gl3_3core_glVertexP4ui(gl.funcs, C.GLenum(gltype), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexP3uiv.xml
+func (gl *GL) VertexP3uiv(gltype glbase.Enum, value []uint32) {
+ C.gl3_3core_glVertexP3uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexP3ui.xml
+func (gl *GL) VertexP3ui(gltype glbase.Enum, value uint32) {
+ C.gl3_3core_glVertexP3ui(gl.funcs, C.GLenum(gltype), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexP2uiv.xml
+func (gl *GL) VertexP2uiv(gltype glbase.Enum, value []uint32) {
+ C.gl3_3core_glVertexP2uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexP2ui.xml
+func (gl *GL) VertexP2ui(gltype glbase.Enum, value uint32) {
+ C.gl3_3core_glVertexP2ui(gl.funcs, C.GLenum(gltype), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetQueryObjectui64v.xml
+func (gl *GL) GetQueryObjectui64v(id uint32, pname glbase.Enum, params []uint64) {
+ C.gl3_3core_glGetQueryObjectui64v(gl.funcs, C.GLuint(id), C.GLenum(pname), (*C.GLuint64)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetQueryObjecti64v.xml
+func (gl *GL) GetQueryObjecti64v(id uint32, pname glbase.Enum, params []int64) {
+ C.gl3_3core_glGetQueryObjecti64v(gl.funcs, C.GLuint(id), C.GLenum(pname), (*C.GLint64)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glQueryCounter.xml
+func (gl *GL) QueryCounter(id uint32, target glbase.Enum) {
+ C.gl3_3core_glQueryCounter(gl.funcs, C.GLuint(id), C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetSamplerParameterIuiv.xml
+func (gl *GL) GetSamplerParameterIuiv(sampler uint32, pname glbase.Enum, params []uint32) {
+ C.gl3_3core_glGetSamplerParameterIuiv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetSamplerParameterfv.xml
+func (gl *GL) GetSamplerParameterfv(sampler uint32, pname glbase.Enum, params []float32) {
+ C.gl3_3core_glGetSamplerParameterfv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetSamplerParameterIiv.xml
+func (gl *GL) GetSamplerParameterIiv(sampler uint32, pname glbase.Enum, params []int32) {
+ C.gl3_3core_glGetSamplerParameterIiv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetSamplerParameteriv.xml
+func (gl *GL) GetSamplerParameteriv(sampler uint32, pname glbase.Enum, params []int32) {
+ C.gl3_3core_glGetSamplerParameteriv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSamplerParameterIuiv.xml
+func (gl *GL) SamplerParameterIuiv(sampler uint32, pname glbase.Enum, param []uint32) {
+ C.gl3_3core_glSamplerParameterIuiv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&param[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSamplerParameterIiv.xml
+func (gl *GL) SamplerParameterIiv(sampler uint32, pname glbase.Enum, param []int32) {
+ C.gl3_3core_glSamplerParameterIiv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&param[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSamplerParameterfv.xml
+func (gl *GL) SamplerParameterfv(sampler uint32, pname glbase.Enum, param []float32) {
+ C.gl3_3core_glSamplerParameterfv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&param[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSamplerParameterf.xml
+func (gl *GL) SamplerParameterf(sampler uint32, pname glbase.Enum, param float32) {
+ C.gl3_3core_glSamplerParameterf(gl.funcs, C.GLuint(sampler), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSamplerParameteriv.xml
+func (gl *GL) SamplerParameteriv(sampler uint32, pname glbase.Enum, param []int32) {
+ C.gl3_3core_glSamplerParameteriv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&param[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glSamplerParameteri.xml
+func (gl *GL) SamplerParameteri(sampler uint32, pname glbase.Enum, param int32) {
+ C.gl3_3core_glSamplerParameteri(gl.funcs, C.GLuint(sampler), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBindSampler.xml
+func (gl *GL) BindSampler(unit, sampler uint32) {
+ C.gl3_3core_glBindSampler(gl.funcs, C.GLuint(unit), C.GLuint(sampler))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glIsSampler.xml
+func (gl *GL) IsSampler(sampler uint32) bool {
+ glresult := C.gl3_3core_glIsSampler(gl.funcs, C.GLuint(sampler))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glDeleteSamplers.xml
+func (gl *GL) DeleteSamplers(count int, samplers []uint32) {
+ C.gl3_3core_glDeleteSamplers(gl.funcs, C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&samplers[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGenSamplers.xml
+func (gl *GL) GenSamplers(count int, samplers []uint32) {
+ C.gl3_3core_glGenSamplers(gl.funcs, C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&samplers[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glGetFragDataIndex.xml
+func (gl *GL) GetFragDataIndex(program glbase.Program, name []byte) int32 {
+ glresult := C.gl3_3core_glGetFragDataIndex(gl.funcs, C.GLuint(program), (*C.GLchar)(unsafe.Pointer(&name[0])))
+ return int32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glBindFragDataLocationIndexed.xml
+func (gl *GL) BindFragDataLocationIndexed(program glbase.Program, colorNumber, index uint32, name []byte) {
+ C.gl3_3core_glBindFragDataLocationIndexed(gl.funcs, C.GLuint(program), C.GLuint(colorNumber), C.GLuint(index), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man3/xhtml/glVertexAttribDivisor.xml
+func (gl *GL) VertexAttribDivisor(index glbase.Attrib, divisor uint32) {
+ C.gl3_3core_glVertexAttribDivisor(gl.funcs, C.GLuint(index), C.GLuint(divisor))
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.0compat/funcs.cpp b/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.0compat/funcs.cpp
new file mode 100644
index 000000000..1dfaf3f0d
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.0compat/funcs.cpp
@@ -0,0 +1,4764 @@
+
+// ** file automatically generated by glgen -- do not edit manually **
+
+#include <QOpenGLContext>
+#include <QtGui/qopenglfunctions_4_0_compatibility.h>
+
+#include "funcs.h"
+
+void *gl4_0compat_funcs() {
+ QOpenGLFunctions_4_0_Compatibility* funcs = QOpenGLContext::currentContext()->versionFunctions<QOpenGLFunctions_4_0_Compatibility>();
+ if (!funcs) {
+ return 0;
+ }
+ funcs->initializeOpenGLFunctions();
+ return funcs;
+}
+
+
+void gl4_0compat_glViewport(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glViewport(x, y, width, height);
+}
+
+void gl4_0compat_glDepthRange(void *_glfuncs, GLdouble nearVal, GLdouble farVal)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glDepthRange(nearVal, farVal);
+}
+
+GLboolean gl4_0compat_glIsEnabled(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsEnabled(cap);
+}
+
+void gl4_0compat_glGetTexLevelParameteriv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexLevelParameteriv(target, level, pname, params);
+}
+
+void gl4_0compat_glGetTexLevelParameterfv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexLevelParameterfv(target, level, pname, params);
+}
+
+void gl4_0compat_glGetTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexParameteriv(target, pname, params);
+}
+
+void gl4_0compat_glGetTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexParameterfv(target, pname, params);
+}
+
+void gl4_0compat_glGetTexImage(void *_glfuncs, GLenum target, GLint level, GLenum format, GLenum gltype, GLvoid* pixels)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexImage(target, level, format, gltype, pixels);
+}
+
+void gl4_0compat_glGetIntegerv(void *_glfuncs, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetIntegerv(pname, params);
+}
+
+void gl4_0compat_glGetFloatv(void *_glfuncs, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetFloatv(pname, params);
+}
+
+GLenum gl4_0compat_glGetError(void *_glfuncs)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ return _qglfuncs->glGetError();
+}
+
+void gl4_0compat_glGetDoublev(void *_glfuncs, GLenum pname, GLdouble* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetDoublev(pname, params);
+}
+
+void gl4_0compat_glGetBooleanv(void *_glfuncs, GLenum pname, GLboolean* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetBooleanv(pname, params);
+}
+
+void gl4_0compat_glReadPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum gltype, GLvoid* pixels)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glReadPixels(x, y, width, height, format, gltype, pixels);
+}
+
+void gl4_0compat_glReadBuffer(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glReadBuffer(mode);
+}
+
+void gl4_0compat_glPixelStorei(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glPixelStorei(pname, param);
+}
+
+void gl4_0compat_glPixelStoref(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glPixelStoref(pname, param);
+}
+
+void gl4_0compat_glDepthFunc(void *_glfuncs, GLenum glfunc)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glDepthFunc(glfunc);
+}
+
+void gl4_0compat_glStencilOp(void *_glfuncs, GLenum fail, GLenum zfail, GLenum zpass)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glStencilOp(fail, zfail, zpass);
+}
+
+void gl4_0compat_glStencilFunc(void *_glfuncs, GLenum glfunc, GLint ref, GLuint mask)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glStencilFunc(glfunc, ref, mask);
+}
+
+void gl4_0compat_glLogicOp(void *_glfuncs, GLenum opcode)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glLogicOp(opcode);
+}
+
+void gl4_0compat_glBlendFunc(void *_glfuncs, GLenum sfactor, GLenum dfactor)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glBlendFunc(sfactor, dfactor);
+}
+
+void gl4_0compat_glFlush(void *_glfuncs)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glFlush();
+}
+
+void gl4_0compat_glFinish(void *_glfuncs)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glFinish();
+}
+
+void gl4_0compat_glEnable(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glEnable(cap);
+}
+
+void gl4_0compat_glDisable(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glDisable(cap);
+}
+
+void gl4_0compat_glDepthMask(void *_glfuncs, GLboolean flag)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glDepthMask(flag);
+}
+
+void gl4_0compat_glColorMask(void *_glfuncs, GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorMask(red, green, blue, alpha);
+}
+
+void gl4_0compat_glStencilMask(void *_glfuncs, GLuint mask)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glStencilMask(mask);
+}
+
+void gl4_0compat_glClearDepth(void *_glfuncs, GLdouble depth)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glClearDepth(depth);
+}
+
+void gl4_0compat_glClearStencil(void *_glfuncs, GLint s)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glClearStencil(s);
+}
+
+void gl4_0compat_glClearColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glClearColor(red, green, blue, alpha);
+}
+
+void gl4_0compat_glClear(void *_glfuncs, GLbitfield mask)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glClear(mask);
+}
+
+void gl4_0compat_glDrawBuffer(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawBuffer(mode);
+}
+
+void gl4_0compat_glTexImage2D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexImage2D(target, level, internalFormat, width, height, border, format, gltype, pixels);
+}
+
+void gl4_0compat_glTexImage1D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexImage1D(target, level, internalFormat, width, border, format, gltype, pixels);
+}
+
+void gl4_0compat_glTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexParameteriv(target, pname, params);
+}
+
+void gl4_0compat_glTexParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexParameteri(target, pname, param);
+}
+
+void gl4_0compat_glTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexParameterfv(target, pname, params);
+}
+
+void gl4_0compat_glTexParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexParameterf(target, pname, param);
+}
+
+void gl4_0compat_glScissor(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glScissor(x, y, width, height);
+}
+
+void gl4_0compat_glPolygonMode(void *_glfuncs, GLenum face, GLenum mode)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glPolygonMode(face, mode);
+}
+
+void gl4_0compat_glPointSize(void *_glfuncs, GLfloat size)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glPointSize(size);
+}
+
+void gl4_0compat_glLineWidth(void *_glfuncs, GLfloat width)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glLineWidth(width);
+}
+
+void gl4_0compat_glHint(void *_glfuncs, GLenum target, GLenum mode)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glHint(target, mode);
+}
+
+void gl4_0compat_glFrontFace(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glFrontFace(mode);
+}
+
+void gl4_0compat_glCullFace(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glCullFace(mode);
+}
+
+void gl4_0compat_glIndexubv(void *_glfuncs, const GLubyte* c)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexubv(c);
+}
+
+void gl4_0compat_glIndexub(void *_glfuncs, GLubyte c)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexub(c);
+}
+
+GLboolean gl4_0compat_glIsTexture(void *_glfuncs, GLuint texture)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsTexture(texture);
+}
+
+void gl4_0compat_glGenTextures(void *_glfuncs, GLsizei n, GLuint* textures)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGenTextures(n, textures);
+}
+
+void gl4_0compat_glDeleteTextures(void *_glfuncs, GLsizei n, const GLuint* textures)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteTextures(n, textures);
+}
+
+void gl4_0compat_glBindTexture(void *_glfuncs, GLenum target, GLuint texture)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindTexture(target, texture);
+}
+
+void gl4_0compat_glTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexSubImage2D(target, level, xoffset, yoffset, width, height, format, gltype, pixels);
+}
+
+void gl4_0compat_glTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexSubImage1D(target, level, xoffset, width, format, gltype, pixels);
+}
+
+void gl4_0compat_glCopyTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage2D(target, level, xoffset, yoffset, x, y, width, height);
+}
+
+void gl4_0compat_glCopyTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage1D(target, level, xoffset, x, y, width);
+}
+
+void gl4_0compat_glCopyTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyTexImage2D(target, level, internalFormat, x, y, width, height, border);
+}
+
+void gl4_0compat_glCopyTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLint border)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyTexImage1D(target, level, internalFormat, x, y, width, border);
+}
+
+void gl4_0compat_glPolygonOffset(void *_glfuncs, GLfloat factor, GLfloat units)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glPolygonOffset(factor, units);
+}
+
+void gl4_0compat_glDrawElements(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawElements(mode, count, gltype, indices);
+}
+
+void gl4_0compat_glDrawArrays(void *_glfuncs, GLenum mode, GLint first, GLsizei count)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawArrays(mode, first, count);
+}
+
+void gl4_0compat_glCopyTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage3D(target, level, xoffset, yoffset, zoffset, x, y, width, height);
+}
+
+void gl4_0compat_glTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, gltype, pixels);
+}
+
+void gl4_0compat_glTexImage3D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexImage3D(target, level, internalFormat, width, height, depth, border, format, gltype, pixels);
+}
+
+void gl4_0compat_glDrawRangeElements(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawRangeElements(mode, start, end, count, gltype, indices);
+}
+
+void gl4_0compat_glBlendEquation(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glBlendEquation(mode);
+}
+
+void gl4_0compat_glBlendColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glBlendColor(red, green, blue, alpha);
+}
+
+void gl4_0compat_glGetCompressedTexImage(void *_glfuncs, GLenum target, GLint level, GLvoid* img)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetCompressedTexImage(target, level, img);
+}
+
+void gl4_0compat_glCompressedTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glCompressedTexSubImage1D(target, level, xoffset, width, format, imageSize, data);
+}
+
+void gl4_0compat_glCompressedTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glCompressedTexSubImage2D(target, level, xoffset, yoffset, width, height, format, imageSize, data);
+}
+
+void gl4_0compat_glCompressedTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glCompressedTexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, imageSize, data);
+}
+
+void gl4_0compat_glCompressedTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glCompressedTexImage1D(target, level, internalFormat, width, border, imageSize, data);
+}
+
+void gl4_0compat_glCompressedTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glCompressedTexImage2D(target, level, internalFormat, width, height, border, imageSize, data);
+}
+
+void gl4_0compat_glCompressedTexImage3D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glCompressedTexImage3D(target, level, internalFormat, width, height, depth, border, imageSize, data);
+}
+
+void gl4_0compat_glSampleCoverage(void *_glfuncs, GLfloat value, GLboolean invert)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glSampleCoverage(value, invert);
+}
+
+void gl4_0compat_glActiveTexture(void *_glfuncs, GLenum texture)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glActiveTexture(texture);
+}
+
+void gl4_0compat_glPointParameteriv(void *_glfuncs, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glPointParameteriv(pname, params);
+}
+
+void gl4_0compat_glPointParameteri(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glPointParameteri(pname, param);
+}
+
+void gl4_0compat_glPointParameterfv(void *_glfuncs, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glPointParameterfv(pname, params);
+}
+
+void gl4_0compat_glPointParameterf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glPointParameterf(pname, param);
+}
+
+void gl4_0compat_glMultiDrawArrays(void *_glfuncs, GLenum mode, const GLint* first, const GLsizei* count, GLsizei drawcount)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiDrawArrays(mode, first, count, drawcount);
+}
+
+void gl4_0compat_glBlendFuncSeparate(void *_glfuncs, GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glBlendFuncSeparate(sfactorRGB, dfactorRGB, sfactorAlpha, dfactorAlpha);
+}
+
+void gl4_0compat_glGetBufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetBufferParameteriv(target, pname, params);
+}
+
+GLboolean gl4_0compat_glUnmapBuffer(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ return _qglfuncs->glUnmapBuffer(target);
+}
+
+void gl4_0compat_glGetBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, GLvoid* data)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetBufferSubData(target, offset, size, data);
+}
+
+void gl4_0compat_glBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid* data)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glBufferSubData(target, offset, size, data);
+}
+
+void gl4_0compat_glBufferData(void *_glfuncs, GLenum target, GLsizeiptr size, const GLvoid* data, GLenum usage)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glBufferData(target, size, data, usage);
+}
+
+GLboolean gl4_0compat_glIsBuffer(void *_glfuncs, GLuint buffer)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsBuffer(buffer);
+}
+
+void gl4_0compat_glGenBuffers(void *_glfuncs, GLsizei n, GLuint* buffers)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGenBuffers(n, buffers);
+}
+
+void gl4_0compat_glDeleteBuffers(void *_glfuncs, GLsizei n, const GLuint* buffers)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteBuffers(n, buffers);
+}
+
+void gl4_0compat_glBindBuffer(void *_glfuncs, GLenum target, GLuint buffer)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindBuffer(target, buffer);
+}
+
+void gl4_0compat_glGetQueryObjectuiv(void *_glfuncs, GLuint id, GLenum pname, GLuint* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetQueryObjectuiv(id, pname, params);
+}
+
+void gl4_0compat_glGetQueryObjectiv(void *_glfuncs, GLuint id, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetQueryObjectiv(id, pname, params);
+}
+
+void gl4_0compat_glGetQueryiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetQueryiv(target, pname, params);
+}
+
+void gl4_0compat_glEndQuery(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glEndQuery(target);
+}
+
+void gl4_0compat_glBeginQuery(void *_glfuncs, GLenum target, GLuint id)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glBeginQuery(target, id);
+}
+
+GLboolean gl4_0compat_glIsQuery(void *_glfuncs, GLuint id)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsQuery(id);
+}
+
+void gl4_0compat_glDeleteQueries(void *_glfuncs, GLsizei n, const GLuint* ids)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteQueries(n, ids);
+}
+
+void gl4_0compat_glGenQueries(void *_glfuncs, GLsizei n, GLuint* ids)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGenQueries(n, ids);
+}
+
+void gl4_0compat_glVertexAttribPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLboolean normalized, GLsizei stride, const GLvoid* offset)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribPointer(index, size, gltype, normalized, stride, offset);
+}
+
+void gl4_0compat_glValidateProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glValidateProgram(program);
+}
+
+void gl4_0compat_glUniformMatrix4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4fv(location, count, transpose, value);
+}
+
+void gl4_0compat_glUniformMatrix3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3fv(location, count, transpose, value);
+}
+
+void gl4_0compat_glUniformMatrix2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2fv(location, count, transpose, value);
+}
+
+void gl4_0compat_glUniform4iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform4iv(location, count, value);
+}
+
+void gl4_0compat_glUniform3iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform3iv(location, count, value);
+}
+
+void gl4_0compat_glUniform2iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform2iv(location, count, value);
+}
+
+void gl4_0compat_glUniform1iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform1iv(location, count, value);
+}
+
+void gl4_0compat_glUniform4fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform4fv(location, count, value);
+}
+
+void gl4_0compat_glUniform3fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform3fv(location, count, value);
+}
+
+void gl4_0compat_glUniform2fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform2fv(location, count, value);
+}
+
+void gl4_0compat_glUniform1fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform1fv(location, count, value);
+}
+
+void gl4_0compat_glUniform4i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2, GLint v3)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform4i(location, v0, v1, v2, v3);
+}
+
+void gl4_0compat_glUniform3i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform3i(location, v0, v1, v2);
+}
+
+void gl4_0compat_glUniform2i(void *_glfuncs, GLint location, GLint v0, GLint v1)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform2i(location, v0, v1);
+}
+
+void gl4_0compat_glUniform1i(void *_glfuncs, GLint location, GLint v0)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform1i(location, v0);
+}
+
+void gl4_0compat_glUniform4f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform4f(location, v0, v1, v2, v3);
+}
+
+void gl4_0compat_glUniform3f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform3f(location, v0, v1, v2);
+}
+
+void gl4_0compat_glUniform2f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform2f(location, v0, v1);
+}
+
+void gl4_0compat_glUniform1f(void *_glfuncs, GLint location, GLfloat v0)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform1f(location, v0);
+}
+
+void gl4_0compat_glUseProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glUseProgram(program);
+}
+
+void gl4_0compat_glShaderSource(void *_glfuncs, GLuint shader, GLsizei count, const GLchar** source, const GLint* length)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glShaderSource(shader, count, source, length);
+}
+
+void gl4_0compat_glLinkProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glLinkProgram(program);
+}
+
+GLboolean gl4_0compat_glIsShader(void *_glfuncs, GLuint shader)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsShader(shader);
+}
+
+GLboolean gl4_0compat_glIsProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsProgram(program);
+}
+
+void gl4_0compat_glGetVertexAttribiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribiv(index, pname, params);
+}
+
+void gl4_0compat_glGetVertexAttribfv(void *_glfuncs, GLuint index, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribfv(index, pname, params);
+}
+
+void gl4_0compat_glGetVertexAttribdv(void *_glfuncs, GLuint index, GLenum pname, GLdouble* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribdv(index, pname, params);
+}
+
+void gl4_0compat_glGetUniformiv(void *_glfuncs, GLuint program, GLint location, GLint* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetUniformiv(program, location, params);
+}
+
+void gl4_0compat_glGetUniformfv(void *_glfuncs, GLuint program, GLint location, GLfloat* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetUniformfv(program, location, params);
+}
+
+GLint gl4_0compat_glGetUniformLocation(void *_glfuncs, GLuint program, const GLchar* name)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ return _qglfuncs->glGetUniformLocation(program, name);
+}
+
+void gl4_0compat_glGetShaderSource(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* source)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetShaderSource(shader, bufSize, length, source);
+}
+
+void gl4_0compat_glGetShaderInfoLog(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* infoLog)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetShaderInfoLog(shader, bufSize, length, infoLog);
+}
+
+void gl4_0compat_glGetShaderiv(void *_glfuncs, GLuint shader, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetShaderiv(shader, pname, params);
+}
+
+void gl4_0compat_glGetProgramInfoLog(void *_glfuncs, GLuint program, GLsizei bufSize, GLsizei* length, GLchar* infoLog)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetProgramInfoLog(program, bufSize, length, infoLog);
+}
+
+void gl4_0compat_glGetProgramiv(void *_glfuncs, GLuint program, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetProgramiv(program, pname, params);
+}
+
+GLint gl4_0compat_glGetAttribLocation(void *_glfuncs, GLuint program, const GLchar* name)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ return _qglfuncs->glGetAttribLocation(program, name);
+}
+
+void gl4_0compat_glGetAttachedShaders(void *_glfuncs, GLuint program, GLsizei maxCount, GLsizei* count, GLuint* obj)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetAttachedShaders(program, maxCount, count, obj);
+}
+
+void gl4_0compat_glGetActiveUniform(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetActiveUniform(program, index, bufSize, length, size, gltype, name);
+}
+
+void gl4_0compat_glGetActiveAttrib(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetActiveAttrib(program, index, bufSize, length, size, gltype, name);
+}
+
+void gl4_0compat_glEnableVertexAttribArray(void *_glfuncs, GLuint index)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glEnableVertexAttribArray(index);
+}
+
+void gl4_0compat_glDisableVertexAttribArray(void *_glfuncs, GLuint index)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glDisableVertexAttribArray(index);
+}
+
+void gl4_0compat_glDetachShader(void *_glfuncs, GLuint program, GLuint shader)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glDetachShader(program, shader);
+}
+
+void gl4_0compat_glDeleteShader(void *_glfuncs, GLuint shader)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteShader(shader);
+}
+
+void gl4_0compat_glDeleteProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteProgram(program);
+}
+
+GLuint gl4_0compat_glCreateShader(void *_glfuncs, GLenum gltype)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ return _qglfuncs->glCreateShader(gltype);
+}
+
+GLuint gl4_0compat_glCreateProgram(void *_glfuncs)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ return _qglfuncs->glCreateProgram();
+}
+
+void gl4_0compat_glCompileShader(void *_glfuncs, GLuint shader)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glCompileShader(shader);
+}
+
+void gl4_0compat_glBindAttribLocation(void *_glfuncs, GLuint program, GLuint index, const GLchar* name)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindAttribLocation(program, index, name);
+}
+
+void gl4_0compat_glAttachShader(void *_glfuncs, GLuint program, GLuint shader)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glAttachShader(program, shader);
+}
+
+void gl4_0compat_glStencilMaskSeparate(void *_glfuncs, GLenum face, GLuint mask)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glStencilMaskSeparate(face, mask);
+}
+
+void gl4_0compat_glStencilFuncSeparate(void *_glfuncs, GLenum face, GLenum glfunc, GLint ref, GLuint mask)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glStencilFuncSeparate(face, glfunc, ref, mask);
+}
+
+void gl4_0compat_glStencilOpSeparate(void *_glfuncs, GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glStencilOpSeparate(face, sfail, dpfail, dppass);
+}
+
+void gl4_0compat_glDrawBuffers(void *_glfuncs, GLsizei n, const GLenum* bufs)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawBuffers(n, bufs);
+}
+
+void gl4_0compat_glBlendEquationSeparate(void *_glfuncs, GLenum modeRGB, GLenum modeAlpha)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glBlendEquationSeparate(modeRGB, modeAlpha);
+}
+
+void gl4_0compat_glUniformMatrix4x3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4x3fv(location, count, transpose, value);
+}
+
+void gl4_0compat_glUniformMatrix3x4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3x4fv(location, count, transpose, value);
+}
+
+void gl4_0compat_glUniformMatrix4x2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4x2fv(location, count, transpose, value);
+}
+
+void gl4_0compat_glUniformMatrix2x4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2x4fv(location, count, transpose, value);
+}
+
+void gl4_0compat_glUniformMatrix3x2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3x2fv(location, count, transpose, value);
+}
+
+void gl4_0compat_glUniformMatrix2x3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2x3fv(location, count, transpose, value);
+}
+
+GLboolean gl4_0compat_glIsVertexArray(void *_glfuncs, GLuint array)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsVertexArray(array);
+}
+
+void gl4_0compat_glGenVertexArrays(void *_glfuncs, GLsizei n, GLuint* arrays)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGenVertexArrays(n, arrays);
+}
+
+void gl4_0compat_glDeleteVertexArrays(void *_glfuncs, GLsizei n, const GLuint* arrays)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteVertexArrays(n, arrays);
+}
+
+void gl4_0compat_glBindVertexArray(void *_glfuncs, GLuint array)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindVertexArray(array);
+}
+
+void gl4_0compat_glFlushMappedBufferRange(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr length)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glFlushMappedBufferRange(target, offset, length);
+}
+
+void gl4_0compat_glFramebufferTextureLayer(void *_glfuncs, GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glFramebufferTextureLayer(target, attachment, texture, level, layer);
+}
+
+void gl4_0compat_glRenderbufferStorageMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLenum internalFormat, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glRenderbufferStorageMultisample(target, samples, internalFormat, width, height);
+}
+
+void gl4_0compat_glBlitFramebuffer(void *_glfuncs, GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glBlitFramebuffer(srcX0, srcY0, srcX1, srcY1, dstX0, dstY0, dstX1, dstY1, mask, filter);
+}
+
+void gl4_0compat_glGenerateMipmap(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGenerateMipmap(target);
+}
+
+void gl4_0compat_glGetFramebufferAttachmentParameteriv(void *_glfuncs, GLenum target, GLenum attachment, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetFramebufferAttachmentParameteriv(target, attachment, pname, params);
+}
+
+void gl4_0compat_glFramebufferRenderbuffer(void *_glfuncs, GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glFramebufferRenderbuffer(target, attachment, renderbuffertarget, renderbuffer);
+}
+
+void gl4_0compat_glFramebufferTexture3D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glFramebufferTexture3D(target, attachment, textarget, texture, level, zoffset);
+}
+
+void gl4_0compat_glFramebufferTexture2D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glFramebufferTexture2D(target, attachment, textarget, texture, level);
+}
+
+void gl4_0compat_glFramebufferTexture1D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glFramebufferTexture1D(target, attachment, textarget, texture, level);
+}
+
+GLenum gl4_0compat_glCheckFramebufferStatus(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ return _qglfuncs->glCheckFramebufferStatus(target);
+}
+
+void gl4_0compat_glGenFramebuffers(void *_glfuncs, GLsizei n, GLuint* framebuffers)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGenFramebuffers(n, framebuffers);
+}
+
+void gl4_0compat_glDeleteFramebuffers(void *_glfuncs, GLsizei n, const GLuint* framebuffers)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteFramebuffers(n, framebuffers);
+}
+
+void gl4_0compat_glBindFramebuffer(void *_glfuncs, GLenum target, GLuint framebuffer)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindFramebuffer(target, framebuffer);
+}
+
+GLboolean gl4_0compat_glIsFramebuffer(void *_glfuncs, GLuint framebuffer)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsFramebuffer(framebuffer);
+}
+
+void gl4_0compat_glGetRenderbufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetRenderbufferParameteriv(target, pname, params);
+}
+
+void gl4_0compat_glRenderbufferStorage(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glRenderbufferStorage(target, internalFormat, width, height);
+}
+
+void gl4_0compat_glGenRenderbuffers(void *_glfuncs, GLsizei n, GLuint* renderbuffers)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGenRenderbuffers(n, renderbuffers);
+}
+
+void gl4_0compat_glDeleteRenderbuffers(void *_glfuncs, GLsizei n, const GLuint* renderbuffers)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteRenderbuffers(n, renderbuffers);
+}
+
+void gl4_0compat_glBindRenderbuffer(void *_glfuncs, GLenum target, GLuint renderbuffer)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindRenderbuffer(target, renderbuffer);
+}
+
+GLboolean gl4_0compat_glIsRenderbuffer(void *_glfuncs, GLuint renderbuffer)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsRenderbuffer(renderbuffer);
+}
+
+void gl4_0compat_glClearBufferfi(void *_glfuncs, GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glClearBufferfi(buffer, drawbuffer, depth, stencil);
+}
+
+void gl4_0compat_glClearBufferfv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLfloat* value)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glClearBufferfv(buffer, drawbuffer, value);
+}
+
+void gl4_0compat_glClearBufferuiv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLuint* value)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glClearBufferuiv(buffer, drawbuffer, value);
+}
+
+void gl4_0compat_glClearBufferiv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLint* value)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glClearBufferiv(buffer, drawbuffer, value);
+}
+
+void gl4_0compat_glGetTexParameterIuiv(void *_glfuncs, GLenum target, GLenum pname, GLuint* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexParameterIuiv(target, pname, params);
+}
+
+void gl4_0compat_glGetTexParameterIiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexParameterIiv(target, pname, params);
+}
+
+void gl4_0compat_glTexParameterIuiv(void *_glfuncs, GLenum target, GLenum pname, const GLuint* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexParameterIuiv(target, pname, params);
+}
+
+void gl4_0compat_glTexParameterIiv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexParameterIiv(target, pname, params);
+}
+
+void gl4_0compat_glUniform4uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform4uiv(location, count, value);
+}
+
+void gl4_0compat_glUniform3uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform3uiv(location, count, value);
+}
+
+void gl4_0compat_glUniform2uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform2uiv(location, count, value);
+}
+
+void gl4_0compat_glUniform1uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform1uiv(location, count, value);
+}
+
+void gl4_0compat_glUniform4ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform4ui(location, v0, v1, v2, v3);
+}
+
+void gl4_0compat_glUniform3ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1, GLuint v2)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform3ui(location, v0, v1, v2);
+}
+
+void gl4_0compat_glUniform2ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform2ui(location, v0, v1);
+}
+
+void gl4_0compat_glUniform1ui(void *_glfuncs, GLint location, GLuint v0)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform1ui(location, v0);
+}
+
+GLint gl4_0compat_glGetFragDataLocation(void *_glfuncs, GLuint program, const GLchar* name)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ return _qglfuncs->glGetFragDataLocation(program, name);
+}
+
+void gl4_0compat_glBindFragDataLocation(void *_glfuncs, GLuint program, GLuint color, const GLchar* name)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindFragDataLocation(program, color, name);
+}
+
+void gl4_0compat_glGetUniformuiv(void *_glfuncs, GLuint program, GLint location, GLuint* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetUniformuiv(program, location, params);
+}
+
+void gl4_0compat_glGetVertexAttribIuiv(void *_glfuncs, GLuint index, GLenum pname, GLuint* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribIuiv(index, pname, params);
+}
+
+void gl4_0compat_glGetVertexAttribIiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribIiv(index, pname, params);
+}
+
+void gl4_0compat_glVertexAttribIPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribIPointer(index, size, gltype, stride, pointer);
+}
+
+void gl4_0compat_glEndConditionalRender(void *_glfuncs)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glEndConditionalRender();
+}
+
+void gl4_0compat_glBeginConditionalRender(void *_glfuncs, GLuint id, GLenum mode)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glBeginConditionalRender(id, mode);
+}
+
+void gl4_0compat_glClampColor(void *_glfuncs, GLenum target, GLenum clamp)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glClampColor(target, clamp);
+}
+
+void gl4_0compat_glGetTransformFeedbackVarying(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLsizei* size, GLenum* gltype, GLchar* name)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTransformFeedbackVarying(program, index, bufSize, length, size, gltype, name);
+}
+
+void gl4_0compat_glBindBufferBase(void *_glfuncs, GLenum target, GLuint index, GLuint buffer)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindBufferBase(target, index, buffer);
+}
+
+void gl4_0compat_glBindBufferRange(void *_glfuncs, GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindBufferRange(target, index, buffer, offset, size);
+}
+
+void gl4_0compat_glEndTransformFeedback(void *_glfuncs)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glEndTransformFeedback();
+}
+
+void gl4_0compat_glBeginTransformFeedback(void *_glfuncs, GLenum primitiveMode)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glBeginTransformFeedback(primitiveMode);
+}
+
+GLboolean gl4_0compat_glIsEnabledi(void *_glfuncs, GLenum target, GLuint index)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsEnabledi(target, index);
+}
+
+void gl4_0compat_glDisablei(void *_glfuncs, GLenum target, GLuint index)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glDisablei(target, index);
+}
+
+void gl4_0compat_glEnablei(void *_glfuncs, GLenum target, GLuint index)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glEnablei(target, index);
+}
+
+void gl4_0compat_glGetIntegeri_v(void *_glfuncs, GLenum target, GLuint index, GLint* data)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetIntegeri_v(target, index, data);
+}
+
+void gl4_0compat_glGetBooleani_v(void *_glfuncs, GLenum target, GLuint index, GLboolean* data)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetBooleani_v(target, index, data);
+}
+
+void gl4_0compat_glColorMaski(void *_glfuncs, GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorMaski(index, r, g, b, a);
+}
+
+void gl4_0compat_glCopyBufferSubData(void *_glfuncs, GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyBufferSubData(readTarget, writeTarget, readOffset, writeOffset, size);
+}
+
+void gl4_0compat_glUniformBlockBinding(void *_glfuncs, GLuint program, GLuint v0, GLuint v1)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformBlockBinding(program, v0, v1);
+}
+
+void gl4_0compat_glGetActiveUniformBlockName(void *_glfuncs, GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei* length, GLchar* uniformBlockName)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetActiveUniformBlockName(program, uniformBlockIndex, bufSize, length, uniformBlockName);
+}
+
+void gl4_0compat_glGetActiveUniformBlockiv(void *_glfuncs, GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetActiveUniformBlockiv(program, uniformBlockIndex, pname, params);
+}
+
+GLuint gl4_0compat_glGetUniformBlockIndex(void *_glfuncs, GLuint program, const GLchar* uniformBlockName)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ return _qglfuncs->glGetUniformBlockIndex(program, uniformBlockName);
+}
+
+void gl4_0compat_glGetActiveUniformName(void *_glfuncs, GLuint program, GLuint uniformIndex, GLsizei bufSize, GLsizei* length, GLchar* uniformName)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetActiveUniformName(program, uniformIndex, bufSize, length, uniformName);
+}
+
+void gl4_0compat_glGetActiveUniformsiv(void *_glfuncs, GLuint program, GLsizei uniformCount, const GLuint* uniformIndices, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetActiveUniformsiv(program, uniformCount, uniformIndices, pname, params);
+}
+
+void gl4_0compat_glPrimitiveRestartIndex(void *_glfuncs, GLuint index)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glPrimitiveRestartIndex(index);
+}
+
+void gl4_0compat_glTexBuffer(void *_glfuncs, GLenum target, GLenum internalFormat, GLuint buffer)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexBuffer(target, internalFormat, buffer);
+}
+
+void gl4_0compat_glDrawElementsInstanced(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawElementsInstanced(mode, count, gltype, indices, instancecount);
+}
+
+void gl4_0compat_glDrawArraysInstanced(void *_glfuncs, GLenum mode, GLint first, GLsizei count, GLsizei instancecount)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawArraysInstanced(mode, first, count, instancecount);
+}
+
+void gl4_0compat_glSampleMaski(void *_glfuncs, GLuint index, GLbitfield mask)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glSampleMaski(index, mask);
+}
+
+void gl4_0compat_glGetMultisamplefv(void *_glfuncs, GLenum pname, GLuint index, GLfloat* val)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetMultisamplefv(pname, index, val);
+}
+
+void gl4_0compat_glTexImage3DMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexImage3DMultisample(target, samples, internalFormat, width, height, depth, fixedsamplelocations);
+}
+
+void gl4_0compat_glTexImage2DMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLint internalFormat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexImage2DMultisample(target, samples, internalFormat, width, height, fixedsamplelocations);
+}
+
+void gl4_0compat_glGetSynciv(void *_glfuncs, GLsync sync, GLenum pname, GLsizei bufSize, GLsizei* length, GLint* values)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetSynciv(sync, pname, bufSize, length, values);
+}
+
+void gl4_0compat_glGetInteger64v(void *_glfuncs, GLenum pname, GLint64* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetInteger64v(pname, params);
+}
+
+void gl4_0compat_glWaitSync(void *_glfuncs, GLsync sync, GLbitfield flags, GLuint64 timeout)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glWaitSync(sync, flags, timeout);
+}
+
+GLenum gl4_0compat_glClientWaitSync(void *_glfuncs, GLsync sync, GLbitfield flags, GLuint64 timeout)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ return _qglfuncs->glClientWaitSync(sync, flags, timeout);
+}
+
+void gl4_0compat_glDeleteSync(void *_glfuncs, GLsync sync)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteSync(sync);
+}
+
+GLboolean gl4_0compat_glIsSync(void *_glfuncs, GLsync sync)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsSync(sync);
+}
+
+GLsync gl4_0compat_glFenceSync(void *_glfuncs, GLenum condition, GLbitfield flags)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ return _qglfuncs->glFenceSync(condition, flags);
+}
+
+void gl4_0compat_glProvokingVertex(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glProvokingVertex(mode);
+}
+
+void gl4_0compat_glDrawElementsInstancedBaseVertex(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount, GLint basevertex)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawElementsInstancedBaseVertex(mode, count, gltype, indices, instancecount, basevertex);
+}
+
+void gl4_0compat_glDrawRangeElementsBaseVertex(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices, GLint basevertex)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawRangeElementsBaseVertex(mode, start, end, count, gltype, indices, basevertex);
+}
+
+void gl4_0compat_glDrawElementsBaseVertex(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLint basevertex)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawElementsBaseVertex(mode, count, gltype, indices, basevertex);
+}
+
+void gl4_0compat_glFramebufferTexture(void *_glfuncs, GLenum target, GLenum attachment, GLuint texture, GLint level)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glFramebufferTexture(target, attachment, texture, level);
+}
+
+void gl4_0compat_glGetBufferParameteri64v(void *_glfuncs, GLenum target, GLenum pname, GLint64* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetBufferParameteri64v(target, pname, params);
+}
+
+void gl4_0compat_glGetInteger64i_v(void *_glfuncs, GLenum target, GLuint index, GLint64* data)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetInteger64i_v(target, index, data);
+}
+
+void gl4_0compat_glVertexAttribP4uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribP4uiv(index, gltype, normalized, value);
+}
+
+void gl4_0compat_glVertexAttribP4ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribP4ui(index, gltype, normalized, value);
+}
+
+void gl4_0compat_glVertexAttribP3uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribP3uiv(index, gltype, normalized, value);
+}
+
+void gl4_0compat_glVertexAttribP3ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribP3ui(index, gltype, normalized, value);
+}
+
+void gl4_0compat_glVertexAttribP2uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribP2uiv(index, gltype, normalized, value);
+}
+
+void gl4_0compat_glVertexAttribP2ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribP2ui(index, gltype, normalized, value);
+}
+
+void gl4_0compat_glVertexAttribP1uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribP1uiv(index, gltype, normalized, value);
+}
+
+void gl4_0compat_glVertexAttribP1ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribP1ui(index, gltype, normalized, value);
+}
+
+void gl4_0compat_glSecondaryColorP3uiv(void *_glfuncs, GLenum gltype, const GLuint* color)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColorP3uiv(gltype, color);
+}
+
+void gl4_0compat_glSecondaryColorP3ui(void *_glfuncs, GLenum gltype, GLuint color)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColorP3ui(gltype, color);
+}
+
+void gl4_0compat_glColorP4uiv(void *_glfuncs, GLenum gltype, const GLuint* color)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorP4uiv(gltype, color);
+}
+
+void gl4_0compat_glColorP4ui(void *_glfuncs, GLenum gltype, GLuint color)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorP4ui(gltype, color);
+}
+
+void gl4_0compat_glColorP3uiv(void *_glfuncs, GLenum gltype, const GLuint* color)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorP3uiv(gltype, color);
+}
+
+void gl4_0compat_glColorP3ui(void *_glfuncs, GLenum gltype, GLuint color)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorP3ui(gltype, color);
+}
+
+void gl4_0compat_glNormalP3uiv(void *_glfuncs, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormalP3uiv(gltype, coords);
+}
+
+void gl4_0compat_glNormalP3ui(void *_glfuncs, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormalP3ui(gltype, coords);
+}
+
+void gl4_0compat_glMultiTexCoordP4uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP4uiv(texture, gltype, coords);
+}
+
+void gl4_0compat_glMultiTexCoordP4ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP4ui(texture, gltype, coords);
+}
+
+void gl4_0compat_glMultiTexCoordP3uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP3uiv(texture, gltype, coords);
+}
+
+void gl4_0compat_glMultiTexCoordP3ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP3ui(texture, gltype, coords);
+}
+
+void gl4_0compat_glMultiTexCoordP2uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP2uiv(texture, gltype, coords);
+}
+
+void gl4_0compat_glMultiTexCoordP2ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP2ui(texture, gltype, coords);
+}
+
+void gl4_0compat_glMultiTexCoordP1uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP1uiv(texture, gltype, coords);
+}
+
+void gl4_0compat_glMultiTexCoordP1ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP1ui(texture, gltype, coords);
+}
+
+void gl4_0compat_glTexCoordP4uiv(void *_glfuncs, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoordP4uiv(gltype, coords);
+}
+
+void gl4_0compat_glTexCoordP4ui(void *_glfuncs, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoordP4ui(gltype, coords);
+}
+
+void gl4_0compat_glTexCoordP3uiv(void *_glfuncs, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoordP3uiv(gltype, coords);
+}
+
+void gl4_0compat_glTexCoordP3ui(void *_glfuncs, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoordP3ui(gltype, coords);
+}
+
+void gl4_0compat_glTexCoordP2uiv(void *_glfuncs, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoordP2uiv(gltype, coords);
+}
+
+void gl4_0compat_glTexCoordP2ui(void *_glfuncs, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoordP2ui(gltype, coords);
+}
+
+void gl4_0compat_glTexCoordP1uiv(void *_glfuncs, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoordP1uiv(gltype, coords);
+}
+
+void gl4_0compat_glTexCoordP1ui(void *_glfuncs, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoordP1ui(gltype, coords);
+}
+
+void gl4_0compat_glVertexP4uiv(void *_glfuncs, GLenum gltype, const GLuint* value)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexP4uiv(gltype, value);
+}
+
+void gl4_0compat_glVertexP4ui(void *_glfuncs, GLenum gltype, GLuint value)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexP4ui(gltype, value);
+}
+
+void gl4_0compat_glVertexP3uiv(void *_glfuncs, GLenum gltype, const GLuint* value)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexP3uiv(gltype, value);
+}
+
+void gl4_0compat_glVertexP3ui(void *_glfuncs, GLenum gltype, GLuint value)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexP3ui(gltype, value);
+}
+
+void gl4_0compat_glVertexP2uiv(void *_glfuncs, GLenum gltype, const GLuint* value)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexP2uiv(gltype, value);
+}
+
+void gl4_0compat_glVertexP2ui(void *_glfuncs, GLenum gltype, GLuint value)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexP2ui(gltype, value);
+}
+
+void gl4_0compat_glGetQueryObjectui64v(void *_glfuncs, GLuint id, GLenum pname, GLuint64* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetQueryObjectui64v(id, pname, params);
+}
+
+void gl4_0compat_glGetQueryObjecti64v(void *_glfuncs, GLuint id, GLenum pname, GLint64* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetQueryObjecti64v(id, pname, params);
+}
+
+void gl4_0compat_glQueryCounter(void *_glfuncs, GLuint id, GLenum target)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glQueryCounter(id, target);
+}
+
+void gl4_0compat_glGetSamplerParameterIuiv(void *_glfuncs, GLuint sampler, GLenum pname, GLuint* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetSamplerParameterIuiv(sampler, pname, params);
+}
+
+void gl4_0compat_glGetSamplerParameterfv(void *_glfuncs, GLuint sampler, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetSamplerParameterfv(sampler, pname, params);
+}
+
+void gl4_0compat_glGetSamplerParameterIiv(void *_glfuncs, GLuint sampler, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetSamplerParameterIiv(sampler, pname, params);
+}
+
+void gl4_0compat_glGetSamplerParameteriv(void *_glfuncs, GLuint sampler, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetSamplerParameteriv(sampler, pname, params);
+}
+
+void gl4_0compat_glSamplerParameterIuiv(void *_glfuncs, GLuint sampler, GLenum pname, const GLuint* param)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glSamplerParameterIuiv(sampler, pname, param);
+}
+
+void gl4_0compat_glSamplerParameterIiv(void *_glfuncs, GLuint sampler, GLenum pname, const GLint* param)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glSamplerParameterIiv(sampler, pname, param);
+}
+
+void gl4_0compat_glSamplerParameterfv(void *_glfuncs, GLuint sampler, GLenum pname, const GLfloat* param)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glSamplerParameterfv(sampler, pname, param);
+}
+
+void gl4_0compat_glSamplerParameterf(void *_glfuncs, GLuint sampler, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glSamplerParameterf(sampler, pname, param);
+}
+
+void gl4_0compat_glSamplerParameteriv(void *_glfuncs, GLuint sampler, GLenum pname, const GLint* param)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glSamplerParameteriv(sampler, pname, param);
+}
+
+void gl4_0compat_glSamplerParameteri(void *_glfuncs, GLuint sampler, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glSamplerParameteri(sampler, pname, param);
+}
+
+void gl4_0compat_glBindSampler(void *_glfuncs, GLuint unit, GLuint sampler)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindSampler(unit, sampler);
+}
+
+GLboolean gl4_0compat_glIsSampler(void *_glfuncs, GLuint sampler)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsSampler(sampler);
+}
+
+void gl4_0compat_glDeleteSamplers(void *_glfuncs, GLsizei count, const GLuint* samplers)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteSamplers(count, samplers);
+}
+
+void gl4_0compat_glGenSamplers(void *_glfuncs, GLsizei count, GLuint* samplers)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGenSamplers(count, samplers);
+}
+
+GLint gl4_0compat_glGetFragDataIndex(void *_glfuncs, GLuint program, const GLchar* name)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ return _qglfuncs->glGetFragDataIndex(program, name);
+}
+
+void gl4_0compat_glBindFragDataLocationIndexed(void *_glfuncs, GLuint program, GLuint colorNumber, GLuint index, const GLchar* name)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindFragDataLocationIndexed(program, colorNumber, index, name);
+}
+
+void gl4_0compat_glVertexAttribDivisor(void *_glfuncs, GLuint index, GLuint divisor)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribDivisor(index, divisor);
+}
+
+void gl4_0compat_glGetQueryIndexediv(void *_glfuncs, GLenum target, GLuint index, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetQueryIndexediv(target, index, pname, params);
+}
+
+void gl4_0compat_glEndQueryIndexed(void *_glfuncs, GLenum target, GLuint index)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glEndQueryIndexed(target, index);
+}
+
+void gl4_0compat_glBeginQueryIndexed(void *_glfuncs, GLenum target, GLuint index, GLuint id)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glBeginQueryIndexed(target, index, id);
+}
+
+void gl4_0compat_glDrawTransformFeedbackStream(void *_glfuncs, GLenum mode, GLuint id, GLuint stream)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawTransformFeedbackStream(mode, id, stream);
+}
+
+void gl4_0compat_glDrawTransformFeedback(void *_glfuncs, GLenum mode, GLuint id)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawTransformFeedback(mode, id);
+}
+
+void gl4_0compat_glResumeTransformFeedback(void *_glfuncs)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glResumeTransformFeedback();
+}
+
+void gl4_0compat_glPauseTransformFeedback(void *_glfuncs)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glPauseTransformFeedback();
+}
+
+GLboolean gl4_0compat_glIsTransformFeedback(void *_glfuncs, GLuint id)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsTransformFeedback(id);
+}
+
+void gl4_0compat_glGenTransformFeedbacks(void *_glfuncs, GLsizei n, GLuint* ids)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGenTransformFeedbacks(n, ids);
+}
+
+void gl4_0compat_glDeleteTransformFeedbacks(void *_glfuncs, GLsizei n, const GLuint* ids)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteTransformFeedbacks(n, ids);
+}
+
+void gl4_0compat_glBindTransformFeedback(void *_glfuncs, GLenum target, GLuint id)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindTransformFeedback(target, id);
+}
+
+void gl4_0compat_glPatchParameterfv(void *_glfuncs, GLenum pname, const GLfloat* values)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glPatchParameterfv(pname, values);
+}
+
+void gl4_0compat_glPatchParameteri(void *_glfuncs, GLenum pname, GLint value)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glPatchParameteri(pname, value);
+}
+
+void gl4_0compat_glGetProgramStageiv(void *_glfuncs, GLuint program, GLenum shadertype, GLenum pname, GLint* values)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetProgramStageiv(program, shadertype, pname, values);
+}
+
+void gl4_0compat_glGetUniformSubroutineuiv(void *_glfuncs, GLenum shadertype, GLint location, GLuint* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetUniformSubroutineuiv(shadertype, location, params);
+}
+
+void gl4_0compat_glUniformSubroutinesuiv(void *_glfuncs, GLenum shadertype, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformSubroutinesuiv(shadertype, count, value);
+}
+
+void gl4_0compat_glGetActiveSubroutineName(void *_glfuncs, GLuint program, GLenum shadertype, GLuint index, GLsizei bufSize, GLsizei* length, GLchar* name)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetActiveSubroutineName(program, shadertype, index, bufSize, length, name);
+}
+
+void gl4_0compat_glGetActiveSubroutineUniformName(void *_glfuncs, GLuint program, GLenum shadertype, GLuint index, GLsizei bufSize, GLsizei* length, GLchar* name)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetActiveSubroutineUniformName(program, shadertype, index, bufSize, length, name);
+}
+
+void gl4_0compat_glGetActiveSubroutineUniformiv(void *_glfuncs, GLuint program, GLenum shadertype, GLuint index, GLenum pname, GLint* values)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetActiveSubroutineUniformiv(program, shadertype, index, pname, values);
+}
+
+GLuint gl4_0compat_glGetSubroutineIndex(void *_glfuncs, GLuint program, GLenum shadertype, const GLchar* name)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ return _qglfuncs->glGetSubroutineIndex(program, shadertype, name);
+}
+
+GLint gl4_0compat_glGetSubroutineUniformLocation(void *_glfuncs, GLuint program, GLenum shadertype, const GLchar* name)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ return _qglfuncs->glGetSubroutineUniformLocation(program, shadertype, name);
+}
+
+void gl4_0compat_glGetUniformdv(void *_glfuncs, GLuint program, GLint location, GLdouble* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetUniformdv(program, location, params);
+}
+
+void gl4_0compat_glUniformMatrix4x3dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4x3dv(location, count, transpose, value);
+}
+
+void gl4_0compat_glUniformMatrix4x2dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4x2dv(location, count, transpose, value);
+}
+
+void gl4_0compat_glUniformMatrix3x4dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3x4dv(location, count, transpose, value);
+}
+
+void gl4_0compat_glUniformMatrix3x2dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3x2dv(location, count, transpose, value);
+}
+
+void gl4_0compat_glUniformMatrix2x4dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2x4dv(location, count, transpose, value);
+}
+
+void gl4_0compat_glUniformMatrix2x3dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2x3dv(location, count, transpose, value);
+}
+
+void gl4_0compat_glUniformMatrix4dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4dv(location, count, transpose, value);
+}
+
+void gl4_0compat_glUniformMatrix3dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3dv(location, count, transpose, value);
+}
+
+void gl4_0compat_glUniformMatrix2dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2dv(location, count, transpose, value);
+}
+
+void gl4_0compat_glUniform4dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform4dv(location, count, value);
+}
+
+void gl4_0compat_glUniform3dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform3dv(location, count, value);
+}
+
+void gl4_0compat_glUniform2dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform2dv(location, count, value);
+}
+
+void gl4_0compat_glUniform1dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform1dv(location, count, value);
+}
+
+void gl4_0compat_glUniform4d(void *_glfuncs, GLint location, GLdouble v0, GLdouble v1, GLdouble v2, GLdouble v3)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform4d(location, v0, v1, v2, v3);
+}
+
+void gl4_0compat_glUniform3d(void *_glfuncs, GLint location, GLdouble v0, GLdouble v1, GLdouble v2)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform3d(location, v0, v1, v2);
+}
+
+void gl4_0compat_glUniform2d(void *_glfuncs, GLint location, GLdouble v0, GLdouble v1)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform2d(location, v0, v1);
+}
+
+void gl4_0compat_glUniform1d(void *_glfuncs, GLint location, GLdouble v0)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform1d(location, v0);
+}
+
+void gl4_0compat_glDrawElementsIndirect(void *_glfuncs, GLenum mode, GLenum gltype, const GLvoid* indirect)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawElementsIndirect(mode, gltype, indirect);
+}
+
+void gl4_0compat_glDrawArraysIndirect(void *_glfuncs, GLenum mode, const GLvoid* indirect)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawArraysIndirect(mode, indirect);
+}
+
+void gl4_0compat_glBlendFuncSeparatei(void *_glfuncs, GLuint buf, GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha, GLenum dstAlpha)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glBlendFuncSeparatei(buf, srcRGB, dstRGB, srcAlpha, dstAlpha);
+}
+
+void gl4_0compat_glBlendFunci(void *_glfuncs, GLuint buf, GLenum src, GLenum dst)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glBlendFunci(buf, src, dst);
+}
+
+void gl4_0compat_glBlendEquationSeparatei(void *_glfuncs, GLuint buf, GLenum modeRGB, GLenum modeAlpha)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glBlendEquationSeparatei(buf, modeRGB, modeAlpha);
+}
+
+void gl4_0compat_glBlendEquationi(void *_glfuncs, GLuint buf, GLenum mode)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glBlendEquationi(buf, mode);
+}
+
+void gl4_0compat_glMinSampleShading(void *_glfuncs, GLfloat value)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glMinSampleShading(value);
+}
+
+void gl4_0compat_glTranslatef(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTranslatef(x, y, z);
+}
+
+void gl4_0compat_glTranslated(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTranslated(x, y, z);
+}
+
+void gl4_0compat_glScalef(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glScalef(x, y, z);
+}
+
+void gl4_0compat_glScaled(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glScaled(x, y, z);
+}
+
+void gl4_0compat_glRotatef(void *_glfuncs, GLfloat angle, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glRotatef(angle, x, y, z);
+}
+
+void gl4_0compat_glRotated(void *_glfuncs, GLdouble angle, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glRotated(angle, x, y, z);
+}
+
+void gl4_0compat_glPushMatrix(void *_glfuncs)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glPushMatrix();
+}
+
+void gl4_0compat_glPopMatrix(void *_glfuncs)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glPopMatrix();
+}
+
+void gl4_0compat_glOrtho(void *_glfuncs, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glOrtho(left, right, bottom, top, zNear, zFar);
+}
+
+void gl4_0compat_glMultMatrixd(void *_glfuncs, const GLdouble* m)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultMatrixd(m);
+}
+
+void gl4_0compat_glMultMatrixf(void *_glfuncs, const GLfloat* m)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultMatrixf(m);
+}
+
+void gl4_0compat_glMatrixMode(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glMatrixMode(mode);
+}
+
+void gl4_0compat_glLoadMatrixd(void *_glfuncs, const GLdouble* m)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glLoadMatrixd(m);
+}
+
+void gl4_0compat_glLoadMatrixf(void *_glfuncs, const GLfloat* m)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glLoadMatrixf(m);
+}
+
+void gl4_0compat_glLoadIdentity(void *_glfuncs)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glLoadIdentity();
+}
+
+void gl4_0compat_glFrustum(void *_glfuncs, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glFrustum(left, right, bottom, top, zNear, zFar);
+}
+
+GLboolean gl4_0compat_glIsList(void *_glfuncs, GLuint list)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsList(list);
+}
+
+void gl4_0compat_glGetTexGeniv(void *_glfuncs, GLenum coord, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexGeniv(coord, pname, params);
+}
+
+void gl4_0compat_glGetTexGenfv(void *_glfuncs, GLenum coord, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexGenfv(coord, pname, params);
+}
+
+void gl4_0compat_glGetTexGendv(void *_glfuncs, GLenum coord, GLenum pname, GLdouble* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexGendv(coord, pname, params);
+}
+
+void gl4_0compat_glGetTexEnviv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexEnviv(target, pname, params);
+}
+
+void gl4_0compat_glGetTexEnvfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexEnvfv(target, pname, params);
+}
+
+void gl4_0compat_glGetPolygonStipple(void *_glfuncs, GLubyte* mask)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetPolygonStipple(mask);
+}
+
+void gl4_0compat_glGetPixelMapusv(void *_glfuncs, GLenum glmap, GLushort* values)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetPixelMapusv(glmap, values);
+}
+
+void gl4_0compat_glGetPixelMapuiv(void *_glfuncs, GLenum glmap, GLuint* values)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetPixelMapuiv(glmap, values);
+}
+
+void gl4_0compat_glGetPixelMapfv(void *_glfuncs, GLenum glmap, GLfloat* values)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetPixelMapfv(glmap, values);
+}
+
+void gl4_0compat_glGetMaterialiv(void *_glfuncs, GLenum face, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetMaterialiv(face, pname, params);
+}
+
+void gl4_0compat_glGetMaterialfv(void *_glfuncs, GLenum face, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetMaterialfv(face, pname, params);
+}
+
+void gl4_0compat_glGetMapiv(void *_glfuncs, GLenum target, GLenum query, GLint* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetMapiv(target, query, v);
+}
+
+void gl4_0compat_glGetMapfv(void *_glfuncs, GLenum target, GLenum query, GLfloat* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetMapfv(target, query, v);
+}
+
+void gl4_0compat_glGetMapdv(void *_glfuncs, GLenum target, GLenum query, GLdouble* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetMapdv(target, query, v);
+}
+
+void gl4_0compat_glGetLightiv(void *_glfuncs, GLenum light, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetLightiv(light, pname, params);
+}
+
+void gl4_0compat_glGetLightfv(void *_glfuncs, GLenum light, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetLightfv(light, pname, params);
+}
+
+void gl4_0compat_glGetClipPlane(void *_glfuncs, GLenum plane, GLdouble* equation)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetClipPlane(plane, equation);
+}
+
+void gl4_0compat_glDrawPixels(void *_glfuncs, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawPixels(width, height, format, gltype, pixels);
+}
+
+void gl4_0compat_glCopyPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum gltype)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyPixels(x, y, width, height, gltype);
+}
+
+void gl4_0compat_glPixelMapusv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLushort* values)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glPixelMapusv(glmap, mapsize, values);
+}
+
+void gl4_0compat_glPixelMapuiv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLuint* values)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glPixelMapuiv(glmap, mapsize, values);
+}
+
+void gl4_0compat_glPixelMapfv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLfloat* values)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glPixelMapfv(glmap, mapsize, values);
+}
+
+void gl4_0compat_glPixelTransferi(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glPixelTransferi(pname, param);
+}
+
+void gl4_0compat_glPixelTransferf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glPixelTransferf(pname, param);
+}
+
+void gl4_0compat_glPixelZoom(void *_glfuncs, GLfloat xfactor, GLfloat yfactor)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glPixelZoom(xfactor, yfactor);
+}
+
+void gl4_0compat_glAlphaFunc(void *_glfuncs, GLenum glfunc, GLfloat ref)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glAlphaFunc(glfunc, ref);
+}
+
+void gl4_0compat_glEvalPoint2(void *_glfuncs, GLint i, GLint j)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalPoint2(i, j);
+}
+
+void gl4_0compat_glEvalMesh2(void *_glfuncs, GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalMesh2(mode, i1, i2, j1, j2);
+}
+
+void gl4_0compat_glEvalPoint1(void *_glfuncs, GLint i)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalPoint1(i);
+}
+
+void gl4_0compat_glEvalMesh1(void *_glfuncs, GLenum mode, GLint i1, GLint i2)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalMesh1(mode, i1, i2);
+}
+
+void gl4_0compat_glEvalCoord2fv(void *_glfuncs, const GLfloat* u)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalCoord2fv(u);
+}
+
+void gl4_0compat_glEvalCoord2f(void *_glfuncs, GLfloat u, GLfloat v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalCoord2f(u, v);
+}
+
+void gl4_0compat_glEvalCoord2dv(void *_glfuncs, const GLdouble* u)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalCoord2dv(u);
+}
+
+void gl4_0compat_glEvalCoord2d(void *_glfuncs, GLdouble u, GLdouble v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalCoord2d(u, v);
+}
+
+void gl4_0compat_glEvalCoord1fv(void *_glfuncs, const GLfloat* u)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalCoord1fv(u);
+}
+
+void gl4_0compat_glEvalCoord1f(void *_glfuncs, GLfloat u)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalCoord1f(u);
+}
+
+void gl4_0compat_glEvalCoord1dv(void *_glfuncs, const GLdouble* u)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalCoord1dv(u);
+}
+
+void gl4_0compat_glEvalCoord1d(void *_glfuncs, GLdouble u)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalCoord1d(u);
+}
+
+void gl4_0compat_glMapGrid2f(void *_glfuncs, GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glMapGrid2f(un, u1, u2, vn, v1, v2);
+}
+
+void gl4_0compat_glMapGrid2d(void *_glfuncs, GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glMapGrid2d(un, u1, u2, vn, v1, v2);
+}
+
+void gl4_0compat_glMapGrid1f(void *_glfuncs, GLint un, GLfloat u1, GLfloat u2)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glMapGrid1f(un, u1, u2);
+}
+
+void gl4_0compat_glMapGrid1d(void *_glfuncs, GLint un, GLdouble u1, GLdouble u2)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glMapGrid1d(un, u1, u2);
+}
+
+void gl4_0compat_glMap2f(void *_glfuncs, GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat* points)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glMap2f(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+void gl4_0compat_glMap2d(void *_glfuncs, GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble* points)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glMap2d(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+void gl4_0compat_glMap1f(void *_glfuncs, GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat* points)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glMap1f(target, u1, u2, stride, order, points);
+}
+
+void gl4_0compat_glMap1d(void *_glfuncs, GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble* points)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glMap1d(target, u1, u2, stride, order, points);
+}
+
+void gl4_0compat_glPushAttrib(void *_glfuncs, GLbitfield mask)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glPushAttrib(mask);
+}
+
+void gl4_0compat_glPopAttrib(void *_glfuncs)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glPopAttrib();
+}
+
+void gl4_0compat_glAccum(void *_glfuncs, GLenum op, GLfloat value)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glAccum(op, value);
+}
+
+void gl4_0compat_glIndexMask(void *_glfuncs, GLuint mask)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexMask(mask);
+}
+
+void gl4_0compat_glClearIndex(void *_glfuncs, GLfloat c)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glClearIndex(c);
+}
+
+void gl4_0compat_glClearAccum(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glClearAccum(red, green, blue, alpha);
+}
+
+void gl4_0compat_glPushName(void *_glfuncs, GLuint name)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glPushName(name);
+}
+
+void gl4_0compat_glPopName(void *_glfuncs)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glPopName();
+}
+
+void gl4_0compat_glPassThrough(void *_glfuncs, GLfloat token)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glPassThrough(token);
+}
+
+void gl4_0compat_glLoadName(void *_glfuncs, GLuint name)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glLoadName(name);
+}
+
+void gl4_0compat_glInitNames(void *_glfuncs)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glInitNames();
+}
+
+GLint gl4_0compat_glRenderMode(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ return _qglfuncs->glRenderMode(mode);
+}
+
+void gl4_0compat_glSelectBuffer(void *_glfuncs, GLsizei size, GLuint* buffer)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glSelectBuffer(size, buffer);
+}
+
+void gl4_0compat_glFeedbackBuffer(void *_glfuncs, GLsizei size, GLenum gltype, GLfloat* buffer)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glFeedbackBuffer(size, gltype, buffer);
+}
+
+void gl4_0compat_glTexGeniv(void *_glfuncs, GLenum coord, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexGeniv(coord, pname, params);
+}
+
+void gl4_0compat_glTexGeni(void *_glfuncs, GLenum coord, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexGeni(coord, pname, param);
+}
+
+void gl4_0compat_glTexGenfv(void *_glfuncs, GLenum coord, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexGenfv(coord, pname, params);
+}
+
+void gl4_0compat_glTexGenf(void *_glfuncs, GLenum coord, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexGenf(coord, pname, param);
+}
+
+void gl4_0compat_glTexGendv(void *_glfuncs, GLenum coord, GLenum pname, const GLdouble* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexGendv(coord, pname, params);
+}
+
+void gl4_0compat_glTexGend(void *_glfuncs, GLenum coord, GLenum pname, GLdouble param)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexGend(coord, pname, param);
+}
+
+void gl4_0compat_glTexEnviv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexEnviv(target, pname, params);
+}
+
+void gl4_0compat_glTexEnvi(void *_glfuncs, GLenum target, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexEnvi(target, pname, param);
+}
+
+void gl4_0compat_glTexEnvfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexEnvfv(target, pname, params);
+}
+
+void gl4_0compat_glTexEnvf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexEnvf(target, pname, param);
+}
+
+void gl4_0compat_glShadeModel(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glShadeModel(mode);
+}
+
+void gl4_0compat_glPolygonStipple(void *_glfuncs, const GLubyte* mask)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glPolygonStipple(mask);
+}
+
+void gl4_0compat_glMaterialiv(void *_glfuncs, GLenum face, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glMaterialiv(face, pname, params);
+}
+
+void gl4_0compat_glMateriali(void *_glfuncs, GLenum face, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glMateriali(face, pname, param);
+}
+
+void gl4_0compat_glMaterialfv(void *_glfuncs, GLenum face, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glMaterialfv(face, pname, params);
+}
+
+void gl4_0compat_glMaterialf(void *_glfuncs, GLenum face, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glMaterialf(face, pname, param);
+}
+
+void gl4_0compat_glLineStipple(void *_glfuncs, GLint factor, GLushort pattern)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glLineStipple(factor, pattern);
+}
+
+void gl4_0compat_glLightModeliv(void *_glfuncs, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glLightModeliv(pname, params);
+}
+
+void gl4_0compat_glLightModeli(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glLightModeli(pname, param);
+}
+
+void gl4_0compat_glLightModelfv(void *_glfuncs, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glLightModelfv(pname, params);
+}
+
+void gl4_0compat_glLightModelf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glLightModelf(pname, param);
+}
+
+void gl4_0compat_glLightiv(void *_glfuncs, GLenum light, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glLightiv(light, pname, params);
+}
+
+void gl4_0compat_glLighti(void *_glfuncs, GLenum light, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glLighti(light, pname, param);
+}
+
+void gl4_0compat_glLightfv(void *_glfuncs, GLenum light, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glLightfv(light, pname, params);
+}
+
+void gl4_0compat_glLightf(void *_glfuncs, GLenum light, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glLightf(light, pname, param);
+}
+
+void gl4_0compat_glFogiv(void *_glfuncs, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glFogiv(pname, params);
+}
+
+void gl4_0compat_glFogi(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glFogi(pname, param);
+}
+
+void gl4_0compat_glFogfv(void *_glfuncs, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glFogfv(pname, params);
+}
+
+void gl4_0compat_glFogf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glFogf(pname, param);
+}
+
+void gl4_0compat_glColorMaterial(void *_glfuncs, GLenum face, GLenum mode)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorMaterial(face, mode);
+}
+
+void gl4_0compat_glClipPlane(void *_glfuncs, GLenum plane, const GLdouble* equation)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glClipPlane(plane, equation);
+}
+
+void gl4_0compat_glVertex4sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex4sv(v);
+}
+
+void gl4_0compat_glVertex4s(void *_glfuncs, GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex4s(x, y, z, w);
+}
+
+void gl4_0compat_glVertex4iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex4iv(v);
+}
+
+void gl4_0compat_glVertex4i(void *_glfuncs, GLint x, GLint y, GLint z, GLint w)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex4i(x, y, z, w);
+}
+
+void gl4_0compat_glVertex4fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex4fv(v);
+}
+
+void gl4_0compat_glVertex4f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex4f(x, y, z, w);
+}
+
+void gl4_0compat_glVertex4dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex4dv(v);
+}
+
+void gl4_0compat_glVertex4d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex4d(x, y, z, w);
+}
+
+void gl4_0compat_glVertex3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex3sv(v);
+}
+
+void gl4_0compat_glVertex3s(void *_glfuncs, GLshort x, GLshort y, GLshort z)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex3s(x, y, z);
+}
+
+void gl4_0compat_glVertex3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex3iv(v);
+}
+
+void gl4_0compat_glVertex3i(void *_glfuncs, GLint x, GLint y, GLint z)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex3i(x, y, z);
+}
+
+void gl4_0compat_glVertex3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex3fv(v);
+}
+
+void gl4_0compat_glVertex3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex3f(x, y, z);
+}
+
+void gl4_0compat_glVertex3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex3dv(v);
+}
+
+void gl4_0compat_glVertex3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex3d(x, y, z);
+}
+
+void gl4_0compat_glVertex2sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex2sv(v);
+}
+
+void gl4_0compat_glVertex2s(void *_glfuncs, GLshort x, GLshort y)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex2s(x, y);
+}
+
+void gl4_0compat_glVertex2iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex2iv(v);
+}
+
+void gl4_0compat_glVertex2i(void *_glfuncs, GLint x, GLint y)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex2i(x, y);
+}
+
+void gl4_0compat_glVertex2fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex2fv(v);
+}
+
+void gl4_0compat_glVertex2f(void *_glfuncs, GLfloat x, GLfloat y)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex2f(x, y);
+}
+
+void gl4_0compat_glVertex2dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex2dv(v);
+}
+
+void gl4_0compat_glVertex2d(void *_glfuncs, GLdouble x, GLdouble y)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex2d(x, y);
+}
+
+void gl4_0compat_glTexCoord4sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord4sv(v);
+}
+
+void gl4_0compat_glTexCoord4s(void *_glfuncs, GLshort s, GLshort t, GLshort r, GLshort q)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord4s(s, t, r, q);
+}
+
+void gl4_0compat_glTexCoord4iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord4iv(v);
+}
+
+void gl4_0compat_glTexCoord4i(void *_glfuncs, GLint s, GLint t, GLint r, GLint q)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord4i(s, t, r, q);
+}
+
+void gl4_0compat_glTexCoord4fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord4fv(v);
+}
+
+void gl4_0compat_glTexCoord4f(void *_glfuncs, GLfloat s, GLfloat t, GLfloat r, GLfloat q)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord4f(s, t, r, q);
+}
+
+void gl4_0compat_glTexCoord4dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord4dv(v);
+}
+
+void gl4_0compat_glTexCoord4d(void *_glfuncs, GLdouble s, GLdouble t, GLdouble r, GLdouble q)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord4d(s, t, r, q);
+}
+
+void gl4_0compat_glTexCoord3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord3sv(v);
+}
+
+void gl4_0compat_glTexCoord3s(void *_glfuncs, GLshort s, GLshort t, GLshort r)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord3s(s, t, r);
+}
+
+void gl4_0compat_glTexCoord3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord3iv(v);
+}
+
+void gl4_0compat_glTexCoord3i(void *_glfuncs, GLint s, GLint t, GLint r)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord3i(s, t, r);
+}
+
+void gl4_0compat_glTexCoord3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord3fv(v);
+}
+
+void gl4_0compat_glTexCoord3f(void *_glfuncs, GLfloat s, GLfloat t, GLfloat r)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord3f(s, t, r);
+}
+
+void gl4_0compat_glTexCoord3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord3dv(v);
+}
+
+void gl4_0compat_glTexCoord3d(void *_glfuncs, GLdouble s, GLdouble t, GLdouble r)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord3d(s, t, r);
+}
+
+void gl4_0compat_glTexCoord2sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord2sv(v);
+}
+
+void gl4_0compat_glTexCoord2s(void *_glfuncs, GLshort s, GLshort t)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord2s(s, t);
+}
+
+void gl4_0compat_glTexCoord2iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord2iv(v);
+}
+
+void gl4_0compat_glTexCoord2i(void *_glfuncs, GLint s, GLint t)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord2i(s, t);
+}
+
+void gl4_0compat_glTexCoord2fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord2fv(v);
+}
+
+void gl4_0compat_glTexCoord2f(void *_glfuncs, GLfloat s, GLfloat t)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord2f(s, t);
+}
+
+void gl4_0compat_glTexCoord2dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord2dv(v);
+}
+
+void gl4_0compat_glTexCoord2d(void *_glfuncs, GLdouble s, GLdouble t)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord2d(s, t);
+}
+
+void gl4_0compat_glTexCoord1sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord1sv(v);
+}
+
+void gl4_0compat_glTexCoord1s(void *_glfuncs, GLshort s)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord1s(s);
+}
+
+void gl4_0compat_glTexCoord1iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord1iv(v);
+}
+
+void gl4_0compat_glTexCoord1i(void *_glfuncs, GLint s)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord1i(s);
+}
+
+void gl4_0compat_glTexCoord1fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord1fv(v);
+}
+
+void gl4_0compat_glTexCoord1f(void *_glfuncs, GLfloat s)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord1f(s);
+}
+
+void gl4_0compat_glTexCoord1dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord1dv(v);
+}
+
+void gl4_0compat_glTexCoord1d(void *_glfuncs, GLdouble s)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord1d(s);
+}
+
+void gl4_0compat_glRectsv(void *_glfuncs, const GLshort* v1, const GLshort* v2)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glRectsv(v1, v2);
+}
+
+void gl4_0compat_glRects(void *_glfuncs, GLshort x1, GLshort y1, GLshort x2, GLshort y2)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glRects(x1, y1, x2, y2);
+}
+
+void gl4_0compat_glRectiv(void *_glfuncs, const GLint* v1, const GLint* v2)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glRectiv(v1, v2);
+}
+
+void gl4_0compat_glRecti(void *_glfuncs, GLint x1, GLint y1, GLint x2, GLint y2)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glRecti(x1, y1, x2, y2);
+}
+
+void gl4_0compat_glRectfv(void *_glfuncs, const GLfloat* v1, const GLfloat* v2)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glRectfv(v1, v2);
+}
+
+void gl4_0compat_glRectf(void *_glfuncs, GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glRectf(x1, y1, x2, y2);
+}
+
+void gl4_0compat_glRectdv(void *_glfuncs, const GLdouble* v1, const GLdouble* v2)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glRectdv(v1, v2);
+}
+
+void gl4_0compat_glRectd(void *_glfuncs, GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glRectd(x1, y1, x2, y2);
+}
+
+void gl4_0compat_glRasterPos4sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos4sv(v);
+}
+
+void gl4_0compat_glRasterPos4s(void *_glfuncs, GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos4s(x, y, z, w);
+}
+
+void gl4_0compat_glRasterPos4iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos4iv(v);
+}
+
+void gl4_0compat_glRasterPos4i(void *_glfuncs, GLint x, GLint y, GLint z, GLint w)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos4i(x, y, z, w);
+}
+
+void gl4_0compat_glRasterPos4fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos4fv(v);
+}
+
+void gl4_0compat_glRasterPos4f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos4f(x, y, z, w);
+}
+
+void gl4_0compat_glRasterPos4dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos4dv(v);
+}
+
+void gl4_0compat_glRasterPos4d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos4d(x, y, z, w);
+}
+
+void gl4_0compat_glRasterPos3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos3sv(v);
+}
+
+void gl4_0compat_glRasterPos3s(void *_glfuncs, GLshort x, GLshort y, GLshort z)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos3s(x, y, z);
+}
+
+void gl4_0compat_glRasterPos3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos3iv(v);
+}
+
+void gl4_0compat_glRasterPos3i(void *_glfuncs, GLint x, GLint y, GLint z)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos3i(x, y, z);
+}
+
+void gl4_0compat_glRasterPos3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos3fv(v);
+}
+
+void gl4_0compat_glRasterPos3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos3f(x, y, z);
+}
+
+void gl4_0compat_glRasterPos3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos3dv(v);
+}
+
+void gl4_0compat_glRasterPos3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos3d(x, y, z);
+}
+
+void gl4_0compat_glRasterPos2sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos2sv(v);
+}
+
+void gl4_0compat_glRasterPos2s(void *_glfuncs, GLshort x, GLshort y)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos2s(x, y);
+}
+
+void gl4_0compat_glRasterPos2iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos2iv(v);
+}
+
+void gl4_0compat_glRasterPos2i(void *_glfuncs, GLint x, GLint y)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos2i(x, y);
+}
+
+void gl4_0compat_glRasterPos2fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos2fv(v);
+}
+
+void gl4_0compat_glRasterPos2f(void *_glfuncs, GLfloat x, GLfloat y)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos2f(x, y);
+}
+
+void gl4_0compat_glRasterPos2dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos2dv(v);
+}
+
+void gl4_0compat_glRasterPos2d(void *_glfuncs, GLdouble x, GLdouble y)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos2d(x, y);
+}
+
+void gl4_0compat_glNormal3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormal3sv(v);
+}
+
+void gl4_0compat_glNormal3s(void *_glfuncs, GLshort nx, GLshort ny, GLshort nz)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormal3s(nx, ny, nz);
+}
+
+void gl4_0compat_glNormal3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormal3iv(v);
+}
+
+void gl4_0compat_glNormal3i(void *_glfuncs, GLint nx, GLint ny, GLint nz)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormal3i(nx, ny, nz);
+}
+
+void gl4_0compat_glNormal3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormal3fv(v);
+}
+
+void gl4_0compat_glNormal3f(void *_glfuncs, GLfloat nx, GLfloat ny, GLfloat nz)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormal3f(nx, ny, nz);
+}
+
+void gl4_0compat_glNormal3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormal3dv(v);
+}
+
+void gl4_0compat_glNormal3d(void *_glfuncs, GLdouble nx, GLdouble ny, GLdouble nz)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormal3d(nx, ny, nz);
+}
+
+void gl4_0compat_glNormal3bv(void *_glfuncs, const GLbyte* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormal3bv(v);
+}
+
+void gl4_0compat_glNormal3b(void *_glfuncs, GLbyte nx, GLbyte ny, GLbyte nz)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormal3b(nx, ny, nz);
+}
+
+void gl4_0compat_glIndexsv(void *_glfuncs, const GLshort* c)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexsv(c);
+}
+
+void gl4_0compat_glIndexs(void *_glfuncs, GLshort c)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexs(c);
+}
+
+void gl4_0compat_glIndexiv(void *_glfuncs, const GLint* c)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexiv(c);
+}
+
+void gl4_0compat_glIndexi(void *_glfuncs, GLint c)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexi(c);
+}
+
+void gl4_0compat_glIndexfv(void *_glfuncs, const GLfloat* c)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexfv(c);
+}
+
+void gl4_0compat_glIndexf(void *_glfuncs, GLfloat c)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexf(c);
+}
+
+void gl4_0compat_glIndexdv(void *_glfuncs, const GLdouble* c)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexdv(c);
+}
+
+void gl4_0compat_glIndexd(void *_glfuncs, GLdouble c)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexd(c);
+}
+
+void gl4_0compat_glEnd(void *_glfuncs)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glEnd();
+}
+
+void gl4_0compat_glEdgeFlagv(void *_glfuncs, const GLboolean* flag)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glEdgeFlagv(flag);
+}
+
+void gl4_0compat_glEdgeFlag(void *_glfuncs, GLboolean flag)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glEdgeFlag(flag);
+}
+
+void gl4_0compat_glColor4usv(void *_glfuncs, const GLushort* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4usv(v);
+}
+
+void gl4_0compat_glColor4us(void *_glfuncs, GLushort red, GLushort green, GLushort blue, GLushort alpha)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4us(red, green, blue, alpha);
+}
+
+void gl4_0compat_glColor4uiv(void *_glfuncs, const GLuint* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4uiv(v);
+}
+
+void gl4_0compat_glColor4ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue, GLuint alpha)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4ui(red, green, blue, alpha);
+}
+
+void gl4_0compat_glColor4ubv(void *_glfuncs, const GLubyte* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4ubv(v);
+}
+
+void gl4_0compat_glColor4ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4ub(red, green, blue, alpha);
+}
+
+void gl4_0compat_glColor4sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4sv(v);
+}
+
+void gl4_0compat_glColor4s(void *_glfuncs, GLshort red, GLshort green, GLshort blue, GLshort alpha)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4s(red, green, blue, alpha);
+}
+
+void gl4_0compat_glColor4iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4iv(v);
+}
+
+void gl4_0compat_glColor4i(void *_glfuncs, GLint red, GLint green, GLint blue, GLint alpha)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4i(red, green, blue, alpha);
+}
+
+void gl4_0compat_glColor4fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4fv(v);
+}
+
+void gl4_0compat_glColor4f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4f(red, green, blue, alpha);
+}
+
+void gl4_0compat_glColor4dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4dv(v);
+}
+
+void gl4_0compat_glColor4d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4d(red, green, blue, alpha);
+}
+
+void gl4_0compat_glColor4bv(void *_glfuncs, const GLbyte* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4bv(v);
+}
+
+void gl4_0compat_glColor4b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4b(red, green, blue, alpha);
+}
+
+void gl4_0compat_glColor3usv(void *_glfuncs, const GLushort* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3usv(v);
+}
+
+void gl4_0compat_glColor3us(void *_glfuncs, GLushort red, GLushort green, GLushort blue)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3us(red, green, blue);
+}
+
+void gl4_0compat_glColor3uiv(void *_glfuncs, const GLuint* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3uiv(v);
+}
+
+void gl4_0compat_glColor3ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3ui(red, green, blue);
+}
+
+void gl4_0compat_glColor3ubv(void *_glfuncs, const GLubyte* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3ubv(v);
+}
+
+void gl4_0compat_glColor3ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3ub(red, green, blue);
+}
+
+void gl4_0compat_glColor3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3sv(v);
+}
+
+void gl4_0compat_glColor3s(void *_glfuncs, GLshort red, GLshort green, GLshort blue)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3s(red, green, blue);
+}
+
+void gl4_0compat_glColor3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3iv(v);
+}
+
+void gl4_0compat_glColor3i(void *_glfuncs, GLint red, GLint green, GLint blue)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3i(red, green, blue);
+}
+
+void gl4_0compat_glColor3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3fv(v);
+}
+
+void gl4_0compat_glColor3f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3f(red, green, blue);
+}
+
+void gl4_0compat_glColor3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3dv(v);
+}
+
+void gl4_0compat_glColor3d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3d(red, green, blue);
+}
+
+void gl4_0compat_glColor3bv(void *_glfuncs, const GLbyte* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3bv(v);
+}
+
+void gl4_0compat_glColor3b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3b(red, green, blue);
+}
+
+void gl4_0compat_glBitmap(void *_glfuncs, GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte* bitmap)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glBitmap(width, height, xorig, yorig, xmove, ymove, bitmap);
+}
+
+void gl4_0compat_glBegin(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glBegin(mode);
+}
+
+void gl4_0compat_glListBase(void *_glfuncs, GLuint base)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glListBase(base);
+}
+
+GLuint gl4_0compat_glGenLists(void *_glfuncs, GLsizei range_)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ return _qglfuncs->glGenLists(range_);
+}
+
+void gl4_0compat_glDeleteLists(void *_glfuncs, GLuint list, GLsizei range_)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteLists(list, range_);
+}
+
+void gl4_0compat_glCallLists(void *_glfuncs, GLsizei n, GLenum gltype, const GLvoid* lists)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glCallLists(n, gltype, lists);
+}
+
+void gl4_0compat_glCallList(void *_glfuncs, GLuint list)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glCallList(list);
+}
+
+void gl4_0compat_glEndList(void *_glfuncs)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glEndList();
+}
+
+void gl4_0compat_glNewList(void *_glfuncs, GLuint list, GLenum mode)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glNewList(list, mode);
+}
+
+void gl4_0compat_glPushClientAttrib(void *_glfuncs, GLbitfield mask)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glPushClientAttrib(mask);
+}
+
+void gl4_0compat_glPopClientAttrib(void *_glfuncs)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glPopClientAttrib();
+}
+
+void gl4_0compat_glPrioritizeTextures(void *_glfuncs, GLsizei n, const GLuint* textures, const GLfloat* priorities)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glPrioritizeTextures(n, textures, priorities);
+}
+
+GLboolean gl4_0compat_glAreTexturesResident(void *_glfuncs, GLsizei n, const GLuint* textures, GLboolean* residences)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ return _qglfuncs->glAreTexturesResident(n, textures, residences);
+}
+
+void gl4_0compat_glVertexPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexPointer(size, gltype, stride, pointer);
+}
+
+void gl4_0compat_glTexCoordPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoordPointer(size, gltype, stride, pointer);
+}
+
+void gl4_0compat_glNormalPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormalPointer(gltype, stride, pointer);
+}
+
+void gl4_0compat_glInterleavedArrays(void *_glfuncs, GLenum format, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glInterleavedArrays(format, stride, pointer);
+}
+
+void gl4_0compat_glIndexPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexPointer(gltype, stride, pointer);
+}
+
+void gl4_0compat_glEnableClientState(void *_glfuncs, GLenum array)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glEnableClientState(array);
+}
+
+void gl4_0compat_glEdgeFlagPointer(void *_glfuncs, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glEdgeFlagPointer(stride, pointer);
+}
+
+void gl4_0compat_glDisableClientState(void *_glfuncs, GLenum array)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glDisableClientState(array);
+}
+
+void gl4_0compat_glColorPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorPointer(size, gltype, stride, pointer);
+}
+
+void gl4_0compat_glArrayElement(void *_glfuncs, GLint i)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glArrayElement(i);
+}
+
+void gl4_0compat_glResetMinmax(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glResetMinmax(target);
+}
+
+void gl4_0compat_glResetHistogram(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glResetHistogram(target);
+}
+
+void gl4_0compat_glMinmax(void *_glfuncs, GLenum target, GLenum internalFormat, GLboolean sink)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glMinmax(target, internalFormat, sink);
+}
+
+void gl4_0compat_glHistogram(void *_glfuncs, GLenum target, GLsizei width, GLenum internalFormat, GLboolean sink)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glHistogram(target, width, internalFormat, sink);
+}
+
+void gl4_0compat_glGetMinmaxParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetMinmaxParameteriv(target, pname, params);
+}
+
+void gl4_0compat_glGetMinmaxParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetMinmaxParameterfv(target, pname, params);
+}
+
+void gl4_0compat_glGetMinmax(void *_glfuncs, GLenum target, GLboolean reset, GLenum format, GLenum gltype, GLvoid* values)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetMinmax(target, reset, format, gltype, values);
+}
+
+void gl4_0compat_glGetHistogramParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetHistogramParameteriv(target, pname, params);
+}
+
+void gl4_0compat_glGetHistogramParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetHistogramParameterfv(target, pname, params);
+}
+
+void gl4_0compat_glGetHistogram(void *_glfuncs, GLenum target, GLboolean reset, GLenum format, GLenum gltype, GLvoid* values)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetHistogram(target, reset, format, gltype, values);
+}
+
+void gl4_0compat_glSeparableFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* row, const GLvoid* column)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glSeparableFilter2D(target, internalFormat, width, height, format, gltype, row, column);
+}
+
+void gl4_0compat_glGetSeparableFilter(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* row, GLvoid* column, GLvoid* span)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetSeparableFilter(target, format, gltype, row, column, span);
+}
+
+void gl4_0compat_glGetConvolutionParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetConvolutionParameteriv(target, pname, params);
+}
+
+void gl4_0compat_glGetConvolutionParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetConvolutionParameterfv(target, pname, params);
+}
+
+void gl4_0compat_glGetConvolutionFilter(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* image)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetConvolutionFilter(target, format, gltype, image);
+}
+
+void gl4_0compat_glCopyConvolutionFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyConvolutionFilter2D(target, internalFormat, x, y, width, height);
+}
+
+void gl4_0compat_glCopyConvolutionFilter1D(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyConvolutionFilter1D(target, internalFormat, x, y, width);
+}
+
+void gl4_0compat_glConvolutionParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glConvolutionParameteriv(target, pname, params);
+}
+
+void gl4_0compat_glConvolutionParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glConvolutionParameteri(target, pname, params);
+}
+
+void gl4_0compat_glConvolutionParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glConvolutionParameterfv(target, pname, params);
+}
+
+void gl4_0compat_glConvolutionParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glConvolutionParameterf(target, pname, params);
+}
+
+void gl4_0compat_glConvolutionFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* image)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glConvolutionFilter2D(target, internalFormat, width, height, format, gltype, image);
+}
+
+void gl4_0compat_glConvolutionFilter1D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLenum format, GLenum gltype, const GLvoid* image)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glConvolutionFilter1D(target, internalFormat, width, format, gltype, image);
+}
+
+void gl4_0compat_glCopyColorSubTable(void *_glfuncs, GLenum target, GLsizei start, GLint x, GLint y, GLsizei width)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyColorSubTable(target, start, x, y, width);
+}
+
+void gl4_0compat_glColorSubTable(void *_glfuncs, GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum gltype, const GLvoid* data)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorSubTable(target, start, count, format, gltype, data);
+}
+
+void gl4_0compat_glGetColorTableParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetColorTableParameteriv(target, pname, params);
+}
+
+void gl4_0compat_glGetColorTableParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetColorTableParameterfv(target, pname, params);
+}
+
+void gl4_0compat_glGetColorTable(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* table)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetColorTable(target, format, gltype, table);
+}
+
+void gl4_0compat_glCopyColorTable(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyColorTable(target, internalFormat, x, y, width);
+}
+
+void gl4_0compat_glColorTableParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorTableParameteriv(target, pname, params);
+}
+
+void gl4_0compat_glColorTableParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorTableParameterfv(target, pname, params);
+}
+
+void gl4_0compat_glColorTable(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLenum format, GLenum gltype, const GLvoid* table)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorTable(target, internalFormat, width, format, gltype, table);
+}
+
+void gl4_0compat_glMultTransposeMatrixd(void *_glfuncs, const GLdouble* m)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultTransposeMatrixd(m);
+}
+
+void gl4_0compat_glMultTransposeMatrixf(void *_glfuncs, const GLfloat* m)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultTransposeMatrixf(m);
+}
+
+void gl4_0compat_glLoadTransposeMatrixd(void *_glfuncs, const GLdouble* m)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glLoadTransposeMatrixd(m);
+}
+
+void gl4_0compat_glLoadTransposeMatrixf(void *_glfuncs, const GLfloat* m)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glLoadTransposeMatrixf(m);
+}
+
+void gl4_0compat_glMultiTexCoord4sv(void *_glfuncs, GLenum target, const GLshort* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4sv(target, v);
+}
+
+void gl4_0compat_glMultiTexCoord4s(void *_glfuncs, GLenum target, GLshort s, GLshort t, GLshort r, GLshort q)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4s(target, s, t, r, q);
+}
+
+void gl4_0compat_glMultiTexCoord4iv(void *_glfuncs, GLenum target, const GLint* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4iv(target, v);
+}
+
+void gl4_0compat_glMultiTexCoord4i(void *_glfuncs, GLenum target, GLint s, GLint t, GLint r, GLint q)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4i(target, s, t, r, q);
+}
+
+void gl4_0compat_glMultiTexCoord4fv(void *_glfuncs, GLenum target, const GLfloat* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4fv(target, v);
+}
+
+void gl4_0compat_glMultiTexCoord4f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4f(target, s, t, r, q);
+}
+
+void gl4_0compat_glMultiTexCoord4dv(void *_glfuncs, GLenum target, const GLdouble* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4dv(target, v);
+}
+
+void gl4_0compat_glMultiTexCoord4d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4d(target, s, t, r, q);
+}
+
+void gl4_0compat_glMultiTexCoord3sv(void *_glfuncs, GLenum target, const GLshort* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3sv(target, v);
+}
+
+void gl4_0compat_glMultiTexCoord3s(void *_glfuncs, GLenum target, GLshort s, GLshort t, GLshort r)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3s(target, s, t, r);
+}
+
+void gl4_0compat_glMultiTexCoord3iv(void *_glfuncs, GLenum target, const GLint* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3iv(target, v);
+}
+
+void gl4_0compat_glMultiTexCoord3i(void *_glfuncs, GLenum target, GLint s, GLint t, GLint r)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3i(target, s, t, r);
+}
+
+void gl4_0compat_glMultiTexCoord3fv(void *_glfuncs, GLenum target, const GLfloat* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3fv(target, v);
+}
+
+void gl4_0compat_glMultiTexCoord3f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t, GLfloat r)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3f(target, s, t, r);
+}
+
+void gl4_0compat_glMultiTexCoord3dv(void *_glfuncs, GLenum target, const GLdouble* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3dv(target, v);
+}
+
+void gl4_0compat_glMultiTexCoord3d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t, GLdouble r)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3d(target, s, t, r);
+}
+
+void gl4_0compat_glMultiTexCoord2sv(void *_glfuncs, GLenum target, const GLshort* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2sv(target, v);
+}
+
+void gl4_0compat_glMultiTexCoord2s(void *_glfuncs, GLenum target, GLshort s, GLshort t)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2s(target, s, t);
+}
+
+void gl4_0compat_glMultiTexCoord2iv(void *_glfuncs, GLenum target, const GLint* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2iv(target, v);
+}
+
+void gl4_0compat_glMultiTexCoord2i(void *_glfuncs, GLenum target, GLint s, GLint t)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2i(target, s, t);
+}
+
+void gl4_0compat_glMultiTexCoord2fv(void *_glfuncs, GLenum target, const GLfloat* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2fv(target, v);
+}
+
+void gl4_0compat_glMultiTexCoord2f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2f(target, s, t);
+}
+
+void gl4_0compat_glMultiTexCoord2dv(void *_glfuncs, GLenum target, const GLdouble* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2dv(target, v);
+}
+
+void gl4_0compat_glMultiTexCoord2d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2d(target, s, t);
+}
+
+void gl4_0compat_glMultiTexCoord1sv(void *_glfuncs, GLenum target, const GLshort* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1sv(target, v);
+}
+
+void gl4_0compat_glMultiTexCoord1s(void *_glfuncs, GLenum target, GLshort s)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1s(target, s);
+}
+
+void gl4_0compat_glMultiTexCoord1iv(void *_glfuncs, GLenum target, const GLint* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1iv(target, v);
+}
+
+void gl4_0compat_glMultiTexCoord1i(void *_glfuncs, GLenum target, GLint s)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1i(target, s);
+}
+
+void gl4_0compat_glMultiTexCoord1fv(void *_glfuncs, GLenum target, const GLfloat* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1fv(target, v);
+}
+
+void gl4_0compat_glMultiTexCoord1f(void *_glfuncs, GLenum target, GLfloat s)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1f(target, s);
+}
+
+void gl4_0compat_glMultiTexCoord1dv(void *_glfuncs, GLenum target, const GLdouble* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1dv(target, v);
+}
+
+void gl4_0compat_glMultiTexCoord1d(void *_glfuncs, GLenum target, GLdouble s)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1d(target, s);
+}
+
+void gl4_0compat_glClientActiveTexture(void *_glfuncs, GLenum texture)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glClientActiveTexture(texture);
+}
+
+void gl4_0compat_glWindowPos3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos3sv(v);
+}
+
+void gl4_0compat_glWindowPos3s(void *_glfuncs, GLshort x, GLshort y, GLshort z)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos3s(x, y, z);
+}
+
+void gl4_0compat_glWindowPos3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos3iv(v);
+}
+
+void gl4_0compat_glWindowPos3i(void *_glfuncs, GLint x, GLint y, GLint z)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos3i(x, y, z);
+}
+
+void gl4_0compat_glWindowPos3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos3fv(v);
+}
+
+void gl4_0compat_glWindowPos3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos3f(x, y, z);
+}
+
+void gl4_0compat_glWindowPos3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos3dv(v);
+}
+
+void gl4_0compat_glWindowPos3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos3d(x, y, z);
+}
+
+void gl4_0compat_glWindowPos2sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos2sv(v);
+}
+
+void gl4_0compat_glWindowPos2s(void *_glfuncs, GLshort x, GLshort y)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos2s(x, y);
+}
+
+void gl4_0compat_glWindowPos2iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos2iv(v);
+}
+
+void gl4_0compat_glWindowPos2i(void *_glfuncs, GLint x, GLint y)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos2i(x, y);
+}
+
+void gl4_0compat_glWindowPos2fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos2fv(v);
+}
+
+void gl4_0compat_glWindowPos2f(void *_glfuncs, GLfloat x, GLfloat y)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos2f(x, y);
+}
+
+void gl4_0compat_glWindowPos2dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos2dv(v);
+}
+
+void gl4_0compat_glWindowPos2d(void *_glfuncs, GLdouble x, GLdouble y)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos2d(x, y);
+}
+
+void gl4_0compat_glSecondaryColorPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColorPointer(size, gltype, stride, pointer);
+}
+
+void gl4_0compat_glSecondaryColor3usv(void *_glfuncs, const GLushort* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3usv(v);
+}
+
+void gl4_0compat_glSecondaryColor3us(void *_glfuncs, GLushort red, GLushort green, GLushort blue)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3us(red, green, blue);
+}
+
+void gl4_0compat_glSecondaryColor3uiv(void *_glfuncs, const GLuint* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3uiv(v);
+}
+
+void gl4_0compat_glSecondaryColor3ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3ui(red, green, blue);
+}
+
+void gl4_0compat_glSecondaryColor3ubv(void *_glfuncs, const GLubyte* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3ubv(v);
+}
+
+void gl4_0compat_glSecondaryColor3ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3ub(red, green, blue);
+}
+
+void gl4_0compat_glSecondaryColor3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3sv(v);
+}
+
+void gl4_0compat_glSecondaryColor3s(void *_glfuncs, GLshort red, GLshort green, GLshort blue)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3s(red, green, blue);
+}
+
+void gl4_0compat_glSecondaryColor3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3iv(v);
+}
+
+void gl4_0compat_glSecondaryColor3i(void *_glfuncs, GLint red, GLint green, GLint blue)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3i(red, green, blue);
+}
+
+void gl4_0compat_glSecondaryColor3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3fv(v);
+}
+
+void gl4_0compat_glSecondaryColor3f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3f(red, green, blue);
+}
+
+void gl4_0compat_glSecondaryColor3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3dv(v);
+}
+
+void gl4_0compat_glSecondaryColor3d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3d(red, green, blue);
+}
+
+void gl4_0compat_glSecondaryColor3bv(void *_glfuncs, const GLbyte* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3bv(v);
+}
+
+void gl4_0compat_glSecondaryColor3b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3b(red, green, blue);
+}
+
+void gl4_0compat_glFogCoordPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glFogCoordPointer(gltype, stride, pointer);
+}
+
+void gl4_0compat_glFogCoorddv(void *_glfuncs, const GLdouble* coord)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glFogCoorddv(coord);
+}
+
+void gl4_0compat_glFogCoordd(void *_glfuncs, GLdouble coord)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glFogCoordd(coord);
+}
+
+void gl4_0compat_glFogCoordfv(void *_glfuncs, const GLfloat* coord)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glFogCoordfv(coord);
+}
+
+void gl4_0compat_glFogCoordf(void *_glfuncs, GLfloat coord)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glFogCoordf(coord);
+}
+
+void gl4_0compat_glVertexAttrib4usv(void *_glfuncs, GLuint index, const GLushort* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4usv(index, v);
+}
+
+void gl4_0compat_glVertexAttrib4uiv(void *_glfuncs, GLuint index, const GLuint* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4uiv(index, v);
+}
+
+void gl4_0compat_glVertexAttrib4ubv(void *_glfuncs, GLuint index, const GLubyte* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4ubv(index, v);
+}
+
+void gl4_0compat_glVertexAttrib4sv(void *_glfuncs, GLuint index, const GLshort* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4sv(index, v);
+}
+
+void gl4_0compat_glVertexAttrib4s(void *_glfuncs, GLuint index, GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4s(index, x, y, z, w);
+}
+
+void gl4_0compat_glVertexAttrib4iv(void *_glfuncs, GLuint index, const GLint* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4iv(index, v);
+}
+
+void gl4_0compat_glVertexAttrib4fv(void *_glfuncs, GLuint index, const GLfloat* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4fv(index, v);
+}
+
+void gl4_0compat_glVertexAttrib4f(void *_glfuncs, GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4f(index, x, y, z, w);
+}
+
+void gl4_0compat_glVertexAttrib4dv(void *_glfuncs, GLuint index, const GLdouble* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4dv(index, v);
+}
+
+void gl4_0compat_glVertexAttrib4d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4d(index, x, y, z, w);
+}
+
+void gl4_0compat_glVertexAttrib4bv(void *_glfuncs, GLuint index, const GLbyte* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4bv(index, v);
+}
+
+void gl4_0compat_glVertexAttrib4Nusv(void *_glfuncs, GLuint index, const GLushort* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Nusv(index, v);
+}
+
+void gl4_0compat_glVertexAttrib4Nuiv(void *_glfuncs, GLuint index, const GLuint* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Nuiv(index, v);
+}
+
+void gl4_0compat_glVertexAttrib4Nubv(void *_glfuncs, GLuint index, const GLubyte* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Nubv(index, v);
+}
+
+void gl4_0compat_glVertexAttrib4Nub(void *_glfuncs, GLuint index, GLubyte x, GLubyte y, GLubyte z, GLubyte w)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Nub(index, x, y, z, w);
+}
+
+void gl4_0compat_glVertexAttrib4Nsv(void *_glfuncs, GLuint index, const GLshort* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Nsv(index, v);
+}
+
+void gl4_0compat_glVertexAttrib4Niv(void *_glfuncs, GLuint index, const GLint* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Niv(index, v);
+}
+
+void gl4_0compat_glVertexAttrib4Nbv(void *_glfuncs, GLuint index, const GLbyte* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Nbv(index, v);
+}
+
+void gl4_0compat_glVertexAttrib3sv(void *_glfuncs, GLuint index, const GLshort* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib3sv(index, v);
+}
+
+void gl4_0compat_glVertexAttrib3s(void *_glfuncs, GLuint index, GLshort x, GLshort y, GLshort z)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib3s(index, x, y, z);
+}
+
+void gl4_0compat_glVertexAttrib3fv(void *_glfuncs, GLuint index, const GLfloat* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib3fv(index, v);
+}
+
+void gl4_0compat_glVertexAttrib3f(void *_glfuncs, GLuint index, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib3f(index, x, y, z);
+}
+
+void gl4_0compat_glVertexAttrib3dv(void *_glfuncs, GLuint index, const GLdouble* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib3dv(index, v);
+}
+
+void gl4_0compat_glVertexAttrib3d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib3d(index, x, y, z);
+}
+
+void gl4_0compat_glVertexAttrib2sv(void *_glfuncs, GLuint index, const GLshort* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib2sv(index, v);
+}
+
+void gl4_0compat_glVertexAttrib2s(void *_glfuncs, GLuint index, GLshort x, GLshort y)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib2s(index, x, y);
+}
+
+void gl4_0compat_glVertexAttrib2fv(void *_glfuncs, GLuint index, const GLfloat* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib2fv(index, v);
+}
+
+void gl4_0compat_glVertexAttrib2f(void *_glfuncs, GLuint index, GLfloat x, GLfloat y)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib2f(index, x, y);
+}
+
+void gl4_0compat_glVertexAttrib2dv(void *_glfuncs, GLuint index, const GLdouble* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib2dv(index, v);
+}
+
+void gl4_0compat_glVertexAttrib2d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib2d(index, x, y);
+}
+
+void gl4_0compat_glVertexAttrib1sv(void *_glfuncs, GLuint index, const GLshort* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib1sv(index, v);
+}
+
+void gl4_0compat_glVertexAttrib1s(void *_glfuncs, GLuint index, GLshort x)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib1s(index, x);
+}
+
+void gl4_0compat_glVertexAttrib1fv(void *_glfuncs, GLuint index, const GLfloat* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib1fv(index, v);
+}
+
+void gl4_0compat_glVertexAttrib1f(void *_glfuncs, GLuint index, GLfloat x)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib1f(index, x);
+}
+
+void gl4_0compat_glVertexAttrib1dv(void *_glfuncs, GLuint index, const GLdouble* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib1dv(index, v);
+}
+
+void gl4_0compat_glVertexAttrib1d(void *_glfuncs, GLuint index, GLdouble x)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib1d(index, x);
+}
+
+void gl4_0compat_glVertexAttribI4usv(void *_glfuncs, GLuint index, const GLushort* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI4usv(index, v);
+}
+
+void gl4_0compat_glVertexAttribI4ubv(void *_glfuncs, GLuint index, const GLubyte* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI4ubv(index, v);
+}
+
+void gl4_0compat_glVertexAttribI4sv(void *_glfuncs, GLuint index, const GLshort* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI4sv(index, v);
+}
+
+void gl4_0compat_glVertexAttribI4bv(void *_glfuncs, GLuint index, const GLbyte* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI4bv(index, v);
+}
+
+void gl4_0compat_glVertexAttribI4uiv(void *_glfuncs, GLuint index, const GLuint* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI4uiv(index, v);
+}
+
+void gl4_0compat_glVertexAttribI3uiv(void *_glfuncs, GLuint index, const GLuint* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI3uiv(index, v);
+}
+
+void gl4_0compat_glVertexAttribI2uiv(void *_glfuncs, GLuint index, const GLuint* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI2uiv(index, v);
+}
+
+void gl4_0compat_glVertexAttribI1uiv(void *_glfuncs, GLuint index, const GLuint* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI1uiv(index, v);
+}
+
+void gl4_0compat_glVertexAttribI4iv(void *_glfuncs, GLuint index, const GLint* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI4iv(index, v);
+}
+
+void gl4_0compat_glVertexAttribI3iv(void *_glfuncs, GLuint index, const GLint* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI3iv(index, v);
+}
+
+void gl4_0compat_glVertexAttribI2iv(void *_glfuncs, GLuint index, const GLint* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI2iv(index, v);
+}
+
+void gl4_0compat_glVertexAttribI1iv(void *_glfuncs, GLuint index, const GLint* v)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI1iv(index, v);
+}
+
+void gl4_0compat_glVertexAttribI4ui(void *_glfuncs, GLuint index, GLuint x, GLuint y, GLuint z, GLuint w)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI4ui(index, x, y, z, w);
+}
+
+void gl4_0compat_glVertexAttribI3ui(void *_glfuncs, GLuint index, GLuint x, GLuint y, GLuint z)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI3ui(index, x, y, z);
+}
+
+void gl4_0compat_glVertexAttribI2ui(void *_glfuncs, GLuint index, GLuint x, GLuint y)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI2ui(index, x, y);
+}
+
+void gl4_0compat_glVertexAttribI1ui(void *_glfuncs, GLuint index, GLuint x)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI1ui(index, x);
+}
+
+void gl4_0compat_glVertexAttribI4i(void *_glfuncs, GLuint index, GLint x, GLint y, GLint z, GLint w)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI4i(index, x, y, z, w);
+}
+
+void gl4_0compat_glVertexAttribI3i(void *_glfuncs, GLuint index, GLint x, GLint y, GLint z)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI3i(index, x, y, z);
+}
+
+void gl4_0compat_glVertexAttribI2i(void *_glfuncs, GLuint index, GLint x, GLint y)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI2i(index, x, y);
+}
+
+void gl4_0compat_glVertexAttribI1i(void *_glfuncs, GLuint index, GLint x)
+{
+ QOpenGLFunctions_4_0_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI1i(index, x);
+}
+
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.0compat/funcs.h b/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.0compat/funcs.h
new file mode 100644
index 000000000..e556b7357
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.0compat/funcs.h
@@ -0,0 +1,833 @@
+
+// ** file automatically generated by glgen -- do not edit manually **
+
+#ifndef __cplusplus
+#include <inttypes.h>
+#include <stddef.h>
+typedef unsigned int GLenum;
+typedef unsigned char GLboolean;
+typedef unsigned int GLbitfield;
+typedef void GLvoid;
+typedef char GLchar;
+typedef signed char GLbyte; /* 1-byte signed */
+typedef short GLshort; /* 2-byte signed */
+typedef int GLint; /* 4-byte signed */
+typedef unsigned char GLubyte; /* 1-byte unsigned */
+typedef unsigned short GLushort; /* 2-byte unsigned */
+typedef unsigned int GLuint; /* 4-byte unsigned */
+typedef int GLsizei; /* 4-byte signed */
+typedef float GLfloat; /* single precision float */
+typedef float GLclampf; /* single precision float in [0,1] */
+typedef double GLdouble; /* double precision float */
+typedef double GLclampd; /* double precision float in [0,1] */
+typedef int64_t GLint64;
+typedef uint64_t GLuint64;
+typedef ptrdiff_t GLintptr;
+typedef ptrdiff_t GLsizeiptr;
+typedef ptrdiff_t GLintptrARB;
+typedef ptrdiff_t GLsizeiptrARB;
+typedef struct __GLsync *GLsync;
+#endif
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+void *gl4_0compat_funcs();
+
+void gl4_0compat_glViewport(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl4_0compat_glDepthRange(void *_glfuncs, GLdouble nearVal, GLdouble farVal);
+GLboolean gl4_0compat_glIsEnabled(void *_glfuncs, GLenum cap);
+void gl4_0compat_glGetTexLevelParameteriv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLint* params);
+void gl4_0compat_glGetTexLevelParameterfv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLfloat* params);
+void gl4_0compat_glGetTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl4_0compat_glGetTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl4_0compat_glGetTexImage(void *_glfuncs, GLenum target, GLint level, GLenum format, GLenum gltype, GLvoid* pixels);
+void gl4_0compat_glGetIntegerv(void *_glfuncs, GLenum pname, GLint* params);
+void gl4_0compat_glGetFloatv(void *_glfuncs, GLenum pname, GLfloat* params);
+GLenum gl4_0compat_glGetError(void *_glfuncs);
+void gl4_0compat_glGetDoublev(void *_glfuncs, GLenum pname, GLdouble* params);
+void gl4_0compat_glGetBooleanv(void *_glfuncs, GLenum pname, GLboolean* params);
+void gl4_0compat_glReadPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum gltype, GLvoid* pixels);
+void gl4_0compat_glReadBuffer(void *_glfuncs, GLenum mode);
+void gl4_0compat_glPixelStorei(void *_glfuncs, GLenum pname, GLint param);
+void gl4_0compat_glPixelStoref(void *_glfuncs, GLenum pname, GLfloat param);
+void gl4_0compat_glDepthFunc(void *_glfuncs, GLenum glfunc);
+void gl4_0compat_glStencilOp(void *_glfuncs, GLenum fail, GLenum zfail, GLenum zpass);
+void gl4_0compat_glStencilFunc(void *_glfuncs, GLenum glfunc, GLint ref, GLuint mask);
+void gl4_0compat_glLogicOp(void *_glfuncs, GLenum opcode);
+void gl4_0compat_glBlendFunc(void *_glfuncs, GLenum sfactor, GLenum dfactor);
+void gl4_0compat_glFlush(void *_glfuncs);
+void gl4_0compat_glFinish(void *_glfuncs);
+void gl4_0compat_glEnable(void *_glfuncs, GLenum cap);
+void gl4_0compat_glDisable(void *_glfuncs, GLenum cap);
+void gl4_0compat_glDepthMask(void *_glfuncs, GLboolean flag);
+void gl4_0compat_glColorMask(void *_glfuncs, GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha);
+void gl4_0compat_glStencilMask(void *_glfuncs, GLuint mask);
+void gl4_0compat_glClearDepth(void *_glfuncs, GLdouble depth);
+void gl4_0compat_glClearStencil(void *_glfuncs, GLint s);
+void gl4_0compat_glClearColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl4_0compat_glClear(void *_glfuncs, GLbitfield mask);
+void gl4_0compat_glDrawBuffer(void *_glfuncs, GLenum mode);
+void gl4_0compat_glTexImage2D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl4_0compat_glTexImage1D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl4_0compat_glTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl4_0compat_glTexParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint param);
+void gl4_0compat_glTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl4_0compat_glTexParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param);
+void gl4_0compat_glScissor(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl4_0compat_glPolygonMode(void *_glfuncs, GLenum face, GLenum mode);
+void gl4_0compat_glPointSize(void *_glfuncs, GLfloat size);
+void gl4_0compat_glLineWidth(void *_glfuncs, GLfloat width);
+void gl4_0compat_glHint(void *_glfuncs, GLenum target, GLenum mode);
+void gl4_0compat_glFrontFace(void *_glfuncs, GLenum mode);
+void gl4_0compat_glCullFace(void *_glfuncs, GLenum mode);
+void gl4_0compat_glIndexubv(void *_glfuncs, const GLubyte* c);
+void gl4_0compat_glIndexub(void *_glfuncs, GLubyte c);
+GLboolean gl4_0compat_glIsTexture(void *_glfuncs, GLuint texture);
+void gl4_0compat_glGenTextures(void *_glfuncs, GLsizei n, GLuint* textures);
+void gl4_0compat_glDeleteTextures(void *_glfuncs, GLsizei n, const GLuint* textures);
+void gl4_0compat_glBindTexture(void *_glfuncs, GLenum target, GLuint texture);
+void gl4_0compat_glTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl4_0compat_glTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl4_0compat_glCopyTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl4_0compat_glCopyTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width);
+void gl4_0compat_glCopyTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border);
+void gl4_0compat_glCopyTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLint border);
+void gl4_0compat_glPolygonOffset(void *_glfuncs, GLfloat factor, GLfloat units);
+void gl4_0compat_glDrawElements(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices);
+void gl4_0compat_glDrawArrays(void *_glfuncs, GLenum mode, GLint first, GLsizei count);
+void gl4_0compat_glCopyTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl4_0compat_glTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl4_0compat_glTexImage3D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl4_0compat_glDrawRangeElements(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices);
+void gl4_0compat_glBlendEquation(void *_glfuncs, GLenum mode);
+void gl4_0compat_glBlendColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl4_0compat_glGetCompressedTexImage(void *_glfuncs, GLenum target, GLint level, GLvoid* img);
+void gl4_0compat_glCompressedTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid* data);
+void gl4_0compat_glCompressedTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid* data);
+void gl4_0compat_glCompressedTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid* data);
+void gl4_0compat_glCompressedTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid* data);
+void gl4_0compat_glCompressedTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid* data);
+void gl4_0compat_glCompressedTexImage3D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid* data);
+void gl4_0compat_glSampleCoverage(void *_glfuncs, GLfloat value, GLboolean invert);
+void gl4_0compat_glActiveTexture(void *_glfuncs, GLenum texture);
+void gl4_0compat_glPointParameteriv(void *_glfuncs, GLenum pname, const GLint* params);
+void gl4_0compat_glPointParameteri(void *_glfuncs, GLenum pname, GLint param);
+void gl4_0compat_glPointParameterfv(void *_glfuncs, GLenum pname, const GLfloat* params);
+void gl4_0compat_glPointParameterf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl4_0compat_glMultiDrawArrays(void *_glfuncs, GLenum mode, const GLint* first, const GLsizei* count, GLsizei drawcount);
+void gl4_0compat_glBlendFuncSeparate(void *_glfuncs, GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha);
+void gl4_0compat_glGetBufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+GLboolean gl4_0compat_glUnmapBuffer(void *_glfuncs, GLenum target);
+void gl4_0compat_glGetBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, GLvoid* data);
+void gl4_0compat_glBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid* data);
+void gl4_0compat_glBufferData(void *_glfuncs, GLenum target, GLsizeiptr size, const GLvoid* data, GLenum usage);
+GLboolean gl4_0compat_glIsBuffer(void *_glfuncs, GLuint buffer);
+void gl4_0compat_glGenBuffers(void *_glfuncs, GLsizei n, GLuint* buffers);
+void gl4_0compat_glDeleteBuffers(void *_glfuncs, GLsizei n, const GLuint* buffers);
+void gl4_0compat_glBindBuffer(void *_glfuncs, GLenum target, GLuint buffer);
+void gl4_0compat_glGetQueryObjectuiv(void *_glfuncs, GLuint id, GLenum pname, GLuint* params);
+void gl4_0compat_glGetQueryObjectiv(void *_glfuncs, GLuint id, GLenum pname, GLint* params);
+void gl4_0compat_glGetQueryiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl4_0compat_glEndQuery(void *_glfuncs, GLenum target);
+void gl4_0compat_glBeginQuery(void *_glfuncs, GLenum target, GLuint id);
+GLboolean gl4_0compat_glIsQuery(void *_glfuncs, GLuint id);
+void gl4_0compat_glDeleteQueries(void *_glfuncs, GLsizei n, const GLuint* ids);
+void gl4_0compat_glGenQueries(void *_glfuncs, GLsizei n, GLuint* ids);
+void gl4_0compat_glVertexAttribPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLboolean normalized, GLsizei stride, const GLvoid* offset);
+void gl4_0compat_glValidateProgram(void *_glfuncs, GLuint program);
+void gl4_0compat_glUniformMatrix4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_0compat_glUniformMatrix3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_0compat_glUniformMatrix2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_0compat_glUniform4iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl4_0compat_glUniform3iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl4_0compat_glUniform2iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl4_0compat_glUniform1iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl4_0compat_glUniform4fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl4_0compat_glUniform3fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl4_0compat_glUniform2fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl4_0compat_glUniform1fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl4_0compat_glUniform4i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2, GLint v3);
+void gl4_0compat_glUniform3i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2);
+void gl4_0compat_glUniform2i(void *_glfuncs, GLint location, GLint v0, GLint v1);
+void gl4_0compat_glUniform1i(void *_glfuncs, GLint location, GLint v0);
+void gl4_0compat_glUniform4f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3);
+void gl4_0compat_glUniform3f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2);
+void gl4_0compat_glUniform2f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1);
+void gl4_0compat_glUniform1f(void *_glfuncs, GLint location, GLfloat v0);
+void gl4_0compat_glUseProgram(void *_glfuncs, GLuint program);
+void gl4_0compat_glShaderSource(void *_glfuncs, GLuint shader, GLsizei count, const GLchar** source, const GLint* length);
+void gl4_0compat_glLinkProgram(void *_glfuncs, GLuint program);
+GLboolean gl4_0compat_glIsShader(void *_glfuncs, GLuint shader);
+GLboolean gl4_0compat_glIsProgram(void *_glfuncs, GLuint program);
+void gl4_0compat_glGetVertexAttribiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params);
+void gl4_0compat_glGetVertexAttribfv(void *_glfuncs, GLuint index, GLenum pname, GLfloat* params);
+void gl4_0compat_glGetVertexAttribdv(void *_glfuncs, GLuint index, GLenum pname, GLdouble* params);
+void gl4_0compat_glGetUniformiv(void *_glfuncs, GLuint program, GLint location, GLint* params);
+void gl4_0compat_glGetUniformfv(void *_glfuncs, GLuint program, GLint location, GLfloat* params);
+GLint gl4_0compat_glGetUniformLocation(void *_glfuncs, GLuint program, const GLchar* name);
+void gl4_0compat_glGetShaderSource(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* source);
+void gl4_0compat_glGetShaderInfoLog(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* infoLog);
+void gl4_0compat_glGetShaderiv(void *_glfuncs, GLuint shader, GLenum pname, GLint* params);
+void gl4_0compat_glGetProgramInfoLog(void *_glfuncs, GLuint program, GLsizei bufSize, GLsizei* length, GLchar* infoLog);
+void gl4_0compat_glGetProgramiv(void *_glfuncs, GLuint program, GLenum pname, GLint* params);
+GLint gl4_0compat_glGetAttribLocation(void *_glfuncs, GLuint program, const GLchar* name);
+void gl4_0compat_glGetAttachedShaders(void *_glfuncs, GLuint program, GLsizei maxCount, GLsizei* count, GLuint* obj);
+void gl4_0compat_glGetActiveUniform(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name);
+void gl4_0compat_glGetActiveAttrib(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name);
+void gl4_0compat_glEnableVertexAttribArray(void *_glfuncs, GLuint index);
+void gl4_0compat_glDisableVertexAttribArray(void *_glfuncs, GLuint index);
+void gl4_0compat_glDetachShader(void *_glfuncs, GLuint program, GLuint shader);
+void gl4_0compat_glDeleteShader(void *_glfuncs, GLuint shader);
+void gl4_0compat_glDeleteProgram(void *_glfuncs, GLuint program);
+GLuint gl4_0compat_glCreateShader(void *_glfuncs, GLenum gltype);
+GLuint gl4_0compat_glCreateProgram(void *_glfuncs);
+void gl4_0compat_glCompileShader(void *_glfuncs, GLuint shader);
+void gl4_0compat_glBindAttribLocation(void *_glfuncs, GLuint program, GLuint index, const GLchar* name);
+void gl4_0compat_glAttachShader(void *_glfuncs, GLuint program, GLuint shader);
+void gl4_0compat_glStencilMaskSeparate(void *_glfuncs, GLenum face, GLuint mask);
+void gl4_0compat_glStencilFuncSeparate(void *_glfuncs, GLenum face, GLenum glfunc, GLint ref, GLuint mask);
+void gl4_0compat_glStencilOpSeparate(void *_glfuncs, GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass);
+void gl4_0compat_glDrawBuffers(void *_glfuncs, GLsizei n, const GLenum* bufs);
+void gl4_0compat_glBlendEquationSeparate(void *_glfuncs, GLenum modeRGB, GLenum modeAlpha);
+void gl4_0compat_glUniformMatrix4x3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_0compat_glUniformMatrix3x4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_0compat_glUniformMatrix4x2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_0compat_glUniformMatrix2x4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_0compat_glUniformMatrix3x2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_0compat_glUniformMatrix2x3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+GLboolean gl4_0compat_glIsVertexArray(void *_glfuncs, GLuint array);
+void gl4_0compat_glGenVertexArrays(void *_glfuncs, GLsizei n, GLuint* arrays);
+void gl4_0compat_glDeleteVertexArrays(void *_glfuncs, GLsizei n, const GLuint* arrays);
+void gl4_0compat_glBindVertexArray(void *_glfuncs, GLuint array);
+void gl4_0compat_glFlushMappedBufferRange(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr length);
+void gl4_0compat_glFramebufferTextureLayer(void *_glfuncs, GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer);
+void gl4_0compat_glRenderbufferStorageMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLenum internalFormat, GLsizei width, GLsizei height);
+void gl4_0compat_glBlitFramebuffer(void *_glfuncs, GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter);
+void gl4_0compat_glGenerateMipmap(void *_glfuncs, GLenum target);
+void gl4_0compat_glGetFramebufferAttachmentParameteriv(void *_glfuncs, GLenum target, GLenum attachment, GLenum pname, GLint* params);
+void gl4_0compat_glFramebufferRenderbuffer(void *_glfuncs, GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer);
+void gl4_0compat_glFramebufferTexture3D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset);
+void gl4_0compat_glFramebufferTexture2D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+void gl4_0compat_glFramebufferTexture1D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+GLenum gl4_0compat_glCheckFramebufferStatus(void *_glfuncs, GLenum target);
+void gl4_0compat_glGenFramebuffers(void *_glfuncs, GLsizei n, GLuint* framebuffers);
+void gl4_0compat_glDeleteFramebuffers(void *_glfuncs, GLsizei n, const GLuint* framebuffers);
+void gl4_0compat_glBindFramebuffer(void *_glfuncs, GLenum target, GLuint framebuffer);
+GLboolean gl4_0compat_glIsFramebuffer(void *_glfuncs, GLuint framebuffer);
+void gl4_0compat_glGetRenderbufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl4_0compat_glRenderbufferStorage(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height);
+void gl4_0compat_glGenRenderbuffers(void *_glfuncs, GLsizei n, GLuint* renderbuffers);
+void gl4_0compat_glDeleteRenderbuffers(void *_glfuncs, GLsizei n, const GLuint* renderbuffers);
+void gl4_0compat_glBindRenderbuffer(void *_glfuncs, GLenum target, GLuint renderbuffer);
+GLboolean gl4_0compat_glIsRenderbuffer(void *_glfuncs, GLuint renderbuffer);
+void gl4_0compat_glClearBufferfi(void *_glfuncs, GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil);
+void gl4_0compat_glClearBufferfv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLfloat* value);
+void gl4_0compat_glClearBufferuiv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLuint* value);
+void gl4_0compat_glClearBufferiv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLint* value);
+void gl4_0compat_glGetTexParameterIuiv(void *_glfuncs, GLenum target, GLenum pname, GLuint* params);
+void gl4_0compat_glGetTexParameterIiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl4_0compat_glTexParameterIuiv(void *_glfuncs, GLenum target, GLenum pname, const GLuint* params);
+void gl4_0compat_glTexParameterIiv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl4_0compat_glUniform4uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value);
+void gl4_0compat_glUniform3uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value);
+void gl4_0compat_glUniform2uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value);
+void gl4_0compat_glUniform1uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value);
+void gl4_0compat_glUniform4ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3);
+void gl4_0compat_glUniform3ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1, GLuint v2);
+void gl4_0compat_glUniform2ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1);
+void gl4_0compat_glUniform1ui(void *_glfuncs, GLint location, GLuint v0);
+GLint gl4_0compat_glGetFragDataLocation(void *_glfuncs, GLuint program, const GLchar* name);
+void gl4_0compat_glBindFragDataLocation(void *_glfuncs, GLuint program, GLuint color, const GLchar* name);
+void gl4_0compat_glGetUniformuiv(void *_glfuncs, GLuint program, GLint location, GLuint* params);
+void gl4_0compat_glGetVertexAttribIuiv(void *_glfuncs, GLuint index, GLenum pname, GLuint* params);
+void gl4_0compat_glGetVertexAttribIiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params);
+void gl4_0compat_glVertexAttribIPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl4_0compat_glEndConditionalRender(void *_glfuncs);
+void gl4_0compat_glBeginConditionalRender(void *_glfuncs, GLuint id, GLenum mode);
+void gl4_0compat_glClampColor(void *_glfuncs, GLenum target, GLenum clamp);
+void gl4_0compat_glGetTransformFeedbackVarying(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLsizei* size, GLenum* gltype, GLchar* name);
+void gl4_0compat_glBindBufferBase(void *_glfuncs, GLenum target, GLuint index, GLuint buffer);
+void gl4_0compat_glBindBufferRange(void *_glfuncs, GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size);
+void gl4_0compat_glEndTransformFeedback(void *_glfuncs);
+void gl4_0compat_glBeginTransformFeedback(void *_glfuncs, GLenum primitiveMode);
+GLboolean gl4_0compat_glIsEnabledi(void *_glfuncs, GLenum target, GLuint index);
+void gl4_0compat_glDisablei(void *_glfuncs, GLenum target, GLuint index);
+void gl4_0compat_glEnablei(void *_glfuncs, GLenum target, GLuint index);
+void gl4_0compat_glGetIntegeri_v(void *_glfuncs, GLenum target, GLuint index, GLint* data);
+void gl4_0compat_glGetBooleani_v(void *_glfuncs, GLenum target, GLuint index, GLboolean* data);
+void gl4_0compat_glColorMaski(void *_glfuncs, GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a);
+void gl4_0compat_glCopyBufferSubData(void *_glfuncs, GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size);
+void gl4_0compat_glUniformBlockBinding(void *_glfuncs, GLuint program, GLuint v0, GLuint v1);
+void gl4_0compat_glGetActiveUniformBlockName(void *_glfuncs, GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei* length, GLchar* uniformBlockName);
+void gl4_0compat_glGetActiveUniformBlockiv(void *_glfuncs, GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint* params);
+GLuint gl4_0compat_glGetUniformBlockIndex(void *_glfuncs, GLuint program, const GLchar* uniformBlockName);
+void gl4_0compat_glGetActiveUniformName(void *_glfuncs, GLuint program, GLuint uniformIndex, GLsizei bufSize, GLsizei* length, GLchar* uniformName);
+void gl4_0compat_glGetActiveUniformsiv(void *_glfuncs, GLuint program, GLsizei uniformCount, const GLuint* uniformIndices, GLenum pname, GLint* params);
+void gl4_0compat_glPrimitiveRestartIndex(void *_glfuncs, GLuint index);
+void gl4_0compat_glTexBuffer(void *_glfuncs, GLenum target, GLenum internalFormat, GLuint buffer);
+void gl4_0compat_glDrawElementsInstanced(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount);
+void gl4_0compat_glDrawArraysInstanced(void *_glfuncs, GLenum mode, GLint first, GLsizei count, GLsizei instancecount);
+void gl4_0compat_glSampleMaski(void *_glfuncs, GLuint index, GLbitfield mask);
+void gl4_0compat_glGetMultisamplefv(void *_glfuncs, GLenum pname, GLuint index, GLfloat* val);
+void gl4_0compat_glTexImage3DMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations);
+void gl4_0compat_glTexImage2DMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLint internalFormat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations);
+void gl4_0compat_glGetSynciv(void *_glfuncs, GLsync sync, GLenum pname, GLsizei bufSize, GLsizei* length, GLint* values);
+void gl4_0compat_glGetInteger64v(void *_glfuncs, GLenum pname, GLint64* params);
+void gl4_0compat_glWaitSync(void *_glfuncs, GLsync sync, GLbitfield flags, GLuint64 timeout);
+GLenum gl4_0compat_glClientWaitSync(void *_glfuncs, GLsync sync, GLbitfield flags, GLuint64 timeout);
+void gl4_0compat_glDeleteSync(void *_glfuncs, GLsync sync);
+GLboolean gl4_0compat_glIsSync(void *_glfuncs, GLsync sync);
+GLsync gl4_0compat_glFenceSync(void *_glfuncs, GLenum condition, GLbitfield flags);
+void gl4_0compat_glProvokingVertex(void *_glfuncs, GLenum mode);
+void gl4_0compat_glDrawElementsInstancedBaseVertex(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount, GLint basevertex);
+void gl4_0compat_glDrawRangeElementsBaseVertex(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices, GLint basevertex);
+void gl4_0compat_glDrawElementsBaseVertex(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLint basevertex);
+void gl4_0compat_glFramebufferTexture(void *_glfuncs, GLenum target, GLenum attachment, GLuint texture, GLint level);
+void gl4_0compat_glGetBufferParameteri64v(void *_glfuncs, GLenum target, GLenum pname, GLint64* params);
+void gl4_0compat_glGetInteger64i_v(void *_glfuncs, GLenum target, GLuint index, GLint64* data);
+void gl4_0compat_glVertexAttribP4uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value);
+void gl4_0compat_glVertexAttribP4ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value);
+void gl4_0compat_glVertexAttribP3uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value);
+void gl4_0compat_glVertexAttribP3ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value);
+void gl4_0compat_glVertexAttribP2uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value);
+void gl4_0compat_glVertexAttribP2ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value);
+void gl4_0compat_glVertexAttribP1uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value);
+void gl4_0compat_glVertexAttribP1ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value);
+void gl4_0compat_glSecondaryColorP3uiv(void *_glfuncs, GLenum gltype, const GLuint* color);
+void gl4_0compat_glSecondaryColorP3ui(void *_glfuncs, GLenum gltype, GLuint color);
+void gl4_0compat_glColorP4uiv(void *_glfuncs, GLenum gltype, const GLuint* color);
+void gl4_0compat_glColorP4ui(void *_glfuncs, GLenum gltype, GLuint color);
+void gl4_0compat_glColorP3uiv(void *_glfuncs, GLenum gltype, const GLuint* color);
+void gl4_0compat_glColorP3ui(void *_glfuncs, GLenum gltype, GLuint color);
+void gl4_0compat_glNormalP3uiv(void *_glfuncs, GLenum gltype, const GLuint* coords);
+void gl4_0compat_glNormalP3ui(void *_glfuncs, GLenum gltype, GLuint coords);
+void gl4_0compat_glMultiTexCoordP4uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords);
+void gl4_0compat_glMultiTexCoordP4ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords);
+void gl4_0compat_glMultiTexCoordP3uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords);
+void gl4_0compat_glMultiTexCoordP3ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords);
+void gl4_0compat_glMultiTexCoordP2uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords);
+void gl4_0compat_glMultiTexCoordP2ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords);
+void gl4_0compat_glMultiTexCoordP1uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords);
+void gl4_0compat_glMultiTexCoordP1ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords);
+void gl4_0compat_glTexCoordP4uiv(void *_glfuncs, GLenum gltype, const GLuint* coords);
+void gl4_0compat_glTexCoordP4ui(void *_glfuncs, GLenum gltype, GLuint coords);
+void gl4_0compat_glTexCoordP3uiv(void *_glfuncs, GLenum gltype, const GLuint* coords);
+void gl4_0compat_glTexCoordP3ui(void *_glfuncs, GLenum gltype, GLuint coords);
+void gl4_0compat_glTexCoordP2uiv(void *_glfuncs, GLenum gltype, const GLuint* coords);
+void gl4_0compat_glTexCoordP2ui(void *_glfuncs, GLenum gltype, GLuint coords);
+void gl4_0compat_glTexCoordP1uiv(void *_glfuncs, GLenum gltype, const GLuint* coords);
+void gl4_0compat_glTexCoordP1ui(void *_glfuncs, GLenum gltype, GLuint coords);
+void gl4_0compat_glVertexP4uiv(void *_glfuncs, GLenum gltype, const GLuint* value);
+void gl4_0compat_glVertexP4ui(void *_glfuncs, GLenum gltype, GLuint value);
+void gl4_0compat_glVertexP3uiv(void *_glfuncs, GLenum gltype, const GLuint* value);
+void gl4_0compat_glVertexP3ui(void *_glfuncs, GLenum gltype, GLuint value);
+void gl4_0compat_glVertexP2uiv(void *_glfuncs, GLenum gltype, const GLuint* value);
+void gl4_0compat_glVertexP2ui(void *_glfuncs, GLenum gltype, GLuint value);
+void gl4_0compat_glGetQueryObjectui64v(void *_glfuncs, GLuint id, GLenum pname, GLuint64* params);
+void gl4_0compat_glGetQueryObjecti64v(void *_glfuncs, GLuint id, GLenum pname, GLint64* params);
+void gl4_0compat_glQueryCounter(void *_glfuncs, GLuint id, GLenum target);
+void gl4_0compat_glGetSamplerParameterIuiv(void *_glfuncs, GLuint sampler, GLenum pname, GLuint* params);
+void gl4_0compat_glGetSamplerParameterfv(void *_glfuncs, GLuint sampler, GLenum pname, GLfloat* params);
+void gl4_0compat_glGetSamplerParameterIiv(void *_glfuncs, GLuint sampler, GLenum pname, GLint* params);
+void gl4_0compat_glGetSamplerParameteriv(void *_glfuncs, GLuint sampler, GLenum pname, GLint* params);
+void gl4_0compat_glSamplerParameterIuiv(void *_glfuncs, GLuint sampler, GLenum pname, const GLuint* param);
+void gl4_0compat_glSamplerParameterIiv(void *_glfuncs, GLuint sampler, GLenum pname, const GLint* param);
+void gl4_0compat_glSamplerParameterfv(void *_glfuncs, GLuint sampler, GLenum pname, const GLfloat* param);
+void gl4_0compat_glSamplerParameterf(void *_glfuncs, GLuint sampler, GLenum pname, GLfloat param);
+void gl4_0compat_glSamplerParameteriv(void *_glfuncs, GLuint sampler, GLenum pname, const GLint* param);
+void gl4_0compat_glSamplerParameteri(void *_glfuncs, GLuint sampler, GLenum pname, GLint param);
+void gl4_0compat_glBindSampler(void *_glfuncs, GLuint unit, GLuint sampler);
+GLboolean gl4_0compat_glIsSampler(void *_glfuncs, GLuint sampler);
+void gl4_0compat_glDeleteSamplers(void *_glfuncs, GLsizei count, const GLuint* samplers);
+void gl4_0compat_glGenSamplers(void *_glfuncs, GLsizei count, GLuint* samplers);
+GLint gl4_0compat_glGetFragDataIndex(void *_glfuncs, GLuint program, const GLchar* name);
+void gl4_0compat_glBindFragDataLocationIndexed(void *_glfuncs, GLuint program, GLuint colorNumber, GLuint index, const GLchar* name);
+void gl4_0compat_glVertexAttribDivisor(void *_glfuncs, GLuint index, GLuint divisor);
+void gl4_0compat_glGetQueryIndexediv(void *_glfuncs, GLenum target, GLuint index, GLenum pname, GLint* params);
+void gl4_0compat_glEndQueryIndexed(void *_glfuncs, GLenum target, GLuint index);
+void gl4_0compat_glBeginQueryIndexed(void *_glfuncs, GLenum target, GLuint index, GLuint id);
+void gl4_0compat_glDrawTransformFeedbackStream(void *_glfuncs, GLenum mode, GLuint id, GLuint stream);
+void gl4_0compat_glDrawTransformFeedback(void *_glfuncs, GLenum mode, GLuint id);
+void gl4_0compat_glResumeTransformFeedback(void *_glfuncs);
+void gl4_0compat_glPauseTransformFeedback(void *_glfuncs);
+GLboolean gl4_0compat_glIsTransformFeedback(void *_glfuncs, GLuint id);
+void gl4_0compat_glGenTransformFeedbacks(void *_glfuncs, GLsizei n, GLuint* ids);
+void gl4_0compat_glDeleteTransformFeedbacks(void *_glfuncs, GLsizei n, const GLuint* ids);
+void gl4_0compat_glBindTransformFeedback(void *_glfuncs, GLenum target, GLuint id);
+void gl4_0compat_glPatchParameterfv(void *_glfuncs, GLenum pname, const GLfloat* values);
+void gl4_0compat_glPatchParameteri(void *_glfuncs, GLenum pname, GLint value);
+void gl4_0compat_glGetProgramStageiv(void *_glfuncs, GLuint program, GLenum shadertype, GLenum pname, GLint* values);
+void gl4_0compat_glGetUniformSubroutineuiv(void *_glfuncs, GLenum shadertype, GLint location, GLuint* params);
+void gl4_0compat_glUniformSubroutinesuiv(void *_glfuncs, GLenum shadertype, GLsizei count, const GLuint* value);
+void gl4_0compat_glGetActiveSubroutineName(void *_glfuncs, GLuint program, GLenum shadertype, GLuint index, GLsizei bufSize, GLsizei* length, GLchar* name);
+void gl4_0compat_glGetActiveSubroutineUniformName(void *_glfuncs, GLuint program, GLenum shadertype, GLuint index, GLsizei bufSize, GLsizei* length, GLchar* name);
+void gl4_0compat_glGetActiveSubroutineUniformiv(void *_glfuncs, GLuint program, GLenum shadertype, GLuint index, GLenum pname, GLint* values);
+GLuint gl4_0compat_glGetSubroutineIndex(void *_glfuncs, GLuint program, GLenum shadertype, const GLchar* name);
+GLint gl4_0compat_glGetSubroutineUniformLocation(void *_glfuncs, GLuint program, GLenum shadertype, const GLchar* name);
+void gl4_0compat_glGetUniformdv(void *_glfuncs, GLuint program, GLint location, GLdouble* params);
+void gl4_0compat_glUniformMatrix4x3dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_0compat_glUniformMatrix4x2dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_0compat_glUniformMatrix3x4dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_0compat_glUniformMatrix3x2dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_0compat_glUniformMatrix2x4dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_0compat_glUniformMatrix2x3dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_0compat_glUniformMatrix4dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_0compat_glUniformMatrix3dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_0compat_glUniformMatrix2dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_0compat_glUniform4dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value);
+void gl4_0compat_glUniform3dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value);
+void gl4_0compat_glUniform2dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value);
+void gl4_0compat_glUniform1dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value);
+void gl4_0compat_glUniform4d(void *_glfuncs, GLint location, GLdouble v0, GLdouble v1, GLdouble v2, GLdouble v3);
+void gl4_0compat_glUniform3d(void *_glfuncs, GLint location, GLdouble v0, GLdouble v1, GLdouble v2);
+void gl4_0compat_glUniform2d(void *_glfuncs, GLint location, GLdouble v0, GLdouble v1);
+void gl4_0compat_glUniform1d(void *_glfuncs, GLint location, GLdouble v0);
+void gl4_0compat_glDrawElementsIndirect(void *_glfuncs, GLenum mode, GLenum gltype, const GLvoid* indirect);
+void gl4_0compat_glDrawArraysIndirect(void *_glfuncs, GLenum mode, const GLvoid* indirect);
+void gl4_0compat_glBlendFuncSeparatei(void *_glfuncs, GLuint buf, GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha, GLenum dstAlpha);
+void gl4_0compat_glBlendFunci(void *_glfuncs, GLuint buf, GLenum src, GLenum dst);
+void gl4_0compat_glBlendEquationSeparatei(void *_glfuncs, GLuint buf, GLenum modeRGB, GLenum modeAlpha);
+void gl4_0compat_glBlendEquationi(void *_glfuncs, GLuint buf, GLenum mode);
+void gl4_0compat_glMinSampleShading(void *_glfuncs, GLfloat value);
+void gl4_0compat_glTranslatef(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl4_0compat_glTranslated(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl4_0compat_glScalef(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl4_0compat_glScaled(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl4_0compat_glRotatef(void *_glfuncs, GLfloat angle, GLfloat x, GLfloat y, GLfloat z);
+void gl4_0compat_glRotated(void *_glfuncs, GLdouble angle, GLdouble x, GLdouble y, GLdouble z);
+void gl4_0compat_glPushMatrix(void *_glfuncs);
+void gl4_0compat_glPopMatrix(void *_glfuncs);
+void gl4_0compat_glOrtho(void *_glfuncs, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+void gl4_0compat_glMultMatrixd(void *_glfuncs, const GLdouble* m);
+void gl4_0compat_glMultMatrixf(void *_glfuncs, const GLfloat* m);
+void gl4_0compat_glMatrixMode(void *_glfuncs, GLenum mode);
+void gl4_0compat_glLoadMatrixd(void *_glfuncs, const GLdouble* m);
+void gl4_0compat_glLoadMatrixf(void *_glfuncs, const GLfloat* m);
+void gl4_0compat_glLoadIdentity(void *_glfuncs);
+void gl4_0compat_glFrustum(void *_glfuncs, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+GLboolean gl4_0compat_glIsList(void *_glfuncs, GLuint list);
+void gl4_0compat_glGetTexGeniv(void *_glfuncs, GLenum coord, GLenum pname, GLint* params);
+void gl4_0compat_glGetTexGenfv(void *_glfuncs, GLenum coord, GLenum pname, GLfloat* params);
+void gl4_0compat_glGetTexGendv(void *_glfuncs, GLenum coord, GLenum pname, GLdouble* params);
+void gl4_0compat_glGetTexEnviv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl4_0compat_glGetTexEnvfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl4_0compat_glGetPolygonStipple(void *_glfuncs, GLubyte* mask);
+void gl4_0compat_glGetPixelMapusv(void *_glfuncs, GLenum glmap, GLushort* values);
+void gl4_0compat_glGetPixelMapuiv(void *_glfuncs, GLenum glmap, GLuint* values);
+void gl4_0compat_glGetPixelMapfv(void *_glfuncs, GLenum glmap, GLfloat* values);
+void gl4_0compat_glGetMaterialiv(void *_glfuncs, GLenum face, GLenum pname, GLint* params);
+void gl4_0compat_glGetMaterialfv(void *_glfuncs, GLenum face, GLenum pname, GLfloat* params);
+void gl4_0compat_glGetMapiv(void *_glfuncs, GLenum target, GLenum query, GLint* v);
+void gl4_0compat_glGetMapfv(void *_glfuncs, GLenum target, GLenum query, GLfloat* v);
+void gl4_0compat_glGetMapdv(void *_glfuncs, GLenum target, GLenum query, GLdouble* v);
+void gl4_0compat_glGetLightiv(void *_glfuncs, GLenum light, GLenum pname, GLint* params);
+void gl4_0compat_glGetLightfv(void *_glfuncs, GLenum light, GLenum pname, GLfloat* params);
+void gl4_0compat_glGetClipPlane(void *_glfuncs, GLenum plane, GLdouble* equation);
+void gl4_0compat_glDrawPixels(void *_glfuncs, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl4_0compat_glCopyPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum gltype);
+void gl4_0compat_glPixelMapusv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLushort* values);
+void gl4_0compat_glPixelMapuiv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLuint* values);
+void gl4_0compat_glPixelMapfv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLfloat* values);
+void gl4_0compat_glPixelTransferi(void *_glfuncs, GLenum pname, GLint param);
+void gl4_0compat_glPixelTransferf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl4_0compat_glPixelZoom(void *_glfuncs, GLfloat xfactor, GLfloat yfactor);
+void gl4_0compat_glAlphaFunc(void *_glfuncs, GLenum glfunc, GLfloat ref);
+void gl4_0compat_glEvalPoint2(void *_glfuncs, GLint i, GLint j);
+void gl4_0compat_glEvalMesh2(void *_glfuncs, GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2);
+void gl4_0compat_glEvalPoint1(void *_glfuncs, GLint i);
+void gl4_0compat_glEvalMesh1(void *_glfuncs, GLenum mode, GLint i1, GLint i2);
+void gl4_0compat_glEvalCoord2fv(void *_glfuncs, const GLfloat* u);
+void gl4_0compat_glEvalCoord2f(void *_glfuncs, GLfloat u, GLfloat v);
+void gl4_0compat_glEvalCoord2dv(void *_glfuncs, const GLdouble* u);
+void gl4_0compat_glEvalCoord2d(void *_glfuncs, GLdouble u, GLdouble v);
+void gl4_0compat_glEvalCoord1fv(void *_glfuncs, const GLfloat* u);
+void gl4_0compat_glEvalCoord1f(void *_glfuncs, GLfloat u);
+void gl4_0compat_glEvalCoord1dv(void *_glfuncs, const GLdouble* u);
+void gl4_0compat_glEvalCoord1d(void *_glfuncs, GLdouble u);
+void gl4_0compat_glMapGrid2f(void *_glfuncs, GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2);
+void gl4_0compat_glMapGrid2d(void *_glfuncs, GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2);
+void gl4_0compat_glMapGrid1f(void *_glfuncs, GLint un, GLfloat u1, GLfloat u2);
+void gl4_0compat_glMapGrid1d(void *_glfuncs, GLint un, GLdouble u1, GLdouble u2);
+void gl4_0compat_glMap2f(void *_glfuncs, GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat* points);
+void gl4_0compat_glMap2d(void *_glfuncs, GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble* points);
+void gl4_0compat_glMap1f(void *_glfuncs, GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat* points);
+void gl4_0compat_glMap1d(void *_glfuncs, GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble* points);
+void gl4_0compat_glPushAttrib(void *_glfuncs, GLbitfield mask);
+void gl4_0compat_glPopAttrib(void *_glfuncs);
+void gl4_0compat_glAccum(void *_glfuncs, GLenum op, GLfloat value);
+void gl4_0compat_glIndexMask(void *_glfuncs, GLuint mask);
+void gl4_0compat_glClearIndex(void *_glfuncs, GLfloat c);
+void gl4_0compat_glClearAccum(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl4_0compat_glPushName(void *_glfuncs, GLuint name);
+void gl4_0compat_glPopName(void *_glfuncs);
+void gl4_0compat_glPassThrough(void *_glfuncs, GLfloat token);
+void gl4_0compat_glLoadName(void *_glfuncs, GLuint name);
+void gl4_0compat_glInitNames(void *_glfuncs);
+GLint gl4_0compat_glRenderMode(void *_glfuncs, GLenum mode);
+void gl4_0compat_glSelectBuffer(void *_glfuncs, GLsizei size, GLuint* buffer);
+void gl4_0compat_glFeedbackBuffer(void *_glfuncs, GLsizei size, GLenum gltype, GLfloat* buffer);
+void gl4_0compat_glTexGeniv(void *_glfuncs, GLenum coord, GLenum pname, const GLint* params);
+void gl4_0compat_glTexGeni(void *_glfuncs, GLenum coord, GLenum pname, GLint param);
+void gl4_0compat_glTexGenfv(void *_glfuncs, GLenum coord, GLenum pname, const GLfloat* params);
+void gl4_0compat_glTexGenf(void *_glfuncs, GLenum coord, GLenum pname, GLfloat param);
+void gl4_0compat_glTexGendv(void *_glfuncs, GLenum coord, GLenum pname, const GLdouble* params);
+void gl4_0compat_glTexGend(void *_glfuncs, GLenum coord, GLenum pname, GLdouble param);
+void gl4_0compat_glTexEnviv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl4_0compat_glTexEnvi(void *_glfuncs, GLenum target, GLenum pname, GLint param);
+void gl4_0compat_glTexEnvfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl4_0compat_glTexEnvf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param);
+void gl4_0compat_glShadeModel(void *_glfuncs, GLenum mode);
+void gl4_0compat_glPolygonStipple(void *_glfuncs, const GLubyte* mask);
+void gl4_0compat_glMaterialiv(void *_glfuncs, GLenum face, GLenum pname, const GLint* params);
+void gl4_0compat_glMateriali(void *_glfuncs, GLenum face, GLenum pname, GLint param);
+void gl4_0compat_glMaterialfv(void *_glfuncs, GLenum face, GLenum pname, const GLfloat* params);
+void gl4_0compat_glMaterialf(void *_glfuncs, GLenum face, GLenum pname, GLfloat param);
+void gl4_0compat_glLineStipple(void *_glfuncs, GLint factor, GLushort pattern);
+void gl4_0compat_glLightModeliv(void *_glfuncs, GLenum pname, const GLint* params);
+void gl4_0compat_glLightModeli(void *_glfuncs, GLenum pname, GLint param);
+void gl4_0compat_glLightModelfv(void *_glfuncs, GLenum pname, const GLfloat* params);
+void gl4_0compat_glLightModelf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl4_0compat_glLightiv(void *_glfuncs, GLenum light, GLenum pname, const GLint* params);
+void gl4_0compat_glLighti(void *_glfuncs, GLenum light, GLenum pname, GLint param);
+void gl4_0compat_glLightfv(void *_glfuncs, GLenum light, GLenum pname, const GLfloat* params);
+void gl4_0compat_glLightf(void *_glfuncs, GLenum light, GLenum pname, GLfloat param);
+void gl4_0compat_glFogiv(void *_glfuncs, GLenum pname, const GLint* params);
+void gl4_0compat_glFogi(void *_glfuncs, GLenum pname, GLint param);
+void gl4_0compat_glFogfv(void *_glfuncs, GLenum pname, const GLfloat* params);
+void gl4_0compat_glFogf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl4_0compat_glColorMaterial(void *_glfuncs, GLenum face, GLenum mode);
+void gl4_0compat_glClipPlane(void *_glfuncs, GLenum plane, const GLdouble* equation);
+void gl4_0compat_glVertex4sv(void *_glfuncs, const GLshort* v);
+void gl4_0compat_glVertex4s(void *_glfuncs, GLshort x, GLshort y, GLshort z, GLshort w);
+void gl4_0compat_glVertex4iv(void *_glfuncs, const GLint* v);
+void gl4_0compat_glVertex4i(void *_glfuncs, GLint x, GLint y, GLint z, GLint w);
+void gl4_0compat_glVertex4fv(void *_glfuncs, const GLfloat* v);
+void gl4_0compat_glVertex4f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+void gl4_0compat_glVertex4dv(void *_glfuncs, const GLdouble* v);
+void gl4_0compat_glVertex4d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+void gl4_0compat_glVertex3sv(void *_glfuncs, const GLshort* v);
+void gl4_0compat_glVertex3s(void *_glfuncs, GLshort x, GLshort y, GLshort z);
+void gl4_0compat_glVertex3iv(void *_glfuncs, const GLint* v);
+void gl4_0compat_glVertex3i(void *_glfuncs, GLint x, GLint y, GLint z);
+void gl4_0compat_glVertex3fv(void *_glfuncs, const GLfloat* v);
+void gl4_0compat_glVertex3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl4_0compat_glVertex3dv(void *_glfuncs, const GLdouble* v);
+void gl4_0compat_glVertex3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl4_0compat_glVertex2sv(void *_glfuncs, const GLshort* v);
+void gl4_0compat_glVertex2s(void *_glfuncs, GLshort x, GLshort y);
+void gl4_0compat_glVertex2iv(void *_glfuncs, const GLint* v);
+void gl4_0compat_glVertex2i(void *_glfuncs, GLint x, GLint y);
+void gl4_0compat_glVertex2fv(void *_glfuncs, const GLfloat* v);
+void gl4_0compat_glVertex2f(void *_glfuncs, GLfloat x, GLfloat y);
+void gl4_0compat_glVertex2dv(void *_glfuncs, const GLdouble* v);
+void gl4_0compat_glVertex2d(void *_glfuncs, GLdouble x, GLdouble y);
+void gl4_0compat_glTexCoord4sv(void *_glfuncs, const GLshort* v);
+void gl4_0compat_glTexCoord4s(void *_glfuncs, GLshort s, GLshort t, GLshort r, GLshort q);
+void gl4_0compat_glTexCoord4iv(void *_glfuncs, const GLint* v);
+void gl4_0compat_glTexCoord4i(void *_glfuncs, GLint s, GLint t, GLint r, GLint q);
+void gl4_0compat_glTexCoord4fv(void *_glfuncs, const GLfloat* v);
+void gl4_0compat_glTexCoord4f(void *_glfuncs, GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+void gl4_0compat_glTexCoord4dv(void *_glfuncs, const GLdouble* v);
+void gl4_0compat_glTexCoord4d(void *_glfuncs, GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+void gl4_0compat_glTexCoord3sv(void *_glfuncs, const GLshort* v);
+void gl4_0compat_glTexCoord3s(void *_glfuncs, GLshort s, GLshort t, GLshort r);
+void gl4_0compat_glTexCoord3iv(void *_glfuncs, const GLint* v);
+void gl4_0compat_glTexCoord3i(void *_glfuncs, GLint s, GLint t, GLint r);
+void gl4_0compat_glTexCoord3fv(void *_glfuncs, const GLfloat* v);
+void gl4_0compat_glTexCoord3f(void *_glfuncs, GLfloat s, GLfloat t, GLfloat r);
+void gl4_0compat_glTexCoord3dv(void *_glfuncs, const GLdouble* v);
+void gl4_0compat_glTexCoord3d(void *_glfuncs, GLdouble s, GLdouble t, GLdouble r);
+void gl4_0compat_glTexCoord2sv(void *_glfuncs, const GLshort* v);
+void gl4_0compat_glTexCoord2s(void *_glfuncs, GLshort s, GLshort t);
+void gl4_0compat_glTexCoord2iv(void *_glfuncs, const GLint* v);
+void gl4_0compat_glTexCoord2i(void *_glfuncs, GLint s, GLint t);
+void gl4_0compat_glTexCoord2fv(void *_glfuncs, const GLfloat* v);
+void gl4_0compat_glTexCoord2f(void *_glfuncs, GLfloat s, GLfloat t);
+void gl4_0compat_glTexCoord2dv(void *_glfuncs, const GLdouble* v);
+void gl4_0compat_glTexCoord2d(void *_glfuncs, GLdouble s, GLdouble t);
+void gl4_0compat_glTexCoord1sv(void *_glfuncs, const GLshort* v);
+void gl4_0compat_glTexCoord1s(void *_glfuncs, GLshort s);
+void gl4_0compat_glTexCoord1iv(void *_glfuncs, const GLint* v);
+void gl4_0compat_glTexCoord1i(void *_glfuncs, GLint s);
+void gl4_0compat_glTexCoord1fv(void *_glfuncs, const GLfloat* v);
+void gl4_0compat_glTexCoord1f(void *_glfuncs, GLfloat s);
+void gl4_0compat_glTexCoord1dv(void *_glfuncs, const GLdouble* v);
+void gl4_0compat_glTexCoord1d(void *_glfuncs, GLdouble s);
+void gl4_0compat_glRectsv(void *_glfuncs, const GLshort* v1, const GLshort* v2);
+void gl4_0compat_glRects(void *_glfuncs, GLshort x1, GLshort y1, GLshort x2, GLshort y2);
+void gl4_0compat_glRectiv(void *_glfuncs, const GLint* v1, const GLint* v2);
+void gl4_0compat_glRecti(void *_glfuncs, GLint x1, GLint y1, GLint x2, GLint y2);
+void gl4_0compat_glRectfv(void *_glfuncs, const GLfloat* v1, const GLfloat* v2);
+void gl4_0compat_glRectf(void *_glfuncs, GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2);
+void gl4_0compat_glRectdv(void *_glfuncs, const GLdouble* v1, const GLdouble* v2);
+void gl4_0compat_glRectd(void *_glfuncs, GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2);
+void gl4_0compat_glRasterPos4sv(void *_glfuncs, const GLshort* v);
+void gl4_0compat_glRasterPos4s(void *_glfuncs, GLshort x, GLshort y, GLshort z, GLshort w);
+void gl4_0compat_glRasterPos4iv(void *_glfuncs, const GLint* v);
+void gl4_0compat_glRasterPos4i(void *_glfuncs, GLint x, GLint y, GLint z, GLint w);
+void gl4_0compat_glRasterPos4fv(void *_glfuncs, const GLfloat* v);
+void gl4_0compat_glRasterPos4f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+void gl4_0compat_glRasterPos4dv(void *_glfuncs, const GLdouble* v);
+void gl4_0compat_glRasterPos4d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+void gl4_0compat_glRasterPos3sv(void *_glfuncs, const GLshort* v);
+void gl4_0compat_glRasterPos3s(void *_glfuncs, GLshort x, GLshort y, GLshort z);
+void gl4_0compat_glRasterPos3iv(void *_glfuncs, const GLint* v);
+void gl4_0compat_glRasterPos3i(void *_glfuncs, GLint x, GLint y, GLint z);
+void gl4_0compat_glRasterPos3fv(void *_glfuncs, const GLfloat* v);
+void gl4_0compat_glRasterPos3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl4_0compat_glRasterPos3dv(void *_glfuncs, const GLdouble* v);
+void gl4_0compat_glRasterPos3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl4_0compat_glRasterPos2sv(void *_glfuncs, const GLshort* v);
+void gl4_0compat_glRasterPos2s(void *_glfuncs, GLshort x, GLshort y);
+void gl4_0compat_glRasterPos2iv(void *_glfuncs, const GLint* v);
+void gl4_0compat_glRasterPos2i(void *_glfuncs, GLint x, GLint y);
+void gl4_0compat_glRasterPos2fv(void *_glfuncs, const GLfloat* v);
+void gl4_0compat_glRasterPos2f(void *_glfuncs, GLfloat x, GLfloat y);
+void gl4_0compat_glRasterPos2dv(void *_glfuncs, const GLdouble* v);
+void gl4_0compat_glRasterPos2d(void *_glfuncs, GLdouble x, GLdouble y);
+void gl4_0compat_glNormal3sv(void *_glfuncs, const GLshort* v);
+void gl4_0compat_glNormal3s(void *_glfuncs, GLshort nx, GLshort ny, GLshort nz);
+void gl4_0compat_glNormal3iv(void *_glfuncs, const GLint* v);
+void gl4_0compat_glNormal3i(void *_glfuncs, GLint nx, GLint ny, GLint nz);
+void gl4_0compat_glNormal3fv(void *_glfuncs, const GLfloat* v);
+void gl4_0compat_glNormal3f(void *_glfuncs, GLfloat nx, GLfloat ny, GLfloat nz);
+void gl4_0compat_glNormal3dv(void *_glfuncs, const GLdouble* v);
+void gl4_0compat_glNormal3d(void *_glfuncs, GLdouble nx, GLdouble ny, GLdouble nz);
+void gl4_0compat_glNormal3bv(void *_glfuncs, const GLbyte* v);
+void gl4_0compat_glNormal3b(void *_glfuncs, GLbyte nx, GLbyte ny, GLbyte nz);
+void gl4_0compat_glIndexsv(void *_glfuncs, const GLshort* c);
+void gl4_0compat_glIndexs(void *_glfuncs, GLshort c);
+void gl4_0compat_glIndexiv(void *_glfuncs, const GLint* c);
+void gl4_0compat_glIndexi(void *_glfuncs, GLint c);
+void gl4_0compat_glIndexfv(void *_glfuncs, const GLfloat* c);
+void gl4_0compat_glIndexf(void *_glfuncs, GLfloat c);
+void gl4_0compat_glIndexdv(void *_glfuncs, const GLdouble* c);
+void gl4_0compat_glIndexd(void *_glfuncs, GLdouble c);
+void gl4_0compat_glEnd(void *_glfuncs);
+void gl4_0compat_glEdgeFlagv(void *_glfuncs, const GLboolean* flag);
+void gl4_0compat_glEdgeFlag(void *_glfuncs, GLboolean flag);
+void gl4_0compat_glColor4usv(void *_glfuncs, const GLushort* v);
+void gl4_0compat_glColor4us(void *_glfuncs, GLushort red, GLushort green, GLushort blue, GLushort alpha);
+void gl4_0compat_glColor4uiv(void *_glfuncs, const GLuint* v);
+void gl4_0compat_glColor4ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue, GLuint alpha);
+void gl4_0compat_glColor4ubv(void *_glfuncs, const GLubyte* v);
+void gl4_0compat_glColor4ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha);
+void gl4_0compat_glColor4sv(void *_glfuncs, const GLshort* v);
+void gl4_0compat_glColor4s(void *_glfuncs, GLshort red, GLshort green, GLshort blue, GLshort alpha);
+void gl4_0compat_glColor4iv(void *_glfuncs, const GLint* v);
+void gl4_0compat_glColor4i(void *_glfuncs, GLint red, GLint green, GLint blue, GLint alpha);
+void gl4_0compat_glColor4fv(void *_glfuncs, const GLfloat* v);
+void gl4_0compat_glColor4f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl4_0compat_glColor4dv(void *_glfuncs, const GLdouble* v);
+void gl4_0compat_glColor4d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha);
+void gl4_0compat_glColor4bv(void *_glfuncs, const GLbyte* v);
+void gl4_0compat_glColor4b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha);
+void gl4_0compat_glColor3usv(void *_glfuncs, const GLushort* v);
+void gl4_0compat_glColor3us(void *_glfuncs, GLushort red, GLushort green, GLushort blue);
+void gl4_0compat_glColor3uiv(void *_glfuncs, const GLuint* v);
+void gl4_0compat_glColor3ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue);
+void gl4_0compat_glColor3ubv(void *_glfuncs, const GLubyte* v);
+void gl4_0compat_glColor3ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue);
+void gl4_0compat_glColor3sv(void *_glfuncs, const GLshort* v);
+void gl4_0compat_glColor3s(void *_glfuncs, GLshort red, GLshort green, GLshort blue);
+void gl4_0compat_glColor3iv(void *_glfuncs, const GLint* v);
+void gl4_0compat_glColor3i(void *_glfuncs, GLint red, GLint green, GLint blue);
+void gl4_0compat_glColor3fv(void *_glfuncs, const GLfloat* v);
+void gl4_0compat_glColor3f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue);
+void gl4_0compat_glColor3dv(void *_glfuncs, const GLdouble* v);
+void gl4_0compat_glColor3d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue);
+void gl4_0compat_glColor3bv(void *_glfuncs, const GLbyte* v);
+void gl4_0compat_glColor3b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue);
+void gl4_0compat_glBitmap(void *_glfuncs, GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte* bitmap);
+void gl4_0compat_glBegin(void *_glfuncs, GLenum mode);
+void gl4_0compat_glListBase(void *_glfuncs, GLuint base);
+GLuint gl4_0compat_glGenLists(void *_glfuncs, GLsizei range_);
+void gl4_0compat_glDeleteLists(void *_glfuncs, GLuint list, GLsizei range_);
+void gl4_0compat_glCallLists(void *_glfuncs, GLsizei n, GLenum gltype, const GLvoid* lists);
+void gl4_0compat_glCallList(void *_glfuncs, GLuint list);
+void gl4_0compat_glEndList(void *_glfuncs);
+void gl4_0compat_glNewList(void *_glfuncs, GLuint list, GLenum mode);
+void gl4_0compat_glPushClientAttrib(void *_glfuncs, GLbitfield mask);
+void gl4_0compat_glPopClientAttrib(void *_glfuncs);
+void gl4_0compat_glPrioritizeTextures(void *_glfuncs, GLsizei n, const GLuint* textures, const GLfloat* priorities);
+GLboolean gl4_0compat_glAreTexturesResident(void *_glfuncs, GLsizei n, const GLuint* textures, GLboolean* residences);
+void gl4_0compat_glVertexPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl4_0compat_glTexCoordPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl4_0compat_glNormalPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl4_0compat_glInterleavedArrays(void *_glfuncs, GLenum format, GLsizei stride, const GLvoid* pointer);
+void gl4_0compat_glIndexPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl4_0compat_glEnableClientState(void *_glfuncs, GLenum array);
+void gl4_0compat_glEdgeFlagPointer(void *_glfuncs, GLsizei stride, const GLvoid* pointer);
+void gl4_0compat_glDisableClientState(void *_glfuncs, GLenum array);
+void gl4_0compat_glColorPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl4_0compat_glArrayElement(void *_glfuncs, GLint i);
+void gl4_0compat_glResetMinmax(void *_glfuncs, GLenum target);
+void gl4_0compat_glResetHistogram(void *_glfuncs, GLenum target);
+void gl4_0compat_glMinmax(void *_glfuncs, GLenum target, GLenum internalFormat, GLboolean sink);
+void gl4_0compat_glHistogram(void *_glfuncs, GLenum target, GLsizei width, GLenum internalFormat, GLboolean sink);
+void gl4_0compat_glGetMinmaxParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl4_0compat_glGetMinmaxParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl4_0compat_glGetMinmax(void *_glfuncs, GLenum target, GLboolean reset, GLenum format, GLenum gltype, GLvoid* values);
+void gl4_0compat_glGetHistogramParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl4_0compat_glGetHistogramParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl4_0compat_glGetHistogram(void *_glfuncs, GLenum target, GLboolean reset, GLenum format, GLenum gltype, GLvoid* values);
+void gl4_0compat_glSeparableFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* row, const GLvoid* column);
+void gl4_0compat_glGetSeparableFilter(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* row, GLvoid* column, GLvoid* span);
+void gl4_0compat_glGetConvolutionParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl4_0compat_glGetConvolutionParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl4_0compat_glGetConvolutionFilter(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* image);
+void gl4_0compat_glCopyConvolutionFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl4_0compat_glCopyConvolutionFilter1D(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width);
+void gl4_0compat_glConvolutionParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl4_0compat_glConvolutionParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint params);
+void gl4_0compat_glConvolutionParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl4_0compat_glConvolutionParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat params);
+void gl4_0compat_glConvolutionFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* image);
+void gl4_0compat_glConvolutionFilter1D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLenum format, GLenum gltype, const GLvoid* image);
+void gl4_0compat_glCopyColorSubTable(void *_glfuncs, GLenum target, GLsizei start, GLint x, GLint y, GLsizei width);
+void gl4_0compat_glColorSubTable(void *_glfuncs, GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum gltype, const GLvoid* data);
+void gl4_0compat_glGetColorTableParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl4_0compat_glGetColorTableParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl4_0compat_glGetColorTable(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* table);
+void gl4_0compat_glCopyColorTable(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width);
+void gl4_0compat_glColorTableParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl4_0compat_glColorTableParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl4_0compat_glColorTable(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLenum format, GLenum gltype, const GLvoid* table);
+void gl4_0compat_glMultTransposeMatrixd(void *_glfuncs, const GLdouble* m);
+void gl4_0compat_glMultTransposeMatrixf(void *_glfuncs, const GLfloat* m);
+void gl4_0compat_glLoadTransposeMatrixd(void *_glfuncs, const GLdouble* m);
+void gl4_0compat_glLoadTransposeMatrixf(void *_glfuncs, const GLfloat* m);
+void gl4_0compat_glMultiTexCoord4sv(void *_glfuncs, GLenum target, const GLshort* v);
+void gl4_0compat_glMultiTexCoord4s(void *_glfuncs, GLenum target, GLshort s, GLshort t, GLshort r, GLshort q);
+void gl4_0compat_glMultiTexCoord4iv(void *_glfuncs, GLenum target, const GLint* v);
+void gl4_0compat_glMultiTexCoord4i(void *_glfuncs, GLenum target, GLint s, GLint t, GLint r, GLint q);
+void gl4_0compat_glMultiTexCoord4fv(void *_glfuncs, GLenum target, const GLfloat* v);
+void gl4_0compat_glMultiTexCoord4f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+void gl4_0compat_glMultiTexCoord4dv(void *_glfuncs, GLenum target, const GLdouble* v);
+void gl4_0compat_glMultiTexCoord4d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+void gl4_0compat_glMultiTexCoord3sv(void *_glfuncs, GLenum target, const GLshort* v);
+void gl4_0compat_glMultiTexCoord3s(void *_glfuncs, GLenum target, GLshort s, GLshort t, GLshort r);
+void gl4_0compat_glMultiTexCoord3iv(void *_glfuncs, GLenum target, const GLint* v);
+void gl4_0compat_glMultiTexCoord3i(void *_glfuncs, GLenum target, GLint s, GLint t, GLint r);
+void gl4_0compat_glMultiTexCoord3fv(void *_glfuncs, GLenum target, const GLfloat* v);
+void gl4_0compat_glMultiTexCoord3f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t, GLfloat r);
+void gl4_0compat_glMultiTexCoord3dv(void *_glfuncs, GLenum target, const GLdouble* v);
+void gl4_0compat_glMultiTexCoord3d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t, GLdouble r);
+void gl4_0compat_glMultiTexCoord2sv(void *_glfuncs, GLenum target, const GLshort* v);
+void gl4_0compat_glMultiTexCoord2s(void *_glfuncs, GLenum target, GLshort s, GLshort t);
+void gl4_0compat_glMultiTexCoord2iv(void *_glfuncs, GLenum target, const GLint* v);
+void gl4_0compat_glMultiTexCoord2i(void *_glfuncs, GLenum target, GLint s, GLint t);
+void gl4_0compat_glMultiTexCoord2fv(void *_glfuncs, GLenum target, const GLfloat* v);
+void gl4_0compat_glMultiTexCoord2f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t);
+void gl4_0compat_glMultiTexCoord2dv(void *_glfuncs, GLenum target, const GLdouble* v);
+void gl4_0compat_glMultiTexCoord2d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t);
+void gl4_0compat_glMultiTexCoord1sv(void *_glfuncs, GLenum target, const GLshort* v);
+void gl4_0compat_glMultiTexCoord1s(void *_glfuncs, GLenum target, GLshort s);
+void gl4_0compat_glMultiTexCoord1iv(void *_glfuncs, GLenum target, const GLint* v);
+void gl4_0compat_glMultiTexCoord1i(void *_glfuncs, GLenum target, GLint s);
+void gl4_0compat_glMultiTexCoord1fv(void *_glfuncs, GLenum target, const GLfloat* v);
+void gl4_0compat_glMultiTexCoord1f(void *_glfuncs, GLenum target, GLfloat s);
+void gl4_0compat_glMultiTexCoord1dv(void *_glfuncs, GLenum target, const GLdouble* v);
+void gl4_0compat_glMultiTexCoord1d(void *_glfuncs, GLenum target, GLdouble s);
+void gl4_0compat_glClientActiveTexture(void *_glfuncs, GLenum texture);
+void gl4_0compat_glWindowPos3sv(void *_glfuncs, const GLshort* v);
+void gl4_0compat_glWindowPos3s(void *_glfuncs, GLshort x, GLshort y, GLshort z);
+void gl4_0compat_glWindowPos3iv(void *_glfuncs, const GLint* v);
+void gl4_0compat_glWindowPos3i(void *_glfuncs, GLint x, GLint y, GLint z);
+void gl4_0compat_glWindowPos3fv(void *_glfuncs, const GLfloat* v);
+void gl4_0compat_glWindowPos3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl4_0compat_glWindowPos3dv(void *_glfuncs, const GLdouble* v);
+void gl4_0compat_glWindowPos3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl4_0compat_glWindowPos2sv(void *_glfuncs, const GLshort* v);
+void gl4_0compat_glWindowPos2s(void *_glfuncs, GLshort x, GLshort y);
+void gl4_0compat_glWindowPos2iv(void *_glfuncs, const GLint* v);
+void gl4_0compat_glWindowPos2i(void *_glfuncs, GLint x, GLint y);
+void gl4_0compat_glWindowPos2fv(void *_glfuncs, const GLfloat* v);
+void gl4_0compat_glWindowPos2f(void *_glfuncs, GLfloat x, GLfloat y);
+void gl4_0compat_glWindowPos2dv(void *_glfuncs, const GLdouble* v);
+void gl4_0compat_glWindowPos2d(void *_glfuncs, GLdouble x, GLdouble y);
+void gl4_0compat_glSecondaryColorPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl4_0compat_glSecondaryColor3usv(void *_glfuncs, const GLushort* v);
+void gl4_0compat_glSecondaryColor3us(void *_glfuncs, GLushort red, GLushort green, GLushort blue);
+void gl4_0compat_glSecondaryColor3uiv(void *_glfuncs, const GLuint* v);
+void gl4_0compat_glSecondaryColor3ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue);
+void gl4_0compat_glSecondaryColor3ubv(void *_glfuncs, const GLubyte* v);
+void gl4_0compat_glSecondaryColor3ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue);
+void gl4_0compat_glSecondaryColor3sv(void *_glfuncs, const GLshort* v);
+void gl4_0compat_glSecondaryColor3s(void *_glfuncs, GLshort red, GLshort green, GLshort blue);
+void gl4_0compat_glSecondaryColor3iv(void *_glfuncs, const GLint* v);
+void gl4_0compat_glSecondaryColor3i(void *_glfuncs, GLint red, GLint green, GLint blue);
+void gl4_0compat_glSecondaryColor3fv(void *_glfuncs, const GLfloat* v);
+void gl4_0compat_glSecondaryColor3f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue);
+void gl4_0compat_glSecondaryColor3dv(void *_glfuncs, const GLdouble* v);
+void gl4_0compat_glSecondaryColor3d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue);
+void gl4_0compat_glSecondaryColor3bv(void *_glfuncs, const GLbyte* v);
+void gl4_0compat_glSecondaryColor3b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue);
+void gl4_0compat_glFogCoordPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl4_0compat_glFogCoorddv(void *_glfuncs, const GLdouble* coord);
+void gl4_0compat_glFogCoordd(void *_glfuncs, GLdouble coord);
+void gl4_0compat_glFogCoordfv(void *_glfuncs, const GLfloat* coord);
+void gl4_0compat_glFogCoordf(void *_glfuncs, GLfloat coord);
+void gl4_0compat_glVertexAttrib4usv(void *_glfuncs, GLuint index, const GLushort* v);
+void gl4_0compat_glVertexAttrib4uiv(void *_glfuncs, GLuint index, const GLuint* v);
+void gl4_0compat_glVertexAttrib4ubv(void *_glfuncs, GLuint index, const GLubyte* v);
+void gl4_0compat_glVertexAttrib4sv(void *_glfuncs, GLuint index, const GLshort* v);
+void gl4_0compat_glVertexAttrib4s(void *_glfuncs, GLuint index, GLshort x, GLshort y, GLshort z, GLshort w);
+void gl4_0compat_glVertexAttrib4iv(void *_glfuncs, GLuint index, const GLint* v);
+void gl4_0compat_glVertexAttrib4fv(void *_glfuncs, GLuint index, const GLfloat* v);
+void gl4_0compat_glVertexAttrib4f(void *_glfuncs, GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+void gl4_0compat_glVertexAttrib4dv(void *_glfuncs, GLuint index, const GLdouble* v);
+void gl4_0compat_glVertexAttrib4d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+void gl4_0compat_glVertexAttrib4bv(void *_glfuncs, GLuint index, const GLbyte* v);
+void gl4_0compat_glVertexAttrib4Nusv(void *_glfuncs, GLuint index, const GLushort* v);
+void gl4_0compat_glVertexAttrib4Nuiv(void *_glfuncs, GLuint index, const GLuint* v);
+void gl4_0compat_glVertexAttrib4Nubv(void *_glfuncs, GLuint index, const GLubyte* v);
+void gl4_0compat_glVertexAttrib4Nub(void *_glfuncs, GLuint index, GLubyte x, GLubyte y, GLubyte z, GLubyte w);
+void gl4_0compat_glVertexAttrib4Nsv(void *_glfuncs, GLuint index, const GLshort* v);
+void gl4_0compat_glVertexAttrib4Niv(void *_glfuncs, GLuint index, const GLint* v);
+void gl4_0compat_glVertexAttrib4Nbv(void *_glfuncs, GLuint index, const GLbyte* v);
+void gl4_0compat_glVertexAttrib3sv(void *_glfuncs, GLuint index, const GLshort* v);
+void gl4_0compat_glVertexAttrib3s(void *_glfuncs, GLuint index, GLshort x, GLshort y, GLshort z);
+void gl4_0compat_glVertexAttrib3fv(void *_glfuncs, GLuint index, const GLfloat* v);
+void gl4_0compat_glVertexAttrib3f(void *_glfuncs, GLuint index, GLfloat x, GLfloat y, GLfloat z);
+void gl4_0compat_glVertexAttrib3dv(void *_glfuncs, GLuint index, const GLdouble* v);
+void gl4_0compat_glVertexAttrib3d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y, GLdouble z);
+void gl4_0compat_glVertexAttrib2sv(void *_glfuncs, GLuint index, const GLshort* v);
+void gl4_0compat_glVertexAttrib2s(void *_glfuncs, GLuint index, GLshort x, GLshort y);
+void gl4_0compat_glVertexAttrib2fv(void *_glfuncs, GLuint index, const GLfloat* v);
+void gl4_0compat_glVertexAttrib2f(void *_glfuncs, GLuint index, GLfloat x, GLfloat y);
+void gl4_0compat_glVertexAttrib2dv(void *_glfuncs, GLuint index, const GLdouble* v);
+void gl4_0compat_glVertexAttrib2d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y);
+void gl4_0compat_glVertexAttrib1sv(void *_glfuncs, GLuint index, const GLshort* v);
+void gl4_0compat_glVertexAttrib1s(void *_glfuncs, GLuint index, GLshort x);
+void gl4_0compat_glVertexAttrib1fv(void *_glfuncs, GLuint index, const GLfloat* v);
+void gl4_0compat_glVertexAttrib1f(void *_glfuncs, GLuint index, GLfloat x);
+void gl4_0compat_glVertexAttrib1dv(void *_glfuncs, GLuint index, const GLdouble* v);
+void gl4_0compat_glVertexAttrib1d(void *_glfuncs, GLuint index, GLdouble x);
+void gl4_0compat_glVertexAttribI4usv(void *_glfuncs, GLuint index, const GLushort* v);
+void gl4_0compat_glVertexAttribI4ubv(void *_glfuncs, GLuint index, const GLubyte* v);
+void gl4_0compat_glVertexAttribI4sv(void *_glfuncs, GLuint index, const GLshort* v);
+void gl4_0compat_glVertexAttribI4bv(void *_glfuncs, GLuint index, const GLbyte* v);
+void gl4_0compat_glVertexAttribI4uiv(void *_glfuncs, GLuint index, const GLuint* v);
+void gl4_0compat_glVertexAttribI3uiv(void *_glfuncs, GLuint index, const GLuint* v);
+void gl4_0compat_glVertexAttribI2uiv(void *_glfuncs, GLuint index, const GLuint* v);
+void gl4_0compat_glVertexAttribI1uiv(void *_glfuncs, GLuint index, const GLuint* v);
+void gl4_0compat_glVertexAttribI4iv(void *_glfuncs, GLuint index, const GLint* v);
+void gl4_0compat_glVertexAttribI3iv(void *_glfuncs, GLuint index, const GLint* v);
+void gl4_0compat_glVertexAttribI2iv(void *_glfuncs, GLuint index, const GLint* v);
+void gl4_0compat_glVertexAttribI1iv(void *_glfuncs, GLuint index, const GLint* v);
+void gl4_0compat_glVertexAttribI4ui(void *_glfuncs, GLuint index, GLuint x, GLuint y, GLuint z, GLuint w);
+void gl4_0compat_glVertexAttribI3ui(void *_glfuncs, GLuint index, GLuint x, GLuint y, GLuint z);
+void gl4_0compat_glVertexAttribI2ui(void *_glfuncs, GLuint index, GLuint x, GLuint y);
+void gl4_0compat_glVertexAttribI1ui(void *_glfuncs, GLuint index, GLuint x);
+void gl4_0compat_glVertexAttribI4i(void *_glfuncs, GLuint index, GLint x, GLint y, GLint z, GLint w);
+void gl4_0compat_glVertexAttribI3i(void *_glfuncs, GLuint index, GLint x, GLint y, GLint z);
+void gl4_0compat_glVertexAttribI2i(void *_glfuncs, GLuint index, GLint x, GLint y);
+void gl4_0compat_glVertexAttribI1i(void *_glfuncs, GLuint index, GLint x);
+
+
+#ifdef __cplusplus
+} // extern "C"
+#endif
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.0compat/gl.go b/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.0compat/gl.go
new file mode 100644
index 000000000..246afb061
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.0compat/gl.go
@@ -0,0 +1,8607 @@
+// ** file automatically generated by glgen -- do not edit manually **
+
+package GL
+
+// #cgo CXXFLAGS: -std=c++0x -pedantic-errors -Wall -fno-strict-aliasing
+// #cgo LDFLAGS: -lstdc++
+// #cgo pkg-config: Qt5Core Qt5OpenGL
+//
+// #include "funcs.h"
+//
+// void free(void*);
+//
+import "C"
+
+import (
+ "fmt"
+ "reflect"
+ "unsafe"
+
+ "gopkg.in/qml.v1/gl/glbase"
+)
+
+// API returns a value that offers methods matching the OpenGL version 4.0 API.
+//
+// The returned API must not be used after the provided OpenGL context becomes invalid.
+func API(context glbase.Contexter) *GL {
+ gl := &GL{}
+ gl.funcs = C.gl4_0compat_funcs()
+ if gl.funcs == nil {
+ panic(fmt.Errorf("OpenGL version 4.0 is not available"))
+ }
+ return gl
+}
+
+// GL implements the OpenGL version 4.0 API. Values of this
+// type must be created via the API function, and it must not be used after
+// the associated OpenGL context becomes invalid.
+type GL struct {
+ funcs unsafe.Pointer
+}
+
+const (
+ FALSE = 0
+ TRUE = 1
+ NONE = 0
+
+ BYTE = 0x1400
+ UNSIGNED_BYTE = 0x1401
+ SHORT = 0x1402
+ UNSIGNED_SHORT = 0x1403
+ INT = 0x1404
+ UNSIGNED_INT = 0x1405
+ FLOAT = 0x1406
+ N2_BYTES = 0x1407
+ N3_BYTES = 0x1408
+ N4_BYTES = 0x1409
+ DOUBLE = 0x140A
+ HALF_FLOAT = 0x140B
+
+ ACCUM = 0x0100
+ LOAD = 0x0101
+ RETURN = 0x0102
+ MULT = 0x0103
+ ADD = 0x0104
+
+ ACCUM_BUFFER_BIT = 0x00000200
+ ALL_ATTRIB_BITS = 0xFFFFFFFF
+ COLOR_BUFFER_BIT = 0x00004000
+ CURRENT_BIT = 0x00000001
+ DEPTH_BUFFER_BIT = 0x00000100
+ ENABLE_BIT = 0x00002000
+ EVAL_BIT = 0x00010000
+ FOG_BIT = 0x00000080
+ HINT_BIT = 0x00008000
+ LIGHTING_BIT = 0x00000040
+ LINE_BIT = 0x00000004
+ LIST_BIT = 0x00020000
+ MULTISAMPLE_BIT = 0x20000000
+ PIXEL_MODE_BIT = 0x00000020
+ POINT_BIT = 0x00000002
+ POLYGON_BIT = 0x00000008
+ POLYGON_STIPPLE_BIT = 0x00000010
+ SCISSOR_BIT = 0x00080000
+ STENCIL_BUFFER_BIT = 0x00000400
+ TEXTURE_BIT = 0x00040000
+ TRANSFORM_BIT = 0x00001000
+ VIEWPORT_BIT = 0x00000800
+
+ ALWAYS = 0x0207
+ EQUAL = 0x0202
+ GEQUAL = 0x0206
+ GREATER = 0x0204
+ LEQUAL = 0x0203
+ LESS = 0x0201
+ NEVER = 0x0200
+ NOTEQUAL = 0x0205
+
+ LOGIC_OP = 0x0BF1
+
+ DST_ALPHA = 0x0304
+ ONE = 1
+ ONE_MINUS_DST_ALPHA = 0x0305
+ ONE_MINUS_SRC_ALPHA = 0x0303
+ ONE_MINUS_SRC_COLOR = 0x0301
+ SRC_ALPHA = 0x0302
+ SRC_COLOR = 0x0300
+ ZERO = 0
+
+ DST_COLOR = 0x0306
+ ONE_MINUS_DST_COLOR = 0x0307
+ SRC_ALPHA_SATURATE = 0x0308
+
+ CLIENT_ALL_ATTRIB_BITS = 0xFFFFFFFF
+ CLIENT_PIXEL_STORE_BIT = 0x00000001
+ CLIENT_VERTEX_ARRAY_BIT = 0x00000002
+
+ CLIP_DISTANCE0 = 0x3000
+ CLIP_DISTANCE1 = 0x3001
+ CLIP_DISTANCE2 = 0x3002
+ CLIP_DISTANCE3 = 0x3003
+ CLIP_DISTANCE4 = 0x3004
+ CLIP_DISTANCE5 = 0x3005
+ CLIP_DISTANCE6 = 0x3006
+ CLIP_DISTANCE7 = 0x3007
+ CLIP_PLANE0 = 0x3000
+ CLIP_PLANE1 = 0x3001
+ CLIP_PLANE2 = 0x3002
+ CLIP_PLANE3 = 0x3003
+ CLIP_PLANE4 = 0x3004
+ CLIP_PLANE5 = 0x3005
+
+ BACK = 0x0405
+ FRONT = 0x0404
+ FRONT_AND_BACK = 0x0408
+
+ AMBIENT = 0x1200
+ AMBIENT_AND_DIFFUSE = 0x1602
+ DIFFUSE = 0x1201
+ EMISSION = 0x1600
+ SPECULAR = 0x1202
+
+ CONTEXT_FLAG_FORWARD_COMPATIBLE_BIT = 0x00000001
+
+ CONTEXT_COMPATIBILITY_PROFILE_BIT = 0x00000002
+ CONTEXT_CORE_PROFILE_BIT = 0x00000001
+
+ AUX0 = 0x0409
+ AUX1 = 0x040A
+ AUX2 = 0x040B
+ AUX3 = 0x040C
+ BACK_LEFT = 0x0402
+ BACK_RIGHT = 0x0403
+ FRONT_LEFT = 0x0400
+ FRONT_RIGHT = 0x0401
+ LEFT = 0x0406
+ RIGHT = 0x0407
+
+ ALPHA_TEST = 0x0BC0
+ AUTO_NORMAL = 0x0D80
+ BLEND = 0x0BE2
+ COLOR_ARRAY = 0x8076
+ COLOR_LOGIC_OP = 0x0BF2
+ COLOR_MATERIAL = 0x0B57
+ CULL_FACE = 0x0B44
+ DEPTH_TEST = 0x0B71
+ DITHER = 0x0BD0
+ EDGE_FLAG_ARRAY = 0x8079
+ FOG = 0x0B60
+ INDEX_ARRAY = 0x8077
+ INDEX_LOGIC_OP = 0x0BF1
+ LIGHT0 = 0x4000
+ LIGHT1 = 0x4001
+ LIGHT2 = 0x4002
+ LIGHT3 = 0x4003
+ LIGHT4 = 0x4004
+ LIGHT5 = 0x4005
+ LIGHT6 = 0x4006
+ LIGHT7 = 0x4007
+ LIGHTING = 0x0B50
+ LINE_SMOOTH = 0x0B20
+ LINE_STIPPLE = 0x0B24
+ MAP1_COLOR_4 = 0x0D90
+ MAP1_INDEX = 0x0D91
+ MAP1_NORMAL = 0x0D92
+ MAP1_TEXTURE_COORD_1 = 0x0D93
+ MAP1_TEXTURE_COORD_2 = 0x0D94
+ MAP1_TEXTURE_COORD_3 = 0x0D95
+ MAP1_TEXTURE_COORD_4 = 0x0D96
+ MAP1_VERTEX_3 = 0x0D97
+ MAP1_VERTEX_4 = 0x0D98
+ MAP2_COLOR_4 = 0x0DB0
+ MAP2_INDEX = 0x0DB1
+ MAP2_NORMAL = 0x0DB2
+ MAP2_TEXTURE_COORD_1 = 0x0DB3
+ MAP2_TEXTURE_COORD_2 = 0x0DB4
+ MAP2_TEXTURE_COORD_3 = 0x0DB5
+ MAP2_TEXTURE_COORD_4 = 0x0DB6
+ MAP2_VERTEX_3 = 0x0DB7
+ MAP2_VERTEX_4 = 0x0DB8
+ NORMALIZE = 0x0BA1
+ NORMAL_ARRAY = 0x8075
+ POINT_SMOOTH = 0x0B10
+ POLYGON_OFFSET_FILL = 0x8037
+ POLYGON_OFFSET_LINE = 0x2A02
+ POLYGON_OFFSET_POINT = 0x2A01
+ POLYGON_SMOOTH = 0x0B41
+ POLYGON_STIPPLE = 0x0B42
+ SCISSOR_TEST = 0x0C11
+ STENCIL_TEST = 0x0B90
+ TEXTURE_1D = 0x0DE0
+ TEXTURE_2D = 0x0DE1
+ TEXTURE_COORD_ARRAY = 0x8078
+ TEXTURE_GEN_Q = 0x0C63
+ TEXTURE_GEN_R = 0x0C62
+ TEXTURE_GEN_S = 0x0C60
+ TEXTURE_GEN_T = 0x0C61
+ VERTEX_ARRAY = 0x8074
+
+ INVALID_ENUM = 0x0500
+ INVALID_FRAMEBUFFER_OPERATION = 0x0506
+ INVALID_OPERATION = 0x0502
+ INVALID_VALUE = 0x0501
+ NO_ERROR = 0
+ OUT_OF_MEMORY = 0x0505
+ STACK_OVERFLOW = 0x0503
+ STACK_UNDERFLOW = 0x0504
+
+ N2D = 0x0600
+ N3D = 0x0601
+ N3D_COLOR = 0x0602
+ N3D_COLOR_TEXTURE = 0x0603
+ N4D_COLOR_TEXTURE = 0x0604
+
+ BITMAP_TOKEN = 0x0704
+ COPY_PIXEL_TOKEN = 0x0706
+ DRAW_PIXEL_TOKEN = 0x0705
+ LINE_RESET_TOKEN = 0x0707
+ LINE_TOKEN = 0x0702
+ PASS_THROUGH_TOKEN = 0x0700
+ POINT_TOKEN = 0x0701
+ POLYGON_TOKEN = 0x0703
+
+ EXP = 0x0800
+ EXP2 = 0x0801
+ LINEAR = 0x2601
+
+ FOG_COLOR = 0x0B66
+ FOG_DENSITY = 0x0B62
+ FOG_END = 0x0B64
+ FOG_INDEX = 0x0B61
+ FOG_MODE = 0x0B65
+ FOG_START = 0x0B63
+
+ CCW = 0x0901
+ CW = 0x0900
+
+ COEFF = 0x0A00
+ DOMAIN = 0x0A02
+ ORDER = 0x0A01
+
+ PIXEL_MAP_A_TO_A = 0x0C79
+ PIXEL_MAP_B_TO_B = 0x0C78
+ PIXEL_MAP_G_TO_G = 0x0C77
+ PIXEL_MAP_I_TO_A = 0x0C75
+ PIXEL_MAP_I_TO_B = 0x0C74
+ PIXEL_MAP_I_TO_G = 0x0C73
+ PIXEL_MAP_I_TO_I = 0x0C70
+ PIXEL_MAP_I_TO_R = 0x0C72
+ PIXEL_MAP_R_TO_R = 0x0C76
+ PIXEL_MAP_S_TO_S = 0x0C71
+
+ ACCUM_ALPHA_BITS = 0x0D5B
+ ACCUM_BLUE_BITS = 0x0D5A
+ ACCUM_CLEAR_VALUE = 0x0B80
+ ACCUM_GREEN_BITS = 0x0D59
+ ACCUM_RED_BITS = 0x0D58
+ ALIASED_LINE_WIDTH_RANGE = 0x846E
+ ALIASED_POINT_SIZE_RANGE = 0x846D
+ ALPHA_BIAS = 0x0D1D
+ ALPHA_BITS = 0x0D55
+ ALPHA_SCALE = 0x0D1C
+ ALPHA_TEST_FUNC = 0x0BC1
+ ALPHA_TEST_REF = 0x0BC2
+ ATTRIB_STACK_DEPTH = 0x0BB0
+ AUX_BUFFERS = 0x0C00
+ BLEND_DST = 0x0BE0
+ BLEND_SRC = 0x0BE1
+ BLUE_BIAS = 0x0D1B
+ BLUE_BITS = 0x0D54
+ BLUE_SCALE = 0x0D1A
+ CLIENT_ATTRIB_STACK_DEPTH = 0x0BB1
+ COLOR_ARRAY_SIZE = 0x8081
+ COLOR_ARRAY_STRIDE = 0x8083
+ COLOR_ARRAY_TYPE = 0x8082
+ COLOR_CLEAR_VALUE = 0x0C22
+ COLOR_MATERIAL_FACE = 0x0B55
+ COLOR_MATERIAL_PARAMETER = 0x0B56
+ COLOR_WRITEMASK = 0x0C23
+ CULL_FACE_MODE = 0x0B45
+ CURRENT_COLOR = 0x0B00
+ CURRENT_INDEX = 0x0B01
+ CURRENT_NORMAL = 0x0B02
+ CURRENT_RASTER_COLOR = 0x0B04
+ CURRENT_RASTER_DISTANCE = 0x0B09
+ CURRENT_RASTER_INDEX = 0x0B05
+ CURRENT_RASTER_POSITION = 0x0B07
+ CURRENT_RASTER_POSITION_VALID = 0x0B08
+ CURRENT_RASTER_TEXTURE_COORDS = 0x0B06
+ CURRENT_TEXTURE_COORDS = 0x0B03
+ DEPTH_BIAS = 0x0D1F
+ DEPTH_BITS = 0x0D56
+ DEPTH_CLEAR_VALUE = 0x0B73
+ DEPTH_FUNC = 0x0B74
+ DEPTH_RANGE = 0x0B70
+ DEPTH_SCALE = 0x0D1E
+ DEPTH_WRITEMASK = 0x0B72
+ DOUBLEBUFFER = 0x0C32
+ DRAW_BUFFER = 0x0C01
+ EDGE_FLAG = 0x0B43
+ EDGE_FLAG_ARRAY_STRIDE = 0x808C
+ FEEDBACK_BUFFER_SIZE = 0x0DF1
+ FEEDBACK_BUFFER_TYPE = 0x0DF2
+ FOG_HINT = 0x0C54
+ FRONT_FACE = 0x0B46
+ GREEN_BIAS = 0x0D19
+ GREEN_BITS = 0x0D53
+ GREEN_SCALE = 0x0D18
+ INDEX_ARRAY_STRIDE = 0x8086
+ INDEX_ARRAY_TYPE = 0x8085
+ INDEX_BITS = 0x0D51
+ INDEX_CLEAR_VALUE = 0x0C20
+ INDEX_MODE = 0x0C30
+ INDEX_OFFSET = 0x0D13
+ INDEX_SHIFT = 0x0D12
+ INDEX_WRITEMASK = 0x0C21
+ LIGHT_MODEL_AMBIENT = 0x0B53
+ LIGHT_MODEL_COLOR_CONTROL = 0x81F8
+ LIGHT_MODEL_LOCAL_VIEWER = 0x0B51
+ LIGHT_MODEL_TWO_SIDE = 0x0B52
+ LINE_SMOOTH_HINT = 0x0C52
+ LINE_STIPPLE_PATTERN = 0x0B25
+ LINE_STIPPLE_REPEAT = 0x0B26
+ LINE_WIDTH = 0x0B21
+ LINE_WIDTH_GRANULARITY = 0x0B23
+ LINE_WIDTH_RANGE = 0x0B22
+ LIST_BASE = 0x0B32
+ LIST_INDEX = 0x0B33
+ LIST_MODE = 0x0B30
+ LOGIC_OP_MODE = 0x0BF0
+ MAP1_GRID_DOMAIN = 0x0DD0
+ MAP1_GRID_SEGMENTS = 0x0DD1
+ MAP2_GRID_DOMAIN = 0x0DD2
+ MAP2_GRID_SEGMENTS = 0x0DD3
+ MAP_COLOR = 0x0D10
+ MAP_STENCIL = 0x0D11
+ MATRIX_MODE = 0x0BA0
+ MAX_ATTRIB_STACK_DEPTH = 0x0D35
+ MAX_CLIENT_ATTRIB_STACK_DEPTH = 0x0D3B
+ MAX_CLIP_DISTANCES = 0x0D32
+ MAX_CLIP_PLANES = 0x0D32
+ MAX_EVAL_ORDER = 0x0D30
+ MAX_LIGHTS = 0x0D31
+ MAX_LIST_NESTING = 0x0B31
+ MAX_MODELVIEW_STACK_DEPTH = 0x0D36
+ MAX_NAME_STACK_DEPTH = 0x0D37
+ MAX_PIXEL_MAP_TABLE = 0x0D34
+ MAX_PROJECTION_STACK_DEPTH = 0x0D38
+ MAX_TEXTURE_SIZE = 0x0D33
+ MAX_TEXTURE_STACK_DEPTH = 0x0D39
+ MAX_VIEWPORT_DIMS = 0x0D3A
+ MODELVIEW_MATRIX = 0x0BA6
+ MODELVIEW_STACK_DEPTH = 0x0BA3
+ NAME_STACK_DEPTH = 0x0D70
+ NORMAL_ARRAY_STRIDE = 0x807F
+ NORMAL_ARRAY_TYPE = 0x807E
+ PACK_ALIGNMENT = 0x0D05
+ PACK_LSB_FIRST = 0x0D01
+ PACK_ROW_LENGTH = 0x0D02
+ PACK_SKIP_PIXELS = 0x0D04
+ PACK_SKIP_ROWS = 0x0D03
+ PACK_SWAP_BYTES = 0x0D00
+ PERSPECTIVE_CORRECTION_HINT = 0x0C50
+ PIXEL_MAP_A_TO_A_SIZE = 0x0CB9
+ PIXEL_MAP_B_TO_B_SIZE = 0x0CB8
+ PIXEL_MAP_G_TO_G_SIZE = 0x0CB7
+ PIXEL_MAP_I_TO_A_SIZE = 0x0CB5
+ PIXEL_MAP_I_TO_B_SIZE = 0x0CB4
+ PIXEL_MAP_I_TO_G_SIZE = 0x0CB3
+ PIXEL_MAP_I_TO_I_SIZE = 0x0CB0
+ PIXEL_MAP_I_TO_R_SIZE = 0x0CB2
+ PIXEL_MAP_R_TO_R_SIZE = 0x0CB6
+ PIXEL_MAP_S_TO_S_SIZE = 0x0CB1
+ POINT_SIZE = 0x0B11
+ POINT_SIZE_GRANULARITY = 0x0B13
+ POINT_SIZE_RANGE = 0x0B12
+ POINT_SMOOTH_HINT = 0x0C51
+ POLYGON_MODE = 0x0B40
+ POLYGON_OFFSET_FACTOR = 0x8038
+ POLYGON_OFFSET_UNITS = 0x2A00
+ POLYGON_SMOOTH_HINT = 0x0C53
+ PROJECTION_MATRIX = 0x0BA7
+ PROJECTION_STACK_DEPTH = 0x0BA4
+ READ_BUFFER = 0x0C02
+ RED_BIAS = 0x0D15
+ RED_BITS = 0x0D52
+ RED_SCALE = 0x0D14
+ RENDER_MODE = 0x0C40
+ RGBA_MODE = 0x0C31
+ SCISSOR_BOX = 0x0C10
+ SELECTION_BUFFER_SIZE = 0x0DF4
+ SHADE_MODEL = 0x0B54
+ SMOOTH_LINE_WIDTH_GRANULARITY = 0x0B23
+ SMOOTH_LINE_WIDTH_RANGE = 0x0B22
+ SMOOTH_POINT_SIZE_GRANULARITY = 0x0B13
+ SMOOTH_POINT_SIZE_RANGE = 0x0B12
+ STENCIL_BITS = 0x0D57
+ STENCIL_CLEAR_VALUE = 0x0B91
+ STENCIL_FAIL = 0x0B94
+ STENCIL_FUNC = 0x0B92
+ STENCIL_PASS_DEPTH_FAIL = 0x0B95
+ STENCIL_PASS_DEPTH_PASS = 0x0B96
+ STENCIL_REF = 0x0B97
+ STENCIL_VALUE_MASK = 0x0B93
+ STENCIL_WRITEMASK = 0x0B98
+ STEREO = 0x0C33
+ SUBPIXEL_BITS = 0x0D50
+ TEXTURE_BINDING_1D = 0x8068
+ TEXTURE_BINDING_2D = 0x8069
+ TEXTURE_BINDING_3D = 0x806A
+ TEXTURE_COORD_ARRAY_SIZE = 0x8088
+ TEXTURE_COORD_ARRAY_STRIDE = 0x808A
+ TEXTURE_COORD_ARRAY_TYPE = 0x8089
+ TEXTURE_MATRIX = 0x0BA8
+ TEXTURE_STACK_DEPTH = 0x0BA5
+ UNPACK_ALIGNMENT = 0x0CF5
+ UNPACK_LSB_FIRST = 0x0CF1
+ UNPACK_ROW_LENGTH = 0x0CF2
+ UNPACK_SKIP_PIXELS = 0x0CF4
+ UNPACK_SKIP_ROWS = 0x0CF3
+ UNPACK_SWAP_BYTES = 0x0CF0
+ VERTEX_ARRAY_SIZE = 0x807A
+ VERTEX_ARRAY_STRIDE = 0x807C
+ VERTEX_ARRAY_TYPE = 0x807B
+ VIEWPORT = 0x0BA2
+ ZOOM_X = 0x0D16
+ ZOOM_Y = 0x0D17
+
+ COLOR_ARRAY_POINTER = 0x8090
+ EDGE_FLAG_ARRAY_POINTER = 0x8093
+ FEEDBACK_BUFFER_POINTER = 0x0DF0
+ INDEX_ARRAY_POINTER = 0x8091
+ NORMAL_ARRAY_POINTER = 0x808F
+ SELECTION_BUFFER_POINTER = 0x0DF3
+ TEXTURE_COORD_ARRAY_POINTER = 0x8092
+ VERTEX_ARRAY_POINTER = 0x808E
+
+ TEXTURE_ALPHA_SIZE = 0x805F
+ TEXTURE_BLUE_SIZE = 0x805E
+ TEXTURE_BORDER = 0x1005
+ TEXTURE_BORDER_COLOR = 0x1004
+ TEXTURE_COMPONENTS = 0x1003
+ TEXTURE_GREEN_SIZE = 0x805D
+ TEXTURE_HEIGHT = 0x1001
+ TEXTURE_INTENSITY_SIZE = 0x8061
+ TEXTURE_INTERNAL_FORMAT = 0x1003
+ TEXTURE_LUMINANCE_SIZE = 0x8060
+ TEXTURE_MAG_FILTER = 0x2800
+ TEXTURE_MIN_FILTER = 0x2801
+ TEXTURE_PRIORITY = 0x8066
+ TEXTURE_RED_SIZE = 0x805C
+ TEXTURE_RESIDENT = 0x8067
+ TEXTURE_WIDTH = 0x1000
+ TEXTURE_WRAP_S = 0x2802
+ TEXTURE_WRAP_T = 0x2803
+
+ DONT_CARE = 0x1100
+ FASTEST = 0x1101
+ NICEST = 0x1102
+
+ FRAGMENT_SHADER_DERIVATIVE_HINT = 0x8B8B
+ GENERATE_MIPMAP_HINT = 0x8192
+ TEXTURE_COMPRESSION_HINT = 0x84EF
+
+ C3F_V3F = 0x2A24
+ C4F_N3F_V3F = 0x2A26
+ C4UB_V2F = 0x2A22
+ C4UB_V3F = 0x2A23
+ N3F_V3F = 0x2A25
+ T2F_C3F_V3F = 0x2A2A
+ T2F_C4F_N3F_V3F = 0x2A2C
+ T2F_C4UB_V3F = 0x2A29
+ T2F_N3F_V3F = 0x2A2B
+ T2F_V3F = 0x2A27
+ T4F_C4F_N3F_V4F = 0x2A2D
+ T4F_V4F = 0x2A28
+ V2F = 0x2A20
+ V3F = 0x2A21
+
+ MODULATE = 0x2100
+ REPLACE = 0x1E01
+
+ SEPARATE_SPECULAR_COLOR = 0x81FA
+ SINGLE_COLOR = 0x81F9
+
+ CONSTANT_ATTENUATION = 0x1207
+ LINEAR_ATTENUATION = 0x1208
+ POSITION = 0x1203
+ QUADRATIC_ATTENUATION = 0x1209
+ SPOT_CUTOFF = 0x1206
+ SPOT_DIRECTION = 0x1204
+ SPOT_EXPONENT = 0x1205
+
+ COMPILE = 0x1300
+ COMPILE_AND_EXECUTE = 0x1301
+
+ AND = 0x1501
+ AND_INVERTED = 0x1504
+ AND_REVERSE = 0x1502
+ CLEAR = 0x1500
+ COPY = 0x1503
+ COPY_INVERTED = 0x150C
+ EQUIV = 0x1509
+ INVERT = 0x150A
+ NAND = 0x150E
+ NOOP = 0x1505
+ NOR = 0x1508
+ OR = 0x1507
+ OR_INVERTED = 0x150D
+ OR_REVERSE = 0x150B
+ SET = 0x150F
+ XOR = 0x1506
+
+ MAP_FLUSH_EXPLICIT_BIT = 0x0010
+ MAP_INVALIDATE_BUFFER_BIT = 0x0008
+ MAP_INVALIDATE_RANGE_BIT = 0x0004
+ MAP_READ_BIT = 0x0001
+ MAP_UNSYNCHRONIZED_BIT = 0x0020
+ MAP_WRITE_BIT = 0x0002
+
+ COLOR_INDEXES = 0x1603
+ SHININESS = 0x1601
+
+ MODELVIEW = 0x1700
+ PROJECTION = 0x1701
+ TEXTURE = 0x1702
+
+ LINE = 0x1B01
+ POINT = 0x1B00
+
+ FILL = 0x1B02
+
+ COLOR = 0x1800
+ DEPTH = 0x1801
+ STENCIL = 0x1802
+
+ ALPHA = 0x1906
+ BLUE = 0x1905
+ COLOR_INDEX = 0x1900
+ DEPTH_COMPONENT = 0x1902
+ GREEN = 0x1904
+ LUMINANCE = 0x1909
+ LUMINANCE_ALPHA = 0x190A
+ RED = 0x1903
+ RGB = 0x1907
+ RGBA = 0x1908
+ STENCIL_INDEX = 0x1901
+
+ ALPHA12 = 0x803D
+ ALPHA16 = 0x803E
+ ALPHA4 = 0x803B
+ ALPHA8 = 0x803C
+ INTENSITY = 0x8049
+ INTENSITY12 = 0x804C
+ INTENSITY16 = 0x804D
+ INTENSITY4 = 0x804A
+ INTENSITY8 = 0x804B
+ LUMINANCE12 = 0x8041
+ LUMINANCE12_ALPHA12 = 0x8047
+ LUMINANCE12_ALPHA4 = 0x8046
+ LUMINANCE16 = 0x8042
+ LUMINANCE16_ALPHA16 = 0x8048
+ LUMINANCE4 = 0x803F
+ LUMINANCE4_ALPHA4 = 0x8043
+ LUMINANCE6_ALPHA2 = 0x8044
+ LUMINANCE8 = 0x8040
+ LUMINANCE8_ALPHA8 = 0x8045
+ R3_G3_B2 = 0x2A10
+ RGB10 = 0x8052
+ RGB10_A2 = 0x8059
+ RGB12 = 0x8053
+ RGB16 = 0x8054
+ RGB4 = 0x804F
+ RGB5 = 0x8050
+ RGB5_A1 = 0x8057
+ RGB8 = 0x8051
+ RGBA12 = 0x805A
+ RGBA16 = 0x805B
+ RGBA2 = 0x8055
+ RGBA4 = 0x8056
+ RGBA8 = 0x8058
+
+ PACK_IMAGE_HEIGHT = 0x806C
+ PACK_SKIP_IMAGES = 0x806B
+ UNPACK_IMAGE_HEIGHT = 0x806E
+ UNPACK_SKIP_IMAGES = 0x806D
+
+ BITMAP = 0x1A00
+ UNSIGNED_BYTE_3_3_2 = 0x8032
+ UNSIGNED_INT_10_10_10_2 = 0x8036
+ UNSIGNED_INT_8_8_8_8 = 0x8035
+ UNSIGNED_SHORT_4_4_4_4 = 0x8033
+ UNSIGNED_SHORT_5_5_5_1 = 0x8034
+
+ POINT_DISTANCE_ATTENUATION = 0x8129
+ POINT_FADE_THRESHOLD_SIZE = 0x8128
+ POINT_SIZE_MAX = 0x8127
+ POINT_SIZE_MIN = 0x8126
+
+ LINES = 0x0001
+ LINES_ADJACENCY = 0x000A
+ LINE_LOOP = 0x0002
+ LINE_STRIP = 0x0003
+ LINE_STRIP_ADJACENCY = 0x000B
+ PATCHES = 0x000E
+ POINTS = 0x0000
+ POLYGON = 0x0009
+ QUADS = 0x0007
+ QUAD_STRIP = 0x0008
+ TRIANGLES = 0x0004
+ TRIANGLES_ADJACENCY = 0x000C
+ TRIANGLE_FAN = 0x0006
+ TRIANGLE_STRIP = 0x0005
+ TRIANGLE_STRIP_ADJACENCY = 0x000D
+
+ FEEDBACK = 0x1C01
+ RENDER = 0x1C00
+ SELECT = 0x1C02
+
+ FLAT = 0x1D00
+ SMOOTH = 0x1D01
+
+ DECR = 0x1E03
+ INCR = 0x1E02
+ KEEP = 0x1E00
+
+ EXTENSIONS = 0x1F03
+ RENDERER = 0x1F01
+ VENDOR = 0x1F00
+ VERSION = 0x1F02
+
+ S = 0x2000
+ T = 0x2001
+ R = 0x2002
+ Q = 0x2003
+
+ DECAL = 0x2101
+
+ TEXTURE_ENV_COLOR = 0x2201
+ TEXTURE_ENV_MODE = 0x2200
+
+ TEXTURE_ENV = 0x2300
+
+ EYE_LINEAR = 0x2400
+ OBJECT_LINEAR = 0x2401
+ SPHERE_MAP = 0x2402
+
+ EYE_PLANE = 0x2502
+ OBJECT_PLANE = 0x2501
+ TEXTURE_GEN_MODE = 0x2500
+
+ NEAREST = 0x2600
+
+ LINEAR_MIPMAP_LINEAR = 0x2703
+ LINEAR_MIPMAP_NEAREST = 0x2701
+ NEAREST_MIPMAP_LINEAR = 0x2702
+ NEAREST_MIPMAP_NEAREST = 0x2700
+
+ GENERATE_MIPMAP = 0x8191
+ TEXTURE_WRAP_R = 0x8072
+
+ PROXY_TEXTURE_1D = 0x8063
+ PROXY_TEXTURE_2D = 0x8064
+ PROXY_TEXTURE_3D = 0x8070
+ TEXTURE_3D = 0x806F
+ TEXTURE_BASE_LEVEL = 0x813C
+ TEXTURE_MAX_LEVEL = 0x813D
+ TEXTURE_MAX_LOD = 0x813B
+ TEXTURE_MIN_LOD = 0x813A
+
+ CLAMP = 0x2900
+ CLAMP_TO_BORDER = 0x812D
+ CLAMP_TO_EDGE = 0x812F
+ REPEAT = 0x2901
+
+ SYNC_FLUSH_COMMANDS_BIT = 0x00000001
+ INVALID_INDEX = 0xFFFFFFFF
+ TIMEOUT_IGNORED = 0xFFFFFFFFFFFFFFFF
+ CONSTANT_COLOR = 0x8001
+ ONE_MINUS_CONSTANT_COLOR = 0x8002
+ CONSTANT_ALPHA = 0x8003
+ ONE_MINUS_CONSTANT_ALPHA = 0x8004
+ FUNC_ADD = 0x8006
+ MIN = 0x8007
+ MAX = 0x8008
+ BLEND_EQUATION_RGB = 0x8009
+ FUNC_SUBTRACT = 0x800A
+ FUNC_REVERSE_SUBTRACT = 0x800B
+ RESCALE_NORMAL = 0x803A
+ TEXTURE_DEPTH = 0x8071
+ MAX_3D_TEXTURE_SIZE = 0x8073
+ MULTISAMPLE = 0x809D
+ SAMPLE_ALPHA_TO_COVERAGE = 0x809E
+ SAMPLE_ALPHA_TO_ONE = 0x809F
+ SAMPLE_COVERAGE = 0x80A0
+ SAMPLE_BUFFERS = 0x80A8
+ SAMPLES = 0x80A9
+ SAMPLE_COVERAGE_VALUE = 0x80AA
+ SAMPLE_COVERAGE_INVERT = 0x80AB
+ BLEND_DST_RGB = 0x80C8
+ BLEND_SRC_RGB = 0x80C9
+ BLEND_DST_ALPHA = 0x80CA
+ BLEND_SRC_ALPHA = 0x80CB
+ BGR = 0x80E0
+ BGRA = 0x80E1
+ MAX_ELEMENTS_VERTICES = 0x80E8
+ MAX_ELEMENTS_INDICES = 0x80E9
+ DEPTH_COMPONENT16 = 0x81A5
+ DEPTH_COMPONENT24 = 0x81A6
+ DEPTH_COMPONENT32 = 0x81A7
+ FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING = 0x8210
+ FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE = 0x8211
+ FRAMEBUFFER_ATTACHMENT_RED_SIZE = 0x8212
+ FRAMEBUFFER_ATTACHMENT_GREEN_SIZE = 0x8213
+ FRAMEBUFFER_ATTACHMENT_BLUE_SIZE = 0x8214
+ FRAMEBUFFER_ATTACHMENT_ALPHA_SIZE = 0x8215
+ FRAMEBUFFER_ATTACHMENT_DEPTH_SIZE = 0x8216
+ FRAMEBUFFER_ATTACHMENT_STENCIL_SIZE = 0x8217
+ FRAMEBUFFER_DEFAULT = 0x8218
+ FRAMEBUFFER_UNDEFINED = 0x8219
+ DEPTH_STENCIL_ATTACHMENT = 0x821A
+ MAJOR_VERSION = 0x821B
+ MINOR_VERSION = 0x821C
+ NUM_EXTENSIONS = 0x821D
+ CONTEXT_FLAGS = 0x821E
+ INDEX = 0x8222
+ COMPRESSED_RED = 0x8225
+ COMPRESSED_RG = 0x8226
+ RG = 0x8227
+ RG_INTEGER = 0x8228
+ R8 = 0x8229
+ R16 = 0x822A
+ RG8 = 0x822B
+ RG16 = 0x822C
+ R16F = 0x822D
+ R32F = 0x822E
+ RG16F = 0x822F
+ RG32F = 0x8230
+ R8I = 0x8231
+ R8UI = 0x8232
+ R16I = 0x8233
+ R16UI = 0x8234
+ R32I = 0x8235
+ R32UI = 0x8236
+ RG8I = 0x8237
+ RG8UI = 0x8238
+ RG16I = 0x8239
+ RG16UI = 0x823A
+ RG32I = 0x823B
+ RG32UI = 0x823C
+ UNSIGNED_BYTE_2_3_3_REV = 0x8362
+ UNSIGNED_SHORT_5_6_5 = 0x8363
+ UNSIGNED_SHORT_5_6_5_REV = 0x8364
+ UNSIGNED_SHORT_4_4_4_4_REV = 0x8365
+ UNSIGNED_SHORT_1_5_5_5_REV = 0x8366
+ UNSIGNED_INT_8_8_8_8_REV = 0x8367
+ UNSIGNED_INT_2_10_10_10_REV = 0x8368
+ MIRRORED_REPEAT = 0x8370
+ FOG_COORDINATE_SOURCE = 0x8450
+ FOG_COORD_SRC = 0x8450
+ FOG_COORDINATE = 0x8451
+ FOG_COORD = 0x8451
+ FRAGMENT_DEPTH = 0x8452
+ CURRENT_FOG_COORDINATE = 0x8453
+ CURRENT_FOG_COORD = 0x8453
+ FOG_COORDINATE_ARRAY_TYPE = 0x8454
+ FOG_COORD_ARRAY_TYPE = 0x8454
+ FOG_COORDINATE_ARRAY_STRIDE = 0x8455
+ FOG_COORD_ARRAY_STRIDE = 0x8455
+ FOG_COORDINATE_ARRAY_POINTER = 0x8456
+ FOG_COORD_ARRAY_POINTER = 0x8456
+ FOG_COORDINATE_ARRAY = 0x8457
+ FOG_COORD_ARRAY = 0x8457
+ COLOR_SUM = 0x8458
+ CURRENT_SECONDARY_COLOR = 0x8459
+ SECONDARY_COLOR_ARRAY_SIZE = 0x845A
+ SECONDARY_COLOR_ARRAY_TYPE = 0x845B
+ SECONDARY_COLOR_ARRAY_STRIDE = 0x845C
+ SECONDARY_COLOR_ARRAY_POINTER = 0x845D
+ SECONDARY_COLOR_ARRAY = 0x845E
+ CURRENT_RASTER_SECONDARY_COLOR = 0x845F
+ TEXTURE0 = 0x84C0
+ TEXTURE1 = 0x84C1
+ TEXTURE2 = 0x84C2
+ TEXTURE3 = 0x84C3
+ TEXTURE4 = 0x84C4
+ TEXTURE5 = 0x84C5
+ TEXTURE6 = 0x84C6
+ TEXTURE7 = 0x84C7
+ TEXTURE8 = 0x84C8
+ TEXTURE9 = 0x84C9
+ TEXTURE10 = 0x84CA
+ TEXTURE11 = 0x84CB
+ TEXTURE12 = 0x84CC
+ TEXTURE13 = 0x84CD
+ TEXTURE14 = 0x84CE
+ TEXTURE15 = 0x84CF
+ TEXTURE16 = 0x84D0
+ TEXTURE17 = 0x84D1
+ TEXTURE18 = 0x84D2
+ TEXTURE19 = 0x84D3
+ TEXTURE20 = 0x84D4
+ TEXTURE21 = 0x84D5
+ TEXTURE22 = 0x84D6
+ TEXTURE23 = 0x84D7
+ TEXTURE24 = 0x84D8
+ TEXTURE25 = 0x84D9
+ TEXTURE26 = 0x84DA
+ TEXTURE27 = 0x84DB
+ TEXTURE28 = 0x84DC
+ TEXTURE29 = 0x84DD
+ TEXTURE30 = 0x84DE
+ TEXTURE31 = 0x84DF
+ ACTIVE_TEXTURE = 0x84E0
+ CLIENT_ACTIVE_TEXTURE = 0x84E1
+ MAX_TEXTURE_UNITS = 0x84E2
+ TRANSPOSE_MODELVIEW_MATRIX = 0x84E3
+ TRANSPOSE_PROJECTION_MATRIX = 0x84E4
+ TRANSPOSE_TEXTURE_MATRIX = 0x84E5
+ TRANSPOSE_COLOR_MATRIX = 0x84E6
+ SUBTRACT = 0x84E7
+ MAX_RENDERBUFFER_SIZE = 0x84E8
+ COMPRESSED_ALPHA = 0x84E9
+ COMPRESSED_LUMINANCE = 0x84EA
+ COMPRESSED_LUMINANCE_ALPHA = 0x84EB
+ COMPRESSED_INTENSITY = 0x84EC
+ COMPRESSED_RGB = 0x84ED
+ COMPRESSED_RGBA = 0x84EE
+ UNIFORM_BLOCK_REFERENCED_BY_TESS_CONTROL_SHADER = 0x84F0
+ UNIFORM_BLOCK_REFERENCED_BY_TESS_EVALUATION_SHADER = 0x84F1
+ TEXTURE_RECTANGLE = 0x84F5
+ TEXTURE_BINDING_RECTANGLE = 0x84F6
+ PROXY_TEXTURE_RECTANGLE = 0x84F7
+ MAX_RECTANGLE_TEXTURE_SIZE = 0x84F8
+ DEPTH_STENCIL = 0x84F9
+ UNSIGNED_INT_24_8 = 0x84FA
+ MAX_TEXTURE_LOD_BIAS = 0x84FD
+ TEXTURE_FILTER_CONTROL = 0x8500
+ TEXTURE_LOD_BIAS = 0x8501
+ INCR_WRAP = 0x8507
+ DECR_WRAP = 0x8508
+ NORMAL_MAP = 0x8511
+ REFLECTION_MAP = 0x8512
+ TEXTURE_CUBE_MAP = 0x8513
+ TEXTURE_BINDING_CUBE_MAP = 0x8514
+ TEXTURE_CUBE_MAP_POSITIVE_X = 0x8515
+ TEXTURE_CUBE_MAP_NEGATIVE_X = 0x8516
+ TEXTURE_CUBE_MAP_POSITIVE_Y = 0x8517
+ TEXTURE_CUBE_MAP_NEGATIVE_Y = 0x8518
+ TEXTURE_CUBE_MAP_POSITIVE_Z = 0x8519
+ TEXTURE_CUBE_MAP_NEGATIVE_Z = 0x851A
+ PROXY_TEXTURE_CUBE_MAP = 0x851B
+ MAX_CUBE_MAP_TEXTURE_SIZE = 0x851C
+ COMBINE = 0x8570
+ COMBINE_RGB = 0x8571
+ COMBINE_ALPHA = 0x8572
+ RGB_SCALE = 0x8573
+ ADD_SIGNED = 0x8574
+ INTERPOLATE = 0x8575
+ CONSTANT = 0x8576
+ PRIMARY_COLOR = 0x8577
+ PREVIOUS = 0x8578
+ SOURCE0_RGB = 0x8580
+ SRC0_RGB = 0x8580
+ SOURCE1_RGB = 0x8581
+ SRC1_RGB = 0x8581
+ SOURCE2_RGB = 0x8582
+ SRC2_RGB = 0x8582
+ SOURCE0_ALPHA = 0x8588
+ SRC0_ALPHA = 0x8588
+ SOURCE1_ALPHA = 0x8589
+ SRC1_ALPHA = 0x8589
+ SOURCE2_ALPHA = 0x858A
+ SRC2_ALPHA = 0x858A
+ OPERAND0_RGB = 0x8590
+ OPERAND1_RGB = 0x8591
+ OPERAND2_RGB = 0x8592
+ OPERAND0_ALPHA = 0x8598
+ OPERAND1_ALPHA = 0x8599
+ OPERAND2_ALPHA = 0x859A
+ VERTEX_ARRAY_BINDING = 0x85B5
+ VERTEX_ATTRIB_ARRAY_ENABLED = 0x8622
+ VERTEX_ATTRIB_ARRAY_SIZE = 0x8623
+ VERTEX_ATTRIB_ARRAY_STRIDE = 0x8624
+ VERTEX_ATTRIB_ARRAY_TYPE = 0x8625
+ CURRENT_VERTEX_ATTRIB = 0x8626
+ VERTEX_PROGRAM_POINT_SIZE = 0x8642
+ PROGRAM_POINT_SIZE = 0x8642
+ VERTEX_PROGRAM_TWO_SIDE = 0x8643
+ VERTEX_ATTRIB_ARRAY_POINTER = 0x8645
+ DEPTH_CLAMP = 0x864F
+ TEXTURE_COMPRESSED_IMAGE_SIZE = 0x86A0
+ TEXTURE_COMPRESSED = 0x86A1
+ NUM_COMPRESSED_TEXTURE_FORMATS = 0x86A2
+ COMPRESSED_TEXTURE_FORMATS = 0x86A3
+ DOT3_RGB = 0x86AE
+ DOT3_RGBA = 0x86AF
+ BUFFER_SIZE = 0x8764
+ BUFFER_USAGE = 0x8765
+ STENCIL_BACK_FUNC = 0x8800
+ STENCIL_BACK_FAIL = 0x8801
+ STENCIL_BACK_PASS_DEPTH_FAIL = 0x8802
+ STENCIL_BACK_PASS_DEPTH_PASS = 0x8803
+ RGBA32F = 0x8814
+ RGB32F = 0x8815
+ RGBA16F = 0x881A
+ RGB16F = 0x881B
+ MAX_DRAW_BUFFERS = 0x8824
+ DRAW_BUFFER0 = 0x8825
+ DRAW_BUFFER1 = 0x8826
+ DRAW_BUFFER2 = 0x8827
+ DRAW_BUFFER3 = 0x8828
+ DRAW_BUFFER4 = 0x8829
+ DRAW_BUFFER5 = 0x882A
+ DRAW_BUFFER6 = 0x882B
+ DRAW_BUFFER7 = 0x882C
+ DRAW_BUFFER8 = 0x882D
+ DRAW_BUFFER9 = 0x882E
+ DRAW_BUFFER10 = 0x882F
+ DRAW_BUFFER11 = 0x8830
+ DRAW_BUFFER12 = 0x8831
+ DRAW_BUFFER13 = 0x8832
+ DRAW_BUFFER14 = 0x8833
+ DRAW_BUFFER15 = 0x8834
+ BLEND_EQUATION_ALPHA = 0x883D
+ TEXTURE_DEPTH_SIZE = 0x884A
+ DEPTH_TEXTURE_MODE = 0x884B
+ TEXTURE_COMPARE_MODE = 0x884C
+ TEXTURE_COMPARE_FUNC = 0x884D
+ COMPARE_R_TO_TEXTURE = 0x884E
+ COMPARE_REF_TO_TEXTURE = 0x884E
+ TEXTURE_CUBE_MAP_SEAMLESS = 0x884F
+ POINT_SPRITE = 0x8861
+ COORD_REPLACE = 0x8862
+ QUERY_COUNTER_BITS = 0x8864
+ CURRENT_QUERY = 0x8865
+ QUERY_RESULT = 0x8866
+ QUERY_RESULT_AVAILABLE = 0x8867
+ MAX_VERTEX_ATTRIBS = 0x8869
+ VERTEX_ATTRIB_ARRAY_NORMALIZED = 0x886A
+ MAX_TESS_CONTROL_INPUT_COMPONENTS = 0x886C
+ MAX_TESS_EVALUATION_INPUT_COMPONENTS = 0x886D
+ MAX_TEXTURE_COORDS = 0x8871
+ MAX_TEXTURE_IMAGE_UNITS = 0x8872
+ GEOMETRY_SHADER_INVOCATIONS = 0x887F
+ ARRAY_BUFFER = 0x8892
+ ELEMENT_ARRAY_BUFFER = 0x8893
+ ARRAY_BUFFER_BINDING = 0x8894
+ ELEMENT_ARRAY_BUFFER_BINDING = 0x8895
+ VERTEX_ARRAY_BUFFER_BINDING = 0x8896
+ NORMAL_ARRAY_BUFFER_BINDING = 0x8897
+ COLOR_ARRAY_BUFFER_BINDING = 0x8898
+ INDEX_ARRAY_BUFFER_BINDING = 0x8899
+ TEXTURE_COORD_ARRAY_BUFFER_BINDING = 0x889A
+ EDGE_FLAG_ARRAY_BUFFER_BINDING = 0x889B
+ SECONDARY_COLOR_ARRAY_BUFFER_BINDING = 0x889C
+ FOG_COORDINATE_ARRAY_BUFFER_BINDING = 0x889D
+ FOG_COORD_ARRAY_BUFFER_BINDING = 0x889D
+ WEIGHT_ARRAY_BUFFER_BINDING = 0x889E
+ VERTEX_ATTRIB_ARRAY_BUFFER_BINDING = 0x889F
+ READ_ONLY = 0x88B8
+ WRITE_ONLY = 0x88B9
+ READ_WRITE = 0x88BA
+ BUFFER_ACCESS = 0x88BB
+ BUFFER_MAPPED = 0x88BC
+ BUFFER_MAP_POINTER = 0x88BD
+ TIME_ELAPSED = 0x88BF
+ STREAM_DRAW = 0x88E0
+ STREAM_READ = 0x88E1
+ STREAM_COPY = 0x88E2
+ STATIC_DRAW = 0x88E4
+ STATIC_READ = 0x88E5
+ STATIC_COPY = 0x88E6
+ DYNAMIC_DRAW = 0x88E8
+ DYNAMIC_READ = 0x88E9
+ DYNAMIC_COPY = 0x88EA
+ PIXEL_PACK_BUFFER = 0x88EB
+ PIXEL_UNPACK_BUFFER = 0x88EC
+ PIXEL_PACK_BUFFER_BINDING = 0x88ED
+ PIXEL_UNPACK_BUFFER_BINDING = 0x88EF
+ DEPTH24_STENCIL8 = 0x88F0
+ TEXTURE_STENCIL_SIZE = 0x88F1
+ SRC1_COLOR = 0x88F9
+ ONE_MINUS_SRC1_COLOR = 0x88FA
+ ONE_MINUS_SRC1_ALPHA = 0x88FB
+ MAX_DUAL_SOURCE_DRAW_BUFFERS = 0x88FC
+ VERTEX_ATTRIB_ARRAY_INTEGER = 0x88FD
+ VERTEX_ATTRIB_ARRAY_DIVISOR = 0x88FE
+ MAX_ARRAY_TEXTURE_LAYERS = 0x88FF
+ MIN_PROGRAM_TEXEL_OFFSET = 0x8904
+ MAX_PROGRAM_TEXEL_OFFSET = 0x8905
+ SAMPLES_PASSED = 0x8914
+ GEOMETRY_VERTICES_OUT = 0x8916
+ GEOMETRY_INPUT_TYPE = 0x8917
+ GEOMETRY_OUTPUT_TYPE = 0x8918
+ SAMPLER_BINDING = 0x8919
+ CLAMP_VERTEX_COLOR = 0x891A
+ CLAMP_FRAGMENT_COLOR = 0x891B
+ CLAMP_READ_COLOR = 0x891C
+ FIXED_ONLY = 0x891D
+ UNIFORM_BUFFER = 0x8A11
+ UNIFORM_BUFFER_BINDING = 0x8A28
+ UNIFORM_BUFFER_START = 0x8A29
+ UNIFORM_BUFFER_SIZE = 0x8A2A
+ MAX_VERTEX_UNIFORM_BLOCKS = 0x8A2B
+ MAX_GEOMETRY_UNIFORM_BLOCKS = 0x8A2C
+ MAX_FRAGMENT_UNIFORM_BLOCKS = 0x8A2D
+ MAX_COMBINED_UNIFORM_BLOCKS = 0x8A2E
+ MAX_UNIFORM_BUFFER_BINDINGS = 0x8A2F
+ MAX_UNIFORM_BLOCK_SIZE = 0x8A30
+ MAX_COMBINED_VERTEX_UNIFORM_COMPONENTS = 0x8A31
+ MAX_COMBINED_GEOMETRY_UNIFORM_COMPONENTS = 0x8A32
+ MAX_COMBINED_FRAGMENT_UNIFORM_COMPONENTS = 0x8A33
+ UNIFORM_BUFFER_OFFSET_ALIGNMENT = 0x8A34
+ ACTIVE_UNIFORM_BLOCK_MAX_NAME_LENGTH = 0x8A35
+ ACTIVE_UNIFORM_BLOCKS = 0x8A36
+ UNIFORM_TYPE = 0x8A37
+ UNIFORM_SIZE = 0x8A38
+ UNIFORM_NAME_LENGTH = 0x8A39
+ UNIFORM_BLOCK_INDEX = 0x8A3A
+ UNIFORM_OFFSET = 0x8A3B
+ UNIFORM_ARRAY_STRIDE = 0x8A3C
+ UNIFORM_MATRIX_STRIDE = 0x8A3D
+ UNIFORM_IS_ROW_MAJOR = 0x8A3E
+ UNIFORM_BLOCK_BINDING = 0x8A3F
+ UNIFORM_BLOCK_DATA_SIZE = 0x8A40
+ UNIFORM_BLOCK_NAME_LENGTH = 0x8A41
+ UNIFORM_BLOCK_ACTIVE_UNIFORMS = 0x8A42
+ UNIFORM_BLOCK_ACTIVE_UNIFORM_INDICES = 0x8A43
+ UNIFORM_BLOCK_REFERENCED_BY_VERTEX_SHADER = 0x8A44
+ UNIFORM_BLOCK_REFERENCED_BY_GEOMETRY_SHADER = 0x8A45
+ UNIFORM_BLOCK_REFERENCED_BY_FRAGMENT_SHADER = 0x8A46
+ FRAGMENT_SHADER = 0x8B30
+ VERTEX_SHADER = 0x8B31
+ MAX_FRAGMENT_UNIFORM_COMPONENTS = 0x8B49
+ MAX_VERTEX_UNIFORM_COMPONENTS = 0x8B4A
+ MAX_VARYING_FLOATS = 0x8B4B
+ MAX_VARYING_COMPONENTS = 0x8B4B
+ MAX_VERTEX_TEXTURE_IMAGE_UNITS = 0x8B4C
+ MAX_COMBINED_TEXTURE_IMAGE_UNITS = 0x8B4D
+ SHADER_TYPE = 0x8B4F
+ FLOAT_VEC2 = 0x8B50
+ FLOAT_VEC3 = 0x8B51
+ FLOAT_VEC4 = 0x8B52
+ INT_VEC2 = 0x8B53
+ INT_VEC3 = 0x8B54
+ INT_VEC4 = 0x8B55
+ BOOL = 0x8B56
+ BOOL_VEC2 = 0x8B57
+ BOOL_VEC3 = 0x8B58
+ BOOL_VEC4 = 0x8B59
+ FLOAT_MAT2 = 0x8B5A
+ FLOAT_MAT3 = 0x8B5B
+ FLOAT_MAT4 = 0x8B5C
+ SAMPLER_1D = 0x8B5D
+ SAMPLER_2D = 0x8B5E
+ SAMPLER_3D = 0x8B5F
+ SAMPLER_CUBE = 0x8B60
+ SAMPLER_1D_SHADOW = 0x8B61
+ SAMPLER_2D_SHADOW = 0x8B62
+ SAMPLER_2D_RECT = 0x8B63
+ SAMPLER_2D_RECT_SHADOW = 0x8B64
+ FLOAT_MAT2x3 = 0x8B65
+ FLOAT_MAT2x4 = 0x8B66
+ FLOAT_MAT3x2 = 0x8B67
+ FLOAT_MAT3x4 = 0x8B68
+ FLOAT_MAT4x2 = 0x8B69
+ FLOAT_MAT4x3 = 0x8B6A
+ DELETE_STATUS = 0x8B80
+ COMPILE_STATUS = 0x8B81
+ LINK_STATUS = 0x8B82
+ VALIDATE_STATUS = 0x8B83
+ INFO_LOG_LENGTH = 0x8B84
+ ATTACHED_SHADERS = 0x8B85
+ ACTIVE_UNIFORMS = 0x8B86
+ ACTIVE_UNIFORM_MAX_LENGTH = 0x8B87
+ SHADER_SOURCE_LENGTH = 0x8B88
+ ACTIVE_ATTRIBUTES = 0x8B89
+ ACTIVE_ATTRIBUTE_MAX_LENGTH = 0x8B8A
+ SHADING_LANGUAGE_VERSION = 0x8B8C
+ CURRENT_PROGRAM = 0x8B8D
+ TEXTURE_RED_TYPE = 0x8C10
+ TEXTURE_GREEN_TYPE = 0x8C11
+ TEXTURE_BLUE_TYPE = 0x8C12
+ TEXTURE_ALPHA_TYPE = 0x8C13
+ TEXTURE_LUMINANCE_TYPE = 0x8C14
+ TEXTURE_INTENSITY_TYPE = 0x8C15
+ TEXTURE_DEPTH_TYPE = 0x8C16
+ UNSIGNED_NORMALIZED = 0x8C17
+ TEXTURE_1D_ARRAY = 0x8C18
+ PROXY_TEXTURE_1D_ARRAY = 0x8C19
+ TEXTURE_2D_ARRAY = 0x8C1A
+ PROXY_TEXTURE_2D_ARRAY = 0x8C1B
+ TEXTURE_BINDING_1D_ARRAY = 0x8C1C
+ TEXTURE_BINDING_2D_ARRAY = 0x8C1D
+ MAX_GEOMETRY_TEXTURE_IMAGE_UNITS = 0x8C29
+ TEXTURE_BUFFER = 0x8C2A
+ MAX_TEXTURE_BUFFER_SIZE = 0x8C2B
+ TEXTURE_BINDING_BUFFER = 0x8C2C
+ TEXTURE_BUFFER_DATA_STORE_BINDING = 0x8C2D
+ ANY_SAMPLES_PASSED = 0x8C2F
+ SAMPLE_SHADING = 0x8C36
+ MIN_SAMPLE_SHADING_VALUE = 0x8C37
+ R11F_G11F_B10F = 0x8C3A
+ UNSIGNED_INT_10F_11F_11F_REV = 0x8C3B
+ RGB9_E5 = 0x8C3D
+ UNSIGNED_INT_5_9_9_9_REV = 0x8C3E
+ TEXTURE_SHARED_SIZE = 0x8C3F
+ SRGB = 0x8C40
+ SRGB8 = 0x8C41
+ SRGB_ALPHA = 0x8C42
+ SRGB8_ALPHA8 = 0x8C43
+ SLUMINANCE_ALPHA = 0x8C44
+ SLUMINANCE8_ALPHA8 = 0x8C45
+ SLUMINANCE = 0x8C46
+ SLUMINANCE8 = 0x8C47
+ COMPRESSED_SRGB = 0x8C48
+ COMPRESSED_SRGB_ALPHA = 0x8C49
+ COMPRESSED_SLUMINANCE = 0x8C4A
+ COMPRESSED_SLUMINANCE_ALPHA = 0x8C4B
+ TRANSFORM_FEEDBACK_VARYING_MAX_LENGTH = 0x8C76
+ TRANSFORM_FEEDBACK_BUFFER_MODE = 0x8C7F
+ MAX_TRANSFORM_FEEDBACK_SEPARATE_COMPONENTS = 0x8C80
+ TRANSFORM_FEEDBACK_VARYINGS = 0x8C83
+ TRANSFORM_FEEDBACK_BUFFER_START = 0x8C84
+ TRANSFORM_FEEDBACK_BUFFER_SIZE = 0x8C85
+ PRIMITIVES_GENERATED = 0x8C87
+ TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN = 0x8C88
+ RASTERIZER_DISCARD = 0x8C89
+ MAX_TRANSFORM_FEEDBACK_INTERLEAVED_COMPONENTS = 0x8C8A
+ MAX_TRANSFORM_FEEDBACK_SEPARATE_ATTRIBS = 0x8C8B
+ INTERLEAVED_ATTRIBS = 0x8C8C
+ SEPARATE_ATTRIBS = 0x8C8D
+ TRANSFORM_FEEDBACK_BUFFER = 0x8C8E
+ TRANSFORM_FEEDBACK_BUFFER_BINDING = 0x8C8F
+ POINT_SPRITE_COORD_ORIGIN = 0x8CA0
+ LOWER_LEFT = 0x8CA1
+ UPPER_LEFT = 0x8CA2
+ STENCIL_BACK_REF = 0x8CA3
+ STENCIL_BACK_VALUE_MASK = 0x8CA4
+ STENCIL_BACK_WRITEMASK = 0x8CA5
+ DRAW_FRAMEBUFFER_BINDING = 0x8CA6
+ FRAMEBUFFER_BINDING = 0x8CA6
+ RENDERBUFFER_BINDING = 0x8CA7
+ READ_FRAMEBUFFER = 0x8CA8
+ DRAW_FRAMEBUFFER = 0x8CA9
+ READ_FRAMEBUFFER_BINDING = 0x8CAA
+ RENDERBUFFER_SAMPLES = 0x8CAB
+ DEPTH_COMPONENT32F = 0x8CAC
+ DEPTH32F_STENCIL8 = 0x8CAD
+ FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE = 0x8CD0
+ FRAMEBUFFER_ATTACHMENT_OBJECT_NAME = 0x8CD1
+ FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL = 0x8CD2
+ FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE = 0x8CD3
+ FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER = 0x8CD4
+ FRAMEBUFFER_COMPLETE = 0x8CD5
+ FRAMEBUFFER_INCOMPLETE_ATTACHMENT = 0x8CD6
+ FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT = 0x8CD7
+ FRAMEBUFFER_INCOMPLETE_DRAW_BUFFER = 0x8CDB
+ FRAMEBUFFER_INCOMPLETE_READ_BUFFER = 0x8CDC
+ FRAMEBUFFER_UNSUPPORTED = 0x8CDD
+ MAX_COLOR_ATTACHMENTS = 0x8CDF
+ COLOR_ATTACHMENT0 = 0x8CE0
+ COLOR_ATTACHMENT1 = 0x8CE1
+ COLOR_ATTACHMENT2 = 0x8CE2
+ COLOR_ATTACHMENT3 = 0x8CE3
+ COLOR_ATTACHMENT4 = 0x8CE4
+ COLOR_ATTACHMENT5 = 0x8CE5
+ COLOR_ATTACHMENT6 = 0x8CE6
+ COLOR_ATTACHMENT7 = 0x8CE7
+ COLOR_ATTACHMENT8 = 0x8CE8
+ COLOR_ATTACHMENT9 = 0x8CE9
+ COLOR_ATTACHMENT10 = 0x8CEA
+ COLOR_ATTACHMENT11 = 0x8CEB
+ COLOR_ATTACHMENT12 = 0x8CEC
+ COLOR_ATTACHMENT13 = 0x8CED
+ COLOR_ATTACHMENT14 = 0x8CEE
+ COLOR_ATTACHMENT15 = 0x8CEF
+ DEPTH_ATTACHMENT = 0x8D00
+ STENCIL_ATTACHMENT = 0x8D20
+ FRAMEBUFFER = 0x8D40
+ RENDERBUFFER = 0x8D41
+ RENDERBUFFER_WIDTH = 0x8D42
+ RENDERBUFFER_HEIGHT = 0x8D43
+ RENDERBUFFER_INTERNAL_FORMAT = 0x8D44
+ STENCIL_INDEX1 = 0x8D46
+ STENCIL_INDEX4 = 0x8D47
+ STENCIL_INDEX8 = 0x8D48
+ STENCIL_INDEX16 = 0x8D49
+ RENDERBUFFER_RED_SIZE = 0x8D50
+ RENDERBUFFER_GREEN_SIZE = 0x8D51
+ RENDERBUFFER_BLUE_SIZE = 0x8D52
+ RENDERBUFFER_ALPHA_SIZE = 0x8D53
+ RENDERBUFFER_DEPTH_SIZE = 0x8D54
+ RENDERBUFFER_STENCIL_SIZE = 0x8D55
+ FRAMEBUFFER_INCOMPLETE_MULTISAMPLE = 0x8D56
+ MAX_SAMPLES = 0x8D57
+ RGBA32UI = 0x8D70
+ RGB32UI = 0x8D71
+ RGBA16UI = 0x8D76
+ RGB16UI = 0x8D77
+ RGBA8UI = 0x8D7C
+ RGB8UI = 0x8D7D
+ RGBA32I = 0x8D82
+ RGB32I = 0x8D83
+ RGBA16I = 0x8D88
+ RGB16I = 0x8D89
+ RGBA8I = 0x8D8E
+ RGB8I = 0x8D8F
+ RED_INTEGER = 0x8D94
+ GREEN_INTEGER = 0x8D95
+ BLUE_INTEGER = 0x8D96
+ ALPHA_INTEGER = 0x8D97
+ RGB_INTEGER = 0x8D98
+ RGBA_INTEGER = 0x8D99
+ BGR_INTEGER = 0x8D9A
+ BGRA_INTEGER = 0x8D9B
+ INT_2_10_10_10_REV = 0x8D9F
+ FRAMEBUFFER_ATTACHMENT_LAYERED = 0x8DA7
+ FRAMEBUFFER_INCOMPLETE_LAYER_TARGETS = 0x8DA8
+ FLOAT_32_UNSIGNED_INT_24_8_REV = 0x8DAD
+ FRAMEBUFFER_SRGB = 0x8DB9
+ COMPRESSED_RED_RGTC1 = 0x8DBB
+ COMPRESSED_SIGNED_RED_RGTC1 = 0x8DBC
+ COMPRESSED_RG_RGTC2 = 0x8DBD
+ COMPRESSED_SIGNED_RG_RGTC2 = 0x8DBE
+ SAMPLER_1D_ARRAY = 0x8DC0
+ SAMPLER_2D_ARRAY = 0x8DC1
+ SAMPLER_BUFFER = 0x8DC2
+ SAMPLER_1D_ARRAY_SHADOW = 0x8DC3
+ SAMPLER_2D_ARRAY_SHADOW = 0x8DC4
+ SAMPLER_CUBE_SHADOW = 0x8DC5
+ UNSIGNED_INT_VEC2 = 0x8DC6
+ UNSIGNED_INT_VEC3 = 0x8DC7
+ UNSIGNED_INT_VEC4 = 0x8DC8
+ INT_SAMPLER_1D = 0x8DC9
+ INT_SAMPLER_2D = 0x8DCA
+ INT_SAMPLER_3D = 0x8DCB
+ INT_SAMPLER_CUBE = 0x8DCC
+ INT_SAMPLER_2D_RECT = 0x8DCD
+ INT_SAMPLER_1D_ARRAY = 0x8DCE
+ INT_SAMPLER_2D_ARRAY = 0x8DCF
+ INT_SAMPLER_BUFFER = 0x8DD0
+ UNSIGNED_INT_SAMPLER_1D = 0x8DD1
+ UNSIGNED_INT_SAMPLER_2D = 0x8DD2
+ UNSIGNED_INT_SAMPLER_3D = 0x8DD3
+ UNSIGNED_INT_SAMPLER_CUBE = 0x8DD4
+ UNSIGNED_INT_SAMPLER_2D_RECT = 0x8DD5
+ UNSIGNED_INT_SAMPLER_1D_ARRAY = 0x8DD6
+ UNSIGNED_INT_SAMPLER_2D_ARRAY = 0x8DD7
+ UNSIGNED_INT_SAMPLER_BUFFER = 0x8DD8
+ GEOMETRY_SHADER = 0x8DD9
+ MAX_GEOMETRY_UNIFORM_COMPONENTS = 0x8DDF
+ MAX_GEOMETRY_OUTPUT_VERTICES = 0x8DE0
+ MAX_GEOMETRY_TOTAL_OUTPUT_COMPONENTS = 0x8DE1
+ ACTIVE_SUBROUTINES = 0x8DE5
+ ACTIVE_SUBROUTINE_UNIFORMS = 0x8DE6
+ MAX_SUBROUTINES = 0x8DE7
+ MAX_SUBROUTINE_UNIFORM_LOCATIONS = 0x8DE8
+ QUERY_WAIT = 0x8E13
+ QUERY_NO_WAIT = 0x8E14
+ QUERY_BY_REGION_WAIT = 0x8E15
+ QUERY_BY_REGION_NO_WAIT = 0x8E16
+ MAX_COMBINED_TESS_CONTROL_UNIFORM_COMPONENTS = 0x8E1E
+ MAX_COMBINED_TESS_EVALUATION_UNIFORM_COMPONENTS = 0x8E1F
+ TRANSFORM_FEEDBACK = 0x8E22
+ TRANSFORM_FEEDBACK_BUFFER_PAUSED = 0x8E23
+ TRANSFORM_FEEDBACK_BUFFER_ACTIVE = 0x8E24
+ TRANSFORM_FEEDBACK_BINDING = 0x8E25
+ TIMESTAMP = 0x8E28
+ TEXTURE_SWIZZLE_R = 0x8E42
+ TEXTURE_SWIZZLE_G = 0x8E43
+ TEXTURE_SWIZZLE_B = 0x8E44
+ TEXTURE_SWIZZLE_A = 0x8E45
+ TEXTURE_SWIZZLE_RGBA = 0x8E46
+ ACTIVE_SUBROUTINE_UNIFORM_LOCATIONS = 0x8E47
+ ACTIVE_SUBROUTINE_MAX_LENGTH = 0x8E48
+ ACTIVE_SUBROUTINE_UNIFORM_MAX_LENGTH = 0x8E49
+ NUM_COMPATIBLE_SUBROUTINES = 0x8E4A
+ COMPATIBLE_SUBROUTINES = 0x8E4B
+ QUADS_FOLLOW_PROVOKING_VERTEX_CONVENTION = 0x8E4C
+ FIRST_VERTEX_CONVENTION = 0x8E4D
+ LAST_VERTEX_CONVENTION = 0x8E4E
+ PROVOKING_VERTEX = 0x8E4F
+ SAMPLE_POSITION = 0x8E50
+ SAMPLE_MASK = 0x8E51
+ SAMPLE_MASK_VALUE = 0x8E52
+ MAX_SAMPLE_MASK_WORDS = 0x8E59
+ MAX_GEOMETRY_SHADER_INVOCATIONS = 0x8E5A
+ MIN_FRAGMENT_INTERPOLATION_OFFSET = 0x8E5B
+ MAX_FRAGMENT_INTERPOLATION_OFFSET = 0x8E5C
+ FRAGMENT_INTERPOLATION_OFFSET_BITS = 0x8E5D
+ MIN_PROGRAM_TEXTURE_GATHER_OFFSET = 0x8E5E
+ MAX_PROGRAM_TEXTURE_GATHER_OFFSET = 0x8E5F
+ MAX_TRANSFORM_FEEDBACK_BUFFERS = 0x8E70
+ MAX_VERTEX_STREAMS = 0x8E71
+ PATCH_VERTICES = 0x8E72
+ PATCH_DEFAULT_INNER_LEVEL = 0x8E73
+ PATCH_DEFAULT_OUTER_LEVEL = 0x8E74
+ TESS_CONTROL_OUTPUT_VERTICES = 0x8E75
+ TESS_GEN_MODE = 0x8E76
+ TESS_GEN_SPACING = 0x8E77
+ TESS_GEN_VERTEX_ORDER = 0x8E78
+ TESS_GEN_POINT_MODE = 0x8E79
+ ISOLINES = 0x8E7A
+ FRACTIONAL_ODD = 0x8E7B
+ FRACTIONAL_EVEN = 0x8E7C
+ MAX_PATCH_VERTICES = 0x8E7D
+ MAX_TESS_GEN_LEVEL = 0x8E7E
+ MAX_TESS_CONTROL_UNIFORM_COMPONENTS = 0x8E7F
+ MAX_TESS_EVALUATION_UNIFORM_COMPONENTS = 0x8E80
+ MAX_TESS_CONTROL_TEXTURE_IMAGE_UNITS = 0x8E81
+ MAX_TESS_EVALUATION_TEXTURE_IMAGE_UNITS = 0x8E82
+ MAX_TESS_CONTROL_OUTPUT_COMPONENTS = 0x8E83
+ MAX_TESS_PATCH_COMPONENTS = 0x8E84
+ MAX_TESS_CONTROL_TOTAL_OUTPUT_COMPONENTS = 0x8E85
+ MAX_TESS_EVALUATION_OUTPUT_COMPONENTS = 0x8E86
+ TESS_EVALUATION_SHADER = 0x8E87
+ TESS_CONTROL_SHADER = 0x8E88
+ MAX_TESS_CONTROL_UNIFORM_BLOCKS = 0x8E89
+ MAX_TESS_EVALUATION_UNIFORM_BLOCKS = 0x8E8A
+ COPY_READ_BUFFER = 0x8F36
+ COPY_WRITE_BUFFER = 0x8F37
+ DRAW_INDIRECT_BUFFER = 0x8F3F
+ DRAW_INDIRECT_BUFFER_BINDING = 0x8F43
+ DOUBLE_MAT2 = 0x8F46
+ DOUBLE_MAT3 = 0x8F47
+ DOUBLE_MAT4 = 0x8F48
+ DOUBLE_MAT2x3 = 0x8F49
+ DOUBLE_MAT2x4 = 0x8F4A
+ DOUBLE_MAT3x2 = 0x8F4B
+ DOUBLE_MAT3x4 = 0x8F4C
+ DOUBLE_MAT4x2 = 0x8F4D
+ DOUBLE_MAT4x3 = 0x8F4E
+ R8_SNORM = 0x8F94
+ RG8_SNORM = 0x8F95
+ RGB8_SNORM = 0x8F96
+ RGBA8_SNORM = 0x8F97
+ R16_SNORM = 0x8F98
+ RG16_SNORM = 0x8F99
+ RGB16_SNORM = 0x8F9A
+ RGBA16_SNORM = 0x8F9B
+ SIGNED_NORMALIZED = 0x8F9C
+ PRIMITIVE_RESTART = 0x8F9D
+ PRIMITIVE_RESTART_INDEX = 0x8F9E
+ DOUBLE_VEC2 = 0x8FFC
+ DOUBLE_VEC3 = 0x8FFD
+ DOUBLE_VEC4 = 0x8FFE
+ TEXTURE_CUBE_MAP_ARRAY = 0x9009
+ TEXTURE_BINDING_CUBE_MAP_ARRAY = 0x900A
+ PROXY_TEXTURE_CUBE_MAP_ARRAY = 0x900B
+ SAMPLER_CUBE_MAP_ARRAY = 0x900C
+ SAMPLER_CUBE_MAP_ARRAY_SHADOW = 0x900D
+ INT_SAMPLER_CUBE_MAP_ARRAY = 0x900E
+ UNSIGNED_INT_SAMPLER_CUBE_MAP_ARRAY = 0x900F
+ RGB10_A2UI = 0x906F
+ TEXTURE_2D_MULTISAMPLE = 0x9100
+ PROXY_TEXTURE_2D_MULTISAMPLE = 0x9101
+ TEXTURE_2D_MULTISAMPLE_ARRAY = 0x9102
+ PROXY_TEXTURE_2D_MULTISAMPLE_ARRAY = 0x9103
+ TEXTURE_BINDING_2D_MULTISAMPLE = 0x9104
+ TEXTURE_BINDING_2D_MULTISAMPLE_ARRAY = 0x9105
+ TEXTURE_SAMPLES = 0x9106
+ TEXTURE_FIXED_SAMPLE_LOCATIONS = 0x9107
+ SAMPLER_2D_MULTISAMPLE = 0x9108
+ INT_SAMPLER_2D_MULTISAMPLE = 0x9109
+ UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE = 0x910A
+ SAMPLER_2D_MULTISAMPLE_ARRAY = 0x910B
+ INT_SAMPLER_2D_MULTISAMPLE_ARRAY = 0x910C
+ UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE_ARRAY = 0x910D
+ MAX_COLOR_TEXTURE_SAMPLES = 0x910E
+ MAX_DEPTH_TEXTURE_SAMPLES = 0x910F
+ MAX_INTEGER_SAMPLES = 0x9110
+ MAX_SERVER_WAIT_TIMEOUT = 0x9111
+ OBJECT_TYPE = 0x9112
+ SYNC_CONDITION = 0x9113
+ SYNC_STATUS = 0x9114
+ SYNC_FLAGS = 0x9115
+ SYNC_FENCE = 0x9116
+ SYNC_GPU_COMMANDS_COMPLETE = 0x9117
+ UNSIGNALED = 0x9118
+ SIGNALED = 0x9119
+ ALREADY_SIGNALED = 0x911A
+ TIMEOUT_EXPIRED = 0x911B
+ CONDITION_SATISFIED = 0x911C
+ WAIT_FAILED = 0x911D
+ BUFFER_ACCESS_FLAGS = 0x911F
+ BUFFER_MAP_LENGTH = 0x9120
+ BUFFER_MAP_OFFSET = 0x9121
+ MAX_VERTEX_OUTPUT_COMPONENTS = 0x9122
+ MAX_GEOMETRY_INPUT_COMPONENTS = 0x9123
+ MAX_GEOMETRY_OUTPUT_COMPONENTS = 0x9124
+ MAX_FRAGMENT_INPUT_COMPONENTS = 0x9125
+ CONTEXT_PROFILE_MASK = 0x9126
+)
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glViewport.xml
+func (gl *GL) Viewport(x, y, width, height int) {
+ C.gl4_0compat_glViewport(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// DepthRange specifies the mapping of depth values from normalized device
+// coordinates to window coordinates.
+//
+// Parameter nearVal specifies the mapping of the near clipping plane to window
+// coordinates (defaults to 0), while farVal specifies the mapping of the far
+// clipping plane to window coordinates (defaults to 1).
+//
+// After clipping and division by w, depth coordinates range from -1 to 1,
+// corresponding to the near and far clipping planes. DepthRange specifies a
+// linear mapping of the normalized depth coordinates in this range to window
+// depth coordinates. Regardless of the actual depth buffer implementation,
+// window coordinate depth values are treated as though they range from 0 through 1
+// (like color components). Thus, the values accepted by DepthRange are both
+// clamped to this range before they are accepted.
+//
+// The default setting of (0, 1) maps the near plane to 0 and the far plane to 1.
+// With this mapping, the depth buffer range is fully utilized.
+//
+// It is not necessary that nearVal be less than farVal. Reverse mappings such as
+// nearVal 1, and farVal 0 are acceptable.
+//
+// GL.INVALID_OPERATION is generated if DepthRange is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) DepthRange(nearVal, farVal float64) {
+ C.gl4_0compat_glDepthRange(gl.funcs, C.GLdouble(nearVal), C.GLdouble(farVal))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsEnabled.xml
+func (gl *GL) IsEnabled(cap glbase.Enum) bool {
+ glresult := C.gl4_0compat_glIsEnabled(gl.funcs, C.GLenum(cap))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexLevelParameteriv.xml
+func (gl *GL) GetTexLevelParameteriv(target glbase.Enum, level int, pname glbase.Enum, params []int32) {
+ C.gl4_0compat_glGetTexLevelParameteriv(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexLevelParameterfv.xml
+func (gl *GL) GetTexLevelParameterfv(target glbase.Enum, level int, pname glbase.Enum, params []float32) {
+ C.gl4_0compat_glGetTexLevelParameterfv(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexParameteriv.xml
+func (gl *GL) GetTexParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl4_0compat_glGetTexParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexParameterfv.xml
+func (gl *GL) GetTexParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl4_0compat_glGetTexParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexImage.xml
+func (gl *GL) GetTexImage(target glbase.Enum, level int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0compat_glGetTexImage(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetIntegerv.xml
+func (gl *GL) GetIntegerv(pname glbase.Enum, params []int32) {
+ C.gl4_0compat_glGetIntegerv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetFloatv.xml
+func (gl *GL) GetFloatv(pname glbase.Enum, params []float32) {
+ C.gl4_0compat_glGetFloatv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetError.xml
+func (gl *GL) GetError() glbase.Enum {
+ glresult := C.gl4_0compat_glGetError(gl.funcs)
+ return glbase.Enum(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetDoublev.xml
+func (gl *GL) GetDoublev(pname glbase.Enum, params []float64) {
+ C.gl4_0compat_glGetDoublev(gl.funcs, C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetBooleanv.xml
+func (gl *GL) GetBooleanv(pname glbase.Enum, params []bool) {
+ C.gl4_0compat_glGetBooleanv(gl.funcs, C.GLenum(pname), (*C.GLboolean)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glReadPixels.xml
+func (gl *GL) ReadPixels(x, y, width, height int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0compat_glReadPixels(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glReadBuffer.xml
+func (gl *GL) ReadBuffer(mode glbase.Enum) {
+ C.gl4_0compat_glReadBuffer(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPixelStorei.xml
+func (gl *GL) PixelStorei(pname glbase.Enum, param int32) {
+ C.gl4_0compat_glPixelStorei(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPixelStoref.xml
+func (gl *GL) PixelStoref(pname glbase.Enum, param float32) {
+ C.gl4_0compat_glPixelStoref(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDepthFunc.xml
+func (gl *GL) DepthFunc(glfunc glbase.Enum) {
+ C.gl4_0compat_glDepthFunc(gl.funcs, C.GLenum(glfunc))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glStencilOp.xml
+func (gl *GL) StencilOp(fail, zfail, zpass glbase.Enum) {
+ C.gl4_0compat_glStencilOp(gl.funcs, C.GLenum(fail), C.GLenum(zfail), C.GLenum(zpass))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glStencilFunc.xml
+func (gl *GL) StencilFunc(glfunc glbase.Enum, ref int32, mask uint32) {
+ C.gl4_0compat_glStencilFunc(gl.funcs, C.GLenum(glfunc), C.GLint(ref), C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLogicOp.xml
+func (gl *GL) LogicOp(opcode glbase.Enum) {
+ C.gl4_0compat_glLogicOp(gl.funcs, C.GLenum(opcode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendFunc.xml
+func (gl *GL) BlendFunc(sfactor, dfactor glbase.Enum) {
+ C.gl4_0compat_glBlendFunc(gl.funcs, C.GLenum(sfactor), C.GLenum(dfactor))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFlush.xml
+func (gl *GL) Flush() {
+ C.gl4_0compat_glFlush(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFinish.xml
+func (gl *GL) Finish() {
+ C.gl4_0compat_glFinish(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEnable.xml
+func (gl *GL) Enable(cap glbase.Enum) {
+ C.gl4_0compat_glEnable(gl.funcs, C.GLenum(cap))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDisable.xml
+func (gl *GL) Disable(cap glbase.Enum) {
+ C.gl4_0compat_glDisable(gl.funcs, C.GLenum(cap))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDepthMask.xml
+func (gl *GL) DepthMask(flag bool) {
+ C.gl4_0compat_glDepthMask(gl.funcs, *(*C.GLboolean)(unsafe.Pointer(&flag)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorMask.xml
+func (gl *GL) ColorMask(red, green, blue, alpha bool) {
+ C.gl4_0compat_glColorMask(gl.funcs, *(*C.GLboolean)(unsafe.Pointer(&red)), *(*C.GLboolean)(unsafe.Pointer(&green)), *(*C.GLboolean)(unsafe.Pointer(&blue)), *(*C.GLboolean)(unsafe.Pointer(&alpha)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glStencilMask.xml
+func (gl *GL) StencilMask(mask uint32) {
+ C.gl4_0compat_glStencilMask(gl.funcs, C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearDepth.xml
+func (gl *GL) ClearDepth(depth float64) {
+ C.gl4_0compat_glClearDepth(gl.funcs, C.GLdouble(depth))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearStencil.xml
+func (gl *GL) ClearStencil(s int32) {
+ C.gl4_0compat_glClearStencil(gl.funcs, C.GLint(s))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearColor.xml
+func (gl *GL) ClearColor(red, green, blue, alpha float32) {
+ C.gl4_0compat_glClearColor(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClear.xml
+func (gl *GL) Clear(mask glbase.Bitfield) {
+ C.gl4_0compat_glClear(gl.funcs, C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawBuffer.xml
+func (gl *GL) DrawBuffer(mode glbase.Enum) {
+ C.gl4_0compat_glDrawBuffer(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexImage2D.xml
+func (gl *GL) TexImage2D(target glbase.Enum, level int, internalFormat int32, width, height, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0compat_glTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexImage1D.xml
+func (gl *GL) TexImage1D(target glbase.Enum, level int, internalFormat int32, width, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0compat_glTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexParameteriv.xml
+func (gl *GL) TexParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl4_0compat_glTexParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexParameteri.xml
+func (gl *GL) TexParameteri(target, pname glbase.Enum, param int32) {
+ C.gl4_0compat_glTexParameteri(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexParameterfv.xml
+func (gl *GL) TexParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl4_0compat_glTexParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexParameterf.xml
+func (gl *GL) TexParameterf(target, pname glbase.Enum, param float32) {
+ C.gl4_0compat_glTexParameterf(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glScissor.xml
+func (gl *GL) Scissor(x, y, width, height int) {
+ C.gl4_0compat_glScissor(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPolygonMode.xml
+func (gl *GL) PolygonMode(face, mode glbase.Enum) {
+ C.gl4_0compat_glPolygonMode(gl.funcs, C.GLenum(face), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPointSize.xml
+func (gl *GL) PointSize(size float32) {
+ C.gl4_0compat_glPointSize(gl.funcs, C.GLfloat(size))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLineWidth.xml
+func (gl *GL) LineWidth(width float32) {
+ C.gl4_0compat_glLineWidth(gl.funcs, C.GLfloat(width))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glHint.xml
+func (gl *GL) Hint(target, mode glbase.Enum) {
+ C.gl4_0compat_glHint(gl.funcs, C.GLenum(target), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFrontFace.xml
+func (gl *GL) FrontFace(mode glbase.Enum) {
+ C.gl4_0compat_glFrontFace(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCullFace.xml
+func (gl *GL) CullFace(mode glbase.Enum) {
+ C.gl4_0compat_glCullFace(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIndexubv.xml
+func (gl *GL) Indexubv(c []uint8) {
+ C.gl4_0compat_glIndexubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIndexub.xml
+func (gl *GL) Indexub(c uint8) {
+ C.gl4_0compat_glIndexub(gl.funcs, C.GLubyte(c))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsTexture.xml
+func (gl *GL) IsTexture(texture glbase.Texture) bool {
+ glresult := C.gl4_0compat_glIsTexture(gl.funcs, C.GLuint(texture))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// GenTextures returns n texture names in textures. There is no guarantee
+// that the names form a contiguous set of integers; however, it is
+// guaranteed that none of the returned names was in use immediately before
+// the call to GenTextures.
+//
+// The generated textures have no dimensionality; they assume the
+// dimensionality of the texture target to which they are first bound (see
+// BindTexture).
+//
+// Texture names returned by a call to GenTextures are not returned by
+// subsequent calls, unless they are first deleted with DeleteTextures.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// GenTextures is available in GL version 2.0 or greater.
+func (gl *GL) GenTextures(n int) []glbase.Texture {
+ if n == 0 {
+ return nil
+ }
+ textures := make([]glbase.Texture, n)
+ C.gl4_0compat_glGenTextures(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])))
+ return textures
+}
+
+// DeleteTextures deletes the textures objects whose names are stored
+// in the textures slice. After a texture is deleted, it has no contents or
+// dimensionality, and its name is free for reuse (for example by
+// GenTextures). If a texture that is currently bound is deleted, the binding
+// reverts to 0 (the default texture).
+//
+// DeleteTextures silently ignores 0's and names that do not correspond to
+// existing textures.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// DeleteTextures is available in GL version 2.0 or greater.
+func (gl *GL) DeleteTextures(textures []glbase.Texture) {
+ n := len(textures)
+ if n == 0 {
+ return
+ }
+ C.gl4_0compat_glDeleteTextures(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindTexture.xml
+func (gl *GL) BindTexture(target glbase.Enum, texture glbase.Texture) {
+ C.gl4_0compat_glBindTexture(gl.funcs, C.GLenum(target), C.GLuint(texture))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexSubImage2D.xml
+func (gl *GL) TexSubImage2D(target glbase.Enum, level, xoffset, yoffset, width, height int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0compat_glTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexSubImage1D.xml
+func (gl *GL) TexSubImage1D(target glbase.Enum, level, xoffset, width int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0compat_glTexSubImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLsizei(width), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyTexSubImage2D.xml
+func (gl *GL) CopyTexSubImage2D(target glbase.Enum, level, xoffset, yoffset, x, y, width, height int) {
+ C.gl4_0compat_glCopyTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyTexSubImage1D.xml
+func (gl *GL) CopyTexSubImage1D(target glbase.Enum, level, xoffset, x, y, width int) {
+ C.gl4_0compat_glCopyTexSubImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(x), C.GLint(y), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyTexImage2D.xml
+func (gl *GL) CopyTexImage2D(target glbase.Enum, level int, internalFormat glbase.Enum, x, y, width, height, border int) {
+ C.gl4_0compat_glCopyTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height), C.GLint(border))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyTexImage1D.xml
+func (gl *GL) CopyTexImage1D(target glbase.Enum, level int, internalFormat glbase.Enum, x, y, width, border int) {
+ C.gl4_0compat_glCopyTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLint(border))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPolygonOffset.xml
+func (gl *GL) PolygonOffset(factor, units float32) {
+ C.gl4_0compat_glPolygonOffset(gl.funcs, C.GLfloat(factor), C.GLfloat(units))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawElements.xml
+func (gl *GL) DrawElements(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0compat_glDrawElements(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawArrays.xml
+func (gl *GL) DrawArrays(mode glbase.Enum, first, count int) {
+ C.gl4_0compat_glDrawArrays(gl.funcs, C.GLenum(mode), C.GLint(first), C.GLsizei(count))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyTexSubImage3D.xml
+func (gl *GL) CopyTexSubImage3D(target glbase.Enum, level, xoffset, yoffset int, zoffset int32, x, y, width, height int) {
+ C.gl4_0compat_glCopyTexSubImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(zoffset), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexSubImage3D.xml
+func (gl *GL) TexSubImage3D(target glbase.Enum, level, xoffset, yoffset int, zoffset int32, width, height int, depth int32, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0compat_glTexSubImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(zoffset), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexImage3D.xml
+func (gl *GL) TexImage3D(target glbase.Enum, level int, internalFormat int32, width, height int, depth int32, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0compat_glTexImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawRangeElements.xml
+func (gl *GL) DrawRangeElements(mode glbase.Enum, start, end uint32, count int, gltype glbase.Enum, indices interface{}) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0compat_glDrawRangeElements(gl.funcs, C.GLenum(mode), C.GLuint(start), C.GLuint(end), C.GLsizei(count), C.GLenum(gltype), indices_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendEquation.xml
+func (gl *GL) BlendEquation(mode glbase.Enum) {
+ C.gl4_0compat_glBlendEquation(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendColor.xml
+func (gl *GL) BlendColor(red, green, blue, alpha float32) {
+ C.gl4_0compat_glBlendColor(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetCompressedTexImage.xml
+func (gl *GL) GetCompressedTexImage(target glbase.Enum, level int, img interface{}) {
+ var img_ptr unsafe.Pointer
+ var img_v = reflect.ValueOf(img)
+ if img != nil && img_v.Kind() != reflect.Slice {
+ panic("parameter img must be a slice")
+ }
+ if img != nil {
+ img_ptr = unsafe.Pointer(img_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0compat_glGetCompressedTexImage(gl.funcs, C.GLenum(target), C.GLint(level), img_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCompressedTexSubImage1D.xml
+func (gl *GL) CompressedTexSubImage1D(target glbase.Enum, level, xoffset, width int, format glbase.Enum, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0compat_glCompressedTexSubImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLsizei(width), C.GLenum(format), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCompressedTexSubImage2D.xml
+func (gl *GL) CompressedTexSubImage2D(target glbase.Enum, level, xoffset, yoffset, width, height int, format glbase.Enum, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0compat_glCompressedTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCompressedTexSubImage3D.xml
+func (gl *GL) CompressedTexSubImage3D(target glbase.Enum, level, xoffset, yoffset int, zoffset int32, width, height int, depth int32, format glbase.Enum, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0compat_glCompressedTexSubImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(zoffset), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLenum(format), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCompressedTexImage1D.xml
+func (gl *GL) CompressedTexImage1D(target glbase.Enum, level int, internalFormat glbase.Enum, width, border, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0compat_glCompressedTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLsizei(width), C.GLint(border), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCompressedTexImage2D.xml
+func (gl *GL) CompressedTexImage2D(target glbase.Enum, level int, internalFormat glbase.Enum, width, height, border, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0compat_glCompressedTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLint(border), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCompressedTexImage3D.xml
+func (gl *GL) CompressedTexImage3D(target glbase.Enum, level int, internalFormat glbase.Enum, width, height int, depth int32, border, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0compat_glCompressedTexImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLint(border), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSampleCoverage.xml
+func (gl *GL) SampleCoverage(value float32, invert bool) {
+ C.gl4_0compat_glSampleCoverage(gl.funcs, C.GLfloat(value), *(*C.GLboolean)(unsafe.Pointer(&invert)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glActiveTexture.xml
+func (gl *GL) ActiveTexture(texture glbase.Enum) {
+ C.gl4_0compat_glActiveTexture(gl.funcs, C.GLenum(texture))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPointParameteriv.xml
+func (gl *GL) PointParameteriv(pname glbase.Enum, params []int32) {
+ C.gl4_0compat_glPointParameteriv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPointParameteri.xml
+func (gl *GL) PointParameteri(pname glbase.Enum, param int32) {
+ C.gl4_0compat_glPointParameteri(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPointParameterfv.xml
+func (gl *GL) PointParameterfv(pname glbase.Enum, params []float32) {
+ C.gl4_0compat_glPointParameterfv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPointParameterf.xml
+func (gl *GL) PointParameterf(pname glbase.Enum, param float32) {
+ C.gl4_0compat_glPointParameterf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiDrawArrays.xml
+func (gl *GL) MultiDrawArrays(mode glbase.Enum, first, count []int, drawcount int32) {
+ C.gl4_0compat_glMultiDrawArrays(gl.funcs, C.GLenum(mode), (*C.GLint)(unsafe.Pointer(&first[0])), (*C.GLsizei)(unsafe.Pointer(&count[0])), C.GLsizei(drawcount))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendFuncSeparate.xml
+func (gl *GL) BlendFuncSeparate(sfactorRGB, dfactorRGB, sfactorAlpha, dfactorAlpha glbase.Enum) {
+ C.gl4_0compat_glBlendFuncSeparate(gl.funcs, C.GLenum(sfactorRGB), C.GLenum(dfactorRGB), C.GLenum(sfactorAlpha), C.GLenum(dfactorAlpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetBufferParameteriv.xml
+func (gl *GL) GetBufferParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl4_0compat_glGetBufferParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUnmapBuffer.xml
+func (gl *GL) UnmapBuffer(target glbase.Enum) bool {
+ glresult := C.gl4_0compat_glUnmapBuffer(gl.funcs, C.GLenum(target))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetBufferSubData.xml
+func (gl *GL) GetBufferSubData(target glbase.Enum, offset, size int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0compat_glGetBufferSubData(gl.funcs, C.GLenum(target), C.GLintptr(offset), C.GLsizeiptr(size), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBufferSubData.xml
+func (gl *GL) BufferSubData(target glbase.Enum, offset, size int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0compat_glBufferSubData(gl.funcs, C.GLenum(target), C.GLintptr(offset), C.GLsizeiptr(size), data_ptr)
+}
+
+// BufferData creates a new data store for the buffer object currently
+// bound to target. Any pre-existing data store is deleted. The new data
+// store is created with the specified size in bytes and usage. If data is
+// not nil, it must be a slice that is used to initialize the data store.
+// In that case the size parameter is ignored and the store size will match
+// the slice data size.
+//
+// In its initial state, the new data store is not mapped, it has a NULL
+// mapped pointer, and its mapped access is GL.READ_WRITE.
+//
+// The target constant must be one of GL.ARRAY_BUFFER, GL.COPY_READ_BUFFER,
+// GL.COPY_WRITE_BUFFER, GL.ELEMENT_ARRAY_BUFFER, GL.PIXEL_PACK_BUFFER,
+// GL.PIXEL_UNPACK_BUFFER, GL.TEXTURE_BUFFER, GL.TRANSFORM_FEEDBACK_BUFFER,
+// or GL.UNIFORM_BUFFER.
+//
+// The usage parameter is a hint to the GL implementation as to how a buffer
+// object's data store will be accessed. This enables the GL implementation
+// to make more intelligent decisions that may significantly impact buffer
+// object performance. It does not, however, constrain the actual usage of
+// the data store. usage can be broken down into two parts: first, the
+// frequency of access (modification and usage), and second, the nature of
+// that access.
+//
+// A usage frequency of STREAM and nature of DRAW is specified via the
+// constant GL.STREAM_DRAW, for example.
+//
+// The usage frequency of access may be one of:
+//
+// STREAM
+// The data store contents will be modified once and used at most a few times.
+//
+// STATIC
+// The data store contents will be modified once and used many times.
+//
+// DYNAMIC
+// The data store contents will be modified repeatedly and used many times.
+//
+// The usage nature of access may be one of:
+//
+// DRAW
+// The data store contents are modified by the application, and used as
+// the source for GL drawing and image specification commands.
+//
+// READ
+// The data store contents are modified by reading data from the GL,
+// and used to return that data when queried by the application.
+//
+// COPY
+// The data store contents are modified by reading data from the GL,
+// and used as the source for GL drawing and image specification
+// commands.
+//
+// Clients must align data elements consistent with the requirements of the
+// client platform, with an additional base-level requirement that an offset
+// within a buffer to a datum comprising N bytes be a multiple of N.
+//
+// Error GL.INVALID_ENUM is generated if target is not one of the accepted
+// buffer targets. GL.INVALID_ENUM is generated if usage is not
+// GL.STREAM_DRAW, GL.STREAM_READ, GL.STREAM_COPY, GL.STATIC_DRAW,
+// GL.STATIC_READ, GL.STATIC_COPY, GL.DYNAMIC_DRAW, GL.DYNAMIC_READ, or
+// GL.DYNAMIC_COPY. GL.INVALID_VALUE is generated if size is negative.
+// GL.INVALID_OPERATION is generated if the reserved buffer object name 0 is
+// bound to target. GL.OUT_OF_MEMORY is generated if the GL is unable to
+// create a data store with the specified size.
+func (gl *GL) BufferData(target glbase.Enum, size int, data interface{}, usage glbase.Enum) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ if data != nil {
+ size = int(data_v.Type().Size()) * data_v.Len()
+ }
+ C.gl4_0compat_glBufferData(gl.funcs, C.GLenum(target), C.GLsizeiptr(size), data_ptr, C.GLenum(usage))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsBuffer.xml
+func (gl *GL) IsBuffer(buffer glbase.Buffer) bool {
+ glresult := C.gl4_0compat_glIsBuffer(gl.funcs, C.GLuint(buffer))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// GenBuffers returns n buffer object names. There is no guarantee that
+// the names form a contiguous set of integers; however, it is guaranteed
+// that none of the returned names was in use immediately before the call to
+// GenBuffers.
+//
+// Buffer object names returned by a call to GenBuffers are not returned by
+// subsequent calls, unless they are first deleted with DeleteBuffers.
+//
+// No buffer objects are associated with the returned buffer object names
+// until they are first bound by calling BindBuffer.
+//
+// Error GL.INVALID_VALUE is generated if n is negative. GL.INVALID_OPERATION
+// is generated if GenBuffers is executed between the execution of Begin
+// and the corresponding execution of End.
+//
+// GenBuffers is available in GL version 1.5 or greater.
+func (gl *GL) GenBuffers(n int) []glbase.Buffer {
+ if n == 0 {
+ return nil
+ }
+ buffers := make([]glbase.Buffer, n)
+ C.gl4_0compat_glGenBuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&buffers[0])))
+ return buffers
+}
+
+// DeleteBuffers deletes the buffer objects whose names are stored in the
+// buffers slice.
+//
+// After a buffer object is deleted, it has no contents, and its name is free
+// for reuse (for example by GenBuffers). If a buffer object that is
+// currently bound is deleted, the binding reverts to 0 (the absence of any
+// buffer object, which reverts to client memory usage).
+//
+// DeleteBuffers silently ignores 0's and names that do not correspond to
+// existing buffer objects.
+//
+// Error GL.INVALID_VALUE is generated if n is negative. GL.INVALID_OPERATION
+// is generated if DeleteBuffers is executed between the execution of Begin
+// and the corresponding execution of End.
+//
+// DeleteBuffers is available in GL version 1.5 or greater.
+func (gl *GL) DeleteBuffers(buffers []glbase.Buffer) {
+ n := len(buffers)
+ if n == 0 {
+ return
+ }
+ C.gl4_0compat_glDeleteBuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&buffers[0])))
+}
+
+// BindBuffer creates or puts in use a named buffer object.
+// Calling BindBuffer with target set to GL.ARRAY_BUFFER,
+// GL.ELEMENT_ARRAY_BUFFER, GL.PIXEL_PACK_BUFFER or GL.PIXEL_UNPACK_BUFFER
+// and buffer set to the name of the new buffer object binds the buffer
+// object name to the target. When a buffer object is bound to a target, the
+// previous binding for that target is automatically broken.
+//
+// Buffer object names are unsigned integers. The value zero is reserved, but
+// there is no default buffer object for each buffer object target. Instead,
+// buffer set to zero effectively unbinds any buffer object previously bound,
+// and restores client memory usage for that buffer object target. Buffer
+// object names and the corresponding buffer object contents are local to the
+// shared display-list space (see XCreateContext) of the current GL rendering
+// context; two rendering contexts share buffer object names only if they
+// also share display lists.
+//
+// GenBuffers may be called to generate a set of new buffer object names.
+//
+// The state of a buffer object immediately after it is first bound is an
+// unmapped zero-sized memory buffer with GL.READ_WRITE access and
+// GL.STATIC_DRAW usage.
+//
+// While a non-zero buffer object name is bound, GL operations on the target
+// to which it is bound affect the bound buffer object, and queries of the
+// target to which it is bound return state from the bound buffer object.
+// While buffer object name zero is bound, as in the initial state, attempts
+// to modify or query state on the target to which it is bound generates an
+// GL.INVALID_OPERATION error.
+//
+// When vertex array pointer state is changed, for example by a call to
+// NormalPointer, the current buffer object binding (GL.ARRAY_BUFFER_BINDING)
+// is copied into the corresponding client state for the vertex array type
+// being changed, for example GL.NORMAL_ARRAY_BUFFER_BINDING. While a
+// non-zero buffer object is bound to the GL.ARRAY_BUFFER target, the vertex
+// array pointer parameter that is traditionally interpreted as a pointer to
+// client-side memory is instead interpreted as an offset within the buffer
+// object measured in basic machine units.
+//
+// While a non-zero buffer object is bound to the GL.ELEMENT_ARRAY_BUFFER
+// target, the indices parameter of DrawElements, DrawRangeElements, or
+// MultiDrawElements that is traditionally interpreted as a pointer to
+// client-side memory is instead interpreted as an offset within the buffer
+// object measured in basic machine units.
+//
+// While a non-zero buffer object is bound to the GL.PIXEL_PACK_BUFFER
+// target, the following commands are affected: GetCompressedTexImage,
+// GetConvolutionFilter, GetHistogram, GetMinmax, GetPixelMap,
+// GetPolygonStipple, GetSeparableFilter, GetTexImage, and ReadPixels. The
+// pointer parameter that is traditionally interpreted as a pointer to
+// client-side memory where the pixels are to be packed is instead
+// interpreted as an offset within the buffer object measured in basic
+// machine units.
+//
+// While a non-zero buffer object is bound to the GL.PIXEL_UNPACK_BUFFER
+// target, the following commands are affected: Bitmap, ColorSubTable,
+// ColorTable, CompressedTexImage1D, CompressedTexImage2D,
+// CompressedTexImage3D, CompressedTexSubImage1D, CompressedTexSubImage2D,
+// CompressedTexSubImage3D, ConvolutionFilter1D, ConvolutionFilter2D,
+// DrawPixels, PixelMap, PolygonStipple, SeparableFilter2D, TexImage1D,
+// TexImage2D, TexImage3D, TexSubImage1D, TexSubImage2D, and TexSubImage3D.
+// The pointer parameter that is traditionally interpreted as a pointer to
+// client-side memory from which the pixels are to be unpacked is instead
+// interpreted as an offset within the buffer object measured in basic
+// machine units.
+//
+// A buffer object binding created with BindBuffer remains active until a
+// different buffer object name is bound to the same target, or until the
+// bound buffer object is deleted with DeleteBuffers.
+//
+// Once created, a named buffer object may be re-bound to any target as often
+// as needed. However, the GL implementation may make choices about how to
+// optimize the storage of a buffer object based on its initial binding
+// target.
+//
+// Error GL.INVALID_ENUM is generated if target is not one of the allowable
+// values. GL.INVALID_OPERATION is generated if BindBuffer is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// BindBuffer is available in GL version 1.5 or greater.
+func (gl *GL) BindBuffer(target glbase.Enum, buffer glbase.Buffer) {
+ C.gl4_0compat_glBindBuffer(gl.funcs, C.GLenum(target), C.GLuint(buffer))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetQueryObjectuiv.xml
+func (gl *GL) GetQueryObjectuiv(id uint32, pname glbase.Enum, params []uint32) {
+ C.gl4_0compat_glGetQueryObjectuiv(gl.funcs, C.GLuint(id), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetQueryObjectiv.xml
+func (gl *GL) GetQueryObjectiv(id uint32, pname glbase.Enum, params []int32) {
+ C.gl4_0compat_glGetQueryObjectiv(gl.funcs, C.GLuint(id), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetQueryiv.xml
+func (gl *GL) GetQueryiv(target, pname glbase.Enum, params []int32) {
+ C.gl4_0compat_glGetQueryiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEndQuery.xml
+func (gl *GL) EndQuery(target glbase.Enum) {
+ C.gl4_0compat_glEndQuery(gl.funcs, C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBeginQuery.xml
+func (gl *GL) BeginQuery(target glbase.Enum, id uint32) {
+ C.gl4_0compat_glBeginQuery(gl.funcs, C.GLenum(target), C.GLuint(id))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsQuery.xml
+func (gl *GL) IsQuery(id uint32) bool {
+ glresult := C.gl4_0compat_glIsQuery(gl.funcs, C.GLuint(id))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDeleteQueries.xml
+func (gl *GL) DeleteQueries(n int, ids []uint32) {
+ C.gl4_0compat_glDeleteQueries(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&ids[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGenQueries.xml
+func (gl *GL) GenQueries(n int, ids []uint32) {
+ C.gl4_0compat_glGenQueries(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&ids[0])))
+}
+
+// VertexAttribPointer specifies the location and data format of the array
+// of generic vertex attributes at index to use when rendering. size
+// specifies the number of components per attribute and must be 1, 2, 3, or
+// 4. type specifies the data type of each component, and stride specifies
+// the byte stride from one attribute to the next, allowing vertices and
+// attributes to be packed into a single array or stored in separate arrays.
+// normalized indicates whether the values stored in an integer format are
+// to be mapped to the range [-1,1] (for signed values) or [0,1]
+// (for unsigned values) when they are accessed and converted to floating
+// point; otherwise, values will be converted to floats directly without
+// normalization. offset is a byte offset into the buffer object's data
+// store, which must be bound to the GL.ARRAY_BUFFER target with BindBuffer.
+//
+// The buffer object binding (GL.ARRAY_BUFFER_BINDING) is saved as
+// generic vertex attribute array client-side state
+// (GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING) for the provided index.
+//
+// To enable and disable a generic vertex attribute array, call
+// EnableVertexAttribArray and DisableVertexAttribArray with index. If
+// enabled, the generic vertex attribute array is used when DrawArrays or
+// DrawElements is called. Each generic vertex attribute array is initially
+// disabled.
+//
+// VertexAttribPointer is typically implemented on the client side.
+//
+// Error GL.INVALID_ENUM is generated if type is not an accepted value.
+// GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_VALUE is generated if size is not 1, 2,
+// 3, or 4. GL.INVALID_VALUE is generated if stride is negative.
+func (gl *GL) VertexAttribPointer(index glbase.Attrib, size int, gltype glbase.Enum, normalized bool, stride int, offset uintptr) {
+ offset_ptr := unsafe.Pointer(offset)
+ C.gl4_0compat_glVertexAttribPointer(gl.funcs, C.GLuint(index), C.GLint(size), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), C.GLsizei(stride), offset_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glValidateProgram.xml
+func (gl *GL) ValidateProgram(program glbase.Program) {
+ C.gl4_0compat_glValidateProgram(gl.funcs, C.GLuint(program))
+}
+
+// UniformMatrix4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix4fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(4*4) != 0 {
+ panic("invalid value length for UniformMatrix4fv")
+ }
+ count := len(value) / (4 * 4)
+ C.gl4_0compat_glUniformMatrix4fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix3fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(3*3) != 0 {
+ panic("invalid value length for UniformMatrix3fv")
+ }
+ count := len(value) / (3 * 3)
+ C.gl4_0compat_glUniformMatrix3fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix2fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(2*2) != 0 {
+ panic("invalid value length for UniformMatrix2fv")
+ }
+ count := len(value) / (2 * 2)
+ C.gl4_0compat_glUniformMatrix2fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform4iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%4 != 0 {
+ panic("invalid value length for Uniform4iv")
+ }
+ count := len(value) / 4
+ C.gl4_0compat_glUniform4iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform3iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform3iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%3 != 0 {
+ panic("invalid value length for Uniform3iv")
+ }
+ count := len(value) / 3
+ C.gl4_0compat_glUniform3iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform2iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform2iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%2 != 0 {
+ panic("invalid value length for Uniform2iv")
+ }
+ count := len(value) / 2
+ C.gl4_0compat_glUniform2iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform1iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform1iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ count := len(value)
+ C.gl4_0compat_glUniform1iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%4 != 0 {
+ panic("invalid value length for Uniform4fv")
+ }
+ count := len(value) / 4
+ C.gl4_0compat_glUniform4fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%3 != 0 {
+ panic("invalid value length for Uniform3fv")
+ }
+ count := len(value) / 3
+ C.gl4_0compat_glUniform3fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%2 != 0 {
+ panic("invalid value length for Uniform2fv")
+ }
+ count := len(value) / 2
+ C.gl4_0compat_glUniform2fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform1fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform1fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ count := len(value)
+ C.gl4_0compat_glUniform1fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform4i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4i(location glbase.Uniform, v0, v1, v2, v3 int32) {
+ C.gl4_0compat_glUniform4i(gl.funcs, C.GLint(location), C.GLint(v0), C.GLint(v1), C.GLint(v2), C.GLint(v3))
+}
+
+// Uniform3i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform3i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3i(location glbase.Uniform, v0, v1, v2 int32) {
+ C.gl4_0compat_glUniform3i(gl.funcs, C.GLint(location), C.GLint(v0), C.GLint(v1), C.GLint(v2))
+}
+
+// Uniform2i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform2i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2i(location glbase.Uniform, v0, v1 int32) {
+ C.gl4_0compat_glUniform2i(gl.funcs, C.GLint(location), C.GLint(v0), C.GLint(v1))
+}
+
+// Uniform1i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform1i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1i(location glbase.Uniform, v0 int32) {
+ C.gl4_0compat_glUniform1i(gl.funcs, C.GLint(location), C.GLint(v0))
+}
+
+// Uniform4f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform4f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4f(location glbase.Uniform, v0, v1, v2, v3 float32) {
+ C.gl4_0compat_glUniform4f(gl.funcs, C.GLint(location), C.GLfloat(v0), C.GLfloat(v1), C.GLfloat(v2), C.GLfloat(v3))
+}
+
+// Uniform3f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform3f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3f(location glbase.Uniform, v0, v1, v2 float32) {
+ C.gl4_0compat_glUniform3f(gl.funcs, C.GLint(location), C.GLfloat(v0), C.GLfloat(v1), C.GLfloat(v2))
+}
+
+// Uniform2f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform2f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2f(location glbase.Uniform, v0, v1 float32) {
+ C.gl4_0compat_glUniform2f(gl.funcs, C.GLint(location), C.GLfloat(v0), C.GLfloat(v1))
+}
+
+// Uniform1f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform1f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1f(location glbase.Uniform, v0 float32) {
+ C.gl4_0compat_glUniform1f(gl.funcs, C.GLint(location), C.GLfloat(v0))
+}
+
+// UseProgram installs the program object specified by program as part of
+// current rendering state. One or more executables are created in a program
+// object by successfully attaching shader objects to it with AttachShader,
+// successfully compiling the shader objects with CompileShader, and
+// successfully linking the program object with LinkProgram.
+//
+// A program object will contain an executable that will run on the vertex
+// processor if it contains one or more shader objects of type
+// GL.VERTEX_SHADER that have been successfully compiled and linked.
+// Similarly, a program object will contain an executable that will run on
+// the fragment processor if it contains one or more shader objects of type
+// GL.FRAGMENT_SHADER that have been successfully compiled and linked.
+//
+// Successfully installing an executable on a programmable processor will
+// cause the corresponding fixed functionality of OpenGL to be disabled.
+// Specifically, if an executable is installed on the vertex processor, the
+// OpenGL fixed functionality will be disabled as follows.
+//
+// - The modelview matrix is not applied to vertex coordinates.
+//
+// - The projection matrix is not applied to vertex coordinates.
+//
+// - The texture matrices are not applied to texture coordinates.
+//
+// - Normals are not transformed to eye coordinates.
+//
+// - Normals are not rescaled or normalized.
+//
+// - Normalization of GL.AUTO_NORMAL evaluated normals is not performed.
+//
+// - Texture coordinates are not generated automatically.
+//
+// - Per-vertex lighting is not performed.
+//
+// - Color material computations are not performed.
+//
+// - Color index lighting is not performed.
+//
+// - This list also applies when setting the current raster position.
+//
+// The executable that is installed on the vertex processor is expected to
+// implement any or all of the desired functionality from the preceding list.
+// Similarly, if an executable is installed on the fragment processor, the
+// OpenGL fixed functionality will be disabled as follows.
+//
+// - Texture environment and texture functions are not applied.
+//
+// - Texture application is not applied.
+//
+// - Color sum is not applied.
+//
+// - Fog is not applied.
+//
+// Again, the fragment shader that is installed is expected to implement any
+// or all of the desired functionality from the preceding list.
+//
+// While a program object is in use, applications are free to modify attached
+// shader objects, compile attached shader objects, attach additional shader
+// objects, and detach or delete shader objects. None of these operations
+// will affect the executables that are part of the current state. However,
+// relinking the program object that is currently in use will install the
+// program object as part of the current rendering state if the link
+// operation was successful (see LinkProgram). If the program object
+// currently in use is relinked unsuccessfully, its link status will be set
+// to GL.FALSE, but the executables and associated state will remain part of
+// the current state until a subsequent call to UseProgram removes it from
+// use. After it is removed from use, it cannot be made part of current state
+// until it has been successfully relinked.
+//
+// If program contains shader objects of type GL.VERTEX_SHADER but it does
+// not contain shader objects of type GL.FRAGMENT_SHADER, an executable will
+// be installed on the vertex processor, but fixed functionality will be used
+// for fragment processing. Similarly, if program contains shader objects of
+// type GL.FRAGMENT_SHADER but it does not contain shader objects of type
+// GL.VERTEX_SHADER, an executable will be installed on the fragment
+// processor, but fixed functionality will be used for vertex processing. If
+// program is 0, the programmable processors will be disabled, and fixed
+// functionality will be used for both vertex and fragment processing.
+//
+// While a program object is in use, the state that controls the disabled
+// fixed functionality may also be updated using the normal OpenGL calls.
+//
+// Like display lists and texture objects, the name space for program objects
+// may be shared across a set of contexts, as long as the server sides of the
+// contexts share the same address space. If the name space is shared across
+// contexts, any attached objects and the data associated with those attached
+// objects are shared as well.
+//
+// Applications are responsible for providing the synchronization across API
+// calls when objects are accessed from different execution threads.
+//
+// Error GL.INVALID_VALUE is generated if program is neither 0 nor a value
+// generated by OpenGL. GL.INVALID_OPERATION is generated if program is not
+// a program object. GL.INVALID_OPERATION is generated if program could not
+// be made part of current state. GL.INVALID_OPERATION is generated if
+// UseProgram is executed between the execution of Begin and the
+// corresponding execution of End.
+//
+// UseProgram is available in GL version 2.0 or greater.
+func (gl *GL) UseProgram(program glbase.Program) {
+ C.gl4_0compat_glUseProgram(gl.funcs, C.GLuint(program))
+}
+
+// ShaderSource sets the source code in shader to the provided source code. Any source
+// code previously stored in the shader object is completely replaced.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader is not a shader
+// object. GL.INVALID_VALUE is generated if count is less than 0.
+// GL.INVALID_OPERATION is generated if ShaderSource is executed between the
+// execution of Begin and the corresponding execution of End.
+//
+// ShaderSource is available in GL version 2.0 or greater.
+func (gl *GL) ShaderSource(shader glbase.Shader, source ...string) {
+ count := len(source)
+ length := make([]int32, count)
+ source_c := make([]unsafe.Pointer, count)
+ for i, src := range source {
+ length[i] = int32(len(src))
+ if len(src) > 0 {
+ source_c[i] = *(*unsafe.Pointer)(unsafe.Pointer(&src))
+ } else {
+ source_c[i] = unsafe.Pointer(uintptr(0))
+ }
+ }
+ C.gl4_0compat_glShaderSource(gl.funcs, C.GLuint(shader), C.GLsizei(count), (**C.GLchar)(unsafe.Pointer(&source_c[0])), (*C.GLint)(unsafe.Pointer(&length[0])))
+}
+
+// LinkProgram links the program object specified by program. If any shader
+// objects of type GL.VERTEX_SHADER are attached to program, they will be
+// used to create an executable that will run on the programmable vertex
+// processor. If any shader objects of type GL.FRAGMENT_SHADER are attached
+// to program, they will be used to create an executable that will run on the
+// programmable fragment processor.
+//
+// The status of the link operation will be stored as part of the program
+// object's state. This value will be set to GL.TRUE if the program object
+// was linked without errors and is ready for use, and GL.FALSE otherwise. It
+// can be queried by calling GetProgramiv with arguments program and
+// GL.LINK_STATUS.
+//
+// As a result of a successful link operation, all active user-defined
+// uniform variables belonging to program will be initialized to 0, and each
+// of the program object's active uniform variables will be assigned a
+// location that can be queried by calling GetUniformLocation. Also, any
+// active user-defined attribute variables that have not been bound to a
+// generic vertex attribute index will be bound to one at this time.
+//
+// Linking of a program object can fail for a number of reasons as specified
+// in the OpenGL Shading Language Specification. The following lists some of
+// the conditions that will cause a link error.
+//
+// - The number of active attribute variables supported by the
+// implementation has been exceeded.
+//
+// - The storage limit for uniform variables has been exceeded.
+//
+// - The number of active uniform variables supported by the implementation
+// has been exceeded.
+//
+// - The main function is missing for the vertex shader or the fragment
+// shader.
+//
+// - A varying variable actually used in the fragment shader is not
+// declared in the same way (or is not declared at all) in the vertex
+// shader.
+//
+// - A reference to a function or variable name is unresolved.
+//
+// - A shared global is declared with two different types or two different
+// initial values.
+//
+// - One or more of the attached shader objects has not been successfully
+// compiled.
+//
+// - Binding a generic attribute matrix caused some rows of the matrix to
+// fall outside the allowed maximum of GL.MAX_VERTEX_ATTRIBS.
+//
+// - Not enough contiguous vertex attribute slots could be found to bind
+// attribute matrices.
+//
+// When a program object has been successfully linked, the program object can
+// be made part of current state by calling UseProgram. Whether or not the
+// link operation was successful, the program object's information log will
+// be overwritten. The information log can be retrieved by calling
+// GetProgramInfoLog.
+//
+// LinkProgram will also install the generated executables as part of the
+// current rendering state if the link operation was successful and the
+// specified program object is already currently in use as a result of a
+// previous call to UseProgram. If the program object currently in use is
+// relinked unsuccessfully, its link status will be set to GL.FALSE , but the
+// executables and associated state will remain part of the current state
+// until a subsequent call to UseProgram removes it from use. After it is
+// removed from use, it cannot be made part of current state until it has
+// been successfully relinked.
+//
+// If program contains shader objects of type GL.VERTEX_SHADER but does not
+// contain shader objects of type GL.FRAGMENT_SHADER, the vertex shader will
+// be linked against the implicit interface for fixed functionality fragment
+// processing. Similarly, if program contains shader objects of type
+// GL.FRAGMENT_SHADER but it does not contain shader objects of type
+// GL.VERTEX_SHADER, the fragment shader will be linked against the implicit
+// interface for fixed functionality vertex processing.
+//
+// The program object's information log is updated and the program is
+// generated at the time of the link operation. After the link operation,
+// applications are free to modify attached shader objects, compile attached
+// shader objects, detach shader objects, delete shader objects, and attach
+// additional shader objects. None of these operations affects the
+// information log or the program that is part of the program object.
+//
+// If the link operation is unsuccessful, any information about a previous
+// link operation on program is lost (a failed link does not restore the
+// old state of program). Certain information can still be retrieved
+// from program even after an unsuccessful link operation. See for instance
+// GetActiveAttrib and GetActiveUniform.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program
+// object. GL.INVALID_OPERATION is generated if LinkProgram is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// LinkProgram is available in GL version 2.0 or greater.
+func (gl *GL) LinkProgram(program glbase.Program) {
+ C.gl4_0compat_glLinkProgram(gl.funcs, C.GLuint(program))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsShader.xml
+func (gl *GL) IsShader(shader glbase.Shader) bool {
+ glresult := C.gl4_0compat_glIsShader(gl.funcs, C.GLuint(shader))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsProgram.xml
+func (gl *GL) IsProgram(program glbase.Program) bool {
+ glresult := C.gl4_0compat_glIsProgram(gl.funcs, C.GLuint(program))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// GetVertexAttribiv returns in params the value of a generic vertex attribute
+// parameter. The generic vertex attribute to be queried is specified by
+// index, and the parameter to be queried is specified by pname.
+//
+// The accepted parameter names are as follows:
+//
+// GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING
+// params returns a single value, the name of the buffer object
+// currently bound to the binding point corresponding to generic vertex
+// attribute array index. If no buffer object is bound, 0 is returned.
+// The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_ENABLED
+// params returns a single value that is non-zero (true) if the vertex
+// attribute array for index is enabled and 0 (false) if it is
+// disabled. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_SIZE
+// params returns a single value, the size of the vertex attribute
+// array for index. The size is the number of values for each element
+// of the vertex attribute array, and it will be 1, 2, 3, or 4. The
+// initial value is 4.
+//
+// GL.VERTEX_ATTRIB_ARRAY_STRIDE
+// params returns a single value, the array stride for (number of bytes
+// between successive elements in) the vertex attribute array for
+// index. A value of 0 indicates that the array elements are stored
+// sequentially in memory. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_TYPE
+// params returns a single value, a symbolic constant indicating the
+// array type for the vertex attribute array for index. Possible values
+// are GL.BYTE, GL.UNSIGNED_BYTE, GL.SHORT, GL.UNSIGNED_SHORT, GL.INT,
+// GL.UNSIGNED_INT, GL.FLOAT, and GL.DOUBLE. The initial value is
+// GL.FLOAT.
+//
+// GL.VERTEX_ATTRIB_ARRAY_NORMALIZED
+// params returns a single value that is non-zero (true) if fixed-point
+// data types for the vertex attribute array indicated by index are
+// normalized when they are converted to floating point, and 0 (false)
+// otherwise. The initial value is 0.
+//
+// GL.CURRENT_VERTEX_ATTRIB
+// params returns four values that represent the current value for the
+// generic vertex attribute specified by index. Generic vertex
+// attribute 0 is unique in that it has no current state, so an error
+// will be generated if index is 0. The initial value for all other
+// generic vertex attributes is (0,0,0,1).
+//
+// All of the parameters except GL.CURRENT_VERTEX_ATTRIB represent
+// client-side state.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_ENUM is generated if pname is not an
+// accepted value. GL.INVALID_OPERATION is generated if index is 0 and pname
+// is GL.CURRENT_VERTEX_ATTRIB.
+//
+// GetVertexAttribiv is available in GL version 2.0 or greater.
+func (gl *GL) GetVertexAttribiv(index glbase.Attrib, pname glbase.Enum, params []int32) {
+ var params_c [4]int32
+ C.gl4_0compat_glGetVertexAttribiv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetVertexAttribfv returns in params the value of a generic vertex attribute
+// parameter. The generic vertex attribute to be queried is specified by
+// index, and the parameter to be queried is specified by pname.
+//
+// The accepted parameter names are as follows:
+//
+// GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING
+// params returns a single value, the name of the buffer object
+// currently bound to the binding point corresponding to generic vertex
+// attribute array index. If no buffer object is bound, 0 is returned.
+// The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_ENABLED
+// params returns a single value that is non-zero (true) if the vertex
+// attribute array for index is enabled and 0 (false) if it is
+// disabled. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_SIZE
+// params returns a single value, the size of the vertex attribute
+// array for index. The size is the number of values for each element
+// of the vertex attribute array, and it will be 1, 2, 3, or 4. The
+// initial value is 4.
+//
+// GL.VERTEX_ATTRIB_ARRAY_STRIDE
+// params returns a single value, the array stride for (number of bytes
+// between successive elements in) the vertex attribute array for
+// index. A value of 0 indicates that the array elements are stored
+// sequentially in memory. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_TYPE
+// params returns a single value, a symbolic constant indicating the
+// array type for the vertex attribute array for index. Possible values
+// are GL.BYTE, GL.UNSIGNED_BYTE, GL.SHORT, GL.UNSIGNED_SHORT, GL.INT,
+// GL.UNSIGNED_INT, GL.FLOAT, and GL.DOUBLE. The initial value is
+// GL.FLOAT.
+//
+// GL.VERTEX_ATTRIB_ARRAY_NORMALIZED
+// params returns a single value that is non-zero (true) if fixed-point
+// data types for the vertex attribute array indicated by index are
+// normalized when they are converted to floating point, and 0 (false)
+// otherwise. The initial value is 0.
+//
+// GL.CURRENT_VERTEX_ATTRIB
+// params returns four values that represent the current value for the
+// generic vertex attribute specified by index. Generic vertex
+// attribute 0 is unique in that it has no current state, so an error
+// will be generated if index is 0. The initial value for all other
+// generic vertex attributes is (0,0,0,1).
+//
+// All of the parameters except GL.CURRENT_VERTEX_ATTRIB represent
+// client-side state.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_ENUM is generated if pname is not an
+// accepted value. GL.INVALID_OPERATION is generated if index is 0 and pname
+// is GL.CURRENT_VERTEX_ATTRIB.
+//
+// GetVertexAttribfv is available in GL version 2.0 or greater.
+func (gl *GL) GetVertexAttribfv(index glbase.Attrib, pname glbase.Enum, params []float32) {
+ var params_c [4]float32
+ C.gl4_0compat_glGetVertexAttribfv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetVertexAttribdv returns in params the value of a generic vertex attribute
+// parameter. The generic vertex attribute to be queried is specified by
+// index, and the parameter to be queried is specified by pname.
+//
+// The accepted parameter names are as follows:
+//
+// GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING
+// params returns a single value, the name of the buffer object
+// currently bound to the binding point corresponding to generic vertex
+// attribute array index. If no buffer object is bound, 0 is returned.
+// The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_ENABLED
+// params returns a single value that is non-zero (true) if the vertex
+// attribute array for index is enabled and 0 (false) if it is
+// disabled. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_SIZE
+// params returns a single value, the size of the vertex attribute
+// array for index. The size is the number of values for each element
+// of the vertex attribute array, and it will be 1, 2, 3, or 4. The
+// initial value is 4.
+//
+// GL.VERTEX_ATTRIB_ARRAY_STRIDE
+// params returns a single value, the array stride for (number of bytes
+// between successive elements in) the vertex attribute array for
+// index. A value of 0 indicates that the array elements are stored
+// sequentially in memory. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_TYPE
+// params returns a single value, a symbolic constant indicating the
+// array type for the vertex attribute array for index. Possible values
+// are GL.BYTE, GL.UNSIGNED_BYTE, GL.SHORT, GL.UNSIGNED_SHORT, GL.INT,
+// GL.UNSIGNED_INT, GL.FLOAT, and GL.DOUBLE. The initial value is
+// GL.FLOAT.
+//
+// GL.VERTEX_ATTRIB_ARRAY_NORMALIZED
+// params returns a single value that is non-zero (true) if fixed-point
+// data types for the vertex attribute array indicated by index are
+// normalized when they are converted to floating point, and 0 (false)
+// otherwise. The initial value is 0.
+//
+// GL.CURRENT_VERTEX_ATTRIB
+// params returns four values that represent the current value for the
+// generic vertex attribute specified by index. Generic vertex
+// attribute 0 is unique in that it has no current state, so an error
+// will be generated if index is 0. The initial value for all other
+// generic vertex attributes is (0,0,0,1).
+//
+// All of the parameters except GL.CURRENT_VERTEX_ATTRIB represent
+// client-side state.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_ENUM is generated if pname is not an
+// accepted value. GL.INVALID_OPERATION is generated if index is 0 and pname
+// is GL.CURRENT_VERTEX_ATTRIB.
+//
+// GetVertexAttribdv is available in GL version 2.0 or greater.
+func (gl *GL) GetVertexAttribdv(index glbase.Attrib, pname glbase.Enum, params []float64) {
+ var params_c [4]float64
+ C.gl4_0compat_glGetVertexAttribdv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetUniformiv returns in params the value of the specified uniform
+// variable. The type of the uniform variable specified by location
+// determines the number of values returned. If the uniform variable is
+// defined in the shader as a boolean, int, or float, a single value will be
+// returned. If it is defined as a vec2, ivec2, or bvec2, two values will be
+// returned. If it is defined as a vec3, ivec3, or bvec3, three values will
+// be returned, and so on. To query values stored in uniform variables
+// declared as arrays, call GetUniformiv for each element of the array. To
+// query values stored in uniform variables declared as structures, call
+// GetUniformiv for each field in the structure. The values for uniform
+// variables declared as a matrix will be returned in column major order.
+//
+// The locations assigned to uniform variables are not known until the
+// program object is linked. After linking has occurred, the command
+// GetUniformLocation can be used to obtain the location of a uniform
+// variable. This location value can then be passed to GetUniformiv in order
+// to query the current value of the uniform variable. After a program object
+// has been linked successfully, the index values for uniform variables
+// remain fixed until the next link command occurs. The uniform variable
+// values can only be queried after a link if the link was successful.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program
+// object. GL.INVALID_OPERATION is generated if program has not been
+// successfully linked. GL.INVALID_OPERATION is generated if location does
+// not correspond to a valid uniform variable location for the specified
+// program object. GL.INVALID_OPERATION is generated if GetUniformiv is
+// executed between the execution of Begin and the corresponding execution of
+// End.
+//
+// GetUniformiv is available in GL version 2.0 or greater.
+func (gl *GL) GetUniformiv(program glbase.Program, location glbase.Uniform, params []int32) {
+ var params_c [4]int32
+ C.gl4_0compat_glGetUniformiv(gl.funcs, C.GLuint(program), C.GLint(location), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetUniformfv returns in params the value of the specified uniform
+// variable. The type of the uniform variable specified by location
+// determines the number of values returned. If the uniform variable is
+// defined in the shader as a boolean, int, or float, a single value will be
+// returned. If it is defined as a vec2, ivec2, or bvec2, two values will be
+// returned. If it is defined as a vec3, ivec3, or bvec3, three values will
+// be returned, and so on. To query values stored in uniform variables
+// declared as arrays, call GetUniformfv for each element of the array. To
+// query values stored in uniform variables declared as structures, call
+// GetUniformfv for each field in the structure. The values for uniform
+// variables declared as a matrix will be returned in column major order.
+//
+// The locations assigned to uniform variables are not known until the
+// program object is linked. After linking has occurred, the command
+// GetUniformLocation can be used to obtain the location of a uniform
+// variable. This location value can then be passed to GetUniformfv in order
+// to query the current value of the uniform variable. After a program object
+// has been linked successfully, the index values for uniform variables
+// remain fixed until the next link command occurs. The uniform variable
+// values can only be queried after a link if the link was successful.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program
+// object. GL.INVALID_OPERATION is generated if program has not been
+// successfully linked. GL.INVALID_OPERATION is generated if location does
+// not correspond to a valid uniform variable location for the specified
+// program object. GL.INVALID_OPERATION is generated if GetUniformfv is
+// executed between the execution of Begin and the corresponding execution of
+// End.
+//
+// GetUniformfv is available in GL version 2.0 or greater.
+func (gl *GL) GetUniformfv(program glbase.Program, location glbase.Uniform, params []float32) {
+ var params_c [4]float32
+ C.gl4_0compat_glGetUniformfv(gl.funcs, C.GLuint(program), C.GLint(location), (*C.GLfloat)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetUniformLocation returns an integer that represents the location of a
+// specific uniform variable within a program object. name must be an active
+// uniform variable name in program that is not a structure, an array of
+// structures, or a subcomponent of a vector or a matrix. This function
+// returns -1 if name does not correspond to an active uniform variable in
+// program or if name starts with the reserved prefix "gl_".
+//
+// Uniform variables that are structures or arrays of structures may be
+// queried by calling GetUniformLocation for each field within the
+// structure. The array element operator "[]" and the structure field
+// operator "." may be used in name in order to select elements within an
+// array or fields within a structure. The result of using these operators is
+// not allowed to be another structure, an array of structures, or a
+// subcomponent of a vector or a matrix. Except if the last part of name
+// indicates a uniform variable array, the location of the first element of
+// an array can be retrieved by using the name of the array, or by using the
+// name appended by "[0]".
+//
+// The actual locations assigned to uniform variables are not known until the
+// program object is linked successfully. After linking has occurred, the
+// command GetUniformLocation can be used to obtain the location of a
+// uniform variable. This location value can then be passed to Uniform to
+// set the value of the uniform variable or to GetUniform in order to query
+// the current value of the uniform variable. After a program object has been
+// linked successfully, the index values for uniform variables remain fixed
+// until the next link command occurs. Uniform variable locations and values
+// can only be queried after a link if the link was successful.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program object.
+// GL.INVALID_OPERATION is generated if program has not been successfully
+// linked. GL.INVALID_OPERATION is generated if GetUniformLocation is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// GetUniformLocation is available in GL version 2.0 or greater.
+func (gl *GL) GetUniformLocation(program glbase.Program, name string) glbase.Uniform {
+ name_cstr := C.CString(name)
+ glresult := C.gl4_0compat_glGetUniformLocation(gl.funcs, C.GLuint(program), (*C.GLchar)(name_cstr))
+ C.free(unsafe.Pointer(name_cstr))
+ return glbase.Uniform(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetShaderSource.xml
+func (gl *GL) GetShaderSource(shader glbase.Shader, bufSize int32, length []int32, source []byte) {
+ C.gl4_0compat_glGetShaderSource(gl.funcs, C.GLuint(shader), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&source[0])))
+}
+
+// GetShaderInfoLog returns the information log for the specified shader
+// object. The information log for a shader object is modified when the
+// shader is compiled.
+//
+// The information log for a shader object is a string that may contain
+// diagnostic messages, warning messages, and other information about the
+// last compile operation. When a shader object is created, its information
+// log will be a string of length 0, and the size of the current log can be
+// obtained by calling GetShaderiv with the value GL.INFO_LOG_LENGTH.
+//
+// The information log for a shader object is the OpenGL implementer's
+// primary mechanism for conveying information about the compilation process.
+// Therefore, the information log can be helpful to application developers
+// during the development process, even when compilation is successful.
+// Application developers should not expect different OpenGL implementations
+// to produce identical information logs.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader is not a shader
+// object. GL.INVALID_VALUE is generated if maxLength is less than 0.
+// GL.INVALID_OPERATION is generated if GetShaderInfoLog is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// GetShaderInfoLog is available in GL version 2.0 or greater.
+func (gl *GL) GetShaderInfoLog(shader glbase.Shader) []byte {
+ var params [1]int32
+ var length int32
+ gl.GetShaderiv(shader, INFO_LOG_LENGTH, params[:])
+ bufSize := params[0]
+ infoLog := make([]byte, int(bufSize))
+ C.gl4_0compat_glGetShaderInfoLog(gl.funcs, C.GLuint(shader), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length)), (*C.GLchar)(unsafe.Pointer(&infoLog[0])))
+ return infoLog
+}
+
+// GetShaderiv GetShader returns in params the value of a parameter for a specific
+// shader object. The following parameters are defined:
+//
+// GL.SHADER_TYPE
+// params returns GL.VERTEX_SHADER if shader is a vertex shader object,
+// and GL.FRAGMENT_SHADER if shader is a fragment shader object.
+//
+// GL.DELETE_STATUS
+// params returns GL.TRUE if shader is currently flagged for deletion,
+// and GL.FALSE otherwise.
+//
+// GL.COMPILE_STATUS
+// params returns GL.TRUE if the last compile operation on shader was
+// successful, and GL.FALSE otherwise.
+//
+// GL.INFO_LOG_LENGTH
+// params returns the number of characters in the information log for
+// shader including the null termination character (the size of the
+// character buffer required to store the information log). If shader has
+// no information log, a value of 0 is returned.
+//
+// GL.SHADER_SOURCE_LENGTH
+// params returns the length of the concatenation of the source strings
+// that make up the shader source for the shader, including the null
+// termination character. (the size of the character buffer
+// required to store the shader source). If no source code exists, 0 is
+// returned.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader does not refer to a
+// shader object. GL.INVALID_ENUM is generated if pname is not an accepted
+// value. GL.INVALID_OPERATION is generated if GetShader is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// GetShaderiv is available in GL version 2.0 or greater.
+func (gl *GL) GetShaderiv(shader glbase.Shader, pname glbase.Enum, params []int32) {
+ var params_c [4]int32
+ C.gl4_0compat_glGetShaderiv(gl.funcs, C.GLuint(shader), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetProgramInfoLog returns the information log for the specified program
+// object. The information log for a program object is modified when the
+// program object is linked or validated.
+//
+// The information log for a program object is either an empty string, or a
+// string containing information about the last link operation, or a string
+// containing information about the last validation operation. It may contain
+// diagnostic messages, warning messages, and other information. When a
+// program object is created, its information log will be a string of length
+// 0, and the size of the current log can be obtained by calling GetProgramiv
+// with the value GL.INFO_LOG_LENGTH.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated
+// by OpenGL. GL.INVALID_OPERATION is generated if program is not a
+// program object.
+func (gl *GL) GetProgramInfoLog(program glbase.Program) []byte {
+ var params [1]int32
+ var length int32
+ gl.GetProgramiv(program, INFO_LOG_LENGTH, params[:])
+ bufSize := params[0]
+ infoLog := make([]byte, int(bufSize))
+ C.gl4_0compat_glGetProgramInfoLog(gl.funcs, C.GLuint(program), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length)), (*C.GLchar)(unsafe.Pointer(&infoLog[0])))
+ return infoLog
+}
+
+// GetProgramiv returns in params the value of a parameter for a specific
+// program object. The following parameters are defined:
+//
+// GL.DELETE_STATUS
+// params returns GL.TRUE if program is currently flagged for deletion,
+// and GL.FALSE otherwise.
+//
+// GL.LINK_STATUS
+// params returns GL.TRUE if the last link operation on program was
+// successful, and GL.FALSE otherwise.
+//
+// GL.VALIDATE_STATUS
+// params returns GL.TRUE or if the last validation operation on
+// program was successful, and GL.FALSE otherwise.
+//
+// GL.INFO_LOG_LENGTH
+// params returns the number of characters in the information log for
+// program including the null termination character (the size of
+// the character buffer required to store the information log). If
+// program has no information log, a value of 0 is returned.
+//
+// GL.ATTACHED_SHADERS
+// params returns the number of shader objects attached to program.
+//
+// GL.ACTIVE_ATTRIBUTES
+// params returns the number of active attribute variables for program.
+//
+// GL.ACTIVE_ATTRIBUTE_MAX_LENGTH
+// params returns the length of the longest active attribute name for
+// program, including the null termination character (the size of
+// the character buffer required to store the longest attribute name).
+// If no active attributes exist, 0 is returned.
+//
+// GL.ACTIVE_UNIFORMS
+// params returns the number of active uniform variables for program.
+//
+// GL.ACTIVE_UNIFORM_MAX_LENGTH
+// params returns the length of the longest active uniform variable
+// name for program, including the null termination character (i.e.,
+// the size of the character buffer required to store the longest
+// uniform variable name). If no active uniform variables exist, 0 is
+// returned.
+//
+// GL.TRANSFORM_FEEDBACK_BUFFER_MODE
+// params returns a symbolic constant indicating the buffer mode used
+// when transform feedback is active. This may be GL.SEPARATE_ATTRIBS
+// or GL.INTERLEAVED_ATTRIBS.
+//
+// GL.TRANSFORM_FEEDBACK_VARYINGS
+// params returns the number of varying variables to capture in transform
+// feedback mode for the program.
+//
+// GL.TRANSFORM_FEEDBACK_VARYING_MAX_LENGTH
+// params returns the length of the longest variable name to be used for
+// transform feedback, including the null-terminator.
+//
+// GL.GEOMETRY_VERTICES_OUT
+// params returns the maximum number of vertices that the geometry shader in
+// program will output.
+//
+// GL.GEOMETRY_INPUT_TYPE
+// params returns a symbolic constant indicating the primitive type accepted
+// as input to the geometry shader contained in program.
+//
+// GL.GEOMETRY_OUTPUT_TYPE
+// params returns a symbolic constant indicating the primitive type that will
+// be output by the geometry shader contained in program.
+//
+// GL.ACTIVE_UNIFORM_BLOCKS and GL.ACTIVE_UNIFORM_BLOCK_MAX_NAME_LENGTH are
+// available only if the GL version 3.1 or greater.
+//
+// GL.GEOMETRY_VERTICES_OUT, GL.GEOMETRY_INPUT_TYPE and
+// GL.GEOMETRY_OUTPUT_TYPE are accepted only if the GL version is 3.2 or
+// greater.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program does not refer to a
+// program object. GL.INVALID_OPERATION is generated if pname is
+// GL.GEOMETRY_VERTICES_OUT, GL.GEOMETRY_INPUT_TYPE, or
+// GL.GEOMETRY_OUTPUT_TYPE, and program does not contain a geometry shader.
+// GL.INVALID_ENUM is generated if pname is not an accepted value.
+func (gl *GL) GetProgramiv(program glbase.Program, pname glbase.Enum, params []int32) {
+ var params_c [4]int32
+ C.gl4_0compat_glGetProgramiv(gl.funcs, C.GLuint(program), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetAttribLocation queries the previously linked program object specified
+// by program for the attribute variable specified by name and returns the
+// index of the generic vertex attribute that is bound to that attribute
+// variable. If name is a matrix attribute variable, the index of the first
+// column of the matrix is returned. If the named attribute variable is not
+// an active attribute in the specified program object or if name starts with
+// the reserved prefix "gl_", a value of -1 is returned.
+//
+// The association between an attribute variable name and a generic attribute
+// index can be specified at any time by calling BindAttribLocation.
+// Attribute bindings do not go into effect until LinkProgram is called.
+// After a program object has been linked successfully, the index values for
+// attribute variables remain fixed until the next link command occurs. The
+// attribute values can only be queried after a link if the link was
+// successful. GetAttribLocation returns the binding that actually went
+// into effect the last time LinkProgram was called for the specified
+// program object. Attribute bindings that have been specified since the last
+// link operation are not returned by GetAttribLocation.
+//
+// Error GL_INVALID_OPERATION is generated if program is not a value
+// generated by OpenGL. GL_INVALID_OPERATION is generated if program is not
+// a program object. GL_INVALID_OPERATION is generated if program has not
+// been successfully linked. GL_INVALID_OPERATION is generated if
+// GetAttribLocation is executed between the execution of Begin and the
+// corresponding execution of End.
+//
+// GetAttribLocation is available in GL version 2.0 or greater.
+func (gl *GL) GetAttribLocation(program glbase.Program, name string) glbase.Attrib {
+ name_cstr := C.CString(name)
+ glresult := C.gl4_0compat_glGetAttribLocation(gl.funcs, C.GLuint(program), (*C.GLchar)(name_cstr))
+ C.free(unsafe.Pointer(name_cstr))
+ return glbase.Attrib(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetAttachedShaders.xml
+func (gl *GL) GetAttachedShaders(program glbase.Program, maxCount int32, count []int, obj []uint32) {
+ C.gl4_0compat_glGetAttachedShaders(gl.funcs, C.GLuint(program), C.GLsizei(maxCount), (*C.GLsizei)(unsafe.Pointer(&count[0])), (*C.GLuint)(unsafe.Pointer(&obj[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveUniform.xml
+func (gl *GL) GetActiveUniform(program glbase.Program, index uint32, bufSize int32, length []int32, size []int, gltype []glbase.Enum, name []byte) {
+ C.gl4_0compat_glGetActiveUniform(gl.funcs, C.GLuint(program), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLint)(unsafe.Pointer(&size[0])), (*C.GLenum)(unsafe.Pointer(&gltype[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveAttrib.xml
+func (gl *GL) GetActiveAttrib(program glbase.Program, index glbase.Attrib, bufSize int32, length []int32, size []int, gltype []glbase.Enum, name []byte) {
+ C.gl4_0compat_glGetActiveAttrib(gl.funcs, C.GLuint(program), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLint)(unsafe.Pointer(&size[0])), (*C.GLenum)(unsafe.Pointer(&gltype[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEnableVertexAttribArray.xml
+func (gl *GL) EnableVertexAttribArray(index glbase.Attrib) {
+ C.gl4_0compat_glEnableVertexAttribArray(gl.funcs, C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDisableVertexAttribArray.xml
+func (gl *GL) DisableVertexAttribArray(index glbase.Attrib) {
+ C.gl4_0compat_glDisableVertexAttribArray(gl.funcs, C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDetachShader.xml
+func (gl *GL) DetachShader(program glbase.Program, shader glbase.Shader) {
+ C.gl4_0compat_glDetachShader(gl.funcs, C.GLuint(program), C.GLuint(shader))
+}
+
+// DeleteShader frees the memory and invalidates the name associated with
+// the shader object specified by shader. This command effectively undoes the
+// effects of a call to CreateShader.
+//
+// If a shader object to be deleted is attached to a program object, it will
+// be flagged for deletion, but it will not be deleted until it is no longer
+// attached to any program object, for any rendering context (it must
+// be detached from wherever it was attached before it will be deleted). A
+// value of 0 for shader will be silently ignored.
+//
+// To determine whether an object has been flagged for deletion, call
+// GetShader with arguments shader and GL.DELETE_STATUS.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL.
+//
+// DeleteShader is available in GL version 2.0 or greater.
+func (gl *GL) DeleteShader(shader glbase.Shader) {
+ C.gl4_0compat_glDeleteShader(gl.funcs, C.GLuint(shader))
+}
+
+// DeleteProgram frees the memory and invalidates the name associated with
+// the program object specified by program. This command effectively undoes
+// the effects of a call to CreateProgram.
+//
+// If a program object is in use as part of current rendering state, it will
+// be flagged for deletion, but it will not be deleted until it is no longer
+// part of current state for any rendering context. If a program object to be
+// deleted has shader objects attached to it, those shader objects will be
+// automatically detached but not deleted unless they have already been
+// flagged for deletion by a previous call to DeleteShader. A value of 0
+// for program will be silently ignored.
+//
+// To determine whether a program object has been flagged for deletion, call
+// GetProgram with arguments program and GL.DELETE_STATUS.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL.
+//
+// DeleteProgram is available in GL version 2.0 or greater.
+func (gl *GL) DeleteProgram(program glbase.Program) {
+ C.gl4_0compat_glDeleteProgram(gl.funcs, C.GLuint(program))
+}
+
+// CreateShader creates an empty shader object and returns a non-zero value
+// by which it can be referenced. A shader object is used to maintain the
+// source code strings that define a shader. shaderType indicates the type of
+// shader to be created.
+//
+// Two types of shaders are supported. A shader of type GL.VERTEX_SHADER is a
+// shader that is intended to run on the programmable vertex processor and
+// replace the fixed functionality vertex processing in OpenGL. A shader of
+// type GL.FRAGMENT_SHADER is a shader that is intended to run on the
+// programmable fragment processor and replace the fixed functionality
+// fragment processing in OpenGL.
+//
+// When created, a shader object's GL.SHADER_TYPE parameter is set to either
+// GL.VERTEX_SHADER or GL.FRAGMENT_SHADER, depending on the value of
+// shaderType.
+//
+// Like display lists and texture objects, the name space for shader objects
+// may be shared across a set of contexts, as long as the server sides of the
+// contexts share the same address space. If the name space is shared across
+// contexts, any attached objects and the data associated with those attached
+// objects are shared as well.
+//
+// This function returns 0 if an error occurs creating the shader object.
+//
+// Error GL.INVALID_ENUM is generated if shaderType is not an accepted value.
+// GL.INVALID_OPERATION is generated if CreateShader is executed between the
+// execution of Begin and the corresponding execution of End.
+//
+// CreateShader is available in GL version 2.0 or greater.
+func (gl *GL) CreateShader(gltype glbase.Enum) glbase.Shader {
+ glresult := C.gl4_0compat_glCreateShader(gl.funcs, C.GLenum(gltype))
+ return glbase.Shader(glresult)
+}
+
+// CreateProgram creates an empty program object and returns a non-zero
+// value by which it can be referenced. A program object is an object to
+// which shader objects can be attached. This provides a mechanism to specify
+// the shader objects that will be linked to create a program. It also
+// provides a means for checking the compatibility of the shaders that will
+// be used to create a program (for instance, checking the compatibility
+// between a vertex shader and a fragment shader). When no longer needed as
+// part of a program object, shader objects can be detached.
+//
+// One or more executables are created in a program object by successfully
+// attaching shader objects to it with AttachShader, successfully compiling
+// the shader objects with CompileShader, and successfully linking the
+// program object with LinkProgram. These executables are made part of
+// current state when UseProgram is called. Program objects can be deleted
+// by calling DeleteProgram. The memory associated with the program object
+// will be deleted when it is no longer part of current rendering state for
+// any context.
+//
+// Like display lists and texture objects, the name space for program objects
+// may be shared across a set of contexts, as long as the server sides of the
+// contexts share the same address space. If the name space is shared across
+// contexts, any attached objects and the data associated with those attached
+// objects are shared as well.
+//
+// Applications are responsible for providing the synchronization across API
+// calls when objects are accessed from different execution threads.
+//
+// This function returns 0 if an error occurs creating the program object.
+//
+// Error GL.INVALID_OPERATION is generated if CreateProgram is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// CreateProgram is available in GL version 2.0 or greater.
+func (gl *GL) CreateProgram() glbase.Program {
+ glresult := C.gl4_0compat_glCreateProgram(gl.funcs)
+ return glbase.Program(glresult)
+}
+
+// CompileShader compiles the source code strings that have been stored in
+// the shader object specified by shader.
+//
+// The compilation status will be stored as part of the shader object's
+// state. This value will be set to GL.TRUE if the shader was compiled without
+// errors and is ready for use, and GL.FALSE otherwise. It can be queried by
+// calling GetShaderiv with arguments shader and GL.COMPILE_STATUS.
+//
+// Compilation of a shader can fail for a number of reasons as specified by
+// the OpenGL Shading Language Specification. Whether or not the compilation
+// was successful, information about the compilation can be obtained from the
+// shader object's information log by calling GetShaderInfoLog.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader is not a shader
+// object. GL.INVALID_OPERATION is generated if CompileShader is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// CompileShader is available in GL version 2.0 or greater.
+func (gl *GL) CompileShader(shader glbase.Shader) {
+ C.gl4_0compat_glCompileShader(gl.funcs, C.GLuint(shader))
+}
+
+// BindAttribLocation associates a user-defined attribute variable in the program
+// object specified by program with a generic vertex attribute index. The name
+// parameter specifies the name of the vertex shader attribute variable to
+// which index is to be bound. When program is made part of the current state,
+// values provided via the generic vertex attribute index will modify the
+// value of the user-defined attribute variable specified by name.
+//
+// If name refers to a matrix attribute variable, index refers to the first
+// column of the matrix. Other matrix columns are then automatically bound to
+// locations index+1 for a matrix of type mat2; index+1 and index+2 for a
+// matrix of type mat3; and index+1, index+2, and index+3 for a matrix of
+// type mat4.
+//
+// This command makes it possible for vertex shaders to use descriptive names
+// for attribute variables rather than generic variables that are numbered
+// from 0 to GL.MAX_VERTEX_ATTRIBS-1. The values sent to each generic
+// attribute index are part of current state, just like standard vertex
+// attributes such as color, normal, and vertex position. If a different
+// program object is made current by calling UseProgram, the generic vertex
+// attributes are tracked in such a way that the same values will be observed
+// by attributes in the new program object that are also bound to index.
+//
+// Attribute variable name-to-generic attribute index bindings for a program
+// object can be explicitly assigned at any time by calling
+// BindAttribLocation. Attribute bindings do not go into effect until
+// LinkProgram is called. After a program object has been linked
+// successfully, the index values for generic attributes remain fixed (and
+// their values can be queried) until the next link command occurs.
+//
+// Applications are not allowed to bind any of the standard OpenGL vertex
+// attributes using this command, as they are bound automatically when
+// needed. Any attribute binding that occurs after the program object has
+// been linked will not take effect until the next time the program object is
+// linked.
+//
+// If name was bound previously, that information is lost. Thus you cannot
+// bind one user-defined attribute variable to multiple indices, but you can
+// bind multiple user-defined attribute variables to the same index.
+//
+// Applications are allowed to bind more than one user-defined attribute
+// variable to the same generic vertex attribute index. This is called
+// aliasing, and it is allowed only if just one of the aliased attributes is
+// active in the executable program, or if no path through the shader
+// consumes more than one attribute of a set of attributes aliased to the
+// same location. The compiler and linker are allowed to assume that no
+// aliasing is done and are free to employ optimizations that work only in
+// the absence of aliasing. OpenGL implementations are not required to do
+// error checking to detect aliasing. Because there is no way to bind
+// standard attributes, it is not possible to alias generic attributes with
+// conventional ones (except for generic attribute 0).
+//
+// BindAttribLocation can be called before any vertex shader objects are
+// bound to the specified program object. It is also permissible to bind a
+// generic attribute index to an attribute variable name that is never used
+// in a vertex shader.
+//
+// Active attributes that are not explicitly bound will be bound by the
+// linker when LinkProgram is called. The locations assigned can be queried
+// by calling GetAttribLocation.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS.
+// GL.INVALID_OPERATION is generated if name starts with the reserved prefix "gl_".
+// GL.INVALID_VALUE is generated if program is not a value generated by OpenGL.
+// GL.INVALID_OPERATION is generated if program is not a program object.
+// GL.INVALID_OPERATION is generated if BindAttribLocation is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// BindAttribLocation is available in GL version 2.0 or greater.
+func (gl *GL) BindAttribLocation(program glbase.Program, index glbase.Attrib, name string) {
+ name_cstr := C.CString(name)
+ C.gl4_0compat_glBindAttribLocation(gl.funcs, C.GLuint(program), C.GLuint(index), (*C.GLchar)(name_cstr))
+ C.free(unsafe.Pointer(name_cstr))
+}
+
+// AttachShader attaches a shader object to a program object.
+//
+// In order to create an executable, there must be a way to specify the list
+// of things that will be linked together. Program objects provide this
+// mechanism. Shaders that are to be linked together in a program object must
+// first be attached to that program object. This indicates that shader will
+// be included in link operations that will be performed on program.
+//
+// All operations that can be performed on a shader object are valid whether
+// or not the shader object is attached to a program object. It is
+// permissible to attach a shader object to a program object before source
+// code has been loaded into the shader object or before the shader object
+// has been compiled. It is permissible to attach multiple shader objects of
+// the same type because each may contain a portion of the complete shader.
+// It is also permissible to attach a shader object to more than one program
+// object. If a shader object is deleted while it is attached to a program
+// object, it will be flagged for deletion, and deletion will not occur until
+// DetachShader is called to detach it from all program objects to which it
+// is attached.
+//
+// Error GL.INVALID_VALUE is generated if either program or shader is not a
+// value generated by OpenGL. GL.INVALID_OPERATION is generated if program
+// is not a program object. GL.INVALID_OPERATION is generated if shader is
+// not a shader object. GL.INVALID_OPERATION is generated if shader is
+// already attached to program. GL.INVALID_OPERATION is generated if
+// AttachShader is executed between the execution of Begin and the
+// corresponding execution of End.
+//
+// AttachShader is available in GL version 2.0 or greater.
+func (gl *GL) AttachShader(program glbase.Program, shader glbase.Shader) {
+ C.gl4_0compat_glAttachShader(gl.funcs, C.GLuint(program), C.GLuint(shader))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glStencilMaskSeparate.xml
+func (gl *GL) StencilMaskSeparate(face glbase.Enum, mask uint32) {
+ C.gl4_0compat_glStencilMaskSeparate(gl.funcs, C.GLenum(face), C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glStencilFuncSeparate.xml
+func (gl *GL) StencilFuncSeparate(face, glfunc glbase.Enum, ref int32, mask uint32) {
+ C.gl4_0compat_glStencilFuncSeparate(gl.funcs, C.GLenum(face), C.GLenum(glfunc), C.GLint(ref), C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glStencilOpSeparate.xml
+func (gl *GL) StencilOpSeparate(face, sfail, dpfail, dppass glbase.Enum) {
+ C.gl4_0compat_glStencilOpSeparate(gl.funcs, C.GLenum(face), C.GLenum(sfail), C.GLenum(dpfail), C.GLenum(dppass))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawBuffers.xml
+func (gl *GL) DrawBuffers(n int, bufs []glbase.Enum) {
+ C.gl4_0compat_glDrawBuffers(gl.funcs, C.GLsizei(n), (*C.GLenum)(unsafe.Pointer(&bufs[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendEquationSeparate.xml
+func (gl *GL) BlendEquationSeparate(modeRGB, modeAlpha glbase.Enum) {
+ C.gl4_0compat_glBlendEquationSeparate(gl.funcs, C.GLenum(modeRGB), C.GLenum(modeAlpha))
+}
+
+// UniformMatrix4x3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix4x3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix4x3fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(4*3) != 0 {
+ panic("invalid value length for UniformMatrix4x3fv")
+ }
+ count := len(value) / (4 * 3)
+ C.gl4_0compat_glUniformMatrix4x3fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix3x4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix3x4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix3x4fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(3*4) != 0 {
+ panic("invalid value length for UniformMatrix3x4fv")
+ }
+ count := len(value) / (3 * 4)
+ C.gl4_0compat_glUniformMatrix3x4fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix4x2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix4x2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix4x2fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(4*2) != 0 {
+ panic("invalid value length for UniformMatrix4x2fv")
+ }
+ count := len(value) / (4 * 2)
+ C.gl4_0compat_glUniformMatrix4x2fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix2x4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix2x4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix2x4fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(2*4) != 0 {
+ panic("invalid value length for UniformMatrix2x4fv")
+ }
+ count := len(value) / (2 * 4)
+ C.gl4_0compat_glUniformMatrix2x4fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix3x2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix3x2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix3x2fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(3*2) != 0 {
+ panic("invalid value length for UniformMatrix3x2fv")
+ }
+ count := len(value) / (3 * 2)
+ C.gl4_0compat_glUniformMatrix3x2fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix2x3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix2x3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix2x3fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(2*3) != 0 {
+ panic("invalid value length for UniformMatrix2x3fv")
+ }
+ count := len(value) / (2 * 3)
+ C.gl4_0compat_glUniformMatrix2x3fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsVertexArray.xml
+func (gl *GL) IsVertexArray(array uint32) bool {
+ glresult := C.gl4_0compat_glIsVertexArray(gl.funcs, C.GLuint(array))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGenVertexArrays.xml
+func (gl *GL) GenVertexArrays(n int, arrays []uint32) {
+ C.gl4_0compat_glGenVertexArrays(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&arrays[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDeleteVertexArrays.xml
+func (gl *GL) DeleteVertexArrays(n int, arrays []uint32) {
+ C.gl4_0compat_glDeleteVertexArrays(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&arrays[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindVertexArray.xml
+func (gl *GL) BindVertexArray(array uint32) {
+ C.gl4_0compat_glBindVertexArray(gl.funcs, C.GLuint(array))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFlushMappedBufferRange.xml
+func (gl *GL) FlushMappedBufferRange(target glbase.Enum, offset, length int) {
+ C.gl4_0compat_glFlushMappedBufferRange(gl.funcs, C.GLenum(target), C.GLintptr(offset), C.GLsizeiptr(length))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFramebufferTextureLayer.xml
+func (gl *GL) FramebufferTextureLayer(target, attachment glbase.Enum, texture glbase.Texture, level int, layer int32) {
+ C.gl4_0compat_glFramebufferTextureLayer(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLuint(texture), C.GLint(level), C.GLint(layer))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRenderbufferStorageMultisample.xml
+func (gl *GL) RenderbufferStorageMultisample(target glbase.Enum, samples int32, internalFormat glbase.Enum, width, height int) {
+ C.gl4_0compat_glRenderbufferStorageMultisample(gl.funcs, C.GLenum(target), C.GLsizei(samples), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlitFramebuffer.xml
+func (gl *GL) BlitFramebuffer(srcX0, srcY0, srcX1, srcY1, dstX0, dstY0, dstX1, dstY1 int32, mask glbase.Bitfield, filter glbase.Enum) {
+ C.gl4_0compat_glBlitFramebuffer(gl.funcs, C.GLint(srcX0), C.GLint(srcY0), C.GLint(srcX1), C.GLint(srcY1), C.GLint(dstX0), C.GLint(dstY0), C.GLint(dstX1), C.GLint(dstY1), C.GLbitfield(mask), C.GLenum(filter))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGenerateMipmap.xml
+func (gl *GL) GenerateMipmap(target glbase.Enum) {
+ C.gl4_0compat_glGenerateMipmap(gl.funcs, C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetFramebufferAttachmentParameteriv.xml
+func (gl *GL) GetFramebufferAttachmentParameteriv(target, attachment, pname glbase.Enum, params []int32) {
+ C.gl4_0compat_glGetFramebufferAttachmentParameteriv(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFramebufferRenderbuffer.xml
+func (gl *GL) FramebufferRenderbuffer(target, attachment, renderbuffertarget glbase.Enum, renderbuffer glbase.Renderbuffer) {
+ C.gl4_0compat_glFramebufferRenderbuffer(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(renderbuffertarget), C.GLuint(renderbuffer))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFramebufferTexture3D.xml
+func (gl *GL) FramebufferTexture3D(target, attachment, textarget glbase.Enum, texture glbase.Texture, level int, zoffset int32) {
+ C.gl4_0compat_glFramebufferTexture3D(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(textarget), C.GLuint(texture), C.GLint(level), C.GLint(zoffset))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFramebufferTexture2D.xml
+func (gl *GL) FramebufferTexture2D(target, attachment, textarget glbase.Enum, texture glbase.Texture, level int) {
+ C.gl4_0compat_glFramebufferTexture2D(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(textarget), C.GLuint(texture), C.GLint(level))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFramebufferTexture1D.xml
+func (gl *GL) FramebufferTexture1D(target, attachment, textarget glbase.Enum, texture glbase.Texture, level int) {
+ C.gl4_0compat_glFramebufferTexture1D(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(textarget), C.GLuint(texture), C.GLint(level))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCheckFramebufferStatus.xml
+func (gl *GL) CheckFramebufferStatus(target glbase.Enum) glbase.Enum {
+ glresult := C.gl4_0compat_glCheckFramebufferStatus(gl.funcs, C.GLenum(target))
+ return glbase.Enum(glresult)
+}
+
+// GenFramebuffers returns n framebuffer object names in ids. There is no
+// guarantee that the names form a contiguous set of integers; however, it is
+// guaranteed that none of the returned names was in use immediately before
+// the call to GenFramebuffers.
+//
+// Framebuffer object names returned by a call to GenFramebuffers are not
+// returned by subsequent calls, unless they are first deleted with
+// DeleteFramebuffers.
+//
+// The names returned in ids are marked as used, for the purposes of
+// GenFramebuffers only, but they acquire state and type only when they are
+// first bound.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+func (gl *GL) GenFramebuffers(n int) []glbase.Framebuffer {
+ if n == 0 {
+ return nil
+ }
+ framebuffers := make([]glbase.Framebuffer, n)
+ C.gl4_0compat_glGenFramebuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&framebuffers[0])))
+ return framebuffers
+}
+
+// DeleteFramebuffers deletes the framebuffer objects whose names are
+// stored in the framebuffers slice. The name zero is reserved by the GL and
+// is silently ignored, should it occur in framebuffers, as are other unused
+// names. Once a framebuffer object is deleted, its name is again unused and
+// it has no attachments. If a framebuffer that is currently bound to one or
+// more of the targets GL.DRAW_FRAMEBUFFER or GL.READ_FRAMEBUFFER is deleted,
+// it is as though BindFramebuffer had been executed with the corresponding
+// target and framebuffer zero.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// DeleteFramebuffers is available in GL version 3.0 or greater.
+func (gl *GL) DeleteFramebuffers(framebuffers []glbase.Framebuffer) {
+ n := len(framebuffers)
+ if n == 0 {
+ return
+ }
+ C.gl4_0compat_glDeleteFramebuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&framebuffers[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindFramebuffer.xml
+func (gl *GL) BindFramebuffer(target glbase.Enum, framebuffer glbase.Framebuffer) {
+ C.gl4_0compat_glBindFramebuffer(gl.funcs, C.GLenum(target), C.GLuint(framebuffer))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsFramebuffer.xml
+func (gl *GL) IsFramebuffer(framebuffer glbase.Framebuffer) bool {
+ glresult := C.gl4_0compat_glIsFramebuffer(gl.funcs, C.GLuint(framebuffer))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetRenderbufferParameteriv.xml
+func (gl *GL) GetRenderbufferParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl4_0compat_glGetRenderbufferParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRenderbufferStorage.xml
+func (gl *GL) RenderbufferStorage(target, internalFormat glbase.Enum, width, height int) {
+ C.gl4_0compat_glRenderbufferStorage(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height))
+}
+
+// GenRenderbuffers returns n renderbuffer object names in renderbuffers.
+// There is no guarantee that the names form a contiguous set of integers;
+// however, it is guaranteed that none of the returned names was in use
+// immediately before the call to GenRenderbuffers.
+//
+// Renderbuffer object names returned by a call to GenRenderbuffers are not
+// returned by subsequent calls, unless they are first deleted with
+// DeleteRenderbuffers.
+//
+// The names returned in renderbuffers are marked as used, for the purposes
+// of GenRenderbuffers only, but they acquire state and type only when they
+// are first bound.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// GenRenderbuffers is available in GL version 3.0 or greater.
+func (gl *GL) GenRenderbuffers(n int) []glbase.Renderbuffer {
+ if n == 0 {
+ return nil
+ }
+ renderbuffers := make([]glbase.Renderbuffer, n)
+ C.gl4_0compat_glGenRenderbuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&renderbuffers[0])))
+ return renderbuffers
+}
+
+// DeleteRenderbuffers deletes the renderbuffer objects whose names are stored
+// in the renderbuffers slice. The name zero is reserved by the GL and
+// is silently ignored, should it occur in renderbuffers, as are other unused
+// names. Once a renderbuffer object is deleted, its name is again unused and
+// it has no contents. If a renderbuffer that is currently bound to the
+// target GL.RENDERBUFFER is deleted, it is as though BindRenderbuffer had
+// been executed with a target of GL.RENDERBUFFER and a name of zero.
+//
+// If a renderbuffer object is attached to one or more attachment points in
+// the currently bound framebuffer, then it as if FramebufferRenderbuffer
+// had been called, with a renderbuffer of zero for each attachment point to
+// which this image was attached in the currently bound framebuffer. In other
+// words, this renderbuffer object is first detached from all attachment
+// ponits in the currently bound framebuffer. Note that the renderbuffer
+// image is specifically not detached from any non-bound framebuffers.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// DeleteRenderbuffers is available in GL version 3.0 or greater.
+func (gl *GL) DeleteRenderbuffers(renderbuffers []glbase.Renderbuffer) {
+ n := len(renderbuffers)
+ if n == 0 {
+ return
+ }
+ C.gl4_0compat_glDeleteRenderbuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&renderbuffers[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindRenderbuffer.xml
+func (gl *GL) BindRenderbuffer(target glbase.Enum, renderbuffer glbase.Renderbuffer) {
+ C.gl4_0compat_glBindRenderbuffer(gl.funcs, C.GLenum(target), C.GLuint(renderbuffer))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsRenderbuffer.xml
+func (gl *GL) IsRenderbuffer(renderbuffer glbase.Renderbuffer) bool {
+ glresult := C.gl4_0compat_glIsRenderbuffer(gl.funcs, C.GLuint(renderbuffer))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearBufferfi.xml
+func (gl *GL) ClearBufferfi(buffer glbase.Enum, drawbuffer int32, depth float32, stencil int32) {
+ C.gl4_0compat_glClearBufferfi(gl.funcs, C.GLenum(buffer), C.GLint(drawbuffer), C.GLfloat(depth), C.GLint(stencil))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearBufferfv.xml
+func (gl *GL) ClearBufferfv(buffer glbase.Enum, drawbuffer int32, value []float32) {
+ C.gl4_0compat_glClearBufferfv(gl.funcs, C.GLenum(buffer), C.GLint(drawbuffer), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearBufferuiv.xml
+func (gl *GL) ClearBufferuiv(buffer glbase.Enum, drawbuffer int32, value []uint32) {
+ C.gl4_0compat_glClearBufferuiv(gl.funcs, C.GLenum(buffer), C.GLint(drawbuffer), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearBufferiv.xml
+func (gl *GL) ClearBufferiv(buffer glbase.Enum, drawbuffer int32, value []int32) {
+ C.gl4_0compat_glClearBufferiv(gl.funcs, C.GLenum(buffer), C.GLint(drawbuffer), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexParameterIuiv.xml
+func (gl *GL) GetTexParameterIuiv(target, pname glbase.Enum, params []uint32) {
+ C.gl4_0compat_glGetTexParameterIuiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexParameterIiv.xml
+func (gl *GL) GetTexParameterIiv(target, pname glbase.Enum, params []int32) {
+ C.gl4_0compat_glGetTexParameterIiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexParameterIuiv.xml
+func (gl *GL) TexParameterIuiv(target, pname glbase.Enum, params []uint32) {
+ C.gl4_0compat_glTexParameterIuiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexParameterIiv.xml
+func (gl *GL) TexParameterIiv(target, pname glbase.Enum, params []int32) {
+ C.gl4_0compat_glTexParameterIiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// Uniform4uiv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform4uiv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4uiv(location glbase.Uniform, value []uint32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%4 != 0 {
+ panic("invalid value length for Uniform4uiv")
+ }
+ count := len(value) / 4
+ C.gl4_0compat_glUniform4uiv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform3uiv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform3uiv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3uiv(location glbase.Uniform, value []uint32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%3 != 0 {
+ panic("invalid value length for Uniform3uiv")
+ }
+ count := len(value) / 3
+ C.gl4_0compat_glUniform3uiv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform2uiv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform2uiv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2uiv(location glbase.Uniform, value []uint32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%2 != 0 {
+ panic("invalid value length for Uniform2uiv")
+ }
+ count := len(value) / 2
+ C.gl4_0compat_glUniform2uiv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform1uiv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform1uiv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1uiv(location glbase.Uniform, value []uint32) {
+ if len(value) == 0 {
+ return
+ }
+ count := len(value)
+ C.gl4_0compat_glUniform1uiv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4ui modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform4ui operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4ui(location glbase.Uniform, v0, v1, v2, v3 uint32) {
+ C.gl4_0compat_glUniform4ui(gl.funcs, C.GLint(location), C.GLuint(v0), C.GLuint(v1), C.GLuint(v2), C.GLuint(v3))
+}
+
+// Uniform3ui modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform3ui operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3ui(location glbase.Uniform, v0, v1, v2 uint32) {
+ C.gl4_0compat_glUniform3ui(gl.funcs, C.GLint(location), C.GLuint(v0), C.GLuint(v1), C.GLuint(v2))
+}
+
+// Uniform2ui modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform2ui operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2ui(location glbase.Uniform, v0, v1 uint32) {
+ C.gl4_0compat_glUniform2ui(gl.funcs, C.GLint(location), C.GLuint(v0), C.GLuint(v1))
+}
+
+// Uniform1ui modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform1ui operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1ui(location glbase.Uniform, v0 uint32) {
+ C.gl4_0compat_glUniform1ui(gl.funcs, C.GLint(location), C.GLuint(v0))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetFragDataLocation.xml
+func (gl *GL) GetFragDataLocation(program glbase.Program, name []byte) int32 {
+ glresult := C.gl4_0compat_glGetFragDataLocation(gl.funcs, C.GLuint(program), (*C.GLchar)(unsafe.Pointer(&name[0])))
+ return int32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindFragDataLocation.xml
+func (gl *GL) BindFragDataLocation(program glbase.Program, color uint32, name []byte) {
+ C.gl4_0compat_glBindFragDataLocation(gl.funcs, C.GLuint(program), C.GLuint(color), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetUniformuiv.xml
+func (gl *GL) GetUniformuiv(program glbase.Program, location glbase.Uniform, params []uint32) {
+ C.gl4_0compat_glGetUniformuiv(gl.funcs, C.GLuint(program), C.GLint(location), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetVertexAttribIuiv.xml
+func (gl *GL) GetVertexAttribIuiv(index glbase.Attrib, pname glbase.Enum, params []uint32) {
+ C.gl4_0compat_glGetVertexAttribIuiv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetVertexAttribIiv.xml
+func (gl *GL) GetVertexAttribIiv(index glbase.Attrib, pname glbase.Enum, params []int32) {
+ C.gl4_0compat_glGetVertexAttribIiv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribIPointer.xml
+func (gl *GL) VertexAttribIPointer(index glbase.Attrib, size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0compat_glVertexAttribIPointer(gl.funcs, C.GLuint(index), C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEndConditionalRender.xml
+func (gl *GL) EndConditionalRender() {
+ C.gl4_0compat_glEndConditionalRender(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBeginConditionalRender.xml
+func (gl *GL) BeginConditionalRender(id uint32, mode glbase.Enum) {
+ C.gl4_0compat_glBeginConditionalRender(gl.funcs, C.GLuint(id), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClampColor.xml
+func (gl *GL) ClampColor(target, clamp glbase.Enum) {
+ C.gl4_0compat_glClampColor(gl.funcs, C.GLenum(target), C.GLenum(clamp))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTransformFeedbackVarying.xml
+func (gl *GL) GetTransformFeedbackVarying(program glbase.Program, index uint32, bufSize int32, length []int32, size []int, gltype []glbase.Enum, name []byte) {
+ C.gl4_0compat_glGetTransformFeedbackVarying(gl.funcs, C.GLuint(program), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLsizei)(unsafe.Pointer(&size[0])), (*C.GLenum)(unsafe.Pointer(&gltype[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindBufferBase.xml
+func (gl *GL) BindBufferBase(target glbase.Enum, index uint32, buffer glbase.Buffer) {
+ C.gl4_0compat_glBindBufferBase(gl.funcs, C.GLenum(target), C.GLuint(index), C.GLuint(buffer))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindBufferRange.xml
+func (gl *GL) BindBufferRange(target glbase.Enum, index uint32, buffer glbase.Buffer, offset, size int) {
+ C.gl4_0compat_glBindBufferRange(gl.funcs, C.GLenum(target), C.GLuint(index), C.GLuint(buffer), C.GLintptr(offset), C.GLsizeiptr(size))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEndTransformFeedback.xml
+func (gl *GL) EndTransformFeedback() {
+ C.gl4_0compat_glEndTransformFeedback(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBeginTransformFeedback.xml
+func (gl *GL) BeginTransformFeedback(primitiveMode glbase.Enum) {
+ C.gl4_0compat_glBeginTransformFeedback(gl.funcs, C.GLenum(primitiveMode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsEnabledi.xml
+func (gl *GL) IsEnabledi(target glbase.Enum, index uint32) bool {
+ glresult := C.gl4_0compat_glIsEnabledi(gl.funcs, C.GLenum(target), C.GLuint(index))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDisablei.xml
+func (gl *GL) Disablei(target glbase.Enum, index uint32) {
+ C.gl4_0compat_glDisablei(gl.funcs, C.GLenum(target), C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEnablei.xml
+func (gl *GL) Enablei(target glbase.Enum, index uint32) {
+ C.gl4_0compat_glEnablei(gl.funcs, C.GLenum(target), C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetIntegeri_v.xml
+func (gl *GL) GetIntegeri_v(target glbase.Enum, index uint32, data []int32) {
+ C.gl4_0compat_glGetIntegeri_v(gl.funcs, C.GLenum(target), C.GLuint(index), (*C.GLint)(unsafe.Pointer(&data[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetBooleani_v.xml
+func (gl *GL) GetBooleani_v(target glbase.Enum, index uint32, data []bool) {
+ C.gl4_0compat_glGetBooleani_v(gl.funcs, C.GLenum(target), C.GLuint(index), (*C.GLboolean)(unsafe.Pointer(&data[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorMaski.xml
+func (gl *GL) ColorMaski(index uint32, r, g, b, a bool) {
+ C.gl4_0compat_glColorMaski(gl.funcs, C.GLuint(index), *(*C.GLboolean)(unsafe.Pointer(&r)), *(*C.GLboolean)(unsafe.Pointer(&g)), *(*C.GLboolean)(unsafe.Pointer(&b)), *(*C.GLboolean)(unsafe.Pointer(&a)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyBufferSubData.xml
+func (gl *GL) CopyBufferSubData(readTarget, writeTarget glbase.Enum, readOffset, writeOffset, size int) {
+ C.gl4_0compat_glCopyBufferSubData(gl.funcs, C.GLenum(readTarget), C.GLenum(writeTarget), C.GLintptr(readOffset), C.GLintptr(writeOffset), C.GLsizeiptr(size))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformBlockBinding.xml
+func (gl *GL) UniformBlockBinding(program glbase.Program, v0, v1 uint32) {
+ C.gl4_0compat_glUniformBlockBinding(gl.funcs, C.GLuint(program), C.GLuint(v0), C.GLuint(v1))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveUniformBlockName.xml
+func (gl *GL) GetActiveUniformBlockName(program glbase.Program, uniformBlockIndex uint32, bufSize int32, length []int32, uniformBlockName []byte) {
+ C.gl4_0compat_glGetActiveUniformBlockName(gl.funcs, C.GLuint(program), C.GLuint(uniformBlockIndex), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&uniformBlockName[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveUniformBlockiv.xml
+func (gl *GL) GetActiveUniformBlockiv(program glbase.Program, uniformBlockIndex uint32, pname glbase.Enum, params []int32) {
+ C.gl4_0compat_glGetActiveUniformBlockiv(gl.funcs, C.GLuint(program), C.GLuint(uniformBlockIndex), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetUniformBlockIndex.xml
+func (gl *GL) GetUniformBlockIndex(program glbase.Program, uniformBlockName []byte) uint32 {
+ glresult := C.gl4_0compat_glGetUniformBlockIndex(gl.funcs, C.GLuint(program), (*C.GLchar)(unsafe.Pointer(&uniformBlockName[0])))
+ return uint32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveUniformName.xml
+func (gl *GL) GetActiveUniformName(program glbase.Program, uniformIndex uint32, bufSize int32, length []int32, uniformName []byte) {
+ C.gl4_0compat_glGetActiveUniformName(gl.funcs, C.GLuint(program), C.GLuint(uniformIndex), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&uniformName[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveUniformsiv.xml
+func (gl *GL) GetActiveUniformsiv(program glbase.Program, uniformCount int32, uniformIndices []uint32, pname glbase.Enum, params []int32) {
+ C.gl4_0compat_glGetActiveUniformsiv(gl.funcs, C.GLuint(program), C.GLsizei(uniformCount), (*C.GLuint)(unsafe.Pointer(&uniformIndices[0])), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPrimitiveRestartIndex.xml
+func (gl *GL) PrimitiveRestartIndex(index uint32) {
+ C.gl4_0compat_glPrimitiveRestartIndex(gl.funcs, C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexBuffer.xml
+func (gl *GL) TexBuffer(target, internalFormat glbase.Enum, buffer glbase.Buffer) {
+ C.gl4_0compat_glTexBuffer(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLuint(buffer))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawElementsInstanced.xml
+func (gl *GL) DrawElementsInstanced(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}, instancecount int32) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0compat_glDrawElementsInstanced(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr, C.GLsizei(instancecount))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawArraysInstanced.xml
+func (gl *GL) DrawArraysInstanced(mode glbase.Enum, first, count int, instancecount int32) {
+ C.gl4_0compat_glDrawArraysInstanced(gl.funcs, C.GLenum(mode), C.GLint(first), C.GLsizei(count), C.GLsizei(instancecount))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSampleMaski.xml
+func (gl *GL) SampleMaski(index uint32, mask glbase.Bitfield) {
+ C.gl4_0compat_glSampleMaski(gl.funcs, C.GLuint(index), C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetMultisamplefv.xml
+func (gl *GL) GetMultisamplefv(pname glbase.Enum, index uint32, val []float32) {
+ C.gl4_0compat_glGetMultisamplefv(gl.funcs, C.GLenum(pname), C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&val[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexImage3DMultisample.xml
+func (gl *GL) TexImage3DMultisample(target glbase.Enum, samples, internalFormat int32, width, height int, depth int32, fixedsamplelocations bool) {
+ C.gl4_0compat_glTexImage3DMultisample(gl.funcs, C.GLenum(target), C.GLsizei(samples), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), *(*C.GLboolean)(unsafe.Pointer(&fixedsamplelocations)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexImage2DMultisample.xml
+func (gl *GL) TexImage2DMultisample(target glbase.Enum, samples, internalFormat int32, width, height int, fixedsamplelocations bool) {
+ C.gl4_0compat_glTexImage2DMultisample(gl.funcs, C.GLenum(target), C.GLsizei(samples), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), *(*C.GLboolean)(unsafe.Pointer(&fixedsamplelocations)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetSynciv.xml
+func (gl *GL) GetSynciv(sync glbase.Sync, pname glbase.Enum, bufSize int32, length, values []int32) {
+ C.gl4_0compat_glGetSynciv(gl.funcs, C.GLsync(unsafe.Pointer(sync)), C.GLenum(pname), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLint)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetInteger64v.xml
+func (gl *GL) GetInteger64v(pname glbase.Enum, params []int64) {
+ C.gl4_0compat_glGetInteger64v(gl.funcs, C.GLenum(pname), (*C.GLint64)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWaitSync.xml
+func (gl *GL) WaitSync(sync glbase.Sync, flags glbase.Bitfield, timeout uint64) {
+ C.gl4_0compat_glWaitSync(gl.funcs, C.GLsync(unsafe.Pointer(sync)), C.GLbitfield(flags), C.GLuint64(timeout))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClientWaitSync.xml
+func (gl *GL) ClientWaitSync(sync glbase.Sync, flags glbase.Bitfield, timeout uint64) glbase.Enum {
+ glresult := C.gl4_0compat_glClientWaitSync(gl.funcs, C.GLsync(unsafe.Pointer(sync)), C.GLbitfield(flags), C.GLuint64(timeout))
+ return glbase.Enum(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDeleteSync.xml
+func (gl *GL) DeleteSync(sync glbase.Sync) {
+ C.gl4_0compat_glDeleteSync(gl.funcs, C.GLsync(unsafe.Pointer(sync)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsSync.xml
+func (gl *GL) IsSync(sync glbase.Sync) bool {
+ glresult := C.gl4_0compat_glIsSync(gl.funcs, C.GLsync(unsafe.Pointer(sync)))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFenceSync.xml
+func (gl *GL) FenceSync(condition glbase.Enum, flags glbase.Bitfield) glbase.Sync {
+ glresult := C.gl4_0compat_glFenceSync(gl.funcs, C.GLenum(condition), C.GLbitfield(flags))
+ return glbase.Sync(unsafe.Pointer(glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProvokingVertex.xml
+func (gl *GL) ProvokingVertex(mode glbase.Enum) {
+ C.gl4_0compat_glProvokingVertex(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawElementsInstancedBaseVertex.xml
+func (gl *GL) DrawElementsInstancedBaseVertex(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}, instancecount, basevertex int32) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0compat_glDrawElementsInstancedBaseVertex(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr, C.GLsizei(instancecount), C.GLint(basevertex))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawRangeElementsBaseVertex.xml
+func (gl *GL) DrawRangeElementsBaseVertex(mode glbase.Enum, start, end uint32, count int, gltype glbase.Enum, indices interface{}, basevertex int32) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0compat_glDrawRangeElementsBaseVertex(gl.funcs, C.GLenum(mode), C.GLuint(start), C.GLuint(end), C.GLsizei(count), C.GLenum(gltype), indices_ptr, C.GLint(basevertex))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawElementsBaseVertex.xml
+func (gl *GL) DrawElementsBaseVertex(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}, basevertex int32) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0compat_glDrawElementsBaseVertex(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr, C.GLint(basevertex))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFramebufferTexture.xml
+func (gl *GL) FramebufferTexture(target, attachment glbase.Enum, texture glbase.Texture, level int) {
+ C.gl4_0compat_glFramebufferTexture(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLuint(texture), C.GLint(level))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetBufferParameteri64v.xml
+func (gl *GL) GetBufferParameteri64v(target, pname glbase.Enum, params []int64) {
+ C.gl4_0compat_glGetBufferParameteri64v(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint64)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetInteger64i_v.xml
+func (gl *GL) GetInteger64i_v(target glbase.Enum, index uint32, data []int64) {
+ C.gl4_0compat_glGetInteger64i_v(gl.funcs, C.GLenum(target), C.GLuint(index), (*C.GLint64)(unsafe.Pointer(&data[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP4uiv.xml
+func (gl *GL) VertexAttribP4uiv(index glbase.Attrib, gltype glbase.Enum, normalized bool, value []uint32) {
+ C.gl4_0compat_glVertexAttribP4uiv(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP4ui.xml
+func (gl *GL) VertexAttribP4ui(index glbase.Attrib, gltype glbase.Enum, normalized bool, value uint32) {
+ C.gl4_0compat_glVertexAttribP4ui(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP3uiv.xml
+func (gl *GL) VertexAttribP3uiv(index glbase.Attrib, gltype glbase.Enum, normalized bool, value []uint32) {
+ C.gl4_0compat_glVertexAttribP3uiv(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP3ui.xml
+func (gl *GL) VertexAttribP3ui(index glbase.Attrib, gltype glbase.Enum, normalized bool, value uint32) {
+ C.gl4_0compat_glVertexAttribP3ui(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP2uiv.xml
+func (gl *GL) VertexAttribP2uiv(index glbase.Attrib, gltype glbase.Enum, normalized bool, value []uint32) {
+ C.gl4_0compat_glVertexAttribP2uiv(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP2ui.xml
+func (gl *GL) VertexAttribP2ui(index glbase.Attrib, gltype glbase.Enum, normalized bool, value uint32) {
+ C.gl4_0compat_glVertexAttribP2ui(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP1uiv.xml
+func (gl *GL) VertexAttribP1uiv(index glbase.Attrib, gltype glbase.Enum, normalized bool, value []uint32) {
+ C.gl4_0compat_glVertexAttribP1uiv(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP1ui.xml
+func (gl *GL) VertexAttribP1ui(index glbase.Attrib, gltype glbase.Enum, normalized bool, value uint32) {
+ C.gl4_0compat_glVertexAttribP1ui(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColorP3uiv.xml
+func (gl *GL) SecondaryColorP3uiv(gltype glbase.Enum, color []uint32) {
+ C.gl4_0compat_glSecondaryColorP3uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&color[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColorP3ui.xml
+func (gl *GL) SecondaryColorP3ui(gltype glbase.Enum, color uint32) {
+ C.gl4_0compat_glSecondaryColorP3ui(gl.funcs, C.GLenum(gltype), C.GLuint(color))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorP4uiv.xml
+func (gl *GL) ColorP4uiv(gltype glbase.Enum, color []uint32) {
+ C.gl4_0compat_glColorP4uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&color[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorP4ui.xml
+func (gl *GL) ColorP4ui(gltype glbase.Enum, color uint32) {
+ C.gl4_0compat_glColorP4ui(gl.funcs, C.GLenum(gltype), C.GLuint(color))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorP3uiv.xml
+func (gl *GL) ColorP3uiv(gltype glbase.Enum, color []uint32) {
+ C.gl4_0compat_glColorP3uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&color[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorP3ui.xml
+func (gl *GL) ColorP3ui(gltype glbase.Enum, color uint32) {
+ C.gl4_0compat_glColorP3ui(gl.funcs, C.GLenum(gltype), C.GLuint(color))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNormalP3uiv.xml
+func (gl *GL) NormalP3uiv(gltype glbase.Enum, coords []uint32) {
+ C.gl4_0compat_glNormalP3uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNormalP3ui.xml
+func (gl *GL) NormalP3ui(gltype glbase.Enum, coords uint32) {
+ C.gl4_0compat_glNormalP3ui(gl.funcs, C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP4uiv.xml
+func (gl *GL) MultiTexCoordP4uiv(texture, gltype glbase.Enum, coords []uint32) {
+ C.gl4_0compat_glMultiTexCoordP4uiv(gl.funcs, C.GLenum(texture), C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP4ui.xml
+func (gl *GL) MultiTexCoordP4ui(texture, gltype glbase.Enum, coords uint32) {
+ C.gl4_0compat_glMultiTexCoordP4ui(gl.funcs, C.GLenum(texture), C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP3uiv.xml
+func (gl *GL) MultiTexCoordP3uiv(texture, gltype glbase.Enum, coords []uint32) {
+ C.gl4_0compat_glMultiTexCoordP3uiv(gl.funcs, C.GLenum(texture), C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP3ui.xml
+func (gl *GL) MultiTexCoordP3ui(texture, gltype glbase.Enum, coords uint32) {
+ C.gl4_0compat_glMultiTexCoordP3ui(gl.funcs, C.GLenum(texture), C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP2uiv.xml
+func (gl *GL) MultiTexCoordP2uiv(texture, gltype glbase.Enum, coords []uint32) {
+ C.gl4_0compat_glMultiTexCoordP2uiv(gl.funcs, C.GLenum(texture), C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP2ui.xml
+func (gl *GL) MultiTexCoordP2ui(texture, gltype glbase.Enum, coords uint32) {
+ C.gl4_0compat_glMultiTexCoordP2ui(gl.funcs, C.GLenum(texture), C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP1uiv.xml
+func (gl *GL) MultiTexCoordP1uiv(texture, gltype glbase.Enum, coords []uint32) {
+ C.gl4_0compat_glMultiTexCoordP1uiv(gl.funcs, C.GLenum(texture), C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP1ui.xml
+func (gl *GL) MultiTexCoordP1ui(texture, gltype glbase.Enum, coords uint32) {
+ C.gl4_0compat_glMultiTexCoordP1ui(gl.funcs, C.GLenum(texture), C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP4uiv.xml
+func (gl *GL) TexCoordP4uiv(gltype glbase.Enum, coords []uint32) {
+ C.gl4_0compat_glTexCoordP4uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP4ui.xml
+func (gl *GL) TexCoordP4ui(gltype glbase.Enum, coords uint32) {
+ C.gl4_0compat_glTexCoordP4ui(gl.funcs, C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP3uiv.xml
+func (gl *GL) TexCoordP3uiv(gltype glbase.Enum, coords []uint32) {
+ C.gl4_0compat_glTexCoordP3uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP3ui.xml
+func (gl *GL) TexCoordP3ui(gltype glbase.Enum, coords uint32) {
+ C.gl4_0compat_glTexCoordP3ui(gl.funcs, C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP2uiv.xml
+func (gl *GL) TexCoordP2uiv(gltype glbase.Enum, coords []uint32) {
+ C.gl4_0compat_glTexCoordP2uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP2ui.xml
+func (gl *GL) TexCoordP2ui(gltype glbase.Enum, coords uint32) {
+ C.gl4_0compat_glTexCoordP2ui(gl.funcs, C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP1uiv.xml
+func (gl *GL) TexCoordP1uiv(gltype glbase.Enum, coords []uint32) {
+ C.gl4_0compat_glTexCoordP1uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP1ui.xml
+func (gl *GL) TexCoordP1ui(gltype glbase.Enum, coords uint32) {
+ C.gl4_0compat_glTexCoordP1ui(gl.funcs, C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexP4uiv.xml
+func (gl *GL) VertexP4uiv(gltype glbase.Enum, value []uint32) {
+ C.gl4_0compat_glVertexP4uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexP4ui.xml
+func (gl *GL) VertexP4ui(gltype glbase.Enum, value uint32) {
+ C.gl4_0compat_glVertexP4ui(gl.funcs, C.GLenum(gltype), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexP3uiv.xml
+func (gl *GL) VertexP3uiv(gltype glbase.Enum, value []uint32) {
+ C.gl4_0compat_glVertexP3uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexP3ui.xml
+func (gl *GL) VertexP3ui(gltype glbase.Enum, value uint32) {
+ C.gl4_0compat_glVertexP3ui(gl.funcs, C.GLenum(gltype), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexP2uiv.xml
+func (gl *GL) VertexP2uiv(gltype glbase.Enum, value []uint32) {
+ C.gl4_0compat_glVertexP2uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexP2ui.xml
+func (gl *GL) VertexP2ui(gltype glbase.Enum, value uint32) {
+ C.gl4_0compat_glVertexP2ui(gl.funcs, C.GLenum(gltype), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetQueryObjectui64v.xml
+func (gl *GL) GetQueryObjectui64v(id uint32, pname glbase.Enum, params []uint64) {
+ C.gl4_0compat_glGetQueryObjectui64v(gl.funcs, C.GLuint(id), C.GLenum(pname), (*C.GLuint64)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetQueryObjecti64v.xml
+func (gl *GL) GetQueryObjecti64v(id uint32, pname glbase.Enum, params []int64) {
+ C.gl4_0compat_glGetQueryObjecti64v(gl.funcs, C.GLuint(id), C.GLenum(pname), (*C.GLint64)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glQueryCounter.xml
+func (gl *GL) QueryCounter(id uint32, target glbase.Enum) {
+ C.gl4_0compat_glQueryCounter(gl.funcs, C.GLuint(id), C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetSamplerParameterIuiv.xml
+func (gl *GL) GetSamplerParameterIuiv(sampler uint32, pname glbase.Enum, params []uint32) {
+ C.gl4_0compat_glGetSamplerParameterIuiv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetSamplerParameterfv.xml
+func (gl *GL) GetSamplerParameterfv(sampler uint32, pname glbase.Enum, params []float32) {
+ C.gl4_0compat_glGetSamplerParameterfv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetSamplerParameterIiv.xml
+func (gl *GL) GetSamplerParameterIiv(sampler uint32, pname glbase.Enum, params []int32) {
+ C.gl4_0compat_glGetSamplerParameterIiv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetSamplerParameteriv.xml
+func (gl *GL) GetSamplerParameteriv(sampler uint32, pname glbase.Enum, params []int32) {
+ C.gl4_0compat_glGetSamplerParameteriv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSamplerParameterIuiv.xml
+func (gl *GL) SamplerParameterIuiv(sampler uint32, pname glbase.Enum, param []uint32) {
+ C.gl4_0compat_glSamplerParameterIuiv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&param[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSamplerParameterIiv.xml
+func (gl *GL) SamplerParameterIiv(sampler uint32, pname glbase.Enum, param []int32) {
+ C.gl4_0compat_glSamplerParameterIiv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&param[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSamplerParameterfv.xml
+func (gl *GL) SamplerParameterfv(sampler uint32, pname glbase.Enum, param []float32) {
+ C.gl4_0compat_glSamplerParameterfv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&param[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSamplerParameterf.xml
+func (gl *GL) SamplerParameterf(sampler uint32, pname glbase.Enum, param float32) {
+ C.gl4_0compat_glSamplerParameterf(gl.funcs, C.GLuint(sampler), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSamplerParameteriv.xml
+func (gl *GL) SamplerParameteriv(sampler uint32, pname glbase.Enum, param []int32) {
+ C.gl4_0compat_glSamplerParameteriv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&param[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSamplerParameteri.xml
+func (gl *GL) SamplerParameteri(sampler uint32, pname glbase.Enum, param int32) {
+ C.gl4_0compat_glSamplerParameteri(gl.funcs, C.GLuint(sampler), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindSampler.xml
+func (gl *GL) BindSampler(unit, sampler uint32) {
+ C.gl4_0compat_glBindSampler(gl.funcs, C.GLuint(unit), C.GLuint(sampler))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsSampler.xml
+func (gl *GL) IsSampler(sampler uint32) bool {
+ glresult := C.gl4_0compat_glIsSampler(gl.funcs, C.GLuint(sampler))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDeleteSamplers.xml
+func (gl *GL) DeleteSamplers(count int, samplers []uint32) {
+ C.gl4_0compat_glDeleteSamplers(gl.funcs, C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&samplers[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGenSamplers.xml
+func (gl *GL) GenSamplers(count int, samplers []uint32) {
+ C.gl4_0compat_glGenSamplers(gl.funcs, C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&samplers[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetFragDataIndex.xml
+func (gl *GL) GetFragDataIndex(program glbase.Program, name []byte) int32 {
+ glresult := C.gl4_0compat_glGetFragDataIndex(gl.funcs, C.GLuint(program), (*C.GLchar)(unsafe.Pointer(&name[0])))
+ return int32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindFragDataLocationIndexed.xml
+func (gl *GL) BindFragDataLocationIndexed(program glbase.Program, colorNumber, index uint32, name []byte) {
+ C.gl4_0compat_glBindFragDataLocationIndexed(gl.funcs, C.GLuint(program), C.GLuint(colorNumber), C.GLuint(index), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribDivisor.xml
+func (gl *GL) VertexAttribDivisor(index glbase.Attrib, divisor uint32) {
+ C.gl4_0compat_glVertexAttribDivisor(gl.funcs, C.GLuint(index), C.GLuint(divisor))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetQueryIndexediv.xml
+func (gl *GL) GetQueryIndexediv(target glbase.Enum, index uint32, pname glbase.Enum, params []int32) {
+ C.gl4_0compat_glGetQueryIndexediv(gl.funcs, C.GLenum(target), C.GLuint(index), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEndQueryIndexed.xml
+func (gl *GL) EndQueryIndexed(target glbase.Enum, index uint32) {
+ C.gl4_0compat_glEndQueryIndexed(gl.funcs, C.GLenum(target), C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBeginQueryIndexed.xml
+func (gl *GL) BeginQueryIndexed(target glbase.Enum, index, id uint32) {
+ C.gl4_0compat_glBeginQueryIndexed(gl.funcs, C.GLenum(target), C.GLuint(index), C.GLuint(id))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawTransformFeedbackStream.xml
+func (gl *GL) DrawTransformFeedbackStream(mode glbase.Enum, id, stream uint32) {
+ C.gl4_0compat_glDrawTransformFeedbackStream(gl.funcs, C.GLenum(mode), C.GLuint(id), C.GLuint(stream))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawTransformFeedback.xml
+func (gl *GL) DrawTransformFeedback(mode glbase.Enum, id uint32) {
+ C.gl4_0compat_glDrawTransformFeedback(gl.funcs, C.GLenum(mode), C.GLuint(id))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glResumeTransformFeedback.xml
+func (gl *GL) ResumeTransformFeedback() {
+ C.gl4_0compat_glResumeTransformFeedback(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPauseTransformFeedback.xml
+func (gl *GL) PauseTransformFeedback() {
+ C.gl4_0compat_glPauseTransformFeedback(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsTransformFeedback.xml
+func (gl *GL) IsTransformFeedback(id uint32) bool {
+ glresult := C.gl4_0compat_glIsTransformFeedback(gl.funcs, C.GLuint(id))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGenTransformFeedbacks.xml
+func (gl *GL) GenTransformFeedbacks(n int, ids []uint32) {
+ C.gl4_0compat_glGenTransformFeedbacks(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&ids[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDeleteTransformFeedbacks.xml
+func (gl *GL) DeleteTransformFeedbacks(n int, ids []uint32) {
+ C.gl4_0compat_glDeleteTransformFeedbacks(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&ids[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindTransformFeedback.xml
+func (gl *GL) BindTransformFeedback(target glbase.Enum, id uint32) {
+ C.gl4_0compat_glBindTransformFeedback(gl.funcs, C.GLenum(target), C.GLuint(id))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPatchParameterfv.xml
+func (gl *GL) PatchParameterfv(pname glbase.Enum, values []float32) {
+ C.gl4_0compat_glPatchParameterfv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPatchParameteri.xml
+func (gl *GL) PatchParameteri(pname glbase.Enum, value int32) {
+ C.gl4_0compat_glPatchParameteri(gl.funcs, C.GLenum(pname), C.GLint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetProgramStageiv.xml
+func (gl *GL) GetProgramStageiv(program glbase.Program, shadertype, pname glbase.Enum, values []int32) {
+ C.gl4_0compat_glGetProgramStageiv(gl.funcs, C.GLuint(program), C.GLenum(shadertype), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetUniformSubroutineuiv.xml
+func (gl *GL) GetUniformSubroutineuiv(shadertype glbase.Enum, location glbase.Uniform, params []uint32) {
+ C.gl4_0compat_glGetUniformSubroutineuiv(gl.funcs, C.GLenum(shadertype), C.GLint(location), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformSubroutinesuiv.xml
+func (gl *GL) UniformSubroutinesuiv(shadertype glbase.Enum, count int, value []uint32) {
+ C.gl4_0compat_glUniformSubroutinesuiv(gl.funcs, C.GLenum(shadertype), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveSubroutineName.xml
+func (gl *GL) GetActiveSubroutineName(program glbase.Program, shadertype glbase.Enum, index uint32, bufSize int32, length []int32, name []byte) {
+ C.gl4_0compat_glGetActiveSubroutineName(gl.funcs, C.GLuint(program), C.GLenum(shadertype), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveSubroutineUniformName.xml
+func (gl *GL) GetActiveSubroutineUniformName(program glbase.Program, shadertype glbase.Enum, index uint32, bufSize int32, length []int32, name []byte) {
+ C.gl4_0compat_glGetActiveSubroutineUniformName(gl.funcs, C.GLuint(program), C.GLenum(shadertype), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveSubroutineUniformiv.xml
+func (gl *GL) GetActiveSubroutineUniformiv(program glbase.Program, shadertype glbase.Enum, index uint32, pname glbase.Enum, values []int32) {
+ C.gl4_0compat_glGetActiveSubroutineUniformiv(gl.funcs, C.GLuint(program), C.GLenum(shadertype), C.GLuint(index), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetSubroutineIndex.xml
+func (gl *GL) GetSubroutineIndex(program glbase.Program, shadertype glbase.Enum, name []byte) uint32 {
+ glresult := C.gl4_0compat_glGetSubroutineIndex(gl.funcs, C.GLuint(program), C.GLenum(shadertype), (*C.GLchar)(unsafe.Pointer(&name[0])))
+ return uint32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetSubroutineUniformLocation.xml
+func (gl *GL) GetSubroutineUniformLocation(program glbase.Program, shadertype glbase.Enum, name []byte) int32 {
+ glresult := C.gl4_0compat_glGetSubroutineUniformLocation(gl.funcs, C.GLuint(program), C.GLenum(shadertype), (*C.GLchar)(unsafe.Pointer(&name[0])))
+ return int32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetUniformdv.xml
+func (gl *GL) GetUniformdv(program glbase.Program, location glbase.Uniform, params []float64) {
+ C.gl4_0compat_glGetUniformdv(gl.funcs, C.GLuint(program), C.GLint(location), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix4x3dv.xml
+func (gl *GL) UniformMatrix4x3dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_0compat_glUniformMatrix4x3dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix4x2dv.xml
+func (gl *GL) UniformMatrix4x2dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_0compat_glUniformMatrix4x2dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix3x4dv.xml
+func (gl *GL) UniformMatrix3x4dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_0compat_glUniformMatrix3x4dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix3x2dv.xml
+func (gl *GL) UniformMatrix3x2dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_0compat_glUniformMatrix3x2dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix2x4dv.xml
+func (gl *GL) UniformMatrix2x4dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_0compat_glUniformMatrix2x4dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix2x3dv.xml
+func (gl *GL) UniformMatrix2x3dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_0compat_glUniformMatrix2x3dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix4dv.xml
+func (gl *GL) UniformMatrix4dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_0compat_glUniformMatrix4dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix3dv.xml
+func (gl *GL) UniformMatrix3dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_0compat_glUniformMatrix3dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix2dv.xml
+func (gl *GL) UniformMatrix2dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_0compat_glUniformMatrix2dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform4dv.xml
+func (gl *GL) Uniform4dv(location glbase.Uniform, count int, value []float64) {
+ C.gl4_0compat_glUniform4dv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform3dv.xml
+func (gl *GL) Uniform3dv(location glbase.Uniform, count int, value []float64) {
+ C.gl4_0compat_glUniform3dv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform2dv.xml
+func (gl *GL) Uniform2dv(location glbase.Uniform, count int, value []float64) {
+ C.gl4_0compat_glUniform2dv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform1dv.xml
+func (gl *GL) Uniform1dv(location glbase.Uniform, count int, value []float64) {
+ C.gl4_0compat_glUniform1dv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform4d.xml
+func (gl *GL) Uniform4d(location glbase.Uniform, v0, v1, v2, v3 float64) {
+ C.gl4_0compat_glUniform4d(gl.funcs, C.GLint(location), C.GLdouble(v0), C.GLdouble(v1), C.GLdouble(v2), C.GLdouble(v3))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform3d.xml
+func (gl *GL) Uniform3d(location glbase.Uniform, v0, v1, v2 float64) {
+ C.gl4_0compat_glUniform3d(gl.funcs, C.GLint(location), C.GLdouble(v0), C.GLdouble(v1), C.GLdouble(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform2d.xml
+func (gl *GL) Uniform2d(location glbase.Uniform, v0, v1 float64) {
+ C.gl4_0compat_glUniform2d(gl.funcs, C.GLint(location), C.GLdouble(v0), C.GLdouble(v1))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform1d.xml
+func (gl *GL) Uniform1d(location glbase.Uniform, v0 float64) {
+ C.gl4_0compat_glUniform1d(gl.funcs, C.GLint(location), C.GLdouble(v0))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawElementsIndirect.xml
+func (gl *GL) DrawElementsIndirect(mode, gltype glbase.Enum, indirect interface{}) {
+ var indirect_ptr unsafe.Pointer
+ var indirect_v = reflect.ValueOf(indirect)
+ if indirect != nil && indirect_v.Kind() != reflect.Slice {
+ panic("parameter indirect must be a slice")
+ }
+ if indirect != nil {
+ indirect_ptr = unsafe.Pointer(indirect_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0compat_glDrawElementsIndirect(gl.funcs, C.GLenum(mode), C.GLenum(gltype), indirect_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawArraysIndirect.xml
+func (gl *GL) DrawArraysIndirect(mode glbase.Enum, indirect interface{}) {
+ var indirect_ptr unsafe.Pointer
+ var indirect_v = reflect.ValueOf(indirect)
+ if indirect != nil && indirect_v.Kind() != reflect.Slice {
+ panic("parameter indirect must be a slice")
+ }
+ if indirect != nil {
+ indirect_ptr = unsafe.Pointer(indirect_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0compat_glDrawArraysIndirect(gl.funcs, C.GLenum(mode), indirect_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendFuncSeparatei.xml
+func (gl *GL) BlendFuncSeparatei(buf uint32, srcRGB, dstRGB, srcAlpha, dstAlpha glbase.Enum) {
+ C.gl4_0compat_glBlendFuncSeparatei(gl.funcs, C.GLuint(buf), C.GLenum(srcRGB), C.GLenum(dstRGB), C.GLenum(srcAlpha), C.GLenum(dstAlpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendFunci.xml
+func (gl *GL) BlendFunci(buf uint32, src, dst glbase.Enum) {
+ C.gl4_0compat_glBlendFunci(gl.funcs, C.GLuint(buf), C.GLenum(src), C.GLenum(dst))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendEquationSeparatei.xml
+func (gl *GL) BlendEquationSeparatei(buf uint32, modeRGB, modeAlpha glbase.Enum) {
+ C.gl4_0compat_glBlendEquationSeparatei(gl.funcs, C.GLuint(buf), C.GLenum(modeRGB), C.GLenum(modeAlpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendEquationi.xml
+func (gl *GL) BlendEquationi(buf uint32, mode glbase.Enum) {
+ C.gl4_0compat_glBlendEquationi(gl.funcs, C.GLuint(buf), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMinSampleShading.xml
+func (gl *GL) MinSampleShading(value float32) {
+ C.gl4_0compat_glMinSampleShading(gl.funcs, C.GLfloat(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTranslatef.xml
+func (gl *GL) Translatef(x, y, z float32) {
+ C.gl4_0compat_glTranslatef(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTranslated.xml
+func (gl *GL) Translated(x, y, z float64) {
+ C.gl4_0compat_glTranslated(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glScalef.xml
+func (gl *GL) Scalef(x, y, z float32) {
+ C.gl4_0compat_glScalef(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glScaled.xml
+func (gl *GL) Scaled(x, y, z float64) {
+ C.gl4_0compat_glScaled(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRotatef.xml
+func (gl *GL) Rotatef(angle, x, y, z float32) {
+ C.gl4_0compat_glRotatef(gl.funcs, C.GLfloat(angle), C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRotated.xml
+func (gl *GL) Rotated(angle, x, y, z float64) {
+ C.gl4_0compat_glRotated(gl.funcs, C.GLdouble(angle), C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPushMatrix.xml
+func (gl *GL) PushMatrix() {
+ C.gl4_0compat_glPushMatrix(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPopMatrix.xml
+func (gl *GL) PopMatrix() {
+ C.gl4_0compat_glPopMatrix(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glOrtho.xml
+func (gl *GL) Ortho(left, right, bottom, top, zNear, zFar float64) {
+ C.gl4_0compat_glOrtho(gl.funcs, C.GLdouble(left), C.GLdouble(right), C.GLdouble(bottom), C.GLdouble(top), C.GLdouble(zNear), C.GLdouble(zFar))
+}
+
+// MultMatrixd multiplies the current matrix with the provided matrix.
+//
+// The m parameter must hold 16 consecutive elements of a 4x4 column-major matrix.
+//
+// The current matrix is determined by the current matrix mode (see
+// MatrixMode). It is either the projection matrix, modelview matrix, or the
+// texture matrix.
+//
+// For example, if the current matrix is C and the coordinates to be transformed
+// are v = (v[0], v[1], v[2], v[3]), then the current transformation is C × v, or
+//
+// c[0] c[4] c[8] c[12] v[0]
+// c[1] c[5] c[9] c[13] v[1]
+// c[2] c[6] c[10] c[14] X v[2]
+// c[3] c[7] c[11] c[15] v[3]
+//
+// Calling MultMatrix with an argument of m = m[0], m[1], ..., m[15]
+// replaces the current transformation with (C X M) x v, or
+//
+// c[0] c[4] c[8] c[12] m[0] m[4] m[8] m[12] v[0]
+// c[1] c[5] c[9] c[13] m[1] m[5] m[9] m[13] v[1]
+// c[2] c[6] c[10] c[14] X m[2] m[6] m[10] m[14] X v[2]
+// c[3] c[7] c[11] c[15] m[3] m[7] m[11] m[15] v[3]
+//
+// Where 'X' denotes matrix multiplication, and v is represented as a 4x1 matrix.
+//
+// While the elements of the matrix may be specified with single or double
+// precision, the GL may store or operate on these values in less-than-single
+// precision.
+//
+// In many computer languages, 4×4 arrays are represented in row-major
+// order. The transformations just described represent these matrices in
+// column-major order. The order of the multiplication is important. For
+// example, if the current transformation is a rotation, and MultMatrix is
+// called with a translation matrix, the translation is done directly on the
+// coordinates to be transformed, while the rotation is done on the results
+// of that translation.
+//
+// GL.INVALID_OPERATION is generated if MultMatrix is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) MultMatrixd(m []float64) {
+ if len(m) != 16 {
+ panic("parameter m must have length 16 for the 4x4 matrix")
+ }
+ C.gl4_0compat_glMultMatrixd(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&m[0])))
+}
+
+// MultMatrixf multiplies the current matrix with the provided matrix.
+//
+// The m parameter must hold 16 consecutive elements of a 4x4 column-major matrix.
+//
+// The current matrix is determined by the current matrix mode (see
+// MatrixMode). It is either the projection matrix, modelview matrix, or the
+// texture matrix.
+//
+// For example, if the current matrix is C and the coordinates to be transformed
+// are v = (v[0], v[1], v[2], v[3]), then the current transformation is C × v, or
+//
+// c[0] c[4] c[8] c[12] v[0]
+// c[1] c[5] c[9] c[13] v[1]
+// c[2] c[6] c[10] c[14] X v[2]
+// c[3] c[7] c[11] c[15] v[3]
+//
+// Calling MultMatrix with an argument of m = m[0], m[1], ..., m[15]
+// replaces the current transformation with (C X M) x v, or
+//
+// c[0] c[4] c[8] c[12] m[0] m[4] m[8] m[12] v[0]
+// c[1] c[5] c[9] c[13] m[1] m[5] m[9] m[13] v[1]
+// c[2] c[6] c[10] c[14] X m[2] m[6] m[10] m[14] X v[2]
+// c[3] c[7] c[11] c[15] m[3] m[7] m[11] m[15] v[3]
+//
+// Where 'X' denotes matrix multiplication, and v is represented as a 4x1 matrix.
+//
+// While the elements of the matrix may be specified with single or double
+// precision, the GL may store or operate on these values in less-than-single
+// precision.
+//
+// In many computer languages, 4×4 arrays are represented in row-major
+// order. The transformations just described represent these matrices in
+// column-major order. The order of the multiplication is important. For
+// example, if the current transformation is a rotation, and MultMatrix is
+// called with a translation matrix, the translation is done directly on the
+// coordinates to be transformed, while the rotation is done on the results
+// of that translation.
+//
+// GL.INVALID_OPERATION is generated if MultMatrix is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) MultMatrixf(m []float32) {
+ if len(m) != 16 {
+ panic("parameter m must have length 16 for the 4x4 matrix")
+ }
+ C.gl4_0compat_glMultMatrixf(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMatrixMode.xml
+func (gl *GL) MatrixMode(mode glbase.Enum) {
+ C.gl4_0compat_glMatrixMode(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLoadMatrixd.xml
+func (gl *GL) LoadMatrixd(m []float64) {
+ C.gl4_0compat_glLoadMatrixd(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLoadMatrixf.xml
+func (gl *GL) LoadMatrixf(m []float32) {
+ C.gl4_0compat_glLoadMatrixf(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLoadIdentity.xml
+func (gl *GL) LoadIdentity() {
+ C.gl4_0compat_glLoadIdentity(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFrustum.xml
+func (gl *GL) Frustum(left, right, bottom, top, zNear, zFar float64) {
+ C.gl4_0compat_glFrustum(gl.funcs, C.GLdouble(left), C.GLdouble(right), C.GLdouble(bottom), C.GLdouble(top), C.GLdouble(zNear), C.GLdouble(zFar))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsList.xml
+func (gl *GL) IsList(list uint32) bool {
+ glresult := C.gl4_0compat_glIsList(gl.funcs, C.GLuint(list))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexGeniv.xml
+func (gl *GL) GetTexGeniv(coord, pname glbase.Enum, params []int32) {
+ C.gl4_0compat_glGetTexGeniv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexGenfv.xml
+func (gl *GL) GetTexGenfv(coord, pname glbase.Enum, params []float32) {
+ C.gl4_0compat_glGetTexGenfv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexGendv.xml
+func (gl *GL) GetTexGendv(coord, pname glbase.Enum, params []float64) {
+ C.gl4_0compat_glGetTexGendv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexEnviv.xml
+func (gl *GL) GetTexEnviv(target, pname glbase.Enum, params []int32) {
+ C.gl4_0compat_glGetTexEnviv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexEnvfv.xml
+func (gl *GL) GetTexEnvfv(target, pname glbase.Enum, params []float32) {
+ C.gl4_0compat_glGetTexEnvfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetPolygonStipple.xml
+func (gl *GL) GetPolygonStipple(mask []uint8) {
+ C.gl4_0compat_glGetPolygonStipple(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&mask[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetPixelMapusv.xml
+func (gl *GL) GetPixelMapusv(glmap glbase.Enum, values []uint16) {
+ C.gl4_0compat_glGetPixelMapusv(gl.funcs, C.GLenum(glmap), (*C.GLushort)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetPixelMapuiv.xml
+func (gl *GL) GetPixelMapuiv(glmap glbase.Enum, values []uint32) {
+ C.gl4_0compat_glGetPixelMapuiv(gl.funcs, C.GLenum(glmap), (*C.GLuint)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetPixelMapfv.xml
+func (gl *GL) GetPixelMapfv(glmap glbase.Enum, values []float32) {
+ C.gl4_0compat_glGetPixelMapfv(gl.funcs, C.GLenum(glmap), (*C.GLfloat)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetMaterialiv.xml
+func (gl *GL) GetMaterialiv(face, pname glbase.Enum, params []int32) {
+ C.gl4_0compat_glGetMaterialiv(gl.funcs, C.GLenum(face), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetMaterialfv.xml
+func (gl *GL) GetMaterialfv(face, pname glbase.Enum, params []float32) {
+ C.gl4_0compat_glGetMaterialfv(gl.funcs, C.GLenum(face), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetMapiv.xml
+func (gl *GL) GetMapiv(target, query glbase.Enum, v []int32) {
+ C.gl4_0compat_glGetMapiv(gl.funcs, C.GLenum(target), C.GLenum(query), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetMapfv.xml
+func (gl *GL) GetMapfv(target, query glbase.Enum, v []float32) {
+ C.gl4_0compat_glGetMapfv(gl.funcs, C.GLenum(target), C.GLenum(query), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetMapdv.xml
+func (gl *GL) GetMapdv(target, query glbase.Enum, v []float64) {
+ C.gl4_0compat_glGetMapdv(gl.funcs, C.GLenum(target), C.GLenum(query), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetLightiv.xml
+func (gl *GL) GetLightiv(light, pname glbase.Enum, params []int32) {
+ C.gl4_0compat_glGetLightiv(gl.funcs, C.GLenum(light), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetLightfv.xml
+func (gl *GL) GetLightfv(light, pname glbase.Enum, params []float32) {
+ C.gl4_0compat_glGetLightfv(gl.funcs, C.GLenum(light), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetClipPlane.xml
+func (gl *GL) GetClipPlane(plane glbase.Enum, equation []float64) {
+ C.gl4_0compat_glGetClipPlane(gl.funcs, C.GLenum(plane), (*C.GLdouble)(unsafe.Pointer(&equation[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawPixels.xml
+func (gl *GL) DrawPixels(width, height int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0compat_glDrawPixels(gl.funcs, C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyPixels.xml
+func (gl *GL) CopyPixels(x, y, width, height int, gltype glbase.Enum) {
+ C.gl4_0compat_glCopyPixels(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height), C.GLenum(gltype))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPixelMapusv.xml
+func (gl *GL) PixelMapusv(glmap glbase.Enum, mapsize int32, values []uint16) {
+ C.gl4_0compat_glPixelMapusv(gl.funcs, C.GLenum(glmap), C.GLint(mapsize), (*C.GLushort)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPixelMapuiv.xml
+func (gl *GL) PixelMapuiv(glmap glbase.Enum, mapsize int32, values []uint32) {
+ C.gl4_0compat_glPixelMapuiv(gl.funcs, C.GLenum(glmap), C.GLint(mapsize), (*C.GLuint)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPixelMapfv.xml
+func (gl *GL) PixelMapfv(glmap glbase.Enum, mapsize int32, values []float32) {
+ C.gl4_0compat_glPixelMapfv(gl.funcs, C.GLenum(glmap), C.GLint(mapsize), (*C.GLfloat)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPixelTransferi.xml
+func (gl *GL) PixelTransferi(pname glbase.Enum, param int32) {
+ C.gl4_0compat_glPixelTransferi(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPixelTransferf.xml
+func (gl *GL) PixelTransferf(pname glbase.Enum, param float32) {
+ C.gl4_0compat_glPixelTransferf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPixelZoom.xml
+func (gl *GL) PixelZoom(xfactor, yfactor float32) {
+ C.gl4_0compat_glPixelZoom(gl.funcs, C.GLfloat(xfactor), C.GLfloat(yfactor))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glAlphaFunc.xml
+func (gl *GL) AlphaFunc(glfunc glbase.Enum, ref float32) {
+ C.gl4_0compat_glAlphaFunc(gl.funcs, C.GLenum(glfunc), C.GLfloat(ref))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEvalPoint2.xml
+func (gl *GL) EvalPoint2(i, j int32) {
+ C.gl4_0compat_glEvalPoint2(gl.funcs, C.GLint(i), C.GLint(j))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEvalMesh2.xml
+func (gl *GL) EvalMesh2(mode glbase.Enum, i1, i2, j1, j2 int32) {
+ C.gl4_0compat_glEvalMesh2(gl.funcs, C.GLenum(mode), C.GLint(i1), C.GLint(i2), C.GLint(j1), C.GLint(j2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEvalPoint1.xml
+func (gl *GL) EvalPoint1(i int32) {
+ C.gl4_0compat_glEvalPoint1(gl.funcs, C.GLint(i))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEvalMesh1.xml
+func (gl *GL) EvalMesh1(mode glbase.Enum, i1, i2 int32) {
+ C.gl4_0compat_glEvalMesh1(gl.funcs, C.GLenum(mode), C.GLint(i1), C.GLint(i2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEvalCoord2fv.xml
+func (gl *GL) EvalCoord2fv(u []float32) {
+ if len(u) != 2 {
+ panic("parameter u has incorrect length")
+ }
+ C.gl4_0compat_glEvalCoord2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&u[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEvalCoord2f.xml
+func (gl *GL) EvalCoord2f(u, v float32) {
+ C.gl4_0compat_glEvalCoord2f(gl.funcs, C.GLfloat(u), C.GLfloat(v))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEvalCoord2dv.xml
+func (gl *GL) EvalCoord2dv(u []float64) {
+ if len(u) != 2 {
+ panic("parameter u has incorrect length")
+ }
+ C.gl4_0compat_glEvalCoord2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&u[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEvalCoord2d.xml
+func (gl *GL) EvalCoord2d(u, v float64) {
+ C.gl4_0compat_glEvalCoord2d(gl.funcs, C.GLdouble(u), C.GLdouble(v))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEvalCoord1fv.xml
+func (gl *GL) EvalCoord1fv(u []float32) {
+ C.gl4_0compat_glEvalCoord1fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&u[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEvalCoord1f.xml
+func (gl *GL) EvalCoord1f(u float32) {
+ C.gl4_0compat_glEvalCoord1f(gl.funcs, C.GLfloat(u))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEvalCoord1dv.xml
+func (gl *GL) EvalCoord1dv(u []float64) {
+ C.gl4_0compat_glEvalCoord1dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&u[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEvalCoord1d.xml
+func (gl *GL) EvalCoord1d(u float64) {
+ C.gl4_0compat_glEvalCoord1d(gl.funcs, C.GLdouble(u))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMapGrid2f.xml
+func (gl *GL) MapGrid2f(un int32, u1, u2 float32, vn int32, v1, v2 float32) {
+ C.gl4_0compat_glMapGrid2f(gl.funcs, C.GLint(un), C.GLfloat(u1), C.GLfloat(u2), C.GLint(vn), C.GLfloat(v1), C.GLfloat(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMapGrid2d.xml
+func (gl *GL) MapGrid2d(un int32, u1, u2 float64, vn int32, v1, v2 float64) {
+ C.gl4_0compat_glMapGrid2d(gl.funcs, C.GLint(un), C.GLdouble(u1), C.GLdouble(u2), C.GLint(vn), C.GLdouble(v1), C.GLdouble(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMapGrid1f.xml
+func (gl *GL) MapGrid1f(un int32, u1, u2 float32) {
+ C.gl4_0compat_glMapGrid1f(gl.funcs, C.GLint(un), C.GLfloat(u1), C.GLfloat(u2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMapGrid1d.xml
+func (gl *GL) MapGrid1d(un int32, u1, u2 float64) {
+ C.gl4_0compat_glMapGrid1d(gl.funcs, C.GLint(un), C.GLdouble(u1), C.GLdouble(u2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMap2f.xml
+func (gl *GL) Map2f(target glbase.Enum, u1, u2 float32, ustride, uorder int32, v1, v2 float32, vstride, vorder int32, points []float32) {
+ C.gl4_0compat_glMap2f(gl.funcs, C.GLenum(target), C.GLfloat(u1), C.GLfloat(u2), C.GLint(ustride), C.GLint(uorder), C.GLfloat(v1), C.GLfloat(v2), C.GLint(vstride), C.GLint(vorder), (*C.GLfloat)(unsafe.Pointer(&points[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMap2d.xml
+func (gl *GL) Map2d(target glbase.Enum, u1, u2 float64, ustride, uorder int32, v1, v2 float64, vstride, vorder int32, points []float64) {
+ C.gl4_0compat_glMap2d(gl.funcs, C.GLenum(target), C.GLdouble(u1), C.GLdouble(u2), C.GLint(ustride), C.GLint(uorder), C.GLdouble(v1), C.GLdouble(v2), C.GLint(vstride), C.GLint(vorder), (*C.GLdouble)(unsafe.Pointer(&points[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMap1f.xml
+func (gl *GL) Map1f(target glbase.Enum, u1, u2 float32, stride, order int, points []float32) {
+ C.gl4_0compat_glMap1f(gl.funcs, C.GLenum(target), C.GLfloat(u1), C.GLfloat(u2), C.GLint(stride), C.GLint(order), (*C.GLfloat)(unsafe.Pointer(&points[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMap1d.xml
+func (gl *GL) Map1d(target glbase.Enum, u1, u2 float64, stride, order int, points []float64) {
+ C.gl4_0compat_glMap1d(gl.funcs, C.GLenum(target), C.GLdouble(u1), C.GLdouble(u2), C.GLint(stride), C.GLint(order), (*C.GLdouble)(unsafe.Pointer(&points[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPushAttrib.xml
+func (gl *GL) PushAttrib(mask glbase.Bitfield) {
+ C.gl4_0compat_glPushAttrib(gl.funcs, C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPopAttrib.xml
+func (gl *GL) PopAttrib() {
+ C.gl4_0compat_glPopAttrib(gl.funcs)
+}
+
+// Accum executes an operation on the accumulation buffer.
+//
+// Parameter op defines the accumulation buffer operation (GL.ACCUM, GL.LOAD,
+// GL.ADD, GL.MULT, or GL.RETURN) and specifies how the value parameter is
+// used.
+//
+// The accumulation buffer is an extended-range color buffer. Images are not
+// rendered into it. Rather, images rendered into one of the color buffers
+// are added to the contents of the accumulation buffer after rendering.
+// Effects such as antialiasing (of points, lines, and polygons), motion
+// blur, and depth of field can be created by accumulating images generated
+// with different transformation matrices.
+//
+// Each pixel in the accumulation buffer consists of red, green, blue, and
+// alpha values. The number of bits per component in the accumulation buffer
+// depends on the implementation. You can examine this number by calling
+// GetIntegerv four times, with arguments GL.ACCUM_RED_BITS,
+// GL.ACCUM_GREEN_BITS, GL.ACCUM_BLUE_BITS, and GL.ACCUM_ALPHA_BITS.
+// Regardless of the number of bits per component, the range of values stored
+// by each component is (-1, 1). The accumulation buffer pixels are mapped
+// one-to-one with frame buffer pixels.
+//
+// All accumulation buffer operations are limited to the area of the current
+// scissor box and applied identically to the red, green, blue, and alpha
+// components of each pixel. If a Accum operation results in a value outside
+// the range (-1, 1), the contents of an accumulation buffer pixel component
+// are undefined.
+//
+// The operations are as follows:
+//
+// GL.ACCUM
+// Obtains R, G, B, and A values from the buffer currently selected for
+// reading (see ReadBuffer). Each component value is divided by 2 n -
+// 1 , where n is the number of bits allocated to each color component
+// in the currently selected buffer. The result is a floating-point
+// value in the range 0 1 , which is multiplied by value and added to
+// the corresponding pixel component in the accumulation buffer,
+// thereby updating the accumulation buffer.
+//
+// GL.LOAD
+// Similar to GL.ACCUM, except that the current value in the
+// accumulation buffer is not used in the calculation of the new value.
+// That is, the R, G, B, and A values from the currently selected
+// buffer are divided by 2 n - 1 , multiplied by value, and then stored
+// in the corresponding accumulation buffer cell, overwriting the
+// current value.
+//
+// GL.ADD
+// Adds value to each R, G, B, and A in the accumulation buffer.
+//
+// GL.MULT
+// Multiplies each R, G, B, and A in the accumulation buffer by value
+// and returns the scaled component to its corresponding accumulation
+// buffer location.
+//
+// GL.RETURN
+// Transfers accumulation buffer values to the color buffer or buffers
+// currently selected for writing. Each R, G, B, and A component is
+// multiplied by value, then multiplied by 2 n - 1 , clamped to the
+// range 0 2 n - 1 , and stored in the corresponding display buffer
+// cell. The only fragment operations that are applied to this transfer
+// are pixel ownership, scissor, dithering, and color writemasks.
+//
+// To clear the accumulation buffer, call ClearAccum with R, G, B, and A
+// values to set it to, then call Clear with the accumulation buffer
+// enabled.
+//
+// Error GL.INVALID_ENUM is generated if op is not an accepted value.
+// GL.INVALID_OPERATION is generated if there is no accumulation buffer.
+// GL.INVALID_OPERATION is generated if Accum is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) Accum(op glbase.Enum, value float32) {
+ C.gl4_0compat_glAccum(gl.funcs, C.GLenum(op), C.GLfloat(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIndexMask.xml
+func (gl *GL) IndexMask(mask uint32) {
+ C.gl4_0compat_glIndexMask(gl.funcs, C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearIndex.xml
+func (gl *GL) ClearIndex(c float32) {
+ C.gl4_0compat_glClearIndex(gl.funcs, C.GLfloat(c))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearAccum.xml
+func (gl *GL) ClearAccum(red, green, blue, alpha float32) {
+ C.gl4_0compat_glClearAccum(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPushName.xml
+func (gl *GL) PushName(name uint32) {
+ C.gl4_0compat_glPushName(gl.funcs, C.GLuint(name))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPopName.xml
+func (gl *GL) PopName() {
+ C.gl4_0compat_glPopName(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPassThrough.xml
+func (gl *GL) PassThrough(token float32) {
+ C.gl4_0compat_glPassThrough(gl.funcs, C.GLfloat(token))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLoadName.xml
+func (gl *GL) LoadName(name uint32) {
+ C.gl4_0compat_glLoadName(gl.funcs, C.GLuint(name))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glInitNames.xml
+func (gl *GL) InitNames() {
+ C.gl4_0compat_glInitNames(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRenderMode.xml
+func (gl *GL) RenderMode(mode glbase.Enum) int32 {
+ glresult := C.gl4_0compat_glRenderMode(gl.funcs, C.GLenum(mode))
+ return int32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSelectBuffer.xml
+func (gl *GL) SelectBuffer(size int, buffer []glbase.Buffer) {
+ C.gl4_0compat_glSelectBuffer(gl.funcs, C.GLsizei(size), (*C.GLuint)(unsafe.Pointer(&buffer[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFeedbackBuffer.xml
+func (gl *GL) FeedbackBuffer(size int, gltype glbase.Enum, buffer []float32) {
+ C.gl4_0compat_glFeedbackBuffer(gl.funcs, C.GLsizei(size), C.GLenum(gltype), (*C.GLfloat)(unsafe.Pointer(&buffer[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexGeniv.xml
+func (gl *GL) TexGeniv(coord, pname glbase.Enum, params []int32) {
+ C.gl4_0compat_glTexGeniv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexGeni.xml
+func (gl *GL) TexGeni(coord, pname glbase.Enum, param int32) {
+ C.gl4_0compat_glTexGeni(gl.funcs, C.GLenum(coord), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexGenfv.xml
+func (gl *GL) TexGenfv(coord, pname glbase.Enum, params []float32) {
+ C.gl4_0compat_glTexGenfv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexGenf.xml
+func (gl *GL) TexGenf(coord, pname glbase.Enum, param float32) {
+ C.gl4_0compat_glTexGenf(gl.funcs, C.GLenum(coord), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexGendv.xml
+func (gl *GL) TexGendv(coord, pname glbase.Enum, params []float64) {
+ C.gl4_0compat_glTexGendv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexGend.xml
+func (gl *GL) TexGend(coord, pname glbase.Enum, param float64) {
+ C.gl4_0compat_glTexGend(gl.funcs, C.GLenum(coord), C.GLenum(pname), C.GLdouble(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexEnviv.xml
+func (gl *GL) TexEnviv(target, pname glbase.Enum, params []int32) {
+ C.gl4_0compat_glTexEnviv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexEnvi.xml
+func (gl *GL) TexEnvi(target, pname glbase.Enum, param int32) {
+ C.gl4_0compat_glTexEnvi(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexEnvfv.xml
+func (gl *GL) TexEnvfv(target, pname glbase.Enum, params []float32) {
+ C.gl4_0compat_glTexEnvfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexEnvf.xml
+func (gl *GL) TexEnvf(target, pname glbase.Enum, param float32) {
+ C.gl4_0compat_glTexEnvf(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glShadeModel.xml
+func (gl *GL) ShadeModel(mode glbase.Enum) {
+ C.gl4_0compat_glShadeModel(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPolygonStipple.xml
+func (gl *GL) PolygonStipple(mask []uint8) {
+ C.gl4_0compat_glPolygonStipple(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&mask[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMaterialiv.xml
+func (gl *GL) Materialiv(face, pname glbase.Enum, params []int32) {
+ C.gl4_0compat_glMaterialiv(gl.funcs, C.GLenum(face), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMateriali.xml
+func (gl *GL) Materiali(face, pname glbase.Enum, param int32) {
+ C.gl4_0compat_glMateriali(gl.funcs, C.GLenum(face), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMaterialfv.xml
+func (gl *GL) Materialfv(face, pname glbase.Enum, params []float32) {
+ C.gl4_0compat_glMaterialfv(gl.funcs, C.GLenum(face), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMaterialf.xml
+func (gl *GL) Materialf(face, pname glbase.Enum, param float32) {
+ C.gl4_0compat_glMaterialf(gl.funcs, C.GLenum(face), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLineStipple.xml
+func (gl *GL) LineStipple(factor int32, pattern uint16) {
+ C.gl4_0compat_glLineStipple(gl.funcs, C.GLint(factor), C.GLushort(pattern))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLightModeliv.xml
+func (gl *GL) LightModeliv(pname glbase.Enum, params []int32) {
+ C.gl4_0compat_glLightModeliv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLightModeli.xml
+func (gl *GL) LightModeli(pname glbase.Enum, param int32) {
+ C.gl4_0compat_glLightModeli(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLightModelfv.xml
+func (gl *GL) LightModelfv(pname glbase.Enum, params []float32) {
+ C.gl4_0compat_glLightModelfv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLightModelf.xml
+func (gl *GL) LightModelf(pname glbase.Enum, param float32) {
+ C.gl4_0compat_glLightModelf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLightiv.xml
+func (gl *GL) Lightiv(light, pname glbase.Enum, params []int32) {
+ C.gl4_0compat_glLightiv(gl.funcs, C.GLenum(light), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLighti.xml
+func (gl *GL) Lighti(light, pname glbase.Enum, param int32) {
+ C.gl4_0compat_glLighti(gl.funcs, C.GLenum(light), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLightfv.xml
+func (gl *GL) Lightfv(light, pname glbase.Enum, params []float32) {
+ C.gl4_0compat_glLightfv(gl.funcs, C.GLenum(light), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLightf.xml
+func (gl *GL) Lightf(light, pname glbase.Enum, param float32) {
+ C.gl4_0compat_glLightf(gl.funcs, C.GLenum(light), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFogiv.xml
+func (gl *GL) Fogiv(pname glbase.Enum, params []int32) {
+ C.gl4_0compat_glFogiv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFogi.xml
+func (gl *GL) Fogi(pname glbase.Enum, param int32) {
+ C.gl4_0compat_glFogi(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFogfv.xml
+func (gl *GL) Fogfv(pname glbase.Enum, params []float32) {
+ C.gl4_0compat_glFogfv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFogf.xml
+func (gl *GL) Fogf(pname glbase.Enum, param float32) {
+ C.gl4_0compat_glFogf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorMaterial.xml
+func (gl *GL) ColorMaterial(face, mode glbase.Enum) {
+ C.gl4_0compat_glColorMaterial(gl.funcs, C.GLenum(face), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClipPlane.xml
+func (gl *GL) ClipPlane(plane glbase.Enum, equation []float64) {
+ C.gl4_0compat_glClipPlane(gl.funcs, C.GLenum(plane), (*C.GLdouble)(unsafe.Pointer(&equation[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex4sv.xml
+func (gl *GL) Vertex4sv(v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glVertex4sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex4s.xml
+func (gl *GL) Vertex4s(x, y, z, w int16) {
+ C.gl4_0compat_glVertex4s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z), C.GLshort(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex4iv.xml
+func (gl *GL) Vertex4iv(v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glVertex4iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex4i.xml
+func (gl *GL) Vertex4i(x, y, z, w int) {
+ C.gl4_0compat_glVertex4i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z), C.GLint(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex4fv.xml
+func (gl *GL) Vertex4fv(v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glVertex4fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex4f.xml
+func (gl *GL) Vertex4f(x, y, z, w float32) {
+ C.gl4_0compat_glVertex4f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z), C.GLfloat(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex4dv.xml
+func (gl *GL) Vertex4dv(v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glVertex4dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex4d.xml
+func (gl *GL) Vertex4d(x, y, z, w float64) {
+ C.gl4_0compat_glVertex4d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z), C.GLdouble(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex3sv.xml
+func (gl *GL) Vertex3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glVertex3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex3s.xml
+func (gl *GL) Vertex3s(x, y, z int16) {
+ C.gl4_0compat_glVertex3s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex3iv.xml
+func (gl *GL) Vertex3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glVertex3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex3i.xml
+func (gl *GL) Vertex3i(x, y, z int) {
+ C.gl4_0compat_glVertex3i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex3fv.xml
+func (gl *GL) Vertex3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glVertex3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex3f.xml
+func (gl *GL) Vertex3f(x, y, z float32) {
+ C.gl4_0compat_glVertex3f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex3dv.xml
+func (gl *GL) Vertex3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glVertex3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex3d.xml
+func (gl *GL) Vertex3d(x, y, z float64) {
+ C.gl4_0compat_glVertex3d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex2sv.xml
+func (gl *GL) Vertex2sv(v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glVertex2sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex2s.xml
+func (gl *GL) Vertex2s(x, y int16) {
+ C.gl4_0compat_glVertex2s(gl.funcs, C.GLshort(x), C.GLshort(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex2iv.xml
+func (gl *GL) Vertex2iv(v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glVertex2iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex2i.xml
+func (gl *GL) Vertex2i(x, y int) {
+ C.gl4_0compat_glVertex2i(gl.funcs, C.GLint(x), C.GLint(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex2fv.xml
+func (gl *GL) Vertex2fv(v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glVertex2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex2f.xml
+func (gl *GL) Vertex2f(x, y float32) {
+ C.gl4_0compat_glVertex2f(gl.funcs, C.GLfloat(x), C.GLfloat(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex2dv.xml
+func (gl *GL) Vertex2dv(v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glVertex2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex2d.xml
+func (gl *GL) Vertex2d(x, y float64) {
+ C.gl4_0compat_glVertex2d(gl.funcs, C.GLdouble(x), C.GLdouble(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord4sv.xml
+func (gl *GL) TexCoord4sv(v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glTexCoord4sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord4s.xml
+func (gl *GL) TexCoord4s(s, t, r, q int16) {
+ C.gl4_0compat_glTexCoord4s(gl.funcs, C.GLshort(s), C.GLshort(t), C.GLshort(r), C.GLshort(q))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord4iv.xml
+func (gl *GL) TexCoord4iv(v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glTexCoord4iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord4i.xml
+func (gl *GL) TexCoord4i(s, t, r, q int32) {
+ C.gl4_0compat_glTexCoord4i(gl.funcs, C.GLint(s), C.GLint(t), C.GLint(r), C.GLint(q))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord4fv.xml
+func (gl *GL) TexCoord4fv(v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glTexCoord4fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord4f.xml
+func (gl *GL) TexCoord4f(s, t, r, q float32) {
+ C.gl4_0compat_glTexCoord4f(gl.funcs, C.GLfloat(s), C.GLfloat(t), C.GLfloat(r), C.GLfloat(q))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord4dv.xml
+func (gl *GL) TexCoord4dv(v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glTexCoord4dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord4d.xml
+func (gl *GL) TexCoord4d(s, t, r, q float64) {
+ C.gl4_0compat_glTexCoord4d(gl.funcs, C.GLdouble(s), C.GLdouble(t), C.GLdouble(r), C.GLdouble(q))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord3sv.xml
+func (gl *GL) TexCoord3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glTexCoord3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord3s.xml
+func (gl *GL) TexCoord3s(s, t, r int16) {
+ C.gl4_0compat_glTexCoord3s(gl.funcs, C.GLshort(s), C.GLshort(t), C.GLshort(r))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord3iv.xml
+func (gl *GL) TexCoord3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glTexCoord3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord3i.xml
+func (gl *GL) TexCoord3i(s, t, r int32) {
+ C.gl4_0compat_glTexCoord3i(gl.funcs, C.GLint(s), C.GLint(t), C.GLint(r))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord3fv.xml
+func (gl *GL) TexCoord3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glTexCoord3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord3f.xml
+func (gl *GL) TexCoord3f(s, t, r float32) {
+ C.gl4_0compat_glTexCoord3f(gl.funcs, C.GLfloat(s), C.GLfloat(t), C.GLfloat(r))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord3dv.xml
+func (gl *GL) TexCoord3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glTexCoord3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord3d.xml
+func (gl *GL) TexCoord3d(s, t, r float64) {
+ C.gl4_0compat_glTexCoord3d(gl.funcs, C.GLdouble(s), C.GLdouble(t), C.GLdouble(r))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord2sv.xml
+func (gl *GL) TexCoord2sv(v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glTexCoord2sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord2s.xml
+func (gl *GL) TexCoord2s(s, t int16) {
+ C.gl4_0compat_glTexCoord2s(gl.funcs, C.GLshort(s), C.GLshort(t))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord2iv.xml
+func (gl *GL) TexCoord2iv(v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glTexCoord2iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord2i.xml
+func (gl *GL) TexCoord2i(s, t int32) {
+ C.gl4_0compat_glTexCoord2i(gl.funcs, C.GLint(s), C.GLint(t))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord2fv.xml
+func (gl *GL) TexCoord2fv(v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glTexCoord2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord2f.xml
+func (gl *GL) TexCoord2f(s, t float32) {
+ C.gl4_0compat_glTexCoord2f(gl.funcs, C.GLfloat(s), C.GLfloat(t))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord2dv.xml
+func (gl *GL) TexCoord2dv(v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glTexCoord2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord2d.xml
+func (gl *GL) TexCoord2d(s, t float64) {
+ C.gl4_0compat_glTexCoord2d(gl.funcs, C.GLdouble(s), C.GLdouble(t))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord1sv.xml
+func (gl *GL) TexCoord1sv(v []int16) {
+ C.gl4_0compat_glTexCoord1sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord1s.xml
+func (gl *GL) TexCoord1s(s int16) {
+ C.gl4_0compat_glTexCoord1s(gl.funcs, C.GLshort(s))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord1iv.xml
+func (gl *GL) TexCoord1iv(v []int32) {
+ C.gl4_0compat_glTexCoord1iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord1i.xml
+func (gl *GL) TexCoord1i(s int32) {
+ C.gl4_0compat_glTexCoord1i(gl.funcs, C.GLint(s))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord1fv.xml
+func (gl *GL) TexCoord1fv(v []float32) {
+ C.gl4_0compat_glTexCoord1fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord1f.xml
+func (gl *GL) TexCoord1f(s float32) {
+ C.gl4_0compat_glTexCoord1f(gl.funcs, C.GLfloat(s))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord1dv.xml
+func (gl *GL) TexCoord1dv(v []float64) {
+ C.gl4_0compat_glTexCoord1dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord1d.xml
+func (gl *GL) TexCoord1d(s float64) {
+ C.gl4_0compat_glTexCoord1d(gl.funcs, C.GLdouble(s))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRectsv.xml
+func (gl *GL) Rectsv(v1, v2 []int16) {
+ C.gl4_0compat_glRectsv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v1[0])), (*C.GLshort)(unsafe.Pointer(&v2[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRects.xml
+func (gl *GL) Rects(x1, y1, x2, y2 int16) {
+ C.gl4_0compat_glRects(gl.funcs, C.GLshort(x1), C.GLshort(y1), C.GLshort(x2), C.GLshort(y2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRectiv.xml
+func (gl *GL) Rectiv(v1, v2 []int32) {
+ C.gl4_0compat_glRectiv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v1[0])), (*C.GLint)(unsafe.Pointer(&v2[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRecti.xml
+func (gl *GL) Recti(x1, y1, x2, y2 int32) {
+ C.gl4_0compat_glRecti(gl.funcs, C.GLint(x1), C.GLint(y1), C.GLint(x2), C.GLint(y2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRectfv.xml
+func (gl *GL) Rectfv(v1, v2 []float32) {
+ C.gl4_0compat_glRectfv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v1[0])), (*C.GLfloat)(unsafe.Pointer(&v2[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRectf.xml
+func (gl *GL) Rectf(x1, y1, x2, y2 float32) {
+ C.gl4_0compat_glRectf(gl.funcs, C.GLfloat(x1), C.GLfloat(y1), C.GLfloat(x2), C.GLfloat(y2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRectdv.xml
+func (gl *GL) Rectdv(v1, v2 []float64) {
+ C.gl4_0compat_glRectdv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v1[0])), (*C.GLdouble)(unsafe.Pointer(&v2[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRectd.xml
+func (gl *GL) Rectd(x1, y1, x2, y2 float64) {
+ C.gl4_0compat_glRectd(gl.funcs, C.GLdouble(x1), C.GLdouble(y1), C.GLdouble(x2), C.GLdouble(y2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos4sv.xml
+func (gl *GL) RasterPos4sv(v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glRasterPos4sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos4s.xml
+func (gl *GL) RasterPos4s(x, y, z, w int16) {
+ C.gl4_0compat_glRasterPos4s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z), C.GLshort(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos4iv.xml
+func (gl *GL) RasterPos4iv(v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glRasterPos4iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos4i.xml
+func (gl *GL) RasterPos4i(x, y, z, w int) {
+ C.gl4_0compat_glRasterPos4i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z), C.GLint(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos4fv.xml
+func (gl *GL) RasterPos4fv(v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glRasterPos4fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos4f.xml
+func (gl *GL) RasterPos4f(x, y, z, w float32) {
+ C.gl4_0compat_glRasterPos4f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z), C.GLfloat(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos4dv.xml
+func (gl *GL) RasterPos4dv(v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glRasterPos4dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos4d.xml
+func (gl *GL) RasterPos4d(x, y, z, w float64) {
+ C.gl4_0compat_glRasterPos4d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z), C.GLdouble(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos3sv.xml
+func (gl *GL) RasterPos3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glRasterPos3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos3s.xml
+func (gl *GL) RasterPos3s(x, y, z int16) {
+ C.gl4_0compat_glRasterPos3s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos3iv.xml
+func (gl *GL) RasterPos3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glRasterPos3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos3i.xml
+func (gl *GL) RasterPos3i(x, y, z int) {
+ C.gl4_0compat_glRasterPos3i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos3fv.xml
+func (gl *GL) RasterPos3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glRasterPos3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos3f.xml
+func (gl *GL) RasterPos3f(x, y, z float32) {
+ C.gl4_0compat_glRasterPos3f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos3dv.xml
+func (gl *GL) RasterPos3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glRasterPos3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos3d.xml
+func (gl *GL) RasterPos3d(x, y, z float64) {
+ C.gl4_0compat_glRasterPos3d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos2sv.xml
+func (gl *GL) RasterPos2sv(v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glRasterPos2sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos2s.xml
+func (gl *GL) RasterPos2s(x, y int16) {
+ C.gl4_0compat_glRasterPos2s(gl.funcs, C.GLshort(x), C.GLshort(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos2iv.xml
+func (gl *GL) RasterPos2iv(v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glRasterPos2iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos2i.xml
+func (gl *GL) RasterPos2i(x, y int) {
+ C.gl4_0compat_glRasterPos2i(gl.funcs, C.GLint(x), C.GLint(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos2fv.xml
+func (gl *GL) RasterPos2fv(v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glRasterPos2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos2f.xml
+func (gl *GL) RasterPos2f(x, y float32) {
+ C.gl4_0compat_glRasterPos2f(gl.funcs, C.GLfloat(x), C.GLfloat(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos2dv.xml
+func (gl *GL) RasterPos2dv(v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glRasterPos2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos2d.xml
+func (gl *GL) RasterPos2d(x, y float64) {
+ C.gl4_0compat_glRasterPos2d(gl.funcs, C.GLdouble(x), C.GLdouble(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNormal3sv.xml
+func (gl *GL) Normal3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glNormal3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNormal3s.xml
+func (gl *GL) Normal3s(nx, ny, nz int16) {
+ C.gl4_0compat_glNormal3s(gl.funcs, C.GLshort(nx), C.GLshort(ny), C.GLshort(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNormal3iv.xml
+func (gl *GL) Normal3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glNormal3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNormal3i.xml
+func (gl *GL) Normal3i(nx, ny, nz int32) {
+ C.gl4_0compat_glNormal3i(gl.funcs, C.GLint(nx), C.GLint(ny), C.GLint(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNormal3fv.xml
+func (gl *GL) Normal3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glNormal3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNormal3f.xml
+func (gl *GL) Normal3f(nx, ny, nz float32) {
+ C.gl4_0compat_glNormal3f(gl.funcs, C.GLfloat(nx), C.GLfloat(ny), C.GLfloat(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNormal3dv.xml
+func (gl *GL) Normal3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glNormal3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNormal3d.xml
+func (gl *GL) Normal3d(nx, ny, nz float64) {
+ C.gl4_0compat_glNormal3d(gl.funcs, C.GLdouble(nx), C.GLdouble(ny), C.GLdouble(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNormal3bv.xml
+func (gl *GL) Normal3bv(v []byte) {
+ C.gl4_0compat_glNormal3bv(gl.funcs, (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNormal3b.xml
+func (gl *GL) Normal3b(nx, ny, nz byte) {
+ C.gl4_0compat_glNormal3b(gl.funcs, C.GLbyte(nx), C.GLbyte(ny), C.GLbyte(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIndexsv.xml
+func (gl *GL) Indexsv(c []int16) {
+ C.gl4_0compat_glIndexsv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIndexs.xml
+func (gl *GL) Indexs(c int16) {
+ C.gl4_0compat_glIndexs(gl.funcs, C.GLshort(c))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIndexiv.xml
+func (gl *GL) Indexiv(c []int32) {
+ C.gl4_0compat_glIndexiv(gl.funcs, (*C.GLint)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIndexi.xml
+func (gl *GL) Indexi(c int32) {
+ C.gl4_0compat_glIndexi(gl.funcs, C.GLint(c))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIndexfv.xml
+func (gl *GL) Indexfv(c []float32) {
+ C.gl4_0compat_glIndexfv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIndexf.xml
+func (gl *GL) Indexf(c float32) {
+ C.gl4_0compat_glIndexf(gl.funcs, C.GLfloat(c))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIndexdv.xml
+func (gl *GL) Indexdv(c []float64) {
+ C.gl4_0compat_glIndexdv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIndexd.xml
+func (gl *GL) Indexd(c float64) {
+ C.gl4_0compat_glIndexd(gl.funcs, C.GLdouble(c))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEnd.xml
+func (gl *GL) End() {
+ C.gl4_0compat_glEnd(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEdgeFlagv.xml
+func (gl *GL) EdgeFlagv(flag []bool) {
+ C.gl4_0compat_glEdgeFlagv(gl.funcs, (*C.GLboolean)(unsafe.Pointer(&flag[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEdgeFlag.xml
+func (gl *GL) EdgeFlag(flag bool) {
+ C.gl4_0compat_glEdgeFlag(gl.funcs, *(*C.GLboolean)(unsafe.Pointer(&flag)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4usv.xml
+func (gl *GL) Color4usv(v []uint16) {
+ C.gl4_0compat_glColor4usv(gl.funcs, (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4us.xml
+func (gl *GL) Color4us(red, green, blue, alpha uint16) {
+ C.gl4_0compat_glColor4us(gl.funcs, C.GLushort(red), C.GLushort(green), C.GLushort(blue), C.GLushort(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4uiv.xml
+func (gl *GL) Color4uiv(v []uint32) {
+ C.gl4_0compat_glColor4uiv(gl.funcs, (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4ui.xml
+func (gl *GL) Color4ui(red, green, blue, alpha uint32) {
+ C.gl4_0compat_glColor4ui(gl.funcs, C.GLuint(red), C.GLuint(green), C.GLuint(blue), C.GLuint(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4ubv.xml
+func (gl *GL) Color4ubv(v []uint8) {
+ C.gl4_0compat_glColor4ubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4ub.xml
+func (gl *GL) Color4ub(red, green, blue, alpha uint8) {
+ C.gl4_0compat_glColor4ub(gl.funcs, C.GLubyte(red), C.GLubyte(green), C.GLubyte(blue), C.GLubyte(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4sv.xml
+func (gl *GL) Color4sv(v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glColor4sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4s.xml
+func (gl *GL) Color4s(red, green, blue, alpha int16) {
+ C.gl4_0compat_glColor4s(gl.funcs, C.GLshort(red), C.GLshort(green), C.GLshort(blue), C.GLshort(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4iv.xml
+func (gl *GL) Color4iv(v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glColor4iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4i.xml
+func (gl *GL) Color4i(red, green, blue, alpha int32) {
+ C.gl4_0compat_glColor4i(gl.funcs, C.GLint(red), C.GLint(green), C.GLint(blue), C.GLint(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4fv.xml
+func (gl *GL) Color4fv(v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glColor4fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4f.xml
+func (gl *GL) Color4f(red, green, blue, alpha float32) {
+ C.gl4_0compat_glColor4f(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4dv.xml
+func (gl *GL) Color4dv(v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glColor4dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4d.xml
+func (gl *GL) Color4d(red, green, blue, alpha float64) {
+ C.gl4_0compat_glColor4d(gl.funcs, C.GLdouble(red), C.GLdouble(green), C.GLdouble(blue), C.GLdouble(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4bv.xml
+func (gl *GL) Color4bv(v []byte) {
+ C.gl4_0compat_glColor4bv(gl.funcs, (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4b.xml
+func (gl *GL) Color4b(red, green, blue, alpha byte) {
+ C.gl4_0compat_glColor4b(gl.funcs, C.GLbyte(red), C.GLbyte(green), C.GLbyte(blue), C.GLbyte(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3usv.xml
+func (gl *GL) Color3usv(v []uint16) {
+ C.gl4_0compat_glColor3usv(gl.funcs, (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3us.xml
+func (gl *GL) Color3us(red, green, blue uint16) {
+ C.gl4_0compat_glColor3us(gl.funcs, C.GLushort(red), C.GLushort(green), C.GLushort(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3uiv.xml
+func (gl *GL) Color3uiv(v []uint32) {
+ C.gl4_0compat_glColor3uiv(gl.funcs, (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3ui.xml
+func (gl *GL) Color3ui(red, green, blue uint32) {
+ C.gl4_0compat_glColor3ui(gl.funcs, C.GLuint(red), C.GLuint(green), C.GLuint(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3ubv.xml
+func (gl *GL) Color3ubv(v []uint8) {
+ C.gl4_0compat_glColor3ubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3ub.xml
+func (gl *GL) Color3ub(red, green, blue uint8) {
+ C.gl4_0compat_glColor3ub(gl.funcs, C.GLubyte(red), C.GLubyte(green), C.GLubyte(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3sv.xml
+func (gl *GL) Color3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glColor3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3s.xml
+func (gl *GL) Color3s(red, green, blue int16) {
+ C.gl4_0compat_glColor3s(gl.funcs, C.GLshort(red), C.GLshort(green), C.GLshort(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3iv.xml
+func (gl *GL) Color3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glColor3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3i.xml
+func (gl *GL) Color3i(red, green, blue int32) {
+ C.gl4_0compat_glColor3i(gl.funcs, C.GLint(red), C.GLint(green), C.GLint(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3fv.xml
+func (gl *GL) Color3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glColor3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3f.xml
+func (gl *GL) Color3f(red, green, blue float32) {
+ C.gl4_0compat_glColor3f(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3dv.xml
+func (gl *GL) Color3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glColor3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3d.xml
+func (gl *GL) Color3d(red, green, blue float64) {
+ C.gl4_0compat_glColor3d(gl.funcs, C.GLdouble(red), C.GLdouble(green), C.GLdouble(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3bv.xml
+func (gl *GL) Color3bv(v []byte) {
+ C.gl4_0compat_glColor3bv(gl.funcs, (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3b.xml
+func (gl *GL) Color3b(red, green, blue byte) {
+ C.gl4_0compat_glColor3b(gl.funcs, C.GLbyte(red), C.GLbyte(green), C.GLbyte(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBitmap.xml
+func (gl *GL) Bitmap(width, height int, xorig, yorig, xmove, ymove float32, bitmap []uint8) {
+ C.gl4_0compat_glBitmap(gl.funcs, C.GLsizei(width), C.GLsizei(height), C.GLfloat(xorig), C.GLfloat(yorig), C.GLfloat(xmove), C.GLfloat(ymove), (*C.GLubyte)(unsafe.Pointer(&bitmap[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBegin.xml
+func (gl *GL) Begin(mode glbase.Enum) {
+ C.gl4_0compat_glBegin(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glListBase.xml
+func (gl *GL) ListBase(base uint32) {
+ C.gl4_0compat_glListBase(gl.funcs, C.GLuint(base))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGenLists.xml
+func (gl *GL) GenLists(range_ int32) uint32 {
+ glresult := C.gl4_0compat_glGenLists(gl.funcs, C.GLsizei(range_))
+ return uint32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDeleteLists.xml
+func (gl *GL) DeleteLists(list uint32, range_ int32) {
+ C.gl4_0compat_glDeleteLists(gl.funcs, C.GLuint(list), C.GLsizei(range_))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCallLists.xml
+func (gl *GL) CallLists(n int, gltype glbase.Enum, lists interface{}) {
+ var lists_ptr unsafe.Pointer
+ var lists_v = reflect.ValueOf(lists)
+ if lists != nil && lists_v.Kind() != reflect.Slice {
+ panic("parameter lists must be a slice")
+ }
+ if lists != nil {
+ lists_ptr = unsafe.Pointer(lists_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0compat_glCallLists(gl.funcs, C.GLsizei(n), C.GLenum(gltype), lists_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCallList.xml
+func (gl *GL) CallList(list uint32) {
+ C.gl4_0compat_glCallList(gl.funcs, C.GLuint(list))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEndList.xml
+func (gl *GL) EndList() {
+ C.gl4_0compat_glEndList(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNewList.xml
+func (gl *GL) NewList(list uint32, mode glbase.Enum) {
+ C.gl4_0compat_glNewList(gl.funcs, C.GLuint(list), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPushClientAttrib.xml
+func (gl *GL) PushClientAttrib(mask glbase.Bitfield) {
+ C.gl4_0compat_glPushClientAttrib(gl.funcs, C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPopClientAttrib.xml
+func (gl *GL) PopClientAttrib() {
+ C.gl4_0compat_glPopClientAttrib(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPrioritizeTextures.xml
+func (gl *GL) PrioritizeTextures(n int, textures []glbase.Texture, priorities []float32) {
+ C.gl4_0compat_glPrioritizeTextures(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])), (*C.GLfloat)(unsafe.Pointer(&priorities[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glAreTexturesResident.xml
+func (gl *GL) AreTexturesResident(n int, textures []glbase.Texture, residences []bool) bool {
+ glresult := C.gl4_0compat_glAreTexturesResident(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])), (*C.GLboolean)(unsafe.Pointer(&residences[0])))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexPointer.xml
+func (gl *GL) VertexPointer(size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0compat_glVertexPointer(gl.funcs, C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordPointer.xml
+func (gl *GL) TexCoordPointer(size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0compat_glTexCoordPointer(gl.funcs, C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNormalPointer.xml
+func (gl *GL) NormalPointer(gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0compat_glNormalPointer(gl.funcs, C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glInterleavedArrays.xml
+func (gl *GL) InterleavedArrays(format glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0compat_glInterleavedArrays(gl.funcs, C.GLenum(format), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIndexPointer.xml
+func (gl *GL) IndexPointer(gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0compat_glIndexPointer(gl.funcs, C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEnableClientState.xml
+func (gl *GL) EnableClientState(array glbase.Enum) {
+ C.gl4_0compat_glEnableClientState(gl.funcs, C.GLenum(array))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEdgeFlagPointer.xml
+func (gl *GL) EdgeFlagPointer(stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0compat_glEdgeFlagPointer(gl.funcs, C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDisableClientState.xml
+func (gl *GL) DisableClientState(array glbase.Enum) {
+ C.gl4_0compat_glDisableClientState(gl.funcs, C.GLenum(array))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorPointer.xml
+func (gl *GL) ColorPointer(size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0compat_glColorPointer(gl.funcs, C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glArrayElement.xml
+func (gl *GL) ArrayElement(i int32) {
+ C.gl4_0compat_glArrayElement(gl.funcs, C.GLint(i))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glResetMinmax.xml
+func (gl *GL) ResetMinmax(target glbase.Enum) {
+ C.gl4_0compat_glResetMinmax(gl.funcs, C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glResetHistogram.xml
+func (gl *GL) ResetHistogram(target glbase.Enum) {
+ C.gl4_0compat_glResetHistogram(gl.funcs, C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMinmax.xml
+func (gl *GL) Minmax(target, internalFormat glbase.Enum, sink bool) {
+ C.gl4_0compat_glMinmax(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), *(*C.GLboolean)(unsafe.Pointer(&sink)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glHistogram.xml
+func (gl *GL) Histogram(target glbase.Enum, width int, internalFormat glbase.Enum, sink bool) {
+ C.gl4_0compat_glHistogram(gl.funcs, C.GLenum(target), C.GLsizei(width), C.GLenum(internalFormat), *(*C.GLboolean)(unsafe.Pointer(&sink)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetMinmaxParameteriv.xml
+func (gl *GL) GetMinmaxParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl4_0compat_glGetMinmaxParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetMinmaxParameterfv.xml
+func (gl *GL) GetMinmaxParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl4_0compat_glGetMinmaxParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetMinmax.xml
+func (gl *GL) GetMinmax(target glbase.Enum, reset bool, format, gltype glbase.Enum, values interface{}) {
+ var values_ptr unsafe.Pointer
+ var values_v = reflect.ValueOf(values)
+ if values != nil && values_v.Kind() != reflect.Slice {
+ panic("parameter values must be a slice")
+ }
+ if values != nil {
+ values_ptr = unsafe.Pointer(values_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0compat_glGetMinmax(gl.funcs, C.GLenum(target), *(*C.GLboolean)(unsafe.Pointer(&reset)), C.GLenum(format), C.GLenum(gltype), values_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetHistogramParameteriv.xml
+func (gl *GL) GetHistogramParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl4_0compat_glGetHistogramParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetHistogramParameterfv.xml
+func (gl *GL) GetHistogramParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl4_0compat_glGetHistogramParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetHistogram.xml
+func (gl *GL) GetHistogram(target glbase.Enum, reset bool, format, gltype glbase.Enum, values interface{}) {
+ var values_ptr unsafe.Pointer
+ var values_v = reflect.ValueOf(values)
+ if values != nil && values_v.Kind() != reflect.Slice {
+ panic("parameter values must be a slice")
+ }
+ if values != nil {
+ values_ptr = unsafe.Pointer(values_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0compat_glGetHistogram(gl.funcs, C.GLenum(target), *(*C.GLboolean)(unsafe.Pointer(&reset)), C.GLenum(format), C.GLenum(gltype), values_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSeparableFilter2D.xml
+func (gl *GL) SeparableFilter2D(target, internalFormat glbase.Enum, width, height int, format, gltype glbase.Enum, row, column interface{}) {
+ var row_ptr unsafe.Pointer
+ var row_v = reflect.ValueOf(row)
+ if row != nil && row_v.Kind() != reflect.Slice {
+ panic("parameter row must be a slice")
+ }
+ if row != nil {
+ row_ptr = unsafe.Pointer(row_v.Index(0).Addr().Pointer())
+ }
+ var column_ptr unsafe.Pointer
+ var column_v = reflect.ValueOf(column)
+ if column != nil && column_v.Kind() != reflect.Slice {
+ panic("parameter column must be a slice")
+ }
+ if column != nil {
+ column_ptr = unsafe.Pointer(column_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0compat_glSeparableFilter2D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), row_ptr, column_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetSeparableFilter.xml
+func (gl *GL) GetSeparableFilter(target, format, gltype glbase.Enum, row, column, span interface{}) {
+ var row_ptr unsafe.Pointer
+ var row_v = reflect.ValueOf(row)
+ if row != nil && row_v.Kind() != reflect.Slice {
+ panic("parameter row must be a slice")
+ }
+ if row != nil {
+ row_ptr = unsafe.Pointer(row_v.Index(0).Addr().Pointer())
+ }
+ var column_ptr unsafe.Pointer
+ var column_v = reflect.ValueOf(column)
+ if column != nil && column_v.Kind() != reflect.Slice {
+ panic("parameter column must be a slice")
+ }
+ if column != nil {
+ column_ptr = unsafe.Pointer(column_v.Index(0).Addr().Pointer())
+ }
+ var span_ptr unsafe.Pointer
+ var span_v = reflect.ValueOf(span)
+ if span != nil && span_v.Kind() != reflect.Slice {
+ panic("parameter span must be a slice")
+ }
+ if span != nil {
+ span_ptr = unsafe.Pointer(span_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0compat_glGetSeparableFilter(gl.funcs, C.GLenum(target), C.GLenum(format), C.GLenum(gltype), row_ptr, column_ptr, span_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetConvolutionParameteriv.xml
+func (gl *GL) GetConvolutionParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl4_0compat_glGetConvolutionParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetConvolutionParameterfv.xml
+func (gl *GL) GetConvolutionParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl4_0compat_glGetConvolutionParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetConvolutionFilter.xml
+func (gl *GL) GetConvolutionFilter(target, format, gltype glbase.Enum, image interface{}) {
+ var image_ptr unsafe.Pointer
+ var image_v = reflect.ValueOf(image)
+ if image != nil && image_v.Kind() != reflect.Slice {
+ panic("parameter image must be a slice")
+ }
+ if image != nil {
+ image_ptr = unsafe.Pointer(image_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0compat_glGetConvolutionFilter(gl.funcs, C.GLenum(target), C.GLenum(format), C.GLenum(gltype), image_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyConvolutionFilter2D.xml
+func (gl *GL) CopyConvolutionFilter2D(target, internalFormat glbase.Enum, x, y, width, height int) {
+ C.gl4_0compat_glCopyConvolutionFilter2D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyConvolutionFilter1D.xml
+func (gl *GL) CopyConvolutionFilter1D(target, internalFormat glbase.Enum, x, y, width int) {
+ C.gl4_0compat_glCopyConvolutionFilter1D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glConvolutionParameteriv.xml
+func (gl *GL) ConvolutionParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl4_0compat_glConvolutionParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glConvolutionParameteri.xml
+func (gl *GL) ConvolutionParameteri(target, pname glbase.Enum, params int32) {
+ C.gl4_0compat_glConvolutionParameteri(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLint(params))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glConvolutionParameterfv.xml
+func (gl *GL) ConvolutionParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl4_0compat_glConvolutionParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glConvolutionParameterf.xml
+func (gl *GL) ConvolutionParameterf(target, pname glbase.Enum, params float32) {
+ C.gl4_0compat_glConvolutionParameterf(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLfloat(params))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glConvolutionFilter2D.xml
+func (gl *GL) ConvolutionFilter2D(target, internalFormat glbase.Enum, width, height int, format, gltype glbase.Enum, image interface{}) {
+ var image_ptr unsafe.Pointer
+ var image_v = reflect.ValueOf(image)
+ if image != nil && image_v.Kind() != reflect.Slice {
+ panic("parameter image must be a slice")
+ }
+ if image != nil {
+ image_ptr = unsafe.Pointer(image_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0compat_glConvolutionFilter2D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), image_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glConvolutionFilter1D.xml
+func (gl *GL) ConvolutionFilter1D(target, internalFormat glbase.Enum, width int, format, gltype glbase.Enum, image interface{}) {
+ var image_ptr unsafe.Pointer
+ var image_v = reflect.ValueOf(image)
+ if image != nil && image_v.Kind() != reflect.Slice {
+ panic("parameter image must be a slice")
+ }
+ if image != nil {
+ image_ptr = unsafe.Pointer(image_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0compat_glConvolutionFilter1D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLenum(format), C.GLenum(gltype), image_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyColorSubTable.xml
+func (gl *GL) CopyColorSubTable(target glbase.Enum, start int32, x, y, width int) {
+ C.gl4_0compat_glCopyColorSubTable(gl.funcs, C.GLenum(target), C.GLsizei(start), C.GLint(x), C.GLint(y), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorSubTable.xml
+func (gl *GL) ColorSubTable(target glbase.Enum, start int32, count int, format, gltype glbase.Enum, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0compat_glColorSubTable(gl.funcs, C.GLenum(target), C.GLsizei(start), C.GLsizei(count), C.GLenum(format), C.GLenum(gltype), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetColorTableParameteriv.xml
+func (gl *GL) GetColorTableParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl4_0compat_glGetColorTableParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetColorTableParameterfv.xml
+func (gl *GL) GetColorTableParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl4_0compat_glGetColorTableParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetColorTable.xml
+func (gl *GL) GetColorTable(target, format, gltype glbase.Enum, table interface{}) {
+ var table_ptr unsafe.Pointer
+ var table_v = reflect.ValueOf(table)
+ if table != nil && table_v.Kind() != reflect.Slice {
+ panic("parameter table must be a slice")
+ }
+ if table != nil {
+ table_ptr = unsafe.Pointer(table_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0compat_glGetColorTable(gl.funcs, C.GLenum(target), C.GLenum(format), C.GLenum(gltype), table_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyColorTable.xml
+func (gl *GL) CopyColorTable(target, internalFormat glbase.Enum, x, y, width int) {
+ C.gl4_0compat_glCopyColorTable(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorTableParameteriv.xml
+func (gl *GL) ColorTableParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl4_0compat_glColorTableParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorTableParameterfv.xml
+func (gl *GL) ColorTableParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl4_0compat_glColorTableParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorTable.xml
+func (gl *GL) ColorTable(target, internalFormat glbase.Enum, width int, format, gltype glbase.Enum, table interface{}) {
+ var table_ptr unsafe.Pointer
+ var table_v = reflect.ValueOf(table)
+ if table != nil && table_v.Kind() != reflect.Slice {
+ panic("parameter table must be a slice")
+ }
+ if table != nil {
+ table_ptr = unsafe.Pointer(table_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0compat_glColorTable(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLenum(format), C.GLenum(gltype), table_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultTransposeMatrixd.xml
+func (gl *GL) MultTransposeMatrixd(m []float64) {
+ C.gl4_0compat_glMultTransposeMatrixd(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultTransposeMatrixf.xml
+func (gl *GL) MultTransposeMatrixf(m []float32) {
+ C.gl4_0compat_glMultTransposeMatrixf(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLoadTransposeMatrixd.xml
+func (gl *GL) LoadTransposeMatrixd(m []float64) {
+ C.gl4_0compat_glLoadTransposeMatrixd(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLoadTransposeMatrixf.xml
+func (gl *GL) LoadTransposeMatrixf(m []float32) {
+ C.gl4_0compat_glLoadTransposeMatrixf(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord4sv.xml
+func (gl *GL) MultiTexCoord4sv(target glbase.Enum, v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glMultiTexCoord4sv(gl.funcs, C.GLenum(target), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord4s.xml
+func (gl *GL) MultiTexCoord4s(target glbase.Enum, s, t, r, q int16) {
+ C.gl4_0compat_glMultiTexCoord4s(gl.funcs, C.GLenum(target), C.GLshort(s), C.GLshort(t), C.GLshort(r), C.GLshort(q))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord4iv.xml
+func (gl *GL) MultiTexCoord4iv(target glbase.Enum, v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glMultiTexCoord4iv(gl.funcs, C.GLenum(target), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord4i.xml
+func (gl *GL) MultiTexCoord4i(target glbase.Enum, s, t, r, q int32) {
+ C.gl4_0compat_glMultiTexCoord4i(gl.funcs, C.GLenum(target), C.GLint(s), C.GLint(t), C.GLint(r), C.GLint(q))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord4fv.xml
+func (gl *GL) MultiTexCoord4fv(target glbase.Enum, v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glMultiTexCoord4fv(gl.funcs, C.GLenum(target), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord4f.xml
+func (gl *GL) MultiTexCoord4f(target glbase.Enum, s, t, r, q float32) {
+ C.gl4_0compat_glMultiTexCoord4f(gl.funcs, C.GLenum(target), C.GLfloat(s), C.GLfloat(t), C.GLfloat(r), C.GLfloat(q))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord4dv.xml
+func (gl *GL) MultiTexCoord4dv(target glbase.Enum, v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glMultiTexCoord4dv(gl.funcs, C.GLenum(target), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord4d.xml
+func (gl *GL) MultiTexCoord4d(target glbase.Enum, s, t, r, q float64) {
+ C.gl4_0compat_glMultiTexCoord4d(gl.funcs, C.GLenum(target), C.GLdouble(s), C.GLdouble(t), C.GLdouble(r), C.GLdouble(q))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord3sv.xml
+func (gl *GL) MultiTexCoord3sv(target glbase.Enum, v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glMultiTexCoord3sv(gl.funcs, C.GLenum(target), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord3s.xml
+func (gl *GL) MultiTexCoord3s(target glbase.Enum, s, t, r int16) {
+ C.gl4_0compat_glMultiTexCoord3s(gl.funcs, C.GLenum(target), C.GLshort(s), C.GLshort(t), C.GLshort(r))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord3iv.xml
+func (gl *GL) MultiTexCoord3iv(target glbase.Enum, v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glMultiTexCoord3iv(gl.funcs, C.GLenum(target), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord3i.xml
+func (gl *GL) MultiTexCoord3i(target glbase.Enum, s, t, r int32) {
+ C.gl4_0compat_glMultiTexCoord3i(gl.funcs, C.GLenum(target), C.GLint(s), C.GLint(t), C.GLint(r))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord3fv.xml
+func (gl *GL) MultiTexCoord3fv(target glbase.Enum, v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glMultiTexCoord3fv(gl.funcs, C.GLenum(target), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord3f.xml
+func (gl *GL) MultiTexCoord3f(target glbase.Enum, s, t, r float32) {
+ C.gl4_0compat_glMultiTexCoord3f(gl.funcs, C.GLenum(target), C.GLfloat(s), C.GLfloat(t), C.GLfloat(r))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord3dv.xml
+func (gl *GL) MultiTexCoord3dv(target glbase.Enum, v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glMultiTexCoord3dv(gl.funcs, C.GLenum(target), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord3d.xml
+func (gl *GL) MultiTexCoord3d(target glbase.Enum, s, t, r float64) {
+ C.gl4_0compat_glMultiTexCoord3d(gl.funcs, C.GLenum(target), C.GLdouble(s), C.GLdouble(t), C.GLdouble(r))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord2sv.xml
+func (gl *GL) MultiTexCoord2sv(target glbase.Enum, v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glMultiTexCoord2sv(gl.funcs, C.GLenum(target), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord2s.xml
+func (gl *GL) MultiTexCoord2s(target glbase.Enum, s, t int16) {
+ C.gl4_0compat_glMultiTexCoord2s(gl.funcs, C.GLenum(target), C.GLshort(s), C.GLshort(t))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord2iv.xml
+func (gl *GL) MultiTexCoord2iv(target glbase.Enum, v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glMultiTexCoord2iv(gl.funcs, C.GLenum(target), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord2i.xml
+func (gl *GL) MultiTexCoord2i(target glbase.Enum, s, t int32) {
+ C.gl4_0compat_glMultiTexCoord2i(gl.funcs, C.GLenum(target), C.GLint(s), C.GLint(t))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord2fv.xml
+func (gl *GL) MultiTexCoord2fv(target glbase.Enum, v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glMultiTexCoord2fv(gl.funcs, C.GLenum(target), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord2f.xml
+func (gl *GL) MultiTexCoord2f(target glbase.Enum, s, t float32) {
+ C.gl4_0compat_glMultiTexCoord2f(gl.funcs, C.GLenum(target), C.GLfloat(s), C.GLfloat(t))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord2dv.xml
+func (gl *GL) MultiTexCoord2dv(target glbase.Enum, v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glMultiTexCoord2dv(gl.funcs, C.GLenum(target), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord2d.xml
+func (gl *GL) MultiTexCoord2d(target glbase.Enum, s, t float64) {
+ C.gl4_0compat_glMultiTexCoord2d(gl.funcs, C.GLenum(target), C.GLdouble(s), C.GLdouble(t))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord1sv.xml
+func (gl *GL) MultiTexCoord1sv(target glbase.Enum, v []int16) {
+ C.gl4_0compat_glMultiTexCoord1sv(gl.funcs, C.GLenum(target), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord1s.xml
+func (gl *GL) MultiTexCoord1s(target glbase.Enum, s int16) {
+ C.gl4_0compat_glMultiTexCoord1s(gl.funcs, C.GLenum(target), C.GLshort(s))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord1iv.xml
+func (gl *GL) MultiTexCoord1iv(target glbase.Enum, v []int32) {
+ C.gl4_0compat_glMultiTexCoord1iv(gl.funcs, C.GLenum(target), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord1i.xml
+func (gl *GL) MultiTexCoord1i(target glbase.Enum, s int32) {
+ C.gl4_0compat_glMultiTexCoord1i(gl.funcs, C.GLenum(target), C.GLint(s))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord1fv.xml
+func (gl *GL) MultiTexCoord1fv(target glbase.Enum, v []float32) {
+ C.gl4_0compat_glMultiTexCoord1fv(gl.funcs, C.GLenum(target), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord1f.xml
+func (gl *GL) MultiTexCoord1f(target glbase.Enum, s float32) {
+ C.gl4_0compat_glMultiTexCoord1f(gl.funcs, C.GLenum(target), C.GLfloat(s))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord1dv.xml
+func (gl *GL) MultiTexCoord1dv(target glbase.Enum, v []float64) {
+ C.gl4_0compat_glMultiTexCoord1dv(gl.funcs, C.GLenum(target), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord1d.xml
+func (gl *GL) MultiTexCoord1d(target glbase.Enum, s float64) {
+ C.gl4_0compat_glMultiTexCoord1d(gl.funcs, C.GLenum(target), C.GLdouble(s))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClientActiveTexture.xml
+func (gl *GL) ClientActiveTexture(texture glbase.Enum) {
+ C.gl4_0compat_glClientActiveTexture(gl.funcs, C.GLenum(texture))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos3sv.xml
+func (gl *GL) WindowPos3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glWindowPos3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos3s.xml
+func (gl *GL) WindowPos3s(x, y, z int16) {
+ C.gl4_0compat_glWindowPos3s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos3iv.xml
+func (gl *GL) WindowPos3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glWindowPos3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos3i.xml
+func (gl *GL) WindowPos3i(x, y, z int) {
+ C.gl4_0compat_glWindowPos3i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos3fv.xml
+func (gl *GL) WindowPos3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glWindowPos3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos3f.xml
+func (gl *GL) WindowPos3f(x, y, z float32) {
+ C.gl4_0compat_glWindowPos3f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos3dv.xml
+func (gl *GL) WindowPos3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glWindowPos3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos3d.xml
+func (gl *GL) WindowPos3d(x, y, z float64) {
+ C.gl4_0compat_glWindowPos3d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos2sv.xml
+func (gl *GL) WindowPos2sv(v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glWindowPos2sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos2s.xml
+func (gl *GL) WindowPos2s(x, y int16) {
+ C.gl4_0compat_glWindowPos2s(gl.funcs, C.GLshort(x), C.GLshort(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos2iv.xml
+func (gl *GL) WindowPos2iv(v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glWindowPos2iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos2i.xml
+func (gl *GL) WindowPos2i(x, y int) {
+ C.gl4_0compat_glWindowPos2i(gl.funcs, C.GLint(x), C.GLint(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos2fv.xml
+func (gl *GL) WindowPos2fv(v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glWindowPos2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos2f.xml
+func (gl *GL) WindowPos2f(x, y float32) {
+ C.gl4_0compat_glWindowPos2f(gl.funcs, C.GLfloat(x), C.GLfloat(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos2dv.xml
+func (gl *GL) WindowPos2dv(v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glWindowPos2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos2d.xml
+func (gl *GL) WindowPos2d(x, y float64) {
+ C.gl4_0compat_glWindowPos2d(gl.funcs, C.GLdouble(x), C.GLdouble(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColorPointer.xml
+func (gl *GL) SecondaryColorPointer(size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0compat_glSecondaryColorPointer(gl.funcs, C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3usv.xml
+func (gl *GL) SecondaryColor3usv(v []uint16) {
+ C.gl4_0compat_glSecondaryColor3usv(gl.funcs, (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3us.xml
+func (gl *GL) SecondaryColor3us(red, green, blue uint16) {
+ C.gl4_0compat_glSecondaryColor3us(gl.funcs, C.GLushort(red), C.GLushort(green), C.GLushort(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3uiv.xml
+func (gl *GL) SecondaryColor3uiv(v []uint32) {
+ C.gl4_0compat_glSecondaryColor3uiv(gl.funcs, (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3ui.xml
+func (gl *GL) SecondaryColor3ui(red, green, blue uint32) {
+ C.gl4_0compat_glSecondaryColor3ui(gl.funcs, C.GLuint(red), C.GLuint(green), C.GLuint(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3ubv.xml
+func (gl *GL) SecondaryColor3ubv(v []uint8) {
+ C.gl4_0compat_glSecondaryColor3ubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3ub.xml
+func (gl *GL) SecondaryColor3ub(red, green, blue uint8) {
+ C.gl4_0compat_glSecondaryColor3ub(gl.funcs, C.GLubyte(red), C.GLubyte(green), C.GLubyte(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3sv.xml
+func (gl *GL) SecondaryColor3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glSecondaryColor3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3s.xml
+func (gl *GL) SecondaryColor3s(red, green, blue int16) {
+ C.gl4_0compat_glSecondaryColor3s(gl.funcs, C.GLshort(red), C.GLshort(green), C.GLshort(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3iv.xml
+func (gl *GL) SecondaryColor3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glSecondaryColor3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3i.xml
+func (gl *GL) SecondaryColor3i(red, green, blue int32) {
+ C.gl4_0compat_glSecondaryColor3i(gl.funcs, C.GLint(red), C.GLint(green), C.GLint(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3fv.xml
+func (gl *GL) SecondaryColor3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glSecondaryColor3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3f.xml
+func (gl *GL) SecondaryColor3f(red, green, blue float32) {
+ C.gl4_0compat_glSecondaryColor3f(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3dv.xml
+func (gl *GL) SecondaryColor3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glSecondaryColor3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3d.xml
+func (gl *GL) SecondaryColor3d(red, green, blue float64) {
+ C.gl4_0compat_glSecondaryColor3d(gl.funcs, C.GLdouble(red), C.GLdouble(green), C.GLdouble(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3bv.xml
+func (gl *GL) SecondaryColor3bv(v []byte) {
+ C.gl4_0compat_glSecondaryColor3bv(gl.funcs, (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3b.xml
+func (gl *GL) SecondaryColor3b(red, green, blue byte) {
+ C.gl4_0compat_glSecondaryColor3b(gl.funcs, C.GLbyte(red), C.GLbyte(green), C.GLbyte(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFogCoordPointer.xml
+func (gl *GL) FogCoordPointer(gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0compat_glFogCoordPointer(gl.funcs, C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFogCoorddv.xml
+func (gl *GL) FogCoorddv(coord []float64) {
+ C.gl4_0compat_glFogCoorddv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&coord[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFogCoordd.xml
+func (gl *GL) FogCoordd(coord float64) {
+ C.gl4_0compat_glFogCoordd(gl.funcs, C.GLdouble(coord))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFogCoordfv.xml
+func (gl *GL) FogCoordfv(coord []float32) {
+ C.gl4_0compat_glFogCoordfv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&coord[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFogCoordf.xml
+func (gl *GL) FogCoordf(coord float32) {
+ C.gl4_0compat_glFogCoordf(gl.funcs, C.GLfloat(coord))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4usv.xml
+func (gl *GL) VertexAttrib4usv(index glbase.Attrib, v []uint16) {
+ C.gl4_0compat_glVertexAttrib4usv(gl.funcs, C.GLuint(index), (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4uiv.xml
+func (gl *GL) VertexAttrib4uiv(index glbase.Attrib, v []uint32) {
+ C.gl4_0compat_glVertexAttrib4uiv(gl.funcs, C.GLuint(index), (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4ubv.xml
+func (gl *GL) VertexAttrib4ubv(index glbase.Attrib, v []uint8) {
+ C.gl4_0compat_glVertexAttrib4ubv(gl.funcs, C.GLuint(index), (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4sv.xml
+func (gl *GL) VertexAttrib4sv(index glbase.Attrib, v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glVertexAttrib4sv(gl.funcs, C.GLuint(index), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4s.xml
+func (gl *GL) VertexAttrib4s(index glbase.Attrib, x, y, z, w int16) {
+ C.gl4_0compat_glVertexAttrib4s(gl.funcs, C.GLuint(index), C.GLshort(x), C.GLshort(y), C.GLshort(z), C.GLshort(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4iv.xml
+func (gl *GL) VertexAttrib4iv(index glbase.Attrib, v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glVertexAttrib4iv(gl.funcs, C.GLuint(index), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4fv.xml
+func (gl *GL) VertexAttrib4fv(index glbase.Attrib, v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glVertexAttrib4fv(gl.funcs, C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4f.xml
+func (gl *GL) VertexAttrib4f(index glbase.Attrib, x, y, z, w float32) {
+ C.gl4_0compat_glVertexAttrib4f(gl.funcs, C.GLuint(index), C.GLfloat(x), C.GLfloat(y), C.GLfloat(z), C.GLfloat(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4dv.xml
+func (gl *GL) VertexAttrib4dv(index glbase.Attrib, v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glVertexAttrib4dv(gl.funcs, C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4d.xml
+func (gl *GL) VertexAttrib4d(index glbase.Attrib, x, y, z, w float64) {
+ C.gl4_0compat_glVertexAttrib4d(gl.funcs, C.GLuint(index), C.GLdouble(x), C.GLdouble(y), C.GLdouble(z), C.GLdouble(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4bv.xml
+func (gl *GL) VertexAttrib4bv(index glbase.Attrib, v []byte) {
+ C.gl4_0compat_glVertexAttrib4bv(gl.funcs, C.GLuint(index), (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4Nusv.xml
+func (gl *GL) VertexAttrib4Nusv(index glbase.Attrib, v []uint16) {
+ C.gl4_0compat_glVertexAttrib4Nusv(gl.funcs, C.GLuint(index), (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4Nuiv.xml
+func (gl *GL) VertexAttrib4Nuiv(index glbase.Attrib, v []uint32) {
+ C.gl4_0compat_glVertexAttrib4Nuiv(gl.funcs, C.GLuint(index), (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4Nubv.xml
+func (gl *GL) VertexAttrib4Nubv(index glbase.Attrib, v []uint8) {
+ C.gl4_0compat_glVertexAttrib4Nubv(gl.funcs, C.GLuint(index), (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4Nub.xml
+func (gl *GL) VertexAttrib4Nub(index glbase.Attrib, x, y, z, w uint8) {
+ C.gl4_0compat_glVertexAttrib4Nub(gl.funcs, C.GLuint(index), C.GLubyte(x), C.GLubyte(y), C.GLubyte(z), C.GLubyte(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4Nsv.xml
+func (gl *GL) VertexAttrib4Nsv(index glbase.Attrib, v []int16) {
+ C.gl4_0compat_glVertexAttrib4Nsv(gl.funcs, C.GLuint(index), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4Niv.xml
+func (gl *GL) VertexAttrib4Niv(index glbase.Attrib, v []int32) {
+ C.gl4_0compat_glVertexAttrib4Niv(gl.funcs, C.GLuint(index), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4Nbv.xml
+func (gl *GL) VertexAttrib4Nbv(index glbase.Attrib, v []byte) {
+ C.gl4_0compat_glVertexAttrib4Nbv(gl.funcs, C.GLuint(index), (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib3sv.xml
+func (gl *GL) VertexAttrib3sv(index glbase.Attrib, v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glVertexAttrib3sv(gl.funcs, C.GLuint(index), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib3s.xml
+func (gl *GL) VertexAttrib3s(index glbase.Attrib, x, y, z int16) {
+ C.gl4_0compat_glVertexAttrib3s(gl.funcs, C.GLuint(index), C.GLshort(x), C.GLshort(y), C.GLshort(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib3fv.xml
+func (gl *GL) VertexAttrib3fv(index glbase.Attrib, v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glVertexAttrib3fv(gl.funcs, C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib3f.xml
+func (gl *GL) VertexAttrib3f(index glbase.Attrib, x, y, z float32) {
+ C.gl4_0compat_glVertexAttrib3f(gl.funcs, C.GLuint(index), C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib3dv.xml
+func (gl *GL) VertexAttrib3dv(index glbase.Attrib, v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glVertexAttrib3dv(gl.funcs, C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib3d.xml
+func (gl *GL) VertexAttrib3d(index glbase.Attrib, x, y, z float64) {
+ C.gl4_0compat_glVertexAttrib3d(gl.funcs, C.GLuint(index), C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib2sv.xml
+func (gl *GL) VertexAttrib2sv(index glbase.Attrib, v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glVertexAttrib2sv(gl.funcs, C.GLuint(index), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib2s.xml
+func (gl *GL) VertexAttrib2s(index glbase.Attrib, x, y int16) {
+ C.gl4_0compat_glVertexAttrib2s(gl.funcs, C.GLuint(index), C.GLshort(x), C.GLshort(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib2fv.xml
+func (gl *GL) VertexAttrib2fv(index glbase.Attrib, v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glVertexAttrib2fv(gl.funcs, C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib2f.xml
+func (gl *GL) VertexAttrib2f(index glbase.Attrib, x, y float32) {
+ C.gl4_0compat_glVertexAttrib2f(gl.funcs, C.GLuint(index), C.GLfloat(x), C.GLfloat(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib2dv.xml
+func (gl *GL) VertexAttrib2dv(index glbase.Attrib, v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glVertexAttrib2dv(gl.funcs, C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib2d.xml
+func (gl *GL) VertexAttrib2d(index glbase.Attrib, x, y float64) {
+ C.gl4_0compat_glVertexAttrib2d(gl.funcs, C.GLuint(index), C.GLdouble(x), C.GLdouble(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib1sv.xml
+func (gl *GL) VertexAttrib1sv(index glbase.Attrib, v []int16) {
+ C.gl4_0compat_glVertexAttrib1sv(gl.funcs, C.GLuint(index), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib1s.xml
+func (gl *GL) VertexAttrib1s(index glbase.Attrib, x int16) {
+ C.gl4_0compat_glVertexAttrib1s(gl.funcs, C.GLuint(index), C.GLshort(x))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib1fv.xml
+func (gl *GL) VertexAttrib1fv(index glbase.Attrib, v []float32) {
+ C.gl4_0compat_glVertexAttrib1fv(gl.funcs, C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib1f.xml
+func (gl *GL) VertexAttrib1f(index glbase.Attrib, x float32) {
+ C.gl4_0compat_glVertexAttrib1f(gl.funcs, C.GLuint(index), C.GLfloat(x))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib1dv.xml
+func (gl *GL) VertexAttrib1dv(index glbase.Attrib, v []float64) {
+ C.gl4_0compat_glVertexAttrib1dv(gl.funcs, C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib1d.xml
+func (gl *GL) VertexAttrib1d(index glbase.Attrib, x float64) {
+ C.gl4_0compat_glVertexAttrib1d(gl.funcs, C.GLuint(index), C.GLdouble(x))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI4usv.xml
+func (gl *GL) VertexAttribI4usv(index glbase.Attrib, v []uint16) {
+ C.gl4_0compat_glVertexAttribI4usv(gl.funcs, C.GLuint(index), (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI4ubv.xml
+func (gl *GL) VertexAttribI4ubv(index glbase.Attrib, v []uint8) {
+ C.gl4_0compat_glVertexAttribI4ubv(gl.funcs, C.GLuint(index), (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI4sv.xml
+func (gl *GL) VertexAttribI4sv(index glbase.Attrib, v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glVertexAttribI4sv(gl.funcs, C.GLuint(index), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI4bv.xml
+func (gl *GL) VertexAttribI4bv(index glbase.Attrib, v []byte) {
+ C.gl4_0compat_glVertexAttribI4bv(gl.funcs, C.GLuint(index), (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI4uiv.xml
+func (gl *GL) VertexAttribI4uiv(index glbase.Attrib, v []uint32) {
+ C.gl4_0compat_glVertexAttribI4uiv(gl.funcs, C.GLuint(index), (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI3uiv.xml
+func (gl *GL) VertexAttribI3uiv(index glbase.Attrib, v []uint32) {
+ C.gl4_0compat_glVertexAttribI3uiv(gl.funcs, C.GLuint(index), (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI2uiv.xml
+func (gl *GL) VertexAttribI2uiv(index glbase.Attrib, v []uint32) {
+ C.gl4_0compat_glVertexAttribI2uiv(gl.funcs, C.GLuint(index), (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI1uiv.xml
+func (gl *GL) VertexAttribI1uiv(index glbase.Attrib, v []uint32) {
+ C.gl4_0compat_glVertexAttribI1uiv(gl.funcs, C.GLuint(index), (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI4iv.xml
+func (gl *GL) VertexAttribI4iv(index glbase.Attrib, v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glVertexAttribI4iv(gl.funcs, C.GLuint(index), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI3iv.xml
+func (gl *GL) VertexAttribI3iv(index glbase.Attrib, v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glVertexAttribI3iv(gl.funcs, C.GLuint(index), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI2iv.xml
+func (gl *GL) VertexAttribI2iv(index glbase.Attrib, v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_0compat_glVertexAttribI2iv(gl.funcs, C.GLuint(index), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI1iv.xml
+func (gl *GL) VertexAttribI1iv(index glbase.Attrib, v []int32) {
+ C.gl4_0compat_glVertexAttribI1iv(gl.funcs, C.GLuint(index), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI4ui.xml
+func (gl *GL) VertexAttribI4ui(index glbase.Attrib, x, y, z, w uint32) {
+ C.gl4_0compat_glVertexAttribI4ui(gl.funcs, C.GLuint(index), C.GLuint(x), C.GLuint(y), C.GLuint(z), C.GLuint(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI3ui.xml
+func (gl *GL) VertexAttribI3ui(index glbase.Attrib, x, y, z uint32) {
+ C.gl4_0compat_glVertexAttribI3ui(gl.funcs, C.GLuint(index), C.GLuint(x), C.GLuint(y), C.GLuint(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI2ui.xml
+func (gl *GL) VertexAttribI2ui(index glbase.Attrib, x, y uint32) {
+ C.gl4_0compat_glVertexAttribI2ui(gl.funcs, C.GLuint(index), C.GLuint(x), C.GLuint(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI1ui.xml
+func (gl *GL) VertexAttribI1ui(index glbase.Attrib, x uint32) {
+ C.gl4_0compat_glVertexAttribI1ui(gl.funcs, C.GLuint(index), C.GLuint(x))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI4i.xml
+func (gl *GL) VertexAttribI4i(index glbase.Attrib, x, y, z, w int) {
+ C.gl4_0compat_glVertexAttribI4i(gl.funcs, C.GLuint(index), C.GLint(x), C.GLint(y), C.GLint(z), C.GLint(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI3i.xml
+func (gl *GL) VertexAttribI3i(index glbase.Attrib, x, y, z int) {
+ C.gl4_0compat_glVertexAttribI3i(gl.funcs, C.GLuint(index), C.GLint(x), C.GLint(y), C.GLint(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI2i.xml
+func (gl *GL) VertexAttribI2i(index glbase.Attrib, x, y int) {
+ C.gl4_0compat_glVertexAttribI2i(gl.funcs, C.GLuint(index), C.GLint(x), C.GLint(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI1i.xml
+func (gl *GL) VertexAttribI1i(index glbase.Attrib, x int) {
+ C.gl4_0compat_glVertexAttribI1i(gl.funcs, C.GLuint(index), C.GLint(x))
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.0core/funcs.cpp b/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.0core/funcs.cpp
new file mode 100644
index 000000000..1be157d64
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.0core/funcs.cpp
@@ -0,0 +1,2154 @@
+
+// ** file automatically generated by glgen -- do not edit manually **
+
+#include <QOpenGLContext>
+#include <QtGui/qopenglfunctions_4_0_core.h>
+
+#include "funcs.h"
+
+void *gl4_0core_funcs() {
+ QOpenGLFunctions_4_0_Core* funcs = QOpenGLContext::currentContext()->versionFunctions<QOpenGLFunctions_4_0_Core>();
+ if (!funcs) {
+ return 0;
+ }
+ funcs->initializeOpenGLFunctions();
+ return funcs;
+}
+
+
+void gl4_0core_glViewport(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glViewport(x, y, width, height);
+}
+
+void gl4_0core_glDepthRange(void *_glfuncs, GLdouble nearVal, GLdouble farVal)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glDepthRange(nearVal, farVal);
+}
+
+GLboolean gl4_0core_glIsEnabled(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ return _qglfuncs->glIsEnabled(cap);
+}
+
+void gl4_0core_glGetTexLevelParameteriv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGetTexLevelParameteriv(target, level, pname, params);
+}
+
+void gl4_0core_glGetTexLevelParameterfv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGetTexLevelParameterfv(target, level, pname, params);
+}
+
+void gl4_0core_glGetTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGetTexParameteriv(target, pname, params);
+}
+
+void gl4_0core_glGetTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGetTexParameterfv(target, pname, params);
+}
+
+void gl4_0core_glGetTexImage(void *_glfuncs, GLenum target, GLint level, GLenum format, GLenum gltype, GLvoid* pixels)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGetTexImage(target, level, format, gltype, pixels);
+}
+
+void gl4_0core_glGetIntegerv(void *_glfuncs, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGetIntegerv(pname, params);
+}
+
+void gl4_0core_glGetFloatv(void *_glfuncs, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGetFloatv(pname, params);
+}
+
+GLenum gl4_0core_glGetError(void *_glfuncs)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ return _qglfuncs->glGetError();
+}
+
+void gl4_0core_glGetDoublev(void *_glfuncs, GLenum pname, GLdouble* params)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGetDoublev(pname, params);
+}
+
+void gl4_0core_glGetBooleanv(void *_glfuncs, GLenum pname, GLboolean* params)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGetBooleanv(pname, params);
+}
+
+void gl4_0core_glReadPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum gltype, GLvoid* pixels)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glReadPixels(x, y, width, height, format, gltype, pixels);
+}
+
+void gl4_0core_glReadBuffer(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glReadBuffer(mode);
+}
+
+void gl4_0core_glPixelStorei(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glPixelStorei(pname, param);
+}
+
+void gl4_0core_glPixelStoref(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glPixelStoref(pname, param);
+}
+
+void gl4_0core_glDepthFunc(void *_glfuncs, GLenum glfunc)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glDepthFunc(glfunc);
+}
+
+void gl4_0core_glStencilOp(void *_glfuncs, GLenum fail, GLenum zfail, GLenum zpass)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glStencilOp(fail, zfail, zpass);
+}
+
+void gl4_0core_glStencilFunc(void *_glfuncs, GLenum glfunc, GLint ref, GLuint mask)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glStencilFunc(glfunc, ref, mask);
+}
+
+void gl4_0core_glLogicOp(void *_glfuncs, GLenum opcode)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glLogicOp(opcode);
+}
+
+void gl4_0core_glBlendFunc(void *_glfuncs, GLenum sfactor, GLenum dfactor)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glBlendFunc(sfactor, dfactor);
+}
+
+void gl4_0core_glFlush(void *_glfuncs)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glFlush();
+}
+
+void gl4_0core_glFinish(void *_glfuncs)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glFinish();
+}
+
+void gl4_0core_glEnable(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glEnable(cap);
+}
+
+void gl4_0core_glDisable(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glDisable(cap);
+}
+
+void gl4_0core_glDepthMask(void *_glfuncs, GLboolean flag)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glDepthMask(flag);
+}
+
+void gl4_0core_glColorMask(void *_glfuncs, GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glColorMask(red, green, blue, alpha);
+}
+
+void gl4_0core_glStencilMask(void *_glfuncs, GLuint mask)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glStencilMask(mask);
+}
+
+void gl4_0core_glClearDepth(void *_glfuncs, GLdouble depth)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glClearDepth(depth);
+}
+
+void gl4_0core_glClearStencil(void *_glfuncs, GLint s)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glClearStencil(s);
+}
+
+void gl4_0core_glClearColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glClearColor(red, green, blue, alpha);
+}
+
+void gl4_0core_glClear(void *_glfuncs, GLbitfield mask)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glClear(mask);
+}
+
+void gl4_0core_glDrawBuffer(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glDrawBuffer(mode);
+}
+
+void gl4_0core_glTexImage2D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glTexImage2D(target, level, internalFormat, width, height, border, format, gltype, pixels);
+}
+
+void gl4_0core_glTexImage1D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glTexImage1D(target, level, internalFormat, width, border, format, gltype, pixels);
+}
+
+void gl4_0core_glTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glTexParameteriv(target, pname, params);
+}
+
+void gl4_0core_glTexParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glTexParameteri(target, pname, param);
+}
+
+void gl4_0core_glTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glTexParameterfv(target, pname, params);
+}
+
+void gl4_0core_glTexParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glTexParameterf(target, pname, param);
+}
+
+void gl4_0core_glScissor(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glScissor(x, y, width, height);
+}
+
+void gl4_0core_glPolygonMode(void *_glfuncs, GLenum face, GLenum mode)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glPolygonMode(face, mode);
+}
+
+void gl4_0core_glPointSize(void *_glfuncs, GLfloat size)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glPointSize(size);
+}
+
+void gl4_0core_glLineWidth(void *_glfuncs, GLfloat width)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glLineWidth(width);
+}
+
+void gl4_0core_glHint(void *_glfuncs, GLenum target, GLenum mode)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glHint(target, mode);
+}
+
+void gl4_0core_glFrontFace(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glFrontFace(mode);
+}
+
+void gl4_0core_glCullFace(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glCullFace(mode);
+}
+
+void gl4_0core_glIndexubv(void *_glfuncs, const GLubyte* c)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glIndexubv(c);
+}
+
+void gl4_0core_glIndexub(void *_glfuncs, GLubyte c)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glIndexub(c);
+}
+
+GLboolean gl4_0core_glIsTexture(void *_glfuncs, GLuint texture)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ return _qglfuncs->glIsTexture(texture);
+}
+
+void gl4_0core_glGenTextures(void *_glfuncs, GLsizei n, GLuint* textures)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGenTextures(n, textures);
+}
+
+void gl4_0core_glDeleteTextures(void *_glfuncs, GLsizei n, const GLuint* textures)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glDeleteTextures(n, textures);
+}
+
+void gl4_0core_glBindTexture(void *_glfuncs, GLenum target, GLuint texture)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glBindTexture(target, texture);
+}
+
+void gl4_0core_glTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glTexSubImage2D(target, level, xoffset, yoffset, width, height, format, gltype, pixels);
+}
+
+void gl4_0core_glTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glTexSubImage1D(target, level, xoffset, width, format, gltype, pixels);
+}
+
+void gl4_0core_glCopyTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage2D(target, level, xoffset, yoffset, x, y, width, height);
+}
+
+void gl4_0core_glCopyTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage1D(target, level, xoffset, x, y, width);
+}
+
+void gl4_0core_glCopyTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glCopyTexImage2D(target, level, internalFormat, x, y, width, height, border);
+}
+
+void gl4_0core_glCopyTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLint border)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glCopyTexImage1D(target, level, internalFormat, x, y, width, border);
+}
+
+void gl4_0core_glPolygonOffset(void *_glfuncs, GLfloat factor, GLfloat units)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glPolygonOffset(factor, units);
+}
+
+void gl4_0core_glDrawElements(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glDrawElements(mode, count, gltype, indices);
+}
+
+void gl4_0core_glDrawArrays(void *_glfuncs, GLenum mode, GLint first, GLsizei count)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glDrawArrays(mode, first, count);
+}
+
+void gl4_0core_glCopyTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage3D(target, level, xoffset, yoffset, zoffset, x, y, width, height);
+}
+
+void gl4_0core_glTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glTexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, gltype, pixels);
+}
+
+void gl4_0core_glTexImage3D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glTexImage3D(target, level, internalFormat, width, height, depth, border, format, gltype, pixels);
+}
+
+void gl4_0core_glDrawRangeElements(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glDrawRangeElements(mode, start, end, count, gltype, indices);
+}
+
+void gl4_0core_glBlendEquation(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glBlendEquation(mode);
+}
+
+void gl4_0core_glBlendColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glBlendColor(red, green, blue, alpha);
+}
+
+void gl4_0core_glGetCompressedTexImage(void *_glfuncs, GLenum target, GLint level, GLvoid* img)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGetCompressedTexImage(target, level, img);
+}
+
+void gl4_0core_glCompressedTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glCompressedTexSubImage1D(target, level, xoffset, width, format, imageSize, data);
+}
+
+void gl4_0core_glCompressedTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glCompressedTexSubImage2D(target, level, xoffset, yoffset, width, height, format, imageSize, data);
+}
+
+void gl4_0core_glCompressedTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glCompressedTexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, imageSize, data);
+}
+
+void gl4_0core_glCompressedTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glCompressedTexImage1D(target, level, internalFormat, width, border, imageSize, data);
+}
+
+void gl4_0core_glCompressedTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glCompressedTexImage2D(target, level, internalFormat, width, height, border, imageSize, data);
+}
+
+void gl4_0core_glCompressedTexImage3D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glCompressedTexImage3D(target, level, internalFormat, width, height, depth, border, imageSize, data);
+}
+
+void gl4_0core_glSampleCoverage(void *_glfuncs, GLfloat value, GLboolean invert)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glSampleCoverage(value, invert);
+}
+
+void gl4_0core_glActiveTexture(void *_glfuncs, GLenum texture)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glActiveTexture(texture);
+}
+
+void gl4_0core_glPointParameteriv(void *_glfuncs, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glPointParameteriv(pname, params);
+}
+
+void gl4_0core_glPointParameteri(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glPointParameteri(pname, param);
+}
+
+void gl4_0core_glPointParameterfv(void *_glfuncs, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glPointParameterfv(pname, params);
+}
+
+void gl4_0core_glPointParameterf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glPointParameterf(pname, param);
+}
+
+void gl4_0core_glMultiDrawArrays(void *_glfuncs, GLenum mode, const GLint* first, const GLsizei* count, GLsizei drawcount)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glMultiDrawArrays(mode, first, count, drawcount);
+}
+
+void gl4_0core_glBlendFuncSeparate(void *_glfuncs, GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glBlendFuncSeparate(sfactorRGB, dfactorRGB, sfactorAlpha, dfactorAlpha);
+}
+
+void gl4_0core_glGetBufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGetBufferParameteriv(target, pname, params);
+}
+
+GLboolean gl4_0core_glUnmapBuffer(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ return _qglfuncs->glUnmapBuffer(target);
+}
+
+void gl4_0core_glGetBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, GLvoid* data)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGetBufferSubData(target, offset, size, data);
+}
+
+void gl4_0core_glBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid* data)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glBufferSubData(target, offset, size, data);
+}
+
+void gl4_0core_glBufferData(void *_glfuncs, GLenum target, GLsizeiptr size, const GLvoid* data, GLenum usage)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glBufferData(target, size, data, usage);
+}
+
+GLboolean gl4_0core_glIsBuffer(void *_glfuncs, GLuint buffer)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ return _qglfuncs->glIsBuffer(buffer);
+}
+
+void gl4_0core_glGenBuffers(void *_glfuncs, GLsizei n, GLuint* buffers)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGenBuffers(n, buffers);
+}
+
+void gl4_0core_glDeleteBuffers(void *_glfuncs, GLsizei n, const GLuint* buffers)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glDeleteBuffers(n, buffers);
+}
+
+void gl4_0core_glBindBuffer(void *_glfuncs, GLenum target, GLuint buffer)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glBindBuffer(target, buffer);
+}
+
+void gl4_0core_glGetQueryObjectuiv(void *_glfuncs, GLuint id, GLenum pname, GLuint* params)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGetQueryObjectuiv(id, pname, params);
+}
+
+void gl4_0core_glGetQueryObjectiv(void *_glfuncs, GLuint id, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGetQueryObjectiv(id, pname, params);
+}
+
+void gl4_0core_glGetQueryiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGetQueryiv(target, pname, params);
+}
+
+void gl4_0core_glEndQuery(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glEndQuery(target);
+}
+
+void gl4_0core_glBeginQuery(void *_glfuncs, GLenum target, GLuint id)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glBeginQuery(target, id);
+}
+
+GLboolean gl4_0core_glIsQuery(void *_glfuncs, GLuint id)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ return _qglfuncs->glIsQuery(id);
+}
+
+void gl4_0core_glDeleteQueries(void *_glfuncs, GLsizei n, const GLuint* ids)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glDeleteQueries(n, ids);
+}
+
+void gl4_0core_glGenQueries(void *_glfuncs, GLsizei n, GLuint* ids)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGenQueries(n, ids);
+}
+
+void gl4_0core_glVertexAttribPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLboolean normalized, GLsizei stride, const GLvoid* offset)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribPointer(index, size, gltype, normalized, stride, offset);
+}
+
+void gl4_0core_glValidateProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glValidateProgram(program);
+}
+
+void gl4_0core_glUniformMatrix4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4fv(location, count, transpose, value);
+}
+
+void gl4_0core_glUniformMatrix3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3fv(location, count, transpose, value);
+}
+
+void gl4_0core_glUniformMatrix2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2fv(location, count, transpose, value);
+}
+
+void gl4_0core_glUniform4iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glUniform4iv(location, count, value);
+}
+
+void gl4_0core_glUniform3iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glUniform3iv(location, count, value);
+}
+
+void gl4_0core_glUniform2iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glUniform2iv(location, count, value);
+}
+
+void gl4_0core_glUniform1iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glUniform1iv(location, count, value);
+}
+
+void gl4_0core_glUniform4fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glUniform4fv(location, count, value);
+}
+
+void gl4_0core_glUniform3fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glUniform3fv(location, count, value);
+}
+
+void gl4_0core_glUniform2fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glUniform2fv(location, count, value);
+}
+
+void gl4_0core_glUniform1fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glUniform1fv(location, count, value);
+}
+
+void gl4_0core_glUniform4i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2, GLint v3)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glUniform4i(location, v0, v1, v2, v3);
+}
+
+void gl4_0core_glUniform3i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glUniform3i(location, v0, v1, v2);
+}
+
+void gl4_0core_glUniform2i(void *_glfuncs, GLint location, GLint v0, GLint v1)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glUniform2i(location, v0, v1);
+}
+
+void gl4_0core_glUniform1i(void *_glfuncs, GLint location, GLint v0)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glUniform1i(location, v0);
+}
+
+void gl4_0core_glUniform4f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glUniform4f(location, v0, v1, v2, v3);
+}
+
+void gl4_0core_glUniform3f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glUniform3f(location, v0, v1, v2);
+}
+
+void gl4_0core_glUniform2f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glUniform2f(location, v0, v1);
+}
+
+void gl4_0core_glUniform1f(void *_glfuncs, GLint location, GLfloat v0)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glUniform1f(location, v0);
+}
+
+void gl4_0core_glUseProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glUseProgram(program);
+}
+
+void gl4_0core_glShaderSource(void *_glfuncs, GLuint shader, GLsizei count, const GLchar** source, const GLint* length)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glShaderSource(shader, count, source, length);
+}
+
+void gl4_0core_glLinkProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glLinkProgram(program);
+}
+
+GLboolean gl4_0core_glIsShader(void *_glfuncs, GLuint shader)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ return _qglfuncs->glIsShader(shader);
+}
+
+GLboolean gl4_0core_glIsProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ return _qglfuncs->glIsProgram(program);
+}
+
+void gl4_0core_glGetVertexAttribiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribiv(index, pname, params);
+}
+
+void gl4_0core_glGetVertexAttribfv(void *_glfuncs, GLuint index, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribfv(index, pname, params);
+}
+
+void gl4_0core_glGetVertexAttribdv(void *_glfuncs, GLuint index, GLenum pname, GLdouble* params)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribdv(index, pname, params);
+}
+
+void gl4_0core_glGetUniformiv(void *_glfuncs, GLuint program, GLint location, GLint* params)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGetUniformiv(program, location, params);
+}
+
+void gl4_0core_glGetUniformfv(void *_glfuncs, GLuint program, GLint location, GLfloat* params)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGetUniformfv(program, location, params);
+}
+
+GLint gl4_0core_glGetUniformLocation(void *_glfuncs, GLuint program, const GLchar* name)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ return _qglfuncs->glGetUniformLocation(program, name);
+}
+
+void gl4_0core_glGetShaderSource(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* source)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGetShaderSource(shader, bufSize, length, source);
+}
+
+void gl4_0core_glGetShaderInfoLog(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* infoLog)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGetShaderInfoLog(shader, bufSize, length, infoLog);
+}
+
+void gl4_0core_glGetShaderiv(void *_glfuncs, GLuint shader, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGetShaderiv(shader, pname, params);
+}
+
+void gl4_0core_glGetProgramInfoLog(void *_glfuncs, GLuint program, GLsizei bufSize, GLsizei* length, GLchar* infoLog)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGetProgramInfoLog(program, bufSize, length, infoLog);
+}
+
+void gl4_0core_glGetProgramiv(void *_glfuncs, GLuint program, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGetProgramiv(program, pname, params);
+}
+
+GLint gl4_0core_glGetAttribLocation(void *_glfuncs, GLuint program, const GLchar* name)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ return _qglfuncs->glGetAttribLocation(program, name);
+}
+
+void gl4_0core_glGetAttachedShaders(void *_glfuncs, GLuint program, GLsizei maxCount, GLsizei* count, GLuint* obj)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGetAttachedShaders(program, maxCount, count, obj);
+}
+
+void gl4_0core_glGetActiveUniform(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGetActiveUniform(program, index, bufSize, length, size, gltype, name);
+}
+
+void gl4_0core_glGetActiveAttrib(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGetActiveAttrib(program, index, bufSize, length, size, gltype, name);
+}
+
+void gl4_0core_glEnableVertexAttribArray(void *_glfuncs, GLuint index)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glEnableVertexAttribArray(index);
+}
+
+void gl4_0core_glDisableVertexAttribArray(void *_glfuncs, GLuint index)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glDisableVertexAttribArray(index);
+}
+
+void gl4_0core_glDetachShader(void *_glfuncs, GLuint program, GLuint shader)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glDetachShader(program, shader);
+}
+
+void gl4_0core_glDeleteShader(void *_glfuncs, GLuint shader)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glDeleteShader(shader);
+}
+
+void gl4_0core_glDeleteProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glDeleteProgram(program);
+}
+
+GLuint gl4_0core_glCreateShader(void *_glfuncs, GLenum gltype)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ return _qglfuncs->glCreateShader(gltype);
+}
+
+GLuint gl4_0core_glCreateProgram(void *_glfuncs)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ return _qglfuncs->glCreateProgram();
+}
+
+void gl4_0core_glCompileShader(void *_glfuncs, GLuint shader)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glCompileShader(shader);
+}
+
+void gl4_0core_glBindAttribLocation(void *_glfuncs, GLuint program, GLuint index, const GLchar* name)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glBindAttribLocation(program, index, name);
+}
+
+void gl4_0core_glAttachShader(void *_glfuncs, GLuint program, GLuint shader)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glAttachShader(program, shader);
+}
+
+void gl4_0core_glStencilMaskSeparate(void *_glfuncs, GLenum face, GLuint mask)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glStencilMaskSeparate(face, mask);
+}
+
+void gl4_0core_glStencilFuncSeparate(void *_glfuncs, GLenum face, GLenum glfunc, GLint ref, GLuint mask)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glStencilFuncSeparate(face, glfunc, ref, mask);
+}
+
+void gl4_0core_glStencilOpSeparate(void *_glfuncs, GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glStencilOpSeparate(face, sfail, dpfail, dppass);
+}
+
+void gl4_0core_glDrawBuffers(void *_glfuncs, GLsizei n, const GLenum* bufs)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glDrawBuffers(n, bufs);
+}
+
+void gl4_0core_glBlendEquationSeparate(void *_glfuncs, GLenum modeRGB, GLenum modeAlpha)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glBlendEquationSeparate(modeRGB, modeAlpha);
+}
+
+void gl4_0core_glUniformMatrix4x3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4x3fv(location, count, transpose, value);
+}
+
+void gl4_0core_glUniformMatrix3x4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3x4fv(location, count, transpose, value);
+}
+
+void gl4_0core_glUniformMatrix4x2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4x2fv(location, count, transpose, value);
+}
+
+void gl4_0core_glUniformMatrix2x4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2x4fv(location, count, transpose, value);
+}
+
+void gl4_0core_glUniformMatrix3x2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3x2fv(location, count, transpose, value);
+}
+
+void gl4_0core_glUniformMatrix2x3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2x3fv(location, count, transpose, value);
+}
+
+GLboolean gl4_0core_glIsVertexArray(void *_glfuncs, GLuint array)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ return _qglfuncs->glIsVertexArray(array);
+}
+
+void gl4_0core_glGenVertexArrays(void *_glfuncs, GLsizei n, GLuint* arrays)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGenVertexArrays(n, arrays);
+}
+
+void gl4_0core_glDeleteVertexArrays(void *_glfuncs, GLsizei n, const GLuint* arrays)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glDeleteVertexArrays(n, arrays);
+}
+
+void gl4_0core_glBindVertexArray(void *_glfuncs, GLuint array)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glBindVertexArray(array);
+}
+
+void gl4_0core_glFlushMappedBufferRange(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr length)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glFlushMappedBufferRange(target, offset, length);
+}
+
+void gl4_0core_glFramebufferTextureLayer(void *_glfuncs, GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glFramebufferTextureLayer(target, attachment, texture, level, layer);
+}
+
+void gl4_0core_glRenderbufferStorageMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLenum internalFormat, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glRenderbufferStorageMultisample(target, samples, internalFormat, width, height);
+}
+
+void gl4_0core_glBlitFramebuffer(void *_glfuncs, GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glBlitFramebuffer(srcX0, srcY0, srcX1, srcY1, dstX0, dstY0, dstX1, dstY1, mask, filter);
+}
+
+void gl4_0core_glGenerateMipmap(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGenerateMipmap(target);
+}
+
+void gl4_0core_glGetFramebufferAttachmentParameteriv(void *_glfuncs, GLenum target, GLenum attachment, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGetFramebufferAttachmentParameteriv(target, attachment, pname, params);
+}
+
+void gl4_0core_glFramebufferRenderbuffer(void *_glfuncs, GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glFramebufferRenderbuffer(target, attachment, renderbuffertarget, renderbuffer);
+}
+
+void gl4_0core_glFramebufferTexture3D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glFramebufferTexture3D(target, attachment, textarget, texture, level, zoffset);
+}
+
+void gl4_0core_glFramebufferTexture2D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glFramebufferTexture2D(target, attachment, textarget, texture, level);
+}
+
+void gl4_0core_glFramebufferTexture1D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glFramebufferTexture1D(target, attachment, textarget, texture, level);
+}
+
+GLenum gl4_0core_glCheckFramebufferStatus(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ return _qglfuncs->glCheckFramebufferStatus(target);
+}
+
+void gl4_0core_glGenFramebuffers(void *_glfuncs, GLsizei n, GLuint* framebuffers)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGenFramebuffers(n, framebuffers);
+}
+
+void gl4_0core_glDeleteFramebuffers(void *_glfuncs, GLsizei n, const GLuint* framebuffers)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glDeleteFramebuffers(n, framebuffers);
+}
+
+void gl4_0core_glBindFramebuffer(void *_glfuncs, GLenum target, GLuint framebuffer)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glBindFramebuffer(target, framebuffer);
+}
+
+GLboolean gl4_0core_glIsFramebuffer(void *_glfuncs, GLuint framebuffer)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ return _qglfuncs->glIsFramebuffer(framebuffer);
+}
+
+void gl4_0core_glGetRenderbufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGetRenderbufferParameteriv(target, pname, params);
+}
+
+void gl4_0core_glRenderbufferStorage(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glRenderbufferStorage(target, internalFormat, width, height);
+}
+
+void gl4_0core_glGenRenderbuffers(void *_glfuncs, GLsizei n, GLuint* renderbuffers)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGenRenderbuffers(n, renderbuffers);
+}
+
+void gl4_0core_glDeleteRenderbuffers(void *_glfuncs, GLsizei n, const GLuint* renderbuffers)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glDeleteRenderbuffers(n, renderbuffers);
+}
+
+void gl4_0core_glBindRenderbuffer(void *_glfuncs, GLenum target, GLuint renderbuffer)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glBindRenderbuffer(target, renderbuffer);
+}
+
+GLboolean gl4_0core_glIsRenderbuffer(void *_glfuncs, GLuint renderbuffer)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ return _qglfuncs->glIsRenderbuffer(renderbuffer);
+}
+
+void gl4_0core_glClearBufferfi(void *_glfuncs, GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glClearBufferfi(buffer, drawbuffer, depth, stencil);
+}
+
+void gl4_0core_glClearBufferfv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLfloat* value)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glClearBufferfv(buffer, drawbuffer, value);
+}
+
+void gl4_0core_glClearBufferuiv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLuint* value)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glClearBufferuiv(buffer, drawbuffer, value);
+}
+
+void gl4_0core_glClearBufferiv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLint* value)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glClearBufferiv(buffer, drawbuffer, value);
+}
+
+void gl4_0core_glGetTexParameterIuiv(void *_glfuncs, GLenum target, GLenum pname, GLuint* params)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGetTexParameterIuiv(target, pname, params);
+}
+
+void gl4_0core_glGetTexParameterIiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGetTexParameterIiv(target, pname, params);
+}
+
+void gl4_0core_glTexParameterIuiv(void *_glfuncs, GLenum target, GLenum pname, const GLuint* params)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glTexParameterIuiv(target, pname, params);
+}
+
+void gl4_0core_glTexParameterIiv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glTexParameterIiv(target, pname, params);
+}
+
+void gl4_0core_glUniform4uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glUniform4uiv(location, count, value);
+}
+
+void gl4_0core_glUniform3uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glUniform3uiv(location, count, value);
+}
+
+void gl4_0core_glUniform2uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glUniform2uiv(location, count, value);
+}
+
+void gl4_0core_glUniform1uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glUniform1uiv(location, count, value);
+}
+
+void gl4_0core_glUniform4ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glUniform4ui(location, v0, v1, v2, v3);
+}
+
+void gl4_0core_glUniform3ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1, GLuint v2)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glUniform3ui(location, v0, v1, v2);
+}
+
+void gl4_0core_glUniform2ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glUniform2ui(location, v0, v1);
+}
+
+void gl4_0core_glUniform1ui(void *_glfuncs, GLint location, GLuint v0)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glUniform1ui(location, v0);
+}
+
+GLint gl4_0core_glGetFragDataLocation(void *_glfuncs, GLuint program, const GLchar* name)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ return _qglfuncs->glGetFragDataLocation(program, name);
+}
+
+void gl4_0core_glBindFragDataLocation(void *_glfuncs, GLuint program, GLuint color, const GLchar* name)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glBindFragDataLocation(program, color, name);
+}
+
+void gl4_0core_glGetUniformuiv(void *_glfuncs, GLuint program, GLint location, GLuint* params)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGetUniformuiv(program, location, params);
+}
+
+void gl4_0core_glGetVertexAttribIuiv(void *_glfuncs, GLuint index, GLenum pname, GLuint* params)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribIuiv(index, pname, params);
+}
+
+void gl4_0core_glGetVertexAttribIiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribIiv(index, pname, params);
+}
+
+void gl4_0core_glVertexAttribIPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribIPointer(index, size, gltype, stride, pointer);
+}
+
+void gl4_0core_glEndConditionalRender(void *_glfuncs)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glEndConditionalRender();
+}
+
+void gl4_0core_glBeginConditionalRender(void *_glfuncs, GLuint id, GLenum mode)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glBeginConditionalRender(id, mode);
+}
+
+void gl4_0core_glClampColor(void *_glfuncs, GLenum target, GLenum clamp)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glClampColor(target, clamp);
+}
+
+void gl4_0core_glGetTransformFeedbackVarying(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLsizei* size, GLenum* gltype, GLchar* name)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGetTransformFeedbackVarying(program, index, bufSize, length, size, gltype, name);
+}
+
+void gl4_0core_glBindBufferBase(void *_glfuncs, GLenum target, GLuint index, GLuint buffer)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glBindBufferBase(target, index, buffer);
+}
+
+void gl4_0core_glBindBufferRange(void *_glfuncs, GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glBindBufferRange(target, index, buffer, offset, size);
+}
+
+void gl4_0core_glEndTransformFeedback(void *_glfuncs)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glEndTransformFeedback();
+}
+
+void gl4_0core_glBeginTransformFeedback(void *_glfuncs, GLenum primitiveMode)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glBeginTransformFeedback(primitiveMode);
+}
+
+GLboolean gl4_0core_glIsEnabledi(void *_glfuncs, GLenum target, GLuint index)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ return _qglfuncs->glIsEnabledi(target, index);
+}
+
+void gl4_0core_glDisablei(void *_glfuncs, GLenum target, GLuint index)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glDisablei(target, index);
+}
+
+void gl4_0core_glEnablei(void *_glfuncs, GLenum target, GLuint index)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glEnablei(target, index);
+}
+
+void gl4_0core_glGetIntegeri_v(void *_glfuncs, GLenum target, GLuint index, GLint* data)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGetIntegeri_v(target, index, data);
+}
+
+void gl4_0core_glGetBooleani_v(void *_glfuncs, GLenum target, GLuint index, GLboolean* data)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGetBooleani_v(target, index, data);
+}
+
+void gl4_0core_glColorMaski(void *_glfuncs, GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glColorMaski(index, r, g, b, a);
+}
+
+void gl4_0core_glCopyBufferSubData(void *_glfuncs, GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glCopyBufferSubData(readTarget, writeTarget, readOffset, writeOffset, size);
+}
+
+void gl4_0core_glUniformBlockBinding(void *_glfuncs, GLuint program, GLuint v0, GLuint v1)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glUniformBlockBinding(program, v0, v1);
+}
+
+void gl4_0core_glGetActiveUniformBlockName(void *_glfuncs, GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei* length, GLchar* uniformBlockName)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGetActiveUniformBlockName(program, uniformBlockIndex, bufSize, length, uniformBlockName);
+}
+
+void gl4_0core_glGetActiveUniformBlockiv(void *_glfuncs, GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGetActiveUniformBlockiv(program, uniformBlockIndex, pname, params);
+}
+
+GLuint gl4_0core_glGetUniformBlockIndex(void *_glfuncs, GLuint program, const GLchar* uniformBlockName)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ return _qglfuncs->glGetUniformBlockIndex(program, uniformBlockName);
+}
+
+void gl4_0core_glGetActiveUniformName(void *_glfuncs, GLuint program, GLuint uniformIndex, GLsizei bufSize, GLsizei* length, GLchar* uniformName)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGetActiveUniformName(program, uniformIndex, bufSize, length, uniformName);
+}
+
+void gl4_0core_glGetActiveUniformsiv(void *_glfuncs, GLuint program, GLsizei uniformCount, const GLuint* uniformIndices, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGetActiveUniformsiv(program, uniformCount, uniformIndices, pname, params);
+}
+
+void gl4_0core_glPrimitiveRestartIndex(void *_glfuncs, GLuint index)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glPrimitiveRestartIndex(index);
+}
+
+void gl4_0core_glTexBuffer(void *_glfuncs, GLenum target, GLenum internalFormat, GLuint buffer)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glTexBuffer(target, internalFormat, buffer);
+}
+
+void gl4_0core_glDrawElementsInstanced(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glDrawElementsInstanced(mode, count, gltype, indices, instancecount);
+}
+
+void gl4_0core_glDrawArraysInstanced(void *_glfuncs, GLenum mode, GLint first, GLsizei count, GLsizei instancecount)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glDrawArraysInstanced(mode, first, count, instancecount);
+}
+
+void gl4_0core_glSampleMaski(void *_glfuncs, GLuint index, GLbitfield mask)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glSampleMaski(index, mask);
+}
+
+void gl4_0core_glGetMultisamplefv(void *_glfuncs, GLenum pname, GLuint index, GLfloat* val)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGetMultisamplefv(pname, index, val);
+}
+
+void gl4_0core_glTexImage3DMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glTexImage3DMultisample(target, samples, internalFormat, width, height, depth, fixedsamplelocations);
+}
+
+void gl4_0core_glTexImage2DMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLint internalFormat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glTexImage2DMultisample(target, samples, internalFormat, width, height, fixedsamplelocations);
+}
+
+void gl4_0core_glGetSynciv(void *_glfuncs, GLsync sync, GLenum pname, GLsizei bufSize, GLsizei* length, GLint* values)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGetSynciv(sync, pname, bufSize, length, values);
+}
+
+void gl4_0core_glGetInteger64v(void *_glfuncs, GLenum pname, GLint64* params)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGetInteger64v(pname, params);
+}
+
+void gl4_0core_glWaitSync(void *_glfuncs, GLsync sync, GLbitfield flags, GLuint64 timeout)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glWaitSync(sync, flags, timeout);
+}
+
+GLenum gl4_0core_glClientWaitSync(void *_glfuncs, GLsync sync, GLbitfield flags, GLuint64 timeout)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ return _qglfuncs->glClientWaitSync(sync, flags, timeout);
+}
+
+void gl4_0core_glDeleteSync(void *_glfuncs, GLsync sync)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glDeleteSync(sync);
+}
+
+GLboolean gl4_0core_glIsSync(void *_glfuncs, GLsync sync)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ return _qglfuncs->glIsSync(sync);
+}
+
+GLsync gl4_0core_glFenceSync(void *_glfuncs, GLenum condition, GLbitfield flags)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ return _qglfuncs->glFenceSync(condition, flags);
+}
+
+void gl4_0core_glProvokingVertex(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glProvokingVertex(mode);
+}
+
+void gl4_0core_glDrawElementsInstancedBaseVertex(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount, GLint basevertex)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glDrawElementsInstancedBaseVertex(mode, count, gltype, indices, instancecount, basevertex);
+}
+
+void gl4_0core_glDrawRangeElementsBaseVertex(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices, GLint basevertex)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glDrawRangeElementsBaseVertex(mode, start, end, count, gltype, indices, basevertex);
+}
+
+void gl4_0core_glDrawElementsBaseVertex(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLint basevertex)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glDrawElementsBaseVertex(mode, count, gltype, indices, basevertex);
+}
+
+void gl4_0core_glFramebufferTexture(void *_glfuncs, GLenum target, GLenum attachment, GLuint texture, GLint level)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glFramebufferTexture(target, attachment, texture, level);
+}
+
+void gl4_0core_glGetBufferParameteri64v(void *_glfuncs, GLenum target, GLenum pname, GLint64* params)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGetBufferParameteri64v(target, pname, params);
+}
+
+void gl4_0core_glGetInteger64i_v(void *_glfuncs, GLenum target, GLuint index, GLint64* data)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGetInteger64i_v(target, index, data);
+}
+
+void gl4_0core_glVertexAttribP4uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribP4uiv(index, gltype, normalized, value);
+}
+
+void gl4_0core_glVertexAttribP4ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribP4ui(index, gltype, normalized, value);
+}
+
+void gl4_0core_glVertexAttribP3uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribP3uiv(index, gltype, normalized, value);
+}
+
+void gl4_0core_glVertexAttribP3ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribP3ui(index, gltype, normalized, value);
+}
+
+void gl4_0core_glVertexAttribP2uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribP2uiv(index, gltype, normalized, value);
+}
+
+void gl4_0core_glVertexAttribP2ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribP2ui(index, gltype, normalized, value);
+}
+
+void gl4_0core_glVertexAttribP1uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribP1uiv(index, gltype, normalized, value);
+}
+
+void gl4_0core_glVertexAttribP1ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribP1ui(index, gltype, normalized, value);
+}
+
+void gl4_0core_glSecondaryColorP3uiv(void *_glfuncs, GLenum gltype, const GLuint* color)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glSecondaryColorP3uiv(gltype, color);
+}
+
+void gl4_0core_glSecondaryColorP3ui(void *_glfuncs, GLenum gltype, GLuint color)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glSecondaryColorP3ui(gltype, color);
+}
+
+void gl4_0core_glColorP4uiv(void *_glfuncs, GLenum gltype, const GLuint* color)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glColorP4uiv(gltype, color);
+}
+
+void gl4_0core_glColorP4ui(void *_glfuncs, GLenum gltype, GLuint color)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glColorP4ui(gltype, color);
+}
+
+void gl4_0core_glColorP3uiv(void *_glfuncs, GLenum gltype, const GLuint* color)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glColorP3uiv(gltype, color);
+}
+
+void gl4_0core_glColorP3ui(void *_glfuncs, GLenum gltype, GLuint color)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glColorP3ui(gltype, color);
+}
+
+void gl4_0core_glNormalP3uiv(void *_glfuncs, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glNormalP3uiv(gltype, coords);
+}
+
+void gl4_0core_glNormalP3ui(void *_glfuncs, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glNormalP3ui(gltype, coords);
+}
+
+void gl4_0core_glMultiTexCoordP4uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP4uiv(texture, gltype, coords);
+}
+
+void gl4_0core_glMultiTexCoordP4ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP4ui(texture, gltype, coords);
+}
+
+void gl4_0core_glMultiTexCoordP3uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP3uiv(texture, gltype, coords);
+}
+
+void gl4_0core_glMultiTexCoordP3ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP3ui(texture, gltype, coords);
+}
+
+void gl4_0core_glMultiTexCoordP2uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP2uiv(texture, gltype, coords);
+}
+
+void gl4_0core_glMultiTexCoordP2ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP2ui(texture, gltype, coords);
+}
+
+void gl4_0core_glMultiTexCoordP1uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP1uiv(texture, gltype, coords);
+}
+
+void gl4_0core_glMultiTexCoordP1ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP1ui(texture, gltype, coords);
+}
+
+void gl4_0core_glTexCoordP4uiv(void *_glfuncs, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glTexCoordP4uiv(gltype, coords);
+}
+
+void gl4_0core_glTexCoordP4ui(void *_glfuncs, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glTexCoordP4ui(gltype, coords);
+}
+
+void gl4_0core_glTexCoordP3uiv(void *_glfuncs, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glTexCoordP3uiv(gltype, coords);
+}
+
+void gl4_0core_glTexCoordP3ui(void *_glfuncs, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glTexCoordP3ui(gltype, coords);
+}
+
+void gl4_0core_glTexCoordP2uiv(void *_glfuncs, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glTexCoordP2uiv(gltype, coords);
+}
+
+void gl4_0core_glTexCoordP2ui(void *_glfuncs, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glTexCoordP2ui(gltype, coords);
+}
+
+void gl4_0core_glTexCoordP1uiv(void *_glfuncs, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glTexCoordP1uiv(gltype, coords);
+}
+
+void gl4_0core_glTexCoordP1ui(void *_glfuncs, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glTexCoordP1ui(gltype, coords);
+}
+
+void gl4_0core_glVertexP4uiv(void *_glfuncs, GLenum gltype, const GLuint* value)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glVertexP4uiv(gltype, value);
+}
+
+void gl4_0core_glVertexP4ui(void *_glfuncs, GLenum gltype, GLuint value)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glVertexP4ui(gltype, value);
+}
+
+void gl4_0core_glVertexP3uiv(void *_glfuncs, GLenum gltype, const GLuint* value)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glVertexP3uiv(gltype, value);
+}
+
+void gl4_0core_glVertexP3ui(void *_glfuncs, GLenum gltype, GLuint value)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glVertexP3ui(gltype, value);
+}
+
+void gl4_0core_glVertexP2uiv(void *_glfuncs, GLenum gltype, const GLuint* value)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glVertexP2uiv(gltype, value);
+}
+
+void gl4_0core_glVertexP2ui(void *_glfuncs, GLenum gltype, GLuint value)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glVertexP2ui(gltype, value);
+}
+
+void gl4_0core_glGetQueryObjectui64v(void *_glfuncs, GLuint id, GLenum pname, GLuint64* params)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGetQueryObjectui64v(id, pname, params);
+}
+
+void gl4_0core_glGetQueryObjecti64v(void *_glfuncs, GLuint id, GLenum pname, GLint64* params)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGetQueryObjecti64v(id, pname, params);
+}
+
+void gl4_0core_glQueryCounter(void *_glfuncs, GLuint id, GLenum target)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glQueryCounter(id, target);
+}
+
+void gl4_0core_glGetSamplerParameterIuiv(void *_glfuncs, GLuint sampler, GLenum pname, GLuint* params)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGetSamplerParameterIuiv(sampler, pname, params);
+}
+
+void gl4_0core_glGetSamplerParameterfv(void *_glfuncs, GLuint sampler, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGetSamplerParameterfv(sampler, pname, params);
+}
+
+void gl4_0core_glGetSamplerParameterIiv(void *_glfuncs, GLuint sampler, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGetSamplerParameterIiv(sampler, pname, params);
+}
+
+void gl4_0core_glGetSamplerParameteriv(void *_glfuncs, GLuint sampler, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGetSamplerParameteriv(sampler, pname, params);
+}
+
+void gl4_0core_glSamplerParameterIuiv(void *_glfuncs, GLuint sampler, GLenum pname, const GLuint* param)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glSamplerParameterIuiv(sampler, pname, param);
+}
+
+void gl4_0core_glSamplerParameterIiv(void *_glfuncs, GLuint sampler, GLenum pname, const GLint* param)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glSamplerParameterIiv(sampler, pname, param);
+}
+
+void gl4_0core_glSamplerParameterfv(void *_glfuncs, GLuint sampler, GLenum pname, const GLfloat* param)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glSamplerParameterfv(sampler, pname, param);
+}
+
+void gl4_0core_glSamplerParameterf(void *_glfuncs, GLuint sampler, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glSamplerParameterf(sampler, pname, param);
+}
+
+void gl4_0core_glSamplerParameteriv(void *_glfuncs, GLuint sampler, GLenum pname, const GLint* param)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glSamplerParameteriv(sampler, pname, param);
+}
+
+void gl4_0core_glSamplerParameteri(void *_glfuncs, GLuint sampler, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glSamplerParameteri(sampler, pname, param);
+}
+
+void gl4_0core_glBindSampler(void *_glfuncs, GLuint unit, GLuint sampler)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glBindSampler(unit, sampler);
+}
+
+GLboolean gl4_0core_glIsSampler(void *_glfuncs, GLuint sampler)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ return _qglfuncs->glIsSampler(sampler);
+}
+
+void gl4_0core_glDeleteSamplers(void *_glfuncs, GLsizei count, const GLuint* samplers)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glDeleteSamplers(count, samplers);
+}
+
+void gl4_0core_glGenSamplers(void *_glfuncs, GLsizei count, GLuint* samplers)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGenSamplers(count, samplers);
+}
+
+GLint gl4_0core_glGetFragDataIndex(void *_glfuncs, GLuint program, const GLchar* name)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ return _qglfuncs->glGetFragDataIndex(program, name);
+}
+
+void gl4_0core_glBindFragDataLocationIndexed(void *_glfuncs, GLuint program, GLuint colorNumber, GLuint index, const GLchar* name)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glBindFragDataLocationIndexed(program, colorNumber, index, name);
+}
+
+void gl4_0core_glVertexAttribDivisor(void *_glfuncs, GLuint index, GLuint divisor)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribDivisor(index, divisor);
+}
+
+void gl4_0core_glGetQueryIndexediv(void *_glfuncs, GLenum target, GLuint index, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGetQueryIndexediv(target, index, pname, params);
+}
+
+void gl4_0core_glEndQueryIndexed(void *_glfuncs, GLenum target, GLuint index)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glEndQueryIndexed(target, index);
+}
+
+void gl4_0core_glBeginQueryIndexed(void *_glfuncs, GLenum target, GLuint index, GLuint id)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glBeginQueryIndexed(target, index, id);
+}
+
+void gl4_0core_glDrawTransformFeedbackStream(void *_glfuncs, GLenum mode, GLuint id, GLuint stream)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glDrawTransformFeedbackStream(mode, id, stream);
+}
+
+void gl4_0core_glDrawTransformFeedback(void *_glfuncs, GLenum mode, GLuint id)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glDrawTransformFeedback(mode, id);
+}
+
+void gl4_0core_glResumeTransformFeedback(void *_glfuncs)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glResumeTransformFeedback();
+}
+
+void gl4_0core_glPauseTransformFeedback(void *_glfuncs)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glPauseTransformFeedback();
+}
+
+GLboolean gl4_0core_glIsTransformFeedback(void *_glfuncs, GLuint id)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ return _qglfuncs->glIsTransformFeedback(id);
+}
+
+void gl4_0core_glGenTransformFeedbacks(void *_glfuncs, GLsizei n, GLuint* ids)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGenTransformFeedbacks(n, ids);
+}
+
+void gl4_0core_glDeleteTransformFeedbacks(void *_glfuncs, GLsizei n, const GLuint* ids)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glDeleteTransformFeedbacks(n, ids);
+}
+
+void gl4_0core_glBindTransformFeedback(void *_glfuncs, GLenum target, GLuint id)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glBindTransformFeedback(target, id);
+}
+
+void gl4_0core_glPatchParameterfv(void *_glfuncs, GLenum pname, const GLfloat* values)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glPatchParameterfv(pname, values);
+}
+
+void gl4_0core_glPatchParameteri(void *_glfuncs, GLenum pname, GLint value)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glPatchParameteri(pname, value);
+}
+
+void gl4_0core_glGetProgramStageiv(void *_glfuncs, GLuint program, GLenum shadertype, GLenum pname, GLint* values)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGetProgramStageiv(program, shadertype, pname, values);
+}
+
+void gl4_0core_glGetUniformSubroutineuiv(void *_glfuncs, GLenum shadertype, GLint location, GLuint* params)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGetUniformSubroutineuiv(shadertype, location, params);
+}
+
+void gl4_0core_glUniformSubroutinesuiv(void *_glfuncs, GLenum shadertype, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glUniformSubroutinesuiv(shadertype, count, value);
+}
+
+void gl4_0core_glGetActiveSubroutineName(void *_glfuncs, GLuint program, GLenum shadertype, GLuint index, GLsizei bufSize, GLsizei* length, GLchar* name)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGetActiveSubroutineName(program, shadertype, index, bufSize, length, name);
+}
+
+void gl4_0core_glGetActiveSubroutineUniformName(void *_glfuncs, GLuint program, GLenum shadertype, GLuint index, GLsizei bufSize, GLsizei* length, GLchar* name)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGetActiveSubroutineUniformName(program, shadertype, index, bufSize, length, name);
+}
+
+void gl4_0core_glGetActiveSubroutineUniformiv(void *_glfuncs, GLuint program, GLenum shadertype, GLuint index, GLenum pname, GLint* values)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGetActiveSubroutineUniformiv(program, shadertype, index, pname, values);
+}
+
+GLuint gl4_0core_glGetSubroutineIndex(void *_glfuncs, GLuint program, GLenum shadertype, const GLchar* name)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ return _qglfuncs->glGetSubroutineIndex(program, shadertype, name);
+}
+
+GLint gl4_0core_glGetSubroutineUniformLocation(void *_glfuncs, GLuint program, GLenum shadertype, const GLchar* name)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ return _qglfuncs->glGetSubroutineUniformLocation(program, shadertype, name);
+}
+
+void gl4_0core_glGetUniformdv(void *_glfuncs, GLuint program, GLint location, GLdouble* params)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glGetUniformdv(program, location, params);
+}
+
+void gl4_0core_glUniformMatrix4x3dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4x3dv(location, count, transpose, value);
+}
+
+void gl4_0core_glUniformMatrix4x2dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4x2dv(location, count, transpose, value);
+}
+
+void gl4_0core_glUniformMatrix3x4dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3x4dv(location, count, transpose, value);
+}
+
+void gl4_0core_glUniformMatrix3x2dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3x2dv(location, count, transpose, value);
+}
+
+void gl4_0core_glUniformMatrix2x4dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2x4dv(location, count, transpose, value);
+}
+
+void gl4_0core_glUniformMatrix2x3dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2x3dv(location, count, transpose, value);
+}
+
+void gl4_0core_glUniformMatrix4dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4dv(location, count, transpose, value);
+}
+
+void gl4_0core_glUniformMatrix3dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3dv(location, count, transpose, value);
+}
+
+void gl4_0core_glUniformMatrix2dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2dv(location, count, transpose, value);
+}
+
+void gl4_0core_glUniform4dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glUniform4dv(location, count, value);
+}
+
+void gl4_0core_glUniform3dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glUniform3dv(location, count, value);
+}
+
+void gl4_0core_glUniform2dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glUniform2dv(location, count, value);
+}
+
+void gl4_0core_glUniform1dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glUniform1dv(location, count, value);
+}
+
+void gl4_0core_glUniform4d(void *_glfuncs, GLint location, GLdouble v0, GLdouble v1, GLdouble v2, GLdouble v3)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glUniform4d(location, v0, v1, v2, v3);
+}
+
+void gl4_0core_glUniform3d(void *_glfuncs, GLint location, GLdouble v0, GLdouble v1, GLdouble v2)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glUniform3d(location, v0, v1, v2);
+}
+
+void gl4_0core_glUniform2d(void *_glfuncs, GLint location, GLdouble v0, GLdouble v1)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glUniform2d(location, v0, v1);
+}
+
+void gl4_0core_glUniform1d(void *_glfuncs, GLint location, GLdouble v0)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glUniform1d(location, v0);
+}
+
+void gl4_0core_glDrawElementsIndirect(void *_glfuncs, GLenum mode, GLenum gltype, const GLvoid* indirect)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glDrawElementsIndirect(mode, gltype, indirect);
+}
+
+void gl4_0core_glDrawArraysIndirect(void *_glfuncs, GLenum mode, const GLvoid* indirect)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glDrawArraysIndirect(mode, indirect);
+}
+
+void gl4_0core_glBlendFuncSeparatei(void *_glfuncs, GLuint buf, GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha, GLenum dstAlpha)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glBlendFuncSeparatei(buf, srcRGB, dstRGB, srcAlpha, dstAlpha);
+}
+
+void gl4_0core_glBlendFunci(void *_glfuncs, GLuint buf, GLenum src, GLenum dst)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glBlendFunci(buf, src, dst);
+}
+
+void gl4_0core_glBlendEquationSeparatei(void *_glfuncs, GLuint buf, GLenum modeRGB, GLenum modeAlpha)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glBlendEquationSeparatei(buf, modeRGB, modeAlpha);
+}
+
+void gl4_0core_glBlendEquationi(void *_glfuncs, GLuint buf, GLenum mode)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glBlendEquationi(buf, mode);
+}
+
+void gl4_0core_glMinSampleShading(void *_glfuncs, GLfloat value)
+{
+ QOpenGLFunctions_4_0_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_0_Core*>(_glfuncs);
+ _qglfuncs->glMinSampleShading(value);
+}
+
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.0core/funcs.h b/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.0core/funcs.h
new file mode 100644
index 000000000..55af051dc
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.0core/funcs.h
@@ -0,0 +1,398 @@
+
+// ** file automatically generated by glgen -- do not edit manually **
+
+#ifndef __cplusplus
+#include <inttypes.h>
+#include <stddef.h>
+typedef unsigned int GLenum;
+typedef unsigned char GLboolean;
+typedef unsigned int GLbitfield;
+typedef void GLvoid;
+typedef char GLchar;
+typedef signed char GLbyte; /* 1-byte signed */
+typedef short GLshort; /* 2-byte signed */
+typedef int GLint; /* 4-byte signed */
+typedef unsigned char GLubyte; /* 1-byte unsigned */
+typedef unsigned short GLushort; /* 2-byte unsigned */
+typedef unsigned int GLuint; /* 4-byte unsigned */
+typedef int GLsizei; /* 4-byte signed */
+typedef float GLfloat; /* single precision float */
+typedef float GLclampf; /* single precision float in [0,1] */
+typedef double GLdouble; /* double precision float */
+typedef double GLclampd; /* double precision float in [0,1] */
+typedef int64_t GLint64;
+typedef uint64_t GLuint64;
+typedef ptrdiff_t GLintptr;
+typedef ptrdiff_t GLsizeiptr;
+typedef ptrdiff_t GLintptrARB;
+typedef ptrdiff_t GLsizeiptrARB;
+typedef struct __GLsync *GLsync;
+#endif
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+void *gl4_0core_funcs();
+
+void gl4_0core_glViewport(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl4_0core_glDepthRange(void *_glfuncs, GLdouble nearVal, GLdouble farVal);
+GLboolean gl4_0core_glIsEnabled(void *_glfuncs, GLenum cap);
+void gl4_0core_glGetTexLevelParameteriv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLint* params);
+void gl4_0core_glGetTexLevelParameterfv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLfloat* params);
+void gl4_0core_glGetTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl4_0core_glGetTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl4_0core_glGetTexImage(void *_glfuncs, GLenum target, GLint level, GLenum format, GLenum gltype, GLvoid* pixels);
+void gl4_0core_glGetIntegerv(void *_glfuncs, GLenum pname, GLint* params);
+void gl4_0core_glGetFloatv(void *_glfuncs, GLenum pname, GLfloat* params);
+GLenum gl4_0core_glGetError(void *_glfuncs);
+void gl4_0core_glGetDoublev(void *_glfuncs, GLenum pname, GLdouble* params);
+void gl4_0core_glGetBooleanv(void *_glfuncs, GLenum pname, GLboolean* params);
+void gl4_0core_glReadPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum gltype, GLvoid* pixels);
+void gl4_0core_glReadBuffer(void *_glfuncs, GLenum mode);
+void gl4_0core_glPixelStorei(void *_glfuncs, GLenum pname, GLint param);
+void gl4_0core_glPixelStoref(void *_glfuncs, GLenum pname, GLfloat param);
+void gl4_0core_glDepthFunc(void *_glfuncs, GLenum glfunc);
+void gl4_0core_glStencilOp(void *_glfuncs, GLenum fail, GLenum zfail, GLenum zpass);
+void gl4_0core_glStencilFunc(void *_glfuncs, GLenum glfunc, GLint ref, GLuint mask);
+void gl4_0core_glLogicOp(void *_glfuncs, GLenum opcode);
+void gl4_0core_glBlendFunc(void *_glfuncs, GLenum sfactor, GLenum dfactor);
+void gl4_0core_glFlush(void *_glfuncs);
+void gl4_0core_glFinish(void *_glfuncs);
+void gl4_0core_glEnable(void *_glfuncs, GLenum cap);
+void gl4_0core_glDisable(void *_glfuncs, GLenum cap);
+void gl4_0core_glDepthMask(void *_glfuncs, GLboolean flag);
+void gl4_0core_glColorMask(void *_glfuncs, GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha);
+void gl4_0core_glStencilMask(void *_glfuncs, GLuint mask);
+void gl4_0core_glClearDepth(void *_glfuncs, GLdouble depth);
+void gl4_0core_glClearStencil(void *_glfuncs, GLint s);
+void gl4_0core_glClearColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl4_0core_glClear(void *_glfuncs, GLbitfield mask);
+void gl4_0core_glDrawBuffer(void *_glfuncs, GLenum mode);
+void gl4_0core_glTexImage2D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl4_0core_glTexImage1D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl4_0core_glTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl4_0core_glTexParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint param);
+void gl4_0core_glTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl4_0core_glTexParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param);
+void gl4_0core_glScissor(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl4_0core_glPolygonMode(void *_glfuncs, GLenum face, GLenum mode);
+void gl4_0core_glPointSize(void *_glfuncs, GLfloat size);
+void gl4_0core_glLineWidth(void *_glfuncs, GLfloat width);
+void gl4_0core_glHint(void *_glfuncs, GLenum target, GLenum mode);
+void gl4_0core_glFrontFace(void *_glfuncs, GLenum mode);
+void gl4_0core_glCullFace(void *_glfuncs, GLenum mode);
+void gl4_0core_glIndexubv(void *_glfuncs, const GLubyte* c);
+void gl4_0core_glIndexub(void *_glfuncs, GLubyte c);
+GLboolean gl4_0core_glIsTexture(void *_glfuncs, GLuint texture);
+void gl4_0core_glGenTextures(void *_glfuncs, GLsizei n, GLuint* textures);
+void gl4_0core_glDeleteTextures(void *_glfuncs, GLsizei n, const GLuint* textures);
+void gl4_0core_glBindTexture(void *_glfuncs, GLenum target, GLuint texture);
+void gl4_0core_glTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl4_0core_glTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl4_0core_glCopyTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl4_0core_glCopyTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width);
+void gl4_0core_glCopyTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border);
+void gl4_0core_glCopyTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLint border);
+void gl4_0core_glPolygonOffset(void *_glfuncs, GLfloat factor, GLfloat units);
+void gl4_0core_glDrawElements(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices);
+void gl4_0core_glDrawArrays(void *_glfuncs, GLenum mode, GLint first, GLsizei count);
+void gl4_0core_glCopyTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl4_0core_glTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl4_0core_glTexImage3D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl4_0core_glDrawRangeElements(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices);
+void gl4_0core_glBlendEquation(void *_glfuncs, GLenum mode);
+void gl4_0core_glBlendColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl4_0core_glGetCompressedTexImage(void *_glfuncs, GLenum target, GLint level, GLvoid* img);
+void gl4_0core_glCompressedTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid* data);
+void gl4_0core_glCompressedTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid* data);
+void gl4_0core_glCompressedTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid* data);
+void gl4_0core_glCompressedTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid* data);
+void gl4_0core_glCompressedTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid* data);
+void gl4_0core_glCompressedTexImage3D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid* data);
+void gl4_0core_glSampleCoverage(void *_glfuncs, GLfloat value, GLboolean invert);
+void gl4_0core_glActiveTexture(void *_glfuncs, GLenum texture);
+void gl4_0core_glPointParameteriv(void *_glfuncs, GLenum pname, const GLint* params);
+void gl4_0core_glPointParameteri(void *_glfuncs, GLenum pname, GLint param);
+void gl4_0core_glPointParameterfv(void *_glfuncs, GLenum pname, const GLfloat* params);
+void gl4_0core_glPointParameterf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl4_0core_glMultiDrawArrays(void *_glfuncs, GLenum mode, const GLint* first, const GLsizei* count, GLsizei drawcount);
+void gl4_0core_glBlendFuncSeparate(void *_glfuncs, GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha);
+void gl4_0core_glGetBufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+GLboolean gl4_0core_glUnmapBuffer(void *_glfuncs, GLenum target);
+void gl4_0core_glGetBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, GLvoid* data);
+void gl4_0core_glBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid* data);
+void gl4_0core_glBufferData(void *_glfuncs, GLenum target, GLsizeiptr size, const GLvoid* data, GLenum usage);
+GLboolean gl4_0core_glIsBuffer(void *_glfuncs, GLuint buffer);
+void gl4_0core_glGenBuffers(void *_glfuncs, GLsizei n, GLuint* buffers);
+void gl4_0core_glDeleteBuffers(void *_glfuncs, GLsizei n, const GLuint* buffers);
+void gl4_0core_glBindBuffer(void *_glfuncs, GLenum target, GLuint buffer);
+void gl4_0core_glGetQueryObjectuiv(void *_glfuncs, GLuint id, GLenum pname, GLuint* params);
+void gl4_0core_glGetQueryObjectiv(void *_glfuncs, GLuint id, GLenum pname, GLint* params);
+void gl4_0core_glGetQueryiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl4_0core_glEndQuery(void *_glfuncs, GLenum target);
+void gl4_0core_glBeginQuery(void *_glfuncs, GLenum target, GLuint id);
+GLboolean gl4_0core_glIsQuery(void *_glfuncs, GLuint id);
+void gl4_0core_glDeleteQueries(void *_glfuncs, GLsizei n, const GLuint* ids);
+void gl4_0core_glGenQueries(void *_glfuncs, GLsizei n, GLuint* ids);
+void gl4_0core_glVertexAttribPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLboolean normalized, GLsizei stride, const GLvoid* offset);
+void gl4_0core_glValidateProgram(void *_glfuncs, GLuint program);
+void gl4_0core_glUniformMatrix4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_0core_glUniformMatrix3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_0core_glUniformMatrix2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_0core_glUniform4iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl4_0core_glUniform3iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl4_0core_glUniform2iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl4_0core_glUniform1iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl4_0core_glUniform4fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl4_0core_glUniform3fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl4_0core_glUniform2fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl4_0core_glUniform1fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl4_0core_glUniform4i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2, GLint v3);
+void gl4_0core_glUniform3i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2);
+void gl4_0core_glUniform2i(void *_glfuncs, GLint location, GLint v0, GLint v1);
+void gl4_0core_glUniform1i(void *_glfuncs, GLint location, GLint v0);
+void gl4_0core_glUniform4f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3);
+void gl4_0core_glUniform3f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2);
+void gl4_0core_glUniform2f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1);
+void gl4_0core_glUniform1f(void *_glfuncs, GLint location, GLfloat v0);
+void gl4_0core_glUseProgram(void *_glfuncs, GLuint program);
+void gl4_0core_glShaderSource(void *_glfuncs, GLuint shader, GLsizei count, const GLchar** source, const GLint* length);
+void gl4_0core_glLinkProgram(void *_glfuncs, GLuint program);
+GLboolean gl4_0core_glIsShader(void *_glfuncs, GLuint shader);
+GLboolean gl4_0core_glIsProgram(void *_glfuncs, GLuint program);
+void gl4_0core_glGetVertexAttribiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params);
+void gl4_0core_glGetVertexAttribfv(void *_glfuncs, GLuint index, GLenum pname, GLfloat* params);
+void gl4_0core_glGetVertexAttribdv(void *_glfuncs, GLuint index, GLenum pname, GLdouble* params);
+void gl4_0core_glGetUniformiv(void *_glfuncs, GLuint program, GLint location, GLint* params);
+void gl4_0core_glGetUniformfv(void *_glfuncs, GLuint program, GLint location, GLfloat* params);
+GLint gl4_0core_glGetUniformLocation(void *_glfuncs, GLuint program, const GLchar* name);
+void gl4_0core_glGetShaderSource(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* source);
+void gl4_0core_glGetShaderInfoLog(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* infoLog);
+void gl4_0core_glGetShaderiv(void *_glfuncs, GLuint shader, GLenum pname, GLint* params);
+void gl4_0core_glGetProgramInfoLog(void *_glfuncs, GLuint program, GLsizei bufSize, GLsizei* length, GLchar* infoLog);
+void gl4_0core_glGetProgramiv(void *_glfuncs, GLuint program, GLenum pname, GLint* params);
+GLint gl4_0core_glGetAttribLocation(void *_glfuncs, GLuint program, const GLchar* name);
+void gl4_0core_glGetAttachedShaders(void *_glfuncs, GLuint program, GLsizei maxCount, GLsizei* count, GLuint* obj);
+void gl4_0core_glGetActiveUniform(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name);
+void gl4_0core_glGetActiveAttrib(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name);
+void gl4_0core_glEnableVertexAttribArray(void *_glfuncs, GLuint index);
+void gl4_0core_glDisableVertexAttribArray(void *_glfuncs, GLuint index);
+void gl4_0core_glDetachShader(void *_glfuncs, GLuint program, GLuint shader);
+void gl4_0core_glDeleteShader(void *_glfuncs, GLuint shader);
+void gl4_0core_glDeleteProgram(void *_glfuncs, GLuint program);
+GLuint gl4_0core_glCreateShader(void *_glfuncs, GLenum gltype);
+GLuint gl4_0core_glCreateProgram(void *_glfuncs);
+void gl4_0core_glCompileShader(void *_glfuncs, GLuint shader);
+void gl4_0core_glBindAttribLocation(void *_glfuncs, GLuint program, GLuint index, const GLchar* name);
+void gl4_0core_glAttachShader(void *_glfuncs, GLuint program, GLuint shader);
+void gl4_0core_glStencilMaskSeparate(void *_glfuncs, GLenum face, GLuint mask);
+void gl4_0core_glStencilFuncSeparate(void *_glfuncs, GLenum face, GLenum glfunc, GLint ref, GLuint mask);
+void gl4_0core_glStencilOpSeparate(void *_glfuncs, GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass);
+void gl4_0core_glDrawBuffers(void *_glfuncs, GLsizei n, const GLenum* bufs);
+void gl4_0core_glBlendEquationSeparate(void *_glfuncs, GLenum modeRGB, GLenum modeAlpha);
+void gl4_0core_glUniformMatrix4x3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_0core_glUniformMatrix3x4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_0core_glUniformMatrix4x2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_0core_glUniformMatrix2x4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_0core_glUniformMatrix3x2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_0core_glUniformMatrix2x3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+GLboolean gl4_0core_glIsVertexArray(void *_glfuncs, GLuint array);
+void gl4_0core_glGenVertexArrays(void *_glfuncs, GLsizei n, GLuint* arrays);
+void gl4_0core_glDeleteVertexArrays(void *_glfuncs, GLsizei n, const GLuint* arrays);
+void gl4_0core_glBindVertexArray(void *_glfuncs, GLuint array);
+void gl4_0core_glFlushMappedBufferRange(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr length);
+void gl4_0core_glFramebufferTextureLayer(void *_glfuncs, GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer);
+void gl4_0core_glRenderbufferStorageMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLenum internalFormat, GLsizei width, GLsizei height);
+void gl4_0core_glBlitFramebuffer(void *_glfuncs, GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter);
+void gl4_0core_glGenerateMipmap(void *_glfuncs, GLenum target);
+void gl4_0core_glGetFramebufferAttachmentParameteriv(void *_glfuncs, GLenum target, GLenum attachment, GLenum pname, GLint* params);
+void gl4_0core_glFramebufferRenderbuffer(void *_glfuncs, GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer);
+void gl4_0core_glFramebufferTexture3D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset);
+void gl4_0core_glFramebufferTexture2D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+void gl4_0core_glFramebufferTexture1D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+GLenum gl4_0core_glCheckFramebufferStatus(void *_glfuncs, GLenum target);
+void gl4_0core_glGenFramebuffers(void *_glfuncs, GLsizei n, GLuint* framebuffers);
+void gl4_0core_glDeleteFramebuffers(void *_glfuncs, GLsizei n, const GLuint* framebuffers);
+void gl4_0core_glBindFramebuffer(void *_glfuncs, GLenum target, GLuint framebuffer);
+GLboolean gl4_0core_glIsFramebuffer(void *_glfuncs, GLuint framebuffer);
+void gl4_0core_glGetRenderbufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl4_0core_glRenderbufferStorage(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height);
+void gl4_0core_glGenRenderbuffers(void *_glfuncs, GLsizei n, GLuint* renderbuffers);
+void gl4_0core_glDeleteRenderbuffers(void *_glfuncs, GLsizei n, const GLuint* renderbuffers);
+void gl4_0core_glBindRenderbuffer(void *_glfuncs, GLenum target, GLuint renderbuffer);
+GLboolean gl4_0core_glIsRenderbuffer(void *_glfuncs, GLuint renderbuffer);
+void gl4_0core_glClearBufferfi(void *_glfuncs, GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil);
+void gl4_0core_glClearBufferfv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLfloat* value);
+void gl4_0core_glClearBufferuiv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLuint* value);
+void gl4_0core_glClearBufferiv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLint* value);
+void gl4_0core_glGetTexParameterIuiv(void *_glfuncs, GLenum target, GLenum pname, GLuint* params);
+void gl4_0core_glGetTexParameterIiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl4_0core_glTexParameterIuiv(void *_glfuncs, GLenum target, GLenum pname, const GLuint* params);
+void gl4_0core_glTexParameterIiv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl4_0core_glUniform4uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value);
+void gl4_0core_glUniform3uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value);
+void gl4_0core_glUniform2uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value);
+void gl4_0core_glUniform1uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value);
+void gl4_0core_glUniform4ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3);
+void gl4_0core_glUniform3ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1, GLuint v2);
+void gl4_0core_glUniform2ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1);
+void gl4_0core_glUniform1ui(void *_glfuncs, GLint location, GLuint v0);
+GLint gl4_0core_glGetFragDataLocation(void *_glfuncs, GLuint program, const GLchar* name);
+void gl4_0core_glBindFragDataLocation(void *_glfuncs, GLuint program, GLuint color, const GLchar* name);
+void gl4_0core_glGetUniformuiv(void *_glfuncs, GLuint program, GLint location, GLuint* params);
+void gl4_0core_glGetVertexAttribIuiv(void *_glfuncs, GLuint index, GLenum pname, GLuint* params);
+void gl4_0core_glGetVertexAttribIiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params);
+void gl4_0core_glVertexAttribIPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl4_0core_glEndConditionalRender(void *_glfuncs);
+void gl4_0core_glBeginConditionalRender(void *_glfuncs, GLuint id, GLenum mode);
+void gl4_0core_glClampColor(void *_glfuncs, GLenum target, GLenum clamp);
+void gl4_0core_glGetTransformFeedbackVarying(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLsizei* size, GLenum* gltype, GLchar* name);
+void gl4_0core_glBindBufferBase(void *_glfuncs, GLenum target, GLuint index, GLuint buffer);
+void gl4_0core_glBindBufferRange(void *_glfuncs, GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size);
+void gl4_0core_glEndTransformFeedback(void *_glfuncs);
+void gl4_0core_glBeginTransformFeedback(void *_glfuncs, GLenum primitiveMode);
+GLboolean gl4_0core_glIsEnabledi(void *_glfuncs, GLenum target, GLuint index);
+void gl4_0core_glDisablei(void *_glfuncs, GLenum target, GLuint index);
+void gl4_0core_glEnablei(void *_glfuncs, GLenum target, GLuint index);
+void gl4_0core_glGetIntegeri_v(void *_glfuncs, GLenum target, GLuint index, GLint* data);
+void gl4_0core_glGetBooleani_v(void *_glfuncs, GLenum target, GLuint index, GLboolean* data);
+void gl4_0core_glColorMaski(void *_glfuncs, GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a);
+void gl4_0core_glCopyBufferSubData(void *_glfuncs, GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size);
+void gl4_0core_glUniformBlockBinding(void *_glfuncs, GLuint program, GLuint v0, GLuint v1);
+void gl4_0core_glGetActiveUniformBlockName(void *_glfuncs, GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei* length, GLchar* uniformBlockName);
+void gl4_0core_glGetActiveUniformBlockiv(void *_glfuncs, GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint* params);
+GLuint gl4_0core_glGetUniformBlockIndex(void *_glfuncs, GLuint program, const GLchar* uniformBlockName);
+void gl4_0core_glGetActiveUniformName(void *_glfuncs, GLuint program, GLuint uniformIndex, GLsizei bufSize, GLsizei* length, GLchar* uniformName);
+void gl4_0core_glGetActiveUniformsiv(void *_glfuncs, GLuint program, GLsizei uniformCount, const GLuint* uniformIndices, GLenum pname, GLint* params);
+void gl4_0core_glPrimitiveRestartIndex(void *_glfuncs, GLuint index);
+void gl4_0core_glTexBuffer(void *_glfuncs, GLenum target, GLenum internalFormat, GLuint buffer);
+void gl4_0core_glDrawElementsInstanced(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount);
+void gl4_0core_glDrawArraysInstanced(void *_glfuncs, GLenum mode, GLint first, GLsizei count, GLsizei instancecount);
+void gl4_0core_glSampleMaski(void *_glfuncs, GLuint index, GLbitfield mask);
+void gl4_0core_glGetMultisamplefv(void *_glfuncs, GLenum pname, GLuint index, GLfloat* val);
+void gl4_0core_glTexImage3DMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations);
+void gl4_0core_glTexImage2DMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLint internalFormat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations);
+void gl4_0core_glGetSynciv(void *_glfuncs, GLsync sync, GLenum pname, GLsizei bufSize, GLsizei* length, GLint* values);
+void gl4_0core_glGetInteger64v(void *_glfuncs, GLenum pname, GLint64* params);
+void gl4_0core_glWaitSync(void *_glfuncs, GLsync sync, GLbitfield flags, GLuint64 timeout);
+GLenum gl4_0core_glClientWaitSync(void *_glfuncs, GLsync sync, GLbitfield flags, GLuint64 timeout);
+void gl4_0core_glDeleteSync(void *_glfuncs, GLsync sync);
+GLboolean gl4_0core_glIsSync(void *_glfuncs, GLsync sync);
+GLsync gl4_0core_glFenceSync(void *_glfuncs, GLenum condition, GLbitfield flags);
+void gl4_0core_glProvokingVertex(void *_glfuncs, GLenum mode);
+void gl4_0core_glDrawElementsInstancedBaseVertex(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount, GLint basevertex);
+void gl4_0core_glDrawRangeElementsBaseVertex(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices, GLint basevertex);
+void gl4_0core_glDrawElementsBaseVertex(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLint basevertex);
+void gl4_0core_glFramebufferTexture(void *_glfuncs, GLenum target, GLenum attachment, GLuint texture, GLint level);
+void gl4_0core_glGetBufferParameteri64v(void *_glfuncs, GLenum target, GLenum pname, GLint64* params);
+void gl4_0core_glGetInteger64i_v(void *_glfuncs, GLenum target, GLuint index, GLint64* data);
+void gl4_0core_glVertexAttribP4uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value);
+void gl4_0core_glVertexAttribP4ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value);
+void gl4_0core_glVertexAttribP3uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value);
+void gl4_0core_glVertexAttribP3ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value);
+void gl4_0core_glVertexAttribP2uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value);
+void gl4_0core_glVertexAttribP2ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value);
+void gl4_0core_glVertexAttribP1uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value);
+void gl4_0core_glVertexAttribP1ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value);
+void gl4_0core_glSecondaryColorP3uiv(void *_glfuncs, GLenum gltype, const GLuint* color);
+void gl4_0core_glSecondaryColorP3ui(void *_glfuncs, GLenum gltype, GLuint color);
+void gl4_0core_glColorP4uiv(void *_glfuncs, GLenum gltype, const GLuint* color);
+void gl4_0core_glColorP4ui(void *_glfuncs, GLenum gltype, GLuint color);
+void gl4_0core_glColorP3uiv(void *_glfuncs, GLenum gltype, const GLuint* color);
+void gl4_0core_glColorP3ui(void *_glfuncs, GLenum gltype, GLuint color);
+void gl4_0core_glNormalP3uiv(void *_glfuncs, GLenum gltype, const GLuint* coords);
+void gl4_0core_glNormalP3ui(void *_glfuncs, GLenum gltype, GLuint coords);
+void gl4_0core_glMultiTexCoordP4uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords);
+void gl4_0core_glMultiTexCoordP4ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords);
+void gl4_0core_glMultiTexCoordP3uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords);
+void gl4_0core_glMultiTexCoordP3ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords);
+void gl4_0core_glMultiTexCoordP2uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords);
+void gl4_0core_glMultiTexCoordP2ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords);
+void gl4_0core_glMultiTexCoordP1uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords);
+void gl4_0core_glMultiTexCoordP1ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords);
+void gl4_0core_glTexCoordP4uiv(void *_glfuncs, GLenum gltype, const GLuint* coords);
+void gl4_0core_glTexCoordP4ui(void *_glfuncs, GLenum gltype, GLuint coords);
+void gl4_0core_glTexCoordP3uiv(void *_glfuncs, GLenum gltype, const GLuint* coords);
+void gl4_0core_glTexCoordP3ui(void *_glfuncs, GLenum gltype, GLuint coords);
+void gl4_0core_glTexCoordP2uiv(void *_glfuncs, GLenum gltype, const GLuint* coords);
+void gl4_0core_glTexCoordP2ui(void *_glfuncs, GLenum gltype, GLuint coords);
+void gl4_0core_glTexCoordP1uiv(void *_glfuncs, GLenum gltype, const GLuint* coords);
+void gl4_0core_glTexCoordP1ui(void *_glfuncs, GLenum gltype, GLuint coords);
+void gl4_0core_glVertexP4uiv(void *_glfuncs, GLenum gltype, const GLuint* value);
+void gl4_0core_glVertexP4ui(void *_glfuncs, GLenum gltype, GLuint value);
+void gl4_0core_glVertexP3uiv(void *_glfuncs, GLenum gltype, const GLuint* value);
+void gl4_0core_glVertexP3ui(void *_glfuncs, GLenum gltype, GLuint value);
+void gl4_0core_glVertexP2uiv(void *_glfuncs, GLenum gltype, const GLuint* value);
+void gl4_0core_glVertexP2ui(void *_glfuncs, GLenum gltype, GLuint value);
+void gl4_0core_glGetQueryObjectui64v(void *_glfuncs, GLuint id, GLenum pname, GLuint64* params);
+void gl4_0core_glGetQueryObjecti64v(void *_glfuncs, GLuint id, GLenum pname, GLint64* params);
+void gl4_0core_glQueryCounter(void *_glfuncs, GLuint id, GLenum target);
+void gl4_0core_glGetSamplerParameterIuiv(void *_glfuncs, GLuint sampler, GLenum pname, GLuint* params);
+void gl4_0core_glGetSamplerParameterfv(void *_glfuncs, GLuint sampler, GLenum pname, GLfloat* params);
+void gl4_0core_glGetSamplerParameterIiv(void *_glfuncs, GLuint sampler, GLenum pname, GLint* params);
+void gl4_0core_glGetSamplerParameteriv(void *_glfuncs, GLuint sampler, GLenum pname, GLint* params);
+void gl4_0core_glSamplerParameterIuiv(void *_glfuncs, GLuint sampler, GLenum pname, const GLuint* param);
+void gl4_0core_glSamplerParameterIiv(void *_glfuncs, GLuint sampler, GLenum pname, const GLint* param);
+void gl4_0core_glSamplerParameterfv(void *_glfuncs, GLuint sampler, GLenum pname, const GLfloat* param);
+void gl4_0core_glSamplerParameterf(void *_glfuncs, GLuint sampler, GLenum pname, GLfloat param);
+void gl4_0core_glSamplerParameteriv(void *_glfuncs, GLuint sampler, GLenum pname, const GLint* param);
+void gl4_0core_glSamplerParameteri(void *_glfuncs, GLuint sampler, GLenum pname, GLint param);
+void gl4_0core_glBindSampler(void *_glfuncs, GLuint unit, GLuint sampler);
+GLboolean gl4_0core_glIsSampler(void *_glfuncs, GLuint sampler);
+void gl4_0core_glDeleteSamplers(void *_glfuncs, GLsizei count, const GLuint* samplers);
+void gl4_0core_glGenSamplers(void *_glfuncs, GLsizei count, GLuint* samplers);
+GLint gl4_0core_glGetFragDataIndex(void *_glfuncs, GLuint program, const GLchar* name);
+void gl4_0core_glBindFragDataLocationIndexed(void *_glfuncs, GLuint program, GLuint colorNumber, GLuint index, const GLchar* name);
+void gl4_0core_glVertexAttribDivisor(void *_glfuncs, GLuint index, GLuint divisor);
+void gl4_0core_glGetQueryIndexediv(void *_glfuncs, GLenum target, GLuint index, GLenum pname, GLint* params);
+void gl4_0core_glEndQueryIndexed(void *_glfuncs, GLenum target, GLuint index);
+void gl4_0core_glBeginQueryIndexed(void *_glfuncs, GLenum target, GLuint index, GLuint id);
+void gl4_0core_glDrawTransformFeedbackStream(void *_glfuncs, GLenum mode, GLuint id, GLuint stream);
+void gl4_0core_glDrawTransformFeedback(void *_glfuncs, GLenum mode, GLuint id);
+void gl4_0core_glResumeTransformFeedback(void *_glfuncs);
+void gl4_0core_glPauseTransformFeedback(void *_glfuncs);
+GLboolean gl4_0core_glIsTransformFeedback(void *_glfuncs, GLuint id);
+void gl4_0core_glGenTransformFeedbacks(void *_glfuncs, GLsizei n, GLuint* ids);
+void gl4_0core_glDeleteTransformFeedbacks(void *_glfuncs, GLsizei n, const GLuint* ids);
+void gl4_0core_glBindTransformFeedback(void *_glfuncs, GLenum target, GLuint id);
+void gl4_0core_glPatchParameterfv(void *_glfuncs, GLenum pname, const GLfloat* values);
+void gl4_0core_glPatchParameteri(void *_glfuncs, GLenum pname, GLint value);
+void gl4_0core_glGetProgramStageiv(void *_glfuncs, GLuint program, GLenum shadertype, GLenum pname, GLint* values);
+void gl4_0core_glGetUniformSubroutineuiv(void *_glfuncs, GLenum shadertype, GLint location, GLuint* params);
+void gl4_0core_glUniformSubroutinesuiv(void *_glfuncs, GLenum shadertype, GLsizei count, const GLuint* value);
+void gl4_0core_glGetActiveSubroutineName(void *_glfuncs, GLuint program, GLenum shadertype, GLuint index, GLsizei bufSize, GLsizei* length, GLchar* name);
+void gl4_0core_glGetActiveSubroutineUniformName(void *_glfuncs, GLuint program, GLenum shadertype, GLuint index, GLsizei bufSize, GLsizei* length, GLchar* name);
+void gl4_0core_glGetActiveSubroutineUniformiv(void *_glfuncs, GLuint program, GLenum shadertype, GLuint index, GLenum pname, GLint* values);
+GLuint gl4_0core_glGetSubroutineIndex(void *_glfuncs, GLuint program, GLenum shadertype, const GLchar* name);
+GLint gl4_0core_glGetSubroutineUniformLocation(void *_glfuncs, GLuint program, GLenum shadertype, const GLchar* name);
+void gl4_0core_glGetUniformdv(void *_glfuncs, GLuint program, GLint location, GLdouble* params);
+void gl4_0core_glUniformMatrix4x3dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_0core_glUniformMatrix4x2dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_0core_glUniformMatrix3x4dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_0core_glUniformMatrix3x2dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_0core_glUniformMatrix2x4dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_0core_glUniformMatrix2x3dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_0core_glUniformMatrix4dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_0core_glUniformMatrix3dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_0core_glUniformMatrix2dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_0core_glUniform4dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value);
+void gl4_0core_glUniform3dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value);
+void gl4_0core_glUniform2dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value);
+void gl4_0core_glUniform1dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value);
+void gl4_0core_glUniform4d(void *_glfuncs, GLint location, GLdouble v0, GLdouble v1, GLdouble v2, GLdouble v3);
+void gl4_0core_glUniform3d(void *_glfuncs, GLint location, GLdouble v0, GLdouble v1, GLdouble v2);
+void gl4_0core_glUniform2d(void *_glfuncs, GLint location, GLdouble v0, GLdouble v1);
+void gl4_0core_glUniform1d(void *_glfuncs, GLint location, GLdouble v0);
+void gl4_0core_glDrawElementsIndirect(void *_glfuncs, GLenum mode, GLenum gltype, const GLvoid* indirect);
+void gl4_0core_glDrawArraysIndirect(void *_glfuncs, GLenum mode, const GLvoid* indirect);
+void gl4_0core_glBlendFuncSeparatei(void *_glfuncs, GLuint buf, GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha, GLenum dstAlpha);
+void gl4_0core_glBlendFunci(void *_glfuncs, GLuint buf, GLenum src, GLenum dst);
+void gl4_0core_glBlendEquationSeparatei(void *_glfuncs, GLuint buf, GLenum modeRGB, GLenum modeAlpha);
+void gl4_0core_glBlendEquationi(void *_glfuncs, GLuint buf, GLenum mode);
+void gl4_0core_glMinSampleShading(void *_glfuncs, GLfloat value);
+
+
+#ifdef __cplusplus
+} // extern "C"
+#endif
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.0core/gl.go b/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.0core/gl.go
new file mode 100644
index 000000000..ddfef9318
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.0core/gl.go
@@ -0,0 +1,5815 @@
+// ** file automatically generated by glgen -- do not edit manually **
+
+package GL
+
+// #cgo CXXFLAGS: -std=c++0x -pedantic-errors -Wall -fno-strict-aliasing
+// #cgo LDFLAGS: -lstdc++
+// #cgo pkg-config: Qt5Core Qt5OpenGL
+//
+// #include "funcs.h"
+//
+// void free(void*);
+//
+import "C"
+
+import (
+ "fmt"
+ "reflect"
+ "unsafe"
+
+ "gopkg.in/qml.v1/gl/glbase"
+)
+
+// API returns a value that offers methods matching the OpenGL version 4.0 API.
+//
+// The returned API must not be used after the provided OpenGL context becomes invalid.
+func API(context glbase.Contexter) *GL {
+ gl := &GL{}
+ gl.funcs = C.gl4_0core_funcs()
+ if gl.funcs == nil {
+ panic(fmt.Errorf("OpenGL version 4.0 is not available"))
+ }
+ return gl
+}
+
+// GL implements the OpenGL version 4.0 API. Values of this
+// type must be created via the API function, and it must not be used after
+// the associated OpenGL context becomes invalid.
+type GL struct {
+ funcs unsafe.Pointer
+}
+
+const (
+ FALSE = 0
+ TRUE = 1
+ NONE = 0
+
+ BYTE = 0x1400
+ UNSIGNED_BYTE = 0x1401
+ SHORT = 0x1402
+ UNSIGNED_SHORT = 0x1403
+ INT = 0x1404
+ UNSIGNED_INT = 0x1405
+ FLOAT = 0x1406
+ N2_BYTES = 0x1407
+ N3_BYTES = 0x1408
+ N4_BYTES = 0x1409
+ DOUBLE = 0x140A
+ HALF_FLOAT = 0x140B
+
+ ACCUM = 0x0100
+ LOAD = 0x0101
+ RETURN = 0x0102
+ MULT = 0x0103
+ ADD = 0x0104
+
+ ACCUM_BUFFER_BIT = 0x00000200
+ ALL_ATTRIB_BITS = 0xFFFFFFFF
+ COLOR_BUFFER_BIT = 0x00004000
+ CURRENT_BIT = 0x00000001
+ DEPTH_BUFFER_BIT = 0x00000100
+ ENABLE_BIT = 0x00002000
+ EVAL_BIT = 0x00010000
+ FOG_BIT = 0x00000080
+ HINT_BIT = 0x00008000
+ LIGHTING_BIT = 0x00000040
+ LINE_BIT = 0x00000004
+ LIST_BIT = 0x00020000
+ MULTISAMPLE_BIT = 0x20000000
+ PIXEL_MODE_BIT = 0x00000020
+ POINT_BIT = 0x00000002
+ POLYGON_BIT = 0x00000008
+ POLYGON_STIPPLE_BIT = 0x00000010
+ SCISSOR_BIT = 0x00080000
+ STENCIL_BUFFER_BIT = 0x00000400
+ TEXTURE_BIT = 0x00040000
+ TRANSFORM_BIT = 0x00001000
+ VIEWPORT_BIT = 0x00000800
+
+ ALWAYS = 0x0207
+ EQUAL = 0x0202
+ GEQUAL = 0x0206
+ GREATER = 0x0204
+ LEQUAL = 0x0203
+ LESS = 0x0201
+ NEVER = 0x0200
+ NOTEQUAL = 0x0205
+
+ LOGIC_OP = 0x0BF1
+
+ DST_ALPHA = 0x0304
+ ONE = 1
+ ONE_MINUS_DST_ALPHA = 0x0305
+ ONE_MINUS_SRC_ALPHA = 0x0303
+ ONE_MINUS_SRC_COLOR = 0x0301
+ SRC_ALPHA = 0x0302
+ SRC_COLOR = 0x0300
+ ZERO = 0
+
+ DST_COLOR = 0x0306
+ ONE_MINUS_DST_COLOR = 0x0307
+ SRC_ALPHA_SATURATE = 0x0308
+
+ CLIENT_ALL_ATTRIB_BITS = 0xFFFFFFFF
+ CLIENT_PIXEL_STORE_BIT = 0x00000001
+ CLIENT_VERTEX_ARRAY_BIT = 0x00000002
+
+ CLIP_DISTANCE0 = 0x3000
+ CLIP_DISTANCE1 = 0x3001
+ CLIP_DISTANCE2 = 0x3002
+ CLIP_DISTANCE3 = 0x3003
+ CLIP_DISTANCE4 = 0x3004
+ CLIP_DISTANCE5 = 0x3005
+ CLIP_DISTANCE6 = 0x3006
+ CLIP_DISTANCE7 = 0x3007
+ CLIP_PLANE0 = 0x3000
+ CLIP_PLANE1 = 0x3001
+ CLIP_PLANE2 = 0x3002
+ CLIP_PLANE3 = 0x3003
+ CLIP_PLANE4 = 0x3004
+ CLIP_PLANE5 = 0x3005
+
+ BACK = 0x0405
+ FRONT = 0x0404
+ FRONT_AND_BACK = 0x0408
+
+ AMBIENT = 0x1200
+ AMBIENT_AND_DIFFUSE = 0x1602
+ DIFFUSE = 0x1201
+ EMISSION = 0x1600
+ SPECULAR = 0x1202
+
+ CONTEXT_FLAG_FORWARD_COMPATIBLE_BIT = 0x00000001
+
+ CONTEXT_COMPATIBILITY_PROFILE_BIT = 0x00000002
+ CONTEXT_CORE_PROFILE_BIT = 0x00000001
+
+ AUX0 = 0x0409
+ AUX1 = 0x040A
+ AUX2 = 0x040B
+ AUX3 = 0x040C
+ BACK_LEFT = 0x0402
+ BACK_RIGHT = 0x0403
+ FRONT_LEFT = 0x0400
+ FRONT_RIGHT = 0x0401
+ LEFT = 0x0406
+ RIGHT = 0x0407
+
+ ALPHA_TEST = 0x0BC0
+ AUTO_NORMAL = 0x0D80
+ BLEND = 0x0BE2
+ COLOR_ARRAY = 0x8076
+ COLOR_LOGIC_OP = 0x0BF2
+ COLOR_MATERIAL = 0x0B57
+ CULL_FACE = 0x0B44
+ DEPTH_TEST = 0x0B71
+ DITHER = 0x0BD0
+ EDGE_FLAG_ARRAY = 0x8079
+ FOG = 0x0B60
+ INDEX_ARRAY = 0x8077
+ INDEX_LOGIC_OP = 0x0BF1
+ LIGHT0 = 0x4000
+ LIGHT1 = 0x4001
+ LIGHT2 = 0x4002
+ LIGHT3 = 0x4003
+ LIGHT4 = 0x4004
+ LIGHT5 = 0x4005
+ LIGHT6 = 0x4006
+ LIGHT7 = 0x4007
+ LIGHTING = 0x0B50
+ LINE_SMOOTH = 0x0B20
+ LINE_STIPPLE = 0x0B24
+ MAP1_COLOR_4 = 0x0D90
+ MAP1_INDEX = 0x0D91
+ MAP1_NORMAL = 0x0D92
+ MAP1_TEXTURE_COORD_1 = 0x0D93
+ MAP1_TEXTURE_COORD_2 = 0x0D94
+ MAP1_TEXTURE_COORD_3 = 0x0D95
+ MAP1_TEXTURE_COORD_4 = 0x0D96
+ MAP1_VERTEX_3 = 0x0D97
+ MAP1_VERTEX_4 = 0x0D98
+ MAP2_COLOR_4 = 0x0DB0
+ MAP2_INDEX = 0x0DB1
+ MAP2_NORMAL = 0x0DB2
+ MAP2_TEXTURE_COORD_1 = 0x0DB3
+ MAP2_TEXTURE_COORD_2 = 0x0DB4
+ MAP2_TEXTURE_COORD_3 = 0x0DB5
+ MAP2_TEXTURE_COORD_4 = 0x0DB6
+ MAP2_VERTEX_3 = 0x0DB7
+ MAP2_VERTEX_4 = 0x0DB8
+ NORMALIZE = 0x0BA1
+ NORMAL_ARRAY = 0x8075
+ POINT_SMOOTH = 0x0B10
+ POLYGON_OFFSET_FILL = 0x8037
+ POLYGON_OFFSET_LINE = 0x2A02
+ POLYGON_OFFSET_POINT = 0x2A01
+ POLYGON_SMOOTH = 0x0B41
+ POLYGON_STIPPLE = 0x0B42
+ SCISSOR_TEST = 0x0C11
+ STENCIL_TEST = 0x0B90
+ TEXTURE_1D = 0x0DE0
+ TEXTURE_2D = 0x0DE1
+ TEXTURE_COORD_ARRAY = 0x8078
+ TEXTURE_GEN_Q = 0x0C63
+ TEXTURE_GEN_R = 0x0C62
+ TEXTURE_GEN_S = 0x0C60
+ TEXTURE_GEN_T = 0x0C61
+ VERTEX_ARRAY = 0x8074
+
+ INVALID_ENUM = 0x0500
+ INVALID_FRAMEBUFFER_OPERATION = 0x0506
+ INVALID_OPERATION = 0x0502
+ INVALID_VALUE = 0x0501
+ NO_ERROR = 0
+ OUT_OF_MEMORY = 0x0505
+ STACK_OVERFLOW = 0x0503
+ STACK_UNDERFLOW = 0x0504
+
+ N2D = 0x0600
+ N3D = 0x0601
+ N3D_COLOR = 0x0602
+ N3D_COLOR_TEXTURE = 0x0603
+ N4D_COLOR_TEXTURE = 0x0604
+
+ BITMAP_TOKEN = 0x0704
+ COPY_PIXEL_TOKEN = 0x0706
+ DRAW_PIXEL_TOKEN = 0x0705
+ LINE_RESET_TOKEN = 0x0707
+ LINE_TOKEN = 0x0702
+ PASS_THROUGH_TOKEN = 0x0700
+ POINT_TOKEN = 0x0701
+ POLYGON_TOKEN = 0x0703
+
+ EXP = 0x0800
+ EXP2 = 0x0801
+ LINEAR = 0x2601
+
+ FOG_COLOR = 0x0B66
+ FOG_DENSITY = 0x0B62
+ FOG_END = 0x0B64
+ FOG_INDEX = 0x0B61
+ FOG_MODE = 0x0B65
+ FOG_START = 0x0B63
+
+ CCW = 0x0901
+ CW = 0x0900
+
+ COEFF = 0x0A00
+ DOMAIN = 0x0A02
+ ORDER = 0x0A01
+
+ PIXEL_MAP_A_TO_A = 0x0C79
+ PIXEL_MAP_B_TO_B = 0x0C78
+ PIXEL_MAP_G_TO_G = 0x0C77
+ PIXEL_MAP_I_TO_A = 0x0C75
+ PIXEL_MAP_I_TO_B = 0x0C74
+ PIXEL_MAP_I_TO_G = 0x0C73
+ PIXEL_MAP_I_TO_I = 0x0C70
+ PIXEL_MAP_I_TO_R = 0x0C72
+ PIXEL_MAP_R_TO_R = 0x0C76
+ PIXEL_MAP_S_TO_S = 0x0C71
+
+ ACCUM_ALPHA_BITS = 0x0D5B
+ ACCUM_BLUE_BITS = 0x0D5A
+ ACCUM_CLEAR_VALUE = 0x0B80
+ ACCUM_GREEN_BITS = 0x0D59
+ ACCUM_RED_BITS = 0x0D58
+ ALIASED_LINE_WIDTH_RANGE = 0x846E
+ ALIASED_POINT_SIZE_RANGE = 0x846D
+ ALPHA_BIAS = 0x0D1D
+ ALPHA_BITS = 0x0D55
+ ALPHA_SCALE = 0x0D1C
+ ALPHA_TEST_FUNC = 0x0BC1
+ ALPHA_TEST_REF = 0x0BC2
+ ATTRIB_STACK_DEPTH = 0x0BB0
+ AUX_BUFFERS = 0x0C00
+ BLEND_DST = 0x0BE0
+ BLEND_SRC = 0x0BE1
+ BLUE_BIAS = 0x0D1B
+ BLUE_BITS = 0x0D54
+ BLUE_SCALE = 0x0D1A
+ CLIENT_ATTRIB_STACK_DEPTH = 0x0BB1
+ COLOR_ARRAY_SIZE = 0x8081
+ COLOR_ARRAY_STRIDE = 0x8083
+ COLOR_ARRAY_TYPE = 0x8082
+ COLOR_CLEAR_VALUE = 0x0C22
+ COLOR_MATERIAL_FACE = 0x0B55
+ COLOR_MATERIAL_PARAMETER = 0x0B56
+ COLOR_WRITEMASK = 0x0C23
+ CULL_FACE_MODE = 0x0B45
+ CURRENT_COLOR = 0x0B00
+ CURRENT_INDEX = 0x0B01
+ CURRENT_NORMAL = 0x0B02
+ CURRENT_RASTER_COLOR = 0x0B04
+ CURRENT_RASTER_DISTANCE = 0x0B09
+ CURRENT_RASTER_INDEX = 0x0B05
+ CURRENT_RASTER_POSITION = 0x0B07
+ CURRENT_RASTER_POSITION_VALID = 0x0B08
+ CURRENT_RASTER_TEXTURE_COORDS = 0x0B06
+ CURRENT_TEXTURE_COORDS = 0x0B03
+ DEPTH_BIAS = 0x0D1F
+ DEPTH_BITS = 0x0D56
+ DEPTH_CLEAR_VALUE = 0x0B73
+ DEPTH_FUNC = 0x0B74
+ DEPTH_RANGE = 0x0B70
+ DEPTH_SCALE = 0x0D1E
+ DEPTH_WRITEMASK = 0x0B72
+ DOUBLEBUFFER = 0x0C32
+ DRAW_BUFFER = 0x0C01
+ EDGE_FLAG = 0x0B43
+ EDGE_FLAG_ARRAY_STRIDE = 0x808C
+ FEEDBACK_BUFFER_SIZE = 0x0DF1
+ FEEDBACK_BUFFER_TYPE = 0x0DF2
+ FOG_HINT = 0x0C54
+ FRONT_FACE = 0x0B46
+ GREEN_BIAS = 0x0D19
+ GREEN_BITS = 0x0D53
+ GREEN_SCALE = 0x0D18
+ INDEX_ARRAY_STRIDE = 0x8086
+ INDEX_ARRAY_TYPE = 0x8085
+ INDEX_BITS = 0x0D51
+ INDEX_CLEAR_VALUE = 0x0C20
+ INDEX_MODE = 0x0C30
+ INDEX_OFFSET = 0x0D13
+ INDEX_SHIFT = 0x0D12
+ INDEX_WRITEMASK = 0x0C21
+ LIGHT_MODEL_AMBIENT = 0x0B53
+ LIGHT_MODEL_COLOR_CONTROL = 0x81F8
+ LIGHT_MODEL_LOCAL_VIEWER = 0x0B51
+ LIGHT_MODEL_TWO_SIDE = 0x0B52
+ LINE_SMOOTH_HINT = 0x0C52
+ LINE_STIPPLE_PATTERN = 0x0B25
+ LINE_STIPPLE_REPEAT = 0x0B26
+ LINE_WIDTH = 0x0B21
+ LINE_WIDTH_GRANULARITY = 0x0B23
+ LINE_WIDTH_RANGE = 0x0B22
+ LIST_BASE = 0x0B32
+ LIST_INDEX = 0x0B33
+ LIST_MODE = 0x0B30
+ LOGIC_OP_MODE = 0x0BF0
+ MAP1_GRID_DOMAIN = 0x0DD0
+ MAP1_GRID_SEGMENTS = 0x0DD1
+ MAP2_GRID_DOMAIN = 0x0DD2
+ MAP2_GRID_SEGMENTS = 0x0DD3
+ MAP_COLOR = 0x0D10
+ MAP_STENCIL = 0x0D11
+ MATRIX_MODE = 0x0BA0
+ MAX_ATTRIB_STACK_DEPTH = 0x0D35
+ MAX_CLIENT_ATTRIB_STACK_DEPTH = 0x0D3B
+ MAX_CLIP_DISTANCES = 0x0D32
+ MAX_CLIP_PLANES = 0x0D32
+ MAX_EVAL_ORDER = 0x0D30
+ MAX_LIGHTS = 0x0D31
+ MAX_LIST_NESTING = 0x0B31
+ MAX_MODELVIEW_STACK_DEPTH = 0x0D36
+ MAX_NAME_STACK_DEPTH = 0x0D37
+ MAX_PIXEL_MAP_TABLE = 0x0D34
+ MAX_PROJECTION_STACK_DEPTH = 0x0D38
+ MAX_TEXTURE_SIZE = 0x0D33
+ MAX_TEXTURE_STACK_DEPTH = 0x0D39
+ MAX_VIEWPORT_DIMS = 0x0D3A
+ MODELVIEW_MATRIX = 0x0BA6
+ MODELVIEW_STACK_DEPTH = 0x0BA3
+ NAME_STACK_DEPTH = 0x0D70
+ NORMAL_ARRAY_STRIDE = 0x807F
+ NORMAL_ARRAY_TYPE = 0x807E
+ PACK_ALIGNMENT = 0x0D05
+ PACK_LSB_FIRST = 0x0D01
+ PACK_ROW_LENGTH = 0x0D02
+ PACK_SKIP_PIXELS = 0x0D04
+ PACK_SKIP_ROWS = 0x0D03
+ PACK_SWAP_BYTES = 0x0D00
+ PERSPECTIVE_CORRECTION_HINT = 0x0C50
+ PIXEL_MAP_A_TO_A_SIZE = 0x0CB9
+ PIXEL_MAP_B_TO_B_SIZE = 0x0CB8
+ PIXEL_MAP_G_TO_G_SIZE = 0x0CB7
+ PIXEL_MAP_I_TO_A_SIZE = 0x0CB5
+ PIXEL_MAP_I_TO_B_SIZE = 0x0CB4
+ PIXEL_MAP_I_TO_G_SIZE = 0x0CB3
+ PIXEL_MAP_I_TO_I_SIZE = 0x0CB0
+ PIXEL_MAP_I_TO_R_SIZE = 0x0CB2
+ PIXEL_MAP_R_TO_R_SIZE = 0x0CB6
+ PIXEL_MAP_S_TO_S_SIZE = 0x0CB1
+ POINT_SIZE = 0x0B11
+ POINT_SIZE_GRANULARITY = 0x0B13
+ POINT_SIZE_RANGE = 0x0B12
+ POINT_SMOOTH_HINT = 0x0C51
+ POLYGON_MODE = 0x0B40
+ POLYGON_OFFSET_FACTOR = 0x8038
+ POLYGON_OFFSET_UNITS = 0x2A00
+ POLYGON_SMOOTH_HINT = 0x0C53
+ PROJECTION_MATRIX = 0x0BA7
+ PROJECTION_STACK_DEPTH = 0x0BA4
+ READ_BUFFER = 0x0C02
+ RED_BIAS = 0x0D15
+ RED_BITS = 0x0D52
+ RED_SCALE = 0x0D14
+ RENDER_MODE = 0x0C40
+ RGBA_MODE = 0x0C31
+ SCISSOR_BOX = 0x0C10
+ SELECTION_BUFFER_SIZE = 0x0DF4
+ SHADE_MODEL = 0x0B54
+ SMOOTH_LINE_WIDTH_GRANULARITY = 0x0B23
+ SMOOTH_LINE_WIDTH_RANGE = 0x0B22
+ SMOOTH_POINT_SIZE_GRANULARITY = 0x0B13
+ SMOOTH_POINT_SIZE_RANGE = 0x0B12
+ STENCIL_BITS = 0x0D57
+ STENCIL_CLEAR_VALUE = 0x0B91
+ STENCIL_FAIL = 0x0B94
+ STENCIL_FUNC = 0x0B92
+ STENCIL_PASS_DEPTH_FAIL = 0x0B95
+ STENCIL_PASS_DEPTH_PASS = 0x0B96
+ STENCIL_REF = 0x0B97
+ STENCIL_VALUE_MASK = 0x0B93
+ STENCIL_WRITEMASK = 0x0B98
+ STEREO = 0x0C33
+ SUBPIXEL_BITS = 0x0D50
+ TEXTURE_BINDING_1D = 0x8068
+ TEXTURE_BINDING_2D = 0x8069
+ TEXTURE_BINDING_3D = 0x806A
+ TEXTURE_COORD_ARRAY_SIZE = 0x8088
+ TEXTURE_COORD_ARRAY_STRIDE = 0x808A
+ TEXTURE_COORD_ARRAY_TYPE = 0x8089
+ TEXTURE_MATRIX = 0x0BA8
+ TEXTURE_STACK_DEPTH = 0x0BA5
+ UNPACK_ALIGNMENT = 0x0CF5
+ UNPACK_LSB_FIRST = 0x0CF1
+ UNPACK_ROW_LENGTH = 0x0CF2
+ UNPACK_SKIP_PIXELS = 0x0CF4
+ UNPACK_SKIP_ROWS = 0x0CF3
+ UNPACK_SWAP_BYTES = 0x0CF0
+ VERTEX_ARRAY_SIZE = 0x807A
+ VERTEX_ARRAY_STRIDE = 0x807C
+ VERTEX_ARRAY_TYPE = 0x807B
+ VIEWPORT = 0x0BA2
+ ZOOM_X = 0x0D16
+ ZOOM_Y = 0x0D17
+
+ COLOR_ARRAY_POINTER = 0x8090
+ EDGE_FLAG_ARRAY_POINTER = 0x8093
+ FEEDBACK_BUFFER_POINTER = 0x0DF0
+ INDEX_ARRAY_POINTER = 0x8091
+ NORMAL_ARRAY_POINTER = 0x808F
+ SELECTION_BUFFER_POINTER = 0x0DF3
+ TEXTURE_COORD_ARRAY_POINTER = 0x8092
+ VERTEX_ARRAY_POINTER = 0x808E
+
+ TEXTURE_ALPHA_SIZE = 0x805F
+ TEXTURE_BLUE_SIZE = 0x805E
+ TEXTURE_BORDER = 0x1005
+ TEXTURE_BORDER_COLOR = 0x1004
+ TEXTURE_COMPONENTS = 0x1003
+ TEXTURE_GREEN_SIZE = 0x805D
+ TEXTURE_HEIGHT = 0x1001
+ TEXTURE_INTENSITY_SIZE = 0x8061
+ TEXTURE_INTERNAL_FORMAT = 0x1003
+ TEXTURE_LUMINANCE_SIZE = 0x8060
+ TEXTURE_MAG_FILTER = 0x2800
+ TEXTURE_MIN_FILTER = 0x2801
+ TEXTURE_PRIORITY = 0x8066
+ TEXTURE_RED_SIZE = 0x805C
+ TEXTURE_RESIDENT = 0x8067
+ TEXTURE_WIDTH = 0x1000
+ TEXTURE_WRAP_S = 0x2802
+ TEXTURE_WRAP_T = 0x2803
+
+ DONT_CARE = 0x1100
+ FASTEST = 0x1101
+ NICEST = 0x1102
+
+ FRAGMENT_SHADER_DERIVATIVE_HINT = 0x8B8B
+ GENERATE_MIPMAP_HINT = 0x8192
+ TEXTURE_COMPRESSION_HINT = 0x84EF
+
+ C3F_V3F = 0x2A24
+ C4F_N3F_V3F = 0x2A26
+ C4UB_V2F = 0x2A22
+ C4UB_V3F = 0x2A23
+ N3F_V3F = 0x2A25
+ T2F_C3F_V3F = 0x2A2A
+ T2F_C4F_N3F_V3F = 0x2A2C
+ T2F_C4UB_V3F = 0x2A29
+ T2F_N3F_V3F = 0x2A2B
+ T2F_V3F = 0x2A27
+ T4F_C4F_N3F_V4F = 0x2A2D
+ T4F_V4F = 0x2A28
+ V2F = 0x2A20
+ V3F = 0x2A21
+
+ MODULATE = 0x2100
+ REPLACE = 0x1E01
+
+ SEPARATE_SPECULAR_COLOR = 0x81FA
+ SINGLE_COLOR = 0x81F9
+
+ CONSTANT_ATTENUATION = 0x1207
+ LINEAR_ATTENUATION = 0x1208
+ POSITION = 0x1203
+ QUADRATIC_ATTENUATION = 0x1209
+ SPOT_CUTOFF = 0x1206
+ SPOT_DIRECTION = 0x1204
+ SPOT_EXPONENT = 0x1205
+
+ COMPILE = 0x1300
+ COMPILE_AND_EXECUTE = 0x1301
+
+ AND = 0x1501
+ AND_INVERTED = 0x1504
+ AND_REVERSE = 0x1502
+ CLEAR = 0x1500
+ COPY = 0x1503
+ COPY_INVERTED = 0x150C
+ EQUIV = 0x1509
+ INVERT = 0x150A
+ NAND = 0x150E
+ NOOP = 0x1505
+ NOR = 0x1508
+ OR = 0x1507
+ OR_INVERTED = 0x150D
+ OR_REVERSE = 0x150B
+ SET = 0x150F
+ XOR = 0x1506
+
+ MAP_FLUSH_EXPLICIT_BIT = 0x0010
+ MAP_INVALIDATE_BUFFER_BIT = 0x0008
+ MAP_INVALIDATE_RANGE_BIT = 0x0004
+ MAP_READ_BIT = 0x0001
+ MAP_UNSYNCHRONIZED_BIT = 0x0020
+ MAP_WRITE_BIT = 0x0002
+
+ COLOR_INDEXES = 0x1603
+ SHININESS = 0x1601
+
+ MODELVIEW = 0x1700
+ PROJECTION = 0x1701
+ TEXTURE = 0x1702
+
+ LINE = 0x1B01
+ POINT = 0x1B00
+
+ FILL = 0x1B02
+
+ COLOR = 0x1800
+ DEPTH = 0x1801
+ STENCIL = 0x1802
+
+ ALPHA = 0x1906
+ BLUE = 0x1905
+ COLOR_INDEX = 0x1900
+ DEPTH_COMPONENT = 0x1902
+ GREEN = 0x1904
+ LUMINANCE = 0x1909
+ LUMINANCE_ALPHA = 0x190A
+ RED = 0x1903
+ RGB = 0x1907
+ RGBA = 0x1908
+ STENCIL_INDEX = 0x1901
+
+ ALPHA12 = 0x803D
+ ALPHA16 = 0x803E
+ ALPHA4 = 0x803B
+ ALPHA8 = 0x803C
+ INTENSITY = 0x8049
+ INTENSITY12 = 0x804C
+ INTENSITY16 = 0x804D
+ INTENSITY4 = 0x804A
+ INTENSITY8 = 0x804B
+ LUMINANCE12 = 0x8041
+ LUMINANCE12_ALPHA12 = 0x8047
+ LUMINANCE12_ALPHA4 = 0x8046
+ LUMINANCE16 = 0x8042
+ LUMINANCE16_ALPHA16 = 0x8048
+ LUMINANCE4 = 0x803F
+ LUMINANCE4_ALPHA4 = 0x8043
+ LUMINANCE6_ALPHA2 = 0x8044
+ LUMINANCE8 = 0x8040
+ LUMINANCE8_ALPHA8 = 0x8045
+ R3_G3_B2 = 0x2A10
+ RGB10 = 0x8052
+ RGB10_A2 = 0x8059
+ RGB12 = 0x8053
+ RGB16 = 0x8054
+ RGB4 = 0x804F
+ RGB5 = 0x8050
+ RGB5_A1 = 0x8057
+ RGB8 = 0x8051
+ RGBA12 = 0x805A
+ RGBA16 = 0x805B
+ RGBA2 = 0x8055
+ RGBA4 = 0x8056
+ RGBA8 = 0x8058
+
+ PACK_IMAGE_HEIGHT = 0x806C
+ PACK_SKIP_IMAGES = 0x806B
+ UNPACK_IMAGE_HEIGHT = 0x806E
+ UNPACK_SKIP_IMAGES = 0x806D
+
+ BITMAP = 0x1A00
+ UNSIGNED_BYTE_3_3_2 = 0x8032
+ UNSIGNED_INT_10_10_10_2 = 0x8036
+ UNSIGNED_INT_8_8_8_8 = 0x8035
+ UNSIGNED_SHORT_4_4_4_4 = 0x8033
+ UNSIGNED_SHORT_5_5_5_1 = 0x8034
+
+ POINT_DISTANCE_ATTENUATION = 0x8129
+ POINT_FADE_THRESHOLD_SIZE = 0x8128
+ POINT_SIZE_MAX = 0x8127
+ POINT_SIZE_MIN = 0x8126
+
+ LINES = 0x0001
+ LINES_ADJACENCY = 0x000A
+ LINE_LOOP = 0x0002
+ LINE_STRIP = 0x0003
+ LINE_STRIP_ADJACENCY = 0x000B
+ PATCHES = 0x000E
+ POINTS = 0x0000
+ POLYGON = 0x0009
+ QUADS = 0x0007
+ QUAD_STRIP = 0x0008
+ TRIANGLES = 0x0004
+ TRIANGLES_ADJACENCY = 0x000C
+ TRIANGLE_FAN = 0x0006
+ TRIANGLE_STRIP = 0x0005
+ TRIANGLE_STRIP_ADJACENCY = 0x000D
+
+ FEEDBACK = 0x1C01
+ RENDER = 0x1C00
+ SELECT = 0x1C02
+
+ FLAT = 0x1D00
+ SMOOTH = 0x1D01
+
+ DECR = 0x1E03
+ INCR = 0x1E02
+ KEEP = 0x1E00
+
+ EXTENSIONS = 0x1F03
+ RENDERER = 0x1F01
+ VENDOR = 0x1F00
+ VERSION = 0x1F02
+
+ S = 0x2000
+ T = 0x2001
+ R = 0x2002
+ Q = 0x2003
+
+ DECAL = 0x2101
+
+ TEXTURE_ENV_COLOR = 0x2201
+ TEXTURE_ENV_MODE = 0x2200
+
+ TEXTURE_ENV = 0x2300
+
+ EYE_LINEAR = 0x2400
+ OBJECT_LINEAR = 0x2401
+ SPHERE_MAP = 0x2402
+
+ EYE_PLANE = 0x2502
+ OBJECT_PLANE = 0x2501
+ TEXTURE_GEN_MODE = 0x2500
+
+ NEAREST = 0x2600
+
+ LINEAR_MIPMAP_LINEAR = 0x2703
+ LINEAR_MIPMAP_NEAREST = 0x2701
+ NEAREST_MIPMAP_LINEAR = 0x2702
+ NEAREST_MIPMAP_NEAREST = 0x2700
+
+ GENERATE_MIPMAP = 0x8191
+ TEXTURE_WRAP_R = 0x8072
+
+ PROXY_TEXTURE_1D = 0x8063
+ PROXY_TEXTURE_2D = 0x8064
+ PROXY_TEXTURE_3D = 0x8070
+ TEXTURE_3D = 0x806F
+ TEXTURE_BASE_LEVEL = 0x813C
+ TEXTURE_MAX_LEVEL = 0x813D
+ TEXTURE_MAX_LOD = 0x813B
+ TEXTURE_MIN_LOD = 0x813A
+
+ CLAMP = 0x2900
+ CLAMP_TO_BORDER = 0x812D
+ CLAMP_TO_EDGE = 0x812F
+ REPEAT = 0x2901
+
+ SYNC_FLUSH_COMMANDS_BIT = 0x00000001
+ INVALID_INDEX = 0xFFFFFFFF
+ TIMEOUT_IGNORED = 0xFFFFFFFFFFFFFFFF
+ CONSTANT_COLOR = 0x8001
+ ONE_MINUS_CONSTANT_COLOR = 0x8002
+ CONSTANT_ALPHA = 0x8003
+ ONE_MINUS_CONSTANT_ALPHA = 0x8004
+ FUNC_ADD = 0x8006
+ MIN = 0x8007
+ MAX = 0x8008
+ BLEND_EQUATION_RGB = 0x8009
+ FUNC_SUBTRACT = 0x800A
+ FUNC_REVERSE_SUBTRACT = 0x800B
+ RESCALE_NORMAL = 0x803A
+ TEXTURE_DEPTH = 0x8071
+ MAX_3D_TEXTURE_SIZE = 0x8073
+ MULTISAMPLE = 0x809D
+ SAMPLE_ALPHA_TO_COVERAGE = 0x809E
+ SAMPLE_ALPHA_TO_ONE = 0x809F
+ SAMPLE_COVERAGE = 0x80A0
+ SAMPLE_BUFFERS = 0x80A8
+ SAMPLES = 0x80A9
+ SAMPLE_COVERAGE_VALUE = 0x80AA
+ SAMPLE_COVERAGE_INVERT = 0x80AB
+ BLEND_DST_RGB = 0x80C8
+ BLEND_SRC_RGB = 0x80C9
+ BLEND_DST_ALPHA = 0x80CA
+ BLEND_SRC_ALPHA = 0x80CB
+ BGR = 0x80E0
+ BGRA = 0x80E1
+ MAX_ELEMENTS_VERTICES = 0x80E8
+ MAX_ELEMENTS_INDICES = 0x80E9
+ DEPTH_COMPONENT16 = 0x81A5
+ DEPTH_COMPONENT24 = 0x81A6
+ DEPTH_COMPONENT32 = 0x81A7
+ FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING = 0x8210
+ FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE = 0x8211
+ FRAMEBUFFER_ATTACHMENT_RED_SIZE = 0x8212
+ FRAMEBUFFER_ATTACHMENT_GREEN_SIZE = 0x8213
+ FRAMEBUFFER_ATTACHMENT_BLUE_SIZE = 0x8214
+ FRAMEBUFFER_ATTACHMENT_ALPHA_SIZE = 0x8215
+ FRAMEBUFFER_ATTACHMENT_DEPTH_SIZE = 0x8216
+ FRAMEBUFFER_ATTACHMENT_STENCIL_SIZE = 0x8217
+ FRAMEBUFFER_DEFAULT = 0x8218
+ FRAMEBUFFER_UNDEFINED = 0x8219
+ DEPTH_STENCIL_ATTACHMENT = 0x821A
+ MAJOR_VERSION = 0x821B
+ MINOR_VERSION = 0x821C
+ NUM_EXTENSIONS = 0x821D
+ CONTEXT_FLAGS = 0x821E
+ COMPRESSED_RED = 0x8225
+ COMPRESSED_RG = 0x8226
+ RG = 0x8227
+ RG_INTEGER = 0x8228
+ R8 = 0x8229
+ R16 = 0x822A
+ RG8 = 0x822B
+ RG16 = 0x822C
+ R16F = 0x822D
+ R32F = 0x822E
+ RG16F = 0x822F
+ RG32F = 0x8230
+ R8I = 0x8231
+ R8UI = 0x8232
+ R16I = 0x8233
+ R16UI = 0x8234
+ R32I = 0x8235
+ R32UI = 0x8236
+ RG8I = 0x8237
+ RG8UI = 0x8238
+ RG16I = 0x8239
+ RG16UI = 0x823A
+ RG32I = 0x823B
+ RG32UI = 0x823C
+ UNSIGNED_BYTE_2_3_3_REV = 0x8362
+ UNSIGNED_SHORT_5_6_5 = 0x8363
+ UNSIGNED_SHORT_5_6_5_REV = 0x8364
+ UNSIGNED_SHORT_4_4_4_4_REV = 0x8365
+ UNSIGNED_SHORT_1_5_5_5_REV = 0x8366
+ UNSIGNED_INT_8_8_8_8_REV = 0x8367
+ UNSIGNED_INT_2_10_10_10_REV = 0x8368
+ MIRRORED_REPEAT = 0x8370
+ FOG_COORDINATE_SOURCE = 0x8450
+ FOG_COORD_SRC = 0x8450
+ FOG_COORDINATE = 0x8451
+ FOG_COORD = 0x8451
+ FRAGMENT_DEPTH = 0x8452
+ CURRENT_FOG_COORDINATE = 0x8453
+ CURRENT_FOG_COORD = 0x8453
+ FOG_COORDINATE_ARRAY_TYPE = 0x8454
+ FOG_COORD_ARRAY_TYPE = 0x8454
+ FOG_COORDINATE_ARRAY_STRIDE = 0x8455
+ FOG_COORD_ARRAY_STRIDE = 0x8455
+ FOG_COORDINATE_ARRAY_POINTER = 0x8456
+ FOG_COORD_ARRAY_POINTER = 0x8456
+ FOG_COORDINATE_ARRAY = 0x8457
+ FOG_COORD_ARRAY = 0x8457
+ COLOR_SUM = 0x8458
+ CURRENT_SECONDARY_COLOR = 0x8459
+ SECONDARY_COLOR_ARRAY_SIZE = 0x845A
+ SECONDARY_COLOR_ARRAY_TYPE = 0x845B
+ SECONDARY_COLOR_ARRAY_STRIDE = 0x845C
+ SECONDARY_COLOR_ARRAY_POINTER = 0x845D
+ SECONDARY_COLOR_ARRAY = 0x845E
+ CURRENT_RASTER_SECONDARY_COLOR = 0x845F
+ TEXTURE0 = 0x84C0
+ TEXTURE1 = 0x84C1
+ TEXTURE2 = 0x84C2
+ TEXTURE3 = 0x84C3
+ TEXTURE4 = 0x84C4
+ TEXTURE5 = 0x84C5
+ TEXTURE6 = 0x84C6
+ TEXTURE7 = 0x84C7
+ TEXTURE8 = 0x84C8
+ TEXTURE9 = 0x84C9
+ TEXTURE10 = 0x84CA
+ TEXTURE11 = 0x84CB
+ TEXTURE12 = 0x84CC
+ TEXTURE13 = 0x84CD
+ TEXTURE14 = 0x84CE
+ TEXTURE15 = 0x84CF
+ TEXTURE16 = 0x84D0
+ TEXTURE17 = 0x84D1
+ TEXTURE18 = 0x84D2
+ TEXTURE19 = 0x84D3
+ TEXTURE20 = 0x84D4
+ TEXTURE21 = 0x84D5
+ TEXTURE22 = 0x84D6
+ TEXTURE23 = 0x84D7
+ TEXTURE24 = 0x84D8
+ TEXTURE25 = 0x84D9
+ TEXTURE26 = 0x84DA
+ TEXTURE27 = 0x84DB
+ TEXTURE28 = 0x84DC
+ TEXTURE29 = 0x84DD
+ TEXTURE30 = 0x84DE
+ TEXTURE31 = 0x84DF
+ ACTIVE_TEXTURE = 0x84E0
+ CLIENT_ACTIVE_TEXTURE = 0x84E1
+ MAX_TEXTURE_UNITS = 0x84E2
+ TRANSPOSE_MODELVIEW_MATRIX = 0x84E3
+ TRANSPOSE_PROJECTION_MATRIX = 0x84E4
+ TRANSPOSE_TEXTURE_MATRIX = 0x84E5
+ TRANSPOSE_COLOR_MATRIX = 0x84E6
+ SUBTRACT = 0x84E7
+ MAX_RENDERBUFFER_SIZE = 0x84E8
+ COMPRESSED_ALPHA = 0x84E9
+ COMPRESSED_LUMINANCE = 0x84EA
+ COMPRESSED_LUMINANCE_ALPHA = 0x84EB
+ COMPRESSED_INTENSITY = 0x84EC
+ COMPRESSED_RGB = 0x84ED
+ COMPRESSED_RGBA = 0x84EE
+ UNIFORM_BLOCK_REFERENCED_BY_TESS_CONTROL_SHADER = 0x84F0
+ UNIFORM_BLOCK_REFERENCED_BY_TESS_EVALUATION_SHADER = 0x84F1
+ TEXTURE_RECTANGLE = 0x84F5
+ TEXTURE_BINDING_RECTANGLE = 0x84F6
+ PROXY_TEXTURE_RECTANGLE = 0x84F7
+ MAX_RECTANGLE_TEXTURE_SIZE = 0x84F8
+ DEPTH_STENCIL = 0x84F9
+ UNSIGNED_INT_24_8 = 0x84FA
+ MAX_TEXTURE_LOD_BIAS = 0x84FD
+ TEXTURE_FILTER_CONTROL = 0x8500
+ TEXTURE_LOD_BIAS = 0x8501
+ INCR_WRAP = 0x8507
+ DECR_WRAP = 0x8508
+ NORMAL_MAP = 0x8511
+ REFLECTION_MAP = 0x8512
+ TEXTURE_CUBE_MAP = 0x8513
+ TEXTURE_BINDING_CUBE_MAP = 0x8514
+ TEXTURE_CUBE_MAP_POSITIVE_X = 0x8515
+ TEXTURE_CUBE_MAP_NEGATIVE_X = 0x8516
+ TEXTURE_CUBE_MAP_POSITIVE_Y = 0x8517
+ TEXTURE_CUBE_MAP_NEGATIVE_Y = 0x8518
+ TEXTURE_CUBE_MAP_POSITIVE_Z = 0x8519
+ TEXTURE_CUBE_MAP_NEGATIVE_Z = 0x851A
+ PROXY_TEXTURE_CUBE_MAP = 0x851B
+ MAX_CUBE_MAP_TEXTURE_SIZE = 0x851C
+ COMBINE = 0x8570
+ COMBINE_RGB = 0x8571
+ COMBINE_ALPHA = 0x8572
+ RGB_SCALE = 0x8573
+ ADD_SIGNED = 0x8574
+ INTERPOLATE = 0x8575
+ CONSTANT = 0x8576
+ PRIMARY_COLOR = 0x8577
+ PREVIOUS = 0x8578
+ SOURCE0_RGB = 0x8580
+ SRC0_RGB = 0x8580
+ SOURCE1_RGB = 0x8581
+ SRC1_RGB = 0x8581
+ SOURCE2_RGB = 0x8582
+ SRC2_RGB = 0x8582
+ SOURCE0_ALPHA = 0x8588
+ SRC0_ALPHA = 0x8588
+ SOURCE1_ALPHA = 0x8589
+ SRC1_ALPHA = 0x8589
+ SOURCE2_ALPHA = 0x858A
+ SRC2_ALPHA = 0x858A
+ OPERAND0_RGB = 0x8590
+ OPERAND1_RGB = 0x8591
+ OPERAND2_RGB = 0x8592
+ OPERAND0_ALPHA = 0x8598
+ OPERAND1_ALPHA = 0x8599
+ OPERAND2_ALPHA = 0x859A
+ VERTEX_ARRAY_BINDING = 0x85B5
+ VERTEX_ATTRIB_ARRAY_ENABLED = 0x8622
+ VERTEX_ATTRIB_ARRAY_SIZE = 0x8623
+ VERTEX_ATTRIB_ARRAY_STRIDE = 0x8624
+ VERTEX_ATTRIB_ARRAY_TYPE = 0x8625
+ CURRENT_VERTEX_ATTRIB = 0x8626
+ VERTEX_PROGRAM_POINT_SIZE = 0x8642
+ PROGRAM_POINT_SIZE = 0x8642
+ VERTEX_PROGRAM_TWO_SIDE = 0x8643
+ VERTEX_ATTRIB_ARRAY_POINTER = 0x8645
+ DEPTH_CLAMP = 0x864F
+ TEXTURE_COMPRESSED_IMAGE_SIZE = 0x86A0
+ TEXTURE_COMPRESSED = 0x86A1
+ NUM_COMPRESSED_TEXTURE_FORMATS = 0x86A2
+ COMPRESSED_TEXTURE_FORMATS = 0x86A3
+ DOT3_RGB = 0x86AE
+ DOT3_RGBA = 0x86AF
+ BUFFER_SIZE = 0x8764
+ BUFFER_USAGE = 0x8765
+ STENCIL_BACK_FUNC = 0x8800
+ STENCIL_BACK_FAIL = 0x8801
+ STENCIL_BACK_PASS_DEPTH_FAIL = 0x8802
+ STENCIL_BACK_PASS_DEPTH_PASS = 0x8803
+ RGBA32F = 0x8814
+ RGB32F = 0x8815
+ RGBA16F = 0x881A
+ RGB16F = 0x881B
+ MAX_DRAW_BUFFERS = 0x8824
+ DRAW_BUFFER0 = 0x8825
+ DRAW_BUFFER1 = 0x8826
+ DRAW_BUFFER2 = 0x8827
+ DRAW_BUFFER3 = 0x8828
+ DRAW_BUFFER4 = 0x8829
+ DRAW_BUFFER5 = 0x882A
+ DRAW_BUFFER6 = 0x882B
+ DRAW_BUFFER7 = 0x882C
+ DRAW_BUFFER8 = 0x882D
+ DRAW_BUFFER9 = 0x882E
+ DRAW_BUFFER10 = 0x882F
+ DRAW_BUFFER11 = 0x8830
+ DRAW_BUFFER12 = 0x8831
+ DRAW_BUFFER13 = 0x8832
+ DRAW_BUFFER14 = 0x8833
+ DRAW_BUFFER15 = 0x8834
+ BLEND_EQUATION_ALPHA = 0x883D
+ TEXTURE_DEPTH_SIZE = 0x884A
+ DEPTH_TEXTURE_MODE = 0x884B
+ TEXTURE_COMPARE_MODE = 0x884C
+ TEXTURE_COMPARE_FUNC = 0x884D
+ COMPARE_R_TO_TEXTURE = 0x884E
+ COMPARE_REF_TO_TEXTURE = 0x884E
+ TEXTURE_CUBE_MAP_SEAMLESS = 0x884F
+ POINT_SPRITE = 0x8861
+ COORD_REPLACE = 0x8862
+ QUERY_COUNTER_BITS = 0x8864
+ CURRENT_QUERY = 0x8865
+ QUERY_RESULT = 0x8866
+ QUERY_RESULT_AVAILABLE = 0x8867
+ MAX_VERTEX_ATTRIBS = 0x8869
+ VERTEX_ATTRIB_ARRAY_NORMALIZED = 0x886A
+ MAX_TESS_CONTROL_INPUT_COMPONENTS = 0x886C
+ MAX_TESS_EVALUATION_INPUT_COMPONENTS = 0x886D
+ MAX_TEXTURE_COORDS = 0x8871
+ MAX_TEXTURE_IMAGE_UNITS = 0x8872
+ GEOMETRY_SHADER_INVOCATIONS = 0x887F
+ ARRAY_BUFFER = 0x8892
+ ELEMENT_ARRAY_BUFFER = 0x8893
+ ARRAY_BUFFER_BINDING = 0x8894
+ ELEMENT_ARRAY_BUFFER_BINDING = 0x8895
+ VERTEX_ARRAY_BUFFER_BINDING = 0x8896
+ NORMAL_ARRAY_BUFFER_BINDING = 0x8897
+ COLOR_ARRAY_BUFFER_BINDING = 0x8898
+ INDEX_ARRAY_BUFFER_BINDING = 0x8899
+ TEXTURE_COORD_ARRAY_BUFFER_BINDING = 0x889A
+ EDGE_FLAG_ARRAY_BUFFER_BINDING = 0x889B
+ SECONDARY_COLOR_ARRAY_BUFFER_BINDING = 0x889C
+ FOG_COORDINATE_ARRAY_BUFFER_BINDING = 0x889D
+ FOG_COORD_ARRAY_BUFFER_BINDING = 0x889D
+ WEIGHT_ARRAY_BUFFER_BINDING = 0x889E
+ VERTEX_ATTRIB_ARRAY_BUFFER_BINDING = 0x889F
+ READ_ONLY = 0x88B8
+ WRITE_ONLY = 0x88B9
+ READ_WRITE = 0x88BA
+ BUFFER_ACCESS = 0x88BB
+ BUFFER_MAPPED = 0x88BC
+ BUFFER_MAP_POINTER = 0x88BD
+ TIME_ELAPSED = 0x88BF
+ STREAM_DRAW = 0x88E0
+ STREAM_READ = 0x88E1
+ STREAM_COPY = 0x88E2
+ STATIC_DRAW = 0x88E4
+ STATIC_READ = 0x88E5
+ STATIC_COPY = 0x88E6
+ DYNAMIC_DRAW = 0x88E8
+ DYNAMIC_READ = 0x88E9
+ DYNAMIC_COPY = 0x88EA
+ PIXEL_PACK_BUFFER = 0x88EB
+ PIXEL_UNPACK_BUFFER = 0x88EC
+ PIXEL_PACK_BUFFER_BINDING = 0x88ED
+ PIXEL_UNPACK_BUFFER_BINDING = 0x88EF
+ DEPTH24_STENCIL8 = 0x88F0
+ TEXTURE_STENCIL_SIZE = 0x88F1
+ SRC1_COLOR = 0x88F9
+ ONE_MINUS_SRC1_COLOR = 0x88FA
+ ONE_MINUS_SRC1_ALPHA = 0x88FB
+ MAX_DUAL_SOURCE_DRAW_BUFFERS = 0x88FC
+ VERTEX_ATTRIB_ARRAY_INTEGER = 0x88FD
+ VERTEX_ATTRIB_ARRAY_DIVISOR = 0x88FE
+ MAX_ARRAY_TEXTURE_LAYERS = 0x88FF
+ MIN_PROGRAM_TEXEL_OFFSET = 0x8904
+ MAX_PROGRAM_TEXEL_OFFSET = 0x8905
+ SAMPLES_PASSED = 0x8914
+ GEOMETRY_VERTICES_OUT = 0x8916
+ GEOMETRY_INPUT_TYPE = 0x8917
+ GEOMETRY_OUTPUT_TYPE = 0x8918
+ SAMPLER_BINDING = 0x8919
+ CLAMP_VERTEX_COLOR = 0x891A
+ CLAMP_FRAGMENT_COLOR = 0x891B
+ CLAMP_READ_COLOR = 0x891C
+ FIXED_ONLY = 0x891D
+ UNIFORM_BUFFER = 0x8A11
+ UNIFORM_BUFFER_BINDING = 0x8A28
+ UNIFORM_BUFFER_START = 0x8A29
+ UNIFORM_BUFFER_SIZE = 0x8A2A
+ MAX_VERTEX_UNIFORM_BLOCKS = 0x8A2B
+ MAX_GEOMETRY_UNIFORM_BLOCKS = 0x8A2C
+ MAX_FRAGMENT_UNIFORM_BLOCKS = 0x8A2D
+ MAX_COMBINED_UNIFORM_BLOCKS = 0x8A2E
+ MAX_UNIFORM_BUFFER_BINDINGS = 0x8A2F
+ MAX_UNIFORM_BLOCK_SIZE = 0x8A30
+ MAX_COMBINED_VERTEX_UNIFORM_COMPONENTS = 0x8A31
+ MAX_COMBINED_GEOMETRY_UNIFORM_COMPONENTS = 0x8A32
+ MAX_COMBINED_FRAGMENT_UNIFORM_COMPONENTS = 0x8A33
+ UNIFORM_BUFFER_OFFSET_ALIGNMENT = 0x8A34
+ ACTIVE_UNIFORM_BLOCK_MAX_NAME_LENGTH = 0x8A35
+ ACTIVE_UNIFORM_BLOCKS = 0x8A36
+ UNIFORM_TYPE = 0x8A37
+ UNIFORM_SIZE = 0x8A38
+ UNIFORM_NAME_LENGTH = 0x8A39
+ UNIFORM_BLOCK_INDEX = 0x8A3A
+ UNIFORM_OFFSET = 0x8A3B
+ UNIFORM_ARRAY_STRIDE = 0x8A3C
+ UNIFORM_MATRIX_STRIDE = 0x8A3D
+ UNIFORM_IS_ROW_MAJOR = 0x8A3E
+ UNIFORM_BLOCK_BINDING = 0x8A3F
+ UNIFORM_BLOCK_DATA_SIZE = 0x8A40
+ UNIFORM_BLOCK_NAME_LENGTH = 0x8A41
+ UNIFORM_BLOCK_ACTIVE_UNIFORMS = 0x8A42
+ UNIFORM_BLOCK_ACTIVE_UNIFORM_INDICES = 0x8A43
+ UNIFORM_BLOCK_REFERENCED_BY_VERTEX_SHADER = 0x8A44
+ UNIFORM_BLOCK_REFERENCED_BY_GEOMETRY_SHADER = 0x8A45
+ UNIFORM_BLOCK_REFERENCED_BY_FRAGMENT_SHADER = 0x8A46
+ FRAGMENT_SHADER = 0x8B30
+ VERTEX_SHADER = 0x8B31
+ MAX_FRAGMENT_UNIFORM_COMPONENTS = 0x8B49
+ MAX_VERTEX_UNIFORM_COMPONENTS = 0x8B4A
+ MAX_VARYING_FLOATS = 0x8B4B
+ MAX_VARYING_COMPONENTS = 0x8B4B
+ MAX_VERTEX_TEXTURE_IMAGE_UNITS = 0x8B4C
+ MAX_COMBINED_TEXTURE_IMAGE_UNITS = 0x8B4D
+ SHADER_TYPE = 0x8B4F
+ FLOAT_VEC2 = 0x8B50
+ FLOAT_VEC3 = 0x8B51
+ FLOAT_VEC4 = 0x8B52
+ INT_VEC2 = 0x8B53
+ INT_VEC3 = 0x8B54
+ INT_VEC4 = 0x8B55
+ BOOL = 0x8B56
+ BOOL_VEC2 = 0x8B57
+ BOOL_VEC3 = 0x8B58
+ BOOL_VEC4 = 0x8B59
+ FLOAT_MAT2 = 0x8B5A
+ FLOAT_MAT3 = 0x8B5B
+ FLOAT_MAT4 = 0x8B5C
+ SAMPLER_1D = 0x8B5D
+ SAMPLER_2D = 0x8B5E
+ SAMPLER_3D = 0x8B5F
+ SAMPLER_CUBE = 0x8B60
+ SAMPLER_1D_SHADOW = 0x8B61
+ SAMPLER_2D_SHADOW = 0x8B62
+ SAMPLER_2D_RECT = 0x8B63
+ SAMPLER_2D_RECT_SHADOW = 0x8B64
+ FLOAT_MAT2x3 = 0x8B65
+ FLOAT_MAT2x4 = 0x8B66
+ FLOAT_MAT3x2 = 0x8B67
+ FLOAT_MAT3x4 = 0x8B68
+ FLOAT_MAT4x2 = 0x8B69
+ FLOAT_MAT4x3 = 0x8B6A
+ DELETE_STATUS = 0x8B80
+ COMPILE_STATUS = 0x8B81
+ LINK_STATUS = 0x8B82
+ VALIDATE_STATUS = 0x8B83
+ INFO_LOG_LENGTH = 0x8B84
+ ATTACHED_SHADERS = 0x8B85
+ ACTIVE_UNIFORMS = 0x8B86
+ ACTIVE_UNIFORM_MAX_LENGTH = 0x8B87
+ SHADER_SOURCE_LENGTH = 0x8B88
+ ACTIVE_ATTRIBUTES = 0x8B89
+ ACTIVE_ATTRIBUTE_MAX_LENGTH = 0x8B8A
+ SHADING_LANGUAGE_VERSION = 0x8B8C
+ CURRENT_PROGRAM = 0x8B8D
+ TEXTURE_RED_TYPE = 0x8C10
+ TEXTURE_GREEN_TYPE = 0x8C11
+ TEXTURE_BLUE_TYPE = 0x8C12
+ TEXTURE_ALPHA_TYPE = 0x8C13
+ TEXTURE_DEPTH_TYPE = 0x8C16
+ UNSIGNED_NORMALIZED = 0x8C17
+ TEXTURE_1D_ARRAY = 0x8C18
+ PROXY_TEXTURE_1D_ARRAY = 0x8C19
+ TEXTURE_2D_ARRAY = 0x8C1A
+ PROXY_TEXTURE_2D_ARRAY = 0x8C1B
+ TEXTURE_BINDING_1D_ARRAY = 0x8C1C
+ TEXTURE_BINDING_2D_ARRAY = 0x8C1D
+ MAX_GEOMETRY_TEXTURE_IMAGE_UNITS = 0x8C29
+ TEXTURE_BUFFER = 0x8C2A
+ MAX_TEXTURE_BUFFER_SIZE = 0x8C2B
+ TEXTURE_BINDING_BUFFER = 0x8C2C
+ TEXTURE_BUFFER_DATA_STORE_BINDING = 0x8C2D
+ ANY_SAMPLES_PASSED = 0x8C2F
+ SAMPLE_SHADING = 0x8C36
+ MIN_SAMPLE_SHADING_VALUE = 0x8C37
+ R11F_G11F_B10F = 0x8C3A
+ UNSIGNED_INT_10F_11F_11F_REV = 0x8C3B
+ RGB9_E5 = 0x8C3D
+ UNSIGNED_INT_5_9_9_9_REV = 0x8C3E
+ TEXTURE_SHARED_SIZE = 0x8C3F
+ SRGB = 0x8C40
+ SRGB8 = 0x8C41
+ SRGB_ALPHA = 0x8C42
+ SRGB8_ALPHA8 = 0x8C43
+ SLUMINANCE_ALPHA = 0x8C44
+ SLUMINANCE8_ALPHA8 = 0x8C45
+ SLUMINANCE = 0x8C46
+ SLUMINANCE8 = 0x8C47
+ COMPRESSED_SRGB = 0x8C48
+ COMPRESSED_SRGB_ALPHA = 0x8C49
+ COMPRESSED_SLUMINANCE = 0x8C4A
+ COMPRESSED_SLUMINANCE_ALPHA = 0x8C4B
+ TRANSFORM_FEEDBACK_VARYING_MAX_LENGTH = 0x8C76
+ TRANSFORM_FEEDBACK_BUFFER_MODE = 0x8C7F
+ MAX_TRANSFORM_FEEDBACK_SEPARATE_COMPONENTS = 0x8C80
+ TRANSFORM_FEEDBACK_VARYINGS = 0x8C83
+ TRANSFORM_FEEDBACK_BUFFER_START = 0x8C84
+ TRANSFORM_FEEDBACK_BUFFER_SIZE = 0x8C85
+ PRIMITIVES_GENERATED = 0x8C87
+ TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN = 0x8C88
+ RASTERIZER_DISCARD = 0x8C89
+ MAX_TRANSFORM_FEEDBACK_INTERLEAVED_COMPONENTS = 0x8C8A
+ MAX_TRANSFORM_FEEDBACK_SEPARATE_ATTRIBS = 0x8C8B
+ INTERLEAVED_ATTRIBS = 0x8C8C
+ SEPARATE_ATTRIBS = 0x8C8D
+ TRANSFORM_FEEDBACK_BUFFER = 0x8C8E
+ TRANSFORM_FEEDBACK_BUFFER_BINDING = 0x8C8F
+ POINT_SPRITE_COORD_ORIGIN = 0x8CA0
+ LOWER_LEFT = 0x8CA1
+ UPPER_LEFT = 0x8CA2
+ STENCIL_BACK_REF = 0x8CA3
+ STENCIL_BACK_VALUE_MASK = 0x8CA4
+ STENCIL_BACK_WRITEMASK = 0x8CA5
+ DRAW_FRAMEBUFFER_BINDING = 0x8CA6
+ FRAMEBUFFER_BINDING = 0x8CA6
+ RENDERBUFFER_BINDING = 0x8CA7
+ READ_FRAMEBUFFER = 0x8CA8
+ DRAW_FRAMEBUFFER = 0x8CA9
+ READ_FRAMEBUFFER_BINDING = 0x8CAA
+ RENDERBUFFER_SAMPLES = 0x8CAB
+ DEPTH_COMPONENT32F = 0x8CAC
+ DEPTH32F_STENCIL8 = 0x8CAD
+ FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE = 0x8CD0
+ FRAMEBUFFER_ATTACHMENT_OBJECT_NAME = 0x8CD1
+ FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL = 0x8CD2
+ FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE = 0x8CD3
+ FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER = 0x8CD4
+ FRAMEBUFFER_COMPLETE = 0x8CD5
+ FRAMEBUFFER_INCOMPLETE_ATTACHMENT = 0x8CD6
+ FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT = 0x8CD7
+ FRAMEBUFFER_INCOMPLETE_DRAW_BUFFER = 0x8CDB
+ FRAMEBUFFER_INCOMPLETE_READ_BUFFER = 0x8CDC
+ FRAMEBUFFER_UNSUPPORTED = 0x8CDD
+ MAX_COLOR_ATTACHMENTS = 0x8CDF
+ COLOR_ATTACHMENT0 = 0x8CE0
+ COLOR_ATTACHMENT1 = 0x8CE1
+ COLOR_ATTACHMENT2 = 0x8CE2
+ COLOR_ATTACHMENT3 = 0x8CE3
+ COLOR_ATTACHMENT4 = 0x8CE4
+ COLOR_ATTACHMENT5 = 0x8CE5
+ COLOR_ATTACHMENT6 = 0x8CE6
+ COLOR_ATTACHMENT7 = 0x8CE7
+ COLOR_ATTACHMENT8 = 0x8CE8
+ COLOR_ATTACHMENT9 = 0x8CE9
+ COLOR_ATTACHMENT10 = 0x8CEA
+ COLOR_ATTACHMENT11 = 0x8CEB
+ COLOR_ATTACHMENT12 = 0x8CEC
+ COLOR_ATTACHMENT13 = 0x8CED
+ COLOR_ATTACHMENT14 = 0x8CEE
+ COLOR_ATTACHMENT15 = 0x8CEF
+ DEPTH_ATTACHMENT = 0x8D00
+ STENCIL_ATTACHMENT = 0x8D20
+ FRAMEBUFFER = 0x8D40
+ RENDERBUFFER = 0x8D41
+ RENDERBUFFER_WIDTH = 0x8D42
+ RENDERBUFFER_HEIGHT = 0x8D43
+ RENDERBUFFER_INTERNAL_FORMAT = 0x8D44
+ STENCIL_INDEX1 = 0x8D46
+ STENCIL_INDEX4 = 0x8D47
+ STENCIL_INDEX8 = 0x8D48
+ STENCIL_INDEX16 = 0x8D49
+ RENDERBUFFER_RED_SIZE = 0x8D50
+ RENDERBUFFER_GREEN_SIZE = 0x8D51
+ RENDERBUFFER_BLUE_SIZE = 0x8D52
+ RENDERBUFFER_ALPHA_SIZE = 0x8D53
+ RENDERBUFFER_DEPTH_SIZE = 0x8D54
+ RENDERBUFFER_STENCIL_SIZE = 0x8D55
+ FRAMEBUFFER_INCOMPLETE_MULTISAMPLE = 0x8D56
+ MAX_SAMPLES = 0x8D57
+ RGBA32UI = 0x8D70
+ RGB32UI = 0x8D71
+ RGBA16UI = 0x8D76
+ RGB16UI = 0x8D77
+ RGBA8UI = 0x8D7C
+ RGB8UI = 0x8D7D
+ RGBA32I = 0x8D82
+ RGB32I = 0x8D83
+ RGBA16I = 0x8D88
+ RGB16I = 0x8D89
+ RGBA8I = 0x8D8E
+ RGB8I = 0x8D8F
+ RED_INTEGER = 0x8D94
+ GREEN_INTEGER = 0x8D95
+ BLUE_INTEGER = 0x8D96
+ ALPHA_INTEGER = 0x8D97
+ RGB_INTEGER = 0x8D98
+ RGBA_INTEGER = 0x8D99
+ BGR_INTEGER = 0x8D9A
+ BGRA_INTEGER = 0x8D9B
+ INT_2_10_10_10_REV = 0x8D9F
+ FRAMEBUFFER_ATTACHMENT_LAYERED = 0x8DA7
+ FRAMEBUFFER_INCOMPLETE_LAYER_TARGETS = 0x8DA8
+ FLOAT_32_UNSIGNED_INT_24_8_REV = 0x8DAD
+ FRAMEBUFFER_SRGB = 0x8DB9
+ COMPRESSED_RED_RGTC1 = 0x8DBB
+ COMPRESSED_SIGNED_RED_RGTC1 = 0x8DBC
+ COMPRESSED_RG_RGTC2 = 0x8DBD
+ COMPRESSED_SIGNED_RG_RGTC2 = 0x8DBE
+ SAMPLER_1D_ARRAY = 0x8DC0
+ SAMPLER_2D_ARRAY = 0x8DC1
+ SAMPLER_BUFFER = 0x8DC2
+ SAMPLER_1D_ARRAY_SHADOW = 0x8DC3
+ SAMPLER_2D_ARRAY_SHADOW = 0x8DC4
+ SAMPLER_CUBE_SHADOW = 0x8DC5
+ UNSIGNED_INT_VEC2 = 0x8DC6
+ UNSIGNED_INT_VEC3 = 0x8DC7
+ UNSIGNED_INT_VEC4 = 0x8DC8
+ INT_SAMPLER_1D = 0x8DC9
+ INT_SAMPLER_2D = 0x8DCA
+ INT_SAMPLER_3D = 0x8DCB
+ INT_SAMPLER_CUBE = 0x8DCC
+ INT_SAMPLER_2D_RECT = 0x8DCD
+ INT_SAMPLER_1D_ARRAY = 0x8DCE
+ INT_SAMPLER_2D_ARRAY = 0x8DCF
+ INT_SAMPLER_BUFFER = 0x8DD0
+ UNSIGNED_INT_SAMPLER_1D = 0x8DD1
+ UNSIGNED_INT_SAMPLER_2D = 0x8DD2
+ UNSIGNED_INT_SAMPLER_3D = 0x8DD3
+ UNSIGNED_INT_SAMPLER_CUBE = 0x8DD4
+ UNSIGNED_INT_SAMPLER_2D_RECT = 0x8DD5
+ UNSIGNED_INT_SAMPLER_1D_ARRAY = 0x8DD6
+ UNSIGNED_INT_SAMPLER_2D_ARRAY = 0x8DD7
+ UNSIGNED_INT_SAMPLER_BUFFER = 0x8DD8
+ GEOMETRY_SHADER = 0x8DD9
+ MAX_GEOMETRY_UNIFORM_COMPONENTS = 0x8DDF
+ MAX_GEOMETRY_OUTPUT_VERTICES = 0x8DE0
+ MAX_GEOMETRY_TOTAL_OUTPUT_COMPONENTS = 0x8DE1
+ ACTIVE_SUBROUTINES = 0x8DE5
+ ACTIVE_SUBROUTINE_UNIFORMS = 0x8DE6
+ MAX_SUBROUTINES = 0x8DE7
+ MAX_SUBROUTINE_UNIFORM_LOCATIONS = 0x8DE8
+ QUERY_WAIT = 0x8E13
+ QUERY_NO_WAIT = 0x8E14
+ QUERY_BY_REGION_WAIT = 0x8E15
+ QUERY_BY_REGION_NO_WAIT = 0x8E16
+ MAX_COMBINED_TESS_CONTROL_UNIFORM_COMPONENTS = 0x8E1E
+ MAX_COMBINED_TESS_EVALUATION_UNIFORM_COMPONENTS = 0x8E1F
+ TRANSFORM_FEEDBACK = 0x8E22
+ TRANSFORM_FEEDBACK_BUFFER_PAUSED = 0x8E23
+ TRANSFORM_FEEDBACK_BUFFER_ACTIVE = 0x8E24
+ TRANSFORM_FEEDBACK_BINDING = 0x8E25
+ TIMESTAMP = 0x8E28
+ TEXTURE_SWIZZLE_R = 0x8E42
+ TEXTURE_SWIZZLE_G = 0x8E43
+ TEXTURE_SWIZZLE_B = 0x8E44
+ TEXTURE_SWIZZLE_A = 0x8E45
+ TEXTURE_SWIZZLE_RGBA = 0x8E46
+ ACTIVE_SUBROUTINE_UNIFORM_LOCATIONS = 0x8E47
+ ACTIVE_SUBROUTINE_MAX_LENGTH = 0x8E48
+ ACTIVE_SUBROUTINE_UNIFORM_MAX_LENGTH = 0x8E49
+ NUM_COMPATIBLE_SUBROUTINES = 0x8E4A
+ COMPATIBLE_SUBROUTINES = 0x8E4B
+ QUADS_FOLLOW_PROVOKING_VERTEX_CONVENTION = 0x8E4C
+ FIRST_VERTEX_CONVENTION = 0x8E4D
+ LAST_VERTEX_CONVENTION = 0x8E4E
+ PROVOKING_VERTEX = 0x8E4F
+ SAMPLE_POSITION = 0x8E50
+ SAMPLE_MASK = 0x8E51
+ SAMPLE_MASK_VALUE = 0x8E52
+ MAX_SAMPLE_MASK_WORDS = 0x8E59
+ MAX_GEOMETRY_SHADER_INVOCATIONS = 0x8E5A
+ MIN_FRAGMENT_INTERPOLATION_OFFSET = 0x8E5B
+ MAX_FRAGMENT_INTERPOLATION_OFFSET = 0x8E5C
+ FRAGMENT_INTERPOLATION_OFFSET_BITS = 0x8E5D
+ MIN_PROGRAM_TEXTURE_GATHER_OFFSET = 0x8E5E
+ MAX_PROGRAM_TEXTURE_GATHER_OFFSET = 0x8E5F
+ MAX_TRANSFORM_FEEDBACK_BUFFERS = 0x8E70
+ MAX_VERTEX_STREAMS = 0x8E71
+ PATCH_VERTICES = 0x8E72
+ PATCH_DEFAULT_INNER_LEVEL = 0x8E73
+ PATCH_DEFAULT_OUTER_LEVEL = 0x8E74
+ TESS_CONTROL_OUTPUT_VERTICES = 0x8E75
+ TESS_GEN_MODE = 0x8E76
+ TESS_GEN_SPACING = 0x8E77
+ TESS_GEN_VERTEX_ORDER = 0x8E78
+ TESS_GEN_POINT_MODE = 0x8E79
+ ISOLINES = 0x8E7A
+ FRACTIONAL_ODD = 0x8E7B
+ FRACTIONAL_EVEN = 0x8E7C
+ MAX_PATCH_VERTICES = 0x8E7D
+ MAX_TESS_GEN_LEVEL = 0x8E7E
+ MAX_TESS_CONTROL_UNIFORM_COMPONENTS = 0x8E7F
+ MAX_TESS_EVALUATION_UNIFORM_COMPONENTS = 0x8E80
+ MAX_TESS_CONTROL_TEXTURE_IMAGE_UNITS = 0x8E81
+ MAX_TESS_EVALUATION_TEXTURE_IMAGE_UNITS = 0x8E82
+ MAX_TESS_CONTROL_OUTPUT_COMPONENTS = 0x8E83
+ MAX_TESS_PATCH_COMPONENTS = 0x8E84
+ MAX_TESS_CONTROL_TOTAL_OUTPUT_COMPONENTS = 0x8E85
+ MAX_TESS_EVALUATION_OUTPUT_COMPONENTS = 0x8E86
+ TESS_EVALUATION_SHADER = 0x8E87
+ TESS_CONTROL_SHADER = 0x8E88
+ MAX_TESS_CONTROL_UNIFORM_BLOCKS = 0x8E89
+ MAX_TESS_EVALUATION_UNIFORM_BLOCKS = 0x8E8A
+ COPY_READ_BUFFER = 0x8F36
+ COPY_WRITE_BUFFER = 0x8F37
+ DRAW_INDIRECT_BUFFER = 0x8F3F
+ DRAW_INDIRECT_BUFFER_BINDING = 0x8F43
+ DOUBLE_MAT2 = 0x8F46
+ DOUBLE_MAT3 = 0x8F47
+ DOUBLE_MAT4 = 0x8F48
+ DOUBLE_MAT2x3 = 0x8F49
+ DOUBLE_MAT2x4 = 0x8F4A
+ DOUBLE_MAT3x2 = 0x8F4B
+ DOUBLE_MAT3x4 = 0x8F4C
+ DOUBLE_MAT4x2 = 0x8F4D
+ DOUBLE_MAT4x3 = 0x8F4E
+ R8_SNORM = 0x8F94
+ RG8_SNORM = 0x8F95
+ RGB8_SNORM = 0x8F96
+ RGBA8_SNORM = 0x8F97
+ R16_SNORM = 0x8F98
+ RG16_SNORM = 0x8F99
+ RGB16_SNORM = 0x8F9A
+ RGBA16_SNORM = 0x8F9B
+ SIGNED_NORMALIZED = 0x8F9C
+ PRIMITIVE_RESTART = 0x8F9D
+ PRIMITIVE_RESTART_INDEX = 0x8F9E
+ DOUBLE_VEC2 = 0x8FFC
+ DOUBLE_VEC3 = 0x8FFD
+ DOUBLE_VEC4 = 0x8FFE
+ TEXTURE_CUBE_MAP_ARRAY = 0x9009
+ TEXTURE_BINDING_CUBE_MAP_ARRAY = 0x900A
+ PROXY_TEXTURE_CUBE_MAP_ARRAY = 0x900B
+ SAMPLER_CUBE_MAP_ARRAY = 0x900C
+ SAMPLER_CUBE_MAP_ARRAY_SHADOW = 0x900D
+ INT_SAMPLER_CUBE_MAP_ARRAY = 0x900E
+ UNSIGNED_INT_SAMPLER_CUBE_MAP_ARRAY = 0x900F
+ RGB10_A2UI = 0x906F
+ TEXTURE_2D_MULTISAMPLE = 0x9100
+ PROXY_TEXTURE_2D_MULTISAMPLE = 0x9101
+ TEXTURE_2D_MULTISAMPLE_ARRAY = 0x9102
+ PROXY_TEXTURE_2D_MULTISAMPLE_ARRAY = 0x9103
+ TEXTURE_BINDING_2D_MULTISAMPLE = 0x9104
+ TEXTURE_BINDING_2D_MULTISAMPLE_ARRAY = 0x9105
+ TEXTURE_SAMPLES = 0x9106
+ TEXTURE_FIXED_SAMPLE_LOCATIONS = 0x9107
+ SAMPLER_2D_MULTISAMPLE = 0x9108
+ INT_SAMPLER_2D_MULTISAMPLE = 0x9109
+ UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE = 0x910A
+ SAMPLER_2D_MULTISAMPLE_ARRAY = 0x910B
+ INT_SAMPLER_2D_MULTISAMPLE_ARRAY = 0x910C
+ UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE_ARRAY = 0x910D
+ MAX_COLOR_TEXTURE_SAMPLES = 0x910E
+ MAX_DEPTH_TEXTURE_SAMPLES = 0x910F
+ MAX_INTEGER_SAMPLES = 0x9110
+ MAX_SERVER_WAIT_TIMEOUT = 0x9111
+ OBJECT_TYPE = 0x9112
+ SYNC_CONDITION = 0x9113
+ SYNC_STATUS = 0x9114
+ SYNC_FLAGS = 0x9115
+ SYNC_FENCE = 0x9116
+ SYNC_GPU_COMMANDS_COMPLETE = 0x9117
+ UNSIGNALED = 0x9118
+ SIGNALED = 0x9119
+ ALREADY_SIGNALED = 0x911A
+ TIMEOUT_EXPIRED = 0x911B
+ CONDITION_SATISFIED = 0x911C
+ WAIT_FAILED = 0x911D
+ BUFFER_ACCESS_FLAGS = 0x911F
+ BUFFER_MAP_LENGTH = 0x9120
+ BUFFER_MAP_OFFSET = 0x9121
+ MAX_VERTEX_OUTPUT_COMPONENTS = 0x9122
+ MAX_GEOMETRY_INPUT_COMPONENTS = 0x9123
+ MAX_GEOMETRY_OUTPUT_COMPONENTS = 0x9124
+ MAX_FRAGMENT_INPUT_COMPONENTS = 0x9125
+ CONTEXT_PROFILE_MASK = 0x9126
+)
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glViewport.xml
+func (gl *GL) Viewport(x, y, width, height int) {
+ C.gl4_0core_glViewport(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// DepthRange specifies the mapping of depth values from normalized device
+// coordinates to window coordinates.
+//
+// Parameter nearVal specifies the mapping of the near clipping plane to window
+// coordinates (defaults to 0), while farVal specifies the mapping of the far
+// clipping plane to window coordinates (defaults to 1).
+//
+// After clipping and division by w, depth coordinates range from -1 to 1,
+// corresponding to the near and far clipping planes. DepthRange specifies a
+// linear mapping of the normalized depth coordinates in this range to window
+// depth coordinates. Regardless of the actual depth buffer implementation,
+// window coordinate depth values are treated as though they range from 0 through 1
+// (like color components). Thus, the values accepted by DepthRange are both
+// clamped to this range before they are accepted.
+//
+// The default setting of (0, 1) maps the near plane to 0 and the far plane to 1.
+// With this mapping, the depth buffer range is fully utilized.
+//
+// It is not necessary that nearVal be less than farVal. Reverse mappings such as
+// nearVal 1, and farVal 0 are acceptable.
+//
+// GL.INVALID_OPERATION is generated if DepthRange is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) DepthRange(nearVal, farVal float64) {
+ C.gl4_0core_glDepthRange(gl.funcs, C.GLdouble(nearVal), C.GLdouble(farVal))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsEnabled.xml
+func (gl *GL) IsEnabled(cap glbase.Enum) bool {
+ glresult := C.gl4_0core_glIsEnabled(gl.funcs, C.GLenum(cap))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexLevelParameteriv.xml
+func (gl *GL) GetTexLevelParameteriv(target glbase.Enum, level int, pname glbase.Enum, params []int32) {
+ C.gl4_0core_glGetTexLevelParameteriv(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexLevelParameterfv.xml
+func (gl *GL) GetTexLevelParameterfv(target glbase.Enum, level int, pname glbase.Enum, params []float32) {
+ C.gl4_0core_glGetTexLevelParameterfv(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexParameteriv.xml
+func (gl *GL) GetTexParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl4_0core_glGetTexParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexParameterfv.xml
+func (gl *GL) GetTexParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl4_0core_glGetTexParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexImage.xml
+func (gl *GL) GetTexImage(target glbase.Enum, level int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0core_glGetTexImage(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetIntegerv.xml
+func (gl *GL) GetIntegerv(pname glbase.Enum, params []int32) {
+ C.gl4_0core_glGetIntegerv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetFloatv.xml
+func (gl *GL) GetFloatv(pname glbase.Enum, params []float32) {
+ C.gl4_0core_glGetFloatv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetError.xml
+func (gl *GL) GetError() glbase.Enum {
+ glresult := C.gl4_0core_glGetError(gl.funcs)
+ return glbase.Enum(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetDoublev.xml
+func (gl *GL) GetDoublev(pname glbase.Enum, params []float64) {
+ C.gl4_0core_glGetDoublev(gl.funcs, C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetBooleanv.xml
+func (gl *GL) GetBooleanv(pname glbase.Enum, params []bool) {
+ C.gl4_0core_glGetBooleanv(gl.funcs, C.GLenum(pname), (*C.GLboolean)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glReadPixels.xml
+func (gl *GL) ReadPixels(x, y, width, height int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0core_glReadPixels(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glReadBuffer.xml
+func (gl *GL) ReadBuffer(mode glbase.Enum) {
+ C.gl4_0core_glReadBuffer(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPixelStorei.xml
+func (gl *GL) PixelStorei(pname glbase.Enum, param int32) {
+ C.gl4_0core_glPixelStorei(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPixelStoref.xml
+func (gl *GL) PixelStoref(pname glbase.Enum, param float32) {
+ C.gl4_0core_glPixelStoref(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDepthFunc.xml
+func (gl *GL) DepthFunc(glfunc glbase.Enum) {
+ C.gl4_0core_glDepthFunc(gl.funcs, C.GLenum(glfunc))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glStencilOp.xml
+func (gl *GL) StencilOp(fail, zfail, zpass glbase.Enum) {
+ C.gl4_0core_glStencilOp(gl.funcs, C.GLenum(fail), C.GLenum(zfail), C.GLenum(zpass))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glStencilFunc.xml
+func (gl *GL) StencilFunc(glfunc glbase.Enum, ref int32, mask uint32) {
+ C.gl4_0core_glStencilFunc(gl.funcs, C.GLenum(glfunc), C.GLint(ref), C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLogicOp.xml
+func (gl *GL) LogicOp(opcode glbase.Enum) {
+ C.gl4_0core_glLogicOp(gl.funcs, C.GLenum(opcode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendFunc.xml
+func (gl *GL) BlendFunc(sfactor, dfactor glbase.Enum) {
+ C.gl4_0core_glBlendFunc(gl.funcs, C.GLenum(sfactor), C.GLenum(dfactor))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFlush.xml
+func (gl *GL) Flush() {
+ C.gl4_0core_glFlush(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFinish.xml
+func (gl *GL) Finish() {
+ C.gl4_0core_glFinish(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEnable.xml
+func (gl *GL) Enable(cap glbase.Enum) {
+ C.gl4_0core_glEnable(gl.funcs, C.GLenum(cap))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDisable.xml
+func (gl *GL) Disable(cap glbase.Enum) {
+ C.gl4_0core_glDisable(gl.funcs, C.GLenum(cap))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDepthMask.xml
+func (gl *GL) DepthMask(flag bool) {
+ C.gl4_0core_glDepthMask(gl.funcs, *(*C.GLboolean)(unsafe.Pointer(&flag)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorMask.xml
+func (gl *GL) ColorMask(red, green, blue, alpha bool) {
+ C.gl4_0core_glColorMask(gl.funcs, *(*C.GLboolean)(unsafe.Pointer(&red)), *(*C.GLboolean)(unsafe.Pointer(&green)), *(*C.GLboolean)(unsafe.Pointer(&blue)), *(*C.GLboolean)(unsafe.Pointer(&alpha)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glStencilMask.xml
+func (gl *GL) StencilMask(mask uint32) {
+ C.gl4_0core_glStencilMask(gl.funcs, C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearDepth.xml
+func (gl *GL) ClearDepth(depth float64) {
+ C.gl4_0core_glClearDepth(gl.funcs, C.GLdouble(depth))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearStencil.xml
+func (gl *GL) ClearStencil(s int32) {
+ C.gl4_0core_glClearStencil(gl.funcs, C.GLint(s))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearColor.xml
+func (gl *GL) ClearColor(red, green, blue, alpha float32) {
+ C.gl4_0core_glClearColor(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClear.xml
+func (gl *GL) Clear(mask glbase.Bitfield) {
+ C.gl4_0core_glClear(gl.funcs, C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawBuffer.xml
+func (gl *GL) DrawBuffer(mode glbase.Enum) {
+ C.gl4_0core_glDrawBuffer(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexImage2D.xml
+func (gl *GL) TexImage2D(target glbase.Enum, level int, internalFormat int32, width, height, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0core_glTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexImage1D.xml
+func (gl *GL) TexImage1D(target glbase.Enum, level int, internalFormat int32, width, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0core_glTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexParameteriv.xml
+func (gl *GL) TexParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl4_0core_glTexParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexParameteri.xml
+func (gl *GL) TexParameteri(target, pname glbase.Enum, param int32) {
+ C.gl4_0core_glTexParameteri(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexParameterfv.xml
+func (gl *GL) TexParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl4_0core_glTexParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexParameterf.xml
+func (gl *GL) TexParameterf(target, pname glbase.Enum, param float32) {
+ C.gl4_0core_glTexParameterf(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glScissor.xml
+func (gl *GL) Scissor(x, y, width, height int) {
+ C.gl4_0core_glScissor(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPolygonMode.xml
+func (gl *GL) PolygonMode(face, mode glbase.Enum) {
+ C.gl4_0core_glPolygonMode(gl.funcs, C.GLenum(face), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPointSize.xml
+func (gl *GL) PointSize(size float32) {
+ C.gl4_0core_glPointSize(gl.funcs, C.GLfloat(size))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLineWidth.xml
+func (gl *GL) LineWidth(width float32) {
+ C.gl4_0core_glLineWidth(gl.funcs, C.GLfloat(width))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glHint.xml
+func (gl *GL) Hint(target, mode glbase.Enum) {
+ C.gl4_0core_glHint(gl.funcs, C.GLenum(target), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFrontFace.xml
+func (gl *GL) FrontFace(mode glbase.Enum) {
+ C.gl4_0core_glFrontFace(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCullFace.xml
+func (gl *GL) CullFace(mode glbase.Enum) {
+ C.gl4_0core_glCullFace(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIndexubv.xml
+func (gl *GL) Indexubv(c []uint8) {
+ C.gl4_0core_glIndexubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIndexub.xml
+func (gl *GL) Indexub(c uint8) {
+ C.gl4_0core_glIndexub(gl.funcs, C.GLubyte(c))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsTexture.xml
+func (gl *GL) IsTexture(texture glbase.Texture) bool {
+ glresult := C.gl4_0core_glIsTexture(gl.funcs, C.GLuint(texture))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// GenTextures returns n texture names in textures. There is no guarantee
+// that the names form a contiguous set of integers; however, it is
+// guaranteed that none of the returned names was in use immediately before
+// the call to GenTextures.
+//
+// The generated textures have no dimensionality; they assume the
+// dimensionality of the texture target to which they are first bound (see
+// BindTexture).
+//
+// Texture names returned by a call to GenTextures are not returned by
+// subsequent calls, unless they are first deleted with DeleteTextures.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// GenTextures is available in GL version 2.0 or greater.
+func (gl *GL) GenTextures(n int) []glbase.Texture {
+ if n == 0 {
+ return nil
+ }
+ textures := make([]glbase.Texture, n)
+ C.gl4_0core_glGenTextures(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])))
+ return textures
+}
+
+// DeleteTextures deletes the textures objects whose names are stored
+// in the textures slice. After a texture is deleted, it has no contents or
+// dimensionality, and its name is free for reuse (for example by
+// GenTextures). If a texture that is currently bound is deleted, the binding
+// reverts to 0 (the default texture).
+//
+// DeleteTextures silently ignores 0's and names that do not correspond to
+// existing textures.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// DeleteTextures is available in GL version 2.0 or greater.
+func (gl *GL) DeleteTextures(textures []glbase.Texture) {
+ n := len(textures)
+ if n == 0 {
+ return
+ }
+ C.gl4_0core_glDeleteTextures(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindTexture.xml
+func (gl *GL) BindTexture(target glbase.Enum, texture glbase.Texture) {
+ C.gl4_0core_glBindTexture(gl.funcs, C.GLenum(target), C.GLuint(texture))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexSubImage2D.xml
+func (gl *GL) TexSubImage2D(target glbase.Enum, level, xoffset, yoffset, width, height int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0core_glTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexSubImage1D.xml
+func (gl *GL) TexSubImage1D(target glbase.Enum, level, xoffset, width int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0core_glTexSubImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLsizei(width), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyTexSubImage2D.xml
+func (gl *GL) CopyTexSubImage2D(target glbase.Enum, level, xoffset, yoffset, x, y, width, height int) {
+ C.gl4_0core_glCopyTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyTexSubImage1D.xml
+func (gl *GL) CopyTexSubImage1D(target glbase.Enum, level, xoffset, x, y, width int) {
+ C.gl4_0core_glCopyTexSubImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(x), C.GLint(y), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyTexImage2D.xml
+func (gl *GL) CopyTexImage2D(target glbase.Enum, level int, internalFormat glbase.Enum, x, y, width, height, border int) {
+ C.gl4_0core_glCopyTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height), C.GLint(border))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyTexImage1D.xml
+func (gl *GL) CopyTexImage1D(target glbase.Enum, level int, internalFormat glbase.Enum, x, y, width, border int) {
+ C.gl4_0core_glCopyTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLint(border))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPolygonOffset.xml
+func (gl *GL) PolygonOffset(factor, units float32) {
+ C.gl4_0core_glPolygonOffset(gl.funcs, C.GLfloat(factor), C.GLfloat(units))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawElements.xml
+func (gl *GL) DrawElements(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0core_glDrawElements(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawArrays.xml
+func (gl *GL) DrawArrays(mode glbase.Enum, first, count int) {
+ C.gl4_0core_glDrawArrays(gl.funcs, C.GLenum(mode), C.GLint(first), C.GLsizei(count))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyTexSubImage3D.xml
+func (gl *GL) CopyTexSubImage3D(target glbase.Enum, level, xoffset, yoffset int, zoffset int32, x, y, width, height int) {
+ C.gl4_0core_glCopyTexSubImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(zoffset), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexSubImage3D.xml
+func (gl *GL) TexSubImage3D(target glbase.Enum, level, xoffset, yoffset int, zoffset int32, width, height int, depth int32, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0core_glTexSubImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(zoffset), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexImage3D.xml
+func (gl *GL) TexImage3D(target glbase.Enum, level int, internalFormat int32, width, height int, depth int32, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0core_glTexImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawRangeElements.xml
+func (gl *GL) DrawRangeElements(mode glbase.Enum, start, end uint32, count int, gltype glbase.Enum, indices interface{}) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0core_glDrawRangeElements(gl.funcs, C.GLenum(mode), C.GLuint(start), C.GLuint(end), C.GLsizei(count), C.GLenum(gltype), indices_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendEquation.xml
+func (gl *GL) BlendEquation(mode glbase.Enum) {
+ C.gl4_0core_glBlendEquation(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendColor.xml
+func (gl *GL) BlendColor(red, green, blue, alpha float32) {
+ C.gl4_0core_glBlendColor(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetCompressedTexImage.xml
+func (gl *GL) GetCompressedTexImage(target glbase.Enum, level int, img interface{}) {
+ var img_ptr unsafe.Pointer
+ var img_v = reflect.ValueOf(img)
+ if img != nil && img_v.Kind() != reflect.Slice {
+ panic("parameter img must be a slice")
+ }
+ if img != nil {
+ img_ptr = unsafe.Pointer(img_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0core_glGetCompressedTexImage(gl.funcs, C.GLenum(target), C.GLint(level), img_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCompressedTexSubImage1D.xml
+func (gl *GL) CompressedTexSubImage1D(target glbase.Enum, level, xoffset, width int, format glbase.Enum, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0core_glCompressedTexSubImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLsizei(width), C.GLenum(format), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCompressedTexSubImage2D.xml
+func (gl *GL) CompressedTexSubImage2D(target glbase.Enum, level, xoffset, yoffset, width, height int, format glbase.Enum, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0core_glCompressedTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCompressedTexSubImage3D.xml
+func (gl *GL) CompressedTexSubImage3D(target glbase.Enum, level, xoffset, yoffset int, zoffset int32, width, height int, depth int32, format glbase.Enum, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0core_glCompressedTexSubImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(zoffset), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLenum(format), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCompressedTexImage1D.xml
+func (gl *GL) CompressedTexImage1D(target glbase.Enum, level int, internalFormat glbase.Enum, width, border, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0core_glCompressedTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLsizei(width), C.GLint(border), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCompressedTexImage2D.xml
+func (gl *GL) CompressedTexImage2D(target glbase.Enum, level int, internalFormat glbase.Enum, width, height, border, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0core_glCompressedTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLint(border), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCompressedTexImage3D.xml
+func (gl *GL) CompressedTexImage3D(target glbase.Enum, level int, internalFormat glbase.Enum, width, height int, depth int32, border, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0core_glCompressedTexImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLint(border), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSampleCoverage.xml
+func (gl *GL) SampleCoverage(value float32, invert bool) {
+ C.gl4_0core_glSampleCoverage(gl.funcs, C.GLfloat(value), *(*C.GLboolean)(unsafe.Pointer(&invert)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glActiveTexture.xml
+func (gl *GL) ActiveTexture(texture glbase.Enum) {
+ C.gl4_0core_glActiveTexture(gl.funcs, C.GLenum(texture))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPointParameteriv.xml
+func (gl *GL) PointParameteriv(pname glbase.Enum, params []int32) {
+ C.gl4_0core_glPointParameteriv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPointParameteri.xml
+func (gl *GL) PointParameteri(pname glbase.Enum, param int32) {
+ C.gl4_0core_glPointParameteri(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPointParameterfv.xml
+func (gl *GL) PointParameterfv(pname glbase.Enum, params []float32) {
+ C.gl4_0core_glPointParameterfv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPointParameterf.xml
+func (gl *GL) PointParameterf(pname glbase.Enum, param float32) {
+ C.gl4_0core_glPointParameterf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiDrawArrays.xml
+func (gl *GL) MultiDrawArrays(mode glbase.Enum, first, count []int, drawcount int32) {
+ C.gl4_0core_glMultiDrawArrays(gl.funcs, C.GLenum(mode), (*C.GLint)(unsafe.Pointer(&first[0])), (*C.GLsizei)(unsafe.Pointer(&count[0])), C.GLsizei(drawcount))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendFuncSeparate.xml
+func (gl *GL) BlendFuncSeparate(sfactorRGB, dfactorRGB, sfactorAlpha, dfactorAlpha glbase.Enum) {
+ C.gl4_0core_glBlendFuncSeparate(gl.funcs, C.GLenum(sfactorRGB), C.GLenum(dfactorRGB), C.GLenum(sfactorAlpha), C.GLenum(dfactorAlpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetBufferParameteriv.xml
+func (gl *GL) GetBufferParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl4_0core_glGetBufferParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUnmapBuffer.xml
+func (gl *GL) UnmapBuffer(target glbase.Enum) bool {
+ glresult := C.gl4_0core_glUnmapBuffer(gl.funcs, C.GLenum(target))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetBufferSubData.xml
+func (gl *GL) GetBufferSubData(target glbase.Enum, offset, size int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0core_glGetBufferSubData(gl.funcs, C.GLenum(target), C.GLintptr(offset), C.GLsizeiptr(size), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBufferSubData.xml
+func (gl *GL) BufferSubData(target glbase.Enum, offset, size int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0core_glBufferSubData(gl.funcs, C.GLenum(target), C.GLintptr(offset), C.GLsizeiptr(size), data_ptr)
+}
+
+// BufferData creates a new data store for the buffer object currently
+// bound to target. Any pre-existing data store is deleted. The new data
+// store is created with the specified size in bytes and usage. If data is
+// not nil, it must be a slice that is used to initialize the data store.
+// In that case the size parameter is ignored and the store size will match
+// the slice data size.
+//
+// In its initial state, the new data store is not mapped, it has a NULL
+// mapped pointer, and its mapped access is GL.READ_WRITE.
+//
+// The target constant must be one of GL.ARRAY_BUFFER, GL.COPY_READ_BUFFER,
+// GL.COPY_WRITE_BUFFER, GL.ELEMENT_ARRAY_BUFFER, GL.PIXEL_PACK_BUFFER,
+// GL.PIXEL_UNPACK_BUFFER, GL.TEXTURE_BUFFER, GL.TRANSFORM_FEEDBACK_BUFFER,
+// or GL.UNIFORM_BUFFER.
+//
+// The usage parameter is a hint to the GL implementation as to how a buffer
+// object's data store will be accessed. This enables the GL implementation
+// to make more intelligent decisions that may significantly impact buffer
+// object performance. It does not, however, constrain the actual usage of
+// the data store. usage can be broken down into two parts: first, the
+// frequency of access (modification and usage), and second, the nature of
+// that access.
+//
+// A usage frequency of STREAM and nature of DRAW is specified via the
+// constant GL.STREAM_DRAW, for example.
+//
+// The usage frequency of access may be one of:
+//
+// STREAM
+// The data store contents will be modified once and used at most a few times.
+//
+// STATIC
+// The data store contents will be modified once and used many times.
+//
+// DYNAMIC
+// The data store contents will be modified repeatedly and used many times.
+//
+// The usage nature of access may be one of:
+//
+// DRAW
+// The data store contents are modified by the application, and used as
+// the source for GL drawing and image specification commands.
+//
+// READ
+// The data store contents are modified by reading data from the GL,
+// and used to return that data when queried by the application.
+//
+// COPY
+// The data store contents are modified by reading data from the GL,
+// and used as the source for GL drawing and image specification
+// commands.
+//
+// Clients must align data elements consistent with the requirements of the
+// client platform, with an additional base-level requirement that an offset
+// within a buffer to a datum comprising N bytes be a multiple of N.
+//
+// Error GL.INVALID_ENUM is generated if target is not one of the accepted
+// buffer targets. GL.INVALID_ENUM is generated if usage is not
+// GL.STREAM_DRAW, GL.STREAM_READ, GL.STREAM_COPY, GL.STATIC_DRAW,
+// GL.STATIC_READ, GL.STATIC_COPY, GL.DYNAMIC_DRAW, GL.DYNAMIC_READ, or
+// GL.DYNAMIC_COPY. GL.INVALID_VALUE is generated if size is negative.
+// GL.INVALID_OPERATION is generated if the reserved buffer object name 0 is
+// bound to target. GL.OUT_OF_MEMORY is generated if the GL is unable to
+// create a data store with the specified size.
+func (gl *GL) BufferData(target glbase.Enum, size int, data interface{}, usage glbase.Enum) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ if data != nil {
+ size = int(data_v.Type().Size()) * data_v.Len()
+ }
+ C.gl4_0core_glBufferData(gl.funcs, C.GLenum(target), C.GLsizeiptr(size), data_ptr, C.GLenum(usage))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsBuffer.xml
+func (gl *GL) IsBuffer(buffer glbase.Buffer) bool {
+ glresult := C.gl4_0core_glIsBuffer(gl.funcs, C.GLuint(buffer))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// GenBuffers returns n buffer object names. There is no guarantee that
+// the names form a contiguous set of integers; however, it is guaranteed
+// that none of the returned names was in use immediately before the call to
+// GenBuffers.
+//
+// Buffer object names returned by a call to GenBuffers are not returned by
+// subsequent calls, unless they are first deleted with DeleteBuffers.
+//
+// No buffer objects are associated with the returned buffer object names
+// until they are first bound by calling BindBuffer.
+//
+// Error GL.INVALID_VALUE is generated if n is negative. GL.INVALID_OPERATION
+// is generated if GenBuffers is executed between the execution of Begin
+// and the corresponding execution of End.
+//
+// GenBuffers is available in GL version 1.5 or greater.
+func (gl *GL) GenBuffers(n int) []glbase.Buffer {
+ if n == 0 {
+ return nil
+ }
+ buffers := make([]glbase.Buffer, n)
+ C.gl4_0core_glGenBuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&buffers[0])))
+ return buffers
+}
+
+// DeleteBuffers deletes the buffer objects whose names are stored in the
+// buffers slice.
+//
+// After a buffer object is deleted, it has no contents, and its name is free
+// for reuse (for example by GenBuffers). If a buffer object that is
+// currently bound is deleted, the binding reverts to 0 (the absence of any
+// buffer object, which reverts to client memory usage).
+//
+// DeleteBuffers silently ignores 0's and names that do not correspond to
+// existing buffer objects.
+//
+// Error GL.INVALID_VALUE is generated if n is negative. GL.INVALID_OPERATION
+// is generated if DeleteBuffers is executed between the execution of Begin
+// and the corresponding execution of End.
+//
+// DeleteBuffers is available in GL version 1.5 or greater.
+func (gl *GL) DeleteBuffers(buffers []glbase.Buffer) {
+ n := len(buffers)
+ if n == 0 {
+ return
+ }
+ C.gl4_0core_glDeleteBuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&buffers[0])))
+}
+
+// BindBuffer creates or puts in use a named buffer object.
+// Calling BindBuffer with target set to GL.ARRAY_BUFFER,
+// GL.ELEMENT_ARRAY_BUFFER, GL.PIXEL_PACK_BUFFER or GL.PIXEL_UNPACK_BUFFER
+// and buffer set to the name of the new buffer object binds the buffer
+// object name to the target. When a buffer object is bound to a target, the
+// previous binding for that target is automatically broken.
+//
+// Buffer object names are unsigned integers. The value zero is reserved, but
+// there is no default buffer object for each buffer object target. Instead,
+// buffer set to zero effectively unbinds any buffer object previously bound,
+// and restores client memory usage for that buffer object target. Buffer
+// object names and the corresponding buffer object contents are local to the
+// shared display-list space (see XCreateContext) of the current GL rendering
+// context; two rendering contexts share buffer object names only if they
+// also share display lists.
+//
+// GenBuffers may be called to generate a set of new buffer object names.
+//
+// The state of a buffer object immediately after it is first bound is an
+// unmapped zero-sized memory buffer with GL.READ_WRITE access and
+// GL.STATIC_DRAW usage.
+//
+// While a non-zero buffer object name is bound, GL operations on the target
+// to which it is bound affect the bound buffer object, and queries of the
+// target to which it is bound return state from the bound buffer object.
+// While buffer object name zero is bound, as in the initial state, attempts
+// to modify or query state on the target to which it is bound generates an
+// GL.INVALID_OPERATION error.
+//
+// When vertex array pointer state is changed, for example by a call to
+// NormalPointer, the current buffer object binding (GL.ARRAY_BUFFER_BINDING)
+// is copied into the corresponding client state for the vertex array type
+// being changed, for example GL.NORMAL_ARRAY_BUFFER_BINDING. While a
+// non-zero buffer object is bound to the GL.ARRAY_BUFFER target, the vertex
+// array pointer parameter that is traditionally interpreted as a pointer to
+// client-side memory is instead interpreted as an offset within the buffer
+// object measured in basic machine units.
+//
+// While a non-zero buffer object is bound to the GL.ELEMENT_ARRAY_BUFFER
+// target, the indices parameter of DrawElements, DrawRangeElements, or
+// MultiDrawElements that is traditionally interpreted as a pointer to
+// client-side memory is instead interpreted as an offset within the buffer
+// object measured in basic machine units.
+//
+// While a non-zero buffer object is bound to the GL.PIXEL_PACK_BUFFER
+// target, the following commands are affected: GetCompressedTexImage,
+// GetConvolutionFilter, GetHistogram, GetMinmax, GetPixelMap,
+// GetPolygonStipple, GetSeparableFilter, GetTexImage, and ReadPixels. The
+// pointer parameter that is traditionally interpreted as a pointer to
+// client-side memory where the pixels are to be packed is instead
+// interpreted as an offset within the buffer object measured in basic
+// machine units.
+//
+// While a non-zero buffer object is bound to the GL.PIXEL_UNPACK_BUFFER
+// target, the following commands are affected: Bitmap, ColorSubTable,
+// ColorTable, CompressedTexImage1D, CompressedTexImage2D,
+// CompressedTexImage3D, CompressedTexSubImage1D, CompressedTexSubImage2D,
+// CompressedTexSubImage3D, ConvolutionFilter1D, ConvolutionFilter2D,
+// DrawPixels, PixelMap, PolygonStipple, SeparableFilter2D, TexImage1D,
+// TexImage2D, TexImage3D, TexSubImage1D, TexSubImage2D, and TexSubImage3D.
+// The pointer parameter that is traditionally interpreted as a pointer to
+// client-side memory from which the pixels are to be unpacked is instead
+// interpreted as an offset within the buffer object measured in basic
+// machine units.
+//
+// A buffer object binding created with BindBuffer remains active until a
+// different buffer object name is bound to the same target, or until the
+// bound buffer object is deleted with DeleteBuffers.
+//
+// Once created, a named buffer object may be re-bound to any target as often
+// as needed. However, the GL implementation may make choices about how to
+// optimize the storage of a buffer object based on its initial binding
+// target.
+//
+// Error GL.INVALID_ENUM is generated if target is not one of the allowable
+// values. GL.INVALID_OPERATION is generated if BindBuffer is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// BindBuffer is available in GL version 1.5 or greater.
+func (gl *GL) BindBuffer(target glbase.Enum, buffer glbase.Buffer) {
+ C.gl4_0core_glBindBuffer(gl.funcs, C.GLenum(target), C.GLuint(buffer))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetQueryObjectuiv.xml
+func (gl *GL) GetQueryObjectuiv(id uint32, pname glbase.Enum, params []uint32) {
+ C.gl4_0core_glGetQueryObjectuiv(gl.funcs, C.GLuint(id), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetQueryObjectiv.xml
+func (gl *GL) GetQueryObjectiv(id uint32, pname glbase.Enum, params []int32) {
+ C.gl4_0core_glGetQueryObjectiv(gl.funcs, C.GLuint(id), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetQueryiv.xml
+func (gl *GL) GetQueryiv(target, pname glbase.Enum, params []int32) {
+ C.gl4_0core_glGetQueryiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEndQuery.xml
+func (gl *GL) EndQuery(target glbase.Enum) {
+ C.gl4_0core_glEndQuery(gl.funcs, C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBeginQuery.xml
+func (gl *GL) BeginQuery(target glbase.Enum, id uint32) {
+ C.gl4_0core_glBeginQuery(gl.funcs, C.GLenum(target), C.GLuint(id))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsQuery.xml
+func (gl *GL) IsQuery(id uint32) bool {
+ glresult := C.gl4_0core_glIsQuery(gl.funcs, C.GLuint(id))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDeleteQueries.xml
+func (gl *GL) DeleteQueries(n int, ids []uint32) {
+ C.gl4_0core_glDeleteQueries(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&ids[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGenQueries.xml
+func (gl *GL) GenQueries(n int, ids []uint32) {
+ C.gl4_0core_glGenQueries(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&ids[0])))
+}
+
+// VertexAttribPointer specifies the location and data format of the array
+// of generic vertex attributes at index to use when rendering. size
+// specifies the number of components per attribute and must be 1, 2, 3, or
+// 4. type specifies the data type of each component, and stride specifies
+// the byte stride from one attribute to the next, allowing vertices and
+// attributes to be packed into a single array or stored in separate arrays.
+// normalized indicates whether the values stored in an integer format are
+// to be mapped to the range [-1,1] (for signed values) or [0,1]
+// (for unsigned values) when they are accessed and converted to floating
+// point; otherwise, values will be converted to floats directly without
+// normalization. offset is a byte offset into the buffer object's data
+// store, which must be bound to the GL.ARRAY_BUFFER target with BindBuffer.
+//
+// The buffer object binding (GL.ARRAY_BUFFER_BINDING) is saved as
+// generic vertex attribute array client-side state
+// (GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING) for the provided index.
+//
+// To enable and disable a generic vertex attribute array, call
+// EnableVertexAttribArray and DisableVertexAttribArray with index. If
+// enabled, the generic vertex attribute array is used when DrawArrays or
+// DrawElements is called. Each generic vertex attribute array is initially
+// disabled.
+//
+// VertexAttribPointer is typically implemented on the client side.
+//
+// Error GL.INVALID_ENUM is generated if type is not an accepted value.
+// GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_VALUE is generated if size is not 1, 2,
+// 3, or 4. GL.INVALID_VALUE is generated if stride is negative.
+func (gl *GL) VertexAttribPointer(index glbase.Attrib, size int, gltype glbase.Enum, normalized bool, stride int, offset uintptr) {
+ offset_ptr := unsafe.Pointer(offset)
+ C.gl4_0core_glVertexAttribPointer(gl.funcs, C.GLuint(index), C.GLint(size), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), C.GLsizei(stride), offset_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glValidateProgram.xml
+func (gl *GL) ValidateProgram(program glbase.Program) {
+ C.gl4_0core_glValidateProgram(gl.funcs, C.GLuint(program))
+}
+
+// UniformMatrix4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix4fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(4*4) != 0 {
+ panic("invalid value length for UniformMatrix4fv")
+ }
+ count := len(value) / (4 * 4)
+ C.gl4_0core_glUniformMatrix4fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix3fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(3*3) != 0 {
+ panic("invalid value length for UniformMatrix3fv")
+ }
+ count := len(value) / (3 * 3)
+ C.gl4_0core_glUniformMatrix3fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix2fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(2*2) != 0 {
+ panic("invalid value length for UniformMatrix2fv")
+ }
+ count := len(value) / (2 * 2)
+ C.gl4_0core_glUniformMatrix2fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform4iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%4 != 0 {
+ panic("invalid value length for Uniform4iv")
+ }
+ count := len(value) / 4
+ C.gl4_0core_glUniform4iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform3iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform3iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%3 != 0 {
+ panic("invalid value length for Uniform3iv")
+ }
+ count := len(value) / 3
+ C.gl4_0core_glUniform3iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform2iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform2iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%2 != 0 {
+ panic("invalid value length for Uniform2iv")
+ }
+ count := len(value) / 2
+ C.gl4_0core_glUniform2iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform1iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform1iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ count := len(value)
+ C.gl4_0core_glUniform1iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%4 != 0 {
+ panic("invalid value length for Uniform4fv")
+ }
+ count := len(value) / 4
+ C.gl4_0core_glUniform4fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%3 != 0 {
+ panic("invalid value length for Uniform3fv")
+ }
+ count := len(value) / 3
+ C.gl4_0core_glUniform3fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%2 != 0 {
+ panic("invalid value length for Uniform2fv")
+ }
+ count := len(value) / 2
+ C.gl4_0core_glUniform2fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform1fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform1fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ count := len(value)
+ C.gl4_0core_glUniform1fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform4i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4i(location glbase.Uniform, v0, v1, v2, v3 int32) {
+ C.gl4_0core_glUniform4i(gl.funcs, C.GLint(location), C.GLint(v0), C.GLint(v1), C.GLint(v2), C.GLint(v3))
+}
+
+// Uniform3i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform3i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3i(location glbase.Uniform, v0, v1, v2 int32) {
+ C.gl4_0core_glUniform3i(gl.funcs, C.GLint(location), C.GLint(v0), C.GLint(v1), C.GLint(v2))
+}
+
+// Uniform2i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform2i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2i(location glbase.Uniform, v0, v1 int32) {
+ C.gl4_0core_glUniform2i(gl.funcs, C.GLint(location), C.GLint(v0), C.GLint(v1))
+}
+
+// Uniform1i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform1i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1i(location glbase.Uniform, v0 int32) {
+ C.gl4_0core_glUniform1i(gl.funcs, C.GLint(location), C.GLint(v0))
+}
+
+// Uniform4f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform4f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4f(location glbase.Uniform, v0, v1, v2, v3 float32) {
+ C.gl4_0core_glUniform4f(gl.funcs, C.GLint(location), C.GLfloat(v0), C.GLfloat(v1), C.GLfloat(v2), C.GLfloat(v3))
+}
+
+// Uniform3f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform3f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3f(location glbase.Uniform, v0, v1, v2 float32) {
+ C.gl4_0core_glUniform3f(gl.funcs, C.GLint(location), C.GLfloat(v0), C.GLfloat(v1), C.GLfloat(v2))
+}
+
+// Uniform2f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform2f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2f(location glbase.Uniform, v0, v1 float32) {
+ C.gl4_0core_glUniform2f(gl.funcs, C.GLint(location), C.GLfloat(v0), C.GLfloat(v1))
+}
+
+// Uniform1f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform1f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1f(location glbase.Uniform, v0 float32) {
+ C.gl4_0core_glUniform1f(gl.funcs, C.GLint(location), C.GLfloat(v0))
+}
+
+// UseProgram installs the program object specified by program as part of
+// current rendering state. One or more executables are created in a program
+// object by successfully attaching shader objects to it with AttachShader,
+// successfully compiling the shader objects with CompileShader, and
+// successfully linking the program object with LinkProgram.
+//
+// A program object will contain an executable that will run on the vertex
+// processor if it contains one or more shader objects of type
+// GL.VERTEX_SHADER that have been successfully compiled and linked.
+// Similarly, a program object will contain an executable that will run on
+// the fragment processor if it contains one or more shader objects of type
+// GL.FRAGMENT_SHADER that have been successfully compiled and linked.
+//
+// Successfully installing an executable on a programmable processor will
+// cause the corresponding fixed functionality of OpenGL to be disabled.
+// Specifically, if an executable is installed on the vertex processor, the
+// OpenGL fixed functionality will be disabled as follows.
+//
+// - The modelview matrix is not applied to vertex coordinates.
+//
+// - The projection matrix is not applied to vertex coordinates.
+//
+// - The texture matrices are not applied to texture coordinates.
+//
+// - Normals are not transformed to eye coordinates.
+//
+// - Normals are not rescaled or normalized.
+//
+// - Normalization of GL.AUTO_NORMAL evaluated normals is not performed.
+//
+// - Texture coordinates are not generated automatically.
+//
+// - Per-vertex lighting is not performed.
+//
+// - Color material computations are not performed.
+//
+// - Color index lighting is not performed.
+//
+// - This list also applies when setting the current raster position.
+//
+// The executable that is installed on the vertex processor is expected to
+// implement any or all of the desired functionality from the preceding list.
+// Similarly, if an executable is installed on the fragment processor, the
+// OpenGL fixed functionality will be disabled as follows.
+//
+// - Texture environment and texture functions are not applied.
+//
+// - Texture application is not applied.
+//
+// - Color sum is not applied.
+//
+// - Fog is not applied.
+//
+// Again, the fragment shader that is installed is expected to implement any
+// or all of the desired functionality from the preceding list.
+//
+// While a program object is in use, applications are free to modify attached
+// shader objects, compile attached shader objects, attach additional shader
+// objects, and detach or delete shader objects. None of these operations
+// will affect the executables that are part of the current state. However,
+// relinking the program object that is currently in use will install the
+// program object as part of the current rendering state if the link
+// operation was successful (see LinkProgram). If the program object
+// currently in use is relinked unsuccessfully, its link status will be set
+// to GL.FALSE, but the executables and associated state will remain part of
+// the current state until a subsequent call to UseProgram removes it from
+// use. After it is removed from use, it cannot be made part of current state
+// until it has been successfully relinked.
+//
+// If program contains shader objects of type GL.VERTEX_SHADER but it does
+// not contain shader objects of type GL.FRAGMENT_SHADER, an executable will
+// be installed on the vertex processor, but fixed functionality will be used
+// for fragment processing. Similarly, if program contains shader objects of
+// type GL.FRAGMENT_SHADER but it does not contain shader objects of type
+// GL.VERTEX_SHADER, an executable will be installed on the fragment
+// processor, but fixed functionality will be used for vertex processing. If
+// program is 0, the programmable processors will be disabled, and fixed
+// functionality will be used for both vertex and fragment processing.
+//
+// While a program object is in use, the state that controls the disabled
+// fixed functionality may also be updated using the normal OpenGL calls.
+//
+// Like display lists and texture objects, the name space for program objects
+// may be shared across a set of contexts, as long as the server sides of the
+// contexts share the same address space. If the name space is shared across
+// contexts, any attached objects and the data associated with those attached
+// objects are shared as well.
+//
+// Applications are responsible for providing the synchronization across API
+// calls when objects are accessed from different execution threads.
+//
+// Error GL.INVALID_VALUE is generated if program is neither 0 nor a value
+// generated by OpenGL. GL.INVALID_OPERATION is generated if program is not
+// a program object. GL.INVALID_OPERATION is generated if program could not
+// be made part of current state. GL.INVALID_OPERATION is generated if
+// UseProgram is executed between the execution of Begin and the
+// corresponding execution of End.
+//
+// UseProgram is available in GL version 2.0 or greater.
+func (gl *GL) UseProgram(program glbase.Program) {
+ C.gl4_0core_glUseProgram(gl.funcs, C.GLuint(program))
+}
+
+// ShaderSource sets the source code in shader to the provided source code. Any source
+// code previously stored in the shader object is completely replaced.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader is not a shader
+// object. GL.INVALID_VALUE is generated if count is less than 0.
+// GL.INVALID_OPERATION is generated if ShaderSource is executed between the
+// execution of Begin and the corresponding execution of End.
+//
+// ShaderSource is available in GL version 2.0 or greater.
+func (gl *GL) ShaderSource(shader glbase.Shader, source ...string) {
+ count := len(source)
+ length := make([]int32, count)
+ source_c := make([]unsafe.Pointer, count)
+ for i, src := range source {
+ length[i] = int32(len(src))
+ if len(src) > 0 {
+ source_c[i] = *(*unsafe.Pointer)(unsafe.Pointer(&src))
+ } else {
+ source_c[i] = unsafe.Pointer(uintptr(0))
+ }
+ }
+ C.gl4_0core_glShaderSource(gl.funcs, C.GLuint(shader), C.GLsizei(count), (**C.GLchar)(unsafe.Pointer(&source_c[0])), (*C.GLint)(unsafe.Pointer(&length[0])))
+}
+
+// LinkProgram links the program object specified by program. If any shader
+// objects of type GL.VERTEX_SHADER are attached to program, they will be
+// used to create an executable that will run on the programmable vertex
+// processor. If any shader objects of type GL.FRAGMENT_SHADER are attached
+// to program, they will be used to create an executable that will run on the
+// programmable fragment processor.
+//
+// The status of the link operation will be stored as part of the program
+// object's state. This value will be set to GL.TRUE if the program object
+// was linked without errors and is ready for use, and GL.FALSE otherwise. It
+// can be queried by calling GetProgramiv with arguments program and
+// GL.LINK_STATUS.
+//
+// As a result of a successful link operation, all active user-defined
+// uniform variables belonging to program will be initialized to 0, and each
+// of the program object's active uniform variables will be assigned a
+// location that can be queried by calling GetUniformLocation. Also, any
+// active user-defined attribute variables that have not been bound to a
+// generic vertex attribute index will be bound to one at this time.
+//
+// Linking of a program object can fail for a number of reasons as specified
+// in the OpenGL Shading Language Specification. The following lists some of
+// the conditions that will cause a link error.
+//
+// - The number of active attribute variables supported by the
+// implementation has been exceeded.
+//
+// - The storage limit for uniform variables has been exceeded.
+//
+// - The number of active uniform variables supported by the implementation
+// has been exceeded.
+//
+// - The main function is missing for the vertex shader or the fragment
+// shader.
+//
+// - A varying variable actually used in the fragment shader is not
+// declared in the same way (or is not declared at all) in the vertex
+// shader.
+//
+// - A reference to a function or variable name is unresolved.
+//
+// - A shared global is declared with two different types or two different
+// initial values.
+//
+// - One or more of the attached shader objects has not been successfully
+// compiled.
+//
+// - Binding a generic attribute matrix caused some rows of the matrix to
+// fall outside the allowed maximum of GL.MAX_VERTEX_ATTRIBS.
+//
+// - Not enough contiguous vertex attribute slots could be found to bind
+// attribute matrices.
+//
+// When a program object has been successfully linked, the program object can
+// be made part of current state by calling UseProgram. Whether or not the
+// link operation was successful, the program object's information log will
+// be overwritten. The information log can be retrieved by calling
+// GetProgramInfoLog.
+//
+// LinkProgram will also install the generated executables as part of the
+// current rendering state if the link operation was successful and the
+// specified program object is already currently in use as a result of a
+// previous call to UseProgram. If the program object currently in use is
+// relinked unsuccessfully, its link status will be set to GL.FALSE , but the
+// executables and associated state will remain part of the current state
+// until a subsequent call to UseProgram removes it from use. After it is
+// removed from use, it cannot be made part of current state until it has
+// been successfully relinked.
+//
+// If program contains shader objects of type GL.VERTEX_SHADER but does not
+// contain shader objects of type GL.FRAGMENT_SHADER, the vertex shader will
+// be linked against the implicit interface for fixed functionality fragment
+// processing. Similarly, if program contains shader objects of type
+// GL.FRAGMENT_SHADER but it does not contain shader objects of type
+// GL.VERTEX_SHADER, the fragment shader will be linked against the implicit
+// interface for fixed functionality vertex processing.
+//
+// The program object's information log is updated and the program is
+// generated at the time of the link operation. After the link operation,
+// applications are free to modify attached shader objects, compile attached
+// shader objects, detach shader objects, delete shader objects, and attach
+// additional shader objects. None of these operations affects the
+// information log or the program that is part of the program object.
+//
+// If the link operation is unsuccessful, any information about a previous
+// link operation on program is lost (a failed link does not restore the
+// old state of program). Certain information can still be retrieved
+// from program even after an unsuccessful link operation. See for instance
+// GetActiveAttrib and GetActiveUniform.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program
+// object. GL.INVALID_OPERATION is generated if LinkProgram is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// LinkProgram is available in GL version 2.0 or greater.
+func (gl *GL) LinkProgram(program glbase.Program) {
+ C.gl4_0core_glLinkProgram(gl.funcs, C.GLuint(program))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsShader.xml
+func (gl *GL) IsShader(shader glbase.Shader) bool {
+ glresult := C.gl4_0core_glIsShader(gl.funcs, C.GLuint(shader))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsProgram.xml
+func (gl *GL) IsProgram(program glbase.Program) bool {
+ glresult := C.gl4_0core_glIsProgram(gl.funcs, C.GLuint(program))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// GetVertexAttribiv returns in params the value of a generic vertex attribute
+// parameter. The generic vertex attribute to be queried is specified by
+// index, and the parameter to be queried is specified by pname.
+//
+// The accepted parameter names are as follows:
+//
+// GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING
+// params returns a single value, the name of the buffer object
+// currently bound to the binding point corresponding to generic vertex
+// attribute array index. If no buffer object is bound, 0 is returned.
+// The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_ENABLED
+// params returns a single value that is non-zero (true) if the vertex
+// attribute array for index is enabled and 0 (false) if it is
+// disabled. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_SIZE
+// params returns a single value, the size of the vertex attribute
+// array for index. The size is the number of values for each element
+// of the vertex attribute array, and it will be 1, 2, 3, or 4. The
+// initial value is 4.
+//
+// GL.VERTEX_ATTRIB_ARRAY_STRIDE
+// params returns a single value, the array stride for (number of bytes
+// between successive elements in) the vertex attribute array for
+// index. A value of 0 indicates that the array elements are stored
+// sequentially in memory. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_TYPE
+// params returns a single value, a symbolic constant indicating the
+// array type for the vertex attribute array for index. Possible values
+// are GL.BYTE, GL.UNSIGNED_BYTE, GL.SHORT, GL.UNSIGNED_SHORT, GL.INT,
+// GL.UNSIGNED_INT, GL.FLOAT, and GL.DOUBLE. The initial value is
+// GL.FLOAT.
+//
+// GL.VERTEX_ATTRIB_ARRAY_NORMALIZED
+// params returns a single value that is non-zero (true) if fixed-point
+// data types for the vertex attribute array indicated by index are
+// normalized when they are converted to floating point, and 0 (false)
+// otherwise. The initial value is 0.
+//
+// GL.CURRENT_VERTEX_ATTRIB
+// params returns four values that represent the current value for the
+// generic vertex attribute specified by index. Generic vertex
+// attribute 0 is unique in that it has no current state, so an error
+// will be generated if index is 0. The initial value for all other
+// generic vertex attributes is (0,0,0,1).
+//
+// All of the parameters except GL.CURRENT_VERTEX_ATTRIB represent
+// client-side state.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_ENUM is generated if pname is not an
+// accepted value. GL.INVALID_OPERATION is generated if index is 0 and pname
+// is GL.CURRENT_VERTEX_ATTRIB.
+//
+// GetVertexAttribiv is available in GL version 2.0 or greater.
+func (gl *GL) GetVertexAttribiv(index glbase.Attrib, pname glbase.Enum, params []int32) {
+ var params_c [4]int32
+ C.gl4_0core_glGetVertexAttribiv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetVertexAttribfv returns in params the value of a generic vertex attribute
+// parameter. The generic vertex attribute to be queried is specified by
+// index, and the parameter to be queried is specified by pname.
+//
+// The accepted parameter names are as follows:
+//
+// GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING
+// params returns a single value, the name of the buffer object
+// currently bound to the binding point corresponding to generic vertex
+// attribute array index. If no buffer object is bound, 0 is returned.
+// The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_ENABLED
+// params returns a single value that is non-zero (true) if the vertex
+// attribute array for index is enabled and 0 (false) if it is
+// disabled. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_SIZE
+// params returns a single value, the size of the vertex attribute
+// array for index. The size is the number of values for each element
+// of the vertex attribute array, and it will be 1, 2, 3, or 4. The
+// initial value is 4.
+//
+// GL.VERTEX_ATTRIB_ARRAY_STRIDE
+// params returns a single value, the array stride for (number of bytes
+// between successive elements in) the vertex attribute array for
+// index. A value of 0 indicates that the array elements are stored
+// sequentially in memory. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_TYPE
+// params returns a single value, a symbolic constant indicating the
+// array type for the vertex attribute array for index. Possible values
+// are GL.BYTE, GL.UNSIGNED_BYTE, GL.SHORT, GL.UNSIGNED_SHORT, GL.INT,
+// GL.UNSIGNED_INT, GL.FLOAT, and GL.DOUBLE. The initial value is
+// GL.FLOAT.
+//
+// GL.VERTEX_ATTRIB_ARRAY_NORMALIZED
+// params returns a single value that is non-zero (true) if fixed-point
+// data types for the vertex attribute array indicated by index are
+// normalized when they are converted to floating point, and 0 (false)
+// otherwise. The initial value is 0.
+//
+// GL.CURRENT_VERTEX_ATTRIB
+// params returns four values that represent the current value for the
+// generic vertex attribute specified by index. Generic vertex
+// attribute 0 is unique in that it has no current state, so an error
+// will be generated if index is 0. The initial value for all other
+// generic vertex attributes is (0,0,0,1).
+//
+// All of the parameters except GL.CURRENT_VERTEX_ATTRIB represent
+// client-side state.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_ENUM is generated if pname is not an
+// accepted value. GL.INVALID_OPERATION is generated if index is 0 and pname
+// is GL.CURRENT_VERTEX_ATTRIB.
+//
+// GetVertexAttribfv is available in GL version 2.0 or greater.
+func (gl *GL) GetVertexAttribfv(index glbase.Attrib, pname glbase.Enum, params []float32) {
+ var params_c [4]float32
+ C.gl4_0core_glGetVertexAttribfv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetVertexAttribdv returns in params the value of a generic vertex attribute
+// parameter. The generic vertex attribute to be queried is specified by
+// index, and the parameter to be queried is specified by pname.
+//
+// The accepted parameter names are as follows:
+//
+// GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING
+// params returns a single value, the name of the buffer object
+// currently bound to the binding point corresponding to generic vertex
+// attribute array index. If no buffer object is bound, 0 is returned.
+// The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_ENABLED
+// params returns a single value that is non-zero (true) if the vertex
+// attribute array for index is enabled and 0 (false) if it is
+// disabled. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_SIZE
+// params returns a single value, the size of the vertex attribute
+// array for index. The size is the number of values for each element
+// of the vertex attribute array, and it will be 1, 2, 3, or 4. The
+// initial value is 4.
+//
+// GL.VERTEX_ATTRIB_ARRAY_STRIDE
+// params returns a single value, the array stride for (number of bytes
+// between successive elements in) the vertex attribute array for
+// index. A value of 0 indicates that the array elements are stored
+// sequentially in memory. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_TYPE
+// params returns a single value, a symbolic constant indicating the
+// array type for the vertex attribute array for index. Possible values
+// are GL.BYTE, GL.UNSIGNED_BYTE, GL.SHORT, GL.UNSIGNED_SHORT, GL.INT,
+// GL.UNSIGNED_INT, GL.FLOAT, and GL.DOUBLE. The initial value is
+// GL.FLOAT.
+//
+// GL.VERTEX_ATTRIB_ARRAY_NORMALIZED
+// params returns a single value that is non-zero (true) if fixed-point
+// data types for the vertex attribute array indicated by index are
+// normalized when they are converted to floating point, and 0 (false)
+// otherwise. The initial value is 0.
+//
+// GL.CURRENT_VERTEX_ATTRIB
+// params returns four values that represent the current value for the
+// generic vertex attribute specified by index. Generic vertex
+// attribute 0 is unique in that it has no current state, so an error
+// will be generated if index is 0. The initial value for all other
+// generic vertex attributes is (0,0,0,1).
+//
+// All of the parameters except GL.CURRENT_VERTEX_ATTRIB represent
+// client-side state.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_ENUM is generated if pname is not an
+// accepted value. GL.INVALID_OPERATION is generated if index is 0 and pname
+// is GL.CURRENT_VERTEX_ATTRIB.
+//
+// GetVertexAttribdv is available in GL version 2.0 or greater.
+func (gl *GL) GetVertexAttribdv(index glbase.Attrib, pname glbase.Enum, params []float64) {
+ var params_c [4]float64
+ C.gl4_0core_glGetVertexAttribdv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetUniformiv returns in params the value of the specified uniform
+// variable. The type of the uniform variable specified by location
+// determines the number of values returned. If the uniform variable is
+// defined in the shader as a boolean, int, or float, a single value will be
+// returned. If it is defined as a vec2, ivec2, or bvec2, two values will be
+// returned. If it is defined as a vec3, ivec3, or bvec3, three values will
+// be returned, and so on. To query values stored in uniform variables
+// declared as arrays, call GetUniformiv for each element of the array. To
+// query values stored in uniform variables declared as structures, call
+// GetUniformiv for each field in the structure. The values for uniform
+// variables declared as a matrix will be returned in column major order.
+//
+// The locations assigned to uniform variables are not known until the
+// program object is linked. After linking has occurred, the command
+// GetUniformLocation can be used to obtain the location of a uniform
+// variable. This location value can then be passed to GetUniformiv in order
+// to query the current value of the uniform variable. After a program object
+// has been linked successfully, the index values for uniform variables
+// remain fixed until the next link command occurs. The uniform variable
+// values can only be queried after a link if the link was successful.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program
+// object. GL.INVALID_OPERATION is generated if program has not been
+// successfully linked. GL.INVALID_OPERATION is generated if location does
+// not correspond to a valid uniform variable location for the specified
+// program object. GL.INVALID_OPERATION is generated if GetUniformiv is
+// executed between the execution of Begin and the corresponding execution of
+// End.
+//
+// GetUniformiv is available in GL version 2.0 or greater.
+func (gl *GL) GetUniformiv(program glbase.Program, location glbase.Uniform, params []int32) {
+ var params_c [4]int32
+ C.gl4_0core_glGetUniformiv(gl.funcs, C.GLuint(program), C.GLint(location), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetUniformfv returns in params the value of the specified uniform
+// variable. The type of the uniform variable specified by location
+// determines the number of values returned. If the uniform variable is
+// defined in the shader as a boolean, int, or float, a single value will be
+// returned. If it is defined as a vec2, ivec2, or bvec2, two values will be
+// returned. If it is defined as a vec3, ivec3, or bvec3, three values will
+// be returned, and so on. To query values stored in uniform variables
+// declared as arrays, call GetUniformfv for each element of the array. To
+// query values stored in uniform variables declared as structures, call
+// GetUniformfv for each field in the structure. The values for uniform
+// variables declared as a matrix will be returned in column major order.
+//
+// The locations assigned to uniform variables are not known until the
+// program object is linked. After linking has occurred, the command
+// GetUniformLocation can be used to obtain the location of a uniform
+// variable. This location value can then be passed to GetUniformfv in order
+// to query the current value of the uniform variable. After a program object
+// has been linked successfully, the index values for uniform variables
+// remain fixed until the next link command occurs. The uniform variable
+// values can only be queried after a link if the link was successful.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program
+// object. GL.INVALID_OPERATION is generated if program has not been
+// successfully linked. GL.INVALID_OPERATION is generated if location does
+// not correspond to a valid uniform variable location for the specified
+// program object. GL.INVALID_OPERATION is generated if GetUniformfv is
+// executed between the execution of Begin and the corresponding execution of
+// End.
+//
+// GetUniformfv is available in GL version 2.0 or greater.
+func (gl *GL) GetUniformfv(program glbase.Program, location glbase.Uniform, params []float32) {
+ var params_c [4]float32
+ C.gl4_0core_glGetUniformfv(gl.funcs, C.GLuint(program), C.GLint(location), (*C.GLfloat)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetUniformLocation returns an integer that represents the location of a
+// specific uniform variable within a program object. name must be an active
+// uniform variable name in program that is not a structure, an array of
+// structures, or a subcomponent of a vector or a matrix. This function
+// returns -1 if name does not correspond to an active uniform variable in
+// program or if name starts with the reserved prefix "gl_".
+//
+// Uniform variables that are structures or arrays of structures may be
+// queried by calling GetUniformLocation for each field within the
+// structure. The array element operator "[]" and the structure field
+// operator "." may be used in name in order to select elements within an
+// array or fields within a structure. The result of using these operators is
+// not allowed to be another structure, an array of structures, or a
+// subcomponent of a vector or a matrix. Except if the last part of name
+// indicates a uniform variable array, the location of the first element of
+// an array can be retrieved by using the name of the array, or by using the
+// name appended by "[0]".
+//
+// The actual locations assigned to uniform variables are not known until the
+// program object is linked successfully. After linking has occurred, the
+// command GetUniformLocation can be used to obtain the location of a
+// uniform variable. This location value can then be passed to Uniform to
+// set the value of the uniform variable or to GetUniform in order to query
+// the current value of the uniform variable. After a program object has been
+// linked successfully, the index values for uniform variables remain fixed
+// until the next link command occurs. Uniform variable locations and values
+// can only be queried after a link if the link was successful.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program object.
+// GL.INVALID_OPERATION is generated if program has not been successfully
+// linked. GL.INVALID_OPERATION is generated if GetUniformLocation is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// GetUniformLocation is available in GL version 2.0 or greater.
+func (gl *GL) GetUniformLocation(program glbase.Program, name string) glbase.Uniform {
+ name_cstr := C.CString(name)
+ glresult := C.gl4_0core_glGetUniformLocation(gl.funcs, C.GLuint(program), (*C.GLchar)(name_cstr))
+ C.free(unsafe.Pointer(name_cstr))
+ return glbase.Uniform(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetShaderSource.xml
+func (gl *GL) GetShaderSource(shader glbase.Shader, bufSize int32, length []int32, source []byte) {
+ C.gl4_0core_glGetShaderSource(gl.funcs, C.GLuint(shader), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&source[0])))
+}
+
+// GetShaderInfoLog returns the information log for the specified shader
+// object. The information log for a shader object is modified when the
+// shader is compiled.
+//
+// The information log for a shader object is a string that may contain
+// diagnostic messages, warning messages, and other information about the
+// last compile operation. When a shader object is created, its information
+// log will be a string of length 0, and the size of the current log can be
+// obtained by calling GetShaderiv with the value GL.INFO_LOG_LENGTH.
+//
+// The information log for a shader object is the OpenGL implementer's
+// primary mechanism for conveying information about the compilation process.
+// Therefore, the information log can be helpful to application developers
+// during the development process, even when compilation is successful.
+// Application developers should not expect different OpenGL implementations
+// to produce identical information logs.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader is not a shader
+// object. GL.INVALID_VALUE is generated if maxLength is less than 0.
+// GL.INVALID_OPERATION is generated if GetShaderInfoLog is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// GetShaderInfoLog is available in GL version 2.0 or greater.
+func (gl *GL) GetShaderInfoLog(shader glbase.Shader) []byte {
+ var params [1]int32
+ var length int32
+ gl.GetShaderiv(shader, INFO_LOG_LENGTH, params[:])
+ bufSize := params[0]
+ infoLog := make([]byte, int(bufSize))
+ C.gl4_0core_glGetShaderInfoLog(gl.funcs, C.GLuint(shader), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length)), (*C.GLchar)(unsafe.Pointer(&infoLog[0])))
+ return infoLog
+}
+
+// GetShaderiv GetShader returns in params the value of a parameter for a specific
+// shader object. The following parameters are defined:
+//
+// GL.SHADER_TYPE
+// params returns GL.VERTEX_SHADER if shader is a vertex shader object,
+// and GL.FRAGMENT_SHADER if shader is a fragment shader object.
+//
+// GL.DELETE_STATUS
+// params returns GL.TRUE if shader is currently flagged for deletion,
+// and GL.FALSE otherwise.
+//
+// GL.COMPILE_STATUS
+// params returns GL.TRUE if the last compile operation on shader was
+// successful, and GL.FALSE otherwise.
+//
+// GL.INFO_LOG_LENGTH
+// params returns the number of characters in the information log for
+// shader including the null termination character (the size of the
+// character buffer required to store the information log). If shader has
+// no information log, a value of 0 is returned.
+//
+// GL.SHADER_SOURCE_LENGTH
+// params returns the length of the concatenation of the source strings
+// that make up the shader source for the shader, including the null
+// termination character. (the size of the character buffer
+// required to store the shader source). If no source code exists, 0 is
+// returned.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader does not refer to a
+// shader object. GL.INVALID_ENUM is generated if pname is not an accepted
+// value. GL.INVALID_OPERATION is generated if GetShader is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// GetShaderiv is available in GL version 2.0 or greater.
+func (gl *GL) GetShaderiv(shader glbase.Shader, pname glbase.Enum, params []int32) {
+ var params_c [4]int32
+ C.gl4_0core_glGetShaderiv(gl.funcs, C.GLuint(shader), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetProgramInfoLog returns the information log for the specified program
+// object. The information log for a program object is modified when the
+// program object is linked or validated.
+//
+// The information log for a program object is either an empty string, or a
+// string containing information about the last link operation, or a string
+// containing information about the last validation operation. It may contain
+// diagnostic messages, warning messages, and other information. When a
+// program object is created, its information log will be a string of length
+// 0, and the size of the current log can be obtained by calling GetProgramiv
+// with the value GL.INFO_LOG_LENGTH.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated
+// by OpenGL. GL.INVALID_OPERATION is generated if program is not a
+// program object.
+func (gl *GL) GetProgramInfoLog(program glbase.Program) []byte {
+ var params [1]int32
+ var length int32
+ gl.GetProgramiv(program, INFO_LOG_LENGTH, params[:])
+ bufSize := params[0]
+ infoLog := make([]byte, int(bufSize))
+ C.gl4_0core_glGetProgramInfoLog(gl.funcs, C.GLuint(program), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length)), (*C.GLchar)(unsafe.Pointer(&infoLog[0])))
+ return infoLog
+}
+
+// GetProgramiv returns in params the value of a parameter for a specific
+// program object. The following parameters are defined:
+//
+// GL.DELETE_STATUS
+// params returns GL.TRUE if program is currently flagged for deletion,
+// and GL.FALSE otherwise.
+//
+// GL.LINK_STATUS
+// params returns GL.TRUE if the last link operation on program was
+// successful, and GL.FALSE otherwise.
+//
+// GL.VALIDATE_STATUS
+// params returns GL.TRUE or if the last validation operation on
+// program was successful, and GL.FALSE otherwise.
+//
+// GL.INFO_LOG_LENGTH
+// params returns the number of characters in the information log for
+// program including the null termination character (the size of
+// the character buffer required to store the information log). If
+// program has no information log, a value of 0 is returned.
+//
+// GL.ATTACHED_SHADERS
+// params returns the number of shader objects attached to program.
+//
+// GL.ACTIVE_ATTRIBUTES
+// params returns the number of active attribute variables for program.
+//
+// GL.ACTIVE_ATTRIBUTE_MAX_LENGTH
+// params returns the length of the longest active attribute name for
+// program, including the null termination character (the size of
+// the character buffer required to store the longest attribute name).
+// If no active attributes exist, 0 is returned.
+//
+// GL.ACTIVE_UNIFORMS
+// params returns the number of active uniform variables for program.
+//
+// GL.ACTIVE_UNIFORM_MAX_LENGTH
+// params returns the length of the longest active uniform variable
+// name for program, including the null termination character (i.e.,
+// the size of the character buffer required to store the longest
+// uniform variable name). If no active uniform variables exist, 0 is
+// returned.
+//
+// GL.TRANSFORM_FEEDBACK_BUFFER_MODE
+// params returns a symbolic constant indicating the buffer mode used
+// when transform feedback is active. This may be GL.SEPARATE_ATTRIBS
+// or GL.INTERLEAVED_ATTRIBS.
+//
+// GL.TRANSFORM_FEEDBACK_VARYINGS
+// params returns the number of varying variables to capture in transform
+// feedback mode for the program.
+//
+// GL.TRANSFORM_FEEDBACK_VARYING_MAX_LENGTH
+// params returns the length of the longest variable name to be used for
+// transform feedback, including the null-terminator.
+//
+// GL.GEOMETRY_VERTICES_OUT
+// params returns the maximum number of vertices that the geometry shader in
+// program will output.
+//
+// GL.GEOMETRY_INPUT_TYPE
+// params returns a symbolic constant indicating the primitive type accepted
+// as input to the geometry shader contained in program.
+//
+// GL.GEOMETRY_OUTPUT_TYPE
+// params returns a symbolic constant indicating the primitive type that will
+// be output by the geometry shader contained in program.
+//
+// GL.ACTIVE_UNIFORM_BLOCKS and GL.ACTIVE_UNIFORM_BLOCK_MAX_NAME_LENGTH are
+// available only if the GL version 3.1 or greater.
+//
+// GL.GEOMETRY_VERTICES_OUT, GL.GEOMETRY_INPUT_TYPE and
+// GL.GEOMETRY_OUTPUT_TYPE are accepted only if the GL version is 3.2 or
+// greater.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program does not refer to a
+// program object. GL.INVALID_OPERATION is generated if pname is
+// GL.GEOMETRY_VERTICES_OUT, GL.GEOMETRY_INPUT_TYPE, or
+// GL.GEOMETRY_OUTPUT_TYPE, and program does not contain a geometry shader.
+// GL.INVALID_ENUM is generated if pname is not an accepted value.
+func (gl *GL) GetProgramiv(program glbase.Program, pname glbase.Enum, params []int32) {
+ var params_c [4]int32
+ C.gl4_0core_glGetProgramiv(gl.funcs, C.GLuint(program), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetAttribLocation queries the previously linked program object specified
+// by program for the attribute variable specified by name and returns the
+// index of the generic vertex attribute that is bound to that attribute
+// variable. If name is a matrix attribute variable, the index of the first
+// column of the matrix is returned. If the named attribute variable is not
+// an active attribute in the specified program object or if name starts with
+// the reserved prefix "gl_", a value of -1 is returned.
+//
+// The association between an attribute variable name and a generic attribute
+// index can be specified at any time by calling BindAttribLocation.
+// Attribute bindings do not go into effect until LinkProgram is called.
+// After a program object has been linked successfully, the index values for
+// attribute variables remain fixed until the next link command occurs. The
+// attribute values can only be queried after a link if the link was
+// successful. GetAttribLocation returns the binding that actually went
+// into effect the last time LinkProgram was called for the specified
+// program object. Attribute bindings that have been specified since the last
+// link operation are not returned by GetAttribLocation.
+//
+// Error GL_INVALID_OPERATION is generated if program is not a value
+// generated by OpenGL. GL_INVALID_OPERATION is generated if program is not
+// a program object. GL_INVALID_OPERATION is generated if program has not
+// been successfully linked. GL_INVALID_OPERATION is generated if
+// GetAttribLocation is executed between the execution of Begin and the
+// corresponding execution of End.
+//
+// GetAttribLocation is available in GL version 2.0 or greater.
+func (gl *GL) GetAttribLocation(program glbase.Program, name string) glbase.Attrib {
+ name_cstr := C.CString(name)
+ glresult := C.gl4_0core_glGetAttribLocation(gl.funcs, C.GLuint(program), (*C.GLchar)(name_cstr))
+ C.free(unsafe.Pointer(name_cstr))
+ return glbase.Attrib(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetAttachedShaders.xml
+func (gl *GL) GetAttachedShaders(program glbase.Program, maxCount int32, count []int, obj []uint32) {
+ C.gl4_0core_glGetAttachedShaders(gl.funcs, C.GLuint(program), C.GLsizei(maxCount), (*C.GLsizei)(unsafe.Pointer(&count[0])), (*C.GLuint)(unsafe.Pointer(&obj[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveUniform.xml
+func (gl *GL) GetActiveUniform(program glbase.Program, index uint32, bufSize int32, length []int32, size []int, gltype []glbase.Enum, name []byte) {
+ C.gl4_0core_glGetActiveUniform(gl.funcs, C.GLuint(program), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLint)(unsafe.Pointer(&size[0])), (*C.GLenum)(unsafe.Pointer(&gltype[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveAttrib.xml
+func (gl *GL) GetActiveAttrib(program glbase.Program, index glbase.Attrib, bufSize int32, length []int32, size []int, gltype []glbase.Enum, name []byte) {
+ C.gl4_0core_glGetActiveAttrib(gl.funcs, C.GLuint(program), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLint)(unsafe.Pointer(&size[0])), (*C.GLenum)(unsafe.Pointer(&gltype[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEnableVertexAttribArray.xml
+func (gl *GL) EnableVertexAttribArray(index glbase.Attrib) {
+ C.gl4_0core_glEnableVertexAttribArray(gl.funcs, C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDisableVertexAttribArray.xml
+func (gl *GL) DisableVertexAttribArray(index glbase.Attrib) {
+ C.gl4_0core_glDisableVertexAttribArray(gl.funcs, C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDetachShader.xml
+func (gl *GL) DetachShader(program glbase.Program, shader glbase.Shader) {
+ C.gl4_0core_glDetachShader(gl.funcs, C.GLuint(program), C.GLuint(shader))
+}
+
+// DeleteShader frees the memory and invalidates the name associated with
+// the shader object specified by shader. This command effectively undoes the
+// effects of a call to CreateShader.
+//
+// If a shader object to be deleted is attached to a program object, it will
+// be flagged for deletion, but it will not be deleted until it is no longer
+// attached to any program object, for any rendering context (it must
+// be detached from wherever it was attached before it will be deleted). A
+// value of 0 for shader will be silently ignored.
+//
+// To determine whether an object has been flagged for deletion, call
+// GetShader with arguments shader and GL.DELETE_STATUS.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL.
+//
+// DeleteShader is available in GL version 2.0 or greater.
+func (gl *GL) DeleteShader(shader glbase.Shader) {
+ C.gl4_0core_glDeleteShader(gl.funcs, C.GLuint(shader))
+}
+
+// DeleteProgram frees the memory and invalidates the name associated with
+// the program object specified by program. This command effectively undoes
+// the effects of a call to CreateProgram.
+//
+// If a program object is in use as part of current rendering state, it will
+// be flagged for deletion, but it will not be deleted until it is no longer
+// part of current state for any rendering context. If a program object to be
+// deleted has shader objects attached to it, those shader objects will be
+// automatically detached but not deleted unless they have already been
+// flagged for deletion by a previous call to DeleteShader. A value of 0
+// for program will be silently ignored.
+//
+// To determine whether a program object has been flagged for deletion, call
+// GetProgram with arguments program and GL.DELETE_STATUS.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL.
+//
+// DeleteProgram is available in GL version 2.0 or greater.
+func (gl *GL) DeleteProgram(program glbase.Program) {
+ C.gl4_0core_glDeleteProgram(gl.funcs, C.GLuint(program))
+}
+
+// CreateShader creates an empty shader object and returns a non-zero value
+// by which it can be referenced. A shader object is used to maintain the
+// source code strings that define a shader. shaderType indicates the type of
+// shader to be created.
+//
+// Two types of shaders are supported. A shader of type GL.VERTEX_SHADER is a
+// shader that is intended to run on the programmable vertex processor and
+// replace the fixed functionality vertex processing in OpenGL. A shader of
+// type GL.FRAGMENT_SHADER is a shader that is intended to run on the
+// programmable fragment processor and replace the fixed functionality
+// fragment processing in OpenGL.
+//
+// When created, a shader object's GL.SHADER_TYPE parameter is set to either
+// GL.VERTEX_SHADER or GL.FRAGMENT_SHADER, depending on the value of
+// shaderType.
+//
+// Like display lists and texture objects, the name space for shader objects
+// may be shared across a set of contexts, as long as the server sides of the
+// contexts share the same address space. If the name space is shared across
+// contexts, any attached objects and the data associated with those attached
+// objects are shared as well.
+//
+// This function returns 0 if an error occurs creating the shader object.
+//
+// Error GL.INVALID_ENUM is generated if shaderType is not an accepted value.
+// GL.INVALID_OPERATION is generated if CreateShader is executed between the
+// execution of Begin and the corresponding execution of End.
+//
+// CreateShader is available in GL version 2.0 or greater.
+func (gl *GL) CreateShader(gltype glbase.Enum) glbase.Shader {
+ glresult := C.gl4_0core_glCreateShader(gl.funcs, C.GLenum(gltype))
+ return glbase.Shader(glresult)
+}
+
+// CreateProgram creates an empty program object and returns a non-zero
+// value by which it can be referenced. A program object is an object to
+// which shader objects can be attached. This provides a mechanism to specify
+// the shader objects that will be linked to create a program. It also
+// provides a means for checking the compatibility of the shaders that will
+// be used to create a program (for instance, checking the compatibility
+// between a vertex shader and a fragment shader). When no longer needed as
+// part of a program object, shader objects can be detached.
+//
+// One or more executables are created in a program object by successfully
+// attaching shader objects to it with AttachShader, successfully compiling
+// the shader objects with CompileShader, and successfully linking the
+// program object with LinkProgram. These executables are made part of
+// current state when UseProgram is called. Program objects can be deleted
+// by calling DeleteProgram. The memory associated with the program object
+// will be deleted when it is no longer part of current rendering state for
+// any context.
+//
+// Like display lists and texture objects, the name space for program objects
+// may be shared across a set of contexts, as long as the server sides of the
+// contexts share the same address space. If the name space is shared across
+// contexts, any attached objects and the data associated with those attached
+// objects are shared as well.
+//
+// Applications are responsible for providing the synchronization across API
+// calls when objects are accessed from different execution threads.
+//
+// This function returns 0 if an error occurs creating the program object.
+//
+// Error GL.INVALID_OPERATION is generated if CreateProgram is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// CreateProgram is available in GL version 2.0 or greater.
+func (gl *GL) CreateProgram() glbase.Program {
+ glresult := C.gl4_0core_glCreateProgram(gl.funcs)
+ return glbase.Program(glresult)
+}
+
+// CompileShader compiles the source code strings that have been stored in
+// the shader object specified by shader.
+//
+// The compilation status will be stored as part of the shader object's
+// state. This value will be set to GL.TRUE if the shader was compiled without
+// errors and is ready for use, and GL.FALSE otherwise. It can be queried by
+// calling GetShaderiv with arguments shader and GL.COMPILE_STATUS.
+//
+// Compilation of a shader can fail for a number of reasons as specified by
+// the OpenGL Shading Language Specification. Whether or not the compilation
+// was successful, information about the compilation can be obtained from the
+// shader object's information log by calling GetShaderInfoLog.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader is not a shader
+// object. GL.INVALID_OPERATION is generated if CompileShader is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// CompileShader is available in GL version 2.0 or greater.
+func (gl *GL) CompileShader(shader glbase.Shader) {
+ C.gl4_0core_glCompileShader(gl.funcs, C.GLuint(shader))
+}
+
+// BindAttribLocation associates a user-defined attribute variable in the program
+// object specified by program with a generic vertex attribute index. The name
+// parameter specifies the name of the vertex shader attribute variable to
+// which index is to be bound. When program is made part of the current state,
+// values provided via the generic vertex attribute index will modify the
+// value of the user-defined attribute variable specified by name.
+//
+// If name refers to a matrix attribute variable, index refers to the first
+// column of the matrix. Other matrix columns are then automatically bound to
+// locations index+1 for a matrix of type mat2; index+1 and index+2 for a
+// matrix of type mat3; and index+1, index+2, and index+3 for a matrix of
+// type mat4.
+//
+// This command makes it possible for vertex shaders to use descriptive names
+// for attribute variables rather than generic variables that are numbered
+// from 0 to GL.MAX_VERTEX_ATTRIBS-1. The values sent to each generic
+// attribute index are part of current state, just like standard vertex
+// attributes such as color, normal, and vertex position. If a different
+// program object is made current by calling UseProgram, the generic vertex
+// attributes are tracked in such a way that the same values will be observed
+// by attributes in the new program object that are also bound to index.
+//
+// Attribute variable name-to-generic attribute index bindings for a program
+// object can be explicitly assigned at any time by calling
+// BindAttribLocation. Attribute bindings do not go into effect until
+// LinkProgram is called. After a program object has been linked
+// successfully, the index values for generic attributes remain fixed (and
+// their values can be queried) until the next link command occurs.
+//
+// Applications are not allowed to bind any of the standard OpenGL vertex
+// attributes using this command, as they are bound automatically when
+// needed. Any attribute binding that occurs after the program object has
+// been linked will not take effect until the next time the program object is
+// linked.
+//
+// If name was bound previously, that information is lost. Thus you cannot
+// bind one user-defined attribute variable to multiple indices, but you can
+// bind multiple user-defined attribute variables to the same index.
+//
+// Applications are allowed to bind more than one user-defined attribute
+// variable to the same generic vertex attribute index. This is called
+// aliasing, and it is allowed only if just one of the aliased attributes is
+// active in the executable program, or if no path through the shader
+// consumes more than one attribute of a set of attributes aliased to the
+// same location. The compiler and linker are allowed to assume that no
+// aliasing is done and are free to employ optimizations that work only in
+// the absence of aliasing. OpenGL implementations are not required to do
+// error checking to detect aliasing. Because there is no way to bind
+// standard attributes, it is not possible to alias generic attributes with
+// conventional ones (except for generic attribute 0).
+//
+// BindAttribLocation can be called before any vertex shader objects are
+// bound to the specified program object. It is also permissible to bind a
+// generic attribute index to an attribute variable name that is never used
+// in a vertex shader.
+//
+// Active attributes that are not explicitly bound will be bound by the
+// linker when LinkProgram is called. The locations assigned can be queried
+// by calling GetAttribLocation.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS.
+// GL.INVALID_OPERATION is generated if name starts with the reserved prefix "gl_".
+// GL.INVALID_VALUE is generated if program is not a value generated by OpenGL.
+// GL.INVALID_OPERATION is generated if program is not a program object.
+// GL.INVALID_OPERATION is generated if BindAttribLocation is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// BindAttribLocation is available in GL version 2.0 or greater.
+func (gl *GL) BindAttribLocation(program glbase.Program, index glbase.Attrib, name string) {
+ name_cstr := C.CString(name)
+ C.gl4_0core_glBindAttribLocation(gl.funcs, C.GLuint(program), C.GLuint(index), (*C.GLchar)(name_cstr))
+ C.free(unsafe.Pointer(name_cstr))
+}
+
+// AttachShader attaches a shader object to a program object.
+//
+// In order to create an executable, there must be a way to specify the list
+// of things that will be linked together. Program objects provide this
+// mechanism. Shaders that are to be linked together in a program object must
+// first be attached to that program object. This indicates that shader will
+// be included in link operations that will be performed on program.
+//
+// All operations that can be performed on a shader object are valid whether
+// or not the shader object is attached to a program object. It is
+// permissible to attach a shader object to a program object before source
+// code has been loaded into the shader object or before the shader object
+// has been compiled. It is permissible to attach multiple shader objects of
+// the same type because each may contain a portion of the complete shader.
+// It is also permissible to attach a shader object to more than one program
+// object. If a shader object is deleted while it is attached to a program
+// object, it will be flagged for deletion, and deletion will not occur until
+// DetachShader is called to detach it from all program objects to which it
+// is attached.
+//
+// Error GL.INVALID_VALUE is generated if either program or shader is not a
+// value generated by OpenGL. GL.INVALID_OPERATION is generated if program
+// is not a program object. GL.INVALID_OPERATION is generated if shader is
+// not a shader object. GL.INVALID_OPERATION is generated if shader is
+// already attached to program. GL.INVALID_OPERATION is generated if
+// AttachShader is executed between the execution of Begin and the
+// corresponding execution of End.
+//
+// AttachShader is available in GL version 2.0 or greater.
+func (gl *GL) AttachShader(program glbase.Program, shader glbase.Shader) {
+ C.gl4_0core_glAttachShader(gl.funcs, C.GLuint(program), C.GLuint(shader))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glStencilMaskSeparate.xml
+func (gl *GL) StencilMaskSeparate(face glbase.Enum, mask uint32) {
+ C.gl4_0core_glStencilMaskSeparate(gl.funcs, C.GLenum(face), C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glStencilFuncSeparate.xml
+func (gl *GL) StencilFuncSeparate(face, glfunc glbase.Enum, ref int32, mask uint32) {
+ C.gl4_0core_glStencilFuncSeparate(gl.funcs, C.GLenum(face), C.GLenum(glfunc), C.GLint(ref), C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glStencilOpSeparate.xml
+func (gl *GL) StencilOpSeparate(face, sfail, dpfail, dppass glbase.Enum) {
+ C.gl4_0core_glStencilOpSeparate(gl.funcs, C.GLenum(face), C.GLenum(sfail), C.GLenum(dpfail), C.GLenum(dppass))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawBuffers.xml
+func (gl *GL) DrawBuffers(n int, bufs []glbase.Enum) {
+ C.gl4_0core_glDrawBuffers(gl.funcs, C.GLsizei(n), (*C.GLenum)(unsafe.Pointer(&bufs[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendEquationSeparate.xml
+func (gl *GL) BlendEquationSeparate(modeRGB, modeAlpha glbase.Enum) {
+ C.gl4_0core_glBlendEquationSeparate(gl.funcs, C.GLenum(modeRGB), C.GLenum(modeAlpha))
+}
+
+// UniformMatrix4x3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix4x3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix4x3fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(4*3) != 0 {
+ panic("invalid value length for UniformMatrix4x3fv")
+ }
+ count := len(value) / (4 * 3)
+ C.gl4_0core_glUniformMatrix4x3fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix3x4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix3x4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix3x4fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(3*4) != 0 {
+ panic("invalid value length for UniformMatrix3x4fv")
+ }
+ count := len(value) / (3 * 4)
+ C.gl4_0core_glUniformMatrix3x4fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix4x2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix4x2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix4x2fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(4*2) != 0 {
+ panic("invalid value length for UniformMatrix4x2fv")
+ }
+ count := len(value) / (4 * 2)
+ C.gl4_0core_glUniformMatrix4x2fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix2x4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix2x4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix2x4fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(2*4) != 0 {
+ panic("invalid value length for UniformMatrix2x4fv")
+ }
+ count := len(value) / (2 * 4)
+ C.gl4_0core_glUniformMatrix2x4fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix3x2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix3x2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix3x2fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(3*2) != 0 {
+ panic("invalid value length for UniformMatrix3x2fv")
+ }
+ count := len(value) / (3 * 2)
+ C.gl4_0core_glUniformMatrix3x2fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix2x3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix2x3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix2x3fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(2*3) != 0 {
+ panic("invalid value length for UniformMatrix2x3fv")
+ }
+ count := len(value) / (2 * 3)
+ C.gl4_0core_glUniformMatrix2x3fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsVertexArray.xml
+func (gl *GL) IsVertexArray(array uint32) bool {
+ glresult := C.gl4_0core_glIsVertexArray(gl.funcs, C.GLuint(array))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGenVertexArrays.xml
+func (gl *GL) GenVertexArrays(n int, arrays []uint32) {
+ C.gl4_0core_glGenVertexArrays(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&arrays[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDeleteVertexArrays.xml
+func (gl *GL) DeleteVertexArrays(n int, arrays []uint32) {
+ C.gl4_0core_glDeleteVertexArrays(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&arrays[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindVertexArray.xml
+func (gl *GL) BindVertexArray(array uint32) {
+ C.gl4_0core_glBindVertexArray(gl.funcs, C.GLuint(array))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFlushMappedBufferRange.xml
+func (gl *GL) FlushMappedBufferRange(target glbase.Enum, offset, length int) {
+ C.gl4_0core_glFlushMappedBufferRange(gl.funcs, C.GLenum(target), C.GLintptr(offset), C.GLsizeiptr(length))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFramebufferTextureLayer.xml
+func (gl *GL) FramebufferTextureLayer(target, attachment glbase.Enum, texture glbase.Texture, level int, layer int32) {
+ C.gl4_0core_glFramebufferTextureLayer(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLuint(texture), C.GLint(level), C.GLint(layer))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRenderbufferStorageMultisample.xml
+func (gl *GL) RenderbufferStorageMultisample(target glbase.Enum, samples int32, internalFormat glbase.Enum, width, height int) {
+ C.gl4_0core_glRenderbufferStorageMultisample(gl.funcs, C.GLenum(target), C.GLsizei(samples), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlitFramebuffer.xml
+func (gl *GL) BlitFramebuffer(srcX0, srcY0, srcX1, srcY1, dstX0, dstY0, dstX1, dstY1 int32, mask glbase.Bitfield, filter glbase.Enum) {
+ C.gl4_0core_glBlitFramebuffer(gl.funcs, C.GLint(srcX0), C.GLint(srcY0), C.GLint(srcX1), C.GLint(srcY1), C.GLint(dstX0), C.GLint(dstY0), C.GLint(dstX1), C.GLint(dstY1), C.GLbitfield(mask), C.GLenum(filter))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGenerateMipmap.xml
+func (gl *GL) GenerateMipmap(target glbase.Enum) {
+ C.gl4_0core_glGenerateMipmap(gl.funcs, C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetFramebufferAttachmentParameteriv.xml
+func (gl *GL) GetFramebufferAttachmentParameteriv(target, attachment, pname glbase.Enum, params []int32) {
+ C.gl4_0core_glGetFramebufferAttachmentParameteriv(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFramebufferRenderbuffer.xml
+func (gl *GL) FramebufferRenderbuffer(target, attachment, renderbuffertarget glbase.Enum, renderbuffer glbase.Renderbuffer) {
+ C.gl4_0core_glFramebufferRenderbuffer(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(renderbuffertarget), C.GLuint(renderbuffer))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFramebufferTexture3D.xml
+func (gl *GL) FramebufferTexture3D(target, attachment, textarget glbase.Enum, texture glbase.Texture, level int, zoffset int32) {
+ C.gl4_0core_glFramebufferTexture3D(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(textarget), C.GLuint(texture), C.GLint(level), C.GLint(zoffset))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFramebufferTexture2D.xml
+func (gl *GL) FramebufferTexture2D(target, attachment, textarget glbase.Enum, texture glbase.Texture, level int) {
+ C.gl4_0core_glFramebufferTexture2D(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(textarget), C.GLuint(texture), C.GLint(level))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFramebufferTexture1D.xml
+func (gl *GL) FramebufferTexture1D(target, attachment, textarget glbase.Enum, texture glbase.Texture, level int) {
+ C.gl4_0core_glFramebufferTexture1D(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(textarget), C.GLuint(texture), C.GLint(level))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCheckFramebufferStatus.xml
+func (gl *GL) CheckFramebufferStatus(target glbase.Enum) glbase.Enum {
+ glresult := C.gl4_0core_glCheckFramebufferStatus(gl.funcs, C.GLenum(target))
+ return glbase.Enum(glresult)
+}
+
+// GenFramebuffers returns n framebuffer object names in ids. There is no
+// guarantee that the names form a contiguous set of integers; however, it is
+// guaranteed that none of the returned names was in use immediately before
+// the call to GenFramebuffers.
+//
+// Framebuffer object names returned by a call to GenFramebuffers are not
+// returned by subsequent calls, unless they are first deleted with
+// DeleteFramebuffers.
+//
+// The names returned in ids are marked as used, for the purposes of
+// GenFramebuffers only, but they acquire state and type only when they are
+// first bound.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+func (gl *GL) GenFramebuffers(n int) []glbase.Framebuffer {
+ if n == 0 {
+ return nil
+ }
+ framebuffers := make([]glbase.Framebuffer, n)
+ C.gl4_0core_glGenFramebuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&framebuffers[0])))
+ return framebuffers
+}
+
+// DeleteFramebuffers deletes the framebuffer objects whose names are
+// stored in the framebuffers slice. The name zero is reserved by the GL and
+// is silently ignored, should it occur in framebuffers, as are other unused
+// names. Once a framebuffer object is deleted, its name is again unused and
+// it has no attachments. If a framebuffer that is currently bound to one or
+// more of the targets GL.DRAW_FRAMEBUFFER or GL.READ_FRAMEBUFFER is deleted,
+// it is as though BindFramebuffer had been executed with the corresponding
+// target and framebuffer zero.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// DeleteFramebuffers is available in GL version 3.0 or greater.
+func (gl *GL) DeleteFramebuffers(framebuffers []glbase.Framebuffer) {
+ n := len(framebuffers)
+ if n == 0 {
+ return
+ }
+ C.gl4_0core_glDeleteFramebuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&framebuffers[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindFramebuffer.xml
+func (gl *GL) BindFramebuffer(target glbase.Enum, framebuffer glbase.Framebuffer) {
+ C.gl4_0core_glBindFramebuffer(gl.funcs, C.GLenum(target), C.GLuint(framebuffer))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsFramebuffer.xml
+func (gl *GL) IsFramebuffer(framebuffer glbase.Framebuffer) bool {
+ glresult := C.gl4_0core_glIsFramebuffer(gl.funcs, C.GLuint(framebuffer))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetRenderbufferParameteriv.xml
+func (gl *GL) GetRenderbufferParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl4_0core_glGetRenderbufferParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRenderbufferStorage.xml
+func (gl *GL) RenderbufferStorage(target, internalFormat glbase.Enum, width, height int) {
+ C.gl4_0core_glRenderbufferStorage(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height))
+}
+
+// GenRenderbuffers returns n renderbuffer object names in renderbuffers.
+// There is no guarantee that the names form a contiguous set of integers;
+// however, it is guaranteed that none of the returned names was in use
+// immediately before the call to GenRenderbuffers.
+//
+// Renderbuffer object names returned by a call to GenRenderbuffers are not
+// returned by subsequent calls, unless they are first deleted with
+// DeleteRenderbuffers.
+//
+// The names returned in renderbuffers are marked as used, for the purposes
+// of GenRenderbuffers only, but they acquire state and type only when they
+// are first bound.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// GenRenderbuffers is available in GL version 3.0 or greater.
+func (gl *GL) GenRenderbuffers(n int) []glbase.Renderbuffer {
+ if n == 0 {
+ return nil
+ }
+ renderbuffers := make([]glbase.Renderbuffer, n)
+ C.gl4_0core_glGenRenderbuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&renderbuffers[0])))
+ return renderbuffers
+}
+
+// DeleteRenderbuffers deletes the renderbuffer objects whose names are stored
+// in the renderbuffers slice. The name zero is reserved by the GL and
+// is silently ignored, should it occur in renderbuffers, as are other unused
+// names. Once a renderbuffer object is deleted, its name is again unused and
+// it has no contents. If a renderbuffer that is currently bound to the
+// target GL.RENDERBUFFER is deleted, it is as though BindRenderbuffer had
+// been executed with a target of GL.RENDERBUFFER and a name of zero.
+//
+// If a renderbuffer object is attached to one or more attachment points in
+// the currently bound framebuffer, then it as if FramebufferRenderbuffer
+// had been called, with a renderbuffer of zero for each attachment point to
+// which this image was attached in the currently bound framebuffer. In other
+// words, this renderbuffer object is first detached from all attachment
+// ponits in the currently bound framebuffer. Note that the renderbuffer
+// image is specifically not detached from any non-bound framebuffers.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// DeleteRenderbuffers is available in GL version 3.0 or greater.
+func (gl *GL) DeleteRenderbuffers(renderbuffers []glbase.Renderbuffer) {
+ n := len(renderbuffers)
+ if n == 0 {
+ return
+ }
+ C.gl4_0core_glDeleteRenderbuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&renderbuffers[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindRenderbuffer.xml
+func (gl *GL) BindRenderbuffer(target glbase.Enum, renderbuffer glbase.Renderbuffer) {
+ C.gl4_0core_glBindRenderbuffer(gl.funcs, C.GLenum(target), C.GLuint(renderbuffer))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsRenderbuffer.xml
+func (gl *GL) IsRenderbuffer(renderbuffer glbase.Renderbuffer) bool {
+ glresult := C.gl4_0core_glIsRenderbuffer(gl.funcs, C.GLuint(renderbuffer))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearBufferfi.xml
+func (gl *GL) ClearBufferfi(buffer glbase.Enum, drawbuffer int32, depth float32, stencil int32) {
+ C.gl4_0core_glClearBufferfi(gl.funcs, C.GLenum(buffer), C.GLint(drawbuffer), C.GLfloat(depth), C.GLint(stencil))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearBufferfv.xml
+func (gl *GL) ClearBufferfv(buffer glbase.Enum, drawbuffer int32, value []float32) {
+ C.gl4_0core_glClearBufferfv(gl.funcs, C.GLenum(buffer), C.GLint(drawbuffer), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearBufferuiv.xml
+func (gl *GL) ClearBufferuiv(buffer glbase.Enum, drawbuffer int32, value []uint32) {
+ C.gl4_0core_glClearBufferuiv(gl.funcs, C.GLenum(buffer), C.GLint(drawbuffer), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearBufferiv.xml
+func (gl *GL) ClearBufferiv(buffer glbase.Enum, drawbuffer int32, value []int32) {
+ C.gl4_0core_glClearBufferiv(gl.funcs, C.GLenum(buffer), C.GLint(drawbuffer), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexParameterIuiv.xml
+func (gl *GL) GetTexParameterIuiv(target, pname glbase.Enum, params []uint32) {
+ C.gl4_0core_glGetTexParameterIuiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexParameterIiv.xml
+func (gl *GL) GetTexParameterIiv(target, pname glbase.Enum, params []int32) {
+ C.gl4_0core_glGetTexParameterIiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexParameterIuiv.xml
+func (gl *GL) TexParameterIuiv(target, pname glbase.Enum, params []uint32) {
+ C.gl4_0core_glTexParameterIuiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexParameterIiv.xml
+func (gl *GL) TexParameterIiv(target, pname glbase.Enum, params []int32) {
+ C.gl4_0core_glTexParameterIiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// Uniform4uiv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform4uiv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4uiv(location glbase.Uniform, value []uint32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%4 != 0 {
+ panic("invalid value length for Uniform4uiv")
+ }
+ count := len(value) / 4
+ C.gl4_0core_glUniform4uiv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform3uiv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform3uiv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3uiv(location glbase.Uniform, value []uint32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%3 != 0 {
+ panic("invalid value length for Uniform3uiv")
+ }
+ count := len(value) / 3
+ C.gl4_0core_glUniform3uiv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform2uiv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform2uiv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2uiv(location glbase.Uniform, value []uint32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%2 != 0 {
+ panic("invalid value length for Uniform2uiv")
+ }
+ count := len(value) / 2
+ C.gl4_0core_glUniform2uiv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform1uiv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform1uiv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1uiv(location glbase.Uniform, value []uint32) {
+ if len(value) == 0 {
+ return
+ }
+ count := len(value)
+ C.gl4_0core_glUniform1uiv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4ui modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform4ui operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4ui(location glbase.Uniform, v0, v1, v2, v3 uint32) {
+ C.gl4_0core_glUniform4ui(gl.funcs, C.GLint(location), C.GLuint(v0), C.GLuint(v1), C.GLuint(v2), C.GLuint(v3))
+}
+
+// Uniform3ui modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform3ui operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3ui(location glbase.Uniform, v0, v1, v2 uint32) {
+ C.gl4_0core_glUniform3ui(gl.funcs, C.GLint(location), C.GLuint(v0), C.GLuint(v1), C.GLuint(v2))
+}
+
+// Uniform2ui modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform2ui operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2ui(location glbase.Uniform, v0, v1 uint32) {
+ C.gl4_0core_glUniform2ui(gl.funcs, C.GLint(location), C.GLuint(v0), C.GLuint(v1))
+}
+
+// Uniform1ui modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform1ui operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1ui(location glbase.Uniform, v0 uint32) {
+ C.gl4_0core_glUniform1ui(gl.funcs, C.GLint(location), C.GLuint(v0))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetFragDataLocation.xml
+func (gl *GL) GetFragDataLocation(program glbase.Program, name []byte) int32 {
+ glresult := C.gl4_0core_glGetFragDataLocation(gl.funcs, C.GLuint(program), (*C.GLchar)(unsafe.Pointer(&name[0])))
+ return int32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindFragDataLocation.xml
+func (gl *GL) BindFragDataLocation(program glbase.Program, color uint32, name []byte) {
+ C.gl4_0core_glBindFragDataLocation(gl.funcs, C.GLuint(program), C.GLuint(color), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetUniformuiv.xml
+func (gl *GL) GetUniformuiv(program glbase.Program, location glbase.Uniform, params []uint32) {
+ C.gl4_0core_glGetUniformuiv(gl.funcs, C.GLuint(program), C.GLint(location), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetVertexAttribIuiv.xml
+func (gl *GL) GetVertexAttribIuiv(index glbase.Attrib, pname glbase.Enum, params []uint32) {
+ C.gl4_0core_glGetVertexAttribIuiv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetVertexAttribIiv.xml
+func (gl *GL) GetVertexAttribIiv(index glbase.Attrib, pname glbase.Enum, params []int32) {
+ C.gl4_0core_glGetVertexAttribIiv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribIPointer.xml
+func (gl *GL) VertexAttribIPointer(index glbase.Attrib, size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0core_glVertexAttribIPointer(gl.funcs, C.GLuint(index), C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEndConditionalRender.xml
+func (gl *GL) EndConditionalRender() {
+ C.gl4_0core_glEndConditionalRender(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBeginConditionalRender.xml
+func (gl *GL) BeginConditionalRender(id uint32, mode glbase.Enum) {
+ C.gl4_0core_glBeginConditionalRender(gl.funcs, C.GLuint(id), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClampColor.xml
+func (gl *GL) ClampColor(target, clamp glbase.Enum) {
+ C.gl4_0core_glClampColor(gl.funcs, C.GLenum(target), C.GLenum(clamp))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTransformFeedbackVarying.xml
+func (gl *GL) GetTransformFeedbackVarying(program glbase.Program, index uint32, bufSize int32, length []int32, size []int, gltype []glbase.Enum, name []byte) {
+ C.gl4_0core_glGetTransformFeedbackVarying(gl.funcs, C.GLuint(program), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLsizei)(unsafe.Pointer(&size[0])), (*C.GLenum)(unsafe.Pointer(&gltype[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindBufferBase.xml
+func (gl *GL) BindBufferBase(target glbase.Enum, index uint32, buffer glbase.Buffer) {
+ C.gl4_0core_glBindBufferBase(gl.funcs, C.GLenum(target), C.GLuint(index), C.GLuint(buffer))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindBufferRange.xml
+func (gl *GL) BindBufferRange(target glbase.Enum, index uint32, buffer glbase.Buffer, offset, size int) {
+ C.gl4_0core_glBindBufferRange(gl.funcs, C.GLenum(target), C.GLuint(index), C.GLuint(buffer), C.GLintptr(offset), C.GLsizeiptr(size))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEndTransformFeedback.xml
+func (gl *GL) EndTransformFeedback() {
+ C.gl4_0core_glEndTransformFeedback(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBeginTransformFeedback.xml
+func (gl *GL) BeginTransformFeedback(primitiveMode glbase.Enum) {
+ C.gl4_0core_glBeginTransformFeedback(gl.funcs, C.GLenum(primitiveMode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsEnabledi.xml
+func (gl *GL) IsEnabledi(target glbase.Enum, index uint32) bool {
+ glresult := C.gl4_0core_glIsEnabledi(gl.funcs, C.GLenum(target), C.GLuint(index))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDisablei.xml
+func (gl *GL) Disablei(target glbase.Enum, index uint32) {
+ C.gl4_0core_glDisablei(gl.funcs, C.GLenum(target), C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEnablei.xml
+func (gl *GL) Enablei(target glbase.Enum, index uint32) {
+ C.gl4_0core_glEnablei(gl.funcs, C.GLenum(target), C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetIntegeri_v.xml
+func (gl *GL) GetIntegeri_v(target glbase.Enum, index uint32, data []int32) {
+ C.gl4_0core_glGetIntegeri_v(gl.funcs, C.GLenum(target), C.GLuint(index), (*C.GLint)(unsafe.Pointer(&data[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetBooleani_v.xml
+func (gl *GL) GetBooleani_v(target glbase.Enum, index uint32, data []bool) {
+ C.gl4_0core_glGetBooleani_v(gl.funcs, C.GLenum(target), C.GLuint(index), (*C.GLboolean)(unsafe.Pointer(&data[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorMaski.xml
+func (gl *GL) ColorMaski(index uint32, r, g, b, a bool) {
+ C.gl4_0core_glColorMaski(gl.funcs, C.GLuint(index), *(*C.GLboolean)(unsafe.Pointer(&r)), *(*C.GLboolean)(unsafe.Pointer(&g)), *(*C.GLboolean)(unsafe.Pointer(&b)), *(*C.GLboolean)(unsafe.Pointer(&a)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyBufferSubData.xml
+func (gl *GL) CopyBufferSubData(readTarget, writeTarget glbase.Enum, readOffset, writeOffset, size int) {
+ C.gl4_0core_glCopyBufferSubData(gl.funcs, C.GLenum(readTarget), C.GLenum(writeTarget), C.GLintptr(readOffset), C.GLintptr(writeOffset), C.GLsizeiptr(size))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformBlockBinding.xml
+func (gl *GL) UniformBlockBinding(program glbase.Program, v0, v1 uint32) {
+ C.gl4_0core_glUniformBlockBinding(gl.funcs, C.GLuint(program), C.GLuint(v0), C.GLuint(v1))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveUniformBlockName.xml
+func (gl *GL) GetActiveUniformBlockName(program glbase.Program, uniformBlockIndex uint32, bufSize int32, length []int32, uniformBlockName []byte) {
+ C.gl4_0core_glGetActiveUniformBlockName(gl.funcs, C.GLuint(program), C.GLuint(uniformBlockIndex), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&uniformBlockName[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveUniformBlockiv.xml
+func (gl *GL) GetActiveUniformBlockiv(program glbase.Program, uniformBlockIndex uint32, pname glbase.Enum, params []int32) {
+ C.gl4_0core_glGetActiveUniformBlockiv(gl.funcs, C.GLuint(program), C.GLuint(uniformBlockIndex), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetUniformBlockIndex.xml
+func (gl *GL) GetUniformBlockIndex(program glbase.Program, uniformBlockName []byte) uint32 {
+ glresult := C.gl4_0core_glGetUniformBlockIndex(gl.funcs, C.GLuint(program), (*C.GLchar)(unsafe.Pointer(&uniformBlockName[0])))
+ return uint32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveUniformName.xml
+func (gl *GL) GetActiveUniformName(program glbase.Program, uniformIndex uint32, bufSize int32, length []int32, uniformName []byte) {
+ C.gl4_0core_glGetActiveUniformName(gl.funcs, C.GLuint(program), C.GLuint(uniformIndex), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&uniformName[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveUniformsiv.xml
+func (gl *GL) GetActiveUniformsiv(program glbase.Program, uniformCount int32, uniformIndices []uint32, pname glbase.Enum, params []int32) {
+ C.gl4_0core_glGetActiveUniformsiv(gl.funcs, C.GLuint(program), C.GLsizei(uniformCount), (*C.GLuint)(unsafe.Pointer(&uniformIndices[0])), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPrimitiveRestartIndex.xml
+func (gl *GL) PrimitiveRestartIndex(index uint32) {
+ C.gl4_0core_glPrimitiveRestartIndex(gl.funcs, C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexBuffer.xml
+func (gl *GL) TexBuffer(target, internalFormat glbase.Enum, buffer glbase.Buffer) {
+ C.gl4_0core_glTexBuffer(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLuint(buffer))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawElementsInstanced.xml
+func (gl *GL) DrawElementsInstanced(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}, instancecount int32) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0core_glDrawElementsInstanced(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr, C.GLsizei(instancecount))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawArraysInstanced.xml
+func (gl *GL) DrawArraysInstanced(mode glbase.Enum, first, count int, instancecount int32) {
+ C.gl4_0core_glDrawArraysInstanced(gl.funcs, C.GLenum(mode), C.GLint(first), C.GLsizei(count), C.GLsizei(instancecount))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSampleMaski.xml
+func (gl *GL) SampleMaski(index uint32, mask glbase.Bitfield) {
+ C.gl4_0core_glSampleMaski(gl.funcs, C.GLuint(index), C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetMultisamplefv.xml
+func (gl *GL) GetMultisamplefv(pname glbase.Enum, index uint32, val []float32) {
+ C.gl4_0core_glGetMultisamplefv(gl.funcs, C.GLenum(pname), C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&val[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexImage3DMultisample.xml
+func (gl *GL) TexImage3DMultisample(target glbase.Enum, samples, internalFormat int32, width, height int, depth int32, fixedsamplelocations bool) {
+ C.gl4_0core_glTexImage3DMultisample(gl.funcs, C.GLenum(target), C.GLsizei(samples), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), *(*C.GLboolean)(unsafe.Pointer(&fixedsamplelocations)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexImage2DMultisample.xml
+func (gl *GL) TexImage2DMultisample(target glbase.Enum, samples, internalFormat int32, width, height int, fixedsamplelocations bool) {
+ C.gl4_0core_glTexImage2DMultisample(gl.funcs, C.GLenum(target), C.GLsizei(samples), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), *(*C.GLboolean)(unsafe.Pointer(&fixedsamplelocations)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetSynciv.xml
+func (gl *GL) GetSynciv(sync glbase.Sync, pname glbase.Enum, bufSize int32, length, values []int32) {
+ C.gl4_0core_glGetSynciv(gl.funcs, C.GLsync(unsafe.Pointer(sync)), C.GLenum(pname), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLint)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetInteger64v.xml
+func (gl *GL) GetInteger64v(pname glbase.Enum, params []int64) {
+ C.gl4_0core_glGetInteger64v(gl.funcs, C.GLenum(pname), (*C.GLint64)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWaitSync.xml
+func (gl *GL) WaitSync(sync glbase.Sync, flags glbase.Bitfield, timeout uint64) {
+ C.gl4_0core_glWaitSync(gl.funcs, C.GLsync(unsafe.Pointer(sync)), C.GLbitfield(flags), C.GLuint64(timeout))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClientWaitSync.xml
+func (gl *GL) ClientWaitSync(sync glbase.Sync, flags glbase.Bitfield, timeout uint64) glbase.Enum {
+ glresult := C.gl4_0core_glClientWaitSync(gl.funcs, C.GLsync(unsafe.Pointer(sync)), C.GLbitfield(flags), C.GLuint64(timeout))
+ return glbase.Enum(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDeleteSync.xml
+func (gl *GL) DeleteSync(sync glbase.Sync) {
+ C.gl4_0core_glDeleteSync(gl.funcs, C.GLsync(unsafe.Pointer(sync)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsSync.xml
+func (gl *GL) IsSync(sync glbase.Sync) bool {
+ glresult := C.gl4_0core_glIsSync(gl.funcs, C.GLsync(unsafe.Pointer(sync)))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFenceSync.xml
+func (gl *GL) FenceSync(condition glbase.Enum, flags glbase.Bitfield) glbase.Sync {
+ glresult := C.gl4_0core_glFenceSync(gl.funcs, C.GLenum(condition), C.GLbitfield(flags))
+ return glbase.Sync(unsafe.Pointer(glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProvokingVertex.xml
+func (gl *GL) ProvokingVertex(mode glbase.Enum) {
+ C.gl4_0core_glProvokingVertex(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawElementsInstancedBaseVertex.xml
+func (gl *GL) DrawElementsInstancedBaseVertex(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}, instancecount, basevertex int32) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0core_glDrawElementsInstancedBaseVertex(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr, C.GLsizei(instancecount), C.GLint(basevertex))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawRangeElementsBaseVertex.xml
+func (gl *GL) DrawRangeElementsBaseVertex(mode glbase.Enum, start, end uint32, count int, gltype glbase.Enum, indices interface{}, basevertex int32) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0core_glDrawRangeElementsBaseVertex(gl.funcs, C.GLenum(mode), C.GLuint(start), C.GLuint(end), C.GLsizei(count), C.GLenum(gltype), indices_ptr, C.GLint(basevertex))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawElementsBaseVertex.xml
+func (gl *GL) DrawElementsBaseVertex(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}, basevertex int32) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0core_glDrawElementsBaseVertex(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr, C.GLint(basevertex))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFramebufferTexture.xml
+func (gl *GL) FramebufferTexture(target, attachment glbase.Enum, texture glbase.Texture, level int) {
+ C.gl4_0core_glFramebufferTexture(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLuint(texture), C.GLint(level))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetBufferParameteri64v.xml
+func (gl *GL) GetBufferParameteri64v(target, pname glbase.Enum, params []int64) {
+ C.gl4_0core_glGetBufferParameteri64v(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint64)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetInteger64i_v.xml
+func (gl *GL) GetInteger64i_v(target glbase.Enum, index uint32, data []int64) {
+ C.gl4_0core_glGetInteger64i_v(gl.funcs, C.GLenum(target), C.GLuint(index), (*C.GLint64)(unsafe.Pointer(&data[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP4uiv.xml
+func (gl *GL) VertexAttribP4uiv(index glbase.Attrib, gltype glbase.Enum, normalized bool, value []uint32) {
+ C.gl4_0core_glVertexAttribP4uiv(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP4ui.xml
+func (gl *GL) VertexAttribP4ui(index glbase.Attrib, gltype glbase.Enum, normalized bool, value uint32) {
+ C.gl4_0core_glVertexAttribP4ui(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP3uiv.xml
+func (gl *GL) VertexAttribP3uiv(index glbase.Attrib, gltype glbase.Enum, normalized bool, value []uint32) {
+ C.gl4_0core_glVertexAttribP3uiv(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP3ui.xml
+func (gl *GL) VertexAttribP3ui(index glbase.Attrib, gltype glbase.Enum, normalized bool, value uint32) {
+ C.gl4_0core_glVertexAttribP3ui(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP2uiv.xml
+func (gl *GL) VertexAttribP2uiv(index glbase.Attrib, gltype glbase.Enum, normalized bool, value []uint32) {
+ C.gl4_0core_glVertexAttribP2uiv(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP2ui.xml
+func (gl *GL) VertexAttribP2ui(index glbase.Attrib, gltype glbase.Enum, normalized bool, value uint32) {
+ C.gl4_0core_glVertexAttribP2ui(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP1uiv.xml
+func (gl *GL) VertexAttribP1uiv(index glbase.Attrib, gltype glbase.Enum, normalized bool, value []uint32) {
+ C.gl4_0core_glVertexAttribP1uiv(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP1ui.xml
+func (gl *GL) VertexAttribP1ui(index glbase.Attrib, gltype glbase.Enum, normalized bool, value uint32) {
+ C.gl4_0core_glVertexAttribP1ui(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColorP3uiv.xml
+func (gl *GL) SecondaryColorP3uiv(gltype glbase.Enum, color []uint32) {
+ C.gl4_0core_glSecondaryColorP3uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&color[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColorP3ui.xml
+func (gl *GL) SecondaryColorP3ui(gltype glbase.Enum, color uint32) {
+ C.gl4_0core_glSecondaryColorP3ui(gl.funcs, C.GLenum(gltype), C.GLuint(color))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorP4uiv.xml
+func (gl *GL) ColorP4uiv(gltype glbase.Enum, color []uint32) {
+ C.gl4_0core_glColorP4uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&color[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorP4ui.xml
+func (gl *GL) ColorP4ui(gltype glbase.Enum, color uint32) {
+ C.gl4_0core_glColorP4ui(gl.funcs, C.GLenum(gltype), C.GLuint(color))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorP3uiv.xml
+func (gl *GL) ColorP3uiv(gltype glbase.Enum, color []uint32) {
+ C.gl4_0core_glColorP3uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&color[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorP3ui.xml
+func (gl *GL) ColorP3ui(gltype glbase.Enum, color uint32) {
+ C.gl4_0core_glColorP3ui(gl.funcs, C.GLenum(gltype), C.GLuint(color))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNormalP3uiv.xml
+func (gl *GL) NormalP3uiv(gltype glbase.Enum, coords []uint32) {
+ C.gl4_0core_glNormalP3uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNormalP3ui.xml
+func (gl *GL) NormalP3ui(gltype glbase.Enum, coords uint32) {
+ C.gl4_0core_glNormalP3ui(gl.funcs, C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP4uiv.xml
+func (gl *GL) MultiTexCoordP4uiv(texture, gltype glbase.Enum, coords []uint32) {
+ C.gl4_0core_glMultiTexCoordP4uiv(gl.funcs, C.GLenum(texture), C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP4ui.xml
+func (gl *GL) MultiTexCoordP4ui(texture, gltype glbase.Enum, coords uint32) {
+ C.gl4_0core_glMultiTexCoordP4ui(gl.funcs, C.GLenum(texture), C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP3uiv.xml
+func (gl *GL) MultiTexCoordP3uiv(texture, gltype glbase.Enum, coords []uint32) {
+ C.gl4_0core_glMultiTexCoordP3uiv(gl.funcs, C.GLenum(texture), C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP3ui.xml
+func (gl *GL) MultiTexCoordP3ui(texture, gltype glbase.Enum, coords uint32) {
+ C.gl4_0core_glMultiTexCoordP3ui(gl.funcs, C.GLenum(texture), C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP2uiv.xml
+func (gl *GL) MultiTexCoordP2uiv(texture, gltype glbase.Enum, coords []uint32) {
+ C.gl4_0core_glMultiTexCoordP2uiv(gl.funcs, C.GLenum(texture), C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP2ui.xml
+func (gl *GL) MultiTexCoordP2ui(texture, gltype glbase.Enum, coords uint32) {
+ C.gl4_0core_glMultiTexCoordP2ui(gl.funcs, C.GLenum(texture), C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP1uiv.xml
+func (gl *GL) MultiTexCoordP1uiv(texture, gltype glbase.Enum, coords []uint32) {
+ C.gl4_0core_glMultiTexCoordP1uiv(gl.funcs, C.GLenum(texture), C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP1ui.xml
+func (gl *GL) MultiTexCoordP1ui(texture, gltype glbase.Enum, coords uint32) {
+ C.gl4_0core_glMultiTexCoordP1ui(gl.funcs, C.GLenum(texture), C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP4uiv.xml
+func (gl *GL) TexCoordP4uiv(gltype glbase.Enum, coords []uint32) {
+ C.gl4_0core_glTexCoordP4uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP4ui.xml
+func (gl *GL) TexCoordP4ui(gltype glbase.Enum, coords uint32) {
+ C.gl4_0core_glTexCoordP4ui(gl.funcs, C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP3uiv.xml
+func (gl *GL) TexCoordP3uiv(gltype glbase.Enum, coords []uint32) {
+ C.gl4_0core_glTexCoordP3uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP3ui.xml
+func (gl *GL) TexCoordP3ui(gltype glbase.Enum, coords uint32) {
+ C.gl4_0core_glTexCoordP3ui(gl.funcs, C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP2uiv.xml
+func (gl *GL) TexCoordP2uiv(gltype glbase.Enum, coords []uint32) {
+ C.gl4_0core_glTexCoordP2uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP2ui.xml
+func (gl *GL) TexCoordP2ui(gltype glbase.Enum, coords uint32) {
+ C.gl4_0core_glTexCoordP2ui(gl.funcs, C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP1uiv.xml
+func (gl *GL) TexCoordP1uiv(gltype glbase.Enum, coords []uint32) {
+ C.gl4_0core_glTexCoordP1uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP1ui.xml
+func (gl *GL) TexCoordP1ui(gltype glbase.Enum, coords uint32) {
+ C.gl4_0core_glTexCoordP1ui(gl.funcs, C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexP4uiv.xml
+func (gl *GL) VertexP4uiv(gltype glbase.Enum, value []uint32) {
+ C.gl4_0core_glVertexP4uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexP4ui.xml
+func (gl *GL) VertexP4ui(gltype glbase.Enum, value uint32) {
+ C.gl4_0core_glVertexP4ui(gl.funcs, C.GLenum(gltype), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexP3uiv.xml
+func (gl *GL) VertexP3uiv(gltype glbase.Enum, value []uint32) {
+ C.gl4_0core_glVertexP3uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexP3ui.xml
+func (gl *GL) VertexP3ui(gltype glbase.Enum, value uint32) {
+ C.gl4_0core_glVertexP3ui(gl.funcs, C.GLenum(gltype), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexP2uiv.xml
+func (gl *GL) VertexP2uiv(gltype glbase.Enum, value []uint32) {
+ C.gl4_0core_glVertexP2uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexP2ui.xml
+func (gl *GL) VertexP2ui(gltype glbase.Enum, value uint32) {
+ C.gl4_0core_glVertexP2ui(gl.funcs, C.GLenum(gltype), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetQueryObjectui64v.xml
+func (gl *GL) GetQueryObjectui64v(id uint32, pname glbase.Enum, params []uint64) {
+ C.gl4_0core_glGetQueryObjectui64v(gl.funcs, C.GLuint(id), C.GLenum(pname), (*C.GLuint64)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetQueryObjecti64v.xml
+func (gl *GL) GetQueryObjecti64v(id uint32, pname glbase.Enum, params []int64) {
+ C.gl4_0core_glGetQueryObjecti64v(gl.funcs, C.GLuint(id), C.GLenum(pname), (*C.GLint64)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glQueryCounter.xml
+func (gl *GL) QueryCounter(id uint32, target glbase.Enum) {
+ C.gl4_0core_glQueryCounter(gl.funcs, C.GLuint(id), C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetSamplerParameterIuiv.xml
+func (gl *GL) GetSamplerParameterIuiv(sampler uint32, pname glbase.Enum, params []uint32) {
+ C.gl4_0core_glGetSamplerParameterIuiv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetSamplerParameterfv.xml
+func (gl *GL) GetSamplerParameterfv(sampler uint32, pname glbase.Enum, params []float32) {
+ C.gl4_0core_glGetSamplerParameterfv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetSamplerParameterIiv.xml
+func (gl *GL) GetSamplerParameterIiv(sampler uint32, pname glbase.Enum, params []int32) {
+ C.gl4_0core_glGetSamplerParameterIiv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetSamplerParameteriv.xml
+func (gl *GL) GetSamplerParameteriv(sampler uint32, pname glbase.Enum, params []int32) {
+ C.gl4_0core_glGetSamplerParameteriv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSamplerParameterIuiv.xml
+func (gl *GL) SamplerParameterIuiv(sampler uint32, pname glbase.Enum, param []uint32) {
+ C.gl4_0core_glSamplerParameterIuiv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&param[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSamplerParameterIiv.xml
+func (gl *GL) SamplerParameterIiv(sampler uint32, pname glbase.Enum, param []int32) {
+ C.gl4_0core_glSamplerParameterIiv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&param[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSamplerParameterfv.xml
+func (gl *GL) SamplerParameterfv(sampler uint32, pname glbase.Enum, param []float32) {
+ C.gl4_0core_glSamplerParameterfv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&param[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSamplerParameterf.xml
+func (gl *GL) SamplerParameterf(sampler uint32, pname glbase.Enum, param float32) {
+ C.gl4_0core_glSamplerParameterf(gl.funcs, C.GLuint(sampler), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSamplerParameteriv.xml
+func (gl *GL) SamplerParameteriv(sampler uint32, pname glbase.Enum, param []int32) {
+ C.gl4_0core_glSamplerParameteriv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&param[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSamplerParameteri.xml
+func (gl *GL) SamplerParameteri(sampler uint32, pname glbase.Enum, param int32) {
+ C.gl4_0core_glSamplerParameteri(gl.funcs, C.GLuint(sampler), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindSampler.xml
+func (gl *GL) BindSampler(unit, sampler uint32) {
+ C.gl4_0core_glBindSampler(gl.funcs, C.GLuint(unit), C.GLuint(sampler))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsSampler.xml
+func (gl *GL) IsSampler(sampler uint32) bool {
+ glresult := C.gl4_0core_glIsSampler(gl.funcs, C.GLuint(sampler))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDeleteSamplers.xml
+func (gl *GL) DeleteSamplers(count int, samplers []uint32) {
+ C.gl4_0core_glDeleteSamplers(gl.funcs, C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&samplers[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGenSamplers.xml
+func (gl *GL) GenSamplers(count int, samplers []uint32) {
+ C.gl4_0core_glGenSamplers(gl.funcs, C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&samplers[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetFragDataIndex.xml
+func (gl *GL) GetFragDataIndex(program glbase.Program, name []byte) int32 {
+ glresult := C.gl4_0core_glGetFragDataIndex(gl.funcs, C.GLuint(program), (*C.GLchar)(unsafe.Pointer(&name[0])))
+ return int32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindFragDataLocationIndexed.xml
+func (gl *GL) BindFragDataLocationIndexed(program glbase.Program, colorNumber, index uint32, name []byte) {
+ C.gl4_0core_glBindFragDataLocationIndexed(gl.funcs, C.GLuint(program), C.GLuint(colorNumber), C.GLuint(index), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribDivisor.xml
+func (gl *GL) VertexAttribDivisor(index glbase.Attrib, divisor uint32) {
+ C.gl4_0core_glVertexAttribDivisor(gl.funcs, C.GLuint(index), C.GLuint(divisor))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetQueryIndexediv.xml
+func (gl *GL) GetQueryIndexediv(target glbase.Enum, index uint32, pname glbase.Enum, params []int32) {
+ C.gl4_0core_glGetQueryIndexediv(gl.funcs, C.GLenum(target), C.GLuint(index), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEndQueryIndexed.xml
+func (gl *GL) EndQueryIndexed(target glbase.Enum, index uint32) {
+ C.gl4_0core_glEndQueryIndexed(gl.funcs, C.GLenum(target), C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBeginQueryIndexed.xml
+func (gl *GL) BeginQueryIndexed(target glbase.Enum, index, id uint32) {
+ C.gl4_0core_glBeginQueryIndexed(gl.funcs, C.GLenum(target), C.GLuint(index), C.GLuint(id))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawTransformFeedbackStream.xml
+func (gl *GL) DrawTransformFeedbackStream(mode glbase.Enum, id, stream uint32) {
+ C.gl4_0core_glDrawTransformFeedbackStream(gl.funcs, C.GLenum(mode), C.GLuint(id), C.GLuint(stream))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawTransformFeedback.xml
+func (gl *GL) DrawTransformFeedback(mode glbase.Enum, id uint32) {
+ C.gl4_0core_glDrawTransformFeedback(gl.funcs, C.GLenum(mode), C.GLuint(id))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glResumeTransformFeedback.xml
+func (gl *GL) ResumeTransformFeedback() {
+ C.gl4_0core_glResumeTransformFeedback(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPauseTransformFeedback.xml
+func (gl *GL) PauseTransformFeedback() {
+ C.gl4_0core_glPauseTransformFeedback(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsTransformFeedback.xml
+func (gl *GL) IsTransformFeedback(id uint32) bool {
+ glresult := C.gl4_0core_glIsTransformFeedback(gl.funcs, C.GLuint(id))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGenTransformFeedbacks.xml
+func (gl *GL) GenTransformFeedbacks(n int, ids []uint32) {
+ C.gl4_0core_glGenTransformFeedbacks(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&ids[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDeleteTransformFeedbacks.xml
+func (gl *GL) DeleteTransformFeedbacks(n int, ids []uint32) {
+ C.gl4_0core_glDeleteTransformFeedbacks(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&ids[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindTransformFeedback.xml
+func (gl *GL) BindTransformFeedback(target glbase.Enum, id uint32) {
+ C.gl4_0core_glBindTransformFeedback(gl.funcs, C.GLenum(target), C.GLuint(id))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPatchParameterfv.xml
+func (gl *GL) PatchParameterfv(pname glbase.Enum, values []float32) {
+ C.gl4_0core_glPatchParameterfv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPatchParameteri.xml
+func (gl *GL) PatchParameteri(pname glbase.Enum, value int32) {
+ C.gl4_0core_glPatchParameteri(gl.funcs, C.GLenum(pname), C.GLint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetProgramStageiv.xml
+func (gl *GL) GetProgramStageiv(program glbase.Program, shadertype, pname glbase.Enum, values []int32) {
+ C.gl4_0core_glGetProgramStageiv(gl.funcs, C.GLuint(program), C.GLenum(shadertype), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetUniformSubroutineuiv.xml
+func (gl *GL) GetUniformSubroutineuiv(shadertype glbase.Enum, location glbase.Uniform, params []uint32) {
+ C.gl4_0core_glGetUniformSubroutineuiv(gl.funcs, C.GLenum(shadertype), C.GLint(location), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformSubroutinesuiv.xml
+func (gl *GL) UniformSubroutinesuiv(shadertype glbase.Enum, count int, value []uint32) {
+ C.gl4_0core_glUniformSubroutinesuiv(gl.funcs, C.GLenum(shadertype), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveSubroutineName.xml
+func (gl *GL) GetActiveSubroutineName(program glbase.Program, shadertype glbase.Enum, index uint32, bufSize int32, length []int32, name []byte) {
+ C.gl4_0core_glGetActiveSubroutineName(gl.funcs, C.GLuint(program), C.GLenum(shadertype), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveSubroutineUniformName.xml
+func (gl *GL) GetActiveSubroutineUniformName(program glbase.Program, shadertype glbase.Enum, index uint32, bufSize int32, length []int32, name []byte) {
+ C.gl4_0core_glGetActiveSubroutineUniformName(gl.funcs, C.GLuint(program), C.GLenum(shadertype), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveSubroutineUniformiv.xml
+func (gl *GL) GetActiveSubroutineUniformiv(program glbase.Program, shadertype glbase.Enum, index uint32, pname glbase.Enum, values []int32) {
+ C.gl4_0core_glGetActiveSubroutineUniformiv(gl.funcs, C.GLuint(program), C.GLenum(shadertype), C.GLuint(index), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetSubroutineIndex.xml
+func (gl *GL) GetSubroutineIndex(program glbase.Program, shadertype glbase.Enum, name []byte) uint32 {
+ glresult := C.gl4_0core_glGetSubroutineIndex(gl.funcs, C.GLuint(program), C.GLenum(shadertype), (*C.GLchar)(unsafe.Pointer(&name[0])))
+ return uint32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetSubroutineUniformLocation.xml
+func (gl *GL) GetSubroutineUniformLocation(program glbase.Program, shadertype glbase.Enum, name []byte) int32 {
+ glresult := C.gl4_0core_glGetSubroutineUniformLocation(gl.funcs, C.GLuint(program), C.GLenum(shadertype), (*C.GLchar)(unsafe.Pointer(&name[0])))
+ return int32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetUniformdv.xml
+func (gl *GL) GetUniformdv(program glbase.Program, location glbase.Uniform, params []float64) {
+ C.gl4_0core_glGetUniformdv(gl.funcs, C.GLuint(program), C.GLint(location), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix4x3dv.xml
+func (gl *GL) UniformMatrix4x3dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_0core_glUniformMatrix4x3dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix4x2dv.xml
+func (gl *GL) UniformMatrix4x2dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_0core_glUniformMatrix4x2dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix3x4dv.xml
+func (gl *GL) UniformMatrix3x4dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_0core_glUniformMatrix3x4dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix3x2dv.xml
+func (gl *GL) UniformMatrix3x2dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_0core_glUniformMatrix3x2dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix2x4dv.xml
+func (gl *GL) UniformMatrix2x4dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_0core_glUniformMatrix2x4dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix2x3dv.xml
+func (gl *GL) UniformMatrix2x3dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_0core_glUniformMatrix2x3dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix4dv.xml
+func (gl *GL) UniformMatrix4dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_0core_glUniformMatrix4dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix3dv.xml
+func (gl *GL) UniformMatrix3dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_0core_glUniformMatrix3dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix2dv.xml
+func (gl *GL) UniformMatrix2dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_0core_glUniformMatrix2dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform4dv.xml
+func (gl *GL) Uniform4dv(location glbase.Uniform, count int, value []float64) {
+ C.gl4_0core_glUniform4dv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform3dv.xml
+func (gl *GL) Uniform3dv(location glbase.Uniform, count int, value []float64) {
+ C.gl4_0core_glUniform3dv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform2dv.xml
+func (gl *GL) Uniform2dv(location glbase.Uniform, count int, value []float64) {
+ C.gl4_0core_glUniform2dv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform1dv.xml
+func (gl *GL) Uniform1dv(location glbase.Uniform, count int, value []float64) {
+ C.gl4_0core_glUniform1dv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform4d.xml
+func (gl *GL) Uniform4d(location glbase.Uniform, v0, v1, v2, v3 float64) {
+ C.gl4_0core_glUniform4d(gl.funcs, C.GLint(location), C.GLdouble(v0), C.GLdouble(v1), C.GLdouble(v2), C.GLdouble(v3))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform3d.xml
+func (gl *GL) Uniform3d(location glbase.Uniform, v0, v1, v2 float64) {
+ C.gl4_0core_glUniform3d(gl.funcs, C.GLint(location), C.GLdouble(v0), C.GLdouble(v1), C.GLdouble(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform2d.xml
+func (gl *GL) Uniform2d(location glbase.Uniform, v0, v1 float64) {
+ C.gl4_0core_glUniform2d(gl.funcs, C.GLint(location), C.GLdouble(v0), C.GLdouble(v1))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform1d.xml
+func (gl *GL) Uniform1d(location glbase.Uniform, v0 float64) {
+ C.gl4_0core_glUniform1d(gl.funcs, C.GLint(location), C.GLdouble(v0))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawElementsIndirect.xml
+func (gl *GL) DrawElementsIndirect(mode, gltype glbase.Enum, indirect interface{}) {
+ var indirect_ptr unsafe.Pointer
+ var indirect_v = reflect.ValueOf(indirect)
+ if indirect != nil && indirect_v.Kind() != reflect.Slice {
+ panic("parameter indirect must be a slice")
+ }
+ if indirect != nil {
+ indirect_ptr = unsafe.Pointer(indirect_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0core_glDrawElementsIndirect(gl.funcs, C.GLenum(mode), C.GLenum(gltype), indirect_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawArraysIndirect.xml
+func (gl *GL) DrawArraysIndirect(mode glbase.Enum, indirect interface{}) {
+ var indirect_ptr unsafe.Pointer
+ var indirect_v = reflect.ValueOf(indirect)
+ if indirect != nil && indirect_v.Kind() != reflect.Slice {
+ panic("parameter indirect must be a slice")
+ }
+ if indirect != nil {
+ indirect_ptr = unsafe.Pointer(indirect_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_0core_glDrawArraysIndirect(gl.funcs, C.GLenum(mode), indirect_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendFuncSeparatei.xml
+func (gl *GL) BlendFuncSeparatei(buf uint32, srcRGB, dstRGB, srcAlpha, dstAlpha glbase.Enum) {
+ C.gl4_0core_glBlendFuncSeparatei(gl.funcs, C.GLuint(buf), C.GLenum(srcRGB), C.GLenum(dstRGB), C.GLenum(srcAlpha), C.GLenum(dstAlpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendFunci.xml
+func (gl *GL) BlendFunci(buf uint32, src, dst glbase.Enum) {
+ C.gl4_0core_glBlendFunci(gl.funcs, C.GLuint(buf), C.GLenum(src), C.GLenum(dst))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendEquationSeparatei.xml
+func (gl *GL) BlendEquationSeparatei(buf uint32, modeRGB, modeAlpha glbase.Enum) {
+ C.gl4_0core_glBlendEquationSeparatei(gl.funcs, C.GLuint(buf), C.GLenum(modeRGB), C.GLenum(modeAlpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendEquationi.xml
+func (gl *GL) BlendEquationi(buf uint32, mode glbase.Enum) {
+ C.gl4_0core_glBlendEquationi(gl.funcs, C.GLuint(buf), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMinSampleShading.xml
+func (gl *GL) MinSampleShading(value float32) {
+ C.gl4_0core_glMinSampleShading(gl.funcs, C.GLfloat(value))
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.1compat/funcs.cpp b/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.1compat/funcs.cpp
new file mode 100644
index 000000000..70ec9e7f3
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.1compat/funcs.cpp
@@ -0,0 +1,5286 @@
+
+// ** file automatically generated by glgen -- do not edit manually **
+
+#include <QOpenGLContext>
+#include <QtGui/qopenglfunctions_4_1_compatibility.h>
+
+#include "funcs.h"
+
+void *gl4_1compat_funcs() {
+ QOpenGLFunctions_4_1_Compatibility* funcs = QOpenGLContext::currentContext()->versionFunctions<QOpenGLFunctions_4_1_Compatibility>();
+ if (!funcs) {
+ return 0;
+ }
+ funcs->initializeOpenGLFunctions();
+ return funcs;
+}
+
+
+void gl4_1compat_glViewport(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glViewport(x, y, width, height);
+}
+
+void gl4_1compat_glDepthRange(void *_glfuncs, GLdouble nearVal, GLdouble farVal)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glDepthRange(nearVal, farVal);
+}
+
+GLboolean gl4_1compat_glIsEnabled(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsEnabled(cap);
+}
+
+void gl4_1compat_glGetTexLevelParameteriv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexLevelParameteriv(target, level, pname, params);
+}
+
+void gl4_1compat_glGetTexLevelParameterfv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexLevelParameterfv(target, level, pname, params);
+}
+
+void gl4_1compat_glGetTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexParameteriv(target, pname, params);
+}
+
+void gl4_1compat_glGetTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexParameterfv(target, pname, params);
+}
+
+void gl4_1compat_glGetTexImage(void *_glfuncs, GLenum target, GLint level, GLenum format, GLenum gltype, GLvoid* pixels)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexImage(target, level, format, gltype, pixels);
+}
+
+void gl4_1compat_glGetIntegerv(void *_glfuncs, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetIntegerv(pname, params);
+}
+
+void gl4_1compat_glGetFloatv(void *_glfuncs, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetFloatv(pname, params);
+}
+
+GLenum gl4_1compat_glGetError(void *_glfuncs)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ return _qglfuncs->glGetError();
+}
+
+void gl4_1compat_glGetDoublev(void *_glfuncs, GLenum pname, GLdouble* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetDoublev(pname, params);
+}
+
+void gl4_1compat_glGetBooleanv(void *_glfuncs, GLenum pname, GLboolean* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetBooleanv(pname, params);
+}
+
+void gl4_1compat_glReadPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum gltype, GLvoid* pixels)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glReadPixels(x, y, width, height, format, gltype, pixels);
+}
+
+void gl4_1compat_glReadBuffer(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glReadBuffer(mode);
+}
+
+void gl4_1compat_glPixelStorei(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glPixelStorei(pname, param);
+}
+
+void gl4_1compat_glPixelStoref(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glPixelStoref(pname, param);
+}
+
+void gl4_1compat_glDepthFunc(void *_glfuncs, GLenum glfunc)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glDepthFunc(glfunc);
+}
+
+void gl4_1compat_glStencilOp(void *_glfuncs, GLenum fail, GLenum zfail, GLenum zpass)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glStencilOp(fail, zfail, zpass);
+}
+
+void gl4_1compat_glStencilFunc(void *_glfuncs, GLenum glfunc, GLint ref, GLuint mask)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glStencilFunc(glfunc, ref, mask);
+}
+
+void gl4_1compat_glLogicOp(void *_glfuncs, GLenum opcode)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glLogicOp(opcode);
+}
+
+void gl4_1compat_glBlendFunc(void *_glfuncs, GLenum sfactor, GLenum dfactor)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glBlendFunc(sfactor, dfactor);
+}
+
+void gl4_1compat_glFlush(void *_glfuncs)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glFlush();
+}
+
+void gl4_1compat_glFinish(void *_glfuncs)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glFinish();
+}
+
+void gl4_1compat_glEnable(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glEnable(cap);
+}
+
+void gl4_1compat_glDisable(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glDisable(cap);
+}
+
+void gl4_1compat_glDepthMask(void *_glfuncs, GLboolean flag)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glDepthMask(flag);
+}
+
+void gl4_1compat_glColorMask(void *_glfuncs, GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorMask(red, green, blue, alpha);
+}
+
+void gl4_1compat_glStencilMask(void *_glfuncs, GLuint mask)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glStencilMask(mask);
+}
+
+void gl4_1compat_glClearDepth(void *_glfuncs, GLdouble depth)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glClearDepth(depth);
+}
+
+void gl4_1compat_glClearStencil(void *_glfuncs, GLint s)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glClearStencil(s);
+}
+
+void gl4_1compat_glClearColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glClearColor(red, green, blue, alpha);
+}
+
+void gl4_1compat_glClear(void *_glfuncs, GLbitfield mask)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glClear(mask);
+}
+
+void gl4_1compat_glDrawBuffer(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawBuffer(mode);
+}
+
+void gl4_1compat_glTexImage2D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexImage2D(target, level, internalFormat, width, height, border, format, gltype, pixels);
+}
+
+void gl4_1compat_glTexImage1D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexImage1D(target, level, internalFormat, width, border, format, gltype, pixels);
+}
+
+void gl4_1compat_glTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexParameteriv(target, pname, params);
+}
+
+void gl4_1compat_glTexParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexParameteri(target, pname, param);
+}
+
+void gl4_1compat_glTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexParameterfv(target, pname, params);
+}
+
+void gl4_1compat_glTexParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexParameterf(target, pname, param);
+}
+
+void gl4_1compat_glScissor(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glScissor(x, y, width, height);
+}
+
+void gl4_1compat_glPolygonMode(void *_glfuncs, GLenum face, GLenum mode)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glPolygonMode(face, mode);
+}
+
+void gl4_1compat_glPointSize(void *_glfuncs, GLfloat size)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glPointSize(size);
+}
+
+void gl4_1compat_glLineWidth(void *_glfuncs, GLfloat width)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glLineWidth(width);
+}
+
+void gl4_1compat_glHint(void *_glfuncs, GLenum target, GLenum mode)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glHint(target, mode);
+}
+
+void gl4_1compat_glFrontFace(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glFrontFace(mode);
+}
+
+void gl4_1compat_glCullFace(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glCullFace(mode);
+}
+
+void gl4_1compat_glIndexubv(void *_glfuncs, const GLubyte* c)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexubv(c);
+}
+
+void gl4_1compat_glIndexub(void *_glfuncs, GLubyte c)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexub(c);
+}
+
+GLboolean gl4_1compat_glIsTexture(void *_glfuncs, GLuint texture)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsTexture(texture);
+}
+
+void gl4_1compat_glGenTextures(void *_glfuncs, GLsizei n, GLuint* textures)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGenTextures(n, textures);
+}
+
+void gl4_1compat_glDeleteTextures(void *_glfuncs, GLsizei n, const GLuint* textures)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteTextures(n, textures);
+}
+
+void gl4_1compat_glBindTexture(void *_glfuncs, GLenum target, GLuint texture)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindTexture(target, texture);
+}
+
+void gl4_1compat_glTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexSubImage2D(target, level, xoffset, yoffset, width, height, format, gltype, pixels);
+}
+
+void gl4_1compat_glTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexSubImage1D(target, level, xoffset, width, format, gltype, pixels);
+}
+
+void gl4_1compat_glCopyTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage2D(target, level, xoffset, yoffset, x, y, width, height);
+}
+
+void gl4_1compat_glCopyTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage1D(target, level, xoffset, x, y, width);
+}
+
+void gl4_1compat_glCopyTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyTexImage2D(target, level, internalFormat, x, y, width, height, border);
+}
+
+void gl4_1compat_glCopyTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLint border)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyTexImage1D(target, level, internalFormat, x, y, width, border);
+}
+
+void gl4_1compat_glPolygonOffset(void *_glfuncs, GLfloat factor, GLfloat units)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glPolygonOffset(factor, units);
+}
+
+void gl4_1compat_glDrawElements(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawElements(mode, count, gltype, indices);
+}
+
+void gl4_1compat_glDrawArrays(void *_glfuncs, GLenum mode, GLint first, GLsizei count)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawArrays(mode, first, count);
+}
+
+void gl4_1compat_glCopyTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage3D(target, level, xoffset, yoffset, zoffset, x, y, width, height);
+}
+
+void gl4_1compat_glTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, gltype, pixels);
+}
+
+void gl4_1compat_glTexImage3D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexImage3D(target, level, internalFormat, width, height, depth, border, format, gltype, pixels);
+}
+
+void gl4_1compat_glDrawRangeElements(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawRangeElements(mode, start, end, count, gltype, indices);
+}
+
+void gl4_1compat_glBlendEquation(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glBlendEquation(mode);
+}
+
+void gl4_1compat_glBlendColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glBlendColor(red, green, blue, alpha);
+}
+
+void gl4_1compat_glGetCompressedTexImage(void *_glfuncs, GLenum target, GLint level, GLvoid* img)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetCompressedTexImage(target, level, img);
+}
+
+void gl4_1compat_glCompressedTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glCompressedTexSubImage1D(target, level, xoffset, width, format, imageSize, data);
+}
+
+void gl4_1compat_glCompressedTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glCompressedTexSubImage2D(target, level, xoffset, yoffset, width, height, format, imageSize, data);
+}
+
+void gl4_1compat_glCompressedTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glCompressedTexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, imageSize, data);
+}
+
+void gl4_1compat_glCompressedTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glCompressedTexImage1D(target, level, internalFormat, width, border, imageSize, data);
+}
+
+void gl4_1compat_glCompressedTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glCompressedTexImage2D(target, level, internalFormat, width, height, border, imageSize, data);
+}
+
+void gl4_1compat_glCompressedTexImage3D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glCompressedTexImage3D(target, level, internalFormat, width, height, depth, border, imageSize, data);
+}
+
+void gl4_1compat_glSampleCoverage(void *_glfuncs, GLfloat value, GLboolean invert)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glSampleCoverage(value, invert);
+}
+
+void gl4_1compat_glActiveTexture(void *_glfuncs, GLenum texture)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glActiveTexture(texture);
+}
+
+void gl4_1compat_glPointParameteriv(void *_glfuncs, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glPointParameteriv(pname, params);
+}
+
+void gl4_1compat_glPointParameteri(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glPointParameteri(pname, param);
+}
+
+void gl4_1compat_glPointParameterfv(void *_glfuncs, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glPointParameterfv(pname, params);
+}
+
+void gl4_1compat_glPointParameterf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glPointParameterf(pname, param);
+}
+
+void gl4_1compat_glMultiDrawArrays(void *_glfuncs, GLenum mode, const GLint* first, const GLsizei* count, GLsizei drawcount)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiDrawArrays(mode, first, count, drawcount);
+}
+
+void gl4_1compat_glBlendFuncSeparate(void *_glfuncs, GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glBlendFuncSeparate(sfactorRGB, dfactorRGB, sfactorAlpha, dfactorAlpha);
+}
+
+void gl4_1compat_glGetBufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetBufferParameteriv(target, pname, params);
+}
+
+GLboolean gl4_1compat_glUnmapBuffer(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ return _qglfuncs->glUnmapBuffer(target);
+}
+
+void gl4_1compat_glGetBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, GLvoid* data)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetBufferSubData(target, offset, size, data);
+}
+
+void gl4_1compat_glBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid* data)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glBufferSubData(target, offset, size, data);
+}
+
+void gl4_1compat_glBufferData(void *_glfuncs, GLenum target, GLsizeiptr size, const GLvoid* data, GLenum usage)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glBufferData(target, size, data, usage);
+}
+
+GLboolean gl4_1compat_glIsBuffer(void *_glfuncs, GLuint buffer)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsBuffer(buffer);
+}
+
+void gl4_1compat_glGenBuffers(void *_glfuncs, GLsizei n, GLuint* buffers)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGenBuffers(n, buffers);
+}
+
+void gl4_1compat_glDeleteBuffers(void *_glfuncs, GLsizei n, const GLuint* buffers)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteBuffers(n, buffers);
+}
+
+void gl4_1compat_glBindBuffer(void *_glfuncs, GLenum target, GLuint buffer)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindBuffer(target, buffer);
+}
+
+void gl4_1compat_glGetQueryObjectuiv(void *_glfuncs, GLuint id, GLenum pname, GLuint* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetQueryObjectuiv(id, pname, params);
+}
+
+void gl4_1compat_glGetQueryObjectiv(void *_glfuncs, GLuint id, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetQueryObjectiv(id, pname, params);
+}
+
+void gl4_1compat_glGetQueryiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetQueryiv(target, pname, params);
+}
+
+void gl4_1compat_glEndQuery(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glEndQuery(target);
+}
+
+void gl4_1compat_glBeginQuery(void *_glfuncs, GLenum target, GLuint id)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glBeginQuery(target, id);
+}
+
+GLboolean gl4_1compat_glIsQuery(void *_glfuncs, GLuint id)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsQuery(id);
+}
+
+void gl4_1compat_glDeleteQueries(void *_glfuncs, GLsizei n, const GLuint* ids)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteQueries(n, ids);
+}
+
+void gl4_1compat_glGenQueries(void *_glfuncs, GLsizei n, GLuint* ids)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGenQueries(n, ids);
+}
+
+void gl4_1compat_glVertexAttribPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLboolean normalized, GLsizei stride, const GLvoid* offset)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribPointer(index, size, gltype, normalized, stride, offset);
+}
+
+void gl4_1compat_glValidateProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glValidateProgram(program);
+}
+
+void gl4_1compat_glUniformMatrix4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4fv(location, count, transpose, value);
+}
+
+void gl4_1compat_glUniformMatrix3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3fv(location, count, transpose, value);
+}
+
+void gl4_1compat_glUniformMatrix2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2fv(location, count, transpose, value);
+}
+
+void gl4_1compat_glUniform4iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform4iv(location, count, value);
+}
+
+void gl4_1compat_glUniform3iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform3iv(location, count, value);
+}
+
+void gl4_1compat_glUniform2iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform2iv(location, count, value);
+}
+
+void gl4_1compat_glUniform1iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform1iv(location, count, value);
+}
+
+void gl4_1compat_glUniform4fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform4fv(location, count, value);
+}
+
+void gl4_1compat_glUniform3fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform3fv(location, count, value);
+}
+
+void gl4_1compat_glUniform2fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform2fv(location, count, value);
+}
+
+void gl4_1compat_glUniform1fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform1fv(location, count, value);
+}
+
+void gl4_1compat_glUniform4i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2, GLint v3)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform4i(location, v0, v1, v2, v3);
+}
+
+void gl4_1compat_glUniform3i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform3i(location, v0, v1, v2);
+}
+
+void gl4_1compat_glUniform2i(void *_glfuncs, GLint location, GLint v0, GLint v1)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform2i(location, v0, v1);
+}
+
+void gl4_1compat_glUniform1i(void *_glfuncs, GLint location, GLint v0)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform1i(location, v0);
+}
+
+void gl4_1compat_glUniform4f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform4f(location, v0, v1, v2, v3);
+}
+
+void gl4_1compat_glUniform3f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform3f(location, v0, v1, v2);
+}
+
+void gl4_1compat_glUniform2f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform2f(location, v0, v1);
+}
+
+void gl4_1compat_glUniform1f(void *_glfuncs, GLint location, GLfloat v0)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform1f(location, v0);
+}
+
+void gl4_1compat_glUseProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glUseProgram(program);
+}
+
+void gl4_1compat_glShaderSource(void *_glfuncs, GLuint shader, GLsizei count, const GLchar** source, const GLint* length)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glShaderSource(shader, count, source, length);
+}
+
+void gl4_1compat_glLinkProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glLinkProgram(program);
+}
+
+GLboolean gl4_1compat_glIsShader(void *_glfuncs, GLuint shader)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsShader(shader);
+}
+
+GLboolean gl4_1compat_glIsProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsProgram(program);
+}
+
+void gl4_1compat_glGetVertexAttribiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribiv(index, pname, params);
+}
+
+void gl4_1compat_glGetVertexAttribfv(void *_glfuncs, GLuint index, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribfv(index, pname, params);
+}
+
+void gl4_1compat_glGetVertexAttribdv(void *_glfuncs, GLuint index, GLenum pname, GLdouble* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribdv(index, pname, params);
+}
+
+void gl4_1compat_glGetUniformiv(void *_glfuncs, GLuint program, GLint location, GLint* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetUniformiv(program, location, params);
+}
+
+void gl4_1compat_glGetUniformfv(void *_glfuncs, GLuint program, GLint location, GLfloat* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetUniformfv(program, location, params);
+}
+
+GLint gl4_1compat_glGetUniformLocation(void *_glfuncs, GLuint program, const GLchar* name)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ return _qglfuncs->glGetUniformLocation(program, name);
+}
+
+void gl4_1compat_glGetShaderSource(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* source)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetShaderSource(shader, bufSize, length, source);
+}
+
+void gl4_1compat_glGetShaderInfoLog(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* infoLog)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetShaderInfoLog(shader, bufSize, length, infoLog);
+}
+
+void gl4_1compat_glGetShaderiv(void *_glfuncs, GLuint shader, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetShaderiv(shader, pname, params);
+}
+
+void gl4_1compat_glGetProgramInfoLog(void *_glfuncs, GLuint program, GLsizei bufSize, GLsizei* length, GLchar* infoLog)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetProgramInfoLog(program, bufSize, length, infoLog);
+}
+
+void gl4_1compat_glGetProgramiv(void *_glfuncs, GLuint program, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetProgramiv(program, pname, params);
+}
+
+GLint gl4_1compat_glGetAttribLocation(void *_glfuncs, GLuint program, const GLchar* name)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ return _qglfuncs->glGetAttribLocation(program, name);
+}
+
+void gl4_1compat_glGetAttachedShaders(void *_glfuncs, GLuint program, GLsizei maxCount, GLsizei* count, GLuint* obj)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetAttachedShaders(program, maxCount, count, obj);
+}
+
+void gl4_1compat_glGetActiveUniform(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetActiveUniform(program, index, bufSize, length, size, gltype, name);
+}
+
+void gl4_1compat_glGetActiveAttrib(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetActiveAttrib(program, index, bufSize, length, size, gltype, name);
+}
+
+void gl4_1compat_glEnableVertexAttribArray(void *_glfuncs, GLuint index)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glEnableVertexAttribArray(index);
+}
+
+void gl4_1compat_glDisableVertexAttribArray(void *_glfuncs, GLuint index)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glDisableVertexAttribArray(index);
+}
+
+void gl4_1compat_glDetachShader(void *_glfuncs, GLuint program, GLuint shader)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glDetachShader(program, shader);
+}
+
+void gl4_1compat_glDeleteShader(void *_glfuncs, GLuint shader)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteShader(shader);
+}
+
+void gl4_1compat_glDeleteProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteProgram(program);
+}
+
+GLuint gl4_1compat_glCreateShader(void *_glfuncs, GLenum gltype)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ return _qglfuncs->glCreateShader(gltype);
+}
+
+GLuint gl4_1compat_glCreateProgram(void *_glfuncs)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ return _qglfuncs->glCreateProgram();
+}
+
+void gl4_1compat_glCompileShader(void *_glfuncs, GLuint shader)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glCompileShader(shader);
+}
+
+void gl4_1compat_glBindAttribLocation(void *_glfuncs, GLuint program, GLuint index, const GLchar* name)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindAttribLocation(program, index, name);
+}
+
+void gl4_1compat_glAttachShader(void *_glfuncs, GLuint program, GLuint shader)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glAttachShader(program, shader);
+}
+
+void gl4_1compat_glStencilMaskSeparate(void *_glfuncs, GLenum face, GLuint mask)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glStencilMaskSeparate(face, mask);
+}
+
+void gl4_1compat_glStencilFuncSeparate(void *_glfuncs, GLenum face, GLenum glfunc, GLint ref, GLuint mask)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glStencilFuncSeparate(face, glfunc, ref, mask);
+}
+
+void gl4_1compat_glStencilOpSeparate(void *_glfuncs, GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glStencilOpSeparate(face, sfail, dpfail, dppass);
+}
+
+void gl4_1compat_glDrawBuffers(void *_glfuncs, GLsizei n, const GLenum* bufs)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawBuffers(n, bufs);
+}
+
+void gl4_1compat_glBlendEquationSeparate(void *_glfuncs, GLenum modeRGB, GLenum modeAlpha)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glBlendEquationSeparate(modeRGB, modeAlpha);
+}
+
+void gl4_1compat_glUniformMatrix4x3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4x3fv(location, count, transpose, value);
+}
+
+void gl4_1compat_glUniformMatrix3x4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3x4fv(location, count, transpose, value);
+}
+
+void gl4_1compat_glUniformMatrix4x2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4x2fv(location, count, transpose, value);
+}
+
+void gl4_1compat_glUniformMatrix2x4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2x4fv(location, count, transpose, value);
+}
+
+void gl4_1compat_glUniformMatrix3x2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3x2fv(location, count, transpose, value);
+}
+
+void gl4_1compat_glUniformMatrix2x3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2x3fv(location, count, transpose, value);
+}
+
+GLboolean gl4_1compat_glIsVertexArray(void *_glfuncs, GLuint array)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsVertexArray(array);
+}
+
+void gl4_1compat_glGenVertexArrays(void *_glfuncs, GLsizei n, GLuint* arrays)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGenVertexArrays(n, arrays);
+}
+
+void gl4_1compat_glDeleteVertexArrays(void *_glfuncs, GLsizei n, const GLuint* arrays)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteVertexArrays(n, arrays);
+}
+
+void gl4_1compat_glBindVertexArray(void *_glfuncs, GLuint array)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindVertexArray(array);
+}
+
+void gl4_1compat_glFlushMappedBufferRange(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr length)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glFlushMappedBufferRange(target, offset, length);
+}
+
+void gl4_1compat_glFramebufferTextureLayer(void *_glfuncs, GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glFramebufferTextureLayer(target, attachment, texture, level, layer);
+}
+
+void gl4_1compat_glRenderbufferStorageMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLenum internalFormat, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glRenderbufferStorageMultisample(target, samples, internalFormat, width, height);
+}
+
+void gl4_1compat_glBlitFramebuffer(void *_glfuncs, GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glBlitFramebuffer(srcX0, srcY0, srcX1, srcY1, dstX0, dstY0, dstX1, dstY1, mask, filter);
+}
+
+void gl4_1compat_glGenerateMipmap(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGenerateMipmap(target);
+}
+
+void gl4_1compat_glGetFramebufferAttachmentParameteriv(void *_glfuncs, GLenum target, GLenum attachment, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetFramebufferAttachmentParameteriv(target, attachment, pname, params);
+}
+
+void gl4_1compat_glFramebufferRenderbuffer(void *_glfuncs, GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glFramebufferRenderbuffer(target, attachment, renderbuffertarget, renderbuffer);
+}
+
+void gl4_1compat_glFramebufferTexture3D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glFramebufferTexture3D(target, attachment, textarget, texture, level, zoffset);
+}
+
+void gl4_1compat_glFramebufferTexture2D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glFramebufferTexture2D(target, attachment, textarget, texture, level);
+}
+
+void gl4_1compat_glFramebufferTexture1D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glFramebufferTexture1D(target, attachment, textarget, texture, level);
+}
+
+GLenum gl4_1compat_glCheckFramebufferStatus(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ return _qglfuncs->glCheckFramebufferStatus(target);
+}
+
+void gl4_1compat_glGenFramebuffers(void *_glfuncs, GLsizei n, GLuint* framebuffers)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGenFramebuffers(n, framebuffers);
+}
+
+void gl4_1compat_glDeleteFramebuffers(void *_glfuncs, GLsizei n, const GLuint* framebuffers)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteFramebuffers(n, framebuffers);
+}
+
+void gl4_1compat_glBindFramebuffer(void *_glfuncs, GLenum target, GLuint framebuffer)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindFramebuffer(target, framebuffer);
+}
+
+GLboolean gl4_1compat_glIsFramebuffer(void *_glfuncs, GLuint framebuffer)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsFramebuffer(framebuffer);
+}
+
+void gl4_1compat_glGetRenderbufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetRenderbufferParameteriv(target, pname, params);
+}
+
+void gl4_1compat_glRenderbufferStorage(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glRenderbufferStorage(target, internalFormat, width, height);
+}
+
+void gl4_1compat_glGenRenderbuffers(void *_glfuncs, GLsizei n, GLuint* renderbuffers)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGenRenderbuffers(n, renderbuffers);
+}
+
+void gl4_1compat_glDeleteRenderbuffers(void *_glfuncs, GLsizei n, const GLuint* renderbuffers)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteRenderbuffers(n, renderbuffers);
+}
+
+void gl4_1compat_glBindRenderbuffer(void *_glfuncs, GLenum target, GLuint renderbuffer)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindRenderbuffer(target, renderbuffer);
+}
+
+GLboolean gl4_1compat_glIsRenderbuffer(void *_glfuncs, GLuint renderbuffer)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsRenderbuffer(renderbuffer);
+}
+
+void gl4_1compat_glClearBufferfi(void *_glfuncs, GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glClearBufferfi(buffer, drawbuffer, depth, stencil);
+}
+
+void gl4_1compat_glClearBufferfv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLfloat* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glClearBufferfv(buffer, drawbuffer, value);
+}
+
+void gl4_1compat_glClearBufferuiv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLuint* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glClearBufferuiv(buffer, drawbuffer, value);
+}
+
+void gl4_1compat_glClearBufferiv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLint* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glClearBufferiv(buffer, drawbuffer, value);
+}
+
+void gl4_1compat_glGetTexParameterIuiv(void *_glfuncs, GLenum target, GLenum pname, GLuint* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexParameterIuiv(target, pname, params);
+}
+
+void gl4_1compat_glGetTexParameterIiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexParameterIiv(target, pname, params);
+}
+
+void gl4_1compat_glTexParameterIuiv(void *_glfuncs, GLenum target, GLenum pname, const GLuint* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexParameterIuiv(target, pname, params);
+}
+
+void gl4_1compat_glTexParameterIiv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexParameterIiv(target, pname, params);
+}
+
+void gl4_1compat_glUniform4uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform4uiv(location, count, value);
+}
+
+void gl4_1compat_glUniform3uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform3uiv(location, count, value);
+}
+
+void gl4_1compat_glUniform2uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform2uiv(location, count, value);
+}
+
+void gl4_1compat_glUniform1uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform1uiv(location, count, value);
+}
+
+void gl4_1compat_glUniform4ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform4ui(location, v0, v1, v2, v3);
+}
+
+void gl4_1compat_glUniform3ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1, GLuint v2)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform3ui(location, v0, v1, v2);
+}
+
+void gl4_1compat_glUniform2ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform2ui(location, v0, v1);
+}
+
+void gl4_1compat_glUniform1ui(void *_glfuncs, GLint location, GLuint v0)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform1ui(location, v0);
+}
+
+GLint gl4_1compat_glGetFragDataLocation(void *_glfuncs, GLuint program, const GLchar* name)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ return _qglfuncs->glGetFragDataLocation(program, name);
+}
+
+void gl4_1compat_glBindFragDataLocation(void *_glfuncs, GLuint program, GLuint color, const GLchar* name)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindFragDataLocation(program, color, name);
+}
+
+void gl4_1compat_glGetUniformuiv(void *_glfuncs, GLuint program, GLint location, GLuint* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetUniformuiv(program, location, params);
+}
+
+void gl4_1compat_glGetVertexAttribIuiv(void *_glfuncs, GLuint index, GLenum pname, GLuint* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribIuiv(index, pname, params);
+}
+
+void gl4_1compat_glGetVertexAttribIiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribIiv(index, pname, params);
+}
+
+void gl4_1compat_glVertexAttribIPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribIPointer(index, size, gltype, stride, pointer);
+}
+
+void gl4_1compat_glEndConditionalRender(void *_glfuncs)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glEndConditionalRender();
+}
+
+void gl4_1compat_glBeginConditionalRender(void *_glfuncs, GLuint id, GLenum mode)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glBeginConditionalRender(id, mode);
+}
+
+void gl4_1compat_glClampColor(void *_glfuncs, GLenum target, GLenum clamp)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glClampColor(target, clamp);
+}
+
+void gl4_1compat_glGetTransformFeedbackVarying(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLsizei* size, GLenum* gltype, GLchar* name)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTransformFeedbackVarying(program, index, bufSize, length, size, gltype, name);
+}
+
+void gl4_1compat_glBindBufferBase(void *_glfuncs, GLenum target, GLuint index, GLuint buffer)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindBufferBase(target, index, buffer);
+}
+
+void gl4_1compat_glBindBufferRange(void *_glfuncs, GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindBufferRange(target, index, buffer, offset, size);
+}
+
+void gl4_1compat_glEndTransformFeedback(void *_glfuncs)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glEndTransformFeedback();
+}
+
+void gl4_1compat_glBeginTransformFeedback(void *_glfuncs, GLenum primitiveMode)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glBeginTransformFeedback(primitiveMode);
+}
+
+GLboolean gl4_1compat_glIsEnabledi(void *_glfuncs, GLenum target, GLuint index)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsEnabledi(target, index);
+}
+
+void gl4_1compat_glDisablei(void *_glfuncs, GLenum target, GLuint index)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glDisablei(target, index);
+}
+
+void gl4_1compat_glEnablei(void *_glfuncs, GLenum target, GLuint index)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glEnablei(target, index);
+}
+
+void gl4_1compat_glGetIntegeri_v(void *_glfuncs, GLenum target, GLuint index, GLint* data)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetIntegeri_v(target, index, data);
+}
+
+void gl4_1compat_glGetBooleani_v(void *_glfuncs, GLenum target, GLuint index, GLboolean* data)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetBooleani_v(target, index, data);
+}
+
+void gl4_1compat_glColorMaski(void *_glfuncs, GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorMaski(index, r, g, b, a);
+}
+
+void gl4_1compat_glCopyBufferSubData(void *_glfuncs, GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyBufferSubData(readTarget, writeTarget, readOffset, writeOffset, size);
+}
+
+void gl4_1compat_glUniformBlockBinding(void *_glfuncs, GLuint program, GLuint v0, GLuint v1)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformBlockBinding(program, v0, v1);
+}
+
+void gl4_1compat_glGetActiveUniformBlockName(void *_glfuncs, GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei* length, GLchar* uniformBlockName)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetActiveUniformBlockName(program, uniformBlockIndex, bufSize, length, uniformBlockName);
+}
+
+void gl4_1compat_glGetActiveUniformBlockiv(void *_glfuncs, GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetActiveUniformBlockiv(program, uniformBlockIndex, pname, params);
+}
+
+GLuint gl4_1compat_glGetUniformBlockIndex(void *_glfuncs, GLuint program, const GLchar* uniformBlockName)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ return _qglfuncs->glGetUniformBlockIndex(program, uniformBlockName);
+}
+
+void gl4_1compat_glGetActiveUniformName(void *_glfuncs, GLuint program, GLuint uniformIndex, GLsizei bufSize, GLsizei* length, GLchar* uniformName)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetActiveUniformName(program, uniformIndex, bufSize, length, uniformName);
+}
+
+void gl4_1compat_glGetActiveUniformsiv(void *_glfuncs, GLuint program, GLsizei uniformCount, const GLuint* uniformIndices, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetActiveUniformsiv(program, uniformCount, uniformIndices, pname, params);
+}
+
+void gl4_1compat_glPrimitiveRestartIndex(void *_glfuncs, GLuint index)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glPrimitiveRestartIndex(index);
+}
+
+void gl4_1compat_glTexBuffer(void *_glfuncs, GLenum target, GLenum internalFormat, GLuint buffer)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexBuffer(target, internalFormat, buffer);
+}
+
+void gl4_1compat_glDrawElementsInstanced(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawElementsInstanced(mode, count, gltype, indices, instancecount);
+}
+
+void gl4_1compat_glDrawArraysInstanced(void *_glfuncs, GLenum mode, GLint first, GLsizei count, GLsizei instancecount)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawArraysInstanced(mode, first, count, instancecount);
+}
+
+void gl4_1compat_glSampleMaski(void *_glfuncs, GLuint index, GLbitfield mask)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glSampleMaski(index, mask);
+}
+
+void gl4_1compat_glGetMultisamplefv(void *_glfuncs, GLenum pname, GLuint index, GLfloat* val)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetMultisamplefv(pname, index, val);
+}
+
+void gl4_1compat_glTexImage3DMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexImage3DMultisample(target, samples, internalFormat, width, height, depth, fixedsamplelocations);
+}
+
+void gl4_1compat_glTexImage2DMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLint internalFormat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexImage2DMultisample(target, samples, internalFormat, width, height, fixedsamplelocations);
+}
+
+void gl4_1compat_glGetSynciv(void *_glfuncs, GLsync sync, GLenum pname, GLsizei bufSize, GLsizei* length, GLint* values)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetSynciv(sync, pname, bufSize, length, values);
+}
+
+void gl4_1compat_glGetInteger64v(void *_glfuncs, GLenum pname, GLint64* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetInteger64v(pname, params);
+}
+
+void gl4_1compat_glWaitSync(void *_glfuncs, GLsync sync, GLbitfield flags, GLuint64 timeout)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glWaitSync(sync, flags, timeout);
+}
+
+GLenum gl4_1compat_glClientWaitSync(void *_glfuncs, GLsync sync, GLbitfield flags, GLuint64 timeout)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ return _qglfuncs->glClientWaitSync(sync, flags, timeout);
+}
+
+void gl4_1compat_glDeleteSync(void *_glfuncs, GLsync sync)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteSync(sync);
+}
+
+GLboolean gl4_1compat_glIsSync(void *_glfuncs, GLsync sync)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsSync(sync);
+}
+
+GLsync gl4_1compat_glFenceSync(void *_glfuncs, GLenum condition, GLbitfield flags)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ return _qglfuncs->glFenceSync(condition, flags);
+}
+
+void gl4_1compat_glProvokingVertex(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glProvokingVertex(mode);
+}
+
+void gl4_1compat_glDrawElementsInstancedBaseVertex(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount, GLint basevertex)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawElementsInstancedBaseVertex(mode, count, gltype, indices, instancecount, basevertex);
+}
+
+void gl4_1compat_glDrawRangeElementsBaseVertex(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices, GLint basevertex)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawRangeElementsBaseVertex(mode, start, end, count, gltype, indices, basevertex);
+}
+
+void gl4_1compat_glDrawElementsBaseVertex(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLint basevertex)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawElementsBaseVertex(mode, count, gltype, indices, basevertex);
+}
+
+void gl4_1compat_glFramebufferTexture(void *_glfuncs, GLenum target, GLenum attachment, GLuint texture, GLint level)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glFramebufferTexture(target, attachment, texture, level);
+}
+
+void gl4_1compat_glGetBufferParameteri64v(void *_glfuncs, GLenum target, GLenum pname, GLint64* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetBufferParameteri64v(target, pname, params);
+}
+
+void gl4_1compat_glGetInteger64i_v(void *_glfuncs, GLenum target, GLuint index, GLint64* data)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetInteger64i_v(target, index, data);
+}
+
+void gl4_1compat_glVertexAttribP4uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribP4uiv(index, gltype, normalized, value);
+}
+
+void gl4_1compat_glVertexAttribP4ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribP4ui(index, gltype, normalized, value);
+}
+
+void gl4_1compat_glVertexAttribP3uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribP3uiv(index, gltype, normalized, value);
+}
+
+void gl4_1compat_glVertexAttribP3ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribP3ui(index, gltype, normalized, value);
+}
+
+void gl4_1compat_glVertexAttribP2uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribP2uiv(index, gltype, normalized, value);
+}
+
+void gl4_1compat_glVertexAttribP2ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribP2ui(index, gltype, normalized, value);
+}
+
+void gl4_1compat_glVertexAttribP1uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribP1uiv(index, gltype, normalized, value);
+}
+
+void gl4_1compat_glVertexAttribP1ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribP1ui(index, gltype, normalized, value);
+}
+
+void gl4_1compat_glSecondaryColorP3uiv(void *_glfuncs, GLenum gltype, const GLuint* color)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColorP3uiv(gltype, color);
+}
+
+void gl4_1compat_glSecondaryColorP3ui(void *_glfuncs, GLenum gltype, GLuint color)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColorP3ui(gltype, color);
+}
+
+void gl4_1compat_glColorP4uiv(void *_glfuncs, GLenum gltype, const GLuint* color)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorP4uiv(gltype, color);
+}
+
+void gl4_1compat_glColorP4ui(void *_glfuncs, GLenum gltype, GLuint color)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorP4ui(gltype, color);
+}
+
+void gl4_1compat_glColorP3uiv(void *_glfuncs, GLenum gltype, const GLuint* color)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorP3uiv(gltype, color);
+}
+
+void gl4_1compat_glColorP3ui(void *_glfuncs, GLenum gltype, GLuint color)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorP3ui(gltype, color);
+}
+
+void gl4_1compat_glNormalP3uiv(void *_glfuncs, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormalP3uiv(gltype, coords);
+}
+
+void gl4_1compat_glNormalP3ui(void *_glfuncs, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormalP3ui(gltype, coords);
+}
+
+void gl4_1compat_glMultiTexCoordP4uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP4uiv(texture, gltype, coords);
+}
+
+void gl4_1compat_glMultiTexCoordP4ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP4ui(texture, gltype, coords);
+}
+
+void gl4_1compat_glMultiTexCoordP3uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP3uiv(texture, gltype, coords);
+}
+
+void gl4_1compat_glMultiTexCoordP3ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP3ui(texture, gltype, coords);
+}
+
+void gl4_1compat_glMultiTexCoordP2uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP2uiv(texture, gltype, coords);
+}
+
+void gl4_1compat_glMultiTexCoordP2ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP2ui(texture, gltype, coords);
+}
+
+void gl4_1compat_glMultiTexCoordP1uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP1uiv(texture, gltype, coords);
+}
+
+void gl4_1compat_glMultiTexCoordP1ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP1ui(texture, gltype, coords);
+}
+
+void gl4_1compat_glTexCoordP4uiv(void *_glfuncs, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoordP4uiv(gltype, coords);
+}
+
+void gl4_1compat_glTexCoordP4ui(void *_glfuncs, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoordP4ui(gltype, coords);
+}
+
+void gl4_1compat_glTexCoordP3uiv(void *_glfuncs, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoordP3uiv(gltype, coords);
+}
+
+void gl4_1compat_glTexCoordP3ui(void *_glfuncs, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoordP3ui(gltype, coords);
+}
+
+void gl4_1compat_glTexCoordP2uiv(void *_glfuncs, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoordP2uiv(gltype, coords);
+}
+
+void gl4_1compat_glTexCoordP2ui(void *_glfuncs, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoordP2ui(gltype, coords);
+}
+
+void gl4_1compat_glTexCoordP1uiv(void *_glfuncs, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoordP1uiv(gltype, coords);
+}
+
+void gl4_1compat_glTexCoordP1ui(void *_glfuncs, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoordP1ui(gltype, coords);
+}
+
+void gl4_1compat_glVertexP4uiv(void *_glfuncs, GLenum gltype, const GLuint* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexP4uiv(gltype, value);
+}
+
+void gl4_1compat_glVertexP4ui(void *_glfuncs, GLenum gltype, GLuint value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexP4ui(gltype, value);
+}
+
+void gl4_1compat_glVertexP3uiv(void *_glfuncs, GLenum gltype, const GLuint* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexP3uiv(gltype, value);
+}
+
+void gl4_1compat_glVertexP3ui(void *_glfuncs, GLenum gltype, GLuint value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexP3ui(gltype, value);
+}
+
+void gl4_1compat_glVertexP2uiv(void *_glfuncs, GLenum gltype, const GLuint* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexP2uiv(gltype, value);
+}
+
+void gl4_1compat_glVertexP2ui(void *_glfuncs, GLenum gltype, GLuint value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexP2ui(gltype, value);
+}
+
+void gl4_1compat_glGetQueryObjectui64v(void *_glfuncs, GLuint id, GLenum pname, GLuint64* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetQueryObjectui64v(id, pname, params);
+}
+
+void gl4_1compat_glGetQueryObjecti64v(void *_glfuncs, GLuint id, GLenum pname, GLint64* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetQueryObjecti64v(id, pname, params);
+}
+
+void gl4_1compat_glQueryCounter(void *_glfuncs, GLuint id, GLenum target)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glQueryCounter(id, target);
+}
+
+void gl4_1compat_glGetSamplerParameterIuiv(void *_glfuncs, GLuint sampler, GLenum pname, GLuint* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetSamplerParameterIuiv(sampler, pname, params);
+}
+
+void gl4_1compat_glGetSamplerParameterfv(void *_glfuncs, GLuint sampler, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetSamplerParameterfv(sampler, pname, params);
+}
+
+void gl4_1compat_glGetSamplerParameterIiv(void *_glfuncs, GLuint sampler, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetSamplerParameterIiv(sampler, pname, params);
+}
+
+void gl4_1compat_glGetSamplerParameteriv(void *_glfuncs, GLuint sampler, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetSamplerParameteriv(sampler, pname, params);
+}
+
+void gl4_1compat_glSamplerParameterIuiv(void *_glfuncs, GLuint sampler, GLenum pname, const GLuint* param)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glSamplerParameterIuiv(sampler, pname, param);
+}
+
+void gl4_1compat_glSamplerParameterIiv(void *_glfuncs, GLuint sampler, GLenum pname, const GLint* param)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glSamplerParameterIiv(sampler, pname, param);
+}
+
+void gl4_1compat_glSamplerParameterfv(void *_glfuncs, GLuint sampler, GLenum pname, const GLfloat* param)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glSamplerParameterfv(sampler, pname, param);
+}
+
+void gl4_1compat_glSamplerParameterf(void *_glfuncs, GLuint sampler, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glSamplerParameterf(sampler, pname, param);
+}
+
+void gl4_1compat_glSamplerParameteriv(void *_glfuncs, GLuint sampler, GLenum pname, const GLint* param)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glSamplerParameteriv(sampler, pname, param);
+}
+
+void gl4_1compat_glSamplerParameteri(void *_glfuncs, GLuint sampler, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glSamplerParameteri(sampler, pname, param);
+}
+
+void gl4_1compat_glBindSampler(void *_glfuncs, GLuint unit, GLuint sampler)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindSampler(unit, sampler);
+}
+
+GLboolean gl4_1compat_glIsSampler(void *_glfuncs, GLuint sampler)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsSampler(sampler);
+}
+
+void gl4_1compat_glDeleteSamplers(void *_glfuncs, GLsizei count, const GLuint* samplers)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteSamplers(count, samplers);
+}
+
+void gl4_1compat_glGenSamplers(void *_glfuncs, GLsizei count, GLuint* samplers)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGenSamplers(count, samplers);
+}
+
+GLint gl4_1compat_glGetFragDataIndex(void *_glfuncs, GLuint program, const GLchar* name)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ return _qglfuncs->glGetFragDataIndex(program, name);
+}
+
+void gl4_1compat_glBindFragDataLocationIndexed(void *_glfuncs, GLuint program, GLuint colorNumber, GLuint index, const GLchar* name)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindFragDataLocationIndexed(program, colorNumber, index, name);
+}
+
+void gl4_1compat_glVertexAttribDivisor(void *_glfuncs, GLuint index, GLuint divisor)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribDivisor(index, divisor);
+}
+
+void gl4_1compat_glGetQueryIndexediv(void *_glfuncs, GLenum target, GLuint index, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetQueryIndexediv(target, index, pname, params);
+}
+
+void gl4_1compat_glEndQueryIndexed(void *_glfuncs, GLenum target, GLuint index)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glEndQueryIndexed(target, index);
+}
+
+void gl4_1compat_glBeginQueryIndexed(void *_glfuncs, GLenum target, GLuint index, GLuint id)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glBeginQueryIndexed(target, index, id);
+}
+
+void gl4_1compat_glDrawTransformFeedbackStream(void *_glfuncs, GLenum mode, GLuint id, GLuint stream)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawTransformFeedbackStream(mode, id, stream);
+}
+
+void gl4_1compat_glDrawTransformFeedback(void *_glfuncs, GLenum mode, GLuint id)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawTransformFeedback(mode, id);
+}
+
+void gl4_1compat_glResumeTransformFeedback(void *_glfuncs)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glResumeTransformFeedback();
+}
+
+void gl4_1compat_glPauseTransformFeedback(void *_glfuncs)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glPauseTransformFeedback();
+}
+
+GLboolean gl4_1compat_glIsTransformFeedback(void *_glfuncs, GLuint id)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsTransformFeedback(id);
+}
+
+void gl4_1compat_glGenTransformFeedbacks(void *_glfuncs, GLsizei n, GLuint* ids)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGenTransformFeedbacks(n, ids);
+}
+
+void gl4_1compat_glDeleteTransformFeedbacks(void *_glfuncs, GLsizei n, const GLuint* ids)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteTransformFeedbacks(n, ids);
+}
+
+void gl4_1compat_glBindTransformFeedback(void *_glfuncs, GLenum target, GLuint id)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindTransformFeedback(target, id);
+}
+
+void gl4_1compat_glPatchParameterfv(void *_glfuncs, GLenum pname, const GLfloat* values)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glPatchParameterfv(pname, values);
+}
+
+void gl4_1compat_glPatchParameteri(void *_glfuncs, GLenum pname, GLint value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glPatchParameteri(pname, value);
+}
+
+void gl4_1compat_glGetProgramStageiv(void *_glfuncs, GLuint program, GLenum shadertype, GLenum pname, GLint* values)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetProgramStageiv(program, shadertype, pname, values);
+}
+
+void gl4_1compat_glGetUniformSubroutineuiv(void *_glfuncs, GLenum shadertype, GLint location, GLuint* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetUniformSubroutineuiv(shadertype, location, params);
+}
+
+void gl4_1compat_glUniformSubroutinesuiv(void *_glfuncs, GLenum shadertype, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformSubroutinesuiv(shadertype, count, value);
+}
+
+void gl4_1compat_glGetActiveSubroutineName(void *_glfuncs, GLuint program, GLenum shadertype, GLuint index, GLsizei bufSize, GLsizei* length, GLchar* name)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetActiveSubroutineName(program, shadertype, index, bufSize, length, name);
+}
+
+void gl4_1compat_glGetActiveSubroutineUniformName(void *_glfuncs, GLuint program, GLenum shadertype, GLuint index, GLsizei bufSize, GLsizei* length, GLchar* name)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetActiveSubroutineUniformName(program, shadertype, index, bufSize, length, name);
+}
+
+void gl4_1compat_glGetActiveSubroutineUniformiv(void *_glfuncs, GLuint program, GLenum shadertype, GLuint index, GLenum pname, GLint* values)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetActiveSubroutineUniformiv(program, shadertype, index, pname, values);
+}
+
+GLuint gl4_1compat_glGetSubroutineIndex(void *_glfuncs, GLuint program, GLenum shadertype, const GLchar* name)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ return _qglfuncs->glGetSubroutineIndex(program, shadertype, name);
+}
+
+GLint gl4_1compat_glGetSubroutineUniformLocation(void *_glfuncs, GLuint program, GLenum shadertype, const GLchar* name)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ return _qglfuncs->glGetSubroutineUniformLocation(program, shadertype, name);
+}
+
+void gl4_1compat_glGetUniformdv(void *_glfuncs, GLuint program, GLint location, GLdouble* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetUniformdv(program, location, params);
+}
+
+void gl4_1compat_glUniformMatrix4x3dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4x3dv(location, count, transpose, value);
+}
+
+void gl4_1compat_glUniformMatrix4x2dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4x2dv(location, count, transpose, value);
+}
+
+void gl4_1compat_glUniformMatrix3x4dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3x4dv(location, count, transpose, value);
+}
+
+void gl4_1compat_glUniformMatrix3x2dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3x2dv(location, count, transpose, value);
+}
+
+void gl4_1compat_glUniformMatrix2x4dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2x4dv(location, count, transpose, value);
+}
+
+void gl4_1compat_glUniformMatrix2x3dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2x3dv(location, count, transpose, value);
+}
+
+void gl4_1compat_glUniformMatrix4dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4dv(location, count, transpose, value);
+}
+
+void gl4_1compat_glUniformMatrix3dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3dv(location, count, transpose, value);
+}
+
+void gl4_1compat_glUniformMatrix2dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2dv(location, count, transpose, value);
+}
+
+void gl4_1compat_glUniform4dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform4dv(location, count, value);
+}
+
+void gl4_1compat_glUniform3dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform3dv(location, count, value);
+}
+
+void gl4_1compat_glUniform2dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform2dv(location, count, value);
+}
+
+void gl4_1compat_glUniform1dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform1dv(location, count, value);
+}
+
+void gl4_1compat_glUniform4d(void *_glfuncs, GLint location, GLdouble v0, GLdouble v1, GLdouble v2, GLdouble v3)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform4d(location, v0, v1, v2, v3);
+}
+
+void gl4_1compat_glUniform3d(void *_glfuncs, GLint location, GLdouble v0, GLdouble v1, GLdouble v2)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform3d(location, v0, v1, v2);
+}
+
+void gl4_1compat_glUniform2d(void *_glfuncs, GLint location, GLdouble v0, GLdouble v1)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform2d(location, v0, v1);
+}
+
+void gl4_1compat_glUniform1d(void *_glfuncs, GLint location, GLdouble v0)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform1d(location, v0);
+}
+
+void gl4_1compat_glDrawElementsIndirect(void *_glfuncs, GLenum mode, GLenum gltype, const GLvoid* indirect)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawElementsIndirect(mode, gltype, indirect);
+}
+
+void gl4_1compat_glDrawArraysIndirect(void *_glfuncs, GLenum mode, const GLvoid* indirect)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawArraysIndirect(mode, indirect);
+}
+
+void gl4_1compat_glBlendFuncSeparatei(void *_glfuncs, GLuint buf, GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha, GLenum dstAlpha)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glBlendFuncSeparatei(buf, srcRGB, dstRGB, srcAlpha, dstAlpha);
+}
+
+void gl4_1compat_glBlendFunci(void *_glfuncs, GLuint buf, GLenum src, GLenum dst)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glBlendFunci(buf, src, dst);
+}
+
+void gl4_1compat_glBlendEquationSeparatei(void *_glfuncs, GLuint buf, GLenum modeRGB, GLenum modeAlpha)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glBlendEquationSeparatei(buf, modeRGB, modeAlpha);
+}
+
+void gl4_1compat_glBlendEquationi(void *_glfuncs, GLuint buf, GLenum mode)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glBlendEquationi(buf, mode);
+}
+
+void gl4_1compat_glMinSampleShading(void *_glfuncs, GLfloat value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glMinSampleShading(value);
+}
+
+void gl4_1compat_glGetDoublei_v(void *_glfuncs, GLenum target, GLuint index, GLdouble* data)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetDoublei_v(target, index, data);
+}
+
+void gl4_1compat_glGetFloati_v(void *_glfuncs, GLenum target, GLuint index, GLfloat* data)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetFloati_v(target, index, data);
+}
+
+void gl4_1compat_glDepthRangeIndexed(void *_glfuncs, GLuint index, GLdouble n, GLdouble f)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glDepthRangeIndexed(index, n, f);
+}
+
+void gl4_1compat_glDepthRangeArrayv(void *_glfuncs, GLuint first, GLsizei count, const GLdouble* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glDepthRangeArrayv(first, count, v);
+}
+
+void gl4_1compat_glScissorIndexedv(void *_glfuncs, GLuint index, const GLint* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glScissorIndexedv(index, v);
+}
+
+void gl4_1compat_glScissorIndexed(void *_glfuncs, GLuint index, GLint left, GLint bottom, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glScissorIndexed(index, left, bottom, width, height);
+}
+
+void gl4_1compat_glScissorArrayv(void *_glfuncs, GLuint first, GLsizei count, const GLint* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glScissorArrayv(first, count, v);
+}
+
+void gl4_1compat_glViewportIndexedfv(void *_glfuncs, GLuint index, const GLfloat* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glViewportIndexedfv(index, v);
+}
+
+void gl4_1compat_glViewportIndexedf(void *_glfuncs, GLuint index, GLfloat x, GLfloat y, GLfloat w, GLfloat h)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glViewportIndexedf(index, x, y, w, h);
+}
+
+void gl4_1compat_glViewportArrayv(void *_glfuncs, GLuint first, GLsizei count, const GLfloat* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glViewportArrayv(first, count, v);
+}
+
+void gl4_1compat_glGetVertexAttribLdv(void *_glfuncs, GLuint index, GLenum pname, GLdouble* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribLdv(index, pname, params);
+}
+
+void gl4_1compat_glVertexAttribLPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribLPointer(index, size, gltype, stride, pointer);
+}
+
+void gl4_1compat_glVertexAttribL4dv(void *_glfuncs, GLuint index, const GLdouble* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribL4dv(index, v);
+}
+
+void gl4_1compat_glVertexAttribL3dv(void *_glfuncs, GLuint index, const GLdouble* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribL3dv(index, v);
+}
+
+void gl4_1compat_glVertexAttribL2dv(void *_glfuncs, GLuint index, const GLdouble* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribL2dv(index, v);
+}
+
+void gl4_1compat_glVertexAttribL1dv(void *_glfuncs, GLuint index, const GLdouble* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribL1dv(index, v);
+}
+
+void gl4_1compat_glVertexAttribL4d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribL4d(index, x, y, z, w);
+}
+
+void gl4_1compat_glVertexAttribL3d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribL3d(index, x, y, z);
+}
+
+void gl4_1compat_glVertexAttribL2d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribL2d(index, x, y);
+}
+
+void gl4_1compat_glVertexAttribL1d(void *_glfuncs, GLuint index, GLdouble x)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribL1d(index, x);
+}
+
+void gl4_1compat_glGetProgramPipelineInfoLog(void *_glfuncs, GLuint pipeline, GLsizei bufSize, GLsizei* length, GLchar* infoLog)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetProgramPipelineInfoLog(pipeline, bufSize, length, infoLog);
+}
+
+void gl4_1compat_glValidateProgramPipeline(void *_glfuncs, GLuint pipeline)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glValidateProgramPipeline(pipeline);
+}
+
+void gl4_1compat_glProgramUniformMatrix4x3dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix4x3dv(program, location, count, transpose, value);
+}
+
+void gl4_1compat_glProgramUniformMatrix3x4dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix3x4dv(program, location, count, transpose, value);
+}
+
+void gl4_1compat_glProgramUniformMatrix4x2dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix4x2dv(program, location, count, transpose, value);
+}
+
+void gl4_1compat_glProgramUniformMatrix2x4dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix2x4dv(program, location, count, transpose, value);
+}
+
+void gl4_1compat_glProgramUniformMatrix3x2dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix3x2dv(program, location, count, transpose, value);
+}
+
+void gl4_1compat_glProgramUniformMatrix2x3dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix2x3dv(program, location, count, transpose, value);
+}
+
+void gl4_1compat_glProgramUniformMatrix4x3fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix4x3fv(program, location, count, transpose, value);
+}
+
+void gl4_1compat_glProgramUniformMatrix3x4fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix3x4fv(program, location, count, transpose, value);
+}
+
+void gl4_1compat_glProgramUniformMatrix4x2fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix4x2fv(program, location, count, transpose, value);
+}
+
+void gl4_1compat_glProgramUniformMatrix2x4fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix2x4fv(program, location, count, transpose, value);
+}
+
+void gl4_1compat_glProgramUniformMatrix3x2fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix3x2fv(program, location, count, transpose, value);
+}
+
+void gl4_1compat_glProgramUniformMatrix2x3fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix2x3fv(program, location, count, transpose, value);
+}
+
+void gl4_1compat_glProgramUniformMatrix4dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix4dv(program, location, count, transpose, value);
+}
+
+void gl4_1compat_glProgramUniformMatrix3dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix3dv(program, location, count, transpose, value);
+}
+
+void gl4_1compat_glProgramUniformMatrix2dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix2dv(program, location, count, transpose, value);
+}
+
+void gl4_1compat_glProgramUniformMatrix4fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix4fv(program, location, count, transpose, value);
+}
+
+void gl4_1compat_glProgramUniformMatrix3fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix3fv(program, location, count, transpose, value);
+}
+
+void gl4_1compat_glProgramUniformMatrix2fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix2fv(program, location, count, transpose, value);
+}
+
+void gl4_1compat_glProgramUniform4uiv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform4uiv(program, location, count, value);
+}
+
+void gl4_1compat_glProgramUniform4ui(void *_glfuncs, GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform4ui(program, location, v0, v1, v2, v3);
+}
+
+void gl4_1compat_glProgramUniform4dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLdouble* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform4dv(program, location, count, value);
+}
+
+void gl4_1compat_glProgramUniform4d(void *_glfuncs, GLuint program, GLint location, GLdouble v0, GLdouble v1, GLdouble v2, GLdouble v3)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform4d(program, location, v0, v1, v2, v3);
+}
+
+void gl4_1compat_glProgramUniform4fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform4fv(program, location, count, value);
+}
+
+void gl4_1compat_glProgramUniform4f(void *_glfuncs, GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform4f(program, location, v0, v1, v2, v3);
+}
+
+void gl4_1compat_glProgramUniform4iv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform4iv(program, location, count, value);
+}
+
+void gl4_1compat_glProgramUniform4i(void *_glfuncs, GLuint program, GLint location, GLint v0, GLint v1, GLint v2, GLint v3)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform4i(program, location, v0, v1, v2, v3);
+}
+
+void gl4_1compat_glProgramUniform3uiv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform3uiv(program, location, count, value);
+}
+
+void gl4_1compat_glProgramUniform3ui(void *_glfuncs, GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform3ui(program, location, v0, v1, v2);
+}
+
+void gl4_1compat_glProgramUniform3dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLdouble* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform3dv(program, location, count, value);
+}
+
+void gl4_1compat_glProgramUniform3d(void *_glfuncs, GLuint program, GLint location, GLdouble v0, GLdouble v1, GLdouble v2)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform3d(program, location, v0, v1, v2);
+}
+
+void gl4_1compat_glProgramUniform3fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform3fv(program, location, count, value);
+}
+
+void gl4_1compat_glProgramUniform3f(void *_glfuncs, GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform3f(program, location, v0, v1, v2);
+}
+
+void gl4_1compat_glProgramUniform3iv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform3iv(program, location, count, value);
+}
+
+void gl4_1compat_glProgramUniform3i(void *_glfuncs, GLuint program, GLint location, GLint v0, GLint v1, GLint v2)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform3i(program, location, v0, v1, v2);
+}
+
+void gl4_1compat_glProgramUniform2uiv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform2uiv(program, location, count, value);
+}
+
+void gl4_1compat_glProgramUniform2ui(void *_glfuncs, GLuint program, GLint location, GLuint v0, GLuint v1)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform2ui(program, location, v0, v1);
+}
+
+void gl4_1compat_glProgramUniform2dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLdouble* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform2dv(program, location, count, value);
+}
+
+void gl4_1compat_glProgramUniform2d(void *_glfuncs, GLuint program, GLint location, GLdouble v0, GLdouble v1)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform2d(program, location, v0, v1);
+}
+
+void gl4_1compat_glProgramUniform2fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform2fv(program, location, count, value);
+}
+
+void gl4_1compat_glProgramUniform2f(void *_glfuncs, GLuint program, GLint location, GLfloat v0, GLfloat v1)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform2f(program, location, v0, v1);
+}
+
+void gl4_1compat_glProgramUniform2iv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform2iv(program, location, count, value);
+}
+
+void gl4_1compat_glProgramUniform2i(void *_glfuncs, GLuint program, GLint location, GLint v0, GLint v1)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform2i(program, location, v0, v1);
+}
+
+void gl4_1compat_glProgramUniform1uiv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform1uiv(program, location, count, value);
+}
+
+void gl4_1compat_glProgramUniform1ui(void *_glfuncs, GLuint program, GLint location, GLuint v0)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform1ui(program, location, v0);
+}
+
+void gl4_1compat_glProgramUniform1dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLdouble* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform1dv(program, location, count, value);
+}
+
+void gl4_1compat_glProgramUniform1d(void *_glfuncs, GLuint program, GLint location, GLdouble v0)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform1d(program, location, v0);
+}
+
+void gl4_1compat_glProgramUniform1fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform1fv(program, location, count, value);
+}
+
+void gl4_1compat_glProgramUniform1f(void *_glfuncs, GLuint program, GLint location, GLfloat v0)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform1f(program, location, v0);
+}
+
+void gl4_1compat_glProgramUniform1iv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform1iv(program, location, count, value);
+}
+
+void gl4_1compat_glProgramUniform1i(void *_glfuncs, GLuint program, GLint location, GLint v0)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform1i(program, location, v0);
+}
+
+void gl4_1compat_glGetProgramPipelineiv(void *_glfuncs, GLuint pipeline, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetProgramPipelineiv(pipeline, pname, params);
+}
+
+GLboolean gl4_1compat_glIsProgramPipeline(void *_glfuncs, GLuint pipeline)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsProgramPipeline(pipeline);
+}
+
+void gl4_1compat_glGenProgramPipelines(void *_glfuncs, GLsizei n, GLuint* pipelines)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGenProgramPipelines(n, pipelines);
+}
+
+void gl4_1compat_glDeleteProgramPipelines(void *_glfuncs, GLsizei n, const GLuint* pipelines)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteProgramPipelines(n, pipelines);
+}
+
+void gl4_1compat_glBindProgramPipeline(void *_glfuncs, GLuint pipeline)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindProgramPipeline(pipeline);
+}
+
+void gl4_1compat_glActiveShaderProgram(void *_glfuncs, GLuint pipeline, GLuint program)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glActiveShaderProgram(pipeline, program);
+}
+
+void gl4_1compat_glUseProgramStages(void *_glfuncs, GLuint pipeline, GLbitfield stages, GLuint program)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glUseProgramStages(pipeline, stages, program);
+}
+
+void gl4_1compat_glProgramParameteri(void *_glfuncs, GLuint program, GLenum pname, GLint value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramParameteri(program, pname, value);
+}
+
+void gl4_1compat_glProgramBinary(void *_glfuncs, GLuint program, GLenum binaryFormat, const GLvoid* binary, GLsizei length)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramBinary(program, binaryFormat, binary, length);
+}
+
+void gl4_1compat_glGetProgramBinary(void *_glfuncs, GLuint program, GLsizei bufSize, GLsizei* length, GLenum* binaryFormat, GLvoid* binary)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetProgramBinary(program, bufSize, length, binaryFormat, binary);
+}
+
+void gl4_1compat_glClearDepthf(void *_glfuncs, GLfloat dd)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glClearDepthf(dd);
+}
+
+void gl4_1compat_glDepthRangef(void *_glfuncs, GLfloat n, GLfloat f)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glDepthRangef(n, f);
+}
+
+void gl4_1compat_glGetShaderPrecisionFormat(void *_glfuncs, GLenum shadertype, GLenum precisionType, GLint* range_, GLint* precision)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetShaderPrecisionFormat(shadertype, precisionType, range_, precision);
+}
+
+void gl4_1compat_glShaderBinary(void *_glfuncs, GLsizei count, const GLuint* shaders, GLenum binaryFormat, const GLvoid* binary, GLsizei length)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glShaderBinary(count, shaders, binaryFormat, binary, length);
+}
+
+void gl4_1compat_glReleaseShaderCompiler(void *_glfuncs)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glReleaseShaderCompiler();
+}
+
+void gl4_1compat_glTranslatef(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTranslatef(x, y, z);
+}
+
+void gl4_1compat_glTranslated(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTranslated(x, y, z);
+}
+
+void gl4_1compat_glScalef(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glScalef(x, y, z);
+}
+
+void gl4_1compat_glScaled(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glScaled(x, y, z);
+}
+
+void gl4_1compat_glRotatef(void *_glfuncs, GLfloat angle, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glRotatef(angle, x, y, z);
+}
+
+void gl4_1compat_glRotated(void *_glfuncs, GLdouble angle, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glRotated(angle, x, y, z);
+}
+
+void gl4_1compat_glPushMatrix(void *_glfuncs)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glPushMatrix();
+}
+
+void gl4_1compat_glPopMatrix(void *_glfuncs)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glPopMatrix();
+}
+
+void gl4_1compat_glOrtho(void *_glfuncs, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glOrtho(left, right, bottom, top, zNear, zFar);
+}
+
+void gl4_1compat_glMultMatrixd(void *_glfuncs, const GLdouble* m)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultMatrixd(m);
+}
+
+void gl4_1compat_glMultMatrixf(void *_glfuncs, const GLfloat* m)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultMatrixf(m);
+}
+
+void gl4_1compat_glMatrixMode(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glMatrixMode(mode);
+}
+
+void gl4_1compat_glLoadMatrixd(void *_glfuncs, const GLdouble* m)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glLoadMatrixd(m);
+}
+
+void gl4_1compat_glLoadMatrixf(void *_glfuncs, const GLfloat* m)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glLoadMatrixf(m);
+}
+
+void gl4_1compat_glLoadIdentity(void *_glfuncs)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glLoadIdentity();
+}
+
+void gl4_1compat_glFrustum(void *_glfuncs, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glFrustum(left, right, bottom, top, zNear, zFar);
+}
+
+GLboolean gl4_1compat_glIsList(void *_glfuncs, GLuint list)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsList(list);
+}
+
+void gl4_1compat_glGetTexGeniv(void *_glfuncs, GLenum coord, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexGeniv(coord, pname, params);
+}
+
+void gl4_1compat_glGetTexGenfv(void *_glfuncs, GLenum coord, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexGenfv(coord, pname, params);
+}
+
+void gl4_1compat_glGetTexGendv(void *_glfuncs, GLenum coord, GLenum pname, GLdouble* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexGendv(coord, pname, params);
+}
+
+void gl4_1compat_glGetTexEnviv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexEnviv(target, pname, params);
+}
+
+void gl4_1compat_glGetTexEnvfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexEnvfv(target, pname, params);
+}
+
+void gl4_1compat_glGetPolygonStipple(void *_glfuncs, GLubyte* mask)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetPolygonStipple(mask);
+}
+
+void gl4_1compat_glGetPixelMapusv(void *_glfuncs, GLenum glmap, GLushort* values)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetPixelMapusv(glmap, values);
+}
+
+void gl4_1compat_glGetPixelMapuiv(void *_glfuncs, GLenum glmap, GLuint* values)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetPixelMapuiv(glmap, values);
+}
+
+void gl4_1compat_glGetPixelMapfv(void *_glfuncs, GLenum glmap, GLfloat* values)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetPixelMapfv(glmap, values);
+}
+
+void gl4_1compat_glGetMaterialiv(void *_glfuncs, GLenum face, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetMaterialiv(face, pname, params);
+}
+
+void gl4_1compat_glGetMaterialfv(void *_glfuncs, GLenum face, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetMaterialfv(face, pname, params);
+}
+
+void gl4_1compat_glGetMapiv(void *_glfuncs, GLenum target, GLenum query, GLint* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetMapiv(target, query, v);
+}
+
+void gl4_1compat_glGetMapfv(void *_glfuncs, GLenum target, GLenum query, GLfloat* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetMapfv(target, query, v);
+}
+
+void gl4_1compat_glGetMapdv(void *_glfuncs, GLenum target, GLenum query, GLdouble* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetMapdv(target, query, v);
+}
+
+void gl4_1compat_glGetLightiv(void *_glfuncs, GLenum light, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetLightiv(light, pname, params);
+}
+
+void gl4_1compat_glGetLightfv(void *_glfuncs, GLenum light, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetLightfv(light, pname, params);
+}
+
+void gl4_1compat_glGetClipPlane(void *_glfuncs, GLenum plane, GLdouble* equation)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetClipPlane(plane, equation);
+}
+
+void gl4_1compat_glDrawPixels(void *_glfuncs, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawPixels(width, height, format, gltype, pixels);
+}
+
+void gl4_1compat_glCopyPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum gltype)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyPixels(x, y, width, height, gltype);
+}
+
+void gl4_1compat_glPixelMapusv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLushort* values)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glPixelMapusv(glmap, mapsize, values);
+}
+
+void gl4_1compat_glPixelMapuiv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLuint* values)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glPixelMapuiv(glmap, mapsize, values);
+}
+
+void gl4_1compat_glPixelMapfv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLfloat* values)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glPixelMapfv(glmap, mapsize, values);
+}
+
+void gl4_1compat_glPixelTransferi(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glPixelTransferi(pname, param);
+}
+
+void gl4_1compat_glPixelTransferf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glPixelTransferf(pname, param);
+}
+
+void gl4_1compat_glPixelZoom(void *_glfuncs, GLfloat xfactor, GLfloat yfactor)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glPixelZoom(xfactor, yfactor);
+}
+
+void gl4_1compat_glAlphaFunc(void *_glfuncs, GLenum glfunc, GLfloat ref)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glAlphaFunc(glfunc, ref);
+}
+
+void gl4_1compat_glEvalPoint2(void *_glfuncs, GLint i, GLint j)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalPoint2(i, j);
+}
+
+void gl4_1compat_glEvalMesh2(void *_glfuncs, GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalMesh2(mode, i1, i2, j1, j2);
+}
+
+void gl4_1compat_glEvalPoint1(void *_glfuncs, GLint i)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalPoint1(i);
+}
+
+void gl4_1compat_glEvalMesh1(void *_glfuncs, GLenum mode, GLint i1, GLint i2)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalMesh1(mode, i1, i2);
+}
+
+void gl4_1compat_glEvalCoord2fv(void *_glfuncs, const GLfloat* u)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalCoord2fv(u);
+}
+
+void gl4_1compat_glEvalCoord2f(void *_glfuncs, GLfloat u, GLfloat v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalCoord2f(u, v);
+}
+
+void gl4_1compat_glEvalCoord2dv(void *_glfuncs, const GLdouble* u)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalCoord2dv(u);
+}
+
+void gl4_1compat_glEvalCoord2d(void *_glfuncs, GLdouble u, GLdouble v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalCoord2d(u, v);
+}
+
+void gl4_1compat_glEvalCoord1fv(void *_glfuncs, const GLfloat* u)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalCoord1fv(u);
+}
+
+void gl4_1compat_glEvalCoord1f(void *_glfuncs, GLfloat u)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalCoord1f(u);
+}
+
+void gl4_1compat_glEvalCoord1dv(void *_glfuncs, const GLdouble* u)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalCoord1dv(u);
+}
+
+void gl4_1compat_glEvalCoord1d(void *_glfuncs, GLdouble u)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalCoord1d(u);
+}
+
+void gl4_1compat_glMapGrid2f(void *_glfuncs, GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glMapGrid2f(un, u1, u2, vn, v1, v2);
+}
+
+void gl4_1compat_glMapGrid2d(void *_glfuncs, GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glMapGrid2d(un, u1, u2, vn, v1, v2);
+}
+
+void gl4_1compat_glMapGrid1f(void *_glfuncs, GLint un, GLfloat u1, GLfloat u2)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glMapGrid1f(un, u1, u2);
+}
+
+void gl4_1compat_glMapGrid1d(void *_glfuncs, GLint un, GLdouble u1, GLdouble u2)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glMapGrid1d(un, u1, u2);
+}
+
+void gl4_1compat_glMap2f(void *_glfuncs, GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat* points)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glMap2f(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+void gl4_1compat_glMap2d(void *_glfuncs, GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble* points)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glMap2d(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+void gl4_1compat_glMap1f(void *_glfuncs, GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat* points)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glMap1f(target, u1, u2, stride, order, points);
+}
+
+void gl4_1compat_glMap1d(void *_glfuncs, GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble* points)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glMap1d(target, u1, u2, stride, order, points);
+}
+
+void gl4_1compat_glPushAttrib(void *_glfuncs, GLbitfield mask)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glPushAttrib(mask);
+}
+
+void gl4_1compat_glPopAttrib(void *_glfuncs)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glPopAttrib();
+}
+
+void gl4_1compat_glAccum(void *_glfuncs, GLenum op, GLfloat value)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glAccum(op, value);
+}
+
+void gl4_1compat_glIndexMask(void *_glfuncs, GLuint mask)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexMask(mask);
+}
+
+void gl4_1compat_glClearIndex(void *_glfuncs, GLfloat c)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glClearIndex(c);
+}
+
+void gl4_1compat_glClearAccum(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glClearAccum(red, green, blue, alpha);
+}
+
+void gl4_1compat_glPushName(void *_glfuncs, GLuint name)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glPushName(name);
+}
+
+void gl4_1compat_glPopName(void *_glfuncs)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glPopName();
+}
+
+void gl4_1compat_glPassThrough(void *_glfuncs, GLfloat token)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glPassThrough(token);
+}
+
+void gl4_1compat_glLoadName(void *_glfuncs, GLuint name)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glLoadName(name);
+}
+
+void gl4_1compat_glInitNames(void *_glfuncs)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glInitNames();
+}
+
+GLint gl4_1compat_glRenderMode(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ return _qglfuncs->glRenderMode(mode);
+}
+
+void gl4_1compat_glSelectBuffer(void *_glfuncs, GLsizei size, GLuint* buffer)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glSelectBuffer(size, buffer);
+}
+
+void gl4_1compat_glFeedbackBuffer(void *_glfuncs, GLsizei size, GLenum gltype, GLfloat* buffer)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glFeedbackBuffer(size, gltype, buffer);
+}
+
+void gl4_1compat_glTexGeniv(void *_glfuncs, GLenum coord, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexGeniv(coord, pname, params);
+}
+
+void gl4_1compat_glTexGeni(void *_glfuncs, GLenum coord, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexGeni(coord, pname, param);
+}
+
+void gl4_1compat_glTexGenfv(void *_glfuncs, GLenum coord, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexGenfv(coord, pname, params);
+}
+
+void gl4_1compat_glTexGenf(void *_glfuncs, GLenum coord, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexGenf(coord, pname, param);
+}
+
+void gl4_1compat_glTexGendv(void *_glfuncs, GLenum coord, GLenum pname, const GLdouble* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexGendv(coord, pname, params);
+}
+
+void gl4_1compat_glTexGend(void *_glfuncs, GLenum coord, GLenum pname, GLdouble param)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexGend(coord, pname, param);
+}
+
+void gl4_1compat_glTexEnviv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexEnviv(target, pname, params);
+}
+
+void gl4_1compat_glTexEnvi(void *_glfuncs, GLenum target, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexEnvi(target, pname, param);
+}
+
+void gl4_1compat_glTexEnvfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexEnvfv(target, pname, params);
+}
+
+void gl4_1compat_glTexEnvf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexEnvf(target, pname, param);
+}
+
+void gl4_1compat_glShadeModel(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glShadeModel(mode);
+}
+
+void gl4_1compat_glPolygonStipple(void *_glfuncs, const GLubyte* mask)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glPolygonStipple(mask);
+}
+
+void gl4_1compat_glMaterialiv(void *_glfuncs, GLenum face, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glMaterialiv(face, pname, params);
+}
+
+void gl4_1compat_glMateriali(void *_glfuncs, GLenum face, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glMateriali(face, pname, param);
+}
+
+void gl4_1compat_glMaterialfv(void *_glfuncs, GLenum face, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glMaterialfv(face, pname, params);
+}
+
+void gl4_1compat_glMaterialf(void *_glfuncs, GLenum face, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glMaterialf(face, pname, param);
+}
+
+void gl4_1compat_glLineStipple(void *_glfuncs, GLint factor, GLushort pattern)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glLineStipple(factor, pattern);
+}
+
+void gl4_1compat_glLightModeliv(void *_glfuncs, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glLightModeliv(pname, params);
+}
+
+void gl4_1compat_glLightModeli(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glLightModeli(pname, param);
+}
+
+void gl4_1compat_glLightModelfv(void *_glfuncs, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glLightModelfv(pname, params);
+}
+
+void gl4_1compat_glLightModelf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glLightModelf(pname, param);
+}
+
+void gl4_1compat_glLightiv(void *_glfuncs, GLenum light, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glLightiv(light, pname, params);
+}
+
+void gl4_1compat_glLighti(void *_glfuncs, GLenum light, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glLighti(light, pname, param);
+}
+
+void gl4_1compat_glLightfv(void *_glfuncs, GLenum light, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glLightfv(light, pname, params);
+}
+
+void gl4_1compat_glLightf(void *_glfuncs, GLenum light, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glLightf(light, pname, param);
+}
+
+void gl4_1compat_glFogiv(void *_glfuncs, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glFogiv(pname, params);
+}
+
+void gl4_1compat_glFogi(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glFogi(pname, param);
+}
+
+void gl4_1compat_glFogfv(void *_glfuncs, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glFogfv(pname, params);
+}
+
+void gl4_1compat_glFogf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glFogf(pname, param);
+}
+
+void gl4_1compat_glColorMaterial(void *_glfuncs, GLenum face, GLenum mode)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorMaterial(face, mode);
+}
+
+void gl4_1compat_glClipPlane(void *_glfuncs, GLenum plane, const GLdouble* equation)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glClipPlane(plane, equation);
+}
+
+void gl4_1compat_glVertex4sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex4sv(v);
+}
+
+void gl4_1compat_glVertex4s(void *_glfuncs, GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex4s(x, y, z, w);
+}
+
+void gl4_1compat_glVertex4iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex4iv(v);
+}
+
+void gl4_1compat_glVertex4i(void *_glfuncs, GLint x, GLint y, GLint z, GLint w)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex4i(x, y, z, w);
+}
+
+void gl4_1compat_glVertex4fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex4fv(v);
+}
+
+void gl4_1compat_glVertex4f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex4f(x, y, z, w);
+}
+
+void gl4_1compat_glVertex4dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex4dv(v);
+}
+
+void gl4_1compat_glVertex4d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex4d(x, y, z, w);
+}
+
+void gl4_1compat_glVertex3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex3sv(v);
+}
+
+void gl4_1compat_glVertex3s(void *_glfuncs, GLshort x, GLshort y, GLshort z)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex3s(x, y, z);
+}
+
+void gl4_1compat_glVertex3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex3iv(v);
+}
+
+void gl4_1compat_glVertex3i(void *_glfuncs, GLint x, GLint y, GLint z)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex3i(x, y, z);
+}
+
+void gl4_1compat_glVertex3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex3fv(v);
+}
+
+void gl4_1compat_glVertex3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex3f(x, y, z);
+}
+
+void gl4_1compat_glVertex3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex3dv(v);
+}
+
+void gl4_1compat_glVertex3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex3d(x, y, z);
+}
+
+void gl4_1compat_glVertex2sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex2sv(v);
+}
+
+void gl4_1compat_glVertex2s(void *_glfuncs, GLshort x, GLshort y)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex2s(x, y);
+}
+
+void gl4_1compat_glVertex2iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex2iv(v);
+}
+
+void gl4_1compat_glVertex2i(void *_glfuncs, GLint x, GLint y)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex2i(x, y);
+}
+
+void gl4_1compat_glVertex2fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex2fv(v);
+}
+
+void gl4_1compat_glVertex2f(void *_glfuncs, GLfloat x, GLfloat y)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex2f(x, y);
+}
+
+void gl4_1compat_glVertex2dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex2dv(v);
+}
+
+void gl4_1compat_glVertex2d(void *_glfuncs, GLdouble x, GLdouble y)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex2d(x, y);
+}
+
+void gl4_1compat_glTexCoord4sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord4sv(v);
+}
+
+void gl4_1compat_glTexCoord4s(void *_glfuncs, GLshort s, GLshort t, GLshort r, GLshort q)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord4s(s, t, r, q);
+}
+
+void gl4_1compat_glTexCoord4iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord4iv(v);
+}
+
+void gl4_1compat_glTexCoord4i(void *_glfuncs, GLint s, GLint t, GLint r, GLint q)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord4i(s, t, r, q);
+}
+
+void gl4_1compat_glTexCoord4fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord4fv(v);
+}
+
+void gl4_1compat_glTexCoord4f(void *_glfuncs, GLfloat s, GLfloat t, GLfloat r, GLfloat q)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord4f(s, t, r, q);
+}
+
+void gl4_1compat_glTexCoord4dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord4dv(v);
+}
+
+void gl4_1compat_glTexCoord4d(void *_glfuncs, GLdouble s, GLdouble t, GLdouble r, GLdouble q)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord4d(s, t, r, q);
+}
+
+void gl4_1compat_glTexCoord3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord3sv(v);
+}
+
+void gl4_1compat_glTexCoord3s(void *_glfuncs, GLshort s, GLshort t, GLshort r)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord3s(s, t, r);
+}
+
+void gl4_1compat_glTexCoord3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord3iv(v);
+}
+
+void gl4_1compat_glTexCoord3i(void *_glfuncs, GLint s, GLint t, GLint r)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord3i(s, t, r);
+}
+
+void gl4_1compat_glTexCoord3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord3fv(v);
+}
+
+void gl4_1compat_glTexCoord3f(void *_glfuncs, GLfloat s, GLfloat t, GLfloat r)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord3f(s, t, r);
+}
+
+void gl4_1compat_glTexCoord3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord3dv(v);
+}
+
+void gl4_1compat_glTexCoord3d(void *_glfuncs, GLdouble s, GLdouble t, GLdouble r)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord3d(s, t, r);
+}
+
+void gl4_1compat_glTexCoord2sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord2sv(v);
+}
+
+void gl4_1compat_glTexCoord2s(void *_glfuncs, GLshort s, GLshort t)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord2s(s, t);
+}
+
+void gl4_1compat_glTexCoord2iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord2iv(v);
+}
+
+void gl4_1compat_glTexCoord2i(void *_glfuncs, GLint s, GLint t)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord2i(s, t);
+}
+
+void gl4_1compat_glTexCoord2fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord2fv(v);
+}
+
+void gl4_1compat_glTexCoord2f(void *_glfuncs, GLfloat s, GLfloat t)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord2f(s, t);
+}
+
+void gl4_1compat_glTexCoord2dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord2dv(v);
+}
+
+void gl4_1compat_glTexCoord2d(void *_glfuncs, GLdouble s, GLdouble t)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord2d(s, t);
+}
+
+void gl4_1compat_glTexCoord1sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord1sv(v);
+}
+
+void gl4_1compat_glTexCoord1s(void *_glfuncs, GLshort s)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord1s(s);
+}
+
+void gl4_1compat_glTexCoord1iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord1iv(v);
+}
+
+void gl4_1compat_glTexCoord1i(void *_glfuncs, GLint s)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord1i(s);
+}
+
+void gl4_1compat_glTexCoord1fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord1fv(v);
+}
+
+void gl4_1compat_glTexCoord1f(void *_glfuncs, GLfloat s)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord1f(s);
+}
+
+void gl4_1compat_glTexCoord1dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord1dv(v);
+}
+
+void gl4_1compat_glTexCoord1d(void *_glfuncs, GLdouble s)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord1d(s);
+}
+
+void gl4_1compat_glRectsv(void *_glfuncs, const GLshort* v1, const GLshort* v2)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glRectsv(v1, v2);
+}
+
+void gl4_1compat_glRects(void *_glfuncs, GLshort x1, GLshort y1, GLshort x2, GLshort y2)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glRects(x1, y1, x2, y2);
+}
+
+void gl4_1compat_glRectiv(void *_glfuncs, const GLint* v1, const GLint* v2)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glRectiv(v1, v2);
+}
+
+void gl4_1compat_glRecti(void *_glfuncs, GLint x1, GLint y1, GLint x2, GLint y2)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glRecti(x1, y1, x2, y2);
+}
+
+void gl4_1compat_glRectfv(void *_glfuncs, const GLfloat* v1, const GLfloat* v2)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glRectfv(v1, v2);
+}
+
+void gl4_1compat_glRectf(void *_glfuncs, GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glRectf(x1, y1, x2, y2);
+}
+
+void gl4_1compat_glRectdv(void *_glfuncs, const GLdouble* v1, const GLdouble* v2)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glRectdv(v1, v2);
+}
+
+void gl4_1compat_glRectd(void *_glfuncs, GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glRectd(x1, y1, x2, y2);
+}
+
+void gl4_1compat_glRasterPos4sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos4sv(v);
+}
+
+void gl4_1compat_glRasterPos4s(void *_glfuncs, GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos4s(x, y, z, w);
+}
+
+void gl4_1compat_glRasterPos4iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos4iv(v);
+}
+
+void gl4_1compat_glRasterPos4i(void *_glfuncs, GLint x, GLint y, GLint z, GLint w)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos4i(x, y, z, w);
+}
+
+void gl4_1compat_glRasterPos4fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos4fv(v);
+}
+
+void gl4_1compat_glRasterPos4f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos4f(x, y, z, w);
+}
+
+void gl4_1compat_glRasterPos4dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos4dv(v);
+}
+
+void gl4_1compat_glRasterPos4d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos4d(x, y, z, w);
+}
+
+void gl4_1compat_glRasterPos3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos3sv(v);
+}
+
+void gl4_1compat_glRasterPos3s(void *_glfuncs, GLshort x, GLshort y, GLshort z)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos3s(x, y, z);
+}
+
+void gl4_1compat_glRasterPos3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos3iv(v);
+}
+
+void gl4_1compat_glRasterPos3i(void *_glfuncs, GLint x, GLint y, GLint z)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos3i(x, y, z);
+}
+
+void gl4_1compat_glRasterPos3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos3fv(v);
+}
+
+void gl4_1compat_glRasterPos3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos3f(x, y, z);
+}
+
+void gl4_1compat_glRasterPos3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos3dv(v);
+}
+
+void gl4_1compat_glRasterPos3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos3d(x, y, z);
+}
+
+void gl4_1compat_glRasterPos2sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos2sv(v);
+}
+
+void gl4_1compat_glRasterPos2s(void *_glfuncs, GLshort x, GLshort y)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos2s(x, y);
+}
+
+void gl4_1compat_glRasterPos2iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos2iv(v);
+}
+
+void gl4_1compat_glRasterPos2i(void *_glfuncs, GLint x, GLint y)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos2i(x, y);
+}
+
+void gl4_1compat_glRasterPos2fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos2fv(v);
+}
+
+void gl4_1compat_glRasterPos2f(void *_glfuncs, GLfloat x, GLfloat y)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos2f(x, y);
+}
+
+void gl4_1compat_glRasterPos2dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos2dv(v);
+}
+
+void gl4_1compat_glRasterPos2d(void *_glfuncs, GLdouble x, GLdouble y)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos2d(x, y);
+}
+
+void gl4_1compat_glNormal3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormal3sv(v);
+}
+
+void gl4_1compat_glNormal3s(void *_glfuncs, GLshort nx, GLshort ny, GLshort nz)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormal3s(nx, ny, nz);
+}
+
+void gl4_1compat_glNormal3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormal3iv(v);
+}
+
+void gl4_1compat_glNormal3i(void *_glfuncs, GLint nx, GLint ny, GLint nz)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormal3i(nx, ny, nz);
+}
+
+void gl4_1compat_glNormal3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormal3fv(v);
+}
+
+void gl4_1compat_glNormal3f(void *_glfuncs, GLfloat nx, GLfloat ny, GLfloat nz)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormal3f(nx, ny, nz);
+}
+
+void gl4_1compat_glNormal3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormal3dv(v);
+}
+
+void gl4_1compat_glNormal3d(void *_glfuncs, GLdouble nx, GLdouble ny, GLdouble nz)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormal3d(nx, ny, nz);
+}
+
+void gl4_1compat_glNormal3bv(void *_glfuncs, const GLbyte* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormal3bv(v);
+}
+
+void gl4_1compat_glNormal3b(void *_glfuncs, GLbyte nx, GLbyte ny, GLbyte nz)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormal3b(nx, ny, nz);
+}
+
+void gl4_1compat_glIndexsv(void *_glfuncs, const GLshort* c)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexsv(c);
+}
+
+void gl4_1compat_glIndexs(void *_glfuncs, GLshort c)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexs(c);
+}
+
+void gl4_1compat_glIndexiv(void *_glfuncs, const GLint* c)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexiv(c);
+}
+
+void gl4_1compat_glIndexi(void *_glfuncs, GLint c)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexi(c);
+}
+
+void gl4_1compat_glIndexfv(void *_glfuncs, const GLfloat* c)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexfv(c);
+}
+
+void gl4_1compat_glIndexf(void *_glfuncs, GLfloat c)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexf(c);
+}
+
+void gl4_1compat_glIndexdv(void *_glfuncs, const GLdouble* c)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexdv(c);
+}
+
+void gl4_1compat_glIndexd(void *_glfuncs, GLdouble c)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexd(c);
+}
+
+void gl4_1compat_glEnd(void *_glfuncs)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glEnd();
+}
+
+void gl4_1compat_glEdgeFlagv(void *_glfuncs, const GLboolean* flag)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glEdgeFlagv(flag);
+}
+
+void gl4_1compat_glEdgeFlag(void *_glfuncs, GLboolean flag)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glEdgeFlag(flag);
+}
+
+void gl4_1compat_glColor4usv(void *_glfuncs, const GLushort* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4usv(v);
+}
+
+void gl4_1compat_glColor4us(void *_glfuncs, GLushort red, GLushort green, GLushort blue, GLushort alpha)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4us(red, green, blue, alpha);
+}
+
+void gl4_1compat_glColor4uiv(void *_glfuncs, const GLuint* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4uiv(v);
+}
+
+void gl4_1compat_glColor4ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue, GLuint alpha)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4ui(red, green, blue, alpha);
+}
+
+void gl4_1compat_glColor4ubv(void *_glfuncs, const GLubyte* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4ubv(v);
+}
+
+void gl4_1compat_glColor4ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4ub(red, green, blue, alpha);
+}
+
+void gl4_1compat_glColor4sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4sv(v);
+}
+
+void gl4_1compat_glColor4s(void *_glfuncs, GLshort red, GLshort green, GLshort blue, GLshort alpha)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4s(red, green, blue, alpha);
+}
+
+void gl4_1compat_glColor4iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4iv(v);
+}
+
+void gl4_1compat_glColor4i(void *_glfuncs, GLint red, GLint green, GLint blue, GLint alpha)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4i(red, green, blue, alpha);
+}
+
+void gl4_1compat_glColor4fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4fv(v);
+}
+
+void gl4_1compat_glColor4f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4f(red, green, blue, alpha);
+}
+
+void gl4_1compat_glColor4dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4dv(v);
+}
+
+void gl4_1compat_glColor4d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4d(red, green, blue, alpha);
+}
+
+void gl4_1compat_glColor4bv(void *_glfuncs, const GLbyte* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4bv(v);
+}
+
+void gl4_1compat_glColor4b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4b(red, green, blue, alpha);
+}
+
+void gl4_1compat_glColor3usv(void *_glfuncs, const GLushort* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3usv(v);
+}
+
+void gl4_1compat_glColor3us(void *_glfuncs, GLushort red, GLushort green, GLushort blue)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3us(red, green, blue);
+}
+
+void gl4_1compat_glColor3uiv(void *_glfuncs, const GLuint* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3uiv(v);
+}
+
+void gl4_1compat_glColor3ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3ui(red, green, blue);
+}
+
+void gl4_1compat_glColor3ubv(void *_glfuncs, const GLubyte* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3ubv(v);
+}
+
+void gl4_1compat_glColor3ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3ub(red, green, blue);
+}
+
+void gl4_1compat_glColor3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3sv(v);
+}
+
+void gl4_1compat_glColor3s(void *_glfuncs, GLshort red, GLshort green, GLshort blue)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3s(red, green, blue);
+}
+
+void gl4_1compat_glColor3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3iv(v);
+}
+
+void gl4_1compat_glColor3i(void *_glfuncs, GLint red, GLint green, GLint blue)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3i(red, green, blue);
+}
+
+void gl4_1compat_glColor3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3fv(v);
+}
+
+void gl4_1compat_glColor3f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3f(red, green, blue);
+}
+
+void gl4_1compat_glColor3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3dv(v);
+}
+
+void gl4_1compat_glColor3d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3d(red, green, blue);
+}
+
+void gl4_1compat_glColor3bv(void *_glfuncs, const GLbyte* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3bv(v);
+}
+
+void gl4_1compat_glColor3b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3b(red, green, blue);
+}
+
+void gl4_1compat_glBitmap(void *_glfuncs, GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte* bitmap)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glBitmap(width, height, xorig, yorig, xmove, ymove, bitmap);
+}
+
+void gl4_1compat_glBegin(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glBegin(mode);
+}
+
+void gl4_1compat_glListBase(void *_glfuncs, GLuint base)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glListBase(base);
+}
+
+GLuint gl4_1compat_glGenLists(void *_glfuncs, GLsizei range_)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ return _qglfuncs->glGenLists(range_);
+}
+
+void gl4_1compat_glDeleteLists(void *_glfuncs, GLuint list, GLsizei range_)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteLists(list, range_);
+}
+
+void gl4_1compat_glCallLists(void *_glfuncs, GLsizei n, GLenum gltype, const GLvoid* lists)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glCallLists(n, gltype, lists);
+}
+
+void gl4_1compat_glCallList(void *_glfuncs, GLuint list)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glCallList(list);
+}
+
+void gl4_1compat_glEndList(void *_glfuncs)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glEndList();
+}
+
+void gl4_1compat_glNewList(void *_glfuncs, GLuint list, GLenum mode)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glNewList(list, mode);
+}
+
+void gl4_1compat_glPushClientAttrib(void *_glfuncs, GLbitfield mask)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glPushClientAttrib(mask);
+}
+
+void gl4_1compat_glPopClientAttrib(void *_glfuncs)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glPopClientAttrib();
+}
+
+void gl4_1compat_glPrioritizeTextures(void *_glfuncs, GLsizei n, const GLuint* textures, const GLfloat* priorities)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glPrioritizeTextures(n, textures, priorities);
+}
+
+GLboolean gl4_1compat_glAreTexturesResident(void *_glfuncs, GLsizei n, const GLuint* textures, GLboolean* residences)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ return _qglfuncs->glAreTexturesResident(n, textures, residences);
+}
+
+void gl4_1compat_glVertexPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexPointer(size, gltype, stride, pointer);
+}
+
+void gl4_1compat_glTexCoordPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoordPointer(size, gltype, stride, pointer);
+}
+
+void gl4_1compat_glNormalPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormalPointer(gltype, stride, pointer);
+}
+
+void gl4_1compat_glInterleavedArrays(void *_glfuncs, GLenum format, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glInterleavedArrays(format, stride, pointer);
+}
+
+void gl4_1compat_glIndexPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexPointer(gltype, stride, pointer);
+}
+
+void gl4_1compat_glEnableClientState(void *_glfuncs, GLenum array)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glEnableClientState(array);
+}
+
+void gl4_1compat_glEdgeFlagPointer(void *_glfuncs, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glEdgeFlagPointer(stride, pointer);
+}
+
+void gl4_1compat_glDisableClientState(void *_glfuncs, GLenum array)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glDisableClientState(array);
+}
+
+void gl4_1compat_glColorPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorPointer(size, gltype, stride, pointer);
+}
+
+void gl4_1compat_glArrayElement(void *_glfuncs, GLint i)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glArrayElement(i);
+}
+
+void gl4_1compat_glResetMinmax(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glResetMinmax(target);
+}
+
+void gl4_1compat_glResetHistogram(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glResetHistogram(target);
+}
+
+void gl4_1compat_glMinmax(void *_glfuncs, GLenum target, GLenum internalFormat, GLboolean sink)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glMinmax(target, internalFormat, sink);
+}
+
+void gl4_1compat_glHistogram(void *_glfuncs, GLenum target, GLsizei width, GLenum internalFormat, GLboolean sink)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glHistogram(target, width, internalFormat, sink);
+}
+
+void gl4_1compat_glGetMinmaxParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetMinmaxParameteriv(target, pname, params);
+}
+
+void gl4_1compat_glGetMinmaxParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetMinmaxParameterfv(target, pname, params);
+}
+
+void gl4_1compat_glGetMinmax(void *_glfuncs, GLenum target, GLboolean reset, GLenum format, GLenum gltype, GLvoid* values)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetMinmax(target, reset, format, gltype, values);
+}
+
+void gl4_1compat_glGetHistogramParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetHistogramParameteriv(target, pname, params);
+}
+
+void gl4_1compat_glGetHistogramParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetHistogramParameterfv(target, pname, params);
+}
+
+void gl4_1compat_glGetHistogram(void *_glfuncs, GLenum target, GLboolean reset, GLenum format, GLenum gltype, GLvoid* values)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetHistogram(target, reset, format, gltype, values);
+}
+
+void gl4_1compat_glSeparableFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* row, const GLvoid* column)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glSeparableFilter2D(target, internalFormat, width, height, format, gltype, row, column);
+}
+
+void gl4_1compat_glGetSeparableFilter(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* row, GLvoid* column, GLvoid* span)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetSeparableFilter(target, format, gltype, row, column, span);
+}
+
+void gl4_1compat_glGetConvolutionParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetConvolutionParameteriv(target, pname, params);
+}
+
+void gl4_1compat_glGetConvolutionParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetConvolutionParameterfv(target, pname, params);
+}
+
+void gl4_1compat_glGetConvolutionFilter(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* image)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetConvolutionFilter(target, format, gltype, image);
+}
+
+void gl4_1compat_glCopyConvolutionFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyConvolutionFilter2D(target, internalFormat, x, y, width, height);
+}
+
+void gl4_1compat_glCopyConvolutionFilter1D(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyConvolutionFilter1D(target, internalFormat, x, y, width);
+}
+
+void gl4_1compat_glConvolutionParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glConvolutionParameteriv(target, pname, params);
+}
+
+void gl4_1compat_glConvolutionParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glConvolutionParameteri(target, pname, params);
+}
+
+void gl4_1compat_glConvolutionParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glConvolutionParameterfv(target, pname, params);
+}
+
+void gl4_1compat_glConvolutionParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glConvolutionParameterf(target, pname, params);
+}
+
+void gl4_1compat_glConvolutionFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* image)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glConvolutionFilter2D(target, internalFormat, width, height, format, gltype, image);
+}
+
+void gl4_1compat_glConvolutionFilter1D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLenum format, GLenum gltype, const GLvoid* image)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glConvolutionFilter1D(target, internalFormat, width, format, gltype, image);
+}
+
+void gl4_1compat_glCopyColorSubTable(void *_glfuncs, GLenum target, GLsizei start, GLint x, GLint y, GLsizei width)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyColorSubTable(target, start, x, y, width);
+}
+
+void gl4_1compat_glColorSubTable(void *_glfuncs, GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum gltype, const GLvoid* data)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorSubTable(target, start, count, format, gltype, data);
+}
+
+void gl4_1compat_glGetColorTableParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetColorTableParameteriv(target, pname, params);
+}
+
+void gl4_1compat_glGetColorTableParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetColorTableParameterfv(target, pname, params);
+}
+
+void gl4_1compat_glGetColorTable(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* table)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetColorTable(target, format, gltype, table);
+}
+
+void gl4_1compat_glCopyColorTable(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyColorTable(target, internalFormat, x, y, width);
+}
+
+void gl4_1compat_glColorTableParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorTableParameteriv(target, pname, params);
+}
+
+void gl4_1compat_glColorTableParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorTableParameterfv(target, pname, params);
+}
+
+void gl4_1compat_glColorTable(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLenum format, GLenum gltype, const GLvoid* table)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorTable(target, internalFormat, width, format, gltype, table);
+}
+
+void gl4_1compat_glMultTransposeMatrixd(void *_glfuncs, const GLdouble* m)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultTransposeMatrixd(m);
+}
+
+void gl4_1compat_glMultTransposeMatrixf(void *_glfuncs, const GLfloat* m)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultTransposeMatrixf(m);
+}
+
+void gl4_1compat_glLoadTransposeMatrixd(void *_glfuncs, const GLdouble* m)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glLoadTransposeMatrixd(m);
+}
+
+void gl4_1compat_glLoadTransposeMatrixf(void *_glfuncs, const GLfloat* m)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glLoadTransposeMatrixf(m);
+}
+
+void gl4_1compat_glMultiTexCoord4sv(void *_glfuncs, GLenum target, const GLshort* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4sv(target, v);
+}
+
+void gl4_1compat_glMultiTexCoord4s(void *_glfuncs, GLenum target, GLshort s, GLshort t, GLshort r, GLshort q)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4s(target, s, t, r, q);
+}
+
+void gl4_1compat_glMultiTexCoord4iv(void *_glfuncs, GLenum target, const GLint* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4iv(target, v);
+}
+
+void gl4_1compat_glMultiTexCoord4i(void *_glfuncs, GLenum target, GLint s, GLint t, GLint r, GLint q)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4i(target, s, t, r, q);
+}
+
+void gl4_1compat_glMultiTexCoord4fv(void *_glfuncs, GLenum target, const GLfloat* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4fv(target, v);
+}
+
+void gl4_1compat_glMultiTexCoord4f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4f(target, s, t, r, q);
+}
+
+void gl4_1compat_glMultiTexCoord4dv(void *_glfuncs, GLenum target, const GLdouble* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4dv(target, v);
+}
+
+void gl4_1compat_glMultiTexCoord4d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4d(target, s, t, r, q);
+}
+
+void gl4_1compat_glMultiTexCoord3sv(void *_glfuncs, GLenum target, const GLshort* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3sv(target, v);
+}
+
+void gl4_1compat_glMultiTexCoord3s(void *_glfuncs, GLenum target, GLshort s, GLshort t, GLshort r)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3s(target, s, t, r);
+}
+
+void gl4_1compat_glMultiTexCoord3iv(void *_glfuncs, GLenum target, const GLint* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3iv(target, v);
+}
+
+void gl4_1compat_glMultiTexCoord3i(void *_glfuncs, GLenum target, GLint s, GLint t, GLint r)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3i(target, s, t, r);
+}
+
+void gl4_1compat_glMultiTexCoord3fv(void *_glfuncs, GLenum target, const GLfloat* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3fv(target, v);
+}
+
+void gl4_1compat_glMultiTexCoord3f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t, GLfloat r)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3f(target, s, t, r);
+}
+
+void gl4_1compat_glMultiTexCoord3dv(void *_glfuncs, GLenum target, const GLdouble* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3dv(target, v);
+}
+
+void gl4_1compat_glMultiTexCoord3d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t, GLdouble r)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3d(target, s, t, r);
+}
+
+void gl4_1compat_glMultiTexCoord2sv(void *_glfuncs, GLenum target, const GLshort* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2sv(target, v);
+}
+
+void gl4_1compat_glMultiTexCoord2s(void *_glfuncs, GLenum target, GLshort s, GLshort t)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2s(target, s, t);
+}
+
+void gl4_1compat_glMultiTexCoord2iv(void *_glfuncs, GLenum target, const GLint* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2iv(target, v);
+}
+
+void gl4_1compat_glMultiTexCoord2i(void *_glfuncs, GLenum target, GLint s, GLint t)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2i(target, s, t);
+}
+
+void gl4_1compat_glMultiTexCoord2fv(void *_glfuncs, GLenum target, const GLfloat* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2fv(target, v);
+}
+
+void gl4_1compat_glMultiTexCoord2f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2f(target, s, t);
+}
+
+void gl4_1compat_glMultiTexCoord2dv(void *_glfuncs, GLenum target, const GLdouble* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2dv(target, v);
+}
+
+void gl4_1compat_glMultiTexCoord2d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2d(target, s, t);
+}
+
+void gl4_1compat_glMultiTexCoord1sv(void *_glfuncs, GLenum target, const GLshort* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1sv(target, v);
+}
+
+void gl4_1compat_glMultiTexCoord1s(void *_glfuncs, GLenum target, GLshort s)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1s(target, s);
+}
+
+void gl4_1compat_glMultiTexCoord1iv(void *_glfuncs, GLenum target, const GLint* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1iv(target, v);
+}
+
+void gl4_1compat_glMultiTexCoord1i(void *_glfuncs, GLenum target, GLint s)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1i(target, s);
+}
+
+void gl4_1compat_glMultiTexCoord1fv(void *_glfuncs, GLenum target, const GLfloat* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1fv(target, v);
+}
+
+void gl4_1compat_glMultiTexCoord1f(void *_glfuncs, GLenum target, GLfloat s)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1f(target, s);
+}
+
+void gl4_1compat_glMultiTexCoord1dv(void *_glfuncs, GLenum target, const GLdouble* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1dv(target, v);
+}
+
+void gl4_1compat_glMultiTexCoord1d(void *_glfuncs, GLenum target, GLdouble s)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1d(target, s);
+}
+
+void gl4_1compat_glClientActiveTexture(void *_glfuncs, GLenum texture)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glClientActiveTexture(texture);
+}
+
+void gl4_1compat_glWindowPos3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos3sv(v);
+}
+
+void gl4_1compat_glWindowPos3s(void *_glfuncs, GLshort x, GLshort y, GLshort z)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos3s(x, y, z);
+}
+
+void gl4_1compat_glWindowPos3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos3iv(v);
+}
+
+void gl4_1compat_glWindowPos3i(void *_glfuncs, GLint x, GLint y, GLint z)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos3i(x, y, z);
+}
+
+void gl4_1compat_glWindowPos3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos3fv(v);
+}
+
+void gl4_1compat_glWindowPos3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos3f(x, y, z);
+}
+
+void gl4_1compat_glWindowPos3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos3dv(v);
+}
+
+void gl4_1compat_glWindowPos3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos3d(x, y, z);
+}
+
+void gl4_1compat_glWindowPos2sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos2sv(v);
+}
+
+void gl4_1compat_glWindowPos2s(void *_glfuncs, GLshort x, GLshort y)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos2s(x, y);
+}
+
+void gl4_1compat_glWindowPos2iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos2iv(v);
+}
+
+void gl4_1compat_glWindowPos2i(void *_glfuncs, GLint x, GLint y)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos2i(x, y);
+}
+
+void gl4_1compat_glWindowPos2fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos2fv(v);
+}
+
+void gl4_1compat_glWindowPos2f(void *_glfuncs, GLfloat x, GLfloat y)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos2f(x, y);
+}
+
+void gl4_1compat_glWindowPos2dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos2dv(v);
+}
+
+void gl4_1compat_glWindowPos2d(void *_glfuncs, GLdouble x, GLdouble y)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos2d(x, y);
+}
+
+void gl4_1compat_glSecondaryColorPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColorPointer(size, gltype, stride, pointer);
+}
+
+void gl4_1compat_glSecondaryColor3usv(void *_glfuncs, const GLushort* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3usv(v);
+}
+
+void gl4_1compat_glSecondaryColor3us(void *_glfuncs, GLushort red, GLushort green, GLushort blue)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3us(red, green, blue);
+}
+
+void gl4_1compat_glSecondaryColor3uiv(void *_glfuncs, const GLuint* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3uiv(v);
+}
+
+void gl4_1compat_glSecondaryColor3ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3ui(red, green, blue);
+}
+
+void gl4_1compat_glSecondaryColor3ubv(void *_glfuncs, const GLubyte* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3ubv(v);
+}
+
+void gl4_1compat_glSecondaryColor3ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3ub(red, green, blue);
+}
+
+void gl4_1compat_glSecondaryColor3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3sv(v);
+}
+
+void gl4_1compat_glSecondaryColor3s(void *_glfuncs, GLshort red, GLshort green, GLshort blue)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3s(red, green, blue);
+}
+
+void gl4_1compat_glSecondaryColor3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3iv(v);
+}
+
+void gl4_1compat_glSecondaryColor3i(void *_glfuncs, GLint red, GLint green, GLint blue)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3i(red, green, blue);
+}
+
+void gl4_1compat_glSecondaryColor3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3fv(v);
+}
+
+void gl4_1compat_glSecondaryColor3f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3f(red, green, blue);
+}
+
+void gl4_1compat_glSecondaryColor3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3dv(v);
+}
+
+void gl4_1compat_glSecondaryColor3d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3d(red, green, blue);
+}
+
+void gl4_1compat_glSecondaryColor3bv(void *_glfuncs, const GLbyte* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3bv(v);
+}
+
+void gl4_1compat_glSecondaryColor3b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3b(red, green, blue);
+}
+
+void gl4_1compat_glFogCoordPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glFogCoordPointer(gltype, stride, pointer);
+}
+
+void gl4_1compat_glFogCoorddv(void *_glfuncs, const GLdouble* coord)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glFogCoorddv(coord);
+}
+
+void gl4_1compat_glFogCoordd(void *_glfuncs, GLdouble coord)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glFogCoordd(coord);
+}
+
+void gl4_1compat_glFogCoordfv(void *_glfuncs, const GLfloat* coord)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glFogCoordfv(coord);
+}
+
+void gl4_1compat_glFogCoordf(void *_glfuncs, GLfloat coord)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glFogCoordf(coord);
+}
+
+void gl4_1compat_glVertexAttrib4usv(void *_glfuncs, GLuint index, const GLushort* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4usv(index, v);
+}
+
+void gl4_1compat_glVertexAttrib4uiv(void *_glfuncs, GLuint index, const GLuint* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4uiv(index, v);
+}
+
+void gl4_1compat_glVertexAttrib4ubv(void *_glfuncs, GLuint index, const GLubyte* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4ubv(index, v);
+}
+
+void gl4_1compat_glVertexAttrib4sv(void *_glfuncs, GLuint index, const GLshort* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4sv(index, v);
+}
+
+void gl4_1compat_glVertexAttrib4s(void *_glfuncs, GLuint index, GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4s(index, x, y, z, w);
+}
+
+void gl4_1compat_glVertexAttrib4iv(void *_glfuncs, GLuint index, const GLint* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4iv(index, v);
+}
+
+void gl4_1compat_glVertexAttrib4fv(void *_glfuncs, GLuint index, const GLfloat* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4fv(index, v);
+}
+
+void gl4_1compat_glVertexAttrib4f(void *_glfuncs, GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4f(index, x, y, z, w);
+}
+
+void gl4_1compat_glVertexAttrib4dv(void *_glfuncs, GLuint index, const GLdouble* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4dv(index, v);
+}
+
+void gl4_1compat_glVertexAttrib4d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4d(index, x, y, z, w);
+}
+
+void gl4_1compat_glVertexAttrib4bv(void *_glfuncs, GLuint index, const GLbyte* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4bv(index, v);
+}
+
+void gl4_1compat_glVertexAttrib4Nusv(void *_glfuncs, GLuint index, const GLushort* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Nusv(index, v);
+}
+
+void gl4_1compat_glVertexAttrib4Nuiv(void *_glfuncs, GLuint index, const GLuint* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Nuiv(index, v);
+}
+
+void gl4_1compat_glVertexAttrib4Nubv(void *_glfuncs, GLuint index, const GLubyte* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Nubv(index, v);
+}
+
+void gl4_1compat_glVertexAttrib4Nub(void *_glfuncs, GLuint index, GLubyte x, GLubyte y, GLubyte z, GLubyte w)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Nub(index, x, y, z, w);
+}
+
+void gl4_1compat_glVertexAttrib4Nsv(void *_glfuncs, GLuint index, const GLshort* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Nsv(index, v);
+}
+
+void gl4_1compat_glVertexAttrib4Niv(void *_glfuncs, GLuint index, const GLint* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Niv(index, v);
+}
+
+void gl4_1compat_glVertexAttrib4Nbv(void *_glfuncs, GLuint index, const GLbyte* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Nbv(index, v);
+}
+
+void gl4_1compat_glVertexAttrib3sv(void *_glfuncs, GLuint index, const GLshort* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib3sv(index, v);
+}
+
+void gl4_1compat_glVertexAttrib3s(void *_glfuncs, GLuint index, GLshort x, GLshort y, GLshort z)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib3s(index, x, y, z);
+}
+
+void gl4_1compat_glVertexAttrib3fv(void *_glfuncs, GLuint index, const GLfloat* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib3fv(index, v);
+}
+
+void gl4_1compat_glVertexAttrib3f(void *_glfuncs, GLuint index, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib3f(index, x, y, z);
+}
+
+void gl4_1compat_glVertexAttrib3dv(void *_glfuncs, GLuint index, const GLdouble* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib3dv(index, v);
+}
+
+void gl4_1compat_glVertexAttrib3d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib3d(index, x, y, z);
+}
+
+void gl4_1compat_glVertexAttrib2sv(void *_glfuncs, GLuint index, const GLshort* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib2sv(index, v);
+}
+
+void gl4_1compat_glVertexAttrib2s(void *_glfuncs, GLuint index, GLshort x, GLshort y)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib2s(index, x, y);
+}
+
+void gl4_1compat_glVertexAttrib2fv(void *_glfuncs, GLuint index, const GLfloat* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib2fv(index, v);
+}
+
+void gl4_1compat_glVertexAttrib2f(void *_glfuncs, GLuint index, GLfloat x, GLfloat y)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib2f(index, x, y);
+}
+
+void gl4_1compat_glVertexAttrib2dv(void *_glfuncs, GLuint index, const GLdouble* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib2dv(index, v);
+}
+
+void gl4_1compat_glVertexAttrib2d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib2d(index, x, y);
+}
+
+void gl4_1compat_glVertexAttrib1sv(void *_glfuncs, GLuint index, const GLshort* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib1sv(index, v);
+}
+
+void gl4_1compat_glVertexAttrib1s(void *_glfuncs, GLuint index, GLshort x)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib1s(index, x);
+}
+
+void gl4_1compat_glVertexAttrib1fv(void *_glfuncs, GLuint index, const GLfloat* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib1fv(index, v);
+}
+
+void gl4_1compat_glVertexAttrib1f(void *_glfuncs, GLuint index, GLfloat x)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib1f(index, x);
+}
+
+void gl4_1compat_glVertexAttrib1dv(void *_glfuncs, GLuint index, const GLdouble* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib1dv(index, v);
+}
+
+void gl4_1compat_glVertexAttrib1d(void *_glfuncs, GLuint index, GLdouble x)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib1d(index, x);
+}
+
+void gl4_1compat_glVertexAttribI4usv(void *_glfuncs, GLuint index, const GLushort* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI4usv(index, v);
+}
+
+void gl4_1compat_glVertexAttribI4ubv(void *_glfuncs, GLuint index, const GLubyte* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI4ubv(index, v);
+}
+
+void gl4_1compat_glVertexAttribI4sv(void *_glfuncs, GLuint index, const GLshort* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI4sv(index, v);
+}
+
+void gl4_1compat_glVertexAttribI4bv(void *_glfuncs, GLuint index, const GLbyte* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI4bv(index, v);
+}
+
+void gl4_1compat_glVertexAttribI4uiv(void *_glfuncs, GLuint index, const GLuint* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI4uiv(index, v);
+}
+
+void gl4_1compat_glVertexAttribI3uiv(void *_glfuncs, GLuint index, const GLuint* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI3uiv(index, v);
+}
+
+void gl4_1compat_glVertexAttribI2uiv(void *_glfuncs, GLuint index, const GLuint* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI2uiv(index, v);
+}
+
+void gl4_1compat_glVertexAttribI1uiv(void *_glfuncs, GLuint index, const GLuint* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI1uiv(index, v);
+}
+
+void gl4_1compat_glVertexAttribI4iv(void *_glfuncs, GLuint index, const GLint* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI4iv(index, v);
+}
+
+void gl4_1compat_glVertexAttribI3iv(void *_glfuncs, GLuint index, const GLint* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI3iv(index, v);
+}
+
+void gl4_1compat_glVertexAttribI2iv(void *_glfuncs, GLuint index, const GLint* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI2iv(index, v);
+}
+
+void gl4_1compat_glVertexAttribI1iv(void *_glfuncs, GLuint index, const GLint* v)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI1iv(index, v);
+}
+
+void gl4_1compat_glVertexAttribI4ui(void *_glfuncs, GLuint index, GLuint x, GLuint y, GLuint z, GLuint w)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI4ui(index, x, y, z, w);
+}
+
+void gl4_1compat_glVertexAttribI3ui(void *_glfuncs, GLuint index, GLuint x, GLuint y, GLuint z)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI3ui(index, x, y, z);
+}
+
+void gl4_1compat_glVertexAttribI2ui(void *_glfuncs, GLuint index, GLuint x, GLuint y)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI2ui(index, x, y);
+}
+
+void gl4_1compat_glVertexAttribI1ui(void *_glfuncs, GLuint index, GLuint x)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI1ui(index, x);
+}
+
+void gl4_1compat_glVertexAttribI4i(void *_glfuncs, GLuint index, GLint x, GLint y, GLint z, GLint w)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI4i(index, x, y, z, w);
+}
+
+void gl4_1compat_glVertexAttribI3i(void *_glfuncs, GLuint index, GLint x, GLint y, GLint z)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI3i(index, x, y, z);
+}
+
+void gl4_1compat_glVertexAttribI2i(void *_glfuncs, GLuint index, GLint x, GLint y)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI2i(index, x, y);
+}
+
+void gl4_1compat_glVertexAttribI1i(void *_glfuncs, GLuint index, GLint x)
+{
+ QOpenGLFunctions_4_1_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI1i(index, x);
+}
+
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.1compat/funcs.h b/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.1compat/funcs.h
new file mode 100644
index 000000000..3e583ce97
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.1compat/funcs.h
@@ -0,0 +1,920 @@
+
+// ** file automatically generated by glgen -- do not edit manually **
+
+#ifndef __cplusplus
+#include <inttypes.h>
+#include <stddef.h>
+typedef unsigned int GLenum;
+typedef unsigned char GLboolean;
+typedef unsigned int GLbitfield;
+typedef void GLvoid;
+typedef char GLchar;
+typedef signed char GLbyte; /* 1-byte signed */
+typedef short GLshort; /* 2-byte signed */
+typedef int GLint; /* 4-byte signed */
+typedef unsigned char GLubyte; /* 1-byte unsigned */
+typedef unsigned short GLushort; /* 2-byte unsigned */
+typedef unsigned int GLuint; /* 4-byte unsigned */
+typedef int GLsizei; /* 4-byte signed */
+typedef float GLfloat; /* single precision float */
+typedef float GLclampf; /* single precision float in [0,1] */
+typedef double GLdouble; /* double precision float */
+typedef double GLclampd; /* double precision float in [0,1] */
+typedef int64_t GLint64;
+typedef uint64_t GLuint64;
+typedef ptrdiff_t GLintptr;
+typedef ptrdiff_t GLsizeiptr;
+typedef ptrdiff_t GLintptrARB;
+typedef ptrdiff_t GLsizeiptrARB;
+typedef struct __GLsync *GLsync;
+#endif
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+void *gl4_1compat_funcs();
+
+void gl4_1compat_glViewport(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl4_1compat_glDepthRange(void *_glfuncs, GLdouble nearVal, GLdouble farVal);
+GLboolean gl4_1compat_glIsEnabled(void *_glfuncs, GLenum cap);
+void gl4_1compat_glGetTexLevelParameteriv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLint* params);
+void gl4_1compat_glGetTexLevelParameterfv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLfloat* params);
+void gl4_1compat_glGetTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl4_1compat_glGetTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl4_1compat_glGetTexImage(void *_glfuncs, GLenum target, GLint level, GLenum format, GLenum gltype, GLvoid* pixels);
+void gl4_1compat_glGetIntegerv(void *_glfuncs, GLenum pname, GLint* params);
+void gl4_1compat_glGetFloatv(void *_glfuncs, GLenum pname, GLfloat* params);
+GLenum gl4_1compat_glGetError(void *_glfuncs);
+void gl4_1compat_glGetDoublev(void *_glfuncs, GLenum pname, GLdouble* params);
+void gl4_1compat_glGetBooleanv(void *_glfuncs, GLenum pname, GLboolean* params);
+void gl4_1compat_glReadPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum gltype, GLvoid* pixels);
+void gl4_1compat_glReadBuffer(void *_glfuncs, GLenum mode);
+void gl4_1compat_glPixelStorei(void *_glfuncs, GLenum pname, GLint param);
+void gl4_1compat_glPixelStoref(void *_glfuncs, GLenum pname, GLfloat param);
+void gl4_1compat_glDepthFunc(void *_glfuncs, GLenum glfunc);
+void gl4_1compat_glStencilOp(void *_glfuncs, GLenum fail, GLenum zfail, GLenum zpass);
+void gl4_1compat_glStencilFunc(void *_glfuncs, GLenum glfunc, GLint ref, GLuint mask);
+void gl4_1compat_glLogicOp(void *_glfuncs, GLenum opcode);
+void gl4_1compat_glBlendFunc(void *_glfuncs, GLenum sfactor, GLenum dfactor);
+void gl4_1compat_glFlush(void *_glfuncs);
+void gl4_1compat_glFinish(void *_glfuncs);
+void gl4_1compat_glEnable(void *_glfuncs, GLenum cap);
+void gl4_1compat_glDisable(void *_glfuncs, GLenum cap);
+void gl4_1compat_glDepthMask(void *_glfuncs, GLboolean flag);
+void gl4_1compat_glColorMask(void *_glfuncs, GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha);
+void gl4_1compat_glStencilMask(void *_glfuncs, GLuint mask);
+void gl4_1compat_glClearDepth(void *_glfuncs, GLdouble depth);
+void gl4_1compat_glClearStencil(void *_glfuncs, GLint s);
+void gl4_1compat_glClearColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl4_1compat_glClear(void *_glfuncs, GLbitfield mask);
+void gl4_1compat_glDrawBuffer(void *_glfuncs, GLenum mode);
+void gl4_1compat_glTexImage2D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl4_1compat_glTexImage1D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl4_1compat_glTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl4_1compat_glTexParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint param);
+void gl4_1compat_glTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl4_1compat_glTexParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param);
+void gl4_1compat_glScissor(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl4_1compat_glPolygonMode(void *_glfuncs, GLenum face, GLenum mode);
+void gl4_1compat_glPointSize(void *_glfuncs, GLfloat size);
+void gl4_1compat_glLineWidth(void *_glfuncs, GLfloat width);
+void gl4_1compat_glHint(void *_glfuncs, GLenum target, GLenum mode);
+void gl4_1compat_glFrontFace(void *_glfuncs, GLenum mode);
+void gl4_1compat_glCullFace(void *_glfuncs, GLenum mode);
+void gl4_1compat_glIndexubv(void *_glfuncs, const GLubyte* c);
+void gl4_1compat_glIndexub(void *_glfuncs, GLubyte c);
+GLboolean gl4_1compat_glIsTexture(void *_glfuncs, GLuint texture);
+void gl4_1compat_glGenTextures(void *_glfuncs, GLsizei n, GLuint* textures);
+void gl4_1compat_glDeleteTextures(void *_glfuncs, GLsizei n, const GLuint* textures);
+void gl4_1compat_glBindTexture(void *_glfuncs, GLenum target, GLuint texture);
+void gl4_1compat_glTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl4_1compat_glTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl4_1compat_glCopyTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl4_1compat_glCopyTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width);
+void gl4_1compat_glCopyTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border);
+void gl4_1compat_glCopyTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLint border);
+void gl4_1compat_glPolygonOffset(void *_glfuncs, GLfloat factor, GLfloat units);
+void gl4_1compat_glDrawElements(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices);
+void gl4_1compat_glDrawArrays(void *_glfuncs, GLenum mode, GLint first, GLsizei count);
+void gl4_1compat_glCopyTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl4_1compat_glTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl4_1compat_glTexImage3D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl4_1compat_glDrawRangeElements(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices);
+void gl4_1compat_glBlendEquation(void *_glfuncs, GLenum mode);
+void gl4_1compat_glBlendColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl4_1compat_glGetCompressedTexImage(void *_glfuncs, GLenum target, GLint level, GLvoid* img);
+void gl4_1compat_glCompressedTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid* data);
+void gl4_1compat_glCompressedTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid* data);
+void gl4_1compat_glCompressedTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid* data);
+void gl4_1compat_glCompressedTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid* data);
+void gl4_1compat_glCompressedTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid* data);
+void gl4_1compat_glCompressedTexImage3D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid* data);
+void gl4_1compat_glSampleCoverage(void *_glfuncs, GLfloat value, GLboolean invert);
+void gl4_1compat_glActiveTexture(void *_glfuncs, GLenum texture);
+void gl4_1compat_glPointParameteriv(void *_glfuncs, GLenum pname, const GLint* params);
+void gl4_1compat_glPointParameteri(void *_glfuncs, GLenum pname, GLint param);
+void gl4_1compat_glPointParameterfv(void *_glfuncs, GLenum pname, const GLfloat* params);
+void gl4_1compat_glPointParameterf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl4_1compat_glMultiDrawArrays(void *_glfuncs, GLenum mode, const GLint* first, const GLsizei* count, GLsizei drawcount);
+void gl4_1compat_glBlendFuncSeparate(void *_glfuncs, GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha);
+void gl4_1compat_glGetBufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+GLboolean gl4_1compat_glUnmapBuffer(void *_glfuncs, GLenum target);
+void gl4_1compat_glGetBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, GLvoid* data);
+void gl4_1compat_glBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid* data);
+void gl4_1compat_glBufferData(void *_glfuncs, GLenum target, GLsizeiptr size, const GLvoid* data, GLenum usage);
+GLboolean gl4_1compat_glIsBuffer(void *_glfuncs, GLuint buffer);
+void gl4_1compat_glGenBuffers(void *_glfuncs, GLsizei n, GLuint* buffers);
+void gl4_1compat_glDeleteBuffers(void *_glfuncs, GLsizei n, const GLuint* buffers);
+void gl4_1compat_glBindBuffer(void *_glfuncs, GLenum target, GLuint buffer);
+void gl4_1compat_glGetQueryObjectuiv(void *_glfuncs, GLuint id, GLenum pname, GLuint* params);
+void gl4_1compat_glGetQueryObjectiv(void *_glfuncs, GLuint id, GLenum pname, GLint* params);
+void gl4_1compat_glGetQueryiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl4_1compat_glEndQuery(void *_glfuncs, GLenum target);
+void gl4_1compat_glBeginQuery(void *_glfuncs, GLenum target, GLuint id);
+GLboolean gl4_1compat_glIsQuery(void *_glfuncs, GLuint id);
+void gl4_1compat_glDeleteQueries(void *_glfuncs, GLsizei n, const GLuint* ids);
+void gl4_1compat_glGenQueries(void *_glfuncs, GLsizei n, GLuint* ids);
+void gl4_1compat_glVertexAttribPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLboolean normalized, GLsizei stride, const GLvoid* offset);
+void gl4_1compat_glValidateProgram(void *_glfuncs, GLuint program);
+void gl4_1compat_glUniformMatrix4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_1compat_glUniformMatrix3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_1compat_glUniformMatrix2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_1compat_glUniform4iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl4_1compat_glUniform3iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl4_1compat_glUniform2iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl4_1compat_glUniform1iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl4_1compat_glUniform4fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl4_1compat_glUniform3fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl4_1compat_glUniform2fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl4_1compat_glUniform1fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl4_1compat_glUniform4i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2, GLint v3);
+void gl4_1compat_glUniform3i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2);
+void gl4_1compat_glUniform2i(void *_glfuncs, GLint location, GLint v0, GLint v1);
+void gl4_1compat_glUniform1i(void *_glfuncs, GLint location, GLint v0);
+void gl4_1compat_glUniform4f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3);
+void gl4_1compat_glUniform3f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2);
+void gl4_1compat_glUniform2f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1);
+void gl4_1compat_glUniform1f(void *_glfuncs, GLint location, GLfloat v0);
+void gl4_1compat_glUseProgram(void *_glfuncs, GLuint program);
+void gl4_1compat_glShaderSource(void *_glfuncs, GLuint shader, GLsizei count, const GLchar** source, const GLint* length);
+void gl4_1compat_glLinkProgram(void *_glfuncs, GLuint program);
+GLboolean gl4_1compat_glIsShader(void *_glfuncs, GLuint shader);
+GLboolean gl4_1compat_glIsProgram(void *_glfuncs, GLuint program);
+void gl4_1compat_glGetVertexAttribiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params);
+void gl4_1compat_glGetVertexAttribfv(void *_glfuncs, GLuint index, GLenum pname, GLfloat* params);
+void gl4_1compat_glGetVertexAttribdv(void *_glfuncs, GLuint index, GLenum pname, GLdouble* params);
+void gl4_1compat_glGetUniformiv(void *_glfuncs, GLuint program, GLint location, GLint* params);
+void gl4_1compat_glGetUniformfv(void *_glfuncs, GLuint program, GLint location, GLfloat* params);
+GLint gl4_1compat_glGetUniformLocation(void *_glfuncs, GLuint program, const GLchar* name);
+void gl4_1compat_glGetShaderSource(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* source);
+void gl4_1compat_glGetShaderInfoLog(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* infoLog);
+void gl4_1compat_glGetShaderiv(void *_glfuncs, GLuint shader, GLenum pname, GLint* params);
+void gl4_1compat_glGetProgramInfoLog(void *_glfuncs, GLuint program, GLsizei bufSize, GLsizei* length, GLchar* infoLog);
+void gl4_1compat_glGetProgramiv(void *_glfuncs, GLuint program, GLenum pname, GLint* params);
+GLint gl4_1compat_glGetAttribLocation(void *_glfuncs, GLuint program, const GLchar* name);
+void gl4_1compat_glGetAttachedShaders(void *_glfuncs, GLuint program, GLsizei maxCount, GLsizei* count, GLuint* obj);
+void gl4_1compat_glGetActiveUniform(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name);
+void gl4_1compat_glGetActiveAttrib(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name);
+void gl4_1compat_glEnableVertexAttribArray(void *_glfuncs, GLuint index);
+void gl4_1compat_glDisableVertexAttribArray(void *_glfuncs, GLuint index);
+void gl4_1compat_glDetachShader(void *_glfuncs, GLuint program, GLuint shader);
+void gl4_1compat_glDeleteShader(void *_glfuncs, GLuint shader);
+void gl4_1compat_glDeleteProgram(void *_glfuncs, GLuint program);
+GLuint gl4_1compat_glCreateShader(void *_glfuncs, GLenum gltype);
+GLuint gl4_1compat_glCreateProgram(void *_glfuncs);
+void gl4_1compat_glCompileShader(void *_glfuncs, GLuint shader);
+void gl4_1compat_glBindAttribLocation(void *_glfuncs, GLuint program, GLuint index, const GLchar* name);
+void gl4_1compat_glAttachShader(void *_glfuncs, GLuint program, GLuint shader);
+void gl4_1compat_glStencilMaskSeparate(void *_glfuncs, GLenum face, GLuint mask);
+void gl4_1compat_glStencilFuncSeparate(void *_glfuncs, GLenum face, GLenum glfunc, GLint ref, GLuint mask);
+void gl4_1compat_glStencilOpSeparate(void *_glfuncs, GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass);
+void gl4_1compat_glDrawBuffers(void *_glfuncs, GLsizei n, const GLenum* bufs);
+void gl4_1compat_glBlendEquationSeparate(void *_glfuncs, GLenum modeRGB, GLenum modeAlpha);
+void gl4_1compat_glUniformMatrix4x3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_1compat_glUniformMatrix3x4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_1compat_glUniformMatrix4x2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_1compat_glUniformMatrix2x4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_1compat_glUniformMatrix3x2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_1compat_glUniformMatrix2x3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+GLboolean gl4_1compat_glIsVertexArray(void *_glfuncs, GLuint array);
+void gl4_1compat_glGenVertexArrays(void *_glfuncs, GLsizei n, GLuint* arrays);
+void gl4_1compat_glDeleteVertexArrays(void *_glfuncs, GLsizei n, const GLuint* arrays);
+void gl4_1compat_glBindVertexArray(void *_glfuncs, GLuint array);
+void gl4_1compat_glFlushMappedBufferRange(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr length);
+void gl4_1compat_glFramebufferTextureLayer(void *_glfuncs, GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer);
+void gl4_1compat_glRenderbufferStorageMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLenum internalFormat, GLsizei width, GLsizei height);
+void gl4_1compat_glBlitFramebuffer(void *_glfuncs, GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter);
+void gl4_1compat_glGenerateMipmap(void *_glfuncs, GLenum target);
+void gl4_1compat_glGetFramebufferAttachmentParameteriv(void *_glfuncs, GLenum target, GLenum attachment, GLenum pname, GLint* params);
+void gl4_1compat_glFramebufferRenderbuffer(void *_glfuncs, GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer);
+void gl4_1compat_glFramebufferTexture3D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset);
+void gl4_1compat_glFramebufferTexture2D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+void gl4_1compat_glFramebufferTexture1D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+GLenum gl4_1compat_glCheckFramebufferStatus(void *_glfuncs, GLenum target);
+void gl4_1compat_glGenFramebuffers(void *_glfuncs, GLsizei n, GLuint* framebuffers);
+void gl4_1compat_glDeleteFramebuffers(void *_glfuncs, GLsizei n, const GLuint* framebuffers);
+void gl4_1compat_glBindFramebuffer(void *_glfuncs, GLenum target, GLuint framebuffer);
+GLboolean gl4_1compat_glIsFramebuffer(void *_glfuncs, GLuint framebuffer);
+void gl4_1compat_glGetRenderbufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl4_1compat_glRenderbufferStorage(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height);
+void gl4_1compat_glGenRenderbuffers(void *_glfuncs, GLsizei n, GLuint* renderbuffers);
+void gl4_1compat_glDeleteRenderbuffers(void *_glfuncs, GLsizei n, const GLuint* renderbuffers);
+void gl4_1compat_glBindRenderbuffer(void *_glfuncs, GLenum target, GLuint renderbuffer);
+GLboolean gl4_1compat_glIsRenderbuffer(void *_glfuncs, GLuint renderbuffer);
+void gl4_1compat_glClearBufferfi(void *_glfuncs, GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil);
+void gl4_1compat_glClearBufferfv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLfloat* value);
+void gl4_1compat_glClearBufferuiv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLuint* value);
+void gl4_1compat_glClearBufferiv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLint* value);
+void gl4_1compat_glGetTexParameterIuiv(void *_glfuncs, GLenum target, GLenum pname, GLuint* params);
+void gl4_1compat_glGetTexParameterIiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl4_1compat_glTexParameterIuiv(void *_glfuncs, GLenum target, GLenum pname, const GLuint* params);
+void gl4_1compat_glTexParameterIiv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl4_1compat_glUniform4uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value);
+void gl4_1compat_glUniform3uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value);
+void gl4_1compat_glUniform2uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value);
+void gl4_1compat_glUniform1uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value);
+void gl4_1compat_glUniform4ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3);
+void gl4_1compat_glUniform3ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1, GLuint v2);
+void gl4_1compat_glUniform2ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1);
+void gl4_1compat_glUniform1ui(void *_glfuncs, GLint location, GLuint v0);
+GLint gl4_1compat_glGetFragDataLocation(void *_glfuncs, GLuint program, const GLchar* name);
+void gl4_1compat_glBindFragDataLocation(void *_glfuncs, GLuint program, GLuint color, const GLchar* name);
+void gl4_1compat_glGetUniformuiv(void *_glfuncs, GLuint program, GLint location, GLuint* params);
+void gl4_1compat_glGetVertexAttribIuiv(void *_glfuncs, GLuint index, GLenum pname, GLuint* params);
+void gl4_1compat_glGetVertexAttribIiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params);
+void gl4_1compat_glVertexAttribIPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl4_1compat_glEndConditionalRender(void *_glfuncs);
+void gl4_1compat_glBeginConditionalRender(void *_glfuncs, GLuint id, GLenum mode);
+void gl4_1compat_glClampColor(void *_glfuncs, GLenum target, GLenum clamp);
+void gl4_1compat_glGetTransformFeedbackVarying(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLsizei* size, GLenum* gltype, GLchar* name);
+void gl4_1compat_glBindBufferBase(void *_glfuncs, GLenum target, GLuint index, GLuint buffer);
+void gl4_1compat_glBindBufferRange(void *_glfuncs, GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size);
+void gl4_1compat_glEndTransformFeedback(void *_glfuncs);
+void gl4_1compat_glBeginTransformFeedback(void *_glfuncs, GLenum primitiveMode);
+GLboolean gl4_1compat_glIsEnabledi(void *_glfuncs, GLenum target, GLuint index);
+void gl4_1compat_glDisablei(void *_glfuncs, GLenum target, GLuint index);
+void gl4_1compat_glEnablei(void *_glfuncs, GLenum target, GLuint index);
+void gl4_1compat_glGetIntegeri_v(void *_glfuncs, GLenum target, GLuint index, GLint* data);
+void gl4_1compat_glGetBooleani_v(void *_glfuncs, GLenum target, GLuint index, GLboolean* data);
+void gl4_1compat_glColorMaski(void *_glfuncs, GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a);
+void gl4_1compat_glCopyBufferSubData(void *_glfuncs, GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size);
+void gl4_1compat_glUniformBlockBinding(void *_glfuncs, GLuint program, GLuint v0, GLuint v1);
+void gl4_1compat_glGetActiveUniformBlockName(void *_glfuncs, GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei* length, GLchar* uniformBlockName);
+void gl4_1compat_glGetActiveUniformBlockiv(void *_glfuncs, GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint* params);
+GLuint gl4_1compat_glGetUniformBlockIndex(void *_glfuncs, GLuint program, const GLchar* uniformBlockName);
+void gl4_1compat_glGetActiveUniformName(void *_glfuncs, GLuint program, GLuint uniformIndex, GLsizei bufSize, GLsizei* length, GLchar* uniformName);
+void gl4_1compat_glGetActiveUniformsiv(void *_glfuncs, GLuint program, GLsizei uniformCount, const GLuint* uniformIndices, GLenum pname, GLint* params);
+void gl4_1compat_glPrimitiveRestartIndex(void *_glfuncs, GLuint index);
+void gl4_1compat_glTexBuffer(void *_glfuncs, GLenum target, GLenum internalFormat, GLuint buffer);
+void gl4_1compat_glDrawElementsInstanced(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount);
+void gl4_1compat_glDrawArraysInstanced(void *_glfuncs, GLenum mode, GLint first, GLsizei count, GLsizei instancecount);
+void gl4_1compat_glSampleMaski(void *_glfuncs, GLuint index, GLbitfield mask);
+void gl4_1compat_glGetMultisamplefv(void *_glfuncs, GLenum pname, GLuint index, GLfloat* val);
+void gl4_1compat_glTexImage3DMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations);
+void gl4_1compat_glTexImage2DMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLint internalFormat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations);
+void gl4_1compat_glGetSynciv(void *_glfuncs, GLsync sync, GLenum pname, GLsizei bufSize, GLsizei* length, GLint* values);
+void gl4_1compat_glGetInteger64v(void *_glfuncs, GLenum pname, GLint64* params);
+void gl4_1compat_glWaitSync(void *_glfuncs, GLsync sync, GLbitfield flags, GLuint64 timeout);
+GLenum gl4_1compat_glClientWaitSync(void *_glfuncs, GLsync sync, GLbitfield flags, GLuint64 timeout);
+void gl4_1compat_glDeleteSync(void *_glfuncs, GLsync sync);
+GLboolean gl4_1compat_glIsSync(void *_glfuncs, GLsync sync);
+GLsync gl4_1compat_glFenceSync(void *_glfuncs, GLenum condition, GLbitfield flags);
+void gl4_1compat_glProvokingVertex(void *_glfuncs, GLenum mode);
+void gl4_1compat_glDrawElementsInstancedBaseVertex(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount, GLint basevertex);
+void gl4_1compat_glDrawRangeElementsBaseVertex(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices, GLint basevertex);
+void gl4_1compat_glDrawElementsBaseVertex(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLint basevertex);
+void gl4_1compat_glFramebufferTexture(void *_glfuncs, GLenum target, GLenum attachment, GLuint texture, GLint level);
+void gl4_1compat_glGetBufferParameteri64v(void *_glfuncs, GLenum target, GLenum pname, GLint64* params);
+void gl4_1compat_glGetInteger64i_v(void *_glfuncs, GLenum target, GLuint index, GLint64* data);
+void gl4_1compat_glVertexAttribP4uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value);
+void gl4_1compat_glVertexAttribP4ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value);
+void gl4_1compat_glVertexAttribP3uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value);
+void gl4_1compat_glVertexAttribP3ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value);
+void gl4_1compat_glVertexAttribP2uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value);
+void gl4_1compat_glVertexAttribP2ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value);
+void gl4_1compat_glVertexAttribP1uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value);
+void gl4_1compat_glVertexAttribP1ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value);
+void gl4_1compat_glSecondaryColorP3uiv(void *_glfuncs, GLenum gltype, const GLuint* color);
+void gl4_1compat_glSecondaryColorP3ui(void *_glfuncs, GLenum gltype, GLuint color);
+void gl4_1compat_glColorP4uiv(void *_glfuncs, GLenum gltype, const GLuint* color);
+void gl4_1compat_glColorP4ui(void *_glfuncs, GLenum gltype, GLuint color);
+void gl4_1compat_glColorP3uiv(void *_glfuncs, GLenum gltype, const GLuint* color);
+void gl4_1compat_glColorP3ui(void *_glfuncs, GLenum gltype, GLuint color);
+void gl4_1compat_glNormalP3uiv(void *_glfuncs, GLenum gltype, const GLuint* coords);
+void gl4_1compat_glNormalP3ui(void *_glfuncs, GLenum gltype, GLuint coords);
+void gl4_1compat_glMultiTexCoordP4uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords);
+void gl4_1compat_glMultiTexCoordP4ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords);
+void gl4_1compat_glMultiTexCoordP3uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords);
+void gl4_1compat_glMultiTexCoordP3ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords);
+void gl4_1compat_glMultiTexCoordP2uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords);
+void gl4_1compat_glMultiTexCoordP2ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords);
+void gl4_1compat_glMultiTexCoordP1uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords);
+void gl4_1compat_glMultiTexCoordP1ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords);
+void gl4_1compat_glTexCoordP4uiv(void *_glfuncs, GLenum gltype, const GLuint* coords);
+void gl4_1compat_glTexCoordP4ui(void *_glfuncs, GLenum gltype, GLuint coords);
+void gl4_1compat_glTexCoordP3uiv(void *_glfuncs, GLenum gltype, const GLuint* coords);
+void gl4_1compat_glTexCoordP3ui(void *_glfuncs, GLenum gltype, GLuint coords);
+void gl4_1compat_glTexCoordP2uiv(void *_glfuncs, GLenum gltype, const GLuint* coords);
+void gl4_1compat_glTexCoordP2ui(void *_glfuncs, GLenum gltype, GLuint coords);
+void gl4_1compat_glTexCoordP1uiv(void *_glfuncs, GLenum gltype, const GLuint* coords);
+void gl4_1compat_glTexCoordP1ui(void *_glfuncs, GLenum gltype, GLuint coords);
+void gl4_1compat_glVertexP4uiv(void *_glfuncs, GLenum gltype, const GLuint* value);
+void gl4_1compat_glVertexP4ui(void *_glfuncs, GLenum gltype, GLuint value);
+void gl4_1compat_glVertexP3uiv(void *_glfuncs, GLenum gltype, const GLuint* value);
+void gl4_1compat_glVertexP3ui(void *_glfuncs, GLenum gltype, GLuint value);
+void gl4_1compat_glVertexP2uiv(void *_glfuncs, GLenum gltype, const GLuint* value);
+void gl4_1compat_glVertexP2ui(void *_glfuncs, GLenum gltype, GLuint value);
+void gl4_1compat_glGetQueryObjectui64v(void *_glfuncs, GLuint id, GLenum pname, GLuint64* params);
+void gl4_1compat_glGetQueryObjecti64v(void *_glfuncs, GLuint id, GLenum pname, GLint64* params);
+void gl4_1compat_glQueryCounter(void *_glfuncs, GLuint id, GLenum target);
+void gl4_1compat_glGetSamplerParameterIuiv(void *_glfuncs, GLuint sampler, GLenum pname, GLuint* params);
+void gl4_1compat_glGetSamplerParameterfv(void *_glfuncs, GLuint sampler, GLenum pname, GLfloat* params);
+void gl4_1compat_glGetSamplerParameterIiv(void *_glfuncs, GLuint sampler, GLenum pname, GLint* params);
+void gl4_1compat_glGetSamplerParameteriv(void *_glfuncs, GLuint sampler, GLenum pname, GLint* params);
+void gl4_1compat_glSamplerParameterIuiv(void *_glfuncs, GLuint sampler, GLenum pname, const GLuint* param);
+void gl4_1compat_glSamplerParameterIiv(void *_glfuncs, GLuint sampler, GLenum pname, const GLint* param);
+void gl4_1compat_glSamplerParameterfv(void *_glfuncs, GLuint sampler, GLenum pname, const GLfloat* param);
+void gl4_1compat_glSamplerParameterf(void *_glfuncs, GLuint sampler, GLenum pname, GLfloat param);
+void gl4_1compat_glSamplerParameteriv(void *_glfuncs, GLuint sampler, GLenum pname, const GLint* param);
+void gl4_1compat_glSamplerParameteri(void *_glfuncs, GLuint sampler, GLenum pname, GLint param);
+void gl4_1compat_glBindSampler(void *_glfuncs, GLuint unit, GLuint sampler);
+GLboolean gl4_1compat_glIsSampler(void *_glfuncs, GLuint sampler);
+void gl4_1compat_glDeleteSamplers(void *_glfuncs, GLsizei count, const GLuint* samplers);
+void gl4_1compat_glGenSamplers(void *_glfuncs, GLsizei count, GLuint* samplers);
+GLint gl4_1compat_glGetFragDataIndex(void *_glfuncs, GLuint program, const GLchar* name);
+void gl4_1compat_glBindFragDataLocationIndexed(void *_glfuncs, GLuint program, GLuint colorNumber, GLuint index, const GLchar* name);
+void gl4_1compat_glVertexAttribDivisor(void *_glfuncs, GLuint index, GLuint divisor);
+void gl4_1compat_glGetQueryIndexediv(void *_glfuncs, GLenum target, GLuint index, GLenum pname, GLint* params);
+void gl4_1compat_glEndQueryIndexed(void *_glfuncs, GLenum target, GLuint index);
+void gl4_1compat_glBeginQueryIndexed(void *_glfuncs, GLenum target, GLuint index, GLuint id);
+void gl4_1compat_glDrawTransformFeedbackStream(void *_glfuncs, GLenum mode, GLuint id, GLuint stream);
+void gl4_1compat_glDrawTransformFeedback(void *_glfuncs, GLenum mode, GLuint id);
+void gl4_1compat_glResumeTransformFeedback(void *_glfuncs);
+void gl4_1compat_glPauseTransformFeedback(void *_glfuncs);
+GLboolean gl4_1compat_glIsTransformFeedback(void *_glfuncs, GLuint id);
+void gl4_1compat_glGenTransformFeedbacks(void *_glfuncs, GLsizei n, GLuint* ids);
+void gl4_1compat_glDeleteTransformFeedbacks(void *_glfuncs, GLsizei n, const GLuint* ids);
+void gl4_1compat_glBindTransformFeedback(void *_glfuncs, GLenum target, GLuint id);
+void gl4_1compat_glPatchParameterfv(void *_glfuncs, GLenum pname, const GLfloat* values);
+void gl4_1compat_glPatchParameteri(void *_glfuncs, GLenum pname, GLint value);
+void gl4_1compat_glGetProgramStageiv(void *_glfuncs, GLuint program, GLenum shadertype, GLenum pname, GLint* values);
+void gl4_1compat_glGetUniformSubroutineuiv(void *_glfuncs, GLenum shadertype, GLint location, GLuint* params);
+void gl4_1compat_glUniformSubroutinesuiv(void *_glfuncs, GLenum shadertype, GLsizei count, const GLuint* value);
+void gl4_1compat_glGetActiveSubroutineName(void *_glfuncs, GLuint program, GLenum shadertype, GLuint index, GLsizei bufSize, GLsizei* length, GLchar* name);
+void gl4_1compat_glGetActiveSubroutineUniformName(void *_glfuncs, GLuint program, GLenum shadertype, GLuint index, GLsizei bufSize, GLsizei* length, GLchar* name);
+void gl4_1compat_glGetActiveSubroutineUniformiv(void *_glfuncs, GLuint program, GLenum shadertype, GLuint index, GLenum pname, GLint* values);
+GLuint gl4_1compat_glGetSubroutineIndex(void *_glfuncs, GLuint program, GLenum shadertype, const GLchar* name);
+GLint gl4_1compat_glGetSubroutineUniformLocation(void *_glfuncs, GLuint program, GLenum shadertype, const GLchar* name);
+void gl4_1compat_glGetUniformdv(void *_glfuncs, GLuint program, GLint location, GLdouble* params);
+void gl4_1compat_glUniformMatrix4x3dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_1compat_glUniformMatrix4x2dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_1compat_glUniformMatrix3x4dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_1compat_glUniformMatrix3x2dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_1compat_glUniformMatrix2x4dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_1compat_glUniformMatrix2x3dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_1compat_glUniformMatrix4dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_1compat_glUniformMatrix3dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_1compat_glUniformMatrix2dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_1compat_glUniform4dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value);
+void gl4_1compat_glUniform3dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value);
+void gl4_1compat_glUniform2dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value);
+void gl4_1compat_glUniform1dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value);
+void gl4_1compat_glUniform4d(void *_glfuncs, GLint location, GLdouble v0, GLdouble v1, GLdouble v2, GLdouble v3);
+void gl4_1compat_glUniform3d(void *_glfuncs, GLint location, GLdouble v0, GLdouble v1, GLdouble v2);
+void gl4_1compat_glUniform2d(void *_glfuncs, GLint location, GLdouble v0, GLdouble v1);
+void gl4_1compat_glUniform1d(void *_glfuncs, GLint location, GLdouble v0);
+void gl4_1compat_glDrawElementsIndirect(void *_glfuncs, GLenum mode, GLenum gltype, const GLvoid* indirect);
+void gl4_1compat_glDrawArraysIndirect(void *_glfuncs, GLenum mode, const GLvoid* indirect);
+void gl4_1compat_glBlendFuncSeparatei(void *_glfuncs, GLuint buf, GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha, GLenum dstAlpha);
+void gl4_1compat_glBlendFunci(void *_glfuncs, GLuint buf, GLenum src, GLenum dst);
+void gl4_1compat_glBlendEquationSeparatei(void *_glfuncs, GLuint buf, GLenum modeRGB, GLenum modeAlpha);
+void gl4_1compat_glBlendEquationi(void *_glfuncs, GLuint buf, GLenum mode);
+void gl4_1compat_glMinSampleShading(void *_glfuncs, GLfloat value);
+void gl4_1compat_glGetDoublei_v(void *_glfuncs, GLenum target, GLuint index, GLdouble* data);
+void gl4_1compat_glGetFloati_v(void *_glfuncs, GLenum target, GLuint index, GLfloat* data);
+void gl4_1compat_glDepthRangeIndexed(void *_glfuncs, GLuint index, GLdouble n, GLdouble f);
+void gl4_1compat_glDepthRangeArrayv(void *_glfuncs, GLuint first, GLsizei count, const GLdouble* v);
+void gl4_1compat_glScissorIndexedv(void *_glfuncs, GLuint index, const GLint* v);
+void gl4_1compat_glScissorIndexed(void *_glfuncs, GLuint index, GLint left, GLint bottom, GLsizei width, GLsizei height);
+void gl4_1compat_glScissorArrayv(void *_glfuncs, GLuint first, GLsizei count, const GLint* v);
+void gl4_1compat_glViewportIndexedfv(void *_glfuncs, GLuint index, const GLfloat* v);
+void gl4_1compat_glViewportIndexedf(void *_glfuncs, GLuint index, GLfloat x, GLfloat y, GLfloat w, GLfloat h);
+void gl4_1compat_glViewportArrayv(void *_glfuncs, GLuint first, GLsizei count, const GLfloat* v);
+void gl4_1compat_glGetVertexAttribLdv(void *_glfuncs, GLuint index, GLenum pname, GLdouble* params);
+void gl4_1compat_glVertexAttribLPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl4_1compat_glVertexAttribL4dv(void *_glfuncs, GLuint index, const GLdouble* v);
+void gl4_1compat_glVertexAttribL3dv(void *_glfuncs, GLuint index, const GLdouble* v);
+void gl4_1compat_glVertexAttribL2dv(void *_glfuncs, GLuint index, const GLdouble* v);
+void gl4_1compat_glVertexAttribL1dv(void *_glfuncs, GLuint index, const GLdouble* v);
+void gl4_1compat_glVertexAttribL4d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+void gl4_1compat_glVertexAttribL3d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y, GLdouble z);
+void gl4_1compat_glVertexAttribL2d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y);
+void gl4_1compat_glVertexAttribL1d(void *_glfuncs, GLuint index, GLdouble x);
+void gl4_1compat_glGetProgramPipelineInfoLog(void *_glfuncs, GLuint pipeline, GLsizei bufSize, GLsizei* length, GLchar* infoLog);
+void gl4_1compat_glValidateProgramPipeline(void *_glfuncs, GLuint pipeline);
+void gl4_1compat_glProgramUniformMatrix4x3dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_1compat_glProgramUniformMatrix3x4dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_1compat_glProgramUniformMatrix4x2dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_1compat_glProgramUniformMatrix2x4dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_1compat_glProgramUniformMatrix3x2dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_1compat_glProgramUniformMatrix2x3dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_1compat_glProgramUniformMatrix4x3fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_1compat_glProgramUniformMatrix3x4fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_1compat_glProgramUniformMatrix4x2fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_1compat_glProgramUniformMatrix2x4fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_1compat_glProgramUniformMatrix3x2fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_1compat_glProgramUniformMatrix2x3fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_1compat_glProgramUniformMatrix4dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_1compat_glProgramUniformMatrix3dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_1compat_glProgramUniformMatrix2dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_1compat_glProgramUniformMatrix4fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_1compat_glProgramUniformMatrix3fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_1compat_glProgramUniformMatrix2fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_1compat_glProgramUniform4uiv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLuint* value);
+void gl4_1compat_glProgramUniform4ui(void *_glfuncs, GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3);
+void gl4_1compat_glProgramUniform4dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLdouble* value);
+void gl4_1compat_glProgramUniform4d(void *_glfuncs, GLuint program, GLint location, GLdouble v0, GLdouble v1, GLdouble v2, GLdouble v3);
+void gl4_1compat_glProgramUniform4fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLfloat* value);
+void gl4_1compat_glProgramUniform4f(void *_glfuncs, GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3);
+void gl4_1compat_glProgramUniform4iv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLint* value);
+void gl4_1compat_glProgramUniform4i(void *_glfuncs, GLuint program, GLint location, GLint v0, GLint v1, GLint v2, GLint v3);
+void gl4_1compat_glProgramUniform3uiv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLuint* value);
+void gl4_1compat_glProgramUniform3ui(void *_glfuncs, GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2);
+void gl4_1compat_glProgramUniform3dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLdouble* value);
+void gl4_1compat_glProgramUniform3d(void *_glfuncs, GLuint program, GLint location, GLdouble v0, GLdouble v1, GLdouble v2);
+void gl4_1compat_glProgramUniform3fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLfloat* value);
+void gl4_1compat_glProgramUniform3f(void *_glfuncs, GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2);
+void gl4_1compat_glProgramUniform3iv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLint* value);
+void gl4_1compat_glProgramUniform3i(void *_glfuncs, GLuint program, GLint location, GLint v0, GLint v1, GLint v2);
+void gl4_1compat_glProgramUniform2uiv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLuint* value);
+void gl4_1compat_glProgramUniform2ui(void *_glfuncs, GLuint program, GLint location, GLuint v0, GLuint v1);
+void gl4_1compat_glProgramUniform2dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLdouble* value);
+void gl4_1compat_glProgramUniform2d(void *_glfuncs, GLuint program, GLint location, GLdouble v0, GLdouble v1);
+void gl4_1compat_glProgramUniform2fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLfloat* value);
+void gl4_1compat_glProgramUniform2f(void *_glfuncs, GLuint program, GLint location, GLfloat v0, GLfloat v1);
+void gl4_1compat_glProgramUniform2iv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLint* value);
+void gl4_1compat_glProgramUniform2i(void *_glfuncs, GLuint program, GLint location, GLint v0, GLint v1);
+void gl4_1compat_glProgramUniform1uiv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLuint* value);
+void gl4_1compat_glProgramUniform1ui(void *_glfuncs, GLuint program, GLint location, GLuint v0);
+void gl4_1compat_glProgramUniform1dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLdouble* value);
+void gl4_1compat_glProgramUniform1d(void *_glfuncs, GLuint program, GLint location, GLdouble v0);
+void gl4_1compat_glProgramUniform1fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLfloat* value);
+void gl4_1compat_glProgramUniform1f(void *_glfuncs, GLuint program, GLint location, GLfloat v0);
+void gl4_1compat_glProgramUniform1iv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLint* value);
+void gl4_1compat_glProgramUniform1i(void *_glfuncs, GLuint program, GLint location, GLint v0);
+void gl4_1compat_glGetProgramPipelineiv(void *_glfuncs, GLuint pipeline, GLenum pname, GLint* params);
+GLboolean gl4_1compat_glIsProgramPipeline(void *_glfuncs, GLuint pipeline);
+void gl4_1compat_glGenProgramPipelines(void *_glfuncs, GLsizei n, GLuint* pipelines);
+void gl4_1compat_glDeleteProgramPipelines(void *_glfuncs, GLsizei n, const GLuint* pipelines);
+void gl4_1compat_glBindProgramPipeline(void *_glfuncs, GLuint pipeline);
+void gl4_1compat_glActiveShaderProgram(void *_glfuncs, GLuint pipeline, GLuint program);
+void gl4_1compat_glUseProgramStages(void *_glfuncs, GLuint pipeline, GLbitfield stages, GLuint program);
+void gl4_1compat_glProgramParameteri(void *_glfuncs, GLuint program, GLenum pname, GLint value);
+void gl4_1compat_glProgramBinary(void *_glfuncs, GLuint program, GLenum binaryFormat, const GLvoid* binary, GLsizei length);
+void gl4_1compat_glGetProgramBinary(void *_glfuncs, GLuint program, GLsizei bufSize, GLsizei* length, GLenum* binaryFormat, GLvoid* binary);
+void gl4_1compat_glClearDepthf(void *_glfuncs, GLfloat dd);
+void gl4_1compat_glDepthRangef(void *_glfuncs, GLfloat n, GLfloat f);
+void gl4_1compat_glGetShaderPrecisionFormat(void *_glfuncs, GLenum shadertype, GLenum precisionType, GLint* range_, GLint* precision);
+void gl4_1compat_glShaderBinary(void *_glfuncs, GLsizei count, const GLuint* shaders, GLenum binaryFormat, const GLvoid* binary, GLsizei length);
+void gl4_1compat_glReleaseShaderCompiler(void *_glfuncs);
+void gl4_1compat_glTranslatef(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl4_1compat_glTranslated(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl4_1compat_glScalef(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl4_1compat_glScaled(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl4_1compat_glRotatef(void *_glfuncs, GLfloat angle, GLfloat x, GLfloat y, GLfloat z);
+void gl4_1compat_glRotated(void *_glfuncs, GLdouble angle, GLdouble x, GLdouble y, GLdouble z);
+void gl4_1compat_glPushMatrix(void *_glfuncs);
+void gl4_1compat_glPopMatrix(void *_glfuncs);
+void gl4_1compat_glOrtho(void *_glfuncs, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+void gl4_1compat_glMultMatrixd(void *_glfuncs, const GLdouble* m);
+void gl4_1compat_glMultMatrixf(void *_glfuncs, const GLfloat* m);
+void gl4_1compat_glMatrixMode(void *_glfuncs, GLenum mode);
+void gl4_1compat_glLoadMatrixd(void *_glfuncs, const GLdouble* m);
+void gl4_1compat_glLoadMatrixf(void *_glfuncs, const GLfloat* m);
+void gl4_1compat_glLoadIdentity(void *_glfuncs);
+void gl4_1compat_glFrustum(void *_glfuncs, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+GLboolean gl4_1compat_glIsList(void *_glfuncs, GLuint list);
+void gl4_1compat_glGetTexGeniv(void *_glfuncs, GLenum coord, GLenum pname, GLint* params);
+void gl4_1compat_glGetTexGenfv(void *_glfuncs, GLenum coord, GLenum pname, GLfloat* params);
+void gl4_1compat_glGetTexGendv(void *_glfuncs, GLenum coord, GLenum pname, GLdouble* params);
+void gl4_1compat_glGetTexEnviv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl4_1compat_glGetTexEnvfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl4_1compat_glGetPolygonStipple(void *_glfuncs, GLubyte* mask);
+void gl4_1compat_glGetPixelMapusv(void *_glfuncs, GLenum glmap, GLushort* values);
+void gl4_1compat_glGetPixelMapuiv(void *_glfuncs, GLenum glmap, GLuint* values);
+void gl4_1compat_glGetPixelMapfv(void *_glfuncs, GLenum glmap, GLfloat* values);
+void gl4_1compat_glGetMaterialiv(void *_glfuncs, GLenum face, GLenum pname, GLint* params);
+void gl4_1compat_glGetMaterialfv(void *_glfuncs, GLenum face, GLenum pname, GLfloat* params);
+void gl4_1compat_glGetMapiv(void *_glfuncs, GLenum target, GLenum query, GLint* v);
+void gl4_1compat_glGetMapfv(void *_glfuncs, GLenum target, GLenum query, GLfloat* v);
+void gl4_1compat_glGetMapdv(void *_glfuncs, GLenum target, GLenum query, GLdouble* v);
+void gl4_1compat_glGetLightiv(void *_glfuncs, GLenum light, GLenum pname, GLint* params);
+void gl4_1compat_glGetLightfv(void *_glfuncs, GLenum light, GLenum pname, GLfloat* params);
+void gl4_1compat_glGetClipPlane(void *_glfuncs, GLenum plane, GLdouble* equation);
+void gl4_1compat_glDrawPixels(void *_glfuncs, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl4_1compat_glCopyPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum gltype);
+void gl4_1compat_glPixelMapusv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLushort* values);
+void gl4_1compat_glPixelMapuiv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLuint* values);
+void gl4_1compat_glPixelMapfv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLfloat* values);
+void gl4_1compat_glPixelTransferi(void *_glfuncs, GLenum pname, GLint param);
+void gl4_1compat_glPixelTransferf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl4_1compat_glPixelZoom(void *_glfuncs, GLfloat xfactor, GLfloat yfactor);
+void gl4_1compat_glAlphaFunc(void *_glfuncs, GLenum glfunc, GLfloat ref);
+void gl4_1compat_glEvalPoint2(void *_glfuncs, GLint i, GLint j);
+void gl4_1compat_glEvalMesh2(void *_glfuncs, GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2);
+void gl4_1compat_glEvalPoint1(void *_glfuncs, GLint i);
+void gl4_1compat_glEvalMesh1(void *_glfuncs, GLenum mode, GLint i1, GLint i2);
+void gl4_1compat_glEvalCoord2fv(void *_glfuncs, const GLfloat* u);
+void gl4_1compat_glEvalCoord2f(void *_glfuncs, GLfloat u, GLfloat v);
+void gl4_1compat_glEvalCoord2dv(void *_glfuncs, const GLdouble* u);
+void gl4_1compat_glEvalCoord2d(void *_glfuncs, GLdouble u, GLdouble v);
+void gl4_1compat_glEvalCoord1fv(void *_glfuncs, const GLfloat* u);
+void gl4_1compat_glEvalCoord1f(void *_glfuncs, GLfloat u);
+void gl4_1compat_glEvalCoord1dv(void *_glfuncs, const GLdouble* u);
+void gl4_1compat_glEvalCoord1d(void *_glfuncs, GLdouble u);
+void gl4_1compat_glMapGrid2f(void *_glfuncs, GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2);
+void gl4_1compat_glMapGrid2d(void *_glfuncs, GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2);
+void gl4_1compat_glMapGrid1f(void *_glfuncs, GLint un, GLfloat u1, GLfloat u2);
+void gl4_1compat_glMapGrid1d(void *_glfuncs, GLint un, GLdouble u1, GLdouble u2);
+void gl4_1compat_glMap2f(void *_glfuncs, GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat* points);
+void gl4_1compat_glMap2d(void *_glfuncs, GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble* points);
+void gl4_1compat_glMap1f(void *_glfuncs, GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat* points);
+void gl4_1compat_glMap1d(void *_glfuncs, GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble* points);
+void gl4_1compat_glPushAttrib(void *_glfuncs, GLbitfield mask);
+void gl4_1compat_glPopAttrib(void *_glfuncs);
+void gl4_1compat_glAccum(void *_glfuncs, GLenum op, GLfloat value);
+void gl4_1compat_glIndexMask(void *_glfuncs, GLuint mask);
+void gl4_1compat_glClearIndex(void *_glfuncs, GLfloat c);
+void gl4_1compat_glClearAccum(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl4_1compat_glPushName(void *_glfuncs, GLuint name);
+void gl4_1compat_glPopName(void *_glfuncs);
+void gl4_1compat_glPassThrough(void *_glfuncs, GLfloat token);
+void gl4_1compat_glLoadName(void *_glfuncs, GLuint name);
+void gl4_1compat_glInitNames(void *_glfuncs);
+GLint gl4_1compat_glRenderMode(void *_glfuncs, GLenum mode);
+void gl4_1compat_glSelectBuffer(void *_glfuncs, GLsizei size, GLuint* buffer);
+void gl4_1compat_glFeedbackBuffer(void *_glfuncs, GLsizei size, GLenum gltype, GLfloat* buffer);
+void gl4_1compat_glTexGeniv(void *_glfuncs, GLenum coord, GLenum pname, const GLint* params);
+void gl4_1compat_glTexGeni(void *_glfuncs, GLenum coord, GLenum pname, GLint param);
+void gl4_1compat_glTexGenfv(void *_glfuncs, GLenum coord, GLenum pname, const GLfloat* params);
+void gl4_1compat_glTexGenf(void *_glfuncs, GLenum coord, GLenum pname, GLfloat param);
+void gl4_1compat_glTexGendv(void *_glfuncs, GLenum coord, GLenum pname, const GLdouble* params);
+void gl4_1compat_glTexGend(void *_glfuncs, GLenum coord, GLenum pname, GLdouble param);
+void gl4_1compat_glTexEnviv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl4_1compat_glTexEnvi(void *_glfuncs, GLenum target, GLenum pname, GLint param);
+void gl4_1compat_glTexEnvfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl4_1compat_glTexEnvf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param);
+void gl4_1compat_glShadeModel(void *_glfuncs, GLenum mode);
+void gl4_1compat_glPolygonStipple(void *_glfuncs, const GLubyte* mask);
+void gl4_1compat_glMaterialiv(void *_glfuncs, GLenum face, GLenum pname, const GLint* params);
+void gl4_1compat_glMateriali(void *_glfuncs, GLenum face, GLenum pname, GLint param);
+void gl4_1compat_glMaterialfv(void *_glfuncs, GLenum face, GLenum pname, const GLfloat* params);
+void gl4_1compat_glMaterialf(void *_glfuncs, GLenum face, GLenum pname, GLfloat param);
+void gl4_1compat_glLineStipple(void *_glfuncs, GLint factor, GLushort pattern);
+void gl4_1compat_glLightModeliv(void *_glfuncs, GLenum pname, const GLint* params);
+void gl4_1compat_glLightModeli(void *_glfuncs, GLenum pname, GLint param);
+void gl4_1compat_glLightModelfv(void *_glfuncs, GLenum pname, const GLfloat* params);
+void gl4_1compat_glLightModelf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl4_1compat_glLightiv(void *_glfuncs, GLenum light, GLenum pname, const GLint* params);
+void gl4_1compat_glLighti(void *_glfuncs, GLenum light, GLenum pname, GLint param);
+void gl4_1compat_glLightfv(void *_glfuncs, GLenum light, GLenum pname, const GLfloat* params);
+void gl4_1compat_glLightf(void *_glfuncs, GLenum light, GLenum pname, GLfloat param);
+void gl4_1compat_glFogiv(void *_glfuncs, GLenum pname, const GLint* params);
+void gl4_1compat_glFogi(void *_glfuncs, GLenum pname, GLint param);
+void gl4_1compat_glFogfv(void *_glfuncs, GLenum pname, const GLfloat* params);
+void gl4_1compat_glFogf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl4_1compat_glColorMaterial(void *_glfuncs, GLenum face, GLenum mode);
+void gl4_1compat_glClipPlane(void *_glfuncs, GLenum plane, const GLdouble* equation);
+void gl4_1compat_glVertex4sv(void *_glfuncs, const GLshort* v);
+void gl4_1compat_glVertex4s(void *_glfuncs, GLshort x, GLshort y, GLshort z, GLshort w);
+void gl4_1compat_glVertex4iv(void *_glfuncs, const GLint* v);
+void gl4_1compat_glVertex4i(void *_glfuncs, GLint x, GLint y, GLint z, GLint w);
+void gl4_1compat_glVertex4fv(void *_glfuncs, const GLfloat* v);
+void gl4_1compat_glVertex4f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+void gl4_1compat_glVertex4dv(void *_glfuncs, const GLdouble* v);
+void gl4_1compat_glVertex4d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+void gl4_1compat_glVertex3sv(void *_glfuncs, const GLshort* v);
+void gl4_1compat_glVertex3s(void *_glfuncs, GLshort x, GLshort y, GLshort z);
+void gl4_1compat_glVertex3iv(void *_glfuncs, const GLint* v);
+void gl4_1compat_glVertex3i(void *_glfuncs, GLint x, GLint y, GLint z);
+void gl4_1compat_glVertex3fv(void *_glfuncs, const GLfloat* v);
+void gl4_1compat_glVertex3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl4_1compat_glVertex3dv(void *_glfuncs, const GLdouble* v);
+void gl4_1compat_glVertex3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl4_1compat_glVertex2sv(void *_glfuncs, const GLshort* v);
+void gl4_1compat_glVertex2s(void *_glfuncs, GLshort x, GLshort y);
+void gl4_1compat_glVertex2iv(void *_glfuncs, const GLint* v);
+void gl4_1compat_glVertex2i(void *_glfuncs, GLint x, GLint y);
+void gl4_1compat_glVertex2fv(void *_glfuncs, const GLfloat* v);
+void gl4_1compat_glVertex2f(void *_glfuncs, GLfloat x, GLfloat y);
+void gl4_1compat_glVertex2dv(void *_glfuncs, const GLdouble* v);
+void gl4_1compat_glVertex2d(void *_glfuncs, GLdouble x, GLdouble y);
+void gl4_1compat_glTexCoord4sv(void *_glfuncs, const GLshort* v);
+void gl4_1compat_glTexCoord4s(void *_glfuncs, GLshort s, GLshort t, GLshort r, GLshort q);
+void gl4_1compat_glTexCoord4iv(void *_glfuncs, const GLint* v);
+void gl4_1compat_glTexCoord4i(void *_glfuncs, GLint s, GLint t, GLint r, GLint q);
+void gl4_1compat_glTexCoord4fv(void *_glfuncs, const GLfloat* v);
+void gl4_1compat_glTexCoord4f(void *_glfuncs, GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+void gl4_1compat_glTexCoord4dv(void *_glfuncs, const GLdouble* v);
+void gl4_1compat_glTexCoord4d(void *_glfuncs, GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+void gl4_1compat_glTexCoord3sv(void *_glfuncs, const GLshort* v);
+void gl4_1compat_glTexCoord3s(void *_glfuncs, GLshort s, GLshort t, GLshort r);
+void gl4_1compat_glTexCoord3iv(void *_glfuncs, const GLint* v);
+void gl4_1compat_glTexCoord3i(void *_glfuncs, GLint s, GLint t, GLint r);
+void gl4_1compat_glTexCoord3fv(void *_glfuncs, const GLfloat* v);
+void gl4_1compat_glTexCoord3f(void *_glfuncs, GLfloat s, GLfloat t, GLfloat r);
+void gl4_1compat_glTexCoord3dv(void *_glfuncs, const GLdouble* v);
+void gl4_1compat_glTexCoord3d(void *_glfuncs, GLdouble s, GLdouble t, GLdouble r);
+void gl4_1compat_glTexCoord2sv(void *_glfuncs, const GLshort* v);
+void gl4_1compat_glTexCoord2s(void *_glfuncs, GLshort s, GLshort t);
+void gl4_1compat_glTexCoord2iv(void *_glfuncs, const GLint* v);
+void gl4_1compat_glTexCoord2i(void *_glfuncs, GLint s, GLint t);
+void gl4_1compat_glTexCoord2fv(void *_glfuncs, const GLfloat* v);
+void gl4_1compat_glTexCoord2f(void *_glfuncs, GLfloat s, GLfloat t);
+void gl4_1compat_glTexCoord2dv(void *_glfuncs, const GLdouble* v);
+void gl4_1compat_glTexCoord2d(void *_glfuncs, GLdouble s, GLdouble t);
+void gl4_1compat_glTexCoord1sv(void *_glfuncs, const GLshort* v);
+void gl4_1compat_glTexCoord1s(void *_glfuncs, GLshort s);
+void gl4_1compat_glTexCoord1iv(void *_glfuncs, const GLint* v);
+void gl4_1compat_glTexCoord1i(void *_glfuncs, GLint s);
+void gl4_1compat_glTexCoord1fv(void *_glfuncs, const GLfloat* v);
+void gl4_1compat_glTexCoord1f(void *_glfuncs, GLfloat s);
+void gl4_1compat_glTexCoord1dv(void *_glfuncs, const GLdouble* v);
+void gl4_1compat_glTexCoord1d(void *_glfuncs, GLdouble s);
+void gl4_1compat_glRectsv(void *_glfuncs, const GLshort* v1, const GLshort* v2);
+void gl4_1compat_glRects(void *_glfuncs, GLshort x1, GLshort y1, GLshort x2, GLshort y2);
+void gl4_1compat_glRectiv(void *_glfuncs, const GLint* v1, const GLint* v2);
+void gl4_1compat_glRecti(void *_glfuncs, GLint x1, GLint y1, GLint x2, GLint y2);
+void gl4_1compat_glRectfv(void *_glfuncs, const GLfloat* v1, const GLfloat* v2);
+void gl4_1compat_glRectf(void *_glfuncs, GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2);
+void gl4_1compat_glRectdv(void *_glfuncs, const GLdouble* v1, const GLdouble* v2);
+void gl4_1compat_glRectd(void *_glfuncs, GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2);
+void gl4_1compat_glRasterPos4sv(void *_glfuncs, const GLshort* v);
+void gl4_1compat_glRasterPos4s(void *_glfuncs, GLshort x, GLshort y, GLshort z, GLshort w);
+void gl4_1compat_glRasterPos4iv(void *_glfuncs, const GLint* v);
+void gl4_1compat_glRasterPos4i(void *_glfuncs, GLint x, GLint y, GLint z, GLint w);
+void gl4_1compat_glRasterPos4fv(void *_glfuncs, const GLfloat* v);
+void gl4_1compat_glRasterPos4f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+void gl4_1compat_glRasterPos4dv(void *_glfuncs, const GLdouble* v);
+void gl4_1compat_glRasterPos4d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+void gl4_1compat_glRasterPos3sv(void *_glfuncs, const GLshort* v);
+void gl4_1compat_glRasterPos3s(void *_glfuncs, GLshort x, GLshort y, GLshort z);
+void gl4_1compat_glRasterPos3iv(void *_glfuncs, const GLint* v);
+void gl4_1compat_glRasterPos3i(void *_glfuncs, GLint x, GLint y, GLint z);
+void gl4_1compat_glRasterPos3fv(void *_glfuncs, const GLfloat* v);
+void gl4_1compat_glRasterPos3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl4_1compat_glRasterPos3dv(void *_glfuncs, const GLdouble* v);
+void gl4_1compat_glRasterPos3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl4_1compat_glRasterPos2sv(void *_glfuncs, const GLshort* v);
+void gl4_1compat_glRasterPos2s(void *_glfuncs, GLshort x, GLshort y);
+void gl4_1compat_glRasterPos2iv(void *_glfuncs, const GLint* v);
+void gl4_1compat_glRasterPos2i(void *_glfuncs, GLint x, GLint y);
+void gl4_1compat_glRasterPos2fv(void *_glfuncs, const GLfloat* v);
+void gl4_1compat_glRasterPos2f(void *_glfuncs, GLfloat x, GLfloat y);
+void gl4_1compat_glRasterPos2dv(void *_glfuncs, const GLdouble* v);
+void gl4_1compat_glRasterPos2d(void *_glfuncs, GLdouble x, GLdouble y);
+void gl4_1compat_glNormal3sv(void *_glfuncs, const GLshort* v);
+void gl4_1compat_glNormal3s(void *_glfuncs, GLshort nx, GLshort ny, GLshort nz);
+void gl4_1compat_glNormal3iv(void *_glfuncs, const GLint* v);
+void gl4_1compat_glNormal3i(void *_glfuncs, GLint nx, GLint ny, GLint nz);
+void gl4_1compat_glNormal3fv(void *_glfuncs, const GLfloat* v);
+void gl4_1compat_glNormal3f(void *_glfuncs, GLfloat nx, GLfloat ny, GLfloat nz);
+void gl4_1compat_glNormal3dv(void *_glfuncs, const GLdouble* v);
+void gl4_1compat_glNormal3d(void *_glfuncs, GLdouble nx, GLdouble ny, GLdouble nz);
+void gl4_1compat_glNormal3bv(void *_glfuncs, const GLbyte* v);
+void gl4_1compat_glNormal3b(void *_glfuncs, GLbyte nx, GLbyte ny, GLbyte nz);
+void gl4_1compat_glIndexsv(void *_glfuncs, const GLshort* c);
+void gl4_1compat_glIndexs(void *_glfuncs, GLshort c);
+void gl4_1compat_glIndexiv(void *_glfuncs, const GLint* c);
+void gl4_1compat_glIndexi(void *_glfuncs, GLint c);
+void gl4_1compat_glIndexfv(void *_glfuncs, const GLfloat* c);
+void gl4_1compat_glIndexf(void *_glfuncs, GLfloat c);
+void gl4_1compat_glIndexdv(void *_glfuncs, const GLdouble* c);
+void gl4_1compat_glIndexd(void *_glfuncs, GLdouble c);
+void gl4_1compat_glEnd(void *_glfuncs);
+void gl4_1compat_glEdgeFlagv(void *_glfuncs, const GLboolean* flag);
+void gl4_1compat_glEdgeFlag(void *_glfuncs, GLboolean flag);
+void gl4_1compat_glColor4usv(void *_glfuncs, const GLushort* v);
+void gl4_1compat_glColor4us(void *_glfuncs, GLushort red, GLushort green, GLushort blue, GLushort alpha);
+void gl4_1compat_glColor4uiv(void *_glfuncs, const GLuint* v);
+void gl4_1compat_glColor4ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue, GLuint alpha);
+void gl4_1compat_glColor4ubv(void *_glfuncs, const GLubyte* v);
+void gl4_1compat_glColor4ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha);
+void gl4_1compat_glColor4sv(void *_glfuncs, const GLshort* v);
+void gl4_1compat_glColor4s(void *_glfuncs, GLshort red, GLshort green, GLshort blue, GLshort alpha);
+void gl4_1compat_glColor4iv(void *_glfuncs, const GLint* v);
+void gl4_1compat_glColor4i(void *_glfuncs, GLint red, GLint green, GLint blue, GLint alpha);
+void gl4_1compat_glColor4fv(void *_glfuncs, const GLfloat* v);
+void gl4_1compat_glColor4f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl4_1compat_glColor4dv(void *_glfuncs, const GLdouble* v);
+void gl4_1compat_glColor4d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha);
+void gl4_1compat_glColor4bv(void *_glfuncs, const GLbyte* v);
+void gl4_1compat_glColor4b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha);
+void gl4_1compat_glColor3usv(void *_glfuncs, const GLushort* v);
+void gl4_1compat_glColor3us(void *_glfuncs, GLushort red, GLushort green, GLushort blue);
+void gl4_1compat_glColor3uiv(void *_glfuncs, const GLuint* v);
+void gl4_1compat_glColor3ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue);
+void gl4_1compat_glColor3ubv(void *_glfuncs, const GLubyte* v);
+void gl4_1compat_glColor3ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue);
+void gl4_1compat_glColor3sv(void *_glfuncs, const GLshort* v);
+void gl4_1compat_glColor3s(void *_glfuncs, GLshort red, GLshort green, GLshort blue);
+void gl4_1compat_glColor3iv(void *_glfuncs, const GLint* v);
+void gl4_1compat_glColor3i(void *_glfuncs, GLint red, GLint green, GLint blue);
+void gl4_1compat_glColor3fv(void *_glfuncs, const GLfloat* v);
+void gl4_1compat_glColor3f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue);
+void gl4_1compat_glColor3dv(void *_glfuncs, const GLdouble* v);
+void gl4_1compat_glColor3d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue);
+void gl4_1compat_glColor3bv(void *_glfuncs, const GLbyte* v);
+void gl4_1compat_glColor3b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue);
+void gl4_1compat_glBitmap(void *_glfuncs, GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte* bitmap);
+void gl4_1compat_glBegin(void *_glfuncs, GLenum mode);
+void gl4_1compat_glListBase(void *_glfuncs, GLuint base);
+GLuint gl4_1compat_glGenLists(void *_glfuncs, GLsizei range_);
+void gl4_1compat_glDeleteLists(void *_glfuncs, GLuint list, GLsizei range_);
+void gl4_1compat_glCallLists(void *_glfuncs, GLsizei n, GLenum gltype, const GLvoid* lists);
+void gl4_1compat_glCallList(void *_glfuncs, GLuint list);
+void gl4_1compat_glEndList(void *_glfuncs);
+void gl4_1compat_glNewList(void *_glfuncs, GLuint list, GLenum mode);
+void gl4_1compat_glPushClientAttrib(void *_glfuncs, GLbitfield mask);
+void gl4_1compat_glPopClientAttrib(void *_glfuncs);
+void gl4_1compat_glPrioritizeTextures(void *_glfuncs, GLsizei n, const GLuint* textures, const GLfloat* priorities);
+GLboolean gl4_1compat_glAreTexturesResident(void *_glfuncs, GLsizei n, const GLuint* textures, GLboolean* residences);
+void gl4_1compat_glVertexPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl4_1compat_glTexCoordPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl4_1compat_glNormalPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl4_1compat_glInterleavedArrays(void *_glfuncs, GLenum format, GLsizei stride, const GLvoid* pointer);
+void gl4_1compat_glIndexPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl4_1compat_glEnableClientState(void *_glfuncs, GLenum array);
+void gl4_1compat_glEdgeFlagPointer(void *_glfuncs, GLsizei stride, const GLvoid* pointer);
+void gl4_1compat_glDisableClientState(void *_glfuncs, GLenum array);
+void gl4_1compat_glColorPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl4_1compat_glArrayElement(void *_glfuncs, GLint i);
+void gl4_1compat_glResetMinmax(void *_glfuncs, GLenum target);
+void gl4_1compat_glResetHistogram(void *_glfuncs, GLenum target);
+void gl4_1compat_glMinmax(void *_glfuncs, GLenum target, GLenum internalFormat, GLboolean sink);
+void gl4_1compat_glHistogram(void *_glfuncs, GLenum target, GLsizei width, GLenum internalFormat, GLboolean sink);
+void gl4_1compat_glGetMinmaxParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl4_1compat_glGetMinmaxParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl4_1compat_glGetMinmax(void *_glfuncs, GLenum target, GLboolean reset, GLenum format, GLenum gltype, GLvoid* values);
+void gl4_1compat_glGetHistogramParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl4_1compat_glGetHistogramParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl4_1compat_glGetHistogram(void *_glfuncs, GLenum target, GLboolean reset, GLenum format, GLenum gltype, GLvoid* values);
+void gl4_1compat_glSeparableFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* row, const GLvoid* column);
+void gl4_1compat_glGetSeparableFilter(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* row, GLvoid* column, GLvoid* span);
+void gl4_1compat_glGetConvolutionParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl4_1compat_glGetConvolutionParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl4_1compat_glGetConvolutionFilter(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* image);
+void gl4_1compat_glCopyConvolutionFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl4_1compat_glCopyConvolutionFilter1D(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width);
+void gl4_1compat_glConvolutionParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl4_1compat_glConvolutionParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint params);
+void gl4_1compat_glConvolutionParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl4_1compat_glConvolutionParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat params);
+void gl4_1compat_glConvolutionFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* image);
+void gl4_1compat_glConvolutionFilter1D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLenum format, GLenum gltype, const GLvoid* image);
+void gl4_1compat_glCopyColorSubTable(void *_glfuncs, GLenum target, GLsizei start, GLint x, GLint y, GLsizei width);
+void gl4_1compat_glColorSubTable(void *_glfuncs, GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum gltype, const GLvoid* data);
+void gl4_1compat_glGetColorTableParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl4_1compat_glGetColorTableParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl4_1compat_glGetColorTable(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* table);
+void gl4_1compat_glCopyColorTable(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width);
+void gl4_1compat_glColorTableParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl4_1compat_glColorTableParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl4_1compat_glColorTable(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLenum format, GLenum gltype, const GLvoid* table);
+void gl4_1compat_glMultTransposeMatrixd(void *_glfuncs, const GLdouble* m);
+void gl4_1compat_glMultTransposeMatrixf(void *_glfuncs, const GLfloat* m);
+void gl4_1compat_glLoadTransposeMatrixd(void *_glfuncs, const GLdouble* m);
+void gl4_1compat_glLoadTransposeMatrixf(void *_glfuncs, const GLfloat* m);
+void gl4_1compat_glMultiTexCoord4sv(void *_glfuncs, GLenum target, const GLshort* v);
+void gl4_1compat_glMultiTexCoord4s(void *_glfuncs, GLenum target, GLshort s, GLshort t, GLshort r, GLshort q);
+void gl4_1compat_glMultiTexCoord4iv(void *_glfuncs, GLenum target, const GLint* v);
+void gl4_1compat_glMultiTexCoord4i(void *_glfuncs, GLenum target, GLint s, GLint t, GLint r, GLint q);
+void gl4_1compat_glMultiTexCoord4fv(void *_glfuncs, GLenum target, const GLfloat* v);
+void gl4_1compat_glMultiTexCoord4f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+void gl4_1compat_glMultiTexCoord4dv(void *_glfuncs, GLenum target, const GLdouble* v);
+void gl4_1compat_glMultiTexCoord4d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+void gl4_1compat_glMultiTexCoord3sv(void *_glfuncs, GLenum target, const GLshort* v);
+void gl4_1compat_glMultiTexCoord3s(void *_glfuncs, GLenum target, GLshort s, GLshort t, GLshort r);
+void gl4_1compat_glMultiTexCoord3iv(void *_glfuncs, GLenum target, const GLint* v);
+void gl4_1compat_glMultiTexCoord3i(void *_glfuncs, GLenum target, GLint s, GLint t, GLint r);
+void gl4_1compat_glMultiTexCoord3fv(void *_glfuncs, GLenum target, const GLfloat* v);
+void gl4_1compat_glMultiTexCoord3f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t, GLfloat r);
+void gl4_1compat_glMultiTexCoord3dv(void *_glfuncs, GLenum target, const GLdouble* v);
+void gl4_1compat_glMultiTexCoord3d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t, GLdouble r);
+void gl4_1compat_glMultiTexCoord2sv(void *_glfuncs, GLenum target, const GLshort* v);
+void gl4_1compat_glMultiTexCoord2s(void *_glfuncs, GLenum target, GLshort s, GLshort t);
+void gl4_1compat_glMultiTexCoord2iv(void *_glfuncs, GLenum target, const GLint* v);
+void gl4_1compat_glMultiTexCoord2i(void *_glfuncs, GLenum target, GLint s, GLint t);
+void gl4_1compat_glMultiTexCoord2fv(void *_glfuncs, GLenum target, const GLfloat* v);
+void gl4_1compat_glMultiTexCoord2f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t);
+void gl4_1compat_glMultiTexCoord2dv(void *_glfuncs, GLenum target, const GLdouble* v);
+void gl4_1compat_glMultiTexCoord2d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t);
+void gl4_1compat_glMultiTexCoord1sv(void *_glfuncs, GLenum target, const GLshort* v);
+void gl4_1compat_glMultiTexCoord1s(void *_glfuncs, GLenum target, GLshort s);
+void gl4_1compat_glMultiTexCoord1iv(void *_glfuncs, GLenum target, const GLint* v);
+void gl4_1compat_glMultiTexCoord1i(void *_glfuncs, GLenum target, GLint s);
+void gl4_1compat_glMultiTexCoord1fv(void *_glfuncs, GLenum target, const GLfloat* v);
+void gl4_1compat_glMultiTexCoord1f(void *_glfuncs, GLenum target, GLfloat s);
+void gl4_1compat_glMultiTexCoord1dv(void *_glfuncs, GLenum target, const GLdouble* v);
+void gl4_1compat_glMultiTexCoord1d(void *_glfuncs, GLenum target, GLdouble s);
+void gl4_1compat_glClientActiveTexture(void *_glfuncs, GLenum texture);
+void gl4_1compat_glWindowPos3sv(void *_glfuncs, const GLshort* v);
+void gl4_1compat_glWindowPos3s(void *_glfuncs, GLshort x, GLshort y, GLshort z);
+void gl4_1compat_glWindowPos3iv(void *_glfuncs, const GLint* v);
+void gl4_1compat_glWindowPos3i(void *_glfuncs, GLint x, GLint y, GLint z);
+void gl4_1compat_glWindowPos3fv(void *_glfuncs, const GLfloat* v);
+void gl4_1compat_glWindowPos3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl4_1compat_glWindowPos3dv(void *_glfuncs, const GLdouble* v);
+void gl4_1compat_glWindowPos3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl4_1compat_glWindowPos2sv(void *_glfuncs, const GLshort* v);
+void gl4_1compat_glWindowPos2s(void *_glfuncs, GLshort x, GLshort y);
+void gl4_1compat_glWindowPos2iv(void *_glfuncs, const GLint* v);
+void gl4_1compat_glWindowPos2i(void *_glfuncs, GLint x, GLint y);
+void gl4_1compat_glWindowPos2fv(void *_glfuncs, const GLfloat* v);
+void gl4_1compat_glWindowPos2f(void *_glfuncs, GLfloat x, GLfloat y);
+void gl4_1compat_glWindowPos2dv(void *_glfuncs, const GLdouble* v);
+void gl4_1compat_glWindowPos2d(void *_glfuncs, GLdouble x, GLdouble y);
+void gl4_1compat_glSecondaryColorPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl4_1compat_glSecondaryColor3usv(void *_glfuncs, const GLushort* v);
+void gl4_1compat_glSecondaryColor3us(void *_glfuncs, GLushort red, GLushort green, GLushort blue);
+void gl4_1compat_glSecondaryColor3uiv(void *_glfuncs, const GLuint* v);
+void gl4_1compat_glSecondaryColor3ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue);
+void gl4_1compat_glSecondaryColor3ubv(void *_glfuncs, const GLubyte* v);
+void gl4_1compat_glSecondaryColor3ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue);
+void gl4_1compat_glSecondaryColor3sv(void *_glfuncs, const GLshort* v);
+void gl4_1compat_glSecondaryColor3s(void *_glfuncs, GLshort red, GLshort green, GLshort blue);
+void gl4_1compat_glSecondaryColor3iv(void *_glfuncs, const GLint* v);
+void gl4_1compat_glSecondaryColor3i(void *_glfuncs, GLint red, GLint green, GLint blue);
+void gl4_1compat_glSecondaryColor3fv(void *_glfuncs, const GLfloat* v);
+void gl4_1compat_glSecondaryColor3f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue);
+void gl4_1compat_glSecondaryColor3dv(void *_glfuncs, const GLdouble* v);
+void gl4_1compat_glSecondaryColor3d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue);
+void gl4_1compat_glSecondaryColor3bv(void *_glfuncs, const GLbyte* v);
+void gl4_1compat_glSecondaryColor3b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue);
+void gl4_1compat_glFogCoordPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl4_1compat_glFogCoorddv(void *_glfuncs, const GLdouble* coord);
+void gl4_1compat_glFogCoordd(void *_glfuncs, GLdouble coord);
+void gl4_1compat_glFogCoordfv(void *_glfuncs, const GLfloat* coord);
+void gl4_1compat_glFogCoordf(void *_glfuncs, GLfloat coord);
+void gl4_1compat_glVertexAttrib4usv(void *_glfuncs, GLuint index, const GLushort* v);
+void gl4_1compat_glVertexAttrib4uiv(void *_glfuncs, GLuint index, const GLuint* v);
+void gl4_1compat_glVertexAttrib4ubv(void *_glfuncs, GLuint index, const GLubyte* v);
+void gl4_1compat_glVertexAttrib4sv(void *_glfuncs, GLuint index, const GLshort* v);
+void gl4_1compat_glVertexAttrib4s(void *_glfuncs, GLuint index, GLshort x, GLshort y, GLshort z, GLshort w);
+void gl4_1compat_glVertexAttrib4iv(void *_glfuncs, GLuint index, const GLint* v);
+void gl4_1compat_glVertexAttrib4fv(void *_glfuncs, GLuint index, const GLfloat* v);
+void gl4_1compat_glVertexAttrib4f(void *_glfuncs, GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+void gl4_1compat_glVertexAttrib4dv(void *_glfuncs, GLuint index, const GLdouble* v);
+void gl4_1compat_glVertexAttrib4d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+void gl4_1compat_glVertexAttrib4bv(void *_glfuncs, GLuint index, const GLbyte* v);
+void gl4_1compat_glVertexAttrib4Nusv(void *_glfuncs, GLuint index, const GLushort* v);
+void gl4_1compat_glVertexAttrib4Nuiv(void *_glfuncs, GLuint index, const GLuint* v);
+void gl4_1compat_glVertexAttrib4Nubv(void *_glfuncs, GLuint index, const GLubyte* v);
+void gl4_1compat_glVertexAttrib4Nub(void *_glfuncs, GLuint index, GLubyte x, GLubyte y, GLubyte z, GLubyte w);
+void gl4_1compat_glVertexAttrib4Nsv(void *_glfuncs, GLuint index, const GLshort* v);
+void gl4_1compat_glVertexAttrib4Niv(void *_glfuncs, GLuint index, const GLint* v);
+void gl4_1compat_glVertexAttrib4Nbv(void *_glfuncs, GLuint index, const GLbyte* v);
+void gl4_1compat_glVertexAttrib3sv(void *_glfuncs, GLuint index, const GLshort* v);
+void gl4_1compat_glVertexAttrib3s(void *_glfuncs, GLuint index, GLshort x, GLshort y, GLshort z);
+void gl4_1compat_glVertexAttrib3fv(void *_glfuncs, GLuint index, const GLfloat* v);
+void gl4_1compat_glVertexAttrib3f(void *_glfuncs, GLuint index, GLfloat x, GLfloat y, GLfloat z);
+void gl4_1compat_glVertexAttrib3dv(void *_glfuncs, GLuint index, const GLdouble* v);
+void gl4_1compat_glVertexAttrib3d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y, GLdouble z);
+void gl4_1compat_glVertexAttrib2sv(void *_glfuncs, GLuint index, const GLshort* v);
+void gl4_1compat_glVertexAttrib2s(void *_glfuncs, GLuint index, GLshort x, GLshort y);
+void gl4_1compat_glVertexAttrib2fv(void *_glfuncs, GLuint index, const GLfloat* v);
+void gl4_1compat_glVertexAttrib2f(void *_glfuncs, GLuint index, GLfloat x, GLfloat y);
+void gl4_1compat_glVertexAttrib2dv(void *_glfuncs, GLuint index, const GLdouble* v);
+void gl4_1compat_glVertexAttrib2d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y);
+void gl4_1compat_glVertexAttrib1sv(void *_glfuncs, GLuint index, const GLshort* v);
+void gl4_1compat_glVertexAttrib1s(void *_glfuncs, GLuint index, GLshort x);
+void gl4_1compat_glVertexAttrib1fv(void *_glfuncs, GLuint index, const GLfloat* v);
+void gl4_1compat_glVertexAttrib1f(void *_glfuncs, GLuint index, GLfloat x);
+void gl4_1compat_glVertexAttrib1dv(void *_glfuncs, GLuint index, const GLdouble* v);
+void gl4_1compat_glVertexAttrib1d(void *_glfuncs, GLuint index, GLdouble x);
+void gl4_1compat_glVertexAttribI4usv(void *_glfuncs, GLuint index, const GLushort* v);
+void gl4_1compat_glVertexAttribI4ubv(void *_glfuncs, GLuint index, const GLubyte* v);
+void gl4_1compat_glVertexAttribI4sv(void *_glfuncs, GLuint index, const GLshort* v);
+void gl4_1compat_glVertexAttribI4bv(void *_glfuncs, GLuint index, const GLbyte* v);
+void gl4_1compat_glVertexAttribI4uiv(void *_glfuncs, GLuint index, const GLuint* v);
+void gl4_1compat_glVertexAttribI3uiv(void *_glfuncs, GLuint index, const GLuint* v);
+void gl4_1compat_glVertexAttribI2uiv(void *_glfuncs, GLuint index, const GLuint* v);
+void gl4_1compat_glVertexAttribI1uiv(void *_glfuncs, GLuint index, const GLuint* v);
+void gl4_1compat_glVertexAttribI4iv(void *_glfuncs, GLuint index, const GLint* v);
+void gl4_1compat_glVertexAttribI3iv(void *_glfuncs, GLuint index, const GLint* v);
+void gl4_1compat_glVertexAttribI2iv(void *_glfuncs, GLuint index, const GLint* v);
+void gl4_1compat_glVertexAttribI1iv(void *_glfuncs, GLuint index, const GLint* v);
+void gl4_1compat_glVertexAttribI4ui(void *_glfuncs, GLuint index, GLuint x, GLuint y, GLuint z, GLuint w);
+void gl4_1compat_glVertexAttribI3ui(void *_glfuncs, GLuint index, GLuint x, GLuint y, GLuint z);
+void gl4_1compat_glVertexAttribI2ui(void *_glfuncs, GLuint index, GLuint x, GLuint y);
+void gl4_1compat_glVertexAttribI1ui(void *_glfuncs, GLuint index, GLuint x);
+void gl4_1compat_glVertexAttribI4i(void *_glfuncs, GLuint index, GLint x, GLint y, GLint z, GLint w);
+void gl4_1compat_glVertexAttribI3i(void *_glfuncs, GLuint index, GLint x, GLint y, GLint z);
+void gl4_1compat_glVertexAttribI2i(void *_glfuncs, GLuint index, GLint x, GLint y);
+void gl4_1compat_glVertexAttribI1i(void *_glfuncs, GLuint index, GLint x);
+
+
+#ifdef __cplusplus
+} // extern "C"
+#endif
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.1compat/gl.go b/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.1compat/gl.go
new file mode 100644
index 000000000..3d4370205
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.1compat/gl.go
@@ -0,0 +1,9201 @@
+// ** file automatically generated by glgen -- do not edit manually **
+
+package GL
+
+// #cgo CXXFLAGS: -std=c++0x -pedantic-errors -Wall -fno-strict-aliasing
+// #cgo LDFLAGS: -lstdc++
+// #cgo pkg-config: Qt5Core Qt5OpenGL
+//
+// #include "funcs.h"
+//
+// void free(void*);
+//
+import "C"
+
+import (
+ "fmt"
+ "reflect"
+ "unsafe"
+
+ "gopkg.in/qml.v1/gl/glbase"
+)
+
+// API returns a value that offers methods matching the OpenGL version 4.1 API.
+//
+// The returned API must not be used after the provided OpenGL context becomes invalid.
+func API(context glbase.Contexter) *GL {
+ gl := &GL{}
+ gl.funcs = C.gl4_1compat_funcs()
+ if gl.funcs == nil {
+ panic(fmt.Errorf("OpenGL version 4.1 is not available"))
+ }
+ return gl
+}
+
+// GL implements the OpenGL version 4.1 API. Values of this
+// type must be created via the API function, and it must not be used after
+// the associated OpenGL context becomes invalid.
+type GL struct {
+ funcs unsafe.Pointer
+}
+
+const (
+ FALSE = 0
+ TRUE = 1
+ NONE = 0
+
+ BYTE = 0x1400
+ UNSIGNED_BYTE = 0x1401
+ SHORT = 0x1402
+ UNSIGNED_SHORT = 0x1403
+ INT = 0x1404
+ UNSIGNED_INT = 0x1405
+ FLOAT = 0x1406
+ N2_BYTES = 0x1407
+ N3_BYTES = 0x1408
+ N4_BYTES = 0x1409
+ DOUBLE = 0x140A
+ HALF_FLOAT = 0x140B
+ FIXED = 0x140C
+
+ ACCUM = 0x0100
+ LOAD = 0x0101
+ RETURN = 0x0102
+ MULT = 0x0103
+ ADD = 0x0104
+
+ ACCUM_BUFFER_BIT = 0x00000200
+ ALL_ATTRIB_BITS = 0xFFFFFFFF
+ COLOR_BUFFER_BIT = 0x00004000
+ CURRENT_BIT = 0x00000001
+ DEPTH_BUFFER_BIT = 0x00000100
+ ENABLE_BIT = 0x00002000
+ EVAL_BIT = 0x00010000
+ FOG_BIT = 0x00000080
+ HINT_BIT = 0x00008000
+ LIGHTING_BIT = 0x00000040
+ LINE_BIT = 0x00000004
+ LIST_BIT = 0x00020000
+ MULTISAMPLE_BIT = 0x20000000
+ PIXEL_MODE_BIT = 0x00000020
+ POINT_BIT = 0x00000002
+ POLYGON_BIT = 0x00000008
+ POLYGON_STIPPLE_BIT = 0x00000010
+ SCISSOR_BIT = 0x00080000
+ STENCIL_BUFFER_BIT = 0x00000400
+ TEXTURE_BIT = 0x00040000
+ TRANSFORM_BIT = 0x00001000
+ VIEWPORT_BIT = 0x00000800
+
+ ALWAYS = 0x0207
+ EQUAL = 0x0202
+ GEQUAL = 0x0206
+ GREATER = 0x0204
+ LEQUAL = 0x0203
+ LESS = 0x0201
+ NEVER = 0x0200
+ NOTEQUAL = 0x0205
+
+ LOGIC_OP = 0x0BF1
+
+ DST_ALPHA = 0x0304
+ ONE = 1
+ ONE_MINUS_DST_ALPHA = 0x0305
+ ONE_MINUS_SRC_ALPHA = 0x0303
+ ONE_MINUS_SRC_COLOR = 0x0301
+ SRC_ALPHA = 0x0302
+ SRC_COLOR = 0x0300
+ ZERO = 0
+
+ DST_COLOR = 0x0306
+ ONE_MINUS_DST_COLOR = 0x0307
+ SRC_ALPHA_SATURATE = 0x0308
+
+ CLIENT_ALL_ATTRIB_BITS = 0xFFFFFFFF
+ CLIENT_PIXEL_STORE_BIT = 0x00000001
+ CLIENT_VERTEX_ARRAY_BIT = 0x00000002
+
+ CLIP_DISTANCE0 = 0x3000
+ CLIP_DISTANCE1 = 0x3001
+ CLIP_DISTANCE2 = 0x3002
+ CLIP_DISTANCE3 = 0x3003
+ CLIP_DISTANCE4 = 0x3004
+ CLIP_DISTANCE5 = 0x3005
+ CLIP_DISTANCE6 = 0x3006
+ CLIP_DISTANCE7 = 0x3007
+ CLIP_PLANE0 = 0x3000
+ CLIP_PLANE1 = 0x3001
+ CLIP_PLANE2 = 0x3002
+ CLIP_PLANE3 = 0x3003
+ CLIP_PLANE4 = 0x3004
+ CLIP_PLANE5 = 0x3005
+
+ BACK = 0x0405
+ FRONT = 0x0404
+ FRONT_AND_BACK = 0x0408
+
+ AMBIENT = 0x1200
+ AMBIENT_AND_DIFFUSE = 0x1602
+ DIFFUSE = 0x1201
+ EMISSION = 0x1600
+ SPECULAR = 0x1202
+
+ CONTEXT_FLAG_FORWARD_COMPATIBLE_BIT = 0x00000001
+
+ CONTEXT_COMPATIBILITY_PROFILE_BIT = 0x00000002
+ CONTEXT_CORE_PROFILE_BIT = 0x00000001
+
+ AUX0 = 0x0409
+ AUX1 = 0x040A
+ AUX2 = 0x040B
+ AUX3 = 0x040C
+ BACK_LEFT = 0x0402
+ BACK_RIGHT = 0x0403
+ FRONT_LEFT = 0x0400
+ FRONT_RIGHT = 0x0401
+ LEFT = 0x0406
+ RIGHT = 0x0407
+
+ ALPHA_TEST = 0x0BC0
+ AUTO_NORMAL = 0x0D80
+ BLEND = 0x0BE2
+ COLOR_ARRAY = 0x8076
+ COLOR_LOGIC_OP = 0x0BF2
+ COLOR_MATERIAL = 0x0B57
+ CULL_FACE = 0x0B44
+ DEPTH_TEST = 0x0B71
+ DITHER = 0x0BD0
+ EDGE_FLAG_ARRAY = 0x8079
+ FOG = 0x0B60
+ INDEX_ARRAY = 0x8077
+ INDEX_LOGIC_OP = 0x0BF1
+ LIGHT0 = 0x4000
+ LIGHT1 = 0x4001
+ LIGHT2 = 0x4002
+ LIGHT3 = 0x4003
+ LIGHT4 = 0x4004
+ LIGHT5 = 0x4005
+ LIGHT6 = 0x4006
+ LIGHT7 = 0x4007
+ LIGHTING = 0x0B50
+ LINE_SMOOTH = 0x0B20
+ LINE_STIPPLE = 0x0B24
+ MAP1_COLOR_4 = 0x0D90
+ MAP1_INDEX = 0x0D91
+ MAP1_NORMAL = 0x0D92
+ MAP1_TEXTURE_COORD_1 = 0x0D93
+ MAP1_TEXTURE_COORD_2 = 0x0D94
+ MAP1_TEXTURE_COORD_3 = 0x0D95
+ MAP1_TEXTURE_COORD_4 = 0x0D96
+ MAP1_VERTEX_3 = 0x0D97
+ MAP1_VERTEX_4 = 0x0D98
+ MAP2_COLOR_4 = 0x0DB0
+ MAP2_INDEX = 0x0DB1
+ MAP2_NORMAL = 0x0DB2
+ MAP2_TEXTURE_COORD_1 = 0x0DB3
+ MAP2_TEXTURE_COORD_2 = 0x0DB4
+ MAP2_TEXTURE_COORD_3 = 0x0DB5
+ MAP2_TEXTURE_COORD_4 = 0x0DB6
+ MAP2_VERTEX_3 = 0x0DB7
+ MAP2_VERTEX_4 = 0x0DB8
+ NORMALIZE = 0x0BA1
+ NORMAL_ARRAY = 0x8075
+ POINT_SMOOTH = 0x0B10
+ POLYGON_OFFSET_FILL = 0x8037
+ POLYGON_OFFSET_LINE = 0x2A02
+ POLYGON_OFFSET_POINT = 0x2A01
+ POLYGON_SMOOTH = 0x0B41
+ POLYGON_STIPPLE = 0x0B42
+ SCISSOR_TEST = 0x0C11
+ STENCIL_TEST = 0x0B90
+ TEXTURE_1D = 0x0DE0
+ TEXTURE_2D = 0x0DE1
+ TEXTURE_COORD_ARRAY = 0x8078
+ TEXTURE_GEN_Q = 0x0C63
+ TEXTURE_GEN_R = 0x0C62
+ TEXTURE_GEN_S = 0x0C60
+ TEXTURE_GEN_T = 0x0C61
+ VERTEX_ARRAY = 0x8074
+
+ INVALID_ENUM = 0x0500
+ INVALID_FRAMEBUFFER_OPERATION = 0x0506
+ INVALID_OPERATION = 0x0502
+ INVALID_VALUE = 0x0501
+ NO_ERROR = 0
+ OUT_OF_MEMORY = 0x0505
+ STACK_OVERFLOW = 0x0503
+ STACK_UNDERFLOW = 0x0504
+
+ N2D = 0x0600
+ N3D = 0x0601
+ N3D_COLOR = 0x0602
+ N3D_COLOR_TEXTURE = 0x0603
+ N4D_COLOR_TEXTURE = 0x0604
+
+ BITMAP_TOKEN = 0x0704
+ COPY_PIXEL_TOKEN = 0x0706
+ DRAW_PIXEL_TOKEN = 0x0705
+ LINE_RESET_TOKEN = 0x0707
+ LINE_TOKEN = 0x0702
+ PASS_THROUGH_TOKEN = 0x0700
+ POINT_TOKEN = 0x0701
+ POLYGON_TOKEN = 0x0703
+
+ EXP = 0x0800
+ EXP2 = 0x0801
+ LINEAR = 0x2601
+
+ FOG_COLOR = 0x0B66
+ FOG_DENSITY = 0x0B62
+ FOG_END = 0x0B64
+ FOG_INDEX = 0x0B61
+ FOG_MODE = 0x0B65
+ FOG_START = 0x0B63
+
+ CCW = 0x0901
+ CW = 0x0900
+
+ COEFF = 0x0A00
+ DOMAIN = 0x0A02
+ ORDER = 0x0A01
+
+ PIXEL_MAP_A_TO_A = 0x0C79
+ PIXEL_MAP_B_TO_B = 0x0C78
+ PIXEL_MAP_G_TO_G = 0x0C77
+ PIXEL_MAP_I_TO_A = 0x0C75
+ PIXEL_MAP_I_TO_B = 0x0C74
+ PIXEL_MAP_I_TO_G = 0x0C73
+ PIXEL_MAP_I_TO_I = 0x0C70
+ PIXEL_MAP_I_TO_R = 0x0C72
+ PIXEL_MAP_R_TO_R = 0x0C76
+ PIXEL_MAP_S_TO_S = 0x0C71
+
+ ACCUM_ALPHA_BITS = 0x0D5B
+ ACCUM_BLUE_BITS = 0x0D5A
+ ACCUM_CLEAR_VALUE = 0x0B80
+ ACCUM_GREEN_BITS = 0x0D59
+ ACCUM_RED_BITS = 0x0D58
+ ALIASED_LINE_WIDTH_RANGE = 0x846E
+ ALIASED_POINT_SIZE_RANGE = 0x846D
+ ALPHA_BIAS = 0x0D1D
+ ALPHA_BITS = 0x0D55
+ ALPHA_SCALE = 0x0D1C
+ ALPHA_TEST_FUNC = 0x0BC1
+ ALPHA_TEST_REF = 0x0BC2
+ ATTRIB_STACK_DEPTH = 0x0BB0
+ AUX_BUFFERS = 0x0C00
+ BLEND_DST = 0x0BE0
+ BLEND_SRC = 0x0BE1
+ BLUE_BIAS = 0x0D1B
+ BLUE_BITS = 0x0D54
+ BLUE_SCALE = 0x0D1A
+ CLIENT_ATTRIB_STACK_DEPTH = 0x0BB1
+ COLOR_ARRAY_SIZE = 0x8081
+ COLOR_ARRAY_STRIDE = 0x8083
+ COLOR_ARRAY_TYPE = 0x8082
+ COLOR_CLEAR_VALUE = 0x0C22
+ COLOR_MATERIAL_FACE = 0x0B55
+ COLOR_MATERIAL_PARAMETER = 0x0B56
+ COLOR_WRITEMASK = 0x0C23
+ CULL_FACE_MODE = 0x0B45
+ CURRENT_COLOR = 0x0B00
+ CURRENT_INDEX = 0x0B01
+ CURRENT_NORMAL = 0x0B02
+ CURRENT_RASTER_COLOR = 0x0B04
+ CURRENT_RASTER_DISTANCE = 0x0B09
+ CURRENT_RASTER_INDEX = 0x0B05
+ CURRENT_RASTER_POSITION = 0x0B07
+ CURRENT_RASTER_POSITION_VALID = 0x0B08
+ CURRENT_RASTER_TEXTURE_COORDS = 0x0B06
+ CURRENT_TEXTURE_COORDS = 0x0B03
+ DEPTH_BIAS = 0x0D1F
+ DEPTH_BITS = 0x0D56
+ DEPTH_CLEAR_VALUE = 0x0B73
+ DEPTH_FUNC = 0x0B74
+ DEPTH_RANGE = 0x0B70
+ DEPTH_SCALE = 0x0D1E
+ DEPTH_WRITEMASK = 0x0B72
+ DOUBLEBUFFER = 0x0C32
+ DRAW_BUFFER = 0x0C01
+ EDGE_FLAG = 0x0B43
+ EDGE_FLAG_ARRAY_STRIDE = 0x808C
+ FEEDBACK_BUFFER_SIZE = 0x0DF1
+ FEEDBACK_BUFFER_TYPE = 0x0DF2
+ FOG_HINT = 0x0C54
+ FRONT_FACE = 0x0B46
+ GREEN_BIAS = 0x0D19
+ GREEN_BITS = 0x0D53
+ GREEN_SCALE = 0x0D18
+ INDEX_ARRAY_STRIDE = 0x8086
+ INDEX_ARRAY_TYPE = 0x8085
+ INDEX_BITS = 0x0D51
+ INDEX_CLEAR_VALUE = 0x0C20
+ INDEX_MODE = 0x0C30
+ INDEX_OFFSET = 0x0D13
+ INDEX_SHIFT = 0x0D12
+ INDEX_WRITEMASK = 0x0C21
+ LIGHT_MODEL_AMBIENT = 0x0B53
+ LIGHT_MODEL_COLOR_CONTROL = 0x81F8
+ LIGHT_MODEL_LOCAL_VIEWER = 0x0B51
+ LIGHT_MODEL_TWO_SIDE = 0x0B52
+ LINE_SMOOTH_HINT = 0x0C52
+ LINE_STIPPLE_PATTERN = 0x0B25
+ LINE_STIPPLE_REPEAT = 0x0B26
+ LINE_WIDTH = 0x0B21
+ LINE_WIDTH_GRANULARITY = 0x0B23
+ LINE_WIDTH_RANGE = 0x0B22
+ LIST_BASE = 0x0B32
+ LIST_INDEX = 0x0B33
+ LIST_MODE = 0x0B30
+ LOGIC_OP_MODE = 0x0BF0
+ MAP1_GRID_DOMAIN = 0x0DD0
+ MAP1_GRID_SEGMENTS = 0x0DD1
+ MAP2_GRID_DOMAIN = 0x0DD2
+ MAP2_GRID_SEGMENTS = 0x0DD3
+ MAP_COLOR = 0x0D10
+ MAP_STENCIL = 0x0D11
+ MATRIX_MODE = 0x0BA0
+ MAX_ATTRIB_STACK_DEPTH = 0x0D35
+ MAX_CLIENT_ATTRIB_STACK_DEPTH = 0x0D3B
+ MAX_CLIP_DISTANCES = 0x0D32
+ MAX_CLIP_PLANES = 0x0D32
+ MAX_EVAL_ORDER = 0x0D30
+ MAX_LIGHTS = 0x0D31
+ MAX_LIST_NESTING = 0x0B31
+ MAX_MODELVIEW_STACK_DEPTH = 0x0D36
+ MAX_NAME_STACK_DEPTH = 0x0D37
+ MAX_PIXEL_MAP_TABLE = 0x0D34
+ MAX_PROJECTION_STACK_DEPTH = 0x0D38
+ MAX_TEXTURE_SIZE = 0x0D33
+ MAX_TEXTURE_STACK_DEPTH = 0x0D39
+ MAX_VIEWPORT_DIMS = 0x0D3A
+ MODELVIEW_MATRIX = 0x0BA6
+ MODELVIEW_STACK_DEPTH = 0x0BA3
+ NAME_STACK_DEPTH = 0x0D70
+ NORMAL_ARRAY_STRIDE = 0x807F
+ NORMAL_ARRAY_TYPE = 0x807E
+ PACK_ALIGNMENT = 0x0D05
+ PACK_LSB_FIRST = 0x0D01
+ PACK_ROW_LENGTH = 0x0D02
+ PACK_SKIP_PIXELS = 0x0D04
+ PACK_SKIP_ROWS = 0x0D03
+ PACK_SWAP_BYTES = 0x0D00
+ PERSPECTIVE_CORRECTION_HINT = 0x0C50
+ PIXEL_MAP_A_TO_A_SIZE = 0x0CB9
+ PIXEL_MAP_B_TO_B_SIZE = 0x0CB8
+ PIXEL_MAP_G_TO_G_SIZE = 0x0CB7
+ PIXEL_MAP_I_TO_A_SIZE = 0x0CB5
+ PIXEL_MAP_I_TO_B_SIZE = 0x0CB4
+ PIXEL_MAP_I_TO_G_SIZE = 0x0CB3
+ PIXEL_MAP_I_TO_I_SIZE = 0x0CB0
+ PIXEL_MAP_I_TO_R_SIZE = 0x0CB2
+ PIXEL_MAP_R_TO_R_SIZE = 0x0CB6
+ PIXEL_MAP_S_TO_S_SIZE = 0x0CB1
+ POINT_SIZE = 0x0B11
+ POINT_SIZE_GRANULARITY = 0x0B13
+ POINT_SIZE_RANGE = 0x0B12
+ POINT_SMOOTH_HINT = 0x0C51
+ POLYGON_MODE = 0x0B40
+ POLYGON_OFFSET_FACTOR = 0x8038
+ POLYGON_OFFSET_UNITS = 0x2A00
+ POLYGON_SMOOTH_HINT = 0x0C53
+ PROJECTION_MATRIX = 0x0BA7
+ PROJECTION_STACK_DEPTH = 0x0BA4
+ READ_BUFFER = 0x0C02
+ RED_BIAS = 0x0D15
+ RED_BITS = 0x0D52
+ RED_SCALE = 0x0D14
+ RENDER_MODE = 0x0C40
+ RGBA_MODE = 0x0C31
+ SCISSOR_BOX = 0x0C10
+ SELECTION_BUFFER_SIZE = 0x0DF4
+ SHADE_MODEL = 0x0B54
+ SMOOTH_LINE_WIDTH_GRANULARITY = 0x0B23
+ SMOOTH_LINE_WIDTH_RANGE = 0x0B22
+ SMOOTH_POINT_SIZE_GRANULARITY = 0x0B13
+ SMOOTH_POINT_SIZE_RANGE = 0x0B12
+ STENCIL_BITS = 0x0D57
+ STENCIL_CLEAR_VALUE = 0x0B91
+ STENCIL_FAIL = 0x0B94
+ STENCIL_FUNC = 0x0B92
+ STENCIL_PASS_DEPTH_FAIL = 0x0B95
+ STENCIL_PASS_DEPTH_PASS = 0x0B96
+ STENCIL_REF = 0x0B97
+ STENCIL_VALUE_MASK = 0x0B93
+ STENCIL_WRITEMASK = 0x0B98
+ STEREO = 0x0C33
+ SUBPIXEL_BITS = 0x0D50
+ TEXTURE_BINDING_1D = 0x8068
+ TEXTURE_BINDING_2D = 0x8069
+ TEXTURE_BINDING_3D = 0x806A
+ TEXTURE_COORD_ARRAY_SIZE = 0x8088
+ TEXTURE_COORD_ARRAY_STRIDE = 0x808A
+ TEXTURE_COORD_ARRAY_TYPE = 0x8089
+ TEXTURE_MATRIX = 0x0BA8
+ TEXTURE_STACK_DEPTH = 0x0BA5
+ UNPACK_ALIGNMENT = 0x0CF5
+ UNPACK_LSB_FIRST = 0x0CF1
+ UNPACK_ROW_LENGTH = 0x0CF2
+ UNPACK_SKIP_PIXELS = 0x0CF4
+ UNPACK_SKIP_ROWS = 0x0CF3
+ UNPACK_SWAP_BYTES = 0x0CF0
+ VERTEX_ARRAY_SIZE = 0x807A
+ VERTEX_ARRAY_STRIDE = 0x807C
+ VERTEX_ARRAY_TYPE = 0x807B
+ VIEWPORT = 0x0BA2
+ ZOOM_X = 0x0D16
+ ZOOM_Y = 0x0D17
+
+ COLOR_ARRAY_POINTER = 0x8090
+ EDGE_FLAG_ARRAY_POINTER = 0x8093
+ FEEDBACK_BUFFER_POINTER = 0x0DF0
+ INDEX_ARRAY_POINTER = 0x8091
+ NORMAL_ARRAY_POINTER = 0x808F
+ SELECTION_BUFFER_POINTER = 0x0DF3
+ TEXTURE_COORD_ARRAY_POINTER = 0x8092
+ VERTEX_ARRAY_POINTER = 0x808E
+
+ TEXTURE_ALPHA_SIZE = 0x805F
+ TEXTURE_BLUE_SIZE = 0x805E
+ TEXTURE_BORDER = 0x1005
+ TEXTURE_BORDER_COLOR = 0x1004
+ TEXTURE_COMPONENTS = 0x1003
+ TEXTURE_GREEN_SIZE = 0x805D
+ TEXTURE_HEIGHT = 0x1001
+ TEXTURE_INTENSITY_SIZE = 0x8061
+ TEXTURE_INTERNAL_FORMAT = 0x1003
+ TEXTURE_LUMINANCE_SIZE = 0x8060
+ TEXTURE_MAG_FILTER = 0x2800
+ TEXTURE_MIN_FILTER = 0x2801
+ TEXTURE_PRIORITY = 0x8066
+ TEXTURE_RED_SIZE = 0x805C
+ TEXTURE_RESIDENT = 0x8067
+ TEXTURE_WIDTH = 0x1000
+ TEXTURE_WRAP_S = 0x2802
+ TEXTURE_WRAP_T = 0x2803
+
+ DONT_CARE = 0x1100
+ FASTEST = 0x1101
+ NICEST = 0x1102
+
+ FRAGMENT_SHADER_DERIVATIVE_HINT = 0x8B8B
+ GENERATE_MIPMAP_HINT = 0x8192
+ PROGRAM_BINARY_RETRIEVABLE_HINT = 0x8257
+ TEXTURE_COMPRESSION_HINT = 0x84EF
+
+ C3F_V3F = 0x2A24
+ C4F_N3F_V3F = 0x2A26
+ C4UB_V2F = 0x2A22
+ C4UB_V3F = 0x2A23
+ N3F_V3F = 0x2A25
+ T2F_C3F_V3F = 0x2A2A
+ T2F_C4F_N3F_V3F = 0x2A2C
+ T2F_C4UB_V3F = 0x2A29
+ T2F_N3F_V3F = 0x2A2B
+ T2F_V3F = 0x2A27
+ T4F_C4F_N3F_V4F = 0x2A2D
+ T4F_V4F = 0x2A28
+ V2F = 0x2A20
+ V3F = 0x2A21
+
+ MODULATE = 0x2100
+ REPLACE = 0x1E01
+
+ SEPARATE_SPECULAR_COLOR = 0x81FA
+ SINGLE_COLOR = 0x81F9
+
+ CONSTANT_ATTENUATION = 0x1207
+ LINEAR_ATTENUATION = 0x1208
+ POSITION = 0x1203
+ QUADRATIC_ATTENUATION = 0x1209
+ SPOT_CUTOFF = 0x1206
+ SPOT_DIRECTION = 0x1204
+ SPOT_EXPONENT = 0x1205
+
+ COMPILE = 0x1300
+ COMPILE_AND_EXECUTE = 0x1301
+
+ AND = 0x1501
+ AND_INVERTED = 0x1504
+ AND_REVERSE = 0x1502
+ CLEAR = 0x1500
+ COPY = 0x1503
+ COPY_INVERTED = 0x150C
+ EQUIV = 0x1509
+ INVERT = 0x150A
+ NAND = 0x150E
+ NOOP = 0x1505
+ NOR = 0x1508
+ OR = 0x1507
+ OR_INVERTED = 0x150D
+ OR_REVERSE = 0x150B
+ SET = 0x150F
+ XOR = 0x1506
+
+ MAP_FLUSH_EXPLICIT_BIT = 0x0010
+ MAP_INVALIDATE_BUFFER_BIT = 0x0008
+ MAP_INVALIDATE_RANGE_BIT = 0x0004
+ MAP_READ_BIT = 0x0001
+ MAP_UNSYNCHRONIZED_BIT = 0x0020
+ MAP_WRITE_BIT = 0x0002
+
+ COLOR_INDEXES = 0x1603
+ SHININESS = 0x1601
+
+ MODELVIEW = 0x1700
+ PROJECTION = 0x1701
+ TEXTURE = 0x1702
+
+ LINE = 0x1B01
+ POINT = 0x1B00
+
+ FILL = 0x1B02
+
+ COLOR = 0x1800
+ DEPTH = 0x1801
+ STENCIL = 0x1802
+
+ ALPHA = 0x1906
+ BLUE = 0x1905
+ COLOR_INDEX = 0x1900
+ DEPTH_COMPONENT = 0x1902
+ GREEN = 0x1904
+ LUMINANCE = 0x1909
+ LUMINANCE_ALPHA = 0x190A
+ RED = 0x1903
+ RGB = 0x1907
+ RGBA = 0x1908
+ STENCIL_INDEX = 0x1901
+
+ ALPHA12 = 0x803D
+ ALPHA16 = 0x803E
+ ALPHA4 = 0x803B
+ ALPHA8 = 0x803C
+ INTENSITY = 0x8049
+ INTENSITY12 = 0x804C
+ INTENSITY16 = 0x804D
+ INTENSITY4 = 0x804A
+ INTENSITY8 = 0x804B
+ LUMINANCE12 = 0x8041
+ LUMINANCE12_ALPHA12 = 0x8047
+ LUMINANCE12_ALPHA4 = 0x8046
+ LUMINANCE16 = 0x8042
+ LUMINANCE16_ALPHA16 = 0x8048
+ LUMINANCE4 = 0x803F
+ LUMINANCE4_ALPHA4 = 0x8043
+ LUMINANCE6_ALPHA2 = 0x8044
+ LUMINANCE8 = 0x8040
+ LUMINANCE8_ALPHA8 = 0x8045
+ R3_G3_B2 = 0x2A10
+ RGB10 = 0x8052
+ RGB10_A2 = 0x8059
+ RGB12 = 0x8053
+ RGB16 = 0x8054
+ RGB4 = 0x804F
+ RGB5 = 0x8050
+ RGB5_A1 = 0x8057
+ RGB8 = 0x8051
+ RGBA12 = 0x805A
+ RGBA16 = 0x805B
+ RGBA2 = 0x8055
+ RGBA4 = 0x8056
+ RGBA8 = 0x8058
+
+ PACK_IMAGE_HEIGHT = 0x806C
+ PACK_SKIP_IMAGES = 0x806B
+ UNPACK_IMAGE_HEIGHT = 0x806E
+ UNPACK_SKIP_IMAGES = 0x806D
+
+ BITMAP = 0x1A00
+ UNSIGNED_BYTE_3_3_2 = 0x8032
+ UNSIGNED_INT_10_10_10_2 = 0x8036
+ UNSIGNED_INT_8_8_8_8 = 0x8035
+ UNSIGNED_SHORT_4_4_4_4 = 0x8033
+ UNSIGNED_SHORT_5_5_5_1 = 0x8034
+
+ POINT_DISTANCE_ATTENUATION = 0x8129
+ POINT_FADE_THRESHOLD_SIZE = 0x8128
+ POINT_SIZE_MAX = 0x8127
+ POINT_SIZE_MIN = 0x8126
+
+ LINES = 0x0001
+ LINES_ADJACENCY = 0x000A
+ LINE_LOOP = 0x0002
+ LINE_STRIP = 0x0003
+ LINE_STRIP_ADJACENCY = 0x000B
+ PATCHES = 0x000E
+ POINTS = 0x0000
+ POLYGON = 0x0009
+ QUADS = 0x0007
+ QUAD_STRIP = 0x0008
+ TRIANGLES = 0x0004
+ TRIANGLES_ADJACENCY = 0x000C
+ TRIANGLE_FAN = 0x0006
+ TRIANGLE_STRIP = 0x0005
+ TRIANGLE_STRIP_ADJACENCY = 0x000D
+
+ FEEDBACK = 0x1C01
+ RENDER = 0x1C00
+ SELECT = 0x1C02
+
+ FLAT = 0x1D00
+ SMOOTH = 0x1D01
+
+ DECR = 0x1E03
+ INCR = 0x1E02
+ KEEP = 0x1E00
+
+ EXTENSIONS = 0x1F03
+ RENDERER = 0x1F01
+ VENDOR = 0x1F00
+ VERSION = 0x1F02
+
+ S = 0x2000
+ T = 0x2001
+ R = 0x2002
+ Q = 0x2003
+
+ DECAL = 0x2101
+
+ TEXTURE_ENV_COLOR = 0x2201
+ TEXTURE_ENV_MODE = 0x2200
+
+ TEXTURE_ENV = 0x2300
+
+ EYE_LINEAR = 0x2400
+ OBJECT_LINEAR = 0x2401
+ SPHERE_MAP = 0x2402
+
+ EYE_PLANE = 0x2502
+ OBJECT_PLANE = 0x2501
+ TEXTURE_GEN_MODE = 0x2500
+
+ NEAREST = 0x2600
+
+ LINEAR_MIPMAP_LINEAR = 0x2703
+ LINEAR_MIPMAP_NEAREST = 0x2701
+ NEAREST_MIPMAP_LINEAR = 0x2702
+ NEAREST_MIPMAP_NEAREST = 0x2700
+
+ GENERATE_MIPMAP = 0x8191
+ TEXTURE_WRAP_R = 0x8072
+
+ PROXY_TEXTURE_1D = 0x8063
+ PROXY_TEXTURE_2D = 0x8064
+ PROXY_TEXTURE_3D = 0x8070
+ TEXTURE_3D = 0x806F
+ TEXTURE_BASE_LEVEL = 0x813C
+ TEXTURE_MAX_LEVEL = 0x813D
+ TEXTURE_MAX_LOD = 0x813B
+ TEXTURE_MIN_LOD = 0x813A
+
+ CLAMP = 0x2900
+ CLAMP_TO_BORDER = 0x812D
+ CLAMP_TO_EDGE = 0x812F
+ REPEAT = 0x2901
+
+ VERTEX_SHADER_BIT = 0x00000001
+ FRAGMENT_SHADER_BIT = 0x00000002
+ GEOMETRY_SHADER_BIT = 0x00000004
+ TESS_CONTROL_SHADER_BIT = 0x00000008
+ TESS_EVALUATION_SHADER_BIT = 0x00000010
+ ALL_SHADER_BITS = 0xFFFFFFFF
+
+ SYNC_FLUSH_COMMANDS_BIT = 0x00000001
+ INVALID_INDEX = 0xFFFFFFFF
+ TIMEOUT_IGNORED = 0xFFFFFFFFFFFFFFFF
+ CONSTANT_COLOR = 0x8001
+ ONE_MINUS_CONSTANT_COLOR = 0x8002
+ CONSTANT_ALPHA = 0x8003
+ ONE_MINUS_CONSTANT_ALPHA = 0x8004
+ FUNC_ADD = 0x8006
+ MIN = 0x8007
+ MAX = 0x8008
+ BLEND_EQUATION_RGB = 0x8009
+ FUNC_SUBTRACT = 0x800A
+ FUNC_REVERSE_SUBTRACT = 0x800B
+ RESCALE_NORMAL = 0x803A
+ TEXTURE_DEPTH = 0x8071
+ MAX_3D_TEXTURE_SIZE = 0x8073
+ MULTISAMPLE = 0x809D
+ SAMPLE_ALPHA_TO_COVERAGE = 0x809E
+ SAMPLE_ALPHA_TO_ONE = 0x809F
+ SAMPLE_COVERAGE = 0x80A0
+ SAMPLE_BUFFERS = 0x80A8
+ SAMPLES = 0x80A9
+ SAMPLE_COVERAGE_VALUE = 0x80AA
+ SAMPLE_COVERAGE_INVERT = 0x80AB
+ BLEND_DST_RGB = 0x80C8
+ BLEND_SRC_RGB = 0x80C9
+ BLEND_DST_ALPHA = 0x80CA
+ BLEND_SRC_ALPHA = 0x80CB
+ BGR = 0x80E0
+ BGRA = 0x80E1
+ MAX_ELEMENTS_VERTICES = 0x80E8
+ MAX_ELEMENTS_INDICES = 0x80E9
+ DEPTH_COMPONENT16 = 0x81A5
+ DEPTH_COMPONENT24 = 0x81A6
+ DEPTH_COMPONENT32 = 0x81A7
+ FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING = 0x8210
+ FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE = 0x8211
+ FRAMEBUFFER_ATTACHMENT_RED_SIZE = 0x8212
+ FRAMEBUFFER_ATTACHMENT_GREEN_SIZE = 0x8213
+ FRAMEBUFFER_ATTACHMENT_BLUE_SIZE = 0x8214
+ FRAMEBUFFER_ATTACHMENT_ALPHA_SIZE = 0x8215
+ FRAMEBUFFER_ATTACHMENT_DEPTH_SIZE = 0x8216
+ FRAMEBUFFER_ATTACHMENT_STENCIL_SIZE = 0x8217
+ FRAMEBUFFER_DEFAULT = 0x8218
+ FRAMEBUFFER_UNDEFINED = 0x8219
+ DEPTH_STENCIL_ATTACHMENT = 0x821A
+ MAJOR_VERSION = 0x821B
+ MINOR_VERSION = 0x821C
+ NUM_EXTENSIONS = 0x821D
+ CONTEXT_FLAGS = 0x821E
+ INDEX = 0x8222
+ COMPRESSED_RED = 0x8225
+ COMPRESSED_RG = 0x8226
+ RG = 0x8227
+ RG_INTEGER = 0x8228
+ R8 = 0x8229
+ R16 = 0x822A
+ RG8 = 0x822B
+ RG16 = 0x822C
+ R16F = 0x822D
+ R32F = 0x822E
+ RG16F = 0x822F
+ RG32F = 0x8230
+ R8I = 0x8231
+ R8UI = 0x8232
+ R16I = 0x8233
+ R16UI = 0x8234
+ R32I = 0x8235
+ R32UI = 0x8236
+ RG8I = 0x8237
+ RG8UI = 0x8238
+ RG16I = 0x8239
+ RG16UI = 0x823A
+ RG32I = 0x823B
+ RG32UI = 0x823C
+ PROGRAM_SEPARABLE = 0x8258
+ ACTIVE_PROGRAM = 0x8259
+ PROGRAM_PIPELINE_BINDING = 0x825A
+ MAX_VIEWPORTS = 0x825B
+ VIEWPORT_SUBPIXEL_BITS = 0x825C
+ VIEWPORT_BOUNDS_RANGE = 0x825D
+ LAYER_PROVOKING_VERTEX = 0x825E
+ VIEWPORT_INDEX_PROVOKING_VERTEX = 0x825F
+ UNDEFINED_VERTEX = 0x8260
+ UNSIGNED_BYTE_2_3_3_REV = 0x8362
+ UNSIGNED_SHORT_5_6_5 = 0x8363
+ UNSIGNED_SHORT_5_6_5_REV = 0x8364
+ UNSIGNED_SHORT_4_4_4_4_REV = 0x8365
+ UNSIGNED_SHORT_1_5_5_5_REV = 0x8366
+ UNSIGNED_INT_8_8_8_8_REV = 0x8367
+ UNSIGNED_INT_2_10_10_10_REV = 0x8368
+ MIRRORED_REPEAT = 0x8370
+ FOG_COORDINATE_SOURCE = 0x8450
+ FOG_COORD_SRC = 0x8450
+ FOG_COORDINATE = 0x8451
+ FOG_COORD = 0x8451
+ FRAGMENT_DEPTH = 0x8452
+ CURRENT_FOG_COORDINATE = 0x8453
+ CURRENT_FOG_COORD = 0x8453
+ FOG_COORDINATE_ARRAY_TYPE = 0x8454
+ FOG_COORD_ARRAY_TYPE = 0x8454
+ FOG_COORDINATE_ARRAY_STRIDE = 0x8455
+ FOG_COORD_ARRAY_STRIDE = 0x8455
+ FOG_COORDINATE_ARRAY_POINTER = 0x8456
+ FOG_COORD_ARRAY_POINTER = 0x8456
+ FOG_COORDINATE_ARRAY = 0x8457
+ FOG_COORD_ARRAY = 0x8457
+ COLOR_SUM = 0x8458
+ CURRENT_SECONDARY_COLOR = 0x8459
+ SECONDARY_COLOR_ARRAY_SIZE = 0x845A
+ SECONDARY_COLOR_ARRAY_TYPE = 0x845B
+ SECONDARY_COLOR_ARRAY_STRIDE = 0x845C
+ SECONDARY_COLOR_ARRAY_POINTER = 0x845D
+ SECONDARY_COLOR_ARRAY = 0x845E
+ CURRENT_RASTER_SECONDARY_COLOR = 0x845F
+ TEXTURE0 = 0x84C0
+ TEXTURE1 = 0x84C1
+ TEXTURE2 = 0x84C2
+ TEXTURE3 = 0x84C3
+ TEXTURE4 = 0x84C4
+ TEXTURE5 = 0x84C5
+ TEXTURE6 = 0x84C6
+ TEXTURE7 = 0x84C7
+ TEXTURE8 = 0x84C8
+ TEXTURE9 = 0x84C9
+ TEXTURE10 = 0x84CA
+ TEXTURE11 = 0x84CB
+ TEXTURE12 = 0x84CC
+ TEXTURE13 = 0x84CD
+ TEXTURE14 = 0x84CE
+ TEXTURE15 = 0x84CF
+ TEXTURE16 = 0x84D0
+ TEXTURE17 = 0x84D1
+ TEXTURE18 = 0x84D2
+ TEXTURE19 = 0x84D3
+ TEXTURE20 = 0x84D4
+ TEXTURE21 = 0x84D5
+ TEXTURE22 = 0x84D6
+ TEXTURE23 = 0x84D7
+ TEXTURE24 = 0x84D8
+ TEXTURE25 = 0x84D9
+ TEXTURE26 = 0x84DA
+ TEXTURE27 = 0x84DB
+ TEXTURE28 = 0x84DC
+ TEXTURE29 = 0x84DD
+ TEXTURE30 = 0x84DE
+ TEXTURE31 = 0x84DF
+ ACTIVE_TEXTURE = 0x84E0
+ CLIENT_ACTIVE_TEXTURE = 0x84E1
+ MAX_TEXTURE_UNITS = 0x84E2
+ TRANSPOSE_MODELVIEW_MATRIX = 0x84E3
+ TRANSPOSE_PROJECTION_MATRIX = 0x84E4
+ TRANSPOSE_TEXTURE_MATRIX = 0x84E5
+ TRANSPOSE_COLOR_MATRIX = 0x84E6
+ SUBTRACT = 0x84E7
+ MAX_RENDERBUFFER_SIZE = 0x84E8
+ COMPRESSED_ALPHA = 0x84E9
+ COMPRESSED_LUMINANCE = 0x84EA
+ COMPRESSED_LUMINANCE_ALPHA = 0x84EB
+ COMPRESSED_INTENSITY = 0x84EC
+ COMPRESSED_RGB = 0x84ED
+ COMPRESSED_RGBA = 0x84EE
+ UNIFORM_BLOCK_REFERENCED_BY_TESS_CONTROL_SHADER = 0x84F0
+ UNIFORM_BLOCK_REFERENCED_BY_TESS_EVALUATION_SHADER = 0x84F1
+ TEXTURE_RECTANGLE = 0x84F5
+ TEXTURE_BINDING_RECTANGLE = 0x84F6
+ PROXY_TEXTURE_RECTANGLE = 0x84F7
+ MAX_RECTANGLE_TEXTURE_SIZE = 0x84F8
+ DEPTH_STENCIL = 0x84F9
+ UNSIGNED_INT_24_8 = 0x84FA
+ MAX_TEXTURE_LOD_BIAS = 0x84FD
+ TEXTURE_FILTER_CONTROL = 0x8500
+ TEXTURE_LOD_BIAS = 0x8501
+ INCR_WRAP = 0x8507
+ DECR_WRAP = 0x8508
+ NORMAL_MAP = 0x8511
+ REFLECTION_MAP = 0x8512
+ TEXTURE_CUBE_MAP = 0x8513
+ TEXTURE_BINDING_CUBE_MAP = 0x8514
+ TEXTURE_CUBE_MAP_POSITIVE_X = 0x8515
+ TEXTURE_CUBE_MAP_NEGATIVE_X = 0x8516
+ TEXTURE_CUBE_MAP_POSITIVE_Y = 0x8517
+ TEXTURE_CUBE_MAP_NEGATIVE_Y = 0x8518
+ TEXTURE_CUBE_MAP_POSITIVE_Z = 0x8519
+ TEXTURE_CUBE_MAP_NEGATIVE_Z = 0x851A
+ PROXY_TEXTURE_CUBE_MAP = 0x851B
+ MAX_CUBE_MAP_TEXTURE_SIZE = 0x851C
+ COMBINE = 0x8570
+ COMBINE_RGB = 0x8571
+ COMBINE_ALPHA = 0x8572
+ RGB_SCALE = 0x8573
+ ADD_SIGNED = 0x8574
+ INTERPOLATE = 0x8575
+ CONSTANT = 0x8576
+ PRIMARY_COLOR = 0x8577
+ PREVIOUS = 0x8578
+ SOURCE0_RGB = 0x8580
+ SRC0_RGB = 0x8580
+ SOURCE1_RGB = 0x8581
+ SRC1_RGB = 0x8581
+ SOURCE2_RGB = 0x8582
+ SRC2_RGB = 0x8582
+ SOURCE0_ALPHA = 0x8588
+ SRC0_ALPHA = 0x8588
+ SOURCE1_ALPHA = 0x8589
+ SRC1_ALPHA = 0x8589
+ SOURCE2_ALPHA = 0x858A
+ SRC2_ALPHA = 0x858A
+ OPERAND0_RGB = 0x8590
+ OPERAND1_RGB = 0x8591
+ OPERAND2_RGB = 0x8592
+ OPERAND0_ALPHA = 0x8598
+ OPERAND1_ALPHA = 0x8599
+ OPERAND2_ALPHA = 0x859A
+ VERTEX_ARRAY_BINDING = 0x85B5
+ VERTEX_ATTRIB_ARRAY_ENABLED = 0x8622
+ VERTEX_ATTRIB_ARRAY_SIZE = 0x8623
+ VERTEX_ATTRIB_ARRAY_STRIDE = 0x8624
+ VERTEX_ATTRIB_ARRAY_TYPE = 0x8625
+ CURRENT_VERTEX_ATTRIB = 0x8626
+ VERTEX_PROGRAM_POINT_SIZE = 0x8642
+ PROGRAM_POINT_SIZE = 0x8642
+ VERTEX_PROGRAM_TWO_SIDE = 0x8643
+ VERTEX_ATTRIB_ARRAY_POINTER = 0x8645
+ DEPTH_CLAMP = 0x864F
+ TEXTURE_COMPRESSED_IMAGE_SIZE = 0x86A0
+ TEXTURE_COMPRESSED = 0x86A1
+ NUM_COMPRESSED_TEXTURE_FORMATS = 0x86A2
+ COMPRESSED_TEXTURE_FORMATS = 0x86A3
+ DOT3_RGB = 0x86AE
+ DOT3_RGBA = 0x86AF
+ PROGRAM_BINARY_LENGTH = 0x8741
+ BUFFER_SIZE = 0x8764
+ BUFFER_USAGE = 0x8765
+ NUM_PROGRAM_BINARY_FORMATS = 0x87FE
+ PROGRAM_BINARY_FORMATS = 0x87FF
+ STENCIL_BACK_FUNC = 0x8800
+ STENCIL_BACK_FAIL = 0x8801
+ STENCIL_BACK_PASS_DEPTH_FAIL = 0x8802
+ STENCIL_BACK_PASS_DEPTH_PASS = 0x8803
+ RGBA32F = 0x8814
+ RGB32F = 0x8815
+ RGBA16F = 0x881A
+ RGB16F = 0x881B
+ MAX_DRAW_BUFFERS = 0x8824
+ DRAW_BUFFER0 = 0x8825
+ DRAW_BUFFER1 = 0x8826
+ DRAW_BUFFER2 = 0x8827
+ DRAW_BUFFER3 = 0x8828
+ DRAW_BUFFER4 = 0x8829
+ DRAW_BUFFER5 = 0x882A
+ DRAW_BUFFER6 = 0x882B
+ DRAW_BUFFER7 = 0x882C
+ DRAW_BUFFER8 = 0x882D
+ DRAW_BUFFER9 = 0x882E
+ DRAW_BUFFER10 = 0x882F
+ DRAW_BUFFER11 = 0x8830
+ DRAW_BUFFER12 = 0x8831
+ DRAW_BUFFER13 = 0x8832
+ DRAW_BUFFER14 = 0x8833
+ DRAW_BUFFER15 = 0x8834
+ BLEND_EQUATION_ALPHA = 0x883D
+ TEXTURE_DEPTH_SIZE = 0x884A
+ DEPTH_TEXTURE_MODE = 0x884B
+ TEXTURE_COMPARE_MODE = 0x884C
+ TEXTURE_COMPARE_FUNC = 0x884D
+ COMPARE_R_TO_TEXTURE = 0x884E
+ COMPARE_REF_TO_TEXTURE = 0x884E
+ TEXTURE_CUBE_MAP_SEAMLESS = 0x884F
+ POINT_SPRITE = 0x8861
+ COORD_REPLACE = 0x8862
+ QUERY_COUNTER_BITS = 0x8864
+ CURRENT_QUERY = 0x8865
+ QUERY_RESULT = 0x8866
+ QUERY_RESULT_AVAILABLE = 0x8867
+ MAX_VERTEX_ATTRIBS = 0x8869
+ VERTEX_ATTRIB_ARRAY_NORMALIZED = 0x886A
+ MAX_TESS_CONTROL_INPUT_COMPONENTS = 0x886C
+ MAX_TESS_EVALUATION_INPUT_COMPONENTS = 0x886D
+ MAX_TEXTURE_COORDS = 0x8871
+ MAX_TEXTURE_IMAGE_UNITS = 0x8872
+ GEOMETRY_SHADER_INVOCATIONS = 0x887F
+ ARRAY_BUFFER = 0x8892
+ ELEMENT_ARRAY_BUFFER = 0x8893
+ ARRAY_BUFFER_BINDING = 0x8894
+ ELEMENT_ARRAY_BUFFER_BINDING = 0x8895
+ VERTEX_ARRAY_BUFFER_BINDING = 0x8896
+ NORMAL_ARRAY_BUFFER_BINDING = 0x8897
+ COLOR_ARRAY_BUFFER_BINDING = 0x8898
+ INDEX_ARRAY_BUFFER_BINDING = 0x8899
+ TEXTURE_COORD_ARRAY_BUFFER_BINDING = 0x889A
+ EDGE_FLAG_ARRAY_BUFFER_BINDING = 0x889B
+ SECONDARY_COLOR_ARRAY_BUFFER_BINDING = 0x889C
+ FOG_COORDINATE_ARRAY_BUFFER_BINDING = 0x889D
+ FOG_COORD_ARRAY_BUFFER_BINDING = 0x889D
+ WEIGHT_ARRAY_BUFFER_BINDING = 0x889E
+ VERTEX_ATTRIB_ARRAY_BUFFER_BINDING = 0x889F
+ READ_ONLY = 0x88B8
+ WRITE_ONLY = 0x88B9
+ READ_WRITE = 0x88BA
+ BUFFER_ACCESS = 0x88BB
+ BUFFER_MAPPED = 0x88BC
+ BUFFER_MAP_POINTER = 0x88BD
+ TIME_ELAPSED = 0x88BF
+ STREAM_DRAW = 0x88E0
+ STREAM_READ = 0x88E1
+ STREAM_COPY = 0x88E2
+ STATIC_DRAW = 0x88E4
+ STATIC_READ = 0x88E5
+ STATIC_COPY = 0x88E6
+ DYNAMIC_DRAW = 0x88E8
+ DYNAMIC_READ = 0x88E9
+ DYNAMIC_COPY = 0x88EA
+ PIXEL_PACK_BUFFER = 0x88EB
+ PIXEL_UNPACK_BUFFER = 0x88EC
+ PIXEL_PACK_BUFFER_BINDING = 0x88ED
+ PIXEL_UNPACK_BUFFER_BINDING = 0x88EF
+ DEPTH24_STENCIL8 = 0x88F0
+ TEXTURE_STENCIL_SIZE = 0x88F1
+ SRC1_COLOR = 0x88F9
+ ONE_MINUS_SRC1_COLOR = 0x88FA
+ ONE_MINUS_SRC1_ALPHA = 0x88FB
+ MAX_DUAL_SOURCE_DRAW_BUFFERS = 0x88FC
+ VERTEX_ATTRIB_ARRAY_INTEGER = 0x88FD
+ VERTEX_ATTRIB_ARRAY_DIVISOR = 0x88FE
+ MAX_ARRAY_TEXTURE_LAYERS = 0x88FF
+ MIN_PROGRAM_TEXEL_OFFSET = 0x8904
+ MAX_PROGRAM_TEXEL_OFFSET = 0x8905
+ SAMPLES_PASSED = 0x8914
+ GEOMETRY_VERTICES_OUT = 0x8916
+ GEOMETRY_INPUT_TYPE = 0x8917
+ GEOMETRY_OUTPUT_TYPE = 0x8918
+ SAMPLER_BINDING = 0x8919
+ CLAMP_VERTEX_COLOR = 0x891A
+ CLAMP_FRAGMENT_COLOR = 0x891B
+ CLAMP_READ_COLOR = 0x891C
+ FIXED_ONLY = 0x891D
+ UNIFORM_BUFFER = 0x8A11
+ UNIFORM_BUFFER_BINDING = 0x8A28
+ UNIFORM_BUFFER_START = 0x8A29
+ UNIFORM_BUFFER_SIZE = 0x8A2A
+ MAX_VERTEX_UNIFORM_BLOCKS = 0x8A2B
+ MAX_GEOMETRY_UNIFORM_BLOCKS = 0x8A2C
+ MAX_FRAGMENT_UNIFORM_BLOCKS = 0x8A2D
+ MAX_COMBINED_UNIFORM_BLOCKS = 0x8A2E
+ MAX_UNIFORM_BUFFER_BINDINGS = 0x8A2F
+ MAX_UNIFORM_BLOCK_SIZE = 0x8A30
+ MAX_COMBINED_VERTEX_UNIFORM_COMPONENTS = 0x8A31
+ MAX_COMBINED_GEOMETRY_UNIFORM_COMPONENTS = 0x8A32
+ MAX_COMBINED_FRAGMENT_UNIFORM_COMPONENTS = 0x8A33
+ UNIFORM_BUFFER_OFFSET_ALIGNMENT = 0x8A34
+ ACTIVE_UNIFORM_BLOCK_MAX_NAME_LENGTH = 0x8A35
+ ACTIVE_UNIFORM_BLOCKS = 0x8A36
+ UNIFORM_TYPE = 0x8A37
+ UNIFORM_SIZE = 0x8A38
+ UNIFORM_NAME_LENGTH = 0x8A39
+ UNIFORM_BLOCK_INDEX = 0x8A3A
+ UNIFORM_OFFSET = 0x8A3B
+ UNIFORM_ARRAY_STRIDE = 0x8A3C
+ UNIFORM_MATRIX_STRIDE = 0x8A3D
+ UNIFORM_IS_ROW_MAJOR = 0x8A3E
+ UNIFORM_BLOCK_BINDING = 0x8A3F
+ UNIFORM_BLOCK_DATA_SIZE = 0x8A40
+ UNIFORM_BLOCK_NAME_LENGTH = 0x8A41
+ UNIFORM_BLOCK_ACTIVE_UNIFORMS = 0x8A42
+ UNIFORM_BLOCK_ACTIVE_UNIFORM_INDICES = 0x8A43
+ UNIFORM_BLOCK_REFERENCED_BY_VERTEX_SHADER = 0x8A44
+ UNIFORM_BLOCK_REFERENCED_BY_GEOMETRY_SHADER = 0x8A45
+ UNIFORM_BLOCK_REFERENCED_BY_FRAGMENT_SHADER = 0x8A46
+ FRAGMENT_SHADER = 0x8B30
+ VERTEX_SHADER = 0x8B31
+ MAX_FRAGMENT_UNIFORM_COMPONENTS = 0x8B49
+ MAX_VERTEX_UNIFORM_COMPONENTS = 0x8B4A
+ MAX_VARYING_FLOATS = 0x8B4B
+ MAX_VARYING_COMPONENTS = 0x8B4B
+ MAX_VERTEX_TEXTURE_IMAGE_UNITS = 0x8B4C
+ MAX_COMBINED_TEXTURE_IMAGE_UNITS = 0x8B4D
+ SHADER_TYPE = 0x8B4F
+ FLOAT_VEC2 = 0x8B50
+ FLOAT_VEC3 = 0x8B51
+ FLOAT_VEC4 = 0x8B52
+ INT_VEC2 = 0x8B53
+ INT_VEC3 = 0x8B54
+ INT_VEC4 = 0x8B55
+ BOOL = 0x8B56
+ BOOL_VEC2 = 0x8B57
+ BOOL_VEC3 = 0x8B58
+ BOOL_VEC4 = 0x8B59
+ FLOAT_MAT2 = 0x8B5A
+ FLOAT_MAT3 = 0x8B5B
+ FLOAT_MAT4 = 0x8B5C
+ SAMPLER_1D = 0x8B5D
+ SAMPLER_2D = 0x8B5E
+ SAMPLER_3D = 0x8B5F
+ SAMPLER_CUBE = 0x8B60
+ SAMPLER_1D_SHADOW = 0x8B61
+ SAMPLER_2D_SHADOW = 0x8B62
+ SAMPLER_2D_RECT = 0x8B63
+ SAMPLER_2D_RECT_SHADOW = 0x8B64
+ FLOAT_MAT2x3 = 0x8B65
+ FLOAT_MAT2x4 = 0x8B66
+ FLOAT_MAT3x2 = 0x8B67
+ FLOAT_MAT3x4 = 0x8B68
+ FLOAT_MAT4x2 = 0x8B69
+ FLOAT_MAT4x3 = 0x8B6A
+ DELETE_STATUS = 0x8B80
+ COMPILE_STATUS = 0x8B81
+ LINK_STATUS = 0x8B82
+ VALIDATE_STATUS = 0x8B83
+ INFO_LOG_LENGTH = 0x8B84
+ ATTACHED_SHADERS = 0x8B85
+ ACTIVE_UNIFORMS = 0x8B86
+ ACTIVE_UNIFORM_MAX_LENGTH = 0x8B87
+ SHADER_SOURCE_LENGTH = 0x8B88
+ ACTIVE_ATTRIBUTES = 0x8B89
+ ACTIVE_ATTRIBUTE_MAX_LENGTH = 0x8B8A
+ SHADING_LANGUAGE_VERSION = 0x8B8C
+ CURRENT_PROGRAM = 0x8B8D
+ IMPLEMENTATION_COLOR_READ_TYPE = 0x8B9A
+ IMPLEMENTATION_COLOR_READ_FORMAT = 0x8B9B
+ TEXTURE_RED_TYPE = 0x8C10
+ TEXTURE_GREEN_TYPE = 0x8C11
+ TEXTURE_BLUE_TYPE = 0x8C12
+ TEXTURE_ALPHA_TYPE = 0x8C13
+ TEXTURE_LUMINANCE_TYPE = 0x8C14
+ TEXTURE_INTENSITY_TYPE = 0x8C15
+ TEXTURE_DEPTH_TYPE = 0x8C16
+ UNSIGNED_NORMALIZED = 0x8C17
+ TEXTURE_1D_ARRAY = 0x8C18
+ PROXY_TEXTURE_1D_ARRAY = 0x8C19
+ TEXTURE_2D_ARRAY = 0x8C1A
+ PROXY_TEXTURE_2D_ARRAY = 0x8C1B
+ TEXTURE_BINDING_1D_ARRAY = 0x8C1C
+ TEXTURE_BINDING_2D_ARRAY = 0x8C1D
+ MAX_GEOMETRY_TEXTURE_IMAGE_UNITS = 0x8C29
+ TEXTURE_BUFFER = 0x8C2A
+ MAX_TEXTURE_BUFFER_SIZE = 0x8C2B
+ TEXTURE_BINDING_BUFFER = 0x8C2C
+ TEXTURE_BUFFER_DATA_STORE_BINDING = 0x8C2D
+ ANY_SAMPLES_PASSED = 0x8C2F
+ SAMPLE_SHADING = 0x8C36
+ MIN_SAMPLE_SHADING_VALUE = 0x8C37
+ R11F_G11F_B10F = 0x8C3A
+ UNSIGNED_INT_10F_11F_11F_REV = 0x8C3B
+ RGB9_E5 = 0x8C3D
+ UNSIGNED_INT_5_9_9_9_REV = 0x8C3E
+ TEXTURE_SHARED_SIZE = 0x8C3F
+ SRGB = 0x8C40
+ SRGB8 = 0x8C41
+ SRGB_ALPHA = 0x8C42
+ SRGB8_ALPHA8 = 0x8C43
+ SLUMINANCE_ALPHA = 0x8C44
+ SLUMINANCE8_ALPHA8 = 0x8C45
+ SLUMINANCE = 0x8C46
+ SLUMINANCE8 = 0x8C47
+ COMPRESSED_SRGB = 0x8C48
+ COMPRESSED_SRGB_ALPHA = 0x8C49
+ COMPRESSED_SLUMINANCE = 0x8C4A
+ COMPRESSED_SLUMINANCE_ALPHA = 0x8C4B
+ TRANSFORM_FEEDBACK_VARYING_MAX_LENGTH = 0x8C76
+ TRANSFORM_FEEDBACK_BUFFER_MODE = 0x8C7F
+ MAX_TRANSFORM_FEEDBACK_SEPARATE_COMPONENTS = 0x8C80
+ TRANSFORM_FEEDBACK_VARYINGS = 0x8C83
+ TRANSFORM_FEEDBACK_BUFFER_START = 0x8C84
+ TRANSFORM_FEEDBACK_BUFFER_SIZE = 0x8C85
+ PRIMITIVES_GENERATED = 0x8C87
+ TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN = 0x8C88
+ RASTERIZER_DISCARD = 0x8C89
+ MAX_TRANSFORM_FEEDBACK_INTERLEAVED_COMPONENTS = 0x8C8A
+ MAX_TRANSFORM_FEEDBACK_SEPARATE_ATTRIBS = 0x8C8B
+ INTERLEAVED_ATTRIBS = 0x8C8C
+ SEPARATE_ATTRIBS = 0x8C8D
+ TRANSFORM_FEEDBACK_BUFFER = 0x8C8E
+ TRANSFORM_FEEDBACK_BUFFER_BINDING = 0x8C8F
+ POINT_SPRITE_COORD_ORIGIN = 0x8CA0
+ LOWER_LEFT = 0x8CA1
+ UPPER_LEFT = 0x8CA2
+ STENCIL_BACK_REF = 0x8CA3
+ STENCIL_BACK_VALUE_MASK = 0x8CA4
+ STENCIL_BACK_WRITEMASK = 0x8CA5
+ DRAW_FRAMEBUFFER_BINDING = 0x8CA6
+ FRAMEBUFFER_BINDING = 0x8CA6
+ RENDERBUFFER_BINDING = 0x8CA7
+ READ_FRAMEBUFFER = 0x8CA8
+ DRAW_FRAMEBUFFER = 0x8CA9
+ READ_FRAMEBUFFER_BINDING = 0x8CAA
+ RENDERBUFFER_SAMPLES = 0x8CAB
+ DEPTH_COMPONENT32F = 0x8CAC
+ DEPTH32F_STENCIL8 = 0x8CAD
+ FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE = 0x8CD0
+ FRAMEBUFFER_ATTACHMENT_OBJECT_NAME = 0x8CD1
+ FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL = 0x8CD2
+ FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE = 0x8CD3
+ FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER = 0x8CD4
+ FRAMEBUFFER_COMPLETE = 0x8CD5
+ FRAMEBUFFER_INCOMPLETE_ATTACHMENT = 0x8CD6
+ FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT = 0x8CD7
+ FRAMEBUFFER_INCOMPLETE_DRAW_BUFFER = 0x8CDB
+ FRAMEBUFFER_INCOMPLETE_READ_BUFFER = 0x8CDC
+ FRAMEBUFFER_UNSUPPORTED = 0x8CDD
+ MAX_COLOR_ATTACHMENTS = 0x8CDF
+ COLOR_ATTACHMENT0 = 0x8CE0
+ COLOR_ATTACHMENT1 = 0x8CE1
+ COLOR_ATTACHMENT2 = 0x8CE2
+ COLOR_ATTACHMENT3 = 0x8CE3
+ COLOR_ATTACHMENT4 = 0x8CE4
+ COLOR_ATTACHMENT5 = 0x8CE5
+ COLOR_ATTACHMENT6 = 0x8CE6
+ COLOR_ATTACHMENT7 = 0x8CE7
+ COLOR_ATTACHMENT8 = 0x8CE8
+ COLOR_ATTACHMENT9 = 0x8CE9
+ COLOR_ATTACHMENT10 = 0x8CEA
+ COLOR_ATTACHMENT11 = 0x8CEB
+ COLOR_ATTACHMENT12 = 0x8CEC
+ COLOR_ATTACHMENT13 = 0x8CED
+ COLOR_ATTACHMENT14 = 0x8CEE
+ COLOR_ATTACHMENT15 = 0x8CEF
+ DEPTH_ATTACHMENT = 0x8D00
+ STENCIL_ATTACHMENT = 0x8D20
+ FRAMEBUFFER = 0x8D40
+ RENDERBUFFER = 0x8D41
+ RENDERBUFFER_WIDTH = 0x8D42
+ RENDERBUFFER_HEIGHT = 0x8D43
+ RENDERBUFFER_INTERNAL_FORMAT = 0x8D44
+ STENCIL_INDEX1 = 0x8D46
+ STENCIL_INDEX4 = 0x8D47
+ STENCIL_INDEX8 = 0x8D48
+ STENCIL_INDEX16 = 0x8D49
+ RENDERBUFFER_RED_SIZE = 0x8D50
+ RENDERBUFFER_GREEN_SIZE = 0x8D51
+ RENDERBUFFER_BLUE_SIZE = 0x8D52
+ RENDERBUFFER_ALPHA_SIZE = 0x8D53
+ RENDERBUFFER_DEPTH_SIZE = 0x8D54
+ RENDERBUFFER_STENCIL_SIZE = 0x8D55
+ FRAMEBUFFER_INCOMPLETE_MULTISAMPLE = 0x8D56
+ MAX_SAMPLES = 0x8D57
+ RGB565 = 0x8D62
+ RGBA32UI = 0x8D70
+ RGB32UI = 0x8D71
+ RGBA16UI = 0x8D76
+ RGB16UI = 0x8D77
+ RGBA8UI = 0x8D7C
+ RGB8UI = 0x8D7D
+ RGBA32I = 0x8D82
+ RGB32I = 0x8D83
+ RGBA16I = 0x8D88
+ RGB16I = 0x8D89
+ RGBA8I = 0x8D8E
+ RGB8I = 0x8D8F
+ RED_INTEGER = 0x8D94
+ GREEN_INTEGER = 0x8D95
+ BLUE_INTEGER = 0x8D96
+ ALPHA_INTEGER = 0x8D97
+ RGB_INTEGER = 0x8D98
+ RGBA_INTEGER = 0x8D99
+ BGR_INTEGER = 0x8D9A
+ BGRA_INTEGER = 0x8D9B
+ INT_2_10_10_10_REV = 0x8D9F
+ FRAMEBUFFER_ATTACHMENT_LAYERED = 0x8DA7
+ FRAMEBUFFER_INCOMPLETE_LAYER_TARGETS = 0x8DA8
+ FLOAT_32_UNSIGNED_INT_24_8_REV = 0x8DAD
+ FRAMEBUFFER_SRGB = 0x8DB9
+ COMPRESSED_RED_RGTC1 = 0x8DBB
+ COMPRESSED_SIGNED_RED_RGTC1 = 0x8DBC
+ COMPRESSED_RG_RGTC2 = 0x8DBD
+ COMPRESSED_SIGNED_RG_RGTC2 = 0x8DBE
+ SAMPLER_1D_ARRAY = 0x8DC0
+ SAMPLER_2D_ARRAY = 0x8DC1
+ SAMPLER_BUFFER = 0x8DC2
+ SAMPLER_1D_ARRAY_SHADOW = 0x8DC3
+ SAMPLER_2D_ARRAY_SHADOW = 0x8DC4
+ SAMPLER_CUBE_SHADOW = 0x8DC5
+ UNSIGNED_INT_VEC2 = 0x8DC6
+ UNSIGNED_INT_VEC3 = 0x8DC7
+ UNSIGNED_INT_VEC4 = 0x8DC8
+ INT_SAMPLER_1D = 0x8DC9
+ INT_SAMPLER_2D = 0x8DCA
+ INT_SAMPLER_3D = 0x8DCB
+ INT_SAMPLER_CUBE = 0x8DCC
+ INT_SAMPLER_2D_RECT = 0x8DCD
+ INT_SAMPLER_1D_ARRAY = 0x8DCE
+ INT_SAMPLER_2D_ARRAY = 0x8DCF
+ INT_SAMPLER_BUFFER = 0x8DD0
+ UNSIGNED_INT_SAMPLER_1D = 0x8DD1
+ UNSIGNED_INT_SAMPLER_2D = 0x8DD2
+ UNSIGNED_INT_SAMPLER_3D = 0x8DD3
+ UNSIGNED_INT_SAMPLER_CUBE = 0x8DD4
+ UNSIGNED_INT_SAMPLER_2D_RECT = 0x8DD5
+ UNSIGNED_INT_SAMPLER_1D_ARRAY = 0x8DD6
+ UNSIGNED_INT_SAMPLER_2D_ARRAY = 0x8DD7
+ UNSIGNED_INT_SAMPLER_BUFFER = 0x8DD8
+ GEOMETRY_SHADER = 0x8DD9
+ MAX_GEOMETRY_UNIFORM_COMPONENTS = 0x8DDF
+ MAX_GEOMETRY_OUTPUT_VERTICES = 0x8DE0
+ MAX_GEOMETRY_TOTAL_OUTPUT_COMPONENTS = 0x8DE1
+ ACTIVE_SUBROUTINES = 0x8DE5
+ ACTIVE_SUBROUTINE_UNIFORMS = 0x8DE6
+ MAX_SUBROUTINES = 0x8DE7
+ MAX_SUBROUTINE_UNIFORM_LOCATIONS = 0x8DE8
+ LOW_FLOAT = 0x8DF0
+ MEDIUM_FLOAT = 0x8DF1
+ HIGH_FLOAT = 0x8DF2
+ LOW_INT = 0x8DF3
+ MEDIUM_INT = 0x8DF4
+ HIGH_INT = 0x8DF5
+ SHADER_BINARY_FORMATS = 0x8DF8
+ NUM_SHADER_BINARY_FORMATS = 0x8DF9
+ SHADER_COMPILER = 0x8DFA
+ MAX_VERTEX_UNIFORM_VECTORS = 0x8DFB
+ MAX_VARYING_VECTORS = 0x8DFC
+ MAX_FRAGMENT_UNIFORM_VECTORS = 0x8DFD
+ QUERY_WAIT = 0x8E13
+ QUERY_NO_WAIT = 0x8E14
+ QUERY_BY_REGION_WAIT = 0x8E15
+ QUERY_BY_REGION_NO_WAIT = 0x8E16
+ MAX_COMBINED_TESS_CONTROL_UNIFORM_COMPONENTS = 0x8E1E
+ MAX_COMBINED_TESS_EVALUATION_UNIFORM_COMPONENTS = 0x8E1F
+ TRANSFORM_FEEDBACK = 0x8E22
+ TRANSFORM_FEEDBACK_BUFFER_PAUSED = 0x8E23
+ TRANSFORM_FEEDBACK_BUFFER_ACTIVE = 0x8E24
+ TRANSFORM_FEEDBACK_BINDING = 0x8E25
+ TIMESTAMP = 0x8E28
+ TEXTURE_SWIZZLE_R = 0x8E42
+ TEXTURE_SWIZZLE_G = 0x8E43
+ TEXTURE_SWIZZLE_B = 0x8E44
+ TEXTURE_SWIZZLE_A = 0x8E45
+ TEXTURE_SWIZZLE_RGBA = 0x8E46
+ ACTIVE_SUBROUTINE_UNIFORM_LOCATIONS = 0x8E47
+ ACTIVE_SUBROUTINE_MAX_LENGTH = 0x8E48
+ ACTIVE_SUBROUTINE_UNIFORM_MAX_LENGTH = 0x8E49
+ NUM_COMPATIBLE_SUBROUTINES = 0x8E4A
+ COMPATIBLE_SUBROUTINES = 0x8E4B
+ QUADS_FOLLOW_PROVOKING_VERTEX_CONVENTION = 0x8E4C
+ FIRST_VERTEX_CONVENTION = 0x8E4D
+ LAST_VERTEX_CONVENTION = 0x8E4E
+ PROVOKING_VERTEX = 0x8E4F
+ SAMPLE_POSITION = 0x8E50
+ SAMPLE_MASK = 0x8E51
+ SAMPLE_MASK_VALUE = 0x8E52
+ MAX_SAMPLE_MASK_WORDS = 0x8E59
+ MAX_GEOMETRY_SHADER_INVOCATIONS = 0x8E5A
+ MIN_FRAGMENT_INTERPOLATION_OFFSET = 0x8E5B
+ MAX_FRAGMENT_INTERPOLATION_OFFSET = 0x8E5C
+ FRAGMENT_INTERPOLATION_OFFSET_BITS = 0x8E5D
+ MIN_PROGRAM_TEXTURE_GATHER_OFFSET = 0x8E5E
+ MAX_PROGRAM_TEXTURE_GATHER_OFFSET = 0x8E5F
+ MAX_TRANSFORM_FEEDBACK_BUFFERS = 0x8E70
+ MAX_VERTEX_STREAMS = 0x8E71
+ PATCH_VERTICES = 0x8E72
+ PATCH_DEFAULT_INNER_LEVEL = 0x8E73
+ PATCH_DEFAULT_OUTER_LEVEL = 0x8E74
+ TESS_CONTROL_OUTPUT_VERTICES = 0x8E75
+ TESS_GEN_MODE = 0x8E76
+ TESS_GEN_SPACING = 0x8E77
+ TESS_GEN_VERTEX_ORDER = 0x8E78
+ TESS_GEN_POINT_MODE = 0x8E79
+ ISOLINES = 0x8E7A
+ FRACTIONAL_ODD = 0x8E7B
+ FRACTIONAL_EVEN = 0x8E7C
+ MAX_PATCH_VERTICES = 0x8E7D
+ MAX_TESS_GEN_LEVEL = 0x8E7E
+ MAX_TESS_CONTROL_UNIFORM_COMPONENTS = 0x8E7F
+ MAX_TESS_EVALUATION_UNIFORM_COMPONENTS = 0x8E80
+ MAX_TESS_CONTROL_TEXTURE_IMAGE_UNITS = 0x8E81
+ MAX_TESS_EVALUATION_TEXTURE_IMAGE_UNITS = 0x8E82
+ MAX_TESS_CONTROL_OUTPUT_COMPONENTS = 0x8E83
+ MAX_TESS_PATCH_COMPONENTS = 0x8E84
+ MAX_TESS_CONTROL_TOTAL_OUTPUT_COMPONENTS = 0x8E85
+ MAX_TESS_EVALUATION_OUTPUT_COMPONENTS = 0x8E86
+ TESS_EVALUATION_SHADER = 0x8E87
+ TESS_CONTROL_SHADER = 0x8E88
+ MAX_TESS_CONTROL_UNIFORM_BLOCKS = 0x8E89
+ MAX_TESS_EVALUATION_UNIFORM_BLOCKS = 0x8E8A
+ COPY_READ_BUFFER = 0x8F36
+ COPY_WRITE_BUFFER = 0x8F37
+ DRAW_INDIRECT_BUFFER = 0x8F3F
+ DRAW_INDIRECT_BUFFER_BINDING = 0x8F43
+ DOUBLE_MAT2 = 0x8F46
+ DOUBLE_MAT3 = 0x8F47
+ DOUBLE_MAT4 = 0x8F48
+ DOUBLE_MAT2x3 = 0x8F49
+ DOUBLE_MAT2x4 = 0x8F4A
+ DOUBLE_MAT3x2 = 0x8F4B
+ DOUBLE_MAT3x4 = 0x8F4C
+ DOUBLE_MAT4x2 = 0x8F4D
+ DOUBLE_MAT4x3 = 0x8F4E
+ R8_SNORM = 0x8F94
+ RG8_SNORM = 0x8F95
+ RGB8_SNORM = 0x8F96
+ RGBA8_SNORM = 0x8F97
+ R16_SNORM = 0x8F98
+ RG16_SNORM = 0x8F99
+ RGB16_SNORM = 0x8F9A
+ RGBA16_SNORM = 0x8F9B
+ SIGNED_NORMALIZED = 0x8F9C
+ PRIMITIVE_RESTART = 0x8F9D
+ PRIMITIVE_RESTART_INDEX = 0x8F9E
+ DOUBLE_VEC2 = 0x8FFC
+ DOUBLE_VEC3 = 0x8FFD
+ DOUBLE_VEC4 = 0x8FFE
+ TEXTURE_CUBE_MAP_ARRAY = 0x9009
+ TEXTURE_BINDING_CUBE_MAP_ARRAY = 0x900A
+ PROXY_TEXTURE_CUBE_MAP_ARRAY = 0x900B
+ SAMPLER_CUBE_MAP_ARRAY = 0x900C
+ SAMPLER_CUBE_MAP_ARRAY_SHADOW = 0x900D
+ INT_SAMPLER_CUBE_MAP_ARRAY = 0x900E
+ UNSIGNED_INT_SAMPLER_CUBE_MAP_ARRAY = 0x900F
+ RGB10_A2UI = 0x906F
+ TEXTURE_2D_MULTISAMPLE = 0x9100
+ PROXY_TEXTURE_2D_MULTISAMPLE = 0x9101
+ TEXTURE_2D_MULTISAMPLE_ARRAY = 0x9102
+ PROXY_TEXTURE_2D_MULTISAMPLE_ARRAY = 0x9103
+ TEXTURE_BINDING_2D_MULTISAMPLE = 0x9104
+ TEXTURE_BINDING_2D_MULTISAMPLE_ARRAY = 0x9105
+ TEXTURE_SAMPLES = 0x9106
+ TEXTURE_FIXED_SAMPLE_LOCATIONS = 0x9107
+ SAMPLER_2D_MULTISAMPLE = 0x9108
+ INT_SAMPLER_2D_MULTISAMPLE = 0x9109
+ UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE = 0x910A
+ SAMPLER_2D_MULTISAMPLE_ARRAY = 0x910B
+ INT_SAMPLER_2D_MULTISAMPLE_ARRAY = 0x910C
+ UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE_ARRAY = 0x910D
+ MAX_COLOR_TEXTURE_SAMPLES = 0x910E
+ MAX_DEPTH_TEXTURE_SAMPLES = 0x910F
+ MAX_INTEGER_SAMPLES = 0x9110
+ MAX_SERVER_WAIT_TIMEOUT = 0x9111
+ OBJECT_TYPE = 0x9112
+ SYNC_CONDITION = 0x9113
+ SYNC_STATUS = 0x9114
+ SYNC_FLAGS = 0x9115
+ SYNC_FENCE = 0x9116
+ SYNC_GPU_COMMANDS_COMPLETE = 0x9117
+ UNSIGNALED = 0x9118
+ SIGNALED = 0x9119
+ ALREADY_SIGNALED = 0x911A
+ TIMEOUT_EXPIRED = 0x911B
+ CONDITION_SATISFIED = 0x911C
+ WAIT_FAILED = 0x911D
+ BUFFER_ACCESS_FLAGS = 0x911F
+ BUFFER_MAP_LENGTH = 0x9120
+ BUFFER_MAP_OFFSET = 0x9121
+ MAX_VERTEX_OUTPUT_COMPONENTS = 0x9122
+ MAX_GEOMETRY_INPUT_COMPONENTS = 0x9123
+ MAX_GEOMETRY_OUTPUT_COMPONENTS = 0x9124
+ MAX_FRAGMENT_INPUT_COMPONENTS = 0x9125
+ CONTEXT_PROFILE_MASK = 0x9126
+)
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glViewport.xml
+func (gl *GL) Viewport(x, y, width, height int) {
+ C.gl4_1compat_glViewport(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// DepthRange specifies the mapping of depth values from normalized device
+// coordinates to window coordinates.
+//
+// Parameter nearVal specifies the mapping of the near clipping plane to window
+// coordinates (defaults to 0), while farVal specifies the mapping of the far
+// clipping plane to window coordinates (defaults to 1).
+//
+// After clipping and division by w, depth coordinates range from -1 to 1,
+// corresponding to the near and far clipping planes. DepthRange specifies a
+// linear mapping of the normalized depth coordinates in this range to window
+// depth coordinates. Regardless of the actual depth buffer implementation,
+// window coordinate depth values are treated as though they range from 0 through 1
+// (like color components). Thus, the values accepted by DepthRange are both
+// clamped to this range before they are accepted.
+//
+// The default setting of (0, 1) maps the near plane to 0 and the far plane to 1.
+// With this mapping, the depth buffer range is fully utilized.
+//
+// It is not necessary that nearVal be less than farVal. Reverse mappings such as
+// nearVal 1, and farVal 0 are acceptable.
+//
+// GL.INVALID_OPERATION is generated if DepthRange is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) DepthRange(nearVal, farVal float64) {
+ C.gl4_1compat_glDepthRange(gl.funcs, C.GLdouble(nearVal), C.GLdouble(farVal))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsEnabled.xml
+func (gl *GL) IsEnabled(cap glbase.Enum) bool {
+ glresult := C.gl4_1compat_glIsEnabled(gl.funcs, C.GLenum(cap))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexLevelParameteriv.xml
+func (gl *GL) GetTexLevelParameteriv(target glbase.Enum, level int, pname glbase.Enum, params []int32) {
+ C.gl4_1compat_glGetTexLevelParameteriv(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexLevelParameterfv.xml
+func (gl *GL) GetTexLevelParameterfv(target glbase.Enum, level int, pname glbase.Enum, params []float32) {
+ C.gl4_1compat_glGetTexLevelParameterfv(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexParameteriv.xml
+func (gl *GL) GetTexParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl4_1compat_glGetTexParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexParameterfv.xml
+func (gl *GL) GetTexParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl4_1compat_glGetTexParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexImage.xml
+func (gl *GL) GetTexImage(target glbase.Enum, level int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1compat_glGetTexImage(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetIntegerv.xml
+func (gl *GL) GetIntegerv(pname glbase.Enum, params []int32) {
+ C.gl4_1compat_glGetIntegerv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetFloatv.xml
+func (gl *GL) GetFloatv(pname glbase.Enum, params []float32) {
+ C.gl4_1compat_glGetFloatv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetError.xml
+func (gl *GL) GetError() glbase.Enum {
+ glresult := C.gl4_1compat_glGetError(gl.funcs)
+ return glbase.Enum(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetDoublev.xml
+func (gl *GL) GetDoublev(pname glbase.Enum, params []float64) {
+ C.gl4_1compat_glGetDoublev(gl.funcs, C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetBooleanv.xml
+func (gl *GL) GetBooleanv(pname glbase.Enum, params []bool) {
+ C.gl4_1compat_glGetBooleanv(gl.funcs, C.GLenum(pname), (*C.GLboolean)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glReadPixels.xml
+func (gl *GL) ReadPixels(x, y, width, height int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1compat_glReadPixels(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glReadBuffer.xml
+func (gl *GL) ReadBuffer(mode glbase.Enum) {
+ C.gl4_1compat_glReadBuffer(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPixelStorei.xml
+func (gl *GL) PixelStorei(pname glbase.Enum, param int32) {
+ C.gl4_1compat_glPixelStorei(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPixelStoref.xml
+func (gl *GL) PixelStoref(pname glbase.Enum, param float32) {
+ C.gl4_1compat_glPixelStoref(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDepthFunc.xml
+func (gl *GL) DepthFunc(glfunc glbase.Enum) {
+ C.gl4_1compat_glDepthFunc(gl.funcs, C.GLenum(glfunc))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glStencilOp.xml
+func (gl *GL) StencilOp(fail, zfail, zpass glbase.Enum) {
+ C.gl4_1compat_glStencilOp(gl.funcs, C.GLenum(fail), C.GLenum(zfail), C.GLenum(zpass))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glStencilFunc.xml
+func (gl *GL) StencilFunc(glfunc glbase.Enum, ref int32, mask uint32) {
+ C.gl4_1compat_glStencilFunc(gl.funcs, C.GLenum(glfunc), C.GLint(ref), C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLogicOp.xml
+func (gl *GL) LogicOp(opcode glbase.Enum) {
+ C.gl4_1compat_glLogicOp(gl.funcs, C.GLenum(opcode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendFunc.xml
+func (gl *GL) BlendFunc(sfactor, dfactor glbase.Enum) {
+ C.gl4_1compat_glBlendFunc(gl.funcs, C.GLenum(sfactor), C.GLenum(dfactor))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFlush.xml
+func (gl *GL) Flush() {
+ C.gl4_1compat_glFlush(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFinish.xml
+func (gl *GL) Finish() {
+ C.gl4_1compat_glFinish(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEnable.xml
+func (gl *GL) Enable(cap glbase.Enum) {
+ C.gl4_1compat_glEnable(gl.funcs, C.GLenum(cap))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDisable.xml
+func (gl *GL) Disable(cap glbase.Enum) {
+ C.gl4_1compat_glDisable(gl.funcs, C.GLenum(cap))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDepthMask.xml
+func (gl *GL) DepthMask(flag bool) {
+ C.gl4_1compat_glDepthMask(gl.funcs, *(*C.GLboolean)(unsafe.Pointer(&flag)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorMask.xml
+func (gl *GL) ColorMask(red, green, blue, alpha bool) {
+ C.gl4_1compat_glColorMask(gl.funcs, *(*C.GLboolean)(unsafe.Pointer(&red)), *(*C.GLboolean)(unsafe.Pointer(&green)), *(*C.GLboolean)(unsafe.Pointer(&blue)), *(*C.GLboolean)(unsafe.Pointer(&alpha)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glStencilMask.xml
+func (gl *GL) StencilMask(mask uint32) {
+ C.gl4_1compat_glStencilMask(gl.funcs, C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearDepth.xml
+func (gl *GL) ClearDepth(depth float64) {
+ C.gl4_1compat_glClearDepth(gl.funcs, C.GLdouble(depth))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearStencil.xml
+func (gl *GL) ClearStencil(s int32) {
+ C.gl4_1compat_glClearStencil(gl.funcs, C.GLint(s))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearColor.xml
+func (gl *GL) ClearColor(red, green, blue, alpha float32) {
+ C.gl4_1compat_glClearColor(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClear.xml
+func (gl *GL) Clear(mask glbase.Bitfield) {
+ C.gl4_1compat_glClear(gl.funcs, C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawBuffer.xml
+func (gl *GL) DrawBuffer(mode glbase.Enum) {
+ C.gl4_1compat_glDrawBuffer(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexImage2D.xml
+func (gl *GL) TexImage2D(target glbase.Enum, level int, internalFormat int32, width, height, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1compat_glTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexImage1D.xml
+func (gl *GL) TexImage1D(target glbase.Enum, level int, internalFormat int32, width, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1compat_glTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexParameteriv.xml
+func (gl *GL) TexParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl4_1compat_glTexParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexParameteri.xml
+func (gl *GL) TexParameteri(target, pname glbase.Enum, param int32) {
+ C.gl4_1compat_glTexParameteri(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexParameterfv.xml
+func (gl *GL) TexParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl4_1compat_glTexParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexParameterf.xml
+func (gl *GL) TexParameterf(target, pname glbase.Enum, param float32) {
+ C.gl4_1compat_glTexParameterf(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glScissor.xml
+func (gl *GL) Scissor(x, y, width, height int) {
+ C.gl4_1compat_glScissor(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPolygonMode.xml
+func (gl *GL) PolygonMode(face, mode glbase.Enum) {
+ C.gl4_1compat_glPolygonMode(gl.funcs, C.GLenum(face), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPointSize.xml
+func (gl *GL) PointSize(size float32) {
+ C.gl4_1compat_glPointSize(gl.funcs, C.GLfloat(size))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLineWidth.xml
+func (gl *GL) LineWidth(width float32) {
+ C.gl4_1compat_glLineWidth(gl.funcs, C.GLfloat(width))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glHint.xml
+func (gl *GL) Hint(target, mode glbase.Enum) {
+ C.gl4_1compat_glHint(gl.funcs, C.GLenum(target), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFrontFace.xml
+func (gl *GL) FrontFace(mode glbase.Enum) {
+ C.gl4_1compat_glFrontFace(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCullFace.xml
+func (gl *GL) CullFace(mode glbase.Enum) {
+ C.gl4_1compat_glCullFace(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIndexubv.xml
+func (gl *GL) Indexubv(c []uint8) {
+ C.gl4_1compat_glIndexubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIndexub.xml
+func (gl *GL) Indexub(c uint8) {
+ C.gl4_1compat_glIndexub(gl.funcs, C.GLubyte(c))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsTexture.xml
+func (gl *GL) IsTexture(texture glbase.Texture) bool {
+ glresult := C.gl4_1compat_glIsTexture(gl.funcs, C.GLuint(texture))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// GenTextures returns n texture names in textures. There is no guarantee
+// that the names form a contiguous set of integers; however, it is
+// guaranteed that none of the returned names was in use immediately before
+// the call to GenTextures.
+//
+// The generated textures have no dimensionality; they assume the
+// dimensionality of the texture target to which they are first bound (see
+// BindTexture).
+//
+// Texture names returned by a call to GenTextures are not returned by
+// subsequent calls, unless they are first deleted with DeleteTextures.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// GenTextures is available in GL version 2.0 or greater.
+func (gl *GL) GenTextures(n int) []glbase.Texture {
+ if n == 0 {
+ return nil
+ }
+ textures := make([]glbase.Texture, n)
+ C.gl4_1compat_glGenTextures(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])))
+ return textures
+}
+
+// DeleteTextures deletes the textures objects whose names are stored
+// in the textures slice. After a texture is deleted, it has no contents or
+// dimensionality, and its name is free for reuse (for example by
+// GenTextures). If a texture that is currently bound is deleted, the binding
+// reverts to 0 (the default texture).
+//
+// DeleteTextures silently ignores 0's and names that do not correspond to
+// existing textures.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// DeleteTextures is available in GL version 2.0 or greater.
+func (gl *GL) DeleteTextures(textures []glbase.Texture) {
+ n := len(textures)
+ if n == 0 {
+ return
+ }
+ C.gl4_1compat_glDeleteTextures(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindTexture.xml
+func (gl *GL) BindTexture(target glbase.Enum, texture glbase.Texture) {
+ C.gl4_1compat_glBindTexture(gl.funcs, C.GLenum(target), C.GLuint(texture))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexSubImage2D.xml
+func (gl *GL) TexSubImage2D(target glbase.Enum, level, xoffset, yoffset, width, height int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1compat_glTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexSubImage1D.xml
+func (gl *GL) TexSubImage1D(target glbase.Enum, level, xoffset, width int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1compat_glTexSubImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLsizei(width), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyTexSubImage2D.xml
+func (gl *GL) CopyTexSubImage2D(target glbase.Enum, level, xoffset, yoffset, x, y, width, height int) {
+ C.gl4_1compat_glCopyTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyTexSubImage1D.xml
+func (gl *GL) CopyTexSubImage1D(target glbase.Enum, level, xoffset, x, y, width int) {
+ C.gl4_1compat_glCopyTexSubImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(x), C.GLint(y), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyTexImage2D.xml
+func (gl *GL) CopyTexImage2D(target glbase.Enum, level int, internalFormat glbase.Enum, x, y, width, height, border int) {
+ C.gl4_1compat_glCopyTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height), C.GLint(border))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyTexImage1D.xml
+func (gl *GL) CopyTexImage1D(target glbase.Enum, level int, internalFormat glbase.Enum, x, y, width, border int) {
+ C.gl4_1compat_glCopyTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLint(border))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPolygonOffset.xml
+func (gl *GL) PolygonOffset(factor, units float32) {
+ C.gl4_1compat_glPolygonOffset(gl.funcs, C.GLfloat(factor), C.GLfloat(units))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawElements.xml
+func (gl *GL) DrawElements(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1compat_glDrawElements(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawArrays.xml
+func (gl *GL) DrawArrays(mode glbase.Enum, first, count int) {
+ C.gl4_1compat_glDrawArrays(gl.funcs, C.GLenum(mode), C.GLint(first), C.GLsizei(count))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyTexSubImage3D.xml
+func (gl *GL) CopyTexSubImage3D(target glbase.Enum, level, xoffset, yoffset int, zoffset int32, x, y, width, height int) {
+ C.gl4_1compat_glCopyTexSubImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(zoffset), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexSubImage3D.xml
+func (gl *GL) TexSubImage3D(target glbase.Enum, level, xoffset, yoffset int, zoffset int32, width, height int, depth int32, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1compat_glTexSubImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(zoffset), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexImage3D.xml
+func (gl *GL) TexImage3D(target glbase.Enum, level int, internalFormat int32, width, height int, depth int32, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1compat_glTexImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawRangeElements.xml
+func (gl *GL) DrawRangeElements(mode glbase.Enum, start, end uint32, count int, gltype glbase.Enum, indices interface{}) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1compat_glDrawRangeElements(gl.funcs, C.GLenum(mode), C.GLuint(start), C.GLuint(end), C.GLsizei(count), C.GLenum(gltype), indices_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendEquation.xml
+func (gl *GL) BlendEquation(mode glbase.Enum) {
+ C.gl4_1compat_glBlendEquation(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendColor.xml
+func (gl *GL) BlendColor(red, green, blue, alpha float32) {
+ C.gl4_1compat_glBlendColor(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetCompressedTexImage.xml
+func (gl *GL) GetCompressedTexImage(target glbase.Enum, level int, img interface{}) {
+ var img_ptr unsafe.Pointer
+ var img_v = reflect.ValueOf(img)
+ if img != nil && img_v.Kind() != reflect.Slice {
+ panic("parameter img must be a slice")
+ }
+ if img != nil {
+ img_ptr = unsafe.Pointer(img_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1compat_glGetCompressedTexImage(gl.funcs, C.GLenum(target), C.GLint(level), img_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCompressedTexSubImage1D.xml
+func (gl *GL) CompressedTexSubImage1D(target glbase.Enum, level, xoffset, width int, format glbase.Enum, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1compat_glCompressedTexSubImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLsizei(width), C.GLenum(format), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCompressedTexSubImage2D.xml
+func (gl *GL) CompressedTexSubImage2D(target glbase.Enum, level, xoffset, yoffset, width, height int, format glbase.Enum, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1compat_glCompressedTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCompressedTexSubImage3D.xml
+func (gl *GL) CompressedTexSubImage3D(target glbase.Enum, level, xoffset, yoffset int, zoffset int32, width, height int, depth int32, format glbase.Enum, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1compat_glCompressedTexSubImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(zoffset), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLenum(format), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCompressedTexImage1D.xml
+func (gl *GL) CompressedTexImage1D(target glbase.Enum, level int, internalFormat glbase.Enum, width, border, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1compat_glCompressedTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLsizei(width), C.GLint(border), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCompressedTexImage2D.xml
+func (gl *GL) CompressedTexImage2D(target glbase.Enum, level int, internalFormat glbase.Enum, width, height, border, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1compat_glCompressedTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLint(border), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCompressedTexImage3D.xml
+func (gl *GL) CompressedTexImage3D(target glbase.Enum, level int, internalFormat glbase.Enum, width, height int, depth int32, border, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1compat_glCompressedTexImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLint(border), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSampleCoverage.xml
+func (gl *GL) SampleCoverage(value float32, invert bool) {
+ C.gl4_1compat_glSampleCoverage(gl.funcs, C.GLfloat(value), *(*C.GLboolean)(unsafe.Pointer(&invert)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glActiveTexture.xml
+func (gl *GL) ActiveTexture(texture glbase.Enum) {
+ C.gl4_1compat_glActiveTexture(gl.funcs, C.GLenum(texture))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPointParameteriv.xml
+func (gl *GL) PointParameteriv(pname glbase.Enum, params []int32) {
+ C.gl4_1compat_glPointParameteriv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPointParameteri.xml
+func (gl *GL) PointParameteri(pname glbase.Enum, param int32) {
+ C.gl4_1compat_glPointParameteri(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPointParameterfv.xml
+func (gl *GL) PointParameterfv(pname glbase.Enum, params []float32) {
+ C.gl4_1compat_glPointParameterfv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPointParameterf.xml
+func (gl *GL) PointParameterf(pname glbase.Enum, param float32) {
+ C.gl4_1compat_glPointParameterf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiDrawArrays.xml
+func (gl *GL) MultiDrawArrays(mode glbase.Enum, first, count []int, drawcount int32) {
+ C.gl4_1compat_glMultiDrawArrays(gl.funcs, C.GLenum(mode), (*C.GLint)(unsafe.Pointer(&first[0])), (*C.GLsizei)(unsafe.Pointer(&count[0])), C.GLsizei(drawcount))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendFuncSeparate.xml
+func (gl *GL) BlendFuncSeparate(sfactorRGB, dfactorRGB, sfactorAlpha, dfactorAlpha glbase.Enum) {
+ C.gl4_1compat_glBlendFuncSeparate(gl.funcs, C.GLenum(sfactorRGB), C.GLenum(dfactorRGB), C.GLenum(sfactorAlpha), C.GLenum(dfactorAlpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetBufferParameteriv.xml
+func (gl *GL) GetBufferParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl4_1compat_glGetBufferParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUnmapBuffer.xml
+func (gl *GL) UnmapBuffer(target glbase.Enum) bool {
+ glresult := C.gl4_1compat_glUnmapBuffer(gl.funcs, C.GLenum(target))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetBufferSubData.xml
+func (gl *GL) GetBufferSubData(target glbase.Enum, offset, size int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1compat_glGetBufferSubData(gl.funcs, C.GLenum(target), C.GLintptr(offset), C.GLsizeiptr(size), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBufferSubData.xml
+func (gl *GL) BufferSubData(target glbase.Enum, offset, size int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1compat_glBufferSubData(gl.funcs, C.GLenum(target), C.GLintptr(offset), C.GLsizeiptr(size), data_ptr)
+}
+
+// BufferData creates a new data store for the buffer object currently
+// bound to target. Any pre-existing data store is deleted. The new data
+// store is created with the specified size in bytes and usage. If data is
+// not nil, it must be a slice that is used to initialize the data store.
+// In that case the size parameter is ignored and the store size will match
+// the slice data size.
+//
+// In its initial state, the new data store is not mapped, it has a NULL
+// mapped pointer, and its mapped access is GL.READ_WRITE.
+//
+// The target constant must be one of GL.ARRAY_BUFFER, GL.COPY_READ_BUFFER,
+// GL.COPY_WRITE_BUFFER, GL.ELEMENT_ARRAY_BUFFER, GL.PIXEL_PACK_BUFFER,
+// GL.PIXEL_UNPACK_BUFFER, GL.TEXTURE_BUFFER, GL.TRANSFORM_FEEDBACK_BUFFER,
+// or GL.UNIFORM_BUFFER.
+//
+// The usage parameter is a hint to the GL implementation as to how a buffer
+// object's data store will be accessed. This enables the GL implementation
+// to make more intelligent decisions that may significantly impact buffer
+// object performance. It does not, however, constrain the actual usage of
+// the data store. usage can be broken down into two parts: first, the
+// frequency of access (modification and usage), and second, the nature of
+// that access.
+//
+// A usage frequency of STREAM and nature of DRAW is specified via the
+// constant GL.STREAM_DRAW, for example.
+//
+// The usage frequency of access may be one of:
+//
+// STREAM
+// The data store contents will be modified once and used at most a few times.
+//
+// STATIC
+// The data store contents will be modified once and used many times.
+//
+// DYNAMIC
+// The data store contents will be modified repeatedly and used many times.
+//
+// The usage nature of access may be one of:
+//
+// DRAW
+// The data store contents are modified by the application, and used as
+// the source for GL drawing and image specification commands.
+//
+// READ
+// The data store contents are modified by reading data from the GL,
+// and used to return that data when queried by the application.
+//
+// COPY
+// The data store contents are modified by reading data from the GL,
+// and used as the source for GL drawing and image specification
+// commands.
+//
+// Clients must align data elements consistent with the requirements of the
+// client platform, with an additional base-level requirement that an offset
+// within a buffer to a datum comprising N bytes be a multiple of N.
+//
+// Error GL.INVALID_ENUM is generated if target is not one of the accepted
+// buffer targets. GL.INVALID_ENUM is generated if usage is not
+// GL.STREAM_DRAW, GL.STREAM_READ, GL.STREAM_COPY, GL.STATIC_DRAW,
+// GL.STATIC_READ, GL.STATIC_COPY, GL.DYNAMIC_DRAW, GL.DYNAMIC_READ, or
+// GL.DYNAMIC_COPY. GL.INVALID_VALUE is generated if size is negative.
+// GL.INVALID_OPERATION is generated if the reserved buffer object name 0 is
+// bound to target. GL.OUT_OF_MEMORY is generated if the GL is unable to
+// create a data store with the specified size.
+func (gl *GL) BufferData(target glbase.Enum, size int, data interface{}, usage glbase.Enum) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ if data != nil {
+ size = int(data_v.Type().Size()) * data_v.Len()
+ }
+ C.gl4_1compat_glBufferData(gl.funcs, C.GLenum(target), C.GLsizeiptr(size), data_ptr, C.GLenum(usage))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsBuffer.xml
+func (gl *GL) IsBuffer(buffer glbase.Buffer) bool {
+ glresult := C.gl4_1compat_glIsBuffer(gl.funcs, C.GLuint(buffer))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// GenBuffers returns n buffer object names. There is no guarantee that
+// the names form a contiguous set of integers; however, it is guaranteed
+// that none of the returned names was in use immediately before the call to
+// GenBuffers.
+//
+// Buffer object names returned by a call to GenBuffers are not returned by
+// subsequent calls, unless they are first deleted with DeleteBuffers.
+//
+// No buffer objects are associated with the returned buffer object names
+// until they are first bound by calling BindBuffer.
+//
+// Error GL.INVALID_VALUE is generated if n is negative. GL.INVALID_OPERATION
+// is generated if GenBuffers is executed between the execution of Begin
+// and the corresponding execution of End.
+//
+// GenBuffers is available in GL version 1.5 or greater.
+func (gl *GL) GenBuffers(n int) []glbase.Buffer {
+ if n == 0 {
+ return nil
+ }
+ buffers := make([]glbase.Buffer, n)
+ C.gl4_1compat_glGenBuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&buffers[0])))
+ return buffers
+}
+
+// DeleteBuffers deletes the buffer objects whose names are stored in the
+// buffers slice.
+//
+// After a buffer object is deleted, it has no contents, and its name is free
+// for reuse (for example by GenBuffers). If a buffer object that is
+// currently bound is deleted, the binding reverts to 0 (the absence of any
+// buffer object, which reverts to client memory usage).
+//
+// DeleteBuffers silently ignores 0's and names that do not correspond to
+// existing buffer objects.
+//
+// Error GL.INVALID_VALUE is generated if n is negative. GL.INVALID_OPERATION
+// is generated if DeleteBuffers is executed between the execution of Begin
+// and the corresponding execution of End.
+//
+// DeleteBuffers is available in GL version 1.5 or greater.
+func (gl *GL) DeleteBuffers(buffers []glbase.Buffer) {
+ n := len(buffers)
+ if n == 0 {
+ return
+ }
+ C.gl4_1compat_glDeleteBuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&buffers[0])))
+}
+
+// BindBuffer creates or puts in use a named buffer object.
+// Calling BindBuffer with target set to GL.ARRAY_BUFFER,
+// GL.ELEMENT_ARRAY_BUFFER, GL.PIXEL_PACK_BUFFER or GL.PIXEL_UNPACK_BUFFER
+// and buffer set to the name of the new buffer object binds the buffer
+// object name to the target. When a buffer object is bound to a target, the
+// previous binding for that target is automatically broken.
+//
+// Buffer object names are unsigned integers. The value zero is reserved, but
+// there is no default buffer object for each buffer object target. Instead,
+// buffer set to zero effectively unbinds any buffer object previously bound,
+// and restores client memory usage for that buffer object target. Buffer
+// object names and the corresponding buffer object contents are local to the
+// shared display-list space (see XCreateContext) of the current GL rendering
+// context; two rendering contexts share buffer object names only if they
+// also share display lists.
+//
+// GenBuffers may be called to generate a set of new buffer object names.
+//
+// The state of a buffer object immediately after it is first bound is an
+// unmapped zero-sized memory buffer with GL.READ_WRITE access and
+// GL.STATIC_DRAW usage.
+//
+// While a non-zero buffer object name is bound, GL operations on the target
+// to which it is bound affect the bound buffer object, and queries of the
+// target to which it is bound return state from the bound buffer object.
+// While buffer object name zero is bound, as in the initial state, attempts
+// to modify or query state on the target to which it is bound generates an
+// GL.INVALID_OPERATION error.
+//
+// When vertex array pointer state is changed, for example by a call to
+// NormalPointer, the current buffer object binding (GL.ARRAY_BUFFER_BINDING)
+// is copied into the corresponding client state for the vertex array type
+// being changed, for example GL.NORMAL_ARRAY_BUFFER_BINDING. While a
+// non-zero buffer object is bound to the GL.ARRAY_BUFFER target, the vertex
+// array pointer parameter that is traditionally interpreted as a pointer to
+// client-side memory is instead interpreted as an offset within the buffer
+// object measured in basic machine units.
+//
+// While a non-zero buffer object is bound to the GL.ELEMENT_ARRAY_BUFFER
+// target, the indices parameter of DrawElements, DrawRangeElements, or
+// MultiDrawElements that is traditionally interpreted as a pointer to
+// client-side memory is instead interpreted as an offset within the buffer
+// object measured in basic machine units.
+//
+// While a non-zero buffer object is bound to the GL.PIXEL_PACK_BUFFER
+// target, the following commands are affected: GetCompressedTexImage,
+// GetConvolutionFilter, GetHistogram, GetMinmax, GetPixelMap,
+// GetPolygonStipple, GetSeparableFilter, GetTexImage, and ReadPixels. The
+// pointer parameter that is traditionally interpreted as a pointer to
+// client-side memory where the pixels are to be packed is instead
+// interpreted as an offset within the buffer object measured in basic
+// machine units.
+//
+// While a non-zero buffer object is bound to the GL.PIXEL_UNPACK_BUFFER
+// target, the following commands are affected: Bitmap, ColorSubTable,
+// ColorTable, CompressedTexImage1D, CompressedTexImage2D,
+// CompressedTexImage3D, CompressedTexSubImage1D, CompressedTexSubImage2D,
+// CompressedTexSubImage3D, ConvolutionFilter1D, ConvolutionFilter2D,
+// DrawPixels, PixelMap, PolygonStipple, SeparableFilter2D, TexImage1D,
+// TexImage2D, TexImage3D, TexSubImage1D, TexSubImage2D, and TexSubImage3D.
+// The pointer parameter that is traditionally interpreted as a pointer to
+// client-side memory from which the pixels are to be unpacked is instead
+// interpreted as an offset within the buffer object measured in basic
+// machine units.
+//
+// A buffer object binding created with BindBuffer remains active until a
+// different buffer object name is bound to the same target, or until the
+// bound buffer object is deleted with DeleteBuffers.
+//
+// Once created, a named buffer object may be re-bound to any target as often
+// as needed. However, the GL implementation may make choices about how to
+// optimize the storage of a buffer object based on its initial binding
+// target.
+//
+// Error GL.INVALID_ENUM is generated if target is not one of the allowable
+// values. GL.INVALID_OPERATION is generated if BindBuffer is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// BindBuffer is available in GL version 1.5 or greater.
+func (gl *GL) BindBuffer(target glbase.Enum, buffer glbase.Buffer) {
+ C.gl4_1compat_glBindBuffer(gl.funcs, C.GLenum(target), C.GLuint(buffer))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetQueryObjectuiv.xml
+func (gl *GL) GetQueryObjectuiv(id uint32, pname glbase.Enum, params []uint32) {
+ C.gl4_1compat_glGetQueryObjectuiv(gl.funcs, C.GLuint(id), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetQueryObjectiv.xml
+func (gl *GL) GetQueryObjectiv(id uint32, pname glbase.Enum, params []int32) {
+ C.gl4_1compat_glGetQueryObjectiv(gl.funcs, C.GLuint(id), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetQueryiv.xml
+func (gl *GL) GetQueryiv(target, pname glbase.Enum, params []int32) {
+ C.gl4_1compat_glGetQueryiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEndQuery.xml
+func (gl *GL) EndQuery(target glbase.Enum) {
+ C.gl4_1compat_glEndQuery(gl.funcs, C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBeginQuery.xml
+func (gl *GL) BeginQuery(target glbase.Enum, id uint32) {
+ C.gl4_1compat_glBeginQuery(gl.funcs, C.GLenum(target), C.GLuint(id))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsQuery.xml
+func (gl *GL) IsQuery(id uint32) bool {
+ glresult := C.gl4_1compat_glIsQuery(gl.funcs, C.GLuint(id))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDeleteQueries.xml
+func (gl *GL) DeleteQueries(n int, ids []uint32) {
+ C.gl4_1compat_glDeleteQueries(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&ids[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGenQueries.xml
+func (gl *GL) GenQueries(n int, ids []uint32) {
+ C.gl4_1compat_glGenQueries(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&ids[0])))
+}
+
+// VertexAttribPointer specifies the location and data format of the array
+// of generic vertex attributes at index to use when rendering. size
+// specifies the number of components per attribute and must be 1, 2, 3, or
+// 4. type specifies the data type of each component, and stride specifies
+// the byte stride from one attribute to the next, allowing vertices and
+// attributes to be packed into a single array or stored in separate arrays.
+// normalized indicates whether the values stored in an integer format are
+// to be mapped to the range [-1,1] (for signed values) or [0,1]
+// (for unsigned values) when they are accessed and converted to floating
+// point; otherwise, values will be converted to floats directly without
+// normalization. offset is a byte offset into the buffer object's data
+// store, which must be bound to the GL.ARRAY_BUFFER target with BindBuffer.
+//
+// The buffer object binding (GL.ARRAY_BUFFER_BINDING) is saved as
+// generic vertex attribute array client-side state
+// (GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING) for the provided index.
+//
+// To enable and disable a generic vertex attribute array, call
+// EnableVertexAttribArray and DisableVertexAttribArray with index. If
+// enabled, the generic vertex attribute array is used when DrawArrays or
+// DrawElements is called. Each generic vertex attribute array is initially
+// disabled.
+//
+// VertexAttribPointer is typically implemented on the client side.
+//
+// Error GL.INVALID_ENUM is generated if type is not an accepted value.
+// GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_VALUE is generated if size is not 1, 2,
+// 3, or 4. GL.INVALID_VALUE is generated if stride is negative.
+func (gl *GL) VertexAttribPointer(index glbase.Attrib, size int, gltype glbase.Enum, normalized bool, stride int, offset uintptr) {
+ offset_ptr := unsafe.Pointer(offset)
+ C.gl4_1compat_glVertexAttribPointer(gl.funcs, C.GLuint(index), C.GLint(size), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), C.GLsizei(stride), offset_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glValidateProgram.xml
+func (gl *GL) ValidateProgram(program glbase.Program) {
+ C.gl4_1compat_glValidateProgram(gl.funcs, C.GLuint(program))
+}
+
+// UniformMatrix4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix4fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(4*4) != 0 {
+ panic("invalid value length for UniformMatrix4fv")
+ }
+ count := len(value) / (4 * 4)
+ C.gl4_1compat_glUniformMatrix4fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix3fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(3*3) != 0 {
+ panic("invalid value length for UniformMatrix3fv")
+ }
+ count := len(value) / (3 * 3)
+ C.gl4_1compat_glUniformMatrix3fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix2fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(2*2) != 0 {
+ panic("invalid value length for UniformMatrix2fv")
+ }
+ count := len(value) / (2 * 2)
+ C.gl4_1compat_glUniformMatrix2fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform4iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%4 != 0 {
+ panic("invalid value length for Uniform4iv")
+ }
+ count := len(value) / 4
+ C.gl4_1compat_glUniform4iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform3iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform3iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%3 != 0 {
+ panic("invalid value length for Uniform3iv")
+ }
+ count := len(value) / 3
+ C.gl4_1compat_glUniform3iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform2iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform2iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%2 != 0 {
+ panic("invalid value length for Uniform2iv")
+ }
+ count := len(value) / 2
+ C.gl4_1compat_glUniform2iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform1iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform1iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ count := len(value)
+ C.gl4_1compat_glUniform1iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%4 != 0 {
+ panic("invalid value length for Uniform4fv")
+ }
+ count := len(value) / 4
+ C.gl4_1compat_glUniform4fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%3 != 0 {
+ panic("invalid value length for Uniform3fv")
+ }
+ count := len(value) / 3
+ C.gl4_1compat_glUniform3fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%2 != 0 {
+ panic("invalid value length for Uniform2fv")
+ }
+ count := len(value) / 2
+ C.gl4_1compat_glUniform2fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform1fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform1fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ count := len(value)
+ C.gl4_1compat_glUniform1fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform4i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4i(location glbase.Uniform, v0, v1, v2, v3 int32) {
+ C.gl4_1compat_glUniform4i(gl.funcs, C.GLint(location), C.GLint(v0), C.GLint(v1), C.GLint(v2), C.GLint(v3))
+}
+
+// Uniform3i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform3i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3i(location glbase.Uniform, v0, v1, v2 int32) {
+ C.gl4_1compat_glUniform3i(gl.funcs, C.GLint(location), C.GLint(v0), C.GLint(v1), C.GLint(v2))
+}
+
+// Uniform2i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform2i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2i(location glbase.Uniform, v0, v1 int32) {
+ C.gl4_1compat_glUniform2i(gl.funcs, C.GLint(location), C.GLint(v0), C.GLint(v1))
+}
+
+// Uniform1i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform1i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1i(location glbase.Uniform, v0 int32) {
+ C.gl4_1compat_glUniform1i(gl.funcs, C.GLint(location), C.GLint(v0))
+}
+
+// Uniform4f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform4f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4f(location glbase.Uniform, v0, v1, v2, v3 float32) {
+ C.gl4_1compat_glUniform4f(gl.funcs, C.GLint(location), C.GLfloat(v0), C.GLfloat(v1), C.GLfloat(v2), C.GLfloat(v3))
+}
+
+// Uniform3f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform3f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3f(location glbase.Uniform, v0, v1, v2 float32) {
+ C.gl4_1compat_glUniform3f(gl.funcs, C.GLint(location), C.GLfloat(v0), C.GLfloat(v1), C.GLfloat(v2))
+}
+
+// Uniform2f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform2f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2f(location glbase.Uniform, v0, v1 float32) {
+ C.gl4_1compat_glUniform2f(gl.funcs, C.GLint(location), C.GLfloat(v0), C.GLfloat(v1))
+}
+
+// Uniform1f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform1f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1f(location glbase.Uniform, v0 float32) {
+ C.gl4_1compat_glUniform1f(gl.funcs, C.GLint(location), C.GLfloat(v0))
+}
+
+// UseProgram installs the program object specified by program as part of
+// current rendering state. One or more executables are created in a program
+// object by successfully attaching shader objects to it with AttachShader,
+// successfully compiling the shader objects with CompileShader, and
+// successfully linking the program object with LinkProgram.
+//
+// A program object will contain an executable that will run on the vertex
+// processor if it contains one or more shader objects of type
+// GL.VERTEX_SHADER that have been successfully compiled and linked.
+// Similarly, a program object will contain an executable that will run on
+// the fragment processor if it contains one or more shader objects of type
+// GL.FRAGMENT_SHADER that have been successfully compiled and linked.
+//
+// Successfully installing an executable on a programmable processor will
+// cause the corresponding fixed functionality of OpenGL to be disabled.
+// Specifically, if an executable is installed on the vertex processor, the
+// OpenGL fixed functionality will be disabled as follows.
+//
+// - The modelview matrix is not applied to vertex coordinates.
+//
+// - The projection matrix is not applied to vertex coordinates.
+//
+// - The texture matrices are not applied to texture coordinates.
+//
+// - Normals are not transformed to eye coordinates.
+//
+// - Normals are not rescaled or normalized.
+//
+// - Normalization of GL.AUTO_NORMAL evaluated normals is not performed.
+//
+// - Texture coordinates are not generated automatically.
+//
+// - Per-vertex lighting is not performed.
+//
+// - Color material computations are not performed.
+//
+// - Color index lighting is not performed.
+//
+// - This list also applies when setting the current raster position.
+//
+// The executable that is installed on the vertex processor is expected to
+// implement any or all of the desired functionality from the preceding list.
+// Similarly, if an executable is installed on the fragment processor, the
+// OpenGL fixed functionality will be disabled as follows.
+//
+// - Texture environment and texture functions are not applied.
+//
+// - Texture application is not applied.
+//
+// - Color sum is not applied.
+//
+// - Fog is not applied.
+//
+// Again, the fragment shader that is installed is expected to implement any
+// or all of the desired functionality from the preceding list.
+//
+// While a program object is in use, applications are free to modify attached
+// shader objects, compile attached shader objects, attach additional shader
+// objects, and detach or delete shader objects. None of these operations
+// will affect the executables that are part of the current state. However,
+// relinking the program object that is currently in use will install the
+// program object as part of the current rendering state if the link
+// operation was successful (see LinkProgram). If the program object
+// currently in use is relinked unsuccessfully, its link status will be set
+// to GL.FALSE, but the executables and associated state will remain part of
+// the current state until a subsequent call to UseProgram removes it from
+// use. After it is removed from use, it cannot be made part of current state
+// until it has been successfully relinked.
+//
+// If program contains shader objects of type GL.VERTEX_SHADER but it does
+// not contain shader objects of type GL.FRAGMENT_SHADER, an executable will
+// be installed on the vertex processor, but fixed functionality will be used
+// for fragment processing. Similarly, if program contains shader objects of
+// type GL.FRAGMENT_SHADER but it does not contain shader objects of type
+// GL.VERTEX_SHADER, an executable will be installed on the fragment
+// processor, but fixed functionality will be used for vertex processing. If
+// program is 0, the programmable processors will be disabled, and fixed
+// functionality will be used for both vertex and fragment processing.
+//
+// While a program object is in use, the state that controls the disabled
+// fixed functionality may also be updated using the normal OpenGL calls.
+//
+// Like display lists and texture objects, the name space for program objects
+// may be shared across a set of contexts, as long as the server sides of the
+// contexts share the same address space. If the name space is shared across
+// contexts, any attached objects and the data associated with those attached
+// objects are shared as well.
+//
+// Applications are responsible for providing the synchronization across API
+// calls when objects are accessed from different execution threads.
+//
+// Error GL.INVALID_VALUE is generated if program is neither 0 nor a value
+// generated by OpenGL. GL.INVALID_OPERATION is generated if program is not
+// a program object. GL.INVALID_OPERATION is generated if program could not
+// be made part of current state. GL.INVALID_OPERATION is generated if
+// UseProgram is executed between the execution of Begin and the
+// corresponding execution of End.
+//
+// UseProgram is available in GL version 2.0 or greater.
+func (gl *GL) UseProgram(program glbase.Program) {
+ C.gl4_1compat_glUseProgram(gl.funcs, C.GLuint(program))
+}
+
+// ShaderSource sets the source code in shader to the provided source code. Any source
+// code previously stored in the shader object is completely replaced.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader is not a shader
+// object. GL.INVALID_VALUE is generated if count is less than 0.
+// GL.INVALID_OPERATION is generated if ShaderSource is executed between the
+// execution of Begin and the corresponding execution of End.
+//
+// ShaderSource is available in GL version 2.0 or greater.
+func (gl *GL) ShaderSource(shader glbase.Shader, source ...string) {
+ count := len(source)
+ length := make([]int32, count)
+ source_c := make([]unsafe.Pointer, count)
+ for i, src := range source {
+ length[i] = int32(len(src))
+ if len(src) > 0 {
+ source_c[i] = *(*unsafe.Pointer)(unsafe.Pointer(&src))
+ } else {
+ source_c[i] = unsafe.Pointer(uintptr(0))
+ }
+ }
+ C.gl4_1compat_glShaderSource(gl.funcs, C.GLuint(shader), C.GLsizei(count), (**C.GLchar)(unsafe.Pointer(&source_c[0])), (*C.GLint)(unsafe.Pointer(&length[0])))
+}
+
+// LinkProgram links the program object specified by program. If any shader
+// objects of type GL.VERTEX_SHADER are attached to program, they will be
+// used to create an executable that will run on the programmable vertex
+// processor. If any shader objects of type GL.FRAGMENT_SHADER are attached
+// to program, they will be used to create an executable that will run on the
+// programmable fragment processor.
+//
+// The status of the link operation will be stored as part of the program
+// object's state. This value will be set to GL.TRUE if the program object
+// was linked without errors and is ready for use, and GL.FALSE otherwise. It
+// can be queried by calling GetProgramiv with arguments program and
+// GL.LINK_STATUS.
+//
+// As a result of a successful link operation, all active user-defined
+// uniform variables belonging to program will be initialized to 0, and each
+// of the program object's active uniform variables will be assigned a
+// location that can be queried by calling GetUniformLocation. Also, any
+// active user-defined attribute variables that have not been bound to a
+// generic vertex attribute index will be bound to one at this time.
+//
+// Linking of a program object can fail for a number of reasons as specified
+// in the OpenGL Shading Language Specification. The following lists some of
+// the conditions that will cause a link error.
+//
+// - The number of active attribute variables supported by the
+// implementation has been exceeded.
+//
+// - The storage limit for uniform variables has been exceeded.
+//
+// - The number of active uniform variables supported by the implementation
+// has been exceeded.
+//
+// - The main function is missing for the vertex shader or the fragment
+// shader.
+//
+// - A varying variable actually used in the fragment shader is not
+// declared in the same way (or is not declared at all) in the vertex
+// shader.
+//
+// - A reference to a function or variable name is unresolved.
+//
+// - A shared global is declared with two different types or two different
+// initial values.
+//
+// - One or more of the attached shader objects has not been successfully
+// compiled.
+//
+// - Binding a generic attribute matrix caused some rows of the matrix to
+// fall outside the allowed maximum of GL.MAX_VERTEX_ATTRIBS.
+//
+// - Not enough contiguous vertex attribute slots could be found to bind
+// attribute matrices.
+//
+// When a program object has been successfully linked, the program object can
+// be made part of current state by calling UseProgram. Whether or not the
+// link operation was successful, the program object's information log will
+// be overwritten. The information log can be retrieved by calling
+// GetProgramInfoLog.
+//
+// LinkProgram will also install the generated executables as part of the
+// current rendering state if the link operation was successful and the
+// specified program object is already currently in use as a result of a
+// previous call to UseProgram. If the program object currently in use is
+// relinked unsuccessfully, its link status will be set to GL.FALSE , but the
+// executables and associated state will remain part of the current state
+// until a subsequent call to UseProgram removes it from use. After it is
+// removed from use, it cannot be made part of current state until it has
+// been successfully relinked.
+//
+// If program contains shader objects of type GL.VERTEX_SHADER but does not
+// contain shader objects of type GL.FRAGMENT_SHADER, the vertex shader will
+// be linked against the implicit interface for fixed functionality fragment
+// processing. Similarly, if program contains shader objects of type
+// GL.FRAGMENT_SHADER but it does not contain shader objects of type
+// GL.VERTEX_SHADER, the fragment shader will be linked against the implicit
+// interface for fixed functionality vertex processing.
+//
+// The program object's information log is updated and the program is
+// generated at the time of the link operation. After the link operation,
+// applications are free to modify attached shader objects, compile attached
+// shader objects, detach shader objects, delete shader objects, and attach
+// additional shader objects. None of these operations affects the
+// information log or the program that is part of the program object.
+//
+// If the link operation is unsuccessful, any information about a previous
+// link operation on program is lost (a failed link does not restore the
+// old state of program). Certain information can still be retrieved
+// from program even after an unsuccessful link operation. See for instance
+// GetActiveAttrib and GetActiveUniform.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program
+// object. GL.INVALID_OPERATION is generated if LinkProgram is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// LinkProgram is available in GL version 2.0 or greater.
+func (gl *GL) LinkProgram(program glbase.Program) {
+ C.gl4_1compat_glLinkProgram(gl.funcs, C.GLuint(program))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsShader.xml
+func (gl *GL) IsShader(shader glbase.Shader) bool {
+ glresult := C.gl4_1compat_glIsShader(gl.funcs, C.GLuint(shader))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsProgram.xml
+func (gl *GL) IsProgram(program glbase.Program) bool {
+ glresult := C.gl4_1compat_glIsProgram(gl.funcs, C.GLuint(program))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// GetVertexAttribiv returns in params the value of a generic vertex attribute
+// parameter. The generic vertex attribute to be queried is specified by
+// index, and the parameter to be queried is specified by pname.
+//
+// The accepted parameter names are as follows:
+//
+// GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING
+// params returns a single value, the name of the buffer object
+// currently bound to the binding point corresponding to generic vertex
+// attribute array index. If no buffer object is bound, 0 is returned.
+// The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_ENABLED
+// params returns a single value that is non-zero (true) if the vertex
+// attribute array for index is enabled and 0 (false) if it is
+// disabled. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_SIZE
+// params returns a single value, the size of the vertex attribute
+// array for index. The size is the number of values for each element
+// of the vertex attribute array, and it will be 1, 2, 3, or 4. The
+// initial value is 4.
+//
+// GL.VERTEX_ATTRIB_ARRAY_STRIDE
+// params returns a single value, the array stride for (number of bytes
+// between successive elements in) the vertex attribute array for
+// index. A value of 0 indicates that the array elements are stored
+// sequentially in memory. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_TYPE
+// params returns a single value, a symbolic constant indicating the
+// array type for the vertex attribute array for index. Possible values
+// are GL.BYTE, GL.UNSIGNED_BYTE, GL.SHORT, GL.UNSIGNED_SHORT, GL.INT,
+// GL.UNSIGNED_INT, GL.FLOAT, and GL.DOUBLE. The initial value is
+// GL.FLOAT.
+//
+// GL.VERTEX_ATTRIB_ARRAY_NORMALIZED
+// params returns a single value that is non-zero (true) if fixed-point
+// data types for the vertex attribute array indicated by index are
+// normalized when they are converted to floating point, and 0 (false)
+// otherwise. The initial value is 0.
+//
+// GL.CURRENT_VERTEX_ATTRIB
+// params returns four values that represent the current value for the
+// generic vertex attribute specified by index. Generic vertex
+// attribute 0 is unique in that it has no current state, so an error
+// will be generated if index is 0. The initial value for all other
+// generic vertex attributes is (0,0,0,1).
+//
+// All of the parameters except GL.CURRENT_VERTEX_ATTRIB represent
+// client-side state.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_ENUM is generated if pname is not an
+// accepted value. GL.INVALID_OPERATION is generated if index is 0 and pname
+// is GL.CURRENT_VERTEX_ATTRIB.
+//
+// GetVertexAttribiv is available in GL version 2.0 or greater.
+func (gl *GL) GetVertexAttribiv(index glbase.Attrib, pname glbase.Enum, params []int32) {
+ var params_c [4]int32
+ C.gl4_1compat_glGetVertexAttribiv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetVertexAttribfv returns in params the value of a generic vertex attribute
+// parameter. The generic vertex attribute to be queried is specified by
+// index, and the parameter to be queried is specified by pname.
+//
+// The accepted parameter names are as follows:
+//
+// GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING
+// params returns a single value, the name of the buffer object
+// currently bound to the binding point corresponding to generic vertex
+// attribute array index. If no buffer object is bound, 0 is returned.
+// The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_ENABLED
+// params returns a single value that is non-zero (true) if the vertex
+// attribute array for index is enabled and 0 (false) if it is
+// disabled. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_SIZE
+// params returns a single value, the size of the vertex attribute
+// array for index. The size is the number of values for each element
+// of the vertex attribute array, and it will be 1, 2, 3, or 4. The
+// initial value is 4.
+//
+// GL.VERTEX_ATTRIB_ARRAY_STRIDE
+// params returns a single value, the array stride for (number of bytes
+// between successive elements in) the vertex attribute array for
+// index. A value of 0 indicates that the array elements are stored
+// sequentially in memory. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_TYPE
+// params returns a single value, a symbolic constant indicating the
+// array type for the vertex attribute array for index. Possible values
+// are GL.BYTE, GL.UNSIGNED_BYTE, GL.SHORT, GL.UNSIGNED_SHORT, GL.INT,
+// GL.UNSIGNED_INT, GL.FLOAT, and GL.DOUBLE. The initial value is
+// GL.FLOAT.
+//
+// GL.VERTEX_ATTRIB_ARRAY_NORMALIZED
+// params returns a single value that is non-zero (true) if fixed-point
+// data types for the vertex attribute array indicated by index are
+// normalized when they are converted to floating point, and 0 (false)
+// otherwise. The initial value is 0.
+//
+// GL.CURRENT_VERTEX_ATTRIB
+// params returns four values that represent the current value for the
+// generic vertex attribute specified by index. Generic vertex
+// attribute 0 is unique in that it has no current state, so an error
+// will be generated if index is 0. The initial value for all other
+// generic vertex attributes is (0,0,0,1).
+//
+// All of the parameters except GL.CURRENT_VERTEX_ATTRIB represent
+// client-side state.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_ENUM is generated if pname is not an
+// accepted value. GL.INVALID_OPERATION is generated if index is 0 and pname
+// is GL.CURRENT_VERTEX_ATTRIB.
+//
+// GetVertexAttribfv is available in GL version 2.0 or greater.
+func (gl *GL) GetVertexAttribfv(index glbase.Attrib, pname glbase.Enum, params []float32) {
+ var params_c [4]float32
+ C.gl4_1compat_glGetVertexAttribfv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetVertexAttribdv returns in params the value of a generic vertex attribute
+// parameter. The generic vertex attribute to be queried is specified by
+// index, and the parameter to be queried is specified by pname.
+//
+// The accepted parameter names are as follows:
+//
+// GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING
+// params returns a single value, the name of the buffer object
+// currently bound to the binding point corresponding to generic vertex
+// attribute array index. If no buffer object is bound, 0 is returned.
+// The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_ENABLED
+// params returns a single value that is non-zero (true) if the vertex
+// attribute array for index is enabled and 0 (false) if it is
+// disabled. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_SIZE
+// params returns a single value, the size of the vertex attribute
+// array for index. The size is the number of values for each element
+// of the vertex attribute array, and it will be 1, 2, 3, or 4. The
+// initial value is 4.
+//
+// GL.VERTEX_ATTRIB_ARRAY_STRIDE
+// params returns a single value, the array stride for (number of bytes
+// between successive elements in) the vertex attribute array for
+// index. A value of 0 indicates that the array elements are stored
+// sequentially in memory. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_TYPE
+// params returns a single value, a symbolic constant indicating the
+// array type for the vertex attribute array for index. Possible values
+// are GL.BYTE, GL.UNSIGNED_BYTE, GL.SHORT, GL.UNSIGNED_SHORT, GL.INT,
+// GL.UNSIGNED_INT, GL.FLOAT, and GL.DOUBLE. The initial value is
+// GL.FLOAT.
+//
+// GL.VERTEX_ATTRIB_ARRAY_NORMALIZED
+// params returns a single value that is non-zero (true) if fixed-point
+// data types for the vertex attribute array indicated by index are
+// normalized when they are converted to floating point, and 0 (false)
+// otherwise. The initial value is 0.
+//
+// GL.CURRENT_VERTEX_ATTRIB
+// params returns four values that represent the current value for the
+// generic vertex attribute specified by index. Generic vertex
+// attribute 0 is unique in that it has no current state, so an error
+// will be generated if index is 0. The initial value for all other
+// generic vertex attributes is (0,0,0,1).
+//
+// All of the parameters except GL.CURRENT_VERTEX_ATTRIB represent
+// client-side state.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_ENUM is generated if pname is not an
+// accepted value. GL.INVALID_OPERATION is generated if index is 0 and pname
+// is GL.CURRENT_VERTEX_ATTRIB.
+//
+// GetVertexAttribdv is available in GL version 2.0 or greater.
+func (gl *GL) GetVertexAttribdv(index glbase.Attrib, pname glbase.Enum, params []float64) {
+ var params_c [4]float64
+ C.gl4_1compat_glGetVertexAttribdv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetUniformiv returns in params the value of the specified uniform
+// variable. The type of the uniform variable specified by location
+// determines the number of values returned. If the uniform variable is
+// defined in the shader as a boolean, int, or float, a single value will be
+// returned. If it is defined as a vec2, ivec2, or bvec2, two values will be
+// returned. If it is defined as a vec3, ivec3, or bvec3, three values will
+// be returned, and so on. To query values stored in uniform variables
+// declared as arrays, call GetUniformiv for each element of the array. To
+// query values stored in uniform variables declared as structures, call
+// GetUniformiv for each field in the structure. The values for uniform
+// variables declared as a matrix will be returned in column major order.
+//
+// The locations assigned to uniform variables are not known until the
+// program object is linked. After linking has occurred, the command
+// GetUniformLocation can be used to obtain the location of a uniform
+// variable. This location value can then be passed to GetUniformiv in order
+// to query the current value of the uniform variable. After a program object
+// has been linked successfully, the index values for uniform variables
+// remain fixed until the next link command occurs. The uniform variable
+// values can only be queried after a link if the link was successful.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program
+// object. GL.INVALID_OPERATION is generated if program has not been
+// successfully linked. GL.INVALID_OPERATION is generated if location does
+// not correspond to a valid uniform variable location for the specified
+// program object. GL.INVALID_OPERATION is generated if GetUniformiv is
+// executed between the execution of Begin and the corresponding execution of
+// End.
+//
+// GetUniformiv is available in GL version 2.0 or greater.
+func (gl *GL) GetUniformiv(program glbase.Program, location glbase.Uniform, params []int32) {
+ var params_c [4]int32
+ C.gl4_1compat_glGetUniformiv(gl.funcs, C.GLuint(program), C.GLint(location), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetUniformfv returns in params the value of the specified uniform
+// variable. The type of the uniform variable specified by location
+// determines the number of values returned. If the uniform variable is
+// defined in the shader as a boolean, int, or float, a single value will be
+// returned. If it is defined as a vec2, ivec2, or bvec2, two values will be
+// returned. If it is defined as a vec3, ivec3, or bvec3, three values will
+// be returned, and so on. To query values stored in uniform variables
+// declared as arrays, call GetUniformfv for each element of the array. To
+// query values stored in uniform variables declared as structures, call
+// GetUniformfv for each field in the structure. The values for uniform
+// variables declared as a matrix will be returned in column major order.
+//
+// The locations assigned to uniform variables are not known until the
+// program object is linked. After linking has occurred, the command
+// GetUniformLocation can be used to obtain the location of a uniform
+// variable. This location value can then be passed to GetUniformfv in order
+// to query the current value of the uniform variable. After a program object
+// has been linked successfully, the index values for uniform variables
+// remain fixed until the next link command occurs. The uniform variable
+// values can only be queried after a link if the link was successful.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program
+// object. GL.INVALID_OPERATION is generated if program has not been
+// successfully linked. GL.INVALID_OPERATION is generated if location does
+// not correspond to a valid uniform variable location for the specified
+// program object. GL.INVALID_OPERATION is generated if GetUniformfv is
+// executed between the execution of Begin and the corresponding execution of
+// End.
+//
+// GetUniformfv is available in GL version 2.0 or greater.
+func (gl *GL) GetUniformfv(program glbase.Program, location glbase.Uniform, params []float32) {
+ var params_c [4]float32
+ C.gl4_1compat_glGetUniformfv(gl.funcs, C.GLuint(program), C.GLint(location), (*C.GLfloat)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetUniformLocation returns an integer that represents the location of a
+// specific uniform variable within a program object. name must be an active
+// uniform variable name in program that is not a structure, an array of
+// structures, or a subcomponent of a vector or a matrix. This function
+// returns -1 if name does not correspond to an active uniform variable in
+// program or if name starts with the reserved prefix "gl_".
+//
+// Uniform variables that are structures or arrays of structures may be
+// queried by calling GetUniformLocation for each field within the
+// structure. The array element operator "[]" and the structure field
+// operator "." may be used in name in order to select elements within an
+// array or fields within a structure. The result of using these operators is
+// not allowed to be another structure, an array of structures, or a
+// subcomponent of a vector or a matrix. Except if the last part of name
+// indicates a uniform variable array, the location of the first element of
+// an array can be retrieved by using the name of the array, or by using the
+// name appended by "[0]".
+//
+// The actual locations assigned to uniform variables are not known until the
+// program object is linked successfully. After linking has occurred, the
+// command GetUniformLocation can be used to obtain the location of a
+// uniform variable. This location value can then be passed to Uniform to
+// set the value of the uniform variable or to GetUniform in order to query
+// the current value of the uniform variable. After a program object has been
+// linked successfully, the index values for uniform variables remain fixed
+// until the next link command occurs. Uniform variable locations and values
+// can only be queried after a link if the link was successful.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program object.
+// GL.INVALID_OPERATION is generated if program has not been successfully
+// linked. GL.INVALID_OPERATION is generated if GetUniformLocation is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// GetUniformLocation is available in GL version 2.0 or greater.
+func (gl *GL) GetUniformLocation(program glbase.Program, name string) glbase.Uniform {
+ name_cstr := C.CString(name)
+ glresult := C.gl4_1compat_glGetUniformLocation(gl.funcs, C.GLuint(program), (*C.GLchar)(name_cstr))
+ C.free(unsafe.Pointer(name_cstr))
+ return glbase.Uniform(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetShaderSource.xml
+func (gl *GL) GetShaderSource(shader glbase.Shader, bufSize int32, length []int32, source []byte) {
+ C.gl4_1compat_glGetShaderSource(gl.funcs, C.GLuint(shader), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&source[0])))
+}
+
+// GetShaderInfoLog returns the information log for the specified shader
+// object. The information log for a shader object is modified when the
+// shader is compiled.
+//
+// The information log for a shader object is a string that may contain
+// diagnostic messages, warning messages, and other information about the
+// last compile operation. When a shader object is created, its information
+// log will be a string of length 0, and the size of the current log can be
+// obtained by calling GetShaderiv with the value GL.INFO_LOG_LENGTH.
+//
+// The information log for a shader object is the OpenGL implementer's
+// primary mechanism for conveying information about the compilation process.
+// Therefore, the information log can be helpful to application developers
+// during the development process, even when compilation is successful.
+// Application developers should not expect different OpenGL implementations
+// to produce identical information logs.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader is not a shader
+// object. GL.INVALID_VALUE is generated if maxLength is less than 0.
+// GL.INVALID_OPERATION is generated if GetShaderInfoLog is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// GetShaderInfoLog is available in GL version 2.0 or greater.
+func (gl *GL) GetShaderInfoLog(shader glbase.Shader) []byte {
+ var params [1]int32
+ var length int32
+ gl.GetShaderiv(shader, INFO_LOG_LENGTH, params[:])
+ bufSize := params[0]
+ infoLog := make([]byte, int(bufSize))
+ C.gl4_1compat_glGetShaderInfoLog(gl.funcs, C.GLuint(shader), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length)), (*C.GLchar)(unsafe.Pointer(&infoLog[0])))
+ return infoLog
+}
+
+// GetShaderiv GetShader returns in params the value of a parameter for a specific
+// shader object. The following parameters are defined:
+//
+// GL.SHADER_TYPE
+// params returns GL.VERTEX_SHADER if shader is a vertex shader object,
+// and GL.FRAGMENT_SHADER if shader is a fragment shader object.
+//
+// GL.DELETE_STATUS
+// params returns GL.TRUE if shader is currently flagged for deletion,
+// and GL.FALSE otherwise.
+//
+// GL.COMPILE_STATUS
+// params returns GL.TRUE if the last compile operation on shader was
+// successful, and GL.FALSE otherwise.
+//
+// GL.INFO_LOG_LENGTH
+// params returns the number of characters in the information log for
+// shader including the null termination character (the size of the
+// character buffer required to store the information log). If shader has
+// no information log, a value of 0 is returned.
+//
+// GL.SHADER_SOURCE_LENGTH
+// params returns the length of the concatenation of the source strings
+// that make up the shader source for the shader, including the null
+// termination character. (the size of the character buffer
+// required to store the shader source). If no source code exists, 0 is
+// returned.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader does not refer to a
+// shader object. GL.INVALID_ENUM is generated if pname is not an accepted
+// value. GL.INVALID_OPERATION is generated if GetShader is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// GetShaderiv is available in GL version 2.0 or greater.
+func (gl *GL) GetShaderiv(shader glbase.Shader, pname glbase.Enum, params []int32) {
+ var params_c [4]int32
+ C.gl4_1compat_glGetShaderiv(gl.funcs, C.GLuint(shader), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetProgramInfoLog returns the information log for the specified program
+// object. The information log for a program object is modified when the
+// program object is linked or validated.
+//
+// The information log for a program object is either an empty string, or a
+// string containing information about the last link operation, or a string
+// containing information about the last validation operation. It may contain
+// diagnostic messages, warning messages, and other information. When a
+// program object is created, its information log will be a string of length
+// 0, and the size of the current log can be obtained by calling GetProgramiv
+// with the value GL.INFO_LOG_LENGTH.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated
+// by OpenGL. GL.INVALID_OPERATION is generated if program is not a
+// program object.
+func (gl *GL) GetProgramInfoLog(program glbase.Program) []byte {
+ var params [1]int32
+ var length int32
+ gl.GetProgramiv(program, INFO_LOG_LENGTH, params[:])
+ bufSize := params[0]
+ infoLog := make([]byte, int(bufSize))
+ C.gl4_1compat_glGetProgramInfoLog(gl.funcs, C.GLuint(program), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length)), (*C.GLchar)(unsafe.Pointer(&infoLog[0])))
+ return infoLog
+}
+
+// GetProgramiv returns in params the value of a parameter for a specific
+// program object. The following parameters are defined:
+//
+// GL.DELETE_STATUS
+// params returns GL.TRUE if program is currently flagged for deletion,
+// and GL.FALSE otherwise.
+//
+// GL.LINK_STATUS
+// params returns GL.TRUE if the last link operation on program was
+// successful, and GL.FALSE otherwise.
+//
+// GL.VALIDATE_STATUS
+// params returns GL.TRUE or if the last validation operation on
+// program was successful, and GL.FALSE otherwise.
+//
+// GL.INFO_LOG_LENGTH
+// params returns the number of characters in the information log for
+// program including the null termination character (the size of
+// the character buffer required to store the information log). If
+// program has no information log, a value of 0 is returned.
+//
+// GL.ATTACHED_SHADERS
+// params returns the number of shader objects attached to program.
+//
+// GL.ACTIVE_ATTRIBUTES
+// params returns the number of active attribute variables for program.
+//
+// GL.ACTIVE_ATTRIBUTE_MAX_LENGTH
+// params returns the length of the longest active attribute name for
+// program, including the null termination character (the size of
+// the character buffer required to store the longest attribute name).
+// If no active attributes exist, 0 is returned.
+//
+// GL.ACTIVE_UNIFORMS
+// params returns the number of active uniform variables for program.
+//
+// GL.ACTIVE_UNIFORM_MAX_LENGTH
+// params returns the length of the longest active uniform variable
+// name for program, including the null termination character (i.e.,
+// the size of the character buffer required to store the longest
+// uniform variable name). If no active uniform variables exist, 0 is
+// returned.
+//
+// GL.TRANSFORM_FEEDBACK_BUFFER_MODE
+// params returns a symbolic constant indicating the buffer mode used
+// when transform feedback is active. This may be GL.SEPARATE_ATTRIBS
+// or GL.INTERLEAVED_ATTRIBS.
+//
+// GL.TRANSFORM_FEEDBACK_VARYINGS
+// params returns the number of varying variables to capture in transform
+// feedback mode for the program.
+//
+// GL.TRANSFORM_FEEDBACK_VARYING_MAX_LENGTH
+// params returns the length of the longest variable name to be used for
+// transform feedback, including the null-terminator.
+//
+// GL.GEOMETRY_VERTICES_OUT
+// params returns the maximum number of vertices that the geometry shader in
+// program will output.
+//
+// GL.GEOMETRY_INPUT_TYPE
+// params returns a symbolic constant indicating the primitive type accepted
+// as input to the geometry shader contained in program.
+//
+// GL.GEOMETRY_OUTPUT_TYPE
+// params returns a symbolic constant indicating the primitive type that will
+// be output by the geometry shader contained in program.
+//
+// GL.ACTIVE_UNIFORM_BLOCKS and GL.ACTIVE_UNIFORM_BLOCK_MAX_NAME_LENGTH are
+// available only if the GL version 3.1 or greater.
+//
+// GL.GEOMETRY_VERTICES_OUT, GL.GEOMETRY_INPUT_TYPE and
+// GL.GEOMETRY_OUTPUT_TYPE are accepted only if the GL version is 3.2 or
+// greater.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program does not refer to a
+// program object. GL.INVALID_OPERATION is generated if pname is
+// GL.GEOMETRY_VERTICES_OUT, GL.GEOMETRY_INPUT_TYPE, or
+// GL.GEOMETRY_OUTPUT_TYPE, and program does not contain a geometry shader.
+// GL.INVALID_ENUM is generated if pname is not an accepted value.
+func (gl *GL) GetProgramiv(program glbase.Program, pname glbase.Enum, params []int32) {
+ var params_c [4]int32
+ C.gl4_1compat_glGetProgramiv(gl.funcs, C.GLuint(program), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetAttribLocation queries the previously linked program object specified
+// by program for the attribute variable specified by name and returns the
+// index of the generic vertex attribute that is bound to that attribute
+// variable. If name is a matrix attribute variable, the index of the first
+// column of the matrix is returned. If the named attribute variable is not
+// an active attribute in the specified program object or if name starts with
+// the reserved prefix "gl_", a value of -1 is returned.
+//
+// The association between an attribute variable name and a generic attribute
+// index can be specified at any time by calling BindAttribLocation.
+// Attribute bindings do not go into effect until LinkProgram is called.
+// After a program object has been linked successfully, the index values for
+// attribute variables remain fixed until the next link command occurs. The
+// attribute values can only be queried after a link if the link was
+// successful. GetAttribLocation returns the binding that actually went
+// into effect the last time LinkProgram was called for the specified
+// program object. Attribute bindings that have been specified since the last
+// link operation are not returned by GetAttribLocation.
+//
+// Error GL_INVALID_OPERATION is generated if program is not a value
+// generated by OpenGL. GL_INVALID_OPERATION is generated if program is not
+// a program object. GL_INVALID_OPERATION is generated if program has not
+// been successfully linked. GL_INVALID_OPERATION is generated if
+// GetAttribLocation is executed between the execution of Begin and the
+// corresponding execution of End.
+//
+// GetAttribLocation is available in GL version 2.0 or greater.
+func (gl *GL) GetAttribLocation(program glbase.Program, name string) glbase.Attrib {
+ name_cstr := C.CString(name)
+ glresult := C.gl4_1compat_glGetAttribLocation(gl.funcs, C.GLuint(program), (*C.GLchar)(name_cstr))
+ C.free(unsafe.Pointer(name_cstr))
+ return glbase.Attrib(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetAttachedShaders.xml
+func (gl *GL) GetAttachedShaders(program glbase.Program, maxCount int32, count []int, obj []uint32) {
+ C.gl4_1compat_glGetAttachedShaders(gl.funcs, C.GLuint(program), C.GLsizei(maxCount), (*C.GLsizei)(unsafe.Pointer(&count[0])), (*C.GLuint)(unsafe.Pointer(&obj[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveUniform.xml
+func (gl *GL) GetActiveUniform(program glbase.Program, index uint32, bufSize int32, length []int32, size []int, gltype []glbase.Enum, name []byte) {
+ C.gl4_1compat_glGetActiveUniform(gl.funcs, C.GLuint(program), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLint)(unsafe.Pointer(&size[0])), (*C.GLenum)(unsafe.Pointer(&gltype[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveAttrib.xml
+func (gl *GL) GetActiveAttrib(program glbase.Program, index glbase.Attrib, bufSize int32, length []int32, size []int, gltype []glbase.Enum, name []byte) {
+ C.gl4_1compat_glGetActiveAttrib(gl.funcs, C.GLuint(program), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLint)(unsafe.Pointer(&size[0])), (*C.GLenum)(unsafe.Pointer(&gltype[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEnableVertexAttribArray.xml
+func (gl *GL) EnableVertexAttribArray(index glbase.Attrib) {
+ C.gl4_1compat_glEnableVertexAttribArray(gl.funcs, C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDisableVertexAttribArray.xml
+func (gl *GL) DisableVertexAttribArray(index glbase.Attrib) {
+ C.gl4_1compat_glDisableVertexAttribArray(gl.funcs, C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDetachShader.xml
+func (gl *GL) DetachShader(program glbase.Program, shader glbase.Shader) {
+ C.gl4_1compat_glDetachShader(gl.funcs, C.GLuint(program), C.GLuint(shader))
+}
+
+// DeleteShader frees the memory and invalidates the name associated with
+// the shader object specified by shader. This command effectively undoes the
+// effects of a call to CreateShader.
+//
+// If a shader object to be deleted is attached to a program object, it will
+// be flagged for deletion, but it will not be deleted until it is no longer
+// attached to any program object, for any rendering context (it must
+// be detached from wherever it was attached before it will be deleted). A
+// value of 0 for shader will be silently ignored.
+//
+// To determine whether an object has been flagged for deletion, call
+// GetShader with arguments shader and GL.DELETE_STATUS.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL.
+//
+// DeleteShader is available in GL version 2.0 or greater.
+func (gl *GL) DeleteShader(shader glbase.Shader) {
+ C.gl4_1compat_glDeleteShader(gl.funcs, C.GLuint(shader))
+}
+
+// DeleteProgram frees the memory and invalidates the name associated with
+// the program object specified by program. This command effectively undoes
+// the effects of a call to CreateProgram.
+//
+// If a program object is in use as part of current rendering state, it will
+// be flagged for deletion, but it will not be deleted until it is no longer
+// part of current state for any rendering context. If a program object to be
+// deleted has shader objects attached to it, those shader objects will be
+// automatically detached but not deleted unless they have already been
+// flagged for deletion by a previous call to DeleteShader. A value of 0
+// for program will be silently ignored.
+//
+// To determine whether a program object has been flagged for deletion, call
+// GetProgram with arguments program and GL.DELETE_STATUS.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL.
+//
+// DeleteProgram is available in GL version 2.0 or greater.
+func (gl *GL) DeleteProgram(program glbase.Program) {
+ C.gl4_1compat_glDeleteProgram(gl.funcs, C.GLuint(program))
+}
+
+// CreateShader creates an empty shader object and returns a non-zero value
+// by which it can be referenced. A shader object is used to maintain the
+// source code strings that define a shader. shaderType indicates the type of
+// shader to be created.
+//
+// Two types of shaders are supported. A shader of type GL.VERTEX_SHADER is a
+// shader that is intended to run on the programmable vertex processor and
+// replace the fixed functionality vertex processing in OpenGL. A shader of
+// type GL.FRAGMENT_SHADER is a shader that is intended to run on the
+// programmable fragment processor and replace the fixed functionality
+// fragment processing in OpenGL.
+//
+// When created, a shader object's GL.SHADER_TYPE parameter is set to either
+// GL.VERTEX_SHADER or GL.FRAGMENT_SHADER, depending on the value of
+// shaderType.
+//
+// Like display lists and texture objects, the name space for shader objects
+// may be shared across a set of contexts, as long as the server sides of the
+// contexts share the same address space. If the name space is shared across
+// contexts, any attached objects and the data associated with those attached
+// objects are shared as well.
+//
+// This function returns 0 if an error occurs creating the shader object.
+//
+// Error GL.INVALID_ENUM is generated if shaderType is not an accepted value.
+// GL.INVALID_OPERATION is generated if CreateShader is executed between the
+// execution of Begin and the corresponding execution of End.
+//
+// CreateShader is available in GL version 2.0 or greater.
+func (gl *GL) CreateShader(gltype glbase.Enum) glbase.Shader {
+ glresult := C.gl4_1compat_glCreateShader(gl.funcs, C.GLenum(gltype))
+ return glbase.Shader(glresult)
+}
+
+// CreateProgram creates an empty program object and returns a non-zero
+// value by which it can be referenced. A program object is an object to
+// which shader objects can be attached. This provides a mechanism to specify
+// the shader objects that will be linked to create a program. It also
+// provides a means for checking the compatibility of the shaders that will
+// be used to create a program (for instance, checking the compatibility
+// between a vertex shader and a fragment shader). When no longer needed as
+// part of a program object, shader objects can be detached.
+//
+// One or more executables are created in a program object by successfully
+// attaching shader objects to it with AttachShader, successfully compiling
+// the shader objects with CompileShader, and successfully linking the
+// program object with LinkProgram. These executables are made part of
+// current state when UseProgram is called. Program objects can be deleted
+// by calling DeleteProgram. The memory associated with the program object
+// will be deleted when it is no longer part of current rendering state for
+// any context.
+//
+// Like display lists and texture objects, the name space for program objects
+// may be shared across a set of contexts, as long as the server sides of the
+// contexts share the same address space. If the name space is shared across
+// contexts, any attached objects and the data associated with those attached
+// objects are shared as well.
+//
+// Applications are responsible for providing the synchronization across API
+// calls when objects are accessed from different execution threads.
+//
+// This function returns 0 if an error occurs creating the program object.
+//
+// Error GL.INVALID_OPERATION is generated if CreateProgram is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// CreateProgram is available in GL version 2.0 or greater.
+func (gl *GL) CreateProgram() glbase.Program {
+ glresult := C.gl4_1compat_glCreateProgram(gl.funcs)
+ return glbase.Program(glresult)
+}
+
+// CompileShader compiles the source code strings that have been stored in
+// the shader object specified by shader.
+//
+// The compilation status will be stored as part of the shader object's
+// state. This value will be set to GL.TRUE if the shader was compiled without
+// errors and is ready for use, and GL.FALSE otherwise. It can be queried by
+// calling GetShaderiv with arguments shader and GL.COMPILE_STATUS.
+//
+// Compilation of a shader can fail for a number of reasons as specified by
+// the OpenGL Shading Language Specification. Whether or not the compilation
+// was successful, information about the compilation can be obtained from the
+// shader object's information log by calling GetShaderInfoLog.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader is not a shader
+// object. GL.INVALID_OPERATION is generated if CompileShader is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// CompileShader is available in GL version 2.0 or greater.
+func (gl *GL) CompileShader(shader glbase.Shader) {
+ C.gl4_1compat_glCompileShader(gl.funcs, C.GLuint(shader))
+}
+
+// BindAttribLocation associates a user-defined attribute variable in the program
+// object specified by program with a generic vertex attribute index. The name
+// parameter specifies the name of the vertex shader attribute variable to
+// which index is to be bound. When program is made part of the current state,
+// values provided via the generic vertex attribute index will modify the
+// value of the user-defined attribute variable specified by name.
+//
+// If name refers to a matrix attribute variable, index refers to the first
+// column of the matrix. Other matrix columns are then automatically bound to
+// locations index+1 for a matrix of type mat2; index+1 and index+2 for a
+// matrix of type mat3; and index+1, index+2, and index+3 for a matrix of
+// type mat4.
+//
+// This command makes it possible for vertex shaders to use descriptive names
+// for attribute variables rather than generic variables that are numbered
+// from 0 to GL.MAX_VERTEX_ATTRIBS-1. The values sent to each generic
+// attribute index are part of current state, just like standard vertex
+// attributes such as color, normal, and vertex position. If a different
+// program object is made current by calling UseProgram, the generic vertex
+// attributes are tracked in such a way that the same values will be observed
+// by attributes in the new program object that are also bound to index.
+//
+// Attribute variable name-to-generic attribute index bindings for a program
+// object can be explicitly assigned at any time by calling
+// BindAttribLocation. Attribute bindings do not go into effect until
+// LinkProgram is called. After a program object has been linked
+// successfully, the index values for generic attributes remain fixed (and
+// their values can be queried) until the next link command occurs.
+//
+// Applications are not allowed to bind any of the standard OpenGL vertex
+// attributes using this command, as they are bound automatically when
+// needed. Any attribute binding that occurs after the program object has
+// been linked will not take effect until the next time the program object is
+// linked.
+//
+// If name was bound previously, that information is lost. Thus you cannot
+// bind one user-defined attribute variable to multiple indices, but you can
+// bind multiple user-defined attribute variables to the same index.
+//
+// Applications are allowed to bind more than one user-defined attribute
+// variable to the same generic vertex attribute index. This is called
+// aliasing, and it is allowed only if just one of the aliased attributes is
+// active in the executable program, or if no path through the shader
+// consumes more than one attribute of a set of attributes aliased to the
+// same location. The compiler and linker are allowed to assume that no
+// aliasing is done and are free to employ optimizations that work only in
+// the absence of aliasing. OpenGL implementations are not required to do
+// error checking to detect aliasing. Because there is no way to bind
+// standard attributes, it is not possible to alias generic attributes with
+// conventional ones (except for generic attribute 0).
+//
+// BindAttribLocation can be called before any vertex shader objects are
+// bound to the specified program object. It is also permissible to bind a
+// generic attribute index to an attribute variable name that is never used
+// in a vertex shader.
+//
+// Active attributes that are not explicitly bound will be bound by the
+// linker when LinkProgram is called. The locations assigned can be queried
+// by calling GetAttribLocation.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS.
+// GL.INVALID_OPERATION is generated if name starts with the reserved prefix "gl_".
+// GL.INVALID_VALUE is generated if program is not a value generated by OpenGL.
+// GL.INVALID_OPERATION is generated if program is not a program object.
+// GL.INVALID_OPERATION is generated if BindAttribLocation is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// BindAttribLocation is available in GL version 2.0 or greater.
+func (gl *GL) BindAttribLocation(program glbase.Program, index glbase.Attrib, name string) {
+ name_cstr := C.CString(name)
+ C.gl4_1compat_glBindAttribLocation(gl.funcs, C.GLuint(program), C.GLuint(index), (*C.GLchar)(name_cstr))
+ C.free(unsafe.Pointer(name_cstr))
+}
+
+// AttachShader attaches a shader object to a program object.
+//
+// In order to create an executable, there must be a way to specify the list
+// of things that will be linked together. Program objects provide this
+// mechanism. Shaders that are to be linked together in a program object must
+// first be attached to that program object. This indicates that shader will
+// be included in link operations that will be performed on program.
+//
+// All operations that can be performed on a shader object are valid whether
+// or not the shader object is attached to a program object. It is
+// permissible to attach a shader object to a program object before source
+// code has been loaded into the shader object or before the shader object
+// has been compiled. It is permissible to attach multiple shader objects of
+// the same type because each may contain a portion of the complete shader.
+// It is also permissible to attach a shader object to more than one program
+// object. If a shader object is deleted while it is attached to a program
+// object, it will be flagged for deletion, and deletion will not occur until
+// DetachShader is called to detach it from all program objects to which it
+// is attached.
+//
+// Error GL.INVALID_VALUE is generated if either program or shader is not a
+// value generated by OpenGL. GL.INVALID_OPERATION is generated if program
+// is not a program object. GL.INVALID_OPERATION is generated if shader is
+// not a shader object. GL.INVALID_OPERATION is generated if shader is
+// already attached to program. GL.INVALID_OPERATION is generated if
+// AttachShader is executed between the execution of Begin and the
+// corresponding execution of End.
+//
+// AttachShader is available in GL version 2.0 or greater.
+func (gl *GL) AttachShader(program glbase.Program, shader glbase.Shader) {
+ C.gl4_1compat_glAttachShader(gl.funcs, C.GLuint(program), C.GLuint(shader))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glStencilMaskSeparate.xml
+func (gl *GL) StencilMaskSeparate(face glbase.Enum, mask uint32) {
+ C.gl4_1compat_glStencilMaskSeparate(gl.funcs, C.GLenum(face), C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glStencilFuncSeparate.xml
+func (gl *GL) StencilFuncSeparate(face, glfunc glbase.Enum, ref int32, mask uint32) {
+ C.gl4_1compat_glStencilFuncSeparate(gl.funcs, C.GLenum(face), C.GLenum(glfunc), C.GLint(ref), C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glStencilOpSeparate.xml
+func (gl *GL) StencilOpSeparate(face, sfail, dpfail, dppass glbase.Enum) {
+ C.gl4_1compat_glStencilOpSeparate(gl.funcs, C.GLenum(face), C.GLenum(sfail), C.GLenum(dpfail), C.GLenum(dppass))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawBuffers.xml
+func (gl *GL) DrawBuffers(n int, bufs []glbase.Enum) {
+ C.gl4_1compat_glDrawBuffers(gl.funcs, C.GLsizei(n), (*C.GLenum)(unsafe.Pointer(&bufs[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendEquationSeparate.xml
+func (gl *GL) BlendEquationSeparate(modeRGB, modeAlpha glbase.Enum) {
+ C.gl4_1compat_glBlendEquationSeparate(gl.funcs, C.GLenum(modeRGB), C.GLenum(modeAlpha))
+}
+
+// UniformMatrix4x3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix4x3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix4x3fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(4*3) != 0 {
+ panic("invalid value length for UniformMatrix4x3fv")
+ }
+ count := len(value) / (4 * 3)
+ C.gl4_1compat_glUniformMatrix4x3fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix3x4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix3x4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix3x4fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(3*4) != 0 {
+ panic("invalid value length for UniformMatrix3x4fv")
+ }
+ count := len(value) / (3 * 4)
+ C.gl4_1compat_glUniformMatrix3x4fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix4x2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix4x2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix4x2fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(4*2) != 0 {
+ panic("invalid value length for UniformMatrix4x2fv")
+ }
+ count := len(value) / (4 * 2)
+ C.gl4_1compat_glUniformMatrix4x2fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix2x4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix2x4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix2x4fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(2*4) != 0 {
+ panic("invalid value length for UniformMatrix2x4fv")
+ }
+ count := len(value) / (2 * 4)
+ C.gl4_1compat_glUniformMatrix2x4fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix3x2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix3x2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix3x2fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(3*2) != 0 {
+ panic("invalid value length for UniformMatrix3x2fv")
+ }
+ count := len(value) / (3 * 2)
+ C.gl4_1compat_glUniformMatrix3x2fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix2x3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix2x3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix2x3fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(2*3) != 0 {
+ panic("invalid value length for UniformMatrix2x3fv")
+ }
+ count := len(value) / (2 * 3)
+ C.gl4_1compat_glUniformMatrix2x3fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsVertexArray.xml
+func (gl *GL) IsVertexArray(array uint32) bool {
+ glresult := C.gl4_1compat_glIsVertexArray(gl.funcs, C.GLuint(array))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGenVertexArrays.xml
+func (gl *GL) GenVertexArrays(n int, arrays []uint32) {
+ C.gl4_1compat_glGenVertexArrays(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&arrays[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDeleteVertexArrays.xml
+func (gl *GL) DeleteVertexArrays(n int, arrays []uint32) {
+ C.gl4_1compat_glDeleteVertexArrays(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&arrays[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindVertexArray.xml
+func (gl *GL) BindVertexArray(array uint32) {
+ C.gl4_1compat_glBindVertexArray(gl.funcs, C.GLuint(array))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFlushMappedBufferRange.xml
+func (gl *GL) FlushMappedBufferRange(target glbase.Enum, offset, length int) {
+ C.gl4_1compat_glFlushMappedBufferRange(gl.funcs, C.GLenum(target), C.GLintptr(offset), C.GLsizeiptr(length))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFramebufferTextureLayer.xml
+func (gl *GL) FramebufferTextureLayer(target, attachment glbase.Enum, texture glbase.Texture, level int, layer int32) {
+ C.gl4_1compat_glFramebufferTextureLayer(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLuint(texture), C.GLint(level), C.GLint(layer))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRenderbufferStorageMultisample.xml
+func (gl *GL) RenderbufferStorageMultisample(target glbase.Enum, samples int32, internalFormat glbase.Enum, width, height int) {
+ C.gl4_1compat_glRenderbufferStorageMultisample(gl.funcs, C.GLenum(target), C.GLsizei(samples), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlitFramebuffer.xml
+func (gl *GL) BlitFramebuffer(srcX0, srcY0, srcX1, srcY1, dstX0, dstY0, dstX1, dstY1 int32, mask glbase.Bitfield, filter glbase.Enum) {
+ C.gl4_1compat_glBlitFramebuffer(gl.funcs, C.GLint(srcX0), C.GLint(srcY0), C.GLint(srcX1), C.GLint(srcY1), C.GLint(dstX0), C.GLint(dstY0), C.GLint(dstX1), C.GLint(dstY1), C.GLbitfield(mask), C.GLenum(filter))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGenerateMipmap.xml
+func (gl *GL) GenerateMipmap(target glbase.Enum) {
+ C.gl4_1compat_glGenerateMipmap(gl.funcs, C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetFramebufferAttachmentParameteriv.xml
+func (gl *GL) GetFramebufferAttachmentParameteriv(target, attachment, pname glbase.Enum, params []int32) {
+ C.gl4_1compat_glGetFramebufferAttachmentParameteriv(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFramebufferRenderbuffer.xml
+func (gl *GL) FramebufferRenderbuffer(target, attachment, renderbuffertarget glbase.Enum, renderbuffer glbase.Renderbuffer) {
+ C.gl4_1compat_glFramebufferRenderbuffer(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(renderbuffertarget), C.GLuint(renderbuffer))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFramebufferTexture3D.xml
+func (gl *GL) FramebufferTexture3D(target, attachment, textarget glbase.Enum, texture glbase.Texture, level int, zoffset int32) {
+ C.gl4_1compat_glFramebufferTexture3D(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(textarget), C.GLuint(texture), C.GLint(level), C.GLint(zoffset))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFramebufferTexture2D.xml
+func (gl *GL) FramebufferTexture2D(target, attachment, textarget glbase.Enum, texture glbase.Texture, level int) {
+ C.gl4_1compat_glFramebufferTexture2D(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(textarget), C.GLuint(texture), C.GLint(level))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFramebufferTexture1D.xml
+func (gl *GL) FramebufferTexture1D(target, attachment, textarget glbase.Enum, texture glbase.Texture, level int) {
+ C.gl4_1compat_glFramebufferTexture1D(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(textarget), C.GLuint(texture), C.GLint(level))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCheckFramebufferStatus.xml
+func (gl *GL) CheckFramebufferStatus(target glbase.Enum) glbase.Enum {
+ glresult := C.gl4_1compat_glCheckFramebufferStatus(gl.funcs, C.GLenum(target))
+ return glbase.Enum(glresult)
+}
+
+// GenFramebuffers returns n framebuffer object names in ids. There is no
+// guarantee that the names form a contiguous set of integers; however, it is
+// guaranteed that none of the returned names was in use immediately before
+// the call to GenFramebuffers.
+//
+// Framebuffer object names returned by a call to GenFramebuffers are not
+// returned by subsequent calls, unless they are first deleted with
+// DeleteFramebuffers.
+//
+// The names returned in ids are marked as used, for the purposes of
+// GenFramebuffers only, but they acquire state and type only when they are
+// first bound.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+func (gl *GL) GenFramebuffers(n int) []glbase.Framebuffer {
+ if n == 0 {
+ return nil
+ }
+ framebuffers := make([]glbase.Framebuffer, n)
+ C.gl4_1compat_glGenFramebuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&framebuffers[0])))
+ return framebuffers
+}
+
+// DeleteFramebuffers deletes the framebuffer objects whose names are
+// stored in the framebuffers slice. The name zero is reserved by the GL and
+// is silently ignored, should it occur in framebuffers, as are other unused
+// names. Once a framebuffer object is deleted, its name is again unused and
+// it has no attachments. If a framebuffer that is currently bound to one or
+// more of the targets GL.DRAW_FRAMEBUFFER or GL.READ_FRAMEBUFFER is deleted,
+// it is as though BindFramebuffer had been executed with the corresponding
+// target and framebuffer zero.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// DeleteFramebuffers is available in GL version 3.0 or greater.
+func (gl *GL) DeleteFramebuffers(framebuffers []glbase.Framebuffer) {
+ n := len(framebuffers)
+ if n == 0 {
+ return
+ }
+ C.gl4_1compat_glDeleteFramebuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&framebuffers[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindFramebuffer.xml
+func (gl *GL) BindFramebuffer(target glbase.Enum, framebuffer glbase.Framebuffer) {
+ C.gl4_1compat_glBindFramebuffer(gl.funcs, C.GLenum(target), C.GLuint(framebuffer))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsFramebuffer.xml
+func (gl *GL) IsFramebuffer(framebuffer glbase.Framebuffer) bool {
+ glresult := C.gl4_1compat_glIsFramebuffer(gl.funcs, C.GLuint(framebuffer))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetRenderbufferParameteriv.xml
+func (gl *GL) GetRenderbufferParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl4_1compat_glGetRenderbufferParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRenderbufferStorage.xml
+func (gl *GL) RenderbufferStorage(target, internalFormat glbase.Enum, width, height int) {
+ C.gl4_1compat_glRenderbufferStorage(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height))
+}
+
+// GenRenderbuffers returns n renderbuffer object names in renderbuffers.
+// There is no guarantee that the names form a contiguous set of integers;
+// however, it is guaranteed that none of the returned names was in use
+// immediately before the call to GenRenderbuffers.
+//
+// Renderbuffer object names returned by a call to GenRenderbuffers are not
+// returned by subsequent calls, unless they are first deleted with
+// DeleteRenderbuffers.
+//
+// The names returned in renderbuffers are marked as used, for the purposes
+// of GenRenderbuffers only, but they acquire state and type only when they
+// are first bound.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// GenRenderbuffers is available in GL version 3.0 or greater.
+func (gl *GL) GenRenderbuffers(n int) []glbase.Renderbuffer {
+ if n == 0 {
+ return nil
+ }
+ renderbuffers := make([]glbase.Renderbuffer, n)
+ C.gl4_1compat_glGenRenderbuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&renderbuffers[0])))
+ return renderbuffers
+}
+
+// DeleteRenderbuffers deletes the renderbuffer objects whose names are stored
+// in the renderbuffers slice. The name zero is reserved by the GL and
+// is silently ignored, should it occur in renderbuffers, as are other unused
+// names. Once a renderbuffer object is deleted, its name is again unused and
+// it has no contents. If a renderbuffer that is currently bound to the
+// target GL.RENDERBUFFER is deleted, it is as though BindRenderbuffer had
+// been executed with a target of GL.RENDERBUFFER and a name of zero.
+//
+// If a renderbuffer object is attached to one or more attachment points in
+// the currently bound framebuffer, then it as if FramebufferRenderbuffer
+// had been called, with a renderbuffer of zero for each attachment point to
+// which this image was attached in the currently bound framebuffer. In other
+// words, this renderbuffer object is first detached from all attachment
+// ponits in the currently bound framebuffer. Note that the renderbuffer
+// image is specifically not detached from any non-bound framebuffers.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// DeleteRenderbuffers is available in GL version 3.0 or greater.
+func (gl *GL) DeleteRenderbuffers(renderbuffers []glbase.Renderbuffer) {
+ n := len(renderbuffers)
+ if n == 0 {
+ return
+ }
+ C.gl4_1compat_glDeleteRenderbuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&renderbuffers[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindRenderbuffer.xml
+func (gl *GL) BindRenderbuffer(target glbase.Enum, renderbuffer glbase.Renderbuffer) {
+ C.gl4_1compat_glBindRenderbuffer(gl.funcs, C.GLenum(target), C.GLuint(renderbuffer))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsRenderbuffer.xml
+func (gl *GL) IsRenderbuffer(renderbuffer glbase.Renderbuffer) bool {
+ glresult := C.gl4_1compat_glIsRenderbuffer(gl.funcs, C.GLuint(renderbuffer))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearBufferfi.xml
+func (gl *GL) ClearBufferfi(buffer glbase.Enum, drawbuffer int32, depth float32, stencil int32) {
+ C.gl4_1compat_glClearBufferfi(gl.funcs, C.GLenum(buffer), C.GLint(drawbuffer), C.GLfloat(depth), C.GLint(stencil))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearBufferfv.xml
+func (gl *GL) ClearBufferfv(buffer glbase.Enum, drawbuffer int32, value []float32) {
+ C.gl4_1compat_glClearBufferfv(gl.funcs, C.GLenum(buffer), C.GLint(drawbuffer), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearBufferuiv.xml
+func (gl *GL) ClearBufferuiv(buffer glbase.Enum, drawbuffer int32, value []uint32) {
+ C.gl4_1compat_glClearBufferuiv(gl.funcs, C.GLenum(buffer), C.GLint(drawbuffer), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearBufferiv.xml
+func (gl *GL) ClearBufferiv(buffer glbase.Enum, drawbuffer int32, value []int32) {
+ C.gl4_1compat_glClearBufferiv(gl.funcs, C.GLenum(buffer), C.GLint(drawbuffer), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexParameterIuiv.xml
+func (gl *GL) GetTexParameterIuiv(target, pname glbase.Enum, params []uint32) {
+ C.gl4_1compat_glGetTexParameterIuiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexParameterIiv.xml
+func (gl *GL) GetTexParameterIiv(target, pname glbase.Enum, params []int32) {
+ C.gl4_1compat_glGetTexParameterIiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexParameterIuiv.xml
+func (gl *GL) TexParameterIuiv(target, pname glbase.Enum, params []uint32) {
+ C.gl4_1compat_glTexParameterIuiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexParameterIiv.xml
+func (gl *GL) TexParameterIiv(target, pname glbase.Enum, params []int32) {
+ C.gl4_1compat_glTexParameterIiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// Uniform4uiv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform4uiv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4uiv(location glbase.Uniform, value []uint32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%4 != 0 {
+ panic("invalid value length for Uniform4uiv")
+ }
+ count := len(value) / 4
+ C.gl4_1compat_glUniform4uiv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform3uiv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform3uiv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3uiv(location glbase.Uniform, value []uint32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%3 != 0 {
+ panic("invalid value length for Uniform3uiv")
+ }
+ count := len(value) / 3
+ C.gl4_1compat_glUniform3uiv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform2uiv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform2uiv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2uiv(location glbase.Uniform, value []uint32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%2 != 0 {
+ panic("invalid value length for Uniform2uiv")
+ }
+ count := len(value) / 2
+ C.gl4_1compat_glUniform2uiv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform1uiv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform1uiv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1uiv(location glbase.Uniform, value []uint32) {
+ if len(value) == 0 {
+ return
+ }
+ count := len(value)
+ C.gl4_1compat_glUniform1uiv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4ui modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform4ui operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4ui(location glbase.Uniform, v0, v1, v2, v3 uint32) {
+ C.gl4_1compat_glUniform4ui(gl.funcs, C.GLint(location), C.GLuint(v0), C.GLuint(v1), C.GLuint(v2), C.GLuint(v3))
+}
+
+// Uniform3ui modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform3ui operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3ui(location glbase.Uniform, v0, v1, v2 uint32) {
+ C.gl4_1compat_glUniform3ui(gl.funcs, C.GLint(location), C.GLuint(v0), C.GLuint(v1), C.GLuint(v2))
+}
+
+// Uniform2ui modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform2ui operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2ui(location glbase.Uniform, v0, v1 uint32) {
+ C.gl4_1compat_glUniform2ui(gl.funcs, C.GLint(location), C.GLuint(v0), C.GLuint(v1))
+}
+
+// Uniform1ui modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform1ui operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1ui(location glbase.Uniform, v0 uint32) {
+ C.gl4_1compat_glUniform1ui(gl.funcs, C.GLint(location), C.GLuint(v0))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetFragDataLocation.xml
+func (gl *GL) GetFragDataLocation(program glbase.Program, name []byte) int32 {
+ glresult := C.gl4_1compat_glGetFragDataLocation(gl.funcs, C.GLuint(program), (*C.GLchar)(unsafe.Pointer(&name[0])))
+ return int32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindFragDataLocation.xml
+func (gl *GL) BindFragDataLocation(program glbase.Program, color uint32, name []byte) {
+ C.gl4_1compat_glBindFragDataLocation(gl.funcs, C.GLuint(program), C.GLuint(color), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetUniformuiv.xml
+func (gl *GL) GetUniformuiv(program glbase.Program, location glbase.Uniform, params []uint32) {
+ C.gl4_1compat_glGetUniformuiv(gl.funcs, C.GLuint(program), C.GLint(location), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetVertexAttribIuiv.xml
+func (gl *GL) GetVertexAttribIuiv(index glbase.Attrib, pname glbase.Enum, params []uint32) {
+ C.gl4_1compat_glGetVertexAttribIuiv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetVertexAttribIiv.xml
+func (gl *GL) GetVertexAttribIiv(index glbase.Attrib, pname glbase.Enum, params []int32) {
+ C.gl4_1compat_glGetVertexAttribIiv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribIPointer.xml
+func (gl *GL) VertexAttribIPointer(index glbase.Attrib, size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1compat_glVertexAttribIPointer(gl.funcs, C.GLuint(index), C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEndConditionalRender.xml
+func (gl *GL) EndConditionalRender() {
+ C.gl4_1compat_glEndConditionalRender(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBeginConditionalRender.xml
+func (gl *GL) BeginConditionalRender(id uint32, mode glbase.Enum) {
+ C.gl4_1compat_glBeginConditionalRender(gl.funcs, C.GLuint(id), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClampColor.xml
+func (gl *GL) ClampColor(target, clamp glbase.Enum) {
+ C.gl4_1compat_glClampColor(gl.funcs, C.GLenum(target), C.GLenum(clamp))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTransformFeedbackVarying.xml
+func (gl *GL) GetTransformFeedbackVarying(program glbase.Program, index uint32, bufSize int32, length []int32, size []int, gltype []glbase.Enum, name []byte) {
+ C.gl4_1compat_glGetTransformFeedbackVarying(gl.funcs, C.GLuint(program), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLsizei)(unsafe.Pointer(&size[0])), (*C.GLenum)(unsafe.Pointer(&gltype[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindBufferBase.xml
+func (gl *GL) BindBufferBase(target glbase.Enum, index uint32, buffer glbase.Buffer) {
+ C.gl4_1compat_glBindBufferBase(gl.funcs, C.GLenum(target), C.GLuint(index), C.GLuint(buffer))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindBufferRange.xml
+func (gl *GL) BindBufferRange(target glbase.Enum, index uint32, buffer glbase.Buffer, offset, size int) {
+ C.gl4_1compat_glBindBufferRange(gl.funcs, C.GLenum(target), C.GLuint(index), C.GLuint(buffer), C.GLintptr(offset), C.GLsizeiptr(size))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEndTransformFeedback.xml
+func (gl *GL) EndTransformFeedback() {
+ C.gl4_1compat_glEndTransformFeedback(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBeginTransformFeedback.xml
+func (gl *GL) BeginTransformFeedback(primitiveMode glbase.Enum) {
+ C.gl4_1compat_glBeginTransformFeedback(gl.funcs, C.GLenum(primitiveMode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsEnabledi.xml
+func (gl *GL) IsEnabledi(target glbase.Enum, index uint32) bool {
+ glresult := C.gl4_1compat_glIsEnabledi(gl.funcs, C.GLenum(target), C.GLuint(index))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDisablei.xml
+func (gl *GL) Disablei(target glbase.Enum, index uint32) {
+ C.gl4_1compat_glDisablei(gl.funcs, C.GLenum(target), C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEnablei.xml
+func (gl *GL) Enablei(target glbase.Enum, index uint32) {
+ C.gl4_1compat_glEnablei(gl.funcs, C.GLenum(target), C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetIntegeri_v.xml
+func (gl *GL) GetIntegeri_v(target glbase.Enum, index uint32, data []int32) {
+ C.gl4_1compat_glGetIntegeri_v(gl.funcs, C.GLenum(target), C.GLuint(index), (*C.GLint)(unsafe.Pointer(&data[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetBooleani_v.xml
+func (gl *GL) GetBooleani_v(target glbase.Enum, index uint32, data []bool) {
+ C.gl4_1compat_glGetBooleani_v(gl.funcs, C.GLenum(target), C.GLuint(index), (*C.GLboolean)(unsafe.Pointer(&data[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorMaski.xml
+func (gl *GL) ColorMaski(index uint32, r, g, b, a bool) {
+ C.gl4_1compat_glColorMaski(gl.funcs, C.GLuint(index), *(*C.GLboolean)(unsafe.Pointer(&r)), *(*C.GLboolean)(unsafe.Pointer(&g)), *(*C.GLboolean)(unsafe.Pointer(&b)), *(*C.GLboolean)(unsafe.Pointer(&a)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyBufferSubData.xml
+func (gl *GL) CopyBufferSubData(readTarget, writeTarget glbase.Enum, readOffset, writeOffset, size int) {
+ C.gl4_1compat_glCopyBufferSubData(gl.funcs, C.GLenum(readTarget), C.GLenum(writeTarget), C.GLintptr(readOffset), C.GLintptr(writeOffset), C.GLsizeiptr(size))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformBlockBinding.xml
+func (gl *GL) UniformBlockBinding(program glbase.Program, v0, v1 uint32) {
+ C.gl4_1compat_glUniformBlockBinding(gl.funcs, C.GLuint(program), C.GLuint(v0), C.GLuint(v1))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveUniformBlockName.xml
+func (gl *GL) GetActiveUniformBlockName(program glbase.Program, uniformBlockIndex uint32, bufSize int32, length []int32, uniformBlockName []byte) {
+ C.gl4_1compat_glGetActiveUniformBlockName(gl.funcs, C.GLuint(program), C.GLuint(uniformBlockIndex), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&uniformBlockName[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveUniformBlockiv.xml
+func (gl *GL) GetActiveUniformBlockiv(program glbase.Program, uniformBlockIndex uint32, pname glbase.Enum, params []int32) {
+ C.gl4_1compat_glGetActiveUniformBlockiv(gl.funcs, C.GLuint(program), C.GLuint(uniformBlockIndex), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetUniformBlockIndex.xml
+func (gl *GL) GetUniformBlockIndex(program glbase.Program, uniformBlockName []byte) uint32 {
+ glresult := C.gl4_1compat_glGetUniformBlockIndex(gl.funcs, C.GLuint(program), (*C.GLchar)(unsafe.Pointer(&uniformBlockName[0])))
+ return uint32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveUniformName.xml
+func (gl *GL) GetActiveUniformName(program glbase.Program, uniformIndex uint32, bufSize int32, length []int32, uniformName []byte) {
+ C.gl4_1compat_glGetActiveUniformName(gl.funcs, C.GLuint(program), C.GLuint(uniformIndex), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&uniformName[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveUniformsiv.xml
+func (gl *GL) GetActiveUniformsiv(program glbase.Program, uniformCount int32, uniformIndices []uint32, pname glbase.Enum, params []int32) {
+ C.gl4_1compat_glGetActiveUniformsiv(gl.funcs, C.GLuint(program), C.GLsizei(uniformCount), (*C.GLuint)(unsafe.Pointer(&uniformIndices[0])), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPrimitiveRestartIndex.xml
+func (gl *GL) PrimitiveRestartIndex(index uint32) {
+ C.gl4_1compat_glPrimitiveRestartIndex(gl.funcs, C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexBuffer.xml
+func (gl *GL) TexBuffer(target, internalFormat glbase.Enum, buffer glbase.Buffer) {
+ C.gl4_1compat_glTexBuffer(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLuint(buffer))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawElementsInstanced.xml
+func (gl *GL) DrawElementsInstanced(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}, instancecount int32) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1compat_glDrawElementsInstanced(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr, C.GLsizei(instancecount))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawArraysInstanced.xml
+func (gl *GL) DrawArraysInstanced(mode glbase.Enum, first, count int, instancecount int32) {
+ C.gl4_1compat_glDrawArraysInstanced(gl.funcs, C.GLenum(mode), C.GLint(first), C.GLsizei(count), C.GLsizei(instancecount))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSampleMaski.xml
+func (gl *GL) SampleMaski(index uint32, mask glbase.Bitfield) {
+ C.gl4_1compat_glSampleMaski(gl.funcs, C.GLuint(index), C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetMultisamplefv.xml
+func (gl *GL) GetMultisamplefv(pname glbase.Enum, index uint32, val []float32) {
+ C.gl4_1compat_glGetMultisamplefv(gl.funcs, C.GLenum(pname), C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&val[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexImage3DMultisample.xml
+func (gl *GL) TexImage3DMultisample(target glbase.Enum, samples, internalFormat int32, width, height int, depth int32, fixedsamplelocations bool) {
+ C.gl4_1compat_glTexImage3DMultisample(gl.funcs, C.GLenum(target), C.GLsizei(samples), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), *(*C.GLboolean)(unsafe.Pointer(&fixedsamplelocations)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexImage2DMultisample.xml
+func (gl *GL) TexImage2DMultisample(target glbase.Enum, samples, internalFormat int32, width, height int, fixedsamplelocations bool) {
+ C.gl4_1compat_glTexImage2DMultisample(gl.funcs, C.GLenum(target), C.GLsizei(samples), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), *(*C.GLboolean)(unsafe.Pointer(&fixedsamplelocations)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetSynciv.xml
+func (gl *GL) GetSynciv(sync glbase.Sync, pname glbase.Enum, bufSize int32, length, values []int32) {
+ C.gl4_1compat_glGetSynciv(gl.funcs, C.GLsync(unsafe.Pointer(sync)), C.GLenum(pname), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLint)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetInteger64v.xml
+func (gl *GL) GetInteger64v(pname glbase.Enum, params []int64) {
+ C.gl4_1compat_glGetInteger64v(gl.funcs, C.GLenum(pname), (*C.GLint64)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWaitSync.xml
+func (gl *GL) WaitSync(sync glbase.Sync, flags glbase.Bitfield, timeout uint64) {
+ C.gl4_1compat_glWaitSync(gl.funcs, C.GLsync(unsafe.Pointer(sync)), C.GLbitfield(flags), C.GLuint64(timeout))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClientWaitSync.xml
+func (gl *GL) ClientWaitSync(sync glbase.Sync, flags glbase.Bitfield, timeout uint64) glbase.Enum {
+ glresult := C.gl4_1compat_glClientWaitSync(gl.funcs, C.GLsync(unsafe.Pointer(sync)), C.GLbitfield(flags), C.GLuint64(timeout))
+ return glbase.Enum(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDeleteSync.xml
+func (gl *GL) DeleteSync(sync glbase.Sync) {
+ C.gl4_1compat_glDeleteSync(gl.funcs, C.GLsync(unsafe.Pointer(sync)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsSync.xml
+func (gl *GL) IsSync(sync glbase.Sync) bool {
+ glresult := C.gl4_1compat_glIsSync(gl.funcs, C.GLsync(unsafe.Pointer(sync)))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFenceSync.xml
+func (gl *GL) FenceSync(condition glbase.Enum, flags glbase.Bitfield) glbase.Sync {
+ glresult := C.gl4_1compat_glFenceSync(gl.funcs, C.GLenum(condition), C.GLbitfield(flags))
+ return glbase.Sync(unsafe.Pointer(glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProvokingVertex.xml
+func (gl *GL) ProvokingVertex(mode glbase.Enum) {
+ C.gl4_1compat_glProvokingVertex(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawElementsInstancedBaseVertex.xml
+func (gl *GL) DrawElementsInstancedBaseVertex(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}, instancecount, basevertex int32) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1compat_glDrawElementsInstancedBaseVertex(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr, C.GLsizei(instancecount), C.GLint(basevertex))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawRangeElementsBaseVertex.xml
+func (gl *GL) DrawRangeElementsBaseVertex(mode glbase.Enum, start, end uint32, count int, gltype glbase.Enum, indices interface{}, basevertex int32) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1compat_glDrawRangeElementsBaseVertex(gl.funcs, C.GLenum(mode), C.GLuint(start), C.GLuint(end), C.GLsizei(count), C.GLenum(gltype), indices_ptr, C.GLint(basevertex))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawElementsBaseVertex.xml
+func (gl *GL) DrawElementsBaseVertex(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}, basevertex int32) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1compat_glDrawElementsBaseVertex(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr, C.GLint(basevertex))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFramebufferTexture.xml
+func (gl *GL) FramebufferTexture(target, attachment glbase.Enum, texture glbase.Texture, level int) {
+ C.gl4_1compat_glFramebufferTexture(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLuint(texture), C.GLint(level))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetBufferParameteri64v.xml
+func (gl *GL) GetBufferParameteri64v(target, pname glbase.Enum, params []int64) {
+ C.gl4_1compat_glGetBufferParameteri64v(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint64)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetInteger64i_v.xml
+func (gl *GL) GetInteger64i_v(target glbase.Enum, index uint32, data []int64) {
+ C.gl4_1compat_glGetInteger64i_v(gl.funcs, C.GLenum(target), C.GLuint(index), (*C.GLint64)(unsafe.Pointer(&data[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP4uiv.xml
+func (gl *GL) VertexAttribP4uiv(index glbase.Attrib, gltype glbase.Enum, normalized bool, value []uint32) {
+ C.gl4_1compat_glVertexAttribP4uiv(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP4ui.xml
+func (gl *GL) VertexAttribP4ui(index glbase.Attrib, gltype glbase.Enum, normalized bool, value uint32) {
+ C.gl4_1compat_glVertexAttribP4ui(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP3uiv.xml
+func (gl *GL) VertexAttribP3uiv(index glbase.Attrib, gltype glbase.Enum, normalized bool, value []uint32) {
+ C.gl4_1compat_glVertexAttribP3uiv(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP3ui.xml
+func (gl *GL) VertexAttribP3ui(index glbase.Attrib, gltype glbase.Enum, normalized bool, value uint32) {
+ C.gl4_1compat_glVertexAttribP3ui(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP2uiv.xml
+func (gl *GL) VertexAttribP2uiv(index glbase.Attrib, gltype glbase.Enum, normalized bool, value []uint32) {
+ C.gl4_1compat_glVertexAttribP2uiv(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP2ui.xml
+func (gl *GL) VertexAttribP2ui(index glbase.Attrib, gltype glbase.Enum, normalized bool, value uint32) {
+ C.gl4_1compat_glVertexAttribP2ui(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP1uiv.xml
+func (gl *GL) VertexAttribP1uiv(index glbase.Attrib, gltype glbase.Enum, normalized bool, value []uint32) {
+ C.gl4_1compat_glVertexAttribP1uiv(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP1ui.xml
+func (gl *GL) VertexAttribP1ui(index glbase.Attrib, gltype glbase.Enum, normalized bool, value uint32) {
+ C.gl4_1compat_glVertexAttribP1ui(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColorP3uiv.xml
+func (gl *GL) SecondaryColorP3uiv(gltype glbase.Enum, color []uint32) {
+ C.gl4_1compat_glSecondaryColorP3uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&color[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColorP3ui.xml
+func (gl *GL) SecondaryColorP3ui(gltype glbase.Enum, color uint32) {
+ C.gl4_1compat_glSecondaryColorP3ui(gl.funcs, C.GLenum(gltype), C.GLuint(color))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorP4uiv.xml
+func (gl *GL) ColorP4uiv(gltype glbase.Enum, color []uint32) {
+ C.gl4_1compat_glColorP4uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&color[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorP4ui.xml
+func (gl *GL) ColorP4ui(gltype glbase.Enum, color uint32) {
+ C.gl4_1compat_glColorP4ui(gl.funcs, C.GLenum(gltype), C.GLuint(color))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorP3uiv.xml
+func (gl *GL) ColorP3uiv(gltype glbase.Enum, color []uint32) {
+ C.gl4_1compat_glColorP3uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&color[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorP3ui.xml
+func (gl *GL) ColorP3ui(gltype glbase.Enum, color uint32) {
+ C.gl4_1compat_glColorP3ui(gl.funcs, C.GLenum(gltype), C.GLuint(color))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNormalP3uiv.xml
+func (gl *GL) NormalP3uiv(gltype glbase.Enum, coords []uint32) {
+ C.gl4_1compat_glNormalP3uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNormalP3ui.xml
+func (gl *GL) NormalP3ui(gltype glbase.Enum, coords uint32) {
+ C.gl4_1compat_glNormalP3ui(gl.funcs, C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP4uiv.xml
+func (gl *GL) MultiTexCoordP4uiv(texture, gltype glbase.Enum, coords []uint32) {
+ C.gl4_1compat_glMultiTexCoordP4uiv(gl.funcs, C.GLenum(texture), C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP4ui.xml
+func (gl *GL) MultiTexCoordP4ui(texture, gltype glbase.Enum, coords uint32) {
+ C.gl4_1compat_glMultiTexCoordP4ui(gl.funcs, C.GLenum(texture), C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP3uiv.xml
+func (gl *GL) MultiTexCoordP3uiv(texture, gltype glbase.Enum, coords []uint32) {
+ C.gl4_1compat_glMultiTexCoordP3uiv(gl.funcs, C.GLenum(texture), C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP3ui.xml
+func (gl *GL) MultiTexCoordP3ui(texture, gltype glbase.Enum, coords uint32) {
+ C.gl4_1compat_glMultiTexCoordP3ui(gl.funcs, C.GLenum(texture), C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP2uiv.xml
+func (gl *GL) MultiTexCoordP2uiv(texture, gltype glbase.Enum, coords []uint32) {
+ C.gl4_1compat_glMultiTexCoordP2uiv(gl.funcs, C.GLenum(texture), C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP2ui.xml
+func (gl *GL) MultiTexCoordP2ui(texture, gltype glbase.Enum, coords uint32) {
+ C.gl4_1compat_glMultiTexCoordP2ui(gl.funcs, C.GLenum(texture), C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP1uiv.xml
+func (gl *GL) MultiTexCoordP1uiv(texture, gltype glbase.Enum, coords []uint32) {
+ C.gl4_1compat_glMultiTexCoordP1uiv(gl.funcs, C.GLenum(texture), C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP1ui.xml
+func (gl *GL) MultiTexCoordP1ui(texture, gltype glbase.Enum, coords uint32) {
+ C.gl4_1compat_glMultiTexCoordP1ui(gl.funcs, C.GLenum(texture), C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP4uiv.xml
+func (gl *GL) TexCoordP4uiv(gltype glbase.Enum, coords []uint32) {
+ C.gl4_1compat_glTexCoordP4uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP4ui.xml
+func (gl *GL) TexCoordP4ui(gltype glbase.Enum, coords uint32) {
+ C.gl4_1compat_glTexCoordP4ui(gl.funcs, C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP3uiv.xml
+func (gl *GL) TexCoordP3uiv(gltype glbase.Enum, coords []uint32) {
+ C.gl4_1compat_glTexCoordP3uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP3ui.xml
+func (gl *GL) TexCoordP3ui(gltype glbase.Enum, coords uint32) {
+ C.gl4_1compat_glTexCoordP3ui(gl.funcs, C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP2uiv.xml
+func (gl *GL) TexCoordP2uiv(gltype glbase.Enum, coords []uint32) {
+ C.gl4_1compat_glTexCoordP2uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP2ui.xml
+func (gl *GL) TexCoordP2ui(gltype glbase.Enum, coords uint32) {
+ C.gl4_1compat_glTexCoordP2ui(gl.funcs, C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP1uiv.xml
+func (gl *GL) TexCoordP1uiv(gltype glbase.Enum, coords []uint32) {
+ C.gl4_1compat_glTexCoordP1uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP1ui.xml
+func (gl *GL) TexCoordP1ui(gltype glbase.Enum, coords uint32) {
+ C.gl4_1compat_glTexCoordP1ui(gl.funcs, C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexP4uiv.xml
+func (gl *GL) VertexP4uiv(gltype glbase.Enum, value []uint32) {
+ C.gl4_1compat_glVertexP4uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexP4ui.xml
+func (gl *GL) VertexP4ui(gltype glbase.Enum, value uint32) {
+ C.gl4_1compat_glVertexP4ui(gl.funcs, C.GLenum(gltype), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexP3uiv.xml
+func (gl *GL) VertexP3uiv(gltype glbase.Enum, value []uint32) {
+ C.gl4_1compat_glVertexP3uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexP3ui.xml
+func (gl *GL) VertexP3ui(gltype glbase.Enum, value uint32) {
+ C.gl4_1compat_glVertexP3ui(gl.funcs, C.GLenum(gltype), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexP2uiv.xml
+func (gl *GL) VertexP2uiv(gltype glbase.Enum, value []uint32) {
+ C.gl4_1compat_glVertexP2uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexP2ui.xml
+func (gl *GL) VertexP2ui(gltype glbase.Enum, value uint32) {
+ C.gl4_1compat_glVertexP2ui(gl.funcs, C.GLenum(gltype), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetQueryObjectui64v.xml
+func (gl *GL) GetQueryObjectui64v(id uint32, pname glbase.Enum, params []uint64) {
+ C.gl4_1compat_glGetQueryObjectui64v(gl.funcs, C.GLuint(id), C.GLenum(pname), (*C.GLuint64)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetQueryObjecti64v.xml
+func (gl *GL) GetQueryObjecti64v(id uint32, pname glbase.Enum, params []int64) {
+ C.gl4_1compat_glGetQueryObjecti64v(gl.funcs, C.GLuint(id), C.GLenum(pname), (*C.GLint64)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glQueryCounter.xml
+func (gl *GL) QueryCounter(id uint32, target glbase.Enum) {
+ C.gl4_1compat_glQueryCounter(gl.funcs, C.GLuint(id), C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetSamplerParameterIuiv.xml
+func (gl *GL) GetSamplerParameterIuiv(sampler uint32, pname glbase.Enum, params []uint32) {
+ C.gl4_1compat_glGetSamplerParameterIuiv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetSamplerParameterfv.xml
+func (gl *GL) GetSamplerParameterfv(sampler uint32, pname glbase.Enum, params []float32) {
+ C.gl4_1compat_glGetSamplerParameterfv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetSamplerParameterIiv.xml
+func (gl *GL) GetSamplerParameterIiv(sampler uint32, pname glbase.Enum, params []int32) {
+ C.gl4_1compat_glGetSamplerParameterIiv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetSamplerParameteriv.xml
+func (gl *GL) GetSamplerParameteriv(sampler uint32, pname glbase.Enum, params []int32) {
+ C.gl4_1compat_glGetSamplerParameteriv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSamplerParameterIuiv.xml
+func (gl *GL) SamplerParameterIuiv(sampler uint32, pname glbase.Enum, param []uint32) {
+ C.gl4_1compat_glSamplerParameterIuiv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&param[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSamplerParameterIiv.xml
+func (gl *GL) SamplerParameterIiv(sampler uint32, pname glbase.Enum, param []int32) {
+ C.gl4_1compat_glSamplerParameterIiv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&param[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSamplerParameterfv.xml
+func (gl *GL) SamplerParameterfv(sampler uint32, pname glbase.Enum, param []float32) {
+ C.gl4_1compat_glSamplerParameterfv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&param[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSamplerParameterf.xml
+func (gl *GL) SamplerParameterf(sampler uint32, pname glbase.Enum, param float32) {
+ C.gl4_1compat_glSamplerParameterf(gl.funcs, C.GLuint(sampler), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSamplerParameteriv.xml
+func (gl *GL) SamplerParameteriv(sampler uint32, pname glbase.Enum, param []int32) {
+ C.gl4_1compat_glSamplerParameteriv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&param[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSamplerParameteri.xml
+func (gl *GL) SamplerParameteri(sampler uint32, pname glbase.Enum, param int32) {
+ C.gl4_1compat_glSamplerParameteri(gl.funcs, C.GLuint(sampler), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindSampler.xml
+func (gl *GL) BindSampler(unit, sampler uint32) {
+ C.gl4_1compat_glBindSampler(gl.funcs, C.GLuint(unit), C.GLuint(sampler))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsSampler.xml
+func (gl *GL) IsSampler(sampler uint32) bool {
+ glresult := C.gl4_1compat_glIsSampler(gl.funcs, C.GLuint(sampler))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDeleteSamplers.xml
+func (gl *GL) DeleteSamplers(count int, samplers []uint32) {
+ C.gl4_1compat_glDeleteSamplers(gl.funcs, C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&samplers[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGenSamplers.xml
+func (gl *GL) GenSamplers(count int, samplers []uint32) {
+ C.gl4_1compat_glGenSamplers(gl.funcs, C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&samplers[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetFragDataIndex.xml
+func (gl *GL) GetFragDataIndex(program glbase.Program, name []byte) int32 {
+ glresult := C.gl4_1compat_glGetFragDataIndex(gl.funcs, C.GLuint(program), (*C.GLchar)(unsafe.Pointer(&name[0])))
+ return int32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindFragDataLocationIndexed.xml
+func (gl *GL) BindFragDataLocationIndexed(program glbase.Program, colorNumber, index uint32, name []byte) {
+ C.gl4_1compat_glBindFragDataLocationIndexed(gl.funcs, C.GLuint(program), C.GLuint(colorNumber), C.GLuint(index), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribDivisor.xml
+func (gl *GL) VertexAttribDivisor(index glbase.Attrib, divisor uint32) {
+ C.gl4_1compat_glVertexAttribDivisor(gl.funcs, C.GLuint(index), C.GLuint(divisor))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetQueryIndexediv.xml
+func (gl *GL) GetQueryIndexediv(target glbase.Enum, index uint32, pname glbase.Enum, params []int32) {
+ C.gl4_1compat_glGetQueryIndexediv(gl.funcs, C.GLenum(target), C.GLuint(index), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEndQueryIndexed.xml
+func (gl *GL) EndQueryIndexed(target glbase.Enum, index uint32) {
+ C.gl4_1compat_glEndQueryIndexed(gl.funcs, C.GLenum(target), C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBeginQueryIndexed.xml
+func (gl *GL) BeginQueryIndexed(target glbase.Enum, index, id uint32) {
+ C.gl4_1compat_glBeginQueryIndexed(gl.funcs, C.GLenum(target), C.GLuint(index), C.GLuint(id))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawTransformFeedbackStream.xml
+func (gl *GL) DrawTransformFeedbackStream(mode glbase.Enum, id, stream uint32) {
+ C.gl4_1compat_glDrawTransformFeedbackStream(gl.funcs, C.GLenum(mode), C.GLuint(id), C.GLuint(stream))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawTransformFeedback.xml
+func (gl *GL) DrawTransformFeedback(mode glbase.Enum, id uint32) {
+ C.gl4_1compat_glDrawTransformFeedback(gl.funcs, C.GLenum(mode), C.GLuint(id))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glResumeTransformFeedback.xml
+func (gl *GL) ResumeTransformFeedback() {
+ C.gl4_1compat_glResumeTransformFeedback(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPauseTransformFeedback.xml
+func (gl *GL) PauseTransformFeedback() {
+ C.gl4_1compat_glPauseTransformFeedback(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsTransformFeedback.xml
+func (gl *GL) IsTransformFeedback(id uint32) bool {
+ glresult := C.gl4_1compat_glIsTransformFeedback(gl.funcs, C.GLuint(id))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGenTransformFeedbacks.xml
+func (gl *GL) GenTransformFeedbacks(n int, ids []uint32) {
+ C.gl4_1compat_glGenTransformFeedbacks(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&ids[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDeleteTransformFeedbacks.xml
+func (gl *GL) DeleteTransformFeedbacks(n int, ids []uint32) {
+ C.gl4_1compat_glDeleteTransformFeedbacks(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&ids[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindTransformFeedback.xml
+func (gl *GL) BindTransformFeedback(target glbase.Enum, id uint32) {
+ C.gl4_1compat_glBindTransformFeedback(gl.funcs, C.GLenum(target), C.GLuint(id))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPatchParameterfv.xml
+func (gl *GL) PatchParameterfv(pname glbase.Enum, values []float32) {
+ C.gl4_1compat_glPatchParameterfv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPatchParameteri.xml
+func (gl *GL) PatchParameteri(pname glbase.Enum, value int32) {
+ C.gl4_1compat_glPatchParameteri(gl.funcs, C.GLenum(pname), C.GLint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetProgramStageiv.xml
+func (gl *GL) GetProgramStageiv(program glbase.Program, shadertype, pname glbase.Enum, values []int32) {
+ C.gl4_1compat_glGetProgramStageiv(gl.funcs, C.GLuint(program), C.GLenum(shadertype), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetUniformSubroutineuiv.xml
+func (gl *GL) GetUniformSubroutineuiv(shadertype glbase.Enum, location glbase.Uniform, params []uint32) {
+ C.gl4_1compat_glGetUniformSubroutineuiv(gl.funcs, C.GLenum(shadertype), C.GLint(location), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformSubroutinesuiv.xml
+func (gl *GL) UniformSubroutinesuiv(shadertype glbase.Enum, count int, value []uint32) {
+ C.gl4_1compat_glUniformSubroutinesuiv(gl.funcs, C.GLenum(shadertype), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveSubroutineName.xml
+func (gl *GL) GetActiveSubroutineName(program glbase.Program, shadertype glbase.Enum, index uint32, bufSize int32, length []int32, name []byte) {
+ C.gl4_1compat_glGetActiveSubroutineName(gl.funcs, C.GLuint(program), C.GLenum(shadertype), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveSubroutineUniformName.xml
+func (gl *GL) GetActiveSubroutineUniformName(program glbase.Program, shadertype glbase.Enum, index uint32, bufSize int32, length []int32, name []byte) {
+ C.gl4_1compat_glGetActiveSubroutineUniformName(gl.funcs, C.GLuint(program), C.GLenum(shadertype), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveSubroutineUniformiv.xml
+func (gl *GL) GetActiveSubroutineUniformiv(program glbase.Program, shadertype glbase.Enum, index uint32, pname glbase.Enum, values []int32) {
+ C.gl4_1compat_glGetActiveSubroutineUniformiv(gl.funcs, C.GLuint(program), C.GLenum(shadertype), C.GLuint(index), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetSubroutineIndex.xml
+func (gl *GL) GetSubroutineIndex(program glbase.Program, shadertype glbase.Enum, name []byte) uint32 {
+ glresult := C.gl4_1compat_glGetSubroutineIndex(gl.funcs, C.GLuint(program), C.GLenum(shadertype), (*C.GLchar)(unsafe.Pointer(&name[0])))
+ return uint32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetSubroutineUniformLocation.xml
+func (gl *GL) GetSubroutineUniformLocation(program glbase.Program, shadertype glbase.Enum, name []byte) int32 {
+ glresult := C.gl4_1compat_glGetSubroutineUniformLocation(gl.funcs, C.GLuint(program), C.GLenum(shadertype), (*C.GLchar)(unsafe.Pointer(&name[0])))
+ return int32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetUniformdv.xml
+func (gl *GL) GetUniformdv(program glbase.Program, location glbase.Uniform, params []float64) {
+ C.gl4_1compat_glGetUniformdv(gl.funcs, C.GLuint(program), C.GLint(location), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix4x3dv.xml
+func (gl *GL) UniformMatrix4x3dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_1compat_glUniformMatrix4x3dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix4x2dv.xml
+func (gl *GL) UniformMatrix4x2dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_1compat_glUniformMatrix4x2dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix3x4dv.xml
+func (gl *GL) UniformMatrix3x4dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_1compat_glUniformMatrix3x4dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix3x2dv.xml
+func (gl *GL) UniformMatrix3x2dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_1compat_glUniformMatrix3x2dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix2x4dv.xml
+func (gl *GL) UniformMatrix2x4dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_1compat_glUniformMatrix2x4dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix2x3dv.xml
+func (gl *GL) UniformMatrix2x3dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_1compat_glUniformMatrix2x3dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix4dv.xml
+func (gl *GL) UniformMatrix4dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_1compat_glUniformMatrix4dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix3dv.xml
+func (gl *GL) UniformMatrix3dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_1compat_glUniformMatrix3dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix2dv.xml
+func (gl *GL) UniformMatrix2dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_1compat_glUniformMatrix2dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform4dv.xml
+func (gl *GL) Uniform4dv(location glbase.Uniform, count int, value []float64) {
+ C.gl4_1compat_glUniform4dv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform3dv.xml
+func (gl *GL) Uniform3dv(location glbase.Uniform, count int, value []float64) {
+ C.gl4_1compat_glUniform3dv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform2dv.xml
+func (gl *GL) Uniform2dv(location glbase.Uniform, count int, value []float64) {
+ C.gl4_1compat_glUniform2dv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform1dv.xml
+func (gl *GL) Uniform1dv(location glbase.Uniform, count int, value []float64) {
+ C.gl4_1compat_glUniform1dv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform4d.xml
+func (gl *GL) Uniform4d(location glbase.Uniform, v0, v1, v2, v3 float64) {
+ C.gl4_1compat_glUniform4d(gl.funcs, C.GLint(location), C.GLdouble(v0), C.GLdouble(v1), C.GLdouble(v2), C.GLdouble(v3))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform3d.xml
+func (gl *GL) Uniform3d(location glbase.Uniform, v0, v1, v2 float64) {
+ C.gl4_1compat_glUniform3d(gl.funcs, C.GLint(location), C.GLdouble(v0), C.GLdouble(v1), C.GLdouble(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform2d.xml
+func (gl *GL) Uniform2d(location glbase.Uniform, v0, v1 float64) {
+ C.gl4_1compat_glUniform2d(gl.funcs, C.GLint(location), C.GLdouble(v0), C.GLdouble(v1))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform1d.xml
+func (gl *GL) Uniform1d(location glbase.Uniform, v0 float64) {
+ C.gl4_1compat_glUniform1d(gl.funcs, C.GLint(location), C.GLdouble(v0))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawElementsIndirect.xml
+func (gl *GL) DrawElementsIndirect(mode, gltype glbase.Enum, indirect interface{}) {
+ var indirect_ptr unsafe.Pointer
+ var indirect_v = reflect.ValueOf(indirect)
+ if indirect != nil && indirect_v.Kind() != reflect.Slice {
+ panic("parameter indirect must be a slice")
+ }
+ if indirect != nil {
+ indirect_ptr = unsafe.Pointer(indirect_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1compat_glDrawElementsIndirect(gl.funcs, C.GLenum(mode), C.GLenum(gltype), indirect_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawArraysIndirect.xml
+func (gl *GL) DrawArraysIndirect(mode glbase.Enum, indirect interface{}) {
+ var indirect_ptr unsafe.Pointer
+ var indirect_v = reflect.ValueOf(indirect)
+ if indirect != nil && indirect_v.Kind() != reflect.Slice {
+ panic("parameter indirect must be a slice")
+ }
+ if indirect != nil {
+ indirect_ptr = unsafe.Pointer(indirect_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1compat_glDrawArraysIndirect(gl.funcs, C.GLenum(mode), indirect_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendFuncSeparatei.xml
+func (gl *GL) BlendFuncSeparatei(buf uint32, srcRGB, dstRGB, srcAlpha, dstAlpha glbase.Enum) {
+ C.gl4_1compat_glBlendFuncSeparatei(gl.funcs, C.GLuint(buf), C.GLenum(srcRGB), C.GLenum(dstRGB), C.GLenum(srcAlpha), C.GLenum(dstAlpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendFunci.xml
+func (gl *GL) BlendFunci(buf uint32, src, dst glbase.Enum) {
+ C.gl4_1compat_glBlendFunci(gl.funcs, C.GLuint(buf), C.GLenum(src), C.GLenum(dst))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendEquationSeparatei.xml
+func (gl *GL) BlendEquationSeparatei(buf uint32, modeRGB, modeAlpha glbase.Enum) {
+ C.gl4_1compat_glBlendEquationSeparatei(gl.funcs, C.GLuint(buf), C.GLenum(modeRGB), C.GLenum(modeAlpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendEquationi.xml
+func (gl *GL) BlendEquationi(buf uint32, mode glbase.Enum) {
+ C.gl4_1compat_glBlendEquationi(gl.funcs, C.GLuint(buf), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMinSampleShading.xml
+func (gl *GL) MinSampleShading(value float32) {
+ C.gl4_1compat_glMinSampleShading(gl.funcs, C.GLfloat(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetDoublei_v.xml
+func (gl *GL) GetDoublei_v(target glbase.Enum, index uint32, data []float64) {
+ C.gl4_1compat_glGetDoublei_v(gl.funcs, C.GLenum(target), C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&data[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetFloati_v.xml
+func (gl *GL) GetFloati_v(target glbase.Enum, index uint32, data []float32) {
+ C.gl4_1compat_glGetFloati_v(gl.funcs, C.GLenum(target), C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&data[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDepthRangeIndexed.xml
+func (gl *GL) DepthRangeIndexed(index uint32, n, f float64) {
+ C.gl4_1compat_glDepthRangeIndexed(gl.funcs, C.GLuint(index), C.GLdouble(n), C.GLdouble(f))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDepthRangeArrayv.xml
+func (gl *GL) DepthRangeArrayv(first uint32, count int, v []float64) {
+ C.gl4_1compat_glDepthRangeArrayv(gl.funcs, C.GLuint(first), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glScissorIndexedv.xml
+func (gl *GL) ScissorIndexedv(index uint32, v []int32) {
+ C.gl4_1compat_glScissorIndexedv(gl.funcs, C.GLuint(index), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glScissorIndexed.xml
+func (gl *GL) ScissorIndexed(index uint32, left, bottom int32, width, height int) {
+ C.gl4_1compat_glScissorIndexed(gl.funcs, C.GLuint(index), C.GLint(left), C.GLint(bottom), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glScissorArrayv.xml
+func (gl *GL) ScissorArrayv(first uint32, count int, v []int32) {
+ C.gl4_1compat_glScissorArrayv(gl.funcs, C.GLuint(first), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glViewportIndexedfv.xml
+func (gl *GL) ViewportIndexedfv(index uint32, v []float32) {
+ C.gl4_1compat_glViewportIndexedfv(gl.funcs, C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glViewportIndexedf.xml
+func (gl *GL) ViewportIndexedf(index uint32, x, y, w, h float32) {
+ C.gl4_1compat_glViewportIndexedf(gl.funcs, C.GLuint(index), C.GLfloat(x), C.GLfloat(y), C.GLfloat(w), C.GLfloat(h))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glViewportArrayv.xml
+func (gl *GL) ViewportArrayv(first uint32, count int, v []float32) {
+ C.gl4_1compat_glViewportArrayv(gl.funcs, C.GLuint(first), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetVertexAttribLdv.xml
+func (gl *GL) GetVertexAttribLdv(index glbase.Attrib, pname glbase.Enum, params []float64) {
+ C.gl4_1compat_glGetVertexAttribLdv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribLPointer.xml
+func (gl *GL) VertexAttribLPointer(index glbase.Attrib, size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1compat_glVertexAttribLPointer(gl.funcs, C.GLuint(index), C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribL4dv.xml
+func (gl *GL) VertexAttribL4dv(index glbase.Attrib, v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glVertexAttribL4dv(gl.funcs, C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribL3dv.xml
+func (gl *GL) VertexAttribL3dv(index glbase.Attrib, v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glVertexAttribL3dv(gl.funcs, C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribL2dv.xml
+func (gl *GL) VertexAttribL2dv(index glbase.Attrib, v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glVertexAttribL2dv(gl.funcs, C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribL1dv.xml
+func (gl *GL) VertexAttribL1dv(index glbase.Attrib, v []float64) {
+ C.gl4_1compat_glVertexAttribL1dv(gl.funcs, C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribL4d.xml
+func (gl *GL) VertexAttribL4d(index glbase.Attrib, x, y, z, w float64) {
+ C.gl4_1compat_glVertexAttribL4d(gl.funcs, C.GLuint(index), C.GLdouble(x), C.GLdouble(y), C.GLdouble(z), C.GLdouble(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribL3d.xml
+func (gl *GL) VertexAttribL3d(index glbase.Attrib, x, y, z float64) {
+ C.gl4_1compat_glVertexAttribL3d(gl.funcs, C.GLuint(index), C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribL2d.xml
+func (gl *GL) VertexAttribL2d(index glbase.Attrib, x, y float64) {
+ C.gl4_1compat_glVertexAttribL2d(gl.funcs, C.GLuint(index), C.GLdouble(x), C.GLdouble(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribL1d.xml
+func (gl *GL) VertexAttribL1d(index glbase.Attrib, x float64) {
+ C.gl4_1compat_glVertexAttribL1d(gl.funcs, C.GLuint(index), C.GLdouble(x))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetProgramPipelineInfoLog.xml
+func (gl *GL) GetProgramPipelineInfoLog(pipeline uint32, bufSize int32, length []int32, infoLog []byte) {
+ C.gl4_1compat_glGetProgramPipelineInfoLog(gl.funcs, C.GLuint(pipeline), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&infoLog[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glValidateProgramPipeline.xml
+func (gl *GL) ValidateProgramPipeline(pipeline uint32) {
+ C.gl4_1compat_glValidateProgramPipeline(gl.funcs, C.GLuint(pipeline))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix4x3dv.xml
+func (gl *GL) ProgramUniformMatrix4x3dv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float64) {
+ if len(value) != 3 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_1compat_glProgramUniformMatrix4x3dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix3x4dv.xml
+func (gl *GL) ProgramUniformMatrix3x4dv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float64) {
+ if len(value) != 4 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_1compat_glProgramUniformMatrix3x4dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix4x2dv.xml
+func (gl *GL) ProgramUniformMatrix4x2dv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float64) {
+ if len(value) != 2 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_1compat_glProgramUniformMatrix4x2dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix2x4dv.xml
+func (gl *GL) ProgramUniformMatrix2x4dv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float64) {
+ if len(value) != 4 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_1compat_glProgramUniformMatrix2x4dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix3x2dv.xml
+func (gl *GL) ProgramUniformMatrix3x2dv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float64) {
+ if len(value) != 2 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_1compat_glProgramUniformMatrix3x2dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix2x3dv.xml
+func (gl *GL) ProgramUniformMatrix2x3dv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float64) {
+ if len(value) != 3 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_1compat_glProgramUniformMatrix2x3dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix4x3fv.xml
+func (gl *GL) ProgramUniformMatrix4x3fv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float32) {
+ if len(value) != 3 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_1compat_glProgramUniformMatrix4x3fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix3x4fv.xml
+func (gl *GL) ProgramUniformMatrix3x4fv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float32) {
+ if len(value) != 4 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_1compat_glProgramUniformMatrix3x4fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix4x2fv.xml
+func (gl *GL) ProgramUniformMatrix4x2fv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float32) {
+ if len(value) != 2 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_1compat_glProgramUniformMatrix4x2fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix2x4fv.xml
+func (gl *GL) ProgramUniformMatrix2x4fv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float32) {
+ if len(value) != 4 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_1compat_glProgramUniformMatrix2x4fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix3x2fv.xml
+func (gl *GL) ProgramUniformMatrix3x2fv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float32) {
+ if len(value) != 2 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_1compat_glProgramUniformMatrix3x2fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix2x3fv.xml
+func (gl *GL) ProgramUniformMatrix2x3fv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float32) {
+ if len(value) != 3 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_1compat_glProgramUniformMatrix2x3fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix4dv.xml
+func (gl *GL) ProgramUniformMatrix4dv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float64) {
+ if len(value) != 4 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_1compat_glProgramUniformMatrix4dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix3dv.xml
+func (gl *GL) ProgramUniformMatrix3dv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float64) {
+ if len(value) != 3 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_1compat_glProgramUniformMatrix3dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix2dv.xml
+func (gl *GL) ProgramUniformMatrix2dv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float64) {
+ if len(value) != 2 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_1compat_glProgramUniformMatrix2dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix4fv.xml
+func (gl *GL) ProgramUniformMatrix4fv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float32) {
+ if len(value) != 4 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_1compat_glProgramUniformMatrix4fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix3fv.xml
+func (gl *GL) ProgramUniformMatrix3fv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float32) {
+ if len(value) != 3 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_1compat_glProgramUniformMatrix3fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix2fv.xml
+func (gl *GL) ProgramUniformMatrix2fv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float32) {
+ if len(value) != 2 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_1compat_glProgramUniformMatrix2fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform4uiv.xml
+func (gl *GL) ProgramUniform4uiv(program glbase.Program, location glbase.Uniform, count int, value []uint32) {
+ C.gl4_1compat_glProgramUniform4uiv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform4ui.xml
+func (gl *GL) ProgramUniform4ui(program glbase.Program, location glbase.Uniform, v0, v1, v2, v3 uint32) {
+ C.gl4_1compat_glProgramUniform4ui(gl.funcs, C.GLuint(program), C.GLint(location), C.GLuint(v0), C.GLuint(v1), C.GLuint(v2), C.GLuint(v3))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform4dv.xml
+func (gl *GL) ProgramUniform4dv(program glbase.Program, location glbase.Uniform, count int, value []float64) {
+ if len(value) != 4 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_1compat_glProgramUniform4dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform4d.xml
+func (gl *GL) ProgramUniform4d(program glbase.Program, location glbase.Uniform, v0, v1, v2, v3 float64) {
+ C.gl4_1compat_glProgramUniform4d(gl.funcs, C.GLuint(program), C.GLint(location), C.GLdouble(v0), C.GLdouble(v1), C.GLdouble(v2), C.GLdouble(v3))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform4fv.xml
+func (gl *GL) ProgramUniform4fv(program glbase.Program, location glbase.Uniform, count int, value []float32) {
+ if len(value) != 4 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_1compat_glProgramUniform4fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform4f.xml
+func (gl *GL) ProgramUniform4f(program glbase.Program, location glbase.Uniform, v0, v1, v2, v3 float32) {
+ C.gl4_1compat_glProgramUniform4f(gl.funcs, C.GLuint(program), C.GLint(location), C.GLfloat(v0), C.GLfloat(v1), C.GLfloat(v2), C.GLfloat(v3))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform4iv.xml
+func (gl *GL) ProgramUniform4iv(program glbase.Program, location glbase.Uniform, count int, value []int32) {
+ if len(value) != 4 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_1compat_glProgramUniform4iv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform4i.xml
+func (gl *GL) ProgramUniform4i(program glbase.Program, location glbase.Uniform, v0, v1, v2, v3 int32) {
+ C.gl4_1compat_glProgramUniform4i(gl.funcs, C.GLuint(program), C.GLint(location), C.GLint(v0), C.GLint(v1), C.GLint(v2), C.GLint(v3))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform3uiv.xml
+func (gl *GL) ProgramUniform3uiv(program glbase.Program, location glbase.Uniform, count int, value []uint32) {
+ C.gl4_1compat_glProgramUniform3uiv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform3ui.xml
+func (gl *GL) ProgramUniform3ui(program glbase.Program, location glbase.Uniform, v0, v1, v2 uint32) {
+ C.gl4_1compat_glProgramUniform3ui(gl.funcs, C.GLuint(program), C.GLint(location), C.GLuint(v0), C.GLuint(v1), C.GLuint(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform3dv.xml
+func (gl *GL) ProgramUniform3dv(program glbase.Program, location glbase.Uniform, count int, value []float64) {
+ if len(value) != 3 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_1compat_glProgramUniform3dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform3d.xml
+func (gl *GL) ProgramUniform3d(program glbase.Program, location glbase.Uniform, v0, v1, v2 float64) {
+ C.gl4_1compat_glProgramUniform3d(gl.funcs, C.GLuint(program), C.GLint(location), C.GLdouble(v0), C.GLdouble(v1), C.GLdouble(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform3fv.xml
+func (gl *GL) ProgramUniform3fv(program glbase.Program, location glbase.Uniform, count int, value []float32) {
+ if len(value) != 3 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_1compat_glProgramUniform3fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform3f.xml
+func (gl *GL) ProgramUniform3f(program glbase.Program, location glbase.Uniform, v0, v1, v2 float32) {
+ C.gl4_1compat_glProgramUniform3f(gl.funcs, C.GLuint(program), C.GLint(location), C.GLfloat(v0), C.GLfloat(v1), C.GLfloat(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform3iv.xml
+func (gl *GL) ProgramUniform3iv(program glbase.Program, location glbase.Uniform, count int, value []int32) {
+ if len(value) != 3 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_1compat_glProgramUniform3iv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform3i.xml
+func (gl *GL) ProgramUniform3i(program glbase.Program, location glbase.Uniform, v0, v1, v2 int32) {
+ C.gl4_1compat_glProgramUniform3i(gl.funcs, C.GLuint(program), C.GLint(location), C.GLint(v0), C.GLint(v1), C.GLint(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform2uiv.xml
+func (gl *GL) ProgramUniform2uiv(program glbase.Program, location glbase.Uniform, count int, value []uint32) {
+ C.gl4_1compat_glProgramUniform2uiv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform2ui.xml
+func (gl *GL) ProgramUniform2ui(program glbase.Program, location glbase.Uniform, v0, v1 uint32) {
+ C.gl4_1compat_glProgramUniform2ui(gl.funcs, C.GLuint(program), C.GLint(location), C.GLuint(v0), C.GLuint(v1))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform2dv.xml
+func (gl *GL) ProgramUniform2dv(program glbase.Program, location glbase.Uniform, count int, value []float64) {
+ if len(value) != 2 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_1compat_glProgramUniform2dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform2d.xml
+func (gl *GL) ProgramUniform2d(program glbase.Program, location glbase.Uniform, v0, v1 float64) {
+ C.gl4_1compat_glProgramUniform2d(gl.funcs, C.GLuint(program), C.GLint(location), C.GLdouble(v0), C.GLdouble(v1))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform2fv.xml
+func (gl *GL) ProgramUniform2fv(program glbase.Program, location glbase.Uniform, count int, value []float32) {
+ if len(value) != 2 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_1compat_glProgramUniform2fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform2f.xml
+func (gl *GL) ProgramUniform2f(program glbase.Program, location glbase.Uniform, v0, v1 float32) {
+ C.gl4_1compat_glProgramUniform2f(gl.funcs, C.GLuint(program), C.GLint(location), C.GLfloat(v0), C.GLfloat(v1))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform2iv.xml
+func (gl *GL) ProgramUniform2iv(program glbase.Program, location glbase.Uniform, count int, value []int32) {
+ if len(value) != 2 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_1compat_glProgramUniform2iv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform2i.xml
+func (gl *GL) ProgramUniform2i(program glbase.Program, location glbase.Uniform, v0, v1 int32) {
+ C.gl4_1compat_glProgramUniform2i(gl.funcs, C.GLuint(program), C.GLint(location), C.GLint(v0), C.GLint(v1))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform1uiv.xml
+func (gl *GL) ProgramUniform1uiv(program glbase.Program, location glbase.Uniform, count int, value []uint32) {
+ C.gl4_1compat_glProgramUniform1uiv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform1ui.xml
+func (gl *GL) ProgramUniform1ui(program glbase.Program, location glbase.Uniform, v0 uint32) {
+ C.gl4_1compat_glProgramUniform1ui(gl.funcs, C.GLuint(program), C.GLint(location), C.GLuint(v0))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform1dv.xml
+func (gl *GL) ProgramUniform1dv(program glbase.Program, location glbase.Uniform, count int, value []float64) {
+ C.gl4_1compat_glProgramUniform1dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform1d.xml
+func (gl *GL) ProgramUniform1d(program glbase.Program, location glbase.Uniform, v0 float64) {
+ C.gl4_1compat_glProgramUniform1d(gl.funcs, C.GLuint(program), C.GLint(location), C.GLdouble(v0))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform1fv.xml
+func (gl *GL) ProgramUniform1fv(program glbase.Program, location glbase.Uniform, count int, value []float32) {
+ C.gl4_1compat_glProgramUniform1fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform1f.xml
+func (gl *GL) ProgramUniform1f(program glbase.Program, location glbase.Uniform, v0 float32) {
+ C.gl4_1compat_glProgramUniform1f(gl.funcs, C.GLuint(program), C.GLint(location), C.GLfloat(v0))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform1iv.xml
+func (gl *GL) ProgramUniform1iv(program glbase.Program, location glbase.Uniform, count int, value []int32) {
+ C.gl4_1compat_glProgramUniform1iv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform1i.xml
+func (gl *GL) ProgramUniform1i(program glbase.Program, location glbase.Uniform, v0 int32) {
+ C.gl4_1compat_glProgramUniform1i(gl.funcs, C.GLuint(program), C.GLint(location), C.GLint(v0))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetProgramPipelineiv.xml
+func (gl *GL) GetProgramPipelineiv(pipeline uint32, pname glbase.Enum, params []int32) {
+ C.gl4_1compat_glGetProgramPipelineiv(gl.funcs, C.GLuint(pipeline), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsProgramPipeline.xml
+func (gl *GL) IsProgramPipeline(pipeline uint32) bool {
+ glresult := C.gl4_1compat_glIsProgramPipeline(gl.funcs, C.GLuint(pipeline))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGenProgramPipelines.xml
+func (gl *GL) GenProgramPipelines(n int, pipelines []uint32) {
+ C.gl4_1compat_glGenProgramPipelines(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&pipelines[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDeleteProgramPipelines.xml
+func (gl *GL) DeleteProgramPipelines(n int, pipelines []uint32) {
+ C.gl4_1compat_glDeleteProgramPipelines(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&pipelines[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindProgramPipeline.xml
+func (gl *GL) BindProgramPipeline(pipeline uint32) {
+ C.gl4_1compat_glBindProgramPipeline(gl.funcs, C.GLuint(pipeline))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glActiveShaderProgram.xml
+func (gl *GL) ActiveShaderProgram(pipeline uint32, program glbase.Program) {
+ C.gl4_1compat_glActiveShaderProgram(gl.funcs, C.GLuint(pipeline), C.GLuint(program))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUseProgramStages.xml
+func (gl *GL) UseProgramStages(pipeline uint32, stages glbase.Bitfield, program glbase.Program) {
+ C.gl4_1compat_glUseProgramStages(gl.funcs, C.GLuint(pipeline), C.GLbitfield(stages), C.GLuint(program))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramParameteri.xml
+func (gl *GL) ProgramParameteri(program glbase.Program, pname glbase.Enum, value int32) {
+ C.gl4_1compat_glProgramParameteri(gl.funcs, C.GLuint(program), C.GLenum(pname), C.GLint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramBinary.xml
+func (gl *GL) ProgramBinary(program glbase.Program, binaryFormat glbase.Enum, binary interface{}, length int32) {
+ var binary_ptr unsafe.Pointer
+ var binary_v = reflect.ValueOf(binary)
+ if binary != nil && binary_v.Kind() != reflect.Slice {
+ panic("parameter binary must be a slice")
+ }
+ if binary != nil {
+ binary_ptr = unsafe.Pointer(binary_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1compat_glProgramBinary(gl.funcs, C.GLuint(program), C.GLenum(binaryFormat), binary_ptr, C.GLsizei(length))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetProgramBinary.xml
+func (gl *GL) GetProgramBinary(program glbase.Program, bufSize int32, length []int32, binaryFormat []glbase.Enum, binary interface{}) {
+ var binary_ptr unsafe.Pointer
+ var binary_v = reflect.ValueOf(binary)
+ if binary != nil && binary_v.Kind() != reflect.Slice {
+ panic("parameter binary must be a slice")
+ }
+ if binary != nil {
+ binary_ptr = unsafe.Pointer(binary_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1compat_glGetProgramBinary(gl.funcs, C.GLuint(program), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLenum)(unsafe.Pointer(&binaryFormat[0])), binary_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearDepthf.xml
+func (gl *GL) ClearDepthf(dd float32) {
+ C.gl4_1compat_glClearDepthf(gl.funcs, C.GLfloat(dd))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDepthRangef.xml
+func (gl *GL) DepthRangef(n, f float32) {
+ C.gl4_1compat_glDepthRangef(gl.funcs, C.GLfloat(n), C.GLfloat(f))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetShaderPrecisionFormat.xml
+func (gl *GL) GetShaderPrecisionFormat(shadertype, precisionType glbase.Enum, range_, precision []int32) {
+ C.gl4_1compat_glGetShaderPrecisionFormat(gl.funcs, C.GLenum(shadertype), C.GLenum(precisionType), (*C.GLint)(unsafe.Pointer(&range_[0])), (*C.GLint)(unsafe.Pointer(&precision[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glShaderBinary.xml
+func (gl *GL) ShaderBinary(count int, shaders []glbase.Shader, binaryFormat glbase.Enum, binary interface{}, length int32) {
+ var binary_ptr unsafe.Pointer
+ var binary_v = reflect.ValueOf(binary)
+ if binary != nil && binary_v.Kind() != reflect.Slice {
+ panic("parameter binary must be a slice")
+ }
+ if binary != nil {
+ binary_ptr = unsafe.Pointer(binary_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1compat_glShaderBinary(gl.funcs, C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&shaders[0])), C.GLenum(binaryFormat), binary_ptr, C.GLsizei(length))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glReleaseShaderCompiler.xml
+func (gl *GL) ReleaseShaderCompiler() {
+ C.gl4_1compat_glReleaseShaderCompiler(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTranslatef.xml
+func (gl *GL) Translatef(x, y, z float32) {
+ C.gl4_1compat_glTranslatef(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTranslated.xml
+func (gl *GL) Translated(x, y, z float64) {
+ C.gl4_1compat_glTranslated(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glScalef.xml
+func (gl *GL) Scalef(x, y, z float32) {
+ C.gl4_1compat_glScalef(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glScaled.xml
+func (gl *GL) Scaled(x, y, z float64) {
+ C.gl4_1compat_glScaled(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRotatef.xml
+func (gl *GL) Rotatef(angle, x, y, z float32) {
+ C.gl4_1compat_glRotatef(gl.funcs, C.GLfloat(angle), C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRotated.xml
+func (gl *GL) Rotated(angle, x, y, z float64) {
+ C.gl4_1compat_glRotated(gl.funcs, C.GLdouble(angle), C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPushMatrix.xml
+func (gl *GL) PushMatrix() {
+ C.gl4_1compat_glPushMatrix(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPopMatrix.xml
+func (gl *GL) PopMatrix() {
+ C.gl4_1compat_glPopMatrix(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glOrtho.xml
+func (gl *GL) Ortho(left, right, bottom, top, zNear, zFar float64) {
+ C.gl4_1compat_glOrtho(gl.funcs, C.GLdouble(left), C.GLdouble(right), C.GLdouble(bottom), C.GLdouble(top), C.GLdouble(zNear), C.GLdouble(zFar))
+}
+
+// MultMatrixd multiplies the current matrix with the provided matrix.
+//
+// The m parameter must hold 16 consecutive elements of a 4x4 column-major matrix.
+//
+// The current matrix is determined by the current matrix mode (see
+// MatrixMode). It is either the projection matrix, modelview matrix, or the
+// texture matrix.
+//
+// For example, if the current matrix is C and the coordinates to be transformed
+// are v = (v[0], v[1], v[2], v[3]), then the current transformation is C × v, or
+//
+// c[0] c[4] c[8] c[12] v[0]
+// c[1] c[5] c[9] c[13] v[1]
+// c[2] c[6] c[10] c[14] X v[2]
+// c[3] c[7] c[11] c[15] v[3]
+//
+// Calling MultMatrix with an argument of m = m[0], m[1], ..., m[15]
+// replaces the current transformation with (C X M) x v, or
+//
+// c[0] c[4] c[8] c[12] m[0] m[4] m[8] m[12] v[0]
+// c[1] c[5] c[9] c[13] m[1] m[5] m[9] m[13] v[1]
+// c[2] c[6] c[10] c[14] X m[2] m[6] m[10] m[14] X v[2]
+// c[3] c[7] c[11] c[15] m[3] m[7] m[11] m[15] v[3]
+//
+// Where 'X' denotes matrix multiplication, and v is represented as a 4x1 matrix.
+//
+// While the elements of the matrix may be specified with single or double
+// precision, the GL may store or operate on these values in less-than-single
+// precision.
+//
+// In many computer languages, 4×4 arrays are represented in row-major
+// order. The transformations just described represent these matrices in
+// column-major order. The order of the multiplication is important. For
+// example, if the current transformation is a rotation, and MultMatrix is
+// called with a translation matrix, the translation is done directly on the
+// coordinates to be transformed, while the rotation is done on the results
+// of that translation.
+//
+// GL.INVALID_OPERATION is generated if MultMatrix is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) MultMatrixd(m []float64) {
+ if len(m) != 16 {
+ panic("parameter m must have length 16 for the 4x4 matrix")
+ }
+ C.gl4_1compat_glMultMatrixd(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&m[0])))
+}
+
+// MultMatrixf multiplies the current matrix with the provided matrix.
+//
+// The m parameter must hold 16 consecutive elements of a 4x4 column-major matrix.
+//
+// The current matrix is determined by the current matrix mode (see
+// MatrixMode). It is either the projection matrix, modelview matrix, or the
+// texture matrix.
+//
+// For example, if the current matrix is C and the coordinates to be transformed
+// are v = (v[0], v[1], v[2], v[3]), then the current transformation is C × v, or
+//
+// c[0] c[4] c[8] c[12] v[0]
+// c[1] c[5] c[9] c[13] v[1]
+// c[2] c[6] c[10] c[14] X v[2]
+// c[3] c[7] c[11] c[15] v[3]
+//
+// Calling MultMatrix with an argument of m = m[0], m[1], ..., m[15]
+// replaces the current transformation with (C X M) x v, or
+//
+// c[0] c[4] c[8] c[12] m[0] m[4] m[8] m[12] v[0]
+// c[1] c[5] c[9] c[13] m[1] m[5] m[9] m[13] v[1]
+// c[2] c[6] c[10] c[14] X m[2] m[6] m[10] m[14] X v[2]
+// c[3] c[7] c[11] c[15] m[3] m[7] m[11] m[15] v[3]
+//
+// Where 'X' denotes matrix multiplication, and v is represented as a 4x1 matrix.
+//
+// While the elements of the matrix may be specified with single or double
+// precision, the GL may store or operate on these values in less-than-single
+// precision.
+//
+// In many computer languages, 4×4 arrays are represented in row-major
+// order. The transformations just described represent these matrices in
+// column-major order. The order of the multiplication is important. For
+// example, if the current transformation is a rotation, and MultMatrix is
+// called with a translation matrix, the translation is done directly on the
+// coordinates to be transformed, while the rotation is done on the results
+// of that translation.
+//
+// GL.INVALID_OPERATION is generated if MultMatrix is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) MultMatrixf(m []float32) {
+ if len(m) != 16 {
+ panic("parameter m must have length 16 for the 4x4 matrix")
+ }
+ C.gl4_1compat_glMultMatrixf(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMatrixMode.xml
+func (gl *GL) MatrixMode(mode glbase.Enum) {
+ C.gl4_1compat_glMatrixMode(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLoadMatrixd.xml
+func (gl *GL) LoadMatrixd(m []float64) {
+ C.gl4_1compat_glLoadMatrixd(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLoadMatrixf.xml
+func (gl *GL) LoadMatrixf(m []float32) {
+ C.gl4_1compat_glLoadMatrixf(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLoadIdentity.xml
+func (gl *GL) LoadIdentity() {
+ C.gl4_1compat_glLoadIdentity(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFrustum.xml
+func (gl *GL) Frustum(left, right, bottom, top, zNear, zFar float64) {
+ C.gl4_1compat_glFrustum(gl.funcs, C.GLdouble(left), C.GLdouble(right), C.GLdouble(bottom), C.GLdouble(top), C.GLdouble(zNear), C.GLdouble(zFar))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsList.xml
+func (gl *GL) IsList(list uint32) bool {
+ glresult := C.gl4_1compat_glIsList(gl.funcs, C.GLuint(list))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexGeniv.xml
+func (gl *GL) GetTexGeniv(coord, pname glbase.Enum, params []int32) {
+ C.gl4_1compat_glGetTexGeniv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexGenfv.xml
+func (gl *GL) GetTexGenfv(coord, pname glbase.Enum, params []float32) {
+ C.gl4_1compat_glGetTexGenfv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexGendv.xml
+func (gl *GL) GetTexGendv(coord, pname glbase.Enum, params []float64) {
+ C.gl4_1compat_glGetTexGendv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexEnviv.xml
+func (gl *GL) GetTexEnviv(target, pname glbase.Enum, params []int32) {
+ C.gl4_1compat_glGetTexEnviv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexEnvfv.xml
+func (gl *GL) GetTexEnvfv(target, pname glbase.Enum, params []float32) {
+ C.gl4_1compat_glGetTexEnvfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetPolygonStipple.xml
+func (gl *GL) GetPolygonStipple(mask []uint8) {
+ C.gl4_1compat_glGetPolygonStipple(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&mask[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetPixelMapusv.xml
+func (gl *GL) GetPixelMapusv(glmap glbase.Enum, values []uint16) {
+ C.gl4_1compat_glGetPixelMapusv(gl.funcs, C.GLenum(glmap), (*C.GLushort)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetPixelMapuiv.xml
+func (gl *GL) GetPixelMapuiv(glmap glbase.Enum, values []uint32) {
+ C.gl4_1compat_glGetPixelMapuiv(gl.funcs, C.GLenum(glmap), (*C.GLuint)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetPixelMapfv.xml
+func (gl *GL) GetPixelMapfv(glmap glbase.Enum, values []float32) {
+ C.gl4_1compat_glGetPixelMapfv(gl.funcs, C.GLenum(glmap), (*C.GLfloat)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetMaterialiv.xml
+func (gl *GL) GetMaterialiv(face, pname glbase.Enum, params []int32) {
+ C.gl4_1compat_glGetMaterialiv(gl.funcs, C.GLenum(face), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetMaterialfv.xml
+func (gl *GL) GetMaterialfv(face, pname glbase.Enum, params []float32) {
+ C.gl4_1compat_glGetMaterialfv(gl.funcs, C.GLenum(face), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetMapiv.xml
+func (gl *GL) GetMapiv(target, query glbase.Enum, v []int32) {
+ C.gl4_1compat_glGetMapiv(gl.funcs, C.GLenum(target), C.GLenum(query), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetMapfv.xml
+func (gl *GL) GetMapfv(target, query glbase.Enum, v []float32) {
+ C.gl4_1compat_glGetMapfv(gl.funcs, C.GLenum(target), C.GLenum(query), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetMapdv.xml
+func (gl *GL) GetMapdv(target, query glbase.Enum, v []float64) {
+ C.gl4_1compat_glGetMapdv(gl.funcs, C.GLenum(target), C.GLenum(query), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetLightiv.xml
+func (gl *GL) GetLightiv(light, pname glbase.Enum, params []int32) {
+ C.gl4_1compat_glGetLightiv(gl.funcs, C.GLenum(light), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetLightfv.xml
+func (gl *GL) GetLightfv(light, pname glbase.Enum, params []float32) {
+ C.gl4_1compat_glGetLightfv(gl.funcs, C.GLenum(light), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetClipPlane.xml
+func (gl *GL) GetClipPlane(plane glbase.Enum, equation []float64) {
+ C.gl4_1compat_glGetClipPlane(gl.funcs, C.GLenum(plane), (*C.GLdouble)(unsafe.Pointer(&equation[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawPixels.xml
+func (gl *GL) DrawPixels(width, height int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1compat_glDrawPixels(gl.funcs, C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyPixels.xml
+func (gl *GL) CopyPixels(x, y, width, height int, gltype glbase.Enum) {
+ C.gl4_1compat_glCopyPixels(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height), C.GLenum(gltype))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPixelMapusv.xml
+func (gl *GL) PixelMapusv(glmap glbase.Enum, mapsize int32, values []uint16) {
+ C.gl4_1compat_glPixelMapusv(gl.funcs, C.GLenum(glmap), C.GLint(mapsize), (*C.GLushort)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPixelMapuiv.xml
+func (gl *GL) PixelMapuiv(glmap glbase.Enum, mapsize int32, values []uint32) {
+ C.gl4_1compat_glPixelMapuiv(gl.funcs, C.GLenum(glmap), C.GLint(mapsize), (*C.GLuint)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPixelMapfv.xml
+func (gl *GL) PixelMapfv(glmap glbase.Enum, mapsize int32, values []float32) {
+ C.gl4_1compat_glPixelMapfv(gl.funcs, C.GLenum(glmap), C.GLint(mapsize), (*C.GLfloat)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPixelTransferi.xml
+func (gl *GL) PixelTransferi(pname glbase.Enum, param int32) {
+ C.gl4_1compat_glPixelTransferi(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPixelTransferf.xml
+func (gl *GL) PixelTransferf(pname glbase.Enum, param float32) {
+ C.gl4_1compat_glPixelTransferf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPixelZoom.xml
+func (gl *GL) PixelZoom(xfactor, yfactor float32) {
+ C.gl4_1compat_glPixelZoom(gl.funcs, C.GLfloat(xfactor), C.GLfloat(yfactor))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glAlphaFunc.xml
+func (gl *GL) AlphaFunc(glfunc glbase.Enum, ref float32) {
+ C.gl4_1compat_glAlphaFunc(gl.funcs, C.GLenum(glfunc), C.GLfloat(ref))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEvalPoint2.xml
+func (gl *GL) EvalPoint2(i, j int32) {
+ C.gl4_1compat_glEvalPoint2(gl.funcs, C.GLint(i), C.GLint(j))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEvalMesh2.xml
+func (gl *GL) EvalMesh2(mode glbase.Enum, i1, i2, j1, j2 int32) {
+ C.gl4_1compat_glEvalMesh2(gl.funcs, C.GLenum(mode), C.GLint(i1), C.GLint(i2), C.GLint(j1), C.GLint(j2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEvalPoint1.xml
+func (gl *GL) EvalPoint1(i int32) {
+ C.gl4_1compat_glEvalPoint1(gl.funcs, C.GLint(i))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEvalMesh1.xml
+func (gl *GL) EvalMesh1(mode glbase.Enum, i1, i2 int32) {
+ C.gl4_1compat_glEvalMesh1(gl.funcs, C.GLenum(mode), C.GLint(i1), C.GLint(i2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEvalCoord2fv.xml
+func (gl *GL) EvalCoord2fv(u []float32) {
+ if len(u) != 2 {
+ panic("parameter u has incorrect length")
+ }
+ C.gl4_1compat_glEvalCoord2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&u[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEvalCoord2f.xml
+func (gl *GL) EvalCoord2f(u, v float32) {
+ C.gl4_1compat_glEvalCoord2f(gl.funcs, C.GLfloat(u), C.GLfloat(v))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEvalCoord2dv.xml
+func (gl *GL) EvalCoord2dv(u []float64) {
+ if len(u) != 2 {
+ panic("parameter u has incorrect length")
+ }
+ C.gl4_1compat_glEvalCoord2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&u[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEvalCoord2d.xml
+func (gl *GL) EvalCoord2d(u, v float64) {
+ C.gl4_1compat_glEvalCoord2d(gl.funcs, C.GLdouble(u), C.GLdouble(v))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEvalCoord1fv.xml
+func (gl *GL) EvalCoord1fv(u []float32) {
+ C.gl4_1compat_glEvalCoord1fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&u[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEvalCoord1f.xml
+func (gl *GL) EvalCoord1f(u float32) {
+ C.gl4_1compat_glEvalCoord1f(gl.funcs, C.GLfloat(u))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEvalCoord1dv.xml
+func (gl *GL) EvalCoord1dv(u []float64) {
+ C.gl4_1compat_glEvalCoord1dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&u[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEvalCoord1d.xml
+func (gl *GL) EvalCoord1d(u float64) {
+ C.gl4_1compat_glEvalCoord1d(gl.funcs, C.GLdouble(u))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMapGrid2f.xml
+func (gl *GL) MapGrid2f(un int32, u1, u2 float32, vn int32, v1, v2 float32) {
+ C.gl4_1compat_glMapGrid2f(gl.funcs, C.GLint(un), C.GLfloat(u1), C.GLfloat(u2), C.GLint(vn), C.GLfloat(v1), C.GLfloat(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMapGrid2d.xml
+func (gl *GL) MapGrid2d(un int32, u1, u2 float64, vn int32, v1, v2 float64) {
+ C.gl4_1compat_glMapGrid2d(gl.funcs, C.GLint(un), C.GLdouble(u1), C.GLdouble(u2), C.GLint(vn), C.GLdouble(v1), C.GLdouble(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMapGrid1f.xml
+func (gl *GL) MapGrid1f(un int32, u1, u2 float32) {
+ C.gl4_1compat_glMapGrid1f(gl.funcs, C.GLint(un), C.GLfloat(u1), C.GLfloat(u2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMapGrid1d.xml
+func (gl *GL) MapGrid1d(un int32, u1, u2 float64) {
+ C.gl4_1compat_glMapGrid1d(gl.funcs, C.GLint(un), C.GLdouble(u1), C.GLdouble(u2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMap2f.xml
+func (gl *GL) Map2f(target glbase.Enum, u1, u2 float32, ustride, uorder int32, v1, v2 float32, vstride, vorder int32, points []float32) {
+ C.gl4_1compat_glMap2f(gl.funcs, C.GLenum(target), C.GLfloat(u1), C.GLfloat(u2), C.GLint(ustride), C.GLint(uorder), C.GLfloat(v1), C.GLfloat(v2), C.GLint(vstride), C.GLint(vorder), (*C.GLfloat)(unsafe.Pointer(&points[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMap2d.xml
+func (gl *GL) Map2d(target glbase.Enum, u1, u2 float64, ustride, uorder int32, v1, v2 float64, vstride, vorder int32, points []float64) {
+ C.gl4_1compat_glMap2d(gl.funcs, C.GLenum(target), C.GLdouble(u1), C.GLdouble(u2), C.GLint(ustride), C.GLint(uorder), C.GLdouble(v1), C.GLdouble(v2), C.GLint(vstride), C.GLint(vorder), (*C.GLdouble)(unsafe.Pointer(&points[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMap1f.xml
+func (gl *GL) Map1f(target glbase.Enum, u1, u2 float32, stride, order int, points []float32) {
+ C.gl4_1compat_glMap1f(gl.funcs, C.GLenum(target), C.GLfloat(u1), C.GLfloat(u2), C.GLint(stride), C.GLint(order), (*C.GLfloat)(unsafe.Pointer(&points[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMap1d.xml
+func (gl *GL) Map1d(target glbase.Enum, u1, u2 float64, stride, order int, points []float64) {
+ C.gl4_1compat_glMap1d(gl.funcs, C.GLenum(target), C.GLdouble(u1), C.GLdouble(u2), C.GLint(stride), C.GLint(order), (*C.GLdouble)(unsafe.Pointer(&points[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPushAttrib.xml
+func (gl *GL) PushAttrib(mask glbase.Bitfield) {
+ C.gl4_1compat_glPushAttrib(gl.funcs, C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPopAttrib.xml
+func (gl *GL) PopAttrib() {
+ C.gl4_1compat_glPopAttrib(gl.funcs)
+}
+
+// Accum executes an operation on the accumulation buffer.
+//
+// Parameter op defines the accumulation buffer operation (GL.ACCUM, GL.LOAD,
+// GL.ADD, GL.MULT, or GL.RETURN) and specifies how the value parameter is
+// used.
+//
+// The accumulation buffer is an extended-range color buffer. Images are not
+// rendered into it. Rather, images rendered into one of the color buffers
+// are added to the contents of the accumulation buffer after rendering.
+// Effects such as antialiasing (of points, lines, and polygons), motion
+// blur, and depth of field can be created by accumulating images generated
+// with different transformation matrices.
+//
+// Each pixel in the accumulation buffer consists of red, green, blue, and
+// alpha values. The number of bits per component in the accumulation buffer
+// depends on the implementation. You can examine this number by calling
+// GetIntegerv four times, with arguments GL.ACCUM_RED_BITS,
+// GL.ACCUM_GREEN_BITS, GL.ACCUM_BLUE_BITS, and GL.ACCUM_ALPHA_BITS.
+// Regardless of the number of bits per component, the range of values stored
+// by each component is (-1, 1). The accumulation buffer pixels are mapped
+// one-to-one with frame buffer pixels.
+//
+// All accumulation buffer operations are limited to the area of the current
+// scissor box and applied identically to the red, green, blue, and alpha
+// components of each pixel. If a Accum operation results in a value outside
+// the range (-1, 1), the contents of an accumulation buffer pixel component
+// are undefined.
+//
+// The operations are as follows:
+//
+// GL.ACCUM
+// Obtains R, G, B, and A values from the buffer currently selected for
+// reading (see ReadBuffer). Each component value is divided by 2 n -
+// 1 , where n is the number of bits allocated to each color component
+// in the currently selected buffer. The result is a floating-point
+// value in the range 0 1 , which is multiplied by value and added to
+// the corresponding pixel component in the accumulation buffer,
+// thereby updating the accumulation buffer.
+//
+// GL.LOAD
+// Similar to GL.ACCUM, except that the current value in the
+// accumulation buffer is not used in the calculation of the new value.
+// That is, the R, G, B, and A values from the currently selected
+// buffer are divided by 2 n - 1 , multiplied by value, and then stored
+// in the corresponding accumulation buffer cell, overwriting the
+// current value.
+//
+// GL.ADD
+// Adds value to each R, G, B, and A in the accumulation buffer.
+//
+// GL.MULT
+// Multiplies each R, G, B, and A in the accumulation buffer by value
+// and returns the scaled component to its corresponding accumulation
+// buffer location.
+//
+// GL.RETURN
+// Transfers accumulation buffer values to the color buffer or buffers
+// currently selected for writing. Each R, G, B, and A component is
+// multiplied by value, then multiplied by 2 n - 1 , clamped to the
+// range 0 2 n - 1 , and stored in the corresponding display buffer
+// cell. The only fragment operations that are applied to this transfer
+// are pixel ownership, scissor, dithering, and color writemasks.
+//
+// To clear the accumulation buffer, call ClearAccum with R, G, B, and A
+// values to set it to, then call Clear with the accumulation buffer
+// enabled.
+//
+// Error GL.INVALID_ENUM is generated if op is not an accepted value.
+// GL.INVALID_OPERATION is generated if there is no accumulation buffer.
+// GL.INVALID_OPERATION is generated if Accum is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) Accum(op glbase.Enum, value float32) {
+ C.gl4_1compat_glAccum(gl.funcs, C.GLenum(op), C.GLfloat(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIndexMask.xml
+func (gl *GL) IndexMask(mask uint32) {
+ C.gl4_1compat_glIndexMask(gl.funcs, C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearIndex.xml
+func (gl *GL) ClearIndex(c float32) {
+ C.gl4_1compat_glClearIndex(gl.funcs, C.GLfloat(c))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearAccum.xml
+func (gl *GL) ClearAccum(red, green, blue, alpha float32) {
+ C.gl4_1compat_glClearAccum(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPushName.xml
+func (gl *GL) PushName(name uint32) {
+ C.gl4_1compat_glPushName(gl.funcs, C.GLuint(name))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPopName.xml
+func (gl *GL) PopName() {
+ C.gl4_1compat_glPopName(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPassThrough.xml
+func (gl *GL) PassThrough(token float32) {
+ C.gl4_1compat_glPassThrough(gl.funcs, C.GLfloat(token))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLoadName.xml
+func (gl *GL) LoadName(name uint32) {
+ C.gl4_1compat_glLoadName(gl.funcs, C.GLuint(name))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glInitNames.xml
+func (gl *GL) InitNames() {
+ C.gl4_1compat_glInitNames(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRenderMode.xml
+func (gl *GL) RenderMode(mode glbase.Enum) int32 {
+ glresult := C.gl4_1compat_glRenderMode(gl.funcs, C.GLenum(mode))
+ return int32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSelectBuffer.xml
+func (gl *GL) SelectBuffer(size int, buffer []glbase.Buffer) {
+ C.gl4_1compat_glSelectBuffer(gl.funcs, C.GLsizei(size), (*C.GLuint)(unsafe.Pointer(&buffer[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFeedbackBuffer.xml
+func (gl *GL) FeedbackBuffer(size int, gltype glbase.Enum, buffer []float32) {
+ C.gl4_1compat_glFeedbackBuffer(gl.funcs, C.GLsizei(size), C.GLenum(gltype), (*C.GLfloat)(unsafe.Pointer(&buffer[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexGeniv.xml
+func (gl *GL) TexGeniv(coord, pname glbase.Enum, params []int32) {
+ C.gl4_1compat_glTexGeniv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexGeni.xml
+func (gl *GL) TexGeni(coord, pname glbase.Enum, param int32) {
+ C.gl4_1compat_glTexGeni(gl.funcs, C.GLenum(coord), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexGenfv.xml
+func (gl *GL) TexGenfv(coord, pname glbase.Enum, params []float32) {
+ C.gl4_1compat_glTexGenfv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexGenf.xml
+func (gl *GL) TexGenf(coord, pname glbase.Enum, param float32) {
+ C.gl4_1compat_glTexGenf(gl.funcs, C.GLenum(coord), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexGendv.xml
+func (gl *GL) TexGendv(coord, pname glbase.Enum, params []float64) {
+ C.gl4_1compat_glTexGendv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexGend.xml
+func (gl *GL) TexGend(coord, pname glbase.Enum, param float64) {
+ C.gl4_1compat_glTexGend(gl.funcs, C.GLenum(coord), C.GLenum(pname), C.GLdouble(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexEnviv.xml
+func (gl *GL) TexEnviv(target, pname glbase.Enum, params []int32) {
+ C.gl4_1compat_glTexEnviv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexEnvi.xml
+func (gl *GL) TexEnvi(target, pname glbase.Enum, param int32) {
+ C.gl4_1compat_glTexEnvi(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexEnvfv.xml
+func (gl *GL) TexEnvfv(target, pname glbase.Enum, params []float32) {
+ C.gl4_1compat_glTexEnvfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexEnvf.xml
+func (gl *GL) TexEnvf(target, pname glbase.Enum, param float32) {
+ C.gl4_1compat_glTexEnvf(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glShadeModel.xml
+func (gl *GL) ShadeModel(mode glbase.Enum) {
+ C.gl4_1compat_glShadeModel(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPolygonStipple.xml
+func (gl *GL) PolygonStipple(mask []uint8) {
+ C.gl4_1compat_glPolygonStipple(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&mask[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMaterialiv.xml
+func (gl *GL) Materialiv(face, pname glbase.Enum, params []int32) {
+ C.gl4_1compat_glMaterialiv(gl.funcs, C.GLenum(face), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMateriali.xml
+func (gl *GL) Materiali(face, pname glbase.Enum, param int32) {
+ C.gl4_1compat_glMateriali(gl.funcs, C.GLenum(face), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMaterialfv.xml
+func (gl *GL) Materialfv(face, pname glbase.Enum, params []float32) {
+ C.gl4_1compat_glMaterialfv(gl.funcs, C.GLenum(face), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMaterialf.xml
+func (gl *GL) Materialf(face, pname glbase.Enum, param float32) {
+ C.gl4_1compat_glMaterialf(gl.funcs, C.GLenum(face), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLineStipple.xml
+func (gl *GL) LineStipple(factor int32, pattern uint16) {
+ C.gl4_1compat_glLineStipple(gl.funcs, C.GLint(factor), C.GLushort(pattern))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLightModeliv.xml
+func (gl *GL) LightModeliv(pname glbase.Enum, params []int32) {
+ C.gl4_1compat_glLightModeliv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLightModeli.xml
+func (gl *GL) LightModeli(pname glbase.Enum, param int32) {
+ C.gl4_1compat_glLightModeli(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLightModelfv.xml
+func (gl *GL) LightModelfv(pname glbase.Enum, params []float32) {
+ C.gl4_1compat_glLightModelfv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLightModelf.xml
+func (gl *GL) LightModelf(pname glbase.Enum, param float32) {
+ C.gl4_1compat_glLightModelf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLightiv.xml
+func (gl *GL) Lightiv(light, pname glbase.Enum, params []int32) {
+ C.gl4_1compat_glLightiv(gl.funcs, C.GLenum(light), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLighti.xml
+func (gl *GL) Lighti(light, pname glbase.Enum, param int32) {
+ C.gl4_1compat_glLighti(gl.funcs, C.GLenum(light), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLightfv.xml
+func (gl *GL) Lightfv(light, pname glbase.Enum, params []float32) {
+ C.gl4_1compat_glLightfv(gl.funcs, C.GLenum(light), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLightf.xml
+func (gl *GL) Lightf(light, pname glbase.Enum, param float32) {
+ C.gl4_1compat_glLightf(gl.funcs, C.GLenum(light), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFogiv.xml
+func (gl *GL) Fogiv(pname glbase.Enum, params []int32) {
+ C.gl4_1compat_glFogiv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFogi.xml
+func (gl *GL) Fogi(pname glbase.Enum, param int32) {
+ C.gl4_1compat_glFogi(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFogfv.xml
+func (gl *GL) Fogfv(pname glbase.Enum, params []float32) {
+ C.gl4_1compat_glFogfv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFogf.xml
+func (gl *GL) Fogf(pname glbase.Enum, param float32) {
+ C.gl4_1compat_glFogf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorMaterial.xml
+func (gl *GL) ColorMaterial(face, mode glbase.Enum) {
+ C.gl4_1compat_glColorMaterial(gl.funcs, C.GLenum(face), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClipPlane.xml
+func (gl *GL) ClipPlane(plane glbase.Enum, equation []float64) {
+ C.gl4_1compat_glClipPlane(gl.funcs, C.GLenum(plane), (*C.GLdouble)(unsafe.Pointer(&equation[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex4sv.xml
+func (gl *GL) Vertex4sv(v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glVertex4sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex4s.xml
+func (gl *GL) Vertex4s(x, y, z, w int16) {
+ C.gl4_1compat_glVertex4s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z), C.GLshort(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex4iv.xml
+func (gl *GL) Vertex4iv(v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glVertex4iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex4i.xml
+func (gl *GL) Vertex4i(x, y, z, w int) {
+ C.gl4_1compat_glVertex4i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z), C.GLint(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex4fv.xml
+func (gl *GL) Vertex4fv(v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glVertex4fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex4f.xml
+func (gl *GL) Vertex4f(x, y, z, w float32) {
+ C.gl4_1compat_glVertex4f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z), C.GLfloat(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex4dv.xml
+func (gl *GL) Vertex4dv(v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glVertex4dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex4d.xml
+func (gl *GL) Vertex4d(x, y, z, w float64) {
+ C.gl4_1compat_glVertex4d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z), C.GLdouble(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex3sv.xml
+func (gl *GL) Vertex3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glVertex3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex3s.xml
+func (gl *GL) Vertex3s(x, y, z int16) {
+ C.gl4_1compat_glVertex3s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex3iv.xml
+func (gl *GL) Vertex3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glVertex3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex3i.xml
+func (gl *GL) Vertex3i(x, y, z int) {
+ C.gl4_1compat_glVertex3i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex3fv.xml
+func (gl *GL) Vertex3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glVertex3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex3f.xml
+func (gl *GL) Vertex3f(x, y, z float32) {
+ C.gl4_1compat_glVertex3f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex3dv.xml
+func (gl *GL) Vertex3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glVertex3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex3d.xml
+func (gl *GL) Vertex3d(x, y, z float64) {
+ C.gl4_1compat_glVertex3d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex2sv.xml
+func (gl *GL) Vertex2sv(v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glVertex2sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex2s.xml
+func (gl *GL) Vertex2s(x, y int16) {
+ C.gl4_1compat_glVertex2s(gl.funcs, C.GLshort(x), C.GLshort(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex2iv.xml
+func (gl *GL) Vertex2iv(v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glVertex2iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex2i.xml
+func (gl *GL) Vertex2i(x, y int) {
+ C.gl4_1compat_glVertex2i(gl.funcs, C.GLint(x), C.GLint(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex2fv.xml
+func (gl *GL) Vertex2fv(v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glVertex2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex2f.xml
+func (gl *GL) Vertex2f(x, y float32) {
+ C.gl4_1compat_glVertex2f(gl.funcs, C.GLfloat(x), C.GLfloat(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex2dv.xml
+func (gl *GL) Vertex2dv(v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glVertex2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex2d.xml
+func (gl *GL) Vertex2d(x, y float64) {
+ C.gl4_1compat_glVertex2d(gl.funcs, C.GLdouble(x), C.GLdouble(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord4sv.xml
+func (gl *GL) TexCoord4sv(v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glTexCoord4sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord4s.xml
+func (gl *GL) TexCoord4s(s, t, r, q int16) {
+ C.gl4_1compat_glTexCoord4s(gl.funcs, C.GLshort(s), C.GLshort(t), C.GLshort(r), C.GLshort(q))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord4iv.xml
+func (gl *GL) TexCoord4iv(v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glTexCoord4iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord4i.xml
+func (gl *GL) TexCoord4i(s, t, r, q int32) {
+ C.gl4_1compat_glTexCoord4i(gl.funcs, C.GLint(s), C.GLint(t), C.GLint(r), C.GLint(q))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord4fv.xml
+func (gl *GL) TexCoord4fv(v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glTexCoord4fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord4f.xml
+func (gl *GL) TexCoord4f(s, t, r, q float32) {
+ C.gl4_1compat_glTexCoord4f(gl.funcs, C.GLfloat(s), C.GLfloat(t), C.GLfloat(r), C.GLfloat(q))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord4dv.xml
+func (gl *GL) TexCoord4dv(v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glTexCoord4dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord4d.xml
+func (gl *GL) TexCoord4d(s, t, r, q float64) {
+ C.gl4_1compat_glTexCoord4d(gl.funcs, C.GLdouble(s), C.GLdouble(t), C.GLdouble(r), C.GLdouble(q))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord3sv.xml
+func (gl *GL) TexCoord3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glTexCoord3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord3s.xml
+func (gl *GL) TexCoord3s(s, t, r int16) {
+ C.gl4_1compat_glTexCoord3s(gl.funcs, C.GLshort(s), C.GLshort(t), C.GLshort(r))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord3iv.xml
+func (gl *GL) TexCoord3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glTexCoord3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord3i.xml
+func (gl *GL) TexCoord3i(s, t, r int32) {
+ C.gl4_1compat_glTexCoord3i(gl.funcs, C.GLint(s), C.GLint(t), C.GLint(r))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord3fv.xml
+func (gl *GL) TexCoord3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glTexCoord3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord3f.xml
+func (gl *GL) TexCoord3f(s, t, r float32) {
+ C.gl4_1compat_glTexCoord3f(gl.funcs, C.GLfloat(s), C.GLfloat(t), C.GLfloat(r))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord3dv.xml
+func (gl *GL) TexCoord3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glTexCoord3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord3d.xml
+func (gl *GL) TexCoord3d(s, t, r float64) {
+ C.gl4_1compat_glTexCoord3d(gl.funcs, C.GLdouble(s), C.GLdouble(t), C.GLdouble(r))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord2sv.xml
+func (gl *GL) TexCoord2sv(v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glTexCoord2sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord2s.xml
+func (gl *GL) TexCoord2s(s, t int16) {
+ C.gl4_1compat_glTexCoord2s(gl.funcs, C.GLshort(s), C.GLshort(t))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord2iv.xml
+func (gl *GL) TexCoord2iv(v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glTexCoord2iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord2i.xml
+func (gl *GL) TexCoord2i(s, t int32) {
+ C.gl4_1compat_glTexCoord2i(gl.funcs, C.GLint(s), C.GLint(t))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord2fv.xml
+func (gl *GL) TexCoord2fv(v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glTexCoord2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord2f.xml
+func (gl *GL) TexCoord2f(s, t float32) {
+ C.gl4_1compat_glTexCoord2f(gl.funcs, C.GLfloat(s), C.GLfloat(t))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord2dv.xml
+func (gl *GL) TexCoord2dv(v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glTexCoord2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord2d.xml
+func (gl *GL) TexCoord2d(s, t float64) {
+ C.gl4_1compat_glTexCoord2d(gl.funcs, C.GLdouble(s), C.GLdouble(t))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord1sv.xml
+func (gl *GL) TexCoord1sv(v []int16) {
+ C.gl4_1compat_glTexCoord1sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord1s.xml
+func (gl *GL) TexCoord1s(s int16) {
+ C.gl4_1compat_glTexCoord1s(gl.funcs, C.GLshort(s))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord1iv.xml
+func (gl *GL) TexCoord1iv(v []int32) {
+ C.gl4_1compat_glTexCoord1iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord1i.xml
+func (gl *GL) TexCoord1i(s int32) {
+ C.gl4_1compat_glTexCoord1i(gl.funcs, C.GLint(s))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord1fv.xml
+func (gl *GL) TexCoord1fv(v []float32) {
+ C.gl4_1compat_glTexCoord1fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord1f.xml
+func (gl *GL) TexCoord1f(s float32) {
+ C.gl4_1compat_glTexCoord1f(gl.funcs, C.GLfloat(s))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord1dv.xml
+func (gl *GL) TexCoord1dv(v []float64) {
+ C.gl4_1compat_glTexCoord1dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord1d.xml
+func (gl *GL) TexCoord1d(s float64) {
+ C.gl4_1compat_glTexCoord1d(gl.funcs, C.GLdouble(s))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRectsv.xml
+func (gl *GL) Rectsv(v1, v2 []int16) {
+ C.gl4_1compat_glRectsv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v1[0])), (*C.GLshort)(unsafe.Pointer(&v2[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRects.xml
+func (gl *GL) Rects(x1, y1, x2, y2 int16) {
+ C.gl4_1compat_glRects(gl.funcs, C.GLshort(x1), C.GLshort(y1), C.GLshort(x2), C.GLshort(y2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRectiv.xml
+func (gl *GL) Rectiv(v1, v2 []int32) {
+ C.gl4_1compat_glRectiv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v1[0])), (*C.GLint)(unsafe.Pointer(&v2[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRecti.xml
+func (gl *GL) Recti(x1, y1, x2, y2 int32) {
+ C.gl4_1compat_glRecti(gl.funcs, C.GLint(x1), C.GLint(y1), C.GLint(x2), C.GLint(y2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRectfv.xml
+func (gl *GL) Rectfv(v1, v2 []float32) {
+ C.gl4_1compat_glRectfv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v1[0])), (*C.GLfloat)(unsafe.Pointer(&v2[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRectf.xml
+func (gl *GL) Rectf(x1, y1, x2, y2 float32) {
+ C.gl4_1compat_glRectf(gl.funcs, C.GLfloat(x1), C.GLfloat(y1), C.GLfloat(x2), C.GLfloat(y2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRectdv.xml
+func (gl *GL) Rectdv(v1, v2 []float64) {
+ C.gl4_1compat_glRectdv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v1[0])), (*C.GLdouble)(unsafe.Pointer(&v2[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRectd.xml
+func (gl *GL) Rectd(x1, y1, x2, y2 float64) {
+ C.gl4_1compat_glRectd(gl.funcs, C.GLdouble(x1), C.GLdouble(y1), C.GLdouble(x2), C.GLdouble(y2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos4sv.xml
+func (gl *GL) RasterPos4sv(v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glRasterPos4sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos4s.xml
+func (gl *GL) RasterPos4s(x, y, z, w int16) {
+ C.gl4_1compat_glRasterPos4s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z), C.GLshort(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos4iv.xml
+func (gl *GL) RasterPos4iv(v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glRasterPos4iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos4i.xml
+func (gl *GL) RasterPos4i(x, y, z, w int) {
+ C.gl4_1compat_glRasterPos4i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z), C.GLint(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos4fv.xml
+func (gl *GL) RasterPos4fv(v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glRasterPos4fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos4f.xml
+func (gl *GL) RasterPos4f(x, y, z, w float32) {
+ C.gl4_1compat_glRasterPos4f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z), C.GLfloat(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos4dv.xml
+func (gl *GL) RasterPos4dv(v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glRasterPos4dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos4d.xml
+func (gl *GL) RasterPos4d(x, y, z, w float64) {
+ C.gl4_1compat_glRasterPos4d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z), C.GLdouble(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos3sv.xml
+func (gl *GL) RasterPos3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glRasterPos3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos3s.xml
+func (gl *GL) RasterPos3s(x, y, z int16) {
+ C.gl4_1compat_glRasterPos3s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos3iv.xml
+func (gl *GL) RasterPos3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glRasterPos3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos3i.xml
+func (gl *GL) RasterPos3i(x, y, z int) {
+ C.gl4_1compat_glRasterPos3i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos3fv.xml
+func (gl *GL) RasterPos3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glRasterPos3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos3f.xml
+func (gl *GL) RasterPos3f(x, y, z float32) {
+ C.gl4_1compat_glRasterPos3f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos3dv.xml
+func (gl *GL) RasterPos3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glRasterPos3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos3d.xml
+func (gl *GL) RasterPos3d(x, y, z float64) {
+ C.gl4_1compat_glRasterPos3d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos2sv.xml
+func (gl *GL) RasterPos2sv(v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glRasterPos2sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos2s.xml
+func (gl *GL) RasterPos2s(x, y int16) {
+ C.gl4_1compat_glRasterPos2s(gl.funcs, C.GLshort(x), C.GLshort(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos2iv.xml
+func (gl *GL) RasterPos2iv(v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glRasterPos2iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos2i.xml
+func (gl *GL) RasterPos2i(x, y int) {
+ C.gl4_1compat_glRasterPos2i(gl.funcs, C.GLint(x), C.GLint(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos2fv.xml
+func (gl *GL) RasterPos2fv(v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glRasterPos2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos2f.xml
+func (gl *GL) RasterPos2f(x, y float32) {
+ C.gl4_1compat_glRasterPos2f(gl.funcs, C.GLfloat(x), C.GLfloat(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos2dv.xml
+func (gl *GL) RasterPos2dv(v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glRasterPos2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos2d.xml
+func (gl *GL) RasterPos2d(x, y float64) {
+ C.gl4_1compat_glRasterPos2d(gl.funcs, C.GLdouble(x), C.GLdouble(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNormal3sv.xml
+func (gl *GL) Normal3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glNormal3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNormal3s.xml
+func (gl *GL) Normal3s(nx, ny, nz int16) {
+ C.gl4_1compat_glNormal3s(gl.funcs, C.GLshort(nx), C.GLshort(ny), C.GLshort(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNormal3iv.xml
+func (gl *GL) Normal3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glNormal3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNormal3i.xml
+func (gl *GL) Normal3i(nx, ny, nz int32) {
+ C.gl4_1compat_glNormal3i(gl.funcs, C.GLint(nx), C.GLint(ny), C.GLint(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNormal3fv.xml
+func (gl *GL) Normal3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glNormal3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNormal3f.xml
+func (gl *GL) Normal3f(nx, ny, nz float32) {
+ C.gl4_1compat_glNormal3f(gl.funcs, C.GLfloat(nx), C.GLfloat(ny), C.GLfloat(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNormal3dv.xml
+func (gl *GL) Normal3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glNormal3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNormal3d.xml
+func (gl *GL) Normal3d(nx, ny, nz float64) {
+ C.gl4_1compat_glNormal3d(gl.funcs, C.GLdouble(nx), C.GLdouble(ny), C.GLdouble(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNormal3bv.xml
+func (gl *GL) Normal3bv(v []byte) {
+ C.gl4_1compat_glNormal3bv(gl.funcs, (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNormal3b.xml
+func (gl *GL) Normal3b(nx, ny, nz byte) {
+ C.gl4_1compat_glNormal3b(gl.funcs, C.GLbyte(nx), C.GLbyte(ny), C.GLbyte(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIndexsv.xml
+func (gl *GL) Indexsv(c []int16) {
+ C.gl4_1compat_glIndexsv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIndexs.xml
+func (gl *GL) Indexs(c int16) {
+ C.gl4_1compat_glIndexs(gl.funcs, C.GLshort(c))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIndexiv.xml
+func (gl *GL) Indexiv(c []int32) {
+ C.gl4_1compat_glIndexiv(gl.funcs, (*C.GLint)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIndexi.xml
+func (gl *GL) Indexi(c int32) {
+ C.gl4_1compat_glIndexi(gl.funcs, C.GLint(c))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIndexfv.xml
+func (gl *GL) Indexfv(c []float32) {
+ C.gl4_1compat_glIndexfv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIndexf.xml
+func (gl *GL) Indexf(c float32) {
+ C.gl4_1compat_glIndexf(gl.funcs, C.GLfloat(c))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIndexdv.xml
+func (gl *GL) Indexdv(c []float64) {
+ C.gl4_1compat_glIndexdv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIndexd.xml
+func (gl *GL) Indexd(c float64) {
+ C.gl4_1compat_glIndexd(gl.funcs, C.GLdouble(c))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEnd.xml
+func (gl *GL) End() {
+ C.gl4_1compat_glEnd(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEdgeFlagv.xml
+func (gl *GL) EdgeFlagv(flag []bool) {
+ C.gl4_1compat_glEdgeFlagv(gl.funcs, (*C.GLboolean)(unsafe.Pointer(&flag[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEdgeFlag.xml
+func (gl *GL) EdgeFlag(flag bool) {
+ C.gl4_1compat_glEdgeFlag(gl.funcs, *(*C.GLboolean)(unsafe.Pointer(&flag)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4usv.xml
+func (gl *GL) Color4usv(v []uint16) {
+ C.gl4_1compat_glColor4usv(gl.funcs, (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4us.xml
+func (gl *GL) Color4us(red, green, blue, alpha uint16) {
+ C.gl4_1compat_glColor4us(gl.funcs, C.GLushort(red), C.GLushort(green), C.GLushort(blue), C.GLushort(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4uiv.xml
+func (gl *GL) Color4uiv(v []uint32) {
+ C.gl4_1compat_glColor4uiv(gl.funcs, (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4ui.xml
+func (gl *GL) Color4ui(red, green, blue, alpha uint32) {
+ C.gl4_1compat_glColor4ui(gl.funcs, C.GLuint(red), C.GLuint(green), C.GLuint(blue), C.GLuint(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4ubv.xml
+func (gl *GL) Color4ubv(v []uint8) {
+ C.gl4_1compat_glColor4ubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4ub.xml
+func (gl *GL) Color4ub(red, green, blue, alpha uint8) {
+ C.gl4_1compat_glColor4ub(gl.funcs, C.GLubyte(red), C.GLubyte(green), C.GLubyte(blue), C.GLubyte(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4sv.xml
+func (gl *GL) Color4sv(v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glColor4sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4s.xml
+func (gl *GL) Color4s(red, green, blue, alpha int16) {
+ C.gl4_1compat_glColor4s(gl.funcs, C.GLshort(red), C.GLshort(green), C.GLshort(blue), C.GLshort(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4iv.xml
+func (gl *GL) Color4iv(v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glColor4iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4i.xml
+func (gl *GL) Color4i(red, green, blue, alpha int32) {
+ C.gl4_1compat_glColor4i(gl.funcs, C.GLint(red), C.GLint(green), C.GLint(blue), C.GLint(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4fv.xml
+func (gl *GL) Color4fv(v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glColor4fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4f.xml
+func (gl *GL) Color4f(red, green, blue, alpha float32) {
+ C.gl4_1compat_glColor4f(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4dv.xml
+func (gl *GL) Color4dv(v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glColor4dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4d.xml
+func (gl *GL) Color4d(red, green, blue, alpha float64) {
+ C.gl4_1compat_glColor4d(gl.funcs, C.GLdouble(red), C.GLdouble(green), C.GLdouble(blue), C.GLdouble(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4bv.xml
+func (gl *GL) Color4bv(v []byte) {
+ C.gl4_1compat_glColor4bv(gl.funcs, (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4b.xml
+func (gl *GL) Color4b(red, green, blue, alpha byte) {
+ C.gl4_1compat_glColor4b(gl.funcs, C.GLbyte(red), C.GLbyte(green), C.GLbyte(blue), C.GLbyte(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3usv.xml
+func (gl *GL) Color3usv(v []uint16) {
+ C.gl4_1compat_glColor3usv(gl.funcs, (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3us.xml
+func (gl *GL) Color3us(red, green, blue uint16) {
+ C.gl4_1compat_glColor3us(gl.funcs, C.GLushort(red), C.GLushort(green), C.GLushort(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3uiv.xml
+func (gl *GL) Color3uiv(v []uint32) {
+ C.gl4_1compat_glColor3uiv(gl.funcs, (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3ui.xml
+func (gl *GL) Color3ui(red, green, blue uint32) {
+ C.gl4_1compat_glColor3ui(gl.funcs, C.GLuint(red), C.GLuint(green), C.GLuint(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3ubv.xml
+func (gl *GL) Color3ubv(v []uint8) {
+ C.gl4_1compat_glColor3ubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3ub.xml
+func (gl *GL) Color3ub(red, green, blue uint8) {
+ C.gl4_1compat_glColor3ub(gl.funcs, C.GLubyte(red), C.GLubyte(green), C.GLubyte(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3sv.xml
+func (gl *GL) Color3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glColor3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3s.xml
+func (gl *GL) Color3s(red, green, blue int16) {
+ C.gl4_1compat_glColor3s(gl.funcs, C.GLshort(red), C.GLshort(green), C.GLshort(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3iv.xml
+func (gl *GL) Color3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glColor3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3i.xml
+func (gl *GL) Color3i(red, green, blue int32) {
+ C.gl4_1compat_glColor3i(gl.funcs, C.GLint(red), C.GLint(green), C.GLint(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3fv.xml
+func (gl *GL) Color3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glColor3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3f.xml
+func (gl *GL) Color3f(red, green, blue float32) {
+ C.gl4_1compat_glColor3f(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3dv.xml
+func (gl *GL) Color3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glColor3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3d.xml
+func (gl *GL) Color3d(red, green, blue float64) {
+ C.gl4_1compat_glColor3d(gl.funcs, C.GLdouble(red), C.GLdouble(green), C.GLdouble(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3bv.xml
+func (gl *GL) Color3bv(v []byte) {
+ C.gl4_1compat_glColor3bv(gl.funcs, (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3b.xml
+func (gl *GL) Color3b(red, green, blue byte) {
+ C.gl4_1compat_glColor3b(gl.funcs, C.GLbyte(red), C.GLbyte(green), C.GLbyte(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBitmap.xml
+func (gl *GL) Bitmap(width, height int, xorig, yorig, xmove, ymove float32, bitmap []uint8) {
+ C.gl4_1compat_glBitmap(gl.funcs, C.GLsizei(width), C.GLsizei(height), C.GLfloat(xorig), C.GLfloat(yorig), C.GLfloat(xmove), C.GLfloat(ymove), (*C.GLubyte)(unsafe.Pointer(&bitmap[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBegin.xml
+func (gl *GL) Begin(mode glbase.Enum) {
+ C.gl4_1compat_glBegin(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glListBase.xml
+func (gl *GL) ListBase(base uint32) {
+ C.gl4_1compat_glListBase(gl.funcs, C.GLuint(base))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGenLists.xml
+func (gl *GL) GenLists(range_ int32) uint32 {
+ glresult := C.gl4_1compat_glGenLists(gl.funcs, C.GLsizei(range_))
+ return uint32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDeleteLists.xml
+func (gl *GL) DeleteLists(list uint32, range_ int32) {
+ C.gl4_1compat_glDeleteLists(gl.funcs, C.GLuint(list), C.GLsizei(range_))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCallLists.xml
+func (gl *GL) CallLists(n int, gltype glbase.Enum, lists interface{}) {
+ var lists_ptr unsafe.Pointer
+ var lists_v = reflect.ValueOf(lists)
+ if lists != nil && lists_v.Kind() != reflect.Slice {
+ panic("parameter lists must be a slice")
+ }
+ if lists != nil {
+ lists_ptr = unsafe.Pointer(lists_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1compat_glCallLists(gl.funcs, C.GLsizei(n), C.GLenum(gltype), lists_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCallList.xml
+func (gl *GL) CallList(list uint32) {
+ C.gl4_1compat_glCallList(gl.funcs, C.GLuint(list))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEndList.xml
+func (gl *GL) EndList() {
+ C.gl4_1compat_glEndList(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNewList.xml
+func (gl *GL) NewList(list uint32, mode glbase.Enum) {
+ C.gl4_1compat_glNewList(gl.funcs, C.GLuint(list), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPushClientAttrib.xml
+func (gl *GL) PushClientAttrib(mask glbase.Bitfield) {
+ C.gl4_1compat_glPushClientAttrib(gl.funcs, C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPopClientAttrib.xml
+func (gl *GL) PopClientAttrib() {
+ C.gl4_1compat_glPopClientAttrib(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPrioritizeTextures.xml
+func (gl *GL) PrioritizeTextures(n int, textures []glbase.Texture, priorities []float32) {
+ C.gl4_1compat_glPrioritizeTextures(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])), (*C.GLfloat)(unsafe.Pointer(&priorities[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glAreTexturesResident.xml
+func (gl *GL) AreTexturesResident(n int, textures []glbase.Texture, residences []bool) bool {
+ glresult := C.gl4_1compat_glAreTexturesResident(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])), (*C.GLboolean)(unsafe.Pointer(&residences[0])))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexPointer.xml
+func (gl *GL) VertexPointer(size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1compat_glVertexPointer(gl.funcs, C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordPointer.xml
+func (gl *GL) TexCoordPointer(size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1compat_glTexCoordPointer(gl.funcs, C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNormalPointer.xml
+func (gl *GL) NormalPointer(gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1compat_glNormalPointer(gl.funcs, C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glInterleavedArrays.xml
+func (gl *GL) InterleavedArrays(format glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1compat_glInterleavedArrays(gl.funcs, C.GLenum(format), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIndexPointer.xml
+func (gl *GL) IndexPointer(gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1compat_glIndexPointer(gl.funcs, C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEnableClientState.xml
+func (gl *GL) EnableClientState(array glbase.Enum) {
+ C.gl4_1compat_glEnableClientState(gl.funcs, C.GLenum(array))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEdgeFlagPointer.xml
+func (gl *GL) EdgeFlagPointer(stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1compat_glEdgeFlagPointer(gl.funcs, C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDisableClientState.xml
+func (gl *GL) DisableClientState(array glbase.Enum) {
+ C.gl4_1compat_glDisableClientState(gl.funcs, C.GLenum(array))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorPointer.xml
+func (gl *GL) ColorPointer(size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1compat_glColorPointer(gl.funcs, C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glArrayElement.xml
+func (gl *GL) ArrayElement(i int32) {
+ C.gl4_1compat_glArrayElement(gl.funcs, C.GLint(i))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glResetMinmax.xml
+func (gl *GL) ResetMinmax(target glbase.Enum) {
+ C.gl4_1compat_glResetMinmax(gl.funcs, C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glResetHistogram.xml
+func (gl *GL) ResetHistogram(target glbase.Enum) {
+ C.gl4_1compat_glResetHistogram(gl.funcs, C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMinmax.xml
+func (gl *GL) Minmax(target, internalFormat glbase.Enum, sink bool) {
+ C.gl4_1compat_glMinmax(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), *(*C.GLboolean)(unsafe.Pointer(&sink)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glHistogram.xml
+func (gl *GL) Histogram(target glbase.Enum, width int, internalFormat glbase.Enum, sink bool) {
+ C.gl4_1compat_glHistogram(gl.funcs, C.GLenum(target), C.GLsizei(width), C.GLenum(internalFormat), *(*C.GLboolean)(unsafe.Pointer(&sink)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetMinmaxParameteriv.xml
+func (gl *GL) GetMinmaxParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl4_1compat_glGetMinmaxParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetMinmaxParameterfv.xml
+func (gl *GL) GetMinmaxParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl4_1compat_glGetMinmaxParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetMinmax.xml
+func (gl *GL) GetMinmax(target glbase.Enum, reset bool, format, gltype glbase.Enum, values interface{}) {
+ var values_ptr unsafe.Pointer
+ var values_v = reflect.ValueOf(values)
+ if values != nil && values_v.Kind() != reflect.Slice {
+ panic("parameter values must be a slice")
+ }
+ if values != nil {
+ values_ptr = unsafe.Pointer(values_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1compat_glGetMinmax(gl.funcs, C.GLenum(target), *(*C.GLboolean)(unsafe.Pointer(&reset)), C.GLenum(format), C.GLenum(gltype), values_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetHistogramParameteriv.xml
+func (gl *GL) GetHistogramParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl4_1compat_glGetHistogramParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetHistogramParameterfv.xml
+func (gl *GL) GetHistogramParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl4_1compat_glGetHistogramParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetHistogram.xml
+func (gl *GL) GetHistogram(target glbase.Enum, reset bool, format, gltype glbase.Enum, values interface{}) {
+ var values_ptr unsafe.Pointer
+ var values_v = reflect.ValueOf(values)
+ if values != nil && values_v.Kind() != reflect.Slice {
+ panic("parameter values must be a slice")
+ }
+ if values != nil {
+ values_ptr = unsafe.Pointer(values_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1compat_glGetHistogram(gl.funcs, C.GLenum(target), *(*C.GLboolean)(unsafe.Pointer(&reset)), C.GLenum(format), C.GLenum(gltype), values_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSeparableFilter2D.xml
+func (gl *GL) SeparableFilter2D(target, internalFormat glbase.Enum, width, height int, format, gltype glbase.Enum, row, column interface{}) {
+ var row_ptr unsafe.Pointer
+ var row_v = reflect.ValueOf(row)
+ if row != nil && row_v.Kind() != reflect.Slice {
+ panic("parameter row must be a slice")
+ }
+ if row != nil {
+ row_ptr = unsafe.Pointer(row_v.Index(0).Addr().Pointer())
+ }
+ var column_ptr unsafe.Pointer
+ var column_v = reflect.ValueOf(column)
+ if column != nil && column_v.Kind() != reflect.Slice {
+ panic("parameter column must be a slice")
+ }
+ if column != nil {
+ column_ptr = unsafe.Pointer(column_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1compat_glSeparableFilter2D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), row_ptr, column_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetSeparableFilter.xml
+func (gl *GL) GetSeparableFilter(target, format, gltype glbase.Enum, row, column, span interface{}) {
+ var row_ptr unsafe.Pointer
+ var row_v = reflect.ValueOf(row)
+ if row != nil && row_v.Kind() != reflect.Slice {
+ panic("parameter row must be a slice")
+ }
+ if row != nil {
+ row_ptr = unsafe.Pointer(row_v.Index(0).Addr().Pointer())
+ }
+ var column_ptr unsafe.Pointer
+ var column_v = reflect.ValueOf(column)
+ if column != nil && column_v.Kind() != reflect.Slice {
+ panic("parameter column must be a slice")
+ }
+ if column != nil {
+ column_ptr = unsafe.Pointer(column_v.Index(0).Addr().Pointer())
+ }
+ var span_ptr unsafe.Pointer
+ var span_v = reflect.ValueOf(span)
+ if span != nil && span_v.Kind() != reflect.Slice {
+ panic("parameter span must be a slice")
+ }
+ if span != nil {
+ span_ptr = unsafe.Pointer(span_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1compat_glGetSeparableFilter(gl.funcs, C.GLenum(target), C.GLenum(format), C.GLenum(gltype), row_ptr, column_ptr, span_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetConvolutionParameteriv.xml
+func (gl *GL) GetConvolutionParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl4_1compat_glGetConvolutionParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetConvolutionParameterfv.xml
+func (gl *GL) GetConvolutionParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl4_1compat_glGetConvolutionParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetConvolutionFilter.xml
+func (gl *GL) GetConvolutionFilter(target, format, gltype glbase.Enum, image interface{}) {
+ var image_ptr unsafe.Pointer
+ var image_v = reflect.ValueOf(image)
+ if image != nil && image_v.Kind() != reflect.Slice {
+ panic("parameter image must be a slice")
+ }
+ if image != nil {
+ image_ptr = unsafe.Pointer(image_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1compat_glGetConvolutionFilter(gl.funcs, C.GLenum(target), C.GLenum(format), C.GLenum(gltype), image_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyConvolutionFilter2D.xml
+func (gl *GL) CopyConvolutionFilter2D(target, internalFormat glbase.Enum, x, y, width, height int) {
+ C.gl4_1compat_glCopyConvolutionFilter2D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyConvolutionFilter1D.xml
+func (gl *GL) CopyConvolutionFilter1D(target, internalFormat glbase.Enum, x, y, width int) {
+ C.gl4_1compat_glCopyConvolutionFilter1D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glConvolutionParameteriv.xml
+func (gl *GL) ConvolutionParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl4_1compat_glConvolutionParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glConvolutionParameteri.xml
+func (gl *GL) ConvolutionParameteri(target, pname glbase.Enum, params int32) {
+ C.gl4_1compat_glConvolutionParameteri(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLint(params))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glConvolutionParameterfv.xml
+func (gl *GL) ConvolutionParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl4_1compat_glConvolutionParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glConvolutionParameterf.xml
+func (gl *GL) ConvolutionParameterf(target, pname glbase.Enum, params float32) {
+ C.gl4_1compat_glConvolutionParameterf(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLfloat(params))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glConvolutionFilter2D.xml
+func (gl *GL) ConvolutionFilter2D(target, internalFormat glbase.Enum, width, height int, format, gltype glbase.Enum, image interface{}) {
+ var image_ptr unsafe.Pointer
+ var image_v = reflect.ValueOf(image)
+ if image != nil && image_v.Kind() != reflect.Slice {
+ panic("parameter image must be a slice")
+ }
+ if image != nil {
+ image_ptr = unsafe.Pointer(image_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1compat_glConvolutionFilter2D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), image_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glConvolutionFilter1D.xml
+func (gl *GL) ConvolutionFilter1D(target, internalFormat glbase.Enum, width int, format, gltype glbase.Enum, image interface{}) {
+ var image_ptr unsafe.Pointer
+ var image_v = reflect.ValueOf(image)
+ if image != nil && image_v.Kind() != reflect.Slice {
+ panic("parameter image must be a slice")
+ }
+ if image != nil {
+ image_ptr = unsafe.Pointer(image_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1compat_glConvolutionFilter1D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLenum(format), C.GLenum(gltype), image_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyColorSubTable.xml
+func (gl *GL) CopyColorSubTable(target glbase.Enum, start int32, x, y, width int) {
+ C.gl4_1compat_glCopyColorSubTable(gl.funcs, C.GLenum(target), C.GLsizei(start), C.GLint(x), C.GLint(y), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorSubTable.xml
+func (gl *GL) ColorSubTable(target glbase.Enum, start int32, count int, format, gltype glbase.Enum, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1compat_glColorSubTable(gl.funcs, C.GLenum(target), C.GLsizei(start), C.GLsizei(count), C.GLenum(format), C.GLenum(gltype), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetColorTableParameteriv.xml
+func (gl *GL) GetColorTableParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl4_1compat_glGetColorTableParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetColorTableParameterfv.xml
+func (gl *GL) GetColorTableParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl4_1compat_glGetColorTableParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetColorTable.xml
+func (gl *GL) GetColorTable(target, format, gltype glbase.Enum, table interface{}) {
+ var table_ptr unsafe.Pointer
+ var table_v = reflect.ValueOf(table)
+ if table != nil && table_v.Kind() != reflect.Slice {
+ panic("parameter table must be a slice")
+ }
+ if table != nil {
+ table_ptr = unsafe.Pointer(table_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1compat_glGetColorTable(gl.funcs, C.GLenum(target), C.GLenum(format), C.GLenum(gltype), table_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyColorTable.xml
+func (gl *GL) CopyColorTable(target, internalFormat glbase.Enum, x, y, width int) {
+ C.gl4_1compat_glCopyColorTable(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorTableParameteriv.xml
+func (gl *GL) ColorTableParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl4_1compat_glColorTableParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorTableParameterfv.xml
+func (gl *GL) ColorTableParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl4_1compat_glColorTableParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorTable.xml
+func (gl *GL) ColorTable(target, internalFormat glbase.Enum, width int, format, gltype glbase.Enum, table interface{}) {
+ var table_ptr unsafe.Pointer
+ var table_v = reflect.ValueOf(table)
+ if table != nil && table_v.Kind() != reflect.Slice {
+ panic("parameter table must be a slice")
+ }
+ if table != nil {
+ table_ptr = unsafe.Pointer(table_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1compat_glColorTable(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLenum(format), C.GLenum(gltype), table_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultTransposeMatrixd.xml
+func (gl *GL) MultTransposeMatrixd(m []float64) {
+ C.gl4_1compat_glMultTransposeMatrixd(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultTransposeMatrixf.xml
+func (gl *GL) MultTransposeMatrixf(m []float32) {
+ C.gl4_1compat_glMultTransposeMatrixf(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLoadTransposeMatrixd.xml
+func (gl *GL) LoadTransposeMatrixd(m []float64) {
+ C.gl4_1compat_glLoadTransposeMatrixd(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLoadTransposeMatrixf.xml
+func (gl *GL) LoadTransposeMatrixf(m []float32) {
+ C.gl4_1compat_glLoadTransposeMatrixf(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord4sv.xml
+func (gl *GL) MultiTexCoord4sv(target glbase.Enum, v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glMultiTexCoord4sv(gl.funcs, C.GLenum(target), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord4s.xml
+func (gl *GL) MultiTexCoord4s(target glbase.Enum, s, t, r, q int16) {
+ C.gl4_1compat_glMultiTexCoord4s(gl.funcs, C.GLenum(target), C.GLshort(s), C.GLshort(t), C.GLshort(r), C.GLshort(q))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord4iv.xml
+func (gl *GL) MultiTexCoord4iv(target glbase.Enum, v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glMultiTexCoord4iv(gl.funcs, C.GLenum(target), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord4i.xml
+func (gl *GL) MultiTexCoord4i(target glbase.Enum, s, t, r, q int32) {
+ C.gl4_1compat_glMultiTexCoord4i(gl.funcs, C.GLenum(target), C.GLint(s), C.GLint(t), C.GLint(r), C.GLint(q))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord4fv.xml
+func (gl *GL) MultiTexCoord4fv(target glbase.Enum, v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glMultiTexCoord4fv(gl.funcs, C.GLenum(target), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord4f.xml
+func (gl *GL) MultiTexCoord4f(target glbase.Enum, s, t, r, q float32) {
+ C.gl4_1compat_glMultiTexCoord4f(gl.funcs, C.GLenum(target), C.GLfloat(s), C.GLfloat(t), C.GLfloat(r), C.GLfloat(q))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord4dv.xml
+func (gl *GL) MultiTexCoord4dv(target glbase.Enum, v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glMultiTexCoord4dv(gl.funcs, C.GLenum(target), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord4d.xml
+func (gl *GL) MultiTexCoord4d(target glbase.Enum, s, t, r, q float64) {
+ C.gl4_1compat_glMultiTexCoord4d(gl.funcs, C.GLenum(target), C.GLdouble(s), C.GLdouble(t), C.GLdouble(r), C.GLdouble(q))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord3sv.xml
+func (gl *GL) MultiTexCoord3sv(target glbase.Enum, v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glMultiTexCoord3sv(gl.funcs, C.GLenum(target), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord3s.xml
+func (gl *GL) MultiTexCoord3s(target glbase.Enum, s, t, r int16) {
+ C.gl4_1compat_glMultiTexCoord3s(gl.funcs, C.GLenum(target), C.GLshort(s), C.GLshort(t), C.GLshort(r))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord3iv.xml
+func (gl *GL) MultiTexCoord3iv(target glbase.Enum, v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glMultiTexCoord3iv(gl.funcs, C.GLenum(target), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord3i.xml
+func (gl *GL) MultiTexCoord3i(target glbase.Enum, s, t, r int32) {
+ C.gl4_1compat_glMultiTexCoord3i(gl.funcs, C.GLenum(target), C.GLint(s), C.GLint(t), C.GLint(r))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord3fv.xml
+func (gl *GL) MultiTexCoord3fv(target glbase.Enum, v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glMultiTexCoord3fv(gl.funcs, C.GLenum(target), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord3f.xml
+func (gl *GL) MultiTexCoord3f(target glbase.Enum, s, t, r float32) {
+ C.gl4_1compat_glMultiTexCoord3f(gl.funcs, C.GLenum(target), C.GLfloat(s), C.GLfloat(t), C.GLfloat(r))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord3dv.xml
+func (gl *GL) MultiTexCoord3dv(target glbase.Enum, v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glMultiTexCoord3dv(gl.funcs, C.GLenum(target), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord3d.xml
+func (gl *GL) MultiTexCoord3d(target glbase.Enum, s, t, r float64) {
+ C.gl4_1compat_glMultiTexCoord3d(gl.funcs, C.GLenum(target), C.GLdouble(s), C.GLdouble(t), C.GLdouble(r))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord2sv.xml
+func (gl *GL) MultiTexCoord2sv(target glbase.Enum, v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glMultiTexCoord2sv(gl.funcs, C.GLenum(target), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord2s.xml
+func (gl *GL) MultiTexCoord2s(target glbase.Enum, s, t int16) {
+ C.gl4_1compat_glMultiTexCoord2s(gl.funcs, C.GLenum(target), C.GLshort(s), C.GLshort(t))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord2iv.xml
+func (gl *GL) MultiTexCoord2iv(target glbase.Enum, v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glMultiTexCoord2iv(gl.funcs, C.GLenum(target), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord2i.xml
+func (gl *GL) MultiTexCoord2i(target glbase.Enum, s, t int32) {
+ C.gl4_1compat_glMultiTexCoord2i(gl.funcs, C.GLenum(target), C.GLint(s), C.GLint(t))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord2fv.xml
+func (gl *GL) MultiTexCoord2fv(target glbase.Enum, v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glMultiTexCoord2fv(gl.funcs, C.GLenum(target), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord2f.xml
+func (gl *GL) MultiTexCoord2f(target glbase.Enum, s, t float32) {
+ C.gl4_1compat_glMultiTexCoord2f(gl.funcs, C.GLenum(target), C.GLfloat(s), C.GLfloat(t))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord2dv.xml
+func (gl *GL) MultiTexCoord2dv(target glbase.Enum, v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glMultiTexCoord2dv(gl.funcs, C.GLenum(target), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord2d.xml
+func (gl *GL) MultiTexCoord2d(target glbase.Enum, s, t float64) {
+ C.gl4_1compat_glMultiTexCoord2d(gl.funcs, C.GLenum(target), C.GLdouble(s), C.GLdouble(t))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord1sv.xml
+func (gl *GL) MultiTexCoord1sv(target glbase.Enum, v []int16) {
+ C.gl4_1compat_glMultiTexCoord1sv(gl.funcs, C.GLenum(target), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord1s.xml
+func (gl *GL) MultiTexCoord1s(target glbase.Enum, s int16) {
+ C.gl4_1compat_glMultiTexCoord1s(gl.funcs, C.GLenum(target), C.GLshort(s))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord1iv.xml
+func (gl *GL) MultiTexCoord1iv(target glbase.Enum, v []int32) {
+ C.gl4_1compat_glMultiTexCoord1iv(gl.funcs, C.GLenum(target), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord1i.xml
+func (gl *GL) MultiTexCoord1i(target glbase.Enum, s int32) {
+ C.gl4_1compat_glMultiTexCoord1i(gl.funcs, C.GLenum(target), C.GLint(s))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord1fv.xml
+func (gl *GL) MultiTexCoord1fv(target glbase.Enum, v []float32) {
+ C.gl4_1compat_glMultiTexCoord1fv(gl.funcs, C.GLenum(target), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord1f.xml
+func (gl *GL) MultiTexCoord1f(target glbase.Enum, s float32) {
+ C.gl4_1compat_glMultiTexCoord1f(gl.funcs, C.GLenum(target), C.GLfloat(s))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord1dv.xml
+func (gl *GL) MultiTexCoord1dv(target glbase.Enum, v []float64) {
+ C.gl4_1compat_glMultiTexCoord1dv(gl.funcs, C.GLenum(target), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord1d.xml
+func (gl *GL) MultiTexCoord1d(target glbase.Enum, s float64) {
+ C.gl4_1compat_glMultiTexCoord1d(gl.funcs, C.GLenum(target), C.GLdouble(s))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClientActiveTexture.xml
+func (gl *GL) ClientActiveTexture(texture glbase.Enum) {
+ C.gl4_1compat_glClientActiveTexture(gl.funcs, C.GLenum(texture))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos3sv.xml
+func (gl *GL) WindowPos3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glWindowPos3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos3s.xml
+func (gl *GL) WindowPos3s(x, y, z int16) {
+ C.gl4_1compat_glWindowPos3s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos3iv.xml
+func (gl *GL) WindowPos3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glWindowPos3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos3i.xml
+func (gl *GL) WindowPos3i(x, y, z int) {
+ C.gl4_1compat_glWindowPos3i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos3fv.xml
+func (gl *GL) WindowPos3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glWindowPos3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos3f.xml
+func (gl *GL) WindowPos3f(x, y, z float32) {
+ C.gl4_1compat_glWindowPos3f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos3dv.xml
+func (gl *GL) WindowPos3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glWindowPos3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos3d.xml
+func (gl *GL) WindowPos3d(x, y, z float64) {
+ C.gl4_1compat_glWindowPos3d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos2sv.xml
+func (gl *GL) WindowPos2sv(v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glWindowPos2sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos2s.xml
+func (gl *GL) WindowPos2s(x, y int16) {
+ C.gl4_1compat_glWindowPos2s(gl.funcs, C.GLshort(x), C.GLshort(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos2iv.xml
+func (gl *GL) WindowPos2iv(v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glWindowPos2iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos2i.xml
+func (gl *GL) WindowPos2i(x, y int) {
+ C.gl4_1compat_glWindowPos2i(gl.funcs, C.GLint(x), C.GLint(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos2fv.xml
+func (gl *GL) WindowPos2fv(v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glWindowPos2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos2f.xml
+func (gl *GL) WindowPos2f(x, y float32) {
+ C.gl4_1compat_glWindowPos2f(gl.funcs, C.GLfloat(x), C.GLfloat(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos2dv.xml
+func (gl *GL) WindowPos2dv(v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glWindowPos2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos2d.xml
+func (gl *GL) WindowPos2d(x, y float64) {
+ C.gl4_1compat_glWindowPos2d(gl.funcs, C.GLdouble(x), C.GLdouble(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColorPointer.xml
+func (gl *GL) SecondaryColorPointer(size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1compat_glSecondaryColorPointer(gl.funcs, C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3usv.xml
+func (gl *GL) SecondaryColor3usv(v []uint16) {
+ C.gl4_1compat_glSecondaryColor3usv(gl.funcs, (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3us.xml
+func (gl *GL) SecondaryColor3us(red, green, blue uint16) {
+ C.gl4_1compat_glSecondaryColor3us(gl.funcs, C.GLushort(red), C.GLushort(green), C.GLushort(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3uiv.xml
+func (gl *GL) SecondaryColor3uiv(v []uint32) {
+ C.gl4_1compat_glSecondaryColor3uiv(gl.funcs, (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3ui.xml
+func (gl *GL) SecondaryColor3ui(red, green, blue uint32) {
+ C.gl4_1compat_glSecondaryColor3ui(gl.funcs, C.GLuint(red), C.GLuint(green), C.GLuint(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3ubv.xml
+func (gl *GL) SecondaryColor3ubv(v []uint8) {
+ C.gl4_1compat_glSecondaryColor3ubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3ub.xml
+func (gl *GL) SecondaryColor3ub(red, green, blue uint8) {
+ C.gl4_1compat_glSecondaryColor3ub(gl.funcs, C.GLubyte(red), C.GLubyte(green), C.GLubyte(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3sv.xml
+func (gl *GL) SecondaryColor3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glSecondaryColor3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3s.xml
+func (gl *GL) SecondaryColor3s(red, green, blue int16) {
+ C.gl4_1compat_glSecondaryColor3s(gl.funcs, C.GLshort(red), C.GLshort(green), C.GLshort(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3iv.xml
+func (gl *GL) SecondaryColor3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glSecondaryColor3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3i.xml
+func (gl *GL) SecondaryColor3i(red, green, blue int32) {
+ C.gl4_1compat_glSecondaryColor3i(gl.funcs, C.GLint(red), C.GLint(green), C.GLint(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3fv.xml
+func (gl *GL) SecondaryColor3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glSecondaryColor3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3f.xml
+func (gl *GL) SecondaryColor3f(red, green, blue float32) {
+ C.gl4_1compat_glSecondaryColor3f(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3dv.xml
+func (gl *GL) SecondaryColor3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glSecondaryColor3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3d.xml
+func (gl *GL) SecondaryColor3d(red, green, blue float64) {
+ C.gl4_1compat_glSecondaryColor3d(gl.funcs, C.GLdouble(red), C.GLdouble(green), C.GLdouble(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3bv.xml
+func (gl *GL) SecondaryColor3bv(v []byte) {
+ C.gl4_1compat_glSecondaryColor3bv(gl.funcs, (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3b.xml
+func (gl *GL) SecondaryColor3b(red, green, blue byte) {
+ C.gl4_1compat_glSecondaryColor3b(gl.funcs, C.GLbyte(red), C.GLbyte(green), C.GLbyte(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFogCoordPointer.xml
+func (gl *GL) FogCoordPointer(gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1compat_glFogCoordPointer(gl.funcs, C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFogCoorddv.xml
+func (gl *GL) FogCoorddv(coord []float64) {
+ C.gl4_1compat_glFogCoorddv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&coord[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFogCoordd.xml
+func (gl *GL) FogCoordd(coord float64) {
+ C.gl4_1compat_glFogCoordd(gl.funcs, C.GLdouble(coord))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFogCoordfv.xml
+func (gl *GL) FogCoordfv(coord []float32) {
+ C.gl4_1compat_glFogCoordfv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&coord[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFogCoordf.xml
+func (gl *GL) FogCoordf(coord float32) {
+ C.gl4_1compat_glFogCoordf(gl.funcs, C.GLfloat(coord))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4usv.xml
+func (gl *GL) VertexAttrib4usv(index glbase.Attrib, v []uint16) {
+ C.gl4_1compat_glVertexAttrib4usv(gl.funcs, C.GLuint(index), (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4uiv.xml
+func (gl *GL) VertexAttrib4uiv(index glbase.Attrib, v []uint32) {
+ C.gl4_1compat_glVertexAttrib4uiv(gl.funcs, C.GLuint(index), (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4ubv.xml
+func (gl *GL) VertexAttrib4ubv(index glbase.Attrib, v []uint8) {
+ C.gl4_1compat_glVertexAttrib4ubv(gl.funcs, C.GLuint(index), (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4sv.xml
+func (gl *GL) VertexAttrib4sv(index glbase.Attrib, v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glVertexAttrib4sv(gl.funcs, C.GLuint(index), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4s.xml
+func (gl *GL) VertexAttrib4s(index glbase.Attrib, x, y, z, w int16) {
+ C.gl4_1compat_glVertexAttrib4s(gl.funcs, C.GLuint(index), C.GLshort(x), C.GLshort(y), C.GLshort(z), C.GLshort(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4iv.xml
+func (gl *GL) VertexAttrib4iv(index glbase.Attrib, v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glVertexAttrib4iv(gl.funcs, C.GLuint(index), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4fv.xml
+func (gl *GL) VertexAttrib4fv(index glbase.Attrib, v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glVertexAttrib4fv(gl.funcs, C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4f.xml
+func (gl *GL) VertexAttrib4f(index glbase.Attrib, x, y, z, w float32) {
+ C.gl4_1compat_glVertexAttrib4f(gl.funcs, C.GLuint(index), C.GLfloat(x), C.GLfloat(y), C.GLfloat(z), C.GLfloat(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4dv.xml
+func (gl *GL) VertexAttrib4dv(index glbase.Attrib, v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glVertexAttrib4dv(gl.funcs, C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4d.xml
+func (gl *GL) VertexAttrib4d(index glbase.Attrib, x, y, z, w float64) {
+ C.gl4_1compat_glVertexAttrib4d(gl.funcs, C.GLuint(index), C.GLdouble(x), C.GLdouble(y), C.GLdouble(z), C.GLdouble(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4bv.xml
+func (gl *GL) VertexAttrib4bv(index glbase.Attrib, v []byte) {
+ C.gl4_1compat_glVertexAttrib4bv(gl.funcs, C.GLuint(index), (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4Nusv.xml
+func (gl *GL) VertexAttrib4Nusv(index glbase.Attrib, v []uint16) {
+ C.gl4_1compat_glVertexAttrib4Nusv(gl.funcs, C.GLuint(index), (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4Nuiv.xml
+func (gl *GL) VertexAttrib4Nuiv(index glbase.Attrib, v []uint32) {
+ C.gl4_1compat_glVertexAttrib4Nuiv(gl.funcs, C.GLuint(index), (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4Nubv.xml
+func (gl *GL) VertexAttrib4Nubv(index glbase.Attrib, v []uint8) {
+ C.gl4_1compat_glVertexAttrib4Nubv(gl.funcs, C.GLuint(index), (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4Nub.xml
+func (gl *GL) VertexAttrib4Nub(index glbase.Attrib, x, y, z, w uint8) {
+ C.gl4_1compat_glVertexAttrib4Nub(gl.funcs, C.GLuint(index), C.GLubyte(x), C.GLubyte(y), C.GLubyte(z), C.GLubyte(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4Nsv.xml
+func (gl *GL) VertexAttrib4Nsv(index glbase.Attrib, v []int16) {
+ C.gl4_1compat_glVertexAttrib4Nsv(gl.funcs, C.GLuint(index), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4Niv.xml
+func (gl *GL) VertexAttrib4Niv(index glbase.Attrib, v []int32) {
+ C.gl4_1compat_glVertexAttrib4Niv(gl.funcs, C.GLuint(index), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4Nbv.xml
+func (gl *GL) VertexAttrib4Nbv(index glbase.Attrib, v []byte) {
+ C.gl4_1compat_glVertexAttrib4Nbv(gl.funcs, C.GLuint(index), (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib3sv.xml
+func (gl *GL) VertexAttrib3sv(index glbase.Attrib, v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glVertexAttrib3sv(gl.funcs, C.GLuint(index), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib3s.xml
+func (gl *GL) VertexAttrib3s(index glbase.Attrib, x, y, z int16) {
+ C.gl4_1compat_glVertexAttrib3s(gl.funcs, C.GLuint(index), C.GLshort(x), C.GLshort(y), C.GLshort(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib3fv.xml
+func (gl *GL) VertexAttrib3fv(index glbase.Attrib, v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glVertexAttrib3fv(gl.funcs, C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib3f.xml
+func (gl *GL) VertexAttrib3f(index glbase.Attrib, x, y, z float32) {
+ C.gl4_1compat_glVertexAttrib3f(gl.funcs, C.GLuint(index), C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib3dv.xml
+func (gl *GL) VertexAttrib3dv(index glbase.Attrib, v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glVertexAttrib3dv(gl.funcs, C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib3d.xml
+func (gl *GL) VertexAttrib3d(index glbase.Attrib, x, y, z float64) {
+ C.gl4_1compat_glVertexAttrib3d(gl.funcs, C.GLuint(index), C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib2sv.xml
+func (gl *GL) VertexAttrib2sv(index glbase.Attrib, v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glVertexAttrib2sv(gl.funcs, C.GLuint(index), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib2s.xml
+func (gl *GL) VertexAttrib2s(index glbase.Attrib, x, y int16) {
+ C.gl4_1compat_glVertexAttrib2s(gl.funcs, C.GLuint(index), C.GLshort(x), C.GLshort(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib2fv.xml
+func (gl *GL) VertexAttrib2fv(index glbase.Attrib, v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glVertexAttrib2fv(gl.funcs, C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib2f.xml
+func (gl *GL) VertexAttrib2f(index glbase.Attrib, x, y float32) {
+ C.gl4_1compat_glVertexAttrib2f(gl.funcs, C.GLuint(index), C.GLfloat(x), C.GLfloat(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib2dv.xml
+func (gl *GL) VertexAttrib2dv(index glbase.Attrib, v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glVertexAttrib2dv(gl.funcs, C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib2d.xml
+func (gl *GL) VertexAttrib2d(index glbase.Attrib, x, y float64) {
+ C.gl4_1compat_glVertexAttrib2d(gl.funcs, C.GLuint(index), C.GLdouble(x), C.GLdouble(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib1sv.xml
+func (gl *GL) VertexAttrib1sv(index glbase.Attrib, v []int16) {
+ C.gl4_1compat_glVertexAttrib1sv(gl.funcs, C.GLuint(index), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib1s.xml
+func (gl *GL) VertexAttrib1s(index glbase.Attrib, x int16) {
+ C.gl4_1compat_glVertexAttrib1s(gl.funcs, C.GLuint(index), C.GLshort(x))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib1fv.xml
+func (gl *GL) VertexAttrib1fv(index glbase.Attrib, v []float32) {
+ C.gl4_1compat_glVertexAttrib1fv(gl.funcs, C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib1f.xml
+func (gl *GL) VertexAttrib1f(index glbase.Attrib, x float32) {
+ C.gl4_1compat_glVertexAttrib1f(gl.funcs, C.GLuint(index), C.GLfloat(x))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib1dv.xml
+func (gl *GL) VertexAttrib1dv(index glbase.Attrib, v []float64) {
+ C.gl4_1compat_glVertexAttrib1dv(gl.funcs, C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib1d.xml
+func (gl *GL) VertexAttrib1d(index glbase.Attrib, x float64) {
+ C.gl4_1compat_glVertexAttrib1d(gl.funcs, C.GLuint(index), C.GLdouble(x))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI4usv.xml
+func (gl *GL) VertexAttribI4usv(index glbase.Attrib, v []uint16) {
+ C.gl4_1compat_glVertexAttribI4usv(gl.funcs, C.GLuint(index), (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI4ubv.xml
+func (gl *GL) VertexAttribI4ubv(index glbase.Attrib, v []uint8) {
+ C.gl4_1compat_glVertexAttribI4ubv(gl.funcs, C.GLuint(index), (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI4sv.xml
+func (gl *GL) VertexAttribI4sv(index glbase.Attrib, v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glVertexAttribI4sv(gl.funcs, C.GLuint(index), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI4bv.xml
+func (gl *GL) VertexAttribI4bv(index glbase.Attrib, v []byte) {
+ C.gl4_1compat_glVertexAttribI4bv(gl.funcs, C.GLuint(index), (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI4uiv.xml
+func (gl *GL) VertexAttribI4uiv(index glbase.Attrib, v []uint32) {
+ C.gl4_1compat_glVertexAttribI4uiv(gl.funcs, C.GLuint(index), (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI3uiv.xml
+func (gl *GL) VertexAttribI3uiv(index glbase.Attrib, v []uint32) {
+ C.gl4_1compat_glVertexAttribI3uiv(gl.funcs, C.GLuint(index), (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI2uiv.xml
+func (gl *GL) VertexAttribI2uiv(index glbase.Attrib, v []uint32) {
+ C.gl4_1compat_glVertexAttribI2uiv(gl.funcs, C.GLuint(index), (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI1uiv.xml
+func (gl *GL) VertexAttribI1uiv(index glbase.Attrib, v []uint32) {
+ C.gl4_1compat_glVertexAttribI1uiv(gl.funcs, C.GLuint(index), (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI4iv.xml
+func (gl *GL) VertexAttribI4iv(index glbase.Attrib, v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glVertexAttribI4iv(gl.funcs, C.GLuint(index), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI3iv.xml
+func (gl *GL) VertexAttribI3iv(index glbase.Attrib, v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glVertexAttribI3iv(gl.funcs, C.GLuint(index), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI2iv.xml
+func (gl *GL) VertexAttribI2iv(index glbase.Attrib, v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1compat_glVertexAttribI2iv(gl.funcs, C.GLuint(index), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI1iv.xml
+func (gl *GL) VertexAttribI1iv(index glbase.Attrib, v []int32) {
+ C.gl4_1compat_glVertexAttribI1iv(gl.funcs, C.GLuint(index), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI4ui.xml
+func (gl *GL) VertexAttribI4ui(index glbase.Attrib, x, y, z, w uint32) {
+ C.gl4_1compat_glVertexAttribI4ui(gl.funcs, C.GLuint(index), C.GLuint(x), C.GLuint(y), C.GLuint(z), C.GLuint(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI3ui.xml
+func (gl *GL) VertexAttribI3ui(index glbase.Attrib, x, y, z uint32) {
+ C.gl4_1compat_glVertexAttribI3ui(gl.funcs, C.GLuint(index), C.GLuint(x), C.GLuint(y), C.GLuint(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI2ui.xml
+func (gl *GL) VertexAttribI2ui(index glbase.Attrib, x, y uint32) {
+ C.gl4_1compat_glVertexAttribI2ui(gl.funcs, C.GLuint(index), C.GLuint(x), C.GLuint(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI1ui.xml
+func (gl *GL) VertexAttribI1ui(index glbase.Attrib, x uint32) {
+ C.gl4_1compat_glVertexAttribI1ui(gl.funcs, C.GLuint(index), C.GLuint(x))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI4i.xml
+func (gl *GL) VertexAttribI4i(index glbase.Attrib, x, y, z, w int) {
+ C.gl4_1compat_glVertexAttribI4i(gl.funcs, C.GLuint(index), C.GLint(x), C.GLint(y), C.GLint(z), C.GLint(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI3i.xml
+func (gl *GL) VertexAttribI3i(index glbase.Attrib, x, y, z int) {
+ C.gl4_1compat_glVertexAttribI3i(gl.funcs, C.GLuint(index), C.GLint(x), C.GLint(y), C.GLint(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI2i.xml
+func (gl *GL) VertexAttribI2i(index glbase.Attrib, x, y int) {
+ C.gl4_1compat_glVertexAttribI2i(gl.funcs, C.GLuint(index), C.GLint(x), C.GLint(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI1i.xml
+func (gl *GL) VertexAttribI1i(index glbase.Attrib, x int) {
+ C.gl4_1compat_glVertexAttribI1i(gl.funcs, C.GLuint(index), C.GLint(x))
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.1core/funcs.cpp b/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.1core/funcs.cpp
new file mode 100644
index 000000000..9ae51693c
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.1core/funcs.cpp
@@ -0,0 +1,2676 @@
+
+// ** file automatically generated by glgen -- do not edit manually **
+
+#include <QOpenGLContext>
+#include <QtGui/qopenglfunctions_4_1_core.h>
+
+#include "funcs.h"
+
+void *gl4_1core_funcs() {
+ QOpenGLFunctions_4_1_Core* funcs = QOpenGLContext::currentContext()->versionFunctions<QOpenGLFunctions_4_1_Core>();
+ if (!funcs) {
+ return 0;
+ }
+ funcs->initializeOpenGLFunctions();
+ return funcs;
+}
+
+
+void gl4_1core_glViewport(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glViewport(x, y, width, height);
+}
+
+void gl4_1core_glDepthRange(void *_glfuncs, GLdouble nearVal, GLdouble farVal)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glDepthRange(nearVal, farVal);
+}
+
+GLboolean gl4_1core_glIsEnabled(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ return _qglfuncs->glIsEnabled(cap);
+}
+
+void gl4_1core_glGetTexLevelParameteriv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetTexLevelParameteriv(target, level, pname, params);
+}
+
+void gl4_1core_glGetTexLevelParameterfv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetTexLevelParameterfv(target, level, pname, params);
+}
+
+void gl4_1core_glGetTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetTexParameteriv(target, pname, params);
+}
+
+void gl4_1core_glGetTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetTexParameterfv(target, pname, params);
+}
+
+void gl4_1core_glGetTexImage(void *_glfuncs, GLenum target, GLint level, GLenum format, GLenum gltype, GLvoid* pixels)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetTexImage(target, level, format, gltype, pixels);
+}
+
+void gl4_1core_glGetIntegerv(void *_glfuncs, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetIntegerv(pname, params);
+}
+
+void gl4_1core_glGetFloatv(void *_glfuncs, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetFloatv(pname, params);
+}
+
+GLenum gl4_1core_glGetError(void *_glfuncs)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ return _qglfuncs->glGetError();
+}
+
+void gl4_1core_glGetDoublev(void *_glfuncs, GLenum pname, GLdouble* params)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetDoublev(pname, params);
+}
+
+void gl4_1core_glGetBooleanv(void *_glfuncs, GLenum pname, GLboolean* params)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetBooleanv(pname, params);
+}
+
+void gl4_1core_glReadPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum gltype, GLvoid* pixels)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glReadPixels(x, y, width, height, format, gltype, pixels);
+}
+
+void gl4_1core_glReadBuffer(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glReadBuffer(mode);
+}
+
+void gl4_1core_glPixelStorei(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glPixelStorei(pname, param);
+}
+
+void gl4_1core_glPixelStoref(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glPixelStoref(pname, param);
+}
+
+void gl4_1core_glDepthFunc(void *_glfuncs, GLenum glfunc)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glDepthFunc(glfunc);
+}
+
+void gl4_1core_glStencilOp(void *_glfuncs, GLenum fail, GLenum zfail, GLenum zpass)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glStencilOp(fail, zfail, zpass);
+}
+
+void gl4_1core_glStencilFunc(void *_glfuncs, GLenum glfunc, GLint ref, GLuint mask)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glStencilFunc(glfunc, ref, mask);
+}
+
+void gl4_1core_glLogicOp(void *_glfuncs, GLenum opcode)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glLogicOp(opcode);
+}
+
+void gl4_1core_glBlendFunc(void *_glfuncs, GLenum sfactor, GLenum dfactor)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glBlendFunc(sfactor, dfactor);
+}
+
+void gl4_1core_glFlush(void *_glfuncs)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glFlush();
+}
+
+void gl4_1core_glFinish(void *_glfuncs)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glFinish();
+}
+
+void gl4_1core_glEnable(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glEnable(cap);
+}
+
+void gl4_1core_glDisable(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glDisable(cap);
+}
+
+void gl4_1core_glDepthMask(void *_glfuncs, GLboolean flag)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glDepthMask(flag);
+}
+
+void gl4_1core_glColorMask(void *_glfuncs, GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glColorMask(red, green, blue, alpha);
+}
+
+void gl4_1core_glStencilMask(void *_glfuncs, GLuint mask)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glStencilMask(mask);
+}
+
+void gl4_1core_glClearDepth(void *_glfuncs, GLdouble depth)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glClearDepth(depth);
+}
+
+void gl4_1core_glClearStencil(void *_glfuncs, GLint s)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glClearStencil(s);
+}
+
+void gl4_1core_glClearColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glClearColor(red, green, blue, alpha);
+}
+
+void gl4_1core_glClear(void *_glfuncs, GLbitfield mask)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glClear(mask);
+}
+
+void gl4_1core_glDrawBuffer(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glDrawBuffer(mode);
+}
+
+void gl4_1core_glTexImage2D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glTexImage2D(target, level, internalFormat, width, height, border, format, gltype, pixels);
+}
+
+void gl4_1core_glTexImage1D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glTexImage1D(target, level, internalFormat, width, border, format, gltype, pixels);
+}
+
+void gl4_1core_glTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glTexParameteriv(target, pname, params);
+}
+
+void gl4_1core_glTexParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glTexParameteri(target, pname, param);
+}
+
+void gl4_1core_glTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glTexParameterfv(target, pname, params);
+}
+
+void gl4_1core_glTexParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glTexParameterf(target, pname, param);
+}
+
+void gl4_1core_glScissor(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glScissor(x, y, width, height);
+}
+
+void gl4_1core_glPolygonMode(void *_glfuncs, GLenum face, GLenum mode)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glPolygonMode(face, mode);
+}
+
+void gl4_1core_glPointSize(void *_glfuncs, GLfloat size)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glPointSize(size);
+}
+
+void gl4_1core_glLineWidth(void *_glfuncs, GLfloat width)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glLineWidth(width);
+}
+
+void gl4_1core_glHint(void *_glfuncs, GLenum target, GLenum mode)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glHint(target, mode);
+}
+
+void gl4_1core_glFrontFace(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glFrontFace(mode);
+}
+
+void gl4_1core_glCullFace(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glCullFace(mode);
+}
+
+void gl4_1core_glIndexubv(void *_glfuncs, const GLubyte* c)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glIndexubv(c);
+}
+
+void gl4_1core_glIndexub(void *_glfuncs, GLubyte c)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glIndexub(c);
+}
+
+GLboolean gl4_1core_glIsTexture(void *_glfuncs, GLuint texture)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ return _qglfuncs->glIsTexture(texture);
+}
+
+void gl4_1core_glGenTextures(void *_glfuncs, GLsizei n, GLuint* textures)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGenTextures(n, textures);
+}
+
+void gl4_1core_glDeleteTextures(void *_glfuncs, GLsizei n, const GLuint* textures)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glDeleteTextures(n, textures);
+}
+
+void gl4_1core_glBindTexture(void *_glfuncs, GLenum target, GLuint texture)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glBindTexture(target, texture);
+}
+
+void gl4_1core_glTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glTexSubImage2D(target, level, xoffset, yoffset, width, height, format, gltype, pixels);
+}
+
+void gl4_1core_glTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glTexSubImage1D(target, level, xoffset, width, format, gltype, pixels);
+}
+
+void gl4_1core_glCopyTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage2D(target, level, xoffset, yoffset, x, y, width, height);
+}
+
+void gl4_1core_glCopyTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage1D(target, level, xoffset, x, y, width);
+}
+
+void gl4_1core_glCopyTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glCopyTexImage2D(target, level, internalFormat, x, y, width, height, border);
+}
+
+void gl4_1core_glCopyTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLint border)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glCopyTexImage1D(target, level, internalFormat, x, y, width, border);
+}
+
+void gl4_1core_glPolygonOffset(void *_glfuncs, GLfloat factor, GLfloat units)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glPolygonOffset(factor, units);
+}
+
+void gl4_1core_glDrawElements(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glDrawElements(mode, count, gltype, indices);
+}
+
+void gl4_1core_glDrawArrays(void *_glfuncs, GLenum mode, GLint first, GLsizei count)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glDrawArrays(mode, first, count);
+}
+
+void gl4_1core_glCopyTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage3D(target, level, xoffset, yoffset, zoffset, x, y, width, height);
+}
+
+void gl4_1core_glTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glTexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, gltype, pixels);
+}
+
+void gl4_1core_glTexImage3D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glTexImage3D(target, level, internalFormat, width, height, depth, border, format, gltype, pixels);
+}
+
+void gl4_1core_glDrawRangeElements(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glDrawRangeElements(mode, start, end, count, gltype, indices);
+}
+
+void gl4_1core_glBlendEquation(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glBlendEquation(mode);
+}
+
+void gl4_1core_glBlendColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glBlendColor(red, green, blue, alpha);
+}
+
+void gl4_1core_glGetCompressedTexImage(void *_glfuncs, GLenum target, GLint level, GLvoid* img)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetCompressedTexImage(target, level, img);
+}
+
+void gl4_1core_glCompressedTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glCompressedTexSubImage1D(target, level, xoffset, width, format, imageSize, data);
+}
+
+void gl4_1core_glCompressedTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glCompressedTexSubImage2D(target, level, xoffset, yoffset, width, height, format, imageSize, data);
+}
+
+void gl4_1core_glCompressedTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glCompressedTexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, imageSize, data);
+}
+
+void gl4_1core_glCompressedTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glCompressedTexImage1D(target, level, internalFormat, width, border, imageSize, data);
+}
+
+void gl4_1core_glCompressedTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glCompressedTexImage2D(target, level, internalFormat, width, height, border, imageSize, data);
+}
+
+void gl4_1core_glCompressedTexImage3D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glCompressedTexImage3D(target, level, internalFormat, width, height, depth, border, imageSize, data);
+}
+
+void gl4_1core_glSampleCoverage(void *_glfuncs, GLfloat value, GLboolean invert)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glSampleCoverage(value, invert);
+}
+
+void gl4_1core_glActiveTexture(void *_glfuncs, GLenum texture)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glActiveTexture(texture);
+}
+
+void gl4_1core_glPointParameteriv(void *_glfuncs, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glPointParameteriv(pname, params);
+}
+
+void gl4_1core_glPointParameteri(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glPointParameteri(pname, param);
+}
+
+void gl4_1core_glPointParameterfv(void *_glfuncs, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glPointParameterfv(pname, params);
+}
+
+void gl4_1core_glPointParameterf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glPointParameterf(pname, param);
+}
+
+void gl4_1core_glMultiDrawArrays(void *_glfuncs, GLenum mode, const GLint* first, const GLsizei* count, GLsizei drawcount)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glMultiDrawArrays(mode, first, count, drawcount);
+}
+
+void gl4_1core_glBlendFuncSeparate(void *_glfuncs, GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glBlendFuncSeparate(sfactorRGB, dfactorRGB, sfactorAlpha, dfactorAlpha);
+}
+
+void gl4_1core_glGetBufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetBufferParameteriv(target, pname, params);
+}
+
+GLboolean gl4_1core_glUnmapBuffer(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ return _qglfuncs->glUnmapBuffer(target);
+}
+
+void gl4_1core_glGetBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, GLvoid* data)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetBufferSubData(target, offset, size, data);
+}
+
+void gl4_1core_glBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid* data)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glBufferSubData(target, offset, size, data);
+}
+
+void gl4_1core_glBufferData(void *_glfuncs, GLenum target, GLsizeiptr size, const GLvoid* data, GLenum usage)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glBufferData(target, size, data, usage);
+}
+
+GLboolean gl4_1core_glIsBuffer(void *_glfuncs, GLuint buffer)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ return _qglfuncs->glIsBuffer(buffer);
+}
+
+void gl4_1core_glGenBuffers(void *_glfuncs, GLsizei n, GLuint* buffers)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGenBuffers(n, buffers);
+}
+
+void gl4_1core_glDeleteBuffers(void *_glfuncs, GLsizei n, const GLuint* buffers)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glDeleteBuffers(n, buffers);
+}
+
+void gl4_1core_glBindBuffer(void *_glfuncs, GLenum target, GLuint buffer)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glBindBuffer(target, buffer);
+}
+
+void gl4_1core_glGetQueryObjectuiv(void *_glfuncs, GLuint id, GLenum pname, GLuint* params)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetQueryObjectuiv(id, pname, params);
+}
+
+void gl4_1core_glGetQueryObjectiv(void *_glfuncs, GLuint id, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetQueryObjectiv(id, pname, params);
+}
+
+void gl4_1core_glGetQueryiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetQueryiv(target, pname, params);
+}
+
+void gl4_1core_glEndQuery(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glEndQuery(target);
+}
+
+void gl4_1core_glBeginQuery(void *_glfuncs, GLenum target, GLuint id)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glBeginQuery(target, id);
+}
+
+GLboolean gl4_1core_glIsQuery(void *_glfuncs, GLuint id)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ return _qglfuncs->glIsQuery(id);
+}
+
+void gl4_1core_glDeleteQueries(void *_glfuncs, GLsizei n, const GLuint* ids)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glDeleteQueries(n, ids);
+}
+
+void gl4_1core_glGenQueries(void *_glfuncs, GLsizei n, GLuint* ids)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGenQueries(n, ids);
+}
+
+void gl4_1core_glVertexAttribPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLboolean normalized, GLsizei stride, const GLvoid* offset)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribPointer(index, size, gltype, normalized, stride, offset);
+}
+
+void gl4_1core_glValidateProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glValidateProgram(program);
+}
+
+void gl4_1core_glUniformMatrix4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4fv(location, count, transpose, value);
+}
+
+void gl4_1core_glUniformMatrix3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3fv(location, count, transpose, value);
+}
+
+void gl4_1core_glUniformMatrix2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2fv(location, count, transpose, value);
+}
+
+void gl4_1core_glUniform4iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glUniform4iv(location, count, value);
+}
+
+void gl4_1core_glUniform3iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glUniform3iv(location, count, value);
+}
+
+void gl4_1core_glUniform2iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glUniform2iv(location, count, value);
+}
+
+void gl4_1core_glUniform1iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glUniform1iv(location, count, value);
+}
+
+void gl4_1core_glUniform4fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glUniform4fv(location, count, value);
+}
+
+void gl4_1core_glUniform3fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glUniform3fv(location, count, value);
+}
+
+void gl4_1core_glUniform2fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glUniform2fv(location, count, value);
+}
+
+void gl4_1core_glUniform1fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glUniform1fv(location, count, value);
+}
+
+void gl4_1core_glUniform4i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2, GLint v3)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glUniform4i(location, v0, v1, v2, v3);
+}
+
+void gl4_1core_glUniform3i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glUniform3i(location, v0, v1, v2);
+}
+
+void gl4_1core_glUniform2i(void *_glfuncs, GLint location, GLint v0, GLint v1)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glUniform2i(location, v0, v1);
+}
+
+void gl4_1core_glUniform1i(void *_glfuncs, GLint location, GLint v0)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glUniform1i(location, v0);
+}
+
+void gl4_1core_glUniform4f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glUniform4f(location, v0, v1, v2, v3);
+}
+
+void gl4_1core_glUniform3f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glUniform3f(location, v0, v1, v2);
+}
+
+void gl4_1core_glUniform2f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glUniform2f(location, v0, v1);
+}
+
+void gl4_1core_glUniform1f(void *_glfuncs, GLint location, GLfloat v0)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glUniform1f(location, v0);
+}
+
+void gl4_1core_glUseProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glUseProgram(program);
+}
+
+void gl4_1core_glShaderSource(void *_glfuncs, GLuint shader, GLsizei count, const GLchar** source, const GLint* length)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glShaderSource(shader, count, source, length);
+}
+
+void gl4_1core_glLinkProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glLinkProgram(program);
+}
+
+GLboolean gl4_1core_glIsShader(void *_glfuncs, GLuint shader)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ return _qglfuncs->glIsShader(shader);
+}
+
+GLboolean gl4_1core_glIsProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ return _qglfuncs->glIsProgram(program);
+}
+
+void gl4_1core_glGetVertexAttribiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribiv(index, pname, params);
+}
+
+void gl4_1core_glGetVertexAttribfv(void *_glfuncs, GLuint index, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribfv(index, pname, params);
+}
+
+void gl4_1core_glGetVertexAttribdv(void *_glfuncs, GLuint index, GLenum pname, GLdouble* params)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribdv(index, pname, params);
+}
+
+void gl4_1core_glGetUniformiv(void *_glfuncs, GLuint program, GLint location, GLint* params)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetUniformiv(program, location, params);
+}
+
+void gl4_1core_glGetUniformfv(void *_glfuncs, GLuint program, GLint location, GLfloat* params)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetUniformfv(program, location, params);
+}
+
+GLint gl4_1core_glGetUniformLocation(void *_glfuncs, GLuint program, const GLchar* name)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ return _qglfuncs->glGetUniformLocation(program, name);
+}
+
+void gl4_1core_glGetShaderSource(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* source)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetShaderSource(shader, bufSize, length, source);
+}
+
+void gl4_1core_glGetShaderInfoLog(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* infoLog)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetShaderInfoLog(shader, bufSize, length, infoLog);
+}
+
+void gl4_1core_glGetShaderiv(void *_glfuncs, GLuint shader, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetShaderiv(shader, pname, params);
+}
+
+void gl4_1core_glGetProgramInfoLog(void *_glfuncs, GLuint program, GLsizei bufSize, GLsizei* length, GLchar* infoLog)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetProgramInfoLog(program, bufSize, length, infoLog);
+}
+
+void gl4_1core_glGetProgramiv(void *_glfuncs, GLuint program, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetProgramiv(program, pname, params);
+}
+
+GLint gl4_1core_glGetAttribLocation(void *_glfuncs, GLuint program, const GLchar* name)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ return _qglfuncs->glGetAttribLocation(program, name);
+}
+
+void gl4_1core_glGetAttachedShaders(void *_glfuncs, GLuint program, GLsizei maxCount, GLsizei* count, GLuint* obj)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetAttachedShaders(program, maxCount, count, obj);
+}
+
+void gl4_1core_glGetActiveUniform(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetActiveUniform(program, index, bufSize, length, size, gltype, name);
+}
+
+void gl4_1core_glGetActiveAttrib(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetActiveAttrib(program, index, bufSize, length, size, gltype, name);
+}
+
+void gl4_1core_glEnableVertexAttribArray(void *_glfuncs, GLuint index)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glEnableVertexAttribArray(index);
+}
+
+void gl4_1core_glDisableVertexAttribArray(void *_glfuncs, GLuint index)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glDisableVertexAttribArray(index);
+}
+
+void gl4_1core_glDetachShader(void *_glfuncs, GLuint program, GLuint shader)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glDetachShader(program, shader);
+}
+
+void gl4_1core_glDeleteShader(void *_glfuncs, GLuint shader)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glDeleteShader(shader);
+}
+
+void gl4_1core_glDeleteProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glDeleteProgram(program);
+}
+
+GLuint gl4_1core_glCreateShader(void *_glfuncs, GLenum gltype)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ return _qglfuncs->glCreateShader(gltype);
+}
+
+GLuint gl4_1core_glCreateProgram(void *_glfuncs)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ return _qglfuncs->glCreateProgram();
+}
+
+void gl4_1core_glCompileShader(void *_glfuncs, GLuint shader)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glCompileShader(shader);
+}
+
+void gl4_1core_glBindAttribLocation(void *_glfuncs, GLuint program, GLuint index, const GLchar* name)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glBindAttribLocation(program, index, name);
+}
+
+void gl4_1core_glAttachShader(void *_glfuncs, GLuint program, GLuint shader)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glAttachShader(program, shader);
+}
+
+void gl4_1core_glStencilMaskSeparate(void *_glfuncs, GLenum face, GLuint mask)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glStencilMaskSeparate(face, mask);
+}
+
+void gl4_1core_glStencilFuncSeparate(void *_glfuncs, GLenum face, GLenum glfunc, GLint ref, GLuint mask)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glStencilFuncSeparate(face, glfunc, ref, mask);
+}
+
+void gl4_1core_glStencilOpSeparate(void *_glfuncs, GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glStencilOpSeparate(face, sfail, dpfail, dppass);
+}
+
+void gl4_1core_glDrawBuffers(void *_glfuncs, GLsizei n, const GLenum* bufs)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glDrawBuffers(n, bufs);
+}
+
+void gl4_1core_glBlendEquationSeparate(void *_glfuncs, GLenum modeRGB, GLenum modeAlpha)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glBlendEquationSeparate(modeRGB, modeAlpha);
+}
+
+void gl4_1core_glUniformMatrix4x3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4x3fv(location, count, transpose, value);
+}
+
+void gl4_1core_glUniformMatrix3x4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3x4fv(location, count, transpose, value);
+}
+
+void gl4_1core_glUniformMatrix4x2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4x2fv(location, count, transpose, value);
+}
+
+void gl4_1core_glUniformMatrix2x4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2x4fv(location, count, transpose, value);
+}
+
+void gl4_1core_glUniformMatrix3x2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3x2fv(location, count, transpose, value);
+}
+
+void gl4_1core_glUniformMatrix2x3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2x3fv(location, count, transpose, value);
+}
+
+GLboolean gl4_1core_glIsVertexArray(void *_glfuncs, GLuint array)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ return _qglfuncs->glIsVertexArray(array);
+}
+
+void gl4_1core_glGenVertexArrays(void *_glfuncs, GLsizei n, GLuint* arrays)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGenVertexArrays(n, arrays);
+}
+
+void gl4_1core_glDeleteVertexArrays(void *_glfuncs, GLsizei n, const GLuint* arrays)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glDeleteVertexArrays(n, arrays);
+}
+
+void gl4_1core_glBindVertexArray(void *_glfuncs, GLuint array)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glBindVertexArray(array);
+}
+
+void gl4_1core_glFlushMappedBufferRange(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr length)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glFlushMappedBufferRange(target, offset, length);
+}
+
+void gl4_1core_glFramebufferTextureLayer(void *_glfuncs, GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glFramebufferTextureLayer(target, attachment, texture, level, layer);
+}
+
+void gl4_1core_glRenderbufferStorageMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLenum internalFormat, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glRenderbufferStorageMultisample(target, samples, internalFormat, width, height);
+}
+
+void gl4_1core_glBlitFramebuffer(void *_glfuncs, GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glBlitFramebuffer(srcX0, srcY0, srcX1, srcY1, dstX0, dstY0, dstX1, dstY1, mask, filter);
+}
+
+void gl4_1core_glGenerateMipmap(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGenerateMipmap(target);
+}
+
+void gl4_1core_glGetFramebufferAttachmentParameteriv(void *_glfuncs, GLenum target, GLenum attachment, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetFramebufferAttachmentParameteriv(target, attachment, pname, params);
+}
+
+void gl4_1core_glFramebufferRenderbuffer(void *_glfuncs, GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glFramebufferRenderbuffer(target, attachment, renderbuffertarget, renderbuffer);
+}
+
+void gl4_1core_glFramebufferTexture3D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glFramebufferTexture3D(target, attachment, textarget, texture, level, zoffset);
+}
+
+void gl4_1core_glFramebufferTexture2D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glFramebufferTexture2D(target, attachment, textarget, texture, level);
+}
+
+void gl4_1core_glFramebufferTexture1D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glFramebufferTexture1D(target, attachment, textarget, texture, level);
+}
+
+GLenum gl4_1core_glCheckFramebufferStatus(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ return _qglfuncs->glCheckFramebufferStatus(target);
+}
+
+void gl4_1core_glGenFramebuffers(void *_glfuncs, GLsizei n, GLuint* framebuffers)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGenFramebuffers(n, framebuffers);
+}
+
+void gl4_1core_glDeleteFramebuffers(void *_glfuncs, GLsizei n, const GLuint* framebuffers)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glDeleteFramebuffers(n, framebuffers);
+}
+
+void gl4_1core_glBindFramebuffer(void *_glfuncs, GLenum target, GLuint framebuffer)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glBindFramebuffer(target, framebuffer);
+}
+
+GLboolean gl4_1core_glIsFramebuffer(void *_glfuncs, GLuint framebuffer)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ return _qglfuncs->glIsFramebuffer(framebuffer);
+}
+
+void gl4_1core_glGetRenderbufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetRenderbufferParameteriv(target, pname, params);
+}
+
+void gl4_1core_glRenderbufferStorage(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glRenderbufferStorage(target, internalFormat, width, height);
+}
+
+void gl4_1core_glGenRenderbuffers(void *_glfuncs, GLsizei n, GLuint* renderbuffers)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGenRenderbuffers(n, renderbuffers);
+}
+
+void gl4_1core_glDeleteRenderbuffers(void *_glfuncs, GLsizei n, const GLuint* renderbuffers)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glDeleteRenderbuffers(n, renderbuffers);
+}
+
+void gl4_1core_glBindRenderbuffer(void *_glfuncs, GLenum target, GLuint renderbuffer)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glBindRenderbuffer(target, renderbuffer);
+}
+
+GLboolean gl4_1core_glIsRenderbuffer(void *_glfuncs, GLuint renderbuffer)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ return _qglfuncs->glIsRenderbuffer(renderbuffer);
+}
+
+void gl4_1core_glClearBufferfi(void *_glfuncs, GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glClearBufferfi(buffer, drawbuffer, depth, stencil);
+}
+
+void gl4_1core_glClearBufferfv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLfloat* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glClearBufferfv(buffer, drawbuffer, value);
+}
+
+void gl4_1core_glClearBufferuiv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLuint* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glClearBufferuiv(buffer, drawbuffer, value);
+}
+
+void gl4_1core_glClearBufferiv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLint* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glClearBufferiv(buffer, drawbuffer, value);
+}
+
+void gl4_1core_glGetTexParameterIuiv(void *_glfuncs, GLenum target, GLenum pname, GLuint* params)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetTexParameterIuiv(target, pname, params);
+}
+
+void gl4_1core_glGetTexParameterIiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetTexParameterIiv(target, pname, params);
+}
+
+void gl4_1core_glTexParameterIuiv(void *_glfuncs, GLenum target, GLenum pname, const GLuint* params)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glTexParameterIuiv(target, pname, params);
+}
+
+void gl4_1core_glTexParameterIiv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glTexParameterIiv(target, pname, params);
+}
+
+void gl4_1core_glUniform4uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glUniform4uiv(location, count, value);
+}
+
+void gl4_1core_glUniform3uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glUniform3uiv(location, count, value);
+}
+
+void gl4_1core_glUniform2uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glUniform2uiv(location, count, value);
+}
+
+void gl4_1core_glUniform1uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glUniform1uiv(location, count, value);
+}
+
+void gl4_1core_glUniform4ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glUniform4ui(location, v0, v1, v2, v3);
+}
+
+void gl4_1core_glUniform3ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1, GLuint v2)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glUniform3ui(location, v0, v1, v2);
+}
+
+void gl4_1core_glUniform2ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glUniform2ui(location, v0, v1);
+}
+
+void gl4_1core_glUniform1ui(void *_glfuncs, GLint location, GLuint v0)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glUniform1ui(location, v0);
+}
+
+GLint gl4_1core_glGetFragDataLocation(void *_glfuncs, GLuint program, const GLchar* name)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ return _qglfuncs->glGetFragDataLocation(program, name);
+}
+
+void gl4_1core_glBindFragDataLocation(void *_glfuncs, GLuint program, GLuint color, const GLchar* name)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glBindFragDataLocation(program, color, name);
+}
+
+void gl4_1core_glGetUniformuiv(void *_glfuncs, GLuint program, GLint location, GLuint* params)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetUniformuiv(program, location, params);
+}
+
+void gl4_1core_glGetVertexAttribIuiv(void *_glfuncs, GLuint index, GLenum pname, GLuint* params)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribIuiv(index, pname, params);
+}
+
+void gl4_1core_glGetVertexAttribIiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribIiv(index, pname, params);
+}
+
+void gl4_1core_glVertexAttribIPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribIPointer(index, size, gltype, stride, pointer);
+}
+
+void gl4_1core_glEndConditionalRender(void *_glfuncs)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glEndConditionalRender();
+}
+
+void gl4_1core_glBeginConditionalRender(void *_glfuncs, GLuint id, GLenum mode)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glBeginConditionalRender(id, mode);
+}
+
+void gl4_1core_glClampColor(void *_glfuncs, GLenum target, GLenum clamp)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glClampColor(target, clamp);
+}
+
+void gl4_1core_glGetTransformFeedbackVarying(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLsizei* size, GLenum* gltype, GLchar* name)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetTransformFeedbackVarying(program, index, bufSize, length, size, gltype, name);
+}
+
+void gl4_1core_glBindBufferBase(void *_glfuncs, GLenum target, GLuint index, GLuint buffer)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glBindBufferBase(target, index, buffer);
+}
+
+void gl4_1core_glBindBufferRange(void *_glfuncs, GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glBindBufferRange(target, index, buffer, offset, size);
+}
+
+void gl4_1core_glEndTransformFeedback(void *_glfuncs)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glEndTransformFeedback();
+}
+
+void gl4_1core_glBeginTransformFeedback(void *_glfuncs, GLenum primitiveMode)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glBeginTransformFeedback(primitiveMode);
+}
+
+GLboolean gl4_1core_glIsEnabledi(void *_glfuncs, GLenum target, GLuint index)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ return _qglfuncs->glIsEnabledi(target, index);
+}
+
+void gl4_1core_glDisablei(void *_glfuncs, GLenum target, GLuint index)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glDisablei(target, index);
+}
+
+void gl4_1core_glEnablei(void *_glfuncs, GLenum target, GLuint index)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glEnablei(target, index);
+}
+
+void gl4_1core_glGetIntegeri_v(void *_glfuncs, GLenum target, GLuint index, GLint* data)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetIntegeri_v(target, index, data);
+}
+
+void gl4_1core_glGetBooleani_v(void *_glfuncs, GLenum target, GLuint index, GLboolean* data)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetBooleani_v(target, index, data);
+}
+
+void gl4_1core_glColorMaski(void *_glfuncs, GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glColorMaski(index, r, g, b, a);
+}
+
+void gl4_1core_glCopyBufferSubData(void *_glfuncs, GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glCopyBufferSubData(readTarget, writeTarget, readOffset, writeOffset, size);
+}
+
+void gl4_1core_glUniformBlockBinding(void *_glfuncs, GLuint program, GLuint v0, GLuint v1)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glUniformBlockBinding(program, v0, v1);
+}
+
+void gl4_1core_glGetActiveUniformBlockName(void *_glfuncs, GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei* length, GLchar* uniformBlockName)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetActiveUniformBlockName(program, uniformBlockIndex, bufSize, length, uniformBlockName);
+}
+
+void gl4_1core_glGetActiveUniformBlockiv(void *_glfuncs, GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetActiveUniformBlockiv(program, uniformBlockIndex, pname, params);
+}
+
+GLuint gl4_1core_glGetUniformBlockIndex(void *_glfuncs, GLuint program, const GLchar* uniformBlockName)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ return _qglfuncs->glGetUniformBlockIndex(program, uniformBlockName);
+}
+
+void gl4_1core_glGetActiveUniformName(void *_glfuncs, GLuint program, GLuint uniformIndex, GLsizei bufSize, GLsizei* length, GLchar* uniformName)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetActiveUniformName(program, uniformIndex, bufSize, length, uniformName);
+}
+
+void gl4_1core_glGetActiveUniformsiv(void *_glfuncs, GLuint program, GLsizei uniformCount, const GLuint* uniformIndices, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetActiveUniformsiv(program, uniformCount, uniformIndices, pname, params);
+}
+
+void gl4_1core_glPrimitiveRestartIndex(void *_glfuncs, GLuint index)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glPrimitiveRestartIndex(index);
+}
+
+void gl4_1core_glTexBuffer(void *_glfuncs, GLenum target, GLenum internalFormat, GLuint buffer)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glTexBuffer(target, internalFormat, buffer);
+}
+
+void gl4_1core_glDrawElementsInstanced(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glDrawElementsInstanced(mode, count, gltype, indices, instancecount);
+}
+
+void gl4_1core_glDrawArraysInstanced(void *_glfuncs, GLenum mode, GLint first, GLsizei count, GLsizei instancecount)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glDrawArraysInstanced(mode, first, count, instancecount);
+}
+
+void gl4_1core_glSampleMaski(void *_glfuncs, GLuint index, GLbitfield mask)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glSampleMaski(index, mask);
+}
+
+void gl4_1core_glGetMultisamplefv(void *_glfuncs, GLenum pname, GLuint index, GLfloat* val)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetMultisamplefv(pname, index, val);
+}
+
+void gl4_1core_glTexImage3DMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glTexImage3DMultisample(target, samples, internalFormat, width, height, depth, fixedsamplelocations);
+}
+
+void gl4_1core_glTexImage2DMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLint internalFormat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glTexImage2DMultisample(target, samples, internalFormat, width, height, fixedsamplelocations);
+}
+
+void gl4_1core_glGetSynciv(void *_glfuncs, GLsync sync, GLenum pname, GLsizei bufSize, GLsizei* length, GLint* values)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetSynciv(sync, pname, bufSize, length, values);
+}
+
+void gl4_1core_glGetInteger64v(void *_glfuncs, GLenum pname, GLint64* params)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetInteger64v(pname, params);
+}
+
+void gl4_1core_glWaitSync(void *_glfuncs, GLsync sync, GLbitfield flags, GLuint64 timeout)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glWaitSync(sync, flags, timeout);
+}
+
+GLenum gl4_1core_glClientWaitSync(void *_glfuncs, GLsync sync, GLbitfield flags, GLuint64 timeout)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ return _qglfuncs->glClientWaitSync(sync, flags, timeout);
+}
+
+void gl4_1core_glDeleteSync(void *_glfuncs, GLsync sync)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glDeleteSync(sync);
+}
+
+GLboolean gl4_1core_glIsSync(void *_glfuncs, GLsync sync)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ return _qglfuncs->glIsSync(sync);
+}
+
+GLsync gl4_1core_glFenceSync(void *_glfuncs, GLenum condition, GLbitfield flags)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ return _qglfuncs->glFenceSync(condition, flags);
+}
+
+void gl4_1core_glProvokingVertex(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glProvokingVertex(mode);
+}
+
+void gl4_1core_glDrawElementsInstancedBaseVertex(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount, GLint basevertex)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glDrawElementsInstancedBaseVertex(mode, count, gltype, indices, instancecount, basevertex);
+}
+
+void gl4_1core_glDrawRangeElementsBaseVertex(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices, GLint basevertex)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glDrawRangeElementsBaseVertex(mode, start, end, count, gltype, indices, basevertex);
+}
+
+void gl4_1core_glDrawElementsBaseVertex(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLint basevertex)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glDrawElementsBaseVertex(mode, count, gltype, indices, basevertex);
+}
+
+void gl4_1core_glFramebufferTexture(void *_glfuncs, GLenum target, GLenum attachment, GLuint texture, GLint level)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glFramebufferTexture(target, attachment, texture, level);
+}
+
+void gl4_1core_glGetBufferParameteri64v(void *_glfuncs, GLenum target, GLenum pname, GLint64* params)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetBufferParameteri64v(target, pname, params);
+}
+
+void gl4_1core_glGetInteger64i_v(void *_glfuncs, GLenum target, GLuint index, GLint64* data)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetInteger64i_v(target, index, data);
+}
+
+void gl4_1core_glVertexAttribP4uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribP4uiv(index, gltype, normalized, value);
+}
+
+void gl4_1core_glVertexAttribP4ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribP4ui(index, gltype, normalized, value);
+}
+
+void gl4_1core_glVertexAttribP3uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribP3uiv(index, gltype, normalized, value);
+}
+
+void gl4_1core_glVertexAttribP3ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribP3ui(index, gltype, normalized, value);
+}
+
+void gl4_1core_glVertexAttribP2uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribP2uiv(index, gltype, normalized, value);
+}
+
+void gl4_1core_glVertexAttribP2ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribP2ui(index, gltype, normalized, value);
+}
+
+void gl4_1core_glVertexAttribP1uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribP1uiv(index, gltype, normalized, value);
+}
+
+void gl4_1core_glVertexAttribP1ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribP1ui(index, gltype, normalized, value);
+}
+
+void gl4_1core_glSecondaryColorP3uiv(void *_glfuncs, GLenum gltype, const GLuint* color)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glSecondaryColorP3uiv(gltype, color);
+}
+
+void gl4_1core_glSecondaryColorP3ui(void *_glfuncs, GLenum gltype, GLuint color)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glSecondaryColorP3ui(gltype, color);
+}
+
+void gl4_1core_glColorP4uiv(void *_glfuncs, GLenum gltype, const GLuint* color)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glColorP4uiv(gltype, color);
+}
+
+void gl4_1core_glColorP4ui(void *_glfuncs, GLenum gltype, GLuint color)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glColorP4ui(gltype, color);
+}
+
+void gl4_1core_glColorP3uiv(void *_glfuncs, GLenum gltype, const GLuint* color)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glColorP3uiv(gltype, color);
+}
+
+void gl4_1core_glColorP3ui(void *_glfuncs, GLenum gltype, GLuint color)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glColorP3ui(gltype, color);
+}
+
+void gl4_1core_glNormalP3uiv(void *_glfuncs, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glNormalP3uiv(gltype, coords);
+}
+
+void gl4_1core_glNormalP3ui(void *_glfuncs, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glNormalP3ui(gltype, coords);
+}
+
+void gl4_1core_glMultiTexCoordP4uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP4uiv(texture, gltype, coords);
+}
+
+void gl4_1core_glMultiTexCoordP4ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP4ui(texture, gltype, coords);
+}
+
+void gl4_1core_glMultiTexCoordP3uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP3uiv(texture, gltype, coords);
+}
+
+void gl4_1core_glMultiTexCoordP3ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP3ui(texture, gltype, coords);
+}
+
+void gl4_1core_glMultiTexCoordP2uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP2uiv(texture, gltype, coords);
+}
+
+void gl4_1core_glMultiTexCoordP2ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP2ui(texture, gltype, coords);
+}
+
+void gl4_1core_glMultiTexCoordP1uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP1uiv(texture, gltype, coords);
+}
+
+void gl4_1core_glMultiTexCoordP1ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP1ui(texture, gltype, coords);
+}
+
+void gl4_1core_glTexCoordP4uiv(void *_glfuncs, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glTexCoordP4uiv(gltype, coords);
+}
+
+void gl4_1core_glTexCoordP4ui(void *_glfuncs, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glTexCoordP4ui(gltype, coords);
+}
+
+void gl4_1core_glTexCoordP3uiv(void *_glfuncs, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glTexCoordP3uiv(gltype, coords);
+}
+
+void gl4_1core_glTexCoordP3ui(void *_glfuncs, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glTexCoordP3ui(gltype, coords);
+}
+
+void gl4_1core_glTexCoordP2uiv(void *_glfuncs, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glTexCoordP2uiv(gltype, coords);
+}
+
+void gl4_1core_glTexCoordP2ui(void *_glfuncs, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glTexCoordP2ui(gltype, coords);
+}
+
+void gl4_1core_glTexCoordP1uiv(void *_glfuncs, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glTexCoordP1uiv(gltype, coords);
+}
+
+void gl4_1core_glTexCoordP1ui(void *_glfuncs, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glTexCoordP1ui(gltype, coords);
+}
+
+void gl4_1core_glVertexP4uiv(void *_glfuncs, GLenum gltype, const GLuint* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glVertexP4uiv(gltype, value);
+}
+
+void gl4_1core_glVertexP4ui(void *_glfuncs, GLenum gltype, GLuint value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glVertexP4ui(gltype, value);
+}
+
+void gl4_1core_glVertexP3uiv(void *_glfuncs, GLenum gltype, const GLuint* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glVertexP3uiv(gltype, value);
+}
+
+void gl4_1core_glVertexP3ui(void *_glfuncs, GLenum gltype, GLuint value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glVertexP3ui(gltype, value);
+}
+
+void gl4_1core_glVertexP2uiv(void *_glfuncs, GLenum gltype, const GLuint* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glVertexP2uiv(gltype, value);
+}
+
+void gl4_1core_glVertexP2ui(void *_glfuncs, GLenum gltype, GLuint value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glVertexP2ui(gltype, value);
+}
+
+void gl4_1core_glGetQueryObjectui64v(void *_glfuncs, GLuint id, GLenum pname, GLuint64* params)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetQueryObjectui64v(id, pname, params);
+}
+
+void gl4_1core_glGetQueryObjecti64v(void *_glfuncs, GLuint id, GLenum pname, GLint64* params)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetQueryObjecti64v(id, pname, params);
+}
+
+void gl4_1core_glQueryCounter(void *_glfuncs, GLuint id, GLenum target)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glQueryCounter(id, target);
+}
+
+void gl4_1core_glGetSamplerParameterIuiv(void *_glfuncs, GLuint sampler, GLenum pname, GLuint* params)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetSamplerParameterIuiv(sampler, pname, params);
+}
+
+void gl4_1core_glGetSamplerParameterfv(void *_glfuncs, GLuint sampler, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetSamplerParameterfv(sampler, pname, params);
+}
+
+void gl4_1core_glGetSamplerParameterIiv(void *_glfuncs, GLuint sampler, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetSamplerParameterIiv(sampler, pname, params);
+}
+
+void gl4_1core_glGetSamplerParameteriv(void *_glfuncs, GLuint sampler, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetSamplerParameteriv(sampler, pname, params);
+}
+
+void gl4_1core_glSamplerParameterIuiv(void *_glfuncs, GLuint sampler, GLenum pname, const GLuint* param)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glSamplerParameterIuiv(sampler, pname, param);
+}
+
+void gl4_1core_glSamplerParameterIiv(void *_glfuncs, GLuint sampler, GLenum pname, const GLint* param)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glSamplerParameterIiv(sampler, pname, param);
+}
+
+void gl4_1core_glSamplerParameterfv(void *_glfuncs, GLuint sampler, GLenum pname, const GLfloat* param)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glSamplerParameterfv(sampler, pname, param);
+}
+
+void gl4_1core_glSamplerParameterf(void *_glfuncs, GLuint sampler, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glSamplerParameterf(sampler, pname, param);
+}
+
+void gl4_1core_glSamplerParameteriv(void *_glfuncs, GLuint sampler, GLenum pname, const GLint* param)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glSamplerParameteriv(sampler, pname, param);
+}
+
+void gl4_1core_glSamplerParameteri(void *_glfuncs, GLuint sampler, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glSamplerParameteri(sampler, pname, param);
+}
+
+void gl4_1core_glBindSampler(void *_glfuncs, GLuint unit, GLuint sampler)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glBindSampler(unit, sampler);
+}
+
+GLboolean gl4_1core_glIsSampler(void *_glfuncs, GLuint sampler)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ return _qglfuncs->glIsSampler(sampler);
+}
+
+void gl4_1core_glDeleteSamplers(void *_glfuncs, GLsizei count, const GLuint* samplers)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glDeleteSamplers(count, samplers);
+}
+
+void gl4_1core_glGenSamplers(void *_glfuncs, GLsizei count, GLuint* samplers)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGenSamplers(count, samplers);
+}
+
+GLint gl4_1core_glGetFragDataIndex(void *_glfuncs, GLuint program, const GLchar* name)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ return _qglfuncs->glGetFragDataIndex(program, name);
+}
+
+void gl4_1core_glBindFragDataLocationIndexed(void *_glfuncs, GLuint program, GLuint colorNumber, GLuint index, const GLchar* name)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glBindFragDataLocationIndexed(program, colorNumber, index, name);
+}
+
+void gl4_1core_glVertexAttribDivisor(void *_glfuncs, GLuint index, GLuint divisor)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribDivisor(index, divisor);
+}
+
+void gl4_1core_glGetQueryIndexediv(void *_glfuncs, GLenum target, GLuint index, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetQueryIndexediv(target, index, pname, params);
+}
+
+void gl4_1core_glEndQueryIndexed(void *_glfuncs, GLenum target, GLuint index)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glEndQueryIndexed(target, index);
+}
+
+void gl4_1core_glBeginQueryIndexed(void *_glfuncs, GLenum target, GLuint index, GLuint id)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glBeginQueryIndexed(target, index, id);
+}
+
+void gl4_1core_glDrawTransformFeedbackStream(void *_glfuncs, GLenum mode, GLuint id, GLuint stream)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glDrawTransformFeedbackStream(mode, id, stream);
+}
+
+void gl4_1core_glDrawTransformFeedback(void *_glfuncs, GLenum mode, GLuint id)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glDrawTransformFeedback(mode, id);
+}
+
+void gl4_1core_glResumeTransformFeedback(void *_glfuncs)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glResumeTransformFeedback();
+}
+
+void gl4_1core_glPauseTransformFeedback(void *_glfuncs)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glPauseTransformFeedback();
+}
+
+GLboolean gl4_1core_glIsTransformFeedback(void *_glfuncs, GLuint id)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ return _qglfuncs->glIsTransformFeedback(id);
+}
+
+void gl4_1core_glGenTransformFeedbacks(void *_glfuncs, GLsizei n, GLuint* ids)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGenTransformFeedbacks(n, ids);
+}
+
+void gl4_1core_glDeleteTransformFeedbacks(void *_glfuncs, GLsizei n, const GLuint* ids)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glDeleteTransformFeedbacks(n, ids);
+}
+
+void gl4_1core_glBindTransformFeedback(void *_glfuncs, GLenum target, GLuint id)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glBindTransformFeedback(target, id);
+}
+
+void gl4_1core_glPatchParameterfv(void *_glfuncs, GLenum pname, const GLfloat* values)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glPatchParameterfv(pname, values);
+}
+
+void gl4_1core_glPatchParameteri(void *_glfuncs, GLenum pname, GLint value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glPatchParameteri(pname, value);
+}
+
+void gl4_1core_glGetProgramStageiv(void *_glfuncs, GLuint program, GLenum shadertype, GLenum pname, GLint* values)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetProgramStageiv(program, shadertype, pname, values);
+}
+
+void gl4_1core_glGetUniformSubroutineuiv(void *_glfuncs, GLenum shadertype, GLint location, GLuint* params)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetUniformSubroutineuiv(shadertype, location, params);
+}
+
+void gl4_1core_glUniformSubroutinesuiv(void *_glfuncs, GLenum shadertype, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glUniformSubroutinesuiv(shadertype, count, value);
+}
+
+void gl4_1core_glGetActiveSubroutineName(void *_glfuncs, GLuint program, GLenum shadertype, GLuint index, GLsizei bufSize, GLsizei* length, GLchar* name)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetActiveSubroutineName(program, shadertype, index, bufSize, length, name);
+}
+
+void gl4_1core_glGetActiveSubroutineUniformName(void *_glfuncs, GLuint program, GLenum shadertype, GLuint index, GLsizei bufSize, GLsizei* length, GLchar* name)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetActiveSubroutineUniformName(program, shadertype, index, bufSize, length, name);
+}
+
+void gl4_1core_glGetActiveSubroutineUniformiv(void *_glfuncs, GLuint program, GLenum shadertype, GLuint index, GLenum pname, GLint* values)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetActiveSubroutineUniformiv(program, shadertype, index, pname, values);
+}
+
+GLuint gl4_1core_glGetSubroutineIndex(void *_glfuncs, GLuint program, GLenum shadertype, const GLchar* name)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ return _qglfuncs->glGetSubroutineIndex(program, shadertype, name);
+}
+
+GLint gl4_1core_glGetSubroutineUniformLocation(void *_glfuncs, GLuint program, GLenum shadertype, const GLchar* name)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ return _qglfuncs->glGetSubroutineUniformLocation(program, shadertype, name);
+}
+
+void gl4_1core_glGetUniformdv(void *_glfuncs, GLuint program, GLint location, GLdouble* params)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetUniformdv(program, location, params);
+}
+
+void gl4_1core_glUniformMatrix4x3dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4x3dv(location, count, transpose, value);
+}
+
+void gl4_1core_glUniformMatrix4x2dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4x2dv(location, count, transpose, value);
+}
+
+void gl4_1core_glUniformMatrix3x4dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3x4dv(location, count, transpose, value);
+}
+
+void gl4_1core_glUniformMatrix3x2dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3x2dv(location, count, transpose, value);
+}
+
+void gl4_1core_glUniformMatrix2x4dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2x4dv(location, count, transpose, value);
+}
+
+void gl4_1core_glUniformMatrix2x3dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2x3dv(location, count, transpose, value);
+}
+
+void gl4_1core_glUniformMatrix4dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4dv(location, count, transpose, value);
+}
+
+void gl4_1core_glUniformMatrix3dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3dv(location, count, transpose, value);
+}
+
+void gl4_1core_glUniformMatrix2dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2dv(location, count, transpose, value);
+}
+
+void gl4_1core_glUniform4dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glUniform4dv(location, count, value);
+}
+
+void gl4_1core_glUniform3dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glUniform3dv(location, count, value);
+}
+
+void gl4_1core_glUniform2dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glUniform2dv(location, count, value);
+}
+
+void gl4_1core_glUniform1dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glUniform1dv(location, count, value);
+}
+
+void gl4_1core_glUniform4d(void *_glfuncs, GLint location, GLdouble v0, GLdouble v1, GLdouble v2, GLdouble v3)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glUniform4d(location, v0, v1, v2, v3);
+}
+
+void gl4_1core_glUniform3d(void *_glfuncs, GLint location, GLdouble v0, GLdouble v1, GLdouble v2)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glUniform3d(location, v0, v1, v2);
+}
+
+void gl4_1core_glUniform2d(void *_glfuncs, GLint location, GLdouble v0, GLdouble v1)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glUniform2d(location, v0, v1);
+}
+
+void gl4_1core_glUniform1d(void *_glfuncs, GLint location, GLdouble v0)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glUniform1d(location, v0);
+}
+
+void gl4_1core_glDrawElementsIndirect(void *_glfuncs, GLenum mode, GLenum gltype, const GLvoid* indirect)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glDrawElementsIndirect(mode, gltype, indirect);
+}
+
+void gl4_1core_glDrawArraysIndirect(void *_glfuncs, GLenum mode, const GLvoid* indirect)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glDrawArraysIndirect(mode, indirect);
+}
+
+void gl4_1core_glBlendFuncSeparatei(void *_glfuncs, GLuint buf, GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha, GLenum dstAlpha)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glBlendFuncSeparatei(buf, srcRGB, dstRGB, srcAlpha, dstAlpha);
+}
+
+void gl4_1core_glBlendFunci(void *_glfuncs, GLuint buf, GLenum src, GLenum dst)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glBlendFunci(buf, src, dst);
+}
+
+void gl4_1core_glBlendEquationSeparatei(void *_glfuncs, GLuint buf, GLenum modeRGB, GLenum modeAlpha)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glBlendEquationSeparatei(buf, modeRGB, modeAlpha);
+}
+
+void gl4_1core_glBlendEquationi(void *_glfuncs, GLuint buf, GLenum mode)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glBlendEquationi(buf, mode);
+}
+
+void gl4_1core_glMinSampleShading(void *_glfuncs, GLfloat value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glMinSampleShading(value);
+}
+
+void gl4_1core_glGetDoublei_v(void *_glfuncs, GLenum target, GLuint index, GLdouble* data)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetDoublei_v(target, index, data);
+}
+
+void gl4_1core_glGetFloati_v(void *_glfuncs, GLenum target, GLuint index, GLfloat* data)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetFloati_v(target, index, data);
+}
+
+void gl4_1core_glDepthRangeIndexed(void *_glfuncs, GLuint index, GLdouble n, GLdouble f)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glDepthRangeIndexed(index, n, f);
+}
+
+void gl4_1core_glDepthRangeArrayv(void *_glfuncs, GLuint first, GLsizei count, const GLdouble* v)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glDepthRangeArrayv(first, count, v);
+}
+
+void gl4_1core_glScissorIndexedv(void *_glfuncs, GLuint index, const GLint* v)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glScissorIndexedv(index, v);
+}
+
+void gl4_1core_glScissorIndexed(void *_glfuncs, GLuint index, GLint left, GLint bottom, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glScissorIndexed(index, left, bottom, width, height);
+}
+
+void gl4_1core_glScissorArrayv(void *_glfuncs, GLuint first, GLsizei count, const GLint* v)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glScissorArrayv(first, count, v);
+}
+
+void gl4_1core_glViewportIndexedfv(void *_glfuncs, GLuint index, const GLfloat* v)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glViewportIndexedfv(index, v);
+}
+
+void gl4_1core_glViewportIndexedf(void *_glfuncs, GLuint index, GLfloat x, GLfloat y, GLfloat w, GLfloat h)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glViewportIndexedf(index, x, y, w, h);
+}
+
+void gl4_1core_glViewportArrayv(void *_glfuncs, GLuint first, GLsizei count, const GLfloat* v)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glViewportArrayv(first, count, v);
+}
+
+void gl4_1core_glGetVertexAttribLdv(void *_glfuncs, GLuint index, GLenum pname, GLdouble* params)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribLdv(index, pname, params);
+}
+
+void gl4_1core_glVertexAttribLPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribLPointer(index, size, gltype, stride, pointer);
+}
+
+void gl4_1core_glVertexAttribL4dv(void *_glfuncs, GLuint index, const GLdouble* v)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribL4dv(index, v);
+}
+
+void gl4_1core_glVertexAttribL3dv(void *_glfuncs, GLuint index, const GLdouble* v)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribL3dv(index, v);
+}
+
+void gl4_1core_glVertexAttribL2dv(void *_glfuncs, GLuint index, const GLdouble* v)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribL2dv(index, v);
+}
+
+void gl4_1core_glVertexAttribL1dv(void *_glfuncs, GLuint index, const GLdouble* v)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribL1dv(index, v);
+}
+
+void gl4_1core_glVertexAttribL4d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribL4d(index, x, y, z, w);
+}
+
+void gl4_1core_glVertexAttribL3d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribL3d(index, x, y, z);
+}
+
+void gl4_1core_glVertexAttribL2d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribL2d(index, x, y);
+}
+
+void gl4_1core_glVertexAttribL1d(void *_glfuncs, GLuint index, GLdouble x)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribL1d(index, x);
+}
+
+void gl4_1core_glGetProgramPipelineInfoLog(void *_glfuncs, GLuint pipeline, GLsizei bufSize, GLsizei* length, GLchar* infoLog)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetProgramPipelineInfoLog(pipeline, bufSize, length, infoLog);
+}
+
+void gl4_1core_glValidateProgramPipeline(void *_glfuncs, GLuint pipeline)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glValidateProgramPipeline(pipeline);
+}
+
+void gl4_1core_glProgramUniformMatrix4x3dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix4x3dv(program, location, count, transpose, value);
+}
+
+void gl4_1core_glProgramUniformMatrix3x4dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix3x4dv(program, location, count, transpose, value);
+}
+
+void gl4_1core_glProgramUniformMatrix4x2dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix4x2dv(program, location, count, transpose, value);
+}
+
+void gl4_1core_glProgramUniformMatrix2x4dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix2x4dv(program, location, count, transpose, value);
+}
+
+void gl4_1core_glProgramUniformMatrix3x2dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix3x2dv(program, location, count, transpose, value);
+}
+
+void gl4_1core_glProgramUniformMatrix2x3dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix2x3dv(program, location, count, transpose, value);
+}
+
+void gl4_1core_glProgramUniformMatrix4x3fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix4x3fv(program, location, count, transpose, value);
+}
+
+void gl4_1core_glProgramUniformMatrix3x4fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix3x4fv(program, location, count, transpose, value);
+}
+
+void gl4_1core_glProgramUniformMatrix4x2fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix4x2fv(program, location, count, transpose, value);
+}
+
+void gl4_1core_glProgramUniformMatrix2x4fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix2x4fv(program, location, count, transpose, value);
+}
+
+void gl4_1core_glProgramUniformMatrix3x2fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix3x2fv(program, location, count, transpose, value);
+}
+
+void gl4_1core_glProgramUniformMatrix2x3fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix2x3fv(program, location, count, transpose, value);
+}
+
+void gl4_1core_glProgramUniformMatrix4dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix4dv(program, location, count, transpose, value);
+}
+
+void gl4_1core_glProgramUniformMatrix3dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix3dv(program, location, count, transpose, value);
+}
+
+void gl4_1core_glProgramUniformMatrix2dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix2dv(program, location, count, transpose, value);
+}
+
+void gl4_1core_glProgramUniformMatrix4fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix4fv(program, location, count, transpose, value);
+}
+
+void gl4_1core_glProgramUniformMatrix3fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix3fv(program, location, count, transpose, value);
+}
+
+void gl4_1core_glProgramUniformMatrix2fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix2fv(program, location, count, transpose, value);
+}
+
+void gl4_1core_glProgramUniform4uiv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform4uiv(program, location, count, value);
+}
+
+void gl4_1core_glProgramUniform4ui(void *_glfuncs, GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform4ui(program, location, v0, v1, v2, v3);
+}
+
+void gl4_1core_glProgramUniform4dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLdouble* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform4dv(program, location, count, value);
+}
+
+void gl4_1core_glProgramUniform4d(void *_glfuncs, GLuint program, GLint location, GLdouble v0, GLdouble v1, GLdouble v2, GLdouble v3)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform4d(program, location, v0, v1, v2, v3);
+}
+
+void gl4_1core_glProgramUniform4fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform4fv(program, location, count, value);
+}
+
+void gl4_1core_glProgramUniform4f(void *_glfuncs, GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform4f(program, location, v0, v1, v2, v3);
+}
+
+void gl4_1core_glProgramUniform4iv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform4iv(program, location, count, value);
+}
+
+void gl4_1core_glProgramUniform4i(void *_glfuncs, GLuint program, GLint location, GLint v0, GLint v1, GLint v2, GLint v3)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform4i(program, location, v0, v1, v2, v3);
+}
+
+void gl4_1core_glProgramUniform3uiv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform3uiv(program, location, count, value);
+}
+
+void gl4_1core_glProgramUniform3ui(void *_glfuncs, GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform3ui(program, location, v0, v1, v2);
+}
+
+void gl4_1core_glProgramUniform3dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLdouble* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform3dv(program, location, count, value);
+}
+
+void gl4_1core_glProgramUniform3d(void *_glfuncs, GLuint program, GLint location, GLdouble v0, GLdouble v1, GLdouble v2)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform3d(program, location, v0, v1, v2);
+}
+
+void gl4_1core_glProgramUniform3fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform3fv(program, location, count, value);
+}
+
+void gl4_1core_glProgramUniform3f(void *_glfuncs, GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform3f(program, location, v0, v1, v2);
+}
+
+void gl4_1core_glProgramUniform3iv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform3iv(program, location, count, value);
+}
+
+void gl4_1core_glProgramUniform3i(void *_glfuncs, GLuint program, GLint location, GLint v0, GLint v1, GLint v2)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform3i(program, location, v0, v1, v2);
+}
+
+void gl4_1core_glProgramUniform2uiv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform2uiv(program, location, count, value);
+}
+
+void gl4_1core_glProgramUniform2ui(void *_glfuncs, GLuint program, GLint location, GLuint v0, GLuint v1)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform2ui(program, location, v0, v1);
+}
+
+void gl4_1core_glProgramUniform2dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLdouble* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform2dv(program, location, count, value);
+}
+
+void gl4_1core_glProgramUniform2d(void *_glfuncs, GLuint program, GLint location, GLdouble v0, GLdouble v1)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform2d(program, location, v0, v1);
+}
+
+void gl4_1core_glProgramUniform2fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform2fv(program, location, count, value);
+}
+
+void gl4_1core_glProgramUniform2f(void *_glfuncs, GLuint program, GLint location, GLfloat v0, GLfloat v1)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform2f(program, location, v0, v1);
+}
+
+void gl4_1core_glProgramUniform2iv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform2iv(program, location, count, value);
+}
+
+void gl4_1core_glProgramUniform2i(void *_glfuncs, GLuint program, GLint location, GLint v0, GLint v1)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform2i(program, location, v0, v1);
+}
+
+void gl4_1core_glProgramUniform1uiv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform1uiv(program, location, count, value);
+}
+
+void gl4_1core_glProgramUniform1ui(void *_glfuncs, GLuint program, GLint location, GLuint v0)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform1ui(program, location, v0);
+}
+
+void gl4_1core_glProgramUniform1dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLdouble* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform1dv(program, location, count, value);
+}
+
+void gl4_1core_glProgramUniform1d(void *_glfuncs, GLuint program, GLint location, GLdouble v0)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform1d(program, location, v0);
+}
+
+void gl4_1core_glProgramUniform1fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform1fv(program, location, count, value);
+}
+
+void gl4_1core_glProgramUniform1f(void *_glfuncs, GLuint program, GLint location, GLfloat v0)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform1f(program, location, v0);
+}
+
+void gl4_1core_glProgramUniform1iv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform1iv(program, location, count, value);
+}
+
+void gl4_1core_glProgramUniform1i(void *_glfuncs, GLuint program, GLint location, GLint v0)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform1i(program, location, v0);
+}
+
+void gl4_1core_glGetProgramPipelineiv(void *_glfuncs, GLuint pipeline, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetProgramPipelineiv(pipeline, pname, params);
+}
+
+GLboolean gl4_1core_glIsProgramPipeline(void *_glfuncs, GLuint pipeline)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ return _qglfuncs->glIsProgramPipeline(pipeline);
+}
+
+void gl4_1core_glGenProgramPipelines(void *_glfuncs, GLsizei n, GLuint* pipelines)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGenProgramPipelines(n, pipelines);
+}
+
+void gl4_1core_glDeleteProgramPipelines(void *_glfuncs, GLsizei n, const GLuint* pipelines)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glDeleteProgramPipelines(n, pipelines);
+}
+
+void gl4_1core_glBindProgramPipeline(void *_glfuncs, GLuint pipeline)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glBindProgramPipeline(pipeline);
+}
+
+void gl4_1core_glActiveShaderProgram(void *_glfuncs, GLuint pipeline, GLuint program)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glActiveShaderProgram(pipeline, program);
+}
+
+void gl4_1core_glUseProgramStages(void *_glfuncs, GLuint pipeline, GLbitfield stages, GLuint program)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glUseProgramStages(pipeline, stages, program);
+}
+
+void gl4_1core_glProgramParameteri(void *_glfuncs, GLuint program, GLenum pname, GLint value)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glProgramParameteri(program, pname, value);
+}
+
+void gl4_1core_glProgramBinary(void *_glfuncs, GLuint program, GLenum binaryFormat, const GLvoid* binary, GLsizei length)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glProgramBinary(program, binaryFormat, binary, length);
+}
+
+void gl4_1core_glGetProgramBinary(void *_glfuncs, GLuint program, GLsizei bufSize, GLsizei* length, GLenum* binaryFormat, GLvoid* binary)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetProgramBinary(program, bufSize, length, binaryFormat, binary);
+}
+
+void gl4_1core_glClearDepthf(void *_glfuncs, GLfloat dd)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glClearDepthf(dd);
+}
+
+void gl4_1core_glDepthRangef(void *_glfuncs, GLfloat n, GLfloat f)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glDepthRangef(n, f);
+}
+
+void gl4_1core_glGetShaderPrecisionFormat(void *_glfuncs, GLenum shadertype, GLenum precisionType, GLint* range_, GLint* precision)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glGetShaderPrecisionFormat(shadertype, precisionType, range_, precision);
+}
+
+void gl4_1core_glShaderBinary(void *_glfuncs, GLsizei count, const GLuint* shaders, GLenum binaryFormat, const GLvoid* binary, GLsizei length)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glShaderBinary(count, shaders, binaryFormat, binary, length);
+}
+
+void gl4_1core_glReleaseShaderCompiler(void *_glfuncs)
+{
+ QOpenGLFunctions_4_1_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_1_Core*>(_glfuncs);
+ _qglfuncs->glReleaseShaderCompiler();
+}
+
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.1core/funcs.h b/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.1core/funcs.h
new file mode 100644
index 000000000..e582a112c
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.1core/funcs.h
@@ -0,0 +1,485 @@
+
+// ** file automatically generated by glgen -- do not edit manually **
+
+#ifndef __cplusplus
+#include <inttypes.h>
+#include <stddef.h>
+typedef unsigned int GLenum;
+typedef unsigned char GLboolean;
+typedef unsigned int GLbitfield;
+typedef void GLvoid;
+typedef char GLchar;
+typedef signed char GLbyte; /* 1-byte signed */
+typedef short GLshort; /* 2-byte signed */
+typedef int GLint; /* 4-byte signed */
+typedef unsigned char GLubyte; /* 1-byte unsigned */
+typedef unsigned short GLushort; /* 2-byte unsigned */
+typedef unsigned int GLuint; /* 4-byte unsigned */
+typedef int GLsizei; /* 4-byte signed */
+typedef float GLfloat; /* single precision float */
+typedef float GLclampf; /* single precision float in [0,1] */
+typedef double GLdouble; /* double precision float */
+typedef double GLclampd; /* double precision float in [0,1] */
+typedef int64_t GLint64;
+typedef uint64_t GLuint64;
+typedef ptrdiff_t GLintptr;
+typedef ptrdiff_t GLsizeiptr;
+typedef ptrdiff_t GLintptrARB;
+typedef ptrdiff_t GLsizeiptrARB;
+typedef struct __GLsync *GLsync;
+#endif
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+void *gl4_1core_funcs();
+
+void gl4_1core_glViewport(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl4_1core_glDepthRange(void *_glfuncs, GLdouble nearVal, GLdouble farVal);
+GLboolean gl4_1core_glIsEnabled(void *_glfuncs, GLenum cap);
+void gl4_1core_glGetTexLevelParameteriv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLint* params);
+void gl4_1core_glGetTexLevelParameterfv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLfloat* params);
+void gl4_1core_glGetTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl4_1core_glGetTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl4_1core_glGetTexImage(void *_glfuncs, GLenum target, GLint level, GLenum format, GLenum gltype, GLvoid* pixels);
+void gl4_1core_glGetIntegerv(void *_glfuncs, GLenum pname, GLint* params);
+void gl4_1core_glGetFloatv(void *_glfuncs, GLenum pname, GLfloat* params);
+GLenum gl4_1core_glGetError(void *_glfuncs);
+void gl4_1core_glGetDoublev(void *_glfuncs, GLenum pname, GLdouble* params);
+void gl4_1core_glGetBooleanv(void *_glfuncs, GLenum pname, GLboolean* params);
+void gl4_1core_glReadPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum gltype, GLvoid* pixels);
+void gl4_1core_glReadBuffer(void *_glfuncs, GLenum mode);
+void gl4_1core_glPixelStorei(void *_glfuncs, GLenum pname, GLint param);
+void gl4_1core_glPixelStoref(void *_glfuncs, GLenum pname, GLfloat param);
+void gl4_1core_glDepthFunc(void *_glfuncs, GLenum glfunc);
+void gl4_1core_glStencilOp(void *_glfuncs, GLenum fail, GLenum zfail, GLenum zpass);
+void gl4_1core_glStencilFunc(void *_glfuncs, GLenum glfunc, GLint ref, GLuint mask);
+void gl4_1core_glLogicOp(void *_glfuncs, GLenum opcode);
+void gl4_1core_glBlendFunc(void *_glfuncs, GLenum sfactor, GLenum dfactor);
+void gl4_1core_glFlush(void *_glfuncs);
+void gl4_1core_glFinish(void *_glfuncs);
+void gl4_1core_glEnable(void *_glfuncs, GLenum cap);
+void gl4_1core_glDisable(void *_glfuncs, GLenum cap);
+void gl4_1core_glDepthMask(void *_glfuncs, GLboolean flag);
+void gl4_1core_glColorMask(void *_glfuncs, GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha);
+void gl4_1core_glStencilMask(void *_glfuncs, GLuint mask);
+void gl4_1core_glClearDepth(void *_glfuncs, GLdouble depth);
+void gl4_1core_glClearStencil(void *_glfuncs, GLint s);
+void gl4_1core_glClearColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl4_1core_glClear(void *_glfuncs, GLbitfield mask);
+void gl4_1core_glDrawBuffer(void *_glfuncs, GLenum mode);
+void gl4_1core_glTexImage2D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl4_1core_glTexImage1D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl4_1core_glTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl4_1core_glTexParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint param);
+void gl4_1core_glTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl4_1core_glTexParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param);
+void gl4_1core_glScissor(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl4_1core_glPolygonMode(void *_glfuncs, GLenum face, GLenum mode);
+void gl4_1core_glPointSize(void *_glfuncs, GLfloat size);
+void gl4_1core_glLineWidth(void *_glfuncs, GLfloat width);
+void gl4_1core_glHint(void *_glfuncs, GLenum target, GLenum mode);
+void gl4_1core_glFrontFace(void *_glfuncs, GLenum mode);
+void gl4_1core_glCullFace(void *_glfuncs, GLenum mode);
+void gl4_1core_glIndexubv(void *_glfuncs, const GLubyte* c);
+void gl4_1core_glIndexub(void *_glfuncs, GLubyte c);
+GLboolean gl4_1core_glIsTexture(void *_glfuncs, GLuint texture);
+void gl4_1core_glGenTextures(void *_glfuncs, GLsizei n, GLuint* textures);
+void gl4_1core_glDeleteTextures(void *_glfuncs, GLsizei n, const GLuint* textures);
+void gl4_1core_glBindTexture(void *_glfuncs, GLenum target, GLuint texture);
+void gl4_1core_glTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl4_1core_glTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl4_1core_glCopyTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl4_1core_glCopyTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width);
+void gl4_1core_glCopyTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border);
+void gl4_1core_glCopyTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLint border);
+void gl4_1core_glPolygonOffset(void *_glfuncs, GLfloat factor, GLfloat units);
+void gl4_1core_glDrawElements(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices);
+void gl4_1core_glDrawArrays(void *_glfuncs, GLenum mode, GLint first, GLsizei count);
+void gl4_1core_glCopyTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl4_1core_glTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl4_1core_glTexImage3D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl4_1core_glDrawRangeElements(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices);
+void gl4_1core_glBlendEquation(void *_glfuncs, GLenum mode);
+void gl4_1core_glBlendColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl4_1core_glGetCompressedTexImage(void *_glfuncs, GLenum target, GLint level, GLvoid* img);
+void gl4_1core_glCompressedTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid* data);
+void gl4_1core_glCompressedTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid* data);
+void gl4_1core_glCompressedTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid* data);
+void gl4_1core_glCompressedTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid* data);
+void gl4_1core_glCompressedTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid* data);
+void gl4_1core_glCompressedTexImage3D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid* data);
+void gl4_1core_glSampleCoverage(void *_glfuncs, GLfloat value, GLboolean invert);
+void gl4_1core_glActiveTexture(void *_glfuncs, GLenum texture);
+void gl4_1core_glPointParameteriv(void *_glfuncs, GLenum pname, const GLint* params);
+void gl4_1core_glPointParameteri(void *_glfuncs, GLenum pname, GLint param);
+void gl4_1core_glPointParameterfv(void *_glfuncs, GLenum pname, const GLfloat* params);
+void gl4_1core_glPointParameterf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl4_1core_glMultiDrawArrays(void *_glfuncs, GLenum mode, const GLint* first, const GLsizei* count, GLsizei drawcount);
+void gl4_1core_glBlendFuncSeparate(void *_glfuncs, GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha);
+void gl4_1core_glGetBufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+GLboolean gl4_1core_glUnmapBuffer(void *_glfuncs, GLenum target);
+void gl4_1core_glGetBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, GLvoid* data);
+void gl4_1core_glBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid* data);
+void gl4_1core_glBufferData(void *_glfuncs, GLenum target, GLsizeiptr size, const GLvoid* data, GLenum usage);
+GLboolean gl4_1core_glIsBuffer(void *_glfuncs, GLuint buffer);
+void gl4_1core_glGenBuffers(void *_glfuncs, GLsizei n, GLuint* buffers);
+void gl4_1core_glDeleteBuffers(void *_glfuncs, GLsizei n, const GLuint* buffers);
+void gl4_1core_glBindBuffer(void *_glfuncs, GLenum target, GLuint buffer);
+void gl4_1core_glGetQueryObjectuiv(void *_glfuncs, GLuint id, GLenum pname, GLuint* params);
+void gl4_1core_glGetQueryObjectiv(void *_glfuncs, GLuint id, GLenum pname, GLint* params);
+void gl4_1core_glGetQueryiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl4_1core_glEndQuery(void *_glfuncs, GLenum target);
+void gl4_1core_glBeginQuery(void *_glfuncs, GLenum target, GLuint id);
+GLboolean gl4_1core_glIsQuery(void *_glfuncs, GLuint id);
+void gl4_1core_glDeleteQueries(void *_glfuncs, GLsizei n, const GLuint* ids);
+void gl4_1core_glGenQueries(void *_glfuncs, GLsizei n, GLuint* ids);
+void gl4_1core_glVertexAttribPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLboolean normalized, GLsizei stride, const GLvoid* offset);
+void gl4_1core_glValidateProgram(void *_glfuncs, GLuint program);
+void gl4_1core_glUniformMatrix4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_1core_glUniformMatrix3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_1core_glUniformMatrix2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_1core_glUniform4iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl4_1core_glUniform3iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl4_1core_glUniform2iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl4_1core_glUniform1iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl4_1core_glUniform4fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl4_1core_glUniform3fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl4_1core_glUniform2fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl4_1core_glUniform1fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl4_1core_glUniform4i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2, GLint v3);
+void gl4_1core_glUniform3i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2);
+void gl4_1core_glUniform2i(void *_glfuncs, GLint location, GLint v0, GLint v1);
+void gl4_1core_glUniform1i(void *_glfuncs, GLint location, GLint v0);
+void gl4_1core_glUniform4f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3);
+void gl4_1core_glUniform3f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2);
+void gl4_1core_glUniform2f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1);
+void gl4_1core_glUniform1f(void *_glfuncs, GLint location, GLfloat v0);
+void gl4_1core_glUseProgram(void *_glfuncs, GLuint program);
+void gl4_1core_glShaderSource(void *_glfuncs, GLuint shader, GLsizei count, const GLchar** source, const GLint* length);
+void gl4_1core_glLinkProgram(void *_glfuncs, GLuint program);
+GLboolean gl4_1core_glIsShader(void *_glfuncs, GLuint shader);
+GLboolean gl4_1core_glIsProgram(void *_glfuncs, GLuint program);
+void gl4_1core_glGetVertexAttribiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params);
+void gl4_1core_glGetVertexAttribfv(void *_glfuncs, GLuint index, GLenum pname, GLfloat* params);
+void gl4_1core_glGetVertexAttribdv(void *_glfuncs, GLuint index, GLenum pname, GLdouble* params);
+void gl4_1core_glGetUniformiv(void *_glfuncs, GLuint program, GLint location, GLint* params);
+void gl4_1core_glGetUniformfv(void *_glfuncs, GLuint program, GLint location, GLfloat* params);
+GLint gl4_1core_glGetUniformLocation(void *_glfuncs, GLuint program, const GLchar* name);
+void gl4_1core_glGetShaderSource(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* source);
+void gl4_1core_glGetShaderInfoLog(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* infoLog);
+void gl4_1core_glGetShaderiv(void *_glfuncs, GLuint shader, GLenum pname, GLint* params);
+void gl4_1core_glGetProgramInfoLog(void *_glfuncs, GLuint program, GLsizei bufSize, GLsizei* length, GLchar* infoLog);
+void gl4_1core_glGetProgramiv(void *_glfuncs, GLuint program, GLenum pname, GLint* params);
+GLint gl4_1core_glGetAttribLocation(void *_glfuncs, GLuint program, const GLchar* name);
+void gl4_1core_glGetAttachedShaders(void *_glfuncs, GLuint program, GLsizei maxCount, GLsizei* count, GLuint* obj);
+void gl4_1core_glGetActiveUniform(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name);
+void gl4_1core_glGetActiveAttrib(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name);
+void gl4_1core_glEnableVertexAttribArray(void *_glfuncs, GLuint index);
+void gl4_1core_glDisableVertexAttribArray(void *_glfuncs, GLuint index);
+void gl4_1core_glDetachShader(void *_glfuncs, GLuint program, GLuint shader);
+void gl4_1core_glDeleteShader(void *_glfuncs, GLuint shader);
+void gl4_1core_glDeleteProgram(void *_glfuncs, GLuint program);
+GLuint gl4_1core_glCreateShader(void *_glfuncs, GLenum gltype);
+GLuint gl4_1core_glCreateProgram(void *_glfuncs);
+void gl4_1core_glCompileShader(void *_glfuncs, GLuint shader);
+void gl4_1core_glBindAttribLocation(void *_glfuncs, GLuint program, GLuint index, const GLchar* name);
+void gl4_1core_glAttachShader(void *_glfuncs, GLuint program, GLuint shader);
+void gl4_1core_glStencilMaskSeparate(void *_glfuncs, GLenum face, GLuint mask);
+void gl4_1core_glStencilFuncSeparate(void *_glfuncs, GLenum face, GLenum glfunc, GLint ref, GLuint mask);
+void gl4_1core_glStencilOpSeparate(void *_glfuncs, GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass);
+void gl4_1core_glDrawBuffers(void *_glfuncs, GLsizei n, const GLenum* bufs);
+void gl4_1core_glBlendEquationSeparate(void *_glfuncs, GLenum modeRGB, GLenum modeAlpha);
+void gl4_1core_glUniformMatrix4x3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_1core_glUniformMatrix3x4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_1core_glUniformMatrix4x2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_1core_glUniformMatrix2x4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_1core_glUniformMatrix3x2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_1core_glUniformMatrix2x3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+GLboolean gl4_1core_glIsVertexArray(void *_glfuncs, GLuint array);
+void gl4_1core_glGenVertexArrays(void *_glfuncs, GLsizei n, GLuint* arrays);
+void gl4_1core_glDeleteVertexArrays(void *_glfuncs, GLsizei n, const GLuint* arrays);
+void gl4_1core_glBindVertexArray(void *_glfuncs, GLuint array);
+void gl4_1core_glFlushMappedBufferRange(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr length);
+void gl4_1core_glFramebufferTextureLayer(void *_glfuncs, GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer);
+void gl4_1core_glRenderbufferStorageMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLenum internalFormat, GLsizei width, GLsizei height);
+void gl4_1core_glBlitFramebuffer(void *_glfuncs, GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter);
+void gl4_1core_glGenerateMipmap(void *_glfuncs, GLenum target);
+void gl4_1core_glGetFramebufferAttachmentParameteriv(void *_glfuncs, GLenum target, GLenum attachment, GLenum pname, GLint* params);
+void gl4_1core_glFramebufferRenderbuffer(void *_glfuncs, GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer);
+void gl4_1core_glFramebufferTexture3D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset);
+void gl4_1core_glFramebufferTexture2D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+void gl4_1core_glFramebufferTexture1D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+GLenum gl4_1core_glCheckFramebufferStatus(void *_glfuncs, GLenum target);
+void gl4_1core_glGenFramebuffers(void *_glfuncs, GLsizei n, GLuint* framebuffers);
+void gl4_1core_glDeleteFramebuffers(void *_glfuncs, GLsizei n, const GLuint* framebuffers);
+void gl4_1core_glBindFramebuffer(void *_glfuncs, GLenum target, GLuint framebuffer);
+GLboolean gl4_1core_glIsFramebuffer(void *_glfuncs, GLuint framebuffer);
+void gl4_1core_glGetRenderbufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl4_1core_glRenderbufferStorage(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height);
+void gl4_1core_glGenRenderbuffers(void *_glfuncs, GLsizei n, GLuint* renderbuffers);
+void gl4_1core_glDeleteRenderbuffers(void *_glfuncs, GLsizei n, const GLuint* renderbuffers);
+void gl4_1core_glBindRenderbuffer(void *_glfuncs, GLenum target, GLuint renderbuffer);
+GLboolean gl4_1core_glIsRenderbuffer(void *_glfuncs, GLuint renderbuffer);
+void gl4_1core_glClearBufferfi(void *_glfuncs, GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil);
+void gl4_1core_glClearBufferfv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLfloat* value);
+void gl4_1core_glClearBufferuiv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLuint* value);
+void gl4_1core_glClearBufferiv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLint* value);
+void gl4_1core_glGetTexParameterIuiv(void *_glfuncs, GLenum target, GLenum pname, GLuint* params);
+void gl4_1core_glGetTexParameterIiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl4_1core_glTexParameterIuiv(void *_glfuncs, GLenum target, GLenum pname, const GLuint* params);
+void gl4_1core_glTexParameterIiv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl4_1core_glUniform4uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value);
+void gl4_1core_glUniform3uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value);
+void gl4_1core_glUniform2uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value);
+void gl4_1core_glUniform1uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value);
+void gl4_1core_glUniform4ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3);
+void gl4_1core_glUniform3ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1, GLuint v2);
+void gl4_1core_glUniform2ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1);
+void gl4_1core_glUniform1ui(void *_glfuncs, GLint location, GLuint v0);
+GLint gl4_1core_glGetFragDataLocation(void *_glfuncs, GLuint program, const GLchar* name);
+void gl4_1core_glBindFragDataLocation(void *_glfuncs, GLuint program, GLuint color, const GLchar* name);
+void gl4_1core_glGetUniformuiv(void *_glfuncs, GLuint program, GLint location, GLuint* params);
+void gl4_1core_glGetVertexAttribIuiv(void *_glfuncs, GLuint index, GLenum pname, GLuint* params);
+void gl4_1core_glGetVertexAttribIiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params);
+void gl4_1core_glVertexAttribIPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl4_1core_glEndConditionalRender(void *_glfuncs);
+void gl4_1core_glBeginConditionalRender(void *_glfuncs, GLuint id, GLenum mode);
+void gl4_1core_glClampColor(void *_glfuncs, GLenum target, GLenum clamp);
+void gl4_1core_glGetTransformFeedbackVarying(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLsizei* size, GLenum* gltype, GLchar* name);
+void gl4_1core_glBindBufferBase(void *_glfuncs, GLenum target, GLuint index, GLuint buffer);
+void gl4_1core_glBindBufferRange(void *_glfuncs, GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size);
+void gl4_1core_glEndTransformFeedback(void *_glfuncs);
+void gl4_1core_glBeginTransformFeedback(void *_glfuncs, GLenum primitiveMode);
+GLboolean gl4_1core_glIsEnabledi(void *_glfuncs, GLenum target, GLuint index);
+void gl4_1core_glDisablei(void *_glfuncs, GLenum target, GLuint index);
+void gl4_1core_glEnablei(void *_glfuncs, GLenum target, GLuint index);
+void gl4_1core_glGetIntegeri_v(void *_glfuncs, GLenum target, GLuint index, GLint* data);
+void gl4_1core_glGetBooleani_v(void *_glfuncs, GLenum target, GLuint index, GLboolean* data);
+void gl4_1core_glColorMaski(void *_glfuncs, GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a);
+void gl4_1core_glCopyBufferSubData(void *_glfuncs, GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size);
+void gl4_1core_glUniformBlockBinding(void *_glfuncs, GLuint program, GLuint v0, GLuint v1);
+void gl4_1core_glGetActiveUniformBlockName(void *_glfuncs, GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei* length, GLchar* uniformBlockName);
+void gl4_1core_glGetActiveUniformBlockiv(void *_glfuncs, GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint* params);
+GLuint gl4_1core_glGetUniformBlockIndex(void *_glfuncs, GLuint program, const GLchar* uniformBlockName);
+void gl4_1core_glGetActiveUniformName(void *_glfuncs, GLuint program, GLuint uniformIndex, GLsizei bufSize, GLsizei* length, GLchar* uniformName);
+void gl4_1core_glGetActiveUniformsiv(void *_glfuncs, GLuint program, GLsizei uniformCount, const GLuint* uniformIndices, GLenum pname, GLint* params);
+void gl4_1core_glPrimitiveRestartIndex(void *_glfuncs, GLuint index);
+void gl4_1core_glTexBuffer(void *_glfuncs, GLenum target, GLenum internalFormat, GLuint buffer);
+void gl4_1core_glDrawElementsInstanced(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount);
+void gl4_1core_glDrawArraysInstanced(void *_glfuncs, GLenum mode, GLint first, GLsizei count, GLsizei instancecount);
+void gl4_1core_glSampleMaski(void *_glfuncs, GLuint index, GLbitfield mask);
+void gl4_1core_glGetMultisamplefv(void *_glfuncs, GLenum pname, GLuint index, GLfloat* val);
+void gl4_1core_glTexImage3DMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations);
+void gl4_1core_glTexImage2DMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLint internalFormat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations);
+void gl4_1core_glGetSynciv(void *_glfuncs, GLsync sync, GLenum pname, GLsizei bufSize, GLsizei* length, GLint* values);
+void gl4_1core_glGetInteger64v(void *_glfuncs, GLenum pname, GLint64* params);
+void gl4_1core_glWaitSync(void *_glfuncs, GLsync sync, GLbitfield flags, GLuint64 timeout);
+GLenum gl4_1core_glClientWaitSync(void *_glfuncs, GLsync sync, GLbitfield flags, GLuint64 timeout);
+void gl4_1core_glDeleteSync(void *_glfuncs, GLsync sync);
+GLboolean gl4_1core_glIsSync(void *_glfuncs, GLsync sync);
+GLsync gl4_1core_glFenceSync(void *_glfuncs, GLenum condition, GLbitfield flags);
+void gl4_1core_glProvokingVertex(void *_glfuncs, GLenum mode);
+void gl4_1core_glDrawElementsInstancedBaseVertex(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount, GLint basevertex);
+void gl4_1core_glDrawRangeElementsBaseVertex(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices, GLint basevertex);
+void gl4_1core_glDrawElementsBaseVertex(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLint basevertex);
+void gl4_1core_glFramebufferTexture(void *_glfuncs, GLenum target, GLenum attachment, GLuint texture, GLint level);
+void gl4_1core_glGetBufferParameteri64v(void *_glfuncs, GLenum target, GLenum pname, GLint64* params);
+void gl4_1core_glGetInteger64i_v(void *_glfuncs, GLenum target, GLuint index, GLint64* data);
+void gl4_1core_glVertexAttribP4uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value);
+void gl4_1core_glVertexAttribP4ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value);
+void gl4_1core_glVertexAttribP3uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value);
+void gl4_1core_glVertexAttribP3ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value);
+void gl4_1core_glVertexAttribP2uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value);
+void gl4_1core_glVertexAttribP2ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value);
+void gl4_1core_glVertexAttribP1uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value);
+void gl4_1core_glVertexAttribP1ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value);
+void gl4_1core_glSecondaryColorP3uiv(void *_glfuncs, GLenum gltype, const GLuint* color);
+void gl4_1core_glSecondaryColorP3ui(void *_glfuncs, GLenum gltype, GLuint color);
+void gl4_1core_glColorP4uiv(void *_glfuncs, GLenum gltype, const GLuint* color);
+void gl4_1core_glColorP4ui(void *_glfuncs, GLenum gltype, GLuint color);
+void gl4_1core_glColorP3uiv(void *_glfuncs, GLenum gltype, const GLuint* color);
+void gl4_1core_glColorP3ui(void *_glfuncs, GLenum gltype, GLuint color);
+void gl4_1core_glNormalP3uiv(void *_glfuncs, GLenum gltype, const GLuint* coords);
+void gl4_1core_glNormalP3ui(void *_glfuncs, GLenum gltype, GLuint coords);
+void gl4_1core_glMultiTexCoordP4uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords);
+void gl4_1core_glMultiTexCoordP4ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords);
+void gl4_1core_glMultiTexCoordP3uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords);
+void gl4_1core_glMultiTexCoordP3ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords);
+void gl4_1core_glMultiTexCoordP2uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords);
+void gl4_1core_glMultiTexCoordP2ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords);
+void gl4_1core_glMultiTexCoordP1uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords);
+void gl4_1core_glMultiTexCoordP1ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords);
+void gl4_1core_glTexCoordP4uiv(void *_glfuncs, GLenum gltype, const GLuint* coords);
+void gl4_1core_glTexCoordP4ui(void *_glfuncs, GLenum gltype, GLuint coords);
+void gl4_1core_glTexCoordP3uiv(void *_glfuncs, GLenum gltype, const GLuint* coords);
+void gl4_1core_glTexCoordP3ui(void *_glfuncs, GLenum gltype, GLuint coords);
+void gl4_1core_glTexCoordP2uiv(void *_glfuncs, GLenum gltype, const GLuint* coords);
+void gl4_1core_glTexCoordP2ui(void *_glfuncs, GLenum gltype, GLuint coords);
+void gl4_1core_glTexCoordP1uiv(void *_glfuncs, GLenum gltype, const GLuint* coords);
+void gl4_1core_glTexCoordP1ui(void *_glfuncs, GLenum gltype, GLuint coords);
+void gl4_1core_glVertexP4uiv(void *_glfuncs, GLenum gltype, const GLuint* value);
+void gl4_1core_glVertexP4ui(void *_glfuncs, GLenum gltype, GLuint value);
+void gl4_1core_glVertexP3uiv(void *_glfuncs, GLenum gltype, const GLuint* value);
+void gl4_1core_glVertexP3ui(void *_glfuncs, GLenum gltype, GLuint value);
+void gl4_1core_glVertexP2uiv(void *_glfuncs, GLenum gltype, const GLuint* value);
+void gl4_1core_glVertexP2ui(void *_glfuncs, GLenum gltype, GLuint value);
+void gl4_1core_glGetQueryObjectui64v(void *_glfuncs, GLuint id, GLenum pname, GLuint64* params);
+void gl4_1core_glGetQueryObjecti64v(void *_glfuncs, GLuint id, GLenum pname, GLint64* params);
+void gl4_1core_glQueryCounter(void *_glfuncs, GLuint id, GLenum target);
+void gl4_1core_glGetSamplerParameterIuiv(void *_glfuncs, GLuint sampler, GLenum pname, GLuint* params);
+void gl4_1core_glGetSamplerParameterfv(void *_glfuncs, GLuint sampler, GLenum pname, GLfloat* params);
+void gl4_1core_glGetSamplerParameterIiv(void *_glfuncs, GLuint sampler, GLenum pname, GLint* params);
+void gl4_1core_glGetSamplerParameteriv(void *_glfuncs, GLuint sampler, GLenum pname, GLint* params);
+void gl4_1core_glSamplerParameterIuiv(void *_glfuncs, GLuint sampler, GLenum pname, const GLuint* param);
+void gl4_1core_glSamplerParameterIiv(void *_glfuncs, GLuint sampler, GLenum pname, const GLint* param);
+void gl4_1core_glSamplerParameterfv(void *_glfuncs, GLuint sampler, GLenum pname, const GLfloat* param);
+void gl4_1core_glSamplerParameterf(void *_glfuncs, GLuint sampler, GLenum pname, GLfloat param);
+void gl4_1core_glSamplerParameteriv(void *_glfuncs, GLuint sampler, GLenum pname, const GLint* param);
+void gl4_1core_glSamplerParameteri(void *_glfuncs, GLuint sampler, GLenum pname, GLint param);
+void gl4_1core_glBindSampler(void *_glfuncs, GLuint unit, GLuint sampler);
+GLboolean gl4_1core_glIsSampler(void *_glfuncs, GLuint sampler);
+void gl4_1core_glDeleteSamplers(void *_glfuncs, GLsizei count, const GLuint* samplers);
+void gl4_1core_glGenSamplers(void *_glfuncs, GLsizei count, GLuint* samplers);
+GLint gl4_1core_glGetFragDataIndex(void *_glfuncs, GLuint program, const GLchar* name);
+void gl4_1core_glBindFragDataLocationIndexed(void *_glfuncs, GLuint program, GLuint colorNumber, GLuint index, const GLchar* name);
+void gl4_1core_glVertexAttribDivisor(void *_glfuncs, GLuint index, GLuint divisor);
+void gl4_1core_glGetQueryIndexediv(void *_glfuncs, GLenum target, GLuint index, GLenum pname, GLint* params);
+void gl4_1core_glEndQueryIndexed(void *_glfuncs, GLenum target, GLuint index);
+void gl4_1core_glBeginQueryIndexed(void *_glfuncs, GLenum target, GLuint index, GLuint id);
+void gl4_1core_glDrawTransformFeedbackStream(void *_glfuncs, GLenum mode, GLuint id, GLuint stream);
+void gl4_1core_glDrawTransformFeedback(void *_glfuncs, GLenum mode, GLuint id);
+void gl4_1core_glResumeTransformFeedback(void *_glfuncs);
+void gl4_1core_glPauseTransformFeedback(void *_glfuncs);
+GLboolean gl4_1core_glIsTransformFeedback(void *_glfuncs, GLuint id);
+void gl4_1core_glGenTransformFeedbacks(void *_glfuncs, GLsizei n, GLuint* ids);
+void gl4_1core_glDeleteTransformFeedbacks(void *_glfuncs, GLsizei n, const GLuint* ids);
+void gl4_1core_glBindTransformFeedback(void *_glfuncs, GLenum target, GLuint id);
+void gl4_1core_glPatchParameterfv(void *_glfuncs, GLenum pname, const GLfloat* values);
+void gl4_1core_glPatchParameteri(void *_glfuncs, GLenum pname, GLint value);
+void gl4_1core_glGetProgramStageiv(void *_glfuncs, GLuint program, GLenum shadertype, GLenum pname, GLint* values);
+void gl4_1core_glGetUniformSubroutineuiv(void *_glfuncs, GLenum shadertype, GLint location, GLuint* params);
+void gl4_1core_glUniformSubroutinesuiv(void *_glfuncs, GLenum shadertype, GLsizei count, const GLuint* value);
+void gl4_1core_glGetActiveSubroutineName(void *_glfuncs, GLuint program, GLenum shadertype, GLuint index, GLsizei bufSize, GLsizei* length, GLchar* name);
+void gl4_1core_glGetActiveSubroutineUniformName(void *_glfuncs, GLuint program, GLenum shadertype, GLuint index, GLsizei bufSize, GLsizei* length, GLchar* name);
+void gl4_1core_glGetActiveSubroutineUniformiv(void *_glfuncs, GLuint program, GLenum shadertype, GLuint index, GLenum pname, GLint* values);
+GLuint gl4_1core_glGetSubroutineIndex(void *_glfuncs, GLuint program, GLenum shadertype, const GLchar* name);
+GLint gl4_1core_glGetSubroutineUniformLocation(void *_glfuncs, GLuint program, GLenum shadertype, const GLchar* name);
+void gl4_1core_glGetUniformdv(void *_glfuncs, GLuint program, GLint location, GLdouble* params);
+void gl4_1core_glUniformMatrix4x3dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_1core_glUniformMatrix4x2dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_1core_glUniformMatrix3x4dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_1core_glUniformMatrix3x2dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_1core_glUniformMatrix2x4dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_1core_glUniformMatrix2x3dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_1core_glUniformMatrix4dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_1core_glUniformMatrix3dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_1core_glUniformMatrix2dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_1core_glUniform4dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value);
+void gl4_1core_glUniform3dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value);
+void gl4_1core_glUniform2dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value);
+void gl4_1core_glUniform1dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value);
+void gl4_1core_glUniform4d(void *_glfuncs, GLint location, GLdouble v0, GLdouble v1, GLdouble v2, GLdouble v3);
+void gl4_1core_glUniform3d(void *_glfuncs, GLint location, GLdouble v0, GLdouble v1, GLdouble v2);
+void gl4_1core_glUniform2d(void *_glfuncs, GLint location, GLdouble v0, GLdouble v1);
+void gl4_1core_glUniform1d(void *_glfuncs, GLint location, GLdouble v0);
+void gl4_1core_glDrawElementsIndirect(void *_glfuncs, GLenum mode, GLenum gltype, const GLvoid* indirect);
+void gl4_1core_glDrawArraysIndirect(void *_glfuncs, GLenum mode, const GLvoid* indirect);
+void gl4_1core_glBlendFuncSeparatei(void *_glfuncs, GLuint buf, GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha, GLenum dstAlpha);
+void gl4_1core_glBlendFunci(void *_glfuncs, GLuint buf, GLenum src, GLenum dst);
+void gl4_1core_glBlendEquationSeparatei(void *_glfuncs, GLuint buf, GLenum modeRGB, GLenum modeAlpha);
+void gl4_1core_glBlendEquationi(void *_glfuncs, GLuint buf, GLenum mode);
+void gl4_1core_glMinSampleShading(void *_glfuncs, GLfloat value);
+void gl4_1core_glGetDoublei_v(void *_glfuncs, GLenum target, GLuint index, GLdouble* data);
+void gl4_1core_glGetFloati_v(void *_glfuncs, GLenum target, GLuint index, GLfloat* data);
+void gl4_1core_glDepthRangeIndexed(void *_glfuncs, GLuint index, GLdouble n, GLdouble f);
+void gl4_1core_glDepthRangeArrayv(void *_glfuncs, GLuint first, GLsizei count, const GLdouble* v);
+void gl4_1core_glScissorIndexedv(void *_glfuncs, GLuint index, const GLint* v);
+void gl4_1core_glScissorIndexed(void *_glfuncs, GLuint index, GLint left, GLint bottom, GLsizei width, GLsizei height);
+void gl4_1core_glScissorArrayv(void *_glfuncs, GLuint first, GLsizei count, const GLint* v);
+void gl4_1core_glViewportIndexedfv(void *_glfuncs, GLuint index, const GLfloat* v);
+void gl4_1core_glViewportIndexedf(void *_glfuncs, GLuint index, GLfloat x, GLfloat y, GLfloat w, GLfloat h);
+void gl4_1core_glViewportArrayv(void *_glfuncs, GLuint first, GLsizei count, const GLfloat* v);
+void gl4_1core_glGetVertexAttribLdv(void *_glfuncs, GLuint index, GLenum pname, GLdouble* params);
+void gl4_1core_glVertexAttribLPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl4_1core_glVertexAttribL4dv(void *_glfuncs, GLuint index, const GLdouble* v);
+void gl4_1core_glVertexAttribL3dv(void *_glfuncs, GLuint index, const GLdouble* v);
+void gl4_1core_glVertexAttribL2dv(void *_glfuncs, GLuint index, const GLdouble* v);
+void gl4_1core_glVertexAttribL1dv(void *_glfuncs, GLuint index, const GLdouble* v);
+void gl4_1core_glVertexAttribL4d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+void gl4_1core_glVertexAttribL3d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y, GLdouble z);
+void gl4_1core_glVertexAttribL2d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y);
+void gl4_1core_glVertexAttribL1d(void *_glfuncs, GLuint index, GLdouble x);
+void gl4_1core_glGetProgramPipelineInfoLog(void *_glfuncs, GLuint pipeline, GLsizei bufSize, GLsizei* length, GLchar* infoLog);
+void gl4_1core_glValidateProgramPipeline(void *_glfuncs, GLuint pipeline);
+void gl4_1core_glProgramUniformMatrix4x3dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_1core_glProgramUniformMatrix3x4dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_1core_glProgramUniformMatrix4x2dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_1core_glProgramUniformMatrix2x4dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_1core_glProgramUniformMatrix3x2dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_1core_glProgramUniformMatrix2x3dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_1core_glProgramUniformMatrix4x3fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_1core_glProgramUniformMatrix3x4fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_1core_glProgramUniformMatrix4x2fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_1core_glProgramUniformMatrix2x4fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_1core_glProgramUniformMatrix3x2fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_1core_glProgramUniformMatrix2x3fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_1core_glProgramUniformMatrix4dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_1core_glProgramUniformMatrix3dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_1core_glProgramUniformMatrix2dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_1core_glProgramUniformMatrix4fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_1core_glProgramUniformMatrix3fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_1core_glProgramUniformMatrix2fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_1core_glProgramUniform4uiv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLuint* value);
+void gl4_1core_glProgramUniform4ui(void *_glfuncs, GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3);
+void gl4_1core_glProgramUniform4dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLdouble* value);
+void gl4_1core_glProgramUniform4d(void *_glfuncs, GLuint program, GLint location, GLdouble v0, GLdouble v1, GLdouble v2, GLdouble v3);
+void gl4_1core_glProgramUniform4fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLfloat* value);
+void gl4_1core_glProgramUniform4f(void *_glfuncs, GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3);
+void gl4_1core_glProgramUniform4iv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLint* value);
+void gl4_1core_glProgramUniform4i(void *_glfuncs, GLuint program, GLint location, GLint v0, GLint v1, GLint v2, GLint v3);
+void gl4_1core_glProgramUniform3uiv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLuint* value);
+void gl4_1core_glProgramUniform3ui(void *_glfuncs, GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2);
+void gl4_1core_glProgramUniform3dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLdouble* value);
+void gl4_1core_glProgramUniform3d(void *_glfuncs, GLuint program, GLint location, GLdouble v0, GLdouble v1, GLdouble v2);
+void gl4_1core_glProgramUniform3fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLfloat* value);
+void gl4_1core_glProgramUniform3f(void *_glfuncs, GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2);
+void gl4_1core_glProgramUniform3iv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLint* value);
+void gl4_1core_glProgramUniform3i(void *_glfuncs, GLuint program, GLint location, GLint v0, GLint v1, GLint v2);
+void gl4_1core_glProgramUniform2uiv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLuint* value);
+void gl4_1core_glProgramUniform2ui(void *_glfuncs, GLuint program, GLint location, GLuint v0, GLuint v1);
+void gl4_1core_glProgramUniform2dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLdouble* value);
+void gl4_1core_glProgramUniform2d(void *_glfuncs, GLuint program, GLint location, GLdouble v0, GLdouble v1);
+void gl4_1core_glProgramUniform2fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLfloat* value);
+void gl4_1core_glProgramUniform2f(void *_glfuncs, GLuint program, GLint location, GLfloat v0, GLfloat v1);
+void gl4_1core_glProgramUniform2iv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLint* value);
+void gl4_1core_glProgramUniform2i(void *_glfuncs, GLuint program, GLint location, GLint v0, GLint v1);
+void gl4_1core_glProgramUniform1uiv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLuint* value);
+void gl4_1core_glProgramUniform1ui(void *_glfuncs, GLuint program, GLint location, GLuint v0);
+void gl4_1core_glProgramUniform1dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLdouble* value);
+void gl4_1core_glProgramUniform1d(void *_glfuncs, GLuint program, GLint location, GLdouble v0);
+void gl4_1core_glProgramUniform1fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLfloat* value);
+void gl4_1core_glProgramUniform1f(void *_glfuncs, GLuint program, GLint location, GLfloat v0);
+void gl4_1core_glProgramUniform1iv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLint* value);
+void gl4_1core_glProgramUniform1i(void *_glfuncs, GLuint program, GLint location, GLint v0);
+void gl4_1core_glGetProgramPipelineiv(void *_glfuncs, GLuint pipeline, GLenum pname, GLint* params);
+GLboolean gl4_1core_glIsProgramPipeline(void *_glfuncs, GLuint pipeline);
+void gl4_1core_glGenProgramPipelines(void *_glfuncs, GLsizei n, GLuint* pipelines);
+void gl4_1core_glDeleteProgramPipelines(void *_glfuncs, GLsizei n, const GLuint* pipelines);
+void gl4_1core_glBindProgramPipeline(void *_glfuncs, GLuint pipeline);
+void gl4_1core_glActiveShaderProgram(void *_glfuncs, GLuint pipeline, GLuint program);
+void gl4_1core_glUseProgramStages(void *_glfuncs, GLuint pipeline, GLbitfield stages, GLuint program);
+void gl4_1core_glProgramParameteri(void *_glfuncs, GLuint program, GLenum pname, GLint value);
+void gl4_1core_glProgramBinary(void *_glfuncs, GLuint program, GLenum binaryFormat, const GLvoid* binary, GLsizei length);
+void gl4_1core_glGetProgramBinary(void *_glfuncs, GLuint program, GLsizei bufSize, GLsizei* length, GLenum* binaryFormat, GLvoid* binary);
+void gl4_1core_glClearDepthf(void *_glfuncs, GLfloat dd);
+void gl4_1core_glDepthRangef(void *_glfuncs, GLfloat n, GLfloat f);
+void gl4_1core_glGetShaderPrecisionFormat(void *_glfuncs, GLenum shadertype, GLenum precisionType, GLint* range_, GLint* precision);
+void gl4_1core_glShaderBinary(void *_glfuncs, GLsizei count, const GLuint* shaders, GLenum binaryFormat, const GLvoid* binary, GLsizei length);
+void gl4_1core_glReleaseShaderCompiler(void *_glfuncs);
+
+
+#ifdef __cplusplus
+} // extern "C"
+#endif
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.1core/gl.go b/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.1core/gl.go
new file mode 100644
index 000000000..e5579001a
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.1core/gl.go
@@ -0,0 +1,6409 @@
+// ** file automatically generated by glgen -- do not edit manually **
+
+package GL
+
+// #cgo CXXFLAGS: -std=c++0x -pedantic-errors -Wall -fno-strict-aliasing
+// #cgo LDFLAGS: -lstdc++
+// #cgo pkg-config: Qt5Core Qt5OpenGL
+//
+// #include "funcs.h"
+//
+// void free(void*);
+//
+import "C"
+
+import (
+ "fmt"
+ "reflect"
+ "unsafe"
+
+ "gopkg.in/qml.v1/gl/glbase"
+)
+
+// API returns a value that offers methods matching the OpenGL version 4.1 API.
+//
+// The returned API must not be used after the provided OpenGL context becomes invalid.
+func API(context glbase.Contexter) *GL {
+ gl := &GL{}
+ gl.funcs = C.gl4_1core_funcs()
+ if gl.funcs == nil {
+ panic(fmt.Errorf("OpenGL version 4.1 is not available"))
+ }
+ return gl
+}
+
+// GL implements the OpenGL version 4.1 API. Values of this
+// type must be created via the API function, and it must not be used after
+// the associated OpenGL context becomes invalid.
+type GL struct {
+ funcs unsafe.Pointer
+}
+
+const (
+ FALSE = 0
+ TRUE = 1
+ NONE = 0
+
+ BYTE = 0x1400
+ UNSIGNED_BYTE = 0x1401
+ SHORT = 0x1402
+ UNSIGNED_SHORT = 0x1403
+ INT = 0x1404
+ UNSIGNED_INT = 0x1405
+ FLOAT = 0x1406
+ N2_BYTES = 0x1407
+ N3_BYTES = 0x1408
+ N4_BYTES = 0x1409
+ DOUBLE = 0x140A
+ HALF_FLOAT = 0x140B
+ FIXED = 0x140C
+
+ ACCUM = 0x0100
+ LOAD = 0x0101
+ RETURN = 0x0102
+ MULT = 0x0103
+ ADD = 0x0104
+
+ ACCUM_BUFFER_BIT = 0x00000200
+ ALL_ATTRIB_BITS = 0xFFFFFFFF
+ COLOR_BUFFER_BIT = 0x00004000
+ CURRENT_BIT = 0x00000001
+ DEPTH_BUFFER_BIT = 0x00000100
+ ENABLE_BIT = 0x00002000
+ EVAL_BIT = 0x00010000
+ FOG_BIT = 0x00000080
+ HINT_BIT = 0x00008000
+ LIGHTING_BIT = 0x00000040
+ LINE_BIT = 0x00000004
+ LIST_BIT = 0x00020000
+ MULTISAMPLE_BIT = 0x20000000
+ PIXEL_MODE_BIT = 0x00000020
+ POINT_BIT = 0x00000002
+ POLYGON_BIT = 0x00000008
+ POLYGON_STIPPLE_BIT = 0x00000010
+ SCISSOR_BIT = 0x00080000
+ STENCIL_BUFFER_BIT = 0x00000400
+ TEXTURE_BIT = 0x00040000
+ TRANSFORM_BIT = 0x00001000
+ VIEWPORT_BIT = 0x00000800
+
+ ALWAYS = 0x0207
+ EQUAL = 0x0202
+ GEQUAL = 0x0206
+ GREATER = 0x0204
+ LEQUAL = 0x0203
+ LESS = 0x0201
+ NEVER = 0x0200
+ NOTEQUAL = 0x0205
+
+ LOGIC_OP = 0x0BF1
+
+ DST_ALPHA = 0x0304
+ ONE = 1
+ ONE_MINUS_DST_ALPHA = 0x0305
+ ONE_MINUS_SRC_ALPHA = 0x0303
+ ONE_MINUS_SRC_COLOR = 0x0301
+ SRC_ALPHA = 0x0302
+ SRC_COLOR = 0x0300
+ ZERO = 0
+
+ DST_COLOR = 0x0306
+ ONE_MINUS_DST_COLOR = 0x0307
+ SRC_ALPHA_SATURATE = 0x0308
+
+ CLIENT_ALL_ATTRIB_BITS = 0xFFFFFFFF
+ CLIENT_PIXEL_STORE_BIT = 0x00000001
+ CLIENT_VERTEX_ARRAY_BIT = 0x00000002
+
+ CLIP_DISTANCE0 = 0x3000
+ CLIP_DISTANCE1 = 0x3001
+ CLIP_DISTANCE2 = 0x3002
+ CLIP_DISTANCE3 = 0x3003
+ CLIP_DISTANCE4 = 0x3004
+ CLIP_DISTANCE5 = 0x3005
+ CLIP_DISTANCE6 = 0x3006
+ CLIP_DISTANCE7 = 0x3007
+ CLIP_PLANE0 = 0x3000
+ CLIP_PLANE1 = 0x3001
+ CLIP_PLANE2 = 0x3002
+ CLIP_PLANE3 = 0x3003
+ CLIP_PLANE4 = 0x3004
+ CLIP_PLANE5 = 0x3005
+
+ BACK = 0x0405
+ FRONT = 0x0404
+ FRONT_AND_BACK = 0x0408
+
+ AMBIENT = 0x1200
+ AMBIENT_AND_DIFFUSE = 0x1602
+ DIFFUSE = 0x1201
+ EMISSION = 0x1600
+ SPECULAR = 0x1202
+
+ CONTEXT_FLAG_FORWARD_COMPATIBLE_BIT = 0x00000001
+
+ CONTEXT_COMPATIBILITY_PROFILE_BIT = 0x00000002
+ CONTEXT_CORE_PROFILE_BIT = 0x00000001
+
+ AUX0 = 0x0409
+ AUX1 = 0x040A
+ AUX2 = 0x040B
+ AUX3 = 0x040C
+ BACK_LEFT = 0x0402
+ BACK_RIGHT = 0x0403
+ FRONT_LEFT = 0x0400
+ FRONT_RIGHT = 0x0401
+ LEFT = 0x0406
+ RIGHT = 0x0407
+
+ ALPHA_TEST = 0x0BC0
+ AUTO_NORMAL = 0x0D80
+ BLEND = 0x0BE2
+ COLOR_ARRAY = 0x8076
+ COLOR_LOGIC_OP = 0x0BF2
+ COLOR_MATERIAL = 0x0B57
+ CULL_FACE = 0x0B44
+ DEPTH_TEST = 0x0B71
+ DITHER = 0x0BD0
+ EDGE_FLAG_ARRAY = 0x8079
+ FOG = 0x0B60
+ INDEX_ARRAY = 0x8077
+ INDEX_LOGIC_OP = 0x0BF1
+ LIGHT0 = 0x4000
+ LIGHT1 = 0x4001
+ LIGHT2 = 0x4002
+ LIGHT3 = 0x4003
+ LIGHT4 = 0x4004
+ LIGHT5 = 0x4005
+ LIGHT6 = 0x4006
+ LIGHT7 = 0x4007
+ LIGHTING = 0x0B50
+ LINE_SMOOTH = 0x0B20
+ LINE_STIPPLE = 0x0B24
+ MAP1_COLOR_4 = 0x0D90
+ MAP1_INDEX = 0x0D91
+ MAP1_NORMAL = 0x0D92
+ MAP1_TEXTURE_COORD_1 = 0x0D93
+ MAP1_TEXTURE_COORD_2 = 0x0D94
+ MAP1_TEXTURE_COORD_3 = 0x0D95
+ MAP1_TEXTURE_COORD_4 = 0x0D96
+ MAP1_VERTEX_3 = 0x0D97
+ MAP1_VERTEX_4 = 0x0D98
+ MAP2_COLOR_4 = 0x0DB0
+ MAP2_INDEX = 0x0DB1
+ MAP2_NORMAL = 0x0DB2
+ MAP2_TEXTURE_COORD_1 = 0x0DB3
+ MAP2_TEXTURE_COORD_2 = 0x0DB4
+ MAP2_TEXTURE_COORD_3 = 0x0DB5
+ MAP2_TEXTURE_COORD_4 = 0x0DB6
+ MAP2_VERTEX_3 = 0x0DB7
+ MAP2_VERTEX_4 = 0x0DB8
+ NORMALIZE = 0x0BA1
+ NORMAL_ARRAY = 0x8075
+ POINT_SMOOTH = 0x0B10
+ POLYGON_OFFSET_FILL = 0x8037
+ POLYGON_OFFSET_LINE = 0x2A02
+ POLYGON_OFFSET_POINT = 0x2A01
+ POLYGON_SMOOTH = 0x0B41
+ POLYGON_STIPPLE = 0x0B42
+ SCISSOR_TEST = 0x0C11
+ STENCIL_TEST = 0x0B90
+ TEXTURE_1D = 0x0DE0
+ TEXTURE_2D = 0x0DE1
+ TEXTURE_COORD_ARRAY = 0x8078
+ TEXTURE_GEN_Q = 0x0C63
+ TEXTURE_GEN_R = 0x0C62
+ TEXTURE_GEN_S = 0x0C60
+ TEXTURE_GEN_T = 0x0C61
+ VERTEX_ARRAY = 0x8074
+
+ INVALID_ENUM = 0x0500
+ INVALID_FRAMEBUFFER_OPERATION = 0x0506
+ INVALID_OPERATION = 0x0502
+ INVALID_VALUE = 0x0501
+ NO_ERROR = 0
+ OUT_OF_MEMORY = 0x0505
+ STACK_OVERFLOW = 0x0503
+ STACK_UNDERFLOW = 0x0504
+
+ N2D = 0x0600
+ N3D = 0x0601
+ N3D_COLOR = 0x0602
+ N3D_COLOR_TEXTURE = 0x0603
+ N4D_COLOR_TEXTURE = 0x0604
+
+ BITMAP_TOKEN = 0x0704
+ COPY_PIXEL_TOKEN = 0x0706
+ DRAW_PIXEL_TOKEN = 0x0705
+ LINE_RESET_TOKEN = 0x0707
+ LINE_TOKEN = 0x0702
+ PASS_THROUGH_TOKEN = 0x0700
+ POINT_TOKEN = 0x0701
+ POLYGON_TOKEN = 0x0703
+
+ EXP = 0x0800
+ EXP2 = 0x0801
+ LINEAR = 0x2601
+
+ FOG_COLOR = 0x0B66
+ FOG_DENSITY = 0x0B62
+ FOG_END = 0x0B64
+ FOG_INDEX = 0x0B61
+ FOG_MODE = 0x0B65
+ FOG_START = 0x0B63
+
+ CCW = 0x0901
+ CW = 0x0900
+
+ COEFF = 0x0A00
+ DOMAIN = 0x0A02
+ ORDER = 0x0A01
+
+ PIXEL_MAP_A_TO_A = 0x0C79
+ PIXEL_MAP_B_TO_B = 0x0C78
+ PIXEL_MAP_G_TO_G = 0x0C77
+ PIXEL_MAP_I_TO_A = 0x0C75
+ PIXEL_MAP_I_TO_B = 0x0C74
+ PIXEL_MAP_I_TO_G = 0x0C73
+ PIXEL_MAP_I_TO_I = 0x0C70
+ PIXEL_MAP_I_TO_R = 0x0C72
+ PIXEL_MAP_R_TO_R = 0x0C76
+ PIXEL_MAP_S_TO_S = 0x0C71
+
+ ACCUM_ALPHA_BITS = 0x0D5B
+ ACCUM_BLUE_BITS = 0x0D5A
+ ACCUM_CLEAR_VALUE = 0x0B80
+ ACCUM_GREEN_BITS = 0x0D59
+ ACCUM_RED_BITS = 0x0D58
+ ALIASED_LINE_WIDTH_RANGE = 0x846E
+ ALIASED_POINT_SIZE_RANGE = 0x846D
+ ALPHA_BIAS = 0x0D1D
+ ALPHA_BITS = 0x0D55
+ ALPHA_SCALE = 0x0D1C
+ ALPHA_TEST_FUNC = 0x0BC1
+ ALPHA_TEST_REF = 0x0BC2
+ ATTRIB_STACK_DEPTH = 0x0BB0
+ AUX_BUFFERS = 0x0C00
+ BLEND_DST = 0x0BE0
+ BLEND_SRC = 0x0BE1
+ BLUE_BIAS = 0x0D1B
+ BLUE_BITS = 0x0D54
+ BLUE_SCALE = 0x0D1A
+ CLIENT_ATTRIB_STACK_DEPTH = 0x0BB1
+ COLOR_ARRAY_SIZE = 0x8081
+ COLOR_ARRAY_STRIDE = 0x8083
+ COLOR_ARRAY_TYPE = 0x8082
+ COLOR_CLEAR_VALUE = 0x0C22
+ COLOR_MATERIAL_FACE = 0x0B55
+ COLOR_MATERIAL_PARAMETER = 0x0B56
+ COLOR_WRITEMASK = 0x0C23
+ CULL_FACE_MODE = 0x0B45
+ CURRENT_COLOR = 0x0B00
+ CURRENT_INDEX = 0x0B01
+ CURRENT_NORMAL = 0x0B02
+ CURRENT_RASTER_COLOR = 0x0B04
+ CURRENT_RASTER_DISTANCE = 0x0B09
+ CURRENT_RASTER_INDEX = 0x0B05
+ CURRENT_RASTER_POSITION = 0x0B07
+ CURRENT_RASTER_POSITION_VALID = 0x0B08
+ CURRENT_RASTER_TEXTURE_COORDS = 0x0B06
+ CURRENT_TEXTURE_COORDS = 0x0B03
+ DEPTH_BIAS = 0x0D1F
+ DEPTH_BITS = 0x0D56
+ DEPTH_CLEAR_VALUE = 0x0B73
+ DEPTH_FUNC = 0x0B74
+ DEPTH_RANGE = 0x0B70
+ DEPTH_SCALE = 0x0D1E
+ DEPTH_WRITEMASK = 0x0B72
+ DOUBLEBUFFER = 0x0C32
+ DRAW_BUFFER = 0x0C01
+ EDGE_FLAG = 0x0B43
+ EDGE_FLAG_ARRAY_STRIDE = 0x808C
+ FEEDBACK_BUFFER_SIZE = 0x0DF1
+ FEEDBACK_BUFFER_TYPE = 0x0DF2
+ FOG_HINT = 0x0C54
+ FRONT_FACE = 0x0B46
+ GREEN_BIAS = 0x0D19
+ GREEN_BITS = 0x0D53
+ GREEN_SCALE = 0x0D18
+ INDEX_ARRAY_STRIDE = 0x8086
+ INDEX_ARRAY_TYPE = 0x8085
+ INDEX_BITS = 0x0D51
+ INDEX_CLEAR_VALUE = 0x0C20
+ INDEX_MODE = 0x0C30
+ INDEX_OFFSET = 0x0D13
+ INDEX_SHIFT = 0x0D12
+ INDEX_WRITEMASK = 0x0C21
+ LIGHT_MODEL_AMBIENT = 0x0B53
+ LIGHT_MODEL_COLOR_CONTROL = 0x81F8
+ LIGHT_MODEL_LOCAL_VIEWER = 0x0B51
+ LIGHT_MODEL_TWO_SIDE = 0x0B52
+ LINE_SMOOTH_HINT = 0x0C52
+ LINE_STIPPLE_PATTERN = 0x0B25
+ LINE_STIPPLE_REPEAT = 0x0B26
+ LINE_WIDTH = 0x0B21
+ LINE_WIDTH_GRANULARITY = 0x0B23
+ LINE_WIDTH_RANGE = 0x0B22
+ LIST_BASE = 0x0B32
+ LIST_INDEX = 0x0B33
+ LIST_MODE = 0x0B30
+ LOGIC_OP_MODE = 0x0BF0
+ MAP1_GRID_DOMAIN = 0x0DD0
+ MAP1_GRID_SEGMENTS = 0x0DD1
+ MAP2_GRID_DOMAIN = 0x0DD2
+ MAP2_GRID_SEGMENTS = 0x0DD3
+ MAP_COLOR = 0x0D10
+ MAP_STENCIL = 0x0D11
+ MATRIX_MODE = 0x0BA0
+ MAX_ATTRIB_STACK_DEPTH = 0x0D35
+ MAX_CLIENT_ATTRIB_STACK_DEPTH = 0x0D3B
+ MAX_CLIP_DISTANCES = 0x0D32
+ MAX_CLIP_PLANES = 0x0D32
+ MAX_EVAL_ORDER = 0x0D30
+ MAX_LIGHTS = 0x0D31
+ MAX_LIST_NESTING = 0x0B31
+ MAX_MODELVIEW_STACK_DEPTH = 0x0D36
+ MAX_NAME_STACK_DEPTH = 0x0D37
+ MAX_PIXEL_MAP_TABLE = 0x0D34
+ MAX_PROJECTION_STACK_DEPTH = 0x0D38
+ MAX_TEXTURE_SIZE = 0x0D33
+ MAX_TEXTURE_STACK_DEPTH = 0x0D39
+ MAX_VIEWPORT_DIMS = 0x0D3A
+ MODELVIEW_MATRIX = 0x0BA6
+ MODELVIEW_STACK_DEPTH = 0x0BA3
+ NAME_STACK_DEPTH = 0x0D70
+ NORMAL_ARRAY_STRIDE = 0x807F
+ NORMAL_ARRAY_TYPE = 0x807E
+ PACK_ALIGNMENT = 0x0D05
+ PACK_LSB_FIRST = 0x0D01
+ PACK_ROW_LENGTH = 0x0D02
+ PACK_SKIP_PIXELS = 0x0D04
+ PACK_SKIP_ROWS = 0x0D03
+ PACK_SWAP_BYTES = 0x0D00
+ PERSPECTIVE_CORRECTION_HINT = 0x0C50
+ PIXEL_MAP_A_TO_A_SIZE = 0x0CB9
+ PIXEL_MAP_B_TO_B_SIZE = 0x0CB8
+ PIXEL_MAP_G_TO_G_SIZE = 0x0CB7
+ PIXEL_MAP_I_TO_A_SIZE = 0x0CB5
+ PIXEL_MAP_I_TO_B_SIZE = 0x0CB4
+ PIXEL_MAP_I_TO_G_SIZE = 0x0CB3
+ PIXEL_MAP_I_TO_I_SIZE = 0x0CB0
+ PIXEL_MAP_I_TO_R_SIZE = 0x0CB2
+ PIXEL_MAP_R_TO_R_SIZE = 0x0CB6
+ PIXEL_MAP_S_TO_S_SIZE = 0x0CB1
+ POINT_SIZE = 0x0B11
+ POINT_SIZE_GRANULARITY = 0x0B13
+ POINT_SIZE_RANGE = 0x0B12
+ POINT_SMOOTH_HINT = 0x0C51
+ POLYGON_MODE = 0x0B40
+ POLYGON_OFFSET_FACTOR = 0x8038
+ POLYGON_OFFSET_UNITS = 0x2A00
+ POLYGON_SMOOTH_HINT = 0x0C53
+ PROJECTION_MATRIX = 0x0BA7
+ PROJECTION_STACK_DEPTH = 0x0BA4
+ READ_BUFFER = 0x0C02
+ RED_BIAS = 0x0D15
+ RED_BITS = 0x0D52
+ RED_SCALE = 0x0D14
+ RENDER_MODE = 0x0C40
+ RGBA_MODE = 0x0C31
+ SCISSOR_BOX = 0x0C10
+ SELECTION_BUFFER_SIZE = 0x0DF4
+ SHADE_MODEL = 0x0B54
+ SMOOTH_LINE_WIDTH_GRANULARITY = 0x0B23
+ SMOOTH_LINE_WIDTH_RANGE = 0x0B22
+ SMOOTH_POINT_SIZE_GRANULARITY = 0x0B13
+ SMOOTH_POINT_SIZE_RANGE = 0x0B12
+ STENCIL_BITS = 0x0D57
+ STENCIL_CLEAR_VALUE = 0x0B91
+ STENCIL_FAIL = 0x0B94
+ STENCIL_FUNC = 0x0B92
+ STENCIL_PASS_DEPTH_FAIL = 0x0B95
+ STENCIL_PASS_DEPTH_PASS = 0x0B96
+ STENCIL_REF = 0x0B97
+ STENCIL_VALUE_MASK = 0x0B93
+ STENCIL_WRITEMASK = 0x0B98
+ STEREO = 0x0C33
+ SUBPIXEL_BITS = 0x0D50
+ TEXTURE_BINDING_1D = 0x8068
+ TEXTURE_BINDING_2D = 0x8069
+ TEXTURE_BINDING_3D = 0x806A
+ TEXTURE_COORD_ARRAY_SIZE = 0x8088
+ TEXTURE_COORD_ARRAY_STRIDE = 0x808A
+ TEXTURE_COORD_ARRAY_TYPE = 0x8089
+ TEXTURE_MATRIX = 0x0BA8
+ TEXTURE_STACK_DEPTH = 0x0BA5
+ UNPACK_ALIGNMENT = 0x0CF5
+ UNPACK_LSB_FIRST = 0x0CF1
+ UNPACK_ROW_LENGTH = 0x0CF2
+ UNPACK_SKIP_PIXELS = 0x0CF4
+ UNPACK_SKIP_ROWS = 0x0CF3
+ UNPACK_SWAP_BYTES = 0x0CF0
+ VERTEX_ARRAY_SIZE = 0x807A
+ VERTEX_ARRAY_STRIDE = 0x807C
+ VERTEX_ARRAY_TYPE = 0x807B
+ VIEWPORT = 0x0BA2
+ ZOOM_X = 0x0D16
+ ZOOM_Y = 0x0D17
+
+ COLOR_ARRAY_POINTER = 0x8090
+ EDGE_FLAG_ARRAY_POINTER = 0x8093
+ FEEDBACK_BUFFER_POINTER = 0x0DF0
+ INDEX_ARRAY_POINTER = 0x8091
+ NORMAL_ARRAY_POINTER = 0x808F
+ SELECTION_BUFFER_POINTER = 0x0DF3
+ TEXTURE_COORD_ARRAY_POINTER = 0x8092
+ VERTEX_ARRAY_POINTER = 0x808E
+
+ TEXTURE_ALPHA_SIZE = 0x805F
+ TEXTURE_BLUE_SIZE = 0x805E
+ TEXTURE_BORDER = 0x1005
+ TEXTURE_BORDER_COLOR = 0x1004
+ TEXTURE_COMPONENTS = 0x1003
+ TEXTURE_GREEN_SIZE = 0x805D
+ TEXTURE_HEIGHT = 0x1001
+ TEXTURE_INTENSITY_SIZE = 0x8061
+ TEXTURE_INTERNAL_FORMAT = 0x1003
+ TEXTURE_LUMINANCE_SIZE = 0x8060
+ TEXTURE_MAG_FILTER = 0x2800
+ TEXTURE_MIN_FILTER = 0x2801
+ TEXTURE_PRIORITY = 0x8066
+ TEXTURE_RED_SIZE = 0x805C
+ TEXTURE_RESIDENT = 0x8067
+ TEXTURE_WIDTH = 0x1000
+ TEXTURE_WRAP_S = 0x2802
+ TEXTURE_WRAP_T = 0x2803
+
+ DONT_CARE = 0x1100
+ FASTEST = 0x1101
+ NICEST = 0x1102
+
+ FRAGMENT_SHADER_DERIVATIVE_HINT = 0x8B8B
+ GENERATE_MIPMAP_HINT = 0x8192
+ PROGRAM_BINARY_RETRIEVABLE_HINT = 0x8257
+ TEXTURE_COMPRESSION_HINT = 0x84EF
+
+ C3F_V3F = 0x2A24
+ C4F_N3F_V3F = 0x2A26
+ C4UB_V2F = 0x2A22
+ C4UB_V3F = 0x2A23
+ N3F_V3F = 0x2A25
+ T2F_C3F_V3F = 0x2A2A
+ T2F_C4F_N3F_V3F = 0x2A2C
+ T2F_C4UB_V3F = 0x2A29
+ T2F_N3F_V3F = 0x2A2B
+ T2F_V3F = 0x2A27
+ T4F_C4F_N3F_V4F = 0x2A2D
+ T4F_V4F = 0x2A28
+ V2F = 0x2A20
+ V3F = 0x2A21
+
+ MODULATE = 0x2100
+ REPLACE = 0x1E01
+
+ SEPARATE_SPECULAR_COLOR = 0x81FA
+ SINGLE_COLOR = 0x81F9
+
+ CONSTANT_ATTENUATION = 0x1207
+ LINEAR_ATTENUATION = 0x1208
+ POSITION = 0x1203
+ QUADRATIC_ATTENUATION = 0x1209
+ SPOT_CUTOFF = 0x1206
+ SPOT_DIRECTION = 0x1204
+ SPOT_EXPONENT = 0x1205
+
+ COMPILE = 0x1300
+ COMPILE_AND_EXECUTE = 0x1301
+
+ AND = 0x1501
+ AND_INVERTED = 0x1504
+ AND_REVERSE = 0x1502
+ CLEAR = 0x1500
+ COPY = 0x1503
+ COPY_INVERTED = 0x150C
+ EQUIV = 0x1509
+ INVERT = 0x150A
+ NAND = 0x150E
+ NOOP = 0x1505
+ NOR = 0x1508
+ OR = 0x1507
+ OR_INVERTED = 0x150D
+ OR_REVERSE = 0x150B
+ SET = 0x150F
+ XOR = 0x1506
+
+ MAP_FLUSH_EXPLICIT_BIT = 0x0010
+ MAP_INVALIDATE_BUFFER_BIT = 0x0008
+ MAP_INVALIDATE_RANGE_BIT = 0x0004
+ MAP_READ_BIT = 0x0001
+ MAP_UNSYNCHRONIZED_BIT = 0x0020
+ MAP_WRITE_BIT = 0x0002
+
+ COLOR_INDEXES = 0x1603
+ SHININESS = 0x1601
+
+ MODELVIEW = 0x1700
+ PROJECTION = 0x1701
+ TEXTURE = 0x1702
+
+ LINE = 0x1B01
+ POINT = 0x1B00
+
+ FILL = 0x1B02
+
+ COLOR = 0x1800
+ DEPTH = 0x1801
+ STENCIL = 0x1802
+
+ ALPHA = 0x1906
+ BLUE = 0x1905
+ COLOR_INDEX = 0x1900
+ DEPTH_COMPONENT = 0x1902
+ GREEN = 0x1904
+ LUMINANCE = 0x1909
+ LUMINANCE_ALPHA = 0x190A
+ RED = 0x1903
+ RGB = 0x1907
+ RGBA = 0x1908
+ STENCIL_INDEX = 0x1901
+
+ ALPHA12 = 0x803D
+ ALPHA16 = 0x803E
+ ALPHA4 = 0x803B
+ ALPHA8 = 0x803C
+ INTENSITY = 0x8049
+ INTENSITY12 = 0x804C
+ INTENSITY16 = 0x804D
+ INTENSITY4 = 0x804A
+ INTENSITY8 = 0x804B
+ LUMINANCE12 = 0x8041
+ LUMINANCE12_ALPHA12 = 0x8047
+ LUMINANCE12_ALPHA4 = 0x8046
+ LUMINANCE16 = 0x8042
+ LUMINANCE16_ALPHA16 = 0x8048
+ LUMINANCE4 = 0x803F
+ LUMINANCE4_ALPHA4 = 0x8043
+ LUMINANCE6_ALPHA2 = 0x8044
+ LUMINANCE8 = 0x8040
+ LUMINANCE8_ALPHA8 = 0x8045
+ R3_G3_B2 = 0x2A10
+ RGB10 = 0x8052
+ RGB10_A2 = 0x8059
+ RGB12 = 0x8053
+ RGB16 = 0x8054
+ RGB4 = 0x804F
+ RGB5 = 0x8050
+ RGB5_A1 = 0x8057
+ RGB8 = 0x8051
+ RGBA12 = 0x805A
+ RGBA16 = 0x805B
+ RGBA2 = 0x8055
+ RGBA4 = 0x8056
+ RGBA8 = 0x8058
+
+ PACK_IMAGE_HEIGHT = 0x806C
+ PACK_SKIP_IMAGES = 0x806B
+ UNPACK_IMAGE_HEIGHT = 0x806E
+ UNPACK_SKIP_IMAGES = 0x806D
+
+ BITMAP = 0x1A00
+ UNSIGNED_BYTE_3_3_2 = 0x8032
+ UNSIGNED_INT_10_10_10_2 = 0x8036
+ UNSIGNED_INT_8_8_8_8 = 0x8035
+ UNSIGNED_SHORT_4_4_4_4 = 0x8033
+ UNSIGNED_SHORT_5_5_5_1 = 0x8034
+
+ POINT_DISTANCE_ATTENUATION = 0x8129
+ POINT_FADE_THRESHOLD_SIZE = 0x8128
+ POINT_SIZE_MAX = 0x8127
+ POINT_SIZE_MIN = 0x8126
+
+ LINES = 0x0001
+ LINES_ADJACENCY = 0x000A
+ LINE_LOOP = 0x0002
+ LINE_STRIP = 0x0003
+ LINE_STRIP_ADJACENCY = 0x000B
+ PATCHES = 0x000E
+ POINTS = 0x0000
+ POLYGON = 0x0009
+ QUADS = 0x0007
+ QUAD_STRIP = 0x0008
+ TRIANGLES = 0x0004
+ TRIANGLES_ADJACENCY = 0x000C
+ TRIANGLE_FAN = 0x0006
+ TRIANGLE_STRIP = 0x0005
+ TRIANGLE_STRIP_ADJACENCY = 0x000D
+
+ FEEDBACK = 0x1C01
+ RENDER = 0x1C00
+ SELECT = 0x1C02
+
+ FLAT = 0x1D00
+ SMOOTH = 0x1D01
+
+ DECR = 0x1E03
+ INCR = 0x1E02
+ KEEP = 0x1E00
+
+ EXTENSIONS = 0x1F03
+ RENDERER = 0x1F01
+ VENDOR = 0x1F00
+ VERSION = 0x1F02
+
+ S = 0x2000
+ T = 0x2001
+ R = 0x2002
+ Q = 0x2003
+
+ DECAL = 0x2101
+
+ TEXTURE_ENV_COLOR = 0x2201
+ TEXTURE_ENV_MODE = 0x2200
+
+ TEXTURE_ENV = 0x2300
+
+ EYE_LINEAR = 0x2400
+ OBJECT_LINEAR = 0x2401
+ SPHERE_MAP = 0x2402
+
+ EYE_PLANE = 0x2502
+ OBJECT_PLANE = 0x2501
+ TEXTURE_GEN_MODE = 0x2500
+
+ NEAREST = 0x2600
+
+ LINEAR_MIPMAP_LINEAR = 0x2703
+ LINEAR_MIPMAP_NEAREST = 0x2701
+ NEAREST_MIPMAP_LINEAR = 0x2702
+ NEAREST_MIPMAP_NEAREST = 0x2700
+
+ GENERATE_MIPMAP = 0x8191
+ TEXTURE_WRAP_R = 0x8072
+
+ PROXY_TEXTURE_1D = 0x8063
+ PROXY_TEXTURE_2D = 0x8064
+ PROXY_TEXTURE_3D = 0x8070
+ TEXTURE_3D = 0x806F
+ TEXTURE_BASE_LEVEL = 0x813C
+ TEXTURE_MAX_LEVEL = 0x813D
+ TEXTURE_MAX_LOD = 0x813B
+ TEXTURE_MIN_LOD = 0x813A
+
+ CLAMP = 0x2900
+ CLAMP_TO_BORDER = 0x812D
+ CLAMP_TO_EDGE = 0x812F
+ REPEAT = 0x2901
+
+ VERTEX_SHADER_BIT = 0x00000001
+ FRAGMENT_SHADER_BIT = 0x00000002
+ GEOMETRY_SHADER_BIT = 0x00000004
+ TESS_CONTROL_SHADER_BIT = 0x00000008
+ TESS_EVALUATION_SHADER_BIT = 0x00000010
+ ALL_SHADER_BITS = 0xFFFFFFFF
+
+ SYNC_FLUSH_COMMANDS_BIT = 0x00000001
+ INVALID_INDEX = 0xFFFFFFFF
+ TIMEOUT_IGNORED = 0xFFFFFFFFFFFFFFFF
+ CONSTANT_COLOR = 0x8001
+ ONE_MINUS_CONSTANT_COLOR = 0x8002
+ CONSTANT_ALPHA = 0x8003
+ ONE_MINUS_CONSTANT_ALPHA = 0x8004
+ FUNC_ADD = 0x8006
+ MIN = 0x8007
+ MAX = 0x8008
+ BLEND_EQUATION_RGB = 0x8009
+ FUNC_SUBTRACT = 0x800A
+ FUNC_REVERSE_SUBTRACT = 0x800B
+ RESCALE_NORMAL = 0x803A
+ TEXTURE_DEPTH = 0x8071
+ MAX_3D_TEXTURE_SIZE = 0x8073
+ MULTISAMPLE = 0x809D
+ SAMPLE_ALPHA_TO_COVERAGE = 0x809E
+ SAMPLE_ALPHA_TO_ONE = 0x809F
+ SAMPLE_COVERAGE = 0x80A0
+ SAMPLE_BUFFERS = 0x80A8
+ SAMPLES = 0x80A9
+ SAMPLE_COVERAGE_VALUE = 0x80AA
+ SAMPLE_COVERAGE_INVERT = 0x80AB
+ BLEND_DST_RGB = 0x80C8
+ BLEND_SRC_RGB = 0x80C9
+ BLEND_DST_ALPHA = 0x80CA
+ BLEND_SRC_ALPHA = 0x80CB
+ BGR = 0x80E0
+ BGRA = 0x80E1
+ MAX_ELEMENTS_VERTICES = 0x80E8
+ MAX_ELEMENTS_INDICES = 0x80E9
+ DEPTH_COMPONENT16 = 0x81A5
+ DEPTH_COMPONENT24 = 0x81A6
+ DEPTH_COMPONENT32 = 0x81A7
+ FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING = 0x8210
+ FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE = 0x8211
+ FRAMEBUFFER_ATTACHMENT_RED_SIZE = 0x8212
+ FRAMEBUFFER_ATTACHMENT_GREEN_SIZE = 0x8213
+ FRAMEBUFFER_ATTACHMENT_BLUE_SIZE = 0x8214
+ FRAMEBUFFER_ATTACHMENT_ALPHA_SIZE = 0x8215
+ FRAMEBUFFER_ATTACHMENT_DEPTH_SIZE = 0x8216
+ FRAMEBUFFER_ATTACHMENT_STENCIL_SIZE = 0x8217
+ FRAMEBUFFER_DEFAULT = 0x8218
+ FRAMEBUFFER_UNDEFINED = 0x8219
+ DEPTH_STENCIL_ATTACHMENT = 0x821A
+ MAJOR_VERSION = 0x821B
+ MINOR_VERSION = 0x821C
+ NUM_EXTENSIONS = 0x821D
+ CONTEXT_FLAGS = 0x821E
+ COMPRESSED_RED = 0x8225
+ COMPRESSED_RG = 0x8226
+ RG = 0x8227
+ RG_INTEGER = 0x8228
+ R8 = 0x8229
+ R16 = 0x822A
+ RG8 = 0x822B
+ RG16 = 0x822C
+ R16F = 0x822D
+ R32F = 0x822E
+ RG16F = 0x822F
+ RG32F = 0x8230
+ R8I = 0x8231
+ R8UI = 0x8232
+ R16I = 0x8233
+ R16UI = 0x8234
+ R32I = 0x8235
+ R32UI = 0x8236
+ RG8I = 0x8237
+ RG8UI = 0x8238
+ RG16I = 0x8239
+ RG16UI = 0x823A
+ RG32I = 0x823B
+ RG32UI = 0x823C
+ PROGRAM_SEPARABLE = 0x8258
+ ACTIVE_PROGRAM = 0x8259
+ PROGRAM_PIPELINE_BINDING = 0x825A
+ MAX_VIEWPORTS = 0x825B
+ VIEWPORT_SUBPIXEL_BITS = 0x825C
+ VIEWPORT_BOUNDS_RANGE = 0x825D
+ LAYER_PROVOKING_VERTEX = 0x825E
+ VIEWPORT_INDEX_PROVOKING_VERTEX = 0x825F
+ UNDEFINED_VERTEX = 0x8260
+ UNSIGNED_BYTE_2_3_3_REV = 0x8362
+ UNSIGNED_SHORT_5_6_5 = 0x8363
+ UNSIGNED_SHORT_5_6_5_REV = 0x8364
+ UNSIGNED_SHORT_4_4_4_4_REV = 0x8365
+ UNSIGNED_SHORT_1_5_5_5_REV = 0x8366
+ UNSIGNED_INT_8_8_8_8_REV = 0x8367
+ UNSIGNED_INT_2_10_10_10_REV = 0x8368
+ MIRRORED_REPEAT = 0x8370
+ FOG_COORDINATE_SOURCE = 0x8450
+ FOG_COORD_SRC = 0x8450
+ FOG_COORDINATE = 0x8451
+ FOG_COORD = 0x8451
+ FRAGMENT_DEPTH = 0x8452
+ CURRENT_FOG_COORDINATE = 0x8453
+ CURRENT_FOG_COORD = 0x8453
+ FOG_COORDINATE_ARRAY_TYPE = 0x8454
+ FOG_COORD_ARRAY_TYPE = 0x8454
+ FOG_COORDINATE_ARRAY_STRIDE = 0x8455
+ FOG_COORD_ARRAY_STRIDE = 0x8455
+ FOG_COORDINATE_ARRAY_POINTER = 0x8456
+ FOG_COORD_ARRAY_POINTER = 0x8456
+ FOG_COORDINATE_ARRAY = 0x8457
+ FOG_COORD_ARRAY = 0x8457
+ COLOR_SUM = 0x8458
+ CURRENT_SECONDARY_COLOR = 0x8459
+ SECONDARY_COLOR_ARRAY_SIZE = 0x845A
+ SECONDARY_COLOR_ARRAY_TYPE = 0x845B
+ SECONDARY_COLOR_ARRAY_STRIDE = 0x845C
+ SECONDARY_COLOR_ARRAY_POINTER = 0x845D
+ SECONDARY_COLOR_ARRAY = 0x845E
+ CURRENT_RASTER_SECONDARY_COLOR = 0x845F
+ TEXTURE0 = 0x84C0
+ TEXTURE1 = 0x84C1
+ TEXTURE2 = 0x84C2
+ TEXTURE3 = 0x84C3
+ TEXTURE4 = 0x84C4
+ TEXTURE5 = 0x84C5
+ TEXTURE6 = 0x84C6
+ TEXTURE7 = 0x84C7
+ TEXTURE8 = 0x84C8
+ TEXTURE9 = 0x84C9
+ TEXTURE10 = 0x84CA
+ TEXTURE11 = 0x84CB
+ TEXTURE12 = 0x84CC
+ TEXTURE13 = 0x84CD
+ TEXTURE14 = 0x84CE
+ TEXTURE15 = 0x84CF
+ TEXTURE16 = 0x84D0
+ TEXTURE17 = 0x84D1
+ TEXTURE18 = 0x84D2
+ TEXTURE19 = 0x84D3
+ TEXTURE20 = 0x84D4
+ TEXTURE21 = 0x84D5
+ TEXTURE22 = 0x84D6
+ TEXTURE23 = 0x84D7
+ TEXTURE24 = 0x84D8
+ TEXTURE25 = 0x84D9
+ TEXTURE26 = 0x84DA
+ TEXTURE27 = 0x84DB
+ TEXTURE28 = 0x84DC
+ TEXTURE29 = 0x84DD
+ TEXTURE30 = 0x84DE
+ TEXTURE31 = 0x84DF
+ ACTIVE_TEXTURE = 0x84E0
+ CLIENT_ACTIVE_TEXTURE = 0x84E1
+ MAX_TEXTURE_UNITS = 0x84E2
+ TRANSPOSE_MODELVIEW_MATRIX = 0x84E3
+ TRANSPOSE_PROJECTION_MATRIX = 0x84E4
+ TRANSPOSE_TEXTURE_MATRIX = 0x84E5
+ TRANSPOSE_COLOR_MATRIX = 0x84E6
+ SUBTRACT = 0x84E7
+ MAX_RENDERBUFFER_SIZE = 0x84E8
+ COMPRESSED_ALPHA = 0x84E9
+ COMPRESSED_LUMINANCE = 0x84EA
+ COMPRESSED_LUMINANCE_ALPHA = 0x84EB
+ COMPRESSED_INTENSITY = 0x84EC
+ COMPRESSED_RGB = 0x84ED
+ COMPRESSED_RGBA = 0x84EE
+ UNIFORM_BLOCK_REFERENCED_BY_TESS_CONTROL_SHADER = 0x84F0
+ UNIFORM_BLOCK_REFERENCED_BY_TESS_EVALUATION_SHADER = 0x84F1
+ TEXTURE_RECTANGLE = 0x84F5
+ TEXTURE_BINDING_RECTANGLE = 0x84F6
+ PROXY_TEXTURE_RECTANGLE = 0x84F7
+ MAX_RECTANGLE_TEXTURE_SIZE = 0x84F8
+ DEPTH_STENCIL = 0x84F9
+ UNSIGNED_INT_24_8 = 0x84FA
+ MAX_TEXTURE_LOD_BIAS = 0x84FD
+ TEXTURE_FILTER_CONTROL = 0x8500
+ TEXTURE_LOD_BIAS = 0x8501
+ INCR_WRAP = 0x8507
+ DECR_WRAP = 0x8508
+ NORMAL_MAP = 0x8511
+ REFLECTION_MAP = 0x8512
+ TEXTURE_CUBE_MAP = 0x8513
+ TEXTURE_BINDING_CUBE_MAP = 0x8514
+ TEXTURE_CUBE_MAP_POSITIVE_X = 0x8515
+ TEXTURE_CUBE_MAP_NEGATIVE_X = 0x8516
+ TEXTURE_CUBE_MAP_POSITIVE_Y = 0x8517
+ TEXTURE_CUBE_MAP_NEGATIVE_Y = 0x8518
+ TEXTURE_CUBE_MAP_POSITIVE_Z = 0x8519
+ TEXTURE_CUBE_MAP_NEGATIVE_Z = 0x851A
+ PROXY_TEXTURE_CUBE_MAP = 0x851B
+ MAX_CUBE_MAP_TEXTURE_SIZE = 0x851C
+ COMBINE = 0x8570
+ COMBINE_RGB = 0x8571
+ COMBINE_ALPHA = 0x8572
+ RGB_SCALE = 0x8573
+ ADD_SIGNED = 0x8574
+ INTERPOLATE = 0x8575
+ CONSTANT = 0x8576
+ PRIMARY_COLOR = 0x8577
+ PREVIOUS = 0x8578
+ SOURCE0_RGB = 0x8580
+ SRC0_RGB = 0x8580
+ SOURCE1_RGB = 0x8581
+ SRC1_RGB = 0x8581
+ SOURCE2_RGB = 0x8582
+ SRC2_RGB = 0x8582
+ SOURCE0_ALPHA = 0x8588
+ SRC0_ALPHA = 0x8588
+ SOURCE1_ALPHA = 0x8589
+ SRC1_ALPHA = 0x8589
+ SOURCE2_ALPHA = 0x858A
+ SRC2_ALPHA = 0x858A
+ OPERAND0_RGB = 0x8590
+ OPERAND1_RGB = 0x8591
+ OPERAND2_RGB = 0x8592
+ OPERAND0_ALPHA = 0x8598
+ OPERAND1_ALPHA = 0x8599
+ OPERAND2_ALPHA = 0x859A
+ VERTEX_ARRAY_BINDING = 0x85B5
+ VERTEX_ATTRIB_ARRAY_ENABLED = 0x8622
+ VERTEX_ATTRIB_ARRAY_SIZE = 0x8623
+ VERTEX_ATTRIB_ARRAY_STRIDE = 0x8624
+ VERTEX_ATTRIB_ARRAY_TYPE = 0x8625
+ CURRENT_VERTEX_ATTRIB = 0x8626
+ VERTEX_PROGRAM_POINT_SIZE = 0x8642
+ PROGRAM_POINT_SIZE = 0x8642
+ VERTEX_PROGRAM_TWO_SIDE = 0x8643
+ VERTEX_ATTRIB_ARRAY_POINTER = 0x8645
+ DEPTH_CLAMP = 0x864F
+ TEXTURE_COMPRESSED_IMAGE_SIZE = 0x86A0
+ TEXTURE_COMPRESSED = 0x86A1
+ NUM_COMPRESSED_TEXTURE_FORMATS = 0x86A2
+ COMPRESSED_TEXTURE_FORMATS = 0x86A3
+ DOT3_RGB = 0x86AE
+ DOT3_RGBA = 0x86AF
+ PROGRAM_BINARY_LENGTH = 0x8741
+ BUFFER_SIZE = 0x8764
+ BUFFER_USAGE = 0x8765
+ NUM_PROGRAM_BINARY_FORMATS = 0x87FE
+ PROGRAM_BINARY_FORMATS = 0x87FF
+ STENCIL_BACK_FUNC = 0x8800
+ STENCIL_BACK_FAIL = 0x8801
+ STENCIL_BACK_PASS_DEPTH_FAIL = 0x8802
+ STENCIL_BACK_PASS_DEPTH_PASS = 0x8803
+ RGBA32F = 0x8814
+ RGB32F = 0x8815
+ RGBA16F = 0x881A
+ RGB16F = 0x881B
+ MAX_DRAW_BUFFERS = 0x8824
+ DRAW_BUFFER0 = 0x8825
+ DRAW_BUFFER1 = 0x8826
+ DRAW_BUFFER2 = 0x8827
+ DRAW_BUFFER3 = 0x8828
+ DRAW_BUFFER4 = 0x8829
+ DRAW_BUFFER5 = 0x882A
+ DRAW_BUFFER6 = 0x882B
+ DRAW_BUFFER7 = 0x882C
+ DRAW_BUFFER8 = 0x882D
+ DRAW_BUFFER9 = 0x882E
+ DRAW_BUFFER10 = 0x882F
+ DRAW_BUFFER11 = 0x8830
+ DRAW_BUFFER12 = 0x8831
+ DRAW_BUFFER13 = 0x8832
+ DRAW_BUFFER14 = 0x8833
+ DRAW_BUFFER15 = 0x8834
+ BLEND_EQUATION_ALPHA = 0x883D
+ TEXTURE_DEPTH_SIZE = 0x884A
+ DEPTH_TEXTURE_MODE = 0x884B
+ TEXTURE_COMPARE_MODE = 0x884C
+ TEXTURE_COMPARE_FUNC = 0x884D
+ COMPARE_R_TO_TEXTURE = 0x884E
+ COMPARE_REF_TO_TEXTURE = 0x884E
+ TEXTURE_CUBE_MAP_SEAMLESS = 0x884F
+ POINT_SPRITE = 0x8861
+ COORD_REPLACE = 0x8862
+ QUERY_COUNTER_BITS = 0x8864
+ CURRENT_QUERY = 0x8865
+ QUERY_RESULT = 0x8866
+ QUERY_RESULT_AVAILABLE = 0x8867
+ MAX_VERTEX_ATTRIBS = 0x8869
+ VERTEX_ATTRIB_ARRAY_NORMALIZED = 0x886A
+ MAX_TESS_CONTROL_INPUT_COMPONENTS = 0x886C
+ MAX_TESS_EVALUATION_INPUT_COMPONENTS = 0x886D
+ MAX_TEXTURE_COORDS = 0x8871
+ MAX_TEXTURE_IMAGE_UNITS = 0x8872
+ GEOMETRY_SHADER_INVOCATIONS = 0x887F
+ ARRAY_BUFFER = 0x8892
+ ELEMENT_ARRAY_BUFFER = 0x8893
+ ARRAY_BUFFER_BINDING = 0x8894
+ ELEMENT_ARRAY_BUFFER_BINDING = 0x8895
+ VERTEX_ARRAY_BUFFER_BINDING = 0x8896
+ NORMAL_ARRAY_BUFFER_BINDING = 0x8897
+ COLOR_ARRAY_BUFFER_BINDING = 0x8898
+ INDEX_ARRAY_BUFFER_BINDING = 0x8899
+ TEXTURE_COORD_ARRAY_BUFFER_BINDING = 0x889A
+ EDGE_FLAG_ARRAY_BUFFER_BINDING = 0x889B
+ SECONDARY_COLOR_ARRAY_BUFFER_BINDING = 0x889C
+ FOG_COORDINATE_ARRAY_BUFFER_BINDING = 0x889D
+ FOG_COORD_ARRAY_BUFFER_BINDING = 0x889D
+ WEIGHT_ARRAY_BUFFER_BINDING = 0x889E
+ VERTEX_ATTRIB_ARRAY_BUFFER_BINDING = 0x889F
+ READ_ONLY = 0x88B8
+ WRITE_ONLY = 0x88B9
+ READ_WRITE = 0x88BA
+ BUFFER_ACCESS = 0x88BB
+ BUFFER_MAPPED = 0x88BC
+ BUFFER_MAP_POINTER = 0x88BD
+ TIME_ELAPSED = 0x88BF
+ STREAM_DRAW = 0x88E0
+ STREAM_READ = 0x88E1
+ STREAM_COPY = 0x88E2
+ STATIC_DRAW = 0x88E4
+ STATIC_READ = 0x88E5
+ STATIC_COPY = 0x88E6
+ DYNAMIC_DRAW = 0x88E8
+ DYNAMIC_READ = 0x88E9
+ DYNAMIC_COPY = 0x88EA
+ PIXEL_PACK_BUFFER = 0x88EB
+ PIXEL_UNPACK_BUFFER = 0x88EC
+ PIXEL_PACK_BUFFER_BINDING = 0x88ED
+ PIXEL_UNPACK_BUFFER_BINDING = 0x88EF
+ DEPTH24_STENCIL8 = 0x88F0
+ TEXTURE_STENCIL_SIZE = 0x88F1
+ SRC1_COLOR = 0x88F9
+ ONE_MINUS_SRC1_COLOR = 0x88FA
+ ONE_MINUS_SRC1_ALPHA = 0x88FB
+ MAX_DUAL_SOURCE_DRAW_BUFFERS = 0x88FC
+ VERTEX_ATTRIB_ARRAY_INTEGER = 0x88FD
+ VERTEX_ATTRIB_ARRAY_DIVISOR = 0x88FE
+ MAX_ARRAY_TEXTURE_LAYERS = 0x88FF
+ MIN_PROGRAM_TEXEL_OFFSET = 0x8904
+ MAX_PROGRAM_TEXEL_OFFSET = 0x8905
+ SAMPLES_PASSED = 0x8914
+ GEOMETRY_VERTICES_OUT = 0x8916
+ GEOMETRY_INPUT_TYPE = 0x8917
+ GEOMETRY_OUTPUT_TYPE = 0x8918
+ SAMPLER_BINDING = 0x8919
+ CLAMP_VERTEX_COLOR = 0x891A
+ CLAMP_FRAGMENT_COLOR = 0x891B
+ CLAMP_READ_COLOR = 0x891C
+ FIXED_ONLY = 0x891D
+ UNIFORM_BUFFER = 0x8A11
+ UNIFORM_BUFFER_BINDING = 0x8A28
+ UNIFORM_BUFFER_START = 0x8A29
+ UNIFORM_BUFFER_SIZE = 0x8A2A
+ MAX_VERTEX_UNIFORM_BLOCKS = 0x8A2B
+ MAX_GEOMETRY_UNIFORM_BLOCKS = 0x8A2C
+ MAX_FRAGMENT_UNIFORM_BLOCKS = 0x8A2D
+ MAX_COMBINED_UNIFORM_BLOCKS = 0x8A2E
+ MAX_UNIFORM_BUFFER_BINDINGS = 0x8A2F
+ MAX_UNIFORM_BLOCK_SIZE = 0x8A30
+ MAX_COMBINED_VERTEX_UNIFORM_COMPONENTS = 0x8A31
+ MAX_COMBINED_GEOMETRY_UNIFORM_COMPONENTS = 0x8A32
+ MAX_COMBINED_FRAGMENT_UNIFORM_COMPONENTS = 0x8A33
+ UNIFORM_BUFFER_OFFSET_ALIGNMENT = 0x8A34
+ ACTIVE_UNIFORM_BLOCK_MAX_NAME_LENGTH = 0x8A35
+ ACTIVE_UNIFORM_BLOCKS = 0x8A36
+ UNIFORM_TYPE = 0x8A37
+ UNIFORM_SIZE = 0x8A38
+ UNIFORM_NAME_LENGTH = 0x8A39
+ UNIFORM_BLOCK_INDEX = 0x8A3A
+ UNIFORM_OFFSET = 0x8A3B
+ UNIFORM_ARRAY_STRIDE = 0x8A3C
+ UNIFORM_MATRIX_STRIDE = 0x8A3D
+ UNIFORM_IS_ROW_MAJOR = 0x8A3E
+ UNIFORM_BLOCK_BINDING = 0x8A3F
+ UNIFORM_BLOCK_DATA_SIZE = 0x8A40
+ UNIFORM_BLOCK_NAME_LENGTH = 0x8A41
+ UNIFORM_BLOCK_ACTIVE_UNIFORMS = 0x8A42
+ UNIFORM_BLOCK_ACTIVE_UNIFORM_INDICES = 0x8A43
+ UNIFORM_BLOCK_REFERENCED_BY_VERTEX_SHADER = 0x8A44
+ UNIFORM_BLOCK_REFERENCED_BY_GEOMETRY_SHADER = 0x8A45
+ UNIFORM_BLOCK_REFERENCED_BY_FRAGMENT_SHADER = 0x8A46
+ FRAGMENT_SHADER = 0x8B30
+ VERTEX_SHADER = 0x8B31
+ MAX_FRAGMENT_UNIFORM_COMPONENTS = 0x8B49
+ MAX_VERTEX_UNIFORM_COMPONENTS = 0x8B4A
+ MAX_VARYING_FLOATS = 0x8B4B
+ MAX_VARYING_COMPONENTS = 0x8B4B
+ MAX_VERTEX_TEXTURE_IMAGE_UNITS = 0x8B4C
+ MAX_COMBINED_TEXTURE_IMAGE_UNITS = 0x8B4D
+ SHADER_TYPE = 0x8B4F
+ FLOAT_VEC2 = 0x8B50
+ FLOAT_VEC3 = 0x8B51
+ FLOAT_VEC4 = 0x8B52
+ INT_VEC2 = 0x8B53
+ INT_VEC3 = 0x8B54
+ INT_VEC4 = 0x8B55
+ BOOL = 0x8B56
+ BOOL_VEC2 = 0x8B57
+ BOOL_VEC3 = 0x8B58
+ BOOL_VEC4 = 0x8B59
+ FLOAT_MAT2 = 0x8B5A
+ FLOAT_MAT3 = 0x8B5B
+ FLOAT_MAT4 = 0x8B5C
+ SAMPLER_1D = 0x8B5D
+ SAMPLER_2D = 0x8B5E
+ SAMPLER_3D = 0x8B5F
+ SAMPLER_CUBE = 0x8B60
+ SAMPLER_1D_SHADOW = 0x8B61
+ SAMPLER_2D_SHADOW = 0x8B62
+ SAMPLER_2D_RECT = 0x8B63
+ SAMPLER_2D_RECT_SHADOW = 0x8B64
+ FLOAT_MAT2x3 = 0x8B65
+ FLOAT_MAT2x4 = 0x8B66
+ FLOAT_MAT3x2 = 0x8B67
+ FLOAT_MAT3x4 = 0x8B68
+ FLOAT_MAT4x2 = 0x8B69
+ FLOAT_MAT4x3 = 0x8B6A
+ DELETE_STATUS = 0x8B80
+ COMPILE_STATUS = 0x8B81
+ LINK_STATUS = 0x8B82
+ VALIDATE_STATUS = 0x8B83
+ INFO_LOG_LENGTH = 0x8B84
+ ATTACHED_SHADERS = 0x8B85
+ ACTIVE_UNIFORMS = 0x8B86
+ ACTIVE_UNIFORM_MAX_LENGTH = 0x8B87
+ SHADER_SOURCE_LENGTH = 0x8B88
+ ACTIVE_ATTRIBUTES = 0x8B89
+ ACTIVE_ATTRIBUTE_MAX_LENGTH = 0x8B8A
+ SHADING_LANGUAGE_VERSION = 0x8B8C
+ CURRENT_PROGRAM = 0x8B8D
+ IMPLEMENTATION_COLOR_READ_TYPE = 0x8B9A
+ IMPLEMENTATION_COLOR_READ_FORMAT = 0x8B9B
+ TEXTURE_RED_TYPE = 0x8C10
+ TEXTURE_GREEN_TYPE = 0x8C11
+ TEXTURE_BLUE_TYPE = 0x8C12
+ TEXTURE_ALPHA_TYPE = 0x8C13
+ TEXTURE_DEPTH_TYPE = 0x8C16
+ UNSIGNED_NORMALIZED = 0x8C17
+ TEXTURE_1D_ARRAY = 0x8C18
+ PROXY_TEXTURE_1D_ARRAY = 0x8C19
+ TEXTURE_2D_ARRAY = 0x8C1A
+ PROXY_TEXTURE_2D_ARRAY = 0x8C1B
+ TEXTURE_BINDING_1D_ARRAY = 0x8C1C
+ TEXTURE_BINDING_2D_ARRAY = 0x8C1D
+ MAX_GEOMETRY_TEXTURE_IMAGE_UNITS = 0x8C29
+ TEXTURE_BUFFER = 0x8C2A
+ MAX_TEXTURE_BUFFER_SIZE = 0x8C2B
+ TEXTURE_BINDING_BUFFER = 0x8C2C
+ TEXTURE_BUFFER_DATA_STORE_BINDING = 0x8C2D
+ ANY_SAMPLES_PASSED = 0x8C2F
+ SAMPLE_SHADING = 0x8C36
+ MIN_SAMPLE_SHADING_VALUE = 0x8C37
+ R11F_G11F_B10F = 0x8C3A
+ UNSIGNED_INT_10F_11F_11F_REV = 0x8C3B
+ RGB9_E5 = 0x8C3D
+ UNSIGNED_INT_5_9_9_9_REV = 0x8C3E
+ TEXTURE_SHARED_SIZE = 0x8C3F
+ SRGB = 0x8C40
+ SRGB8 = 0x8C41
+ SRGB_ALPHA = 0x8C42
+ SRGB8_ALPHA8 = 0x8C43
+ SLUMINANCE_ALPHA = 0x8C44
+ SLUMINANCE8_ALPHA8 = 0x8C45
+ SLUMINANCE = 0x8C46
+ SLUMINANCE8 = 0x8C47
+ COMPRESSED_SRGB = 0x8C48
+ COMPRESSED_SRGB_ALPHA = 0x8C49
+ COMPRESSED_SLUMINANCE = 0x8C4A
+ COMPRESSED_SLUMINANCE_ALPHA = 0x8C4B
+ TRANSFORM_FEEDBACK_VARYING_MAX_LENGTH = 0x8C76
+ TRANSFORM_FEEDBACK_BUFFER_MODE = 0x8C7F
+ MAX_TRANSFORM_FEEDBACK_SEPARATE_COMPONENTS = 0x8C80
+ TRANSFORM_FEEDBACK_VARYINGS = 0x8C83
+ TRANSFORM_FEEDBACK_BUFFER_START = 0x8C84
+ TRANSFORM_FEEDBACK_BUFFER_SIZE = 0x8C85
+ PRIMITIVES_GENERATED = 0x8C87
+ TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN = 0x8C88
+ RASTERIZER_DISCARD = 0x8C89
+ MAX_TRANSFORM_FEEDBACK_INTERLEAVED_COMPONENTS = 0x8C8A
+ MAX_TRANSFORM_FEEDBACK_SEPARATE_ATTRIBS = 0x8C8B
+ INTERLEAVED_ATTRIBS = 0x8C8C
+ SEPARATE_ATTRIBS = 0x8C8D
+ TRANSFORM_FEEDBACK_BUFFER = 0x8C8E
+ TRANSFORM_FEEDBACK_BUFFER_BINDING = 0x8C8F
+ POINT_SPRITE_COORD_ORIGIN = 0x8CA0
+ LOWER_LEFT = 0x8CA1
+ UPPER_LEFT = 0x8CA2
+ STENCIL_BACK_REF = 0x8CA3
+ STENCIL_BACK_VALUE_MASK = 0x8CA4
+ STENCIL_BACK_WRITEMASK = 0x8CA5
+ DRAW_FRAMEBUFFER_BINDING = 0x8CA6
+ FRAMEBUFFER_BINDING = 0x8CA6
+ RENDERBUFFER_BINDING = 0x8CA7
+ READ_FRAMEBUFFER = 0x8CA8
+ DRAW_FRAMEBUFFER = 0x8CA9
+ READ_FRAMEBUFFER_BINDING = 0x8CAA
+ RENDERBUFFER_SAMPLES = 0x8CAB
+ DEPTH_COMPONENT32F = 0x8CAC
+ DEPTH32F_STENCIL8 = 0x8CAD
+ FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE = 0x8CD0
+ FRAMEBUFFER_ATTACHMENT_OBJECT_NAME = 0x8CD1
+ FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL = 0x8CD2
+ FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE = 0x8CD3
+ FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER = 0x8CD4
+ FRAMEBUFFER_COMPLETE = 0x8CD5
+ FRAMEBUFFER_INCOMPLETE_ATTACHMENT = 0x8CD6
+ FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT = 0x8CD7
+ FRAMEBUFFER_INCOMPLETE_DRAW_BUFFER = 0x8CDB
+ FRAMEBUFFER_INCOMPLETE_READ_BUFFER = 0x8CDC
+ FRAMEBUFFER_UNSUPPORTED = 0x8CDD
+ MAX_COLOR_ATTACHMENTS = 0x8CDF
+ COLOR_ATTACHMENT0 = 0x8CE0
+ COLOR_ATTACHMENT1 = 0x8CE1
+ COLOR_ATTACHMENT2 = 0x8CE2
+ COLOR_ATTACHMENT3 = 0x8CE3
+ COLOR_ATTACHMENT4 = 0x8CE4
+ COLOR_ATTACHMENT5 = 0x8CE5
+ COLOR_ATTACHMENT6 = 0x8CE6
+ COLOR_ATTACHMENT7 = 0x8CE7
+ COLOR_ATTACHMENT8 = 0x8CE8
+ COLOR_ATTACHMENT9 = 0x8CE9
+ COLOR_ATTACHMENT10 = 0x8CEA
+ COLOR_ATTACHMENT11 = 0x8CEB
+ COLOR_ATTACHMENT12 = 0x8CEC
+ COLOR_ATTACHMENT13 = 0x8CED
+ COLOR_ATTACHMENT14 = 0x8CEE
+ COLOR_ATTACHMENT15 = 0x8CEF
+ DEPTH_ATTACHMENT = 0x8D00
+ STENCIL_ATTACHMENT = 0x8D20
+ FRAMEBUFFER = 0x8D40
+ RENDERBUFFER = 0x8D41
+ RENDERBUFFER_WIDTH = 0x8D42
+ RENDERBUFFER_HEIGHT = 0x8D43
+ RENDERBUFFER_INTERNAL_FORMAT = 0x8D44
+ STENCIL_INDEX1 = 0x8D46
+ STENCIL_INDEX4 = 0x8D47
+ STENCIL_INDEX8 = 0x8D48
+ STENCIL_INDEX16 = 0x8D49
+ RENDERBUFFER_RED_SIZE = 0x8D50
+ RENDERBUFFER_GREEN_SIZE = 0x8D51
+ RENDERBUFFER_BLUE_SIZE = 0x8D52
+ RENDERBUFFER_ALPHA_SIZE = 0x8D53
+ RENDERBUFFER_DEPTH_SIZE = 0x8D54
+ RENDERBUFFER_STENCIL_SIZE = 0x8D55
+ FRAMEBUFFER_INCOMPLETE_MULTISAMPLE = 0x8D56
+ MAX_SAMPLES = 0x8D57
+ RGB565 = 0x8D62
+ RGBA32UI = 0x8D70
+ RGB32UI = 0x8D71
+ RGBA16UI = 0x8D76
+ RGB16UI = 0x8D77
+ RGBA8UI = 0x8D7C
+ RGB8UI = 0x8D7D
+ RGBA32I = 0x8D82
+ RGB32I = 0x8D83
+ RGBA16I = 0x8D88
+ RGB16I = 0x8D89
+ RGBA8I = 0x8D8E
+ RGB8I = 0x8D8F
+ RED_INTEGER = 0x8D94
+ GREEN_INTEGER = 0x8D95
+ BLUE_INTEGER = 0x8D96
+ ALPHA_INTEGER = 0x8D97
+ RGB_INTEGER = 0x8D98
+ RGBA_INTEGER = 0x8D99
+ BGR_INTEGER = 0x8D9A
+ BGRA_INTEGER = 0x8D9B
+ INT_2_10_10_10_REV = 0x8D9F
+ FRAMEBUFFER_ATTACHMENT_LAYERED = 0x8DA7
+ FRAMEBUFFER_INCOMPLETE_LAYER_TARGETS = 0x8DA8
+ FLOAT_32_UNSIGNED_INT_24_8_REV = 0x8DAD
+ FRAMEBUFFER_SRGB = 0x8DB9
+ COMPRESSED_RED_RGTC1 = 0x8DBB
+ COMPRESSED_SIGNED_RED_RGTC1 = 0x8DBC
+ COMPRESSED_RG_RGTC2 = 0x8DBD
+ COMPRESSED_SIGNED_RG_RGTC2 = 0x8DBE
+ SAMPLER_1D_ARRAY = 0x8DC0
+ SAMPLER_2D_ARRAY = 0x8DC1
+ SAMPLER_BUFFER = 0x8DC2
+ SAMPLER_1D_ARRAY_SHADOW = 0x8DC3
+ SAMPLER_2D_ARRAY_SHADOW = 0x8DC4
+ SAMPLER_CUBE_SHADOW = 0x8DC5
+ UNSIGNED_INT_VEC2 = 0x8DC6
+ UNSIGNED_INT_VEC3 = 0x8DC7
+ UNSIGNED_INT_VEC4 = 0x8DC8
+ INT_SAMPLER_1D = 0x8DC9
+ INT_SAMPLER_2D = 0x8DCA
+ INT_SAMPLER_3D = 0x8DCB
+ INT_SAMPLER_CUBE = 0x8DCC
+ INT_SAMPLER_2D_RECT = 0x8DCD
+ INT_SAMPLER_1D_ARRAY = 0x8DCE
+ INT_SAMPLER_2D_ARRAY = 0x8DCF
+ INT_SAMPLER_BUFFER = 0x8DD0
+ UNSIGNED_INT_SAMPLER_1D = 0x8DD1
+ UNSIGNED_INT_SAMPLER_2D = 0x8DD2
+ UNSIGNED_INT_SAMPLER_3D = 0x8DD3
+ UNSIGNED_INT_SAMPLER_CUBE = 0x8DD4
+ UNSIGNED_INT_SAMPLER_2D_RECT = 0x8DD5
+ UNSIGNED_INT_SAMPLER_1D_ARRAY = 0x8DD6
+ UNSIGNED_INT_SAMPLER_2D_ARRAY = 0x8DD7
+ UNSIGNED_INT_SAMPLER_BUFFER = 0x8DD8
+ GEOMETRY_SHADER = 0x8DD9
+ MAX_GEOMETRY_UNIFORM_COMPONENTS = 0x8DDF
+ MAX_GEOMETRY_OUTPUT_VERTICES = 0x8DE0
+ MAX_GEOMETRY_TOTAL_OUTPUT_COMPONENTS = 0x8DE1
+ ACTIVE_SUBROUTINES = 0x8DE5
+ ACTIVE_SUBROUTINE_UNIFORMS = 0x8DE6
+ MAX_SUBROUTINES = 0x8DE7
+ MAX_SUBROUTINE_UNIFORM_LOCATIONS = 0x8DE8
+ LOW_FLOAT = 0x8DF0
+ MEDIUM_FLOAT = 0x8DF1
+ HIGH_FLOAT = 0x8DF2
+ LOW_INT = 0x8DF3
+ MEDIUM_INT = 0x8DF4
+ HIGH_INT = 0x8DF5
+ SHADER_BINARY_FORMATS = 0x8DF8
+ NUM_SHADER_BINARY_FORMATS = 0x8DF9
+ SHADER_COMPILER = 0x8DFA
+ MAX_VERTEX_UNIFORM_VECTORS = 0x8DFB
+ MAX_VARYING_VECTORS = 0x8DFC
+ MAX_FRAGMENT_UNIFORM_VECTORS = 0x8DFD
+ QUERY_WAIT = 0x8E13
+ QUERY_NO_WAIT = 0x8E14
+ QUERY_BY_REGION_WAIT = 0x8E15
+ QUERY_BY_REGION_NO_WAIT = 0x8E16
+ MAX_COMBINED_TESS_CONTROL_UNIFORM_COMPONENTS = 0x8E1E
+ MAX_COMBINED_TESS_EVALUATION_UNIFORM_COMPONENTS = 0x8E1F
+ TRANSFORM_FEEDBACK = 0x8E22
+ TRANSFORM_FEEDBACK_BUFFER_PAUSED = 0x8E23
+ TRANSFORM_FEEDBACK_BUFFER_ACTIVE = 0x8E24
+ TRANSFORM_FEEDBACK_BINDING = 0x8E25
+ TIMESTAMP = 0x8E28
+ TEXTURE_SWIZZLE_R = 0x8E42
+ TEXTURE_SWIZZLE_G = 0x8E43
+ TEXTURE_SWIZZLE_B = 0x8E44
+ TEXTURE_SWIZZLE_A = 0x8E45
+ TEXTURE_SWIZZLE_RGBA = 0x8E46
+ ACTIVE_SUBROUTINE_UNIFORM_LOCATIONS = 0x8E47
+ ACTIVE_SUBROUTINE_MAX_LENGTH = 0x8E48
+ ACTIVE_SUBROUTINE_UNIFORM_MAX_LENGTH = 0x8E49
+ NUM_COMPATIBLE_SUBROUTINES = 0x8E4A
+ COMPATIBLE_SUBROUTINES = 0x8E4B
+ QUADS_FOLLOW_PROVOKING_VERTEX_CONVENTION = 0x8E4C
+ FIRST_VERTEX_CONVENTION = 0x8E4D
+ LAST_VERTEX_CONVENTION = 0x8E4E
+ PROVOKING_VERTEX = 0x8E4F
+ SAMPLE_POSITION = 0x8E50
+ SAMPLE_MASK = 0x8E51
+ SAMPLE_MASK_VALUE = 0x8E52
+ MAX_SAMPLE_MASK_WORDS = 0x8E59
+ MAX_GEOMETRY_SHADER_INVOCATIONS = 0x8E5A
+ MIN_FRAGMENT_INTERPOLATION_OFFSET = 0x8E5B
+ MAX_FRAGMENT_INTERPOLATION_OFFSET = 0x8E5C
+ FRAGMENT_INTERPOLATION_OFFSET_BITS = 0x8E5D
+ MIN_PROGRAM_TEXTURE_GATHER_OFFSET = 0x8E5E
+ MAX_PROGRAM_TEXTURE_GATHER_OFFSET = 0x8E5F
+ MAX_TRANSFORM_FEEDBACK_BUFFERS = 0x8E70
+ MAX_VERTEX_STREAMS = 0x8E71
+ PATCH_VERTICES = 0x8E72
+ PATCH_DEFAULT_INNER_LEVEL = 0x8E73
+ PATCH_DEFAULT_OUTER_LEVEL = 0x8E74
+ TESS_CONTROL_OUTPUT_VERTICES = 0x8E75
+ TESS_GEN_MODE = 0x8E76
+ TESS_GEN_SPACING = 0x8E77
+ TESS_GEN_VERTEX_ORDER = 0x8E78
+ TESS_GEN_POINT_MODE = 0x8E79
+ ISOLINES = 0x8E7A
+ FRACTIONAL_ODD = 0x8E7B
+ FRACTIONAL_EVEN = 0x8E7C
+ MAX_PATCH_VERTICES = 0x8E7D
+ MAX_TESS_GEN_LEVEL = 0x8E7E
+ MAX_TESS_CONTROL_UNIFORM_COMPONENTS = 0x8E7F
+ MAX_TESS_EVALUATION_UNIFORM_COMPONENTS = 0x8E80
+ MAX_TESS_CONTROL_TEXTURE_IMAGE_UNITS = 0x8E81
+ MAX_TESS_EVALUATION_TEXTURE_IMAGE_UNITS = 0x8E82
+ MAX_TESS_CONTROL_OUTPUT_COMPONENTS = 0x8E83
+ MAX_TESS_PATCH_COMPONENTS = 0x8E84
+ MAX_TESS_CONTROL_TOTAL_OUTPUT_COMPONENTS = 0x8E85
+ MAX_TESS_EVALUATION_OUTPUT_COMPONENTS = 0x8E86
+ TESS_EVALUATION_SHADER = 0x8E87
+ TESS_CONTROL_SHADER = 0x8E88
+ MAX_TESS_CONTROL_UNIFORM_BLOCKS = 0x8E89
+ MAX_TESS_EVALUATION_UNIFORM_BLOCKS = 0x8E8A
+ COPY_READ_BUFFER = 0x8F36
+ COPY_WRITE_BUFFER = 0x8F37
+ DRAW_INDIRECT_BUFFER = 0x8F3F
+ DRAW_INDIRECT_BUFFER_BINDING = 0x8F43
+ DOUBLE_MAT2 = 0x8F46
+ DOUBLE_MAT3 = 0x8F47
+ DOUBLE_MAT4 = 0x8F48
+ DOUBLE_MAT2x3 = 0x8F49
+ DOUBLE_MAT2x4 = 0x8F4A
+ DOUBLE_MAT3x2 = 0x8F4B
+ DOUBLE_MAT3x4 = 0x8F4C
+ DOUBLE_MAT4x2 = 0x8F4D
+ DOUBLE_MAT4x3 = 0x8F4E
+ R8_SNORM = 0x8F94
+ RG8_SNORM = 0x8F95
+ RGB8_SNORM = 0x8F96
+ RGBA8_SNORM = 0x8F97
+ R16_SNORM = 0x8F98
+ RG16_SNORM = 0x8F99
+ RGB16_SNORM = 0x8F9A
+ RGBA16_SNORM = 0x8F9B
+ SIGNED_NORMALIZED = 0x8F9C
+ PRIMITIVE_RESTART = 0x8F9D
+ PRIMITIVE_RESTART_INDEX = 0x8F9E
+ DOUBLE_VEC2 = 0x8FFC
+ DOUBLE_VEC3 = 0x8FFD
+ DOUBLE_VEC4 = 0x8FFE
+ TEXTURE_CUBE_MAP_ARRAY = 0x9009
+ TEXTURE_BINDING_CUBE_MAP_ARRAY = 0x900A
+ PROXY_TEXTURE_CUBE_MAP_ARRAY = 0x900B
+ SAMPLER_CUBE_MAP_ARRAY = 0x900C
+ SAMPLER_CUBE_MAP_ARRAY_SHADOW = 0x900D
+ INT_SAMPLER_CUBE_MAP_ARRAY = 0x900E
+ UNSIGNED_INT_SAMPLER_CUBE_MAP_ARRAY = 0x900F
+ RGB10_A2UI = 0x906F
+ TEXTURE_2D_MULTISAMPLE = 0x9100
+ PROXY_TEXTURE_2D_MULTISAMPLE = 0x9101
+ TEXTURE_2D_MULTISAMPLE_ARRAY = 0x9102
+ PROXY_TEXTURE_2D_MULTISAMPLE_ARRAY = 0x9103
+ TEXTURE_BINDING_2D_MULTISAMPLE = 0x9104
+ TEXTURE_BINDING_2D_MULTISAMPLE_ARRAY = 0x9105
+ TEXTURE_SAMPLES = 0x9106
+ TEXTURE_FIXED_SAMPLE_LOCATIONS = 0x9107
+ SAMPLER_2D_MULTISAMPLE = 0x9108
+ INT_SAMPLER_2D_MULTISAMPLE = 0x9109
+ UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE = 0x910A
+ SAMPLER_2D_MULTISAMPLE_ARRAY = 0x910B
+ INT_SAMPLER_2D_MULTISAMPLE_ARRAY = 0x910C
+ UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE_ARRAY = 0x910D
+ MAX_COLOR_TEXTURE_SAMPLES = 0x910E
+ MAX_DEPTH_TEXTURE_SAMPLES = 0x910F
+ MAX_INTEGER_SAMPLES = 0x9110
+ MAX_SERVER_WAIT_TIMEOUT = 0x9111
+ OBJECT_TYPE = 0x9112
+ SYNC_CONDITION = 0x9113
+ SYNC_STATUS = 0x9114
+ SYNC_FLAGS = 0x9115
+ SYNC_FENCE = 0x9116
+ SYNC_GPU_COMMANDS_COMPLETE = 0x9117
+ UNSIGNALED = 0x9118
+ SIGNALED = 0x9119
+ ALREADY_SIGNALED = 0x911A
+ TIMEOUT_EXPIRED = 0x911B
+ CONDITION_SATISFIED = 0x911C
+ WAIT_FAILED = 0x911D
+ BUFFER_ACCESS_FLAGS = 0x911F
+ BUFFER_MAP_LENGTH = 0x9120
+ BUFFER_MAP_OFFSET = 0x9121
+ MAX_VERTEX_OUTPUT_COMPONENTS = 0x9122
+ MAX_GEOMETRY_INPUT_COMPONENTS = 0x9123
+ MAX_GEOMETRY_OUTPUT_COMPONENTS = 0x9124
+ MAX_FRAGMENT_INPUT_COMPONENTS = 0x9125
+ CONTEXT_PROFILE_MASK = 0x9126
+)
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glViewport.xml
+func (gl *GL) Viewport(x, y, width, height int) {
+ C.gl4_1core_glViewport(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// DepthRange specifies the mapping of depth values from normalized device
+// coordinates to window coordinates.
+//
+// Parameter nearVal specifies the mapping of the near clipping plane to window
+// coordinates (defaults to 0), while farVal specifies the mapping of the far
+// clipping plane to window coordinates (defaults to 1).
+//
+// After clipping and division by w, depth coordinates range from -1 to 1,
+// corresponding to the near and far clipping planes. DepthRange specifies a
+// linear mapping of the normalized depth coordinates in this range to window
+// depth coordinates. Regardless of the actual depth buffer implementation,
+// window coordinate depth values are treated as though they range from 0 through 1
+// (like color components). Thus, the values accepted by DepthRange are both
+// clamped to this range before they are accepted.
+//
+// The default setting of (0, 1) maps the near plane to 0 and the far plane to 1.
+// With this mapping, the depth buffer range is fully utilized.
+//
+// It is not necessary that nearVal be less than farVal. Reverse mappings such as
+// nearVal 1, and farVal 0 are acceptable.
+//
+// GL.INVALID_OPERATION is generated if DepthRange is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) DepthRange(nearVal, farVal float64) {
+ C.gl4_1core_glDepthRange(gl.funcs, C.GLdouble(nearVal), C.GLdouble(farVal))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsEnabled.xml
+func (gl *GL) IsEnabled(cap glbase.Enum) bool {
+ glresult := C.gl4_1core_glIsEnabled(gl.funcs, C.GLenum(cap))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexLevelParameteriv.xml
+func (gl *GL) GetTexLevelParameteriv(target glbase.Enum, level int, pname glbase.Enum, params []int32) {
+ C.gl4_1core_glGetTexLevelParameteriv(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexLevelParameterfv.xml
+func (gl *GL) GetTexLevelParameterfv(target glbase.Enum, level int, pname glbase.Enum, params []float32) {
+ C.gl4_1core_glGetTexLevelParameterfv(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexParameteriv.xml
+func (gl *GL) GetTexParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl4_1core_glGetTexParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexParameterfv.xml
+func (gl *GL) GetTexParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl4_1core_glGetTexParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexImage.xml
+func (gl *GL) GetTexImage(target glbase.Enum, level int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1core_glGetTexImage(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetIntegerv.xml
+func (gl *GL) GetIntegerv(pname glbase.Enum, params []int32) {
+ C.gl4_1core_glGetIntegerv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetFloatv.xml
+func (gl *GL) GetFloatv(pname glbase.Enum, params []float32) {
+ C.gl4_1core_glGetFloatv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetError.xml
+func (gl *GL) GetError() glbase.Enum {
+ glresult := C.gl4_1core_glGetError(gl.funcs)
+ return glbase.Enum(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetDoublev.xml
+func (gl *GL) GetDoublev(pname glbase.Enum, params []float64) {
+ C.gl4_1core_glGetDoublev(gl.funcs, C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetBooleanv.xml
+func (gl *GL) GetBooleanv(pname glbase.Enum, params []bool) {
+ C.gl4_1core_glGetBooleanv(gl.funcs, C.GLenum(pname), (*C.GLboolean)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glReadPixels.xml
+func (gl *GL) ReadPixels(x, y, width, height int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1core_glReadPixels(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glReadBuffer.xml
+func (gl *GL) ReadBuffer(mode glbase.Enum) {
+ C.gl4_1core_glReadBuffer(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPixelStorei.xml
+func (gl *GL) PixelStorei(pname glbase.Enum, param int32) {
+ C.gl4_1core_glPixelStorei(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPixelStoref.xml
+func (gl *GL) PixelStoref(pname glbase.Enum, param float32) {
+ C.gl4_1core_glPixelStoref(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDepthFunc.xml
+func (gl *GL) DepthFunc(glfunc glbase.Enum) {
+ C.gl4_1core_glDepthFunc(gl.funcs, C.GLenum(glfunc))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glStencilOp.xml
+func (gl *GL) StencilOp(fail, zfail, zpass glbase.Enum) {
+ C.gl4_1core_glStencilOp(gl.funcs, C.GLenum(fail), C.GLenum(zfail), C.GLenum(zpass))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glStencilFunc.xml
+func (gl *GL) StencilFunc(glfunc glbase.Enum, ref int32, mask uint32) {
+ C.gl4_1core_glStencilFunc(gl.funcs, C.GLenum(glfunc), C.GLint(ref), C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLogicOp.xml
+func (gl *GL) LogicOp(opcode glbase.Enum) {
+ C.gl4_1core_glLogicOp(gl.funcs, C.GLenum(opcode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendFunc.xml
+func (gl *GL) BlendFunc(sfactor, dfactor glbase.Enum) {
+ C.gl4_1core_glBlendFunc(gl.funcs, C.GLenum(sfactor), C.GLenum(dfactor))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFlush.xml
+func (gl *GL) Flush() {
+ C.gl4_1core_glFlush(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFinish.xml
+func (gl *GL) Finish() {
+ C.gl4_1core_glFinish(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEnable.xml
+func (gl *GL) Enable(cap glbase.Enum) {
+ C.gl4_1core_glEnable(gl.funcs, C.GLenum(cap))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDisable.xml
+func (gl *GL) Disable(cap glbase.Enum) {
+ C.gl4_1core_glDisable(gl.funcs, C.GLenum(cap))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDepthMask.xml
+func (gl *GL) DepthMask(flag bool) {
+ C.gl4_1core_glDepthMask(gl.funcs, *(*C.GLboolean)(unsafe.Pointer(&flag)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorMask.xml
+func (gl *GL) ColorMask(red, green, blue, alpha bool) {
+ C.gl4_1core_glColorMask(gl.funcs, *(*C.GLboolean)(unsafe.Pointer(&red)), *(*C.GLboolean)(unsafe.Pointer(&green)), *(*C.GLboolean)(unsafe.Pointer(&blue)), *(*C.GLboolean)(unsafe.Pointer(&alpha)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glStencilMask.xml
+func (gl *GL) StencilMask(mask uint32) {
+ C.gl4_1core_glStencilMask(gl.funcs, C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearDepth.xml
+func (gl *GL) ClearDepth(depth float64) {
+ C.gl4_1core_glClearDepth(gl.funcs, C.GLdouble(depth))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearStencil.xml
+func (gl *GL) ClearStencil(s int32) {
+ C.gl4_1core_glClearStencil(gl.funcs, C.GLint(s))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearColor.xml
+func (gl *GL) ClearColor(red, green, blue, alpha float32) {
+ C.gl4_1core_glClearColor(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClear.xml
+func (gl *GL) Clear(mask glbase.Bitfield) {
+ C.gl4_1core_glClear(gl.funcs, C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawBuffer.xml
+func (gl *GL) DrawBuffer(mode glbase.Enum) {
+ C.gl4_1core_glDrawBuffer(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexImage2D.xml
+func (gl *GL) TexImage2D(target glbase.Enum, level int, internalFormat int32, width, height, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1core_glTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexImage1D.xml
+func (gl *GL) TexImage1D(target glbase.Enum, level int, internalFormat int32, width, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1core_glTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexParameteriv.xml
+func (gl *GL) TexParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl4_1core_glTexParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexParameteri.xml
+func (gl *GL) TexParameteri(target, pname glbase.Enum, param int32) {
+ C.gl4_1core_glTexParameteri(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexParameterfv.xml
+func (gl *GL) TexParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl4_1core_glTexParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexParameterf.xml
+func (gl *GL) TexParameterf(target, pname glbase.Enum, param float32) {
+ C.gl4_1core_glTexParameterf(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glScissor.xml
+func (gl *GL) Scissor(x, y, width, height int) {
+ C.gl4_1core_glScissor(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPolygonMode.xml
+func (gl *GL) PolygonMode(face, mode glbase.Enum) {
+ C.gl4_1core_glPolygonMode(gl.funcs, C.GLenum(face), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPointSize.xml
+func (gl *GL) PointSize(size float32) {
+ C.gl4_1core_glPointSize(gl.funcs, C.GLfloat(size))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLineWidth.xml
+func (gl *GL) LineWidth(width float32) {
+ C.gl4_1core_glLineWidth(gl.funcs, C.GLfloat(width))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glHint.xml
+func (gl *GL) Hint(target, mode glbase.Enum) {
+ C.gl4_1core_glHint(gl.funcs, C.GLenum(target), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFrontFace.xml
+func (gl *GL) FrontFace(mode glbase.Enum) {
+ C.gl4_1core_glFrontFace(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCullFace.xml
+func (gl *GL) CullFace(mode glbase.Enum) {
+ C.gl4_1core_glCullFace(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIndexubv.xml
+func (gl *GL) Indexubv(c []uint8) {
+ C.gl4_1core_glIndexubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIndexub.xml
+func (gl *GL) Indexub(c uint8) {
+ C.gl4_1core_glIndexub(gl.funcs, C.GLubyte(c))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsTexture.xml
+func (gl *GL) IsTexture(texture glbase.Texture) bool {
+ glresult := C.gl4_1core_glIsTexture(gl.funcs, C.GLuint(texture))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// GenTextures returns n texture names in textures. There is no guarantee
+// that the names form a contiguous set of integers; however, it is
+// guaranteed that none of the returned names was in use immediately before
+// the call to GenTextures.
+//
+// The generated textures have no dimensionality; they assume the
+// dimensionality of the texture target to which they are first bound (see
+// BindTexture).
+//
+// Texture names returned by a call to GenTextures are not returned by
+// subsequent calls, unless they are first deleted with DeleteTextures.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// GenTextures is available in GL version 2.0 or greater.
+func (gl *GL) GenTextures(n int) []glbase.Texture {
+ if n == 0 {
+ return nil
+ }
+ textures := make([]glbase.Texture, n)
+ C.gl4_1core_glGenTextures(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])))
+ return textures
+}
+
+// DeleteTextures deletes the textures objects whose names are stored
+// in the textures slice. After a texture is deleted, it has no contents or
+// dimensionality, and its name is free for reuse (for example by
+// GenTextures). If a texture that is currently bound is deleted, the binding
+// reverts to 0 (the default texture).
+//
+// DeleteTextures silently ignores 0's and names that do not correspond to
+// existing textures.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// DeleteTextures is available in GL version 2.0 or greater.
+func (gl *GL) DeleteTextures(textures []glbase.Texture) {
+ n := len(textures)
+ if n == 0 {
+ return
+ }
+ C.gl4_1core_glDeleteTextures(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindTexture.xml
+func (gl *GL) BindTexture(target glbase.Enum, texture glbase.Texture) {
+ C.gl4_1core_glBindTexture(gl.funcs, C.GLenum(target), C.GLuint(texture))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexSubImage2D.xml
+func (gl *GL) TexSubImage2D(target glbase.Enum, level, xoffset, yoffset, width, height int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1core_glTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexSubImage1D.xml
+func (gl *GL) TexSubImage1D(target glbase.Enum, level, xoffset, width int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1core_glTexSubImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLsizei(width), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyTexSubImage2D.xml
+func (gl *GL) CopyTexSubImage2D(target glbase.Enum, level, xoffset, yoffset, x, y, width, height int) {
+ C.gl4_1core_glCopyTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyTexSubImage1D.xml
+func (gl *GL) CopyTexSubImage1D(target glbase.Enum, level, xoffset, x, y, width int) {
+ C.gl4_1core_glCopyTexSubImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(x), C.GLint(y), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyTexImage2D.xml
+func (gl *GL) CopyTexImage2D(target glbase.Enum, level int, internalFormat glbase.Enum, x, y, width, height, border int) {
+ C.gl4_1core_glCopyTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height), C.GLint(border))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyTexImage1D.xml
+func (gl *GL) CopyTexImage1D(target glbase.Enum, level int, internalFormat glbase.Enum, x, y, width, border int) {
+ C.gl4_1core_glCopyTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLint(border))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPolygonOffset.xml
+func (gl *GL) PolygonOffset(factor, units float32) {
+ C.gl4_1core_glPolygonOffset(gl.funcs, C.GLfloat(factor), C.GLfloat(units))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawElements.xml
+func (gl *GL) DrawElements(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1core_glDrawElements(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawArrays.xml
+func (gl *GL) DrawArrays(mode glbase.Enum, first, count int) {
+ C.gl4_1core_glDrawArrays(gl.funcs, C.GLenum(mode), C.GLint(first), C.GLsizei(count))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyTexSubImage3D.xml
+func (gl *GL) CopyTexSubImage3D(target glbase.Enum, level, xoffset, yoffset int, zoffset int32, x, y, width, height int) {
+ C.gl4_1core_glCopyTexSubImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(zoffset), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexSubImage3D.xml
+func (gl *GL) TexSubImage3D(target glbase.Enum, level, xoffset, yoffset int, zoffset int32, width, height int, depth int32, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1core_glTexSubImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(zoffset), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexImage3D.xml
+func (gl *GL) TexImage3D(target glbase.Enum, level int, internalFormat int32, width, height int, depth int32, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1core_glTexImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawRangeElements.xml
+func (gl *GL) DrawRangeElements(mode glbase.Enum, start, end uint32, count int, gltype glbase.Enum, indices interface{}) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1core_glDrawRangeElements(gl.funcs, C.GLenum(mode), C.GLuint(start), C.GLuint(end), C.GLsizei(count), C.GLenum(gltype), indices_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendEquation.xml
+func (gl *GL) BlendEquation(mode glbase.Enum) {
+ C.gl4_1core_glBlendEquation(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendColor.xml
+func (gl *GL) BlendColor(red, green, blue, alpha float32) {
+ C.gl4_1core_glBlendColor(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetCompressedTexImage.xml
+func (gl *GL) GetCompressedTexImage(target glbase.Enum, level int, img interface{}) {
+ var img_ptr unsafe.Pointer
+ var img_v = reflect.ValueOf(img)
+ if img != nil && img_v.Kind() != reflect.Slice {
+ panic("parameter img must be a slice")
+ }
+ if img != nil {
+ img_ptr = unsafe.Pointer(img_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1core_glGetCompressedTexImage(gl.funcs, C.GLenum(target), C.GLint(level), img_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCompressedTexSubImage1D.xml
+func (gl *GL) CompressedTexSubImage1D(target glbase.Enum, level, xoffset, width int, format glbase.Enum, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1core_glCompressedTexSubImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLsizei(width), C.GLenum(format), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCompressedTexSubImage2D.xml
+func (gl *GL) CompressedTexSubImage2D(target glbase.Enum, level, xoffset, yoffset, width, height int, format glbase.Enum, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1core_glCompressedTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCompressedTexSubImage3D.xml
+func (gl *GL) CompressedTexSubImage3D(target glbase.Enum, level, xoffset, yoffset int, zoffset int32, width, height int, depth int32, format glbase.Enum, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1core_glCompressedTexSubImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(zoffset), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLenum(format), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCompressedTexImage1D.xml
+func (gl *GL) CompressedTexImage1D(target glbase.Enum, level int, internalFormat glbase.Enum, width, border, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1core_glCompressedTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLsizei(width), C.GLint(border), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCompressedTexImage2D.xml
+func (gl *GL) CompressedTexImage2D(target glbase.Enum, level int, internalFormat glbase.Enum, width, height, border, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1core_glCompressedTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLint(border), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCompressedTexImage3D.xml
+func (gl *GL) CompressedTexImage3D(target glbase.Enum, level int, internalFormat glbase.Enum, width, height int, depth int32, border, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1core_glCompressedTexImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLint(border), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSampleCoverage.xml
+func (gl *GL) SampleCoverage(value float32, invert bool) {
+ C.gl4_1core_glSampleCoverage(gl.funcs, C.GLfloat(value), *(*C.GLboolean)(unsafe.Pointer(&invert)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glActiveTexture.xml
+func (gl *GL) ActiveTexture(texture glbase.Enum) {
+ C.gl4_1core_glActiveTexture(gl.funcs, C.GLenum(texture))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPointParameteriv.xml
+func (gl *GL) PointParameteriv(pname glbase.Enum, params []int32) {
+ C.gl4_1core_glPointParameteriv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPointParameteri.xml
+func (gl *GL) PointParameteri(pname glbase.Enum, param int32) {
+ C.gl4_1core_glPointParameteri(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPointParameterfv.xml
+func (gl *GL) PointParameterfv(pname glbase.Enum, params []float32) {
+ C.gl4_1core_glPointParameterfv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPointParameterf.xml
+func (gl *GL) PointParameterf(pname glbase.Enum, param float32) {
+ C.gl4_1core_glPointParameterf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiDrawArrays.xml
+func (gl *GL) MultiDrawArrays(mode glbase.Enum, first, count []int, drawcount int32) {
+ C.gl4_1core_glMultiDrawArrays(gl.funcs, C.GLenum(mode), (*C.GLint)(unsafe.Pointer(&first[0])), (*C.GLsizei)(unsafe.Pointer(&count[0])), C.GLsizei(drawcount))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendFuncSeparate.xml
+func (gl *GL) BlendFuncSeparate(sfactorRGB, dfactorRGB, sfactorAlpha, dfactorAlpha glbase.Enum) {
+ C.gl4_1core_glBlendFuncSeparate(gl.funcs, C.GLenum(sfactorRGB), C.GLenum(dfactorRGB), C.GLenum(sfactorAlpha), C.GLenum(dfactorAlpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetBufferParameteriv.xml
+func (gl *GL) GetBufferParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl4_1core_glGetBufferParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUnmapBuffer.xml
+func (gl *GL) UnmapBuffer(target glbase.Enum) bool {
+ glresult := C.gl4_1core_glUnmapBuffer(gl.funcs, C.GLenum(target))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetBufferSubData.xml
+func (gl *GL) GetBufferSubData(target glbase.Enum, offset, size int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1core_glGetBufferSubData(gl.funcs, C.GLenum(target), C.GLintptr(offset), C.GLsizeiptr(size), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBufferSubData.xml
+func (gl *GL) BufferSubData(target glbase.Enum, offset, size int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1core_glBufferSubData(gl.funcs, C.GLenum(target), C.GLintptr(offset), C.GLsizeiptr(size), data_ptr)
+}
+
+// BufferData creates a new data store for the buffer object currently
+// bound to target. Any pre-existing data store is deleted. The new data
+// store is created with the specified size in bytes and usage. If data is
+// not nil, it must be a slice that is used to initialize the data store.
+// In that case the size parameter is ignored and the store size will match
+// the slice data size.
+//
+// In its initial state, the new data store is not mapped, it has a NULL
+// mapped pointer, and its mapped access is GL.READ_WRITE.
+//
+// The target constant must be one of GL.ARRAY_BUFFER, GL.COPY_READ_BUFFER,
+// GL.COPY_WRITE_BUFFER, GL.ELEMENT_ARRAY_BUFFER, GL.PIXEL_PACK_BUFFER,
+// GL.PIXEL_UNPACK_BUFFER, GL.TEXTURE_BUFFER, GL.TRANSFORM_FEEDBACK_BUFFER,
+// or GL.UNIFORM_BUFFER.
+//
+// The usage parameter is a hint to the GL implementation as to how a buffer
+// object's data store will be accessed. This enables the GL implementation
+// to make more intelligent decisions that may significantly impact buffer
+// object performance. It does not, however, constrain the actual usage of
+// the data store. usage can be broken down into two parts: first, the
+// frequency of access (modification and usage), and second, the nature of
+// that access.
+//
+// A usage frequency of STREAM and nature of DRAW is specified via the
+// constant GL.STREAM_DRAW, for example.
+//
+// The usage frequency of access may be one of:
+//
+// STREAM
+// The data store contents will be modified once and used at most a few times.
+//
+// STATIC
+// The data store contents will be modified once and used many times.
+//
+// DYNAMIC
+// The data store contents will be modified repeatedly and used many times.
+//
+// The usage nature of access may be one of:
+//
+// DRAW
+// The data store contents are modified by the application, and used as
+// the source for GL drawing and image specification commands.
+//
+// READ
+// The data store contents are modified by reading data from the GL,
+// and used to return that data when queried by the application.
+//
+// COPY
+// The data store contents are modified by reading data from the GL,
+// and used as the source for GL drawing and image specification
+// commands.
+//
+// Clients must align data elements consistent with the requirements of the
+// client platform, with an additional base-level requirement that an offset
+// within a buffer to a datum comprising N bytes be a multiple of N.
+//
+// Error GL.INVALID_ENUM is generated if target is not one of the accepted
+// buffer targets. GL.INVALID_ENUM is generated if usage is not
+// GL.STREAM_DRAW, GL.STREAM_READ, GL.STREAM_COPY, GL.STATIC_DRAW,
+// GL.STATIC_READ, GL.STATIC_COPY, GL.DYNAMIC_DRAW, GL.DYNAMIC_READ, or
+// GL.DYNAMIC_COPY. GL.INVALID_VALUE is generated if size is negative.
+// GL.INVALID_OPERATION is generated if the reserved buffer object name 0 is
+// bound to target. GL.OUT_OF_MEMORY is generated if the GL is unable to
+// create a data store with the specified size.
+func (gl *GL) BufferData(target glbase.Enum, size int, data interface{}, usage glbase.Enum) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ if data != nil {
+ size = int(data_v.Type().Size()) * data_v.Len()
+ }
+ C.gl4_1core_glBufferData(gl.funcs, C.GLenum(target), C.GLsizeiptr(size), data_ptr, C.GLenum(usage))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsBuffer.xml
+func (gl *GL) IsBuffer(buffer glbase.Buffer) bool {
+ glresult := C.gl4_1core_glIsBuffer(gl.funcs, C.GLuint(buffer))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// GenBuffers returns n buffer object names. There is no guarantee that
+// the names form a contiguous set of integers; however, it is guaranteed
+// that none of the returned names was in use immediately before the call to
+// GenBuffers.
+//
+// Buffer object names returned by a call to GenBuffers are not returned by
+// subsequent calls, unless they are first deleted with DeleteBuffers.
+//
+// No buffer objects are associated with the returned buffer object names
+// until they are first bound by calling BindBuffer.
+//
+// Error GL.INVALID_VALUE is generated if n is negative. GL.INVALID_OPERATION
+// is generated if GenBuffers is executed between the execution of Begin
+// and the corresponding execution of End.
+//
+// GenBuffers is available in GL version 1.5 or greater.
+func (gl *GL) GenBuffers(n int) []glbase.Buffer {
+ if n == 0 {
+ return nil
+ }
+ buffers := make([]glbase.Buffer, n)
+ C.gl4_1core_glGenBuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&buffers[0])))
+ return buffers
+}
+
+// DeleteBuffers deletes the buffer objects whose names are stored in the
+// buffers slice.
+//
+// After a buffer object is deleted, it has no contents, and its name is free
+// for reuse (for example by GenBuffers). If a buffer object that is
+// currently bound is deleted, the binding reverts to 0 (the absence of any
+// buffer object, which reverts to client memory usage).
+//
+// DeleteBuffers silently ignores 0's and names that do not correspond to
+// existing buffer objects.
+//
+// Error GL.INVALID_VALUE is generated if n is negative. GL.INVALID_OPERATION
+// is generated if DeleteBuffers is executed between the execution of Begin
+// and the corresponding execution of End.
+//
+// DeleteBuffers is available in GL version 1.5 or greater.
+func (gl *GL) DeleteBuffers(buffers []glbase.Buffer) {
+ n := len(buffers)
+ if n == 0 {
+ return
+ }
+ C.gl4_1core_glDeleteBuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&buffers[0])))
+}
+
+// BindBuffer creates or puts in use a named buffer object.
+// Calling BindBuffer with target set to GL.ARRAY_BUFFER,
+// GL.ELEMENT_ARRAY_BUFFER, GL.PIXEL_PACK_BUFFER or GL.PIXEL_UNPACK_BUFFER
+// and buffer set to the name of the new buffer object binds the buffer
+// object name to the target. When a buffer object is bound to a target, the
+// previous binding for that target is automatically broken.
+//
+// Buffer object names are unsigned integers. The value zero is reserved, but
+// there is no default buffer object for each buffer object target. Instead,
+// buffer set to zero effectively unbinds any buffer object previously bound,
+// and restores client memory usage for that buffer object target. Buffer
+// object names and the corresponding buffer object contents are local to the
+// shared display-list space (see XCreateContext) of the current GL rendering
+// context; two rendering contexts share buffer object names only if they
+// also share display lists.
+//
+// GenBuffers may be called to generate a set of new buffer object names.
+//
+// The state of a buffer object immediately after it is first bound is an
+// unmapped zero-sized memory buffer with GL.READ_WRITE access and
+// GL.STATIC_DRAW usage.
+//
+// While a non-zero buffer object name is bound, GL operations on the target
+// to which it is bound affect the bound buffer object, and queries of the
+// target to which it is bound return state from the bound buffer object.
+// While buffer object name zero is bound, as in the initial state, attempts
+// to modify or query state on the target to which it is bound generates an
+// GL.INVALID_OPERATION error.
+//
+// When vertex array pointer state is changed, for example by a call to
+// NormalPointer, the current buffer object binding (GL.ARRAY_BUFFER_BINDING)
+// is copied into the corresponding client state for the vertex array type
+// being changed, for example GL.NORMAL_ARRAY_BUFFER_BINDING. While a
+// non-zero buffer object is bound to the GL.ARRAY_BUFFER target, the vertex
+// array pointer parameter that is traditionally interpreted as a pointer to
+// client-side memory is instead interpreted as an offset within the buffer
+// object measured in basic machine units.
+//
+// While a non-zero buffer object is bound to the GL.ELEMENT_ARRAY_BUFFER
+// target, the indices parameter of DrawElements, DrawRangeElements, or
+// MultiDrawElements that is traditionally interpreted as a pointer to
+// client-side memory is instead interpreted as an offset within the buffer
+// object measured in basic machine units.
+//
+// While a non-zero buffer object is bound to the GL.PIXEL_PACK_BUFFER
+// target, the following commands are affected: GetCompressedTexImage,
+// GetConvolutionFilter, GetHistogram, GetMinmax, GetPixelMap,
+// GetPolygonStipple, GetSeparableFilter, GetTexImage, and ReadPixels. The
+// pointer parameter that is traditionally interpreted as a pointer to
+// client-side memory where the pixels are to be packed is instead
+// interpreted as an offset within the buffer object measured in basic
+// machine units.
+//
+// While a non-zero buffer object is bound to the GL.PIXEL_UNPACK_BUFFER
+// target, the following commands are affected: Bitmap, ColorSubTable,
+// ColorTable, CompressedTexImage1D, CompressedTexImage2D,
+// CompressedTexImage3D, CompressedTexSubImage1D, CompressedTexSubImage2D,
+// CompressedTexSubImage3D, ConvolutionFilter1D, ConvolutionFilter2D,
+// DrawPixels, PixelMap, PolygonStipple, SeparableFilter2D, TexImage1D,
+// TexImage2D, TexImage3D, TexSubImage1D, TexSubImage2D, and TexSubImage3D.
+// The pointer parameter that is traditionally interpreted as a pointer to
+// client-side memory from which the pixels are to be unpacked is instead
+// interpreted as an offset within the buffer object measured in basic
+// machine units.
+//
+// A buffer object binding created with BindBuffer remains active until a
+// different buffer object name is bound to the same target, or until the
+// bound buffer object is deleted with DeleteBuffers.
+//
+// Once created, a named buffer object may be re-bound to any target as often
+// as needed. However, the GL implementation may make choices about how to
+// optimize the storage of a buffer object based on its initial binding
+// target.
+//
+// Error GL.INVALID_ENUM is generated if target is not one of the allowable
+// values. GL.INVALID_OPERATION is generated if BindBuffer is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// BindBuffer is available in GL version 1.5 or greater.
+func (gl *GL) BindBuffer(target glbase.Enum, buffer glbase.Buffer) {
+ C.gl4_1core_glBindBuffer(gl.funcs, C.GLenum(target), C.GLuint(buffer))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetQueryObjectuiv.xml
+func (gl *GL) GetQueryObjectuiv(id uint32, pname glbase.Enum, params []uint32) {
+ C.gl4_1core_glGetQueryObjectuiv(gl.funcs, C.GLuint(id), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetQueryObjectiv.xml
+func (gl *GL) GetQueryObjectiv(id uint32, pname glbase.Enum, params []int32) {
+ C.gl4_1core_glGetQueryObjectiv(gl.funcs, C.GLuint(id), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetQueryiv.xml
+func (gl *GL) GetQueryiv(target, pname glbase.Enum, params []int32) {
+ C.gl4_1core_glGetQueryiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEndQuery.xml
+func (gl *GL) EndQuery(target glbase.Enum) {
+ C.gl4_1core_glEndQuery(gl.funcs, C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBeginQuery.xml
+func (gl *GL) BeginQuery(target glbase.Enum, id uint32) {
+ C.gl4_1core_glBeginQuery(gl.funcs, C.GLenum(target), C.GLuint(id))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsQuery.xml
+func (gl *GL) IsQuery(id uint32) bool {
+ glresult := C.gl4_1core_glIsQuery(gl.funcs, C.GLuint(id))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDeleteQueries.xml
+func (gl *GL) DeleteQueries(n int, ids []uint32) {
+ C.gl4_1core_glDeleteQueries(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&ids[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGenQueries.xml
+func (gl *GL) GenQueries(n int, ids []uint32) {
+ C.gl4_1core_glGenQueries(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&ids[0])))
+}
+
+// VertexAttribPointer specifies the location and data format of the array
+// of generic vertex attributes at index to use when rendering. size
+// specifies the number of components per attribute and must be 1, 2, 3, or
+// 4. type specifies the data type of each component, and stride specifies
+// the byte stride from one attribute to the next, allowing vertices and
+// attributes to be packed into a single array or stored in separate arrays.
+// normalized indicates whether the values stored in an integer format are
+// to be mapped to the range [-1,1] (for signed values) or [0,1]
+// (for unsigned values) when they are accessed and converted to floating
+// point; otherwise, values will be converted to floats directly without
+// normalization. offset is a byte offset into the buffer object's data
+// store, which must be bound to the GL.ARRAY_BUFFER target with BindBuffer.
+//
+// The buffer object binding (GL.ARRAY_BUFFER_BINDING) is saved as
+// generic vertex attribute array client-side state
+// (GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING) for the provided index.
+//
+// To enable and disable a generic vertex attribute array, call
+// EnableVertexAttribArray and DisableVertexAttribArray with index. If
+// enabled, the generic vertex attribute array is used when DrawArrays or
+// DrawElements is called. Each generic vertex attribute array is initially
+// disabled.
+//
+// VertexAttribPointer is typically implemented on the client side.
+//
+// Error GL.INVALID_ENUM is generated if type is not an accepted value.
+// GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_VALUE is generated if size is not 1, 2,
+// 3, or 4. GL.INVALID_VALUE is generated if stride is negative.
+func (gl *GL) VertexAttribPointer(index glbase.Attrib, size int, gltype glbase.Enum, normalized bool, stride int, offset uintptr) {
+ offset_ptr := unsafe.Pointer(offset)
+ C.gl4_1core_glVertexAttribPointer(gl.funcs, C.GLuint(index), C.GLint(size), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), C.GLsizei(stride), offset_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glValidateProgram.xml
+func (gl *GL) ValidateProgram(program glbase.Program) {
+ C.gl4_1core_glValidateProgram(gl.funcs, C.GLuint(program))
+}
+
+// UniformMatrix4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix4fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(4*4) != 0 {
+ panic("invalid value length for UniformMatrix4fv")
+ }
+ count := len(value) / (4 * 4)
+ C.gl4_1core_glUniformMatrix4fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix3fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(3*3) != 0 {
+ panic("invalid value length for UniformMatrix3fv")
+ }
+ count := len(value) / (3 * 3)
+ C.gl4_1core_glUniformMatrix3fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix2fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(2*2) != 0 {
+ panic("invalid value length for UniformMatrix2fv")
+ }
+ count := len(value) / (2 * 2)
+ C.gl4_1core_glUniformMatrix2fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform4iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%4 != 0 {
+ panic("invalid value length for Uniform4iv")
+ }
+ count := len(value) / 4
+ C.gl4_1core_glUniform4iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform3iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform3iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%3 != 0 {
+ panic("invalid value length for Uniform3iv")
+ }
+ count := len(value) / 3
+ C.gl4_1core_glUniform3iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform2iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform2iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%2 != 0 {
+ panic("invalid value length for Uniform2iv")
+ }
+ count := len(value) / 2
+ C.gl4_1core_glUniform2iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform1iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform1iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ count := len(value)
+ C.gl4_1core_glUniform1iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%4 != 0 {
+ panic("invalid value length for Uniform4fv")
+ }
+ count := len(value) / 4
+ C.gl4_1core_glUniform4fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%3 != 0 {
+ panic("invalid value length for Uniform3fv")
+ }
+ count := len(value) / 3
+ C.gl4_1core_glUniform3fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%2 != 0 {
+ panic("invalid value length for Uniform2fv")
+ }
+ count := len(value) / 2
+ C.gl4_1core_glUniform2fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform1fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform1fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ count := len(value)
+ C.gl4_1core_glUniform1fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform4i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4i(location glbase.Uniform, v0, v1, v2, v3 int32) {
+ C.gl4_1core_glUniform4i(gl.funcs, C.GLint(location), C.GLint(v0), C.GLint(v1), C.GLint(v2), C.GLint(v3))
+}
+
+// Uniform3i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform3i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3i(location glbase.Uniform, v0, v1, v2 int32) {
+ C.gl4_1core_glUniform3i(gl.funcs, C.GLint(location), C.GLint(v0), C.GLint(v1), C.GLint(v2))
+}
+
+// Uniform2i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform2i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2i(location glbase.Uniform, v0, v1 int32) {
+ C.gl4_1core_glUniform2i(gl.funcs, C.GLint(location), C.GLint(v0), C.GLint(v1))
+}
+
+// Uniform1i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform1i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1i(location glbase.Uniform, v0 int32) {
+ C.gl4_1core_glUniform1i(gl.funcs, C.GLint(location), C.GLint(v0))
+}
+
+// Uniform4f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform4f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4f(location glbase.Uniform, v0, v1, v2, v3 float32) {
+ C.gl4_1core_glUniform4f(gl.funcs, C.GLint(location), C.GLfloat(v0), C.GLfloat(v1), C.GLfloat(v2), C.GLfloat(v3))
+}
+
+// Uniform3f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform3f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3f(location glbase.Uniform, v0, v1, v2 float32) {
+ C.gl4_1core_glUniform3f(gl.funcs, C.GLint(location), C.GLfloat(v0), C.GLfloat(v1), C.GLfloat(v2))
+}
+
+// Uniform2f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform2f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2f(location glbase.Uniform, v0, v1 float32) {
+ C.gl4_1core_glUniform2f(gl.funcs, C.GLint(location), C.GLfloat(v0), C.GLfloat(v1))
+}
+
+// Uniform1f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform1f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1f(location glbase.Uniform, v0 float32) {
+ C.gl4_1core_glUniform1f(gl.funcs, C.GLint(location), C.GLfloat(v0))
+}
+
+// UseProgram installs the program object specified by program as part of
+// current rendering state. One or more executables are created in a program
+// object by successfully attaching shader objects to it with AttachShader,
+// successfully compiling the shader objects with CompileShader, and
+// successfully linking the program object with LinkProgram.
+//
+// A program object will contain an executable that will run on the vertex
+// processor if it contains one or more shader objects of type
+// GL.VERTEX_SHADER that have been successfully compiled and linked.
+// Similarly, a program object will contain an executable that will run on
+// the fragment processor if it contains one or more shader objects of type
+// GL.FRAGMENT_SHADER that have been successfully compiled and linked.
+//
+// Successfully installing an executable on a programmable processor will
+// cause the corresponding fixed functionality of OpenGL to be disabled.
+// Specifically, if an executable is installed on the vertex processor, the
+// OpenGL fixed functionality will be disabled as follows.
+//
+// - The modelview matrix is not applied to vertex coordinates.
+//
+// - The projection matrix is not applied to vertex coordinates.
+//
+// - The texture matrices are not applied to texture coordinates.
+//
+// - Normals are not transformed to eye coordinates.
+//
+// - Normals are not rescaled or normalized.
+//
+// - Normalization of GL.AUTO_NORMAL evaluated normals is not performed.
+//
+// - Texture coordinates are not generated automatically.
+//
+// - Per-vertex lighting is not performed.
+//
+// - Color material computations are not performed.
+//
+// - Color index lighting is not performed.
+//
+// - This list also applies when setting the current raster position.
+//
+// The executable that is installed on the vertex processor is expected to
+// implement any or all of the desired functionality from the preceding list.
+// Similarly, if an executable is installed on the fragment processor, the
+// OpenGL fixed functionality will be disabled as follows.
+//
+// - Texture environment and texture functions are not applied.
+//
+// - Texture application is not applied.
+//
+// - Color sum is not applied.
+//
+// - Fog is not applied.
+//
+// Again, the fragment shader that is installed is expected to implement any
+// or all of the desired functionality from the preceding list.
+//
+// While a program object is in use, applications are free to modify attached
+// shader objects, compile attached shader objects, attach additional shader
+// objects, and detach or delete shader objects. None of these operations
+// will affect the executables that are part of the current state. However,
+// relinking the program object that is currently in use will install the
+// program object as part of the current rendering state if the link
+// operation was successful (see LinkProgram). If the program object
+// currently in use is relinked unsuccessfully, its link status will be set
+// to GL.FALSE, but the executables and associated state will remain part of
+// the current state until a subsequent call to UseProgram removes it from
+// use. After it is removed from use, it cannot be made part of current state
+// until it has been successfully relinked.
+//
+// If program contains shader objects of type GL.VERTEX_SHADER but it does
+// not contain shader objects of type GL.FRAGMENT_SHADER, an executable will
+// be installed on the vertex processor, but fixed functionality will be used
+// for fragment processing. Similarly, if program contains shader objects of
+// type GL.FRAGMENT_SHADER but it does not contain shader objects of type
+// GL.VERTEX_SHADER, an executable will be installed on the fragment
+// processor, but fixed functionality will be used for vertex processing. If
+// program is 0, the programmable processors will be disabled, and fixed
+// functionality will be used for both vertex and fragment processing.
+//
+// While a program object is in use, the state that controls the disabled
+// fixed functionality may also be updated using the normal OpenGL calls.
+//
+// Like display lists and texture objects, the name space for program objects
+// may be shared across a set of contexts, as long as the server sides of the
+// contexts share the same address space. If the name space is shared across
+// contexts, any attached objects and the data associated with those attached
+// objects are shared as well.
+//
+// Applications are responsible for providing the synchronization across API
+// calls when objects are accessed from different execution threads.
+//
+// Error GL.INVALID_VALUE is generated if program is neither 0 nor a value
+// generated by OpenGL. GL.INVALID_OPERATION is generated if program is not
+// a program object. GL.INVALID_OPERATION is generated if program could not
+// be made part of current state. GL.INVALID_OPERATION is generated if
+// UseProgram is executed between the execution of Begin and the
+// corresponding execution of End.
+//
+// UseProgram is available in GL version 2.0 or greater.
+func (gl *GL) UseProgram(program glbase.Program) {
+ C.gl4_1core_glUseProgram(gl.funcs, C.GLuint(program))
+}
+
+// ShaderSource sets the source code in shader to the provided source code. Any source
+// code previously stored in the shader object is completely replaced.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader is not a shader
+// object. GL.INVALID_VALUE is generated if count is less than 0.
+// GL.INVALID_OPERATION is generated if ShaderSource is executed between the
+// execution of Begin and the corresponding execution of End.
+//
+// ShaderSource is available in GL version 2.0 or greater.
+func (gl *GL) ShaderSource(shader glbase.Shader, source ...string) {
+ count := len(source)
+ length := make([]int32, count)
+ source_c := make([]unsafe.Pointer, count)
+ for i, src := range source {
+ length[i] = int32(len(src))
+ if len(src) > 0 {
+ source_c[i] = *(*unsafe.Pointer)(unsafe.Pointer(&src))
+ } else {
+ source_c[i] = unsafe.Pointer(uintptr(0))
+ }
+ }
+ C.gl4_1core_glShaderSource(gl.funcs, C.GLuint(shader), C.GLsizei(count), (**C.GLchar)(unsafe.Pointer(&source_c[0])), (*C.GLint)(unsafe.Pointer(&length[0])))
+}
+
+// LinkProgram links the program object specified by program. If any shader
+// objects of type GL.VERTEX_SHADER are attached to program, they will be
+// used to create an executable that will run on the programmable vertex
+// processor. If any shader objects of type GL.FRAGMENT_SHADER are attached
+// to program, they will be used to create an executable that will run on the
+// programmable fragment processor.
+//
+// The status of the link operation will be stored as part of the program
+// object's state. This value will be set to GL.TRUE if the program object
+// was linked without errors and is ready for use, and GL.FALSE otherwise. It
+// can be queried by calling GetProgramiv with arguments program and
+// GL.LINK_STATUS.
+//
+// As a result of a successful link operation, all active user-defined
+// uniform variables belonging to program will be initialized to 0, and each
+// of the program object's active uniform variables will be assigned a
+// location that can be queried by calling GetUniformLocation. Also, any
+// active user-defined attribute variables that have not been bound to a
+// generic vertex attribute index will be bound to one at this time.
+//
+// Linking of a program object can fail for a number of reasons as specified
+// in the OpenGL Shading Language Specification. The following lists some of
+// the conditions that will cause a link error.
+//
+// - The number of active attribute variables supported by the
+// implementation has been exceeded.
+//
+// - The storage limit for uniform variables has been exceeded.
+//
+// - The number of active uniform variables supported by the implementation
+// has been exceeded.
+//
+// - The main function is missing for the vertex shader or the fragment
+// shader.
+//
+// - A varying variable actually used in the fragment shader is not
+// declared in the same way (or is not declared at all) in the vertex
+// shader.
+//
+// - A reference to a function or variable name is unresolved.
+//
+// - A shared global is declared with two different types or two different
+// initial values.
+//
+// - One or more of the attached shader objects has not been successfully
+// compiled.
+//
+// - Binding a generic attribute matrix caused some rows of the matrix to
+// fall outside the allowed maximum of GL.MAX_VERTEX_ATTRIBS.
+//
+// - Not enough contiguous vertex attribute slots could be found to bind
+// attribute matrices.
+//
+// When a program object has been successfully linked, the program object can
+// be made part of current state by calling UseProgram. Whether or not the
+// link operation was successful, the program object's information log will
+// be overwritten. The information log can be retrieved by calling
+// GetProgramInfoLog.
+//
+// LinkProgram will also install the generated executables as part of the
+// current rendering state if the link operation was successful and the
+// specified program object is already currently in use as a result of a
+// previous call to UseProgram. If the program object currently in use is
+// relinked unsuccessfully, its link status will be set to GL.FALSE , but the
+// executables and associated state will remain part of the current state
+// until a subsequent call to UseProgram removes it from use. After it is
+// removed from use, it cannot be made part of current state until it has
+// been successfully relinked.
+//
+// If program contains shader objects of type GL.VERTEX_SHADER but does not
+// contain shader objects of type GL.FRAGMENT_SHADER, the vertex shader will
+// be linked against the implicit interface for fixed functionality fragment
+// processing. Similarly, if program contains shader objects of type
+// GL.FRAGMENT_SHADER but it does not contain shader objects of type
+// GL.VERTEX_SHADER, the fragment shader will be linked against the implicit
+// interface for fixed functionality vertex processing.
+//
+// The program object's information log is updated and the program is
+// generated at the time of the link operation. After the link operation,
+// applications are free to modify attached shader objects, compile attached
+// shader objects, detach shader objects, delete shader objects, and attach
+// additional shader objects. None of these operations affects the
+// information log or the program that is part of the program object.
+//
+// If the link operation is unsuccessful, any information about a previous
+// link operation on program is lost (a failed link does not restore the
+// old state of program). Certain information can still be retrieved
+// from program even after an unsuccessful link operation. See for instance
+// GetActiveAttrib and GetActiveUniform.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program
+// object. GL.INVALID_OPERATION is generated if LinkProgram is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// LinkProgram is available in GL version 2.0 or greater.
+func (gl *GL) LinkProgram(program glbase.Program) {
+ C.gl4_1core_glLinkProgram(gl.funcs, C.GLuint(program))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsShader.xml
+func (gl *GL) IsShader(shader glbase.Shader) bool {
+ glresult := C.gl4_1core_glIsShader(gl.funcs, C.GLuint(shader))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsProgram.xml
+func (gl *GL) IsProgram(program glbase.Program) bool {
+ glresult := C.gl4_1core_glIsProgram(gl.funcs, C.GLuint(program))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// GetVertexAttribiv returns in params the value of a generic vertex attribute
+// parameter. The generic vertex attribute to be queried is specified by
+// index, and the parameter to be queried is specified by pname.
+//
+// The accepted parameter names are as follows:
+//
+// GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING
+// params returns a single value, the name of the buffer object
+// currently bound to the binding point corresponding to generic vertex
+// attribute array index. If no buffer object is bound, 0 is returned.
+// The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_ENABLED
+// params returns a single value that is non-zero (true) if the vertex
+// attribute array for index is enabled and 0 (false) if it is
+// disabled. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_SIZE
+// params returns a single value, the size of the vertex attribute
+// array for index. The size is the number of values for each element
+// of the vertex attribute array, and it will be 1, 2, 3, or 4. The
+// initial value is 4.
+//
+// GL.VERTEX_ATTRIB_ARRAY_STRIDE
+// params returns a single value, the array stride for (number of bytes
+// between successive elements in) the vertex attribute array for
+// index. A value of 0 indicates that the array elements are stored
+// sequentially in memory. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_TYPE
+// params returns a single value, a symbolic constant indicating the
+// array type for the vertex attribute array for index. Possible values
+// are GL.BYTE, GL.UNSIGNED_BYTE, GL.SHORT, GL.UNSIGNED_SHORT, GL.INT,
+// GL.UNSIGNED_INT, GL.FLOAT, and GL.DOUBLE. The initial value is
+// GL.FLOAT.
+//
+// GL.VERTEX_ATTRIB_ARRAY_NORMALIZED
+// params returns a single value that is non-zero (true) if fixed-point
+// data types for the vertex attribute array indicated by index are
+// normalized when they are converted to floating point, and 0 (false)
+// otherwise. The initial value is 0.
+//
+// GL.CURRENT_VERTEX_ATTRIB
+// params returns four values that represent the current value for the
+// generic vertex attribute specified by index. Generic vertex
+// attribute 0 is unique in that it has no current state, so an error
+// will be generated if index is 0. The initial value for all other
+// generic vertex attributes is (0,0,0,1).
+//
+// All of the parameters except GL.CURRENT_VERTEX_ATTRIB represent
+// client-side state.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_ENUM is generated if pname is not an
+// accepted value. GL.INVALID_OPERATION is generated if index is 0 and pname
+// is GL.CURRENT_VERTEX_ATTRIB.
+//
+// GetVertexAttribiv is available in GL version 2.0 or greater.
+func (gl *GL) GetVertexAttribiv(index glbase.Attrib, pname glbase.Enum, params []int32) {
+ var params_c [4]int32
+ C.gl4_1core_glGetVertexAttribiv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetVertexAttribfv returns in params the value of a generic vertex attribute
+// parameter. The generic vertex attribute to be queried is specified by
+// index, and the parameter to be queried is specified by pname.
+//
+// The accepted parameter names are as follows:
+//
+// GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING
+// params returns a single value, the name of the buffer object
+// currently bound to the binding point corresponding to generic vertex
+// attribute array index. If no buffer object is bound, 0 is returned.
+// The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_ENABLED
+// params returns a single value that is non-zero (true) if the vertex
+// attribute array for index is enabled and 0 (false) if it is
+// disabled. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_SIZE
+// params returns a single value, the size of the vertex attribute
+// array for index. The size is the number of values for each element
+// of the vertex attribute array, and it will be 1, 2, 3, or 4. The
+// initial value is 4.
+//
+// GL.VERTEX_ATTRIB_ARRAY_STRIDE
+// params returns a single value, the array stride for (number of bytes
+// between successive elements in) the vertex attribute array for
+// index. A value of 0 indicates that the array elements are stored
+// sequentially in memory. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_TYPE
+// params returns a single value, a symbolic constant indicating the
+// array type for the vertex attribute array for index. Possible values
+// are GL.BYTE, GL.UNSIGNED_BYTE, GL.SHORT, GL.UNSIGNED_SHORT, GL.INT,
+// GL.UNSIGNED_INT, GL.FLOAT, and GL.DOUBLE. The initial value is
+// GL.FLOAT.
+//
+// GL.VERTEX_ATTRIB_ARRAY_NORMALIZED
+// params returns a single value that is non-zero (true) if fixed-point
+// data types for the vertex attribute array indicated by index are
+// normalized when they are converted to floating point, and 0 (false)
+// otherwise. The initial value is 0.
+//
+// GL.CURRENT_VERTEX_ATTRIB
+// params returns four values that represent the current value for the
+// generic vertex attribute specified by index. Generic vertex
+// attribute 0 is unique in that it has no current state, so an error
+// will be generated if index is 0. The initial value for all other
+// generic vertex attributes is (0,0,0,1).
+//
+// All of the parameters except GL.CURRENT_VERTEX_ATTRIB represent
+// client-side state.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_ENUM is generated if pname is not an
+// accepted value. GL.INVALID_OPERATION is generated if index is 0 and pname
+// is GL.CURRENT_VERTEX_ATTRIB.
+//
+// GetVertexAttribfv is available in GL version 2.0 or greater.
+func (gl *GL) GetVertexAttribfv(index glbase.Attrib, pname glbase.Enum, params []float32) {
+ var params_c [4]float32
+ C.gl4_1core_glGetVertexAttribfv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetVertexAttribdv returns in params the value of a generic vertex attribute
+// parameter. The generic vertex attribute to be queried is specified by
+// index, and the parameter to be queried is specified by pname.
+//
+// The accepted parameter names are as follows:
+//
+// GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING
+// params returns a single value, the name of the buffer object
+// currently bound to the binding point corresponding to generic vertex
+// attribute array index. If no buffer object is bound, 0 is returned.
+// The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_ENABLED
+// params returns a single value that is non-zero (true) if the vertex
+// attribute array for index is enabled and 0 (false) if it is
+// disabled. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_SIZE
+// params returns a single value, the size of the vertex attribute
+// array for index. The size is the number of values for each element
+// of the vertex attribute array, and it will be 1, 2, 3, or 4. The
+// initial value is 4.
+//
+// GL.VERTEX_ATTRIB_ARRAY_STRIDE
+// params returns a single value, the array stride for (number of bytes
+// between successive elements in) the vertex attribute array for
+// index. A value of 0 indicates that the array elements are stored
+// sequentially in memory. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_TYPE
+// params returns a single value, a symbolic constant indicating the
+// array type for the vertex attribute array for index. Possible values
+// are GL.BYTE, GL.UNSIGNED_BYTE, GL.SHORT, GL.UNSIGNED_SHORT, GL.INT,
+// GL.UNSIGNED_INT, GL.FLOAT, and GL.DOUBLE. The initial value is
+// GL.FLOAT.
+//
+// GL.VERTEX_ATTRIB_ARRAY_NORMALIZED
+// params returns a single value that is non-zero (true) if fixed-point
+// data types for the vertex attribute array indicated by index are
+// normalized when they are converted to floating point, and 0 (false)
+// otherwise. The initial value is 0.
+//
+// GL.CURRENT_VERTEX_ATTRIB
+// params returns four values that represent the current value for the
+// generic vertex attribute specified by index. Generic vertex
+// attribute 0 is unique in that it has no current state, so an error
+// will be generated if index is 0. The initial value for all other
+// generic vertex attributes is (0,0,0,1).
+//
+// All of the parameters except GL.CURRENT_VERTEX_ATTRIB represent
+// client-side state.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_ENUM is generated if pname is not an
+// accepted value. GL.INVALID_OPERATION is generated if index is 0 and pname
+// is GL.CURRENT_VERTEX_ATTRIB.
+//
+// GetVertexAttribdv is available in GL version 2.0 or greater.
+func (gl *GL) GetVertexAttribdv(index glbase.Attrib, pname glbase.Enum, params []float64) {
+ var params_c [4]float64
+ C.gl4_1core_glGetVertexAttribdv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetUniformiv returns in params the value of the specified uniform
+// variable. The type of the uniform variable specified by location
+// determines the number of values returned. If the uniform variable is
+// defined in the shader as a boolean, int, or float, a single value will be
+// returned. If it is defined as a vec2, ivec2, or bvec2, two values will be
+// returned. If it is defined as a vec3, ivec3, or bvec3, three values will
+// be returned, and so on. To query values stored in uniform variables
+// declared as arrays, call GetUniformiv for each element of the array. To
+// query values stored in uniform variables declared as structures, call
+// GetUniformiv for each field in the structure. The values for uniform
+// variables declared as a matrix will be returned in column major order.
+//
+// The locations assigned to uniform variables are not known until the
+// program object is linked. After linking has occurred, the command
+// GetUniformLocation can be used to obtain the location of a uniform
+// variable. This location value can then be passed to GetUniformiv in order
+// to query the current value of the uniform variable. After a program object
+// has been linked successfully, the index values for uniform variables
+// remain fixed until the next link command occurs. The uniform variable
+// values can only be queried after a link if the link was successful.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program
+// object. GL.INVALID_OPERATION is generated if program has not been
+// successfully linked. GL.INVALID_OPERATION is generated if location does
+// not correspond to a valid uniform variable location for the specified
+// program object. GL.INVALID_OPERATION is generated if GetUniformiv is
+// executed between the execution of Begin and the corresponding execution of
+// End.
+//
+// GetUniformiv is available in GL version 2.0 or greater.
+func (gl *GL) GetUniformiv(program glbase.Program, location glbase.Uniform, params []int32) {
+ var params_c [4]int32
+ C.gl4_1core_glGetUniformiv(gl.funcs, C.GLuint(program), C.GLint(location), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetUniformfv returns in params the value of the specified uniform
+// variable. The type of the uniform variable specified by location
+// determines the number of values returned. If the uniform variable is
+// defined in the shader as a boolean, int, or float, a single value will be
+// returned. If it is defined as a vec2, ivec2, or bvec2, two values will be
+// returned. If it is defined as a vec3, ivec3, or bvec3, three values will
+// be returned, and so on. To query values stored in uniform variables
+// declared as arrays, call GetUniformfv for each element of the array. To
+// query values stored in uniform variables declared as structures, call
+// GetUniformfv for each field in the structure. The values for uniform
+// variables declared as a matrix will be returned in column major order.
+//
+// The locations assigned to uniform variables are not known until the
+// program object is linked. After linking has occurred, the command
+// GetUniformLocation can be used to obtain the location of a uniform
+// variable. This location value can then be passed to GetUniformfv in order
+// to query the current value of the uniform variable. After a program object
+// has been linked successfully, the index values for uniform variables
+// remain fixed until the next link command occurs. The uniform variable
+// values can only be queried after a link if the link was successful.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program
+// object. GL.INVALID_OPERATION is generated if program has not been
+// successfully linked. GL.INVALID_OPERATION is generated if location does
+// not correspond to a valid uniform variable location for the specified
+// program object. GL.INVALID_OPERATION is generated if GetUniformfv is
+// executed between the execution of Begin and the corresponding execution of
+// End.
+//
+// GetUniformfv is available in GL version 2.0 or greater.
+func (gl *GL) GetUniformfv(program glbase.Program, location glbase.Uniform, params []float32) {
+ var params_c [4]float32
+ C.gl4_1core_glGetUniformfv(gl.funcs, C.GLuint(program), C.GLint(location), (*C.GLfloat)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetUniformLocation returns an integer that represents the location of a
+// specific uniform variable within a program object. name must be an active
+// uniform variable name in program that is not a structure, an array of
+// structures, or a subcomponent of a vector or a matrix. This function
+// returns -1 if name does not correspond to an active uniform variable in
+// program or if name starts with the reserved prefix "gl_".
+//
+// Uniform variables that are structures or arrays of structures may be
+// queried by calling GetUniformLocation for each field within the
+// structure. The array element operator "[]" and the structure field
+// operator "." may be used in name in order to select elements within an
+// array or fields within a structure. The result of using these operators is
+// not allowed to be another structure, an array of structures, or a
+// subcomponent of a vector or a matrix. Except if the last part of name
+// indicates a uniform variable array, the location of the first element of
+// an array can be retrieved by using the name of the array, or by using the
+// name appended by "[0]".
+//
+// The actual locations assigned to uniform variables are not known until the
+// program object is linked successfully. After linking has occurred, the
+// command GetUniformLocation can be used to obtain the location of a
+// uniform variable. This location value can then be passed to Uniform to
+// set the value of the uniform variable or to GetUniform in order to query
+// the current value of the uniform variable. After a program object has been
+// linked successfully, the index values for uniform variables remain fixed
+// until the next link command occurs. Uniform variable locations and values
+// can only be queried after a link if the link was successful.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program object.
+// GL.INVALID_OPERATION is generated if program has not been successfully
+// linked. GL.INVALID_OPERATION is generated if GetUniformLocation is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// GetUniformLocation is available in GL version 2.0 or greater.
+func (gl *GL) GetUniformLocation(program glbase.Program, name string) glbase.Uniform {
+ name_cstr := C.CString(name)
+ glresult := C.gl4_1core_glGetUniformLocation(gl.funcs, C.GLuint(program), (*C.GLchar)(name_cstr))
+ C.free(unsafe.Pointer(name_cstr))
+ return glbase.Uniform(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetShaderSource.xml
+func (gl *GL) GetShaderSource(shader glbase.Shader, bufSize int32, length []int32, source []byte) {
+ C.gl4_1core_glGetShaderSource(gl.funcs, C.GLuint(shader), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&source[0])))
+}
+
+// GetShaderInfoLog returns the information log for the specified shader
+// object. The information log for a shader object is modified when the
+// shader is compiled.
+//
+// The information log for a shader object is a string that may contain
+// diagnostic messages, warning messages, and other information about the
+// last compile operation. When a shader object is created, its information
+// log will be a string of length 0, and the size of the current log can be
+// obtained by calling GetShaderiv with the value GL.INFO_LOG_LENGTH.
+//
+// The information log for a shader object is the OpenGL implementer's
+// primary mechanism for conveying information about the compilation process.
+// Therefore, the information log can be helpful to application developers
+// during the development process, even when compilation is successful.
+// Application developers should not expect different OpenGL implementations
+// to produce identical information logs.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader is not a shader
+// object. GL.INVALID_VALUE is generated if maxLength is less than 0.
+// GL.INVALID_OPERATION is generated if GetShaderInfoLog is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// GetShaderInfoLog is available in GL version 2.0 or greater.
+func (gl *GL) GetShaderInfoLog(shader glbase.Shader) []byte {
+ var params [1]int32
+ var length int32
+ gl.GetShaderiv(shader, INFO_LOG_LENGTH, params[:])
+ bufSize := params[0]
+ infoLog := make([]byte, int(bufSize))
+ C.gl4_1core_glGetShaderInfoLog(gl.funcs, C.GLuint(shader), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length)), (*C.GLchar)(unsafe.Pointer(&infoLog[0])))
+ return infoLog
+}
+
+// GetShaderiv GetShader returns in params the value of a parameter for a specific
+// shader object. The following parameters are defined:
+//
+// GL.SHADER_TYPE
+// params returns GL.VERTEX_SHADER if shader is a vertex shader object,
+// and GL.FRAGMENT_SHADER if shader is a fragment shader object.
+//
+// GL.DELETE_STATUS
+// params returns GL.TRUE if shader is currently flagged for deletion,
+// and GL.FALSE otherwise.
+//
+// GL.COMPILE_STATUS
+// params returns GL.TRUE if the last compile operation on shader was
+// successful, and GL.FALSE otherwise.
+//
+// GL.INFO_LOG_LENGTH
+// params returns the number of characters in the information log for
+// shader including the null termination character (the size of the
+// character buffer required to store the information log). If shader has
+// no information log, a value of 0 is returned.
+//
+// GL.SHADER_SOURCE_LENGTH
+// params returns the length of the concatenation of the source strings
+// that make up the shader source for the shader, including the null
+// termination character. (the size of the character buffer
+// required to store the shader source). If no source code exists, 0 is
+// returned.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader does not refer to a
+// shader object. GL.INVALID_ENUM is generated if pname is not an accepted
+// value. GL.INVALID_OPERATION is generated if GetShader is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// GetShaderiv is available in GL version 2.0 or greater.
+func (gl *GL) GetShaderiv(shader glbase.Shader, pname glbase.Enum, params []int32) {
+ var params_c [4]int32
+ C.gl4_1core_glGetShaderiv(gl.funcs, C.GLuint(shader), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetProgramInfoLog returns the information log for the specified program
+// object. The information log for a program object is modified when the
+// program object is linked or validated.
+//
+// The information log for a program object is either an empty string, or a
+// string containing information about the last link operation, or a string
+// containing information about the last validation operation. It may contain
+// diagnostic messages, warning messages, and other information. When a
+// program object is created, its information log will be a string of length
+// 0, and the size of the current log can be obtained by calling GetProgramiv
+// with the value GL.INFO_LOG_LENGTH.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated
+// by OpenGL. GL.INVALID_OPERATION is generated if program is not a
+// program object.
+func (gl *GL) GetProgramInfoLog(program glbase.Program) []byte {
+ var params [1]int32
+ var length int32
+ gl.GetProgramiv(program, INFO_LOG_LENGTH, params[:])
+ bufSize := params[0]
+ infoLog := make([]byte, int(bufSize))
+ C.gl4_1core_glGetProgramInfoLog(gl.funcs, C.GLuint(program), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length)), (*C.GLchar)(unsafe.Pointer(&infoLog[0])))
+ return infoLog
+}
+
+// GetProgramiv returns in params the value of a parameter for a specific
+// program object. The following parameters are defined:
+//
+// GL.DELETE_STATUS
+// params returns GL.TRUE if program is currently flagged for deletion,
+// and GL.FALSE otherwise.
+//
+// GL.LINK_STATUS
+// params returns GL.TRUE if the last link operation on program was
+// successful, and GL.FALSE otherwise.
+//
+// GL.VALIDATE_STATUS
+// params returns GL.TRUE or if the last validation operation on
+// program was successful, and GL.FALSE otherwise.
+//
+// GL.INFO_LOG_LENGTH
+// params returns the number of characters in the information log for
+// program including the null termination character (the size of
+// the character buffer required to store the information log). If
+// program has no information log, a value of 0 is returned.
+//
+// GL.ATTACHED_SHADERS
+// params returns the number of shader objects attached to program.
+//
+// GL.ACTIVE_ATTRIBUTES
+// params returns the number of active attribute variables for program.
+//
+// GL.ACTIVE_ATTRIBUTE_MAX_LENGTH
+// params returns the length of the longest active attribute name for
+// program, including the null termination character (the size of
+// the character buffer required to store the longest attribute name).
+// If no active attributes exist, 0 is returned.
+//
+// GL.ACTIVE_UNIFORMS
+// params returns the number of active uniform variables for program.
+//
+// GL.ACTIVE_UNIFORM_MAX_LENGTH
+// params returns the length of the longest active uniform variable
+// name for program, including the null termination character (i.e.,
+// the size of the character buffer required to store the longest
+// uniform variable name). If no active uniform variables exist, 0 is
+// returned.
+//
+// GL.TRANSFORM_FEEDBACK_BUFFER_MODE
+// params returns a symbolic constant indicating the buffer mode used
+// when transform feedback is active. This may be GL.SEPARATE_ATTRIBS
+// or GL.INTERLEAVED_ATTRIBS.
+//
+// GL.TRANSFORM_FEEDBACK_VARYINGS
+// params returns the number of varying variables to capture in transform
+// feedback mode for the program.
+//
+// GL.TRANSFORM_FEEDBACK_VARYING_MAX_LENGTH
+// params returns the length of the longest variable name to be used for
+// transform feedback, including the null-terminator.
+//
+// GL.GEOMETRY_VERTICES_OUT
+// params returns the maximum number of vertices that the geometry shader in
+// program will output.
+//
+// GL.GEOMETRY_INPUT_TYPE
+// params returns a symbolic constant indicating the primitive type accepted
+// as input to the geometry shader contained in program.
+//
+// GL.GEOMETRY_OUTPUT_TYPE
+// params returns a symbolic constant indicating the primitive type that will
+// be output by the geometry shader contained in program.
+//
+// GL.ACTIVE_UNIFORM_BLOCKS and GL.ACTIVE_UNIFORM_BLOCK_MAX_NAME_LENGTH are
+// available only if the GL version 3.1 or greater.
+//
+// GL.GEOMETRY_VERTICES_OUT, GL.GEOMETRY_INPUT_TYPE and
+// GL.GEOMETRY_OUTPUT_TYPE are accepted only if the GL version is 3.2 or
+// greater.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program does not refer to a
+// program object. GL.INVALID_OPERATION is generated if pname is
+// GL.GEOMETRY_VERTICES_OUT, GL.GEOMETRY_INPUT_TYPE, or
+// GL.GEOMETRY_OUTPUT_TYPE, and program does not contain a geometry shader.
+// GL.INVALID_ENUM is generated if pname is not an accepted value.
+func (gl *GL) GetProgramiv(program glbase.Program, pname glbase.Enum, params []int32) {
+ var params_c [4]int32
+ C.gl4_1core_glGetProgramiv(gl.funcs, C.GLuint(program), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetAttribLocation queries the previously linked program object specified
+// by program for the attribute variable specified by name and returns the
+// index of the generic vertex attribute that is bound to that attribute
+// variable. If name is a matrix attribute variable, the index of the first
+// column of the matrix is returned. If the named attribute variable is not
+// an active attribute in the specified program object or if name starts with
+// the reserved prefix "gl_", a value of -1 is returned.
+//
+// The association between an attribute variable name and a generic attribute
+// index can be specified at any time by calling BindAttribLocation.
+// Attribute bindings do not go into effect until LinkProgram is called.
+// After a program object has been linked successfully, the index values for
+// attribute variables remain fixed until the next link command occurs. The
+// attribute values can only be queried after a link if the link was
+// successful. GetAttribLocation returns the binding that actually went
+// into effect the last time LinkProgram was called for the specified
+// program object. Attribute bindings that have been specified since the last
+// link operation are not returned by GetAttribLocation.
+//
+// Error GL_INVALID_OPERATION is generated if program is not a value
+// generated by OpenGL. GL_INVALID_OPERATION is generated if program is not
+// a program object. GL_INVALID_OPERATION is generated if program has not
+// been successfully linked. GL_INVALID_OPERATION is generated if
+// GetAttribLocation is executed between the execution of Begin and the
+// corresponding execution of End.
+//
+// GetAttribLocation is available in GL version 2.0 or greater.
+func (gl *GL) GetAttribLocation(program glbase.Program, name string) glbase.Attrib {
+ name_cstr := C.CString(name)
+ glresult := C.gl4_1core_glGetAttribLocation(gl.funcs, C.GLuint(program), (*C.GLchar)(name_cstr))
+ C.free(unsafe.Pointer(name_cstr))
+ return glbase.Attrib(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetAttachedShaders.xml
+func (gl *GL) GetAttachedShaders(program glbase.Program, maxCount int32, count []int, obj []uint32) {
+ C.gl4_1core_glGetAttachedShaders(gl.funcs, C.GLuint(program), C.GLsizei(maxCount), (*C.GLsizei)(unsafe.Pointer(&count[0])), (*C.GLuint)(unsafe.Pointer(&obj[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveUniform.xml
+func (gl *GL) GetActiveUniform(program glbase.Program, index uint32, bufSize int32, length []int32, size []int, gltype []glbase.Enum, name []byte) {
+ C.gl4_1core_glGetActiveUniform(gl.funcs, C.GLuint(program), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLint)(unsafe.Pointer(&size[0])), (*C.GLenum)(unsafe.Pointer(&gltype[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveAttrib.xml
+func (gl *GL) GetActiveAttrib(program glbase.Program, index glbase.Attrib, bufSize int32, length []int32, size []int, gltype []glbase.Enum, name []byte) {
+ C.gl4_1core_glGetActiveAttrib(gl.funcs, C.GLuint(program), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLint)(unsafe.Pointer(&size[0])), (*C.GLenum)(unsafe.Pointer(&gltype[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEnableVertexAttribArray.xml
+func (gl *GL) EnableVertexAttribArray(index glbase.Attrib) {
+ C.gl4_1core_glEnableVertexAttribArray(gl.funcs, C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDisableVertexAttribArray.xml
+func (gl *GL) DisableVertexAttribArray(index glbase.Attrib) {
+ C.gl4_1core_glDisableVertexAttribArray(gl.funcs, C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDetachShader.xml
+func (gl *GL) DetachShader(program glbase.Program, shader glbase.Shader) {
+ C.gl4_1core_glDetachShader(gl.funcs, C.GLuint(program), C.GLuint(shader))
+}
+
+// DeleteShader frees the memory and invalidates the name associated with
+// the shader object specified by shader. This command effectively undoes the
+// effects of a call to CreateShader.
+//
+// If a shader object to be deleted is attached to a program object, it will
+// be flagged for deletion, but it will not be deleted until it is no longer
+// attached to any program object, for any rendering context (it must
+// be detached from wherever it was attached before it will be deleted). A
+// value of 0 for shader will be silently ignored.
+//
+// To determine whether an object has been flagged for deletion, call
+// GetShader with arguments shader and GL.DELETE_STATUS.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL.
+//
+// DeleteShader is available in GL version 2.0 or greater.
+func (gl *GL) DeleteShader(shader glbase.Shader) {
+ C.gl4_1core_glDeleteShader(gl.funcs, C.GLuint(shader))
+}
+
+// DeleteProgram frees the memory and invalidates the name associated with
+// the program object specified by program. This command effectively undoes
+// the effects of a call to CreateProgram.
+//
+// If a program object is in use as part of current rendering state, it will
+// be flagged for deletion, but it will not be deleted until it is no longer
+// part of current state for any rendering context. If a program object to be
+// deleted has shader objects attached to it, those shader objects will be
+// automatically detached but not deleted unless they have already been
+// flagged for deletion by a previous call to DeleteShader. A value of 0
+// for program will be silently ignored.
+//
+// To determine whether a program object has been flagged for deletion, call
+// GetProgram with arguments program and GL.DELETE_STATUS.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL.
+//
+// DeleteProgram is available in GL version 2.0 or greater.
+func (gl *GL) DeleteProgram(program glbase.Program) {
+ C.gl4_1core_glDeleteProgram(gl.funcs, C.GLuint(program))
+}
+
+// CreateShader creates an empty shader object and returns a non-zero value
+// by which it can be referenced. A shader object is used to maintain the
+// source code strings that define a shader. shaderType indicates the type of
+// shader to be created.
+//
+// Two types of shaders are supported. A shader of type GL.VERTEX_SHADER is a
+// shader that is intended to run on the programmable vertex processor and
+// replace the fixed functionality vertex processing in OpenGL. A shader of
+// type GL.FRAGMENT_SHADER is a shader that is intended to run on the
+// programmable fragment processor and replace the fixed functionality
+// fragment processing in OpenGL.
+//
+// When created, a shader object's GL.SHADER_TYPE parameter is set to either
+// GL.VERTEX_SHADER or GL.FRAGMENT_SHADER, depending on the value of
+// shaderType.
+//
+// Like display lists and texture objects, the name space for shader objects
+// may be shared across a set of contexts, as long as the server sides of the
+// contexts share the same address space. If the name space is shared across
+// contexts, any attached objects and the data associated with those attached
+// objects are shared as well.
+//
+// This function returns 0 if an error occurs creating the shader object.
+//
+// Error GL.INVALID_ENUM is generated if shaderType is not an accepted value.
+// GL.INVALID_OPERATION is generated if CreateShader is executed between the
+// execution of Begin and the corresponding execution of End.
+//
+// CreateShader is available in GL version 2.0 or greater.
+func (gl *GL) CreateShader(gltype glbase.Enum) glbase.Shader {
+ glresult := C.gl4_1core_glCreateShader(gl.funcs, C.GLenum(gltype))
+ return glbase.Shader(glresult)
+}
+
+// CreateProgram creates an empty program object and returns a non-zero
+// value by which it can be referenced. A program object is an object to
+// which shader objects can be attached. This provides a mechanism to specify
+// the shader objects that will be linked to create a program. It also
+// provides a means for checking the compatibility of the shaders that will
+// be used to create a program (for instance, checking the compatibility
+// between a vertex shader and a fragment shader). When no longer needed as
+// part of a program object, shader objects can be detached.
+//
+// One or more executables are created in a program object by successfully
+// attaching shader objects to it with AttachShader, successfully compiling
+// the shader objects with CompileShader, and successfully linking the
+// program object with LinkProgram. These executables are made part of
+// current state when UseProgram is called. Program objects can be deleted
+// by calling DeleteProgram. The memory associated with the program object
+// will be deleted when it is no longer part of current rendering state for
+// any context.
+//
+// Like display lists and texture objects, the name space for program objects
+// may be shared across a set of contexts, as long as the server sides of the
+// contexts share the same address space. If the name space is shared across
+// contexts, any attached objects and the data associated with those attached
+// objects are shared as well.
+//
+// Applications are responsible for providing the synchronization across API
+// calls when objects are accessed from different execution threads.
+//
+// This function returns 0 if an error occurs creating the program object.
+//
+// Error GL.INVALID_OPERATION is generated if CreateProgram is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// CreateProgram is available in GL version 2.0 or greater.
+func (gl *GL) CreateProgram() glbase.Program {
+ glresult := C.gl4_1core_glCreateProgram(gl.funcs)
+ return glbase.Program(glresult)
+}
+
+// CompileShader compiles the source code strings that have been stored in
+// the shader object specified by shader.
+//
+// The compilation status will be stored as part of the shader object's
+// state. This value will be set to GL.TRUE if the shader was compiled without
+// errors and is ready for use, and GL.FALSE otherwise. It can be queried by
+// calling GetShaderiv with arguments shader and GL.COMPILE_STATUS.
+//
+// Compilation of a shader can fail for a number of reasons as specified by
+// the OpenGL Shading Language Specification. Whether or not the compilation
+// was successful, information about the compilation can be obtained from the
+// shader object's information log by calling GetShaderInfoLog.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader is not a shader
+// object. GL.INVALID_OPERATION is generated if CompileShader is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// CompileShader is available in GL version 2.0 or greater.
+func (gl *GL) CompileShader(shader glbase.Shader) {
+ C.gl4_1core_glCompileShader(gl.funcs, C.GLuint(shader))
+}
+
+// BindAttribLocation associates a user-defined attribute variable in the program
+// object specified by program with a generic vertex attribute index. The name
+// parameter specifies the name of the vertex shader attribute variable to
+// which index is to be bound. When program is made part of the current state,
+// values provided via the generic vertex attribute index will modify the
+// value of the user-defined attribute variable specified by name.
+//
+// If name refers to a matrix attribute variable, index refers to the first
+// column of the matrix. Other matrix columns are then automatically bound to
+// locations index+1 for a matrix of type mat2; index+1 and index+2 for a
+// matrix of type mat3; and index+1, index+2, and index+3 for a matrix of
+// type mat4.
+//
+// This command makes it possible for vertex shaders to use descriptive names
+// for attribute variables rather than generic variables that are numbered
+// from 0 to GL.MAX_VERTEX_ATTRIBS-1. The values sent to each generic
+// attribute index are part of current state, just like standard vertex
+// attributes such as color, normal, and vertex position. If a different
+// program object is made current by calling UseProgram, the generic vertex
+// attributes are tracked in such a way that the same values will be observed
+// by attributes in the new program object that are also bound to index.
+//
+// Attribute variable name-to-generic attribute index bindings for a program
+// object can be explicitly assigned at any time by calling
+// BindAttribLocation. Attribute bindings do not go into effect until
+// LinkProgram is called. After a program object has been linked
+// successfully, the index values for generic attributes remain fixed (and
+// their values can be queried) until the next link command occurs.
+//
+// Applications are not allowed to bind any of the standard OpenGL vertex
+// attributes using this command, as they are bound automatically when
+// needed. Any attribute binding that occurs after the program object has
+// been linked will not take effect until the next time the program object is
+// linked.
+//
+// If name was bound previously, that information is lost. Thus you cannot
+// bind one user-defined attribute variable to multiple indices, but you can
+// bind multiple user-defined attribute variables to the same index.
+//
+// Applications are allowed to bind more than one user-defined attribute
+// variable to the same generic vertex attribute index. This is called
+// aliasing, and it is allowed only if just one of the aliased attributes is
+// active in the executable program, or if no path through the shader
+// consumes more than one attribute of a set of attributes aliased to the
+// same location. The compiler and linker are allowed to assume that no
+// aliasing is done and are free to employ optimizations that work only in
+// the absence of aliasing. OpenGL implementations are not required to do
+// error checking to detect aliasing. Because there is no way to bind
+// standard attributes, it is not possible to alias generic attributes with
+// conventional ones (except for generic attribute 0).
+//
+// BindAttribLocation can be called before any vertex shader objects are
+// bound to the specified program object. It is also permissible to bind a
+// generic attribute index to an attribute variable name that is never used
+// in a vertex shader.
+//
+// Active attributes that are not explicitly bound will be bound by the
+// linker when LinkProgram is called. The locations assigned can be queried
+// by calling GetAttribLocation.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS.
+// GL.INVALID_OPERATION is generated if name starts with the reserved prefix "gl_".
+// GL.INVALID_VALUE is generated if program is not a value generated by OpenGL.
+// GL.INVALID_OPERATION is generated if program is not a program object.
+// GL.INVALID_OPERATION is generated if BindAttribLocation is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// BindAttribLocation is available in GL version 2.0 or greater.
+func (gl *GL) BindAttribLocation(program glbase.Program, index glbase.Attrib, name string) {
+ name_cstr := C.CString(name)
+ C.gl4_1core_glBindAttribLocation(gl.funcs, C.GLuint(program), C.GLuint(index), (*C.GLchar)(name_cstr))
+ C.free(unsafe.Pointer(name_cstr))
+}
+
+// AttachShader attaches a shader object to a program object.
+//
+// In order to create an executable, there must be a way to specify the list
+// of things that will be linked together. Program objects provide this
+// mechanism. Shaders that are to be linked together in a program object must
+// first be attached to that program object. This indicates that shader will
+// be included in link operations that will be performed on program.
+//
+// All operations that can be performed on a shader object are valid whether
+// or not the shader object is attached to a program object. It is
+// permissible to attach a shader object to a program object before source
+// code has been loaded into the shader object or before the shader object
+// has been compiled. It is permissible to attach multiple shader objects of
+// the same type because each may contain a portion of the complete shader.
+// It is also permissible to attach a shader object to more than one program
+// object. If a shader object is deleted while it is attached to a program
+// object, it will be flagged for deletion, and deletion will not occur until
+// DetachShader is called to detach it from all program objects to which it
+// is attached.
+//
+// Error GL.INVALID_VALUE is generated if either program or shader is not a
+// value generated by OpenGL. GL.INVALID_OPERATION is generated if program
+// is not a program object. GL.INVALID_OPERATION is generated if shader is
+// not a shader object. GL.INVALID_OPERATION is generated if shader is
+// already attached to program. GL.INVALID_OPERATION is generated if
+// AttachShader is executed between the execution of Begin and the
+// corresponding execution of End.
+//
+// AttachShader is available in GL version 2.0 or greater.
+func (gl *GL) AttachShader(program glbase.Program, shader glbase.Shader) {
+ C.gl4_1core_glAttachShader(gl.funcs, C.GLuint(program), C.GLuint(shader))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glStencilMaskSeparate.xml
+func (gl *GL) StencilMaskSeparate(face glbase.Enum, mask uint32) {
+ C.gl4_1core_glStencilMaskSeparate(gl.funcs, C.GLenum(face), C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glStencilFuncSeparate.xml
+func (gl *GL) StencilFuncSeparate(face, glfunc glbase.Enum, ref int32, mask uint32) {
+ C.gl4_1core_glStencilFuncSeparate(gl.funcs, C.GLenum(face), C.GLenum(glfunc), C.GLint(ref), C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glStencilOpSeparate.xml
+func (gl *GL) StencilOpSeparate(face, sfail, dpfail, dppass glbase.Enum) {
+ C.gl4_1core_glStencilOpSeparate(gl.funcs, C.GLenum(face), C.GLenum(sfail), C.GLenum(dpfail), C.GLenum(dppass))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawBuffers.xml
+func (gl *GL) DrawBuffers(n int, bufs []glbase.Enum) {
+ C.gl4_1core_glDrawBuffers(gl.funcs, C.GLsizei(n), (*C.GLenum)(unsafe.Pointer(&bufs[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendEquationSeparate.xml
+func (gl *GL) BlendEquationSeparate(modeRGB, modeAlpha glbase.Enum) {
+ C.gl4_1core_glBlendEquationSeparate(gl.funcs, C.GLenum(modeRGB), C.GLenum(modeAlpha))
+}
+
+// UniformMatrix4x3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix4x3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix4x3fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(4*3) != 0 {
+ panic("invalid value length for UniformMatrix4x3fv")
+ }
+ count := len(value) / (4 * 3)
+ C.gl4_1core_glUniformMatrix4x3fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix3x4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix3x4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix3x4fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(3*4) != 0 {
+ panic("invalid value length for UniformMatrix3x4fv")
+ }
+ count := len(value) / (3 * 4)
+ C.gl4_1core_glUniformMatrix3x4fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix4x2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix4x2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix4x2fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(4*2) != 0 {
+ panic("invalid value length for UniformMatrix4x2fv")
+ }
+ count := len(value) / (4 * 2)
+ C.gl4_1core_glUniformMatrix4x2fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix2x4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix2x4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix2x4fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(2*4) != 0 {
+ panic("invalid value length for UniformMatrix2x4fv")
+ }
+ count := len(value) / (2 * 4)
+ C.gl4_1core_glUniformMatrix2x4fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix3x2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix3x2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix3x2fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(3*2) != 0 {
+ panic("invalid value length for UniformMatrix3x2fv")
+ }
+ count := len(value) / (3 * 2)
+ C.gl4_1core_glUniformMatrix3x2fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix2x3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix2x3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix2x3fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(2*3) != 0 {
+ panic("invalid value length for UniformMatrix2x3fv")
+ }
+ count := len(value) / (2 * 3)
+ C.gl4_1core_glUniformMatrix2x3fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsVertexArray.xml
+func (gl *GL) IsVertexArray(array uint32) bool {
+ glresult := C.gl4_1core_glIsVertexArray(gl.funcs, C.GLuint(array))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGenVertexArrays.xml
+func (gl *GL) GenVertexArrays(n int, arrays []uint32) {
+ C.gl4_1core_glGenVertexArrays(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&arrays[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDeleteVertexArrays.xml
+func (gl *GL) DeleteVertexArrays(n int, arrays []uint32) {
+ C.gl4_1core_glDeleteVertexArrays(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&arrays[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindVertexArray.xml
+func (gl *GL) BindVertexArray(array uint32) {
+ C.gl4_1core_glBindVertexArray(gl.funcs, C.GLuint(array))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFlushMappedBufferRange.xml
+func (gl *GL) FlushMappedBufferRange(target glbase.Enum, offset, length int) {
+ C.gl4_1core_glFlushMappedBufferRange(gl.funcs, C.GLenum(target), C.GLintptr(offset), C.GLsizeiptr(length))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFramebufferTextureLayer.xml
+func (gl *GL) FramebufferTextureLayer(target, attachment glbase.Enum, texture glbase.Texture, level int, layer int32) {
+ C.gl4_1core_glFramebufferTextureLayer(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLuint(texture), C.GLint(level), C.GLint(layer))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRenderbufferStorageMultisample.xml
+func (gl *GL) RenderbufferStorageMultisample(target glbase.Enum, samples int32, internalFormat glbase.Enum, width, height int) {
+ C.gl4_1core_glRenderbufferStorageMultisample(gl.funcs, C.GLenum(target), C.GLsizei(samples), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlitFramebuffer.xml
+func (gl *GL) BlitFramebuffer(srcX0, srcY0, srcX1, srcY1, dstX0, dstY0, dstX1, dstY1 int32, mask glbase.Bitfield, filter glbase.Enum) {
+ C.gl4_1core_glBlitFramebuffer(gl.funcs, C.GLint(srcX0), C.GLint(srcY0), C.GLint(srcX1), C.GLint(srcY1), C.GLint(dstX0), C.GLint(dstY0), C.GLint(dstX1), C.GLint(dstY1), C.GLbitfield(mask), C.GLenum(filter))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGenerateMipmap.xml
+func (gl *GL) GenerateMipmap(target glbase.Enum) {
+ C.gl4_1core_glGenerateMipmap(gl.funcs, C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetFramebufferAttachmentParameteriv.xml
+func (gl *GL) GetFramebufferAttachmentParameteriv(target, attachment, pname glbase.Enum, params []int32) {
+ C.gl4_1core_glGetFramebufferAttachmentParameteriv(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFramebufferRenderbuffer.xml
+func (gl *GL) FramebufferRenderbuffer(target, attachment, renderbuffertarget glbase.Enum, renderbuffer glbase.Renderbuffer) {
+ C.gl4_1core_glFramebufferRenderbuffer(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(renderbuffertarget), C.GLuint(renderbuffer))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFramebufferTexture3D.xml
+func (gl *GL) FramebufferTexture3D(target, attachment, textarget glbase.Enum, texture glbase.Texture, level int, zoffset int32) {
+ C.gl4_1core_glFramebufferTexture3D(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(textarget), C.GLuint(texture), C.GLint(level), C.GLint(zoffset))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFramebufferTexture2D.xml
+func (gl *GL) FramebufferTexture2D(target, attachment, textarget glbase.Enum, texture glbase.Texture, level int) {
+ C.gl4_1core_glFramebufferTexture2D(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(textarget), C.GLuint(texture), C.GLint(level))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFramebufferTexture1D.xml
+func (gl *GL) FramebufferTexture1D(target, attachment, textarget glbase.Enum, texture glbase.Texture, level int) {
+ C.gl4_1core_glFramebufferTexture1D(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(textarget), C.GLuint(texture), C.GLint(level))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCheckFramebufferStatus.xml
+func (gl *GL) CheckFramebufferStatus(target glbase.Enum) glbase.Enum {
+ glresult := C.gl4_1core_glCheckFramebufferStatus(gl.funcs, C.GLenum(target))
+ return glbase.Enum(glresult)
+}
+
+// GenFramebuffers returns n framebuffer object names in ids. There is no
+// guarantee that the names form a contiguous set of integers; however, it is
+// guaranteed that none of the returned names was in use immediately before
+// the call to GenFramebuffers.
+//
+// Framebuffer object names returned by a call to GenFramebuffers are not
+// returned by subsequent calls, unless they are first deleted with
+// DeleteFramebuffers.
+//
+// The names returned in ids are marked as used, for the purposes of
+// GenFramebuffers only, but they acquire state and type only when they are
+// first bound.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+func (gl *GL) GenFramebuffers(n int) []glbase.Framebuffer {
+ if n == 0 {
+ return nil
+ }
+ framebuffers := make([]glbase.Framebuffer, n)
+ C.gl4_1core_glGenFramebuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&framebuffers[0])))
+ return framebuffers
+}
+
+// DeleteFramebuffers deletes the framebuffer objects whose names are
+// stored in the framebuffers slice. The name zero is reserved by the GL and
+// is silently ignored, should it occur in framebuffers, as are other unused
+// names. Once a framebuffer object is deleted, its name is again unused and
+// it has no attachments. If a framebuffer that is currently bound to one or
+// more of the targets GL.DRAW_FRAMEBUFFER or GL.READ_FRAMEBUFFER is deleted,
+// it is as though BindFramebuffer had been executed with the corresponding
+// target and framebuffer zero.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// DeleteFramebuffers is available in GL version 3.0 or greater.
+func (gl *GL) DeleteFramebuffers(framebuffers []glbase.Framebuffer) {
+ n := len(framebuffers)
+ if n == 0 {
+ return
+ }
+ C.gl4_1core_glDeleteFramebuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&framebuffers[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindFramebuffer.xml
+func (gl *GL) BindFramebuffer(target glbase.Enum, framebuffer glbase.Framebuffer) {
+ C.gl4_1core_glBindFramebuffer(gl.funcs, C.GLenum(target), C.GLuint(framebuffer))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsFramebuffer.xml
+func (gl *GL) IsFramebuffer(framebuffer glbase.Framebuffer) bool {
+ glresult := C.gl4_1core_glIsFramebuffer(gl.funcs, C.GLuint(framebuffer))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetRenderbufferParameteriv.xml
+func (gl *GL) GetRenderbufferParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl4_1core_glGetRenderbufferParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRenderbufferStorage.xml
+func (gl *GL) RenderbufferStorage(target, internalFormat glbase.Enum, width, height int) {
+ C.gl4_1core_glRenderbufferStorage(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height))
+}
+
+// GenRenderbuffers returns n renderbuffer object names in renderbuffers.
+// There is no guarantee that the names form a contiguous set of integers;
+// however, it is guaranteed that none of the returned names was in use
+// immediately before the call to GenRenderbuffers.
+//
+// Renderbuffer object names returned by a call to GenRenderbuffers are not
+// returned by subsequent calls, unless they are first deleted with
+// DeleteRenderbuffers.
+//
+// The names returned in renderbuffers are marked as used, for the purposes
+// of GenRenderbuffers only, but they acquire state and type only when they
+// are first bound.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// GenRenderbuffers is available in GL version 3.0 or greater.
+func (gl *GL) GenRenderbuffers(n int) []glbase.Renderbuffer {
+ if n == 0 {
+ return nil
+ }
+ renderbuffers := make([]glbase.Renderbuffer, n)
+ C.gl4_1core_glGenRenderbuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&renderbuffers[0])))
+ return renderbuffers
+}
+
+// DeleteRenderbuffers deletes the renderbuffer objects whose names are stored
+// in the renderbuffers slice. The name zero is reserved by the GL and
+// is silently ignored, should it occur in renderbuffers, as are other unused
+// names. Once a renderbuffer object is deleted, its name is again unused and
+// it has no contents. If a renderbuffer that is currently bound to the
+// target GL.RENDERBUFFER is deleted, it is as though BindRenderbuffer had
+// been executed with a target of GL.RENDERBUFFER and a name of zero.
+//
+// If a renderbuffer object is attached to one or more attachment points in
+// the currently bound framebuffer, then it as if FramebufferRenderbuffer
+// had been called, with a renderbuffer of zero for each attachment point to
+// which this image was attached in the currently bound framebuffer. In other
+// words, this renderbuffer object is first detached from all attachment
+// ponits in the currently bound framebuffer. Note that the renderbuffer
+// image is specifically not detached from any non-bound framebuffers.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// DeleteRenderbuffers is available in GL version 3.0 or greater.
+func (gl *GL) DeleteRenderbuffers(renderbuffers []glbase.Renderbuffer) {
+ n := len(renderbuffers)
+ if n == 0 {
+ return
+ }
+ C.gl4_1core_glDeleteRenderbuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&renderbuffers[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindRenderbuffer.xml
+func (gl *GL) BindRenderbuffer(target glbase.Enum, renderbuffer glbase.Renderbuffer) {
+ C.gl4_1core_glBindRenderbuffer(gl.funcs, C.GLenum(target), C.GLuint(renderbuffer))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsRenderbuffer.xml
+func (gl *GL) IsRenderbuffer(renderbuffer glbase.Renderbuffer) bool {
+ glresult := C.gl4_1core_glIsRenderbuffer(gl.funcs, C.GLuint(renderbuffer))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearBufferfi.xml
+func (gl *GL) ClearBufferfi(buffer glbase.Enum, drawbuffer int32, depth float32, stencil int32) {
+ C.gl4_1core_glClearBufferfi(gl.funcs, C.GLenum(buffer), C.GLint(drawbuffer), C.GLfloat(depth), C.GLint(stencil))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearBufferfv.xml
+func (gl *GL) ClearBufferfv(buffer glbase.Enum, drawbuffer int32, value []float32) {
+ C.gl4_1core_glClearBufferfv(gl.funcs, C.GLenum(buffer), C.GLint(drawbuffer), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearBufferuiv.xml
+func (gl *GL) ClearBufferuiv(buffer glbase.Enum, drawbuffer int32, value []uint32) {
+ C.gl4_1core_glClearBufferuiv(gl.funcs, C.GLenum(buffer), C.GLint(drawbuffer), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearBufferiv.xml
+func (gl *GL) ClearBufferiv(buffer glbase.Enum, drawbuffer int32, value []int32) {
+ C.gl4_1core_glClearBufferiv(gl.funcs, C.GLenum(buffer), C.GLint(drawbuffer), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexParameterIuiv.xml
+func (gl *GL) GetTexParameterIuiv(target, pname glbase.Enum, params []uint32) {
+ C.gl4_1core_glGetTexParameterIuiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexParameterIiv.xml
+func (gl *GL) GetTexParameterIiv(target, pname glbase.Enum, params []int32) {
+ C.gl4_1core_glGetTexParameterIiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexParameterIuiv.xml
+func (gl *GL) TexParameterIuiv(target, pname glbase.Enum, params []uint32) {
+ C.gl4_1core_glTexParameterIuiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexParameterIiv.xml
+func (gl *GL) TexParameterIiv(target, pname glbase.Enum, params []int32) {
+ C.gl4_1core_glTexParameterIiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// Uniform4uiv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform4uiv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4uiv(location glbase.Uniform, value []uint32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%4 != 0 {
+ panic("invalid value length for Uniform4uiv")
+ }
+ count := len(value) / 4
+ C.gl4_1core_glUniform4uiv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform3uiv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform3uiv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3uiv(location glbase.Uniform, value []uint32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%3 != 0 {
+ panic("invalid value length for Uniform3uiv")
+ }
+ count := len(value) / 3
+ C.gl4_1core_glUniform3uiv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform2uiv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform2uiv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2uiv(location glbase.Uniform, value []uint32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%2 != 0 {
+ panic("invalid value length for Uniform2uiv")
+ }
+ count := len(value) / 2
+ C.gl4_1core_glUniform2uiv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform1uiv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform1uiv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1uiv(location glbase.Uniform, value []uint32) {
+ if len(value) == 0 {
+ return
+ }
+ count := len(value)
+ C.gl4_1core_glUniform1uiv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4ui modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform4ui operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4ui(location glbase.Uniform, v0, v1, v2, v3 uint32) {
+ C.gl4_1core_glUniform4ui(gl.funcs, C.GLint(location), C.GLuint(v0), C.GLuint(v1), C.GLuint(v2), C.GLuint(v3))
+}
+
+// Uniform3ui modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform3ui operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3ui(location glbase.Uniform, v0, v1, v2 uint32) {
+ C.gl4_1core_glUniform3ui(gl.funcs, C.GLint(location), C.GLuint(v0), C.GLuint(v1), C.GLuint(v2))
+}
+
+// Uniform2ui modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform2ui operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2ui(location glbase.Uniform, v0, v1 uint32) {
+ C.gl4_1core_glUniform2ui(gl.funcs, C.GLint(location), C.GLuint(v0), C.GLuint(v1))
+}
+
+// Uniform1ui modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform1ui operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1ui(location glbase.Uniform, v0 uint32) {
+ C.gl4_1core_glUniform1ui(gl.funcs, C.GLint(location), C.GLuint(v0))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetFragDataLocation.xml
+func (gl *GL) GetFragDataLocation(program glbase.Program, name []byte) int32 {
+ glresult := C.gl4_1core_glGetFragDataLocation(gl.funcs, C.GLuint(program), (*C.GLchar)(unsafe.Pointer(&name[0])))
+ return int32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindFragDataLocation.xml
+func (gl *GL) BindFragDataLocation(program glbase.Program, color uint32, name []byte) {
+ C.gl4_1core_glBindFragDataLocation(gl.funcs, C.GLuint(program), C.GLuint(color), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetUniformuiv.xml
+func (gl *GL) GetUniformuiv(program glbase.Program, location glbase.Uniform, params []uint32) {
+ C.gl4_1core_glGetUniformuiv(gl.funcs, C.GLuint(program), C.GLint(location), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetVertexAttribIuiv.xml
+func (gl *GL) GetVertexAttribIuiv(index glbase.Attrib, pname glbase.Enum, params []uint32) {
+ C.gl4_1core_glGetVertexAttribIuiv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetVertexAttribIiv.xml
+func (gl *GL) GetVertexAttribIiv(index glbase.Attrib, pname glbase.Enum, params []int32) {
+ C.gl4_1core_glGetVertexAttribIiv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribIPointer.xml
+func (gl *GL) VertexAttribIPointer(index glbase.Attrib, size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1core_glVertexAttribIPointer(gl.funcs, C.GLuint(index), C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEndConditionalRender.xml
+func (gl *GL) EndConditionalRender() {
+ C.gl4_1core_glEndConditionalRender(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBeginConditionalRender.xml
+func (gl *GL) BeginConditionalRender(id uint32, mode glbase.Enum) {
+ C.gl4_1core_glBeginConditionalRender(gl.funcs, C.GLuint(id), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClampColor.xml
+func (gl *GL) ClampColor(target, clamp glbase.Enum) {
+ C.gl4_1core_glClampColor(gl.funcs, C.GLenum(target), C.GLenum(clamp))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTransformFeedbackVarying.xml
+func (gl *GL) GetTransformFeedbackVarying(program glbase.Program, index uint32, bufSize int32, length []int32, size []int, gltype []glbase.Enum, name []byte) {
+ C.gl4_1core_glGetTransformFeedbackVarying(gl.funcs, C.GLuint(program), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLsizei)(unsafe.Pointer(&size[0])), (*C.GLenum)(unsafe.Pointer(&gltype[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindBufferBase.xml
+func (gl *GL) BindBufferBase(target glbase.Enum, index uint32, buffer glbase.Buffer) {
+ C.gl4_1core_glBindBufferBase(gl.funcs, C.GLenum(target), C.GLuint(index), C.GLuint(buffer))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindBufferRange.xml
+func (gl *GL) BindBufferRange(target glbase.Enum, index uint32, buffer glbase.Buffer, offset, size int) {
+ C.gl4_1core_glBindBufferRange(gl.funcs, C.GLenum(target), C.GLuint(index), C.GLuint(buffer), C.GLintptr(offset), C.GLsizeiptr(size))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEndTransformFeedback.xml
+func (gl *GL) EndTransformFeedback() {
+ C.gl4_1core_glEndTransformFeedback(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBeginTransformFeedback.xml
+func (gl *GL) BeginTransformFeedback(primitiveMode glbase.Enum) {
+ C.gl4_1core_glBeginTransformFeedback(gl.funcs, C.GLenum(primitiveMode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsEnabledi.xml
+func (gl *GL) IsEnabledi(target glbase.Enum, index uint32) bool {
+ glresult := C.gl4_1core_glIsEnabledi(gl.funcs, C.GLenum(target), C.GLuint(index))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDisablei.xml
+func (gl *GL) Disablei(target glbase.Enum, index uint32) {
+ C.gl4_1core_glDisablei(gl.funcs, C.GLenum(target), C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEnablei.xml
+func (gl *GL) Enablei(target glbase.Enum, index uint32) {
+ C.gl4_1core_glEnablei(gl.funcs, C.GLenum(target), C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetIntegeri_v.xml
+func (gl *GL) GetIntegeri_v(target glbase.Enum, index uint32, data []int32) {
+ C.gl4_1core_glGetIntegeri_v(gl.funcs, C.GLenum(target), C.GLuint(index), (*C.GLint)(unsafe.Pointer(&data[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetBooleani_v.xml
+func (gl *GL) GetBooleani_v(target glbase.Enum, index uint32, data []bool) {
+ C.gl4_1core_glGetBooleani_v(gl.funcs, C.GLenum(target), C.GLuint(index), (*C.GLboolean)(unsafe.Pointer(&data[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorMaski.xml
+func (gl *GL) ColorMaski(index uint32, r, g, b, a bool) {
+ C.gl4_1core_glColorMaski(gl.funcs, C.GLuint(index), *(*C.GLboolean)(unsafe.Pointer(&r)), *(*C.GLboolean)(unsafe.Pointer(&g)), *(*C.GLboolean)(unsafe.Pointer(&b)), *(*C.GLboolean)(unsafe.Pointer(&a)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyBufferSubData.xml
+func (gl *GL) CopyBufferSubData(readTarget, writeTarget glbase.Enum, readOffset, writeOffset, size int) {
+ C.gl4_1core_glCopyBufferSubData(gl.funcs, C.GLenum(readTarget), C.GLenum(writeTarget), C.GLintptr(readOffset), C.GLintptr(writeOffset), C.GLsizeiptr(size))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformBlockBinding.xml
+func (gl *GL) UniformBlockBinding(program glbase.Program, v0, v1 uint32) {
+ C.gl4_1core_glUniformBlockBinding(gl.funcs, C.GLuint(program), C.GLuint(v0), C.GLuint(v1))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveUniformBlockName.xml
+func (gl *GL) GetActiveUniformBlockName(program glbase.Program, uniformBlockIndex uint32, bufSize int32, length []int32, uniformBlockName []byte) {
+ C.gl4_1core_glGetActiveUniformBlockName(gl.funcs, C.GLuint(program), C.GLuint(uniformBlockIndex), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&uniformBlockName[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveUniformBlockiv.xml
+func (gl *GL) GetActiveUniformBlockiv(program glbase.Program, uniformBlockIndex uint32, pname glbase.Enum, params []int32) {
+ C.gl4_1core_glGetActiveUniformBlockiv(gl.funcs, C.GLuint(program), C.GLuint(uniformBlockIndex), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetUniformBlockIndex.xml
+func (gl *GL) GetUniformBlockIndex(program glbase.Program, uniformBlockName []byte) uint32 {
+ glresult := C.gl4_1core_glGetUniformBlockIndex(gl.funcs, C.GLuint(program), (*C.GLchar)(unsafe.Pointer(&uniformBlockName[0])))
+ return uint32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveUniformName.xml
+func (gl *GL) GetActiveUniformName(program glbase.Program, uniformIndex uint32, bufSize int32, length []int32, uniformName []byte) {
+ C.gl4_1core_glGetActiveUniformName(gl.funcs, C.GLuint(program), C.GLuint(uniformIndex), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&uniformName[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveUniformsiv.xml
+func (gl *GL) GetActiveUniformsiv(program glbase.Program, uniformCount int32, uniformIndices []uint32, pname glbase.Enum, params []int32) {
+ C.gl4_1core_glGetActiveUniformsiv(gl.funcs, C.GLuint(program), C.GLsizei(uniformCount), (*C.GLuint)(unsafe.Pointer(&uniformIndices[0])), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPrimitiveRestartIndex.xml
+func (gl *GL) PrimitiveRestartIndex(index uint32) {
+ C.gl4_1core_glPrimitiveRestartIndex(gl.funcs, C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexBuffer.xml
+func (gl *GL) TexBuffer(target, internalFormat glbase.Enum, buffer glbase.Buffer) {
+ C.gl4_1core_glTexBuffer(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLuint(buffer))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawElementsInstanced.xml
+func (gl *GL) DrawElementsInstanced(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}, instancecount int32) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1core_glDrawElementsInstanced(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr, C.GLsizei(instancecount))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawArraysInstanced.xml
+func (gl *GL) DrawArraysInstanced(mode glbase.Enum, first, count int, instancecount int32) {
+ C.gl4_1core_glDrawArraysInstanced(gl.funcs, C.GLenum(mode), C.GLint(first), C.GLsizei(count), C.GLsizei(instancecount))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSampleMaski.xml
+func (gl *GL) SampleMaski(index uint32, mask glbase.Bitfield) {
+ C.gl4_1core_glSampleMaski(gl.funcs, C.GLuint(index), C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetMultisamplefv.xml
+func (gl *GL) GetMultisamplefv(pname glbase.Enum, index uint32, val []float32) {
+ C.gl4_1core_glGetMultisamplefv(gl.funcs, C.GLenum(pname), C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&val[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexImage3DMultisample.xml
+func (gl *GL) TexImage3DMultisample(target glbase.Enum, samples, internalFormat int32, width, height int, depth int32, fixedsamplelocations bool) {
+ C.gl4_1core_glTexImage3DMultisample(gl.funcs, C.GLenum(target), C.GLsizei(samples), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), *(*C.GLboolean)(unsafe.Pointer(&fixedsamplelocations)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexImage2DMultisample.xml
+func (gl *GL) TexImage2DMultisample(target glbase.Enum, samples, internalFormat int32, width, height int, fixedsamplelocations bool) {
+ C.gl4_1core_glTexImage2DMultisample(gl.funcs, C.GLenum(target), C.GLsizei(samples), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), *(*C.GLboolean)(unsafe.Pointer(&fixedsamplelocations)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetSynciv.xml
+func (gl *GL) GetSynciv(sync glbase.Sync, pname glbase.Enum, bufSize int32, length, values []int32) {
+ C.gl4_1core_glGetSynciv(gl.funcs, C.GLsync(unsafe.Pointer(sync)), C.GLenum(pname), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLint)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetInteger64v.xml
+func (gl *GL) GetInteger64v(pname glbase.Enum, params []int64) {
+ C.gl4_1core_glGetInteger64v(gl.funcs, C.GLenum(pname), (*C.GLint64)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWaitSync.xml
+func (gl *GL) WaitSync(sync glbase.Sync, flags glbase.Bitfield, timeout uint64) {
+ C.gl4_1core_glWaitSync(gl.funcs, C.GLsync(unsafe.Pointer(sync)), C.GLbitfield(flags), C.GLuint64(timeout))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClientWaitSync.xml
+func (gl *GL) ClientWaitSync(sync glbase.Sync, flags glbase.Bitfield, timeout uint64) glbase.Enum {
+ glresult := C.gl4_1core_glClientWaitSync(gl.funcs, C.GLsync(unsafe.Pointer(sync)), C.GLbitfield(flags), C.GLuint64(timeout))
+ return glbase.Enum(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDeleteSync.xml
+func (gl *GL) DeleteSync(sync glbase.Sync) {
+ C.gl4_1core_glDeleteSync(gl.funcs, C.GLsync(unsafe.Pointer(sync)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsSync.xml
+func (gl *GL) IsSync(sync glbase.Sync) bool {
+ glresult := C.gl4_1core_glIsSync(gl.funcs, C.GLsync(unsafe.Pointer(sync)))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFenceSync.xml
+func (gl *GL) FenceSync(condition glbase.Enum, flags glbase.Bitfield) glbase.Sync {
+ glresult := C.gl4_1core_glFenceSync(gl.funcs, C.GLenum(condition), C.GLbitfield(flags))
+ return glbase.Sync(unsafe.Pointer(glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProvokingVertex.xml
+func (gl *GL) ProvokingVertex(mode glbase.Enum) {
+ C.gl4_1core_glProvokingVertex(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawElementsInstancedBaseVertex.xml
+func (gl *GL) DrawElementsInstancedBaseVertex(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}, instancecount, basevertex int32) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1core_glDrawElementsInstancedBaseVertex(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr, C.GLsizei(instancecount), C.GLint(basevertex))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawRangeElementsBaseVertex.xml
+func (gl *GL) DrawRangeElementsBaseVertex(mode glbase.Enum, start, end uint32, count int, gltype glbase.Enum, indices interface{}, basevertex int32) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1core_glDrawRangeElementsBaseVertex(gl.funcs, C.GLenum(mode), C.GLuint(start), C.GLuint(end), C.GLsizei(count), C.GLenum(gltype), indices_ptr, C.GLint(basevertex))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawElementsBaseVertex.xml
+func (gl *GL) DrawElementsBaseVertex(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}, basevertex int32) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1core_glDrawElementsBaseVertex(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr, C.GLint(basevertex))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFramebufferTexture.xml
+func (gl *GL) FramebufferTexture(target, attachment glbase.Enum, texture glbase.Texture, level int) {
+ C.gl4_1core_glFramebufferTexture(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLuint(texture), C.GLint(level))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetBufferParameteri64v.xml
+func (gl *GL) GetBufferParameteri64v(target, pname glbase.Enum, params []int64) {
+ C.gl4_1core_glGetBufferParameteri64v(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint64)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetInteger64i_v.xml
+func (gl *GL) GetInteger64i_v(target glbase.Enum, index uint32, data []int64) {
+ C.gl4_1core_glGetInteger64i_v(gl.funcs, C.GLenum(target), C.GLuint(index), (*C.GLint64)(unsafe.Pointer(&data[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP4uiv.xml
+func (gl *GL) VertexAttribP4uiv(index glbase.Attrib, gltype glbase.Enum, normalized bool, value []uint32) {
+ C.gl4_1core_glVertexAttribP4uiv(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP4ui.xml
+func (gl *GL) VertexAttribP4ui(index glbase.Attrib, gltype glbase.Enum, normalized bool, value uint32) {
+ C.gl4_1core_glVertexAttribP4ui(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP3uiv.xml
+func (gl *GL) VertexAttribP3uiv(index glbase.Attrib, gltype glbase.Enum, normalized bool, value []uint32) {
+ C.gl4_1core_glVertexAttribP3uiv(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP3ui.xml
+func (gl *GL) VertexAttribP3ui(index glbase.Attrib, gltype glbase.Enum, normalized bool, value uint32) {
+ C.gl4_1core_glVertexAttribP3ui(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP2uiv.xml
+func (gl *GL) VertexAttribP2uiv(index glbase.Attrib, gltype glbase.Enum, normalized bool, value []uint32) {
+ C.gl4_1core_glVertexAttribP2uiv(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP2ui.xml
+func (gl *GL) VertexAttribP2ui(index glbase.Attrib, gltype glbase.Enum, normalized bool, value uint32) {
+ C.gl4_1core_glVertexAttribP2ui(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP1uiv.xml
+func (gl *GL) VertexAttribP1uiv(index glbase.Attrib, gltype glbase.Enum, normalized bool, value []uint32) {
+ C.gl4_1core_glVertexAttribP1uiv(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP1ui.xml
+func (gl *GL) VertexAttribP1ui(index glbase.Attrib, gltype glbase.Enum, normalized bool, value uint32) {
+ C.gl4_1core_glVertexAttribP1ui(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColorP3uiv.xml
+func (gl *GL) SecondaryColorP3uiv(gltype glbase.Enum, color []uint32) {
+ C.gl4_1core_glSecondaryColorP3uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&color[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColorP3ui.xml
+func (gl *GL) SecondaryColorP3ui(gltype glbase.Enum, color uint32) {
+ C.gl4_1core_glSecondaryColorP3ui(gl.funcs, C.GLenum(gltype), C.GLuint(color))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorP4uiv.xml
+func (gl *GL) ColorP4uiv(gltype glbase.Enum, color []uint32) {
+ C.gl4_1core_glColorP4uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&color[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorP4ui.xml
+func (gl *GL) ColorP4ui(gltype glbase.Enum, color uint32) {
+ C.gl4_1core_glColorP4ui(gl.funcs, C.GLenum(gltype), C.GLuint(color))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorP3uiv.xml
+func (gl *GL) ColorP3uiv(gltype glbase.Enum, color []uint32) {
+ C.gl4_1core_glColorP3uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&color[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorP3ui.xml
+func (gl *GL) ColorP3ui(gltype glbase.Enum, color uint32) {
+ C.gl4_1core_glColorP3ui(gl.funcs, C.GLenum(gltype), C.GLuint(color))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNormalP3uiv.xml
+func (gl *GL) NormalP3uiv(gltype glbase.Enum, coords []uint32) {
+ C.gl4_1core_glNormalP3uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNormalP3ui.xml
+func (gl *GL) NormalP3ui(gltype glbase.Enum, coords uint32) {
+ C.gl4_1core_glNormalP3ui(gl.funcs, C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP4uiv.xml
+func (gl *GL) MultiTexCoordP4uiv(texture, gltype glbase.Enum, coords []uint32) {
+ C.gl4_1core_glMultiTexCoordP4uiv(gl.funcs, C.GLenum(texture), C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP4ui.xml
+func (gl *GL) MultiTexCoordP4ui(texture, gltype glbase.Enum, coords uint32) {
+ C.gl4_1core_glMultiTexCoordP4ui(gl.funcs, C.GLenum(texture), C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP3uiv.xml
+func (gl *GL) MultiTexCoordP3uiv(texture, gltype glbase.Enum, coords []uint32) {
+ C.gl4_1core_glMultiTexCoordP3uiv(gl.funcs, C.GLenum(texture), C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP3ui.xml
+func (gl *GL) MultiTexCoordP3ui(texture, gltype glbase.Enum, coords uint32) {
+ C.gl4_1core_glMultiTexCoordP3ui(gl.funcs, C.GLenum(texture), C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP2uiv.xml
+func (gl *GL) MultiTexCoordP2uiv(texture, gltype glbase.Enum, coords []uint32) {
+ C.gl4_1core_glMultiTexCoordP2uiv(gl.funcs, C.GLenum(texture), C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP2ui.xml
+func (gl *GL) MultiTexCoordP2ui(texture, gltype glbase.Enum, coords uint32) {
+ C.gl4_1core_glMultiTexCoordP2ui(gl.funcs, C.GLenum(texture), C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP1uiv.xml
+func (gl *GL) MultiTexCoordP1uiv(texture, gltype glbase.Enum, coords []uint32) {
+ C.gl4_1core_glMultiTexCoordP1uiv(gl.funcs, C.GLenum(texture), C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP1ui.xml
+func (gl *GL) MultiTexCoordP1ui(texture, gltype glbase.Enum, coords uint32) {
+ C.gl4_1core_glMultiTexCoordP1ui(gl.funcs, C.GLenum(texture), C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP4uiv.xml
+func (gl *GL) TexCoordP4uiv(gltype glbase.Enum, coords []uint32) {
+ C.gl4_1core_glTexCoordP4uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP4ui.xml
+func (gl *GL) TexCoordP4ui(gltype glbase.Enum, coords uint32) {
+ C.gl4_1core_glTexCoordP4ui(gl.funcs, C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP3uiv.xml
+func (gl *GL) TexCoordP3uiv(gltype glbase.Enum, coords []uint32) {
+ C.gl4_1core_glTexCoordP3uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP3ui.xml
+func (gl *GL) TexCoordP3ui(gltype glbase.Enum, coords uint32) {
+ C.gl4_1core_glTexCoordP3ui(gl.funcs, C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP2uiv.xml
+func (gl *GL) TexCoordP2uiv(gltype glbase.Enum, coords []uint32) {
+ C.gl4_1core_glTexCoordP2uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP2ui.xml
+func (gl *GL) TexCoordP2ui(gltype glbase.Enum, coords uint32) {
+ C.gl4_1core_glTexCoordP2ui(gl.funcs, C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP1uiv.xml
+func (gl *GL) TexCoordP1uiv(gltype glbase.Enum, coords []uint32) {
+ C.gl4_1core_glTexCoordP1uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP1ui.xml
+func (gl *GL) TexCoordP1ui(gltype glbase.Enum, coords uint32) {
+ C.gl4_1core_glTexCoordP1ui(gl.funcs, C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexP4uiv.xml
+func (gl *GL) VertexP4uiv(gltype glbase.Enum, value []uint32) {
+ C.gl4_1core_glVertexP4uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexP4ui.xml
+func (gl *GL) VertexP4ui(gltype glbase.Enum, value uint32) {
+ C.gl4_1core_glVertexP4ui(gl.funcs, C.GLenum(gltype), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexP3uiv.xml
+func (gl *GL) VertexP3uiv(gltype glbase.Enum, value []uint32) {
+ C.gl4_1core_glVertexP3uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexP3ui.xml
+func (gl *GL) VertexP3ui(gltype glbase.Enum, value uint32) {
+ C.gl4_1core_glVertexP3ui(gl.funcs, C.GLenum(gltype), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexP2uiv.xml
+func (gl *GL) VertexP2uiv(gltype glbase.Enum, value []uint32) {
+ C.gl4_1core_glVertexP2uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexP2ui.xml
+func (gl *GL) VertexP2ui(gltype glbase.Enum, value uint32) {
+ C.gl4_1core_glVertexP2ui(gl.funcs, C.GLenum(gltype), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetQueryObjectui64v.xml
+func (gl *GL) GetQueryObjectui64v(id uint32, pname glbase.Enum, params []uint64) {
+ C.gl4_1core_glGetQueryObjectui64v(gl.funcs, C.GLuint(id), C.GLenum(pname), (*C.GLuint64)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetQueryObjecti64v.xml
+func (gl *GL) GetQueryObjecti64v(id uint32, pname glbase.Enum, params []int64) {
+ C.gl4_1core_glGetQueryObjecti64v(gl.funcs, C.GLuint(id), C.GLenum(pname), (*C.GLint64)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glQueryCounter.xml
+func (gl *GL) QueryCounter(id uint32, target glbase.Enum) {
+ C.gl4_1core_glQueryCounter(gl.funcs, C.GLuint(id), C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetSamplerParameterIuiv.xml
+func (gl *GL) GetSamplerParameterIuiv(sampler uint32, pname glbase.Enum, params []uint32) {
+ C.gl4_1core_glGetSamplerParameterIuiv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetSamplerParameterfv.xml
+func (gl *GL) GetSamplerParameterfv(sampler uint32, pname glbase.Enum, params []float32) {
+ C.gl4_1core_glGetSamplerParameterfv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetSamplerParameterIiv.xml
+func (gl *GL) GetSamplerParameterIiv(sampler uint32, pname glbase.Enum, params []int32) {
+ C.gl4_1core_glGetSamplerParameterIiv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetSamplerParameteriv.xml
+func (gl *GL) GetSamplerParameteriv(sampler uint32, pname glbase.Enum, params []int32) {
+ C.gl4_1core_glGetSamplerParameteriv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSamplerParameterIuiv.xml
+func (gl *GL) SamplerParameterIuiv(sampler uint32, pname glbase.Enum, param []uint32) {
+ C.gl4_1core_glSamplerParameterIuiv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&param[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSamplerParameterIiv.xml
+func (gl *GL) SamplerParameterIiv(sampler uint32, pname glbase.Enum, param []int32) {
+ C.gl4_1core_glSamplerParameterIiv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&param[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSamplerParameterfv.xml
+func (gl *GL) SamplerParameterfv(sampler uint32, pname glbase.Enum, param []float32) {
+ C.gl4_1core_glSamplerParameterfv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&param[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSamplerParameterf.xml
+func (gl *GL) SamplerParameterf(sampler uint32, pname glbase.Enum, param float32) {
+ C.gl4_1core_glSamplerParameterf(gl.funcs, C.GLuint(sampler), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSamplerParameteriv.xml
+func (gl *GL) SamplerParameteriv(sampler uint32, pname glbase.Enum, param []int32) {
+ C.gl4_1core_glSamplerParameteriv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&param[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSamplerParameteri.xml
+func (gl *GL) SamplerParameteri(sampler uint32, pname glbase.Enum, param int32) {
+ C.gl4_1core_glSamplerParameteri(gl.funcs, C.GLuint(sampler), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindSampler.xml
+func (gl *GL) BindSampler(unit, sampler uint32) {
+ C.gl4_1core_glBindSampler(gl.funcs, C.GLuint(unit), C.GLuint(sampler))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsSampler.xml
+func (gl *GL) IsSampler(sampler uint32) bool {
+ glresult := C.gl4_1core_glIsSampler(gl.funcs, C.GLuint(sampler))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDeleteSamplers.xml
+func (gl *GL) DeleteSamplers(count int, samplers []uint32) {
+ C.gl4_1core_glDeleteSamplers(gl.funcs, C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&samplers[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGenSamplers.xml
+func (gl *GL) GenSamplers(count int, samplers []uint32) {
+ C.gl4_1core_glGenSamplers(gl.funcs, C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&samplers[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetFragDataIndex.xml
+func (gl *GL) GetFragDataIndex(program glbase.Program, name []byte) int32 {
+ glresult := C.gl4_1core_glGetFragDataIndex(gl.funcs, C.GLuint(program), (*C.GLchar)(unsafe.Pointer(&name[0])))
+ return int32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindFragDataLocationIndexed.xml
+func (gl *GL) BindFragDataLocationIndexed(program glbase.Program, colorNumber, index uint32, name []byte) {
+ C.gl4_1core_glBindFragDataLocationIndexed(gl.funcs, C.GLuint(program), C.GLuint(colorNumber), C.GLuint(index), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribDivisor.xml
+func (gl *GL) VertexAttribDivisor(index glbase.Attrib, divisor uint32) {
+ C.gl4_1core_glVertexAttribDivisor(gl.funcs, C.GLuint(index), C.GLuint(divisor))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetQueryIndexediv.xml
+func (gl *GL) GetQueryIndexediv(target glbase.Enum, index uint32, pname glbase.Enum, params []int32) {
+ C.gl4_1core_glGetQueryIndexediv(gl.funcs, C.GLenum(target), C.GLuint(index), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEndQueryIndexed.xml
+func (gl *GL) EndQueryIndexed(target glbase.Enum, index uint32) {
+ C.gl4_1core_glEndQueryIndexed(gl.funcs, C.GLenum(target), C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBeginQueryIndexed.xml
+func (gl *GL) BeginQueryIndexed(target glbase.Enum, index, id uint32) {
+ C.gl4_1core_glBeginQueryIndexed(gl.funcs, C.GLenum(target), C.GLuint(index), C.GLuint(id))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawTransformFeedbackStream.xml
+func (gl *GL) DrawTransformFeedbackStream(mode glbase.Enum, id, stream uint32) {
+ C.gl4_1core_glDrawTransformFeedbackStream(gl.funcs, C.GLenum(mode), C.GLuint(id), C.GLuint(stream))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawTransformFeedback.xml
+func (gl *GL) DrawTransformFeedback(mode glbase.Enum, id uint32) {
+ C.gl4_1core_glDrawTransformFeedback(gl.funcs, C.GLenum(mode), C.GLuint(id))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glResumeTransformFeedback.xml
+func (gl *GL) ResumeTransformFeedback() {
+ C.gl4_1core_glResumeTransformFeedback(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPauseTransformFeedback.xml
+func (gl *GL) PauseTransformFeedback() {
+ C.gl4_1core_glPauseTransformFeedback(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsTransformFeedback.xml
+func (gl *GL) IsTransformFeedback(id uint32) bool {
+ glresult := C.gl4_1core_glIsTransformFeedback(gl.funcs, C.GLuint(id))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGenTransformFeedbacks.xml
+func (gl *GL) GenTransformFeedbacks(n int, ids []uint32) {
+ C.gl4_1core_glGenTransformFeedbacks(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&ids[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDeleteTransformFeedbacks.xml
+func (gl *GL) DeleteTransformFeedbacks(n int, ids []uint32) {
+ C.gl4_1core_glDeleteTransformFeedbacks(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&ids[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindTransformFeedback.xml
+func (gl *GL) BindTransformFeedback(target glbase.Enum, id uint32) {
+ C.gl4_1core_glBindTransformFeedback(gl.funcs, C.GLenum(target), C.GLuint(id))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPatchParameterfv.xml
+func (gl *GL) PatchParameterfv(pname glbase.Enum, values []float32) {
+ C.gl4_1core_glPatchParameterfv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPatchParameteri.xml
+func (gl *GL) PatchParameteri(pname glbase.Enum, value int32) {
+ C.gl4_1core_glPatchParameteri(gl.funcs, C.GLenum(pname), C.GLint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetProgramStageiv.xml
+func (gl *GL) GetProgramStageiv(program glbase.Program, shadertype, pname glbase.Enum, values []int32) {
+ C.gl4_1core_glGetProgramStageiv(gl.funcs, C.GLuint(program), C.GLenum(shadertype), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetUniformSubroutineuiv.xml
+func (gl *GL) GetUniformSubroutineuiv(shadertype glbase.Enum, location glbase.Uniform, params []uint32) {
+ C.gl4_1core_glGetUniformSubroutineuiv(gl.funcs, C.GLenum(shadertype), C.GLint(location), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformSubroutinesuiv.xml
+func (gl *GL) UniformSubroutinesuiv(shadertype glbase.Enum, count int, value []uint32) {
+ C.gl4_1core_glUniformSubroutinesuiv(gl.funcs, C.GLenum(shadertype), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveSubroutineName.xml
+func (gl *GL) GetActiveSubroutineName(program glbase.Program, shadertype glbase.Enum, index uint32, bufSize int32, length []int32, name []byte) {
+ C.gl4_1core_glGetActiveSubroutineName(gl.funcs, C.GLuint(program), C.GLenum(shadertype), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveSubroutineUniformName.xml
+func (gl *GL) GetActiveSubroutineUniformName(program glbase.Program, shadertype glbase.Enum, index uint32, bufSize int32, length []int32, name []byte) {
+ C.gl4_1core_glGetActiveSubroutineUniformName(gl.funcs, C.GLuint(program), C.GLenum(shadertype), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveSubroutineUniformiv.xml
+func (gl *GL) GetActiveSubroutineUniformiv(program glbase.Program, shadertype glbase.Enum, index uint32, pname glbase.Enum, values []int32) {
+ C.gl4_1core_glGetActiveSubroutineUniformiv(gl.funcs, C.GLuint(program), C.GLenum(shadertype), C.GLuint(index), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetSubroutineIndex.xml
+func (gl *GL) GetSubroutineIndex(program glbase.Program, shadertype glbase.Enum, name []byte) uint32 {
+ glresult := C.gl4_1core_glGetSubroutineIndex(gl.funcs, C.GLuint(program), C.GLenum(shadertype), (*C.GLchar)(unsafe.Pointer(&name[0])))
+ return uint32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetSubroutineUniformLocation.xml
+func (gl *GL) GetSubroutineUniformLocation(program glbase.Program, shadertype glbase.Enum, name []byte) int32 {
+ glresult := C.gl4_1core_glGetSubroutineUniformLocation(gl.funcs, C.GLuint(program), C.GLenum(shadertype), (*C.GLchar)(unsafe.Pointer(&name[0])))
+ return int32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetUniformdv.xml
+func (gl *GL) GetUniformdv(program glbase.Program, location glbase.Uniform, params []float64) {
+ C.gl4_1core_glGetUniformdv(gl.funcs, C.GLuint(program), C.GLint(location), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix4x3dv.xml
+func (gl *GL) UniformMatrix4x3dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_1core_glUniformMatrix4x3dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix4x2dv.xml
+func (gl *GL) UniformMatrix4x2dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_1core_glUniformMatrix4x2dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix3x4dv.xml
+func (gl *GL) UniformMatrix3x4dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_1core_glUniformMatrix3x4dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix3x2dv.xml
+func (gl *GL) UniformMatrix3x2dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_1core_glUniformMatrix3x2dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix2x4dv.xml
+func (gl *GL) UniformMatrix2x4dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_1core_glUniformMatrix2x4dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix2x3dv.xml
+func (gl *GL) UniformMatrix2x3dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_1core_glUniformMatrix2x3dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix4dv.xml
+func (gl *GL) UniformMatrix4dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_1core_glUniformMatrix4dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix3dv.xml
+func (gl *GL) UniformMatrix3dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_1core_glUniformMatrix3dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix2dv.xml
+func (gl *GL) UniformMatrix2dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_1core_glUniformMatrix2dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform4dv.xml
+func (gl *GL) Uniform4dv(location glbase.Uniform, count int, value []float64) {
+ C.gl4_1core_glUniform4dv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform3dv.xml
+func (gl *GL) Uniform3dv(location glbase.Uniform, count int, value []float64) {
+ C.gl4_1core_glUniform3dv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform2dv.xml
+func (gl *GL) Uniform2dv(location glbase.Uniform, count int, value []float64) {
+ C.gl4_1core_glUniform2dv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform1dv.xml
+func (gl *GL) Uniform1dv(location glbase.Uniform, count int, value []float64) {
+ C.gl4_1core_glUniform1dv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform4d.xml
+func (gl *GL) Uniform4d(location glbase.Uniform, v0, v1, v2, v3 float64) {
+ C.gl4_1core_glUniform4d(gl.funcs, C.GLint(location), C.GLdouble(v0), C.GLdouble(v1), C.GLdouble(v2), C.GLdouble(v3))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform3d.xml
+func (gl *GL) Uniform3d(location glbase.Uniform, v0, v1, v2 float64) {
+ C.gl4_1core_glUniform3d(gl.funcs, C.GLint(location), C.GLdouble(v0), C.GLdouble(v1), C.GLdouble(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform2d.xml
+func (gl *GL) Uniform2d(location glbase.Uniform, v0, v1 float64) {
+ C.gl4_1core_glUniform2d(gl.funcs, C.GLint(location), C.GLdouble(v0), C.GLdouble(v1))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform1d.xml
+func (gl *GL) Uniform1d(location glbase.Uniform, v0 float64) {
+ C.gl4_1core_glUniform1d(gl.funcs, C.GLint(location), C.GLdouble(v0))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawElementsIndirect.xml
+func (gl *GL) DrawElementsIndirect(mode, gltype glbase.Enum, indirect interface{}) {
+ var indirect_ptr unsafe.Pointer
+ var indirect_v = reflect.ValueOf(indirect)
+ if indirect != nil && indirect_v.Kind() != reflect.Slice {
+ panic("parameter indirect must be a slice")
+ }
+ if indirect != nil {
+ indirect_ptr = unsafe.Pointer(indirect_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1core_glDrawElementsIndirect(gl.funcs, C.GLenum(mode), C.GLenum(gltype), indirect_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawArraysIndirect.xml
+func (gl *GL) DrawArraysIndirect(mode glbase.Enum, indirect interface{}) {
+ var indirect_ptr unsafe.Pointer
+ var indirect_v = reflect.ValueOf(indirect)
+ if indirect != nil && indirect_v.Kind() != reflect.Slice {
+ panic("parameter indirect must be a slice")
+ }
+ if indirect != nil {
+ indirect_ptr = unsafe.Pointer(indirect_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1core_glDrawArraysIndirect(gl.funcs, C.GLenum(mode), indirect_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendFuncSeparatei.xml
+func (gl *GL) BlendFuncSeparatei(buf uint32, srcRGB, dstRGB, srcAlpha, dstAlpha glbase.Enum) {
+ C.gl4_1core_glBlendFuncSeparatei(gl.funcs, C.GLuint(buf), C.GLenum(srcRGB), C.GLenum(dstRGB), C.GLenum(srcAlpha), C.GLenum(dstAlpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendFunci.xml
+func (gl *GL) BlendFunci(buf uint32, src, dst glbase.Enum) {
+ C.gl4_1core_glBlendFunci(gl.funcs, C.GLuint(buf), C.GLenum(src), C.GLenum(dst))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendEquationSeparatei.xml
+func (gl *GL) BlendEquationSeparatei(buf uint32, modeRGB, modeAlpha glbase.Enum) {
+ C.gl4_1core_glBlendEquationSeparatei(gl.funcs, C.GLuint(buf), C.GLenum(modeRGB), C.GLenum(modeAlpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendEquationi.xml
+func (gl *GL) BlendEquationi(buf uint32, mode glbase.Enum) {
+ C.gl4_1core_glBlendEquationi(gl.funcs, C.GLuint(buf), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMinSampleShading.xml
+func (gl *GL) MinSampleShading(value float32) {
+ C.gl4_1core_glMinSampleShading(gl.funcs, C.GLfloat(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetDoublei_v.xml
+func (gl *GL) GetDoublei_v(target glbase.Enum, index uint32, data []float64) {
+ C.gl4_1core_glGetDoublei_v(gl.funcs, C.GLenum(target), C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&data[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetFloati_v.xml
+func (gl *GL) GetFloati_v(target glbase.Enum, index uint32, data []float32) {
+ C.gl4_1core_glGetFloati_v(gl.funcs, C.GLenum(target), C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&data[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDepthRangeIndexed.xml
+func (gl *GL) DepthRangeIndexed(index uint32, n, f float64) {
+ C.gl4_1core_glDepthRangeIndexed(gl.funcs, C.GLuint(index), C.GLdouble(n), C.GLdouble(f))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDepthRangeArrayv.xml
+func (gl *GL) DepthRangeArrayv(first uint32, count int, v []float64) {
+ C.gl4_1core_glDepthRangeArrayv(gl.funcs, C.GLuint(first), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glScissorIndexedv.xml
+func (gl *GL) ScissorIndexedv(index uint32, v []int32) {
+ C.gl4_1core_glScissorIndexedv(gl.funcs, C.GLuint(index), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glScissorIndexed.xml
+func (gl *GL) ScissorIndexed(index uint32, left, bottom int32, width, height int) {
+ C.gl4_1core_glScissorIndexed(gl.funcs, C.GLuint(index), C.GLint(left), C.GLint(bottom), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glScissorArrayv.xml
+func (gl *GL) ScissorArrayv(first uint32, count int, v []int32) {
+ C.gl4_1core_glScissorArrayv(gl.funcs, C.GLuint(first), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glViewportIndexedfv.xml
+func (gl *GL) ViewportIndexedfv(index uint32, v []float32) {
+ C.gl4_1core_glViewportIndexedfv(gl.funcs, C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glViewportIndexedf.xml
+func (gl *GL) ViewportIndexedf(index uint32, x, y, w, h float32) {
+ C.gl4_1core_glViewportIndexedf(gl.funcs, C.GLuint(index), C.GLfloat(x), C.GLfloat(y), C.GLfloat(w), C.GLfloat(h))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glViewportArrayv.xml
+func (gl *GL) ViewportArrayv(first uint32, count int, v []float32) {
+ C.gl4_1core_glViewportArrayv(gl.funcs, C.GLuint(first), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetVertexAttribLdv.xml
+func (gl *GL) GetVertexAttribLdv(index glbase.Attrib, pname glbase.Enum, params []float64) {
+ C.gl4_1core_glGetVertexAttribLdv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribLPointer.xml
+func (gl *GL) VertexAttribLPointer(index glbase.Attrib, size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1core_glVertexAttribLPointer(gl.funcs, C.GLuint(index), C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribL4dv.xml
+func (gl *GL) VertexAttribL4dv(index glbase.Attrib, v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1core_glVertexAttribL4dv(gl.funcs, C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribL3dv.xml
+func (gl *GL) VertexAttribL3dv(index glbase.Attrib, v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1core_glVertexAttribL3dv(gl.funcs, C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribL2dv.xml
+func (gl *GL) VertexAttribL2dv(index glbase.Attrib, v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_1core_glVertexAttribL2dv(gl.funcs, C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribL1dv.xml
+func (gl *GL) VertexAttribL1dv(index glbase.Attrib, v []float64) {
+ C.gl4_1core_glVertexAttribL1dv(gl.funcs, C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribL4d.xml
+func (gl *GL) VertexAttribL4d(index glbase.Attrib, x, y, z, w float64) {
+ C.gl4_1core_glVertexAttribL4d(gl.funcs, C.GLuint(index), C.GLdouble(x), C.GLdouble(y), C.GLdouble(z), C.GLdouble(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribL3d.xml
+func (gl *GL) VertexAttribL3d(index glbase.Attrib, x, y, z float64) {
+ C.gl4_1core_glVertexAttribL3d(gl.funcs, C.GLuint(index), C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribL2d.xml
+func (gl *GL) VertexAttribL2d(index glbase.Attrib, x, y float64) {
+ C.gl4_1core_glVertexAttribL2d(gl.funcs, C.GLuint(index), C.GLdouble(x), C.GLdouble(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribL1d.xml
+func (gl *GL) VertexAttribL1d(index glbase.Attrib, x float64) {
+ C.gl4_1core_glVertexAttribL1d(gl.funcs, C.GLuint(index), C.GLdouble(x))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetProgramPipelineInfoLog.xml
+func (gl *GL) GetProgramPipelineInfoLog(pipeline uint32, bufSize int32, length []int32, infoLog []byte) {
+ C.gl4_1core_glGetProgramPipelineInfoLog(gl.funcs, C.GLuint(pipeline), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&infoLog[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glValidateProgramPipeline.xml
+func (gl *GL) ValidateProgramPipeline(pipeline uint32) {
+ C.gl4_1core_glValidateProgramPipeline(gl.funcs, C.GLuint(pipeline))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix4x3dv.xml
+func (gl *GL) ProgramUniformMatrix4x3dv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float64) {
+ if len(value) != 3 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_1core_glProgramUniformMatrix4x3dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix3x4dv.xml
+func (gl *GL) ProgramUniformMatrix3x4dv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float64) {
+ if len(value) != 4 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_1core_glProgramUniformMatrix3x4dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix4x2dv.xml
+func (gl *GL) ProgramUniformMatrix4x2dv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float64) {
+ if len(value) != 2 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_1core_glProgramUniformMatrix4x2dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix2x4dv.xml
+func (gl *GL) ProgramUniformMatrix2x4dv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float64) {
+ if len(value) != 4 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_1core_glProgramUniformMatrix2x4dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix3x2dv.xml
+func (gl *GL) ProgramUniformMatrix3x2dv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float64) {
+ if len(value) != 2 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_1core_glProgramUniformMatrix3x2dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix2x3dv.xml
+func (gl *GL) ProgramUniformMatrix2x3dv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float64) {
+ if len(value) != 3 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_1core_glProgramUniformMatrix2x3dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix4x3fv.xml
+func (gl *GL) ProgramUniformMatrix4x3fv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float32) {
+ if len(value) != 3 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_1core_glProgramUniformMatrix4x3fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix3x4fv.xml
+func (gl *GL) ProgramUniformMatrix3x4fv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float32) {
+ if len(value) != 4 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_1core_glProgramUniformMatrix3x4fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix4x2fv.xml
+func (gl *GL) ProgramUniformMatrix4x2fv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float32) {
+ if len(value) != 2 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_1core_glProgramUniformMatrix4x2fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix2x4fv.xml
+func (gl *GL) ProgramUniformMatrix2x4fv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float32) {
+ if len(value) != 4 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_1core_glProgramUniformMatrix2x4fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix3x2fv.xml
+func (gl *GL) ProgramUniformMatrix3x2fv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float32) {
+ if len(value) != 2 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_1core_glProgramUniformMatrix3x2fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix2x3fv.xml
+func (gl *GL) ProgramUniformMatrix2x3fv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float32) {
+ if len(value) != 3 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_1core_glProgramUniformMatrix2x3fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix4dv.xml
+func (gl *GL) ProgramUniformMatrix4dv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float64) {
+ if len(value) != 4 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_1core_glProgramUniformMatrix4dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix3dv.xml
+func (gl *GL) ProgramUniformMatrix3dv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float64) {
+ if len(value) != 3 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_1core_glProgramUniformMatrix3dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix2dv.xml
+func (gl *GL) ProgramUniformMatrix2dv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float64) {
+ if len(value) != 2 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_1core_glProgramUniformMatrix2dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix4fv.xml
+func (gl *GL) ProgramUniformMatrix4fv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float32) {
+ if len(value) != 4 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_1core_glProgramUniformMatrix4fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix3fv.xml
+func (gl *GL) ProgramUniformMatrix3fv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float32) {
+ if len(value) != 3 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_1core_glProgramUniformMatrix3fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix2fv.xml
+func (gl *GL) ProgramUniformMatrix2fv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float32) {
+ if len(value) != 2 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_1core_glProgramUniformMatrix2fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform4uiv.xml
+func (gl *GL) ProgramUniform4uiv(program glbase.Program, location glbase.Uniform, count int, value []uint32) {
+ C.gl4_1core_glProgramUniform4uiv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform4ui.xml
+func (gl *GL) ProgramUniform4ui(program glbase.Program, location glbase.Uniform, v0, v1, v2, v3 uint32) {
+ C.gl4_1core_glProgramUniform4ui(gl.funcs, C.GLuint(program), C.GLint(location), C.GLuint(v0), C.GLuint(v1), C.GLuint(v2), C.GLuint(v3))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform4dv.xml
+func (gl *GL) ProgramUniform4dv(program glbase.Program, location glbase.Uniform, count int, value []float64) {
+ if len(value) != 4 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_1core_glProgramUniform4dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform4d.xml
+func (gl *GL) ProgramUniform4d(program glbase.Program, location glbase.Uniform, v0, v1, v2, v3 float64) {
+ C.gl4_1core_glProgramUniform4d(gl.funcs, C.GLuint(program), C.GLint(location), C.GLdouble(v0), C.GLdouble(v1), C.GLdouble(v2), C.GLdouble(v3))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform4fv.xml
+func (gl *GL) ProgramUniform4fv(program glbase.Program, location glbase.Uniform, count int, value []float32) {
+ if len(value) != 4 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_1core_glProgramUniform4fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform4f.xml
+func (gl *GL) ProgramUniform4f(program glbase.Program, location glbase.Uniform, v0, v1, v2, v3 float32) {
+ C.gl4_1core_glProgramUniform4f(gl.funcs, C.GLuint(program), C.GLint(location), C.GLfloat(v0), C.GLfloat(v1), C.GLfloat(v2), C.GLfloat(v3))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform4iv.xml
+func (gl *GL) ProgramUniform4iv(program glbase.Program, location glbase.Uniform, count int, value []int32) {
+ if len(value) != 4 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_1core_glProgramUniform4iv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform4i.xml
+func (gl *GL) ProgramUniform4i(program glbase.Program, location glbase.Uniform, v0, v1, v2, v3 int32) {
+ C.gl4_1core_glProgramUniform4i(gl.funcs, C.GLuint(program), C.GLint(location), C.GLint(v0), C.GLint(v1), C.GLint(v2), C.GLint(v3))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform3uiv.xml
+func (gl *GL) ProgramUniform3uiv(program glbase.Program, location glbase.Uniform, count int, value []uint32) {
+ C.gl4_1core_glProgramUniform3uiv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform3ui.xml
+func (gl *GL) ProgramUniform3ui(program glbase.Program, location glbase.Uniform, v0, v1, v2 uint32) {
+ C.gl4_1core_glProgramUniform3ui(gl.funcs, C.GLuint(program), C.GLint(location), C.GLuint(v0), C.GLuint(v1), C.GLuint(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform3dv.xml
+func (gl *GL) ProgramUniform3dv(program glbase.Program, location glbase.Uniform, count int, value []float64) {
+ if len(value) != 3 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_1core_glProgramUniform3dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform3d.xml
+func (gl *GL) ProgramUniform3d(program glbase.Program, location glbase.Uniform, v0, v1, v2 float64) {
+ C.gl4_1core_glProgramUniform3d(gl.funcs, C.GLuint(program), C.GLint(location), C.GLdouble(v0), C.GLdouble(v1), C.GLdouble(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform3fv.xml
+func (gl *GL) ProgramUniform3fv(program glbase.Program, location glbase.Uniform, count int, value []float32) {
+ if len(value) != 3 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_1core_glProgramUniform3fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform3f.xml
+func (gl *GL) ProgramUniform3f(program glbase.Program, location glbase.Uniform, v0, v1, v2 float32) {
+ C.gl4_1core_glProgramUniform3f(gl.funcs, C.GLuint(program), C.GLint(location), C.GLfloat(v0), C.GLfloat(v1), C.GLfloat(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform3iv.xml
+func (gl *GL) ProgramUniform3iv(program glbase.Program, location glbase.Uniform, count int, value []int32) {
+ if len(value) != 3 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_1core_glProgramUniform3iv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform3i.xml
+func (gl *GL) ProgramUniform3i(program glbase.Program, location glbase.Uniform, v0, v1, v2 int32) {
+ C.gl4_1core_glProgramUniform3i(gl.funcs, C.GLuint(program), C.GLint(location), C.GLint(v0), C.GLint(v1), C.GLint(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform2uiv.xml
+func (gl *GL) ProgramUniform2uiv(program glbase.Program, location glbase.Uniform, count int, value []uint32) {
+ C.gl4_1core_glProgramUniform2uiv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform2ui.xml
+func (gl *GL) ProgramUniform2ui(program glbase.Program, location glbase.Uniform, v0, v1 uint32) {
+ C.gl4_1core_glProgramUniform2ui(gl.funcs, C.GLuint(program), C.GLint(location), C.GLuint(v0), C.GLuint(v1))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform2dv.xml
+func (gl *GL) ProgramUniform2dv(program glbase.Program, location glbase.Uniform, count int, value []float64) {
+ if len(value) != 2 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_1core_glProgramUniform2dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform2d.xml
+func (gl *GL) ProgramUniform2d(program glbase.Program, location glbase.Uniform, v0, v1 float64) {
+ C.gl4_1core_glProgramUniform2d(gl.funcs, C.GLuint(program), C.GLint(location), C.GLdouble(v0), C.GLdouble(v1))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform2fv.xml
+func (gl *GL) ProgramUniform2fv(program glbase.Program, location glbase.Uniform, count int, value []float32) {
+ if len(value) != 2 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_1core_glProgramUniform2fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform2f.xml
+func (gl *GL) ProgramUniform2f(program glbase.Program, location glbase.Uniform, v0, v1 float32) {
+ C.gl4_1core_glProgramUniform2f(gl.funcs, C.GLuint(program), C.GLint(location), C.GLfloat(v0), C.GLfloat(v1))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform2iv.xml
+func (gl *GL) ProgramUniform2iv(program glbase.Program, location glbase.Uniform, count int, value []int32) {
+ if len(value) != 2 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_1core_glProgramUniform2iv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform2i.xml
+func (gl *GL) ProgramUniform2i(program glbase.Program, location glbase.Uniform, v0, v1 int32) {
+ C.gl4_1core_glProgramUniform2i(gl.funcs, C.GLuint(program), C.GLint(location), C.GLint(v0), C.GLint(v1))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform1uiv.xml
+func (gl *GL) ProgramUniform1uiv(program glbase.Program, location glbase.Uniform, count int, value []uint32) {
+ C.gl4_1core_glProgramUniform1uiv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform1ui.xml
+func (gl *GL) ProgramUniform1ui(program glbase.Program, location glbase.Uniform, v0 uint32) {
+ C.gl4_1core_glProgramUniform1ui(gl.funcs, C.GLuint(program), C.GLint(location), C.GLuint(v0))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform1dv.xml
+func (gl *GL) ProgramUniform1dv(program glbase.Program, location glbase.Uniform, count int, value []float64) {
+ C.gl4_1core_glProgramUniform1dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform1d.xml
+func (gl *GL) ProgramUniform1d(program glbase.Program, location glbase.Uniform, v0 float64) {
+ C.gl4_1core_glProgramUniform1d(gl.funcs, C.GLuint(program), C.GLint(location), C.GLdouble(v0))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform1fv.xml
+func (gl *GL) ProgramUniform1fv(program glbase.Program, location glbase.Uniform, count int, value []float32) {
+ C.gl4_1core_glProgramUniform1fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform1f.xml
+func (gl *GL) ProgramUniform1f(program glbase.Program, location glbase.Uniform, v0 float32) {
+ C.gl4_1core_glProgramUniform1f(gl.funcs, C.GLuint(program), C.GLint(location), C.GLfloat(v0))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform1iv.xml
+func (gl *GL) ProgramUniform1iv(program glbase.Program, location glbase.Uniform, count int, value []int32) {
+ C.gl4_1core_glProgramUniform1iv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform1i.xml
+func (gl *GL) ProgramUniform1i(program glbase.Program, location glbase.Uniform, v0 int32) {
+ C.gl4_1core_glProgramUniform1i(gl.funcs, C.GLuint(program), C.GLint(location), C.GLint(v0))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetProgramPipelineiv.xml
+func (gl *GL) GetProgramPipelineiv(pipeline uint32, pname glbase.Enum, params []int32) {
+ C.gl4_1core_glGetProgramPipelineiv(gl.funcs, C.GLuint(pipeline), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsProgramPipeline.xml
+func (gl *GL) IsProgramPipeline(pipeline uint32) bool {
+ glresult := C.gl4_1core_glIsProgramPipeline(gl.funcs, C.GLuint(pipeline))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGenProgramPipelines.xml
+func (gl *GL) GenProgramPipelines(n int, pipelines []uint32) {
+ C.gl4_1core_glGenProgramPipelines(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&pipelines[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDeleteProgramPipelines.xml
+func (gl *GL) DeleteProgramPipelines(n int, pipelines []uint32) {
+ C.gl4_1core_glDeleteProgramPipelines(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&pipelines[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindProgramPipeline.xml
+func (gl *GL) BindProgramPipeline(pipeline uint32) {
+ C.gl4_1core_glBindProgramPipeline(gl.funcs, C.GLuint(pipeline))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glActiveShaderProgram.xml
+func (gl *GL) ActiveShaderProgram(pipeline uint32, program glbase.Program) {
+ C.gl4_1core_glActiveShaderProgram(gl.funcs, C.GLuint(pipeline), C.GLuint(program))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUseProgramStages.xml
+func (gl *GL) UseProgramStages(pipeline uint32, stages glbase.Bitfield, program glbase.Program) {
+ C.gl4_1core_glUseProgramStages(gl.funcs, C.GLuint(pipeline), C.GLbitfield(stages), C.GLuint(program))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramParameteri.xml
+func (gl *GL) ProgramParameteri(program glbase.Program, pname glbase.Enum, value int32) {
+ C.gl4_1core_glProgramParameteri(gl.funcs, C.GLuint(program), C.GLenum(pname), C.GLint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramBinary.xml
+func (gl *GL) ProgramBinary(program glbase.Program, binaryFormat glbase.Enum, binary interface{}, length int32) {
+ var binary_ptr unsafe.Pointer
+ var binary_v = reflect.ValueOf(binary)
+ if binary != nil && binary_v.Kind() != reflect.Slice {
+ panic("parameter binary must be a slice")
+ }
+ if binary != nil {
+ binary_ptr = unsafe.Pointer(binary_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1core_glProgramBinary(gl.funcs, C.GLuint(program), C.GLenum(binaryFormat), binary_ptr, C.GLsizei(length))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetProgramBinary.xml
+func (gl *GL) GetProgramBinary(program glbase.Program, bufSize int32, length []int32, binaryFormat []glbase.Enum, binary interface{}) {
+ var binary_ptr unsafe.Pointer
+ var binary_v = reflect.ValueOf(binary)
+ if binary != nil && binary_v.Kind() != reflect.Slice {
+ panic("parameter binary must be a slice")
+ }
+ if binary != nil {
+ binary_ptr = unsafe.Pointer(binary_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1core_glGetProgramBinary(gl.funcs, C.GLuint(program), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLenum)(unsafe.Pointer(&binaryFormat[0])), binary_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearDepthf.xml
+func (gl *GL) ClearDepthf(dd float32) {
+ C.gl4_1core_glClearDepthf(gl.funcs, C.GLfloat(dd))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDepthRangef.xml
+func (gl *GL) DepthRangef(n, f float32) {
+ C.gl4_1core_glDepthRangef(gl.funcs, C.GLfloat(n), C.GLfloat(f))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetShaderPrecisionFormat.xml
+func (gl *GL) GetShaderPrecisionFormat(shadertype, precisionType glbase.Enum, range_, precision []int32) {
+ C.gl4_1core_glGetShaderPrecisionFormat(gl.funcs, C.GLenum(shadertype), C.GLenum(precisionType), (*C.GLint)(unsafe.Pointer(&range_[0])), (*C.GLint)(unsafe.Pointer(&precision[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glShaderBinary.xml
+func (gl *GL) ShaderBinary(count int, shaders []glbase.Shader, binaryFormat glbase.Enum, binary interface{}, length int32) {
+ var binary_ptr unsafe.Pointer
+ var binary_v = reflect.ValueOf(binary)
+ if binary != nil && binary_v.Kind() != reflect.Slice {
+ panic("parameter binary must be a slice")
+ }
+ if binary != nil {
+ binary_ptr = unsafe.Pointer(binary_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_1core_glShaderBinary(gl.funcs, C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&shaders[0])), C.GLenum(binaryFormat), binary_ptr, C.GLsizei(length))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glReleaseShaderCompiler.xml
+func (gl *GL) ReleaseShaderCompiler() {
+ C.gl4_1core_glReleaseShaderCompiler(gl.funcs)
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.2compat/funcs.cpp b/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.2compat/funcs.cpp
new file mode 100644
index 000000000..6101e99de
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.2compat/funcs.cpp
@@ -0,0 +1,5358 @@
+
+// ** file automatically generated by glgen -- do not edit manually **
+
+#include <QOpenGLContext>
+#include <QtGui/qopenglfunctions_4_2_compatibility.h>
+
+#include "funcs.h"
+
+void *gl4_2compat_funcs() {
+ QOpenGLFunctions_4_2_Compatibility* funcs = QOpenGLContext::currentContext()->versionFunctions<QOpenGLFunctions_4_2_Compatibility>();
+ if (!funcs) {
+ return 0;
+ }
+ funcs->initializeOpenGLFunctions();
+ return funcs;
+}
+
+
+void gl4_2compat_glViewport(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glViewport(x, y, width, height);
+}
+
+void gl4_2compat_glDepthRange(void *_glfuncs, GLdouble nearVal, GLdouble farVal)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDepthRange(nearVal, farVal);
+}
+
+GLboolean gl4_2compat_glIsEnabled(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsEnabled(cap);
+}
+
+void gl4_2compat_glGetTexLevelParameteriv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexLevelParameteriv(target, level, pname, params);
+}
+
+void gl4_2compat_glGetTexLevelParameterfv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexLevelParameterfv(target, level, pname, params);
+}
+
+void gl4_2compat_glGetTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexParameteriv(target, pname, params);
+}
+
+void gl4_2compat_glGetTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexParameterfv(target, pname, params);
+}
+
+void gl4_2compat_glGetTexImage(void *_glfuncs, GLenum target, GLint level, GLenum format, GLenum gltype, GLvoid* pixels)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexImage(target, level, format, gltype, pixels);
+}
+
+void gl4_2compat_glGetIntegerv(void *_glfuncs, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetIntegerv(pname, params);
+}
+
+void gl4_2compat_glGetFloatv(void *_glfuncs, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetFloatv(pname, params);
+}
+
+GLenum gl4_2compat_glGetError(void *_glfuncs)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ return _qglfuncs->glGetError();
+}
+
+void gl4_2compat_glGetDoublev(void *_glfuncs, GLenum pname, GLdouble* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetDoublev(pname, params);
+}
+
+void gl4_2compat_glGetBooleanv(void *_glfuncs, GLenum pname, GLboolean* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetBooleanv(pname, params);
+}
+
+void gl4_2compat_glReadPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum gltype, GLvoid* pixels)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glReadPixels(x, y, width, height, format, gltype, pixels);
+}
+
+void gl4_2compat_glReadBuffer(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glReadBuffer(mode);
+}
+
+void gl4_2compat_glPixelStorei(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glPixelStorei(pname, param);
+}
+
+void gl4_2compat_glPixelStoref(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glPixelStoref(pname, param);
+}
+
+void gl4_2compat_glDepthFunc(void *_glfuncs, GLenum glfunc)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDepthFunc(glfunc);
+}
+
+void gl4_2compat_glStencilOp(void *_glfuncs, GLenum fail, GLenum zfail, GLenum zpass)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glStencilOp(fail, zfail, zpass);
+}
+
+void gl4_2compat_glStencilFunc(void *_glfuncs, GLenum glfunc, GLint ref, GLuint mask)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glStencilFunc(glfunc, ref, mask);
+}
+
+void gl4_2compat_glLogicOp(void *_glfuncs, GLenum opcode)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glLogicOp(opcode);
+}
+
+void gl4_2compat_glBlendFunc(void *_glfuncs, GLenum sfactor, GLenum dfactor)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glBlendFunc(sfactor, dfactor);
+}
+
+void gl4_2compat_glFlush(void *_glfuncs)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glFlush();
+}
+
+void gl4_2compat_glFinish(void *_glfuncs)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glFinish();
+}
+
+void gl4_2compat_glEnable(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glEnable(cap);
+}
+
+void gl4_2compat_glDisable(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDisable(cap);
+}
+
+void gl4_2compat_glDepthMask(void *_glfuncs, GLboolean flag)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDepthMask(flag);
+}
+
+void gl4_2compat_glColorMask(void *_glfuncs, GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorMask(red, green, blue, alpha);
+}
+
+void gl4_2compat_glStencilMask(void *_glfuncs, GLuint mask)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glStencilMask(mask);
+}
+
+void gl4_2compat_glClearDepth(void *_glfuncs, GLdouble depth)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glClearDepth(depth);
+}
+
+void gl4_2compat_glClearStencil(void *_glfuncs, GLint s)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glClearStencil(s);
+}
+
+void gl4_2compat_glClearColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glClearColor(red, green, blue, alpha);
+}
+
+void gl4_2compat_glClear(void *_glfuncs, GLbitfield mask)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glClear(mask);
+}
+
+void gl4_2compat_glDrawBuffer(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawBuffer(mode);
+}
+
+void gl4_2compat_glTexImage2D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexImage2D(target, level, internalFormat, width, height, border, format, gltype, pixels);
+}
+
+void gl4_2compat_glTexImage1D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexImage1D(target, level, internalFormat, width, border, format, gltype, pixels);
+}
+
+void gl4_2compat_glTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexParameteriv(target, pname, params);
+}
+
+void gl4_2compat_glTexParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexParameteri(target, pname, param);
+}
+
+void gl4_2compat_glTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexParameterfv(target, pname, params);
+}
+
+void gl4_2compat_glTexParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexParameterf(target, pname, param);
+}
+
+void gl4_2compat_glScissor(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glScissor(x, y, width, height);
+}
+
+void gl4_2compat_glPolygonMode(void *_glfuncs, GLenum face, GLenum mode)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glPolygonMode(face, mode);
+}
+
+void gl4_2compat_glPointSize(void *_glfuncs, GLfloat size)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glPointSize(size);
+}
+
+void gl4_2compat_glLineWidth(void *_glfuncs, GLfloat width)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glLineWidth(width);
+}
+
+void gl4_2compat_glHint(void *_glfuncs, GLenum target, GLenum mode)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glHint(target, mode);
+}
+
+void gl4_2compat_glFrontFace(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glFrontFace(mode);
+}
+
+void gl4_2compat_glCullFace(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glCullFace(mode);
+}
+
+void gl4_2compat_glIndexubv(void *_glfuncs, const GLubyte* c)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexubv(c);
+}
+
+void gl4_2compat_glIndexub(void *_glfuncs, GLubyte c)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexub(c);
+}
+
+GLboolean gl4_2compat_glIsTexture(void *_glfuncs, GLuint texture)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsTexture(texture);
+}
+
+void gl4_2compat_glGenTextures(void *_glfuncs, GLsizei n, GLuint* textures)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGenTextures(n, textures);
+}
+
+void gl4_2compat_glDeleteTextures(void *_glfuncs, GLsizei n, const GLuint* textures)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteTextures(n, textures);
+}
+
+void gl4_2compat_glBindTexture(void *_glfuncs, GLenum target, GLuint texture)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindTexture(target, texture);
+}
+
+void gl4_2compat_glTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexSubImage2D(target, level, xoffset, yoffset, width, height, format, gltype, pixels);
+}
+
+void gl4_2compat_glTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexSubImage1D(target, level, xoffset, width, format, gltype, pixels);
+}
+
+void gl4_2compat_glCopyTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage2D(target, level, xoffset, yoffset, x, y, width, height);
+}
+
+void gl4_2compat_glCopyTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage1D(target, level, xoffset, x, y, width);
+}
+
+void gl4_2compat_glCopyTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyTexImage2D(target, level, internalFormat, x, y, width, height, border);
+}
+
+void gl4_2compat_glCopyTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLint border)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyTexImage1D(target, level, internalFormat, x, y, width, border);
+}
+
+void gl4_2compat_glPolygonOffset(void *_glfuncs, GLfloat factor, GLfloat units)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glPolygonOffset(factor, units);
+}
+
+void gl4_2compat_glDrawElements(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawElements(mode, count, gltype, indices);
+}
+
+void gl4_2compat_glDrawArrays(void *_glfuncs, GLenum mode, GLint first, GLsizei count)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawArrays(mode, first, count);
+}
+
+void gl4_2compat_glCopyTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage3D(target, level, xoffset, yoffset, zoffset, x, y, width, height);
+}
+
+void gl4_2compat_glTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, gltype, pixels);
+}
+
+void gl4_2compat_glTexImage3D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexImage3D(target, level, internalFormat, width, height, depth, border, format, gltype, pixels);
+}
+
+void gl4_2compat_glDrawRangeElements(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawRangeElements(mode, start, end, count, gltype, indices);
+}
+
+void gl4_2compat_glBlendEquation(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glBlendEquation(mode);
+}
+
+void gl4_2compat_glBlendColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glBlendColor(red, green, blue, alpha);
+}
+
+void gl4_2compat_glGetCompressedTexImage(void *_glfuncs, GLenum target, GLint level, GLvoid* img)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetCompressedTexImage(target, level, img);
+}
+
+void gl4_2compat_glCompressedTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glCompressedTexSubImage1D(target, level, xoffset, width, format, imageSize, data);
+}
+
+void gl4_2compat_glCompressedTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glCompressedTexSubImage2D(target, level, xoffset, yoffset, width, height, format, imageSize, data);
+}
+
+void gl4_2compat_glCompressedTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glCompressedTexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, imageSize, data);
+}
+
+void gl4_2compat_glCompressedTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glCompressedTexImage1D(target, level, internalFormat, width, border, imageSize, data);
+}
+
+void gl4_2compat_glCompressedTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glCompressedTexImage2D(target, level, internalFormat, width, height, border, imageSize, data);
+}
+
+void gl4_2compat_glCompressedTexImage3D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glCompressedTexImage3D(target, level, internalFormat, width, height, depth, border, imageSize, data);
+}
+
+void gl4_2compat_glSampleCoverage(void *_glfuncs, GLfloat value, GLboolean invert)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glSampleCoverage(value, invert);
+}
+
+void gl4_2compat_glActiveTexture(void *_glfuncs, GLenum texture)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glActiveTexture(texture);
+}
+
+void gl4_2compat_glPointParameteriv(void *_glfuncs, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glPointParameteriv(pname, params);
+}
+
+void gl4_2compat_glPointParameteri(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glPointParameteri(pname, param);
+}
+
+void gl4_2compat_glPointParameterfv(void *_glfuncs, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glPointParameterfv(pname, params);
+}
+
+void gl4_2compat_glPointParameterf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glPointParameterf(pname, param);
+}
+
+void gl4_2compat_glMultiDrawArrays(void *_glfuncs, GLenum mode, const GLint* first, const GLsizei* count, GLsizei drawcount)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiDrawArrays(mode, first, count, drawcount);
+}
+
+void gl4_2compat_glBlendFuncSeparate(void *_glfuncs, GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glBlendFuncSeparate(sfactorRGB, dfactorRGB, sfactorAlpha, dfactorAlpha);
+}
+
+void gl4_2compat_glGetBufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetBufferParameteriv(target, pname, params);
+}
+
+GLboolean gl4_2compat_glUnmapBuffer(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ return _qglfuncs->glUnmapBuffer(target);
+}
+
+void gl4_2compat_glGetBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, GLvoid* data)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetBufferSubData(target, offset, size, data);
+}
+
+void gl4_2compat_glBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid* data)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glBufferSubData(target, offset, size, data);
+}
+
+void gl4_2compat_glBufferData(void *_glfuncs, GLenum target, GLsizeiptr size, const GLvoid* data, GLenum usage)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glBufferData(target, size, data, usage);
+}
+
+GLboolean gl4_2compat_glIsBuffer(void *_glfuncs, GLuint buffer)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsBuffer(buffer);
+}
+
+void gl4_2compat_glGenBuffers(void *_glfuncs, GLsizei n, GLuint* buffers)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGenBuffers(n, buffers);
+}
+
+void gl4_2compat_glDeleteBuffers(void *_glfuncs, GLsizei n, const GLuint* buffers)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteBuffers(n, buffers);
+}
+
+void gl4_2compat_glBindBuffer(void *_glfuncs, GLenum target, GLuint buffer)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindBuffer(target, buffer);
+}
+
+void gl4_2compat_glGetQueryObjectuiv(void *_glfuncs, GLuint id, GLenum pname, GLuint* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetQueryObjectuiv(id, pname, params);
+}
+
+void gl4_2compat_glGetQueryObjectiv(void *_glfuncs, GLuint id, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetQueryObjectiv(id, pname, params);
+}
+
+void gl4_2compat_glGetQueryiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetQueryiv(target, pname, params);
+}
+
+void gl4_2compat_glEndQuery(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glEndQuery(target);
+}
+
+void gl4_2compat_glBeginQuery(void *_glfuncs, GLenum target, GLuint id)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glBeginQuery(target, id);
+}
+
+GLboolean gl4_2compat_glIsQuery(void *_glfuncs, GLuint id)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsQuery(id);
+}
+
+void gl4_2compat_glDeleteQueries(void *_glfuncs, GLsizei n, const GLuint* ids)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteQueries(n, ids);
+}
+
+void gl4_2compat_glGenQueries(void *_glfuncs, GLsizei n, GLuint* ids)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGenQueries(n, ids);
+}
+
+void gl4_2compat_glVertexAttribPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLboolean normalized, GLsizei stride, const GLvoid* offset)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribPointer(index, size, gltype, normalized, stride, offset);
+}
+
+void gl4_2compat_glValidateProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glValidateProgram(program);
+}
+
+void gl4_2compat_glUniformMatrix4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4fv(location, count, transpose, value);
+}
+
+void gl4_2compat_glUniformMatrix3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3fv(location, count, transpose, value);
+}
+
+void gl4_2compat_glUniformMatrix2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2fv(location, count, transpose, value);
+}
+
+void gl4_2compat_glUniform4iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform4iv(location, count, value);
+}
+
+void gl4_2compat_glUniform3iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform3iv(location, count, value);
+}
+
+void gl4_2compat_glUniform2iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform2iv(location, count, value);
+}
+
+void gl4_2compat_glUniform1iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform1iv(location, count, value);
+}
+
+void gl4_2compat_glUniform4fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform4fv(location, count, value);
+}
+
+void gl4_2compat_glUniform3fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform3fv(location, count, value);
+}
+
+void gl4_2compat_glUniform2fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform2fv(location, count, value);
+}
+
+void gl4_2compat_glUniform1fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform1fv(location, count, value);
+}
+
+void gl4_2compat_glUniform4i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2, GLint v3)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform4i(location, v0, v1, v2, v3);
+}
+
+void gl4_2compat_glUniform3i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform3i(location, v0, v1, v2);
+}
+
+void gl4_2compat_glUniform2i(void *_glfuncs, GLint location, GLint v0, GLint v1)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform2i(location, v0, v1);
+}
+
+void gl4_2compat_glUniform1i(void *_glfuncs, GLint location, GLint v0)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform1i(location, v0);
+}
+
+void gl4_2compat_glUniform4f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform4f(location, v0, v1, v2, v3);
+}
+
+void gl4_2compat_glUniform3f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform3f(location, v0, v1, v2);
+}
+
+void gl4_2compat_glUniform2f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform2f(location, v0, v1);
+}
+
+void gl4_2compat_glUniform1f(void *_glfuncs, GLint location, GLfloat v0)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform1f(location, v0);
+}
+
+void gl4_2compat_glUseProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUseProgram(program);
+}
+
+void gl4_2compat_glShaderSource(void *_glfuncs, GLuint shader, GLsizei count, const GLchar** source, const GLint* length)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glShaderSource(shader, count, source, length);
+}
+
+void gl4_2compat_glLinkProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glLinkProgram(program);
+}
+
+GLboolean gl4_2compat_glIsShader(void *_glfuncs, GLuint shader)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsShader(shader);
+}
+
+GLboolean gl4_2compat_glIsProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsProgram(program);
+}
+
+void gl4_2compat_glGetVertexAttribiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribiv(index, pname, params);
+}
+
+void gl4_2compat_glGetVertexAttribfv(void *_glfuncs, GLuint index, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribfv(index, pname, params);
+}
+
+void gl4_2compat_glGetVertexAttribdv(void *_glfuncs, GLuint index, GLenum pname, GLdouble* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribdv(index, pname, params);
+}
+
+void gl4_2compat_glGetUniformiv(void *_glfuncs, GLuint program, GLint location, GLint* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetUniformiv(program, location, params);
+}
+
+void gl4_2compat_glGetUniformfv(void *_glfuncs, GLuint program, GLint location, GLfloat* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetUniformfv(program, location, params);
+}
+
+GLint gl4_2compat_glGetUniformLocation(void *_glfuncs, GLuint program, const GLchar* name)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ return _qglfuncs->glGetUniformLocation(program, name);
+}
+
+void gl4_2compat_glGetShaderSource(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* source)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetShaderSource(shader, bufSize, length, source);
+}
+
+void gl4_2compat_glGetShaderInfoLog(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* infoLog)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetShaderInfoLog(shader, bufSize, length, infoLog);
+}
+
+void gl4_2compat_glGetShaderiv(void *_glfuncs, GLuint shader, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetShaderiv(shader, pname, params);
+}
+
+void gl4_2compat_glGetProgramInfoLog(void *_glfuncs, GLuint program, GLsizei bufSize, GLsizei* length, GLchar* infoLog)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetProgramInfoLog(program, bufSize, length, infoLog);
+}
+
+void gl4_2compat_glGetProgramiv(void *_glfuncs, GLuint program, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetProgramiv(program, pname, params);
+}
+
+GLint gl4_2compat_glGetAttribLocation(void *_glfuncs, GLuint program, const GLchar* name)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ return _qglfuncs->glGetAttribLocation(program, name);
+}
+
+void gl4_2compat_glGetAttachedShaders(void *_glfuncs, GLuint program, GLsizei maxCount, GLsizei* count, GLuint* obj)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetAttachedShaders(program, maxCount, count, obj);
+}
+
+void gl4_2compat_glGetActiveUniform(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetActiveUniform(program, index, bufSize, length, size, gltype, name);
+}
+
+void gl4_2compat_glGetActiveAttrib(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetActiveAttrib(program, index, bufSize, length, size, gltype, name);
+}
+
+void gl4_2compat_glEnableVertexAttribArray(void *_glfuncs, GLuint index)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glEnableVertexAttribArray(index);
+}
+
+void gl4_2compat_glDisableVertexAttribArray(void *_glfuncs, GLuint index)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDisableVertexAttribArray(index);
+}
+
+void gl4_2compat_glDetachShader(void *_glfuncs, GLuint program, GLuint shader)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDetachShader(program, shader);
+}
+
+void gl4_2compat_glDeleteShader(void *_glfuncs, GLuint shader)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteShader(shader);
+}
+
+void gl4_2compat_glDeleteProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteProgram(program);
+}
+
+GLuint gl4_2compat_glCreateShader(void *_glfuncs, GLenum gltype)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ return _qglfuncs->glCreateShader(gltype);
+}
+
+GLuint gl4_2compat_glCreateProgram(void *_glfuncs)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ return _qglfuncs->glCreateProgram();
+}
+
+void gl4_2compat_glCompileShader(void *_glfuncs, GLuint shader)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glCompileShader(shader);
+}
+
+void gl4_2compat_glBindAttribLocation(void *_glfuncs, GLuint program, GLuint index, const GLchar* name)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindAttribLocation(program, index, name);
+}
+
+void gl4_2compat_glAttachShader(void *_glfuncs, GLuint program, GLuint shader)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glAttachShader(program, shader);
+}
+
+void gl4_2compat_glStencilMaskSeparate(void *_glfuncs, GLenum face, GLuint mask)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glStencilMaskSeparate(face, mask);
+}
+
+void gl4_2compat_glStencilFuncSeparate(void *_glfuncs, GLenum face, GLenum glfunc, GLint ref, GLuint mask)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glStencilFuncSeparate(face, glfunc, ref, mask);
+}
+
+void gl4_2compat_glStencilOpSeparate(void *_glfuncs, GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glStencilOpSeparate(face, sfail, dpfail, dppass);
+}
+
+void gl4_2compat_glDrawBuffers(void *_glfuncs, GLsizei n, const GLenum* bufs)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawBuffers(n, bufs);
+}
+
+void gl4_2compat_glBlendEquationSeparate(void *_glfuncs, GLenum modeRGB, GLenum modeAlpha)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glBlendEquationSeparate(modeRGB, modeAlpha);
+}
+
+void gl4_2compat_glUniformMatrix4x3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4x3fv(location, count, transpose, value);
+}
+
+void gl4_2compat_glUniformMatrix3x4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3x4fv(location, count, transpose, value);
+}
+
+void gl4_2compat_glUniformMatrix4x2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4x2fv(location, count, transpose, value);
+}
+
+void gl4_2compat_glUniformMatrix2x4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2x4fv(location, count, transpose, value);
+}
+
+void gl4_2compat_glUniformMatrix3x2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3x2fv(location, count, transpose, value);
+}
+
+void gl4_2compat_glUniformMatrix2x3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2x3fv(location, count, transpose, value);
+}
+
+GLboolean gl4_2compat_glIsVertexArray(void *_glfuncs, GLuint array)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsVertexArray(array);
+}
+
+void gl4_2compat_glGenVertexArrays(void *_glfuncs, GLsizei n, GLuint* arrays)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGenVertexArrays(n, arrays);
+}
+
+void gl4_2compat_glDeleteVertexArrays(void *_glfuncs, GLsizei n, const GLuint* arrays)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteVertexArrays(n, arrays);
+}
+
+void gl4_2compat_glBindVertexArray(void *_glfuncs, GLuint array)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindVertexArray(array);
+}
+
+void gl4_2compat_glFlushMappedBufferRange(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr length)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glFlushMappedBufferRange(target, offset, length);
+}
+
+void gl4_2compat_glFramebufferTextureLayer(void *_glfuncs, GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glFramebufferTextureLayer(target, attachment, texture, level, layer);
+}
+
+void gl4_2compat_glRenderbufferStorageMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLenum internalFormat, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRenderbufferStorageMultisample(target, samples, internalFormat, width, height);
+}
+
+void gl4_2compat_glBlitFramebuffer(void *_glfuncs, GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glBlitFramebuffer(srcX0, srcY0, srcX1, srcY1, dstX0, dstY0, dstX1, dstY1, mask, filter);
+}
+
+void gl4_2compat_glGenerateMipmap(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGenerateMipmap(target);
+}
+
+void gl4_2compat_glGetFramebufferAttachmentParameteriv(void *_glfuncs, GLenum target, GLenum attachment, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetFramebufferAttachmentParameteriv(target, attachment, pname, params);
+}
+
+void gl4_2compat_glFramebufferRenderbuffer(void *_glfuncs, GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glFramebufferRenderbuffer(target, attachment, renderbuffertarget, renderbuffer);
+}
+
+void gl4_2compat_glFramebufferTexture3D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glFramebufferTexture3D(target, attachment, textarget, texture, level, zoffset);
+}
+
+void gl4_2compat_glFramebufferTexture2D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glFramebufferTexture2D(target, attachment, textarget, texture, level);
+}
+
+void gl4_2compat_glFramebufferTexture1D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glFramebufferTexture1D(target, attachment, textarget, texture, level);
+}
+
+GLenum gl4_2compat_glCheckFramebufferStatus(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ return _qglfuncs->glCheckFramebufferStatus(target);
+}
+
+void gl4_2compat_glGenFramebuffers(void *_glfuncs, GLsizei n, GLuint* framebuffers)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGenFramebuffers(n, framebuffers);
+}
+
+void gl4_2compat_glDeleteFramebuffers(void *_glfuncs, GLsizei n, const GLuint* framebuffers)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteFramebuffers(n, framebuffers);
+}
+
+void gl4_2compat_glBindFramebuffer(void *_glfuncs, GLenum target, GLuint framebuffer)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindFramebuffer(target, framebuffer);
+}
+
+GLboolean gl4_2compat_glIsFramebuffer(void *_glfuncs, GLuint framebuffer)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsFramebuffer(framebuffer);
+}
+
+void gl4_2compat_glGetRenderbufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetRenderbufferParameteriv(target, pname, params);
+}
+
+void gl4_2compat_glRenderbufferStorage(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRenderbufferStorage(target, internalFormat, width, height);
+}
+
+void gl4_2compat_glGenRenderbuffers(void *_glfuncs, GLsizei n, GLuint* renderbuffers)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGenRenderbuffers(n, renderbuffers);
+}
+
+void gl4_2compat_glDeleteRenderbuffers(void *_glfuncs, GLsizei n, const GLuint* renderbuffers)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteRenderbuffers(n, renderbuffers);
+}
+
+void gl4_2compat_glBindRenderbuffer(void *_glfuncs, GLenum target, GLuint renderbuffer)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindRenderbuffer(target, renderbuffer);
+}
+
+GLboolean gl4_2compat_glIsRenderbuffer(void *_glfuncs, GLuint renderbuffer)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsRenderbuffer(renderbuffer);
+}
+
+void gl4_2compat_glClearBufferfi(void *_glfuncs, GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glClearBufferfi(buffer, drawbuffer, depth, stencil);
+}
+
+void gl4_2compat_glClearBufferfv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLfloat* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glClearBufferfv(buffer, drawbuffer, value);
+}
+
+void gl4_2compat_glClearBufferuiv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLuint* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glClearBufferuiv(buffer, drawbuffer, value);
+}
+
+void gl4_2compat_glClearBufferiv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLint* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glClearBufferiv(buffer, drawbuffer, value);
+}
+
+void gl4_2compat_glGetTexParameterIuiv(void *_glfuncs, GLenum target, GLenum pname, GLuint* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexParameterIuiv(target, pname, params);
+}
+
+void gl4_2compat_glGetTexParameterIiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexParameterIiv(target, pname, params);
+}
+
+void gl4_2compat_glTexParameterIuiv(void *_glfuncs, GLenum target, GLenum pname, const GLuint* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexParameterIuiv(target, pname, params);
+}
+
+void gl4_2compat_glTexParameterIiv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexParameterIiv(target, pname, params);
+}
+
+void gl4_2compat_glUniform4uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform4uiv(location, count, value);
+}
+
+void gl4_2compat_glUniform3uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform3uiv(location, count, value);
+}
+
+void gl4_2compat_glUniform2uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform2uiv(location, count, value);
+}
+
+void gl4_2compat_glUniform1uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform1uiv(location, count, value);
+}
+
+void gl4_2compat_glUniform4ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform4ui(location, v0, v1, v2, v3);
+}
+
+void gl4_2compat_glUniform3ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1, GLuint v2)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform3ui(location, v0, v1, v2);
+}
+
+void gl4_2compat_glUniform2ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform2ui(location, v0, v1);
+}
+
+void gl4_2compat_glUniform1ui(void *_glfuncs, GLint location, GLuint v0)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform1ui(location, v0);
+}
+
+GLint gl4_2compat_glGetFragDataLocation(void *_glfuncs, GLuint program, const GLchar* name)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ return _qglfuncs->glGetFragDataLocation(program, name);
+}
+
+void gl4_2compat_glBindFragDataLocation(void *_glfuncs, GLuint program, GLuint color, const GLchar* name)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindFragDataLocation(program, color, name);
+}
+
+void gl4_2compat_glGetUniformuiv(void *_glfuncs, GLuint program, GLint location, GLuint* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetUniformuiv(program, location, params);
+}
+
+void gl4_2compat_glGetVertexAttribIuiv(void *_glfuncs, GLuint index, GLenum pname, GLuint* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribIuiv(index, pname, params);
+}
+
+void gl4_2compat_glGetVertexAttribIiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribIiv(index, pname, params);
+}
+
+void gl4_2compat_glVertexAttribIPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribIPointer(index, size, gltype, stride, pointer);
+}
+
+void gl4_2compat_glEndConditionalRender(void *_glfuncs)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glEndConditionalRender();
+}
+
+void gl4_2compat_glBeginConditionalRender(void *_glfuncs, GLuint id, GLenum mode)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glBeginConditionalRender(id, mode);
+}
+
+void gl4_2compat_glClampColor(void *_glfuncs, GLenum target, GLenum clamp)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glClampColor(target, clamp);
+}
+
+void gl4_2compat_glGetTransformFeedbackVarying(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLsizei* size, GLenum* gltype, GLchar* name)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTransformFeedbackVarying(program, index, bufSize, length, size, gltype, name);
+}
+
+void gl4_2compat_glBindBufferBase(void *_glfuncs, GLenum target, GLuint index, GLuint buffer)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindBufferBase(target, index, buffer);
+}
+
+void gl4_2compat_glBindBufferRange(void *_glfuncs, GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindBufferRange(target, index, buffer, offset, size);
+}
+
+void gl4_2compat_glEndTransformFeedback(void *_glfuncs)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glEndTransformFeedback();
+}
+
+void gl4_2compat_glBeginTransformFeedback(void *_glfuncs, GLenum primitiveMode)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glBeginTransformFeedback(primitiveMode);
+}
+
+GLboolean gl4_2compat_glIsEnabledi(void *_glfuncs, GLenum target, GLuint index)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsEnabledi(target, index);
+}
+
+void gl4_2compat_glDisablei(void *_glfuncs, GLenum target, GLuint index)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDisablei(target, index);
+}
+
+void gl4_2compat_glEnablei(void *_glfuncs, GLenum target, GLuint index)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glEnablei(target, index);
+}
+
+void gl4_2compat_glGetIntegeri_v(void *_glfuncs, GLenum target, GLuint index, GLint* data)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetIntegeri_v(target, index, data);
+}
+
+void gl4_2compat_glGetBooleani_v(void *_glfuncs, GLenum target, GLuint index, GLboolean* data)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetBooleani_v(target, index, data);
+}
+
+void gl4_2compat_glColorMaski(void *_glfuncs, GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorMaski(index, r, g, b, a);
+}
+
+void gl4_2compat_glCopyBufferSubData(void *_glfuncs, GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyBufferSubData(readTarget, writeTarget, readOffset, writeOffset, size);
+}
+
+void gl4_2compat_glUniformBlockBinding(void *_glfuncs, GLuint program, GLuint v0, GLuint v1)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformBlockBinding(program, v0, v1);
+}
+
+void gl4_2compat_glGetActiveUniformBlockName(void *_glfuncs, GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei* length, GLchar* uniformBlockName)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetActiveUniformBlockName(program, uniformBlockIndex, bufSize, length, uniformBlockName);
+}
+
+void gl4_2compat_glGetActiveUniformBlockiv(void *_glfuncs, GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetActiveUniformBlockiv(program, uniformBlockIndex, pname, params);
+}
+
+GLuint gl4_2compat_glGetUniformBlockIndex(void *_glfuncs, GLuint program, const GLchar* uniformBlockName)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ return _qglfuncs->glGetUniformBlockIndex(program, uniformBlockName);
+}
+
+void gl4_2compat_glGetActiveUniformName(void *_glfuncs, GLuint program, GLuint uniformIndex, GLsizei bufSize, GLsizei* length, GLchar* uniformName)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetActiveUniformName(program, uniformIndex, bufSize, length, uniformName);
+}
+
+void gl4_2compat_glGetActiveUniformsiv(void *_glfuncs, GLuint program, GLsizei uniformCount, const GLuint* uniformIndices, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetActiveUniformsiv(program, uniformCount, uniformIndices, pname, params);
+}
+
+void gl4_2compat_glPrimitiveRestartIndex(void *_glfuncs, GLuint index)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glPrimitiveRestartIndex(index);
+}
+
+void gl4_2compat_glTexBuffer(void *_glfuncs, GLenum target, GLenum internalFormat, GLuint buffer)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexBuffer(target, internalFormat, buffer);
+}
+
+void gl4_2compat_glDrawElementsInstanced(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawElementsInstanced(mode, count, gltype, indices, instancecount);
+}
+
+void gl4_2compat_glDrawArraysInstanced(void *_glfuncs, GLenum mode, GLint first, GLsizei count, GLsizei instancecount)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawArraysInstanced(mode, first, count, instancecount);
+}
+
+void gl4_2compat_glSampleMaski(void *_glfuncs, GLuint index, GLbitfield mask)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glSampleMaski(index, mask);
+}
+
+void gl4_2compat_glGetMultisamplefv(void *_glfuncs, GLenum pname, GLuint index, GLfloat* val)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetMultisamplefv(pname, index, val);
+}
+
+void gl4_2compat_glTexImage3DMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexImage3DMultisample(target, samples, internalFormat, width, height, depth, fixedsamplelocations);
+}
+
+void gl4_2compat_glTexImage2DMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLint internalFormat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexImage2DMultisample(target, samples, internalFormat, width, height, fixedsamplelocations);
+}
+
+void gl4_2compat_glGetSynciv(void *_glfuncs, GLsync sync, GLenum pname, GLsizei bufSize, GLsizei* length, GLint* values)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetSynciv(sync, pname, bufSize, length, values);
+}
+
+void gl4_2compat_glGetInteger64v(void *_glfuncs, GLenum pname, GLint64* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetInteger64v(pname, params);
+}
+
+void gl4_2compat_glWaitSync(void *_glfuncs, GLsync sync, GLbitfield flags, GLuint64 timeout)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glWaitSync(sync, flags, timeout);
+}
+
+GLenum gl4_2compat_glClientWaitSync(void *_glfuncs, GLsync sync, GLbitfield flags, GLuint64 timeout)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ return _qglfuncs->glClientWaitSync(sync, flags, timeout);
+}
+
+void gl4_2compat_glDeleteSync(void *_glfuncs, GLsync sync)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteSync(sync);
+}
+
+GLboolean gl4_2compat_glIsSync(void *_glfuncs, GLsync sync)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsSync(sync);
+}
+
+GLsync gl4_2compat_glFenceSync(void *_glfuncs, GLenum condition, GLbitfield flags)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ return _qglfuncs->glFenceSync(condition, flags);
+}
+
+void gl4_2compat_glProvokingVertex(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glProvokingVertex(mode);
+}
+
+void gl4_2compat_glDrawElementsInstancedBaseVertex(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount, GLint basevertex)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawElementsInstancedBaseVertex(mode, count, gltype, indices, instancecount, basevertex);
+}
+
+void gl4_2compat_glDrawRangeElementsBaseVertex(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices, GLint basevertex)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawRangeElementsBaseVertex(mode, start, end, count, gltype, indices, basevertex);
+}
+
+void gl4_2compat_glDrawElementsBaseVertex(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLint basevertex)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawElementsBaseVertex(mode, count, gltype, indices, basevertex);
+}
+
+void gl4_2compat_glFramebufferTexture(void *_glfuncs, GLenum target, GLenum attachment, GLuint texture, GLint level)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glFramebufferTexture(target, attachment, texture, level);
+}
+
+void gl4_2compat_glGetBufferParameteri64v(void *_glfuncs, GLenum target, GLenum pname, GLint64* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetBufferParameteri64v(target, pname, params);
+}
+
+void gl4_2compat_glGetInteger64i_v(void *_glfuncs, GLenum target, GLuint index, GLint64* data)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetInteger64i_v(target, index, data);
+}
+
+void gl4_2compat_glVertexAttribP4uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribP4uiv(index, gltype, normalized, value);
+}
+
+void gl4_2compat_glVertexAttribP4ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribP4ui(index, gltype, normalized, value);
+}
+
+void gl4_2compat_glVertexAttribP3uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribP3uiv(index, gltype, normalized, value);
+}
+
+void gl4_2compat_glVertexAttribP3ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribP3ui(index, gltype, normalized, value);
+}
+
+void gl4_2compat_glVertexAttribP2uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribP2uiv(index, gltype, normalized, value);
+}
+
+void gl4_2compat_glVertexAttribP2ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribP2ui(index, gltype, normalized, value);
+}
+
+void gl4_2compat_glVertexAttribP1uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribP1uiv(index, gltype, normalized, value);
+}
+
+void gl4_2compat_glVertexAttribP1ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribP1ui(index, gltype, normalized, value);
+}
+
+void gl4_2compat_glSecondaryColorP3uiv(void *_glfuncs, GLenum gltype, const GLuint* color)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColorP3uiv(gltype, color);
+}
+
+void gl4_2compat_glSecondaryColorP3ui(void *_glfuncs, GLenum gltype, GLuint color)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColorP3ui(gltype, color);
+}
+
+void gl4_2compat_glColorP4uiv(void *_glfuncs, GLenum gltype, const GLuint* color)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorP4uiv(gltype, color);
+}
+
+void gl4_2compat_glColorP4ui(void *_glfuncs, GLenum gltype, GLuint color)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorP4ui(gltype, color);
+}
+
+void gl4_2compat_glColorP3uiv(void *_glfuncs, GLenum gltype, const GLuint* color)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorP3uiv(gltype, color);
+}
+
+void gl4_2compat_glColorP3ui(void *_glfuncs, GLenum gltype, GLuint color)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorP3ui(gltype, color);
+}
+
+void gl4_2compat_glNormalP3uiv(void *_glfuncs, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormalP3uiv(gltype, coords);
+}
+
+void gl4_2compat_glNormalP3ui(void *_glfuncs, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormalP3ui(gltype, coords);
+}
+
+void gl4_2compat_glMultiTexCoordP4uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP4uiv(texture, gltype, coords);
+}
+
+void gl4_2compat_glMultiTexCoordP4ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP4ui(texture, gltype, coords);
+}
+
+void gl4_2compat_glMultiTexCoordP3uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP3uiv(texture, gltype, coords);
+}
+
+void gl4_2compat_glMultiTexCoordP3ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP3ui(texture, gltype, coords);
+}
+
+void gl4_2compat_glMultiTexCoordP2uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP2uiv(texture, gltype, coords);
+}
+
+void gl4_2compat_glMultiTexCoordP2ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP2ui(texture, gltype, coords);
+}
+
+void gl4_2compat_glMultiTexCoordP1uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP1uiv(texture, gltype, coords);
+}
+
+void gl4_2compat_glMultiTexCoordP1ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP1ui(texture, gltype, coords);
+}
+
+void gl4_2compat_glTexCoordP4uiv(void *_glfuncs, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoordP4uiv(gltype, coords);
+}
+
+void gl4_2compat_glTexCoordP4ui(void *_glfuncs, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoordP4ui(gltype, coords);
+}
+
+void gl4_2compat_glTexCoordP3uiv(void *_glfuncs, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoordP3uiv(gltype, coords);
+}
+
+void gl4_2compat_glTexCoordP3ui(void *_glfuncs, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoordP3ui(gltype, coords);
+}
+
+void gl4_2compat_glTexCoordP2uiv(void *_glfuncs, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoordP2uiv(gltype, coords);
+}
+
+void gl4_2compat_glTexCoordP2ui(void *_glfuncs, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoordP2ui(gltype, coords);
+}
+
+void gl4_2compat_glTexCoordP1uiv(void *_glfuncs, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoordP1uiv(gltype, coords);
+}
+
+void gl4_2compat_glTexCoordP1ui(void *_glfuncs, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoordP1ui(gltype, coords);
+}
+
+void gl4_2compat_glVertexP4uiv(void *_glfuncs, GLenum gltype, const GLuint* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexP4uiv(gltype, value);
+}
+
+void gl4_2compat_glVertexP4ui(void *_glfuncs, GLenum gltype, GLuint value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexP4ui(gltype, value);
+}
+
+void gl4_2compat_glVertexP3uiv(void *_glfuncs, GLenum gltype, const GLuint* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexP3uiv(gltype, value);
+}
+
+void gl4_2compat_glVertexP3ui(void *_glfuncs, GLenum gltype, GLuint value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexP3ui(gltype, value);
+}
+
+void gl4_2compat_glVertexP2uiv(void *_glfuncs, GLenum gltype, const GLuint* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexP2uiv(gltype, value);
+}
+
+void gl4_2compat_glVertexP2ui(void *_glfuncs, GLenum gltype, GLuint value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexP2ui(gltype, value);
+}
+
+void gl4_2compat_glGetQueryObjectui64v(void *_glfuncs, GLuint id, GLenum pname, GLuint64* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetQueryObjectui64v(id, pname, params);
+}
+
+void gl4_2compat_glGetQueryObjecti64v(void *_glfuncs, GLuint id, GLenum pname, GLint64* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetQueryObjecti64v(id, pname, params);
+}
+
+void gl4_2compat_glQueryCounter(void *_glfuncs, GLuint id, GLenum target)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glQueryCounter(id, target);
+}
+
+void gl4_2compat_glGetSamplerParameterIuiv(void *_glfuncs, GLuint sampler, GLenum pname, GLuint* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetSamplerParameterIuiv(sampler, pname, params);
+}
+
+void gl4_2compat_glGetSamplerParameterfv(void *_glfuncs, GLuint sampler, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetSamplerParameterfv(sampler, pname, params);
+}
+
+void gl4_2compat_glGetSamplerParameterIiv(void *_glfuncs, GLuint sampler, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetSamplerParameterIiv(sampler, pname, params);
+}
+
+void gl4_2compat_glGetSamplerParameteriv(void *_glfuncs, GLuint sampler, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetSamplerParameteriv(sampler, pname, params);
+}
+
+void gl4_2compat_glSamplerParameterIuiv(void *_glfuncs, GLuint sampler, GLenum pname, const GLuint* param)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glSamplerParameterIuiv(sampler, pname, param);
+}
+
+void gl4_2compat_glSamplerParameterIiv(void *_glfuncs, GLuint sampler, GLenum pname, const GLint* param)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glSamplerParameterIiv(sampler, pname, param);
+}
+
+void gl4_2compat_glSamplerParameterfv(void *_glfuncs, GLuint sampler, GLenum pname, const GLfloat* param)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glSamplerParameterfv(sampler, pname, param);
+}
+
+void gl4_2compat_glSamplerParameterf(void *_glfuncs, GLuint sampler, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glSamplerParameterf(sampler, pname, param);
+}
+
+void gl4_2compat_glSamplerParameteriv(void *_glfuncs, GLuint sampler, GLenum pname, const GLint* param)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glSamplerParameteriv(sampler, pname, param);
+}
+
+void gl4_2compat_glSamplerParameteri(void *_glfuncs, GLuint sampler, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glSamplerParameteri(sampler, pname, param);
+}
+
+void gl4_2compat_glBindSampler(void *_glfuncs, GLuint unit, GLuint sampler)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindSampler(unit, sampler);
+}
+
+GLboolean gl4_2compat_glIsSampler(void *_glfuncs, GLuint sampler)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsSampler(sampler);
+}
+
+void gl4_2compat_glDeleteSamplers(void *_glfuncs, GLsizei count, const GLuint* samplers)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteSamplers(count, samplers);
+}
+
+void gl4_2compat_glGenSamplers(void *_glfuncs, GLsizei count, GLuint* samplers)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGenSamplers(count, samplers);
+}
+
+GLint gl4_2compat_glGetFragDataIndex(void *_glfuncs, GLuint program, const GLchar* name)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ return _qglfuncs->glGetFragDataIndex(program, name);
+}
+
+void gl4_2compat_glBindFragDataLocationIndexed(void *_glfuncs, GLuint program, GLuint colorNumber, GLuint index, const GLchar* name)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindFragDataLocationIndexed(program, colorNumber, index, name);
+}
+
+void gl4_2compat_glVertexAttribDivisor(void *_glfuncs, GLuint index, GLuint divisor)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribDivisor(index, divisor);
+}
+
+void gl4_2compat_glGetQueryIndexediv(void *_glfuncs, GLenum target, GLuint index, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetQueryIndexediv(target, index, pname, params);
+}
+
+void gl4_2compat_glEndQueryIndexed(void *_glfuncs, GLenum target, GLuint index)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glEndQueryIndexed(target, index);
+}
+
+void gl4_2compat_glBeginQueryIndexed(void *_glfuncs, GLenum target, GLuint index, GLuint id)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glBeginQueryIndexed(target, index, id);
+}
+
+void gl4_2compat_glDrawTransformFeedbackStream(void *_glfuncs, GLenum mode, GLuint id, GLuint stream)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawTransformFeedbackStream(mode, id, stream);
+}
+
+void gl4_2compat_glDrawTransformFeedback(void *_glfuncs, GLenum mode, GLuint id)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawTransformFeedback(mode, id);
+}
+
+void gl4_2compat_glResumeTransformFeedback(void *_glfuncs)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glResumeTransformFeedback();
+}
+
+void gl4_2compat_glPauseTransformFeedback(void *_glfuncs)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glPauseTransformFeedback();
+}
+
+GLboolean gl4_2compat_glIsTransformFeedback(void *_glfuncs, GLuint id)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsTransformFeedback(id);
+}
+
+void gl4_2compat_glGenTransformFeedbacks(void *_glfuncs, GLsizei n, GLuint* ids)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGenTransformFeedbacks(n, ids);
+}
+
+void gl4_2compat_glDeleteTransformFeedbacks(void *_glfuncs, GLsizei n, const GLuint* ids)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteTransformFeedbacks(n, ids);
+}
+
+void gl4_2compat_glBindTransformFeedback(void *_glfuncs, GLenum target, GLuint id)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindTransformFeedback(target, id);
+}
+
+void gl4_2compat_glPatchParameterfv(void *_glfuncs, GLenum pname, const GLfloat* values)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glPatchParameterfv(pname, values);
+}
+
+void gl4_2compat_glPatchParameteri(void *_glfuncs, GLenum pname, GLint value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glPatchParameteri(pname, value);
+}
+
+void gl4_2compat_glGetProgramStageiv(void *_glfuncs, GLuint program, GLenum shadertype, GLenum pname, GLint* values)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetProgramStageiv(program, shadertype, pname, values);
+}
+
+void gl4_2compat_glGetUniformSubroutineuiv(void *_glfuncs, GLenum shadertype, GLint location, GLuint* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetUniformSubroutineuiv(shadertype, location, params);
+}
+
+void gl4_2compat_glUniformSubroutinesuiv(void *_glfuncs, GLenum shadertype, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformSubroutinesuiv(shadertype, count, value);
+}
+
+void gl4_2compat_glGetActiveSubroutineName(void *_glfuncs, GLuint program, GLenum shadertype, GLuint index, GLsizei bufSize, GLsizei* length, GLchar* name)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetActiveSubroutineName(program, shadertype, index, bufSize, length, name);
+}
+
+void gl4_2compat_glGetActiveSubroutineUniformName(void *_glfuncs, GLuint program, GLenum shadertype, GLuint index, GLsizei bufSize, GLsizei* length, GLchar* name)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetActiveSubroutineUniformName(program, shadertype, index, bufSize, length, name);
+}
+
+void gl4_2compat_glGetActiveSubroutineUniformiv(void *_glfuncs, GLuint program, GLenum shadertype, GLuint index, GLenum pname, GLint* values)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetActiveSubroutineUniformiv(program, shadertype, index, pname, values);
+}
+
+GLuint gl4_2compat_glGetSubroutineIndex(void *_glfuncs, GLuint program, GLenum shadertype, const GLchar* name)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ return _qglfuncs->glGetSubroutineIndex(program, shadertype, name);
+}
+
+GLint gl4_2compat_glGetSubroutineUniformLocation(void *_glfuncs, GLuint program, GLenum shadertype, const GLchar* name)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ return _qglfuncs->glGetSubroutineUniformLocation(program, shadertype, name);
+}
+
+void gl4_2compat_glGetUniformdv(void *_glfuncs, GLuint program, GLint location, GLdouble* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetUniformdv(program, location, params);
+}
+
+void gl4_2compat_glUniformMatrix4x3dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4x3dv(location, count, transpose, value);
+}
+
+void gl4_2compat_glUniformMatrix4x2dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4x2dv(location, count, transpose, value);
+}
+
+void gl4_2compat_glUniformMatrix3x4dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3x4dv(location, count, transpose, value);
+}
+
+void gl4_2compat_glUniformMatrix3x2dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3x2dv(location, count, transpose, value);
+}
+
+void gl4_2compat_glUniformMatrix2x4dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2x4dv(location, count, transpose, value);
+}
+
+void gl4_2compat_glUniformMatrix2x3dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2x3dv(location, count, transpose, value);
+}
+
+void gl4_2compat_glUniformMatrix4dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4dv(location, count, transpose, value);
+}
+
+void gl4_2compat_glUniformMatrix3dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3dv(location, count, transpose, value);
+}
+
+void gl4_2compat_glUniformMatrix2dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2dv(location, count, transpose, value);
+}
+
+void gl4_2compat_glUniform4dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform4dv(location, count, value);
+}
+
+void gl4_2compat_glUniform3dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform3dv(location, count, value);
+}
+
+void gl4_2compat_glUniform2dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform2dv(location, count, value);
+}
+
+void gl4_2compat_glUniform1dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform1dv(location, count, value);
+}
+
+void gl4_2compat_glUniform4d(void *_glfuncs, GLint location, GLdouble v0, GLdouble v1, GLdouble v2, GLdouble v3)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform4d(location, v0, v1, v2, v3);
+}
+
+void gl4_2compat_glUniform3d(void *_glfuncs, GLint location, GLdouble v0, GLdouble v1, GLdouble v2)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform3d(location, v0, v1, v2);
+}
+
+void gl4_2compat_glUniform2d(void *_glfuncs, GLint location, GLdouble v0, GLdouble v1)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform2d(location, v0, v1);
+}
+
+void gl4_2compat_glUniform1d(void *_glfuncs, GLint location, GLdouble v0)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform1d(location, v0);
+}
+
+void gl4_2compat_glDrawElementsIndirect(void *_glfuncs, GLenum mode, GLenum gltype, const GLvoid* indirect)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawElementsIndirect(mode, gltype, indirect);
+}
+
+void gl4_2compat_glDrawArraysIndirect(void *_glfuncs, GLenum mode, const GLvoid* indirect)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawArraysIndirect(mode, indirect);
+}
+
+void gl4_2compat_glBlendFuncSeparatei(void *_glfuncs, GLuint buf, GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha, GLenum dstAlpha)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glBlendFuncSeparatei(buf, srcRGB, dstRGB, srcAlpha, dstAlpha);
+}
+
+void gl4_2compat_glBlendFunci(void *_glfuncs, GLuint buf, GLenum src, GLenum dst)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glBlendFunci(buf, src, dst);
+}
+
+void gl4_2compat_glBlendEquationSeparatei(void *_glfuncs, GLuint buf, GLenum modeRGB, GLenum modeAlpha)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glBlendEquationSeparatei(buf, modeRGB, modeAlpha);
+}
+
+void gl4_2compat_glBlendEquationi(void *_glfuncs, GLuint buf, GLenum mode)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glBlendEquationi(buf, mode);
+}
+
+void gl4_2compat_glMinSampleShading(void *_glfuncs, GLfloat value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMinSampleShading(value);
+}
+
+void gl4_2compat_glGetDoublei_v(void *_glfuncs, GLenum target, GLuint index, GLdouble* data)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetDoublei_v(target, index, data);
+}
+
+void gl4_2compat_glGetFloati_v(void *_glfuncs, GLenum target, GLuint index, GLfloat* data)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetFloati_v(target, index, data);
+}
+
+void gl4_2compat_glDepthRangeIndexed(void *_glfuncs, GLuint index, GLdouble n, GLdouble f)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDepthRangeIndexed(index, n, f);
+}
+
+void gl4_2compat_glDepthRangeArrayv(void *_glfuncs, GLuint first, GLsizei count, const GLdouble* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDepthRangeArrayv(first, count, v);
+}
+
+void gl4_2compat_glScissorIndexedv(void *_glfuncs, GLuint index, const GLint* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glScissorIndexedv(index, v);
+}
+
+void gl4_2compat_glScissorIndexed(void *_glfuncs, GLuint index, GLint left, GLint bottom, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glScissorIndexed(index, left, bottom, width, height);
+}
+
+void gl4_2compat_glScissorArrayv(void *_glfuncs, GLuint first, GLsizei count, const GLint* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glScissorArrayv(first, count, v);
+}
+
+void gl4_2compat_glViewportIndexedfv(void *_glfuncs, GLuint index, const GLfloat* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glViewportIndexedfv(index, v);
+}
+
+void gl4_2compat_glViewportIndexedf(void *_glfuncs, GLuint index, GLfloat x, GLfloat y, GLfloat w, GLfloat h)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glViewportIndexedf(index, x, y, w, h);
+}
+
+void gl4_2compat_glViewportArrayv(void *_glfuncs, GLuint first, GLsizei count, const GLfloat* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glViewportArrayv(first, count, v);
+}
+
+void gl4_2compat_glGetVertexAttribLdv(void *_glfuncs, GLuint index, GLenum pname, GLdouble* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribLdv(index, pname, params);
+}
+
+void gl4_2compat_glVertexAttribLPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribLPointer(index, size, gltype, stride, pointer);
+}
+
+void gl4_2compat_glVertexAttribL4dv(void *_glfuncs, GLuint index, const GLdouble* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribL4dv(index, v);
+}
+
+void gl4_2compat_glVertexAttribL3dv(void *_glfuncs, GLuint index, const GLdouble* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribL3dv(index, v);
+}
+
+void gl4_2compat_glVertexAttribL2dv(void *_glfuncs, GLuint index, const GLdouble* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribL2dv(index, v);
+}
+
+void gl4_2compat_glVertexAttribL1dv(void *_glfuncs, GLuint index, const GLdouble* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribL1dv(index, v);
+}
+
+void gl4_2compat_glVertexAttribL4d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribL4d(index, x, y, z, w);
+}
+
+void gl4_2compat_glVertexAttribL3d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribL3d(index, x, y, z);
+}
+
+void gl4_2compat_glVertexAttribL2d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribL2d(index, x, y);
+}
+
+void gl4_2compat_glVertexAttribL1d(void *_glfuncs, GLuint index, GLdouble x)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribL1d(index, x);
+}
+
+void gl4_2compat_glGetProgramPipelineInfoLog(void *_glfuncs, GLuint pipeline, GLsizei bufSize, GLsizei* length, GLchar* infoLog)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetProgramPipelineInfoLog(pipeline, bufSize, length, infoLog);
+}
+
+void gl4_2compat_glValidateProgramPipeline(void *_glfuncs, GLuint pipeline)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glValidateProgramPipeline(pipeline);
+}
+
+void gl4_2compat_glProgramUniformMatrix4x3dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix4x3dv(program, location, count, transpose, value);
+}
+
+void gl4_2compat_glProgramUniformMatrix3x4dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix3x4dv(program, location, count, transpose, value);
+}
+
+void gl4_2compat_glProgramUniformMatrix4x2dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix4x2dv(program, location, count, transpose, value);
+}
+
+void gl4_2compat_glProgramUniformMatrix2x4dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix2x4dv(program, location, count, transpose, value);
+}
+
+void gl4_2compat_glProgramUniformMatrix3x2dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix3x2dv(program, location, count, transpose, value);
+}
+
+void gl4_2compat_glProgramUniformMatrix2x3dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix2x3dv(program, location, count, transpose, value);
+}
+
+void gl4_2compat_glProgramUniformMatrix4x3fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix4x3fv(program, location, count, transpose, value);
+}
+
+void gl4_2compat_glProgramUniformMatrix3x4fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix3x4fv(program, location, count, transpose, value);
+}
+
+void gl4_2compat_glProgramUniformMatrix4x2fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix4x2fv(program, location, count, transpose, value);
+}
+
+void gl4_2compat_glProgramUniformMatrix2x4fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix2x4fv(program, location, count, transpose, value);
+}
+
+void gl4_2compat_glProgramUniformMatrix3x2fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix3x2fv(program, location, count, transpose, value);
+}
+
+void gl4_2compat_glProgramUniformMatrix2x3fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix2x3fv(program, location, count, transpose, value);
+}
+
+void gl4_2compat_glProgramUniformMatrix4dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix4dv(program, location, count, transpose, value);
+}
+
+void gl4_2compat_glProgramUniformMatrix3dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix3dv(program, location, count, transpose, value);
+}
+
+void gl4_2compat_glProgramUniformMatrix2dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix2dv(program, location, count, transpose, value);
+}
+
+void gl4_2compat_glProgramUniformMatrix4fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix4fv(program, location, count, transpose, value);
+}
+
+void gl4_2compat_glProgramUniformMatrix3fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix3fv(program, location, count, transpose, value);
+}
+
+void gl4_2compat_glProgramUniformMatrix2fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix2fv(program, location, count, transpose, value);
+}
+
+void gl4_2compat_glProgramUniform4uiv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform4uiv(program, location, count, value);
+}
+
+void gl4_2compat_glProgramUniform4ui(void *_glfuncs, GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform4ui(program, location, v0, v1, v2, v3);
+}
+
+void gl4_2compat_glProgramUniform4dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLdouble* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform4dv(program, location, count, value);
+}
+
+void gl4_2compat_glProgramUniform4d(void *_glfuncs, GLuint program, GLint location, GLdouble v0, GLdouble v1, GLdouble v2, GLdouble v3)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform4d(program, location, v0, v1, v2, v3);
+}
+
+void gl4_2compat_glProgramUniform4fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform4fv(program, location, count, value);
+}
+
+void gl4_2compat_glProgramUniform4f(void *_glfuncs, GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform4f(program, location, v0, v1, v2, v3);
+}
+
+void gl4_2compat_glProgramUniform4iv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform4iv(program, location, count, value);
+}
+
+void gl4_2compat_glProgramUniform4i(void *_glfuncs, GLuint program, GLint location, GLint v0, GLint v1, GLint v2, GLint v3)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform4i(program, location, v0, v1, v2, v3);
+}
+
+void gl4_2compat_glProgramUniform3uiv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform3uiv(program, location, count, value);
+}
+
+void gl4_2compat_glProgramUniform3ui(void *_glfuncs, GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform3ui(program, location, v0, v1, v2);
+}
+
+void gl4_2compat_glProgramUniform3dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLdouble* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform3dv(program, location, count, value);
+}
+
+void gl4_2compat_glProgramUniform3d(void *_glfuncs, GLuint program, GLint location, GLdouble v0, GLdouble v1, GLdouble v2)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform3d(program, location, v0, v1, v2);
+}
+
+void gl4_2compat_glProgramUniform3fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform3fv(program, location, count, value);
+}
+
+void gl4_2compat_glProgramUniform3f(void *_glfuncs, GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform3f(program, location, v0, v1, v2);
+}
+
+void gl4_2compat_glProgramUniform3iv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform3iv(program, location, count, value);
+}
+
+void gl4_2compat_glProgramUniform3i(void *_glfuncs, GLuint program, GLint location, GLint v0, GLint v1, GLint v2)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform3i(program, location, v0, v1, v2);
+}
+
+void gl4_2compat_glProgramUniform2uiv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform2uiv(program, location, count, value);
+}
+
+void gl4_2compat_glProgramUniform2ui(void *_glfuncs, GLuint program, GLint location, GLuint v0, GLuint v1)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform2ui(program, location, v0, v1);
+}
+
+void gl4_2compat_glProgramUniform2dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLdouble* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform2dv(program, location, count, value);
+}
+
+void gl4_2compat_glProgramUniform2d(void *_glfuncs, GLuint program, GLint location, GLdouble v0, GLdouble v1)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform2d(program, location, v0, v1);
+}
+
+void gl4_2compat_glProgramUniform2fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform2fv(program, location, count, value);
+}
+
+void gl4_2compat_glProgramUniform2f(void *_glfuncs, GLuint program, GLint location, GLfloat v0, GLfloat v1)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform2f(program, location, v0, v1);
+}
+
+void gl4_2compat_glProgramUniform2iv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform2iv(program, location, count, value);
+}
+
+void gl4_2compat_glProgramUniform2i(void *_glfuncs, GLuint program, GLint location, GLint v0, GLint v1)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform2i(program, location, v0, v1);
+}
+
+void gl4_2compat_glProgramUniform1uiv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform1uiv(program, location, count, value);
+}
+
+void gl4_2compat_glProgramUniform1ui(void *_glfuncs, GLuint program, GLint location, GLuint v0)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform1ui(program, location, v0);
+}
+
+void gl4_2compat_glProgramUniform1dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLdouble* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform1dv(program, location, count, value);
+}
+
+void gl4_2compat_glProgramUniform1d(void *_glfuncs, GLuint program, GLint location, GLdouble v0)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform1d(program, location, v0);
+}
+
+void gl4_2compat_glProgramUniform1fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform1fv(program, location, count, value);
+}
+
+void gl4_2compat_glProgramUniform1f(void *_glfuncs, GLuint program, GLint location, GLfloat v0)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform1f(program, location, v0);
+}
+
+void gl4_2compat_glProgramUniform1iv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform1iv(program, location, count, value);
+}
+
+void gl4_2compat_glProgramUniform1i(void *_glfuncs, GLuint program, GLint location, GLint v0)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform1i(program, location, v0);
+}
+
+void gl4_2compat_glGetProgramPipelineiv(void *_glfuncs, GLuint pipeline, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetProgramPipelineiv(pipeline, pname, params);
+}
+
+GLboolean gl4_2compat_glIsProgramPipeline(void *_glfuncs, GLuint pipeline)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsProgramPipeline(pipeline);
+}
+
+void gl4_2compat_glGenProgramPipelines(void *_glfuncs, GLsizei n, GLuint* pipelines)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGenProgramPipelines(n, pipelines);
+}
+
+void gl4_2compat_glDeleteProgramPipelines(void *_glfuncs, GLsizei n, const GLuint* pipelines)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteProgramPipelines(n, pipelines);
+}
+
+void gl4_2compat_glBindProgramPipeline(void *_glfuncs, GLuint pipeline)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindProgramPipeline(pipeline);
+}
+
+void gl4_2compat_glActiveShaderProgram(void *_glfuncs, GLuint pipeline, GLuint program)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glActiveShaderProgram(pipeline, program);
+}
+
+void gl4_2compat_glUseProgramStages(void *_glfuncs, GLuint pipeline, GLbitfield stages, GLuint program)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glUseProgramStages(pipeline, stages, program);
+}
+
+void gl4_2compat_glProgramParameteri(void *_glfuncs, GLuint program, GLenum pname, GLint value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramParameteri(program, pname, value);
+}
+
+void gl4_2compat_glProgramBinary(void *_glfuncs, GLuint program, GLenum binaryFormat, const GLvoid* binary, GLsizei length)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramBinary(program, binaryFormat, binary, length);
+}
+
+void gl4_2compat_glGetProgramBinary(void *_glfuncs, GLuint program, GLsizei bufSize, GLsizei* length, GLenum* binaryFormat, GLvoid* binary)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetProgramBinary(program, bufSize, length, binaryFormat, binary);
+}
+
+void gl4_2compat_glClearDepthf(void *_glfuncs, GLfloat dd)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glClearDepthf(dd);
+}
+
+void gl4_2compat_glDepthRangef(void *_glfuncs, GLfloat n, GLfloat f)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDepthRangef(n, f);
+}
+
+void gl4_2compat_glGetShaderPrecisionFormat(void *_glfuncs, GLenum shadertype, GLenum precisionType, GLint* range_, GLint* precision)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetShaderPrecisionFormat(shadertype, precisionType, range_, precision);
+}
+
+void gl4_2compat_glShaderBinary(void *_glfuncs, GLsizei count, const GLuint* shaders, GLenum binaryFormat, const GLvoid* binary, GLsizei length)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glShaderBinary(count, shaders, binaryFormat, binary, length);
+}
+
+void gl4_2compat_glReleaseShaderCompiler(void *_glfuncs)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glReleaseShaderCompiler();
+}
+
+void gl4_2compat_glTexStorage3D(void *_glfuncs, GLenum target, GLsizei levels, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexStorage3D(target, levels, internalFormat, width, height, depth);
+}
+
+void gl4_2compat_glTexStorage2D(void *_glfuncs, GLenum target, GLsizei levels, GLenum internalFormat, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexStorage2D(target, levels, internalFormat, width, height);
+}
+
+void gl4_2compat_glTexStorage1D(void *_glfuncs, GLenum target, GLsizei levels, GLenum internalFormat, GLsizei width)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexStorage1D(target, levels, internalFormat, width);
+}
+
+void gl4_2compat_glMemoryBarrier(void *_glfuncs, GLbitfield barriers)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMemoryBarrier(barriers);
+}
+
+void gl4_2compat_glBindImageTexture(void *_glfuncs, GLuint unit, GLuint texture, GLint level, GLboolean layered, GLint layer, GLenum access, GLenum format)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindImageTexture(unit, texture, level, layered, layer, access, format);
+}
+
+void gl4_2compat_glGetActiveAtomicCounterBufferiv(void *_glfuncs, GLuint program, GLuint bufferIndex, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetActiveAtomicCounterBufferiv(program, bufferIndex, pname, params);
+}
+
+void gl4_2compat_glGetInternalformativ(void *_glfuncs, GLenum target, GLenum internalFormat, GLenum pname, GLsizei bufSize, GLint* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetInternalformativ(target, internalFormat, pname, bufSize, params);
+}
+
+void gl4_2compat_glDrawTransformFeedbackStreamInstanced(void *_glfuncs, GLenum mode, GLuint id, GLuint stream, GLsizei instancecount)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawTransformFeedbackStreamInstanced(mode, id, stream, instancecount);
+}
+
+void gl4_2compat_glDrawTransformFeedbackInstanced(void *_glfuncs, GLenum mode, GLuint id, GLsizei instancecount)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawTransformFeedbackInstanced(mode, id, instancecount);
+}
+
+void gl4_2compat_glDrawElementsInstancedBaseVertexBaseInstance(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount, GLint basevertex, GLuint baseinstance)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawElementsInstancedBaseVertexBaseInstance(mode, count, gltype, indices, instancecount, basevertex, baseinstance);
+}
+
+void gl4_2compat_glDrawElementsInstancedBaseInstance(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount, GLuint baseinstance)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawElementsInstancedBaseInstance(mode, count, gltype, indices, instancecount, baseinstance);
+}
+
+void gl4_2compat_glDrawArraysInstancedBaseInstance(void *_glfuncs, GLenum mode, GLint first, GLsizei count, GLsizei instancecount, GLuint baseinstance)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawArraysInstancedBaseInstance(mode, first, count, instancecount, baseinstance);
+}
+
+void gl4_2compat_glTranslatef(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTranslatef(x, y, z);
+}
+
+void gl4_2compat_glTranslated(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTranslated(x, y, z);
+}
+
+void gl4_2compat_glScalef(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glScalef(x, y, z);
+}
+
+void gl4_2compat_glScaled(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glScaled(x, y, z);
+}
+
+void gl4_2compat_glRotatef(void *_glfuncs, GLfloat angle, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRotatef(angle, x, y, z);
+}
+
+void gl4_2compat_glRotated(void *_glfuncs, GLdouble angle, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRotated(angle, x, y, z);
+}
+
+void gl4_2compat_glPushMatrix(void *_glfuncs)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glPushMatrix();
+}
+
+void gl4_2compat_glPopMatrix(void *_glfuncs)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glPopMatrix();
+}
+
+void gl4_2compat_glOrtho(void *_glfuncs, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glOrtho(left, right, bottom, top, zNear, zFar);
+}
+
+void gl4_2compat_glMultMatrixd(void *_glfuncs, const GLdouble* m)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultMatrixd(m);
+}
+
+void gl4_2compat_glMultMatrixf(void *_glfuncs, const GLfloat* m)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultMatrixf(m);
+}
+
+void gl4_2compat_glMatrixMode(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMatrixMode(mode);
+}
+
+void gl4_2compat_glLoadMatrixd(void *_glfuncs, const GLdouble* m)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glLoadMatrixd(m);
+}
+
+void gl4_2compat_glLoadMatrixf(void *_glfuncs, const GLfloat* m)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glLoadMatrixf(m);
+}
+
+void gl4_2compat_glLoadIdentity(void *_glfuncs)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glLoadIdentity();
+}
+
+void gl4_2compat_glFrustum(void *_glfuncs, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glFrustum(left, right, bottom, top, zNear, zFar);
+}
+
+GLboolean gl4_2compat_glIsList(void *_glfuncs, GLuint list)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsList(list);
+}
+
+void gl4_2compat_glGetTexGeniv(void *_glfuncs, GLenum coord, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexGeniv(coord, pname, params);
+}
+
+void gl4_2compat_glGetTexGenfv(void *_glfuncs, GLenum coord, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexGenfv(coord, pname, params);
+}
+
+void gl4_2compat_glGetTexGendv(void *_glfuncs, GLenum coord, GLenum pname, GLdouble* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexGendv(coord, pname, params);
+}
+
+void gl4_2compat_glGetTexEnviv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexEnviv(target, pname, params);
+}
+
+void gl4_2compat_glGetTexEnvfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexEnvfv(target, pname, params);
+}
+
+void gl4_2compat_glGetPolygonStipple(void *_glfuncs, GLubyte* mask)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetPolygonStipple(mask);
+}
+
+void gl4_2compat_glGetPixelMapusv(void *_glfuncs, GLenum glmap, GLushort* values)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetPixelMapusv(glmap, values);
+}
+
+void gl4_2compat_glGetPixelMapuiv(void *_glfuncs, GLenum glmap, GLuint* values)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetPixelMapuiv(glmap, values);
+}
+
+void gl4_2compat_glGetPixelMapfv(void *_glfuncs, GLenum glmap, GLfloat* values)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetPixelMapfv(glmap, values);
+}
+
+void gl4_2compat_glGetMaterialiv(void *_glfuncs, GLenum face, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetMaterialiv(face, pname, params);
+}
+
+void gl4_2compat_glGetMaterialfv(void *_glfuncs, GLenum face, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetMaterialfv(face, pname, params);
+}
+
+void gl4_2compat_glGetMapiv(void *_glfuncs, GLenum target, GLenum query, GLint* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetMapiv(target, query, v);
+}
+
+void gl4_2compat_glGetMapfv(void *_glfuncs, GLenum target, GLenum query, GLfloat* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetMapfv(target, query, v);
+}
+
+void gl4_2compat_glGetMapdv(void *_glfuncs, GLenum target, GLenum query, GLdouble* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetMapdv(target, query, v);
+}
+
+void gl4_2compat_glGetLightiv(void *_glfuncs, GLenum light, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetLightiv(light, pname, params);
+}
+
+void gl4_2compat_glGetLightfv(void *_glfuncs, GLenum light, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetLightfv(light, pname, params);
+}
+
+void gl4_2compat_glGetClipPlane(void *_glfuncs, GLenum plane, GLdouble* equation)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetClipPlane(plane, equation);
+}
+
+void gl4_2compat_glDrawPixels(void *_glfuncs, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawPixels(width, height, format, gltype, pixels);
+}
+
+void gl4_2compat_glCopyPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum gltype)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyPixels(x, y, width, height, gltype);
+}
+
+void gl4_2compat_glPixelMapusv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLushort* values)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glPixelMapusv(glmap, mapsize, values);
+}
+
+void gl4_2compat_glPixelMapuiv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLuint* values)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glPixelMapuiv(glmap, mapsize, values);
+}
+
+void gl4_2compat_glPixelMapfv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLfloat* values)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glPixelMapfv(glmap, mapsize, values);
+}
+
+void gl4_2compat_glPixelTransferi(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glPixelTransferi(pname, param);
+}
+
+void gl4_2compat_glPixelTransferf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glPixelTransferf(pname, param);
+}
+
+void gl4_2compat_glPixelZoom(void *_glfuncs, GLfloat xfactor, GLfloat yfactor)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glPixelZoom(xfactor, yfactor);
+}
+
+void gl4_2compat_glAlphaFunc(void *_glfuncs, GLenum glfunc, GLfloat ref)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glAlphaFunc(glfunc, ref);
+}
+
+void gl4_2compat_glEvalPoint2(void *_glfuncs, GLint i, GLint j)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalPoint2(i, j);
+}
+
+void gl4_2compat_glEvalMesh2(void *_glfuncs, GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalMesh2(mode, i1, i2, j1, j2);
+}
+
+void gl4_2compat_glEvalPoint1(void *_glfuncs, GLint i)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalPoint1(i);
+}
+
+void gl4_2compat_glEvalMesh1(void *_glfuncs, GLenum mode, GLint i1, GLint i2)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalMesh1(mode, i1, i2);
+}
+
+void gl4_2compat_glEvalCoord2fv(void *_glfuncs, const GLfloat* u)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalCoord2fv(u);
+}
+
+void gl4_2compat_glEvalCoord2f(void *_glfuncs, GLfloat u, GLfloat v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalCoord2f(u, v);
+}
+
+void gl4_2compat_glEvalCoord2dv(void *_glfuncs, const GLdouble* u)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalCoord2dv(u);
+}
+
+void gl4_2compat_glEvalCoord2d(void *_glfuncs, GLdouble u, GLdouble v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalCoord2d(u, v);
+}
+
+void gl4_2compat_glEvalCoord1fv(void *_glfuncs, const GLfloat* u)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalCoord1fv(u);
+}
+
+void gl4_2compat_glEvalCoord1f(void *_glfuncs, GLfloat u)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalCoord1f(u);
+}
+
+void gl4_2compat_glEvalCoord1dv(void *_glfuncs, const GLdouble* u)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalCoord1dv(u);
+}
+
+void gl4_2compat_glEvalCoord1d(void *_glfuncs, GLdouble u)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalCoord1d(u);
+}
+
+void gl4_2compat_glMapGrid2f(void *_glfuncs, GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMapGrid2f(un, u1, u2, vn, v1, v2);
+}
+
+void gl4_2compat_glMapGrid2d(void *_glfuncs, GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMapGrid2d(un, u1, u2, vn, v1, v2);
+}
+
+void gl4_2compat_glMapGrid1f(void *_glfuncs, GLint un, GLfloat u1, GLfloat u2)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMapGrid1f(un, u1, u2);
+}
+
+void gl4_2compat_glMapGrid1d(void *_glfuncs, GLint un, GLdouble u1, GLdouble u2)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMapGrid1d(un, u1, u2);
+}
+
+void gl4_2compat_glMap2f(void *_glfuncs, GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat* points)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMap2f(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+void gl4_2compat_glMap2d(void *_glfuncs, GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble* points)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMap2d(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+void gl4_2compat_glMap1f(void *_glfuncs, GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat* points)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMap1f(target, u1, u2, stride, order, points);
+}
+
+void gl4_2compat_glMap1d(void *_glfuncs, GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble* points)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMap1d(target, u1, u2, stride, order, points);
+}
+
+void gl4_2compat_glPushAttrib(void *_glfuncs, GLbitfield mask)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glPushAttrib(mask);
+}
+
+void gl4_2compat_glPopAttrib(void *_glfuncs)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glPopAttrib();
+}
+
+void gl4_2compat_glAccum(void *_glfuncs, GLenum op, GLfloat value)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glAccum(op, value);
+}
+
+void gl4_2compat_glIndexMask(void *_glfuncs, GLuint mask)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexMask(mask);
+}
+
+void gl4_2compat_glClearIndex(void *_glfuncs, GLfloat c)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glClearIndex(c);
+}
+
+void gl4_2compat_glClearAccum(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glClearAccum(red, green, blue, alpha);
+}
+
+void gl4_2compat_glPushName(void *_glfuncs, GLuint name)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glPushName(name);
+}
+
+void gl4_2compat_glPopName(void *_glfuncs)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glPopName();
+}
+
+void gl4_2compat_glPassThrough(void *_glfuncs, GLfloat token)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glPassThrough(token);
+}
+
+void gl4_2compat_glLoadName(void *_glfuncs, GLuint name)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glLoadName(name);
+}
+
+void gl4_2compat_glInitNames(void *_glfuncs)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glInitNames();
+}
+
+GLint gl4_2compat_glRenderMode(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ return _qglfuncs->glRenderMode(mode);
+}
+
+void gl4_2compat_glSelectBuffer(void *_glfuncs, GLsizei size, GLuint* buffer)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glSelectBuffer(size, buffer);
+}
+
+void gl4_2compat_glFeedbackBuffer(void *_glfuncs, GLsizei size, GLenum gltype, GLfloat* buffer)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glFeedbackBuffer(size, gltype, buffer);
+}
+
+void gl4_2compat_glTexGeniv(void *_glfuncs, GLenum coord, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexGeniv(coord, pname, params);
+}
+
+void gl4_2compat_glTexGeni(void *_glfuncs, GLenum coord, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexGeni(coord, pname, param);
+}
+
+void gl4_2compat_glTexGenfv(void *_glfuncs, GLenum coord, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexGenfv(coord, pname, params);
+}
+
+void gl4_2compat_glTexGenf(void *_glfuncs, GLenum coord, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexGenf(coord, pname, param);
+}
+
+void gl4_2compat_glTexGendv(void *_glfuncs, GLenum coord, GLenum pname, const GLdouble* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexGendv(coord, pname, params);
+}
+
+void gl4_2compat_glTexGend(void *_glfuncs, GLenum coord, GLenum pname, GLdouble param)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexGend(coord, pname, param);
+}
+
+void gl4_2compat_glTexEnviv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexEnviv(target, pname, params);
+}
+
+void gl4_2compat_glTexEnvi(void *_glfuncs, GLenum target, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexEnvi(target, pname, param);
+}
+
+void gl4_2compat_glTexEnvfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexEnvfv(target, pname, params);
+}
+
+void gl4_2compat_glTexEnvf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexEnvf(target, pname, param);
+}
+
+void gl4_2compat_glShadeModel(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glShadeModel(mode);
+}
+
+void gl4_2compat_glPolygonStipple(void *_glfuncs, const GLubyte* mask)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glPolygonStipple(mask);
+}
+
+void gl4_2compat_glMaterialiv(void *_glfuncs, GLenum face, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMaterialiv(face, pname, params);
+}
+
+void gl4_2compat_glMateriali(void *_glfuncs, GLenum face, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMateriali(face, pname, param);
+}
+
+void gl4_2compat_glMaterialfv(void *_glfuncs, GLenum face, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMaterialfv(face, pname, params);
+}
+
+void gl4_2compat_glMaterialf(void *_glfuncs, GLenum face, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMaterialf(face, pname, param);
+}
+
+void gl4_2compat_glLineStipple(void *_glfuncs, GLint factor, GLushort pattern)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glLineStipple(factor, pattern);
+}
+
+void gl4_2compat_glLightModeliv(void *_glfuncs, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glLightModeliv(pname, params);
+}
+
+void gl4_2compat_glLightModeli(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glLightModeli(pname, param);
+}
+
+void gl4_2compat_glLightModelfv(void *_glfuncs, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glLightModelfv(pname, params);
+}
+
+void gl4_2compat_glLightModelf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glLightModelf(pname, param);
+}
+
+void gl4_2compat_glLightiv(void *_glfuncs, GLenum light, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glLightiv(light, pname, params);
+}
+
+void gl4_2compat_glLighti(void *_glfuncs, GLenum light, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glLighti(light, pname, param);
+}
+
+void gl4_2compat_glLightfv(void *_glfuncs, GLenum light, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glLightfv(light, pname, params);
+}
+
+void gl4_2compat_glLightf(void *_glfuncs, GLenum light, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glLightf(light, pname, param);
+}
+
+void gl4_2compat_glFogiv(void *_glfuncs, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glFogiv(pname, params);
+}
+
+void gl4_2compat_glFogi(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glFogi(pname, param);
+}
+
+void gl4_2compat_glFogfv(void *_glfuncs, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glFogfv(pname, params);
+}
+
+void gl4_2compat_glFogf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glFogf(pname, param);
+}
+
+void gl4_2compat_glColorMaterial(void *_glfuncs, GLenum face, GLenum mode)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorMaterial(face, mode);
+}
+
+void gl4_2compat_glClipPlane(void *_glfuncs, GLenum plane, const GLdouble* equation)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glClipPlane(plane, equation);
+}
+
+void gl4_2compat_glVertex4sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex4sv(v);
+}
+
+void gl4_2compat_glVertex4s(void *_glfuncs, GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex4s(x, y, z, w);
+}
+
+void gl4_2compat_glVertex4iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex4iv(v);
+}
+
+void gl4_2compat_glVertex4i(void *_glfuncs, GLint x, GLint y, GLint z, GLint w)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex4i(x, y, z, w);
+}
+
+void gl4_2compat_glVertex4fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex4fv(v);
+}
+
+void gl4_2compat_glVertex4f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex4f(x, y, z, w);
+}
+
+void gl4_2compat_glVertex4dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex4dv(v);
+}
+
+void gl4_2compat_glVertex4d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex4d(x, y, z, w);
+}
+
+void gl4_2compat_glVertex3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex3sv(v);
+}
+
+void gl4_2compat_glVertex3s(void *_glfuncs, GLshort x, GLshort y, GLshort z)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex3s(x, y, z);
+}
+
+void gl4_2compat_glVertex3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex3iv(v);
+}
+
+void gl4_2compat_glVertex3i(void *_glfuncs, GLint x, GLint y, GLint z)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex3i(x, y, z);
+}
+
+void gl4_2compat_glVertex3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex3fv(v);
+}
+
+void gl4_2compat_glVertex3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex3f(x, y, z);
+}
+
+void gl4_2compat_glVertex3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex3dv(v);
+}
+
+void gl4_2compat_glVertex3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex3d(x, y, z);
+}
+
+void gl4_2compat_glVertex2sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex2sv(v);
+}
+
+void gl4_2compat_glVertex2s(void *_glfuncs, GLshort x, GLshort y)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex2s(x, y);
+}
+
+void gl4_2compat_glVertex2iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex2iv(v);
+}
+
+void gl4_2compat_glVertex2i(void *_glfuncs, GLint x, GLint y)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex2i(x, y);
+}
+
+void gl4_2compat_glVertex2fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex2fv(v);
+}
+
+void gl4_2compat_glVertex2f(void *_glfuncs, GLfloat x, GLfloat y)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex2f(x, y);
+}
+
+void gl4_2compat_glVertex2dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex2dv(v);
+}
+
+void gl4_2compat_glVertex2d(void *_glfuncs, GLdouble x, GLdouble y)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex2d(x, y);
+}
+
+void gl4_2compat_glTexCoord4sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord4sv(v);
+}
+
+void gl4_2compat_glTexCoord4s(void *_glfuncs, GLshort s, GLshort t, GLshort r, GLshort q)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord4s(s, t, r, q);
+}
+
+void gl4_2compat_glTexCoord4iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord4iv(v);
+}
+
+void gl4_2compat_glTexCoord4i(void *_glfuncs, GLint s, GLint t, GLint r, GLint q)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord4i(s, t, r, q);
+}
+
+void gl4_2compat_glTexCoord4fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord4fv(v);
+}
+
+void gl4_2compat_glTexCoord4f(void *_glfuncs, GLfloat s, GLfloat t, GLfloat r, GLfloat q)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord4f(s, t, r, q);
+}
+
+void gl4_2compat_glTexCoord4dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord4dv(v);
+}
+
+void gl4_2compat_glTexCoord4d(void *_glfuncs, GLdouble s, GLdouble t, GLdouble r, GLdouble q)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord4d(s, t, r, q);
+}
+
+void gl4_2compat_glTexCoord3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord3sv(v);
+}
+
+void gl4_2compat_glTexCoord3s(void *_glfuncs, GLshort s, GLshort t, GLshort r)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord3s(s, t, r);
+}
+
+void gl4_2compat_glTexCoord3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord3iv(v);
+}
+
+void gl4_2compat_glTexCoord3i(void *_glfuncs, GLint s, GLint t, GLint r)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord3i(s, t, r);
+}
+
+void gl4_2compat_glTexCoord3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord3fv(v);
+}
+
+void gl4_2compat_glTexCoord3f(void *_glfuncs, GLfloat s, GLfloat t, GLfloat r)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord3f(s, t, r);
+}
+
+void gl4_2compat_glTexCoord3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord3dv(v);
+}
+
+void gl4_2compat_glTexCoord3d(void *_glfuncs, GLdouble s, GLdouble t, GLdouble r)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord3d(s, t, r);
+}
+
+void gl4_2compat_glTexCoord2sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord2sv(v);
+}
+
+void gl4_2compat_glTexCoord2s(void *_glfuncs, GLshort s, GLshort t)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord2s(s, t);
+}
+
+void gl4_2compat_glTexCoord2iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord2iv(v);
+}
+
+void gl4_2compat_glTexCoord2i(void *_glfuncs, GLint s, GLint t)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord2i(s, t);
+}
+
+void gl4_2compat_glTexCoord2fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord2fv(v);
+}
+
+void gl4_2compat_glTexCoord2f(void *_glfuncs, GLfloat s, GLfloat t)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord2f(s, t);
+}
+
+void gl4_2compat_glTexCoord2dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord2dv(v);
+}
+
+void gl4_2compat_glTexCoord2d(void *_glfuncs, GLdouble s, GLdouble t)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord2d(s, t);
+}
+
+void gl4_2compat_glTexCoord1sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord1sv(v);
+}
+
+void gl4_2compat_glTexCoord1s(void *_glfuncs, GLshort s)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord1s(s);
+}
+
+void gl4_2compat_glTexCoord1iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord1iv(v);
+}
+
+void gl4_2compat_glTexCoord1i(void *_glfuncs, GLint s)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord1i(s);
+}
+
+void gl4_2compat_glTexCoord1fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord1fv(v);
+}
+
+void gl4_2compat_glTexCoord1f(void *_glfuncs, GLfloat s)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord1f(s);
+}
+
+void gl4_2compat_glTexCoord1dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord1dv(v);
+}
+
+void gl4_2compat_glTexCoord1d(void *_glfuncs, GLdouble s)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord1d(s);
+}
+
+void gl4_2compat_glRectsv(void *_glfuncs, const GLshort* v1, const GLshort* v2)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRectsv(v1, v2);
+}
+
+void gl4_2compat_glRects(void *_glfuncs, GLshort x1, GLshort y1, GLshort x2, GLshort y2)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRects(x1, y1, x2, y2);
+}
+
+void gl4_2compat_glRectiv(void *_glfuncs, const GLint* v1, const GLint* v2)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRectiv(v1, v2);
+}
+
+void gl4_2compat_glRecti(void *_glfuncs, GLint x1, GLint y1, GLint x2, GLint y2)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRecti(x1, y1, x2, y2);
+}
+
+void gl4_2compat_glRectfv(void *_glfuncs, const GLfloat* v1, const GLfloat* v2)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRectfv(v1, v2);
+}
+
+void gl4_2compat_glRectf(void *_glfuncs, GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRectf(x1, y1, x2, y2);
+}
+
+void gl4_2compat_glRectdv(void *_glfuncs, const GLdouble* v1, const GLdouble* v2)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRectdv(v1, v2);
+}
+
+void gl4_2compat_glRectd(void *_glfuncs, GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRectd(x1, y1, x2, y2);
+}
+
+void gl4_2compat_glRasterPos4sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos4sv(v);
+}
+
+void gl4_2compat_glRasterPos4s(void *_glfuncs, GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos4s(x, y, z, w);
+}
+
+void gl4_2compat_glRasterPos4iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos4iv(v);
+}
+
+void gl4_2compat_glRasterPos4i(void *_glfuncs, GLint x, GLint y, GLint z, GLint w)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos4i(x, y, z, w);
+}
+
+void gl4_2compat_glRasterPos4fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos4fv(v);
+}
+
+void gl4_2compat_glRasterPos4f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos4f(x, y, z, w);
+}
+
+void gl4_2compat_glRasterPos4dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos4dv(v);
+}
+
+void gl4_2compat_glRasterPos4d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos4d(x, y, z, w);
+}
+
+void gl4_2compat_glRasterPos3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos3sv(v);
+}
+
+void gl4_2compat_glRasterPos3s(void *_glfuncs, GLshort x, GLshort y, GLshort z)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos3s(x, y, z);
+}
+
+void gl4_2compat_glRasterPos3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos3iv(v);
+}
+
+void gl4_2compat_glRasterPos3i(void *_glfuncs, GLint x, GLint y, GLint z)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos3i(x, y, z);
+}
+
+void gl4_2compat_glRasterPos3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos3fv(v);
+}
+
+void gl4_2compat_glRasterPos3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos3f(x, y, z);
+}
+
+void gl4_2compat_glRasterPos3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos3dv(v);
+}
+
+void gl4_2compat_glRasterPos3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos3d(x, y, z);
+}
+
+void gl4_2compat_glRasterPos2sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos2sv(v);
+}
+
+void gl4_2compat_glRasterPos2s(void *_glfuncs, GLshort x, GLshort y)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos2s(x, y);
+}
+
+void gl4_2compat_glRasterPos2iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos2iv(v);
+}
+
+void gl4_2compat_glRasterPos2i(void *_glfuncs, GLint x, GLint y)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos2i(x, y);
+}
+
+void gl4_2compat_glRasterPos2fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos2fv(v);
+}
+
+void gl4_2compat_glRasterPos2f(void *_glfuncs, GLfloat x, GLfloat y)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos2f(x, y);
+}
+
+void gl4_2compat_glRasterPos2dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos2dv(v);
+}
+
+void gl4_2compat_glRasterPos2d(void *_glfuncs, GLdouble x, GLdouble y)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos2d(x, y);
+}
+
+void gl4_2compat_glNormal3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormal3sv(v);
+}
+
+void gl4_2compat_glNormal3s(void *_glfuncs, GLshort nx, GLshort ny, GLshort nz)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormal3s(nx, ny, nz);
+}
+
+void gl4_2compat_glNormal3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormal3iv(v);
+}
+
+void gl4_2compat_glNormal3i(void *_glfuncs, GLint nx, GLint ny, GLint nz)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormal3i(nx, ny, nz);
+}
+
+void gl4_2compat_glNormal3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormal3fv(v);
+}
+
+void gl4_2compat_glNormal3f(void *_glfuncs, GLfloat nx, GLfloat ny, GLfloat nz)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormal3f(nx, ny, nz);
+}
+
+void gl4_2compat_glNormal3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormal3dv(v);
+}
+
+void gl4_2compat_glNormal3d(void *_glfuncs, GLdouble nx, GLdouble ny, GLdouble nz)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormal3d(nx, ny, nz);
+}
+
+void gl4_2compat_glNormal3bv(void *_glfuncs, const GLbyte* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormal3bv(v);
+}
+
+void gl4_2compat_glNormal3b(void *_glfuncs, GLbyte nx, GLbyte ny, GLbyte nz)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormal3b(nx, ny, nz);
+}
+
+void gl4_2compat_glIndexsv(void *_glfuncs, const GLshort* c)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexsv(c);
+}
+
+void gl4_2compat_glIndexs(void *_glfuncs, GLshort c)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexs(c);
+}
+
+void gl4_2compat_glIndexiv(void *_glfuncs, const GLint* c)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexiv(c);
+}
+
+void gl4_2compat_glIndexi(void *_glfuncs, GLint c)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexi(c);
+}
+
+void gl4_2compat_glIndexfv(void *_glfuncs, const GLfloat* c)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexfv(c);
+}
+
+void gl4_2compat_glIndexf(void *_glfuncs, GLfloat c)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexf(c);
+}
+
+void gl4_2compat_glIndexdv(void *_glfuncs, const GLdouble* c)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexdv(c);
+}
+
+void gl4_2compat_glIndexd(void *_glfuncs, GLdouble c)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexd(c);
+}
+
+void gl4_2compat_glEnd(void *_glfuncs)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glEnd();
+}
+
+void gl4_2compat_glEdgeFlagv(void *_glfuncs, const GLboolean* flag)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glEdgeFlagv(flag);
+}
+
+void gl4_2compat_glEdgeFlag(void *_glfuncs, GLboolean flag)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glEdgeFlag(flag);
+}
+
+void gl4_2compat_glColor4usv(void *_glfuncs, const GLushort* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4usv(v);
+}
+
+void gl4_2compat_glColor4us(void *_glfuncs, GLushort red, GLushort green, GLushort blue, GLushort alpha)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4us(red, green, blue, alpha);
+}
+
+void gl4_2compat_glColor4uiv(void *_glfuncs, const GLuint* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4uiv(v);
+}
+
+void gl4_2compat_glColor4ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue, GLuint alpha)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4ui(red, green, blue, alpha);
+}
+
+void gl4_2compat_glColor4ubv(void *_glfuncs, const GLubyte* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4ubv(v);
+}
+
+void gl4_2compat_glColor4ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4ub(red, green, blue, alpha);
+}
+
+void gl4_2compat_glColor4sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4sv(v);
+}
+
+void gl4_2compat_glColor4s(void *_glfuncs, GLshort red, GLshort green, GLshort blue, GLshort alpha)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4s(red, green, blue, alpha);
+}
+
+void gl4_2compat_glColor4iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4iv(v);
+}
+
+void gl4_2compat_glColor4i(void *_glfuncs, GLint red, GLint green, GLint blue, GLint alpha)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4i(red, green, blue, alpha);
+}
+
+void gl4_2compat_glColor4fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4fv(v);
+}
+
+void gl4_2compat_glColor4f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4f(red, green, blue, alpha);
+}
+
+void gl4_2compat_glColor4dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4dv(v);
+}
+
+void gl4_2compat_glColor4d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4d(red, green, blue, alpha);
+}
+
+void gl4_2compat_glColor4bv(void *_glfuncs, const GLbyte* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4bv(v);
+}
+
+void gl4_2compat_glColor4b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4b(red, green, blue, alpha);
+}
+
+void gl4_2compat_glColor3usv(void *_glfuncs, const GLushort* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3usv(v);
+}
+
+void gl4_2compat_glColor3us(void *_glfuncs, GLushort red, GLushort green, GLushort blue)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3us(red, green, blue);
+}
+
+void gl4_2compat_glColor3uiv(void *_glfuncs, const GLuint* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3uiv(v);
+}
+
+void gl4_2compat_glColor3ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3ui(red, green, blue);
+}
+
+void gl4_2compat_glColor3ubv(void *_glfuncs, const GLubyte* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3ubv(v);
+}
+
+void gl4_2compat_glColor3ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3ub(red, green, blue);
+}
+
+void gl4_2compat_glColor3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3sv(v);
+}
+
+void gl4_2compat_glColor3s(void *_glfuncs, GLshort red, GLshort green, GLshort blue)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3s(red, green, blue);
+}
+
+void gl4_2compat_glColor3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3iv(v);
+}
+
+void gl4_2compat_glColor3i(void *_glfuncs, GLint red, GLint green, GLint blue)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3i(red, green, blue);
+}
+
+void gl4_2compat_glColor3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3fv(v);
+}
+
+void gl4_2compat_glColor3f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3f(red, green, blue);
+}
+
+void gl4_2compat_glColor3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3dv(v);
+}
+
+void gl4_2compat_glColor3d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3d(red, green, blue);
+}
+
+void gl4_2compat_glColor3bv(void *_glfuncs, const GLbyte* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3bv(v);
+}
+
+void gl4_2compat_glColor3b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3b(red, green, blue);
+}
+
+void gl4_2compat_glBitmap(void *_glfuncs, GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte* bitmap)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glBitmap(width, height, xorig, yorig, xmove, ymove, bitmap);
+}
+
+void gl4_2compat_glBegin(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glBegin(mode);
+}
+
+void gl4_2compat_glListBase(void *_glfuncs, GLuint base)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glListBase(base);
+}
+
+GLuint gl4_2compat_glGenLists(void *_glfuncs, GLsizei range_)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ return _qglfuncs->glGenLists(range_);
+}
+
+void gl4_2compat_glDeleteLists(void *_glfuncs, GLuint list, GLsizei range_)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteLists(list, range_);
+}
+
+void gl4_2compat_glCallLists(void *_glfuncs, GLsizei n, GLenum gltype, const GLvoid* lists)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glCallLists(n, gltype, lists);
+}
+
+void gl4_2compat_glCallList(void *_glfuncs, GLuint list)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glCallList(list);
+}
+
+void gl4_2compat_glEndList(void *_glfuncs)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glEndList();
+}
+
+void gl4_2compat_glNewList(void *_glfuncs, GLuint list, GLenum mode)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glNewList(list, mode);
+}
+
+void gl4_2compat_glPushClientAttrib(void *_glfuncs, GLbitfield mask)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glPushClientAttrib(mask);
+}
+
+void gl4_2compat_glPopClientAttrib(void *_glfuncs)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glPopClientAttrib();
+}
+
+void gl4_2compat_glPrioritizeTextures(void *_glfuncs, GLsizei n, const GLuint* textures, const GLfloat* priorities)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glPrioritizeTextures(n, textures, priorities);
+}
+
+GLboolean gl4_2compat_glAreTexturesResident(void *_glfuncs, GLsizei n, const GLuint* textures, GLboolean* residences)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ return _qglfuncs->glAreTexturesResident(n, textures, residences);
+}
+
+void gl4_2compat_glVertexPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexPointer(size, gltype, stride, pointer);
+}
+
+void gl4_2compat_glTexCoordPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoordPointer(size, gltype, stride, pointer);
+}
+
+void gl4_2compat_glNormalPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormalPointer(gltype, stride, pointer);
+}
+
+void gl4_2compat_glInterleavedArrays(void *_glfuncs, GLenum format, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glInterleavedArrays(format, stride, pointer);
+}
+
+void gl4_2compat_glIndexPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexPointer(gltype, stride, pointer);
+}
+
+void gl4_2compat_glEnableClientState(void *_glfuncs, GLenum array)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glEnableClientState(array);
+}
+
+void gl4_2compat_glEdgeFlagPointer(void *_glfuncs, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glEdgeFlagPointer(stride, pointer);
+}
+
+void gl4_2compat_glDisableClientState(void *_glfuncs, GLenum array)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glDisableClientState(array);
+}
+
+void gl4_2compat_glColorPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorPointer(size, gltype, stride, pointer);
+}
+
+void gl4_2compat_glArrayElement(void *_glfuncs, GLint i)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glArrayElement(i);
+}
+
+void gl4_2compat_glResetMinmax(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glResetMinmax(target);
+}
+
+void gl4_2compat_glResetHistogram(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glResetHistogram(target);
+}
+
+void gl4_2compat_glMinmax(void *_glfuncs, GLenum target, GLenum internalFormat, GLboolean sink)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMinmax(target, internalFormat, sink);
+}
+
+void gl4_2compat_glHistogram(void *_glfuncs, GLenum target, GLsizei width, GLenum internalFormat, GLboolean sink)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glHistogram(target, width, internalFormat, sink);
+}
+
+void gl4_2compat_glGetMinmaxParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetMinmaxParameteriv(target, pname, params);
+}
+
+void gl4_2compat_glGetMinmaxParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetMinmaxParameterfv(target, pname, params);
+}
+
+void gl4_2compat_glGetMinmax(void *_glfuncs, GLenum target, GLboolean reset, GLenum format, GLenum gltype, GLvoid* values)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetMinmax(target, reset, format, gltype, values);
+}
+
+void gl4_2compat_glGetHistogramParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetHistogramParameteriv(target, pname, params);
+}
+
+void gl4_2compat_glGetHistogramParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetHistogramParameterfv(target, pname, params);
+}
+
+void gl4_2compat_glGetHistogram(void *_glfuncs, GLenum target, GLboolean reset, GLenum format, GLenum gltype, GLvoid* values)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetHistogram(target, reset, format, gltype, values);
+}
+
+void gl4_2compat_glSeparableFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* row, const GLvoid* column)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glSeparableFilter2D(target, internalFormat, width, height, format, gltype, row, column);
+}
+
+void gl4_2compat_glGetSeparableFilter(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* row, GLvoid* column, GLvoid* span)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetSeparableFilter(target, format, gltype, row, column, span);
+}
+
+void gl4_2compat_glGetConvolutionParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetConvolutionParameteriv(target, pname, params);
+}
+
+void gl4_2compat_glGetConvolutionParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetConvolutionParameterfv(target, pname, params);
+}
+
+void gl4_2compat_glGetConvolutionFilter(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* image)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetConvolutionFilter(target, format, gltype, image);
+}
+
+void gl4_2compat_glCopyConvolutionFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyConvolutionFilter2D(target, internalFormat, x, y, width, height);
+}
+
+void gl4_2compat_glCopyConvolutionFilter1D(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyConvolutionFilter1D(target, internalFormat, x, y, width);
+}
+
+void gl4_2compat_glConvolutionParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glConvolutionParameteriv(target, pname, params);
+}
+
+void gl4_2compat_glConvolutionParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glConvolutionParameteri(target, pname, params);
+}
+
+void gl4_2compat_glConvolutionParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glConvolutionParameterfv(target, pname, params);
+}
+
+void gl4_2compat_glConvolutionParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glConvolutionParameterf(target, pname, params);
+}
+
+void gl4_2compat_glConvolutionFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* image)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glConvolutionFilter2D(target, internalFormat, width, height, format, gltype, image);
+}
+
+void gl4_2compat_glConvolutionFilter1D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLenum format, GLenum gltype, const GLvoid* image)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glConvolutionFilter1D(target, internalFormat, width, format, gltype, image);
+}
+
+void gl4_2compat_glCopyColorSubTable(void *_glfuncs, GLenum target, GLsizei start, GLint x, GLint y, GLsizei width)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyColorSubTable(target, start, x, y, width);
+}
+
+void gl4_2compat_glColorSubTable(void *_glfuncs, GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum gltype, const GLvoid* data)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorSubTable(target, start, count, format, gltype, data);
+}
+
+void gl4_2compat_glGetColorTableParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetColorTableParameteriv(target, pname, params);
+}
+
+void gl4_2compat_glGetColorTableParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetColorTableParameterfv(target, pname, params);
+}
+
+void gl4_2compat_glGetColorTable(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* table)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetColorTable(target, format, gltype, table);
+}
+
+void gl4_2compat_glCopyColorTable(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyColorTable(target, internalFormat, x, y, width);
+}
+
+void gl4_2compat_glColorTableParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorTableParameteriv(target, pname, params);
+}
+
+void gl4_2compat_glColorTableParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorTableParameterfv(target, pname, params);
+}
+
+void gl4_2compat_glColorTable(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLenum format, GLenum gltype, const GLvoid* table)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorTable(target, internalFormat, width, format, gltype, table);
+}
+
+void gl4_2compat_glMultTransposeMatrixd(void *_glfuncs, const GLdouble* m)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultTransposeMatrixd(m);
+}
+
+void gl4_2compat_glMultTransposeMatrixf(void *_glfuncs, const GLfloat* m)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultTransposeMatrixf(m);
+}
+
+void gl4_2compat_glLoadTransposeMatrixd(void *_glfuncs, const GLdouble* m)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glLoadTransposeMatrixd(m);
+}
+
+void gl4_2compat_glLoadTransposeMatrixf(void *_glfuncs, const GLfloat* m)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glLoadTransposeMatrixf(m);
+}
+
+void gl4_2compat_glMultiTexCoord4sv(void *_glfuncs, GLenum target, const GLshort* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4sv(target, v);
+}
+
+void gl4_2compat_glMultiTexCoord4s(void *_glfuncs, GLenum target, GLshort s, GLshort t, GLshort r, GLshort q)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4s(target, s, t, r, q);
+}
+
+void gl4_2compat_glMultiTexCoord4iv(void *_glfuncs, GLenum target, const GLint* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4iv(target, v);
+}
+
+void gl4_2compat_glMultiTexCoord4i(void *_glfuncs, GLenum target, GLint s, GLint t, GLint r, GLint q)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4i(target, s, t, r, q);
+}
+
+void gl4_2compat_glMultiTexCoord4fv(void *_glfuncs, GLenum target, const GLfloat* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4fv(target, v);
+}
+
+void gl4_2compat_glMultiTexCoord4f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4f(target, s, t, r, q);
+}
+
+void gl4_2compat_glMultiTexCoord4dv(void *_glfuncs, GLenum target, const GLdouble* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4dv(target, v);
+}
+
+void gl4_2compat_glMultiTexCoord4d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4d(target, s, t, r, q);
+}
+
+void gl4_2compat_glMultiTexCoord3sv(void *_glfuncs, GLenum target, const GLshort* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3sv(target, v);
+}
+
+void gl4_2compat_glMultiTexCoord3s(void *_glfuncs, GLenum target, GLshort s, GLshort t, GLshort r)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3s(target, s, t, r);
+}
+
+void gl4_2compat_glMultiTexCoord3iv(void *_glfuncs, GLenum target, const GLint* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3iv(target, v);
+}
+
+void gl4_2compat_glMultiTexCoord3i(void *_glfuncs, GLenum target, GLint s, GLint t, GLint r)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3i(target, s, t, r);
+}
+
+void gl4_2compat_glMultiTexCoord3fv(void *_glfuncs, GLenum target, const GLfloat* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3fv(target, v);
+}
+
+void gl4_2compat_glMultiTexCoord3f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t, GLfloat r)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3f(target, s, t, r);
+}
+
+void gl4_2compat_glMultiTexCoord3dv(void *_glfuncs, GLenum target, const GLdouble* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3dv(target, v);
+}
+
+void gl4_2compat_glMultiTexCoord3d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t, GLdouble r)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3d(target, s, t, r);
+}
+
+void gl4_2compat_glMultiTexCoord2sv(void *_glfuncs, GLenum target, const GLshort* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2sv(target, v);
+}
+
+void gl4_2compat_glMultiTexCoord2s(void *_glfuncs, GLenum target, GLshort s, GLshort t)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2s(target, s, t);
+}
+
+void gl4_2compat_glMultiTexCoord2iv(void *_glfuncs, GLenum target, const GLint* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2iv(target, v);
+}
+
+void gl4_2compat_glMultiTexCoord2i(void *_glfuncs, GLenum target, GLint s, GLint t)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2i(target, s, t);
+}
+
+void gl4_2compat_glMultiTexCoord2fv(void *_glfuncs, GLenum target, const GLfloat* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2fv(target, v);
+}
+
+void gl4_2compat_glMultiTexCoord2f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2f(target, s, t);
+}
+
+void gl4_2compat_glMultiTexCoord2dv(void *_glfuncs, GLenum target, const GLdouble* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2dv(target, v);
+}
+
+void gl4_2compat_glMultiTexCoord2d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2d(target, s, t);
+}
+
+void gl4_2compat_glMultiTexCoord1sv(void *_glfuncs, GLenum target, const GLshort* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1sv(target, v);
+}
+
+void gl4_2compat_glMultiTexCoord1s(void *_glfuncs, GLenum target, GLshort s)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1s(target, s);
+}
+
+void gl4_2compat_glMultiTexCoord1iv(void *_glfuncs, GLenum target, const GLint* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1iv(target, v);
+}
+
+void gl4_2compat_glMultiTexCoord1i(void *_glfuncs, GLenum target, GLint s)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1i(target, s);
+}
+
+void gl4_2compat_glMultiTexCoord1fv(void *_glfuncs, GLenum target, const GLfloat* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1fv(target, v);
+}
+
+void gl4_2compat_glMultiTexCoord1f(void *_glfuncs, GLenum target, GLfloat s)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1f(target, s);
+}
+
+void gl4_2compat_glMultiTexCoord1dv(void *_glfuncs, GLenum target, const GLdouble* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1dv(target, v);
+}
+
+void gl4_2compat_glMultiTexCoord1d(void *_glfuncs, GLenum target, GLdouble s)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1d(target, s);
+}
+
+void gl4_2compat_glClientActiveTexture(void *_glfuncs, GLenum texture)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glClientActiveTexture(texture);
+}
+
+void gl4_2compat_glWindowPos3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos3sv(v);
+}
+
+void gl4_2compat_glWindowPos3s(void *_glfuncs, GLshort x, GLshort y, GLshort z)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos3s(x, y, z);
+}
+
+void gl4_2compat_glWindowPos3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos3iv(v);
+}
+
+void gl4_2compat_glWindowPos3i(void *_glfuncs, GLint x, GLint y, GLint z)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos3i(x, y, z);
+}
+
+void gl4_2compat_glWindowPos3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos3fv(v);
+}
+
+void gl4_2compat_glWindowPos3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos3f(x, y, z);
+}
+
+void gl4_2compat_glWindowPos3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos3dv(v);
+}
+
+void gl4_2compat_glWindowPos3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos3d(x, y, z);
+}
+
+void gl4_2compat_glWindowPos2sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos2sv(v);
+}
+
+void gl4_2compat_glWindowPos2s(void *_glfuncs, GLshort x, GLshort y)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos2s(x, y);
+}
+
+void gl4_2compat_glWindowPos2iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos2iv(v);
+}
+
+void gl4_2compat_glWindowPos2i(void *_glfuncs, GLint x, GLint y)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos2i(x, y);
+}
+
+void gl4_2compat_glWindowPos2fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos2fv(v);
+}
+
+void gl4_2compat_glWindowPos2f(void *_glfuncs, GLfloat x, GLfloat y)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos2f(x, y);
+}
+
+void gl4_2compat_glWindowPos2dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos2dv(v);
+}
+
+void gl4_2compat_glWindowPos2d(void *_glfuncs, GLdouble x, GLdouble y)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos2d(x, y);
+}
+
+void gl4_2compat_glSecondaryColorPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColorPointer(size, gltype, stride, pointer);
+}
+
+void gl4_2compat_glSecondaryColor3usv(void *_glfuncs, const GLushort* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3usv(v);
+}
+
+void gl4_2compat_glSecondaryColor3us(void *_glfuncs, GLushort red, GLushort green, GLushort blue)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3us(red, green, blue);
+}
+
+void gl4_2compat_glSecondaryColor3uiv(void *_glfuncs, const GLuint* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3uiv(v);
+}
+
+void gl4_2compat_glSecondaryColor3ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3ui(red, green, blue);
+}
+
+void gl4_2compat_glSecondaryColor3ubv(void *_glfuncs, const GLubyte* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3ubv(v);
+}
+
+void gl4_2compat_glSecondaryColor3ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3ub(red, green, blue);
+}
+
+void gl4_2compat_glSecondaryColor3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3sv(v);
+}
+
+void gl4_2compat_glSecondaryColor3s(void *_glfuncs, GLshort red, GLshort green, GLshort blue)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3s(red, green, blue);
+}
+
+void gl4_2compat_glSecondaryColor3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3iv(v);
+}
+
+void gl4_2compat_glSecondaryColor3i(void *_glfuncs, GLint red, GLint green, GLint blue)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3i(red, green, blue);
+}
+
+void gl4_2compat_glSecondaryColor3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3fv(v);
+}
+
+void gl4_2compat_glSecondaryColor3f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3f(red, green, blue);
+}
+
+void gl4_2compat_glSecondaryColor3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3dv(v);
+}
+
+void gl4_2compat_glSecondaryColor3d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3d(red, green, blue);
+}
+
+void gl4_2compat_glSecondaryColor3bv(void *_glfuncs, const GLbyte* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3bv(v);
+}
+
+void gl4_2compat_glSecondaryColor3b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3b(red, green, blue);
+}
+
+void gl4_2compat_glFogCoordPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glFogCoordPointer(gltype, stride, pointer);
+}
+
+void gl4_2compat_glFogCoorddv(void *_glfuncs, const GLdouble* coord)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glFogCoorddv(coord);
+}
+
+void gl4_2compat_glFogCoordd(void *_glfuncs, GLdouble coord)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glFogCoordd(coord);
+}
+
+void gl4_2compat_glFogCoordfv(void *_glfuncs, const GLfloat* coord)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glFogCoordfv(coord);
+}
+
+void gl4_2compat_glFogCoordf(void *_glfuncs, GLfloat coord)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glFogCoordf(coord);
+}
+
+void gl4_2compat_glVertexAttrib4usv(void *_glfuncs, GLuint index, const GLushort* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4usv(index, v);
+}
+
+void gl4_2compat_glVertexAttrib4uiv(void *_glfuncs, GLuint index, const GLuint* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4uiv(index, v);
+}
+
+void gl4_2compat_glVertexAttrib4ubv(void *_glfuncs, GLuint index, const GLubyte* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4ubv(index, v);
+}
+
+void gl4_2compat_glVertexAttrib4sv(void *_glfuncs, GLuint index, const GLshort* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4sv(index, v);
+}
+
+void gl4_2compat_glVertexAttrib4s(void *_glfuncs, GLuint index, GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4s(index, x, y, z, w);
+}
+
+void gl4_2compat_glVertexAttrib4iv(void *_glfuncs, GLuint index, const GLint* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4iv(index, v);
+}
+
+void gl4_2compat_glVertexAttrib4fv(void *_glfuncs, GLuint index, const GLfloat* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4fv(index, v);
+}
+
+void gl4_2compat_glVertexAttrib4f(void *_glfuncs, GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4f(index, x, y, z, w);
+}
+
+void gl4_2compat_glVertexAttrib4dv(void *_glfuncs, GLuint index, const GLdouble* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4dv(index, v);
+}
+
+void gl4_2compat_glVertexAttrib4d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4d(index, x, y, z, w);
+}
+
+void gl4_2compat_glVertexAttrib4bv(void *_glfuncs, GLuint index, const GLbyte* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4bv(index, v);
+}
+
+void gl4_2compat_glVertexAttrib4Nusv(void *_glfuncs, GLuint index, const GLushort* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Nusv(index, v);
+}
+
+void gl4_2compat_glVertexAttrib4Nuiv(void *_glfuncs, GLuint index, const GLuint* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Nuiv(index, v);
+}
+
+void gl4_2compat_glVertexAttrib4Nubv(void *_glfuncs, GLuint index, const GLubyte* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Nubv(index, v);
+}
+
+void gl4_2compat_glVertexAttrib4Nub(void *_glfuncs, GLuint index, GLubyte x, GLubyte y, GLubyte z, GLubyte w)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Nub(index, x, y, z, w);
+}
+
+void gl4_2compat_glVertexAttrib4Nsv(void *_glfuncs, GLuint index, const GLshort* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Nsv(index, v);
+}
+
+void gl4_2compat_glVertexAttrib4Niv(void *_glfuncs, GLuint index, const GLint* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Niv(index, v);
+}
+
+void gl4_2compat_glVertexAttrib4Nbv(void *_glfuncs, GLuint index, const GLbyte* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Nbv(index, v);
+}
+
+void gl4_2compat_glVertexAttrib3sv(void *_glfuncs, GLuint index, const GLshort* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib3sv(index, v);
+}
+
+void gl4_2compat_glVertexAttrib3s(void *_glfuncs, GLuint index, GLshort x, GLshort y, GLshort z)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib3s(index, x, y, z);
+}
+
+void gl4_2compat_glVertexAttrib3fv(void *_glfuncs, GLuint index, const GLfloat* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib3fv(index, v);
+}
+
+void gl4_2compat_glVertexAttrib3f(void *_glfuncs, GLuint index, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib3f(index, x, y, z);
+}
+
+void gl4_2compat_glVertexAttrib3dv(void *_glfuncs, GLuint index, const GLdouble* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib3dv(index, v);
+}
+
+void gl4_2compat_glVertexAttrib3d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib3d(index, x, y, z);
+}
+
+void gl4_2compat_glVertexAttrib2sv(void *_glfuncs, GLuint index, const GLshort* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib2sv(index, v);
+}
+
+void gl4_2compat_glVertexAttrib2s(void *_glfuncs, GLuint index, GLshort x, GLshort y)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib2s(index, x, y);
+}
+
+void gl4_2compat_glVertexAttrib2fv(void *_glfuncs, GLuint index, const GLfloat* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib2fv(index, v);
+}
+
+void gl4_2compat_glVertexAttrib2f(void *_glfuncs, GLuint index, GLfloat x, GLfloat y)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib2f(index, x, y);
+}
+
+void gl4_2compat_glVertexAttrib2dv(void *_glfuncs, GLuint index, const GLdouble* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib2dv(index, v);
+}
+
+void gl4_2compat_glVertexAttrib2d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib2d(index, x, y);
+}
+
+void gl4_2compat_glVertexAttrib1sv(void *_glfuncs, GLuint index, const GLshort* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib1sv(index, v);
+}
+
+void gl4_2compat_glVertexAttrib1s(void *_glfuncs, GLuint index, GLshort x)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib1s(index, x);
+}
+
+void gl4_2compat_glVertexAttrib1fv(void *_glfuncs, GLuint index, const GLfloat* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib1fv(index, v);
+}
+
+void gl4_2compat_glVertexAttrib1f(void *_glfuncs, GLuint index, GLfloat x)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib1f(index, x);
+}
+
+void gl4_2compat_glVertexAttrib1dv(void *_glfuncs, GLuint index, const GLdouble* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib1dv(index, v);
+}
+
+void gl4_2compat_glVertexAttrib1d(void *_glfuncs, GLuint index, GLdouble x)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib1d(index, x);
+}
+
+void gl4_2compat_glVertexAttribI4usv(void *_glfuncs, GLuint index, const GLushort* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI4usv(index, v);
+}
+
+void gl4_2compat_glVertexAttribI4ubv(void *_glfuncs, GLuint index, const GLubyte* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI4ubv(index, v);
+}
+
+void gl4_2compat_glVertexAttribI4sv(void *_glfuncs, GLuint index, const GLshort* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI4sv(index, v);
+}
+
+void gl4_2compat_glVertexAttribI4bv(void *_glfuncs, GLuint index, const GLbyte* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI4bv(index, v);
+}
+
+void gl4_2compat_glVertexAttribI4uiv(void *_glfuncs, GLuint index, const GLuint* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI4uiv(index, v);
+}
+
+void gl4_2compat_glVertexAttribI3uiv(void *_glfuncs, GLuint index, const GLuint* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI3uiv(index, v);
+}
+
+void gl4_2compat_glVertexAttribI2uiv(void *_glfuncs, GLuint index, const GLuint* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI2uiv(index, v);
+}
+
+void gl4_2compat_glVertexAttribI1uiv(void *_glfuncs, GLuint index, const GLuint* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI1uiv(index, v);
+}
+
+void gl4_2compat_glVertexAttribI4iv(void *_glfuncs, GLuint index, const GLint* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI4iv(index, v);
+}
+
+void gl4_2compat_glVertexAttribI3iv(void *_glfuncs, GLuint index, const GLint* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI3iv(index, v);
+}
+
+void gl4_2compat_glVertexAttribI2iv(void *_glfuncs, GLuint index, const GLint* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI2iv(index, v);
+}
+
+void gl4_2compat_glVertexAttribI1iv(void *_glfuncs, GLuint index, const GLint* v)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI1iv(index, v);
+}
+
+void gl4_2compat_glVertexAttribI4ui(void *_glfuncs, GLuint index, GLuint x, GLuint y, GLuint z, GLuint w)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI4ui(index, x, y, z, w);
+}
+
+void gl4_2compat_glVertexAttribI3ui(void *_glfuncs, GLuint index, GLuint x, GLuint y, GLuint z)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI3ui(index, x, y, z);
+}
+
+void gl4_2compat_glVertexAttribI2ui(void *_glfuncs, GLuint index, GLuint x, GLuint y)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI2ui(index, x, y);
+}
+
+void gl4_2compat_glVertexAttribI1ui(void *_glfuncs, GLuint index, GLuint x)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI1ui(index, x);
+}
+
+void gl4_2compat_glVertexAttribI4i(void *_glfuncs, GLuint index, GLint x, GLint y, GLint z, GLint w)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI4i(index, x, y, z, w);
+}
+
+void gl4_2compat_glVertexAttribI3i(void *_glfuncs, GLuint index, GLint x, GLint y, GLint z)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI3i(index, x, y, z);
+}
+
+void gl4_2compat_glVertexAttribI2i(void *_glfuncs, GLuint index, GLint x, GLint y)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI2i(index, x, y);
+}
+
+void gl4_2compat_glVertexAttribI1i(void *_glfuncs, GLuint index, GLint x)
+{
+ QOpenGLFunctions_4_2_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI1i(index, x);
+}
+
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.2compat/funcs.h b/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.2compat/funcs.h
new file mode 100644
index 000000000..964194dcc
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.2compat/funcs.h
@@ -0,0 +1,932 @@
+
+// ** file automatically generated by glgen -- do not edit manually **
+
+#ifndef __cplusplus
+#include <inttypes.h>
+#include <stddef.h>
+typedef unsigned int GLenum;
+typedef unsigned char GLboolean;
+typedef unsigned int GLbitfield;
+typedef void GLvoid;
+typedef char GLchar;
+typedef signed char GLbyte; /* 1-byte signed */
+typedef short GLshort; /* 2-byte signed */
+typedef int GLint; /* 4-byte signed */
+typedef unsigned char GLubyte; /* 1-byte unsigned */
+typedef unsigned short GLushort; /* 2-byte unsigned */
+typedef unsigned int GLuint; /* 4-byte unsigned */
+typedef int GLsizei; /* 4-byte signed */
+typedef float GLfloat; /* single precision float */
+typedef float GLclampf; /* single precision float in [0,1] */
+typedef double GLdouble; /* double precision float */
+typedef double GLclampd; /* double precision float in [0,1] */
+typedef int64_t GLint64;
+typedef uint64_t GLuint64;
+typedef ptrdiff_t GLintptr;
+typedef ptrdiff_t GLsizeiptr;
+typedef ptrdiff_t GLintptrARB;
+typedef ptrdiff_t GLsizeiptrARB;
+typedef struct __GLsync *GLsync;
+#endif
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+void *gl4_2compat_funcs();
+
+void gl4_2compat_glViewport(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl4_2compat_glDepthRange(void *_glfuncs, GLdouble nearVal, GLdouble farVal);
+GLboolean gl4_2compat_glIsEnabled(void *_glfuncs, GLenum cap);
+void gl4_2compat_glGetTexLevelParameteriv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLint* params);
+void gl4_2compat_glGetTexLevelParameterfv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLfloat* params);
+void gl4_2compat_glGetTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl4_2compat_glGetTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl4_2compat_glGetTexImage(void *_glfuncs, GLenum target, GLint level, GLenum format, GLenum gltype, GLvoid* pixels);
+void gl4_2compat_glGetIntegerv(void *_glfuncs, GLenum pname, GLint* params);
+void gl4_2compat_glGetFloatv(void *_glfuncs, GLenum pname, GLfloat* params);
+GLenum gl4_2compat_glGetError(void *_glfuncs);
+void gl4_2compat_glGetDoublev(void *_glfuncs, GLenum pname, GLdouble* params);
+void gl4_2compat_glGetBooleanv(void *_glfuncs, GLenum pname, GLboolean* params);
+void gl4_2compat_glReadPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum gltype, GLvoid* pixels);
+void gl4_2compat_glReadBuffer(void *_glfuncs, GLenum mode);
+void gl4_2compat_glPixelStorei(void *_glfuncs, GLenum pname, GLint param);
+void gl4_2compat_glPixelStoref(void *_glfuncs, GLenum pname, GLfloat param);
+void gl4_2compat_glDepthFunc(void *_glfuncs, GLenum glfunc);
+void gl4_2compat_glStencilOp(void *_glfuncs, GLenum fail, GLenum zfail, GLenum zpass);
+void gl4_2compat_glStencilFunc(void *_glfuncs, GLenum glfunc, GLint ref, GLuint mask);
+void gl4_2compat_glLogicOp(void *_glfuncs, GLenum opcode);
+void gl4_2compat_glBlendFunc(void *_glfuncs, GLenum sfactor, GLenum dfactor);
+void gl4_2compat_glFlush(void *_glfuncs);
+void gl4_2compat_glFinish(void *_glfuncs);
+void gl4_2compat_glEnable(void *_glfuncs, GLenum cap);
+void gl4_2compat_glDisable(void *_glfuncs, GLenum cap);
+void gl4_2compat_glDepthMask(void *_glfuncs, GLboolean flag);
+void gl4_2compat_glColorMask(void *_glfuncs, GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha);
+void gl4_2compat_glStencilMask(void *_glfuncs, GLuint mask);
+void gl4_2compat_glClearDepth(void *_glfuncs, GLdouble depth);
+void gl4_2compat_glClearStencil(void *_glfuncs, GLint s);
+void gl4_2compat_glClearColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl4_2compat_glClear(void *_glfuncs, GLbitfield mask);
+void gl4_2compat_glDrawBuffer(void *_glfuncs, GLenum mode);
+void gl4_2compat_glTexImage2D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl4_2compat_glTexImage1D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl4_2compat_glTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl4_2compat_glTexParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint param);
+void gl4_2compat_glTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl4_2compat_glTexParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param);
+void gl4_2compat_glScissor(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl4_2compat_glPolygonMode(void *_glfuncs, GLenum face, GLenum mode);
+void gl4_2compat_glPointSize(void *_glfuncs, GLfloat size);
+void gl4_2compat_glLineWidth(void *_glfuncs, GLfloat width);
+void gl4_2compat_glHint(void *_glfuncs, GLenum target, GLenum mode);
+void gl4_2compat_glFrontFace(void *_glfuncs, GLenum mode);
+void gl4_2compat_glCullFace(void *_glfuncs, GLenum mode);
+void gl4_2compat_glIndexubv(void *_glfuncs, const GLubyte* c);
+void gl4_2compat_glIndexub(void *_glfuncs, GLubyte c);
+GLboolean gl4_2compat_glIsTexture(void *_glfuncs, GLuint texture);
+void gl4_2compat_glGenTextures(void *_glfuncs, GLsizei n, GLuint* textures);
+void gl4_2compat_glDeleteTextures(void *_glfuncs, GLsizei n, const GLuint* textures);
+void gl4_2compat_glBindTexture(void *_glfuncs, GLenum target, GLuint texture);
+void gl4_2compat_glTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl4_2compat_glTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl4_2compat_glCopyTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl4_2compat_glCopyTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width);
+void gl4_2compat_glCopyTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border);
+void gl4_2compat_glCopyTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLint border);
+void gl4_2compat_glPolygonOffset(void *_glfuncs, GLfloat factor, GLfloat units);
+void gl4_2compat_glDrawElements(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices);
+void gl4_2compat_glDrawArrays(void *_glfuncs, GLenum mode, GLint first, GLsizei count);
+void gl4_2compat_glCopyTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl4_2compat_glTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl4_2compat_glTexImage3D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl4_2compat_glDrawRangeElements(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices);
+void gl4_2compat_glBlendEquation(void *_glfuncs, GLenum mode);
+void gl4_2compat_glBlendColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl4_2compat_glGetCompressedTexImage(void *_glfuncs, GLenum target, GLint level, GLvoid* img);
+void gl4_2compat_glCompressedTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid* data);
+void gl4_2compat_glCompressedTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid* data);
+void gl4_2compat_glCompressedTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid* data);
+void gl4_2compat_glCompressedTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid* data);
+void gl4_2compat_glCompressedTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid* data);
+void gl4_2compat_glCompressedTexImage3D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid* data);
+void gl4_2compat_glSampleCoverage(void *_glfuncs, GLfloat value, GLboolean invert);
+void gl4_2compat_glActiveTexture(void *_glfuncs, GLenum texture);
+void gl4_2compat_glPointParameteriv(void *_glfuncs, GLenum pname, const GLint* params);
+void gl4_2compat_glPointParameteri(void *_glfuncs, GLenum pname, GLint param);
+void gl4_2compat_glPointParameterfv(void *_glfuncs, GLenum pname, const GLfloat* params);
+void gl4_2compat_glPointParameterf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl4_2compat_glMultiDrawArrays(void *_glfuncs, GLenum mode, const GLint* first, const GLsizei* count, GLsizei drawcount);
+void gl4_2compat_glBlendFuncSeparate(void *_glfuncs, GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha);
+void gl4_2compat_glGetBufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+GLboolean gl4_2compat_glUnmapBuffer(void *_glfuncs, GLenum target);
+void gl4_2compat_glGetBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, GLvoid* data);
+void gl4_2compat_glBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid* data);
+void gl4_2compat_glBufferData(void *_glfuncs, GLenum target, GLsizeiptr size, const GLvoid* data, GLenum usage);
+GLboolean gl4_2compat_glIsBuffer(void *_glfuncs, GLuint buffer);
+void gl4_2compat_glGenBuffers(void *_glfuncs, GLsizei n, GLuint* buffers);
+void gl4_2compat_glDeleteBuffers(void *_glfuncs, GLsizei n, const GLuint* buffers);
+void gl4_2compat_glBindBuffer(void *_glfuncs, GLenum target, GLuint buffer);
+void gl4_2compat_glGetQueryObjectuiv(void *_glfuncs, GLuint id, GLenum pname, GLuint* params);
+void gl4_2compat_glGetQueryObjectiv(void *_glfuncs, GLuint id, GLenum pname, GLint* params);
+void gl4_2compat_glGetQueryiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl4_2compat_glEndQuery(void *_glfuncs, GLenum target);
+void gl4_2compat_glBeginQuery(void *_glfuncs, GLenum target, GLuint id);
+GLboolean gl4_2compat_glIsQuery(void *_glfuncs, GLuint id);
+void gl4_2compat_glDeleteQueries(void *_glfuncs, GLsizei n, const GLuint* ids);
+void gl4_2compat_glGenQueries(void *_glfuncs, GLsizei n, GLuint* ids);
+void gl4_2compat_glVertexAttribPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLboolean normalized, GLsizei stride, const GLvoid* offset);
+void gl4_2compat_glValidateProgram(void *_glfuncs, GLuint program);
+void gl4_2compat_glUniformMatrix4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_2compat_glUniformMatrix3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_2compat_glUniformMatrix2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_2compat_glUniform4iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl4_2compat_glUniform3iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl4_2compat_glUniform2iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl4_2compat_glUniform1iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl4_2compat_glUniform4fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl4_2compat_glUniform3fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl4_2compat_glUniform2fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl4_2compat_glUniform1fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl4_2compat_glUniform4i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2, GLint v3);
+void gl4_2compat_glUniform3i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2);
+void gl4_2compat_glUniform2i(void *_glfuncs, GLint location, GLint v0, GLint v1);
+void gl4_2compat_glUniform1i(void *_glfuncs, GLint location, GLint v0);
+void gl4_2compat_glUniform4f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3);
+void gl4_2compat_glUniform3f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2);
+void gl4_2compat_glUniform2f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1);
+void gl4_2compat_glUniform1f(void *_glfuncs, GLint location, GLfloat v0);
+void gl4_2compat_glUseProgram(void *_glfuncs, GLuint program);
+void gl4_2compat_glShaderSource(void *_glfuncs, GLuint shader, GLsizei count, const GLchar** source, const GLint* length);
+void gl4_2compat_glLinkProgram(void *_glfuncs, GLuint program);
+GLboolean gl4_2compat_glIsShader(void *_glfuncs, GLuint shader);
+GLboolean gl4_2compat_glIsProgram(void *_glfuncs, GLuint program);
+void gl4_2compat_glGetVertexAttribiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params);
+void gl4_2compat_glGetVertexAttribfv(void *_glfuncs, GLuint index, GLenum pname, GLfloat* params);
+void gl4_2compat_glGetVertexAttribdv(void *_glfuncs, GLuint index, GLenum pname, GLdouble* params);
+void gl4_2compat_glGetUniformiv(void *_glfuncs, GLuint program, GLint location, GLint* params);
+void gl4_2compat_glGetUniformfv(void *_glfuncs, GLuint program, GLint location, GLfloat* params);
+GLint gl4_2compat_glGetUniformLocation(void *_glfuncs, GLuint program, const GLchar* name);
+void gl4_2compat_glGetShaderSource(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* source);
+void gl4_2compat_glGetShaderInfoLog(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* infoLog);
+void gl4_2compat_glGetShaderiv(void *_glfuncs, GLuint shader, GLenum pname, GLint* params);
+void gl4_2compat_glGetProgramInfoLog(void *_glfuncs, GLuint program, GLsizei bufSize, GLsizei* length, GLchar* infoLog);
+void gl4_2compat_glGetProgramiv(void *_glfuncs, GLuint program, GLenum pname, GLint* params);
+GLint gl4_2compat_glGetAttribLocation(void *_glfuncs, GLuint program, const GLchar* name);
+void gl4_2compat_glGetAttachedShaders(void *_glfuncs, GLuint program, GLsizei maxCount, GLsizei* count, GLuint* obj);
+void gl4_2compat_glGetActiveUniform(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name);
+void gl4_2compat_glGetActiveAttrib(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name);
+void gl4_2compat_glEnableVertexAttribArray(void *_glfuncs, GLuint index);
+void gl4_2compat_glDisableVertexAttribArray(void *_glfuncs, GLuint index);
+void gl4_2compat_glDetachShader(void *_glfuncs, GLuint program, GLuint shader);
+void gl4_2compat_glDeleteShader(void *_glfuncs, GLuint shader);
+void gl4_2compat_glDeleteProgram(void *_glfuncs, GLuint program);
+GLuint gl4_2compat_glCreateShader(void *_glfuncs, GLenum gltype);
+GLuint gl4_2compat_glCreateProgram(void *_glfuncs);
+void gl4_2compat_glCompileShader(void *_glfuncs, GLuint shader);
+void gl4_2compat_glBindAttribLocation(void *_glfuncs, GLuint program, GLuint index, const GLchar* name);
+void gl4_2compat_glAttachShader(void *_glfuncs, GLuint program, GLuint shader);
+void gl4_2compat_glStencilMaskSeparate(void *_glfuncs, GLenum face, GLuint mask);
+void gl4_2compat_glStencilFuncSeparate(void *_glfuncs, GLenum face, GLenum glfunc, GLint ref, GLuint mask);
+void gl4_2compat_glStencilOpSeparate(void *_glfuncs, GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass);
+void gl4_2compat_glDrawBuffers(void *_glfuncs, GLsizei n, const GLenum* bufs);
+void gl4_2compat_glBlendEquationSeparate(void *_glfuncs, GLenum modeRGB, GLenum modeAlpha);
+void gl4_2compat_glUniformMatrix4x3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_2compat_glUniformMatrix3x4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_2compat_glUniformMatrix4x2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_2compat_glUniformMatrix2x4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_2compat_glUniformMatrix3x2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_2compat_glUniformMatrix2x3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+GLboolean gl4_2compat_glIsVertexArray(void *_glfuncs, GLuint array);
+void gl4_2compat_glGenVertexArrays(void *_glfuncs, GLsizei n, GLuint* arrays);
+void gl4_2compat_glDeleteVertexArrays(void *_glfuncs, GLsizei n, const GLuint* arrays);
+void gl4_2compat_glBindVertexArray(void *_glfuncs, GLuint array);
+void gl4_2compat_glFlushMappedBufferRange(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr length);
+void gl4_2compat_glFramebufferTextureLayer(void *_glfuncs, GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer);
+void gl4_2compat_glRenderbufferStorageMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLenum internalFormat, GLsizei width, GLsizei height);
+void gl4_2compat_glBlitFramebuffer(void *_glfuncs, GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter);
+void gl4_2compat_glGenerateMipmap(void *_glfuncs, GLenum target);
+void gl4_2compat_glGetFramebufferAttachmentParameteriv(void *_glfuncs, GLenum target, GLenum attachment, GLenum pname, GLint* params);
+void gl4_2compat_glFramebufferRenderbuffer(void *_glfuncs, GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer);
+void gl4_2compat_glFramebufferTexture3D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset);
+void gl4_2compat_glFramebufferTexture2D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+void gl4_2compat_glFramebufferTexture1D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+GLenum gl4_2compat_glCheckFramebufferStatus(void *_glfuncs, GLenum target);
+void gl4_2compat_glGenFramebuffers(void *_glfuncs, GLsizei n, GLuint* framebuffers);
+void gl4_2compat_glDeleteFramebuffers(void *_glfuncs, GLsizei n, const GLuint* framebuffers);
+void gl4_2compat_glBindFramebuffer(void *_glfuncs, GLenum target, GLuint framebuffer);
+GLboolean gl4_2compat_glIsFramebuffer(void *_glfuncs, GLuint framebuffer);
+void gl4_2compat_glGetRenderbufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl4_2compat_glRenderbufferStorage(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height);
+void gl4_2compat_glGenRenderbuffers(void *_glfuncs, GLsizei n, GLuint* renderbuffers);
+void gl4_2compat_glDeleteRenderbuffers(void *_glfuncs, GLsizei n, const GLuint* renderbuffers);
+void gl4_2compat_glBindRenderbuffer(void *_glfuncs, GLenum target, GLuint renderbuffer);
+GLboolean gl4_2compat_glIsRenderbuffer(void *_glfuncs, GLuint renderbuffer);
+void gl4_2compat_glClearBufferfi(void *_glfuncs, GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil);
+void gl4_2compat_glClearBufferfv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLfloat* value);
+void gl4_2compat_glClearBufferuiv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLuint* value);
+void gl4_2compat_glClearBufferiv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLint* value);
+void gl4_2compat_glGetTexParameterIuiv(void *_glfuncs, GLenum target, GLenum pname, GLuint* params);
+void gl4_2compat_glGetTexParameterIiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl4_2compat_glTexParameterIuiv(void *_glfuncs, GLenum target, GLenum pname, const GLuint* params);
+void gl4_2compat_glTexParameterIiv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl4_2compat_glUniform4uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value);
+void gl4_2compat_glUniform3uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value);
+void gl4_2compat_glUniform2uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value);
+void gl4_2compat_glUniform1uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value);
+void gl4_2compat_glUniform4ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3);
+void gl4_2compat_glUniform3ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1, GLuint v2);
+void gl4_2compat_glUniform2ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1);
+void gl4_2compat_glUniform1ui(void *_glfuncs, GLint location, GLuint v0);
+GLint gl4_2compat_glGetFragDataLocation(void *_glfuncs, GLuint program, const GLchar* name);
+void gl4_2compat_glBindFragDataLocation(void *_glfuncs, GLuint program, GLuint color, const GLchar* name);
+void gl4_2compat_glGetUniformuiv(void *_glfuncs, GLuint program, GLint location, GLuint* params);
+void gl4_2compat_glGetVertexAttribIuiv(void *_glfuncs, GLuint index, GLenum pname, GLuint* params);
+void gl4_2compat_glGetVertexAttribIiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params);
+void gl4_2compat_glVertexAttribIPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl4_2compat_glEndConditionalRender(void *_glfuncs);
+void gl4_2compat_glBeginConditionalRender(void *_glfuncs, GLuint id, GLenum mode);
+void gl4_2compat_glClampColor(void *_glfuncs, GLenum target, GLenum clamp);
+void gl4_2compat_glGetTransformFeedbackVarying(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLsizei* size, GLenum* gltype, GLchar* name);
+void gl4_2compat_glBindBufferBase(void *_glfuncs, GLenum target, GLuint index, GLuint buffer);
+void gl4_2compat_glBindBufferRange(void *_glfuncs, GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size);
+void gl4_2compat_glEndTransformFeedback(void *_glfuncs);
+void gl4_2compat_glBeginTransformFeedback(void *_glfuncs, GLenum primitiveMode);
+GLboolean gl4_2compat_glIsEnabledi(void *_glfuncs, GLenum target, GLuint index);
+void gl4_2compat_glDisablei(void *_glfuncs, GLenum target, GLuint index);
+void gl4_2compat_glEnablei(void *_glfuncs, GLenum target, GLuint index);
+void gl4_2compat_glGetIntegeri_v(void *_glfuncs, GLenum target, GLuint index, GLint* data);
+void gl4_2compat_glGetBooleani_v(void *_glfuncs, GLenum target, GLuint index, GLboolean* data);
+void gl4_2compat_glColorMaski(void *_glfuncs, GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a);
+void gl4_2compat_glCopyBufferSubData(void *_glfuncs, GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size);
+void gl4_2compat_glUniformBlockBinding(void *_glfuncs, GLuint program, GLuint v0, GLuint v1);
+void gl4_2compat_glGetActiveUniformBlockName(void *_glfuncs, GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei* length, GLchar* uniformBlockName);
+void gl4_2compat_glGetActiveUniformBlockiv(void *_glfuncs, GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint* params);
+GLuint gl4_2compat_glGetUniformBlockIndex(void *_glfuncs, GLuint program, const GLchar* uniformBlockName);
+void gl4_2compat_glGetActiveUniformName(void *_glfuncs, GLuint program, GLuint uniformIndex, GLsizei bufSize, GLsizei* length, GLchar* uniformName);
+void gl4_2compat_glGetActiveUniformsiv(void *_glfuncs, GLuint program, GLsizei uniformCount, const GLuint* uniformIndices, GLenum pname, GLint* params);
+void gl4_2compat_glPrimitiveRestartIndex(void *_glfuncs, GLuint index);
+void gl4_2compat_glTexBuffer(void *_glfuncs, GLenum target, GLenum internalFormat, GLuint buffer);
+void gl4_2compat_glDrawElementsInstanced(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount);
+void gl4_2compat_glDrawArraysInstanced(void *_glfuncs, GLenum mode, GLint first, GLsizei count, GLsizei instancecount);
+void gl4_2compat_glSampleMaski(void *_glfuncs, GLuint index, GLbitfield mask);
+void gl4_2compat_glGetMultisamplefv(void *_glfuncs, GLenum pname, GLuint index, GLfloat* val);
+void gl4_2compat_glTexImage3DMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations);
+void gl4_2compat_glTexImage2DMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLint internalFormat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations);
+void gl4_2compat_glGetSynciv(void *_glfuncs, GLsync sync, GLenum pname, GLsizei bufSize, GLsizei* length, GLint* values);
+void gl4_2compat_glGetInteger64v(void *_glfuncs, GLenum pname, GLint64* params);
+void gl4_2compat_glWaitSync(void *_glfuncs, GLsync sync, GLbitfield flags, GLuint64 timeout);
+GLenum gl4_2compat_glClientWaitSync(void *_glfuncs, GLsync sync, GLbitfield flags, GLuint64 timeout);
+void gl4_2compat_glDeleteSync(void *_glfuncs, GLsync sync);
+GLboolean gl4_2compat_glIsSync(void *_glfuncs, GLsync sync);
+GLsync gl4_2compat_glFenceSync(void *_glfuncs, GLenum condition, GLbitfield flags);
+void gl4_2compat_glProvokingVertex(void *_glfuncs, GLenum mode);
+void gl4_2compat_glDrawElementsInstancedBaseVertex(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount, GLint basevertex);
+void gl4_2compat_glDrawRangeElementsBaseVertex(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices, GLint basevertex);
+void gl4_2compat_glDrawElementsBaseVertex(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLint basevertex);
+void gl4_2compat_glFramebufferTexture(void *_glfuncs, GLenum target, GLenum attachment, GLuint texture, GLint level);
+void gl4_2compat_glGetBufferParameteri64v(void *_glfuncs, GLenum target, GLenum pname, GLint64* params);
+void gl4_2compat_glGetInteger64i_v(void *_glfuncs, GLenum target, GLuint index, GLint64* data);
+void gl4_2compat_glVertexAttribP4uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value);
+void gl4_2compat_glVertexAttribP4ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value);
+void gl4_2compat_glVertexAttribP3uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value);
+void gl4_2compat_glVertexAttribP3ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value);
+void gl4_2compat_glVertexAttribP2uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value);
+void gl4_2compat_glVertexAttribP2ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value);
+void gl4_2compat_glVertexAttribP1uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value);
+void gl4_2compat_glVertexAttribP1ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value);
+void gl4_2compat_glSecondaryColorP3uiv(void *_glfuncs, GLenum gltype, const GLuint* color);
+void gl4_2compat_glSecondaryColorP3ui(void *_glfuncs, GLenum gltype, GLuint color);
+void gl4_2compat_glColorP4uiv(void *_glfuncs, GLenum gltype, const GLuint* color);
+void gl4_2compat_glColorP4ui(void *_glfuncs, GLenum gltype, GLuint color);
+void gl4_2compat_glColorP3uiv(void *_glfuncs, GLenum gltype, const GLuint* color);
+void gl4_2compat_glColorP3ui(void *_glfuncs, GLenum gltype, GLuint color);
+void gl4_2compat_glNormalP3uiv(void *_glfuncs, GLenum gltype, const GLuint* coords);
+void gl4_2compat_glNormalP3ui(void *_glfuncs, GLenum gltype, GLuint coords);
+void gl4_2compat_glMultiTexCoordP4uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords);
+void gl4_2compat_glMultiTexCoordP4ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords);
+void gl4_2compat_glMultiTexCoordP3uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords);
+void gl4_2compat_glMultiTexCoordP3ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords);
+void gl4_2compat_glMultiTexCoordP2uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords);
+void gl4_2compat_glMultiTexCoordP2ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords);
+void gl4_2compat_glMultiTexCoordP1uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords);
+void gl4_2compat_glMultiTexCoordP1ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords);
+void gl4_2compat_glTexCoordP4uiv(void *_glfuncs, GLenum gltype, const GLuint* coords);
+void gl4_2compat_glTexCoordP4ui(void *_glfuncs, GLenum gltype, GLuint coords);
+void gl4_2compat_glTexCoordP3uiv(void *_glfuncs, GLenum gltype, const GLuint* coords);
+void gl4_2compat_glTexCoordP3ui(void *_glfuncs, GLenum gltype, GLuint coords);
+void gl4_2compat_glTexCoordP2uiv(void *_glfuncs, GLenum gltype, const GLuint* coords);
+void gl4_2compat_glTexCoordP2ui(void *_glfuncs, GLenum gltype, GLuint coords);
+void gl4_2compat_glTexCoordP1uiv(void *_glfuncs, GLenum gltype, const GLuint* coords);
+void gl4_2compat_glTexCoordP1ui(void *_glfuncs, GLenum gltype, GLuint coords);
+void gl4_2compat_glVertexP4uiv(void *_glfuncs, GLenum gltype, const GLuint* value);
+void gl4_2compat_glVertexP4ui(void *_glfuncs, GLenum gltype, GLuint value);
+void gl4_2compat_glVertexP3uiv(void *_glfuncs, GLenum gltype, const GLuint* value);
+void gl4_2compat_glVertexP3ui(void *_glfuncs, GLenum gltype, GLuint value);
+void gl4_2compat_glVertexP2uiv(void *_glfuncs, GLenum gltype, const GLuint* value);
+void gl4_2compat_glVertexP2ui(void *_glfuncs, GLenum gltype, GLuint value);
+void gl4_2compat_glGetQueryObjectui64v(void *_glfuncs, GLuint id, GLenum pname, GLuint64* params);
+void gl4_2compat_glGetQueryObjecti64v(void *_glfuncs, GLuint id, GLenum pname, GLint64* params);
+void gl4_2compat_glQueryCounter(void *_glfuncs, GLuint id, GLenum target);
+void gl4_2compat_glGetSamplerParameterIuiv(void *_glfuncs, GLuint sampler, GLenum pname, GLuint* params);
+void gl4_2compat_glGetSamplerParameterfv(void *_glfuncs, GLuint sampler, GLenum pname, GLfloat* params);
+void gl4_2compat_glGetSamplerParameterIiv(void *_glfuncs, GLuint sampler, GLenum pname, GLint* params);
+void gl4_2compat_glGetSamplerParameteriv(void *_glfuncs, GLuint sampler, GLenum pname, GLint* params);
+void gl4_2compat_glSamplerParameterIuiv(void *_glfuncs, GLuint sampler, GLenum pname, const GLuint* param);
+void gl4_2compat_glSamplerParameterIiv(void *_glfuncs, GLuint sampler, GLenum pname, const GLint* param);
+void gl4_2compat_glSamplerParameterfv(void *_glfuncs, GLuint sampler, GLenum pname, const GLfloat* param);
+void gl4_2compat_glSamplerParameterf(void *_glfuncs, GLuint sampler, GLenum pname, GLfloat param);
+void gl4_2compat_glSamplerParameteriv(void *_glfuncs, GLuint sampler, GLenum pname, const GLint* param);
+void gl4_2compat_glSamplerParameteri(void *_glfuncs, GLuint sampler, GLenum pname, GLint param);
+void gl4_2compat_glBindSampler(void *_glfuncs, GLuint unit, GLuint sampler);
+GLboolean gl4_2compat_glIsSampler(void *_glfuncs, GLuint sampler);
+void gl4_2compat_glDeleteSamplers(void *_glfuncs, GLsizei count, const GLuint* samplers);
+void gl4_2compat_glGenSamplers(void *_glfuncs, GLsizei count, GLuint* samplers);
+GLint gl4_2compat_glGetFragDataIndex(void *_glfuncs, GLuint program, const GLchar* name);
+void gl4_2compat_glBindFragDataLocationIndexed(void *_glfuncs, GLuint program, GLuint colorNumber, GLuint index, const GLchar* name);
+void gl4_2compat_glVertexAttribDivisor(void *_glfuncs, GLuint index, GLuint divisor);
+void gl4_2compat_glGetQueryIndexediv(void *_glfuncs, GLenum target, GLuint index, GLenum pname, GLint* params);
+void gl4_2compat_glEndQueryIndexed(void *_glfuncs, GLenum target, GLuint index);
+void gl4_2compat_glBeginQueryIndexed(void *_glfuncs, GLenum target, GLuint index, GLuint id);
+void gl4_2compat_glDrawTransformFeedbackStream(void *_glfuncs, GLenum mode, GLuint id, GLuint stream);
+void gl4_2compat_glDrawTransformFeedback(void *_glfuncs, GLenum mode, GLuint id);
+void gl4_2compat_glResumeTransformFeedback(void *_glfuncs);
+void gl4_2compat_glPauseTransformFeedback(void *_glfuncs);
+GLboolean gl4_2compat_glIsTransformFeedback(void *_glfuncs, GLuint id);
+void gl4_2compat_glGenTransformFeedbacks(void *_glfuncs, GLsizei n, GLuint* ids);
+void gl4_2compat_glDeleteTransformFeedbacks(void *_glfuncs, GLsizei n, const GLuint* ids);
+void gl4_2compat_glBindTransformFeedback(void *_glfuncs, GLenum target, GLuint id);
+void gl4_2compat_glPatchParameterfv(void *_glfuncs, GLenum pname, const GLfloat* values);
+void gl4_2compat_glPatchParameteri(void *_glfuncs, GLenum pname, GLint value);
+void gl4_2compat_glGetProgramStageiv(void *_glfuncs, GLuint program, GLenum shadertype, GLenum pname, GLint* values);
+void gl4_2compat_glGetUniformSubroutineuiv(void *_glfuncs, GLenum shadertype, GLint location, GLuint* params);
+void gl4_2compat_glUniformSubroutinesuiv(void *_glfuncs, GLenum shadertype, GLsizei count, const GLuint* value);
+void gl4_2compat_glGetActiveSubroutineName(void *_glfuncs, GLuint program, GLenum shadertype, GLuint index, GLsizei bufSize, GLsizei* length, GLchar* name);
+void gl4_2compat_glGetActiveSubroutineUniformName(void *_glfuncs, GLuint program, GLenum shadertype, GLuint index, GLsizei bufSize, GLsizei* length, GLchar* name);
+void gl4_2compat_glGetActiveSubroutineUniformiv(void *_glfuncs, GLuint program, GLenum shadertype, GLuint index, GLenum pname, GLint* values);
+GLuint gl4_2compat_glGetSubroutineIndex(void *_glfuncs, GLuint program, GLenum shadertype, const GLchar* name);
+GLint gl4_2compat_glGetSubroutineUniformLocation(void *_glfuncs, GLuint program, GLenum shadertype, const GLchar* name);
+void gl4_2compat_glGetUniformdv(void *_glfuncs, GLuint program, GLint location, GLdouble* params);
+void gl4_2compat_glUniformMatrix4x3dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_2compat_glUniformMatrix4x2dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_2compat_glUniformMatrix3x4dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_2compat_glUniformMatrix3x2dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_2compat_glUniformMatrix2x4dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_2compat_glUniformMatrix2x3dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_2compat_glUniformMatrix4dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_2compat_glUniformMatrix3dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_2compat_glUniformMatrix2dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_2compat_glUniform4dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value);
+void gl4_2compat_glUniform3dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value);
+void gl4_2compat_glUniform2dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value);
+void gl4_2compat_glUniform1dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value);
+void gl4_2compat_glUniform4d(void *_glfuncs, GLint location, GLdouble v0, GLdouble v1, GLdouble v2, GLdouble v3);
+void gl4_2compat_glUniform3d(void *_glfuncs, GLint location, GLdouble v0, GLdouble v1, GLdouble v2);
+void gl4_2compat_glUniform2d(void *_glfuncs, GLint location, GLdouble v0, GLdouble v1);
+void gl4_2compat_glUniform1d(void *_glfuncs, GLint location, GLdouble v0);
+void gl4_2compat_glDrawElementsIndirect(void *_glfuncs, GLenum mode, GLenum gltype, const GLvoid* indirect);
+void gl4_2compat_glDrawArraysIndirect(void *_glfuncs, GLenum mode, const GLvoid* indirect);
+void gl4_2compat_glBlendFuncSeparatei(void *_glfuncs, GLuint buf, GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha, GLenum dstAlpha);
+void gl4_2compat_glBlendFunci(void *_glfuncs, GLuint buf, GLenum src, GLenum dst);
+void gl4_2compat_glBlendEquationSeparatei(void *_glfuncs, GLuint buf, GLenum modeRGB, GLenum modeAlpha);
+void gl4_2compat_glBlendEquationi(void *_glfuncs, GLuint buf, GLenum mode);
+void gl4_2compat_glMinSampleShading(void *_glfuncs, GLfloat value);
+void gl4_2compat_glGetDoublei_v(void *_glfuncs, GLenum target, GLuint index, GLdouble* data);
+void gl4_2compat_glGetFloati_v(void *_glfuncs, GLenum target, GLuint index, GLfloat* data);
+void gl4_2compat_glDepthRangeIndexed(void *_glfuncs, GLuint index, GLdouble n, GLdouble f);
+void gl4_2compat_glDepthRangeArrayv(void *_glfuncs, GLuint first, GLsizei count, const GLdouble* v);
+void gl4_2compat_glScissorIndexedv(void *_glfuncs, GLuint index, const GLint* v);
+void gl4_2compat_glScissorIndexed(void *_glfuncs, GLuint index, GLint left, GLint bottom, GLsizei width, GLsizei height);
+void gl4_2compat_glScissorArrayv(void *_glfuncs, GLuint first, GLsizei count, const GLint* v);
+void gl4_2compat_glViewportIndexedfv(void *_glfuncs, GLuint index, const GLfloat* v);
+void gl4_2compat_glViewportIndexedf(void *_glfuncs, GLuint index, GLfloat x, GLfloat y, GLfloat w, GLfloat h);
+void gl4_2compat_glViewportArrayv(void *_glfuncs, GLuint first, GLsizei count, const GLfloat* v);
+void gl4_2compat_glGetVertexAttribLdv(void *_glfuncs, GLuint index, GLenum pname, GLdouble* params);
+void gl4_2compat_glVertexAttribLPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl4_2compat_glVertexAttribL4dv(void *_glfuncs, GLuint index, const GLdouble* v);
+void gl4_2compat_glVertexAttribL3dv(void *_glfuncs, GLuint index, const GLdouble* v);
+void gl4_2compat_glVertexAttribL2dv(void *_glfuncs, GLuint index, const GLdouble* v);
+void gl4_2compat_glVertexAttribL1dv(void *_glfuncs, GLuint index, const GLdouble* v);
+void gl4_2compat_glVertexAttribL4d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+void gl4_2compat_glVertexAttribL3d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y, GLdouble z);
+void gl4_2compat_glVertexAttribL2d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y);
+void gl4_2compat_glVertexAttribL1d(void *_glfuncs, GLuint index, GLdouble x);
+void gl4_2compat_glGetProgramPipelineInfoLog(void *_glfuncs, GLuint pipeline, GLsizei bufSize, GLsizei* length, GLchar* infoLog);
+void gl4_2compat_glValidateProgramPipeline(void *_glfuncs, GLuint pipeline);
+void gl4_2compat_glProgramUniformMatrix4x3dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_2compat_glProgramUniformMatrix3x4dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_2compat_glProgramUniformMatrix4x2dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_2compat_glProgramUniformMatrix2x4dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_2compat_glProgramUniformMatrix3x2dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_2compat_glProgramUniformMatrix2x3dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_2compat_glProgramUniformMatrix4x3fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_2compat_glProgramUniformMatrix3x4fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_2compat_glProgramUniformMatrix4x2fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_2compat_glProgramUniformMatrix2x4fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_2compat_glProgramUniformMatrix3x2fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_2compat_glProgramUniformMatrix2x3fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_2compat_glProgramUniformMatrix4dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_2compat_glProgramUniformMatrix3dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_2compat_glProgramUniformMatrix2dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_2compat_glProgramUniformMatrix4fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_2compat_glProgramUniformMatrix3fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_2compat_glProgramUniformMatrix2fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_2compat_glProgramUniform4uiv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLuint* value);
+void gl4_2compat_glProgramUniform4ui(void *_glfuncs, GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3);
+void gl4_2compat_glProgramUniform4dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLdouble* value);
+void gl4_2compat_glProgramUniform4d(void *_glfuncs, GLuint program, GLint location, GLdouble v0, GLdouble v1, GLdouble v2, GLdouble v3);
+void gl4_2compat_glProgramUniform4fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLfloat* value);
+void gl4_2compat_glProgramUniform4f(void *_glfuncs, GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3);
+void gl4_2compat_glProgramUniform4iv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLint* value);
+void gl4_2compat_glProgramUniform4i(void *_glfuncs, GLuint program, GLint location, GLint v0, GLint v1, GLint v2, GLint v3);
+void gl4_2compat_glProgramUniform3uiv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLuint* value);
+void gl4_2compat_glProgramUniform3ui(void *_glfuncs, GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2);
+void gl4_2compat_glProgramUniform3dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLdouble* value);
+void gl4_2compat_glProgramUniform3d(void *_glfuncs, GLuint program, GLint location, GLdouble v0, GLdouble v1, GLdouble v2);
+void gl4_2compat_glProgramUniform3fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLfloat* value);
+void gl4_2compat_glProgramUniform3f(void *_glfuncs, GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2);
+void gl4_2compat_glProgramUniform3iv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLint* value);
+void gl4_2compat_glProgramUniform3i(void *_glfuncs, GLuint program, GLint location, GLint v0, GLint v1, GLint v2);
+void gl4_2compat_glProgramUniform2uiv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLuint* value);
+void gl4_2compat_glProgramUniform2ui(void *_glfuncs, GLuint program, GLint location, GLuint v0, GLuint v1);
+void gl4_2compat_glProgramUniform2dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLdouble* value);
+void gl4_2compat_glProgramUniform2d(void *_glfuncs, GLuint program, GLint location, GLdouble v0, GLdouble v1);
+void gl4_2compat_glProgramUniform2fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLfloat* value);
+void gl4_2compat_glProgramUniform2f(void *_glfuncs, GLuint program, GLint location, GLfloat v0, GLfloat v1);
+void gl4_2compat_glProgramUniform2iv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLint* value);
+void gl4_2compat_glProgramUniform2i(void *_glfuncs, GLuint program, GLint location, GLint v0, GLint v1);
+void gl4_2compat_glProgramUniform1uiv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLuint* value);
+void gl4_2compat_glProgramUniform1ui(void *_glfuncs, GLuint program, GLint location, GLuint v0);
+void gl4_2compat_glProgramUniform1dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLdouble* value);
+void gl4_2compat_glProgramUniform1d(void *_glfuncs, GLuint program, GLint location, GLdouble v0);
+void gl4_2compat_glProgramUniform1fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLfloat* value);
+void gl4_2compat_glProgramUniform1f(void *_glfuncs, GLuint program, GLint location, GLfloat v0);
+void gl4_2compat_glProgramUniform1iv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLint* value);
+void gl4_2compat_glProgramUniform1i(void *_glfuncs, GLuint program, GLint location, GLint v0);
+void gl4_2compat_glGetProgramPipelineiv(void *_glfuncs, GLuint pipeline, GLenum pname, GLint* params);
+GLboolean gl4_2compat_glIsProgramPipeline(void *_glfuncs, GLuint pipeline);
+void gl4_2compat_glGenProgramPipelines(void *_glfuncs, GLsizei n, GLuint* pipelines);
+void gl4_2compat_glDeleteProgramPipelines(void *_glfuncs, GLsizei n, const GLuint* pipelines);
+void gl4_2compat_glBindProgramPipeline(void *_glfuncs, GLuint pipeline);
+void gl4_2compat_glActiveShaderProgram(void *_glfuncs, GLuint pipeline, GLuint program);
+void gl4_2compat_glUseProgramStages(void *_glfuncs, GLuint pipeline, GLbitfield stages, GLuint program);
+void gl4_2compat_glProgramParameteri(void *_glfuncs, GLuint program, GLenum pname, GLint value);
+void gl4_2compat_glProgramBinary(void *_glfuncs, GLuint program, GLenum binaryFormat, const GLvoid* binary, GLsizei length);
+void gl4_2compat_glGetProgramBinary(void *_glfuncs, GLuint program, GLsizei bufSize, GLsizei* length, GLenum* binaryFormat, GLvoid* binary);
+void gl4_2compat_glClearDepthf(void *_glfuncs, GLfloat dd);
+void gl4_2compat_glDepthRangef(void *_glfuncs, GLfloat n, GLfloat f);
+void gl4_2compat_glGetShaderPrecisionFormat(void *_glfuncs, GLenum shadertype, GLenum precisionType, GLint* range_, GLint* precision);
+void gl4_2compat_glShaderBinary(void *_glfuncs, GLsizei count, const GLuint* shaders, GLenum binaryFormat, const GLvoid* binary, GLsizei length);
+void gl4_2compat_glReleaseShaderCompiler(void *_glfuncs);
+void gl4_2compat_glTexStorage3D(void *_glfuncs, GLenum target, GLsizei levels, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth);
+void gl4_2compat_glTexStorage2D(void *_glfuncs, GLenum target, GLsizei levels, GLenum internalFormat, GLsizei width, GLsizei height);
+void gl4_2compat_glTexStorage1D(void *_glfuncs, GLenum target, GLsizei levels, GLenum internalFormat, GLsizei width);
+void gl4_2compat_glMemoryBarrier(void *_glfuncs, GLbitfield barriers);
+void gl4_2compat_glBindImageTexture(void *_glfuncs, GLuint unit, GLuint texture, GLint level, GLboolean layered, GLint layer, GLenum access, GLenum format);
+void gl4_2compat_glGetActiveAtomicCounterBufferiv(void *_glfuncs, GLuint program, GLuint bufferIndex, GLenum pname, GLint* params);
+void gl4_2compat_glGetInternalformativ(void *_glfuncs, GLenum target, GLenum internalFormat, GLenum pname, GLsizei bufSize, GLint* params);
+void gl4_2compat_glDrawTransformFeedbackStreamInstanced(void *_glfuncs, GLenum mode, GLuint id, GLuint stream, GLsizei instancecount);
+void gl4_2compat_glDrawTransformFeedbackInstanced(void *_glfuncs, GLenum mode, GLuint id, GLsizei instancecount);
+void gl4_2compat_glDrawElementsInstancedBaseVertexBaseInstance(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount, GLint basevertex, GLuint baseinstance);
+void gl4_2compat_glDrawElementsInstancedBaseInstance(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount, GLuint baseinstance);
+void gl4_2compat_glDrawArraysInstancedBaseInstance(void *_glfuncs, GLenum mode, GLint first, GLsizei count, GLsizei instancecount, GLuint baseinstance);
+void gl4_2compat_glTranslatef(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl4_2compat_glTranslated(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl4_2compat_glScalef(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl4_2compat_glScaled(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl4_2compat_glRotatef(void *_glfuncs, GLfloat angle, GLfloat x, GLfloat y, GLfloat z);
+void gl4_2compat_glRotated(void *_glfuncs, GLdouble angle, GLdouble x, GLdouble y, GLdouble z);
+void gl4_2compat_glPushMatrix(void *_glfuncs);
+void gl4_2compat_glPopMatrix(void *_glfuncs);
+void gl4_2compat_glOrtho(void *_glfuncs, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+void gl4_2compat_glMultMatrixd(void *_glfuncs, const GLdouble* m);
+void gl4_2compat_glMultMatrixf(void *_glfuncs, const GLfloat* m);
+void gl4_2compat_glMatrixMode(void *_glfuncs, GLenum mode);
+void gl4_2compat_glLoadMatrixd(void *_glfuncs, const GLdouble* m);
+void gl4_2compat_glLoadMatrixf(void *_glfuncs, const GLfloat* m);
+void gl4_2compat_glLoadIdentity(void *_glfuncs);
+void gl4_2compat_glFrustum(void *_glfuncs, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+GLboolean gl4_2compat_glIsList(void *_glfuncs, GLuint list);
+void gl4_2compat_glGetTexGeniv(void *_glfuncs, GLenum coord, GLenum pname, GLint* params);
+void gl4_2compat_glGetTexGenfv(void *_glfuncs, GLenum coord, GLenum pname, GLfloat* params);
+void gl4_2compat_glGetTexGendv(void *_glfuncs, GLenum coord, GLenum pname, GLdouble* params);
+void gl4_2compat_glGetTexEnviv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl4_2compat_glGetTexEnvfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl4_2compat_glGetPolygonStipple(void *_glfuncs, GLubyte* mask);
+void gl4_2compat_glGetPixelMapusv(void *_glfuncs, GLenum glmap, GLushort* values);
+void gl4_2compat_glGetPixelMapuiv(void *_glfuncs, GLenum glmap, GLuint* values);
+void gl4_2compat_glGetPixelMapfv(void *_glfuncs, GLenum glmap, GLfloat* values);
+void gl4_2compat_glGetMaterialiv(void *_glfuncs, GLenum face, GLenum pname, GLint* params);
+void gl4_2compat_glGetMaterialfv(void *_glfuncs, GLenum face, GLenum pname, GLfloat* params);
+void gl4_2compat_glGetMapiv(void *_glfuncs, GLenum target, GLenum query, GLint* v);
+void gl4_2compat_glGetMapfv(void *_glfuncs, GLenum target, GLenum query, GLfloat* v);
+void gl4_2compat_glGetMapdv(void *_glfuncs, GLenum target, GLenum query, GLdouble* v);
+void gl4_2compat_glGetLightiv(void *_glfuncs, GLenum light, GLenum pname, GLint* params);
+void gl4_2compat_glGetLightfv(void *_glfuncs, GLenum light, GLenum pname, GLfloat* params);
+void gl4_2compat_glGetClipPlane(void *_glfuncs, GLenum plane, GLdouble* equation);
+void gl4_2compat_glDrawPixels(void *_glfuncs, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl4_2compat_glCopyPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum gltype);
+void gl4_2compat_glPixelMapusv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLushort* values);
+void gl4_2compat_glPixelMapuiv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLuint* values);
+void gl4_2compat_glPixelMapfv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLfloat* values);
+void gl4_2compat_glPixelTransferi(void *_glfuncs, GLenum pname, GLint param);
+void gl4_2compat_glPixelTransferf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl4_2compat_glPixelZoom(void *_glfuncs, GLfloat xfactor, GLfloat yfactor);
+void gl4_2compat_glAlphaFunc(void *_glfuncs, GLenum glfunc, GLfloat ref);
+void gl4_2compat_glEvalPoint2(void *_glfuncs, GLint i, GLint j);
+void gl4_2compat_glEvalMesh2(void *_glfuncs, GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2);
+void gl4_2compat_glEvalPoint1(void *_glfuncs, GLint i);
+void gl4_2compat_glEvalMesh1(void *_glfuncs, GLenum mode, GLint i1, GLint i2);
+void gl4_2compat_glEvalCoord2fv(void *_glfuncs, const GLfloat* u);
+void gl4_2compat_glEvalCoord2f(void *_glfuncs, GLfloat u, GLfloat v);
+void gl4_2compat_glEvalCoord2dv(void *_glfuncs, const GLdouble* u);
+void gl4_2compat_glEvalCoord2d(void *_glfuncs, GLdouble u, GLdouble v);
+void gl4_2compat_glEvalCoord1fv(void *_glfuncs, const GLfloat* u);
+void gl4_2compat_glEvalCoord1f(void *_glfuncs, GLfloat u);
+void gl4_2compat_glEvalCoord1dv(void *_glfuncs, const GLdouble* u);
+void gl4_2compat_glEvalCoord1d(void *_glfuncs, GLdouble u);
+void gl4_2compat_glMapGrid2f(void *_glfuncs, GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2);
+void gl4_2compat_glMapGrid2d(void *_glfuncs, GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2);
+void gl4_2compat_glMapGrid1f(void *_glfuncs, GLint un, GLfloat u1, GLfloat u2);
+void gl4_2compat_glMapGrid1d(void *_glfuncs, GLint un, GLdouble u1, GLdouble u2);
+void gl4_2compat_glMap2f(void *_glfuncs, GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat* points);
+void gl4_2compat_glMap2d(void *_glfuncs, GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble* points);
+void gl4_2compat_glMap1f(void *_glfuncs, GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat* points);
+void gl4_2compat_glMap1d(void *_glfuncs, GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble* points);
+void gl4_2compat_glPushAttrib(void *_glfuncs, GLbitfield mask);
+void gl4_2compat_glPopAttrib(void *_glfuncs);
+void gl4_2compat_glAccum(void *_glfuncs, GLenum op, GLfloat value);
+void gl4_2compat_glIndexMask(void *_glfuncs, GLuint mask);
+void gl4_2compat_glClearIndex(void *_glfuncs, GLfloat c);
+void gl4_2compat_glClearAccum(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl4_2compat_glPushName(void *_glfuncs, GLuint name);
+void gl4_2compat_glPopName(void *_glfuncs);
+void gl4_2compat_glPassThrough(void *_glfuncs, GLfloat token);
+void gl4_2compat_glLoadName(void *_glfuncs, GLuint name);
+void gl4_2compat_glInitNames(void *_glfuncs);
+GLint gl4_2compat_glRenderMode(void *_glfuncs, GLenum mode);
+void gl4_2compat_glSelectBuffer(void *_glfuncs, GLsizei size, GLuint* buffer);
+void gl4_2compat_glFeedbackBuffer(void *_glfuncs, GLsizei size, GLenum gltype, GLfloat* buffer);
+void gl4_2compat_glTexGeniv(void *_glfuncs, GLenum coord, GLenum pname, const GLint* params);
+void gl4_2compat_glTexGeni(void *_glfuncs, GLenum coord, GLenum pname, GLint param);
+void gl4_2compat_glTexGenfv(void *_glfuncs, GLenum coord, GLenum pname, const GLfloat* params);
+void gl4_2compat_glTexGenf(void *_glfuncs, GLenum coord, GLenum pname, GLfloat param);
+void gl4_2compat_glTexGendv(void *_glfuncs, GLenum coord, GLenum pname, const GLdouble* params);
+void gl4_2compat_glTexGend(void *_glfuncs, GLenum coord, GLenum pname, GLdouble param);
+void gl4_2compat_glTexEnviv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl4_2compat_glTexEnvi(void *_glfuncs, GLenum target, GLenum pname, GLint param);
+void gl4_2compat_glTexEnvfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl4_2compat_glTexEnvf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param);
+void gl4_2compat_glShadeModel(void *_glfuncs, GLenum mode);
+void gl4_2compat_glPolygonStipple(void *_glfuncs, const GLubyte* mask);
+void gl4_2compat_glMaterialiv(void *_glfuncs, GLenum face, GLenum pname, const GLint* params);
+void gl4_2compat_glMateriali(void *_glfuncs, GLenum face, GLenum pname, GLint param);
+void gl4_2compat_glMaterialfv(void *_glfuncs, GLenum face, GLenum pname, const GLfloat* params);
+void gl4_2compat_glMaterialf(void *_glfuncs, GLenum face, GLenum pname, GLfloat param);
+void gl4_2compat_glLineStipple(void *_glfuncs, GLint factor, GLushort pattern);
+void gl4_2compat_glLightModeliv(void *_glfuncs, GLenum pname, const GLint* params);
+void gl4_2compat_glLightModeli(void *_glfuncs, GLenum pname, GLint param);
+void gl4_2compat_glLightModelfv(void *_glfuncs, GLenum pname, const GLfloat* params);
+void gl4_2compat_glLightModelf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl4_2compat_glLightiv(void *_glfuncs, GLenum light, GLenum pname, const GLint* params);
+void gl4_2compat_glLighti(void *_glfuncs, GLenum light, GLenum pname, GLint param);
+void gl4_2compat_glLightfv(void *_glfuncs, GLenum light, GLenum pname, const GLfloat* params);
+void gl4_2compat_glLightf(void *_glfuncs, GLenum light, GLenum pname, GLfloat param);
+void gl4_2compat_glFogiv(void *_glfuncs, GLenum pname, const GLint* params);
+void gl4_2compat_glFogi(void *_glfuncs, GLenum pname, GLint param);
+void gl4_2compat_glFogfv(void *_glfuncs, GLenum pname, const GLfloat* params);
+void gl4_2compat_glFogf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl4_2compat_glColorMaterial(void *_glfuncs, GLenum face, GLenum mode);
+void gl4_2compat_glClipPlane(void *_glfuncs, GLenum plane, const GLdouble* equation);
+void gl4_2compat_glVertex4sv(void *_glfuncs, const GLshort* v);
+void gl4_2compat_glVertex4s(void *_glfuncs, GLshort x, GLshort y, GLshort z, GLshort w);
+void gl4_2compat_glVertex4iv(void *_glfuncs, const GLint* v);
+void gl4_2compat_glVertex4i(void *_glfuncs, GLint x, GLint y, GLint z, GLint w);
+void gl4_2compat_glVertex4fv(void *_glfuncs, const GLfloat* v);
+void gl4_2compat_glVertex4f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+void gl4_2compat_glVertex4dv(void *_glfuncs, const GLdouble* v);
+void gl4_2compat_glVertex4d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+void gl4_2compat_glVertex3sv(void *_glfuncs, const GLshort* v);
+void gl4_2compat_glVertex3s(void *_glfuncs, GLshort x, GLshort y, GLshort z);
+void gl4_2compat_glVertex3iv(void *_glfuncs, const GLint* v);
+void gl4_2compat_glVertex3i(void *_glfuncs, GLint x, GLint y, GLint z);
+void gl4_2compat_glVertex3fv(void *_glfuncs, const GLfloat* v);
+void gl4_2compat_glVertex3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl4_2compat_glVertex3dv(void *_glfuncs, const GLdouble* v);
+void gl4_2compat_glVertex3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl4_2compat_glVertex2sv(void *_glfuncs, const GLshort* v);
+void gl4_2compat_glVertex2s(void *_glfuncs, GLshort x, GLshort y);
+void gl4_2compat_glVertex2iv(void *_glfuncs, const GLint* v);
+void gl4_2compat_glVertex2i(void *_glfuncs, GLint x, GLint y);
+void gl4_2compat_glVertex2fv(void *_glfuncs, const GLfloat* v);
+void gl4_2compat_glVertex2f(void *_glfuncs, GLfloat x, GLfloat y);
+void gl4_2compat_glVertex2dv(void *_glfuncs, const GLdouble* v);
+void gl4_2compat_glVertex2d(void *_glfuncs, GLdouble x, GLdouble y);
+void gl4_2compat_glTexCoord4sv(void *_glfuncs, const GLshort* v);
+void gl4_2compat_glTexCoord4s(void *_glfuncs, GLshort s, GLshort t, GLshort r, GLshort q);
+void gl4_2compat_glTexCoord4iv(void *_glfuncs, const GLint* v);
+void gl4_2compat_glTexCoord4i(void *_glfuncs, GLint s, GLint t, GLint r, GLint q);
+void gl4_2compat_glTexCoord4fv(void *_glfuncs, const GLfloat* v);
+void gl4_2compat_glTexCoord4f(void *_glfuncs, GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+void gl4_2compat_glTexCoord4dv(void *_glfuncs, const GLdouble* v);
+void gl4_2compat_glTexCoord4d(void *_glfuncs, GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+void gl4_2compat_glTexCoord3sv(void *_glfuncs, const GLshort* v);
+void gl4_2compat_glTexCoord3s(void *_glfuncs, GLshort s, GLshort t, GLshort r);
+void gl4_2compat_glTexCoord3iv(void *_glfuncs, const GLint* v);
+void gl4_2compat_glTexCoord3i(void *_glfuncs, GLint s, GLint t, GLint r);
+void gl4_2compat_glTexCoord3fv(void *_glfuncs, const GLfloat* v);
+void gl4_2compat_glTexCoord3f(void *_glfuncs, GLfloat s, GLfloat t, GLfloat r);
+void gl4_2compat_glTexCoord3dv(void *_glfuncs, const GLdouble* v);
+void gl4_2compat_glTexCoord3d(void *_glfuncs, GLdouble s, GLdouble t, GLdouble r);
+void gl4_2compat_glTexCoord2sv(void *_glfuncs, const GLshort* v);
+void gl4_2compat_glTexCoord2s(void *_glfuncs, GLshort s, GLshort t);
+void gl4_2compat_glTexCoord2iv(void *_glfuncs, const GLint* v);
+void gl4_2compat_glTexCoord2i(void *_glfuncs, GLint s, GLint t);
+void gl4_2compat_glTexCoord2fv(void *_glfuncs, const GLfloat* v);
+void gl4_2compat_glTexCoord2f(void *_glfuncs, GLfloat s, GLfloat t);
+void gl4_2compat_glTexCoord2dv(void *_glfuncs, const GLdouble* v);
+void gl4_2compat_glTexCoord2d(void *_glfuncs, GLdouble s, GLdouble t);
+void gl4_2compat_glTexCoord1sv(void *_glfuncs, const GLshort* v);
+void gl4_2compat_glTexCoord1s(void *_glfuncs, GLshort s);
+void gl4_2compat_glTexCoord1iv(void *_glfuncs, const GLint* v);
+void gl4_2compat_glTexCoord1i(void *_glfuncs, GLint s);
+void gl4_2compat_glTexCoord1fv(void *_glfuncs, const GLfloat* v);
+void gl4_2compat_glTexCoord1f(void *_glfuncs, GLfloat s);
+void gl4_2compat_glTexCoord1dv(void *_glfuncs, const GLdouble* v);
+void gl4_2compat_glTexCoord1d(void *_glfuncs, GLdouble s);
+void gl4_2compat_glRectsv(void *_glfuncs, const GLshort* v1, const GLshort* v2);
+void gl4_2compat_glRects(void *_glfuncs, GLshort x1, GLshort y1, GLshort x2, GLshort y2);
+void gl4_2compat_glRectiv(void *_glfuncs, const GLint* v1, const GLint* v2);
+void gl4_2compat_glRecti(void *_glfuncs, GLint x1, GLint y1, GLint x2, GLint y2);
+void gl4_2compat_glRectfv(void *_glfuncs, const GLfloat* v1, const GLfloat* v2);
+void gl4_2compat_glRectf(void *_glfuncs, GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2);
+void gl4_2compat_glRectdv(void *_glfuncs, const GLdouble* v1, const GLdouble* v2);
+void gl4_2compat_glRectd(void *_glfuncs, GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2);
+void gl4_2compat_glRasterPos4sv(void *_glfuncs, const GLshort* v);
+void gl4_2compat_glRasterPos4s(void *_glfuncs, GLshort x, GLshort y, GLshort z, GLshort w);
+void gl4_2compat_glRasterPos4iv(void *_glfuncs, const GLint* v);
+void gl4_2compat_glRasterPos4i(void *_glfuncs, GLint x, GLint y, GLint z, GLint w);
+void gl4_2compat_glRasterPos4fv(void *_glfuncs, const GLfloat* v);
+void gl4_2compat_glRasterPos4f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+void gl4_2compat_glRasterPos4dv(void *_glfuncs, const GLdouble* v);
+void gl4_2compat_glRasterPos4d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+void gl4_2compat_glRasterPos3sv(void *_glfuncs, const GLshort* v);
+void gl4_2compat_glRasterPos3s(void *_glfuncs, GLshort x, GLshort y, GLshort z);
+void gl4_2compat_glRasterPos3iv(void *_glfuncs, const GLint* v);
+void gl4_2compat_glRasterPos3i(void *_glfuncs, GLint x, GLint y, GLint z);
+void gl4_2compat_glRasterPos3fv(void *_glfuncs, const GLfloat* v);
+void gl4_2compat_glRasterPos3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl4_2compat_glRasterPos3dv(void *_glfuncs, const GLdouble* v);
+void gl4_2compat_glRasterPos3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl4_2compat_glRasterPos2sv(void *_glfuncs, const GLshort* v);
+void gl4_2compat_glRasterPos2s(void *_glfuncs, GLshort x, GLshort y);
+void gl4_2compat_glRasterPos2iv(void *_glfuncs, const GLint* v);
+void gl4_2compat_glRasterPos2i(void *_glfuncs, GLint x, GLint y);
+void gl4_2compat_glRasterPos2fv(void *_glfuncs, const GLfloat* v);
+void gl4_2compat_glRasterPos2f(void *_glfuncs, GLfloat x, GLfloat y);
+void gl4_2compat_glRasterPos2dv(void *_glfuncs, const GLdouble* v);
+void gl4_2compat_glRasterPos2d(void *_glfuncs, GLdouble x, GLdouble y);
+void gl4_2compat_glNormal3sv(void *_glfuncs, const GLshort* v);
+void gl4_2compat_glNormal3s(void *_glfuncs, GLshort nx, GLshort ny, GLshort nz);
+void gl4_2compat_glNormal3iv(void *_glfuncs, const GLint* v);
+void gl4_2compat_glNormal3i(void *_glfuncs, GLint nx, GLint ny, GLint nz);
+void gl4_2compat_glNormal3fv(void *_glfuncs, const GLfloat* v);
+void gl4_2compat_glNormal3f(void *_glfuncs, GLfloat nx, GLfloat ny, GLfloat nz);
+void gl4_2compat_glNormal3dv(void *_glfuncs, const GLdouble* v);
+void gl4_2compat_glNormal3d(void *_glfuncs, GLdouble nx, GLdouble ny, GLdouble nz);
+void gl4_2compat_glNormal3bv(void *_glfuncs, const GLbyte* v);
+void gl4_2compat_glNormal3b(void *_glfuncs, GLbyte nx, GLbyte ny, GLbyte nz);
+void gl4_2compat_glIndexsv(void *_glfuncs, const GLshort* c);
+void gl4_2compat_glIndexs(void *_glfuncs, GLshort c);
+void gl4_2compat_glIndexiv(void *_glfuncs, const GLint* c);
+void gl4_2compat_glIndexi(void *_glfuncs, GLint c);
+void gl4_2compat_glIndexfv(void *_glfuncs, const GLfloat* c);
+void gl4_2compat_glIndexf(void *_glfuncs, GLfloat c);
+void gl4_2compat_glIndexdv(void *_glfuncs, const GLdouble* c);
+void gl4_2compat_glIndexd(void *_glfuncs, GLdouble c);
+void gl4_2compat_glEnd(void *_glfuncs);
+void gl4_2compat_glEdgeFlagv(void *_glfuncs, const GLboolean* flag);
+void gl4_2compat_glEdgeFlag(void *_glfuncs, GLboolean flag);
+void gl4_2compat_glColor4usv(void *_glfuncs, const GLushort* v);
+void gl4_2compat_glColor4us(void *_glfuncs, GLushort red, GLushort green, GLushort blue, GLushort alpha);
+void gl4_2compat_glColor4uiv(void *_glfuncs, const GLuint* v);
+void gl4_2compat_glColor4ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue, GLuint alpha);
+void gl4_2compat_glColor4ubv(void *_glfuncs, const GLubyte* v);
+void gl4_2compat_glColor4ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha);
+void gl4_2compat_glColor4sv(void *_glfuncs, const GLshort* v);
+void gl4_2compat_glColor4s(void *_glfuncs, GLshort red, GLshort green, GLshort blue, GLshort alpha);
+void gl4_2compat_glColor4iv(void *_glfuncs, const GLint* v);
+void gl4_2compat_glColor4i(void *_glfuncs, GLint red, GLint green, GLint blue, GLint alpha);
+void gl4_2compat_glColor4fv(void *_glfuncs, const GLfloat* v);
+void gl4_2compat_glColor4f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl4_2compat_glColor4dv(void *_glfuncs, const GLdouble* v);
+void gl4_2compat_glColor4d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha);
+void gl4_2compat_glColor4bv(void *_glfuncs, const GLbyte* v);
+void gl4_2compat_glColor4b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha);
+void gl4_2compat_glColor3usv(void *_glfuncs, const GLushort* v);
+void gl4_2compat_glColor3us(void *_glfuncs, GLushort red, GLushort green, GLushort blue);
+void gl4_2compat_glColor3uiv(void *_glfuncs, const GLuint* v);
+void gl4_2compat_glColor3ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue);
+void gl4_2compat_glColor3ubv(void *_glfuncs, const GLubyte* v);
+void gl4_2compat_glColor3ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue);
+void gl4_2compat_glColor3sv(void *_glfuncs, const GLshort* v);
+void gl4_2compat_glColor3s(void *_glfuncs, GLshort red, GLshort green, GLshort blue);
+void gl4_2compat_glColor3iv(void *_glfuncs, const GLint* v);
+void gl4_2compat_glColor3i(void *_glfuncs, GLint red, GLint green, GLint blue);
+void gl4_2compat_glColor3fv(void *_glfuncs, const GLfloat* v);
+void gl4_2compat_glColor3f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue);
+void gl4_2compat_glColor3dv(void *_glfuncs, const GLdouble* v);
+void gl4_2compat_glColor3d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue);
+void gl4_2compat_glColor3bv(void *_glfuncs, const GLbyte* v);
+void gl4_2compat_glColor3b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue);
+void gl4_2compat_glBitmap(void *_glfuncs, GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte* bitmap);
+void gl4_2compat_glBegin(void *_glfuncs, GLenum mode);
+void gl4_2compat_glListBase(void *_glfuncs, GLuint base);
+GLuint gl4_2compat_glGenLists(void *_glfuncs, GLsizei range_);
+void gl4_2compat_glDeleteLists(void *_glfuncs, GLuint list, GLsizei range_);
+void gl4_2compat_glCallLists(void *_glfuncs, GLsizei n, GLenum gltype, const GLvoid* lists);
+void gl4_2compat_glCallList(void *_glfuncs, GLuint list);
+void gl4_2compat_glEndList(void *_glfuncs);
+void gl4_2compat_glNewList(void *_glfuncs, GLuint list, GLenum mode);
+void gl4_2compat_glPushClientAttrib(void *_glfuncs, GLbitfield mask);
+void gl4_2compat_glPopClientAttrib(void *_glfuncs);
+void gl4_2compat_glPrioritizeTextures(void *_glfuncs, GLsizei n, const GLuint* textures, const GLfloat* priorities);
+GLboolean gl4_2compat_glAreTexturesResident(void *_glfuncs, GLsizei n, const GLuint* textures, GLboolean* residences);
+void gl4_2compat_glVertexPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl4_2compat_glTexCoordPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl4_2compat_glNormalPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl4_2compat_glInterleavedArrays(void *_glfuncs, GLenum format, GLsizei stride, const GLvoid* pointer);
+void gl4_2compat_glIndexPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl4_2compat_glEnableClientState(void *_glfuncs, GLenum array);
+void gl4_2compat_glEdgeFlagPointer(void *_glfuncs, GLsizei stride, const GLvoid* pointer);
+void gl4_2compat_glDisableClientState(void *_glfuncs, GLenum array);
+void gl4_2compat_glColorPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl4_2compat_glArrayElement(void *_glfuncs, GLint i);
+void gl4_2compat_glResetMinmax(void *_glfuncs, GLenum target);
+void gl4_2compat_glResetHistogram(void *_glfuncs, GLenum target);
+void gl4_2compat_glMinmax(void *_glfuncs, GLenum target, GLenum internalFormat, GLboolean sink);
+void gl4_2compat_glHistogram(void *_glfuncs, GLenum target, GLsizei width, GLenum internalFormat, GLboolean sink);
+void gl4_2compat_glGetMinmaxParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl4_2compat_glGetMinmaxParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl4_2compat_glGetMinmax(void *_glfuncs, GLenum target, GLboolean reset, GLenum format, GLenum gltype, GLvoid* values);
+void gl4_2compat_glGetHistogramParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl4_2compat_glGetHistogramParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl4_2compat_glGetHistogram(void *_glfuncs, GLenum target, GLboolean reset, GLenum format, GLenum gltype, GLvoid* values);
+void gl4_2compat_glSeparableFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* row, const GLvoid* column);
+void gl4_2compat_glGetSeparableFilter(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* row, GLvoid* column, GLvoid* span);
+void gl4_2compat_glGetConvolutionParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl4_2compat_glGetConvolutionParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl4_2compat_glGetConvolutionFilter(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* image);
+void gl4_2compat_glCopyConvolutionFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl4_2compat_glCopyConvolutionFilter1D(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width);
+void gl4_2compat_glConvolutionParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl4_2compat_glConvolutionParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint params);
+void gl4_2compat_glConvolutionParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl4_2compat_glConvolutionParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat params);
+void gl4_2compat_glConvolutionFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* image);
+void gl4_2compat_glConvolutionFilter1D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLenum format, GLenum gltype, const GLvoid* image);
+void gl4_2compat_glCopyColorSubTable(void *_glfuncs, GLenum target, GLsizei start, GLint x, GLint y, GLsizei width);
+void gl4_2compat_glColorSubTable(void *_glfuncs, GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum gltype, const GLvoid* data);
+void gl4_2compat_glGetColorTableParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl4_2compat_glGetColorTableParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl4_2compat_glGetColorTable(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* table);
+void gl4_2compat_glCopyColorTable(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width);
+void gl4_2compat_glColorTableParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl4_2compat_glColorTableParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl4_2compat_glColorTable(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLenum format, GLenum gltype, const GLvoid* table);
+void gl4_2compat_glMultTransposeMatrixd(void *_glfuncs, const GLdouble* m);
+void gl4_2compat_glMultTransposeMatrixf(void *_glfuncs, const GLfloat* m);
+void gl4_2compat_glLoadTransposeMatrixd(void *_glfuncs, const GLdouble* m);
+void gl4_2compat_glLoadTransposeMatrixf(void *_glfuncs, const GLfloat* m);
+void gl4_2compat_glMultiTexCoord4sv(void *_glfuncs, GLenum target, const GLshort* v);
+void gl4_2compat_glMultiTexCoord4s(void *_glfuncs, GLenum target, GLshort s, GLshort t, GLshort r, GLshort q);
+void gl4_2compat_glMultiTexCoord4iv(void *_glfuncs, GLenum target, const GLint* v);
+void gl4_2compat_glMultiTexCoord4i(void *_glfuncs, GLenum target, GLint s, GLint t, GLint r, GLint q);
+void gl4_2compat_glMultiTexCoord4fv(void *_glfuncs, GLenum target, const GLfloat* v);
+void gl4_2compat_glMultiTexCoord4f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+void gl4_2compat_glMultiTexCoord4dv(void *_glfuncs, GLenum target, const GLdouble* v);
+void gl4_2compat_glMultiTexCoord4d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+void gl4_2compat_glMultiTexCoord3sv(void *_glfuncs, GLenum target, const GLshort* v);
+void gl4_2compat_glMultiTexCoord3s(void *_glfuncs, GLenum target, GLshort s, GLshort t, GLshort r);
+void gl4_2compat_glMultiTexCoord3iv(void *_glfuncs, GLenum target, const GLint* v);
+void gl4_2compat_glMultiTexCoord3i(void *_glfuncs, GLenum target, GLint s, GLint t, GLint r);
+void gl4_2compat_glMultiTexCoord3fv(void *_glfuncs, GLenum target, const GLfloat* v);
+void gl4_2compat_glMultiTexCoord3f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t, GLfloat r);
+void gl4_2compat_glMultiTexCoord3dv(void *_glfuncs, GLenum target, const GLdouble* v);
+void gl4_2compat_glMultiTexCoord3d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t, GLdouble r);
+void gl4_2compat_glMultiTexCoord2sv(void *_glfuncs, GLenum target, const GLshort* v);
+void gl4_2compat_glMultiTexCoord2s(void *_glfuncs, GLenum target, GLshort s, GLshort t);
+void gl4_2compat_glMultiTexCoord2iv(void *_glfuncs, GLenum target, const GLint* v);
+void gl4_2compat_glMultiTexCoord2i(void *_glfuncs, GLenum target, GLint s, GLint t);
+void gl4_2compat_glMultiTexCoord2fv(void *_glfuncs, GLenum target, const GLfloat* v);
+void gl4_2compat_glMultiTexCoord2f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t);
+void gl4_2compat_glMultiTexCoord2dv(void *_glfuncs, GLenum target, const GLdouble* v);
+void gl4_2compat_glMultiTexCoord2d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t);
+void gl4_2compat_glMultiTexCoord1sv(void *_glfuncs, GLenum target, const GLshort* v);
+void gl4_2compat_glMultiTexCoord1s(void *_glfuncs, GLenum target, GLshort s);
+void gl4_2compat_glMultiTexCoord1iv(void *_glfuncs, GLenum target, const GLint* v);
+void gl4_2compat_glMultiTexCoord1i(void *_glfuncs, GLenum target, GLint s);
+void gl4_2compat_glMultiTexCoord1fv(void *_glfuncs, GLenum target, const GLfloat* v);
+void gl4_2compat_glMultiTexCoord1f(void *_glfuncs, GLenum target, GLfloat s);
+void gl4_2compat_glMultiTexCoord1dv(void *_glfuncs, GLenum target, const GLdouble* v);
+void gl4_2compat_glMultiTexCoord1d(void *_glfuncs, GLenum target, GLdouble s);
+void gl4_2compat_glClientActiveTexture(void *_glfuncs, GLenum texture);
+void gl4_2compat_glWindowPos3sv(void *_glfuncs, const GLshort* v);
+void gl4_2compat_glWindowPos3s(void *_glfuncs, GLshort x, GLshort y, GLshort z);
+void gl4_2compat_glWindowPos3iv(void *_glfuncs, const GLint* v);
+void gl4_2compat_glWindowPos3i(void *_glfuncs, GLint x, GLint y, GLint z);
+void gl4_2compat_glWindowPos3fv(void *_glfuncs, const GLfloat* v);
+void gl4_2compat_glWindowPos3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl4_2compat_glWindowPos3dv(void *_glfuncs, const GLdouble* v);
+void gl4_2compat_glWindowPos3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl4_2compat_glWindowPos2sv(void *_glfuncs, const GLshort* v);
+void gl4_2compat_glWindowPos2s(void *_glfuncs, GLshort x, GLshort y);
+void gl4_2compat_glWindowPos2iv(void *_glfuncs, const GLint* v);
+void gl4_2compat_glWindowPos2i(void *_glfuncs, GLint x, GLint y);
+void gl4_2compat_glWindowPos2fv(void *_glfuncs, const GLfloat* v);
+void gl4_2compat_glWindowPos2f(void *_glfuncs, GLfloat x, GLfloat y);
+void gl4_2compat_glWindowPos2dv(void *_glfuncs, const GLdouble* v);
+void gl4_2compat_glWindowPos2d(void *_glfuncs, GLdouble x, GLdouble y);
+void gl4_2compat_glSecondaryColorPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl4_2compat_glSecondaryColor3usv(void *_glfuncs, const GLushort* v);
+void gl4_2compat_glSecondaryColor3us(void *_glfuncs, GLushort red, GLushort green, GLushort blue);
+void gl4_2compat_glSecondaryColor3uiv(void *_glfuncs, const GLuint* v);
+void gl4_2compat_glSecondaryColor3ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue);
+void gl4_2compat_glSecondaryColor3ubv(void *_glfuncs, const GLubyte* v);
+void gl4_2compat_glSecondaryColor3ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue);
+void gl4_2compat_glSecondaryColor3sv(void *_glfuncs, const GLshort* v);
+void gl4_2compat_glSecondaryColor3s(void *_glfuncs, GLshort red, GLshort green, GLshort blue);
+void gl4_2compat_glSecondaryColor3iv(void *_glfuncs, const GLint* v);
+void gl4_2compat_glSecondaryColor3i(void *_glfuncs, GLint red, GLint green, GLint blue);
+void gl4_2compat_glSecondaryColor3fv(void *_glfuncs, const GLfloat* v);
+void gl4_2compat_glSecondaryColor3f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue);
+void gl4_2compat_glSecondaryColor3dv(void *_glfuncs, const GLdouble* v);
+void gl4_2compat_glSecondaryColor3d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue);
+void gl4_2compat_glSecondaryColor3bv(void *_glfuncs, const GLbyte* v);
+void gl4_2compat_glSecondaryColor3b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue);
+void gl4_2compat_glFogCoordPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl4_2compat_glFogCoorddv(void *_glfuncs, const GLdouble* coord);
+void gl4_2compat_glFogCoordd(void *_glfuncs, GLdouble coord);
+void gl4_2compat_glFogCoordfv(void *_glfuncs, const GLfloat* coord);
+void gl4_2compat_glFogCoordf(void *_glfuncs, GLfloat coord);
+void gl4_2compat_glVertexAttrib4usv(void *_glfuncs, GLuint index, const GLushort* v);
+void gl4_2compat_glVertexAttrib4uiv(void *_glfuncs, GLuint index, const GLuint* v);
+void gl4_2compat_glVertexAttrib4ubv(void *_glfuncs, GLuint index, const GLubyte* v);
+void gl4_2compat_glVertexAttrib4sv(void *_glfuncs, GLuint index, const GLshort* v);
+void gl4_2compat_glVertexAttrib4s(void *_glfuncs, GLuint index, GLshort x, GLshort y, GLshort z, GLshort w);
+void gl4_2compat_glVertexAttrib4iv(void *_glfuncs, GLuint index, const GLint* v);
+void gl4_2compat_glVertexAttrib4fv(void *_glfuncs, GLuint index, const GLfloat* v);
+void gl4_2compat_glVertexAttrib4f(void *_glfuncs, GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+void gl4_2compat_glVertexAttrib4dv(void *_glfuncs, GLuint index, const GLdouble* v);
+void gl4_2compat_glVertexAttrib4d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+void gl4_2compat_glVertexAttrib4bv(void *_glfuncs, GLuint index, const GLbyte* v);
+void gl4_2compat_glVertexAttrib4Nusv(void *_glfuncs, GLuint index, const GLushort* v);
+void gl4_2compat_glVertexAttrib4Nuiv(void *_glfuncs, GLuint index, const GLuint* v);
+void gl4_2compat_glVertexAttrib4Nubv(void *_glfuncs, GLuint index, const GLubyte* v);
+void gl4_2compat_glVertexAttrib4Nub(void *_glfuncs, GLuint index, GLubyte x, GLubyte y, GLubyte z, GLubyte w);
+void gl4_2compat_glVertexAttrib4Nsv(void *_glfuncs, GLuint index, const GLshort* v);
+void gl4_2compat_glVertexAttrib4Niv(void *_glfuncs, GLuint index, const GLint* v);
+void gl4_2compat_glVertexAttrib4Nbv(void *_glfuncs, GLuint index, const GLbyte* v);
+void gl4_2compat_glVertexAttrib3sv(void *_glfuncs, GLuint index, const GLshort* v);
+void gl4_2compat_glVertexAttrib3s(void *_glfuncs, GLuint index, GLshort x, GLshort y, GLshort z);
+void gl4_2compat_glVertexAttrib3fv(void *_glfuncs, GLuint index, const GLfloat* v);
+void gl4_2compat_glVertexAttrib3f(void *_glfuncs, GLuint index, GLfloat x, GLfloat y, GLfloat z);
+void gl4_2compat_glVertexAttrib3dv(void *_glfuncs, GLuint index, const GLdouble* v);
+void gl4_2compat_glVertexAttrib3d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y, GLdouble z);
+void gl4_2compat_glVertexAttrib2sv(void *_glfuncs, GLuint index, const GLshort* v);
+void gl4_2compat_glVertexAttrib2s(void *_glfuncs, GLuint index, GLshort x, GLshort y);
+void gl4_2compat_glVertexAttrib2fv(void *_glfuncs, GLuint index, const GLfloat* v);
+void gl4_2compat_glVertexAttrib2f(void *_glfuncs, GLuint index, GLfloat x, GLfloat y);
+void gl4_2compat_glVertexAttrib2dv(void *_glfuncs, GLuint index, const GLdouble* v);
+void gl4_2compat_glVertexAttrib2d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y);
+void gl4_2compat_glVertexAttrib1sv(void *_glfuncs, GLuint index, const GLshort* v);
+void gl4_2compat_glVertexAttrib1s(void *_glfuncs, GLuint index, GLshort x);
+void gl4_2compat_glVertexAttrib1fv(void *_glfuncs, GLuint index, const GLfloat* v);
+void gl4_2compat_glVertexAttrib1f(void *_glfuncs, GLuint index, GLfloat x);
+void gl4_2compat_glVertexAttrib1dv(void *_glfuncs, GLuint index, const GLdouble* v);
+void gl4_2compat_glVertexAttrib1d(void *_glfuncs, GLuint index, GLdouble x);
+void gl4_2compat_glVertexAttribI4usv(void *_glfuncs, GLuint index, const GLushort* v);
+void gl4_2compat_glVertexAttribI4ubv(void *_glfuncs, GLuint index, const GLubyte* v);
+void gl4_2compat_glVertexAttribI4sv(void *_glfuncs, GLuint index, const GLshort* v);
+void gl4_2compat_glVertexAttribI4bv(void *_glfuncs, GLuint index, const GLbyte* v);
+void gl4_2compat_glVertexAttribI4uiv(void *_glfuncs, GLuint index, const GLuint* v);
+void gl4_2compat_glVertexAttribI3uiv(void *_glfuncs, GLuint index, const GLuint* v);
+void gl4_2compat_glVertexAttribI2uiv(void *_glfuncs, GLuint index, const GLuint* v);
+void gl4_2compat_glVertexAttribI1uiv(void *_glfuncs, GLuint index, const GLuint* v);
+void gl4_2compat_glVertexAttribI4iv(void *_glfuncs, GLuint index, const GLint* v);
+void gl4_2compat_glVertexAttribI3iv(void *_glfuncs, GLuint index, const GLint* v);
+void gl4_2compat_glVertexAttribI2iv(void *_glfuncs, GLuint index, const GLint* v);
+void gl4_2compat_glVertexAttribI1iv(void *_glfuncs, GLuint index, const GLint* v);
+void gl4_2compat_glVertexAttribI4ui(void *_glfuncs, GLuint index, GLuint x, GLuint y, GLuint z, GLuint w);
+void gl4_2compat_glVertexAttribI3ui(void *_glfuncs, GLuint index, GLuint x, GLuint y, GLuint z);
+void gl4_2compat_glVertexAttribI2ui(void *_glfuncs, GLuint index, GLuint x, GLuint y);
+void gl4_2compat_glVertexAttribI1ui(void *_glfuncs, GLuint index, GLuint x);
+void gl4_2compat_glVertexAttribI4i(void *_glfuncs, GLuint index, GLint x, GLint y, GLint z, GLint w);
+void gl4_2compat_glVertexAttribI3i(void *_glfuncs, GLuint index, GLint x, GLint y, GLint z);
+void gl4_2compat_glVertexAttribI2i(void *_glfuncs, GLuint index, GLint x, GLint y);
+void gl4_2compat_glVertexAttribI1i(void *_glfuncs, GLuint index, GLint x);
+
+
+#ifdef __cplusplus
+} // extern "C"
+#endif
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.2compat/gl.go b/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.2compat/gl.go
new file mode 100644
index 000000000..c91fbef65
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.2compat/gl.go
@@ -0,0 +1,9386 @@
+// ** file automatically generated by glgen -- do not edit manually **
+
+package GL
+
+// #cgo CXXFLAGS: -std=c++0x -pedantic-errors -Wall -fno-strict-aliasing
+// #cgo LDFLAGS: -lstdc++
+// #cgo pkg-config: Qt5Core Qt5OpenGL
+//
+// #include "funcs.h"
+//
+// void free(void*);
+//
+import "C"
+
+import (
+ "fmt"
+ "reflect"
+ "unsafe"
+
+ "gopkg.in/qml.v1/gl/glbase"
+)
+
+// API returns a value that offers methods matching the OpenGL version 4.2 API.
+//
+// The returned API must not be used after the provided OpenGL context becomes invalid.
+func API(context glbase.Contexter) *GL {
+ gl := &GL{}
+ gl.funcs = C.gl4_2compat_funcs()
+ if gl.funcs == nil {
+ panic(fmt.Errorf("OpenGL version 4.2 is not available"))
+ }
+ return gl
+}
+
+// GL implements the OpenGL version 4.2 API. Values of this
+// type must be created via the API function, and it must not be used after
+// the associated OpenGL context becomes invalid.
+type GL struct {
+ funcs unsafe.Pointer
+}
+
+const (
+ FALSE = 0
+ TRUE = 1
+ NONE = 0
+
+ BYTE = 0x1400
+ UNSIGNED_BYTE = 0x1401
+ SHORT = 0x1402
+ UNSIGNED_SHORT = 0x1403
+ INT = 0x1404
+ UNSIGNED_INT = 0x1405
+ FLOAT = 0x1406
+ N2_BYTES = 0x1407
+ N3_BYTES = 0x1408
+ N4_BYTES = 0x1409
+ DOUBLE = 0x140A
+ HALF_FLOAT = 0x140B
+ FIXED = 0x140C
+
+ ACCUM = 0x0100
+ LOAD = 0x0101
+ RETURN = 0x0102
+ MULT = 0x0103
+ ADD = 0x0104
+
+ ACCUM_BUFFER_BIT = 0x00000200
+ ALL_ATTRIB_BITS = 0xFFFFFFFF
+ COLOR_BUFFER_BIT = 0x00004000
+ CURRENT_BIT = 0x00000001
+ DEPTH_BUFFER_BIT = 0x00000100
+ ENABLE_BIT = 0x00002000
+ EVAL_BIT = 0x00010000
+ FOG_BIT = 0x00000080
+ HINT_BIT = 0x00008000
+ LIGHTING_BIT = 0x00000040
+ LINE_BIT = 0x00000004
+ LIST_BIT = 0x00020000
+ MULTISAMPLE_BIT = 0x20000000
+ PIXEL_MODE_BIT = 0x00000020
+ POINT_BIT = 0x00000002
+ POLYGON_BIT = 0x00000008
+ POLYGON_STIPPLE_BIT = 0x00000010
+ SCISSOR_BIT = 0x00080000
+ STENCIL_BUFFER_BIT = 0x00000400
+ TEXTURE_BIT = 0x00040000
+ TRANSFORM_BIT = 0x00001000
+ VIEWPORT_BIT = 0x00000800
+
+ ALWAYS = 0x0207
+ EQUAL = 0x0202
+ GEQUAL = 0x0206
+ GREATER = 0x0204
+ LEQUAL = 0x0203
+ LESS = 0x0201
+ NEVER = 0x0200
+ NOTEQUAL = 0x0205
+
+ LOGIC_OP = 0x0BF1
+
+ DST_ALPHA = 0x0304
+ ONE = 1
+ ONE_MINUS_DST_ALPHA = 0x0305
+ ONE_MINUS_SRC_ALPHA = 0x0303
+ ONE_MINUS_SRC_COLOR = 0x0301
+ SRC_ALPHA = 0x0302
+ SRC_COLOR = 0x0300
+ ZERO = 0
+
+ DST_COLOR = 0x0306
+ ONE_MINUS_DST_COLOR = 0x0307
+ SRC_ALPHA_SATURATE = 0x0308
+
+ CLIENT_ALL_ATTRIB_BITS = 0xFFFFFFFF
+ CLIENT_PIXEL_STORE_BIT = 0x00000001
+ CLIENT_VERTEX_ARRAY_BIT = 0x00000002
+
+ CLIP_DISTANCE0 = 0x3000
+ CLIP_DISTANCE1 = 0x3001
+ CLIP_DISTANCE2 = 0x3002
+ CLIP_DISTANCE3 = 0x3003
+ CLIP_DISTANCE4 = 0x3004
+ CLIP_DISTANCE5 = 0x3005
+ CLIP_DISTANCE6 = 0x3006
+ CLIP_DISTANCE7 = 0x3007
+ CLIP_PLANE0 = 0x3000
+ CLIP_PLANE1 = 0x3001
+ CLIP_PLANE2 = 0x3002
+ CLIP_PLANE3 = 0x3003
+ CLIP_PLANE4 = 0x3004
+ CLIP_PLANE5 = 0x3005
+
+ BACK = 0x0405
+ FRONT = 0x0404
+ FRONT_AND_BACK = 0x0408
+
+ AMBIENT = 0x1200
+ AMBIENT_AND_DIFFUSE = 0x1602
+ DIFFUSE = 0x1201
+ EMISSION = 0x1600
+ SPECULAR = 0x1202
+
+ CONTEXT_FLAG_FORWARD_COMPATIBLE_BIT = 0x00000001
+
+ CONTEXT_COMPATIBILITY_PROFILE_BIT = 0x00000002
+ CONTEXT_CORE_PROFILE_BIT = 0x00000001
+
+ AUX0 = 0x0409
+ AUX1 = 0x040A
+ AUX2 = 0x040B
+ AUX3 = 0x040C
+ BACK_LEFT = 0x0402
+ BACK_RIGHT = 0x0403
+ FRONT_LEFT = 0x0400
+ FRONT_RIGHT = 0x0401
+ LEFT = 0x0406
+ RIGHT = 0x0407
+
+ ALPHA_TEST = 0x0BC0
+ AUTO_NORMAL = 0x0D80
+ BLEND = 0x0BE2
+ COLOR_ARRAY = 0x8076
+ COLOR_LOGIC_OP = 0x0BF2
+ COLOR_MATERIAL = 0x0B57
+ CULL_FACE = 0x0B44
+ DEPTH_TEST = 0x0B71
+ DITHER = 0x0BD0
+ EDGE_FLAG_ARRAY = 0x8079
+ FOG = 0x0B60
+ INDEX_ARRAY = 0x8077
+ INDEX_LOGIC_OP = 0x0BF1
+ LIGHT0 = 0x4000
+ LIGHT1 = 0x4001
+ LIGHT2 = 0x4002
+ LIGHT3 = 0x4003
+ LIGHT4 = 0x4004
+ LIGHT5 = 0x4005
+ LIGHT6 = 0x4006
+ LIGHT7 = 0x4007
+ LIGHTING = 0x0B50
+ LINE_SMOOTH = 0x0B20
+ LINE_STIPPLE = 0x0B24
+ MAP1_COLOR_4 = 0x0D90
+ MAP1_INDEX = 0x0D91
+ MAP1_NORMAL = 0x0D92
+ MAP1_TEXTURE_COORD_1 = 0x0D93
+ MAP1_TEXTURE_COORD_2 = 0x0D94
+ MAP1_TEXTURE_COORD_3 = 0x0D95
+ MAP1_TEXTURE_COORD_4 = 0x0D96
+ MAP1_VERTEX_3 = 0x0D97
+ MAP1_VERTEX_4 = 0x0D98
+ MAP2_COLOR_4 = 0x0DB0
+ MAP2_INDEX = 0x0DB1
+ MAP2_NORMAL = 0x0DB2
+ MAP2_TEXTURE_COORD_1 = 0x0DB3
+ MAP2_TEXTURE_COORD_2 = 0x0DB4
+ MAP2_TEXTURE_COORD_3 = 0x0DB5
+ MAP2_TEXTURE_COORD_4 = 0x0DB6
+ MAP2_VERTEX_3 = 0x0DB7
+ MAP2_VERTEX_4 = 0x0DB8
+ NORMALIZE = 0x0BA1
+ NORMAL_ARRAY = 0x8075
+ POINT_SMOOTH = 0x0B10
+ POLYGON_OFFSET_FILL = 0x8037
+ POLYGON_OFFSET_LINE = 0x2A02
+ POLYGON_OFFSET_POINT = 0x2A01
+ POLYGON_SMOOTH = 0x0B41
+ POLYGON_STIPPLE = 0x0B42
+ SCISSOR_TEST = 0x0C11
+ STENCIL_TEST = 0x0B90
+ TEXTURE_1D = 0x0DE0
+ TEXTURE_2D = 0x0DE1
+ TEXTURE_COORD_ARRAY = 0x8078
+ TEXTURE_GEN_Q = 0x0C63
+ TEXTURE_GEN_R = 0x0C62
+ TEXTURE_GEN_S = 0x0C60
+ TEXTURE_GEN_T = 0x0C61
+ VERTEX_ARRAY = 0x8074
+
+ INVALID_ENUM = 0x0500
+ INVALID_FRAMEBUFFER_OPERATION = 0x0506
+ INVALID_OPERATION = 0x0502
+ INVALID_VALUE = 0x0501
+ NO_ERROR = 0
+ OUT_OF_MEMORY = 0x0505
+ STACK_OVERFLOW = 0x0503
+ STACK_UNDERFLOW = 0x0504
+
+ N2D = 0x0600
+ N3D = 0x0601
+ N3D_COLOR = 0x0602
+ N3D_COLOR_TEXTURE = 0x0603
+ N4D_COLOR_TEXTURE = 0x0604
+
+ BITMAP_TOKEN = 0x0704
+ COPY_PIXEL_TOKEN = 0x0706
+ DRAW_PIXEL_TOKEN = 0x0705
+ LINE_RESET_TOKEN = 0x0707
+ LINE_TOKEN = 0x0702
+ PASS_THROUGH_TOKEN = 0x0700
+ POINT_TOKEN = 0x0701
+ POLYGON_TOKEN = 0x0703
+
+ EXP = 0x0800
+ EXP2 = 0x0801
+ LINEAR = 0x2601
+
+ FOG_COLOR = 0x0B66
+ FOG_DENSITY = 0x0B62
+ FOG_END = 0x0B64
+ FOG_INDEX = 0x0B61
+ FOG_MODE = 0x0B65
+ FOG_START = 0x0B63
+
+ CCW = 0x0901
+ CW = 0x0900
+
+ COEFF = 0x0A00
+ DOMAIN = 0x0A02
+ ORDER = 0x0A01
+
+ PIXEL_MAP_A_TO_A = 0x0C79
+ PIXEL_MAP_B_TO_B = 0x0C78
+ PIXEL_MAP_G_TO_G = 0x0C77
+ PIXEL_MAP_I_TO_A = 0x0C75
+ PIXEL_MAP_I_TO_B = 0x0C74
+ PIXEL_MAP_I_TO_G = 0x0C73
+ PIXEL_MAP_I_TO_I = 0x0C70
+ PIXEL_MAP_I_TO_R = 0x0C72
+ PIXEL_MAP_R_TO_R = 0x0C76
+ PIXEL_MAP_S_TO_S = 0x0C71
+
+ ACCUM_ALPHA_BITS = 0x0D5B
+ ACCUM_BLUE_BITS = 0x0D5A
+ ACCUM_CLEAR_VALUE = 0x0B80
+ ACCUM_GREEN_BITS = 0x0D59
+ ACCUM_RED_BITS = 0x0D58
+ ALIASED_LINE_WIDTH_RANGE = 0x846E
+ ALIASED_POINT_SIZE_RANGE = 0x846D
+ ALPHA_BIAS = 0x0D1D
+ ALPHA_BITS = 0x0D55
+ ALPHA_SCALE = 0x0D1C
+ ALPHA_TEST_FUNC = 0x0BC1
+ ALPHA_TEST_REF = 0x0BC2
+ ATTRIB_STACK_DEPTH = 0x0BB0
+ AUX_BUFFERS = 0x0C00
+ BLEND_DST = 0x0BE0
+ BLEND_SRC = 0x0BE1
+ BLUE_BIAS = 0x0D1B
+ BLUE_BITS = 0x0D54
+ BLUE_SCALE = 0x0D1A
+ CLIENT_ATTRIB_STACK_DEPTH = 0x0BB1
+ COLOR_ARRAY_SIZE = 0x8081
+ COLOR_ARRAY_STRIDE = 0x8083
+ COLOR_ARRAY_TYPE = 0x8082
+ COLOR_CLEAR_VALUE = 0x0C22
+ COLOR_MATERIAL_FACE = 0x0B55
+ COLOR_MATERIAL_PARAMETER = 0x0B56
+ COLOR_WRITEMASK = 0x0C23
+ CULL_FACE_MODE = 0x0B45
+ CURRENT_COLOR = 0x0B00
+ CURRENT_INDEX = 0x0B01
+ CURRENT_NORMAL = 0x0B02
+ CURRENT_RASTER_COLOR = 0x0B04
+ CURRENT_RASTER_DISTANCE = 0x0B09
+ CURRENT_RASTER_INDEX = 0x0B05
+ CURRENT_RASTER_POSITION = 0x0B07
+ CURRENT_RASTER_POSITION_VALID = 0x0B08
+ CURRENT_RASTER_TEXTURE_COORDS = 0x0B06
+ CURRENT_TEXTURE_COORDS = 0x0B03
+ DEPTH_BIAS = 0x0D1F
+ DEPTH_BITS = 0x0D56
+ DEPTH_CLEAR_VALUE = 0x0B73
+ DEPTH_FUNC = 0x0B74
+ DEPTH_RANGE = 0x0B70
+ DEPTH_SCALE = 0x0D1E
+ DEPTH_WRITEMASK = 0x0B72
+ DOUBLEBUFFER = 0x0C32
+ DRAW_BUFFER = 0x0C01
+ EDGE_FLAG = 0x0B43
+ EDGE_FLAG_ARRAY_STRIDE = 0x808C
+ FEEDBACK_BUFFER_SIZE = 0x0DF1
+ FEEDBACK_BUFFER_TYPE = 0x0DF2
+ FOG_HINT = 0x0C54
+ FRONT_FACE = 0x0B46
+ GREEN_BIAS = 0x0D19
+ GREEN_BITS = 0x0D53
+ GREEN_SCALE = 0x0D18
+ INDEX_ARRAY_STRIDE = 0x8086
+ INDEX_ARRAY_TYPE = 0x8085
+ INDEX_BITS = 0x0D51
+ INDEX_CLEAR_VALUE = 0x0C20
+ INDEX_MODE = 0x0C30
+ INDEX_OFFSET = 0x0D13
+ INDEX_SHIFT = 0x0D12
+ INDEX_WRITEMASK = 0x0C21
+ LIGHT_MODEL_AMBIENT = 0x0B53
+ LIGHT_MODEL_COLOR_CONTROL = 0x81F8
+ LIGHT_MODEL_LOCAL_VIEWER = 0x0B51
+ LIGHT_MODEL_TWO_SIDE = 0x0B52
+ LINE_SMOOTH_HINT = 0x0C52
+ LINE_STIPPLE_PATTERN = 0x0B25
+ LINE_STIPPLE_REPEAT = 0x0B26
+ LINE_WIDTH = 0x0B21
+ LINE_WIDTH_GRANULARITY = 0x0B23
+ LINE_WIDTH_RANGE = 0x0B22
+ LIST_BASE = 0x0B32
+ LIST_INDEX = 0x0B33
+ LIST_MODE = 0x0B30
+ LOGIC_OP_MODE = 0x0BF0
+ MAP1_GRID_DOMAIN = 0x0DD0
+ MAP1_GRID_SEGMENTS = 0x0DD1
+ MAP2_GRID_DOMAIN = 0x0DD2
+ MAP2_GRID_SEGMENTS = 0x0DD3
+ MAP_COLOR = 0x0D10
+ MAP_STENCIL = 0x0D11
+ MATRIX_MODE = 0x0BA0
+ MAX_ATTRIB_STACK_DEPTH = 0x0D35
+ MAX_CLIENT_ATTRIB_STACK_DEPTH = 0x0D3B
+ MAX_CLIP_DISTANCES = 0x0D32
+ MAX_CLIP_PLANES = 0x0D32
+ MAX_EVAL_ORDER = 0x0D30
+ MAX_LIGHTS = 0x0D31
+ MAX_LIST_NESTING = 0x0B31
+ MAX_MODELVIEW_STACK_DEPTH = 0x0D36
+ MAX_NAME_STACK_DEPTH = 0x0D37
+ MAX_PIXEL_MAP_TABLE = 0x0D34
+ MAX_PROJECTION_STACK_DEPTH = 0x0D38
+ MAX_TEXTURE_SIZE = 0x0D33
+ MAX_TEXTURE_STACK_DEPTH = 0x0D39
+ MAX_VIEWPORT_DIMS = 0x0D3A
+ MODELVIEW_MATRIX = 0x0BA6
+ MODELVIEW_STACK_DEPTH = 0x0BA3
+ NAME_STACK_DEPTH = 0x0D70
+ NORMAL_ARRAY_STRIDE = 0x807F
+ NORMAL_ARRAY_TYPE = 0x807E
+ PACK_ALIGNMENT = 0x0D05
+ PACK_LSB_FIRST = 0x0D01
+ PACK_ROW_LENGTH = 0x0D02
+ PACK_SKIP_PIXELS = 0x0D04
+ PACK_SKIP_ROWS = 0x0D03
+ PACK_SWAP_BYTES = 0x0D00
+ PERSPECTIVE_CORRECTION_HINT = 0x0C50
+ PIXEL_MAP_A_TO_A_SIZE = 0x0CB9
+ PIXEL_MAP_B_TO_B_SIZE = 0x0CB8
+ PIXEL_MAP_G_TO_G_SIZE = 0x0CB7
+ PIXEL_MAP_I_TO_A_SIZE = 0x0CB5
+ PIXEL_MAP_I_TO_B_SIZE = 0x0CB4
+ PIXEL_MAP_I_TO_G_SIZE = 0x0CB3
+ PIXEL_MAP_I_TO_I_SIZE = 0x0CB0
+ PIXEL_MAP_I_TO_R_SIZE = 0x0CB2
+ PIXEL_MAP_R_TO_R_SIZE = 0x0CB6
+ PIXEL_MAP_S_TO_S_SIZE = 0x0CB1
+ POINT_SIZE = 0x0B11
+ POINT_SIZE_GRANULARITY = 0x0B13
+ POINT_SIZE_RANGE = 0x0B12
+ POINT_SMOOTH_HINT = 0x0C51
+ POLYGON_MODE = 0x0B40
+ POLYGON_OFFSET_FACTOR = 0x8038
+ POLYGON_OFFSET_UNITS = 0x2A00
+ POLYGON_SMOOTH_HINT = 0x0C53
+ PROJECTION_MATRIX = 0x0BA7
+ PROJECTION_STACK_DEPTH = 0x0BA4
+ READ_BUFFER = 0x0C02
+ RED_BIAS = 0x0D15
+ RED_BITS = 0x0D52
+ RED_SCALE = 0x0D14
+ RENDER_MODE = 0x0C40
+ RGBA_MODE = 0x0C31
+ SCISSOR_BOX = 0x0C10
+ SELECTION_BUFFER_SIZE = 0x0DF4
+ SHADE_MODEL = 0x0B54
+ SMOOTH_LINE_WIDTH_GRANULARITY = 0x0B23
+ SMOOTH_LINE_WIDTH_RANGE = 0x0B22
+ SMOOTH_POINT_SIZE_GRANULARITY = 0x0B13
+ SMOOTH_POINT_SIZE_RANGE = 0x0B12
+ STENCIL_BITS = 0x0D57
+ STENCIL_CLEAR_VALUE = 0x0B91
+ STENCIL_FAIL = 0x0B94
+ STENCIL_FUNC = 0x0B92
+ STENCIL_PASS_DEPTH_FAIL = 0x0B95
+ STENCIL_PASS_DEPTH_PASS = 0x0B96
+ STENCIL_REF = 0x0B97
+ STENCIL_VALUE_MASK = 0x0B93
+ STENCIL_WRITEMASK = 0x0B98
+ STEREO = 0x0C33
+ SUBPIXEL_BITS = 0x0D50
+ TEXTURE_BINDING_1D = 0x8068
+ TEXTURE_BINDING_2D = 0x8069
+ TEXTURE_BINDING_3D = 0x806A
+ TEXTURE_COORD_ARRAY_SIZE = 0x8088
+ TEXTURE_COORD_ARRAY_STRIDE = 0x808A
+ TEXTURE_COORD_ARRAY_TYPE = 0x8089
+ TEXTURE_MATRIX = 0x0BA8
+ TEXTURE_STACK_DEPTH = 0x0BA5
+ UNPACK_ALIGNMENT = 0x0CF5
+ UNPACK_LSB_FIRST = 0x0CF1
+ UNPACK_ROW_LENGTH = 0x0CF2
+ UNPACK_SKIP_PIXELS = 0x0CF4
+ UNPACK_SKIP_ROWS = 0x0CF3
+ UNPACK_SWAP_BYTES = 0x0CF0
+ VERTEX_ARRAY_SIZE = 0x807A
+ VERTEX_ARRAY_STRIDE = 0x807C
+ VERTEX_ARRAY_TYPE = 0x807B
+ VIEWPORT = 0x0BA2
+ ZOOM_X = 0x0D16
+ ZOOM_Y = 0x0D17
+
+ COLOR_ARRAY_POINTER = 0x8090
+ EDGE_FLAG_ARRAY_POINTER = 0x8093
+ FEEDBACK_BUFFER_POINTER = 0x0DF0
+ INDEX_ARRAY_POINTER = 0x8091
+ NORMAL_ARRAY_POINTER = 0x808F
+ SELECTION_BUFFER_POINTER = 0x0DF3
+ TEXTURE_COORD_ARRAY_POINTER = 0x8092
+ VERTEX_ARRAY_POINTER = 0x808E
+
+ TEXTURE_ALPHA_SIZE = 0x805F
+ TEXTURE_BLUE_SIZE = 0x805E
+ TEXTURE_BORDER = 0x1005
+ TEXTURE_BORDER_COLOR = 0x1004
+ TEXTURE_COMPONENTS = 0x1003
+ TEXTURE_GREEN_SIZE = 0x805D
+ TEXTURE_HEIGHT = 0x1001
+ TEXTURE_INTENSITY_SIZE = 0x8061
+ TEXTURE_INTERNAL_FORMAT = 0x1003
+ TEXTURE_LUMINANCE_SIZE = 0x8060
+ TEXTURE_MAG_FILTER = 0x2800
+ TEXTURE_MIN_FILTER = 0x2801
+ TEXTURE_PRIORITY = 0x8066
+ TEXTURE_RED_SIZE = 0x805C
+ TEXTURE_RESIDENT = 0x8067
+ TEXTURE_WIDTH = 0x1000
+ TEXTURE_WRAP_S = 0x2802
+ TEXTURE_WRAP_T = 0x2803
+
+ DONT_CARE = 0x1100
+ FASTEST = 0x1101
+ NICEST = 0x1102
+
+ FRAGMENT_SHADER_DERIVATIVE_HINT = 0x8B8B
+ GENERATE_MIPMAP_HINT = 0x8192
+ PROGRAM_BINARY_RETRIEVABLE_HINT = 0x8257
+ TEXTURE_COMPRESSION_HINT = 0x84EF
+
+ C3F_V3F = 0x2A24
+ C4F_N3F_V3F = 0x2A26
+ C4UB_V2F = 0x2A22
+ C4UB_V3F = 0x2A23
+ N3F_V3F = 0x2A25
+ T2F_C3F_V3F = 0x2A2A
+ T2F_C4F_N3F_V3F = 0x2A2C
+ T2F_C4UB_V3F = 0x2A29
+ T2F_N3F_V3F = 0x2A2B
+ T2F_V3F = 0x2A27
+ T4F_C4F_N3F_V4F = 0x2A2D
+ T4F_V4F = 0x2A28
+ V2F = 0x2A20
+ V3F = 0x2A21
+
+ MODULATE = 0x2100
+ REPLACE = 0x1E01
+
+ SEPARATE_SPECULAR_COLOR = 0x81FA
+ SINGLE_COLOR = 0x81F9
+
+ CONSTANT_ATTENUATION = 0x1207
+ LINEAR_ATTENUATION = 0x1208
+ POSITION = 0x1203
+ QUADRATIC_ATTENUATION = 0x1209
+ SPOT_CUTOFF = 0x1206
+ SPOT_DIRECTION = 0x1204
+ SPOT_EXPONENT = 0x1205
+
+ COMPILE = 0x1300
+ COMPILE_AND_EXECUTE = 0x1301
+
+ AND = 0x1501
+ AND_INVERTED = 0x1504
+ AND_REVERSE = 0x1502
+ CLEAR = 0x1500
+ COPY = 0x1503
+ COPY_INVERTED = 0x150C
+ EQUIV = 0x1509
+ INVERT = 0x150A
+ NAND = 0x150E
+ NOOP = 0x1505
+ NOR = 0x1508
+ OR = 0x1507
+ OR_INVERTED = 0x150D
+ OR_REVERSE = 0x150B
+ SET = 0x150F
+ XOR = 0x1506
+
+ MAP_FLUSH_EXPLICIT_BIT = 0x0010
+ MAP_INVALIDATE_BUFFER_BIT = 0x0008
+ MAP_INVALIDATE_RANGE_BIT = 0x0004
+ MAP_READ_BIT = 0x0001
+ MAP_UNSYNCHRONIZED_BIT = 0x0020
+ MAP_WRITE_BIT = 0x0002
+
+ COLOR_INDEXES = 0x1603
+ SHININESS = 0x1601
+
+ MODELVIEW = 0x1700
+ PROJECTION = 0x1701
+ TEXTURE = 0x1702
+
+ ALL_BARRIER_BITS = 0xFFFFFFFF
+ ATOMIC_COUNTER_BARRIER_BIT = 0x00001000
+ BUFFER_UPDATE_BARRIER_BIT = 0x00000200
+ COMMAND_BARRIER_BIT = 0x00000040
+ ELEMENT_ARRAY_BARRIER_BIT = 0x00000002
+ FRAMEBUFFER_BARRIER_BIT = 0x00000400
+ PIXEL_BUFFER_BARRIER_BIT = 0x00000080
+ SHADER_IMAGE_ACCESS_BARRIER_BIT = 0x00000020
+ TEXTURE_FETCH_BARRIER_BIT = 0x00000008
+ TEXTURE_UPDATE_BARRIER_BIT = 0x00000100
+ TRANSFORM_FEEDBACK_BARRIER_BIT = 0x00000800
+ UNIFORM_BARRIER_BIT = 0x00000004
+ VERTEX_ATTRIB_ARRAY_BARRIER_BIT = 0x00000001
+
+ LINE = 0x1B01
+ POINT = 0x1B00
+
+ FILL = 0x1B02
+
+ COLOR = 0x1800
+ DEPTH = 0x1801
+ STENCIL = 0x1802
+
+ ALPHA = 0x1906
+ BLUE = 0x1905
+ COLOR_INDEX = 0x1900
+ DEPTH_COMPONENT = 0x1902
+ GREEN = 0x1904
+ LUMINANCE = 0x1909
+ LUMINANCE_ALPHA = 0x190A
+ RED = 0x1903
+ RGB = 0x1907
+ RGBA = 0x1908
+ STENCIL_INDEX = 0x1901
+
+ ALPHA12 = 0x803D
+ ALPHA16 = 0x803E
+ ALPHA4 = 0x803B
+ ALPHA8 = 0x803C
+ INTENSITY = 0x8049
+ INTENSITY12 = 0x804C
+ INTENSITY16 = 0x804D
+ INTENSITY4 = 0x804A
+ INTENSITY8 = 0x804B
+ LUMINANCE12 = 0x8041
+ LUMINANCE12_ALPHA12 = 0x8047
+ LUMINANCE12_ALPHA4 = 0x8046
+ LUMINANCE16 = 0x8042
+ LUMINANCE16_ALPHA16 = 0x8048
+ LUMINANCE4 = 0x803F
+ LUMINANCE4_ALPHA4 = 0x8043
+ LUMINANCE6_ALPHA2 = 0x8044
+ LUMINANCE8 = 0x8040
+ LUMINANCE8_ALPHA8 = 0x8045
+ R3_G3_B2 = 0x2A10
+ RGB10 = 0x8052
+ RGB10_A2 = 0x8059
+ RGB12 = 0x8053
+ RGB16 = 0x8054
+ RGB4 = 0x804F
+ RGB5 = 0x8050
+ RGB5_A1 = 0x8057
+ RGB8 = 0x8051
+ RGBA12 = 0x805A
+ RGBA16 = 0x805B
+ RGBA2 = 0x8055
+ RGBA4 = 0x8056
+ RGBA8 = 0x8058
+
+ PACK_IMAGE_HEIGHT = 0x806C
+ PACK_SKIP_IMAGES = 0x806B
+ UNPACK_IMAGE_HEIGHT = 0x806E
+ UNPACK_SKIP_IMAGES = 0x806D
+
+ BITMAP = 0x1A00
+ UNSIGNED_BYTE_3_3_2 = 0x8032
+ UNSIGNED_INT_10_10_10_2 = 0x8036
+ UNSIGNED_INT_8_8_8_8 = 0x8035
+ UNSIGNED_SHORT_4_4_4_4 = 0x8033
+ UNSIGNED_SHORT_5_5_5_1 = 0x8034
+
+ POINT_DISTANCE_ATTENUATION = 0x8129
+ POINT_FADE_THRESHOLD_SIZE = 0x8128
+ POINT_SIZE_MAX = 0x8127
+ POINT_SIZE_MIN = 0x8126
+
+ LINES = 0x0001
+ LINES_ADJACENCY = 0x000A
+ LINE_LOOP = 0x0002
+ LINE_STRIP = 0x0003
+ LINE_STRIP_ADJACENCY = 0x000B
+ PATCHES = 0x000E
+ POINTS = 0x0000
+ POLYGON = 0x0009
+ QUADS = 0x0007
+ QUAD_STRIP = 0x0008
+ TRIANGLES = 0x0004
+ TRIANGLES_ADJACENCY = 0x000C
+ TRIANGLE_FAN = 0x0006
+ TRIANGLE_STRIP = 0x0005
+ TRIANGLE_STRIP_ADJACENCY = 0x000D
+
+ FEEDBACK = 0x1C01
+ RENDER = 0x1C00
+ SELECT = 0x1C02
+
+ FLAT = 0x1D00
+ SMOOTH = 0x1D01
+
+ DECR = 0x1E03
+ INCR = 0x1E02
+ KEEP = 0x1E00
+
+ EXTENSIONS = 0x1F03
+ RENDERER = 0x1F01
+ VENDOR = 0x1F00
+ VERSION = 0x1F02
+
+ S = 0x2000
+ T = 0x2001
+ R = 0x2002
+ Q = 0x2003
+
+ DECAL = 0x2101
+
+ TEXTURE_ENV_COLOR = 0x2201
+ TEXTURE_ENV_MODE = 0x2200
+
+ TEXTURE_ENV = 0x2300
+
+ EYE_LINEAR = 0x2400
+ OBJECT_LINEAR = 0x2401
+ SPHERE_MAP = 0x2402
+
+ EYE_PLANE = 0x2502
+ OBJECT_PLANE = 0x2501
+ TEXTURE_GEN_MODE = 0x2500
+
+ NEAREST = 0x2600
+
+ LINEAR_MIPMAP_LINEAR = 0x2703
+ LINEAR_MIPMAP_NEAREST = 0x2701
+ NEAREST_MIPMAP_LINEAR = 0x2702
+ NEAREST_MIPMAP_NEAREST = 0x2700
+
+ GENERATE_MIPMAP = 0x8191
+ TEXTURE_WRAP_R = 0x8072
+
+ PROXY_TEXTURE_1D = 0x8063
+ PROXY_TEXTURE_2D = 0x8064
+ PROXY_TEXTURE_3D = 0x8070
+ TEXTURE_3D = 0x806F
+ TEXTURE_BASE_LEVEL = 0x813C
+ TEXTURE_MAX_LEVEL = 0x813D
+ TEXTURE_MAX_LOD = 0x813B
+ TEXTURE_MIN_LOD = 0x813A
+
+ CLAMP = 0x2900
+ CLAMP_TO_BORDER = 0x812D
+ CLAMP_TO_EDGE = 0x812F
+ REPEAT = 0x2901
+
+ VERTEX_SHADER_BIT = 0x00000001
+ FRAGMENT_SHADER_BIT = 0x00000002
+ GEOMETRY_SHADER_BIT = 0x00000004
+ TESS_CONTROL_SHADER_BIT = 0x00000008
+ TESS_EVALUATION_SHADER_BIT = 0x00000010
+ ALL_SHADER_BITS = 0xFFFFFFFF
+
+ SYNC_FLUSH_COMMANDS_BIT = 0x00000001
+ INVALID_INDEX = 0xFFFFFFFF
+ TIMEOUT_IGNORED = 0xFFFFFFFFFFFFFFFF
+ CONSTANT_COLOR = 0x8001
+ ONE_MINUS_CONSTANT_COLOR = 0x8002
+ CONSTANT_ALPHA = 0x8003
+ ONE_MINUS_CONSTANT_ALPHA = 0x8004
+ FUNC_ADD = 0x8006
+ MIN = 0x8007
+ MAX = 0x8008
+ BLEND_EQUATION_RGB = 0x8009
+ FUNC_SUBTRACT = 0x800A
+ FUNC_REVERSE_SUBTRACT = 0x800B
+ RESCALE_NORMAL = 0x803A
+ TEXTURE_DEPTH = 0x8071
+ MAX_3D_TEXTURE_SIZE = 0x8073
+ MULTISAMPLE = 0x809D
+ SAMPLE_ALPHA_TO_COVERAGE = 0x809E
+ SAMPLE_ALPHA_TO_ONE = 0x809F
+ SAMPLE_COVERAGE = 0x80A0
+ SAMPLE_BUFFERS = 0x80A8
+ SAMPLES = 0x80A9
+ SAMPLE_COVERAGE_VALUE = 0x80AA
+ SAMPLE_COVERAGE_INVERT = 0x80AB
+ BLEND_DST_RGB = 0x80C8
+ BLEND_SRC_RGB = 0x80C9
+ BLEND_DST_ALPHA = 0x80CA
+ BLEND_SRC_ALPHA = 0x80CB
+ BGR = 0x80E0
+ BGRA = 0x80E1
+ MAX_ELEMENTS_VERTICES = 0x80E8
+ MAX_ELEMENTS_INDICES = 0x80E9
+ DEPTH_COMPONENT16 = 0x81A5
+ DEPTH_COMPONENT24 = 0x81A6
+ DEPTH_COMPONENT32 = 0x81A7
+ FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING = 0x8210
+ FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE = 0x8211
+ FRAMEBUFFER_ATTACHMENT_RED_SIZE = 0x8212
+ FRAMEBUFFER_ATTACHMENT_GREEN_SIZE = 0x8213
+ FRAMEBUFFER_ATTACHMENT_BLUE_SIZE = 0x8214
+ FRAMEBUFFER_ATTACHMENT_ALPHA_SIZE = 0x8215
+ FRAMEBUFFER_ATTACHMENT_DEPTH_SIZE = 0x8216
+ FRAMEBUFFER_ATTACHMENT_STENCIL_SIZE = 0x8217
+ FRAMEBUFFER_DEFAULT = 0x8218
+ FRAMEBUFFER_UNDEFINED = 0x8219
+ DEPTH_STENCIL_ATTACHMENT = 0x821A
+ MAJOR_VERSION = 0x821B
+ MINOR_VERSION = 0x821C
+ NUM_EXTENSIONS = 0x821D
+ CONTEXT_FLAGS = 0x821E
+ INDEX = 0x8222
+ COMPRESSED_RED = 0x8225
+ COMPRESSED_RG = 0x8226
+ RG = 0x8227
+ RG_INTEGER = 0x8228
+ R8 = 0x8229
+ R16 = 0x822A
+ RG8 = 0x822B
+ RG16 = 0x822C
+ R16F = 0x822D
+ R32F = 0x822E
+ RG16F = 0x822F
+ RG32F = 0x8230
+ R8I = 0x8231
+ R8UI = 0x8232
+ R16I = 0x8233
+ R16UI = 0x8234
+ R32I = 0x8235
+ R32UI = 0x8236
+ RG8I = 0x8237
+ RG8UI = 0x8238
+ RG16I = 0x8239
+ RG16UI = 0x823A
+ RG32I = 0x823B
+ RG32UI = 0x823C
+ PROGRAM_SEPARABLE = 0x8258
+ ACTIVE_PROGRAM = 0x8259
+ PROGRAM_PIPELINE_BINDING = 0x825A
+ MAX_VIEWPORTS = 0x825B
+ VIEWPORT_SUBPIXEL_BITS = 0x825C
+ VIEWPORT_BOUNDS_RANGE = 0x825D
+ LAYER_PROVOKING_VERTEX = 0x825E
+ VIEWPORT_INDEX_PROVOKING_VERTEX = 0x825F
+ UNDEFINED_VERTEX = 0x8260
+ UNSIGNED_BYTE_2_3_3_REV = 0x8362
+ UNSIGNED_SHORT_5_6_5 = 0x8363
+ UNSIGNED_SHORT_5_6_5_REV = 0x8364
+ UNSIGNED_SHORT_4_4_4_4_REV = 0x8365
+ UNSIGNED_SHORT_1_5_5_5_REV = 0x8366
+ UNSIGNED_INT_8_8_8_8_REV = 0x8367
+ UNSIGNED_INT_2_10_10_10_REV = 0x8368
+ MIRRORED_REPEAT = 0x8370
+ FOG_COORDINATE_SOURCE = 0x8450
+ FOG_COORD_SRC = 0x8450
+ FOG_COORDINATE = 0x8451
+ FOG_COORD = 0x8451
+ FRAGMENT_DEPTH = 0x8452
+ CURRENT_FOG_COORDINATE = 0x8453
+ CURRENT_FOG_COORD = 0x8453
+ FOG_COORDINATE_ARRAY_TYPE = 0x8454
+ FOG_COORD_ARRAY_TYPE = 0x8454
+ FOG_COORDINATE_ARRAY_STRIDE = 0x8455
+ FOG_COORD_ARRAY_STRIDE = 0x8455
+ FOG_COORDINATE_ARRAY_POINTER = 0x8456
+ FOG_COORD_ARRAY_POINTER = 0x8456
+ FOG_COORDINATE_ARRAY = 0x8457
+ FOG_COORD_ARRAY = 0x8457
+ COLOR_SUM = 0x8458
+ CURRENT_SECONDARY_COLOR = 0x8459
+ SECONDARY_COLOR_ARRAY_SIZE = 0x845A
+ SECONDARY_COLOR_ARRAY_TYPE = 0x845B
+ SECONDARY_COLOR_ARRAY_STRIDE = 0x845C
+ SECONDARY_COLOR_ARRAY_POINTER = 0x845D
+ SECONDARY_COLOR_ARRAY = 0x845E
+ CURRENT_RASTER_SECONDARY_COLOR = 0x845F
+ TEXTURE0 = 0x84C0
+ TEXTURE1 = 0x84C1
+ TEXTURE2 = 0x84C2
+ TEXTURE3 = 0x84C3
+ TEXTURE4 = 0x84C4
+ TEXTURE5 = 0x84C5
+ TEXTURE6 = 0x84C6
+ TEXTURE7 = 0x84C7
+ TEXTURE8 = 0x84C8
+ TEXTURE9 = 0x84C9
+ TEXTURE10 = 0x84CA
+ TEXTURE11 = 0x84CB
+ TEXTURE12 = 0x84CC
+ TEXTURE13 = 0x84CD
+ TEXTURE14 = 0x84CE
+ TEXTURE15 = 0x84CF
+ TEXTURE16 = 0x84D0
+ TEXTURE17 = 0x84D1
+ TEXTURE18 = 0x84D2
+ TEXTURE19 = 0x84D3
+ TEXTURE20 = 0x84D4
+ TEXTURE21 = 0x84D5
+ TEXTURE22 = 0x84D6
+ TEXTURE23 = 0x84D7
+ TEXTURE24 = 0x84D8
+ TEXTURE25 = 0x84D9
+ TEXTURE26 = 0x84DA
+ TEXTURE27 = 0x84DB
+ TEXTURE28 = 0x84DC
+ TEXTURE29 = 0x84DD
+ TEXTURE30 = 0x84DE
+ TEXTURE31 = 0x84DF
+ ACTIVE_TEXTURE = 0x84E0
+ CLIENT_ACTIVE_TEXTURE = 0x84E1
+ MAX_TEXTURE_UNITS = 0x84E2
+ TRANSPOSE_MODELVIEW_MATRIX = 0x84E3
+ TRANSPOSE_PROJECTION_MATRIX = 0x84E4
+ TRANSPOSE_TEXTURE_MATRIX = 0x84E5
+ TRANSPOSE_COLOR_MATRIX = 0x84E6
+ SUBTRACT = 0x84E7
+ MAX_RENDERBUFFER_SIZE = 0x84E8
+ COMPRESSED_ALPHA = 0x84E9
+ COMPRESSED_LUMINANCE = 0x84EA
+ COMPRESSED_LUMINANCE_ALPHA = 0x84EB
+ COMPRESSED_INTENSITY = 0x84EC
+ COMPRESSED_RGB = 0x84ED
+ COMPRESSED_RGBA = 0x84EE
+ UNIFORM_BLOCK_REFERENCED_BY_TESS_CONTROL_SHADER = 0x84F0
+ UNIFORM_BLOCK_REFERENCED_BY_TESS_EVALUATION_SHADER = 0x84F1
+ TEXTURE_RECTANGLE = 0x84F5
+ TEXTURE_BINDING_RECTANGLE = 0x84F6
+ PROXY_TEXTURE_RECTANGLE = 0x84F7
+ MAX_RECTANGLE_TEXTURE_SIZE = 0x84F8
+ DEPTH_STENCIL = 0x84F9
+ UNSIGNED_INT_24_8 = 0x84FA
+ MAX_TEXTURE_LOD_BIAS = 0x84FD
+ TEXTURE_FILTER_CONTROL = 0x8500
+ TEXTURE_LOD_BIAS = 0x8501
+ INCR_WRAP = 0x8507
+ DECR_WRAP = 0x8508
+ NORMAL_MAP = 0x8511
+ REFLECTION_MAP = 0x8512
+ TEXTURE_CUBE_MAP = 0x8513
+ TEXTURE_BINDING_CUBE_MAP = 0x8514
+ TEXTURE_CUBE_MAP_POSITIVE_X = 0x8515
+ TEXTURE_CUBE_MAP_NEGATIVE_X = 0x8516
+ TEXTURE_CUBE_MAP_POSITIVE_Y = 0x8517
+ TEXTURE_CUBE_MAP_NEGATIVE_Y = 0x8518
+ TEXTURE_CUBE_MAP_POSITIVE_Z = 0x8519
+ TEXTURE_CUBE_MAP_NEGATIVE_Z = 0x851A
+ PROXY_TEXTURE_CUBE_MAP = 0x851B
+ MAX_CUBE_MAP_TEXTURE_SIZE = 0x851C
+ COMBINE = 0x8570
+ COMBINE_RGB = 0x8571
+ COMBINE_ALPHA = 0x8572
+ RGB_SCALE = 0x8573
+ ADD_SIGNED = 0x8574
+ INTERPOLATE = 0x8575
+ CONSTANT = 0x8576
+ PRIMARY_COLOR = 0x8577
+ PREVIOUS = 0x8578
+ SOURCE0_RGB = 0x8580
+ SRC0_RGB = 0x8580
+ SOURCE1_RGB = 0x8581
+ SRC1_RGB = 0x8581
+ SOURCE2_RGB = 0x8582
+ SRC2_RGB = 0x8582
+ SOURCE0_ALPHA = 0x8588
+ SRC0_ALPHA = 0x8588
+ SOURCE1_ALPHA = 0x8589
+ SRC1_ALPHA = 0x8589
+ SOURCE2_ALPHA = 0x858A
+ SRC2_ALPHA = 0x858A
+ OPERAND0_RGB = 0x8590
+ OPERAND1_RGB = 0x8591
+ OPERAND2_RGB = 0x8592
+ OPERAND0_ALPHA = 0x8598
+ OPERAND1_ALPHA = 0x8599
+ OPERAND2_ALPHA = 0x859A
+ VERTEX_ARRAY_BINDING = 0x85B5
+ VERTEX_ATTRIB_ARRAY_ENABLED = 0x8622
+ VERTEX_ATTRIB_ARRAY_SIZE = 0x8623
+ VERTEX_ATTRIB_ARRAY_STRIDE = 0x8624
+ VERTEX_ATTRIB_ARRAY_TYPE = 0x8625
+ CURRENT_VERTEX_ATTRIB = 0x8626
+ VERTEX_PROGRAM_POINT_SIZE = 0x8642
+ PROGRAM_POINT_SIZE = 0x8642
+ VERTEX_PROGRAM_TWO_SIDE = 0x8643
+ VERTEX_ATTRIB_ARRAY_POINTER = 0x8645
+ DEPTH_CLAMP = 0x864F
+ TEXTURE_COMPRESSED_IMAGE_SIZE = 0x86A0
+ TEXTURE_COMPRESSED = 0x86A1
+ NUM_COMPRESSED_TEXTURE_FORMATS = 0x86A2
+ COMPRESSED_TEXTURE_FORMATS = 0x86A3
+ DOT3_RGB = 0x86AE
+ DOT3_RGBA = 0x86AF
+ PROGRAM_BINARY_LENGTH = 0x8741
+ BUFFER_SIZE = 0x8764
+ BUFFER_USAGE = 0x8765
+ NUM_PROGRAM_BINARY_FORMATS = 0x87FE
+ PROGRAM_BINARY_FORMATS = 0x87FF
+ STENCIL_BACK_FUNC = 0x8800
+ STENCIL_BACK_FAIL = 0x8801
+ STENCIL_BACK_PASS_DEPTH_FAIL = 0x8802
+ STENCIL_BACK_PASS_DEPTH_PASS = 0x8803
+ RGBA32F = 0x8814
+ RGB32F = 0x8815
+ RGBA16F = 0x881A
+ RGB16F = 0x881B
+ MAX_DRAW_BUFFERS = 0x8824
+ DRAW_BUFFER0 = 0x8825
+ DRAW_BUFFER1 = 0x8826
+ DRAW_BUFFER2 = 0x8827
+ DRAW_BUFFER3 = 0x8828
+ DRAW_BUFFER4 = 0x8829
+ DRAW_BUFFER5 = 0x882A
+ DRAW_BUFFER6 = 0x882B
+ DRAW_BUFFER7 = 0x882C
+ DRAW_BUFFER8 = 0x882D
+ DRAW_BUFFER9 = 0x882E
+ DRAW_BUFFER10 = 0x882F
+ DRAW_BUFFER11 = 0x8830
+ DRAW_BUFFER12 = 0x8831
+ DRAW_BUFFER13 = 0x8832
+ DRAW_BUFFER14 = 0x8833
+ DRAW_BUFFER15 = 0x8834
+ BLEND_EQUATION_ALPHA = 0x883D
+ TEXTURE_DEPTH_SIZE = 0x884A
+ DEPTH_TEXTURE_MODE = 0x884B
+ TEXTURE_COMPARE_MODE = 0x884C
+ TEXTURE_COMPARE_FUNC = 0x884D
+ COMPARE_R_TO_TEXTURE = 0x884E
+ COMPARE_REF_TO_TEXTURE = 0x884E
+ TEXTURE_CUBE_MAP_SEAMLESS = 0x884F
+ POINT_SPRITE = 0x8861
+ COORD_REPLACE = 0x8862
+ QUERY_COUNTER_BITS = 0x8864
+ CURRENT_QUERY = 0x8865
+ QUERY_RESULT = 0x8866
+ QUERY_RESULT_AVAILABLE = 0x8867
+ MAX_VERTEX_ATTRIBS = 0x8869
+ VERTEX_ATTRIB_ARRAY_NORMALIZED = 0x886A
+ MAX_TESS_CONTROL_INPUT_COMPONENTS = 0x886C
+ MAX_TESS_EVALUATION_INPUT_COMPONENTS = 0x886D
+ MAX_TEXTURE_COORDS = 0x8871
+ MAX_TEXTURE_IMAGE_UNITS = 0x8872
+ GEOMETRY_SHADER_INVOCATIONS = 0x887F
+ ARRAY_BUFFER = 0x8892
+ ELEMENT_ARRAY_BUFFER = 0x8893
+ ARRAY_BUFFER_BINDING = 0x8894
+ ELEMENT_ARRAY_BUFFER_BINDING = 0x8895
+ VERTEX_ARRAY_BUFFER_BINDING = 0x8896
+ NORMAL_ARRAY_BUFFER_BINDING = 0x8897
+ COLOR_ARRAY_BUFFER_BINDING = 0x8898
+ INDEX_ARRAY_BUFFER_BINDING = 0x8899
+ TEXTURE_COORD_ARRAY_BUFFER_BINDING = 0x889A
+ EDGE_FLAG_ARRAY_BUFFER_BINDING = 0x889B
+ SECONDARY_COLOR_ARRAY_BUFFER_BINDING = 0x889C
+ FOG_COORDINATE_ARRAY_BUFFER_BINDING = 0x889D
+ FOG_COORD_ARRAY_BUFFER_BINDING = 0x889D
+ WEIGHT_ARRAY_BUFFER_BINDING = 0x889E
+ VERTEX_ATTRIB_ARRAY_BUFFER_BINDING = 0x889F
+ READ_ONLY = 0x88B8
+ WRITE_ONLY = 0x88B9
+ READ_WRITE = 0x88BA
+ BUFFER_ACCESS = 0x88BB
+ BUFFER_MAPPED = 0x88BC
+ BUFFER_MAP_POINTER = 0x88BD
+ TIME_ELAPSED = 0x88BF
+ STREAM_DRAW = 0x88E0
+ STREAM_READ = 0x88E1
+ STREAM_COPY = 0x88E2
+ STATIC_DRAW = 0x88E4
+ STATIC_READ = 0x88E5
+ STATIC_COPY = 0x88E6
+ DYNAMIC_DRAW = 0x88E8
+ DYNAMIC_READ = 0x88E9
+ DYNAMIC_COPY = 0x88EA
+ PIXEL_PACK_BUFFER = 0x88EB
+ PIXEL_UNPACK_BUFFER = 0x88EC
+ PIXEL_PACK_BUFFER_BINDING = 0x88ED
+ PIXEL_UNPACK_BUFFER_BINDING = 0x88EF
+ DEPTH24_STENCIL8 = 0x88F0
+ TEXTURE_STENCIL_SIZE = 0x88F1
+ SRC1_COLOR = 0x88F9
+ ONE_MINUS_SRC1_COLOR = 0x88FA
+ ONE_MINUS_SRC1_ALPHA = 0x88FB
+ MAX_DUAL_SOURCE_DRAW_BUFFERS = 0x88FC
+ VERTEX_ATTRIB_ARRAY_INTEGER = 0x88FD
+ VERTEX_ATTRIB_ARRAY_DIVISOR = 0x88FE
+ MAX_ARRAY_TEXTURE_LAYERS = 0x88FF
+ MIN_PROGRAM_TEXEL_OFFSET = 0x8904
+ MAX_PROGRAM_TEXEL_OFFSET = 0x8905
+ SAMPLES_PASSED = 0x8914
+ GEOMETRY_VERTICES_OUT = 0x8916
+ GEOMETRY_INPUT_TYPE = 0x8917
+ GEOMETRY_OUTPUT_TYPE = 0x8918
+ SAMPLER_BINDING = 0x8919
+ CLAMP_VERTEX_COLOR = 0x891A
+ CLAMP_FRAGMENT_COLOR = 0x891B
+ CLAMP_READ_COLOR = 0x891C
+ FIXED_ONLY = 0x891D
+ UNIFORM_BUFFER = 0x8A11
+ UNIFORM_BUFFER_BINDING = 0x8A28
+ UNIFORM_BUFFER_START = 0x8A29
+ UNIFORM_BUFFER_SIZE = 0x8A2A
+ MAX_VERTEX_UNIFORM_BLOCKS = 0x8A2B
+ MAX_GEOMETRY_UNIFORM_BLOCKS = 0x8A2C
+ MAX_FRAGMENT_UNIFORM_BLOCKS = 0x8A2D
+ MAX_COMBINED_UNIFORM_BLOCKS = 0x8A2E
+ MAX_UNIFORM_BUFFER_BINDINGS = 0x8A2F
+ MAX_UNIFORM_BLOCK_SIZE = 0x8A30
+ MAX_COMBINED_VERTEX_UNIFORM_COMPONENTS = 0x8A31
+ MAX_COMBINED_GEOMETRY_UNIFORM_COMPONENTS = 0x8A32
+ MAX_COMBINED_FRAGMENT_UNIFORM_COMPONENTS = 0x8A33
+ UNIFORM_BUFFER_OFFSET_ALIGNMENT = 0x8A34
+ ACTIVE_UNIFORM_BLOCK_MAX_NAME_LENGTH = 0x8A35
+ ACTIVE_UNIFORM_BLOCKS = 0x8A36
+ UNIFORM_TYPE = 0x8A37
+ UNIFORM_SIZE = 0x8A38
+ UNIFORM_NAME_LENGTH = 0x8A39
+ UNIFORM_BLOCK_INDEX = 0x8A3A
+ UNIFORM_OFFSET = 0x8A3B
+ UNIFORM_ARRAY_STRIDE = 0x8A3C
+ UNIFORM_MATRIX_STRIDE = 0x8A3D
+ UNIFORM_IS_ROW_MAJOR = 0x8A3E
+ UNIFORM_BLOCK_BINDING = 0x8A3F
+ UNIFORM_BLOCK_DATA_SIZE = 0x8A40
+ UNIFORM_BLOCK_NAME_LENGTH = 0x8A41
+ UNIFORM_BLOCK_ACTIVE_UNIFORMS = 0x8A42
+ UNIFORM_BLOCK_ACTIVE_UNIFORM_INDICES = 0x8A43
+ UNIFORM_BLOCK_REFERENCED_BY_VERTEX_SHADER = 0x8A44
+ UNIFORM_BLOCK_REFERENCED_BY_GEOMETRY_SHADER = 0x8A45
+ UNIFORM_BLOCK_REFERENCED_BY_FRAGMENT_SHADER = 0x8A46
+ FRAGMENT_SHADER = 0x8B30
+ VERTEX_SHADER = 0x8B31
+ MAX_FRAGMENT_UNIFORM_COMPONENTS = 0x8B49
+ MAX_VERTEX_UNIFORM_COMPONENTS = 0x8B4A
+ MAX_VARYING_FLOATS = 0x8B4B
+ MAX_VARYING_COMPONENTS = 0x8B4B
+ MAX_VERTEX_TEXTURE_IMAGE_UNITS = 0x8B4C
+ MAX_COMBINED_TEXTURE_IMAGE_UNITS = 0x8B4D
+ SHADER_TYPE = 0x8B4F
+ FLOAT_VEC2 = 0x8B50
+ FLOAT_VEC3 = 0x8B51
+ FLOAT_VEC4 = 0x8B52
+ INT_VEC2 = 0x8B53
+ INT_VEC3 = 0x8B54
+ INT_VEC4 = 0x8B55
+ BOOL = 0x8B56
+ BOOL_VEC2 = 0x8B57
+ BOOL_VEC3 = 0x8B58
+ BOOL_VEC4 = 0x8B59
+ FLOAT_MAT2 = 0x8B5A
+ FLOAT_MAT3 = 0x8B5B
+ FLOAT_MAT4 = 0x8B5C
+ SAMPLER_1D = 0x8B5D
+ SAMPLER_2D = 0x8B5E
+ SAMPLER_3D = 0x8B5F
+ SAMPLER_CUBE = 0x8B60
+ SAMPLER_1D_SHADOW = 0x8B61
+ SAMPLER_2D_SHADOW = 0x8B62
+ SAMPLER_2D_RECT = 0x8B63
+ SAMPLER_2D_RECT_SHADOW = 0x8B64
+ FLOAT_MAT2x3 = 0x8B65
+ FLOAT_MAT2x4 = 0x8B66
+ FLOAT_MAT3x2 = 0x8B67
+ FLOAT_MAT3x4 = 0x8B68
+ FLOAT_MAT4x2 = 0x8B69
+ FLOAT_MAT4x3 = 0x8B6A
+ DELETE_STATUS = 0x8B80
+ COMPILE_STATUS = 0x8B81
+ LINK_STATUS = 0x8B82
+ VALIDATE_STATUS = 0x8B83
+ INFO_LOG_LENGTH = 0x8B84
+ ATTACHED_SHADERS = 0x8B85
+ ACTIVE_UNIFORMS = 0x8B86
+ ACTIVE_UNIFORM_MAX_LENGTH = 0x8B87
+ SHADER_SOURCE_LENGTH = 0x8B88
+ ACTIVE_ATTRIBUTES = 0x8B89
+ ACTIVE_ATTRIBUTE_MAX_LENGTH = 0x8B8A
+ SHADING_LANGUAGE_VERSION = 0x8B8C
+ CURRENT_PROGRAM = 0x8B8D
+ IMPLEMENTATION_COLOR_READ_TYPE = 0x8B9A
+ IMPLEMENTATION_COLOR_READ_FORMAT = 0x8B9B
+ TEXTURE_RED_TYPE = 0x8C10
+ TEXTURE_GREEN_TYPE = 0x8C11
+ TEXTURE_BLUE_TYPE = 0x8C12
+ TEXTURE_ALPHA_TYPE = 0x8C13
+ TEXTURE_LUMINANCE_TYPE = 0x8C14
+ TEXTURE_INTENSITY_TYPE = 0x8C15
+ TEXTURE_DEPTH_TYPE = 0x8C16
+ UNSIGNED_NORMALIZED = 0x8C17
+ TEXTURE_1D_ARRAY = 0x8C18
+ PROXY_TEXTURE_1D_ARRAY = 0x8C19
+ TEXTURE_2D_ARRAY = 0x8C1A
+ PROXY_TEXTURE_2D_ARRAY = 0x8C1B
+ TEXTURE_BINDING_1D_ARRAY = 0x8C1C
+ TEXTURE_BINDING_2D_ARRAY = 0x8C1D
+ MAX_GEOMETRY_TEXTURE_IMAGE_UNITS = 0x8C29
+ TEXTURE_BUFFER = 0x8C2A
+ MAX_TEXTURE_BUFFER_SIZE = 0x8C2B
+ TEXTURE_BINDING_BUFFER = 0x8C2C
+ TEXTURE_BUFFER_DATA_STORE_BINDING = 0x8C2D
+ ANY_SAMPLES_PASSED = 0x8C2F
+ SAMPLE_SHADING = 0x8C36
+ MIN_SAMPLE_SHADING_VALUE = 0x8C37
+ R11F_G11F_B10F = 0x8C3A
+ UNSIGNED_INT_10F_11F_11F_REV = 0x8C3B
+ RGB9_E5 = 0x8C3D
+ UNSIGNED_INT_5_9_9_9_REV = 0x8C3E
+ TEXTURE_SHARED_SIZE = 0x8C3F
+ SRGB = 0x8C40
+ SRGB8 = 0x8C41
+ SRGB_ALPHA = 0x8C42
+ SRGB8_ALPHA8 = 0x8C43
+ SLUMINANCE_ALPHA = 0x8C44
+ SLUMINANCE8_ALPHA8 = 0x8C45
+ SLUMINANCE = 0x8C46
+ SLUMINANCE8 = 0x8C47
+ COMPRESSED_SRGB = 0x8C48
+ COMPRESSED_SRGB_ALPHA = 0x8C49
+ COMPRESSED_SLUMINANCE = 0x8C4A
+ COMPRESSED_SLUMINANCE_ALPHA = 0x8C4B
+ TRANSFORM_FEEDBACK_VARYING_MAX_LENGTH = 0x8C76
+ TRANSFORM_FEEDBACK_BUFFER_MODE = 0x8C7F
+ MAX_TRANSFORM_FEEDBACK_SEPARATE_COMPONENTS = 0x8C80
+ TRANSFORM_FEEDBACK_VARYINGS = 0x8C83
+ TRANSFORM_FEEDBACK_BUFFER_START = 0x8C84
+ TRANSFORM_FEEDBACK_BUFFER_SIZE = 0x8C85
+ PRIMITIVES_GENERATED = 0x8C87
+ TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN = 0x8C88
+ RASTERIZER_DISCARD = 0x8C89
+ MAX_TRANSFORM_FEEDBACK_INTERLEAVED_COMPONENTS = 0x8C8A
+ MAX_TRANSFORM_FEEDBACK_SEPARATE_ATTRIBS = 0x8C8B
+ INTERLEAVED_ATTRIBS = 0x8C8C
+ SEPARATE_ATTRIBS = 0x8C8D
+ TRANSFORM_FEEDBACK_BUFFER = 0x8C8E
+ TRANSFORM_FEEDBACK_BUFFER_BINDING = 0x8C8F
+ POINT_SPRITE_COORD_ORIGIN = 0x8CA0
+ LOWER_LEFT = 0x8CA1
+ UPPER_LEFT = 0x8CA2
+ STENCIL_BACK_REF = 0x8CA3
+ STENCIL_BACK_VALUE_MASK = 0x8CA4
+ STENCIL_BACK_WRITEMASK = 0x8CA5
+ DRAW_FRAMEBUFFER_BINDING = 0x8CA6
+ FRAMEBUFFER_BINDING = 0x8CA6
+ RENDERBUFFER_BINDING = 0x8CA7
+ READ_FRAMEBUFFER = 0x8CA8
+ DRAW_FRAMEBUFFER = 0x8CA9
+ READ_FRAMEBUFFER_BINDING = 0x8CAA
+ RENDERBUFFER_SAMPLES = 0x8CAB
+ DEPTH_COMPONENT32F = 0x8CAC
+ DEPTH32F_STENCIL8 = 0x8CAD
+ FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE = 0x8CD0
+ FRAMEBUFFER_ATTACHMENT_OBJECT_NAME = 0x8CD1
+ FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL = 0x8CD2
+ FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE = 0x8CD3
+ FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER = 0x8CD4
+ FRAMEBUFFER_COMPLETE = 0x8CD5
+ FRAMEBUFFER_INCOMPLETE_ATTACHMENT = 0x8CD6
+ FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT = 0x8CD7
+ FRAMEBUFFER_INCOMPLETE_DRAW_BUFFER = 0x8CDB
+ FRAMEBUFFER_INCOMPLETE_READ_BUFFER = 0x8CDC
+ FRAMEBUFFER_UNSUPPORTED = 0x8CDD
+ MAX_COLOR_ATTACHMENTS = 0x8CDF
+ COLOR_ATTACHMENT0 = 0x8CE0
+ COLOR_ATTACHMENT1 = 0x8CE1
+ COLOR_ATTACHMENT2 = 0x8CE2
+ COLOR_ATTACHMENT3 = 0x8CE3
+ COLOR_ATTACHMENT4 = 0x8CE4
+ COLOR_ATTACHMENT5 = 0x8CE5
+ COLOR_ATTACHMENT6 = 0x8CE6
+ COLOR_ATTACHMENT7 = 0x8CE7
+ COLOR_ATTACHMENT8 = 0x8CE8
+ COLOR_ATTACHMENT9 = 0x8CE9
+ COLOR_ATTACHMENT10 = 0x8CEA
+ COLOR_ATTACHMENT11 = 0x8CEB
+ COLOR_ATTACHMENT12 = 0x8CEC
+ COLOR_ATTACHMENT13 = 0x8CED
+ COLOR_ATTACHMENT14 = 0x8CEE
+ COLOR_ATTACHMENT15 = 0x8CEF
+ DEPTH_ATTACHMENT = 0x8D00
+ STENCIL_ATTACHMENT = 0x8D20
+ FRAMEBUFFER = 0x8D40
+ RENDERBUFFER = 0x8D41
+ RENDERBUFFER_WIDTH = 0x8D42
+ RENDERBUFFER_HEIGHT = 0x8D43
+ RENDERBUFFER_INTERNAL_FORMAT = 0x8D44
+ STENCIL_INDEX1 = 0x8D46
+ STENCIL_INDEX4 = 0x8D47
+ STENCIL_INDEX8 = 0x8D48
+ STENCIL_INDEX16 = 0x8D49
+ RENDERBUFFER_RED_SIZE = 0x8D50
+ RENDERBUFFER_GREEN_SIZE = 0x8D51
+ RENDERBUFFER_BLUE_SIZE = 0x8D52
+ RENDERBUFFER_ALPHA_SIZE = 0x8D53
+ RENDERBUFFER_DEPTH_SIZE = 0x8D54
+ RENDERBUFFER_STENCIL_SIZE = 0x8D55
+ FRAMEBUFFER_INCOMPLETE_MULTISAMPLE = 0x8D56
+ MAX_SAMPLES = 0x8D57
+ RGB565 = 0x8D62
+ RGBA32UI = 0x8D70
+ RGB32UI = 0x8D71
+ RGBA16UI = 0x8D76
+ RGB16UI = 0x8D77
+ RGBA8UI = 0x8D7C
+ RGB8UI = 0x8D7D
+ RGBA32I = 0x8D82
+ RGB32I = 0x8D83
+ RGBA16I = 0x8D88
+ RGB16I = 0x8D89
+ RGBA8I = 0x8D8E
+ RGB8I = 0x8D8F
+ RED_INTEGER = 0x8D94
+ GREEN_INTEGER = 0x8D95
+ BLUE_INTEGER = 0x8D96
+ ALPHA_INTEGER = 0x8D97
+ RGB_INTEGER = 0x8D98
+ RGBA_INTEGER = 0x8D99
+ BGR_INTEGER = 0x8D9A
+ BGRA_INTEGER = 0x8D9B
+ INT_2_10_10_10_REV = 0x8D9F
+ FRAMEBUFFER_ATTACHMENT_LAYERED = 0x8DA7
+ FRAMEBUFFER_INCOMPLETE_LAYER_TARGETS = 0x8DA8
+ FLOAT_32_UNSIGNED_INT_24_8_REV = 0x8DAD
+ FRAMEBUFFER_SRGB = 0x8DB9
+ COMPRESSED_RED_RGTC1 = 0x8DBB
+ COMPRESSED_SIGNED_RED_RGTC1 = 0x8DBC
+ COMPRESSED_RG_RGTC2 = 0x8DBD
+ COMPRESSED_SIGNED_RG_RGTC2 = 0x8DBE
+ SAMPLER_1D_ARRAY = 0x8DC0
+ SAMPLER_2D_ARRAY = 0x8DC1
+ SAMPLER_BUFFER = 0x8DC2
+ SAMPLER_1D_ARRAY_SHADOW = 0x8DC3
+ SAMPLER_2D_ARRAY_SHADOW = 0x8DC4
+ SAMPLER_CUBE_SHADOW = 0x8DC5
+ UNSIGNED_INT_VEC2 = 0x8DC6
+ UNSIGNED_INT_VEC3 = 0x8DC7
+ UNSIGNED_INT_VEC4 = 0x8DC8
+ INT_SAMPLER_1D = 0x8DC9
+ INT_SAMPLER_2D = 0x8DCA
+ INT_SAMPLER_3D = 0x8DCB
+ INT_SAMPLER_CUBE = 0x8DCC
+ INT_SAMPLER_2D_RECT = 0x8DCD
+ INT_SAMPLER_1D_ARRAY = 0x8DCE
+ INT_SAMPLER_2D_ARRAY = 0x8DCF
+ INT_SAMPLER_BUFFER = 0x8DD0
+ UNSIGNED_INT_SAMPLER_1D = 0x8DD1
+ UNSIGNED_INT_SAMPLER_2D = 0x8DD2
+ UNSIGNED_INT_SAMPLER_3D = 0x8DD3
+ UNSIGNED_INT_SAMPLER_CUBE = 0x8DD4
+ UNSIGNED_INT_SAMPLER_2D_RECT = 0x8DD5
+ UNSIGNED_INT_SAMPLER_1D_ARRAY = 0x8DD6
+ UNSIGNED_INT_SAMPLER_2D_ARRAY = 0x8DD7
+ UNSIGNED_INT_SAMPLER_BUFFER = 0x8DD8
+ GEOMETRY_SHADER = 0x8DD9
+ MAX_GEOMETRY_UNIFORM_COMPONENTS = 0x8DDF
+ MAX_GEOMETRY_OUTPUT_VERTICES = 0x8DE0
+ MAX_GEOMETRY_TOTAL_OUTPUT_COMPONENTS = 0x8DE1
+ ACTIVE_SUBROUTINES = 0x8DE5
+ ACTIVE_SUBROUTINE_UNIFORMS = 0x8DE6
+ MAX_SUBROUTINES = 0x8DE7
+ MAX_SUBROUTINE_UNIFORM_LOCATIONS = 0x8DE8
+ LOW_FLOAT = 0x8DF0
+ MEDIUM_FLOAT = 0x8DF1
+ HIGH_FLOAT = 0x8DF2
+ LOW_INT = 0x8DF3
+ MEDIUM_INT = 0x8DF4
+ HIGH_INT = 0x8DF5
+ SHADER_BINARY_FORMATS = 0x8DF8
+ NUM_SHADER_BINARY_FORMATS = 0x8DF9
+ SHADER_COMPILER = 0x8DFA
+ MAX_VERTEX_UNIFORM_VECTORS = 0x8DFB
+ MAX_VARYING_VECTORS = 0x8DFC
+ MAX_FRAGMENT_UNIFORM_VECTORS = 0x8DFD
+ QUERY_WAIT = 0x8E13
+ QUERY_NO_WAIT = 0x8E14
+ QUERY_BY_REGION_WAIT = 0x8E15
+ QUERY_BY_REGION_NO_WAIT = 0x8E16
+ MAX_COMBINED_TESS_CONTROL_UNIFORM_COMPONENTS = 0x8E1E
+ MAX_COMBINED_TESS_EVALUATION_UNIFORM_COMPONENTS = 0x8E1F
+ TRANSFORM_FEEDBACK = 0x8E22
+ TRANSFORM_FEEDBACK_BUFFER_PAUSED = 0x8E23
+ TRANSFORM_FEEDBACK_BUFFER_ACTIVE = 0x8E24
+ TRANSFORM_FEEDBACK_BINDING = 0x8E25
+ TIMESTAMP = 0x8E28
+ TEXTURE_SWIZZLE_R = 0x8E42
+ TEXTURE_SWIZZLE_G = 0x8E43
+ TEXTURE_SWIZZLE_B = 0x8E44
+ TEXTURE_SWIZZLE_A = 0x8E45
+ TEXTURE_SWIZZLE_RGBA = 0x8E46
+ ACTIVE_SUBROUTINE_UNIFORM_LOCATIONS = 0x8E47
+ ACTIVE_SUBROUTINE_MAX_LENGTH = 0x8E48
+ ACTIVE_SUBROUTINE_UNIFORM_MAX_LENGTH = 0x8E49
+ NUM_COMPATIBLE_SUBROUTINES = 0x8E4A
+ COMPATIBLE_SUBROUTINES = 0x8E4B
+ QUADS_FOLLOW_PROVOKING_VERTEX_CONVENTION = 0x8E4C
+ FIRST_VERTEX_CONVENTION = 0x8E4D
+ LAST_VERTEX_CONVENTION = 0x8E4E
+ PROVOKING_VERTEX = 0x8E4F
+ SAMPLE_POSITION = 0x8E50
+ SAMPLE_MASK = 0x8E51
+ SAMPLE_MASK_VALUE = 0x8E52
+ MAX_SAMPLE_MASK_WORDS = 0x8E59
+ MAX_GEOMETRY_SHADER_INVOCATIONS = 0x8E5A
+ MIN_FRAGMENT_INTERPOLATION_OFFSET = 0x8E5B
+ MAX_FRAGMENT_INTERPOLATION_OFFSET = 0x8E5C
+ FRAGMENT_INTERPOLATION_OFFSET_BITS = 0x8E5D
+ MIN_PROGRAM_TEXTURE_GATHER_OFFSET = 0x8E5E
+ MAX_PROGRAM_TEXTURE_GATHER_OFFSET = 0x8E5F
+ MAX_TRANSFORM_FEEDBACK_BUFFERS = 0x8E70
+ MAX_VERTEX_STREAMS = 0x8E71
+ PATCH_VERTICES = 0x8E72
+ PATCH_DEFAULT_INNER_LEVEL = 0x8E73
+ PATCH_DEFAULT_OUTER_LEVEL = 0x8E74
+ TESS_CONTROL_OUTPUT_VERTICES = 0x8E75
+ TESS_GEN_MODE = 0x8E76
+ TESS_GEN_SPACING = 0x8E77
+ TESS_GEN_VERTEX_ORDER = 0x8E78
+ TESS_GEN_POINT_MODE = 0x8E79
+ ISOLINES = 0x8E7A
+ FRACTIONAL_ODD = 0x8E7B
+ FRACTIONAL_EVEN = 0x8E7C
+ MAX_PATCH_VERTICES = 0x8E7D
+ MAX_TESS_GEN_LEVEL = 0x8E7E
+ MAX_TESS_CONTROL_UNIFORM_COMPONENTS = 0x8E7F
+ MAX_TESS_EVALUATION_UNIFORM_COMPONENTS = 0x8E80
+ MAX_TESS_CONTROL_TEXTURE_IMAGE_UNITS = 0x8E81
+ MAX_TESS_EVALUATION_TEXTURE_IMAGE_UNITS = 0x8E82
+ MAX_TESS_CONTROL_OUTPUT_COMPONENTS = 0x8E83
+ MAX_TESS_PATCH_COMPONENTS = 0x8E84
+ MAX_TESS_CONTROL_TOTAL_OUTPUT_COMPONENTS = 0x8E85
+ MAX_TESS_EVALUATION_OUTPUT_COMPONENTS = 0x8E86
+ TESS_EVALUATION_SHADER = 0x8E87
+ TESS_CONTROL_SHADER = 0x8E88
+ MAX_TESS_CONTROL_UNIFORM_BLOCKS = 0x8E89
+ MAX_TESS_EVALUATION_UNIFORM_BLOCKS = 0x8E8A
+ COMPRESSED_RGBA_BPTC_UNORM = 0x8E8C
+ COMPRESSED_SRGB_ALPHA_BPTC_UNORM = 0x8E8D
+ COMPRESSED_RGB_BPTC_SIGNED_FLOAT = 0x8E8E
+ COMPRESSED_RGB_BPTC_UNSIGNED_FLOAT = 0x8E8F
+ COPY_READ_BUFFER = 0x8F36
+ COPY_WRITE_BUFFER = 0x8F37
+ MAX_IMAGE_UNITS = 0x8F38
+ MAX_COMBINED_IMAGE_UNITS_AND_FRAGMENT_OUTPUTS = 0x8F39
+ IMAGE_BINDING_NAME = 0x8F3A
+ IMAGE_BINDING_LEVEL = 0x8F3B
+ IMAGE_BINDING_LAYERED = 0x8F3C
+ IMAGE_BINDING_LAYER = 0x8F3D
+ IMAGE_BINDING_ACCESS = 0x8F3E
+ DRAW_INDIRECT_BUFFER = 0x8F3F
+ DRAW_INDIRECT_BUFFER_BINDING = 0x8F43
+ DOUBLE_MAT2 = 0x8F46
+ DOUBLE_MAT3 = 0x8F47
+ DOUBLE_MAT4 = 0x8F48
+ DOUBLE_MAT2x3 = 0x8F49
+ DOUBLE_MAT2x4 = 0x8F4A
+ DOUBLE_MAT3x2 = 0x8F4B
+ DOUBLE_MAT3x4 = 0x8F4C
+ DOUBLE_MAT4x2 = 0x8F4D
+ DOUBLE_MAT4x3 = 0x8F4E
+ R8_SNORM = 0x8F94
+ RG8_SNORM = 0x8F95
+ RGB8_SNORM = 0x8F96
+ RGBA8_SNORM = 0x8F97
+ R16_SNORM = 0x8F98
+ RG16_SNORM = 0x8F99
+ RGB16_SNORM = 0x8F9A
+ RGBA16_SNORM = 0x8F9B
+ SIGNED_NORMALIZED = 0x8F9C
+ PRIMITIVE_RESTART = 0x8F9D
+ PRIMITIVE_RESTART_INDEX = 0x8F9E
+ DOUBLE_VEC2 = 0x8FFC
+ DOUBLE_VEC3 = 0x8FFD
+ DOUBLE_VEC4 = 0x8FFE
+ TEXTURE_CUBE_MAP_ARRAY = 0x9009
+ TEXTURE_BINDING_CUBE_MAP_ARRAY = 0x900A
+ PROXY_TEXTURE_CUBE_MAP_ARRAY = 0x900B
+ SAMPLER_CUBE_MAP_ARRAY = 0x900C
+ SAMPLER_CUBE_MAP_ARRAY_SHADOW = 0x900D
+ INT_SAMPLER_CUBE_MAP_ARRAY = 0x900E
+ UNSIGNED_INT_SAMPLER_CUBE_MAP_ARRAY = 0x900F
+ IMAGE_1D = 0x904C
+ IMAGE_2D = 0x904D
+ IMAGE_3D = 0x904E
+ IMAGE_2D_RECT = 0x904F
+ IMAGE_CUBE = 0x9050
+ IMAGE_BUFFER = 0x9051
+ IMAGE_1D_ARRAY = 0x9052
+ IMAGE_2D_ARRAY = 0x9053
+ IMAGE_CUBE_MAP_ARRAY = 0x9054
+ IMAGE_2D_MULTISAMPLE = 0x9055
+ IMAGE_2D_MULTISAMPLE_ARRAY = 0x9056
+ INT_IMAGE_1D = 0x9057
+ INT_IMAGE_2D = 0x9058
+ INT_IMAGE_3D = 0x9059
+ INT_IMAGE_2D_RECT = 0x905A
+ INT_IMAGE_CUBE = 0x905B
+ INT_IMAGE_BUFFER = 0x905C
+ INT_IMAGE_1D_ARRAY = 0x905D
+ INT_IMAGE_2D_ARRAY = 0x905E
+ INT_IMAGE_CUBE_MAP_ARRAY = 0x905F
+ INT_IMAGE_2D_MULTISAMPLE = 0x9060
+ INT_IMAGE_2D_MULTISAMPLE_ARRAY = 0x9061
+ UNSIGNED_INT_IMAGE_1D = 0x9062
+ UNSIGNED_INT_IMAGE_2D = 0x9063
+ UNSIGNED_INT_IMAGE_3D = 0x9064
+ UNSIGNED_INT_IMAGE_2D_RECT = 0x9065
+ UNSIGNED_INT_IMAGE_CUBE = 0x9066
+ UNSIGNED_INT_IMAGE_BUFFER = 0x9067
+ UNSIGNED_INT_IMAGE_1D_ARRAY = 0x9068
+ UNSIGNED_INT_IMAGE_2D_ARRAY = 0x9069
+ UNSIGNED_INT_IMAGE_CUBE_MAP_ARRAY = 0x906A
+ UNSIGNED_INT_IMAGE_2D_MULTISAMPLE = 0x906B
+ UNSIGNED_INT_IMAGE_2D_MULTISAMPLE_ARRAY = 0x906C
+ MAX_IMAGE_SAMPLES = 0x906D
+ IMAGE_BINDING_FORMAT = 0x906E
+ RGB10_A2UI = 0x906F
+ MIN_MAP_BUFFER_ALIGNMENT = 0x90BC
+ IMAGE_FORMAT_COMPATIBILITY_TYPE = 0x90C7
+ IMAGE_FORMAT_COMPATIBILITY_BY_SIZE = 0x90C8
+ IMAGE_FORMAT_COMPATIBILITY_BY_CLASS = 0x90C9
+ MAX_VERTEX_IMAGE_UNIFORMS = 0x90CA
+ MAX_TESS_CONTROL_IMAGE_UNIFORMS = 0x90CB
+ MAX_TESS_EVALUATION_IMAGE_UNIFORMS = 0x90CC
+ MAX_GEOMETRY_IMAGE_UNIFORMS = 0x90CD
+ MAX_FRAGMENT_IMAGE_UNIFORMS = 0x90CE
+ MAX_COMBINED_IMAGE_UNIFORMS = 0x90CF
+ TEXTURE_2D_MULTISAMPLE = 0x9100
+ PROXY_TEXTURE_2D_MULTISAMPLE = 0x9101
+ TEXTURE_2D_MULTISAMPLE_ARRAY = 0x9102
+ PROXY_TEXTURE_2D_MULTISAMPLE_ARRAY = 0x9103
+ TEXTURE_BINDING_2D_MULTISAMPLE = 0x9104
+ TEXTURE_BINDING_2D_MULTISAMPLE_ARRAY = 0x9105
+ TEXTURE_SAMPLES = 0x9106
+ TEXTURE_FIXED_SAMPLE_LOCATIONS = 0x9107
+ SAMPLER_2D_MULTISAMPLE = 0x9108
+ INT_SAMPLER_2D_MULTISAMPLE = 0x9109
+ UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE = 0x910A
+ SAMPLER_2D_MULTISAMPLE_ARRAY = 0x910B
+ INT_SAMPLER_2D_MULTISAMPLE_ARRAY = 0x910C
+ UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE_ARRAY = 0x910D
+ MAX_COLOR_TEXTURE_SAMPLES = 0x910E
+ MAX_DEPTH_TEXTURE_SAMPLES = 0x910F
+ MAX_INTEGER_SAMPLES = 0x9110
+ MAX_SERVER_WAIT_TIMEOUT = 0x9111
+ OBJECT_TYPE = 0x9112
+ SYNC_CONDITION = 0x9113
+ SYNC_STATUS = 0x9114
+ SYNC_FLAGS = 0x9115
+ SYNC_FENCE = 0x9116
+ SYNC_GPU_COMMANDS_COMPLETE = 0x9117
+ UNSIGNALED = 0x9118
+ SIGNALED = 0x9119
+ ALREADY_SIGNALED = 0x911A
+ TIMEOUT_EXPIRED = 0x911B
+ CONDITION_SATISFIED = 0x911C
+ WAIT_FAILED = 0x911D
+ BUFFER_ACCESS_FLAGS = 0x911F
+ BUFFER_MAP_LENGTH = 0x9120
+ BUFFER_MAP_OFFSET = 0x9121
+ MAX_VERTEX_OUTPUT_COMPONENTS = 0x9122
+ MAX_GEOMETRY_INPUT_COMPONENTS = 0x9123
+ MAX_GEOMETRY_OUTPUT_COMPONENTS = 0x9124
+ MAX_FRAGMENT_INPUT_COMPONENTS = 0x9125
+ CONTEXT_PROFILE_MASK = 0x9126
+ UNPACK_COMPRESSED_BLOCK_WIDTH = 0x9127
+ UNPACK_COMPRESSED_BLOCK_HEIGHT = 0x9128
+ UNPACK_COMPRESSED_BLOCK_DEPTH = 0x9129
+ UNPACK_COMPRESSED_BLOCK_SIZE = 0x912A
+ PACK_COMPRESSED_BLOCK_WIDTH = 0x912B
+ PACK_COMPRESSED_BLOCK_HEIGHT = 0x912C
+ PACK_COMPRESSED_BLOCK_DEPTH = 0x912D
+ PACK_COMPRESSED_BLOCK_SIZE = 0x912E
+ TEXTURE_IMMUTABLE_FORMAT = 0x912F
+ ATOMIC_COUNTER_BUFFER = 0x92C0
+ ATOMIC_COUNTER_BUFFER_BINDING = 0x92C1
+ ATOMIC_COUNTER_BUFFER_START = 0x92C2
+ ATOMIC_COUNTER_BUFFER_SIZE = 0x92C3
+ ATOMIC_COUNTER_BUFFER_DATA_SIZE = 0x92C4
+ ATOMIC_COUNTER_BUFFER_ACTIVE_ATOMIC_COUNTERS = 0x92C5
+ ATOMIC_COUNTER_BUFFER_ACTIVE_ATOMIC_COUNTER_INDICES = 0x92C6
+ ATOMIC_COUNTER_BUFFER_REFERENCED_BY_VERTEX_SHADER = 0x92C7
+ ATOMIC_COUNTER_BUFFER_REFERENCED_BY_TESS_CONTROL_SHADER = 0x92C8
+ ATOMIC_COUNTER_BUFFER_REFERENCED_BY_TESS_EVALUATION_SHADER = 0x92C9
+ ATOMIC_COUNTER_BUFFER_REFERENCED_BY_GEOMETRY_SHADER = 0x92CA
+ ATOMIC_COUNTER_BUFFER_REFERENCED_BY_FRAGMENT_SHADER = 0x92CB
+ MAX_VERTEX_ATOMIC_COUNTER_BUFFERS = 0x92CC
+ MAX_TESS_CONTROL_ATOMIC_COUNTER_BUFFERS = 0x92CD
+ MAX_TESS_EVALUATION_ATOMIC_COUNTER_BUFFERS = 0x92CE
+ MAX_GEOMETRY_ATOMIC_COUNTER_BUFFERS = 0x92CF
+ MAX_FRAGMENT_ATOMIC_COUNTER_BUFFERS = 0x92D0
+ MAX_COMBINED_ATOMIC_COUNTER_BUFFERS = 0x92D1
+ MAX_VERTEX_ATOMIC_COUNTERS = 0x92D2
+ MAX_TESS_CONTROL_ATOMIC_COUNTERS = 0x92D3
+ MAX_TESS_EVALUATION_ATOMIC_COUNTERS = 0x92D4
+ MAX_GEOMETRY_ATOMIC_COUNTERS = 0x92D5
+ MAX_FRAGMENT_ATOMIC_COUNTERS = 0x92D6
+ MAX_COMBINED_ATOMIC_COUNTERS = 0x92D7
+ MAX_ATOMIC_COUNTER_BUFFER_SIZE = 0x92D8
+ ACTIVE_ATOMIC_COUNTER_BUFFERS = 0x92D9
+ UNIFORM_ATOMIC_COUNTER_BUFFER_INDEX = 0x92DA
+ UNSIGNED_INT_ATOMIC_COUNTER = 0x92DB
+ MAX_ATOMIC_COUNTER_BUFFER_BINDINGS = 0x92DC
+ NUM_SAMPLE_COUNTS = 0x9380
+)
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glViewport.xml
+func (gl *GL) Viewport(x, y, width, height int) {
+ C.gl4_2compat_glViewport(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// DepthRange specifies the mapping of depth values from normalized device
+// coordinates to window coordinates.
+//
+// Parameter nearVal specifies the mapping of the near clipping plane to window
+// coordinates (defaults to 0), while farVal specifies the mapping of the far
+// clipping plane to window coordinates (defaults to 1).
+//
+// After clipping and division by w, depth coordinates range from -1 to 1,
+// corresponding to the near and far clipping planes. DepthRange specifies a
+// linear mapping of the normalized depth coordinates in this range to window
+// depth coordinates. Regardless of the actual depth buffer implementation,
+// window coordinate depth values are treated as though they range from 0 through 1
+// (like color components). Thus, the values accepted by DepthRange are both
+// clamped to this range before they are accepted.
+//
+// The default setting of (0, 1) maps the near plane to 0 and the far plane to 1.
+// With this mapping, the depth buffer range is fully utilized.
+//
+// It is not necessary that nearVal be less than farVal. Reverse mappings such as
+// nearVal 1, and farVal 0 are acceptable.
+//
+// GL.INVALID_OPERATION is generated if DepthRange is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) DepthRange(nearVal, farVal float64) {
+ C.gl4_2compat_glDepthRange(gl.funcs, C.GLdouble(nearVal), C.GLdouble(farVal))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsEnabled.xml
+func (gl *GL) IsEnabled(cap glbase.Enum) bool {
+ glresult := C.gl4_2compat_glIsEnabled(gl.funcs, C.GLenum(cap))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexLevelParameteriv.xml
+func (gl *GL) GetTexLevelParameteriv(target glbase.Enum, level int, pname glbase.Enum, params []int32) {
+ C.gl4_2compat_glGetTexLevelParameteriv(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexLevelParameterfv.xml
+func (gl *GL) GetTexLevelParameterfv(target glbase.Enum, level int, pname glbase.Enum, params []float32) {
+ C.gl4_2compat_glGetTexLevelParameterfv(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexParameteriv.xml
+func (gl *GL) GetTexParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl4_2compat_glGetTexParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexParameterfv.xml
+func (gl *GL) GetTexParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl4_2compat_glGetTexParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexImage.xml
+func (gl *GL) GetTexImage(target glbase.Enum, level int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2compat_glGetTexImage(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetIntegerv.xml
+func (gl *GL) GetIntegerv(pname glbase.Enum, params []int32) {
+ C.gl4_2compat_glGetIntegerv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetFloatv.xml
+func (gl *GL) GetFloatv(pname glbase.Enum, params []float32) {
+ C.gl4_2compat_glGetFloatv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetError.xml
+func (gl *GL) GetError() glbase.Enum {
+ glresult := C.gl4_2compat_glGetError(gl.funcs)
+ return glbase.Enum(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetDoublev.xml
+func (gl *GL) GetDoublev(pname glbase.Enum, params []float64) {
+ C.gl4_2compat_glGetDoublev(gl.funcs, C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetBooleanv.xml
+func (gl *GL) GetBooleanv(pname glbase.Enum, params []bool) {
+ C.gl4_2compat_glGetBooleanv(gl.funcs, C.GLenum(pname), (*C.GLboolean)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glReadPixels.xml
+func (gl *GL) ReadPixels(x, y, width, height int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2compat_glReadPixels(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glReadBuffer.xml
+func (gl *GL) ReadBuffer(mode glbase.Enum) {
+ C.gl4_2compat_glReadBuffer(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPixelStorei.xml
+func (gl *GL) PixelStorei(pname glbase.Enum, param int32) {
+ C.gl4_2compat_glPixelStorei(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPixelStoref.xml
+func (gl *GL) PixelStoref(pname glbase.Enum, param float32) {
+ C.gl4_2compat_glPixelStoref(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDepthFunc.xml
+func (gl *GL) DepthFunc(glfunc glbase.Enum) {
+ C.gl4_2compat_glDepthFunc(gl.funcs, C.GLenum(glfunc))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glStencilOp.xml
+func (gl *GL) StencilOp(fail, zfail, zpass glbase.Enum) {
+ C.gl4_2compat_glStencilOp(gl.funcs, C.GLenum(fail), C.GLenum(zfail), C.GLenum(zpass))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glStencilFunc.xml
+func (gl *GL) StencilFunc(glfunc glbase.Enum, ref int32, mask uint32) {
+ C.gl4_2compat_glStencilFunc(gl.funcs, C.GLenum(glfunc), C.GLint(ref), C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLogicOp.xml
+func (gl *GL) LogicOp(opcode glbase.Enum) {
+ C.gl4_2compat_glLogicOp(gl.funcs, C.GLenum(opcode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendFunc.xml
+func (gl *GL) BlendFunc(sfactor, dfactor glbase.Enum) {
+ C.gl4_2compat_glBlendFunc(gl.funcs, C.GLenum(sfactor), C.GLenum(dfactor))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFlush.xml
+func (gl *GL) Flush() {
+ C.gl4_2compat_glFlush(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFinish.xml
+func (gl *GL) Finish() {
+ C.gl4_2compat_glFinish(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEnable.xml
+func (gl *GL) Enable(cap glbase.Enum) {
+ C.gl4_2compat_glEnable(gl.funcs, C.GLenum(cap))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDisable.xml
+func (gl *GL) Disable(cap glbase.Enum) {
+ C.gl4_2compat_glDisable(gl.funcs, C.GLenum(cap))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDepthMask.xml
+func (gl *GL) DepthMask(flag bool) {
+ C.gl4_2compat_glDepthMask(gl.funcs, *(*C.GLboolean)(unsafe.Pointer(&flag)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorMask.xml
+func (gl *GL) ColorMask(red, green, blue, alpha bool) {
+ C.gl4_2compat_glColorMask(gl.funcs, *(*C.GLboolean)(unsafe.Pointer(&red)), *(*C.GLboolean)(unsafe.Pointer(&green)), *(*C.GLboolean)(unsafe.Pointer(&blue)), *(*C.GLboolean)(unsafe.Pointer(&alpha)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glStencilMask.xml
+func (gl *GL) StencilMask(mask uint32) {
+ C.gl4_2compat_glStencilMask(gl.funcs, C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearDepth.xml
+func (gl *GL) ClearDepth(depth float64) {
+ C.gl4_2compat_glClearDepth(gl.funcs, C.GLdouble(depth))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearStencil.xml
+func (gl *GL) ClearStencil(s int32) {
+ C.gl4_2compat_glClearStencil(gl.funcs, C.GLint(s))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearColor.xml
+func (gl *GL) ClearColor(red, green, blue, alpha float32) {
+ C.gl4_2compat_glClearColor(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClear.xml
+func (gl *GL) Clear(mask glbase.Bitfield) {
+ C.gl4_2compat_glClear(gl.funcs, C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawBuffer.xml
+func (gl *GL) DrawBuffer(mode glbase.Enum) {
+ C.gl4_2compat_glDrawBuffer(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexImage2D.xml
+func (gl *GL) TexImage2D(target glbase.Enum, level int, internalFormat int32, width, height, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2compat_glTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexImage1D.xml
+func (gl *GL) TexImage1D(target glbase.Enum, level int, internalFormat int32, width, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2compat_glTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexParameteriv.xml
+func (gl *GL) TexParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl4_2compat_glTexParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexParameteri.xml
+func (gl *GL) TexParameteri(target, pname glbase.Enum, param int32) {
+ C.gl4_2compat_glTexParameteri(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexParameterfv.xml
+func (gl *GL) TexParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl4_2compat_glTexParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexParameterf.xml
+func (gl *GL) TexParameterf(target, pname glbase.Enum, param float32) {
+ C.gl4_2compat_glTexParameterf(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glScissor.xml
+func (gl *GL) Scissor(x, y, width, height int) {
+ C.gl4_2compat_glScissor(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPolygonMode.xml
+func (gl *GL) PolygonMode(face, mode glbase.Enum) {
+ C.gl4_2compat_glPolygonMode(gl.funcs, C.GLenum(face), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPointSize.xml
+func (gl *GL) PointSize(size float32) {
+ C.gl4_2compat_glPointSize(gl.funcs, C.GLfloat(size))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLineWidth.xml
+func (gl *GL) LineWidth(width float32) {
+ C.gl4_2compat_glLineWidth(gl.funcs, C.GLfloat(width))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glHint.xml
+func (gl *GL) Hint(target, mode glbase.Enum) {
+ C.gl4_2compat_glHint(gl.funcs, C.GLenum(target), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFrontFace.xml
+func (gl *GL) FrontFace(mode glbase.Enum) {
+ C.gl4_2compat_glFrontFace(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCullFace.xml
+func (gl *GL) CullFace(mode glbase.Enum) {
+ C.gl4_2compat_glCullFace(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIndexubv.xml
+func (gl *GL) Indexubv(c []uint8) {
+ C.gl4_2compat_glIndexubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIndexub.xml
+func (gl *GL) Indexub(c uint8) {
+ C.gl4_2compat_glIndexub(gl.funcs, C.GLubyte(c))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsTexture.xml
+func (gl *GL) IsTexture(texture glbase.Texture) bool {
+ glresult := C.gl4_2compat_glIsTexture(gl.funcs, C.GLuint(texture))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// GenTextures returns n texture names in textures. There is no guarantee
+// that the names form a contiguous set of integers; however, it is
+// guaranteed that none of the returned names was in use immediately before
+// the call to GenTextures.
+//
+// The generated textures have no dimensionality; they assume the
+// dimensionality of the texture target to which they are first bound (see
+// BindTexture).
+//
+// Texture names returned by a call to GenTextures are not returned by
+// subsequent calls, unless they are first deleted with DeleteTextures.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// GenTextures is available in GL version 2.0 or greater.
+func (gl *GL) GenTextures(n int) []glbase.Texture {
+ if n == 0 {
+ return nil
+ }
+ textures := make([]glbase.Texture, n)
+ C.gl4_2compat_glGenTextures(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])))
+ return textures
+}
+
+// DeleteTextures deletes the textures objects whose names are stored
+// in the textures slice. After a texture is deleted, it has no contents or
+// dimensionality, and its name is free for reuse (for example by
+// GenTextures). If a texture that is currently bound is deleted, the binding
+// reverts to 0 (the default texture).
+//
+// DeleteTextures silently ignores 0's and names that do not correspond to
+// existing textures.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// DeleteTextures is available in GL version 2.0 or greater.
+func (gl *GL) DeleteTextures(textures []glbase.Texture) {
+ n := len(textures)
+ if n == 0 {
+ return
+ }
+ C.gl4_2compat_glDeleteTextures(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindTexture.xml
+func (gl *GL) BindTexture(target glbase.Enum, texture glbase.Texture) {
+ C.gl4_2compat_glBindTexture(gl.funcs, C.GLenum(target), C.GLuint(texture))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexSubImage2D.xml
+func (gl *GL) TexSubImage2D(target glbase.Enum, level, xoffset, yoffset, width, height int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2compat_glTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexSubImage1D.xml
+func (gl *GL) TexSubImage1D(target glbase.Enum, level, xoffset, width int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2compat_glTexSubImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLsizei(width), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyTexSubImage2D.xml
+func (gl *GL) CopyTexSubImage2D(target glbase.Enum, level, xoffset, yoffset, x, y, width, height int) {
+ C.gl4_2compat_glCopyTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyTexSubImage1D.xml
+func (gl *GL) CopyTexSubImage1D(target glbase.Enum, level, xoffset, x, y, width int) {
+ C.gl4_2compat_glCopyTexSubImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(x), C.GLint(y), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyTexImage2D.xml
+func (gl *GL) CopyTexImage2D(target glbase.Enum, level int, internalFormat glbase.Enum, x, y, width, height, border int) {
+ C.gl4_2compat_glCopyTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height), C.GLint(border))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyTexImage1D.xml
+func (gl *GL) CopyTexImage1D(target glbase.Enum, level int, internalFormat glbase.Enum, x, y, width, border int) {
+ C.gl4_2compat_glCopyTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLint(border))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPolygonOffset.xml
+func (gl *GL) PolygonOffset(factor, units float32) {
+ C.gl4_2compat_glPolygonOffset(gl.funcs, C.GLfloat(factor), C.GLfloat(units))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawElements.xml
+func (gl *GL) DrawElements(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2compat_glDrawElements(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawArrays.xml
+func (gl *GL) DrawArrays(mode glbase.Enum, first, count int) {
+ C.gl4_2compat_glDrawArrays(gl.funcs, C.GLenum(mode), C.GLint(first), C.GLsizei(count))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyTexSubImage3D.xml
+func (gl *GL) CopyTexSubImage3D(target glbase.Enum, level, xoffset, yoffset int, zoffset int32, x, y, width, height int) {
+ C.gl4_2compat_glCopyTexSubImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(zoffset), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexSubImage3D.xml
+func (gl *GL) TexSubImage3D(target glbase.Enum, level, xoffset, yoffset int, zoffset int32, width, height int, depth int32, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2compat_glTexSubImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(zoffset), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexImage3D.xml
+func (gl *GL) TexImage3D(target glbase.Enum, level int, internalFormat int32, width, height int, depth int32, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2compat_glTexImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawRangeElements.xml
+func (gl *GL) DrawRangeElements(mode glbase.Enum, start, end uint32, count int, gltype glbase.Enum, indices interface{}) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2compat_glDrawRangeElements(gl.funcs, C.GLenum(mode), C.GLuint(start), C.GLuint(end), C.GLsizei(count), C.GLenum(gltype), indices_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendEquation.xml
+func (gl *GL) BlendEquation(mode glbase.Enum) {
+ C.gl4_2compat_glBlendEquation(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendColor.xml
+func (gl *GL) BlendColor(red, green, blue, alpha float32) {
+ C.gl4_2compat_glBlendColor(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetCompressedTexImage.xml
+func (gl *GL) GetCompressedTexImage(target glbase.Enum, level int, img interface{}) {
+ var img_ptr unsafe.Pointer
+ var img_v = reflect.ValueOf(img)
+ if img != nil && img_v.Kind() != reflect.Slice {
+ panic("parameter img must be a slice")
+ }
+ if img != nil {
+ img_ptr = unsafe.Pointer(img_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2compat_glGetCompressedTexImage(gl.funcs, C.GLenum(target), C.GLint(level), img_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCompressedTexSubImage1D.xml
+func (gl *GL) CompressedTexSubImage1D(target glbase.Enum, level, xoffset, width int, format glbase.Enum, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2compat_glCompressedTexSubImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLsizei(width), C.GLenum(format), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCompressedTexSubImage2D.xml
+func (gl *GL) CompressedTexSubImage2D(target glbase.Enum, level, xoffset, yoffset, width, height int, format glbase.Enum, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2compat_glCompressedTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCompressedTexSubImage3D.xml
+func (gl *GL) CompressedTexSubImage3D(target glbase.Enum, level, xoffset, yoffset int, zoffset int32, width, height int, depth int32, format glbase.Enum, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2compat_glCompressedTexSubImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(zoffset), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLenum(format), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCompressedTexImage1D.xml
+func (gl *GL) CompressedTexImage1D(target glbase.Enum, level int, internalFormat glbase.Enum, width, border, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2compat_glCompressedTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLsizei(width), C.GLint(border), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCompressedTexImage2D.xml
+func (gl *GL) CompressedTexImage2D(target glbase.Enum, level int, internalFormat glbase.Enum, width, height, border, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2compat_glCompressedTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLint(border), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCompressedTexImage3D.xml
+func (gl *GL) CompressedTexImage3D(target glbase.Enum, level int, internalFormat glbase.Enum, width, height int, depth int32, border, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2compat_glCompressedTexImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLint(border), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSampleCoverage.xml
+func (gl *GL) SampleCoverage(value float32, invert bool) {
+ C.gl4_2compat_glSampleCoverage(gl.funcs, C.GLfloat(value), *(*C.GLboolean)(unsafe.Pointer(&invert)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glActiveTexture.xml
+func (gl *GL) ActiveTexture(texture glbase.Enum) {
+ C.gl4_2compat_glActiveTexture(gl.funcs, C.GLenum(texture))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPointParameteriv.xml
+func (gl *GL) PointParameteriv(pname glbase.Enum, params []int32) {
+ C.gl4_2compat_glPointParameteriv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPointParameteri.xml
+func (gl *GL) PointParameteri(pname glbase.Enum, param int32) {
+ C.gl4_2compat_glPointParameteri(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPointParameterfv.xml
+func (gl *GL) PointParameterfv(pname glbase.Enum, params []float32) {
+ C.gl4_2compat_glPointParameterfv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPointParameterf.xml
+func (gl *GL) PointParameterf(pname glbase.Enum, param float32) {
+ C.gl4_2compat_glPointParameterf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiDrawArrays.xml
+func (gl *GL) MultiDrawArrays(mode glbase.Enum, first, count []int, drawcount int32) {
+ C.gl4_2compat_glMultiDrawArrays(gl.funcs, C.GLenum(mode), (*C.GLint)(unsafe.Pointer(&first[0])), (*C.GLsizei)(unsafe.Pointer(&count[0])), C.GLsizei(drawcount))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendFuncSeparate.xml
+func (gl *GL) BlendFuncSeparate(sfactorRGB, dfactorRGB, sfactorAlpha, dfactorAlpha glbase.Enum) {
+ C.gl4_2compat_glBlendFuncSeparate(gl.funcs, C.GLenum(sfactorRGB), C.GLenum(dfactorRGB), C.GLenum(sfactorAlpha), C.GLenum(dfactorAlpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetBufferParameteriv.xml
+func (gl *GL) GetBufferParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl4_2compat_glGetBufferParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUnmapBuffer.xml
+func (gl *GL) UnmapBuffer(target glbase.Enum) bool {
+ glresult := C.gl4_2compat_glUnmapBuffer(gl.funcs, C.GLenum(target))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetBufferSubData.xml
+func (gl *GL) GetBufferSubData(target glbase.Enum, offset, size int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2compat_glGetBufferSubData(gl.funcs, C.GLenum(target), C.GLintptr(offset), C.GLsizeiptr(size), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBufferSubData.xml
+func (gl *GL) BufferSubData(target glbase.Enum, offset, size int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2compat_glBufferSubData(gl.funcs, C.GLenum(target), C.GLintptr(offset), C.GLsizeiptr(size), data_ptr)
+}
+
+// BufferData creates a new data store for the buffer object currently
+// bound to target. Any pre-existing data store is deleted. The new data
+// store is created with the specified size in bytes and usage. If data is
+// not nil, it must be a slice that is used to initialize the data store.
+// In that case the size parameter is ignored and the store size will match
+// the slice data size.
+//
+// In its initial state, the new data store is not mapped, it has a NULL
+// mapped pointer, and its mapped access is GL.READ_WRITE.
+//
+// The target constant must be one of GL.ARRAY_BUFFER, GL.COPY_READ_BUFFER,
+// GL.COPY_WRITE_BUFFER, GL.ELEMENT_ARRAY_BUFFER, GL.PIXEL_PACK_BUFFER,
+// GL.PIXEL_UNPACK_BUFFER, GL.TEXTURE_BUFFER, GL.TRANSFORM_FEEDBACK_BUFFER,
+// or GL.UNIFORM_BUFFER.
+//
+// The usage parameter is a hint to the GL implementation as to how a buffer
+// object's data store will be accessed. This enables the GL implementation
+// to make more intelligent decisions that may significantly impact buffer
+// object performance. It does not, however, constrain the actual usage of
+// the data store. usage can be broken down into two parts: first, the
+// frequency of access (modification and usage), and second, the nature of
+// that access.
+//
+// A usage frequency of STREAM and nature of DRAW is specified via the
+// constant GL.STREAM_DRAW, for example.
+//
+// The usage frequency of access may be one of:
+//
+// STREAM
+// The data store contents will be modified once and used at most a few times.
+//
+// STATIC
+// The data store contents will be modified once and used many times.
+//
+// DYNAMIC
+// The data store contents will be modified repeatedly and used many times.
+//
+// The usage nature of access may be one of:
+//
+// DRAW
+// The data store contents are modified by the application, and used as
+// the source for GL drawing and image specification commands.
+//
+// READ
+// The data store contents are modified by reading data from the GL,
+// and used to return that data when queried by the application.
+//
+// COPY
+// The data store contents are modified by reading data from the GL,
+// and used as the source for GL drawing and image specification
+// commands.
+//
+// Clients must align data elements consistent with the requirements of the
+// client platform, with an additional base-level requirement that an offset
+// within a buffer to a datum comprising N bytes be a multiple of N.
+//
+// Error GL.INVALID_ENUM is generated if target is not one of the accepted
+// buffer targets. GL.INVALID_ENUM is generated if usage is not
+// GL.STREAM_DRAW, GL.STREAM_READ, GL.STREAM_COPY, GL.STATIC_DRAW,
+// GL.STATIC_READ, GL.STATIC_COPY, GL.DYNAMIC_DRAW, GL.DYNAMIC_READ, or
+// GL.DYNAMIC_COPY. GL.INVALID_VALUE is generated if size is negative.
+// GL.INVALID_OPERATION is generated if the reserved buffer object name 0 is
+// bound to target. GL.OUT_OF_MEMORY is generated if the GL is unable to
+// create a data store with the specified size.
+func (gl *GL) BufferData(target glbase.Enum, size int, data interface{}, usage glbase.Enum) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ if data != nil {
+ size = int(data_v.Type().Size()) * data_v.Len()
+ }
+ C.gl4_2compat_glBufferData(gl.funcs, C.GLenum(target), C.GLsizeiptr(size), data_ptr, C.GLenum(usage))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsBuffer.xml
+func (gl *GL) IsBuffer(buffer glbase.Buffer) bool {
+ glresult := C.gl4_2compat_glIsBuffer(gl.funcs, C.GLuint(buffer))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// GenBuffers returns n buffer object names. There is no guarantee that
+// the names form a contiguous set of integers; however, it is guaranteed
+// that none of the returned names was in use immediately before the call to
+// GenBuffers.
+//
+// Buffer object names returned by a call to GenBuffers are not returned by
+// subsequent calls, unless they are first deleted with DeleteBuffers.
+//
+// No buffer objects are associated with the returned buffer object names
+// until they are first bound by calling BindBuffer.
+//
+// Error GL.INVALID_VALUE is generated if n is negative. GL.INVALID_OPERATION
+// is generated if GenBuffers is executed between the execution of Begin
+// and the corresponding execution of End.
+//
+// GenBuffers is available in GL version 1.5 or greater.
+func (gl *GL) GenBuffers(n int) []glbase.Buffer {
+ if n == 0 {
+ return nil
+ }
+ buffers := make([]glbase.Buffer, n)
+ C.gl4_2compat_glGenBuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&buffers[0])))
+ return buffers
+}
+
+// DeleteBuffers deletes the buffer objects whose names are stored in the
+// buffers slice.
+//
+// After a buffer object is deleted, it has no contents, and its name is free
+// for reuse (for example by GenBuffers). If a buffer object that is
+// currently bound is deleted, the binding reverts to 0 (the absence of any
+// buffer object, which reverts to client memory usage).
+//
+// DeleteBuffers silently ignores 0's and names that do not correspond to
+// existing buffer objects.
+//
+// Error GL.INVALID_VALUE is generated if n is negative. GL.INVALID_OPERATION
+// is generated if DeleteBuffers is executed between the execution of Begin
+// and the corresponding execution of End.
+//
+// DeleteBuffers is available in GL version 1.5 or greater.
+func (gl *GL) DeleteBuffers(buffers []glbase.Buffer) {
+ n := len(buffers)
+ if n == 0 {
+ return
+ }
+ C.gl4_2compat_glDeleteBuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&buffers[0])))
+}
+
+// BindBuffer creates or puts in use a named buffer object.
+// Calling BindBuffer with target set to GL.ARRAY_BUFFER,
+// GL.ELEMENT_ARRAY_BUFFER, GL.PIXEL_PACK_BUFFER or GL.PIXEL_UNPACK_BUFFER
+// and buffer set to the name of the new buffer object binds the buffer
+// object name to the target. When a buffer object is bound to a target, the
+// previous binding for that target is automatically broken.
+//
+// Buffer object names are unsigned integers. The value zero is reserved, but
+// there is no default buffer object for each buffer object target. Instead,
+// buffer set to zero effectively unbinds any buffer object previously bound,
+// and restores client memory usage for that buffer object target. Buffer
+// object names and the corresponding buffer object contents are local to the
+// shared display-list space (see XCreateContext) of the current GL rendering
+// context; two rendering contexts share buffer object names only if they
+// also share display lists.
+//
+// GenBuffers may be called to generate a set of new buffer object names.
+//
+// The state of a buffer object immediately after it is first bound is an
+// unmapped zero-sized memory buffer with GL.READ_WRITE access and
+// GL.STATIC_DRAW usage.
+//
+// While a non-zero buffer object name is bound, GL operations on the target
+// to which it is bound affect the bound buffer object, and queries of the
+// target to which it is bound return state from the bound buffer object.
+// While buffer object name zero is bound, as in the initial state, attempts
+// to modify or query state on the target to which it is bound generates an
+// GL.INVALID_OPERATION error.
+//
+// When vertex array pointer state is changed, for example by a call to
+// NormalPointer, the current buffer object binding (GL.ARRAY_BUFFER_BINDING)
+// is copied into the corresponding client state for the vertex array type
+// being changed, for example GL.NORMAL_ARRAY_BUFFER_BINDING. While a
+// non-zero buffer object is bound to the GL.ARRAY_BUFFER target, the vertex
+// array pointer parameter that is traditionally interpreted as a pointer to
+// client-side memory is instead interpreted as an offset within the buffer
+// object measured in basic machine units.
+//
+// While a non-zero buffer object is bound to the GL.ELEMENT_ARRAY_BUFFER
+// target, the indices parameter of DrawElements, DrawRangeElements, or
+// MultiDrawElements that is traditionally interpreted as a pointer to
+// client-side memory is instead interpreted as an offset within the buffer
+// object measured in basic machine units.
+//
+// While a non-zero buffer object is bound to the GL.PIXEL_PACK_BUFFER
+// target, the following commands are affected: GetCompressedTexImage,
+// GetConvolutionFilter, GetHistogram, GetMinmax, GetPixelMap,
+// GetPolygonStipple, GetSeparableFilter, GetTexImage, and ReadPixels. The
+// pointer parameter that is traditionally interpreted as a pointer to
+// client-side memory where the pixels are to be packed is instead
+// interpreted as an offset within the buffer object measured in basic
+// machine units.
+//
+// While a non-zero buffer object is bound to the GL.PIXEL_UNPACK_BUFFER
+// target, the following commands are affected: Bitmap, ColorSubTable,
+// ColorTable, CompressedTexImage1D, CompressedTexImage2D,
+// CompressedTexImage3D, CompressedTexSubImage1D, CompressedTexSubImage2D,
+// CompressedTexSubImage3D, ConvolutionFilter1D, ConvolutionFilter2D,
+// DrawPixels, PixelMap, PolygonStipple, SeparableFilter2D, TexImage1D,
+// TexImage2D, TexImage3D, TexSubImage1D, TexSubImage2D, and TexSubImage3D.
+// The pointer parameter that is traditionally interpreted as a pointer to
+// client-side memory from which the pixels are to be unpacked is instead
+// interpreted as an offset within the buffer object measured in basic
+// machine units.
+//
+// A buffer object binding created with BindBuffer remains active until a
+// different buffer object name is bound to the same target, or until the
+// bound buffer object is deleted with DeleteBuffers.
+//
+// Once created, a named buffer object may be re-bound to any target as often
+// as needed. However, the GL implementation may make choices about how to
+// optimize the storage of a buffer object based on its initial binding
+// target.
+//
+// Error GL.INVALID_ENUM is generated if target is not one of the allowable
+// values. GL.INVALID_OPERATION is generated if BindBuffer is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// BindBuffer is available in GL version 1.5 or greater.
+func (gl *GL) BindBuffer(target glbase.Enum, buffer glbase.Buffer) {
+ C.gl4_2compat_glBindBuffer(gl.funcs, C.GLenum(target), C.GLuint(buffer))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetQueryObjectuiv.xml
+func (gl *GL) GetQueryObjectuiv(id uint32, pname glbase.Enum, params []uint32) {
+ C.gl4_2compat_glGetQueryObjectuiv(gl.funcs, C.GLuint(id), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetQueryObjectiv.xml
+func (gl *GL) GetQueryObjectiv(id uint32, pname glbase.Enum, params []int32) {
+ C.gl4_2compat_glGetQueryObjectiv(gl.funcs, C.GLuint(id), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetQueryiv.xml
+func (gl *GL) GetQueryiv(target, pname glbase.Enum, params []int32) {
+ C.gl4_2compat_glGetQueryiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEndQuery.xml
+func (gl *GL) EndQuery(target glbase.Enum) {
+ C.gl4_2compat_glEndQuery(gl.funcs, C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBeginQuery.xml
+func (gl *GL) BeginQuery(target glbase.Enum, id uint32) {
+ C.gl4_2compat_glBeginQuery(gl.funcs, C.GLenum(target), C.GLuint(id))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsQuery.xml
+func (gl *GL) IsQuery(id uint32) bool {
+ glresult := C.gl4_2compat_glIsQuery(gl.funcs, C.GLuint(id))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDeleteQueries.xml
+func (gl *GL) DeleteQueries(n int, ids []uint32) {
+ C.gl4_2compat_glDeleteQueries(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&ids[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGenQueries.xml
+func (gl *GL) GenQueries(n int, ids []uint32) {
+ C.gl4_2compat_glGenQueries(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&ids[0])))
+}
+
+// VertexAttribPointer specifies the location and data format of the array
+// of generic vertex attributes at index to use when rendering. size
+// specifies the number of components per attribute and must be 1, 2, 3, or
+// 4. type specifies the data type of each component, and stride specifies
+// the byte stride from one attribute to the next, allowing vertices and
+// attributes to be packed into a single array or stored in separate arrays.
+// normalized indicates whether the values stored in an integer format are
+// to be mapped to the range [-1,1] (for signed values) or [0,1]
+// (for unsigned values) when they are accessed and converted to floating
+// point; otherwise, values will be converted to floats directly without
+// normalization. offset is a byte offset into the buffer object's data
+// store, which must be bound to the GL.ARRAY_BUFFER target with BindBuffer.
+//
+// The buffer object binding (GL.ARRAY_BUFFER_BINDING) is saved as
+// generic vertex attribute array client-side state
+// (GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING) for the provided index.
+//
+// To enable and disable a generic vertex attribute array, call
+// EnableVertexAttribArray and DisableVertexAttribArray with index. If
+// enabled, the generic vertex attribute array is used when DrawArrays or
+// DrawElements is called. Each generic vertex attribute array is initially
+// disabled.
+//
+// VertexAttribPointer is typically implemented on the client side.
+//
+// Error GL.INVALID_ENUM is generated if type is not an accepted value.
+// GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_VALUE is generated if size is not 1, 2,
+// 3, or 4. GL.INVALID_VALUE is generated if stride is negative.
+func (gl *GL) VertexAttribPointer(index glbase.Attrib, size int, gltype glbase.Enum, normalized bool, stride int, offset uintptr) {
+ offset_ptr := unsafe.Pointer(offset)
+ C.gl4_2compat_glVertexAttribPointer(gl.funcs, C.GLuint(index), C.GLint(size), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), C.GLsizei(stride), offset_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glValidateProgram.xml
+func (gl *GL) ValidateProgram(program glbase.Program) {
+ C.gl4_2compat_glValidateProgram(gl.funcs, C.GLuint(program))
+}
+
+// UniformMatrix4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix4fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(4*4) != 0 {
+ panic("invalid value length for UniformMatrix4fv")
+ }
+ count := len(value) / (4 * 4)
+ C.gl4_2compat_glUniformMatrix4fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix3fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(3*3) != 0 {
+ panic("invalid value length for UniformMatrix3fv")
+ }
+ count := len(value) / (3 * 3)
+ C.gl4_2compat_glUniformMatrix3fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix2fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(2*2) != 0 {
+ panic("invalid value length for UniformMatrix2fv")
+ }
+ count := len(value) / (2 * 2)
+ C.gl4_2compat_glUniformMatrix2fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform4iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%4 != 0 {
+ panic("invalid value length for Uniform4iv")
+ }
+ count := len(value) / 4
+ C.gl4_2compat_glUniform4iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform3iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform3iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%3 != 0 {
+ panic("invalid value length for Uniform3iv")
+ }
+ count := len(value) / 3
+ C.gl4_2compat_glUniform3iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform2iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform2iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%2 != 0 {
+ panic("invalid value length for Uniform2iv")
+ }
+ count := len(value) / 2
+ C.gl4_2compat_glUniform2iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform1iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform1iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ count := len(value)
+ C.gl4_2compat_glUniform1iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%4 != 0 {
+ panic("invalid value length for Uniform4fv")
+ }
+ count := len(value) / 4
+ C.gl4_2compat_glUniform4fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%3 != 0 {
+ panic("invalid value length for Uniform3fv")
+ }
+ count := len(value) / 3
+ C.gl4_2compat_glUniform3fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%2 != 0 {
+ panic("invalid value length for Uniform2fv")
+ }
+ count := len(value) / 2
+ C.gl4_2compat_glUniform2fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform1fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform1fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ count := len(value)
+ C.gl4_2compat_glUniform1fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform4i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4i(location glbase.Uniform, v0, v1, v2, v3 int32) {
+ C.gl4_2compat_glUniform4i(gl.funcs, C.GLint(location), C.GLint(v0), C.GLint(v1), C.GLint(v2), C.GLint(v3))
+}
+
+// Uniform3i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform3i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3i(location glbase.Uniform, v0, v1, v2 int32) {
+ C.gl4_2compat_glUniform3i(gl.funcs, C.GLint(location), C.GLint(v0), C.GLint(v1), C.GLint(v2))
+}
+
+// Uniform2i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform2i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2i(location glbase.Uniform, v0, v1 int32) {
+ C.gl4_2compat_glUniform2i(gl.funcs, C.GLint(location), C.GLint(v0), C.GLint(v1))
+}
+
+// Uniform1i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform1i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1i(location glbase.Uniform, v0 int32) {
+ C.gl4_2compat_glUniform1i(gl.funcs, C.GLint(location), C.GLint(v0))
+}
+
+// Uniform4f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform4f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4f(location glbase.Uniform, v0, v1, v2, v3 float32) {
+ C.gl4_2compat_glUniform4f(gl.funcs, C.GLint(location), C.GLfloat(v0), C.GLfloat(v1), C.GLfloat(v2), C.GLfloat(v3))
+}
+
+// Uniform3f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform3f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3f(location glbase.Uniform, v0, v1, v2 float32) {
+ C.gl4_2compat_glUniform3f(gl.funcs, C.GLint(location), C.GLfloat(v0), C.GLfloat(v1), C.GLfloat(v2))
+}
+
+// Uniform2f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform2f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2f(location glbase.Uniform, v0, v1 float32) {
+ C.gl4_2compat_glUniform2f(gl.funcs, C.GLint(location), C.GLfloat(v0), C.GLfloat(v1))
+}
+
+// Uniform1f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform1f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1f(location glbase.Uniform, v0 float32) {
+ C.gl4_2compat_glUniform1f(gl.funcs, C.GLint(location), C.GLfloat(v0))
+}
+
+// UseProgram installs the program object specified by program as part of
+// current rendering state. One or more executables are created in a program
+// object by successfully attaching shader objects to it with AttachShader,
+// successfully compiling the shader objects with CompileShader, and
+// successfully linking the program object with LinkProgram.
+//
+// A program object will contain an executable that will run on the vertex
+// processor if it contains one or more shader objects of type
+// GL.VERTEX_SHADER that have been successfully compiled and linked.
+// Similarly, a program object will contain an executable that will run on
+// the fragment processor if it contains one or more shader objects of type
+// GL.FRAGMENT_SHADER that have been successfully compiled and linked.
+//
+// Successfully installing an executable on a programmable processor will
+// cause the corresponding fixed functionality of OpenGL to be disabled.
+// Specifically, if an executable is installed on the vertex processor, the
+// OpenGL fixed functionality will be disabled as follows.
+//
+// - The modelview matrix is not applied to vertex coordinates.
+//
+// - The projection matrix is not applied to vertex coordinates.
+//
+// - The texture matrices are not applied to texture coordinates.
+//
+// - Normals are not transformed to eye coordinates.
+//
+// - Normals are not rescaled or normalized.
+//
+// - Normalization of GL.AUTO_NORMAL evaluated normals is not performed.
+//
+// - Texture coordinates are not generated automatically.
+//
+// - Per-vertex lighting is not performed.
+//
+// - Color material computations are not performed.
+//
+// - Color index lighting is not performed.
+//
+// - This list also applies when setting the current raster position.
+//
+// The executable that is installed on the vertex processor is expected to
+// implement any or all of the desired functionality from the preceding list.
+// Similarly, if an executable is installed on the fragment processor, the
+// OpenGL fixed functionality will be disabled as follows.
+//
+// - Texture environment and texture functions are not applied.
+//
+// - Texture application is not applied.
+//
+// - Color sum is not applied.
+//
+// - Fog is not applied.
+//
+// Again, the fragment shader that is installed is expected to implement any
+// or all of the desired functionality from the preceding list.
+//
+// While a program object is in use, applications are free to modify attached
+// shader objects, compile attached shader objects, attach additional shader
+// objects, and detach or delete shader objects. None of these operations
+// will affect the executables that are part of the current state. However,
+// relinking the program object that is currently in use will install the
+// program object as part of the current rendering state if the link
+// operation was successful (see LinkProgram). If the program object
+// currently in use is relinked unsuccessfully, its link status will be set
+// to GL.FALSE, but the executables and associated state will remain part of
+// the current state until a subsequent call to UseProgram removes it from
+// use. After it is removed from use, it cannot be made part of current state
+// until it has been successfully relinked.
+//
+// If program contains shader objects of type GL.VERTEX_SHADER but it does
+// not contain shader objects of type GL.FRAGMENT_SHADER, an executable will
+// be installed on the vertex processor, but fixed functionality will be used
+// for fragment processing. Similarly, if program contains shader objects of
+// type GL.FRAGMENT_SHADER but it does not contain shader objects of type
+// GL.VERTEX_SHADER, an executable will be installed on the fragment
+// processor, but fixed functionality will be used for vertex processing. If
+// program is 0, the programmable processors will be disabled, and fixed
+// functionality will be used for both vertex and fragment processing.
+//
+// While a program object is in use, the state that controls the disabled
+// fixed functionality may also be updated using the normal OpenGL calls.
+//
+// Like display lists and texture objects, the name space for program objects
+// may be shared across a set of contexts, as long as the server sides of the
+// contexts share the same address space. If the name space is shared across
+// contexts, any attached objects and the data associated with those attached
+// objects are shared as well.
+//
+// Applications are responsible for providing the synchronization across API
+// calls when objects are accessed from different execution threads.
+//
+// Error GL.INVALID_VALUE is generated if program is neither 0 nor a value
+// generated by OpenGL. GL.INVALID_OPERATION is generated if program is not
+// a program object. GL.INVALID_OPERATION is generated if program could not
+// be made part of current state. GL.INVALID_OPERATION is generated if
+// UseProgram is executed between the execution of Begin and the
+// corresponding execution of End.
+//
+// UseProgram is available in GL version 2.0 or greater.
+func (gl *GL) UseProgram(program glbase.Program) {
+ C.gl4_2compat_glUseProgram(gl.funcs, C.GLuint(program))
+}
+
+// ShaderSource sets the source code in shader to the provided source code. Any source
+// code previously stored in the shader object is completely replaced.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader is not a shader
+// object. GL.INVALID_VALUE is generated if count is less than 0.
+// GL.INVALID_OPERATION is generated if ShaderSource is executed between the
+// execution of Begin and the corresponding execution of End.
+//
+// ShaderSource is available in GL version 2.0 or greater.
+func (gl *GL) ShaderSource(shader glbase.Shader, source ...string) {
+ count := len(source)
+ length := make([]int32, count)
+ source_c := make([]unsafe.Pointer, count)
+ for i, src := range source {
+ length[i] = int32(len(src))
+ if len(src) > 0 {
+ source_c[i] = *(*unsafe.Pointer)(unsafe.Pointer(&src))
+ } else {
+ source_c[i] = unsafe.Pointer(uintptr(0))
+ }
+ }
+ C.gl4_2compat_glShaderSource(gl.funcs, C.GLuint(shader), C.GLsizei(count), (**C.GLchar)(unsafe.Pointer(&source_c[0])), (*C.GLint)(unsafe.Pointer(&length[0])))
+}
+
+// LinkProgram links the program object specified by program. If any shader
+// objects of type GL.VERTEX_SHADER are attached to program, they will be
+// used to create an executable that will run on the programmable vertex
+// processor. If any shader objects of type GL.FRAGMENT_SHADER are attached
+// to program, they will be used to create an executable that will run on the
+// programmable fragment processor.
+//
+// The status of the link operation will be stored as part of the program
+// object's state. This value will be set to GL.TRUE if the program object
+// was linked without errors and is ready for use, and GL.FALSE otherwise. It
+// can be queried by calling GetProgramiv with arguments program and
+// GL.LINK_STATUS.
+//
+// As a result of a successful link operation, all active user-defined
+// uniform variables belonging to program will be initialized to 0, and each
+// of the program object's active uniform variables will be assigned a
+// location that can be queried by calling GetUniformLocation. Also, any
+// active user-defined attribute variables that have not been bound to a
+// generic vertex attribute index will be bound to one at this time.
+//
+// Linking of a program object can fail for a number of reasons as specified
+// in the OpenGL Shading Language Specification. The following lists some of
+// the conditions that will cause a link error.
+//
+// - The number of active attribute variables supported by the
+// implementation has been exceeded.
+//
+// - The storage limit for uniform variables has been exceeded.
+//
+// - The number of active uniform variables supported by the implementation
+// has been exceeded.
+//
+// - The main function is missing for the vertex shader or the fragment
+// shader.
+//
+// - A varying variable actually used in the fragment shader is not
+// declared in the same way (or is not declared at all) in the vertex
+// shader.
+//
+// - A reference to a function or variable name is unresolved.
+//
+// - A shared global is declared with two different types or two different
+// initial values.
+//
+// - One or more of the attached shader objects has not been successfully
+// compiled.
+//
+// - Binding a generic attribute matrix caused some rows of the matrix to
+// fall outside the allowed maximum of GL.MAX_VERTEX_ATTRIBS.
+//
+// - Not enough contiguous vertex attribute slots could be found to bind
+// attribute matrices.
+//
+// When a program object has been successfully linked, the program object can
+// be made part of current state by calling UseProgram. Whether or not the
+// link operation was successful, the program object's information log will
+// be overwritten. The information log can be retrieved by calling
+// GetProgramInfoLog.
+//
+// LinkProgram will also install the generated executables as part of the
+// current rendering state if the link operation was successful and the
+// specified program object is already currently in use as a result of a
+// previous call to UseProgram. If the program object currently in use is
+// relinked unsuccessfully, its link status will be set to GL.FALSE , but the
+// executables and associated state will remain part of the current state
+// until a subsequent call to UseProgram removes it from use. After it is
+// removed from use, it cannot be made part of current state until it has
+// been successfully relinked.
+//
+// If program contains shader objects of type GL.VERTEX_SHADER but does not
+// contain shader objects of type GL.FRAGMENT_SHADER, the vertex shader will
+// be linked against the implicit interface for fixed functionality fragment
+// processing. Similarly, if program contains shader objects of type
+// GL.FRAGMENT_SHADER but it does not contain shader objects of type
+// GL.VERTEX_SHADER, the fragment shader will be linked against the implicit
+// interface for fixed functionality vertex processing.
+//
+// The program object's information log is updated and the program is
+// generated at the time of the link operation. After the link operation,
+// applications are free to modify attached shader objects, compile attached
+// shader objects, detach shader objects, delete shader objects, and attach
+// additional shader objects. None of these operations affects the
+// information log or the program that is part of the program object.
+//
+// If the link operation is unsuccessful, any information about a previous
+// link operation on program is lost (a failed link does not restore the
+// old state of program). Certain information can still be retrieved
+// from program even after an unsuccessful link operation. See for instance
+// GetActiveAttrib and GetActiveUniform.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program
+// object. GL.INVALID_OPERATION is generated if LinkProgram is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// LinkProgram is available in GL version 2.0 or greater.
+func (gl *GL) LinkProgram(program glbase.Program) {
+ C.gl4_2compat_glLinkProgram(gl.funcs, C.GLuint(program))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsShader.xml
+func (gl *GL) IsShader(shader glbase.Shader) bool {
+ glresult := C.gl4_2compat_glIsShader(gl.funcs, C.GLuint(shader))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsProgram.xml
+func (gl *GL) IsProgram(program glbase.Program) bool {
+ glresult := C.gl4_2compat_glIsProgram(gl.funcs, C.GLuint(program))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// GetVertexAttribiv returns in params the value of a generic vertex attribute
+// parameter. The generic vertex attribute to be queried is specified by
+// index, and the parameter to be queried is specified by pname.
+//
+// The accepted parameter names are as follows:
+//
+// GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING
+// params returns a single value, the name of the buffer object
+// currently bound to the binding point corresponding to generic vertex
+// attribute array index. If no buffer object is bound, 0 is returned.
+// The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_ENABLED
+// params returns a single value that is non-zero (true) if the vertex
+// attribute array for index is enabled and 0 (false) if it is
+// disabled. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_SIZE
+// params returns a single value, the size of the vertex attribute
+// array for index. The size is the number of values for each element
+// of the vertex attribute array, and it will be 1, 2, 3, or 4. The
+// initial value is 4.
+//
+// GL.VERTEX_ATTRIB_ARRAY_STRIDE
+// params returns a single value, the array stride for (number of bytes
+// between successive elements in) the vertex attribute array for
+// index. A value of 0 indicates that the array elements are stored
+// sequentially in memory. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_TYPE
+// params returns a single value, a symbolic constant indicating the
+// array type for the vertex attribute array for index. Possible values
+// are GL.BYTE, GL.UNSIGNED_BYTE, GL.SHORT, GL.UNSIGNED_SHORT, GL.INT,
+// GL.UNSIGNED_INT, GL.FLOAT, and GL.DOUBLE. The initial value is
+// GL.FLOAT.
+//
+// GL.VERTEX_ATTRIB_ARRAY_NORMALIZED
+// params returns a single value that is non-zero (true) if fixed-point
+// data types for the vertex attribute array indicated by index are
+// normalized when they are converted to floating point, and 0 (false)
+// otherwise. The initial value is 0.
+//
+// GL.CURRENT_VERTEX_ATTRIB
+// params returns four values that represent the current value for the
+// generic vertex attribute specified by index. Generic vertex
+// attribute 0 is unique in that it has no current state, so an error
+// will be generated if index is 0. The initial value for all other
+// generic vertex attributes is (0,0,0,1).
+//
+// All of the parameters except GL.CURRENT_VERTEX_ATTRIB represent
+// client-side state.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_ENUM is generated if pname is not an
+// accepted value. GL.INVALID_OPERATION is generated if index is 0 and pname
+// is GL.CURRENT_VERTEX_ATTRIB.
+//
+// GetVertexAttribiv is available in GL version 2.0 or greater.
+func (gl *GL) GetVertexAttribiv(index glbase.Attrib, pname glbase.Enum, params []int32) {
+ var params_c [4]int32
+ C.gl4_2compat_glGetVertexAttribiv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetVertexAttribfv returns in params the value of a generic vertex attribute
+// parameter. The generic vertex attribute to be queried is specified by
+// index, and the parameter to be queried is specified by pname.
+//
+// The accepted parameter names are as follows:
+//
+// GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING
+// params returns a single value, the name of the buffer object
+// currently bound to the binding point corresponding to generic vertex
+// attribute array index. If no buffer object is bound, 0 is returned.
+// The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_ENABLED
+// params returns a single value that is non-zero (true) if the vertex
+// attribute array for index is enabled and 0 (false) if it is
+// disabled. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_SIZE
+// params returns a single value, the size of the vertex attribute
+// array for index. The size is the number of values for each element
+// of the vertex attribute array, and it will be 1, 2, 3, or 4. The
+// initial value is 4.
+//
+// GL.VERTEX_ATTRIB_ARRAY_STRIDE
+// params returns a single value, the array stride for (number of bytes
+// between successive elements in) the vertex attribute array for
+// index. A value of 0 indicates that the array elements are stored
+// sequentially in memory. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_TYPE
+// params returns a single value, a symbolic constant indicating the
+// array type for the vertex attribute array for index. Possible values
+// are GL.BYTE, GL.UNSIGNED_BYTE, GL.SHORT, GL.UNSIGNED_SHORT, GL.INT,
+// GL.UNSIGNED_INT, GL.FLOAT, and GL.DOUBLE. The initial value is
+// GL.FLOAT.
+//
+// GL.VERTEX_ATTRIB_ARRAY_NORMALIZED
+// params returns a single value that is non-zero (true) if fixed-point
+// data types for the vertex attribute array indicated by index are
+// normalized when they are converted to floating point, and 0 (false)
+// otherwise. The initial value is 0.
+//
+// GL.CURRENT_VERTEX_ATTRIB
+// params returns four values that represent the current value for the
+// generic vertex attribute specified by index. Generic vertex
+// attribute 0 is unique in that it has no current state, so an error
+// will be generated if index is 0. The initial value for all other
+// generic vertex attributes is (0,0,0,1).
+//
+// All of the parameters except GL.CURRENT_VERTEX_ATTRIB represent
+// client-side state.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_ENUM is generated if pname is not an
+// accepted value. GL.INVALID_OPERATION is generated if index is 0 and pname
+// is GL.CURRENT_VERTEX_ATTRIB.
+//
+// GetVertexAttribfv is available in GL version 2.0 or greater.
+func (gl *GL) GetVertexAttribfv(index glbase.Attrib, pname glbase.Enum, params []float32) {
+ var params_c [4]float32
+ C.gl4_2compat_glGetVertexAttribfv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetVertexAttribdv returns in params the value of a generic vertex attribute
+// parameter. The generic vertex attribute to be queried is specified by
+// index, and the parameter to be queried is specified by pname.
+//
+// The accepted parameter names are as follows:
+//
+// GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING
+// params returns a single value, the name of the buffer object
+// currently bound to the binding point corresponding to generic vertex
+// attribute array index. If no buffer object is bound, 0 is returned.
+// The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_ENABLED
+// params returns a single value that is non-zero (true) if the vertex
+// attribute array for index is enabled and 0 (false) if it is
+// disabled. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_SIZE
+// params returns a single value, the size of the vertex attribute
+// array for index. The size is the number of values for each element
+// of the vertex attribute array, and it will be 1, 2, 3, or 4. The
+// initial value is 4.
+//
+// GL.VERTEX_ATTRIB_ARRAY_STRIDE
+// params returns a single value, the array stride for (number of bytes
+// between successive elements in) the vertex attribute array for
+// index. A value of 0 indicates that the array elements are stored
+// sequentially in memory. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_TYPE
+// params returns a single value, a symbolic constant indicating the
+// array type for the vertex attribute array for index. Possible values
+// are GL.BYTE, GL.UNSIGNED_BYTE, GL.SHORT, GL.UNSIGNED_SHORT, GL.INT,
+// GL.UNSIGNED_INT, GL.FLOAT, and GL.DOUBLE. The initial value is
+// GL.FLOAT.
+//
+// GL.VERTEX_ATTRIB_ARRAY_NORMALIZED
+// params returns a single value that is non-zero (true) if fixed-point
+// data types for the vertex attribute array indicated by index are
+// normalized when they are converted to floating point, and 0 (false)
+// otherwise. The initial value is 0.
+//
+// GL.CURRENT_VERTEX_ATTRIB
+// params returns four values that represent the current value for the
+// generic vertex attribute specified by index. Generic vertex
+// attribute 0 is unique in that it has no current state, so an error
+// will be generated if index is 0. The initial value for all other
+// generic vertex attributes is (0,0,0,1).
+//
+// All of the parameters except GL.CURRENT_VERTEX_ATTRIB represent
+// client-side state.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_ENUM is generated if pname is not an
+// accepted value. GL.INVALID_OPERATION is generated if index is 0 and pname
+// is GL.CURRENT_VERTEX_ATTRIB.
+//
+// GetVertexAttribdv is available in GL version 2.0 or greater.
+func (gl *GL) GetVertexAttribdv(index glbase.Attrib, pname glbase.Enum, params []float64) {
+ var params_c [4]float64
+ C.gl4_2compat_glGetVertexAttribdv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetUniformiv returns in params the value of the specified uniform
+// variable. The type of the uniform variable specified by location
+// determines the number of values returned. If the uniform variable is
+// defined in the shader as a boolean, int, or float, a single value will be
+// returned. If it is defined as a vec2, ivec2, or bvec2, two values will be
+// returned. If it is defined as a vec3, ivec3, or bvec3, three values will
+// be returned, and so on. To query values stored in uniform variables
+// declared as arrays, call GetUniformiv for each element of the array. To
+// query values stored in uniform variables declared as structures, call
+// GetUniformiv for each field in the structure. The values for uniform
+// variables declared as a matrix will be returned in column major order.
+//
+// The locations assigned to uniform variables are not known until the
+// program object is linked. After linking has occurred, the command
+// GetUniformLocation can be used to obtain the location of a uniform
+// variable. This location value can then be passed to GetUniformiv in order
+// to query the current value of the uniform variable. After a program object
+// has been linked successfully, the index values for uniform variables
+// remain fixed until the next link command occurs. The uniform variable
+// values can only be queried after a link if the link was successful.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program
+// object. GL.INVALID_OPERATION is generated if program has not been
+// successfully linked. GL.INVALID_OPERATION is generated if location does
+// not correspond to a valid uniform variable location for the specified
+// program object. GL.INVALID_OPERATION is generated if GetUniformiv is
+// executed between the execution of Begin and the corresponding execution of
+// End.
+//
+// GetUniformiv is available in GL version 2.0 or greater.
+func (gl *GL) GetUniformiv(program glbase.Program, location glbase.Uniform, params []int32) {
+ var params_c [4]int32
+ C.gl4_2compat_glGetUniformiv(gl.funcs, C.GLuint(program), C.GLint(location), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetUniformfv returns in params the value of the specified uniform
+// variable. The type of the uniform variable specified by location
+// determines the number of values returned. If the uniform variable is
+// defined in the shader as a boolean, int, or float, a single value will be
+// returned. If it is defined as a vec2, ivec2, or bvec2, two values will be
+// returned. If it is defined as a vec3, ivec3, or bvec3, three values will
+// be returned, and so on. To query values stored in uniform variables
+// declared as arrays, call GetUniformfv for each element of the array. To
+// query values stored in uniform variables declared as structures, call
+// GetUniformfv for each field in the structure. The values for uniform
+// variables declared as a matrix will be returned in column major order.
+//
+// The locations assigned to uniform variables are not known until the
+// program object is linked. After linking has occurred, the command
+// GetUniformLocation can be used to obtain the location of a uniform
+// variable. This location value can then be passed to GetUniformfv in order
+// to query the current value of the uniform variable. After a program object
+// has been linked successfully, the index values for uniform variables
+// remain fixed until the next link command occurs. The uniform variable
+// values can only be queried after a link if the link was successful.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program
+// object. GL.INVALID_OPERATION is generated if program has not been
+// successfully linked. GL.INVALID_OPERATION is generated if location does
+// not correspond to a valid uniform variable location for the specified
+// program object. GL.INVALID_OPERATION is generated if GetUniformfv is
+// executed between the execution of Begin and the corresponding execution of
+// End.
+//
+// GetUniformfv is available in GL version 2.0 or greater.
+func (gl *GL) GetUniformfv(program glbase.Program, location glbase.Uniform, params []float32) {
+ var params_c [4]float32
+ C.gl4_2compat_glGetUniformfv(gl.funcs, C.GLuint(program), C.GLint(location), (*C.GLfloat)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetUniformLocation returns an integer that represents the location of a
+// specific uniform variable within a program object. name must be an active
+// uniform variable name in program that is not a structure, an array of
+// structures, or a subcomponent of a vector or a matrix. This function
+// returns -1 if name does not correspond to an active uniform variable in
+// program or if name starts with the reserved prefix "gl_".
+//
+// Uniform variables that are structures or arrays of structures may be
+// queried by calling GetUniformLocation for each field within the
+// structure. The array element operator "[]" and the structure field
+// operator "." may be used in name in order to select elements within an
+// array or fields within a structure. The result of using these operators is
+// not allowed to be another structure, an array of structures, or a
+// subcomponent of a vector or a matrix. Except if the last part of name
+// indicates a uniform variable array, the location of the first element of
+// an array can be retrieved by using the name of the array, or by using the
+// name appended by "[0]".
+//
+// The actual locations assigned to uniform variables are not known until the
+// program object is linked successfully. After linking has occurred, the
+// command GetUniformLocation can be used to obtain the location of a
+// uniform variable. This location value can then be passed to Uniform to
+// set the value of the uniform variable or to GetUniform in order to query
+// the current value of the uniform variable. After a program object has been
+// linked successfully, the index values for uniform variables remain fixed
+// until the next link command occurs. Uniform variable locations and values
+// can only be queried after a link if the link was successful.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program object.
+// GL.INVALID_OPERATION is generated if program has not been successfully
+// linked. GL.INVALID_OPERATION is generated if GetUniformLocation is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// GetUniformLocation is available in GL version 2.0 or greater.
+func (gl *GL) GetUniformLocation(program glbase.Program, name string) glbase.Uniform {
+ name_cstr := C.CString(name)
+ glresult := C.gl4_2compat_glGetUniformLocation(gl.funcs, C.GLuint(program), (*C.GLchar)(name_cstr))
+ C.free(unsafe.Pointer(name_cstr))
+ return glbase.Uniform(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetShaderSource.xml
+func (gl *GL) GetShaderSource(shader glbase.Shader, bufSize int32, length []int32, source []byte) {
+ C.gl4_2compat_glGetShaderSource(gl.funcs, C.GLuint(shader), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&source[0])))
+}
+
+// GetShaderInfoLog returns the information log for the specified shader
+// object. The information log for a shader object is modified when the
+// shader is compiled.
+//
+// The information log for a shader object is a string that may contain
+// diagnostic messages, warning messages, and other information about the
+// last compile operation. When a shader object is created, its information
+// log will be a string of length 0, and the size of the current log can be
+// obtained by calling GetShaderiv with the value GL.INFO_LOG_LENGTH.
+//
+// The information log for a shader object is the OpenGL implementer's
+// primary mechanism for conveying information about the compilation process.
+// Therefore, the information log can be helpful to application developers
+// during the development process, even when compilation is successful.
+// Application developers should not expect different OpenGL implementations
+// to produce identical information logs.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader is not a shader
+// object. GL.INVALID_VALUE is generated if maxLength is less than 0.
+// GL.INVALID_OPERATION is generated if GetShaderInfoLog is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// GetShaderInfoLog is available in GL version 2.0 or greater.
+func (gl *GL) GetShaderInfoLog(shader glbase.Shader) []byte {
+ var params [1]int32
+ var length int32
+ gl.GetShaderiv(shader, INFO_LOG_LENGTH, params[:])
+ bufSize := params[0]
+ infoLog := make([]byte, int(bufSize))
+ C.gl4_2compat_glGetShaderInfoLog(gl.funcs, C.GLuint(shader), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length)), (*C.GLchar)(unsafe.Pointer(&infoLog[0])))
+ return infoLog
+}
+
+// GetShaderiv GetShader returns in params the value of a parameter for a specific
+// shader object. The following parameters are defined:
+//
+// GL.SHADER_TYPE
+// params returns GL.VERTEX_SHADER if shader is a vertex shader object,
+// and GL.FRAGMENT_SHADER if shader is a fragment shader object.
+//
+// GL.DELETE_STATUS
+// params returns GL.TRUE if shader is currently flagged for deletion,
+// and GL.FALSE otherwise.
+//
+// GL.COMPILE_STATUS
+// params returns GL.TRUE if the last compile operation on shader was
+// successful, and GL.FALSE otherwise.
+//
+// GL.INFO_LOG_LENGTH
+// params returns the number of characters in the information log for
+// shader including the null termination character (the size of the
+// character buffer required to store the information log). If shader has
+// no information log, a value of 0 is returned.
+//
+// GL.SHADER_SOURCE_LENGTH
+// params returns the length of the concatenation of the source strings
+// that make up the shader source for the shader, including the null
+// termination character. (the size of the character buffer
+// required to store the shader source). If no source code exists, 0 is
+// returned.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader does not refer to a
+// shader object. GL.INVALID_ENUM is generated if pname is not an accepted
+// value. GL.INVALID_OPERATION is generated if GetShader is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// GetShaderiv is available in GL version 2.0 or greater.
+func (gl *GL) GetShaderiv(shader glbase.Shader, pname glbase.Enum, params []int32) {
+ var params_c [4]int32
+ C.gl4_2compat_glGetShaderiv(gl.funcs, C.GLuint(shader), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetProgramInfoLog returns the information log for the specified program
+// object. The information log for a program object is modified when the
+// program object is linked or validated.
+//
+// The information log for a program object is either an empty string, or a
+// string containing information about the last link operation, or a string
+// containing information about the last validation operation. It may contain
+// diagnostic messages, warning messages, and other information. When a
+// program object is created, its information log will be a string of length
+// 0, and the size of the current log can be obtained by calling GetProgramiv
+// with the value GL.INFO_LOG_LENGTH.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated
+// by OpenGL. GL.INVALID_OPERATION is generated if program is not a
+// program object.
+func (gl *GL) GetProgramInfoLog(program glbase.Program) []byte {
+ var params [1]int32
+ var length int32
+ gl.GetProgramiv(program, INFO_LOG_LENGTH, params[:])
+ bufSize := params[0]
+ infoLog := make([]byte, int(bufSize))
+ C.gl4_2compat_glGetProgramInfoLog(gl.funcs, C.GLuint(program), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length)), (*C.GLchar)(unsafe.Pointer(&infoLog[0])))
+ return infoLog
+}
+
+// GetProgramiv returns in params the value of a parameter for a specific
+// program object. The following parameters are defined:
+//
+// GL.DELETE_STATUS
+// params returns GL.TRUE if program is currently flagged for deletion,
+// and GL.FALSE otherwise.
+//
+// GL.LINK_STATUS
+// params returns GL.TRUE if the last link operation on program was
+// successful, and GL.FALSE otherwise.
+//
+// GL.VALIDATE_STATUS
+// params returns GL.TRUE or if the last validation operation on
+// program was successful, and GL.FALSE otherwise.
+//
+// GL.INFO_LOG_LENGTH
+// params returns the number of characters in the information log for
+// program including the null termination character (the size of
+// the character buffer required to store the information log). If
+// program has no information log, a value of 0 is returned.
+//
+// GL.ATTACHED_SHADERS
+// params returns the number of shader objects attached to program.
+//
+// GL.ACTIVE_ATTRIBUTES
+// params returns the number of active attribute variables for program.
+//
+// GL.ACTIVE_ATTRIBUTE_MAX_LENGTH
+// params returns the length of the longest active attribute name for
+// program, including the null termination character (the size of
+// the character buffer required to store the longest attribute name).
+// If no active attributes exist, 0 is returned.
+//
+// GL.ACTIVE_UNIFORMS
+// params returns the number of active uniform variables for program.
+//
+// GL.ACTIVE_UNIFORM_MAX_LENGTH
+// params returns the length of the longest active uniform variable
+// name for program, including the null termination character (i.e.,
+// the size of the character buffer required to store the longest
+// uniform variable name). If no active uniform variables exist, 0 is
+// returned.
+//
+// GL.TRANSFORM_FEEDBACK_BUFFER_MODE
+// params returns a symbolic constant indicating the buffer mode used
+// when transform feedback is active. This may be GL.SEPARATE_ATTRIBS
+// or GL.INTERLEAVED_ATTRIBS.
+//
+// GL.TRANSFORM_FEEDBACK_VARYINGS
+// params returns the number of varying variables to capture in transform
+// feedback mode for the program.
+//
+// GL.TRANSFORM_FEEDBACK_VARYING_MAX_LENGTH
+// params returns the length of the longest variable name to be used for
+// transform feedback, including the null-terminator.
+//
+// GL.GEOMETRY_VERTICES_OUT
+// params returns the maximum number of vertices that the geometry shader in
+// program will output.
+//
+// GL.GEOMETRY_INPUT_TYPE
+// params returns a symbolic constant indicating the primitive type accepted
+// as input to the geometry shader contained in program.
+//
+// GL.GEOMETRY_OUTPUT_TYPE
+// params returns a symbolic constant indicating the primitive type that will
+// be output by the geometry shader contained in program.
+//
+// GL.ACTIVE_UNIFORM_BLOCKS and GL.ACTIVE_UNIFORM_BLOCK_MAX_NAME_LENGTH are
+// available only if the GL version 3.1 or greater.
+//
+// GL.GEOMETRY_VERTICES_OUT, GL.GEOMETRY_INPUT_TYPE and
+// GL.GEOMETRY_OUTPUT_TYPE are accepted only if the GL version is 3.2 or
+// greater.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program does not refer to a
+// program object. GL.INVALID_OPERATION is generated if pname is
+// GL.GEOMETRY_VERTICES_OUT, GL.GEOMETRY_INPUT_TYPE, or
+// GL.GEOMETRY_OUTPUT_TYPE, and program does not contain a geometry shader.
+// GL.INVALID_ENUM is generated if pname is not an accepted value.
+func (gl *GL) GetProgramiv(program glbase.Program, pname glbase.Enum, params []int32) {
+ var params_c [4]int32
+ C.gl4_2compat_glGetProgramiv(gl.funcs, C.GLuint(program), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetAttribLocation queries the previously linked program object specified
+// by program for the attribute variable specified by name and returns the
+// index of the generic vertex attribute that is bound to that attribute
+// variable. If name is a matrix attribute variable, the index of the first
+// column of the matrix is returned. If the named attribute variable is not
+// an active attribute in the specified program object or if name starts with
+// the reserved prefix "gl_", a value of -1 is returned.
+//
+// The association between an attribute variable name and a generic attribute
+// index can be specified at any time by calling BindAttribLocation.
+// Attribute bindings do not go into effect until LinkProgram is called.
+// After a program object has been linked successfully, the index values for
+// attribute variables remain fixed until the next link command occurs. The
+// attribute values can only be queried after a link if the link was
+// successful. GetAttribLocation returns the binding that actually went
+// into effect the last time LinkProgram was called for the specified
+// program object. Attribute bindings that have been specified since the last
+// link operation are not returned by GetAttribLocation.
+//
+// Error GL_INVALID_OPERATION is generated if program is not a value
+// generated by OpenGL. GL_INVALID_OPERATION is generated if program is not
+// a program object. GL_INVALID_OPERATION is generated if program has not
+// been successfully linked. GL_INVALID_OPERATION is generated if
+// GetAttribLocation is executed between the execution of Begin and the
+// corresponding execution of End.
+//
+// GetAttribLocation is available in GL version 2.0 or greater.
+func (gl *GL) GetAttribLocation(program glbase.Program, name string) glbase.Attrib {
+ name_cstr := C.CString(name)
+ glresult := C.gl4_2compat_glGetAttribLocation(gl.funcs, C.GLuint(program), (*C.GLchar)(name_cstr))
+ C.free(unsafe.Pointer(name_cstr))
+ return glbase.Attrib(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetAttachedShaders.xml
+func (gl *GL) GetAttachedShaders(program glbase.Program, maxCount int32, count []int, obj []uint32) {
+ C.gl4_2compat_glGetAttachedShaders(gl.funcs, C.GLuint(program), C.GLsizei(maxCount), (*C.GLsizei)(unsafe.Pointer(&count[0])), (*C.GLuint)(unsafe.Pointer(&obj[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveUniform.xml
+func (gl *GL) GetActiveUniform(program glbase.Program, index uint32, bufSize int32, length []int32, size []int, gltype []glbase.Enum, name []byte) {
+ C.gl4_2compat_glGetActiveUniform(gl.funcs, C.GLuint(program), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLint)(unsafe.Pointer(&size[0])), (*C.GLenum)(unsafe.Pointer(&gltype[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveAttrib.xml
+func (gl *GL) GetActiveAttrib(program glbase.Program, index glbase.Attrib, bufSize int32, length []int32, size []int, gltype []glbase.Enum, name []byte) {
+ C.gl4_2compat_glGetActiveAttrib(gl.funcs, C.GLuint(program), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLint)(unsafe.Pointer(&size[0])), (*C.GLenum)(unsafe.Pointer(&gltype[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEnableVertexAttribArray.xml
+func (gl *GL) EnableVertexAttribArray(index glbase.Attrib) {
+ C.gl4_2compat_glEnableVertexAttribArray(gl.funcs, C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDisableVertexAttribArray.xml
+func (gl *GL) DisableVertexAttribArray(index glbase.Attrib) {
+ C.gl4_2compat_glDisableVertexAttribArray(gl.funcs, C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDetachShader.xml
+func (gl *GL) DetachShader(program glbase.Program, shader glbase.Shader) {
+ C.gl4_2compat_glDetachShader(gl.funcs, C.GLuint(program), C.GLuint(shader))
+}
+
+// DeleteShader frees the memory and invalidates the name associated with
+// the shader object specified by shader. This command effectively undoes the
+// effects of a call to CreateShader.
+//
+// If a shader object to be deleted is attached to a program object, it will
+// be flagged for deletion, but it will not be deleted until it is no longer
+// attached to any program object, for any rendering context (it must
+// be detached from wherever it was attached before it will be deleted). A
+// value of 0 for shader will be silently ignored.
+//
+// To determine whether an object has been flagged for deletion, call
+// GetShader with arguments shader and GL.DELETE_STATUS.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL.
+//
+// DeleteShader is available in GL version 2.0 or greater.
+func (gl *GL) DeleteShader(shader glbase.Shader) {
+ C.gl4_2compat_glDeleteShader(gl.funcs, C.GLuint(shader))
+}
+
+// DeleteProgram frees the memory and invalidates the name associated with
+// the program object specified by program. This command effectively undoes
+// the effects of a call to CreateProgram.
+//
+// If a program object is in use as part of current rendering state, it will
+// be flagged for deletion, but it will not be deleted until it is no longer
+// part of current state for any rendering context. If a program object to be
+// deleted has shader objects attached to it, those shader objects will be
+// automatically detached but not deleted unless they have already been
+// flagged for deletion by a previous call to DeleteShader. A value of 0
+// for program will be silently ignored.
+//
+// To determine whether a program object has been flagged for deletion, call
+// GetProgram with arguments program and GL.DELETE_STATUS.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL.
+//
+// DeleteProgram is available in GL version 2.0 or greater.
+func (gl *GL) DeleteProgram(program glbase.Program) {
+ C.gl4_2compat_glDeleteProgram(gl.funcs, C.GLuint(program))
+}
+
+// CreateShader creates an empty shader object and returns a non-zero value
+// by which it can be referenced. A shader object is used to maintain the
+// source code strings that define a shader. shaderType indicates the type of
+// shader to be created.
+//
+// Two types of shaders are supported. A shader of type GL.VERTEX_SHADER is a
+// shader that is intended to run on the programmable vertex processor and
+// replace the fixed functionality vertex processing in OpenGL. A shader of
+// type GL.FRAGMENT_SHADER is a shader that is intended to run on the
+// programmable fragment processor and replace the fixed functionality
+// fragment processing in OpenGL.
+//
+// When created, a shader object's GL.SHADER_TYPE parameter is set to either
+// GL.VERTEX_SHADER or GL.FRAGMENT_SHADER, depending on the value of
+// shaderType.
+//
+// Like display lists and texture objects, the name space for shader objects
+// may be shared across a set of contexts, as long as the server sides of the
+// contexts share the same address space. If the name space is shared across
+// contexts, any attached objects and the data associated with those attached
+// objects are shared as well.
+//
+// This function returns 0 if an error occurs creating the shader object.
+//
+// Error GL.INVALID_ENUM is generated if shaderType is not an accepted value.
+// GL.INVALID_OPERATION is generated if CreateShader is executed between the
+// execution of Begin and the corresponding execution of End.
+//
+// CreateShader is available in GL version 2.0 or greater.
+func (gl *GL) CreateShader(gltype glbase.Enum) glbase.Shader {
+ glresult := C.gl4_2compat_glCreateShader(gl.funcs, C.GLenum(gltype))
+ return glbase.Shader(glresult)
+}
+
+// CreateProgram creates an empty program object and returns a non-zero
+// value by which it can be referenced. A program object is an object to
+// which shader objects can be attached. This provides a mechanism to specify
+// the shader objects that will be linked to create a program. It also
+// provides a means for checking the compatibility of the shaders that will
+// be used to create a program (for instance, checking the compatibility
+// between a vertex shader and a fragment shader). When no longer needed as
+// part of a program object, shader objects can be detached.
+//
+// One or more executables are created in a program object by successfully
+// attaching shader objects to it with AttachShader, successfully compiling
+// the shader objects with CompileShader, and successfully linking the
+// program object with LinkProgram. These executables are made part of
+// current state when UseProgram is called. Program objects can be deleted
+// by calling DeleteProgram. The memory associated with the program object
+// will be deleted when it is no longer part of current rendering state for
+// any context.
+//
+// Like display lists and texture objects, the name space for program objects
+// may be shared across a set of contexts, as long as the server sides of the
+// contexts share the same address space. If the name space is shared across
+// contexts, any attached objects and the data associated with those attached
+// objects are shared as well.
+//
+// Applications are responsible for providing the synchronization across API
+// calls when objects are accessed from different execution threads.
+//
+// This function returns 0 if an error occurs creating the program object.
+//
+// Error GL.INVALID_OPERATION is generated if CreateProgram is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// CreateProgram is available in GL version 2.0 or greater.
+func (gl *GL) CreateProgram() glbase.Program {
+ glresult := C.gl4_2compat_glCreateProgram(gl.funcs)
+ return glbase.Program(glresult)
+}
+
+// CompileShader compiles the source code strings that have been stored in
+// the shader object specified by shader.
+//
+// The compilation status will be stored as part of the shader object's
+// state. This value will be set to GL.TRUE if the shader was compiled without
+// errors and is ready for use, and GL.FALSE otherwise. It can be queried by
+// calling GetShaderiv with arguments shader and GL.COMPILE_STATUS.
+//
+// Compilation of a shader can fail for a number of reasons as specified by
+// the OpenGL Shading Language Specification. Whether or not the compilation
+// was successful, information about the compilation can be obtained from the
+// shader object's information log by calling GetShaderInfoLog.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader is not a shader
+// object. GL.INVALID_OPERATION is generated if CompileShader is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// CompileShader is available in GL version 2.0 or greater.
+func (gl *GL) CompileShader(shader glbase.Shader) {
+ C.gl4_2compat_glCompileShader(gl.funcs, C.GLuint(shader))
+}
+
+// BindAttribLocation associates a user-defined attribute variable in the program
+// object specified by program with a generic vertex attribute index. The name
+// parameter specifies the name of the vertex shader attribute variable to
+// which index is to be bound. When program is made part of the current state,
+// values provided via the generic vertex attribute index will modify the
+// value of the user-defined attribute variable specified by name.
+//
+// If name refers to a matrix attribute variable, index refers to the first
+// column of the matrix. Other matrix columns are then automatically bound to
+// locations index+1 for a matrix of type mat2; index+1 and index+2 for a
+// matrix of type mat3; and index+1, index+2, and index+3 for a matrix of
+// type mat4.
+//
+// This command makes it possible for vertex shaders to use descriptive names
+// for attribute variables rather than generic variables that are numbered
+// from 0 to GL.MAX_VERTEX_ATTRIBS-1. The values sent to each generic
+// attribute index are part of current state, just like standard vertex
+// attributes such as color, normal, and vertex position. If a different
+// program object is made current by calling UseProgram, the generic vertex
+// attributes are tracked in such a way that the same values will be observed
+// by attributes in the new program object that are also bound to index.
+//
+// Attribute variable name-to-generic attribute index bindings for a program
+// object can be explicitly assigned at any time by calling
+// BindAttribLocation. Attribute bindings do not go into effect until
+// LinkProgram is called. After a program object has been linked
+// successfully, the index values for generic attributes remain fixed (and
+// their values can be queried) until the next link command occurs.
+//
+// Applications are not allowed to bind any of the standard OpenGL vertex
+// attributes using this command, as they are bound automatically when
+// needed. Any attribute binding that occurs after the program object has
+// been linked will not take effect until the next time the program object is
+// linked.
+//
+// If name was bound previously, that information is lost. Thus you cannot
+// bind one user-defined attribute variable to multiple indices, but you can
+// bind multiple user-defined attribute variables to the same index.
+//
+// Applications are allowed to bind more than one user-defined attribute
+// variable to the same generic vertex attribute index. This is called
+// aliasing, and it is allowed only if just one of the aliased attributes is
+// active in the executable program, or if no path through the shader
+// consumes more than one attribute of a set of attributes aliased to the
+// same location. The compiler and linker are allowed to assume that no
+// aliasing is done and are free to employ optimizations that work only in
+// the absence of aliasing. OpenGL implementations are not required to do
+// error checking to detect aliasing. Because there is no way to bind
+// standard attributes, it is not possible to alias generic attributes with
+// conventional ones (except for generic attribute 0).
+//
+// BindAttribLocation can be called before any vertex shader objects are
+// bound to the specified program object. It is also permissible to bind a
+// generic attribute index to an attribute variable name that is never used
+// in a vertex shader.
+//
+// Active attributes that are not explicitly bound will be bound by the
+// linker when LinkProgram is called. The locations assigned can be queried
+// by calling GetAttribLocation.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS.
+// GL.INVALID_OPERATION is generated if name starts with the reserved prefix "gl_".
+// GL.INVALID_VALUE is generated if program is not a value generated by OpenGL.
+// GL.INVALID_OPERATION is generated if program is not a program object.
+// GL.INVALID_OPERATION is generated if BindAttribLocation is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// BindAttribLocation is available in GL version 2.0 or greater.
+func (gl *GL) BindAttribLocation(program glbase.Program, index glbase.Attrib, name string) {
+ name_cstr := C.CString(name)
+ C.gl4_2compat_glBindAttribLocation(gl.funcs, C.GLuint(program), C.GLuint(index), (*C.GLchar)(name_cstr))
+ C.free(unsafe.Pointer(name_cstr))
+}
+
+// AttachShader attaches a shader object to a program object.
+//
+// In order to create an executable, there must be a way to specify the list
+// of things that will be linked together. Program objects provide this
+// mechanism. Shaders that are to be linked together in a program object must
+// first be attached to that program object. This indicates that shader will
+// be included in link operations that will be performed on program.
+//
+// All operations that can be performed on a shader object are valid whether
+// or not the shader object is attached to a program object. It is
+// permissible to attach a shader object to a program object before source
+// code has been loaded into the shader object or before the shader object
+// has been compiled. It is permissible to attach multiple shader objects of
+// the same type because each may contain a portion of the complete shader.
+// It is also permissible to attach a shader object to more than one program
+// object. If a shader object is deleted while it is attached to a program
+// object, it will be flagged for deletion, and deletion will not occur until
+// DetachShader is called to detach it from all program objects to which it
+// is attached.
+//
+// Error GL.INVALID_VALUE is generated if either program or shader is not a
+// value generated by OpenGL. GL.INVALID_OPERATION is generated if program
+// is not a program object. GL.INVALID_OPERATION is generated if shader is
+// not a shader object. GL.INVALID_OPERATION is generated if shader is
+// already attached to program. GL.INVALID_OPERATION is generated if
+// AttachShader is executed between the execution of Begin and the
+// corresponding execution of End.
+//
+// AttachShader is available in GL version 2.0 or greater.
+func (gl *GL) AttachShader(program glbase.Program, shader glbase.Shader) {
+ C.gl4_2compat_glAttachShader(gl.funcs, C.GLuint(program), C.GLuint(shader))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glStencilMaskSeparate.xml
+func (gl *GL) StencilMaskSeparate(face glbase.Enum, mask uint32) {
+ C.gl4_2compat_glStencilMaskSeparate(gl.funcs, C.GLenum(face), C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glStencilFuncSeparate.xml
+func (gl *GL) StencilFuncSeparate(face, glfunc glbase.Enum, ref int32, mask uint32) {
+ C.gl4_2compat_glStencilFuncSeparate(gl.funcs, C.GLenum(face), C.GLenum(glfunc), C.GLint(ref), C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glStencilOpSeparate.xml
+func (gl *GL) StencilOpSeparate(face, sfail, dpfail, dppass glbase.Enum) {
+ C.gl4_2compat_glStencilOpSeparate(gl.funcs, C.GLenum(face), C.GLenum(sfail), C.GLenum(dpfail), C.GLenum(dppass))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawBuffers.xml
+func (gl *GL) DrawBuffers(n int, bufs []glbase.Enum) {
+ C.gl4_2compat_glDrawBuffers(gl.funcs, C.GLsizei(n), (*C.GLenum)(unsafe.Pointer(&bufs[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendEquationSeparate.xml
+func (gl *GL) BlendEquationSeparate(modeRGB, modeAlpha glbase.Enum) {
+ C.gl4_2compat_glBlendEquationSeparate(gl.funcs, C.GLenum(modeRGB), C.GLenum(modeAlpha))
+}
+
+// UniformMatrix4x3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix4x3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix4x3fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(4*3) != 0 {
+ panic("invalid value length for UniformMatrix4x3fv")
+ }
+ count := len(value) / (4 * 3)
+ C.gl4_2compat_glUniformMatrix4x3fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix3x4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix3x4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix3x4fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(3*4) != 0 {
+ panic("invalid value length for UniformMatrix3x4fv")
+ }
+ count := len(value) / (3 * 4)
+ C.gl4_2compat_glUniformMatrix3x4fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix4x2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix4x2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix4x2fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(4*2) != 0 {
+ panic("invalid value length for UniformMatrix4x2fv")
+ }
+ count := len(value) / (4 * 2)
+ C.gl4_2compat_glUniformMatrix4x2fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix2x4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix2x4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix2x4fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(2*4) != 0 {
+ panic("invalid value length for UniformMatrix2x4fv")
+ }
+ count := len(value) / (2 * 4)
+ C.gl4_2compat_glUniformMatrix2x4fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix3x2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix3x2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix3x2fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(3*2) != 0 {
+ panic("invalid value length for UniformMatrix3x2fv")
+ }
+ count := len(value) / (3 * 2)
+ C.gl4_2compat_glUniformMatrix3x2fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix2x3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix2x3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix2x3fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(2*3) != 0 {
+ panic("invalid value length for UniformMatrix2x3fv")
+ }
+ count := len(value) / (2 * 3)
+ C.gl4_2compat_glUniformMatrix2x3fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsVertexArray.xml
+func (gl *GL) IsVertexArray(array uint32) bool {
+ glresult := C.gl4_2compat_glIsVertexArray(gl.funcs, C.GLuint(array))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGenVertexArrays.xml
+func (gl *GL) GenVertexArrays(n int, arrays []uint32) {
+ C.gl4_2compat_glGenVertexArrays(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&arrays[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDeleteVertexArrays.xml
+func (gl *GL) DeleteVertexArrays(n int, arrays []uint32) {
+ C.gl4_2compat_glDeleteVertexArrays(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&arrays[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindVertexArray.xml
+func (gl *GL) BindVertexArray(array uint32) {
+ C.gl4_2compat_glBindVertexArray(gl.funcs, C.GLuint(array))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFlushMappedBufferRange.xml
+func (gl *GL) FlushMappedBufferRange(target glbase.Enum, offset, length int) {
+ C.gl4_2compat_glFlushMappedBufferRange(gl.funcs, C.GLenum(target), C.GLintptr(offset), C.GLsizeiptr(length))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFramebufferTextureLayer.xml
+func (gl *GL) FramebufferTextureLayer(target, attachment glbase.Enum, texture glbase.Texture, level int, layer int32) {
+ C.gl4_2compat_glFramebufferTextureLayer(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLuint(texture), C.GLint(level), C.GLint(layer))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRenderbufferStorageMultisample.xml
+func (gl *GL) RenderbufferStorageMultisample(target glbase.Enum, samples int32, internalFormat glbase.Enum, width, height int) {
+ C.gl4_2compat_glRenderbufferStorageMultisample(gl.funcs, C.GLenum(target), C.GLsizei(samples), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlitFramebuffer.xml
+func (gl *GL) BlitFramebuffer(srcX0, srcY0, srcX1, srcY1, dstX0, dstY0, dstX1, dstY1 int32, mask glbase.Bitfield, filter glbase.Enum) {
+ C.gl4_2compat_glBlitFramebuffer(gl.funcs, C.GLint(srcX0), C.GLint(srcY0), C.GLint(srcX1), C.GLint(srcY1), C.GLint(dstX0), C.GLint(dstY0), C.GLint(dstX1), C.GLint(dstY1), C.GLbitfield(mask), C.GLenum(filter))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGenerateMipmap.xml
+func (gl *GL) GenerateMipmap(target glbase.Enum) {
+ C.gl4_2compat_glGenerateMipmap(gl.funcs, C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetFramebufferAttachmentParameteriv.xml
+func (gl *GL) GetFramebufferAttachmentParameteriv(target, attachment, pname glbase.Enum, params []int32) {
+ C.gl4_2compat_glGetFramebufferAttachmentParameteriv(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFramebufferRenderbuffer.xml
+func (gl *GL) FramebufferRenderbuffer(target, attachment, renderbuffertarget glbase.Enum, renderbuffer glbase.Renderbuffer) {
+ C.gl4_2compat_glFramebufferRenderbuffer(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(renderbuffertarget), C.GLuint(renderbuffer))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFramebufferTexture3D.xml
+func (gl *GL) FramebufferTexture3D(target, attachment, textarget glbase.Enum, texture glbase.Texture, level int, zoffset int32) {
+ C.gl4_2compat_glFramebufferTexture3D(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(textarget), C.GLuint(texture), C.GLint(level), C.GLint(zoffset))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFramebufferTexture2D.xml
+func (gl *GL) FramebufferTexture2D(target, attachment, textarget glbase.Enum, texture glbase.Texture, level int) {
+ C.gl4_2compat_glFramebufferTexture2D(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(textarget), C.GLuint(texture), C.GLint(level))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFramebufferTexture1D.xml
+func (gl *GL) FramebufferTexture1D(target, attachment, textarget glbase.Enum, texture glbase.Texture, level int) {
+ C.gl4_2compat_glFramebufferTexture1D(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(textarget), C.GLuint(texture), C.GLint(level))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCheckFramebufferStatus.xml
+func (gl *GL) CheckFramebufferStatus(target glbase.Enum) glbase.Enum {
+ glresult := C.gl4_2compat_glCheckFramebufferStatus(gl.funcs, C.GLenum(target))
+ return glbase.Enum(glresult)
+}
+
+// GenFramebuffers returns n framebuffer object names in ids. There is no
+// guarantee that the names form a contiguous set of integers; however, it is
+// guaranteed that none of the returned names was in use immediately before
+// the call to GenFramebuffers.
+//
+// Framebuffer object names returned by a call to GenFramebuffers are not
+// returned by subsequent calls, unless they are first deleted with
+// DeleteFramebuffers.
+//
+// The names returned in ids are marked as used, for the purposes of
+// GenFramebuffers only, but they acquire state and type only when they are
+// first bound.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+func (gl *GL) GenFramebuffers(n int) []glbase.Framebuffer {
+ if n == 0 {
+ return nil
+ }
+ framebuffers := make([]glbase.Framebuffer, n)
+ C.gl4_2compat_glGenFramebuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&framebuffers[0])))
+ return framebuffers
+}
+
+// DeleteFramebuffers deletes the framebuffer objects whose names are
+// stored in the framebuffers slice. The name zero is reserved by the GL and
+// is silently ignored, should it occur in framebuffers, as are other unused
+// names. Once a framebuffer object is deleted, its name is again unused and
+// it has no attachments. If a framebuffer that is currently bound to one or
+// more of the targets GL.DRAW_FRAMEBUFFER or GL.READ_FRAMEBUFFER is deleted,
+// it is as though BindFramebuffer had been executed with the corresponding
+// target and framebuffer zero.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// DeleteFramebuffers is available in GL version 3.0 or greater.
+func (gl *GL) DeleteFramebuffers(framebuffers []glbase.Framebuffer) {
+ n := len(framebuffers)
+ if n == 0 {
+ return
+ }
+ C.gl4_2compat_glDeleteFramebuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&framebuffers[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindFramebuffer.xml
+func (gl *GL) BindFramebuffer(target glbase.Enum, framebuffer glbase.Framebuffer) {
+ C.gl4_2compat_glBindFramebuffer(gl.funcs, C.GLenum(target), C.GLuint(framebuffer))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsFramebuffer.xml
+func (gl *GL) IsFramebuffer(framebuffer glbase.Framebuffer) bool {
+ glresult := C.gl4_2compat_glIsFramebuffer(gl.funcs, C.GLuint(framebuffer))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetRenderbufferParameteriv.xml
+func (gl *GL) GetRenderbufferParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl4_2compat_glGetRenderbufferParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRenderbufferStorage.xml
+func (gl *GL) RenderbufferStorage(target, internalFormat glbase.Enum, width, height int) {
+ C.gl4_2compat_glRenderbufferStorage(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height))
+}
+
+// GenRenderbuffers returns n renderbuffer object names in renderbuffers.
+// There is no guarantee that the names form a contiguous set of integers;
+// however, it is guaranteed that none of the returned names was in use
+// immediately before the call to GenRenderbuffers.
+//
+// Renderbuffer object names returned by a call to GenRenderbuffers are not
+// returned by subsequent calls, unless they are first deleted with
+// DeleteRenderbuffers.
+//
+// The names returned in renderbuffers are marked as used, for the purposes
+// of GenRenderbuffers only, but they acquire state and type only when they
+// are first bound.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// GenRenderbuffers is available in GL version 3.0 or greater.
+func (gl *GL) GenRenderbuffers(n int) []glbase.Renderbuffer {
+ if n == 0 {
+ return nil
+ }
+ renderbuffers := make([]glbase.Renderbuffer, n)
+ C.gl4_2compat_glGenRenderbuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&renderbuffers[0])))
+ return renderbuffers
+}
+
+// DeleteRenderbuffers deletes the renderbuffer objects whose names are stored
+// in the renderbuffers slice. The name zero is reserved by the GL and
+// is silently ignored, should it occur in renderbuffers, as are other unused
+// names. Once a renderbuffer object is deleted, its name is again unused and
+// it has no contents. If a renderbuffer that is currently bound to the
+// target GL.RENDERBUFFER is deleted, it is as though BindRenderbuffer had
+// been executed with a target of GL.RENDERBUFFER and a name of zero.
+//
+// If a renderbuffer object is attached to one or more attachment points in
+// the currently bound framebuffer, then it as if FramebufferRenderbuffer
+// had been called, with a renderbuffer of zero for each attachment point to
+// which this image was attached in the currently bound framebuffer. In other
+// words, this renderbuffer object is first detached from all attachment
+// ponits in the currently bound framebuffer. Note that the renderbuffer
+// image is specifically not detached from any non-bound framebuffers.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// DeleteRenderbuffers is available in GL version 3.0 or greater.
+func (gl *GL) DeleteRenderbuffers(renderbuffers []glbase.Renderbuffer) {
+ n := len(renderbuffers)
+ if n == 0 {
+ return
+ }
+ C.gl4_2compat_glDeleteRenderbuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&renderbuffers[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindRenderbuffer.xml
+func (gl *GL) BindRenderbuffer(target glbase.Enum, renderbuffer glbase.Renderbuffer) {
+ C.gl4_2compat_glBindRenderbuffer(gl.funcs, C.GLenum(target), C.GLuint(renderbuffer))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsRenderbuffer.xml
+func (gl *GL) IsRenderbuffer(renderbuffer glbase.Renderbuffer) bool {
+ glresult := C.gl4_2compat_glIsRenderbuffer(gl.funcs, C.GLuint(renderbuffer))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearBufferfi.xml
+func (gl *GL) ClearBufferfi(buffer glbase.Enum, drawbuffer int32, depth float32, stencil int32) {
+ C.gl4_2compat_glClearBufferfi(gl.funcs, C.GLenum(buffer), C.GLint(drawbuffer), C.GLfloat(depth), C.GLint(stencil))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearBufferfv.xml
+func (gl *GL) ClearBufferfv(buffer glbase.Enum, drawbuffer int32, value []float32) {
+ C.gl4_2compat_glClearBufferfv(gl.funcs, C.GLenum(buffer), C.GLint(drawbuffer), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearBufferuiv.xml
+func (gl *GL) ClearBufferuiv(buffer glbase.Enum, drawbuffer int32, value []uint32) {
+ C.gl4_2compat_glClearBufferuiv(gl.funcs, C.GLenum(buffer), C.GLint(drawbuffer), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearBufferiv.xml
+func (gl *GL) ClearBufferiv(buffer glbase.Enum, drawbuffer int32, value []int32) {
+ C.gl4_2compat_glClearBufferiv(gl.funcs, C.GLenum(buffer), C.GLint(drawbuffer), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexParameterIuiv.xml
+func (gl *GL) GetTexParameterIuiv(target, pname glbase.Enum, params []uint32) {
+ C.gl4_2compat_glGetTexParameterIuiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexParameterIiv.xml
+func (gl *GL) GetTexParameterIiv(target, pname glbase.Enum, params []int32) {
+ C.gl4_2compat_glGetTexParameterIiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexParameterIuiv.xml
+func (gl *GL) TexParameterIuiv(target, pname glbase.Enum, params []uint32) {
+ C.gl4_2compat_glTexParameterIuiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexParameterIiv.xml
+func (gl *GL) TexParameterIiv(target, pname glbase.Enum, params []int32) {
+ C.gl4_2compat_glTexParameterIiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// Uniform4uiv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform4uiv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4uiv(location glbase.Uniform, value []uint32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%4 != 0 {
+ panic("invalid value length for Uniform4uiv")
+ }
+ count := len(value) / 4
+ C.gl4_2compat_glUniform4uiv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform3uiv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform3uiv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3uiv(location glbase.Uniform, value []uint32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%3 != 0 {
+ panic("invalid value length for Uniform3uiv")
+ }
+ count := len(value) / 3
+ C.gl4_2compat_glUniform3uiv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform2uiv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform2uiv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2uiv(location glbase.Uniform, value []uint32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%2 != 0 {
+ panic("invalid value length for Uniform2uiv")
+ }
+ count := len(value) / 2
+ C.gl4_2compat_glUniform2uiv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform1uiv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform1uiv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1uiv(location glbase.Uniform, value []uint32) {
+ if len(value) == 0 {
+ return
+ }
+ count := len(value)
+ C.gl4_2compat_glUniform1uiv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4ui modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform4ui operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4ui(location glbase.Uniform, v0, v1, v2, v3 uint32) {
+ C.gl4_2compat_glUniform4ui(gl.funcs, C.GLint(location), C.GLuint(v0), C.GLuint(v1), C.GLuint(v2), C.GLuint(v3))
+}
+
+// Uniform3ui modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform3ui operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3ui(location glbase.Uniform, v0, v1, v2 uint32) {
+ C.gl4_2compat_glUniform3ui(gl.funcs, C.GLint(location), C.GLuint(v0), C.GLuint(v1), C.GLuint(v2))
+}
+
+// Uniform2ui modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform2ui operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2ui(location glbase.Uniform, v0, v1 uint32) {
+ C.gl4_2compat_glUniform2ui(gl.funcs, C.GLint(location), C.GLuint(v0), C.GLuint(v1))
+}
+
+// Uniform1ui modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform1ui operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1ui(location glbase.Uniform, v0 uint32) {
+ C.gl4_2compat_glUniform1ui(gl.funcs, C.GLint(location), C.GLuint(v0))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetFragDataLocation.xml
+func (gl *GL) GetFragDataLocation(program glbase.Program, name []byte) int32 {
+ glresult := C.gl4_2compat_glGetFragDataLocation(gl.funcs, C.GLuint(program), (*C.GLchar)(unsafe.Pointer(&name[0])))
+ return int32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindFragDataLocation.xml
+func (gl *GL) BindFragDataLocation(program glbase.Program, color uint32, name []byte) {
+ C.gl4_2compat_glBindFragDataLocation(gl.funcs, C.GLuint(program), C.GLuint(color), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetUniformuiv.xml
+func (gl *GL) GetUniformuiv(program glbase.Program, location glbase.Uniform, params []uint32) {
+ C.gl4_2compat_glGetUniformuiv(gl.funcs, C.GLuint(program), C.GLint(location), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetVertexAttribIuiv.xml
+func (gl *GL) GetVertexAttribIuiv(index glbase.Attrib, pname glbase.Enum, params []uint32) {
+ C.gl4_2compat_glGetVertexAttribIuiv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetVertexAttribIiv.xml
+func (gl *GL) GetVertexAttribIiv(index glbase.Attrib, pname glbase.Enum, params []int32) {
+ C.gl4_2compat_glGetVertexAttribIiv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribIPointer.xml
+func (gl *GL) VertexAttribIPointer(index glbase.Attrib, size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2compat_glVertexAttribIPointer(gl.funcs, C.GLuint(index), C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEndConditionalRender.xml
+func (gl *GL) EndConditionalRender() {
+ C.gl4_2compat_glEndConditionalRender(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBeginConditionalRender.xml
+func (gl *GL) BeginConditionalRender(id uint32, mode glbase.Enum) {
+ C.gl4_2compat_glBeginConditionalRender(gl.funcs, C.GLuint(id), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClampColor.xml
+func (gl *GL) ClampColor(target, clamp glbase.Enum) {
+ C.gl4_2compat_glClampColor(gl.funcs, C.GLenum(target), C.GLenum(clamp))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTransformFeedbackVarying.xml
+func (gl *GL) GetTransformFeedbackVarying(program glbase.Program, index uint32, bufSize int32, length []int32, size []int, gltype []glbase.Enum, name []byte) {
+ C.gl4_2compat_glGetTransformFeedbackVarying(gl.funcs, C.GLuint(program), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLsizei)(unsafe.Pointer(&size[0])), (*C.GLenum)(unsafe.Pointer(&gltype[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindBufferBase.xml
+func (gl *GL) BindBufferBase(target glbase.Enum, index uint32, buffer glbase.Buffer) {
+ C.gl4_2compat_glBindBufferBase(gl.funcs, C.GLenum(target), C.GLuint(index), C.GLuint(buffer))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindBufferRange.xml
+func (gl *GL) BindBufferRange(target glbase.Enum, index uint32, buffer glbase.Buffer, offset, size int) {
+ C.gl4_2compat_glBindBufferRange(gl.funcs, C.GLenum(target), C.GLuint(index), C.GLuint(buffer), C.GLintptr(offset), C.GLsizeiptr(size))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEndTransformFeedback.xml
+func (gl *GL) EndTransformFeedback() {
+ C.gl4_2compat_glEndTransformFeedback(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBeginTransformFeedback.xml
+func (gl *GL) BeginTransformFeedback(primitiveMode glbase.Enum) {
+ C.gl4_2compat_glBeginTransformFeedback(gl.funcs, C.GLenum(primitiveMode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsEnabledi.xml
+func (gl *GL) IsEnabledi(target glbase.Enum, index uint32) bool {
+ glresult := C.gl4_2compat_glIsEnabledi(gl.funcs, C.GLenum(target), C.GLuint(index))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDisablei.xml
+func (gl *GL) Disablei(target glbase.Enum, index uint32) {
+ C.gl4_2compat_glDisablei(gl.funcs, C.GLenum(target), C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEnablei.xml
+func (gl *GL) Enablei(target glbase.Enum, index uint32) {
+ C.gl4_2compat_glEnablei(gl.funcs, C.GLenum(target), C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetIntegeri_v.xml
+func (gl *GL) GetIntegeri_v(target glbase.Enum, index uint32, data []int32) {
+ C.gl4_2compat_glGetIntegeri_v(gl.funcs, C.GLenum(target), C.GLuint(index), (*C.GLint)(unsafe.Pointer(&data[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetBooleani_v.xml
+func (gl *GL) GetBooleani_v(target glbase.Enum, index uint32, data []bool) {
+ C.gl4_2compat_glGetBooleani_v(gl.funcs, C.GLenum(target), C.GLuint(index), (*C.GLboolean)(unsafe.Pointer(&data[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorMaski.xml
+func (gl *GL) ColorMaski(index uint32, r, g, b, a bool) {
+ C.gl4_2compat_glColorMaski(gl.funcs, C.GLuint(index), *(*C.GLboolean)(unsafe.Pointer(&r)), *(*C.GLboolean)(unsafe.Pointer(&g)), *(*C.GLboolean)(unsafe.Pointer(&b)), *(*C.GLboolean)(unsafe.Pointer(&a)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyBufferSubData.xml
+func (gl *GL) CopyBufferSubData(readTarget, writeTarget glbase.Enum, readOffset, writeOffset, size int) {
+ C.gl4_2compat_glCopyBufferSubData(gl.funcs, C.GLenum(readTarget), C.GLenum(writeTarget), C.GLintptr(readOffset), C.GLintptr(writeOffset), C.GLsizeiptr(size))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformBlockBinding.xml
+func (gl *GL) UniformBlockBinding(program glbase.Program, v0, v1 uint32) {
+ C.gl4_2compat_glUniformBlockBinding(gl.funcs, C.GLuint(program), C.GLuint(v0), C.GLuint(v1))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveUniformBlockName.xml
+func (gl *GL) GetActiveUniformBlockName(program glbase.Program, uniformBlockIndex uint32, bufSize int32, length []int32, uniformBlockName []byte) {
+ C.gl4_2compat_glGetActiveUniformBlockName(gl.funcs, C.GLuint(program), C.GLuint(uniformBlockIndex), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&uniformBlockName[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveUniformBlockiv.xml
+func (gl *GL) GetActiveUniformBlockiv(program glbase.Program, uniformBlockIndex uint32, pname glbase.Enum, params []int32) {
+ C.gl4_2compat_glGetActiveUniformBlockiv(gl.funcs, C.GLuint(program), C.GLuint(uniformBlockIndex), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetUniformBlockIndex.xml
+func (gl *GL) GetUniformBlockIndex(program glbase.Program, uniformBlockName []byte) uint32 {
+ glresult := C.gl4_2compat_glGetUniformBlockIndex(gl.funcs, C.GLuint(program), (*C.GLchar)(unsafe.Pointer(&uniformBlockName[0])))
+ return uint32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveUniformName.xml
+func (gl *GL) GetActiveUniformName(program glbase.Program, uniformIndex uint32, bufSize int32, length []int32, uniformName []byte) {
+ C.gl4_2compat_glGetActiveUniformName(gl.funcs, C.GLuint(program), C.GLuint(uniformIndex), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&uniformName[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveUniformsiv.xml
+func (gl *GL) GetActiveUniformsiv(program glbase.Program, uniformCount int32, uniformIndices []uint32, pname glbase.Enum, params []int32) {
+ C.gl4_2compat_glGetActiveUniformsiv(gl.funcs, C.GLuint(program), C.GLsizei(uniformCount), (*C.GLuint)(unsafe.Pointer(&uniformIndices[0])), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPrimitiveRestartIndex.xml
+func (gl *GL) PrimitiveRestartIndex(index uint32) {
+ C.gl4_2compat_glPrimitiveRestartIndex(gl.funcs, C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexBuffer.xml
+func (gl *GL) TexBuffer(target, internalFormat glbase.Enum, buffer glbase.Buffer) {
+ C.gl4_2compat_glTexBuffer(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLuint(buffer))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawElementsInstanced.xml
+func (gl *GL) DrawElementsInstanced(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}, instancecount int32) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2compat_glDrawElementsInstanced(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr, C.GLsizei(instancecount))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawArraysInstanced.xml
+func (gl *GL) DrawArraysInstanced(mode glbase.Enum, first, count int, instancecount int32) {
+ C.gl4_2compat_glDrawArraysInstanced(gl.funcs, C.GLenum(mode), C.GLint(first), C.GLsizei(count), C.GLsizei(instancecount))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSampleMaski.xml
+func (gl *GL) SampleMaski(index uint32, mask glbase.Bitfield) {
+ C.gl4_2compat_glSampleMaski(gl.funcs, C.GLuint(index), C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetMultisamplefv.xml
+func (gl *GL) GetMultisamplefv(pname glbase.Enum, index uint32, val []float32) {
+ C.gl4_2compat_glGetMultisamplefv(gl.funcs, C.GLenum(pname), C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&val[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexImage3DMultisample.xml
+func (gl *GL) TexImage3DMultisample(target glbase.Enum, samples, internalFormat int32, width, height int, depth int32, fixedsamplelocations bool) {
+ C.gl4_2compat_glTexImage3DMultisample(gl.funcs, C.GLenum(target), C.GLsizei(samples), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), *(*C.GLboolean)(unsafe.Pointer(&fixedsamplelocations)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexImage2DMultisample.xml
+func (gl *GL) TexImage2DMultisample(target glbase.Enum, samples, internalFormat int32, width, height int, fixedsamplelocations bool) {
+ C.gl4_2compat_glTexImage2DMultisample(gl.funcs, C.GLenum(target), C.GLsizei(samples), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), *(*C.GLboolean)(unsafe.Pointer(&fixedsamplelocations)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetSynciv.xml
+func (gl *GL) GetSynciv(sync glbase.Sync, pname glbase.Enum, bufSize int32, length, values []int32) {
+ C.gl4_2compat_glGetSynciv(gl.funcs, C.GLsync(unsafe.Pointer(sync)), C.GLenum(pname), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLint)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetInteger64v.xml
+func (gl *GL) GetInteger64v(pname glbase.Enum, params []int64) {
+ C.gl4_2compat_glGetInteger64v(gl.funcs, C.GLenum(pname), (*C.GLint64)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWaitSync.xml
+func (gl *GL) WaitSync(sync glbase.Sync, flags glbase.Bitfield, timeout uint64) {
+ C.gl4_2compat_glWaitSync(gl.funcs, C.GLsync(unsafe.Pointer(sync)), C.GLbitfield(flags), C.GLuint64(timeout))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClientWaitSync.xml
+func (gl *GL) ClientWaitSync(sync glbase.Sync, flags glbase.Bitfield, timeout uint64) glbase.Enum {
+ glresult := C.gl4_2compat_glClientWaitSync(gl.funcs, C.GLsync(unsafe.Pointer(sync)), C.GLbitfield(flags), C.GLuint64(timeout))
+ return glbase.Enum(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDeleteSync.xml
+func (gl *GL) DeleteSync(sync glbase.Sync) {
+ C.gl4_2compat_glDeleteSync(gl.funcs, C.GLsync(unsafe.Pointer(sync)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsSync.xml
+func (gl *GL) IsSync(sync glbase.Sync) bool {
+ glresult := C.gl4_2compat_glIsSync(gl.funcs, C.GLsync(unsafe.Pointer(sync)))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFenceSync.xml
+func (gl *GL) FenceSync(condition glbase.Enum, flags glbase.Bitfield) glbase.Sync {
+ glresult := C.gl4_2compat_glFenceSync(gl.funcs, C.GLenum(condition), C.GLbitfield(flags))
+ return glbase.Sync(unsafe.Pointer(glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProvokingVertex.xml
+func (gl *GL) ProvokingVertex(mode glbase.Enum) {
+ C.gl4_2compat_glProvokingVertex(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawElementsInstancedBaseVertex.xml
+func (gl *GL) DrawElementsInstancedBaseVertex(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}, instancecount, basevertex int32) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2compat_glDrawElementsInstancedBaseVertex(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr, C.GLsizei(instancecount), C.GLint(basevertex))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawRangeElementsBaseVertex.xml
+func (gl *GL) DrawRangeElementsBaseVertex(mode glbase.Enum, start, end uint32, count int, gltype glbase.Enum, indices interface{}, basevertex int32) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2compat_glDrawRangeElementsBaseVertex(gl.funcs, C.GLenum(mode), C.GLuint(start), C.GLuint(end), C.GLsizei(count), C.GLenum(gltype), indices_ptr, C.GLint(basevertex))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawElementsBaseVertex.xml
+func (gl *GL) DrawElementsBaseVertex(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}, basevertex int32) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2compat_glDrawElementsBaseVertex(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr, C.GLint(basevertex))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFramebufferTexture.xml
+func (gl *GL) FramebufferTexture(target, attachment glbase.Enum, texture glbase.Texture, level int) {
+ C.gl4_2compat_glFramebufferTexture(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLuint(texture), C.GLint(level))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetBufferParameteri64v.xml
+func (gl *GL) GetBufferParameteri64v(target, pname glbase.Enum, params []int64) {
+ C.gl4_2compat_glGetBufferParameteri64v(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint64)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetInteger64i_v.xml
+func (gl *GL) GetInteger64i_v(target glbase.Enum, index uint32, data []int64) {
+ C.gl4_2compat_glGetInteger64i_v(gl.funcs, C.GLenum(target), C.GLuint(index), (*C.GLint64)(unsafe.Pointer(&data[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP4uiv.xml
+func (gl *GL) VertexAttribP4uiv(index glbase.Attrib, gltype glbase.Enum, normalized bool, value []uint32) {
+ C.gl4_2compat_glVertexAttribP4uiv(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP4ui.xml
+func (gl *GL) VertexAttribP4ui(index glbase.Attrib, gltype glbase.Enum, normalized bool, value uint32) {
+ C.gl4_2compat_glVertexAttribP4ui(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP3uiv.xml
+func (gl *GL) VertexAttribP3uiv(index glbase.Attrib, gltype glbase.Enum, normalized bool, value []uint32) {
+ C.gl4_2compat_glVertexAttribP3uiv(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP3ui.xml
+func (gl *GL) VertexAttribP3ui(index glbase.Attrib, gltype glbase.Enum, normalized bool, value uint32) {
+ C.gl4_2compat_glVertexAttribP3ui(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP2uiv.xml
+func (gl *GL) VertexAttribP2uiv(index glbase.Attrib, gltype glbase.Enum, normalized bool, value []uint32) {
+ C.gl4_2compat_glVertexAttribP2uiv(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP2ui.xml
+func (gl *GL) VertexAttribP2ui(index glbase.Attrib, gltype glbase.Enum, normalized bool, value uint32) {
+ C.gl4_2compat_glVertexAttribP2ui(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP1uiv.xml
+func (gl *GL) VertexAttribP1uiv(index glbase.Attrib, gltype glbase.Enum, normalized bool, value []uint32) {
+ C.gl4_2compat_glVertexAttribP1uiv(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP1ui.xml
+func (gl *GL) VertexAttribP1ui(index glbase.Attrib, gltype glbase.Enum, normalized bool, value uint32) {
+ C.gl4_2compat_glVertexAttribP1ui(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColorP3uiv.xml
+func (gl *GL) SecondaryColorP3uiv(gltype glbase.Enum, color []uint32) {
+ C.gl4_2compat_glSecondaryColorP3uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&color[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColorP3ui.xml
+func (gl *GL) SecondaryColorP3ui(gltype glbase.Enum, color uint32) {
+ C.gl4_2compat_glSecondaryColorP3ui(gl.funcs, C.GLenum(gltype), C.GLuint(color))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorP4uiv.xml
+func (gl *GL) ColorP4uiv(gltype glbase.Enum, color []uint32) {
+ C.gl4_2compat_glColorP4uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&color[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorP4ui.xml
+func (gl *GL) ColorP4ui(gltype glbase.Enum, color uint32) {
+ C.gl4_2compat_glColorP4ui(gl.funcs, C.GLenum(gltype), C.GLuint(color))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorP3uiv.xml
+func (gl *GL) ColorP3uiv(gltype glbase.Enum, color []uint32) {
+ C.gl4_2compat_glColorP3uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&color[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorP3ui.xml
+func (gl *GL) ColorP3ui(gltype glbase.Enum, color uint32) {
+ C.gl4_2compat_glColorP3ui(gl.funcs, C.GLenum(gltype), C.GLuint(color))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNormalP3uiv.xml
+func (gl *GL) NormalP3uiv(gltype glbase.Enum, coords []uint32) {
+ C.gl4_2compat_glNormalP3uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNormalP3ui.xml
+func (gl *GL) NormalP3ui(gltype glbase.Enum, coords uint32) {
+ C.gl4_2compat_glNormalP3ui(gl.funcs, C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP4uiv.xml
+func (gl *GL) MultiTexCoordP4uiv(texture, gltype glbase.Enum, coords []uint32) {
+ C.gl4_2compat_glMultiTexCoordP4uiv(gl.funcs, C.GLenum(texture), C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP4ui.xml
+func (gl *GL) MultiTexCoordP4ui(texture, gltype glbase.Enum, coords uint32) {
+ C.gl4_2compat_glMultiTexCoordP4ui(gl.funcs, C.GLenum(texture), C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP3uiv.xml
+func (gl *GL) MultiTexCoordP3uiv(texture, gltype glbase.Enum, coords []uint32) {
+ C.gl4_2compat_glMultiTexCoordP3uiv(gl.funcs, C.GLenum(texture), C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP3ui.xml
+func (gl *GL) MultiTexCoordP3ui(texture, gltype glbase.Enum, coords uint32) {
+ C.gl4_2compat_glMultiTexCoordP3ui(gl.funcs, C.GLenum(texture), C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP2uiv.xml
+func (gl *GL) MultiTexCoordP2uiv(texture, gltype glbase.Enum, coords []uint32) {
+ C.gl4_2compat_glMultiTexCoordP2uiv(gl.funcs, C.GLenum(texture), C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP2ui.xml
+func (gl *GL) MultiTexCoordP2ui(texture, gltype glbase.Enum, coords uint32) {
+ C.gl4_2compat_glMultiTexCoordP2ui(gl.funcs, C.GLenum(texture), C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP1uiv.xml
+func (gl *GL) MultiTexCoordP1uiv(texture, gltype glbase.Enum, coords []uint32) {
+ C.gl4_2compat_glMultiTexCoordP1uiv(gl.funcs, C.GLenum(texture), C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP1ui.xml
+func (gl *GL) MultiTexCoordP1ui(texture, gltype glbase.Enum, coords uint32) {
+ C.gl4_2compat_glMultiTexCoordP1ui(gl.funcs, C.GLenum(texture), C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP4uiv.xml
+func (gl *GL) TexCoordP4uiv(gltype glbase.Enum, coords []uint32) {
+ C.gl4_2compat_glTexCoordP4uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP4ui.xml
+func (gl *GL) TexCoordP4ui(gltype glbase.Enum, coords uint32) {
+ C.gl4_2compat_glTexCoordP4ui(gl.funcs, C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP3uiv.xml
+func (gl *GL) TexCoordP3uiv(gltype glbase.Enum, coords []uint32) {
+ C.gl4_2compat_glTexCoordP3uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP3ui.xml
+func (gl *GL) TexCoordP3ui(gltype glbase.Enum, coords uint32) {
+ C.gl4_2compat_glTexCoordP3ui(gl.funcs, C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP2uiv.xml
+func (gl *GL) TexCoordP2uiv(gltype glbase.Enum, coords []uint32) {
+ C.gl4_2compat_glTexCoordP2uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP2ui.xml
+func (gl *GL) TexCoordP2ui(gltype glbase.Enum, coords uint32) {
+ C.gl4_2compat_glTexCoordP2ui(gl.funcs, C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP1uiv.xml
+func (gl *GL) TexCoordP1uiv(gltype glbase.Enum, coords []uint32) {
+ C.gl4_2compat_glTexCoordP1uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP1ui.xml
+func (gl *GL) TexCoordP1ui(gltype glbase.Enum, coords uint32) {
+ C.gl4_2compat_glTexCoordP1ui(gl.funcs, C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexP4uiv.xml
+func (gl *GL) VertexP4uiv(gltype glbase.Enum, value []uint32) {
+ C.gl4_2compat_glVertexP4uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexP4ui.xml
+func (gl *GL) VertexP4ui(gltype glbase.Enum, value uint32) {
+ C.gl4_2compat_glVertexP4ui(gl.funcs, C.GLenum(gltype), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexP3uiv.xml
+func (gl *GL) VertexP3uiv(gltype glbase.Enum, value []uint32) {
+ C.gl4_2compat_glVertexP3uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexP3ui.xml
+func (gl *GL) VertexP3ui(gltype glbase.Enum, value uint32) {
+ C.gl4_2compat_glVertexP3ui(gl.funcs, C.GLenum(gltype), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexP2uiv.xml
+func (gl *GL) VertexP2uiv(gltype glbase.Enum, value []uint32) {
+ C.gl4_2compat_glVertexP2uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexP2ui.xml
+func (gl *GL) VertexP2ui(gltype glbase.Enum, value uint32) {
+ C.gl4_2compat_glVertexP2ui(gl.funcs, C.GLenum(gltype), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetQueryObjectui64v.xml
+func (gl *GL) GetQueryObjectui64v(id uint32, pname glbase.Enum, params []uint64) {
+ C.gl4_2compat_glGetQueryObjectui64v(gl.funcs, C.GLuint(id), C.GLenum(pname), (*C.GLuint64)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetQueryObjecti64v.xml
+func (gl *GL) GetQueryObjecti64v(id uint32, pname glbase.Enum, params []int64) {
+ C.gl4_2compat_glGetQueryObjecti64v(gl.funcs, C.GLuint(id), C.GLenum(pname), (*C.GLint64)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glQueryCounter.xml
+func (gl *GL) QueryCounter(id uint32, target glbase.Enum) {
+ C.gl4_2compat_glQueryCounter(gl.funcs, C.GLuint(id), C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetSamplerParameterIuiv.xml
+func (gl *GL) GetSamplerParameterIuiv(sampler uint32, pname glbase.Enum, params []uint32) {
+ C.gl4_2compat_glGetSamplerParameterIuiv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetSamplerParameterfv.xml
+func (gl *GL) GetSamplerParameterfv(sampler uint32, pname glbase.Enum, params []float32) {
+ C.gl4_2compat_glGetSamplerParameterfv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetSamplerParameterIiv.xml
+func (gl *GL) GetSamplerParameterIiv(sampler uint32, pname glbase.Enum, params []int32) {
+ C.gl4_2compat_glGetSamplerParameterIiv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetSamplerParameteriv.xml
+func (gl *GL) GetSamplerParameteriv(sampler uint32, pname glbase.Enum, params []int32) {
+ C.gl4_2compat_glGetSamplerParameteriv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSamplerParameterIuiv.xml
+func (gl *GL) SamplerParameterIuiv(sampler uint32, pname glbase.Enum, param []uint32) {
+ C.gl4_2compat_glSamplerParameterIuiv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&param[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSamplerParameterIiv.xml
+func (gl *GL) SamplerParameterIiv(sampler uint32, pname glbase.Enum, param []int32) {
+ C.gl4_2compat_glSamplerParameterIiv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&param[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSamplerParameterfv.xml
+func (gl *GL) SamplerParameterfv(sampler uint32, pname glbase.Enum, param []float32) {
+ C.gl4_2compat_glSamplerParameterfv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&param[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSamplerParameterf.xml
+func (gl *GL) SamplerParameterf(sampler uint32, pname glbase.Enum, param float32) {
+ C.gl4_2compat_glSamplerParameterf(gl.funcs, C.GLuint(sampler), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSamplerParameteriv.xml
+func (gl *GL) SamplerParameteriv(sampler uint32, pname glbase.Enum, param []int32) {
+ C.gl4_2compat_glSamplerParameteriv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&param[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSamplerParameteri.xml
+func (gl *GL) SamplerParameteri(sampler uint32, pname glbase.Enum, param int32) {
+ C.gl4_2compat_glSamplerParameteri(gl.funcs, C.GLuint(sampler), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindSampler.xml
+func (gl *GL) BindSampler(unit, sampler uint32) {
+ C.gl4_2compat_glBindSampler(gl.funcs, C.GLuint(unit), C.GLuint(sampler))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsSampler.xml
+func (gl *GL) IsSampler(sampler uint32) bool {
+ glresult := C.gl4_2compat_glIsSampler(gl.funcs, C.GLuint(sampler))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDeleteSamplers.xml
+func (gl *GL) DeleteSamplers(count int, samplers []uint32) {
+ C.gl4_2compat_glDeleteSamplers(gl.funcs, C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&samplers[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGenSamplers.xml
+func (gl *GL) GenSamplers(count int, samplers []uint32) {
+ C.gl4_2compat_glGenSamplers(gl.funcs, C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&samplers[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetFragDataIndex.xml
+func (gl *GL) GetFragDataIndex(program glbase.Program, name []byte) int32 {
+ glresult := C.gl4_2compat_glGetFragDataIndex(gl.funcs, C.GLuint(program), (*C.GLchar)(unsafe.Pointer(&name[0])))
+ return int32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindFragDataLocationIndexed.xml
+func (gl *GL) BindFragDataLocationIndexed(program glbase.Program, colorNumber, index uint32, name []byte) {
+ C.gl4_2compat_glBindFragDataLocationIndexed(gl.funcs, C.GLuint(program), C.GLuint(colorNumber), C.GLuint(index), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribDivisor.xml
+func (gl *GL) VertexAttribDivisor(index glbase.Attrib, divisor uint32) {
+ C.gl4_2compat_glVertexAttribDivisor(gl.funcs, C.GLuint(index), C.GLuint(divisor))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetQueryIndexediv.xml
+func (gl *GL) GetQueryIndexediv(target glbase.Enum, index uint32, pname glbase.Enum, params []int32) {
+ C.gl4_2compat_glGetQueryIndexediv(gl.funcs, C.GLenum(target), C.GLuint(index), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEndQueryIndexed.xml
+func (gl *GL) EndQueryIndexed(target glbase.Enum, index uint32) {
+ C.gl4_2compat_glEndQueryIndexed(gl.funcs, C.GLenum(target), C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBeginQueryIndexed.xml
+func (gl *GL) BeginQueryIndexed(target glbase.Enum, index, id uint32) {
+ C.gl4_2compat_glBeginQueryIndexed(gl.funcs, C.GLenum(target), C.GLuint(index), C.GLuint(id))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawTransformFeedbackStream.xml
+func (gl *GL) DrawTransformFeedbackStream(mode glbase.Enum, id, stream uint32) {
+ C.gl4_2compat_glDrawTransformFeedbackStream(gl.funcs, C.GLenum(mode), C.GLuint(id), C.GLuint(stream))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawTransformFeedback.xml
+func (gl *GL) DrawTransformFeedback(mode glbase.Enum, id uint32) {
+ C.gl4_2compat_glDrawTransformFeedback(gl.funcs, C.GLenum(mode), C.GLuint(id))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glResumeTransformFeedback.xml
+func (gl *GL) ResumeTransformFeedback() {
+ C.gl4_2compat_glResumeTransformFeedback(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPauseTransformFeedback.xml
+func (gl *GL) PauseTransformFeedback() {
+ C.gl4_2compat_glPauseTransformFeedback(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsTransformFeedback.xml
+func (gl *GL) IsTransformFeedback(id uint32) bool {
+ glresult := C.gl4_2compat_glIsTransformFeedback(gl.funcs, C.GLuint(id))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGenTransformFeedbacks.xml
+func (gl *GL) GenTransformFeedbacks(n int, ids []uint32) {
+ C.gl4_2compat_glGenTransformFeedbacks(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&ids[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDeleteTransformFeedbacks.xml
+func (gl *GL) DeleteTransformFeedbacks(n int, ids []uint32) {
+ C.gl4_2compat_glDeleteTransformFeedbacks(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&ids[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindTransformFeedback.xml
+func (gl *GL) BindTransformFeedback(target glbase.Enum, id uint32) {
+ C.gl4_2compat_glBindTransformFeedback(gl.funcs, C.GLenum(target), C.GLuint(id))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPatchParameterfv.xml
+func (gl *GL) PatchParameterfv(pname glbase.Enum, values []float32) {
+ C.gl4_2compat_glPatchParameterfv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPatchParameteri.xml
+func (gl *GL) PatchParameteri(pname glbase.Enum, value int32) {
+ C.gl4_2compat_glPatchParameteri(gl.funcs, C.GLenum(pname), C.GLint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetProgramStageiv.xml
+func (gl *GL) GetProgramStageiv(program glbase.Program, shadertype, pname glbase.Enum, values []int32) {
+ C.gl4_2compat_glGetProgramStageiv(gl.funcs, C.GLuint(program), C.GLenum(shadertype), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetUniformSubroutineuiv.xml
+func (gl *GL) GetUniformSubroutineuiv(shadertype glbase.Enum, location glbase.Uniform, params []uint32) {
+ C.gl4_2compat_glGetUniformSubroutineuiv(gl.funcs, C.GLenum(shadertype), C.GLint(location), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformSubroutinesuiv.xml
+func (gl *GL) UniformSubroutinesuiv(shadertype glbase.Enum, count int, value []uint32) {
+ C.gl4_2compat_glUniformSubroutinesuiv(gl.funcs, C.GLenum(shadertype), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveSubroutineName.xml
+func (gl *GL) GetActiveSubroutineName(program glbase.Program, shadertype glbase.Enum, index uint32, bufSize int32, length []int32, name []byte) {
+ C.gl4_2compat_glGetActiveSubroutineName(gl.funcs, C.GLuint(program), C.GLenum(shadertype), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveSubroutineUniformName.xml
+func (gl *GL) GetActiveSubroutineUniformName(program glbase.Program, shadertype glbase.Enum, index uint32, bufSize int32, length []int32, name []byte) {
+ C.gl4_2compat_glGetActiveSubroutineUniformName(gl.funcs, C.GLuint(program), C.GLenum(shadertype), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveSubroutineUniformiv.xml
+func (gl *GL) GetActiveSubroutineUniformiv(program glbase.Program, shadertype glbase.Enum, index uint32, pname glbase.Enum, values []int32) {
+ C.gl4_2compat_glGetActiveSubroutineUniformiv(gl.funcs, C.GLuint(program), C.GLenum(shadertype), C.GLuint(index), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetSubroutineIndex.xml
+func (gl *GL) GetSubroutineIndex(program glbase.Program, shadertype glbase.Enum, name []byte) uint32 {
+ glresult := C.gl4_2compat_glGetSubroutineIndex(gl.funcs, C.GLuint(program), C.GLenum(shadertype), (*C.GLchar)(unsafe.Pointer(&name[0])))
+ return uint32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetSubroutineUniformLocation.xml
+func (gl *GL) GetSubroutineUniformLocation(program glbase.Program, shadertype glbase.Enum, name []byte) int32 {
+ glresult := C.gl4_2compat_glGetSubroutineUniformLocation(gl.funcs, C.GLuint(program), C.GLenum(shadertype), (*C.GLchar)(unsafe.Pointer(&name[0])))
+ return int32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetUniformdv.xml
+func (gl *GL) GetUniformdv(program glbase.Program, location glbase.Uniform, params []float64) {
+ C.gl4_2compat_glGetUniformdv(gl.funcs, C.GLuint(program), C.GLint(location), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix4x3dv.xml
+func (gl *GL) UniformMatrix4x3dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_2compat_glUniformMatrix4x3dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix4x2dv.xml
+func (gl *GL) UniformMatrix4x2dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_2compat_glUniformMatrix4x2dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix3x4dv.xml
+func (gl *GL) UniformMatrix3x4dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_2compat_glUniformMatrix3x4dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix3x2dv.xml
+func (gl *GL) UniformMatrix3x2dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_2compat_glUniformMatrix3x2dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix2x4dv.xml
+func (gl *GL) UniformMatrix2x4dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_2compat_glUniformMatrix2x4dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix2x3dv.xml
+func (gl *GL) UniformMatrix2x3dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_2compat_glUniformMatrix2x3dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix4dv.xml
+func (gl *GL) UniformMatrix4dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_2compat_glUniformMatrix4dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix3dv.xml
+func (gl *GL) UniformMatrix3dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_2compat_glUniformMatrix3dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix2dv.xml
+func (gl *GL) UniformMatrix2dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_2compat_glUniformMatrix2dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform4dv.xml
+func (gl *GL) Uniform4dv(location glbase.Uniform, count int, value []float64) {
+ C.gl4_2compat_glUniform4dv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform3dv.xml
+func (gl *GL) Uniform3dv(location glbase.Uniform, count int, value []float64) {
+ C.gl4_2compat_glUniform3dv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform2dv.xml
+func (gl *GL) Uniform2dv(location glbase.Uniform, count int, value []float64) {
+ C.gl4_2compat_glUniform2dv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform1dv.xml
+func (gl *GL) Uniform1dv(location glbase.Uniform, count int, value []float64) {
+ C.gl4_2compat_glUniform1dv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform4d.xml
+func (gl *GL) Uniform4d(location glbase.Uniform, v0, v1, v2, v3 float64) {
+ C.gl4_2compat_glUniform4d(gl.funcs, C.GLint(location), C.GLdouble(v0), C.GLdouble(v1), C.GLdouble(v2), C.GLdouble(v3))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform3d.xml
+func (gl *GL) Uniform3d(location glbase.Uniform, v0, v1, v2 float64) {
+ C.gl4_2compat_glUniform3d(gl.funcs, C.GLint(location), C.GLdouble(v0), C.GLdouble(v1), C.GLdouble(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform2d.xml
+func (gl *GL) Uniform2d(location glbase.Uniform, v0, v1 float64) {
+ C.gl4_2compat_glUniform2d(gl.funcs, C.GLint(location), C.GLdouble(v0), C.GLdouble(v1))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform1d.xml
+func (gl *GL) Uniform1d(location glbase.Uniform, v0 float64) {
+ C.gl4_2compat_glUniform1d(gl.funcs, C.GLint(location), C.GLdouble(v0))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawElementsIndirect.xml
+func (gl *GL) DrawElementsIndirect(mode, gltype glbase.Enum, indirect interface{}) {
+ var indirect_ptr unsafe.Pointer
+ var indirect_v = reflect.ValueOf(indirect)
+ if indirect != nil && indirect_v.Kind() != reflect.Slice {
+ panic("parameter indirect must be a slice")
+ }
+ if indirect != nil {
+ indirect_ptr = unsafe.Pointer(indirect_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2compat_glDrawElementsIndirect(gl.funcs, C.GLenum(mode), C.GLenum(gltype), indirect_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawArraysIndirect.xml
+func (gl *GL) DrawArraysIndirect(mode glbase.Enum, indirect interface{}) {
+ var indirect_ptr unsafe.Pointer
+ var indirect_v = reflect.ValueOf(indirect)
+ if indirect != nil && indirect_v.Kind() != reflect.Slice {
+ panic("parameter indirect must be a slice")
+ }
+ if indirect != nil {
+ indirect_ptr = unsafe.Pointer(indirect_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2compat_glDrawArraysIndirect(gl.funcs, C.GLenum(mode), indirect_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendFuncSeparatei.xml
+func (gl *GL) BlendFuncSeparatei(buf uint32, srcRGB, dstRGB, srcAlpha, dstAlpha glbase.Enum) {
+ C.gl4_2compat_glBlendFuncSeparatei(gl.funcs, C.GLuint(buf), C.GLenum(srcRGB), C.GLenum(dstRGB), C.GLenum(srcAlpha), C.GLenum(dstAlpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendFunci.xml
+func (gl *GL) BlendFunci(buf uint32, src, dst glbase.Enum) {
+ C.gl4_2compat_glBlendFunci(gl.funcs, C.GLuint(buf), C.GLenum(src), C.GLenum(dst))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendEquationSeparatei.xml
+func (gl *GL) BlendEquationSeparatei(buf uint32, modeRGB, modeAlpha glbase.Enum) {
+ C.gl4_2compat_glBlendEquationSeparatei(gl.funcs, C.GLuint(buf), C.GLenum(modeRGB), C.GLenum(modeAlpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendEquationi.xml
+func (gl *GL) BlendEquationi(buf uint32, mode glbase.Enum) {
+ C.gl4_2compat_glBlendEquationi(gl.funcs, C.GLuint(buf), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMinSampleShading.xml
+func (gl *GL) MinSampleShading(value float32) {
+ C.gl4_2compat_glMinSampleShading(gl.funcs, C.GLfloat(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetDoublei_v.xml
+func (gl *GL) GetDoublei_v(target glbase.Enum, index uint32, data []float64) {
+ C.gl4_2compat_glGetDoublei_v(gl.funcs, C.GLenum(target), C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&data[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetFloati_v.xml
+func (gl *GL) GetFloati_v(target glbase.Enum, index uint32, data []float32) {
+ C.gl4_2compat_glGetFloati_v(gl.funcs, C.GLenum(target), C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&data[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDepthRangeIndexed.xml
+func (gl *GL) DepthRangeIndexed(index uint32, n, f float64) {
+ C.gl4_2compat_glDepthRangeIndexed(gl.funcs, C.GLuint(index), C.GLdouble(n), C.GLdouble(f))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDepthRangeArrayv.xml
+func (gl *GL) DepthRangeArrayv(first uint32, count int, v []float64) {
+ C.gl4_2compat_glDepthRangeArrayv(gl.funcs, C.GLuint(first), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glScissorIndexedv.xml
+func (gl *GL) ScissorIndexedv(index uint32, v []int32) {
+ C.gl4_2compat_glScissorIndexedv(gl.funcs, C.GLuint(index), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glScissorIndexed.xml
+func (gl *GL) ScissorIndexed(index uint32, left, bottom int32, width, height int) {
+ C.gl4_2compat_glScissorIndexed(gl.funcs, C.GLuint(index), C.GLint(left), C.GLint(bottom), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glScissorArrayv.xml
+func (gl *GL) ScissorArrayv(first uint32, count int, v []int32) {
+ C.gl4_2compat_glScissorArrayv(gl.funcs, C.GLuint(first), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glViewportIndexedfv.xml
+func (gl *GL) ViewportIndexedfv(index uint32, v []float32) {
+ C.gl4_2compat_glViewportIndexedfv(gl.funcs, C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glViewportIndexedf.xml
+func (gl *GL) ViewportIndexedf(index uint32, x, y, w, h float32) {
+ C.gl4_2compat_glViewportIndexedf(gl.funcs, C.GLuint(index), C.GLfloat(x), C.GLfloat(y), C.GLfloat(w), C.GLfloat(h))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glViewportArrayv.xml
+func (gl *GL) ViewportArrayv(first uint32, count int, v []float32) {
+ C.gl4_2compat_glViewportArrayv(gl.funcs, C.GLuint(first), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetVertexAttribLdv.xml
+func (gl *GL) GetVertexAttribLdv(index glbase.Attrib, pname glbase.Enum, params []float64) {
+ C.gl4_2compat_glGetVertexAttribLdv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribLPointer.xml
+func (gl *GL) VertexAttribLPointer(index glbase.Attrib, size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2compat_glVertexAttribLPointer(gl.funcs, C.GLuint(index), C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribL4dv.xml
+func (gl *GL) VertexAttribL4dv(index glbase.Attrib, v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glVertexAttribL4dv(gl.funcs, C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribL3dv.xml
+func (gl *GL) VertexAttribL3dv(index glbase.Attrib, v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glVertexAttribL3dv(gl.funcs, C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribL2dv.xml
+func (gl *GL) VertexAttribL2dv(index glbase.Attrib, v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glVertexAttribL2dv(gl.funcs, C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribL1dv.xml
+func (gl *GL) VertexAttribL1dv(index glbase.Attrib, v []float64) {
+ C.gl4_2compat_glVertexAttribL1dv(gl.funcs, C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribL4d.xml
+func (gl *GL) VertexAttribL4d(index glbase.Attrib, x, y, z, w float64) {
+ C.gl4_2compat_glVertexAttribL4d(gl.funcs, C.GLuint(index), C.GLdouble(x), C.GLdouble(y), C.GLdouble(z), C.GLdouble(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribL3d.xml
+func (gl *GL) VertexAttribL3d(index glbase.Attrib, x, y, z float64) {
+ C.gl4_2compat_glVertexAttribL3d(gl.funcs, C.GLuint(index), C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribL2d.xml
+func (gl *GL) VertexAttribL2d(index glbase.Attrib, x, y float64) {
+ C.gl4_2compat_glVertexAttribL2d(gl.funcs, C.GLuint(index), C.GLdouble(x), C.GLdouble(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribL1d.xml
+func (gl *GL) VertexAttribL1d(index glbase.Attrib, x float64) {
+ C.gl4_2compat_glVertexAttribL1d(gl.funcs, C.GLuint(index), C.GLdouble(x))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetProgramPipelineInfoLog.xml
+func (gl *GL) GetProgramPipelineInfoLog(pipeline uint32, bufSize int32, length []int32, infoLog []byte) {
+ C.gl4_2compat_glGetProgramPipelineInfoLog(gl.funcs, C.GLuint(pipeline), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&infoLog[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glValidateProgramPipeline.xml
+func (gl *GL) ValidateProgramPipeline(pipeline uint32) {
+ C.gl4_2compat_glValidateProgramPipeline(gl.funcs, C.GLuint(pipeline))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix4x3dv.xml
+func (gl *GL) ProgramUniformMatrix4x3dv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float64) {
+ if len(value) != 3 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_2compat_glProgramUniformMatrix4x3dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix3x4dv.xml
+func (gl *GL) ProgramUniformMatrix3x4dv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float64) {
+ if len(value) != 4 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_2compat_glProgramUniformMatrix3x4dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix4x2dv.xml
+func (gl *GL) ProgramUniformMatrix4x2dv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float64) {
+ if len(value) != 2 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_2compat_glProgramUniformMatrix4x2dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix2x4dv.xml
+func (gl *GL) ProgramUniformMatrix2x4dv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float64) {
+ if len(value) != 4 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_2compat_glProgramUniformMatrix2x4dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix3x2dv.xml
+func (gl *GL) ProgramUniformMatrix3x2dv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float64) {
+ if len(value) != 2 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_2compat_glProgramUniformMatrix3x2dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix2x3dv.xml
+func (gl *GL) ProgramUniformMatrix2x3dv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float64) {
+ if len(value) != 3 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_2compat_glProgramUniformMatrix2x3dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix4x3fv.xml
+func (gl *GL) ProgramUniformMatrix4x3fv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float32) {
+ if len(value) != 3 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_2compat_glProgramUniformMatrix4x3fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix3x4fv.xml
+func (gl *GL) ProgramUniformMatrix3x4fv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float32) {
+ if len(value) != 4 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_2compat_glProgramUniformMatrix3x4fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix4x2fv.xml
+func (gl *GL) ProgramUniformMatrix4x2fv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float32) {
+ if len(value) != 2 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_2compat_glProgramUniformMatrix4x2fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix2x4fv.xml
+func (gl *GL) ProgramUniformMatrix2x4fv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float32) {
+ if len(value) != 4 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_2compat_glProgramUniformMatrix2x4fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix3x2fv.xml
+func (gl *GL) ProgramUniformMatrix3x2fv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float32) {
+ if len(value) != 2 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_2compat_glProgramUniformMatrix3x2fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix2x3fv.xml
+func (gl *GL) ProgramUniformMatrix2x3fv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float32) {
+ if len(value) != 3 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_2compat_glProgramUniformMatrix2x3fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix4dv.xml
+func (gl *GL) ProgramUniformMatrix4dv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float64) {
+ if len(value) != 4 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_2compat_glProgramUniformMatrix4dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix3dv.xml
+func (gl *GL) ProgramUniformMatrix3dv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float64) {
+ if len(value) != 3 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_2compat_glProgramUniformMatrix3dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix2dv.xml
+func (gl *GL) ProgramUniformMatrix2dv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float64) {
+ if len(value) != 2 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_2compat_glProgramUniformMatrix2dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix4fv.xml
+func (gl *GL) ProgramUniformMatrix4fv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float32) {
+ if len(value) != 4 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_2compat_glProgramUniformMatrix4fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix3fv.xml
+func (gl *GL) ProgramUniformMatrix3fv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float32) {
+ if len(value) != 3 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_2compat_glProgramUniformMatrix3fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix2fv.xml
+func (gl *GL) ProgramUniformMatrix2fv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float32) {
+ if len(value) != 2 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_2compat_glProgramUniformMatrix2fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform4uiv.xml
+func (gl *GL) ProgramUniform4uiv(program glbase.Program, location glbase.Uniform, count int, value []uint32) {
+ C.gl4_2compat_glProgramUniform4uiv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform4ui.xml
+func (gl *GL) ProgramUniform4ui(program glbase.Program, location glbase.Uniform, v0, v1, v2, v3 uint32) {
+ C.gl4_2compat_glProgramUniform4ui(gl.funcs, C.GLuint(program), C.GLint(location), C.GLuint(v0), C.GLuint(v1), C.GLuint(v2), C.GLuint(v3))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform4dv.xml
+func (gl *GL) ProgramUniform4dv(program glbase.Program, location glbase.Uniform, count int, value []float64) {
+ if len(value) != 4 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_2compat_glProgramUniform4dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform4d.xml
+func (gl *GL) ProgramUniform4d(program glbase.Program, location glbase.Uniform, v0, v1, v2, v3 float64) {
+ C.gl4_2compat_glProgramUniform4d(gl.funcs, C.GLuint(program), C.GLint(location), C.GLdouble(v0), C.GLdouble(v1), C.GLdouble(v2), C.GLdouble(v3))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform4fv.xml
+func (gl *GL) ProgramUniform4fv(program glbase.Program, location glbase.Uniform, count int, value []float32) {
+ if len(value) != 4 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_2compat_glProgramUniform4fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform4f.xml
+func (gl *GL) ProgramUniform4f(program glbase.Program, location glbase.Uniform, v0, v1, v2, v3 float32) {
+ C.gl4_2compat_glProgramUniform4f(gl.funcs, C.GLuint(program), C.GLint(location), C.GLfloat(v0), C.GLfloat(v1), C.GLfloat(v2), C.GLfloat(v3))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform4iv.xml
+func (gl *GL) ProgramUniform4iv(program glbase.Program, location glbase.Uniform, count int, value []int32) {
+ if len(value) != 4 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_2compat_glProgramUniform4iv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform4i.xml
+func (gl *GL) ProgramUniform4i(program glbase.Program, location glbase.Uniform, v0, v1, v2, v3 int32) {
+ C.gl4_2compat_glProgramUniform4i(gl.funcs, C.GLuint(program), C.GLint(location), C.GLint(v0), C.GLint(v1), C.GLint(v2), C.GLint(v3))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform3uiv.xml
+func (gl *GL) ProgramUniform3uiv(program glbase.Program, location glbase.Uniform, count int, value []uint32) {
+ C.gl4_2compat_glProgramUniform3uiv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform3ui.xml
+func (gl *GL) ProgramUniform3ui(program glbase.Program, location glbase.Uniform, v0, v1, v2 uint32) {
+ C.gl4_2compat_glProgramUniform3ui(gl.funcs, C.GLuint(program), C.GLint(location), C.GLuint(v0), C.GLuint(v1), C.GLuint(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform3dv.xml
+func (gl *GL) ProgramUniform3dv(program glbase.Program, location glbase.Uniform, count int, value []float64) {
+ if len(value) != 3 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_2compat_glProgramUniform3dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform3d.xml
+func (gl *GL) ProgramUniform3d(program glbase.Program, location glbase.Uniform, v0, v1, v2 float64) {
+ C.gl4_2compat_glProgramUniform3d(gl.funcs, C.GLuint(program), C.GLint(location), C.GLdouble(v0), C.GLdouble(v1), C.GLdouble(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform3fv.xml
+func (gl *GL) ProgramUniform3fv(program glbase.Program, location glbase.Uniform, count int, value []float32) {
+ if len(value) != 3 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_2compat_glProgramUniform3fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform3f.xml
+func (gl *GL) ProgramUniform3f(program glbase.Program, location glbase.Uniform, v0, v1, v2 float32) {
+ C.gl4_2compat_glProgramUniform3f(gl.funcs, C.GLuint(program), C.GLint(location), C.GLfloat(v0), C.GLfloat(v1), C.GLfloat(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform3iv.xml
+func (gl *GL) ProgramUniform3iv(program glbase.Program, location glbase.Uniform, count int, value []int32) {
+ if len(value) != 3 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_2compat_glProgramUniform3iv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform3i.xml
+func (gl *GL) ProgramUniform3i(program glbase.Program, location glbase.Uniform, v0, v1, v2 int32) {
+ C.gl4_2compat_glProgramUniform3i(gl.funcs, C.GLuint(program), C.GLint(location), C.GLint(v0), C.GLint(v1), C.GLint(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform2uiv.xml
+func (gl *GL) ProgramUniform2uiv(program glbase.Program, location glbase.Uniform, count int, value []uint32) {
+ C.gl4_2compat_glProgramUniform2uiv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform2ui.xml
+func (gl *GL) ProgramUniform2ui(program glbase.Program, location glbase.Uniform, v0, v1 uint32) {
+ C.gl4_2compat_glProgramUniform2ui(gl.funcs, C.GLuint(program), C.GLint(location), C.GLuint(v0), C.GLuint(v1))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform2dv.xml
+func (gl *GL) ProgramUniform2dv(program glbase.Program, location glbase.Uniform, count int, value []float64) {
+ if len(value) != 2 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_2compat_glProgramUniform2dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform2d.xml
+func (gl *GL) ProgramUniform2d(program glbase.Program, location glbase.Uniform, v0, v1 float64) {
+ C.gl4_2compat_glProgramUniform2d(gl.funcs, C.GLuint(program), C.GLint(location), C.GLdouble(v0), C.GLdouble(v1))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform2fv.xml
+func (gl *GL) ProgramUniform2fv(program glbase.Program, location glbase.Uniform, count int, value []float32) {
+ if len(value) != 2 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_2compat_glProgramUniform2fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform2f.xml
+func (gl *GL) ProgramUniform2f(program glbase.Program, location glbase.Uniform, v0, v1 float32) {
+ C.gl4_2compat_glProgramUniform2f(gl.funcs, C.GLuint(program), C.GLint(location), C.GLfloat(v0), C.GLfloat(v1))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform2iv.xml
+func (gl *GL) ProgramUniform2iv(program glbase.Program, location glbase.Uniform, count int, value []int32) {
+ if len(value) != 2 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_2compat_glProgramUniform2iv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform2i.xml
+func (gl *GL) ProgramUniform2i(program glbase.Program, location glbase.Uniform, v0, v1 int32) {
+ C.gl4_2compat_glProgramUniform2i(gl.funcs, C.GLuint(program), C.GLint(location), C.GLint(v0), C.GLint(v1))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform1uiv.xml
+func (gl *GL) ProgramUniform1uiv(program glbase.Program, location glbase.Uniform, count int, value []uint32) {
+ C.gl4_2compat_glProgramUniform1uiv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform1ui.xml
+func (gl *GL) ProgramUniform1ui(program glbase.Program, location glbase.Uniform, v0 uint32) {
+ C.gl4_2compat_glProgramUniform1ui(gl.funcs, C.GLuint(program), C.GLint(location), C.GLuint(v0))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform1dv.xml
+func (gl *GL) ProgramUniform1dv(program glbase.Program, location glbase.Uniform, count int, value []float64) {
+ C.gl4_2compat_glProgramUniform1dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform1d.xml
+func (gl *GL) ProgramUniform1d(program glbase.Program, location glbase.Uniform, v0 float64) {
+ C.gl4_2compat_glProgramUniform1d(gl.funcs, C.GLuint(program), C.GLint(location), C.GLdouble(v0))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform1fv.xml
+func (gl *GL) ProgramUniform1fv(program glbase.Program, location glbase.Uniform, count int, value []float32) {
+ C.gl4_2compat_glProgramUniform1fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform1f.xml
+func (gl *GL) ProgramUniform1f(program glbase.Program, location glbase.Uniform, v0 float32) {
+ C.gl4_2compat_glProgramUniform1f(gl.funcs, C.GLuint(program), C.GLint(location), C.GLfloat(v0))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform1iv.xml
+func (gl *GL) ProgramUniform1iv(program glbase.Program, location glbase.Uniform, count int, value []int32) {
+ C.gl4_2compat_glProgramUniform1iv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform1i.xml
+func (gl *GL) ProgramUniform1i(program glbase.Program, location glbase.Uniform, v0 int32) {
+ C.gl4_2compat_glProgramUniform1i(gl.funcs, C.GLuint(program), C.GLint(location), C.GLint(v0))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetProgramPipelineiv.xml
+func (gl *GL) GetProgramPipelineiv(pipeline uint32, pname glbase.Enum, params []int32) {
+ C.gl4_2compat_glGetProgramPipelineiv(gl.funcs, C.GLuint(pipeline), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsProgramPipeline.xml
+func (gl *GL) IsProgramPipeline(pipeline uint32) bool {
+ glresult := C.gl4_2compat_glIsProgramPipeline(gl.funcs, C.GLuint(pipeline))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGenProgramPipelines.xml
+func (gl *GL) GenProgramPipelines(n int, pipelines []uint32) {
+ C.gl4_2compat_glGenProgramPipelines(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&pipelines[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDeleteProgramPipelines.xml
+func (gl *GL) DeleteProgramPipelines(n int, pipelines []uint32) {
+ C.gl4_2compat_glDeleteProgramPipelines(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&pipelines[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindProgramPipeline.xml
+func (gl *GL) BindProgramPipeline(pipeline uint32) {
+ C.gl4_2compat_glBindProgramPipeline(gl.funcs, C.GLuint(pipeline))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glActiveShaderProgram.xml
+func (gl *GL) ActiveShaderProgram(pipeline uint32, program glbase.Program) {
+ C.gl4_2compat_glActiveShaderProgram(gl.funcs, C.GLuint(pipeline), C.GLuint(program))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUseProgramStages.xml
+func (gl *GL) UseProgramStages(pipeline uint32, stages glbase.Bitfield, program glbase.Program) {
+ C.gl4_2compat_glUseProgramStages(gl.funcs, C.GLuint(pipeline), C.GLbitfield(stages), C.GLuint(program))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramParameteri.xml
+func (gl *GL) ProgramParameteri(program glbase.Program, pname glbase.Enum, value int32) {
+ C.gl4_2compat_glProgramParameteri(gl.funcs, C.GLuint(program), C.GLenum(pname), C.GLint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramBinary.xml
+func (gl *GL) ProgramBinary(program glbase.Program, binaryFormat glbase.Enum, binary interface{}, length int32) {
+ var binary_ptr unsafe.Pointer
+ var binary_v = reflect.ValueOf(binary)
+ if binary != nil && binary_v.Kind() != reflect.Slice {
+ panic("parameter binary must be a slice")
+ }
+ if binary != nil {
+ binary_ptr = unsafe.Pointer(binary_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2compat_glProgramBinary(gl.funcs, C.GLuint(program), C.GLenum(binaryFormat), binary_ptr, C.GLsizei(length))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetProgramBinary.xml
+func (gl *GL) GetProgramBinary(program glbase.Program, bufSize int32, length []int32, binaryFormat []glbase.Enum, binary interface{}) {
+ var binary_ptr unsafe.Pointer
+ var binary_v = reflect.ValueOf(binary)
+ if binary != nil && binary_v.Kind() != reflect.Slice {
+ panic("parameter binary must be a slice")
+ }
+ if binary != nil {
+ binary_ptr = unsafe.Pointer(binary_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2compat_glGetProgramBinary(gl.funcs, C.GLuint(program), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLenum)(unsafe.Pointer(&binaryFormat[0])), binary_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearDepthf.xml
+func (gl *GL) ClearDepthf(dd float32) {
+ C.gl4_2compat_glClearDepthf(gl.funcs, C.GLfloat(dd))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDepthRangef.xml
+func (gl *GL) DepthRangef(n, f float32) {
+ C.gl4_2compat_glDepthRangef(gl.funcs, C.GLfloat(n), C.GLfloat(f))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetShaderPrecisionFormat.xml
+func (gl *GL) GetShaderPrecisionFormat(shadertype, precisionType glbase.Enum, range_, precision []int32) {
+ C.gl4_2compat_glGetShaderPrecisionFormat(gl.funcs, C.GLenum(shadertype), C.GLenum(precisionType), (*C.GLint)(unsafe.Pointer(&range_[0])), (*C.GLint)(unsafe.Pointer(&precision[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glShaderBinary.xml
+func (gl *GL) ShaderBinary(count int, shaders []glbase.Shader, binaryFormat glbase.Enum, binary interface{}, length int32) {
+ var binary_ptr unsafe.Pointer
+ var binary_v = reflect.ValueOf(binary)
+ if binary != nil && binary_v.Kind() != reflect.Slice {
+ panic("parameter binary must be a slice")
+ }
+ if binary != nil {
+ binary_ptr = unsafe.Pointer(binary_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2compat_glShaderBinary(gl.funcs, C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&shaders[0])), C.GLenum(binaryFormat), binary_ptr, C.GLsizei(length))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glReleaseShaderCompiler.xml
+func (gl *GL) ReleaseShaderCompiler() {
+ C.gl4_2compat_glReleaseShaderCompiler(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexStorage3D.xml
+func (gl *GL) TexStorage3D(target glbase.Enum, levels int32, internalFormat glbase.Enum, width, height int, depth int32) {
+ C.gl4_2compat_glTexStorage3D(gl.funcs, C.GLenum(target), C.GLsizei(levels), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexStorage2D.xml
+func (gl *GL) TexStorage2D(target glbase.Enum, levels int32, internalFormat glbase.Enum, width, height int) {
+ C.gl4_2compat_glTexStorage2D(gl.funcs, C.GLenum(target), C.GLsizei(levels), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexStorage1D.xml
+func (gl *GL) TexStorage1D(target glbase.Enum, levels int32, internalFormat glbase.Enum, width int) {
+ C.gl4_2compat_glTexStorage1D(gl.funcs, C.GLenum(target), C.GLsizei(levels), C.GLenum(internalFormat), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMemoryBarrier.xml
+func (gl *GL) MemoryBarrier(barriers glbase.Bitfield) {
+ C.gl4_2compat_glMemoryBarrier(gl.funcs, C.GLbitfield(barriers))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindImageTexture.xml
+func (gl *GL) BindImageTexture(unit uint32, texture glbase.Texture, level int, layered bool, layer int32, access, format glbase.Enum) {
+ C.gl4_2compat_glBindImageTexture(gl.funcs, C.GLuint(unit), C.GLuint(texture), C.GLint(level), *(*C.GLboolean)(unsafe.Pointer(&layered)), C.GLint(layer), C.GLenum(access), C.GLenum(format))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveAtomicCounterBufferiv.xml
+func (gl *GL) GetActiveAtomicCounterBufferiv(program glbase.Program, bufferIndex uint32, pname glbase.Enum, params []int32) {
+ C.gl4_2compat_glGetActiveAtomicCounterBufferiv(gl.funcs, C.GLuint(program), C.GLuint(bufferIndex), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetInternalformativ.xml
+func (gl *GL) GetInternalformativ(target, internalFormat, pname glbase.Enum, bufSize int32, params []int32) {
+ C.gl4_2compat_glGetInternalformativ(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLenum(pname), C.GLsizei(bufSize), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawTransformFeedbackStreamInstanced.xml
+func (gl *GL) DrawTransformFeedbackStreamInstanced(mode glbase.Enum, id, stream uint32, instancecount int32) {
+ C.gl4_2compat_glDrawTransformFeedbackStreamInstanced(gl.funcs, C.GLenum(mode), C.GLuint(id), C.GLuint(stream), C.GLsizei(instancecount))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawTransformFeedbackInstanced.xml
+func (gl *GL) DrawTransformFeedbackInstanced(mode glbase.Enum, id uint32, instancecount int32) {
+ C.gl4_2compat_glDrawTransformFeedbackInstanced(gl.funcs, C.GLenum(mode), C.GLuint(id), C.GLsizei(instancecount))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawElementsInstancedBaseVertexBaseInstance.xml
+func (gl *GL) DrawElementsInstancedBaseVertexBaseInstance(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}, instancecount, basevertex int32, baseinstance uint32) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2compat_glDrawElementsInstancedBaseVertexBaseInstance(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr, C.GLsizei(instancecount), C.GLint(basevertex), C.GLuint(baseinstance))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawElementsInstancedBaseInstance.xml
+func (gl *GL) DrawElementsInstancedBaseInstance(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}, instancecount int32, baseinstance uint32) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2compat_glDrawElementsInstancedBaseInstance(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr, C.GLsizei(instancecount), C.GLuint(baseinstance))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawArraysInstancedBaseInstance.xml
+func (gl *GL) DrawArraysInstancedBaseInstance(mode glbase.Enum, first, count int, instancecount int32, baseinstance uint32) {
+ C.gl4_2compat_glDrawArraysInstancedBaseInstance(gl.funcs, C.GLenum(mode), C.GLint(first), C.GLsizei(count), C.GLsizei(instancecount), C.GLuint(baseinstance))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTranslatef.xml
+func (gl *GL) Translatef(x, y, z float32) {
+ C.gl4_2compat_glTranslatef(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTranslated.xml
+func (gl *GL) Translated(x, y, z float64) {
+ C.gl4_2compat_glTranslated(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glScalef.xml
+func (gl *GL) Scalef(x, y, z float32) {
+ C.gl4_2compat_glScalef(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glScaled.xml
+func (gl *GL) Scaled(x, y, z float64) {
+ C.gl4_2compat_glScaled(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRotatef.xml
+func (gl *GL) Rotatef(angle, x, y, z float32) {
+ C.gl4_2compat_glRotatef(gl.funcs, C.GLfloat(angle), C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRotated.xml
+func (gl *GL) Rotated(angle, x, y, z float64) {
+ C.gl4_2compat_glRotated(gl.funcs, C.GLdouble(angle), C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPushMatrix.xml
+func (gl *GL) PushMatrix() {
+ C.gl4_2compat_glPushMatrix(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPopMatrix.xml
+func (gl *GL) PopMatrix() {
+ C.gl4_2compat_glPopMatrix(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glOrtho.xml
+func (gl *GL) Ortho(left, right, bottom, top, zNear, zFar float64) {
+ C.gl4_2compat_glOrtho(gl.funcs, C.GLdouble(left), C.GLdouble(right), C.GLdouble(bottom), C.GLdouble(top), C.GLdouble(zNear), C.GLdouble(zFar))
+}
+
+// MultMatrixd multiplies the current matrix with the provided matrix.
+//
+// The m parameter must hold 16 consecutive elements of a 4x4 column-major matrix.
+//
+// The current matrix is determined by the current matrix mode (see
+// MatrixMode). It is either the projection matrix, modelview matrix, or the
+// texture matrix.
+//
+// For example, if the current matrix is C and the coordinates to be transformed
+// are v = (v[0], v[1], v[2], v[3]), then the current transformation is C × v, or
+//
+// c[0] c[4] c[8] c[12] v[0]
+// c[1] c[5] c[9] c[13] v[1]
+// c[2] c[6] c[10] c[14] X v[2]
+// c[3] c[7] c[11] c[15] v[3]
+//
+// Calling MultMatrix with an argument of m = m[0], m[1], ..., m[15]
+// replaces the current transformation with (C X M) x v, or
+//
+// c[0] c[4] c[8] c[12] m[0] m[4] m[8] m[12] v[0]
+// c[1] c[5] c[9] c[13] m[1] m[5] m[9] m[13] v[1]
+// c[2] c[6] c[10] c[14] X m[2] m[6] m[10] m[14] X v[2]
+// c[3] c[7] c[11] c[15] m[3] m[7] m[11] m[15] v[3]
+//
+// Where 'X' denotes matrix multiplication, and v is represented as a 4x1 matrix.
+//
+// While the elements of the matrix may be specified with single or double
+// precision, the GL may store or operate on these values in less-than-single
+// precision.
+//
+// In many computer languages, 4×4 arrays are represented in row-major
+// order. The transformations just described represent these matrices in
+// column-major order. The order of the multiplication is important. For
+// example, if the current transformation is a rotation, and MultMatrix is
+// called with a translation matrix, the translation is done directly on the
+// coordinates to be transformed, while the rotation is done on the results
+// of that translation.
+//
+// GL.INVALID_OPERATION is generated if MultMatrix is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) MultMatrixd(m []float64) {
+ if len(m) != 16 {
+ panic("parameter m must have length 16 for the 4x4 matrix")
+ }
+ C.gl4_2compat_glMultMatrixd(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&m[0])))
+}
+
+// MultMatrixf multiplies the current matrix with the provided matrix.
+//
+// The m parameter must hold 16 consecutive elements of a 4x4 column-major matrix.
+//
+// The current matrix is determined by the current matrix mode (see
+// MatrixMode). It is either the projection matrix, modelview matrix, or the
+// texture matrix.
+//
+// For example, if the current matrix is C and the coordinates to be transformed
+// are v = (v[0], v[1], v[2], v[3]), then the current transformation is C × v, or
+//
+// c[0] c[4] c[8] c[12] v[0]
+// c[1] c[5] c[9] c[13] v[1]
+// c[2] c[6] c[10] c[14] X v[2]
+// c[3] c[7] c[11] c[15] v[3]
+//
+// Calling MultMatrix with an argument of m = m[0], m[1], ..., m[15]
+// replaces the current transformation with (C X M) x v, or
+//
+// c[0] c[4] c[8] c[12] m[0] m[4] m[8] m[12] v[0]
+// c[1] c[5] c[9] c[13] m[1] m[5] m[9] m[13] v[1]
+// c[2] c[6] c[10] c[14] X m[2] m[6] m[10] m[14] X v[2]
+// c[3] c[7] c[11] c[15] m[3] m[7] m[11] m[15] v[3]
+//
+// Where 'X' denotes matrix multiplication, and v is represented as a 4x1 matrix.
+//
+// While the elements of the matrix may be specified with single or double
+// precision, the GL may store or operate on these values in less-than-single
+// precision.
+//
+// In many computer languages, 4×4 arrays are represented in row-major
+// order. The transformations just described represent these matrices in
+// column-major order. The order of the multiplication is important. For
+// example, if the current transformation is a rotation, and MultMatrix is
+// called with a translation matrix, the translation is done directly on the
+// coordinates to be transformed, while the rotation is done on the results
+// of that translation.
+//
+// GL.INVALID_OPERATION is generated if MultMatrix is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) MultMatrixf(m []float32) {
+ if len(m) != 16 {
+ panic("parameter m must have length 16 for the 4x4 matrix")
+ }
+ C.gl4_2compat_glMultMatrixf(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMatrixMode.xml
+func (gl *GL) MatrixMode(mode glbase.Enum) {
+ C.gl4_2compat_glMatrixMode(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLoadMatrixd.xml
+func (gl *GL) LoadMatrixd(m []float64) {
+ C.gl4_2compat_glLoadMatrixd(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLoadMatrixf.xml
+func (gl *GL) LoadMatrixf(m []float32) {
+ C.gl4_2compat_glLoadMatrixf(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLoadIdentity.xml
+func (gl *GL) LoadIdentity() {
+ C.gl4_2compat_glLoadIdentity(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFrustum.xml
+func (gl *GL) Frustum(left, right, bottom, top, zNear, zFar float64) {
+ C.gl4_2compat_glFrustum(gl.funcs, C.GLdouble(left), C.GLdouble(right), C.GLdouble(bottom), C.GLdouble(top), C.GLdouble(zNear), C.GLdouble(zFar))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsList.xml
+func (gl *GL) IsList(list uint32) bool {
+ glresult := C.gl4_2compat_glIsList(gl.funcs, C.GLuint(list))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexGeniv.xml
+func (gl *GL) GetTexGeniv(coord, pname glbase.Enum, params []int32) {
+ C.gl4_2compat_glGetTexGeniv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexGenfv.xml
+func (gl *GL) GetTexGenfv(coord, pname glbase.Enum, params []float32) {
+ C.gl4_2compat_glGetTexGenfv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexGendv.xml
+func (gl *GL) GetTexGendv(coord, pname glbase.Enum, params []float64) {
+ C.gl4_2compat_glGetTexGendv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexEnviv.xml
+func (gl *GL) GetTexEnviv(target, pname glbase.Enum, params []int32) {
+ C.gl4_2compat_glGetTexEnviv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexEnvfv.xml
+func (gl *GL) GetTexEnvfv(target, pname glbase.Enum, params []float32) {
+ C.gl4_2compat_glGetTexEnvfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetPolygonStipple.xml
+func (gl *GL) GetPolygonStipple(mask []uint8) {
+ C.gl4_2compat_glGetPolygonStipple(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&mask[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetPixelMapusv.xml
+func (gl *GL) GetPixelMapusv(glmap glbase.Enum, values []uint16) {
+ C.gl4_2compat_glGetPixelMapusv(gl.funcs, C.GLenum(glmap), (*C.GLushort)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetPixelMapuiv.xml
+func (gl *GL) GetPixelMapuiv(glmap glbase.Enum, values []uint32) {
+ C.gl4_2compat_glGetPixelMapuiv(gl.funcs, C.GLenum(glmap), (*C.GLuint)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetPixelMapfv.xml
+func (gl *GL) GetPixelMapfv(glmap glbase.Enum, values []float32) {
+ C.gl4_2compat_glGetPixelMapfv(gl.funcs, C.GLenum(glmap), (*C.GLfloat)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetMaterialiv.xml
+func (gl *GL) GetMaterialiv(face, pname glbase.Enum, params []int32) {
+ C.gl4_2compat_glGetMaterialiv(gl.funcs, C.GLenum(face), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetMaterialfv.xml
+func (gl *GL) GetMaterialfv(face, pname glbase.Enum, params []float32) {
+ C.gl4_2compat_glGetMaterialfv(gl.funcs, C.GLenum(face), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetMapiv.xml
+func (gl *GL) GetMapiv(target, query glbase.Enum, v []int32) {
+ C.gl4_2compat_glGetMapiv(gl.funcs, C.GLenum(target), C.GLenum(query), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetMapfv.xml
+func (gl *GL) GetMapfv(target, query glbase.Enum, v []float32) {
+ C.gl4_2compat_glGetMapfv(gl.funcs, C.GLenum(target), C.GLenum(query), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetMapdv.xml
+func (gl *GL) GetMapdv(target, query glbase.Enum, v []float64) {
+ C.gl4_2compat_glGetMapdv(gl.funcs, C.GLenum(target), C.GLenum(query), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetLightiv.xml
+func (gl *GL) GetLightiv(light, pname glbase.Enum, params []int32) {
+ C.gl4_2compat_glGetLightiv(gl.funcs, C.GLenum(light), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetLightfv.xml
+func (gl *GL) GetLightfv(light, pname glbase.Enum, params []float32) {
+ C.gl4_2compat_glGetLightfv(gl.funcs, C.GLenum(light), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetClipPlane.xml
+func (gl *GL) GetClipPlane(plane glbase.Enum, equation []float64) {
+ C.gl4_2compat_glGetClipPlane(gl.funcs, C.GLenum(plane), (*C.GLdouble)(unsafe.Pointer(&equation[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawPixels.xml
+func (gl *GL) DrawPixels(width, height int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2compat_glDrawPixels(gl.funcs, C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyPixels.xml
+func (gl *GL) CopyPixels(x, y, width, height int, gltype glbase.Enum) {
+ C.gl4_2compat_glCopyPixels(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height), C.GLenum(gltype))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPixelMapusv.xml
+func (gl *GL) PixelMapusv(glmap glbase.Enum, mapsize int32, values []uint16) {
+ C.gl4_2compat_glPixelMapusv(gl.funcs, C.GLenum(glmap), C.GLint(mapsize), (*C.GLushort)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPixelMapuiv.xml
+func (gl *GL) PixelMapuiv(glmap glbase.Enum, mapsize int32, values []uint32) {
+ C.gl4_2compat_glPixelMapuiv(gl.funcs, C.GLenum(glmap), C.GLint(mapsize), (*C.GLuint)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPixelMapfv.xml
+func (gl *GL) PixelMapfv(glmap glbase.Enum, mapsize int32, values []float32) {
+ C.gl4_2compat_glPixelMapfv(gl.funcs, C.GLenum(glmap), C.GLint(mapsize), (*C.GLfloat)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPixelTransferi.xml
+func (gl *GL) PixelTransferi(pname glbase.Enum, param int32) {
+ C.gl4_2compat_glPixelTransferi(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPixelTransferf.xml
+func (gl *GL) PixelTransferf(pname glbase.Enum, param float32) {
+ C.gl4_2compat_glPixelTransferf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPixelZoom.xml
+func (gl *GL) PixelZoom(xfactor, yfactor float32) {
+ C.gl4_2compat_glPixelZoom(gl.funcs, C.GLfloat(xfactor), C.GLfloat(yfactor))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glAlphaFunc.xml
+func (gl *GL) AlphaFunc(glfunc glbase.Enum, ref float32) {
+ C.gl4_2compat_glAlphaFunc(gl.funcs, C.GLenum(glfunc), C.GLfloat(ref))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEvalPoint2.xml
+func (gl *GL) EvalPoint2(i, j int32) {
+ C.gl4_2compat_glEvalPoint2(gl.funcs, C.GLint(i), C.GLint(j))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEvalMesh2.xml
+func (gl *GL) EvalMesh2(mode glbase.Enum, i1, i2, j1, j2 int32) {
+ C.gl4_2compat_glEvalMesh2(gl.funcs, C.GLenum(mode), C.GLint(i1), C.GLint(i2), C.GLint(j1), C.GLint(j2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEvalPoint1.xml
+func (gl *GL) EvalPoint1(i int32) {
+ C.gl4_2compat_glEvalPoint1(gl.funcs, C.GLint(i))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEvalMesh1.xml
+func (gl *GL) EvalMesh1(mode glbase.Enum, i1, i2 int32) {
+ C.gl4_2compat_glEvalMesh1(gl.funcs, C.GLenum(mode), C.GLint(i1), C.GLint(i2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEvalCoord2fv.xml
+func (gl *GL) EvalCoord2fv(u []float32) {
+ if len(u) != 2 {
+ panic("parameter u has incorrect length")
+ }
+ C.gl4_2compat_glEvalCoord2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&u[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEvalCoord2f.xml
+func (gl *GL) EvalCoord2f(u, v float32) {
+ C.gl4_2compat_glEvalCoord2f(gl.funcs, C.GLfloat(u), C.GLfloat(v))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEvalCoord2dv.xml
+func (gl *GL) EvalCoord2dv(u []float64) {
+ if len(u) != 2 {
+ panic("parameter u has incorrect length")
+ }
+ C.gl4_2compat_glEvalCoord2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&u[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEvalCoord2d.xml
+func (gl *GL) EvalCoord2d(u, v float64) {
+ C.gl4_2compat_glEvalCoord2d(gl.funcs, C.GLdouble(u), C.GLdouble(v))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEvalCoord1fv.xml
+func (gl *GL) EvalCoord1fv(u []float32) {
+ C.gl4_2compat_glEvalCoord1fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&u[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEvalCoord1f.xml
+func (gl *GL) EvalCoord1f(u float32) {
+ C.gl4_2compat_glEvalCoord1f(gl.funcs, C.GLfloat(u))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEvalCoord1dv.xml
+func (gl *GL) EvalCoord1dv(u []float64) {
+ C.gl4_2compat_glEvalCoord1dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&u[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEvalCoord1d.xml
+func (gl *GL) EvalCoord1d(u float64) {
+ C.gl4_2compat_glEvalCoord1d(gl.funcs, C.GLdouble(u))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMapGrid2f.xml
+func (gl *GL) MapGrid2f(un int32, u1, u2 float32, vn int32, v1, v2 float32) {
+ C.gl4_2compat_glMapGrid2f(gl.funcs, C.GLint(un), C.GLfloat(u1), C.GLfloat(u2), C.GLint(vn), C.GLfloat(v1), C.GLfloat(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMapGrid2d.xml
+func (gl *GL) MapGrid2d(un int32, u1, u2 float64, vn int32, v1, v2 float64) {
+ C.gl4_2compat_glMapGrid2d(gl.funcs, C.GLint(un), C.GLdouble(u1), C.GLdouble(u2), C.GLint(vn), C.GLdouble(v1), C.GLdouble(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMapGrid1f.xml
+func (gl *GL) MapGrid1f(un int32, u1, u2 float32) {
+ C.gl4_2compat_glMapGrid1f(gl.funcs, C.GLint(un), C.GLfloat(u1), C.GLfloat(u2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMapGrid1d.xml
+func (gl *GL) MapGrid1d(un int32, u1, u2 float64) {
+ C.gl4_2compat_glMapGrid1d(gl.funcs, C.GLint(un), C.GLdouble(u1), C.GLdouble(u2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMap2f.xml
+func (gl *GL) Map2f(target glbase.Enum, u1, u2 float32, ustride, uorder int32, v1, v2 float32, vstride, vorder int32, points []float32) {
+ C.gl4_2compat_glMap2f(gl.funcs, C.GLenum(target), C.GLfloat(u1), C.GLfloat(u2), C.GLint(ustride), C.GLint(uorder), C.GLfloat(v1), C.GLfloat(v2), C.GLint(vstride), C.GLint(vorder), (*C.GLfloat)(unsafe.Pointer(&points[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMap2d.xml
+func (gl *GL) Map2d(target glbase.Enum, u1, u2 float64, ustride, uorder int32, v1, v2 float64, vstride, vorder int32, points []float64) {
+ C.gl4_2compat_glMap2d(gl.funcs, C.GLenum(target), C.GLdouble(u1), C.GLdouble(u2), C.GLint(ustride), C.GLint(uorder), C.GLdouble(v1), C.GLdouble(v2), C.GLint(vstride), C.GLint(vorder), (*C.GLdouble)(unsafe.Pointer(&points[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMap1f.xml
+func (gl *GL) Map1f(target glbase.Enum, u1, u2 float32, stride, order int, points []float32) {
+ C.gl4_2compat_glMap1f(gl.funcs, C.GLenum(target), C.GLfloat(u1), C.GLfloat(u2), C.GLint(stride), C.GLint(order), (*C.GLfloat)(unsafe.Pointer(&points[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMap1d.xml
+func (gl *GL) Map1d(target glbase.Enum, u1, u2 float64, stride, order int, points []float64) {
+ C.gl4_2compat_glMap1d(gl.funcs, C.GLenum(target), C.GLdouble(u1), C.GLdouble(u2), C.GLint(stride), C.GLint(order), (*C.GLdouble)(unsafe.Pointer(&points[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPushAttrib.xml
+func (gl *GL) PushAttrib(mask glbase.Bitfield) {
+ C.gl4_2compat_glPushAttrib(gl.funcs, C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPopAttrib.xml
+func (gl *GL) PopAttrib() {
+ C.gl4_2compat_glPopAttrib(gl.funcs)
+}
+
+// Accum executes an operation on the accumulation buffer.
+//
+// Parameter op defines the accumulation buffer operation (GL.ACCUM, GL.LOAD,
+// GL.ADD, GL.MULT, or GL.RETURN) and specifies how the value parameter is
+// used.
+//
+// The accumulation buffer is an extended-range color buffer. Images are not
+// rendered into it. Rather, images rendered into one of the color buffers
+// are added to the contents of the accumulation buffer after rendering.
+// Effects such as antialiasing (of points, lines, and polygons), motion
+// blur, and depth of field can be created by accumulating images generated
+// with different transformation matrices.
+//
+// Each pixel in the accumulation buffer consists of red, green, blue, and
+// alpha values. The number of bits per component in the accumulation buffer
+// depends on the implementation. You can examine this number by calling
+// GetIntegerv four times, with arguments GL.ACCUM_RED_BITS,
+// GL.ACCUM_GREEN_BITS, GL.ACCUM_BLUE_BITS, and GL.ACCUM_ALPHA_BITS.
+// Regardless of the number of bits per component, the range of values stored
+// by each component is (-1, 1). The accumulation buffer pixels are mapped
+// one-to-one with frame buffer pixels.
+//
+// All accumulation buffer operations are limited to the area of the current
+// scissor box and applied identically to the red, green, blue, and alpha
+// components of each pixel. If a Accum operation results in a value outside
+// the range (-1, 1), the contents of an accumulation buffer pixel component
+// are undefined.
+//
+// The operations are as follows:
+//
+// GL.ACCUM
+// Obtains R, G, B, and A values from the buffer currently selected for
+// reading (see ReadBuffer). Each component value is divided by 2 n -
+// 1 , where n is the number of bits allocated to each color component
+// in the currently selected buffer. The result is a floating-point
+// value in the range 0 1 , which is multiplied by value and added to
+// the corresponding pixel component in the accumulation buffer,
+// thereby updating the accumulation buffer.
+//
+// GL.LOAD
+// Similar to GL.ACCUM, except that the current value in the
+// accumulation buffer is not used in the calculation of the new value.
+// That is, the R, G, B, and A values from the currently selected
+// buffer are divided by 2 n - 1 , multiplied by value, and then stored
+// in the corresponding accumulation buffer cell, overwriting the
+// current value.
+//
+// GL.ADD
+// Adds value to each R, G, B, and A in the accumulation buffer.
+//
+// GL.MULT
+// Multiplies each R, G, B, and A in the accumulation buffer by value
+// and returns the scaled component to its corresponding accumulation
+// buffer location.
+//
+// GL.RETURN
+// Transfers accumulation buffer values to the color buffer or buffers
+// currently selected for writing. Each R, G, B, and A component is
+// multiplied by value, then multiplied by 2 n - 1 , clamped to the
+// range 0 2 n - 1 , and stored in the corresponding display buffer
+// cell. The only fragment operations that are applied to this transfer
+// are pixel ownership, scissor, dithering, and color writemasks.
+//
+// To clear the accumulation buffer, call ClearAccum with R, G, B, and A
+// values to set it to, then call Clear with the accumulation buffer
+// enabled.
+//
+// Error GL.INVALID_ENUM is generated if op is not an accepted value.
+// GL.INVALID_OPERATION is generated if there is no accumulation buffer.
+// GL.INVALID_OPERATION is generated if Accum is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) Accum(op glbase.Enum, value float32) {
+ C.gl4_2compat_glAccum(gl.funcs, C.GLenum(op), C.GLfloat(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIndexMask.xml
+func (gl *GL) IndexMask(mask uint32) {
+ C.gl4_2compat_glIndexMask(gl.funcs, C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearIndex.xml
+func (gl *GL) ClearIndex(c float32) {
+ C.gl4_2compat_glClearIndex(gl.funcs, C.GLfloat(c))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearAccum.xml
+func (gl *GL) ClearAccum(red, green, blue, alpha float32) {
+ C.gl4_2compat_glClearAccum(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPushName.xml
+func (gl *GL) PushName(name uint32) {
+ C.gl4_2compat_glPushName(gl.funcs, C.GLuint(name))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPopName.xml
+func (gl *GL) PopName() {
+ C.gl4_2compat_glPopName(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPassThrough.xml
+func (gl *GL) PassThrough(token float32) {
+ C.gl4_2compat_glPassThrough(gl.funcs, C.GLfloat(token))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLoadName.xml
+func (gl *GL) LoadName(name uint32) {
+ C.gl4_2compat_glLoadName(gl.funcs, C.GLuint(name))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glInitNames.xml
+func (gl *GL) InitNames() {
+ C.gl4_2compat_glInitNames(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRenderMode.xml
+func (gl *GL) RenderMode(mode glbase.Enum) int32 {
+ glresult := C.gl4_2compat_glRenderMode(gl.funcs, C.GLenum(mode))
+ return int32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSelectBuffer.xml
+func (gl *GL) SelectBuffer(size int, buffer []glbase.Buffer) {
+ C.gl4_2compat_glSelectBuffer(gl.funcs, C.GLsizei(size), (*C.GLuint)(unsafe.Pointer(&buffer[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFeedbackBuffer.xml
+func (gl *GL) FeedbackBuffer(size int, gltype glbase.Enum, buffer []float32) {
+ C.gl4_2compat_glFeedbackBuffer(gl.funcs, C.GLsizei(size), C.GLenum(gltype), (*C.GLfloat)(unsafe.Pointer(&buffer[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexGeniv.xml
+func (gl *GL) TexGeniv(coord, pname glbase.Enum, params []int32) {
+ C.gl4_2compat_glTexGeniv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexGeni.xml
+func (gl *GL) TexGeni(coord, pname glbase.Enum, param int32) {
+ C.gl4_2compat_glTexGeni(gl.funcs, C.GLenum(coord), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexGenfv.xml
+func (gl *GL) TexGenfv(coord, pname glbase.Enum, params []float32) {
+ C.gl4_2compat_glTexGenfv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexGenf.xml
+func (gl *GL) TexGenf(coord, pname glbase.Enum, param float32) {
+ C.gl4_2compat_glTexGenf(gl.funcs, C.GLenum(coord), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexGendv.xml
+func (gl *GL) TexGendv(coord, pname glbase.Enum, params []float64) {
+ C.gl4_2compat_glTexGendv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexGend.xml
+func (gl *GL) TexGend(coord, pname glbase.Enum, param float64) {
+ C.gl4_2compat_glTexGend(gl.funcs, C.GLenum(coord), C.GLenum(pname), C.GLdouble(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexEnviv.xml
+func (gl *GL) TexEnviv(target, pname glbase.Enum, params []int32) {
+ C.gl4_2compat_glTexEnviv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexEnvi.xml
+func (gl *GL) TexEnvi(target, pname glbase.Enum, param int32) {
+ C.gl4_2compat_glTexEnvi(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexEnvfv.xml
+func (gl *GL) TexEnvfv(target, pname glbase.Enum, params []float32) {
+ C.gl4_2compat_glTexEnvfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexEnvf.xml
+func (gl *GL) TexEnvf(target, pname glbase.Enum, param float32) {
+ C.gl4_2compat_glTexEnvf(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glShadeModel.xml
+func (gl *GL) ShadeModel(mode glbase.Enum) {
+ C.gl4_2compat_glShadeModel(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPolygonStipple.xml
+func (gl *GL) PolygonStipple(mask []uint8) {
+ C.gl4_2compat_glPolygonStipple(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&mask[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMaterialiv.xml
+func (gl *GL) Materialiv(face, pname glbase.Enum, params []int32) {
+ C.gl4_2compat_glMaterialiv(gl.funcs, C.GLenum(face), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMateriali.xml
+func (gl *GL) Materiali(face, pname glbase.Enum, param int32) {
+ C.gl4_2compat_glMateriali(gl.funcs, C.GLenum(face), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMaterialfv.xml
+func (gl *GL) Materialfv(face, pname glbase.Enum, params []float32) {
+ C.gl4_2compat_glMaterialfv(gl.funcs, C.GLenum(face), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMaterialf.xml
+func (gl *GL) Materialf(face, pname glbase.Enum, param float32) {
+ C.gl4_2compat_glMaterialf(gl.funcs, C.GLenum(face), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLineStipple.xml
+func (gl *GL) LineStipple(factor int32, pattern uint16) {
+ C.gl4_2compat_glLineStipple(gl.funcs, C.GLint(factor), C.GLushort(pattern))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLightModeliv.xml
+func (gl *GL) LightModeliv(pname glbase.Enum, params []int32) {
+ C.gl4_2compat_glLightModeliv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLightModeli.xml
+func (gl *GL) LightModeli(pname glbase.Enum, param int32) {
+ C.gl4_2compat_glLightModeli(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLightModelfv.xml
+func (gl *GL) LightModelfv(pname glbase.Enum, params []float32) {
+ C.gl4_2compat_glLightModelfv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLightModelf.xml
+func (gl *GL) LightModelf(pname glbase.Enum, param float32) {
+ C.gl4_2compat_glLightModelf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLightiv.xml
+func (gl *GL) Lightiv(light, pname glbase.Enum, params []int32) {
+ C.gl4_2compat_glLightiv(gl.funcs, C.GLenum(light), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLighti.xml
+func (gl *GL) Lighti(light, pname glbase.Enum, param int32) {
+ C.gl4_2compat_glLighti(gl.funcs, C.GLenum(light), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLightfv.xml
+func (gl *GL) Lightfv(light, pname glbase.Enum, params []float32) {
+ C.gl4_2compat_glLightfv(gl.funcs, C.GLenum(light), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLightf.xml
+func (gl *GL) Lightf(light, pname glbase.Enum, param float32) {
+ C.gl4_2compat_glLightf(gl.funcs, C.GLenum(light), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFogiv.xml
+func (gl *GL) Fogiv(pname glbase.Enum, params []int32) {
+ C.gl4_2compat_glFogiv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFogi.xml
+func (gl *GL) Fogi(pname glbase.Enum, param int32) {
+ C.gl4_2compat_glFogi(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFogfv.xml
+func (gl *GL) Fogfv(pname glbase.Enum, params []float32) {
+ C.gl4_2compat_glFogfv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFogf.xml
+func (gl *GL) Fogf(pname glbase.Enum, param float32) {
+ C.gl4_2compat_glFogf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorMaterial.xml
+func (gl *GL) ColorMaterial(face, mode glbase.Enum) {
+ C.gl4_2compat_glColorMaterial(gl.funcs, C.GLenum(face), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClipPlane.xml
+func (gl *GL) ClipPlane(plane glbase.Enum, equation []float64) {
+ C.gl4_2compat_glClipPlane(gl.funcs, C.GLenum(plane), (*C.GLdouble)(unsafe.Pointer(&equation[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex4sv.xml
+func (gl *GL) Vertex4sv(v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glVertex4sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex4s.xml
+func (gl *GL) Vertex4s(x, y, z, w int16) {
+ C.gl4_2compat_glVertex4s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z), C.GLshort(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex4iv.xml
+func (gl *GL) Vertex4iv(v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glVertex4iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex4i.xml
+func (gl *GL) Vertex4i(x, y, z, w int) {
+ C.gl4_2compat_glVertex4i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z), C.GLint(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex4fv.xml
+func (gl *GL) Vertex4fv(v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glVertex4fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex4f.xml
+func (gl *GL) Vertex4f(x, y, z, w float32) {
+ C.gl4_2compat_glVertex4f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z), C.GLfloat(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex4dv.xml
+func (gl *GL) Vertex4dv(v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glVertex4dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex4d.xml
+func (gl *GL) Vertex4d(x, y, z, w float64) {
+ C.gl4_2compat_glVertex4d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z), C.GLdouble(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex3sv.xml
+func (gl *GL) Vertex3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glVertex3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex3s.xml
+func (gl *GL) Vertex3s(x, y, z int16) {
+ C.gl4_2compat_glVertex3s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex3iv.xml
+func (gl *GL) Vertex3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glVertex3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex3i.xml
+func (gl *GL) Vertex3i(x, y, z int) {
+ C.gl4_2compat_glVertex3i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex3fv.xml
+func (gl *GL) Vertex3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glVertex3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex3f.xml
+func (gl *GL) Vertex3f(x, y, z float32) {
+ C.gl4_2compat_glVertex3f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex3dv.xml
+func (gl *GL) Vertex3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glVertex3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex3d.xml
+func (gl *GL) Vertex3d(x, y, z float64) {
+ C.gl4_2compat_glVertex3d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex2sv.xml
+func (gl *GL) Vertex2sv(v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glVertex2sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex2s.xml
+func (gl *GL) Vertex2s(x, y int16) {
+ C.gl4_2compat_glVertex2s(gl.funcs, C.GLshort(x), C.GLshort(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex2iv.xml
+func (gl *GL) Vertex2iv(v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glVertex2iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex2i.xml
+func (gl *GL) Vertex2i(x, y int) {
+ C.gl4_2compat_glVertex2i(gl.funcs, C.GLint(x), C.GLint(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex2fv.xml
+func (gl *GL) Vertex2fv(v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glVertex2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex2f.xml
+func (gl *GL) Vertex2f(x, y float32) {
+ C.gl4_2compat_glVertex2f(gl.funcs, C.GLfloat(x), C.GLfloat(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex2dv.xml
+func (gl *GL) Vertex2dv(v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glVertex2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex2d.xml
+func (gl *GL) Vertex2d(x, y float64) {
+ C.gl4_2compat_glVertex2d(gl.funcs, C.GLdouble(x), C.GLdouble(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord4sv.xml
+func (gl *GL) TexCoord4sv(v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glTexCoord4sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord4s.xml
+func (gl *GL) TexCoord4s(s, t, r, q int16) {
+ C.gl4_2compat_glTexCoord4s(gl.funcs, C.GLshort(s), C.GLshort(t), C.GLshort(r), C.GLshort(q))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord4iv.xml
+func (gl *GL) TexCoord4iv(v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glTexCoord4iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord4i.xml
+func (gl *GL) TexCoord4i(s, t, r, q int32) {
+ C.gl4_2compat_glTexCoord4i(gl.funcs, C.GLint(s), C.GLint(t), C.GLint(r), C.GLint(q))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord4fv.xml
+func (gl *GL) TexCoord4fv(v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glTexCoord4fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord4f.xml
+func (gl *GL) TexCoord4f(s, t, r, q float32) {
+ C.gl4_2compat_glTexCoord4f(gl.funcs, C.GLfloat(s), C.GLfloat(t), C.GLfloat(r), C.GLfloat(q))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord4dv.xml
+func (gl *GL) TexCoord4dv(v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glTexCoord4dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord4d.xml
+func (gl *GL) TexCoord4d(s, t, r, q float64) {
+ C.gl4_2compat_glTexCoord4d(gl.funcs, C.GLdouble(s), C.GLdouble(t), C.GLdouble(r), C.GLdouble(q))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord3sv.xml
+func (gl *GL) TexCoord3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glTexCoord3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord3s.xml
+func (gl *GL) TexCoord3s(s, t, r int16) {
+ C.gl4_2compat_glTexCoord3s(gl.funcs, C.GLshort(s), C.GLshort(t), C.GLshort(r))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord3iv.xml
+func (gl *GL) TexCoord3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glTexCoord3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord3i.xml
+func (gl *GL) TexCoord3i(s, t, r int32) {
+ C.gl4_2compat_glTexCoord3i(gl.funcs, C.GLint(s), C.GLint(t), C.GLint(r))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord3fv.xml
+func (gl *GL) TexCoord3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glTexCoord3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord3f.xml
+func (gl *GL) TexCoord3f(s, t, r float32) {
+ C.gl4_2compat_glTexCoord3f(gl.funcs, C.GLfloat(s), C.GLfloat(t), C.GLfloat(r))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord3dv.xml
+func (gl *GL) TexCoord3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glTexCoord3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord3d.xml
+func (gl *GL) TexCoord3d(s, t, r float64) {
+ C.gl4_2compat_glTexCoord3d(gl.funcs, C.GLdouble(s), C.GLdouble(t), C.GLdouble(r))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord2sv.xml
+func (gl *GL) TexCoord2sv(v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glTexCoord2sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord2s.xml
+func (gl *GL) TexCoord2s(s, t int16) {
+ C.gl4_2compat_glTexCoord2s(gl.funcs, C.GLshort(s), C.GLshort(t))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord2iv.xml
+func (gl *GL) TexCoord2iv(v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glTexCoord2iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord2i.xml
+func (gl *GL) TexCoord2i(s, t int32) {
+ C.gl4_2compat_glTexCoord2i(gl.funcs, C.GLint(s), C.GLint(t))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord2fv.xml
+func (gl *GL) TexCoord2fv(v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glTexCoord2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord2f.xml
+func (gl *GL) TexCoord2f(s, t float32) {
+ C.gl4_2compat_glTexCoord2f(gl.funcs, C.GLfloat(s), C.GLfloat(t))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord2dv.xml
+func (gl *GL) TexCoord2dv(v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glTexCoord2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord2d.xml
+func (gl *GL) TexCoord2d(s, t float64) {
+ C.gl4_2compat_glTexCoord2d(gl.funcs, C.GLdouble(s), C.GLdouble(t))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord1sv.xml
+func (gl *GL) TexCoord1sv(v []int16) {
+ C.gl4_2compat_glTexCoord1sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord1s.xml
+func (gl *GL) TexCoord1s(s int16) {
+ C.gl4_2compat_glTexCoord1s(gl.funcs, C.GLshort(s))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord1iv.xml
+func (gl *GL) TexCoord1iv(v []int32) {
+ C.gl4_2compat_glTexCoord1iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord1i.xml
+func (gl *GL) TexCoord1i(s int32) {
+ C.gl4_2compat_glTexCoord1i(gl.funcs, C.GLint(s))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord1fv.xml
+func (gl *GL) TexCoord1fv(v []float32) {
+ C.gl4_2compat_glTexCoord1fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord1f.xml
+func (gl *GL) TexCoord1f(s float32) {
+ C.gl4_2compat_glTexCoord1f(gl.funcs, C.GLfloat(s))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord1dv.xml
+func (gl *GL) TexCoord1dv(v []float64) {
+ C.gl4_2compat_glTexCoord1dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord1d.xml
+func (gl *GL) TexCoord1d(s float64) {
+ C.gl4_2compat_glTexCoord1d(gl.funcs, C.GLdouble(s))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRectsv.xml
+func (gl *GL) Rectsv(v1, v2 []int16) {
+ C.gl4_2compat_glRectsv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v1[0])), (*C.GLshort)(unsafe.Pointer(&v2[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRects.xml
+func (gl *GL) Rects(x1, y1, x2, y2 int16) {
+ C.gl4_2compat_glRects(gl.funcs, C.GLshort(x1), C.GLshort(y1), C.GLshort(x2), C.GLshort(y2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRectiv.xml
+func (gl *GL) Rectiv(v1, v2 []int32) {
+ C.gl4_2compat_glRectiv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v1[0])), (*C.GLint)(unsafe.Pointer(&v2[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRecti.xml
+func (gl *GL) Recti(x1, y1, x2, y2 int32) {
+ C.gl4_2compat_glRecti(gl.funcs, C.GLint(x1), C.GLint(y1), C.GLint(x2), C.GLint(y2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRectfv.xml
+func (gl *GL) Rectfv(v1, v2 []float32) {
+ C.gl4_2compat_glRectfv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v1[0])), (*C.GLfloat)(unsafe.Pointer(&v2[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRectf.xml
+func (gl *GL) Rectf(x1, y1, x2, y2 float32) {
+ C.gl4_2compat_glRectf(gl.funcs, C.GLfloat(x1), C.GLfloat(y1), C.GLfloat(x2), C.GLfloat(y2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRectdv.xml
+func (gl *GL) Rectdv(v1, v2 []float64) {
+ C.gl4_2compat_glRectdv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v1[0])), (*C.GLdouble)(unsafe.Pointer(&v2[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRectd.xml
+func (gl *GL) Rectd(x1, y1, x2, y2 float64) {
+ C.gl4_2compat_glRectd(gl.funcs, C.GLdouble(x1), C.GLdouble(y1), C.GLdouble(x2), C.GLdouble(y2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos4sv.xml
+func (gl *GL) RasterPos4sv(v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glRasterPos4sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos4s.xml
+func (gl *GL) RasterPos4s(x, y, z, w int16) {
+ C.gl4_2compat_glRasterPos4s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z), C.GLshort(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos4iv.xml
+func (gl *GL) RasterPos4iv(v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glRasterPos4iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos4i.xml
+func (gl *GL) RasterPos4i(x, y, z, w int) {
+ C.gl4_2compat_glRasterPos4i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z), C.GLint(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos4fv.xml
+func (gl *GL) RasterPos4fv(v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glRasterPos4fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos4f.xml
+func (gl *GL) RasterPos4f(x, y, z, w float32) {
+ C.gl4_2compat_glRasterPos4f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z), C.GLfloat(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos4dv.xml
+func (gl *GL) RasterPos4dv(v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glRasterPos4dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos4d.xml
+func (gl *GL) RasterPos4d(x, y, z, w float64) {
+ C.gl4_2compat_glRasterPos4d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z), C.GLdouble(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos3sv.xml
+func (gl *GL) RasterPos3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glRasterPos3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos3s.xml
+func (gl *GL) RasterPos3s(x, y, z int16) {
+ C.gl4_2compat_glRasterPos3s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos3iv.xml
+func (gl *GL) RasterPos3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glRasterPos3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos3i.xml
+func (gl *GL) RasterPos3i(x, y, z int) {
+ C.gl4_2compat_glRasterPos3i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos3fv.xml
+func (gl *GL) RasterPos3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glRasterPos3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos3f.xml
+func (gl *GL) RasterPos3f(x, y, z float32) {
+ C.gl4_2compat_glRasterPos3f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos3dv.xml
+func (gl *GL) RasterPos3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glRasterPos3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos3d.xml
+func (gl *GL) RasterPos3d(x, y, z float64) {
+ C.gl4_2compat_glRasterPos3d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos2sv.xml
+func (gl *GL) RasterPos2sv(v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glRasterPos2sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos2s.xml
+func (gl *GL) RasterPos2s(x, y int16) {
+ C.gl4_2compat_glRasterPos2s(gl.funcs, C.GLshort(x), C.GLshort(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos2iv.xml
+func (gl *GL) RasterPos2iv(v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glRasterPos2iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos2i.xml
+func (gl *GL) RasterPos2i(x, y int) {
+ C.gl4_2compat_glRasterPos2i(gl.funcs, C.GLint(x), C.GLint(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos2fv.xml
+func (gl *GL) RasterPos2fv(v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glRasterPos2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos2f.xml
+func (gl *GL) RasterPos2f(x, y float32) {
+ C.gl4_2compat_glRasterPos2f(gl.funcs, C.GLfloat(x), C.GLfloat(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos2dv.xml
+func (gl *GL) RasterPos2dv(v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glRasterPos2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos2d.xml
+func (gl *GL) RasterPos2d(x, y float64) {
+ C.gl4_2compat_glRasterPos2d(gl.funcs, C.GLdouble(x), C.GLdouble(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNormal3sv.xml
+func (gl *GL) Normal3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glNormal3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNormal3s.xml
+func (gl *GL) Normal3s(nx, ny, nz int16) {
+ C.gl4_2compat_glNormal3s(gl.funcs, C.GLshort(nx), C.GLshort(ny), C.GLshort(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNormal3iv.xml
+func (gl *GL) Normal3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glNormal3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNormal3i.xml
+func (gl *GL) Normal3i(nx, ny, nz int32) {
+ C.gl4_2compat_glNormal3i(gl.funcs, C.GLint(nx), C.GLint(ny), C.GLint(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNormal3fv.xml
+func (gl *GL) Normal3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glNormal3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNormal3f.xml
+func (gl *GL) Normal3f(nx, ny, nz float32) {
+ C.gl4_2compat_glNormal3f(gl.funcs, C.GLfloat(nx), C.GLfloat(ny), C.GLfloat(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNormal3dv.xml
+func (gl *GL) Normal3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glNormal3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNormal3d.xml
+func (gl *GL) Normal3d(nx, ny, nz float64) {
+ C.gl4_2compat_glNormal3d(gl.funcs, C.GLdouble(nx), C.GLdouble(ny), C.GLdouble(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNormal3bv.xml
+func (gl *GL) Normal3bv(v []byte) {
+ C.gl4_2compat_glNormal3bv(gl.funcs, (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNormal3b.xml
+func (gl *GL) Normal3b(nx, ny, nz byte) {
+ C.gl4_2compat_glNormal3b(gl.funcs, C.GLbyte(nx), C.GLbyte(ny), C.GLbyte(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIndexsv.xml
+func (gl *GL) Indexsv(c []int16) {
+ C.gl4_2compat_glIndexsv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIndexs.xml
+func (gl *GL) Indexs(c int16) {
+ C.gl4_2compat_glIndexs(gl.funcs, C.GLshort(c))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIndexiv.xml
+func (gl *GL) Indexiv(c []int32) {
+ C.gl4_2compat_glIndexiv(gl.funcs, (*C.GLint)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIndexi.xml
+func (gl *GL) Indexi(c int32) {
+ C.gl4_2compat_glIndexi(gl.funcs, C.GLint(c))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIndexfv.xml
+func (gl *GL) Indexfv(c []float32) {
+ C.gl4_2compat_glIndexfv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIndexf.xml
+func (gl *GL) Indexf(c float32) {
+ C.gl4_2compat_glIndexf(gl.funcs, C.GLfloat(c))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIndexdv.xml
+func (gl *GL) Indexdv(c []float64) {
+ C.gl4_2compat_glIndexdv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIndexd.xml
+func (gl *GL) Indexd(c float64) {
+ C.gl4_2compat_glIndexd(gl.funcs, C.GLdouble(c))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEnd.xml
+func (gl *GL) End() {
+ C.gl4_2compat_glEnd(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEdgeFlagv.xml
+func (gl *GL) EdgeFlagv(flag []bool) {
+ C.gl4_2compat_glEdgeFlagv(gl.funcs, (*C.GLboolean)(unsafe.Pointer(&flag[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEdgeFlag.xml
+func (gl *GL) EdgeFlag(flag bool) {
+ C.gl4_2compat_glEdgeFlag(gl.funcs, *(*C.GLboolean)(unsafe.Pointer(&flag)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4usv.xml
+func (gl *GL) Color4usv(v []uint16) {
+ C.gl4_2compat_glColor4usv(gl.funcs, (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4us.xml
+func (gl *GL) Color4us(red, green, blue, alpha uint16) {
+ C.gl4_2compat_glColor4us(gl.funcs, C.GLushort(red), C.GLushort(green), C.GLushort(blue), C.GLushort(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4uiv.xml
+func (gl *GL) Color4uiv(v []uint32) {
+ C.gl4_2compat_glColor4uiv(gl.funcs, (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4ui.xml
+func (gl *GL) Color4ui(red, green, blue, alpha uint32) {
+ C.gl4_2compat_glColor4ui(gl.funcs, C.GLuint(red), C.GLuint(green), C.GLuint(blue), C.GLuint(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4ubv.xml
+func (gl *GL) Color4ubv(v []uint8) {
+ C.gl4_2compat_glColor4ubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4ub.xml
+func (gl *GL) Color4ub(red, green, blue, alpha uint8) {
+ C.gl4_2compat_glColor4ub(gl.funcs, C.GLubyte(red), C.GLubyte(green), C.GLubyte(blue), C.GLubyte(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4sv.xml
+func (gl *GL) Color4sv(v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glColor4sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4s.xml
+func (gl *GL) Color4s(red, green, blue, alpha int16) {
+ C.gl4_2compat_glColor4s(gl.funcs, C.GLshort(red), C.GLshort(green), C.GLshort(blue), C.GLshort(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4iv.xml
+func (gl *GL) Color4iv(v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glColor4iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4i.xml
+func (gl *GL) Color4i(red, green, blue, alpha int32) {
+ C.gl4_2compat_glColor4i(gl.funcs, C.GLint(red), C.GLint(green), C.GLint(blue), C.GLint(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4fv.xml
+func (gl *GL) Color4fv(v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glColor4fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4f.xml
+func (gl *GL) Color4f(red, green, blue, alpha float32) {
+ C.gl4_2compat_glColor4f(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4dv.xml
+func (gl *GL) Color4dv(v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glColor4dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4d.xml
+func (gl *GL) Color4d(red, green, blue, alpha float64) {
+ C.gl4_2compat_glColor4d(gl.funcs, C.GLdouble(red), C.GLdouble(green), C.GLdouble(blue), C.GLdouble(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4bv.xml
+func (gl *GL) Color4bv(v []byte) {
+ C.gl4_2compat_glColor4bv(gl.funcs, (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4b.xml
+func (gl *GL) Color4b(red, green, blue, alpha byte) {
+ C.gl4_2compat_glColor4b(gl.funcs, C.GLbyte(red), C.GLbyte(green), C.GLbyte(blue), C.GLbyte(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3usv.xml
+func (gl *GL) Color3usv(v []uint16) {
+ C.gl4_2compat_glColor3usv(gl.funcs, (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3us.xml
+func (gl *GL) Color3us(red, green, blue uint16) {
+ C.gl4_2compat_glColor3us(gl.funcs, C.GLushort(red), C.GLushort(green), C.GLushort(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3uiv.xml
+func (gl *GL) Color3uiv(v []uint32) {
+ C.gl4_2compat_glColor3uiv(gl.funcs, (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3ui.xml
+func (gl *GL) Color3ui(red, green, blue uint32) {
+ C.gl4_2compat_glColor3ui(gl.funcs, C.GLuint(red), C.GLuint(green), C.GLuint(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3ubv.xml
+func (gl *GL) Color3ubv(v []uint8) {
+ C.gl4_2compat_glColor3ubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3ub.xml
+func (gl *GL) Color3ub(red, green, blue uint8) {
+ C.gl4_2compat_glColor3ub(gl.funcs, C.GLubyte(red), C.GLubyte(green), C.GLubyte(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3sv.xml
+func (gl *GL) Color3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glColor3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3s.xml
+func (gl *GL) Color3s(red, green, blue int16) {
+ C.gl4_2compat_glColor3s(gl.funcs, C.GLshort(red), C.GLshort(green), C.GLshort(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3iv.xml
+func (gl *GL) Color3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glColor3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3i.xml
+func (gl *GL) Color3i(red, green, blue int32) {
+ C.gl4_2compat_glColor3i(gl.funcs, C.GLint(red), C.GLint(green), C.GLint(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3fv.xml
+func (gl *GL) Color3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glColor3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3f.xml
+func (gl *GL) Color3f(red, green, blue float32) {
+ C.gl4_2compat_glColor3f(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3dv.xml
+func (gl *GL) Color3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glColor3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3d.xml
+func (gl *GL) Color3d(red, green, blue float64) {
+ C.gl4_2compat_glColor3d(gl.funcs, C.GLdouble(red), C.GLdouble(green), C.GLdouble(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3bv.xml
+func (gl *GL) Color3bv(v []byte) {
+ C.gl4_2compat_glColor3bv(gl.funcs, (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3b.xml
+func (gl *GL) Color3b(red, green, blue byte) {
+ C.gl4_2compat_glColor3b(gl.funcs, C.GLbyte(red), C.GLbyte(green), C.GLbyte(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBitmap.xml
+func (gl *GL) Bitmap(width, height int, xorig, yorig, xmove, ymove float32, bitmap []uint8) {
+ C.gl4_2compat_glBitmap(gl.funcs, C.GLsizei(width), C.GLsizei(height), C.GLfloat(xorig), C.GLfloat(yorig), C.GLfloat(xmove), C.GLfloat(ymove), (*C.GLubyte)(unsafe.Pointer(&bitmap[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBegin.xml
+func (gl *GL) Begin(mode glbase.Enum) {
+ C.gl4_2compat_glBegin(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glListBase.xml
+func (gl *GL) ListBase(base uint32) {
+ C.gl4_2compat_glListBase(gl.funcs, C.GLuint(base))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGenLists.xml
+func (gl *GL) GenLists(range_ int32) uint32 {
+ glresult := C.gl4_2compat_glGenLists(gl.funcs, C.GLsizei(range_))
+ return uint32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDeleteLists.xml
+func (gl *GL) DeleteLists(list uint32, range_ int32) {
+ C.gl4_2compat_glDeleteLists(gl.funcs, C.GLuint(list), C.GLsizei(range_))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCallLists.xml
+func (gl *GL) CallLists(n int, gltype glbase.Enum, lists interface{}) {
+ var lists_ptr unsafe.Pointer
+ var lists_v = reflect.ValueOf(lists)
+ if lists != nil && lists_v.Kind() != reflect.Slice {
+ panic("parameter lists must be a slice")
+ }
+ if lists != nil {
+ lists_ptr = unsafe.Pointer(lists_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2compat_glCallLists(gl.funcs, C.GLsizei(n), C.GLenum(gltype), lists_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCallList.xml
+func (gl *GL) CallList(list uint32) {
+ C.gl4_2compat_glCallList(gl.funcs, C.GLuint(list))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEndList.xml
+func (gl *GL) EndList() {
+ C.gl4_2compat_glEndList(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNewList.xml
+func (gl *GL) NewList(list uint32, mode glbase.Enum) {
+ C.gl4_2compat_glNewList(gl.funcs, C.GLuint(list), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPushClientAttrib.xml
+func (gl *GL) PushClientAttrib(mask glbase.Bitfield) {
+ C.gl4_2compat_glPushClientAttrib(gl.funcs, C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPopClientAttrib.xml
+func (gl *GL) PopClientAttrib() {
+ C.gl4_2compat_glPopClientAttrib(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPrioritizeTextures.xml
+func (gl *GL) PrioritizeTextures(n int, textures []glbase.Texture, priorities []float32) {
+ C.gl4_2compat_glPrioritizeTextures(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])), (*C.GLfloat)(unsafe.Pointer(&priorities[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glAreTexturesResident.xml
+func (gl *GL) AreTexturesResident(n int, textures []glbase.Texture, residences []bool) bool {
+ glresult := C.gl4_2compat_glAreTexturesResident(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])), (*C.GLboolean)(unsafe.Pointer(&residences[0])))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexPointer.xml
+func (gl *GL) VertexPointer(size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2compat_glVertexPointer(gl.funcs, C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordPointer.xml
+func (gl *GL) TexCoordPointer(size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2compat_glTexCoordPointer(gl.funcs, C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNormalPointer.xml
+func (gl *GL) NormalPointer(gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2compat_glNormalPointer(gl.funcs, C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glInterleavedArrays.xml
+func (gl *GL) InterleavedArrays(format glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2compat_glInterleavedArrays(gl.funcs, C.GLenum(format), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIndexPointer.xml
+func (gl *GL) IndexPointer(gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2compat_glIndexPointer(gl.funcs, C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEnableClientState.xml
+func (gl *GL) EnableClientState(array glbase.Enum) {
+ C.gl4_2compat_glEnableClientState(gl.funcs, C.GLenum(array))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEdgeFlagPointer.xml
+func (gl *GL) EdgeFlagPointer(stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2compat_glEdgeFlagPointer(gl.funcs, C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDisableClientState.xml
+func (gl *GL) DisableClientState(array glbase.Enum) {
+ C.gl4_2compat_glDisableClientState(gl.funcs, C.GLenum(array))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorPointer.xml
+func (gl *GL) ColorPointer(size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2compat_glColorPointer(gl.funcs, C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glArrayElement.xml
+func (gl *GL) ArrayElement(i int32) {
+ C.gl4_2compat_glArrayElement(gl.funcs, C.GLint(i))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glResetMinmax.xml
+func (gl *GL) ResetMinmax(target glbase.Enum) {
+ C.gl4_2compat_glResetMinmax(gl.funcs, C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glResetHistogram.xml
+func (gl *GL) ResetHistogram(target glbase.Enum) {
+ C.gl4_2compat_glResetHistogram(gl.funcs, C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMinmax.xml
+func (gl *GL) Minmax(target, internalFormat glbase.Enum, sink bool) {
+ C.gl4_2compat_glMinmax(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), *(*C.GLboolean)(unsafe.Pointer(&sink)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glHistogram.xml
+func (gl *GL) Histogram(target glbase.Enum, width int, internalFormat glbase.Enum, sink bool) {
+ C.gl4_2compat_glHistogram(gl.funcs, C.GLenum(target), C.GLsizei(width), C.GLenum(internalFormat), *(*C.GLboolean)(unsafe.Pointer(&sink)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetMinmaxParameteriv.xml
+func (gl *GL) GetMinmaxParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl4_2compat_glGetMinmaxParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetMinmaxParameterfv.xml
+func (gl *GL) GetMinmaxParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl4_2compat_glGetMinmaxParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetMinmax.xml
+func (gl *GL) GetMinmax(target glbase.Enum, reset bool, format, gltype glbase.Enum, values interface{}) {
+ var values_ptr unsafe.Pointer
+ var values_v = reflect.ValueOf(values)
+ if values != nil && values_v.Kind() != reflect.Slice {
+ panic("parameter values must be a slice")
+ }
+ if values != nil {
+ values_ptr = unsafe.Pointer(values_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2compat_glGetMinmax(gl.funcs, C.GLenum(target), *(*C.GLboolean)(unsafe.Pointer(&reset)), C.GLenum(format), C.GLenum(gltype), values_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetHistogramParameteriv.xml
+func (gl *GL) GetHistogramParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl4_2compat_glGetHistogramParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetHistogramParameterfv.xml
+func (gl *GL) GetHistogramParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl4_2compat_glGetHistogramParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetHistogram.xml
+func (gl *GL) GetHistogram(target glbase.Enum, reset bool, format, gltype glbase.Enum, values interface{}) {
+ var values_ptr unsafe.Pointer
+ var values_v = reflect.ValueOf(values)
+ if values != nil && values_v.Kind() != reflect.Slice {
+ panic("parameter values must be a slice")
+ }
+ if values != nil {
+ values_ptr = unsafe.Pointer(values_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2compat_glGetHistogram(gl.funcs, C.GLenum(target), *(*C.GLboolean)(unsafe.Pointer(&reset)), C.GLenum(format), C.GLenum(gltype), values_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSeparableFilter2D.xml
+func (gl *GL) SeparableFilter2D(target, internalFormat glbase.Enum, width, height int, format, gltype glbase.Enum, row, column interface{}) {
+ var row_ptr unsafe.Pointer
+ var row_v = reflect.ValueOf(row)
+ if row != nil && row_v.Kind() != reflect.Slice {
+ panic("parameter row must be a slice")
+ }
+ if row != nil {
+ row_ptr = unsafe.Pointer(row_v.Index(0).Addr().Pointer())
+ }
+ var column_ptr unsafe.Pointer
+ var column_v = reflect.ValueOf(column)
+ if column != nil && column_v.Kind() != reflect.Slice {
+ panic("parameter column must be a slice")
+ }
+ if column != nil {
+ column_ptr = unsafe.Pointer(column_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2compat_glSeparableFilter2D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), row_ptr, column_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetSeparableFilter.xml
+func (gl *GL) GetSeparableFilter(target, format, gltype glbase.Enum, row, column, span interface{}) {
+ var row_ptr unsafe.Pointer
+ var row_v = reflect.ValueOf(row)
+ if row != nil && row_v.Kind() != reflect.Slice {
+ panic("parameter row must be a slice")
+ }
+ if row != nil {
+ row_ptr = unsafe.Pointer(row_v.Index(0).Addr().Pointer())
+ }
+ var column_ptr unsafe.Pointer
+ var column_v = reflect.ValueOf(column)
+ if column != nil && column_v.Kind() != reflect.Slice {
+ panic("parameter column must be a slice")
+ }
+ if column != nil {
+ column_ptr = unsafe.Pointer(column_v.Index(0).Addr().Pointer())
+ }
+ var span_ptr unsafe.Pointer
+ var span_v = reflect.ValueOf(span)
+ if span != nil && span_v.Kind() != reflect.Slice {
+ panic("parameter span must be a slice")
+ }
+ if span != nil {
+ span_ptr = unsafe.Pointer(span_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2compat_glGetSeparableFilter(gl.funcs, C.GLenum(target), C.GLenum(format), C.GLenum(gltype), row_ptr, column_ptr, span_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetConvolutionParameteriv.xml
+func (gl *GL) GetConvolutionParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl4_2compat_glGetConvolutionParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetConvolutionParameterfv.xml
+func (gl *GL) GetConvolutionParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl4_2compat_glGetConvolutionParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetConvolutionFilter.xml
+func (gl *GL) GetConvolutionFilter(target, format, gltype glbase.Enum, image interface{}) {
+ var image_ptr unsafe.Pointer
+ var image_v = reflect.ValueOf(image)
+ if image != nil && image_v.Kind() != reflect.Slice {
+ panic("parameter image must be a slice")
+ }
+ if image != nil {
+ image_ptr = unsafe.Pointer(image_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2compat_glGetConvolutionFilter(gl.funcs, C.GLenum(target), C.GLenum(format), C.GLenum(gltype), image_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyConvolutionFilter2D.xml
+func (gl *GL) CopyConvolutionFilter2D(target, internalFormat glbase.Enum, x, y, width, height int) {
+ C.gl4_2compat_glCopyConvolutionFilter2D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyConvolutionFilter1D.xml
+func (gl *GL) CopyConvolutionFilter1D(target, internalFormat glbase.Enum, x, y, width int) {
+ C.gl4_2compat_glCopyConvolutionFilter1D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glConvolutionParameteriv.xml
+func (gl *GL) ConvolutionParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl4_2compat_glConvolutionParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glConvolutionParameteri.xml
+func (gl *GL) ConvolutionParameteri(target, pname glbase.Enum, params int32) {
+ C.gl4_2compat_glConvolutionParameteri(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLint(params))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glConvolutionParameterfv.xml
+func (gl *GL) ConvolutionParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl4_2compat_glConvolutionParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glConvolutionParameterf.xml
+func (gl *GL) ConvolutionParameterf(target, pname glbase.Enum, params float32) {
+ C.gl4_2compat_glConvolutionParameterf(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLfloat(params))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glConvolutionFilter2D.xml
+func (gl *GL) ConvolutionFilter2D(target, internalFormat glbase.Enum, width, height int, format, gltype glbase.Enum, image interface{}) {
+ var image_ptr unsafe.Pointer
+ var image_v = reflect.ValueOf(image)
+ if image != nil && image_v.Kind() != reflect.Slice {
+ panic("parameter image must be a slice")
+ }
+ if image != nil {
+ image_ptr = unsafe.Pointer(image_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2compat_glConvolutionFilter2D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), image_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glConvolutionFilter1D.xml
+func (gl *GL) ConvolutionFilter1D(target, internalFormat glbase.Enum, width int, format, gltype glbase.Enum, image interface{}) {
+ var image_ptr unsafe.Pointer
+ var image_v = reflect.ValueOf(image)
+ if image != nil && image_v.Kind() != reflect.Slice {
+ panic("parameter image must be a slice")
+ }
+ if image != nil {
+ image_ptr = unsafe.Pointer(image_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2compat_glConvolutionFilter1D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLenum(format), C.GLenum(gltype), image_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyColorSubTable.xml
+func (gl *GL) CopyColorSubTable(target glbase.Enum, start int32, x, y, width int) {
+ C.gl4_2compat_glCopyColorSubTable(gl.funcs, C.GLenum(target), C.GLsizei(start), C.GLint(x), C.GLint(y), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorSubTable.xml
+func (gl *GL) ColorSubTable(target glbase.Enum, start int32, count int, format, gltype glbase.Enum, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2compat_glColorSubTable(gl.funcs, C.GLenum(target), C.GLsizei(start), C.GLsizei(count), C.GLenum(format), C.GLenum(gltype), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetColorTableParameteriv.xml
+func (gl *GL) GetColorTableParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl4_2compat_glGetColorTableParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetColorTableParameterfv.xml
+func (gl *GL) GetColorTableParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl4_2compat_glGetColorTableParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetColorTable.xml
+func (gl *GL) GetColorTable(target, format, gltype glbase.Enum, table interface{}) {
+ var table_ptr unsafe.Pointer
+ var table_v = reflect.ValueOf(table)
+ if table != nil && table_v.Kind() != reflect.Slice {
+ panic("parameter table must be a slice")
+ }
+ if table != nil {
+ table_ptr = unsafe.Pointer(table_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2compat_glGetColorTable(gl.funcs, C.GLenum(target), C.GLenum(format), C.GLenum(gltype), table_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyColorTable.xml
+func (gl *GL) CopyColorTable(target, internalFormat glbase.Enum, x, y, width int) {
+ C.gl4_2compat_glCopyColorTable(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorTableParameteriv.xml
+func (gl *GL) ColorTableParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl4_2compat_glColorTableParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorTableParameterfv.xml
+func (gl *GL) ColorTableParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl4_2compat_glColorTableParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorTable.xml
+func (gl *GL) ColorTable(target, internalFormat glbase.Enum, width int, format, gltype glbase.Enum, table interface{}) {
+ var table_ptr unsafe.Pointer
+ var table_v = reflect.ValueOf(table)
+ if table != nil && table_v.Kind() != reflect.Slice {
+ panic("parameter table must be a slice")
+ }
+ if table != nil {
+ table_ptr = unsafe.Pointer(table_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2compat_glColorTable(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLenum(format), C.GLenum(gltype), table_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultTransposeMatrixd.xml
+func (gl *GL) MultTransposeMatrixd(m []float64) {
+ C.gl4_2compat_glMultTransposeMatrixd(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultTransposeMatrixf.xml
+func (gl *GL) MultTransposeMatrixf(m []float32) {
+ C.gl4_2compat_glMultTransposeMatrixf(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLoadTransposeMatrixd.xml
+func (gl *GL) LoadTransposeMatrixd(m []float64) {
+ C.gl4_2compat_glLoadTransposeMatrixd(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLoadTransposeMatrixf.xml
+func (gl *GL) LoadTransposeMatrixf(m []float32) {
+ C.gl4_2compat_glLoadTransposeMatrixf(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord4sv.xml
+func (gl *GL) MultiTexCoord4sv(target glbase.Enum, v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glMultiTexCoord4sv(gl.funcs, C.GLenum(target), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord4s.xml
+func (gl *GL) MultiTexCoord4s(target glbase.Enum, s, t, r, q int16) {
+ C.gl4_2compat_glMultiTexCoord4s(gl.funcs, C.GLenum(target), C.GLshort(s), C.GLshort(t), C.GLshort(r), C.GLshort(q))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord4iv.xml
+func (gl *GL) MultiTexCoord4iv(target glbase.Enum, v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glMultiTexCoord4iv(gl.funcs, C.GLenum(target), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord4i.xml
+func (gl *GL) MultiTexCoord4i(target glbase.Enum, s, t, r, q int32) {
+ C.gl4_2compat_glMultiTexCoord4i(gl.funcs, C.GLenum(target), C.GLint(s), C.GLint(t), C.GLint(r), C.GLint(q))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord4fv.xml
+func (gl *GL) MultiTexCoord4fv(target glbase.Enum, v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glMultiTexCoord4fv(gl.funcs, C.GLenum(target), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord4f.xml
+func (gl *GL) MultiTexCoord4f(target glbase.Enum, s, t, r, q float32) {
+ C.gl4_2compat_glMultiTexCoord4f(gl.funcs, C.GLenum(target), C.GLfloat(s), C.GLfloat(t), C.GLfloat(r), C.GLfloat(q))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord4dv.xml
+func (gl *GL) MultiTexCoord4dv(target glbase.Enum, v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glMultiTexCoord4dv(gl.funcs, C.GLenum(target), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord4d.xml
+func (gl *GL) MultiTexCoord4d(target glbase.Enum, s, t, r, q float64) {
+ C.gl4_2compat_glMultiTexCoord4d(gl.funcs, C.GLenum(target), C.GLdouble(s), C.GLdouble(t), C.GLdouble(r), C.GLdouble(q))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord3sv.xml
+func (gl *GL) MultiTexCoord3sv(target glbase.Enum, v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glMultiTexCoord3sv(gl.funcs, C.GLenum(target), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord3s.xml
+func (gl *GL) MultiTexCoord3s(target glbase.Enum, s, t, r int16) {
+ C.gl4_2compat_glMultiTexCoord3s(gl.funcs, C.GLenum(target), C.GLshort(s), C.GLshort(t), C.GLshort(r))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord3iv.xml
+func (gl *GL) MultiTexCoord3iv(target glbase.Enum, v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glMultiTexCoord3iv(gl.funcs, C.GLenum(target), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord3i.xml
+func (gl *GL) MultiTexCoord3i(target glbase.Enum, s, t, r int32) {
+ C.gl4_2compat_glMultiTexCoord3i(gl.funcs, C.GLenum(target), C.GLint(s), C.GLint(t), C.GLint(r))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord3fv.xml
+func (gl *GL) MultiTexCoord3fv(target glbase.Enum, v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glMultiTexCoord3fv(gl.funcs, C.GLenum(target), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord3f.xml
+func (gl *GL) MultiTexCoord3f(target glbase.Enum, s, t, r float32) {
+ C.gl4_2compat_glMultiTexCoord3f(gl.funcs, C.GLenum(target), C.GLfloat(s), C.GLfloat(t), C.GLfloat(r))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord3dv.xml
+func (gl *GL) MultiTexCoord3dv(target glbase.Enum, v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glMultiTexCoord3dv(gl.funcs, C.GLenum(target), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord3d.xml
+func (gl *GL) MultiTexCoord3d(target glbase.Enum, s, t, r float64) {
+ C.gl4_2compat_glMultiTexCoord3d(gl.funcs, C.GLenum(target), C.GLdouble(s), C.GLdouble(t), C.GLdouble(r))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord2sv.xml
+func (gl *GL) MultiTexCoord2sv(target glbase.Enum, v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glMultiTexCoord2sv(gl.funcs, C.GLenum(target), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord2s.xml
+func (gl *GL) MultiTexCoord2s(target glbase.Enum, s, t int16) {
+ C.gl4_2compat_glMultiTexCoord2s(gl.funcs, C.GLenum(target), C.GLshort(s), C.GLshort(t))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord2iv.xml
+func (gl *GL) MultiTexCoord2iv(target glbase.Enum, v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glMultiTexCoord2iv(gl.funcs, C.GLenum(target), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord2i.xml
+func (gl *GL) MultiTexCoord2i(target glbase.Enum, s, t int32) {
+ C.gl4_2compat_glMultiTexCoord2i(gl.funcs, C.GLenum(target), C.GLint(s), C.GLint(t))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord2fv.xml
+func (gl *GL) MultiTexCoord2fv(target glbase.Enum, v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glMultiTexCoord2fv(gl.funcs, C.GLenum(target), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord2f.xml
+func (gl *GL) MultiTexCoord2f(target glbase.Enum, s, t float32) {
+ C.gl4_2compat_glMultiTexCoord2f(gl.funcs, C.GLenum(target), C.GLfloat(s), C.GLfloat(t))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord2dv.xml
+func (gl *GL) MultiTexCoord2dv(target glbase.Enum, v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glMultiTexCoord2dv(gl.funcs, C.GLenum(target), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord2d.xml
+func (gl *GL) MultiTexCoord2d(target glbase.Enum, s, t float64) {
+ C.gl4_2compat_glMultiTexCoord2d(gl.funcs, C.GLenum(target), C.GLdouble(s), C.GLdouble(t))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord1sv.xml
+func (gl *GL) MultiTexCoord1sv(target glbase.Enum, v []int16) {
+ C.gl4_2compat_glMultiTexCoord1sv(gl.funcs, C.GLenum(target), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord1s.xml
+func (gl *GL) MultiTexCoord1s(target glbase.Enum, s int16) {
+ C.gl4_2compat_glMultiTexCoord1s(gl.funcs, C.GLenum(target), C.GLshort(s))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord1iv.xml
+func (gl *GL) MultiTexCoord1iv(target glbase.Enum, v []int32) {
+ C.gl4_2compat_glMultiTexCoord1iv(gl.funcs, C.GLenum(target), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord1i.xml
+func (gl *GL) MultiTexCoord1i(target glbase.Enum, s int32) {
+ C.gl4_2compat_glMultiTexCoord1i(gl.funcs, C.GLenum(target), C.GLint(s))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord1fv.xml
+func (gl *GL) MultiTexCoord1fv(target glbase.Enum, v []float32) {
+ C.gl4_2compat_glMultiTexCoord1fv(gl.funcs, C.GLenum(target), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord1f.xml
+func (gl *GL) MultiTexCoord1f(target glbase.Enum, s float32) {
+ C.gl4_2compat_glMultiTexCoord1f(gl.funcs, C.GLenum(target), C.GLfloat(s))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord1dv.xml
+func (gl *GL) MultiTexCoord1dv(target glbase.Enum, v []float64) {
+ C.gl4_2compat_glMultiTexCoord1dv(gl.funcs, C.GLenum(target), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord1d.xml
+func (gl *GL) MultiTexCoord1d(target glbase.Enum, s float64) {
+ C.gl4_2compat_glMultiTexCoord1d(gl.funcs, C.GLenum(target), C.GLdouble(s))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClientActiveTexture.xml
+func (gl *GL) ClientActiveTexture(texture glbase.Enum) {
+ C.gl4_2compat_glClientActiveTexture(gl.funcs, C.GLenum(texture))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos3sv.xml
+func (gl *GL) WindowPos3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glWindowPos3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos3s.xml
+func (gl *GL) WindowPos3s(x, y, z int16) {
+ C.gl4_2compat_glWindowPos3s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos3iv.xml
+func (gl *GL) WindowPos3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glWindowPos3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos3i.xml
+func (gl *GL) WindowPos3i(x, y, z int) {
+ C.gl4_2compat_glWindowPos3i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos3fv.xml
+func (gl *GL) WindowPos3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glWindowPos3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos3f.xml
+func (gl *GL) WindowPos3f(x, y, z float32) {
+ C.gl4_2compat_glWindowPos3f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos3dv.xml
+func (gl *GL) WindowPos3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glWindowPos3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos3d.xml
+func (gl *GL) WindowPos3d(x, y, z float64) {
+ C.gl4_2compat_glWindowPos3d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos2sv.xml
+func (gl *GL) WindowPos2sv(v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glWindowPos2sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos2s.xml
+func (gl *GL) WindowPos2s(x, y int16) {
+ C.gl4_2compat_glWindowPos2s(gl.funcs, C.GLshort(x), C.GLshort(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos2iv.xml
+func (gl *GL) WindowPos2iv(v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glWindowPos2iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos2i.xml
+func (gl *GL) WindowPos2i(x, y int) {
+ C.gl4_2compat_glWindowPos2i(gl.funcs, C.GLint(x), C.GLint(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos2fv.xml
+func (gl *GL) WindowPos2fv(v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glWindowPos2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos2f.xml
+func (gl *GL) WindowPos2f(x, y float32) {
+ C.gl4_2compat_glWindowPos2f(gl.funcs, C.GLfloat(x), C.GLfloat(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos2dv.xml
+func (gl *GL) WindowPos2dv(v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glWindowPos2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos2d.xml
+func (gl *GL) WindowPos2d(x, y float64) {
+ C.gl4_2compat_glWindowPos2d(gl.funcs, C.GLdouble(x), C.GLdouble(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColorPointer.xml
+func (gl *GL) SecondaryColorPointer(size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2compat_glSecondaryColorPointer(gl.funcs, C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3usv.xml
+func (gl *GL) SecondaryColor3usv(v []uint16) {
+ C.gl4_2compat_glSecondaryColor3usv(gl.funcs, (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3us.xml
+func (gl *GL) SecondaryColor3us(red, green, blue uint16) {
+ C.gl4_2compat_glSecondaryColor3us(gl.funcs, C.GLushort(red), C.GLushort(green), C.GLushort(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3uiv.xml
+func (gl *GL) SecondaryColor3uiv(v []uint32) {
+ C.gl4_2compat_glSecondaryColor3uiv(gl.funcs, (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3ui.xml
+func (gl *GL) SecondaryColor3ui(red, green, blue uint32) {
+ C.gl4_2compat_glSecondaryColor3ui(gl.funcs, C.GLuint(red), C.GLuint(green), C.GLuint(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3ubv.xml
+func (gl *GL) SecondaryColor3ubv(v []uint8) {
+ C.gl4_2compat_glSecondaryColor3ubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3ub.xml
+func (gl *GL) SecondaryColor3ub(red, green, blue uint8) {
+ C.gl4_2compat_glSecondaryColor3ub(gl.funcs, C.GLubyte(red), C.GLubyte(green), C.GLubyte(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3sv.xml
+func (gl *GL) SecondaryColor3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glSecondaryColor3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3s.xml
+func (gl *GL) SecondaryColor3s(red, green, blue int16) {
+ C.gl4_2compat_glSecondaryColor3s(gl.funcs, C.GLshort(red), C.GLshort(green), C.GLshort(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3iv.xml
+func (gl *GL) SecondaryColor3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glSecondaryColor3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3i.xml
+func (gl *GL) SecondaryColor3i(red, green, blue int32) {
+ C.gl4_2compat_glSecondaryColor3i(gl.funcs, C.GLint(red), C.GLint(green), C.GLint(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3fv.xml
+func (gl *GL) SecondaryColor3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glSecondaryColor3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3f.xml
+func (gl *GL) SecondaryColor3f(red, green, blue float32) {
+ C.gl4_2compat_glSecondaryColor3f(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3dv.xml
+func (gl *GL) SecondaryColor3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glSecondaryColor3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3d.xml
+func (gl *GL) SecondaryColor3d(red, green, blue float64) {
+ C.gl4_2compat_glSecondaryColor3d(gl.funcs, C.GLdouble(red), C.GLdouble(green), C.GLdouble(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3bv.xml
+func (gl *GL) SecondaryColor3bv(v []byte) {
+ C.gl4_2compat_glSecondaryColor3bv(gl.funcs, (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3b.xml
+func (gl *GL) SecondaryColor3b(red, green, blue byte) {
+ C.gl4_2compat_glSecondaryColor3b(gl.funcs, C.GLbyte(red), C.GLbyte(green), C.GLbyte(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFogCoordPointer.xml
+func (gl *GL) FogCoordPointer(gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2compat_glFogCoordPointer(gl.funcs, C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFogCoorddv.xml
+func (gl *GL) FogCoorddv(coord []float64) {
+ C.gl4_2compat_glFogCoorddv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&coord[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFogCoordd.xml
+func (gl *GL) FogCoordd(coord float64) {
+ C.gl4_2compat_glFogCoordd(gl.funcs, C.GLdouble(coord))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFogCoordfv.xml
+func (gl *GL) FogCoordfv(coord []float32) {
+ C.gl4_2compat_glFogCoordfv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&coord[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFogCoordf.xml
+func (gl *GL) FogCoordf(coord float32) {
+ C.gl4_2compat_glFogCoordf(gl.funcs, C.GLfloat(coord))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4usv.xml
+func (gl *GL) VertexAttrib4usv(index glbase.Attrib, v []uint16) {
+ C.gl4_2compat_glVertexAttrib4usv(gl.funcs, C.GLuint(index), (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4uiv.xml
+func (gl *GL) VertexAttrib4uiv(index glbase.Attrib, v []uint32) {
+ C.gl4_2compat_glVertexAttrib4uiv(gl.funcs, C.GLuint(index), (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4ubv.xml
+func (gl *GL) VertexAttrib4ubv(index glbase.Attrib, v []uint8) {
+ C.gl4_2compat_glVertexAttrib4ubv(gl.funcs, C.GLuint(index), (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4sv.xml
+func (gl *GL) VertexAttrib4sv(index glbase.Attrib, v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glVertexAttrib4sv(gl.funcs, C.GLuint(index), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4s.xml
+func (gl *GL) VertexAttrib4s(index glbase.Attrib, x, y, z, w int16) {
+ C.gl4_2compat_glVertexAttrib4s(gl.funcs, C.GLuint(index), C.GLshort(x), C.GLshort(y), C.GLshort(z), C.GLshort(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4iv.xml
+func (gl *GL) VertexAttrib4iv(index glbase.Attrib, v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glVertexAttrib4iv(gl.funcs, C.GLuint(index), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4fv.xml
+func (gl *GL) VertexAttrib4fv(index glbase.Attrib, v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glVertexAttrib4fv(gl.funcs, C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4f.xml
+func (gl *GL) VertexAttrib4f(index glbase.Attrib, x, y, z, w float32) {
+ C.gl4_2compat_glVertexAttrib4f(gl.funcs, C.GLuint(index), C.GLfloat(x), C.GLfloat(y), C.GLfloat(z), C.GLfloat(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4dv.xml
+func (gl *GL) VertexAttrib4dv(index glbase.Attrib, v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glVertexAttrib4dv(gl.funcs, C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4d.xml
+func (gl *GL) VertexAttrib4d(index glbase.Attrib, x, y, z, w float64) {
+ C.gl4_2compat_glVertexAttrib4d(gl.funcs, C.GLuint(index), C.GLdouble(x), C.GLdouble(y), C.GLdouble(z), C.GLdouble(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4bv.xml
+func (gl *GL) VertexAttrib4bv(index glbase.Attrib, v []byte) {
+ C.gl4_2compat_glVertexAttrib4bv(gl.funcs, C.GLuint(index), (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4Nusv.xml
+func (gl *GL) VertexAttrib4Nusv(index glbase.Attrib, v []uint16) {
+ C.gl4_2compat_glVertexAttrib4Nusv(gl.funcs, C.GLuint(index), (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4Nuiv.xml
+func (gl *GL) VertexAttrib4Nuiv(index glbase.Attrib, v []uint32) {
+ C.gl4_2compat_glVertexAttrib4Nuiv(gl.funcs, C.GLuint(index), (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4Nubv.xml
+func (gl *GL) VertexAttrib4Nubv(index glbase.Attrib, v []uint8) {
+ C.gl4_2compat_glVertexAttrib4Nubv(gl.funcs, C.GLuint(index), (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4Nub.xml
+func (gl *GL) VertexAttrib4Nub(index glbase.Attrib, x, y, z, w uint8) {
+ C.gl4_2compat_glVertexAttrib4Nub(gl.funcs, C.GLuint(index), C.GLubyte(x), C.GLubyte(y), C.GLubyte(z), C.GLubyte(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4Nsv.xml
+func (gl *GL) VertexAttrib4Nsv(index glbase.Attrib, v []int16) {
+ C.gl4_2compat_glVertexAttrib4Nsv(gl.funcs, C.GLuint(index), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4Niv.xml
+func (gl *GL) VertexAttrib4Niv(index glbase.Attrib, v []int32) {
+ C.gl4_2compat_glVertexAttrib4Niv(gl.funcs, C.GLuint(index), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4Nbv.xml
+func (gl *GL) VertexAttrib4Nbv(index glbase.Attrib, v []byte) {
+ C.gl4_2compat_glVertexAttrib4Nbv(gl.funcs, C.GLuint(index), (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib3sv.xml
+func (gl *GL) VertexAttrib3sv(index glbase.Attrib, v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glVertexAttrib3sv(gl.funcs, C.GLuint(index), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib3s.xml
+func (gl *GL) VertexAttrib3s(index glbase.Attrib, x, y, z int16) {
+ C.gl4_2compat_glVertexAttrib3s(gl.funcs, C.GLuint(index), C.GLshort(x), C.GLshort(y), C.GLshort(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib3fv.xml
+func (gl *GL) VertexAttrib3fv(index glbase.Attrib, v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glVertexAttrib3fv(gl.funcs, C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib3f.xml
+func (gl *GL) VertexAttrib3f(index glbase.Attrib, x, y, z float32) {
+ C.gl4_2compat_glVertexAttrib3f(gl.funcs, C.GLuint(index), C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib3dv.xml
+func (gl *GL) VertexAttrib3dv(index glbase.Attrib, v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glVertexAttrib3dv(gl.funcs, C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib3d.xml
+func (gl *GL) VertexAttrib3d(index glbase.Attrib, x, y, z float64) {
+ C.gl4_2compat_glVertexAttrib3d(gl.funcs, C.GLuint(index), C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib2sv.xml
+func (gl *GL) VertexAttrib2sv(index glbase.Attrib, v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glVertexAttrib2sv(gl.funcs, C.GLuint(index), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib2s.xml
+func (gl *GL) VertexAttrib2s(index glbase.Attrib, x, y int16) {
+ C.gl4_2compat_glVertexAttrib2s(gl.funcs, C.GLuint(index), C.GLshort(x), C.GLshort(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib2fv.xml
+func (gl *GL) VertexAttrib2fv(index glbase.Attrib, v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glVertexAttrib2fv(gl.funcs, C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib2f.xml
+func (gl *GL) VertexAttrib2f(index glbase.Attrib, x, y float32) {
+ C.gl4_2compat_glVertexAttrib2f(gl.funcs, C.GLuint(index), C.GLfloat(x), C.GLfloat(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib2dv.xml
+func (gl *GL) VertexAttrib2dv(index glbase.Attrib, v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glVertexAttrib2dv(gl.funcs, C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib2d.xml
+func (gl *GL) VertexAttrib2d(index glbase.Attrib, x, y float64) {
+ C.gl4_2compat_glVertexAttrib2d(gl.funcs, C.GLuint(index), C.GLdouble(x), C.GLdouble(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib1sv.xml
+func (gl *GL) VertexAttrib1sv(index glbase.Attrib, v []int16) {
+ C.gl4_2compat_glVertexAttrib1sv(gl.funcs, C.GLuint(index), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib1s.xml
+func (gl *GL) VertexAttrib1s(index glbase.Attrib, x int16) {
+ C.gl4_2compat_glVertexAttrib1s(gl.funcs, C.GLuint(index), C.GLshort(x))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib1fv.xml
+func (gl *GL) VertexAttrib1fv(index glbase.Attrib, v []float32) {
+ C.gl4_2compat_glVertexAttrib1fv(gl.funcs, C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib1f.xml
+func (gl *GL) VertexAttrib1f(index glbase.Attrib, x float32) {
+ C.gl4_2compat_glVertexAttrib1f(gl.funcs, C.GLuint(index), C.GLfloat(x))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib1dv.xml
+func (gl *GL) VertexAttrib1dv(index glbase.Attrib, v []float64) {
+ C.gl4_2compat_glVertexAttrib1dv(gl.funcs, C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib1d.xml
+func (gl *GL) VertexAttrib1d(index glbase.Attrib, x float64) {
+ C.gl4_2compat_glVertexAttrib1d(gl.funcs, C.GLuint(index), C.GLdouble(x))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI4usv.xml
+func (gl *GL) VertexAttribI4usv(index glbase.Attrib, v []uint16) {
+ C.gl4_2compat_glVertexAttribI4usv(gl.funcs, C.GLuint(index), (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI4ubv.xml
+func (gl *GL) VertexAttribI4ubv(index glbase.Attrib, v []uint8) {
+ C.gl4_2compat_glVertexAttribI4ubv(gl.funcs, C.GLuint(index), (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI4sv.xml
+func (gl *GL) VertexAttribI4sv(index glbase.Attrib, v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glVertexAttribI4sv(gl.funcs, C.GLuint(index), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI4bv.xml
+func (gl *GL) VertexAttribI4bv(index glbase.Attrib, v []byte) {
+ C.gl4_2compat_glVertexAttribI4bv(gl.funcs, C.GLuint(index), (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI4uiv.xml
+func (gl *GL) VertexAttribI4uiv(index glbase.Attrib, v []uint32) {
+ C.gl4_2compat_glVertexAttribI4uiv(gl.funcs, C.GLuint(index), (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI3uiv.xml
+func (gl *GL) VertexAttribI3uiv(index glbase.Attrib, v []uint32) {
+ C.gl4_2compat_glVertexAttribI3uiv(gl.funcs, C.GLuint(index), (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI2uiv.xml
+func (gl *GL) VertexAttribI2uiv(index glbase.Attrib, v []uint32) {
+ C.gl4_2compat_glVertexAttribI2uiv(gl.funcs, C.GLuint(index), (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI1uiv.xml
+func (gl *GL) VertexAttribI1uiv(index glbase.Attrib, v []uint32) {
+ C.gl4_2compat_glVertexAttribI1uiv(gl.funcs, C.GLuint(index), (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI4iv.xml
+func (gl *GL) VertexAttribI4iv(index glbase.Attrib, v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glVertexAttribI4iv(gl.funcs, C.GLuint(index), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI3iv.xml
+func (gl *GL) VertexAttribI3iv(index glbase.Attrib, v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glVertexAttribI3iv(gl.funcs, C.GLuint(index), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI2iv.xml
+func (gl *GL) VertexAttribI2iv(index glbase.Attrib, v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2compat_glVertexAttribI2iv(gl.funcs, C.GLuint(index), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI1iv.xml
+func (gl *GL) VertexAttribI1iv(index glbase.Attrib, v []int32) {
+ C.gl4_2compat_glVertexAttribI1iv(gl.funcs, C.GLuint(index), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI4ui.xml
+func (gl *GL) VertexAttribI4ui(index glbase.Attrib, x, y, z, w uint32) {
+ C.gl4_2compat_glVertexAttribI4ui(gl.funcs, C.GLuint(index), C.GLuint(x), C.GLuint(y), C.GLuint(z), C.GLuint(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI3ui.xml
+func (gl *GL) VertexAttribI3ui(index glbase.Attrib, x, y, z uint32) {
+ C.gl4_2compat_glVertexAttribI3ui(gl.funcs, C.GLuint(index), C.GLuint(x), C.GLuint(y), C.GLuint(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI2ui.xml
+func (gl *GL) VertexAttribI2ui(index glbase.Attrib, x, y uint32) {
+ C.gl4_2compat_glVertexAttribI2ui(gl.funcs, C.GLuint(index), C.GLuint(x), C.GLuint(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI1ui.xml
+func (gl *GL) VertexAttribI1ui(index glbase.Attrib, x uint32) {
+ C.gl4_2compat_glVertexAttribI1ui(gl.funcs, C.GLuint(index), C.GLuint(x))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI4i.xml
+func (gl *GL) VertexAttribI4i(index glbase.Attrib, x, y, z, w int) {
+ C.gl4_2compat_glVertexAttribI4i(gl.funcs, C.GLuint(index), C.GLint(x), C.GLint(y), C.GLint(z), C.GLint(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI3i.xml
+func (gl *GL) VertexAttribI3i(index glbase.Attrib, x, y, z int) {
+ C.gl4_2compat_glVertexAttribI3i(gl.funcs, C.GLuint(index), C.GLint(x), C.GLint(y), C.GLint(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI2i.xml
+func (gl *GL) VertexAttribI2i(index glbase.Attrib, x, y int) {
+ C.gl4_2compat_glVertexAttribI2i(gl.funcs, C.GLuint(index), C.GLint(x), C.GLint(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI1i.xml
+func (gl *GL) VertexAttribI1i(index glbase.Attrib, x int) {
+ C.gl4_2compat_glVertexAttribI1i(gl.funcs, C.GLuint(index), C.GLint(x))
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.2core/funcs.cpp b/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.2core/funcs.cpp
new file mode 100644
index 000000000..567e39b30
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.2core/funcs.cpp
@@ -0,0 +1,2748 @@
+
+// ** file automatically generated by glgen -- do not edit manually **
+
+#include <QOpenGLContext>
+#include <QtGui/qopenglfunctions_4_2_core.h>
+
+#include "funcs.h"
+
+void *gl4_2core_funcs() {
+ QOpenGLFunctions_4_2_Core* funcs = QOpenGLContext::currentContext()->versionFunctions<QOpenGLFunctions_4_2_Core>();
+ if (!funcs) {
+ return 0;
+ }
+ funcs->initializeOpenGLFunctions();
+ return funcs;
+}
+
+
+void gl4_2core_glViewport(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glViewport(x, y, width, height);
+}
+
+void gl4_2core_glDepthRange(void *_glfuncs, GLdouble nearVal, GLdouble farVal)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glDepthRange(nearVal, farVal);
+}
+
+GLboolean gl4_2core_glIsEnabled(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ return _qglfuncs->glIsEnabled(cap);
+}
+
+void gl4_2core_glGetTexLevelParameteriv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetTexLevelParameteriv(target, level, pname, params);
+}
+
+void gl4_2core_glGetTexLevelParameterfv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetTexLevelParameterfv(target, level, pname, params);
+}
+
+void gl4_2core_glGetTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetTexParameteriv(target, pname, params);
+}
+
+void gl4_2core_glGetTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetTexParameterfv(target, pname, params);
+}
+
+void gl4_2core_glGetTexImage(void *_glfuncs, GLenum target, GLint level, GLenum format, GLenum gltype, GLvoid* pixels)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetTexImage(target, level, format, gltype, pixels);
+}
+
+void gl4_2core_glGetIntegerv(void *_glfuncs, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetIntegerv(pname, params);
+}
+
+void gl4_2core_glGetFloatv(void *_glfuncs, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetFloatv(pname, params);
+}
+
+GLenum gl4_2core_glGetError(void *_glfuncs)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ return _qglfuncs->glGetError();
+}
+
+void gl4_2core_glGetDoublev(void *_glfuncs, GLenum pname, GLdouble* params)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetDoublev(pname, params);
+}
+
+void gl4_2core_glGetBooleanv(void *_glfuncs, GLenum pname, GLboolean* params)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetBooleanv(pname, params);
+}
+
+void gl4_2core_glReadPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum gltype, GLvoid* pixels)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glReadPixels(x, y, width, height, format, gltype, pixels);
+}
+
+void gl4_2core_glReadBuffer(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glReadBuffer(mode);
+}
+
+void gl4_2core_glPixelStorei(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glPixelStorei(pname, param);
+}
+
+void gl4_2core_glPixelStoref(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glPixelStoref(pname, param);
+}
+
+void gl4_2core_glDepthFunc(void *_glfuncs, GLenum glfunc)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glDepthFunc(glfunc);
+}
+
+void gl4_2core_glStencilOp(void *_glfuncs, GLenum fail, GLenum zfail, GLenum zpass)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glStencilOp(fail, zfail, zpass);
+}
+
+void gl4_2core_glStencilFunc(void *_glfuncs, GLenum glfunc, GLint ref, GLuint mask)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glStencilFunc(glfunc, ref, mask);
+}
+
+void gl4_2core_glLogicOp(void *_glfuncs, GLenum opcode)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glLogicOp(opcode);
+}
+
+void gl4_2core_glBlendFunc(void *_glfuncs, GLenum sfactor, GLenum dfactor)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glBlendFunc(sfactor, dfactor);
+}
+
+void gl4_2core_glFlush(void *_glfuncs)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glFlush();
+}
+
+void gl4_2core_glFinish(void *_glfuncs)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glFinish();
+}
+
+void gl4_2core_glEnable(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glEnable(cap);
+}
+
+void gl4_2core_glDisable(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glDisable(cap);
+}
+
+void gl4_2core_glDepthMask(void *_glfuncs, GLboolean flag)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glDepthMask(flag);
+}
+
+void gl4_2core_glColorMask(void *_glfuncs, GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glColorMask(red, green, blue, alpha);
+}
+
+void gl4_2core_glStencilMask(void *_glfuncs, GLuint mask)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glStencilMask(mask);
+}
+
+void gl4_2core_glClearDepth(void *_glfuncs, GLdouble depth)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glClearDepth(depth);
+}
+
+void gl4_2core_glClearStencil(void *_glfuncs, GLint s)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glClearStencil(s);
+}
+
+void gl4_2core_glClearColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glClearColor(red, green, blue, alpha);
+}
+
+void gl4_2core_glClear(void *_glfuncs, GLbitfield mask)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glClear(mask);
+}
+
+void gl4_2core_glDrawBuffer(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glDrawBuffer(mode);
+}
+
+void gl4_2core_glTexImage2D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glTexImage2D(target, level, internalFormat, width, height, border, format, gltype, pixels);
+}
+
+void gl4_2core_glTexImage1D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glTexImage1D(target, level, internalFormat, width, border, format, gltype, pixels);
+}
+
+void gl4_2core_glTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glTexParameteriv(target, pname, params);
+}
+
+void gl4_2core_glTexParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glTexParameteri(target, pname, param);
+}
+
+void gl4_2core_glTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glTexParameterfv(target, pname, params);
+}
+
+void gl4_2core_glTexParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glTexParameterf(target, pname, param);
+}
+
+void gl4_2core_glScissor(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glScissor(x, y, width, height);
+}
+
+void gl4_2core_glPolygonMode(void *_glfuncs, GLenum face, GLenum mode)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glPolygonMode(face, mode);
+}
+
+void gl4_2core_glPointSize(void *_glfuncs, GLfloat size)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glPointSize(size);
+}
+
+void gl4_2core_glLineWidth(void *_glfuncs, GLfloat width)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glLineWidth(width);
+}
+
+void gl4_2core_glHint(void *_glfuncs, GLenum target, GLenum mode)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glHint(target, mode);
+}
+
+void gl4_2core_glFrontFace(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glFrontFace(mode);
+}
+
+void gl4_2core_glCullFace(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glCullFace(mode);
+}
+
+void gl4_2core_glIndexubv(void *_glfuncs, const GLubyte* c)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glIndexubv(c);
+}
+
+void gl4_2core_glIndexub(void *_glfuncs, GLubyte c)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glIndexub(c);
+}
+
+GLboolean gl4_2core_glIsTexture(void *_glfuncs, GLuint texture)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ return _qglfuncs->glIsTexture(texture);
+}
+
+void gl4_2core_glGenTextures(void *_glfuncs, GLsizei n, GLuint* textures)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGenTextures(n, textures);
+}
+
+void gl4_2core_glDeleteTextures(void *_glfuncs, GLsizei n, const GLuint* textures)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glDeleteTextures(n, textures);
+}
+
+void gl4_2core_glBindTexture(void *_glfuncs, GLenum target, GLuint texture)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glBindTexture(target, texture);
+}
+
+void gl4_2core_glTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glTexSubImage2D(target, level, xoffset, yoffset, width, height, format, gltype, pixels);
+}
+
+void gl4_2core_glTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glTexSubImage1D(target, level, xoffset, width, format, gltype, pixels);
+}
+
+void gl4_2core_glCopyTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage2D(target, level, xoffset, yoffset, x, y, width, height);
+}
+
+void gl4_2core_glCopyTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage1D(target, level, xoffset, x, y, width);
+}
+
+void gl4_2core_glCopyTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glCopyTexImage2D(target, level, internalFormat, x, y, width, height, border);
+}
+
+void gl4_2core_glCopyTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLint border)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glCopyTexImage1D(target, level, internalFormat, x, y, width, border);
+}
+
+void gl4_2core_glPolygonOffset(void *_glfuncs, GLfloat factor, GLfloat units)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glPolygonOffset(factor, units);
+}
+
+void gl4_2core_glDrawElements(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glDrawElements(mode, count, gltype, indices);
+}
+
+void gl4_2core_glDrawArrays(void *_glfuncs, GLenum mode, GLint first, GLsizei count)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glDrawArrays(mode, first, count);
+}
+
+void gl4_2core_glCopyTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage3D(target, level, xoffset, yoffset, zoffset, x, y, width, height);
+}
+
+void gl4_2core_glTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glTexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, gltype, pixels);
+}
+
+void gl4_2core_glTexImage3D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glTexImage3D(target, level, internalFormat, width, height, depth, border, format, gltype, pixels);
+}
+
+void gl4_2core_glDrawRangeElements(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glDrawRangeElements(mode, start, end, count, gltype, indices);
+}
+
+void gl4_2core_glBlendEquation(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glBlendEquation(mode);
+}
+
+void gl4_2core_glBlendColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glBlendColor(red, green, blue, alpha);
+}
+
+void gl4_2core_glGetCompressedTexImage(void *_glfuncs, GLenum target, GLint level, GLvoid* img)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetCompressedTexImage(target, level, img);
+}
+
+void gl4_2core_glCompressedTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glCompressedTexSubImage1D(target, level, xoffset, width, format, imageSize, data);
+}
+
+void gl4_2core_glCompressedTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glCompressedTexSubImage2D(target, level, xoffset, yoffset, width, height, format, imageSize, data);
+}
+
+void gl4_2core_glCompressedTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glCompressedTexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, imageSize, data);
+}
+
+void gl4_2core_glCompressedTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glCompressedTexImage1D(target, level, internalFormat, width, border, imageSize, data);
+}
+
+void gl4_2core_glCompressedTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glCompressedTexImage2D(target, level, internalFormat, width, height, border, imageSize, data);
+}
+
+void gl4_2core_glCompressedTexImage3D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glCompressedTexImage3D(target, level, internalFormat, width, height, depth, border, imageSize, data);
+}
+
+void gl4_2core_glSampleCoverage(void *_glfuncs, GLfloat value, GLboolean invert)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glSampleCoverage(value, invert);
+}
+
+void gl4_2core_glActiveTexture(void *_glfuncs, GLenum texture)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glActiveTexture(texture);
+}
+
+void gl4_2core_glPointParameteriv(void *_glfuncs, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glPointParameteriv(pname, params);
+}
+
+void gl4_2core_glPointParameteri(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glPointParameteri(pname, param);
+}
+
+void gl4_2core_glPointParameterfv(void *_glfuncs, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glPointParameterfv(pname, params);
+}
+
+void gl4_2core_glPointParameterf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glPointParameterf(pname, param);
+}
+
+void gl4_2core_glMultiDrawArrays(void *_glfuncs, GLenum mode, const GLint* first, const GLsizei* count, GLsizei drawcount)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glMultiDrawArrays(mode, first, count, drawcount);
+}
+
+void gl4_2core_glBlendFuncSeparate(void *_glfuncs, GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glBlendFuncSeparate(sfactorRGB, dfactorRGB, sfactorAlpha, dfactorAlpha);
+}
+
+void gl4_2core_glGetBufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetBufferParameteriv(target, pname, params);
+}
+
+GLboolean gl4_2core_glUnmapBuffer(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ return _qglfuncs->glUnmapBuffer(target);
+}
+
+void gl4_2core_glGetBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, GLvoid* data)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetBufferSubData(target, offset, size, data);
+}
+
+void gl4_2core_glBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid* data)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glBufferSubData(target, offset, size, data);
+}
+
+void gl4_2core_glBufferData(void *_glfuncs, GLenum target, GLsizeiptr size, const GLvoid* data, GLenum usage)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glBufferData(target, size, data, usage);
+}
+
+GLboolean gl4_2core_glIsBuffer(void *_glfuncs, GLuint buffer)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ return _qglfuncs->glIsBuffer(buffer);
+}
+
+void gl4_2core_glGenBuffers(void *_glfuncs, GLsizei n, GLuint* buffers)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGenBuffers(n, buffers);
+}
+
+void gl4_2core_glDeleteBuffers(void *_glfuncs, GLsizei n, const GLuint* buffers)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glDeleteBuffers(n, buffers);
+}
+
+void gl4_2core_glBindBuffer(void *_glfuncs, GLenum target, GLuint buffer)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glBindBuffer(target, buffer);
+}
+
+void gl4_2core_glGetQueryObjectuiv(void *_glfuncs, GLuint id, GLenum pname, GLuint* params)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetQueryObjectuiv(id, pname, params);
+}
+
+void gl4_2core_glGetQueryObjectiv(void *_glfuncs, GLuint id, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetQueryObjectiv(id, pname, params);
+}
+
+void gl4_2core_glGetQueryiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetQueryiv(target, pname, params);
+}
+
+void gl4_2core_glEndQuery(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glEndQuery(target);
+}
+
+void gl4_2core_glBeginQuery(void *_glfuncs, GLenum target, GLuint id)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glBeginQuery(target, id);
+}
+
+GLboolean gl4_2core_glIsQuery(void *_glfuncs, GLuint id)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ return _qglfuncs->glIsQuery(id);
+}
+
+void gl4_2core_glDeleteQueries(void *_glfuncs, GLsizei n, const GLuint* ids)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glDeleteQueries(n, ids);
+}
+
+void gl4_2core_glGenQueries(void *_glfuncs, GLsizei n, GLuint* ids)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGenQueries(n, ids);
+}
+
+void gl4_2core_glVertexAttribPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLboolean normalized, GLsizei stride, const GLvoid* offset)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribPointer(index, size, gltype, normalized, stride, offset);
+}
+
+void gl4_2core_glValidateProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glValidateProgram(program);
+}
+
+void gl4_2core_glUniformMatrix4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4fv(location, count, transpose, value);
+}
+
+void gl4_2core_glUniformMatrix3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3fv(location, count, transpose, value);
+}
+
+void gl4_2core_glUniformMatrix2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2fv(location, count, transpose, value);
+}
+
+void gl4_2core_glUniform4iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glUniform4iv(location, count, value);
+}
+
+void gl4_2core_glUniform3iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glUniform3iv(location, count, value);
+}
+
+void gl4_2core_glUniform2iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glUniform2iv(location, count, value);
+}
+
+void gl4_2core_glUniform1iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glUniform1iv(location, count, value);
+}
+
+void gl4_2core_glUniform4fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glUniform4fv(location, count, value);
+}
+
+void gl4_2core_glUniform3fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glUniform3fv(location, count, value);
+}
+
+void gl4_2core_glUniform2fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glUniform2fv(location, count, value);
+}
+
+void gl4_2core_glUniform1fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glUniform1fv(location, count, value);
+}
+
+void gl4_2core_glUniform4i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2, GLint v3)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glUniform4i(location, v0, v1, v2, v3);
+}
+
+void gl4_2core_glUniform3i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glUniform3i(location, v0, v1, v2);
+}
+
+void gl4_2core_glUniform2i(void *_glfuncs, GLint location, GLint v0, GLint v1)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glUniform2i(location, v0, v1);
+}
+
+void gl4_2core_glUniform1i(void *_glfuncs, GLint location, GLint v0)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glUniform1i(location, v0);
+}
+
+void gl4_2core_glUniform4f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glUniform4f(location, v0, v1, v2, v3);
+}
+
+void gl4_2core_glUniform3f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glUniform3f(location, v0, v1, v2);
+}
+
+void gl4_2core_glUniform2f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glUniform2f(location, v0, v1);
+}
+
+void gl4_2core_glUniform1f(void *_glfuncs, GLint location, GLfloat v0)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glUniform1f(location, v0);
+}
+
+void gl4_2core_glUseProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glUseProgram(program);
+}
+
+void gl4_2core_glShaderSource(void *_glfuncs, GLuint shader, GLsizei count, const GLchar** source, const GLint* length)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glShaderSource(shader, count, source, length);
+}
+
+void gl4_2core_glLinkProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glLinkProgram(program);
+}
+
+GLboolean gl4_2core_glIsShader(void *_glfuncs, GLuint shader)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ return _qglfuncs->glIsShader(shader);
+}
+
+GLboolean gl4_2core_glIsProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ return _qglfuncs->glIsProgram(program);
+}
+
+void gl4_2core_glGetVertexAttribiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribiv(index, pname, params);
+}
+
+void gl4_2core_glGetVertexAttribfv(void *_glfuncs, GLuint index, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribfv(index, pname, params);
+}
+
+void gl4_2core_glGetVertexAttribdv(void *_glfuncs, GLuint index, GLenum pname, GLdouble* params)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribdv(index, pname, params);
+}
+
+void gl4_2core_glGetUniformiv(void *_glfuncs, GLuint program, GLint location, GLint* params)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetUniformiv(program, location, params);
+}
+
+void gl4_2core_glGetUniformfv(void *_glfuncs, GLuint program, GLint location, GLfloat* params)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetUniformfv(program, location, params);
+}
+
+GLint gl4_2core_glGetUniformLocation(void *_glfuncs, GLuint program, const GLchar* name)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ return _qglfuncs->glGetUniformLocation(program, name);
+}
+
+void gl4_2core_glGetShaderSource(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* source)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetShaderSource(shader, bufSize, length, source);
+}
+
+void gl4_2core_glGetShaderInfoLog(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* infoLog)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetShaderInfoLog(shader, bufSize, length, infoLog);
+}
+
+void gl4_2core_glGetShaderiv(void *_glfuncs, GLuint shader, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetShaderiv(shader, pname, params);
+}
+
+void gl4_2core_glGetProgramInfoLog(void *_glfuncs, GLuint program, GLsizei bufSize, GLsizei* length, GLchar* infoLog)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetProgramInfoLog(program, bufSize, length, infoLog);
+}
+
+void gl4_2core_glGetProgramiv(void *_glfuncs, GLuint program, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetProgramiv(program, pname, params);
+}
+
+GLint gl4_2core_glGetAttribLocation(void *_glfuncs, GLuint program, const GLchar* name)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ return _qglfuncs->glGetAttribLocation(program, name);
+}
+
+void gl4_2core_glGetAttachedShaders(void *_glfuncs, GLuint program, GLsizei maxCount, GLsizei* count, GLuint* obj)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetAttachedShaders(program, maxCount, count, obj);
+}
+
+void gl4_2core_glGetActiveUniform(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetActiveUniform(program, index, bufSize, length, size, gltype, name);
+}
+
+void gl4_2core_glGetActiveAttrib(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetActiveAttrib(program, index, bufSize, length, size, gltype, name);
+}
+
+void gl4_2core_glEnableVertexAttribArray(void *_glfuncs, GLuint index)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glEnableVertexAttribArray(index);
+}
+
+void gl4_2core_glDisableVertexAttribArray(void *_glfuncs, GLuint index)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glDisableVertexAttribArray(index);
+}
+
+void gl4_2core_glDetachShader(void *_glfuncs, GLuint program, GLuint shader)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glDetachShader(program, shader);
+}
+
+void gl4_2core_glDeleteShader(void *_glfuncs, GLuint shader)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glDeleteShader(shader);
+}
+
+void gl4_2core_glDeleteProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glDeleteProgram(program);
+}
+
+GLuint gl4_2core_glCreateShader(void *_glfuncs, GLenum gltype)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ return _qglfuncs->glCreateShader(gltype);
+}
+
+GLuint gl4_2core_glCreateProgram(void *_glfuncs)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ return _qglfuncs->glCreateProgram();
+}
+
+void gl4_2core_glCompileShader(void *_glfuncs, GLuint shader)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glCompileShader(shader);
+}
+
+void gl4_2core_glBindAttribLocation(void *_glfuncs, GLuint program, GLuint index, const GLchar* name)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glBindAttribLocation(program, index, name);
+}
+
+void gl4_2core_glAttachShader(void *_glfuncs, GLuint program, GLuint shader)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glAttachShader(program, shader);
+}
+
+void gl4_2core_glStencilMaskSeparate(void *_glfuncs, GLenum face, GLuint mask)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glStencilMaskSeparate(face, mask);
+}
+
+void gl4_2core_glStencilFuncSeparate(void *_glfuncs, GLenum face, GLenum glfunc, GLint ref, GLuint mask)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glStencilFuncSeparate(face, glfunc, ref, mask);
+}
+
+void gl4_2core_glStencilOpSeparate(void *_glfuncs, GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glStencilOpSeparate(face, sfail, dpfail, dppass);
+}
+
+void gl4_2core_glDrawBuffers(void *_glfuncs, GLsizei n, const GLenum* bufs)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glDrawBuffers(n, bufs);
+}
+
+void gl4_2core_glBlendEquationSeparate(void *_glfuncs, GLenum modeRGB, GLenum modeAlpha)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glBlendEquationSeparate(modeRGB, modeAlpha);
+}
+
+void gl4_2core_glUniformMatrix4x3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4x3fv(location, count, transpose, value);
+}
+
+void gl4_2core_glUniformMatrix3x4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3x4fv(location, count, transpose, value);
+}
+
+void gl4_2core_glUniformMatrix4x2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4x2fv(location, count, transpose, value);
+}
+
+void gl4_2core_glUniformMatrix2x4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2x4fv(location, count, transpose, value);
+}
+
+void gl4_2core_glUniformMatrix3x2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3x2fv(location, count, transpose, value);
+}
+
+void gl4_2core_glUniformMatrix2x3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2x3fv(location, count, transpose, value);
+}
+
+GLboolean gl4_2core_glIsVertexArray(void *_glfuncs, GLuint array)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ return _qglfuncs->glIsVertexArray(array);
+}
+
+void gl4_2core_glGenVertexArrays(void *_glfuncs, GLsizei n, GLuint* arrays)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGenVertexArrays(n, arrays);
+}
+
+void gl4_2core_glDeleteVertexArrays(void *_glfuncs, GLsizei n, const GLuint* arrays)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glDeleteVertexArrays(n, arrays);
+}
+
+void gl4_2core_glBindVertexArray(void *_glfuncs, GLuint array)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glBindVertexArray(array);
+}
+
+void gl4_2core_glFlushMappedBufferRange(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr length)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glFlushMappedBufferRange(target, offset, length);
+}
+
+void gl4_2core_glFramebufferTextureLayer(void *_glfuncs, GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glFramebufferTextureLayer(target, attachment, texture, level, layer);
+}
+
+void gl4_2core_glRenderbufferStorageMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLenum internalFormat, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glRenderbufferStorageMultisample(target, samples, internalFormat, width, height);
+}
+
+void gl4_2core_glBlitFramebuffer(void *_glfuncs, GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glBlitFramebuffer(srcX0, srcY0, srcX1, srcY1, dstX0, dstY0, dstX1, dstY1, mask, filter);
+}
+
+void gl4_2core_glGenerateMipmap(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGenerateMipmap(target);
+}
+
+void gl4_2core_glGetFramebufferAttachmentParameteriv(void *_glfuncs, GLenum target, GLenum attachment, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetFramebufferAttachmentParameteriv(target, attachment, pname, params);
+}
+
+void gl4_2core_glFramebufferRenderbuffer(void *_glfuncs, GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glFramebufferRenderbuffer(target, attachment, renderbuffertarget, renderbuffer);
+}
+
+void gl4_2core_glFramebufferTexture3D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glFramebufferTexture3D(target, attachment, textarget, texture, level, zoffset);
+}
+
+void gl4_2core_glFramebufferTexture2D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glFramebufferTexture2D(target, attachment, textarget, texture, level);
+}
+
+void gl4_2core_glFramebufferTexture1D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glFramebufferTexture1D(target, attachment, textarget, texture, level);
+}
+
+GLenum gl4_2core_glCheckFramebufferStatus(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ return _qglfuncs->glCheckFramebufferStatus(target);
+}
+
+void gl4_2core_glGenFramebuffers(void *_glfuncs, GLsizei n, GLuint* framebuffers)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGenFramebuffers(n, framebuffers);
+}
+
+void gl4_2core_glDeleteFramebuffers(void *_glfuncs, GLsizei n, const GLuint* framebuffers)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glDeleteFramebuffers(n, framebuffers);
+}
+
+void gl4_2core_glBindFramebuffer(void *_glfuncs, GLenum target, GLuint framebuffer)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glBindFramebuffer(target, framebuffer);
+}
+
+GLboolean gl4_2core_glIsFramebuffer(void *_glfuncs, GLuint framebuffer)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ return _qglfuncs->glIsFramebuffer(framebuffer);
+}
+
+void gl4_2core_glGetRenderbufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetRenderbufferParameteriv(target, pname, params);
+}
+
+void gl4_2core_glRenderbufferStorage(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glRenderbufferStorage(target, internalFormat, width, height);
+}
+
+void gl4_2core_glGenRenderbuffers(void *_glfuncs, GLsizei n, GLuint* renderbuffers)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGenRenderbuffers(n, renderbuffers);
+}
+
+void gl4_2core_glDeleteRenderbuffers(void *_glfuncs, GLsizei n, const GLuint* renderbuffers)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glDeleteRenderbuffers(n, renderbuffers);
+}
+
+void gl4_2core_glBindRenderbuffer(void *_glfuncs, GLenum target, GLuint renderbuffer)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glBindRenderbuffer(target, renderbuffer);
+}
+
+GLboolean gl4_2core_glIsRenderbuffer(void *_glfuncs, GLuint renderbuffer)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ return _qglfuncs->glIsRenderbuffer(renderbuffer);
+}
+
+void gl4_2core_glClearBufferfi(void *_glfuncs, GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glClearBufferfi(buffer, drawbuffer, depth, stencil);
+}
+
+void gl4_2core_glClearBufferfv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLfloat* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glClearBufferfv(buffer, drawbuffer, value);
+}
+
+void gl4_2core_glClearBufferuiv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLuint* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glClearBufferuiv(buffer, drawbuffer, value);
+}
+
+void gl4_2core_glClearBufferiv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLint* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glClearBufferiv(buffer, drawbuffer, value);
+}
+
+void gl4_2core_glGetTexParameterIuiv(void *_glfuncs, GLenum target, GLenum pname, GLuint* params)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetTexParameterIuiv(target, pname, params);
+}
+
+void gl4_2core_glGetTexParameterIiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetTexParameterIiv(target, pname, params);
+}
+
+void gl4_2core_glTexParameterIuiv(void *_glfuncs, GLenum target, GLenum pname, const GLuint* params)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glTexParameterIuiv(target, pname, params);
+}
+
+void gl4_2core_glTexParameterIiv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glTexParameterIiv(target, pname, params);
+}
+
+void gl4_2core_glUniform4uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glUniform4uiv(location, count, value);
+}
+
+void gl4_2core_glUniform3uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glUniform3uiv(location, count, value);
+}
+
+void gl4_2core_glUniform2uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glUniform2uiv(location, count, value);
+}
+
+void gl4_2core_glUniform1uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glUniform1uiv(location, count, value);
+}
+
+void gl4_2core_glUniform4ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glUniform4ui(location, v0, v1, v2, v3);
+}
+
+void gl4_2core_glUniform3ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1, GLuint v2)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glUniform3ui(location, v0, v1, v2);
+}
+
+void gl4_2core_glUniform2ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glUniform2ui(location, v0, v1);
+}
+
+void gl4_2core_glUniform1ui(void *_glfuncs, GLint location, GLuint v0)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glUniform1ui(location, v0);
+}
+
+GLint gl4_2core_glGetFragDataLocation(void *_glfuncs, GLuint program, const GLchar* name)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ return _qglfuncs->glGetFragDataLocation(program, name);
+}
+
+void gl4_2core_glBindFragDataLocation(void *_glfuncs, GLuint program, GLuint color, const GLchar* name)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glBindFragDataLocation(program, color, name);
+}
+
+void gl4_2core_glGetUniformuiv(void *_glfuncs, GLuint program, GLint location, GLuint* params)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetUniformuiv(program, location, params);
+}
+
+void gl4_2core_glGetVertexAttribIuiv(void *_glfuncs, GLuint index, GLenum pname, GLuint* params)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribIuiv(index, pname, params);
+}
+
+void gl4_2core_glGetVertexAttribIiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribIiv(index, pname, params);
+}
+
+void gl4_2core_glVertexAttribIPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribIPointer(index, size, gltype, stride, pointer);
+}
+
+void gl4_2core_glEndConditionalRender(void *_glfuncs)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glEndConditionalRender();
+}
+
+void gl4_2core_glBeginConditionalRender(void *_glfuncs, GLuint id, GLenum mode)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glBeginConditionalRender(id, mode);
+}
+
+void gl4_2core_glClampColor(void *_glfuncs, GLenum target, GLenum clamp)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glClampColor(target, clamp);
+}
+
+void gl4_2core_glGetTransformFeedbackVarying(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLsizei* size, GLenum* gltype, GLchar* name)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetTransformFeedbackVarying(program, index, bufSize, length, size, gltype, name);
+}
+
+void gl4_2core_glBindBufferBase(void *_glfuncs, GLenum target, GLuint index, GLuint buffer)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glBindBufferBase(target, index, buffer);
+}
+
+void gl4_2core_glBindBufferRange(void *_glfuncs, GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glBindBufferRange(target, index, buffer, offset, size);
+}
+
+void gl4_2core_glEndTransformFeedback(void *_glfuncs)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glEndTransformFeedback();
+}
+
+void gl4_2core_glBeginTransformFeedback(void *_glfuncs, GLenum primitiveMode)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glBeginTransformFeedback(primitiveMode);
+}
+
+GLboolean gl4_2core_glIsEnabledi(void *_glfuncs, GLenum target, GLuint index)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ return _qglfuncs->glIsEnabledi(target, index);
+}
+
+void gl4_2core_glDisablei(void *_glfuncs, GLenum target, GLuint index)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glDisablei(target, index);
+}
+
+void gl4_2core_glEnablei(void *_glfuncs, GLenum target, GLuint index)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glEnablei(target, index);
+}
+
+void gl4_2core_glGetIntegeri_v(void *_glfuncs, GLenum target, GLuint index, GLint* data)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetIntegeri_v(target, index, data);
+}
+
+void gl4_2core_glGetBooleani_v(void *_glfuncs, GLenum target, GLuint index, GLboolean* data)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetBooleani_v(target, index, data);
+}
+
+void gl4_2core_glColorMaski(void *_glfuncs, GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glColorMaski(index, r, g, b, a);
+}
+
+void gl4_2core_glCopyBufferSubData(void *_glfuncs, GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glCopyBufferSubData(readTarget, writeTarget, readOffset, writeOffset, size);
+}
+
+void gl4_2core_glUniformBlockBinding(void *_glfuncs, GLuint program, GLuint v0, GLuint v1)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glUniformBlockBinding(program, v0, v1);
+}
+
+void gl4_2core_glGetActiveUniformBlockName(void *_glfuncs, GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei* length, GLchar* uniformBlockName)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetActiveUniformBlockName(program, uniformBlockIndex, bufSize, length, uniformBlockName);
+}
+
+void gl4_2core_glGetActiveUniformBlockiv(void *_glfuncs, GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetActiveUniformBlockiv(program, uniformBlockIndex, pname, params);
+}
+
+GLuint gl4_2core_glGetUniformBlockIndex(void *_glfuncs, GLuint program, const GLchar* uniformBlockName)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ return _qglfuncs->glGetUniformBlockIndex(program, uniformBlockName);
+}
+
+void gl4_2core_glGetActiveUniformName(void *_glfuncs, GLuint program, GLuint uniformIndex, GLsizei bufSize, GLsizei* length, GLchar* uniformName)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetActiveUniformName(program, uniformIndex, bufSize, length, uniformName);
+}
+
+void gl4_2core_glGetActiveUniformsiv(void *_glfuncs, GLuint program, GLsizei uniformCount, const GLuint* uniformIndices, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetActiveUniformsiv(program, uniformCount, uniformIndices, pname, params);
+}
+
+void gl4_2core_glPrimitiveRestartIndex(void *_glfuncs, GLuint index)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glPrimitiveRestartIndex(index);
+}
+
+void gl4_2core_glTexBuffer(void *_glfuncs, GLenum target, GLenum internalFormat, GLuint buffer)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glTexBuffer(target, internalFormat, buffer);
+}
+
+void gl4_2core_glDrawElementsInstanced(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glDrawElementsInstanced(mode, count, gltype, indices, instancecount);
+}
+
+void gl4_2core_glDrawArraysInstanced(void *_glfuncs, GLenum mode, GLint first, GLsizei count, GLsizei instancecount)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glDrawArraysInstanced(mode, first, count, instancecount);
+}
+
+void gl4_2core_glSampleMaski(void *_glfuncs, GLuint index, GLbitfield mask)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glSampleMaski(index, mask);
+}
+
+void gl4_2core_glGetMultisamplefv(void *_glfuncs, GLenum pname, GLuint index, GLfloat* val)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetMultisamplefv(pname, index, val);
+}
+
+void gl4_2core_glTexImage3DMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glTexImage3DMultisample(target, samples, internalFormat, width, height, depth, fixedsamplelocations);
+}
+
+void gl4_2core_glTexImage2DMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLint internalFormat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glTexImage2DMultisample(target, samples, internalFormat, width, height, fixedsamplelocations);
+}
+
+void gl4_2core_glGetSynciv(void *_glfuncs, GLsync sync, GLenum pname, GLsizei bufSize, GLsizei* length, GLint* values)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetSynciv(sync, pname, bufSize, length, values);
+}
+
+void gl4_2core_glGetInteger64v(void *_glfuncs, GLenum pname, GLint64* params)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetInteger64v(pname, params);
+}
+
+void gl4_2core_glWaitSync(void *_glfuncs, GLsync sync, GLbitfield flags, GLuint64 timeout)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glWaitSync(sync, flags, timeout);
+}
+
+GLenum gl4_2core_glClientWaitSync(void *_glfuncs, GLsync sync, GLbitfield flags, GLuint64 timeout)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ return _qglfuncs->glClientWaitSync(sync, flags, timeout);
+}
+
+void gl4_2core_glDeleteSync(void *_glfuncs, GLsync sync)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glDeleteSync(sync);
+}
+
+GLboolean gl4_2core_glIsSync(void *_glfuncs, GLsync sync)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ return _qglfuncs->glIsSync(sync);
+}
+
+GLsync gl4_2core_glFenceSync(void *_glfuncs, GLenum condition, GLbitfield flags)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ return _qglfuncs->glFenceSync(condition, flags);
+}
+
+void gl4_2core_glProvokingVertex(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glProvokingVertex(mode);
+}
+
+void gl4_2core_glDrawElementsInstancedBaseVertex(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount, GLint basevertex)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glDrawElementsInstancedBaseVertex(mode, count, gltype, indices, instancecount, basevertex);
+}
+
+void gl4_2core_glDrawRangeElementsBaseVertex(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices, GLint basevertex)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glDrawRangeElementsBaseVertex(mode, start, end, count, gltype, indices, basevertex);
+}
+
+void gl4_2core_glDrawElementsBaseVertex(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLint basevertex)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glDrawElementsBaseVertex(mode, count, gltype, indices, basevertex);
+}
+
+void gl4_2core_glFramebufferTexture(void *_glfuncs, GLenum target, GLenum attachment, GLuint texture, GLint level)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glFramebufferTexture(target, attachment, texture, level);
+}
+
+void gl4_2core_glGetBufferParameteri64v(void *_glfuncs, GLenum target, GLenum pname, GLint64* params)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetBufferParameteri64v(target, pname, params);
+}
+
+void gl4_2core_glGetInteger64i_v(void *_glfuncs, GLenum target, GLuint index, GLint64* data)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetInteger64i_v(target, index, data);
+}
+
+void gl4_2core_glVertexAttribP4uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribP4uiv(index, gltype, normalized, value);
+}
+
+void gl4_2core_glVertexAttribP4ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribP4ui(index, gltype, normalized, value);
+}
+
+void gl4_2core_glVertexAttribP3uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribP3uiv(index, gltype, normalized, value);
+}
+
+void gl4_2core_glVertexAttribP3ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribP3ui(index, gltype, normalized, value);
+}
+
+void gl4_2core_glVertexAttribP2uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribP2uiv(index, gltype, normalized, value);
+}
+
+void gl4_2core_glVertexAttribP2ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribP2ui(index, gltype, normalized, value);
+}
+
+void gl4_2core_glVertexAttribP1uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribP1uiv(index, gltype, normalized, value);
+}
+
+void gl4_2core_glVertexAttribP1ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribP1ui(index, gltype, normalized, value);
+}
+
+void gl4_2core_glSecondaryColorP3uiv(void *_glfuncs, GLenum gltype, const GLuint* color)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glSecondaryColorP3uiv(gltype, color);
+}
+
+void gl4_2core_glSecondaryColorP3ui(void *_glfuncs, GLenum gltype, GLuint color)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glSecondaryColorP3ui(gltype, color);
+}
+
+void gl4_2core_glColorP4uiv(void *_glfuncs, GLenum gltype, const GLuint* color)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glColorP4uiv(gltype, color);
+}
+
+void gl4_2core_glColorP4ui(void *_glfuncs, GLenum gltype, GLuint color)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glColorP4ui(gltype, color);
+}
+
+void gl4_2core_glColorP3uiv(void *_glfuncs, GLenum gltype, const GLuint* color)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glColorP3uiv(gltype, color);
+}
+
+void gl4_2core_glColorP3ui(void *_glfuncs, GLenum gltype, GLuint color)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glColorP3ui(gltype, color);
+}
+
+void gl4_2core_glNormalP3uiv(void *_glfuncs, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glNormalP3uiv(gltype, coords);
+}
+
+void gl4_2core_glNormalP3ui(void *_glfuncs, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glNormalP3ui(gltype, coords);
+}
+
+void gl4_2core_glMultiTexCoordP4uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP4uiv(texture, gltype, coords);
+}
+
+void gl4_2core_glMultiTexCoordP4ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP4ui(texture, gltype, coords);
+}
+
+void gl4_2core_glMultiTexCoordP3uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP3uiv(texture, gltype, coords);
+}
+
+void gl4_2core_glMultiTexCoordP3ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP3ui(texture, gltype, coords);
+}
+
+void gl4_2core_glMultiTexCoordP2uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP2uiv(texture, gltype, coords);
+}
+
+void gl4_2core_glMultiTexCoordP2ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP2ui(texture, gltype, coords);
+}
+
+void gl4_2core_glMultiTexCoordP1uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP1uiv(texture, gltype, coords);
+}
+
+void gl4_2core_glMultiTexCoordP1ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP1ui(texture, gltype, coords);
+}
+
+void gl4_2core_glTexCoordP4uiv(void *_glfuncs, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glTexCoordP4uiv(gltype, coords);
+}
+
+void gl4_2core_glTexCoordP4ui(void *_glfuncs, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glTexCoordP4ui(gltype, coords);
+}
+
+void gl4_2core_glTexCoordP3uiv(void *_glfuncs, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glTexCoordP3uiv(gltype, coords);
+}
+
+void gl4_2core_glTexCoordP3ui(void *_glfuncs, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glTexCoordP3ui(gltype, coords);
+}
+
+void gl4_2core_glTexCoordP2uiv(void *_glfuncs, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glTexCoordP2uiv(gltype, coords);
+}
+
+void gl4_2core_glTexCoordP2ui(void *_glfuncs, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glTexCoordP2ui(gltype, coords);
+}
+
+void gl4_2core_glTexCoordP1uiv(void *_glfuncs, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glTexCoordP1uiv(gltype, coords);
+}
+
+void gl4_2core_glTexCoordP1ui(void *_glfuncs, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glTexCoordP1ui(gltype, coords);
+}
+
+void gl4_2core_glVertexP4uiv(void *_glfuncs, GLenum gltype, const GLuint* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glVertexP4uiv(gltype, value);
+}
+
+void gl4_2core_glVertexP4ui(void *_glfuncs, GLenum gltype, GLuint value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glVertexP4ui(gltype, value);
+}
+
+void gl4_2core_glVertexP3uiv(void *_glfuncs, GLenum gltype, const GLuint* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glVertexP3uiv(gltype, value);
+}
+
+void gl4_2core_glVertexP3ui(void *_glfuncs, GLenum gltype, GLuint value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glVertexP3ui(gltype, value);
+}
+
+void gl4_2core_glVertexP2uiv(void *_glfuncs, GLenum gltype, const GLuint* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glVertexP2uiv(gltype, value);
+}
+
+void gl4_2core_glVertexP2ui(void *_glfuncs, GLenum gltype, GLuint value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glVertexP2ui(gltype, value);
+}
+
+void gl4_2core_glGetQueryObjectui64v(void *_glfuncs, GLuint id, GLenum pname, GLuint64* params)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetQueryObjectui64v(id, pname, params);
+}
+
+void gl4_2core_glGetQueryObjecti64v(void *_glfuncs, GLuint id, GLenum pname, GLint64* params)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetQueryObjecti64v(id, pname, params);
+}
+
+void gl4_2core_glQueryCounter(void *_glfuncs, GLuint id, GLenum target)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glQueryCounter(id, target);
+}
+
+void gl4_2core_glGetSamplerParameterIuiv(void *_glfuncs, GLuint sampler, GLenum pname, GLuint* params)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetSamplerParameterIuiv(sampler, pname, params);
+}
+
+void gl4_2core_glGetSamplerParameterfv(void *_glfuncs, GLuint sampler, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetSamplerParameterfv(sampler, pname, params);
+}
+
+void gl4_2core_glGetSamplerParameterIiv(void *_glfuncs, GLuint sampler, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetSamplerParameterIiv(sampler, pname, params);
+}
+
+void gl4_2core_glGetSamplerParameteriv(void *_glfuncs, GLuint sampler, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetSamplerParameteriv(sampler, pname, params);
+}
+
+void gl4_2core_glSamplerParameterIuiv(void *_glfuncs, GLuint sampler, GLenum pname, const GLuint* param)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glSamplerParameterIuiv(sampler, pname, param);
+}
+
+void gl4_2core_glSamplerParameterIiv(void *_glfuncs, GLuint sampler, GLenum pname, const GLint* param)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glSamplerParameterIiv(sampler, pname, param);
+}
+
+void gl4_2core_glSamplerParameterfv(void *_glfuncs, GLuint sampler, GLenum pname, const GLfloat* param)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glSamplerParameterfv(sampler, pname, param);
+}
+
+void gl4_2core_glSamplerParameterf(void *_glfuncs, GLuint sampler, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glSamplerParameterf(sampler, pname, param);
+}
+
+void gl4_2core_glSamplerParameteriv(void *_glfuncs, GLuint sampler, GLenum pname, const GLint* param)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glSamplerParameteriv(sampler, pname, param);
+}
+
+void gl4_2core_glSamplerParameteri(void *_glfuncs, GLuint sampler, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glSamplerParameteri(sampler, pname, param);
+}
+
+void gl4_2core_glBindSampler(void *_glfuncs, GLuint unit, GLuint sampler)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glBindSampler(unit, sampler);
+}
+
+GLboolean gl4_2core_glIsSampler(void *_glfuncs, GLuint sampler)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ return _qglfuncs->glIsSampler(sampler);
+}
+
+void gl4_2core_glDeleteSamplers(void *_glfuncs, GLsizei count, const GLuint* samplers)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glDeleteSamplers(count, samplers);
+}
+
+void gl4_2core_glGenSamplers(void *_glfuncs, GLsizei count, GLuint* samplers)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGenSamplers(count, samplers);
+}
+
+GLint gl4_2core_glGetFragDataIndex(void *_glfuncs, GLuint program, const GLchar* name)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ return _qglfuncs->glGetFragDataIndex(program, name);
+}
+
+void gl4_2core_glBindFragDataLocationIndexed(void *_glfuncs, GLuint program, GLuint colorNumber, GLuint index, const GLchar* name)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glBindFragDataLocationIndexed(program, colorNumber, index, name);
+}
+
+void gl4_2core_glVertexAttribDivisor(void *_glfuncs, GLuint index, GLuint divisor)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribDivisor(index, divisor);
+}
+
+void gl4_2core_glGetQueryIndexediv(void *_glfuncs, GLenum target, GLuint index, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetQueryIndexediv(target, index, pname, params);
+}
+
+void gl4_2core_glEndQueryIndexed(void *_glfuncs, GLenum target, GLuint index)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glEndQueryIndexed(target, index);
+}
+
+void gl4_2core_glBeginQueryIndexed(void *_glfuncs, GLenum target, GLuint index, GLuint id)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glBeginQueryIndexed(target, index, id);
+}
+
+void gl4_2core_glDrawTransformFeedbackStream(void *_glfuncs, GLenum mode, GLuint id, GLuint stream)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glDrawTransformFeedbackStream(mode, id, stream);
+}
+
+void gl4_2core_glDrawTransformFeedback(void *_glfuncs, GLenum mode, GLuint id)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glDrawTransformFeedback(mode, id);
+}
+
+void gl4_2core_glResumeTransformFeedback(void *_glfuncs)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glResumeTransformFeedback();
+}
+
+void gl4_2core_glPauseTransformFeedback(void *_glfuncs)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glPauseTransformFeedback();
+}
+
+GLboolean gl4_2core_glIsTransformFeedback(void *_glfuncs, GLuint id)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ return _qglfuncs->glIsTransformFeedback(id);
+}
+
+void gl4_2core_glGenTransformFeedbacks(void *_glfuncs, GLsizei n, GLuint* ids)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGenTransformFeedbacks(n, ids);
+}
+
+void gl4_2core_glDeleteTransformFeedbacks(void *_glfuncs, GLsizei n, const GLuint* ids)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glDeleteTransformFeedbacks(n, ids);
+}
+
+void gl4_2core_glBindTransformFeedback(void *_glfuncs, GLenum target, GLuint id)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glBindTransformFeedback(target, id);
+}
+
+void gl4_2core_glPatchParameterfv(void *_glfuncs, GLenum pname, const GLfloat* values)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glPatchParameterfv(pname, values);
+}
+
+void gl4_2core_glPatchParameteri(void *_glfuncs, GLenum pname, GLint value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glPatchParameteri(pname, value);
+}
+
+void gl4_2core_glGetProgramStageiv(void *_glfuncs, GLuint program, GLenum shadertype, GLenum pname, GLint* values)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetProgramStageiv(program, shadertype, pname, values);
+}
+
+void gl4_2core_glGetUniformSubroutineuiv(void *_glfuncs, GLenum shadertype, GLint location, GLuint* params)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetUniformSubroutineuiv(shadertype, location, params);
+}
+
+void gl4_2core_glUniformSubroutinesuiv(void *_glfuncs, GLenum shadertype, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glUniformSubroutinesuiv(shadertype, count, value);
+}
+
+void gl4_2core_glGetActiveSubroutineName(void *_glfuncs, GLuint program, GLenum shadertype, GLuint index, GLsizei bufSize, GLsizei* length, GLchar* name)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetActiveSubroutineName(program, shadertype, index, bufSize, length, name);
+}
+
+void gl4_2core_glGetActiveSubroutineUniformName(void *_glfuncs, GLuint program, GLenum shadertype, GLuint index, GLsizei bufSize, GLsizei* length, GLchar* name)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetActiveSubroutineUniformName(program, shadertype, index, bufSize, length, name);
+}
+
+void gl4_2core_glGetActiveSubroutineUniformiv(void *_glfuncs, GLuint program, GLenum shadertype, GLuint index, GLenum pname, GLint* values)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetActiveSubroutineUniformiv(program, shadertype, index, pname, values);
+}
+
+GLuint gl4_2core_glGetSubroutineIndex(void *_glfuncs, GLuint program, GLenum shadertype, const GLchar* name)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ return _qglfuncs->glGetSubroutineIndex(program, shadertype, name);
+}
+
+GLint gl4_2core_glGetSubroutineUniformLocation(void *_glfuncs, GLuint program, GLenum shadertype, const GLchar* name)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ return _qglfuncs->glGetSubroutineUniformLocation(program, shadertype, name);
+}
+
+void gl4_2core_glGetUniformdv(void *_glfuncs, GLuint program, GLint location, GLdouble* params)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetUniformdv(program, location, params);
+}
+
+void gl4_2core_glUniformMatrix4x3dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4x3dv(location, count, transpose, value);
+}
+
+void gl4_2core_glUniformMatrix4x2dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4x2dv(location, count, transpose, value);
+}
+
+void gl4_2core_glUniformMatrix3x4dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3x4dv(location, count, transpose, value);
+}
+
+void gl4_2core_glUniformMatrix3x2dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3x2dv(location, count, transpose, value);
+}
+
+void gl4_2core_glUniformMatrix2x4dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2x4dv(location, count, transpose, value);
+}
+
+void gl4_2core_glUniformMatrix2x3dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2x3dv(location, count, transpose, value);
+}
+
+void gl4_2core_glUniformMatrix4dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4dv(location, count, transpose, value);
+}
+
+void gl4_2core_glUniformMatrix3dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3dv(location, count, transpose, value);
+}
+
+void gl4_2core_glUniformMatrix2dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2dv(location, count, transpose, value);
+}
+
+void gl4_2core_glUniform4dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glUniform4dv(location, count, value);
+}
+
+void gl4_2core_glUniform3dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glUniform3dv(location, count, value);
+}
+
+void gl4_2core_glUniform2dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glUniform2dv(location, count, value);
+}
+
+void gl4_2core_glUniform1dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glUniform1dv(location, count, value);
+}
+
+void gl4_2core_glUniform4d(void *_glfuncs, GLint location, GLdouble v0, GLdouble v1, GLdouble v2, GLdouble v3)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glUniform4d(location, v0, v1, v2, v3);
+}
+
+void gl4_2core_glUniform3d(void *_glfuncs, GLint location, GLdouble v0, GLdouble v1, GLdouble v2)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glUniform3d(location, v0, v1, v2);
+}
+
+void gl4_2core_glUniform2d(void *_glfuncs, GLint location, GLdouble v0, GLdouble v1)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glUniform2d(location, v0, v1);
+}
+
+void gl4_2core_glUniform1d(void *_glfuncs, GLint location, GLdouble v0)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glUniform1d(location, v0);
+}
+
+void gl4_2core_glDrawElementsIndirect(void *_glfuncs, GLenum mode, GLenum gltype, const GLvoid* indirect)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glDrawElementsIndirect(mode, gltype, indirect);
+}
+
+void gl4_2core_glDrawArraysIndirect(void *_glfuncs, GLenum mode, const GLvoid* indirect)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glDrawArraysIndirect(mode, indirect);
+}
+
+void gl4_2core_glBlendFuncSeparatei(void *_glfuncs, GLuint buf, GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha, GLenum dstAlpha)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glBlendFuncSeparatei(buf, srcRGB, dstRGB, srcAlpha, dstAlpha);
+}
+
+void gl4_2core_glBlendFunci(void *_glfuncs, GLuint buf, GLenum src, GLenum dst)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glBlendFunci(buf, src, dst);
+}
+
+void gl4_2core_glBlendEquationSeparatei(void *_glfuncs, GLuint buf, GLenum modeRGB, GLenum modeAlpha)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glBlendEquationSeparatei(buf, modeRGB, modeAlpha);
+}
+
+void gl4_2core_glBlendEquationi(void *_glfuncs, GLuint buf, GLenum mode)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glBlendEquationi(buf, mode);
+}
+
+void gl4_2core_glMinSampleShading(void *_glfuncs, GLfloat value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glMinSampleShading(value);
+}
+
+void gl4_2core_glGetDoublei_v(void *_glfuncs, GLenum target, GLuint index, GLdouble* data)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetDoublei_v(target, index, data);
+}
+
+void gl4_2core_glGetFloati_v(void *_glfuncs, GLenum target, GLuint index, GLfloat* data)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetFloati_v(target, index, data);
+}
+
+void gl4_2core_glDepthRangeIndexed(void *_glfuncs, GLuint index, GLdouble n, GLdouble f)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glDepthRangeIndexed(index, n, f);
+}
+
+void gl4_2core_glDepthRangeArrayv(void *_glfuncs, GLuint first, GLsizei count, const GLdouble* v)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glDepthRangeArrayv(first, count, v);
+}
+
+void gl4_2core_glScissorIndexedv(void *_glfuncs, GLuint index, const GLint* v)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glScissorIndexedv(index, v);
+}
+
+void gl4_2core_glScissorIndexed(void *_glfuncs, GLuint index, GLint left, GLint bottom, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glScissorIndexed(index, left, bottom, width, height);
+}
+
+void gl4_2core_glScissorArrayv(void *_glfuncs, GLuint first, GLsizei count, const GLint* v)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glScissorArrayv(first, count, v);
+}
+
+void gl4_2core_glViewportIndexedfv(void *_glfuncs, GLuint index, const GLfloat* v)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glViewportIndexedfv(index, v);
+}
+
+void gl4_2core_glViewportIndexedf(void *_glfuncs, GLuint index, GLfloat x, GLfloat y, GLfloat w, GLfloat h)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glViewportIndexedf(index, x, y, w, h);
+}
+
+void gl4_2core_glViewportArrayv(void *_glfuncs, GLuint first, GLsizei count, const GLfloat* v)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glViewportArrayv(first, count, v);
+}
+
+void gl4_2core_glGetVertexAttribLdv(void *_glfuncs, GLuint index, GLenum pname, GLdouble* params)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribLdv(index, pname, params);
+}
+
+void gl4_2core_glVertexAttribLPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribLPointer(index, size, gltype, stride, pointer);
+}
+
+void gl4_2core_glVertexAttribL4dv(void *_glfuncs, GLuint index, const GLdouble* v)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribL4dv(index, v);
+}
+
+void gl4_2core_glVertexAttribL3dv(void *_glfuncs, GLuint index, const GLdouble* v)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribL3dv(index, v);
+}
+
+void gl4_2core_glVertexAttribL2dv(void *_glfuncs, GLuint index, const GLdouble* v)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribL2dv(index, v);
+}
+
+void gl4_2core_glVertexAttribL1dv(void *_glfuncs, GLuint index, const GLdouble* v)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribL1dv(index, v);
+}
+
+void gl4_2core_glVertexAttribL4d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribL4d(index, x, y, z, w);
+}
+
+void gl4_2core_glVertexAttribL3d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribL3d(index, x, y, z);
+}
+
+void gl4_2core_glVertexAttribL2d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribL2d(index, x, y);
+}
+
+void gl4_2core_glVertexAttribL1d(void *_glfuncs, GLuint index, GLdouble x)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribL1d(index, x);
+}
+
+void gl4_2core_glGetProgramPipelineInfoLog(void *_glfuncs, GLuint pipeline, GLsizei bufSize, GLsizei* length, GLchar* infoLog)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetProgramPipelineInfoLog(pipeline, bufSize, length, infoLog);
+}
+
+void gl4_2core_glValidateProgramPipeline(void *_glfuncs, GLuint pipeline)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glValidateProgramPipeline(pipeline);
+}
+
+void gl4_2core_glProgramUniformMatrix4x3dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix4x3dv(program, location, count, transpose, value);
+}
+
+void gl4_2core_glProgramUniformMatrix3x4dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix3x4dv(program, location, count, transpose, value);
+}
+
+void gl4_2core_glProgramUniformMatrix4x2dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix4x2dv(program, location, count, transpose, value);
+}
+
+void gl4_2core_glProgramUniformMatrix2x4dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix2x4dv(program, location, count, transpose, value);
+}
+
+void gl4_2core_glProgramUniformMatrix3x2dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix3x2dv(program, location, count, transpose, value);
+}
+
+void gl4_2core_glProgramUniformMatrix2x3dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix2x3dv(program, location, count, transpose, value);
+}
+
+void gl4_2core_glProgramUniformMatrix4x3fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix4x3fv(program, location, count, transpose, value);
+}
+
+void gl4_2core_glProgramUniformMatrix3x4fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix3x4fv(program, location, count, transpose, value);
+}
+
+void gl4_2core_glProgramUniformMatrix4x2fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix4x2fv(program, location, count, transpose, value);
+}
+
+void gl4_2core_glProgramUniformMatrix2x4fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix2x4fv(program, location, count, transpose, value);
+}
+
+void gl4_2core_glProgramUniformMatrix3x2fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix3x2fv(program, location, count, transpose, value);
+}
+
+void gl4_2core_glProgramUniformMatrix2x3fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix2x3fv(program, location, count, transpose, value);
+}
+
+void gl4_2core_glProgramUniformMatrix4dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix4dv(program, location, count, transpose, value);
+}
+
+void gl4_2core_glProgramUniformMatrix3dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix3dv(program, location, count, transpose, value);
+}
+
+void gl4_2core_glProgramUniformMatrix2dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix2dv(program, location, count, transpose, value);
+}
+
+void gl4_2core_glProgramUniformMatrix4fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix4fv(program, location, count, transpose, value);
+}
+
+void gl4_2core_glProgramUniformMatrix3fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix3fv(program, location, count, transpose, value);
+}
+
+void gl4_2core_glProgramUniformMatrix2fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix2fv(program, location, count, transpose, value);
+}
+
+void gl4_2core_glProgramUniform4uiv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform4uiv(program, location, count, value);
+}
+
+void gl4_2core_glProgramUniform4ui(void *_glfuncs, GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform4ui(program, location, v0, v1, v2, v3);
+}
+
+void gl4_2core_glProgramUniform4dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLdouble* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform4dv(program, location, count, value);
+}
+
+void gl4_2core_glProgramUniform4d(void *_glfuncs, GLuint program, GLint location, GLdouble v0, GLdouble v1, GLdouble v2, GLdouble v3)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform4d(program, location, v0, v1, v2, v3);
+}
+
+void gl4_2core_glProgramUniform4fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform4fv(program, location, count, value);
+}
+
+void gl4_2core_glProgramUniform4f(void *_glfuncs, GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform4f(program, location, v0, v1, v2, v3);
+}
+
+void gl4_2core_glProgramUniform4iv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform4iv(program, location, count, value);
+}
+
+void gl4_2core_glProgramUniform4i(void *_glfuncs, GLuint program, GLint location, GLint v0, GLint v1, GLint v2, GLint v3)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform4i(program, location, v0, v1, v2, v3);
+}
+
+void gl4_2core_glProgramUniform3uiv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform3uiv(program, location, count, value);
+}
+
+void gl4_2core_glProgramUniform3ui(void *_glfuncs, GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform3ui(program, location, v0, v1, v2);
+}
+
+void gl4_2core_glProgramUniform3dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLdouble* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform3dv(program, location, count, value);
+}
+
+void gl4_2core_glProgramUniform3d(void *_glfuncs, GLuint program, GLint location, GLdouble v0, GLdouble v1, GLdouble v2)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform3d(program, location, v0, v1, v2);
+}
+
+void gl4_2core_glProgramUniform3fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform3fv(program, location, count, value);
+}
+
+void gl4_2core_glProgramUniform3f(void *_glfuncs, GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform3f(program, location, v0, v1, v2);
+}
+
+void gl4_2core_glProgramUniform3iv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform3iv(program, location, count, value);
+}
+
+void gl4_2core_glProgramUniform3i(void *_glfuncs, GLuint program, GLint location, GLint v0, GLint v1, GLint v2)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform3i(program, location, v0, v1, v2);
+}
+
+void gl4_2core_glProgramUniform2uiv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform2uiv(program, location, count, value);
+}
+
+void gl4_2core_glProgramUniform2ui(void *_glfuncs, GLuint program, GLint location, GLuint v0, GLuint v1)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform2ui(program, location, v0, v1);
+}
+
+void gl4_2core_glProgramUniform2dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLdouble* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform2dv(program, location, count, value);
+}
+
+void gl4_2core_glProgramUniform2d(void *_glfuncs, GLuint program, GLint location, GLdouble v0, GLdouble v1)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform2d(program, location, v0, v1);
+}
+
+void gl4_2core_glProgramUniform2fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform2fv(program, location, count, value);
+}
+
+void gl4_2core_glProgramUniform2f(void *_glfuncs, GLuint program, GLint location, GLfloat v0, GLfloat v1)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform2f(program, location, v0, v1);
+}
+
+void gl4_2core_glProgramUniform2iv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform2iv(program, location, count, value);
+}
+
+void gl4_2core_glProgramUniform2i(void *_glfuncs, GLuint program, GLint location, GLint v0, GLint v1)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform2i(program, location, v0, v1);
+}
+
+void gl4_2core_glProgramUniform1uiv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform1uiv(program, location, count, value);
+}
+
+void gl4_2core_glProgramUniform1ui(void *_glfuncs, GLuint program, GLint location, GLuint v0)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform1ui(program, location, v0);
+}
+
+void gl4_2core_glProgramUniform1dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLdouble* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform1dv(program, location, count, value);
+}
+
+void gl4_2core_glProgramUniform1d(void *_glfuncs, GLuint program, GLint location, GLdouble v0)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform1d(program, location, v0);
+}
+
+void gl4_2core_glProgramUniform1fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform1fv(program, location, count, value);
+}
+
+void gl4_2core_glProgramUniform1f(void *_glfuncs, GLuint program, GLint location, GLfloat v0)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform1f(program, location, v0);
+}
+
+void gl4_2core_glProgramUniform1iv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform1iv(program, location, count, value);
+}
+
+void gl4_2core_glProgramUniform1i(void *_glfuncs, GLuint program, GLint location, GLint v0)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform1i(program, location, v0);
+}
+
+void gl4_2core_glGetProgramPipelineiv(void *_glfuncs, GLuint pipeline, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetProgramPipelineiv(pipeline, pname, params);
+}
+
+GLboolean gl4_2core_glIsProgramPipeline(void *_glfuncs, GLuint pipeline)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ return _qglfuncs->glIsProgramPipeline(pipeline);
+}
+
+void gl4_2core_glGenProgramPipelines(void *_glfuncs, GLsizei n, GLuint* pipelines)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGenProgramPipelines(n, pipelines);
+}
+
+void gl4_2core_glDeleteProgramPipelines(void *_glfuncs, GLsizei n, const GLuint* pipelines)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glDeleteProgramPipelines(n, pipelines);
+}
+
+void gl4_2core_glBindProgramPipeline(void *_glfuncs, GLuint pipeline)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glBindProgramPipeline(pipeline);
+}
+
+void gl4_2core_glActiveShaderProgram(void *_glfuncs, GLuint pipeline, GLuint program)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glActiveShaderProgram(pipeline, program);
+}
+
+void gl4_2core_glUseProgramStages(void *_glfuncs, GLuint pipeline, GLbitfield stages, GLuint program)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glUseProgramStages(pipeline, stages, program);
+}
+
+void gl4_2core_glProgramParameteri(void *_glfuncs, GLuint program, GLenum pname, GLint value)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glProgramParameteri(program, pname, value);
+}
+
+void gl4_2core_glProgramBinary(void *_glfuncs, GLuint program, GLenum binaryFormat, const GLvoid* binary, GLsizei length)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glProgramBinary(program, binaryFormat, binary, length);
+}
+
+void gl4_2core_glGetProgramBinary(void *_glfuncs, GLuint program, GLsizei bufSize, GLsizei* length, GLenum* binaryFormat, GLvoid* binary)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetProgramBinary(program, bufSize, length, binaryFormat, binary);
+}
+
+void gl4_2core_glClearDepthf(void *_glfuncs, GLfloat dd)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glClearDepthf(dd);
+}
+
+void gl4_2core_glDepthRangef(void *_glfuncs, GLfloat n, GLfloat f)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glDepthRangef(n, f);
+}
+
+void gl4_2core_glGetShaderPrecisionFormat(void *_glfuncs, GLenum shadertype, GLenum precisionType, GLint* range_, GLint* precision)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetShaderPrecisionFormat(shadertype, precisionType, range_, precision);
+}
+
+void gl4_2core_glShaderBinary(void *_glfuncs, GLsizei count, const GLuint* shaders, GLenum binaryFormat, const GLvoid* binary, GLsizei length)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glShaderBinary(count, shaders, binaryFormat, binary, length);
+}
+
+void gl4_2core_glReleaseShaderCompiler(void *_glfuncs)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glReleaseShaderCompiler();
+}
+
+void gl4_2core_glTexStorage3D(void *_glfuncs, GLenum target, GLsizei levels, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glTexStorage3D(target, levels, internalFormat, width, height, depth);
+}
+
+void gl4_2core_glTexStorage2D(void *_glfuncs, GLenum target, GLsizei levels, GLenum internalFormat, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glTexStorage2D(target, levels, internalFormat, width, height);
+}
+
+void gl4_2core_glTexStorage1D(void *_glfuncs, GLenum target, GLsizei levels, GLenum internalFormat, GLsizei width)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glTexStorage1D(target, levels, internalFormat, width);
+}
+
+void gl4_2core_glMemoryBarrier(void *_glfuncs, GLbitfield barriers)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glMemoryBarrier(barriers);
+}
+
+void gl4_2core_glBindImageTexture(void *_glfuncs, GLuint unit, GLuint texture, GLint level, GLboolean layered, GLint layer, GLenum access, GLenum format)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glBindImageTexture(unit, texture, level, layered, layer, access, format);
+}
+
+void gl4_2core_glGetActiveAtomicCounterBufferiv(void *_glfuncs, GLuint program, GLuint bufferIndex, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetActiveAtomicCounterBufferiv(program, bufferIndex, pname, params);
+}
+
+void gl4_2core_glGetInternalformativ(void *_glfuncs, GLenum target, GLenum internalFormat, GLenum pname, GLsizei bufSize, GLint* params)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glGetInternalformativ(target, internalFormat, pname, bufSize, params);
+}
+
+void gl4_2core_glDrawTransformFeedbackStreamInstanced(void *_glfuncs, GLenum mode, GLuint id, GLuint stream, GLsizei instancecount)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glDrawTransformFeedbackStreamInstanced(mode, id, stream, instancecount);
+}
+
+void gl4_2core_glDrawTransformFeedbackInstanced(void *_glfuncs, GLenum mode, GLuint id, GLsizei instancecount)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glDrawTransformFeedbackInstanced(mode, id, instancecount);
+}
+
+void gl4_2core_glDrawElementsInstancedBaseVertexBaseInstance(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount, GLint basevertex, GLuint baseinstance)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glDrawElementsInstancedBaseVertexBaseInstance(mode, count, gltype, indices, instancecount, basevertex, baseinstance);
+}
+
+void gl4_2core_glDrawElementsInstancedBaseInstance(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount, GLuint baseinstance)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glDrawElementsInstancedBaseInstance(mode, count, gltype, indices, instancecount, baseinstance);
+}
+
+void gl4_2core_glDrawArraysInstancedBaseInstance(void *_glfuncs, GLenum mode, GLint first, GLsizei count, GLsizei instancecount, GLuint baseinstance)
+{
+ QOpenGLFunctions_4_2_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_2_Core*>(_glfuncs);
+ _qglfuncs->glDrawArraysInstancedBaseInstance(mode, first, count, instancecount, baseinstance);
+}
+
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.2core/funcs.h b/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.2core/funcs.h
new file mode 100644
index 000000000..969f03fdd
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.2core/funcs.h
@@ -0,0 +1,497 @@
+
+// ** file automatically generated by glgen -- do not edit manually **
+
+#ifndef __cplusplus
+#include <inttypes.h>
+#include <stddef.h>
+typedef unsigned int GLenum;
+typedef unsigned char GLboolean;
+typedef unsigned int GLbitfield;
+typedef void GLvoid;
+typedef char GLchar;
+typedef signed char GLbyte; /* 1-byte signed */
+typedef short GLshort; /* 2-byte signed */
+typedef int GLint; /* 4-byte signed */
+typedef unsigned char GLubyte; /* 1-byte unsigned */
+typedef unsigned short GLushort; /* 2-byte unsigned */
+typedef unsigned int GLuint; /* 4-byte unsigned */
+typedef int GLsizei; /* 4-byte signed */
+typedef float GLfloat; /* single precision float */
+typedef float GLclampf; /* single precision float in [0,1] */
+typedef double GLdouble; /* double precision float */
+typedef double GLclampd; /* double precision float in [0,1] */
+typedef int64_t GLint64;
+typedef uint64_t GLuint64;
+typedef ptrdiff_t GLintptr;
+typedef ptrdiff_t GLsizeiptr;
+typedef ptrdiff_t GLintptrARB;
+typedef ptrdiff_t GLsizeiptrARB;
+typedef struct __GLsync *GLsync;
+#endif
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+void *gl4_2core_funcs();
+
+void gl4_2core_glViewport(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl4_2core_glDepthRange(void *_glfuncs, GLdouble nearVal, GLdouble farVal);
+GLboolean gl4_2core_glIsEnabled(void *_glfuncs, GLenum cap);
+void gl4_2core_glGetTexLevelParameteriv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLint* params);
+void gl4_2core_glGetTexLevelParameterfv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLfloat* params);
+void gl4_2core_glGetTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl4_2core_glGetTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl4_2core_glGetTexImage(void *_glfuncs, GLenum target, GLint level, GLenum format, GLenum gltype, GLvoid* pixels);
+void gl4_2core_glGetIntegerv(void *_glfuncs, GLenum pname, GLint* params);
+void gl4_2core_glGetFloatv(void *_glfuncs, GLenum pname, GLfloat* params);
+GLenum gl4_2core_glGetError(void *_glfuncs);
+void gl4_2core_glGetDoublev(void *_glfuncs, GLenum pname, GLdouble* params);
+void gl4_2core_glGetBooleanv(void *_glfuncs, GLenum pname, GLboolean* params);
+void gl4_2core_glReadPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum gltype, GLvoid* pixels);
+void gl4_2core_glReadBuffer(void *_glfuncs, GLenum mode);
+void gl4_2core_glPixelStorei(void *_glfuncs, GLenum pname, GLint param);
+void gl4_2core_glPixelStoref(void *_glfuncs, GLenum pname, GLfloat param);
+void gl4_2core_glDepthFunc(void *_glfuncs, GLenum glfunc);
+void gl4_2core_glStencilOp(void *_glfuncs, GLenum fail, GLenum zfail, GLenum zpass);
+void gl4_2core_glStencilFunc(void *_glfuncs, GLenum glfunc, GLint ref, GLuint mask);
+void gl4_2core_glLogicOp(void *_glfuncs, GLenum opcode);
+void gl4_2core_glBlendFunc(void *_glfuncs, GLenum sfactor, GLenum dfactor);
+void gl4_2core_glFlush(void *_glfuncs);
+void gl4_2core_glFinish(void *_glfuncs);
+void gl4_2core_glEnable(void *_glfuncs, GLenum cap);
+void gl4_2core_glDisable(void *_glfuncs, GLenum cap);
+void gl4_2core_glDepthMask(void *_glfuncs, GLboolean flag);
+void gl4_2core_glColorMask(void *_glfuncs, GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha);
+void gl4_2core_glStencilMask(void *_glfuncs, GLuint mask);
+void gl4_2core_glClearDepth(void *_glfuncs, GLdouble depth);
+void gl4_2core_glClearStencil(void *_glfuncs, GLint s);
+void gl4_2core_glClearColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl4_2core_glClear(void *_glfuncs, GLbitfield mask);
+void gl4_2core_glDrawBuffer(void *_glfuncs, GLenum mode);
+void gl4_2core_glTexImage2D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl4_2core_glTexImage1D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl4_2core_glTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl4_2core_glTexParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint param);
+void gl4_2core_glTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl4_2core_glTexParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param);
+void gl4_2core_glScissor(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl4_2core_glPolygonMode(void *_glfuncs, GLenum face, GLenum mode);
+void gl4_2core_glPointSize(void *_glfuncs, GLfloat size);
+void gl4_2core_glLineWidth(void *_glfuncs, GLfloat width);
+void gl4_2core_glHint(void *_glfuncs, GLenum target, GLenum mode);
+void gl4_2core_glFrontFace(void *_glfuncs, GLenum mode);
+void gl4_2core_glCullFace(void *_glfuncs, GLenum mode);
+void gl4_2core_glIndexubv(void *_glfuncs, const GLubyte* c);
+void gl4_2core_glIndexub(void *_glfuncs, GLubyte c);
+GLboolean gl4_2core_glIsTexture(void *_glfuncs, GLuint texture);
+void gl4_2core_glGenTextures(void *_glfuncs, GLsizei n, GLuint* textures);
+void gl4_2core_glDeleteTextures(void *_glfuncs, GLsizei n, const GLuint* textures);
+void gl4_2core_glBindTexture(void *_glfuncs, GLenum target, GLuint texture);
+void gl4_2core_glTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl4_2core_glTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl4_2core_glCopyTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl4_2core_glCopyTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width);
+void gl4_2core_glCopyTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border);
+void gl4_2core_glCopyTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLint border);
+void gl4_2core_glPolygonOffset(void *_glfuncs, GLfloat factor, GLfloat units);
+void gl4_2core_glDrawElements(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices);
+void gl4_2core_glDrawArrays(void *_glfuncs, GLenum mode, GLint first, GLsizei count);
+void gl4_2core_glCopyTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl4_2core_glTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl4_2core_glTexImage3D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl4_2core_glDrawRangeElements(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices);
+void gl4_2core_glBlendEquation(void *_glfuncs, GLenum mode);
+void gl4_2core_glBlendColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl4_2core_glGetCompressedTexImage(void *_glfuncs, GLenum target, GLint level, GLvoid* img);
+void gl4_2core_glCompressedTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid* data);
+void gl4_2core_glCompressedTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid* data);
+void gl4_2core_glCompressedTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid* data);
+void gl4_2core_glCompressedTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid* data);
+void gl4_2core_glCompressedTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid* data);
+void gl4_2core_glCompressedTexImage3D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid* data);
+void gl4_2core_glSampleCoverage(void *_glfuncs, GLfloat value, GLboolean invert);
+void gl4_2core_glActiveTexture(void *_glfuncs, GLenum texture);
+void gl4_2core_glPointParameteriv(void *_glfuncs, GLenum pname, const GLint* params);
+void gl4_2core_glPointParameteri(void *_glfuncs, GLenum pname, GLint param);
+void gl4_2core_glPointParameterfv(void *_glfuncs, GLenum pname, const GLfloat* params);
+void gl4_2core_glPointParameterf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl4_2core_glMultiDrawArrays(void *_glfuncs, GLenum mode, const GLint* first, const GLsizei* count, GLsizei drawcount);
+void gl4_2core_glBlendFuncSeparate(void *_glfuncs, GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha);
+void gl4_2core_glGetBufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+GLboolean gl4_2core_glUnmapBuffer(void *_glfuncs, GLenum target);
+void gl4_2core_glGetBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, GLvoid* data);
+void gl4_2core_glBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid* data);
+void gl4_2core_glBufferData(void *_glfuncs, GLenum target, GLsizeiptr size, const GLvoid* data, GLenum usage);
+GLboolean gl4_2core_glIsBuffer(void *_glfuncs, GLuint buffer);
+void gl4_2core_glGenBuffers(void *_glfuncs, GLsizei n, GLuint* buffers);
+void gl4_2core_glDeleteBuffers(void *_glfuncs, GLsizei n, const GLuint* buffers);
+void gl4_2core_glBindBuffer(void *_glfuncs, GLenum target, GLuint buffer);
+void gl4_2core_glGetQueryObjectuiv(void *_glfuncs, GLuint id, GLenum pname, GLuint* params);
+void gl4_2core_glGetQueryObjectiv(void *_glfuncs, GLuint id, GLenum pname, GLint* params);
+void gl4_2core_glGetQueryiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl4_2core_glEndQuery(void *_glfuncs, GLenum target);
+void gl4_2core_glBeginQuery(void *_glfuncs, GLenum target, GLuint id);
+GLboolean gl4_2core_glIsQuery(void *_glfuncs, GLuint id);
+void gl4_2core_glDeleteQueries(void *_glfuncs, GLsizei n, const GLuint* ids);
+void gl4_2core_glGenQueries(void *_glfuncs, GLsizei n, GLuint* ids);
+void gl4_2core_glVertexAttribPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLboolean normalized, GLsizei stride, const GLvoid* offset);
+void gl4_2core_glValidateProgram(void *_glfuncs, GLuint program);
+void gl4_2core_glUniformMatrix4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_2core_glUniformMatrix3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_2core_glUniformMatrix2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_2core_glUniform4iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl4_2core_glUniform3iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl4_2core_glUniform2iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl4_2core_glUniform1iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl4_2core_glUniform4fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl4_2core_glUniform3fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl4_2core_glUniform2fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl4_2core_glUniform1fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl4_2core_glUniform4i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2, GLint v3);
+void gl4_2core_glUniform3i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2);
+void gl4_2core_glUniform2i(void *_glfuncs, GLint location, GLint v0, GLint v1);
+void gl4_2core_glUniform1i(void *_glfuncs, GLint location, GLint v0);
+void gl4_2core_glUniform4f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3);
+void gl4_2core_glUniform3f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2);
+void gl4_2core_glUniform2f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1);
+void gl4_2core_glUniform1f(void *_glfuncs, GLint location, GLfloat v0);
+void gl4_2core_glUseProgram(void *_glfuncs, GLuint program);
+void gl4_2core_glShaderSource(void *_glfuncs, GLuint shader, GLsizei count, const GLchar** source, const GLint* length);
+void gl4_2core_glLinkProgram(void *_glfuncs, GLuint program);
+GLboolean gl4_2core_glIsShader(void *_glfuncs, GLuint shader);
+GLboolean gl4_2core_glIsProgram(void *_glfuncs, GLuint program);
+void gl4_2core_glGetVertexAttribiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params);
+void gl4_2core_glGetVertexAttribfv(void *_glfuncs, GLuint index, GLenum pname, GLfloat* params);
+void gl4_2core_glGetVertexAttribdv(void *_glfuncs, GLuint index, GLenum pname, GLdouble* params);
+void gl4_2core_glGetUniformiv(void *_glfuncs, GLuint program, GLint location, GLint* params);
+void gl4_2core_glGetUniformfv(void *_glfuncs, GLuint program, GLint location, GLfloat* params);
+GLint gl4_2core_glGetUniformLocation(void *_glfuncs, GLuint program, const GLchar* name);
+void gl4_2core_glGetShaderSource(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* source);
+void gl4_2core_glGetShaderInfoLog(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* infoLog);
+void gl4_2core_glGetShaderiv(void *_glfuncs, GLuint shader, GLenum pname, GLint* params);
+void gl4_2core_glGetProgramInfoLog(void *_glfuncs, GLuint program, GLsizei bufSize, GLsizei* length, GLchar* infoLog);
+void gl4_2core_glGetProgramiv(void *_glfuncs, GLuint program, GLenum pname, GLint* params);
+GLint gl4_2core_glGetAttribLocation(void *_glfuncs, GLuint program, const GLchar* name);
+void gl4_2core_glGetAttachedShaders(void *_glfuncs, GLuint program, GLsizei maxCount, GLsizei* count, GLuint* obj);
+void gl4_2core_glGetActiveUniform(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name);
+void gl4_2core_glGetActiveAttrib(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name);
+void gl4_2core_glEnableVertexAttribArray(void *_glfuncs, GLuint index);
+void gl4_2core_glDisableVertexAttribArray(void *_glfuncs, GLuint index);
+void gl4_2core_glDetachShader(void *_glfuncs, GLuint program, GLuint shader);
+void gl4_2core_glDeleteShader(void *_glfuncs, GLuint shader);
+void gl4_2core_glDeleteProgram(void *_glfuncs, GLuint program);
+GLuint gl4_2core_glCreateShader(void *_glfuncs, GLenum gltype);
+GLuint gl4_2core_glCreateProgram(void *_glfuncs);
+void gl4_2core_glCompileShader(void *_glfuncs, GLuint shader);
+void gl4_2core_glBindAttribLocation(void *_glfuncs, GLuint program, GLuint index, const GLchar* name);
+void gl4_2core_glAttachShader(void *_glfuncs, GLuint program, GLuint shader);
+void gl4_2core_glStencilMaskSeparate(void *_glfuncs, GLenum face, GLuint mask);
+void gl4_2core_glStencilFuncSeparate(void *_glfuncs, GLenum face, GLenum glfunc, GLint ref, GLuint mask);
+void gl4_2core_glStencilOpSeparate(void *_glfuncs, GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass);
+void gl4_2core_glDrawBuffers(void *_glfuncs, GLsizei n, const GLenum* bufs);
+void gl4_2core_glBlendEquationSeparate(void *_glfuncs, GLenum modeRGB, GLenum modeAlpha);
+void gl4_2core_glUniformMatrix4x3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_2core_glUniformMatrix3x4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_2core_glUniformMatrix4x2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_2core_glUniformMatrix2x4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_2core_glUniformMatrix3x2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_2core_glUniformMatrix2x3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+GLboolean gl4_2core_glIsVertexArray(void *_glfuncs, GLuint array);
+void gl4_2core_glGenVertexArrays(void *_glfuncs, GLsizei n, GLuint* arrays);
+void gl4_2core_glDeleteVertexArrays(void *_glfuncs, GLsizei n, const GLuint* arrays);
+void gl4_2core_glBindVertexArray(void *_glfuncs, GLuint array);
+void gl4_2core_glFlushMappedBufferRange(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr length);
+void gl4_2core_glFramebufferTextureLayer(void *_glfuncs, GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer);
+void gl4_2core_glRenderbufferStorageMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLenum internalFormat, GLsizei width, GLsizei height);
+void gl4_2core_glBlitFramebuffer(void *_glfuncs, GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter);
+void gl4_2core_glGenerateMipmap(void *_glfuncs, GLenum target);
+void gl4_2core_glGetFramebufferAttachmentParameteriv(void *_glfuncs, GLenum target, GLenum attachment, GLenum pname, GLint* params);
+void gl4_2core_glFramebufferRenderbuffer(void *_glfuncs, GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer);
+void gl4_2core_glFramebufferTexture3D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset);
+void gl4_2core_glFramebufferTexture2D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+void gl4_2core_glFramebufferTexture1D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+GLenum gl4_2core_glCheckFramebufferStatus(void *_glfuncs, GLenum target);
+void gl4_2core_glGenFramebuffers(void *_glfuncs, GLsizei n, GLuint* framebuffers);
+void gl4_2core_glDeleteFramebuffers(void *_glfuncs, GLsizei n, const GLuint* framebuffers);
+void gl4_2core_glBindFramebuffer(void *_glfuncs, GLenum target, GLuint framebuffer);
+GLboolean gl4_2core_glIsFramebuffer(void *_glfuncs, GLuint framebuffer);
+void gl4_2core_glGetRenderbufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl4_2core_glRenderbufferStorage(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height);
+void gl4_2core_glGenRenderbuffers(void *_glfuncs, GLsizei n, GLuint* renderbuffers);
+void gl4_2core_glDeleteRenderbuffers(void *_glfuncs, GLsizei n, const GLuint* renderbuffers);
+void gl4_2core_glBindRenderbuffer(void *_glfuncs, GLenum target, GLuint renderbuffer);
+GLboolean gl4_2core_glIsRenderbuffer(void *_glfuncs, GLuint renderbuffer);
+void gl4_2core_glClearBufferfi(void *_glfuncs, GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil);
+void gl4_2core_glClearBufferfv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLfloat* value);
+void gl4_2core_glClearBufferuiv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLuint* value);
+void gl4_2core_glClearBufferiv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLint* value);
+void gl4_2core_glGetTexParameterIuiv(void *_glfuncs, GLenum target, GLenum pname, GLuint* params);
+void gl4_2core_glGetTexParameterIiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl4_2core_glTexParameterIuiv(void *_glfuncs, GLenum target, GLenum pname, const GLuint* params);
+void gl4_2core_glTexParameterIiv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl4_2core_glUniform4uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value);
+void gl4_2core_glUniform3uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value);
+void gl4_2core_glUniform2uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value);
+void gl4_2core_glUniform1uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value);
+void gl4_2core_glUniform4ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3);
+void gl4_2core_glUniform3ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1, GLuint v2);
+void gl4_2core_glUniform2ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1);
+void gl4_2core_glUniform1ui(void *_glfuncs, GLint location, GLuint v0);
+GLint gl4_2core_glGetFragDataLocation(void *_glfuncs, GLuint program, const GLchar* name);
+void gl4_2core_glBindFragDataLocation(void *_glfuncs, GLuint program, GLuint color, const GLchar* name);
+void gl4_2core_glGetUniformuiv(void *_glfuncs, GLuint program, GLint location, GLuint* params);
+void gl4_2core_glGetVertexAttribIuiv(void *_glfuncs, GLuint index, GLenum pname, GLuint* params);
+void gl4_2core_glGetVertexAttribIiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params);
+void gl4_2core_glVertexAttribIPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl4_2core_glEndConditionalRender(void *_glfuncs);
+void gl4_2core_glBeginConditionalRender(void *_glfuncs, GLuint id, GLenum mode);
+void gl4_2core_glClampColor(void *_glfuncs, GLenum target, GLenum clamp);
+void gl4_2core_glGetTransformFeedbackVarying(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLsizei* size, GLenum* gltype, GLchar* name);
+void gl4_2core_glBindBufferBase(void *_glfuncs, GLenum target, GLuint index, GLuint buffer);
+void gl4_2core_glBindBufferRange(void *_glfuncs, GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size);
+void gl4_2core_glEndTransformFeedback(void *_glfuncs);
+void gl4_2core_glBeginTransformFeedback(void *_glfuncs, GLenum primitiveMode);
+GLboolean gl4_2core_glIsEnabledi(void *_glfuncs, GLenum target, GLuint index);
+void gl4_2core_glDisablei(void *_glfuncs, GLenum target, GLuint index);
+void gl4_2core_glEnablei(void *_glfuncs, GLenum target, GLuint index);
+void gl4_2core_glGetIntegeri_v(void *_glfuncs, GLenum target, GLuint index, GLint* data);
+void gl4_2core_glGetBooleani_v(void *_glfuncs, GLenum target, GLuint index, GLboolean* data);
+void gl4_2core_glColorMaski(void *_glfuncs, GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a);
+void gl4_2core_glCopyBufferSubData(void *_glfuncs, GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size);
+void gl4_2core_glUniformBlockBinding(void *_glfuncs, GLuint program, GLuint v0, GLuint v1);
+void gl4_2core_glGetActiveUniformBlockName(void *_glfuncs, GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei* length, GLchar* uniformBlockName);
+void gl4_2core_glGetActiveUniformBlockiv(void *_glfuncs, GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint* params);
+GLuint gl4_2core_glGetUniformBlockIndex(void *_glfuncs, GLuint program, const GLchar* uniformBlockName);
+void gl4_2core_glGetActiveUniformName(void *_glfuncs, GLuint program, GLuint uniformIndex, GLsizei bufSize, GLsizei* length, GLchar* uniformName);
+void gl4_2core_glGetActiveUniformsiv(void *_glfuncs, GLuint program, GLsizei uniformCount, const GLuint* uniformIndices, GLenum pname, GLint* params);
+void gl4_2core_glPrimitiveRestartIndex(void *_glfuncs, GLuint index);
+void gl4_2core_glTexBuffer(void *_glfuncs, GLenum target, GLenum internalFormat, GLuint buffer);
+void gl4_2core_glDrawElementsInstanced(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount);
+void gl4_2core_glDrawArraysInstanced(void *_glfuncs, GLenum mode, GLint first, GLsizei count, GLsizei instancecount);
+void gl4_2core_glSampleMaski(void *_glfuncs, GLuint index, GLbitfield mask);
+void gl4_2core_glGetMultisamplefv(void *_glfuncs, GLenum pname, GLuint index, GLfloat* val);
+void gl4_2core_glTexImage3DMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations);
+void gl4_2core_glTexImage2DMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLint internalFormat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations);
+void gl4_2core_glGetSynciv(void *_glfuncs, GLsync sync, GLenum pname, GLsizei bufSize, GLsizei* length, GLint* values);
+void gl4_2core_glGetInteger64v(void *_glfuncs, GLenum pname, GLint64* params);
+void gl4_2core_glWaitSync(void *_glfuncs, GLsync sync, GLbitfield flags, GLuint64 timeout);
+GLenum gl4_2core_glClientWaitSync(void *_glfuncs, GLsync sync, GLbitfield flags, GLuint64 timeout);
+void gl4_2core_glDeleteSync(void *_glfuncs, GLsync sync);
+GLboolean gl4_2core_glIsSync(void *_glfuncs, GLsync sync);
+GLsync gl4_2core_glFenceSync(void *_glfuncs, GLenum condition, GLbitfield flags);
+void gl4_2core_glProvokingVertex(void *_glfuncs, GLenum mode);
+void gl4_2core_glDrawElementsInstancedBaseVertex(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount, GLint basevertex);
+void gl4_2core_glDrawRangeElementsBaseVertex(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices, GLint basevertex);
+void gl4_2core_glDrawElementsBaseVertex(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLint basevertex);
+void gl4_2core_glFramebufferTexture(void *_glfuncs, GLenum target, GLenum attachment, GLuint texture, GLint level);
+void gl4_2core_glGetBufferParameteri64v(void *_glfuncs, GLenum target, GLenum pname, GLint64* params);
+void gl4_2core_glGetInteger64i_v(void *_glfuncs, GLenum target, GLuint index, GLint64* data);
+void gl4_2core_glVertexAttribP4uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value);
+void gl4_2core_glVertexAttribP4ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value);
+void gl4_2core_glVertexAttribP3uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value);
+void gl4_2core_glVertexAttribP3ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value);
+void gl4_2core_glVertexAttribP2uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value);
+void gl4_2core_glVertexAttribP2ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value);
+void gl4_2core_glVertexAttribP1uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value);
+void gl4_2core_glVertexAttribP1ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value);
+void gl4_2core_glSecondaryColorP3uiv(void *_glfuncs, GLenum gltype, const GLuint* color);
+void gl4_2core_glSecondaryColorP3ui(void *_glfuncs, GLenum gltype, GLuint color);
+void gl4_2core_glColorP4uiv(void *_glfuncs, GLenum gltype, const GLuint* color);
+void gl4_2core_glColorP4ui(void *_glfuncs, GLenum gltype, GLuint color);
+void gl4_2core_glColorP3uiv(void *_glfuncs, GLenum gltype, const GLuint* color);
+void gl4_2core_glColorP3ui(void *_glfuncs, GLenum gltype, GLuint color);
+void gl4_2core_glNormalP3uiv(void *_glfuncs, GLenum gltype, const GLuint* coords);
+void gl4_2core_glNormalP3ui(void *_glfuncs, GLenum gltype, GLuint coords);
+void gl4_2core_glMultiTexCoordP4uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords);
+void gl4_2core_glMultiTexCoordP4ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords);
+void gl4_2core_glMultiTexCoordP3uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords);
+void gl4_2core_glMultiTexCoordP3ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords);
+void gl4_2core_glMultiTexCoordP2uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords);
+void gl4_2core_glMultiTexCoordP2ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords);
+void gl4_2core_glMultiTexCoordP1uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords);
+void gl4_2core_glMultiTexCoordP1ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords);
+void gl4_2core_glTexCoordP4uiv(void *_glfuncs, GLenum gltype, const GLuint* coords);
+void gl4_2core_glTexCoordP4ui(void *_glfuncs, GLenum gltype, GLuint coords);
+void gl4_2core_glTexCoordP3uiv(void *_glfuncs, GLenum gltype, const GLuint* coords);
+void gl4_2core_glTexCoordP3ui(void *_glfuncs, GLenum gltype, GLuint coords);
+void gl4_2core_glTexCoordP2uiv(void *_glfuncs, GLenum gltype, const GLuint* coords);
+void gl4_2core_glTexCoordP2ui(void *_glfuncs, GLenum gltype, GLuint coords);
+void gl4_2core_glTexCoordP1uiv(void *_glfuncs, GLenum gltype, const GLuint* coords);
+void gl4_2core_glTexCoordP1ui(void *_glfuncs, GLenum gltype, GLuint coords);
+void gl4_2core_glVertexP4uiv(void *_glfuncs, GLenum gltype, const GLuint* value);
+void gl4_2core_glVertexP4ui(void *_glfuncs, GLenum gltype, GLuint value);
+void gl4_2core_glVertexP3uiv(void *_glfuncs, GLenum gltype, const GLuint* value);
+void gl4_2core_glVertexP3ui(void *_glfuncs, GLenum gltype, GLuint value);
+void gl4_2core_glVertexP2uiv(void *_glfuncs, GLenum gltype, const GLuint* value);
+void gl4_2core_glVertexP2ui(void *_glfuncs, GLenum gltype, GLuint value);
+void gl4_2core_glGetQueryObjectui64v(void *_glfuncs, GLuint id, GLenum pname, GLuint64* params);
+void gl4_2core_glGetQueryObjecti64v(void *_glfuncs, GLuint id, GLenum pname, GLint64* params);
+void gl4_2core_glQueryCounter(void *_glfuncs, GLuint id, GLenum target);
+void gl4_2core_glGetSamplerParameterIuiv(void *_glfuncs, GLuint sampler, GLenum pname, GLuint* params);
+void gl4_2core_glGetSamplerParameterfv(void *_glfuncs, GLuint sampler, GLenum pname, GLfloat* params);
+void gl4_2core_glGetSamplerParameterIiv(void *_glfuncs, GLuint sampler, GLenum pname, GLint* params);
+void gl4_2core_glGetSamplerParameteriv(void *_glfuncs, GLuint sampler, GLenum pname, GLint* params);
+void gl4_2core_glSamplerParameterIuiv(void *_glfuncs, GLuint sampler, GLenum pname, const GLuint* param);
+void gl4_2core_glSamplerParameterIiv(void *_glfuncs, GLuint sampler, GLenum pname, const GLint* param);
+void gl4_2core_glSamplerParameterfv(void *_glfuncs, GLuint sampler, GLenum pname, const GLfloat* param);
+void gl4_2core_glSamplerParameterf(void *_glfuncs, GLuint sampler, GLenum pname, GLfloat param);
+void gl4_2core_glSamplerParameteriv(void *_glfuncs, GLuint sampler, GLenum pname, const GLint* param);
+void gl4_2core_glSamplerParameteri(void *_glfuncs, GLuint sampler, GLenum pname, GLint param);
+void gl4_2core_glBindSampler(void *_glfuncs, GLuint unit, GLuint sampler);
+GLboolean gl4_2core_glIsSampler(void *_glfuncs, GLuint sampler);
+void gl4_2core_glDeleteSamplers(void *_glfuncs, GLsizei count, const GLuint* samplers);
+void gl4_2core_glGenSamplers(void *_glfuncs, GLsizei count, GLuint* samplers);
+GLint gl4_2core_glGetFragDataIndex(void *_glfuncs, GLuint program, const GLchar* name);
+void gl4_2core_glBindFragDataLocationIndexed(void *_glfuncs, GLuint program, GLuint colorNumber, GLuint index, const GLchar* name);
+void gl4_2core_glVertexAttribDivisor(void *_glfuncs, GLuint index, GLuint divisor);
+void gl4_2core_glGetQueryIndexediv(void *_glfuncs, GLenum target, GLuint index, GLenum pname, GLint* params);
+void gl4_2core_glEndQueryIndexed(void *_glfuncs, GLenum target, GLuint index);
+void gl4_2core_glBeginQueryIndexed(void *_glfuncs, GLenum target, GLuint index, GLuint id);
+void gl4_2core_glDrawTransformFeedbackStream(void *_glfuncs, GLenum mode, GLuint id, GLuint stream);
+void gl4_2core_glDrawTransformFeedback(void *_glfuncs, GLenum mode, GLuint id);
+void gl4_2core_glResumeTransformFeedback(void *_glfuncs);
+void gl4_2core_glPauseTransformFeedback(void *_glfuncs);
+GLboolean gl4_2core_glIsTransformFeedback(void *_glfuncs, GLuint id);
+void gl4_2core_glGenTransformFeedbacks(void *_glfuncs, GLsizei n, GLuint* ids);
+void gl4_2core_glDeleteTransformFeedbacks(void *_glfuncs, GLsizei n, const GLuint* ids);
+void gl4_2core_glBindTransformFeedback(void *_glfuncs, GLenum target, GLuint id);
+void gl4_2core_glPatchParameterfv(void *_glfuncs, GLenum pname, const GLfloat* values);
+void gl4_2core_glPatchParameteri(void *_glfuncs, GLenum pname, GLint value);
+void gl4_2core_glGetProgramStageiv(void *_glfuncs, GLuint program, GLenum shadertype, GLenum pname, GLint* values);
+void gl4_2core_glGetUniformSubroutineuiv(void *_glfuncs, GLenum shadertype, GLint location, GLuint* params);
+void gl4_2core_glUniformSubroutinesuiv(void *_glfuncs, GLenum shadertype, GLsizei count, const GLuint* value);
+void gl4_2core_glGetActiveSubroutineName(void *_glfuncs, GLuint program, GLenum shadertype, GLuint index, GLsizei bufSize, GLsizei* length, GLchar* name);
+void gl4_2core_glGetActiveSubroutineUniformName(void *_glfuncs, GLuint program, GLenum shadertype, GLuint index, GLsizei bufSize, GLsizei* length, GLchar* name);
+void gl4_2core_glGetActiveSubroutineUniformiv(void *_glfuncs, GLuint program, GLenum shadertype, GLuint index, GLenum pname, GLint* values);
+GLuint gl4_2core_glGetSubroutineIndex(void *_glfuncs, GLuint program, GLenum shadertype, const GLchar* name);
+GLint gl4_2core_glGetSubroutineUniformLocation(void *_glfuncs, GLuint program, GLenum shadertype, const GLchar* name);
+void gl4_2core_glGetUniformdv(void *_glfuncs, GLuint program, GLint location, GLdouble* params);
+void gl4_2core_glUniformMatrix4x3dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_2core_glUniformMatrix4x2dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_2core_glUniformMatrix3x4dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_2core_glUniformMatrix3x2dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_2core_glUniformMatrix2x4dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_2core_glUniformMatrix2x3dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_2core_glUniformMatrix4dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_2core_glUniformMatrix3dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_2core_glUniformMatrix2dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_2core_glUniform4dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value);
+void gl4_2core_glUniform3dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value);
+void gl4_2core_glUniform2dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value);
+void gl4_2core_glUniform1dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value);
+void gl4_2core_glUniform4d(void *_glfuncs, GLint location, GLdouble v0, GLdouble v1, GLdouble v2, GLdouble v3);
+void gl4_2core_glUniform3d(void *_glfuncs, GLint location, GLdouble v0, GLdouble v1, GLdouble v2);
+void gl4_2core_glUniform2d(void *_glfuncs, GLint location, GLdouble v0, GLdouble v1);
+void gl4_2core_glUniform1d(void *_glfuncs, GLint location, GLdouble v0);
+void gl4_2core_glDrawElementsIndirect(void *_glfuncs, GLenum mode, GLenum gltype, const GLvoid* indirect);
+void gl4_2core_glDrawArraysIndirect(void *_glfuncs, GLenum mode, const GLvoid* indirect);
+void gl4_2core_glBlendFuncSeparatei(void *_glfuncs, GLuint buf, GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha, GLenum dstAlpha);
+void gl4_2core_glBlendFunci(void *_glfuncs, GLuint buf, GLenum src, GLenum dst);
+void gl4_2core_glBlendEquationSeparatei(void *_glfuncs, GLuint buf, GLenum modeRGB, GLenum modeAlpha);
+void gl4_2core_glBlendEquationi(void *_glfuncs, GLuint buf, GLenum mode);
+void gl4_2core_glMinSampleShading(void *_glfuncs, GLfloat value);
+void gl4_2core_glGetDoublei_v(void *_glfuncs, GLenum target, GLuint index, GLdouble* data);
+void gl4_2core_glGetFloati_v(void *_glfuncs, GLenum target, GLuint index, GLfloat* data);
+void gl4_2core_glDepthRangeIndexed(void *_glfuncs, GLuint index, GLdouble n, GLdouble f);
+void gl4_2core_glDepthRangeArrayv(void *_glfuncs, GLuint first, GLsizei count, const GLdouble* v);
+void gl4_2core_glScissorIndexedv(void *_glfuncs, GLuint index, const GLint* v);
+void gl4_2core_glScissorIndexed(void *_glfuncs, GLuint index, GLint left, GLint bottom, GLsizei width, GLsizei height);
+void gl4_2core_glScissorArrayv(void *_glfuncs, GLuint first, GLsizei count, const GLint* v);
+void gl4_2core_glViewportIndexedfv(void *_glfuncs, GLuint index, const GLfloat* v);
+void gl4_2core_glViewportIndexedf(void *_glfuncs, GLuint index, GLfloat x, GLfloat y, GLfloat w, GLfloat h);
+void gl4_2core_glViewportArrayv(void *_glfuncs, GLuint first, GLsizei count, const GLfloat* v);
+void gl4_2core_glGetVertexAttribLdv(void *_glfuncs, GLuint index, GLenum pname, GLdouble* params);
+void gl4_2core_glVertexAttribLPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl4_2core_glVertexAttribL4dv(void *_glfuncs, GLuint index, const GLdouble* v);
+void gl4_2core_glVertexAttribL3dv(void *_glfuncs, GLuint index, const GLdouble* v);
+void gl4_2core_glVertexAttribL2dv(void *_glfuncs, GLuint index, const GLdouble* v);
+void gl4_2core_glVertexAttribL1dv(void *_glfuncs, GLuint index, const GLdouble* v);
+void gl4_2core_glVertexAttribL4d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+void gl4_2core_glVertexAttribL3d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y, GLdouble z);
+void gl4_2core_glVertexAttribL2d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y);
+void gl4_2core_glVertexAttribL1d(void *_glfuncs, GLuint index, GLdouble x);
+void gl4_2core_glGetProgramPipelineInfoLog(void *_glfuncs, GLuint pipeline, GLsizei bufSize, GLsizei* length, GLchar* infoLog);
+void gl4_2core_glValidateProgramPipeline(void *_glfuncs, GLuint pipeline);
+void gl4_2core_glProgramUniformMatrix4x3dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_2core_glProgramUniformMatrix3x4dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_2core_glProgramUniformMatrix4x2dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_2core_glProgramUniformMatrix2x4dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_2core_glProgramUniformMatrix3x2dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_2core_glProgramUniformMatrix2x3dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_2core_glProgramUniformMatrix4x3fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_2core_glProgramUniformMatrix3x4fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_2core_glProgramUniformMatrix4x2fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_2core_glProgramUniformMatrix2x4fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_2core_glProgramUniformMatrix3x2fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_2core_glProgramUniformMatrix2x3fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_2core_glProgramUniformMatrix4dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_2core_glProgramUniformMatrix3dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_2core_glProgramUniformMatrix2dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_2core_glProgramUniformMatrix4fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_2core_glProgramUniformMatrix3fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_2core_glProgramUniformMatrix2fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_2core_glProgramUniform4uiv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLuint* value);
+void gl4_2core_glProgramUniform4ui(void *_glfuncs, GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3);
+void gl4_2core_glProgramUniform4dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLdouble* value);
+void gl4_2core_glProgramUniform4d(void *_glfuncs, GLuint program, GLint location, GLdouble v0, GLdouble v1, GLdouble v2, GLdouble v3);
+void gl4_2core_glProgramUniform4fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLfloat* value);
+void gl4_2core_glProgramUniform4f(void *_glfuncs, GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3);
+void gl4_2core_glProgramUniform4iv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLint* value);
+void gl4_2core_glProgramUniform4i(void *_glfuncs, GLuint program, GLint location, GLint v0, GLint v1, GLint v2, GLint v3);
+void gl4_2core_glProgramUniform3uiv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLuint* value);
+void gl4_2core_glProgramUniform3ui(void *_glfuncs, GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2);
+void gl4_2core_glProgramUniform3dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLdouble* value);
+void gl4_2core_glProgramUniform3d(void *_glfuncs, GLuint program, GLint location, GLdouble v0, GLdouble v1, GLdouble v2);
+void gl4_2core_glProgramUniform3fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLfloat* value);
+void gl4_2core_glProgramUniform3f(void *_glfuncs, GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2);
+void gl4_2core_glProgramUniform3iv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLint* value);
+void gl4_2core_glProgramUniform3i(void *_glfuncs, GLuint program, GLint location, GLint v0, GLint v1, GLint v2);
+void gl4_2core_glProgramUniform2uiv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLuint* value);
+void gl4_2core_glProgramUniform2ui(void *_glfuncs, GLuint program, GLint location, GLuint v0, GLuint v1);
+void gl4_2core_glProgramUniform2dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLdouble* value);
+void gl4_2core_glProgramUniform2d(void *_glfuncs, GLuint program, GLint location, GLdouble v0, GLdouble v1);
+void gl4_2core_glProgramUniform2fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLfloat* value);
+void gl4_2core_glProgramUniform2f(void *_glfuncs, GLuint program, GLint location, GLfloat v0, GLfloat v1);
+void gl4_2core_glProgramUniform2iv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLint* value);
+void gl4_2core_glProgramUniform2i(void *_glfuncs, GLuint program, GLint location, GLint v0, GLint v1);
+void gl4_2core_glProgramUniform1uiv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLuint* value);
+void gl4_2core_glProgramUniform1ui(void *_glfuncs, GLuint program, GLint location, GLuint v0);
+void gl4_2core_glProgramUniform1dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLdouble* value);
+void gl4_2core_glProgramUniform1d(void *_glfuncs, GLuint program, GLint location, GLdouble v0);
+void gl4_2core_glProgramUniform1fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLfloat* value);
+void gl4_2core_glProgramUniform1f(void *_glfuncs, GLuint program, GLint location, GLfloat v0);
+void gl4_2core_glProgramUniform1iv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLint* value);
+void gl4_2core_glProgramUniform1i(void *_glfuncs, GLuint program, GLint location, GLint v0);
+void gl4_2core_glGetProgramPipelineiv(void *_glfuncs, GLuint pipeline, GLenum pname, GLint* params);
+GLboolean gl4_2core_glIsProgramPipeline(void *_glfuncs, GLuint pipeline);
+void gl4_2core_glGenProgramPipelines(void *_glfuncs, GLsizei n, GLuint* pipelines);
+void gl4_2core_glDeleteProgramPipelines(void *_glfuncs, GLsizei n, const GLuint* pipelines);
+void gl4_2core_glBindProgramPipeline(void *_glfuncs, GLuint pipeline);
+void gl4_2core_glActiveShaderProgram(void *_glfuncs, GLuint pipeline, GLuint program);
+void gl4_2core_glUseProgramStages(void *_glfuncs, GLuint pipeline, GLbitfield stages, GLuint program);
+void gl4_2core_glProgramParameteri(void *_glfuncs, GLuint program, GLenum pname, GLint value);
+void gl4_2core_glProgramBinary(void *_glfuncs, GLuint program, GLenum binaryFormat, const GLvoid* binary, GLsizei length);
+void gl4_2core_glGetProgramBinary(void *_glfuncs, GLuint program, GLsizei bufSize, GLsizei* length, GLenum* binaryFormat, GLvoid* binary);
+void gl4_2core_glClearDepthf(void *_glfuncs, GLfloat dd);
+void gl4_2core_glDepthRangef(void *_glfuncs, GLfloat n, GLfloat f);
+void gl4_2core_glGetShaderPrecisionFormat(void *_glfuncs, GLenum shadertype, GLenum precisionType, GLint* range_, GLint* precision);
+void gl4_2core_glShaderBinary(void *_glfuncs, GLsizei count, const GLuint* shaders, GLenum binaryFormat, const GLvoid* binary, GLsizei length);
+void gl4_2core_glReleaseShaderCompiler(void *_glfuncs);
+void gl4_2core_glTexStorage3D(void *_glfuncs, GLenum target, GLsizei levels, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth);
+void gl4_2core_glTexStorage2D(void *_glfuncs, GLenum target, GLsizei levels, GLenum internalFormat, GLsizei width, GLsizei height);
+void gl4_2core_glTexStorage1D(void *_glfuncs, GLenum target, GLsizei levels, GLenum internalFormat, GLsizei width);
+void gl4_2core_glMemoryBarrier(void *_glfuncs, GLbitfield barriers);
+void gl4_2core_glBindImageTexture(void *_glfuncs, GLuint unit, GLuint texture, GLint level, GLboolean layered, GLint layer, GLenum access, GLenum format);
+void gl4_2core_glGetActiveAtomicCounterBufferiv(void *_glfuncs, GLuint program, GLuint bufferIndex, GLenum pname, GLint* params);
+void gl4_2core_glGetInternalformativ(void *_glfuncs, GLenum target, GLenum internalFormat, GLenum pname, GLsizei bufSize, GLint* params);
+void gl4_2core_glDrawTransformFeedbackStreamInstanced(void *_glfuncs, GLenum mode, GLuint id, GLuint stream, GLsizei instancecount);
+void gl4_2core_glDrawTransformFeedbackInstanced(void *_glfuncs, GLenum mode, GLuint id, GLsizei instancecount);
+void gl4_2core_glDrawElementsInstancedBaseVertexBaseInstance(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount, GLint basevertex, GLuint baseinstance);
+void gl4_2core_glDrawElementsInstancedBaseInstance(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount, GLuint baseinstance);
+void gl4_2core_glDrawArraysInstancedBaseInstance(void *_glfuncs, GLenum mode, GLint first, GLsizei count, GLsizei instancecount, GLuint baseinstance);
+
+
+#ifdef __cplusplus
+} // extern "C"
+#endif
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.2core/gl.go b/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.2core/gl.go
new file mode 100644
index 000000000..a452b7296
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.2core/gl.go
@@ -0,0 +1,6594 @@
+// ** file automatically generated by glgen -- do not edit manually **
+
+package GL
+
+// #cgo CXXFLAGS: -std=c++0x -pedantic-errors -Wall -fno-strict-aliasing
+// #cgo LDFLAGS: -lstdc++
+// #cgo pkg-config: Qt5Core Qt5OpenGL
+//
+// #include "funcs.h"
+//
+// void free(void*);
+//
+import "C"
+
+import (
+ "fmt"
+ "reflect"
+ "unsafe"
+
+ "gopkg.in/qml.v1/gl/glbase"
+)
+
+// API returns a value that offers methods matching the OpenGL version 4.2 API.
+//
+// The returned API must not be used after the provided OpenGL context becomes invalid.
+func API(context glbase.Contexter) *GL {
+ gl := &GL{}
+ gl.funcs = C.gl4_2core_funcs()
+ if gl.funcs == nil {
+ panic(fmt.Errorf("OpenGL version 4.2 is not available"))
+ }
+ return gl
+}
+
+// GL implements the OpenGL version 4.2 API. Values of this
+// type must be created via the API function, and it must not be used after
+// the associated OpenGL context becomes invalid.
+type GL struct {
+ funcs unsafe.Pointer
+}
+
+const (
+ FALSE = 0
+ TRUE = 1
+ NONE = 0
+
+ BYTE = 0x1400
+ UNSIGNED_BYTE = 0x1401
+ SHORT = 0x1402
+ UNSIGNED_SHORT = 0x1403
+ INT = 0x1404
+ UNSIGNED_INT = 0x1405
+ FLOAT = 0x1406
+ N2_BYTES = 0x1407
+ N3_BYTES = 0x1408
+ N4_BYTES = 0x1409
+ DOUBLE = 0x140A
+ HALF_FLOAT = 0x140B
+ FIXED = 0x140C
+
+ ACCUM = 0x0100
+ LOAD = 0x0101
+ RETURN = 0x0102
+ MULT = 0x0103
+ ADD = 0x0104
+
+ ACCUM_BUFFER_BIT = 0x00000200
+ ALL_ATTRIB_BITS = 0xFFFFFFFF
+ COLOR_BUFFER_BIT = 0x00004000
+ CURRENT_BIT = 0x00000001
+ DEPTH_BUFFER_BIT = 0x00000100
+ ENABLE_BIT = 0x00002000
+ EVAL_BIT = 0x00010000
+ FOG_BIT = 0x00000080
+ HINT_BIT = 0x00008000
+ LIGHTING_BIT = 0x00000040
+ LINE_BIT = 0x00000004
+ LIST_BIT = 0x00020000
+ MULTISAMPLE_BIT = 0x20000000
+ PIXEL_MODE_BIT = 0x00000020
+ POINT_BIT = 0x00000002
+ POLYGON_BIT = 0x00000008
+ POLYGON_STIPPLE_BIT = 0x00000010
+ SCISSOR_BIT = 0x00080000
+ STENCIL_BUFFER_BIT = 0x00000400
+ TEXTURE_BIT = 0x00040000
+ TRANSFORM_BIT = 0x00001000
+ VIEWPORT_BIT = 0x00000800
+
+ ALWAYS = 0x0207
+ EQUAL = 0x0202
+ GEQUAL = 0x0206
+ GREATER = 0x0204
+ LEQUAL = 0x0203
+ LESS = 0x0201
+ NEVER = 0x0200
+ NOTEQUAL = 0x0205
+
+ LOGIC_OP = 0x0BF1
+
+ DST_ALPHA = 0x0304
+ ONE = 1
+ ONE_MINUS_DST_ALPHA = 0x0305
+ ONE_MINUS_SRC_ALPHA = 0x0303
+ ONE_MINUS_SRC_COLOR = 0x0301
+ SRC_ALPHA = 0x0302
+ SRC_COLOR = 0x0300
+ ZERO = 0
+
+ DST_COLOR = 0x0306
+ ONE_MINUS_DST_COLOR = 0x0307
+ SRC_ALPHA_SATURATE = 0x0308
+
+ CLIENT_ALL_ATTRIB_BITS = 0xFFFFFFFF
+ CLIENT_PIXEL_STORE_BIT = 0x00000001
+ CLIENT_VERTEX_ARRAY_BIT = 0x00000002
+
+ CLIP_DISTANCE0 = 0x3000
+ CLIP_DISTANCE1 = 0x3001
+ CLIP_DISTANCE2 = 0x3002
+ CLIP_DISTANCE3 = 0x3003
+ CLIP_DISTANCE4 = 0x3004
+ CLIP_DISTANCE5 = 0x3005
+ CLIP_DISTANCE6 = 0x3006
+ CLIP_DISTANCE7 = 0x3007
+ CLIP_PLANE0 = 0x3000
+ CLIP_PLANE1 = 0x3001
+ CLIP_PLANE2 = 0x3002
+ CLIP_PLANE3 = 0x3003
+ CLIP_PLANE4 = 0x3004
+ CLIP_PLANE5 = 0x3005
+
+ BACK = 0x0405
+ FRONT = 0x0404
+ FRONT_AND_BACK = 0x0408
+
+ AMBIENT = 0x1200
+ AMBIENT_AND_DIFFUSE = 0x1602
+ DIFFUSE = 0x1201
+ EMISSION = 0x1600
+ SPECULAR = 0x1202
+
+ CONTEXT_FLAG_FORWARD_COMPATIBLE_BIT = 0x00000001
+
+ CONTEXT_COMPATIBILITY_PROFILE_BIT = 0x00000002
+ CONTEXT_CORE_PROFILE_BIT = 0x00000001
+
+ AUX0 = 0x0409
+ AUX1 = 0x040A
+ AUX2 = 0x040B
+ AUX3 = 0x040C
+ BACK_LEFT = 0x0402
+ BACK_RIGHT = 0x0403
+ FRONT_LEFT = 0x0400
+ FRONT_RIGHT = 0x0401
+ LEFT = 0x0406
+ RIGHT = 0x0407
+
+ ALPHA_TEST = 0x0BC0
+ AUTO_NORMAL = 0x0D80
+ BLEND = 0x0BE2
+ COLOR_ARRAY = 0x8076
+ COLOR_LOGIC_OP = 0x0BF2
+ COLOR_MATERIAL = 0x0B57
+ CULL_FACE = 0x0B44
+ DEPTH_TEST = 0x0B71
+ DITHER = 0x0BD0
+ EDGE_FLAG_ARRAY = 0x8079
+ FOG = 0x0B60
+ INDEX_ARRAY = 0x8077
+ INDEX_LOGIC_OP = 0x0BF1
+ LIGHT0 = 0x4000
+ LIGHT1 = 0x4001
+ LIGHT2 = 0x4002
+ LIGHT3 = 0x4003
+ LIGHT4 = 0x4004
+ LIGHT5 = 0x4005
+ LIGHT6 = 0x4006
+ LIGHT7 = 0x4007
+ LIGHTING = 0x0B50
+ LINE_SMOOTH = 0x0B20
+ LINE_STIPPLE = 0x0B24
+ MAP1_COLOR_4 = 0x0D90
+ MAP1_INDEX = 0x0D91
+ MAP1_NORMAL = 0x0D92
+ MAP1_TEXTURE_COORD_1 = 0x0D93
+ MAP1_TEXTURE_COORD_2 = 0x0D94
+ MAP1_TEXTURE_COORD_3 = 0x0D95
+ MAP1_TEXTURE_COORD_4 = 0x0D96
+ MAP1_VERTEX_3 = 0x0D97
+ MAP1_VERTEX_4 = 0x0D98
+ MAP2_COLOR_4 = 0x0DB0
+ MAP2_INDEX = 0x0DB1
+ MAP2_NORMAL = 0x0DB2
+ MAP2_TEXTURE_COORD_1 = 0x0DB3
+ MAP2_TEXTURE_COORD_2 = 0x0DB4
+ MAP2_TEXTURE_COORD_3 = 0x0DB5
+ MAP2_TEXTURE_COORD_4 = 0x0DB6
+ MAP2_VERTEX_3 = 0x0DB7
+ MAP2_VERTEX_4 = 0x0DB8
+ NORMALIZE = 0x0BA1
+ NORMAL_ARRAY = 0x8075
+ POINT_SMOOTH = 0x0B10
+ POLYGON_OFFSET_FILL = 0x8037
+ POLYGON_OFFSET_LINE = 0x2A02
+ POLYGON_OFFSET_POINT = 0x2A01
+ POLYGON_SMOOTH = 0x0B41
+ POLYGON_STIPPLE = 0x0B42
+ SCISSOR_TEST = 0x0C11
+ STENCIL_TEST = 0x0B90
+ TEXTURE_1D = 0x0DE0
+ TEXTURE_2D = 0x0DE1
+ TEXTURE_COORD_ARRAY = 0x8078
+ TEXTURE_GEN_Q = 0x0C63
+ TEXTURE_GEN_R = 0x0C62
+ TEXTURE_GEN_S = 0x0C60
+ TEXTURE_GEN_T = 0x0C61
+ VERTEX_ARRAY = 0x8074
+
+ INVALID_ENUM = 0x0500
+ INVALID_FRAMEBUFFER_OPERATION = 0x0506
+ INVALID_OPERATION = 0x0502
+ INVALID_VALUE = 0x0501
+ NO_ERROR = 0
+ OUT_OF_MEMORY = 0x0505
+ STACK_OVERFLOW = 0x0503
+ STACK_UNDERFLOW = 0x0504
+
+ N2D = 0x0600
+ N3D = 0x0601
+ N3D_COLOR = 0x0602
+ N3D_COLOR_TEXTURE = 0x0603
+ N4D_COLOR_TEXTURE = 0x0604
+
+ BITMAP_TOKEN = 0x0704
+ COPY_PIXEL_TOKEN = 0x0706
+ DRAW_PIXEL_TOKEN = 0x0705
+ LINE_RESET_TOKEN = 0x0707
+ LINE_TOKEN = 0x0702
+ PASS_THROUGH_TOKEN = 0x0700
+ POINT_TOKEN = 0x0701
+ POLYGON_TOKEN = 0x0703
+
+ EXP = 0x0800
+ EXP2 = 0x0801
+ LINEAR = 0x2601
+
+ FOG_COLOR = 0x0B66
+ FOG_DENSITY = 0x0B62
+ FOG_END = 0x0B64
+ FOG_INDEX = 0x0B61
+ FOG_MODE = 0x0B65
+ FOG_START = 0x0B63
+
+ CCW = 0x0901
+ CW = 0x0900
+
+ COEFF = 0x0A00
+ DOMAIN = 0x0A02
+ ORDER = 0x0A01
+
+ PIXEL_MAP_A_TO_A = 0x0C79
+ PIXEL_MAP_B_TO_B = 0x0C78
+ PIXEL_MAP_G_TO_G = 0x0C77
+ PIXEL_MAP_I_TO_A = 0x0C75
+ PIXEL_MAP_I_TO_B = 0x0C74
+ PIXEL_MAP_I_TO_G = 0x0C73
+ PIXEL_MAP_I_TO_I = 0x0C70
+ PIXEL_MAP_I_TO_R = 0x0C72
+ PIXEL_MAP_R_TO_R = 0x0C76
+ PIXEL_MAP_S_TO_S = 0x0C71
+
+ ACCUM_ALPHA_BITS = 0x0D5B
+ ACCUM_BLUE_BITS = 0x0D5A
+ ACCUM_CLEAR_VALUE = 0x0B80
+ ACCUM_GREEN_BITS = 0x0D59
+ ACCUM_RED_BITS = 0x0D58
+ ALIASED_LINE_WIDTH_RANGE = 0x846E
+ ALIASED_POINT_SIZE_RANGE = 0x846D
+ ALPHA_BIAS = 0x0D1D
+ ALPHA_BITS = 0x0D55
+ ALPHA_SCALE = 0x0D1C
+ ALPHA_TEST_FUNC = 0x0BC1
+ ALPHA_TEST_REF = 0x0BC2
+ ATTRIB_STACK_DEPTH = 0x0BB0
+ AUX_BUFFERS = 0x0C00
+ BLEND_DST = 0x0BE0
+ BLEND_SRC = 0x0BE1
+ BLUE_BIAS = 0x0D1B
+ BLUE_BITS = 0x0D54
+ BLUE_SCALE = 0x0D1A
+ CLIENT_ATTRIB_STACK_DEPTH = 0x0BB1
+ COLOR_ARRAY_SIZE = 0x8081
+ COLOR_ARRAY_STRIDE = 0x8083
+ COLOR_ARRAY_TYPE = 0x8082
+ COLOR_CLEAR_VALUE = 0x0C22
+ COLOR_MATERIAL_FACE = 0x0B55
+ COLOR_MATERIAL_PARAMETER = 0x0B56
+ COLOR_WRITEMASK = 0x0C23
+ CULL_FACE_MODE = 0x0B45
+ CURRENT_COLOR = 0x0B00
+ CURRENT_INDEX = 0x0B01
+ CURRENT_NORMAL = 0x0B02
+ CURRENT_RASTER_COLOR = 0x0B04
+ CURRENT_RASTER_DISTANCE = 0x0B09
+ CURRENT_RASTER_INDEX = 0x0B05
+ CURRENT_RASTER_POSITION = 0x0B07
+ CURRENT_RASTER_POSITION_VALID = 0x0B08
+ CURRENT_RASTER_TEXTURE_COORDS = 0x0B06
+ CURRENT_TEXTURE_COORDS = 0x0B03
+ DEPTH_BIAS = 0x0D1F
+ DEPTH_BITS = 0x0D56
+ DEPTH_CLEAR_VALUE = 0x0B73
+ DEPTH_FUNC = 0x0B74
+ DEPTH_RANGE = 0x0B70
+ DEPTH_SCALE = 0x0D1E
+ DEPTH_WRITEMASK = 0x0B72
+ DOUBLEBUFFER = 0x0C32
+ DRAW_BUFFER = 0x0C01
+ EDGE_FLAG = 0x0B43
+ EDGE_FLAG_ARRAY_STRIDE = 0x808C
+ FEEDBACK_BUFFER_SIZE = 0x0DF1
+ FEEDBACK_BUFFER_TYPE = 0x0DF2
+ FOG_HINT = 0x0C54
+ FRONT_FACE = 0x0B46
+ GREEN_BIAS = 0x0D19
+ GREEN_BITS = 0x0D53
+ GREEN_SCALE = 0x0D18
+ INDEX_ARRAY_STRIDE = 0x8086
+ INDEX_ARRAY_TYPE = 0x8085
+ INDEX_BITS = 0x0D51
+ INDEX_CLEAR_VALUE = 0x0C20
+ INDEX_MODE = 0x0C30
+ INDEX_OFFSET = 0x0D13
+ INDEX_SHIFT = 0x0D12
+ INDEX_WRITEMASK = 0x0C21
+ LIGHT_MODEL_AMBIENT = 0x0B53
+ LIGHT_MODEL_COLOR_CONTROL = 0x81F8
+ LIGHT_MODEL_LOCAL_VIEWER = 0x0B51
+ LIGHT_MODEL_TWO_SIDE = 0x0B52
+ LINE_SMOOTH_HINT = 0x0C52
+ LINE_STIPPLE_PATTERN = 0x0B25
+ LINE_STIPPLE_REPEAT = 0x0B26
+ LINE_WIDTH = 0x0B21
+ LINE_WIDTH_GRANULARITY = 0x0B23
+ LINE_WIDTH_RANGE = 0x0B22
+ LIST_BASE = 0x0B32
+ LIST_INDEX = 0x0B33
+ LIST_MODE = 0x0B30
+ LOGIC_OP_MODE = 0x0BF0
+ MAP1_GRID_DOMAIN = 0x0DD0
+ MAP1_GRID_SEGMENTS = 0x0DD1
+ MAP2_GRID_DOMAIN = 0x0DD2
+ MAP2_GRID_SEGMENTS = 0x0DD3
+ MAP_COLOR = 0x0D10
+ MAP_STENCIL = 0x0D11
+ MATRIX_MODE = 0x0BA0
+ MAX_ATTRIB_STACK_DEPTH = 0x0D35
+ MAX_CLIENT_ATTRIB_STACK_DEPTH = 0x0D3B
+ MAX_CLIP_DISTANCES = 0x0D32
+ MAX_CLIP_PLANES = 0x0D32
+ MAX_EVAL_ORDER = 0x0D30
+ MAX_LIGHTS = 0x0D31
+ MAX_LIST_NESTING = 0x0B31
+ MAX_MODELVIEW_STACK_DEPTH = 0x0D36
+ MAX_NAME_STACK_DEPTH = 0x0D37
+ MAX_PIXEL_MAP_TABLE = 0x0D34
+ MAX_PROJECTION_STACK_DEPTH = 0x0D38
+ MAX_TEXTURE_SIZE = 0x0D33
+ MAX_TEXTURE_STACK_DEPTH = 0x0D39
+ MAX_VIEWPORT_DIMS = 0x0D3A
+ MODELVIEW_MATRIX = 0x0BA6
+ MODELVIEW_STACK_DEPTH = 0x0BA3
+ NAME_STACK_DEPTH = 0x0D70
+ NORMAL_ARRAY_STRIDE = 0x807F
+ NORMAL_ARRAY_TYPE = 0x807E
+ PACK_ALIGNMENT = 0x0D05
+ PACK_LSB_FIRST = 0x0D01
+ PACK_ROW_LENGTH = 0x0D02
+ PACK_SKIP_PIXELS = 0x0D04
+ PACK_SKIP_ROWS = 0x0D03
+ PACK_SWAP_BYTES = 0x0D00
+ PERSPECTIVE_CORRECTION_HINT = 0x0C50
+ PIXEL_MAP_A_TO_A_SIZE = 0x0CB9
+ PIXEL_MAP_B_TO_B_SIZE = 0x0CB8
+ PIXEL_MAP_G_TO_G_SIZE = 0x0CB7
+ PIXEL_MAP_I_TO_A_SIZE = 0x0CB5
+ PIXEL_MAP_I_TO_B_SIZE = 0x0CB4
+ PIXEL_MAP_I_TO_G_SIZE = 0x0CB3
+ PIXEL_MAP_I_TO_I_SIZE = 0x0CB0
+ PIXEL_MAP_I_TO_R_SIZE = 0x0CB2
+ PIXEL_MAP_R_TO_R_SIZE = 0x0CB6
+ PIXEL_MAP_S_TO_S_SIZE = 0x0CB1
+ POINT_SIZE = 0x0B11
+ POINT_SIZE_GRANULARITY = 0x0B13
+ POINT_SIZE_RANGE = 0x0B12
+ POINT_SMOOTH_HINT = 0x0C51
+ POLYGON_MODE = 0x0B40
+ POLYGON_OFFSET_FACTOR = 0x8038
+ POLYGON_OFFSET_UNITS = 0x2A00
+ POLYGON_SMOOTH_HINT = 0x0C53
+ PROJECTION_MATRIX = 0x0BA7
+ PROJECTION_STACK_DEPTH = 0x0BA4
+ READ_BUFFER = 0x0C02
+ RED_BIAS = 0x0D15
+ RED_BITS = 0x0D52
+ RED_SCALE = 0x0D14
+ RENDER_MODE = 0x0C40
+ RGBA_MODE = 0x0C31
+ SCISSOR_BOX = 0x0C10
+ SELECTION_BUFFER_SIZE = 0x0DF4
+ SHADE_MODEL = 0x0B54
+ SMOOTH_LINE_WIDTH_GRANULARITY = 0x0B23
+ SMOOTH_LINE_WIDTH_RANGE = 0x0B22
+ SMOOTH_POINT_SIZE_GRANULARITY = 0x0B13
+ SMOOTH_POINT_SIZE_RANGE = 0x0B12
+ STENCIL_BITS = 0x0D57
+ STENCIL_CLEAR_VALUE = 0x0B91
+ STENCIL_FAIL = 0x0B94
+ STENCIL_FUNC = 0x0B92
+ STENCIL_PASS_DEPTH_FAIL = 0x0B95
+ STENCIL_PASS_DEPTH_PASS = 0x0B96
+ STENCIL_REF = 0x0B97
+ STENCIL_VALUE_MASK = 0x0B93
+ STENCIL_WRITEMASK = 0x0B98
+ STEREO = 0x0C33
+ SUBPIXEL_BITS = 0x0D50
+ TEXTURE_BINDING_1D = 0x8068
+ TEXTURE_BINDING_2D = 0x8069
+ TEXTURE_BINDING_3D = 0x806A
+ TEXTURE_COORD_ARRAY_SIZE = 0x8088
+ TEXTURE_COORD_ARRAY_STRIDE = 0x808A
+ TEXTURE_COORD_ARRAY_TYPE = 0x8089
+ TEXTURE_MATRIX = 0x0BA8
+ TEXTURE_STACK_DEPTH = 0x0BA5
+ UNPACK_ALIGNMENT = 0x0CF5
+ UNPACK_LSB_FIRST = 0x0CF1
+ UNPACK_ROW_LENGTH = 0x0CF2
+ UNPACK_SKIP_PIXELS = 0x0CF4
+ UNPACK_SKIP_ROWS = 0x0CF3
+ UNPACK_SWAP_BYTES = 0x0CF0
+ VERTEX_ARRAY_SIZE = 0x807A
+ VERTEX_ARRAY_STRIDE = 0x807C
+ VERTEX_ARRAY_TYPE = 0x807B
+ VIEWPORT = 0x0BA2
+ ZOOM_X = 0x0D16
+ ZOOM_Y = 0x0D17
+
+ COLOR_ARRAY_POINTER = 0x8090
+ EDGE_FLAG_ARRAY_POINTER = 0x8093
+ FEEDBACK_BUFFER_POINTER = 0x0DF0
+ INDEX_ARRAY_POINTER = 0x8091
+ NORMAL_ARRAY_POINTER = 0x808F
+ SELECTION_BUFFER_POINTER = 0x0DF3
+ TEXTURE_COORD_ARRAY_POINTER = 0x8092
+ VERTEX_ARRAY_POINTER = 0x808E
+
+ TEXTURE_ALPHA_SIZE = 0x805F
+ TEXTURE_BLUE_SIZE = 0x805E
+ TEXTURE_BORDER = 0x1005
+ TEXTURE_BORDER_COLOR = 0x1004
+ TEXTURE_COMPONENTS = 0x1003
+ TEXTURE_GREEN_SIZE = 0x805D
+ TEXTURE_HEIGHT = 0x1001
+ TEXTURE_INTENSITY_SIZE = 0x8061
+ TEXTURE_INTERNAL_FORMAT = 0x1003
+ TEXTURE_LUMINANCE_SIZE = 0x8060
+ TEXTURE_MAG_FILTER = 0x2800
+ TEXTURE_MIN_FILTER = 0x2801
+ TEXTURE_PRIORITY = 0x8066
+ TEXTURE_RED_SIZE = 0x805C
+ TEXTURE_RESIDENT = 0x8067
+ TEXTURE_WIDTH = 0x1000
+ TEXTURE_WRAP_S = 0x2802
+ TEXTURE_WRAP_T = 0x2803
+
+ DONT_CARE = 0x1100
+ FASTEST = 0x1101
+ NICEST = 0x1102
+
+ FRAGMENT_SHADER_DERIVATIVE_HINT = 0x8B8B
+ GENERATE_MIPMAP_HINT = 0x8192
+ PROGRAM_BINARY_RETRIEVABLE_HINT = 0x8257
+ TEXTURE_COMPRESSION_HINT = 0x84EF
+
+ C3F_V3F = 0x2A24
+ C4F_N3F_V3F = 0x2A26
+ C4UB_V2F = 0x2A22
+ C4UB_V3F = 0x2A23
+ N3F_V3F = 0x2A25
+ T2F_C3F_V3F = 0x2A2A
+ T2F_C4F_N3F_V3F = 0x2A2C
+ T2F_C4UB_V3F = 0x2A29
+ T2F_N3F_V3F = 0x2A2B
+ T2F_V3F = 0x2A27
+ T4F_C4F_N3F_V4F = 0x2A2D
+ T4F_V4F = 0x2A28
+ V2F = 0x2A20
+ V3F = 0x2A21
+
+ MODULATE = 0x2100
+ REPLACE = 0x1E01
+
+ SEPARATE_SPECULAR_COLOR = 0x81FA
+ SINGLE_COLOR = 0x81F9
+
+ CONSTANT_ATTENUATION = 0x1207
+ LINEAR_ATTENUATION = 0x1208
+ POSITION = 0x1203
+ QUADRATIC_ATTENUATION = 0x1209
+ SPOT_CUTOFF = 0x1206
+ SPOT_DIRECTION = 0x1204
+ SPOT_EXPONENT = 0x1205
+
+ COMPILE = 0x1300
+ COMPILE_AND_EXECUTE = 0x1301
+
+ AND = 0x1501
+ AND_INVERTED = 0x1504
+ AND_REVERSE = 0x1502
+ CLEAR = 0x1500
+ COPY = 0x1503
+ COPY_INVERTED = 0x150C
+ EQUIV = 0x1509
+ INVERT = 0x150A
+ NAND = 0x150E
+ NOOP = 0x1505
+ NOR = 0x1508
+ OR = 0x1507
+ OR_INVERTED = 0x150D
+ OR_REVERSE = 0x150B
+ SET = 0x150F
+ XOR = 0x1506
+
+ MAP_FLUSH_EXPLICIT_BIT = 0x0010
+ MAP_INVALIDATE_BUFFER_BIT = 0x0008
+ MAP_INVALIDATE_RANGE_BIT = 0x0004
+ MAP_READ_BIT = 0x0001
+ MAP_UNSYNCHRONIZED_BIT = 0x0020
+ MAP_WRITE_BIT = 0x0002
+
+ COLOR_INDEXES = 0x1603
+ SHININESS = 0x1601
+
+ MODELVIEW = 0x1700
+ PROJECTION = 0x1701
+ TEXTURE = 0x1702
+
+ ALL_BARRIER_BITS = 0xFFFFFFFF
+ ATOMIC_COUNTER_BARRIER_BIT = 0x00001000
+ BUFFER_UPDATE_BARRIER_BIT = 0x00000200
+ COMMAND_BARRIER_BIT = 0x00000040
+ ELEMENT_ARRAY_BARRIER_BIT = 0x00000002
+ FRAMEBUFFER_BARRIER_BIT = 0x00000400
+ PIXEL_BUFFER_BARRIER_BIT = 0x00000080
+ SHADER_IMAGE_ACCESS_BARRIER_BIT = 0x00000020
+ TEXTURE_FETCH_BARRIER_BIT = 0x00000008
+ TEXTURE_UPDATE_BARRIER_BIT = 0x00000100
+ TRANSFORM_FEEDBACK_BARRIER_BIT = 0x00000800
+ UNIFORM_BARRIER_BIT = 0x00000004
+ VERTEX_ATTRIB_ARRAY_BARRIER_BIT = 0x00000001
+
+ LINE = 0x1B01
+ POINT = 0x1B00
+
+ FILL = 0x1B02
+
+ COLOR = 0x1800
+ DEPTH = 0x1801
+ STENCIL = 0x1802
+
+ ALPHA = 0x1906
+ BLUE = 0x1905
+ COLOR_INDEX = 0x1900
+ DEPTH_COMPONENT = 0x1902
+ GREEN = 0x1904
+ LUMINANCE = 0x1909
+ LUMINANCE_ALPHA = 0x190A
+ RED = 0x1903
+ RGB = 0x1907
+ RGBA = 0x1908
+ STENCIL_INDEX = 0x1901
+
+ ALPHA12 = 0x803D
+ ALPHA16 = 0x803E
+ ALPHA4 = 0x803B
+ ALPHA8 = 0x803C
+ INTENSITY = 0x8049
+ INTENSITY12 = 0x804C
+ INTENSITY16 = 0x804D
+ INTENSITY4 = 0x804A
+ INTENSITY8 = 0x804B
+ LUMINANCE12 = 0x8041
+ LUMINANCE12_ALPHA12 = 0x8047
+ LUMINANCE12_ALPHA4 = 0x8046
+ LUMINANCE16 = 0x8042
+ LUMINANCE16_ALPHA16 = 0x8048
+ LUMINANCE4 = 0x803F
+ LUMINANCE4_ALPHA4 = 0x8043
+ LUMINANCE6_ALPHA2 = 0x8044
+ LUMINANCE8 = 0x8040
+ LUMINANCE8_ALPHA8 = 0x8045
+ R3_G3_B2 = 0x2A10
+ RGB10 = 0x8052
+ RGB10_A2 = 0x8059
+ RGB12 = 0x8053
+ RGB16 = 0x8054
+ RGB4 = 0x804F
+ RGB5 = 0x8050
+ RGB5_A1 = 0x8057
+ RGB8 = 0x8051
+ RGBA12 = 0x805A
+ RGBA16 = 0x805B
+ RGBA2 = 0x8055
+ RGBA4 = 0x8056
+ RGBA8 = 0x8058
+
+ PACK_IMAGE_HEIGHT = 0x806C
+ PACK_SKIP_IMAGES = 0x806B
+ UNPACK_IMAGE_HEIGHT = 0x806E
+ UNPACK_SKIP_IMAGES = 0x806D
+
+ BITMAP = 0x1A00
+ UNSIGNED_BYTE_3_3_2 = 0x8032
+ UNSIGNED_INT_10_10_10_2 = 0x8036
+ UNSIGNED_INT_8_8_8_8 = 0x8035
+ UNSIGNED_SHORT_4_4_4_4 = 0x8033
+ UNSIGNED_SHORT_5_5_5_1 = 0x8034
+
+ POINT_DISTANCE_ATTENUATION = 0x8129
+ POINT_FADE_THRESHOLD_SIZE = 0x8128
+ POINT_SIZE_MAX = 0x8127
+ POINT_SIZE_MIN = 0x8126
+
+ LINES = 0x0001
+ LINES_ADJACENCY = 0x000A
+ LINE_LOOP = 0x0002
+ LINE_STRIP = 0x0003
+ LINE_STRIP_ADJACENCY = 0x000B
+ PATCHES = 0x000E
+ POINTS = 0x0000
+ POLYGON = 0x0009
+ QUADS = 0x0007
+ QUAD_STRIP = 0x0008
+ TRIANGLES = 0x0004
+ TRIANGLES_ADJACENCY = 0x000C
+ TRIANGLE_FAN = 0x0006
+ TRIANGLE_STRIP = 0x0005
+ TRIANGLE_STRIP_ADJACENCY = 0x000D
+
+ FEEDBACK = 0x1C01
+ RENDER = 0x1C00
+ SELECT = 0x1C02
+
+ FLAT = 0x1D00
+ SMOOTH = 0x1D01
+
+ DECR = 0x1E03
+ INCR = 0x1E02
+ KEEP = 0x1E00
+
+ EXTENSIONS = 0x1F03
+ RENDERER = 0x1F01
+ VENDOR = 0x1F00
+ VERSION = 0x1F02
+
+ S = 0x2000
+ T = 0x2001
+ R = 0x2002
+ Q = 0x2003
+
+ DECAL = 0x2101
+
+ TEXTURE_ENV_COLOR = 0x2201
+ TEXTURE_ENV_MODE = 0x2200
+
+ TEXTURE_ENV = 0x2300
+
+ EYE_LINEAR = 0x2400
+ OBJECT_LINEAR = 0x2401
+ SPHERE_MAP = 0x2402
+
+ EYE_PLANE = 0x2502
+ OBJECT_PLANE = 0x2501
+ TEXTURE_GEN_MODE = 0x2500
+
+ NEAREST = 0x2600
+
+ LINEAR_MIPMAP_LINEAR = 0x2703
+ LINEAR_MIPMAP_NEAREST = 0x2701
+ NEAREST_MIPMAP_LINEAR = 0x2702
+ NEAREST_MIPMAP_NEAREST = 0x2700
+
+ GENERATE_MIPMAP = 0x8191
+ TEXTURE_WRAP_R = 0x8072
+
+ PROXY_TEXTURE_1D = 0x8063
+ PROXY_TEXTURE_2D = 0x8064
+ PROXY_TEXTURE_3D = 0x8070
+ TEXTURE_3D = 0x806F
+ TEXTURE_BASE_LEVEL = 0x813C
+ TEXTURE_MAX_LEVEL = 0x813D
+ TEXTURE_MAX_LOD = 0x813B
+ TEXTURE_MIN_LOD = 0x813A
+
+ CLAMP = 0x2900
+ CLAMP_TO_BORDER = 0x812D
+ CLAMP_TO_EDGE = 0x812F
+ REPEAT = 0x2901
+
+ VERTEX_SHADER_BIT = 0x00000001
+ FRAGMENT_SHADER_BIT = 0x00000002
+ GEOMETRY_SHADER_BIT = 0x00000004
+ TESS_CONTROL_SHADER_BIT = 0x00000008
+ TESS_EVALUATION_SHADER_BIT = 0x00000010
+ ALL_SHADER_BITS = 0xFFFFFFFF
+
+ SYNC_FLUSH_COMMANDS_BIT = 0x00000001
+ INVALID_INDEX = 0xFFFFFFFF
+ TIMEOUT_IGNORED = 0xFFFFFFFFFFFFFFFF
+ CONSTANT_COLOR = 0x8001
+ ONE_MINUS_CONSTANT_COLOR = 0x8002
+ CONSTANT_ALPHA = 0x8003
+ ONE_MINUS_CONSTANT_ALPHA = 0x8004
+ FUNC_ADD = 0x8006
+ MIN = 0x8007
+ MAX = 0x8008
+ BLEND_EQUATION_RGB = 0x8009
+ FUNC_SUBTRACT = 0x800A
+ FUNC_REVERSE_SUBTRACT = 0x800B
+ RESCALE_NORMAL = 0x803A
+ TEXTURE_DEPTH = 0x8071
+ MAX_3D_TEXTURE_SIZE = 0x8073
+ MULTISAMPLE = 0x809D
+ SAMPLE_ALPHA_TO_COVERAGE = 0x809E
+ SAMPLE_ALPHA_TO_ONE = 0x809F
+ SAMPLE_COVERAGE = 0x80A0
+ SAMPLE_BUFFERS = 0x80A8
+ SAMPLES = 0x80A9
+ SAMPLE_COVERAGE_VALUE = 0x80AA
+ SAMPLE_COVERAGE_INVERT = 0x80AB
+ BLEND_DST_RGB = 0x80C8
+ BLEND_SRC_RGB = 0x80C9
+ BLEND_DST_ALPHA = 0x80CA
+ BLEND_SRC_ALPHA = 0x80CB
+ BGR = 0x80E0
+ BGRA = 0x80E1
+ MAX_ELEMENTS_VERTICES = 0x80E8
+ MAX_ELEMENTS_INDICES = 0x80E9
+ DEPTH_COMPONENT16 = 0x81A5
+ DEPTH_COMPONENT24 = 0x81A6
+ DEPTH_COMPONENT32 = 0x81A7
+ FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING = 0x8210
+ FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE = 0x8211
+ FRAMEBUFFER_ATTACHMENT_RED_SIZE = 0x8212
+ FRAMEBUFFER_ATTACHMENT_GREEN_SIZE = 0x8213
+ FRAMEBUFFER_ATTACHMENT_BLUE_SIZE = 0x8214
+ FRAMEBUFFER_ATTACHMENT_ALPHA_SIZE = 0x8215
+ FRAMEBUFFER_ATTACHMENT_DEPTH_SIZE = 0x8216
+ FRAMEBUFFER_ATTACHMENT_STENCIL_SIZE = 0x8217
+ FRAMEBUFFER_DEFAULT = 0x8218
+ FRAMEBUFFER_UNDEFINED = 0x8219
+ DEPTH_STENCIL_ATTACHMENT = 0x821A
+ MAJOR_VERSION = 0x821B
+ MINOR_VERSION = 0x821C
+ NUM_EXTENSIONS = 0x821D
+ CONTEXT_FLAGS = 0x821E
+ COMPRESSED_RED = 0x8225
+ COMPRESSED_RG = 0x8226
+ RG = 0x8227
+ RG_INTEGER = 0x8228
+ R8 = 0x8229
+ R16 = 0x822A
+ RG8 = 0x822B
+ RG16 = 0x822C
+ R16F = 0x822D
+ R32F = 0x822E
+ RG16F = 0x822F
+ RG32F = 0x8230
+ R8I = 0x8231
+ R8UI = 0x8232
+ R16I = 0x8233
+ R16UI = 0x8234
+ R32I = 0x8235
+ R32UI = 0x8236
+ RG8I = 0x8237
+ RG8UI = 0x8238
+ RG16I = 0x8239
+ RG16UI = 0x823A
+ RG32I = 0x823B
+ RG32UI = 0x823C
+ PROGRAM_SEPARABLE = 0x8258
+ ACTIVE_PROGRAM = 0x8259
+ PROGRAM_PIPELINE_BINDING = 0x825A
+ MAX_VIEWPORTS = 0x825B
+ VIEWPORT_SUBPIXEL_BITS = 0x825C
+ VIEWPORT_BOUNDS_RANGE = 0x825D
+ LAYER_PROVOKING_VERTEX = 0x825E
+ VIEWPORT_INDEX_PROVOKING_VERTEX = 0x825F
+ UNDEFINED_VERTEX = 0x8260
+ UNSIGNED_BYTE_2_3_3_REV = 0x8362
+ UNSIGNED_SHORT_5_6_5 = 0x8363
+ UNSIGNED_SHORT_5_6_5_REV = 0x8364
+ UNSIGNED_SHORT_4_4_4_4_REV = 0x8365
+ UNSIGNED_SHORT_1_5_5_5_REV = 0x8366
+ UNSIGNED_INT_8_8_8_8_REV = 0x8367
+ UNSIGNED_INT_2_10_10_10_REV = 0x8368
+ MIRRORED_REPEAT = 0x8370
+ FOG_COORDINATE_SOURCE = 0x8450
+ FOG_COORD_SRC = 0x8450
+ FOG_COORDINATE = 0x8451
+ FOG_COORD = 0x8451
+ FRAGMENT_DEPTH = 0x8452
+ CURRENT_FOG_COORDINATE = 0x8453
+ CURRENT_FOG_COORD = 0x8453
+ FOG_COORDINATE_ARRAY_TYPE = 0x8454
+ FOG_COORD_ARRAY_TYPE = 0x8454
+ FOG_COORDINATE_ARRAY_STRIDE = 0x8455
+ FOG_COORD_ARRAY_STRIDE = 0x8455
+ FOG_COORDINATE_ARRAY_POINTER = 0x8456
+ FOG_COORD_ARRAY_POINTER = 0x8456
+ FOG_COORDINATE_ARRAY = 0x8457
+ FOG_COORD_ARRAY = 0x8457
+ COLOR_SUM = 0x8458
+ CURRENT_SECONDARY_COLOR = 0x8459
+ SECONDARY_COLOR_ARRAY_SIZE = 0x845A
+ SECONDARY_COLOR_ARRAY_TYPE = 0x845B
+ SECONDARY_COLOR_ARRAY_STRIDE = 0x845C
+ SECONDARY_COLOR_ARRAY_POINTER = 0x845D
+ SECONDARY_COLOR_ARRAY = 0x845E
+ CURRENT_RASTER_SECONDARY_COLOR = 0x845F
+ TEXTURE0 = 0x84C0
+ TEXTURE1 = 0x84C1
+ TEXTURE2 = 0x84C2
+ TEXTURE3 = 0x84C3
+ TEXTURE4 = 0x84C4
+ TEXTURE5 = 0x84C5
+ TEXTURE6 = 0x84C6
+ TEXTURE7 = 0x84C7
+ TEXTURE8 = 0x84C8
+ TEXTURE9 = 0x84C9
+ TEXTURE10 = 0x84CA
+ TEXTURE11 = 0x84CB
+ TEXTURE12 = 0x84CC
+ TEXTURE13 = 0x84CD
+ TEXTURE14 = 0x84CE
+ TEXTURE15 = 0x84CF
+ TEXTURE16 = 0x84D0
+ TEXTURE17 = 0x84D1
+ TEXTURE18 = 0x84D2
+ TEXTURE19 = 0x84D3
+ TEXTURE20 = 0x84D4
+ TEXTURE21 = 0x84D5
+ TEXTURE22 = 0x84D6
+ TEXTURE23 = 0x84D7
+ TEXTURE24 = 0x84D8
+ TEXTURE25 = 0x84D9
+ TEXTURE26 = 0x84DA
+ TEXTURE27 = 0x84DB
+ TEXTURE28 = 0x84DC
+ TEXTURE29 = 0x84DD
+ TEXTURE30 = 0x84DE
+ TEXTURE31 = 0x84DF
+ ACTIVE_TEXTURE = 0x84E0
+ CLIENT_ACTIVE_TEXTURE = 0x84E1
+ MAX_TEXTURE_UNITS = 0x84E2
+ TRANSPOSE_MODELVIEW_MATRIX = 0x84E3
+ TRANSPOSE_PROJECTION_MATRIX = 0x84E4
+ TRANSPOSE_TEXTURE_MATRIX = 0x84E5
+ TRANSPOSE_COLOR_MATRIX = 0x84E6
+ SUBTRACT = 0x84E7
+ MAX_RENDERBUFFER_SIZE = 0x84E8
+ COMPRESSED_ALPHA = 0x84E9
+ COMPRESSED_LUMINANCE = 0x84EA
+ COMPRESSED_LUMINANCE_ALPHA = 0x84EB
+ COMPRESSED_INTENSITY = 0x84EC
+ COMPRESSED_RGB = 0x84ED
+ COMPRESSED_RGBA = 0x84EE
+ UNIFORM_BLOCK_REFERENCED_BY_TESS_CONTROL_SHADER = 0x84F0
+ UNIFORM_BLOCK_REFERENCED_BY_TESS_EVALUATION_SHADER = 0x84F1
+ TEXTURE_RECTANGLE = 0x84F5
+ TEXTURE_BINDING_RECTANGLE = 0x84F6
+ PROXY_TEXTURE_RECTANGLE = 0x84F7
+ MAX_RECTANGLE_TEXTURE_SIZE = 0x84F8
+ DEPTH_STENCIL = 0x84F9
+ UNSIGNED_INT_24_8 = 0x84FA
+ MAX_TEXTURE_LOD_BIAS = 0x84FD
+ TEXTURE_FILTER_CONTROL = 0x8500
+ TEXTURE_LOD_BIAS = 0x8501
+ INCR_WRAP = 0x8507
+ DECR_WRAP = 0x8508
+ NORMAL_MAP = 0x8511
+ REFLECTION_MAP = 0x8512
+ TEXTURE_CUBE_MAP = 0x8513
+ TEXTURE_BINDING_CUBE_MAP = 0x8514
+ TEXTURE_CUBE_MAP_POSITIVE_X = 0x8515
+ TEXTURE_CUBE_MAP_NEGATIVE_X = 0x8516
+ TEXTURE_CUBE_MAP_POSITIVE_Y = 0x8517
+ TEXTURE_CUBE_MAP_NEGATIVE_Y = 0x8518
+ TEXTURE_CUBE_MAP_POSITIVE_Z = 0x8519
+ TEXTURE_CUBE_MAP_NEGATIVE_Z = 0x851A
+ PROXY_TEXTURE_CUBE_MAP = 0x851B
+ MAX_CUBE_MAP_TEXTURE_SIZE = 0x851C
+ COMBINE = 0x8570
+ COMBINE_RGB = 0x8571
+ COMBINE_ALPHA = 0x8572
+ RGB_SCALE = 0x8573
+ ADD_SIGNED = 0x8574
+ INTERPOLATE = 0x8575
+ CONSTANT = 0x8576
+ PRIMARY_COLOR = 0x8577
+ PREVIOUS = 0x8578
+ SOURCE0_RGB = 0x8580
+ SRC0_RGB = 0x8580
+ SOURCE1_RGB = 0x8581
+ SRC1_RGB = 0x8581
+ SOURCE2_RGB = 0x8582
+ SRC2_RGB = 0x8582
+ SOURCE0_ALPHA = 0x8588
+ SRC0_ALPHA = 0x8588
+ SOURCE1_ALPHA = 0x8589
+ SRC1_ALPHA = 0x8589
+ SOURCE2_ALPHA = 0x858A
+ SRC2_ALPHA = 0x858A
+ OPERAND0_RGB = 0x8590
+ OPERAND1_RGB = 0x8591
+ OPERAND2_RGB = 0x8592
+ OPERAND0_ALPHA = 0x8598
+ OPERAND1_ALPHA = 0x8599
+ OPERAND2_ALPHA = 0x859A
+ VERTEX_ARRAY_BINDING = 0x85B5
+ VERTEX_ATTRIB_ARRAY_ENABLED = 0x8622
+ VERTEX_ATTRIB_ARRAY_SIZE = 0x8623
+ VERTEX_ATTRIB_ARRAY_STRIDE = 0x8624
+ VERTEX_ATTRIB_ARRAY_TYPE = 0x8625
+ CURRENT_VERTEX_ATTRIB = 0x8626
+ VERTEX_PROGRAM_POINT_SIZE = 0x8642
+ PROGRAM_POINT_SIZE = 0x8642
+ VERTEX_PROGRAM_TWO_SIDE = 0x8643
+ VERTEX_ATTRIB_ARRAY_POINTER = 0x8645
+ DEPTH_CLAMP = 0x864F
+ TEXTURE_COMPRESSED_IMAGE_SIZE = 0x86A0
+ TEXTURE_COMPRESSED = 0x86A1
+ NUM_COMPRESSED_TEXTURE_FORMATS = 0x86A2
+ COMPRESSED_TEXTURE_FORMATS = 0x86A3
+ DOT3_RGB = 0x86AE
+ DOT3_RGBA = 0x86AF
+ PROGRAM_BINARY_LENGTH = 0x8741
+ BUFFER_SIZE = 0x8764
+ BUFFER_USAGE = 0x8765
+ NUM_PROGRAM_BINARY_FORMATS = 0x87FE
+ PROGRAM_BINARY_FORMATS = 0x87FF
+ STENCIL_BACK_FUNC = 0x8800
+ STENCIL_BACK_FAIL = 0x8801
+ STENCIL_BACK_PASS_DEPTH_FAIL = 0x8802
+ STENCIL_BACK_PASS_DEPTH_PASS = 0x8803
+ RGBA32F = 0x8814
+ RGB32F = 0x8815
+ RGBA16F = 0x881A
+ RGB16F = 0x881B
+ MAX_DRAW_BUFFERS = 0x8824
+ DRAW_BUFFER0 = 0x8825
+ DRAW_BUFFER1 = 0x8826
+ DRAW_BUFFER2 = 0x8827
+ DRAW_BUFFER3 = 0x8828
+ DRAW_BUFFER4 = 0x8829
+ DRAW_BUFFER5 = 0x882A
+ DRAW_BUFFER6 = 0x882B
+ DRAW_BUFFER7 = 0x882C
+ DRAW_BUFFER8 = 0x882D
+ DRAW_BUFFER9 = 0x882E
+ DRAW_BUFFER10 = 0x882F
+ DRAW_BUFFER11 = 0x8830
+ DRAW_BUFFER12 = 0x8831
+ DRAW_BUFFER13 = 0x8832
+ DRAW_BUFFER14 = 0x8833
+ DRAW_BUFFER15 = 0x8834
+ BLEND_EQUATION_ALPHA = 0x883D
+ TEXTURE_DEPTH_SIZE = 0x884A
+ DEPTH_TEXTURE_MODE = 0x884B
+ TEXTURE_COMPARE_MODE = 0x884C
+ TEXTURE_COMPARE_FUNC = 0x884D
+ COMPARE_R_TO_TEXTURE = 0x884E
+ COMPARE_REF_TO_TEXTURE = 0x884E
+ TEXTURE_CUBE_MAP_SEAMLESS = 0x884F
+ POINT_SPRITE = 0x8861
+ COORD_REPLACE = 0x8862
+ QUERY_COUNTER_BITS = 0x8864
+ CURRENT_QUERY = 0x8865
+ QUERY_RESULT = 0x8866
+ QUERY_RESULT_AVAILABLE = 0x8867
+ MAX_VERTEX_ATTRIBS = 0x8869
+ VERTEX_ATTRIB_ARRAY_NORMALIZED = 0x886A
+ MAX_TESS_CONTROL_INPUT_COMPONENTS = 0x886C
+ MAX_TESS_EVALUATION_INPUT_COMPONENTS = 0x886D
+ MAX_TEXTURE_COORDS = 0x8871
+ MAX_TEXTURE_IMAGE_UNITS = 0x8872
+ GEOMETRY_SHADER_INVOCATIONS = 0x887F
+ ARRAY_BUFFER = 0x8892
+ ELEMENT_ARRAY_BUFFER = 0x8893
+ ARRAY_BUFFER_BINDING = 0x8894
+ ELEMENT_ARRAY_BUFFER_BINDING = 0x8895
+ VERTEX_ARRAY_BUFFER_BINDING = 0x8896
+ NORMAL_ARRAY_BUFFER_BINDING = 0x8897
+ COLOR_ARRAY_BUFFER_BINDING = 0x8898
+ INDEX_ARRAY_BUFFER_BINDING = 0x8899
+ TEXTURE_COORD_ARRAY_BUFFER_BINDING = 0x889A
+ EDGE_FLAG_ARRAY_BUFFER_BINDING = 0x889B
+ SECONDARY_COLOR_ARRAY_BUFFER_BINDING = 0x889C
+ FOG_COORDINATE_ARRAY_BUFFER_BINDING = 0x889D
+ FOG_COORD_ARRAY_BUFFER_BINDING = 0x889D
+ WEIGHT_ARRAY_BUFFER_BINDING = 0x889E
+ VERTEX_ATTRIB_ARRAY_BUFFER_BINDING = 0x889F
+ READ_ONLY = 0x88B8
+ WRITE_ONLY = 0x88B9
+ READ_WRITE = 0x88BA
+ BUFFER_ACCESS = 0x88BB
+ BUFFER_MAPPED = 0x88BC
+ BUFFER_MAP_POINTER = 0x88BD
+ TIME_ELAPSED = 0x88BF
+ STREAM_DRAW = 0x88E0
+ STREAM_READ = 0x88E1
+ STREAM_COPY = 0x88E2
+ STATIC_DRAW = 0x88E4
+ STATIC_READ = 0x88E5
+ STATIC_COPY = 0x88E6
+ DYNAMIC_DRAW = 0x88E8
+ DYNAMIC_READ = 0x88E9
+ DYNAMIC_COPY = 0x88EA
+ PIXEL_PACK_BUFFER = 0x88EB
+ PIXEL_UNPACK_BUFFER = 0x88EC
+ PIXEL_PACK_BUFFER_BINDING = 0x88ED
+ PIXEL_UNPACK_BUFFER_BINDING = 0x88EF
+ DEPTH24_STENCIL8 = 0x88F0
+ TEXTURE_STENCIL_SIZE = 0x88F1
+ SRC1_COLOR = 0x88F9
+ ONE_MINUS_SRC1_COLOR = 0x88FA
+ ONE_MINUS_SRC1_ALPHA = 0x88FB
+ MAX_DUAL_SOURCE_DRAW_BUFFERS = 0x88FC
+ VERTEX_ATTRIB_ARRAY_INTEGER = 0x88FD
+ VERTEX_ATTRIB_ARRAY_DIVISOR = 0x88FE
+ MAX_ARRAY_TEXTURE_LAYERS = 0x88FF
+ MIN_PROGRAM_TEXEL_OFFSET = 0x8904
+ MAX_PROGRAM_TEXEL_OFFSET = 0x8905
+ SAMPLES_PASSED = 0x8914
+ GEOMETRY_VERTICES_OUT = 0x8916
+ GEOMETRY_INPUT_TYPE = 0x8917
+ GEOMETRY_OUTPUT_TYPE = 0x8918
+ SAMPLER_BINDING = 0x8919
+ CLAMP_VERTEX_COLOR = 0x891A
+ CLAMP_FRAGMENT_COLOR = 0x891B
+ CLAMP_READ_COLOR = 0x891C
+ FIXED_ONLY = 0x891D
+ UNIFORM_BUFFER = 0x8A11
+ UNIFORM_BUFFER_BINDING = 0x8A28
+ UNIFORM_BUFFER_START = 0x8A29
+ UNIFORM_BUFFER_SIZE = 0x8A2A
+ MAX_VERTEX_UNIFORM_BLOCKS = 0x8A2B
+ MAX_GEOMETRY_UNIFORM_BLOCKS = 0x8A2C
+ MAX_FRAGMENT_UNIFORM_BLOCKS = 0x8A2D
+ MAX_COMBINED_UNIFORM_BLOCKS = 0x8A2E
+ MAX_UNIFORM_BUFFER_BINDINGS = 0x8A2F
+ MAX_UNIFORM_BLOCK_SIZE = 0x8A30
+ MAX_COMBINED_VERTEX_UNIFORM_COMPONENTS = 0x8A31
+ MAX_COMBINED_GEOMETRY_UNIFORM_COMPONENTS = 0x8A32
+ MAX_COMBINED_FRAGMENT_UNIFORM_COMPONENTS = 0x8A33
+ UNIFORM_BUFFER_OFFSET_ALIGNMENT = 0x8A34
+ ACTIVE_UNIFORM_BLOCK_MAX_NAME_LENGTH = 0x8A35
+ ACTIVE_UNIFORM_BLOCKS = 0x8A36
+ UNIFORM_TYPE = 0x8A37
+ UNIFORM_SIZE = 0x8A38
+ UNIFORM_NAME_LENGTH = 0x8A39
+ UNIFORM_BLOCK_INDEX = 0x8A3A
+ UNIFORM_OFFSET = 0x8A3B
+ UNIFORM_ARRAY_STRIDE = 0x8A3C
+ UNIFORM_MATRIX_STRIDE = 0x8A3D
+ UNIFORM_IS_ROW_MAJOR = 0x8A3E
+ UNIFORM_BLOCK_BINDING = 0x8A3F
+ UNIFORM_BLOCK_DATA_SIZE = 0x8A40
+ UNIFORM_BLOCK_NAME_LENGTH = 0x8A41
+ UNIFORM_BLOCK_ACTIVE_UNIFORMS = 0x8A42
+ UNIFORM_BLOCK_ACTIVE_UNIFORM_INDICES = 0x8A43
+ UNIFORM_BLOCK_REFERENCED_BY_VERTEX_SHADER = 0x8A44
+ UNIFORM_BLOCK_REFERENCED_BY_GEOMETRY_SHADER = 0x8A45
+ UNIFORM_BLOCK_REFERENCED_BY_FRAGMENT_SHADER = 0x8A46
+ FRAGMENT_SHADER = 0x8B30
+ VERTEX_SHADER = 0x8B31
+ MAX_FRAGMENT_UNIFORM_COMPONENTS = 0x8B49
+ MAX_VERTEX_UNIFORM_COMPONENTS = 0x8B4A
+ MAX_VARYING_FLOATS = 0x8B4B
+ MAX_VARYING_COMPONENTS = 0x8B4B
+ MAX_VERTEX_TEXTURE_IMAGE_UNITS = 0x8B4C
+ MAX_COMBINED_TEXTURE_IMAGE_UNITS = 0x8B4D
+ SHADER_TYPE = 0x8B4F
+ FLOAT_VEC2 = 0x8B50
+ FLOAT_VEC3 = 0x8B51
+ FLOAT_VEC4 = 0x8B52
+ INT_VEC2 = 0x8B53
+ INT_VEC3 = 0x8B54
+ INT_VEC4 = 0x8B55
+ BOOL = 0x8B56
+ BOOL_VEC2 = 0x8B57
+ BOOL_VEC3 = 0x8B58
+ BOOL_VEC4 = 0x8B59
+ FLOAT_MAT2 = 0x8B5A
+ FLOAT_MAT3 = 0x8B5B
+ FLOAT_MAT4 = 0x8B5C
+ SAMPLER_1D = 0x8B5D
+ SAMPLER_2D = 0x8B5E
+ SAMPLER_3D = 0x8B5F
+ SAMPLER_CUBE = 0x8B60
+ SAMPLER_1D_SHADOW = 0x8B61
+ SAMPLER_2D_SHADOW = 0x8B62
+ SAMPLER_2D_RECT = 0x8B63
+ SAMPLER_2D_RECT_SHADOW = 0x8B64
+ FLOAT_MAT2x3 = 0x8B65
+ FLOAT_MAT2x4 = 0x8B66
+ FLOAT_MAT3x2 = 0x8B67
+ FLOAT_MAT3x4 = 0x8B68
+ FLOAT_MAT4x2 = 0x8B69
+ FLOAT_MAT4x3 = 0x8B6A
+ DELETE_STATUS = 0x8B80
+ COMPILE_STATUS = 0x8B81
+ LINK_STATUS = 0x8B82
+ VALIDATE_STATUS = 0x8B83
+ INFO_LOG_LENGTH = 0x8B84
+ ATTACHED_SHADERS = 0x8B85
+ ACTIVE_UNIFORMS = 0x8B86
+ ACTIVE_UNIFORM_MAX_LENGTH = 0x8B87
+ SHADER_SOURCE_LENGTH = 0x8B88
+ ACTIVE_ATTRIBUTES = 0x8B89
+ ACTIVE_ATTRIBUTE_MAX_LENGTH = 0x8B8A
+ SHADING_LANGUAGE_VERSION = 0x8B8C
+ CURRENT_PROGRAM = 0x8B8D
+ IMPLEMENTATION_COLOR_READ_TYPE = 0x8B9A
+ IMPLEMENTATION_COLOR_READ_FORMAT = 0x8B9B
+ TEXTURE_RED_TYPE = 0x8C10
+ TEXTURE_GREEN_TYPE = 0x8C11
+ TEXTURE_BLUE_TYPE = 0x8C12
+ TEXTURE_ALPHA_TYPE = 0x8C13
+ TEXTURE_DEPTH_TYPE = 0x8C16
+ UNSIGNED_NORMALIZED = 0x8C17
+ TEXTURE_1D_ARRAY = 0x8C18
+ PROXY_TEXTURE_1D_ARRAY = 0x8C19
+ TEXTURE_2D_ARRAY = 0x8C1A
+ PROXY_TEXTURE_2D_ARRAY = 0x8C1B
+ TEXTURE_BINDING_1D_ARRAY = 0x8C1C
+ TEXTURE_BINDING_2D_ARRAY = 0x8C1D
+ MAX_GEOMETRY_TEXTURE_IMAGE_UNITS = 0x8C29
+ TEXTURE_BUFFER = 0x8C2A
+ MAX_TEXTURE_BUFFER_SIZE = 0x8C2B
+ TEXTURE_BINDING_BUFFER = 0x8C2C
+ TEXTURE_BUFFER_DATA_STORE_BINDING = 0x8C2D
+ ANY_SAMPLES_PASSED = 0x8C2F
+ SAMPLE_SHADING = 0x8C36
+ MIN_SAMPLE_SHADING_VALUE = 0x8C37
+ R11F_G11F_B10F = 0x8C3A
+ UNSIGNED_INT_10F_11F_11F_REV = 0x8C3B
+ RGB9_E5 = 0x8C3D
+ UNSIGNED_INT_5_9_9_9_REV = 0x8C3E
+ TEXTURE_SHARED_SIZE = 0x8C3F
+ SRGB = 0x8C40
+ SRGB8 = 0x8C41
+ SRGB_ALPHA = 0x8C42
+ SRGB8_ALPHA8 = 0x8C43
+ SLUMINANCE_ALPHA = 0x8C44
+ SLUMINANCE8_ALPHA8 = 0x8C45
+ SLUMINANCE = 0x8C46
+ SLUMINANCE8 = 0x8C47
+ COMPRESSED_SRGB = 0x8C48
+ COMPRESSED_SRGB_ALPHA = 0x8C49
+ COMPRESSED_SLUMINANCE = 0x8C4A
+ COMPRESSED_SLUMINANCE_ALPHA = 0x8C4B
+ TRANSFORM_FEEDBACK_VARYING_MAX_LENGTH = 0x8C76
+ TRANSFORM_FEEDBACK_BUFFER_MODE = 0x8C7F
+ MAX_TRANSFORM_FEEDBACK_SEPARATE_COMPONENTS = 0x8C80
+ TRANSFORM_FEEDBACK_VARYINGS = 0x8C83
+ TRANSFORM_FEEDBACK_BUFFER_START = 0x8C84
+ TRANSFORM_FEEDBACK_BUFFER_SIZE = 0x8C85
+ PRIMITIVES_GENERATED = 0x8C87
+ TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN = 0x8C88
+ RASTERIZER_DISCARD = 0x8C89
+ MAX_TRANSFORM_FEEDBACK_INTERLEAVED_COMPONENTS = 0x8C8A
+ MAX_TRANSFORM_FEEDBACK_SEPARATE_ATTRIBS = 0x8C8B
+ INTERLEAVED_ATTRIBS = 0x8C8C
+ SEPARATE_ATTRIBS = 0x8C8D
+ TRANSFORM_FEEDBACK_BUFFER = 0x8C8E
+ TRANSFORM_FEEDBACK_BUFFER_BINDING = 0x8C8F
+ POINT_SPRITE_COORD_ORIGIN = 0x8CA0
+ LOWER_LEFT = 0x8CA1
+ UPPER_LEFT = 0x8CA2
+ STENCIL_BACK_REF = 0x8CA3
+ STENCIL_BACK_VALUE_MASK = 0x8CA4
+ STENCIL_BACK_WRITEMASK = 0x8CA5
+ DRAW_FRAMEBUFFER_BINDING = 0x8CA6
+ FRAMEBUFFER_BINDING = 0x8CA6
+ RENDERBUFFER_BINDING = 0x8CA7
+ READ_FRAMEBUFFER = 0x8CA8
+ DRAW_FRAMEBUFFER = 0x8CA9
+ READ_FRAMEBUFFER_BINDING = 0x8CAA
+ RENDERBUFFER_SAMPLES = 0x8CAB
+ DEPTH_COMPONENT32F = 0x8CAC
+ DEPTH32F_STENCIL8 = 0x8CAD
+ FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE = 0x8CD0
+ FRAMEBUFFER_ATTACHMENT_OBJECT_NAME = 0x8CD1
+ FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL = 0x8CD2
+ FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE = 0x8CD3
+ FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER = 0x8CD4
+ FRAMEBUFFER_COMPLETE = 0x8CD5
+ FRAMEBUFFER_INCOMPLETE_ATTACHMENT = 0x8CD6
+ FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT = 0x8CD7
+ FRAMEBUFFER_INCOMPLETE_DRAW_BUFFER = 0x8CDB
+ FRAMEBUFFER_INCOMPLETE_READ_BUFFER = 0x8CDC
+ FRAMEBUFFER_UNSUPPORTED = 0x8CDD
+ MAX_COLOR_ATTACHMENTS = 0x8CDF
+ COLOR_ATTACHMENT0 = 0x8CE0
+ COLOR_ATTACHMENT1 = 0x8CE1
+ COLOR_ATTACHMENT2 = 0x8CE2
+ COLOR_ATTACHMENT3 = 0x8CE3
+ COLOR_ATTACHMENT4 = 0x8CE4
+ COLOR_ATTACHMENT5 = 0x8CE5
+ COLOR_ATTACHMENT6 = 0x8CE6
+ COLOR_ATTACHMENT7 = 0x8CE7
+ COLOR_ATTACHMENT8 = 0x8CE8
+ COLOR_ATTACHMENT9 = 0x8CE9
+ COLOR_ATTACHMENT10 = 0x8CEA
+ COLOR_ATTACHMENT11 = 0x8CEB
+ COLOR_ATTACHMENT12 = 0x8CEC
+ COLOR_ATTACHMENT13 = 0x8CED
+ COLOR_ATTACHMENT14 = 0x8CEE
+ COLOR_ATTACHMENT15 = 0x8CEF
+ DEPTH_ATTACHMENT = 0x8D00
+ STENCIL_ATTACHMENT = 0x8D20
+ FRAMEBUFFER = 0x8D40
+ RENDERBUFFER = 0x8D41
+ RENDERBUFFER_WIDTH = 0x8D42
+ RENDERBUFFER_HEIGHT = 0x8D43
+ RENDERBUFFER_INTERNAL_FORMAT = 0x8D44
+ STENCIL_INDEX1 = 0x8D46
+ STENCIL_INDEX4 = 0x8D47
+ STENCIL_INDEX8 = 0x8D48
+ STENCIL_INDEX16 = 0x8D49
+ RENDERBUFFER_RED_SIZE = 0x8D50
+ RENDERBUFFER_GREEN_SIZE = 0x8D51
+ RENDERBUFFER_BLUE_SIZE = 0x8D52
+ RENDERBUFFER_ALPHA_SIZE = 0x8D53
+ RENDERBUFFER_DEPTH_SIZE = 0x8D54
+ RENDERBUFFER_STENCIL_SIZE = 0x8D55
+ FRAMEBUFFER_INCOMPLETE_MULTISAMPLE = 0x8D56
+ MAX_SAMPLES = 0x8D57
+ RGB565 = 0x8D62
+ RGBA32UI = 0x8D70
+ RGB32UI = 0x8D71
+ RGBA16UI = 0x8D76
+ RGB16UI = 0x8D77
+ RGBA8UI = 0x8D7C
+ RGB8UI = 0x8D7D
+ RGBA32I = 0x8D82
+ RGB32I = 0x8D83
+ RGBA16I = 0x8D88
+ RGB16I = 0x8D89
+ RGBA8I = 0x8D8E
+ RGB8I = 0x8D8F
+ RED_INTEGER = 0x8D94
+ GREEN_INTEGER = 0x8D95
+ BLUE_INTEGER = 0x8D96
+ ALPHA_INTEGER = 0x8D97
+ RGB_INTEGER = 0x8D98
+ RGBA_INTEGER = 0x8D99
+ BGR_INTEGER = 0x8D9A
+ BGRA_INTEGER = 0x8D9B
+ INT_2_10_10_10_REV = 0x8D9F
+ FRAMEBUFFER_ATTACHMENT_LAYERED = 0x8DA7
+ FRAMEBUFFER_INCOMPLETE_LAYER_TARGETS = 0x8DA8
+ FLOAT_32_UNSIGNED_INT_24_8_REV = 0x8DAD
+ FRAMEBUFFER_SRGB = 0x8DB9
+ COMPRESSED_RED_RGTC1 = 0x8DBB
+ COMPRESSED_SIGNED_RED_RGTC1 = 0x8DBC
+ COMPRESSED_RG_RGTC2 = 0x8DBD
+ COMPRESSED_SIGNED_RG_RGTC2 = 0x8DBE
+ SAMPLER_1D_ARRAY = 0x8DC0
+ SAMPLER_2D_ARRAY = 0x8DC1
+ SAMPLER_BUFFER = 0x8DC2
+ SAMPLER_1D_ARRAY_SHADOW = 0x8DC3
+ SAMPLER_2D_ARRAY_SHADOW = 0x8DC4
+ SAMPLER_CUBE_SHADOW = 0x8DC5
+ UNSIGNED_INT_VEC2 = 0x8DC6
+ UNSIGNED_INT_VEC3 = 0x8DC7
+ UNSIGNED_INT_VEC4 = 0x8DC8
+ INT_SAMPLER_1D = 0x8DC9
+ INT_SAMPLER_2D = 0x8DCA
+ INT_SAMPLER_3D = 0x8DCB
+ INT_SAMPLER_CUBE = 0x8DCC
+ INT_SAMPLER_2D_RECT = 0x8DCD
+ INT_SAMPLER_1D_ARRAY = 0x8DCE
+ INT_SAMPLER_2D_ARRAY = 0x8DCF
+ INT_SAMPLER_BUFFER = 0x8DD0
+ UNSIGNED_INT_SAMPLER_1D = 0x8DD1
+ UNSIGNED_INT_SAMPLER_2D = 0x8DD2
+ UNSIGNED_INT_SAMPLER_3D = 0x8DD3
+ UNSIGNED_INT_SAMPLER_CUBE = 0x8DD4
+ UNSIGNED_INT_SAMPLER_2D_RECT = 0x8DD5
+ UNSIGNED_INT_SAMPLER_1D_ARRAY = 0x8DD6
+ UNSIGNED_INT_SAMPLER_2D_ARRAY = 0x8DD7
+ UNSIGNED_INT_SAMPLER_BUFFER = 0x8DD8
+ GEOMETRY_SHADER = 0x8DD9
+ MAX_GEOMETRY_UNIFORM_COMPONENTS = 0x8DDF
+ MAX_GEOMETRY_OUTPUT_VERTICES = 0x8DE0
+ MAX_GEOMETRY_TOTAL_OUTPUT_COMPONENTS = 0x8DE1
+ ACTIVE_SUBROUTINES = 0x8DE5
+ ACTIVE_SUBROUTINE_UNIFORMS = 0x8DE6
+ MAX_SUBROUTINES = 0x8DE7
+ MAX_SUBROUTINE_UNIFORM_LOCATIONS = 0x8DE8
+ LOW_FLOAT = 0x8DF0
+ MEDIUM_FLOAT = 0x8DF1
+ HIGH_FLOAT = 0x8DF2
+ LOW_INT = 0x8DF3
+ MEDIUM_INT = 0x8DF4
+ HIGH_INT = 0x8DF5
+ SHADER_BINARY_FORMATS = 0x8DF8
+ NUM_SHADER_BINARY_FORMATS = 0x8DF9
+ SHADER_COMPILER = 0x8DFA
+ MAX_VERTEX_UNIFORM_VECTORS = 0x8DFB
+ MAX_VARYING_VECTORS = 0x8DFC
+ MAX_FRAGMENT_UNIFORM_VECTORS = 0x8DFD
+ QUERY_WAIT = 0x8E13
+ QUERY_NO_WAIT = 0x8E14
+ QUERY_BY_REGION_WAIT = 0x8E15
+ QUERY_BY_REGION_NO_WAIT = 0x8E16
+ MAX_COMBINED_TESS_CONTROL_UNIFORM_COMPONENTS = 0x8E1E
+ MAX_COMBINED_TESS_EVALUATION_UNIFORM_COMPONENTS = 0x8E1F
+ TRANSFORM_FEEDBACK = 0x8E22
+ TRANSFORM_FEEDBACK_BUFFER_PAUSED = 0x8E23
+ TRANSFORM_FEEDBACK_BUFFER_ACTIVE = 0x8E24
+ TRANSFORM_FEEDBACK_BINDING = 0x8E25
+ TIMESTAMP = 0x8E28
+ TEXTURE_SWIZZLE_R = 0x8E42
+ TEXTURE_SWIZZLE_G = 0x8E43
+ TEXTURE_SWIZZLE_B = 0x8E44
+ TEXTURE_SWIZZLE_A = 0x8E45
+ TEXTURE_SWIZZLE_RGBA = 0x8E46
+ ACTIVE_SUBROUTINE_UNIFORM_LOCATIONS = 0x8E47
+ ACTIVE_SUBROUTINE_MAX_LENGTH = 0x8E48
+ ACTIVE_SUBROUTINE_UNIFORM_MAX_LENGTH = 0x8E49
+ NUM_COMPATIBLE_SUBROUTINES = 0x8E4A
+ COMPATIBLE_SUBROUTINES = 0x8E4B
+ QUADS_FOLLOW_PROVOKING_VERTEX_CONVENTION = 0x8E4C
+ FIRST_VERTEX_CONVENTION = 0x8E4D
+ LAST_VERTEX_CONVENTION = 0x8E4E
+ PROVOKING_VERTEX = 0x8E4F
+ SAMPLE_POSITION = 0x8E50
+ SAMPLE_MASK = 0x8E51
+ SAMPLE_MASK_VALUE = 0x8E52
+ MAX_SAMPLE_MASK_WORDS = 0x8E59
+ MAX_GEOMETRY_SHADER_INVOCATIONS = 0x8E5A
+ MIN_FRAGMENT_INTERPOLATION_OFFSET = 0x8E5B
+ MAX_FRAGMENT_INTERPOLATION_OFFSET = 0x8E5C
+ FRAGMENT_INTERPOLATION_OFFSET_BITS = 0x8E5D
+ MIN_PROGRAM_TEXTURE_GATHER_OFFSET = 0x8E5E
+ MAX_PROGRAM_TEXTURE_GATHER_OFFSET = 0x8E5F
+ MAX_TRANSFORM_FEEDBACK_BUFFERS = 0x8E70
+ MAX_VERTEX_STREAMS = 0x8E71
+ PATCH_VERTICES = 0x8E72
+ PATCH_DEFAULT_INNER_LEVEL = 0x8E73
+ PATCH_DEFAULT_OUTER_LEVEL = 0x8E74
+ TESS_CONTROL_OUTPUT_VERTICES = 0x8E75
+ TESS_GEN_MODE = 0x8E76
+ TESS_GEN_SPACING = 0x8E77
+ TESS_GEN_VERTEX_ORDER = 0x8E78
+ TESS_GEN_POINT_MODE = 0x8E79
+ ISOLINES = 0x8E7A
+ FRACTIONAL_ODD = 0x8E7B
+ FRACTIONAL_EVEN = 0x8E7C
+ MAX_PATCH_VERTICES = 0x8E7D
+ MAX_TESS_GEN_LEVEL = 0x8E7E
+ MAX_TESS_CONTROL_UNIFORM_COMPONENTS = 0x8E7F
+ MAX_TESS_EVALUATION_UNIFORM_COMPONENTS = 0x8E80
+ MAX_TESS_CONTROL_TEXTURE_IMAGE_UNITS = 0x8E81
+ MAX_TESS_EVALUATION_TEXTURE_IMAGE_UNITS = 0x8E82
+ MAX_TESS_CONTROL_OUTPUT_COMPONENTS = 0x8E83
+ MAX_TESS_PATCH_COMPONENTS = 0x8E84
+ MAX_TESS_CONTROL_TOTAL_OUTPUT_COMPONENTS = 0x8E85
+ MAX_TESS_EVALUATION_OUTPUT_COMPONENTS = 0x8E86
+ TESS_EVALUATION_SHADER = 0x8E87
+ TESS_CONTROL_SHADER = 0x8E88
+ MAX_TESS_CONTROL_UNIFORM_BLOCKS = 0x8E89
+ MAX_TESS_EVALUATION_UNIFORM_BLOCKS = 0x8E8A
+ COMPRESSED_RGBA_BPTC_UNORM = 0x8E8C
+ COMPRESSED_SRGB_ALPHA_BPTC_UNORM = 0x8E8D
+ COMPRESSED_RGB_BPTC_SIGNED_FLOAT = 0x8E8E
+ COMPRESSED_RGB_BPTC_UNSIGNED_FLOAT = 0x8E8F
+ COPY_READ_BUFFER = 0x8F36
+ COPY_WRITE_BUFFER = 0x8F37
+ MAX_IMAGE_UNITS = 0x8F38
+ MAX_COMBINED_IMAGE_UNITS_AND_FRAGMENT_OUTPUTS = 0x8F39
+ IMAGE_BINDING_NAME = 0x8F3A
+ IMAGE_BINDING_LEVEL = 0x8F3B
+ IMAGE_BINDING_LAYERED = 0x8F3C
+ IMAGE_BINDING_LAYER = 0x8F3D
+ IMAGE_BINDING_ACCESS = 0x8F3E
+ DRAW_INDIRECT_BUFFER = 0x8F3F
+ DRAW_INDIRECT_BUFFER_BINDING = 0x8F43
+ DOUBLE_MAT2 = 0x8F46
+ DOUBLE_MAT3 = 0x8F47
+ DOUBLE_MAT4 = 0x8F48
+ DOUBLE_MAT2x3 = 0x8F49
+ DOUBLE_MAT2x4 = 0x8F4A
+ DOUBLE_MAT3x2 = 0x8F4B
+ DOUBLE_MAT3x4 = 0x8F4C
+ DOUBLE_MAT4x2 = 0x8F4D
+ DOUBLE_MAT4x3 = 0x8F4E
+ R8_SNORM = 0x8F94
+ RG8_SNORM = 0x8F95
+ RGB8_SNORM = 0x8F96
+ RGBA8_SNORM = 0x8F97
+ R16_SNORM = 0x8F98
+ RG16_SNORM = 0x8F99
+ RGB16_SNORM = 0x8F9A
+ RGBA16_SNORM = 0x8F9B
+ SIGNED_NORMALIZED = 0x8F9C
+ PRIMITIVE_RESTART = 0x8F9D
+ PRIMITIVE_RESTART_INDEX = 0x8F9E
+ DOUBLE_VEC2 = 0x8FFC
+ DOUBLE_VEC3 = 0x8FFD
+ DOUBLE_VEC4 = 0x8FFE
+ TEXTURE_CUBE_MAP_ARRAY = 0x9009
+ TEXTURE_BINDING_CUBE_MAP_ARRAY = 0x900A
+ PROXY_TEXTURE_CUBE_MAP_ARRAY = 0x900B
+ SAMPLER_CUBE_MAP_ARRAY = 0x900C
+ SAMPLER_CUBE_MAP_ARRAY_SHADOW = 0x900D
+ INT_SAMPLER_CUBE_MAP_ARRAY = 0x900E
+ UNSIGNED_INT_SAMPLER_CUBE_MAP_ARRAY = 0x900F
+ IMAGE_1D = 0x904C
+ IMAGE_2D = 0x904D
+ IMAGE_3D = 0x904E
+ IMAGE_2D_RECT = 0x904F
+ IMAGE_CUBE = 0x9050
+ IMAGE_BUFFER = 0x9051
+ IMAGE_1D_ARRAY = 0x9052
+ IMAGE_2D_ARRAY = 0x9053
+ IMAGE_CUBE_MAP_ARRAY = 0x9054
+ IMAGE_2D_MULTISAMPLE = 0x9055
+ IMAGE_2D_MULTISAMPLE_ARRAY = 0x9056
+ INT_IMAGE_1D = 0x9057
+ INT_IMAGE_2D = 0x9058
+ INT_IMAGE_3D = 0x9059
+ INT_IMAGE_2D_RECT = 0x905A
+ INT_IMAGE_CUBE = 0x905B
+ INT_IMAGE_BUFFER = 0x905C
+ INT_IMAGE_1D_ARRAY = 0x905D
+ INT_IMAGE_2D_ARRAY = 0x905E
+ INT_IMAGE_CUBE_MAP_ARRAY = 0x905F
+ INT_IMAGE_2D_MULTISAMPLE = 0x9060
+ INT_IMAGE_2D_MULTISAMPLE_ARRAY = 0x9061
+ UNSIGNED_INT_IMAGE_1D = 0x9062
+ UNSIGNED_INT_IMAGE_2D = 0x9063
+ UNSIGNED_INT_IMAGE_3D = 0x9064
+ UNSIGNED_INT_IMAGE_2D_RECT = 0x9065
+ UNSIGNED_INT_IMAGE_CUBE = 0x9066
+ UNSIGNED_INT_IMAGE_BUFFER = 0x9067
+ UNSIGNED_INT_IMAGE_1D_ARRAY = 0x9068
+ UNSIGNED_INT_IMAGE_2D_ARRAY = 0x9069
+ UNSIGNED_INT_IMAGE_CUBE_MAP_ARRAY = 0x906A
+ UNSIGNED_INT_IMAGE_2D_MULTISAMPLE = 0x906B
+ UNSIGNED_INT_IMAGE_2D_MULTISAMPLE_ARRAY = 0x906C
+ MAX_IMAGE_SAMPLES = 0x906D
+ IMAGE_BINDING_FORMAT = 0x906E
+ RGB10_A2UI = 0x906F
+ MIN_MAP_BUFFER_ALIGNMENT = 0x90BC
+ IMAGE_FORMAT_COMPATIBILITY_TYPE = 0x90C7
+ IMAGE_FORMAT_COMPATIBILITY_BY_SIZE = 0x90C8
+ IMAGE_FORMAT_COMPATIBILITY_BY_CLASS = 0x90C9
+ MAX_VERTEX_IMAGE_UNIFORMS = 0x90CA
+ MAX_TESS_CONTROL_IMAGE_UNIFORMS = 0x90CB
+ MAX_TESS_EVALUATION_IMAGE_UNIFORMS = 0x90CC
+ MAX_GEOMETRY_IMAGE_UNIFORMS = 0x90CD
+ MAX_FRAGMENT_IMAGE_UNIFORMS = 0x90CE
+ MAX_COMBINED_IMAGE_UNIFORMS = 0x90CF
+ TEXTURE_2D_MULTISAMPLE = 0x9100
+ PROXY_TEXTURE_2D_MULTISAMPLE = 0x9101
+ TEXTURE_2D_MULTISAMPLE_ARRAY = 0x9102
+ PROXY_TEXTURE_2D_MULTISAMPLE_ARRAY = 0x9103
+ TEXTURE_BINDING_2D_MULTISAMPLE = 0x9104
+ TEXTURE_BINDING_2D_MULTISAMPLE_ARRAY = 0x9105
+ TEXTURE_SAMPLES = 0x9106
+ TEXTURE_FIXED_SAMPLE_LOCATIONS = 0x9107
+ SAMPLER_2D_MULTISAMPLE = 0x9108
+ INT_SAMPLER_2D_MULTISAMPLE = 0x9109
+ UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE = 0x910A
+ SAMPLER_2D_MULTISAMPLE_ARRAY = 0x910B
+ INT_SAMPLER_2D_MULTISAMPLE_ARRAY = 0x910C
+ UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE_ARRAY = 0x910D
+ MAX_COLOR_TEXTURE_SAMPLES = 0x910E
+ MAX_DEPTH_TEXTURE_SAMPLES = 0x910F
+ MAX_INTEGER_SAMPLES = 0x9110
+ MAX_SERVER_WAIT_TIMEOUT = 0x9111
+ OBJECT_TYPE = 0x9112
+ SYNC_CONDITION = 0x9113
+ SYNC_STATUS = 0x9114
+ SYNC_FLAGS = 0x9115
+ SYNC_FENCE = 0x9116
+ SYNC_GPU_COMMANDS_COMPLETE = 0x9117
+ UNSIGNALED = 0x9118
+ SIGNALED = 0x9119
+ ALREADY_SIGNALED = 0x911A
+ TIMEOUT_EXPIRED = 0x911B
+ CONDITION_SATISFIED = 0x911C
+ WAIT_FAILED = 0x911D
+ BUFFER_ACCESS_FLAGS = 0x911F
+ BUFFER_MAP_LENGTH = 0x9120
+ BUFFER_MAP_OFFSET = 0x9121
+ MAX_VERTEX_OUTPUT_COMPONENTS = 0x9122
+ MAX_GEOMETRY_INPUT_COMPONENTS = 0x9123
+ MAX_GEOMETRY_OUTPUT_COMPONENTS = 0x9124
+ MAX_FRAGMENT_INPUT_COMPONENTS = 0x9125
+ CONTEXT_PROFILE_MASK = 0x9126
+ UNPACK_COMPRESSED_BLOCK_WIDTH = 0x9127
+ UNPACK_COMPRESSED_BLOCK_HEIGHT = 0x9128
+ UNPACK_COMPRESSED_BLOCK_DEPTH = 0x9129
+ UNPACK_COMPRESSED_BLOCK_SIZE = 0x912A
+ PACK_COMPRESSED_BLOCK_WIDTH = 0x912B
+ PACK_COMPRESSED_BLOCK_HEIGHT = 0x912C
+ PACK_COMPRESSED_BLOCK_DEPTH = 0x912D
+ PACK_COMPRESSED_BLOCK_SIZE = 0x912E
+ TEXTURE_IMMUTABLE_FORMAT = 0x912F
+ ATOMIC_COUNTER_BUFFER = 0x92C0
+ ATOMIC_COUNTER_BUFFER_BINDING = 0x92C1
+ ATOMIC_COUNTER_BUFFER_START = 0x92C2
+ ATOMIC_COUNTER_BUFFER_SIZE = 0x92C3
+ ATOMIC_COUNTER_BUFFER_DATA_SIZE = 0x92C4
+ ATOMIC_COUNTER_BUFFER_ACTIVE_ATOMIC_COUNTERS = 0x92C5
+ ATOMIC_COUNTER_BUFFER_ACTIVE_ATOMIC_COUNTER_INDICES = 0x92C6
+ ATOMIC_COUNTER_BUFFER_REFERENCED_BY_VERTEX_SHADER = 0x92C7
+ ATOMIC_COUNTER_BUFFER_REFERENCED_BY_TESS_CONTROL_SHADER = 0x92C8
+ ATOMIC_COUNTER_BUFFER_REFERENCED_BY_TESS_EVALUATION_SHADER = 0x92C9
+ ATOMIC_COUNTER_BUFFER_REFERENCED_BY_GEOMETRY_SHADER = 0x92CA
+ ATOMIC_COUNTER_BUFFER_REFERENCED_BY_FRAGMENT_SHADER = 0x92CB
+ MAX_VERTEX_ATOMIC_COUNTER_BUFFERS = 0x92CC
+ MAX_TESS_CONTROL_ATOMIC_COUNTER_BUFFERS = 0x92CD
+ MAX_TESS_EVALUATION_ATOMIC_COUNTER_BUFFERS = 0x92CE
+ MAX_GEOMETRY_ATOMIC_COUNTER_BUFFERS = 0x92CF
+ MAX_FRAGMENT_ATOMIC_COUNTER_BUFFERS = 0x92D0
+ MAX_COMBINED_ATOMIC_COUNTER_BUFFERS = 0x92D1
+ MAX_VERTEX_ATOMIC_COUNTERS = 0x92D2
+ MAX_TESS_CONTROL_ATOMIC_COUNTERS = 0x92D3
+ MAX_TESS_EVALUATION_ATOMIC_COUNTERS = 0x92D4
+ MAX_GEOMETRY_ATOMIC_COUNTERS = 0x92D5
+ MAX_FRAGMENT_ATOMIC_COUNTERS = 0x92D6
+ MAX_COMBINED_ATOMIC_COUNTERS = 0x92D7
+ MAX_ATOMIC_COUNTER_BUFFER_SIZE = 0x92D8
+ ACTIVE_ATOMIC_COUNTER_BUFFERS = 0x92D9
+ UNIFORM_ATOMIC_COUNTER_BUFFER_INDEX = 0x92DA
+ UNSIGNED_INT_ATOMIC_COUNTER = 0x92DB
+ MAX_ATOMIC_COUNTER_BUFFER_BINDINGS = 0x92DC
+ NUM_SAMPLE_COUNTS = 0x9380
+)
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glViewport.xml
+func (gl *GL) Viewport(x, y, width, height int) {
+ C.gl4_2core_glViewport(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// DepthRange specifies the mapping of depth values from normalized device
+// coordinates to window coordinates.
+//
+// Parameter nearVal specifies the mapping of the near clipping plane to window
+// coordinates (defaults to 0), while farVal specifies the mapping of the far
+// clipping plane to window coordinates (defaults to 1).
+//
+// After clipping and division by w, depth coordinates range from -1 to 1,
+// corresponding to the near and far clipping planes. DepthRange specifies a
+// linear mapping of the normalized depth coordinates in this range to window
+// depth coordinates. Regardless of the actual depth buffer implementation,
+// window coordinate depth values are treated as though they range from 0 through 1
+// (like color components). Thus, the values accepted by DepthRange are both
+// clamped to this range before they are accepted.
+//
+// The default setting of (0, 1) maps the near plane to 0 and the far plane to 1.
+// With this mapping, the depth buffer range is fully utilized.
+//
+// It is not necessary that nearVal be less than farVal. Reverse mappings such as
+// nearVal 1, and farVal 0 are acceptable.
+//
+// GL.INVALID_OPERATION is generated if DepthRange is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) DepthRange(nearVal, farVal float64) {
+ C.gl4_2core_glDepthRange(gl.funcs, C.GLdouble(nearVal), C.GLdouble(farVal))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsEnabled.xml
+func (gl *GL) IsEnabled(cap glbase.Enum) bool {
+ glresult := C.gl4_2core_glIsEnabled(gl.funcs, C.GLenum(cap))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexLevelParameteriv.xml
+func (gl *GL) GetTexLevelParameteriv(target glbase.Enum, level int, pname glbase.Enum, params []int32) {
+ C.gl4_2core_glGetTexLevelParameteriv(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexLevelParameterfv.xml
+func (gl *GL) GetTexLevelParameterfv(target glbase.Enum, level int, pname glbase.Enum, params []float32) {
+ C.gl4_2core_glGetTexLevelParameterfv(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexParameteriv.xml
+func (gl *GL) GetTexParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl4_2core_glGetTexParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexParameterfv.xml
+func (gl *GL) GetTexParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl4_2core_glGetTexParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexImage.xml
+func (gl *GL) GetTexImage(target glbase.Enum, level int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2core_glGetTexImage(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetIntegerv.xml
+func (gl *GL) GetIntegerv(pname glbase.Enum, params []int32) {
+ C.gl4_2core_glGetIntegerv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetFloatv.xml
+func (gl *GL) GetFloatv(pname glbase.Enum, params []float32) {
+ C.gl4_2core_glGetFloatv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetError.xml
+func (gl *GL) GetError() glbase.Enum {
+ glresult := C.gl4_2core_glGetError(gl.funcs)
+ return glbase.Enum(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetDoublev.xml
+func (gl *GL) GetDoublev(pname glbase.Enum, params []float64) {
+ C.gl4_2core_glGetDoublev(gl.funcs, C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetBooleanv.xml
+func (gl *GL) GetBooleanv(pname glbase.Enum, params []bool) {
+ C.gl4_2core_glGetBooleanv(gl.funcs, C.GLenum(pname), (*C.GLboolean)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glReadPixels.xml
+func (gl *GL) ReadPixels(x, y, width, height int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2core_glReadPixels(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glReadBuffer.xml
+func (gl *GL) ReadBuffer(mode glbase.Enum) {
+ C.gl4_2core_glReadBuffer(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPixelStorei.xml
+func (gl *GL) PixelStorei(pname glbase.Enum, param int32) {
+ C.gl4_2core_glPixelStorei(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPixelStoref.xml
+func (gl *GL) PixelStoref(pname glbase.Enum, param float32) {
+ C.gl4_2core_glPixelStoref(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDepthFunc.xml
+func (gl *GL) DepthFunc(glfunc glbase.Enum) {
+ C.gl4_2core_glDepthFunc(gl.funcs, C.GLenum(glfunc))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glStencilOp.xml
+func (gl *GL) StencilOp(fail, zfail, zpass glbase.Enum) {
+ C.gl4_2core_glStencilOp(gl.funcs, C.GLenum(fail), C.GLenum(zfail), C.GLenum(zpass))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glStencilFunc.xml
+func (gl *GL) StencilFunc(glfunc glbase.Enum, ref int32, mask uint32) {
+ C.gl4_2core_glStencilFunc(gl.funcs, C.GLenum(glfunc), C.GLint(ref), C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLogicOp.xml
+func (gl *GL) LogicOp(opcode glbase.Enum) {
+ C.gl4_2core_glLogicOp(gl.funcs, C.GLenum(opcode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendFunc.xml
+func (gl *GL) BlendFunc(sfactor, dfactor glbase.Enum) {
+ C.gl4_2core_glBlendFunc(gl.funcs, C.GLenum(sfactor), C.GLenum(dfactor))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFlush.xml
+func (gl *GL) Flush() {
+ C.gl4_2core_glFlush(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFinish.xml
+func (gl *GL) Finish() {
+ C.gl4_2core_glFinish(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEnable.xml
+func (gl *GL) Enable(cap glbase.Enum) {
+ C.gl4_2core_glEnable(gl.funcs, C.GLenum(cap))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDisable.xml
+func (gl *GL) Disable(cap glbase.Enum) {
+ C.gl4_2core_glDisable(gl.funcs, C.GLenum(cap))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDepthMask.xml
+func (gl *GL) DepthMask(flag bool) {
+ C.gl4_2core_glDepthMask(gl.funcs, *(*C.GLboolean)(unsafe.Pointer(&flag)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorMask.xml
+func (gl *GL) ColorMask(red, green, blue, alpha bool) {
+ C.gl4_2core_glColorMask(gl.funcs, *(*C.GLboolean)(unsafe.Pointer(&red)), *(*C.GLboolean)(unsafe.Pointer(&green)), *(*C.GLboolean)(unsafe.Pointer(&blue)), *(*C.GLboolean)(unsafe.Pointer(&alpha)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glStencilMask.xml
+func (gl *GL) StencilMask(mask uint32) {
+ C.gl4_2core_glStencilMask(gl.funcs, C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearDepth.xml
+func (gl *GL) ClearDepth(depth float64) {
+ C.gl4_2core_glClearDepth(gl.funcs, C.GLdouble(depth))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearStencil.xml
+func (gl *GL) ClearStencil(s int32) {
+ C.gl4_2core_glClearStencil(gl.funcs, C.GLint(s))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearColor.xml
+func (gl *GL) ClearColor(red, green, blue, alpha float32) {
+ C.gl4_2core_glClearColor(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClear.xml
+func (gl *GL) Clear(mask glbase.Bitfield) {
+ C.gl4_2core_glClear(gl.funcs, C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawBuffer.xml
+func (gl *GL) DrawBuffer(mode glbase.Enum) {
+ C.gl4_2core_glDrawBuffer(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexImage2D.xml
+func (gl *GL) TexImage2D(target glbase.Enum, level int, internalFormat int32, width, height, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2core_glTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexImage1D.xml
+func (gl *GL) TexImage1D(target glbase.Enum, level int, internalFormat int32, width, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2core_glTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexParameteriv.xml
+func (gl *GL) TexParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl4_2core_glTexParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexParameteri.xml
+func (gl *GL) TexParameteri(target, pname glbase.Enum, param int32) {
+ C.gl4_2core_glTexParameteri(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexParameterfv.xml
+func (gl *GL) TexParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl4_2core_glTexParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexParameterf.xml
+func (gl *GL) TexParameterf(target, pname glbase.Enum, param float32) {
+ C.gl4_2core_glTexParameterf(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glScissor.xml
+func (gl *GL) Scissor(x, y, width, height int) {
+ C.gl4_2core_glScissor(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPolygonMode.xml
+func (gl *GL) PolygonMode(face, mode glbase.Enum) {
+ C.gl4_2core_glPolygonMode(gl.funcs, C.GLenum(face), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPointSize.xml
+func (gl *GL) PointSize(size float32) {
+ C.gl4_2core_glPointSize(gl.funcs, C.GLfloat(size))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLineWidth.xml
+func (gl *GL) LineWidth(width float32) {
+ C.gl4_2core_glLineWidth(gl.funcs, C.GLfloat(width))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glHint.xml
+func (gl *GL) Hint(target, mode glbase.Enum) {
+ C.gl4_2core_glHint(gl.funcs, C.GLenum(target), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFrontFace.xml
+func (gl *GL) FrontFace(mode glbase.Enum) {
+ C.gl4_2core_glFrontFace(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCullFace.xml
+func (gl *GL) CullFace(mode glbase.Enum) {
+ C.gl4_2core_glCullFace(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIndexubv.xml
+func (gl *GL) Indexubv(c []uint8) {
+ C.gl4_2core_glIndexubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIndexub.xml
+func (gl *GL) Indexub(c uint8) {
+ C.gl4_2core_glIndexub(gl.funcs, C.GLubyte(c))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsTexture.xml
+func (gl *GL) IsTexture(texture glbase.Texture) bool {
+ glresult := C.gl4_2core_glIsTexture(gl.funcs, C.GLuint(texture))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// GenTextures returns n texture names in textures. There is no guarantee
+// that the names form a contiguous set of integers; however, it is
+// guaranteed that none of the returned names was in use immediately before
+// the call to GenTextures.
+//
+// The generated textures have no dimensionality; they assume the
+// dimensionality of the texture target to which they are first bound (see
+// BindTexture).
+//
+// Texture names returned by a call to GenTextures are not returned by
+// subsequent calls, unless they are first deleted with DeleteTextures.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// GenTextures is available in GL version 2.0 or greater.
+func (gl *GL) GenTextures(n int) []glbase.Texture {
+ if n == 0 {
+ return nil
+ }
+ textures := make([]glbase.Texture, n)
+ C.gl4_2core_glGenTextures(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])))
+ return textures
+}
+
+// DeleteTextures deletes the textures objects whose names are stored
+// in the textures slice. After a texture is deleted, it has no contents or
+// dimensionality, and its name is free for reuse (for example by
+// GenTextures). If a texture that is currently bound is deleted, the binding
+// reverts to 0 (the default texture).
+//
+// DeleteTextures silently ignores 0's and names that do not correspond to
+// existing textures.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// DeleteTextures is available in GL version 2.0 or greater.
+func (gl *GL) DeleteTextures(textures []glbase.Texture) {
+ n := len(textures)
+ if n == 0 {
+ return
+ }
+ C.gl4_2core_glDeleteTextures(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindTexture.xml
+func (gl *GL) BindTexture(target glbase.Enum, texture glbase.Texture) {
+ C.gl4_2core_glBindTexture(gl.funcs, C.GLenum(target), C.GLuint(texture))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexSubImage2D.xml
+func (gl *GL) TexSubImage2D(target glbase.Enum, level, xoffset, yoffset, width, height int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2core_glTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexSubImage1D.xml
+func (gl *GL) TexSubImage1D(target glbase.Enum, level, xoffset, width int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2core_glTexSubImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLsizei(width), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyTexSubImage2D.xml
+func (gl *GL) CopyTexSubImage2D(target glbase.Enum, level, xoffset, yoffset, x, y, width, height int) {
+ C.gl4_2core_glCopyTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyTexSubImage1D.xml
+func (gl *GL) CopyTexSubImage1D(target glbase.Enum, level, xoffset, x, y, width int) {
+ C.gl4_2core_glCopyTexSubImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(x), C.GLint(y), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyTexImage2D.xml
+func (gl *GL) CopyTexImage2D(target glbase.Enum, level int, internalFormat glbase.Enum, x, y, width, height, border int) {
+ C.gl4_2core_glCopyTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height), C.GLint(border))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyTexImage1D.xml
+func (gl *GL) CopyTexImage1D(target glbase.Enum, level int, internalFormat glbase.Enum, x, y, width, border int) {
+ C.gl4_2core_glCopyTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLint(border))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPolygonOffset.xml
+func (gl *GL) PolygonOffset(factor, units float32) {
+ C.gl4_2core_glPolygonOffset(gl.funcs, C.GLfloat(factor), C.GLfloat(units))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawElements.xml
+func (gl *GL) DrawElements(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2core_glDrawElements(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawArrays.xml
+func (gl *GL) DrawArrays(mode glbase.Enum, first, count int) {
+ C.gl4_2core_glDrawArrays(gl.funcs, C.GLenum(mode), C.GLint(first), C.GLsizei(count))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyTexSubImage3D.xml
+func (gl *GL) CopyTexSubImage3D(target glbase.Enum, level, xoffset, yoffset int, zoffset int32, x, y, width, height int) {
+ C.gl4_2core_glCopyTexSubImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(zoffset), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexSubImage3D.xml
+func (gl *GL) TexSubImage3D(target glbase.Enum, level, xoffset, yoffset int, zoffset int32, width, height int, depth int32, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2core_glTexSubImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(zoffset), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexImage3D.xml
+func (gl *GL) TexImage3D(target glbase.Enum, level int, internalFormat int32, width, height int, depth int32, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2core_glTexImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawRangeElements.xml
+func (gl *GL) DrawRangeElements(mode glbase.Enum, start, end uint32, count int, gltype glbase.Enum, indices interface{}) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2core_glDrawRangeElements(gl.funcs, C.GLenum(mode), C.GLuint(start), C.GLuint(end), C.GLsizei(count), C.GLenum(gltype), indices_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendEquation.xml
+func (gl *GL) BlendEquation(mode glbase.Enum) {
+ C.gl4_2core_glBlendEquation(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendColor.xml
+func (gl *GL) BlendColor(red, green, blue, alpha float32) {
+ C.gl4_2core_glBlendColor(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetCompressedTexImage.xml
+func (gl *GL) GetCompressedTexImage(target glbase.Enum, level int, img interface{}) {
+ var img_ptr unsafe.Pointer
+ var img_v = reflect.ValueOf(img)
+ if img != nil && img_v.Kind() != reflect.Slice {
+ panic("parameter img must be a slice")
+ }
+ if img != nil {
+ img_ptr = unsafe.Pointer(img_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2core_glGetCompressedTexImage(gl.funcs, C.GLenum(target), C.GLint(level), img_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCompressedTexSubImage1D.xml
+func (gl *GL) CompressedTexSubImage1D(target glbase.Enum, level, xoffset, width int, format glbase.Enum, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2core_glCompressedTexSubImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLsizei(width), C.GLenum(format), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCompressedTexSubImage2D.xml
+func (gl *GL) CompressedTexSubImage2D(target glbase.Enum, level, xoffset, yoffset, width, height int, format glbase.Enum, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2core_glCompressedTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCompressedTexSubImage3D.xml
+func (gl *GL) CompressedTexSubImage3D(target glbase.Enum, level, xoffset, yoffset int, zoffset int32, width, height int, depth int32, format glbase.Enum, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2core_glCompressedTexSubImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(zoffset), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLenum(format), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCompressedTexImage1D.xml
+func (gl *GL) CompressedTexImage1D(target glbase.Enum, level int, internalFormat glbase.Enum, width, border, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2core_glCompressedTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLsizei(width), C.GLint(border), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCompressedTexImage2D.xml
+func (gl *GL) CompressedTexImage2D(target glbase.Enum, level int, internalFormat glbase.Enum, width, height, border, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2core_glCompressedTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLint(border), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCompressedTexImage3D.xml
+func (gl *GL) CompressedTexImage3D(target glbase.Enum, level int, internalFormat glbase.Enum, width, height int, depth int32, border, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2core_glCompressedTexImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLint(border), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSampleCoverage.xml
+func (gl *GL) SampleCoverage(value float32, invert bool) {
+ C.gl4_2core_glSampleCoverage(gl.funcs, C.GLfloat(value), *(*C.GLboolean)(unsafe.Pointer(&invert)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glActiveTexture.xml
+func (gl *GL) ActiveTexture(texture glbase.Enum) {
+ C.gl4_2core_glActiveTexture(gl.funcs, C.GLenum(texture))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPointParameteriv.xml
+func (gl *GL) PointParameteriv(pname glbase.Enum, params []int32) {
+ C.gl4_2core_glPointParameteriv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPointParameteri.xml
+func (gl *GL) PointParameteri(pname glbase.Enum, param int32) {
+ C.gl4_2core_glPointParameteri(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPointParameterfv.xml
+func (gl *GL) PointParameterfv(pname glbase.Enum, params []float32) {
+ C.gl4_2core_glPointParameterfv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPointParameterf.xml
+func (gl *GL) PointParameterf(pname glbase.Enum, param float32) {
+ C.gl4_2core_glPointParameterf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiDrawArrays.xml
+func (gl *GL) MultiDrawArrays(mode glbase.Enum, first, count []int, drawcount int32) {
+ C.gl4_2core_glMultiDrawArrays(gl.funcs, C.GLenum(mode), (*C.GLint)(unsafe.Pointer(&first[0])), (*C.GLsizei)(unsafe.Pointer(&count[0])), C.GLsizei(drawcount))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendFuncSeparate.xml
+func (gl *GL) BlendFuncSeparate(sfactorRGB, dfactorRGB, sfactorAlpha, dfactorAlpha glbase.Enum) {
+ C.gl4_2core_glBlendFuncSeparate(gl.funcs, C.GLenum(sfactorRGB), C.GLenum(dfactorRGB), C.GLenum(sfactorAlpha), C.GLenum(dfactorAlpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetBufferParameteriv.xml
+func (gl *GL) GetBufferParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl4_2core_glGetBufferParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUnmapBuffer.xml
+func (gl *GL) UnmapBuffer(target glbase.Enum) bool {
+ glresult := C.gl4_2core_glUnmapBuffer(gl.funcs, C.GLenum(target))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetBufferSubData.xml
+func (gl *GL) GetBufferSubData(target glbase.Enum, offset, size int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2core_glGetBufferSubData(gl.funcs, C.GLenum(target), C.GLintptr(offset), C.GLsizeiptr(size), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBufferSubData.xml
+func (gl *GL) BufferSubData(target glbase.Enum, offset, size int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2core_glBufferSubData(gl.funcs, C.GLenum(target), C.GLintptr(offset), C.GLsizeiptr(size), data_ptr)
+}
+
+// BufferData creates a new data store for the buffer object currently
+// bound to target. Any pre-existing data store is deleted. The new data
+// store is created with the specified size in bytes and usage. If data is
+// not nil, it must be a slice that is used to initialize the data store.
+// In that case the size parameter is ignored and the store size will match
+// the slice data size.
+//
+// In its initial state, the new data store is not mapped, it has a NULL
+// mapped pointer, and its mapped access is GL.READ_WRITE.
+//
+// The target constant must be one of GL.ARRAY_BUFFER, GL.COPY_READ_BUFFER,
+// GL.COPY_WRITE_BUFFER, GL.ELEMENT_ARRAY_BUFFER, GL.PIXEL_PACK_BUFFER,
+// GL.PIXEL_UNPACK_BUFFER, GL.TEXTURE_BUFFER, GL.TRANSFORM_FEEDBACK_BUFFER,
+// or GL.UNIFORM_BUFFER.
+//
+// The usage parameter is a hint to the GL implementation as to how a buffer
+// object's data store will be accessed. This enables the GL implementation
+// to make more intelligent decisions that may significantly impact buffer
+// object performance. It does not, however, constrain the actual usage of
+// the data store. usage can be broken down into two parts: first, the
+// frequency of access (modification and usage), and second, the nature of
+// that access.
+//
+// A usage frequency of STREAM and nature of DRAW is specified via the
+// constant GL.STREAM_DRAW, for example.
+//
+// The usage frequency of access may be one of:
+//
+// STREAM
+// The data store contents will be modified once and used at most a few times.
+//
+// STATIC
+// The data store contents will be modified once and used many times.
+//
+// DYNAMIC
+// The data store contents will be modified repeatedly and used many times.
+//
+// The usage nature of access may be one of:
+//
+// DRAW
+// The data store contents are modified by the application, and used as
+// the source for GL drawing and image specification commands.
+//
+// READ
+// The data store contents are modified by reading data from the GL,
+// and used to return that data when queried by the application.
+//
+// COPY
+// The data store contents are modified by reading data from the GL,
+// and used as the source for GL drawing and image specification
+// commands.
+//
+// Clients must align data elements consistent with the requirements of the
+// client platform, with an additional base-level requirement that an offset
+// within a buffer to a datum comprising N bytes be a multiple of N.
+//
+// Error GL.INVALID_ENUM is generated if target is not one of the accepted
+// buffer targets. GL.INVALID_ENUM is generated if usage is not
+// GL.STREAM_DRAW, GL.STREAM_READ, GL.STREAM_COPY, GL.STATIC_DRAW,
+// GL.STATIC_READ, GL.STATIC_COPY, GL.DYNAMIC_DRAW, GL.DYNAMIC_READ, or
+// GL.DYNAMIC_COPY. GL.INVALID_VALUE is generated if size is negative.
+// GL.INVALID_OPERATION is generated if the reserved buffer object name 0 is
+// bound to target. GL.OUT_OF_MEMORY is generated if the GL is unable to
+// create a data store with the specified size.
+func (gl *GL) BufferData(target glbase.Enum, size int, data interface{}, usage glbase.Enum) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ if data != nil {
+ size = int(data_v.Type().Size()) * data_v.Len()
+ }
+ C.gl4_2core_glBufferData(gl.funcs, C.GLenum(target), C.GLsizeiptr(size), data_ptr, C.GLenum(usage))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsBuffer.xml
+func (gl *GL) IsBuffer(buffer glbase.Buffer) bool {
+ glresult := C.gl4_2core_glIsBuffer(gl.funcs, C.GLuint(buffer))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// GenBuffers returns n buffer object names. There is no guarantee that
+// the names form a contiguous set of integers; however, it is guaranteed
+// that none of the returned names was in use immediately before the call to
+// GenBuffers.
+//
+// Buffer object names returned by a call to GenBuffers are not returned by
+// subsequent calls, unless they are first deleted with DeleteBuffers.
+//
+// No buffer objects are associated with the returned buffer object names
+// until they are first bound by calling BindBuffer.
+//
+// Error GL.INVALID_VALUE is generated if n is negative. GL.INVALID_OPERATION
+// is generated if GenBuffers is executed between the execution of Begin
+// and the corresponding execution of End.
+//
+// GenBuffers is available in GL version 1.5 or greater.
+func (gl *GL) GenBuffers(n int) []glbase.Buffer {
+ if n == 0 {
+ return nil
+ }
+ buffers := make([]glbase.Buffer, n)
+ C.gl4_2core_glGenBuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&buffers[0])))
+ return buffers
+}
+
+// DeleteBuffers deletes the buffer objects whose names are stored in the
+// buffers slice.
+//
+// After a buffer object is deleted, it has no contents, and its name is free
+// for reuse (for example by GenBuffers). If a buffer object that is
+// currently bound is deleted, the binding reverts to 0 (the absence of any
+// buffer object, which reverts to client memory usage).
+//
+// DeleteBuffers silently ignores 0's and names that do not correspond to
+// existing buffer objects.
+//
+// Error GL.INVALID_VALUE is generated if n is negative. GL.INVALID_OPERATION
+// is generated if DeleteBuffers is executed between the execution of Begin
+// and the corresponding execution of End.
+//
+// DeleteBuffers is available in GL version 1.5 or greater.
+func (gl *GL) DeleteBuffers(buffers []glbase.Buffer) {
+ n := len(buffers)
+ if n == 0 {
+ return
+ }
+ C.gl4_2core_glDeleteBuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&buffers[0])))
+}
+
+// BindBuffer creates or puts in use a named buffer object.
+// Calling BindBuffer with target set to GL.ARRAY_BUFFER,
+// GL.ELEMENT_ARRAY_BUFFER, GL.PIXEL_PACK_BUFFER or GL.PIXEL_UNPACK_BUFFER
+// and buffer set to the name of the new buffer object binds the buffer
+// object name to the target. When a buffer object is bound to a target, the
+// previous binding for that target is automatically broken.
+//
+// Buffer object names are unsigned integers. The value zero is reserved, but
+// there is no default buffer object for each buffer object target. Instead,
+// buffer set to zero effectively unbinds any buffer object previously bound,
+// and restores client memory usage for that buffer object target. Buffer
+// object names and the corresponding buffer object contents are local to the
+// shared display-list space (see XCreateContext) of the current GL rendering
+// context; two rendering contexts share buffer object names only if they
+// also share display lists.
+//
+// GenBuffers may be called to generate a set of new buffer object names.
+//
+// The state of a buffer object immediately after it is first bound is an
+// unmapped zero-sized memory buffer with GL.READ_WRITE access and
+// GL.STATIC_DRAW usage.
+//
+// While a non-zero buffer object name is bound, GL operations on the target
+// to which it is bound affect the bound buffer object, and queries of the
+// target to which it is bound return state from the bound buffer object.
+// While buffer object name zero is bound, as in the initial state, attempts
+// to modify or query state on the target to which it is bound generates an
+// GL.INVALID_OPERATION error.
+//
+// When vertex array pointer state is changed, for example by a call to
+// NormalPointer, the current buffer object binding (GL.ARRAY_BUFFER_BINDING)
+// is copied into the corresponding client state for the vertex array type
+// being changed, for example GL.NORMAL_ARRAY_BUFFER_BINDING. While a
+// non-zero buffer object is bound to the GL.ARRAY_BUFFER target, the vertex
+// array pointer parameter that is traditionally interpreted as a pointer to
+// client-side memory is instead interpreted as an offset within the buffer
+// object measured in basic machine units.
+//
+// While a non-zero buffer object is bound to the GL.ELEMENT_ARRAY_BUFFER
+// target, the indices parameter of DrawElements, DrawRangeElements, or
+// MultiDrawElements that is traditionally interpreted as a pointer to
+// client-side memory is instead interpreted as an offset within the buffer
+// object measured in basic machine units.
+//
+// While a non-zero buffer object is bound to the GL.PIXEL_PACK_BUFFER
+// target, the following commands are affected: GetCompressedTexImage,
+// GetConvolutionFilter, GetHistogram, GetMinmax, GetPixelMap,
+// GetPolygonStipple, GetSeparableFilter, GetTexImage, and ReadPixels. The
+// pointer parameter that is traditionally interpreted as a pointer to
+// client-side memory where the pixels are to be packed is instead
+// interpreted as an offset within the buffer object measured in basic
+// machine units.
+//
+// While a non-zero buffer object is bound to the GL.PIXEL_UNPACK_BUFFER
+// target, the following commands are affected: Bitmap, ColorSubTable,
+// ColorTable, CompressedTexImage1D, CompressedTexImage2D,
+// CompressedTexImage3D, CompressedTexSubImage1D, CompressedTexSubImage2D,
+// CompressedTexSubImage3D, ConvolutionFilter1D, ConvolutionFilter2D,
+// DrawPixels, PixelMap, PolygonStipple, SeparableFilter2D, TexImage1D,
+// TexImage2D, TexImage3D, TexSubImage1D, TexSubImage2D, and TexSubImage3D.
+// The pointer parameter that is traditionally interpreted as a pointer to
+// client-side memory from which the pixels are to be unpacked is instead
+// interpreted as an offset within the buffer object measured in basic
+// machine units.
+//
+// A buffer object binding created with BindBuffer remains active until a
+// different buffer object name is bound to the same target, or until the
+// bound buffer object is deleted with DeleteBuffers.
+//
+// Once created, a named buffer object may be re-bound to any target as often
+// as needed. However, the GL implementation may make choices about how to
+// optimize the storage of a buffer object based on its initial binding
+// target.
+//
+// Error GL.INVALID_ENUM is generated if target is not one of the allowable
+// values. GL.INVALID_OPERATION is generated if BindBuffer is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// BindBuffer is available in GL version 1.5 or greater.
+func (gl *GL) BindBuffer(target glbase.Enum, buffer glbase.Buffer) {
+ C.gl4_2core_glBindBuffer(gl.funcs, C.GLenum(target), C.GLuint(buffer))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetQueryObjectuiv.xml
+func (gl *GL) GetQueryObjectuiv(id uint32, pname glbase.Enum, params []uint32) {
+ C.gl4_2core_glGetQueryObjectuiv(gl.funcs, C.GLuint(id), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetQueryObjectiv.xml
+func (gl *GL) GetQueryObjectiv(id uint32, pname glbase.Enum, params []int32) {
+ C.gl4_2core_glGetQueryObjectiv(gl.funcs, C.GLuint(id), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetQueryiv.xml
+func (gl *GL) GetQueryiv(target, pname glbase.Enum, params []int32) {
+ C.gl4_2core_glGetQueryiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEndQuery.xml
+func (gl *GL) EndQuery(target glbase.Enum) {
+ C.gl4_2core_glEndQuery(gl.funcs, C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBeginQuery.xml
+func (gl *GL) BeginQuery(target glbase.Enum, id uint32) {
+ C.gl4_2core_glBeginQuery(gl.funcs, C.GLenum(target), C.GLuint(id))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsQuery.xml
+func (gl *GL) IsQuery(id uint32) bool {
+ glresult := C.gl4_2core_glIsQuery(gl.funcs, C.GLuint(id))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDeleteQueries.xml
+func (gl *GL) DeleteQueries(n int, ids []uint32) {
+ C.gl4_2core_glDeleteQueries(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&ids[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGenQueries.xml
+func (gl *GL) GenQueries(n int, ids []uint32) {
+ C.gl4_2core_glGenQueries(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&ids[0])))
+}
+
+// VertexAttribPointer specifies the location and data format of the array
+// of generic vertex attributes at index to use when rendering. size
+// specifies the number of components per attribute and must be 1, 2, 3, or
+// 4. type specifies the data type of each component, and stride specifies
+// the byte stride from one attribute to the next, allowing vertices and
+// attributes to be packed into a single array or stored in separate arrays.
+// normalized indicates whether the values stored in an integer format are
+// to be mapped to the range [-1,1] (for signed values) or [0,1]
+// (for unsigned values) when they are accessed and converted to floating
+// point; otherwise, values will be converted to floats directly without
+// normalization. offset is a byte offset into the buffer object's data
+// store, which must be bound to the GL.ARRAY_BUFFER target with BindBuffer.
+//
+// The buffer object binding (GL.ARRAY_BUFFER_BINDING) is saved as
+// generic vertex attribute array client-side state
+// (GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING) for the provided index.
+//
+// To enable and disable a generic vertex attribute array, call
+// EnableVertexAttribArray and DisableVertexAttribArray with index. If
+// enabled, the generic vertex attribute array is used when DrawArrays or
+// DrawElements is called. Each generic vertex attribute array is initially
+// disabled.
+//
+// VertexAttribPointer is typically implemented on the client side.
+//
+// Error GL.INVALID_ENUM is generated if type is not an accepted value.
+// GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_VALUE is generated if size is not 1, 2,
+// 3, or 4. GL.INVALID_VALUE is generated if stride is negative.
+func (gl *GL) VertexAttribPointer(index glbase.Attrib, size int, gltype glbase.Enum, normalized bool, stride int, offset uintptr) {
+ offset_ptr := unsafe.Pointer(offset)
+ C.gl4_2core_glVertexAttribPointer(gl.funcs, C.GLuint(index), C.GLint(size), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), C.GLsizei(stride), offset_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glValidateProgram.xml
+func (gl *GL) ValidateProgram(program glbase.Program) {
+ C.gl4_2core_glValidateProgram(gl.funcs, C.GLuint(program))
+}
+
+// UniformMatrix4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix4fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(4*4) != 0 {
+ panic("invalid value length for UniformMatrix4fv")
+ }
+ count := len(value) / (4 * 4)
+ C.gl4_2core_glUniformMatrix4fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix3fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(3*3) != 0 {
+ panic("invalid value length for UniformMatrix3fv")
+ }
+ count := len(value) / (3 * 3)
+ C.gl4_2core_glUniformMatrix3fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix2fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(2*2) != 0 {
+ panic("invalid value length for UniformMatrix2fv")
+ }
+ count := len(value) / (2 * 2)
+ C.gl4_2core_glUniformMatrix2fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform4iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%4 != 0 {
+ panic("invalid value length for Uniform4iv")
+ }
+ count := len(value) / 4
+ C.gl4_2core_glUniform4iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform3iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform3iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%3 != 0 {
+ panic("invalid value length for Uniform3iv")
+ }
+ count := len(value) / 3
+ C.gl4_2core_glUniform3iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform2iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform2iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%2 != 0 {
+ panic("invalid value length for Uniform2iv")
+ }
+ count := len(value) / 2
+ C.gl4_2core_glUniform2iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform1iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform1iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ count := len(value)
+ C.gl4_2core_glUniform1iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%4 != 0 {
+ panic("invalid value length for Uniform4fv")
+ }
+ count := len(value) / 4
+ C.gl4_2core_glUniform4fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%3 != 0 {
+ panic("invalid value length for Uniform3fv")
+ }
+ count := len(value) / 3
+ C.gl4_2core_glUniform3fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%2 != 0 {
+ panic("invalid value length for Uniform2fv")
+ }
+ count := len(value) / 2
+ C.gl4_2core_glUniform2fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform1fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform1fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ count := len(value)
+ C.gl4_2core_glUniform1fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform4i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4i(location glbase.Uniform, v0, v1, v2, v3 int32) {
+ C.gl4_2core_glUniform4i(gl.funcs, C.GLint(location), C.GLint(v0), C.GLint(v1), C.GLint(v2), C.GLint(v3))
+}
+
+// Uniform3i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform3i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3i(location glbase.Uniform, v0, v1, v2 int32) {
+ C.gl4_2core_glUniform3i(gl.funcs, C.GLint(location), C.GLint(v0), C.GLint(v1), C.GLint(v2))
+}
+
+// Uniform2i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform2i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2i(location glbase.Uniform, v0, v1 int32) {
+ C.gl4_2core_glUniform2i(gl.funcs, C.GLint(location), C.GLint(v0), C.GLint(v1))
+}
+
+// Uniform1i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform1i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1i(location glbase.Uniform, v0 int32) {
+ C.gl4_2core_glUniform1i(gl.funcs, C.GLint(location), C.GLint(v0))
+}
+
+// Uniform4f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform4f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4f(location glbase.Uniform, v0, v1, v2, v3 float32) {
+ C.gl4_2core_glUniform4f(gl.funcs, C.GLint(location), C.GLfloat(v0), C.GLfloat(v1), C.GLfloat(v2), C.GLfloat(v3))
+}
+
+// Uniform3f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform3f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3f(location glbase.Uniform, v0, v1, v2 float32) {
+ C.gl4_2core_glUniform3f(gl.funcs, C.GLint(location), C.GLfloat(v0), C.GLfloat(v1), C.GLfloat(v2))
+}
+
+// Uniform2f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform2f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2f(location glbase.Uniform, v0, v1 float32) {
+ C.gl4_2core_glUniform2f(gl.funcs, C.GLint(location), C.GLfloat(v0), C.GLfloat(v1))
+}
+
+// Uniform1f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform1f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1f(location glbase.Uniform, v0 float32) {
+ C.gl4_2core_glUniform1f(gl.funcs, C.GLint(location), C.GLfloat(v0))
+}
+
+// UseProgram installs the program object specified by program as part of
+// current rendering state. One or more executables are created in a program
+// object by successfully attaching shader objects to it with AttachShader,
+// successfully compiling the shader objects with CompileShader, and
+// successfully linking the program object with LinkProgram.
+//
+// A program object will contain an executable that will run on the vertex
+// processor if it contains one or more shader objects of type
+// GL.VERTEX_SHADER that have been successfully compiled and linked.
+// Similarly, a program object will contain an executable that will run on
+// the fragment processor if it contains one or more shader objects of type
+// GL.FRAGMENT_SHADER that have been successfully compiled and linked.
+//
+// Successfully installing an executable on a programmable processor will
+// cause the corresponding fixed functionality of OpenGL to be disabled.
+// Specifically, if an executable is installed on the vertex processor, the
+// OpenGL fixed functionality will be disabled as follows.
+//
+// - The modelview matrix is not applied to vertex coordinates.
+//
+// - The projection matrix is not applied to vertex coordinates.
+//
+// - The texture matrices are not applied to texture coordinates.
+//
+// - Normals are not transformed to eye coordinates.
+//
+// - Normals are not rescaled or normalized.
+//
+// - Normalization of GL.AUTO_NORMAL evaluated normals is not performed.
+//
+// - Texture coordinates are not generated automatically.
+//
+// - Per-vertex lighting is not performed.
+//
+// - Color material computations are not performed.
+//
+// - Color index lighting is not performed.
+//
+// - This list also applies when setting the current raster position.
+//
+// The executable that is installed on the vertex processor is expected to
+// implement any or all of the desired functionality from the preceding list.
+// Similarly, if an executable is installed on the fragment processor, the
+// OpenGL fixed functionality will be disabled as follows.
+//
+// - Texture environment and texture functions are not applied.
+//
+// - Texture application is not applied.
+//
+// - Color sum is not applied.
+//
+// - Fog is not applied.
+//
+// Again, the fragment shader that is installed is expected to implement any
+// or all of the desired functionality from the preceding list.
+//
+// While a program object is in use, applications are free to modify attached
+// shader objects, compile attached shader objects, attach additional shader
+// objects, and detach or delete shader objects. None of these operations
+// will affect the executables that are part of the current state. However,
+// relinking the program object that is currently in use will install the
+// program object as part of the current rendering state if the link
+// operation was successful (see LinkProgram). If the program object
+// currently in use is relinked unsuccessfully, its link status will be set
+// to GL.FALSE, but the executables and associated state will remain part of
+// the current state until a subsequent call to UseProgram removes it from
+// use. After it is removed from use, it cannot be made part of current state
+// until it has been successfully relinked.
+//
+// If program contains shader objects of type GL.VERTEX_SHADER but it does
+// not contain shader objects of type GL.FRAGMENT_SHADER, an executable will
+// be installed on the vertex processor, but fixed functionality will be used
+// for fragment processing. Similarly, if program contains shader objects of
+// type GL.FRAGMENT_SHADER but it does not contain shader objects of type
+// GL.VERTEX_SHADER, an executable will be installed on the fragment
+// processor, but fixed functionality will be used for vertex processing. If
+// program is 0, the programmable processors will be disabled, and fixed
+// functionality will be used for both vertex and fragment processing.
+//
+// While a program object is in use, the state that controls the disabled
+// fixed functionality may also be updated using the normal OpenGL calls.
+//
+// Like display lists and texture objects, the name space for program objects
+// may be shared across a set of contexts, as long as the server sides of the
+// contexts share the same address space. If the name space is shared across
+// contexts, any attached objects and the data associated with those attached
+// objects are shared as well.
+//
+// Applications are responsible for providing the synchronization across API
+// calls when objects are accessed from different execution threads.
+//
+// Error GL.INVALID_VALUE is generated if program is neither 0 nor a value
+// generated by OpenGL. GL.INVALID_OPERATION is generated if program is not
+// a program object. GL.INVALID_OPERATION is generated if program could not
+// be made part of current state. GL.INVALID_OPERATION is generated if
+// UseProgram is executed between the execution of Begin and the
+// corresponding execution of End.
+//
+// UseProgram is available in GL version 2.0 or greater.
+func (gl *GL) UseProgram(program glbase.Program) {
+ C.gl4_2core_glUseProgram(gl.funcs, C.GLuint(program))
+}
+
+// ShaderSource sets the source code in shader to the provided source code. Any source
+// code previously stored in the shader object is completely replaced.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader is not a shader
+// object. GL.INVALID_VALUE is generated if count is less than 0.
+// GL.INVALID_OPERATION is generated if ShaderSource is executed between the
+// execution of Begin and the corresponding execution of End.
+//
+// ShaderSource is available in GL version 2.0 or greater.
+func (gl *GL) ShaderSource(shader glbase.Shader, source ...string) {
+ count := len(source)
+ length := make([]int32, count)
+ source_c := make([]unsafe.Pointer, count)
+ for i, src := range source {
+ length[i] = int32(len(src))
+ if len(src) > 0 {
+ source_c[i] = *(*unsafe.Pointer)(unsafe.Pointer(&src))
+ } else {
+ source_c[i] = unsafe.Pointer(uintptr(0))
+ }
+ }
+ C.gl4_2core_glShaderSource(gl.funcs, C.GLuint(shader), C.GLsizei(count), (**C.GLchar)(unsafe.Pointer(&source_c[0])), (*C.GLint)(unsafe.Pointer(&length[0])))
+}
+
+// LinkProgram links the program object specified by program. If any shader
+// objects of type GL.VERTEX_SHADER are attached to program, they will be
+// used to create an executable that will run on the programmable vertex
+// processor. If any shader objects of type GL.FRAGMENT_SHADER are attached
+// to program, they will be used to create an executable that will run on the
+// programmable fragment processor.
+//
+// The status of the link operation will be stored as part of the program
+// object's state. This value will be set to GL.TRUE if the program object
+// was linked without errors and is ready for use, and GL.FALSE otherwise. It
+// can be queried by calling GetProgramiv with arguments program and
+// GL.LINK_STATUS.
+//
+// As a result of a successful link operation, all active user-defined
+// uniform variables belonging to program will be initialized to 0, and each
+// of the program object's active uniform variables will be assigned a
+// location that can be queried by calling GetUniformLocation. Also, any
+// active user-defined attribute variables that have not been bound to a
+// generic vertex attribute index will be bound to one at this time.
+//
+// Linking of a program object can fail for a number of reasons as specified
+// in the OpenGL Shading Language Specification. The following lists some of
+// the conditions that will cause a link error.
+//
+// - The number of active attribute variables supported by the
+// implementation has been exceeded.
+//
+// - The storage limit for uniform variables has been exceeded.
+//
+// - The number of active uniform variables supported by the implementation
+// has been exceeded.
+//
+// - The main function is missing for the vertex shader or the fragment
+// shader.
+//
+// - A varying variable actually used in the fragment shader is not
+// declared in the same way (or is not declared at all) in the vertex
+// shader.
+//
+// - A reference to a function or variable name is unresolved.
+//
+// - A shared global is declared with two different types or two different
+// initial values.
+//
+// - One or more of the attached shader objects has not been successfully
+// compiled.
+//
+// - Binding a generic attribute matrix caused some rows of the matrix to
+// fall outside the allowed maximum of GL.MAX_VERTEX_ATTRIBS.
+//
+// - Not enough contiguous vertex attribute slots could be found to bind
+// attribute matrices.
+//
+// When a program object has been successfully linked, the program object can
+// be made part of current state by calling UseProgram. Whether or not the
+// link operation was successful, the program object's information log will
+// be overwritten. The information log can be retrieved by calling
+// GetProgramInfoLog.
+//
+// LinkProgram will also install the generated executables as part of the
+// current rendering state if the link operation was successful and the
+// specified program object is already currently in use as a result of a
+// previous call to UseProgram. If the program object currently in use is
+// relinked unsuccessfully, its link status will be set to GL.FALSE , but the
+// executables and associated state will remain part of the current state
+// until a subsequent call to UseProgram removes it from use. After it is
+// removed from use, it cannot be made part of current state until it has
+// been successfully relinked.
+//
+// If program contains shader objects of type GL.VERTEX_SHADER but does not
+// contain shader objects of type GL.FRAGMENT_SHADER, the vertex shader will
+// be linked against the implicit interface for fixed functionality fragment
+// processing. Similarly, if program contains shader objects of type
+// GL.FRAGMENT_SHADER but it does not contain shader objects of type
+// GL.VERTEX_SHADER, the fragment shader will be linked against the implicit
+// interface for fixed functionality vertex processing.
+//
+// The program object's information log is updated and the program is
+// generated at the time of the link operation. After the link operation,
+// applications are free to modify attached shader objects, compile attached
+// shader objects, detach shader objects, delete shader objects, and attach
+// additional shader objects. None of these operations affects the
+// information log or the program that is part of the program object.
+//
+// If the link operation is unsuccessful, any information about a previous
+// link operation on program is lost (a failed link does not restore the
+// old state of program). Certain information can still be retrieved
+// from program even after an unsuccessful link operation. See for instance
+// GetActiveAttrib and GetActiveUniform.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program
+// object. GL.INVALID_OPERATION is generated if LinkProgram is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// LinkProgram is available in GL version 2.0 or greater.
+func (gl *GL) LinkProgram(program glbase.Program) {
+ C.gl4_2core_glLinkProgram(gl.funcs, C.GLuint(program))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsShader.xml
+func (gl *GL) IsShader(shader glbase.Shader) bool {
+ glresult := C.gl4_2core_glIsShader(gl.funcs, C.GLuint(shader))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsProgram.xml
+func (gl *GL) IsProgram(program glbase.Program) bool {
+ glresult := C.gl4_2core_glIsProgram(gl.funcs, C.GLuint(program))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// GetVertexAttribiv returns in params the value of a generic vertex attribute
+// parameter. The generic vertex attribute to be queried is specified by
+// index, and the parameter to be queried is specified by pname.
+//
+// The accepted parameter names are as follows:
+//
+// GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING
+// params returns a single value, the name of the buffer object
+// currently bound to the binding point corresponding to generic vertex
+// attribute array index. If no buffer object is bound, 0 is returned.
+// The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_ENABLED
+// params returns a single value that is non-zero (true) if the vertex
+// attribute array for index is enabled and 0 (false) if it is
+// disabled. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_SIZE
+// params returns a single value, the size of the vertex attribute
+// array for index. The size is the number of values for each element
+// of the vertex attribute array, and it will be 1, 2, 3, or 4. The
+// initial value is 4.
+//
+// GL.VERTEX_ATTRIB_ARRAY_STRIDE
+// params returns a single value, the array stride for (number of bytes
+// between successive elements in) the vertex attribute array for
+// index. A value of 0 indicates that the array elements are stored
+// sequentially in memory. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_TYPE
+// params returns a single value, a symbolic constant indicating the
+// array type for the vertex attribute array for index. Possible values
+// are GL.BYTE, GL.UNSIGNED_BYTE, GL.SHORT, GL.UNSIGNED_SHORT, GL.INT,
+// GL.UNSIGNED_INT, GL.FLOAT, and GL.DOUBLE. The initial value is
+// GL.FLOAT.
+//
+// GL.VERTEX_ATTRIB_ARRAY_NORMALIZED
+// params returns a single value that is non-zero (true) if fixed-point
+// data types for the vertex attribute array indicated by index are
+// normalized when they are converted to floating point, and 0 (false)
+// otherwise. The initial value is 0.
+//
+// GL.CURRENT_VERTEX_ATTRIB
+// params returns four values that represent the current value for the
+// generic vertex attribute specified by index. Generic vertex
+// attribute 0 is unique in that it has no current state, so an error
+// will be generated if index is 0. The initial value for all other
+// generic vertex attributes is (0,0,0,1).
+//
+// All of the parameters except GL.CURRENT_VERTEX_ATTRIB represent
+// client-side state.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_ENUM is generated if pname is not an
+// accepted value. GL.INVALID_OPERATION is generated if index is 0 and pname
+// is GL.CURRENT_VERTEX_ATTRIB.
+//
+// GetVertexAttribiv is available in GL version 2.0 or greater.
+func (gl *GL) GetVertexAttribiv(index glbase.Attrib, pname glbase.Enum, params []int32) {
+ var params_c [4]int32
+ C.gl4_2core_glGetVertexAttribiv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetVertexAttribfv returns in params the value of a generic vertex attribute
+// parameter. The generic vertex attribute to be queried is specified by
+// index, and the parameter to be queried is specified by pname.
+//
+// The accepted parameter names are as follows:
+//
+// GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING
+// params returns a single value, the name of the buffer object
+// currently bound to the binding point corresponding to generic vertex
+// attribute array index. If no buffer object is bound, 0 is returned.
+// The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_ENABLED
+// params returns a single value that is non-zero (true) if the vertex
+// attribute array for index is enabled and 0 (false) if it is
+// disabled. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_SIZE
+// params returns a single value, the size of the vertex attribute
+// array for index. The size is the number of values for each element
+// of the vertex attribute array, and it will be 1, 2, 3, or 4. The
+// initial value is 4.
+//
+// GL.VERTEX_ATTRIB_ARRAY_STRIDE
+// params returns a single value, the array stride for (number of bytes
+// between successive elements in) the vertex attribute array for
+// index. A value of 0 indicates that the array elements are stored
+// sequentially in memory. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_TYPE
+// params returns a single value, a symbolic constant indicating the
+// array type for the vertex attribute array for index. Possible values
+// are GL.BYTE, GL.UNSIGNED_BYTE, GL.SHORT, GL.UNSIGNED_SHORT, GL.INT,
+// GL.UNSIGNED_INT, GL.FLOAT, and GL.DOUBLE. The initial value is
+// GL.FLOAT.
+//
+// GL.VERTEX_ATTRIB_ARRAY_NORMALIZED
+// params returns a single value that is non-zero (true) if fixed-point
+// data types for the vertex attribute array indicated by index are
+// normalized when they are converted to floating point, and 0 (false)
+// otherwise. The initial value is 0.
+//
+// GL.CURRENT_VERTEX_ATTRIB
+// params returns four values that represent the current value for the
+// generic vertex attribute specified by index. Generic vertex
+// attribute 0 is unique in that it has no current state, so an error
+// will be generated if index is 0. The initial value for all other
+// generic vertex attributes is (0,0,0,1).
+//
+// All of the parameters except GL.CURRENT_VERTEX_ATTRIB represent
+// client-side state.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_ENUM is generated if pname is not an
+// accepted value. GL.INVALID_OPERATION is generated if index is 0 and pname
+// is GL.CURRENT_VERTEX_ATTRIB.
+//
+// GetVertexAttribfv is available in GL version 2.0 or greater.
+func (gl *GL) GetVertexAttribfv(index glbase.Attrib, pname glbase.Enum, params []float32) {
+ var params_c [4]float32
+ C.gl4_2core_glGetVertexAttribfv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetVertexAttribdv returns in params the value of a generic vertex attribute
+// parameter. The generic vertex attribute to be queried is specified by
+// index, and the parameter to be queried is specified by pname.
+//
+// The accepted parameter names are as follows:
+//
+// GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING
+// params returns a single value, the name of the buffer object
+// currently bound to the binding point corresponding to generic vertex
+// attribute array index. If no buffer object is bound, 0 is returned.
+// The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_ENABLED
+// params returns a single value that is non-zero (true) if the vertex
+// attribute array for index is enabled and 0 (false) if it is
+// disabled. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_SIZE
+// params returns a single value, the size of the vertex attribute
+// array for index. The size is the number of values for each element
+// of the vertex attribute array, and it will be 1, 2, 3, or 4. The
+// initial value is 4.
+//
+// GL.VERTEX_ATTRIB_ARRAY_STRIDE
+// params returns a single value, the array stride for (number of bytes
+// between successive elements in) the vertex attribute array for
+// index. A value of 0 indicates that the array elements are stored
+// sequentially in memory. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_TYPE
+// params returns a single value, a symbolic constant indicating the
+// array type for the vertex attribute array for index. Possible values
+// are GL.BYTE, GL.UNSIGNED_BYTE, GL.SHORT, GL.UNSIGNED_SHORT, GL.INT,
+// GL.UNSIGNED_INT, GL.FLOAT, and GL.DOUBLE. The initial value is
+// GL.FLOAT.
+//
+// GL.VERTEX_ATTRIB_ARRAY_NORMALIZED
+// params returns a single value that is non-zero (true) if fixed-point
+// data types for the vertex attribute array indicated by index are
+// normalized when they are converted to floating point, and 0 (false)
+// otherwise. The initial value is 0.
+//
+// GL.CURRENT_VERTEX_ATTRIB
+// params returns four values that represent the current value for the
+// generic vertex attribute specified by index. Generic vertex
+// attribute 0 is unique in that it has no current state, so an error
+// will be generated if index is 0. The initial value for all other
+// generic vertex attributes is (0,0,0,1).
+//
+// All of the parameters except GL.CURRENT_VERTEX_ATTRIB represent
+// client-side state.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_ENUM is generated if pname is not an
+// accepted value. GL.INVALID_OPERATION is generated if index is 0 and pname
+// is GL.CURRENT_VERTEX_ATTRIB.
+//
+// GetVertexAttribdv is available in GL version 2.0 or greater.
+func (gl *GL) GetVertexAttribdv(index glbase.Attrib, pname glbase.Enum, params []float64) {
+ var params_c [4]float64
+ C.gl4_2core_glGetVertexAttribdv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetUniformiv returns in params the value of the specified uniform
+// variable. The type of the uniform variable specified by location
+// determines the number of values returned. If the uniform variable is
+// defined in the shader as a boolean, int, or float, a single value will be
+// returned. If it is defined as a vec2, ivec2, or bvec2, two values will be
+// returned. If it is defined as a vec3, ivec3, or bvec3, three values will
+// be returned, and so on. To query values stored in uniform variables
+// declared as arrays, call GetUniformiv for each element of the array. To
+// query values stored in uniform variables declared as structures, call
+// GetUniformiv for each field in the structure. The values for uniform
+// variables declared as a matrix will be returned in column major order.
+//
+// The locations assigned to uniform variables are not known until the
+// program object is linked. After linking has occurred, the command
+// GetUniformLocation can be used to obtain the location of a uniform
+// variable. This location value can then be passed to GetUniformiv in order
+// to query the current value of the uniform variable. After a program object
+// has been linked successfully, the index values for uniform variables
+// remain fixed until the next link command occurs. The uniform variable
+// values can only be queried after a link if the link was successful.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program
+// object. GL.INVALID_OPERATION is generated if program has not been
+// successfully linked. GL.INVALID_OPERATION is generated if location does
+// not correspond to a valid uniform variable location for the specified
+// program object. GL.INVALID_OPERATION is generated if GetUniformiv is
+// executed between the execution of Begin and the corresponding execution of
+// End.
+//
+// GetUniformiv is available in GL version 2.0 or greater.
+func (gl *GL) GetUniformiv(program glbase.Program, location glbase.Uniform, params []int32) {
+ var params_c [4]int32
+ C.gl4_2core_glGetUniformiv(gl.funcs, C.GLuint(program), C.GLint(location), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetUniformfv returns in params the value of the specified uniform
+// variable. The type of the uniform variable specified by location
+// determines the number of values returned. If the uniform variable is
+// defined in the shader as a boolean, int, or float, a single value will be
+// returned. If it is defined as a vec2, ivec2, or bvec2, two values will be
+// returned. If it is defined as a vec3, ivec3, or bvec3, three values will
+// be returned, and so on. To query values stored in uniform variables
+// declared as arrays, call GetUniformfv for each element of the array. To
+// query values stored in uniform variables declared as structures, call
+// GetUniformfv for each field in the structure. The values for uniform
+// variables declared as a matrix will be returned in column major order.
+//
+// The locations assigned to uniform variables are not known until the
+// program object is linked. After linking has occurred, the command
+// GetUniformLocation can be used to obtain the location of a uniform
+// variable. This location value can then be passed to GetUniformfv in order
+// to query the current value of the uniform variable. After a program object
+// has been linked successfully, the index values for uniform variables
+// remain fixed until the next link command occurs. The uniform variable
+// values can only be queried after a link if the link was successful.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program
+// object. GL.INVALID_OPERATION is generated if program has not been
+// successfully linked. GL.INVALID_OPERATION is generated if location does
+// not correspond to a valid uniform variable location for the specified
+// program object. GL.INVALID_OPERATION is generated if GetUniformfv is
+// executed between the execution of Begin and the corresponding execution of
+// End.
+//
+// GetUniformfv is available in GL version 2.0 or greater.
+func (gl *GL) GetUniformfv(program glbase.Program, location glbase.Uniform, params []float32) {
+ var params_c [4]float32
+ C.gl4_2core_glGetUniformfv(gl.funcs, C.GLuint(program), C.GLint(location), (*C.GLfloat)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetUniformLocation returns an integer that represents the location of a
+// specific uniform variable within a program object. name must be an active
+// uniform variable name in program that is not a structure, an array of
+// structures, or a subcomponent of a vector or a matrix. This function
+// returns -1 if name does not correspond to an active uniform variable in
+// program or if name starts with the reserved prefix "gl_".
+//
+// Uniform variables that are structures or arrays of structures may be
+// queried by calling GetUniformLocation for each field within the
+// structure. The array element operator "[]" and the structure field
+// operator "." may be used in name in order to select elements within an
+// array or fields within a structure. The result of using these operators is
+// not allowed to be another structure, an array of structures, or a
+// subcomponent of a vector or a matrix. Except if the last part of name
+// indicates a uniform variable array, the location of the first element of
+// an array can be retrieved by using the name of the array, or by using the
+// name appended by "[0]".
+//
+// The actual locations assigned to uniform variables are not known until the
+// program object is linked successfully. After linking has occurred, the
+// command GetUniformLocation can be used to obtain the location of a
+// uniform variable. This location value can then be passed to Uniform to
+// set the value of the uniform variable or to GetUniform in order to query
+// the current value of the uniform variable. After a program object has been
+// linked successfully, the index values for uniform variables remain fixed
+// until the next link command occurs. Uniform variable locations and values
+// can only be queried after a link if the link was successful.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program object.
+// GL.INVALID_OPERATION is generated if program has not been successfully
+// linked. GL.INVALID_OPERATION is generated if GetUniformLocation is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// GetUniformLocation is available in GL version 2.0 or greater.
+func (gl *GL) GetUniformLocation(program glbase.Program, name string) glbase.Uniform {
+ name_cstr := C.CString(name)
+ glresult := C.gl4_2core_glGetUniformLocation(gl.funcs, C.GLuint(program), (*C.GLchar)(name_cstr))
+ C.free(unsafe.Pointer(name_cstr))
+ return glbase.Uniform(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetShaderSource.xml
+func (gl *GL) GetShaderSource(shader glbase.Shader, bufSize int32, length []int32, source []byte) {
+ C.gl4_2core_glGetShaderSource(gl.funcs, C.GLuint(shader), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&source[0])))
+}
+
+// GetShaderInfoLog returns the information log for the specified shader
+// object. The information log for a shader object is modified when the
+// shader is compiled.
+//
+// The information log for a shader object is a string that may contain
+// diagnostic messages, warning messages, and other information about the
+// last compile operation. When a shader object is created, its information
+// log will be a string of length 0, and the size of the current log can be
+// obtained by calling GetShaderiv with the value GL.INFO_LOG_LENGTH.
+//
+// The information log for a shader object is the OpenGL implementer's
+// primary mechanism for conveying information about the compilation process.
+// Therefore, the information log can be helpful to application developers
+// during the development process, even when compilation is successful.
+// Application developers should not expect different OpenGL implementations
+// to produce identical information logs.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader is not a shader
+// object. GL.INVALID_VALUE is generated if maxLength is less than 0.
+// GL.INVALID_OPERATION is generated if GetShaderInfoLog is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// GetShaderInfoLog is available in GL version 2.0 or greater.
+func (gl *GL) GetShaderInfoLog(shader glbase.Shader) []byte {
+ var params [1]int32
+ var length int32
+ gl.GetShaderiv(shader, INFO_LOG_LENGTH, params[:])
+ bufSize := params[0]
+ infoLog := make([]byte, int(bufSize))
+ C.gl4_2core_glGetShaderInfoLog(gl.funcs, C.GLuint(shader), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length)), (*C.GLchar)(unsafe.Pointer(&infoLog[0])))
+ return infoLog
+}
+
+// GetShaderiv GetShader returns in params the value of a parameter for a specific
+// shader object. The following parameters are defined:
+//
+// GL.SHADER_TYPE
+// params returns GL.VERTEX_SHADER if shader is a vertex shader object,
+// and GL.FRAGMENT_SHADER if shader is a fragment shader object.
+//
+// GL.DELETE_STATUS
+// params returns GL.TRUE if shader is currently flagged for deletion,
+// and GL.FALSE otherwise.
+//
+// GL.COMPILE_STATUS
+// params returns GL.TRUE if the last compile operation on shader was
+// successful, and GL.FALSE otherwise.
+//
+// GL.INFO_LOG_LENGTH
+// params returns the number of characters in the information log for
+// shader including the null termination character (the size of the
+// character buffer required to store the information log). If shader has
+// no information log, a value of 0 is returned.
+//
+// GL.SHADER_SOURCE_LENGTH
+// params returns the length of the concatenation of the source strings
+// that make up the shader source for the shader, including the null
+// termination character. (the size of the character buffer
+// required to store the shader source). If no source code exists, 0 is
+// returned.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader does not refer to a
+// shader object. GL.INVALID_ENUM is generated if pname is not an accepted
+// value. GL.INVALID_OPERATION is generated if GetShader is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// GetShaderiv is available in GL version 2.0 or greater.
+func (gl *GL) GetShaderiv(shader glbase.Shader, pname glbase.Enum, params []int32) {
+ var params_c [4]int32
+ C.gl4_2core_glGetShaderiv(gl.funcs, C.GLuint(shader), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetProgramInfoLog returns the information log for the specified program
+// object. The information log for a program object is modified when the
+// program object is linked or validated.
+//
+// The information log for a program object is either an empty string, or a
+// string containing information about the last link operation, or a string
+// containing information about the last validation operation. It may contain
+// diagnostic messages, warning messages, and other information. When a
+// program object is created, its information log will be a string of length
+// 0, and the size of the current log can be obtained by calling GetProgramiv
+// with the value GL.INFO_LOG_LENGTH.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated
+// by OpenGL. GL.INVALID_OPERATION is generated if program is not a
+// program object.
+func (gl *GL) GetProgramInfoLog(program glbase.Program) []byte {
+ var params [1]int32
+ var length int32
+ gl.GetProgramiv(program, INFO_LOG_LENGTH, params[:])
+ bufSize := params[0]
+ infoLog := make([]byte, int(bufSize))
+ C.gl4_2core_glGetProgramInfoLog(gl.funcs, C.GLuint(program), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length)), (*C.GLchar)(unsafe.Pointer(&infoLog[0])))
+ return infoLog
+}
+
+// GetProgramiv returns in params the value of a parameter for a specific
+// program object. The following parameters are defined:
+//
+// GL.DELETE_STATUS
+// params returns GL.TRUE if program is currently flagged for deletion,
+// and GL.FALSE otherwise.
+//
+// GL.LINK_STATUS
+// params returns GL.TRUE if the last link operation on program was
+// successful, and GL.FALSE otherwise.
+//
+// GL.VALIDATE_STATUS
+// params returns GL.TRUE or if the last validation operation on
+// program was successful, and GL.FALSE otherwise.
+//
+// GL.INFO_LOG_LENGTH
+// params returns the number of characters in the information log for
+// program including the null termination character (the size of
+// the character buffer required to store the information log). If
+// program has no information log, a value of 0 is returned.
+//
+// GL.ATTACHED_SHADERS
+// params returns the number of shader objects attached to program.
+//
+// GL.ACTIVE_ATTRIBUTES
+// params returns the number of active attribute variables for program.
+//
+// GL.ACTIVE_ATTRIBUTE_MAX_LENGTH
+// params returns the length of the longest active attribute name for
+// program, including the null termination character (the size of
+// the character buffer required to store the longest attribute name).
+// If no active attributes exist, 0 is returned.
+//
+// GL.ACTIVE_UNIFORMS
+// params returns the number of active uniform variables for program.
+//
+// GL.ACTIVE_UNIFORM_MAX_LENGTH
+// params returns the length of the longest active uniform variable
+// name for program, including the null termination character (i.e.,
+// the size of the character buffer required to store the longest
+// uniform variable name). If no active uniform variables exist, 0 is
+// returned.
+//
+// GL.TRANSFORM_FEEDBACK_BUFFER_MODE
+// params returns a symbolic constant indicating the buffer mode used
+// when transform feedback is active. This may be GL.SEPARATE_ATTRIBS
+// or GL.INTERLEAVED_ATTRIBS.
+//
+// GL.TRANSFORM_FEEDBACK_VARYINGS
+// params returns the number of varying variables to capture in transform
+// feedback mode for the program.
+//
+// GL.TRANSFORM_FEEDBACK_VARYING_MAX_LENGTH
+// params returns the length of the longest variable name to be used for
+// transform feedback, including the null-terminator.
+//
+// GL.GEOMETRY_VERTICES_OUT
+// params returns the maximum number of vertices that the geometry shader in
+// program will output.
+//
+// GL.GEOMETRY_INPUT_TYPE
+// params returns a symbolic constant indicating the primitive type accepted
+// as input to the geometry shader contained in program.
+//
+// GL.GEOMETRY_OUTPUT_TYPE
+// params returns a symbolic constant indicating the primitive type that will
+// be output by the geometry shader contained in program.
+//
+// GL.ACTIVE_UNIFORM_BLOCKS and GL.ACTIVE_UNIFORM_BLOCK_MAX_NAME_LENGTH are
+// available only if the GL version 3.1 or greater.
+//
+// GL.GEOMETRY_VERTICES_OUT, GL.GEOMETRY_INPUT_TYPE and
+// GL.GEOMETRY_OUTPUT_TYPE are accepted only if the GL version is 3.2 or
+// greater.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program does not refer to a
+// program object. GL.INVALID_OPERATION is generated if pname is
+// GL.GEOMETRY_VERTICES_OUT, GL.GEOMETRY_INPUT_TYPE, or
+// GL.GEOMETRY_OUTPUT_TYPE, and program does not contain a geometry shader.
+// GL.INVALID_ENUM is generated if pname is not an accepted value.
+func (gl *GL) GetProgramiv(program glbase.Program, pname glbase.Enum, params []int32) {
+ var params_c [4]int32
+ C.gl4_2core_glGetProgramiv(gl.funcs, C.GLuint(program), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetAttribLocation queries the previously linked program object specified
+// by program for the attribute variable specified by name and returns the
+// index of the generic vertex attribute that is bound to that attribute
+// variable. If name is a matrix attribute variable, the index of the first
+// column of the matrix is returned. If the named attribute variable is not
+// an active attribute in the specified program object or if name starts with
+// the reserved prefix "gl_", a value of -1 is returned.
+//
+// The association between an attribute variable name and a generic attribute
+// index can be specified at any time by calling BindAttribLocation.
+// Attribute bindings do not go into effect until LinkProgram is called.
+// After a program object has been linked successfully, the index values for
+// attribute variables remain fixed until the next link command occurs. The
+// attribute values can only be queried after a link if the link was
+// successful. GetAttribLocation returns the binding that actually went
+// into effect the last time LinkProgram was called for the specified
+// program object. Attribute bindings that have been specified since the last
+// link operation are not returned by GetAttribLocation.
+//
+// Error GL_INVALID_OPERATION is generated if program is not a value
+// generated by OpenGL. GL_INVALID_OPERATION is generated if program is not
+// a program object. GL_INVALID_OPERATION is generated if program has not
+// been successfully linked. GL_INVALID_OPERATION is generated if
+// GetAttribLocation is executed between the execution of Begin and the
+// corresponding execution of End.
+//
+// GetAttribLocation is available in GL version 2.0 or greater.
+func (gl *GL) GetAttribLocation(program glbase.Program, name string) glbase.Attrib {
+ name_cstr := C.CString(name)
+ glresult := C.gl4_2core_glGetAttribLocation(gl.funcs, C.GLuint(program), (*C.GLchar)(name_cstr))
+ C.free(unsafe.Pointer(name_cstr))
+ return glbase.Attrib(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetAttachedShaders.xml
+func (gl *GL) GetAttachedShaders(program glbase.Program, maxCount int32, count []int, obj []uint32) {
+ C.gl4_2core_glGetAttachedShaders(gl.funcs, C.GLuint(program), C.GLsizei(maxCount), (*C.GLsizei)(unsafe.Pointer(&count[0])), (*C.GLuint)(unsafe.Pointer(&obj[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveUniform.xml
+func (gl *GL) GetActiveUniform(program glbase.Program, index uint32, bufSize int32, length []int32, size []int, gltype []glbase.Enum, name []byte) {
+ C.gl4_2core_glGetActiveUniform(gl.funcs, C.GLuint(program), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLint)(unsafe.Pointer(&size[0])), (*C.GLenum)(unsafe.Pointer(&gltype[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveAttrib.xml
+func (gl *GL) GetActiveAttrib(program glbase.Program, index glbase.Attrib, bufSize int32, length []int32, size []int, gltype []glbase.Enum, name []byte) {
+ C.gl4_2core_glGetActiveAttrib(gl.funcs, C.GLuint(program), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLint)(unsafe.Pointer(&size[0])), (*C.GLenum)(unsafe.Pointer(&gltype[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEnableVertexAttribArray.xml
+func (gl *GL) EnableVertexAttribArray(index glbase.Attrib) {
+ C.gl4_2core_glEnableVertexAttribArray(gl.funcs, C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDisableVertexAttribArray.xml
+func (gl *GL) DisableVertexAttribArray(index glbase.Attrib) {
+ C.gl4_2core_glDisableVertexAttribArray(gl.funcs, C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDetachShader.xml
+func (gl *GL) DetachShader(program glbase.Program, shader glbase.Shader) {
+ C.gl4_2core_glDetachShader(gl.funcs, C.GLuint(program), C.GLuint(shader))
+}
+
+// DeleteShader frees the memory and invalidates the name associated with
+// the shader object specified by shader. This command effectively undoes the
+// effects of a call to CreateShader.
+//
+// If a shader object to be deleted is attached to a program object, it will
+// be flagged for deletion, but it will not be deleted until it is no longer
+// attached to any program object, for any rendering context (it must
+// be detached from wherever it was attached before it will be deleted). A
+// value of 0 for shader will be silently ignored.
+//
+// To determine whether an object has been flagged for deletion, call
+// GetShader with arguments shader and GL.DELETE_STATUS.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL.
+//
+// DeleteShader is available in GL version 2.0 or greater.
+func (gl *GL) DeleteShader(shader glbase.Shader) {
+ C.gl4_2core_glDeleteShader(gl.funcs, C.GLuint(shader))
+}
+
+// DeleteProgram frees the memory and invalidates the name associated with
+// the program object specified by program. This command effectively undoes
+// the effects of a call to CreateProgram.
+//
+// If a program object is in use as part of current rendering state, it will
+// be flagged for deletion, but it will not be deleted until it is no longer
+// part of current state for any rendering context. If a program object to be
+// deleted has shader objects attached to it, those shader objects will be
+// automatically detached but not deleted unless they have already been
+// flagged for deletion by a previous call to DeleteShader. A value of 0
+// for program will be silently ignored.
+//
+// To determine whether a program object has been flagged for deletion, call
+// GetProgram with arguments program and GL.DELETE_STATUS.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL.
+//
+// DeleteProgram is available in GL version 2.0 or greater.
+func (gl *GL) DeleteProgram(program glbase.Program) {
+ C.gl4_2core_glDeleteProgram(gl.funcs, C.GLuint(program))
+}
+
+// CreateShader creates an empty shader object and returns a non-zero value
+// by which it can be referenced. A shader object is used to maintain the
+// source code strings that define a shader. shaderType indicates the type of
+// shader to be created.
+//
+// Two types of shaders are supported. A shader of type GL.VERTEX_SHADER is a
+// shader that is intended to run on the programmable vertex processor and
+// replace the fixed functionality vertex processing in OpenGL. A shader of
+// type GL.FRAGMENT_SHADER is a shader that is intended to run on the
+// programmable fragment processor and replace the fixed functionality
+// fragment processing in OpenGL.
+//
+// When created, a shader object's GL.SHADER_TYPE parameter is set to either
+// GL.VERTEX_SHADER or GL.FRAGMENT_SHADER, depending on the value of
+// shaderType.
+//
+// Like display lists and texture objects, the name space for shader objects
+// may be shared across a set of contexts, as long as the server sides of the
+// contexts share the same address space. If the name space is shared across
+// contexts, any attached objects and the data associated with those attached
+// objects are shared as well.
+//
+// This function returns 0 if an error occurs creating the shader object.
+//
+// Error GL.INVALID_ENUM is generated if shaderType is not an accepted value.
+// GL.INVALID_OPERATION is generated if CreateShader is executed between the
+// execution of Begin and the corresponding execution of End.
+//
+// CreateShader is available in GL version 2.0 or greater.
+func (gl *GL) CreateShader(gltype glbase.Enum) glbase.Shader {
+ glresult := C.gl4_2core_glCreateShader(gl.funcs, C.GLenum(gltype))
+ return glbase.Shader(glresult)
+}
+
+// CreateProgram creates an empty program object and returns a non-zero
+// value by which it can be referenced. A program object is an object to
+// which shader objects can be attached. This provides a mechanism to specify
+// the shader objects that will be linked to create a program. It also
+// provides a means for checking the compatibility of the shaders that will
+// be used to create a program (for instance, checking the compatibility
+// between a vertex shader and a fragment shader). When no longer needed as
+// part of a program object, shader objects can be detached.
+//
+// One or more executables are created in a program object by successfully
+// attaching shader objects to it with AttachShader, successfully compiling
+// the shader objects with CompileShader, and successfully linking the
+// program object with LinkProgram. These executables are made part of
+// current state when UseProgram is called. Program objects can be deleted
+// by calling DeleteProgram. The memory associated with the program object
+// will be deleted when it is no longer part of current rendering state for
+// any context.
+//
+// Like display lists and texture objects, the name space for program objects
+// may be shared across a set of contexts, as long as the server sides of the
+// contexts share the same address space. If the name space is shared across
+// contexts, any attached objects and the data associated with those attached
+// objects are shared as well.
+//
+// Applications are responsible for providing the synchronization across API
+// calls when objects are accessed from different execution threads.
+//
+// This function returns 0 if an error occurs creating the program object.
+//
+// Error GL.INVALID_OPERATION is generated if CreateProgram is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// CreateProgram is available in GL version 2.0 or greater.
+func (gl *GL) CreateProgram() glbase.Program {
+ glresult := C.gl4_2core_glCreateProgram(gl.funcs)
+ return glbase.Program(glresult)
+}
+
+// CompileShader compiles the source code strings that have been stored in
+// the shader object specified by shader.
+//
+// The compilation status will be stored as part of the shader object's
+// state. This value will be set to GL.TRUE if the shader was compiled without
+// errors and is ready for use, and GL.FALSE otherwise. It can be queried by
+// calling GetShaderiv with arguments shader and GL.COMPILE_STATUS.
+//
+// Compilation of a shader can fail for a number of reasons as specified by
+// the OpenGL Shading Language Specification. Whether or not the compilation
+// was successful, information about the compilation can be obtained from the
+// shader object's information log by calling GetShaderInfoLog.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader is not a shader
+// object. GL.INVALID_OPERATION is generated if CompileShader is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// CompileShader is available in GL version 2.0 or greater.
+func (gl *GL) CompileShader(shader glbase.Shader) {
+ C.gl4_2core_glCompileShader(gl.funcs, C.GLuint(shader))
+}
+
+// BindAttribLocation associates a user-defined attribute variable in the program
+// object specified by program with a generic vertex attribute index. The name
+// parameter specifies the name of the vertex shader attribute variable to
+// which index is to be bound. When program is made part of the current state,
+// values provided via the generic vertex attribute index will modify the
+// value of the user-defined attribute variable specified by name.
+//
+// If name refers to a matrix attribute variable, index refers to the first
+// column of the matrix. Other matrix columns are then automatically bound to
+// locations index+1 for a matrix of type mat2; index+1 and index+2 for a
+// matrix of type mat3; and index+1, index+2, and index+3 for a matrix of
+// type mat4.
+//
+// This command makes it possible for vertex shaders to use descriptive names
+// for attribute variables rather than generic variables that are numbered
+// from 0 to GL.MAX_VERTEX_ATTRIBS-1. The values sent to each generic
+// attribute index are part of current state, just like standard vertex
+// attributes such as color, normal, and vertex position. If a different
+// program object is made current by calling UseProgram, the generic vertex
+// attributes are tracked in such a way that the same values will be observed
+// by attributes in the new program object that are also bound to index.
+//
+// Attribute variable name-to-generic attribute index bindings for a program
+// object can be explicitly assigned at any time by calling
+// BindAttribLocation. Attribute bindings do not go into effect until
+// LinkProgram is called. After a program object has been linked
+// successfully, the index values for generic attributes remain fixed (and
+// their values can be queried) until the next link command occurs.
+//
+// Applications are not allowed to bind any of the standard OpenGL vertex
+// attributes using this command, as they are bound automatically when
+// needed. Any attribute binding that occurs after the program object has
+// been linked will not take effect until the next time the program object is
+// linked.
+//
+// If name was bound previously, that information is lost. Thus you cannot
+// bind one user-defined attribute variable to multiple indices, but you can
+// bind multiple user-defined attribute variables to the same index.
+//
+// Applications are allowed to bind more than one user-defined attribute
+// variable to the same generic vertex attribute index. This is called
+// aliasing, and it is allowed only if just one of the aliased attributes is
+// active in the executable program, or if no path through the shader
+// consumes more than one attribute of a set of attributes aliased to the
+// same location. The compiler and linker are allowed to assume that no
+// aliasing is done and are free to employ optimizations that work only in
+// the absence of aliasing. OpenGL implementations are not required to do
+// error checking to detect aliasing. Because there is no way to bind
+// standard attributes, it is not possible to alias generic attributes with
+// conventional ones (except for generic attribute 0).
+//
+// BindAttribLocation can be called before any vertex shader objects are
+// bound to the specified program object. It is also permissible to bind a
+// generic attribute index to an attribute variable name that is never used
+// in a vertex shader.
+//
+// Active attributes that are not explicitly bound will be bound by the
+// linker when LinkProgram is called. The locations assigned can be queried
+// by calling GetAttribLocation.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS.
+// GL.INVALID_OPERATION is generated if name starts with the reserved prefix "gl_".
+// GL.INVALID_VALUE is generated if program is not a value generated by OpenGL.
+// GL.INVALID_OPERATION is generated if program is not a program object.
+// GL.INVALID_OPERATION is generated if BindAttribLocation is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// BindAttribLocation is available in GL version 2.0 or greater.
+func (gl *GL) BindAttribLocation(program glbase.Program, index glbase.Attrib, name string) {
+ name_cstr := C.CString(name)
+ C.gl4_2core_glBindAttribLocation(gl.funcs, C.GLuint(program), C.GLuint(index), (*C.GLchar)(name_cstr))
+ C.free(unsafe.Pointer(name_cstr))
+}
+
+// AttachShader attaches a shader object to a program object.
+//
+// In order to create an executable, there must be a way to specify the list
+// of things that will be linked together. Program objects provide this
+// mechanism. Shaders that are to be linked together in a program object must
+// first be attached to that program object. This indicates that shader will
+// be included in link operations that will be performed on program.
+//
+// All operations that can be performed on a shader object are valid whether
+// or not the shader object is attached to a program object. It is
+// permissible to attach a shader object to a program object before source
+// code has been loaded into the shader object or before the shader object
+// has been compiled. It is permissible to attach multiple shader objects of
+// the same type because each may contain a portion of the complete shader.
+// It is also permissible to attach a shader object to more than one program
+// object. If a shader object is deleted while it is attached to a program
+// object, it will be flagged for deletion, and deletion will not occur until
+// DetachShader is called to detach it from all program objects to which it
+// is attached.
+//
+// Error GL.INVALID_VALUE is generated if either program or shader is not a
+// value generated by OpenGL. GL.INVALID_OPERATION is generated if program
+// is not a program object. GL.INVALID_OPERATION is generated if shader is
+// not a shader object. GL.INVALID_OPERATION is generated if shader is
+// already attached to program. GL.INVALID_OPERATION is generated if
+// AttachShader is executed between the execution of Begin and the
+// corresponding execution of End.
+//
+// AttachShader is available in GL version 2.0 or greater.
+func (gl *GL) AttachShader(program glbase.Program, shader glbase.Shader) {
+ C.gl4_2core_glAttachShader(gl.funcs, C.GLuint(program), C.GLuint(shader))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glStencilMaskSeparate.xml
+func (gl *GL) StencilMaskSeparate(face glbase.Enum, mask uint32) {
+ C.gl4_2core_glStencilMaskSeparate(gl.funcs, C.GLenum(face), C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glStencilFuncSeparate.xml
+func (gl *GL) StencilFuncSeparate(face, glfunc glbase.Enum, ref int32, mask uint32) {
+ C.gl4_2core_glStencilFuncSeparate(gl.funcs, C.GLenum(face), C.GLenum(glfunc), C.GLint(ref), C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glStencilOpSeparate.xml
+func (gl *GL) StencilOpSeparate(face, sfail, dpfail, dppass glbase.Enum) {
+ C.gl4_2core_glStencilOpSeparate(gl.funcs, C.GLenum(face), C.GLenum(sfail), C.GLenum(dpfail), C.GLenum(dppass))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawBuffers.xml
+func (gl *GL) DrawBuffers(n int, bufs []glbase.Enum) {
+ C.gl4_2core_glDrawBuffers(gl.funcs, C.GLsizei(n), (*C.GLenum)(unsafe.Pointer(&bufs[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendEquationSeparate.xml
+func (gl *GL) BlendEquationSeparate(modeRGB, modeAlpha glbase.Enum) {
+ C.gl4_2core_glBlendEquationSeparate(gl.funcs, C.GLenum(modeRGB), C.GLenum(modeAlpha))
+}
+
+// UniformMatrix4x3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix4x3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix4x3fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(4*3) != 0 {
+ panic("invalid value length for UniformMatrix4x3fv")
+ }
+ count := len(value) / (4 * 3)
+ C.gl4_2core_glUniformMatrix4x3fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix3x4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix3x4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix3x4fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(3*4) != 0 {
+ panic("invalid value length for UniformMatrix3x4fv")
+ }
+ count := len(value) / (3 * 4)
+ C.gl4_2core_glUniformMatrix3x4fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix4x2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix4x2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix4x2fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(4*2) != 0 {
+ panic("invalid value length for UniformMatrix4x2fv")
+ }
+ count := len(value) / (4 * 2)
+ C.gl4_2core_glUniformMatrix4x2fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix2x4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix2x4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix2x4fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(2*4) != 0 {
+ panic("invalid value length for UniformMatrix2x4fv")
+ }
+ count := len(value) / (2 * 4)
+ C.gl4_2core_glUniformMatrix2x4fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix3x2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix3x2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix3x2fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(3*2) != 0 {
+ panic("invalid value length for UniformMatrix3x2fv")
+ }
+ count := len(value) / (3 * 2)
+ C.gl4_2core_glUniformMatrix3x2fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix2x3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix2x3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix2x3fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(2*3) != 0 {
+ panic("invalid value length for UniformMatrix2x3fv")
+ }
+ count := len(value) / (2 * 3)
+ C.gl4_2core_glUniformMatrix2x3fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsVertexArray.xml
+func (gl *GL) IsVertexArray(array uint32) bool {
+ glresult := C.gl4_2core_glIsVertexArray(gl.funcs, C.GLuint(array))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGenVertexArrays.xml
+func (gl *GL) GenVertexArrays(n int, arrays []uint32) {
+ C.gl4_2core_glGenVertexArrays(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&arrays[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDeleteVertexArrays.xml
+func (gl *GL) DeleteVertexArrays(n int, arrays []uint32) {
+ C.gl4_2core_glDeleteVertexArrays(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&arrays[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindVertexArray.xml
+func (gl *GL) BindVertexArray(array uint32) {
+ C.gl4_2core_glBindVertexArray(gl.funcs, C.GLuint(array))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFlushMappedBufferRange.xml
+func (gl *GL) FlushMappedBufferRange(target glbase.Enum, offset, length int) {
+ C.gl4_2core_glFlushMappedBufferRange(gl.funcs, C.GLenum(target), C.GLintptr(offset), C.GLsizeiptr(length))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFramebufferTextureLayer.xml
+func (gl *GL) FramebufferTextureLayer(target, attachment glbase.Enum, texture glbase.Texture, level int, layer int32) {
+ C.gl4_2core_glFramebufferTextureLayer(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLuint(texture), C.GLint(level), C.GLint(layer))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRenderbufferStorageMultisample.xml
+func (gl *GL) RenderbufferStorageMultisample(target glbase.Enum, samples int32, internalFormat glbase.Enum, width, height int) {
+ C.gl4_2core_glRenderbufferStorageMultisample(gl.funcs, C.GLenum(target), C.GLsizei(samples), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlitFramebuffer.xml
+func (gl *GL) BlitFramebuffer(srcX0, srcY0, srcX1, srcY1, dstX0, dstY0, dstX1, dstY1 int32, mask glbase.Bitfield, filter glbase.Enum) {
+ C.gl4_2core_glBlitFramebuffer(gl.funcs, C.GLint(srcX0), C.GLint(srcY0), C.GLint(srcX1), C.GLint(srcY1), C.GLint(dstX0), C.GLint(dstY0), C.GLint(dstX1), C.GLint(dstY1), C.GLbitfield(mask), C.GLenum(filter))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGenerateMipmap.xml
+func (gl *GL) GenerateMipmap(target glbase.Enum) {
+ C.gl4_2core_glGenerateMipmap(gl.funcs, C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetFramebufferAttachmentParameteriv.xml
+func (gl *GL) GetFramebufferAttachmentParameteriv(target, attachment, pname glbase.Enum, params []int32) {
+ C.gl4_2core_glGetFramebufferAttachmentParameteriv(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFramebufferRenderbuffer.xml
+func (gl *GL) FramebufferRenderbuffer(target, attachment, renderbuffertarget glbase.Enum, renderbuffer glbase.Renderbuffer) {
+ C.gl4_2core_glFramebufferRenderbuffer(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(renderbuffertarget), C.GLuint(renderbuffer))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFramebufferTexture3D.xml
+func (gl *GL) FramebufferTexture3D(target, attachment, textarget glbase.Enum, texture glbase.Texture, level int, zoffset int32) {
+ C.gl4_2core_glFramebufferTexture3D(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(textarget), C.GLuint(texture), C.GLint(level), C.GLint(zoffset))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFramebufferTexture2D.xml
+func (gl *GL) FramebufferTexture2D(target, attachment, textarget glbase.Enum, texture glbase.Texture, level int) {
+ C.gl4_2core_glFramebufferTexture2D(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(textarget), C.GLuint(texture), C.GLint(level))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFramebufferTexture1D.xml
+func (gl *GL) FramebufferTexture1D(target, attachment, textarget glbase.Enum, texture glbase.Texture, level int) {
+ C.gl4_2core_glFramebufferTexture1D(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(textarget), C.GLuint(texture), C.GLint(level))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCheckFramebufferStatus.xml
+func (gl *GL) CheckFramebufferStatus(target glbase.Enum) glbase.Enum {
+ glresult := C.gl4_2core_glCheckFramebufferStatus(gl.funcs, C.GLenum(target))
+ return glbase.Enum(glresult)
+}
+
+// GenFramebuffers returns n framebuffer object names in ids. There is no
+// guarantee that the names form a contiguous set of integers; however, it is
+// guaranteed that none of the returned names was in use immediately before
+// the call to GenFramebuffers.
+//
+// Framebuffer object names returned by a call to GenFramebuffers are not
+// returned by subsequent calls, unless they are first deleted with
+// DeleteFramebuffers.
+//
+// The names returned in ids are marked as used, for the purposes of
+// GenFramebuffers only, but they acquire state and type only when they are
+// first bound.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+func (gl *GL) GenFramebuffers(n int) []glbase.Framebuffer {
+ if n == 0 {
+ return nil
+ }
+ framebuffers := make([]glbase.Framebuffer, n)
+ C.gl4_2core_glGenFramebuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&framebuffers[0])))
+ return framebuffers
+}
+
+// DeleteFramebuffers deletes the framebuffer objects whose names are
+// stored in the framebuffers slice. The name zero is reserved by the GL and
+// is silently ignored, should it occur in framebuffers, as are other unused
+// names. Once a framebuffer object is deleted, its name is again unused and
+// it has no attachments. If a framebuffer that is currently bound to one or
+// more of the targets GL.DRAW_FRAMEBUFFER or GL.READ_FRAMEBUFFER is deleted,
+// it is as though BindFramebuffer had been executed with the corresponding
+// target and framebuffer zero.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// DeleteFramebuffers is available in GL version 3.0 or greater.
+func (gl *GL) DeleteFramebuffers(framebuffers []glbase.Framebuffer) {
+ n := len(framebuffers)
+ if n == 0 {
+ return
+ }
+ C.gl4_2core_glDeleteFramebuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&framebuffers[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindFramebuffer.xml
+func (gl *GL) BindFramebuffer(target glbase.Enum, framebuffer glbase.Framebuffer) {
+ C.gl4_2core_glBindFramebuffer(gl.funcs, C.GLenum(target), C.GLuint(framebuffer))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsFramebuffer.xml
+func (gl *GL) IsFramebuffer(framebuffer glbase.Framebuffer) bool {
+ glresult := C.gl4_2core_glIsFramebuffer(gl.funcs, C.GLuint(framebuffer))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetRenderbufferParameteriv.xml
+func (gl *GL) GetRenderbufferParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl4_2core_glGetRenderbufferParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRenderbufferStorage.xml
+func (gl *GL) RenderbufferStorage(target, internalFormat glbase.Enum, width, height int) {
+ C.gl4_2core_glRenderbufferStorage(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height))
+}
+
+// GenRenderbuffers returns n renderbuffer object names in renderbuffers.
+// There is no guarantee that the names form a contiguous set of integers;
+// however, it is guaranteed that none of the returned names was in use
+// immediately before the call to GenRenderbuffers.
+//
+// Renderbuffer object names returned by a call to GenRenderbuffers are not
+// returned by subsequent calls, unless they are first deleted with
+// DeleteRenderbuffers.
+//
+// The names returned in renderbuffers are marked as used, for the purposes
+// of GenRenderbuffers only, but they acquire state and type only when they
+// are first bound.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// GenRenderbuffers is available in GL version 3.0 or greater.
+func (gl *GL) GenRenderbuffers(n int) []glbase.Renderbuffer {
+ if n == 0 {
+ return nil
+ }
+ renderbuffers := make([]glbase.Renderbuffer, n)
+ C.gl4_2core_glGenRenderbuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&renderbuffers[0])))
+ return renderbuffers
+}
+
+// DeleteRenderbuffers deletes the renderbuffer objects whose names are stored
+// in the renderbuffers slice. The name zero is reserved by the GL and
+// is silently ignored, should it occur in renderbuffers, as are other unused
+// names. Once a renderbuffer object is deleted, its name is again unused and
+// it has no contents. If a renderbuffer that is currently bound to the
+// target GL.RENDERBUFFER is deleted, it is as though BindRenderbuffer had
+// been executed with a target of GL.RENDERBUFFER and a name of zero.
+//
+// If a renderbuffer object is attached to one or more attachment points in
+// the currently bound framebuffer, then it as if FramebufferRenderbuffer
+// had been called, with a renderbuffer of zero for each attachment point to
+// which this image was attached in the currently bound framebuffer. In other
+// words, this renderbuffer object is first detached from all attachment
+// ponits in the currently bound framebuffer. Note that the renderbuffer
+// image is specifically not detached from any non-bound framebuffers.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// DeleteRenderbuffers is available in GL version 3.0 or greater.
+func (gl *GL) DeleteRenderbuffers(renderbuffers []glbase.Renderbuffer) {
+ n := len(renderbuffers)
+ if n == 0 {
+ return
+ }
+ C.gl4_2core_glDeleteRenderbuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&renderbuffers[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindRenderbuffer.xml
+func (gl *GL) BindRenderbuffer(target glbase.Enum, renderbuffer glbase.Renderbuffer) {
+ C.gl4_2core_glBindRenderbuffer(gl.funcs, C.GLenum(target), C.GLuint(renderbuffer))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsRenderbuffer.xml
+func (gl *GL) IsRenderbuffer(renderbuffer glbase.Renderbuffer) bool {
+ glresult := C.gl4_2core_glIsRenderbuffer(gl.funcs, C.GLuint(renderbuffer))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearBufferfi.xml
+func (gl *GL) ClearBufferfi(buffer glbase.Enum, drawbuffer int32, depth float32, stencil int32) {
+ C.gl4_2core_glClearBufferfi(gl.funcs, C.GLenum(buffer), C.GLint(drawbuffer), C.GLfloat(depth), C.GLint(stencil))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearBufferfv.xml
+func (gl *GL) ClearBufferfv(buffer glbase.Enum, drawbuffer int32, value []float32) {
+ C.gl4_2core_glClearBufferfv(gl.funcs, C.GLenum(buffer), C.GLint(drawbuffer), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearBufferuiv.xml
+func (gl *GL) ClearBufferuiv(buffer glbase.Enum, drawbuffer int32, value []uint32) {
+ C.gl4_2core_glClearBufferuiv(gl.funcs, C.GLenum(buffer), C.GLint(drawbuffer), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearBufferiv.xml
+func (gl *GL) ClearBufferiv(buffer glbase.Enum, drawbuffer int32, value []int32) {
+ C.gl4_2core_glClearBufferiv(gl.funcs, C.GLenum(buffer), C.GLint(drawbuffer), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexParameterIuiv.xml
+func (gl *GL) GetTexParameterIuiv(target, pname glbase.Enum, params []uint32) {
+ C.gl4_2core_glGetTexParameterIuiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexParameterIiv.xml
+func (gl *GL) GetTexParameterIiv(target, pname glbase.Enum, params []int32) {
+ C.gl4_2core_glGetTexParameterIiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexParameterIuiv.xml
+func (gl *GL) TexParameterIuiv(target, pname glbase.Enum, params []uint32) {
+ C.gl4_2core_glTexParameterIuiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexParameterIiv.xml
+func (gl *GL) TexParameterIiv(target, pname glbase.Enum, params []int32) {
+ C.gl4_2core_glTexParameterIiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// Uniform4uiv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform4uiv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4uiv(location glbase.Uniform, value []uint32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%4 != 0 {
+ panic("invalid value length for Uniform4uiv")
+ }
+ count := len(value) / 4
+ C.gl4_2core_glUniform4uiv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform3uiv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform3uiv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3uiv(location glbase.Uniform, value []uint32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%3 != 0 {
+ panic("invalid value length for Uniform3uiv")
+ }
+ count := len(value) / 3
+ C.gl4_2core_glUniform3uiv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform2uiv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform2uiv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2uiv(location glbase.Uniform, value []uint32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%2 != 0 {
+ panic("invalid value length for Uniform2uiv")
+ }
+ count := len(value) / 2
+ C.gl4_2core_glUniform2uiv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform1uiv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform1uiv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1uiv(location glbase.Uniform, value []uint32) {
+ if len(value) == 0 {
+ return
+ }
+ count := len(value)
+ C.gl4_2core_glUniform1uiv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4ui modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform4ui operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4ui(location glbase.Uniform, v0, v1, v2, v3 uint32) {
+ C.gl4_2core_glUniform4ui(gl.funcs, C.GLint(location), C.GLuint(v0), C.GLuint(v1), C.GLuint(v2), C.GLuint(v3))
+}
+
+// Uniform3ui modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform3ui operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3ui(location glbase.Uniform, v0, v1, v2 uint32) {
+ C.gl4_2core_glUniform3ui(gl.funcs, C.GLint(location), C.GLuint(v0), C.GLuint(v1), C.GLuint(v2))
+}
+
+// Uniform2ui modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform2ui operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2ui(location glbase.Uniform, v0, v1 uint32) {
+ C.gl4_2core_glUniform2ui(gl.funcs, C.GLint(location), C.GLuint(v0), C.GLuint(v1))
+}
+
+// Uniform1ui modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform1ui operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1ui(location glbase.Uniform, v0 uint32) {
+ C.gl4_2core_glUniform1ui(gl.funcs, C.GLint(location), C.GLuint(v0))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetFragDataLocation.xml
+func (gl *GL) GetFragDataLocation(program glbase.Program, name []byte) int32 {
+ glresult := C.gl4_2core_glGetFragDataLocation(gl.funcs, C.GLuint(program), (*C.GLchar)(unsafe.Pointer(&name[0])))
+ return int32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindFragDataLocation.xml
+func (gl *GL) BindFragDataLocation(program glbase.Program, color uint32, name []byte) {
+ C.gl4_2core_glBindFragDataLocation(gl.funcs, C.GLuint(program), C.GLuint(color), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetUniformuiv.xml
+func (gl *GL) GetUniformuiv(program glbase.Program, location glbase.Uniform, params []uint32) {
+ C.gl4_2core_glGetUniformuiv(gl.funcs, C.GLuint(program), C.GLint(location), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetVertexAttribIuiv.xml
+func (gl *GL) GetVertexAttribIuiv(index glbase.Attrib, pname glbase.Enum, params []uint32) {
+ C.gl4_2core_glGetVertexAttribIuiv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetVertexAttribIiv.xml
+func (gl *GL) GetVertexAttribIiv(index glbase.Attrib, pname glbase.Enum, params []int32) {
+ C.gl4_2core_glGetVertexAttribIiv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribIPointer.xml
+func (gl *GL) VertexAttribIPointer(index glbase.Attrib, size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2core_glVertexAttribIPointer(gl.funcs, C.GLuint(index), C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEndConditionalRender.xml
+func (gl *GL) EndConditionalRender() {
+ C.gl4_2core_glEndConditionalRender(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBeginConditionalRender.xml
+func (gl *GL) BeginConditionalRender(id uint32, mode glbase.Enum) {
+ C.gl4_2core_glBeginConditionalRender(gl.funcs, C.GLuint(id), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClampColor.xml
+func (gl *GL) ClampColor(target, clamp glbase.Enum) {
+ C.gl4_2core_glClampColor(gl.funcs, C.GLenum(target), C.GLenum(clamp))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTransformFeedbackVarying.xml
+func (gl *GL) GetTransformFeedbackVarying(program glbase.Program, index uint32, bufSize int32, length []int32, size []int, gltype []glbase.Enum, name []byte) {
+ C.gl4_2core_glGetTransformFeedbackVarying(gl.funcs, C.GLuint(program), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLsizei)(unsafe.Pointer(&size[0])), (*C.GLenum)(unsafe.Pointer(&gltype[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindBufferBase.xml
+func (gl *GL) BindBufferBase(target glbase.Enum, index uint32, buffer glbase.Buffer) {
+ C.gl4_2core_glBindBufferBase(gl.funcs, C.GLenum(target), C.GLuint(index), C.GLuint(buffer))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindBufferRange.xml
+func (gl *GL) BindBufferRange(target glbase.Enum, index uint32, buffer glbase.Buffer, offset, size int) {
+ C.gl4_2core_glBindBufferRange(gl.funcs, C.GLenum(target), C.GLuint(index), C.GLuint(buffer), C.GLintptr(offset), C.GLsizeiptr(size))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEndTransformFeedback.xml
+func (gl *GL) EndTransformFeedback() {
+ C.gl4_2core_glEndTransformFeedback(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBeginTransformFeedback.xml
+func (gl *GL) BeginTransformFeedback(primitiveMode glbase.Enum) {
+ C.gl4_2core_glBeginTransformFeedback(gl.funcs, C.GLenum(primitiveMode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsEnabledi.xml
+func (gl *GL) IsEnabledi(target glbase.Enum, index uint32) bool {
+ glresult := C.gl4_2core_glIsEnabledi(gl.funcs, C.GLenum(target), C.GLuint(index))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDisablei.xml
+func (gl *GL) Disablei(target glbase.Enum, index uint32) {
+ C.gl4_2core_glDisablei(gl.funcs, C.GLenum(target), C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEnablei.xml
+func (gl *GL) Enablei(target glbase.Enum, index uint32) {
+ C.gl4_2core_glEnablei(gl.funcs, C.GLenum(target), C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetIntegeri_v.xml
+func (gl *GL) GetIntegeri_v(target glbase.Enum, index uint32, data []int32) {
+ C.gl4_2core_glGetIntegeri_v(gl.funcs, C.GLenum(target), C.GLuint(index), (*C.GLint)(unsafe.Pointer(&data[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetBooleani_v.xml
+func (gl *GL) GetBooleani_v(target glbase.Enum, index uint32, data []bool) {
+ C.gl4_2core_glGetBooleani_v(gl.funcs, C.GLenum(target), C.GLuint(index), (*C.GLboolean)(unsafe.Pointer(&data[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorMaski.xml
+func (gl *GL) ColorMaski(index uint32, r, g, b, a bool) {
+ C.gl4_2core_glColorMaski(gl.funcs, C.GLuint(index), *(*C.GLboolean)(unsafe.Pointer(&r)), *(*C.GLboolean)(unsafe.Pointer(&g)), *(*C.GLboolean)(unsafe.Pointer(&b)), *(*C.GLboolean)(unsafe.Pointer(&a)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyBufferSubData.xml
+func (gl *GL) CopyBufferSubData(readTarget, writeTarget glbase.Enum, readOffset, writeOffset, size int) {
+ C.gl4_2core_glCopyBufferSubData(gl.funcs, C.GLenum(readTarget), C.GLenum(writeTarget), C.GLintptr(readOffset), C.GLintptr(writeOffset), C.GLsizeiptr(size))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformBlockBinding.xml
+func (gl *GL) UniformBlockBinding(program glbase.Program, v0, v1 uint32) {
+ C.gl4_2core_glUniformBlockBinding(gl.funcs, C.GLuint(program), C.GLuint(v0), C.GLuint(v1))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveUniformBlockName.xml
+func (gl *GL) GetActiveUniformBlockName(program glbase.Program, uniformBlockIndex uint32, bufSize int32, length []int32, uniformBlockName []byte) {
+ C.gl4_2core_glGetActiveUniformBlockName(gl.funcs, C.GLuint(program), C.GLuint(uniformBlockIndex), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&uniformBlockName[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveUniformBlockiv.xml
+func (gl *GL) GetActiveUniformBlockiv(program glbase.Program, uniformBlockIndex uint32, pname glbase.Enum, params []int32) {
+ C.gl4_2core_glGetActiveUniformBlockiv(gl.funcs, C.GLuint(program), C.GLuint(uniformBlockIndex), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetUniformBlockIndex.xml
+func (gl *GL) GetUniformBlockIndex(program glbase.Program, uniformBlockName []byte) uint32 {
+ glresult := C.gl4_2core_glGetUniformBlockIndex(gl.funcs, C.GLuint(program), (*C.GLchar)(unsafe.Pointer(&uniformBlockName[0])))
+ return uint32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveUniformName.xml
+func (gl *GL) GetActiveUniformName(program glbase.Program, uniformIndex uint32, bufSize int32, length []int32, uniformName []byte) {
+ C.gl4_2core_glGetActiveUniformName(gl.funcs, C.GLuint(program), C.GLuint(uniformIndex), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&uniformName[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveUniformsiv.xml
+func (gl *GL) GetActiveUniformsiv(program glbase.Program, uniformCount int32, uniformIndices []uint32, pname glbase.Enum, params []int32) {
+ C.gl4_2core_glGetActiveUniformsiv(gl.funcs, C.GLuint(program), C.GLsizei(uniformCount), (*C.GLuint)(unsafe.Pointer(&uniformIndices[0])), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPrimitiveRestartIndex.xml
+func (gl *GL) PrimitiveRestartIndex(index uint32) {
+ C.gl4_2core_glPrimitiveRestartIndex(gl.funcs, C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexBuffer.xml
+func (gl *GL) TexBuffer(target, internalFormat glbase.Enum, buffer glbase.Buffer) {
+ C.gl4_2core_glTexBuffer(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLuint(buffer))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawElementsInstanced.xml
+func (gl *GL) DrawElementsInstanced(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}, instancecount int32) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2core_glDrawElementsInstanced(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr, C.GLsizei(instancecount))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawArraysInstanced.xml
+func (gl *GL) DrawArraysInstanced(mode glbase.Enum, first, count int, instancecount int32) {
+ C.gl4_2core_glDrawArraysInstanced(gl.funcs, C.GLenum(mode), C.GLint(first), C.GLsizei(count), C.GLsizei(instancecount))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSampleMaski.xml
+func (gl *GL) SampleMaski(index uint32, mask glbase.Bitfield) {
+ C.gl4_2core_glSampleMaski(gl.funcs, C.GLuint(index), C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetMultisamplefv.xml
+func (gl *GL) GetMultisamplefv(pname glbase.Enum, index uint32, val []float32) {
+ C.gl4_2core_glGetMultisamplefv(gl.funcs, C.GLenum(pname), C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&val[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexImage3DMultisample.xml
+func (gl *GL) TexImage3DMultisample(target glbase.Enum, samples, internalFormat int32, width, height int, depth int32, fixedsamplelocations bool) {
+ C.gl4_2core_glTexImage3DMultisample(gl.funcs, C.GLenum(target), C.GLsizei(samples), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), *(*C.GLboolean)(unsafe.Pointer(&fixedsamplelocations)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexImage2DMultisample.xml
+func (gl *GL) TexImage2DMultisample(target glbase.Enum, samples, internalFormat int32, width, height int, fixedsamplelocations bool) {
+ C.gl4_2core_glTexImage2DMultisample(gl.funcs, C.GLenum(target), C.GLsizei(samples), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), *(*C.GLboolean)(unsafe.Pointer(&fixedsamplelocations)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetSynciv.xml
+func (gl *GL) GetSynciv(sync glbase.Sync, pname glbase.Enum, bufSize int32, length, values []int32) {
+ C.gl4_2core_glGetSynciv(gl.funcs, C.GLsync(unsafe.Pointer(sync)), C.GLenum(pname), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLint)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetInteger64v.xml
+func (gl *GL) GetInteger64v(pname glbase.Enum, params []int64) {
+ C.gl4_2core_glGetInteger64v(gl.funcs, C.GLenum(pname), (*C.GLint64)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWaitSync.xml
+func (gl *GL) WaitSync(sync glbase.Sync, flags glbase.Bitfield, timeout uint64) {
+ C.gl4_2core_glWaitSync(gl.funcs, C.GLsync(unsafe.Pointer(sync)), C.GLbitfield(flags), C.GLuint64(timeout))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClientWaitSync.xml
+func (gl *GL) ClientWaitSync(sync glbase.Sync, flags glbase.Bitfield, timeout uint64) glbase.Enum {
+ glresult := C.gl4_2core_glClientWaitSync(gl.funcs, C.GLsync(unsafe.Pointer(sync)), C.GLbitfield(flags), C.GLuint64(timeout))
+ return glbase.Enum(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDeleteSync.xml
+func (gl *GL) DeleteSync(sync glbase.Sync) {
+ C.gl4_2core_glDeleteSync(gl.funcs, C.GLsync(unsafe.Pointer(sync)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsSync.xml
+func (gl *GL) IsSync(sync glbase.Sync) bool {
+ glresult := C.gl4_2core_glIsSync(gl.funcs, C.GLsync(unsafe.Pointer(sync)))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFenceSync.xml
+func (gl *GL) FenceSync(condition glbase.Enum, flags glbase.Bitfield) glbase.Sync {
+ glresult := C.gl4_2core_glFenceSync(gl.funcs, C.GLenum(condition), C.GLbitfield(flags))
+ return glbase.Sync(unsafe.Pointer(glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProvokingVertex.xml
+func (gl *GL) ProvokingVertex(mode glbase.Enum) {
+ C.gl4_2core_glProvokingVertex(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawElementsInstancedBaseVertex.xml
+func (gl *GL) DrawElementsInstancedBaseVertex(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}, instancecount, basevertex int32) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2core_glDrawElementsInstancedBaseVertex(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr, C.GLsizei(instancecount), C.GLint(basevertex))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawRangeElementsBaseVertex.xml
+func (gl *GL) DrawRangeElementsBaseVertex(mode glbase.Enum, start, end uint32, count int, gltype glbase.Enum, indices interface{}, basevertex int32) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2core_glDrawRangeElementsBaseVertex(gl.funcs, C.GLenum(mode), C.GLuint(start), C.GLuint(end), C.GLsizei(count), C.GLenum(gltype), indices_ptr, C.GLint(basevertex))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawElementsBaseVertex.xml
+func (gl *GL) DrawElementsBaseVertex(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}, basevertex int32) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2core_glDrawElementsBaseVertex(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr, C.GLint(basevertex))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFramebufferTexture.xml
+func (gl *GL) FramebufferTexture(target, attachment glbase.Enum, texture glbase.Texture, level int) {
+ C.gl4_2core_glFramebufferTexture(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLuint(texture), C.GLint(level))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetBufferParameteri64v.xml
+func (gl *GL) GetBufferParameteri64v(target, pname glbase.Enum, params []int64) {
+ C.gl4_2core_glGetBufferParameteri64v(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint64)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetInteger64i_v.xml
+func (gl *GL) GetInteger64i_v(target glbase.Enum, index uint32, data []int64) {
+ C.gl4_2core_glGetInteger64i_v(gl.funcs, C.GLenum(target), C.GLuint(index), (*C.GLint64)(unsafe.Pointer(&data[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP4uiv.xml
+func (gl *GL) VertexAttribP4uiv(index glbase.Attrib, gltype glbase.Enum, normalized bool, value []uint32) {
+ C.gl4_2core_glVertexAttribP4uiv(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP4ui.xml
+func (gl *GL) VertexAttribP4ui(index glbase.Attrib, gltype glbase.Enum, normalized bool, value uint32) {
+ C.gl4_2core_glVertexAttribP4ui(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP3uiv.xml
+func (gl *GL) VertexAttribP3uiv(index glbase.Attrib, gltype glbase.Enum, normalized bool, value []uint32) {
+ C.gl4_2core_glVertexAttribP3uiv(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP3ui.xml
+func (gl *GL) VertexAttribP3ui(index glbase.Attrib, gltype glbase.Enum, normalized bool, value uint32) {
+ C.gl4_2core_glVertexAttribP3ui(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP2uiv.xml
+func (gl *GL) VertexAttribP2uiv(index glbase.Attrib, gltype glbase.Enum, normalized bool, value []uint32) {
+ C.gl4_2core_glVertexAttribP2uiv(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP2ui.xml
+func (gl *GL) VertexAttribP2ui(index glbase.Attrib, gltype glbase.Enum, normalized bool, value uint32) {
+ C.gl4_2core_glVertexAttribP2ui(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP1uiv.xml
+func (gl *GL) VertexAttribP1uiv(index glbase.Attrib, gltype glbase.Enum, normalized bool, value []uint32) {
+ C.gl4_2core_glVertexAttribP1uiv(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP1ui.xml
+func (gl *GL) VertexAttribP1ui(index glbase.Attrib, gltype glbase.Enum, normalized bool, value uint32) {
+ C.gl4_2core_glVertexAttribP1ui(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColorP3uiv.xml
+func (gl *GL) SecondaryColorP3uiv(gltype glbase.Enum, color []uint32) {
+ C.gl4_2core_glSecondaryColorP3uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&color[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColorP3ui.xml
+func (gl *GL) SecondaryColorP3ui(gltype glbase.Enum, color uint32) {
+ C.gl4_2core_glSecondaryColorP3ui(gl.funcs, C.GLenum(gltype), C.GLuint(color))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorP4uiv.xml
+func (gl *GL) ColorP4uiv(gltype glbase.Enum, color []uint32) {
+ C.gl4_2core_glColorP4uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&color[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorP4ui.xml
+func (gl *GL) ColorP4ui(gltype glbase.Enum, color uint32) {
+ C.gl4_2core_glColorP4ui(gl.funcs, C.GLenum(gltype), C.GLuint(color))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorP3uiv.xml
+func (gl *GL) ColorP3uiv(gltype glbase.Enum, color []uint32) {
+ C.gl4_2core_glColorP3uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&color[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorP3ui.xml
+func (gl *GL) ColorP3ui(gltype glbase.Enum, color uint32) {
+ C.gl4_2core_glColorP3ui(gl.funcs, C.GLenum(gltype), C.GLuint(color))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNormalP3uiv.xml
+func (gl *GL) NormalP3uiv(gltype glbase.Enum, coords []uint32) {
+ C.gl4_2core_glNormalP3uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNormalP3ui.xml
+func (gl *GL) NormalP3ui(gltype glbase.Enum, coords uint32) {
+ C.gl4_2core_glNormalP3ui(gl.funcs, C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP4uiv.xml
+func (gl *GL) MultiTexCoordP4uiv(texture, gltype glbase.Enum, coords []uint32) {
+ C.gl4_2core_glMultiTexCoordP4uiv(gl.funcs, C.GLenum(texture), C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP4ui.xml
+func (gl *GL) MultiTexCoordP4ui(texture, gltype glbase.Enum, coords uint32) {
+ C.gl4_2core_glMultiTexCoordP4ui(gl.funcs, C.GLenum(texture), C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP3uiv.xml
+func (gl *GL) MultiTexCoordP3uiv(texture, gltype glbase.Enum, coords []uint32) {
+ C.gl4_2core_glMultiTexCoordP3uiv(gl.funcs, C.GLenum(texture), C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP3ui.xml
+func (gl *GL) MultiTexCoordP3ui(texture, gltype glbase.Enum, coords uint32) {
+ C.gl4_2core_glMultiTexCoordP3ui(gl.funcs, C.GLenum(texture), C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP2uiv.xml
+func (gl *GL) MultiTexCoordP2uiv(texture, gltype glbase.Enum, coords []uint32) {
+ C.gl4_2core_glMultiTexCoordP2uiv(gl.funcs, C.GLenum(texture), C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP2ui.xml
+func (gl *GL) MultiTexCoordP2ui(texture, gltype glbase.Enum, coords uint32) {
+ C.gl4_2core_glMultiTexCoordP2ui(gl.funcs, C.GLenum(texture), C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP1uiv.xml
+func (gl *GL) MultiTexCoordP1uiv(texture, gltype glbase.Enum, coords []uint32) {
+ C.gl4_2core_glMultiTexCoordP1uiv(gl.funcs, C.GLenum(texture), C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP1ui.xml
+func (gl *GL) MultiTexCoordP1ui(texture, gltype glbase.Enum, coords uint32) {
+ C.gl4_2core_glMultiTexCoordP1ui(gl.funcs, C.GLenum(texture), C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP4uiv.xml
+func (gl *GL) TexCoordP4uiv(gltype glbase.Enum, coords []uint32) {
+ C.gl4_2core_glTexCoordP4uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP4ui.xml
+func (gl *GL) TexCoordP4ui(gltype glbase.Enum, coords uint32) {
+ C.gl4_2core_glTexCoordP4ui(gl.funcs, C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP3uiv.xml
+func (gl *GL) TexCoordP3uiv(gltype glbase.Enum, coords []uint32) {
+ C.gl4_2core_glTexCoordP3uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP3ui.xml
+func (gl *GL) TexCoordP3ui(gltype glbase.Enum, coords uint32) {
+ C.gl4_2core_glTexCoordP3ui(gl.funcs, C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP2uiv.xml
+func (gl *GL) TexCoordP2uiv(gltype glbase.Enum, coords []uint32) {
+ C.gl4_2core_glTexCoordP2uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP2ui.xml
+func (gl *GL) TexCoordP2ui(gltype glbase.Enum, coords uint32) {
+ C.gl4_2core_glTexCoordP2ui(gl.funcs, C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP1uiv.xml
+func (gl *GL) TexCoordP1uiv(gltype glbase.Enum, coords []uint32) {
+ C.gl4_2core_glTexCoordP1uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP1ui.xml
+func (gl *GL) TexCoordP1ui(gltype glbase.Enum, coords uint32) {
+ C.gl4_2core_glTexCoordP1ui(gl.funcs, C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexP4uiv.xml
+func (gl *GL) VertexP4uiv(gltype glbase.Enum, value []uint32) {
+ C.gl4_2core_glVertexP4uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexP4ui.xml
+func (gl *GL) VertexP4ui(gltype glbase.Enum, value uint32) {
+ C.gl4_2core_glVertexP4ui(gl.funcs, C.GLenum(gltype), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexP3uiv.xml
+func (gl *GL) VertexP3uiv(gltype glbase.Enum, value []uint32) {
+ C.gl4_2core_glVertexP3uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexP3ui.xml
+func (gl *GL) VertexP3ui(gltype glbase.Enum, value uint32) {
+ C.gl4_2core_glVertexP3ui(gl.funcs, C.GLenum(gltype), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexP2uiv.xml
+func (gl *GL) VertexP2uiv(gltype glbase.Enum, value []uint32) {
+ C.gl4_2core_glVertexP2uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexP2ui.xml
+func (gl *GL) VertexP2ui(gltype glbase.Enum, value uint32) {
+ C.gl4_2core_glVertexP2ui(gl.funcs, C.GLenum(gltype), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetQueryObjectui64v.xml
+func (gl *GL) GetQueryObjectui64v(id uint32, pname glbase.Enum, params []uint64) {
+ C.gl4_2core_glGetQueryObjectui64v(gl.funcs, C.GLuint(id), C.GLenum(pname), (*C.GLuint64)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetQueryObjecti64v.xml
+func (gl *GL) GetQueryObjecti64v(id uint32, pname glbase.Enum, params []int64) {
+ C.gl4_2core_glGetQueryObjecti64v(gl.funcs, C.GLuint(id), C.GLenum(pname), (*C.GLint64)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glQueryCounter.xml
+func (gl *GL) QueryCounter(id uint32, target glbase.Enum) {
+ C.gl4_2core_glQueryCounter(gl.funcs, C.GLuint(id), C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetSamplerParameterIuiv.xml
+func (gl *GL) GetSamplerParameterIuiv(sampler uint32, pname glbase.Enum, params []uint32) {
+ C.gl4_2core_glGetSamplerParameterIuiv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetSamplerParameterfv.xml
+func (gl *GL) GetSamplerParameterfv(sampler uint32, pname glbase.Enum, params []float32) {
+ C.gl4_2core_glGetSamplerParameterfv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetSamplerParameterIiv.xml
+func (gl *GL) GetSamplerParameterIiv(sampler uint32, pname glbase.Enum, params []int32) {
+ C.gl4_2core_glGetSamplerParameterIiv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetSamplerParameteriv.xml
+func (gl *GL) GetSamplerParameteriv(sampler uint32, pname glbase.Enum, params []int32) {
+ C.gl4_2core_glGetSamplerParameteriv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSamplerParameterIuiv.xml
+func (gl *GL) SamplerParameterIuiv(sampler uint32, pname glbase.Enum, param []uint32) {
+ C.gl4_2core_glSamplerParameterIuiv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&param[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSamplerParameterIiv.xml
+func (gl *GL) SamplerParameterIiv(sampler uint32, pname glbase.Enum, param []int32) {
+ C.gl4_2core_glSamplerParameterIiv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&param[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSamplerParameterfv.xml
+func (gl *GL) SamplerParameterfv(sampler uint32, pname glbase.Enum, param []float32) {
+ C.gl4_2core_glSamplerParameterfv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&param[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSamplerParameterf.xml
+func (gl *GL) SamplerParameterf(sampler uint32, pname glbase.Enum, param float32) {
+ C.gl4_2core_glSamplerParameterf(gl.funcs, C.GLuint(sampler), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSamplerParameteriv.xml
+func (gl *GL) SamplerParameteriv(sampler uint32, pname glbase.Enum, param []int32) {
+ C.gl4_2core_glSamplerParameteriv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&param[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSamplerParameteri.xml
+func (gl *GL) SamplerParameteri(sampler uint32, pname glbase.Enum, param int32) {
+ C.gl4_2core_glSamplerParameteri(gl.funcs, C.GLuint(sampler), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindSampler.xml
+func (gl *GL) BindSampler(unit, sampler uint32) {
+ C.gl4_2core_glBindSampler(gl.funcs, C.GLuint(unit), C.GLuint(sampler))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsSampler.xml
+func (gl *GL) IsSampler(sampler uint32) bool {
+ glresult := C.gl4_2core_glIsSampler(gl.funcs, C.GLuint(sampler))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDeleteSamplers.xml
+func (gl *GL) DeleteSamplers(count int, samplers []uint32) {
+ C.gl4_2core_glDeleteSamplers(gl.funcs, C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&samplers[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGenSamplers.xml
+func (gl *GL) GenSamplers(count int, samplers []uint32) {
+ C.gl4_2core_glGenSamplers(gl.funcs, C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&samplers[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetFragDataIndex.xml
+func (gl *GL) GetFragDataIndex(program glbase.Program, name []byte) int32 {
+ glresult := C.gl4_2core_glGetFragDataIndex(gl.funcs, C.GLuint(program), (*C.GLchar)(unsafe.Pointer(&name[0])))
+ return int32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindFragDataLocationIndexed.xml
+func (gl *GL) BindFragDataLocationIndexed(program glbase.Program, colorNumber, index uint32, name []byte) {
+ C.gl4_2core_glBindFragDataLocationIndexed(gl.funcs, C.GLuint(program), C.GLuint(colorNumber), C.GLuint(index), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribDivisor.xml
+func (gl *GL) VertexAttribDivisor(index glbase.Attrib, divisor uint32) {
+ C.gl4_2core_glVertexAttribDivisor(gl.funcs, C.GLuint(index), C.GLuint(divisor))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetQueryIndexediv.xml
+func (gl *GL) GetQueryIndexediv(target glbase.Enum, index uint32, pname glbase.Enum, params []int32) {
+ C.gl4_2core_glGetQueryIndexediv(gl.funcs, C.GLenum(target), C.GLuint(index), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEndQueryIndexed.xml
+func (gl *GL) EndQueryIndexed(target glbase.Enum, index uint32) {
+ C.gl4_2core_glEndQueryIndexed(gl.funcs, C.GLenum(target), C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBeginQueryIndexed.xml
+func (gl *GL) BeginQueryIndexed(target glbase.Enum, index, id uint32) {
+ C.gl4_2core_glBeginQueryIndexed(gl.funcs, C.GLenum(target), C.GLuint(index), C.GLuint(id))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawTransformFeedbackStream.xml
+func (gl *GL) DrawTransformFeedbackStream(mode glbase.Enum, id, stream uint32) {
+ C.gl4_2core_glDrawTransformFeedbackStream(gl.funcs, C.GLenum(mode), C.GLuint(id), C.GLuint(stream))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawTransformFeedback.xml
+func (gl *GL) DrawTransformFeedback(mode glbase.Enum, id uint32) {
+ C.gl4_2core_glDrawTransformFeedback(gl.funcs, C.GLenum(mode), C.GLuint(id))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glResumeTransformFeedback.xml
+func (gl *GL) ResumeTransformFeedback() {
+ C.gl4_2core_glResumeTransformFeedback(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPauseTransformFeedback.xml
+func (gl *GL) PauseTransformFeedback() {
+ C.gl4_2core_glPauseTransformFeedback(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsTransformFeedback.xml
+func (gl *GL) IsTransformFeedback(id uint32) bool {
+ glresult := C.gl4_2core_glIsTransformFeedback(gl.funcs, C.GLuint(id))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGenTransformFeedbacks.xml
+func (gl *GL) GenTransformFeedbacks(n int, ids []uint32) {
+ C.gl4_2core_glGenTransformFeedbacks(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&ids[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDeleteTransformFeedbacks.xml
+func (gl *GL) DeleteTransformFeedbacks(n int, ids []uint32) {
+ C.gl4_2core_glDeleteTransformFeedbacks(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&ids[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindTransformFeedback.xml
+func (gl *GL) BindTransformFeedback(target glbase.Enum, id uint32) {
+ C.gl4_2core_glBindTransformFeedback(gl.funcs, C.GLenum(target), C.GLuint(id))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPatchParameterfv.xml
+func (gl *GL) PatchParameterfv(pname glbase.Enum, values []float32) {
+ C.gl4_2core_glPatchParameterfv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPatchParameteri.xml
+func (gl *GL) PatchParameteri(pname glbase.Enum, value int32) {
+ C.gl4_2core_glPatchParameteri(gl.funcs, C.GLenum(pname), C.GLint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetProgramStageiv.xml
+func (gl *GL) GetProgramStageiv(program glbase.Program, shadertype, pname glbase.Enum, values []int32) {
+ C.gl4_2core_glGetProgramStageiv(gl.funcs, C.GLuint(program), C.GLenum(shadertype), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetUniformSubroutineuiv.xml
+func (gl *GL) GetUniformSubroutineuiv(shadertype glbase.Enum, location glbase.Uniform, params []uint32) {
+ C.gl4_2core_glGetUniformSubroutineuiv(gl.funcs, C.GLenum(shadertype), C.GLint(location), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformSubroutinesuiv.xml
+func (gl *GL) UniformSubroutinesuiv(shadertype glbase.Enum, count int, value []uint32) {
+ C.gl4_2core_glUniformSubroutinesuiv(gl.funcs, C.GLenum(shadertype), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveSubroutineName.xml
+func (gl *GL) GetActiveSubroutineName(program glbase.Program, shadertype glbase.Enum, index uint32, bufSize int32, length []int32, name []byte) {
+ C.gl4_2core_glGetActiveSubroutineName(gl.funcs, C.GLuint(program), C.GLenum(shadertype), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveSubroutineUniformName.xml
+func (gl *GL) GetActiveSubroutineUniformName(program glbase.Program, shadertype glbase.Enum, index uint32, bufSize int32, length []int32, name []byte) {
+ C.gl4_2core_glGetActiveSubroutineUniformName(gl.funcs, C.GLuint(program), C.GLenum(shadertype), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveSubroutineUniformiv.xml
+func (gl *GL) GetActiveSubroutineUniformiv(program glbase.Program, shadertype glbase.Enum, index uint32, pname glbase.Enum, values []int32) {
+ C.gl4_2core_glGetActiveSubroutineUniformiv(gl.funcs, C.GLuint(program), C.GLenum(shadertype), C.GLuint(index), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetSubroutineIndex.xml
+func (gl *GL) GetSubroutineIndex(program glbase.Program, shadertype glbase.Enum, name []byte) uint32 {
+ glresult := C.gl4_2core_glGetSubroutineIndex(gl.funcs, C.GLuint(program), C.GLenum(shadertype), (*C.GLchar)(unsafe.Pointer(&name[0])))
+ return uint32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetSubroutineUniformLocation.xml
+func (gl *GL) GetSubroutineUniformLocation(program glbase.Program, shadertype glbase.Enum, name []byte) int32 {
+ glresult := C.gl4_2core_glGetSubroutineUniformLocation(gl.funcs, C.GLuint(program), C.GLenum(shadertype), (*C.GLchar)(unsafe.Pointer(&name[0])))
+ return int32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetUniformdv.xml
+func (gl *GL) GetUniformdv(program glbase.Program, location glbase.Uniform, params []float64) {
+ C.gl4_2core_glGetUniformdv(gl.funcs, C.GLuint(program), C.GLint(location), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix4x3dv.xml
+func (gl *GL) UniformMatrix4x3dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_2core_glUniformMatrix4x3dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix4x2dv.xml
+func (gl *GL) UniformMatrix4x2dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_2core_glUniformMatrix4x2dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix3x4dv.xml
+func (gl *GL) UniformMatrix3x4dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_2core_glUniformMatrix3x4dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix3x2dv.xml
+func (gl *GL) UniformMatrix3x2dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_2core_glUniformMatrix3x2dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix2x4dv.xml
+func (gl *GL) UniformMatrix2x4dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_2core_glUniformMatrix2x4dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix2x3dv.xml
+func (gl *GL) UniformMatrix2x3dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_2core_glUniformMatrix2x3dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix4dv.xml
+func (gl *GL) UniformMatrix4dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_2core_glUniformMatrix4dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix3dv.xml
+func (gl *GL) UniformMatrix3dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_2core_glUniformMatrix3dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix2dv.xml
+func (gl *GL) UniformMatrix2dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_2core_glUniformMatrix2dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform4dv.xml
+func (gl *GL) Uniform4dv(location glbase.Uniform, count int, value []float64) {
+ C.gl4_2core_glUniform4dv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform3dv.xml
+func (gl *GL) Uniform3dv(location glbase.Uniform, count int, value []float64) {
+ C.gl4_2core_glUniform3dv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform2dv.xml
+func (gl *GL) Uniform2dv(location glbase.Uniform, count int, value []float64) {
+ C.gl4_2core_glUniform2dv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform1dv.xml
+func (gl *GL) Uniform1dv(location glbase.Uniform, count int, value []float64) {
+ C.gl4_2core_glUniform1dv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform4d.xml
+func (gl *GL) Uniform4d(location glbase.Uniform, v0, v1, v2, v3 float64) {
+ C.gl4_2core_glUniform4d(gl.funcs, C.GLint(location), C.GLdouble(v0), C.GLdouble(v1), C.GLdouble(v2), C.GLdouble(v3))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform3d.xml
+func (gl *GL) Uniform3d(location glbase.Uniform, v0, v1, v2 float64) {
+ C.gl4_2core_glUniform3d(gl.funcs, C.GLint(location), C.GLdouble(v0), C.GLdouble(v1), C.GLdouble(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform2d.xml
+func (gl *GL) Uniform2d(location glbase.Uniform, v0, v1 float64) {
+ C.gl4_2core_glUniform2d(gl.funcs, C.GLint(location), C.GLdouble(v0), C.GLdouble(v1))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform1d.xml
+func (gl *GL) Uniform1d(location glbase.Uniform, v0 float64) {
+ C.gl4_2core_glUniform1d(gl.funcs, C.GLint(location), C.GLdouble(v0))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawElementsIndirect.xml
+func (gl *GL) DrawElementsIndirect(mode, gltype glbase.Enum, indirect interface{}) {
+ var indirect_ptr unsafe.Pointer
+ var indirect_v = reflect.ValueOf(indirect)
+ if indirect != nil && indirect_v.Kind() != reflect.Slice {
+ panic("parameter indirect must be a slice")
+ }
+ if indirect != nil {
+ indirect_ptr = unsafe.Pointer(indirect_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2core_glDrawElementsIndirect(gl.funcs, C.GLenum(mode), C.GLenum(gltype), indirect_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawArraysIndirect.xml
+func (gl *GL) DrawArraysIndirect(mode glbase.Enum, indirect interface{}) {
+ var indirect_ptr unsafe.Pointer
+ var indirect_v = reflect.ValueOf(indirect)
+ if indirect != nil && indirect_v.Kind() != reflect.Slice {
+ panic("parameter indirect must be a slice")
+ }
+ if indirect != nil {
+ indirect_ptr = unsafe.Pointer(indirect_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2core_glDrawArraysIndirect(gl.funcs, C.GLenum(mode), indirect_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendFuncSeparatei.xml
+func (gl *GL) BlendFuncSeparatei(buf uint32, srcRGB, dstRGB, srcAlpha, dstAlpha glbase.Enum) {
+ C.gl4_2core_glBlendFuncSeparatei(gl.funcs, C.GLuint(buf), C.GLenum(srcRGB), C.GLenum(dstRGB), C.GLenum(srcAlpha), C.GLenum(dstAlpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendFunci.xml
+func (gl *GL) BlendFunci(buf uint32, src, dst glbase.Enum) {
+ C.gl4_2core_glBlendFunci(gl.funcs, C.GLuint(buf), C.GLenum(src), C.GLenum(dst))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendEquationSeparatei.xml
+func (gl *GL) BlendEquationSeparatei(buf uint32, modeRGB, modeAlpha glbase.Enum) {
+ C.gl4_2core_glBlendEquationSeparatei(gl.funcs, C.GLuint(buf), C.GLenum(modeRGB), C.GLenum(modeAlpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendEquationi.xml
+func (gl *GL) BlendEquationi(buf uint32, mode glbase.Enum) {
+ C.gl4_2core_glBlendEquationi(gl.funcs, C.GLuint(buf), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMinSampleShading.xml
+func (gl *GL) MinSampleShading(value float32) {
+ C.gl4_2core_glMinSampleShading(gl.funcs, C.GLfloat(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetDoublei_v.xml
+func (gl *GL) GetDoublei_v(target glbase.Enum, index uint32, data []float64) {
+ C.gl4_2core_glGetDoublei_v(gl.funcs, C.GLenum(target), C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&data[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetFloati_v.xml
+func (gl *GL) GetFloati_v(target glbase.Enum, index uint32, data []float32) {
+ C.gl4_2core_glGetFloati_v(gl.funcs, C.GLenum(target), C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&data[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDepthRangeIndexed.xml
+func (gl *GL) DepthRangeIndexed(index uint32, n, f float64) {
+ C.gl4_2core_glDepthRangeIndexed(gl.funcs, C.GLuint(index), C.GLdouble(n), C.GLdouble(f))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDepthRangeArrayv.xml
+func (gl *GL) DepthRangeArrayv(first uint32, count int, v []float64) {
+ C.gl4_2core_glDepthRangeArrayv(gl.funcs, C.GLuint(first), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glScissorIndexedv.xml
+func (gl *GL) ScissorIndexedv(index uint32, v []int32) {
+ C.gl4_2core_glScissorIndexedv(gl.funcs, C.GLuint(index), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glScissorIndexed.xml
+func (gl *GL) ScissorIndexed(index uint32, left, bottom int32, width, height int) {
+ C.gl4_2core_glScissorIndexed(gl.funcs, C.GLuint(index), C.GLint(left), C.GLint(bottom), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glScissorArrayv.xml
+func (gl *GL) ScissorArrayv(first uint32, count int, v []int32) {
+ C.gl4_2core_glScissorArrayv(gl.funcs, C.GLuint(first), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glViewportIndexedfv.xml
+func (gl *GL) ViewportIndexedfv(index uint32, v []float32) {
+ C.gl4_2core_glViewportIndexedfv(gl.funcs, C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glViewportIndexedf.xml
+func (gl *GL) ViewportIndexedf(index uint32, x, y, w, h float32) {
+ C.gl4_2core_glViewportIndexedf(gl.funcs, C.GLuint(index), C.GLfloat(x), C.GLfloat(y), C.GLfloat(w), C.GLfloat(h))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glViewportArrayv.xml
+func (gl *GL) ViewportArrayv(first uint32, count int, v []float32) {
+ C.gl4_2core_glViewportArrayv(gl.funcs, C.GLuint(first), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetVertexAttribLdv.xml
+func (gl *GL) GetVertexAttribLdv(index glbase.Attrib, pname glbase.Enum, params []float64) {
+ C.gl4_2core_glGetVertexAttribLdv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribLPointer.xml
+func (gl *GL) VertexAttribLPointer(index glbase.Attrib, size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2core_glVertexAttribLPointer(gl.funcs, C.GLuint(index), C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribL4dv.xml
+func (gl *GL) VertexAttribL4dv(index glbase.Attrib, v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2core_glVertexAttribL4dv(gl.funcs, C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribL3dv.xml
+func (gl *GL) VertexAttribL3dv(index glbase.Attrib, v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2core_glVertexAttribL3dv(gl.funcs, C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribL2dv.xml
+func (gl *GL) VertexAttribL2dv(index glbase.Attrib, v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_2core_glVertexAttribL2dv(gl.funcs, C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribL1dv.xml
+func (gl *GL) VertexAttribL1dv(index glbase.Attrib, v []float64) {
+ C.gl4_2core_glVertexAttribL1dv(gl.funcs, C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribL4d.xml
+func (gl *GL) VertexAttribL4d(index glbase.Attrib, x, y, z, w float64) {
+ C.gl4_2core_glVertexAttribL4d(gl.funcs, C.GLuint(index), C.GLdouble(x), C.GLdouble(y), C.GLdouble(z), C.GLdouble(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribL3d.xml
+func (gl *GL) VertexAttribL3d(index glbase.Attrib, x, y, z float64) {
+ C.gl4_2core_glVertexAttribL3d(gl.funcs, C.GLuint(index), C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribL2d.xml
+func (gl *GL) VertexAttribL2d(index glbase.Attrib, x, y float64) {
+ C.gl4_2core_glVertexAttribL2d(gl.funcs, C.GLuint(index), C.GLdouble(x), C.GLdouble(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribL1d.xml
+func (gl *GL) VertexAttribL1d(index glbase.Attrib, x float64) {
+ C.gl4_2core_glVertexAttribL1d(gl.funcs, C.GLuint(index), C.GLdouble(x))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetProgramPipelineInfoLog.xml
+func (gl *GL) GetProgramPipelineInfoLog(pipeline uint32, bufSize int32, length []int32, infoLog []byte) {
+ C.gl4_2core_glGetProgramPipelineInfoLog(gl.funcs, C.GLuint(pipeline), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&infoLog[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glValidateProgramPipeline.xml
+func (gl *GL) ValidateProgramPipeline(pipeline uint32) {
+ C.gl4_2core_glValidateProgramPipeline(gl.funcs, C.GLuint(pipeline))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix4x3dv.xml
+func (gl *GL) ProgramUniformMatrix4x3dv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float64) {
+ if len(value) != 3 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_2core_glProgramUniformMatrix4x3dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix3x4dv.xml
+func (gl *GL) ProgramUniformMatrix3x4dv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float64) {
+ if len(value) != 4 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_2core_glProgramUniformMatrix3x4dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix4x2dv.xml
+func (gl *GL) ProgramUniformMatrix4x2dv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float64) {
+ if len(value) != 2 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_2core_glProgramUniformMatrix4x2dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix2x4dv.xml
+func (gl *GL) ProgramUniformMatrix2x4dv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float64) {
+ if len(value) != 4 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_2core_glProgramUniformMatrix2x4dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix3x2dv.xml
+func (gl *GL) ProgramUniformMatrix3x2dv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float64) {
+ if len(value) != 2 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_2core_glProgramUniformMatrix3x2dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix2x3dv.xml
+func (gl *GL) ProgramUniformMatrix2x3dv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float64) {
+ if len(value) != 3 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_2core_glProgramUniformMatrix2x3dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix4x3fv.xml
+func (gl *GL) ProgramUniformMatrix4x3fv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float32) {
+ if len(value) != 3 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_2core_glProgramUniformMatrix4x3fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix3x4fv.xml
+func (gl *GL) ProgramUniformMatrix3x4fv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float32) {
+ if len(value) != 4 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_2core_glProgramUniformMatrix3x4fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix4x2fv.xml
+func (gl *GL) ProgramUniformMatrix4x2fv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float32) {
+ if len(value) != 2 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_2core_glProgramUniformMatrix4x2fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix2x4fv.xml
+func (gl *GL) ProgramUniformMatrix2x4fv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float32) {
+ if len(value) != 4 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_2core_glProgramUniformMatrix2x4fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix3x2fv.xml
+func (gl *GL) ProgramUniformMatrix3x2fv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float32) {
+ if len(value) != 2 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_2core_glProgramUniformMatrix3x2fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix2x3fv.xml
+func (gl *GL) ProgramUniformMatrix2x3fv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float32) {
+ if len(value) != 3 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_2core_glProgramUniformMatrix2x3fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix4dv.xml
+func (gl *GL) ProgramUniformMatrix4dv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float64) {
+ if len(value) != 4 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_2core_glProgramUniformMatrix4dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix3dv.xml
+func (gl *GL) ProgramUniformMatrix3dv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float64) {
+ if len(value) != 3 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_2core_glProgramUniformMatrix3dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix2dv.xml
+func (gl *GL) ProgramUniformMatrix2dv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float64) {
+ if len(value) != 2 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_2core_glProgramUniformMatrix2dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix4fv.xml
+func (gl *GL) ProgramUniformMatrix4fv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float32) {
+ if len(value) != 4 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_2core_glProgramUniformMatrix4fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix3fv.xml
+func (gl *GL) ProgramUniformMatrix3fv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float32) {
+ if len(value) != 3 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_2core_glProgramUniformMatrix3fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix2fv.xml
+func (gl *GL) ProgramUniformMatrix2fv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float32) {
+ if len(value) != 2 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_2core_glProgramUniformMatrix2fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform4uiv.xml
+func (gl *GL) ProgramUniform4uiv(program glbase.Program, location glbase.Uniform, count int, value []uint32) {
+ C.gl4_2core_glProgramUniform4uiv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform4ui.xml
+func (gl *GL) ProgramUniform4ui(program glbase.Program, location glbase.Uniform, v0, v1, v2, v3 uint32) {
+ C.gl4_2core_glProgramUniform4ui(gl.funcs, C.GLuint(program), C.GLint(location), C.GLuint(v0), C.GLuint(v1), C.GLuint(v2), C.GLuint(v3))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform4dv.xml
+func (gl *GL) ProgramUniform4dv(program glbase.Program, location glbase.Uniform, count int, value []float64) {
+ if len(value) != 4 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_2core_glProgramUniform4dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform4d.xml
+func (gl *GL) ProgramUniform4d(program glbase.Program, location glbase.Uniform, v0, v1, v2, v3 float64) {
+ C.gl4_2core_glProgramUniform4d(gl.funcs, C.GLuint(program), C.GLint(location), C.GLdouble(v0), C.GLdouble(v1), C.GLdouble(v2), C.GLdouble(v3))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform4fv.xml
+func (gl *GL) ProgramUniform4fv(program glbase.Program, location glbase.Uniform, count int, value []float32) {
+ if len(value) != 4 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_2core_glProgramUniform4fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform4f.xml
+func (gl *GL) ProgramUniform4f(program glbase.Program, location glbase.Uniform, v0, v1, v2, v3 float32) {
+ C.gl4_2core_glProgramUniform4f(gl.funcs, C.GLuint(program), C.GLint(location), C.GLfloat(v0), C.GLfloat(v1), C.GLfloat(v2), C.GLfloat(v3))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform4iv.xml
+func (gl *GL) ProgramUniform4iv(program glbase.Program, location glbase.Uniform, count int, value []int32) {
+ if len(value) != 4 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_2core_glProgramUniform4iv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform4i.xml
+func (gl *GL) ProgramUniform4i(program glbase.Program, location glbase.Uniform, v0, v1, v2, v3 int32) {
+ C.gl4_2core_glProgramUniform4i(gl.funcs, C.GLuint(program), C.GLint(location), C.GLint(v0), C.GLint(v1), C.GLint(v2), C.GLint(v3))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform3uiv.xml
+func (gl *GL) ProgramUniform3uiv(program glbase.Program, location glbase.Uniform, count int, value []uint32) {
+ C.gl4_2core_glProgramUniform3uiv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform3ui.xml
+func (gl *GL) ProgramUniform3ui(program glbase.Program, location glbase.Uniform, v0, v1, v2 uint32) {
+ C.gl4_2core_glProgramUniform3ui(gl.funcs, C.GLuint(program), C.GLint(location), C.GLuint(v0), C.GLuint(v1), C.GLuint(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform3dv.xml
+func (gl *GL) ProgramUniform3dv(program glbase.Program, location glbase.Uniform, count int, value []float64) {
+ if len(value) != 3 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_2core_glProgramUniform3dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform3d.xml
+func (gl *GL) ProgramUniform3d(program glbase.Program, location glbase.Uniform, v0, v1, v2 float64) {
+ C.gl4_2core_glProgramUniform3d(gl.funcs, C.GLuint(program), C.GLint(location), C.GLdouble(v0), C.GLdouble(v1), C.GLdouble(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform3fv.xml
+func (gl *GL) ProgramUniform3fv(program glbase.Program, location glbase.Uniform, count int, value []float32) {
+ if len(value) != 3 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_2core_glProgramUniform3fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform3f.xml
+func (gl *GL) ProgramUniform3f(program glbase.Program, location glbase.Uniform, v0, v1, v2 float32) {
+ C.gl4_2core_glProgramUniform3f(gl.funcs, C.GLuint(program), C.GLint(location), C.GLfloat(v0), C.GLfloat(v1), C.GLfloat(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform3iv.xml
+func (gl *GL) ProgramUniform3iv(program glbase.Program, location glbase.Uniform, count int, value []int32) {
+ if len(value) != 3 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_2core_glProgramUniform3iv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform3i.xml
+func (gl *GL) ProgramUniform3i(program glbase.Program, location glbase.Uniform, v0, v1, v2 int32) {
+ C.gl4_2core_glProgramUniform3i(gl.funcs, C.GLuint(program), C.GLint(location), C.GLint(v0), C.GLint(v1), C.GLint(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform2uiv.xml
+func (gl *GL) ProgramUniform2uiv(program glbase.Program, location glbase.Uniform, count int, value []uint32) {
+ C.gl4_2core_glProgramUniform2uiv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform2ui.xml
+func (gl *GL) ProgramUniform2ui(program glbase.Program, location glbase.Uniform, v0, v1 uint32) {
+ C.gl4_2core_glProgramUniform2ui(gl.funcs, C.GLuint(program), C.GLint(location), C.GLuint(v0), C.GLuint(v1))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform2dv.xml
+func (gl *GL) ProgramUniform2dv(program glbase.Program, location glbase.Uniform, count int, value []float64) {
+ if len(value) != 2 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_2core_glProgramUniform2dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform2d.xml
+func (gl *GL) ProgramUniform2d(program glbase.Program, location glbase.Uniform, v0, v1 float64) {
+ C.gl4_2core_glProgramUniform2d(gl.funcs, C.GLuint(program), C.GLint(location), C.GLdouble(v0), C.GLdouble(v1))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform2fv.xml
+func (gl *GL) ProgramUniform2fv(program glbase.Program, location glbase.Uniform, count int, value []float32) {
+ if len(value) != 2 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_2core_glProgramUniform2fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform2f.xml
+func (gl *GL) ProgramUniform2f(program glbase.Program, location glbase.Uniform, v0, v1 float32) {
+ C.gl4_2core_glProgramUniform2f(gl.funcs, C.GLuint(program), C.GLint(location), C.GLfloat(v0), C.GLfloat(v1))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform2iv.xml
+func (gl *GL) ProgramUniform2iv(program glbase.Program, location glbase.Uniform, count int, value []int32) {
+ if len(value) != 2 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_2core_glProgramUniform2iv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform2i.xml
+func (gl *GL) ProgramUniform2i(program glbase.Program, location glbase.Uniform, v0, v1 int32) {
+ C.gl4_2core_glProgramUniform2i(gl.funcs, C.GLuint(program), C.GLint(location), C.GLint(v0), C.GLint(v1))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform1uiv.xml
+func (gl *GL) ProgramUniform1uiv(program glbase.Program, location glbase.Uniform, count int, value []uint32) {
+ C.gl4_2core_glProgramUniform1uiv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform1ui.xml
+func (gl *GL) ProgramUniform1ui(program glbase.Program, location glbase.Uniform, v0 uint32) {
+ C.gl4_2core_glProgramUniform1ui(gl.funcs, C.GLuint(program), C.GLint(location), C.GLuint(v0))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform1dv.xml
+func (gl *GL) ProgramUniform1dv(program glbase.Program, location glbase.Uniform, count int, value []float64) {
+ C.gl4_2core_glProgramUniform1dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform1d.xml
+func (gl *GL) ProgramUniform1d(program glbase.Program, location glbase.Uniform, v0 float64) {
+ C.gl4_2core_glProgramUniform1d(gl.funcs, C.GLuint(program), C.GLint(location), C.GLdouble(v0))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform1fv.xml
+func (gl *GL) ProgramUniform1fv(program glbase.Program, location glbase.Uniform, count int, value []float32) {
+ C.gl4_2core_glProgramUniform1fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform1f.xml
+func (gl *GL) ProgramUniform1f(program glbase.Program, location glbase.Uniform, v0 float32) {
+ C.gl4_2core_glProgramUniform1f(gl.funcs, C.GLuint(program), C.GLint(location), C.GLfloat(v0))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform1iv.xml
+func (gl *GL) ProgramUniform1iv(program glbase.Program, location glbase.Uniform, count int, value []int32) {
+ C.gl4_2core_glProgramUniform1iv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform1i.xml
+func (gl *GL) ProgramUniform1i(program glbase.Program, location glbase.Uniform, v0 int32) {
+ C.gl4_2core_glProgramUniform1i(gl.funcs, C.GLuint(program), C.GLint(location), C.GLint(v0))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetProgramPipelineiv.xml
+func (gl *GL) GetProgramPipelineiv(pipeline uint32, pname glbase.Enum, params []int32) {
+ C.gl4_2core_glGetProgramPipelineiv(gl.funcs, C.GLuint(pipeline), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsProgramPipeline.xml
+func (gl *GL) IsProgramPipeline(pipeline uint32) bool {
+ glresult := C.gl4_2core_glIsProgramPipeline(gl.funcs, C.GLuint(pipeline))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGenProgramPipelines.xml
+func (gl *GL) GenProgramPipelines(n int, pipelines []uint32) {
+ C.gl4_2core_glGenProgramPipelines(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&pipelines[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDeleteProgramPipelines.xml
+func (gl *GL) DeleteProgramPipelines(n int, pipelines []uint32) {
+ C.gl4_2core_glDeleteProgramPipelines(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&pipelines[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindProgramPipeline.xml
+func (gl *GL) BindProgramPipeline(pipeline uint32) {
+ C.gl4_2core_glBindProgramPipeline(gl.funcs, C.GLuint(pipeline))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glActiveShaderProgram.xml
+func (gl *GL) ActiveShaderProgram(pipeline uint32, program glbase.Program) {
+ C.gl4_2core_glActiveShaderProgram(gl.funcs, C.GLuint(pipeline), C.GLuint(program))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUseProgramStages.xml
+func (gl *GL) UseProgramStages(pipeline uint32, stages glbase.Bitfield, program glbase.Program) {
+ C.gl4_2core_glUseProgramStages(gl.funcs, C.GLuint(pipeline), C.GLbitfield(stages), C.GLuint(program))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramParameteri.xml
+func (gl *GL) ProgramParameteri(program glbase.Program, pname glbase.Enum, value int32) {
+ C.gl4_2core_glProgramParameteri(gl.funcs, C.GLuint(program), C.GLenum(pname), C.GLint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramBinary.xml
+func (gl *GL) ProgramBinary(program glbase.Program, binaryFormat glbase.Enum, binary interface{}, length int32) {
+ var binary_ptr unsafe.Pointer
+ var binary_v = reflect.ValueOf(binary)
+ if binary != nil && binary_v.Kind() != reflect.Slice {
+ panic("parameter binary must be a slice")
+ }
+ if binary != nil {
+ binary_ptr = unsafe.Pointer(binary_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2core_glProgramBinary(gl.funcs, C.GLuint(program), C.GLenum(binaryFormat), binary_ptr, C.GLsizei(length))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetProgramBinary.xml
+func (gl *GL) GetProgramBinary(program glbase.Program, bufSize int32, length []int32, binaryFormat []glbase.Enum, binary interface{}) {
+ var binary_ptr unsafe.Pointer
+ var binary_v = reflect.ValueOf(binary)
+ if binary != nil && binary_v.Kind() != reflect.Slice {
+ panic("parameter binary must be a slice")
+ }
+ if binary != nil {
+ binary_ptr = unsafe.Pointer(binary_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2core_glGetProgramBinary(gl.funcs, C.GLuint(program), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLenum)(unsafe.Pointer(&binaryFormat[0])), binary_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearDepthf.xml
+func (gl *GL) ClearDepthf(dd float32) {
+ C.gl4_2core_glClearDepthf(gl.funcs, C.GLfloat(dd))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDepthRangef.xml
+func (gl *GL) DepthRangef(n, f float32) {
+ C.gl4_2core_glDepthRangef(gl.funcs, C.GLfloat(n), C.GLfloat(f))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetShaderPrecisionFormat.xml
+func (gl *GL) GetShaderPrecisionFormat(shadertype, precisionType glbase.Enum, range_, precision []int32) {
+ C.gl4_2core_glGetShaderPrecisionFormat(gl.funcs, C.GLenum(shadertype), C.GLenum(precisionType), (*C.GLint)(unsafe.Pointer(&range_[0])), (*C.GLint)(unsafe.Pointer(&precision[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glShaderBinary.xml
+func (gl *GL) ShaderBinary(count int, shaders []glbase.Shader, binaryFormat glbase.Enum, binary interface{}, length int32) {
+ var binary_ptr unsafe.Pointer
+ var binary_v = reflect.ValueOf(binary)
+ if binary != nil && binary_v.Kind() != reflect.Slice {
+ panic("parameter binary must be a slice")
+ }
+ if binary != nil {
+ binary_ptr = unsafe.Pointer(binary_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2core_glShaderBinary(gl.funcs, C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&shaders[0])), C.GLenum(binaryFormat), binary_ptr, C.GLsizei(length))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glReleaseShaderCompiler.xml
+func (gl *GL) ReleaseShaderCompiler() {
+ C.gl4_2core_glReleaseShaderCompiler(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexStorage3D.xml
+func (gl *GL) TexStorage3D(target glbase.Enum, levels int32, internalFormat glbase.Enum, width, height int, depth int32) {
+ C.gl4_2core_glTexStorage3D(gl.funcs, C.GLenum(target), C.GLsizei(levels), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexStorage2D.xml
+func (gl *GL) TexStorage2D(target glbase.Enum, levels int32, internalFormat glbase.Enum, width, height int) {
+ C.gl4_2core_glTexStorage2D(gl.funcs, C.GLenum(target), C.GLsizei(levels), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexStorage1D.xml
+func (gl *GL) TexStorage1D(target glbase.Enum, levels int32, internalFormat glbase.Enum, width int) {
+ C.gl4_2core_glTexStorage1D(gl.funcs, C.GLenum(target), C.GLsizei(levels), C.GLenum(internalFormat), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMemoryBarrier.xml
+func (gl *GL) MemoryBarrier(barriers glbase.Bitfield) {
+ C.gl4_2core_glMemoryBarrier(gl.funcs, C.GLbitfield(barriers))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindImageTexture.xml
+func (gl *GL) BindImageTexture(unit uint32, texture glbase.Texture, level int, layered bool, layer int32, access, format glbase.Enum) {
+ C.gl4_2core_glBindImageTexture(gl.funcs, C.GLuint(unit), C.GLuint(texture), C.GLint(level), *(*C.GLboolean)(unsafe.Pointer(&layered)), C.GLint(layer), C.GLenum(access), C.GLenum(format))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveAtomicCounterBufferiv.xml
+func (gl *GL) GetActiveAtomicCounterBufferiv(program glbase.Program, bufferIndex uint32, pname glbase.Enum, params []int32) {
+ C.gl4_2core_glGetActiveAtomicCounterBufferiv(gl.funcs, C.GLuint(program), C.GLuint(bufferIndex), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetInternalformativ.xml
+func (gl *GL) GetInternalformativ(target, internalFormat, pname glbase.Enum, bufSize int32, params []int32) {
+ C.gl4_2core_glGetInternalformativ(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLenum(pname), C.GLsizei(bufSize), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawTransformFeedbackStreamInstanced.xml
+func (gl *GL) DrawTransformFeedbackStreamInstanced(mode glbase.Enum, id, stream uint32, instancecount int32) {
+ C.gl4_2core_glDrawTransformFeedbackStreamInstanced(gl.funcs, C.GLenum(mode), C.GLuint(id), C.GLuint(stream), C.GLsizei(instancecount))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawTransformFeedbackInstanced.xml
+func (gl *GL) DrawTransformFeedbackInstanced(mode glbase.Enum, id uint32, instancecount int32) {
+ C.gl4_2core_glDrawTransformFeedbackInstanced(gl.funcs, C.GLenum(mode), C.GLuint(id), C.GLsizei(instancecount))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawElementsInstancedBaseVertexBaseInstance.xml
+func (gl *GL) DrawElementsInstancedBaseVertexBaseInstance(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}, instancecount, basevertex int32, baseinstance uint32) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2core_glDrawElementsInstancedBaseVertexBaseInstance(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr, C.GLsizei(instancecount), C.GLint(basevertex), C.GLuint(baseinstance))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawElementsInstancedBaseInstance.xml
+func (gl *GL) DrawElementsInstancedBaseInstance(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}, instancecount int32, baseinstance uint32) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_2core_glDrawElementsInstancedBaseInstance(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr, C.GLsizei(instancecount), C.GLuint(baseinstance))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawArraysInstancedBaseInstance.xml
+func (gl *GL) DrawArraysInstancedBaseInstance(mode glbase.Enum, first, count int, instancecount int32, baseinstance uint32) {
+ C.gl4_2core_glDrawArraysInstancedBaseInstance(gl.funcs, C.GLenum(mode), C.GLint(first), C.GLsizei(count), C.GLsizei(instancecount), C.GLuint(baseinstance))
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.3compat/funcs.cpp b/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.3compat/funcs.cpp
new file mode 100644
index 000000000..04ab8fadd
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.3compat/funcs.cpp
@@ -0,0 +1,5556 @@
+
+// ** file automatically generated by glgen -- do not edit manually **
+
+#include <QOpenGLContext>
+#include <QtGui/qopenglfunctions_4_3_compatibility.h>
+
+#include "funcs.h"
+
+void *gl4_3compat_funcs() {
+ QOpenGLFunctions_4_3_Compatibility* funcs = QOpenGLContext::currentContext()->versionFunctions<QOpenGLFunctions_4_3_Compatibility>();
+ if (!funcs) {
+ return 0;
+ }
+ funcs->initializeOpenGLFunctions();
+ return funcs;
+}
+
+
+void gl4_3compat_glViewport(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glViewport(x, y, width, height);
+}
+
+void gl4_3compat_glDepthRange(void *_glfuncs, GLdouble nearVal, GLdouble farVal)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDepthRange(nearVal, farVal);
+}
+
+GLboolean gl4_3compat_glIsEnabled(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsEnabled(cap);
+}
+
+void gl4_3compat_glGetTexLevelParameteriv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexLevelParameteriv(target, level, pname, params);
+}
+
+void gl4_3compat_glGetTexLevelParameterfv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexLevelParameterfv(target, level, pname, params);
+}
+
+void gl4_3compat_glGetTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexParameteriv(target, pname, params);
+}
+
+void gl4_3compat_glGetTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexParameterfv(target, pname, params);
+}
+
+void gl4_3compat_glGetTexImage(void *_glfuncs, GLenum target, GLint level, GLenum format, GLenum gltype, GLvoid* pixels)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexImage(target, level, format, gltype, pixels);
+}
+
+void gl4_3compat_glGetIntegerv(void *_glfuncs, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetIntegerv(pname, params);
+}
+
+void gl4_3compat_glGetFloatv(void *_glfuncs, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetFloatv(pname, params);
+}
+
+GLenum gl4_3compat_glGetError(void *_glfuncs)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glGetError();
+}
+
+void gl4_3compat_glGetDoublev(void *_glfuncs, GLenum pname, GLdouble* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetDoublev(pname, params);
+}
+
+void gl4_3compat_glGetBooleanv(void *_glfuncs, GLenum pname, GLboolean* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetBooleanv(pname, params);
+}
+
+void gl4_3compat_glReadPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum gltype, GLvoid* pixels)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glReadPixels(x, y, width, height, format, gltype, pixels);
+}
+
+void gl4_3compat_glReadBuffer(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glReadBuffer(mode);
+}
+
+void gl4_3compat_glPixelStorei(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glPixelStorei(pname, param);
+}
+
+void gl4_3compat_glPixelStoref(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glPixelStoref(pname, param);
+}
+
+void gl4_3compat_glDepthFunc(void *_glfuncs, GLenum glfunc)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDepthFunc(glfunc);
+}
+
+void gl4_3compat_glStencilOp(void *_glfuncs, GLenum fail, GLenum zfail, GLenum zpass)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glStencilOp(fail, zfail, zpass);
+}
+
+void gl4_3compat_glStencilFunc(void *_glfuncs, GLenum glfunc, GLint ref, GLuint mask)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glStencilFunc(glfunc, ref, mask);
+}
+
+void gl4_3compat_glLogicOp(void *_glfuncs, GLenum opcode)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glLogicOp(opcode);
+}
+
+void gl4_3compat_glBlendFunc(void *_glfuncs, GLenum sfactor, GLenum dfactor)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glBlendFunc(sfactor, dfactor);
+}
+
+void gl4_3compat_glFlush(void *_glfuncs)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glFlush();
+}
+
+void gl4_3compat_glFinish(void *_glfuncs)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glFinish();
+}
+
+void gl4_3compat_glEnable(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glEnable(cap);
+}
+
+void gl4_3compat_glDisable(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDisable(cap);
+}
+
+void gl4_3compat_glDepthMask(void *_glfuncs, GLboolean flag)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDepthMask(flag);
+}
+
+void gl4_3compat_glColorMask(void *_glfuncs, GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorMask(red, green, blue, alpha);
+}
+
+void gl4_3compat_glStencilMask(void *_glfuncs, GLuint mask)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glStencilMask(mask);
+}
+
+void gl4_3compat_glClearDepth(void *_glfuncs, GLdouble depth)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glClearDepth(depth);
+}
+
+void gl4_3compat_glClearStencil(void *_glfuncs, GLint s)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glClearStencil(s);
+}
+
+void gl4_3compat_glClearColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glClearColor(red, green, blue, alpha);
+}
+
+void gl4_3compat_glClear(void *_glfuncs, GLbitfield mask)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glClear(mask);
+}
+
+void gl4_3compat_glDrawBuffer(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawBuffer(mode);
+}
+
+void gl4_3compat_glTexImage2D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexImage2D(target, level, internalFormat, width, height, border, format, gltype, pixels);
+}
+
+void gl4_3compat_glTexImage1D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexImage1D(target, level, internalFormat, width, border, format, gltype, pixels);
+}
+
+void gl4_3compat_glTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexParameteriv(target, pname, params);
+}
+
+void gl4_3compat_glTexParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexParameteri(target, pname, param);
+}
+
+void gl4_3compat_glTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexParameterfv(target, pname, params);
+}
+
+void gl4_3compat_glTexParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexParameterf(target, pname, param);
+}
+
+void gl4_3compat_glScissor(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glScissor(x, y, width, height);
+}
+
+void gl4_3compat_glPolygonMode(void *_glfuncs, GLenum face, GLenum mode)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glPolygonMode(face, mode);
+}
+
+void gl4_3compat_glPointSize(void *_glfuncs, GLfloat size)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glPointSize(size);
+}
+
+void gl4_3compat_glLineWidth(void *_glfuncs, GLfloat width)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glLineWidth(width);
+}
+
+void gl4_3compat_glHint(void *_glfuncs, GLenum target, GLenum mode)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glHint(target, mode);
+}
+
+void gl4_3compat_glFrontFace(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glFrontFace(mode);
+}
+
+void gl4_3compat_glCullFace(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glCullFace(mode);
+}
+
+void gl4_3compat_glIndexubv(void *_glfuncs, const GLubyte* c)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexubv(c);
+}
+
+void gl4_3compat_glIndexub(void *_glfuncs, GLubyte c)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexub(c);
+}
+
+GLboolean gl4_3compat_glIsTexture(void *_glfuncs, GLuint texture)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsTexture(texture);
+}
+
+void gl4_3compat_glGenTextures(void *_glfuncs, GLsizei n, GLuint* textures)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGenTextures(n, textures);
+}
+
+void gl4_3compat_glDeleteTextures(void *_glfuncs, GLsizei n, const GLuint* textures)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteTextures(n, textures);
+}
+
+void gl4_3compat_glBindTexture(void *_glfuncs, GLenum target, GLuint texture)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindTexture(target, texture);
+}
+
+void gl4_3compat_glTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexSubImage2D(target, level, xoffset, yoffset, width, height, format, gltype, pixels);
+}
+
+void gl4_3compat_glTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexSubImage1D(target, level, xoffset, width, format, gltype, pixels);
+}
+
+void gl4_3compat_glCopyTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage2D(target, level, xoffset, yoffset, x, y, width, height);
+}
+
+void gl4_3compat_glCopyTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage1D(target, level, xoffset, x, y, width);
+}
+
+void gl4_3compat_glCopyTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyTexImage2D(target, level, internalFormat, x, y, width, height, border);
+}
+
+void gl4_3compat_glCopyTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLint border)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyTexImage1D(target, level, internalFormat, x, y, width, border);
+}
+
+void gl4_3compat_glPolygonOffset(void *_glfuncs, GLfloat factor, GLfloat units)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glPolygonOffset(factor, units);
+}
+
+void gl4_3compat_glDrawElements(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawElements(mode, count, gltype, indices);
+}
+
+void gl4_3compat_glDrawArrays(void *_glfuncs, GLenum mode, GLint first, GLsizei count)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawArrays(mode, first, count);
+}
+
+void gl4_3compat_glCopyTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage3D(target, level, xoffset, yoffset, zoffset, x, y, width, height);
+}
+
+void gl4_3compat_glTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, gltype, pixels);
+}
+
+void gl4_3compat_glTexImage3D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexImage3D(target, level, internalFormat, width, height, depth, border, format, gltype, pixels);
+}
+
+void gl4_3compat_glDrawRangeElements(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawRangeElements(mode, start, end, count, gltype, indices);
+}
+
+void gl4_3compat_glBlendEquation(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glBlendEquation(mode);
+}
+
+void gl4_3compat_glBlendColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glBlendColor(red, green, blue, alpha);
+}
+
+void gl4_3compat_glGetCompressedTexImage(void *_glfuncs, GLenum target, GLint level, GLvoid* img)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetCompressedTexImage(target, level, img);
+}
+
+void gl4_3compat_glCompressedTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glCompressedTexSubImage1D(target, level, xoffset, width, format, imageSize, data);
+}
+
+void gl4_3compat_glCompressedTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glCompressedTexSubImage2D(target, level, xoffset, yoffset, width, height, format, imageSize, data);
+}
+
+void gl4_3compat_glCompressedTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glCompressedTexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, imageSize, data);
+}
+
+void gl4_3compat_glCompressedTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glCompressedTexImage1D(target, level, internalFormat, width, border, imageSize, data);
+}
+
+void gl4_3compat_glCompressedTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glCompressedTexImage2D(target, level, internalFormat, width, height, border, imageSize, data);
+}
+
+void gl4_3compat_glCompressedTexImage3D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glCompressedTexImage3D(target, level, internalFormat, width, height, depth, border, imageSize, data);
+}
+
+void gl4_3compat_glSampleCoverage(void *_glfuncs, GLfloat value, GLboolean invert)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glSampleCoverage(value, invert);
+}
+
+void gl4_3compat_glActiveTexture(void *_glfuncs, GLenum texture)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glActiveTexture(texture);
+}
+
+void gl4_3compat_glPointParameteriv(void *_glfuncs, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glPointParameteriv(pname, params);
+}
+
+void gl4_3compat_glPointParameteri(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glPointParameteri(pname, param);
+}
+
+void gl4_3compat_glPointParameterfv(void *_glfuncs, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glPointParameterfv(pname, params);
+}
+
+void gl4_3compat_glPointParameterf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glPointParameterf(pname, param);
+}
+
+void gl4_3compat_glMultiDrawArrays(void *_glfuncs, GLenum mode, const GLint* first, const GLsizei* count, GLsizei drawcount)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiDrawArrays(mode, first, count, drawcount);
+}
+
+void gl4_3compat_glBlendFuncSeparate(void *_glfuncs, GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glBlendFuncSeparate(sfactorRGB, dfactorRGB, sfactorAlpha, dfactorAlpha);
+}
+
+void gl4_3compat_glGetBufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetBufferParameteriv(target, pname, params);
+}
+
+GLboolean gl4_3compat_glUnmapBuffer(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glUnmapBuffer(target);
+}
+
+void gl4_3compat_glGetBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, GLvoid* data)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetBufferSubData(target, offset, size, data);
+}
+
+void gl4_3compat_glBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid* data)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glBufferSubData(target, offset, size, data);
+}
+
+void gl4_3compat_glBufferData(void *_glfuncs, GLenum target, GLsizeiptr size, const GLvoid* data, GLenum usage)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glBufferData(target, size, data, usage);
+}
+
+GLboolean gl4_3compat_glIsBuffer(void *_glfuncs, GLuint buffer)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsBuffer(buffer);
+}
+
+void gl4_3compat_glGenBuffers(void *_glfuncs, GLsizei n, GLuint* buffers)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGenBuffers(n, buffers);
+}
+
+void gl4_3compat_glDeleteBuffers(void *_glfuncs, GLsizei n, const GLuint* buffers)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteBuffers(n, buffers);
+}
+
+void gl4_3compat_glBindBuffer(void *_glfuncs, GLenum target, GLuint buffer)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindBuffer(target, buffer);
+}
+
+void gl4_3compat_glGetQueryObjectuiv(void *_glfuncs, GLuint id, GLenum pname, GLuint* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetQueryObjectuiv(id, pname, params);
+}
+
+void gl4_3compat_glGetQueryObjectiv(void *_glfuncs, GLuint id, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetQueryObjectiv(id, pname, params);
+}
+
+void gl4_3compat_glGetQueryiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetQueryiv(target, pname, params);
+}
+
+void gl4_3compat_glEndQuery(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glEndQuery(target);
+}
+
+void gl4_3compat_glBeginQuery(void *_glfuncs, GLenum target, GLuint id)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glBeginQuery(target, id);
+}
+
+GLboolean gl4_3compat_glIsQuery(void *_glfuncs, GLuint id)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsQuery(id);
+}
+
+void gl4_3compat_glDeleteQueries(void *_glfuncs, GLsizei n, const GLuint* ids)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteQueries(n, ids);
+}
+
+void gl4_3compat_glGenQueries(void *_glfuncs, GLsizei n, GLuint* ids)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGenQueries(n, ids);
+}
+
+void gl4_3compat_glVertexAttribPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLboolean normalized, GLsizei stride, const GLvoid* offset)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribPointer(index, size, gltype, normalized, stride, offset);
+}
+
+void gl4_3compat_glValidateProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glValidateProgram(program);
+}
+
+void gl4_3compat_glUniformMatrix4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4fv(location, count, transpose, value);
+}
+
+void gl4_3compat_glUniformMatrix3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3fv(location, count, transpose, value);
+}
+
+void gl4_3compat_glUniformMatrix2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2fv(location, count, transpose, value);
+}
+
+void gl4_3compat_glUniform4iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform4iv(location, count, value);
+}
+
+void gl4_3compat_glUniform3iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform3iv(location, count, value);
+}
+
+void gl4_3compat_glUniform2iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform2iv(location, count, value);
+}
+
+void gl4_3compat_glUniform1iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform1iv(location, count, value);
+}
+
+void gl4_3compat_glUniform4fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform4fv(location, count, value);
+}
+
+void gl4_3compat_glUniform3fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform3fv(location, count, value);
+}
+
+void gl4_3compat_glUniform2fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform2fv(location, count, value);
+}
+
+void gl4_3compat_glUniform1fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform1fv(location, count, value);
+}
+
+void gl4_3compat_glUniform4i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2, GLint v3)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform4i(location, v0, v1, v2, v3);
+}
+
+void gl4_3compat_glUniform3i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform3i(location, v0, v1, v2);
+}
+
+void gl4_3compat_glUniform2i(void *_glfuncs, GLint location, GLint v0, GLint v1)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform2i(location, v0, v1);
+}
+
+void gl4_3compat_glUniform1i(void *_glfuncs, GLint location, GLint v0)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform1i(location, v0);
+}
+
+void gl4_3compat_glUniform4f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform4f(location, v0, v1, v2, v3);
+}
+
+void gl4_3compat_glUniform3f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform3f(location, v0, v1, v2);
+}
+
+void gl4_3compat_glUniform2f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform2f(location, v0, v1);
+}
+
+void gl4_3compat_glUniform1f(void *_glfuncs, GLint location, GLfloat v0)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform1f(location, v0);
+}
+
+void gl4_3compat_glUseProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUseProgram(program);
+}
+
+void gl4_3compat_glShaderSource(void *_glfuncs, GLuint shader, GLsizei count, const GLchar** source, const GLint* length)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glShaderSource(shader, count, source, length);
+}
+
+void gl4_3compat_glLinkProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glLinkProgram(program);
+}
+
+GLboolean gl4_3compat_glIsShader(void *_glfuncs, GLuint shader)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsShader(shader);
+}
+
+GLboolean gl4_3compat_glIsProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsProgram(program);
+}
+
+void gl4_3compat_glGetVertexAttribiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribiv(index, pname, params);
+}
+
+void gl4_3compat_glGetVertexAttribfv(void *_glfuncs, GLuint index, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribfv(index, pname, params);
+}
+
+void gl4_3compat_glGetVertexAttribdv(void *_glfuncs, GLuint index, GLenum pname, GLdouble* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribdv(index, pname, params);
+}
+
+void gl4_3compat_glGetUniformiv(void *_glfuncs, GLuint program, GLint location, GLint* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetUniformiv(program, location, params);
+}
+
+void gl4_3compat_glGetUniformfv(void *_glfuncs, GLuint program, GLint location, GLfloat* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetUniformfv(program, location, params);
+}
+
+GLint gl4_3compat_glGetUniformLocation(void *_glfuncs, GLuint program, const GLchar* name)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glGetUniformLocation(program, name);
+}
+
+void gl4_3compat_glGetShaderSource(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* source)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetShaderSource(shader, bufSize, length, source);
+}
+
+void gl4_3compat_glGetShaderInfoLog(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* infoLog)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetShaderInfoLog(shader, bufSize, length, infoLog);
+}
+
+void gl4_3compat_glGetShaderiv(void *_glfuncs, GLuint shader, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetShaderiv(shader, pname, params);
+}
+
+void gl4_3compat_glGetProgramInfoLog(void *_glfuncs, GLuint program, GLsizei bufSize, GLsizei* length, GLchar* infoLog)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetProgramInfoLog(program, bufSize, length, infoLog);
+}
+
+void gl4_3compat_glGetProgramiv(void *_glfuncs, GLuint program, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetProgramiv(program, pname, params);
+}
+
+GLint gl4_3compat_glGetAttribLocation(void *_glfuncs, GLuint program, const GLchar* name)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glGetAttribLocation(program, name);
+}
+
+void gl4_3compat_glGetAttachedShaders(void *_glfuncs, GLuint program, GLsizei maxCount, GLsizei* count, GLuint* obj)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetAttachedShaders(program, maxCount, count, obj);
+}
+
+void gl4_3compat_glGetActiveUniform(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetActiveUniform(program, index, bufSize, length, size, gltype, name);
+}
+
+void gl4_3compat_glGetActiveAttrib(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetActiveAttrib(program, index, bufSize, length, size, gltype, name);
+}
+
+void gl4_3compat_glEnableVertexAttribArray(void *_glfuncs, GLuint index)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glEnableVertexAttribArray(index);
+}
+
+void gl4_3compat_glDisableVertexAttribArray(void *_glfuncs, GLuint index)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDisableVertexAttribArray(index);
+}
+
+void gl4_3compat_glDetachShader(void *_glfuncs, GLuint program, GLuint shader)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDetachShader(program, shader);
+}
+
+void gl4_3compat_glDeleteShader(void *_glfuncs, GLuint shader)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteShader(shader);
+}
+
+void gl4_3compat_glDeleteProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteProgram(program);
+}
+
+GLuint gl4_3compat_glCreateShader(void *_glfuncs, GLenum gltype)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glCreateShader(gltype);
+}
+
+GLuint gl4_3compat_glCreateProgram(void *_glfuncs)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glCreateProgram();
+}
+
+void gl4_3compat_glCompileShader(void *_glfuncs, GLuint shader)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glCompileShader(shader);
+}
+
+void gl4_3compat_glBindAttribLocation(void *_glfuncs, GLuint program, GLuint index, const GLchar* name)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindAttribLocation(program, index, name);
+}
+
+void gl4_3compat_glAttachShader(void *_glfuncs, GLuint program, GLuint shader)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glAttachShader(program, shader);
+}
+
+void gl4_3compat_glStencilMaskSeparate(void *_glfuncs, GLenum face, GLuint mask)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glStencilMaskSeparate(face, mask);
+}
+
+void gl4_3compat_glStencilFuncSeparate(void *_glfuncs, GLenum face, GLenum glfunc, GLint ref, GLuint mask)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glStencilFuncSeparate(face, glfunc, ref, mask);
+}
+
+void gl4_3compat_glStencilOpSeparate(void *_glfuncs, GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glStencilOpSeparate(face, sfail, dpfail, dppass);
+}
+
+void gl4_3compat_glDrawBuffers(void *_glfuncs, GLsizei n, const GLenum* bufs)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawBuffers(n, bufs);
+}
+
+void gl4_3compat_glBlendEquationSeparate(void *_glfuncs, GLenum modeRGB, GLenum modeAlpha)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glBlendEquationSeparate(modeRGB, modeAlpha);
+}
+
+void gl4_3compat_glUniformMatrix4x3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4x3fv(location, count, transpose, value);
+}
+
+void gl4_3compat_glUniformMatrix3x4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3x4fv(location, count, transpose, value);
+}
+
+void gl4_3compat_glUniformMatrix4x2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4x2fv(location, count, transpose, value);
+}
+
+void gl4_3compat_glUniformMatrix2x4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2x4fv(location, count, transpose, value);
+}
+
+void gl4_3compat_glUniformMatrix3x2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3x2fv(location, count, transpose, value);
+}
+
+void gl4_3compat_glUniformMatrix2x3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2x3fv(location, count, transpose, value);
+}
+
+GLboolean gl4_3compat_glIsVertexArray(void *_glfuncs, GLuint array)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsVertexArray(array);
+}
+
+void gl4_3compat_glGenVertexArrays(void *_glfuncs, GLsizei n, GLuint* arrays)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGenVertexArrays(n, arrays);
+}
+
+void gl4_3compat_glDeleteVertexArrays(void *_glfuncs, GLsizei n, const GLuint* arrays)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteVertexArrays(n, arrays);
+}
+
+void gl4_3compat_glBindVertexArray(void *_glfuncs, GLuint array)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindVertexArray(array);
+}
+
+void gl4_3compat_glFlushMappedBufferRange(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr length)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glFlushMappedBufferRange(target, offset, length);
+}
+
+void gl4_3compat_glFramebufferTextureLayer(void *_glfuncs, GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glFramebufferTextureLayer(target, attachment, texture, level, layer);
+}
+
+void gl4_3compat_glRenderbufferStorageMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLenum internalFormat, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRenderbufferStorageMultisample(target, samples, internalFormat, width, height);
+}
+
+void gl4_3compat_glBlitFramebuffer(void *_glfuncs, GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glBlitFramebuffer(srcX0, srcY0, srcX1, srcY1, dstX0, dstY0, dstX1, dstY1, mask, filter);
+}
+
+void gl4_3compat_glGenerateMipmap(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGenerateMipmap(target);
+}
+
+void gl4_3compat_glGetFramebufferAttachmentParameteriv(void *_glfuncs, GLenum target, GLenum attachment, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetFramebufferAttachmentParameteriv(target, attachment, pname, params);
+}
+
+void gl4_3compat_glFramebufferRenderbuffer(void *_glfuncs, GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glFramebufferRenderbuffer(target, attachment, renderbuffertarget, renderbuffer);
+}
+
+void gl4_3compat_glFramebufferTexture3D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glFramebufferTexture3D(target, attachment, textarget, texture, level, zoffset);
+}
+
+void gl4_3compat_glFramebufferTexture2D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glFramebufferTexture2D(target, attachment, textarget, texture, level);
+}
+
+void gl4_3compat_glFramebufferTexture1D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glFramebufferTexture1D(target, attachment, textarget, texture, level);
+}
+
+GLenum gl4_3compat_glCheckFramebufferStatus(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glCheckFramebufferStatus(target);
+}
+
+void gl4_3compat_glGenFramebuffers(void *_glfuncs, GLsizei n, GLuint* framebuffers)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGenFramebuffers(n, framebuffers);
+}
+
+void gl4_3compat_glDeleteFramebuffers(void *_glfuncs, GLsizei n, const GLuint* framebuffers)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteFramebuffers(n, framebuffers);
+}
+
+void gl4_3compat_glBindFramebuffer(void *_glfuncs, GLenum target, GLuint framebuffer)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindFramebuffer(target, framebuffer);
+}
+
+GLboolean gl4_3compat_glIsFramebuffer(void *_glfuncs, GLuint framebuffer)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsFramebuffer(framebuffer);
+}
+
+void gl4_3compat_glGetRenderbufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetRenderbufferParameteriv(target, pname, params);
+}
+
+void gl4_3compat_glRenderbufferStorage(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRenderbufferStorage(target, internalFormat, width, height);
+}
+
+void gl4_3compat_glGenRenderbuffers(void *_glfuncs, GLsizei n, GLuint* renderbuffers)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGenRenderbuffers(n, renderbuffers);
+}
+
+void gl4_3compat_glDeleteRenderbuffers(void *_glfuncs, GLsizei n, const GLuint* renderbuffers)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteRenderbuffers(n, renderbuffers);
+}
+
+void gl4_3compat_glBindRenderbuffer(void *_glfuncs, GLenum target, GLuint renderbuffer)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindRenderbuffer(target, renderbuffer);
+}
+
+GLboolean gl4_3compat_glIsRenderbuffer(void *_glfuncs, GLuint renderbuffer)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsRenderbuffer(renderbuffer);
+}
+
+void gl4_3compat_glClearBufferfi(void *_glfuncs, GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glClearBufferfi(buffer, drawbuffer, depth, stencil);
+}
+
+void gl4_3compat_glClearBufferfv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLfloat* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glClearBufferfv(buffer, drawbuffer, value);
+}
+
+void gl4_3compat_glClearBufferuiv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLuint* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glClearBufferuiv(buffer, drawbuffer, value);
+}
+
+void gl4_3compat_glClearBufferiv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLint* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glClearBufferiv(buffer, drawbuffer, value);
+}
+
+void gl4_3compat_glGetTexParameterIuiv(void *_glfuncs, GLenum target, GLenum pname, GLuint* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexParameterIuiv(target, pname, params);
+}
+
+void gl4_3compat_glGetTexParameterIiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexParameterIiv(target, pname, params);
+}
+
+void gl4_3compat_glTexParameterIuiv(void *_glfuncs, GLenum target, GLenum pname, const GLuint* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexParameterIuiv(target, pname, params);
+}
+
+void gl4_3compat_glTexParameterIiv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexParameterIiv(target, pname, params);
+}
+
+void gl4_3compat_glUniform4uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform4uiv(location, count, value);
+}
+
+void gl4_3compat_glUniform3uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform3uiv(location, count, value);
+}
+
+void gl4_3compat_glUniform2uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform2uiv(location, count, value);
+}
+
+void gl4_3compat_glUniform1uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform1uiv(location, count, value);
+}
+
+void gl4_3compat_glUniform4ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform4ui(location, v0, v1, v2, v3);
+}
+
+void gl4_3compat_glUniform3ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1, GLuint v2)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform3ui(location, v0, v1, v2);
+}
+
+void gl4_3compat_glUniform2ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform2ui(location, v0, v1);
+}
+
+void gl4_3compat_glUniform1ui(void *_glfuncs, GLint location, GLuint v0)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform1ui(location, v0);
+}
+
+GLint gl4_3compat_glGetFragDataLocation(void *_glfuncs, GLuint program, const GLchar* name)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glGetFragDataLocation(program, name);
+}
+
+void gl4_3compat_glBindFragDataLocation(void *_glfuncs, GLuint program, GLuint color, const GLchar* name)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindFragDataLocation(program, color, name);
+}
+
+void gl4_3compat_glGetUniformuiv(void *_glfuncs, GLuint program, GLint location, GLuint* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetUniformuiv(program, location, params);
+}
+
+void gl4_3compat_glGetVertexAttribIuiv(void *_glfuncs, GLuint index, GLenum pname, GLuint* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribIuiv(index, pname, params);
+}
+
+void gl4_3compat_glGetVertexAttribIiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribIiv(index, pname, params);
+}
+
+void gl4_3compat_glVertexAttribIPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribIPointer(index, size, gltype, stride, pointer);
+}
+
+void gl4_3compat_glEndConditionalRender(void *_glfuncs)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glEndConditionalRender();
+}
+
+void gl4_3compat_glBeginConditionalRender(void *_glfuncs, GLuint id, GLenum mode)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glBeginConditionalRender(id, mode);
+}
+
+void gl4_3compat_glClampColor(void *_glfuncs, GLenum target, GLenum clamp)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glClampColor(target, clamp);
+}
+
+void gl4_3compat_glGetTransformFeedbackVarying(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLsizei* size, GLenum* gltype, GLchar* name)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTransformFeedbackVarying(program, index, bufSize, length, size, gltype, name);
+}
+
+void gl4_3compat_glBindBufferBase(void *_glfuncs, GLenum target, GLuint index, GLuint buffer)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindBufferBase(target, index, buffer);
+}
+
+void gl4_3compat_glBindBufferRange(void *_glfuncs, GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindBufferRange(target, index, buffer, offset, size);
+}
+
+void gl4_3compat_glEndTransformFeedback(void *_glfuncs)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glEndTransformFeedback();
+}
+
+void gl4_3compat_glBeginTransformFeedback(void *_glfuncs, GLenum primitiveMode)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glBeginTransformFeedback(primitiveMode);
+}
+
+GLboolean gl4_3compat_glIsEnabledi(void *_glfuncs, GLenum target, GLuint index)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsEnabledi(target, index);
+}
+
+void gl4_3compat_glDisablei(void *_glfuncs, GLenum target, GLuint index)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDisablei(target, index);
+}
+
+void gl4_3compat_glEnablei(void *_glfuncs, GLenum target, GLuint index)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glEnablei(target, index);
+}
+
+void gl4_3compat_glGetIntegeri_v(void *_glfuncs, GLenum target, GLuint index, GLint* data)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetIntegeri_v(target, index, data);
+}
+
+void gl4_3compat_glGetBooleani_v(void *_glfuncs, GLenum target, GLuint index, GLboolean* data)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetBooleani_v(target, index, data);
+}
+
+void gl4_3compat_glColorMaski(void *_glfuncs, GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorMaski(index, r, g, b, a);
+}
+
+void gl4_3compat_glCopyBufferSubData(void *_glfuncs, GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyBufferSubData(readTarget, writeTarget, readOffset, writeOffset, size);
+}
+
+void gl4_3compat_glUniformBlockBinding(void *_glfuncs, GLuint program, GLuint v0, GLuint v1)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformBlockBinding(program, v0, v1);
+}
+
+void gl4_3compat_glGetActiveUniformBlockName(void *_glfuncs, GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei* length, GLchar* uniformBlockName)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetActiveUniformBlockName(program, uniformBlockIndex, bufSize, length, uniformBlockName);
+}
+
+void gl4_3compat_glGetActiveUniformBlockiv(void *_glfuncs, GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetActiveUniformBlockiv(program, uniformBlockIndex, pname, params);
+}
+
+GLuint gl4_3compat_glGetUniformBlockIndex(void *_glfuncs, GLuint program, const GLchar* uniformBlockName)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glGetUniformBlockIndex(program, uniformBlockName);
+}
+
+void gl4_3compat_glGetActiveUniformName(void *_glfuncs, GLuint program, GLuint uniformIndex, GLsizei bufSize, GLsizei* length, GLchar* uniformName)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetActiveUniformName(program, uniformIndex, bufSize, length, uniformName);
+}
+
+void gl4_3compat_glGetActiveUniformsiv(void *_glfuncs, GLuint program, GLsizei uniformCount, const GLuint* uniformIndices, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetActiveUniformsiv(program, uniformCount, uniformIndices, pname, params);
+}
+
+void gl4_3compat_glPrimitiveRestartIndex(void *_glfuncs, GLuint index)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glPrimitiveRestartIndex(index);
+}
+
+void gl4_3compat_glTexBuffer(void *_glfuncs, GLenum target, GLenum internalFormat, GLuint buffer)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexBuffer(target, internalFormat, buffer);
+}
+
+void gl4_3compat_glDrawElementsInstanced(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawElementsInstanced(mode, count, gltype, indices, instancecount);
+}
+
+void gl4_3compat_glDrawArraysInstanced(void *_glfuncs, GLenum mode, GLint first, GLsizei count, GLsizei instancecount)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawArraysInstanced(mode, first, count, instancecount);
+}
+
+void gl4_3compat_glSampleMaski(void *_glfuncs, GLuint index, GLbitfield mask)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glSampleMaski(index, mask);
+}
+
+void gl4_3compat_glGetMultisamplefv(void *_glfuncs, GLenum pname, GLuint index, GLfloat* val)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetMultisamplefv(pname, index, val);
+}
+
+void gl4_3compat_glTexImage3DMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexImage3DMultisample(target, samples, internalFormat, width, height, depth, fixedsamplelocations);
+}
+
+void gl4_3compat_glTexImage2DMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLint internalFormat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexImage2DMultisample(target, samples, internalFormat, width, height, fixedsamplelocations);
+}
+
+void gl4_3compat_glGetSynciv(void *_glfuncs, GLsync sync, GLenum pname, GLsizei bufSize, GLsizei* length, GLint* values)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetSynciv(sync, pname, bufSize, length, values);
+}
+
+void gl4_3compat_glGetInteger64v(void *_glfuncs, GLenum pname, GLint64* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetInteger64v(pname, params);
+}
+
+void gl4_3compat_glWaitSync(void *_glfuncs, GLsync sync, GLbitfield flags, GLuint64 timeout)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glWaitSync(sync, flags, timeout);
+}
+
+GLenum gl4_3compat_glClientWaitSync(void *_glfuncs, GLsync sync, GLbitfield flags, GLuint64 timeout)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glClientWaitSync(sync, flags, timeout);
+}
+
+void gl4_3compat_glDeleteSync(void *_glfuncs, GLsync sync)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteSync(sync);
+}
+
+GLboolean gl4_3compat_glIsSync(void *_glfuncs, GLsync sync)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsSync(sync);
+}
+
+GLsync gl4_3compat_glFenceSync(void *_glfuncs, GLenum condition, GLbitfield flags)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glFenceSync(condition, flags);
+}
+
+void gl4_3compat_glProvokingVertex(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glProvokingVertex(mode);
+}
+
+void gl4_3compat_glDrawElementsInstancedBaseVertex(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount, GLint basevertex)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawElementsInstancedBaseVertex(mode, count, gltype, indices, instancecount, basevertex);
+}
+
+void gl4_3compat_glDrawRangeElementsBaseVertex(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices, GLint basevertex)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawRangeElementsBaseVertex(mode, start, end, count, gltype, indices, basevertex);
+}
+
+void gl4_3compat_glDrawElementsBaseVertex(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLint basevertex)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawElementsBaseVertex(mode, count, gltype, indices, basevertex);
+}
+
+void gl4_3compat_glFramebufferTexture(void *_glfuncs, GLenum target, GLenum attachment, GLuint texture, GLint level)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glFramebufferTexture(target, attachment, texture, level);
+}
+
+void gl4_3compat_glGetBufferParameteri64v(void *_glfuncs, GLenum target, GLenum pname, GLint64* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetBufferParameteri64v(target, pname, params);
+}
+
+void gl4_3compat_glGetInteger64i_v(void *_glfuncs, GLenum target, GLuint index, GLint64* data)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetInteger64i_v(target, index, data);
+}
+
+void gl4_3compat_glVertexAttribP4uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribP4uiv(index, gltype, normalized, value);
+}
+
+void gl4_3compat_glVertexAttribP4ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribP4ui(index, gltype, normalized, value);
+}
+
+void gl4_3compat_glVertexAttribP3uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribP3uiv(index, gltype, normalized, value);
+}
+
+void gl4_3compat_glVertexAttribP3ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribP3ui(index, gltype, normalized, value);
+}
+
+void gl4_3compat_glVertexAttribP2uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribP2uiv(index, gltype, normalized, value);
+}
+
+void gl4_3compat_glVertexAttribP2ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribP2ui(index, gltype, normalized, value);
+}
+
+void gl4_3compat_glVertexAttribP1uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribP1uiv(index, gltype, normalized, value);
+}
+
+void gl4_3compat_glVertexAttribP1ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribP1ui(index, gltype, normalized, value);
+}
+
+void gl4_3compat_glSecondaryColorP3uiv(void *_glfuncs, GLenum gltype, const GLuint* color)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColorP3uiv(gltype, color);
+}
+
+void gl4_3compat_glSecondaryColorP3ui(void *_glfuncs, GLenum gltype, GLuint color)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColorP3ui(gltype, color);
+}
+
+void gl4_3compat_glColorP4uiv(void *_glfuncs, GLenum gltype, const GLuint* color)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorP4uiv(gltype, color);
+}
+
+void gl4_3compat_glColorP4ui(void *_glfuncs, GLenum gltype, GLuint color)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorP4ui(gltype, color);
+}
+
+void gl4_3compat_glColorP3uiv(void *_glfuncs, GLenum gltype, const GLuint* color)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorP3uiv(gltype, color);
+}
+
+void gl4_3compat_glColorP3ui(void *_glfuncs, GLenum gltype, GLuint color)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorP3ui(gltype, color);
+}
+
+void gl4_3compat_glNormalP3uiv(void *_glfuncs, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormalP3uiv(gltype, coords);
+}
+
+void gl4_3compat_glNormalP3ui(void *_glfuncs, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormalP3ui(gltype, coords);
+}
+
+void gl4_3compat_glMultiTexCoordP4uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP4uiv(texture, gltype, coords);
+}
+
+void gl4_3compat_glMultiTexCoordP4ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP4ui(texture, gltype, coords);
+}
+
+void gl4_3compat_glMultiTexCoordP3uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP3uiv(texture, gltype, coords);
+}
+
+void gl4_3compat_glMultiTexCoordP3ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP3ui(texture, gltype, coords);
+}
+
+void gl4_3compat_glMultiTexCoordP2uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP2uiv(texture, gltype, coords);
+}
+
+void gl4_3compat_glMultiTexCoordP2ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP2ui(texture, gltype, coords);
+}
+
+void gl4_3compat_glMultiTexCoordP1uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP1uiv(texture, gltype, coords);
+}
+
+void gl4_3compat_glMultiTexCoordP1ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP1ui(texture, gltype, coords);
+}
+
+void gl4_3compat_glTexCoordP4uiv(void *_glfuncs, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoordP4uiv(gltype, coords);
+}
+
+void gl4_3compat_glTexCoordP4ui(void *_glfuncs, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoordP4ui(gltype, coords);
+}
+
+void gl4_3compat_glTexCoordP3uiv(void *_glfuncs, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoordP3uiv(gltype, coords);
+}
+
+void gl4_3compat_glTexCoordP3ui(void *_glfuncs, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoordP3ui(gltype, coords);
+}
+
+void gl4_3compat_glTexCoordP2uiv(void *_glfuncs, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoordP2uiv(gltype, coords);
+}
+
+void gl4_3compat_glTexCoordP2ui(void *_glfuncs, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoordP2ui(gltype, coords);
+}
+
+void gl4_3compat_glTexCoordP1uiv(void *_glfuncs, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoordP1uiv(gltype, coords);
+}
+
+void gl4_3compat_glTexCoordP1ui(void *_glfuncs, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoordP1ui(gltype, coords);
+}
+
+void gl4_3compat_glVertexP4uiv(void *_glfuncs, GLenum gltype, const GLuint* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexP4uiv(gltype, value);
+}
+
+void gl4_3compat_glVertexP4ui(void *_glfuncs, GLenum gltype, GLuint value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexP4ui(gltype, value);
+}
+
+void gl4_3compat_glVertexP3uiv(void *_glfuncs, GLenum gltype, const GLuint* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexP3uiv(gltype, value);
+}
+
+void gl4_3compat_glVertexP3ui(void *_glfuncs, GLenum gltype, GLuint value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexP3ui(gltype, value);
+}
+
+void gl4_3compat_glVertexP2uiv(void *_glfuncs, GLenum gltype, const GLuint* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexP2uiv(gltype, value);
+}
+
+void gl4_3compat_glVertexP2ui(void *_glfuncs, GLenum gltype, GLuint value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexP2ui(gltype, value);
+}
+
+void gl4_3compat_glGetQueryObjectui64v(void *_glfuncs, GLuint id, GLenum pname, GLuint64* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetQueryObjectui64v(id, pname, params);
+}
+
+void gl4_3compat_glGetQueryObjecti64v(void *_glfuncs, GLuint id, GLenum pname, GLint64* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetQueryObjecti64v(id, pname, params);
+}
+
+void gl4_3compat_glQueryCounter(void *_glfuncs, GLuint id, GLenum target)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glQueryCounter(id, target);
+}
+
+void gl4_3compat_glGetSamplerParameterIuiv(void *_glfuncs, GLuint sampler, GLenum pname, GLuint* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetSamplerParameterIuiv(sampler, pname, params);
+}
+
+void gl4_3compat_glGetSamplerParameterfv(void *_glfuncs, GLuint sampler, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetSamplerParameterfv(sampler, pname, params);
+}
+
+void gl4_3compat_glGetSamplerParameterIiv(void *_glfuncs, GLuint sampler, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetSamplerParameterIiv(sampler, pname, params);
+}
+
+void gl4_3compat_glGetSamplerParameteriv(void *_glfuncs, GLuint sampler, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetSamplerParameteriv(sampler, pname, params);
+}
+
+void gl4_3compat_glSamplerParameterIuiv(void *_glfuncs, GLuint sampler, GLenum pname, const GLuint* param)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glSamplerParameterIuiv(sampler, pname, param);
+}
+
+void gl4_3compat_glSamplerParameterIiv(void *_glfuncs, GLuint sampler, GLenum pname, const GLint* param)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glSamplerParameterIiv(sampler, pname, param);
+}
+
+void gl4_3compat_glSamplerParameterfv(void *_glfuncs, GLuint sampler, GLenum pname, const GLfloat* param)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glSamplerParameterfv(sampler, pname, param);
+}
+
+void gl4_3compat_glSamplerParameterf(void *_glfuncs, GLuint sampler, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glSamplerParameterf(sampler, pname, param);
+}
+
+void gl4_3compat_glSamplerParameteriv(void *_glfuncs, GLuint sampler, GLenum pname, const GLint* param)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glSamplerParameteriv(sampler, pname, param);
+}
+
+void gl4_3compat_glSamplerParameteri(void *_glfuncs, GLuint sampler, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glSamplerParameteri(sampler, pname, param);
+}
+
+void gl4_3compat_glBindSampler(void *_glfuncs, GLuint unit, GLuint sampler)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindSampler(unit, sampler);
+}
+
+GLboolean gl4_3compat_glIsSampler(void *_glfuncs, GLuint sampler)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsSampler(sampler);
+}
+
+void gl4_3compat_glDeleteSamplers(void *_glfuncs, GLsizei count, const GLuint* samplers)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteSamplers(count, samplers);
+}
+
+void gl4_3compat_glGenSamplers(void *_glfuncs, GLsizei count, GLuint* samplers)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGenSamplers(count, samplers);
+}
+
+GLint gl4_3compat_glGetFragDataIndex(void *_glfuncs, GLuint program, const GLchar* name)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glGetFragDataIndex(program, name);
+}
+
+void gl4_3compat_glBindFragDataLocationIndexed(void *_glfuncs, GLuint program, GLuint colorNumber, GLuint index, const GLchar* name)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindFragDataLocationIndexed(program, colorNumber, index, name);
+}
+
+void gl4_3compat_glVertexAttribDivisor(void *_glfuncs, GLuint index, GLuint divisor)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribDivisor(index, divisor);
+}
+
+void gl4_3compat_glGetQueryIndexediv(void *_glfuncs, GLenum target, GLuint index, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetQueryIndexediv(target, index, pname, params);
+}
+
+void gl4_3compat_glEndQueryIndexed(void *_glfuncs, GLenum target, GLuint index)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glEndQueryIndexed(target, index);
+}
+
+void gl4_3compat_glBeginQueryIndexed(void *_glfuncs, GLenum target, GLuint index, GLuint id)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glBeginQueryIndexed(target, index, id);
+}
+
+void gl4_3compat_glDrawTransformFeedbackStream(void *_glfuncs, GLenum mode, GLuint id, GLuint stream)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawTransformFeedbackStream(mode, id, stream);
+}
+
+void gl4_3compat_glDrawTransformFeedback(void *_glfuncs, GLenum mode, GLuint id)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawTransformFeedback(mode, id);
+}
+
+void gl4_3compat_glResumeTransformFeedback(void *_glfuncs)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glResumeTransformFeedback();
+}
+
+void gl4_3compat_glPauseTransformFeedback(void *_glfuncs)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glPauseTransformFeedback();
+}
+
+GLboolean gl4_3compat_glIsTransformFeedback(void *_glfuncs, GLuint id)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsTransformFeedback(id);
+}
+
+void gl4_3compat_glGenTransformFeedbacks(void *_glfuncs, GLsizei n, GLuint* ids)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGenTransformFeedbacks(n, ids);
+}
+
+void gl4_3compat_glDeleteTransformFeedbacks(void *_glfuncs, GLsizei n, const GLuint* ids)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteTransformFeedbacks(n, ids);
+}
+
+void gl4_3compat_glBindTransformFeedback(void *_glfuncs, GLenum target, GLuint id)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindTransformFeedback(target, id);
+}
+
+void gl4_3compat_glPatchParameterfv(void *_glfuncs, GLenum pname, const GLfloat* values)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glPatchParameterfv(pname, values);
+}
+
+void gl4_3compat_glPatchParameteri(void *_glfuncs, GLenum pname, GLint value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glPatchParameteri(pname, value);
+}
+
+void gl4_3compat_glGetProgramStageiv(void *_glfuncs, GLuint program, GLenum shadertype, GLenum pname, GLint* values)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetProgramStageiv(program, shadertype, pname, values);
+}
+
+void gl4_3compat_glGetUniformSubroutineuiv(void *_glfuncs, GLenum shadertype, GLint location, GLuint* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetUniformSubroutineuiv(shadertype, location, params);
+}
+
+void gl4_3compat_glUniformSubroutinesuiv(void *_glfuncs, GLenum shadertype, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformSubroutinesuiv(shadertype, count, value);
+}
+
+void gl4_3compat_glGetActiveSubroutineName(void *_glfuncs, GLuint program, GLenum shadertype, GLuint index, GLsizei bufSize, GLsizei* length, GLchar* name)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetActiveSubroutineName(program, shadertype, index, bufSize, length, name);
+}
+
+void gl4_3compat_glGetActiveSubroutineUniformName(void *_glfuncs, GLuint program, GLenum shadertype, GLuint index, GLsizei bufSize, GLsizei* length, GLchar* name)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetActiveSubroutineUniformName(program, shadertype, index, bufSize, length, name);
+}
+
+void gl4_3compat_glGetActiveSubroutineUniformiv(void *_glfuncs, GLuint program, GLenum shadertype, GLuint index, GLenum pname, GLint* values)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetActiveSubroutineUniformiv(program, shadertype, index, pname, values);
+}
+
+GLuint gl4_3compat_glGetSubroutineIndex(void *_glfuncs, GLuint program, GLenum shadertype, const GLchar* name)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glGetSubroutineIndex(program, shadertype, name);
+}
+
+GLint gl4_3compat_glGetSubroutineUniformLocation(void *_glfuncs, GLuint program, GLenum shadertype, const GLchar* name)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glGetSubroutineUniformLocation(program, shadertype, name);
+}
+
+void gl4_3compat_glGetUniformdv(void *_glfuncs, GLuint program, GLint location, GLdouble* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetUniformdv(program, location, params);
+}
+
+void gl4_3compat_glUniformMatrix4x3dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4x3dv(location, count, transpose, value);
+}
+
+void gl4_3compat_glUniformMatrix4x2dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4x2dv(location, count, transpose, value);
+}
+
+void gl4_3compat_glUniformMatrix3x4dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3x4dv(location, count, transpose, value);
+}
+
+void gl4_3compat_glUniformMatrix3x2dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3x2dv(location, count, transpose, value);
+}
+
+void gl4_3compat_glUniformMatrix2x4dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2x4dv(location, count, transpose, value);
+}
+
+void gl4_3compat_glUniformMatrix2x3dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2x3dv(location, count, transpose, value);
+}
+
+void gl4_3compat_glUniformMatrix4dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4dv(location, count, transpose, value);
+}
+
+void gl4_3compat_glUniformMatrix3dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3dv(location, count, transpose, value);
+}
+
+void gl4_3compat_glUniformMatrix2dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2dv(location, count, transpose, value);
+}
+
+void gl4_3compat_glUniform4dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform4dv(location, count, value);
+}
+
+void gl4_3compat_glUniform3dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform3dv(location, count, value);
+}
+
+void gl4_3compat_glUniform2dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform2dv(location, count, value);
+}
+
+void gl4_3compat_glUniform1dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform1dv(location, count, value);
+}
+
+void gl4_3compat_glUniform4d(void *_glfuncs, GLint location, GLdouble v0, GLdouble v1, GLdouble v2, GLdouble v3)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform4d(location, v0, v1, v2, v3);
+}
+
+void gl4_3compat_glUniform3d(void *_glfuncs, GLint location, GLdouble v0, GLdouble v1, GLdouble v2)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform3d(location, v0, v1, v2);
+}
+
+void gl4_3compat_glUniform2d(void *_glfuncs, GLint location, GLdouble v0, GLdouble v1)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform2d(location, v0, v1);
+}
+
+void gl4_3compat_glUniform1d(void *_glfuncs, GLint location, GLdouble v0)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUniform1d(location, v0);
+}
+
+void gl4_3compat_glDrawElementsIndirect(void *_glfuncs, GLenum mode, GLenum gltype, const GLvoid* indirect)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawElementsIndirect(mode, gltype, indirect);
+}
+
+void gl4_3compat_glDrawArraysIndirect(void *_glfuncs, GLenum mode, const GLvoid* indirect)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawArraysIndirect(mode, indirect);
+}
+
+void gl4_3compat_glBlendFuncSeparatei(void *_glfuncs, GLuint buf, GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha, GLenum dstAlpha)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glBlendFuncSeparatei(buf, srcRGB, dstRGB, srcAlpha, dstAlpha);
+}
+
+void gl4_3compat_glBlendFunci(void *_glfuncs, GLuint buf, GLenum src, GLenum dst)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glBlendFunci(buf, src, dst);
+}
+
+void gl4_3compat_glBlendEquationSeparatei(void *_glfuncs, GLuint buf, GLenum modeRGB, GLenum modeAlpha)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glBlendEquationSeparatei(buf, modeRGB, modeAlpha);
+}
+
+void gl4_3compat_glBlendEquationi(void *_glfuncs, GLuint buf, GLenum mode)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glBlendEquationi(buf, mode);
+}
+
+void gl4_3compat_glMinSampleShading(void *_glfuncs, GLfloat value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMinSampleShading(value);
+}
+
+void gl4_3compat_glGetDoublei_v(void *_glfuncs, GLenum target, GLuint index, GLdouble* data)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetDoublei_v(target, index, data);
+}
+
+void gl4_3compat_glGetFloati_v(void *_glfuncs, GLenum target, GLuint index, GLfloat* data)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetFloati_v(target, index, data);
+}
+
+void gl4_3compat_glDepthRangeIndexed(void *_glfuncs, GLuint index, GLdouble n, GLdouble f)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDepthRangeIndexed(index, n, f);
+}
+
+void gl4_3compat_glDepthRangeArrayv(void *_glfuncs, GLuint first, GLsizei count, const GLdouble* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDepthRangeArrayv(first, count, v);
+}
+
+void gl4_3compat_glScissorIndexedv(void *_glfuncs, GLuint index, const GLint* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glScissorIndexedv(index, v);
+}
+
+void gl4_3compat_glScissorIndexed(void *_glfuncs, GLuint index, GLint left, GLint bottom, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glScissorIndexed(index, left, bottom, width, height);
+}
+
+void gl4_3compat_glScissorArrayv(void *_glfuncs, GLuint first, GLsizei count, const GLint* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glScissorArrayv(first, count, v);
+}
+
+void gl4_3compat_glViewportIndexedfv(void *_glfuncs, GLuint index, const GLfloat* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glViewportIndexedfv(index, v);
+}
+
+void gl4_3compat_glViewportIndexedf(void *_glfuncs, GLuint index, GLfloat x, GLfloat y, GLfloat w, GLfloat h)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glViewportIndexedf(index, x, y, w, h);
+}
+
+void gl4_3compat_glViewportArrayv(void *_glfuncs, GLuint first, GLsizei count, const GLfloat* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glViewportArrayv(first, count, v);
+}
+
+void gl4_3compat_glGetVertexAttribLdv(void *_glfuncs, GLuint index, GLenum pname, GLdouble* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribLdv(index, pname, params);
+}
+
+void gl4_3compat_glVertexAttribLPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribLPointer(index, size, gltype, stride, pointer);
+}
+
+void gl4_3compat_glVertexAttribL4dv(void *_glfuncs, GLuint index, const GLdouble* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribL4dv(index, v);
+}
+
+void gl4_3compat_glVertexAttribL3dv(void *_glfuncs, GLuint index, const GLdouble* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribL3dv(index, v);
+}
+
+void gl4_3compat_glVertexAttribL2dv(void *_glfuncs, GLuint index, const GLdouble* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribL2dv(index, v);
+}
+
+void gl4_3compat_glVertexAttribL1dv(void *_glfuncs, GLuint index, const GLdouble* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribL1dv(index, v);
+}
+
+void gl4_3compat_glVertexAttribL4d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribL4d(index, x, y, z, w);
+}
+
+void gl4_3compat_glVertexAttribL3d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribL3d(index, x, y, z);
+}
+
+void gl4_3compat_glVertexAttribL2d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribL2d(index, x, y);
+}
+
+void gl4_3compat_glVertexAttribL1d(void *_glfuncs, GLuint index, GLdouble x)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribL1d(index, x);
+}
+
+void gl4_3compat_glGetProgramPipelineInfoLog(void *_glfuncs, GLuint pipeline, GLsizei bufSize, GLsizei* length, GLchar* infoLog)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetProgramPipelineInfoLog(pipeline, bufSize, length, infoLog);
+}
+
+void gl4_3compat_glValidateProgramPipeline(void *_glfuncs, GLuint pipeline)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glValidateProgramPipeline(pipeline);
+}
+
+void gl4_3compat_glProgramUniformMatrix4x3dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix4x3dv(program, location, count, transpose, value);
+}
+
+void gl4_3compat_glProgramUniformMatrix3x4dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix3x4dv(program, location, count, transpose, value);
+}
+
+void gl4_3compat_glProgramUniformMatrix4x2dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix4x2dv(program, location, count, transpose, value);
+}
+
+void gl4_3compat_glProgramUniformMatrix2x4dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix2x4dv(program, location, count, transpose, value);
+}
+
+void gl4_3compat_glProgramUniformMatrix3x2dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix3x2dv(program, location, count, transpose, value);
+}
+
+void gl4_3compat_glProgramUniformMatrix2x3dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix2x3dv(program, location, count, transpose, value);
+}
+
+void gl4_3compat_glProgramUniformMatrix4x3fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix4x3fv(program, location, count, transpose, value);
+}
+
+void gl4_3compat_glProgramUniformMatrix3x4fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix3x4fv(program, location, count, transpose, value);
+}
+
+void gl4_3compat_glProgramUniformMatrix4x2fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix4x2fv(program, location, count, transpose, value);
+}
+
+void gl4_3compat_glProgramUniformMatrix2x4fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix2x4fv(program, location, count, transpose, value);
+}
+
+void gl4_3compat_glProgramUniformMatrix3x2fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix3x2fv(program, location, count, transpose, value);
+}
+
+void gl4_3compat_glProgramUniformMatrix2x3fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix2x3fv(program, location, count, transpose, value);
+}
+
+void gl4_3compat_glProgramUniformMatrix4dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix4dv(program, location, count, transpose, value);
+}
+
+void gl4_3compat_glProgramUniformMatrix3dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix3dv(program, location, count, transpose, value);
+}
+
+void gl4_3compat_glProgramUniformMatrix2dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix2dv(program, location, count, transpose, value);
+}
+
+void gl4_3compat_glProgramUniformMatrix4fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix4fv(program, location, count, transpose, value);
+}
+
+void gl4_3compat_glProgramUniformMatrix3fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix3fv(program, location, count, transpose, value);
+}
+
+void gl4_3compat_glProgramUniformMatrix2fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix2fv(program, location, count, transpose, value);
+}
+
+void gl4_3compat_glProgramUniform4uiv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform4uiv(program, location, count, value);
+}
+
+void gl4_3compat_glProgramUniform4ui(void *_glfuncs, GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform4ui(program, location, v0, v1, v2, v3);
+}
+
+void gl4_3compat_glProgramUniform4dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLdouble* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform4dv(program, location, count, value);
+}
+
+void gl4_3compat_glProgramUniform4d(void *_glfuncs, GLuint program, GLint location, GLdouble v0, GLdouble v1, GLdouble v2, GLdouble v3)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform4d(program, location, v0, v1, v2, v3);
+}
+
+void gl4_3compat_glProgramUniform4fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform4fv(program, location, count, value);
+}
+
+void gl4_3compat_glProgramUniform4f(void *_glfuncs, GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform4f(program, location, v0, v1, v2, v3);
+}
+
+void gl4_3compat_glProgramUniform4iv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform4iv(program, location, count, value);
+}
+
+void gl4_3compat_glProgramUniform4i(void *_glfuncs, GLuint program, GLint location, GLint v0, GLint v1, GLint v2, GLint v3)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform4i(program, location, v0, v1, v2, v3);
+}
+
+void gl4_3compat_glProgramUniform3uiv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform3uiv(program, location, count, value);
+}
+
+void gl4_3compat_glProgramUniform3ui(void *_glfuncs, GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform3ui(program, location, v0, v1, v2);
+}
+
+void gl4_3compat_glProgramUniform3dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLdouble* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform3dv(program, location, count, value);
+}
+
+void gl4_3compat_glProgramUniform3d(void *_glfuncs, GLuint program, GLint location, GLdouble v0, GLdouble v1, GLdouble v2)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform3d(program, location, v0, v1, v2);
+}
+
+void gl4_3compat_glProgramUniform3fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform3fv(program, location, count, value);
+}
+
+void gl4_3compat_glProgramUniform3f(void *_glfuncs, GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform3f(program, location, v0, v1, v2);
+}
+
+void gl4_3compat_glProgramUniform3iv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform3iv(program, location, count, value);
+}
+
+void gl4_3compat_glProgramUniform3i(void *_glfuncs, GLuint program, GLint location, GLint v0, GLint v1, GLint v2)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform3i(program, location, v0, v1, v2);
+}
+
+void gl4_3compat_glProgramUniform2uiv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform2uiv(program, location, count, value);
+}
+
+void gl4_3compat_glProgramUniform2ui(void *_glfuncs, GLuint program, GLint location, GLuint v0, GLuint v1)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform2ui(program, location, v0, v1);
+}
+
+void gl4_3compat_glProgramUniform2dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLdouble* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform2dv(program, location, count, value);
+}
+
+void gl4_3compat_glProgramUniform2d(void *_glfuncs, GLuint program, GLint location, GLdouble v0, GLdouble v1)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform2d(program, location, v0, v1);
+}
+
+void gl4_3compat_glProgramUniform2fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform2fv(program, location, count, value);
+}
+
+void gl4_3compat_glProgramUniform2f(void *_glfuncs, GLuint program, GLint location, GLfloat v0, GLfloat v1)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform2f(program, location, v0, v1);
+}
+
+void gl4_3compat_glProgramUniform2iv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform2iv(program, location, count, value);
+}
+
+void gl4_3compat_glProgramUniform2i(void *_glfuncs, GLuint program, GLint location, GLint v0, GLint v1)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform2i(program, location, v0, v1);
+}
+
+void gl4_3compat_glProgramUniform1uiv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform1uiv(program, location, count, value);
+}
+
+void gl4_3compat_glProgramUniform1ui(void *_glfuncs, GLuint program, GLint location, GLuint v0)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform1ui(program, location, v0);
+}
+
+void gl4_3compat_glProgramUniform1dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLdouble* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform1dv(program, location, count, value);
+}
+
+void gl4_3compat_glProgramUniform1d(void *_glfuncs, GLuint program, GLint location, GLdouble v0)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform1d(program, location, v0);
+}
+
+void gl4_3compat_glProgramUniform1fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform1fv(program, location, count, value);
+}
+
+void gl4_3compat_glProgramUniform1f(void *_glfuncs, GLuint program, GLint location, GLfloat v0)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform1f(program, location, v0);
+}
+
+void gl4_3compat_glProgramUniform1iv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform1iv(program, location, count, value);
+}
+
+void gl4_3compat_glProgramUniform1i(void *_glfuncs, GLuint program, GLint location, GLint v0)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramUniform1i(program, location, v0);
+}
+
+void gl4_3compat_glGetProgramPipelineiv(void *_glfuncs, GLuint pipeline, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetProgramPipelineiv(pipeline, pname, params);
+}
+
+GLboolean gl4_3compat_glIsProgramPipeline(void *_glfuncs, GLuint pipeline)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsProgramPipeline(pipeline);
+}
+
+void gl4_3compat_glGenProgramPipelines(void *_glfuncs, GLsizei n, GLuint* pipelines)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGenProgramPipelines(n, pipelines);
+}
+
+void gl4_3compat_glDeleteProgramPipelines(void *_glfuncs, GLsizei n, const GLuint* pipelines)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteProgramPipelines(n, pipelines);
+}
+
+void gl4_3compat_glBindProgramPipeline(void *_glfuncs, GLuint pipeline)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindProgramPipeline(pipeline);
+}
+
+void gl4_3compat_glActiveShaderProgram(void *_glfuncs, GLuint pipeline, GLuint program)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glActiveShaderProgram(pipeline, program);
+}
+
+void gl4_3compat_glUseProgramStages(void *_glfuncs, GLuint pipeline, GLbitfield stages, GLuint program)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glUseProgramStages(pipeline, stages, program);
+}
+
+void gl4_3compat_glProgramParameteri(void *_glfuncs, GLuint program, GLenum pname, GLint value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramParameteri(program, pname, value);
+}
+
+void gl4_3compat_glProgramBinary(void *_glfuncs, GLuint program, GLenum binaryFormat, const GLvoid* binary, GLsizei length)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glProgramBinary(program, binaryFormat, binary, length);
+}
+
+void gl4_3compat_glGetProgramBinary(void *_glfuncs, GLuint program, GLsizei bufSize, GLsizei* length, GLenum* binaryFormat, GLvoid* binary)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetProgramBinary(program, bufSize, length, binaryFormat, binary);
+}
+
+void gl4_3compat_glClearDepthf(void *_glfuncs, GLfloat dd)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glClearDepthf(dd);
+}
+
+void gl4_3compat_glDepthRangef(void *_glfuncs, GLfloat n, GLfloat f)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDepthRangef(n, f);
+}
+
+void gl4_3compat_glGetShaderPrecisionFormat(void *_glfuncs, GLenum shadertype, GLenum precisionType, GLint* range_, GLint* precision)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetShaderPrecisionFormat(shadertype, precisionType, range_, precision);
+}
+
+void gl4_3compat_glShaderBinary(void *_glfuncs, GLsizei count, const GLuint* shaders, GLenum binaryFormat, const GLvoid* binary, GLsizei length)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glShaderBinary(count, shaders, binaryFormat, binary, length);
+}
+
+void gl4_3compat_glReleaseShaderCompiler(void *_glfuncs)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glReleaseShaderCompiler();
+}
+
+void gl4_3compat_glTexStorage3D(void *_glfuncs, GLenum target, GLsizei levels, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexStorage3D(target, levels, internalFormat, width, height, depth);
+}
+
+void gl4_3compat_glTexStorage2D(void *_glfuncs, GLenum target, GLsizei levels, GLenum internalFormat, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexStorage2D(target, levels, internalFormat, width, height);
+}
+
+void gl4_3compat_glTexStorage1D(void *_glfuncs, GLenum target, GLsizei levels, GLenum internalFormat, GLsizei width)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexStorage1D(target, levels, internalFormat, width);
+}
+
+void gl4_3compat_glMemoryBarrier(void *_glfuncs, GLbitfield barriers)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMemoryBarrier(barriers);
+}
+
+void gl4_3compat_glBindImageTexture(void *_glfuncs, GLuint unit, GLuint texture, GLint level, GLboolean layered, GLint layer, GLenum access, GLenum format)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindImageTexture(unit, texture, level, layered, layer, access, format);
+}
+
+void gl4_3compat_glGetActiveAtomicCounterBufferiv(void *_glfuncs, GLuint program, GLuint bufferIndex, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetActiveAtomicCounterBufferiv(program, bufferIndex, pname, params);
+}
+
+void gl4_3compat_glGetInternalformativ(void *_glfuncs, GLenum target, GLenum internalFormat, GLenum pname, GLsizei bufSize, GLint* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetInternalformativ(target, internalFormat, pname, bufSize, params);
+}
+
+void gl4_3compat_glDrawTransformFeedbackStreamInstanced(void *_glfuncs, GLenum mode, GLuint id, GLuint stream, GLsizei instancecount)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawTransformFeedbackStreamInstanced(mode, id, stream, instancecount);
+}
+
+void gl4_3compat_glDrawTransformFeedbackInstanced(void *_glfuncs, GLenum mode, GLuint id, GLsizei instancecount)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawTransformFeedbackInstanced(mode, id, instancecount);
+}
+
+void gl4_3compat_glDrawElementsInstancedBaseVertexBaseInstance(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount, GLint basevertex, GLuint baseinstance)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawElementsInstancedBaseVertexBaseInstance(mode, count, gltype, indices, instancecount, basevertex, baseinstance);
+}
+
+void gl4_3compat_glDrawElementsInstancedBaseInstance(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount, GLuint baseinstance)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawElementsInstancedBaseInstance(mode, count, gltype, indices, instancecount, baseinstance);
+}
+
+void gl4_3compat_glDrawArraysInstancedBaseInstance(void *_glfuncs, GLenum mode, GLint first, GLsizei count, GLsizei instancecount, GLuint baseinstance)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawArraysInstancedBaseInstance(mode, first, count, instancecount, baseinstance);
+}
+
+void gl4_3compat_glTexStorage3DMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexStorage3DMultisample(target, samples, internalFormat, width, height, depth, fixedsamplelocations);
+}
+
+void gl4_3compat_glTexStorage2DMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLenum internalFormat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexStorage2DMultisample(target, samples, internalFormat, width, height, fixedsamplelocations);
+}
+
+void gl4_3compat_glTexBufferRange(void *_glfuncs, GLenum target, GLenum internalFormat, GLuint buffer, GLintptr offset, GLsizeiptr size)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexBufferRange(target, internalFormat, buffer, offset, size);
+}
+
+void gl4_3compat_glShaderStorageBlockBinding(void *_glfuncs, GLuint program, GLuint storageBlockIndex, GLuint storageBlockBinding)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glShaderStorageBlockBinding(program, storageBlockIndex, storageBlockBinding);
+}
+
+GLint gl4_3compat_glGetProgramResourceLocationIndex(void *_glfuncs, GLuint program, GLenum programInterface, const GLchar* name)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glGetProgramResourceLocationIndex(program, programInterface, name);
+}
+
+GLint gl4_3compat_glGetProgramResourceLocation(void *_glfuncs, GLuint program, GLenum programInterface, const GLchar* name)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glGetProgramResourceLocation(program, programInterface, name);
+}
+
+void gl4_3compat_glGetProgramResourceiv(void *_glfuncs, GLuint program, GLenum programInterface, GLuint index, GLsizei propCount, const GLenum* props, GLsizei bufSize, GLsizei* length, GLint* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetProgramResourceiv(program, programInterface, index, propCount, props, bufSize, length, params);
+}
+
+void gl4_3compat_glGetProgramResourceName(void *_glfuncs, GLuint program, GLenum programInterface, GLuint index, GLsizei bufSize, GLsizei* length, GLchar* name)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetProgramResourceName(program, programInterface, index, bufSize, length, name);
+}
+
+GLuint gl4_3compat_glGetProgramResourceIndex(void *_glfuncs, GLuint program, GLenum programInterface, const GLchar* name)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glGetProgramResourceIndex(program, programInterface, name);
+}
+
+void gl4_3compat_glGetProgramInterfaceiv(void *_glfuncs, GLuint program, GLenum programInterface, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetProgramInterfaceiv(program, programInterface, pname, params);
+}
+
+void gl4_3compat_glMultiDrawElementsIndirect(void *_glfuncs, GLenum mode, GLenum gltype, const GLvoid* indirect, GLsizei drawcount, GLsizei stride)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiDrawElementsIndirect(mode, gltype, indirect, drawcount, stride);
+}
+
+void gl4_3compat_glMultiDrawArraysIndirect(void *_glfuncs, GLenum mode, const GLvoid* indirect, GLsizei drawcount, GLsizei stride)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiDrawArraysIndirect(mode, indirect, drawcount, stride);
+}
+
+void gl4_3compat_glInvalidateSubFramebuffer(void *_glfuncs, GLenum target, GLsizei numAttachments, const GLenum* attachments, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glInvalidateSubFramebuffer(target, numAttachments, attachments, x, y, width, height);
+}
+
+void gl4_3compat_glInvalidateFramebuffer(void *_glfuncs, GLenum target, GLsizei numAttachments, const GLenum* attachments)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glInvalidateFramebuffer(target, numAttachments, attachments);
+}
+
+void gl4_3compat_glInvalidateBufferData(void *_glfuncs, GLuint buffer)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glInvalidateBufferData(buffer);
+}
+
+void gl4_3compat_glInvalidateBufferSubData(void *_glfuncs, GLuint buffer, GLintptr offset, GLsizeiptr length)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glInvalidateBufferSubData(buffer, offset, length);
+}
+
+void gl4_3compat_glInvalidateTexImage(void *_glfuncs, GLuint texture, GLint level)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glInvalidateTexImage(texture, level);
+}
+
+void gl4_3compat_glInvalidateTexSubImage(void *_glfuncs, GLuint texture, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glInvalidateTexSubImage(texture, level, xoffset, yoffset, zoffset, width, height, depth);
+}
+
+void gl4_3compat_glGetInternalformati64v(void *_glfuncs, GLenum target, GLenum internalFormat, GLenum pname, GLsizei bufSize, GLint64* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetInternalformati64v(target, internalFormat, pname, bufSize, params);
+}
+
+void gl4_3compat_glGetFramebufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetFramebufferParameteriv(target, pname, params);
+}
+
+void gl4_3compat_glFramebufferParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glFramebufferParameteri(target, pname, param);
+}
+
+void gl4_3compat_glVertexBindingDivisor(void *_glfuncs, GLuint bindingindex, GLuint divisor)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexBindingDivisor(bindingindex, divisor);
+}
+
+void gl4_3compat_glVertexAttribBinding(void *_glfuncs, GLuint attribindex, GLuint bindingindex)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribBinding(attribindex, bindingindex);
+}
+
+void gl4_3compat_glVertexAttribLFormat(void *_glfuncs, GLuint attribindex, GLint size, GLenum gltype, GLuint relativeoffset)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribLFormat(attribindex, size, gltype, relativeoffset);
+}
+
+void gl4_3compat_glVertexAttribIFormat(void *_glfuncs, GLuint attribindex, GLint size, GLenum gltype, GLuint relativeoffset)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribIFormat(attribindex, size, gltype, relativeoffset);
+}
+
+void gl4_3compat_glVertexAttribFormat(void *_glfuncs, GLuint attribindex, GLint size, GLenum gltype, GLboolean normalized, GLuint relativeoffset)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribFormat(attribindex, size, gltype, normalized, relativeoffset);
+}
+
+void gl4_3compat_glBindVertexBuffer(void *_glfuncs, GLuint bindingindex, GLuint buffer, GLintptr offset, GLsizei stride)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glBindVertexBuffer(bindingindex, buffer, offset, stride);
+}
+
+void gl4_3compat_glTextureView(void *_glfuncs, GLuint texture, GLenum target, GLuint origtexture, GLenum internalFormat, GLuint minlevel, GLuint numlevels, GLuint minlayer, GLuint numlayers)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTextureView(texture, target, origtexture, internalFormat, minlevel, numlevels, minlayer, numlayers);
+}
+
+void gl4_3compat_glCopyImageSubData(void *_glfuncs, GLuint srcName, GLenum srcTarget, GLint srcLevel, GLint srcX, GLint srcY, GLint srcZ, GLuint dstName, GLenum dstTarget, GLint dstLevel, GLint dstX, GLint dstY, GLint dstZ, GLsizei srcWidth, GLsizei srcHeight, GLsizei srcDepth)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyImageSubData(srcName, srcTarget, srcLevel, srcX, srcY, srcZ, dstName, dstTarget, dstLevel, dstX, dstY, dstZ, srcWidth, srcHeight, srcDepth);
+}
+
+void gl4_3compat_glDispatchComputeIndirect(void *_glfuncs, GLintptr indirect)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDispatchComputeIndirect(indirect);
+}
+
+void gl4_3compat_glDispatchCompute(void *_glfuncs, GLuint num_groups_x, GLuint num_groups_y, GLuint num_groups_z)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDispatchCompute(num_groups_x, num_groups_y, num_groups_z);
+}
+
+void gl4_3compat_glClearBufferSubData(void *_glfuncs, GLenum target, GLenum internalFormat, GLintptr offset, GLsizeiptr size, GLenum format, GLenum gltype, const GLvoid* data)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glClearBufferSubData(target, internalFormat, offset, size, format, gltype, data);
+}
+
+void gl4_3compat_glClearBufferData(void *_glfuncs, GLenum target, GLenum internalFormat, GLenum format, GLenum gltype, const GLvoid* data)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glClearBufferData(target, internalFormat, format, gltype, data);
+}
+
+void gl4_3compat_glTranslatef(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTranslatef(x, y, z);
+}
+
+void gl4_3compat_glTranslated(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTranslated(x, y, z);
+}
+
+void gl4_3compat_glScalef(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glScalef(x, y, z);
+}
+
+void gl4_3compat_glScaled(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glScaled(x, y, z);
+}
+
+void gl4_3compat_glRotatef(void *_glfuncs, GLfloat angle, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRotatef(angle, x, y, z);
+}
+
+void gl4_3compat_glRotated(void *_glfuncs, GLdouble angle, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRotated(angle, x, y, z);
+}
+
+void gl4_3compat_glPushMatrix(void *_glfuncs)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glPushMatrix();
+}
+
+void gl4_3compat_glPopMatrix(void *_glfuncs)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glPopMatrix();
+}
+
+void gl4_3compat_glOrtho(void *_glfuncs, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glOrtho(left, right, bottom, top, zNear, zFar);
+}
+
+void gl4_3compat_glMultMatrixd(void *_glfuncs, const GLdouble* m)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultMatrixd(m);
+}
+
+void gl4_3compat_glMultMatrixf(void *_glfuncs, const GLfloat* m)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultMatrixf(m);
+}
+
+void gl4_3compat_glMatrixMode(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMatrixMode(mode);
+}
+
+void gl4_3compat_glLoadMatrixd(void *_glfuncs, const GLdouble* m)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glLoadMatrixd(m);
+}
+
+void gl4_3compat_glLoadMatrixf(void *_glfuncs, const GLfloat* m)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glLoadMatrixf(m);
+}
+
+void gl4_3compat_glLoadIdentity(void *_glfuncs)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glLoadIdentity();
+}
+
+void gl4_3compat_glFrustum(void *_glfuncs, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glFrustum(left, right, bottom, top, zNear, zFar);
+}
+
+GLboolean gl4_3compat_glIsList(void *_glfuncs, GLuint list)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glIsList(list);
+}
+
+void gl4_3compat_glGetTexGeniv(void *_glfuncs, GLenum coord, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexGeniv(coord, pname, params);
+}
+
+void gl4_3compat_glGetTexGenfv(void *_glfuncs, GLenum coord, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexGenfv(coord, pname, params);
+}
+
+void gl4_3compat_glGetTexGendv(void *_glfuncs, GLenum coord, GLenum pname, GLdouble* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexGendv(coord, pname, params);
+}
+
+void gl4_3compat_glGetTexEnviv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexEnviv(target, pname, params);
+}
+
+void gl4_3compat_glGetTexEnvfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetTexEnvfv(target, pname, params);
+}
+
+void gl4_3compat_glGetPolygonStipple(void *_glfuncs, GLubyte* mask)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetPolygonStipple(mask);
+}
+
+void gl4_3compat_glGetPixelMapusv(void *_glfuncs, GLenum glmap, GLushort* values)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetPixelMapusv(glmap, values);
+}
+
+void gl4_3compat_glGetPixelMapuiv(void *_glfuncs, GLenum glmap, GLuint* values)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetPixelMapuiv(glmap, values);
+}
+
+void gl4_3compat_glGetPixelMapfv(void *_glfuncs, GLenum glmap, GLfloat* values)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetPixelMapfv(glmap, values);
+}
+
+void gl4_3compat_glGetMaterialiv(void *_glfuncs, GLenum face, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetMaterialiv(face, pname, params);
+}
+
+void gl4_3compat_glGetMaterialfv(void *_glfuncs, GLenum face, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetMaterialfv(face, pname, params);
+}
+
+void gl4_3compat_glGetMapiv(void *_glfuncs, GLenum target, GLenum query, GLint* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetMapiv(target, query, v);
+}
+
+void gl4_3compat_glGetMapfv(void *_glfuncs, GLenum target, GLenum query, GLfloat* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetMapfv(target, query, v);
+}
+
+void gl4_3compat_glGetMapdv(void *_glfuncs, GLenum target, GLenum query, GLdouble* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetMapdv(target, query, v);
+}
+
+void gl4_3compat_glGetLightiv(void *_glfuncs, GLenum light, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetLightiv(light, pname, params);
+}
+
+void gl4_3compat_glGetLightfv(void *_glfuncs, GLenum light, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetLightfv(light, pname, params);
+}
+
+void gl4_3compat_glGetClipPlane(void *_glfuncs, GLenum plane, GLdouble* equation)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetClipPlane(plane, equation);
+}
+
+void gl4_3compat_glDrawPixels(void *_glfuncs, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDrawPixels(width, height, format, gltype, pixels);
+}
+
+void gl4_3compat_glCopyPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum gltype)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyPixels(x, y, width, height, gltype);
+}
+
+void gl4_3compat_glPixelMapusv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLushort* values)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glPixelMapusv(glmap, mapsize, values);
+}
+
+void gl4_3compat_glPixelMapuiv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLuint* values)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glPixelMapuiv(glmap, mapsize, values);
+}
+
+void gl4_3compat_glPixelMapfv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLfloat* values)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glPixelMapfv(glmap, mapsize, values);
+}
+
+void gl4_3compat_glPixelTransferi(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glPixelTransferi(pname, param);
+}
+
+void gl4_3compat_glPixelTransferf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glPixelTransferf(pname, param);
+}
+
+void gl4_3compat_glPixelZoom(void *_glfuncs, GLfloat xfactor, GLfloat yfactor)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glPixelZoom(xfactor, yfactor);
+}
+
+void gl4_3compat_glAlphaFunc(void *_glfuncs, GLenum glfunc, GLfloat ref)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glAlphaFunc(glfunc, ref);
+}
+
+void gl4_3compat_glEvalPoint2(void *_glfuncs, GLint i, GLint j)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalPoint2(i, j);
+}
+
+void gl4_3compat_glEvalMesh2(void *_glfuncs, GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalMesh2(mode, i1, i2, j1, j2);
+}
+
+void gl4_3compat_glEvalPoint1(void *_glfuncs, GLint i)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalPoint1(i);
+}
+
+void gl4_3compat_glEvalMesh1(void *_glfuncs, GLenum mode, GLint i1, GLint i2)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalMesh1(mode, i1, i2);
+}
+
+void gl4_3compat_glEvalCoord2fv(void *_glfuncs, const GLfloat* u)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalCoord2fv(u);
+}
+
+void gl4_3compat_glEvalCoord2f(void *_glfuncs, GLfloat u, GLfloat v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalCoord2f(u, v);
+}
+
+void gl4_3compat_glEvalCoord2dv(void *_glfuncs, const GLdouble* u)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalCoord2dv(u);
+}
+
+void gl4_3compat_glEvalCoord2d(void *_glfuncs, GLdouble u, GLdouble v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalCoord2d(u, v);
+}
+
+void gl4_3compat_glEvalCoord1fv(void *_glfuncs, const GLfloat* u)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalCoord1fv(u);
+}
+
+void gl4_3compat_glEvalCoord1f(void *_glfuncs, GLfloat u)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalCoord1f(u);
+}
+
+void gl4_3compat_glEvalCoord1dv(void *_glfuncs, const GLdouble* u)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalCoord1dv(u);
+}
+
+void gl4_3compat_glEvalCoord1d(void *_glfuncs, GLdouble u)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glEvalCoord1d(u);
+}
+
+void gl4_3compat_glMapGrid2f(void *_glfuncs, GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMapGrid2f(un, u1, u2, vn, v1, v2);
+}
+
+void gl4_3compat_glMapGrid2d(void *_glfuncs, GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMapGrid2d(un, u1, u2, vn, v1, v2);
+}
+
+void gl4_3compat_glMapGrid1f(void *_glfuncs, GLint un, GLfloat u1, GLfloat u2)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMapGrid1f(un, u1, u2);
+}
+
+void gl4_3compat_glMapGrid1d(void *_glfuncs, GLint un, GLdouble u1, GLdouble u2)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMapGrid1d(un, u1, u2);
+}
+
+void gl4_3compat_glMap2f(void *_glfuncs, GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat* points)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMap2f(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+void gl4_3compat_glMap2d(void *_glfuncs, GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble* points)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMap2d(target, u1, u2, ustride, uorder, v1, v2, vstride, vorder, points);
+}
+
+void gl4_3compat_glMap1f(void *_glfuncs, GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat* points)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMap1f(target, u1, u2, stride, order, points);
+}
+
+void gl4_3compat_glMap1d(void *_glfuncs, GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble* points)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMap1d(target, u1, u2, stride, order, points);
+}
+
+void gl4_3compat_glPushAttrib(void *_glfuncs, GLbitfield mask)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glPushAttrib(mask);
+}
+
+void gl4_3compat_glPopAttrib(void *_glfuncs)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glPopAttrib();
+}
+
+void gl4_3compat_glAccum(void *_glfuncs, GLenum op, GLfloat value)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glAccum(op, value);
+}
+
+void gl4_3compat_glIndexMask(void *_glfuncs, GLuint mask)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexMask(mask);
+}
+
+void gl4_3compat_glClearIndex(void *_glfuncs, GLfloat c)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glClearIndex(c);
+}
+
+void gl4_3compat_glClearAccum(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glClearAccum(red, green, blue, alpha);
+}
+
+void gl4_3compat_glPushName(void *_glfuncs, GLuint name)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glPushName(name);
+}
+
+void gl4_3compat_glPopName(void *_glfuncs)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glPopName();
+}
+
+void gl4_3compat_glPassThrough(void *_glfuncs, GLfloat token)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glPassThrough(token);
+}
+
+void gl4_3compat_glLoadName(void *_glfuncs, GLuint name)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glLoadName(name);
+}
+
+void gl4_3compat_glInitNames(void *_glfuncs)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glInitNames();
+}
+
+GLint gl4_3compat_glRenderMode(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glRenderMode(mode);
+}
+
+void gl4_3compat_glSelectBuffer(void *_glfuncs, GLsizei size, GLuint* buffer)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glSelectBuffer(size, buffer);
+}
+
+void gl4_3compat_glFeedbackBuffer(void *_glfuncs, GLsizei size, GLenum gltype, GLfloat* buffer)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glFeedbackBuffer(size, gltype, buffer);
+}
+
+void gl4_3compat_glTexGeniv(void *_glfuncs, GLenum coord, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexGeniv(coord, pname, params);
+}
+
+void gl4_3compat_glTexGeni(void *_glfuncs, GLenum coord, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexGeni(coord, pname, param);
+}
+
+void gl4_3compat_glTexGenfv(void *_glfuncs, GLenum coord, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexGenfv(coord, pname, params);
+}
+
+void gl4_3compat_glTexGenf(void *_glfuncs, GLenum coord, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexGenf(coord, pname, param);
+}
+
+void gl4_3compat_glTexGendv(void *_glfuncs, GLenum coord, GLenum pname, const GLdouble* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexGendv(coord, pname, params);
+}
+
+void gl4_3compat_glTexGend(void *_glfuncs, GLenum coord, GLenum pname, GLdouble param)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexGend(coord, pname, param);
+}
+
+void gl4_3compat_glTexEnviv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexEnviv(target, pname, params);
+}
+
+void gl4_3compat_glTexEnvi(void *_glfuncs, GLenum target, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexEnvi(target, pname, param);
+}
+
+void gl4_3compat_glTexEnvfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexEnvfv(target, pname, params);
+}
+
+void gl4_3compat_glTexEnvf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexEnvf(target, pname, param);
+}
+
+void gl4_3compat_glShadeModel(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glShadeModel(mode);
+}
+
+void gl4_3compat_glPolygonStipple(void *_glfuncs, const GLubyte* mask)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glPolygonStipple(mask);
+}
+
+void gl4_3compat_glMaterialiv(void *_glfuncs, GLenum face, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMaterialiv(face, pname, params);
+}
+
+void gl4_3compat_glMateriali(void *_glfuncs, GLenum face, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMateriali(face, pname, param);
+}
+
+void gl4_3compat_glMaterialfv(void *_glfuncs, GLenum face, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMaterialfv(face, pname, params);
+}
+
+void gl4_3compat_glMaterialf(void *_glfuncs, GLenum face, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMaterialf(face, pname, param);
+}
+
+void gl4_3compat_glLineStipple(void *_glfuncs, GLint factor, GLushort pattern)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glLineStipple(factor, pattern);
+}
+
+void gl4_3compat_glLightModeliv(void *_glfuncs, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glLightModeliv(pname, params);
+}
+
+void gl4_3compat_glLightModeli(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glLightModeli(pname, param);
+}
+
+void gl4_3compat_glLightModelfv(void *_glfuncs, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glLightModelfv(pname, params);
+}
+
+void gl4_3compat_glLightModelf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glLightModelf(pname, param);
+}
+
+void gl4_3compat_glLightiv(void *_glfuncs, GLenum light, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glLightiv(light, pname, params);
+}
+
+void gl4_3compat_glLighti(void *_glfuncs, GLenum light, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glLighti(light, pname, param);
+}
+
+void gl4_3compat_glLightfv(void *_glfuncs, GLenum light, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glLightfv(light, pname, params);
+}
+
+void gl4_3compat_glLightf(void *_glfuncs, GLenum light, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glLightf(light, pname, param);
+}
+
+void gl4_3compat_glFogiv(void *_glfuncs, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glFogiv(pname, params);
+}
+
+void gl4_3compat_glFogi(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glFogi(pname, param);
+}
+
+void gl4_3compat_glFogfv(void *_glfuncs, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glFogfv(pname, params);
+}
+
+void gl4_3compat_glFogf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glFogf(pname, param);
+}
+
+void gl4_3compat_glColorMaterial(void *_glfuncs, GLenum face, GLenum mode)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorMaterial(face, mode);
+}
+
+void gl4_3compat_glClipPlane(void *_glfuncs, GLenum plane, const GLdouble* equation)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glClipPlane(plane, equation);
+}
+
+void gl4_3compat_glVertex4sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex4sv(v);
+}
+
+void gl4_3compat_glVertex4s(void *_glfuncs, GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex4s(x, y, z, w);
+}
+
+void gl4_3compat_glVertex4iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex4iv(v);
+}
+
+void gl4_3compat_glVertex4i(void *_glfuncs, GLint x, GLint y, GLint z, GLint w)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex4i(x, y, z, w);
+}
+
+void gl4_3compat_glVertex4fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex4fv(v);
+}
+
+void gl4_3compat_glVertex4f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex4f(x, y, z, w);
+}
+
+void gl4_3compat_glVertex4dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex4dv(v);
+}
+
+void gl4_3compat_glVertex4d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex4d(x, y, z, w);
+}
+
+void gl4_3compat_glVertex3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex3sv(v);
+}
+
+void gl4_3compat_glVertex3s(void *_glfuncs, GLshort x, GLshort y, GLshort z)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex3s(x, y, z);
+}
+
+void gl4_3compat_glVertex3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex3iv(v);
+}
+
+void gl4_3compat_glVertex3i(void *_glfuncs, GLint x, GLint y, GLint z)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex3i(x, y, z);
+}
+
+void gl4_3compat_glVertex3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex3fv(v);
+}
+
+void gl4_3compat_glVertex3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex3f(x, y, z);
+}
+
+void gl4_3compat_glVertex3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex3dv(v);
+}
+
+void gl4_3compat_glVertex3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex3d(x, y, z);
+}
+
+void gl4_3compat_glVertex2sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex2sv(v);
+}
+
+void gl4_3compat_glVertex2s(void *_glfuncs, GLshort x, GLshort y)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex2s(x, y);
+}
+
+void gl4_3compat_glVertex2iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex2iv(v);
+}
+
+void gl4_3compat_glVertex2i(void *_glfuncs, GLint x, GLint y)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex2i(x, y);
+}
+
+void gl4_3compat_glVertex2fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex2fv(v);
+}
+
+void gl4_3compat_glVertex2f(void *_glfuncs, GLfloat x, GLfloat y)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex2f(x, y);
+}
+
+void gl4_3compat_glVertex2dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex2dv(v);
+}
+
+void gl4_3compat_glVertex2d(void *_glfuncs, GLdouble x, GLdouble y)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertex2d(x, y);
+}
+
+void gl4_3compat_glTexCoord4sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord4sv(v);
+}
+
+void gl4_3compat_glTexCoord4s(void *_glfuncs, GLshort s, GLshort t, GLshort r, GLshort q)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord4s(s, t, r, q);
+}
+
+void gl4_3compat_glTexCoord4iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord4iv(v);
+}
+
+void gl4_3compat_glTexCoord4i(void *_glfuncs, GLint s, GLint t, GLint r, GLint q)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord4i(s, t, r, q);
+}
+
+void gl4_3compat_glTexCoord4fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord4fv(v);
+}
+
+void gl4_3compat_glTexCoord4f(void *_glfuncs, GLfloat s, GLfloat t, GLfloat r, GLfloat q)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord4f(s, t, r, q);
+}
+
+void gl4_3compat_glTexCoord4dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord4dv(v);
+}
+
+void gl4_3compat_glTexCoord4d(void *_glfuncs, GLdouble s, GLdouble t, GLdouble r, GLdouble q)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord4d(s, t, r, q);
+}
+
+void gl4_3compat_glTexCoord3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord3sv(v);
+}
+
+void gl4_3compat_glTexCoord3s(void *_glfuncs, GLshort s, GLshort t, GLshort r)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord3s(s, t, r);
+}
+
+void gl4_3compat_glTexCoord3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord3iv(v);
+}
+
+void gl4_3compat_glTexCoord3i(void *_glfuncs, GLint s, GLint t, GLint r)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord3i(s, t, r);
+}
+
+void gl4_3compat_glTexCoord3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord3fv(v);
+}
+
+void gl4_3compat_glTexCoord3f(void *_glfuncs, GLfloat s, GLfloat t, GLfloat r)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord3f(s, t, r);
+}
+
+void gl4_3compat_glTexCoord3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord3dv(v);
+}
+
+void gl4_3compat_glTexCoord3d(void *_glfuncs, GLdouble s, GLdouble t, GLdouble r)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord3d(s, t, r);
+}
+
+void gl4_3compat_glTexCoord2sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord2sv(v);
+}
+
+void gl4_3compat_glTexCoord2s(void *_glfuncs, GLshort s, GLshort t)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord2s(s, t);
+}
+
+void gl4_3compat_glTexCoord2iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord2iv(v);
+}
+
+void gl4_3compat_glTexCoord2i(void *_glfuncs, GLint s, GLint t)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord2i(s, t);
+}
+
+void gl4_3compat_glTexCoord2fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord2fv(v);
+}
+
+void gl4_3compat_glTexCoord2f(void *_glfuncs, GLfloat s, GLfloat t)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord2f(s, t);
+}
+
+void gl4_3compat_glTexCoord2dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord2dv(v);
+}
+
+void gl4_3compat_glTexCoord2d(void *_glfuncs, GLdouble s, GLdouble t)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord2d(s, t);
+}
+
+void gl4_3compat_glTexCoord1sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord1sv(v);
+}
+
+void gl4_3compat_glTexCoord1s(void *_glfuncs, GLshort s)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord1s(s);
+}
+
+void gl4_3compat_glTexCoord1iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord1iv(v);
+}
+
+void gl4_3compat_glTexCoord1i(void *_glfuncs, GLint s)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord1i(s);
+}
+
+void gl4_3compat_glTexCoord1fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord1fv(v);
+}
+
+void gl4_3compat_glTexCoord1f(void *_glfuncs, GLfloat s)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord1f(s);
+}
+
+void gl4_3compat_glTexCoord1dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord1dv(v);
+}
+
+void gl4_3compat_glTexCoord1d(void *_glfuncs, GLdouble s)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoord1d(s);
+}
+
+void gl4_3compat_glRectsv(void *_glfuncs, const GLshort* v1, const GLshort* v2)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRectsv(v1, v2);
+}
+
+void gl4_3compat_glRects(void *_glfuncs, GLshort x1, GLshort y1, GLshort x2, GLshort y2)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRects(x1, y1, x2, y2);
+}
+
+void gl4_3compat_glRectiv(void *_glfuncs, const GLint* v1, const GLint* v2)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRectiv(v1, v2);
+}
+
+void gl4_3compat_glRecti(void *_glfuncs, GLint x1, GLint y1, GLint x2, GLint y2)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRecti(x1, y1, x2, y2);
+}
+
+void gl4_3compat_glRectfv(void *_glfuncs, const GLfloat* v1, const GLfloat* v2)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRectfv(v1, v2);
+}
+
+void gl4_3compat_glRectf(void *_glfuncs, GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRectf(x1, y1, x2, y2);
+}
+
+void gl4_3compat_glRectdv(void *_glfuncs, const GLdouble* v1, const GLdouble* v2)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRectdv(v1, v2);
+}
+
+void gl4_3compat_glRectd(void *_glfuncs, GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRectd(x1, y1, x2, y2);
+}
+
+void gl4_3compat_glRasterPos4sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos4sv(v);
+}
+
+void gl4_3compat_glRasterPos4s(void *_glfuncs, GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos4s(x, y, z, w);
+}
+
+void gl4_3compat_glRasterPos4iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos4iv(v);
+}
+
+void gl4_3compat_glRasterPos4i(void *_glfuncs, GLint x, GLint y, GLint z, GLint w)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos4i(x, y, z, w);
+}
+
+void gl4_3compat_glRasterPos4fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos4fv(v);
+}
+
+void gl4_3compat_glRasterPos4f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos4f(x, y, z, w);
+}
+
+void gl4_3compat_glRasterPos4dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos4dv(v);
+}
+
+void gl4_3compat_glRasterPos4d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos4d(x, y, z, w);
+}
+
+void gl4_3compat_glRasterPos3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos3sv(v);
+}
+
+void gl4_3compat_glRasterPos3s(void *_glfuncs, GLshort x, GLshort y, GLshort z)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos3s(x, y, z);
+}
+
+void gl4_3compat_glRasterPos3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos3iv(v);
+}
+
+void gl4_3compat_glRasterPos3i(void *_glfuncs, GLint x, GLint y, GLint z)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos3i(x, y, z);
+}
+
+void gl4_3compat_glRasterPos3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos3fv(v);
+}
+
+void gl4_3compat_glRasterPos3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos3f(x, y, z);
+}
+
+void gl4_3compat_glRasterPos3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos3dv(v);
+}
+
+void gl4_3compat_glRasterPos3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos3d(x, y, z);
+}
+
+void gl4_3compat_glRasterPos2sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos2sv(v);
+}
+
+void gl4_3compat_glRasterPos2s(void *_glfuncs, GLshort x, GLshort y)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos2s(x, y);
+}
+
+void gl4_3compat_glRasterPos2iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos2iv(v);
+}
+
+void gl4_3compat_glRasterPos2i(void *_glfuncs, GLint x, GLint y)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos2i(x, y);
+}
+
+void gl4_3compat_glRasterPos2fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos2fv(v);
+}
+
+void gl4_3compat_glRasterPos2f(void *_glfuncs, GLfloat x, GLfloat y)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos2f(x, y);
+}
+
+void gl4_3compat_glRasterPos2dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos2dv(v);
+}
+
+void gl4_3compat_glRasterPos2d(void *_glfuncs, GLdouble x, GLdouble y)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glRasterPos2d(x, y);
+}
+
+void gl4_3compat_glNormal3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormal3sv(v);
+}
+
+void gl4_3compat_glNormal3s(void *_glfuncs, GLshort nx, GLshort ny, GLshort nz)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormal3s(nx, ny, nz);
+}
+
+void gl4_3compat_glNormal3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormal3iv(v);
+}
+
+void gl4_3compat_glNormal3i(void *_glfuncs, GLint nx, GLint ny, GLint nz)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormal3i(nx, ny, nz);
+}
+
+void gl4_3compat_glNormal3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormal3fv(v);
+}
+
+void gl4_3compat_glNormal3f(void *_glfuncs, GLfloat nx, GLfloat ny, GLfloat nz)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormal3f(nx, ny, nz);
+}
+
+void gl4_3compat_glNormal3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormal3dv(v);
+}
+
+void gl4_3compat_glNormal3d(void *_glfuncs, GLdouble nx, GLdouble ny, GLdouble nz)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormal3d(nx, ny, nz);
+}
+
+void gl4_3compat_glNormal3bv(void *_glfuncs, const GLbyte* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormal3bv(v);
+}
+
+void gl4_3compat_glNormal3b(void *_glfuncs, GLbyte nx, GLbyte ny, GLbyte nz)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormal3b(nx, ny, nz);
+}
+
+void gl4_3compat_glIndexsv(void *_glfuncs, const GLshort* c)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexsv(c);
+}
+
+void gl4_3compat_glIndexs(void *_glfuncs, GLshort c)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexs(c);
+}
+
+void gl4_3compat_glIndexiv(void *_glfuncs, const GLint* c)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexiv(c);
+}
+
+void gl4_3compat_glIndexi(void *_glfuncs, GLint c)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexi(c);
+}
+
+void gl4_3compat_glIndexfv(void *_glfuncs, const GLfloat* c)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexfv(c);
+}
+
+void gl4_3compat_glIndexf(void *_glfuncs, GLfloat c)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexf(c);
+}
+
+void gl4_3compat_glIndexdv(void *_glfuncs, const GLdouble* c)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexdv(c);
+}
+
+void gl4_3compat_glIndexd(void *_glfuncs, GLdouble c)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexd(c);
+}
+
+void gl4_3compat_glEnd(void *_glfuncs)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glEnd();
+}
+
+void gl4_3compat_glEdgeFlagv(void *_glfuncs, const GLboolean* flag)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glEdgeFlagv(flag);
+}
+
+void gl4_3compat_glEdgeFlag(void *_glfuncs, GLboolean flag)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glEdgeFlag(flag);
+}
+
+void gl4_3compat_glColor4usv(void *_glfuncs, const GLushort* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4usv(v);
+}
+
+void gl4_3compat_glColor4us(void *_glfuncs, GLushort red, GLushort green, GLushort blue, GLushort alpha)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4us(red, green, blue, alpha);
+}
+
+void gl4_3compat_glColor4uiv(void *_glfuncs, const GLuint* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4uiv(v);
+}
+
+void gl4_3compat_glColor4ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue, GLuint alpha)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4ui(red, green, blue, alpha);
+}
+
+void gl4_3compat_glColor4ubv(void *_glfuncs, const GLubyte* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4ubv(v);
+}
+
+void gl4_3compat_glColor4ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4ub(red, green, blue, alpha);
+}
+
+void gl4_3compat_glColor4sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4sv(v);
+}
+
+void gl4_3compat_glColor4s(void *_glfuncs, GLshort red, GLshort green, GLshort blue, GLshort alpha)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4s(red, green, blue, alpha);
+}
+
+void gl4_3compat_glColor4iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4iv(v);
+}
+
+void gl4_3compat_glColor4i(void *_glfuncs, GLint red, GLint green, GLint blue, GLint alpha)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4i(red, green, blue, alpha);
+}
+
+void gl4_3compat_glColor4fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4fv(v);
+}
+
+void gl4_3compat_glColor4f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4f(red, green, blue, alpha);
+}
+
+void gl4_3compat_glColor4dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4dv(v);
+}
+
+void gl4_3compat_glColor4d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4d(red, green, blue, alpha);
+}
+
+void gl4_3compat_glColor4bv(void *_glfuncs, const GLbyte* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4bv(v);
+}
+
+void gl4_3compat_glColor4b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor4b(red, green, blue, alpha);
+}
+
+void gl4_3compat_glColor3usv(void *_glfuncs, const GLushort* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3usv(v);
+}
+
+void gl4_3compat_glColor3us(void *_glfuncs, GLushort red, GLushort green, GLushort blue)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3us(red, green, blue);
+}
+
+void gl4_3compat_glColor3uiv(void *_glfuncs, const GLuint* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3uiv(v);
+}
+
+void gl4_3compat_glColor3ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3ui(red, green, blue);
+}
+
+void gl4_3compat_glColor3ubv(void *_glfuncs, const GLubyte* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3ubv(v);
+}
+
+void gl4_3compat_glColor3ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3ub(red, green, blue);
+}
+
+void gl4_3compat_glColor3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3sv(v);
+}
+
+void gl4_3compat_glColor3s(void *_glfuncs, GLshort red, GLshort green, GLshort blue)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3s(red, green, blue);
+}
+
+void gl4_3compat_glColor3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3iv(v);
+}
+
+void gl4_3compat_glColor3i(void *_glfuncs, GLint red, GLint green, GLint blue)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3i(red, green, blue);
+}
+
+void gl4_3compat_glColor3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3fv(v);
+}
+
+void gl4_3compat_glColor3f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3f(red, green, blue);
+}
+
+void gl4_3compat_glColor3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3dv(v);
+}
+
+void gl4_3compat_glColor3d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3d(red, green, blue);
+}
+
+void gl4_3compat_glColor3bv(void *_glfuncs, const GLbyte* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3bv(v);
+}
+
+void gl4_3compat_glColor3b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColor3b(red, green, blue);
+}
+
+void gl4_3compat_glBitmap(void *_glfuncs, GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte* bitmap)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glBitmap(width, height, xorig, yorig, xmove, ymove, bitmap);
+}
+
+void gl4_3compat_glBegin(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glBegin(mode);
+}
+
+void gl4_3compat_glListBase(void *_glfuncs, GLuint base)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glListBase(base);
+}
+
+GLuint gl4_3compat_glGenLists(void *_glfuncs, GLsizei range_)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glGenLists(range_);
+}
+
+void gl4_3compat_glDeleteLists(void *_glfuncs, GLuint list, GLsizei range_)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDeleteLists(list, range_);
+}
+
+void gl4_3compat_glCallLists(void *_glfuncs, GLsizei n, GLenum gltype, const GLvoid* lists)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glCallLists(n, gltype, lists);
+}
+
+void gl4_3compat_glCallList(void *_glfuncs, GLuint list)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glCallList(list);
+}
+
+void gl4_3compat_glEndList(void *_glfuncs)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glEndList();
+}
+
+void gl4_3compat_glNewList(void *_glfuncs, GLuint list, GLenum mode)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glNewList(list, mode);
+}
+
+void gl4_3compat_glPushClientAttrib(void *_glfuncs, GLbitfield mask)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glPushClientAttrib(mask);
+}
+
+void gl4_3compat_glPopClientAttrib(void *_glfuncs)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glPopClientAttrib();
+}
+
+void gl4_3compat_glPrioritizeTextures(void *_glfuncs, GLsizei n, const GLuint* textures, const GLfloat* priorities)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glPrioritizeTextures(n, textures, priorities);
+}
+
+GLboolean gl4_3compat_glAreTexturesResident(void *_glfuncs, GLsizei n, const GLuint* textures, GLboolean* residences)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ return _qglfuncs->glAreTexturesResident(n, textures, residences);
+}
+
+void gl4_3compat_glVertexPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexPointer(size, gltype, stride, pointer);
+}
+
+void gl4_3compat_glTexCoordPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glTexCoordPointer(size, gltype, stride, pointer);
+}
+
+void gl4_3compat_glNormalPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glNormalPointer(gltype, stride, pointer);
+}
+
+void gl4_3compat_glInterleavedArrays(void *_glfuncs, GLenum format, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glInterleavedArrays(format, stride, pointer);
+}
+
+void gl4_3compat_glIndexPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glIndexPointer(gltype, stride, pointer);
+}
+
+void gl4_3compat_glEnableClientState(void *_glfuncs, GLenum array)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glEnableClientState(array);
+}
+
+void gl4_3compat_glEdgeFlagPointer(void *_glfuncs, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glEdgeFlagPointer(stride, pointer);
+}
+
+void gl4_3compat_glDisableClientState(void *_glfuncs, GLenum array)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glDisableClientState(array);
+}
+
+void gl4_3compat_glColorPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorPointer(size, gltype, stride, pointer);
+}
+
+void gl4_3compat_glArrayElement(void *_glfuncs, GLint i)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glArrayElement(i);
+}
+
+void gl4_3compat_glResetMinmax(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glResetMinmax(target);
+}
+
+void gl4_3compat_glResetHistogram(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glResetHistogram(target);
+}
+
+void gl4_3compat_glMinmax(void *_glfuncs, GLenum target, GLenum internalFormat, GLboolean sink)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMinmax(target, internalFormat, sink);
+}
+
+void gl4_3compat_glHistogram(void *_glfuncs, GLenum target, GLsizei width, GLenum internalFormat, GLboolean sink)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glHistogram(target, width, internalFormat, sink);
+}
+
+void gl4_3compat_glGetMinmaxParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetMinmaxParameteriv(target, pname, params);
+}
+
+void gl4_3compat_glGetMinmaxParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetMinmaxParameterfv(target, pname, params);
+}
+
+void gl4_3compat_glGetMinmax(void *_glfuncs, GLenum target, GLboolean reset, GLenum format, GLenum gltype, GLvoid* values)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetMinmax(target, reset, format, gltype, values);
+}
+
+void gl4_3compat_glGetHistogramParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetHistogramParameteriv(target, pname, params);
+}
+
+void gl4_3compat_glGetHistogramParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetHistogramParameterfv(target, pname, params);
+}
+
+void gl4_3compat_glGetHistogram(void *_glfuncs, GLenum target, GLboolean reset, GLenum format, GLenum gltype, GLvoid* values)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetHistogram(target, reset, format, gltype, values);
+}
+
+void gl4_3compat_glSeparableFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* row, const GLvoid* column)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glSeparableFilter2D(target, internalFormat, width, height, format, gltype, row, column);
+}
+
+void gl4_3compat_glGetSeparableFilter(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* row, GLvoid* column, GLvoid* span)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetSeparableFilter(target, format, gltype, row, column, span);
+}
+
+void gl4_3compat_glGetConvolutionParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetConvolutionParameteriv(target, pname, params);
+}
+
+void gl4_3compat_glGetConvolutionParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetConvolutionParameterfv(target, pname, params);
+}
+
+void gl4_3compat_glGetConvolutionFilter(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* image)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetConvolutionFilter(target, format, gltype, image);
+}
+
+void gl4_3compat_glCopyConvolutionFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyConvolutionFilter2D(target, internalFormat, x, y, width, height);
+}
+
+void gl4_3compat_glCopyConvolutionFilter1D(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyConvolutionFilter1D(target, internalFormat, x, y, width);
+}
+
+void gl4_3compat_glConvolutionParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glConvolutionParameteriv(target, pname, params);
+}
+
+void gl4_3compat_glConvolutionParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glConvolutionParameteri(target, pname, params);
+}
+
+void gl4_3compat_glConvolutionParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glConvolutionParameterfv(target, pname, params);
+}
+
+void gl4_3compat_glConvolutionParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glConvolutionParameterf(target, pname, params);
+}
+
+void gl4_3compat_glConvolutionFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* image)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glConvolutionFilter2D(target, internalFormat, width, height, format, gltype, image);
+}
+
+void gl4_3compat_glConvolutionFilter1D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLenum format, GLenum gltype, const GLvoid* image)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glConvolutionFilter1D(target, internalFormat, width, format, gltype, image);
+}
+
+void gl4_3compat_glCopyColorSubTable(void *_glfuncs, GLenum target, GLsizei start, GLint x, GLint y, GLsizei width)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyColorSubTable(target, start, x, y, width);
+}
+
+void gl4_3compat_glColorSubTable(void *_glfuncs, GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum gltype, const GLvoid* data)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorSubTable(target, start, count, format, gltype, data);
+}
+
+void gl4_3compat_glGetColorTableParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetColorTableParameteriv(target, pname, params);
+}
+
+void gl4_3compat_glGetColorTableParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetColorTableParameterfv(target, pname, params);
+}
+
+void gl4_3compat_glGetColorTable(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* table)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glGetColorTable(target, format, gltype, table);
+}
+
+void gl4_3compat_glCopyColorTable(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glCopyColorTable(target, internalFormat, x, y, width);
+}
+
+void gl4_3compat_glColorTableParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorTableParameteriv(target, pname, params);
+}
+
+void gl4_3compat_glColorTableParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorTableParameterfv(target, pname, params);
+}
+
+void gl4_3compat_glColorTable(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLenum format, GLenum gltype, const GLvoid* table)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glColorTable(target, internalFormat, width, format, gltype, table);
+}
+
+void gl4_3compat_glMultTransposeMatrixd(void *_glfuncs, const GLdouble* m)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultTransposeMatrixd(m);
+}
+
+void gl4_3compat_glMultTransposeMatrixf(void *_glfuncs, const GLfloat* m)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultTransposeMatrixf(m);
+}
+
+void gl4_3compat_glLoadTransposeMatrixd(void *_glfuncs, const GLdouble* m)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glLoadTransposeMatrixd(m);
+}
+
+void gl4_3compat_glLoadTransposeMatrixf(void *_glfuncs, const GLfloat* m)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glLoadTransposeMatrixf(m);
+}
+
+void gl4_3compat_glMultiTexCoord4sv(void *_glfuncs, GLenum target, const GLshort* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4sv(target, v);
+}
+
+void gl4_3compat_glMultiTexCoord4s(void *_glfuncs, GLenum target, GLshort s, GLshort t, GLshort r, GLshort q)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4s(target, s, t, r, q);
+}
+
+void gl4_3compat_glMultiTexCoord4iv(void *_glfuncs, GLenum target, const GLint* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4iv(target, v);
+}
+
+void gl4_3compat_glMultiTexCoord4i(void *_glfuncs, GLenum target, GLint s, GLint t, GLint r, GLint q)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4i(target, s, t, r, q);
+}
+
+void gl4_3compat_glMultiTexCoord4fv(void *_glfuncs, GLenum target, const GLfloat* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4fv(target, v);
+}
+
+void gl4_3compat_glMultiTexCoord4f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4f(target, s, t, r, q);
+}
+
+void gl4_3compat_glMultiTexCoord4dv(void *_glfuncs, GLenum target, const GLdouble* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4dv(target, v);
+}
+
+void gl4_3compat_glMultiTexCoord4d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord4d(target, s, t, r, q);
+}
+
+void gl4_3compat_glMultiTexCoord3sv(void *_glfuncs, GLenum target, const GLshort* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3sv(target, v);
+}
+
+void gl4_3compat_glMultiTexCoord3s(void *_glfuncs, GLenum target, GLshort s, GLshort t, GLshort r)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3s(target, s, t, r);
+}
+
+void gl4_3compat_glMultiTexCoord3iv(void *_glfuncs, GLenum target, const GLint* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3iv(target, v);
+}
+
+void gl4_3compat_glMultiTexCoord3i(void *_glfuncs, GLenum target, GLint s, GLint t, GLint r)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3i(target, s, t, r);
+}
+
+void gl4_3compat_glMultiTexCoord3fv(void *_glfuncs, GLenum target, const GLfloat* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3fv(target, v);
+}
+
+void gl4_3compat_glMultiTexCoord3f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t, GLfloat r)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3f(target, s, t, r);
+}
+
+void gl4_3compat_glMultiTexCoord3dv(void *_glfuncs, GLenum target, const GLdouble* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3dv(target, v);
+}
+
+void gl4_3compat_glMultiTexCoord3d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t, GLdouble r)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord3d(target, s, t, r);
+}
+
+void gl4_3compat_glMultiTexCoord2sv(void *_glfuncs, GLenum target, const GLshort* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2sv(target, v);
+}
+
+void gl4_3compat_glMultiTexCoord2s(void *_glfuncs, GLenum target, GLshort s, GLshort t)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2s(target, s, t);
+}
+
+void gl4_3compat_glMultiTexCoord2iv(void *_glfuncs, GLenum target, const GLint* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2iv(target, v);
+}
+
+void gl4_3compat_glMultiTexCoord2i(void *_glfuncs, GLenum target, GLint s, GLint t)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2i(target, s, t);
+}
+
+void gl4_3compat_glMultiTexCoord2fv(void *_glfuncs, GLenum target, const GLfloat* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2fv(target, v);
+}
+
+void gl4_3compat_glMultiTexCoord2f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2f(target, s, t);
+}
+
+void gl4_3compat_glMultiTexCoord2dv(void *_glfuncs, GLenum target, const GLdouble* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2dv(target, v);
+}
+
+void gl4_3compat_glMultiTexCoord2d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord2d(target, s, t);
+}
+
+void gl4_3compat_glMultiTexCoord1sv(void *_glfuncs, GLenum target, const GLshort* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1sv(target, v);
+}
+
+void gl4_3compat_glMultiTexCoord1s(void *_glfuncs, GLenum target, GLshort s)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1s(target, s);
+}
+
+void gl4_3compat_glMultiTexCoord1iv(void *_glfuncs, GLenum target, const GLint* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1iv(target, v);
+}
+
+void gl4_3compat_glMultiTexCoord1i(void *_glfuncs, GLenum target, GLint s)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1i(target, s);
+}
+
+void gl4_3compat_glMultiTexCoord1fv(void *_glfuncs, GLenum target, const GLfloat* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1fv(target, v);
+}
+
+void gl4_3compat_glMultiTexCoord1f(void *_glfuncs, GLenum target, GLfloat s)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1f(target, s);
+}
+
+void gl4_3compat_glMultiTexCoord1dv(void *_glfuncs, GLenum target, const GLdouble* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1dv(target, v);
+}
+
+void gl4_3compat_glMultiTexCoord1d(void *_glfuncs, GLenum target, GLdouble s)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glMultiTexCoord1d(target, s);
+}
+
+void gl4_3compat_glClientActiveTexture(void *_glfuncs, GLenum texture)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glClientActiveTexture(texture);
+}
+
+void gl4_3compat_glWindowPos3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos3sv(v);
+}
+
+void gl4_3compat_glWindowPos3s(void *_glfuncs, GLshort x, GLshort y, GLshort z)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos3s(x, y, z);
+}
+
+void gl4_3compat_glWindowPos3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos3iv(v);
+}
+
+void gl4_3compat_glWindowPos3i(void *_glfuncs, GLint x, GLint y, GLint z)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos3i(x, y, z);
+}
+
+void gl4_3compat_glWindowPos3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos3fv(v);
+}
+
+void gl4_3compat_glWindowPos3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos3f(x, y, z);
+}
+
+void gl4_3compat_glWindowPos3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos3dv(v);
+}
+
+void gl4_3compat_glWindowPos3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos3d(x, y, z);
+}
+
+void gl4_3compat_glWindowPos2sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos2sv(v);
+}
+
+void gl4_3compat_glWindowPos2s(void *_glfuncs, GLshort x, GLshort y)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos2s(x, y);
+}
+
+void gl4_3compat_glWindowPos2iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos2iv(v);
+}
+
+void gl4_3compat_glWindowPos2i(void *_glfuncs, GLint x, GLint y)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos2i(x, y);
+}
+
+void gl4_3compat_glWindowPos2fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos2fv(v);
+}
+
+void gl4_3compat_glWindowPos2f(void *_glfuncs, GLfloat x, GLfloat y)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos2f(x, y);
+}
+
+void gl4_3compat_glWindowPos2dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos2dv(v);
+}
+
+void gl4_3compat_glWindowPos2d(void *_glfuncs, GLdouble x, GLdouble y)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glWindowPos2d(x, y);
+}
+
+void gl4_3compat_glSecondaryColorPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColorPointer(size, gltype, stride, pointer);
+}
+
+void gl4_3compat_glSecondaryColor3usv(void *_glfuncs, const GLushort* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3usv(v);
+}
+
+void gl4_3compat_glSecondaryColor3us(void *_glfuncs, GLushort red, GLushort green, GLushort blue)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3us(red, green, blue);
+}
+
+void gl4_3compat_glSecondaryColor3uiv(void *_glfuncs, const GLuint* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3uiv(v);
+}
+
+void gl4_3compat_glSecondaryColor3ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3ui(red, green, blue);
+}
+
+void gl4_3compat_glSecondaryColor3ubv(void *_glfuncs, const GLubyte* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3ubv(v);
+}
+
+void gl4_3compat_glSecondaryColor3ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3ub(red, green, blue);
+}
+
+void gl4_3compat_glSecondaryColor3sv(void *_glfuncs, const GLshort* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3sv(v);
+}
+
+void gl4_3compat_glSecondaryColor3s(void *_glfuncs, GLshort red, GLshort green, GLshort blue)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3s(red, green, blue);
+}
+
+void gl4_3compat_glSecondaryColor3iv(void *_glfuncs, const GLint* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3iv(v);
+}
+
+void gl4_3compat_glSecondaryColor3i(void *_glfuncs, GLint red, GLint green, GLint blue)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3i(red, green, blue);
+}
+
+void gl4_3compat_glSecondaryColor3fv(void *_glfuncs, const GLfloat* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3fv(v);
+}
+
+void gl4_3compat_glSecondaryColor3f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3f(red, green, blue);
+}
+
+void gl4_3compat_glSecondaryColor3dv(void *_glfuncs, const GLdouble* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3dv(v);
+}
+
+void gl4_3compat_glSecondaryColor3d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3d(red, green, blue);
+}
+
+void gl4_3compat_glSecondaryColor3bv(void *_glfuncs, const GLbyte* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3bv(v);
+}
+
+void gl4_3compat_glSecondaryColor3b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glSecondaryColor3b(red, green, blue);
+}
+
+void gl4_3compat_glFogCoordPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glFogCoordPointer(gltype, stride, pointer);
+}
+
+void gl4_3compat_glFogCoorddv(void *_glfuncs, const GLdouble* coord)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glFogCoorddv(coord);
+}
+
+void gl4_3compat_glFogCoordd(void *_glfuncs, GLdouble coord)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glFogCoordd(coord);
+}
+
+void gl4_3compat_glFogCoordfv(void *_glfuncs, const GLfloat* coord)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glFogCoordfv(coord);
+}
+
+void gl4_3compat_glFogCoordf(void *_glfuncs, GLfloat coord)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glFogCoordf(coord);
+}
+
+void gl4_3compat_glVertexAttrib4usv(void *_glfuncs, GLuint index, const GLushort* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4usv(index, v);
+}
+
+void gl4_3compat_glVertexAttrib4uiv(void *_glfuncs, GLuint index, const GLuint* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4uiv(index, v);
+}
+
+void gl4_3compat_glVertexAttrib4ubv(void *_glfuncs, GLuint index, const GLubyte* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4ubv(index, v);
+}
+
+void gl4_3compat_glVertexAttrib4sv(void *_glfuncs, GLuint index, const GLshort* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4sv(index, v);
+}
+
+void gl4_3compat_glVertexAttrib4s(void *_glfuncs, GLuint index, GLshort x, GLshort y, GLshort z, GLshort w)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4s(index, x, y, z, w);
+}
+
+void gl4_3compat_glVertexAttrib4iv(void *_glfuncs, GLuint index, const GLint* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4iv(index, v);
+}
+
+void gl4_3compat_glVertexAttrib4fv(void *_glfuncs, GLuint index, const GLfloat* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4fv(index, v);
+}
+
+void gl4_3compat_glVertexAttrib4f(void *_glfuncs, GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4f(index, x, y, z, w);
+}
+
+void gl4_3compat_glVertexAttrib4dv(void *_glfuncs, GLuint index, const GLdouble* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4dv(index, v);
+}
+
+void gl4_3compat_glVertexAttrib4d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4d(index, x, y, z, w);
+}
+
+void gl4_3compat_glVertexAttrib4bv(void *_glfuncs, GLuint index, const GLbyte* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4bv(index, v);
+}
+
+void gl4_3compat_glVertexAttrib4Nusv(void *_glfuncs, GLuint index, const GLushort* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Nusv(index, v);
+}
+
+void gl4_3compat_glVertexAttrib4Nuiv(void *_glfuncs, GLuint index, const GLuint* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Nuiv(index, v);
+}
+
+void gl4_3compat_glVertexAttrib4Nubv(void *_glfuncs, GLuint index, const GLubyte* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Nubv(index, v);
+}
+
+void gl4_3compat_glVertexAttrib4Nub(void *_glfuncs, GLuint index, GLubyte x, GLubyte y, GLubyte z, GLubyte w)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Nub(index, x, y, z, w);
+}
+
+void gl4_3compat_glVertexAttrib4Nsv(void *_glfuncs, GLuint index, const GLshort* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Nsv(index, v);
+}
+
+void gl4_3compat_glVertexAttrib4Niv(void *_glfuncs, GLuint index, const GLint* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Niv(index, v);
+}
+
+void gl4_3compat_glVertexAttrib4Nbv(void *_glfuncs, GLuint index, const GLbyte* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4Nbv(index, v);
+}
+
+void gl4_3compat_glVertexAttrib3sv(void *_glfuncs, GLuint index, const GLshort* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib3sv(index, v);
+}
+
+void gl4_3compat_glVertexAttrib3s(void *_glfuncs, GLuint index, GLshort x, GLshort y, GLshort z)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib3s(index, x, y, z);
+}
+
+void gl4_3compat_glVertexAttrib3fv(void *_glfuncs, GLuint index, const GLfloat* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib3fv(index, v);
+}
+
+void gl4_3compat_glVertexAttrib3f(void *_glfuncs, GLuint index, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib3f(index, x, y, z);
+}
+
+void gl4_3compat_glVertexAttrib3dv(void *_glfuncs, GLuint index, const GLdouble* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib3dv(index, v);
+}
+
+void gl4_3compat_glVertexAttrib3d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib3d(index, x, y, z);
+}
+
+void gl4_3compat_glVertexAttrib2sv(void *_glfuncs, GLuint index, const GLshort* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib2sv(index, v);
+}
+
+void gl4_3compat_glVertexAttrib2s(void *_glfuncs, GLuint index, GLshort x, GLshort y)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib2s(index, x, y);
+}
+
+void gl4_3compat_glVertexAttrib2fv(void *_glfuncs, GLuint index, const GLfloat* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib2fv(index, v);
+}
+
+void gl4_3compat_glVertexAttrib2f(void *_glfuncs, GLuint index, GLfloat x, GLfloat y)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib2f(index, x, y);
+}
+
+void gl4_3compat_glVertexAttrib2dv(void *_glfuncs, GLuint index, const GLdouble* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib2dv(index, v);
+}
+
+void gl4_3compat_glVertexAttrib2d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib2d(index, x, y);
+}
+
+void gl4_3compat_glVertexAttrib1sv(void *_glfuncs, GLuint index, const GLshort* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib1sv(index, v);
+}
+
+void gl4_3compat_glVertexAttrib1s(void *_glfuncs, GLuint index, GLshort x)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib1s(index, x);
+}
+
+void gl4_3compat_glVertexAttrib1fv(void *_glfuncs, GLuint index, const GLfloat* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib1fv(index, v);
+}
+
+void gl4_3compat_glVertexAttrib1f(void *_glfuncs, GLuint index, GLfloat x)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib1f(index, x);
+}
+
+void gl4_3compat_glVertexAttrib1dv(void *_glfuncs, GLuint index, const GLdouble* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib1dv(index, v);
+}
+
+void gl4_3compat_glVertexAttrib1d(void *_glfuncs, GLuint index, GLdouble x)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttrib1d(index, x);
+}
+
+void gl4_3compat_glVertexAttribI4usv(void *_glfuncs, GLuint index, const GLushort* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI4usv(index, v);
+}
+
+void gl4_3compat_glVertexAttribI4ubv(void *_glfuncs, GLuint index, const GLubyte* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI4ubv(index, v);
+}
+
+void gl4_3compat_glVertexAttribI4sv(void *_glfuncs, GLuint index, const GLshort* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI4sv(index, v);
+}
+
+void gl4_3compat_glVertexAttribI4bv(void *_glfuncs, GLuint index, const GLbyte* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI4bv(index, v);
+}
+
+void gl4_3compat_glVertexAttribI4uiv(void *_glfuncs, GLuint index, const GLuint* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI4uiv(index, v);
+}
+
+void gl4_3compat_glVertexAttribI3uiv(void *_glfuncs, GLuint index, const GLuint* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI3uiv(index, v);
+}
+
+void gl4_3compat_glVertexAttribI2uiv(void *_glfuncs, GLuint index, const GLuint* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI2uiv(index, v);
+}
+
+void gl4_3compat_glVertexAttribI1uiv(void *_glfuncs, GLuint index, const GLuint* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI1uiv(index, v);
+}
+
+void gl4_3compat_glVertexAttribI4iv(void *_glfuncs, GLuint index, const GLint* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI4iv(index, v);
+}
+
+void gl4_3compat_glVertexAttribI3iv(void *_glfuncs, GLuint index, const GLint* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI3iv(index, v);
+}
+
+void gl4_3compat_glVertexAttribI2iv(void *_glfuncs, GLuint index, const GLint* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI2iv(index, v);
+}
+
+void gl4_3compat_glVertexAttribI1iv(void *_glfuncs, GLuint index, const GLint* v)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI1iv(index, v);
+}
+
+void gl4_3compat_glVertexAttribI4ui(void *_glfuncs, GLuint index, GLuint x, GLuint y, GLuint z, GLuint w)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI4ui(index, x, y, z, w);
+}
+
+void gl4_3compat_glVertexAttribI3ui(void *_glfuncs, GLuint index, GLuint x, GLuint y, GLuint z)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI3ui(index, x, y, z);
+}
+
+void gl4_3compat_glVertexAttribI2ui(void *_glfuncs, GLuint index, GLuint x, GLuint y)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI2ui(index, x, y);
+}
+
+void gl4_3compat_glVertexAttribI1ui(void *_glfuncs, GLuint index, GLuint x)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI1ui(index, x);
+}
+
+void gl4_3compat_glVertexAttribI4i(void *_glfuncs, GLuint index, GLint x, GLint y, GLint z, GLint w)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI4i(index, x, y, z, w);
+}
+
+void gl4_3compat_glVertexAttribI3i(void *_glfuncs, GLuint index, GLint x, GLint y, GLint z)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI3i(index, x, y, z);
+}
+
+void gl4_3compat_glVertexAttribI2i(void *_glfuncs, GLuint index, GLint x, GLint y)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI2i(index, x, y);
+}
+
+void gl4_3compat_glVertexAttribI1i(void *_glfuncs, GLuint index, GLint x)
+{
+ QOpenGLFunctions_4_3_Compatibility* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Compatibility*>(_glfuncs);
+ _qglfuncs->glVertexAttribI1i(index, x);
+}
+
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.3compat/funcs.h b/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.3compat/funcs.h
new file mode 100644
index 000000000..ef3dac794
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.3compat/funcs.h
@@ -0,0 +1,965 @@
+
+// ** file automatically generated by glgen -- do not edit manually **
+
+#ifndef __cplusplus
+#include <inttypes.h>
+#include <stddef.h>
+typedef unsigned int GLenum;
+typedef unsigned char GLboolean;
+typedef unsigned int GLbitfield;
+typedef void GLvoid;
+typedef char GLchar;
+typedef signed char GLbyte; /* 1-byte signed */
+typedef short GLshort; /* 2-byte signed */
+typedef int GLint; /* 4-byte signed */
+typedef unsigned char GLubyte; /* 1-byte unsigned */
+typedef unsigned short GLushort; /* 2-byte unsigned */
+typedef unsigned int GLuint; /* 4-byte unsigned */
+typedef int GLsizei; /* 4-byte signed */
+typedef float GLfloat; /* single precision float */
+typedef float GLclampf; /* single precision float in [0,1] */
+typedef double GLdouble; /* double precision float */
+typedef double GLclampd; /* double precision float in [0,1] */
+typedef int64_t GLint64;
+typedef uint64_t GLuint64;
+typedef ptrdiff_t GLintptr;
+typedef ptrdiff_t GLsizeiptr;
+typedef ptrdiff_t GLintptrARB;
+typedef ptrdiff_t GLsizeiptrARB;
+typedef struct __GLsync *GLsync;
+#endif
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+void *gl4_3compat_funcs();
+
+void gl4_3compat_glViewport(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl4_3compat_glDepthRange(void *_glfuncs, GLdouble nearVal, GLdouble farVal);
+GLboolean gl4_3compat_glIsEnabled(void *_glfuncs, GLenum cap);
+void gl4_3compat_glGetTexLevelParameteriv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLint* params);
+void gl4_3compat_glGetTexLevelParameterfv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLfloat* params);
+void gl4_3compat_glGetTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl4_3compat_glGetTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl4_3compat_glGetTexImage(void *_glfuncs, GLenum target, GLint level, GLenum format, GLenum gltype, GLvoid* pixels);
+void gl4_3compat_glGetIntegerv(void *_glfuncs, GLenum pname, GLint* params);
+void gl4_3compat_glGetFloatv(void *_glfuncs, GLenum pname, GLfloat* params);
+GLenum gl4_3compat_glGetError(void *_glfuncs);
+void gl4_3compat_glGetDoublev(void *_glfuncs, GLenum pname, GLdouble* params);
+void gl4_3compat_glGetBooleanv(void *_glfuncs, GLenum pname, GLboolean* params);
+void gl4_3compat_glReadPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum gltype, GLvoid* pixels);
+void gl4_3compat_glReadBuffer(void *_glfuncs, GLenum mode);
+void gl4_3compat_glPixelStorei(void *_glfuncs, GLenum pname, GLint param);
+void gl4_3compat_glPixelStoref(void *_glfuncs, GLenum pname, GLfloat param);
+void gl4_3compat_glDepthFunc(void *_glfuncs, GLenum glfunc);
+void gl4_3compat_glStencilOp(void *_glfuncs, GLenum fail, GLenum zfail, GLenum zpass);
+void gl4_3compat_glStencilFunc(void *_glfuncs, GLenum glfunc, GLint ref, GLuint mask);
+void gl4_3compat_glLogicOp(void *_glfuncs, GLenum opcode);
+void gl4_3compat_glBlendFunc(void *_glfuncs, GLenum sfactor, GLenum dfactor);
+void gl4_3compat_glFlush(void *_glfuncs);
+void gl4_3compat_glFinish(void *_glfuncs);
+void gl4_3compat_glEnable(void *_glfuncs, GLenum cap);
+void gl4_3compat_glDisable(void *_glfuncs, GLenum cap);
+void gl4_3compat_glDepthMask(void *_glfuncs, GLboolean flag);
+void gl4_3compat_glColorMask(void *_glfuncs, GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha);
+void gl4_3compat_glStencilMask(void *_glfuncs, GLuint mask);
+void gl4_3compat_glClearDepth(void *_glfuncs, GLdouble depth);
+void gl4_3compat_glClearStencil(void *_glfuncs, GLint s);
+void gl4_3compat_glClearColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl4_3compat_glClear(void *_glfuncs, GLbitfield mask);
+void gl4_3compat_glDrawBuffer(void *_glfuncs, GLenum mode);
+void gl4_3compat_glTexImage2D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl4_3compat_glTexImage1D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl4_3compat_glTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl4_3compat_glTexParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint param);
+void gl4_3compat_glTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl4_3compat_glTexParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param);
+void gl4_3compat_glScissor(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl4_3compat_glPolygonMode(void *_glfuncs, GLenum face, GLenum mode);
+void gl4_3compat_glPointSize(void *_glfuncs, GLfloat size);
+void gl4_3compat_glLineWidth(void *_glfuncs, GLfloat width);
+void gl4_3compat_glHint(void *_glfuncs, GLenum target, GLenum mode);
+void gl4_3compat_glFrontFace(void *_glfuncs, GLenum mode);
+void gl4_3compat_glCullFace(void *_glfuncs, GLenum mode);
+void gl4_3compat_glIndexubv(void *_glfuncs, const GLubyte* c);
+void gl4_3compat_glIndexub(void *_glfuncs, GLubyte c);
+GLboolean gl4_3compat_glIsTexture(void *_glfuncs, GLuint texture);
+void gl4_3compat_glGenTextures(void *_glfuncs, GLsizei n, GLuint* textures);
+void gl4_3compat_glDeleteTextures(void *_glfuncs, GLsizei n, const GLuint* textures);
+void gl4_3compat_glBindTexture(void *_glfuncs, GLenum target, GLuint texture);
+void gl4_3compat_glTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl4_3compat_glTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl4_3compat_glCopyTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl4_3compat_glCopyTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width);
+void gl4_3compat_glCopyTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border);
+void gl4_3compat_glCopyTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLint border);
+void gl4_3compat_glPolygonOffset(void *_glfuncs, GLfloat factor, GLfloat units);
+void gl4_3compat_glDrawElements(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices);
+void gl4_3compat_glDrawArrays(void *_glfuncs, GLenum mode, GLint first, GLsizei count);
+void gl4_3compat_glCopyTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl4_3compat_glTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl4_3compat_glTexImage3D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl4_3compat_glDrawRangeElements(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices);
+void gl4_3compat_glBlendEquation(void *_glfuncs, GLenum mode);
+void gl4_3compat_glBlendColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl4_3compat_glGetCompressedTexImage(void *_glfuncs, GLenum target, GLint level, GLvoid* img);
+void gl4_3compat_glCompressedTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid* data);
+void gl4_3compat_glCompressedTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid* data);
+void gl4_3compat_glCompressedTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid* data);
+void gl4_3compat_glCompressedTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid* data);
+void gl4_3compat_glCompressedTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid* data);
+void gl4_3compat_glCompressedTexImage3D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid* data);
+void gl4_3compat_glSampleCoverage(void *_glfuncs, GLfloat value, GLboolean invert);
+void gl4_3compat_glActiveTexture(void *_glfuncs, GLenum texture);
+void gl4_3compat_glPointParameteriv(void *_glfuncs, GLenum pname, const GLint* params);
+void gl4_3compat_glPointParameteri(void *_glfuncs, GLenum pname, GLint param);
+void gl4_3compat_glPointParameterfv(void *_glfuncs, GLenum pname, const GLfloat* params);
+void gl4_3compat_glPointParameterf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl4_3compat_glMultiDrawArrays(void *_glfuncs, GLenum mode, const GLint* first, const GLsizei* count, GLsizei drawcount);
+void gl4_3compat_glBlendFuncSeparate(void *_glfuncs, GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha);
+void gl4_3compat_glGetBufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+GLboolean gl4_3compat_glUnmapBuffer(void *_glfuncs, GLenum target);
+void gl4_3compat_glGetBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, GLvoid* data);
+void gl4_3compat_glBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid* data);
+void gl4_3compat_glBufferData(void *_glfuncs, GLenum target, GLsizeiptr size, const GLvoid* data, GLenum usage);
+GLboolean gl4_3compat_glIsBuffer(void *_glfuncs, GLuint buffer);
+void gl4_3compat_glGenBuffers(void *_glfuncs, GLsizei n, GLuint* buffers);
+void gl4_3compat_glDeleteBuffers(void *_glfuncs, GLsizei n, const GLuint* buffers);
+void gl4_3compat_glBindBuffer(void *_glfuncs, GLenum target, GLuint buffer);
+void gl4_3compat_glGetQueryObjectuiv(void *_glfuncs, GLuint id, GLenum pname, GLuint* params);
+void gl4_3compat_glGetQueryObjectiv(void *_glfuncs, GLuint id, GLenum pname, GLint* params);
+void gl4_3compat_glGetQueryiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl4_3compat_glEndQuery(void *_glfuncs, GLenum target);
+void gl4_3compat_glBeginQuery(void *_glfuncs, GLenum target, GLuint id);
+GLboolean gl4_3compat_glIsQuery(void *_glfuncs, GLuint id);
+void gl4_3compat_glDeleteQueries(void *_glfuncs, GLsizei n, const GLuint* ids);
+void gl4_3compat_glGenQueries(void *_glfuncs, GLsizei n, GLuint* ids);
+void gl4_3compat_glVertexAttribPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLboolean normalized, GLsizei stride, const GLvoid* offset);
+void gl4_3compat_glValidateProgram(void *_glfuncs, GLuint program);
+void gl4_3compat_glUniformMatrix4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_3compat_glUniformMatrix3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_3compat_glUniformMatrix2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_3compat_glUniform4iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl4_3compat_glUniform3iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl4_3compat_glUniform2iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl4_3compat_glUniform1iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl4_3compat_glUniform4fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl4_3compat_glUniform3fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl4_3compat_glUniform2fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl4_3compat_glUniform1fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl4_3compat_glUniform4i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2, GLint v3);
+void gl4_3compat_glUniform3i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2);
+void gl4_3compat_glUniform2i(void *_glfuncs, GLint location, GLint v0, GLint v1);
+void gl4_3compat_glUniform1i(void *_glfuncs, GLint location, GLint v0);
+void gl4_3compat_glUniform4f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3);
+void gl4_3compat_glUniform3f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2);
+void gl4_3compat_glUniform2f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1);
+void gl4_3compat_glUniform1f(void *_glfuncs, GLint location, GLfloat v0);
+void gl4_3compat_glUseProgram(void *_glfuncs, GLuint program);
+void gl4_3compat_glShaderSource(void *_glfuncs, GLuint shader, GLsizei count, const GLchar** source, const GLint* length);
+void gl4_3compat_glLinkProgram(void *_glfuncs, GLuint program);
+GLboolean gl4_3compat_glIsShader(void *_glfuncs, GLuint shader);
+GLboolean gl4_3compat_glIsProgram(void *_glfuncs, GLuint program);
+void gl4_3compat_glGetVertexAttribiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params);
+void gl4_3compat_glGetVertexAttribfv(void *_glfuncs, GLuint index, GLenum pname, GLfloat* params);
+void gl4_3compat_glGetVertexAttribdv(void *_glfuncs, GLuint index, GLenum pname, GLdouble* params);
+void gl4_3compat_glGetUniformiv(void *_glfuncs, GLuint program, GLint location, GLint* params);
+void gl4_3compat_glGetUniformfv(void *_glfuncs, GLuint program, GLint location, GLfloat* params);
+GLint gl4_3compat_glGetUniformLocation(void *_glfuncs, GLuint program, const GLchar* name);
+void gl4_3compat_glGetShaderSource(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* source);
+void gl4_3compat_glGetShaderInfoLog(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* infoLog);
+void gl4_3compat_glGetShaderiv(void *_glfuncs, GLuint shader, GLenum pname, GLint* params);
+void gl4_3compat_glGetProgramInfoLog(void *_glfuncs, GLuint program, GLsizei bufSize, GLsizei* length, GLchar* infoLog);
+void gl4_3compat_glGetProgramiv(void *_glfuncs, GLuint program, GLenum pname, GLint* params);
+GLint gl4_3compat_glGetAttribLocation(void *_glfuncs, GLuint program, const GLchar* name);
+void gl4_3compat_glGetAttachedShaders(void *_glfuncs, GLuint program, GLsizei maxCount, GLsizei* count, GLuint* obj);
+void gl4_3compat_glGetActiveUniform(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name);
+void gl4_3compat_glGetActiveAttrib(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name);
+void gl4_3compat_glEnableVertexAttribArray(void *_glfuncs, GLuint index);
+void gl4_3compat_glDisableVertexAttribArray(void *_glfuncs, GLuint index);
+void gl4_3compat_glDetachShader(void *_glfuncs, GLuint program, GLuint shader);
+void gl4_3compat_glDeleteShader(void *_glfuncs, GLuint shader);
+void gl4_3compat_glDeleteProgram(void *_glfuncs, GLuint program);
+GLuint gl4_3compat_glCreateShader(void *_glfuncs, GLenum gltype);
+GLuint gl4_3compat_glCreateProgram(void *_glfuncs);
+void gl4_3compat_glCompileShader(void *_glfuncs, GLuint shader);
+void gl4_3compat_glBindAttribLocation(void *_glfuncs, GLuint program, GLuint index, const GLchar* name);
+void gl4_3compat_glAttachShader(void *_glfuncs, GLuint program, GLuint shader);
+void gl4_3compat_glStencilMaskSeparate(void *_glfuncs, GLenum face, GLuint mask);
+void gl4_3compat_glStencilFuncSeparate(void *_glfuncs, GLenum face, GLenum glfunc, GLint ref, GLuint mask);
+void gl4_3compat_glStencilOpSeparate(void *_glfuncs, GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass);
+void gl4_3compat_glDrawBuffers(void *_glfuncs, GLsizei n, const GLenum* bufs);
+void gl4_3compat_glBlendEquationSeparate(void *_glfuncs, GLenum modeRGB, GLenum modeAlpha);
+void gl4_3compat_glUniformMatrix4x3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_3compat_glUniformMatrix3x4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_3compat_glUniformMatrix4x2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_3compat_glUniformMatrix2x4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_3compat_glUniformMatrix3x2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_3compat_glUniformMatrix2x3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+GLboolean gl4_3compat_glIsVertexArray(void *_glfuncs, GLuint array);
+void gl4_3compat_glGenVertexArrays(void *_glfuncs, GLsizei n, GLuint* arrays);
+void gl4_3compat_glDeleteVertexArrays(void *_glfuncs, GLsizei n, const GLuint* arrays);
+void gl4_3compat_glBindVertexArray(void *_glfuncs, GLuint array);
+void gl4_3compat_glFlushMappedBufferRange(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr length);
+void gl4_3compat_glFramebufferTextureLayer(void *_glfuncs, GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer);
+void gl4_3compat_glRenderbufferStorageMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLenum internalFormat, GLsizei width, GLsizei height);
+void gl4_3compat_glBlitFramebuffer(void *_glfuncs, GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter);
+void gl4_3compat_glGenerateMipmap(void *_glfuncs, GLenum target);
+void gl4_3compat_glGetFramebufferAttachmentParameteriv(void *_glfuncs, GLenum target, GLenum attachment, GLenum pname, GLint* params);
+void gl4_3compat_glFramebufferRenderbuffer(void *_glfuncs, GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer);
+void gl4_3compat_glFramebufferTexture3D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset);
+void gl4_3compat_glFramebufferTexture2D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+void gl4_3compat_glFramebufferTexture1D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+GLenum gl4_3compat_glCheckFramebufferStatus(void *_glfuncs, GLenum target);
+void gl4_3compat_glGenFramebuffers(void *_glfuncs, GLsizei n, GLuint* framebuffers);
+void gl4_3compat_glDeleteFramebuffers(void *_glfuncs, GLsizei n, const GLuint* framebuffers);
+void gl4_3compat_glBindFramebuffer(void *_glfuncs, GLenum target, GLuint framebuffer);
+GLboolean gl4_3compat_glIsFramebuffer(void *_glfuncs, GLuint framebuffer);
+void gl4_3compat_glGetRenderbufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl4_3compat_glRenderbufferStorage(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height);
+void gl4_3compat_glGenRenderbuffers(void *_glfuncs, GLsizei n, GLuint* renderbuffers);
+void gl4_3compat_glDeleteRenderbuffers(void *_glfuncs, GLsizei n, const GLuint* renderbuffers);
+void gl4_3compat_glBindRenderbuffer(void *_glfuncs, GLenum target, GLuint renderbuffer);
+GLboolean gl4_3compat_glIsRenderbuffer(void *_glfuncs, GLuint renderbuffer);
+void gl4_3compat_glClearBufferfi(void *_glfuncs, GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil);
+void gl4_3compat_glClearBufferfv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLfloat* value);
+void gl4_3compat_glClearBufferuiv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLuint* value);
+void gl4_3compat_glClearBufferiv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLint* value);
+void gl4_3compat_glGetTexParameterIuiv(void *_glfuncs, GLenum target, GLenum pname, GLuint* params);
+void gl4_3compat_glGetTexParameterIiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl4_3compat_glTexParameterIuiv(void *_glfuncs, GLenum target, GLenum pname, const GLuint* params);
+void gl4_3compat_glTexParameterIiv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl4_3compat_glUniform4uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value);
+void gl4_3compat_glUniform3uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value);
+void gl4_3compat_glUniform2uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value);
+void gl4_3compat_glUniform1uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value);
+void gl4_3compat_glUniform4ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3);
+void gl4_3compat_glUniform3ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1, GLuint v2);
+void gl4_3compat_glUniform2ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1);
+void gl4_3compat_glUniform1ui(void *_glfuncs, GLint location, GLuint v0);
+GLint gl4_3compat_glGetFragDataLocation(void *_glfuncs, GLuint program, const GLchar* name);
+void gl4_3compat_glBindFragDataLocation(void *_glfuncs, GLuint program, GLuint color, const GLchar* name);
+void gl4_3compat_glGetUniformuiv(void *_glfuncs, GLuint program, GLint location, GLuint* params);
+void gl4_3compat_glGetVertexAttribIuiv(void *_glfuncs, GLuint index, GLenum pname, GLuint* params);
+void gl4_3compat_glGetVertexAttribIiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params);
+void gl4_3compat_glVertexAttribIPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl4_3compat_glEndConditionalRender(void *_glfuncs);
+void gl4_3compat_glBeginConditionalRender(void *_glfuncs, GLuint id, GLenum mode);
+void gl4_3compat_glClampColor(void *_glfuncs, GLenum target, GLenum clamp);
+void gl4_3compat_glGetTransformFeedbackVarying(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLsizei* size, GLenum* gltype, GLchar* name);
+void gl4_3compat_glBindBufferBase(void *_glfuncs, GLenum target, GLuint index, GLuint buffer);
+void gl4_3compat_glBindBufferRange(void *_glfuncs, GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size);
+void gl4_3compat_glEndTransformFeedback(void *_glfuncs);
+void gl4_3compat_glBeginTransformFeedback(void *_glfuncs, GLenum primitiveMode);
+GLboolean gl4_3compat_glIsEnabledi(void *_glfuncs, GLenum target, GLuint index);
+void gl4_3compat_glDisablei(void *_glfuncs, GLenum target, GLuint index);
+void gl4_3compat_glEnablei(void *_glfuncs, GLenum target, GLuint index);
+void gl4_3compat_glGetIntegeri_v(void *_glfuncs, GLenum target, GLuint index, GLint* data);
+void gl4_3compat_glGetBooleani_v(void *_glfuncs, GLenum target, GLuint index, GLboolean* data);
+void gl4_3compat_glColorMaski(void *_glfuncs, GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a);
+void gl4_3compat_glCopyBufferSubData(void *_glfuncs, GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size);
+void gl4_3compat_glUniformBlockBinding(void *_glfuncs, GLuint program, GLuint v0, GLuint v1);
+void gl4_3compat_glGetActiveUniformBlockName(void *_glfuncs, GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei* length, GLchar* uniformBlockName);
+void gl4_3compat_glGetActiveUniformBlockiv(void *_glfuncs, GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint* params);
+GLuint gl4_3compat_glGetUniformBlockIndex(void *_glfuncs, GLuint program, const GLchar* uniformBlockName);
+void gl4_3compat_glGetActiveUniformName(void *_glfuncs, GLuint program, GLuint uniformIndex, GLsizei bufSize, GLsizei* length, GLchar* uniformName);
+void gl4_3compat_glGetActiveUniformsiv(void *_glfuncs, GLuint program, GLsizei uniformCount, const GLuint* uniformIndices, GLenum pname, GLint* params);
+void gl4_3compat_glPrimitiveRestartIndex(void *_glfuncs, GLuint index);
+void gl4_3compat_glTexBuffer(void *_glfuncs, GLenum target, GLenum internalFormat, GLuint buffer);
+void gl4_3compat_glDrawElementsInstanced(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount);
+void gl4_3compat_glDrawArraysInstanced(void *_glfuncs, GLenum mode, GLint first, GLsizei count, GLsizei instancecount);
+void gl4_3compat_glSampleMaski(void *_glfuncs, GLuint index, GLbitfield mask);
+void gl4_3compat_glGetMultisamplefv(void *_glfuncs, GLenum pname, GLuint index, GLfloat* val);
+void gl4_3compat_glTexImage3DMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations);
+void gl4_3compat_glTexImage2DMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLint internalFormat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations);
+void gl4_3compat_glGetSynciv(void *_glfuncs, GLsync sync, GLenum pname, GLsizei bufSize, GLsizei* length, GLint* values);
+void gl4_3compat_glGetInteger64v(void *_glfuncs, GLenum pname, GLint64* params);
+void gl4_3compat_glWaitSync(void *_glfuncs, GLsync sync, GLbitfield flags, GLuint64 timeout);
+GLenum gl4_3compat_glClientWaitSync(void *_glfuncs, GLsync sync, GLbitfield flags, GLuint64 timeout);
+void gl4_3compat_glDeleteSync(void *_glfuncs, GLsync sync);
+GLboolean gl4_3compat_glIsSync(void *_glfuncs, GLsync sync);
+GLsync gl4_3compat_glFenceSync(void *_glfuncs, GLenum condition, GLbitfield flags);
+void gl4_3compat_glProvokingVertex(void *_glfuncs, GLenum mode);
+void gl4_3compat_glDrawElementsInstancedBaseVertex(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount, GLint basevertex);
+void gl4_3compat_glDrawRangeElementsBaseVertex(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices, GLint basevertex);
+void gl4_3compat_glDrawElementsBaseVertex(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLint basevertex);
+void gl4_3compat_glFramebufferTexture(void *_glfuncs, GLenum target, GLenum attachment, GLuint texture, GLint level);
+void gl4_3compat_glGetBufferParameteri64v(void *_glfuncs, GLenum target, GLenum pname, GLint64* params);
+void gl4_3compat_glGetInteger64i_v(void *_glfuncs, GLenum target, GLuint index, GLint64* data);
+void gl4_3compat_glVertexAttribP4uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value);
+void gl4_3compat_glVertexAttribP4ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value);
+void gl4_3compat_glVertexAttribP3uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value);
+void gl4_3compat_glVertexAttribP3ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value);
+void gl4_3compat_glVertexAttribP2uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value);
+void gl4_3compat_glVertexAttribP2ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value);
+void gl4_3compat_glVertexAttribP1uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value);
+void gl4_3compat_glVertexAttribP1ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value);
+void gl4_3compat_glSecondaryColorP3uiv(void *_glfuncs, GLenum gltype, const GLuint* color);
+void gl4_3compat_glSecondaryColorP3ui(void *_glfuncs, GLenum gltype, GLuint color);
+void gl4_3compat_glColorP4uiv(void *_glfuncs, GLenum gltype, const GLuint* color);
+void gl4_3compat_glColorP4ui(void *_glfuncs, GLenum gltype, GLuint color);
+void gl4_3compat_glColorP3uiv(void *_glfuncs, GLenum gltype, const GLuint* color);
+void gl4_3compat_glColorP3ui(void *_glfuncs, GLenum gltype, GLuint color);
+void gl4_3compat_glNormalP3uiv(void *_glfuncs, GLenum gltype, const GLuint* coords);
+void gl4_3compat_glNormalP3ui(void *_glfuncs, GLenum gltype, GLuint coords);
+void gl4_3compat_glMultiTexCoordP4uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords);
+void gl4_3compat_glMultiTexCoordP4ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords);
+void gl4_3compat_glMultiTexCoordP3uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords);
+void gl4_3compat_glMultiTexCoordP3ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords);
+void gl4_3compat_glMultiTexCoordP2uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords);
+void gl4_3compat_glMultiTexCoordP2ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords);
+void gl4_3compat_glMultiTexCoordP1uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords);
+void gl4_3compat_glMultiTexCoordP1ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords);
+void gl4_3compat_glTexCoordP4uiv(void *_glfuncs, GLenum gltype, const GLuint* coords);
+void gl4_3compat_glTexCoordP4ui(void *_glfuncs, GLenum gltype, GLuint coords);
+void gl4_3compat_glTexCoordP3uiv(void *_glfuncs, GLenum gltype, const GLuint* coords);
+void gl4_3compat_glTexCoordP3ui(void *_glfuncs, GLenum gltype, GLuint coords);
+void gl4_3compat_glTexCoordP2uiv(void *_glfuncs, GLenum gltype, const GLuint* coords);
+void gl4_3compat_glTexCoordP2ui(void *_glfuncs, GLenum gltype, GLuint coords);
+void gl4_3compat_glTexCoordP1uiv(void *_glfuncs, GLenum gltype, const GLuint* coords);
+void gl4_3compat_glTexCoordP1ui(void *_glfuncs, GLenum gltype, GLuint coords);
+void gl4_3compat_glVertexP4uiv(void *_glfuncs, GLenum gltype, const GLuint* value);
+void gl4_3compat_glVertexP4ui(void *_glfuncs, GLenum gltype, GLuint value);
+void gl4_3compat_glVertexP3uiv(void *_glfuncs, GLenum gltype, const GLuint* value);
+void gl4_3compat_glVertexP3ui(void *_glfuncs, GLenum gltype, GLuint value);
+void gl4_3compat_glVertexP2uiv(void *_glfuncs, GLenum gltype, const GLuint* value);
+void gl4_3compat_glVertexP2ui(void *_glfuncs, GLenum gltype, GLuint value);
+void gl4_3compat_glGetQueryObjectui64v(void *_glfuncs, GLuint id, GLenum pname, GLuint64* params);
+void gl4_3compat_glGetQueryObjecti64v(void *_glfuncs, GLuint id, GLenum pname, GLint64* params);
+void gl4_3compat_glQueryCounter(void *_glfuncs, GLuint id, GLenum target);
+void gl4_3compat_glGetSamplerParameterIuiv(void *_glfuncs, GLuint sampler, GLenum pname, GLuint* params);
+void gl4_3compat_glGetSamplerParameterfv(void *_glfuncs, GLuint sampler, GLenum pname, GLfloat* params);
+void gl4_3compat_glGetSamplerParameterIiv(void *_glfuncs, GLuint sampler, GLenum pname, GLint* params);
+void gl4_3compat_glGetSamplerParameteriv(void *_glfuncs, GLuint sampler, GLenum pname, GLint* params);
+void gl4_3compat_glSamplerParameterIuiv(void *_glfuncs, GLuint sampler, GLenum pname, const GLuint* param);
+void gl4_3compat_glSamplerParameterIiv(void *_glfuncs, GLuint sampler, GLenum pname, const GLint* param);
+void gl4_3compat_glSamplerParameterfv(void *_glfuncs, GLuint sampler, GLenum pname, const GLfloat* param);
+void gl4_3compat_glSamplerParameterf(void *_glfuncs, GLuint sampler, GLenum pname, GLfloat param);
+void gl4_3compat_glSamplerParameteriv(void *_glfuncs, GLuint sampler, GLenum pname, const GLint* param);
+void gl4_3compat_glSamplerParameteri(void *_glfuncs, GLuint sampler, GLenum pname, GLint param);
+void gl4_3compat_glBindSampler(void *_glfuncs, GLuint unit, GLuint sampler);
+GLboolean gl4_3compat_glIsSampler(void *_glfuncs, GLuint sampler);
+void gl4_3compat_glDeleteSamplers(void *_glfuncs, GLsizei count, const GLuint* samplers);
+void gl4_3compat_glGenSamplers(void *_glfuncs, GLsizei count, GLuint* samplers);
+GLint gl4_3compat_glGetFragDataIndex(void *_glfuncs, GLuint program, const GLchar* name);
+void gl4_3compat_glBindFragDataLocationIndexed(void *_glfuncs, GLuint program, GLuint colorNumber, GLuint index, const GLchar* name);
+void gl4_3compat_glVertexAttribDivisor(void *_glfuncs, GLuint index, GLuint divisor);
+void gl4_3compat_glGetQueryIndexediv(void *_glfuncs, GLenum target, GLuint index, GLenum pname, GLint* params);
+void gl4_3compat_glEndQueryIndexed(void *_glfuncs, GLenum target, GLuint index);
+void gl4_3compat_glBeginQueryIndexed(void *_glfuncs, GLenum target, GLuint index, GLuint id);
+void gl4_3compat_glDrawTransformFeedbackStream(void *_glfuncs, GLenum mode, GLuint id, GLuint stream);
+void gl4_3compat_glDrawTransformFeedback(void *_glfuncs, GLenum mode, GLuint id);
+void gl4_3compat_glResumeTransformFeedback(void *_glfuncs);
+void gl4_3compat_glPauseTransformFeedback(void *_glfuncs);
+GLboolean gl4_3compat_glIsTransformFeedback(void *_glfuncs, GLuint id);
+void gl4_3compat_glGenTransformFeedbacks(void *_glfuncs, GLsizei n, GLuint* ids);
+void gl4_3compat_glDeleteTransformFeedbacks(void *_glfuncs, GLsizei n, const GLuint* ids);
+void gl4_3compat_glBindTransformFeedback(void *_glfuncs, GLenum target, GLuint id);
+void gl4_3compat_glPatchParameterfv(void *_glfuncs, GLenum pname, const GLfloat* values);
+void gl4_3compat_glPatchParameteri(void *_glfuncs, GLenum pname, GLint value);
+void gl4_3compat_glGetProgramStageiv(void *_glfuncs, GLuint program, GLenum shadertype, GLenum pname, GLint* values);
+void gl4_3compat_glGetUniformSubroutineuiv(void *_glfuncs, GLenum shadertype, GLint location, GLuint* params);
+void gl4_3compat_glUniformSubroutinesuiv(void *_glfuncs, GLenum shadertype, GLsizei count, const GLuint* value);
+void gl4_3compat_glGetActiveSubroutineName(void *_glfuncs, GLuint program, GLenum shadertype, GLuint index, GLsizei bufSize, GLsizei* length, GLchar* name);
+void gl4_3compat_glGetActiveSubroutineUniformName(void *_glfuncs, GLuint program, GLenum shadertype, GLuint index, GLsizei bufSize, GLsizei* length, GLchar* name);
+void gl4_3compat_glGetActiveSubroutineUniformiv(void *_glfuncs, GLuint program, GLenum shadertype, GLuint index, GLenum pname, GLint* values);
+GLuint gl4_3compat_glGetSubroutineIndex(void *_glfuncs, GLuint program, GLenum shadertype, const GLchar* name);
+GLint gl4_3compat_glGetSubroutineUniformLocation(void *_glfuncs, GLuint program, GLenum shadertype, const GLchar* name);
+void gl4_3compat_glGetUniformdv(void *_glfuncs, GLuint program, GLint location, GLdouble* params);
+void gl4_3compat_glUniformMatrix4x3dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_3compat_glUniformMatrix4x2dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_3compat_glUniformMatrix3x4dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_3compat_glUniformMatrix3x2dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_3compat_glUniformMatrix2x4dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_3compat_glUniformMatrix2x3dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_3compat_glUniformMatrix4dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_3compat_glUniformMatrix3dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_3compat_glUniformMatrix2dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_3compat_glUniform4dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value);
+void gl4_3compat_glUniform3dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value);
+void gl4_3compat_glUniform2dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value);
+void gl4_3compat_glUniform1dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value);
+void gl4_3compat_glUniform4d(void *_glfuncs, GLint location, GLdouble v0, GLdouble v1, GLdouble v2, GLdouble v3);
+void gl4_3compat_glUniform3d(void *_glfuncs, GLint location, GLdouble v0, GLdouble v1, GLdouble v2);
+void gl4_3compat_glUniform2d(void *_glfuncs, GLint location, GLdouble v0, GLdouble v1);
+void gl4_3compat_glUniform1d(void *_glfuncs, GLint location, GLdouble v0);
+void gl4_3compat_glDrawElementsIndirect(void *_glfuncs, GLenum mode, GLenum gltype, const GLvoid* indirect);
+void gl4_3compat_glDrawArraysIndirect(void *_glfuncs, GLenum mode, const GLvoid* indirect);
+void gl4_3compat_glBlendFuncSeparatei(void *_glfuncs, GLuint buf, GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha, GLenum dstAlpha);
+void gl4_3compat_glBlendFunci(void *_glfuncs, GLuint buf, GLenum src, GLenum dst);
+void gl4_3compat_glBlendEquationSeparatei(void *_glfuncs, GLuint buf, GLenum modeRGB, GLenum modeAlpha);
+void gl4_3compat_glBlendEquationi(void *_glfuncs, GLuint buf, GLenum mode);
+void gl4_3compat_glMinSampleShading(void *_glfuncs, GLfloat value);
+void gl4_3compat_glGetDoublei_v(void *_glfuncs, GLenum target, GLuint index, GLdouble* data);
+void gl4_3compat_glGetFloati_v(void *_glfuncs, GLenum target, GLuint index, GLfloat* data);
+void gl4_3compat_glDepthRangeIndexed(void *_glfuncs, GLuint index, GLdouble n, GLdouble f);
+void gl4_3compat_glDepthRangeArrayv(void *_glfuncs, GLuint first, GLsizei count, const GLdouble* v);
+void gl4_3compat_glScissorIndexedv(void *_glfuncs, GLuint index, const GLint* v);
+void gl4_3compat_glScissorIndexed(void *_glfuncs, GLuint index, GLint left, GLint bottom, GLsizei width, GLsizei height);
+void gl4_3compat_glScissorArrayv(void *_glfuncs, GLuint first, GLsizei count, const GLint* v);
+void gl4_3compat_glViewportIndexedfv(void *_glfuncs, GLuint index, const GLfloat* v);
+void gl4_3compat_glViewportIndexedf(void *_glfuncs, GLuint index, GLfloat x, GLfloat y, GLfloat w, GLfloat h);
+void gl4_3compat_glViewportArrayv(void *_glfuncs, GLuint first, GLsizei count, const GLfloat* v);
+void gl4_3compat_glGetVertexAttribLdv(void *_glfuncs, GLuint index, GLenum pname, GLdouble* params);
+void gl4_3compat_glVertexAttribLPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl4_3compat_glVertexAttribL4dv(void *_glfuncs, GLuint index, const GLdouble* v);
+void gl4_3compat_glVertexAttribL3dv(void *_glfuncs, GLuint index, const GLdouble* v);
+void gl4_3compat_glVertexAttribL2dv(void *_glfuncs, GLuint index, const GLdouble* v);
+void gl4_3compat_glVertexAttribL1dv(void *_glfuncs, GLuint index, const GLdouble* v);
+void gl4_3compat_glVertexAttribL4d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+void gl4_3compat_glVertexAttribL3d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y, GLdouble z);
+void gl4_3compat_glVertexAttribL2d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y);
+void gl4_3compat_glVertexAttribL1d(void *_glfuncs, GLuint index, GLdouble x);
+void gl4_3compat_glGetProgramPipelineInfoLog(void *_glfuncs, GLuint pipeline, GLsizei bufSize, GLsizei* length, GLchar* infoLog);
+void gl4_3compat_glValidateProgramPipeline(void *_glfuncs, GLuint pipeline);
+void gl4_3compat_glProgramUniformMatrix4x3dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_3compat_glProgramUniformMatrix3x4dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_3compat_glProgramUniformMatrix4x2dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_3compat_glProgramUniformMatrix2x4dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_3compat_glProgramUniformMatrix3x2dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_3compat_glProgramUniformMatrix2x3dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_3compat_glProgramUniformMatrix4x3fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_3compat_glProgramUniformMatrix3x4fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_3compat_glProgramUniformMatrix4x2fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_3compat_glProgramUniformMatrix2x4fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_3compat_glProgramUniformMatrix3x2fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_3compat_glProgramUniformMatrix2x3fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_3compat_glProgramUniformMatrix4dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_3compat_glProgramUniformMatrix3dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_3compat_glProgramUniformMatrix2dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_3compat_glProgramUniformMatrix4fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_3compat_glProgramUniformMatrix3fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_3compat_glProgramUniformMatrix2fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_3compat_glProgramUniform4uiv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLuint* value);
+void gl4_3compat_glProgramUniform4ui(void *_glfuncs, GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3);
+void gl4_3compat_glProgramUniform4dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLdouble* value);
+void gl4_3compat_glProgramUniform4d(void *_glfuncs, GLuint program, GLint location, GLdouble v0, GLdouble v1, GLdouble v2, GLdouble v3);
+void gl4_3compat_glProgramUniform4fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLfloat* value);
+void gl4_3compat_glProgramUniform4f(void *_glfuncs, GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3);
+void gl4_3compat_glProgramUniform4iv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLint* value);
+void gl4_3compat_glProgramUniform4i(void *_glfuncs, GLuint program, GLint location, GLint v0, GLint v1, GLint v2, GLint v3);
+void gl4_3compat_glProgramUniform3uiv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLuint* value);
+void gl4_3compat_glProgramUniform3ui(void *_glfuncs, GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2);
+void gl4_3compat_glProgramUniform3dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLdouble* value);
+void gl4_3compat_glProgramUniform3d(void *_glfuncs, GLuint program, GLint location, GLdouble v0, GLdouble v1, GLdouble v2);
+void gl4_3compat_glProgramUniform3fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLfloat* value);
+void gl4_3compat_glProgramUniform3f(void *_glfuncs, GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2);
+void gl4_3compat_glProgramUniform3iv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLint* value);
+void gl4_3compat_glProgramUniform3i(void *_glfuncs, GLuint program, GLint location, GLint v0, GLint v1, GLint v2);
+void gl4_3compat_glProgramUniform2uiv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLuint* value);
+void gl4_3compat_glProgramUniform2ui(void *_glfuncs, GLuint program, GLint location, GLuint v0, GLuint v1);
+void gl4_3compat_glProgramUniform2dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLdouble* value);
+void gl4_3compat_glProgramUniform2d(void *_glfuncs, GLuint program, GLint location, GLdouble v0, GLdouble v1);
+void gl4_3compat_glProgramUniform2fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLfloat* value);
+void gl4_3compat_glProgramUniform2f(void *_glfuncs, GLuint program, GLint location, GLfloat v0, GLfloat v1);
+void gl4_3compat_glProgramUniform2iv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLint* value);
+void gl4_3compat_glProgramUniform2i(void *_glfuncs, GLuint program, GLint location, GLint v0, GLint v1);
+void gl4_3compat_glProgramUniform1uiv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLuint* value);
+void gl4_3compat_glProgramUniform1ui(void *_glfuncs, GLuint program, GLint location, GLuint v0);
+void gl4_3compat_glProgramUniform1dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLdouble* value);
+void gl4_3compat_glProgramUniform1d(void *_glfuncs, GLuint program, GLint location, GLdouble v0);
+void gl4_3compat_glProgramUniform1fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLfloat* value);
+void gl4_3compat_glProgramUniform1f(void *_glfuncs, GLuint program, GLint location, GLfloat v0);
+void gl4_3compat_glProgramUniform1iv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLint* value);
+void gl4_3compat_glProgramUniform1i(void *_glfuncs, GLuint program, GLint location, GLint v0);
+void gl4_3compat_glGetProgramPipelineiv(void *_glfuncs, GLuint pipeline, GLenum pname, GLint* params);
+GLboolean gl4_3compat_glIsProgramPipeline(void *_glfuncs, GLuint pipeline);
+void gl4_3compat_glGenProgramPipelines(void *_glfuncs, GLsizei n, GLuint* pipelines);
+void gl4_3compat_glDeleteProgramPipelines(void *_glfuncs, GLsizei n, const GLuint* pipelines);
+void gl4_3compat_glBindProgramPipeline(void *_glfuncs, GLuint pipeline);
+void gl4_3compat_glActiveShaderProgram(void *_glfuncs, GLuint pipeline, GLuint program);
+void gl4_3compat_glUseProgramStages(void *_glfuncs, GLuint pipeline, GLbitfield stages, GLuint program);
+void gl4_3compat_glProgramParameteri(void *_glfuncs, GLuint program, GLenum pname, GLint value);
+void gl4_3compat_glProgramBinary(void *_glfuncs, GLuint program, GLenum binaryFormat, const GLvoid* binary, GLsizei length);
+void gl4_3compat_glGetProgramBinary(void *_glfuncs, GLuint program, GLsizei bufSize, GLsizei* length, GLenum* binaryFormat, GLvoid* binary);
+void gl4_3compat_glClearDepthf(void *_glfuncs, GLfloat dd);
+void gl4_3compat_glDepthRangef(void *_glfuncs, GLfloat n, GLfloat f);
+void gl4_3compat_glGetShaderPrecisionFormat(void *_glfuncs, GLenum shadertype, GLenum precisionType, GLint* range_, GLint* precision);
+void gl4_3compat_glShaderBinary(void *_glfuncs, GLsizei count, const GLuint* shaders, GLenum binaryFormat, const GLvoid* binary, GLsizei length);
+void gl4_3compat_glReleaseShaderCompiler(void *_glfuncs);
+void gl4_3compat_glTexStorage3D(void *_glfuncs, GLenum target, GLsizei levels, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth);
+void gl4_3compat_glTexStorage2D(void *_glfuncs, GLenum target, GLsizei levels, GLenum internalFormat, GLsizei width, GLsizei height);
+void gl4_3compat_glTexStorage1D(void *_glfuncs, GLenum target, GLsizei levels, GLenum internalFormat, GLsizei width);
+void gl4_3compat_glMemoryBarrier(void *_glfuncs, GLbitfield barriers);
+void gl4_3compat_glBindImageTexture(void *_glfuncs, GLuint unit, GLuint texture, GLint level, GLboolean layered, GLint layer, GLenum access, GLenum format);
+void gl4_3compat_glGetActiveAtomicCounterBufferiv(void *_glfuncs, GLuint program, GLuint bufferIndex, GLenum pname, GLint* params);
+void gl4_3compat_glGetInternalformativ(void *_glfuncs, GLenum target, GLenum internalFormat, GLenum pname, GLsizei bufSize, GLint* params);
+void gl4_3compat_glDrawTransformFeedbackStreamInstanced(void *_glfuncs, GLenum mode, GLuint id, GLuint stream, GLsizei instancecount);
+void gl4_3compat_glDrawTransformFeedbackInstanced(void *_glfuncs, GLenum mode, GLuint id, GLsizei instancecount);
+void gl4_3compat_glDrawElementsInstancedBaseVertexBaseInstance(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount, GLint basevertex, GLuint baseinstance);
+void gl4_3compat_glDrawElementsInstancedBaseInstance(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount, GLuint baseinstance);
+void gl4_3compat_glDrawArraysInstancedBaseInstance(void *_glfuncs, GLenum mode, GLint first, GLsizei count, GLsizei instancecount, GLuint baseinstance);
+void gl4_3compat_glTexStorage3DMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations);
+void gl4_3compat_glTexStorage2DMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLenum internalFormat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations);
+void gl4_3compat_glTexBufferRange(void *_glfuncs, GLenum target, GLenum internalFormat, GLuint buffer, GLintptr offset, GLsizeiptr size);
+void gl4_3compat_glShaderStorageBlockBinding(void *_glfuncs, GLuint program, GLuint storageBlockIndex, GLuint storageBlockBinding);
+GLint gl4_3compat_glGetProgramResourceLocationIndex(void *_glfuncs, GLuint program, GLenum programInterface, const GLchar* name);
+GLint gl4_3compat_glGetProgramResourceLocation(void *_glfuncs, GLuint program, GLenum programInterface, const GLchar* name);
+void gl4_3compat_glGetProgramResourceiv(void *_glfuncs, GLuint program, GLenum programInterface, GLuint index, GLsizei propCount, const GLenum* props, GLsizei bufSize, GLsizei* length, GLint* params);
+void gl4_3compat_glGetProgramResourceName(void *_glfuncs, GLuint program, GLenum programInterface, GLuint index, GLsizei bufSize, GLsizei* length, GLchar* name);
+GLuint gl4_3compat_glGetProgramResourceIndex(void *_glfuncs, GLuint program, GLenum programInterface, const GLchar* name);
+void gl4_3compat_glGetProgramInterfaceiv(void *_glfuncs, GLuint program, GLenum programInterface, GLenum pname, GLint* params);
+void gl4_3compat_glMultiDrawElementsIndirect(void *_glfuncs, GLenum mode, GLenum gltype, const GLvoid* indirect, GLsizei drawcount, GLsizei stride);
+void gl4_3compat_glMultiDrawArraysIndirect(void *_glfuncs, GLenum mode, const GLvoid* indirect, GLsizei drawcount, GLsizei stride);
+void gl4_3compat_glInvalidateSubFramebuffer(void *_glfuncs, GLenum target, GLsizei numAttachments, const GLenum* attachments, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl4_3compat_glInvalidateFramebuffer(void *_glfuncs, GLenum target, GLsizei numAttachments, const GLenum* attachments);
+void gl4_3compat_glInvalidateBufferData(void *_glfuncs, GLuint buffer);
+void gl4_3compat_glInvalidateBufferSubData(void *_glfuncs, GLuint buffer, GLintptr offset, GLsizeiptr length);
+void gl4_3compat_glInvalidateTexImage(void *_glfuncs, GLuint texture, GLint level);
+void gl4_3compat_glInvalidateTexSubImage(void *_glfuncs, GLuint texture, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth);
+void gl4_3compat_glGetInternalformati64v(void *_glfuncs, GLenum target, GLenum internalFormat, GLenum pname, GLsizei bufSize, GLint64* params);
+void gl4_3compat_glGetFramebufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl4_3compat_glFramebufferParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint param);
+void gl4_3compat_glVertexBindingDivisor(void *_glfuncs, GLuint bindingindex, GLuint divisor);
+void gl4_3compat_glVertexAttribBinding(void *_glfuncs, GLuint attribindex, GLuint bindingindex);
+void gl4_3compat_glVertexAttribLFormat(void *_glfuncs, GLuint attribindex, GLint size, GLenum gltype, GLuint relativeoffset);
+void gl4_3compat_glVertexAttribIFormat(void *_glfuncs, GLuint attribindex, GLint size, GLenum gltype, GLuint relativeoffset);
+void gl4_3compat_glVertexAttribFormat(void *_glfuncs, GLuint attribindex, GLint size, GLenum gltype, GLboolean normalized, GLuint relativeoffset);
+void gl4_3compat_glBindVertexBuffer(void *_glfuncs, GLuint bindingindex, GLuint buffer, GLintptr offset, GLsizei stride);
+void gl4_3compat_glTextureView(void *_glfuncs, GLuint texture, GLenum target, GLuint origtexture, GLenum internalFormat, GLuint minlevel, GLuint numlevels, GLuint minlayer, GLuint numlayers);
+void gl4_3compat_glCopyImageSubData(void *_glfuncs, GLuint srcName, GLenum srcTarget, GLint srcLevel, GLint srcX, GLint srcY, GLint srcZ, GLuint dstName, GLenum dstTarget, GLint dstLevel, GLint dstX, GLint dstY, GLint dstZ, GLsizei srcWidth, GLsizei srcHeight, GLsizei srcDepth);
+void gl4_3compat_glDispatchComputeIndirect(void *_glfuncs, GLintptr indirect);
+void gl4_3compat_glDispatchCompute(void *_glfuncs, GLuint num_groups_x, GLuint num_groups_y, GLuint num_groups_z);
+void gl4_3compat_glClearBufferSubData(void *_glfuncs, GLenum target, GLenum internalFormat, GLintptr offset, GLsizeiptr size, GLenum format, GLenum gltype, const GLvoid* data);
+void gl4_3compat_glClearBufferData(void *_glfuncs, GLenum target, GLenum internalFormat, GLenum format, GLenum gltype, const GLvoid* data);
+void gl4_3compat_glTranslatef(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl4_3compat_glTranslated(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl4_3compat_glScalef(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl4_3compat_glScaled(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl4_3compat_glRotatef(void *_glfuncs, GLfloat angle, GLfloat x, GLfloat y, GLfloat z);
+void gl4_3compat_glRotated(void *_glfuncs, GLdouble angle, GLdouble x, GLdouble y, GLdouble z);
+void gl4_3compat_glPushMatrix(void *_glfuncs);
+void gl4_3compat_glPopMatrix(void *_glfuncs);
+void gl4_3compat_glOrtho(void *_glfuncs, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+void gl4_3compat_glMultMatrixd(void *_glfuncs, const GLdouble* m);
+void gl4_3compat_glMultMatrixf(void *_glfuncs, const GLfloat* m);
+void gl4_3compat_glMatrixMode(void *_glfuncs, GLenum mode);
+void gl4_3compat_glLoadMatrixd(void *_glfuncs, const GLdouble* m);
+void gl4_3compat_glLoadMatrixf(void *_glfuncs, const GLfloat* m);
+void gl4_3compat_glLoadIdentity(void *_glfuncs);
+void gl4_3compat_glFrustum(void *_glfuncs, GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+GLboolean gl4_3compat_glIsList(void *_glfuncs, GLuint list);
+void gl4_3compat_glGetTexGeniv(void *_glfuncs, GLenum coord, GLenum pname, GLint* params);
+void gl4_3compat_glGetTexGenfv(void *_glfuncs, GLenum coord, GLenum pname, GLfloat* params);
+void gl4_3compat_glGetTexGendv(void *_glfuncs, GLenum coord, GLenum pname, GLdouble* params);
+void gl4_3compat_glGetTexEnviv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl4_3compat_glGetTexEnvfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl4_3compat_glGetPolygonStipple(void *_glfuncs, GLubyte* mask);
+void gl4_3compat_glGetPixelMapusv(void *_glfuncs, GLenum glmap, GLushort* values);
+void gl4_3compat_glGetPixelMapuiv(void *_glfuncs, GLenum glmap, GLuint* values);
+void gl4_3compat_glGetPixelMapfv(void *_glfuncs, GLenum glmap, GLfloat* values);
+void gl4_3compat_glGetMaterialiv(void *_glfuncs, GLenum face, GLenum pname, GLint* params);
+void gl4_3compat_glGetMaterialfv(void *_glfuncs, GLenum face, GLenum pname, GLfloat* params);
+void gl4_3compat_glGetMapiv(void *_glfuncs, GLenum target, GLenum query, GLint* v);
+void gl4_3compat_glGetMapfv(void *_glfuncs, GLenum target, GLenum query, GLfloat* v);
+void gl4_3compat_glGetMapdv(void *_glfuncs, GLenum target, GLenum query, GLdouble* v);
+void gl4_3compat_glGetLightiv(void *_glfuncs, GLenum light, GLenum pname, GLint* params);
+void gl4_3compat_glGetLightfv(void *_glfuncs, GLenum light, GLenum pname, GLfloat* params);
+void gl4_3compat_glGetClipPlane(void *_glfuncs, GLenum plane, GLdouble* equation);
+void gl4_3compat_glDrawPixels(void *_glfuncs, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl4_3compat_glCopyPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum gltype);
+void gl4_3compat_glPixelMapusv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLushort* values);
+void gl4_3compat_glPixelMapuiv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLuint* values);
+void gl4_3compat_glPixelMapfv(void *_glfuncs, GLenum glmap, GLint mapsize, const GLfloat* values);
+void gl4_3compat_glPixelTransferi(void *_glfuncs, GLenum pname, GLint param);
+void gl4_3compat_glPixelTransferf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl4_3compat_glPixelZoom(void *_glfuncs, GLfloat xfactor, GLfloat yfactor);
+void gl4_3compat_glAlphaFunc(void *_glfuncs, GLenum glfunc, GLfloat ref);
+void gl4_3compat_glEvalPoint2(void *_glfuncs, GLint i, GLint j);
+void gl4_3compat_glEvalMesh2(void *_glfuncs, GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2);
+void gl4_3compat_glEvalPoint1(void *_glfuncs, GLint i);
+void gl4_3compat_glEvalMesh1(void *_glfuncs, GLenum mode, GLint i1, GLint i2);
+void gl4_3compat_glEvalCoord2fv(void *_glfuncs, const GLfloat* u);
+void gl4_3compat_glEvalCoord2f(void *_glfuncs, GLfloat u, GLfloat v);
+void gl4_3compat_glEvalCoord2dv(void *_glfuncs, const GLdouble* u);
+void gl4_3compat_glEvalCoord2d(void *_glfuncs, GLdouble u, GLdouble v);
+void gl4_3compat_glEvalCoord1fv(void *_glfuncs, const GLfloat* u);
+void gl4_3compat_glEvalCoord1f(void *_glfuncs, GLfloat u);
+void gl4_3compat_glEvalCoord1dv(void *_glfuncs, const GLdouble* u);
+void gl4_3compat_glEvalCoord1d(void *_glfuncs, GLdouble u);
+void gl4_3compat_glMapGrid2f(void *_glfuncs, GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2);
+void gl4_3compat_glMapGrid2d(void *_glfuncs, GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2);
+void gl4_3compat_glMapGrid1f(void *_glfuncs, GLint un, GLfloat u1, GLfloat u2);
+void gl4_3compat_glMapGrid1d(void *_glfuncs, GLint un, GLdouble u1, GLdouble u2);
+void gl4_3compat_glMap2f(void *_glfuncs, GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, const GLfloat* points);
+void gl4_3compat_glMap2d(void *_glfuncs, GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, const GLdouble* points);
+void gl4_3compat_glMap1f(void *_glfuncs, GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, const GLfloat* points);
+void gl4_3compat_glMap1d(void *_glfuncs, GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, const GLdouble* points);
+void gl4_3compat_glPushAttrib(void *_glfuncs, GLbitfield mask);
+void gl4_3compat_glPopAttrib(void *_glfuncs);
+void gl4_3compat_glAccum(void *_glfuncs, GLenum op, GLfloat value);
+void gl4_3compat_glIndexMask(void *_glfuncs, GLuint mask);
+void gl4_3compat_glClearIndex(void *_glfuncs, GLfloat c);
+void gl4_3compat_glClearAccum(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl4_3compat_glPushName(void *_glfuncs, GLuint name);
+void gl4_3compat_glPopName(void *_glfuncs);
+void gl4_3compat_glPassThrough(void *_glfuncs, GLfloat token);
+void gl4_3compat_glLoadName(void *_glfuncs, GLuint name);
+void gl4_3compat_glInitNames(void *_glfuncs);
+GLint gl4_3compat_glRenderMode(void *_glfuncs, GLenum mode);
+void gl4_3compat_glSelectBuffer(void *_glfuncs, GLsizei size, GLuint* buffer);
+void gl4_3compat_glFeedbackBuffer(void *_glfuncs, GLsizei size, GLenum gltype, GLfloat* buffer);
+void gl4_3compat_glTexGeniv(void *_glfuncs, GLenum coord, GLenum pname, const GLint* params);
+void gl4_3compat_glTexGeni(void *_glfuncs, GLenum coord, GLenum pname, GLint param);
+void gl4_3compat_glTexGenfv(void *_glfuncs, GLenum coord, GLenum pname, const GLfloat* params);
+void gl4_3compat_glTexGenf(void *_glfuncs, GLenum coord, GLenum pname, GLfloat param);
+void gl4_3compat_glTexGendv(void *_glfuncs, GLenum coord, GLenum pname, const GLdouble* params);
+void gl4_3compat_glTexGend(void *_glfuncs, GLenum coord, GLenum pname, GLdouble param);
+void gl4_3compat_glTexEnviv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl4_3compat_glTexEnvi(void *_glfuncs, GLenum target, GLenum pname, GLint param);
+void gl4_3compat_glTexEnvfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl4_3compat_glTexEnvf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param);
+void gl4_3compat_glShadeModel(void *_glfuncs, GLenum mode);
+void gl4_3compat_glPolygonStipple(void *_glfuncs, const GLubyte* mask);
+void gl4_3compat_glMaterialiv(void *_glfuncs, GLenum face, GLenum pname, const GLint* params);
+void gl4_3compat_glMateriali(void *_glfuncs, GLenum face, GLenum pname, GLint param);
+void gl4_3compat_glMaterialfv(void *_glfuncs, GLenum face, GLenum pname, const GLfloat* params);
+void gl4_3compat_glMaterialf(void *_glfuncs, GLenum face, GLenum pname, GLfloat param);
+void gl4_3compat_glLineStipple(void *_glfuncs, GLint factor, GLushort pattern);
+void gl4_3compat_glLightModeliv(void *_glfuncs, GLenum pname, const GLint* params);
+void gl4_3compat_glLightModeli(void *_glfuncs, GLenum pname, GLint param);
+void gl4_3compat_glLightModelfv(void *_glfuncs, GLenum pname, const GLfloat* params);
+void gl4_3compat_glLightModelf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl4_3compat_glLightiv(void *_glfuncs, GLenum light, GLenum pname, const GLint* params);
+void gl4_3compat_glLighti(void *_glfuncs, GLenum light, GLenum pname, GLint param);
+void gl4_3compat_glLightfv(void *_glfuncs, GLenum light, GLenum pname, const GLfloat* params);
+void gl4_3compat_glLightf(void *_glfuncs, GLenum light, GLenum pname, GLfloat param);
+void gl4_3compat_glFogiv(void *_glfuncs, GLenum pname, const GLint* params);
+void gl4_3compat_glFogi(void *_glfuncs, GLenum pname, GLint param);
+void gl4_3compat_glFogfv(void *_glfuncs, GLenum pname, const GLfloat* params);
+void gl4_3compat_glFogf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl4_3compat_glColorMaterial(void *_glfuncs, GLenum face, GLenum mode);
+void gl4_3compat_glClipPlane(void *_glfuncs, GLenum plane, const GLdouble* equation);
+void gl4_3compat_glVertex4sv(void *_glfuncs, const GLshort* v);
+void gl4_3compat_glVertex4s(void *_glfuncs, GLshort x, GLshort y, GLshort z, GLshort w);
+void gl4_3compat_glVertex4iv(void *_glfuncs, const GLint* v);
+void gl4_3compat_glVertex4i(void *_glfuncs, GLint x, GLint y, GLint z, GLint w);
+void gl4_3compat_glVertex4fv(void *_glfuncs, const GLfloat* v);
+void gl4_3compat_glVertex4f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+void gl4_3compat_glVertex4dv(void *_glfuncs, const GLdouble* v);
+void gl4_3compat_glVertex4d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+void gl4_3compat_glVertex3sv(void *_glfuncs, const GLshort* v);
+void gl4_3compat_glVertex3s(void *_glfuncs, GLshort x, GLshort y, GLshort z);
+void gl4_3compat_glVertex3iv(void *_glfuncs, const GLint* v);
+void gl4_3compat_glVertex3i(void *_glfuncs, GLint x, GLint y, GLint z);
+void gl4_3compat_glVertex3fv(void *_glfuncs, const GLfloat* v);
+void gl4_3compat_glVertex3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl4_3compat_glVertex3dv(void *_glfuncs, const GLdouble* v);
+void gl4_3compat_glVertex3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl4_3compat_glVertex2sv(void *_glfuncs, const GLshort* v);
+void gl4_3compat_glVertex2s(void *_glfuncs, GLshort x, GLshort y);
+void gl4_3compat_glVertex2iv(void *_glfuncs, const GLint* v);
+void gl4_3compat_glVertex2i(void *_glfuncs, GLint x, GLint y);
+void gl4_3compat_glVertex2fv(void *_glfuncs, const GLfloat* v);
+void gl4_3compat_glVertex2f(void *_glfuncs, GLfloat x, GLfloat y);
+void gl4_3compat_glVertex2dv(void *_glfuncs, const GLdouble* v);
+void gl4_3compat_glVertex2d(void *_glfuncs, GLdouble x, GLdouble y);
+void gl4_3compat_glTexCoord4sv(void *_glfuncs, const GLshort* v);
+void gl4_3compat_glTexCoord4s(void *_glfuncs, GLshort s, GLshort t, GLshort r, GLshort q);
+void gl4_3compat_glTexCoord4iv(void *_glfuncs, const GLint* v);
+void gl4_3compat_glTexCoord4i(void *_glfuncs, GLint s, GLint t, GLint r, GLint q);
+void gl4_3compat_glTexCoord4fv(void *_glfuncs, const GLfloat* v);
+void gl4_3compat_glTexCoord4f(void *_glfuncs, GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+void gl4_3compat_glTexCoord4dv(void *_glfuncs, const GLdouble* v);
+void gl4_3compat_glTexCoord4d(void *_glfuncs, GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+void gl4_3compat_glTexCoord3sv(void *_glfuncs, const GLshort* v);
+void gl4_3compat_glTexCoord3s(void *_glfuncs, GLshort s, GLshort t, GLshort r);
+void gl4_3compat_glTexCoord3iv(void *_glfuncs, const GLint* v);
+void gl4_3compat_glTexCoord3i(void *_glfuncs, GLint s, GLint t, GLint r);
+void gl4_3compat_glTexCoord3fv(void *_glfuncs, const GLfloat* v);
+void gl4_3compat_glTexCoord3f(void *_glfuncs, GLfloat s, GLfloat t, GLfloat r);
+void gl4_3compat_glTexCoord3dv(void *_glfuncs, const GLdouble* v);
+void gl4_3compat_glTexCoord3d(void *_glfuncs, GLdouble s, GLdouble t, GLdouble r);
+void gl4_3compat_glTexCoord2sv(void *_glfuncs, const GLshort* v);
+void gl4_3compat_glTexCoord2s(void *_glfuncs, GLshort s, GLshort t);
+void gl4_3compat_glTexCoord2iv(void *_glfuncs, const GLint* v);
+void gl4_3compat_glTexCoord2i(void *_glfuncs, GLint s, GLint t);
+void gl4_3compat_glTexCoord2fv(void *_glfuncs, const GLfloat* v);
+void gl4_3compat_glTexCoord2f(void *_glfuncs, GLfloat s, GLfloat t);
+void gl4_3compat_glTexCoord2dv(void *_glfuncs, const GLdouble* v);
+void gl4_3compat_glTexCoord2d(void *_glfuncs, GLdouble s, GLdouble t);
+void gl4_3compat_glTexCoord1sv(void *_glfuncs, const GLshort* v);
+void gl4_3compat_glTexCoord1s(void *_glfuncs, GLshort s);
+void gl4_3compat_glTexCoord1iv(void *_glfuncs, const GLint* v);
+void gl4_3compat_glTexCoord1i(void *_glfuncs, GLint s);
+void gl4_3compat_glTexCoord1fv(void *_glfuncs, const GLfloat* v);
+void gl4_3compat_glTexCoord1f(void *_glfuncs, GLfloat s);
+void gl4_3compat_glTexCoord1dv(void *_glfuncs, const GLdouble* v);
+void gl4_3compat_glTexCoord1d(void *_glfuncs, GLdouble s);
+void gl4_3compat_glRectsv(void *_glfuncs, const GLshort* v1, const GLshort* v2);
+void gl4_3compat_glRects(void *_glfuncs, GLshort x1, GLshort y1, GLshort x2, GLshort y2);
+void gl4_3compat_glRectiv(void *_glfuncs, const GLint* v1, const GLint* v2);
+void gl4_3compat_glRecti(void *_glfuncs, GLint x1, GLint y1, GLint x2, GLint y2);
+void gl4_3compat_glRectfv(void *_glfuncs, const GLfloat* v1, const GLfloat* v2);
+void gl4_3compat_glRectf(void *_glfuncs, GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2);
+void gl4_3compat_glRectdv(void *_glfuncs, const GLdouble* v1, const GLdouble* v2);
+void gl4_3compat_glRectd(void *_glfuncs, GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2);
+void gl4_3compat_glRasterPos4sv(void *_glfuncs, const GLshort* v);
+void gl4_3compat_glRasterPos4s(void *_glfuncs, GLshort x, GLshort y, GLshort z, GLshort w);
+void gl4_3compat_glRasterPos4iv(void *_glfuncs, const GLint* v);
+void gl4_3compat_glRasterPos4i(void *_glfuncs, GLint x, GLint y, GLint z, GLint w);
+void gl4_3compat_glRasterPos4fv(void *_glfuncs, const GLfloat* v);
+void gl4_3compat_glRasterPos4f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+void gl4_3compat_glRasterPos4dv(void *_glfuncs, const GLdouble* v);
+void gl4_3compat_glRasterPos4d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+void gl4_3compat_glRasterPos3sv(void *_glfuncs, const GLshort* v);
+void gl4_3compat_glRasterPos3s(void *_glfuncs, GLshort x, GLshort y, GLshort z);
+void gl4_3compat_glRasterPos3iv(void *_glfuncs, const GLint* v);
+void gl4_3compat_glRasterPos3i(void *_glfuncs, GLint x, GLint y, GLint z);
+void gl4_3compat_glRasterPos3fv(void *_glfuncs, const GLfloat* v);
+void gl4_3compat_glRasterPos3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl4_3compat_glRasterPos3dv(void *_glfuncs, const GLdouble* v);
+void gl4_3compat_glRasterPos3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl4_3compat_glRasterPos2sv(void *_glfuncs, const GLshort* v);
+void gl4_3compat_glRasterPos2s(void *_glfuncs, GLshort x, GLshort y);
+void gl4_3compat_glRasterPos2iv(void *_glfuncs, const GLint* v);
+void gl4_3compat_glRasterPos2i(void *_glfuncs, GLint x, GLint y);
+void gl4_3compat_glRasterPos2fv(void *_glfuncs, const GLfloat* v);
+void gl4_3compat_glRasterPos2f(void *_glfuncs, GLfloat x, GLfloat y);
+void gl4_3compat_glRasterPos2dv(void *_glfuncs, const GLdouble* v);
+void gl4_3compat_glRasterPos2d(void *_glfuncs, GLdouble x, GLdouble y);
+void gl4_3compat_glNormal3sv(void *_glfuncs, const GLshort* v);
+void gl4_3compat_glNormal3s(void *_glfuncs, GLshort nx, GLshort ny, GLshort nz);
+void gl4_3compat_glNormal3iv(void *_glfuncs, const GLint* v);
+void gl4_3compat_glNormal3i(void *_glfuncs, GLint nx, GLint ny, GLint nz);
+void gl4_3compat_glNormal3fv(void *_glfuncs, const GLfloat* v);
+void gl4_3compat_glNormal3f(void *_glfuncs, GLfloat nx, GLfloat ny, GLfloat nz);
+void gl4_3compat_glNormal3dv(void *_glfuncs, const GLdouble* v);
+void gl4_3compat_glNormal3d(void *_glfuncs, GLdouble nx, GLdouble ny, GLdouble nz);
+void gl4_3compat_glNormal3bv(void *_glfuncs, const GLbyte* v);
+void gl4_3compat_glNormal3b(void *_glfuncs, GLbyte nx, GLbyte ny, GLbyte nz);
+void gl4_3compat_glIndexsv(void *_glfuncs, const GLshort* c);
+void gl4_3compat_glIndexs(void *_glfuncs, GLshort c);
+void gl4_3compat_glIndexiv(void *_glfuncs, const GLint* c);
+void gl4_3compat_glIndexi(void *_glfuncs, GLint c);
+void gl4_3compat_glIndexfv(void *_glfuncs, const GLfloat* c);
+void gl4_3compat_glIndexf(void *_glfuncs, GLfloat c);
+void gl4_3compat_glIndexdv(void *_glfuncs, const GLdouble* c);
+void gl4_3compat_glIndexd(void *_glfuncs, GLdouble c);
+void gl4_3compat_glEnd(void *_glfuncs);
+void gl4_3compat_glEdgeFlagv(void *_glfuncs, const GLboolean* flag);
+void gl4_3compat_glEdgeFlag(void *_glfuncs, GLboolean flag);
+void gl4_3compat_glColor4usv(void *_glfuncs, const GLushort* v);
+void gl4_3compat_glColor4us(void *_glfuncs, GLushort red, GLushort green, GLushort blue, GLushort alpha);
+void gl4_3compat_glColor4uiv(void *_glfuncs, const GLuint* v);
+void gl4_3compat_glColor4ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue, GLuint alpha);
+void gl4_3compat_glColor4ubv(void *_glfuncs, const GLubyte* v);
+void gl4_3compat_glColor4ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha);
+void gl4_3compat_glColor4sv(void *_glfuncs, const GLshort* v);
+void gl4_3compat_glColor4s(void *_glfuncs, GLshort red, GLshort green, GLshort blue, GLshort alpha);
+void gl4_3compat_glColor4iv(void *_glfuncs, const GLint* v);
+void gl4_3compat_glColor4i(void *_glfuncs, GLint red, GLint green, GLint blue, GLint alpha);
+void gl4_3compat_glColor4fv(void *_glfuncs, const GLfloat* v);
+void gl4_3compat_glColor4f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl4_3compat_glColor4dv(void *_glfuncs, const GLdouble* v);
+void gl4_3compat_glColor4d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha);
+void gl4_3compat_glColor4bv(void *_glfuncs, const GLbyte* v);
+void gl4_3compat_glColor4b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha);
+void gl4_3compat_glColor3usv(void *_glfuncs, const GLushort* v);
+void gl4_3compat_glColor3us(void *_glfuncs, GLushort red, GLushort green, GLushort blue);
+void gl4_3compat_glColor3uiv(void *_glfuncs, const GLuint* v);
+void gl4_3compat_glColor3ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue);
+void gl4_3compat_glColor3ubv(void *_glfuncs, const GLubyte* v);
+void gl4_3compat_glColor3ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue);
+void gl4_3compat_glColor3sv(void *_glfuncs, const GLshort* v);
+void gl4_3compat_glColor3s(void *_glfuncs, GLshort red, GLshort green, GLshort blue);
+void gl4_3compat_glColor3iv(void *_glfuncs, const GLint* v);
+void gl4_3compat_glColor3i(void *_glfuncs, GLint red, GLint green, GLint blue);
+void gl4_3compat_glColor3fv(void *_glfuncs, const GLfloat* v);
+void gl4_3compat_glColor3f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue);
+void gl4_3compat_glColor3dv(void *_glfuncs, const GLdouble* v);
+void gl4_3compat_glColor3d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue);
+void gl4_3compat_glColor3bv(void *_glfuncs, const GLbyte* v);
+void gl4_3compat_glColor3b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue);
+void gl4_3compat_glBitmap(void *_glfuncs, GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, const GLubyte* bitmap);
+void gl4_3compat_glBegin(void *_glfuncs, GLenum mode);
+void gl4_3compat_glListBase(void *_glfuncs, GLuint base);
+GLuint gl4_3compat_glGenLists(void *_glfuncs, GLsizei range_);
+void gl4_3compat_glDeleteLists(void *_glfuncs, GLuint list, GLsizei range_);
+void gl4_3compat_glCallLists(void *_glfuncs, GLsizei n, GLenum gltype, const GLvoid* lists);
+void gl4_3compat_glCallList(void *_glfuncs, GLuint list);
+void gl4_3compat_glEndList(void *_glfuncs);
+void gl4_3compat_glNewList(void *_glfuncs, GLuint list, GLenum mode);
+void gl4_3compat_glPushClientAttrib(void *_glfuncs, GLbitfield mask);
+void gl4_3compat_glPopClientAttrib(void *_glfuncs);
+void gl4_3compat_glPrioritizeTextures(void *_glfuncs, GLsizei n, const GLuint* textures, const GLfloat* priorities);
+GLboolean gl4_3compat_glAreTexturesResident(void *_glfuncs, GLsizei n, const GLuint* textures, GLboolean* residences);
+void gl4_3compat_glVertexPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl4_3compat_glTexCoordPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl4_3compat_glNormalPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl4_3compat_glInterleavedArrays(void *_glfuncs, GLenum format, GLsizei stride, const GLvoid* pointer);
+void gl4_3compat_glIndexPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl4_3compat_glEnableClientState(void *_glfuncs, GLenum array);
+void gl4_3compat_glEdgeFlagPointer(void *_glfuncs, GLsizei stride, const GLvoid* pointer);
+void gl4_3compat_glDisableClientState(void *_glfuncs, GLenum array);
+void gl4_3compat_glColorPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl4_3compat_glArrayElement(void *_glfuncs, GLint i);
+void gl4_3compat_glResetMinmax(void *_glfuncs, GLenum target);
+void gl4_3compat_glResetHistogram(void *_glfuncs, GLenum target);
+void gl4_3compat_glMinmax(void *_glfuncs, GLenum target, GLenum internalFormat, GLboolean sink);
+void gl4_3compat_glHistogram(void *_glfuncs, GLenum target, GLsizei width, GLenum internalFormat, GLboolean sink);
+void gl4_3compat_glGetMinmaxParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl4_3compat_glGetMinmaxParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl4_3compat_glGetMinmax(void *_glfuncs, GLenum target, GLboolean reset, GLenum format, GLenum gltype, GLvoid* values);
+void gl4_3compat_glGetHistogramParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl4_3compat_glGetHistogramParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl4_3compat_glGetHistogram(void *_glfuncs, GLenum target, GLboolean reset, GLenum format, GLenum gltype, GLvoid* values);
+void gl4_3compat_glSeparableFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* row, const GLvoid* column);
+void gl4_3compat_glGetSeparableFilter(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* row, GLvoid* column, GLvoid* span);
+void gl4_3compat_glGetConvolutionParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl4_3compat_glGetConvolutionParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl4_3compat_glGetConvolutionFilter(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* image);
+void gl4_3compat_glCopyConvolutionFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl4_3compat_glCopyConvolutionFilter1D(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width);
+void gl4_3compat_glConvolutionParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl4_3compat_glConvolutionParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint params);
+void gl4_3compat_glConvolutionParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl4_3compat_glConvolutionParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat params);
+void gl4_3compat_glConvolutionFilter2D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* image);
+void gl4_3compat_glConvolutionFilter1D(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLenum format, GLenum gltype, const GLvoid* image);
+void gl4_3compat_glCopyColorSubTable(void *_glfuncs, GLenum target, GLsizei start, GLint x, GLint y, GLsizei width);
+void gl4_3compat_glColorSubTable(void *_glfuncs, GLenum target, GLsizei start, GLsizei count, GLenum format, GLenum gltype, const GLvoid* data);
+void gl4_3compat_glGetColorTableParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl4_3compat_glGetColorTableParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl4_3compat_glGetColorTable(void *_glfuncs, GLenum target, GLenum format, GLenum gltype, GLvoid* table);
+void gl4_3compat_glCopyColorTable(void *_glfuncs, GLenum target, GLenum internalFormat, GLint x, GLint y, GLsizei width);
+void gl4_3compat_glColorTableParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl4_3compat_glColorTableParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl4_3compat_glColorTable(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLenum format, GLenum gltype, const GLvoid* table);
+void gl4_3compat_glMultTransposeMatrixd(void *_glfuncs, const GLdouble* m);
+void gl4_3compat_glMultTransposeMatrixf(void *_glfuncs, const GLfloat* m);
+void gl4_3compat_glLoadTransposeMatrixd(void *_glfuncs, const GLdouble* m);
+void gl4_3compat_glLoadTransposeMatrixf(void *_glfuncs, const GLfloat* m);
+void gl4_3compat_glMultiTexCoord4sv(void *_glfuncs, GLenum target, const GLshort* v);
+void gl4_3compat_glMultiTexCoord4s(void *_glfuncs, GLenum target, GLshort s, GLshort t, GLshort r, GLshort q);
+void gl4_3compat_glMultiTexCoord4iv(void *_glfuncs, GLenum target, const GLint* v);
+void gl4_3compat_glMultiTexCoord4i(void *_glfuncs, GLenum target, GLint s, GLint t, GLint r, GLint q);
+void gl4_3compat_glMultiTexCoord4fv(void *_glfuncs, GLenum target, const GLfloat* v);
+void gl4_3compat_glMultiTexCoord4f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+void gl4_3compat_glMultiTexCoord4dv(void *_glfuncs, GLenum target, const GLdouble* v);
+void gl4_3compat_glMultiTexCoord4d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+void gl4_3compat_glMultiTexCoord3sv(void *_glfuncs, GLenum target, const GLshort* v);
+void gl4_3compat_glMultiTexCoord3s(void *_glfuncs, GLenum target, GLshort s, GLshort t, GLshort r);
+void gl4_3compat_glMultiTexCoord3iv(void *_glfuncs, GLenum target, const GLint* v);
+void gl4_3compat_glMultiTexCoord3i(void *_glfuncs, GLenum target, GLint s, GLint t, GLint r);
+void gl4_3compat_glMultiTexCoord3fv(void *_glfuncs, GLenum target, const GLfloat* v);
+void gl4_3compat_glMultiTexCoord3f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t, GLfloat r);
+void gl4_3compat_glMultiTexCoord3dv(void *_glfuncs, GLenum target, const GLdouble* v);
+void gl4_3compat_glMultiTexCoord3d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t, GLdouble r);
+void gl4_3compat_glMultiTexCoord2sv(void *_glfuncs, GLenum target, const GLshort* v);
+void gl4_3compat_glMultiTexCoord2s(void *_glfuncs, GLenum target, GLshort s, GLshort t);
+void gl4_3compat_glMultiTexCoord2iv(void *_glfuncs, GLenum target, const GLint* v);
+void gl4_3compat_glMultiTexCoord2i(void *_glfuncs, GLenum target, GLint s, GLint t);
+void gl4_3compat_glMultiTexCoord2fv(void *_glfuncs, GLenum target, const GLfloat* v);
+void gl4_3compat_glMultiTexCoord2f(void *_glfuncs, GLenum target, GLfloat s, GLfloat t);
+void gl4_3compat_glMultiTexCoord2dv(void *_glfuncs, GLenum target, const GLdouble* v);
+void gl4_3compat_glMultiTexCoord2d(void *_glfuncs, GLenum target, GLdouble s, GLdouble t);
+void gl4_3compat_glMultiTexCoord1sv(void *_glfuncs, GLenum target, const GLshort* v);
+void gl4_3compat_glMultiTexCoord1s(void *_glfuncs, GLenum target, GLshort s);
+void gl4_3compat_glMultiTexCoord1iv(void *_glfuncs, GLenum target, const GLint* v);
+void gl4_3compat_glMultiTexCoord1i(void *_glfuncs, GLenum target, GLint s);
+void gl4_3compat_glMultiTexCoord1fv(void *_glfuncs, GLenum target, const GLfloat* v);
+void gl4_3compat_glMultiTexCoord1f(void *_glfuncs, GLenum target, GLfloat s);
+void gl4_3compat_glMultiTexCoord1dv(void *_glfuncs, GLenum target, const GLdouble* v);
+void gl4_3compat_glMultiTexCoord1d(void *_glfuncs, GLenum target, GLdouble s);
+void gl4_3compat_glClientActiveTexture(void *_glfuncs, GLenum texture);
+void gl4_3compat_glWindowPos3sv(void *_glfuncs, const GLshort* v);
+void gl4_3compat_glWindowPos3s(void *_glfuncs, GLshort x, GLshort y, GLshort z);
+void gl4_3compat_glWindowPos3iv(void *_glfuncs, const GLint* v);
+void gl4_3compat_glWindowPos3i(void *_glfuncs, GLint x, GLint y, GLint z);
+void gl4_3compat_glWindowPos3fv(void *_glfuncs, const GLfloat* v);
+void gl4_3compat_glWindowPos3f(void *_glfuncs, GLfloat x, GLfloat y, GLfloat z);
+void gl4_3compat_glWindowPos3dv(void *_glfuncs, const GLdouble* v);
+void gl4_3compat_glWindowPos3d(void *_glfuncs, GLdouble x, GLdouble y, GLdouble z);
+void gl4_3compat_glWindowPos2sv(void *_glfuncs, const GLshort* v);
+void gl4_3compat_glWindowPos2s(void *_glfuncs, GLshort x, GLshort y);
+void gl4_3compat_glWindowPos2iv(void *_glfuncs, const GLint* v);
+void gl4_3compat_glWindowPos2i(void *_glfuncs, GLint x, GLint y);
+void gl4_3compat_glWindowPos2fv(void *_glfuncs, const GLfloat* v);
+void gl4_3compat_glWindowPos2f(void *_glfuncs, GLfloat x, GLfloat y);
+void gl4_3compat_glWindowPos2dv(void *_glfuncs, const GLdouble* v);
+void gl4_3compat_glWindowPos2d(void *_glfuncs, GLdouble x, GLdouble y);
+void gl4_3compat_glSecondaryColorPointer(void *_glfuncs, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl4_3compat_glSecondaryColor3usv(void *_glfuncs, const GLushort* v);
+void gl4_3compat_glSecondaryColor3us(void *_glfuncs, GLushort red, GLushort green, GLushort blue);
+void gl4_3compat_glSecondaryColor3uiv(void *_glfuncs, const GLuint* v);
+void gl4_3compat_glSecondaryColor3ui(void *_glfuncs, GLuint red, GLuint green, GLuint blue);
+void gl4_3compat_glSecondaryColor3ubv(void *_glfuncs, const GLubyte* v);
+void gl4_3compat_glSecondaryColor3ub(void *_glfuncs, GLubyte red, GLubyte green, GLubyte blue);
+void gl4_3compat_glSecondaryColor3sv(void *_glfuncs, const GLshort* v);
+void gl4_3compat_glSecondaryColor3s(void *_glfuncs, GLshort red, GLshort green, GLshort blue);
+void gl4_3compat_glSecondaryColor3iv(void *_glfuncs, const GLint* v);
+void gl4_3compat_glSecondaryColor3i(void *_glfuncs, GLint red, GLint green, GLint blue);
+void gl4_3compat_glSecondaryColor3fv(void *_glfuncs, const GLfloat* v);
+void gl4_3compat_glSecondaryColor3f(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue);
+void gl4_3compat_glSecondaryColor3dv(void *_glfuncs, const GLdouble* v);
+void gl4_3compat_glSecondaryColor3d(void *_glfuncs, GLdouble red, GLdouble green, GLdouble blue);
+void gl4_3compat_glSecondaryColor3bv(void *_glfuncs, const GLbyte* v);
+void gl4_3compat_glSecondaryColor3b(void *_glfuncs, GLbyte red, GLbyte green, GLbyte blue);
+void gl4_3compat_glFogCoordPointer(void *_glfuncs, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl4_3compat_glFogCoorddv(void *_glfuncs, const GLdouble* coord);
+void gl4_3compat_glFogCoordd(void *_glfuncs, GLdouble coord);
+void gl4_3compat_glFogCoordfv(void *_glfuncs, const GLfloat* coord);
+void gl4_3compat_glFogCoordf(void *_glfuncs, GLfloat coord);
+void gl4_3compat_glVertexAttrib4usv(void *_glfuncs, GLuint index, const GLushort* v);
+void gl4_3compat_glVertexAttrib4uiv(void *_glfuncs, GLuint index, const GLuint* v);
+void gl4_3compat_glVertexAttrib4ubv(void *_glfuncs, GLuint index, const GLubyte* v);
+void gl4_3compat_glVertexAttrib4sv(void *_glfuncs, GLuint index, const GLshort* v);
+void gl4_3compat_glVertexAttrib4s(void *_glfuncs, GLuint index, GLshort x, GLshort y, GLshort z, GLshort w);
+void gl4_3compat_glVertexAttrib4iv(void *_glfuncs, GLuint index, const GLint* v);
+void gl4_3compat_glVertexAttrib4fv(void *_glfuncs, GLuint index, const GLfloat* v);
+void gl4_3compat_glVertexAttrib4f(void *_glfuncs, GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+void gl4_3compat_glVertexAttrib4dv(void *_glfuncs, GLuint index, const GLdouble* v);
+void gl4_3compat_glVertexAttrib4d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+void gl4_3compat_glVertexAttrib4bv(void *_glfuncs, GLuint index, const GLbyte* v);
+void gl4_3compat_glVertexAttrib4Nusv(void *_glfuncs, GLuint index, const GLushort* v);
+void gl4_3compat_glVertexAttrib4Nuiv(void *_glfuncs, GLuint index, const GLuint* v);
+void gl4_3compat_glVertexAttrib4Nubv(void *_glfuncs, GLuint index, const GLubyte* v);
+void gl4_3compat_glVertexAttrib4Nub(void *_glfuncs, GLuint index, GLubyte x, GLubyte y, GLubyte z, GLubyte w);
+void gl4_3compat_glVertexAttrib4Nsv(void *_glfuncs, GLuint index, const GLshort* v);
+void gl4_3compat_glVertexAttrib4Niv(void *_glfuncs, GLuint index, const GLint* v);
+void gl4_3compat_glVertexAttrib4Nbv(void *_glfuncs, GLuint index, const GLbyte* v);
+void gl4_3compat_glVertexAttrib3sv(void *_glfuncs, GLuint index, const GLshort* v);
+void gl4_3compat_glVertexAttrib3s(void *_glfuncs, GLuint index, GLshort x, GLshort y, GLshort z);
+void gl4_3compat_glVertexAttrib3fv(void *_glfuncs, GLuint index, const GLfloat* v);
+void gl4_3compat_glVertexAttrib3f(void *_glfuncs, GLuint index, GLfloat x, GLfloat y, GLfloat z);
+void gl4_3compat_glVertexAttrib3dv(void *_glfuncs, GLuint index, const GLdouble* v);
+void gl4_3compat_glVertexAttrib3d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y, GLdouble z);
+void gl4_3compat_glVertexAttrib2sv(void *_glfuncs, GLuint index, const GLshort* v);
+void gl4_3compat_glVertexAttrib2s(void *_glfuncs, GLuint index, GLshort x, GLshort y);
+void gl4_3compat_glVertexAttrib2fv(void *_glfuncs, GLuint index, const GLfloat* v);
+void gl4_3compat_glVertexAttrib2f(void *_glfuncs, GLuint index, GLfloat x, GLfloat y);
+void gl4_3compat_glVertexAttrib2dv(void *_glfuncs, GLuint index, const GLdouble* v);
+void gl4_3compat_glVertexAttrib2d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y);
+void gl4_3compat_glVertexAttrib1sv(void *_glfuncs, GLuint index, const GLshort* v);
+void gl4_3compat_glVertexAttrib1s(void *_glfuncs, GLuint index, GLshort x);
+void gl4_3compat_glVertexAttrib1fv(void *_glfuncs, GLuint index, const GLfloat* v);
+void gl4_3compat_glVertexAttrib1f(void *_glfuncs, GLuint index, GLfloat x);
+void gl4_3compat_glVertexAttrib1dv(void *_glfuncs, GLuint index, const GLdouble* v);
+void gl4_3compat_glVertexAttrib1d(void *_glfuncs, GLuint index, GLdouble x);
+void gl4_3compat_glVertexAttribI4usv(void *_glfuncs, GLuint index, const GLushort* v);
+void gl4_3compat_glVertexAttribI4ubv(void *_glfuncs, GLuint index, const GLubyte* v);
+void gl4_3compat_glVertexAttribI4sv(void *_glfuncs, GLuint index, const GLshort* v);
+void gl4_3compat_glVertexAttribI4bv(void *_glfuncs, GLuint index, const GLbyte* v);
+void gl4_3compat_glVertexAttribI4uiv(void *_glfuncs, GLuint index, const GLuint* v);
+void gl4_3compat_glVertexAttribI3uiv(void *_glfuncs, GLuint index, const GLuint* v);
+void gl4_3compat_glVertexAttribI2uiv(void *_glfuncs, GLuint index, const GLuint* v);
+void gl4_3compat_glVertexAttribI1uiv(void *_glfuncs, GLuint index, const GLuint* v);
+void gl4_3compat_glVertexAttribI4iv(void *_glfuncs, GLuint index, const GLint* v);
+void gl4_3compat_glVertexAttribI3iv(void *_glfuncs, GLuint index, const GLint* v);
+void gl4_3compat_glVertexAttribI2iv(void *_glfuncs, GLuint index, const GLint* v);
+void gl4_3compat_glVertexAttribI1iv(void *_glfuncs, GLuint index, const GLint* v);
+void gl4_3compat_glVertexAttribI4ui(void *_glfuncs, GLuint index, GLuint x, GLuint y, GLuint z, GLuint w);
+void gl4_3compat_glVertexAttribI3ui(void *_glfuncs, GLuint index, GLuint x, GLuint y, GLuint z);
+void gl4_3compat_glVertexAttribI2ui(void *_glfuncs, GLuint index, GLuint x, GLuint y);
+void gl4_3compat_glVertexAttribI1ui(void *_glfuncs, GLuint index, GLuint x);
+void gl4_3compat_glVertexAttribI4i(void *_glfuncs, GLuint index, GLint x, GLint y, GLint z, GLint w);
+void gl4_3compat_glVertexAttribI3i(void *_glfuncs, GLuint index, GLint x, GLint y, GLint z);
+void gl4_3compat_glVertexAttribI2i(void *_glfuncs, GLuint index, GLint x, GLint y);
+void gl4_3compat_glVertexAttribI1i(void *_glfuncs, GLuint index, GLint x);
+
+
+#ifdef __cplusplus
+} // extern "C"
+#endif
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.3compat/gl.go b/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.3compat/gl.go
new file mode 100644
index 000000000..4ee8a9ef6
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.3compat/gl.go
@@ -0,0 +1,9845 @@
+// ** file automatically generated by glgen -- do not edit manually **
+
+package GL
+
+// #cgo CXXFLAGS: -std=c++0x -pedantic-errors -Wall -fno-strict-aliasing
+// #cgo LDFLAGS: -lstdc++
+// #cgo pkg-config: Qt5Core Qt5OpenGL
+//
+// #include "funcs.h"
+//
+// void free(void*);
+//
+import "C"
+
+import (
+ "fmt"
+ "reflect"
+ "unsafe"
+
+ "gopkg.in/qml.v1/gl/glbase"
+)
+
+// API returns a value that offers methods matching the OpenGL version 4.3 API.
+//
+// The returned API must not be used after the provided OpenGL context becomes invalid.
+func API(context glbase.Contexter) *GL {
+ gl := &GL{}
+ gl.funcs = C.gl4_3compat_funcs()
+ if gl.funcs == nil {
+ panic(fmt.Errorf("OpenGL version 4.3 is not available"))
+ }
+ return gl
+}
+
+// GL implements the OpenGL version 4.3 API. Values of this
+// type must be created via the API function, and it must not be used after
+// the associated OpenGL context becomes invalid.
+type GL struct {
+ funcs unsafe.Pointer
+}
+
+const (
+ FALSE = 0
+ TRUE = 1
+ NONE = 0
+
+ BYTE = 0x1400
+ UNSIGNED_BYTE = 0x1401
+ SHORT = 0x1402
+ UNSIGNED_SHORT = 0x1403
+ INT = 0x1404
+ UNSIGNED_INT = 0x1405
+ FLOAT = 0x1406
+ N2_BYTES = 0x1407
+ N3_BYTES = 0x1408
+ N4_BYTES = 0x1409
+ DOUBLE = 0x140A
+ HALF_FLOAT = 0x140B
+ FIXED = 0x140C
+
+ ACCUM = 0x0100
+ LOAD = 0x0101
+ RETURN = 0x0102
+ MULT = 0x0103
+ ADD = 0x0104
+
+ ACCUM_BUFFER_BIT = 0x00000200
+ ALL_ATTRIB_BITS = 0xFFFFFFFF
+ COLOR_BUFFER_BIT = 0x00004000
+ CURRENT_BIT = 0x00000001
+ DEPTH_BUFFER_BIT = 0x00000100
+ ENABLE_BIT = 0x00002000
+ EVAL_BIT = 0x00010000
+ FOG_BIT = 0x00000080
+ HINT_BIT = 0x00008000
+ LIGHTING_BIT = 0x00000040
+ LINE_BIT = 0x00000004
+ LIST_BIT = 0x00020000
+ MULTISAMPLE_BIT = 0x20000000
+ PIXEL_MODE_BIT = 0x00000020
+ POINT_BIT = 0x00000002
+ POLYGON_BIT = 0x00000008
+ POLYGON_STIPPLE_BIT = 0x00000010
+ SCISSOR_BIT = 0x00080000
+ STENCIL_BUFFER_BIT = 0x00000400
+ TEXTURE_BIT = 0x00040000
+ TRANSFORM_BIT = 0x00001000
+ VIEWPORT_BIT = 0x00000800
+
+ ALWAYS = 0x0207
+ EQUAL = 0x0202
+ GEQUAL = 0x0206
+ GREATER = 0x0204
+ LEQUAL = 0x0203
+ LESS = 0x0201
+ NEVER = 0x0200
+ NOTEQUAL = 0x0205
+
+ LOGIC_OP = 0x0BF1
+
+ DST_ALPHA = 0x0304
+ ONE = 1
+ ONE_MINUS_DST_ALPHA = 0x0305
+ ONE_MINUS_SRC_ALPHA = 0x0303
+ ONE_MINUS_SRC_COLOR = 0x0301
+ SRC_ALPHA = 0x0302
+ SRC_COLOR = 0x0300
+ ZERO = 0
+
+ DST_COLOR = 0x0306
+ ONE_MINUS_DST_COLOR = 0x0307
+ SRC_ALPHA_SATURATE = 0x0308
+
+ CLIENT_ALL_ATTRIB_BITS = 0xFFFFFFFF
+ CLIENT_PIXEL_STORE_BIT = 0x00000001
+ CLIENT_VERTEX_ARRAY_BIT = 0x00000002
+
+ CLIP_DISTANCE0 = 0x3000
+ CLIP_DISTANCE1 = 0x3001
+ CLIP_DISTANCE2 = 0x3002
+ CLIP_DISTANCE3 = 0x3003
+ CLIP_DISTANCE4 = 0x3004
+ CLIP_DISTANCE5 = 0x3005
+ CLIP_DISTANCE6 = 0x3006
+ CLIP_DISTANCE7 = 0x3007
+ CLIP_PLANE0 = 0x3000
+ CLIP_PLANE1 = 0x3001
+ CLIP_PLANE2 = 0x3002
+ CLIP_PLANE3 = 0x3003
+ CLIP_PLANE4 = 0x3004
+ CLIP_PLANE5 = 0x3005
+
+ BACK = 0x0405
+ FRONT = 0x0404
+ FRONT_AND_BACK = 0x0408
+
+ AMBIENT = 0x1200
+ AMBIENT_AND_DIFFUSE = 0x1602
+ DIFFUSE = 0x1201
+ EMISSION = 0x1600
+ SPECULAR = 0x1202
+
+ CONTEXT_FLAG_DEBUG_BIT = 0x00000002
+ CONTEXT_FLAG_FORWARD_COMPATIBLE_BIT = 0x00000001
+
+ CONTEXT_COMPATIBILITY_PROFILE_BIT = 0x00000002
+ CONTEXT_CORE_PROFILE_BIT = 0x00000001
+
+ AUX0 = 0x0409
+ AUX1 = 0x040A
+ AUX2 = 0x040B
+ AUX3 = 0x040C
+ BACK_LEFT = 0x0402
+ BACK_RIGHT = 0x0403
+ FRONT_LEFT = 0x0400
+ FRONT_RIGHT = 0x0401
+ LEFT = 0x0406
+ RIGHT = 0x0407
+
+ ALPHA_TEST = 0x0BC0
+ AUTO_NORMAL = 0x0D80
+ BLEND = 0x0BE2
+ COLOR_ARRAY = 0x8076
+ COLOR_LOGIC_OP = 0x0BF2
+ COLOR_MATERIAL = 0x0B57
+ CULL_FACE = 0x0B44
+ DEPTH_TEST = 0x0B71
+ DITHER = 0x0BD0
+ EDGE_FLAG_ARRAY = 0x8079
+ FOG = 0x0B60
+ INDEX_ARRAY = 0x8077
+ INDEX_LOGIC_OP = 0x0BF1
+ LIGHT0 = 0x4000
+ LIGHT1 = 0x4001
+ LIGHT2 = 0x4002
+ LIGHT3 = 0x4003
+ LIGHT4 = 0x4004
+ LIGHT5 = 0x4005
+ LIGHT6 = 0x4006
+ LIGHT7 = 0x4007
+ LIGHTING = 0x0B50
+ LINE_SMOOTH = 0x0B20
+ LINE_STIPPLE = 0x0B24
+ MAP1_COLOR_4 = 0x0D90
+ MAP1_INDEX = 0x0D91
+ MAP1_NORMAL = 0x0D92
+ MAP1_TEXTURE_COORD_1 = 0x0D93
+ MAP1_TEXTURE_COORD_2 = 0x0D94
+ MAP1_TEXTURE_COORD_3 = 0x0D95
+ MAP1_TEXTURE_COORD_4 = 0x0D96
+ MAP1_VERTEX_3 = 0x0D97
+ MAP1_VERTEX_4 = 0x0D98
+ MAP2_COLOR_4 = 0x0DB0
+ MAP2_INDEX = 0x0DB1
+ MAP2_NORMAL = 0x0DB2
+ MAP2_TEXTURE_COORD_1 = 0x0DB3
+ MAP2_TEXTURE_COORD_2 = 0x0DB4
+ MAP2_TEXTURE_COORD_3 = 0x0DB5
+ MAP2_TEXTURE_COORD_4 = 0x0DB6
+ MAP2_VERTEX_3 = 0x0DB7
+ MAP2_VERTEX_4 = 0x0DB8
+ NORMALIZE = 0x0BA1
+ NORMAL_ARRAY = 0x8075
+ POINT_SMOOTH = 0x0B10
+ POLYGON_OFFSET_FILL = 0x8037
+ POLYGON_OFFSET_LINE = 0x2A02
+ POLYGON_OFFSET_POINT = 0x2A01
+ POLYGON_SMOOTH = 0x0B41
+ POLYGON_STIPPLE = 0x0B42
+ SCISSOR_TEST = 0x0C11
+ STENCIL_TEST = 0x0B90
+ TEXTURE_1D = 0x0DE0
+ TEXTURE_2D = 0x0DE1
+ TEXTURE_COORD_ARRAY = 0x8078
+ TEXTURE_GEN_Q = 0x0C63
+ TEXTURE_GEN_R = 0x0C62
+ TEXTURE_GEN_S = 0x0C60
+ TEXTURE_GEN_T = 0x0C61
+ VERTEX_ARRAY = 0x8074
+
+ INVALID_ENUM = 0x0500
+ INVALID_FRAMEBUFFER_OPERATION = 0x0506
+ INVALID_OPERATION = 0x0502
+ INVALID_VALUE = 0x0501
+ NO_ERROR = 0
+ OUT_OF_MEMORY = 0x0505
+ STACK_OVERFLOW = 0x0503
+ STACK_UNDERFLOW = 0x0504
+
+ N2D = 0x0600
+ N3D = 0x0601
+ N3D_COLOR = 0x0602
+ N3D_COLOR_TEXTURE = 0x0603
+ N4D_COLOR_TEXTURE = 0x0604
+
+ BITMAP_TOKEN = 0x0704
+ COPY_PIXEL_TOKEN = 0x0706
+ DRAW_PIXEL_TOKEN = 0x0705
+ LINE_RESET_TOKEN = 0x0707
+ LINE_TOKEN = 0x0702
+ PASS_THROUGH_TOKEN = 0x0700
+ POINT_TOKEN = 0x0701
+ POLYGON_TOKEN = 0x0703
+
+ EXP = 0x0800
+ EXP2 = 0x0801
+ LINEAR = 0x2601
+
+ FOG_COLOR = 0x0B66
+ FOG_DENSITY = 0x0B62
+ FOG_END = 0x0B64
+ FOG_INDEX = 0x0B61
+ FOG_MODE = 0x0B65
+ FOG_START = 0x0B63
+
+ CCW = 0x0901
+ CW = 0x0900
+
+ COEFF = 0x0A00
+ DOMAIN = 0x0A02
+ ORDER = 0x0A01
+
+ PIXEL_MAP_A_TO_A = 0x0C79
+ PIXEL_MAP_B_TO_B = 0x0C78
+ PIXEL_MAP_G_TO_G = 0x0C77
+ PIXEL_MAP_I_TO_A = 0x0C75
+ PIXEL_MAP_I_TO_B = 0x0C74
+ PIXEL_MAP_I_TO_G = 0x0C73
+ PIXEL_MAP_I_TO_I = 0x0C70
+ PIXEL_MAP_I_TO_R = 0x0C72
+ PIXEL_MAP_R_TO_R = 0x0C76
+ PIXEL_MAP_S_TO_S = 0x0C71
+
+ ACCUM_ALPHA_BITS = 0x0D5B
+ ACCUM_BLUE_BITS = 0x0D5A
+ ACCUM_CLEAR_VALUE = 0x0B80
+ ACCUM_GREEN_BITS = 0x0D59
+ ACCUM_RED_BITS = 0x0D58
+ ALIASED_LINE_WIDTH_RANGE = 0x846E
+ ALIASED_POINT_SIZE_RANGE = 0x846D
+ ALPHA_BIAS = 0x0D1D
+ ALPHA_BITS = 0x0D55
+ ALPHA_SCALE = 0x0D1C
+ ALPHA_TEST_FUNC = 0x0BC1
+ ALPHA_TEST_REF = 0x0BC2
+ ATTRIB_STACK_DEPTH = 0x0BB0
+ AUX_BUFFERS = 0x0C00
+ BLEND_DST = 0x0BE0
+ BLEND_SRC = 0x0BE1
+ BLUE_BIAS = 0x0D1B
+ BLUE_BITS = 0x0D54
+ BLUE_SCALE = 0x0D1A
+ CLIENT_ATTRIB_STACK_DEPTH = 0x0BB1
+ COLOR_ARRAY_SIZE = 0x8081
+ COLOR_ARRAY_STRIDE = 0x8083
+ COLOR_ARRAY_TYPE = 0x8082
+ COLOR_CLEAR_VALUE = 0x0C22
+ COLOR_MATERIAL_FACE = 0x0B55
+ COLOR_MATERIAL_PARAMETER = 0x0B56
+ COLOR_WRITEMASK = 0x0C23
+ CULL_FACE_MODE = 0x0B45
+ CURRENT_COLOR = 0x0B00
+ CURRENT_INDEX = 0x0B01
+ CURRENT_NORMAL = 0x0B02
+ CURRENT_RASTER_COLOR = 0x0B04
+ CURRENT_RASTER_DISTANCE = 0x0B09
+ CURRENT_RASTER_INDEX = 0x0B05
+ CURRENT_RASTER_POSITION = 0x0B07
+ CURRENT_RASTER_POSITION_VALID = 0x0B08
+ CURRENT_RASTER_TEXTURE_COORDS = 0x0B06
+ CURRENT_TEXTURE_COORDS = 0x0B03
+ DEPTH_BIAS = 0x0D1F
+ DEPTH_BITS = 0x0D56
+ DEPTH_CLEAR_VALUE = 0x0B73
+ DEPTH_FUNC = 0x0B74
+ DEPTH_RANGE = 0x0B70
+ DEPTH_SCALE = 0x0D1E
+ DEPTH_WRITEMASK = 0x0B72
+ DOUBLEBUFFER = 0x0C32
+ DRAW_BUFFER = 0x0C01
+ EDGE_FLAG = 0x0B43
+ EDGE_FLAG_ARRAY_STRIDE = 0x808C
+ FEEDBACK_BUFFER_SIZE = 0x0DF1
+ FEEDBACK_BUFFER_TYPE = 0x0DF2
+ FOG_HINT = 0x0C54
+ FRONT_FACE = 0x0B46
+ GREEN_BIAS = 0x0D19
+ GREEN_BITS = 0x0D53
+ GREEN_SCALE = 0x0D18
+ INDEX_ARRAY_STRIDE = 0x8086
+ INDEX_ARRAY_TYPE = 0x8085
+ INDEX_BITS = 0x0D51
+ INDEX_CLEAR_VALUE = 0x0C20
+ INDEX_MODE = 0x0C30
+ INDEX_OFFSET = 0x0D13
+ INDEX_SHIFT = 0x0D12
+ INDEX_WRITEMASK = 0x0C21
+ LIGHT_MODEL_AMBIENT = 0x0B53
+ LIGHT_MODEL_COLOR_CONTROL = 0x81F8
+ LIGHT_MODEL_LOCAL_VIEWER = 0x0B51
+ LIGHT_MODEL_TWO_SIDE = 0x0B52
+ LINE_SMOOTH_HINT = 0x0C52
+ LINE_STIPPLE_PATTERN = 0x0B25
+ LINE_STIPPLE_REPEAT = 0x0B26
+ LINE_WIDTH = 0x0B21
+ LINE_WIDTH_GRANULARITY = 0x0B23
+ LINE_WIDTH_RANGE = 0x0B22
+ LIST_BASE = 0x0B32
+ LIST_INDEX = 0x0B33
+ LIST_MODE = 0x0B30
+ LOGIC_OP_MODE = 0x0BF0
+ MAP1_GRID_DOMAIN = 0x0DD0
+ MAP1_GRID_SEGMENTS = 0x0DD1
+ MAP2_GRID_DOMAIN = 0x0DD2
+ MAP2_GRID_SEGMENTS = 0x0DD3
+ MAP_COLOR = 0x0D10
+ MAP_STENCIL = 0x0D11
+ MATRIX_MODE = 0x0BA0
+ MAX_ATTRIB_STACK_DEPTH = 0x0D35
+ MAX_CLIENT_ATTRIB_STACK_DEPTH = 0x0D3B
+ MAX_CLIP_DISTANCES = 0x0D32
+ MAX_CLIP_PLANES = 0x0D32
+ MAX_EVAL_ORDER = 0x0D30
+ MAX_LIGHTS = 0x0D31
+ MAX_LIST_NESTING = 0x0B31
+ MAX_MODELVIEW_STACK_DEPTH = 0x0D36
+ MAX_NAME_STACK_DEPTH = 0x0D37
+ MAX_PIXEL_MAP_TABLE = 0x0D34
+ MAX_PROJECTION_STACK_DEPTH = 0x0D38
+ MAX_TEXTURE_SIZE = 0x0D33
+ MAX_TEXTURE_STACK_DEPTH = 0x0D39
+ MAX_VIEWPORT_DIMS = 0x0D3A
+ MODELVIEW_MATRIX = 0x0BA6
+ MODELVIEW_STACK_DEPTH = 0x0BA3
+ NAME_STACK_DEPTH = 0x0D70
+ NORMAL_ARRAY_STRIDE = 0x807F
+ NORMAL_ARRAY_TYPE = 0x807E
+ PACK_ALIGNMENT = 0x0D05
+ PACK_LSB_FIRST = 0x0D01
+ PACK_ROW_LENGTH = 0x0D02
+ PACK_SKIP_PIXELS = 0x0D04
+ PACK_SKIP_ROWS = 0x0D03
+ PACK_SWAP_BYTES = 0x0D00
+ PERSPECTIVE_CORRECTION_HINT = 0x0C50
+ PIXEL_MAP_A_TO_A_SIZE = 0x0CB9
+ PIXEL_MAP_B_TO_B_SIZE = 0x0CB8
+ PIXEL_MAP_G_TO_G_SIZE = 0x0CB7
+ PIXEL_MAP_I_TO_A_SIZE = 0x0CB5
+ PIXEL_MAP_I_TO_B_SIZE = 0x0CB4
+ PIXEL_MAP_I_TO_G_SIZE = 0x0CB3
+ PIXEL_MAP_I_TO_I_SIZE = 0x0CB0
+ PIXEL_MAP_I_TO_R_SIZE = 0x0CB2
+ PIXEL_MAP_R_TO_R_SIZE = 0x0CB6
+ PIXEL_MAP_S_TO_S_SIZE = 0x0CB1
+ POINT_SIZE = 0x0B11
+ POINT_SIZE_GRANULARITY = 0x0B13
+ POINT_SIZE_RANGE = 0x0B12
+ POINT_SMOOTH_HINT = 0x0C51
+ POLYGON_MODE = 0x0B40
+ POLYGON_OFFSET_FACTOR = 0x8038
+ POLYGON_OFFSET_UNITS = 0x2A00
+ POLYGON_SMOOTH_HINT = 0x0C53
+ PROJECTION_MATRIX = 0x0BA7
+ PROJECTION_STACK_DEPTH = 0x0BA4
+ READ_BUFFER = 0x0C02
+ RED_BIAS = 0x0D15
+ RED_BITS = 0x0D52
+ RED_SCALE = 0x0D14
+ RENDER_MODE = 0x0C40
+ RGBA_MODE = 0x0C31
+ SCISSOR_BOX = 0x0C10
+ SELECTION_BUFFER_SIZE = 0x0DF4
+ SHADE_MODEL = 0x0B54
+ SMOOTH_LINE_WIDTH_GRANULARITY = 0x0B23
+ SMOOTH_LINE_WIDTH_RANGE = 0x0B22
+ SMOOTH_POINT_SIZE_GRANULARITY = 0x0B13
+ SMOOTH_POINT_SIZE_RANGE = 0x0B12
+ STENCIL_BITS = 0x0D57
+ STENCIL_CLEAR_VALUE = 0x0B91
+ STENCIL_FAIL = 0x0B94
+ STENCIL_FUNC = 0x0B92
+ STENCIL_PASS_DEPTH_FAIL = 0x0B95
+ STENCIL_PASS_DEPTH_PASS = 0x0B96
+ STENCIL_REF = 0x0B97
+ STENCIL_VALUE_MASK = 0x0B93
+ STENCIL_WRITEMASK = 0x0B98
+ STEREO = 0x0C33
+ SUBPIXEL_BITS = 0x0D50
+ TEXTURE_BINDING_1D = 0x8068
+ TEXTURE_BINDING_2D = 0x8069
+ TEXTURE_BINDING_3D = 0x806A
+ TEXTURE_COORD_ARRAY_SIZE = 0x8088
+ TEXTURE_COORD_ARRAY_STRIDE = 0x808A
+ TEXTURE_COORD_ARRAY_TYPE = 0x8089
+ TEXTURE_MATRIX = 0x0BA8
+ TEXTURE_STACK_DEPTH = 0x0BA5
+ UNPACK_ALIGNMENT = 0x0CF5
+ UNPACK_LSB_FIRST = 0x0CF1
+ UNPACK_ROW_LENGTH = 0x0CF2
+ UNPACK_SKIP_PIXELS = 0x0CF4
+ UNPACK_SKIP_ROWS = 0x0CF3
+ UNPACK_SWAP_BYTES = 0x0CF0
+ VERTEX_ARRAY_SIZE = 0x807A
+ VERTEX_ARRAY_STRIDE = 0x807C
+ VERTEX_ARRAY_TYPE = 0x807B
+ VIEWPORT = 0x0BA2
+ ZOOM_X = 0x0D16
+ ZOOM_Y = 0x0D17
+
+ COLOR_ARRAY_POINTER = 0x8090
+ EDGE_FLAG_ARRAY_POINTER = 0x8093
+ FEEDBACK_BUFFER_POINTER = 0x0DF0
+ INDEX_ARRAY_POINTER = 0x8091
+ NORMAL_ARRAY_POINTER = 0x808F
+ SELECTION_BUFFER_POINTER = 0x0DF3
+ TEXTURE_COORD_ARRAY_POINTER = 0x8092
+ VERTEX_ARRAY_POINTER = 0x808E
+
+ TEXTURE_ALPHA_SIZE = 0x805F
+ TEXTURE_BLUE_SIZE = 0x805E
+ TEXTURE_BORDER = 0x1005
+ TEXTURE_BORDER_COLOR = 0x1004
+ TEXTURE_COMPONENTS = 0x1003
+ TEXTURE_GREEN_SIZE = 0x805D
+ TEXTURE_HEIGHT = 0x1001
+ TEXTURE_INTENSITY_SIZE = 0x8061
+ TEXTURE_INTERNAL_FORMAT = 0x1003
+ TEXTURE_LUMINANCE_SIZE = 0x8060
+ TEXTURE_MAG_FILTER = 0x2800
+ TEXTURE_MIN_FILTER = 0x2801
+ TEXTURE_PRIORITY = 0x8066
+ TEXTURE_RED_SIZE = 0x805C
+ TEXTURE_RESIDENT = 0x8067
+ TEXTURE_WIDTH = 0x1000
+ TEXTURE_WRAP_S = 0x2802
+ TEXTURE_WRAP_T = 0x2803
+
+ DONT_CARE = 0x1100
+ FASTEST = 0x1101
+ NICEST = 0x1102
+
+ FRAGMENT_SHADER_DERIVATIVE_HINT = 0x8B8B
+ GENERATE_MIPMAP_HINT = 0x8192
+ PROGRAM_BINARY_RETRIEVABLE_HINT = 0x8257
+ TEXTURE_COMPRESSION_HINT = 0x84EF
+
+ C3F_V3F = 0x2A24
+ C4F_N3F_V3F = 0x2A26
+ C4UB_V2F = 0x2A22
+ C4UB_V3F = 0x2A23
+ N3F_V3F = 0x2A25
+ T2F_C3F_V3F = 0x2A2A
+ T2F_C4F_N3F_V3F = 0x2A2C
+ T2F_C4UB_V3F = 0x2A29
+ T2F_N3F_V3F = 0x2A2B
+ T2F_V3F = 0x2A27
+ T4F_C4F_N3F_V4F = 0x2A2D
+ T4F_V4F = 0x2A28
+ V2F = 0x2A20
+ V3F = 0x2A21
+
+ MODULATE = 0x2100
+ REPLACE = 0x1E01
+
+ SEPARATE_SPECULAR_COLOR = 0x81FA
+ SINGLE_COLOR = 0x81F9
+
+ CONSTANT_ATTENUATION = 0x1207
+ LINEAR_ATTENUATION = 0x1208
+ POSITION = 0x1203
+ QUADRATIC_ATTENUATION = 0x1209
+ SPOT_CUTOFF = 0x1206
+ SPOT_DIRECTION = 0x1204
+ SPOT_EXPONENT = 0x1205
+
+ COMPILE = 0x1300
+ COMPILE_AND_EXECUTE = 0x1301
+
+ AND = 0x1501
+ AND_INVERTED = 0x1504
+ AND_REVERSE = 0x1502
+ CLEAR = 0x1500
+ COPY = 0x1503
+ COPY_INVERTED = 0x150C
+ EQUIV = 0x1509
+ INVERT = 0x150A
+ NAND = 0x150E
+ NOOP = 0x1505
+ NOR = 0x1508
+ OR = 0x1507
+ OR_INVERTED = 0x150D
+ OR_REVERSE = 0x150B
+ SET = 0x150F
+ XOR = 0x1506
+
+ MAP_FLUSH_EXPLICIT_BIT = 0x0010
+ MAP_INVALIDATE_BUFFER_BIT = 0x0008
+ MAP_INVALIDATE_RANGE_BIT = 0x0004
+ MAP_READ_BIT = 0x0001
+ MAP_UNSYNCHRONIZED_BIT = 0x0020
+ MAP_WRITE_BIT = 0x0002
+
+ COLOR_INDEXES = 0x1603
+ SHININESS = 0x1601
+
+ MODELVIEW = 0x1700
+ PROJECTION = 0x1701
+ TEXTURE = 0x1702
+
+ ALL_BARRIER_BITS = 0xFFFFFFFF
+ ATOMIC_COUNTER_BARRIER_BIT = 0x00001000
+ BUFFER_UPDATE_BARRIER_BIT = 0x00000200
+ COMMAND_BARRIER_BIT = 0x00000040
+ ELEMENT_ARRAY_BARRIER_BIT = 0x00000002
+ FRAMEBUFFER_BARRIER_BIT = 0x00000400
+ PIXEL_BUFFER_BARRIER_BIT = 0x00000080
+ SHADER_IMAGE_ACCESS_BARRIER_BIT = 0x00000020
+ SHADER_STORAGE_BARRIER_BIT = 0x00002000
+ TEXTURE_FETCH_BARRIER_BIT = 0x00000008
+ TEXTURE_UPDATE_BARRIER_BIT = 0x00000100
+ TRANSFORM_FEEDBACK_BARRIER_BIT = 0x00000800
+ UNIFORM_BARRIER_BIT = 0x00000004
+ VERTEX_ATTRIB_ARRAY_BARRIER_BIT = 0x00000001
+
+ LINE = 0x1B01
+ POINT = 0x1B00
+
+ FILL = 0x1B02
+
+ COLOR = 0x1800
+ DEPTH = 0x1801
+ STENCIL = 0x1802
+
+ ALPHA = 0x1906
+ BLUE = 0x1905
+ COLOR_INDEX = 0x1900
+ DEPTH_COMPONENT = 0x1902
+ GREEN = 0x1904
+ LUMINANCE = 0x1909
+ LUMINANCE_ALPHA = 0x190A
+ RED = 0x1903
+ RGB = 0x1907
+ RGBA = 0x1908
+ STENCIL_INDEX = 0x1901
+
+ ALPHA12 = 0x803D
+ ALPHA16 = 0x803E
+ ALPHA4 = 0x803B
+ ALPHA8 = 0x803C
+ INTENSITY = 0x8049
+ INTENSITY12 = 0x804C
+ INTENSITY16 = 0x804D
+ INTENSITY4 = 0x804A
+ INTENSITY8 = 0x804B
+ LUMINANCE12 = 0x8041
+ LUMINANCE12_ALPHA12 = 0x8047
+ LUMINANCE12_ALPHA4 = 0x8046
+ LUMINANCE16 = 0x8042
+ LUMINANCE16_ALPHA16 = 0x8048
+ LUMINANCE4 = 0x803F
+ LUMINANCE4_ALPHA4 = 0x8043
+ LUMINANCE6_ALPHA2 = 0x8044
+ LUMINANCE8 = 0x8040
+ LUMINANCE8_ALPHA8 = 0x8045
+ R3_G3_B2 = 0x2A10
+ RGB10 = 0x8052
+ RGB10_A2 = 0x8059
+ RGB12 = 0x8053
+ RGB16 = 0x8054
+ RGB4 = 0x804F
+ RGB5 = 0x8050
+ RGB5_A1 = 0x8057
+ RGB8 = 0x8051
+ RGBA12 = 0x805A
+ RGBA16 = 0x805B
+ RGBA2 = 0x8055
+ RGBA4 = 0x8056
+ RGBA8 = 0x8058
+
+ PACK_IMAGE_HEIGHT = 0x806C
+ PACK_SKIP_IMAGES = 0x806B
+ UNPACK_IMAGE_HEIGHT = 0x806E
+ UNPACK_SKIP_IMAGES = 0x806D
+
+ BITMAP = 0x1A00
+ UNSIGNED_BYTE_3_3_2 = 0x8032
+ UNSIGNED_INT_10_10_10_2 = 0x8036
+ UNSIGNED_INT_8_8_8_8 = 0x8035
+ UNSIGNED_SHORT_4_4_4_4 = 0x8033
+ UNSIGNED_SHORT_5_5_5_1 = 0x8034
+
+ POINT_DISTANCE_ATTENUATION = 0x8129
+ POINT_FADE_THRESHOLD_SIZE = 0x8128
+ POINT_SIZE_MAX = 0x8127
+ POINT_SIZE_MIN = 0x8126
+
+ LINES = 0x0001
+ LINES_ADJACENCY = 0x000A
+ LINE_LOOP = 0x0002
+ LINE_STRIP = 0x0003
+ LINE_STRIP_ADJACENCY = 0x000B
+ PATCHES = 0x000E
+ POINTS = 0x0000
+ POLYGON = 0x0009
+ QUADS = 0x0007
+ QUAD_STRIP = 0x0008
+ TRIANGLES = 0x0004
+ TRIANGLES_ADJACENCY = 0x000C
+ TRIANGLE_FAN = 0x0006
+ TRIANGLE_STRIP = 0x0005
+ TRIANGLE_STRIP_ADJACENCY = 0x000D
+
+ FEEDBACK = 0x1C01
+ RENDER = 0x1C00
+ SELECT = 0x1C02
+
+ FLAT = 0x1D00
+ SMOOTH = 0x1D01
+
+ DECR = 0x1E03
+ INCR = 0x1E02
+ KEEP = 0x1E00
+
+ EXTENSIONS = 0x1F03
+ RENDERER = 0x1F01
+ VENDOR = 0x1F00
+ VERSION = 0x1F02
+
+ S = 0x2000
+ T = 0x2001
+ R = 0x2002
+ Q = 0x2003
+
+ DECAL = 0x2101
+
+ TEXTURE_ENV_COLOR = 0x2201
+ TEXTURE_ENV_MODE = 0x2200
+
+ TEXTURE_ENV = 0x2300
+
+ EYE_LINEAR = 0x2400
+ OBJECT_LINEAR = 0x2401
+ SPHERE_MAP = 0x2402
+
+ EYE_PLANE = 0x2502
+ OBJECT_PLANE = 0x2501
+ TEXTURE_GEN_MODE = 0x2500
+
+ NEAREST = 0x2600
+
+ LINEAR_MIPMAP_LINEAR = 0x2703
+ LINEAR_MIPMAP_NEAREST = 0x2701
+ NEAREST_MIPMAP_LINEAR = 0x2702
+ NEAREST_MIPMAP_NEAREST = 0x2700
+
+ GENERATE_MIPMAP = 0x8191
+ TEXTURE_WRAP_R = 0x8072
+
+ PROXY_TEXTURE_1D = 0x8063
+ PROXY_TEXTURE_2D = 0x8064
+ PROXY_TEXTURE_3D = 0x8070
+ TEXTURE_3D = 0x806F
+ TEXTURE_BASE_LEVEL = 0x813C
+ TEXTURE_MAX_LEVEL = 0x813D
+ TEXTURE_MAX_LOD = 0x813B
+ TEXTURE_MIN_LOD = 0x813A
+
+ CLAMP = 0x2900
+ CLAMP_TO_BORDER = 0x812D
+ CLAMP_TO_EDGE = 0x812F
+ REPEAT = 0x2901
+
+ VERTEX_SHADER_BIT = 0x00000001
+ FRAGMENT_SHADER_BIT = 0x00000002
+ GEOMETRY_SHADER_BIT = 0x00000004
+ TESS_CONTROL_SHADER_BIT = 0x00000008
+ TESS_EVALUATION_SHADER_BIT = 0x00000010
+ COMPUTE_SHADER_BIT = 0x00000020
+ ALL_SHADER_BITS = 0xFFFFFFFF
+
+ SYNC_FLUSH_COMMANDS_BIT = 0x00000001
+ INVALID_INDEX = 0xFFFFFFFF
+ TIMEOUT_IGNORED = 0xFFFFFFFFFFFFFFFF
+ CONSTANT_COLOR = 0x8001
+ ONE_MINUS_CONSTANT_COLOR = 0x8002
+ CONSTANT_ALPHA = 0x8003
+ ONE_MINUS_CONSTANT_ALPHA = 0x8004
+ FUNC_ADD = 0x8006
+ MIN = 0x8007
+ MAX = 0x8008
+ BLEND_EQUATION_RGB = 0x8009
+ FUNC_SUBTRACT = 0x800A
+ FUNC_REVERSE_SUBTRACT = 0x800B
+ RESCALE_NORMAL = 0x803A
+ TEXTURE_DEPTH = 0x8071
+ MAX_3D_TEXTURE_SIZE = 0x8073
+ MULTISAMPLE = 0x809D
+ SAMPLE_ALPHA_TO_COVERAGE = 0x809E
+ SAMPLE_ALPHA_TO_ONE = 0x809F
+ SAMPLE_COVERAGE = 0x80A0
+ SAMPLE_BUFFERS = 0x80A8
+ SAMPLES = 0x80A9
+ SAMPLE_COVERAGE_VALUE = 0x80AA
+ SAMPLE_COVERAGE_INVERT = 0x80AB
+ BLEND_DST_RGB = 0x80C8
+ BLEND_SRC_RGB = 0x80C9
+ BLEND_DST_ALPHA = 0x80CA
+ BLEND_SRC_ALPHA = 0x80CB
+ BGR = 0x80E0
+ BGRA = 0x80E1
+ MAX_ELEMENTS_VERTICES = 0x80E8
+ MAX_ELEMENTS_INDICES = 0x80E9
+ DEPTH_COMPONENT16 = 0x81A5
+ DEPTH_COMPONENT24 = 0x81A6
+ DEPTH_COMPONENT32 = 0x81A7
+ FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING = 0x8210
+ FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE = 0x8211
+ FRAMEBUFFER_ATTACHMENT_RED_SIZE = 0x8212
+ FRAMEBUFFER_ATTACHMENT_GREEN_SIZE = 0x8213
+ FRAMEBUFFER_ATTACHMENT_BLUE_SIZE = 0x8214
+ FRAMEBUFFER_ATTACHMENT_ALPHA_SIZE = 0x8215
+ FRAMEBUFFER_ATTACHMENT_DEPTH_SIZE = 0x8216
+ FRAMEBUFFER_ATTACHMENT_STENCIL_SIZE = 0x8217
+ FRAMEBUFFER_DEFAULT = 0x8218
+ FRAMEBUFFER_UNDEFINED = 0x8219
+ DEPTH_STENCIL_ATTACHMENT = 0x821A
+ MAJOR_VERSION = 0x821B
+ MINOR_VERSION = 0x821C
+ NUM_EXTENSIONS = 0x821D
+ CONTEXT_FLAGS = 0x821E
+ INDEX = 0x8222
+ COMPRESSED_RED = 0x8225
+ COMPRESSED_RG = 0x8226
+ RG = 0x8227
+ RG_INTEGER = 0x8228
+ R8 = 0x8229
+ R16 = 0x822A
+ RG8 = 0x822B
+ RG16 = 0x822C
+ R16F = 0x822D
+ R32F = 0x822E
+ RG16F = 0x822F
+ RG32F = 0x8230
+ R8I = 0x8231
+ R8UI = 0x8232
+ R16I = 0x8233
+ R16UI = 0x8234
+ R32I = 0x8235
+ R32UI = 0x8236
+ RG8I = 0x8237
+ RG8UI = 0x8238
+ RG16I = 0x8239
+ RG16UI = 0x823A
+ RG32I = 0x823B
+ RG32UI = 0x823C
+ DEBUG_OUTPUT_SYNCHRONOUS = 0x8242
+ DEBUG_NEXT_LOGGED_MESSAGE_LENGTH = 0x8243
+ DEBUG_CALLBACK_FUNCTION = 0x8244
+ DEBUG_CALLBACK_USER_PARAM = 0x8245
+ DEBUG_SOURCE_API = 0x8246
+ DEBUG_SOURCE_WINDOW_SYSTEM = 0x8247
+ DEBUG_SOURCE_SHADER_COMPILER = 0x8248
+ DEBUG_SOURCE_THIRD_PARTY = 0x8249
+ DEBUG_SOURCE_APPLICATION = 0x824A
+ DEBUG_SOURCE_OTHER = 0x824B
+ DEBUG_TYPE_ERROR = 0x824C
+ DEBUG_TYPE_DEPRECATED_BEHAVIOR = 0x824D
+ DEBUG_TYPE_UNDEFINED_BEHAVIOR = 0x824E
+ DEBUG_TYPE_PORTABILITY = 0x824F
+ DEBUG_TYPE_PERFORMANCE = 0x8250
+ DEBUG_TYPE_OTHER = 0x8251
+ PROGRAM_SEPARABLE = 0x8258
+ ACTIVE_PROGRAM = 0x8259
+ PROGRAM_PIPELINE_BINDING = 0x825A
+ MAX_VIEWPORTS = 0x825B
+ VIEWPORT_SUBPIXEL_BITS = 0x825C
+ VIEWPORT_BOUNDS_RANGE = 0x825D
+ LAYER_PROVOKING_VERTEX = 0x825E
+ VIEWPORT_INDEX_PROVOKING_VERTEX = 0x825F
+ UNDEFINED_VERTEX = 0x8260
+ MAX_COMPUTE_SHARED_MEMORY_SIZE = 0x8262
+ MAX_COMPUTE_UNIFORM_COMPONENTS = 0x8263
+ MAX_COMPUTE_ATOMIC_COUNTER_BUFFERS = 0x8264
+ MAX_COMPUTE_ATOMIC_COUNTERS = 0x8265
+ MAX_COMBINED_COMPUTE_UNIFORM_COMPONENTS = 0x8266
+ COMPUTE_WORK_GROUP_SIZE = 0x8267
+ DEBUG_TYPE_MARKER = 0x8268
+ DEBUG_TYPE_PUSH_GROUP = 0x8269
+ DEBUG_TYPE_POP_GROUP = 0x826A
+ DEBUG_SEVERITY_NOTIFICATION = 0x826B
+ MAX_DEBUG_GROUP_STACK_DEPTH = 0x826C
+ DEBUG_GROUP_STACK_DEPTH = 0x826D
+ MAX_UNIFORM_LOCATIONS = 0x826E
+ INTERNALFORMAT_SUPPORTED = 0x826F
+ INTERNALFORMAT_PREFERRED = 0x8270
+ INTERNALFORMAT_RED_SIZE = 0x8271
+ INTERNALFORMAT_GREEN_SIZE = 0x8272
+ INTERNALFORMAT_BLUE_SIZE = 0x8273
+ INTERNALFORMAT_ALPHA_SIZE = 0x8274
+ INTERNALFORMAT_DEPTH_SIZE = 0x8275
+ INTERNALFORMAT_STENCIL_SIZE = 0x8276
+ INTERNALFORMAT_SHARED_SIZE = 0x8277
+ INTERNALFORMAT_RED_TYPE = 0x8278
+ INTERNALFORMAT_GREEN_TYPE = 0x8279
+ INTERNALFORMAT_BLUE_TYPE = 0x827A
+ INTERNALFORMAT_ALPHA_TYPE = 0x827B
+ INTERNALFORMAT_DEPTH_TYPE = 0x827C
+ INTERNALFORMAT_STENCIL_TYPE = 0x827D
+ MAX_WIDTH = 0x827E
+ MAX_HEIGHT = 0x827F
+ MAX_DEPTH = 0x8280
+ MAX_LAYERS = 0x8281
+ MAX_COMBINED_DIMENSIONS = 0x8282
+ COLOR_COMPONENTS = 0x8283
+ DEPTH_COMPONENTS = 0x8284
+ STENCIL_COMPONENTS = 0x8285
+ COLOR_RENDERABLE = 0x8286
+ DEPTH_RENDERABLE = 0x8287
+ STENCIL_RENDERABLE = 0x8288
+ FRAMEBUFFER_RENDERABLE = 0x8289
+ FRAMEBUFFER_RENDERABLE_LAYERED = 0x828A
+ FRAMEBUFFER_BLEND = 0x828B
+ READ_PIXELS = 0x828C
+ READ_PIXELS_FORMAT = 0x828D
+ READ_PIXELS_TYPE = 0x828E
+ TEXTURE_IMAGE_FORMAT = 0x828F
+ TEXTURE_IMAGE_TYPE = 0x8290
+ GET_TEXTURE_IMAGE_FORMAT = 0x8291
+ GET_TEXTURE_IMAGE_TYPE = 0x8292
+ MIPMAP = 0x8293
+ MANUAL_GENERATE_MIPMAP = 0x8294
+ AUTO_GENERATE_MIPMAP = 0x8295
+ COLOR_ENCODING = 0x8296
+ SRGB_READ = 0x8297
+ SRGB_WRITE = 0x8298
+ FILTER = 0x829A
+ VERTEX_TEXTURE = 0x829B
+ TESS_CONTROL_TEXTURE = 0x829C
+ TESS_EVALUATION_TEXTURE = 0x829D
+ GEOMETRY_TEXTURE = 0x829E
+ FRAGMENT_TEXTURE = 0x829F
+ COMPUTE_TEXTURE = 0x82A0
+ TEXTURE_SHADOW = 0x82A1
+ TEXTURE_GATHER = 0x82A2
+ TEXTURE_GATHER_SHADOW = 0x82A3
+ SHADER_IMAGE_LOAD = 0x82A4
+ SHADER_IMAGE_STORE = 0x82A5
+ SHADER_IMAGE_ATOMIC = 0x82A6
+ IMAGE_TEXEL_SIZE = 0x82A7
+ IMAGE_COMPATIBILITY_CLASS = 0x82A8
+ IMAGE_PIXEL_FORMAT = 0x82A9
+ IMAGE_PIXEL_TYPE = 0x82AA
+ SIMULTANEOUS_TEXTURE_AND_DEPTH_TEST = 0x82AC
+ SIMULTANEOUS_TEXTURE_AND_STENCIL_TEST = 0x82AD
+ SIMULTANEOUS_TEXTURE_AND_DEPTH_WRITE = 0x82AE
+ SIMULTANEOUS_TEXTURE_AND_STENCIL_WRITE = 0x82AF
+ TEXTURE_COMPRESSED_BLOCK_WIDTH = 0x82B1
+ TEXTURE_COMPRESSED_BLOCK_HEIGHT = 0x82B2
+ TEXTURE_COMPRESSED_BLOCK_SIZE = 0x82B3
+ CLEAR_BUFFER = 0x82B4
+ TEXTURE_VIEW = 0x82B5
+ VIEW_COMPATIBILITY_CLASS = 0x82B6
+ FULL_SUPPORT = 0x82B7
+ CAVEAT_SUPPORT = 0x82B8
+ IMAGE_CLASS_4_X_32 = 0x82B9
+ IMAGE_CLASS_2_X_32 = 0x82BA
+ IMAGE_CLASS_1_X_32 = 0x82BB
+ IMAGE_CLASS_4_X_16 = 0x82BC
+ IMAGE_CLASS_2_X_16 = 0x82BD
+ IMAGE_CLASS_1_X_16 = 0x82BE
+ IMAGE_CLASS_4_X_8 = 0x82BF
+ IMAGE_CLASS_2_X_8 = 0x82C0
+ IMAGE_CLASS_1_X_8 = 0x82C1
+ IMAGE_CLASS_11_11_10 = 0x82C2
+ IMAGE_CLASS_10_10_10_2 = 0x82C3
+ VIEW_CLASS_128_BITS = 0x82C4
+ VIEW_CLASS_96_BITS = 0x82C5
+ VIEW_CLASS_64_BITS = 0x82C6
+ VIEW_CLASS_48_BITS = 0x82C7
+ VIEW_CLASS_32_BITS = 0x82C8
+ VIEW_CLASS_24_BITS = 0x82C9
+ VIEW_CLASS_16_BITS = 0x82CA
+ VIEW_CLASS_8_BITS = 0x82CB
+ VIEW_CLASS_S3TC_DXT1_RGB = 0x82CC
+ VIEW_CLASS_S3TC_DXT1_RGBA = 0x82CD
+ VIEW_CLASS_S3TC_DXT3_RGBA = 0x82CE
+ VIEW_CLASS_S3TC_DXT5_RGBA = 0x82CF
+ VIEW_CLASS_RGTC1_RED = 0x82D0
+ VIEW_CLASS_RGTC2_RG = 0x82D1
+ VIEW_CLASS_BPTC_UNORM = 0x82D2
+ VIEW_CLASS_BPTC_FLOAT = 0x82D3
+ VERTEX_ATTRIB_BINDING = 0x82D4
+ VERTEX_ATTRIB_RELATIVE_OFFSET = 0x82D5
+ VERTEX_BINDING_DIVISOR = 0x82D6
+ VERTEX_BINDING_OFFSET = 0x82D7
+ VERTEX_BINDING_STRIDE = 0x82D8
+ MAX_VERTEX_ATTRIB_RELATIVE_OFFSET = 0x82D9
+ MAX_VERTEX_ATTRIB_BINDINGS = 0x82DA
+ TEXTURE_VIEW_MIN_LEVEL = 0x82DB
+ TEXTURE_VIEW_NUM_LEVELS = 0x82DC
+ TEXTURE_VIEW_MIN_LAYER = 0x82DD
+ TEXTURE_VIEW_NUM_LAYERS = 0x82DE
+ TEXTURE_IMMUTABLE_LEVELS = 0x82DF
+ BUFFER = 0x82E0
+ SHADER = 0x82E1
+ PROGRAM = 0x82E2
+ QUERY = 0x82E3
+ PROGRAM_PIPELINE = 0x82E4
+ SAMPLER = 0x82E6
+ DISPLAY_LIST = 0x82E7
+ MAX_LABEL_LENGTH = 0x82E8
+ NUM_SHADING_LANGUAGE_VERSIONS = 0x82E9
+ UNSIGNED_BYTE_2_3_3_REV = 0x8362
+ UNSIGNED_SHORT_5_6_5 = 0x8363
+ UNSIGNED_SHORT_5_6_5_REV = 0x8364
+ UNSIGNED_SHORT_4_4_4_4_REV = 0x8365
+ UNSIGNED_SHORT_1_5_5_5_REV = 0x8366
+ UNSIGNED_INT_8_8_8_8_REV = 0x8367
+ UNSIGNED_INT_2_10_10_10_REV = 0x8368
+ MIRRORED_REPEAT = 0x8370
+ FOG_COORDINATE_SOURCE = 0x8450
+ FOG_COORD_SRC = 0x8450
+ FOG_COORDINATE = 0x8451
+ FOG_COORD = 0x8451
+ FRAGMENT_DEPTH = 0x8452
+ CURRENT_FOG_COORDINATE = 0x8453
+ CURRENT_FOG_COORD = 0x8453
+ FOG_COORDINATE_ARRAY_TYPE = 0x8454
+ FOG_COORD_ARRAY_TYPE = 0x8454
+ FOG_COORDINATE_ARRAY_STRIDE = 0x8455
+ FOG_COORD_ARRAY_STRIDE = 0x8455
+ FOG_COORDINATE_ARRAY_POINTER = 0x8456
+ FOG_COORD_ARRAY_POINTER = 0x8456
+ FOG_COORDINATE_ARRAY = 0x8457
+ FOG_COORD_ARRAY = 0x8457
+ COLOR_SUM = 0x8458
+ CURRENT_SECONDARY_COLOR = 0x8459
+ SECONDARY_COLOR_ARRAY_SIZE = 0x845A
+ SECONDARY_COLOR_ARRAY_TYPE = 0x845B
+ SECONDARY_COLOR_ARRAY_STRIDE = 0x845C
+ SECONDARY_COLOR_ARRAY_POINTER = 0x845D
+ SECONDARY_COLOR_ARRAY = 0x845E
+ CURRENT_RASTER_SECONDARY_COLOR = 0x845F
+ TEXTURE0 = 0x84C0
+ TEXTURE1 = 0x84C1
+ TEXTURE2 = 0x84C2
+ TEXTURE3 = 0x84C3
+ TEXTURE4 = 0x84C4
+ TEXTURE5 = 0x84C5
+ TEXTURE6 = 0x84C6
+ TEXTURE7 = 0x84C7
+ TEXTURE8 = 0x84C8
+ TEXTURE9 = 0x84C9
+ TEXTURE10 = 0x84CA
+ TEXTURE11 = 0x84CB
+ TEXTURE12 = 0x84CC
+ TEXTURE13 = 0x84CD
+ TEXTURE14 = 0x84CE
+ TEXTURE15 = 0x84CF
+ TEXTURE16 = 0x84D0
+ TEXTURE17 = 0x84D1
+ TEXTURE18 = 0x84D2
+ TEXTURE19 = 0x84D3
+ TEXTURE20 = 0x84D4
+ TEXTURE21 = 0x84D5
+ TEXTURE22 = 0x84D6
+ TEXTURE23 = 0x84D7
+ TEXTURE24 = 0x84D8
+ TEXTURE25 = 0x84D9
+ TEXTURE26 = 0x84DA
+ TEXTURE27 = 0x84DB
+ TEXTURE28 = 0x84DC
+ TEXTURE29 = 0x84DD
+ TEXTURE30 = 0x84DE
+ TEXTURE31 = 0x84DF
+ ACTIVE_TEXTURE = 0x84E0
+ CLIENT_ACTIVE_TEXTURE = 0x84E1
+ MAX_TEXTURE_UNITS = 0x84E2
+ TRANSPOSE_MODELVIEW_MATRIX = 0x84E3
+ TRANSPOSE_PROJECTION_MATRIX = 0x84E4
+ TRANSPOSE_TEXTURE_MATRIX = 0x84E5
+ TRANSPOSE_COLOR_MATRIX = 0x84E6
+ SUBTRACT = 0x84E7
+ MAX_RENDERBUFFER_SIZE = 0x84E8
+ COMPRESSED_ALPHA = 0x84E9
+ COMPRESSED_LUMINANCE = 0x84EA
+ COMPRESSED_LUMINANCE_ALPHA = 0x84EB
+ COMPRESSED_INTENSITY = 0x84EC
+ COMPRESSED_RGB = 0x84ED
+ COMPRESSED_RGBA = 0x84EE
+ UNIFORM_BLOCK_REFERENCED_BY_TESS_CONTROL_SHADER = 0x84F0
+ UNIFORM_BLOCK_REFERENCED_BY_TESS_EVALUATION_SHADER = 0x84F1
+ TEXTURE_RECTANGLE = 0x84F5
+ TEXTURE_BINDING_RECTANGLE = 0x84F6
+ PROXY_TEXTURE_RECTANGLE = 0x84F7
+ MAX_RECTANGLE_TEXTURE_SIZE = 0x84F8
+ DEPTH_STENCIL = 0x84F9
+ UNSIGNED_INT_24_8 = 0x84FA
+ MAX_TEXTURE_LOD_BIAS = 0x84FD
+ TEXTURE_FILTER_CONTROL = 0x8500
+ TEXTURE_LOD_BIAS = 0x8501
+ INCR_WRAP = 0x8507
+ DECR_WRAP = 0x8508
+ NORMAL_MAP = 0x8511
+ REFLECTION_MAP = 0x8512
+ TEXTURE_CUBE_MAP = 0x8513
+ TEXTURE_BINDING_CUBE_MAP = 0x8514
+ TEXTURE_CUBE_MAP_POSITIVE_X = 0x8515
+ TEXTURE_CUBE_MAP_NEGATIVE_X = 0x8516
+ TEXTURE_CUBE_MAP_POSITIVE_Y = 0x8517
+ TEXTURE_CUBE_MAP_NEGATIVE_Y = 0x8518
+ TEXTURE_CUBE_MAP_POSITIVE_Z = 0x8519
+ TEXTURE_CUBE_MAP_NEGATIVE_Z = 0x851A
+ PROXY_TEXTURE_CUBE_MAP = 0x851B
+ MAX_CUBE_MAP_TEXTURE_SIZE = 0x851C
+ COMBINE = 0x8570
+ COMBINE_RGB = 0x8571
+ COMBINE_ALPHA = 0x8572
+ RGB_SCALE = 0x8573
+ ADD_SIGNED = 0x8574
+ INTERPOLATE = 0x8575
+ CONSTANT = 0x8576
+ PRIMARY_COLOR = 0x8577
+ PREVIOUS = 0x8578
+ SOURCE0_RGB = 0x8580
+ SRC0_RGB = 0x8580
+ SOURCE1_RGB = 0x8581
+ SRC1_RGB = 0x8581
+ SOURCE2_RGB = 0x8582
+ SRC2_RGB = 0x8582
+ SOURCE0_ALPHA = 0x8588
+ SRC0_ALPHA = 0x8588
+ SOURCE1_ALPHA = 0x8589
+ SRC1_ALPHA = 0x8589
+ SOURCE2_ALPHA = 0x858A
+ SRC2_ALPHA = 0x858A
+ OPERAND0_RGB = 0x8590
+ OPERAND1_RGB = 0x8591
+ OPERAND2_RGB = 0x8592
+ OPERAND0_ALPHA = 0x8598
+ OPERAND1_ALPHA = 0x8599
+ OPERAND2_ALPHA = 0x859A
+ VERTEX_ARRAY_BINDING = 0x85B5
+ VERTEX_ATTRIB_ARRAY_ENABLED = 0x8622
+ VERTEX_ATTRIB_ARRAY_SIZE = 0x8623
+ VERTEX_ATTRIB_ARRAY_STRIDE = 0x8624
+ VERTEX_ATTRIB_ARRAY_TYPE = 0x8625
+ CURRENT_VERTEX_ATTRIB = 0x8626
+ VERTEX_PROGRAM_POINT_SIZE = 0x8642
+ PROGRAM_POINT_SIZE = 0x8642
+ VERTEX_PROGRAM_TWO_SIDE = 0x8643
+ VERTEX_ATTRIB_ARRAY_POINTER = 0x8645
+ DEPTH_CLAMP = 0x864F
+ TEXTURE_COMPRESSED_IMAGE_SIZE = 0x86A0
+ TEXTURE_COMPRESSED = 0x86A1
+ NUM_COMPRESSED_TEXTURE_FORMATS = 0x86A2
+ COMPRESSED_TEXTURE_FORMATS = 0x86A3
+ DOT3_RGB = 0x86AE
+ DOT3_RGBA = 0x86AF
+ PROGRAM_BINARY_LENGTH = 0x8741
+ VERTEX_ATTRIB_ARRAY_LONG = 0x874E
+ BUFFER_SIZE = 0x8764
+ BUFFER_USAGE = 0x8765
+ NUM_PROGRAM_BINARY_FORMATS = 0x87FE
+ PROGRAM_BINARY_FORMATS = 0x87FF
+ STENCIL_BACK_FUNC = 0x8800
+ STENCIL_BACK_FAIL = 0x8801
+ STENCIL_BACK_PASS_DEPTH_FAIL = 0x8802
+ STENCIL_BACK_PASS_DEPTH_PASS = 0x8803
+ RGBA32F = 0x8814
+ RGB32F = 0x8815
+ RGBA16F = 0x881A
+ RGB16F = 0x881B
+ MAX_DRAW_BUFFERS = 0x8824
+ DRAW_BUFFER0 = 0x8825
+ DRAW_BUFFER1 = 0x8826
+ DRAW_BUFFER2 = 0x8827
+ DRAW_BUFFER3 = 0x8828
+ DRAW_BUFFER4 = 0x8829
+ DRAW_BUFFER5 = 0x882A
+ DRAW_BUFFER6 = 0x882B
+ DRAW_BUFFER7 = 0x882C
+ DRAW_BUFFER8 = 0x882D
+ DRAW_BUFFER9 = 0x882E
+ DRAW_BUFFER10 = 0x882F
+ DRAW_BUFFER11 = 0x8830
+ DRAW_BUFFER12 = 0x8831
+ DRAW_BUFFER13 = 0x8832
+ DRAW_BUFFER14 = 0x8833
+ DRAW_BUFFER15 = 0x8834
+ BLEND_EQUATION_ALPHA = 0x883D
+ TEXTURE_DEPTH_SIZE = 0x884A
+ DEPTH_TEXTURE_MODE = 0x884B
+ TEXTURE_COMPARE_MODE = 0x884C
+ TEXTURE_COMPARE_FUNC = 0x884D
+ COMPARE_R_TO_TEXTURE = 0x884E
+ COMPARE_REF_TO_TEXTURE = 0x884E
+ TEXTURE_CUBE_MAP_SEAMLESS = 0x884F
+ POINT_SPRITE = 0x8861
+ COORD_REPLACE = 0x8862
+ QUERY_COUNTER_BITS = 0x8864
+ CURRENT_QUERY = 0x8865
+ QUERY_RESULT = 0x8866
+ QUERY_RESULT_AVAILABLE = 0x8867
+ MAX_VERTEX_ATTRIBS = 0x8869
+ VERTEX_ATTRIB_ARRAY_NORMALIZED = 0x886A
+ MAX_TESS_CONTROL_INPUT_COMPONENTS = 0x886C
+ MAX_TESS_EVALUATION_INPUT_COMPONENTS = 0x886D
+ MAX_TEXTURE_COORDS = 0x8871
+ MAX_TEXTURE_IMAGE_UNITS = 0x8872
+ GEOMETRY_SHADER_INVOCATIONS = 0x887F
+ ARRAY_BUFFER = 0x8892
+ ELEMENT_ARRAY_BUFFER = 0x8893
+ ARRAY_BUFFER_BINDING = 0x8894
+ ELEMENT_ARRAY_BUFFER_BINDING = 0x8895
+ VERTEX_ARRAY_BUFFER_BINDING = 0x8896
+ NORMAL_ARRAY_BUFFER_BINDING = 0x8897
+ COLOR_ARRAY_BUFFER_BINDING = 0x8898
+ INDEX_ARRAY_BUFFER_BINDING = 0x8899
+ TEXTURE_COORD_ARRAY_BUFFER_BINDING = 0x889A
+ EDGE_FLAG_ARRAY_BUFFER_BINDING = 0x889B
+ SECONDARY_COLOR_ARRAY_BUFFER_BINDING = 0x889C
+ FOG_COORDINATE_ARRAY_BUFFER_BINDING = 0x889D
+ FOG_COORD_ARRAY_BUFFER_BINDING = 0x889D
+ WEIGHT_ARRAY_BUFFER_BINDING = 0x889E
+ VERTEX_ATTRIB_ARRAY_BUFFER_BINDING = 0x889F
+ READ_ONLY = 0x88B8
+ WRITE_ONLY = 0x88B9
+ READ_WRITE = 0x88BA
+ BUFFER_ACCESS = 0x88BB
+ BUFFER_MAPPED = 0x88BC
+ BUFFER_MAP_POINTER = 0x88BD
+ TIME_ELAPSED = 0x88BF
+ STREAM_DRAW = 0x88E0
+ STREAM_READ = 0x88E1
+ STREAM_COPY = 0x88E2
+ STATIC_DRAW = 0x88E4
+ STATIC_READ = 0x88E5
+ STATIC_COPY = 0x88E6
+ DYNAMIC_DRAW = 0x88E8
+ DYNAMIC_READ = 0x88E9
+ DYNAMIC_COPY = 0x88EA
+ PIXEL_PACK_BUFFER = 0x88EB
+ PIXEL_UNPACK_BUFFER = 0x88EC
+ PIXEL_PACK_BUFFER_BINDING = 0x88ED
+ PIXEL_UNPACK_BUFFER_BINDING = 0x88EF
+ DEPTH24_STENCIL8 = 0x88F0
+ TEXTURE_STENCIL_SIZE = 0x88F1
+ SRC1_COLOR = 0x88F9
+ ONE_MINUS_SRC1_COLOR = 0x88FA
+ ONE_MINUS_SRC1_ALPHA = 0x88FB
+ MAX_DUAL_SOURCE_DRAW_BUFFERS = 0x88FC
+ VERTEX_ATTRIB_ARRAY_INTEGER = 0x88FD
+ VERTEX_ATTRIB_ARRAY_DIVISOR = 0x88FE
+ MAX_ARRAY_TEXTURE_LAYERS = 0x88FF
+ MIN_PROGRAM_TEXEL_OFFSET = 0x8904
+ MAX_PROGRAM_TEXEL_OFFSET = 0x8905
+ SAMPLES_PASSED = 0x8914
+ GEOMETRY_VERTICES_OUT = 0x8916
+ GEOMETRY_INPUT_TYPE = 0x8917
+ GEOMETRY_OUTPUT_TYPE = 0x8918
+ SAMPLER_BINDING = 0x8919
+ CLAMP_VERTEX_COLOR = 0x891A
+ CLAMP_FRAGMENT_COLOR = 0x891B
+ CLAMP_READ_COLOR = 0x891C
+ FIXED_ONLY = 0x891D
+ UNIFORM_BUFFER = 0x8A11
+ UNIFORM_BUFFER_BINDING = 0x8A28
+ UNIFORM_BUFFER_START = 0x8A29
+ UNIFORM_BUFFER_SIZE = 0x8A2A
+ MAX_VERTEX_UNIFORM_BLOCKS = 0x8A2B
+ MAX_GEOMETRY_UNIFORM_BLOCKS = 0x8A2C
+ MAX_FRAGMENT_UNIFORM_BLOCKS = 0x8A2D
+ MAX_COMBINED_UNIFORM_BLOCKS = 0x8A2E
+ MAX_UNIFORM_BUFFER_BINDINGS = 0x8A2F
+ MAX_UNIFORM_BLOCK_SIZE = 0x8A30
+ MAX_COMBINED_VERTEX_UNIFORM_COMPONENTS = 0x8A31
+ MAX_COMBINED_GEOMETRY_UNIFORM_COMPONENTS = 0x8A32
+ MAX_COMBINED_FRAGMENT_UNIFORM_COMPONENTS = 0x8A33
+ UNIFORM_BUFFER_OFFSET_ALIGNMENT = 0x8A34
+ ACTIVE_UNIFORM_BLOCK_MAX_NAME_LENGTH = 0x8A35
+ ACTIVE_UNIFORM_BLOCKS = 0x8A36
+ UNIFORM_TYPE = 0x8A37
+ UNIFORM_SIZE = 0x8A38
+ UNIFORM_NAME_LENGTH = 0x8A39
+ UNIFORM_BLOCK_INDEX = 0x8A3A
+ UNIFORM_OFFSET = 0x8A3B
+ UNIFORM_ARRAY_STRIDE = 0x8A3C
+ UNIFORM_MATRIX_STRIDE = 0x8A3D
+ UNIFORM_IS_ROW_MAJOR = 0x8A3E
+ UNIFORM_BLOCK_BINDING = 0x8A3F
+ UNIFORM_BLOCK_DATA_SIZE = 0x8A40
+ UNIFORM_BLOCK_NAME_LENGTH = 0x8A41
+ UNIFORM_BLOCK_ACTIVE_UNIFORMS = 0x8A42
+ UNIFORM_BLOCK_ACTIVE_UNIFORM_INDICES = 0x8A43
+ UNIFORM_BLOCK_REFERENCED_BY_VERTEX_SHADER = 0x8A44
+ UNIFORM_BLOCK_REFERENCED_BY_GEOMETRY_SHADER = 0x8A45
+ UNIFORM_BLOCK_REFERENCED_BY_FRAGMENT_SHADER = 0x8A46
+ FRAGMENT_SHADER = 0x8B30
+ VERTEX_SHADER = 0x8B31
+ MAX_FRAGMENT_UNIFORM_COMPONENTS = 0x8B49
+ MAX_VERTEX_UNIFORM_COMPONENTS = 0x8B4A
+ MAX_VARYING_FLOATS = 0x8B4B
+ MAX_VARYING_COMPONENTS = 0x8B4B
+ MAX_VERTEX_TEXTURE_IMAGE_UNITS = 0x8B4C
+ MAX_COMBINED_TEXTURE_IMAGE_UNITS = 0x8B4D
+ SHADER_TYPE = 0x8B4F
+ FLOAT_VEC2 = 0x8B50
+ FLOAT_VEC3 = 0x8B51
+ FLOAT_VEC4 = 0x8B52
+ INT_VEC2 = 0x8B53
+ INT_VEC3 = 0x8B54
+ INT_VEC4 = 0x8B55
+ BOOL = 0x8B56
+ BOOL_VEC2 = 0x8B57
+ BOOL_VEC3 = 0x8B58
+ BOOL_VEC4 = 0x8B59
+ FLOAT_MAT2 = 0x8B5A
+ FLOAT_MAT3 = 0x8B5B
+ FLOAT_MAT4 = 0x8B5C
+ SAMPLER_1D = 0x8B5D
+ SAMPLER_2D = 0x8B5E
+ SAMPLER_3D = 0x8B5F
+ SAMPLER_CUBE = 0x8B60
+ SAMPLER_1D_SHADOW = 0x8B61
+ SAMPLER_2D_SHADOW = 0x8B62
+ SAMPLER_2D_RECT = 0x8B63
+ SAMPLER_2D_RECT_SHADOW = 0x8B64
+ FLOAT_MAT2x3 = 0x8B65
+ FLOAT_MAT2x4 = 0x8B66
+ FLOAT_MAT3x2 = 0x8B67
+ FLOAT_MAT3x4 = 0x8B68
+ FLOAT_MAT4x2 = 0x8B69
+ FLOAT_MAT4x3 = 0x8B6A
+ DELETE_STATUS = 0x8B80
+ COMPILE_STATUS = 0x8B81
+ LINK_STATUS = 0x8B82
+ VALIDATE_STATUS = 0x8B83
+ INFO_LOG_LENGTH = 0x8B84
+ ATTACHED_SHADERS = 0x8B85
+ ACTIVE_UNIFORMS = 0x8B86
+ ACTIVE_UNIFORM_MAX_LENGTH = 0x8B87
+ SHADER_SOURCE_LENGTH = 0x8B88
+ ACTIVE_ATTRIBUTES = 0x8B89
+ ACTIVE_ATTRIBUTE_MAX_LENGTH = 0x8B8A
+ SHADING_LANGUAGE_VERSION = 0x8B8C
+ CURRENT_PROGRAM = 0x8B8D
+ IMPLEMENTATION_COLOR_READ_TYPE = 0x8B9A
+ IMPLEMENTATION_COLOR_READ_FORMAT = 0x8B9B
+ TEXTURE_RED_TYPE = 0x8C10
+ TEXTURE_GREEN_TYPE = 0x8C11
+ TEXTURE_BLUE_TYPE = 0x8C12
+ TEXTURE_ALPHA_TYPE = 0x8C13
+ TEXTURE_LUMINANCE_TYPE = 0x8C14
+ TEXTURE_INTENSITY_TYPE = 0x8C15
+ TEXTURE_DEPTH_TYPE = 0x8C16
+ UNSIGNED_NORMALIZED = 0x8C17
+ TEXTURE_1D_ARRAY = 0x8C18
+ PROXY_TEXTURE_1D_ARRAY = 0x8C19
+ TEXTURE_2D_ARRAY = 0x8C1A
+ PROXY_TEXTURE_2D_ARRAY = 0x8C1B
+ TEXTURE_BINDING_1D_ARRAY = 0x8C1C
+ TEXTURE_BINDING_2D_ARRAY = 0x8C1D
+ MAX_GEOMETRY_TEXTURE_IMAGE_UNITS = 0x8C29
+ TEXTURE_BUFFER = 0x8C2A
+ MAX_TEXTURE_BUFFER_SIZE = 0x8C2B
+ TEXTURE_BINDING_BUFFER = 0x8C2C
+ TEXTURE_BUFFER_DATA_STORE_BINDING = 0x8C2D
+ ANY_SAMPLES_PASSED = 0x8C2F
+ SAMPLE_SHADING = 0x8C36
+ MIN_SAMPLE_SHADING_VALUE = 0x8C37
+ R11F_G11F_B10F = 0x8C3A
+ UNSIGNED_INT_10F_11F_11F_REV = 0x8C3B
+ RGB9_E5 = 0x8C3D
+ UNSIGNED_INT_5_9_9_9_REV = 0x8C3E
+ TEXTURE_SHARED_SIZE = 0x8C3F
+ SRGB = 0x8C40
+ SRGB8 = 0x8C41
+ SRGB_ALPHA = 0x8C42
+ SRGB8_ALPHA8 = 0x8C43
+ SLUMINANCE_ALPHA = 0x8C44
+ SLUMINANCE8_ALPHA8 = 0x8C45
+ SLUMINANCE = 0x8C46
+ SLUMINANCE8 = 0x8C47
+ COMPRESSED_SRGB = 0x8C48
+ COMPRESSED_SRGB_ALPHA = 0x8C49
+ COMPRESSED_SLUMINANCE = 0x8C4A
+ COMPRESSED_SLUMINANCE_ALPHA = 0x8C4B
+ TRANSFORM_FEEDBACK_VARYING_MAX_LENGTH = 0x8C76
+ TRANSFORM_FEEDBACK_BUFFER_MODE = 0x8C7F
+ MAX_TRANSFORM_FEEDBACK_SEPARATE_COMPONENTS = 0x8C80
+ TRANSFORM_FEEDBACK_VARYINGS = 0x8C83
+ TRANSFORM_FEEDBACK_BUFFER_START = 0x8C84
+ TRANSFORM_FEEDBACK_BUFFER_SIZE = 0x8C85
+ PRIMITIVES_GENERATED = 0x8C87
+ TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN = 0x8C88
+ RASTERIZER_DISCARD = 0x8C89
+ MAX_TRANSFORM_FEEDBACK_INTERLEAVED_COMPONENTS = 0x8C8A
+ MAX_TRANSFORM_FEEDBACK_SEPARATE_ATTRIBS = 0x8C8B
+ INTERLEAVED_ATTRIBS = 0x8C8C
+ SEPARATE_ATTRIBS = 0x8C8D
+ TRANSFORM_FEEDBACK_BUFFER = 0x8C8E
+ TRANSFORM_FEEDBACK_BUFFER_BINDING = 0x8C8F
+ POINT_SPRITE_COORD_ORIGIN = 0x8CA0
+ LOWER_LEFT = 0x8CA1
+ UPPER_LEFT = 0x8CA2
+ STENCIL_BACK_REF = 0x8CA3
+ STENCIL_BACK_VALUE_MASK = 0x8CA4
+ STENCIL_BACK_WRITEMASK = 0x8CA5
+ DRAW_FRAMEBUFFER_BINDING = 0x8CA6
+ FRAMEBUFFER_BINDING = 0x8CA6
+ RENDERBUFFER_BINDING = 0x8CA7
+ READ_FRAMEBUFFER = 0x8CA8
+ DRAW_FRAMEBUFFER = 0x8CA9
+ READ_FRAMEBUFFER_BINDING = 0x8CAA
+ RENDERBUFFER_SAMPLES = 0x8CAB
+ DEPTH_COMPONENT32F = 0x8CAC
+ DEPTH32F_STENCIL8 = 0x8CAD
+ FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE = 0x8CD0
+ FRAMEBUFFER_ATTACHMENT_OBJECT_NAME = 0x8CD1
+ FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL = 0x8CD2
+ FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE = 0x8CD3
+ FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER = 0x8CD4
+ FRAMEBUFFER_COMPLETE = 0x8CD5
+ FRAMEBUFFER_INCOMPLETE_ATTACHMENT = 0x8CD6
+ FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT = 0x8CD7
+ FRAMEBUFFER_INCOMPLETE_DRAW_BUFFER = 0x8CDB
+ FRAMEBUFFER_INCOMPLETE_READ_BUFFER = 0x8CDC
+ FRAMEBUFFER_UNSUPPORTED = 0x8CDD
+ MAX_COLOR_ATTACHMENTS = 0x8CDF
+ COLOR_ATTACHMENT0 = 0x8CE0
+ COLOR_ATTACHMENT1 = 0x8CE1
+ COLOR_ATTACHMENT2 = 0x8CE2
+ COLOR_ATTACHMENT3 = 0x8CE3
+ COLOR_ATTACHMENT4 = 0x8CE4
+ COLOR_ATTACHMENT5 = 0x8CE5
+ COLOR_ATTACHMENT6 = 0x8CE6
+ COLOR_ATTACHMENT7 = 0x8CE7
+ COLOR_ATTACHMENT8 = 0x8CE8
+ COLOR_ATTACHMENT9 = 0x8CE9
+ COLOR_ATTACHMENT10 = 0x8CEA
+ COLOR_ATTACHMENT11 = 0x8CEB
+ COLOR_ATTACHMENT12 = 0x8CEC
+ COLOR_ATTACHMENT13 = 0x8CED
+ COLOR_ATTACHMENT14 = 0x8CEE
+ COLOR_ATTACHMENT15 = 0x8CEF
+ DEPTH_ATTACHMENT = 0x8D00
+ STENCIL_ATTACHMENT = 0x8D20
+ FRAMEBUFFER = 0x8D40
+ RENDERBUFFER = 0x8D41
+ RENDERBUFFER_WIDTH = 0x8D42
+ RENDERBUFFER_HEIGHT = 0x8D43
+ RENDERBUFFER_INTERNAL_FORMAT = 0x8D44
+ STENCIL_INDEX1 = 0x8D46
+ STENCIL_INDEX4 = 0x8D47
+ STENCIL_INDEX8 = 0x8D48
+ STENCIL_INDEX16 = 0x8D49
+ RENDERBUFFER_RED_SIZE = 0x8D50
+ RENDERBUFFER_GREEN_SIZE = 0x8D51
+ RENDERBUFFER_BLUE_SIZE = 0x8D52
+ RENDERBUFFER_ALPHA_SIZE = 0x8D53
+ RENDERBUFFER_DEPTH_SIZE = 0x8D54
+ RENDERBUFFER_STENCIL_SIZE = 0x8D55
+ FRAMEBUFFER_INCOMPLETE_MULTISAMPLE = 0x8D56
+ MAX_SAMPLES = 0x8D57
+ RGB565 = 0x8D62
+ PRIMITIVE_RESTART_FIXED_INDEX = 0x8D69
+ ANY_SAMPLES_PASSED_CONSERVATIVE = 0x8D6A
+ MAX_ELEMENT_INDEX = 0x8D6B
+ RGBA32UI = 0x8D70
+ RGB32UI = 0x8D71
+ RGBA16UI = 0x8D76
+ RGB16UI = 0x8D77
+ RGBA8UI = 0x8D7C
+ RGB8UI = 0x8D7D
+ RGBA32I = 0x8D82
+ RGB32I = 0x8D83
+ RGBA16I = 0x8D88
+ RGB16I = 0x8D89
+ RGBA8I = 0x8D8E
+ RGB8I = 0x8D8F
+ RED_INTEGER = 0x8D94
+ GREEN_INTEGER = 0x8D95
+ BLUE_INTEGER = 0x8D96
+ ALPHA_INTEGER = 0x8D97
+ RGB_INTEGER = 0x8D98
+ RGBA_INTEGER = 0x8D99
+ BGR_INTEGER = 0x8D9A
+ BGRA_INTEGER = 0x8D9B
+ INT_2_10_10_10_REV = 0x8D9F
+ FRAMEBUFFER_ATTACHMENT_LAYERED = 0x8DA7
+ FRAMEBUFFER_INCOMPLETE_LAYER_TARGETS = 0x8DA8
+ FLOAT_32_UNSIGNED_INT_24_8_REV = 0x8DAD
+ FRAMEBUFFER_SRGB = 0x8DB9
+ COMPRESSED_RED_RGTC1 = 0x8DBB
+ COMPRESSED_SIGNED_RED_RGTC1 = 0x8DBC
+ COMPRESSED_RG_RGTC2 = 0x8DBD
+ COMPRESSED_SIGNED_RG_RGTC2 = 0x8DBE
+ SAMPLER_1D_ARRAY = 0x8DC0
+ SAMPLER_2D_ARRAY = 0x8DC1
+ SAMPLER_BUFFER = 0x8DC2
+ SAMPLER_1D_ARRAY_SHADOW = 0x8DC3
+ SAMPLER_2D_ARRAY_SHADOW = 0x8DC4
+ SAMPLER_CUBE_SHADOW = 0x8DC5
+ UNSIGNED_INT_VEC2 = 0x8DC6
+ UNSIGNED_INT_VEC3 = 0x8DC7
+ UNSIGNED_INT_VEC4 = 0x8DC8
+ INT_SAMPLER_1D = 0x8DC9
+ INT_SAMPLER_2D = 0x8DCA
+ INT_SAMPLER_3D = 0x8DCB
+ INT_SAMPLER_CUBE = 0x8DCC
+ INT_SAMPLER_2D_RECT = 0x8DCD
+ INT_SAMPLER_1D_ARRAY = 0x8DCE
+ INT_SAMPLER_2D_ARRAY = 0x8DCF
+ INT_SAMPLER_BUFFER = 0x8DD0
+ UNSIGNED_INT_SAMPLER_1D = 0x8DD1
+ UNSIGNED_INT_SAMPLER_2D = 0x8DD2
+ UNSIGNED_INT_SAMPLER_3D = 0x8DD3
+ UNSIGNED_INT_SAMPLER_CUBE = 0x8DD4
+ UNSIGNED_INT_SAMPLER_2D_RECT = 0x8DD5
+ UNSIGNED_INT_SAMPLER_1D_ARRAY = 0x8DD6
+ UNSIGNED_INT_SAMPLER_2D_ARRAY = 0x8DD7
+ UNSIGNED_INT_SAMPLER_BUFFER = 0x8DD8
+ GEOMETRY_SHADER = 0x8DD9
+ MAX_GEOMETRY_UNIFORM_COMPONENTS = 0x8DDF
+ MAX_GEOMETRY_OUTPUT_VERTICES = 0x8DE0
+ MAX_GEOMETRY_TOTAL_OUTPUT_COMPONENTS = 0x8DE1
+ ACTIVE_SUBROUTINES = 0x8DE5
+ ACTIVE_SUBROUTINE_UNIFORMS = 0x8DE6
+ MAX_SUBROUTINES = 0x8DE7
+ MAX_SUBROUTINE_UNIFORM_LOCATIONS = 0x8DE8
+ LOW_FLOAT = 0x8DF0
+ MEDIUM_FLOAT = 0x8DF1
+ HIGH_FLOAT = 0x8DF2
+ LOW_INT = 0x8DF3
+ MEDIUM_INT = 0x8DF4
+ HIGH_INT = 0x8DF5
+ SHADER_BINARY_FORMATS = 0x8DF8
+ NUM_SHADER_BINARY_FORMATS = 0x8DF9
+ SHADER_COMPILER = 0x8DFA
+ MAX_VERTEX_UNIFORM_VECTORS = 0x8DFB
+ MAX_VARYING_VECTORS = 0x8DFC
+ MAX_FRAGMENT_UNIFORM_VECTORS = 0x8DFD
+ QUERY_WAIT = 0x8E13
+ QUERY_NO_WAIT = 0x8E14
+ QUERY_BY_REGION_WAIT = 0x8E15
+ QUERY_BY_REGION_NO_WAIT = 0x8E16
+ MAX_COMBINED_TESS_CONTROL_UNIFORM_COMPONENTS = 0x8E1E
+ MAX_COMBINED_TESS_EVALUATION_UNIFORM_COMPONENTS = 0x8E1F
+ TRANSFORM_FEEDBACK = 0x8E22
+ TRANSFORM_FEEDBACK_BUFFER_PAUSED = 0x8E23
+ TRANSFORM_FEEDBACK_BUFFER_ACTIVE = 0x8E24
+ TRANSFORM_FEEDBACK_BINDING = 0x8E25
+ TIMESTAMP = 0x8E28
+ TEXTURE_SWIZZLE_R = 0x8E42
+ TEXTURE_SWIZZLE_G = 0x8E43
+ TEXTURE_SWIZZLE_B = 0x8E44
+ TEXTURE_SWIZZLE_A = 0x8E45
+ TEXTURE_SWIZZLE_RGBA = 0x8E46
+ ACTIVE_SUBROUTINE_UNIFORM_LOCATIONS = 0x8E47
+ ACTIVE_SUBROUTINE_MAX_LENGTH = 0x8E48
+ ACTIVE_SUBROUTINE_UNIFORM_MAX_LENGTH = 0x8E49
+ NUM_COMPATIBLE_SUBROUTINES = 0x8E4A
+ COMPATIBLE_SUBROUTINES = 0x8E4B
+ QUADS_FOLLOW_PROVOKING_VERTEX_CONVENTION = 0x8E4C
+ FIRST_VERTEX_CONVENTION = 0x8E4D
+ LAST_VERTEX_CONVENTION = 0x8E4E
+ PROVOKING_VERTEX = 0x8E4F
+ SAMPLE_POSITION = 0x8E50
+ SAMPLE_MASK = 0x8E51
+ SAMPLE_MASK_VALUE = 0x8E52
+ MAX_SAMPLE_MASK_WORDS = 0x8E59
+ MAX_GEOMETRY_SHADER_INVOCATIONS = 0x8E5A
+ MIN_FRAGMENT_INTERPOLATION_OFFSET = 0x8E5B
+ MAX_FRAGMENT_INTERPOLATION_OFFSET = 0x8E5C
+ FRAGMENT_INTERPOLATION_OFFSET_BITS = 0x8E5D
+ MIN_PROGRAM_TEXTURE_GATHER_OFFSET = 0x8E5E
+ MAX_PROGRAM_TEXTURE_GATHER_OFFSET = 0x8E5F
+ MAX_TRANSFORM_FEEDBACK_BUFFERS = 0x8E70
+ MAX_VERTEX_STREAMS = 0x8E71
+ PATCH_VERTICES = 0x8E72
+ PATCH_DEFAULT_INNER_LEVEL = 0x8E73
+ PATCH_DEFAULT_OUTER_LEVEL = 0x8E74
+ TESS_CONTROL_OUTPUT_VERTICES = 0x8E75
+ TESS_GEN_MODE = 0x8E76
+ TESS_GEN_SPACING = 0x8E77
+ TESS_GEN_VERTEX_ORDER = 0x8E78
+ TESS_GEN_POINT_MODE = 0x8E79
+ ISOLINES = 0x8E7A
+ FRACTIONAL_ODD = 0x8E7B
+ FRACTIONAL_EVEN = 0x8E7C
+ MAX_PATCH_VERTICES = 0x8E7D
+ MAX_TESS_GEN_LEVEL = 0x8E7E
+ MAX_TESS_CONTROL_UNIFORM_COMPONENTS = 0x8E7F
+ MAX_TESS_EVALUATION_UNIFORM_COMPONENTS = 0x8E80
+ MAX_TESS_CONTROL_TEXTURE_IMAGE_UNITS = 0x8E81
+ MAX_TESS_EVALUATION_TEXTURE_IMAGE_UNITS = 0x8E82
+ MAX_TESS_CONTROL_OUTPUT_COMPONENTS = 0x8E83
+ MAX_TESS_PATCH_COMPONENTS = 0x8E84
+ MAX_TESS_CONTROL_TOTAL_OUTPUT_COMPONENTS = 0x8E85
+ MAX_TESS_EVALUATION_OUTPUT_COMPONENTS = 0x8E86
+ TESS_EVALUATION_SHADER = 0x8E87
+ TESS_CONTROL_SHADER = 0x8E88
+ MAX_TESS_CONTROL_UNIFORM_BLOCKS = 0x8E89
+ MAX_TESS_EVALUATION_UNIFORM_BLOCKS = 0x8E8A
+ COMPRESSED_RGBA_BPTC_UNORM = 0x8E8C
+ COMPRESSED_SRGB_ALPHA_BPTC_UNORM = 0x8E8D
+ COMPRESSED_RGB_BPTC_SIGNED_FLOAT = 0x8E8E
+ COMPRESSED_RGB_BPTC_UNSIGNED_FLOAT = 0x8E8F
+ COPY_READ_BUFFER = 0x8F36
+ COPY_WRITE_BUFFER = 0x8F37
+ MAX_IMAGE_UNITS = 0x8F38
+ MAX_COMBINED_IMAGE_UNITS_AND_FRAGMENT_OUTPUTS = 0x8F39
+ MAX_COMBINED_SHADER_OUTPUT_RESOURCES = 0x8F39
+ IMAGE_BINDING_NAME = 0x8F3A
+ IMAGE_BINDING_LEVEL = 0x8F3B
+ IMAGE_BINDING_LAYERED = 0x8F3C
+ IMAGE_BINDING_LAYER = 0x8F3D
+ IMAGE_BINDING_ACCESS = 0x8F3E
+ DRAW_INDIRECT_BUFFER = 0x8F3F
+ DRAW_INDIRECT_BUFFER_BINDING = 0x8F43
+ DOUBLE_MAT2 = 0x8F46
+ DOUBLE_MAT3 = 0x8F47
+ DOUBLE_MAT4 = 0x8F48
+ DOUBLE_MAT2x3 = 0x8F49
+ DOUBLE_MAT2x4 = 0x8F4A
+ DOUBLE_MAT3x2 = 0x8F4B
+ DOUBLE_MAT3x4 = 0x8F4C
+ DOUBLE_MAT4x2 = 0x8F4D
+ DOUBLE_MAT4x3 = 0x8F4E
+ VERTEX_BINDING_BUFFER = 0x8F4F
+ R8_SNORM = 0x8F94
+ RG8_SNORM = 0x8F95
+ RGB8_SNORM = 0x8F96
+ RGBA8_SNORM = 0x8F97
+ R16_SNORM = 0x8F98
+ RG16_SNORM = 0x8F99
+ RGB16_SNORM = 0x8F9A
+ RGBA16_SNORM = 0x8F9B
+ SIGNED_NORMALIZED = 0x8F9C
+ PRIMITIVE_RESTART = 0x8F9D
+ PRIMITIVE_RESTART_INDEX = 0x8F9E
+ DOUBLE_VEC2 = 0x8FFC
+ DOUBLE_VEC3 = 0x8FFD
+ DOUBLE_VEC4 = 0x8FFE
+ TEXTURE_CUBE_MAP_ARRAY = 0x9009
+ TEXTURE_BINDING_CUBE_MAP_ARRAY = 0x900A
+ PROXY_TEXTURE_CUBE_MAP_ARRAY = 0x900B
+ SAMPLER_CUBE_MAP_ARRAY = 0x900C
+ SAMPLER_CUBE_MAP_ARRAY_SHADOW = 0x900D
+ INT_SAMPLER_CUBE_MAP_ARRAY = 0x900E
+ UNSIGNED_INT_SAMPLER_CUBE_MAP_ARRAY = 0x900F
+ IMAGE_1D = 0x904C
+ IMAGE_2D = 0x904D
+ IMAGE_3D = 0x904E
+ IMAGE_2D_RECT = 0x904F
+ IMAGE_CUBE = 0x9050
+ IMAGE_BUFFER = 0x9051
+ IMAGE_1D_ARRAY = 0x9052
+ IMAGE_2D_ARRAY = 0x9053
+ IMAGE_CUBE_MAP_ARRAY = 0x9054
+ IMAGE_2D_MULTISAMPLE = 0x9055
+ IMAGE_2D_MULTISAMPLE_ARRAY = 0x9056
+ INT_IMAGE_1D = 0x9057
+ INT_IMAGE_2D = 0x9058
+ INT_IMAGE_3D = 0x9059
+ INT_IMAGE_2D_RECT = 0x905A
+ INT_IMAGE_CUBE = 0x905B
+ INT_IMAGE_BUFFER = 0x905C
+ INT_IMAGE_1D_ARRAY = 0x905D
+ INT_IMAGE_2D_ARRAY = 0x905E
+ INT_IMAGE_CUBE_MAP_ARRAY = 0x905F
+ INT_IMAGE_2D_MULTISAMPLE = 0x9060
+ INT_IMAGE_2D_MULTISAMPLE_ARRAY = 0x9061
+ UNSIGNED_INT_IMAGE_1D = 0x9062
+ UNSIGNED_INT_IMAGE_2D = 0x9063
+ UNSIGNED_INT_IMAGE_3D = 0x9064
+ UNSIGNED_INT_IMAGE_2D_RECT = 0x9065
+ UNSIGNED_INT_IMAGE_CUBE = 0x9066
+ UNSIGNED_INT_IMAGE_BUFFER = 0x9067
+ UNSIGNED_INT_IMAGE_1D_ARRAY = 0x9068
+ UNSIGNED_INT_IMAGE_2D_ARRAY = 0x9069
+ UNSIGNED_INT_IMAGE_CUBE_MAP_ARRAY = 0x906A
+ UNSIGNED_INT_IMAGE_2D_MULTISAMPLE = 0x906B
+ UNSIGNED_INT_IMAGE_2D_MULTISAMPLE_ARRAY = 0x906C
+ MAX_IMAGE_SAMPLES = 0x906D
+ IMAGE_BINDING_FORMAT = 0x906E
+ RGB10_A2UI = 0x906F
+ MIN_MAP_BUFFER_ALIGNMENT = 0x90BC
+ IMAGE_FORMAT_COMPATIBILITY_TYPE = 0x90C7
+ IMAGE_FORMAT_COMPATIBILITY_BY_SIZE = 0x90C8
+ IMAGE_FORMAT_COMPATIBILITY_BY_CLASS = 0x90C9
+ MAX_VERTEX_IMAGE_UNIFORMS = 0x90CA
+ MAX_TESS_CONTROL_IMAGE_UNIFORMS = 0x90CB
+ MAX_TESS_EVALUATION_IMAGE_UNIFORMS = 0x90CC
+ MAX_GEOMETRY_IMAGE_UNIFORMS = 0x90CD
+ MAX_FRAGMENT_IMAGE_UNIFORMS = 0x90CE
+ MAX_COMBINED_IMAGE_UNIFORMS = 0x90CF
+ SHADER_STORAGE_BUFFER = 0x90D2
+ SHADER_STORAGE_BUFFER_BINDING = 0x90D3
+ SHADER_STORAGE_BUFFER_START = 0x90D4
+ SHADER_STORAGE_BUFFER_SIZE = 0x90D5
+ MAX_VERTEX_SHADER_STORAGE_BLOCKS = 0x90D6
+ MAX_GEOMETRY_SHADER_STORAGE_BLOCKS = 0x90D7
+ MAX_TESS_CONTROL_SHADER_STORAGE_BLOCKS = 0x90D8
+ MAX_TESS_EVALUATION_SHADER_STORAGE_BLOCKS = 0x90D9
+ MAX_FRAGMENT_SHADER_STORAGE_BLOCKS = 0x90DA
+ MAX_COMPUTE_SHADER_STORAGE_BLOCKS = 0x90DB
+ MAX_COMBINED_SHADER_STORAGE_BLOCKS = 0x90DC
+ MAX_SHADER_STORAGE_BUFFER_BINDINGS = 0x90DD
+ MAX_SHADER_STORAGE_BLOCK_SIZE = 0x90DE
+ SHADER_STORAGE_BUFFER_OFFSET_ALIGNMENT = 0x90DF
+ DEPTH_STENCIL_TEXTURE_MODE = 0x90EA
+ MAX_COMPUTE_WORK_GROUP_INVOCATIONS = 0x90EB
+ UNIFORM_BLOCK_REFERENCED_BY_COMPUTE_SHADER = 0x90EC
+ ATOMIC_COUNTER_BUFFER_REFERENCED_BY_COMPUTE_SHADER = 0x90ED
+ DISPATCH_INDIRECT_BUFFER = 0x90EE
+ DISPATCH_INDIRECT_BUFFER_BINDING = 0x90EF
+ TEXTURE_2D_MULTISAMPLE = 0x9100
+ PROXY_TEXTURE_2D_MULTISAMPLE = 0x9101
+ TEXTURE_2D_MULTISAMPLE_ARRAY = 0x9102
+ PROXY_TEXTURE_2D_MULTISAMPLE_ARRAY = 0x9103
+ TEXTURE_BINDING_2D_MULTISAMPLE = 0x9104
+ TEXTURE_BINDING_2D_MULTISAMPLE_ARRAY = 0x9105
+ TEXTURE_SAMPLES = 0x9106
+ TEXTURE_FIXED_SAMPLE_LOCATIONS = 0x9107
+ SAMPLER_2D_MULTISAMPLE = 0x9108
+ INT_SAMPLER_2D_MULTISAMPLE = 0x9109
+ UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE = 0x910A
+ SAMPLER_2D_MULTISAMPLE_ARRAY = 0x910B
+ INT_SAMPLER_2D_MULTISAMPLE_ARRAY = 0x910C
+ UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE_ARRAY = 0x910D
+ MAX_COLOR_TEXTURE_SAMPLES = 0x910E
+ MAX_DEPTH_TEXTURE_SAMPLES = 0x910F
+ MAX_INTEGER_SAMPLES = 0x9110
+ MAX_SERVER_WAIT_TIMEOUT = 0x9111
+ OBJECT_TYPE = 0x9112
+ SYNC_CONDITION = 0x9113
+ SYNC_STATUS = 0x9114
+ SYNC_FLAGS = 0x9115
+ SYNC_FENCE = 0x9116
+ SYNC_GPU_COMMANDS_COMPLETE = 0x9117
+ UNSIGNALED = 0x9118
+ SIGNALED = 0x9119
+ ALREADY_SIGNALED = 0x911A
+ TIMEOUT_EXPIRED = 0x911B
+ CONDITION_SATISFIED = 0x911C
+ WAIT_FAILED = 0x911D
+ BUFFER_ACCESS_FLAGS = 0x911F
+ BUFFER_MAP_LENGTH = 0x9120
+ BUFFER_MAP_OFFSET = 0x9121
+ MAX_VERTEX_OUTPUT_COMPONENTS = 0x9122
+ MAX_GEOMETRY_INPUT_COMPONENTS = 0x9123
+ MAX_GEOMETRY_OUTPUT_COMPONENTS = 0x9124
+ MAX_FRAGMENT_INPUT_COMPONENTS = 0x9125
+ CONTEXT_PROFILE_MASK = 0x9126
+ UNPACK_COMPRESSED_BLOCK_WIDTH = 0x9127
+ UNPACK_COMPRESSED_BLOCK_HEIGHT = 0x9128
+ UNPACK_COMPRESSED_BLOCK_DEPTH = 0x9129
+ UNPACK_COMPRESSED_BLOCK_SIZE = 0x912A
+ PACK_COMPRESSED_BLOCK_WIDTH = 0x912B
+ PACK_COMPRESSED_BLOCK_HEIGHT = 0x912C
+ PACK_COMPRESSED_BLOCK_DEPTH = 0x912D
+ PACK_COMPRESSED_BLOCK_SIZE = 0x912E
+ TEXTURE_IMMUTABLE_FORMAT = 0x912F
+ MAX_DEBUG_MESSAGE_LENGTH = 0x9143
+ MAX_DEBUG_LOGGED_MESSAGES = 0x9144
+ DEBUG_LOGGED_MESSAGES = 0x9145
+ DEBUG_SEVERITY_HIGH = 0x9146
+ DEBUG_SEVERITY_MEDIUM = 0x9147
+ DEBUG_SEVERITY_LOW = 0x9148
+ TEXTURE_BUFFER_OFFSET = 0x919D
+ TEXTURE_BUFFER_SIZE = 0x919E
+ TEXTURE_BUFFER_OFFSET_ALIGNMENT = 0x919F
+ COMPUTE_SHADER = 0x91B9
+ MAX_COMPUTE_UNIFORM_BLOCKS = 0x91BB
+ MAX_COMPUTE_TEXTURE_IMAGE_UNITS = 0x91BC
+ MAX_COMPUTE_IMAGE_UNIFORMS = 0x91BD
+ MAX_COMPUTE_WORK_GROUP_COUNT = 0x91BE
+ MAX_COMPUTE_WORK_GROUP_SIZE = 0x91BF
+ COMPRESSED_R11_EAC = 0x9270
+ COMPRESSED_SIGNED_R11_EAC = 0x9271
+ COMPRESSED_RG11_EAC = 0x9272
+ COMPRESSED_SIGNED_RG11_EAC = 0x9273
+ COMPRESSED_RGB8_ETC2 = 0x9274
+ COMPRESSED_SRGB8_ETC2 = 0x9275
+ COMPRESSED_RGB8_PUNCHTHROUGH_ALPHA1_ETC2 = 0x9276
+ COMPRESSED_SRGB8_PUNCHTHROUGH_ALPHA1_ETC2 = 0x9277
+ COMPRESSED_RGBA8_ETC2_EAC = 0x9278
+ COMPRESSED_SRGB8_ALPHA8_ETC2_EAC = 0x9279
+ ATOMIC_COUNTER_BUFFER = 0x92C0
+ ATOMIC_COUNTER_BUFFER_BINDING = 0x92C1
+ ATOMIC_COUNTER_BUFFER_START = 0x92C2
+ ATOMIC_COUNTER_BUFFER_SIZE = 0x92C3
+ ATOMIC_COUNTER_BUFFER_DATA_SIZE = 0x92C4
+ ATOMIC_COUNTER_BUFFER_ACTIVE_ATOMIC_COUNTERS = 0x92C5
+ ATOMIC_COUNTER_BUFFER_ACTIVE_ATOMIC_COUNTER_INDICES = 0x92C6
+ ATOMIC_COUNTER_BUFFER_REFERENCED_BY_VERTEX_SHADER = 0x92C7
+ ATOMIC_COUNTER_BUFFER_REFERENCED_BY_TESS_CONTROL_SHADER = 0x92C8
+ ATOMIC_COUNTER_BUFFER_REFERENCED_BY_TESS_EVALUATION_SHADER = 0x92C9
+ ATOMIC_COUNTER_BUFFER_REFERENCED_BY_GEOMETRY_SHADER = 0x92CA
+ ATOMIC_COUNTER_BUFFER_REFERENCED_BY_FRAGMENT_SHADER = 0x92CB
+ MAX_VERTEX_ATOMIC_COUNTER_BUFFERS = 0x92CC
+ MAX_TESS_CONTROL_ATOMIC_COUNTER_BUFFERS = 0x92CD
+ MAX_TESS_EVALUATION_ATOMIC_COUNTER_BUFFERS = 0x92CE
+ MAX_GEOMETRY_ATOMIC_COUNTER_BUFFERS = 0x92CF
+ MAX_FRAGMENT_ATOMIC_COUNTER_BUFFERS = 0x92D0
+ MAX_COMBINED_ATOMIC_COUNTER_BUFFERS = 0x92D1
+ MAX_VERTEX_ATOMIC_COUNTERS = 0x92D2
+ MAX_TESS_CONTROL_ATOMIC_COUNTERS = 0x92D3
+ MAX_TESS_EVALUATION_ATOMIC_COUNTERS = 0x92D4
+ MAX_GEOMETRY_ATOMIC_COUNTERS = 0x92D5
+ MAX_FRAGMENT_ATOMIC_COUNTERS = 0x92D6
+ MAX_COMBINED_ATOMIC_COUNTERS = 0x92D7
+ MAX_ATOMIC_COUNTER_BUFFER_SIZE = 0x92D8
+ ACTIVE_ATOMIC_COUNTER_BUFFERS = 0x92D9
+ UNIFORM_ATOMIC_COUNTER_BUFFER_INDEX = 0x92DA
+ UNSIGNED_INT_ATOMIC_COUNTER = 0x92DB
+ MAX_ATOMIC_COUNTER_BUFFER_BINDINGS = 0x92DC
+ DEBUG_OUTPUT = 0x92E0
+ UNIFORM = 0x92E1
+ UNIFORM_BLOCK = 0x92E2
+ PROGRAM_INPUT = 0x92E3
+ PROGRAM_OUTPUT = 0x92E4
+ BUFFER_VARIABLE = 0x92E5
+ SHADER_STORAGE_BLOCK = 0x92E6
+ IS_PER_PATCH = 0x92E7
+ VERTEX_SUBROUTINE = 0x92E8
+ TESS_CONTROL_SUBROUTINE = 0x92E9
+ TESS_EVALUATION_SUBROUTINE = 0x92EA
+ GEOMETRY_SUBROUTINE = 0x92EB
+ FRAGMENT_SUBROUTINE = 0x92EC
+ COMPUTE_SUBROUTINE = 0x92ED
+ VERTEX_SUBROUTINE_UNIFORM = 0x92EE
+ TESS_CONTROL_SUBROUTINE_UNIFORM = 0x92EF
+ TESS_EVALUATION_SUBROUTINE_UNIFORM = 0x92F0
+ GEOMETRY_SUBROUTINE_UNIFORM = 0x92F1
+ FRAGMENT_SUBROUTINE_UNIFORM = 0x92F2
+ COMPUTE_SUBROUTINE_UNIFORM = 0x92F3
+ TRANSFORM_FEEDBACK_VARYING = 0x92F4
+ ACTIVE_RESOURCES = 0x92F5
+ MAX_NAME_LENGTH = 0x92F6
+ MAX_NUM_ACTIVE_VARIABLES = 0x92F7
+ MAX_NUM_COMPATIBLE_SUBROUTINES = 0x92F8
+ NAME_LENGTH = 0x92F9
+ TYPE = 0x92FA
+ ARRAY_SIZE = 0x92FB
+ OFFSET = 0x92FC
+ BLOCK_INDEX = 0x92FD
+ ARRAY_STRIDE = 0x92FE
+ MATRIX_STRIDE = 0x92FF
+ IS_ROW_MAJOR = 0x9300
+ ATOMIC_COUNTER_BUFFER_INDEX = 0x9301
+ BUFFER_BINDING = 0x9302
+ BUFFER_DATA_SIZE = 0x9303
+ NUM_ACTIVE_VARIABLES = 0x9304
+ ACTIVE_VARIABLES = 0x9305
+ REFERENCED_BY_VERTEX_SHADER = 0x9306
+ REFERENCED_BY_TESS_CONTROL_SHADER = 0x9307
+ REFERENCED_BY_TESS_EVALUATION_SHADER = 0x9308
+ REFERENCED_BY_GEOMETRY_SHADER = 0x9309
+ REFERENCED_BY_FRAGMENT_SHADER = 0x930A
+ REFERENCED_BY_COMPUTE_SHADER = 0x930B
+ TOP_LEVEL_ARRAY_SIZE = 0x930C
+ TOP_LEVEL_ARRAY_STRIDE = 0x930D
+ LOCATION = 0x930E
+ LOCATION_INDEX = 0x930F
+ FRAMEBUFFER_DEFAULT_WIDTH = 0x9310
+ FRAMEBUFFER_DEFAULT_HEIGHT = 0x9311
+ FRAMEBUFFER_DEFAULT_LAYERS = 0x9312
+ FRAMEBUFFER_DEFAULT_SAMPLES = 0x9313
+ FRAMEBUFFER_DEFAULT_FIXED_SAMPLE_LOCATIONS = 0x9314
+ MAX_FRAMEBUFFER_WIDTH = 0x9315
+ MAX_FRAMEBUFFER_HEIGHT = 0x9316
+ MAX_FRAMEBUFFER_LAYERS = 0x9317
+ MAX_FRAMEBUFFER_SAMPLES = 0x9318
+ NUM_SAMPLE_COUNTS = 0x9380
+)
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glViewport.xml
+func (gl *GL) Viewport(x, y, width, height int) {
+ C.gl4_3compat_glViewport(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// DepthRange specifies the mapping of depth values from normalized device
+// coordinates to window coordinates.
+//
+// Parameter nearVal specifies the mapping of the near clipping plane to window
+// coordinates (defaults to 0), while farVal specifies the mapping of the far
+// clipping plane to window coordinates (defaults to 1).
+//
+// After clipping and division by w, depth coordinates range from -1 to 1,
+// corresponding to the near and far clipping planes. DepthRange specifies a
+// linear mapping of the normalized depth coordinates in this range to window
+// depth coordinates. Regardless of the actual depth buffer implementation,
+// window coordinate depth values are treated as though they range from 0 through 1
+// (like color components). Thus, the values accepted by DepthRange are both
+// clamped to this range before they are accepted.
+//
+// The default setting of (0, 1) maps the near plane to 0 and the far plane to 1.
+// With this mapping, the depth buffer range is fully utilized.
+//
+// It is not necessary that nearVal be less than farVal. Reverse mappings such as
+// nearVal 1, and farVal 0 are acceptable.
+//
+// GL.INVALID_OPERATION is generated if DepthRange is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) DepthRange(nearVal, farVal float64) {
+ C.gl4_3compat_glDepthRange(gl.funcs, C.GLdouble(nearVal), C.GLdouble(farVal))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsEnabled.xml
+func (gl *GL) IsEnabled(cap glbase.Enum) bool {
+ glresult := C.gl4_3compat_glIsEnabled(gl.funcs, C.GLenum(cap))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexLevelParameteriv.xml
+func (gl *GL) GetTexLevelParameteriv(target glbase.Enum, level int, pname glbase.Enum, params []int32) {
+ C.gl4_3compat_glGetTexLevelParameteriv(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexLevelParameterfv.xml
+func (gl *GL) GetTexLevelParameterfv(target glbase.Enum, level int, pname glbase.Enum, params []float32) {
+ C.gl4_3compat_glGetTexLevelParameterfv(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexParameteriv.xml
+func (gl *GL) GetTexParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl4_3compat_glGetTexParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexParameterfv.xml
+func (gl *GL) GetTexParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl4_3compat_glGetTexParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexImage.xml
+func (gl *GL) GetTexImage(target glbase.Enum, level int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3compat_glGetTexImage(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetIntegerv.xml
+func (gl *GL) GetIntegerv(pname glbase.Enum, params []int32) {
+ C.gl4_3compat_glGetIntegerv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetFloatv.xml
+func (gl *GL) GetFloatv(pname glbase.Enum, params []float32) {
+ C.gl4_3compat_glGetFloatv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetError.xml
+func (gl *GL) GetError() glbase.Enum {
+ glresult := C.gl4_3compat_glGetError(gl.funcs)
+ return glbase.Enum(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetDoublev.xml
+func (gl *GL) GetDoublev(pname glbase.Enum, params []float64) {
+ C.gl4_3compat_glGetDoublev(gl.funcs, C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetBooleanv.xml
+func (gl *GL) GetBooleanv(pname glbase.Enum, params []bool) {
+ C.gl4_3compat_glGetBooleanv(gl.funcs, C.GLenum(pname), (*C.GLboolean)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glReadPixels.xml
+func (gl *GL) ReadPixels(x, y, width, height int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3compat_glReadPixels(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glReadBuffer.xml
+func (gl *GL) ReadBuffer(mode glbase.Enum) {
+ C.gl4_3compat_glReadBuffer(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPixelStorei.xml
+func (gl *GL) PixelStorei(pname glbase.Enum, param int32) {
+ C.gl4_3compat_glPixelStorei(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPixelStoref.xml
+func (gl *GL) PixelStoref(pname glbase.Enum, param float32) {
+ C.gl4_3compat_glPixelStoref(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDepthFunc.xml
+func (gl *GL) DepthFunc(glfunc glbase.Enum) {
+ C.gl4_3compat_glDepthFunc(gl.funcs, C.GLenum(glfunc))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glStencilOp.xml
+func (gl *GL) StencilOp(fail, zfail, zpass glbase.Enum) {
+ C.gl4_3compat_glStencilOp(gl.funcs, C.GLenum(fail), C.GLenum(zfail), C.GLenum(zpass))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glStencilFunc.xml
+func (gl *GL) StencilFunc(glfunc glbase.Enum, ref int32, mask uint32) {
+ C.gl4_3compat_glStencilFunc(gl.funcs, C.GLenum(glfunc), C.GLint(ref), C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLogicOp.xml
+func (gl *GL) LogicOp(opcode glbase.Enum) {
+ C.gl4_3compat_glLogicOp(gl.funcs, C.GLenum(opcode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendFunc.xml
+func (gl *GL) BlendFunc(sfactor, dfactor glbase.Enum) {
+ C.gl4_3compat_glBlendFunc(gl.funcs, C.GLenum(sfactor), C.GLenum(dfactor))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFlush.xml
+func (gl *GL) Flush() {
+ C.gl4_3compat_glFlush(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFinish.xml
+func (gl *GL) Finish() {
+ C.gl4_3compat_glFinish(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEnable.xml
+func (gl *GL) Enable(cap glbase.Enum) {
+ C.gl4_3compat_glEnable(gl.funcs, C.GLenum(cap))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDisable.xml
+func (gl *GL) Disable(cap glbase.Enum) {
+ C.gl4_3compat_glDisable(gl.funcs, C.GLenum(cap))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDepthMask.xml
+func (gl *GL) DepthMask(flag bool) {
+ C.gl4_3compat_glDepthMask(gl.funcs, *(*C.GLboolean)(unsafe.Pointer(&flag)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorMask.xml
+func (gl *GL) ColorMask(red, green, blue, alpha bool) {
+ C.gl4_3compat_glColorMask(gl.funcs, *(*C.GLboolean)(unsafe.Pointer(&red)), *(*C.GLboolean)(unsafe.Pointer(&green)), *(*C.GLboolean)(unsafe.Pointer(&blue)), *(*C.GLboolean)(unsafe.Pointer(&alpha)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glStencilMask.xml
+func (gl *GL) StencilMask(mask uint32) {
+ C.gl4_3compat_glStencilMask(gl.funcs, C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearDepth.xml
+func (gl *GL) ClearDepth(depth float64) {
+ C.gl4_3compat_glClearDepth(gl.funcs, C.GLdouble(depth))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearStencil.xml
+func (gl *GL) ClearStencil(s int32) {
+ C.gl4_3compat_glClearStencil(gl.funcs, C.GLint(s))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearColor.xml
+func (gl *GL) ClearColor(red, green, blue, alpha float32) {
+ C.gl4_3compat_glClearColor(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClear.xml
+func (gl *GL) Clear(mask glbase.Bitfield) {
+ C.gl4_3compat_glClear(gl.funcs, C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawBuffer.xml
+func (gl *GL) DrawBuffer(mode glbase.Enum) {
+ C.gl4_3compat_glDrawBuffer(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexImage2D.xml
+func (gl *GL) TexImage2D(target glbase.Enum, level int, internalFormat int32, width, height, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3compat_glTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexImage1D.xml
+func (gl *GL) TexImage1D(target glbase.Enum, level int, internalFormat int32, width, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3compat_glTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexParameteriv.xml
+func (gl *GL) TexParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl4_3compat_glTexParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexParameteri.xml
+func (gl *GL) TexParameteri(target, pname glbase.Enum, param int32) {
+ C.gl4_3compat_glTexParameteri(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexParameterfv.xml
+func (gl *GL) TexParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl4_3compat_glTexParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexParameterf.xml
+func (gl *GL) TexParameterf(target, pname glbase.Enum, param float32) {
+ C.gl4_3compat_glTexParameterf(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glScissor.xml
+func (gl *GL) Scissor(x, y, width, height int) {
+ C.gl4_3compat_glScissor(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPolygonMode.xml
+func (gl *GL) PolygonMode(face, mode glbase.Enum) {
+ C.gl4_3compat_glPolygonMode(gl.funcs, C.GLenum(face), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPointSize.xml
+func (gl *GL) PointSize(size float32) {
+ C.gl4_3compat_glPointSize(gl.funcs, C.GLfloat(size))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLineWidth.xml
+func (gl *GL) LineWidth(width float32) {
+ C.gl4_3compat_glLineWidth(gl.funcs, C.GLfloat(width))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glHint.xml
+func (gl *GL) Hint(target, mode glbase.Enum) {
+ C.gl4_3compat_glHint(gl.funcs, C.GLenum(target), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFrontFace.xml
+func (gl *GL) FrontFace(mode glbase.Enum) {
+ C.gl4_3compat_glFrontFace(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCullFace.xml
+func (gl *GL) CullFace(mode glbase.Enum) {
+ C.gl4_3compat_glCullFace(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIndexubv.xml
+func (gl *GL) Indexubv(c []uint8) {
+ C.gl4_3compat_glIndexubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIndexub.xml
+func (gl *GL) Indexub(c uint8) {
+ C.gl4_3compat_glIndexub(gl.funcs, C.GLubyte(c))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsTexture.xml
+func (gl *GL) IsTexture(texture glbase.Texture) bool {
+ glresult := C.gl4_3compat_glIsTexture(gl.funcs, C.GLuint(texture))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// GenTextures returns n texture names in textures. There is no guarantee
+// that the names form a contiguous set of integers; however, it is
+// guaranteed that none of the returned names was in use immediately before
+// the call to GenTextures.
+//
+// The generated textures have no dimensionality; they assume the
+// dimensionality of the texture target to which they are first bound (see
+// BindTexture).
+//
+// Texture names returned by a call to GenTextures are not returned by
+// subsequent calls, unless they are first deleted with DeleteTextures.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// GenTextures is available in GL version 2.0 or greater.
+func (gl *GL) GenTextures(n int) []glbase.Texture {
+ if n == 0 {
+ return nil
+ }
+ textures := make([]glbase.Texture, n)
+ C.gl4_3compat_glGenTextures(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])))
+ return textures
+}
+
+// DeleteTextures deletes the textures objects whose names are stored
+// in the textures slice. After a texture is deleted, it has no contents or
+// dimensionality, and its name is free for reuse (for example by
+// GenTextures). If a texture that is currently bound is deleted, the binding
+// reverts to 0 (the default texture).
+//
+// DeleteTextures silently ignores 0's and names that do not correspond to
+// existing textures.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// DeleteTextures is available in GL version 2.0 or greater.
+func (gl *GL) DeleteTextures(textures []glbase.Texture) {
+ n := len(textures)
+ if n == 0 {
+ return
+ }
+ C.gl4_3compat_glDeleteTextures(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindTexture.xml
+func (gl *GL) BindTexture(target glbase.Enum, texture glbase.Texture) {
+ C.gl4_3compat_glBindTexture(gl.funcs, C.GLenum(target), C.GLuint(texture))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexSubImage2D.xml
+func (gl *GL) TexSubImage2D(target glbase.Enum, level, xoffset, yoffset, width, height int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3compat_glTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexSubImage1D.xml
+func (gl *GL) TexSubImage1D(target glbase.Enum, level, xoffset, width int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3compat_glTexSubImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLsizei(width), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyTexSubImage2D.xml
+func (gl *GL) CopyTexSubImage2D(target glbase.Enum, level, xoffset, yoffset, x, y, width, height int) {
+ C.gl4_3compat_glCopyTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyTexSubImage1D.xml
+func (gl *GL) CopyTexSubImage1D(target glbase.Enum, level, xoffset, x, y, width int) {
+ C.gl4_3compat_glCopyTexSubImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(x), C.GLint(y), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyTexImage2D.xml
+func (gl *GL) CopyTexImage2D(target glbase.Enum, level int, internalFormat glbase.Enum, x, y, width, height, border int) {
+ C.gl4_3compat_glCopyTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height), C.GLint(border))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyTexImage1D.xml
+func (gl *GL) CopyTexImage1D(target glbase.Enum, level int, internalFormat glbase.Enum, x, y, width, border int) {
+ C.gl4_3compat_glCopyTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLint(border))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPolygonOffset.xml
+func (gl *GL) PolygonOffset(factor, units float32) {
+ C.gl4_3compat_glPolygonOffset(gl.funcs, C.GLfloat(factor), C.GLfloat(units))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawElements.xml
+func (gl *GL) DrawElements(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3compat_glDrawElements(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawArrays.xml
+func (gl *GL) DrawArrays(mode glbase.Enum, first, count int) {
+ C.gl4_3compat_glDrawArrays(gl.funcs, C.GLenum(mode), C.GLint(first), C.GLsizei(count))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyTexSubImage3D.xml
+func (gl *GL) CopyTexSubImage3D(target glbase.Enum, level, xoffset, yoffset int, zoffset int32, x, y, width, height int) {
+ C.gl4_3compat_glCopyTexSubImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(zoffset), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexSubImage3D.xml
+func (gl *GL) TexSubImage3D(target glbase.Enum, level, xoffset, yoffset int, zoffset int32, width, height int, depth int32, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3compat_glTexSubImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(zoffset), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexImage3D.xml
+func (gl *GL) TexImage3D(target glbase.Enum, level int, internalFormat int32, width, height int, depth int32, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3compat_glTexImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawRangeElements.xml
+func (gl *GL) DrawRangeElements(mode glbase.Enum, start, end uint32, count int, gltype glbase.Enum, indices interface{}) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3compat_glDrawRangeElements(gl.funcs, C.GLenum(mode), C.GLuint(start), C.GLuint(end), C.GLsizei(count), C.GLenum(gltype), indices_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendEquation.xml
+func (gl *GL) BlendEquation(mode glbase.Enum) {
+ C.gl4_3compat_glBlendEquation(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendColor.xml
+func (gl *GL) BlendColor(red, green, blue, alpha float32) {
+ C.gl4_3compat_glBlendColor(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetCompressedTexImage.xml
+func (gl *GL) GetCompressedTexImage(target glbase.Enum, level int, img interface{}) {
+ var img_ptr unsafe.Pointer
+ var img_v = reflect.ValueOf(img)
+ if img != nil && img_v.Kind() != reflect.Slice {
+ panic("parameter img must be a slice")
+ }
+ if img != nil {
+ img_ptr = unsafe.Pointer(img_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3compat_glGetCompressedTexImage(gl.funcs, C.GLenum(target), C.GLint(level), img_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCompressedTexSubImage1D.xml
+func (gl *GL) CompressedTexSubImage1D(target glbase.Enum, level, xoffset, width int, format glbase.Enum, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3compat_glCompressedTexSubImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLsizei(width), C.GLenum(format), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCompressedTexSubImage2D.xml
+func (gl *GL) CompressedTexSubImage2D(target glbase.Enum, level, xoffset, yoffset, width, height int, format glbase.Enum, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3compat_glCompressedTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCompressedTexSubImage3D.xml
+func (gl *GL) CompressedTexSubImage3D(target glbase.Enum, level, xoffset, yoffset int, zoffset int32, width, height int, depth int32, format glbase.Enum, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3compat_glCompressedTexSubImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(zoffset), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLenum(format), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCompressedTexImage1D.xml
+func (gl *GL) CompressedTexImage1D(target glbase.Enum, level int, internalFormat glbase.Enum, width, border, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3compat_glCompressedTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLsizei(width), C.GLint(border), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCompressedTexImage2D.xml
+func (gl *GL) CompressedTexImage2D(target glbase.Enum, level int, internalFormat glbase.Enum, width, height, border, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3compat_glCompressedTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLint(border), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCompressedTexImage3D.xml
+func (gl *GL) CompressedTexImage3D(target glbase.Enum, level int, internalFormat glbase.Enum, width, height int, depth int32, border, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3compat_glCompressedTexImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLint(border), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSampleCoverage.xml
+func (gl *GL) SampleCoverage(value float32, invert bool) {
+ C.gl4_3compat_glSampleCoverage(gl.funcs, C.GLfloat(value), *(*C.GLboolean)(unsafe.Pointer(&invert)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glActiveTexture.xml
+func (gl *GL) ActiveTexture(texture glbase.Enum) {
+ C.gl4_3compat_glActiveTexture(gl.funcs, C.GLenum(texture))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPointParameteriv.xml
+func (gl *GL) PointParameteriv(pname glbase.Enum, params []int32) {
+ C.gl4_3compat_glPointParameteriv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPointParameteri.xml
+func (gl *GL) PointParameteri(pname glbase.Enum, param int32) {
+ C.gl4_3compat_glPointParameteri(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPointParameterfv.xml
+func (gl *GL) PointParameterfv(pname glbase.Enum, params []float32) {
+ C.gl4_3compat_glPointParameterfv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPointParameterf.xml
+func (gl *GL) PointParameterf(pname glbase.Enum, param float32) {
+ C.gl4_3compat_glPointParameterf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiDrawArrays.xml
+func (gl *GL) MultiDrawArrays(mode glbase.Enum, first, count []int, drawcount int32) {
+ C.gl4_3compat_glMultiDrawArrays(gl.funcs, C.GLenum(mode), (*C.GLint)(unsafe.Pointer(&first[0])), (*C.GLsizei)(unsafe.Pointer(&count[0])), C.GLsizei(drawcount))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendFuncSeparate.xml
+func (gl *GL) BlendFuncSeparate(sfactorRGB, dfactorRGB, sfactorAlpha, dfactorAlpha glbase.Enum) {
+ C.gl4_3compat_glBlendFuncSeparate(gl.funcs, C.GLenum(sfactorRGB), C.GLenum(dfactorRGB), C.GLenum(sfactorAlpha), C.GLenum(dfactorAlpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetBufferParameteriv.xml
+func (gl *GL) GetBufferParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl4_3compat_glGetBufferParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUnmapBuffer.xml
+func (gl *GL) UnmapBuffer(target glbase.Enum) bool {
+ glresult := C.gl4_3compat_glUnmapBuffer(gl.funcs, C.GLenum(target))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetBufferSubData.xml
+func (gl *GL) GetBufferSubData(target glbase.Enum, offset, size int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3compat_glGetBufferSubData(gl.funcs, C.GLenum(target), C.GLintptr(offset), C.GLsizeiptr(size), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBufferSubData.xml
+func (gl *GL) BufferSubData(target glbase.Enum, offset, size int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3compat_glBufferSubData(gl.funcs, C.GLenum(target), C.GLintptr(offset), C.GLsizeiptr(size), data_ptr)
+}
+
+// BufferData creates a new data store for the buffer object currently
+// bound to target. Any pre-existing data store is deleted. The new data
+// store is created with the specified size in bytes and usage. If data is
+// not nil, it must be a slice that is used to initialize the data store.
+// In that case the size parameter is ignored and the store size will match
+// the slice data size.
+//
+// In its initial state, the new data store is not mapped, it has a NULL
+// mapped pointer, and its mapped access is GL.READ_WRITE.
+//
+// The target constant must be one of GL.ARRAY_BUFFER, GL.COPY_READ_BUFFER,
+// GL.COPY_WRITE_BUFFER, GL.ELEMENT_ARRAY_BUFFER, GL.PIXEL_PACK_BUFFER,
+// GL.PIXEL_UNPACK_BUFFER, GL.TEXTURE_BUFFER, GL.TRANSFORM_FEEDBACK_BUFFER,
+// or GL.UNIFORM_BUFFER.
+//
+// The usage parameter is a hint to the GL implementation as to how a buffer
+// object's data store will be accessed. This enables the GL implementation
+// to make more intelligent decisions that may significantly impact buffer
+// object performance. It does not, however, constrain the actual usage of
+// the data store. usage can be broken down into two parts: first, the
+// frequency of access (modification and usage), and second, the nature of
+// that access.
+//
+// A usage frequency of STREAM and nature of DRAW is specified via the
+// constant GL.STREAM_DRAW, for example.
+//
+// The usage frequency of access may be one of:
+//
+// STREAM
+// The data store contents will be modified once and used at most a few times.
+//
+// STATIC
+// The data store contents will be modified once and used many times.
+//
+// DYNAMIC
+// The data store contents will be modified repeatedly and used many times.
+//
+// The usage nature of access may be one of:
+//
+// DRAW
+// The data store contents are modified by the application, and used as
+// the source for GL drawing and image specification commands.
+//
+// READ
+// The data store contents are modified by reading data from the GL,
+// and used to return that data when queried by the application.
+//
+// COPY
+// The data store contents are modified by reading data from the GL,
+// and used as the source for GL drawing and image specification
+// commands.
+//
+// Clients must align data elements consistent with the requirements of the
+// client platform, with an additional base-level requirement that an offset
+// within a buffer to a datum comprising N bytes be a multiple of N.
+//
+// Error GL.INVALID_ENUM is generated if target is not one of the accepted
+// buffer targets. GL.INVALID_ENUM is generated if usage is not
+// GL.STREAM_DRAW, GL.STREAM_READ, GL.STREAM_COPY, GL.STATIC_DRAW,
+// GL.STATIC_READ, GL.STATIC_COPY, GL.DYNAMIC_DRAW, GL.DYNAMIC_READ, or
+// GL.DYNAMIC_COPY. GL.INVALID_VALUE is generated if size is negative.
+// GL.INVALID_OPERATION is generated if the reserved buffer object name 0 is
+// bound to target. GL.OUT_OF_MEMORY is generated if the GL is unable to
+// create a data store with the specified size.
+func (gl *GL) BufferData(target glbase.Enum, size int, data interface{}, usage glbase.Enum) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ if data != nil {
+ size = int(data_v.Type().Size()) * data_v.Len()
+ }
+ C.gl4_3compat_glBufferData(gl.funcs, C.GLenum(target), C.GLsizeiptr(size), data_ptr, C.GLenum(usage))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsBuffer.xml
+func (gl *GL) IsBuffer(buffer glbase.Buffer) bool {
+ glresult := C.gl4_3compat_glIsBuffer(gl.funcs, C.GLuint(buffer))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// GenBuffers returns n buffer object names. There is no guarantee that
+// the names form a contiguous set of integers; however, it is guaranteed
+// that none of the returned names was in use immediately before the call to
+// GenBuffers.
+//
+// Buffer object names returned by a call to GenBuffers are not returned by
+// subsequent calls, unless they are first deleted with DeleteBuffers.
+//
+// No buffer objects are associated with the returned buffer object names
+// until they are first bound by calling BindBuffer.
+//
+// Error GL.INVALID_VALUE is generated if n is negative. GL.INVALID_OPERATION
+// is generated if GenBuffers is executed between the execution of Begin
+// and the corresponding execution of End.
+//
+// GenBuffers is available in GL version 1.5 or greater.
+func (gl *GL) GenBuffers(n int) []glbase.Buffer {
+ if n == 0 {
+ return nil
+ }
+ buffers := make([]glbase.Buffer, n)
+ C.gl4_3compat_glGenBuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&buffers[0])))
+ return buffers
+}
+
+// DeleteBuffers deletes the buffer objects whose names are stored in the
+// buffers slice.
+//
+// After a buffer object is deleted, it has no contents, and its name is free
+// for reuse (for example by GenBuffers). If a buffer object that is
+// currently bound is deleted, the binding reverts to 0 (the absence of any
+// buffer object, which reverts to client memory usage).
+//
+// DeleteBuffers silently ignores 0's and names that do not correspond to
+// existing buffer objects.
+//
+// Error GL.INVALID_VALUE is generated if n is negative. GL.INVALID_OPERATION
+// is generated if DeleteBuffers is executed between the execution of Begin
+// and the corresponding execution of End.
+//
+// DeleteBuffers is available in GL version 1.5 or greater.
+func (gl *GL) DeleteBuffers(buffers []glbase.Buffer) {
+ n := len(buffers)
+ if n == 0 {
+ return
+ }
+ C.gl4_3compat_glDeleteBuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&buffers[0])))
+}
+
+// BindBuffer creates or puts in use a named buffer object.
+// Calling BindBuffer with target set to GL.ARRAY_BUFFER,
+// GL.ELEMENT_ARRAY_BUFFER, GL.PIXEL_PACK_BUFFER or GL.PIXEL_UNPACK_BUFFER
+// and buffer set to the name of the new buffer object binds the buffer
+// object name to the target. When a buffer object is bound to a target, the
+// previous binding for that target is automatically broken.
+//
+// Buffer object names are unsigned integers. The value zero is reserved, but
+// there is no default buffer object for each buffer object target. Instead,
+// buffer set to zero effectively unbinds any buffer object previously bound,
+// and restores client memory usage for that buffer object target. Buffer
+// object names and the corresponding buffer object contents are local to the
+// shared display-list space (see XCreateContext) of the current GL rendering
+// context; two rendering contexts share buffer object names only if they
+// also share display lists.
+//
+// GenBuffers may be called to generate a set of new buffer object names.
+//
+// The state of a buffer object immediately after it is first bound is an
+// unmapped zero-sized memory buffer with GL.READ_WRITE access and
+// GL.STATIC_DRAW usage.
+//
+// While a non-zero buffer object name is bound, GL operations on the target
+// to which it is bound affect the bound buffer object, and queries of the
+// target to which it is bound return state from the bound buffer object.
+// While buffer object name zero is bound, as in the initial state, attempts
+// to modify or query state on the target to which it is bound generates an
+// GL.INVALID_OPERATION error.
+//
+// When vertex array pointer state is changed, for example by a call to
+// NormalPointer, the current buffer object binding (GL.ARRAY_BUFFER_BINDING)
+// is copied into the corresponding client state for the vertex array type
+// being changed, for example GL.NORMAL_ARRAY_BUFFER_BINDING. While a
+// non-zero buffer object is bound to the GL.ARRAY_BUFFER target, the vertex
+// array pointer parameter that is traditionally interpreted as a pointer to
+// client-side memory is instead interpreted as an offset within the buffer
+// object measured in basic machine units.
+//
+// While a non-zero buffer object is bound to the GL.ELEMENT_ARRAY_BUFFER
+// target, the indices parameter of DrawElements, DrawRangeElements, or
+// MultiDrawElements that is traditionally interpreted as a pointer to
+// client-side memory is instead interpreted as an offset within the buffer
+// object measured in basic machine units.
+//
+// While a non-zero buffer object is bound to the GL.PIXEL_PACK_BUFFER
+// target, the following commands are affected: GetCompressedTexImage,
+// GetConvolutionFilter, GetHistogram, GetMinmax, GetPixelMap,
+// GetPolygonStipple, GetSeparableFilter, GetTexImage, and ReadPixels. The
+// pointer parameter that is traditionally interpreted as a pointer to
+// client-side memory where the pixels are to be packed is instead
+// interpreted as an offset within the buffer object measured in basic
+// machine units.
+//
+// While a non-zero buffer object is bound to the GL.PIXEL_UNPACK_BUFFER
+// target, the following commands are affected: Bitmap, ColorSubTable,
+// ColorTable, CompressedTexImage1D, CompressedTexImage2D,
+// CompressedTexImage3D, CompressedTexSubImage1D, CompressedTexSubImage2D,
+// CompressedTexSubImage3D, ConvolutionFilter1D, ConvolutionFilter2D,
+// DrawPixels, PixelMap, PolygonStipple, SeparableFilter2D, TexImage1D,
+// TexImage2D, TexImage3D, TexSubImage1D, TexSubImage2D, and TexSubImage3D.
+// The pointer parameter that is traditionally interpreted as a pointer to
+// client-side memory from which the pixels are to be unpacked is instead
+// interpreted as an offset within the buffer object measured in basic
+// machine units.
+//
+// A buffer object binding created with BindBuffer remains active until a
+// different buffer object name is bound to the same target, or until the
+// bound buffer object is deleted with DeleteBuffers.
+//
+// Once created, a named buffer object may be re-bound to any target as often
+// as needed. However, the GL implementation may make choices about how to
+// optimize the storage of a buffer object based on its initial binding
+// target.
+//
+// Error GL.INVALID_ENUM is generated if target is not one of the allowable
+// values. GL.INVALID_OPERATION is generated if BindBuffer is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// BindBuffer is available in GL version 1.5 or greater.
+func (gl *GL) BindBuffer(target glbase.Enum, buffer glbase.Buffer) {
+ C.gl4_3compat_glBindBuffer(gl.funcs, C.GLenum(target), C.GLuint(buffer))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetQueryObjectuiv.xml
+func (gl *GL) GetQueryObjectuiv(id uint32, pname glbase.Enum, params []uint32) {
+ C.gl4_3compat_glGetQueryObjectuiv(gl.funcs, C.GLuint(id), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetQueryObjectiv.xml
+func (gl *GL) GetQueryObjectiv(id uint32, pname glbase.Enum, params []int32) {
+ C.gl4_3compat_glGetQueryObjectiv(gl.funcs, C.GLuint(id), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetQueryiv.xml
+func (gl *GL) GetQueryiv(target, pname glbase.Enum, params []int32) {
+ C.gl4_3compat_glGetQueryiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEndQuery.xml
+func (gl *GL) EndQuery(target glbase.Enum) {
+ C.gl4_3compat_glEndQuery(gl.funcs, C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBeginQuery.xml
+func (gl *GL) BeginQuery(target glbase.Enum, id uint32) {
+ C.gl4_3compat_glBeginQuery(gl.funcs, C.GLenum(target), C.GLuint(id))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsQuery.xml
+func (gl *GL) IsQuery(id uint32) bool {
+ glresult := C.gl4_3compat_glIsQuery(gl.funcs, C.GLuint(id))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDeleteQueries.xml
+func (gl *GL) DeleteQueries(n int, ids []uint32) {
+ C.gl4_3compat_glDeleteQueries(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&ids[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGenQueries.xml
+func (gl *GL) GenQueries(n int, ids []uint32) {
+ C.gl4_3compat_glGenQueries(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&ids[0])))
+}
+
+// VertexAttribPointer specifies the location and data format of the array
+// of generic vertex attributes at index to use when rendering. size
+// specifies the number of components per attribute and must be 1, 2, 3, or
+// 4. type specifies the data type of each component, and stride specifies
+// the byte stride from one attribute to the next, allowing vertices and
+// attributes to be packed into a single array or stored in separate arrays.
+// normalized indicates whether the values stored in an integer format are
+// to be mapped to the range [-1,1] (for signed values) or [0,1]
+// (for unsigned values) when they are accessed and converted to floating
+// point; otherwise, values will be converted to floats directly without
+// normalization. offset is a byte offset into the buffer object's data
+// store, which must be bound to the GL.ARRAY_BUFFER target with BindBuffer.
+//
+// The buffer object binding (GL.ARRAY_BUFFER_BINDING) is saved as
+// generic vertex attribute array client-side state
+// (GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING) for the provided index.
+//
+// To enable and disable a generic vertex attribute array, call
+// EnableVertexAttribArray and DisableVertexAttribArray with index. If
+// enabled, the generic vertex attribute array is used when DrawArrays or
+// DrawElements is called. Each generic vertex attribute array is initially
+// disabled.
+//
+// VertexAttribPointer is typically implemented on the client side.
+//
+// Error GL.INVALID_ENUM is generated if type is not an accepted value.
+// GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_VALUE is generated if size is not 1, 2,
+// 3, or 4. GL.INVALID_VALUE is generated if stride is negative.
+func (gl *GL) VertexAttribPointer(index glbase.Attrib, size int, gltype glbase.Enum, normalized bool, stride int, offset uintptr) {
+ offset_ptr := unsafe.Pointer(offset)
+ C.gl4_3compat_glVertexAttribPointer(gl.funcs, C.GLuint(index), C.GLint(size), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), C.GLsizei(stride), offset_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glValidateProgram.xml
+func (gl *GL) ValidateProgram(program glbase.Program) {
+ C.gl4_3compat_glValidateProgram(gl.funcs, C.GLuint(program))
+}
+
+// UniformMatrix4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix4fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(4*4) != 0 {
+ panic("invalid value length for UniformMatrix4fv")
+ }
+ count := len(value) / (4 * 4)
+ C.gl4_3compat_glUniformMatrix4fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix3fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(3*3) != 0 {
+ panic("invalid value length for UniformMatrix3fv")
+ }
+ count := len(value) / (3 * 3)
+ C.gl4_3compat_glUniformMatrix3fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix2fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(2*2) != 0 {
+ panic("invalid value length for UniformMatrix2fv")
+ }
+ count := len(value) / (2 * 2)
+ C.gl4_3compat_glUniformMatrix2fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform4iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%4 != 0 {
+ panic("invalid value length for Uniform4iv")
+ }
+ count := len(value) / 4
+ C.gl4_3compat_glUniform4iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform3iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform3iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%3 != 0 {
+ panic("invalid value length for Uniform3iv")
+ }
+ count := len(value) / 3
+ C.gl4_3compat_glUniform3iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform2iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform2iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%2 != 0 {
+ panic("invalid value length for Uniform2iv")
+ }
+ count := len(value) / 2
+ C.gl4_3compat_glUniform2iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform1iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform1iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ count := len(value)
+ C.gl4_3compat_glUniform1iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%4 != 0 {
+ panic("invalid value length for Uniform4fv")
+ }
+ count := len(value) / 4
+ C.gl4_3compat_glUniform4fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%3 != 0 {
+ panic("invalid value length for Uniform3fv")
+ }
+ count := len(value) / 3
+ C.gl4_3compat_glUniform3fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%2 != 0 {
+ panic("invalid value length for Uniform2fv")
+ }
+ count := len(value) / 2
+ C.gl4_3compat_glUniform2fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform1fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform1fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ count := len(value)
+ C.gl4_3compat_glUniform1fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform4i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4i(location glbase.Uniform, v0, v1, v2, v3 int32) {
+ C.gl4_3compat_glUniform4i(gl.funcs, C.GLint(location), C.GLint(v0), C.GLint(v1), C.GLint(v2), C.GLint(v3))
+}
+
+// Uniform3i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform3i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3i(location glbase.Uniform, v0, v1, v2 int32) {
+ C.gl4_3compat_glUniform3i(gl.funcs, C.GLint(location), C.GLint(v0), C.GLint(v1), C.GLint(v2))
+}
+
+// Uniform2i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform2i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2i(location glbase.Uniform, v0, v1 int32) {
+ C.gl4_3compat_glUniform2i(gl.funcs, C.GLint(location), C.GLint(v0), C.GLint(v1))
+}
+
+// Uniform1i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform1i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1i(location glbase.Uniform, v0 int32) {
+ C.gl4_3compat_glUniform1i(gl.funcs, C.GLint(location), C.GLint(v0))
+}
+
+// Uniform4f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform4f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4f(location glbase.Uniform, v0, v1, v2, v3 float32) {
+ C.gl4_3compat_glUniform4f(gl.funcs, C.GLint(location), C.GLfloat(v0), C.GLfloat(v1), C.GLfloat(v2), C.GLfloat(v3))
+}
+
+// Uniform3f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform3f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3f(location glbase.Uniform, v0, v1, v2 float32) {
+ C.gl4_3compat_glUniform3f(gl.funcs, C.GLint(location), C.GLfloat(v0), C.GLfloat(v1), C.GLfloat(v2))
+}
+
+// Uniform2f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform2f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2f(location glbase.Uniform, v0, v1 float32) {
+ C.gl4_3compat_glUniform2f(gl.funcs, C.GLint(location), C.GLfloat(v0), C.GLfloat(v1))
+}
+
+// Uniform1f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform1f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1f(location glbase.Uniform, v0 float32) {
+ C.gl4_3compat_glUniform1f(gl.funcs, C.GLint(location), C.GLfloat(v0))
+}
+
+// UseProgram installs the program object specified by program as part of
+// current rendering state. One or more executables are created in a program
+// object by successfully attaching shader objects to it with AttachShader,
+// successfully compiling the shader objects with CompileShader, and
+// successfully linking the program object with LinkProgram.
+//
+// A program object will contain an executable that will run on the vertex
+// processor if it contains one or more shader objects of type
+// GL.VERTEX_SHADER that have been successfully compiled and linked.
+// Similarly, a program object will contain an executable that will run on
+// the fragment processor if it contains one or more shader objects of type
+// GL.FRAGMENT_SHADER that have been successfully compiled and linked.
+//
+// Successfully installing an executable on a programmable processor will
+// cause the corresponding fixed functionality of OpenGL to be disabled.
+// Specifically, if an executable is installed on the vertex processor, the
+// OpenGL fixed functionality will be disabled as follows.
+//
+// - The modelview matrix is not applied to vertex coordinates.
+//
+// - The projection matrix is not applied to vertex coordinates.
+//
+// - The texture matrices are not applied to texture coordinates.
+//
+// - Normals are not transformed to eye coordinates.
+//
+// - Normals are not rescaled or normalized.
+//
+// - Normalization of GL.AUTO_NORMAL evaluated normals is not performed.
+//
+// - Texture coordinates are not generated automatically.
+//
+// - Per-vertex lighting is not performed.
+//
+// - Color material computations are not performed.
+//
+// - Color index lighting is not performed.
+//
+// - This list also applies when setting the current raster position.
+//
+// The executable that is installed on the vertex processor is expected to
+// implement any or all of the desired functionality from the preceding list.
+// Similarly, if an executable is installed on the fragment processor, the
+// OpenGL fixed functionality will be disabled as follows.
+//
+// - Texture environment and texture functions are not applied.
+//
+// - Texture application is not applied.
+//
+// - Color sum is not applied.
+//
+// - Fog is not applied.
+//
+// Again, the fragment shader that is installed is expected to implement any
+// or all of the desired functionality from the preceding list.
+//
+// While a program object is in use, applications are free to modify attached
+// shader objects, compile attached shader objects, attach additional shader
+// objects, and detach or delete shader objects. None of these operations
+// will affect the executables that are part of the current state. However,
+// relinking the program object that is currently in use will install the
+// program object as part of the current rendering state if the link
+// operation was successful (see LinkProgram). If the program object
+// currently in use is relinked unsuccessfully, its link status will be set
+// to GL.FALSE, but the executables and associated state will remain part of
+// the current state until a subsequent call to UseProgram removes it from
+// use. After it is removed from use, it cannot be made part of current state
+// until it has been successfully relinked.
+//
+// If program contains shader objects of type GL.VERTEX_SHADER but it does
+// not contain shader objects of type GL.FRAGMENT_SHADER, an executable will
+// be installed on the vertex processor, but fixed functionality will be used
+// for fragment processing. Similarly, if program contains shader objects of
+// type GL.FRAGMENT_SHADER but it does not contain shader objects of type
+// GL.VERTEX_SHADER, an executable will be installed on the fragment
+// processor, but fixed functionality will be used for vertex processing. If
+// program is 0, the programmable processors will be disabled, and fixed
+// functionality will be used for both vertex and fragment processing.
+//
+// While a program object is in use, the state that controls the disabled
+// fixed functionality may also be updated using the normal OpenGL calls.
+//
+// Like display lists and texture objects, the name space for program objects
+// may be shared across a set of contexts, as long as the server sides of the
+// contexts share the same address space. If the name space is shared across
+// contexts, any attached objects and the data associated with those attached
+// objects are shared as well.
+//
+// Applications are responsible for providing the synchronization across API
+// calls when objects are accessed from different execution threads.
+//
+// Error GL.INVALID_VALUE is generated if program is neither 0 nor a value
+// generated by OpenGL. GL.INVALID_OPERATION is generated if program is not
+// a program object. GL.INVALID_OPERATION is generated if program could not
+// be made part of current state. GL.INVALID_OPERATION is generated if
+// UseProgram is executed between the execution of Begin and the
+// corresponding execution of End.
+//
+// UseProgram is available in GL version 2.0 or greater.
+func (gl *GL) UseProgram(program glbase.Program) {
+ C.gl4_3compat_glUseProgram(gl.funcs, C.GLuint(program))
+}
+
+// ShaderSource sets the source code in shader to the provided source code. Any source
+// code previously stored in the shader object is completely replaced.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader is not a shader
+// object. GL.INVALID_VALUE is generated if count is less than 0.
+// GL.INVALID_OPERATION is generated if ShaderSource is executed between the
+// execution of Begin and the corresponding execution of End.
+//
+// ShaderSource is available in GL version 2.0 or greater.
+func (gl *GL) ShaderSource(shader glbase.Shader, source ...string) {
+ count := len(source)
+ length := make([]int32, count)
+ source_c := make([]unsafe.Pointer, count)
+ for i, src := range source {
+ length[i] = int32(len(src))
+ if len(src) > 0 {
+ source_c[i] = *(*unsafe.Pointer)(unsafe.Pointer(&src))
+ } else {
+ source_c[i] = unsafe.Pointer(uintptr(0))
+ }
+ }
+ C.gl4_3compat_glShaderSource(gl.funcs, C.GLuint(shader), C.GLsizei(count), (**C.GLchar)(unsafe.Pointer(&source_c[0])), (*C.GLint)(unsafe.Pointer(&length[0])))
+}
+
+// LinkProgram links the program object specified by program. If any shader
+// objects of type GL.VERTEX_SHADER are attached to program, they will be
+// used to create an executable that will run on the programmable vertex
+// processor. If any shader objects of type GL.FRAGMENT_SHADER are attached
+// to program, they will be used to create an executable that will run on the
+// programmable fragment processor.
+//
+// The status of the link operation will be stored as part of the program
+// object's state. This value will be set to GL.TRUE if the program object
+// was linked without errors and is ready for use, and GL.FALSE otherwise. It
+// can be queried by calling GetProgramiv with arguments program and
+// GL.LINK_STATUS.
+//
+// As a result of a successful link operation, all active user-defined
+// uniform variables belonging to program will be initialized to 0, and each
+// of the program object's active uniform variables will be assigned a
+// location that can be queried by calling GetUniformLocation. Also, any
+// active user-defined attribute variables that have not been bound to a
+// generic vertex attribute index will be bound to one at this time.
+//
+// Linking of a program object can fail for a number of reasons as specified
+// in the OpenGL Shading Language Specification. The following lists some of
+// the conditions that will cause a link error.
+//
+// - The number of active attribute variables supported by the
+// implementation has been exceeded.
+//
+// - The storage limit for uniform variables has been exceeded.
+//
+// - The number of active uniform variables supported by the implementation
+// has been exceeded.
+//
+// - The main function is missing for the vertex shader or the fragment
+// shader.
+//
+// - A varying variable actually used in the fragment shader is not
+// declared in the same way (or is not declared at all) in the vertex
+// shader.
+//
+// - A reference to a function or variable name is unresolved.
+//
+// - A shared global is declared with two different types or two different
+// initial values.
+//
+// - One or more of the attached shader objects has not been successfully
+// compiled.
+//
+// - Binding a generic attribute matrix caused some rows of the matrix to
+// fall outside the allowed maximum of GL.MAX_VERTEX_ATTRIBS.
+//
+// - Not enough contiguous vertex attribute slots could be found to bind
+// attribute matrices.
+//
+// When a program object has been successfully linked, the program object can
+// be made part of current state by calling UseProgram. Whether or not the
+// link operation was successful, the program object's information log will
+// be overwritten. The information log can be retrieved by calling
+// GetProgramInfoLog.
+//
+// LinkProgram will also install the generated executables as part of the
+// current rendering state if the link operation was successful and the
+// specified program object is already currently in use as a result of a
+// previous call to UseProgram. If the program object currently in use is
+// relinked unsuccessfully, its link status will be set to GL.FALSE , but the
+// executables and associated state will remain part of the current state
+// until a subsequent call to UseProgram removes it from use. After it is
+// removed from use, it cannot be made part of current state until it has
+// been successfully relinked.
+//
+// If program contains shader objects of type GL.VERTEX_SHADER but does not
+// contain shader objects of type GL.FRAGMENT_SHADER, the vertex shader will
+// be linked against the implicit interface for fixed functionality fragment
+// processing. Similarly, if program contains shader objects of type
+// GL.FRAGMENT_SHADER but it does not contain shader objects of type
+// GL.VERTEX_SHADER, the fragment shader will be linked against the implicit
+// interface for fixed functionality vertex processing.
+//
+// The program object's information log is updated and the program is
+// generated at the time of the link operation. After the link operation,
+// applications are free to modify attached shader objects, compile attached
+// shader objects, detach shader objects, delete shader objects, and attach
+// additional shader objects. None of these operations affects the
+// information log or the program that is part of the program object.
+//
+// If the link operation is unsuccessful, any information about a previous
+// link operation on program is lost (a failed link does not restore the
+// old state of program). Certain information can still be retrieved
+// from program even after an unsuccessful link operation. See for instance
+// GetActiveAttrib and GetActiveUniform.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program
+// object. GL.INVALID_OPERATION is generated if LinkProgram is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// LinkProgram is available in GL version 2.0 or greater.
+func (gl *GL) LinkProgram(program glbase.Program) {
+ C.gl4_3compat_glLinkProgram(gl.funcs, C.GLuint(program))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsShader.xml
+func (gl *GL) IsShader(shader glbase.Shader) bool {
+ glresult := C.gl4_3compat_glIsShader(gl.funcs, C.GLuint(shader))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsProgram.xml
+func (gl *GL) IsProgram(program glbase.Program) bool {
+ glresult := C.gl4_3compat_glIsProgram(gl.funcs, C.GLuint(program))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// GetVertexAttribiv returns in params the value of a generic vertex attribute
+// parameter. The generic vertex attribute to be queried is specified by
+// index, and the parameter to be queried is specified by pname.
+//
+// The accepted parameter names are as follows:
+//
+// GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING
+// params returns a single value, the name of the buffer object
+// currently bound to the binding point corresponding to generic vertex
+// attribute array index. If no buffer object is bound, 0 is returned.
+// The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_ENABLED
+// params returns a single value that is non-zero (true) if the vertex
+// attribute array for index is enabled and 0 (false) if it is
+// disabled. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_SIZE
+// params returns a single value, the size of the vertex attribute
+// array for index. The size is the number of values for each element
+// of the vertex attribute array, and it will be 1, 2, 3, or 4. The
+// initial value is 4.
+//
+// GL.VERTEX_ATTRIB_ARRAY_STRIDE
+// params returns a single value, the array stride for (number of bytes
+// between successive elements in) the vertex attribute array for
+// index. A value of 0 indicates that the array elements are stored
+// sequentially in memory. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_TYPE
+// params returns a single value, a symbolic constant indicating the
+// array type for the vertex attribute array for index. Possible values
+// are GL.BYTE, GL.UNSIGNED_BYTE, GL.SHORT, GL.UNSIGNED_SHORT, GL.INT,
+// GL.UNSIGNED_INT, GL.FLOAT, and GL.DOUBLE. The initial value is
+// GL.FLOAT.
+//
+// GL.VERTEX_ATTRIB_ARRAY_NORMALIZED
+// params returns a single value that is non-zero (true) if fixed-point
+// data types for the vertex attribute array indicated by index are
+// normalized when they are converted to floating point, and 0 (false)
+// otherwise. The initial value is 0.
+//
+// GL.CURRENT_VERTEX_ATTRIB
+// params returns four values that represent the current value for the
+// generic vertex attribute specified by index. Generic vertex
+// attribute 0 is unique in that it has no current state, so an error
+// will be generated if index is 0. The initial value for all other
+// generic vertex attributes is (0,0,0,1).
+//
+// All of the parameters except GL.CURRENT_VERTEX_ATTRIB represent
+// client-side state.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_ENUM is generated if pname is not an
+// accepted value. GL.INVALID_OPERATION is generated if index is 0 and pname
+// is GL.CURRENT_VERTEX_ATTRIB.
+//
+// GetVertexAttribiv is available in GL version 2.0 or greater.
+func (gl *GL) GetVertexAttribiv(index glbase.Attrib, pname glbase.Enum, params []int32) {
+ var params_c [4]int32
+ C.gl4_3compat_glGetVertexAttribiv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetVertexAttribfv returns in params the value of a generic vertex attribute
+// parameter. The generic vertex attribute to be queried is specified by
+// index, and the parameter to be queried is specified by pname.
+//
+// The accepted parameter names are as follows:
+//
+// GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING
+// params returns a single value, the name of the buffer object
+// currently bound to the binding point corresponding to generic vertex
+// attribute array index. If no buffer object is bound, 0 is returned.
+// The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_ENABLED
+// params returns a single value that is non-zero (true) if the vertex
+// attribute array for index is enabled and 0 (false) if it is
+// disabled. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_SIZE
+// params returns a single value, the size of the vertex attribute
+// array for index. The size is the number of values for each element
+// of the vertex attribute array, and it will be 1, 2, 3, or 4. The
+// initial value is 4.
+//
+// GL.VERTEX_ATTRIB_ARRAY_STRIDE
+// params returns a single value, the array stride for (number of bytes
+// between successive elements in) the vertex attribute array for
+// index. A value of 0 indicates that the array elements are stored
+// sequentially in memory. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_TYPE
+// params returns a single value, a symbolic constant indicating the
+// array type for the vertex attribute array for index. Possible values
+// are GL.BYTE, GL.UNSIGNED_BYTE, GL.SHORT, GL.UNSIGNED_SHORT, GL.INT,
+// GL.UNSIGNED_INT, GL.FLOAT, and GL.DOUBLE. The initial value is
+// GL.FLOAT.
+//
+// GL.VERTEX_ATTRIB_ARRAY_NORMALIZED
+// params returns a single value that is non-zero (true) if fixed-point
+// data types for the vertex attribute array indicated by index are
+// normalized when they are converted to floating point, and 0 (false)
+// otherwise. The initial value is 0.
+//
+// GL.CURRENT_VERTEX_ATTRIB
+// params returns four values that represent the current value for the
+// generic vertex attribute specified by index. Generic vertex
+// attribute 0 is unique in that it has no current state, so an error
+// will be generated if index is 0. The initial value for all other
+// generic vertex attributes is (0,0,0,1).
+//
+// All of the parameters except GL.CURRENT_VERTEX_ATTRIB represent
+// client-side state.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_ENUM is generated if pname is not an
+// accepted value. GL.INVALID_OPERATION is generated if index is 0 and pname
+// is GL.CURRENT_VERTEX_ATTRIB.
+//
+// GetVertexAttribfv is available in GL version 2.0 or greater.
+func (gl *GL) GetVertexAttribfv(index glbase.Attrib, pname glbase.Enum, params []float32) {
+ var params_c [4]float32
+ C.gl4_3compat_glGetVertexAttribfv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetVertexAttribdv returns in params the value of a generic vertex attribute
+// parameter. The generic vertex attribute to be queried is specified by
+// index, and the parameter to be queried is specified by pname.
+//
+// The accepted parameter names are as follows:
+//
+// GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING
+// params returns a single value, the name of the buffer object
+// currently bound to the binding point corresponding to generic vertex
+// attribute array index. If no buffer object is bound, 0 is returned.
+// The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_ENABLED
+// params returns a single value that is non-zero (true) if the vertex
+// attribute array for index is enabled and 0 (false) if it is
+// disabled. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_SIZE
+// params returns a single value, the size of the vertex attribute
+// array for index. The size is the number of values for each element
+// of the vertex attribute array, and it will be 1, 2, 3, or 4. The
+// initial value is 4.
+//
+// GL.VERTEX_ATTRIB_ARRAY_STRIDE
+// params returns a single value, the array stride for (number of bytes
+// between successive elements in) the vertex attribute array for
+// index. A value of 0 indicates that the array elements are stored
+// sequentially in memory. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_TYPE
+// params returns a single value, a symbolic constant indicating the
+// array type for the vertex attribute array for index. Possible values
+// are GL.BYTE, GL.UNSIGNED_BYTE, GL.SHORT, GL.UNSIGNED_SHORT, GL.INT,
+// GL.UNSIGNED_INT, GL.FLOAT, and GL.DOUBLE. The initial value is
+// GL.FLOAT.
+//
+// GL.VERTEX_ATTRIB_ARRAY_NORMALIZED
+// params returns a single value that is non-zero (true) if fixed-point
+// data types for the vertex attribute array indicated by index are
+// normalized when they are converted to floating point, and 0 (false)
+// otherwise. The initial value is 0.
+//
+// GL.CURRENT_VERTEX_ATTRIB
+// params returns four values that represent the current value for the
+// generic vertex attribute specified by index. Generic vertex
+// attribute 0 is unique in that it has no current state, so an error
+// will be generated if index is 0. The initial value for all other
+// generic vertex attributes is (0,0,0,1).
+//
+// All of the parameters except GL.CURRENT_VERTEX_ATTRIB represent
+// client-side state.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_ENUM is generated if pname is not an
+// accepted value. GL.INVALID_OPERATION is generated if index is 0 and pname
+// is GL.CURRENT_VERTEX_ATTRIB.
+//
+// GetVertexAttribdv is available in GL version 2.0 or greater.
+func (gl *GL) GetVertexAttribdv(index glbase.Attrib, pname glbase.Enum, params []float64) {
+ var params_c [4]float64
+ C.gl4_3compat_glGetVertexAttribdv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetUniformiv returns in params the value of the specified uniform
+// variable. The type of the uniform variable specified by location
+// determines the number of values returned. If the uniform variable is
+// defined in the shader as a boolean, int, or float, a single value will be
+// returned. If it is defined as a vec2, ivec2, or bvec2, two values will be
+// returned. If it is defined as a vec3, ivec3, or bvec3, three values will
+// be returned, and so on. To query values stored in uniform variables
+// declared as arrays, call GetUniformiv for each element of the array. To
+// query values stored in uniform variables declared as structures, call
+// GetUniformiv for each field in the structure. The values for uniform
+// variables declared as a matrix will be returned in column major order.
+//
+// The locations assigned to uniform variables are not known until the
+// program object is linked. After linking has occurred, the command
+// GetUniformLocation can be used to obtain the location of a uniform
+// variable. This location value can then be passed to GetUniformiv in order
+// to query the current value of the uniform variable. After a program object
+// has been linked successfully, the index values for uniform variables
+// remain fixed until the next link command occurs. The uniform variable
+// values can only be queried after a link if the link was successful.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program
+// object. GL.INVALID_OPERATION is generated if program has not been
+// successfully linked. GL.INVALID_OPERATION is generated if location does
+// not correspond to a valid uniform variable location for the specified
+// program object. GL.INVALID_OPERATION is generated if GetUniformiv is
+// executed between the execution of Begin and the corresponding execution of
+// End.
+//
+// GetUniformiv is available in GL version 2.0 or greater.
+func (gl *GL) GetUniformiv(program glbase.Program, location glbase.Uniform, params []int32) {
+ var params_c [4]int32
+ C.gl4_3compat_glGetUniformiv(gl.funcs, C.GLuint(program), C.GLint(location), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetUniformfv returns in params the value of the specified uniform
+// variable. The type of the uniform variable specified by location
+// determines the number of values returned. If the uniform variable is
+// defined in the shader as a boolean, int, or float, a single value will be
+// returned. If it is defined as a vec2, ivec2, or bvec2, two values will be
+// returned. If it is defined as a vec3, ivec3, or bvec3, three values will
+// be returned, and so on. To query values stored in uniform variables
+// declared as arrays, call GetUniformfv for each element of the array. To
+// query values stored in uniform variables declared as structures, call
+// GetUniformfv for each field in the structure. The values for uniform
+// variables declared as a matrix will be returned in column major order.
+//
+// The locations assigned to uniform variables are not known until the
+// program object is linked. After linking has occurred, the command
+// GetUniformLocation can be used to obtain the location of a uniform
+// variable. This location value can then be passed to GetUniformfv in order
+// to query the current value of the uniform variable. After a program object
+// has been linked successfully, the index values for uniform variables
+// remain fixed until the next link command occurs. The uniform variable
+// values can only be queried after a link if the link was successful.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program
+// object. GL.INVALID_OPERATION is generated if program has not been
+// successfully linked. GL.INVALID_OPERATION is generated if location does
+// not correspond to a valid uniform variable location for the specified
+// program object. GL.INVALID_OPERATION is generated if GetUniformfv is
+// executed between the execution of Begin and the corresponding execution of
+// End.
+//
+// GetUniformfv is available in GL version 2.0 or greater.
+func (gl *GL) GetUniformfv(program glbase.Program, location glbase.Uniform, params []float32) {
+ var params_c [4]float32
+ C.gl4_3compat_glGetUniformfv(gl.funcs, C.GLuint(program), C.GLint(location), (*C.GLfloat)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetUniformLocation returns an integer that represents the location of a
+// specific uniform variable within a program object. name must be an active
+// uniform variable name in program that is not a structure, an array of
+// structures, or a subcomponent of a vector or a matrix. This function
+// returns -1 if name does not correspond to an active uniform variable in
+// program or if name starts with the reserved prefix "gl_".
+//
+// Uniform variables that are structures or arrays of structures may be
+// queried by calling GetUniformLocation for each field within the
+// structure. The array element operator "[]" and the structure field
+// operator "." may be used in name in order to select elements within an
+// array or fields within a structure. The result of using these operators is
+// not allowed to be another structure, an array of structures, or a
+// subcomponent of a vector or a matrix. Except if the last part of name
+// indicates a uniform variable array, the location of the first element of
+// an array can be retrieved by using the name of the array, or by using the
+// name appended by "[0]".
+//
+// The actual locations assigned to uniform variables are not known until the
+// program object is linked successfully. After linking has occurred, the
+// command GetUniformLocation can be used to obtain the location of a
+// uniform variable. This location value can then be passed to Uniform to
+// set the value of the uniform variable or to GetUniform in order to query
+// the current value of the uniform variable. After a program object has been
+// linked successfully, the index values for uniform variables remain fixed
+// until the next link command occurs. Uniform variable locations and values
+// can only be queried after a link if the link was successful.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program object.
+// GL.INVALID_OPERATION is generated if program has not been successfully
+// linked. GL.INVALID_OPERATION is generated if GetUniformLocation is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// GetUniformLocation is available in GL version 2.0 or greater.
+func (gl *GL) GetUniformLocation(program glbase.Program, name string) glbase.Uniform {
+ name_cstr := C.CString(name)
+ glresult := C.gl4_3compat_glGetUniformLocation(gl.funcs, C.GLuint(program), (*C.GLchar)(name_cstr))
+ C.free(unsafe.Pointer(name_cstr))
+ return glbase.Uniform(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetShaderSource.xml
+func (gl *GL) GetShaderSource(shader glbase.Shader, bufSize int32, length []int32, source []byte) {
+ C.gl4_3compat_glGetShaderSource(gl.funcs, C.GLuint(shader), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&source[0])))
+}
+
+// GetShaderInfoLog returns the information log for the specified shader
+// object. The information log for a shader object is modified when the
+// shader is compiled.
+//
+// The information log for a shader object is a string that may contain
+// diagnostic messages, warning messages, and other information about the
+// last compile operation. When a shader object is created, its information
+// log will be a string of length 0, and the size of the current log can be
+// obtained by calling GetShaderiv with the value GL.INFO_LOG_LENGTH.
+//
+// The information log for a shader object is the OpenGL implementer's
+// primary mechanism for conveying information about the compilation process.
+// Therefore, the information log can be helpful to application developers
+// during the development process, even when compilation is successful.
+// Application developers should not expect different OpenGL implementations
+// to produce identical information logs.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader is not a shader
+// object. GL.INVALID_VALUE is generated if maxLength is less than 0.
+// GL.INVALID_OPERATION is generated if GetShaderInfoLog is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// GetShaderInfoLog is available in GL version 2.0 or greater.
+func (gl *GL) GetShaderInfoLog(shader glbase.Shader) []byte {
+ var params [1]int32
+ var length int32
+ gl.GetShaderiv(shader, INFO_LOG_LENGTH, params[:])
+ bufSize := params[0]
+ infoLog := make([]byte, int(bufSize))
+ C.gl4_3compat_glGetShaderInfoLog(gl.funcs, C.GLuint(shader), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length)), (*C.GLchar)(unsafe.Pointer(&infoLog[0])))
+ return infoLog
+}
+
+// GetShaderiv GetShader returns in params the value of a parameter for a specific
+// shader object. The following parameters are defined:
+//
+// GL.SHADER_TYPE
+// params returns GL.VERTEX_SHADER if shader is a vertex shader object,
+// and GL.FRAGMENT_SHADER if shader is a fragment shader object.
+//
+// GL.DELETE_STATUS
+// params returns GL.TRUE if shader is currently flagged for deletion,
+// and GL.FALSE otherwise.
+//
+// GL.COMPILE_STATUS
+// params returns GL.TRUE if the last compile operation on shader was
+// successful, and GL.FALSE otherwise.
+//
+// GL.INFO_LOG_LENGTH
+// params returns the number of characters in the information log for
+// shader including the null termination character (the size of the
+// character buffer required to store the information log). If shader has
+// no information log, a value of 0 is returned.
+//
+// GL.SHADER_SOURCE_LENGTH
+// params returns the length of the concatenation of the source strings
+// that make up the shader source for the shader, including the null
+// termination character. (the size of the character buffer
+// required to store the shader source). If no source code exists, 0 is
+// returned.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader does not refer to a
+// shader object. GL.INVALID_ENUM is generated if pname is not an accepted
+// value. GL.INVALID_OPERATION is generated if GetShader is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// GetShaderiv is available in GL version 2.0 or greater.
+func (gl *GL) GetShaderiv(shader glbase.Shader, pname glbase.Enum, params []int32) {
+ var params_c [4]int32
+ C.gl4_3compat_glGetShaderiv(gl.funcs, C.GLuint(shader), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetProgramInfoLog returns the information log for the specified program
+// object. The information log for a program object is modified when the
+// program object is linked or validated.
+//
+// The information log for a program object is either an empty string, or a
+// string containing information about the last link operation, or a string
+// containing information about the last validation operation. It may contain
+// diagnostic messages, warning messages, and other information. When a
+// program object is created, its information log will be a string of length
+// 0, and the size of the current log can be obtained by calling GetProgramiv
+// with the value GL.INFO_LOG_LENGTH.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated
+// by OpenGL. GL.INVALID_OPERATION is generated if program is not a
+// program object.
+func (gl *GL) GetProgramInfoLog(program glbase.Program) []byte {
+ var params [1]int32
+ var length int32
+ gl.GetProgramiv(program, INFO_LOG_LENGTH, params[:])
+ bufSize := params[0]
+ infoLog := make([]byte, int(bufSize))
+ C.gl4_3compat_glGetProgramInfoLog(gl.funcs, C.GLuint(program), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length)), (*C.GLchar)(unsafe.Pointer(&infoLog[0])))
+ return infoLog
+}
+
+// GetProgramiv returns in params the value of a parameter for a specific
+// program object. The following parameters are defined:
+//
+// GL.DELETE_STATUS
+// params returns GL.TRUE if program is currently flagged for deletion,
+// and GL.FALSE otherwise.
+//
+// GL.LINK_STATUS
+// params returns GL.TRUE if the last link operation on program was
+// successful, and GL.FALSE otherwise.
+//
+// GL.VALIDATE_STATUS
+// params returns GL.TRUE or if the last validation operation on
+// program was successful, and GL.FALSE otherwise.
+//
+// GL.INFO_LOG_LENGTH
+// params returns the number of characters in the information log for
+// program including the null termination character (the size of
+// the character buffer required to store the information log). If
+// program has no information log, a value of 0 is returned.
+//
+// GL.ATTACHED_SHADERS
+// params returns the number of shader objects attached to program.
+//
+// GL.ACTIVE_ATTRIBUTES
+// params returns the number of active attribute variables for program.
+//
+// GL.ACTIVE_ATTRIBUTE_MAX_LENGTH
+// params returns the length of the longest active attribute name for
+// program, including the null termination character (the size of
+// the character buffer required to store the longest attribute name).
+// If no active attributes exist, 0 is returned.
+//
+// GL.ACTIVE_UNIFORMS
+// params returns the number of active uniform variables for program.
+//
+// GL.ACTIVE_UNIFORM_MAX_LENGTH
+// params returns the length of the longest active uniform variable
+// name for program, including the null termination character (i.e.,
+// the size of the character buffer required to store the longest
+// uniform variable name). If no active uniform variables exist, 0 is
+// returned.
+//
+// GL.TRANSFORM_FEEDBACK_BUFFER_MODE
+// params returns a symbolic constant indicating the buffer mode used
+// when transform feedback is active. This may be GL.SEPARATE_ATTRIBS
+// or GL.INTERLEAVED_ATTRIBS.
+//
+// GL.TRANSFORM_FEEDBACK_VARYINGS
+// params returns the number of varying variables to capture in transform
+// feedback mode for the program.
+//
+// GL.TRANSFORM_FEEDBACK_VARYING_MAX_LENGTH
+// params returns the length of the longest variable name to be used for
+// transform feedback, including the null-terminator.
+//
+// GL.GEOMETRY_VERTICES_OUT
+// params returns the maximum number of vertices that the geometry shader in
+// program will output.
+//
+// GL.GEOMETRY_INPUT_TYPE
+// params returns a symbolic constant indicating the primitive type accepted
+// as input to the geometry shader contained in program.
+//
+// GL.GEOMETRY_OUTPUT_TYPE
+// params returns a symbolic constant indicating the primitive type that will
+// be output by the geometry shader contained in program.
+//
+// GL.ACTIVE_UNIFORM_BLOCKS and GL.ACTIVE_UNIFORM_BLOCK_MAX_NAME_LENGTH are
+// available only if the GL version 3.1 or greater.
+//
+// GL.GEOMETRY_VERTICES_OUT, GL.GEOMETRY_INPUT_TYPE and
+// GL.GEOMETRY_OUTPUT_TYPE are accepted only if the GL version is 3.2 or
+// greater.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program does not refer to a
+// program object. GL.INVALID_OPERATION is generated if pname is
+// GL.GEOMETRY_VERTICES_OUT, GL.GEOMETRY_INPUT_TYPE, or
+// GL.GEOMETRY_OUTPUT_TYPE, and program does not contain a geometry shader.
+// GL.INVALID_ENUM is generated if pname is not an accepted value.
+func (gl *GL) GetProgramiv(program glbase.Program, pname glbase.Enum, params []int32) {
+ var params_c [4]int32
+ C.gl4_3compat_glGetProgramiv(gl.funcs, C.GLuint(program), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetAttribLocation queries the previously linked program object specified
+// by program for the attribute variable specified by name and returns the
+// index of the generic vertex attribute that is bound to that attribute
+// variable. If name is a matrix attribute variable, the index of the first
+// column of the matrix is returned. If the named attribute variable is not
+// an active attribute in the specified program object or if name starts with
+// the reserved prefix "gl_", a value of -1 is returned.
+//
+// The association between an attribute variable name and a generic attribute
+// index can be specified at any time by calling BindAttribLocation.
+// Attribute bindings do not go into effect until LinkProgram is called.
+// After a program object has been linked successfully, the index values for
+// attribute variables remain fixed until the next link command occurs. The
+// attribute values can only be queried after a link if the link was
+// successful. GetAttribLocation returns the binding that actually went
+// into effect the last time LinkProgram was called for the specified
+// program object. Attribute bindings that have been specified since the last
+// link operation are not returned by GetAttribLocation.
+//
+// Error GL_INVALID_OPERATION is generated if program is not a value
+// generated by OpenGL. GL_INVALID_OPERATION is generated if program is not
+// a program object. GL_INVALID_OPERATION is generated if program has not
+// been successfully linked. GL_INVALID_OPERATION is generated if
+// GetAttribLocation is executed between the execution of Begin and the
+// corresponding execution of End.
+//
+// GetAttribLocation is available in GL version 2.0 or greater.
+func (gl *GL) GetAttribLocation(program glbase.Program, name string) glbase.Attrib {
+ name_cstr := C.CString(name)
+ glresult := C.gl4_3compat_glGetAttribLocation(gl.funcs, C.GLuint(program), (*C.GLchar)(name_cstr))
+ C.free(unsafe.Pointer(name_cstr))
+ return glbase.Attrib(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetAttachedShaders.xml
+func (gl *GL) GetAttachedShaders(program glbase.Program, maxCount int32, count []int, obj []uint32) {
+ C.gl4_3compat_glGetAttachedShaders(gl.funcs, C.GLuint(program), C.GLsizei(maxCount), (*C.GLsizei)(unsafe.Pointer(&count[0])), (*C.GLuint)(unsafe.Pointer(&obj[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveUniform.xml
+func (gl *GL) GetActiveUniform(program glbase.Program, index uint32, bufSize int32, length []int32, size []int, gltype []glbase.Enum, name []byte) {
+ C.gl4_3compat_glGetActiveUniform(gl.funcs, C.GLuint(program), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLint)(unsafe.Pointer(&size[0])), (*C.GLenum)(unsafe.Pointer(&gltype[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveAttrib.xml
+func (gl *GL) GetActiveAttrib(program glbase.Program, index glbase.Attrib, bufSize int32, length []int32, size []int, gltype []glbase.Enum, name []byte) {
+ C.gl4_3compat_glGetActiveAttrib(gl.funcs, C.GLuint(program), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLint)(unsafe.Pointer(&size[0])), (*C.GLenum)(unsafe.Pointer(&gltype[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEnableVertexAttribArray.xml
+func (gl *GL) EnableVertexAttribArray(index glbase.Attrib) {
+ C.gl4_3compat_glEnableVertexAttribArray(gl.funcs, C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDisableVertexAttribArray.xml
+func (gl *GL) DisableVertexAttribArray(index glbase.Attrib) {
+ C.gl4_3compat_glDisableVertexAttribArray(gl.funcs, C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDetachShader.xml
+func (gl *GL) DetachShader(program glbase.Program, shader glbase.Shader) {
+ C.gl4_3compat_glDetachShader(gl.funcs, C.GLuint(program), C.GLuint(shader))
+}
+
+// DeleteShader frees the memory and invalidates the name associated with
+// the shader object specified by shader. This command effectively undoes the
+// effects of a call to CreateShader.
+//
+// If a shader object to be deleted is attached to a program object, it will
+// be flagged for deletion, but it will not be deleted until it is no longer
+// attached to any program object, for any rendering context (it must
+// be detached from wherever it was attached before it will be deleted). A
+// value of 0 for shader will be silently ignored.
+//
+// To determine whether an object has been flagged for deletion, call
+// GetShader with arguments shader and GL.DELETE_STATUS.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL.
+//
+// DeleteShader is available in GL version 2.0 or greater.
+func (gl *GL) DeleteShader(shader glbase.Shader) {
+ C.gl4_3compat_glDeleteShader(gl.funcs, C.GLuint(shader))
+}
+
+// DeleteProgram frees the memory and invalidates the name associated with
+// the program object specified by program. This command effectively undoes
+// the effects of a call to CreateProgram.
+//
+// If a program object is in use as part of current rendering state, it will
+// be flagged for deletion, but it will not be deleted until it is no longer
+// part of current state for any rendering context. If a program object to be
+// deleted has shader objects attached to it, those shader objects will be
+// automatically detached but not deleted unless they have already been
+// flagged for deletion by a previous call to DeleteShader. A value of 0
+// for program will be silently ignored.
+//
+// To determine whether a program object has been flagged for deletion, call
+// GetProgram with arguments program and GL.DELETE_STATUS.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL.
+//
+// DeleteProgram is available in GL version 2.0 or greater.
+func (gl *GL) DeleteProgram(program glbase.Program) {
+ C.gl4_3compat_glDeleteProgram(gl.funcs, C.GLuint(program))
+}
+
+// CreateShader creates an empty shader object and returns a non-zero value
+// by which it can be referenced. A shader object is used to maintain the
+// source code strings that define a shader. shaderType indicates the type of
+// shader to be created.
+//
+// Two types of shaders are supported. A shader of type GL.VERTEX_SHADER is a
+// shader that is intended to run on the programmable vertex processor and
+// replace the fixed functionality vertex processing in OpenGL. A shader of
+// type GL.FRAGMENT_SHADER is a shader that is intended to run on the
+// programmable fragment processor and replace the fixed functionality
+// fragment processing in OpenGL.
+//
+// When created, a shader object's GL.SHADER_TYPE parameter is set to either
+// GL.VERTEX_SHADER or GL.FRAGMENT_SHADER, depending on the value of
+// shaderType.
+//
+// Like display lists and texture objects, the name space for shader objects
+// may be shared across a set of contexts, as long as the server sides of the
+// contexts share the same address space. If the name space is shared across
+// contexts, any attached objects and the data associated with those attached
+// objects are shared as well.
+//
+// This function returns 0 if an error occurs creating the shader object.
+//
+// Error GL.INVALID_ENUM is generated if shaderType is not an accepted value.
+// GL.INVALID_OPERATION is generated if CreateShader is executed between the
+// execution of Begin and the corresponding execution of End.
+//
+// CreateShader is available in GL version 2.0 or greater.
+func (gl *GL) CreateShader(gltype glbase.Enum) glbase.Shader {
+ glresult := C.gl4_3compat_glCreateShader(gl.funcs, C.GLenum(gltype))
+ return glbase.Shader(glresult)
+}
+
+// CreateProgram creates an empty program object and returns a non-zero
+// value by which it can be referenced. A program object is an object to
+// which shader objects can be attached. This provides a mechanism to specify
+// the shader objects that will be linked to create a program. It also
+// provides a means for checking the compatibility of the shaders that will
+// be used to create a program (for instance, checking the compatibility
+// between a vertex shader and a fragment shader). When no longer needed as
+// part of a program object, shader objects can be detached.
+//
+// One or more executables are created in a program object by successfully
+// attaching shader objects to it with AttachShader, successfully compiling
+// the shader objects with CompileShader, and successfully linking the
+// program object with LinkProgram. These executables are made part of
+// current state when UseProgram is called. Program objects can be deleted
+// by calling DeleteProgram. The memory associated with the program object
+// will be deleted when it is no longer part of current rendering state for
+// any context.
+//
+// Like display lists and texture objects, the name space for program objects
+// may be shared across a set of contexts, as long as the server sides of the
+// contexts share the same address space. If the name space is shared across
+// contexts, any attached objects and the data associated with those attached
+// objects are shared as well.
+//
+// Applications are responsible for providing the synchronization across API
+// calls when objects are accessed from different execution threads.
+//
+// This function returns 0 if an error occurs creating the program object.
+//
+// Error GL.INVALID_OPERATION is generated if CreateProgram is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// CreateProgram is available in GL version 2.0 or greater.
+func (gl *GL) CreateProgram() glbase.Program {
+ glresult := C.gl4_3compat_glCreateProgram(gl.funcs)
+ return glbase.Program(glresult)
+}
+
+// CompileShader compiles the source code strings that have been stored in
+// the shader object specified by shader.
+//
+// The compilation status will be stored as part of the shader object's
+// state. This value will be set to GL.TRUE if the shader was compiled without
+// errors and is ready for use, and GL.FALSE otherwise. It can be queried by
+// calling GetShaderiv with arguments shader and GL.COMPILE_STATUS.
+//
+// Compilation of a shader can fail for a number of reasons as specified by
+// the OpenGL Shading Language Specification. Whether or not the compilation
+// was successful, information about the compilation can be obtained from the
+// shader object's information log by calling GetShaderInfoLog.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader is not a shader
+// object. GL.INVALID_OPERATION is generated if CompileShader is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// CompileShader is available in GL version 2.0 or greater.
+func (gl *GL) CompileShader(shader glbase.Shader) {
+ C.gl4_3compat_glCompileShader(gl.funcs, C.GLuint(shader))
+}
+
+// BindAttribLocation associates a user-defined attribute variable in the program
+// object specified by program with a generic vertex attribute index. The name
+// parameter specifies the name of the vertex shader attribute variable to
+// which index is to be bound. When program is made part of the current state,
+// values provided via the generic vertex attribute index will modify the
+// value of the user-defined attribute variable specified by name.
+//
+// If name refers to a matrix attribute variable, index refers to the first
+// column of the matrix. Other matrix columns are then automatically bound to
+// locations index+1 for a matrix of type mat2; index+1 and index+2 for a
+// matrix of type mat3; and index+1, index+2, and index+3 for a matrix of
+// type mat4.
+//
+// This command makes it possible for vertex shaders to use descriptive names
+// for attribute variables rather than generic variables that are numbered
+// from 0 to GL.MAX_VERTEX_ATTRIBS-1. The values sent to each generic
+// attribute index are part of current state, just like standard vertex
+// attributes such as color, normal, and vertex position. If a different
+// program object is made current by calling UseProgram, the generic vertex
+// attributes are tracked in such a way that the same values will be observed
+// by attributes in the new program object that are also bound to index.
+//
+// Attribute variable name-to-generic attribute index bindings for a program
+// object can be explicitly assigned at any time by calling
+// BindAttribLocation. Attribute bindings do not go into effect until
+// LinkProgram is called. After a program object has been linked
+// successfully, the index values for generic attributes remain fixed (and
+// their values can be queried) until the next link command occurs.
+//
+// Applications are not allowed to bind any of the standard OpenGL vertex
+// attributes using this command, as they are bound automatically when
+// needed. Any attribute binding that occurs after the program object has
+// been linked will not take effect until the next time the program object is
+// linked.
+//
+// If name was bound previously, that information is lost. Thus you cannot
+// bind one user-defined attribute variable to multiple indices, but you can
+// bind multiple user-defined attribute variables to the same index.
+//
+// Applications are allowed to bind more than one user-defined attribute
+// variable to the same generic vertex attribute index. This is called
+// aliasing, and it is allowed only if just one of the aliased attributes is
+// active in the executable program, or if no path through the shader
+// consumes more than one attribute of a set of attributes aliased to the
+// same location. The compiler and linker are allowed to assume that no
+// aliasing is done and are free to employ optimizations that work only in
+// the absence of aliasing. OpenGL implementations are not required to do
+// error checking to detect aliasing. Because there is no way to bind
+// standard attributes, it is not possible to alias generic attributes with
+// conventional ones (except for generic attribute 0).
+//
+// BindAttribLocation can be called before any vertex shader objects are
+// bound to the specified program object. It is also permissible to bind a
+// generic attribute index to an attribute variable name that is never used
+// in a vertex shader.
+//
+// Active attributes that are not explicitly bound will be bound by the
+// linker when LinkProgram is called. The locations assigned can be queried
+// by calling GetAttribLocation.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS.
+// GL.INVALID_OPERATION is generated if name starts with the reserved prefix "gl_".
+// GL.INVALID_VALUE is generated if program is not a value generated by OpenGL.
+// GL.INVALID_OPERATION is generated if program is not a program object.
+// GL.INVALID_OPERATION is generated if BindAttribLocation is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// BindAttribLocation is available in GL version 2.0 or greater.
+func (gl *GL) BindAttribLocation(program glbase.Program, index glbase.Attrib, name string) {
+ name_cstr := C.CString(name)
+ C.gl4_3compat_glBindAttribLocation(gl.funcs, C.GLuint(program), C.GLuint(index), (*C.GLchar)(name_cstr))
+ C.free(unsafe.Pointer(name_cstr))
+}
+
+// AttachShader attaches a shader object to a program object.
+//
+// In order to create an executable, there must be a way to specify the list
+// of things that will be linked together. Program objects provide this
+// mechanism. Shaders that are to be linked together in a program object must
+// first be attached to that program object. This indicates that shader will
+// be included in link operations that will be performed on program.
+//
+// All operations that can be performed on a shader object are valid whether
+// or not the shader object is attached to a program object. It is
+// permissible to attach a shader object to a program object before source
+// code has been loaded into the shader object or before the shader object
+// has been compiled. It is permissible to attach multiple shader objects of
+// the same type because each may contain a portion of the complete shader.
+// It is also permissible to attach a shader object to more than one program
+// object. If a shader object is deleted while it is attached to a program
+// object, it will be flagged for deletion, and deletion will not occur until
+// DetachShader is called to detach it from all program objects to which it
+// is attached.
+//
+// Error GL.INVALID_VALUE is generated if either program or shader is not a
+// value generated by OpenGL. GL.INVALID_OPERATION is generated if program
+// is not a program object. GL.INVALID_OPERATION is generated if shader is
+// not a shader object. GL.INVALID_OPERATION is generated if shader is
+// already attached to program. GL.INVALID_OPERATION is generated if
+// AttachShader is executed between the execution of Begin and the
+// corresponding execution of End.
+//
+// AttachShader is available in GL version 2.0 or greater.
+func (gl *GL) AttachShader(program glbase.Program, shader glbase.Shader) {
+ C.gl4_3compat_glAttachShader(gl.funcs, C.GLuint(program), C.GLuint(shader))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glStencilMaskSeparate.xml
+func (gl *GL) StencilMaskSeparate(face glbase.Enum, mask uint32) {
+ C.gl4_3compat_glStencilMaskSeparate(gl.funcs, C.GLenum(face), C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glStencilFuncSeparate.xml
+func (gl *GL) StencilFuncSeparate(face, glfunc glbase.Enum, ref int32, mask uint32) {
+ C.gl4_3compat_glStencilFuncSeparate(gl.funcs, C.GLenum(face), C.GLenum(glfunc), C.GLint(ref), C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glStencilOpSeparate.xml
+func (gl *GL) StencilOpSeparate(face, sfail, dpfail, dppass glbase.Enum) {
+ C.gl4_3compat_glStencilOpSeparate(gl.funcs, C.GLenum(face), C.GLenum(sfail), C.GLenum(dpfail), C.GLenum(dppass))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawBuffers.xml
+func (gl *GL) DrawBuffers(n int, bufs []glbase.Enum) {
+ C.gl4_3compat_glDrawBuffers(gl.funcs, C.GLsizei(n), (*C.GLenum)(unsafe.Pointer(&bufs[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendEquationSeparate.xml
+func (gl *GL) BlendEquationSeparate(modeRGB, modeAlpha glbase.Enum) {
+ C.gl4_3compat_glBlendEquationSeparate(gl.funcs, C.GLenum(modeRGB), C.GLenum(modeAlpha))
+}
+
+// UniformMatrix4x3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix4x3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix4x3fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(4*3) != 0 {
+ panic("invalid value length for UniformMatrix4x3fv")
+ }
+ count := len(value) / (4 * 3)
+ C.gl4_3compat_glUniformMatrix4x3fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix3x4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix3x4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix3x4fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(3*4) != 0 {
+ panic("invalid value length for UniformMatrix3x4fv")
+ }
+ count := len(value) / (3 * 4)
+ C.gl4_3compat_glUniformMatrix3x4fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix4x2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix4x2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix4x2fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(4*2) != 0 {
+ panic("invalid value length for UniformMatrix4x2fv")
+ }
+ count := len(value) / (4 * 2)
+ C.gl4_3compat_glUniformMatrix4x2fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix2x4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix2x4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix2x4fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(2*4) != 0 {
+ panic("invalid value length for UniformMatrix2x4fv")
+ }
+ count := len(value) / (2 * 4)
+ C.gl4_3compat_glUniformMatrix2x4fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix3x2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix3x2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix3x2fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(3*2) != 0 {
+ panic("invalid value length for UniformMatrix3x2fv")
+ }
+ count := len(value) / (3 * 2)
+ C.gl4_3compat_glUniformMatrix3x2fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix2x3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix2x3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix2x3fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(2*3) != 0 {
+ panic("invalid value length for UniformMatrix2x3fv")
+ }
+ count := len(value) / (2 * 3)
+ C.gl4_3compat_glUniformMatrix2x3fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsVertexArray.xml
+func (gl *GL) IsVertexArray(array uint32) bool {
+ glresult := C.gl4_3compat_glIsVertexArray(gl.funcs, C.GLuint(array))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGenVertexArrays.xml
+func (gl *GL) GenVertexArrays(n int, arrays []uint32) {
+ C.gl4_3compat_glGenVertexArrays(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&arrays[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDeleteVertexArrays.xml
+func (gl *GL) DeleteVertexArrays(n int, arrays []uint32) {
+ C.gl4_3compat_glDeleteVertexArrays(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&arrays[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindVertexArray.xml
+func (gl *GL) BindVertexArray(array uint32) {
+ C.gl4_3compat_glBindVertexArray(gl.funcs, C.GLuint(array))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFlushMappedBufferRange.xml
+func (gl *GL) FlushMappedBufferRange(target glbase.Enum, offset, length int) {
+ C.gl4_3compat_glFlushMappedBufferRange(gl.funcs, C.GLenum(target), C.GLintptr(offset), C.GLsizeiptr(length))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFramebufferTextureLayer.xml
+func (gl *GL) FramebufferTextureLayer(target, attachment glbase.Enum, texture glbase.Texture, level int, layer int32) {
+ C.gl4_3compat_glFramebufferTextureLayer(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLuint(texture), C.GLint(level), C.GLint(layer))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRenderbufferStorageMultisample.xml
+func (gl *GL) RenderbufferStorageMultisample(target glbase.Enum, samples int32, internalFormat glbase.Enum, width, height int) {
+ C.gl4_3compat_glRenderbufferStorageMultisample(gl.funcs, C.GLenum(target), C.GLsizei(samples), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlitFramebuffer.xml
+func (gl *GL) BlitFramebuffer(srcX0, srcY0, srcX1, srcY1, dstX0, dstY0, dstX1, dstY1 int32, mask glbase.Bitfield, filter glbase.Enum) {
+ C.gl4_3compat_glBlitFramebuffer(gl.funcs, C.GLint(srcX0), C.GLint(srcY0), C.GLint(srcX1), C.GLint(srcY1), C.GLint(dstX0), C.GLint(dstY0), C.GLint(dstX1), C.GLint(dstY1), C.GLbitfield(mask), C.GLenum(filter))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGenerateMipmap.xml
+func (gl *GL) GenerateMipmap(target glbase.Enum) {
+ C.gl4_3compat_glGenerateMipmap(gl.funcs, C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetFramebufferAttachmentParameteriv.xml
+func (gl *GL) GetFramebufferAttachmentParameteriv(target, attachment, pname glbase.Enum, params []int32) {
+ C.gl4_3compat_glGetFramebufferAttachmentParameteriv(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFramebufferRenderbuffer.xml
+func (gl *GL) FramebufferRenderbuffer(target, attachment, renderbuffertarget glbase.Enum, renderbuffer glbase.Renderbuffer) {
+ C.gl4_3compat_glFramebufferRenderbuffer(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(renderbuffertarget), C.GLuint(renderbuffer))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFramebufferTexture3D.xml
+func (gl *GL) FramebufferTexture3D(target, attachment, textarget glbase.Enum, texture glbase.Texture, level int, zoffset int32) {
+ C.gl4_3compat_glFramebufferTexture3D(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(textarget), C.GLuint(texture), C.GLint(level), C.GLint(zoffset))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFramebufferTexture2D.xml
+func (gl *GL) FramebufferTexture2D(target, attachment, textarget glbase.Enum, texture glbase.Texture, level int) {
+ C.gl4_3compat_glFramebufferTexture2D(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(textarget), C.GLuint(texture), C.GLint(level))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFramebufferTexture1D.xml
+func (gl *GL) FramebufferTexture1D(target, attachment, textarget glbase.Enum, texture glbase.Texture, level int) {
+ C.gl4_3compat_glFramebufferTexture1D(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(textarget), C.GLuint(texture), C.GLint(level))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCheckFramebufferStatus.xml
+func (gl *GL) CheckFramebufferStatus(target glbase.Enum) glbase.Enum {
+ glresult := C.gl4_3compat_glCheckFramebufferStatus(gl.funcs, C.GLenum(target))
+ return glbase.Enum(glresult)
+}
+
+// GenFramebuffers returns n framebuffer object names in ids. There is no
+// guarantee that the names form a contiguous set of integers; however, it is
+// guaranteed that none of the returned names was in use immediately before
+// the call to GenFramebuffers.
+//
+// Framebuffer object names returned by a call to GenFramebuffers are not
+// returned by subsequent calls, unless they are first deleted with
+// DeleteFramebuffers.
+//
+// The names returned in ids are marked as used, for the purposes of
+// GenFramebuffers only, but they acquire state and type only when they are
+// first bound.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+func (gl *GL) GenFramebuffers(n int) []glbase.Framebuffer {
+ if n == 0 {
+ return nil
+ }
+ framebuffers := make([]glbase.Framebuffer, n)
+ C.gl4_3compat_glGenFramebuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&framebuffers[0])))
+ return framebuffers
+}
+
+// DeleteFramebuffers deletes the framebuffer objects whose names are
+// stored in the framebuffers slice. The name zero is reserved by the GL and
+// is silently ignored, should it occur in framebuffers, as are other unused
+// names. Once a framebuffer object is deleted, its name is again unused and
+// it has no attachments. If a framebuffer that is currently bound to one or
+// more of the targets GL.DRAW_FRAMEBUFFER or GL.READ_FRAMEBUFFER is deleted,
+// it is as though BindFramebuffer had been executed with the corresponding
+// target and framebuffer zero.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// DeleteFramebuffers is available in GL version 3.0 or greater.
+func (gl *GL) DeleteFramebuffers(framebuffers []glbase.Framebuffer) {
+ n := len(framebuffers)
+ if n == 0 {
+ return
+ }
+ C.gl4_3compat_glDeleteFramebuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&framebuffers[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindFramebuffer.xml
+func (gl *GL) BindFramebuffer(target glbase.Enum, framebuffer glbase.Framebuffer) {
+ C.gl4_3compat_glBindFramebuffer(gl.funcs, C.GLenum(target), C.GLuint(framebuffer))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsFramebuffer.xml
+func (gl *GL) IsFramebuffer(framebuffer glbase.Framebuffer) bool {
+ glresult := C.gl4_3compat_glIsFramebuffer(gl.funcs, C.GLuint(framebuffer))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetRenderbufferParameteriv.xml
+func (gl *GL) GetRenderbufferParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl4_3compat_glGetRenderbufferParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRenderbufferStorage.xml
+func (gl *GL) RenderbufferStorage(target, internalFormat glbase.Enum, width, height int) {
+ C.gl4_3compat_glRenderbufferStorage(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height))
+}
+
+// GenRenderbuffers returns n renderbuffer object names in renderbuffers.
+// There is no guarantee that the names form a contiguous set of integers;
+// however, it is guaranteed that none of the returned names was in use
+// immediately before the call to GenRenderbuffers.
+//
+// Renderbuffer object names returned by a call to GenRenderbuffers are not
+// returned by subsequent calls, unless they are first deleted with
+// DeleteRenderbuffers.
+//
+// The names returned in renderbuffers are marked as used, for the purposes
+// of GenRenderbuffers only, but they acquire state and type only when they
+// are first bound.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// GenRenderbuffers is available in GL version 3.0 or greater.
+func (gl *GL) GenRenderbuffers(n int) []glbase.Renderbuffer {
+ if n == 0 {
+ return nil
+ }
+ renderbuffers := make([]glbase.Renderbuffer, n)
+ C.gl4_3compat_glGenRenderbuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&renderbuffers[0])))
+ return renderbuffers
+}
+
+// DeleteRenderbuffers deletes the renderbuffer objects whose names are stored
+// in the renderbuffers slice. The name zero is reserved by the GL and
+// is silently ignored, should it occur in renderbuffers, as are other unused
+// names. Once a renderbuffer object is deleted, its name is again unused and
+// it has no contents. If a renderbuffer that is currently bound to the
+// target GL.RENDERBUFFER is deleted, it is as though BindRenderbuffer had
+// been executed with a target of GL.RENDERBUFFER and a name of zero.
+//
+// If a renderbuffer object is attached to one or more attachment points in
+// the currently bound framebuffer, then it as if FramebufferRenderbuffer
+// had been called, with a renderbuffer of zero for each attachment point to
+// which this image was attached in the currently bound framebuffer. In other
+// words, this renderbuffer object is first detached from all attachment
+// ponits in the currently bound framebuffer. Note that the renderbuffer
+// image is specifically not detached from any non-bound framebuffers.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// DeleteRenderbuffers is available in GL version 3.0 or greater.
+func (gl *GL) DeleteRenderbuffers(renderbuffers []glbase.Renderbuffer) {
+ n := len(renderbuffers)
+ if n == 0 {
+ return
+ }
+ C.gl4_3compat_glDeleteRenderbuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&renderbuffers[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindRenderbuffer.xml
+func (gl *GL) BindRenderbuffer(target glbase.Enum, renderbuffer glbase.Renderbuffer) {
+ C.gl4_3compat_glBindRenderbuffer(gl.funcs, C.GLenum(target), C.GLuint(renderbuffer))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsRenderbuffer.xml
+func (gl *GL) IsRenderbuffer(renderbuffer glbase.Renderbuffer) bool {
+ glresult := C.gl4_3compat_glIsRenderbuffer(gl.funcs, C.GLuint(renderbuffer))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearBufferfi.xml
+func (gl *GL) ClearBufferfi(buffer glbase.Enum, drawbuffer int32, depth float32, stencil int32) {
+ C.gl4_3compat_glClearBufferfi(gl.funcs, C.GLenum(buffer), C.GLint(drawbuffer), C.GLfloat(depth), C.GLint(stencil))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearBufferfv.xml
+func (gl *GL) ClearBufferfv(buffer glbase.Enum, drawbuffer int32, value []float32) {
+ C.gl4_3compat_glClearBufferfv(gl.funcs, C.GLenum(buffer), C.GLint(drawbuffer), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearBufferuiv.xml
+func (gl *GL) ClearBufferuiv(buffer glbase.Enum, drawbuffer int32, value []uint32) {
+ C.gl4_3compat_glClearBufferuiv(gl.funcs, C.GLenum(buffer), C.GLint(drawbuffer), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearBufferiv.xml
+func (gl *GL) ClearBufferiv(buffer glbase.Enum, drawbuffer int32, value []int32) {
+ C.gl4_3compat_glClearBufferiv(gl.funcs, C.GLenum(buffer), C.GLint(drawbuffer), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexParameterIuiv.xml
+func (gl *GL) GetTexParameterIuiv(target, pname glbase.Enum, params []uint32) {
+ C.gl4_3compat_glGetTexParameterIuiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexParameterIiv.xml
+func (gl *GL) GetTexParameterIiv(target, pname glbase.Enum, params []int32) {
+ C.gl4_3compat_glGetTexParameterIiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexParameterIuiv.xml
+func (gl *GL) TexParameterIuiv(target, pname glbase.Enum, params []uint32) {
+ C.gl4_3compat_glTexParameterIuiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexParameterIiv.xml
+func (gl *GL) TexParameterIiv(target, pname glbase.Enum, params []int32) {
+ C.gl4_3compat_glTexParameterIiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// Uniform4uiv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform4uiv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4uiv(location glbase.Uniform, value []uint32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%4 != 0 {
+ panic("invalid value length for Uniform4uiv")
+ }
+ count := len(value) / 4
+ C.gl4_3compat_glUniform4uiv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform3uiv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform3uiv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3uiv(location glbase.Uniform, value []uint32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%3 != 0 {
+ panic("invalid value length for Uniform3uiv")
+ }
+ count := len(value) / 3
+ C.gl4_3compat_glUniform3uiv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform2uiv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform2uiv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2uiv(location glbase.Uniform, value []uint32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%2 != 0 {
+ panic("invalid value length for Uniform2uiv")
+ }
+ count := len(value) / 2
+ C.gl4_3compat_glUniform2uiv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform1uiv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform1uiv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1uiv(location glbase.Uniform, value []uint32) {
+ if len(value) == 0 {
+ return
+ }
+ count := len(value)
+ C.gl4_3compat_glUniform1uiv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4ui modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform4ui operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4ui(location glbase.Uniform, v0, v1, v2, v3 uint32) {
+ C.gl4_3compat_glUniform4ui(gl.funcs, C.GLint(location), C.GLuint(v0), C.GLuint(v1), C.GLuint(v2), C.GLuint(v3))
+}
+
+// Uniform3ui modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform3ui operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3ui(location glbase.Uniform, v0, v1, v2 uint32) {
+ C.gl4_3compat_glUniform3ui(gl.funcs, C.GLint(location), C.GLuint(v0), C.GLuint(v1), C.GLuint(v2))
+}
+
+// Uniform2ui modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform2ui operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2ui(location glbase.Uniform, v0, v1 uint32) {
+ C.gl4_3compat_glUniform2ui(gl.funcs, C.GLint(location), C.GLuint(v0), C.GLuint(v1))
+}
+
+// Uniform1ui modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform1ui operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1ui(location glbase.Uniform, v0 uint32) {
+ C.gl4_3compat_glUniform1ui(gl.funcs, C.GLint(location), C.GLuint(v0))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetFragDataLocation.xml
+func (gl *GL) GetFragDataLocation(program glbase.Program, name []byte) int32 {
+ glresult := C.gl4_3compat_glGetFragDataLocation(gl.funcs, C.GLuint(program), (*C.GLchar)(unsafe.Pointer(&name[0])))
+ return int32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindFragDataLocation.xml
+func (gl *GL) BindFragDataLocation(program glbase.Program, color uint32, name []byte) {
+ C.gl4_3compat_glBindFragDataLocation(gl.funcs, C.GLuint(program), C.GLuint(color), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetUniformuiv.xml
+func (gl *GL) GetUniformuiv(program glbase.Program, location glbase.Uniform, params []uint32) {
+ C.gl4_3compat_glGetUniformuiv(gl.funcs, C.GLuint(program), C.GLint(location), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetVertexAttribIuiv.xml
+func (gl *GL) GetVertexAttribIuiv(index glbase.Attrib, pname glbase.Enum, params []uint32) {
+ C.gl4_3compat_glGetVertexAttribIuiv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetVertexAttribIiv.xml
+func (gl *GL) GetVertexAttribIiv(index glbase.Attrib, pname glbase.Enum, params []int32) {
+ C.gl4_3compat_glGetVertexAttribIiv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribIPointer.xml
+func (gl *GL) VertexAttribIPointer(index glbase.Attrib, size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3compat_glVertexAttribIPointer(gl.funcs, C.GLuint(index), C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEndConditionalRender.xml
+func (gl *GL) EndConditionalRender() {
+ C.gl4_3compat_glEndConditionalRender(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBeginConditionalRender.xml
+func (gl *GL) BeginConditionalRender(id uint32, mode glbase.Enum) {
+ C.gl4_3compat_glBeginConditionalRender(gl.funcs, C.GLuint(id), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClampColor.xml
+func (gl *GL) ClampColor(target, clamp glbase.Enum) {
+ C.gl4_3compat_glClampColor(gl.funcs, C.GLenum(target), C.GLenum(clamp))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTransformFeedbackVarying.xml
+func (gl *GL) GetTransformFeedbackVarying(program glbase.Program, index uint32, bufSize int32, length []int32, size []int, gltype []glbase.Enum, name []byte) {
+ C.gl4_3compat_glGetTransformFeedbackVarying(gl.funcs, C.GLuint(program), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLsizei)(unsafe.Pointer(&size[0])), (*C.GLenum)(unsafe.Pointer(&gltype[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindBufferBase.xml
+func (gl *GL) BindBufferBase(target glbase.Enum, index uint32, buffer glbase.Buffer) {
+ C.gl4_3compat_glBindBufferBase(gl.funcs, C.GLenum(target), C.GLuint(index), C.GLuint(buffer))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindBufferRange.xml
+func (gl *GL) BindBufferRange(target glbase.Enum, index uint32, buffer glbase.Buffer, offset, size int) {
+ C.gl4_3compat_glBindBufferRange(gl.funcs, C.GLenum(target), C.GLuint(index), C.GLuint(buffer), C.GLintptr(offset), C.GLsizeiptr(size))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEndTransformFeedback.xml
+func (gl *GL) EndTransformFeedback() {
+ C.gl4_3compat_glEndTransformFeedback(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBeginTransformFeedback.xml
+func (gl *GL) BeginTransformFeedback(primitiveMode glbase.Enum) {
+ C.gl4_3compat_glBeginTransformFeedback(gl.funcs, C.GLenum(primitiveMode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsEnabledi.xml
+func (gl *GL) IsEnabledi(target glbase.Enum, index uint32) bool {
+ glresult := C.gl4_3compat_glIsEnabledi(gl.funcs, C.GLenum(target), C.GLuint(index))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDisablei.xml
+func (gl *GL) Disablei(target glbase.Enum, index uint32) {
+ C.gl4_3compat_glDisablei(gl.funcs, C.GLenum(target), C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEnablei.xml
+func (gl *GL) Enablei(target glbase.Enum, index uint32) {
+ C.gl4_3compat_glEnablei(gl.funcs, C.GLenum(target), C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetIntegeri_v.xml
+func (gl *GL) GetIntegeri_v(target glbase.Enum, index uint32, data []int32) {
+ C.gl4_3compat_glGetIntegeri_v(gl.funcs, C.GLenum(target), C.GLuint(index), (*C.GLint)(unsafe.Pointer(&data[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetBooleani_v.xml
+func (gl *GL) GetBooleani_v(target glbase.Enum, index uint32, data []bool) {
+ C.gl4_3compat_glGetBooleani_v(gl.funcs, C.GLenum(target), C.GLuint(index), (*C.GLboolean)(unsafe.Pointer(&data[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorMaski.xml
+func (gl *GL) ColorMaski(index uint32, r, g, b, a bool) {
+ C.gl4_3compat_glColorMaski(gl.funcs, C.GLuint(index), *(*C.GLboolean)(unsafe.Pointer(&r)), *(*C.GLboolean)(unsafe.Pointer(&g)), *(*C.GLboolean)(unsafe.Pointer(&b)), *(*C.GLboolean)(unsafe.Pointer(&a)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyBufferSubData.xml
+func (gl *GL) CopyBufferSubData(readTarget, writeTarget glbase.Enum, readOffset, writeOffset, size int) {
+ C.gl4_3compat_glCopyBufferSubData(gl.funcs, C.GLenum(readTarget), C.GLenum(writeTarget), C.GLintptr(readOffset), C.GLintptr(writeOffset), C.GLsizeiptr(size))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformBlockBinding.xml
+func (gl *GL) UniformBlockBinding(program glbase.Program, v0, v1 uint32) {
+ C.gl4_3compat_glUniformBlockBinding(gl.funcs, C.GLuint(program), C.GLuint(v0), C.GLuint(v1))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveUniformBlockName.xml
+func (gl *GL) GetActiveUniformBlockName(program glbase.Program, uniformBlockIndex uint32, bufSize int32, length []int32, uniformBlockName []byte) {
+ C.gl4_3compat_glGetActiveUniformBlockName(gl.funcs, C.GLuint(program), C.GLuint(uniformBlockIndex), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&uniformBlockName[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveUniformBlockiv.xml
+func (gl *GL) GetActiveUniformBlockiv(program glbase.Program, uniformBlockIndex uint32, pname glbase.Enum, params []int32) {
+ C.gl4_3compat_glGetActiveUniformBlockiv(gl.funcs, C.GLuint(program), C.GLuint(uniformBlockIndex), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetUniformBlockIndex.xml
+func (gl *GL) GetUniformBlockIndex(program glbase.Program, uniformBlockName []byte) uint32 {
+ glresult := C.gl4_3compat_glGetUniformBlockIndex(gl.funcs, C.GLuint(program), (*C.GLchar)(unsafe.Pointer(&uniformBlockName[0])))
+ return uint32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveUniformName.xml
+func (gl *GL) GetActiveUniformName(program glbase.Program, uniformIndex uint32, bufSize int32, length []int32, uniformName []byte) {
+ C.gl4_3compat_glGetActiveUniformName(gl.funcs, C.GLuint(program), C.GLuint(uniformIndex), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&uniformName[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveUniformsiv.xml
+func (gl *GL) GetActiveUniformsiv(program glbase.Program, uniformCount int32, uniformIndices []uint32, pname glbase.Enum, params []int32) {
+ C.gl4_3compat_glGetActiveUniformsiv(gl.funcs, C.GLuint(program), C.GLsizei(uniformCount), (*C.GLuint)(unsafe.Pointer(&uniformIndices[0])), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPrimitiveRestartIndex.xml
+func (gl *GL) PrimitiveRestartIndex(index uint32) {
+ C.gl4_3compat_glPrimitiveRestartIndex(gl.funcs, C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexBuffer.xml
+func (gl *GL) TexBuffer(target, internalFormat glbase.Enum, buffer glbase.Buffer) {
+ C.gl4_3compat_glTexBuffer(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLuint(buffer))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawElementsInstanced.xml
+func (gl *GL) DrawElementsInstanced(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}, instancecount int32) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3compat_glDrawElementsInstanced(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr, C.GLsizei(instancecount))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawArraysInstanced.xml
+func (gl *GL) DrawArraysInstanced(mode glbase.Enum, first, count int, instancecount int32) {
+ C.gl4_3compat_glDrawArraysInstanced(gl.funcs, C.GLenum(mode), C.GLint(first), C.GLsizei(count), C.GLsizei(instancecount))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSampleMaski.xml
+func (gl *GL) SampleMaski(index uint32, mask glbase.Bitfield) {
+ C.gl4_3compat_glSampleMaski(gl.funcs, C.GLuint(index), C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetMultisamplefv.xml
+func (gl *GL) GetMultisamplefv(pname glbase.Enum, index uint32, val []float32) {
+ C.gl4_3compat_glGetMultisamplefv(gl.funcs, C.GLenum(pname), C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&val[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexImage3DMultisample.xml
+func (gl *GL) TexImage3DMultisample(target glbase.Enum, samples, internalFormat int32, width, height int, depth int32, fixedsamplelocations bool) {
+ C.gl4_3compat_glTexImage3DMultisample(gl.funcs, C.GLenum(target), C.GLsizei(samples), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), *(*C.GLboolean)(unsafe.Pointer(&fixedsamplelocations)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexImage2DMultisample.xml
+func (gl *GL) TexImage2DMultisample(target glbase.Enum, samples, internalFormat int32, width, height int, fixedsamplelocations bool) {
+ C.gl4_3compat_glTexImage2DMultisample(gl.funcs, C.GLenum(target), C.GLsizei(samples), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), *(*C.GLboolean)(unsafe.Pointer(&fixedsamplelocations)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetSynciv.xml
+func (gl *GL) GetSynciv(sync glbase.Sync, pname glbase.Enum, bufSize int32, length, values []int32) {
+ C.gl4_3compat_glGetSynciv(gl.funcs, C.GLsync(unsafe.Pointer(sync)), C.GLenum(pname), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLint)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetInteger64v.xml
+func (gl *GL) GetInteger64v(pname glbase.Enum, params []int64) {
+ C.gl4_3compat_glGetInteger64v(gl.funcs, C.GLenum(pname), (*C.GLint64)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWaitSync.xml
+func (gl *GL) WaitSync(sync glbase.Sync, flags glbase.Bitfield, timeout uint64) {
+ C.gl4_3compat_glWaitSync(gl.funcs, C.GLsync(unsafe.Pointer(sync)), C.GLbitfield(flags), C.GLuint64(timeout))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClientWaitSync.xml
+func (gl *GL) ClientWaitSync(sync glbase.Sync, flags glbase.Bitfield, timeout uint64) glbase.Enum {
+ glresult := C.gl4_3compat_glClientWaitSync(gl.funcs, C.GLsync(unsafe.Pointer(sync)), C.GLbitfield(flags), C.GLuint64(timeout))
+ return glbase.Enum(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDeleteSync.xml
+func (gl *GL) DeleteSync(sync glbase.Sync) {
+ C.gl4_3compat_glDeleteSync(gl.funcs, C.GLsync(unsafe.Pointer(sync)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsSync.xml
+func (gl *GL) IsSync(sync glbase.Sync) bool {
+ glresult := C.gl4_3compat_glIsSync(gl.funcs, C.GLsync(unsafe.Pointer(sync)))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFenceSync.xml
+func (gl *GL) FenceSync(condition glbase.Enum, flags glbase.Bitfield) glbase.Sync {
+ glresult := C.gl4_3compat_glFenceSync(gl.funcs, C.GLenum(condition), C.GLbitfield(flags))
+ return glbase.Sync(unsafe.Pointer(glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProvokingVertex.xml
+func (gl *GL) ProvokingVertex(mode glbase.Enum) {
+ C.gl4_3compat_glProvokingVertex(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawElementsInstancedBaseVertex.xml
+func (gl *GL) DrawElementsInstancedBaseVertex(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}, instancecount, basevertex int32) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3compat_glDrawElementsInstancedBaseVertex(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr, C.GLsizei(instancecount), C.GLint(basevertex))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawRangeElementsBaseVertex.xml
+func (gl *GL) DrawRangeElementsBaseVertex(mode glbase.Enum, start, end uint32, count int, gltype glbase.Enum, indices interface{}, basevertex int32) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3compat_glDrawRangeElementsBaseVertex(gl.funcs, C.GLenum(mode), C.GLuint(start), C.GLuint(end), C.GLsizei(count), C.GLenum(gltype), indices_ptr, C.GLint(basevertex))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawElementsBaseVertex.xml
+func (gl *GL) DrawElementsBaseVertex(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}, basevertex int32) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3compat_glDrawElementsBaseVertex(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr, C.GLint(basevertex))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFramebufferTexture.xml
+func (gl *GL) FramebufferTexture(target, attachment glbase.Enum, texture glbase.Texture, level int) {
+ C.gl4_3compat_glFramebufferTexture(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLuint(texture), C.GLint(level))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetBufferParameteri64v.xml
+func (gl *GL) GetBufferParameteri64v(target, pname glbase.Enum, params []int64) {
+ C.gl4_3compat_glGetBufferParameteri64v(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint64)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetInteger64i_v.xml
+func (gl *GL) GetInteger64i_v(target glbase.Enum, index uint32, data []int64) {
+ C.gl4_3compat_glGetInteger64i_v(gl.funcs, C.GLenum(target), C.GLuint(index), (*C.GLint64)(unsafe.Pointer(&data[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP4uiv.xml
+func (gl *GL) VertexAttribP4uiv(index glbase.Attrib, gltype glbase.Enum, normalized bool, value []uint32) {
+ C.gl4_3compat_glVertexAttribP4uiv(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP4ui.xml
+func (gl *GL) VertexAttribP4ui(index glbase.Attrib, gltype glbase.Enum, normalized bool, value uint32) {
+ C.gl4_3compat_glVertexAttribP4ui(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP3uiv.xml
+func (gl *GL) VertexAttribP3uiv(index glbase.Attrib, gltype glbase.Enum, normalized bool, value []uint32) {
+ C.gl4_3compat_glVertexAttribP3uiv(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP3ui.xml
+func (gl *GL) VertexAttribP3ui(index glbase.Attrib, gltype glbase.Enum, normalized bool, value uint32) {
+ C.gl4_3compat_glVertexAttribP3ui(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP2uiv.xml
+func (gl *GL) VertexAttribP2uiv(index glbase.Attrib, gltype glbase.Enum, normalized bool, value []uint32) {
+ C.gl4_3compat_glVertexAttribP2uiv(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP2ui.xml
+func (gl *GL) VertexAttribP2ui(index glbase.Attrib, gltype glbase.Enum, normalized bool, value uint32) {
+ C.gl4_3compat_glVertexAttribP2ui(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP1uiv.xml
+func (gl *GL) VertexAttribP1uiv(index glbase.Attrib, gltype glbase.Enum, normalized bool, value []uint32) {
+ C.gl4_3compat_glVertexAttribP1uiv(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP1ui.xml
+func (gl *GL) VertexAttribP1ui(index glbase.Attrib, gltype glbase.Enum, normalized bool, value uint32) {
+ C.gl4_3compat_glVertexAttribP1ui(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColorP3uiv.xml
+func (gl *GL) SecondaryColorP3uiv(gltype glbase.Enum, color []uint32) {
+ C.gl4_3compat_glSecondaryColorP3uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&color[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColorP3ui.xml
+func (gl *GL) SecondaryColorP3ui(gltype glbase.Enum, color uint32) {
+ C.gl4_3compat_glSecondaryColorP3ui(gl.funcs, C.GLenum(gltype), C.GLuint(color))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorP4uiv.xml
+func (gl *GL) ColorP4uiv(gltype glbase.Enum, color []uint32) {
+ C.gl4_3compat_glColorP4uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&color[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorP4ui.xml
+func (gl *GL) ColorP4ui(gltype glbase.Enum, color uint32) {
+ C.gl4_3compat_glColorP4ui(gl.funcs, C.GLenum(gltype), C.GLuint(color))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorP3uiv.xml
+func (gl *GL) ColorP3uiv(gltype glbase.Enum, color []uint32) {
+ C.gl4_3compat_glColorP3uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&color[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorP3ui.xml
+func (gl *GL) ColorP3ui(gltype glbase.Enum, color uint32) {
+ C.gl4_3compat_glColorP3ui(gl.funcs, C.GLenum(gltype), C.GLuint(color))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNormalP3uiv.xml
+func (gl *GL) NormalP3uiv(gltype glbase.Enum, coords []uint32) {
+ C.gl4_3compat_glNormalP3uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNormalP3ui.xml
+func (gl *GL) NormalP3ui(gltype glbase.Enum, coords uint32) {
+ C.gl4_3compat_glNormalP3ui(gl.funcs, C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP4uiv.xml
+func (gl *GL) MultiTexCoordP4uiv(texture, gltype glbase.Enum, coords []uint32) {
+ C.gl4_3compat_glMultiTexCoordP4uiv(gl.funcs, C.GLenum(texture), C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP4ui.xml
+func (gl *GL) MultiTexCoordP4ui(texture, gltype glbase.Enum, coords uint32) {
+ C.gl4_3compat_glMultiTexCoordP4ui(gl.funcs, C.GLenum(texture), C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP3uiv.xml
+func (gl *GL) MultiTexCoordP3uiv(texture, gltype glbase.Enum, coords []uint32) {
+ C.gl4_3compat_glMultiTexCoordP3uiv(gl.funcs, C.GLenum(texture), C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP3ui.xml
+func (gl *GL) MultiTexCoordP3ui(texture, gltype glbase.Enum, coords uint32) {
+ C.gl4_3compat_glMultiTexCoordP3ui(gl.funcs, C.GLenum(texture), C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP2uiv.xml
+func (gl *GL) MultiTexCoordP2uiv(texture, gltype glbase.Enum, coords []uint32) {
+ C.gl4_3compat_glMultiTexCoordP2uiv(gl.funcs, C.GLenum(texture), C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP2ui.xml
+func (gl *GL) MultiTexCoordP2ui(texture, gltype glbase.Enum, coords uint32) {
+ C.gl4_3compat_glMultiTexCoordP2ui(gl.funcs, C.GLenum(texture), C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP1uiv.xml
+func (gl *GL) MultiTexCoordP1uiv(texture, gltype glbase.Enum, coords []uint32) {
+ C.gl4_3compat_glMultiTexCoordP1uiv(gl.funcs, C.GLenum(texture), C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP1ui.xml
+func (gl *GL) MultiTexCoordP1ui(texture, gltype glbase.Enum, coords uint32) {
+ C.gl4_3compat_glMultiTexCoordP1ui(gl.funcs, C.GLenum(texture), C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP4uiv.xml
+func (gl *GL) TexCoordP4uiv(gltype glbase.Enum, coords []uint32) {
+ C.gl4_3compat_glTexCoordP4uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP4ui.xml
+func (gl *GL) TexCoordP4ui(gltype glbase.Enum, coords uint32) {
+ C.gl4_3compat_glTexCoordP4ui(gl.funcs, C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP3uiv.xml
+func (gl *GL) TexCoordP3uiv(gltype glbase.Enum, coords []uint32) {
+ C.gl4_3compat_glTexCoordP3uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP3ui.xml
+func (gl *GL) TexCoordP3ui(gltype glbase.Enum, coords uint32) {
+ C.gl4_3compat_glTexCoordP3ui(gl.funcs, C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP2uiv.xml
+func (gl *GL) TexCoordP2uiv(gltype glbase.Enum, coords []uint32) {
+ C.gl4_3compat_glTexCoordP2uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP2ui.xml
+func (gl *GL) TexCoordP2ui(gltype glbase.Enum, coords uint32) {
+ C.gl4_3compat_glTexCoordP2ui(gl.funcs, C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP1uiv.xml
+func (gl *GL) TexCoordP1uiv(gltype glbase.Enum, coords []uint32) {
+ C.gl4_3compat_glTexCoordP1uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP1ui.xml
+func (gl *GL) TexCoordP1ui(gltype glbase.Enum, coords uint32) {
+ C.gl4_3compat_glTexCoordP1ui(gl.funcs, C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexP4uiv.xml
+func (gl *GL) VertexP4uiv(gltype glbase.Enum, value []uint32) {
+ C.gl4_3compat_glVertexP4uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexP4ui.xml
+func (gl *GL) VertexP4ui(gltype glbase.Enum, value uint32) {
+ C.gl4_3compat_glVertexP4ui(gl.funcs, C.GLenum(gltype), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexP3uiv.xml
+func (gl *GL) VertexP3uiv(gltype glbase.Enum, value []uint32) {
+ C.gl4_3compat_glVertexP3uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexP3ui.xml
+func (gl *GL) VertexP3ui(gltype glbase.Enum, value uint32) {
+ C.gl4_3compat_glVertexP3ui(gl.funcs, C.GLenum(gltype), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexP2uiv.xml
+func (gl *GL) VertexP2uiv(gltype glbase.Enum, value []uint32) {
+ C.gl4_3compat_glVertexP2uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexP2ui.xml
+func (gl *GL) VertexP2ui(gltype glbase.Enum, value uint32) {
+ C.gl4_3compat_glVertexP2ui(gl.funcs, C.GLenum(gltype), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetQueryObjectui64v.xml
+func (gl *GL) GetQueryObjectui64v(id uint32, pname glbase.Enum, params []uint64) {
+ C.gl4_3compat_glGetQueryObjectui64v(gl.funcs, C.GLuint(id), C.GLenum(pname), (*C.GLuint64)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetQueryObjecti64v.xml
+func (gl *GL) GetQueryObjecti64v(id uint32, pname glbase.Enum, params []int64) {
+ C.gl4_3compat_glGetQueryObjecti64v(gl.funcs, C.GLuint(id), C.GLenum(pname), (*C.GLint64)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glQueryCounter.xml
+func (gl *GL) QueryCounter(id uint32, target glbase.Enum) {
+ C.gl4_3compat_glQueryCounter(gl.funcs, C.GLuint(id), C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetSamplerParameterIuiv.xml
+func (gl *GL) GetSamplerParameterIuiv(sampler uint32, pname glbase.Enum, params []uint32) {
+ C.gl4_3compat_glGetSamplerParameterIuiv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetSamplerParameterfv.xml
+func (gl *GL) GetSamplerParameterfv(sampler uint32, pname glbase.Enum, params []float32) {
+ C.gl4_3compat_glGetSamplerParameterfv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetSamplerParameterIiv.xml
+func (gl *GL) GetSamplerParameterIiv(sampler uint32, pname glbase.Enum, params []int32) {
+ C.gl4_3compat_glGetSamplerParameterIiv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetSamplerParameteriv.xml
+func (gl *GL) GetSamplerParameteriv(sampler uint32, pname glbase.Enum, params []int32) {
+ C.gl4_3compat_glGetSamplerParameteriv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSamplerParameterIuiv.xml
+func (gl *GL) SamplerParameterIuiv(sampler uint32, pname glbase.Enum, param []uint32) {
+ C.gl4_3compat_glSamplerParameterIuiv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&param[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSamplerParameterIiv.xml
+func (gl *GL) SamplerParameterIiv(sampler uint32, pname glbase.Enum, param []int32) {
+ C.gl4_3compat_glSamplerParameterIiv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&param[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSamplerParameterfv.xml
+func (gl *GL) SamplerParameterfv(sampler uint32, pname glbase.Enum, param []float32) {
+ C.gl4_3compat_glSamplerParameterfv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&param[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSamplerParameterf.xml
+func (gl *GL) SamplerParameterf(sampler uint32, pname glbase.Enum, param float32) {
+ C.gl4_3compat_glSamplerParameterf(gl.funcs, C.GLuint(sampler), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSamplerParameteriv.xml
+func (gl *GL) SamplerParameteriv(sampler uint32, pname glbase.Enum, param []int32) {
+ C.gl4_3compat_glSamplerParameteriv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&param[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSamplerParameteri.xml
+func (gl *GL) SamplerParameteri(sampler uint32, pname glbase.Enum, param int32) {
+ C.gl4_3compat_glSamplerParameteri(gl.funcs, C.GLuint(sampler), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindSampler.xml
+func (gl *GL) BindSampler(unit, sampler uint32) {
+ C.gl4_3compat_glBindSampler(gl.funcs, C.GLuint(unit), C.GLuint(sampler))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsSampler.xml
+func (gl *GL) IsSampler(sampler uint32) bool {
+ glresult := C.gl4_3compat_glIsSampler(gl.funcs, C.GLuint(sampler))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDeleteSamplers.xml
+func (gl *GL) DeleteSamplers(count int, samplers []uint32) {
+ C.gl4_3compat_glDeleteSamplers(gl.funcs, C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&samplers[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGenSamplers.xml
+func (gl *GL) GenSamplers(count int, samplers []uint32) {
+ C.gl4_3compat_glGenSamplers(gl.funcs, C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&samplers[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetFragDataIndex.xml
+func (gl *GL) GetFragDataIndex(program glbase.Program, name []byte) int32 {
+ glresult := C.gl4_3compat_glGetFragDataIndex(gl.funcs, C.GLuint(program), (*C.GLchar)(unsafe.Pointer(&name[0])))
+ return int32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindFragDataLocationIndexed.xml
+func (gl *GL) BindFragDataLocationIndexed(program glbase.Program, colorNumber, index uint32, name []byte) {
+ C.gl4_3compat_glBindFragDataLocationIndexed(gl.funcs, C.GLuint(program), C.GLuint(colorNumber), C.GLuint(index), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribDivisor.xml
+func (gl *GL) VertexAttribDivisor(index glbase.Attrib, divisor uint32) {
+ C.gl4_3compat_glVertexAttribDivisor(gl.funcs, C.GLuint(index), C.GLuint(divisor))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetQueryIndexediv.xml
+func (gl *GL) GetQueryIndexediv(target glbase.Enum, index uint32, pname glbase.Enum, params []int32) {
+ C.gl4_3compat_glGetQueryIndexediv(gl.funcs, C.GLenum(target), C.GLuint(index), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEndQueryIndexed.xml
+func (gl *GL) EndQueryIndexed(target glbase.Enum, index uint32) {
+ C.gl4_3compat_glEndQueryIndexed(gl.funcs, C.GLenum(target), C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBeginQueryIndexed.xml
+func (gl *GL) BeginQueryIndexed(target glbase.Enum, index, id uint32) {
+ C.gl4_3compat_glBeginQueryIndexed(gl.funcs, C.GLenum(target), C.GLuint(index), C.GLuint(id))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawTransformFeedbackStream.xml
+func (gl *GL) DrawTransformFeedbackStream(mode glbase.Enum, id, stream uint32) {
+ C.gl4_3compat_glDrawTransformFeedbackStream(gl.funcs, C.GLenum(mode), C.GLuint(id), C.GLuint(stream))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawTransformFeedback.xml
+func (gl *GL) DrawTransformFeedback(mode glbase.Enum, id uint32) {
+ C.gl4_3compat_glDrawTransformFeedback(gl.funcs, C.GLenum(mode), C.GLuint(id))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glResumeTransformFeedback.xml
+func (gl *GL) ResumeTransformFeedback() {
+ C.gl4_3compat_glResumeTransformFeedback(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPauseTransformFeedback.xml
+func (gl *GL) PauseTransformFeedback() {
+ C.gl4_3compat_glPauseTransformFeedback(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsTransformFeedback.xml
+func (gl *GL) IsTransformFeedback(id uint32) bool {
+ glresult := C.gl4_3compat_glIsTransformFeedback(gl.funcs, C.GLuint(id))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGenTransformFeedbacks.xml
+func (gl *GL) GenTransformFeedbacks(n int, ids []uint32) {
+ C.gl4_3compat_glGenTransformFeedbacks(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&ids[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDeleteTransformFeedbacks.xml
+func (gl *GL) DeleteTransformFeedbacks(n int, ids []uint32) {
+ C.gl4_3compat_glDeleteTransformFeedbacks(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&ids[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindTransformFeedback.xml
+func (gl *GL) BindTransformFeedback(target glbase.Enum, id uint32) {
+ C.gl4_3compat_glBindTransformFeedback(gl.funcs, C.GLenum(target), C.GLuint(id))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPatchParameterfv.xml
+func (gl *GL) PatchParameterfv(pname glbase.Enum, values []float32) {
+ C.gl4_3compat_glPatchParameterfv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPatchParameteri.xml
+func (gl *GL) PatchParameteri(pname glbase.Enum, value int32) {
+ C.gl4_3compat_glPatchParameteri(gl.funcs, C.GLenum(pname), C.GLint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetProgramStageiv.xml
+func (gl *GL) GetProgramStageiv(program glbase.Program, shadertype, pname glbase.Enum, values []int32) {
+ C.gl4_3compat_glGetProgramStageiv(gl.funcs, C.GLuint(program), C.GLenum(shadertype), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetUniformSubroutineuiv.xml
+func (gl *GL) GetUniformSubroutineuiv(shadertype glbase.Enum, location glbase.Uniform, params []uint32) {
+ C.gl4_3compat_glGetUniformSubroutineuiv(gl.funcs, C.GLenum(shadertype), C.GLint(location), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformSubroutinesuiv.xml
+func (gl *GL) UniformSubroutinesuiv(shadertype glbase.Enum, count int, value []uint32) {
+ C.gl4_3compat_glUniformSubroutinesuiv(gl.funcs, C.GLenum(shadertype), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveSubroutineName.xml
+func (gl *GL) GetActiveSubroutineName(program glbase.Program, shadertype glbase.Enum, index uint32, bufSize int32, length []int32, name []byte) {
+ C.gl4_3compat_glGetActiveSubroutineName(gl.funcs, C.GLuint(program), C.GLenum(shadertype), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveSubroutineUniformName.xml
+func (gl *GL) GetActiveSubroutineUniformName(program glbase.Program, shadertype glbase.Enum, index uint32, bufSize int32, length []int32, name []byte) {
+ C.gl4_3compat_glGetActiveSubroutineUniformName(gl.funcs, C.GLuint(program), C.GLenum(shadertype), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveSubroutineUniformiv.xml
+func (gl *GL) GetActiveSubroutineUniformiv(program glbase.Program, shadertype glbase.Enum, index uint32, pname glbase.Enum, values []int32) {
+ C.gl4_3compat_glGetActiveSubroutineUniformiv(gl.funcs, C.GLuint(program), C.GLenum(shadertype), C.GLuint(index), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetSubroutineIndex.xml
+func (gl *GL) GetSubroutineIndex(program glbase.Program, shadertype glbase.Enum, name []byte) uint32 {
+ glresult := C.gl4_3compat_glGetSubroutineIndex(gl.funcs, C.GLuint(program), C.GLenum(shadertype), (*C.GLchar)(unsafe.Pointer(&name[0])))
+ return uint32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetSubroutineUniformLocation.xml
+func (gl *GL) GetSubroutineUniformLocation(program glbase.Program, shadertype glbase.Enum, name []byte) int32 {
+ glresult := C.gl4_3compat_glGetSubroutineUniformLocation(gl.funcs, C.GLuint(program), C.GLenum(shadertype), (*C.GLchar)(unsafe.Pointer(&name[0])))
+ return int32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetUniformdv.xml
+func (gl *GL) GetUniformdv(program glbase.Program, location glbase.Uniform, params []float64) {
+ C.gl4_3compat_glGetUniformdv(gl.funcs, C.GLuint(program), C.GLint(location), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix4x3dv.xml
+func (gl *GL) UniformMatrix4x3dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_3compat_glUniformMatrix4x3dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix4x2dv.xml
+func (gl *GL) UniformMatrix4x2dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_3compat_glUniformMatrix4x2dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix3x4dv.xml
+func (gl *GL) UniformMatrix3x4dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_3compat_glUniformMatrix3x4dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix3x2dv.xml
+func (gl *GL) UniformMatrix3x2dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_3compat_glUniformMatrix3x2dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix2x4dv.xml
+func (gl *GL) UniformMatrix2x4dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_3compat_glUniformMatrix2x4dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix2x3dv.xml
+func (gl *GL) UniformMatrix2x3dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_3compat_glUniformMatrix2x3dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix4dv.xml
+func (gl *GL) UniformMatrix4dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_3compat_glUniformMatrix4dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix3dv.xml
+func (gl *GL) UniformMatrix3dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_3compat_glUniformMatrix3dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix2dv.xml
+func (gl *GL) UniformMatrix2dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_3compat_glUniformMatrix2dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform4dv.xml
+func (gl *GL) Uniform4dv(location glbase.Uniform, count int, value []float64) {
+ C.gl4_3compat_glUniform4dv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform3dv.xml
+func (gl *GL) Uniform3dv(location glbase.Uniform, count int, value []float64) {
+ C.gl4_3compat_glUniform3dv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform2dv.xml
+func (gl *GL) Uniform2dv(location glbase.Uniform, count int, value []float64) {
+ C.gl4_3compat_glUniform2dv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform1dv.xml
+func (gl *GL) Uniform1dv(location glbase.Uniform, count int, value []float64) {
+ C.gl4_3compat_glUniform1dv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform4d.xml
+func (gl *GL) Uniform4d(location glbase.Uniform, v0, v1, v2, v3 float64) {
+ C.gl4_3compat_glUniform4d(gl.funcs, C.GLint(location), C.GLdouble(v0), C.GLdouble(v1), C.GLdouble(v2), C.GLdouble(v3))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform3d.xml
+func (gl *GL) Uniform3d(location glbase.Uniform, v0, v1, v2 float64) {
+ C.gl4_3compat_glUniform3d(gl.funcs, C.GLint(location), C.GLdouble(v0), C.GLdouble(v1), C.GLdouble(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform2d.xml
+func (gl *GL) Uniform2d(location glbase.Uniform, v0, v1 float64) {
+ C.gl4_3compat_glUniform2d(gl.funcs, C.GLint(location), C.GLdouble(v0), C.GLdouble(v1))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform1d.xml
+func (gl *GL) Uniform1d(location glbase.Uniform, v0 float64) {
+ C.gl4_3compat_glUniform1d(gl.funcs, C.GLint(location), C.GLdouble(v0))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawElementsIndirect.xml
+func (gl *GL) DrawElementsIndirect(mode, gltype glbase.Enum, indirect interface{}) {
+ var indirect_ptr unsafe.Pointer
+ var indirect_v = reflect.ValueOf(indirect)
+ if indirect != nil && indirect_v.Kind() != reflect.Slice {
+ panic("parameter indirect must be a slice")
+ }
+ if indirect != nil {
+ indirect_ptr = unsafe.Pointer(indirect_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3compat_glDrawElementsIndirect(gl.funcs, C.GLenum(mode), C.GLenum(gltype), indirect_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawArraysIndirect.xml
+func (gl *GL) DrawArraysIndirect(mode glbase.Enum, indirect interface{}) {
+ var indirect_ptr unsafe.Pointer
+ var indirect_v = reflect.ValueOf(indirect)
+ if indirect != nil && indirect_v.Kind() != reflect.Slice {
+ panic("parameter indirect must be a slice")
+ }
+ if indirect != nil {
+ indirect_ptr = unsafe.Pointer(indirect_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3compat_glDrawArraysIndirect(gl.funcs, C.GLenum(mode), indirect_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendFuncSeparatei.xml
+func (gl *GL) BlendFuncSeparatei(buf uint32, srcRGB, dstRGB, srcAlpha, dstAlpha glbase.Enum) {
+ C.gl4_3compat_glBlendFuncSeparatei(gl.funcs, C.GLuint(buf), C.GLenum(srcRGB), C.GLenum(dstRGB), C.GLenum(srcAlpha), C.GLenum(dstAlpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendFunci.xml
+func (gl *GL) BlendFunci(buf uint32, src, dst glbase.Enum) {
+ C.gl4_3compat_glBlendFunci(gl.funcs, C.GLuint(buf), C.GLenum(src), C.GLenum(dst))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendEquationSeparatei.xml
+func (gl *GL) BlendEquationSeparatei(buf uint32, modeRGB, modeAlpha glbase.Enum) {
+ C.gl4_3compat_glBlendEquationSeparatei(gl.funcs, C.GLuint(buf), C.GLenum(modeRGB), C.GLenum(modeAlpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendEquationi.xml
+func (gl *GL) BlendEquationi(buf uint32, mode glbase.Enum) {
+ C.gl4_3compat_glBlendEquationi(gl.funcs, C.GLuint(buf), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMinSampleShading.xml
+func (gl *GL) MinSampleShading(value float32) {
+ C.gl4_3compat_glMinSampleShading(gl.funcs, C.GLfloat(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetDoublei_v.xml
+func (gl *GL) GetDoublei_v(target glbase.Enum, index uint32, data []float64) {
+ C.gl4_3compat_glGetDoublei_v(gl.funcs, C.GLenum(target), C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&data[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetFloati_v.xml
+func (gl *GL) GetFloati_v(target glbase.Enum, index uint32, data []float32) {
+ C.gl4_3compat_glGetFloati_v(gl.funcs, C.GLenum(target), C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&data[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDepthRangeIndexed.xml
+func (gl *GL) DepthRangeIndexed(index uint32, n, f float64) {
+ C.gl4_3compat_glDepthRangeIndexed(gl.funcs, C.GLuint(index), C.GLdouble(n), C.GLdouble(f))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDepthRangeArrayv.xml
+func (gl *GL) DepthRangeArrayv(first uint32, count int, v []float64) {
+ C.gl4_3compat_glDepthRangeArrayv(gl.funcs, C.GLuint(first), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glScissorIndexedv.xml
+func (gl *GL) ScissorIndexedv(index uint32, v []int32) {
+ C.gl4_3compat_glScissorIndexedv(gl.funcs, C.GLuint(index), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glScissorIndexed.xml
+func (gl *GL) ScissorIndexed(index uint32, left, bottom int32, width, height int) {
+ C.gl4_3compat_glScissorIndexed(gl.funcs, C.GLuint(index), C.GLint(left), C.GLint(bottom), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glScissorArrayv.xml
+func (gl *GL) ScissorArrayv(first uint32, count int, v []int32) {
+ C.gl4_3compat_glScissorArrayv(gl.funcs, C.GLuint(first), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glViewportIndexedfv.xml
+func (gl *GL) ViewportIndexedfv(index uint32, v []float32) {
+ C.gl4_3compat_glViewportIndexedfv(gl.funcs, C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glViewportIndexedf.xml
+func (gl *GL) ViewportIndexedf(index uint32, x, y, w, h float32) {
+ C.gl4_3compat_glViewportIndexedf(gl.funcs, C.GLuint(index), C.GLfloat(x), C.GLfloat(y), C.GLfloat(w), C.GLfloat(h))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glViewportArrayv.xml
+func (gl *GL) ViewportArrayv(first uint32, count int, v []float32) {
+ C.gl4_3compat_glViewportArrayv(gl.funcs, C.GLuint(first), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetVertexAttribLdv.xml
+func (gl *GL) GetVertexAttribLdv(index glbase.Attrib, pname glbase.Enum, params []float64) {
+ C.gl4_3compat_glGetVertexAttribLdv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribLPointer.xml
+func (gl *GL) VertexAttribLPointer(index glbase.Attrib, size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3compat_glVertexAttribLPointer(gl.funcs, C.GLuint(index), C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribL4dv.xml
+func (gl *GL) VertexAttribL4dv(index glbase.Attrib, v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glVertexAttribL4dv(gl.funcs, C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribL3dv.xml
+func (gl *GL) VertexAttribL3dv(index glbase.Attrib, v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glVertexAttribL3dv(gl.funcs, C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribL2dv.xml
+func (gl *GL) VertexAttribL2dv(index glbase.Attrib, v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glVertexAttribL2dv(gl.funcs, C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribL1dv.xml
+func (gl *GL) VertexAttribL1dv(index glbase.Attrib, v []float64) {
+ C.gl4_3compat_glVertexAttribL1dv(gl.funcs, C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribL4d.xml
+func (gl *GL) VertexAttribL4d(index glbase.Attrib, x, y, z, w float64) {
+ C.gl4_3compat_glVertexAttribL4d(gl.funcs, C.GLuint(index), C.GLdouble(x), C.GLdouble(y), C.GLdouble(z), C.GLdouble(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribL3d.xml
+func (gl *GL) VertexAttribL3d(index glbase.Attrib, x, y, z float64) {
+ C.gl4_3compat_glVertexAttribL3d(gl.funcs, C.GLuint(index), C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribL2d.xml
+func (gl *GL) VertexAttribL2d(index glbase.Attrib, x, y float64) {
+ C.gl4_3compat_glVertexAttribL2d(gl.funcs, C.GLuint(index), C.GLdouble(x), C.GLdouble(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribL1d.xml
+func (gl *GL) VertexAttribL1d(index glbase.Attrib, x float64) {
+ C.gl4_3compat_glVertexAttribL1d(gl.funcs, C.GLuint(index), C.GLdouble(x))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetProgramPipelineInfoLog.xml
+func (gl *GL) GetProgramPipelineInfoLog(pipeline uint32, bufSize int32, length []int32, infoLog []byte) {
+ C.gl4_3compat_glGetProgramPipelineInfoLog(gl.funcs, C.GLuint(pipeline), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&infoLog[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glValidateProgramPipeline.xml
+func (gl *GL) ValidateProgramPipeline(pipeline uint32) {
+ C.gl4_3compat_glValidateProgramPipeline(gl.funcs, C.GLuint(pipeline))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix4x3dv.xml
+func (gl *GL) ProgramUniformMatrix4x3dv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float64) {
+ if len(value) != 3 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_3compat_glProgramUniformMatrix4x3dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix3x4dv.xml
+func (gl *GL) ProgramUniformMatrix3x4dv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float64) {
+ if len(value) != 4 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_3compat_glProgramUniformMatrix3x4dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix4x2dv.xml
+func (gl *GL) ProgramUniformMatrix4x2dv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float64) {
+ if len(value) != 2 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_3compat_glProgramUniformMatrix4x2dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix2x4dv.xml
+func (gl *GL) ProgramUniformMatrix2x4dv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float64) {
+ if len(value) != 4 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_3compat_glProgramUniformMatrix2x4dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix3x2dv.xml
+func (gl *GL) ProgramUniformMatrix3x2dv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float64) {
+ if len(value) != 2 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_3compat_glProgramUniformMatrix3x2dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix2x3dv.xml
+func (gl *GL) ProgramUniformMatrix2x3dv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float64) {
+ if len(value) != 3 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_3compat_glProgramUniformMatrix2x3dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix4x3fv.xml
+func (gl *GL) ProgramUniformMatrix4x3fv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float32) {
+ if len(value) != 3 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_3compat_glProgramUniformMatrix4x3fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix3x4fv.xml
+func (gl *GL) ProgramUniformMatrix3x4fv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float32) {
+ if len(value) != 4 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_3compat_glProgramUniformMatrix3x4fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix4x2fv.xml
+func (gl *GL) ProgramUniformMatrix4x2fv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float32) {
+ if len(value) != 2 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_3compat_glProgramUniformMatrix4x2fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix2x4fv.xml
+func (gl *GL) ProgramUniformMatrix2x4fv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float32) {
+ if len(value) != 4 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_3compat_glProgramUniformMatrix2x4fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix3x2fv.xml
+func (gl *GL) ProgramUniformMatrix3x2fv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float32) {
+ if len(value) != 2 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_3compat_glProgramUniformMatrix3x2fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix2x3fv.xml
+func (gl *GL) ProgramUniformMatrix2x3fv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float32) {
+ if len(value) != 3 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_3compat_glProgramUniformMatrix2x3fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix4dv.xml
+func (gl *GL) ProgramUniformMatrix4dv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float64) {
+ if len(value) != 4 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_3compat_glProgramUniformMatrix4dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix3dv.xml
+func (gl *GL) ProgramUniformMatrix3dv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float64) {
+ if len(value) != 3 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_3compat_glProgramUniformMatrix3dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix2dv.xml
+func (gl *GL) ProgramUniformMatrix2dv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float64) {
+ if len(value) != 2 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_3compat_glProgramUniformMatrix2dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix4fv.xml
+func (gl *GL) ProgramUniformMatrix4fv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float32) {
+ if len(value) != 4 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_3compat_glProgramUniformMatrix4fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix3fv.xml
+func (gl *GL) ProgramUniformMatrix3fv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float32) {
+ if len(value) != 3 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_3compat_glProgramUniformMatrix3fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix2fv.xml
+func (gl *GL) ProgramUniformMatrix2fv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float32) {
+ if len(value) != 2 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_3compat_glProgramUniformMatrix2fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform4uiv.xml
+func (gl *GL) ProgramUniform4uiv(program glbase.Program, location glbase.Uniform, count int, value []uint32) {
+ C.gl4_3compat_glProgramUniform4uiv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform4ui.xml
+func (gl *GL) ProgramUniform4ui(program glbase.Program, location glbase.Uniform, v0, v1, v2, v3 uint32) {
+ C.gl4_3compat_glProgramUniform4ui(gl.funcs, C.GLuint(program), C.GLint(location), C.GLuint(v0), C.GLuint(v1), C.GLuint(v2), C.GLuint(v3))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform4dv.xml
+func (gl *GL) ProgramUniform4dv(program glbase.Program, location glbase.Uniform, count int, value []float64) {
+ if len(value) != 4 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_3compat_glProgramUniform4dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform4d.xml
+func (gl *GL) ProgramUniform4d(program glbase.Program, location glbase.Uniform, v0, v1, v2, v3 float64) {
+ C.gl4_3compat_glProgramUniform4d(gl.funcs, C.GLuint(program), C.GLint(location), C.GLdouble(v0), C.GLdouble(v1), C.GLdouble(v2), C.GLdouble(v3))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform4fv.xml
+func (gl *GL) ProgramUniform4fv(program glbase.Program, location glbase.Uniform, count int, value []float32) {
+ if len(value) != 4 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_3compat_glProgramUniform4fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform4f.xml
+func (gl *GL) ProgramUniform4f(program glbase.Program, location glbase.Uniform, v0, v1, v2, v3 float32) {
+ C.gl4_3compat_glProgramUniform4f(gl.funcs, C.GLuint(program), C.GLint(location), C.GLfloat(v0), C.GLfloat(v1), C.GLfloat(v2), C.GLfloat(v3))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform4iv.xml
+func (gl *GL) ProgramUniform4iv(program glbase.Program, location glbase.Uniform, count int, value []int32) {
+ if len(value) != 4 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_3compat_glProgramUniform4iv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform4i.xml
+func (gl *GL) ProgramUniform4i(program glbase.Program, location glbase.Uniform, v0, v1, v2, v3 int32) {
+ C.gl4_3compat_glProgramUniform4i(gl.funcs, C.GLuint(program), C.GLint(location), C.GLint(v0), C.GLint(v1), C.GLint(v2), C.GLint(v3))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform3uiv.xml
+func (gl *GL) ProgramUniform3uiv(program glbase.Program, location glbase.Uniform, count int, value []uint32) {
+ C.gl4_3compat_glProgramUniform3uiv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform3ui.xml
+func (gl *GL) ProgramUniform3ui(program glbase.Program, location glbase.Uniform, v0, v1, v2 uint32) {
+ C.gl4_3compat_glProgramUniform3ui(gl.funcs, C.GLuint(program), C.GLint(location), C.GLuint(v0), C.GLuint(v1), C.GLuint(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform3dv.xml
+func (gl *GL) ProgramUniform3dv(program glbase.Program, location glbase.Uniform, count int, value []float64) {
+ if len(value) != 3 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_3compat_glProgramUniform3dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform3d.xml
+func (gl *GL) ProgramUniform3d(program glbase.Program, location glbase.Uniform, v0, v1, v2 float64) {
+ C.gl4_3compat_glProgramUniform3d(gl.funcs, C.GLuint(program), C.GLint(location), C.GLdouble(v0), C.GLdouble(v1), C.GLdouble(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform3fv.xml
+func (gl *GL) ProgramUniform3fv(program glbase.Program, location glbase.Uniform, count int, value []float32) {
+ if len(value) != 3 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_3compat_glProgramUniform3fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform3f.xml
+func (gl *GL) ProgramUniform3f(program glbase.Program, location glbase.Uniform, v0, v1, v2 float32) {
+ C.gl4_3compat_glProgramUniform3f(gl.funcs, C.GLuint(program), C.GLint(location), C.GLfloat(v0), C.GLfloat(v1), C.GLfloat(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform3iv.xml
+func (gl *GL) ProgramUniform3iv(program glbase.Program, location glbase.Uniform, count int, value []int32) {
+ if len(value) != 3 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_3compat_glProgramUniform3iv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform3i.xml
+func (gl *GL) ProgramUniform3i(program glbase.Program, location glbase.Uniform, v0, v1, v2 int32) {
+ C.gl4_3compat_glProgramUniform3i(gl.funcs, C.GLuint(program), C.GLint(location), C.GLint(v0), C.GLint(v1), C.GLint(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform2uiv.xml
+func (gl *GL) ProgramUniform2uiv(program glbase.Program, location glbase.Uniform, count int, value []uint32) {
+ C.gl4_3compat_glProgramUniform2uiv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform2ui.xml
+func (gl *GL) ProgramUniform2ui(program glbase.Program, location glbase.Uniform, v0, v1 uint32) {
+ C.gl4_3compat_glProgramUniform2ui(gl.funcs, C.GLuint(program), C.GLint(location), C.GLuint(v0), C.GLuint(v1))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform2dv.xml
+func (gl *GL) ProgramUniform2dv(program glbase.Program, location glbase.Uniform, count int, value []float64) {
+ if len(value) != 2 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_3compat_glProgramUniform2dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform2d.xml
+func (gl *GL) ProgramUniform2d(program glbase.Program, location glbase.Uniform, v0, v1 float64) {
+ C.gl4_3compat_glProgramUniform2d(gl.funcs, C.GLuint(program), C.GLint(location), C.GLdouble(v0), C.GLdouble(v1))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform2fv.xml
+func (gl *GL) ProgramUniform2fv(program glbase.Program, location glbase.Uniform, count int, value []float32) {
+ if len(value) != 2 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_3compat_glProgramUniform2fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform2f.xml
+func (gl *GL) ProgramUniform2f(program glbase.Program, location glbase.Uniform, v0, v1 float32) {
+ C.gl4_3compat_glProgramUniform2f(gl.funcs, C.GLuint(program), C.GLint(location), C.GLfloat(v0), C.GLfloat(v1))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform2iv.xml
+func (gl *GL) ProgramUniform2iv(program glbase.Program, location glbase.Uniform, count int, value []int32) {
+ if len(value) != 2 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_3compat_glProgramUniform2iv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform2i.xml
+func (gl *GL) ProgramUniform2i(program glbase.Program, location glbase.Uniform, v0, v1 int32) {
+ C.gl4_3compat_glProgramUniform2i(gl.funcs, C.GLuint(program), C.GLint(location), C.GLint(v0), C.GLint(v1))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform1uiv.xml
+func (gl *GL) ProgramUniform1uiv(program glbase.Program, location glbase.Uniform, count int, value []uint32) {
+ C.gl4_3compat_glProgramUniform1uiv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform1ui.xml
+func (gl *GL) ProgramUniform1ui(program glbase.Program, location glbase.Uniform, v0 uint32) {
+ C.gl4_3compat_glProgramUniform1ui(gl.funcs, C.GLuint(program), C.GLint(location), C.GLuint(v0))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform1dv.xml
+func (gl *GL) ProgramUniform1dv(program glbase.Program, location glbase.Uniform, count int, value []float64) {
+ C.gl4_3compat_glProgramUniform1dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform1d.xml
+func (gl *GL) ProgramUniform1d(program glbase.Program, location glbase.Uniform, v0 float64) {
+ C.gl4_3compat_glProgramUniform1d(gl.funcs, C.GLuint(program), C.GLint(location), C.GLdouble(v0))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform1fv.xml
+func (gl *GL) ProgramUniform1fv(program glbase.Program, location glbase.Uniform, count int, value []float32) {
+ C.gl4_3compat_glProgramUniform1fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform1f.xml
+func (gl *GL) ProgramUniform1f(program glbase.Program, location glbase.Uniform, v0 float32) {
+ C.gl4_3compat_glProgramUniform1f(gl.funcs, C.GLuint(program), C.GLint(location), C.GLfloat(v0))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform1iv.xml
+func (gl *GL) ProgramUniform1iv(program glbase.Program, location glbase.Uniform, count int, value []int32) {
+ C.gl4_3compat_glProgramUniform1iv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform1i.xml
+func (gl *GL) ProgramUniform1i(program glbase.Program, location glbase.Uniform, v0 int32) {
+ C.gl4_3compat_glProgramUniform1i(gl.funcs, C.GLuint(program), C.GLint(location), C.GLint(v0))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetProgramPipelineiv.xml
+func (gl *GL) GetProgramPipelineiv(pipeline uint32, pname glbase.Enum, params []int32) {
+ C.gl4_3compat_glGetProgramPipelineiv(gl.funcs, C.GLuint(pipeline), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsProgramPipeline.xml
+func (gl *GL) IsProgramPipeline(pipeline uint32) bool {
+ glresult := C.gl4_3compat_glIsProgramPipeline(gl.funcs, C.GLuint(pipeline))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGenProgramPipelines.xml
+func (gl *GL) GenProgramPipelines(n int, pipelines []uint32) {
+ C.gl4_3compat_glGenProgramPipelines(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&pipelines[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDeleteProgramPipelines.xml
+func (gl *GL) DeleteProgramPipelines(n int, pipelines []uint32) {
+ C.gl4_3compat_glDeleteProgramPipelines(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&pipelines[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindProgramPipeline.xml
+func (gl *GL) BindProgramPipeline(pipeline uint32) {
+ C.gl4_3compat_glBindProgramPipeline(gl.funcs, C.GLuint(pipeline))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glActiveShaderProgram.xml
+func (gl *GL) ActiveShaderProgram(pipeline uint32, program glbase.Program) {
+ C.gl4_3compat_glActiveShaderProgram(gl.funcs, C.GLuint(pipeline), C.GLuint(program))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUseProgramStages.xml
+func (gl *GL) UseProgramStages(pipeline uint32, stages glbase.Bitfield, program glbase.Program) {
+ C.gl4_3compat_glUseProgramStages(gl.funcs, C.GLuint(pipeline), C.GLbitfield(stages), C.GLuint(program))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramParameteri.xml
+func (gl *GL) ProgramParameteri(program glbase.Program, pname glbase.Enum, value int32) {
+ C.gl4_3compat_glProgramParameteri(gl.funcs, C.GLuint(program), C.GLenum(pname), C.GLint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramBinary.xml
+func (gl *GL) ProgramBinary(program glbase.Program, binaryFormat glbase.Enum, binary interface{}, length int32) {
+ var binary_ptr unsafe.Pointer
+ var binary_v = reflect.ValueOf(binary)
+ if binary != nil && binary_v.Kind() != reflect.Slice {
+ panic("parameter binary must be a slice")
+ }
+ if binary != nil {
+ binary_ptr = unsafe.Pointer(binary_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3compat_glProgramBinary(gl.funcs, C.GLuint(program), C.GLenum(binaryFormat), binary_ptr, C.GLsizei(length))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetProgramBinary.xml
+func (gl *GL) GetProgramBinary(program glbase.Program, bufSize int32, length []int32, binaryFormat []glbase.Enum, binary interface{}) {
+ var binary_ptr unsafe.Pointer
+ var binary_v = reflect.ValueOf(binary)
+ if binary != nil && binary_v.Kind() != reflect.Slice {
+ panic("parameter binary must be a slice")
+ }
+ if binary != nil {
+ binary_ptr = unsafe.Pointer(binary_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3compat_glGetProgramBinary(gl.funcs, C.GLuint(program), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLenum)(unsafe.Pointer(&binaryFormat[0])), binary_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearDepthf.xml
+func (gl *GL) ClearDepthf(dd float32) {
+ C.gl4_3compat_glClearDepthf(gl.funcs, C.GLfloat(dd))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDepthRangef.xml
+func (gl *GL) DepthRangef(n, f float32) {
+ C.gl4_3compat_glDepthRangef(gl.funcs, C.GLfloat(n), C.GLfloat(f))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetShaderPrecisionFormat.xml
+func (gl *GL) GetShaderPrecisionFormat(shadertype, precisionType glbase.Enum, range_, precision []int32) {
+ C.gl4_3compat_glGetShaderPrecisionFormat(gl.funcs, C.GLenum(shadertype), C.GLenum(precisionType), (*C.GLint)(unsafe.Pointer(&range_[0])), (*C.GLint)(unsafe.Pointer(&precision[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glShaderBinary.xml
+func (gl *GL) ShaderBinary(count int, shaders []glbase.Shader, binaryFormat glbase.Enum, binary interface{}, length int32) {
+ var binary_ptr unsafe.Pointer
+ var binary_v = reflect.ValueOf(binary)
+ if binary != nil && binary_v.Kind() != reflect.Slice {
+ panic("parameter binary must be a slice")
+ }
+ if binary != nil {
+ binary_ptr = unsafe.Pointer(binary_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3compat_glShaderBinary(gl.funcs, C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&shaders[0])), C.GLenum(binaryFormat), binary_ptr, C.GLsizei(length))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glReleaseShaderCompiler.xml
+func (gl *GL) ReleaseShaderCompiler() {
+ C.gl4_3compat_glReleaseShaderCompiler(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexStorage3D.xml
+func (gl *GL) TexStorage3D(target glbase.Enum, levels int32, internalFormat glbase.Enum, width, height int, depth int32) {
+ C.gl4_3compat_glTexStorage3D(gl.funcs, C.GLenum(target), C.GLsizei(levels), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexStorage2D.xml
+func (gl *GL) TexStorage2D(target glbase.Enum, levels int32, internalFormat glbase.Enum, width, height int) {
+ C.gl4_3compat_glTexStorage2D(gl.funcs, C.GLenum(target), C.GLsizei(levels), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexStorage1D.xml
+func (gl *GL) TexStorage1D(target glbase.Enum, levels int32, internalFormat glbase.Enum, width int) {
+ C.gl4_3compat_glTexStorage1D(gl.funcs, C.GLenum(target), C.GLsizei(levels), C.GLenum(internalFormat), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMemoryBarrier.xml
+func (gl *GL) MemoryBarrier(barriers glbase.Bitfield) {
+ C.gl4_3compat_glMemoryBarrier(gl.funcs, C.GLbitfield(barriers))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindImageTexture.xml
+func (gl *GL) BindImageTexture(unit uint32, texture glbase.Texture, level int, layered bool, layer int32, access, format glbase.Enum) {
+ C.gl4_3compat_glBindImageTexture(gl.funcs, C.GLuint(unit), C.GLuint(texture), C.GLint(level), *(*C.GLboolean)(unsafe.Pointer(&layered)), C.GLint(layer), C.GLenum(access), C.GLenum(format))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveAtomicCounterBufferiv.xml
+func (gl *GL) GetActiveAtomicCounterBufferiv(program glbase.Program, bufferIndex uint32, pname glbase.Enum, params []int32) {
+ C.gl4_3compat_glGetActiveAtomicCounterBufferiv(gl.funcs, C.GLuint(program), C.GLuint(bufferIndex), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetInternalformativ.xml
+func (gl *GL) GetInternalformativ(target, internalFormat, pname glbase.Enum, bufSize int32, params []int32) {
+ C.gl4_3compat_glGetInternalformativ(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLenum(pname), C.GLsizei(bufSize), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawTransformFeedbackStreamInstanced.xml
+func (gl *GL) DrawTransformFeedbackStreamInstanced(mode glbase.Enum, id, stream uint32, instancecount int32) {
+ C.gl4_3compat_glDrawTransformFeedbackStreamInstanced(gl.funcs, C.GLenum(mode), C.GLuint(id), C.GLuint(stream), C.GLsizei(instancecount))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawTransformFeedbackInstanced.xml
+func (gl *GL) DrawTransformFeedbackInstanced(mode glbase.Enum, id uint32, instancecount int32) {
+ C.gl4_3compat_glDrawTransformFeedbackInstanced(gl.funcs, C.GLenum(mode), C.GLuint(id), C.GLsizei(instancecount))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawElementsInstancedBaseVertexBaseInstance.xml
+func (gl *GL) DrawElementsInstancedBaseVertexBaseInstance(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}, instancecount, basevertex int32, baseinstance uint32) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3compat_glDrawElementsInstancedBaseVertexBaseInstance(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr, C.GLsizei(instancecount), C.GLint(basevertex), C.GLuint(baseinstance))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawElementsInstancedBaseInstance.xml
+func (gl *GL) DrawElementsInstancedBaseInstance(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}, instancecount int32, baseinstance uint32) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3compat_glDrawElementsInstancedBaseInstance(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr, C.GLsizei(instancecount), C.GLuint(baseinstance))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawArraysInstancedBaseInstance.xml
+func (gl *GL) DrawArraysInstancedBaseInstance(mode glbase.Enum, first, count int, instancecount int32, baseinstance uint32) {
+ C.gl4_3compat_glDrawArraysInstancedBaseInstance(gl.funcs, C.GLenum(mode), C.GLint(first), C.GLsizei(count), C.GLsizei(instancecount), C.GLuint(baseinstance))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexStorage3DMultisample.xml
+func (gl *GL) TexStorage3DMultisample(target glbase.Enum, samples int32, internalFormat glbase.Enum, width, height int, depth int32, fixedsamplelocations bool) {
+ C.gl4_3compat_glTexStorage3DMultisample(gl.funcs, C.GLenum(target), C.GLsizei(samples), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), *(*C.GLboolean)(unsafe.Pointer(&fixedsamplelocations)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexStorage2DMultisample.xml
+func (gl *GL) TexStorage2DMultisample(target glbase.Enum, samples int32, internalFormat glbase.Enum, width, height int, fixedsamplelocations bool) {
+ C.gl4_3compat_glTexStorage2DMultisample(gl.funcs, C.GLenum(target), C.GLsizei(samples), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), *(*C.GLboolean)(unsafe.Pointer(&fixedsamplelocations)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexBufferRange.xml
+func (gl *GL) TexBufferRange(target, internalFormat glbase.Enum, buffer glbase.Buffer, offset, size int) {
+ C.gl4_3compat_glTexBufferRange(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLuint(buffer), C.GLintptr(offset), C.GLsizeiptr(size))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glShaderStorageBlockBinding.xml
+func (gl *GL) ShaderStorageBlockBinding(program glbase.Program, storageBlockIndex, storageBlockBinding uint32) {
+ C.gl4_3compat_glShaderStorageBlockBinding(gl.funcs, C.GLuint(program), C.GLuint(storageBlockIndex), C.GLuint(storageBlockBinding))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetProgramResourceLocationIndex.xml
+func (gl *GL) GetProgramResourceLocationIndex(program glbase.Program, programInterface glbase.Enum, name []byte) int32 {
+ glresult := C.gl4_3compat_glGetProgramResourceLocationIndex(gl.funcs, C.GLuint(program), C.GLenum(programInterface), (*C.GLchar)(unsafe.Pointer(&name[0])))
+ return int32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetProgramResourceLocation.xml
+func (gl *GL) GetProgramResourceLocation(program glbase.Program, programInterface glbase.Enum, name []byte) int32 {
+ glresult := C.gl4_3compat_glGetProgramResourceLocation(gl.funcs, C.GLuint(program), C.GLenum(programInterface), (*C.GLchar)(unsafe.Pointer(&name[0])))
+ return int32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetProgramResourceiv.xml
+func (gl *GL) GetProgramResourceiv(program glbase.Program, programInterface glbase.Enum, index uint32, propCount int32, props []glbase.Enum, bufSize int32, length, params []int32) {
+ C.gl4_3compat_glGetProgramResourceiv(gl.funcs, C.GLuint(program), C.GLenum(programInterface), C.GLuint(index), C.GLsizei(propCount), (*C.GLenum)(unsafe.Pointer(&props[0])), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetProgramResourceName.xml
+func (gl *GL) GetProgramResourceName(program glbase.Program, programInterface glbase.Enum, index uint32, bufSize int32, length []int32, name []byte) {
+ C.gl4_3compat_glGetProgramResourceName(gl.funcs, C.GLuint(program), C.GLenum(programInterface), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetProgramResourceIndex.xml
+func (gl *GL) GetProgramResourceIndex(program glbase.Program, programInterface glbase.Enum, name []byte) uint32 {
+ glresult := C.gl4_3compat_glGetProgramResourceIndex(gl.funcs, C.GLuint(program), C.GLenum(programInterface), (*C.GLchar)(unsafe.Pointer(&name[0])))
+ return uint32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetProgramInterfaceiv.xml
+func (gl *GL) GetProgramInterfaceiv(program glbase.Program, programInterface, pname glbase.Enum, params []int32) {
+ C.gl4_3compat_glGetProgramInterfaceiv(gl.funcs, C.GLuint(program), C.GLenum(programInterface), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiDrawElementsIndirect.xml
+func (gl *GL) MultiDrawElementsIndirect(mode, gltype glbase.Enum, indirect interface{}, drawcount int32, stride int) {
+ var indirect_ptr unsafe.Pointer
+ var indirect_v = reflect.ValueOf(indirect)
+ if indirect != nil && indirect_v.Kind() != reflect.Slice {
+ panic("parameter indirect must be a slice")
+ }
+ if indirect != nil {
+ indirect_ptr = unsafe.Pointer(indirect_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3compat_glMultiDrawElementsIndirect(gl.funcs, C.GLenum(mode), C.GLenum(gltype), indirect_ptr, C.GLsizei(drawcount), C.GLsizei(stride))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiDrawArraysIndirect.xml
+func (gl *GL) MultiDrawArraysIndirect(mode glbase.Enum, indirect interface{}, drawcount int32, stride int) {
+ var indirect_ptr unsafe.Pointer
+ var indirect_v = reflect.ValueOf(indirect)
+ if indirect != nil && indirect_v.Kind() != reflect.Slice {
+ panic("parameter indirect must be a slice")
+ }
+ if indirect != nil {
+ indirect_ptr = unsafe.Pointer(indirect_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3compat_glMultiDrawArraysIndirect(gl.funcs, C.GLenum(mode), indirect_ptr, C.GLsizei(drawcount), C.GLsizei(stride))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glInvalidateSubFramebuffer.xml
+func (gl *GL) InvalidateSubFramebuffer(target glbase.Enum, numAttachments int32, attachments []glbase.Enum, x, y, width, height int) {
+ C.gl4_3compat_glInvalidateSubFramebuffer(gl.funcs, C.GLenum(target), C.GLsizei(numAttachments), (*C.GLenum)(unsafe.Pointer(&attachments[0])), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glInvalidateFramebuffer.xml
+func (gl *GL) InvalidateFramebuffer(target glbase.Enum, numAttachments int32, attachments []glbase.Enum) {
+ C.gl4_3compat_glInvalidateFramebuffer(gl.funcs, C.GLenum(target), C.GLsizei(numAttachments), (*C.GLenum)(unsafe.Pointer(&attachments[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glInvalidateBufferData.xml
+func (gl *GL) InvalidateBufferData(buffer glbase.Buffer) {
+ C.gl4_3compat_glInvalidateBufferData(gl.funcs, C.GLuint(buffer))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glInvalidateBufferSubData.xml
+func (gl *GL) InvalidateBufferSubData(buffer glbase.Buffer, offset, length int) {
+ C.gl4_3compat_glInvalidateBufferSubData(gl.funcs, C.GLuint(buffer), C.GLintptr(offset), C.GLsizeiptr(length))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glInvalidateTexImage.xml
+func (gl *GL) InvalidateTexImage(texture glbase.Texture, level int) {
+ C.gl4_3compat_glInvalidateTexImage(gl.funcs, C.GLuint(texture), C.GLint(level))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glInvalidateTexSubImage.xml
+func (gl *GL) InvalidateTexSubImage(texture glbase.Texture, level, xoffset, yoffset int, zoffset int32, width, height int, depth int32) {
+ C.gl4_3compat_glInvalidateTexSubImage(gl.funcs, C.GLuint(texture), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(zoffset), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetInternalformati64v.xml
+func (gl *GL) GetInternalformati64v(target, internalFormat, pname glbase.Enum, bufSize int32, params []int64) {
+ C.gl4_3compat_glGetInternalformati64v(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLenum(pname), C.GLsizei(bufSize), (*C.GLint64)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetFramebufferParameteriv.xml
+func (gl *GL) GetFramebufferParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl4_3compat_glGetFramebufferParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFramebufferParameteri.xml
+func (gl *GL) FramebufferParameteri(target, pname glbase.Enum, param int32) {
+ C.gl4_3compat_glFramebufferParameteri(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexBindingDivisor.xml
+func (gl *GL) VertexBindingDivisor(bindingindex, divisor uint32) {
+ C.gl4_3compat_glVertexBindingDivisor(gl.funcs, C.GLuint(bindingindex), C.GLuint(divisor))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribBinding.xml
+func (gl *GL) VertexAttribBinding(attribindex, bindingindex uint32) {
+ C.gl4_3compat_glVertexAttribBinding(gl.funcs, C.GLuint(attribindex), C.GLuint(bindingindex))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribLFormat.xml
+func (gl *GL) VertexAttribLFormat(attribindex uint32, size int, gltype glbase.Enum, relativeoffset uint32) {
+ C.gl4_3compat_glVertexAttribLFormat(gl.funcs, C.GLuint(attribindex), C.GLint(size), C.GLenum(gltype), C.GLuint(relativeoffset))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribIFormat.xml
+func (gl *GL) VertexAttribIFormat(attribindex uint32, size int, gltype glbase.Enum, relativeoffset uint32) {
+ C.gl4_3compat_glVertexAttribIFormat(gl.funcs, C.GLuint(attribindex), C.GLint(size), C.GLenum(gltype), C.GLuint(relativeoffset))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribFormat.xml
+func (gl *GL) VertexAttribFormat(attribindex uint32, size int, gltype glbase.Enum, normalized bool, relativeoffset uint32) {
+ C.gl4_3compat_glVertexAttribFormat(gl.funcs, C.GLuint(attribindex), C.GLint(size), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), C.GLuint(relativeoffset))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindVertexBuffer.xml
+func (gl *GL) BindVertexBuffer(bindingindex uint32, buffer glbase.Buffer, offset, stride int) {
+ C.gl4_3compat_glBindVertexBuffer(gl.funcs, C.GLuint(bindingindex), C.GLuint(buffer), C.GLintptr(offset), C.GLsizei(stride))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTextureView.xml
+func (gl *GL) TextureView(texture glbase.Texture, target glbase.Enum, origtexture uint32, internalFormat glbase.Enum, minlevel, numlevels, minlayer, numlayers uint32) {
+ C.gl4_3compat_glTextureView(gl.funcs, C.GLuint(texture), C.GLenum(target), C.GLuint(origtexture), C.GLenum(internalFormat), C.GLuint(minlevel), C.GLuint(numlevels), C.GLuint(minlayer), C.GLuint(numlayers))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyImageSubData.xml
+func (gl *GL) CopyImageSubData(srcName uint32, srcTarget glbase.Enum, srcLevel, srcX, srcY, srcZ int32, dstName uint32, dstTarget glbase.Enum, dstLevel, dstX, dstY, dstZ, srcWidth, srcHeight, srcDepth int32) {
+ C.gl4_3compat_glCopyImageSubData(gl.funcs, C.GLuint(srcName), C.GLenum(srcTarget), C.GLint(srcLevel), C.GLint(srcX), C.GLint(srcY), C.GLint(srcZ), C.GLuint(dstName), C.GLenum(dstTarget), C.GLint(dstLevel), C.GLint(dstX), C.GLint(dstY), C.GLint(dstZ), C.GLsizei(srcWidth), C.GLsizei(srcHeight), C.GLsizei(srcDepth))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDispatchComputeIndirect.xml
+func (gl *GL) DispatchComputeIndirect(indirect int) {
+ C.gl4_3compat_glDispatchComputeIndirect(gl.funcs, C.GLintptr(indirect))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDispatchCompute.xml
+func (gl *GL) DispatchCompute(num_groups_x, num_groups_y, num_groups_z uint32) {
+ C.gl4_3compat_glDispatchCompute(gl.funcs, C.GLuint(num_groups_x), C.GLuint(num_groups_y), C.GLuint(num_groups_z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearBufferSubData.xml
+func (gl *GL) ClearBufferSubData(target, internalFormat glbase.Enum, offset, size int, format, gltype glbase.Enum, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3compat_glClearBufferSubData(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLintptr(offset), C.GLsizeiptr(size), C.GLenum(format), C.GLenum(gltype), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearBufferData.xml
+func (gl *GL) ClearBufferData(target, internalFormat, format, gltype glbase.Enum, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3compat_glClearBufferData(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLenum(format), C.GLenum(gltype), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTranslatef.xml
+func (gl *GL) Translatef(x, y, z float32) {
+ C.gl4_3compat_glTranslatef(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTranslated.xml
+func (gl *GL) Translated(x, y, z float64) {
+ C.gl4_3compat_glTranslated(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glScalef.xml
+func (gl *GL) Scalef(x, y, z float32) {
+ C.gl4_3compat_glScalef(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glScaled.xml
+func (gl *GL) Scaled(x, y, z float64) {
+ C.gl4_3compat_glScaled(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRotatef.xml
+func (gl *GL) Rotatef(angle, x, y, z float32) {
+ C.gl4_3compat_glRotatef(gl.funcs, C.GLfloat(angle), C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRotated.xml
+func (gl *GL) Rotated(angle, x, y, z float64) {
+ C.gl4_3compat_glRotated(gl.funcs, C.GLdouble(angle), C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPushMatrix.xml
+func (gl *GL) PushMatrix() {
+ C.gl4_3compat_glPushMatrix(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPopMatrix.xml
+func (gl *GL) PopMatrix() {
+ C.gl4_3compat_glPopMatrix(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glOrtho.xml
+func (gl *GL) Ortho(left, right, bottom, top, zNear, zFar float64) {
+ C.gl4_3compat_glOrtho(gl.funcs, C.GLdouble(left), C.GLdouble(right), C.GLdouble(bottom), C.GLdouble(top), C.GLdouble(zNear), C.GLdouble(zFar))
+}
+
+// MultMatrixd multiplies the current matrix with the provided matrix.
+//
+// The m parameter must hold 16 consecutive elements of a 4x4 column-major matrix.
+//
+// The current matrix is determined by the current matrix mode (see
+// MatrixMode). It is either the projection matrix, modelview matrix, or the
+// texture matrix.
+//
+// For example, if the current matrix is C and the coordinates to be transformed
+// are v = (v[0], v[1], v[2], v[3]), then the current transformation is C × v, or
+//
+// c[0] c[4] c[8] c[12] v[0]
+// c[1] c[5] c[9] c[13] v[1]
+// c[2] c[6] c[10] c[14] X v[2]
+// c[3] c[7] c[11] c[15] v[3]
+//
+// Calling MultMatrix with an argument of m = m[0], m[1], ..., m[15]
+// replaces the current transformation with (C X M) x v, or
+//
+// c[0] c[4] c[8] c[12] m[0] m[4] m[8] m[12] v[0]
+// c[1] c[5] c[9] c[13] m[1] m[5] m[9] m[13] v[1]
+// c[2] c[6] c[10] c[14] X m[2] m[6] m[10] m[14] X v[2]
+// c[3] c[7] c[11] c[15] m[3] m[7] m[11] m[15] v[3]
+//
+// Where 'X' denotes matrix multiplication, and v is represented as a 4x1 matrix.
+//
+// While the elements of the matrix may be specified with single or double
+// precision, the GL may store or operate on these values in less-than-single
+// precision.
+//
+// In many computer languages, 4×4 arrays are represented in row-major
+// order. The transformations just described represent these matrices in
+// column-major order. The order of the multiplication is important. For
+// example, if the current transformation is a rotation, and MultMatrix is
+// called with a translation matrix, the translation is done directly on the
+// coordinates to be transformed, while the rotation is done on the results
+// of that translation.
+//
+// GL.INVALID_OPERATION is generated if MultMatrix is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) MultMatrixd(m []float64) {
+ if len(m) != 16 {
+ panic("parameter m must have length 16 for the 4x4 matrix")
+ }
+ C.gl4_3compat_glMultMatrixd(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&m[0])))
+}
+
+// MultMatrixf multiplies the current matrix with the provided matrix.
+//
+// The m parameter must hold 16 consecutive elements of a 4x4 column-major matrix.
+//
+// The current matrix is determined by the current matrix mode (see
+// MatrixMode). It is either the projection matrix, modelview matrix, or the
+// texture matrix.
+//
+// For example, if the current matrix is C and the coordinates to be transformed
+// are v = (v[0], v[1], v[2], v[3]), then the current transformation is C × v, or
+//
+// c[0] c[4] c[8] c[12] v[0]
+// c[1] c[5] c[9] c[13] v[1]
+// c[2] c[6] c[10] c[14] X v[2]
+// c[3] c[7] c[11] c[15] v[3]
+//
+// Calling MultMatrix with an argument of m = m[0], m[1], ..., m[15]
+// replaces the current transformation with (C X M) x v, or
+//
+// c[0] c[4] c[8] c[12] m[0] m[4] m[8] m[12] v[0]
+// c[1] c[5] c[9] c[13] m[1] m[5] m[9] m[13] v[1]
+// c[2] c[6] c[10] c[14] X m[2] m[6] m[10] m[14] X v[2]
+// c[3] c[7] c[11] c[15] m[3] m[7] m[11] m[15] v[3]
+//
+// Where 'X' denotes matrix multiplication, and v is represented as a 4x1 matrix.
+//
+// While the elements of the matrix may be specified with single or double
+// precision, the GL may store or operate on these values in less-than-single
+// precision.
+//
+// In many computer languages, 4×4 arrays are represented in row-major
+// order. The transformations just described represent these matrices in
+// column-major order. The order of the multiplication is important. For
+// example, if the current transformation is a rotation, and MultMatrix is
+// called with a translation matrix, the translation is done directly on the
+// coordinates to be transformed, while the rotation is done on the results
+// of that translation.
+//
+// GL.INVALID_OPERATION is generated if MultMatrix is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) MultMatrixf(m []float32) {
+ if len(m) != 16 {
+ panic("parameter m must have length 16 for the 4x4 matrix")
+ }
+ C.gl4_3compat_glMultMatrixf(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMatrixMode.xml
+func (gl *GL) MatrixMode(mode glbase.Enum) {
+ C.gl4_3compat_glMatrixMode(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLoadMatrixd.xml
+func (gl *GL) LoadMatrixd(m []float64) {
+ C.gl4_3compat_glLoadMatrixd(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLoadMatrixf.xml
+func (gl *GL) LoadMatrixf(m []float32) {
+ C.gl4_3compat_glLoadMatrixf(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLoadIdentity.xml
+func (gl *GL) LoadIdentity() {
+ C.gl4_3compat_glLoadIdentity(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFrustum.xml
+func (gl *GL) Frustum(left, right, bottom, top, zNear, zFar float64) {
+ C.gl4_3compat_glFrustum(gl.funcs, C.GLdouble(left), C.GLdouble(right), C.GLdouble(bottom), C.GLdouble(top), C.GLdouble(zNear), C.GLdouble(zFar))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsList.xml
+func (gl *GL) IsList(list uint32) bool {
+ glresult := C.gl4_3compat_glIsList(gl.funcs, C.GLuint(list))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexGeniv.xml
+func (gl *GL) GetTexGeniv(coord, pname glbase.Enum, params []int32) {
+ C.gl4_3compat_glGetTexGeniv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexGenfv.xml
+func (gl *GL) GetTexGenfv(coord, pname glbase.Enum, params []float32) {
+ C.gl4_3compat_glGetTexGenfv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexGendv.xml
+func (gl *GL) GetTexGendv(coord, pname glbase.Enum, params []float64) {
+ C.gl4_3compat_glGetTexGendv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexEnviv.xml
+func (gl *GL) GetTexEnviv(target, pname glbase.Enum, params []int32) {
+ C.gl4_3compat_glGetTexEnviv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexEnvfv.xml
+func (gl *GL) GetTexEnvfv(target, pname glbase.Enum, params []float32) {
+ C.gl4_3compat_glGetTexEnvfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetPolygonStipple.xml
+func (gl *GL) GetPolygonStipple(mask []uint8) {
+ C.gl4_3compat_glGetPolygonStipple(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&mask[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetPixelMapusv.xml
+func (gl *GL) GetPixelMapusv(glmap glbase.Enum, values []uint16) {
+ C.gl4_3compat_glGetPixelMapusv(gl.funcs, C.GLenum(glmap), (*C.GLushort)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetPixelMapuiv.xml
+func (gl *GL) GetPixelMapuiv(glmap glbase.Enum, values []uint32) {
+ C.gl4_3compat_glGetPixelMapuiv(gl.funcs, C.GLenum(glmap), (*C.GLuint)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetPixelMapfv.xml
+func (gl *GL) GetPixelMapfv(glmap glbase.Enum, values []float32) {
+ C.gl4_3compat_glGetPixelMapfv(gl.funcs, C.GLenum(glmap), (*C.GLfloat)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetMaterialiv.xml
+func (gl *GL) GetMaterialiv(face, pname glbase.Enum, params []int32) {
+ C.gl4_3compat_glGetMaterialiv(gl.funcs, C.GLenum(face), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetMaterialfv.xml
+func (gl *GL) GetMaterialfv(face, pname glbase.Enum, params []float32) {
+ C.gl4_3compat_glGetMaterialfv(gl.funcs, C.GLenum(face), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetMapiv.xml
+func (gl *GL) GetMapiv(target, query glbase.Enum, v []int32) {
+ C.gl4_3compat_glGetMapiv(gl.funcs, C.GLenum(target), C.GLenum(query), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetMapfv.xml
+func (gl *GL) GetMapfv(target, query glbase.Enum, v []float32) {
+ C.gl4_3compat_glGetMapfv(gl.funcs, C.GLenum(target), C.GLenum(query), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetMapdv.xml
+func (gl *GL) GetMapdv(target, query glbase.Enum, v []float64) {
+ C.gl4_3compat_glGetMapdv(gl.funcs, C.GLenum(target), C.GLenum(query), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetLightiv.xml
+func (gl *GL) GetLightiv(light, pname glbase.Enum, params []int32) {
+ C.gl4_3compat_glGetLightiv(gl.funcs, C.GLenum(light), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetLightfv.xml
+func (gl *GL) GetLightfv(light, pname glbase.Enum, params []float32) {
+ C.gl4_3compat_glGetLightfv(gl.funcs, C.GLenum(light), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetClipPlane.xml
+func (gl *GL) GetClipPlane(plane glbase.Enum, equation []float64) {
+ C.gl4_3compat_glGetClipPlane(gl.funcs, C.GLenum(plane), (*C.GLdouble)(unsafe.Pointer(&equation[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawPixels.xml
+func (gl *GL) DrawPixels(width, height int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3compat_glDrawPixels(gl.funcs, C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyPixels.xml
+func (gl *GL) CopyPixels(x, y, width, height int, gltype glbase.Enum) {
+ C.gl4_3compat_glCopyPixels(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height), C.GLenum(gltype))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPixelMapusv.xml
+func (gl *GL) PixelMapusv(glmap glbase.Enum, mapsize int32, values []uint16) {
+ C.gl4_3compat_glPixelMapusv(gl.funcs, C.GLenum(glmap), C.GLint(mapsize), (*C.GLushort)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPixelMapuiv.xml
+func (gl *GL) PixelMapuiv(glmap glbase.Enum, mapsize int32, values []uint32) {
+ C.gl4_3compat_glPixelMapuiv(gl.funcs, C.GLenum(glmap), C.GLint(mapsize), (*C.GLuint)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPixelMapfv.xml
+func (gl *GL) PixelMapfv(glmap glbase.Enum, mapsize int32, values []float32) {
+ C.gl4_3compat_glPixelMapfv(gl.funcs, C.GLenum(glmap), C.GLint(mapsize), (*C.GLfloat)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPixelTransferi.xml
+func (gl *GL) PixelTransferi(pname glbase.Enum, param int32) {
+ C.gl4_3compat_glPixelTransferi(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPixelTransferf.xml
+func (gl *GL) PixelTransferf(pname glbase.Enum, param float32) {
+ C.gl4_3compat_glPixelTransferf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPixelZoom.xml
+func (gl *GL) PixelZoom(xfactor, yfactor float32) {
+ C.gl4_3compat_glPixelZoom(gl.funcs, C.GLfloat(xfactor), C.GLfloat(yfactor))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glAlphaFunc.xml
+func (gl *GL) AlphaFunc(glfunc glbase.Enum, ref float32) {
+ C.gl4_3compat_glAlphaFunc(gl.funcs, C.GLenum(glfunc), C.GLfloat(ref))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEvalPoint2.xml
+func (gl *GL) EvalPoint2(i, j int32) {
+ C.gl4_3compat_glEvalPoint2(gl.funcs, C.GLint(i), C.GLint(j))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEvalMesh2.xml
+func (gl *GL) EvalMesh2(mode glbase.Enum, i1, i2, j1, j2 int32) {
+ C.gl4_3compat_glEvalMesh2(gl.funcs, C.GLenum(mode), C.GLint(i1), C.GLint(i2), C.GLint(j1), C.GLint(j2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEvalPoint1.xml
+func (gl *GL) EvalPoint1(i int32) {
+ C.gl4_3compat_glEvalPoint1(gl.funcs, C.GLint(i))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEvalMesh1.xml
+func (gl *GL) EvalMesh1(mode glbase.Enum, i1, i2 int32) {
+ C.gl4_3compat_glEvalMesh1(gl.funcs, C.GLenum(mode), C.GLint(i1), C.GLint(i2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEvalCoord2fv.xml
+func (gl *GL) EvalCoord2fv(u []float32) {
+ if len(u) != 2 {
+ panic("parameter u has incorrect length")
+ }
+ C.gl4_3compat_glEvalCoord2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&u[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEvalCoord2f.xml
+func (gl *GL) EvalCoord2f(u, v float32) {
+ C.gl4_3compat_glEvalCoord2f(gl.funcs, C.GLfloat(u), C.GLfloat(v))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEvalCoord2dv.xml
+func (gl *GL) EvalCoord2dv(u []float64) {
+ if len(u) != 2 {
+ panic("parameter u has incorrect length")
+ }
+ C.gl4_3compat_glEvalCoord2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&u[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEvalCoord2d.xml
+func (gl *GL) EvalCoord2d(u, v float64) {
+ C.gl4_3compat_glEvalCoord2d(gl.funcs, C.GLdouble(u), C.GLdouble(v))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEvalCoord1fv.xml
+func (gl *GL) EvalCoord1fv(u []float32) {
+ C.gl4_3compat_glEvalCoord1fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&u[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEvalCoord1f.xml
+func (gl *GL) EvalCoord1f(u float32) {
+ C.gl4_3compat_glEvalCoord1f(gl.funcs, C.GLfloat(u))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEvalCoord1dv.xml
+func (gl *GL) EvalCoord1dv(u []float64) {
+ C.gl4_3compat_glEvalCoord1dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&u[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEvalCoord1d.xml
+func (gl *GL) EvalCoord1d(u float64) {
+ C.gl4_3compat_glEvalCoord1d(gl.funcs, C.GLdouble(u))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMapGrid2f.xml
+func (gl *GL) MapGrid2f(un int32, u1, u2 float32, vn int32, v1, v2 float32) {
+ C.gl4_3compat_glMapGrid2f(gl.funcs, C.GLint(un), C.GLfloat(u1), C.GLfloat(u2), C.GLint(vn), C.GLfloat(v1), C.GLfloat(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMapGrid2d.xml
+func (gl *GL) MapGrid2d(un int32, u1, u2 float64, vn int32, v1, v2 float64) {
+ C.gl4_3compat_glMapGrid2d(gl.funcs, C.GLint(un), C.GLdouble(u1), C.GLdouble(u2), C.GLint(vn), C.GLdouble(v1), C.GLdouble(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMapGrid1f.xml
+func (gl *GL) MapGrid1f(un int32, u1, u2 float32) {
+ C.gl4_3compat_glMapGrid1f(gl.funcs, C.GLint(un), C.GLfloat(u1), C.GLfloat(u2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMapGrid1d.xml
+func (gl *GL) MapGrid1d(un int32, u1, u2 float64) {
+ C.gl4_3compat_glMapGrid1d(gl.funcs, C.GLint(un), C.GLdouble(u1), C.GLdouble(u2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMap2f.xml
+func (gl *GL) Map2f(target glbase.Enum, u1, u2 float32, ustride, uorder int32, v1, v2 float32, vstride, vorder int32, points []float32) {
+ C.gl4_3compat_glMap2f(gl.funcs, C.GLenum(target), C.GLfloat(u1), C.GLfloat(u2), C.GLint(ustride), C.GLint(uorder), C.GLfloat(v1), C.GLfloat(v2), C.GLint(vstride), C.GLint(vorder), (*C.GLfloat)(unsafe.Pointer(&points[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMap2d.xml
+func (gl *GL) Map2d(target glbase.Enum, u1, u2 float64, ustride, uorder int32, v1, v2 float64, vstride, vorder int32, points []float64) {
+ C.gl4_3compat_glMap2d(gl.funcs, C.GLenum(target), C.GLdouble(u1), C.GLdouble(u2), C.GLint(ustride), C.GLint(uorder), C.GLdouble(v1), C.GLdouble(v2), C.GLint(vstride), C.GLint(vorder), (*C.GLdouble)(unsafe.Pointer(&points[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMap1f.xml
+func (gl *GL) Map1f(target glbase.Enum, u1, u2 float32, stride, order int, points []float32) {
+ C.gl4_3compat_glMap1f(gl.funcs, C.GLenum(target), C.GLfloat(u1), C.GLfloat(u2), C.GLint(stride), C.GLint(order), (*C.GLfloat)(unsafe.Pointer(&points[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMap1d.xml
+func (gl *GL) Map1d(target glbase.Enum, u1, u2 float64, stride, order int, points []float64) {
+ C.gl4_3compat_glMap1d(gl.funcs, C.GLenum(target), C.GLdouble(u1), C.GLdouble(u2), C.GLint(stride), C.GLint(order), (*C.GLdouble)(unsafe.Pointer(&points[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPushAttrib.xml
+func (gl *GL) PushAttrib(mask glbase.Bitfield) {
+ C.gl4_3compat_glPushAttrib(gl.funcs, C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPopAttrib.xml
+func (gl *GL) PopAttrib() {
+ C.gl4_3compat_glPopAttrib(gl.funcs)
+}
+
+// Accum executes an operation on the accumulation buffer.
+//
+// Parameter op defines the accumulation buffer operation (GL.ACCUM, GL.LOAD,
+// GL.ADD, GL.MULT, or GL.RETURN) and specifies how the value parameter is
+// used.
+//
+// The accumulation buffer is an extended-range color buffer. Images are not
+// rendered into it. Rather, images rendered into one of the color buffers
+// are added to the contents of the accumulation buffer after rendering.
+// Effects such as antialiasing (of points, lines, and polygons), motion
+// blur, and depth of field can be created by accumulating images generated
+// with different transformation matrices.
+//
+// Each pixel in the accumulation buffer consists of red, green, blue, and
+// alpha values. The number of bits per component in the accumulation buffer
+// depends on the implementation. You can examine this number by calling
+// GetIntegerv four times, with arguments GL.ACCUM_RED_BITS,
+// GL.ACCUM_GREEN_BITS, GL.ACCUM_BLUE_BITS, and GL.ACCUM_ALPHA_BITS.
+// Regardless of the number of bits per component, the range of values stored
+// by each component is (-1, 1). The accumulation buffer pixels are mapped
+// one-to-one with frame buffer pixels.
+//
+// All accumulation buffer operations are limited to the area of the current
+// scissor box and applied identically to the red, green, blue, and alpha
+// components of each pixel. If a Accum operation results in a value outside
+// the range (-1, 1), the contents of an accumulation buffer pixel component
+// are undefined.
+//
+// The operations are as follows:
+//
+// GL.ACCUM
+// Obtains R, G, B, and A values from the buffer currently selected for
+// reading (see ReadBuffer). Each component value is divided by 2 n -
+// 1 , where n is the number of bits allocated to each color component
+// in the currently selected buffer. The result is a floating-point
+// value in the range 0 1 , which is multiplied by value and added to
+// the corresponding pixel component in the accumulation buffer,
+// thereby updating the accumulation buffer.
+//
+// GL.LOAD
+// Similar to GL.ACCUM, except that the current value in the
+// accumulation buffer is not used in the calculation of the new value.
+// That is, the R, G, B, and A values from the currently selected
+// buffer are divided by 2 n - 1 , multiplied by value, and then stored
+// in the corresponding accumulation buffer cell, overwriting the
+// current value.
+//
+// GL.ADD
+// Adds value to each R, G, B, and A in the accumulation buffer.
+//
+// GL.MULT
+// Multiplies each R, G, B, and A in the accumulation buffer by value
+// and returns the scaled component to its corresponding accumulation
+// buffer location.
+//
+// GL.RETURN
+// Transfers accumulation buffer values to the color buffer or buffers
+// currently selected for writing. Each R, G, B, and A component is
+// multiplied by value, then multiplied by 2 n - 1 , clamped to the
+// range 0 2 n - 1 , and stored in the corresponding display buffer
+// cell. The only fragment operations that are applied to this transfer
+// are pixel ownership, scissor, dithering, and color writemasks.
+//
+// To clear the accumulation buffer, call ClearAccum with R, G, B, and A
+// values to set it to, then call Clear with the accumulation buffer
+// enabled.
+//
+// Error GL.INVALID_ENUM is generated if op is not an accepted value.
+// GL.INVALID_OPERATION is generated if there is no accumulation buffer.
+// GL.INVALID_OPERATION is generated if Accum is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) Accum(op glbase.Enum, value float32) {
+ C.gl4_3compat_glAccum(gl.funcs, C.GLenum(op), C.GLfloat(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIndexMask.xml
+func (gl *GL) IndexMask(mask uint32) {
+ C.gl4_3compat_glIndexMask(gl.funcs, C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearIndex.xml
+func (gl *GL) ClearIndex(c float32) {
+ C.gl4_3compat_glClearIndex(gl.funcs, C.GLfloat(c))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearAccum.xml
+func (gl *GL) ClearAccum(red, green, blue, alpha float32) {
+ C.gl4_3compat_glClearAccum(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPushName.xml
+func (gl *GL) PushName(name uint32) {
+ C.gl4_3compat_glPushName(gl.funcs, C.GLuint(name))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPopName.xml
+func (gl *GL) PopName() {
+ C.gl4_3compat_glPopName(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPassThrough.xml
+func (gl *GL) PassThrough(token float32) {
+ C.gl4_3compat_glPassThrough(gl.funcs, C.GLfloat(token))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLoadName.xml
+func (gl *GL) LoadName(name uint32) {
+ C.gl4_3compat_glLoadName(gl.funcs, C.GLuint(name))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glInitNames.xml
+func (gl *GL) InitNames() {
+ C.gl4_3compat_glInitNames(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRenderMode.xml
+func (gl *GL) RenderMode(mode glbase.Enum) int32 {
+ glresult := C.gl4_3compat_glRenderMode(gl.funcs, C.GLenum(mode))
+ return int32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSelectBuffer.xml
+func (gl *GL) SelectBuffer(size int, buffer []glbase.Buffer) {
+ C.gl4_3compat_glSelectBuffer(gl.funcs, C.GLsizei(size), (*C.GLuint)(unsafe.Pointer(&buffer[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFeedbackBuffer.xml
+func (gl *GL) FeedbackBuffer(size int, gltype glbase.Enum, buffer []float32) {
+ C.gl4_3compat_glFeedbackBuffer(gl.funcs, C.GLsizei(size), C.GLenum(gltype), (*C.GLfloat)(unsafe.Pointer(&buffer[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexGeniv.xml
+func (gl *GL) TexGeniv(coord, pname glbase.Enum, params []int32) {
+ C.gl4_3compat_glTexGeniv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexGeni.xml
+func (gl *GL) TexGeni(coord, pname glbase.Enum, param int32) {
+ C.gl4_3compat_glTexGeni(gl.funcs, C.GLenum(coord), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexGenfv.xml
+func (gl *GL) TexGenfv(coord, pname glbase.Enum, params []float32) {
+ C.gl4_3compat_glTexGenfv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexGenf.xml
+func (gl *GL) TexGenf(coord, pname glbase.Enum, param float32) {
+ C.gl4_3compat_glTexGenf(gl.funcs, C.GLenum(coord), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexGendv.xml
+func (gl *GL) TexGendv(coord, pname glbase.Enum, params []float64) {
+ C.gl4_3compat_glTexGendv(gl.funcs, C.GLenum(coord), C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexGend.xml
+func (gl *GL) TexGend(coord, pname glbase.Enum, param float64) {
+ C.gl4_3compat_glTexGend(gl.funcs, C.GLenum(coord), C.GLenum(pname), C.GLdouble(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexEnviv.xml
+func (gl *GL) TexEnviv(target, pname glbase.Enum, params []int32) {
+ C.gl4_3compat_glTexEnviv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexEnvi.xml
+func (gl *GL) TexEnvi(target, pname glbase.Enum, param int32) {
+ C.gl4_3compat_glTexEnvi(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexEnvfv.xml
+func (gl *GL) TexEnvfv(target, pname glbase.Enum, params []float32) {
+ C.gl4_3compat_glTexEnvfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexEnvf.xml
+func (gl *GL) TexEnvf(target, pname glbase.Enum, param float32) {
+ C.gl4_3compat_glTexEnvf(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glShadeModel.xml
+func (gl *GL) ShadeModel(mode glbase.Enum) {
+ C.gl4_3compat_glShadeModel(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPolygonStipple.xml
+func (gl *GL) PolygonStipple(mask []uint8) {
+ C.gl4_3compat_glPolygonStipple(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&mask[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMaterialiv.xml
+func (gl *GL) Materialiv(face, pname glbase.Enum, params []int32) {
+ C.gl4_3compat_glMaterialiv(gl.funcs, C.GLenum(face), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMateriali.xml
+func (gl *GL) Materiali(face, pname glbase.Enum, param int32) {
+ C.gl4_3compat_glMateriali(gl.funcs, C.GLenum(face), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMaterialfv.xml
+func (gl *GL) Materialfv(face, pname glbase.Enum, params []float32) {
+ C.gl4_3compat_glMaterialfv(gl.funcs, C.GLenum(face), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMaterialf.xml
+func (gl *GL) Materialf(face, pname glbase.Enum, param float32) {
+ C.gl4_3compat_glMaterialf(gl.funcs, C.GLenum(face), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLineStipple.xml
+func (gl *GL) LineStipple(factor int32, pattern uint16) {
+ C.gl4_3compat_glLineStipple(gl.funcs, C.GLint(factor), C.GLushort(pattern))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLightModeliv.xml
+func (gl *GL) LightModeliv(pname glbase.Enum, params []int32) {
+ C.gl4_3compat_glLightModeliv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLightModeli.xml
+func (gl *GL) LightModeli(pname glbase.Enum, param int32) {
+ C.gl4_3compat_glLightModeli(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLightModelfv.xml
+func (gl *GL) LightModelfv(pname glbase.Enum, params []float32) {
+ C.gl4_3compat_glLightModelfv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLightModelf.xml
+func (gl *GL) LightModelf(pname glbase.Enum, param float32) {
+ C.gl4_3compat_glLightModelf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLightiv.xml
+func (gl *GL) Lightiv(light, pname glbase.Enum, params []int32) {
+ C.gl4_3compat_glLightiv(gl.funcs, C.GLenum(light), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLighti.xml
+func (gl *GL) Lighti(light, pname glbase.Enum, param int32) {
+ C.gl4_3compat_glLighti(gl.funcs, C.GLenum(light), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLightfv.xml
+func (gl *GL) Lightfv(light, pname glbase.Enum, params []float32) {
+ C.gl4_3compat_glLightfv(gl.funcs, C.GLenum(light), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLightf.xml
+func (gl *GL) Lightf(light, pname glbase.Enum, param float32) {
+ C.gl4_3compat_glLightf(gl.funcs, C.GLenum(light), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFogiv.xml
+func (gl *GL) Fogiv(pname glbase.Enum, params []int32) {
+ C.gl4_3compat_glFogiv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFogi.xml
+func (gl *GL) Fogi(pname glbase.Enum, param int32) {
+ C.gl4_3compat_glFogi(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFogfv.xml
+func (gl *GL) Fogfv(pname glbase.Enum, params []float32) {
+ C.gl4_3compat_glFogfv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFogf.xml
+func (gl *GL) Fogf(pname glbase.Enum, param float32) {
+ C.gl4_3compat_glFogf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorMaterial.xml
+func (gl *GL) ColorMaterial(face, mode glbase.Enum) {
+ C.gl4_3compat_glColorMaterial(gl.funcs, C.GLenum(face), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClipPlane.xml
+func (gl *GL) ClipPlane(plane glbase.Enum, equation []float64) {
+ C.gl4_3compat_glClipPlane(gl.funcs, C.GLenum(plane), (*C.GLdouble)(unsafe.Pointer(&equation[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex4sv.xml
+func (gl *GL) Vertex4sv(v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glVertex4sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex4s.xml
+func (gl *GL) Vertex4s(x, y, z, w int16) {
+ C.gl4_3compat_glVertex4s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z), C.GLshort(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex4iv.xml
+func (gl *GL) Vertex4iv(v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glVertex4iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex4i.xml
+func (gl *GL) Vertex4i(x, y, z, w int) {
+ C.gl4_3compat_glVertex4i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z), C.GLint(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex4fv.xml
+func (gl *GL) Vertex4fv(v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glVertex4fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex4f.xml
+func (gl *GL) Vertex4f(x, y, z, w float32) {
+ C.gl4_3compat_glVertex4f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z), C.GLfloat(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex4dv.xml
+func (gl *GL) Vertex4dv(v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glVertex4dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex4d.xml
+func (gl *GL) Vertex4d(x, y, z, w float64) {
+ C.gl4_3compat_glVertex4d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z), C.GLdouble(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex3sv.xml
+func (gl *GL) Vertex3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glVertex3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex3s.xml
+func (gl *GL) Vertex3s(x, y, z int16) {
+ C.gl4_3compat_glVertex3s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex3iv.xml
+func (gl *GL) Vertex3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glVertex3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex3i.xml
+func (gl *GL) Vertex3i(x, y, z int) {
+ C.gl4_3compat_glVertex3i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex3fv.xml
+func (gl *GL) Vertex3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glVertex3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex3f.xml
+func (gl *GL) Vertex3f(x, y, z float32) {
+ C.gl4_3compat_glVertex3f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex3dv.xml
+func (gl *GL) Vertex3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glVertex3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex3d.xml
+func (gl *GL) Vertex3d(x, y, z float64) {
+ C.gl4_3compat_glVertex3d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex2sv.xml
+func (gl *GL) Vertex2sv(v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glVertex2sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex2s.xml
+func (gl *GL) Vertex2s(x, y int16) {
+ C.gl4_3compat_glVertex2s(gl.funcs, C.GLshort(x), C.GLshort(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex2iv.xml
+func (gl *GL) Vertex2iv(v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glVertex2iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex2i.xml
+func (gl *GL) Vertex2i(x, y int) {
+ C.gl4_3compat_glVertex2i(gl.funcs, C.GLint(x), C.GLint(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex2fv.xml
+func (gl *GL) Vertex2fv(v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glVertex2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex2f.xml
+func (gl *GL) Vertex2f(x, y float32) {
+ C.gl4_3compat_glVertex2f(gl.funcs, C.GLfloat(x), C.GLfloat(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex2dv.xml
+func (gl *GL) Vertex2dv(v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glVertex2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertex2d.xml
+func (gl *GL) Vertex2d(x, y float64) {
+ C.gl4_3compat_glVertex2d(gl.funcs, C.GLdouble(x), C.GLdouble(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord4sv.xml
+func (gl *GL) TexCoord4sv(v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glTexCoord4sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord4s.xml
+func (gl *GL) TexCoord4s(s, t, r, q int16) {
+ C.gl4_3compat_glTexCoord4s(gl.funcs, C.GLshort(s), C.GLshort(t), C.GLshort(r), C.GLshort(q))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord4iv.xml
+func (gl *GL) TexCoord4iv(v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glTexCoord4iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord4i.xml
+func (gl *GL) TexCoord4i(s, t, r, q int32) {
+ C.gl4_3compat_glTexCoord4i(gl.funcs, C.GLint(s), C.GLint(t), C.GLint(r), C.GLint(q))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord4fv.xml
+func (gl *GL) TexCoord4fv(v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glTexCoord4fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord4f.xml
+func (gl *GL) TexCoord4f(s, t, r, q float32) {
+ C.gl4_3compat_glTexCoord4f(gl.funcs, C.GLfloat(s), C.GLfloat(t), C.GLfloat(r), C.GLfloat(q))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord4dv.xml
+func (gl *GL) TexCoord4dv(v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glTexCoord4dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord4d.xml
+func (gl *GL) TexCoord4d(s, t, r, q float64) {
+ C.gl4_3compat_glTexCoord4d(gl.funcs, C.GLdouble(s), C.GLdouble(t), C.GLdouble(r), C.GLdouble(q))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord3sv.xml
+func (gl *GL) TexCoord3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glTexCoord3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord3s.xml
+func (gl *GL) TexCoord3s(s, t, r int16) {
+ C.gl4_3compat_glTexCoord3s(gl.funcs, C.GLshort(s), C.GLshort(t), C.GLshort(r))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord3iv.xml
+func (gl *GL) TexCoord3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glTexCoord3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord3i.xml
+func (gl *GL) TexCoord3i(s, t, r int32) {
+ C.gl4_3compat_glTexCoord3i(gl.funcs, C.GLint(s), C.GLint(t), C.GLint(r))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord3fv.xml
+func (gl *GL) TexCoord3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glTexCoord3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord3f.xml
+func (gl *GL) TexCoord3f(s, t, r float32) {
+ C.gl4_3compat_glTexCoord3f(gl.funcs, C.GLfloat(s), C.GLfloat(t), C.GLfloat(r))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord3dv.xml
+func (gl *GL) TexCoord3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glTexCoord3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord3d.xml
+func (gl *GL) TexCoord3d(s, t, r float64) {
+ C.gl4_3compat_glTexCoord3d(gl.funcs, C.GLdouble(s), C.GLdouble(t), C.GLdouble(r))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord2sv.xml
+func (gl *GL) TexCoord2sv(v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glTexCoord2sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord2s.xml
+func (gl *GL) TexCoord2s(s, t int16) {
+ C.gl4_3compat_glTexCoord2s(gl.funcs, C.GLshort(s), C.GLshort(t))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord2iv.xml
+func (gl *GL) TexCoord2iv(v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glTexCoord2iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord2i.xml
+func (gl *GL) TexCoord2i(s, t int32) {
+ C.gl4_3compat_glTexCoord2i(gl.funcs, C.GLint(s), C.GLint(t))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord2fv.xml
+func (gl *GL) TexCoord2fv(v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glTexCoord2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord2f.xml
+func (gl *GL) TexCoord2f(s, t float32) {
+ C.gl4_3compat_glTexCoord2f(gl.funcs, C.GLfloat(s), C.GLfloat(t))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord2dv.xml
+func (gl *GL) TexCoord2dv(v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glTexCoord2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord2d.xml
+func (gl *GL) TexCoord2d(s, t float64) {
+ C.gl4_3compat_glTexCoord2d(gl.funcs, C.GLdouble(s), C.GLdouble(t))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord1sv.xml
+func (gl *GL) TexCoord1sv(v []int16) {
+ C.gl4_3compat_glTexCoord1sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord1s.xml
+func (gl *GL) TexCoord1s(s int16) {
+ C.gl4_3compat_glTexCoord1s(gl.funcs, C.GLshort(s))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord1iv.xml
+func (gl *GL) TexCoord1iv(v []int32) {
+ C.gl4_3compat_glTexCoord1iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord1i.xml
+func (gl *GL) TexCoord1i(s int32) {
+ C.gl4_3compat_glTexCoord1i(gl.funcs, C.GLint(s))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord1fv.xml
+func (gl *GL) TexCoord1fv(v []float32) {
+ C.gl4_3compat_glTexCoord1fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord1f.xml
+func (gl *GL) TexCoord1f(s float32) {
+ C.gl4_3compat_glTexCoord1f(gl.funcs, C.GLfloat(s))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord1dv.xml
+func (gl *GL) TexCoord1dv(v []float64) {
+ C.gl4_3compat_glTexCoord1dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoord1d.xml
+func (gl *GL) TexCoord1d(s float64) {
+ C.gl4_3compat_glTexCoord1d(gl.funcs, C.GLdouble(s))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRectsv.xml
+func (gl *GL) Rectsv(v1, v2 []int16) {
+ C.gl4_3compat_glRectsv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v1[0])), (*C.GLshort)(unsafe.Pointer(&v2[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRects.xml
+func (gl *GL) Rects(x1, y1, x2, y2 int16) {
+ C.gl4_3compat_glRects(gl.funcs, C.GLshort(x1), C.GLshort(y1), C.GLshort(x2), C.GLshort(y2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRectiv.xml
+func (gl *GL) Rectiv(v1, v2 []int32) {
+ C.gl4_3compat_glRectiv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v1[0])), (*C.GLint)(unsafe.Pointer(&v2[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRecti.xml
+func (gl *GL) Recti(x1, y1, x2, y2 int32) {
+ C.gl4_3compat_glRecti(gl.funcs, C.GLint(x1), C.GLint(y1), C.GLint(x2), C.GLint(y2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRectfv.xml
+func (gl *GL) Rectfv(v1, v2 []float32) {
+ C.gl4_3compat_glRectfv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v1[0])), (*C.GLfloat)(unsafe.Pointer(&v2[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRectf.xml
+func (gl *GL) Rectf(x1, y1, x2, y2 float32) {
+ C.gl4_3compat_glRectf(gl.funcs, C.GLfloat(x1), C.GLfloat(y1), C.GLfloat(x2), C.GLfloat(y2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRectdv.xml
+func (gl *GL) Rectdv(v1, v2 []float64) {
+ C.gl4_3compat_glRectdv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v1[0])), (*C.GLdouble)(unsafe.Pointer(&v2[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRectd.xml
+func (gl *GL) Rectd(x1, y1, x2, y2 float64) {
+ C.gl4_3compat_glRectd(gl.funcs, C.GLdouble(x1), C.GLdouble(y1), C.GLdouble(x2), C.GLdouble(y2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos4sv.xml
+func (gl *GL) RasterPos4sv(v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glRasterPos4sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos4s.xml
+func (gl *GL) RasterPos4s(x, y, z, w int16) {
+ C.gl4_3compat_glRasterPos4s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z), C.GLshort(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos4iv.xml
+func (gl *GL) RasterPos4iv(v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glRasterPos4iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos4i.xml
+func (gl *GL) RasterPos4i(x, y, z, w int) {
+ C.gl4_3compat_glRasterPos4i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z), C.GLint(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos4fv.xml
+func (gl *GL) RasterPos4fv(v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glRasterPos4fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos4f.xml
+func (gl *GL) RasterPos4f(x, y, z, w float32) {
+ C.gl4_3compat_glRasterPos4f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z), C.GLfloat(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos4dv.xml
+func (gl *GL) RasterPos4dv(v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glRasterPos4dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos4d.xml
+func (gl *GL) RasterPos4d(x, y, z, w float64) {
+ C.gl4_3compat_glRasterPos4d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z), C.GLdouble(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos3sv.xml
+func (gl *GL) RasterPos3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glRasterPos3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos3s.xml
+func (gl *GL) RasterPos3s(x, y, z int16) {
+ C.gl4_3compat_glRasterPos3s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos3iv.xml
+func (gl *GL) RasterPos3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glRasterPos3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos3i.xml
+func (gl *GL) RasterPos3i(x, y, z int) {
+ C.gl4_3compat_glRasterPos3i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos3fv.xml
+func (gl *GL) RasterPos3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glRasterPos3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos3f.xml
+func (gl *GL) RasterPos3f(x, y, z float32) {
+ C.gl4_3compat_glRasterPos3f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos3dv.xml
+func (gl *GL) RasterPos3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glRasterPos3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos3d.xml
+func (gl *GL) RasterPos3d(x, y, z float64) {
+ C.gl4_3compat_glRasterPos3d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos2sv.xml
+func (gl *GL) RasterPos2sv(v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glRasterPos2sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos2s.xml
+func (gl *GL) RasterPos2s(x, y int16) {
+ C.gl4_3compat_glRasterPos2s(gl.funcs, C.GLshort(x), C.GLshort(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos2iv.xml
+func (gl *GL) RasterPos2iv(v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glRasterPos2iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos2i.xml
+func (gl *GL) RasterPos2i(x, y int) {
+ C.gl4_3compat_glRasterPos2i(gl.funcs, C.GLint(x), C.GLint(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos2fv.xml
+func (gl *GL) RasterPos2fv(v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glRasterPos2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos2f.xml
+func (gl *GL) RasterPos2f(x, y float32) {
+ C.gl4_3compat_glRasterPos2f(gl.funcs, C.GLfloat(x), C.GLfloat(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos2dv.xml
+func (gl *GL) RasterPos2dv(v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glRasterPos2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRasterPos2d.xml
+func (gl *GL) RasterPos2d(x, y float64) {
+ C.gl4_3compat_glRasterPos2d(gl.funcs, C.GLdouble(x), C.GLdouble(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNormal3sv.xml
+func (gl *GL) Normal3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glNormal3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNormal3s.xml
+func (gl *GL) Normal3s(nx, ny, nz int16) {
+ C.gl4_3compat_glNormal3s(gl.funcs, C.GLshort(nx), C.GLshort(ny), C.GLshort(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNormal3iv.xml
+func (gl *GL) Normal3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glNormal3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNormal3i.xml
+func (gl *GL) Normal3i(nx, ny, nz int32) {
+ C.gl4_3compat_glNormal3i(gl.funcs, C.GLint(nx), C.GLint(ny), C.GLint(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNormal3fv.xml
+func (gl *GL) Normal3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glNormal3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNormal3f.xml
+func (gl *GL) Normal3f(nx, ny, nz float32) {
+ C.gl4_3compat_glNormal3f(gl.funcs, C.GLfloat(nx), C.GLfloat(ny), C.GLfloat(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNormal3dv.xml
+func (gl *GL) Normal3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glNormal3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNormal3d.xml
+func (gl *GL) Normal3d(nx, ny, nz float64) {
+ C.gl4_3compat_glNormal3d(gl.funcs, C.GLdouble(nx), C.GLdouble(ny), C.GLdouble(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNormal3bv.xml
+func (gl *GL) Normal3bv(v []byte) {
+ C.gl4_3compat_glNormal3bv(gl.funcs, (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNormal3b.xml
+func (gl *GL) Normal3b(nx, ny, nz byte) {
+ C.gl4_3compat_glNormal3b(gl.funcs, C.GLbyte(nx), C.GLbyte(ny), C.GLbyte(nz))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIndexsv.xml
+func (gl *GL) Indexsv(c []int16) {
+ C.gl4_3compat_glIndexsv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIndexs.xml
+func (gl *GL) Indexs(c int16) {
+ C.gl4_3compat_glIndexs(gl.funcs, C.GLshort(c))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIndexiv.xml
+func (gl *GL) Indexiv(c []int32) {
+ C.gl4_3compat_glIndexiv(gl.funcs, (*C.GLint)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIndexi.xml
+func (gl *GL) Indexi(c int32) {
+ C.gl4_3compat_glIndexi(gl.funcs, C.GLint(c))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIndexfv.xml
+func (gl *GL) Indexfv(c []float32) {
+ C.gl4_3compat_glIndexfv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIndexf.xml
+func (gl *GL) Indexf(c float32) {
+ C.gl4_3compat_glIndexf(gl.funcs, C.GLfloat(c))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIndexdv.xml
+func (gl *GL) Indexdv(c []float64) {
+ C.gl4_3compat_glIndexdv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIndexd.xml
+func (gl *GL) Indexd(c float64) {
+ C.gl4_3compat_glIndexd(gl.funcs, C.GLdouble(c))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEnd.xml
+func (gl *GL) End() {
+ C.gl4_3compat_glEnd(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEdgeFlagv.xml
+func (gl *GL) EdgeFlagv(flag []bool) {
+ C.gl4_3compat_glEdgeFlagv(gl.funcs, (*C.GLboolean)(unsafe.Pointer(&flag[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEdgeFlag.xml
+func (gl *GL) EdgeFlag(flag bool) {
+ C.gl4_3compat_glEdgeFlag(gl.funcs, *(*C.GLboolean)(unsafe.Pointer(&flag)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4usv.xml
+func (gl *GL) Color4usv(v []uint16) {
+ C.gl4_3compat_glColor4usv(gl.funcs, (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4us.xml
+func (gl *GL) Color4us(red, green, blue, alpha uint16) {
+ C.gl4_3compat_glColor4us(gl.funcs, C.GLushort(red), C.GLushort(green), C.GLushort(blue), C.GLushort(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4uiv.xml
+func (gl *GL) Color4uiv(v []uint32) {
+ C.gl4_3compat_glColor4uiv(gl.funcs, (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4ui.xml
+func (gl *GL) Color4ui(red, green, blue, alpha uint32) {
+ C.gl4_3compat_glColor4ui(gl.funcs, C.GLuint(red), C.GLuint(green), C.GLuint(blue), C.GLuint(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4ubv.xml
+func (gl *GL) Color4ubv(v []uint8) {
+ C.gl4_3compat_glColor4ubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4ub.xml
+func (gl *GL) Color4ub(red, green, blue, alpha uint8) {
+ C.gl4_3compat_glColor4ub(gl.funcs, C.GLubyte(red), C.GLubyte(green), C.GLubyte(blue), C.GLubyte(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4sv.xml
+func (gl *GL) Color4sv(v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glColor4sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4s.xml
+func (gl *GL) Color4s(red, green, blue, alpha int16) {
+ C.gl4_3compat_glColor4s(gl.funcs, C.GLshort(red), C.GLshort(green), C.GLshort(blue), C.GLshort(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4iv.xml
+func (gl *GL) Color4iv(v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glColor4iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4i.xml
+func (gl *GL) Color4i(red, green, blue, alpha int32) {
+ C.gl4_3compat_glColor4i(gl.funcs, C.GLint(red), C.GLint(green), C.GLint(blue), C.GLint(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4fv.xml
+func (gl *GL) Color4fv(v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glColor4fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4f.xml
+func (gl *GL) Color4f(red, green, blue, alpha float32) {
+ C.gl4_3compat_glColor4f(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4dv.xml
+func (gl *GL) Color4dv(v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glColor4dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4d.xml
+func (gl *GL) Color4d(red, green, blue, alpha float64) {
+ C.gl4_3compat_glColor4d(gl.funcs, C.GLdouble(red), C.GLdouble(green), C.GLdouble(blue), C.GLdouble(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4bv.xml
+func (gl *GL) Color4bv(v []byte) {
+ C.gl4_3compat_glColor4bv(gl.funcs, (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor4b.xml
+func (gl *GL) Color4b(red, green, blue, alpha byte) {
+ C.gl4_3compat_glColor4b(gl.funcs, C.GLbyte(red), C.GLbyte(green), C.GLbyte(blue), C.GLbyte(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3usv.xml
+func (gl *GL) Color3usv(v []uint16) {
+ C.gl4_3compat_glColor3usv(gl.funcs, (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3us.xml
+func (gl *GL) Color3us(red, green, blue uint16) {
+ C.gl4_3compat_glColor3us(gl.funcs, C.GLushort(red), C.GLushort(green), C.GLushort(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3uiv.xml
+func (gl *GL) Color3uiv(v []uint32) {
+ C.gl4_3compat_glColor3uiv(gl.funcs, (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3ui.xml
+func (gl *GL) Color3ui(red, green, blue uint32) {
+ C.gl4_3compat_glColor3ui(gl.funcs, C.GLuint(red), C.GLuint(green), C.GLuint(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3ubv.xml
+func (gl *GL) Color3ubv(v []uint8) {
+ C.gl4_3compat_glColor3ubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3ub.xml
+func (gl *GL) Color3ub(red, green, blue uint8) {
+ C.gl4_3compat_glColor3ub(gl.funcs, C.GLubyte(red), C.GLubyte(green), C.GLubyte(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3sv.xml
+func (gl *GL) Color3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glColor3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3s.xml
+func (gl *GL) Color3s(red, green, blue int16) {
+ C.gl4_3compat_glColor3s(gl.funcs, C.GLshort(red), C.GLshort(green), C.GLshort(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3iv.xml
+func (gl *GL) Color3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glColor3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3i.xml
+func (gl *GL) Color3i(red, green, blue int32) {
+ C.gl4_3compat_glColor3i(gl.funcs, C.GLint(red), C.GLint(green), C.GLint(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3fv.xml
+func (gl *GL) Color3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glColor3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3f.xml
+func (gl *GL) Color3f(red, green, blue float32) {
+ C.gl4_3compat_glColor3f(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3dv.xml
+func (gl *GL) Color3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glColor3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3d.xml
+func (gl *GL) Color3d(red, green, blue float64) {
+ C.gl4_3compat_glColor3d(gl.funcs, C.GLdouble(red), C.GLdouble(green), C.GLdouble(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3bv.xml
+func (gl *GL) Color3bv(v []byte) {
+ C.gl4_3compat_glColor3bv(gl.funcs, (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColor3b.xml
+func (gl *GL) Color3b(red, green, blue byte) {
+ C.gl4_3compat_glColor3b(gl.funcs, C.GLbyte(red), C.GLbyte(green), C.GLbyte(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBitmap.xml
+func (gl *GL) Bitmap(width, height int, xorig, yorig, xmove, ymove float32, bitmap []uint8) {
+ C.gl4_3compat_glBitmap(gl.funcs, C.GLsizei(width), C.GLsizei(height), C.GLfloat(xorig), C.GLfloat(yorig), C.GLfloat(xmove), C.GLfloat(ymove), (*C.GLubyte)(unsafe.Pointer(&bitmap[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBegin.xml
+func (gl *GL) Begin(mode glbase.Enum) {
+ C.gl4_3compat_glBegin(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glListBase.xml
+func (gl *GL) ListBase(base uint32) {
+ C.gl4_3compat_glListBase(gl.funcs, C.GLuint(base))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGenLists.xml
+func (gl *GL) GenLists(range_ int32) uint32 {
+ glresult := C.gl4_3compat_glGenLists(gl.funcs, C.GLsizei(range_))
+ return uint32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDeleteLists.xml
+func (gl *GL) DeleteLists(list uint32, range_ int32) {
+ C.gl4_3compat_glDeleteLists(gl.funcs, C.GLuint(list), C.GLsizei(range_))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCallLists.xml
+func (gl *GL) CallLists(n int, gltype glbase.Enum, lists interface{}) {
+ var lists_ptr unsafe.Pointer
+ var lists_v = reflect.ValueOf(lists)
+ if lists != nil && lists_v.Kind() != reflect.Slice {
+ panic("parameter lists must be a slice")
+ }
+ if lists != nil {
+ lists_ptr = unsafe.Pointer(lists_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3compat_glCallLists(gl.funcs, C.GLsizei(n), C.GLenum(gltype), lists_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCallList.xml
+func (gl *GL) CallList(list uint32) {
+ C.gl4_3compat_glCallList(gl.funcs, C.GLuint(list))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEndList.xml
+func (gl *GL) EndList() {
+ C.gl4_3compat_glEndList(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNewList.xml
+func (gl *GL) NewList(list uint32, mode glbase.Enum) {
+ C.gl4_3compat_glNewList(gl.funcs, C.GLuint(list), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPushClientAttrib.xml
+func (gl *GL) PushClientAttrib(mask glbase.Bitfield) {
+ C.gl4_3compat_glPushClientAttrib(gl.funcs, C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPopClientAttrib.xml
+func (gl *GL) PopClientAttrib() {
+ C.gl4_3compat_glPopClientAttrib(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPrioritizeTextures.xml
+func (gl *GL) PrioritizeTextures(n int, textures []glbase.Texture, priorities []float32) {
+ C.gl4_3compat_glPrioritizeTextures(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])), (*C.GLfloat)(unsafe.Pointer(&priorities[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glAreTexturesResident.xml
+func (gl *GL) AreTexturesResident(n int, textures []glbase.Texture, residences []bool) bool {
+ glresult := C.gl4_3compat_glAreTexturesResident(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])), (*C.GLboolean)(unsafe.Pointer(&residences[0])))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexPointer.xml
+func (gl *GL) VertexPointer(size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3compat_glVertexPointer(gl.funcs, C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordPointer.xml
+func (gl *GL) TexCoordPointer(size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3compat_glTexCoordPointer(gl.funcs, C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNormalPointer.xml
+func (gl *GL) NormalPointer(gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3compat_glNormalPointer(gl.funcs, C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glInterleavedArrays.xml
+func (gl *GL) InterleavedArrays(format glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3compat_glInterleavedArrays(gl.funcs, C.GLenum(format), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIndexPointer.xml
+func (gl *GL) IndexPointer(gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3compat_glIndexPointer(gl.funcs, C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEnableClientState.xml
+func (gl *GL) EnableClientState(array glbase.Enum) {
+ C.gl4_3compat_glEnableClientState(gl.funcs, C.GLenum(array))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEdgeFlagPointer.xml
+func (gl *GL) EdgeFlagPointer(stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3compat_glEdgeFlagPointer(gl.funcs, C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDisableClientState.xml
+func (gl *GL) DisableClientState(array glbase.Enum) {
+ C.gl4_3compat_glDisableClientState(gl.funcs, C.GLenum(array))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorPointer.xml
+func (gl *GL) ColorPointer(size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3compat_glColorPointer(gl.funcs, C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glArrayElement.xml
+func (gl *GL) ArrayElement(i int32) {
+ C.gl4_3compat_glArrayElement(gl.funcs, C.GLint(i))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glResetMinmax.xml
+func (gl *GL) ResetMinmax(target glbase.Enum) {
+ C.gl4_3compat_glResetMinmax(gl.funcs, C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glResetHistogram.xml
+func (gl *GL) ResetHistogram(target glbase.Enum) {
+ C.gl4_3compat_glResetHistogram(gl.funcs, C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMinmax.xml
+func (gl *GL) Minmax(target, internalFormat glbase.Enum, sink bool) {
+ C.gl4_3compat_glMinmax(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), *(*C.GLboolean)(unsafe.Pointer(&sink)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glHistogram.xml
+func (gl *GL) Histogram(target glbase.Enum, width int, internalFormat glbase.Enum, sink bool) {
+ C.gl4_3compat_glHistogram(gl.funcs, C.GLenum(target), C.GLsizei(width), C.GLenum(internalFormat), *(*C.GLboolean)(unsafe.Pointer(&sink)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetMinmaxParameteriv.xml
+func (gl *GL) GetMinmaxParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl4_3compat_glGetMinmaxParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetMinmaxParameterfv.xml
+func (gl *GL) GetMinmaxParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl4_3compat_glGetMinmaxParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetMinmax.xml
+func (gl *GL) GetMinmax(target glbase.Enum, reset bool, format, gltype glbase.Enum, values interface{}) {
+ var values_ptr unsafe.Pointer
+ var values_v = reflect.ValueOf(values)
+ if values != nil && values_v.Kind() != reflect.Slice {
+ panic("parameter values must be a slice")
+ }
+ if values != nil {
+ values_ptr = unsafe.Pointer(values_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3compat_glGetMinmax(gl.funcs, C.GLenum(target), *(*C.GLboolean)(unsafe.Pointer(&reset)), C.GLenum(format), C.GLenum(gltype), values_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetHistogramParameteriv.xml
+func (gl *GL) GetHistogramParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl4_3compat_glGetHistogramParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetHistogramParameterfv.xml
+func (gl *GL) GetHistogramParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl4_3compat_glGetHistogramParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetHistogram.xml
+func (gl *GL) GetHistogram(target glbase.Enum, reset bool, format, gltype glbase.Enum, values interface{}) {
+ var values_ptr unsafe.Pointer
+ var values_v = reflect.ValueOf(values)
+ if values != nil && values_v.Kind() != reflect.Slice {
+ panic("parameter values must be a slice")
+ }
+ if values != nil {
+ values_ptr = unsafe.Pointer(values_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3compat_glGetHistogram(gl.funcs, C.GLenum(target), *(*C.GLboolean)(unsafe.Pointer(&reset)), C.GLenum(format), C.GLenum(gltype), values_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSeparableFilter2D.xml
+func (gl *GL) SeparableFilter2D(target, internalFormat glbase.Enum, width, height int, format, gltype glbase.Enum, row, column interface{}) {
+ var row_ptr unsafe.Pointer
+ var row_v = reflect.ValueOf(row)
+ if row != nil && row_v.Kind() != reflect.Slice {
+ panic("parameter row must be a slice")
+ }
+ if row != nil {
+ row_ptr = unsafe.Pointer(row_v.Index(0).Addr().Pointer())
+ }
+ var column_ptr unsafe.Pointer
+ var column_v = reflect.ValueOf(column)
+ if column != nil && column_v.Kind() != reflect.Slice {
+ panic("parameter column must be a slice")
+ }
+ if column != nil {
+ column_ptr = unsafe.Pointer(column_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3compat_glSeparableFilter2D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), row_ptr, column_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetSeparableFilter.xml
+func (gl *GL) GetSeparableFilter(target, format, gltype glbase.Enum, row, column, span interface{}) {
+ var row_ptr unsafe.Pointer
+ var row_v = reflect.ValueOf(row)
+ if row != nil && row_v.Kind() != reflect.Slice {
+ panic("parameter row must be a slice")
+ }
+ if row != nil {
+ row_ptr = unsafe.Pointer(row_v.Index(0).Addr().Pointer())
+ }
+ var column_ptr unsafe.Pointer
+ var column_v = reflect.ValueOf(column)
+ if column != nil && column_v.Kind() != reflect.Slice {
+ panic("parameter column must be a slice")
+ }
+ if column != nil {
+ column_ptr = unsafe.Pointer(column_v.Index(0).Addr().Pointer())
+ }
+ var span_ptr unsafe.Pointer
+ var span_v = reflect.ValueOf(span)
+ if span != nil && span_v.Kind() != reflect.Slice {
+ panic("parameter span must be a slice")
+ }
+ if span != nil {
+ span_ptr = unsafe.Pointer(span_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3compat_glGetSeparableFilter(gl.funcs, C.GLenum(target), C.GLenum(format), C.GLenum(gltype), row_ptr, column_ptr, span_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetConvolutionParameteriv.xml
+func (gl *GL) GetConvolutionParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl4_3compat_glGetConvolutionParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetConvolutionParameterfv.xml
+func (gl *GL) GetConvolutionParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl4_3compat_glGetConvolutionParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetConvolutionFilter.xml
+func (gl *GL) GetConvolutionFilter(target, format, gltype glbase.Enum, image interface{}) {
+ var image_ptr unsafe.Pointer
+ var image_v = reflect.ValueOf(image)
+ if image != nil && image_v.Kind() != reflect.Slice {
+ panic("parameter image must be a slice")
+ }
+ if image != nil {
+ image_ptr = unsafe.Pointer(image_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3compat_glGetConvolutionFilter(gl.funcs, C.GLenum(target), C.GLenum(format), C.GLenum(gltype), image_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyConvolutionFilter2D.xml
+func (gl *GL) CopyConvolutionFilter2D(target, internalFormat glbase.Enum, x, y, width, height int) {
+ C.gl4_3compat_glCopyConvolutionFilter2D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyConvolutionFilter1D.xml
+func (gl *GL) CopyConvolutionFilter1D(target, internalFormat glbase.Enum, x, y, width int) {
+ C.gl4_3compat_glCopyConvolutionFilter1D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glConvolutionParameteriv.xml
+func (gl *GL) ConvolutionParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl4_3compat_glConvolutionParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glConvolutionParameteri.xml
+func (gl *GL) ConvolutionParameteri(target, pname glbase.Enum, params int32) {
+ C.gl4_3compat_glConvolutionParameteri(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLint(params))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glConvolutionParameterfv.xml
+func (gl *GL) ConvolutionParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl4_3compat_glConvolutionParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glConvolutionParameterf.xml
+func (gl *GL) ConvolutionParameterf(target, pname glbase.Enum, params float32) {
+ C.gl4_3compat_glConvolutionParameterf(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLfloat(params))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glConvolutionFilter2D.xml
+func (gl *GL) ConvolutionFilter2D(target, internalFormat glbase.Enum, width, height int, format, gltype glbase.Enum, image interface{}) {
+ var image_ptr unsafe.Pointer
+ var image_v = reflect.ValueOf(image)
+ if image != nil && image_v.Kind() != reflect.Slice {
+ panic("parameter image must be a slice")
+ }
+ if image != nil {
+ image_ptr = unsafe.Pointer(image_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3compat_glConvolutionFilter2D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), image_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glConvolutionFilter1D.xml
+func (gl *GL) ConvolutionFilter1D(target, internalFormat glbase.Enum, width int, format, gltype glbase.Enum, image interface{}) {
+ var image_ptr unsafe.Pointer
+ var image_v = reflect.ValueOf(image)
+ if image != nil && image_v.Kind() != reflect.Slice {
+ panic("parameter image must be a slice")
+ }
+ if image != nil {
+ image_ptr = unsafe.Pointer(image_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3compat_glConvolutionFilter1D(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLenum(format), C.GLenum(gltype), image_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyColorSubTable.xml
+func (gl *GL) CopyColorSubTable(target glbase.Enum, start int32, x, y, width int) {
+ C.gl4_3compat_glCopyColorSubTable(gl.funcs, C.GLenum(target), C.GLsizei(start), C.GLint(x), C.GLint(y), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorSubTable.xml
+func (gl *GL) ColorSubTable(target glbase.Enum, start int32, count int, format, gltype glbase.Enum, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3compat_glColorSubTable(gl.funcs, C.GLenum(target), C.GLsizei(start), C.GLsizei(count), C.GLenum(format), C.GLenum(gltype), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetColorTableParameteriv.xml
+func (gl *GL) GetColorTableParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl4_3compat_glGetColorTableParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetColorTableParameterfv.xml
+func (gl *GL) GetColorTableParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl4_3compat_glGetColorTableParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetColorTable.xml
+func (gl *GL) GetColorTable(target, format, gltype glbase.Enum, table interface{}) {
+ var table_ptr unsafe.Pointer
+ var table_v = reflect.ValueOf(table)
+ if table != nil && table_v.Kind() != reflect.Slice {
+ panic("parameter table must be a slice")
+ }
+ if table != nil {
+ table_ptr = unsafe.Pointer(table_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3compat_glGetColorTable(gl.funcs, C.GLenum(target), C.GLenum(format), C.GLenum(gltype), table_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyColorTable.xml
+func (gl *GL) CopyColorTable(target, internalFormat glbase.Enum, x, y, width int) {
+ C.gl4_3compat_glCopyColorTable(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorTableParameteriv.xml
+func (gl *GL) ColorTableParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl4_3compat_glColorTableParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorTableParameterfv.xml
+func (gl *GL) ColorTableParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl4_3compat_glColorTableParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorTable.xml
+func (gl *GL) ColorTable(target, internalFormat glbase.Enum, width int, format, gltype glbase.Enum, table interface{}) {
+ var table_ptr unsafe.Pointer
+ var table_v = reflect.ValueOf(table)
+ if table != nil && table_v.Kind() != reflect.Slice {
+ panic("parameter table must be a slice")
+ }
+ if table != nil {
+ table_ptr = unsafe.Pointer(table_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3compat_glColorTable(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLenum(format), C.GLenum(gltype), table_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultTransposeMatrixd.xml
+func (gl *GL) MultTransposeMatrixd(m []float64) {
+ C.gl4_3compat_glMultTransposeMatrixd(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultTransposeMatrixf.xml
+func (gl *GL) MultTransposeMatrixf(m []float32) {
+ C.gl4_3compat_glMultTransposeMatrixf(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLoadTransposeMatrixd.xml
+func (gl *GL) LoadTransposeMatrixd(m []float64) {
+ C.gl4_3compat_glLoadTransposeMatrixd(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLoadTransposeMatrixf.xml
+func (gl *GL) LoadTransposeMatrixf(m []float32) {
+ C.gl4_3compat_glLoadTransposeMatrixf(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&m[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord4sv.xml
+func (gl *GL) MultiTexCoord4sv(target glbase.Enum, v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glMultiTexCoord4sv(gl.funcs, C.GLenum(target), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord4s.xml
+func (gl *GL) MultiTexCoord4s(target glbase.Enum, s, t, r, q int16) {
+ C.gl4_3compat_glMultiTexCoord4s(gl.funcs, C.GLenum(target), C.GLshort(s), C.GLshort(t), C.GLshort(r), C.GLshort(q))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord4iv.xml
+func (gl *GL) MultiTexCoord4iv(target glbase.Enum, v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glMultiTexCoord4iv(gl.funcs, C.GLenum(target), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord4i.xml
+func (gl *GL) MultiTexCoord4i(target glbase.Enum, s, t, r, q int32) {
+ C.gl4_3compat_glMultiTexCoord4i(gl.funcs, C.GLenum(target), C.GLint(s), C.GLint(t), C.GLint(r), C.GLint(q))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord4fv.xml
+func (gl *GL) MultiTexCoord4fv(target glbase.Enum, v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glMultiTexCoord4fv(gl.funcs, C.GLenum(target), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord4f.xml
+func (gl *GL) MultiTexCoord4f(target glbase.Enum, s, t, r, q float32) {
+ C.gl4_3compat_glMultiTexCoord4f(gl.funcs, C.GLenum(target), C.GLfloat(s), C.GLfloat(t), C.GLfloat(r), C.GLfloat(q))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord4dv.xml
+func (gl *GL) MultiTexCoord4dv(target glbase.Enum, v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glMultiTexCoord4dv(gl.funcs, C.GLenum(target), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord4d.xml
+func (gl *GL) MultiTexCoord4d(target glbase.Enum, s, t, r, q float64) {
+ C.gl4_3compat_glMultiTexCoord4d(gl.funcs, C.GLenum(target), C.GLdouble(s), C.GLdouble(t), C.GLdouble(r), C.GLdouble(q))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord3sv.xml
+func (gl *GL) MultiTexCoord3sv(target glbase.Enum, v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glMultiTexCoord3sv(gl.funcs, C.GLenum(target), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord3s.xml
+func (gl *GL) MultiTexCoord3s(target glbase.Enum, s, t, r int16) {
+ C.gl4_3compat_glMultiTexCoord3s(gl.funcs, C.GLenum(target), C.GLshort(s), C.GLshort(t), C.GLshort(r))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord3iv.xml
+func (gl *GL) MultiTexCoord3iv(target glbase.Enum, v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glMultiTexCoord3iv(gl.funcs, C.GLenum(target), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord3i.xml
+func (gl *GL) MultiTexCoord3i(target glbase.Enum, s, t, r int32) {
+ C.gl4_3compat_glMultiTexCoord3i(gl.funcs, C.GLenum(target), C.GLint(s), C.GLint(t), C.GLint(r))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord3fv.xml
+func (gl *GL) MultiTexCoord3fv(target glbase.Enum, v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glMultiTexCoord3fv(gl.funcs, C.GLenum(target), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord3f.xml
+func (gl *GL) MultiTexCoord3f(target glbase.Enum, s, t, r float32) {
+ C.gl4_3compat_glMultiTexCoord3f(gl.funcs, C.GLenum(target), C.GLfloat(s), C.GLfloat(t), C.GLfloat(r))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord3dv.xml
+func (gl *GL) MultiTexCoord3dv(target glbase.Enum, v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glMultiTexCoord3dv(gl.funcs, C.GLenum(target), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord3d.xml
+func (gl *GL) MultiTexCoord3d(target glbase.Enum, s, t, r float64) {
+ C.gl4_3compat_glMultiTexCoord3d(gl.funcs, C.GLenum(target), C.GLdouble(s), C.GLdouble(t), C.GLdouble(r))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord2sv.xml
+func (gl *GL) MultiTexCoord2sv(target glbase.Enum, v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glMultiTexCoord2sv(gl.funcs, C.GLenum(target), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord2s.xml
+func (gl *GL) MultiTexCoord2s(target glbase.Enum, s, t int16) {
+ C.gl4_3compat_glMultiTexCoord2s(gl.funcs, C.GLenum(target), C.GLshort(s), C.GLshort(t))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord2iv.xml
+func (gl *GL) MultiTexCoord2iv(target glbase.Enum, v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glMultiTexCoord2iv(gl.funcs, C.GLenum(target), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord2i.xml
+func (gl *GL) MultiTexCoord2i(target glbase.Enum, s, t int32) {
+ C.gl4_3compat_glMultiTexCoord2i(gl.funcs, C.GLenum(target), C.GLint(s), C.GLint(t))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord2fv.xml
+func (gl *GL) MultiTexCoord2fv(target glbase.Enum, v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glMultiTexCoord2fv(gl.funcs, C.GLenum(target), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord2f.xml
+func (gl *GL) MultiTexCoord2f(target glbase.Enum, s, t float32) {
+ C.gl4_3compat_glMultiTexCoord2f(gl.funcs, C.GLenum(target), C.GLfloat(s), C.GLfloat(t))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord2dv.xml
+func (gl *GL) MultiTexCoord2dv(target glbase.Enum, v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glMultiTexCoord2dv(gl.funcs, C.GLenum(target), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord2d.xml
+func (gl *GL) MultiTexCoord2d(target glbase.Enum, s, t float64) {
+ C.gl4_3compat_glMultiTexCoord2d(gl.funcs, C.GLenum(target), C.GLdouble(s), C.GLdouble(t))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord1sv.xml
+func (gl *GL) MultiTexCoord1sv(target glbase.Enum, v []int16) {
+ C.gl4_3compat_glMultiTexCoord1sv(gl.funcs, C.GLenum(target), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord1s.xml
+func (gl *GL) MultiTexCoord1s(target glbase.Enum, s int16) {
+ C.gl4_3compat_glMultiTexCoord1s(gl.funcs, C.GLenum(target), C.GLshort(s))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord1iv.xml
+func (gl *GL) MultiTexCoord1iv(target glbase.Enum, v []int32) {
+ C.gl4_3compat_glMultiTexCoord1iv(gl.funcs, C.GLenum(target), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord1i.xml
+func (gl *GL) MultiTexCoord1i(target glbase.Enum, s int32) {
+ C.gl4_3compat_glMultiTexCoord1i(gl.funcs, C.GLenum(target), C.GLint(s))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord1fv.xml
+func (gl *GL) MultiTexCoord1fv(target glbase.Enum, v []float32) {
+ C.gl4_3compat_glMultiTexCoord1fv(gl.funcs, C.GLenum(target), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord1f.xml
+func (gl *GL) MultiTexCoord1f(target glbase.Enum, s float32) {
+ C.gl4_3compat_glMultiTexCoord1f(gl.funcs, C.GLenum(target), C.GLfloat(s))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord1dv.xml
+func (gl *GL) MultiTexCoord1dv(target glbase.Enum, v []float64) {
+ C.gl4_3compat_glMultiTexCoord1dv(gl.funcs, C.GLenum(target), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoord1d.xml
+func (gl *GL) MultiTexCoord1d(target glbase.Enum, s float64) {
+ C.gl4_3compat_glMultiTexCoord1d(gl.funcs, C.GLenum(target), C.GLdouble(s))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClientActiveTexture.xml
+func (gl *GL) ClientActiveTexture(texture glbase.Enum) {
+ C.gl4_3compat_glClientActiveTexture(gl.funcs, C.GLenum(texture))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos3sv.xml
+func (gl *GL) WindowPos3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glWindowPos3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos3s.xml
+func (gl *GL) WindowPos3s(x, y, z int16) {
+ C.gl4_3compat_glWindowPos3s(gl.funcs, C.GLshort(x), C.GLshort(y), C.GLshort(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos3iv.xml
+func (gl *GL) WindowPos3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glWindowPos3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos3i.xml
+func (gl *GL) WindowPos3i(x, y, z int) {
+ C.gl4_3compat_glWindowPos3i(gl.funcs, C.GLint(x), C.GLint(y), C.GLint(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos3fv.xml
+func (gl *GL) WindowPos3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glWindowPos3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos3f.xml
+func (gl *GL) WindowPos3f(x, y, z float32) {
+ C.gl4_3compat_glWindowPos3f(gl.funcs, C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos3dv.xml
+func (gl *GL) WindowPos3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glWindowPos3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos3d.xml
+func (gl *GL) WindowPos3d(x, y, z float64) {
+ C.gl4_3compat_glWindowPos3d(gl.funcs, C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos2sv.xml
+func (gl *GL) WindowPos2sv(v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glWindowPos2sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos2s.xml
+func (gl *GL) WindowPos2s(x, y int16) {
+ C.gl4_3compat_glWindowPos2s(gl.funcs, C.GLshort(x), C.GLshort(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos2iv.xml
+func (gl *GL) WindowPos2iv(v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glWindowPos2iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos2i.xml
+func (gl *GL) WindowPos2i(x, y int) {
+ C.gl4_3compat_glWindowPos2i(gl.funcs, C.GLint(x), C.GLint(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos2fv.xml
+func (gl *GL) WindowPos2fv(v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glWindowPos2fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos2f.xml
+func (gl *GL) WindowPos2f(x, y float32) {
+ C.gl4_3compat_glWindowPos2f(gl.funcs, C.GLfloat(x), C.GLfloat(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos2dv.xml
+func (gl *GL) WindowPos2dv(v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glWindowPos2dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWindowPos2d.xml
+func (gl *GL) WindowPos2d(x, y float64) {
+ C.gl4_3compat_glWindowPos2d(gl.funcs, C.GLdouble(x), C.GLdouble(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColorPointer.xml
+func (gl *GL) SecondaryColorPointer(size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3compat_glSecondaryColorPointer(gl.funcs, C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3usv.xml
+func (gl *GL) SecondaryColor3usv(v []uint16) {
+ C.gl4_3compat_glSecondaryColor3usv(gl.funcs, (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3us.xml
+func (gl *GL) SecondaryColor3us(red, green, blue uint16) {
+ C.gl4_3compat_glSecondaryColor3us(gl.funcs, C.GLushort(red), C.GLushort(green), C.GLushort(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3uiv.xml
+func (gl *GL) SecondaryColor3uiv(v []uint32) {
+ C.gl4_3compat_glSecondaryColor3uiv(gl.funcs, (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3ui.xml
+func (gl *GL) SecondaryColor3ui(red, green, blue uint32) {
+ C.gl4_3compat_glSecondaryColor3ui(gl.funcs, C.GLuint(red), C.GLuint(green), C.GLuint(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3ubv.xml
+func (gl *GL) SecondaryColor3ubv(v []uint8) {
+ C.gl4_3compat_glSecondaryColor3ubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3ub.xml
+func (gl *GL) SecondaryColor3ub(red, green, blue uint8) {
+ C.gl4_3compat_glSecondaryColor3ub(gl.funcs, C.GLubyte(red), C.GLubyte(green), C.GLubyte(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3sv.xml
+func (gl *GL) SecondaryColor3sv(v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glSecondaryColor3sv(gl.funcs, (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3s.xml
+func (gl *GL) SecondaryColor3s(red, green, blue int16) {
+ C.gl4_3compat_glSecondaryColor3s(gl.funcs, C.GLshort(red), C.GLshort(green), C.GLshort(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3iv.xml
+func (gl *GL) SecondaryColor3iv(v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glSecondaryColor3iv(gl.funcs, (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3i.xml
+func (gl *GL) SecondaryColor3i(red, green, blue int32) {
+ C.gl4_3compat_glSecondaryColor3i(gl.funcs, C.GLint(red), C.GLint(green), C.GLint(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3fv.xml
+func (gl *GL) SecondaryColor3fv(v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glSecondaryColor3fv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3f.xml
+func (gl *GL) SecondaryColor3f(red, green, blue float32) {
+ C.gl4_3compat_glSecondaryColor3f(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3dv.xml
+func (gl *GL) SecondaryColor3dv(v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glSecondaryColor3dv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3d.xml
+func (gl *GL) SecondaryColor3d(red, green, blue float64) {
+ C.gl4_3compat_glSecondaryColor3d(gl.funcs, C.GLdouble(red), C.GLdouble(green), C.GLdouble(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3bv.xml
+func (gl *GL) SecondaryColor3bv(v []byte) {
+ C.gl4_3compat_glSecondaryColor3bv(gl.funcs, (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColor3b.xml
+func (gl *GL) SecondaryColor3b(red, green, blue byte) {
+ C.gl4_3compat_glSecondaryColor3b(gl.funcs, C.GLbyte(red), C.GLbyte(green), C.GLbyte(blue))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFogCoordPointer.xml
+func (gl *GL) FogCoordPointer(gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3compat_glFogCoordPointer(gl.funcs, C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFogCoorddv.xml
+func (gl *GL) FogCoorddv(coord []float64) {
+ C.gl4_3compat_glFogCoorddv(gl.funcs, (*C.GLdouble)(unsafe.Pointer(&coord[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFogCoordd.xml
+func (gl *GL) FogCoordd(coord float64) {
+ C.gl4_3compat_glFogCoordd(gl.funcs, C.GLdouble(coord))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFogCoordfv.xml
+func (gl *GL) FogCoordfv(coord []float32) {
+ C.gl4_3compat_glFogCoordfv(gl.funcs, (*C.GLfloat)(unsafe.Pointer(&coord[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFogCoordf.xml
+func (gl *GL) FogCoordf(coord float32) {
+ C.gl4_3compat_glFogCoordf(gl.funcs, C.GLfloat(coord))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4usv.xml
+func (gl *GL) VertexAttrib4usv(index glbase.Attrib, v []uint16) {
+ C.gl4_3compat_glVertexAttrib4usv(gl.funcs, C.GLuint(index), (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4uiv.xml
+func (gl *GL) VertexAttrib4uiv(index glbase.Attrib, v []uint32) {
+ C.gl4_3compat_glVertexAttrib4uiv(gl.funcs, C.GLuint(index), (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4ubv.xml
+func (gl *GL) VertexAttrib4ubv(index glbase.Attrib, v []uint8) {
+ C.gl4_3compat_glVertexAttrib4ubv(gl.funcs, C.GLuint(index), (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4sv.xml
+func (gl *GL) VertexAttrib4sv(index glbase.Attrib, v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glVertexAttrib4sv(gl.funcs, C.GLuint(index), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4s.xml
+func (gl *GL) VertexAttrib4s(index glbase.Attrib, x, y, z, w int16) {
+ C.gl4_3compat_glVertexAttrib4s(gl.funcs, C.GLuint(index), C.GLshort(x), C.GLshort(y), C.GLshort(z), C.GLshort(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4iv.xml
+func (gl *GL) VertexAttrib4iv(index glbase.Attrib, v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glVertexAttrib4iv(gl.funcs, C.GLuint(index), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4fv.xml
+func (gl *GL) VertexAttrib4fv(index glbase.Attrib, v []float32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glVertexAttrib4fv(gl.funcs, C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4f.xml
+func (gl *GL) VertexAttrib4f(index glbase.Attrib, x, y, z, w float32) {
+ C.gl4_3compat_glVertexAttrib4f(gl.funcs, C.GLuint(index), C.GLfloat(x), C.GLfloat(y), C.GLfloat(z), C.GLfloat(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4dv.xml
+func (gl *GL) VertexAttrib4dv(index glbase.Attrib, v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glVertexAttrib4dv(gl.funcs, C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4d.xml
+func (gl *GL) VertexAttrib4d(index glbase.Attrib, x, y, z, w float64) {
+ C.gl4_3compat_glVertexAttrib4d(gl.funcs, C.GLuint(index), C.GLdouble(x), C.GLdouble(y), C.GLdouble(z), C.GLdouble(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4bv.xml
+func (gl *GL) VertexAttrib4bv(index glbase.Attrib, v []byte) {
+ C.gl4_3compat_glVertexAttrib4bv(gl.funcs, C.GLuint(index), (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4Nusv.xml
+func (gl *GL) VertexAttrib4Nusv(index glbase.Attrib, v []uint16) {
+ C.gl4_3compat_glVertexAttrib4Nusv(gl.funcs, C.GLuint(index), (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4Nuiv.xml
+func (gl *GL) VertexAttrib4Nuiv(index glbase.Attrib, v []uint32) {
+ C.gl4_3compat_glVertexAttrib4Nuiv(gl.funcs, C.GLuint(index), (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4Nubv.xml
+func (gl *GL) VertexAttrib4Nubv(index glbase.Attrib, v []uint8) {
+ C.gl4_3compat_glVertexAttrib4Nubv(gl.funcs, C.GLuint(index), (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4Nub.xml
+func (gl *GL) VertexAttrib4Nub(index glbase.Attrib, x, y, z, w uint8) {
+ C.gl4_3compat_glVertexAttrib4Nub(gl.funcs, C.GLuint(index), C.GLubyte(x), C.GLubyte(y), C.GLubyte(z), C.GLubyte(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4Nsv.xml
+func (gl *GL) VertexAttrib4Nsv(index glbase.Attrib, v []int16) {
+ C.gl4_3compat_glVertexAttrib4Nsv(gl.funcs, C.GLuint(index), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4Niv.xml
+func (gl *GL) VertexAttrib4Niv(index glbase.Attrib, v []int32) {
+ C.gl4_3compat_glVertexAttrib4Niv(gl.funcs, C.GLuint(index), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib4Nbv.xml
+func (gl *GL) VertexAttrib4Nbv(index glbase.Attrib, v []byte) {
+ C.gl4_3compat_glVertexAttrib4Nbv(gl.funcs, C.GLuint(index), (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib3sv.xml
+func (gl *GL) VertexAttrib3sv(index glbase.Attrib, v []int16) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glVertexAttrib3sv(gl.funcs, C.GLuint(index), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib3s.xml
+func (gl *GL) VertexAttrib3s(index glbase.Attrib, x, y, z int16) {
+ C.gl4_3compat_glVertexAttrib3s(gl.funcs, C.GLuint(index), C.GLshort(x), C.GLshort(y), C.GLshort(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib3fv.xml
+func (gl *GL) VertexAttrib3fv(index glbase.Attrib, v []float32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glVertexAttrib3fv(gl.funcs, C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib3f.xml
+func (gl *GL) VertexAttrib3f(index glbase.Attrib, x, y, z float32) {
+ C.gl4_3compat_glVertexAttrib3f(gl.funcs, C.GLuint(index), C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib3dv.xml
+func (gl *GL) VertexAttrib3dv(index glbase.Attrib, v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glVertexAttrib3dv(gl.funcs, C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib3d.xml
+func (gl *GL) VertexAttrib3d(index glbase.Attrib, x, y, z float64) {
+ C.gl4_3compat_glVertexAttrib3d(gl.funcs, C.GLuint(index), C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib2sv.xml
+func (gl *GL) VertexAttrib2sv(index glbase.Attrib, v []int16) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glVertexAttrib2sv(gl.funcs, C.GLuint(index), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib2s.xml
+func (gl *GL) VertexAttrib2s(index glbase.Attrib, x, y int16) {
+ C.gl4_3compat_glVertexAttrib2s(gl.funcs, C.GLuint(index), C.GLshort(x), C.GLshort(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib2fv.xml
+func (gl *GL) VertexAttrib2fv(index glbase.Attrib, v []float32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glVertexAttrib2fv(gl.funcs, C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib2f.xml
+func (gl *GL) VertexAttrib2f(index glbase.Attrib, x, y float32) {
+ C.gl4_3compat_glVertexAttrib2f(gl.funcs, C.GLuint(index), C.GLfloat(x), C.GLfloat(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib2dv.xml
+func (gl *GL) VertexAttrib2dv(index glbase.Attrib, v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glVertexAttrib2dv(gl.funcs, C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib2d.xml
+func (gl *GL) VertexAttrib2d(index glbase.Attrib, x, y float64) {
+ C.gl4_3compat_glVertexAttrib2d(gl.funcs, C.GLuint(index), C.GLdouble(x), C.GLdouble(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib1sv.xml
+func (gl *GL) VertexAttrib1sv(index glbase.Attrib, v []int16) {
+ C.gl4_3compat_glVertexAttrib1sv(gl.funcs, C.GLuint(index), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib1s.xml
+func (gl *GL) VertexAttrib1s(index glbase.Attrib, x int16) {
+ C.gl4_3compat_glVertexAttrib1s(gl.funcs, C.GLuint(index), C.GLshort(x))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib1fv.xml
+func (gl *GL) VertexAttrib1fv(index glbase.Attrib, v []float32) {
+ C.gl4_3compat_glVertexAttrib1fv(gl.funcs, C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib1f.xml
+func (gl *GL) VertexAttrib1f(index glbase.Attrib, x float32) {
+ C.gl4_3compat_glVertexAttrib1f(gl.funcs, C.GLuint(index), C.GLfloat(x))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib1dv.xml
+func (gl *GL) VertexAttrib1dv(index glbase.Attrib, v []float64) {
+ C.gl4_3compat_glVertexAttrib1dv(gl.funcs, C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttrib1d.xml
+func (gl *GL) VertexAttrib1d(index glbase.Attrib, x float64) {
+ C.gl4_3compat_glVertexAttrib1d(gl.funcs, C.GLuint(index), C.GLdouble(x))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI4usv.xml
+func (gl *GL) VertexAttribI4usv(index glbase.Attrib, v []uint16) {
+ C.gl4_3compat_glVertexAttribI4usv(gl.funcs, C.GLuint(index), (*C.GLushort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI4ubv.xml
+func (gl *GL) VertexAttribI4ubv(index glbase.Attrib, v []uint8) {
+ C.gl4_3compat_glVertexAttribI4ubv(gl.funcs, C.GLuint(index), (*C.GLubyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI4sv.xml
+func (gl *GL) VertexAttribI4sv(index glbase.Attrib, v []int16) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glVertexAttribI4sv(gl.funcs, C.GLuint(index), (*C.GLshort)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI4bv.xml
+func (gl *GL) VertexAttribI4bv(index glbase.Attrib, v []byte) {
+ C.gl4_3compat_glVertexAttribI4bv(gl.funcs, C.GLuint(index), (*C.GLbyte)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI4uiv.xml
+func (gl *GL) VertexAttribI4uiv(index glbase.Attrib, v []uint32) {
+ C.gl4_3compat_glVertexAttribI4uiv(gl.funcs, C.GLuint(index), (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI3uiv.xml
+func (gl *GL) VertexAttribI3uiv(index glbase.Attrib, v []uint32) {
+ C.gl4_3compat_glVertexAttribI3uiv(gl.funcs, C.GLuint(index), (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI2uiv.xml
+func (gl *GL) VertexAttribI2uiv(index glbase.Attrib, v []uint32) {
+ C.gl4_3compat_glVertexAttribI2uiv(gl.funcs, C.GLuint(index), (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI1uiv.xml
+func (gl *GL) VertexAttribI1uiv(index glbase.Attrib, v []uint32) {
+ C.gl4_3compat_glVertexAttribI1uiv(gl.funcs, C.GLuint(index), (*C.GLuint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI4iv.xml
+func (gl *GL) VertexAttribI4iv(index glbase.Attrib, v []int32) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glVertexAttribI4iv(gl.funcs, C.GLuint(index), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI3iv.xml
+func (gl *GL) VertexAttribI3iv(index glbase.Attrib, v []int32) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glVertexAttribI3iv(gl.funcs, C.GLuint(index), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI2iv.xml
+func (gl *GL) VertexAttribI2iv(index glbase.Attrib, v []int32) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3compat_glVertexAttribI2iv(gl.funcs, C.GLuint(index), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI1iv.xml
+func (gl *GL) VertexAttribI1iv(index glbase.Attrib, v []int32) {
+ C.gl4_3compat_glVertexAttribI1iv(gl.funcs, C.GLuint(index), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI4ui.xml
+func (gl *GL) VertexAttribI4ui(index glbase.Attrib, x, y, z, w uint32) {
+ C.gl4_3compat_glVertexAttribI4ui(gl.funcs, C.GLuint(index), C.GLuint(x), C.GLuint(y), C.GLuint(z), C.GLuint(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI3ui.xml
+func (gl *GL) VertexAttribI3ui(index glbase.Attrib, x, y, z uint32) {
+ C.gl4_3compat_glVertexAttribI3ui(gl.funcs, C.GLuint(index), C.GLuint(x), C.GLuint(y), C.GLuint(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI2ui.xml
+func (gl *GL) VertexAttribI2ui(index glbase.Attrib, x, y uint32) {
+ C.gl4_3compat_glVertexAttribI2ui(gl.funcs, C.GLuint(index), C.GLuint(x), C.GLuint(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI1ui.xml
+func (gl *GL) VertexAttribI1ui(index glbase.Attrib, x uint32) {
+ C.gl4_3compat_glVertexAttribI1ui(gl.funcs, C.GLuint(index), C.GLuint(x))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI4i.xml
+func (gl *GL) VertexAttribI4i(index glbase.Attrib, x, y, z, w int) {
+ C.gl4_3compat_glVertexAttribI4i(gl.funcs, C.GLuint(index), C.GLint(x), C.GLint(y), C.GLint(z), C.GLint(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI3i.xml
+func (gl *GL) VertexAttribI3i(index glbase.Attrib, x, y, z int) {
+ C.gl4_3compat_glVertexAttribI3i(gl.funcs, C.GLuint(index), C.GLint(x), C.GLint(y), C.GLint(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI2i.xml
+func (gl *GL) VertexAttribI2i(index glbase.Attrib, x, y int) {
+ C.gl4_3compat_glVertexAttribI2i(gl.funcs, C.GLuint(index), C.GLint(x), C.GLint(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribI1i.xml
+func (gl *GL) VertexAttribI1i(index glbase.Attrib, x int) {
+ C.gl4_3compat_glVertexAttribI1i(gl.funcs, C.GLuint(index), C.GLint(x))
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.3core/funcs.cpp b/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.3core/funcs.cpp
new file mode 100644
index 000000000..fec3ebd31
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.3core/funcs.cpp
@@ -0,0 +1,2946 @@
+
+// ** file automatically generated by glgen -- do not edit manually **
+
+#include <QOpenGLContext>
+#include <QtGui/qopenglfunctions_4_3_core.h>
+
+#include "funcs.h"
+
+void *gl4_3core_funcs() {
+ QOpenGLFunctions_4_3_Core* funcs = QOpenGLContext::currentContext()->versionFunctions<QOpenGLFunctions_4_3_Core>();
+ if (!funcs) {
+ return 0;
+ }
+ funcs->initializeOpenGLFunctions();
+ return funcs;
+}
+
+
+void gl4_3core_glViewport(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glViewport(x, y, width, height);
+}
+
+void gl4_3core_glDepthRange(void *_glfuncs, GLdouble nearVal, GLdouble farVal)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glDepthRange(nearVal, farVal);
+}
+
+GLboolean gl4_3core_glIsEnabled(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ return _qglfuncs->glIsEnabled(cap);
+}
+
+void gl4_3core_glGetTexLevelParameteriv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetTexLevelParameteriv(target, level, pname, params);
+}
+
+void gl4_3core_glGetTexLevelParameterfv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetTexLevelParameterfv(target, level, pname, params);
+}
+
+void gl4_3core_glGetTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetTexParameteriv(target, pname, params);
+}
+
+void gl4_3core_glGetTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetTexParameterfv(target, pname, params);
+}
+
+void gl4_3core_glGetTexImage(void *_glfuncs, GLenum target, GLint level, GLenum format, GLenum gltype, GLvoid* pixels)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetTexImage(target, level, format, gltype, pixels);
+}
+
+void gl4_3core_glGetIntegerv(void *_glfuncs, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetIntegerv(pname, params);
+}
+
+void gl4_3core_glGetFloatv(void *_glfuncs, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetFloatv(pname, params);
+}
+
+GLenum gl4_3core_glGetError(void *_glfuncs)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ return _qglfuncs->glGetError();
+}
+
+void gl4_3core_glGetDoublev(void *_glfuncs, GLenum pname, GLdouble* params)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetDoublev(pname, params);
+}
+
+void gl4_3core_glGetBooleanv(void *_glfuncs, GLenum pname, GLboolean* params)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetBooleanv(pname, params);
+}
+
+void gl4_3core_glReadPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum gltype, GLvoid* pixels)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glReadPixels(x, y, width, height, format, gltype, pixels);
+}
+
+void gl4_3core_glReadBuffer(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glReadBuffer(mode);
+}
+
+void gl4_3core_glPixelStorei(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glPixelStorei(pname, param);
+}
+
+void gl4_3core_glPixelStoref(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glPixelStoref(pname, param);
+}
+
+void gl4_3core_glDepthFunc(void *_glfuncs, GLenum glfunc)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glDepthFunc(glfunc);
+}
+
+void gl4_3core_glStencilOp(void *_glfuncs, GLenum fail, GLenum zfail, GLenum zpass)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glStencilOp(fail, zfail, zpass);
+}
+
+void gl4_3core_glStencilFunc(void *_glfuncs, GLenum glfunc, GLint ref, GLuint mask)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glStencilFunc(glfunc, ref, mask);
+}
+
+void gl4_3core_glLogicOp(void *_glfuncs, GLenum opcode)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glLogicOp(opcode);
+}
+
+void gl4_3core_glBlendFunc(void *_glfuncs, GLenum sfactor, GLenum dfactor)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glBlendFunc(sfactor, dfactor);
+}
+
+void gl4_3core_glFlush(void *_glfuncs)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glFlush();
+}
+
+void gl4_3core_glFinish(void *_glfuncs)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glFinish();
+}
+
+void gl4_3core_glEnable(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glEnable(cap);
+}
+
+void gl4_3core_glDisable(void *_glfuncs, GLenum cap)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glDisable(cap);
+}
+
+void gl4_3core_glDepthMask(void *_glfuncs, GLboolean flag)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glDepthMask(flag);
+}
+
+void gl4_3core_glColorMask(void *_glfuncs, GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glColorMask(red, green, blue, alpha);
+}
+
+void gl4_3core_glStencilMask(void *_glfuncs, GLuint mask)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glStencilMask(mask);
+}
+
+void gl4_3core_glClearDepth(void *_glfuncs, GLdouble depth)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glClearDepth(depth);
+}
+
+void gl4_3core_glClearStencil(void *_glfuncs, GLint s)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glClearStencil(s);
+}
+
+void gl4_3core_glClearColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glClearColor(red, green, blue, alpha);
+}
+
+void gl4_3core_glClear(void *_glfuncs, GLbitfield mask)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glClear(mask);
+}
+
+void gl4_3core_glDrawBuffer(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glDrawBuffer(mode);
+}
+
+void gl4_3core_glTexImage2D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glTexImage2D(target, level, internalFormat, width, height, border, format, gltype, pixels);
+}
+
+void gl4_3core_glTexImage1D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glTexImage1D(target, level, internalFormat, width, border, format, gltype, pixels);
+}
+
+void gl4_3core_glTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glTexParameteriv(target, pname, params);
+}
+
+void gl4_3core_glTexParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glTexParameteri(target, pname, param);
+}
+
+void gl4_3core_glTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glTexParameterfv(target, pname, params);
+}
+
+void gl4_3core_glTexParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glTexParameterf(target, pname, param);
+}
+
+void gl4_3core_glScissor(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glScissor(x, y, width, height);
+}
+
+void gl4_3core_glPolygonMode(void *_glfuncs, GLenum face, GLenum mode)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glPolygonMode(face, mode);
+}
+
+void gl4_3core_glPointSize(void *_glfuncs, GLfloat size)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glPointSize(size);
+}
+
+void gl4_3core_glLineWidth(void *_glfuncs, GLfloat width)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glLineWidth(width);
+}
+
+void gl4_3core_glHint(void *_glfuncs, GLenum target, GLenum mode)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glHint(target, mode);
+}
+
+void gl4_3core_glFrontFace(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glFrontFace(mode);
+}
+
+void gl4_3core_glCullFace(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glCullFace(mode);
+}
+
+void gl4_3core_glIndexubv(void *_glfuncs, const GLubyte* c)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glIndexubv(c);
+}
+
+void gl4_3core_glIndexub(void *_glfuncs, GLubyte c)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glIndexub(c);
+}
+
+GLboolean gl4_3core_glIsTexture(void *_glfuncs, GLuint texture)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ return _qglfuncs->glIsTexture(texture);
+}
+
+void gl4_3core_glGenTextures(void *_glfuncs, GLsizei n, GLuint* textures)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGenTextures(n, textures);
+}
+
+void gl4_3core_glDeleteTextures(void *_glfuncs, GLsizei n, const GLuint* textures)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glDeleteTextures(n, textures);
+}
+
+void gl4_3core_glBindTexture(void *_glfuncs, GLenum target, GLuint texture)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glBindTexture(target, texture);
+}
+
+void gl4_3core_glTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glTexSubImage2D(target, level, xoffset, yoffset, width, height, format, gltype, pixels);
+}
+
+void gl4_3core_glTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glTexSubImage1D(target, level, xoffset, width, format, gltype, pixels);
+}
+
+void gl4_3core_glCopyTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage2D(target, level, xoffset, yoffset, x, y, width, height);
+}
+
+void gl4_3core_glCopyTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage1D(target, level, xoffset, x, y, width);
+}
+
+void gl4_3core_glCopyTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glCopyTexImage2D(target, level, internalFormat, x, y, width, height, border);
+}
+
+void gl4_3core_glCopyTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLint border)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glCopyTexImage1D(target, level, internalFormat, x, y, width, border);
+}
+
+void gl4_3core_glPolygonOffset(void *_glfuncs, GLfloat factor, GLfloat units)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glPolygonOffset(factor, units);
+}
+
+void gl4_3core_glDrawElements(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glDrawElements(mode, count, gltype, indices);
+}
+
+void gl4_3core_glDrawArrays(void *_glfuncs, GLenum mode, GLint first, GLsizei count)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glDrawArrays(mode, first, count);
+}
+
+void gl4_3core_glCopyTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glCopyTexSubImage3D(target, level, xoffset, yoffset, zoffset, x, y, width, height);
+}
+
+void gl4_3core_glTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glTexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, gltype, pixels);
+}
+
+void gl4_3core_glTexImage3D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glTexImage3D(target, level, internalFormat, width, height, depth, border, format, gltype, pixels);
+}
+
+void gl4_3core_glDrawRangeElements(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glDrawRangeElements(mode, start, end, count, gltype, indices);
+}
+
+void gl4_3core_glBlendEquation(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glBlendEquation(mode);
+}
+
+void gl4_3core_glBlendColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glBlendColor(red, green, blue, alpha);
+}
+
+void gl4_3core_glGetCompressedTexImage(void *_glfuncs, GLenum target, GLint level, GLvoid* img)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetCompressedTexImage(target, level, img);
+}
+
+void gl4_3core_glCompressedTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glCompressedTexSubImage1D(target, level, xoffset, width, format, imageSize, data);
+}
+
+void gl4_3core_glCompressedTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glCompressedTexSubImage2D(target, level, xoffset, yoffset, width, height, format, imageSize, data);
+}
+
+void gl4_3core_glCompressedTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glCompressedTexSubImage3D(target, level, xoffset, yoffset, zoffset, width, height, depth, format, imageSize, data);
+}
+
+void gl4_3core_glCompressedTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glCompressedTexImage1D(target, level, internalFormat, width, border, imageSize, data);
+}
+
+void gl4_3core_glCompressedTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glCompressedTexImage2D(target, level, internalFormat, width, height, border, imageSize, data);
+}
+
+void gl4_3core_glCompressedTexImage3D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glCompressedTexImage3D(target, level, internalFormat, width, height, depth, border, imageSize, data);
+}
+
+void gl4_3core_glSampleCoverage(void *_glfuncs, GLfloat value, GLboolean invert)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glSampleCoverage(value, invert);
+}
+
+void gl4_3core_glActiveTexture(void *_glfuncs, GLenum texture)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glActiveTexture(texture);
+}
+
+void gl4_3core_glPointParameteriv(void *_glfuncs, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glPointParameteriv(pname, params);
+}
+
+void gl4_3core_glPointParameteri(void *_glfuncs, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glPointParameteri(pname, param);
+}
+
+void gl4_3core_glPointParameterfv(void *_glfuncs, GLenum pname, const GLfloat* params)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glPointParameterfv(pname, params);
+}
+
+void gl4_3core_glPointParameterf(void *_glfuncs, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glPointParameterf(pname, param);
+}
+
+void gl4_3core_glMultiDrawArrays(void *_glfuncs, GLenum mode, const GLint* first, const GLsizei* count, GLsizei drawcount)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glMultiDrawArrays(mode, first, count, drawcount);
+}
+
+void gl4_3core_glBlendFuncSeparate(void *_glfuncs, GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glBlendFuncSeparate(sfactorRGB, dfactorRGB, sfactorAlpha, dfactorAlpha);
+}
+
+void gl4_3core_glGetBufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetBufferParameteriv(target, pname, params);
+}
+
+GLboolean gl4_3core_glUnmapBuffer(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ return _qglfuncs->glUnmapBuffer(target);
+}
+
+void gl4_3core_glGetBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, GLvoid* data)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetBufferSubData(target, offset, size, data);
+}
+
+void gl4_3core_glBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid* data)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glBufferSubData(target, offset, size, data);
+}
+
+void gl4_3core_glBufferData(void *_glfuncs, GLenum target, GLsizeiptr size, const GLvoid* data, GLenum usage)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glBufferData(target, size, data, usage);
+}
+
+GLboolean gl4_3core_glIsBuffer(void *_glfuncs, GLuint buffer)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ return _qglfuncs->glIsBuffer(buffer);
+}
+
+void gl4_3core_glGenBuffers(void *_glfuncs, GLsizei n, GLuint* buffers)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGenBuffers(n, buffers);
+}
+
+void gl4_3core_glDeleteBuffers(void *_glfuncs, GLsizei n, const GLuint* buffers)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glDeleteBuffers(n, buffers);
+}
+
+void gl4_3core_glBindBuffer(void *_glfuncs, GLenum target, GLuint buffer)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glBindBuffer(target, buffer);
+}
+
+void gl4_3core_glGetQueryObjectuiv(void *_glfuncs, GLuint id, GLenum pname, GLuint* params)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetQueryObjectuiv(id, pname, params);
+}
+
+void gl4_3core_glGetQueryObjectiv(void *_glfuncs, GLuint id, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetQueryObjectiv(id, pname, params);
+}
+
+void gl4_3core_glGetQueryiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetQueryiv(target, pname, params);
+}
+
+void gl4_3core_glEndQuery(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glEndQuery(target);
+}
+
+void gl4_3core_glBeginQuery(void *_glfuncs, GLenum target, GLuint id)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glBeginQuery(target, id);
+}
+
+GLboolean gl4_3core_glIsQuery(void *_glfuncs, GLuint id)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ return _qglfuncs->glIsQuery(id);
+}
+
+void gl4_3core_glDeleteQueries(void *_glfuncs, GLsizei n, const GLuint* ids)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glDeleteQueries(n, ids);
+}
+
+void gl4_3core_glGenQueries(void *_glfuncs, GLsizei n, GLuint* ids)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGenQueries(n, ids);
+}
+
+void gl4_3core_glVertexAttribPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLboolean normalized, GLsizei stride, const GLvoid* offset)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribPointer(index, size, gltype, normalized, stride, offset);
+}
+
+void gl4_3core_glValidateProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glValidateProgram(program);
+}
+
+void gl4_3core_glUniformMatrix4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4fv(location, count, transpose, value);
+}
+
+void gl4_3core_glUniformMatrix3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3fv(location, count, transpose, value);
+}
+
+void gl4_3core_glUniformMatrix2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2fv(location, count, transpose, value);
+}
+
+void gl4_3core_glUniform4iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glUniform4iv(location, count, value);
+}
+
+void gl4_3core_glUniform3iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glUniform3iv(location, count, value);
+}
+
+void gl4_3core_glUniform2iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glUniform2iv(location, count, value);
+}
+
+void gl4_3core_glUniform1iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glUniform1iv(location, count, value);
+}
+
+void gl4_3core_glUniform4fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glUniform4fv(location, count, value);
+}
+
+void gl4_3core_glUniform3fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glUniform3fv(location, count, value);
+}
+
+void gl4_3core_glUniform2fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glUniform2fv(location, count, value);
+}
+
+void gl4_3core_glUniform1fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glUniform1fv(location, count, value);
+}
+
+void gl4_3core_glUniform4i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2, GLint v3)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glUniform4i(location, v0, v1, v2, v3);
+}
+
+void gl4_3core_glUniform3i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glUniform3i(location, v0, v1, v2);
+}
+
+void gl4_3core_glUniform2i(void *_glfuncs, GLint location, GLint v0, GLint v1)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glUniform2i(location, v0, v1);
+}
+
+void gl4_3core_glUniform1i(void *_glfuncs, GLint location, GLint v0)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glUniform1i(location, v0);
+}
+
+void gl4_3core_glUniform4f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glUniform4f(location, v0, v1, v2, v3);
+}
+
+void gl4_3core_glUniform3f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glUniform3f(location, v0, v1, v2);
+}
+
+void gl4_3core_glUniform2f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glUniform2f(location, v0, v1);
+}
+
+void gl4_3core_glUniform1f(void *_glfuncs, GLint location, GLfloat v0)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glUniform1f(location, v0);
+}
+
+void gl4_3core_glUseProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glUseProgram(program);
+}
+
+void gl4_3core_glShaderSource(void *_glfuncs, GLuint shader, GLsizei count, const GLchar** source, const GLint* length)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glShaderSource(shader, count, source, length);
+}
+
+void gl4_3core_glLinkProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glLinkProgram(program);
+}
+
+GLboolean gl4_3core_glIsShader(void *_glfuncs, GLuint shader)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ return _qglfuncs->glIsShader(shader);
+}
+
+GLboolean gl4_3core_glIsProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ return _qglfuncs->glIsProgram(program);
+}
+
+void gl4_3core_glGetVertexAttribiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribiv(index, pname, params);
+}
+
+void gl4_3core_glGetVertexAttribfv(void *_glfuncs, GLuint index, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribfv(index, pname, params);
+}
+
+void gl4_3core_glGetVertexAttribdv(void *_glfuncs, GLuint index, GLenum pname, GLdouble* params)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribdv(index, pname, params);
+}
+
+void gl4_3core_glGetUniformiv(void *_glfuncs, GLuint program, GLint location, GLint* params)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetUniformiv(program, location, params);
+}
+
+void gl4_3core_glGetUniformfv(void *_glfuncs, GLuint program, GLint location, GLfloat* params)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetUniformfv(program, location, params);
+}
+
+GLint gl4_3core_glGetUniformLocation(void *_glfuncs, GLuint program, const GLchar* name)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ return _qglfuncs->glGetUniformLocation(program, name);
+}
+
+void gl4_3core_glGetShaderSource(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* source)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetShaderSource(shader, bufSize, length, source);
+}
+
+void gl4_3core_glGetShaderInfoLog(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* infoLog)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetShaderInfoLog(shader, bufSize, length, infoLog);
+}
+
+void gl4_3core_glGetShaderiv(void *_glfuncs, GLuint shader, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetShaderiv(shader, pname, params);
+}
+
+void gl4_3core_glGetProgramInfoLog(void *_glfuncs, GLuint program, GLsizei bufSize, GLsizei* length, GLchar* infoLog)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetProgramInfoLog(program, bufSize, length, infoLog);
+}
+
+void gl4_3core_glGetProgramiv(void *_glfuncs, GLuint program, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetProgramiv(program, pname, params);
+}
+
+GLint gl4_3core_glGetAttribLocation(void *_glfuncs, GLuint program, const GLchar* name)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ return _qglfuncs->glGetAttribLocation(program, name);
+}
+
+void gl4_3core_glGetAttachedShaders(void *_glfuncs, GLuint program, GLsizei maxCount, GLsizei* count, GLuint* obj)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetAttachedShaders(program, maxCount, count, obj);
+}
+
+void gl4_3core_glGetActiveUniform(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetActiveUniform(program, index, bufSize, length, size, gltype, name);
+}
+
+void gl4_3core_glGetActiveAttrib(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetActiveAttrib(program, index, bufSize, length, size, gltype, name);
+}
+
+void gl4_3core_glEnableVertexAttribArray(void *_glfuncs, GLuint index)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glEnableVertexAttribArray(index);
+}
+
+void gl4_3core_glDisableVertexAttribArray(void *_glfuncs, GLuint index)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glDisableVertexAttribArray(index);
+}
+
+void gl4_3core_glDetachShader(void *_glfuncs, GLuint program, GLuint shader)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glDetachShader(program, shader);
+}
+
+void gl4_3core_glDeleteShader(void *_glfuncs, GLuint shader)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glDeleteShader(shader);
+}
+
+void gl4_3core_glDeleteProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glDeleteProgram(program);
+}
+
+GLuint gl4_3core_glCreateShader(void *_glfuncs, GLenum gltype)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ return _qglfuncs->glCreateShader(gltype);
+}
+
+GLuint gl4_3core_glCreateProgram(void *_glfuncs)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ return _qglfuncs->glCreateProgram();
+}
+
+void gl4_3core_glCompileShader(void *_glfuncs, GLuint shader)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glCompileShader(shader);
+}
+
+void gl4_3core_glBindAttribLocation(void *_glfuncs, GLuint program, GLuint index, const GLchar* name)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glBindAttribLocation(program, index, name);
+}
+
+void gl4_3core_glAttachShader(void *_glfuncs, GLuint program, GLuint shader)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glAttachShader(program, shader);
+}
+
+void gl4_3core_glStencilMaskSeparate(void *_glfuncs, GLenum face, GLuint mask)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glStencilMaskSeparate(face, mask);
+}
+
+void gl4_3core_glStencilFuncSeparate(void *_glfuncs, GLenum face, GLenum glfunc, GLint ref, GLuint mask)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glStencilFuncSeparate(face, glfunc, ref, mask);
+}
+
+void gl4_3core_glStencilOpSeparate(void *_glfuncs, GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glStencilOpSeparate(face, sfail, dpfail, dppass);
+}
+
+void gl4_3core_glDrawBuffers(void *_glfuncs, GLsizei n, const GLenum* bufs)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glDrawBuffers(n, bufs);
+}
+
+void gl4_3core_glBlendEquationSeparate(void *_glfuncs, GLenum modeRGB, GLenum modeAlpha)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glBlendEquationSeparate(modeRGB, modeAlpha);
+}
+
+void gl4_3core_glUniformMatrix4x3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4x3fv(location, count, transpose, value);
+}
+
+void gl4_3core_glUniformMatrix3x4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3x4fv(location, count, transpose, value);
+}
+
+void gl4_3core_glUniformMatrix4x2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4x2fv(location, count, transpose, value);
+}
+
+void gl4_3core_glUniformMatrix2x4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2x4fv(location, count, transpose, value);
+}
+
+void gl4_3core_glUniformMatrix3x2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3x2fv(location, count, transpose, value);
+}
+
+void gl4_3core_glUniformMatrix2x3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2x3fv(location, count, transpose, value);
+}
+
+GLboolean gl4_3core_glIsVertexArray(void *_glfuncs, GLuint array)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ return _qglfuncs->glIsVertexArray(array);
+}
+
+void gl4_3core_glGenVertexArrays(void *_glfuncs, GLsizei n, GLuint* arrays)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGenVertexArrays(n, arrays);
+}
+
+void gl4_3core_glDeleteVertexArrays(void *_glfuncs, GLsizei n, const GLuint* arrays)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glDeleteVertexArrays(n, arrays);
+}
+
+void gl4_3core_glBindVertexArray(void *_glfuncs, GLuint array)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glBindVertexArray(array);
+}
+
+void gl4_3core_glFlushMappedBufferRange(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr length)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glFlushMappedBufferRange(target, offset, length);
+}
+
+void gl4_3core_glFramebufferTextureLayer(void *_glfuncs, GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glFramebufferTextureLayer(target, attachment, texture, level, layer);
+}
+
+void gl4_3core_glRenderbufferStorageMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLenum internalFormat, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glRenderbufferStorageMultisample(target, samples, internalFormat, width, height);
+}
+
+void gl4_3core_glBlitFramebuffer(void *_glfuncs, GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glBlitFramebuffer(srcX0, srcY0, srcX1, srcY1, dstX0, dstY0, dstX1, dstY1, mask, filter);
+}
+
+void gl4_3core_glGenerateMipmap(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGenerateMipmap(target);
+}
+
+void gl4_3core_glGetFramebufferAttachmentParameteriv(void *_glfuncs, GLenum target, GLenum attachment, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetFramebufferAttachmentParameteriv(target, attachment, pname, params);
+}
+
+void gl4_3core_glFramebufferRenderbuffer(void *_glfuncs, GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glFramebufferRenderbuffer(target, attachment, renderbuffertarget, renderbuffer);
+}
+
+void gl4_3core_glFramebufferTexture3D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glFramebufferTexture3D(target, attachment, textarget, texture, level, zoffset);
+}
+
+void gl4_3core_glFramebufferTexture2D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glFramebufferTexture2D(target, attachment, textarget, texture, level);
+}
+
+void gl4_3core_glFramebufferTexture1D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glFramebufferTexture1D(target, attachment, textarget, texture, level);
+}
+
+GLenum gl4_3core_glCheckFramebufferStatus(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ return _qglfuncs->glCheckFramebufferStatus(target);
+}
+
+void gl4_3core_glGenFramebuffers(void *_glfuncs, GLsizei n, GLuint* framebuffers)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGenFramebuffers(n, framebuffers);
+}
+
+void gl4_3core_glDeleteFramebuffers(void *_glfuncs, GLsizei n, const GLuint* framebuffers)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glDeleteFramebuffers(n, framebuffers);
+}
+
+void gl4_3core_glBindFramebuffer(void *_glfuncs, GLenum target, GLuint framebuffer)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glBindFramebuffer(target, framebuffer);
+}
+
+GLboolean gl4_3core_glIsFramebuffer(void *_glfuncs, GLuint framebuffer)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ return _qglfuncs->glIsFramebuffer(framebuffer);
+}
+
+void gl4_3core_glGetRenderbufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetRenderbufferParameteriv(target, pname, params);
+}
+
+void gl4_3core_glRenderbufferStorage(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glRenderbufferStorage(target, internalFormat, width, height);
+}
+
+void gl4_3core_glGenRenderbuffers(void *_glfuncs, GLsizei n, GLuint* renderbuffers)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGenRenderbuffers(n, renderbuffers);
+}
+
+void gl4_3core_glDeleteRenderbuffers(void *_glfuncs, GLsizei n, const GLuint* renderbuffers)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glDeleteRenderbuffers(n, renderbuffers);
+}
+
+void gl4_3core_glBindRenderbuffer(void *_glfuncs, GLenum target, GLuint renderbuffer)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glBindRenderbuffer(target, renderbuffer);
+}
+
+GLboolean gl4_3core_glIsRenderbuffer(void *_glfuncs, GLuint renderbuffer)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ return _qglfuncs->glIsRenderbuffer(renderbuffer);
+}
+
+void gl4_3core_glClearBufferfi(void *_glfuncs, GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glClearBufferfi(buffer, drawbuffer, depth, stencil);
+}
+
+void gl4_3core_glClearBufferfv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLfloat* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glClearBufferfv(buffer, drawbuffer, value);
+}
+
+void gl4_3core_glClearBufferuiv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLuint* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glClearBufferuiv(buffer, drawbuffer, value);
+}
+
+void gl4_3core_glClearBufferiv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLint* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glClearBufferiv(buffer, drawbuffer, value);
+}
+
+void gl4_3core_glGetTexParameterIuiv(void *_glfuncs, GLenum target, GLenum pname, GLuint* params)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetTexParameterIuiv(target, pname, params);
+}
+
+void gl4_3core_glGetTexParameterIiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetTexParameterIiv(target, pname, params);
+}
+
+void gl4_3core_glTexParameterIuiv(void *_glfuncs, GLenum target, GLenum pname, const GLuint* params)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glTexParameterIuiv(target, pname, params);
+}
+
+void gl4_3core_glTexParameterIiv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glTexParameterIiv(target, pname, params);
+}
+
+void gl4_3core_glUniform4uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glUniform4uiv(location, count, value);
+}
+
+void gl4_3core_glUniform3uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glUniform3uiv(location, count, value);
+}
+
+void gl4_3core_glUniform2uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glUniform2uiv(location, count, value);
+}
+
+void gl4_3core_glUniform1uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glUniform1uiv(location, count, value);
+}
+
+void gl4_3core_glUniform4ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glUniform4ui(location, v0, v1, v2, v3);
+}
+
+void gl4_3core_glUniform3ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1, GLuint v2)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glUniform3ui(location, v0, v1, v2);
+}
+
+void gl4_3core_glUniform2ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glUniform2ui(location, v0, v1);
+}
+
+void gl4_3core_glUniform1ui(void *_glfuncs, GLint location, GLuint v0)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glUniform1ui(location, v0);
+}
+
+GLint gl4_3core_glGetFragDataLocation(void *_glfuncs, GLuint program, const GLchar* name)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ return _qglfuncs->glGetFragDataLocation(program, name);
+}
+
+void gl4_3core_glBindFragDataLocation(void *_glfuncs, GLuint program, GLuint color, const GLchar* name)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glBindFragDataLocation(program, color, name);
+}
+
+void gl4_3core_glGetUniformuiv(void *_glfuncs, GLuint program, GLint location, GLuint* params)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetUniformuiv(program, location, params);
+}
+
+void gl4_3core_glGetVertexAttribIuiv(void *_glfuncs, GLuint index, GLenum pname, GLuint* params)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribIuiv(index, pname, params);
+}
+
+void gl4_3core_glGetVertexAttribIiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribIiv(index, pname, params);
+}
+
+void gl4_3core_glVertexAttribIPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribIPointer(index, size, gltype, stride, pointer);
+}
+
+void gl4_3core_glEndConditionalRender(void *_glfuncs)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glEndConditionalRender();
+}
+
+void gl4_3core_glBeginConditionalRender(void *_glfuncs, GLuint id, GLenum mode)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glBeginConditionalRender(id, mode);
+}
+
+void gl4_3core_glClampColor(void *_glfuncs, GLenum target, GLenum clamp)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glClampColor(target, clamp);
+}
+
+void gl4_3core_glGetTransformFeedbackVarying(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLsizei* size, GLenum* gltype, GLchar* name)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetTransformFeedbackVarying(program, index, bufSize, length, size, gltype, name);
+}
+
+void gl4_3core_glBindBufferBase(void *_glfuncs, GLenum target, GLuint index, GLuint buffer)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glBindBufferBase(target, index, buffer);
+}
+
+void gl4_3core_glBindBufferRange(void *_glfuncs, GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glBindBufferRange(target, index, buffer, offset, size);
+}
+
+void gl4_3core_glEndTransformFeedback(void *_glfuncs)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glEndTransformFeedback();
+}
+
+void gl4_3core_glBeginTransformFeedback(void *_glfuncs, GLenum primitiveMode)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glBeginTransformFeedback(primitiveMode);
+}
+
+GLboolean gl4_3core_glIsEnabledi(void *_glfuncs, GLenum target, GLuint index)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ return _qglfuncs->glIsEnabledi(target, index);
+}
+
+void gl4_3core_glDisablei(void *_glfuncs, GLenum target, GLuint index)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glDisablei(target, index);
+}
+
+void gl4_3core_glEnablei(void *_glfuncs, GLenum target, GLuint index)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glEnablei(target, index);
+}
+
+void gl4_3core_glGetIntegeri_v(void *_glfuncs, GLenum target, GLuint index, GLint* data)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetIntegeri_v(target, index, data);
+}
+
+void gl4_3core_glGetBooleani_v(void *_glfuncs, GLenum target, GLuint index, GLboolean* data)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetBooleani_v(target, index, data);
+}
+
+void gl4_3core_glColorMaski(void *_glfuncs, GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glColorMaski(index, r, g, b, a);
+}
+
+void gl4_3core_glCopyBufferSubData(void *_glfuncs, GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glCopyBufferSubData(readTarget, writeTarget, readOffset, writeOffset, size);
+}
+
+void gl4_3core_glUniformBlockBinding(void *_glfuncs, GLuint program, GLuint v0, GLuint v1)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glUniformBlockBinding(program, v0, v1);
+}
+
+void gl4_3core_glGetActiveUniformBlockName(void *_glfuncs, GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei* length, GLchar* uniformBlockName)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetActiveUniformBlockName(program, uniformBlockIndex, bufSize, length, uniformBlockName);
+}
+
+void gl4_3core_glGetActiveUniformBlockiv(void *_glfuncs, GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetActiveUniformBlockiv(program, uniformBlockIndex, pname, params);
+}
+
+GLuint gl4_3core_glGetUniformBlockIndex(void *_glfuncs, GLuint program, const GLchar* uniformBlockName)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ return _qglfuncs->glGetUniformBlockIndex(program, uniformBlockName);
+}
+
+void gl4_3core_glGetActiveUniformName(void *_glfuncs, GLuint program, GLuint uniformIndex, GLsizei bufSize, GLsizei* length, GLchar* uniformName)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetActiveUniformName(program, uniformIndex, bufSize, length, uniformName);
+}
+
+void gl4_3core_glGetActiveUniformsiv(void *_glfuncs, GLuint program, GLsizei uniformCount, const GLuint* uniformIndices, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetActiveUniformsiv(program, uniformCount, uniformIndices, pname, params);
+}
+
+void gl4_3core_glPrimitiveRestartIndex(void *_glfuncs, GLuint index)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glPrimitiveRestartIndex(index);
+}
+
+void gl4_3core_glTexBuffer(void *_glfuncs, GLenum target, GLenum internalFormat, GLuint buffer)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glTexBuffer(target, internalFormat, buffer);
+}
+
+void gl4_3core_glDrawElementsInstanced(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glDrawElementsInstanced(mode, count, gltype, indices, instancecount);
+}
+
+void gl4_3core_glDrawArraysInstanced(void *_glfuncs, GLenum mode, GLint first, GLsizei count, GLsizei instancecount)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glDrawArraysInstanced(mode, first, count, instancecount);
+}
+
+void gl4_3core_glSampleMaski(void *_glfuncs, GLuint index, GLbitfield mask)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glSampleMaski(index, mask);
+}
+
+void gl4_3core_glGetMultisamplefv(void *_glfuncs, GLenum pname, GLuint index, GLfloat* val)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetMultisamplefv(pname, index, val);
+}
+
+void gl4_3core_glTexImage3DMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glTexImage3DMultisample(target, samples, internalFormat, width, height, depth, fixedsamplelocations);
+}
+
+void gl4_3core_glTexImage2DMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLint internalFormat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glTexImage2DMultisample(target, samples, internalFormat, width, height, fixedsamplelocations);
+}
+
+void gl4_3core_glGetSynciv(void *_glfuncs, GLsync sync, GLenum pname, GLsizei bufSize, GLsizei* length, GLint* values)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetSynciv(sync, pname, bufSize, length, values);
+}
+
+void gl4_3core_glGetInteger64v(void *_glfuncs, GLenum pname, GLint64* params)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetInteger64v(pname, params);
+}
+
+void gl4_3core_glWaitSync(void *_glfuncs, GLsync sync, GLbitfield flags, GLuint64 timeout)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glWaitSync(sync, flags, timeout);
+}
+
+GLenum gl4_3core_glClientWaitSync(void *_glfuncs, GLsync sync, GLbitfield flags, GLuint64 timeout)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ return _qglfuncs->glClientWaitSync(sync, flags, timeout);
+}
+
+void gl4_3core_glDeleteSync(void *_glfuncs, GLsync sync)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glDeleteSync(sync);
+}
+
+GLboolean gl4_3core_glIsSync(void *_glfuncs, GLsync sync)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ return _qglfuncs->glIsSync(sync);
+}
+
+GLsync gl4_3core_glFenceSync(void *_glfuncs, GLenum condition, GLbitfield flags)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ return _qglfuncs->glFenceSync(condition, flags);
+}
+
+void gl4_3core_glProvokingVertex(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glProvokingVertex(mode);
+}
+
+void gl4_3core_glDrawElementsInstancedBaseVertex(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount, GLint basevertex)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glDrawElementsInstancedBaseVertex(mode, count, gltype, indices, instancecount, basevertex);
+}
+
+void gl4_3core_glDrawRangeElementsBaseVertex(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices, GLint basevertex)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glDrawRangeElementsBaseVertex(mode, start, end, count, gltype, indices, basevertex);
+}
+
+void gl4_3core_glDrawElementsBaseVertex(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLint basevertex)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glDrawElementsBaseVertex(mode, count, gltype, indices, basevertex);
+}
+
+void gl4_3core_glFramebufferTexture(void *_glfuncs, GLenum target, GLenum attachment, GLuint texture, GLint level)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glFramebufferTexture(target, attachment, texture, level);
+}
+
+void gl4_3core_glGetBufferParameteri64v(void *_glfuncs, GLenum target, GLenum pname, GLint64* params)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetBufferParameteri64v(target, pname, params);
+}
+
+void gl4_3core_glGetInteger64i_v(void *_glfuncs, GLenum target, GLuint index, GLint64* data)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetInteger64i_v(target, index, data);
+}
+
+void gl4_3core_glVertexAttribP4uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribP4uiv(index, gltype, normalized, value);
+}
+
+void gl4_3core_glVertexAttribP4ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribP4ui(index, gltype, normalized, value);
+}
+
+void gl4_3core_glVertexAttribP3uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribP3uiv(index, gltype, normalized, value);
+}
+
+void gl4_3core_glVertexAttribP3ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribP3ui(index, gltype, normalized, value);
+}
+
+void gl4_3core_glVertexAttribP2uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribP2uiv(index, gltype, normalized, value);
+}
+
+void gl4_3core_glVertexAttribP2ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribP2ui(index, gltype, normalized, value);
+}
+
+void gl4_3core_glVertexAttribP1uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribP1uiv(index, gltype, normalized, value);
+}
+
+void gl4_3core_glVertexAttribP1ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribP1ui(index, gltype, normalized, value);
+}
+
+void gl4_3core_glSecondaryColorP3uiv(void *_glfuncs, GLenum gltype, const GLuint* color)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glSecondaryColorP3uiv(gltype, color);
+}
+
+void gl4_3core_glSecondaryColorP3ui(void *_glfuncs, GLenum gltype, GLuint color)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glSecondaryColorP3ui(gltype, color);
+}
+
+void gl4_3core_glColorP4uiv(void *_glfuncs, GLenum gltype, const GLuint* color)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glColorP4uiv(gltype, color);
+}
+
+void gl4_3core_glColorP4ui(void *_glfuncs, GLenum gltype, GLuint color)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glColorP4ui(gltype, color);
+}
+
+void gl4_3core_glColorP3uiv(void *_glfuncs, GLenum gltype, const GLuint* color)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glColorP3uiv(gltype, color);
+}
+
+void gl4_3core_glColorP3ui(void *_glfuncs, GLenum gltype, GLuint color)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glColorP3ui(gltype, color);
+}
+
+void gl4_3core_glNormalP3uiv(void *_glfuncs, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glNormalP3uiv(gltype, coords);
+}
+
+void gl4_3core_glNormalP3ui(void *_glfuncs, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glNormalP3ui(gltype, coords);
+}
+
+void gl4_3core_glMultiTexCoordP4uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP4uiv(texture, gltype, coords);
+}
+
+void gl4_3core_glMultiTexCoordP4ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP4ui(texture, gltype, coords);
+}
+
+void gl4_3core_glMultiTexCoordP3uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP3uiv(texture, gltype, coords);
+}
+
+void gl4_3core_glMultiTexCoordP3ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP3ui(texture, gltype, coords);
+}
+
+void gl4_3core_glMultiTexCoordP2uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP2uiv(texture, gltype, coords);
+}
+
+void gl4_3core_glMultiTexCoordP2ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP2ui(texture, gltype, coords);
+}
+
+void gl4_3core_glMultiTexCoordP1uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP1uiv(texture, gltype, coords);
+}
+
+void gl4_3core_glMultiTexCoordP1ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glMultiTexCoordP1ui(texture, gltype, coords);
+}
+
+void gl4_3core_glTexCoordP4uiv(void *_glfuncs, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glTexCoordP4uiv(gltype, coords);
+}
+
+void gl4_3core_glTexCoordP4ui(void *_glfuncs, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glTexCoordP4ui(gltype, coords);
+}
+
+void gl4_3core_glTexCoordP3uiv(void *_glfuncs, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glTexCoordP3uiv(gltype, coords);
+}
+
+void gl4_3core_glTexCoordP3ui(void *_glfuncs, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glTexCoordP3ui(gltype, coords);
+}
+
+void gl4_3core_glTexCoordP2uiv(void *_glfuncs, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glTexCoordP2uiv(gltype, coords);
+}
+
+void gl4_3core_glTexCoordP2ui(void *_glfuncs, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glTexCoordP2ui(gltype, coords);
+}
+
+void gl4_3core_glTexCoordP1uiv(void *_glfuncs, GLenum gltype, const GLuint* coords)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glTexCoordP1uiv(gltype, coords);
+}
+
+void gl4_3core_glTexCoordP1ui(void *_glfuncs, GLenum gltype, GLuint coords)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glTexCoordP1ui(gltype, coords);
+}
+
+void gl4_3core_glVertexP4uiv(void *_glfuncs, GLenum gltype, const GLuint* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glVertexP4uiv(gltype, value);
+}
+
+void gl4_3core_glVertexP4ui(void *_glfuncs, GLenum gltype, GLuint value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glVertexP4ui(gltype, value);
+}
+
+void gl4_3core_glVertexP3uiv(void *_glfuncs, GLenum gltype, const GLuint* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glVertexP3uiv(gltype, value);
+}
+
+void gl4_3core_glVertexP3ui(void *_glfuncs, GLenum gltype, GLuint value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glVertexP3ui(gltype, value);
+}
+
+void gl4_3core_glVertexP2uiv(void *_glfuncs, GLenum gltype, const GLuint* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glVertexP2uiv(gltype, value);
+}
+
+void gl4_3core_glVertexP2ui(void *_glfuncs, GLenum gltype, GLuint value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glVertexP2ui(gltype, value);
+}
+
+void gl4_3core_glGetQueryObjectui64v(void *_glfuncs, GLuint id, GLenum pname, GLuint64* params)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetQueryObjectui64v(id, pname, params);
+}
+
+void gl4_3core_glGetQueryObjecti64v(void *_glfuncs, GLuint id, GLenum pname, GLint64* params)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetQueryObjecti64v(id, pname, params);
+}
+
+void gl4_3core_glQueryCounter(void *_glfuncs, GLuint id, GLenum target)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glQueryCounter(id, target);
+}
+
+void gl4_3core_glGetSamplerParameterIuiv(void *_glfuncs, GLuint sampler, GLenum pname, GLuint* params)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetSamplerParameterIuiv(sampler, pname, params);
+}
+
+void gl4_3core_glGetSamplerParameterfv(void *_glfuncs, GLuint sampler, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetSamplerParameterfv(sampler, pname, params);
+}
+
+void gl4_3core_glGetSamplerParameterIiv(void *_glfuncs, GLuint sampler, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetSamplerParameterIiv(sampler, pname, params);
+}
+
+void gl4_3core_glGetSamplerParameteriv(void *_glfuncs, GLuint sampler, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetSamplerParameteriv(sampler, pname, params);
+}
+
+void gl4_3core_glSamplerParameterIuiv(void *_glfuncs, GLuint sampler, GLenum pname, const GLuint* param)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glSamplerParameterIuiv(sampler, pname, param);
+}
+
+void gl4_3core_glSamplerParameterIiv(void *_glfuncs, GLuint sampler, GLenum pname, const GLint* param)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glSamplerParameterIiv(sampler, pname, param);
+}
+
+void gl4_3core_glSamplerParameterfv(void *_glfuncs, GLuint sampler, GLenum pname, const GLfloat* param)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glSamplerParameterfv(sampler, pname, param);
+}
+
+void gl4_3core_glSamplerParameterf(void *_glfuncs, GLuint sampler, GLenum pname, GLfloat param)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glSamplerParameterf(sampler, pname, param);
+}
+
+void gl4_3core_glSamplerParameteriv(void *_glfuncs, GLuint sampler, GLenum pname, const GLint* param)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glSamplerParameteriv(sampler, pname, param);
+}
+
+void gl4_3core_glSamplerParameteri(void *_glfuncs, GLuint sampler, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glSamplerParameteri(sampler, pname, param);
+}
+
+void gl4_3core_glBindSampler(void *_glfuncs, GLuint unit, GLuint sampler)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glBindSampler(unit, sampler);
+}
+
+GLboolean gl4_3core_glIsSampler(void *_glfuncs, GLuint sampler)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ return _qglfuncs->glIsSampler(sampler);
+}
+
+void gl4_3core_glDeleteSamplers(void *_glfuncs, GLsizei count, const GLuint* samplers)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glDeleteSamplers(count, samplers);
+}
+
+void gl4_3core_glGenSamplers(void *_glfuncs, GLsizei count, GLuint* samplers)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGenSamplers(count, samplers);
+}
+
+GLint gl4_3core_glGetFragDataIndex(void *_glfuncs, GLuint program, const GLchar* name)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ return _qglfuncs->glGetFragDataIndex(program, name);
+}
+
+void gl4_3core_glBindFragDataLocationIndexed(void *_glfuncs, GLuint program, GLuint colorNumber, GLuint index, const GLchar* name)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glBindFragDataLocationIndexed(program, colorNumber, index, name);
+}
+
+void gl4_3core_glVertexAttribDivisor(void *_glfuncs, GLuint index, GLuint divisor)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribDivisor(index, divisor);
+}
+
+void gl4_3core_glGetQueryIndexediv(void *_glfuncs, GLenum target, GLuint index, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetQueryIndexediv(target, index, pname, params);
+}
+
+void gl4_3core_glEndQueryIndexed(void *_glfuncs, GLenum target, GLuint index)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glEndQueryIndexed(target, index);
+}
+
+void gl4_3core_glBeginQueryIndexed(void *_glfuncs, GLenum target, GLuint index, GLuint id)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glBeginQueryIndexed(target, index, id);
+}
+
+void gl4_3core_glDrawTransformFeedbackStream(void *_glfuncs, GLenum mode, GLuint id, GLuint stream)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glDrawTransformFeedbackStream(mode, id, stream);
+}
+
+void gl4_3core_glDrawTransformFeedback(void *_glfuncs, GLenum mode, GLuint id)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glDrawTransformFeedback(mode, id);
+}
+
+void gl4_3core_glResumeTransformFeedback(void *_glfuncs)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glResumeTransformFeedback();
+}
+
+void gl4_3core_glPauseTransformFeedback(void *_glfuncs)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glPauseTransformFeedback();
+}
+
+GLboolean gl4_3core_glIsTransformFeedback(void *_glfuncs, GLuint id)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ return _qglfuncs->glIsTransformFeedback(id);
+}
+
+void gl4_3core_glGenTransformFeedbacks(void *_glfuncs, GLsizei n, GLuint* ids)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGenTransformFeedbacks(n, ids);
+}
+
+void gl4_3core_glDeleteTransformFeedbacks(void *_glfuncs, GLsizei n, const GLuint* ids)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glDeleteTransformFeedbacks(n, ids);
+}
+
+void gl4_3core_glBindTransformFeedback(void *_glfuncs, GLenum target, GLuint id)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glBindTransformFeedback(target, id);
+}
+
+void gl4_3core_glPatchParameterfv(void *_glfuncs, GLenum pname, const GLfloat* values)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glPatchParameterfv(pname, values);
+}
+
+void gl4_3core_glPatchParameteri(void *_glfuncs, GLenum pname, GLint value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glPatchParameteri(pname, value);
+}
+
+void gl4_3core_glGetProgramStageiv(void *_glfuncs, GLuint program, GLenum shadertype, GLenum pname, GLint* values)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetProgramStageiv(program, shadertype, pname, values);
+}
+
+void gl4_3core_glGetUniformSubroutineuiv(void *_glfuncs, GLenum shadertype, GLint location, GLuint* params)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetUniformSubroutineuiv(shadertype, location, params);
+}
+
+void gl4_3core_glUniformSubroutinesuiv(void *_glfuncs, GLenum shadertype, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glUniformSubroutinesuiv(shadertype, count, value);
+}
+
+void gl4_3core_glGetActiveSubroutineName(void *_glfuncs, GLuint program, GLenum shadertype, GLuint index, GLsizei bufSize, GLsizei* length, GLchar* name)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetActiveSubroutineName(program, shadertype, index, bufSize, length, name);
+}
+
+void gl4_3core_glGetActiveSubroutineUniformName(void *_glfuncs, GLuint program, GLenum shadertype, GLuint index, GLsizei bufSize, GLsizei* length, GLchar* name)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetActiveSubroutineUniformName(program, shadertype, index, bufSize, length, name);
+}
+
+void gl4_3core_glGetActiveSubroutineUniformiv(void *_glfuncs, GLuint program, GLenum shadertype, GLuint index, GLenum pname, GLint* values)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetActiveSubroutineUniformiv(program, shadertype, index, pname, values);
+}
+
+GLuint gl4_3core_glGetSubroutineIndex(void *_glfuncs, GLuint program, GLenum shadertype, const GLchar* name)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ return _qglfuncs->glGetSubroutineIndex(program, shadertype, name);
+}
+
+GLint gl4_3core_glGetSubroutineUniformLocation(void *_glfuncs, GLuint program, GLenum shadertype, const GLchar* name)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ return _qglfuncs->glGetSubroutineUniformLocation(program, shadertype, name);
+}
+
+void gl4_3core_glGetUniformdv(void *_glfuncs, GLuint program, GLint location, GLdouble* params)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetUniformdv(program, location, params);
+}
+
+void gl4_3core_glUniformMatrix4x3dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4x3dv(location, count, transpose, value);
+}
+
+void gl4_3core_glUniformMatrix4x2dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4x2dv(location, count, transpose, value);
+}
+
+void gl4_3core_glUniformMatrix3x4dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3x4dv(location, count, transpose, value);
+}
+
+void gl4_3core_glUniformMatrix3x2dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3x2dv(location, count, transpose, value);
+}
+
+void gl4_3core_glUniformMatrix2x4dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2x4dv(location, count, transpose, value);
+}
+
+void gl4_3core_glUniformMatrix2x3dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2x3dv(location, count, transpose, value);
+}
+
+void gl4_3core_glUniformMatrix4dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4dv(location, count, transpose, value);
+}
+
+void gl4_3core_glUniformMatrix3dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3dv(location, count, transpose, value);
+}
+
+void gl4_3core_glUniformMatrix2dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2dv(location, count, transpose, value);
+}
+
+void gl4_3core_glUniform4dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glUniform4dv(location, count, value);
+}
+
+void gl4_3core_glUniform3dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glUniform3dv(location, count, value);
+}
+
+void gl4_3core_glUniform2dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glUniform2dv(location, count, value);
+}
+
+void gl4_3core_glUniform1dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glUniform1dv(location, count, value);
+}
+
+void gl4_3core_glUniform4d(void *_glfuncs, GLint location, GLdouble v0, GLdouble v1, GLdouble v2, GLdouble v3)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glUniform4d(location, v0, v1, v2, v3);
+}
+
+void gl4_3core_glUniform3d(void *_glfuncs, GLint location, GLdouble v0, GLdouble v1, GLdouble v2)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glUniform3d(location, v0, v1, v2);
+}
+
+void gl4_3core_glUniform2d(void *_glfuncs, GLint location, GLdouble v0, GLdouble v1)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glUniform2d(location, v0, v1);
+}
+
+void gl4_3core_glUniform1d(void *_glfuncs, GLint location, GLdouble v0)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glUniform1d(location, v0);
+}
+
+void gl4_3core_glDrawElementsIndirect(void *_glfuncs, GLenum mode, GLenum gltype, const GLvoid* indirect)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glDrawElementsIndirect(mode, gltype, indirect);
+}
+
+void gl4_3core_glDrawArraysIndirect(void *_glfuncs, GLenum mode, const GLvoid* indirect)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glDrawArraysIndirect(mode, indirect);
+}
+
+void gl4_3core_glBlendFuncSeparatei(void *_glfuncs, GLuint buf, GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha, GLenum dstAlpha)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glBlendFuncSeparatei(buf, srcRGB, dstRGB, srcAlpha, dstAlpha);
+}
+
+void gl4_3core_glBlendFunci(void *_glfuncs, GLuint buf, GLenum src, GLenum dst)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glBlendFunci(buf, src, dst);
+}
+
+void gl4_3core_glBlendEquationSeparatei(void *_glfuncs, GLuint buf, GLenum modeRGB, GLenum modeAlpha)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glBlendEquationSeparatei(buf, modeRGB, modeAlpha);
+}
+
+void gl4_3core_glBlendEquationi(void *_glfuncs, GLuint buf, GLenum mode)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glBlendEquationi(buf, mode);
+}
+
+void gl4_3core_glMinSampleShading(void *_glfuncs, GLfloat value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glMinSampleShading(value);
+}
+
+void gl4_3core_glGetDoublei_v(void *_glfuncs, GLenum target, GLuint index, GLdouble* data)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetDoublei_v(target, index, data);
+}
+
+void gl4_3core_glGetFloati_v(void *_glfuncs, GLenum target, GLuint index, GLfloat* data)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetFloati_v(target, index, data);
+}
+
+void gl4_3core_glDepthRangeIndexed(void *_glfuncs, GLuint index, GLdouble n, GLdouble f)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glDepthRangeIndexed(index, n, f);
+}
+
+void gl4_3core_glDepthRangeArrayv(void *_glfuncs, GLuint first, GLsizei count, const GLdouble* v)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glDepthRangeArrayv(first, count, v);
+}
+
+void gl4_3core_glScissorIndexedv(void *_glfuncs, GLuint index, const GLint* v)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glScissorIndexedv(index, v);
+}
+
+void gl4_3core_glScissorIndexed(void *_glfuncs, GLuint index, GLint left, GLint bottom, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glScissorIndexed(index, left, bottom, width, height);
+}
+
+void gl4_3core_glScissorArrayv(void *_glfuncs, GLuint first, GLsizei count, const GLint* v)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glScissorArrayv(first, count, v);
+}
+
+void gl4_3core_glViewportIndexedfv(void *_glfuncs, GLuint index, const GLfloat* v)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glViewportIndexedfv(index, v);
+}
+
+void gl4_3core_glViewportIndexedf(void *_glfuncs, GLuint index, GLfloat x, GLfloat y, GLfloat w, GLfloat h)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glViewportIndexedf(index, x, y, w, h);
+}
+
+void gl4_3core_glViewportArrayv(void *_glfuncs, GLuint first, GLsizei count, const GLfloat* v)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glViewportArrayv(first, count, v);
+}
+
+void gl4_3core_glGetVertexAttribLdv(void *_glfuncs, GLuint index, GLenum pname, GLdouble* params)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribLdv(index, pname, params);
+}
+
+void gl4_3core_glVertexAttribLPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribLPointer(index, size, gltype, stride, pointer);
+}
+
+void gl4_3core_glVertexAttribL4dv(void *_glfuncs, GLuint index, const GLdouble* v)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribL4dv(index, v);
+}
+
+void gl4_3core_glVertexAttribL3dv(void *_glfuncs, GLuint index, const GLdouble* v)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribL3dv(index, v);
+}
+
+void gl4_3core_glVertexAttribL2dv(void *_glfuncs, GLuint index, const GLdouble* v)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribL2dv(index, v);
+}
+
+void gl4_3core_glVertexAttribL1dv(void *_glfuncs, GLuint index, const GLdouble* v)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribL1dv(index, v);
+}
+
+void gl4_3core_glVertexAttribL4d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribL4d(index, x, y, z, w);
+}
+
+void gl4_3core_glVertexAttribL3d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y, GLdouble z)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribL3d(index, x, y, z);
+}
+
+void gl4_3core_glVertexAttribL2d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribL2d(index, x, y);
+}
+
+void gl4_3core_glVertexAttribL1d(void *_glfuncs, GLuint index, GLdouble x)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribL1d(index, x);
+}
+
+void gl4_3core_glGetProgramPipelineInfoLog(void *_glfuncs, GLuint pipeline, GLsizei bufSize, GLsizei* length, GLchar* infoLog)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetProgramPipelineInfoLog(pipeline, bufSize, length, infoLog);
+}
+
+void gl4_3core_glValidateProgramPipeline(void *_glfuncs, GLuint pipeline)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glValidateProgramPipeline(pipeline);
+}
+
+void gl4_3core_glProgramUniformMatrix4x3dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix4x3dv(program, location, count, transpose, value);
+}
+
+void gl4_3core_glProgramUniformMatrix3x4dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix3x4dv(program, location, count, transpose, value);
+}
+
+void gl4_3core_glProgramUniformMatrix4x2dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix4x2dv(program, location, count, transpose, value);
+}
+
+void gl4_3core_glProgramUniformMatrix2x4dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix2x4dv(program, location, count, transpose, value);
+}
+
+void gl4_3core_glProgramUniformMatrix3x2dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix3x2dv(program, location, count, transpose, value);
+}
+
+void gl4_3core_glProgramUniformMatrix2x3dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix2x3dv(program, location, count, transpose, value);
+}
+
+void gl4_3core_glProgramUniformMatrix4x3fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix4x3fv(program, location, count, transpose, value);
+}
+
+void gl4_3core_glProgramUniformMatrix3x4fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix3x4fv(program, location, count, transpose, value);
+}
+
+void gl4_3core_glProgramUniformMatrix4x2fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix4x2fv(program, location, count, transpose, value);
+}
+
+void gl4_3core_glProgramUniformMatrix2x4fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix2x4fv(program, location, count, transpose, value);
+}
+
+void gl4_3core_glProgramUniformMatrix3x2fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix3x2fv(program, location, count, transpose, value);
+}
+
+void gl4_3core_glProgramUniformMatrix2x3fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix2x3fv(program, location, count, transpose, value);
+}
+
+void gl4_3core_glProgramUniformMatrix4dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix4dv(program, location, count, transpose, value);
+}
+
+void gl4_3core_glProgramUniformMatrix3dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix3dv(program, location, count, transpose, value);
+}
+
+void gl4_3core_glProgramUniformMatrix2dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix2dv(program, location, count, transpose, value);
+}
+
+void gl4_3core_glProgramUniformMatrix4fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix4fv(program, location, count, transpose, value);
+}
+
+void gl4_3core_glProgramUniformMatrix3fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix3fv(program, location, count, transpose, value);
+}
+
+void gl4_3core_glProgramUniformMatrix2fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniformMatrix2fv(program, location, count, transpose, value);
+}
+
+void gl4_3core_glProgramUniform4uiv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform4uiv(program, location, count, value);
+}
+
+void gl4_3core_glProgramUniform4ui(void *_glfuncs, GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform4ui(program, location, v0, v1, v2, v3);
+}
+
+void gl4_3core_glProgramUniform4dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLdouble* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform4dv(program, location, count, value);
+}
+
+void gl4_3core_glProgramUniform4d(void *_glfuncs, GLuint program, GLint location, GLdouble v0, GLdouble v1, GLdouble v2, GLdouble v3)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform4d(program, location, v0, v1, v2, v3);
+}
+
+void gl4_3core_glProgramUniform4fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform4fv(program, location, count, value);
+}
+
+void gl4_3core_glProgramUniform4f(void *_glfuncs, GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform4f(program, location, v0, v1, v2, v3);
+}
+
+void gl4_3core_glProgramUniform4iv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform4iv(program, location, count, value);
+}
+
+void gl4_3core_glProgramUniform4i(void *_glfuncs, GLuint program, GLint location, GLint v0, GLint v1, GLint v2, GLint v3)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform4i(program, location, v0, v1, v2, v3);
+}
+
+void gl4_3core_glProgramUniform3uiv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform3uiv(program, location, count, value);
+}
+
+void gl4_3core_glProgramUniform3ui(void *_glfuncs, GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform3ui(program, location, v0, v1, v2);
+}
+
+void gl4_3core_glProgramUniform3dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLdouble* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform3dv(program, location, count, value);
+}
+
+void gl4_3core_glProgramUniform3d(void *_glfuncs, GLuint program, GLint location, GLdouble v0, GLdouble v1, GLdouble v2)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform3d(program, location, v0, v1, v2);
+}
+
+void gl4_3core_glProgramUniform3fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform3fv(program, location, count, value);
+}
+
+void gl4_3core_glProgramUniform3f(void *_glfuncs, GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform3f(program, location, v0, v1, v2);
+}
+
+void gl4_3core_glProgramUniform3iv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform3iv(program, location, count, value);
+}
+
+void gl4_3core_glProgramUniform3i(void *_glfuncs, GLuint program, GLint location, GLint v0, GLint v1, GLint v2)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform3i(program, location, v0, v1, v2);
+}
+
+void gl4_3core_glProgramUniform2uiv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform2uiv(program, location, count, value);
+}
+
+void gl4_3core_glProgramUniform2ui(void *_glfuncs, GLuint program, GLint location, GLuint v0, GLuint v1)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform2ui(program, location, v0, v1);
+}
+
+void gl4_3core_glProgramUniform2dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLdouble* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform2dv(program, location, count, value);
+}
+
+void gl4_3core_glProgramUniform2d(void *_glfuncs, GLuint program, GLint location, GLdouble v0, GLdouble v1)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform2d(program, location, v0, v1);
+}
+
+void gl4_3core_glProgramUniform2fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform2fv(program, location, count, value);
+}
+
+void gl4_3core_glProgramUniform2f(void *_glfuncs, GLuint program, GLint location, GLfloat v0, GLfloat v1)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform2f(program, location, v0, v1);
+}
+
+void gl4_3core_glProgramUniform2iv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform2iv(program, location, count, value);
+}
+
+void gl4_3core_glProgramUniform2i(void *_glfuncs, GLuint program, GLint location, GLint v0, GLint v1)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform2i(program, location, v0, v1);
+}
+
+void gl4_3core_glProgramUniform1uiv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLuint* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform1uiv(program, location, count, value);
+}
+
+void gl4_3core_glProgramUniform1ui(void *_glfuncs, GLuint program, GLint location, GLuint v0)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform1ui(program, location, v0);
+}
+
+void gl4_3core_glProgramUniform1dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLdouble* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform1dv(program, location, count, value);
+}
+
+void gl4_3core_glProgramUniform1d(void *_glfuncs, GLuint program, GLint location, GLdouble v0)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform1d(program, location, v0);
+}
+
+void gl4_3core_glProgramUniform1fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform1fv(program, location, count, value);
+}
+
+void gl4_3core_glProgramUniform1f(void *_glfuncs, GLuint program, GLint location, GLfloat v0)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform1f(program, location, v0);
+}
+
+void gl4_3core_glProgramUniform1iv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform1iv(program, location, count, value);
+}
+
+void gl4_3core_glProgramUniform1i(void *_glfuncs, GLuint program, GLint location, GLint v0)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glProgramUniform1i(program, location, v0);
+}
+
+void gl4_3core_glGetProgramPipelineiv(void *_glfuncs, GLuint pipeline, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetProgramPipelineiv(pipeline, pname, params);
+}
+
+GLboolean gl4_3core_glIsProgramPipeline(void *_glfuncs, GLuint pipeline)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ return _qglfuncs->glIsProgramPipeline(pipeline);
+}
+
+void gl4_3core_glGenProgramPipelines(void *_glfuncs, GLsizei n, GLuint* pipelines)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGenProgramPipelines(n, pipelines);
+}
+
+void gl4_3core_glDeleteProgramPipelines(void *_glfuncs, GLsizei n, const GLuint* pipelines)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glDeleteProgramPipelines(n, pipelines);
+}
+
+void gl4_3core_glBindProgramPipeline(void *_glfuncs, GLuint pipeline)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glBindProgramPipeline(pipeline);
+}
+
+void gl4_3core_glActiveShaderProgram(void *_glfuncs, GLuint pipeline, GLuint program)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glActiveShaderProgram(pipeline, program);
+}
+
+void gl4_3core_glUseProgramStages(void *_glfuncs, GLuint pipeline, GLbitfield stages, GLuint program)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glUseProgramStages(pipeline, stages, program);
+}
+
+void gl4_3core_glProgramParameteri(void *_glfuncs, GLuint program, GLenum pname, GLint value)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glProgramParameteri(program, pname, value);
+}
+
+void gl4_3core_glProgramBinary(void *_glfuncs, GLuint program, GLenum binaryFormat, const GLvoid* binary, GLsizei length)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glProgramBinary(program, binaryFormat, binary, length);
+}
+
+void gl4_3core_glGetProgramBinary(void *_glfuncs, GLuint program, GLsizei bufSize, GLsizei* length, GLenum* binaryFormat, GLvoid* binary)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetProgramBinary(program, bufSize, length, binaryFormat, binary);
+}
+
+void gl4_3core_glClearDepthf(void *_glfuncs, GLfloat dd)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glClearDepthf(dd);
+}
+
+void gl4_3core_glDepthRangef(void *_glfuncs, GLfloat n, GLfloat f)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glDepthRangef(n, f);
+}
+
+void gl4_3core_glGetShaderPrecisionFormat(void *_glfuncs, GLenum shadertype, GLenum precisionType, GLint* range_, GLint* precision)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetShaderPrecisionFormat(shadertype, precisionType, range_, precision);
+}
+
+void gl4_3core_glShaderBinary(void *_glfuncs, GLsizei count, const GLuint* shaders, GLenum binaryFormat, const GLvoid* binary, GLsizei length)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glShaderBinary(count, shaders, binaryFormat, binary, length);
+}
+
+void gl4_3core_glReleaseShaderCompiler(void *_glfuncs)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glReleaseShaderCompiler();
+}
+
+void gl4_3core_glTexStorage3D(void *_glfuncs, GLenum target, GLsizei levels, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glTexStorage3D(target, levels, internalFormat, width, height, depth);
+}
+
+void gl4_3core_glTexStorage2D(void *_glfuncs, GLenum target, GLsizei levels, GLenum internalFormat, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glTexStorage2D(target, levels, internalFormat, width, height);
+}
+
+void gl4_3core_glTexStorage1D(void *_glfuncs, GLenum target, GLsizei levels, GLenum internalFormat, GLsizei width)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glTexStorage1D(target, levels, internalFormat, width);
+}
+
+void gl4_3core_glMemoryBarrier(void *_glfuncs, GLbitfield barriers)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glMemoryBarrier(barriers);
+}
+
+void gl4_3core_glBindImageTexture(void *_glfuncs, GLuint unit, GLuint texture, GLint level, GLboolean layered, GLint layer, GLenum access, GLenum format)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glBindImageTexture(unit, texture, level, layered, layer, access, format);
+}
+
+void gl4_3core_glGetActiveAtomicCounterBufferiv(void *_glfuncs, GLuint program, GLuint bufferIndex, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetActiveAtomicCounterBufferiv(program, bufferIndex, pname, params);
+}
+
+void gl4_3core_glGetInternalformativ(void *_glfuncs, GLenum target, GLenum internalFormat, GLenum pname, GLsizei bufSize, GLint* params)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetInternalformativ(target, internalFormat, pname, bufSize, params);
+}
+
+void gl4_3core_glDrawTransformFeedbackStreamInstanced(void *_glfuncs, GLenum mode, GLuint id, GLuint stream, GLsizei instancecount)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glDrawTransformFeedbackStreamInstanced(mode, id, stream, instancecount);
+}
+
+void gl4_3core_glDrawTransformFeedbackInstanced(void *_glfuncs, GLenum mode, GLuint id, GLsizei instancecount)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glDrawTransformFeedbackInstanced(mode, id, instancecount);
+}
+
+void gl4_3core_glDrawElementsInstancedBaseVertexBaseInstance(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount, GLint basevertex, GLuint baseinstance)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glDrawElementsInstancedBaseVertexBaseInstance(mode, count, gltype, indices, instancecount, basevertex, baseinstance);
+}
+
+void gl4_3core_glDrawElementsInstancedBaseInstance(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount, GLuint baseinstance)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glDrawElementsInstancedBaseInstance(mode, count, gltype, indices, instancecount, baseinstance);
+}
+
+void gl4_3core_glDrawArraysInstancedBaseInstance(void *_glfuncs, GLenum mode, GLint first, GLsizei count, GLsizei instancecount, GLuint baseinstance)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glDrawArraysInstancedBaseInstance(mode, first, count, instancecount, baseinstance);
+}
+
+void gl4_3core_glTexStorage3DMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glTexStorage3DMultisample(target, samples, internalFormat, width, height, depth, fixedsamplelocations);
+}
+
+void gl4_3core_glTexStorage2DMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLenum internalFormat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glTexStorage2DMultisample(target, samples, internalFormat, width, height, fixedsamplelocations);
+}
+
+void gl4_3core_glTexBufferRange(void *_glfuncs, GLenum target, GLenum internalFormat, GLuint buffer, GLintptr offset, GLsizeiptr size)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glTexBufferRange(target, internalFormat, buffer, offset, size);
+}
+
+void gl4_3core_glShaderStorageBlockBinding(void *_glfuncs, GLuint program, GLuint storageBlockIndex, GLuint storageBlockBinding)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glShaderStorageBlockBinding(program, storageBlockIndex, storageBlockBinding);
+}
+
+GLint gl4_3core_glGetProgramResourceLocationIndex(void *_glfuncs, GLuint program, GLenum programInterface, const GLchar* name)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ return _qglfuncs->glGetProgramResourceLocationIndex(program, programInterface, name);
+}
+
+GLint gl4_3core_glGetProgramResourceLocation(void *_glfuncs, GLuint program, GLenum programInterface, const GLchar* name)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ return _qglfuncs->glGetProgramResourceLocation(program, programInterface, name);
+}
+
+void gl4_3core_glGetProgramResourceiv(void *_glfuncs, GLuint program, GLenum programInterface, GLuint index, GLsizei propCount, const GLenum* props, GLsizei bufSize, GLsizei* length, GLint* params)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetProgramResourceiv(program, programInterface, index, propCount, props, bufSize, length, params);
+}
+
+void gl4_3core_glGetProgramResourceName(void *_glfuncs, GLuint program, GLenum programInterface, GLuint index, GLsizei bufSize, GLsizei* length, GLchar* name)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetProgramResourceName(program, programInterface, index, bufSize, length, name);
+}
+
+GLuint gl4_3core_glGetProgramResourceIndex(void *_glfuncs, GLuint program, GLenum programInterface, const GLchar* name)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ return _qglfuncs->glGetProgramResourceIndex(program, programInterface, name);
+}
+
+void gl4_3core_glGetProgramInterfaceiv(void *_glfuncs, GLuint program, GLenum programInterface, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetProgramInterfaceiv(program, programInterface, pname, params);
+}
+
+void gl4_3core_glMultiDrawElementsIndirect(void *_glfuncs, GLenum mode, GLenum gltype, const GLvoid* indirect, GLsizei drawcount, GLsizei stride)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glMultiDrawElementsIndirect(mode, gltype, indirect, drawcount, stride);
+}
+
+void gl4_3core_glMultiDrawArraysIndirect(void *_glfuncs, GLenum mode, const GLvoid* indirect, GLsizei drawcount, GLsizei stride)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glMultiDrawArraysIndirect(mode, indirect, drawcount, stride);
+}
+
+void gl4_3core_glInvalidateSubFramebuffer(void *_glfuncs, GLenum target, GLsizei numAttachments, const GLenum* attachments, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glInvalidateSubFramebuffer(target, numAttachments, attachments, x, y, width, height);
+}
+
+void gl4_3core_glInvalidateFramebuffer(void *_glfuncs, GLenum target, GLsizei numAttachments, const GLenum* attachments)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glInvalidateFramebuffer(target, numAttachments, attachments);
+}
+
+void gl4_3core_glInvalidateBufferData(void *_glfuncs, GLuint buffer)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glInvalidateBufferData(buffer);
+}
+
+void gl4_3core_glInvalidateBufferSubData(void *_glfuncs, GLuint buffer, GLintptr offset, GLsizeiptr length)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glInvalidateBufferSubData(buffer, offset, length);
+}
+
+void gl4_3core_glInvalidateTexImage(void *_glfuncs, GLuint texture, GLint level)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glInvalidateTexImage(texture, level);
+}
+
+void gl4_3core_glInvalidateTexSubImage(void *_glfuncs, GLuint texture, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glInvalidateTexSubImage(texture, level, xoffset, yoffset, zoffset, width, height, depth);
+}
+
+void gl4_3core_glGetInternalformati64v(void *_glfuncs, GLenum target, GLenum internalFormat, GLenum pname, GLsizei bufSize, GLint64* params)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetInternalformati64v(target, internalFormat, pname, bufSize, params);
+}
+
+void gl4_3core_glGetFramebufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glGetFramebufferParameteriv(target, pname, params);
+}
+
+void gl4_3core_glFramebufferParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint param)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glFramebufferParameteri(target, pname, param);
+}
+
+void gl4_3core_glVertexBindingDivisor(void *_glfuncs, GLuint bindingindex, GLuint divisor)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glVertexBindingDivisor(bindingindex, divisor);
+}
+
+void gl4_3core_glVertexAttribBinding(void *_glfuncs, GLuint attribindex, GLuint bindingindex)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribBinding(attribindex, bindingindex);
+}
+
+void gl4_3core_glVertexAttribLFormat(void *_glfuncs, GLuint attribindex, GLint size, GLenum gltype, GLuint relativeoffset)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribLFormat(attribindex, size, gltype, relativeoffset);
+}
+
+void gl4_3core_glVertexAttribIFormat(void *_glfuncs, GLuint attribindex, GLint size, GLenum gltype, GLuint relativeoffset)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribIFormat(attribindex, size, gltype, relativeoffset);
+}
+
+void gl4_3core_glVertexAttribFormat(void *_glfuncs, GLuint attribindex, GLint size, GLenum gltype, GLboolean normalized, GLuint relativeoffset)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glVertexAttribFormat(attribindex, size, gltype, normalized, relativeoffset);
+}
+
+void gl4_3core_glBindVertexBuffer(void *_glfuncs, GLuint bindingindex, GLuint buffer, GLintptr offset, GLsizei stride)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glBindVertexBuffer(bindingindex, buffer, offset, stride);
+}
+
+void gl4_3core_glTextureView(void *_glfuncs, GLuint texture, GLenum target, GLuint origtexture, GLenum internalFormat, GLuint minlevel, GLuint numlevels, GLuint minlayer, GLuint numlayers)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glTextureView(texture, target, origtexture, internalFormat, minlevel, numlevels, minlayer, numlayers);
+}
+
+void gl4_3core_glCopyImageSubData(void *_glfuncs, GLuint srcName, GLenum srcTarget, GLint srcLevel, GLint srcX, GLint srcY, GLint srcZ, GLuint dstName, GLenum dstTarget, GLint dstLevel, GLint dstX, GLint dstY, GLint dstZ, GLsizei srcWidth, GLsizei srcHeight, GLsizei srcDepth)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glCopyImageSubData(srcName, srcTarget, srcLevel, srcX, srcY, srcZ, dstName, dstTarget, dstLevel, dstX, dstY, dstZ, srcWidth, srcHeight, srcDepth);
+}
+
+void gl4_3core_glDispatchComputeIndirect(void *_glfuncs, GLintptr indirect)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glDispatchComputeIndirect(indirect);
+}
+
+void gl4_3core_glDispatchCompute(void *_glfuncs, GLuint num_groups_x, GLuint num_groups_y, GLuint num_groups_z)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glDispatchCompute(num_groups_x, num_groups_y, num_groups_z);
+}
+
+void gl4_3core_glClearBufferSubData(void *_glfuncs, GLenum target, GLenum internalFormat, GLintptr offset, GLsizeiptr size, GLenum format, GLenum gltype, const GLvoid* data)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glClearBufferSubData(target, internalFormat, offset, size, format, gltype, data);
+}
+
+void gl4_3core_glClearBufferData(void *_glfuncs, GLenum target, GLenum internalFormat, GLenum format, GLenum gltype, const GLvoid* data)
+{
+ QOpenGLFunctions_4_3_Core* _qglfuncs = reinterpret_cast<QOpenGLFunctions_4_3_Core*>(_glfuncs);
+ _qglfuncs->glClearBufferData(target, internalFormat, format, gltype, data);
+}
+
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.3core/funcs.h b/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.3core/funcs.h
new file mode 100644
index 000000000..b65f69bc4
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.3core/funcs.h
@@ -0,0 +1,530 @@
+
+// ** file automatically generated by glgen -- do not edit manually **
+
+#ifndef __cplusplus
+#include <inttypes.h>
+#include <stddef.h>
+typedef unsigned int GLenum;
+typedef unsigned char GLboolean;
+typedef unsigned int GLbitfield;
+typedef void GLvoid;
+typedef char GLchar;
+typedef signed char GLbyte; /* 1-byte signed */
+typedef short GLshort; /* 2-byte signed */
+typedef int GLint; /* 4-byte signed */
+typedef unsigned char GLubyte; /* 1-byte unsigned */
+typedef unsigned short GLushort; /* 2-byte unsigned */
+typedef unsigned int GLuint; /* 4-byte unsigned */
+typedef int GLsizei; /* 4-byte signed */
+typedef float GLfloat; /* single precision float */
+typedef float GLclampf; /* single precision float in [0,1] */
+typedef double GLdouble; /* double precision float */
+typedef double GLclampd; /* double precision float in [0,1] */
+typedef int64_t GLint64;
+typedef uint64_t GLuint64;
+typedef ptrdiff_t GLintptr;
+typedef ptrdiff_t GLsizeiptr;
+typedef ptrdiff_t GLintptrARB;
+typedef ptrdiff_t GLsizeiptrARB;
+typedef struct __GLsync *GLsync;
+#endif
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+void *gl4_3core_funcs();
+
+void gl4_3core_glViewport(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl4_3core_glDepthRange(void *_glfuncs, GLdouble nearVal, GLdouble farVal);
+GLboolean gl4_3core_glIsEnabled(void *_glfuncs, GLenum cap);
+void gl4_3core_glGetTexLevelParameteriv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLint* params);
+void gl4_3core_glGetTexLevelParameterfv(void *_glfuncs, GLenum target, GLint level, GLenum pname, GLfloat* params);
+void gl4_3core_glGetTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl4_3core_glGetTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gl4_3core_glGetTexImage(void *_glfuncs, GLenum target, GLint level, GLenum format, GLenum gltype, GLvoid* pixels);
+void gl4_3core_glGetIntegerv(void *_glfuncs, GLenum pname, GLint* params);
+void gl4_3core_glGetFloatv(void *_glfuncs, GLenum pname, GLfloat* params);
+GLenum gl4_3core_glGetError(void *_glfuncs);
+void gl4_3core_glGetDoublev(void *_glfuncs, GLenum pname, GLdouble* params);
+void gl4_3core_glGetBooleanv(void *_glfuncs, GLenum pname, GLboolean* params);
+void gl4_3core_glReadPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum gltype, GLvoid* pixels);
+void gl4_3core_glReadBuffer(void *_glfuncs, GLenum mode);
+void gl4_3core_glPixelStorei(void *_glfuncs, GLenum pname, GLint param);
+void gl4_3core_glPixelStoref(void *_glfuncs, GLenum pname, GLfloat param);
+void gl4_3core_glDepthFunc(void *_glfuncs, GLenum glfunc);
+void gl4_3core_glStencilOp(void *_glfuncs, GLenum fail, GLenum zfail, GLenum zpass);
+void gl4_3core_glStencilFunc(void *_glfuncs, GLenum glfunc, GLint ref, GLuint mask);
+void gl4_3core_glLogicOp(void *_glfuncs, GLenum opcode);
+void gl4_3core_glBlendFunc(void *_glfuncs, GLenum sfactor, GLenum dfactor);
+void gl4_3core_glFlush(void *_glfuncs);
+void gl4_3core_glFinish(void *_glfuncs);
+void gl4_3core_glEnable(void *_glfuncs, GLenum cap);
+void gl4_3core_glDisable(void *_glfuncs, GLenum cap);
+void gl4_3core_glDepthMask(void *_glfuncs, GLboolean flag);
+void gl4_3core_glColorMask(void *_glfuncs, GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha);
+void gl4_3core_glStencilMask(void *_glfuncs, GLuint mask);
+void gl4_3core_glClearDepth(void *_glfuncs, GLdouble depth);
+void gl4_3core_glClearStencil(void *_glfuncs, GLint s);
+void gl4_3core_glClearColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl4_3core_glClear(void *_glfuncs, GLbitfield mask);
+void gl4_3core_glDrawBuffer(void *_glfuncs, GLenum mode);
+void gl4_3core_glTexImage2D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl4_3core_glTexImage1D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl4_3core_glTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl4_3core_glTexParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint param);
+void gl4_3core_glTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gl4_3core_glTexParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param);
+void gl4_3core_glScissor(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl4_3core_glPolygonMode(void *_glfuncs, GLenum face, GLenum mode);
+void gl4_3core_glPointSize(void *_glfuncs, GLfloat size);
+void gl4_3core_glLineWidth(void *_glfuncs, GLfloat width);
+void gl4_3core_glHint(void *_glfuncs, GLenum target, GLenum mode);
+void gl4_3core_glFrontFace(void *_glfuncs, GLenum mode);
+void gl4_3core_glCullFace(void *_glfuncs, GLenum mode);
+void gl4_3core_glIndexubv(void *_glfuncs, const GLubyte* c);
+void gl4_3core_glIndexub(void *_glfuncs, GLubyte c);
+GLboolean gl4_3core_glIsTexture(void *_glfuncs, GLuint texture);
+void gl4_3core_glGenTextures(void *_glfuncs, GLsizei n, GLuint* textures);
+void gl4_3core_glDeleteTextures(void *_glfuncs, GLsizei n, const GLuint* textures);
+void gl4_3core_glBindTexture(void *_glfuncs, GLenum target, GLuint texture);
+void gl4_3core_glTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl4_3core_glTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl4_3core_glCopyTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl4_3core_glCopyTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width);
+void gl4_3core_glCopyTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border);
+void gl4_3core_glCopyTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLint border);
+void gl4_3core_glPolygonOffset(void *_glfuncs, GLfloat factor, GLfloat units);
+void gl4_3core_glDrawElements(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices);
+void gl4_3core_glDrawArrays(void *_glfuncs, GLenum mode, GLint first, GLsizei count);
+void gl4_3core_glCopyTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl4_3core_glTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl4_3core_glTexImage3D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gl4_3core_glDrawRangeElements(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices);
+void gl4_3core_glBlendEquation(void *_glfuncs, GLenum mode);
+void gl4_3core_glBlendColor(void *_glfuncs, GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+void gl4_3core_glGetCompressedTexImage(void *_glfuncs, GLenum target, GLint level, GLvoid* img);
+void gl4_3core_glCompressedTexSubImage1D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLsizei imageSize, const GLvoid* data);
+void gl4_3core_glCompressedTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid* data);
+void gl4_3core_glCompressedTexSubImage3D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLsizei imageSize, const GLvoid* data);
+void gl4_3core_glCompressedTexImage1D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLint border, GLsizei imageSize, const GLvoid* data);
+void gl4_3core_glCompressedTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid* data);
+void gl4_3core_glCompressedTexImage3D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLint border, GLsizei imageSize, const GLvoid* data);
+void gl4_3core_glSampleCoverage(void *_glfuncs, GLfloat value, GLboolean invert);
+void gl4_3core_glActiveTexture(void *_glfuncs, GLenum texture);
+void gl4_3core_glPointParameteriv(void *_glfuncs, GLenum pname, const GLint* params);
+void gl4_3core_glPointParameteri(void *_glfuncs, GLenum pname, GLint param);
+void gl4_3core_glPointParameterfv(void *_glfuncs, GLenum pname, const GLfloat* params);
+void gl4_3core_glPointParameterf(void *_glfuncs, GLenum pname, GLfloat param);
+void gl4_3core_glMultiDrawArrays(void *_glfuncs, GLenum mode, const GLint* first, const GLsizei* count, GLsizei drawcount);
+void gl4_3core_glBlendFuncSeparate(void *_glfuncs, GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha);
+void gl4_3core_glGetBufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+GLboolean gl4_3core_glUnmapBuffer(void *_glfuncs, GLenum target);
+void gl4_3core_glGetBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, GLvoid* data);
+void gl4_3core_glBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid* data);
+void gl4_3core_glBufferData(void *_glfuncs, GLenum target, GLsizeiptr size, const GLvoid* data, GLenum usage);
+GLboolean gl4_3core_glIsBuffer(void *_glfuncs, GLuint buffer);
+void gl4_3core_glGenBuffers(void *_glfuncs, GLsizei n, GLuint* buffers);
+void gl4_3core_glDeleteBuffers(void *_glfuncs, GLsizei n, const GLuint* buffers);
+void gl4_3core_glBindBuffer(void *_glfuncs, GLenum target, GLuint buffer);
+void gl4_3core_glGetQueryObjectuiv(void *_glfuncs, GLuint id, GLenum pname, GLuint* params);
+void gl4_3core_glGetQueryObjectiv(void *_glfuncs, GLuint id, GLenum pname, GLint* params);
+void gl4_3core_glGetQueryiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl4_3core_glEndQuery(void *_glfuncs, GLenum target);
+void gl4_3core_glBeginQuery(void *_glfuncs, GLenum target, GLuint id);
+GLboolean gl4_3core_glIsQuery(void *_glfuncs, GLuint id);
+void gl4_3core_glDeleteQueries(void *_glfuncs, GLsizei n, const GLuint* ids);
+void gl4_3core_glGenQueries(void *_glfuncs, GLsizei n, GLuint* ids);
+void gl4_3core_glVertexAttribPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLboolean normalized, GLsizei stride, const GLvoid* offset);
+void gl4_3core_glValidateProgram(void *_glfuncs, GLuint program);
+void gl4_3core_glUniformMatrix4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_3core_glUniformMatrix3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_3core_glUniformMatrix2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_3core_glUniform4iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl4_3core_glUniform3iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl4_3core_glUniform2iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl4_3core_glUniform1iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gl4_3core_glUniform4fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl4_3core_glUniform3fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl4_3core_glUniform2fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl4_3core_glUniform1fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gl4_3core_glUniform4i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2, GLint v3);
+void gl4_3core_glUniform3i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2);
+void gl4_3core_glUniform2i(void *_glfuncs, GLint location, GLint v0, GLint v1);
+void gl4_3core_glUniform1i(void *_glfuncs, GLint location, GLint v0);
+void gl4_3core_glUniform4f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3);
+void gl4_3core_glUniform3f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2);
+void gl4_3core_glUniform2f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1);
+void gl4_3core_glUniform1f(void *_glfuncs, GLint location, GLfloat v0);
+void gl4_3core_glUseProgram(void *_glfuncs, GLuint program);
+void gl4_3core_glShaderSource(void *_glfuncs, GLuint shader, GLsizei count, const GLchar** source, const GLint* length);
+void gl4_3core_glLinkProgram(void *_glfuncs, GLuint program);
+GLboolean gl4_3core_glIsShader(void *_glfuncs, GLuint shader);
+GLboolean gl4_3core_glIsProgram(void *_glfuncs, GLuint program);
+void gl4_3core_glGetVertexAttribiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params);
+void gl4_3core_glGetVertexAttribfv(void *_glfuncs, GLuint index, GLenum pname, GLfloat* params);
+void gl4_3core_glGetVertexAttribdv(void *_glfuncs, GLuint index, GLenum pname, GLdouble* params);
+void gl4_3core_glGetUniformiv(void *_glfuncs, GLuint program, GLint location, GLint* params);
+void gl4_3core_glGetUniformfv(void *_glfuncs, GLuint program, GLint location, GLfloat* params);
+GLint gl4_3core_glGetUniformLocation(void *_glfuncs, GLuint program, const GLchar* name);
+void gl4_3core_glGetShaderSource(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* source);
+void gl4_3core_glGetShaderInfoLog(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* infoLog);
+void gl4_3core_glGetShaderiv(void *_glfuncs, GLuint shader, GLenum pname, GLint* params);
+void gl4_3core_glGetProgramInfoLog(void *_glfuncs, GLuint program, GLsizei bufSize, GLsizei* length, GLchar* infoLog);
+void gl4_3core_glGetProgramiv(void *_glfuncs, GLuint program, GLenum pname, GLint* params);
+GLint gl4_3core_glGetAttribLocation(void *_glfuncs, GLuint program, const GLchar* name);
+void gl4_3core_glGetAttachedShaders(void *_glfuncs, GLuint program, GLsizei maxCount, GLsizei* count, GLuint* obj);
+void gl4_3core_glGetActiveUniform(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name);
+void gl4_3core_glGetActiveAttrib(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name);
+void gl4_3core_glEnableVertexAttribArray(void *_glfuncs, GLuint index);
+void gl4_3core_glDisableVertexAttribArray(void *_glfuncs, GLuint index);
+void gl4_3core_glDetachShader(void *_glfuncs, GLuint program, GLuint shader);
+void gl4_3core_glDeleteShader(void *_glfuncs, GLuint shader);
+void gl4_3core_glDeleteProgram(void *_glfuncs, GLuint program);
+GLuint gl4_3core_glCreateShader(void *_glfuncs, GLenum gltype);
+GLuint gl4_3core_glCreateProgram(void *_glfuncs);
+void gl4_3core_glCompileShader(void *_glfuncs, GLuint shader);
+void gl4_3core_glBindAttribLocation(void *_glfuncs, GLuint program, GLuint index, const GLchar* name);
+void gl4_3core_glAttachShader(void *_glfuncs, GLuint program, GLuint shader);
+void gl4_3core_glStencilMaskSeparate(void *_glfuncs, GLenum face, GLuint mask);
+void gl4_3core_glStencilFuncSeparate(void *_glfuncs, GLenum face, GLenum glfunc, GLint ref, GLuint mask);
+void gl4_3core_glStencilOpSeparate(void *_glfuncs, GLenum face, GLenum sfail, GLenum dpfail, GLenum dppass);
+void gl4_3core_glDrawBuffers(void *_glfuncs, GLsizei n, const GLenum* bufs);
+void gl4_3core_glBlendEquationSeparate(void *_glfuncs, GLenum modeRGB, GLenum modeAlpha);
+void gl4_3core_glUniformMatrix4x3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_3core_glUniformMatrix3x4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_3core_glUniformMatrix4x2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_3core_glUniformMatrix2x4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_3core_glUniformMatrix3x2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_3core_glUniformMatrix2x3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+GLboolean gl4_3core_glIsVertexArray(void *_glfuncs, GLuint array);
+void gl4_3core_glGenVertexArrays(void *_glfuncs, GLsizei n, GLuint* arrays);
+void gl4_3core_glDeleteVertexArrays(void *_glfuncs, GLsizei n, const GLuint* arrays);
+void gl4_3core_glBindVertexArray(void *_glfuncs, GLuint array);
+void gl4_3core_glFlushMappedBufferRange(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr length);
+void gl4_3core_glFramebufferTextureLayer(void *_glfuncs, GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer);
+void gl4_3core_glRenderbufferStorageMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLenum internalFormat, GLsizei width, GLsizei height);
+void gl4_3core_glBlitFramebuffer(void *_glfuncs, GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter);
+void gl4_3core_glGenerateMipmap(void *_glfuncs, GLenum target);
+void gl4_3core_glGetFramebufferAttachmentParameteriv(void *_glfuncs, GLenum target, GLenum attachment, GLenum pname, GLint* params);
+void gl4_3core_glFramebufferRenderbuffer(void *_glfuncs, GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer);
+void gl4_3core_glFramebufferTexture3D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset);
+void gl4_3core_glFramebufferTexture2D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+void gl4_3core_glFramebufferTexture1D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+GLenum gl4_3core_glCheckFramebufferStatus(void *_glfuncs, GLenum target);
+void gl4_3core_glGenFramebuffers(void *_glfuncs, GLsizei n, GLuint* framebuffers);
+void gl4_3core_glDeleteFramebuffers(void *_glfuncs, GLsizei n, const GLuint* framebuffers);
+void gl4_3core_glBindFramebuffer(void *_glfuncs, GLenum target, GLuint framebuffer);
+GLboolean gl4_3core_glIsFramebuffer(void *_glfuncs, GLuint framebuffer);
+void gl4_3core_glGetRenderbufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl4_3core_glRenderbufferStorage(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height);
+void gl4_3core_glGenRenderbuffers(void *_glfuncs, GLsizei n, GLuint* renderbuffers);
+void gl4_3core_glDeleteRenderbuffers(void *_glfuncs, GLsizei n, const GLuint* renderbuffers);
+void gl4_3core_glBindRenderbuffer(void *_glfuncs, GLenum target, GLuint renderbuffer);
+GLboolean gl4_3core_glIsRenderbuffer(void *_glfuncs, GLuint renderbuffer);
+void gl4_3core_glClearBufferfi(void *_glfuncs, GLenum buffer, GLint drawbuffer, GLfloat depth, GLint stencil);
+void gl4_3core_glClearBufferfv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLfloat* value);
+void gl4_3core_glClearBufferuiv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLuint* value);
+void gl4_3core_glClearBufferiv(void *_glfuncs, GLenum buffer, GLint drawbuffer, const GLint* value);
+void gl4_3core_glGetTexParameterIuiv(void *_glfuncs, GLenum target, GLenum pname, GLuint* params);
+void gl4_3core_glGetTexParameterIiv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl4_3core_glTexParameterIuiv(void *_glfuncs, GLenum target, GLenum pname, const GLuint* params);
+void gl4_3core_glTexParameterIiv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gl4_3core_glUniform4uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value);
+void gl4_3core_glUniform3uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value);
+void gl4_3core_glUniform2uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value);
+void gl4_3core_glUniform1uiv(void *_glfuncs, GLint location, GLsizei count, const GLuint* value);
+void gl4_3core_glUniform4ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3);
+void gl4_3core_glUniform3ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1, GLuint v2);
+void gl4_3core_glUniform2ui(void *_glfuncs, GLint location, GLuint v0, GLuint v1);
+void gl4_3core_glUniform1ui(void *_glfuncs, GLint location, GLuint v0);
+GLint gl4_3core_glGetFragDataLocation(void *_glfuncs, GLuint program, const GLchar* name);
+void gl4_3core_glBindFragDataLocation(void *_glfuncs, GLuint program, GLuint color, const GLchar* name);
+void gl4_3core_glGetUniformuiv(void *_glfuncs, GLuint program, GLint location, GLuint* params);
+void gl4_3core_glGetVertexAttribIuiv(void *_glfuncs, GLuint index, GLenum pname, GLuint* params);
+void gl4_3core_glGetVertexAttribIiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params);
+void gl4_3core_glVertexAttribIPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl4_3core_glEndConditionalRender(void *_glfuncs);
+void gl4_3core_glBeginConditionalRender(void *_glfuncs, GLuint id, GLenum mode);
+void gl4_3core_glClampColor(void *_glfuncs, GLenum target, GLenum clamp);
+void gl4_3core_glGetTransformFeedbackVarying(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLsizei* size, GLenum* gltype, GLchar* name);
+void gl4_3core_glBindBufferBase(void *_glfuncs, GLenum target, GLuint index, GLuint buffer);
+void gl4_3core_glBindBufferRange(void *_glfuncs, GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size);
+void gl4_3core_glEndTransformFeedback(void *_glfuncs);
+void gl4_3core_glBeginTransformFeedback(void *_glfuncs, GLenum primitiveMode);
+GLboolean gl4_3core_glIsEnabledi(void *_glfuncs, GLenum target, GLuint index);
+void gl4_3core_glDisablei(void *_glfuncs, GLenum target, GLuint index);
+void gl4_3core_glEnablei(void *_glfuncs, GLenum target, GLuint index);
+void gl4_3core_glGetIntegeri_v(void *_glfuncs, GLenum target, GLuint index, GLint* data);
+void gl4_3core_glGetBooleani_v(void *_glfuncs, GLenum target, GLuint index, GLboolean* data);
+void gl4_3core_glColorMaski(void *_glfuncs, GLuint index, GLboolean r, GLboolean g, GLboolean b, GLboolean a);
+void gl4_3core_glCopyBufferSubData(void *_glfuncs, GLenum readTarget, GLenum writeTarget, GLintptr readOffset, GLintptr writeOffset, GLsizeiptr size);
+void gl4_3core_glUniformBlockBinding(void *_glfuncs, GLuint program, GLuint v0, GLuint v1);
+void gl4_3core_glGetActiveUniformBlockName(void *_glfuncs, GLuint program, GLuint uniformBlockIndex, GLsizei bufSize, GLsizei* length, GLchar* uniformBlockName);
+void gl4_3core_glGetActiveUniformBlockiv(void *_glfuncs, GLuint program, GLuint uniformBlockIndex, GLenum pname, GLint* params);
+GLuint gl4_3core_glGetUniformBlockIndex(void *_glfuncs, GLuint program, const GLchar* uniformBlockName);
+void gl4_3core_glGetActiveUniformName(void *_glfuncs, GLuint program, GLuint uniformIndex, GLsizei bufSize, GLsizei* length, GLchar* uniformName);
+void gl4_3core_glGetActiveUniformsiv(void *_glfuncs, GLuint program, GLsizei uniformCount, const GLuint* uniformIndices, GLenum pname, GLint* params);
+void gl4_3core_glPrimitiveRestartIndex(void *_glfuncs, GLuint index);
+void gl4_3core_glTexBuffer(void *_glfuncs, GLenum target, GLenum internalFormat, GLuint buffer);
+void gl4_3core_glDrawElementsInstanced(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount);
+void gl4_3core_glDrawArraysInstanced(void *_glfuncs, GLenum mode, GLint first, GLsizei count, GLsizei instancecount);
+void gl4_3core_glSampleMaski(void *_glfuncs, GLuint index, GLbitfield mask);
+void gl4_3core_glGetMultisamplefv(void *_glfuncs, GLenum pname, GLuint index, GLfloat* val);
+void gl4_3core_glTexImage3DMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations);
+void gl4_3core_glTexImage2DMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLint internalFormat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations);
+void gl4_3core_glGetSynciv(void *_glfuncs, GLsync sync, GLenum pname, GLsizei bufSize, GLsizei* length, GLint* values);
+void gl4_3core_glGetInteger64v(void *_glfuncs, GLenum pname, GLint64* params);
+void gl4_3core_glWaitSync(void *_glfuncs, GLsync sync, GLbitfield flags, GLuint64 timeout);
+GLenum gl4_3core_glClientWaitSync(void *_glfuncs, GLsync sync, GLbitfield flags, GLuint64 timeout);
+void gl4_3core_glDeleteSync(void *_glfuncs, GLsync sync);
+GLboolean gl4_3core_glIsSync(void *_glfuncs, GLsync sync);
+GLsync gl4_3core_glFenceSync(void *_glfuncs, GLenum condition, GLbitfield flags);
+void gl4_3core_glProvokingVertex(void *_glfuncs, GLenum mode);
+void gl4_3core_glDrawElementsInstancedBaseVertex(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount, GLint basevertex);
+void gl4_3core_glDrawRangeElementsBaseVertex(void *_glfuncs, GLenum mode, GLuint start, GLuint end, GLsizei count, GLenum gltype, const GLvoid* indices, GLint basevertex);
+void gl4_3core_glDrawElementsBaseVertex(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLint basevertex);
+void gl4_3core_glFramebufferTexture(void *_glfuncs, GLenum target, GLenum attachment, GLuint texture, GLint level);
+void gl4_3core_glGetBufferParameteri64v(void *_glfuncs, GLenum target, GLenum pname, GLint64* params);
+void gl4_3core_glGetInteger64i_v(void *_glfuncs, GLenum target, GLuint index, GLint64* data);
+void gl4_3core_glVertexAttribP4uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value);
+void gl4_3core_glVertexAttribP4ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value);
+void gl4_3core_glVertexAttribP3uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value);
+void gl4_3core_glVertexAttribP3ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value);
+void gl4_3core_glVertexAttribP2uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value);
+void gl4_3core_glVertexAttribP2ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value);
+void gl4_3core_glVertexAttribP1uiv(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, const GLuint* value);
+void gl4_3core_glVertexAttribP1ui(void *_glfuncs, GLuint index, GLenum gltype, GLboolean normalized, GLuint value);
+void gl4_3core_glSecondaryColorP3uiv(void *_glfuncs, GLenum gltype, const GLuint* color);
+void gl4_3core_glSecondaryColorP3ui(void *_glfuncs, GLenum gltype, GLuint color);
+void gl4_3core_glColorP4uiv(void *_glfuncs, GLenum gltype, const GLuint* color);
+void gl4_3core_glColorP4ui(void *_glfuncs, GLenum gltype, GLuint color);
+void gl4_3core_glColorP3uiv(void *_glfuncs, GLenum gltype, const GLuint* color);
+void gl4_3core_glColorP3ui(void *_glfuncs, GLenum gltype, GLuint color);
+void gl4_3core_glNormalP3uiv(void *_glfuncs, GLenum gltype, const GLuint* coords);
+void gl4_3core_glNormalP3ui(void *_glfuncs, GLenum gltype, GLuint coords);
+void gl4_3core_glMultiTexCoordP4uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords);
+void gl4_3core_glMultiTexCoordP4ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords);
+void gl4_3core_glMultiTexCoordP3uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords);
+void gl4_3core_glMultiTexCoordP3ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords);
+void gl4_3core_glMultiTexCoordP2uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords);
+void gl4_3core_glMultiTexCoordP2ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords);
+void gl4_3core_glMultiTexCoordP1uiv(void *_glfuncs, GLenum texture, GLenum gltype, const GLuint* coords);
+void gl4_3core_glMultiTexCoordP1ui(void *_glfuncs, GLenum texture, GLenum gltype, GLuint coords);
+void gl4_3core_glTexCoordP4uiv(void *_glfuncs, GLenum gltype, const GLuint* coords);
+void gl4_3core_glTexCoordP4ui(void *_glfuncs, GLenum gltype, GLuint coords);
+void gl4_3core_glTexCoordP3uiv(void *_glfuncs, GLenum gltype, const GLuint* coords);
+void gl4_3core_glTexCoordP3ui(void *_glfuncs, GLenum gltype, GLuint coords);
+void gl4_3core_glTexCoordP2uiv(void *_glfuncs, GLenum gltype, const GLuint* coords);
+void gl4_3core_glTexCoordP2ui(void *_glfuncs, GLenum gltype, GLuint coords);
+void gl4_3core_glTexCoordP1uiv(void *_glfuncs, GLenum gltype, const GLuint* coords);
+void gl4_3core_glTexCoordP1ui(void *_glfuncs, GLenum gltype, GLuint coords);
+void gl4_3core_glVertexP4uiv(void *_glfuncs, GLenum gltype, const GLuint* value);
+void gl4_3core_glVertexP4ui(void *_glfuncs, GLenum gltype, GLuint value);
+void gl4_3core_glVertexP3uiv(void *_glfuncs, GLenum gltype, const GLuint* value);
+void gl4_3core_glVertexP3ui(void *_glfuncs, GLenum gltype, GLuint value);
+void gl4_3core_glVertexP2uiv(void *_glfuncs, GLenum gltype, const GLuint* value);
+void gl4_3core_glVertexP2ui(void *_glfuncs, GLenum gltype, GLuint value);
+void gl4_3core_glGetQueryObjectui64v(void *_glfuncs, GLuint id, GLenum pname, GLuint64* params);
+void gl4_3core_glGetQueryObjecti64v(void *_glfuncs, GLuint id, GLenum pname, GLint64* params);
+void gl4_3core_glQueryCounter(void *_glfuncs, GLuint id, GLenum target);
+void gl4_3core_glGetSamplerParameterIuiv(void *_glfuncs, GLuint sampler, GLenum pname, GLuint* params);
+void gl4_3core_glGetSamplerParameterfv(void *_glfuncs, GLuint sampler, GLenum pname, GLfloat* params);
+void gl4_3core_glGetSamplerParameterIiv(void *_glfuncs, GLuint sampler, GLenum pname, GLint* params);
+void gl4_3core_glGetSamplerParameteriv(void *_glfuncs, GLuint sampler, GLenum pname, GLint* params);
+void gl4_3core_glSamplerParameterIuiv(void *_glfuncs, GLuint sampler, GLenum pname, const GLuint* param);
+void gl4_3core_glSamplerParameterIiv(void *_glfuncs, GLuint sampler, GLenum pname, const GLint* param);
+void gl4_3core_glSamplerParameterfv(void *_glfuncs, GLuint sampler, GLenum pname, const GLfloat* param);
+void gl4_3core_glSamplerParameterf(void *_glfuncs, GLuint sampler, GLenum pname, GLfloat param);
+void gl4_3core_glSamplerParameteriv(void *_glfuncs, GLuint sampler, GLenum pname, const GLint* param);
+void gl4_3core_glSamplerParameteri(void *_glfuncs, GLuint sampler, GLenum pname, GLint param);
+void gl4_3core_glBindSampler(void *_glfuncs, GLuint unit, GLuint sampler);
+GLboolean gl4_3core_glIsSampler(void *_glfuncs, GLuint sampler);
+void gl4_3core_glDeleteSamplers(void *_glfuncs, GLsizei count, const GLuint* samplers);
+void gl4_3core_glGenSamplers(void *_glfuncs, GLsizei count, GLuint* samplers);
+GLint gl4_3core_glGetFragDataIndex(void *_glfuncs, GLuint program, const GLchar* name);
+void gl4_3core_glBindFragDataLocationIndexed(void *_glfuncs, GLuint program, GLuint colorNumber, GLuint index, const GLchar* name);
+void gl4_3core_glVertexAttribDivisor(void *_glfuncs, GLuint index, GLuint divisor);
+void gl4_3core_glGetQueryIndexediv(void *_glfuncs, GLenum target, GLuint index, GLenum pname, GLint* params);
+void gl4_3core_glEndQueryIndexed(void *_glfuncs, GLenum target, GLuint index);
+void gl4_3core_glBeginQueryIndexed(void *_glfuncs, GLenum target, GLuint index, GLuint id);
+void gl4_3core_glDrawTransformFeedbackStream(void *_glfuncs, GLenum mode, GLuint id, GLuint stream);
+void gl4_3core_glDrawTransformFeedback(void *_glfuncs, GLenum mode, GLuint id);
+void gl4_3core_glResumeTransformFeedback(void *_glfuncs);
+void gl4_3core_glPauseTransformFeedback(void *_glfuncs);
+GLboolean gl4_3core_glIsTransformFeedback(void *_glfuncs, GLuint id);
+void gl4_3core_glGenTransformFeedbacks(void *_glfuncs, GLsizei n, GLuint* ids);
+void gl4_3core_glDeleteTransformFeedbacks(void *_glfuncs, GLsizei n, const GLuint* ids);
+void gl4_3core_glBindTransformFeedback(void *_glfuncs, GLenum target, GLuint id);
+void gl4_3core_glPatchParameterfv(void *_glfuncs, GLenum pname, const GLfloat* values);
+void gl4_3core_glPatchParameteri(void *_glfuncs, GLenum pname, GLint value);
+void gl4_3core_glGetProgramStageiv(void *_glfuncs, GLuint program, GLenum shadertype, GLenum pname, GLint* values);
+void gl4_3core_glGetUniformSubroutineuiv(void *_glfuncs, GLenum shadertype, GLint location, GLuint* params);
+void gl4_3core_glUniformSubroutinesuiv(void *_glfuncs, GLenum shadertype, GLsizei count, const GLuint* value);
+void gl4_3core_glGetActiveSubroutineName(void *_glfuncs, GLuint program, GLenum shadertype, GLuint index, GLsizei bufSize, GLsizei* length, GLchar* name);
+void gl4_3core_glGetActiveSubroutineUniformName(void *_glfuncs, GLuint program, GLenum shadertype, GLuint index, GLsizei bufSize, GLsizei* length, GLchar* name);
+void gl4_3core_glGetActiveSubroutineUniformiv(void *_glfuncs, GLuint program, GLenum shadertype, GLuint index, GLenum pname, GLint* values);
+GLuint gl4_3core_glGetSubroutineIndex(void *_glfuncs, GLuint program, GLenum shadertype, const GLchar* name);
+GLint gl4_3core_glGetSubroutineUniformLocation(void *_glfuncs, GLuint program, GLenum shadertype, const GLchar* name);
+void gl4_3core_glGetUniformdv(void *_glfuncs, GLuint program, GLint location, GLdouble* params);
+void gl4_3core_glUniformMatrix4x3dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_3core_glUniformMatrix4x2dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_3core_glUniformMatrix3x4dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_3core_glUniformMatrix3x2dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_3core_glUniformMatrix2x4dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_3core_glUniformMatrix2x3dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_3core_glUniformMatrix4dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_3core_glUniformMatrix3dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_3core_glUniformMatrix2dv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_3core_glUniform4dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value);
+void gl4_3core_glUniform3dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value);
+void gl4_3core_glUniform2dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value);
+void gl4_3core_glUniform1dv(void *_glfuncs, GLint location, GLsizei count, const GLdouble* value);
+void gl4_3core_glUniform4d(void *_glfuncs, GLint location, GLdouble v0, GLdouble v1, GLdouble v2, GLdouble v3);
+void gl4_3core_glUniform3d(void *_glfuncs, GLint location, GLdouble v0, GLdouble v1, GLdouble v2);
+void gl4_3core_glUniform2d(void *_glfuncs, GLint location, GLdouble v0, GLdouble v1);
+void gl4_3core_glUniform1d(void *_glfuncs, GLint location, GLdouble v0);
+void gl4_3core_glDrawElementsIndirect(void *_glfuncs, GLenum mode, GLenum gltype, const GLvoid* indirect);
+void gl4_3core_glDrawArraysIndirect(void *_glfuncs, GLenum mode, const GLvoid* indirect);
+void gl4_3core_glBlendFuncSeparatei(void *_glfuncs, GLuint buf, GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha, GLenum dstAlpha);
+void gl4_3core_glBlendFunci(void *_glfuncs, GLuint buf, GLenum src, GLenum dst);
+void gl4_3core_glBlendEquationSeparatei(void *_glfuncs, GLuint buf, GLenum modeRGB, GLenum modeAlpha);
+void gl4_3core_glBlendEquationi(void *_glfuncs, GLuint buf, GLenum mode);
+void gl4_3core_glMinSampleShading(void *_glfuncs, GLfloat value);
+void gl4_3core_glGetDoublei_v(void *_glfuncs, GLenum target, GLuint index, GLdouble* data);
+void gl4_3core_glGetFloati_v(void *_glfuncs, GLenum target, GLuint index, GLfloat* data);
+void gl4_3core_glDepthRangeIndexed(void *_glfuncs, GLuint index, GLdouble n, GLdouble f);
+void gl4_3core_glDepthRangeArrayv(void *_glfuncs, GLuint first, GLsizei count, const GLdouble* v);
+void gl4_3core_glScissorIndexedv(void *_glfuncs, GLuint index, const GLint* v);
+void gl4_3core_glScissorIndexed(void *_glfuncs, GLuint index, GLint left, GLint bottom, GLsizei width, GLsizei height);
+void gl4_3core_glScissorArrayv(void *_glfuncs, GLuint first, GLsizei count, const GLint* v);
+void gl4_3core_glViewportIndexedfv(void *_glfuncs, GLuint index, const GLfloat* v);
+void gl4_3core_glViewportIndexedf(void *_glfuncs, GLuint index, GLfloat x, GLfloat y, GLfloat w, GLfloat h);
+void gl4_3core_glViewportArrayv(void *_glfuncs, GLuint first, GLsizei count, const GLfloat* v);
+void gl4_3core_glGetVertexAttribLdv(void *_glfuncs, GLuint index, GLenum pname, GLdouble* params);
+void gl4_3core_glVertexAttribLPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLsizei stride, const GLvoid* pointer);
+void gl4_3core_glVertexAttribL4dv(void *_glfuncs, GLuint index, const GLdouble* v);
+void gl4_3core_glVertexAttribL3dv(void *_glfuncs, GLuint index, const GLdouble* v);
+void gl4_3core_glVertexAttribL2dv(void *_glfuncs, GLuint index, const GLdouble* v);
+void gl4_3core_glVertexAttribL1dv(void *_glfuncs, GLuint index, const GLdouble* v);
+void gl4_3core_glVertexAttribL4d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+void gl4_3core_glVertexAttribL3d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y, GLdouble z);
+void gl4_3core_glVertexAttribL2d(void *_glfuncs, GLuint index, GLdouble x, GLdouble y);
+void gl4_3core_glVertexAttribL1d(void *_glfuncs, GLuint index, GLdouble x);
+void gl4_3core_glGetProgramPipelineInfoLog(void *_glfuncs, GLuint pipeline, GLsizei bufSize, GLsizei* length, GLchar* infoLog);
+void gl4_3core_glValidateProgramPipeline(void *_glfuncs, GLuint pipeline);
+void gl4_3core_glProgramUniformMatrix4x3dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_3core_glProgramUniformMatrix3x4dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_3core_glProgramUniformMatrix4x2dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_3core_glProgramUniformMatrix2x4dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_3core_glProgramUniformMatrix3x2dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_3core_glProgramUniformMatrix2x3dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_3core_glProgramUniformMatrix4x3fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_3core_glProgramUniformMatrix3x4fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_3core_glProgramUniformMatrix4x2fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_3core_glProgramUniformMatrix2x4fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_3core_glProgramUniformMatrix3x2fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_3core_glProgramUniformMatrix2x3fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_3core_glProgramUniformMatrix4dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_3core_glProgramUniformMatrix3dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_3core_glProgramUniformMatrix2dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLdouble* value);
+void gl4_3core_glProgramUniformMatrix4fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_3core_glProgramUniformMatrix3fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_3core_glProgramUniformMatrix2fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gl4_3core_glProgramUniform4uiv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLuint* value);
+void gl4_3core_glProgramUniform4ui(void *_glfuncs, GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2, GLuint v3);
+void gl4_3core_glProgramUniform4dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLdouble* value);
+void gl4_3core_glProgramUniform4d(void *_glfuncs, GLuint program, GLint location, GLdouble v0, GLdouble v1, GLdouble v2, GLdouble v3);
+void gl4_3core_glProgramUniform4fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLfloat* value);
+void gl4_3core_glProgramUniform4f(void *_glfuncs, GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3);
+void gl4_3core_glProgramUniform4iv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLint* value);
+void gl4_3core_glProgramUniform4i(void *_glfuncs, GLuint program, GLint location, GLint v0, GLint v1, GLint v2, GLint v3);
+void gl4_3core_glProgramUniform3uiv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLuint* value);
+void gl4_3core_glProgramUniform3ui(void *_glfuncs, GLuint program, GLint location, GLuint v0, GLuint v1, GLuint v2);
+void gl4_3core_glProgramUniform3dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLdouble* value);
+void gl4_3core_glProgramUniform3d(void *_glfuncs, GLuint program, GLint location, GLdouble v0, GLdouble v1, GLdouble v2);
+void gl4_3core_glProgramUniform3fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLfloat* value);
+void gl4_3core_glProgramUniform3f(void *_glfuncs, GLuint program, GLint location, GLfloat v0, GLfloat v1, GLfloat v2);
+void gl4_3core_glProgramUniform3iv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLint* value);
+void gl4_3core_glProgramUniform3i(void *_glfuncs, GLuint program, GLint location, GLint v0, GLint v1, GLint v2);
+void gl4_3core_glProgramUniform2uiv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLuint* value);
+void gl4_3core_glProgramUniform2ui(void *_glfuncs, GLuint program, GLint location, GLuint v0, GLuint v1);
+void gl4_3core_glProgramUniform2dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLdouble* value);
+void gl4_3core_glProgramUniform2d(void *_glfuncs, GLuint program, GLint location, GLdouble v0, GLdouble v1);
+void gl4_3core_glProgramUniform2fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLfloat* value);
+void gl4_3core_glProgramUniform2f(void *_glfuncs, GLuint program, GLint location, GLfloat v0, GLfloat v1);
+void gl4_3core_glProgramUniform2iv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLint* value);
+void gl4_3core_glProgramUniform2i(void *_glfuncs, GLuint program, GLint location, GLint v0, GLint v1);
+void gl4_3core_glProgramUniform1uiv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLuint* value);
+void gl4_3core_glProgramUniform1ui(void *_glfuncs, GLuint program, GLint location, GLuint v0);
+void gl4_3core_glProgramUniform1dv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLdouble* value);
+void gl4_3core_glProgramUniform1d(void *_glfuncs, GLuint program, GLint location, GLdouble v0);
+void gl4_3core_glProgramUniform1fv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLfloat* value);
+void gl4_3core_glProgramUniform1f(void *_glfuncs, GLuint program, GLint location, GLfloat v0);
+void gl4_3core_glProgramUniform1iv(void *_glfuncs, GLuint program, GLint location, GLsizei count, const GLint* value);
+void gl4_3core_glProgramUniform1i(void *_glfuncs, GLuint program, GLint location, GLint v0);
+void gl4_3core_glGetProgramPipelineiv(void *_glfuncs, GLuint pipeline, GLenum pname, GLint* params);
+GLboolean gl4_3core_glIsProgramPipeline(void *_glfuncs, GLuint pipeline);
+void gl4_3core_glGenProgramPipelines(void *_glfuncs, GLsizei n, GLuint* pipelines);
+void gl4_3core_glDeleteProgramPipelines(void *_glfuncs, GLsizei n, const GLuint* pipelines);
+void gl4_3core_glBindProgramPipeline(void *_glfuncs, GLuint pipeline);
+void gl4_3core_glActiveShaderProgram(void *_glfuncs, GLuint pipeline, GLuint program);
+void gl4_3core_glUseProgramStages(void *_glfuncs, GLuint pipeline, GLbitfield stages, GLuint program);
+void gl4_3core_glProgramParameteri(void *_glfuncs, GLuint program, GLenum pname, GLint value);
+void gl4_3core_glProgramBinary(void *_glfuncs, GLuint program, GLenum binaryFormat, const GLvoid* binary, GLsizei length);
+void gl4_3core_glGetProgramBinary(void *_glfuncs, GLuint program, GLsizei bufSize, GLsizei* length, GLenum* binaryFormat, GLvoid* binary);
+void gl4_3core_glClearDepthf(void *_glfuncs, GLfloat dd);
+void gl4_3core_glDepthRangef(void *_glfuncs, GLfloat n, GLfloat f);
+void gl4_3core_glGetShaderPrecisionFormat(void *_glfuncs, GLenum shadertype, GLenum precisionType, GLint* range_, GLint* precision);
+void gl4_3core_glShaderBinary(void *_glfuncs, GLsizei count, const GLuint* shaders, GLenum binaryFormat, const GLvoid* binary, GLsizei length);
+void gl4_3core_glReleaseShaderCompiler(void *_glfuncs);
+void gl4_3core_glTexStorage3D(void *_glfuncs, GLenum target, GLsizei levels, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth);
+void gl4_3core_glTexStorage2D(void *_glfuncs, GLenum target, GLsizei levels, GLenum internalFormat, GLsizei width, GLsizei height);
+void gl4_3core_glTexStorage1D(void *_glfuncs, GLenum target, GLsizei levels, GLenum internalFormat, GLsizei width);
+void gl4_3core_glMemoryBarrier(void *_glfuncs, GLbitfield barriers);
+void gl4_3core_glBindImageTexture(void *_glfuncs, GLuint unit, GLuint texture, GLint level, GLboolean layered, GLint layer, GLenum access, GLenum format);
+void gl4_3core_glGetActiveAtomicCounterBufferiv(void *_glfuncs, GLuint program, GLuint bufferIndex, GLenum pname, GLint* params);
+void gl4_3core_glGetInternalformativ(void *_glfuncs, GLenum target, GLenum internalFormat, GLenum pname, GLsizei bufSize, GLint* params);
+void gl4_3core_glDrawTransformFeedbackStreamInstanced(void *_glfuncs, GLenum mode, GLuint id, GLuint stream, GLsizei instancecount);
+void gl4_3core_glDrawTransformFeedbackInstanced(void *_glfuncs, GLenum mode, GLuint id, GLsizei instancecount);
+void gl4_3core_glDrawElementsInstancedBaseVertexBaseInstance(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount, GLint basevertex, GLuint baseinstance);
+void gl4_3core_glDrawElementsInstancedBaseInstance(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices, GLsizei instancecount, GLuint baseinstance);
+void gl4_3core_glDrawArraysInstancedBaseInstance(void *_glfuncs, GLenum mode, GLint first, GLsizei count, GLsizei instancecount, GLuint baseinstance);
+void gl4_3core_glTexStorage3DMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLenum internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLboolean fixedsamplelocations);
+void gl4_3core_glTexStorage2DMultisample(void *_glfuncs, GLenum target, GLsizei samples, GLenum internalFormat, GLsizei width, GLsizei height, GLboolean fixedsamplelocations);
+void gl4_3core_glTexBufferRange(void *_glfuncs, GLenum target, GLenum internalFormat, GLuint buffer, GLintptr offset, GLsizeiptr size);
+void gl4_3core_glShaderStorageBlockBinding(void *_glfuncs, GLuint program, GLuint storageBlockIndex, GLuint storageBlockBinding);
+GLint gl4_3core_glGetProgramResourceLocationIndex(void *_glfuncs, GLuint program, GLenum programInterface, const GLchar* name);
+GLint gl4_3core_glGetProgramResourceLocation(void *_glfuncs, GLuint program, GLenum programInterface, const GLchar* name);
+void gl4_3core_glGetProgramResourceiv(void *_glfuncs, GLuint program, GLenum programInterface, GLuint index, GLsizei propCount, const GLenum* props, GLsizei bufSize, GLsizei* length, GLint* params);
+void gl4_3core_glGetProgramResourceName(void *_glfuncs, GLuint program, GLenum programInterface, GLuint index, GLsizei bufSize, GLsizei* length, GLchar* name);
+GLuint gl4_3core_glGetProgramResourceIndex(void *_glfuncs, GLuint program, GLenum programInterface, const GLchar* name);
+void gl4_3core_glGetProgramInterfaceiv(void *_glfuncs, GLuint program, GLenum programInterface, GLenum pname, GLint* params);
+void gl4_3core_glMultiDrawElementsIndirect(void *_glfuncs, GLenum mode, GLenum gltype, const GLvoid* indirect, GLsizei drawcount, GLsizei stride);
+void gl4_3core_glMultiDrawArraysIndirect(void *_glfuncs, GLenum mode, const GLvoid* indirect, GLsizei drawcount, GLsizei stride);
+void gl4_3core_glInvalidateSubFramebuffer(void *_glfuncs, GLenum target, GLsizei numAttachments, const GLenum* attachments, GLint x, GLint y, GLsizei width, GLsizei height);
+void gl4_3core_glInvalidateFramebuffer(void *_glfuncs, GLenum target, GLsizei numAttachments, const GLenum* attachments);
+void gl4_3core_glInvalidateBufferData(void *_glfuncs, GLuint buffer);
+void gl4_3core_glInvalidateBufferSubData(void *_glfuncs, GLuint buffer, GLintptr offset, GLsizeiptr length);
+void gl4_3core_glInvalidateTexImage(void *_glfuncs, GLuint texture, GLint level);
+void gl4_3core_glInvalidateTexSubImage(void *_glfuncs, GLuint texture, GLint level, GLint xoffset, GLint yoffset, GLint zoffset, GLsizei width, GLsizei height, GLsizei depth);
+void gl4_3core_glGetInternalformati64v(void *_glfuncs, GLenum target, GLenum internalFormat, GLenum pname, GLsizei bufSize, GLint64* params);
+void gl4_3core_glGetFramebufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gl4_3core_glFramebufferParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint param);
+void gl4_3core_glVertexBindingDivisor(void *_glfuncs, GLuint bindingindex, GLuint divisor);
+void gl4_3core_glVertexAttribBinding(void *_glfuncs, GLuint attribindex, GLuint bindingindex);
+void gl4_3core_glVertexAttribLFormat(void *_glfuncs, GLuint attribindex, GLint size, GLenum gltype, GLuint relativeoffset);
+void gl4_3core_glVertexAttribIFormat(void *_glfuncs, GLuint attribindex, GLint size, GLenum gltype, GLuint relativeoffset);
+void gl4_3core_glVertexAttribFormat(void *_glfuncs, GLuint attribindex, GLint size, GLenum gltype, GLboolean normalized, GLuint relativeoffset);
+void gl4_3core_glBindVertexBuffer(void *_glfuncs, GLuint bindingindex, GLuint buffer, GLintptr offset, GLsizei stride);
+void gl4_3core_glTextureView(void *_glfuncs, GLuint texture, GLenum target, GLuint origtexture, GLenum internalFormat, GLuint minlevel, GLuint numlevels, GLuint minlayer, GLuint numlayers);
+void gl4_3core_glCopyImageSubData(void *_glfuncs, GLuint srcName, GLenum srcTarget, GLint srcLevel, GLint srcX, GLint srcY, GLint srcZ, GLuint dstName, GLenum dstTarget, GLint dstLevel, GLint dstX, GLint dstY, GLint dstZ, GLsizei srcWidth, GLsizei srcHeight, GLsizei srcDepth);
+void gl4_3core_glDispatchComputeIndirect(void *_glfuncs, GLintptr indirect);
+void gl4_3core_glDispatchCompute(void *_glfuncs, GLuint num_groups_x, GLuint num_groups_y, GLuint num_groups_z);
+void gl4_3core_glClearBufferSubData(void *_glfuncs, GLenum target, GLenum internalFormat, GLintptr offset, GLsizeiptr size, GLenum format, GLenum gltype, const GLvoid* data);
+void gl4_3core_glClearBufferData(void *_glfuncs, GLenum target, GLenum internalFormat, GLenum format, GLenum gltype, const GLvoid* data);
+
+
+#ifdef __cplusplus
+} // extern "C"
+#endif
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.3core/gl.go b/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.3core/gl.go
new file mode 100644
index 000000000..76df4604f
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/4.3core/gl.go
@@ -0,0 +1,7052 @@
+// ** file automatically generated by glgen -- do not edit manually **
+
+package GL
+
+// #cgo CXXFLAGS: -std=c++0x -pedantic-errors -Wall -fno-strict-aliasing
+// #cgo LDFLAGS: -lstdc++
+// #cgo pkg-config: Qt5Core Qt5OpenGL
+//
+// #include "funcs.h"
+//
+// void free(void*);
+//
+import "C"
+
+import (
+ "fmt"
+ "reflect"
+ "unsafe"
+
+ "gopkg.in/qml.v1/gl/glbase"
+)
+
+// API returns a value that offers methods matching the OpenGL version 4.3 API.
+//
+// The returned API must not be used after the provided OpenGL context becomes invalid.
+func API(context glbase.Contexter) *GL {
+ gl := &GL{}
+ gl.funcs = C.gl4_3core_funcs()
+ if gl.funcs == nil {
+ panic(fmt.Errorf("OpenGL version 4.3 is not available"))
+ }
+ return gl
+}
+
+// GL implements the OpenGL version 4.3 API. Values of this
+// type must be created via the API function, and it must not be used after
+// the associated OpenGL context becomes invalid.
+type GL struct {
+ funcs unsafe.Pointer
+}
+
+const (
+ FALSE = 0
+ TRUE = 1
+ NONE = 0
+
+ BYTE = 0x1400
+ UNSIGNED_BYTE = 0x1401
+ SHORT = 0x1402
+ UNSIGNED_SHORT = 0x1403
+ INT = 0x1404
+ UNSIGNED_INT = 0x1405
+ FLOAT = 0x1406
+ N2_BYTES = 0x1407
+ N3_BYTES = 0x1408
+ N4_BYTES = 0x1409
+ DOUBLE = 0x140A
+ HALF_FLOAT = 0x140B
+ FIXED = 0x140C
+
+ ACCUM = 0x0100
+ LOAD = 0x0101
+ RETURN = 0x0102
+ MULT = 0x0103
+ ADD = 0x0104
+
+ ACCUM_BUFFER_BIT = 0x00000200
+ ALL_ATTRIB_BITS = 0xFFFFFFFF
+ COLOR_BUFFER_BIT = 0x00004000
+ CURRENT_BIT = 0x00000001
+ DEPTH_BUFFER_BIT = 0x00000100
+ ENABLE_BIT = 0x00002000
+ EVAL_BIT = 0x00010000
+ FOG_BIT = 0x00000080
+ HINT_BIT = 0x00008000
+ LIGHTING_BIT = 0x00000040
+ LINE_BIT = 0x00000004
+ LIST_BIT = 0x00020000
+ MULTISAMPLE_BIT = 0x20000000
+ PIXEL_MODE_BIT = 0x00000020
+ POINT_BIT = 0x00000002
+ POLYGON_BIT = 0x00000008
+ POLYGON_STIPPLE_BIT = 0x00000010
+ SCISSOR_BIT = 0x00080000
+ STENCIL_BUFFER_BIT = 0x00000400
+ TEXTURE_BIT = 0x00040000
+ TRANSFORM_BIT = 0x00001000
+ VIEWPORT_BIT = 0x00000800
+
+ ALWAYS = 0x0207
+ EQUAL = 0x0202
+ GEQUAL = 0x0206
+ GREATER = 0x0204
+ LEQUAL = 0x0203
+ LESS = 0x0201
+ NEVER = 0x0200
+ NOTEQUAL = 0x0205
+
+ LOGIC_OP = 0x0BF1
+
+ DST_ALPHA = 0x0304
+ ONE = 1
+ ONE_MINUS_DST_ALPHA = 0x0305
+ ONE_MINUS_SRC_ALPHA = 0x0303
+ ONE_MINUS_SRC_COLOR = 0x0301
+ SRC_ALPHA = 0x0302
+ SRC_COLOR = 0x0300
+ ZERO = 0
+
+ DST_COLOR = 0x0306
+ ONE_MINUS_DST_COLOR = 0x0307
+ SRC_ALPHA_SATURATE = 0x0308
+
+ CLIENT_ALL_ATTRIB_BITS = 0xFFFFFFFF
+ CLIENT_PIXEL_STORE_BIT = 0x00000001
+ CLIENT_VERTEX_ARRAY_BIT = 0x00000002
+
+ CLIP_DISTANCE0 = 0x3000
+ CLIP_DISTANCE1 = 0x3001
+ CLIP_DISTANCE2 = 0x3002
+ CLIP_DISTANCE3 = 0x3003
+ CLIP_DISTANCE4 = 0x3004
+ CLIP_DISTANCE5 = 0x3005
+ CLIP_DISTANCE6 = 0x3006
+ CLIP_DISTANCE7 = 0x3007
+ CLIP_PLANE0 = 0x3000
+ CLIP_PLANE1 = 0x3001
+ CLIP_PLANE2 = 0x3002
+ CLIP_PLANE3 = 0x3003
+ CLIP_PLANE4 = 0x3004
+ CLIP_PLANE5 = 0x3005
+
+ BACK = 0x0405
+ FRONT = 0x0404
+ FRONT_AND_BACK = 0x0408
+
+ AMBIENT = 0x1200
+ AMBIENT_AND_DIFFUSE = 0x1602
+ DIFFUSE = 0x1201
+ EMISSION = 0x1600
+ SPECULAR = 0x1202
+
+ CONTEXT_FLAG_DEBUG_BIT = 0x00000002
+ CONTEXT_FLAG_FORWARD_COMPATIBLE_BIT = 0x00000001
+
+ CONTEXT_COMPATIBILITY_PROFILE_BIT = 0x00000002
+ CONTEXT_CORE_PROFILE_BIT = 0x00000001
+
+ AUX0 = 0x0409
+ AUX1 = 0x040A
+ AUX2 = 0x040B
+ AUX3 = 0x040C
+ BACK_LEFT = 0x0402
+ BACK_RIGHT = 0x0403
+ FRONT_LEFT = 0x0400
+ FRONT_RIGHT = 0x0401
+ LEFT = 0x0406
+ RIGHT = 0x0407
+
+ ALPHA_TEST = 0x0BC0
+ AUTO_NORMAL = 0x0D80
+ BLEND = 0x0BE2
+ COLOR_ARRAY = 0x8076
+ COLOR_LOGIC_OP = 0x0BF2
+ COLOR_MATERIAL = 0x0B57
+ CULL_FACE = 0x0B44
+ DEPTH_TEST = 0x0B71
+ DITHER = 0x0BD0
+ EDGE_FLAG_ARRAY = 0x8079
+ FOG = 0x0B60
+ INDEX_ARRAY = 0x8077
+ INDEX_LOGIC_OP = 0x0BF1
+ LIGHT0 = 0x4000
+ LIGHT1 = 0x4001
+ LIGHT2 = 0x4002
+ LIGHT3 = 0x4003
+ LIGHT4 = 0x4004
+ LIGHT5 = 0x4005
+ LIGHT6 = 0x4006
+ LIGHT7 = 0x4007
+ LIGHTING = 0x0B50
+ LINE_SMOOTH = 0x0B20
+ LINE_STIPPLE = 0x0B24
+ MAP1_COLOR_4 = 0x0D90
+ MAP1_INDEX = 0x0D91
+ MAP1_NORMAL = 0x0D92
+ MAP1_TEXTURE_COORD_1 = 0x0D93
+ MAP1_TEXTURE_COORD_2 = 0x0D94
+ MAP1_TEXTURE_COORD_3 = 0x0D95
+ MAP1_TEXTURE_COORD_4 = 0x0D96
+ MAP1_VERTEX_3 = 0x0D97
+ MAP1_VERTEX_4 = 0x0D98
+ MAP2_COLOR_4 = 0x0DB0
+ MAP2_INDEX = 0x0DB1
+ MAP2_NORMAL = 0x0DB2
+ MAP2_TEXTURE_COORD_1 = 0x0DB3
+ MAP2_TEXTURE_COORD_2 = 0x0DB4
+ MAP2_TEXTURE_COORD_3 = 0x0DB5
+ MAP2_TEXTURE_COORD_4 = 0x0DB6
+ MAP2_VERTEX_3 = 0x0DB7
+ MAP2_VERTEX_4 = 0x0DB8
+ NORMALIZE = 0x0BA1
+ NORMAL_ARRAY = 0x8075
+ POINT_SMOOTH = 0x0B10
+ POLYGON_OFFSET_FILL = 0x8037
+ POLYGON_OFFSET_LINE = 0x2A02
+ POLYGON_OFFSET_POINT = 0x2A01
+ POLYGON_SMOOTH = 0x0B41
+ POLYGON_STIPPLE = 0x0B42
+ SCISSOR_TEST = 0x0C11
+ STENCIL_TEST = 0x0B90
+ TEXTURE_1D = 0x0DE0
+ TEXTURE_2D = 0x0DE1
+ TEXTURE_COORD_ARRAY = 0x8078
+ TEXTURE_GEN_Q = 0x0C63
+ TEXTURE_GEN_R = 0x0C62
+ TEXTURE_GEN_S = 0x0C60
+ TEXTURE_GEN_T = 0x0C61
+ VERTEX_ARRAY = 0x8074
+
+ INVALID_ENUM = 0x0500
+ INVALID_FRAMEBUFFER_OPERATION = 0x0506
+ INVALID_OPERATION = 0x0502
+ INVALID_VALUE = 0x0501
+ NO_ERROR = 0
+ OUT_OF_MEMORY = 0x0505
+ STACK_OVERFLOW = 0x0503
+ STACK_UNDERFLOW = 0x0504
+
+ N2D = 0x0600
+ N3D = 0x0601
+ N3D_COLOR = 0x0602
+ N3D_COLOR_TEXTURE = 0x0603
+ N4D_COLOR_TEXTURE = 0x0604
+
+ BITMAP_TOKEN = 0x0704
+ COPY_PIXEL_TOKEN = 0x0706
+ DRAW_PIXEL_TOKEN = 0x0705
+ LINE_RESET_TOKEN = 0x0707
+ LINE_TOKEN = 0x0702
+ PASS_THROUGH_TOKEN = 0x0700
+ POINT_TOKEN = 0x0701
+ POLYGON_TOKEN = 0x0703
+
+ EXP = 0x0800
+ EXP2 = 0x0801
+ LINEAR = 0x2601
+
+ FOG_COLOR = 0x0B66
+ FOG_DENSITY = 0x0B62
+ FOG_END = 0x0B64
+ FOG_INDEX = 0x0B61
+ FOG_MODE = 0x0B65
+ FOG_START = 0x0B63
+
+ CCW = 0x0901
+ CW = 0x0900
+
+ COEFF = 0x0A00
+ DOMAIN = 0x0A02
+ ORDER = 0x0A01
+
+ PIXEL_MAP_A_TO_A = 0x0C79
+ PIXEL_MAP_B_TO_B = 0x0C78
+ PIXEL_MAP_G_TO_G = 0x0C77
+ PIXEL_MAP_I_TO_A = 0x0C75
+ PIXEL_MAP_I_TO_B = 0x0C74
+ PIXEL_MAP_I_TO_G = 0x0C73
+ PIXEL_MAP_I_TO_I = 0x0C70
+ PIXEL_MAP_I_TO_R = 0x0C72
+ PIXEL_MAP_R_TO_R = 0x0C76
+ PIXEL_MAP_S_TO_S = 0x0C71
+
+ ACCUM_ALPHA_BITS = 0x0D5B
+ ACCUM_BLUE_BITS = 0x0D5A
+ ACCUM_CLEAR_VALUE = 0x0B80
+ ACCUM_GREEN_BITS = 0x0D59
+ ACCUM_RED_BITS = 0x0D58
+ ALIASED_LINE_WIDTH_RANGE = 0x846E
+ ALIASED_POINT_SIZE_RANGE = 0x846D
+ ALPHA_BIAS = 0x0D1D
+ ALPHA_BITS = 0x0D55
+ ALPHA_SCALE = 0x0D1C
+ ALPHA_TEST_FUNC = 0x0BC1
+ ALPHA_TEST_REF = 0x0BC2
+ ATTRIB_STACK_DEPTH = 0x0BB0
+ AUX_BUFFERS = 0x0C00
+ BLEND_DST = 0x0BE0
+ BLEND_SRC = 0x0BE1
+ BLUE_BIAS = 0x0D1B
+ BLUE_BITS = 0x0D54
+ BLUE_SCALE = 0x0D1A
+ CLIENT_ATTRIB_STACK_DEPTH = 0x0BB1
+ COLOR_ARRAY_SIZE = 0x8081
+ COLOR_ARRAY_STRIDE = 0x8083
+ COLOR_ARRAY_TYPE = 0x8082
+ COLOR_CLEAR_VALUE = 0x0C22
+ COLOR_MATERIAL_FACE = 0x0B55
+ COLOR_MATERIAL_PARAMETER = 0x0B56
+ COLOR_WRITEMASK = 0x0C23
+ CULL_FACE_MODE = 0x0B45
+ CURRENT_COLOR = 0x0B00
+ CURRENT_INDEX = 0x0B01
+ CURRENT_NORMAL = 0x0B02
+ CURRENT_RASTER_COLOR = 0x0B04
+ CURRENT_RASTER_DISTANCE = 0x0B09
+ CURRENT_RASTER_INDEX = 0x0B05
+ CURRENT_RASTER_POSITION = 0x0B07
+ CURRENT_RASTER_POSITION_VALID = 0x0B08
+ CURRENT_RASTER_TEXTURE_COORDS = 0x0B06
+ CURRENT_TEXTURE_COORDS = 0x0B03
+ DEPTH_BIAS = 0x0D1F
+ DEPTH_BITS = 0x0D56
+ DEPTH_CLEAR_VALUE = 0x0B73
+ DEPTH_FUNC = 0x0B74
+ DEPTH_RANGE = 0x0B70
+ DEPTH_SCALE = 0x0D1E
+ DEPTH_WRITEMASK = 0x0B72
+ DOUBLEBUFFER = 0x0C32
+ DRAW_BUFFER = 0x0C01
+ EDGE_FLAG = 0x0B43
+ EDGE_FLAG_ARRAY_STRIDE = 0x808C
+ FEEDBACK_BUFFER_SIZE = 0x0DF1
+ FEEDBACK_BUFFER_TYPE = 0x0DF2
+ FOG_HINT = 0x0C54
+ FRONT_FACE = 0x0B46
+ GREEN_BIAS = 0x0D19
+ GREEN_BITS = 0x0D53
+ GREEN_SCALE = 0x0D18
+ INDEX_ARRAY_STRIDE = 0x8086
+ INDEX_ARRAY_TYPE = 0x8085
+ INDEX_BITS = 0x0D51
+ INDEX_CLEAR_VALUE = 0x0C20
+ INDEX_MODE = 0x0C30
+ INDEX_OFFSET = 0x0D13
+ INDEX_SHIFT = 0x0D12
+ INDEX_WRITEMASK = 0x0C21
+ LIGHT_MODEL_AMBIENT = 0x0B53
+ LIGHT_MODEL_COLOR_CONTROL = 0x81F8
+ LIGHT_MODEL_LOCAL_VIEWER = 0x0B51
+ LIGHT_MODEL_TWO_SIDE = 0x0B52
+ LINE_SMOOTH_HINT = 0x0C52
+ LINE_STIPPLE_PATTERN = 0x0B25
+ LINE_STIPPLE_REPEAT = 0x0B26
+ LINE_WIDTH = 0x0B21
+ LINE_WIDTH_GRANULARITY = 0x0B23
+ LINE_WIDTH_RANGE = 0x0B22
+ LIST_BASE = 0x0B32
+ LIST_INDEX = 0x0B33
+ LIST_MODE = 0x0B30
+ LOGIC_OP_MODE = 0x0BF0
+ MAP1_GRID_DOMAIN = 0x0DD0
+ MAP1_GRID_SEGMENTS = 0x0DD1
+ MAP2_GRID_DOMAIN = 0x0DD2
+ MAP2_GRID_SEGMENTS = 0x0DD3
+ MAP_COLOR = 0x0D10
+ MAP_STENCIL = 0x0D11
+ MATRIX_MODE = 0x0BA0
+ MAX_ATTRIB_STACK_DEPTH = 0x0D35
+ MAX_CLIENT_ATTRIB_STACK_DEPTH = 0x0D3B
+ MAX_CLIP_DISTANCES = 0x0D32
+ MAX_CLIP_PLANES = 0x0D32
+ MAX_EVAL_ORDER = 0x0D30
+ MAX_LIGHTS = 0x0D31
+ MAX_LIST_NESTING = 0x0B31
+ MAX_MODELVIEW_STACK_DEPTH = 0x0D36
+ MAX_NAME_STACK_DEPTH = 0x0D37
+ MAX_PIXEL_MAP_TABLE = 0x0D34
+ MAX_PROJECTION_STACK_DEPTH = 0x0D38
+ MAX_TEXTURE_SIZE = 0x0D33
+ MAX_TEXTURE_STACK_DEPTH = 0x0D39
+ MAX_VIEWPORT_DIMS = 0x0D3A
+ MODELVIEW_MATRIX = 0x0BA6
+ MODELVIEW_STACK_DEPTH = 0x0BA3
+ NAME_STACK_DEPTH = 0x0D70
+ NORMAL_ARRAY_STRIDE = 0x807F
+ NORMAL_ARRAY_TYPE = 0x807E
+ PACK_ALIGNMENT = 0x0D05
+ PACK_LSB_FIRST = 0x0D01
+ PACK_ROW_LENGTH = 0x0D02
+ PACK_SKIP_PIXELS = 0x0D04
+ PACK_SKIP_ROWS = 0x0D03
+ PACK_SWAP_BYTES = 0x0D00
+ PERSPECTIVE_CORRECTION_HINT = 0x0C50
+ PIXEL_MAP_A_TO_A_SIZE = 0x0CB9
+ PIXEL_MAP_B_TO_B_SIZE = 0x0CB8
+ PIXEL_MAP_G_TO_G_SIZE = 0x0CB7
+ PIXEL_MAP_I_TO_A_SIZE = 0x0CB5
+ PIXEL_MAP_I_TO_B_SIZE = 0x0CB4
+ PIXEL_MAP_I_TO_G_SIZE = 0x0CB3
+ PIXEL_MAP_I_TO_I_SIZE = 0x0CB0
+ PIXEL_MAP_I_TO_R_SIZE = 0x0CB2
+ PIXEL_MAP_R_TO_R_SIZE = 0x0CB6
+ PIXEL_MAP_S_TO_S_SIZE = 0x0CB1
+ POINT_SIZE = 0x0B11
+ POINT_SIZE_GRANULARITY = 0x0B13
+ POINT_SIZE_RANGE = 0x0B12
+ POINT_SMOOTH_HINT = 0x0C51
+ POLYGON_MODE = 0x0B40
+ POLYGON_OFFSET_FACTOR = 0x8038
+ POLYGON_OFFSET_UNITS = 0x2A00
+ POLYGON_SMOOTH_HINT = 0x0C53
+ PROJECTION_MATRIX = 0x0BA7
+ PROJECTION_STACK_DEPTH = 0x0BA4
+ READ_BUFFER = 0x0C02
+ RED_BIAS = 0x0D15
+ RED_BITS = 0x0D52
+ RED_SCALE = 0x0D14
+ RENDER_MODE = 0x0C40
+ RGBA_MODE = 0x0C31
+ SCISSOR_BOX = 0x0C10
+ SELECTION_BUFFER_SIZE = 0x0DF4
+ SHADE_MODEL = 0x0B54
+ SMOOTH_LINE_WIDTH_GRANULARITY = 0x0B23
+ SMOOTH_LINE_WIDTH_RANGE = 0x0B22
+ SMOOTH_POINT_SIZE_GRANULARITY = 0x0B13
+ SMOOTH_POINT_SIZE_RANGE = 0x0B12
+ STENCIL_BITS = 0x0D57
+ STENCIL_CLEAR_VALUE = 0x0B91
+ STENCIL_FAIL = 0x0B94
+ STENCIL_FUNC = 0x0B92
+ STENCIL_PASS_DEPTH_FAIL = 0x0B95
+ STENCIL_PASS_DEPTH_PASS = 0x0B96
+ STENCIL_REF = 0x0B97
+ STENCIL_VALUE_MASK = 0x0B93
+ STENCIL_WRITEMASK = 0x0B98
+ STEREO = 0x0C33
+ SUBPIXEL_BITS = 0x0D50
+ TEXTURE_BINDING_1D = 0x8068
+ TEXTURE_BINDING_2D = 0x8069
+ TEXTURE_BINDING_3D = 0x806A
+ TEXTURE_COORD_ARRAY_SIZE = 0x8088
+ TEXTURE_COORD_ARRAY_STRIDE = 0x808A
+ TEXTURE_COORD_ARRAY_TYPE = 0x8089
+ TEXTURE_MATRIX = 0x0BA8
+ TEXTURE_STACK_DEPTH = 0x0BA5
+ UNPACK_ALIGNMENT = 0x0CF5
+ UNPACK_LSB_FIRST = 0x0CF1
+ UNPACK_ROW_LENGTH = 0x0CF2
+ UNPACK_SKIP_PIXELS = 0x0CF4
+ UNPACK_SKIP_ROWS = 0x0CF3
+ UNPACK_SWAP_BYTES = 0x0CF0
+ VERTEX_ARRAY_SIZE = 0x807A
+ VERTEX_ARRAY_STRIDE = 0x807C
+ VERTEX_ARRAY_TYPE = 0x807B
+ VIEWPORT = 0x0BA2
+ ZOOM_X = 0x0D16
+ ZOOM_Y = 0x0D17
+
+ COLOR_ARRAY_POINTER = 0x8090
+ EDGE_FLAG_ARRAY_POINTER = 0x8093
+ FEEDBACK_BUFFER_POINTER = 0x0DF0
+ INDEX_ARRAY_POINTER = 0x8091
+ NORMAL_ARRAY_POINTER = 0x808F
+ SELECTION_BUFFER_POINTER = 0x0DF3
+ TEXTURE_COORD_ARRAY_POINTER = 0x8092
+ VERTEX_ARRAY_POINTER = 0x808E
+
+ TEXTURE_ALPHA_SIZE = 0x805F
+ TEXTURE_BLUE_SIZE = 0x805E
+ TEXTURE_BORDER = 0x1005
+ TEXTURE_BORDER_COLOR = 0x1004
+ TEXTURE_COMPONENTS = 0x1003
+ TEXTURE_GREEN_SIZE = 0x805D
+ TEXTURE_HEIGHT = 0x1001
+ TEXTURE_INTENSITY_SIZE = 0x8061
+ TEXTURE_INTERNAL_FORMAT = 0x1003
+ TEXTURE_LUMINANCE_SIZE = 0x8060
+ TEXTURE_MAG_FILTER = 0x2800
+ TEXTURE_MIN_FILTER = 0x2801
+ TEXTURE_PRIORITY = 0x8066
+ TEXTURE_RED_SIZE = 0x805C
+ TEXTURE_RESIDENT = 0x8067
+ TEXTURE_WIDTH = 0x1000
+ TEXTURE_WRAP_S = 0x2802
+ TEXTURE_WRAP_T = 0x2803
+
+ DONT_CARE = 0x1100
+ FASTEST = 0x1101
+ NICEST = 0x1102
+
+ FRAGMENT_SHADER_DERIVATIVE_HINT = 0x8B8B
+ GENERATE_MIPMAP_HINT = 0x8192
+ PROGRAM_BINARY_RETRIEVABLE_HINT = 0x8257
+ TEXTURE_COMPRESSION_HINT = 0x84EF
+
+ C3F_V3F = 0x2A24
+ C4F_N3F_V3F = 0x2A26
+ C4UB_V2F = 0x2A22
+ C4UB_V3F = 0x2A23
+ N3F_V3F = 0x2A25
+ T2F_C3F_V3F = 0x2A2A
+ T2F_C4F_N3F_V3F = 0x2A2C
+ T2F_C4UB_V3F = 0x2A29
+ T2F_N3F_V3F = 0x2A2B
+ T2F_V3F = 0x2A27
+ T4F_C4F_N3F_V4F = 0x2A2D
+ T4F_V4F = 0x2A28
+ V2F = 0x2A20
+ V3F = 0x2A21
+
+ MODULATE = 0x2100
+ REPLACE = 0x1E01
+
+ SEPARATE_SPECULAR_COLOR = 0x81FA
+ SINGLE_COLOR = 0x81F9
+
+ CONSTANT_ATTENUATION = 0x1207
+ LINEAR_ATTENUATION = 0x1208
+ POSITION = 0x1203
+ QUADRATIC_ATTENUATION = 0x1209
+ SPOT_CUTOFF = 0x1206
+ SPOT_DIRECTION = 0x1204
+ SPOT_EXPONENT = 0x1205
+
+ COMPILE = 0x1300
+ COMPILE_AND_EXECUTE = 0x1301
+
+ AND = 0x1501
+ AND_INVERTED = 0x1504
+ AND_REVERSE = 0x1502
+ CLEAR = 0x1500
+ COPY = 0x1503
+ COPY_INVERTED = 0x150C
+ EQUIV = 0x1509
+ INVERT = 0x150A
+ NAND = 0x150E
+ NOOP = 0x1505
+ NOR = 0x1508
+ OR = 0x1507
+ OR_INVERTED = 0x150D
+ OR_REVERSE = 0x150B
+ SET = 0x150F
+ XOR = 0x1506
+
+ MAP_FLUSH_EXPLICIT_BIT = 0x0010
+ MAP_INVALIDATE_BUFFER_BIT = 0x0008
+ MAP_INVALIDATE_RANGE_BIT = 0x0004
+ MAP_READ_BIT = 0x0001
+ MAP_UNSYNCHRONIZED_BIT = 0x0020
+ MAP_WRITE_BIT = 0x0002
+
+ COLOR_INDEXES = 0x1603
+ SHININESS = 0x1601
+
+ MODELVIEW = 0x1700
+ PROJECTION = 0x1701
+ TEXTURE = 0x1702
+
+ ALL_BARRIER_BITS = 0xFFFFFFFF
+ ATOMIC_COUNTER_BARRIER_BIT = 0x00001000
+ BUFFER_UPDATE_BARRIER_BIT = 0x00000200
+ COMMAND_BARRIER_BIT = 0x00000040
+ ELEMENT_ARRAY_BARRIER_BIT = 0x00000002
+ FRAMEBUFFER_BARRIER_BIT = 0x00000400
+ PIXEL_BUFFER_BARRIER_BIT = 0x00000080
+ SHADER_IMAGE_ACCESS_BARRIER_BIT = 0x00000020
+ SHADER_STORAGE_BARRIER_BIT = 0x00002000
+ TEXTURE_FETCH_BARRIER_BIT = 0x00000008
+ TEXTURE_UPDATE_BARRIER_BIT = 0x00000100
+ TRANSFORM_FEEDBACK_BARRIER_BIT = 0x00000800
+ UNIFORM_BARRIER_BIT = 0x00000004
+ VERTEX_ATTRIB_ARRAY_BARRIER_BIT = 0x00000001
+
+ LINE = 0x1B01
+ POINT = 0x1B00
+
+ FILL = 0x1B02
+
+ COLOR = 0x1800
+ DEPTH = 0x1801
+ STENCIL = 0x1802
+
+ ALPHA = 0x1906
+ BLUE = 0x1905
+ COLOR_INDEX = 0x1900
+ DEPTH_COMPONENT = 0x1902
+ GREEN = 0x1904
+ LUMINANCE = 0x1909
+ LUMINANCE_ALPHA = 0x190A
+ RED = 0x1903
+ RGB = 0x1907
+ RGBA = 0x1908
+ STENCIL_INDEX = 0x1901
+
+ ALPHA12 = 0x803D
+ ALPHA16 = 0x803E
+ ALPHA4 = 0x803B
+ ALPHA8 = 0x803C
+ INTENSITY = 0x8049
+ INTENSITY12 = 0x804C
+ INTENSITY16 = 0x804D
+ INTENSITY4 = 0x804A
+ INTENSITY8 = 0x804B
+ LUMINANCE12 = 0x8041
+ LUMINANCE12_ALPHA12 = 0x8047
+ LUMINANCE12_ALPHA4 = 0x8046
+ LUMINANCE16 = 0x8042
+ LUMINANCE16_ALPHA16 = 0x8048
+ LUMINANCE4 = 0x803F
+ LUMINANCE4_ALPHA4 = 0x8043
+ LUMINANCE6_ALPHA2 = 0x8044
+ LUMINANCE8 = 0x8040
+ LUMINANCE8_ALPHA8 = 0x8045
+ R3_G3_B2 = 0x2A10
+ RGB10 = 0x8052
+ RGB10_A2 = 0x8059
+ RGB12 = 0x8053
+ RGB16 = 0x8054
+ RGB4 = 0x804F
+ RGB5 = 0x8050
+ RGB5_A1 = 0x8057
+ RGB8 = 0x8051
+ RGBA12 = 0x805A
+ RGBA16 = 0x805B
+ RGBA2 = 0x8055
+ RGBA4 = 0x8056
+ RGBA8 = 0x8058
+
+ PACK_IMAGE_HEIGHT = 0x806C
+ PACK_SKIP_IMAGES = 0x806B
+ UNPACK_IMAGE_HEIGHT = 0x806E
+ UNPACK_SKIP_IMAGES = 0x806D
+
+ BITMAP = 0x1A00
+ UNSIGNED_BYTE_3_3_2 = 0x8032
+ UNSIGNED_INT_10_10_10_2 = 0x8036
+ UNSIGNED_INT_8_8_8_8 = 0x8035
+ UNSIGNED_SHORT_4_4_4_4 = 0x8033
+ UNSIGNED_SHORT_5_5_5_1 = 0x8034
+
+ POINT_DISTANCE_ATTENUATION = 0x8129
+ POINT_FADE_THRESHOLD_SIZE = 0x8128
+ POINT_SIZE_MAX = 0x8127
+ POINT_SIZE_MIN = 0x8126
+
+ LINES = 0x0001
+ LINES_ADJACENCY = 0x000A
+ LINE_LOOP = 0x0002
+ LINE_STRIP = 0x0003
+ LINE_STRIP_ADJACENCY = 0x000B
+ PATCHES = 0x000E
+ POINTS = 0x0000
+ POLYGON = 0x0009
+ QUADS = 0x0007
+ QUAD_STRIP = 0x0008
+ TRIANGLES = 0x0004
+ TRIANGLES_ADJACENCY = 0x000C
+ TRIANGLE_FAN = 0x0006
+ TRIANGLE_STRIP = 0x0005
+ TRIANGLE_STRIP_ADJACENCY = 0x000D
+
+ FEEDBACK = 0x1C01
+ RENDER = 0x1C00
+ SELECT = 0x1C02
+
+ FLAT = 0x1D00
+ SMOOTH = 0x1D01
+
+ DECR = 0x1E03
+ INCR = 0x1E02
+ KEEP = 0x1E00
+
+ EXTENSIONS = 0x1F03
+ RENDERER = 0x1F01
+ VENDOR = 0x1F00
+ VERSION = 0x1F02
+
+ S = 0x2000
+ T = 0x2001
+ R = 0x2002
+ Q = 0x2003
+
+ DECAL = 0x2101
+
+ TEXTURE_ENV_COLOR = 0x2201
+ TEXTURE_ENV_MODE = 0x2200
+
+ TEXTURE_ENV = 0x2300
+
+ EYE_LINEAR = 0x2400
+ OBJECT_LINEAR = 0x2401
+ SPHERE_MAP = 0x2402
+
+ EYE_PLANE = 0x2502
+ OBJECT_PLANE = 0x2501
+ TEXTURE_GEN_MODE = 0x2500
+
+ NEAREST = 0x2600
+
+ LINEAR_MIPMAP_LINEAR = 0x2703
+ LINEAR_MIPMAP_NEAREST = 0x2701
+ NEAREST_MIPMAP_LINEAR = 0x2702
+ NEAREST_MIPMAP_NEAREST = 0x2700
+
+ GENERATE_MIPMAP = 0x8191
+ TEXTURE_WRAP_R = 0x8072
+
+ PROXY_TEXTURE_1D = 0x8063
+ PROXY_TEXTURE_2D = 0x8064
+ PROXY_TEXTURE_3D = 0x8070
+ TEXTURE_3D = 0x806F
+ TEXTURE_BASE_LEVEL = 0x813C
+ TEXTURE_MAX_LEVEL = 0x813D
+ TEXTURE_MAX_LOD = 0x813B
+ TEXTURE_MIN_LOD = 0x813A
+
+ CLAMP = 0x2900
+ CLAMP_TO_BORDER = 0x812D
+ CLAMP_TO_EDGE = 0x812F
+ REPEAT = 0x2901
+
+ VERTEX_SHADER_BIT = 0x00000001
+ FRAGMENT_SHADER_BIT = 0x00000002
+ GEOMETRY_SHADER_BIT = 0x00000004
+ TESS_CONTROL_SHADER_BIT = 0x00000008
+ TESS_EVALUATION_SHADER_BIT = 0x00000010
+ COMPUTE_SHADER_BIT = 0x00000020
+ ALL_SHADER_BITS = 0xFFFFFFFF
+
+ SYNC_FLUSH_COMMANDS_BIT = 0x00000001
+ INVALID_INDEX = 0xFFFFFFFF
+ TIMEOUT_IGNORED = 0xFFFFFFFFFFFFFFFF
+ CONSTANT_COLOR = 0x8001
+ ONE_MINUS_CONSTANT_COLOR = 0x8002
+ CONSTANT_ALPHA = 0x8003
+ ONE_MINUS_CONSTANT_ALPHA = 0x8004
+ FUNC_ADD = 0x8006
+ MIN = 0x8007
+ MAX = 0x8008
+ BLEND_EQUATION_RGB = 0x8009
+ FUNC_SUBTRACT = 0x800A
+ FUNC_REVERSE_SUBTRACT = 0x800B
+ RESCALE_NORMAL = 0x803A
+ TEXTURE_DEPTH = 0x8071
+ MAX_3D_TEXTURE_SIZE = 0x8073
+ MULTISAMPLE = 0x809D
+ SAMPLE_ALPHA_TO_COVERAGE = 0x809E
+ SAMPLE_ALPHA_TO_ONE = 0x809F
+ SAMPLE_COVERAGE = 0x80A0
+ SAMPLE_BUFFERS = 0x80A8
+ SAMPLES = 0x80A9
+ SAMPLE_COVERAGE_VALUE = 0x80AA
+ SAMPLE_COVERAGE_INVERT = 0x80AB
+ BLEND_DST_RGB = 0x80C8
+ BLEND_SRC_RGB = 0x80C9
+ BLEND_DST_ALPHA = 0x80CA
+ BLEND_SRC_ALPHA = 0x80CB
+ BGR = 0x80E0
+ BGRA = 0x80E1
+ MAX_ELEMENTS_VERTICES = 0x80E8
+ MAX_ELEMENTS_INDICES = 0x80E9
+ DEPTH_COMPONENT16 = 0x81A5
+ DEPTH_COMPONENT24 = 0x81A6
+ DEPTH_COMPONENT32 = 0x81A7
+ FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING = 0x8210
+ FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE = 0x8211
+ FRAMEBUFFER_ATTACHMENT_RED_SIZE = 0x8212
+ FRAMEBUFFER_ATTACHMENT_GREEN_SIZE = 0x8213
+ FRAMEBUFFER_ATTACHMENT_BLUE_SIZE = 0x8214
+ FRAMEBUFFER_ATTACHMENT_ALPHA_SIZE = 0x8215
+ FRAMEBUFFER_ATTACHMENT_DEPTH_SIZE = 0x8216
+ FRAMEBUFFER_ATTACHMENT_STENCIL_SIZE = 0x8217
+ FRAMEBUFFER_DEFAULT = 0x8218
+ FRAMEBUFFER_UNDEFINED = 0x8219
+ DEPTH_STENCIL_ATTACHMENT = 0x821A
+ MAJOR_VERSION = 0x821B
+ MINOR_VERSION = 0x821C
+ NUM_EXTENSIONS = 0x821D
+ CONTEXT_FLAGS = 0x821E
+ COMPRESSED_RED = 0x8225
+ COMPRESSED_RG = 0x8226
+ RG = 0x8227
+ RG_INTEGER = 0x8228
+ R8 = 0x8229
+ R16 = 0x822A
+ RG8 = 0x822B
+ RG16 = 0x822C
+ R16F = 0x822D
+ R32F = 0x822E
+ RG16F = 0x822F
+ RG32F = 0x8230
+ R8I = 0x8231
+ R8UI = 0x8232
+ R16I = 0x8233
+ R16UI = 0x8234
+ R32I = 0x8235
+ R32UI = 0x8236
+ RG8I = 0x8237
+ RG8UI = 0x8238
+ RG16I = 0x8239
+ RG16UI = 0x823A
+ RG32I = 0x823B
+ RG32UI = 0x823C
+ DEBUG_OUTPUT_SYNCHRONOUS = 0x8242
+ DEBUG_NEXT_LOGGED_MESSAGE_LENGTH = 0x8243
+ DEBUG_CALLBACK_FUNCTION = 0x8244
+ DEBUG_CALLBACK_USER_PARAM = 0x8245
+ DEBUG_SOURCE_API = 0x8246
+ DEBUG_SOURCE_WINDOW_SYSTEM = 0x8247
+ DEBUG_SOURCE_SHADER_COMPILER = 0x8248
+ DEBUG_SOURCE_THIRD_PARTY = 0x8249
+ DEBUG_SOURCE_APPLICATION = 0x824A
+ DEBUG_SOURCE_OTHER = 0x824B
+ DEBUG_TYPE_ERROR = 0x824C
+ DEBUG_TYPE_DEPRECATED_BEHAVIOR = 0x824D
+ DEBUG_TYPE_UNDEFINED_BEHAVIOR = 0x824E
+ DEBUG_TYPE_PORTABILITY = 0x824F
+ DEBUG_TYPE_PERFORMANCE = 0x8250
+ DEBUG_TYPE_OTHER = 0x8251
+ PROGRAM_SEPARABLE = 0x8258
+ ACTIVE_PROGRAM = 0x8259
+ PROGRAM_PIPELINE_BINDING = 0x825A
+ MAX_VIEWPORTS = 0x825B
+ VIEWPORT_SUBPIXEL_BITS = 0x825C
+ VIEWPORT_BOUNDS_RANGE = 0x825D
+ LAYER_PROVOKING_VERTEX = 0x825E
+ VIEWPORT_INDEX_PROVOKING_VERTEX = 0x825F
+ UNDEFINED_VERTEX = 0x8260
+ MAX_COMPUTE_SHARED_MEMORY_SIZE = 0x8262
+ MAX_COMPUTE_UNIFORM_COMPONENTS = 0x8263
+ MAX_COMPUTE_ATOMIC_COUNTER_BUFFERS = 0x8264
+ MAX_COMPUTE_ATOMIC_COUNTERS = 0x8265
+ MAX_COMBINED_COMPUTE_UNIFORM_COMPONENTS = 0x8266
+ COMPUTE_WORK_GROUP_SIZE = 0x8267
+ DEBUG_TYPE_MARKER = 0x8268
+ DEBUG_TYPE_PUSH_GROUP = 0x8269
+ DEBUG_TYPE_POP_GROUP = 0x826A
+ DEBUG_SEVERITY_NOTIFICATION = 0x826B
+ MAX_DEBUG_GROUP_STACK_DEPTH = 0x826C
+ DEBUG_GROUP_STACK_DEPTH = 0x826D
+ MAX_UNIFORM_LOCATIONS = 0x826E
+ INTERNALFORMAT_SUPPORTED = 0x826F
+ INTERNALFORMAT_PREFERRED = 0x8270
+ INTERNALFORMAT_RED_SIZE = 0x8271
+ INTERNALFORMAT_GREEN_SIZE = 0x8272
+ INTERNALFORMAT_BLUE_SIZE = 0x8273
+ INTERNALFORMAT_ALPHA_SIZE = 0x8274
+ INTERNALFORMAT_DEPTH_SIZE = 0x8275
+ INTERNALFORMAT_STENCIL_SIZE = 0x8276
+ INTERNALFORMAT_SHARED_SIZE = 0x8277
+ INTERNALFORMAT_RED_TYPE = 0x8278
+ INTERNALFORMAT_GREEN_TYPE = 0x8279
+ INTERNALFORMAT_BLUE_TYPE = 0x827A
+ INTERNALFORMAT_ALPHA_TYPE = 0x827B
+ INTERNALFORMAT_DEPTH_TYPE = 0x827C
+ INTERNALFORMAT_STENCIL_TYPE = 0x827D
+ MAX_WIDTH = 0x827E
+ MAX_HEIGHT = 0x827F
+ MAX_DEPTH = 0x8280
+ MAX_LAYERS = 0x8281
+ MAX_COMBINED_DIMENSIONS = 0x8282
+ COLOR_COMPONENTS = 0x8283
+ DEPTH_COMPONENTS = 0x8284
+ STENCIL_COMPONENTS = 0x8285
+ COLOR_RENDERABLE = 0x8286
+ DEPTH_RENDERABLE = 0x8287
+ STENCIL_RENDERABLE = 0x8288
+ FRAMEBUFFER_RENDERABLE = 0x8289
+ FRAMEBUFFER_RENDERABLE_LAYERED = 0x828A
+ FRAMEBUFFER_BLEND = 0x828B
+ READ_PIXELS = 0x828C
+ READ_PIXELS_FORMAT = 0x828D
+ READ_PIXELS_TYPE = 0x828E
+ TEXTURE_IMAGE_FORMAT = 0x828F
+ TEXTURE_IMAGE_TYPE = 0x8290
+ GET_TEXTURE_IMAGE_FORMAT = 0x8291
+ GET_TEXTURE_IMAGE_TYPE = 0x8292
+ MIPMAP = 0x8293
+ MANUAL_GENERATE_MIPMAP = 0x8294
+ AUTO_GENERATE_MIPMAP = 0x8295
+ COLOR_ENCODING = 0x8296
+ SRGB_READ = 0x8297
+ SRGB_WRITE = 0x8298
+ FILTER = 0x829A
+ VERTEX_TEXTURE = 0x829B
+ TESS_CONTROL_TEXTURE = 0x829C
+ TESS_EVALUATION_TEXTURE = 0x829D
+ GEOMETRY_TEXTURE = 0x829E
+ FRAGMENT_TEXTURE = 0x829F
+ COMPUTE_TEXTURE = 0x82A0
+ TEXTURE_SHADOW = 0x82A1
+ TEXTURE_GATHER = 0x82A2
+ TEXTURE_GATHER_SHADOW = 0x82A3
+ SHADER_IMAGE_LOAD = 0x82A4
+ SHADER_IMAGE_STORE = 0x82A5
+ SHADER_IMAGE_ATOMIC = 0x82A6
+ IMAGE_TEXEL_SIZE = 0x82A7
+ IMAGE_COMPATIBILITY_CLASS = 0x82A8
+ IMAGE_PIXEL_FORMAT = 0x82A9
+ IMAGE_PIXEL_TYPE = 0x82AA
+ SIMULTANEOUS_TEXTURE_AND_DEPTH_TEST = 0x82AC
+ SIMULTANEOUS_TEXTURE_AND_STENCIL_TEST = 0x82AD
+ SIMULTANEOUS_TEXTURE_AND_DEPTH_WRITE = 0x82AE
+ SIMULTANEOUS_TEXTURE_AND_STENCIL_WRITE = 0x82AF
+ TEXTURE_COMPRESSED_BLOCK_WIDTH = 0x82B1
+ TEXTURE_COMPRESSED_BLOCK_HEIGHT = 0x82B2
+ TEXTURE_COMPRESSED_BLOCK_SIZE = 0x82B3
+ CLEAR_BUFFER = 0x82B4
+ TEXTURE_VIEW = 0x82B5
+ VIEW_COMPATIBILITY_CLASS = 0x82B6
+ FULL_SUPPORT = 0x82B7
+ CAVEAT_SUPPORT = 0x82B8
+ IMAGE_CLASS_4_X_32 = 0x82B9
+ IMAGE_CLASS_2_X_32 = 0x82BA
+ IMAGE_CLASS_1_X_32 = 0x82BB
+ IMAGE_CLASS_4_X_16 = 0x82BC
+ IMAGE_CLASS_2_X_16 = 0x82BD
+ IMAGE_CLASS_1_X_16 = 0x82BE
+ IMAGE_CLASS_4_X_8 = 0x82BF
+ IMAGE_CLASS_2_X_8 = 0x82C0
+ IMAGE_CLASS_1_X_8 = 0x82C1
+ IMAGE_CLASS_11_11_10 = 0x82C2
+ IMAGE_CLASS_10_10_10_2 = 0x82C3
+ VIEW_CLASS_128_BITS = 0x82C4
+ VIEW_CLASS_96_BITS = 0x82C5
+ VIEW_CLASS_64_BITS = 0x82C6
+ VIEW_CLASS_48_BITS = 0x82C7
+ VIEW_CLASS_32_BITS = 0x82C8
+ VIEW_CLASS_24_BITS = 0x82C9
+ VIEW_CLASS_16_BITS = 0x82CA
+ VIEW_CLASS_8_BITS = 0x82CB
+ VIEW_CLASS_S3TC_DXT1_RGB = 0x82CC
+ VIEW_CLASS_S3TC_DXT1_RGBA = 0x82CD
+ VIEW_CLASS_S3TC_DXT3_RGBA = 0x82CE
+ VIEW_CLASS_S3TC_DXT5_RGBA = 0x82CF
+ VIEW_CLASS_RGTC1_RED = 0x82D0
+ VIEW_CLASS_RGTC2_RG = 0x82D1
+ VIEW_CLASS_BPTC_UNORM = 0x82D2
+ VIEW_CLASS_BPTC_FLOAT = 0x82D3
+ VERTEX_ATTRIB_BINDING = 0x82D4
+ VERTEX_ATTRIB_RELATIVE_OFFSET = 0x82D5
+ VERTEX_BINDING_DIVISOR = 0x82D6
+ VERTEX_BINDING_OFFSET = 0x82D7
+ VERTEX_BINDING_STRIDE = 0x82D8
+ MAX_VERTEX_ATTRIB_RELATIVE_OFFSET = 0x82D9
+ MAX_VERTEX_ATTRIB_BINDINGS = 0x82DA
+ TEXTURE_VIEW_MIN_LEVEL = 0x82DB
+ TEXTURE_VIEW_NUM_LEVELS = 0x82DC
+ TEXTURE_VIEW_MIN_LAYER = 0x82DD
+ TEXTURE_VIEW_NUM_LAYERS = 0x82DE
+ TEXTURE_IMMUTABLE_LEVELS = 0x82DF
+ BUFFER = 0x82E0
+ SHADER = 0x82E1
+ PROGRAM = 0x82E2
+ QUERY = 0x82E3
+ PROGRAM_PIPELINE = 0x82E4
+ SAMPLER = 0x82E6
+ MAX_LABEL_LENGTH = 0x82E8
+ NUM_SHADING_LANGUAGE_VERSIONS = 0x82E9
+ UNSIGNED_BYTE_2_3_3_REV = 0x8362
+ UNSIGNED_SHORT_5_6_5 = 0x8363
+ UNSIGNED_SHORT_5_6_5_REV = 0x8364
+ UNSIGNED_SHORT_4_4_4_4_REV = 0x8365
+ UNSIGNED_SHORT_1_5_5_5_REV = 0x8366
+ UNSIGNED_INT_8_8_8_8_REV = 0x8367
+ UNSIGNED_INT_2_10_10_10_REV = 0x8368
+ MIRRORED_REPEAT = 0x8370
+ FOG_COORDINATE_SOURCE = 0x8450
+ FOG_COORD_SRC = 0x8450
+ FOG_COORDINATE = 0x8451
+ FOG_COORD = 0x8451
+ FRAGMENT_DEPTH = 0x8452
+ CURRENT_FOG_COORDINATE = 0x8453
+ CURRENT_FOG_COORD = 0x8453
+ FOG_COORDINATE_ARRAY_TYPE = 0x8454
+ FOG_COORD_ARRAY_TYPE = 0x8454
+ FOG_COORDINATE_ARRAY_STRIDE = 0x8455
+ FOG_COORD_ARRAY_STRIDE = 0x8455
+ FOG_COORDINATE_ARRAY_POINTER = 0x8456
+ FOG_COORD_ARRAY_POINTER = 0x8456
+ FOG_COORDINATE_ARRAY = 0x8457
+ FOG_COORD_ARRAY = 0x8457
+ COLOR_SUM = 0x8458
+ CURRENT_SECONDARY_COLOR = 0x8459
+ SECONDARY_COLOR_ARRAY_SIZE = 0x845A
+ SECONDARY_COLOR_ARRAY_TYPE = 0x845B
+ SECONDARY_COLOR_ARRAY_STRIDE = 0x845C
+ SECONDARY_COLOR_ARRAY_POINTER = 0x845D
+ SECONDARY_COLOR_ARRAY = 0x845E
+ CURRENT_RASTER_SECONDARY_COLOR = 0x845F
+ TEXTURE0 = 0x84C0
+ TEXTURE1 = 0x84C1
+ TEXTURE2 = 0x84C2
+ TEXTURE3 = 0x84C3
+ TEXTURE4 = 0x84C4
+ TEXTURE5 = 0x84C5
+ TEXTURE6 = 0x84C6
+ TEXTURE7 = 0x84C7
+ TEXTURE8 = 0x84C8
+ TEXTURE9 = 0x84C9
+ TEXTURE10 = 0x84CA
+ TEXTURE11 = 0x84CB
+ TEXTURE12 = 0x84CC
+ TEXTURE13 = 0x84CD
+ TEXTURE14 = 0x84CE
+ TEXTURE15 = 0x84CF
+ TEXTURE16 = 0x84D0
+ TEXTURE17 = 0x84D1
+ TEXTURE18 = 0x84D2
+ TEXTURE19 = 0x84D3
+ TEXTURE20 = 0x84D4
+ TEXTURE21 = 0x84D5
+ TEXTURE22 = 0x84D6
+ TEXTURE23 = 0x84D7
+ TEXTURE24 = 0x84D8
+ TEXTURE25 = 0x84D9
+ TEXTURE26 = 0x84DA
+ TEXTURE27 = 0x84DB
+ TEXTURE28 = 0x84DC
+ TEXTURE29 = 0x84DD
+ TEXTURE30 = 0x84DE
+ TEXTURE31 = 0x84DF
+ ACTIVE_TEXTURE = 0x84E0
+ CLIENT_ACTIVE_TEXTURE = 0x84E1
+ MAX_TEXTURE_UNITS = 0x84E2
+ TRANSPOSE_MODELVIEW_MATRIX = 0x84E3
+ TRANSPOSE_PROJECTION_MATRIX = 0x84E4
+ TRANSPOSE_TEXTURE_MATRIX = 0x84E5
+ TRANSPOSE_COLOR_MATRIX = 0x84E6
+ SUBTRACT = 0x84E7
+ MAX_RENDERBUFFER_SIZE = 0x84E8
+ COMPRESSED_ALPHA = 0x84E9
+ COMPRESSED_LUMINANCE = 0x84EA
+ COMPRESSED_LUMINANCE_ALPHA = 0x84EB
+ COMPRESSED_INTENSITY = 0x84EC
+ COMPRESSED_RGB = 0x84ED
+ COMPRESSED_RGBA = 0x84EE
+ UNIFORM_BLOCK_REFERENCED_BY_TESS_CONTROL_SHADER = 0x84F0
+ UNIFORM_BLOCK_REFERENCED_BY_TESS_EVALUATION_SHADER = 0x84F1
+ TEXTURE_RECTANGLE = 0x84F5
+ TEXTURE_BINDING_RECTANGLE = 0x84F6
+ PROXY_TEXTURE_RECTANGLE = 0x84F7
+ MAX_RECTANGLE_TEXTURE_SIZE = 0x84F8
+ DEPTH_STENCIL = 0x84F9
+ UNSIGNED_INT_24_8 = 0x84FA
+ MAX_TEXTURE_LOD_BIAS = 0x84FD
+ TEXTURE_FILTER_CONTROL = 0x8500
+ TEXTURE_LOD_BIAS = 0x8501
+ INCR_WRAP = 0x8507
+ DECR_WRAP = 0x8508
+ NORMAL_MAP = 0x8511
+ REFLECTION_MAP = 0x8512
+ TEXTURE_CUBE_MAP = 0x8513
+ TEXTURE_BINDING_CUBE_MAP = 0x8514
+ TEXTURE_CUBE_MAP_POSITIVE_X = 0x8515
+ TEXTURE_CUBE_MAP_NEGATIVE_X = 0x8516
+ TEXTURE_CUBE_MAP_POSITIVE_Y = 0x8517
+ TEXTURE_CUBE_MAP_NEGATIVE_Y = 0x8518
+ TEXTURE_CUBE_MAP_POSITIVE_Z = 0x8519
+ TEXTURE_CUBE_MAP_NEGATIVE_Z = 0x851A
+ PROXY_TEXTURE_CUBE_MAP = 0x851B
+ MAX_CUBE_MAP_TEXTURE_SIZE = 0x851C
+ COMBINE = 0x8570
+ COMBINE_RGB = 0x8571
+ COMBINE_ALPHA = 0x8572
+ RGB_SCALE = 0x8573
+ ADD_SIGNED = 0x8574
+ INTERPOLATE = 0x8575
+ CONSTANT = 0x8576
+ PRIMARY_COLOR = 0x8577
+ PREVIOUS = 0x8578
+ SOURCE0_RGB = 0x8580
+ SRC0_RGB = 0x8580
+ SOURCE1_RGB = 0x8581
+ SRC1_RGB = 0x8581
+ SOURCE2_RGB = 0x8582
+ SRC2_RGB = 0x8582
+ SOURCE0_ALPHA = 0x8588
+ SRC0_ALPHA = 0x8588
+ SOURCE1_ALPHA = 0x8589
+ SRC1_ALPHA = 0x8589
+ SOURCE2_ALPHA = 0x858A
+ SRC2_ALPHA = 0x858A
+ OPERAND0_RGB = 0x8590
+ OPERAND1_RGB = 0x8591
+ OPERAND2_RGB = 0x8592
+ OPERAND0_ALPHA = 0x8598
+ OPERAND1_ALPHA = 0x8599
+ OPERAND2_ALPHA = 0x859A
+ VERTEX_ARRAY_BINDING = 0x85B5
+ VERTEX_ATTRIB_ARRAY_ENABLED = 0x8622
+ VERTEX_ATTRIB_ARRAY_SIZE = 0x8623
+ VERTEX_ATTRIB_ARRAY_STRIDE = 0x8624
+ VERTEX_ATTRIB_ARRAY_TYPE = 0x8625
+ CURRENT_VERTEX_ATTRIB = 0x8626
+ VERTEX_PROGRAM_POINT_SIZE = 0x8642
+ PROGRAM_POINT_SIZE = 0x8642
+ VERTEX_PROGRAM_TWO_SIDE = 0x8643
+ VERTEX_ATTRIB_ARRAY_POINTER = 0x8645
+ DEPTH_CLAMP = 0x864F
+ TEXTURE_COMPRESSED_IMAGE_SIZE = 0x86A0
+ TEXTURE_COMPRESSED = 0x86A1
+ NUM_COMPRESSED_TEXTURE_FORMATS = 0x86A2
+ COMPRESSED_TEXTURE_FORMATS = 0x86A3
+ DOT3_RGB = 0x86AE
+ DOT3_RGBA = 0x86AF
+ PROGRAM_BINARY_LENGTH = 0x8741
+ VERTEX_ATTRIB_ARRAY_LONG = 0x874E
+ BUFFER_SIZE = 0x8764
+ BUFFER_USAGE = 0x8765
+ NUM_PROGRAM_BINARY_FORMATS = 0x87FE
+ PROGRAM_BINARY_FORMATS = 0x87FF
+ STENCIL_BACK_FUNC = 0x8800
+ STENCIL_BACK_FAIL = 0x8801
+ STENCIL_BACK_PASS_DEPTH_FAIL = 0x8802
+ STENCIL_BACK_PASS_DEPTH_PASS = 0x8803
+ RGBA32F = 0x8814
+ RGB32F = 0x8815
+ RGBA16F = 0x881A
+ RGB16F = 0x881B
+ MAX_DRAW_BUFFERS = 0x8824
+ DRAW_BUFFER0 = 0x8825
+ DRAW_BUFFER1 = 0x8826
+ DRAW_BUFFER2 = 0x8827
+ DRAW_BUFFER3 = 0x8828
+ DRAW_BUFFER4 = 0x8829
+ DRAW_BUFFER5 = 0x882A
+ DRAW_BUFFER6 = 0x882B
+ DRAW_BUFFER7 = 0x882C
+ DRAW_BUFFER8 = 0x882D
+ DRAW_BUFFER9 = 0x882E
+ DRAW_BUFFER10 = 0x882F
+ DRAW_BUFFER11 = 0x8830
+ DRAW_BUFFER12 = 0x8831
+ DRAW_BUFFER13 = 0x8832
+ DRAW_BUFFER14 = 0x8833
+ DRAW_BUFFER15 = 0x8834
+ BLEND_EQUATION_ALPHA = 0x883D
+ TEXTURE_DEPTH_SIZE = 0x884A
+ DEPTH_TEXTURE_MODE = 0x884B
+ TEXTURE_COMPARE_MODE = 0x884C
+ TEXTURE_COMPARE_FUNC = 0x884D
+ COMPARE_R_TO_TEXTURE = 0x884E
+ COMPARE_REF_TO_TEXTURE = 0x884E
+ TEXTURE_CUBE_MAP_SEAMLESS = 0x884F
+ POINT_SPRITE = 0x8861
+ COORD_REPLACE = 0x8862
+ QUERY_COUNTER_BITS = 0x8864
+ CURRENT_QUERY = 0x8865
+ QUERY_RESULT = 0x8866
+ QUERY_RESULT_AVAILABLE = 0x8867
+ MAX_VERTEX_ATTRIBS = 0x8869
+ VERTEX_ATTRIB_ARRAY_NORMALIZED = 0x886A
+ MAX_TESS_CONTROL_INPUT_COMPONENTS = 0x886C
+ MAX_TESS_EVALUATION_INPUT_COMPONENTS = 0x886D
+ MAX_TEXTURE_COORDS = 0x8871
+ MAX_TEXTURE_IMAGE_UNITS = 0x8872
+ GEOMETRY_SHADER_INVOCATIONS = 0x887F
+ ARRAY_BUFFER = 0x8892
+ ELEMENT_ARRAY_BUFFER = 0x8893
+ ARRAY_BUFFER_BINDING = 0x8894
+ ELEMENT_ARRAY_BUFFER_BINDING = 0x8895
+ VERTEX_ARRAY_BUFFER_BINDING = 0x8896
+ NORMAL_ARRAY_BUFFER_BINDING = 0x8897
+ COLOR_ARRAY_BUFFER_BINDING = 0x8898
+ INDEX_ARRAY_BUFFER_BINDING = 0x8899
+ TEXTURE_COORD_ARRAY_BUFFER_BINDING = 0x889A
+ EDGE_FLAG_ARRAY_BUFFER_BINDING = 0x889B
+ SECONDARY_COLOR_ARRAY_BUFFER_BINDING = 0x889C
+ FOG_COORDINATE_ARRAY_BUFFER_BINDING = 0x889D
+ FOG_COORD_ARRAY_BUFFER_BINDING = 0x889D
+ WEIGHT_ARRAY_BUFFER_BINDING = 0x889E
+ VERTEX_ATTRIB_ARRAY_BUFFER_BINDING = 0x889F
+ READ_ONLY = 0x88B8
+ WRITE_ONLY = 0x88B9
+ READ_WRITE = 0x88BA
+ BUFFER_ACCESS = 0x88BB
+ BUFFER_MAPPED = 0x88BC
+ BUFFER_MAP_POINTER = 0x88BD
+ TIME_ELAPSED = 0x88BF
+ STREAM_DRAW = 0x88E0
+ STREAM_READ = 0x88E1
+ STREAM_COPY = 0x88E2
+ STATIC_DRAW = 0x88E4
+ STATIC_READ = 0x88E5
+ STATIC_COPY = 0x88E6
+ DYNAMIC_DRAW = 0x88E8
+ DYNAMIC_READ = 0x88E9
+ DYNAMIC_COPY = 0x88EA
+ PIXEL_PACK_BUFFER = 0x88EB
+ PIXEL_UNPACK_BUFFER = 0x88EC
+ PIXEL_PACK_BUFFER_BINDING = 0x88ED
+ PIXEL_UNPACK_BUFFER_BINDING = 0x88EF
+ DEPTH24_STENCIL8 = 0x88F0
+ TEXTURE_STENCIL_SIZE = 0x88F1
+ SRC1_COLOR = 0x88F9
+ ONE_MINUS_SRC1_COLOR = 0x88FA
+ ONE_MINUS_SRC1_ALPHA = 0x88FB
+ MAX_DUAL_SOURCE_DRAW_BUFFERS = 0x88FC
+ VERTEX_ATTRIB_ARRAY_INTEGER = 0x88FD
+ VERTEX_ATTRIB_ARRAY_DIVISOR = 0x88FE
+ MAX_ARRAY_TEXTURE_LAYERS = 0x88FF
+ MIN_PROGRAM_TEXEL_OFFSET = 0x8904
+ MAX_PROGRAM_TEXEL_OFFSET = 0x8905
+ SAMPLES_PASSED = 0x8914
+ GEOMETRY_VERTICES_OUT = 0x8916
+ GEOMETRY_INPUT_TYPE = 0x8917
+ GEOMETRY_OUTPUT_TYPE = 0x8918
+ SAMPLER_BINDING = 0x8919
+ CLAMP_VERTEX_COLOR = 0x891A
+ CLAMP_FRAGMENT_COLOR = 0x891B
+ CLAMP_READ_COLOR = 0x891C
+ FIXED_ONLY = 0x891D
+ UNIFORM_BUFFER = 0x8A11
+ UNIFORM_BUFFER_BINDING = 0x8A28
+ UNIFORM_BUFFER_START = 0x8A29
+ UNIFORM_BUFFER_SIZE = 0x8A2A
+ MAX_VERTEX_UNIFORM_BLOCKS = 0x8A2B
+ MAX_GEOMETRY_UNIFORM_BLOCKS = 0x8A2C
+ MAX_FRAGMENT_UNIFORM_BLOCKS = 0x8A2D
+ MAX_COMBINED_UNIFORM_BLOCKS = 0x8A2E
+ MAX_UNIFORM_BUFFER_BINDINGS = 0x8A2F
+ MAX_UNIFORM_BLOCK_SIZE = 0x8A30
+ MAX_COMBINED_VERTEX_UNIFORM_COMPONENTS = 0x8A31
+ MAX_COMBINED_GEOMETRY_UNIFORM_COMPONENTS = 0x8A32
+ MAX_COMBINED_FRAGMENT_UNIFORM_COMPONENTS = 0x8A33
+ UNIFORM_BUFFER_OFFSET_ALIGNMENT = 0x8A34
+ ACTIVE_UNIFORM_BLOCK_MAX_NAME_LENGTH = 0x8A35
+ ACTIVE_UNIFORM_BLOCKS = 0x8A36
+ UNIFORM_TYPE = 0x8A37
+ UNIFORM_SIZE = 0x8A38
+ UNIFORM_NAME_LENGTH = 0x8A39
+ UNIFORM_BLOCK_INDEX = 0x8A3A
+ UNIFORM_OFFSET = 0x8A3B
+ UNIFORM_ARRAY_STRIDE = 0x8A3C
+ UNIFORM_MATRIX_STRIDE = 0x8A3D
+ UNIFORM_IS_ROW_MAJOR = 0x8A3E
+ UNIFORM_BLOCK_BINDING = 0x8A3F
+ UNIFORM_BLOCK_DATA_SIZE = 0x8A40
+ UNIFORM_BLOCK_NAME_LENGTH = 0x8A41
+ UNIFORM_BLOCK_ACTIVE_UNIFORMS = 0x8A42
+ UNIFORM_BLOCK_ACTIVE_UNIFORM_INDICES = 0x8A43
+ UNIFORM_BLOCK_REFERENCED_BY_VERTEX_SHADER = 0x8A44
+ UNIFORM_BLOCK_REFERENCED_BY_GEOMETRY_SHADER = 0x8A45
+ UNIFORM_BLOCK_REFERENCED_BY_FRAGMENT_SHADER = 0x8A46
+ FRAGMENT_SHADER = 0x8B30
+ VERTEX_SHADER = 0x8B31
+ MAX_FRAGMENT_UNIFORM_COMPONENTS = 0x8B49
+ MAX_VERTEX_UNIFORM_COMPONENTS = 0x8B4A
+ MAX_VARYING_FLOATS = 0x8B4B
+ MAX_VARYING_COMPONENTS = 0x8B4B
+ MAX_VERTEX_TEXTURE_IMAGE_UNITS = 0x8B4C
+ MAX_COMBINED_TEXTURE_IMAGE_UNITS = 0x8B4D
+ SHADER_TYPE = 0x8B4F
+ FLOAT_VEC2 = 0x8B50
+ FLOAT_VEC3 = 0x8B51
+ FLOAT_VEC4 = 0x8B52
+ INT_VEC2 = 0x8B53
+ INT_VEC3 = 0x8B54
+ INT_VEC4 = 0x8B55
+ BOOL = 0x8B56
+ BOOL_VEC2 = 0x8B57
+ BOOL_VEC3 = 0x8B58
+ BOOL_VEC4 = 0x8B59
+ FLOAT_MAT2 = 0x8B5A
+ FLOAT_MAT3 = 0x8B5B
+ FLOAT_MAT4 = 0x8B5C
+ SAMPLER_1D = 0x8B5D
+ SAMPLER_2D = 0x8B5E
+ SAMPLER_3D = 0x8B5F
+ SAMPLER_CUBE = 0x8B60
+ SAMPLER_1D_SHADOW = 0x8B61
+ SAMPLER_2D_SHADOW = 0x8B62
+ SAMPLER_2D_RECT = 0x8B63
+ SAMPLER_2D_RECT_SHADOW = 0x8B64
+ FLOAT_MAT2x3 = 0x8B65
+ FLOAT_MAT2x4 = 0x8B66
+ FLOAT_MAT3x2 = 0x8B67
+ FLOAT_MAT3x4 = 0x8B68
+ FLOAT_MAT4x2 = 0x8B69
+ FLOAT_MAT4x3 = 0x8B6A
+ DELETE_STATUS = 0x8B80
+ COMPILE_STATUS = 0x8B81
+ LINK_STATUS = 0x8B82
+ VALIDATE_STATUS = 0x8B83
+ INFO_LOG_LENGTH = 0x8B84
+ ATTACHED_SHADERS = 0x8B85
+ ACTIVE_UNIFORMS = 0x8B86
+ ACTIVE_UNIFORM_MAX_LENGTH = 0x8B87
+ SHADER_SOURCE_LENGTH = 0x8B88
+ ACTIVE_ATTRIBUTES = 0x8B89
+ ACTIVE_ATTRIBUTE_MAX_LENGTH = 0x8B8A
+ SHADING_LANGUAGE_VERSION = 0x8B8C
+ CURRENT_PROGRAM = 0x8B8D
+ IMPLEMENTATION_COLOR_READ_TYPE = 0x8B9A
+ IMPLEMENTATION_COLOR_READ_FORMAT = 0x8B9B
+ TEXTURE_RED_TYPE = 0x8C10
+ TEXTURE_GREEN_TYPE = 0x8C11
+ TEXTURE_BLUE_TYPE = 0x8C12
+ TEXTURE_ALPHA_TYPE = 0x8C13
+ TEXTURE_DEPTH_TYPE = 0x8C16
+ UNSIGNED_NORMALIZED = 0x8C17
+ TEXTURE_1D_ARRAY = 0x8C18
+ PROXY_TEXTURE_1D_ARRAY = 0x8C19
+ TEXTURE_2D_ARRAY = 0x8C1A
+ PROXY_TEXTURE_2D_ARRAY = 0x8C1B
+ TEXTURE_BINDING_1D_ARRAY = 0x8C1C
+ TEXTURE_BINDING_2D_ARRAY = 0x8C1D
+ MAX_GEOMETRY_TEXTURE_IMAGE_UNITS = 0x8C29
+ TEXTURE_BUFFER = 0x8C2A
+ MAX_TEXTURE_BUFFER_SIZE = 0x8C2B
+ TEXTURE_BINDING_BUFFER = 0x8C2C
+ TEXTURE_BUFFER_DATA_STORE_BINDING = 0x8C2D
+ ANY_SAMPLES_PASSED = 0x8C2F
+ SAMPLE_SHADING = 0x8C36
+ MIN_SAMPLE_SHADING_VALUE = 0x8C37
+ R11F_G11F_B10F = 0x8C3A
+ UNSIGNED_INT_10F_11F_11F_REV = 0x8C3B
+ RGB9_E5 = 0x8C3D
+ UNSIGNED_INT_5_9_9_9_REV = 0x8C3E
+ TEXTURE_SHARED_SIZE = 0x8C3F
+ SRGB = 0x8C40
+ SRGB8 = 0x8C41
+ SRGB_ALPHA = 0x8C42
+ SRGB8_ALPHA8 = 0x8C43
+ SLUMINANCE_ALPHA = 0x8C44
+ SLUMINANCE8_ALPHA8 = 0x8C45
+ SLUMINANCE = 0x8C46
+ SLUMINANCE8 = 0x8C47
+ COMPRESSED_SRGB = 0x8C48
+ COMPRESSED_SRGB_ALPHA = 0x8C49
+ COMPRESSED_SLUMINANCE = 0x8C4A
+ COMPRESSED_SLUMINANCE_ALPHA = 0x8C4B
+ TRANSFORM_FEEDBACK_VARYING_MAX_LENGTH = 0x8C76
+ TRANSFORM_FEEDBACK_BUFFER_MODE = 0x8C7F
+ MAX_TRANSFORM_FEEDBACK_SEPARATE_COMPONENTS = 0x8C80
+ TRANSFORM_FEEDBACK_VARYINGS = 0x8C83
+ TRANSFORM_FEEDBACK_BUFFER_START = 0x8C84
+ TRANSFORM_FEEDBACK_BUFFER_SIZE = 0x8C85
+ PRIMITIVES_GENERATED = 0x8C87
+ TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN = 0x8C88
+ RASTERIZER_DISCARD = 0x8C89
+ MAX_TRANSFORM_FEEDBACK_INTERLEAVED_COMPONENTS = 0x8C8A
+ MAX_TRANSFORM_FEEDBACK_SEPARATE_ATTRIBS = 0x8C8B
+ INTERLEAVED_ATTRIBS = 0x8C8C
+ SEPARATE_ATTRIBS = 0x8C8D
+ TRANSFORM_FEEDBACK_BUFFER = 0x8C8E
+ TRANSFORM_FEEDBACK_BUFFER_BINDING = 0x8C8F
+ POINT_SPRITE_COORD_ORIGIN = 0x8CA0
+ LOWER_LEFT = 0x8CA1
+ UPPER_LEFT = 0x8CA2
+ STENCIL_BACK_REF = 0x8CA3
+ STENCIL_BACK_VALUE_MASK = 0x8CA4
+ STENCIL_BACK_WRITEMASK = 0x8CA5
+ DRAW_FRAMEBUFFER_BINDING = 0x8CA6
+ FRAMEBUFFER_BINDING = 0x8CA6
+ RENDERBUFFER_BINDING = 0x8CA7
+ READ_FRAMEBUFFER = 0x8CA8
+ DRAW_FRAMEBUFFER = 0x8CA9
+ READ_FRAMEBUFFER_BINDING = 0x8CAA
+ RENDERBUFFER_SAMPLES = 0x8CAB
+ DEPTH_COMPONENT32F = 0x8CAC
+ DEPTH32F_STENCIL8 = 0x8CAD
+ FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE = 0x8CD0
+ FRAMEBUFFER_ATTACHMENT_OBJECT_NAME = 0x8CD1
+ FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL = 0x8CD2
+ FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE = 0x8CD3
+ FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER = 0x8CD4
+ FRAMEBUFFER_COMPLETE = 0x8CD5
+ FRAMEBUFFER_INCOMPLETE_ATTACHMENT = 0x8CD6
+ FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT = 0x8CD7
+ FRAMEBUFFER_INCOMPLETE_DRAW_BUFFER = 0x8CDB
+ FRAMEBUFFER_INCOMPLETE_READ_BUFFER = 0x8CDC
+ FRAMEBUFFER_UNSUPPORTED = 0x8CDD
+ MAX_COLOR_ATTACHMENTS = 0x8CDF
+ COLOR_ATTACHMENT0 = 0x8CE0
+ COLOR_ATTACHMENT1 = 0x8CE1
+ COLOR_ATTACHMENT2 = 0x8CE2
+ COLOR_ATTACHMENT3 = 0x8CE3
+ COLOR_ATTACHMENT4 = 0x8CE4
+ COLOR_ATTACHMENT5 = 0x8CE5
+ COLOR_ATTACHMENT6 = 0x8CE6
+ COLOR_ATTACHMENT7 = 0x8CE7
+ COLOR_ATTACHMENT8 = 0x8CE8
+ COLOR_ATTACHMENT9 = 0x8CE9
+ COLOR_ATTACHMENT10 = 0x8CEA
+ COLOR_ATTACHMENT11 = 0x8CEB
+ COLOR_ATTACHMENT12 = 0x8CEC
+ COLOR_ATTACHMENT13 = 0x8CED
+ COLOR_ATTACHMENT14 = 0x8CEE
+ COLOR_ATTACHMENT15 = 0x8CEF
+ DEPTH_ATTACHMENT = 0x8D00
+ STENCIL_ATTACHMENT = 0x8D20
+ FRAMEBUFFER = 0x8D40
+ RENDERBUFFER = 0x8D41
+ RENDERBUFFER_WIDTH = 0x8D42
+ RENDERBUFFER_HEIGHT = 0x8D43
+ RENDERBUFFER_INTERNAL_FORMAT = 0x8D44
+ STENCIL_INDEX1 = 0x8D46
+ STENCIL_INDEX4 = 0x8D47
+ STENCIL_INDEX8 = 0x8D48
+ STENCIL_INDEX16 = 0x8D49
+ RENDERBUFFER_RED_SIZE = 0x8D50
+ RENDERBUFFER_GREEN_SIZE = 0x8D51
+ RENDERBUFFER_BLUE_SIZE = 0x8D52
+ RENDERBUFFER_ALPHA_SIZE = 0x8D53
+ RENDERBUFFER_DEPTH_SIZE = 0x8D54
+ RENDERBUFFER_STENCIL_SIZE = 0x8D55
+ FRAMEBUFFER_INCOMPLETE_MULTISAMPLE = 0x8D56
+ MAX_SAMPLES = 0x8D57
+ RGB565 = 0x8D62
+ PRIMITIVE_RESTART_FIXED_INDEX = 0x8D69
+ ANY_SAMPLES_PASSED_CONSERVATIVE = 0x8D6A
+ MAX_ELEMENT_INDEX = 0x8D6B
+ RGBA32UI = 0x8D70
+ RGB32UI = 0x8D71
+ RGBA16UI = 0x8D76
+ RGB16UI = 0x8D77
+ RGBA8UI = 0x8D7C
+ RGB8UI = 0x8D7D
+ RGBA32I = 0x8D82
+ RGB32I = 0x8D83
+ RGBA16I = 0x8D88
+ RGB16I = 0x8D89
+ RGBA8I = 0x8D8E
+ RGB8I = 0x8D8F
+ RED_INTEGER = 0x8D94
+ GREEN_INTEGER = 0x8D95
+ BLUE_INTEGER = 0x8D96
+ ALPHA_INTEGER = 0x8D97
+ RGB_INTEGER = 0x8D98
+ RGBA_INTEGER = 0x8D99
+ BGR_INTEGER = 0x8D9A
+ BGRA_INTEGER = 0x8D9B
+ INT_2_10_10_10_REV = 0x8D9F
+ FRAMEBUFFER_ATTACHMENT_LAYERED = 0x8DA7
+ FRAMEBUFFER_INCOMPLETE_LAYER_TARGETS = 0x8DA8
+ FLOAT_32_UNSIGNED_INT_24_8_REV = 0x8DAD
+ FRAMEBUFFER_SRGB = 0x8DB9
+ COMPRESSED_RED_RGTC1 = 0x8DBB
+ COMPRESSED_SIGNED_RED_RGTC1 = 0x8DBC
+ COMPRESSED_RG_RGTC2 = 0x8DBD
+ COMPRESSED_SIGNED_RG_RGTC2 = 0x8DBE
+ SAMPLER_1D_ARRAY = 0x8DC0
+ SAMPLER_2D_ARRAY = 0x8DC1
+ SAMPLER_BUFFER = 0x8DC2
+ SAMPLER_1D_ARRAY_SHADOW = 0x8DC3
+ SAMPLER_2D_ARRAY_SHADOW = 0x8DC4
+ SAMPLER_CUBE_SHADOW = 0x8DC5
+ UNSIGNED_INT_VEC2 = 0x8DC6
+ UNSIGNED_INT_VEC3 = 0x8DC7
+ UNSIGNED_INT_VEC4 = 0x8DC8
+ INT_SAMPLER_1D = 0x8DC9
+ INT_SAMPLER_2D = 0x8DCA
+ INT_SAMPLER_3D = 0x8DCB
+ INT_SAMPLER_CUBE = 0x8DCC
+ INT_SAMPLER_2D_RECT = 0x8DCD
+ INT_SAMPLER_1D_ARRAY = 0x8DCE
+ INT_SAMPLER_2D_ARRAY = 0x8DCF
+ INT_SAMPLER_BUFFER = 0x8DD0
+ UNSIGNED_INT_SAMPLER_1D = 0x8DD1
+ UNSIGNED_INT_SAMPLER_2D = 0x8DD2
+ UNSIGNED_INT_SAMPLER_3D = 0x8DD3
+ UNSIGNED_INT_SAMPLER_CUBE = 0x8DD4
+ UNSIGNED_INT_SAMPLER_2D_RECT = 0x8DD5
+ UNSIGNED_INT_SAMPLER_1D_ARRAY = 0x8DD6
+ UNSIGNED_INT_SAMPLER_2D_ARRAY = 0x8DD7
+ UNSIGNED_INT_SAMPLER_BUFFER = 0x8DD8
+ GEOMETRY_SHADER = 0x8DD9
+ MAX_GEOMETRY_UNIFORM_COMPONENTS = 0x8DDF
+ MAX_GEOMETRY_OUTPUT_VERTICES = 0x8DE0
+ MAX_GEOMETRY_TOTAL_OUTPUT_COMPONENTS = 0x8DE1
+ ACTIVE_SUBROUTINES = 0x8DE5
+ ACTIVE_SUBROUTINE_UNIFORMS = 0x8DE6
+ MAX_SUBROUTINES = 0x8DE7
+ MAX_SUBROUTINE_UNIFORM_LOCATIONS = 0x8DE8
+ LOW_FLOAT = 0x8DF0
+ MEDIUM_FLOAT = 0x8DF1
+ HIGH_FLOAT = 0x8DF2
+ LOW_INT = 0x8DF3
+ MEDIUM_INT = 0x8DF4
+ HIGH_INT = 0x8DF5
+ SHADER_BINARY_FORMATS = 0x8DF8
+ NUM_SHADER_BINARY_FORMATS = 0x8DF9
+ SHADER_COMPILER = 0x8DFA
+ MAX_VERTEX_UNIFORM_VECTORS = 0x8DFB
+ MAX_VARYING_VECTORS = 0x8DFC
+ MAX_FRAGMENT_UNIFORM_VECTORS = 0x8DFD
+ QUERY_WAIT = 0x8E13
+ QUERY_NO_WAIT = 0x8E14
+ QUERY_BY_REGION_WAIT = 0x8E15
+ QUERY_BY_REGION_NO_WAIT = 0x8E16
+ MAX_COMBINED_TESS_CONTROL_UNIFORM_COMPONENTS = 0x8E1E
+ MAX_COMBINED_TESS_EVALUATION_UNIFORM_COMPONENTS = 0x8E1F
+ TRANSFORM_FEEDBACK = 0x8E22
+ TRANSFORM_FEEDBACK_BUFFER_PAUSED = 0x8E23
+ TRANSFORM_FEEDBACK_BUFFER_ACTIVE = 0x8E24
+ TRANSFORM_FEEDBACK_BINDING = 0x8E25
+ TIMESTAMP = 0x8E28
+ TEXTURE_SWIZZLE_R = 0x8E42
+ TEXTURE_SWIZZLE_G = 0x8E43
+ TEXTURE_SWIZZLE_B = 0x8E44
+ TEXTURE_SWIZZLE_A = 0x8E45
+ TEXTURE_SWIZZLE_RGBA = 0x8E46
+ ACTIVE_SUBROUTINE_UNIFORM_LOCATIONS = 0x8E47
+ ACTIVE_SUBROUTINE_MAX_LENGTH = 0x8E48
+ ACTIVE_SUBROUTINE_UNIFORM_MAX_LENGTH = 0x8E49
+ NUM_COMPATIBLE_SUBROUTINES = 0x8E4A
+ COMPATIBLE_SUBROUTINES = 0x8E4B
+ QUADS_FOLLOW_PROVOKING_VERTEX_CONVENTION = 0x8E4C
+ FIRST_VERTEX_CONVENTION = 0x8E4D
+ LAST_VERTEX_CONVENTION = 0x8E4E
+ PROVOKING_VERTEX = 0x8E4F
+ SAMPLE_POSITION = 0x8E50
+ SAMPLE_MASK = 0x8E51
+ SAMPLE_MASK_VALUE = 0x8E52
+ MAX_SAMPLE_MASK_WORDS = 0x8E59
+ MAX_GEOMETRY_SHADER_INVOCATIONS = 0x8E5A
+ MIN_FRAGMENT_INTERPOLATION_OFFSET = 0x8E5B
+ MAX_FRAGMENT_INTERPOLATION_OFFSET = 0x8E5C
+ FRAGMENT_INTERPOLATION_OFFSET_BITS = 0x8E5D
+ MIN_PROGRAM_TEXTURE_GATHER_OFFSET = 0x8E5E
+ MAX_PROGRAM_TEXTURE_GATHER_OFFSET = 0x8E5F
+ MAX_TRANSFORM_FEEDBACK_BUFFERS = 0x8E70
+ MAX_VERTEX_STREAMS = 0x8E71
+ PATCH_VERTICES = 0x8E72
+ PATCH_DEFAULT_INNER_LEVEL = 0x8E73
+ PATCH_DEFAULT_OUTER_LEVEL = 0x8E74
+ TESS_CONTROL_OUTPUT_VERTICES = 0x8E75
+ TESS_GEN_MODE = 0x8E76
+ TESS_GEN_SPACING = 0x8E77
+ TESS_GEN_VERTEX_ORDER = 0x8E78
+ TESS_GEN_POINT_MODE = 0x8E79
+ ISOLINES = 0x8E7A
+ FRACTIONAL_ODD = 0x8E7B
+ FRACTIONAL_EVEN = 0x8E7C
+ MAX_PATCH_VERTICES = 0x8E7D
+ MAX_TESS_GEN_LEVEL = 0x8E7E
+ MAX_TESS_CONTROL_UNIFORM_COMPONENTS = 0x8E7F
+ MAX_TESS_EVALUATION_UNIFORM_COMPONENTS = 0x8E80
+ MAX_TESS_CONTROL_TEXTURE_IMAGE_UNITS = 0x8E81
+ MAX_TESS_EVALUATION_TEXTURE_IMAGE_UNITS = 0x8E82
+ MAX_TESS_CONTROL_OUTPUT_COMPONENTS = 0x8E83
+ MAX_TESS_PATCH_COMPONENTS = 0x8E84
+ MAX_TESS_CONTROL_TOTAL_OUTPUT_COMPONENTS = 0x8E85
+ MAX_TESS_EVALUATION_OUTPUT_COMPONENTS = 0x8E86
+ TESS_EVALUATION_SHADER = 0x8E87
+ TESS_CONTROL_SHADER = 0x8E88
+ MAX_TESS_CONTROL_UNIFORM_BLOCKS = 0x8E89
+ MAX_TESS_EVALUATION_UNIFORM_BLOCKS = 0x8E8A
+ COMPRESSED_RGBA_BPTC_UNORM = 0x8E8C
+ COMPRESSED_SRGB_ALPHA_BPTC_UNORM = 0x8E8D
+ COMPRESSED_RGB_BPTC_SIGNED_FLOAT = 0x8E8E
+ COMPRESSED_RGB_BPTC_UNSIGNED_FLOAT = 0x8E8F
+ COPY_READ_BUFFER = 0x8F36
+ COPY_WRITE_BUFFER = 0x8F37
+ MAX_IMAGE_UNITS = 0x8F38
+ MAX_COMBINED_IMAGE_UNITS_AND_FRAGMENT_OUTPUTS = 0x8F39
+ MAX_COMBINED_SHADER_OUTPUT_RESOURCES = 0x8F39
+ IMAGE_BINDING_NAME = 0x8F3A
+ IMAGE_BINDING_LEVEL = 0x8F3B
+ IMAGE_BINDING_LAYERED = 0x8F3C
+ IMAGE_BINDING_LAYER = 0x8F3D
+ IMAGE_BINDING_ACCESS = 0x8F3E
+ DRAW_INDIRECT_BUFFER = 0x8F3F
+ DRAW_INDIRECT_BUFFER_BINDING = 0x8F43
+ DOUBLE_MAT2 = 0x8F46
+ DOUBLE_MAT3 = 0x8F47
+ DOUBLE_MAT4 = 0x8F48
+ DOUBLE_MAT2x3 = 0x8F49
+ DOUBLE_MAT2x4 = 0x8F4A
+ DOUBLE_MAT3x2 = 0x8F4B
+ DOUBLE_MAT3x4 = 0x8F4C
+ DOUBLE_MAT4x2 = 0x8F4D
+ DOUBLE_MAT4x3 = 0x8F4E
+ VERTEX_BINDING_BUFFER = 0x8F4F
+ R8_SNORM = 0x8F94
+ RG8_SNORM = 0x8F95
+ RGB8_SNORM = 0x8F96
+ RGBA8_SNORM = 0x8F97
+ R16_SNORM = 0x8F98
+ RG16_SNORM = 0x8F99
+ RGB16_SNORM = 0x8F9A
+ RGBA16_SNORM = 0x8F9B
+ SIGNED_NORMALIZED = 0x8F9C
+ PRIMITIVE_RESTART = 0x8F9D
+ PRIMITIVE_RESTART_INDEX = 0x8F9E
+ DOUBLE_VEC2 = 0x8FFC
+ DOUBLE_VEC3 = 0x8FFD
+ DOUBLE_VEC4 = 0x8FFE
+ TEXTURE_CUBE_MAP_ARRAY = 0x9009
+ TEXTURE_BINDING_CUBE_MAP_ARRAY = 0x900A
+ PROXY_TEXTURE_CUBE_MAP_ARRAY = 0x900B
+ SAMPLER_CUBE_MAP_ARRAY = 0x900C
+ SAMPLER_CUBE_MAP_ARRAY_SHADOW = 0x900D
+ INT_SAMPLER_CUBE_MAP_ARRAY = 0x900E
+ UNSIGNED_INT_SAMPLER_CUBE_MAP_ARRAY = 0x900F
+ IMAGE_1D = 0x904C
+ IMAGE_2D = 0x904D
+ IMAGE_3D = 0x904E
+ IMAGE_2D_RECT = 0x904F
+ IMAGE_CUBE = 0x9050
+ IMAGE_BUFFER = 0x9051
+ IMAGE_1D_ARRAY = 0x9052
+ IMAGE_2D_ARRAY = 0x9053
+ IMAGE_CUBE_MAP_ARRAY = 0x9054
+ IMAGE_2D_MULTISAMPLE = 0x9055
+ IMAGE_2D_MULTISAMPLE_ARRAY = 0x9056
+ INT_IMAGE_1D = 0x9057
+ INT_IMAGE_2D = 0x9058
+ INT_IMAGE_3D = 0x9059
+ INT_IMAGE_2D_RECT = 0x905A
+ INT_IMAGE_CUBE = 0x905B
+ INT_IMAGE_BUFFER = 0x905C
+ INT_IMAGE_1D_ARRAY = 0x905D
+ INT_IMAGE_2D_ARRAY = 0x905E
+ INT_IMAGE_CUBE_MAP_ARRAY = 0x905F
+ INT_IMAGE_2D_MULTISAMPLE = 0x9060
+ INT_IMAGE_2D_MULTISAMPLE_ARRAY = 0x9061
+ UNSIGNED_INT_IMAGE_1D = 0x9062
+ UNSIGNED_INT_IMAGE_2D = 0x9063
+ UNSIGNED_INT_IMAGE_3D = 0x9064
+ UNSIGNED_INT_IMAGE_2D_RECT = 0x9065
+ UNSIGNED_INT_IMAGE_CUBE = 0x9066
+ UNSIGNED_INT_IMAGE_BUFFER = 0x9067
+ UNSIGNED_INT_IMAGE_1D_ARRAY = 0x9068
+ UNSIGNED_INT_IMAGE_2D_ARRAY = 0x9069
+ UNSIGNED_INT_IMAGE_CUBE_MAP_ARRAY = 0x906A
+ UNSIGNED_INT_IMAGE_2D_MULTISAMPLE = 0x906B
+ UNSIGNED_INT_IMAGE_2D_MULTISAMPLE_ARRAY = 0x906C
+ MAX_IMAGE_SAMPLES = 0x906D
+ IMAGE_BINDING_FORMAT = 0x906E
+ RGB10_A2UI = 0x906F
+ MIN_MAP_BUFFER_ALIGNMENT = 0x90BC
+ IMAGE_FORMAT_COMPATIBILITY_TYPE = 0x90C7
+ IMAGE_FORMAT_COMPATIBILITY_BY_SIZE = 0x90C8
+ IMAGE_FORMAT_COMPATIBILITY_BY_CLASS = 0x90C9
+ MAX_VERTEX_IMAGE_UNIFORMS = 0x90CA
+ MAX_TESS_CONTROL_IMAGE_UNIFORMS = 0x90CB
+ MAX_TESS_EVALUATION_IMAGE_UNIFORMS = 0x90CC
+ MAX_GEOMETRY_IMAGE_UNIFORMS = 0x90CD
+ MAX_FRAGMENT_IMAGE_UNIFORMS = 0x90CE
+ MAX_COMBINED_IMAGE_UNIFORMS = 0x90CF
+ SHADER_STORAGE_BUFFER = 0x90D2
+ SHADER_STORAGE_BUFFER_BINDING = 0x90D3
+ SHADER_STORAGE_BUFFER_START = 0x90D4
+ SHADER_STORAGE_BUFFER_SIZE = 0x90D5
+ MAX_VERTEX_SHADER_STORAGE_BLOCKS = 0x90D6
+ MAX_GEOMETRY_SHADER_STORAGE_BLOCKS = 0x90D7
+ MAX_TESS_CONTROL_SHADER_STORAGE_BLOCKS = 0x90D8
+ MAX_TESS_EVALUATION_SHADER_STORAGE_BLOCKS = 0x90D9
+ MAX_FRAGMENT_SHADER_STORAGE_BLOCKS = 0x90DA
+ MAX_COMPUTE_SHADER_STORAGE_BLOCKS = 0x90DB
+ MAX_COMBINED_SHADER_STORAGE_BLOCKS = 0x90DC
+ MAX_SHADER_STORAGE_BUFFER_BINDINGS = 0x90DD
+ MAX_SHADER_STORAGE_BLOCK_SIZE = 0x90DE
+ SHADER_STORAGE_BUFFER_OFFSET_ALIGNMENT = 0x90DF
+ DEPTH_STENCIL_TEXTURE_MODE = 0x90EA
+ MAX_COMPUTE_WORK_GROUP_INVOCATIONS = 0x90EB
+ UNIFORM_BLOCK_REFERENCED_BY_COMPUTE_SHADER = 0x90EC
+ ATOMIC_COUNTER_BUFFER_REFERENCED_BY_COMPUTE_SHADER = 0x90ED
+ DISPATCH_INDIRECT_BUFFER = 0x90EE
+ DISPATCH_INDIRECT_BUFFER_BINDING = 0x90EF
+ TEXTURE_2D_MULTISAMPLE = 0x9100
+ PROXY_TEXTURE_2D_MULTISAMPLE = 0x9101
+ TEXTURE_2D_MULTISAMPLE_ARRAY = 0x9102
+ PROXY_TEXTURE_2D_MULTISAMPLE_ARRAY = 0x9103
+ TEXTURE_BINDING_2D_MULTISAMPLE = 0x9104
+ TEXTURE_BINDING_2D_MULTISAMPLE_ARRAY = 0x9105
+ TEXTURE_SAMPLES = 0x9106
+ TEXTURE_FIXED_SAMPLE_LOCATIONS = 0x9107
+ SAMPLER_2D_MULTISAMPLE = 0x9108
+ INT_SAMPLER_2D_MULTISAMPLE = 0x9109
+ UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE = 0x910A
+ SAMPLER_2D_MULTISAMPLE_ARRAY = 0x910B
+ INT_SAMPLER_2D_MULTISAMPLE_ARRAY = 0x910C
+ UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE_ARRAY = 0x910D
+ MAX_COLOR_TEXTURE_SAMPLES = 0x910E
+ MAX_DEPTH_TEXTURE_SAMPLES = 0x910F
+ MAX_INTEGER_SAMPLES = 0x9110
+ MAX_SERVER_WAIT_TIMEOUT = 0x9111
+ OBJECT_TYPE = 0x9112
+ SYNC_CONDITION = 0x9113
+ SYNC_STATUS = 0x9114
+ SYNC_FLAGS = 0x9115
+ SYNC_FENCE = 0x9116
+ SYNC_GPU_COMMANDS_COMPLETE = 0x9117
+ UNSIGNALED = 0x9118
+ SIGNALED = 0x9119
+ ALREADY_SIGNALED = 0x911A
+ TIMEOUT_EXPIRED = 0x911B
+ CONDITION_SATISFIED = 0x911C
+ WAIT_FAILED = 0x911D
+ BUFFER_ACCESS_FLAGS = 0x911F
+ BUFFER_MAP_LENGTH = 0x9120
+ BUFFER_MAP_OFFSET = 0x9121
+ MAX_VERTEX_OUTPUT_COMPONENTS = 0x9122
+ MAX_GEOMETRY_INPUT_COMPONENTS = 0x9123
+ MAX_GEOMETRY_OUTPUT_COMPONENTS = 0x9124
+ MAX_FRAGMENT_INPUT_COMPONENTS = 0x9125
+ CONTEXT_PROFILE_MASK = 0x9126
+ UNPACK_COMPRESSED_BLOCK_WIDTH = 0x9127
+ UNPACK_COMPRESSED_BLOCK_HEIGHT = 0x9128
+ UNPACK_COMPRESSED_BLOCK_DEPTH = 0x9129
+ UNPACK_COMPRESSED_BLOCK_SIZE = 0x912A
+ PACK_COMPRESSED_BLOCK_WIDTH = 0x912B
+ PACK_COMPRESSED_BLOCK_HEIGHT = 0x912C
+ PACK_COMPRESSED_BLOCK_DEPTH = 0x912D
+ PACK_COMPRESSED_BLOCK_SIZE = 0x912E
+ TEXTURE_IMMUTABLE_FORMAT = 0x912F
+ MAX_DEBUG_MESSAGE_LENGTH = 0x9143
+ MAX_DEBUG_LOGGED_MESSAGES = 0x9144
+ DEBUG_LOGGED_MESSAGES = 0x9145
+ DEBUG_SEVERITY_HIGH = 0x9146
+ DEBUG_SEVERITY_MEDIUM = 0x9147
+ DEBUG_SEVERITY_LOW = 0x9148
+ TEXTURE_BUFFER_OFFSET = 0x919D
+ TEXTURE_BUFFER_SIZE = 0x919E
+ TEXTURE_BUFFER_OFFSET_ALIGNMENT = 0x919F
+ COMPUTE_SHADER = 0x91B9
+ MAX_COMPUTE_UNIFORM_BLOCKS = 0x91BB
+ MAX_COMPUTE_TEXTURE_IMAGE_UNITS = 0x91BC
+ MAX_COMPUTE_IMAGE_UNIFORMS = 0x91BD
+ MAX_COMPUTE_WORK_GROUP_COUNT = 0x91BE
+ MAX_COMPUTE_WORK_GROUP_SIZE = 0x91BF
+ COMPRESSED_R11_EAC = 0x9270
+ COMPRESSED_SIGNED_R11_EAC = 0x9271
+ COMPRESSED_RG11_EAC = 0x9272
+ COMPRESSED_SIGNED_RG11_EAC = 0x9273
+ COMPRESSED_RGB8_ETC2 = 0x9274
+ COMPRESSED_SRGB8_ETC2 = 0x9275
+ COMPRESSED_RGB8_PUNCHTHROUGH_ALPHA1_ETC2 = 0x9276
+ COMPRESSED_SRGB8_PUNCHTHROUGH_ALPHA1_ETC2 = 0x9277
+ COMPRESSED_RGBA8_ETC2_EAC = 0x9278
+ COMPRESSED_SRGB8_ALPHA8_ETC2_EAC = 0x9279
+ ATOMIC_COUNTER_BUFFER = 0x92C0
+ ATOMIC_COUNTER_BUFFER_BINDING = 0x92C1
+ ATOMIC_COUNTER_BUFFER_START = 0x92C2
+ ATOMIC_COUNTER_BUFFER_SIZE = 0x92C3
+ ATOMIC_COUNTER_BUFFER_DATA_SIZE = 0x92C4
+ ATOMIC_COUNTER_BUFFER_ACTIVE_ATOMIC_COUNTERS = 0x92C5
+ ATOMIC_COUNTER_BUFFER_ACTIVE_ATOMIC_COUNTER_INDICES = 0x92C6
+ ATOMIC_COUNTER_BUFFER_REFERENCED_BY_VERTEX_SHADER = 0x92C7
+ ATOMIC_COUNTER_BUFFER_REFERENCED_BY_TESS_CONTROL_SHADER = 0x92C8
+ ATOMIC_COUNTER_BUFFER_REFERENCED_BY_TESS_EVALUATION_SHADER = 0x92C9
+ ATOMIC_COUNTER_BUFFER_REFERENCED_BY_GEOMETRY_SHADER = 0x92CA
+ ATOMIC_COUNTER_BUFFER_REFERENCED_BY_FRAGMENT_SHADER = 0x92CB
+ MAX_VERTEX_ATOMIC_COUNTER_BUFFERS = 0x92CC
+ MAX_TESS_CONTROL_ATOMIC_COUNTER_BUFFERS = 0x92CD
+ MAX_TESS_EVALUATION_ATOMIC_COUNTER_BUFFERS = 0x92CE
+ MAX_GEOMETRY_ATOMIC_COUNTER_BUFFERS = 0x92CF
+ MAX_FRAGMENT_ATOMIC_COUNTER_BUFFERS = 0x92D0
+ MAX_COMBINED_ATOMIC_COUNTER_BUFFERS = 0x92D1
+ MAX_VERTEX_ATOMIC_COUNTERS = 0x92D2
+ MAX_TESS_CONTROL_ATOMIC_COUNTERS = 0x92D3
+ MAX_TESS_EVALUATION_ATOMIC_COUNTERS = 0x92D4
+ MAX_GEOMETRY_ATOMIC_COUNTERS = 0x92D5
+ MAX_FRAGMENT_ATOMIC_COUNTERS = 0x92D6
+ MAX_COMBINED_ATOMIC_COUNTERS = 0x92D7
+ MAX_ATOMIC_COUNTER_BUFFER_SIZE = 0x92D8
+ ACTIVE_ATOMIC_COUNTER_BUFFERS = 0x92D9
+ UNIFORM_ATOMIC_COUNTER_BUFFER_INDEX = 0x92DA
+ UNSIGNED_INT_ATOMIC_COUNTER = 0x92DB
+ MAX_ATOMIC_COUNTER_BUFFER_BINDINGS = 0x92DC
+ DEBUG_OUTPUT = 0x92E0
+ UNIFORM = 0x92E1
+ UNIFORM_BLOCK = 0x92E2
+ PROGRAM_INPUT = 0x92E3
+ PROGRAM_OUTPUT = 0x92E4
+ BUFFER_VARIABLE = 0x92E5
+ SHADER_STORAGE_BLOCK = 0x92E6
+ IS_PER_PATCH = 0x92E7
+ VERTEX_SUBROUTINE = 0x92E8
+ TESS_CONTROL_SUBROUTINE = 0x92E9
+ TESS_EVALUATION_SUBROUTINE = 0x92EA
+ GEOMETRY_SUBROUTINE = 0x92EB
+ FRAGMENT_SUBROUTINE = 0x92EC
+ COMPUTE_SUBROUTINE = 0x92ED
+ VERTEX_SUBROUTINE_UNIFORM = 0x92EE
+ TESS_CONTROL_SUBROUTINE_UNIFORM = 0x92EF
+ TESS_EVALUATION_SUBROUTINE_UNIFORM = 0x92F0
+ GEOMETRY_SUBROUTINE_UNIFORM = 0x92F1
+ FRAGMENT_SUBROUTINE_UNIFORM = 0x92F2
+ COMPUTE_SUBROUTINE_UNIFORM = 0x92F3
+ TRANSFORM_FEEDBACK_VARYING = 0x92F4
+ ACTIVE_RESOURCES = 0x92F5
+ MAX_NAME_LENGTH = 0x92F6
+ MAX_NUM_ACTIVE_VARIABLES = 0x92F7
+ MAX_NUM_COMPATIBLE_SUBROUTINES = 0x92F8
+ NAME_LENGTH = 0x92F9
+ TYPE = 0x92FA
+ ARRAY_SIZE = 0x92FB
+ OFFSET = 0x92FC
+ BLOCK_INDEX = 0x92FD
+ ARRAY_STRIDE = 0x92FE
+ MATRIX_STRIDE = 0x92FF
+ IS_ROW_MAJOR = 0x9300
+ ATOMIC_COUNTER_BUFFER_INDEX = 0x9301
+ BUFFER_BINDING = 0x9302
+ BUFFER_DATA_SIZE = 0x9303
+ NUM_ACTIVE_VARIABLES = 0x9304
+ ACTIVE_VARIABLES = 0x9305
+ REFERENCED_BY_VERTEX_SHADER = 0x9306
+ REFERENCED_BY_TESS_CONTROL_SHADER = 0x9307
+ REFERENCED_BY_TESS_EVALUATION_SHADER = 0x9308
+ REFERENCED_BY_GEOMETRY_SHADER = 0x9309
+ REFERENCED_BY_FRAGMENT_SHADER = 0x930A
+ REFERENCED_BY_COMPUTE_SHADER = 0x930B
+ TOP_LEVEL_ARRAY_SIZE = 0x930C
+ TOP_LEVEL_ARRAY_STRIDE = 0x930D
+ LOCATION = 0x930E
+ LOCATION_INDEX = 0x930F
+ FRAMEBUFFER_DEFAULT_WIDTH = 0x9310
+ FRAMEBUFFER_DEFAULT_HEIGHT = 0x9311
+ FRAMEBUFFER_DEFAULT_LAYERS = 0x9312
+ FRAMEBUFFER_DEFAULT_SAMPLES = 0x9313
+ FRAMEBUFFER_DEFAULT_FIXED_SAMPLE_LOCATIONS = 0x9314
+ MAX_FRAMEBUFFER_WIDTH = 0x9315
+ MAX_FRAMEBUFFER_HEIGHT = 0x9316
+ MAX_FRAMEBUFFER_LAYERS = 0x9317
+ MAX_FRAMEBUFFER_SAMPLES = 0x9318
+ NUM_SAMPLE_COUNTS = 0x9380
+)
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glViewport.xml
+func (gl *GL) Viewport(x, y, width, height int) {
+ C.gl4_3core_glViewport(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// DepthRange specifies the mapping of depth values from normalized device
+// coordinates to window coordinates.
+//
+// Parameter nearVal specifies the mapping of the near clipping plane to window
+// coordinates (defaults to 0), while farVal specifies the mapping of the far
+// clipping plane to window coordinates (defaults to 1).
+//
+// After clipping and division by w, depth coordinates range from -1 to 1,
+// corresponding to the near and far clipping planes. DepthRange specifies a
+// linear mapping of the normalized depth coordinates in this range to window
+// depth coordinates. Regardless of the actual depth buffer implementation,
+// window coordinate depth values are treated as though they range from 0 through 1
+// (like color components). Thus, the values accepted by DepthRange are both
+// clamped to this range before they are accepted.
+//
+// The default setting of (0, 1) maps the near plane to 0 and the far plane to 1.
+// With this mapping, the depth buffer range is fully utilized.
+//
+// It is not necessary that nearVal be less than farVal. Reverse mappings such as
+// nearVal 1, and farVal 0 are acceptable.
+//
+// GL.INVALID_OPERATION is generated if DepthRange is executed between the
+// execution of Begin and the corresponding execution of End.
+func (gl *GL) DepthRange(nearVal, farVal float64) {
+ C.gl4_3core_glDepthRange(gl.funcs, C.GLdouble(nearVal), C.GLdouble(farVal))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsEnabled.xml
+func (gl *GL) IsEnabled(cap glbase.Enum) bool {
+ glresult := C.gl4_3core_glIsEnabled(gl.funcs, C.GLenum(cap))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexLevelParameteriv.xml
+func (gl *GL) GetTexLevelParameteriv(target glbase.Enum, level int, pname glbase.Enum, params []int32) {
+ C.gl4_3core_glGetTexLevelParameteriv(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexLevelParameterfv.xml
+func (gl *GL) GetTexLevelParameterfv(target glbase.Enum, level int, pname glbase.Enum, params []float32) {
+ C.gl4_3core_glGetTexLevelParameterfv(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexParameteriv.xml
+func (gl *GL) GetTexParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl4_3core_glGetTexParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexParameterfv.xml
+func (gl *GL) GetTexParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl4_3core_glGetTexParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexImage.xml
+func (gl *GL) GetTexImage(target glbase.Enum, level int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3core_glGetTexImage(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetIntegerv.xml
+func (gl *GL) GetIntegerv(pname glbase.Enum, params []int32) {
+ C.gl4_3core_glGetIntegerv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetFloatv.xml
+func (gl *GL) GetFloatv(pname glbase.Enum, params []float32) {
+ C.gl4_3core_glGetFloatv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetError.xml
+func (gl *GL) GetError() glbase.Enum {
+ glresult := C.gl4_3core_glGetError(gl.funcs)
+ return glbase.Enum(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetDoublev.xml
+func (gl *GL) GetDoublev(pname glbase.Enum, params []float64) {
+ C.gl4_3core_glGetDoublev(gl.funcs, C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetBooleanv.xml
+func (gl *GL) GetBooleanv(pname glbase.Enum, params []bool) {
+ C.gl4_3core_glGetBooleanv(gl.funcs, C.GLenum(pname), (*C.GLboolean)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glReadPixels.xml
+func (gl *GL) ReadPixels(x, y, width, height int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3core_glReadPixels(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glReadBuffer.xml
+func (gl *GL) ReadBuffer(mode glbase.Enum) {
+ C.gl4_3core_glReadBuffer(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPixelStorei.xml
+func (gl *GL) PixelStorei(pname glbase.Enum, param int32) {
+ C.gl4_3core_glPixelStorei(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPixelStoref.xml
+func (gl *GL) PixelStoref(pname glbase.Enum, param float32) {
+ C.gl4_3core_glPixelStoref(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDepthFunc.xml
+func (gl *GL) DepthFunc(glfunc glbase.Enum) {
+ C.gl4_3core_glDepthFunc(gl.funcs, C.GLenum(glfunc))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glStencilOp.xml
+func (gl *GL) StencilOp(fail, zfail, zpass glbase.Enum) {
+ C.gl4_3core_glStencilOp(gl.funcs, C.GLenum(fail), C.GLenum(zfail), C.GLenum(zpass))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glStencilFunc.xml
+func (gl *GL) StencilFunc(glfunc glbase.Enum, ref int32, mask uint32) {
+ C.gl4_3core_glStencilFunc(gl.funcs, C.GLenum(glfunc), C.GLint(ref), C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLogicOp.xml
+func (gl *GL) LogicOp(opcode glbase.Enum) {
+ C.gl4_3core_glLogicOp(gl.funcs, C.GLenum(opcode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendFunc.xml
+func (gl *GL) BlendFunc(sfactor, dfactor glbase.Enum) {
+ C.gl4_3core_glBlendFunc(gl.funcs, C.GLenum(sfactor), C.GLenum(dfactor))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFlush.xml
+func (gl *GL) Flush() {
+ C.gl4_3core_glFlush(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFinish.xml
+func (gl *GL) Finish() {
+ C.gl4_3core_glFinish(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEnable.xml
+func (gl *GL) Enable(cap glbase.Enum) {
+ C.gl4_3core_glEnable(gl.funcs, C.GLenum(cap))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDisable.xml
+func (gl *GL) Disable(cap glbase.Enum) {
+ C.gl4_3core_glDisable(gl.funcs, C.GLenum(cap))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDepthMask.xml
+func (gl *GL) DepthMask(flag bool) {
+ C.gl4_3core_glDepthMask(gl.funcs, *(*C.GLboolean)(unsafe.Pointer(&flag)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorMask.xml
+func (gl *GL) ColorMask(red, green, blue, alpha bool) {
+ C.gl4_3core_glColorMask(gl.funcs, *(*C.GLboolean)(unsafe.Pointer(&red)), *(*C.GLboolean)(unsafe.Pointer(&green)), *(*C.GLboolean)(unsafe.Pointer(&blue)), *(*C.GLboolean)(unsafe.Pointer(&alpha)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glStencilMask.xml
+func (gl *GL) StencilMask(mask uint32) {
+ C.gl4_3core_glStencilMask(gl.funcs, C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearDepth.xml
+func (gl *GL) ClearDepth(depth float64) {
+ C.gl4_3core_glClearDepth(gl.funcs, C.GLdouble(depth))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearStencil.xml
+func (gl *GL) ClearStencil(s int32) {
+ C.gl4_3core_glClearStencil(gl.funcs, C.GLint(s))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearColor.xml
+func (gl *GL) ClearColor(red, green, blue, alpha float32) {
+ C.gl4_3core_glClearColor(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClear.xml
+func (gl *GL) Clear(mask glbase.Bitfield) {
+ C.gl4_3core_glClear(gl.funcs, C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawBuffer.xml
+func (gl *GL) DrawBuffer(mode glbase.Enum) {
+ C.gl4_3core_glDrawBuffer(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexImage2D.xml
+func (gl *GL) TexImage2D(target glbase.Enum, level int, internalFormat int32, width, height, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3core_glTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexImage1D.xml
+func (gl *GL) TexImage1D(target glbase.Enum, level int, internalFormat int32, width, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3core_glTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexParameteriv.xml
+func (gl *GL) TexParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl4_3core_glTexParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexParameteri.xml
+func (gl *GL) TexParameteri(target, pname glbase.Enum, param int32) {
+ C.gl4_3core_glTexParameteri(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexParameterfv.xml
+func (gl *GL) TexParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gl4_3core_glTexParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexParameterf.xml
+func (gl *GL) TexParameterf(target, pname glbase.Enum, param float32) {
+ C.gl4_3core_glTexParameterf(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glScissor.xml
+func (gl *GL) Scissor(x, y, width, height int) {
+ C.gl4_3core_glScissor(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPolygonMode.xml
+func (gl *GL) PolygonMode(face, mode glbase.Enum) {
+ C.gl4_3core_glPolygonMode(gl.funcs, C.GLenum(face), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPointSize.xml
+func (gl *GL) PointSize(size float32) {
+ C.gl4_3core_glPointSize(gl.funcs, C.GLfloat(size))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glLineWidth.xml
+func (gl *GL) LineWidth(width float32) {
+ C.gl4_3core_glLineWidth(gl.funcs, C.GLfloat(width))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glHint.xml
+func (gl *GL) Hint(target, mode glbase.Enum) {
+ C.gl4_3core_glHint(gl.funcs, C.GLenum(target), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFrontFace.xml
+func (gl *GL) FrontFace(mode glbase.Enum) {
+ C.gl4_3core_glFrontFace(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCullFace.xml
+func (gl *GL) CullFace(mode glbase.Enum) {
+ C.gl4_3core_glCullFace(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIndexubv.xml
+func (gl *GL) Indexubv(c []uint8) {
+ C.gl4_3core_glIndexubv(gl.funcs, (*C.GLubyte)(unsafe.Pointer(&c[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIndexub.xml
+func (gl *GL) Indexub(c uint8) {
+ C.gl4_3core_glIndexub(gl.funcs, C.GLubyte(c))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsTexture.xml
+func (gl *GL) IsTexture(texture glbase.Texture) bool {
+ glresult := C.gl4_3core_glIsTexture(gl.funcs, C.GLuint(texture))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// GenTextures returns n texture names in textures. There is no guarantee
+// that the names form a contiguous set of integers; however, it is
+// guaranteed that none of the returned names was in use immediately before
+// the call to GenTextures.
+//
+// The generated textures have no dimensionality; they assume the
+// dimensionality of the texture target to which they are first bound (see
+// BindTexture).
+//
+// Texture names returned by a call to GenTextures are not returned by
+// subsequent calls, unless they are first deleted with DeleteTextures.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// GenTextures is available in GL version 2.0 or greater.
+func (gl *GL) GenTextures(n int) []glbase.Texture {
+ if n == 0 {
+ return nil
+ }
+ textures := make([]glbase.Texture, n)
+ C.gl4_3core_glGenTextures(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])))
+ return textures
+}
+
+// DeleteTextures deletes the textures objects whose names are stored
+// in the textures slice. After a texture is deleted, it has no contents or
+// dimensionality, and its name is free for reuse (for example by
+// GenTextures). If a texture that is currently bound is deleted, the binding
+// reverts to 0 (the default texture).
+//
+// DeleteTextures silently ignores 0's and names that do not correspond to
+// existing textures.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// DeleteTextures is available in GL version 2.0 or greater.
+func (gl *GL) DeleteTextures(textures []glbase.Texture) {
+ n := len(textures)
+ if n == 0 {
+ return
+ }
+ C.gl4_3core_glDeleteTextures(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindTexture.xml
+func (gl *GL) BindTexture(target glbase.Enum, texture glbase.Texture) {
+ C.gl4_3core_glBindTexture(gl.funcs, C.GLenum(target), C.GLuint(texture))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexSubImage2D.xml
+func (gl *GL) TexSubImage2D(target glbase.Enum, level, xoffset, yoffset, width, height int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3core_glTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexSubImage1D.xml
+func (gl *GL) TexSubImage1D(target glbase.Enum, level, xoffset, width int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3core_glTexSubImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLsizei(width), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyTexSubImage2D.xml
+func (gl *GL) CopyTexSubImage2D(target glbase.Enum, level, xoffset, yoffset, x, y, width, height int) {
+ C.gl4_3core_glCopyTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyTexSubImage1D.xml
+func (gl *GL) CopyTexSubImage1D(target glbase.Enum, level, xoffset, x, y, width int) {
+ C.gl4_3core_glCopyTexSubImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(x), C.GLint(y), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyTexImage2D.xml
+func (gl *GL) CopyTexImage2D(target glbase.Enum, level int, internalFormat glbase.Enum, x, y, width, height, border int) {
+ C.gl4_3core_glCopyTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height), C.GLint(border))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyTexImage1D.xml
+func (gl *GL) CopyTexImage1D(target glbase.Enum, level int, internalFormat glbase.Enum, x, y, width, border int) {
+ C.gl4_3core_glCopyTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLint(border))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPolygonOffset.xml
+func (gl *GL) PolygonOffset(factor, units float32) {
+ C.gl4_3core_glPolygonOffset(gl.funcs, C.GLfloat(factor), C.GLfloat(units))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawElements.xml
+func (gl *GL) DrawElements(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3core_glDrawElements(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawArrays.xml
+func (gl *GL) DrawArrays(mode glbase.Enum, first, count int) {
+ C.gl4_3core_glDrawArrays(gl.funcs, C.GLenum(mode), C.GLint(first), C.GLsizei(count))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyTexSubImage3D.xml
+func (gl *GL) CopyTexSubImage3D(target glbase.Enum, level, xoffset, yoffset int, zoffset int32, x, y, width, height int) {
+ C.gl4_3core_glCopyTexSubImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(zoffset), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexSubImage3D.xml
+func (gl *GL) TexSubImage3D(target glbase.Enum, level, xoffset, yoffset int, zoffset int32, width, height int, depth int32, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3core_glTexSubImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(zoffset), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexImage3D.xml
+func (gl *GL) TexImage3D(target glbase.Enum, level int, internalFormat int32, width, height int, depth int32, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3core_glTexImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawRangeElements.xml
+func (gl *GL) DrawRangeElements(mode glbase.Enum, start, end uint32, count int, gltype glbase.Enum, indices interface{}) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3core_glDrawRangeElements(gl.funcs, C.GLenum(mode), C.GLuint(start), C.GLuint(end), C.GLsizei(count), C.GLenum(gltype), indices_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendEquation.xml
+func (gl *GL) BlendEquation(mode glbase.Enum) {
+ C.gl4_3core_glBlendEquation(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendColor.xml
+func (gl *GL) BlendColor(red, green, blue, alpha float32) {
+ C.gl4_3core_glBlendColor(gl.funcs, C.GLfloat(red), C.GLfloat(green), C.GLfloat(blue), C.GLfloat(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetCompressedTexImage.xml
+func (gl *GL) GetCompressedTexImage(target glbase.Enum, level int, img interface{}) {
+ var img_ptr unsafe.Pointer
+ var img_v = reflect.ValueOf(img)
+ if img != nil && img_v.Kind() != reflect.Slice {
+ panic("parameter img must be a slice")
+ }
+ if img != nil {
+ img_ptr = unsafe.Pointer(img_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3core_glGetCompressedTexImage(gl.funcs, C.GLenum(target), C.GLint(level), img_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCompressedTexSubImage1D.xml
+func (gl *GL) CompressedTexSubImage1D(target glbase.Enum, level, xoffset, width int, format glbase.Enum, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3core_glCompressedTexSubImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLsizei(width), C.GLenum(format), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCompressedTexSubImage2D.xml
+func (gl *GL) CompressedTexSubImage2D(target glbase.Enum, level, xoffset, yoffset, width, height int, format glbase.Enum, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3core_glCompressedTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCompressedTexSubImage3D.xml
+func (gl *GL) CompressedTexSubImage3D(target glbase.Enum, level, xoffset, yoffset int, zoffset int32, width, height int, depth int32, format glbase.Enum, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3core_glCompressedTexSubImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(zoffset), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLenum(format), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCompressedTexImage1D.xml
+func (gl *GL) CompressedTexImage1D(target glbase.Enum, level int, internalFormat glbase.Enum, width, border, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3core_glCompressedTexImage1D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLsizei(width), C.GLint(border), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCompressedTexImage2D.xml
+func (gl *GL) CompressedTexImage2D(target glbase.Enum, level int, internalFormat glbase.Enum, width, height, border, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3core_glCompressedTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLint(border), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCompressedTexImage3D.xml
+func (gl *GL) CompressedTexImage3D(target glbase.Enum, level int, internalFormat glbase.Enum, width, height int, depth int32, border, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3core_glCompressedTexImage3D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), C.GLint(border), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSampleCoverage.xml
+func (gl *GL) SampleCoverage(value float32, invert bool) {
+ C.gl4_3core_glSampleCoverage(gl.funcs, C.GLfloat(value), *(*C.GLboolean)(unsafe.Pointer(&invert)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glActiveTexture.xml
+func (gl *GL) ActiveTexture(texture glbase.Enum) {
+ C.gl4_3core_glActiveTexture(gl.funcs, C.GLenum(texture))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPointParameteriv.xml
+func (gl *GL) PointParameteriv(pname glbase.Enum, params []int32) {
+ C.gl4_3core_glPointParameteriv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPointParameteri.xml
+func (gl *GL) PointParameteri(pname glbase.Enum, param int32) {
+ C.gl4_3core_glPointParameteri(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPointParameterfv.xml
+func (gl *GL) PointParameterfv(pname glbase.Enum, params []float32) {
+ C.gl4_3core_glPointParameterfv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPointParameterf.xml
+func (gl *GL) PointParameterf(pname glbase.Enum, param float32) {
+ C.gl4_3core_glPointParameterf(gl.funcs, C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiDrawArrays.xml
+func (gl *GL) MultiDrawArrays(mode glbase.Enum, first, count []int, drawcount int32) {
+ C.gl4_3core_glMultiDrawArrays(gl.funcs, C.GLenum(mode), (*C.GLint)(unsafe.Pointer(&first[0])), (*C.GLsizei)(unsafe.Pointer(&count[0])), C.GLsizei(drawcount))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendFuncSeparate.xml
+func (gl *GL) BlendFuncSeparate(sfactorRGB, dfactorRGB, sfactorAlpha, dfactorAlpha glbase.Enum) {
+ C.gl4_3core_glBlendFuncSeparate(gl.funcs, C.GLenum(sfactorRGB), C.GLenum(dfactorRGB), C.GLenum(sfactorAlpha), C.GLenum(dfactorAlpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetBufferParameteriv.xml
+func (gl *GL) GetBufferParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl4_3core_glGetBufferParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUnmapBuffer.xml
+func (gl *GL) UnmapBuffer(target glbase.Enum) bool {
+ glresult := C.gl4_3core_glUnmapBuffer(gl.funcs, C.GLenum(target))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetBufferSubData.xml
+func (gl *GL) GetBufferSubData(target glbase.Enum, offset, size int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3core_glGetBufferSubData(gl.funcs, C.GLenum(target), C.GLintptr(offset), C.GLsizeiptr(size), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBufferSubData.xml
+func (gl *GL) BufferSubData(target glbase.Enum, offset, size int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3core_glBufferSubData(gl.funcs, C.GLenum(target), C.GLintptr(offset), C.GLsizeiptr(size), data_ptr)
+}
+
+// BufferData creates a new data store for the buffer object currently
+// bound to target. Any pre-existing data store is deleted. The new data
+// store is created with the specified size in bytes and usage. If data is
+// not nil, it must be a slice that is used to initialize the data store.
+// In that case the size parameter is ignored and the store size will match
+// the slice data size.
+//
+// In its initial state, the new data store is not mapped, it has a NULL
+// mapped pointer, and its mapped access is GL.READ_WRITE.
+//
+// The target constant must be one of GL.ARRAY_BUFFER, GL.COPY_READ_BUFFER,
+// GL.COPY_WRITE_BUFFER, GL.ELEMENT_ARRAY_BUFFER, GL.PIXEL_PACK_BUFFER,
+// GL.PIXEL_UNPACK_BUFFER, GL.TEXTURE_BUFFER, GL.TRANSFORM_FEEDBACK_BUFFER,
+// or GL.UNIFORM_BUFFER.
+//
+// The usage parameter is a hint to the GL implementation as to how a buffer
+// object's data store will be accessed. This enables the GL implementation
+// to make more intelligent decisions that may significantly impact buffer
+// object performance. It does not, however, constrain the actual usage of
+// the data store. usage can be broken down into two parts: first, the
+// frequency of access (modification and usage), and second, the nature of
+// that access.
+//
+// A usage frequency of STREAM and nature of DRAW is specified via the
+// constant GL.STREAM_DRAW, for example.
+//
+// The usage frequency of access may be one of:
+//
+// STREAM
+// The data store contents will be modified once and used at most a few times.
+//
+// STATIC
+// The data store contents will be modified once and used many times.
+//
+// DYNAMIC
+// The data store contents will be modified repeatedly and used many times.
+//
+// The usage nature of access may be one of:
+//
+// DRAW
+// The data store contents are modified by the application, and used as
+// the source for GL drawing and image specification commands.
+//
+// READ
+// The data store contents are modified by reading data from the GL,
+// and used to return that data when queried by the application.
+//
+// COPY
+// The data store contents are modified by reading data from the GL,
+// and used as the source for GL drawing and image specification
+// commands.
+//
+// Clients must align data elements consistent with the requirements of the
+// client platform, with an additional base-level requirement that an offset
+// within a buffer to a datum comprising N bytes be a multiple of N.
+//
+// Error GL.INVALID_ENUM is generated if target is not one of the accepted
+// buffer targets. GL.INVALID_ENUM is generated if usage is not
+// GL.STREAM_DRAW, GL.STREAM_READ, GL.STREAM_COPY, GL.STATIC_DRAW,
+// GL.STATIC_READ, GL.STATIC_COPY, GL.DYNAMIC_DRAW, GL.DYNAMIC_READ, or
+// GL.DYNAMIC_COPY. GL.INVALID_VALUE is generated if size is negative.
+// GL.INVALID_OPERATION is generated if the reserved buffer object name 0 is
+// bound to target. GL.OUT_OF_MEMORY is generated if the GL is unable to
+// create a data store with the specified size.
+func (gl *GL) BufferData(target glbase.Enum, size int, data interface{}, usage glbase.Enum) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ if data != nil {
+ size = int(data_v.Type().Size()) * data_v.Len()
+ }
+ C.gl4_3core_glBufferData(gl.funcs, C.GLenum(target), C.GLsizeiptr(size), data_ptr, C.GLenum(usage))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsBuffer.xml
+func (gl *GL) IsBuffer(buffer glbase.Buffer) bool {
+ glresult := C.gl4_3core_glIsBuffer(gl.funcs, C.GLuint(buffer))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// GenBuffers returns n buffer object names. There is no guarantee that
+// the names form a contiguous set of integers; however, it is guaranteed
+// that none of the returned names was in use immediately before the call to
+// GenBuffers.
+//
+// Buffer object names returned by a call to GenBuffers are not returned by
+// subsequent calls, unless they are first deleted with DeleteBuffers.
+//
+// No buffer objects are associated with the returned buffer object names
+// until they are first bound by calling BindBuffer.
+//
+// Error GL.INVALID_VALUE is generated if n is negative. GL.INVALID_OPERATION
+// is generated if GenBuffers is executed between the execution of Begin
+// and the corresponding execution of End.
+//
+// GenBuffers is available in GL version 1.5 or greater.
+func (gl *GL) GenBuffers(n int) []glbase.Buffer {
+ if n == 0 {
+ return nil
+ }
+ buffers := make([]glbase.Buffer, n)
+ C.gl4_3core_glGenBuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&buffers[0])))
+ return buffers
+}
+
+// DeleteBuffers deletes the buffer objects whose names are stored in the
+// buffers slice.
+//
+// After a buffer object is deleted, it has no contents, and its name is free
+// for reuse (for example by GenBuffers). If a buffer object that is
+// currently bound is deleted, the binding reverts to 0 (the absence of any
+// buffer object, which reverts to client memory usage).
+//
+// DeleteBuffers silently ignores 0's and names that do not correspond to
+// existing buffer objects.
+//
+// Error GL.INVALID_VALUE is generated if n is negative. GL.INVALID_OPERATION
+// is generated if DeleteBuffers is executed between the execution of Begin
+// and the corresponding execution of End.
+//
+// DeleteBuffers is available in GL version 1.5 or greater.
+func (gl *GL) DeleteBuffers(buffers []glbase.Buffer) {
+ n := len(buffers)
+ if n == 0 {
+ return
+ }
+ C.gl4_3core_glDeleteBuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&buffers[0])))
+}
+
+// BindBuffer creates or puts in use a named buffer object.
+// Calling BindBuffer with target set to GL.ARRAY_BUFFER,
+// GL.ELEMENT_ARRAY_BUFFER, GL.PIXEL_PACK_BUFFER or GL.PIXEL_UNPACK_BUFFER
+// and buffer set to the name of the new buffer object binds the buffer
+// object name to the target. When a buffer object is bound to a target, the
+// previous binding for that target is automatically broken.
+//
+// Buffer object names are unsigned integers. The value zero is reserved, but
+// there is no default buffer object for each buffer object target. Instead,
+// buffer set to zero effectively unbinds any buffer object previously bound,
+// and restores client memory usage for that buffer object target. Buffer
+// object names and the corresponding buffer object contents are local to the
+// shared display-list space (see XCreateContext) of the current GL rendering
+// context; two rendering contexts share buffer object names only if they
+// also share display lists.
+//
+// GenBuffers may be called to generate a set of new buffer object names.
+//
+// The state of a buffer object immediately after it is first bound is an
+// unmapped zero-sized memory buffer with GL.READ_WRITE access and
+// GL.STATIC_DRAW usage.
+//
+// While a non-zero buffer object name is bound, GL operations on the target
+// to which it is bound affect the bound buffer object, and queries of the
+// target to which it is bound return state from the bound buffer object.
+// While buffer object name zero is bound, as in the initial state, attempts
+// to modify or query state on the target to which it is bound generates an
+// GL.INVALID_OPERATION error.
+//
+// When vertex array pointer state is changed, for example by a call to
+// NormalPointer, the current buffer object binding (GL.ARRAY_BUFFER_BINDING)
+// is copied into the corresponding client state for the vertex array type
+// being changed, for example GL.NORMAL_ARRAY_BUFFER_BINDING. While a
+// non-zero buffer object is bound to the GL.ARRAY_BUFFER target, the vertex
+// array pointer parameter that is traditionally interpreted as a pointer to
+// client-side memory is instead interpreted as an offset within the buffer
+// object measured in basic machine units.
+//
+// While a non-zero buffer object is bound to the GL.ELEMENT_ARRAY_BUFFER
+// target, the indices parameter of DrawElements, DrawRangeElements, or
+// MultiDrawElements that is traditionally interpreted as a pointer to
+// client-side memory is instead interpreted as an offset within the buffer
+// object measured in basic machine units.
+//
+// While a non-zero buffer object is bound to the GL.PIXEL_PACK_BUFFER
+// target, the following commands are affected: GetCompressedTexImage,
+// GetConvolutionFilter, GetHistogram, GetMinmax, GetPixelMap,
+// GetPolygonStipple, GetSeparableFilter, GetTexImage, and ReadPixels. The
+// pointer parameter that is traditionally interpreted as a pointer to
+// client-side memory where the pixels are to be packed is instead
+// interpreted as an offset within the buffer object measured in basic
+// machine units.
+//
+// While a non-zero buffer object is bound to the GL.PIXEL_UNPACK_BUFFER
+// target, the following commands are affected: Bitmap, ColorSubTable,
+// ColorTable, CompressedTexImage1D, CompressedTexImage2D,
+// CompressedTexImage3D, CompressedTexSubImage1D, CompressedTexSubImage2D,
+// CompressedTexSubImage3D, ConvolutionFilter1D, ConvolutionFilter2D,
+// DrawPixels, PixelMap, PolygonStipple, SeparableFilter2D, TexImage1D,
+// TexImage2D, TexImage3D, TexSubImage1D, TexSubImage2D, and TexSubImage3D.
+// The pointer parameter that is traditionally interpreted as a pointer to
+// client-side memory from which the pixels are to be unpacked is instead
+// interpreted as an offset within the buffer object measured in basic
+// machine units.
+//
+// A buffer object binding created with BindBuffer remains active until a
+// different buffer object name is bound to the same target, or until the
+// bound buffer object is deleted with DeleteBuffers.
+//
+// Once created, a named buffer object may be re-bound to any target as often
+// as needed. However, the GL implementation may make choices about how to
+// optimize the storage of a buffer object based on its initial binding
+// target.
+//
+// Error GL.INVALID_ENUM is generated if target is not one of the allowable
+// values. GL.INVALID_OPERATION is generated if BindBuffer is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// BindBuffer is available in GL version 1.5 or greater.
+func (gl *GL) BindBuffer(target glbase.Enum, buffer glbase.Buffer) {
+ C.gl4_3core_glBindBuffer(gl.funcs, C.GLenum(target), C.GLuint(buffer))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetQueryObjectuiv.xml
+func (gl *GL) GetQueryObjectuiv(id uint32, pname glbase.Enum, params []uint32) {
+ C.gl4_3core_glGetQueryObjectuiv(gl.funcs, C.GLuint(id), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetQueryObjectiv.xml
+func (gl *GL) GetQueryObjectiv(id uint32, pname glbase.Enum, params []int32) {
+ C.gl4_3core_glGetQueryObjectiv(gl.funcs, C.GLuint(id), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetQueryiv.xml
+func (gl *GL) GetQueryiv(target, pname glbase.Enum, params []int32) {
+ C.gl4_3core_glGetQueryiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEndQuery.xml
+func (gl *GL) EndQuery(target glbase.Enum) {
+ C.gl4_3core_glEndQuery(gl.funcs, C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBeginQuery.xml
+func (gl *GL) BeginQuery(target glbase.Enum, id uint32) {
+ C.gl4_3core_glBeginQuery(gl.funcs, C.GLenum(target), C.GLuint(id))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsQuery.xml
+func (gl *GL) IsQuery(id uint32) bool {
+ glresult := C.gl4_3core_glIsQuery(gl.funcs, C.GLuint(id))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDeleteQueries.xml
+func (gl *GL) DeleteQueries(n int, ids []uint32) {
+ C.gl4_3core_glDeleteQueries(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&ids[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGenQueries.xml
+func (gl *GL) GenQueries(n int, ids []uint32) {
+ C.gl4_3core_glGenQueries(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&ids[0])))
+}
+
+// VertexAttribPointer specifies the location and data format of the array
+// of generic vertex attributes at index to use when rendering. size
+// specifies the number of components per attribute and must be 1, 2, 3, or
+// 4. type specifies the data type of each component, and stride specifies
+// the byte stride from one attribute to the next, allowing vertices and
+// attributes to be packed into a single array or stored in separate arrays.
+// normalized indicates whether the values stored in an integer format are
+// to be mapped to the range [-1,1] (for signed values) or [0,1]
+// (for unsigned values) when they are accessed and converted to floating
+// point; otherwise, values will be converted to floats directly without
+// normalization. offset is a byte offset into the buffer object's data
+// store, which must be bound to the GL.ARRAY_BUFFER target with BindBuffer.
+//
+// The buffer object binding (GL.ARRAY_BUFFER_BINDING) is saved as
+// generic vertex attribute array client-side state
+// (GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING) for the provided index.
+//
+// To enable and disable a generic vertex attribute array, call
+// EnableVertexAttribArray and DisableVertexAttribArray with index. If
+// enabled, the generic vertex attribute array is used when DrawArrays or
+// DrawElements is called. Each generic vertex attribute array is initially
+// disabled.
+//
+// VertexAttribPointer is typically implemented on the client side.
+//
+// Error GL.INVALID_ENUM is generated if type is not an accepted value.
+// GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_VALUE is generated if size is not 1, 2,
+// 3, or 4. GL.INVALID_VALUE is generated if stride is negative.
+func (gl *GL) VertexAttribPointer(index glbase.Attrib, size int, gltype glbase.Enum, normalized bool, stride int, offset uintptr) {
+ offset_ptr := unsafe.Pointer(offset)
+ C.gl4_3core_glVertexAttribPointer(gl.funcs, C.GLuint(index), C.GLint(size), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), C.GLsizei(stride), offset_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glValidateProgram.xml
+func (gl *GL) ValidateProgram(program glbase.Program) {
+ C.gl4_3core_glValidateProgram(gl.funcs, C.GLuint(program))
+}
+
+// UniformMatrix4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix4fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(4*4) != 0 {
+ panic("invalid value length for UniformMatrix4fv")
+ }
+ count := len(value) / (4 * 4)
+ C.gl4_3core_glUniformMatrix4fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix3fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(3*3) != 0 {
+ panic("invalid value length for UniformMatrix3fv")
+ }
+ count := len(value) / (3 * 3)
+ C.gl4_3core_glUniformMatrix3fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix2fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(2*2) != 0 {
+ panic("invalid value length for UniformMatrix2fv")
+ }
+ count := len(value) / (2 * 2)
+ C.gl4_3core_glUniformMatrix2fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform4iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%4 != 0 {
+ panic("invalid value length for Uniform4iv")
+ }
+ count := len(value) / 4
+ C.gl4_3core_glUniform4iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform3iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform3iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%3 != 0 {
+ panic("invalid value length for Uniform3iv")
+ }
+ count := len(value) / 3
+ C.gl4_3core_glUniform3iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform2iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform2iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%2 != 0 {
+ panic("invalid value length for Uniform2iv")
+ }
+ count := len(value) / 2
+ C.gl4_3core_glUniform2iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform1iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform1iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ count := len(value)
+ C.gl4_3core_glUniform1iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%4 != 0 {
+ panic("invalid value length for Uniform4fv")
+ }
+ count := len(value) / 4
+ C.gl4_3core_glUniform4fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%3 != 0 {
+ panic("invalid value length for Uniform3fv")
+ }
+ count := len(value) / 3
+ C.gl4_3core_glUniform3fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%2 != 0 {
+ panic("invalid value length for Uniform2fv")
+ }
+ count := len(value) / 2
+ C.gl4_3core_glUniform2fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform1fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform1fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ count := len(value)
+ C.gl4_3core_glUniform1fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform4i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4i(location glbase.Uniform, v0, v1, v2, v3 int32) {
+ C.gl4_3core_glUniform4i(gl.funcs, C.GLint(location), C.GLint(v0), C.GLint(v1), C.GLint(v2), C.GLint(v3))
+}
+
+// Uniform3i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform3i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3i(location glbase.Uniform, v0, v1, v2 int32) {
+ C.gl4_3core_glUniform3i(gl.funcs, C.GLint(location), C.GLint(v0), C.GLint(v1), C.GLint(v2))
+}
+
+// Uniform2i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform2i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2i(location glbase.Uniform, v0, v1 int32) {
+ C.gl4_3core_glUniform2i(gl.funcs, C.GLint(location), C.GLint(v0), C.GLint(v1))
+}
+
+// Uniform1i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform1i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1i(location glbase.Uniform, v0 int32) {
+ C.gl4_3core_glUniform1i(gl.funcs, C.GLint(location), C.GLint(v0))
+}
+
+// Uniform4f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform4f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4f(location glbase.Uniform, v0, v1, v2, v3 float32) {
+ C.gl4_3core_glUniform4f(gl.funcs, C.GLint(location), C.GLfloat(v0), C.GLfloat(v1), C.GLfloat(v2), C.GLfloat(v3))
+}
+
+// Uniform3f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform3f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3f(location glbase.Uniform, v0, v1, v2 float32) {
+ C.gl4_3core_glUniform3f(gl.funcs, C.GLint(location), C.GLfloat(v0), C.GLfloat(v1), C.GLfloat(v2))
+}
+
+// Uniform2f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform2f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2f(location glbase.Uniform, v0, v1 float32) {
+ C.gl4_3core_glUniform2f(gl.funcs, C.GLint(location), C.GLfloat(v0), C.GLfloat(v1))
+}
+
+// Uniform1f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform1f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1f(location glbase.Uniform, v0 float32) {
+ C.gl4_3core_glUniform1f(gl.funcs, C.GLint(location), C.GLfloat(v0))
+}
+
+// UseProgram installs the program object specified by program as part of
+// current rendering state. One or more executables are created in a program
+// object by successfully attaching shader objects to it with AttachShader,
+// successfully compiling the shader objects with CompileShader, and
+// successfully linking the program object with LinkProgram.
+//
+// A program object will contain an executable that will run on the vertex
+// processor if it contains one or more shader objects of type
+// GL.VERTEX_SHADER that have been successfully compiled and linked.
+// Similarly, a program object will contain an executable that will run on
+// the fragment processor if it contains one or more shader objects of type
+// GL.FRAGMENT_SHADER that have been successfully compiled and linked.
+//
+// Successfully installing an executable on a programmable processor will
+// cause the corresponding fixed functionality of OpenGL to be disabled.
+// Specifically, if an executable is installed on the vertex processor, the
+// OpenGL fixed functionality will be disabled as follows.
+//
+// - The modelview matrix is not applied to vertex coordinates.
+//
+// - The projection matrix is not applied to vertex coordinates.
+//
+// - The texture matrices are not applied to texture coordinates.
+//
+// - Normals are not transformed to eye coordinates.
+//
+// - Normals are not rescaled or normalized.
+//
+// - Normalization of GL.AUTO_NORMAL evaluated normals is not performed.
+//
+// - Texture coordinates are not generated automatically.
+//
+// - Per-vertex lighting is not performed.
+//
+// - Color material computations are not performed.
+//
+// - Color index lighting is not performed.
+//
+// - This list also applies when setting the current raster position.
+//
+// The executable that is installed on the vertex processor is expected to
+// implement any or all of the desired functionality from the preceding list.
+// Similarly, if an executable is installed on the fragment processor, the
+// OpenGL fixed functionality will be disabled as follows.
+//
+// - Texture environment and texture functions are not applied.
+//
+// - Texture application is not applied.
+//
+// - Color sum is not applied.
+//
+// - Fog is not applied.
+//
+// Again, the fragment shader that is installed is expected to implement any
+// or all of the desired functionality from the preceding list.
+//
+// While a program object is in use, applications are free to modify attached
+// shader objects, compile attached shader objects, attach additional shader
+// objects, and detach or delete shader objects. None of these operations
+// will affect the executables that are part of the current state. However,
+// relinking the program object that is currently in use will install the
+// program object as part of the current rendering state if the link
+// operation was successful (see LinkProgram). If the program object
+// currently in use is relinked unsuccessfully, its link status will be set
+// to GL.FALSE, but the executables and associated state will remain part of
+// the current state until a subsequent call to UseProgram removes it from
+// use. After it is removed from use, it cannot be made part of current state
+// until it has been successfully relinked.
+//
+// If program contains shader objects of type GL.VERTEX_SHADER but it does
+// not contain shader objects of type GL.FRAGMENT_SHADER, an executable will
+// be installed on the vertex processor, but fixed functionality will be used
+// for fragment processing. Similarly, if program contains shader objects of
+// type GL.FRAGMENT_SHADER but it does not contain shader objects of type
+// GL.VERTEX_SHADER, an executable will be installed on the fragment
+// processor, but fixed functionality will be used for vertex processing. If
+// program is 0, the programmable processors will be disabled, and fixed
+// functionality will be used for both vertex and fragment processing.
+//
+// While a program object is in use, the state that controls the disabled
+// fixed functionality may also be updated using the normal OpenGL calls.
+//
+// Like display lists and texture objects, the name space for program objects
+// may be shared across a set of contexts, as long as the server sides of the
+// contexts share the same address space. If the name space is shared across
+// contexts, any attached objects and the data associated with those attached
+// objects are shared as well.
+//
+// Applications are responsible for providing the synchronization across API
+// calls when objects are accessed from different execution threads.
+//
+// Error GL.INVALID_VALUE is generated if program is neither 0 nor a value
+// generated by OpenGL. GL.INVALID_OPERATION is generated if program is not
+// a program object. GL.INVALID_OPERATION is generated if program could not
+// be made part of current state. GL.INVALID_OPERATION is generated if
+// UseProgram is executed between the execution of Begin and the
+// corresponding execution of End.
+//
+// UseProgram is available in GL version 2.0 or greater.
+func (gl *GL) UseProgram(program glbase.Program) {
+ C.gl4_3core_glUseProgram(gl.funcs, C.GLuint(program))
+}
+
+// ShaderSource sets the source code in shader to the provided source code. Any source
+// code previously stored in the shader object is completely replaced.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader is not a shader
+// object. GL.INVALID_VALUE is generated if count is less than 0.
+// GL.INVALID_OPERATION is generated if ShaderSource is executed between the
+// execution of Begin and the corresponding execution of End.
+//
+// ShaderSource is available in GL version 2.0 or greater.
+func (gl *GL) ShaderSource(shader glbase.Shader, source ...string) {
+ count := len(source)
+ length := make([]int32, count)
+ source_c := make([]unsafe.Pointer, count)
+ for i, src := range source {
+ length[i] = int32(len(src))
+ if len(src) > 0 {
+ source_c[i] = *(*unsafe.Pointer)(unsafe.Pointer(&src))
+ } else {
+ source_c[i] = unsafe.Pointer(uintptr(0))
+ }
+ }
+ C.gl4_3core_glShaderSource(gl.funcs, C.GLuint(shader), C.GLsizei(count), (**C.GLchar)(unsafe.Pointer(&source_c[0])), (*C.GLint)(unsafe.Pointer(&length[0])))
+}
+
+// LinkProgram links the program object specified by program. If any shader
+// objects of type GL.VERTEX_SHADER are attached to program, they will be
+// used to create an executable that will run on the programmable vertex
+// processor. If any shader objects of type GL.FRAGMENT_SHADER are attached
+// to program, they will be used to create an executable that will run on the
+// programmable fragment processor.
+//
+// The status of the link operation will be stored as part of the program
+// object's state. This value will be set to GL.TRUE if the program object
+// was linked without errors and is ready for use, and GL.FALSE otherwise. It
+// can be queried by calling GetProgramiv with arguments program and
+// GL.LINK_STATUS.
+//
+// As a result of a successful link operation, all active user-defined
+// uniform variables belonging to program will be initialized to 0, and each
+// of the program object's active uniform variables will be assigned a
+// location that can be queried by calling GetUniformLocation. Also, any
+// active user-defined attribute variables that have not been bound to a
+// generic vertex attribute index will be bound to one at this time.
+//
+// Linking of a program object can fail for a number of reasons as specified
+// in the OpenGL Shading Language Specification. The following lists some of
+// the conditions that will cause a link error.
+//
+// - The number of active attribute variables supported by the
+// implementation has been exceeded.
+//
+// - The storage limit for uniform variables has been exceeded.
+//
+// - The number of active uniform variables supported by the implementation
+// has been exceeded.
+//
+// - The main function is missing for the vertex shader or the fragment
+// shader.
+//
+// - A varying variable actually used in the fragment shader is not
+// declared in the same way (or is not declared at all) in the vertex
+// shader.
+//
+// - A reference to a function or variable name is unresolved.
+//
+// - A shared global is declared with two different types or two different
+// initial values.
+//
+// - One or more of the attached shader objects has not been successfully
+// compiled.
+//
+// - Binding a generic attribute matrix caused some rows of the matrix to
+// fall outside the allowed maximum of GL.MAX_VERTEX_ATTRIBS.
+//
+// - Not enough contiguous vertex attribute slots could be found to bind
+// attribute matrices.
+//
+// When a program object has been successfully linked, the program object can
+// be made part of current state by calling UseProgram. Whether or not the
+// link operation was successful, the program object's information log will
+// be overwritten. The information log can be retrieved by calling
+// GetProgramInfoLog.
+//
+// LinkProgram will also install the generated executables as part of the
+// current rendering state if the link operation was successful and the
+// specified program object is already currently in use as a result of a
+// previous call to UseProgram. If the program object currently in use is
+// relinked unsuccessfully, its link status will be set to GL.FALSE , but the
+// executables and associated state will remain part of the current state
+// until a subsequent call to UseProgram removes it from use. After it is
+// removed from use, it cannot be made part of current state until it has
+// been successfully relinked.
+//
+// If program contains shader objects of type GL.VERTEX_SHADER but does not
+// contain shader objects of type GL.FRAGMENT_SHADER, the vertex shader will
+// be linked against the implicit interface for fixed functionality fragment
+// processing. Similarly, if program contains shader objects of type
+// GL.FRAGMENT_SHADER but it does not contain shader objects of type
+// GL.VERTEX_SHADER, the fragment shader will be linked against the implicit
+// interface for fixed functionality vertex processing.
+//
+// The program object's information log is updated and the program is
+// generated at the time of the link operation. After the link operation,
+// applications are free to modify attached shader objects, compile attached
+// shader objects, detach shader objects, delete shader objects, and attach
+// additional shader objects. None of these operations affects the
+// information log or the program that is part of the program object.
+//
+// If the link operation is unsuccessful, any information about a previous
+// link operation on program is lost (a failed link does not restore the
+// old state of program). Certain information can still be retrieved
+// from program even after an unsuccessful link operation. See for instance
+// GetActiveAttrib and GetActiveUniform.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program
+// object. GL.INVALID_OPERATION is generated if LinkProgram is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// LinkProgram is available in GL version 2.0 or greater.
+func (gl *GL) LinkProgram(program glbase.Program) {
+ C.gl4_3core_glLinkProgram(gl.funcs, C.GLuint(program))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsShader.xml
+func (gl *GL) IsShader(shader glbase.Shader) bool {
+ glresult := C.gl4_3core_glIsShader(gl.funcs, C.GLuint(shader))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsProgram.xml
+func (gl *GL) IsProgram(program glbase.Program) bool {
+ glresult := C.gl4_3core_glIsProgram(gl.funcs, C.GLuint(program))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// GetVertexAttribiv returns in params the value of a generic vertex attribute
+// parameter. The generic vertex attribute to be queried is specified by
+// index, and the parameter to be queried is specified by pname.
+//
+// The accepted parameter names are as follows:
+//
+// GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING
+// params returns a single value, the name of the buffer object
+// currently bound to the binding point corresponding to generic vertex
+// attribute array index. If no buffer object is bound, 0 is returned.
+// The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_ENABLED
+// params returns a single value that is non-zero (true) if the vertex
+// attribute array for index is enabled and 0 (false) if it is
+// disabled. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_SIZE
+// params returns a single value, the size of the vertex attribute
+// array for index. The size is the number of values for each element
+// of the vertex attribute array, and it will be 1, 2, 3, or 4. The
+// initial value is 4.
+//
+// GL.VERTEX_ATTRIB_ARRAY_STRIDE
+// params returns a single value, the array stride for (number of bytes
+// between successive elements in) the vertex attribute array for
+// index. A value of 0 indicates that the array elements are stored
+// sequentially in memory. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_TYPE
+// params returns a single value, a symbolic constant indicating the
+// array type for the vertex attribute array for index. Possible values
+// are GL.BYTE, GL.UNSIGNED_BYTE, GL.SHORT, GL.UNSIGNED_SHORT, GL.INT,
+// GL.UNSIGNED_INT, GL.FLOAT, and GL.DOUBLE. The initial value is
+// GL.FLOAT.
+//
+// GL.VERTEX_ATTRIB_ARRAY_NORMALIZED
+// params returns a single value that is non-zero (true) if fixed-point
+// data types for the vertex attribute array indicated by index are
+// normalized when they are converted to floating point, and 0 (false)
+// otherwise. The initial value is 0.
+//
+// GL.CURRENT_VERTEX_ATTRIB
+// params returns four values that represent the current value for the
+// generic vertex attribute specified by index. Generic vertex
+// attribute 0 is unique in that it has no current state, so an error
+// will be generated if index is 0. The initial value for all other
+// generic vertex attributes is (0,0,0,1).
+//
+// All of the parameters except GL.CURRENT_VERTEX_ATTRIB represent
+// client-side state.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_ENUM is generated if pname is not an
+// accepted value. GL.INVALID_OPERATION is generated if index is 0 and pname
+// is GL.CURRENT_VERTEX_ATTRIB.
+//
+// GetVertexAttribiv is available in GL version 2.0 or greater.
+func (gl *GL) GetVertexAttribiv(index glbase.Attrib, pname glbase.Enum, params []int32) {
+ var params_c [4]int32
+ C.gl4_3core_glGetVertexAttribiv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetVertexAttribfv returns in params the value of a generic vertex attribute
+// parameter. The generic vertex attribute to be queried is specified by
+// index, and the parameter to be queried is specified by pname.
+//
+// The accepted parameter names are as follows:
+//
+// GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING
+// params returns a single value, the name of the buffer object
+// currently bound to the binding point corresponding to generic vertex
+// attribute array index. If no buffer object is bound, 0 is returned.
+// The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_ENABLED
+// params returns a single value that is non-zero (true) if the vertex
+// attribute array for index is enabled and 0 (false) if it is
+// disabled. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_SIZE
+// params returns a single value, the size of the vertex attribute
+// array for index. The size is the number of values for each element
+// of the vertex attribute array, and it will be 1, 2, 3, or 4. The
+// initial value is 4.
+//
+// GL.VERTEX_ATTRIB_ARRAY_STRIDE
+// params returns a single value, the array stride for (number of bytes
+// between successive elements in) the vertex attribute array for
+// index. A value of 0 indicates that the array elements are stored
+// sequentially in memory. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_TYPE
+// params returns a single value, a symbolic constant indicating the
+// array type for the vertex attribute array for index. Possible values
+// are GL.BYTE, GL.UNSIGNED_BYTE, GL.SHORT, GL.UNSIGNED_SHORT, GL.INT,
+// GL.UNSIGNED_INT, GL.FLOAT, and GL.DOUBLE. The initial value is
+// GL.FLOAT.
+//
+// GL.VERTEX_ATTRIB_ARRAY_NORMALIZED
+// params returns a single value that is non-zero (true) if fixed-point
+// data types for the vertex attribute array indicated by index are
+// normalized when they are converted to floating point, and 0 (false)
+// otherwise. The initial value is 0.
+//
+// GL.CURRENT_VERTEX_ATTRIB
+// params returns four values that represent the current value for the
+// generic vertex attribute specified by index. Generic vertex
+// attribute 0 is unique in that it has no current state, so an error
+// will be generated if index is 0. The initial value for all other
+// generic vertex attributes is (0,0,0,1).
+//
+// All of the parameters except GL.CURRENT_VERTEX_ATTRIB represent
+// client-side state.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_ENUM is generated if pname is not an
+// accepted value. GL.INVALID_OPERATION is generated if index is 0 and pname
+// is GL.CURRENT_VERTEX_ATTRIB.
+//
+// GetVertexAttribfv is available in GL version 2.0 or greater.
+func (gl *GL) GetVertexAttribfv(index glbase.Attrib, pname glbase.Enum, params []float32) {
+ var params_c [4]float32
+ C.gl4_3core_glGetVertexAttribfv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetVertexAttribdv returns in params the value of a generic vertex attribute
+// parameter. The generic vertex attribute to be queried is specified by
+// index, and the parameter to be queried is specified by pname.
+//
+// The accepted parameter names are as follows:
+//
+// GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING
+// params returns a single value, the name of the buffer object
+// currently bound to the binding point corresponding to generic vertex
+// attribute array index. If no buffer object is bound, 0 is returned.
+// The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_ENABLED
+// params returns a single value that is non-zero (true) if the vertex
+// attribute array for index is enabled and 0 (false) if it is
+// disabled. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_SIZE
+// params returns a single value, the size of the vertex attribute
+// array for index. The size is the number of values for each element
+// of the vertex attribute array, and it will be 1, 2, 3, or 4. The
+// initial value is 4.
+//
+// GL.VERTEX_ATTRIB_ARRAY_STRIDE
+// params returns a single value, the array stride for (number of bytes
+// between successive elements in) the vertex attribute array for
+// index. A value of 0 indicates that the array elements are stored
+// sequentially in memory. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_TYPE
+// params returns a single value, a symbolic constant indicating the
+// array type for the vertex attribute array for index. Possible values
+// are GL.BYTE, GL.UNSIGNED_BYTE, GL.SHORT, GL.UNSIGNED_SHORT, GL.INT,
+// GL.UNSIGNED_INT, GL.FLOAT, and GL.DOUBLE. The initial value is
+// GL.FLOAT.
+//
+// GL.VERTEX_ATTRIB_ARRAY_NORMALIZED
+// params returns a single value that is non-zero (true) if fixed-point
+// data types for the vertex attribute array indicated by index are
+// normalized when they are converted to floating point, and 0 (false)
+// otherwise. The initial value is 0.
+//
+// GL.CURRENT_VERTEX_ATTRIB
+// params returns four values that represent the current value for the
+// generic vertex attribute specified by index. Generic vertex
+// attribute 0 is unique in that it has no current state, so an error
+// will be generated if index is 0. The initial value for all other
+// generic vertex attributes is (0,0,0,1).
+//
+// All of the parameters except GL.CURRENT_VERTEX_ATTRIB represent
+// client-side state.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_ENUM is generated if pname is not an
+// accepted value. GL.INVALID_OPERATION is generated if index is 0 and pname
+// is GL.CURRENT_VERTEX_ATTRIB.
+//
+// GetVertexAttribdv is available in GL version 2.0 or greater.
+func (gl *GL) GetVertexAttribdv(index glbase.Attrib, pname glbase.Enum, params []float64) {
+ var params_c [4]float64
+ C.gl4_3core_glGetVertexAttribdv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetUniformiv returns in params the value of the specified uniform
+// variable. The type of the uniform variable specified by location
+// determines the number of values returned. If the uniform variable is
+// defined in the shader as a boolean, int, or float, a single value will be
+// returned. If it is defined as a vec2, ivec2, or bvec2, two values will be
+// returned. If it is defined as a vec3, ivec3, or bvec3, three values will
+// be returned, and so on. To query values stored in uniform variables
+// declared as arrays, call GetUniformiv for each element of the array. To
+// query values stored in uniform variables declared as structures, call
+// GetUniformiv for each field in the structure. The values for uniform
+// variables declared as a matrix will be returned in column major order.
+//
+// The locations assigned to uniform variables are not known until the
+// program object is linked. After linking has occurred, the command
+// GetUniformLocation can be used to obtain the location of a uniform
+// variable. This location value can then be passed to GetUniformiv in order
+// to query the current value of the uniform variable. After a program object
+// has been linked successfully, the index values for uniform variables
+// remain fixed until the next link command occurs. The uniform variable
+// values can only be queried after a link if the link was successful.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program
+// object. GL.INVALID_OPERATION is generated if program has not been
+// successfully linked. GL.INVALID_OPERATION is generated if location does
+// not correspond to a valid uniform variable location for the specified
+// program object. GL.INVALID_OPERATION is generated if GetUniformiv is
+// executed between the execution of Begin and the corresponding execution of
+// End.
+//
+// GetUniformiv is available in GL version 2.0 or greater.
+func (gl *GL) GetUniformiv(program glbase.Program, location glbase.Uniform, params []int32) {
+ var params_c [4]int32
+ C.gl4_3core_glGetUniformiv(gl.funcs, C.GLuint(program), C.GLint(location), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetUniformfv returns in params the value of the specified uniform
+// variable. The type of the uniform variable specified by location
+// determines the number of values returned. If the uniform variable is
+// defined in the shader as a boolean, int, or float, a single value will be
+// returned. If it is defined as a vec2, ivec2, or bvec2, two values will be
+// returned. If it is defined as a vec3, ivec3, or bvec3, three values will
+// be returned, and so on. To query values stored in uniform variables
+// declared as arrays, call GetUniformfv for each element of the array. To
+// query values stored in uniform variables declared as structures, call
+// GetUniformfv for each field in the structure. The values for uniform
+// variables declared as a matrix will be returned in column major order.
+//
+// The locations assigned to uniform variables are not known until the
+// program object is linked. After linking has occurred, the command
+// GetUniformLocation can be used to obtain the location of a uniform
+// variable. This location value can then be passed to GetUniformfv in order
+// to query the current value of the uniform variable. After a program object
+// has been linked successfully, the index values for uniform variables
+// remain fixed until the next link command occurs. The uniform variable
+// values can only be queried after a link if the link was successful.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program
+// object. GL.INVALID_OPERATION is generated if program has not been
+// successfully linked. GL.INVALID_OPERATION is generated if location does
+// not correspond to a valid uniform variable location for the specified
+// program object. GL.INVALID_OPERATION is generated if GetUniformfv is
+// executed between the execution of Begin and the corresponding execution of
+// End.
+//
+// GetUniformfv is available in GL version 2.0 or greater.
+func (gl *GL) GetUniformfv(program glbase.Program, location glbase.Uniform, params []float32) {
+ var params_c [4]float32
+ C.gl4_3core_glGetUniformfv(gl.funcs, C.GLuint(program), C.GLint(location), (*C.GLfloat)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetUniformLocation returns an integer that represents the location of a
+// specific uniform variable within a program object. name must be an active
+// uniform variable name in program that is not a structure, an array of
+// structures, or a subcomponent of a vector or a matrix. This function
+// returns -1 if name does not correspond to an active uniform variable in
+// program or if name starts with the reserved prefix "gl_".
+//
+// Uniform variables that are structures or arrays of structures may be
+// queried by calling GetUniformLocation for each field within the
+// structure. The array element operator "[]" and the structure field
+// operator "." may be used in name in order to select elements within an
+// array or fields within a structure. The result of using these operators is
+// not allowed to be another structure, an array of structures, or a
+// subcomponent of a vector or a matrix. Except if the last part of name
+// indicates a uniform variable array, the location of the first element of
+// an array can be retrieved by using the name of the array, or by using the
+// name appended by "[0]".
+//
+// The actual locations assigned to uniform variables are not known until the
+// program object is linked successfully. After linking has occurred, the
+// command GetUniformLocation can be used to obtain the location of a
+// uniform variable. This location value can then be passed to Uniform to
+// set the value of the uniform variable or to GetUniform in order to query
+// the current value of the uniform variable. After a program object has been
+// linked successfully, the index values for uniform variables remain fixed
+// until the next link command occurs. Uniform variable locations and values
+// can only be queried after a link if the link was successful.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program object.
+// GL.INVALID_OPERATION is generated if program has not been successfully
+// linked. GL.INVALID_OPERATION is generated if GetUniformLocation is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// GetUniformLocation is available in GL version 2.0 or greater.
+func (gl *GL) GetUniformLocation(program glbase.Program, name string) glbase.Uniform {
+ name_cstr := C.CString(name)
+ glresult := C.gl4_3core_glGetUniformLocation(gl.funcs, C.GLuint(program), (*C.GLchar)(name_cstr))
+ C.free(unsafe.Pointer(name_cstr))
+ return glbase.Uniform(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetShaderSource.xml
+func (gl *GL) GetShaderSource(shader glbase.Shader, bufSize int32, length []int32, source []byte) {
+ C.gl4_3core_glGetShaderSource(gl.funcs, C.GLuint(shader), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&source[0])))
+}
+
+// GetShaderInfoLog returns the information log for the specified shader
+// object. The information log for a shader object is modified when the
+// shader is compiled.
+//
+// The information log for a shader object is a string that may contain
+// diagnostic messages, warning messages, and other information about the
+// last compile operation. When a shader object is created, its information
+// log will be a string of length 0, and the size of the current log can be
+// obtained by calling GetShaderiv with the value GL.INFO_LOG_LENGTH.
+//
+// The information log for a shader object is the OpenGL implementer's
+// primary mechanism for conveying information about the compilation process.
+// Therefore, the information log can be helpful to application developers
+// during the development process, even when compilation is successful.
+// Application developers should not expect different OpenGL implementations
+// to produce identical information logs.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader is not a shader
+// object. GL.INVALID_VALUE is generated if maxLength is less than 0.
+// GL.INVALID_OPERATION is generated if GetShaderInfoLog is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// GetShaderInfoLog is available in GL version 2.0 or greater.
+func (gl *GL) GetShaderInfoLog(shader glbase.Shader) []byte {
+ var params [1]int32
+ var length int32
+ gl.GetShaderiv(shader, INFO_LOG_LENGTH, params[:])
+ bufSize := params[0]
+ infoLog := make([]byte, int(bufSize))
+ C.gl4_3core_glGetShaderInfoLog(gl.funcs, C.GLuint(shader), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length)), (*C.GLchar)(unsafe.Pointer(&infoLog[0])))
+ return infoLog
+}
+
+// GetShaderiv GetShader returns in params the value of a parameter for a specific
+// shader object. The following parameters are defined:
+//
+// GL.SHADER_TYPE
+// params returns GL.VERTEX_SHADER if shader is a vertex shader object,
+// and GL.FRAGMENT_SHADER if shader is a fragment shader object.
+//
+// GL.DELETE_STATUS
+// params returns GL.TRUE if shader is currently flagged for deletion,
+// and GL.FALSE otherwise.
+//
+// GL.COMPILE_STATUS
+// params returns GL.TRUE if the last compile operation on shader was
+// successful, and GL.FALSE otherwise.
+//
+// GL.INFO_LOG_LENGTH
+// params returns the number of characters in the information log for
+// shader including the null termination character (the size of the
+// character buffer required to store the information log). If shader has
+// no information log, a value of 0 is returned.
+//
+// GL.SHADER_SOURCE_LENGTH
+// params returns the length of the concatenation of the source strings
+// that make up the shader source for the shader, including the null
+// termination character. (the size of the character buffer
+// required to store the shader source). If no source code exists, 0 is
+// returned.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader does not refer to a
+// shader object. GL.INVALID_ENUM is generated if pname is not an accepted
+// value. GL.INVALID_OPERATION is generated if GetShader is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// GetShaderiv is available in GL version 2.0 or greater.
+func (gl *GL) GetShaderiv(shader glbase.Shader, pname glbase.Enum, params []int32) {
+ var params_c [4]int32
+ C.gl4_3core_glGetShaderiv(gl.funcs, C.GLuint(shader), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetProgramInfoLog returns the information log for the specified program
+// object. The information log for a program object is modified when the
+// program object is linked or validated.
+//
+// The information log for a program object is either an empty string, or a
+// string containing information about the last link operation, or a string
+// containing information about the last validation operation. It may contain
+// diagnostic messages, warning messages, and other information. When a
+// program object is created, its information log will be a string of length
+// 0, and the size of the current log can be obtained by calling GetProgramiv
+// with the value GL.INFO_LOG_LENGTH.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated
+// by OpenGL. GL.INVALID_OPERATION is generated if program is not a
+// program object.
+func (gl *GL) GetProgramInfoLog(program glbase.Program) []byte {
+ var params [1]int32
+ var length int32
+ gl.GetProgramiv(program, INFO_LOG_LENGTH, params[:])
+ bufSize := params[0]
+ infoLog := make([]byte, int(bufSize))
+ C.gl4_3core_glGetProgramInfoLog(gl.funcs, C.GLuint(program), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length)), (*C.GLchar)(unsafe.Pointer(&infoLog[0])))
+ return infoLog
+}
+
+// GetProgramiv returns in params the value of a parameter for a specific
+// program object. The following parameters are defined:
+//
+// GL.DELETE_STATUS
+// params returns GL.TRUE if program is currently flagged for deletion,
+// and GL.FALSE otherwise.
+//
+// GL.LINK_STATUS
+// params returns GL.TRUE if the last link operation on program was
+// successful, and GL.FALSE otherwise.
+//
+// GL.VALIDATE_STATUS
+// params returns GL.TRUE or if the last validation operation on
+// program was successful, and GL.FALSE otherwise.
+//
+// GL.INFO_LOG_LENGTH
+// params returns the number of characters in the information log for
+// program including the null termination character (the size of
+// the character buffer required to store the information log). If
+// program has no information log, a value of 0 is returned.
+//
+// GL.ATTACHED_SHADERS
+// params returns the number of shader objects attached to program.
+//
+// GL.ACTIVE_ATTRIBUTES
+// params returns the number of active attribute variables for program.
+//
+// GL.ACTIVE_ATTRIBUTE_MAX_LENGTH
+// params returns the length of the longest active attribute name for
+// program, including the null termination character (the size of
+// the character buffer required to store the longest attribute name).
+// If no active attributes exist, 0 is returned.
+//
+// GL.ACTIVE_UNIFORMS
+// params returns the number of active uniform variables for program.
+//
+// GL.ACTIVE_UNIFORM_MAX_LENGTH
+// params returns the length of the longest active uniform variable
+// name for program, including the null termination character (i.e.,
+// the size of the character buffer required to store the longest
+// uniform variable name). If no active uniform variables exist, 0 is
+// returned.
+//
+// GL.TRANSFORM_FEEDBACK_BUFFER_MODE
+// params returns a symbolic constant indicating the buffer mode used
+// when transform feedback is active. This may be GL.SEPARATE_ATTRIBS
+// or GL.INTERLEAVED_ATTRIBS.
+//
+// GL.TRANSFORM_FEEDBACK_VARYINGS
+// params returns the number of varying variables to capture in transform
+// feedback mode for the program.
+//
+// GL.TRANSFORM_FEEDBACK_VARYING_MAX_LENGTH
+// params returns the length of the longest variable name to be used for
+// transform feedback, including the null-terminator.
+//
+// GL.GEOMETRY_VERTICES_OUT
+// params returns the maximum number of vertices that the geometry shader in
+// program will output.
+//
+// GL.GEOMETRY_INPUT_TYPE
+// params returns a symbolic constant indicating the primitive type accepted
+// as input to the geometry shader contained in program.
+//
+// GL.GEOMETRY_OUTPUT_TYPE
+// params returns a symbolic constant indicating the primitive type that will
+// be output by the geometry shader contained in program.
+//
+// GL.ACTIVE_UNIFORM_BLOCKS and GL.ACTIVE_UNIFORM_BLOCK_MAX_NAME_LENGTH are
+// available only if the GL version 3.1 or greater.
+//
+// GL.GEOMETRY_VERTICES_OUT, GL.GEOMETRY_INPUT_TYPE and
+// GL.GEOMETRY_OUTPUT_TYPE are accepted only if the GL version is 3.2 or
+// greater.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program does not refer to a
+// program object. GL.INVALID_OPERATION is generated if pname is
+// GL.GEOMETRY_VERTICES_OUT, GL.GEOMETRY_INPUT_TYPE, or
+// GL.GEOMETRY_OUTPUT_TYPE, and program does not contain a geometry shader.
+// GL.INVALID_ENUM is generated if pname is not an accepted value.
+func (gl *GL) GetProgramiv(program glbase.Program, pname glbase.Enum, params []int32) {
+ var params_c [4]int32
+ C.gl4_3core_glGetProgramiv(gl.funcs, C.GLuint(program), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetAttribLocation queries the previously linked program object specified
+// by program for the attribute variable specified by name and returns the
+// index of the generic vertex attribute that is bound to that attribute
+// variable. If name is a matrix attribute variable, the index of the first
+// column of the matrix is returned. If the named attribute variable is not
+// an active attribute in the specified program object or if name starts with
+// the reserved prefix "gl_", a value of -1 is returned.
+//
+// The association between an attribute variable name and a generic attribute
+// index can be specified at any time by calling BindAttribLocation.
+// Attribute bindings do not go into effect until LinkProgram is called.
+// After a program object has been linked successfully, the index values for
+// attribute variables remain fixed until the next link command occurs. The
+// attribute values can only be queried after a link if the link was
+// successful. GetAttribLocation returns the binding that actually went
+// into effect the last time LinkProgram was called for the specified
+// program object. Attribute bindings that have been specified since the last
+// link operation are not returned by GetAttribLocation.
+//
+// Error GL_INVALID_OPERATION is generated if program is not a value
+// generated by OpenGL. GL_INVALID_OPERATION is generated if program is not
+// a program object. GL_INVALID_OPERATION is generated if program has not
+// been successfully linked. GL_INVALID_OPERATION is generated if
+// GetAttribLocation is executed between the execution of Begin and the
+// corresponding execution of End.
+//
+// GetAttribLocation is available in GL version 2.0 or greater.
+func (gl *GL) GetAttribLocation(program glbase.Program, name string) glbase.Attrib {
+ name_cstr := C.CString(name)
+ glresult := C.gl4_3core_glGetAttribLocation(gl.funcs, C.GLuint(program), (*C.GLchar)(name_cstr))
+ C.free(unsafe.Pointer(name_cstr))
+ return glbase.Attrib(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetAttachedShaders.xml
+func (gl *GL) GetAttachedShaders(program glbase.Program, maxCount int32, count []int, obj []uint32) {
+ C.gl4_3core_glGetAttachedShaders(gl.funcs, C.GLuint(program), C.GLsizei(maxCount), (*C.GLsizei)(unsafe.Pointer(&count[0])), (*C.GLuint)(unsafe.Pointer(&obj[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveUniform.xml
+func (gl *GL) GetActiveUniform(program glbase.Program, index uint32, bufSize int32, length []int32, size []int, gltype []glbase.Enum, name []byte) {
+ C.gl4_3core_glGetActiveUniform(gl.funcs, C.GLuint(program), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLint)(unsafe.Pointer(&size[0])), (*C.GLenum)(unsafe.Pointer(&gltype[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveAttrib.xml
+func (gl *GL) GetActiveAttrib(program glbase.Program, index glbase.Attrib, bufSize int32, length []int32, size []int, gltype []glbase.Enum, name []byte) {
+ C.gl4_3core_glGetActiveAttrib(gl.funcs, C.GLuint(program), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLint)(unsafe.Pointer(&size[0])), (*C.GLenum)(unsafe.Pointer(&gltype[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEnableVertexAttribArray.xml
+func (gl *GL) EnableVertexAttribArray(index glbase.Attrib) {
+ C.gl4_3core_glEnableVertexAttribArray(gl.funcs, C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDisableVertexAttribArray.xml
+func (gl *GL) DisableVertexAttribArray(index glbase.Attrib) {
+ C.gl4_3core_glDisableVertexAttribArray(gl.funcs, C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDetachShader.xml
+func (gl *GL) DetachShader(program glbase.Program, shader glbase.Shader) {
+ C.gl4_3core_glDetachShader(gl.funcs, C.GLuint(program), C.GLuint(shader))
+}
+
+// DeleteShader frees the memory and invalidates the name associated with
+// the shader object specified by shader. This command effectively undoes the
+// effects of a call to CreateShader.
+//
+// If a shader object to be deleted is attached to a program object, it will
+// be flagged for deletion, but it will not be deleted until it is no longer
+// attached to any program object, for any rendering context (it must
+// be detached from wherever it was attached before it will be deleted). A
+// value of 0 for shader will be silently ignored.
+//
+// To determine whether an object has been flagged for deletion, call
+// GetShader with arguments shader and GL.DELETE_STATUS.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL.
+//
+// DeleteShader is available in GL version 2.0 or greater.
+func (gl *GL) DeleteShader(shader glbase.Shader) {
+ C.gl4_3core_glDeleteShader(gl.funcs, C.GLuint(shader))
+}
+
+// DeleteProgram frees the memory and invalidates the name associated with
+// the program object specified by program. This command effectively undoes
+// the effects of a call to CreateProgram.
+//
+// If a program object is in use as part of current rendering state, it will
+// be flagged for deletion, but it will not be deleted until it is no longer
+// part of current state for any rendering context. If a program object to be
+// deleted has shader objects attached to it, those shader objects will be
+// automatically detached but not deleted unless they have already been
+// flagged for deletion by a previous call to DeleteShader. A value of 0
+// for program will be silently ignored.
+//
+// To determine whether a program object has been flagged for deletion, call
+// GetProgram with arguments program and GL.DELETE_STATUS.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL.
+//
+// DeleteProgram is available in GL version 2.0 or greater.
+func (gl *GL) DeleteProgram(program glbase.Program) {
+ C.gl4_3core_glDeleteProgram(gl.funcs, C.GLuint(program))
+}
+
+// CreateShader creates an empty shader object and returns a non-zero value
+// by which it can be referenced. A shader object is used to maintain the
+// source code strings that define a shader. shaderType indicates the type of
+// shader to be created.
+//
+// Two types of shaders are supported. A shader of type GL.VERTEX_SHADER is a
+// shader that is intended to run on the programmable vertex processor and
+// replace the fixed functionality vertex processing in OpenGL. A shader of
+// type GL.FRAGMENT_SHADER is a shader that is intended to run on the
+// programmable fragment processor and replace the fixed functionality
+// fragment processing in OpenGL.
+//
+// When created, a shader object's GL.SHADER_TYPE parameter is set to either
+// GL.VERTEX_SHADER or GL.FRAGMENT_SHADER, depending on the value of
+// shaderType.
+//
+// Like display lists and texture objects, the name space for shader objects
+// may be shared across a set of contexts, as long as the server sides of the
+// contexts share the same address space. If the name space is shared across
+// contexts, any attached objects and the data associated with those attached
+// objects are shared as well.
+//
+// This function returns 0 if an error occurs creating the shader object.
+//
+// Error GL.INVALID_ENUM is generated if shaderType is not an accepted value.
+// GL.INVALID_OPERATION is generated if CreateShader is executed between the
+// execution of Begin and the corresponding execution of End.
+//
+// CreateShader is available in GL version 2.0 or greater.
+func (gl *GL) CreateShader(gltype glbase.Enum) glbase.Shader {
+ glresult := C.gl4_3core_glCreateShader(gl.funcs, C.GLenum(gltype))
+ return glbase.Shader(glresult)
+}
+
+// CreateProgram creates an empty program object and returns a non-zero
+// value by which it can be referenced. A program object is an object to
+// which shader objects can be attached. This provides a mechanism to specify
+// the shader objects that will be linked to create a program. It also
+// provides a means for checking the compatibility of the shaders that will
+// be used to create a program (for instance, checking the compatibility
+// between a vertex shader and a fragment shader). When no longer needed as
+// part of a program object, shader objects can be detached.
+//
+// One or more executables are created in a program object by successfully
+// attaching shader objects to it with AttachShader, successfully compiling
+// the shader objects with CompileShader, and successfully linking the
+// program object with LinkProgram. These executables are made part of
+// current state when UseProgram is called. Program objects can be deleted
+// by calling DeleteProgram. The memory associated with the program object
+// will be deleted when it is no longer part of current rendering state for
+// any context.
+//
+// Like display lists and texture objects, the name space for program objects
+// may be shared across a set of contexts, as long as the server sides of the
+// contexts share the same address space. If the name space is shared across
+// contexts, any attached objects and the data associated with those attached
+// objects are shared as well.
+//
+// Applications are responsible for providing the synchronization across API
+// calls when objects are accessed from different execution threads.
+//
+// This function returns 0 if an error occurs creating the program object.
+//
+// Error GL.INVALID_OPERATION is generated if CreateProgram is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// CreateProgram is available in GL version 2.0 or greater.
+func (gl *GL) CreateProgram() glbase.Program {
+ glresult := C.gl4_3core_glCreateProgram(gl.funcs)
+ return glbase.Program(glresult)
+}
+
+// CompileShader compiles the source code strings that have been stored in
+// the shader object specified by shader.
+//
+// The compilation status will be stored as part of the shader object's
+// state. This value will be set to GL.TRUE if the shader was compiled without
+// errors and is ready for use, and GL.FALSE otherwise. It can be queried by
+// calling GetShaderiv with arguments shader and GL.COMPILE_STATUS.
+//
+// Compilation of a shader can fail for a number of reasons as specified by
+// the OpenGL Shading Language Specification. Whether or not the compilation
+// was successful, information about the compilation can be obtained from the
+// shader object's information log by calling GetShaderInfoLog.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader is not a shader
+// object. GL.INVALID_OPERATION is generated if CompileShader is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// CompileShader is available in GL version 2.0 or greater.
+func (gl *GL) CompileShader(shader glbase.Shader) {
+ C.gl4_3core_glCompileShader(gl.funcs, C.GLuint(shader))
+}
+
+// BindAttribLocation associates a user-defined attribute variable in the program
+// object specified by program with a generic vertex attribute index. The name
+// parameter specifies the name of the vertex shader attribute variable to
+// which index is to be bound. When program is made part of the current state,
+// values provided via the generic vertex attribute index will modify the
+// value of the user-defined attribute variable specified by name.
+//
+// If name refers to a matrix attribute variable, index refers to the first
+// column of the matrix. Other matrix columns are then automatically bound to
+// locations index+1 for a matrix of type mat2; index+1 and index+2 for a
+// matrix of type mat3; and index+1, index+2, and index+3 for a matrix of
+// type mat4.
+//
+// This command makes it possible for vertex shaders to use descriptive names
+// for attribute variables rather than generic variables that are numbered
+// from 0 to GL.MAX_VERTEX_ATTRIBS-1. The values sent to each generic
+// attribute index are part of current state, just like standard vertex
+// attributes such as color, normal, and vertex position. If a different
+// program object is made current by calling UseProgram, the generic vertex
+// attributes are tracked in such a way that the same values will be observed
+// by attributes in the new program object that are also bound to index.
+//
+// Attribute variable name-to-generic attribute index bindings for a program
+// object can be explicitly assigned at any time by calling
+// BindAttribLocation. Attribute bindings do not go into effect until
+// LinkProgram is called. After a program object has been linked
+// successfully, the index values for generic attributes remain fixed (and
+// their values can be queried) until the next link command occurs.
+//
+// Applications are not allowed to bind any of the standard OpenGL vertex
+// attributes using this command, as they are bound automatically when
+// needed. Any attribute binding that occurs after the program object has
+// been linked will not take effect until the next time the program object is
+// linked.
+//
+// If name was bound previously, that information is lost. Thus you cannot
+// bind one user-defined attribute variable to multiple indices, but you can
+// bind multiple user-defined attribute variables to the same index.
+//
+// Applications are allowed to bind more than one user-defined attribute
+// variable to the same generic vertex attribute index. This is called
+// aliasing, and it is allowed only if just one of the aliased attributes is
+// active in the executable program, or if no path through the shader
+// consumes more than one attribute of a set of attributes aliased to the
+// same location. The compiler and linker are allowed to assume that no
+// aliasing is done and are free to employ optimizations that work only in
+// the absence of aliasing. OpenGL implementations are not required to do
+// error checking to detect aliasing. Because there is no way to bind
+// standard attributes, it is not possible to alias generic attributes with
+// conventional ones (except for generic attribute 0).
+//
+// BindAttribLocation can be called before any vertex shader objects are
+// bound to the specified program object. It is also permissible to bind a
+// generic attribute index to an attribute variable name that is never used
+// in a vertex shader.
+//
+// Active attributes that are not explicitly bound will be bound by the
+// linker when LinkProgram is called. The locations assigned can be queried
+// by calling GetAttribLocation.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS.
+// GL.INVALID_OPERATION is generated if name starts with the reserved prefix "gl_".
+// GL.INVALID_VALUE is generated if program is not a value generated by OpenGL.
+// GL.INVALID_OPERATION is generated if program is not a program object.
+// GL.INVALID_OPERATION is generated if BindAttribLocation is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// BindAttribLocation is available in GL version 2.0 or greater.
+func (gl *GL) BindAttribLocation(program glbase.Program, index glbase.Attrib, name string) {
+ name_cstr := C.CString(name)
+ C.gl4_3core_glBindAttribLocation(gl.funcs, C.GLuint(program), C.GLuint(index), (*C.GLchar)(name_cstr))
+ C.free(unsafe.Pointer(name_cstr))
+}
+
+// AttachShader attaches a shader object to a program object.
+//
+// In order to create an executable, there must be a way to specify the list
+// of things that will be linked together. Program objects provide this
+// mechanism. Shaders that are to be linked together in a program object must
+// first be attached to that program object. This indicates that shader will
+// be included in link operations that will be performed on program.
+//
+// All operations that can be performed on a shader object are valid whether
+// or not the shader object is attached to a program object. It is
+// permissible to attach a shader object to a program object before source
+// code has been loaded into the shader object or before the shader object
+// has been compiled. It is permissible to attach multiple shader objects of
+// the same type because each may contain a portion of the complete shader.
+// It is also permissible to attach a shader object to more than one program
+// object. If a shader object is deleted while it is attached to a program
+// object, it will be flagged for deletion, and deletion will not occur until
+// DetachShader is called to detach it from all program objects to which it
+// is attached.
+//
+// Error GL.INVALID_VALUE is generated if either program or shader is not a
+// value generated by OpenGL. GL.INVALID_OPERATION is generated if program
+// is not a program object. GL.INVALID_OPERATION is generated if shader is
+// not a shader object. GL.INVALID_OPERATION is generated if shader is
+// already attached to program. GL.INVALID_OPERATION is generated if
+// AttachShader is executed between the execution of Begin and the
+// corresponding execution of End.
+//
+// AttachShader is available in GL version 2.0 or greater.
+func (gl *GL) AttachShader(program glbase.Program, shader glbase.Shader) {
+ C.gl4_3core_glAttachShader(gl.funcs, C.GLuint(program), C.GLuint(shader))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glStencilMaskSeparate.xml
+func (gl *GL) StencilMaskSeparate(face glbase.Enum, mask uint32) {
+ C.gl4_3core_glStencilMaskSeparate(gl.funcs, C.GLenum(face), C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glStencilFuncSeparate.xml
+func (gl *GL) StencilFuncSeparate(face, glfunc glbase.Enum, ref int32, mask uint32) {
+ C.gl4_3core_glStencilFuncSeparate(gl.funcs, C.GLenum(face), C.GLenum(glfunc), C.GLint(ref), C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glStencilOpSeparate.xml
+func (gl *GL) StencilOpSeparate(face, sfail, dpfail, dppass glbase.Enum) {
+ C.gl4_3core_glStencilOpSeparate(gl.funcs, C.GLenum(face), C.GLenum(sfail), C.GLenum(dpfail), C.GLenum(dppass))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawBuffers.xml
+func (gl *GL) DrawBuffers(n int, bufs []glbase.Enum) {
+ C.gl4_3core_glDrawBuffers(gl.funcs, C.GLsizei(n), (*C.GLenum)(unsafe.Pointer(&bufs[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendEquationSeparate.xml
+func (gl *GL) BlendEquationSeparate(modeRGB, modeAlpha glbase.Enum) {
+ C.gl4_3core_glBlendEquationSeparate(gl.funcs, C.GLenum(modeRGB), C.GLenum(modeAlpha))
+}
+
+// UniformMatrix4x3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix4x3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix4x3fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(4*3) != 0 {
+ panic("invalid value length for UniformMatrix4x3fv")
+ }
+ count := len(value) / (4 * 3)
+ C.gl4_3core_glUniformMatrix4x3fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix3x4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix3x4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix3x4fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(3*4) != 0 {
+ panic("invalid value length for UniformMatrix3x4fv")
+ }
+ count := len(value) / (3 * 4)
+ C.gl4_3core_glUniformMatrix3x4fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix4x2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix4x2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix4x2fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(4*2) != 0 {
+ panic("invalid value length for UniformMatrix4x2fv")
+ }
+ count := len(value) / (4 * 2)
+ C.gl4_3core_glUniformMatrix4x2fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix2x4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix2x4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix2x4fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(2*4) != 0 {
+ panic("invalid value length for UniformMatrix2x4fv")
+ }
+ count := len(value) / (2 * 4)
+ C.gl4_3core_glUniformMatrix2x4fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix3x2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix3x2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix3x2fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(3*2) != 0 {
+ panic("invalid value length for UniformMatrix3x2fv")
+ }
+ count := len(value) / (3 * 2)
+ C.gl4_3core_glUniformMatrix3x2fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix2x3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix2x3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix2x3fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(2*3) != 0 {
+ panic("invalid value length for UniformMatrix2x3fv")
+ }
+ count := len(value) / (2 * 3)
+ C.gl4_3core_glUniformMatrix2x3fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsVertexArray.xml
+func (gl *GL) IsVertexArray(array uint32) bool {
+ glresult := C.gl4_3core_glIsVertexArray(gl.funcs, C.GLuint(array))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGenVertexArrays.xml
+func (gl *GL) GenVertexArrays(n int, arrays []uint32) {
+ C.gl4_3core_glGenVertexArrays(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&arrays[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDeleteVertexArrays.xml
+func (gl *GL) DeleteVertexArrays(n int, arrays []uint32) {
+ C.gl4_3core_glDeleteVertexArrays(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&arrays[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindVertexArray.xml
+func (gl *GL) BindVertexArray(array uint32) {
+ C.gl4_3core_glBindVertexArray(gl.funcs, C.GLuint(array))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFlushMappedBufferRange.xml
+func (gl *GL) FlushMappedBufferRange(target glbase.Enum, offset, length int) {
+ C.gl4_3core_glFlushMappedBufferRange(gl.funcs, C.GLenum(target), C.GLintptr(offset), C.GLsizeiptr(length))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFramebufferTextureLayer.xml
+func (gl *GL) FramebufferTextureLayer(target, attachment glbase.Enum, texture glbase.Texture, level int, layer int32) {
+ C.gl4_3core_glFramebufferTextureLayer(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLuint(texture), C.GLint(level), C.GLint(layer))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRenderbufferStorageMultisample.xml
+func (gl *GL) RenderbufferStorageMultisample(target glbase.Enum, samples int32, internalFormat glbase.Enum, width, height int) {
+ C.gl4_3core_glRenderbufferStorageMultisample(gl.funcs, C.GLenum(target), C.GLsizei(samples), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlitFramebuffer.xml
+func (gl *GL) BlitFramebuffer(srcX0, srcY0, srcX1, srcY1, dstX0, dstY0, dstX1, dstY1 int32, mask glbase.Bitfield, filter glbase.Enum) {
+ C.gl4_3core_glBlitFramebuffer(gl.funcs, C.GLint(srcX0), C.GLint(srcY0), C.GLint(srcX1), C.GLint(srcY1), C.GLint(dstX0), C.GLint(dstY0), C.GLint(dstX1), C.GLint(dstY1), C.GLbitfield(mask), C.GLenum(filter))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGenerateMipmap.xml
+func (gl *GL) GenerateMipmap(target glbase.Enum) {
+ C.gl4_3core_glGenerateMipmap(gl.funcs, C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetFramebufferAttachmentParameteriv.xml
+func (gl *GL) GetFramebufferAttachmentParameteriv(target, attachment, pname glbase.Enum, params []int32) {
+ C.gl4_3core_glGetFramebufferAttachmentParameteriv(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFramebufferRenderbuffer.xml
+func (gl *GL) FramebufferRenderbuffer(target, attachment, renderbuffertarget glbase.Enum, renderbuffer glbase.Renderbuffer) {
+ C.gl4_3core_glFramebufferRenderbuffer(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(renderbuffertarget), C.GLuint(renderbuffer))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFramebufferTexture3D.xml
+func (gl *GL) FramebufferTexture3D(target, attachment, textarget glbase.Enum, texture glbase.Texture, level int, zoffset int32) {
+ C.gl4_3core_glFramebufferTexture3D(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(textarget), C.GLuint(texture), C.GLint(level), C.GLint(zoffset))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFramebufferTexture2D.xml
+func (gl *GL) FramebufferTexture2D(target, attachment, textarget glbase.Enum, texture glbase.Texture, level int) {
+ C.gl4_3core_glFramebufferTexture2D(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(textarget), C.GLuint(texture), C.GLint(level))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFramebufferTexture1D.xml
+func (gl *GL) FramebufferTexture1D(target, attachment, textarget glbase.Enum, texture glbase.Texture, level int) {
+ C.gl4_3core_glFramebufferTexture1D(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(textarget), C.GLuint(texture), C.GLint(level))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCheckFramebufferStatus.xml
+func (gl *GL) CheckFramebufferStatus(target glbase.Enum) glbase.Enum {
+ glresult := C.gl4_3core_glCheckFramebufferStatus(gl.funcs, C.GLenum(target))
+ return glbase.Enum(glresult)
+}
+
+// GenFramebuffers returns n framebuffer object names in ids. There is no
+// guarantee that the names form a contiguous set of integers; however, it is
+// guaranteed that none of the returned names was in use immediately before
+// the call to GenFramebuffers.
+//
+// Framebuffer object names returned by a call to GenFramebuffers are not
+// returned by subsequent calls, unless they are first deleted with
+// DeleteFramebuffers.
+//
+// The names returned in ids are marked as used, for the purposes of
+// GenFramebuffers only, but they acquire state and type only when they are
+// first bound.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+func (gl *GL) GenFramebuffers(n int) []glbase.Framebuffer {
+ if n == 0 {
+ return nil
+ }
+ framebuffers := make([]glbase.Framebuffer, n)
+ C.gl4_3core_glGenFramebuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&framebuffers[0])))
+ return framebuffers
+}
+
+// DeleteFramebuffers deletes the framebuffer objects whose names are
+// stored in the framebuffers slice. The name zero is reserved by the GL and
+// is silently ignored, should it occur in framebuffers, as are other unused
+// names. Once a framebuffer object is deleted, its name is again unused and
+// it has no attachments. If a framebuffer that is currently bound to one or
+// more of the targets GL.DRAW_FRAMEBUFFER or GL.READ_FRAMEBUFFER is deleted,
+// it is as though BindFramebuffer had been executed with the corresponding
+// target and framebuffer zero.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// DeleteFramebuffers is available in GL version 3.0 or greater.
+func (gl *GL) DeleteFramebuffers(framebuffers []glbase.Framebuffer) {
+ n := len(framebuffers)
+ if n == 0 {
+ return
+ }
+ C.gl4_3core_glDeleteFramebuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&framebuffers[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindFramebuffer.xml
+func (gl *GL) BindFramebuffer(target glbase.Enum, framebuffer glbase.Framebuffer) {
+ C.gl4_3core_glBindFramebuffer(gl.funcs, C.GLenum(target), C.GLuint(framebuffer))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsFramebuffer.xml
+func (gl *GL) IsFramebuffer(framebuffer glbase.Framebuffer) bool {
+ glresult := C.gl4_3core_glIsFramebuffer(gl.funcs, C.GLuint(framebuffer))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetRenderbufferParameteriv.xml
+func (gl *GL) GetRenderbufferParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl4_3core_glGetRenderbufferParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glRenderbufferStorage.xml
+func (gl *GL) RenderbufferStorage(target, internalFormat glbase.Enum, width, height int) {
+ C.gl4_3core_glRenderbufferStorage(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height))
+}
+
+// GenRenderbuffers returns n renderbuffer object names in renderbuffers.
+// There is no guarantee that the names form a contiguous set of integers;
+// however, it is guaranteed that none of the returned names was in use
+// immediately before the call to GenRenderbuffers.
+//
+// Renderbuffer object names returned by a call to GenRenderbuffers are not
+// returned by subsequent calls, unless they are first deleted with
+// DeleteRenderbuffers.
+//
+// The names returned in renderbuffers are marked as used, for the purposes
+// of GenRenderbuffers only, but they acquire state and type only when they
+// are first bound.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// GenRenderbuffers is available in GL version 3.0 or greater.
+func (gl *GL) GenRenderbuffers(n int) []glbase.Renderbuffer {
+ if n == 0 {
+ return nil
+ }
+ renderbuffers := make([]glbase.Renderbuffer, n)
+ C.gl4_3core_glGenRenderbuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&renderbuffers[0])))
+ return renderbuffers
+}
+
+// DeleteRenderbuffers deletes the renderbuffer objects whose names are stored
+// in the renderbuffers slice. The name zero is reserved by the GL and
+// is silently ignored, should it occur in renderbuffers, as are other unused
+// names. Once a renderbuffer object is deleted, its name is again unused and
+// it has no contents. If a renderbuffer that is currently bound to the
+// target GL.RENDERBUFFER is deleted, it is as though BindRenderbuffer had
+// been executed with a target of GL.RENDERBUFFER and a name of zero.
+//
+// If a renderbuffer object is attached to one or more attachment points in
+// the currently bound framebuffer, then it as if FramebufferRenderbuffer
+// had been called, with a renderbuffer of zero for each attachment point to
+// which this image was attached in the currently bound framebuffer. In other
+// words, this renderbuffer object is first detached from all attachment
+// ponits in the currently bound framebuffer. Note that the renderbuffer
+// image is specifically not detached from any non-bound framebuffers.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// DeleteRenderbuffers is available in GL version 3.0 or greater.
+func (gl *GL) DeleteRenderbuffers(renderbuffers []glbase.Renderbuffer) {
+ n := len(renderbuffers)
+ if n == 0 {
+ return
+ }
+ C.gl4_3core_glDeleteRenderbuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&renderbuffers[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindRenderbuffer.xml
+func (gl *GL) BindRenderbuffer(target glbase.Enum, renderbuffer glbase.Renderbuffer) {
+ C.gl4_3core_glBindRenderbuffer(gl.funcs, C.GLenum(target), C.GLuint(renderbuffer))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsRenderbuffer.xml
+func (gl *GL) IsRenderbuffer(renderbuffer glbase.Renderbuffer) bool {
+ glresult := C.gl4_3core_glIsRenderbuffer(gl.funcs, C.GLuint(renderbuffer))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearBufferfi.xml
+func (gl *GL) ClearBufferfi(buffer glbase.Enum, drawbuffer int32, depth float32, stencil int32) {
+ C.gl4_3core_glClearBufferfi(gl.funcs, C.GLenum(buffer), C.GLint(drawbuffer), C.GLfloat(depth), C.GLint(stencil))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearBufferfv.xml
+func (gl *GL) ClearBufferfv(buffer glbase.Enum, drawbuffer int32, value []float32) {
+ C.gl4_3core_glClearBufferfv(gl.funcs, C.GLenum(buffer), C.GLint(drawbuffer), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearBufferuiv.xml
+func (gl *GL) ClearBufferuiv(buffer glbase.Enum, drawbuffer int32, value []uint32) {
+ C.gl4_3core_glClearBufferuiv(gl.funcs, C.GLenum(buffer), C.GLint(drawbuffer), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearBufferiv.xml
+func (gl *GL) ClearBufferiv(buffer glbase.Enum, drawbuffer int32, value []int32) {
+ C.gl4_3core_glClearBufferiv(gl.funcs, C.GLenum(buffer), C.GLint(drawbuffer), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexParameterIuiv.xml
+func (gl *GL) GetTexParameterIuiv(target, pname glbase.Enum, params []uint32) {
+ C.gl4_3core_glGetTexParameterIuiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTexParameterIiv.xml
+func (gl *GL) GetTexParameterIiv(target, pname glbase.Enum, params []int32) {
+ C.gl4_3core_glGetTexParameterIiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexParameterIuiv.xml
+func (gl *GL) TexParameterIuiv(target, pname glbase.Enum, params []uint32) {
+ C.gl4_3core_glTexParameterIuiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexParameterIiv.xml
+func (gl *GL) TexParameterIiv(target, pname glbase.Enum, params []int32) {
+ C.gl4_3core_glTexParameterIiv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// Uniform4uiv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform4uiv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4uiv(location glbase.Uniform, value []uint32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%4 != 0 {
+ panic("invalid value length for Uniform4uiv")
+ }
+ count := len(value) / 4
+ C.gl4_3core_glUniform4uiv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform3uiv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform3uiv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3uiv(location glbase.Uniform, value []uint32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%3 != 0 {
+ panic("invalid value length for Uniform3uiv")
+ }
+ count := len(value) / 3
+ C.gl4_3core_glUniform3uiv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform2uiv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform2uiv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2uiv(location glbase.Uniform, value []uint32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%2 != 0 {
+ panic("invalid value length for Uniform2uiv")
+ }
+ count := len(value) / 2
+ C.gl4_3core_glUniform2uiv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform1uiv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform1uiv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1uiv(location glbase.Uniform, value []uint32) {
+ if len(value) == 0 {
+ return
+ }
+ count := len(value)
+ C.gl4_3core_glUniform1uiv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4ui modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform4ui operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4ui(location glbase.Uniform, v0, v1, v2, v3 uint32) {
+ C.gl4_3core_glUniform4ui(gl.funcs, C.GLint(location), C.GLuint(v0), C.GLuint(v1), C.GLuint(v2), C.GLuint(v3))
+}
+
+// Uniform3ui modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform3ui operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3ui(location glbase.Uniform, v0, v1, v2 uint32) {
+ C.gl4_3core_glUniform3ui(gl.funcs, C.GLint(location), C.GLuint(v0), C.GLuint(v1), C.GLuint(v2))
+}
+
+// Uniform2ui modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform2ui operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2ui(location glbase.Uniform, v0, v1 uint32) {
+ C.gl4_3core_glUniform2ui(gl.funcs, C.GLint(location), C.GLuint(v0), C.GLuint(v1))
+}
+
+// Uniform1ui modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform1ui operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1ui(location glbase.Uniform, v0 uint32) {
+ C.gl4_3core_glUniform1ui(gl.funcs, C.GLint(location), C.GLuint(v0))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetFragDataLocation.xml
+func (gl *GL) GetFragDataLocation(program glbase.Program, name []byte) int32 {
+ glresult := C.gl4_3core_glGetFragDataLocation(gl.funcs, C.GLuint(program), (*C.GLchar)(unsafe.Pointer(&name[0])))
+ return int32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindFragDataLocation.xml
+func (gl *GL) BindFragDataLocation(program glbase.Program, color uint32, name []byte) {
+ C.gl4_3core_glBindFragDataLocation(gl.funcs, C.GLuint(program), C.GLuint(color), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetUniformuiv.xml
+func (gl *GL) GetUniformuiv(program glbase.Program, location glbase.Uniform, params []uint32) {
+ C.gl4_3core_glGetUniformuiv(gl.funcs, C.GLuint(program), C.GLint(location), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetVertexAttribIuiv.xml
+func (gl *GL) GetVertexAttribIuiv(index glbase.Attrib, pname glbase.Enum, params []uint32) {
+ C.gl4_3core_glGetVertexAttribIuiv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetVertexAttribIiv.xml
+func (gl *GL) GetVertexAttribIiv(index glbase.Attrib, pname glbase.Enum, params []int32) {
+ C.gl4_3core_glGetVertexAttribIiv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribIPointer.xml
+func (gl *GL) VertexAttribIPointer(index glbase.Attrib, size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3core_glVertexAttribIPointer(gl.funcs, C.GLuint(index), C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEndConditionalRender.xml
+func (gl *GL) EndConditionalRender() {
+ C.gl4_3core_glEndConditionalRender(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBeginConditionalRender.xml
+func (gl *GL) BeginConditionalRender(id uint32, mode glbase.Enum) {
+ C.gl4_3core_glBeginConditionalRender(gl.funcs, C.GLuint(id), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClampColor.xml
+func (gl *GL) ClampColor(target, clamp glbase.Enum) {
+ C.gl4_3core_glClampColor(gl.funcs, C.GLenum(target), C.GLenum(clamp))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetTransformFeedbackVarying.xml
+func (gl *GL) GetTransformFeedbackVarying(program glbase.Program, index uint32, bufSize int32, length []int32, size []int, gltype []glbase.Enum, name []byte) {
+ C.gl4_3core_glGetTransformFeedbackVarying(gl.funcs, C.GLuint(program), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLsizei)(unsafe.Pointer(&size[0])), (*C.GLenum)(unsafe.Pointer(&gltype[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindBufferBase.xml
+func (gl *GL) BindBufferBase(target glbase.Enum, index uint32, buffer glbase.Buffer) {
+ C.gl4_3core_glBindBufferBase(gl.funcs, C.GLenum(target), C.GLuint(index), C.GLuint(buffer))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindBufferRange.xml
+func (gl *GL) BindBufferRange(target glbase.Enum, index uint32, buffer glbase.Buffer, offset, size int) {
+ C.gl4_3core_glBindBufferRange(gl.funcs, C.GLenum(target), C.GLuint(index), C.GLuint(buffer), C.GLintptr(offset), C.GLsizeiptr(size))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEndTransformFeedback.xml
+func (gl *GL) EndTransformFeedback() {
+ C.gl4_3core_glEndTransformFeedback(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBeginTransformFeedback.xml
+func (gl *GL) BeginTransformFeedback(primitiveMode glbase.Enum) {
+ C.gl4_3core_glBeginTransformFeedback(gl.funcs, C.GLenum(primitiveMode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsEnabledi.xml
+func (gl *GL) IsEnabledi(target glbase.Enum, index uint32) bool {
+ glresult := C.gl4_3core_glIsEnabledi(gl.funcs, C.GLenum(target), C.GLuint(index))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDisablei.xml
+func (gl *GL) Disablei(target glbase.Enum, index uint32) {
+ C.gl4_3core_glDisablei(gl.funcs, C.GLenum(target), C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEnablei.xml
+func (gl *GL) Enablei(target glbase.Enum, index uint32) {
+ C.gl4_3core_glEnablei(gl.funcs, C.GLenum(target), C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetIntegeri_v.xml
+func (gl *GL) GetIntegeri_v(target glbase.Enum, index uint32, data []int32) {
+ C.gl4_3core_glGetIntegeri_v(gl.funcs, C.GLenum(target), C.GLuint(index), (*C.GLint)(unsafe.Pointer(&data[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetBooleani_v.xml
+func (gl *GL) GetBooleani_v(target glbase.Enum, index uint32, data []bool) {
+ C.gl4_3core_glGetBooleani_v(gl.funcs, C.GLenum(target), C.GLuint(index), (*C.GLboolean)(unsafe.Pointer(&data[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorMaski.xml
+func (gl *GL) ColorMaski(index uint32, r, g, b, a bool) {
+ C.gl4_3core_glColorMaski(gl.funcs, C.GLuint(index), *(*C.GLboolean)(unsafe.Pointer(&r)), *(*C.GLboolean)(unsafe.Pointer(&g)), *(*C.GLboolean)(unsafe.Pointer(&b)), *(*C.GLboolean)(unsafe.Pointer(&a)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyBufferSubData.xml
+func (gl *GL) CopyBufferSubData(readTarget, writeTarget glbase.Enum, readOffset, writeOffset, size int) {
+ C.gl4_3core_glCopyBufferSubData(gl.funcs, C.GLenum(readTarget), C.GLenum(writeTarget), C.GLintptr(readOffset), C.GLintptr(writeOffset), C.GLsizeiptr(size))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformBlockBinding.xml
+func (gl *GL) UniformBlockBinding(program glbase.Program, v0, v1 uint32) {
+ C.gl4_3core_glUniformBlockBinding(gl.funcs, C.GLuint(program), C.GLuint(v0), C.GLuint(v1))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveUniformBlockName.xml
+func (gl *GL) GetActiveUniformBlockName(program glbase.Program, uniformBlockIndex uint32, bufSize int32, length []int32, uniformBlockName []byte) {
+ C.gl4_3core_glGetActiveUniformBlockName(gl.funcs, C.GLuint(program), C.GLuint(uniformBlockIndex), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&uniformBlockName[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveUniformBlockiv.xml
+func (gl *GL) GetActiveUniformBlockiv(program glbase.Program, uniformBlockIndex uint32, pname glbase.Enum, params []int32) {
+ C.gl4_3core_glGetActiveUniformBlockiv(gl.funcs, C.GLuint(program), C.GLuint(uniformBlockIndex), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetUniformBlockIndex.xml
+func (gl *GL) GetUniformBlockIndex(program glbase.Program, uniformBlockName []byte) uint32 {
+ glresult := C.gl4_3core_glGetUniformBlockIndex(gl.funcs, C.GLuint(program), (*C.GLchar)(unsafe.Pointer(&uniformBlockName[0])))
+ return uint32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveUniformName.xml
+func (gl *GL) GetActiveUniformName(program glbase.Program, uniformIndex uint32, bufSize int32, length []int32, uniformName []byte) {
+ C.gl4_3core_glGetActiveUniformName(gl.funcs, C.GLuint(program), C.GLuint(uniformIndex), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&uniformName[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveUniformsiv.xml
+func (gl *GL) GetActiveUniformsiv(program glbase.Program, uniformCount int32, uniformIndices []uint32, pname glbase.Enum, params []int32) {
+ C.gl4_3core_glGetActiveUniformsiv(gl.funcs, C.GLuint(program), C.GLsizei(uniformCount), (*C.GLuint)(unsafe.Pointer(&uniformIndices[0])), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPrimitiveRestartIndex.xml
+func (gl *GL) PrimitiveRestartIndex(index uint32) {
+ C.gl4_3core_glPrimitiveRestartIndex(gl.funcs, C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexBuffer.xml
+func (gl *GL) TexBuffer(target, internalFormat glbase.Enum, buffer glbase.Buffer) {
+ C.gl4_3core_glTexBuffer(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLuint(buffer))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawElementsInstanced.xml
+func (gl *GL) DrawElementsInstanced(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}, instancecount int32) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3core_glDrawElementsInstanced(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr, C.GLsizei(instancecount))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawArraysInstanced.xml
+func (gl *GL) DrawArraysInstanced(mode glbase.Enum, first, count int, instancecount int32) {
+ C.gl4_3core_glDrawArraysInstanced(gl.funcs, C.GLenum(mode), C.GLint(first), C.GLsizei(count), C.GLsizei(instancecount))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSampleMaski.xml
+func (gl *GL) SampleMaski(index uint32, mask glbase.Bitfield) {
+ C.gl4_3core_glSampleMaski(gl.funcs, C.GLuint(index), C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetMultisamplefv.xml
+func (gl *GL) GetMultisamplefv(pname glbase.Enum, index uint32, val []float32) {
+ C.gl4_3core_glGetMultisamplefv(gl.funcs, C.GLenum(pname), C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&val[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexImage3DMultisample.xml
+func (gl *GL) TexImage3DMultisample(target glbase.Enum, samples, internalFormat int32, width, height int, depth int32, fixedsamplelocations bool) {
+ C.gl4_3core_glTexImage3DMultisample(gl.funcs, C.GLenum(target), C.GLsizei(samples), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), *(*C.GLboolean)(unsafe.Pointer(&fixedsamplelocations)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexImage2DMultisample.xml
+func (gl *GL) TexImage2DMultisample(target glbase.Enum, samples, internalFormat int32, width, height int, fixedsamplelocations bool) {
+ C.gl4_3core_glTexImage2DMultisample(gl.funcs, C.GLenum(target), C.GLsizei(samples), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), *(*C.GLboolean)(unsafe.Pointer(&fixedsamplelocations)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetSynciv.xml
+func (gl *GL) GetSynciv(sync glbase.Sync, pname glbase.Enum, bufSize int32, length, values []int32) {
+ C.gl4_3core_glGetSynciv(gl.funcs, C.GLsync(unsafe.Pointer(sync)), C.GLenum(pname), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLint)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetInteger64v.xml
+func (gl *GL) GetInteger64v(pname glbase.Enum, params []int64) {
+ C.gl4_3core_glGetInteger64v(gl.funcs, C.GLenum(pname), (*C.GLint64)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glWaitSync.xml
+func (gl *GL) WaitSync(sync glbase.Sync, flags glbase.Bitfield, timeout uint64) {
+ C.gl4_3core_glWaitSync(gl.funcs, C.GLsync(unsafe.Pointer(sync)), C.GLbitfield(flags), C.GLuint64(timeout))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClientWaitSync.xml
+func (gl *GL) ClientWaitSync(sync glbase.Sync, flags glbase.Bitfield, timeout uint64) glbase.Enum {
+ glresult := C.gl4_3core_glClientWaitSync(gl.funcs, C.GLsync(unsafe.Pointer(sync)), C.GLbitfield(flags), C.GLuint64(timeout))
+ return glbase.Enum(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDeleteSync.xml
+func (gl *GL) DeleteSync(sync glbase.Sync) {
+ C.gl4_3core_glDeleteSync(gl.funcs, C.GLsync(unsafe.Pointer(sync)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsSync.xml
+func (gl *GL) IsSync(sync glbase.Sync) bool {
+ glresult := C.gl4_3core_glIsSync(gl.funcs, C.GLsync(unsafe.Pointer(sync)))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFenceSync.xml
+func (gl *GL) FenceSync(condition glbase.Enum, flags glbase.Bitfield) glbase.Sync {
+ glresult := C.gl4_3core_glFenceSync(gl.funcs, C.GLenum(condition), C.GLbitfield(flags))
+ return glbase.Sync(unsafe.Pointer(glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProvokingVertex.xml
+func (gl *GL) ProvokingVertex(mode glbase.Enum) {
+ C.gl4_3core_glProvokingVertex(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawElementsInstancedBaseVertex.xml
+func (gl *GL) DrawElementsInstancedBaseVertex(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}, instancecount, basevertex int32) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3core_glDrawElementsInstancedBaseVertex(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr, C.GLsizei(instancecount), C.GLint(basevertex))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawRangeElementsBaseVertex.xml
+func (gl *GL) DrawRangeElementsBaseVertex(mode glbase.Enum, start, end uint32, count int, gltype glbase.Enum, indices interface{}, basevertex int32) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3core_glDrawRangeElementsBaseVertex(gl.funcs, C.GLenum(mode), C.GLuint(start), C.GLuint(end), C.GLsizei(count), C.GLenum(gltype), indices_ptr, C.GLint(basevertex))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawElementsBaseVertex.xml
+func (gl *GL) DrawElementsBaseVertex(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}, basevertex int32) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3core_glDrawElementsBaseVertex(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr, C.GLint(basevertex))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFramebufferTexture.xml
+func (gl *GL) FramebufferTexture(target, attachment glbase.Enum, texture glbase.Texture, level int) {
+ C.gl4_3core_glFramebufferTexture(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLuint(texture), C.GLint(level))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetBufferParameteri64v.xml
+func (gl *GL) GetBufferParameteri64v(target, pname glbase.Enum, params []int64) {
+ C.gl4_3core_glGetBufferParameteri64v(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint64)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetInteger64i_v.xml
+func (gl *GL) GetInteger64i_v(target glbase.Enum, index uint32, data []int64) {
+ C.gl4_3core_glGetInteger64i_v(gl.funcs, C.GLenum(target), C.GLuint(index), (*C.GLint64)(unsafe.Pointer(&data[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP4uiv.xml
+func (gl *GL) VertexAttribP4uiv(index glbase.Attrib, gltype glbase.Enum, normalized bool, value []uint32) {
+ C.gl4_3core_glVertexAttribP4uiv(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP4ui.xml
+func (gl *GL) VertexAttribP4ui(index glbase.Attrib, gltype glbase.Enum, normalized bool, value uint32) {
+ C.gl4_3core_glVertexAttribP4ui(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP3uiv.xml
+func (gl *GL) VertexAttribP3uiv(index glbase.Attrib, gltype glbase.Enum, normalized bool, value []uint32) {
+ C.gl4_3core_glVertexAttribP3uiv(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP3ui.xml
+func (gl *GL) VertexAttribP3ui(index glbase.Attrib, gltype glbase.Enum, normalized bool, value uint32) {
+ C.gl4_3core_glVertexAttribP3ui(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP2uiv.xml
+func (gl *GL) VertexAttribP2uiv(index glbase.Attrib, gltype glbase.Enum, normalized bool, value []uint32) {
+ C.gl4_3core_glVertexAttribP2uiv(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP2ui.xml
+func (gl *GL) VertexAttribP2ui(index glbase.Attrib, gltype glbase.Enum, normalized bool, value uint32) {
+ C.gl4_3core_glVertexAttribP2ui(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP1uiv.xml
+func (gl *GL) VertexAttribP1uiv(index glbase.Attrib, gltype glbase.Enum, normalized bool, value []uint32) {
+ C.gl4_3core_glVertexAttribP1uiv(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribP1ui.xml
+func (gl *GL) VertexAttribP1ui(index glbase.Attrib, gltype glbase.Enum, normalized bool, value uint32) {
+ C.gl4_3core_glVertexAttribP1ui(gl.funcs, C.GLuint(index), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColorP3uiv.xml
+func (gl *GL) SecondaryColorP3uiv(gltype glbase.Enum, color []uint32) {
+ C.gl4_3core_glSecondaryColorP3uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&color[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSecondaryColorP3ui.xml
+func (gl *GL) SecondaryColorP3ui(gltype glbase.Enum, color uint32) {
+ C.gl4_3core_glSecondaryColorP3ui(gl.funcs, C.GLenum(gltype), C.GLuint(color))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorP4uiv.xml
+func (gl *GL) ColorP4uiv(gltype glbase.Enum, color []uint32) {
+ C.gl4_3core_glColorP4uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&color[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorP4ui.xml
+func (gl *GL) ColorP4ui(gltype glbase.Enum, color uint32) {
+ C.gl4_3core_glColorP4ui(gl.funcs, C.GLenum(gltype), C.GLuint(color))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorP3uiv.xml
+func (gl *GL) ColorP3uiv(gltype glbase.Enum, color []uint32) {
+ C.gl4_3core_glColorP3uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&color[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glColorP3ui.xml
+func (gl *GL) ColorP3ui(gltype glbase.Enum, color uint32) {
+ C.gl4_3core_glColorP3ui(gl.funcs, C.GLenum(gltype), C.GLuint(color))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNormalP3uiv.xml
+func (gl *GL) NormalP3uiv(gltype glbase.Enum, coords []uint32) {
+ C.gl4_3core_glNormalP3uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glNormalP3ui.xml
+func (gl *GL) NormalP3ui(gltype glbase.Enum, coords uint32) {
+ C.gl4_3core_glNormalP3ui(gl.funcs, C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP4uiv.xml
+func (gl *GL) MultiTexCoordP4uiv(texture, gltype glbase.Enum, coords []uint32) {
+ C.gl4_3core_glMultiTexCoordP4uiv(gl.funcs, C.GLenum(texture), C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP4ui.xml
+func (gl *GL) MultiTexCoordP4ui(texture, gltype glbase.Enum, coords uint32) {
+ C.gl4_3core_glMultiTexCoordP4ui(gl.funcs, C.GLenum(texture), C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP3uiv.xml
+func (gl *GL) MultiTexCoordP3uiv(texture, gltype glbase.Enum, coords []uint32) {
+ C.gl4_3core_glMultiTexCoordP3uiv(gl.funcs, C.GLenum(texture), C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP3ui.xml
+func (gl *GL) MultiTexCoordP3ui(texture, gltype glbase.Enum, coords uint32) {
+ C.gl4_3core_glMultiTexCoordP3ui(gl.funcs, C.GLenum(texture), C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP2uiv.xml
+func (gl *GL) MultiTexCoordP2uiv(texture, gltype glbase.Enum, coords []uint32) {
+ C.gl4_3core_glMultiTexCoordP2uiv(gl.funcs, C.GLenum(texture), C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP2ui.xml
+func (gl *GL) MultiTexCoordP2ui(texture, gltype glbase.Enum, coords uint32) {
+ C.gl4_3core_glMultiTexCoordP2ui(gl.funcs, C.GLenum(texture), C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP1uiv.xml
+func (gl *GL) MultiTexCoordP1uiv(texture, gltype glbase.Enum, coords []uint32) {
+ C.gl4_3core_glMultiTexCoordP1uiv(gl.funcs, C.GLenum(texture), C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiTexCoordP1ui.xml
+func (gl *GL) MultiTexCoordP1ui(texture, gltype glbase.Enum, coords uint32) {
+ C.gl4_3core_glMultiTexCoordP1ui(gl.funcs, C.GLenum(texture), C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP4uiv.xml
+func (gl *GL) TexCoordP4uiv(gltype glbase.Enum, coords []uint32) {
+ C.gl4_3core_glTexCoordP4uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP4ui.xml
+func (gl *GL) TexCoordP4ui(gltype glbase.Enum, coords uint32) {
+ C.gl4_3core_glTexCoordP4ui(gl.funcs, C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP3uiv.xml
+func (gl *GL) TexCoordP3uiv(gltype glbase.Enum, coords []uint32) {
+ C.gl4_3core_glTexCoordP3uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP3ui.xml
+func (gl *GL) TexCoordP3ui(gltype glbase.Enum, coords uint32) {
+ C.gl4_3core_glTexCoordP3ui(gl.funcs, C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP2uiv.xml
+func (gl *GL) TexCoordP2uiv(gltype glbase.Enum, coords []uint32) {
+ C.gl4_3core_glTexCoordP2uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP2ui.xml
+func (gl *GL) TexCoordP2ui(gltype glbase.Enum, coords uint32) {
+ C.gl4_3core_glTexCoordP2ui(gl.funcs, C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP1uiv.xml
+func (gl *GL) TexCoordP1uiv(gltype glbase.Enum, coords []uint32) {
+ C.gl4_3core_glTexCoordP1uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&coords[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexCoordP1ui.xml
+func (gl *GL) TexCoordP1ui(gltype glbase.Enum, coords uint32) {
+ C.gl4_3core_glTexCoordP1ui(gl.funcs, C.GLenum(gltype), C.GLuint(coords))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexP4uiv.xml
+func (gl *GL) VertexP4uiv(gltype glbase.Enum, value []uint32) {
+ C.gl4_3core_glVertexP4uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexP4ui.xml
+func (gl *GL) VertexP4ui(gltype glbase.Enum, value uint32) {
+ C.gl4_3core_glVertexP4ui(gl.funcs, C.GLenum(gltype), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexP3uiv.xml
+func (gl *GL) VertexP3uiv(gltype glbase.Enum, value []uint32) {
+ C.gl4_3core_glVertexP3uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexP3ui.xml
+func (gl *GL) VertexP3ui(gltype glbase.Enum, value uint32) {
+ C.gl4_3core_glVertexP3ui(gl.funcs, C.GLenum(gltype), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexP2uiv.xml
+func (gl *GL) VertexP2uiv(gltype glbase.Enum, value []uint32) {
+ C.gl4_3core_glVertexP2uiv(gl.funcs, C.GLenum(gltype), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexP2ui.xml
+func (gl *GL) VertexP2ui(gltype glbase.Enum, value uint32) {
+ C.gl4_3core_glVertexP2ui(gl.funcs, C.GLenum(gltype), C.GLuint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetQueryObjectui64v.xml
+func (gl *GL) GetQueryObjectui64v(id uint32, pname glbase.Enum, params []uint64) {
+ C.gl4_3core_glGetQueryObjectui64v(gl.funcs, C.GLuint(id), C.GLenum(pname), (*C.GLuint64)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetQueryObjecti64v.xml
+func (gl *GL) GetQueryObjecti64v(id uint32, pname glbase.Enum, params []int64) {
+ C.gl4_3core_glGetQueryObjecti64v(gl.funcs, C.GLuint(id), C.GLenum(pname), (*C.GLint64)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glQueryCounter.xml
+func (gl *GL) QueryCounter(id uint32, target glbase.Enum) {
+ C.gl4_3core_glQueryCounter(gl.funcs, C.GLuint(id), C.GLenum(target))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetSamplerParameterIuiv.xml
+func (gl *GL) GetSamplerParameterIuiv(sampler uint32, pname glbase.Enum, params []uint32) {
+ C.gl4_3core_glGetSamplerParameterIuiv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetSamplerParameterfv.xml
+func (gl *GL) GetSamplerParameterfv(sampler uint32, pname glbase.Enum, params []float32) {
+ C.gl4_3core_glGetSamplerParameterfv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetSamplerParameterIiv.xml
+func (gl *GL) GetSamplerParameterIiv(sampler uint32, pname glbase.Enum, params []int32) {
+ C.gl4_3core_glGetSamplerParameterIiv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetSamplerParameteriv.xml
+func (gl *GL) GetSamplerParameteriv(sampler uint32, pname glbase.Enum, params []int32) {
+ C.gl4_3core_glGetSamplerParameteriv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSamplerParameterIuiv.xml
+func (gl *GL) SamplerParameterIuiv(sampler uint32, pname glbase.Enum, param []uint32) {
+ C.gl4_3core_glSamplerParameterIuiv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLuint)(unsafe.Pointer(&param[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSamplerParameterIiv.xml
+func (gl *GL) SamplerParameterIiv(sampler uint32, pname glbase.Enum, param []int32) {
+ C.gl4_3core_glSamplerParameterIiv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&param[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSamplerParameterfv.xml
+func (gl *GL) SamplerParameterfv(sampler uint32, pname glbase.Enum, param []float32) {
+ C.gl4_3core_glSamplerParameterfv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&param[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSamplerParameterf.xml
+func (gl *GL) SamplerParameterf(sampler uint32, pname glbase.Enum, param float32) {
+ C.gl4_3core_glSamplerParameterf(gl.funcs, C.GLuint(sampler), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSamplerParameteriv.xml
+func (gl *GL) SamplerParameteriv(sampler uint32, pname glbase.Enum, param []int32) {
+ C.gl4_3core_glSamplerParameteriv(gl.funcs, C.GLuint(sampler), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&param[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glSamplerParameteri.xml
+func (gl *GL) SamplerParameteri(sampler uint32, pname glbase.Enum, param int32) {
+ C.gl4_3core_glSamplerParameteri(gl.funcs, C.GLuint(sampler), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindSampler.xml
+func (gl *GL) BindSampler(unit, sampler uint32) {
+ C.gl4_3core_glBindSampler(gl.funcs, C.GLuint(unit), C.GLuint(sampler))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsSampler.xml
+func (gl *GL) IsSampler(sampler uint32) bool {
+ glresult := C.gl4_3core_glIsSampler(gl.funcs, C.GLuint(sampler))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDeleteSamplers.xml
+func (gl *GL) DeleteSamplers(count int, samplers []uint32) {
+ C.gl4_3core_glDeleteSamplers(gl.funcs, C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&samplers[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGenSamplers.xml
+func (gl *GL) GenSamplers(count int, samplers []uint32) {
+ C.gl4_3core_glGenSamplers(gl.funcs, C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&samplers[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetFragDataIndex.xml
+func (gl *GL) GetFragDataIndex(program glbase.Program, name []byte) int32 {
+ glresult := C.gl4_3core_glGetFragDataIndex(gl.funcs, C.GLuint(program), (*C.GLchar)(unsafe.Pointer(&name[0])))
+ return int32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindFragDataLocationIndexed.xml
+func (gl *GL) BindFragDataLocationIndexed(program glbase.Program, colorNumber, index uint32, name []byte) {
+ C.gl4_3core_glBindFragDataLocationIndexed(gl.funcs, C.GLuint(program), C.GLuint(colorNumber), C.GLuint(index), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribDivisor.xml
+func (gl *GL) VertexAttribDivisor(index glbase.Attrib, divisor uint32) {
+ C.gl4_3core_glVertexAttribDivisor(gl.funcs, C.GLuint(index), C.GLuint(divisor))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetQueryIndexediv.xml
+func (gl *GL) GetQueryIndexediv(target glbase.Enum, index uint32, pname glbase.Enum, params []int32) {
+ C.gl4_3core_glGetQueryIndexediv(gl.funcs, C.GLenum(target), C.GLuint(index), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glEndQueryIndexed.xml
+func (gl *GL) EndQueryIndexed(target glbase.Enum, index uint32) {
+ C.gl4_3core_glEndQueryIndexed(gl.funcs, C.GLenum(target), C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBeginQueryIndexed.xml
+func (gl *GL) BeginQueryIndexed(target glbase.Enum, index, id uint32) {
+ C.gl4_3core_glBeginQueryIndexed(gl.funcs, C.GLenum(target), C.GLuint(index), C.GLuint(id))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawTransformFeedbackStream.xml
+func (gl *GL) DrawTransformFeedbackStream(mode glbase.Enum, id, stream uint32) {
+ C.gl4_3core_glDrawTransformFeedbackStream(gl.funcs, C.GLenum(mode), C.GLuint(id), C.GLuint(stream))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawTransformFeedback.xml
+func (gl *GL) DrawTransformFeedback(mode glbase.Enum, id uint32) {
+ C.gl4_3core_glDrawTransformFeedback(gl.funcs, C.GLenum(mode), C.GLuint(id))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glResumeTransformFeedback.xml
+func (gl *GL) ResumeTransformFeedback() {
+ C.gl4_3core_glResumeTransformFeedback(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPauseTransformFeedback.xml
+func (gl *GL) PauseTransformFeedback() {
+ C.gl4_3core_glPauseTransformFeedback(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsTransformFeedback.xml
+func (gl *GL) IsTransformFeedback(id uint32) bool {
+ glresult := C.gl4_3core_glIsTransformFeedback(gl.funcs, C.GLuint(id))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGenTransformFeedbacks.xml
+func (gl *GL) GenTransformFeedbacks(n int, ids []uint32) {
+ C.gl4_3core_glGenTransformFeedbacks(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&ids[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDeleteTransformFeedbacks.xml
+func (gl *GL) DeleteTransformFeedbacks(n int, ids []uint32) {
+ C.gl4_3core_glDeleteTransformFeedbacks(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&ids[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindTransformFeedback.xml
+func (gl *GL) BindTransformFeedback(target glbase.Enum, id uint32) {
+ C.gl4_3core_glBindTransformFeedback(gl.funcs, C.GLenum(target), C.GLuint(id))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPatchParameterfv.xml
+func (gl *GL) PatchParameterfv(pname glbase.Enum, values []float32) {
+ C.gl4_3core_glPatchParameterfv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glPatchParameteri.xml
+func (gl *GL) PatchParameteri(pname glbase.Enum, value int32) {
+ C.gl4_3core_glPatchParameteri(gl.funcs, C.GLenum(pname), C.GLint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetProgramStageiv.xml
+func (gl *GL) GetProgramStageiv(program glbase.Program, shadertype, pname glbase.Enum, values []int32) {
+ C.gl4_3core_glGetProgramStageiv(gl.funcs, C.GLuint(program), C.GLenum(shadertype), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetUniformSubroutineuiv.xml
+func (gl *GL) GetUniformSubroutineuiv(shadertype glbase.Enum, location glbase.Uniform, params []uint32) {
+ C.gl4_3core_glGetUniformSubroutineuiv(gl.funcs, C.GLenum(shadertype), C.GLint(location), (*C.GLuint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformSubroutinesuiv.xml
+func (gl *GL) UniformSubroutinesuiv(shadertype glbase.Enum, count int, value []uint32) {
+ C.gl4_3core_glUniformSubroutinesuiv(gl.funcs, C.GLenum(shadertype), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveSubroutineName.xml
+func (gl *GL) GetActiveSubroutineName(program glbase.Program, shadertype glbase.Enum, index uint32, bufSize int32, length []int32, name []byte) {
+ C.gl4_3core_glGetActiveSubroutineName(gl.funcs, C.GLuint(program), C.GLenum(shadertype), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveSubroutineUniformName.xml
+func (gl *GL) GetActiveSubroutineUniformName(program glbase.Program, shadertype glbase.Enum, index uint32, bufSize int32, length []int32, name []byte) {
+ C.gl4_3core_glGetActiveSubroutineUniformName(gl.funcs, C.GLuint(program), C.GLenum(shadertype), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveSubroutineUniformiv.xml
+func (gl *GL) GetActiveSubroutineUniformiv(program glbase.Program, shadertype glbase.Enum, index uint32, pname glbase.Enum, values []int32) {
+ C.gl4_3core_glGetActiveSubroutineUniformiv(gl.funcs, C.GLuint(program), C.GLenum(shadertype), C.GLuint(index), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetSubroutineIndex.xml
+func (gl *GL) GetSubroutineIndex(program glbase.Program, shadertype glbase.Enum, name []byte) uint32 {
+ glresult := C.gl4_3core_glGetSubroutineIndex(gl.funcs, C.GLuint(program), C.GLenum(shadertype), (*C.GLchar)(unsafe.Pointer(&name[0])))
+ return uint32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetSubroutineUniformLocation.xml
+func (gl *GL) GetSubroutineUniformLocation(program glbase.Program, shadertype glbase.Enum, name []byte) int32 {
+ glresult := C.gl4_3core_glGetSubroutineUniformLocation(gl.funcs, C.GLuint(program), C.GLenum(shadertype), (*C.GLchar)(unsafe.Pointer(&name[0])))
+ return int32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetUniformdv.xml
+func (gl *GL) GetUniformdv(program glbase.Program, location glbase.Uniform, params []float64) {
+ C.gl4_3core_glGetUniformdv(gl.funcs, C.GLuint(program), C.GLint(location), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix4x3dv.xml
+func (gl *GL) UniformMatrix4x3dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_3core_glUniformMatrix4x3dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix4x2dv.xml
+func (gl *GL) UniformMatrix4x2dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_3core_glUniformMatrix4x2dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix3x4dv.xml
+func (gl *GL) UniformMatrix3x4dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_3core_glUniformMatrix3x4dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix3x2dv.xml
+func (gl *GL) UniformMatrix3x2dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_3core_glUniformMatrix3x2dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix2x4dv.xml
+func (gl *GL) UniformMatrix2x4dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_3core_glUniformMatrix2x4dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix2x3dv.xml
+func (gl *GL) UniformMatrix2x3dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_3core_glUniformMatrix2x3dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix4dv.xml
+func (gl *GL) UniformMatrix4dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_3core_glUniformMatrix4dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix3dv.xml
+func (gl *GL) UniformMatrix3dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_3core_glUniformMatrix3dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniformMatrix2dv.xml
+func (gl *GL) UniformMatrix2dv(location glbase.Uniform, count int, transpose bool, value []float64) {
+ C.gl4_3core_glUniformMatrix2dv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform4dv.xml
+func (gl *GL) Uniform4dv(location glbase.Uniform, count int, value []float64) {
+ C.gl4_3core_glUniform4dv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform3dv.xml
+func (gl *GL) Uniform3dv(location glbase.Uniform, count int, value []float64) {
+ C.gl4_3core_glUniform3dv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform2dv.xml
+func (gl *GL) Uniform2dv(location glbase.Uniform, count int, value []float64) {
+ C.gl4_3core_glUniform2dv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform1dv.xml
+func (gl *GL) Uniform1dv(location glbase.Uniform, count int, value []float64) {
+ C.gl4_3core_glUniform1dv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform4d.xml
+func (gl *GL) Uniform4d(location glbase.Uniform, v0, v1, v2, v3 float64) {
+ C.gl4_3core_glUniform4d(gl.funcs, C.GLint(location), C.GLdouble(v0), C.GLdouble(v1), C.GLdouble(v2), C.GLdouble(v3))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform3d.xml
+func (gl *GL) Uniform3d(location glbase.Uniform, v0, v1, v2 float64) {
+ C.gl4_3core_glUniform3d(gl.funcs, C.GLint(location), C.GLdouble(v0), C.GLdouble(v1), C.GLdouble(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform2d.xml
+func (gl *GL) Uniform2d(location glbase.Uniform, v0, v1 float64) {
+ C.gl4_3core_glUniform2d(gl.funcs, C.GLint(location), C.GLdouble(v0), C.GLdouble(v1))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUniform1d.xml
+func (gl *GL) Uniform1d(location glbase.Uniform, v0 float64) {
+ C.gl4_3core_glUniform1d(gl.funcs, C.GLint(location), C.GLdouble(v0))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawElementsIndirect.xml
+func (gl *GL) DrawElementsIndirect(mode, gltype glbase.Enum, indirect interface{}) {
+ var indirect_ptr unsafe.Pointer
+ var indirect_v = reflect.ValueOf(indirect)
+ if indirect != nil && indirect_v.Kind() != reflect.Slice {
+ panic("parameter indirect must be a slice")
+ }
+ if indirect != nil {
+ indirect_ptr = unsafe.Pointer(indirect_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3core_glDrawElementsIndirect(gl.funcs, C.GLenum(mode), C.GLenum(gltype), indirect_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawArraysIndirect.xml
+func (gl *GL) DrawArraysIndirect(mode glbase.Enum, indirect interface{}) {
+ var indirect_ptr unsafe.Pointer
+ var indirect_v = reflect.ValueOf(indirect)
+ if indirect != nil && indirect_v.Kind() != reflect.Slice {
+ panic("parameter indirect must be a slice")
+ }
+ if indirect != nil {
+ indirect_ptr = unsafe.Pointer(indirect_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3core_glDrawArraysIndirect(gl.funcs, C.GLenum(mode), indirect_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendFuncSeparatei.xml
+func (gl *GL) BlendFuncSeparatei(buf uint32, srcRGB, dstRGB, srcAlpha, dstAlpha glbase.Enum) {
+ C.gl4_3core_glBlendFuncSeparatei(gl.funcs, C.GLuint(buf), C.GLenum(srcRGB), C.GLenum(dstRGB), C.GLenum(srcAlpha), C.GLenum(dstAlpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendFunci.xml
+func (gl *GL) BlendFunci(buf uint32, src, dst glbase.Enum) {
+ C.gl4_3core_glBlendFunci(gl.funcs, C.GLuint(buf), C.GLenum(src), C.GLenum(dst))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendEquationSeparatei.xml
+func (gl *GL) BlendEquationSeparatei(buf uint32, modeRGB, modeAlpha glbase.Enum) {
+ C.gl4_3core_glBlendEquationSeparatei(gl.funcs, C.GLuint(buf), C.GLenum(modeRGB), C.GLenum(modeAlpha))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBlendEquationi.xml
+func (gl *GL) BlendEquationi(buf uint32, mode glbase.Enum) {
+ C.gl4_3core_glBlendEquationi(gl.funcs, C.GLuint(buf), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMinSampleShading.xml
+func (gl *GL) MinSampleShading(value float32) {
+ C.gl4_3core_glMinSampleShading(gl.funcs, C.GLfloat(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetDoublei_v.xml
+func (gl *GL) GetDoublei_v(target glbase.Enum, index uint32, data []float64) {
+ C.gl4_3core_glGetDoublei_v(gl.funcs, C.GLenum(target), C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&data[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetFloati_v.xml
+func (gl *GL) GetFloati_v(target glbase.Enum, index uint32, data []float32) {
+ C.gl4_3core_glGetFloati_v(gl.funcs, C.GLenum(target), C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&data[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDepthRangeIndexed.xml
+func (gl *GL) DepthRangeIndexed(index uint32, n, f float64) {
+ C.gl4_3core_glDepthRangeIndexed(gl.funcs, C.GLuint(index), C.GLdouble(n), C.GLdouble(f))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDepthRangeArrayv.xml
+func (gl *GL) DepthRangeArrayv(first uint32, count int, v []float64) {
+ C.gl4_3core_glDepthRangeArrayv(gl.funcs, C.GLuint(first), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glScissorIndexedv.xml
+func (gl *GL) ScissorIndexedv(index uint32, v []int32) {
+ C.gl4_3core_glScissorIndexedv(gl.funcs, C.GLuint(index), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glScissorIndexed.xml
+func (gl *GL) ScissorIndexed(index uint32, left, bottom int32, width, height int) {
+ C.gl4_3core_glScissorIndexed(gl.funcs, C.GLuint(index), C.GLint(left), C.GLint(bottom), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glScissorArrayv.xml
+func (gl *GL) ScissorArrayv(first uint32, count int, v []int32) {
+ C.gl4_3core_glScissorArrayv(gl.funcs, C.GLuint(first), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glViewportIndexedfv.xml
+func (gl *GL) ViewportIndexedfv(index uint32, v []float32) {
+ C.gl4_3core_glViewportIndexedfv(gl.funcs, C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glViewportIndexedf.xml
+func (gl *GL) ViewportIndexedf(index uint32, x, y, w, h float32) {
+ C.gl4_3core_glViewportIndexedf(gl.funcs, C.GLuint(index), C.GLfloat(x), C.GLfloat(y), C.GLfloat(w), C.GLfloat(h))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glViewportArrayv.xml
+func (gl *GL) ViewportArrayv(first uint32, count int, v []float32) {
+ C.gl4_3core_glViewportArrayv(gl.funcs, C.GLuint(first), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetVertexAttribLdv.xml
+func (gl *GL) GetVertexAttribLdv(index glbase.Attrib, pname glbase.Enum, params []float64) {
+ C.gl4_3core_glGetVertexAttribLdv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLdouble)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribLPointer.xml
+func (gl *GL) VertexAttribLPointer(index glbase.Attrib, size int, gltype glbase.Enum, stride int, pointer interface{}) {
+ var pointer_ptr unsafe.Pointer
+ var pointer_v = reflect.ValueOf(pointer)
+ if pointer != nil && pointer_v.Kind() != reflect.Slice {
+ panic("parameter pointer must be a slice")
+ }
+ if pointer != nil {
+ pointer_ptr = unsafe.Pointer(pointer_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3core_glVertexAttribLPointer(gl.funcs, C.GLuint(index), C.GLint(size), C.GLenum(gltype), C.GLsizei(stride), pointer_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribL4dv.xml
+func (gl *GL) VertexAttribL4dv(index glbase.Attrib, v []float64) {
+ if len(v) != 4 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3core_glVertexAttribL4dv(gl.funcs, C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribL3dv.xml
+func (gl *GL) VertexAttribL3dv(index glbase.Attrib, v []float64) {
+ if len(v) != 3 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3core_glVertexAttribL3dv(gl.funcs, C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribL2dv.xml
+func (gl *GL) VertexAttribL2dv(index glbase.Attrib, v []float64) {
+ if len(v) != 2 {
+ panic("parameter v has incorrect length")
+ }
+ C.gl4_3core_glVertexAttribL2dv(gl.funcs, C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribL1dv.xml
+func (gl *GL) VertexAttribL1dv(index glbase.Attrib, v []float64) {
+ C.gl4_3core_glVertexAttribL1dv(gl.funcs, C.GLuint(index), (*C.GLdouble)(unsafe.Pointer(&v[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribL4d.xml
+func (gl *GL) VertexAttribL4d(index glbase.Attrib, x, y, z, w float64) {
+ C.gl4_3core_glVertexAttribL4d(gl.funcs, C.GLuint(index), C.GLdouble(x), C.GLdouble(y), C.GLdouble(z), C.GLdouble(w))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribL3d.xml
+func (gl *GL) VertexAttribL3d(index glbase.Attrib, x, y, z float64) {
+ C.gl4_3core_glVertexAttribL3d(gl.funcs, C.GLuint(index), C.GLdouble(x), C.GLdouble(y), C.GLdouble(z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribL2d.xml
+func (gl *GL) VertexAttribL2d(index glbase.Attrib, x, y float64) {
+ C.gl4_3core_glVertexAttribL2d(gl.funcs, C.GLuint(index), C.GLdouble(x), C.GLdouble(y))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribL1d.xml
+func (gl *GL) VertexAttribL1d(index glbase.Attrib, x float64) {
+ C.gl4_3core_glVertexAttribL1d(gl.funcs, C.GLuint(index), C.GLdouble(x))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetProgramPipelineInfoLog.xml
+func (gl *GL) GetProgramPipelineInfoLog(pipeline uint32, bufSize int32, length []int32, infoLog []byte) {
+ C.gl4_3core_glGetProgramPipelineInfoLog(gl.funcs, C.GLuint(pipeline), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&infoLog[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glValidateProgramPipeline.xml
+func (gl *GL) ValidateProgramPipeline(pipeline uint32) {
+ C.gl4_3core_glValidateProgramPipeline(gl.funcs, C.GLuint(pipeline))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix4x3dv.xml
+func (gl *GL) ProgramUniformMatrix4x3dv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float64) {
+ if len(value) != 3 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_3core_glProgramUniformMatrix4x3dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix3x4dv.xml
+func (gl *GL) ProgramUniformMatrix3x4dv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float64) {
+ if len(value) != 4 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_3core_glProgramUniformMatrix3x4dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix4x2dv.xml
+func (gl *GL) ProgramUniformMatrix4x2dv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float64) {
+ if len(value) != 2 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_3core_glProgramUniformMatrix4x2dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix2x4dv.xml
+func (gl *GL) ProgramUniformMatrix2x4dv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float64) {
+ if len(value) != 4 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_3core_glProgramUniformMatrix2x4dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix3x2dv.xml
+func (gl *GL) ProgramUniformMatrix3x2dv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float64) {
+ if len(value) != 2 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_3core_glProgramUniformMatrix3x2dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix2x3dv.xml
+func (gl *GL) ProgramUniformMatrix2x3dv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float64) {
+ if len(value) != 3 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_3core_glProgramUniformMatrix2x3dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix4x3fv.xml
+func (gl *GL) ProgramUniformMatrix4x3fv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float32) {
+ if len(value) != 3 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_3core_glProgramUniformMatrix4x3fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix3x4fv.xml
+func (gl *GL) ProgramUniformMatrix3x4fv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float32) {
+ if len(value) != 4 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_3core_glProgramUniformMatrix3x4fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix4x2fv.xml
+func (gl *GL) ProgramUniformMatrix4x2fv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float32) {
+ if len(value) != 2 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_3core_glProgramUniformMatrix4x2fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix2x4fv.xml
+func (gl *GL) ProgramUniformMatrix2x4fv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float32) {
+ if len(value) != 4 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_3core_glProgramUniformMatrix2x4fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix3x2fv.xml
+func (gl *GL) ProgramUniformMatrix3x2fv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float32) {
+ if len(value) != 2 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_3core_glProgramUniformMatrix3x2fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix2x3fv.xml
+func (gl *GL) ProgramUniformMatrix2x3fv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float32) {
+ if len(value) != 3 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_3core_glProgramUniformMatrix2x3fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix4dv.xml
+func (gl *GL) ProgramUniformMatrix4dv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float64) {
+ if len(value) != 4 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_3core_glProgramUniformMatrix4dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix3dv.xml
+func (gl *GL) ProgramUniformMatrix3dv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float64) {
+ if len(value) != 3 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_3core_glProgramUniformMatrix3dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix2dv.xml
+func (gl *GL) ProgramUniformMatrix2dv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float64) {
+ if len(value) != 2 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_3core_glProgramUniformMatrix2dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix4fv.xml
+func (gl *GL) ProgramUniformMatrix4fv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float32) {
+ if len(value) != 4 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_3core_glProgramUniformMatrix4fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix3fv.xml
+func (gl *GL) ProgramUniformMatrix3fv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float32) {
+ if len(value) != 3 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_3core_glProgramUniformMatrix3fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniformMatrix2fv.xml
+func (gl *GL) ProgramUniformMatrix2fv(program glbase.Program, location glbase.Uniform, count int, transpose bool, value []float32) {
+ if len(value) != 2 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_3core_glProgramUniformMatrix2fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform4uiv.xml
+func (gl *GL) ProgramUniform4uiv(program glbase.Program, location glbase.Uniform, count int, value []uint32) {
+ C.gl4_3core_glProgramUniform4uiv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform4ui.xml
+func (gl *GL) ProgramUniform4ui(program glbase.Program, location glbase.Uniform, v0, v1, v2, v3 uint32) {
+ C.gl4_3core_glProgramUniform4ui(gl.funcs, C.GLuint(program), C.GLint(location), C.GLuint(v0), C.GLuint(v1), C.GLuint(v2), C.GLuint(v3))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform4dv.xml
+func (gl *GL) ProgramUniform4dv(program glbase.Program, location glbase.Uniform, count int, value []float64) {
+ if len(value) != 4 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_3core_glProgramUniform4dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform4d.xml
+func (gl *GL) ProgramUniform4d(program glbase.Program, location glbase.Uniform, v0, v1, v2, v3 float64) {
+ C.gl4_3core_glProgramUniform4d(gl.funcs, C.GLuint(program), C.GLint(location), C.GLdouble(v0), C.GLdouble(v1), C.GLdouble(v2), C.GLdouble(v3))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform4fv.xml
+func (gl *GL) ProgramUniform4fv(program glbase.Program, location glbase.Uniform, count int, value []float32) {
+ if len(value) != 4 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_3core_glProgramUniform4fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform4f.xml
+func (gl *GL) ProgramUniform4f(program glbase.Program, location glbase.Uniform, v0, v1, v2, v3 float32) {
+ C.gl4_3core_glProgramUniform4f(gl.funcs, C.GLuint(program), C.GLint(location), C.GLfloat(v0), C.GLfloat(v1), C.GLfloat(v2), C.GLfloat(v3))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform4iv.xml
+func (gl *GL) ProgramUniform4iv(program glbase.Program, location glbase.Uniform, count int, value []int32) {
+ if len(value) != 4 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_3core_glProgramUniform4iv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform4i.xml
+func (gl *GL) ProgramUniform4i(program glbase.Program, location glbase.Uniform, v0, v1, v2, v3 int32) {
+ C.gl4_3core_glProgramUniform4i(gl.funcs, C.GLuint(program), C.GLint(location), C.GLint(v0), C.GLint(v1), C.GLint(v2), C.GLint(v3))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform3uiv.xml
+func (gl *GL) ProgramUniform3uiv(program glbase.Program, location glbase.Uniform, count int, value []uint32) {
+ C.gl4_3core_glProgramUniform3uiv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform3ui.xml
+func (gl *GL) ProgramUniform3ui(program glbase.Program, location glbase.Uniform, v0, v1, v2 uint32) {
+ C.gl4_3core_glProgramUniform3ui(gl.funcs, C.GLuint(program), C.GLint(location), C.GLuint(v0), C.GLuint(v1), C.GLuint(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform3dv.xml
+func (gl *GL) ProgramUniform3dv(program glbase.Program, location glbase.Uniform, count int, value []float64) {
+ if len(value) != 3 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_3core_glProgramUniform3dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform3d.xml
+func (gl *GL) ProgramUniform3d(program glbase.Program, location glbase.Uniform, v0, v1, v2 float64) {
+ C.gl4_3core_glProgramUniform3d(gl.funcs, C.GLuint(program), C.GLint(location), C.GLdouble(v0), C.GLdouble(v1), C.GLdouble(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform3fv.xml
+func (gl *GL) ProgramUniform3fv(program glbase.Program, location glbase.Uniform, count int, value []float32) {
+ if len(value) != 3 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_3core_glProgramUniform3fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform3f.xml
+func (gl *GL) ProgramUniform3f(program glbase.Program, location glbase.Uniform, v0, v1, v2 float32) {
+ C.gl4_3core_glProgramUniform3f(gl.funcs, C.GLuint(program), C.GLint(location), C.GLfloat(v0), C.GLfloat(v1), C.GLfloat(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform3iv.xml
+func (gl *GL) ProgramUniform3iv(program glbase.Program, location glbase.Uniform, count int, value []int32) {
+ if len(value) != 3 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_3core_glProgramUniform3iv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform3i.xml
+func (gl *GL) ProgramUniform3i(program glbase.Program, location glbase.Uniform, v0, v1, v2 int32) {
+ C.gl4_3core_glProgramUniform3i(gl.funcs, C.GLuint(program), C.GLint(location), C.GLint(v0), C.GLint(v1), C.GLint(v2))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform2uiv.xml
+func (gl *GL) ProgramUniform2uiv(program glbase.Program, location glbase.Uniform, count int, value []uint32) {
+ C.gl4_3core_glProgramUniform2uiv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform2ui.xml
+func (gl *GL) ProgramUniform2ui(program glbase.Program, location glbase.Uniform, v0, v1 uint32) {
+ C.gl4_3core_glProgramUniform2ui(gl.funcs, C.GLuint(program), C.GLint(location), C.GLuint(v0), C.GLuint(v1))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform2dv.xml
+func (gl *GL) ProgramUniform2dv(program glbase.Program, location glbase.Uniform, count int, value []float64) {
+ if len(value) != 2 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_3core_glProgramUniform2dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform2d.xml
+func (gl *GL) ProgramUniform2d(program glbase.Program, location glbase.Uniform, v0, v1 float64) {
+ C.gl4_3core_glProgramUniform2d(gl.funcs, C.GLuint(program), C.GLint(location), C.GLdouble(v0), C.GLdouble(v1))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform2fv.xml
+func (gl *GL) ProgramUniform2fv(program glbase.Program, location glbase.Uniform, count int, value []float32) {
+ if len(value) != 2 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_3core_glProgramUniform2fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform2f.xml
+func (gl *GL) ProgramUniform2f(program glbase.Program, location glbase.Uniform, v0, v1 float32) {
+ C.gl4_3core_glProgramUniform2f(gl.funcs, C.GLuint(program), C.GLint(location), C.GLfloat(v0), C.GLfloat(v1))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform2iv.xml
+func (gl *GL) ProgramUniform2iv(program glbase.Program, location glbase.Uniform, count int, value []int32) {
+ if len(value) != 2 {
+ panic("parameter value has incorrect length")
+ }
+ C.gl4_3core_glProgramUniform2iv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform2i.xml
+func (gl *GL) ProgramUniform2i(program glbase.Program, location glbase.Uniform, v0, v1 int32) {
+ C.gl4_3core_glProgramUniform2i(gl.funcs, C.GLuint(program), C.GLint(location), C.GLint(v0), C.GLint(v1))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform1uiv.xml
+func (gl *GL) ProgramUniform1uiv(program glbase.Program, location glbase.Uniform, count int, value []uint32) {
+ C.gl4_3core_glProgramUniform1uiv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform1ui.xml
+func (gl *GL) ProgramUniform1ui(program glbase.Program, location glbase.Uniform, v0 uint32) {
+ C.gl4_3core_glProgramUniform1ui(gl.funcs, C.GLuint(program), C.GLint(location), C.GLuint(v0))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform1dv.xml
+func (gl *GL) ProgramUniform1dv(program glbase.Program, location glbase.Uniform, count int, value []float64) {
+ C.gl4_3core_glProgramUniform1dv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLdouble)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform1d.xml
+func (gl *GL) ProgramUniform1d(program glbase.Program, location glbase.Uniform, v0 float64) {
+ C.gl4_3core_glProgramUniform1d(gl.funcs, C.GLuint(program), C.GLint(location), C.GLdouble(v0))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform1fv.xml
+func (gl *GL) ProgramUniform1fv(program glbase.Program, location glbase.Uniform, count int, value []float32) {
+ C.gl4_3core_glProgramUniform1fv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform1f.xml
+func (gl *GL) ProgramUniform1f(program glbase.Program, location glbase.Uniform, v0 float32) {
+ C.gl4_3core_glProgramUniform1f(gl.funcs, C.GLuint(program), C.GLint(location), C.GLfloat(v0))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform1iv.xml
+func (gl *GL) ProgramUniform1iv(program glbase.Program, location glbase.Uniform, count int, value []int32) {
+ C.gl4_3core_glProgramUniform1iv(gl.funcs, C.GLuint(program), C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramUniform1i.xml
+func (gl *GL) ProgramUniform1i(program glbase.Program, location glbase.Uniform, v0 int32) {
+ C.gl4_3core_glProgramUniform1i(gl.funcs, C.GLuint(program), C.GLint(location), C.GLint(v0))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetProgramPipelineiv.xml
+func (gl *GL) GetProgramPipelineiv(pipeline uint32, pname glbase.Enum, params []int32) {
+ C.gl4_3core_glGetProgramPipelineiv(gl.funcs, C.GLuint(pipeline), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glIsProgramPipeline.xml
+func (gl *GL) IsProgramPipeline(pipeline uint32) bool {
+ glresult := C.gl4_3core_glIsProgramPipeline(gl.funcs, C.GLuint(pipeline))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGenProgramPipelines.xml
+func (gl *GL) GenProgramPipelines(n int, pipelines []uint32) {
+ C.gl4_3core_glGenProgramPipelines(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&pipelines[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDeleteProgramPipelines.xml
+func (gl *GL) DeleteProgramPipelines(n int, pipelines []uint32) {
+ C.gl4_3core_glDeleteProgramPipelines(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&pipelines[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindProgramPipeline.xml
+func (gl *GL) BindProgramPipeline(pipeline uint32) {
+ C.gl4_3core_glBindProgramPipeline(gl.funcs, C.GLuint(pipeline))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glActiveShaderProgram.xml
+func (gl *GL) ActiveShaderProgram(pipeline uint32, program glbase.Program) {
+ C.gl4_3core_glActiveShaderProgram(gl.funcs, C.GLuint(pipeline), C.GLuint(program))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glUseProgramStages.xml
+func (gl *GL) UseProgramStages(pipeline uint32, stages glbase.Bitfield, program glbase.Program) {
+ C.gl4_3core_glUseProgramStages(gl.funcs, C.GLuint(pipeline), C.GLbitfield(stages), C.GLuint(program))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramParameteri.xml
+func (gl *GL) ProgramParameteri(program glbase.Program, pname glbase.Enum, value int32) {
+ C.gl4_3core_glProgramParameteri(gl.funcs, C.GLuint(program), C.GLenum(pname), C.GLint(value))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glProgramBinary.xml
+func (gl *GL) ProgramBinary(program glbase.Program, binaryFormat glbase.Enum, binary interface{}, length int32) {
+ var binary_ptr unsafe.Pointer
+ var binary_v = reflect.ValueOf(binary)
+ if binary != nil && binary_v.Kind() != reflect.Slice {
+ panic("parameter binary must be a slice")
+ }
+ if binary != nil {
+ binary_ptr = unsafe.Pointer(binary_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3core_glProgramBinary(gl.funcs, C.GLuint(program), C.GLenum(binaryFormat), binary_ptr, C.GLsizei(length))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetProgramBinary.xml
+func (gl *GL) GetProgramBinary(program glbase.Program, bufSize int32, length []int32, binaryFormat []glbase.Enum, binary interface{}) {
+ var binary_ptr unsafe.Pointer
+ var binary_v = reflect.ValueOf(binary)
+ if binary != nil && binary_v.Kind() != reflect.Slice {
+ panic("parameter binary must be a slice")
+ }
+ if binary != nil {
+ binary_ptr = unsafe.Pointer(binary_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3core_glGetProgramBinary(gl.funcs, C.GLuint(program), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLenum)(unsafe.Pointer(&binaryFormat[0])), binary_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearDepthf.xml
+func (gl *GL) ClearDepthf(dd float32) {
+ C.gl4_3core_glClearDepthf(gl.funcs, C.GLfloat(dd))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDepthRangef.xml
+func (gl *GL) DepthRangef(n, f float32) {
+ C.gl4_3core_glDepthRangef(gl.funcs, C.GLfloat(n), C.GLfloat(f))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetShaderPrecisionFormat.xml
+func (gl *GL) GetShaderPrecisionFormat(shadertype, precisionType glbase.Enum, range_, precision []int32) {
+ C.gl4_3core_glGetShaderPrecisionFormat(gl.funcs, C.GLenum(shadertype), C.GLenum(precisionType), (*C.GLint)(unsafe.Pointer(&range_[0])), (*C.GLint)(unsafe.Pointer(&precision[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glShaderBinary.xml
+func (gl *GL) ShaderBinary(count int, shaders []glbase.Shader, binaryFormat glbase.Enum, binary interface{}, length int32) {
+ var binary_ptr unsafe.Pointer
+ var binary_v = reflect.ValueOf(binary)
+ if binary != nil && binary_v.Kind() != reflect.Slice {
+ panic("parameter binary must be a slice")
+ }
+ if binary != nil {
+ binary_ptr = unsafe.Pointer(binary_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3core_glShaderBinary(gl.funcs, C.GLsizei(count), (*C.GLuint)(unsafe.Pointer(&shaders[0])), C.GLenum(binaryFormat), binary_ptr, C.GLsizei(length))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glReleaseShaderCompiler.xml
+func (gl *GL) ReleaseShaderCompiler() {
+ C.gl4_3core_glReleaseShaderCompiler(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexStorage3D.xml
+func (gl *GL) TexStorage3D(target glbase.Enum, levels int32, internalFormat glbase.Enum, width, height int, depth int32) {
+ C.gl4_3core_glTexStorage3D(gl.funcs, C.GLenum(target), C.GLsizei(levels), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexStorage2D.xml
+func (gl *GL) TexStorage2D(target glbase.Enum, levels int32, internalFormat glbase.Enum, width, height int) {
+ C.gl4_3core_glTexStorage2D(gl.funcs, C.GLenum(target), C.GLsizei(levels), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexStorage1D.xml
+func (gl *GL) TexStorage1D(target glbase.Enum, levels int32, internalFormat glbase.Enum, width int) {
+ C.gl4_3core_glTexStorage1D(gl.funcs, C.GLenum(target), C.GLsizei(levels), C.GLenum(internalFormat), C.GLsizei(width))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMemoryBarrier.xml
+func (gl *GL) MemoryBarrier(barriers glbase.Bitfield) {
+ C.gl4_3core_glMemoryBarrier(gl.funcs, C.GLbitfield(barriers))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindImageTexture.xml
+func (gl *GL) BindImageTexture(unit uint32, texture glbase.Texture, level int, layered bool, layer int32, access, format glbase.Enum) {
+ C.gl4_3core_glBindImageTexture(gl.funcs, C.GLuint(unit), C.GLuint(texture), C.GLint(level), *(*C.GLboolean)(unsafe.Pointer(&layered)), C.GLint(layer), C.GLenum(access), C.GLenum(format))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetActiveAtomicCounterBufferiv.xml
+func (gl *GL) GetActiveAtomicCounterBufferiv(program glbase.Program, bufferIndex uint32, pname glbase.Enum, params []int32) {
+ C.gl4_3core_glGetActiveAtomicCounterBufferiv(gl.funcs, C.GLuint(program), C.GLuint(bufferIndex), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetInternalformativ.xml
+func (gl *GL) GetInternalformativ(target, internalFormat, pname glbase.Enum, bufSize int32, params []int32) {
+ C.gl4_3core_glGetInternalformativ(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLenum(pname), C.GLsizei(bufSize), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawTransformFeedbackStreamInstanced.xml
+func (gl *GL) DrawTransformFeedbackStreamInstanced(mode glbase.Enum, id, stream uint32, instancecount int32) {
+ C.gl4_3core_glDrawTransformFeedbackStreamInstanced(gl.funcs, C.GLenum(mode), C.GLuint(id), C.GLuint(stream), C.GLsizei(instancecount))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawTransformFeedbackInstanced.xml
+func (gl *GL) DrawTransformFeedbackInstanced(mode glbase.Enum, id uint32, instancecount int32) {
+ C.gl4_3core_glDrawTransformFeedbackInstanced(gl.funcs, C.GLenum(mode), C.GLuint(id), C.GLsizei(instancecount))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawElementsInstancedBaseVertexBaseInstance.xml
+func (gl *GL) DrawElementsInstancedBaseVertexBaseInstance(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}, instancecount, basevertex int32, baseinstance uint32) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3core_glDrawElementsInstancedBaseVertexBaseInstance(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr, C.GLsizei(instancecount), C.GLint(basevertex), C.GLuint(baseinstance))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawElementsInstancedBaseInstance.xml
+func (gl *GL) DrawElementsInstancedBaseInstance(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}, instancecount int32, baseinstance uint32) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3core_glDrawElementsInstancedBaseInstance(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr, C.GLsizei(instancecount), C.GLuint(baseinstance))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDrawArraysInstancedBaseInstance.xml
+func (gl *GL) DrawArraysInstancedBaseInstance(mode glbase.Enum, first, count int, instancecount int32, baseinstance uint32) {
+ C.gl4_3core_glDrawArraysInstancedBaseInstance(gl.funcs, C.GLenum(mode), C.GLint(first), C.GLsizei(count), C.GLsizei(instancecount), C.GLuint(baseinstance))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexStorage3DMultisample.xml
+func (gl *GL) TexStorage3DMultisample(target glbase.Enum, samples int32, internalFormat glbase.Enum, width, height int, depth int32, fixedsamplelocations bool) {
+ C.gl4_3core_glTexStorage3DMultisample(gl.funcs, C.GLenum(target), C.GLsizei(samples), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth), *(*C.GLboolean)(unsafe.Pointer(&fixedsamplelocations)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexStorage2DMultisample.xml
+func (gl *GL) TexStorage2DMultisample(target glbase.Enum, samples int32, internalFormat glbase.Enum, width, height int, fixedsamplelocations bool) {
+ C.gl4_3core_glTexStorage2DMultisample(gl.funcs, C.GLenum(target), C.GLsizei(samples), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), *(*C.GLboolean)(unsafe.Pointer(&fixedsamplelocations)))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTexBufferRange.xml
+func (gl *GL) TexBufferRange(target, internalFormat glbase.Enum, buffer glbase.Buffer, offset, size int) {
+ C.gl4_3core_glTexBufferRange(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLuint(buffer), C.GLintptr(offset), C.GLsizeiptr(size))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glShaderStorageBlockBinding.xml
+func (gl *GL) ShaderStorageBlockBinding(program glbase.Program, storageBlockIndex, storageBlockBinding uint32) {
+ C.gl4_3core_glShaderStorageBlockBinding(gl.funcs, C.GLuint(program), C.GLuint(storageBlockIndex), C.GLuint(storageBlockBinding))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetProgramResourceLocationIndex.xml
+func (gl *GL) GetProgramResourceLocationIndex(program glbase.Program, programInterface glbase.Enum, name []byte) int32 {
+ glresult := C.gl4_3core_glGetProgramResourceLocationIndex(gl.funcs, C.GLuint(program), C.GLenum(programInterface), (*C.GLchar)(unsafe.Pointer(&name[0])))
+ return int32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetProgramResourceLocation.xml
+func (gl *GL) GetProgramResourceLocation(program glbase.Program, programInterface glbase.Enum, name []byte) int32 {
+ glresult := C.gl4_3core_glGetProgramResourceLocation(gl.funcs, C.GLuint(program), C.GLenum(programInterface), (*C.GLchar)(unsafe.Pointer(&name[0])))
+ return int32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetProgramResourceiv.xml
+func (gl *GL) GetProgramResourceiv(program glbase.Program, programInterface glbase.Enum, index uint32, propCount int32, props []glbase.Enum, bufSize int32, length, params []int32) {
+ C.gl4_3core_glGetProgramResourceiv(gl.funcs, C.GLuint(program), C.GLenum(programInterface), C.GLuint(index), C.GLsizei(propCount), (*C.GLenum)(unsafe.Pointer(&props[0])), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetProgramResourceName.xml
+func (gl *GL) GetProgramResourceName(program glbase.Program, programInterface glbase.Enum, index uint32, bufSize int32, length []int32, name []byte) {
+ C.gl4_3core_glGetProgramResourceName(gl.funcs, C.GLuint(program), C.GLenum(programInterface), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetProgramResourceIndex.xml
+func (gl *GL) GetProgramResourceIndex(program glbase.Program, programInterface glbase.Enum, name []byte) uint32 {
+ glresult := C.gl4_3core_glGetProgramResourceIndex(gl.funcs, C.GLuint(program), C.GLenum(programInterface), (*C.GLchar)(unsafe.Pointer(&name[0])))
+ return uint32(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetProgramInterfaceiv.xml
+func (gl *GL) GetProgramInterfaceiv(program glbase.Program, programInterface, pname glbase.Enum, params []int32) {
+ C.gl4_3core_glGetProgramInterfaceiv(gl.funcs, C.GLuint(program), C.GLenum(programInterface), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiDrawElementsIndirect.xml
+func (gl *GL) MultiDrawElementsIndirect(mode, gltype glbase.Enum, indirect interface{}, drawcount int32, stride int) {
+ var indirect_ptr unsafe.Pointer
+ var indirect_v = reflect.ValueOf(indirect)
+ if indirect != nil && indirect_v.Kind() != reflect.Slice {
+ panic("parameter indirect must be a slice")
+ }
+ if indirect != nil {
+ indirect_ptr = unsafe.Pointer(indirect_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3core_glMultiDrawElementsIndirect(gl.funcs, C.GLenum(mode), C.GLenum(gltype), indirect_ptr, C.GLsizei(drawcount), C.GLsizei(stride))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glMultiDrawArraysIndirect.xml
+func (gl *GL) MultiDrawArraysIndirect(mode glbase.Enum, indirect interface{}, drawcount int32, stride int) {
+ var indirect_ptr unsafe.Pointer
+ var indirect_v = reflect.ValueOf(indirect)
+ if indirect != nil && indirect_v.Kind() != reflect.Slice {
+ panic("parameter indirect must be a slice")
+ }
+ if indirect != nil {
+ indirect_ptr = unsafe.Pointer(indirect_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3core_glMultiDrawArraysIndirect(gl.funcs, C.GLenum(mode), indirect_ptr, C.GLsizei(drawcount), C.GLsizei(stride))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glInvalidateSubFramebuffer.xml
+func (gl *GL) InvalidateSubFramebuffer(target glbase.Enum, numAttachments int32, attachments []glbase.Enum, x, y, width, height int) {
+ C.gl4_3core_glInvalidateSubFramebuffer(gl.funcs, C.GLenum(target), C.GLsizei(numAttachments), (*C.GLenum)(unsafe.Pointer(&attachments[0])), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glInvalidateFramebuffer.xml
+func (gl *GL) InvalidateFramebuffer(target glbase.Enum, numAttachments int32, attachments []glbase.Enum) {
+ C.gl4_3core_glInvalidateFramebuffer(gl.funcs, C.GLenum(target), C.GLsizei(numAttachments), (*C.GLenum)(unsafe.Pointer(&attachments[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glInvalidateBufferData.xml
+func (gl *GL) InvalidateBufferData(buffer glbase.Buffer) {
+ C.gl4_3core_glInvalidateBufferData(gl.funcs, C.GLuint(buffer))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glInvalidateBufferSubData.xml
+func (gl *GL) InvalidateBufferSubData(buffer glbase.Buffer, offset, length int) {
+ C.gl4_3core_glInvalidateBufferSubData(gl.funcs, C.GLuint(buffer), C.GLintptr(offset), C.GLsizeiptr(length))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glInvalidateTexImage.xml
+func (gl *GL) InvalidateTexImage(texture glbase.Texture, level int) {
+ C.gl4_3core_glInvalidateTexImage(gl.funcs, C.GLuint(texture), C.GLint(level))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glInvalidateTexSubImage.xml
+func (gl *GL) InvalidateTexSubImage(texture glbase.Texture, level, xoffset, yoffset int, zoffset int32, width, height int, depth int32) {
+ C.gl4_3core_glInvalidateTexSubImage(gl.funcs, C.GLuint(texture), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(zoffset), C.GLsizei(width), C.GLsizei(height), C.GLsizei(depth))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetInternalformati64v.xml
+func (gl *GL) GetInternalformati64v(target, internalFormat, pname glbase.Enum, bufSize int32, params []int64) {
+ C.gl4_3core_glGetInternalformati64v(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLenum(pname), C.GLsizei(bufSize), (*C.GLint64)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glGetFramebufferParameteriv.xml
+func (gl *GL) GetFramebufferParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gl4_3core_glGetFramebufferParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glFramebufferParameteri.xml
+func (gl *GL) FramebufferParameteri(target, pname glbase.Enum, param int32) {
+ C.gl4_3core_glFramebufferParameteri(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexBindingDivisor.xml
+func (gl *GL) VertexBindingDivisor(bindingindex, divisor uint32) {
+ C.gl4_3core_glVertexBindingDivisor(gl.funcs, C.GLuint(bindingindex), C.GLuint(divisor))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribBinding.xml
+func (gl *GL) VertexAttribBinding(attribindex, bindingindex uint32) {
+ C.gl4_3core_glVertexAttribBinding(gl.funcs, C.GLuint(attribindex), C.GLuint(bindingindex))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribLFormat.xml
+func (gl *GL) VertexAttribLFormat(attribindex uint32, size int, gltype glbase.Enum, relativeoffset uint32) {
+ C.gl4_3core_glVertexAttribLFormat(gl.funcs, C.GLuint(attribindex), C.GLint(size), C.GLenum(gltype), C.GLuint(relativeoffset))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribIFormat.xml
+func (gl *GL) VertexAttribIFormat(attribindex uint32, size int, gltype glbase.Enum, relativeoffset uint32) {
+ C.gl4_3core_glVertexAttribIFormat(gl.funcs, C.GLuint(attribindex), C.GLint(size), C.GLenum(gltype), C.GLuint(relativeoffset))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glVertexAttribFormat.xml
+func (gl *GL) VertexAttribFormat(attribindex uint32, size int, gltype glbase.Enum, normalized bool, relativeoffset uint32) {
+ C.gl4_3core_glVertexAttribFormat(gl.funcs, C.GLuint(attribindex), C.GLint(size), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), C.GLuint(relativeoffset))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glBindVertexBuffer.xml
+func (gl *GL) BindVertexBuffer(bindingindex uint32, buffer glbase.Buffer, offset, stride int) {
+ C.gl4_3core_glBindVertexBuffer(gl.funcs, C.GLuint(bindingindex), C.GLuint(buffer), C.GLintptr(offset), C.GLsizei(stride))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glTextureView.xml
+func (gl *GL) TextureView(texture glbase.Texture, target glbase.Enum, origtexture uint32, internalFormat glbase.Enum, minlevel, numlevels, minlayer, numlayers uint32) {
+ C.gl4_3core_glTextureView(gl.funcs, C.GLuint(texture), C.GLenum(target), C.GLuint(origtexture), C.GLenum(internalFormat), C.GLuint(minlevel), C.GLuint(numlevels), C.GLuint(minlayer), C.GLuint(numlayers))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glCopyImageSubData.xml
+func (gl *GL) CopyImageSubData(srcName uint32, srcTarget glbase.Enum, srcLevel, srcX, srcY, srcZ int32, dstName uint32, dstTarget glbase.Enum, dstLevel, dstX, dstY, dstZ, srcWidth, srcHeight, srcDepth int32) {
+ C.gl4_3core_glCopyImageSubData(gl.funcs, C.GLuint(srcName), C.GLenum(srcTarget), C.GLint(srcLevel), C.GLint(srcX), C.GLint(srcY), C.GLint(srcZ), C.GLuint(dstName), C.GLenum(dstTarget), C.GLint(dstLevel), C.GLint(dstX), C.GLint(dstY), C.GLint(dstZ), C.GLsizei(srcWidth), C.GLsizei(srcHeight), C.GLsizei(srcDepth))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDispatchComputeIndirect.xml
+func (gl *GL) DispatchComputeIndirect(indirect int) {
+ C.gl4_3core_glDispatchComputeIndirect(gl.funcs, C.GLintptr(indirect))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glDispatchCompute.xml
+func (gl *GL) DispatchCompute(num_groups_x, num_groups_y, num_groups_z uint32) {
+ C.gl4_3core_glDispatchCompute(gl.funcs, C.GLuint(num_groups_x), C.GLuint(num_groups_y), C.GLuint(num_groups_z))
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearBufferSubData.xml
+func (gl *GL) ClearBufferSubData(target, internalFormat glbase.Enum, offset, size int, format, gltype glbase.Enum, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3core_glClearBufferSubData(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLintptr(offset), C.GLsizeiptr(size), C.GLenum(format), C.GLenum(gltype), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man4/xhtml/glClearBufferData.xml
+func (gl *GL) ClearBufferData(target, internalFormat, format, gltype glbase.Enum, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gl4_3core_glClearBufferData(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLenum(format), C.GLenum(gltype), data_ptr)
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/es2/funcs.cpp b/Godeps/_workspace/src/github.com/obscuren/qml/gl/es2/funcs.cpp
new file mode 100644
index 000000000..71acf8d1b
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/es2/funcs.cpp
@@ -0,0 +1,813 @@
+
+// ** file automatically generated by glgen -- do not edit manually **
+
+#include <QOpenGLContext>
+#include <QtGui/qopenglfunctions.h>
+
+#include "funcs.h"
+
+void *gles2_funcs() {
+ QOpenGLFunctions* funcs = QOpenGLContext::currentContext()->functions();
+ if (!funcs) {
+ return 0;
+ }
+ return funcs;
+}
+
+
+void gles2_glActiveTexture(void *_glfuncs, GLenum texture)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glActiveTexture(texture);
+}
+
+void gles2_glAttachShader(void *_glfuncs, GLuint program, GLuint shader)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glAttachShader(program, shader);
+}
+
+void gles2_glBindAttribLocation(void *_glfuncs, GLuint program, GLuint index, const GLchar* name)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glBindAttribLocation(program, index, name);
+}
+
+void gles2_glBindBuffer(void *_glfuncs, GLenum target, GLuint buffer)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glBindBuffer(target, buffer);
+}
+
+void gles2_glBindFramebuffer(void *_glfuncs, GLenum target, GLuint framebuffer)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glBindFramebuffer(target, framebuffer);
+}
+
+void gles2_glBindRenderbuffer(void *_glfuncs, GLenum target, GLuint renderbuffer)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glBindRenderbuffer(target, renderbuffer);
+}
+
+void gles2_glBlendColor(void *_glfuncs, GLclampf red, GLclampf green, GLclampf blue, GLclampf alpha)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glBlendColor(red, green, blue, alpha);
+}
+
+void gles2_glBlendEquation(void *_glfuncs, GLenum mode)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glBlendEquation(mode);
+}
+
+void gles2_glBlendEquationSeparate(void *_glfuncs, GLenum modeRGB, GLenum modeAlpha)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glBlendEquationSeparate(modeRGB, modeAlpha);
+}
+
+void gles2_glBlendFuncSeparate(void *_glfuncs, GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha, GLenum dstAlpha)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glBlendFuncSeparate(srcRGB, dstRGB, srcAlpha, dstAlpha);
+}
+
+void gles2_glBufferData(void *_glfuncs, GLenum target, GLsizeiptr size, const GLvoid* data, GLenum usage)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glBufferData(target, size, data, usage);
+}
+
+void gles2_glBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid* data)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glBufferSubData(target, offset, size, data);
+}
+
+GLenum gles2_glCheckFramebufferStatus(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ return _qglfuncs->glCheckFramebufferStatus(target);
+}
+
+void gles2_glClearDepthf(void *_glfuncs, GLclampf depth)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glClearDepthf(depth);
+}
+
+void gles2_glCompileShader(void *_glfuncs, GLuint shader)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glCompileShader(shader);
+}
+
+void gles2_glCompressedTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glCompressedTexImage2D(target, level, internalFormat, width, height, border, imageSize, data);
+}
+
+void gles2_glCompressedTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid* data)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glCompressedTexSubImage2D(target, level, xoffset, yoffset, width, height, format, imageSize, data);
+}
+
+GLuint gles2_glCreateProgram(void *_glfuncs)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ return _qglfuncs->glCreateProgram();
+}
+
+GLuint gles2_glCreateShader(void *_glfuncs, GLenum gltype)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ return _qglfuncs->glCreateShader(gltype);
+}
+
+void gles2_glDeleteBuffers(void *_glfuncs, GLsizei n, const GLuint* buffers)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glDeleteBuffers(n, buffers);
+}
+
+void gles2_glDeleteFramebuffers(void *_glfuncs, GLsizei n, const GLuint* framebuffers)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glDeleteFramebuffers(n, framebuffers);
+}
+
+void gles2_glDeleteProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glDeleteProgram(program);
+}
+
+void gles2_glDeleteRenderbuffers(void *_glfuncs, GLsizei n, const GLuint* renderbuffers)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glDeleteRenderbuffers(n, renderbuffers);
+}
+
+void gles2_glDeleteShader(void *_glfuncs, GLuint shader)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glDeleteShader(shader);
+}
+
+void gles2_glDepthRangef(void *_glfuncs, GLclampf zNear, GLclampf zFar)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glDepthRangef(zNear, zFar);
+}
+
+void gles2_glDetachShader(void *_glfuncs, GLuint program, GLuint shader)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glDetachShader(program, shader);
+}
+
+void gles2_glDisableVertexAttribArray(void *_glfuncs, GLuint index)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glDisableVertexAttribArray(index);
+}
+
+void gles2_glEnableVertexAttribArray(void *_glfuncs, GLuint index)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glEnableVertexAttribArray(index);
+}
+
+void gles2_glFramebufferRenderbuffer(void *_glfuncs, GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glFramebufferRenderbuffer(target, attachment, renderbuffertarget, renderbuffer);
+}
+
+void gles2_glFramebufferTexture2D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glFramebufferTexture2D(target, attachment, textarget, texture, level);
+}
+
+void gles2_glGenBuffers(void *_glfuncs, GLsizei n, GLuint* buffers)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glGenBuffers(n, buffers);
+}
+
+void gles2_glGenerateMipmap(void *_glfuncs, GLenum target)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glGenerateMipmap(target);
+}
+
+void gles2_glGenFramebuffers(void *_glfuncs, GLsizei n, GLuint* framebuffers)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glGenFramebuffers(n, framebuffers);
+}
+
+void gles2_glGenRenderbuffers(void *_glfuncs, GLsizei n, GLuint* renderbuffers)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glGenRenderbuffers(n, renderbuffers);
+}
+
+void gles2_glGetActiveAttrib(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glGetActiveAttrib(program, index, bufSize, length, size, gltype, name);
+}
+
+void gles2_glGetActiveUniform(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glGetActiveUniform(program, index, bufSize, length, size, gltype, name);
+}
+
+void gles2_glGetAttachedShaders(void *_glfuncs, GLuint program, GLsizei maxcount, GLsizei* count, GLuint* shaders)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glGetAttachedShaders(program, maxcount, count, shaders);
+}
+
+GLint gles2_glGetAttribLocation(void *_glfuncs, GLuint program, const GLchar* name)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ return _qglfuncs->glGetAttribLocation(program, name);
+}
+
+void gles2_glGetBufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glGetBufferParameteriv(target, pname, params);
+}
+
+void gles2_glGetFramebufferAttachmentParameteriv(void *_glfuncs, GLenum target, GLenum attachment, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glGetFramebufferAttachmentParameteriv(target, attachment, pname, params);
+}
+
+void gles2_glGetProgramiv(void *_glfuncs, GLuint program, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glGetProgramiv(program, pname, params);
+}
+
+void gles2_glGetProgramInfoLog(void *_glfuncs, GLuint program, GLsizei bufSize, GLsizei* length, GLchar* infoLog)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glGetProgramInfoLog(program, bufSize, length, infoLog);
+}
+
+void gles2_glGetRenderbufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glGetRenderbufferParameteriv(target, pname, params);
+}
+
+void gles2_glGetShaderiv(void *_glfuncs, GLuint shader, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glGetShaderiv(shader, pname, params);
+}
+
+void gles2_glGetShaderInfoLog(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* infoLog)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glGetShaderInfoLog(shader, bufSize, length, infoLog);
+}
+
+void gles2_glGetShaderPrecisionFormat(void *_glfuncs, GLenum shadertype, GLenum precisionType, GLint* range_, GLint* precision)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glGetShaderPrecisionFormat(shadertype, precisionType, range_, precision);
+}
+
+void gles2_glGetShaderSource(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* source)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glGetShaderSource(shader, bufSize, length, source);
+}
+
+void gles2_glGetUniformfv(void *_glfuncs, GLuint program, GLint location, GLfloat* params)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glGetUniformfv(program, location, params);
+}
+
+void gles2_glGetUniformiv(void *_glfuncs, GLuint program, GLint location, GLint* params)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glGetUniformiv(program, location, params);
+}
+
+GLint gles2_glGetUniformLocation(void *_glfuncs, GLuint program, const GLchar* name)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ return _qglfuncs->glGetUniformLocation(program, name);
+}
+
+void gles2_glGetVertexAttribfv(void *_glfuncs, GLuint index, GLenum pname, GLfloat* params)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribfv(index, pname, params);
+}
+
+void gles2_glGetVertexAttribiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glGetVertexAttribiv(index, pname, params);
+}
+
+GLboolean gles2_glIsBuffer(void *_glfuncs, GLuint buffer)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ return _qglfuncs->glIsBuffer(buffer);
+}
+
+GLboolean gles2_glIsFramebuffer(void *_glfuncs, GLuint framebuffer)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ return _qglfuncs->glIsFramebuffer(framebuffer);
+}
+
+GLboolean gles2_glIsProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ return _qglfuncs->glIsProgram(program);
+}
+
+GLboolean gles2_glIsRenderbuffer(void *_glfuncs, GLuint renderbuffer)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ return _qglfuncs->glIsRenderbuffer(renderbuffer);
+}
+
+GLboolean gles2_glIsShader(void *_glfuncs, GLuint shader)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ return _qglfuncs->glIsShader(shader);
+}
+
+void gles2_glLinkProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glLinkProgram(program);
+}
+
+void gles2_glReleaseShaderCompiler(void *_glfuncs)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glReleaseShaderCompiler();
+}
+
+void gles2_glRenderbufferStorage(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glRenderbufferStorage(target, internalFormat, width, height);
+}
+
+void gles2_glSampleCoverage(void *_glfuncs, GLclampf value, GLboolean invert)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glSampleCoverage(value, invert);
+}
+
+void gles2_glShaderBinary(void *_glfuncs, GLint n, const GLuint* shaders, GLenum binaryFormat, const GLvoid* binary, GLint length)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glShaderBinary(n, shaders, binaryFormat, binary, length);
+}
+
+void gles2_glShaderSource(void *_glfuncs, GLuint shader, GLsizei count, const GLchar** source, const GLint* length)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glShaderSource(shader, count, source, length);
+}
+
+void gles2_glStencilFuncSeparate(void *_glfuncs, GLenum face, GLenum glfunc, GLint ref, GLuint mask)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glStencilFuncSeparate(face, glfunc, ref, mask);
+}
+
+void gles2_glStencilMaskSeparate(void *_glfuncs, GLenum face, GLuint mask)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glStencilMaskSeparate(face, mask);
+}
+
+void gles2_glStencilOpSeparate(void *_glfuncs, GLenum face, GLenum fail, GLenum zfail, GLenum zpass)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glStencilOpSeparate(face, fail, zfail, zpass);
+}
+
+void gles2_glUniform1f(void *_glfuncs, GLint location, GLfloat v0)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glUniform1f(location, v0);
+}
+
+void gles2_glUniform1fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glUniform1fv(location, count, value);
+}
+
+void gles2_glUniform1i(void *_glfuncs, GLint location, GLint v0)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glUniform1i(location, v0);
+}
+
+void gles2_glUniform1iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glUniform1iv(location, count, value);
+}
+
+void gles2_glUniform2f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glUniform2f(location, v0, v1);
+}
+
+void gles2_glUniform2fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glUniform2fv(location, count, value);
+}
+
+void gles2_glUniform2i(void *_glfuncs, GLint location, GLint v0, GLint v1)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glUniform2i(location, v0, v1);
+}
+
+void gles2_glUniform2iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glUniform2iv(location, count, value);
+}
+
+void gles2_glUniform3f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glUniform3f(location, v0, v1, v2);
+}
+
+void gles2_glUniform3fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glUniform3fv(location, count, value);
+}
+
+void gles2_glUniform3i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glUniform3i(location, v0, v1, v2);
+}
+
+void gles2_glUniform3iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glUniform3iv(location, count, value);
+}
+
+void gles2_glUniform4f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glUniform4f(location, v0, v1, v2, v3);
+}
+
+void gles2_glUniform4fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glUniform4fv(location, count, value);
+}
+
+void gles2_glUniform4i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2, GLint v3)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glUniform4i(location, v0, v1, v2, v3);
+}
+
+void gles2_glUniform4iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glUniform4iv(location, count, value);
+}
+
+void gles2_glUniformMatrix2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glUniformMatrix2fv(location, count, transpose, value);
+}
+
+void gles2_glUniformMatrix3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glUniformMatrix3fv(location, count, transpose, value);
+}
+
+void gles2_glUniformMatrix4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glUniformMatrix4fv(location, count, transpose, value);
+}
+
+void gles2_glUseProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glUseProgram(program);
+}
+
+void gles2_glValidateProgram(void *_glfuncs, GLuint program)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glValidateProgram(program);
+}
+
+void gles2_glVertexAttrib1f(void *_glfuncs, GLuint index, GLfloat x)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glVertexAttrib1f(index, x);
+}
+
+void gles2_glVertexAttrib1fv(void *_glfuncs, GLuint index, const GLfloat* values)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glVertexAttrib1fv(index, values);
+}
+
+void gles2_glVertexAttrib2f(void *_glfuncs, GLuint index, GLfloat x, GLfloat y)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glVertexAttrib2f(index, x, y);
+}
+
+void gles2_glVertexAttrib2fv(void *_glfuncs, GLuint index, const GLfloat* values)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glVertexAttrib2fv(index, values);
+}
+
+void gles2_glVertexAttrib3f(void *_glfuncs, GLuint index, GLfloat x, GLfloat y, GLfloat z)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glVertexAttrib3f(index, x, y, z);
+}
+
+void gles2_glVertexAttrib3fv(void *_glfuncs, GLuint index, const GLfloat* values)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glVertexAttrib3fv(index, values);
+}
+
+void gles2_glVertexAttrib4f(void *_glfuncs, GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4f(index, x, y, z, w);
+}
+
+void gles2_glVertexAttrib4fv(void *_glfuncs, GLuint index, const GLfloat* values)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glVertexAttrib4fv(index, values);
+}
+
+void gles2_glVertexAttribPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLboolean normalized, GLsizei stride, const GLvoid* offset)
+{
+ QOpenGLFunctions* _qglfuncs = reinterpret_cast<QOpenGLFunctions*>(_glfuncs);
+ _qglfuncs->glVertexAttribPointer(index, size, gltype, normalized, stride, offset);
+}
+
+void gles2_glBindTexture(void *_glfuncs, GLenum target, GLuint texture)
+{
+ glBindTexture(target, texture);
+}
+
+void gles2_glBlendFunc(void *_glfuncs, GLenum sfactor, GLenum dfactor)
+{
+ glBlendFunc(sfactor, dfactor);
+}
+
+void gles2_glClear(void *_glfuncs, GLbitfield mask)
+{
+ glClear(mask);
+}
+
+void gles2_glClearColor(void *_glfuncs, GLclampf red, GLclampf green, GLclampf blue, GLclampf alpha)
+{
+ glClearColor(red, green, blue, alpha);
+}
+
+void gles2_glClearStencil(void *_glfuncs, GLint s)
+{
+ glClearStencil(s);
+}
+
+void gles2_glColorMask(void *_glfuncs, GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha)
+{
+ glColorMask(red, green, blue, alpha);
+}
+
+void gles2_glCopyTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border)
+{
+ glCopyTexImage2D(target, level, internalFormat, x, y, width, height, border);
+}
+
+void gles2_glCopyTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ glCopyTexSubImage2D(target, level, xoffset, yoffset, x, y, width, height);
+}
+
+void gles2_glCullFace(void *_glfuncs, GLenum mode)
+{
+ glCullFace(mode);
+}
+
+void gles2_glDeleteTextures(void *_glfuncs, GLsizei n, const GLuint* textures)
+{
+ glDeleteTextures(n, textures);
+}
+
+void gles2_glDepthFunc(void *_glfuncs, GLenum glfunc)
+{
+ glDepthFunc(glfunc);
+}
+
+void gles2_glDepthMask(void *_glfuncs, GLboolean flag)
+{
+ glDepthMask(flag);
+}
+
+void gles2_glDisable(void *_glfuncs, GLenum cap)
+{
+ glDisable(cap);
+}
+
+void gles2_glDrawArrays(void *_glfuncs, GLenum mode, GLint first, GLsizei count)
+{
+ glDrawArrays(mode, first, count);
+}
+
+void gles2_glDrawElements(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices)
+{
+ glDrawElements(mode, count, gltype, indices);
+}
+
+void gles2_glEnable(void *_glfuncs, GLenum cap)
+{
+ glEnable(cap);
+}
+
+void gles2_glFinish(void *_glfuncs)
+{
+ glFinish();
+}
+
+void gles2_glFlush(void *_glfuncs)
+{
+ glFlush();
+}
+
+void gles2_glFrontFace(void *_glfuncs, GLenum mode)
+{
+ glFrontFace(mode);
+}
+
+void gles2_glGenTextures(void *_glfuncs, GLsizei n, GLuint* textures)
+{
+ glGenTextures(n, textures);
+}
+
+void gles2_glGetBooleanv(void *_glfuncs, GLenum pname, GLboolean* params)
+{
+ glGetBooleanv(pname, params);
+}
+
+GLenum gles2_glGetError(void *_glfuncs)
+{
+ return glGetError();
+}
+
+void gles2_glGetFloatv(void *_glfuncs, GLenum pname, GLfloat* params)
+{
+ glGetFloatv(pname, params);
+}
+
+void gles2_glGetIntegerv(void *_glfuncs, GLenum pname, GLint* params)
+{
+ glGetIntegerv(pname, params);
+}
+
+void gles2_glGetTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params)
+{
+ glGetTexParameterfv(target, pname, params);
+}
+
+void gles2_glGetTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params)
+{
+ glGetTexParameteriv(target, pname, params);
+}
+
+void gles2_glHint(void *_glfuncs, GLenum target, GLenum mode)
+{
+ glHint(target, mode);
+}
+
+GLboolean gles2_glIsEnabled(void *_glfuncs, GLenum cap)
+{
+ return glIsEnabled(cap);
+}
+
+GLboolean gles2_glIsTexture(void *_glfuncs, GLuint texture)
+{
+ return glIsTexture(texture);
+}
+
+void gles2_glLineWidth(void *_glfuncs, GLfloat width)
+{
+ glLineWidth(width);
+}
+
+void gles2_glPixelStorei(void *_glfuncs, GLenum pname, GLint param)
+{
+ glPixelStorei(pname, param);
+}
+
+void gles2_glPolygonOffset(void *_glfuncs, GLfloat factor, GLfloat units)
+{
+ glPolygonOffset(factor, units);
+}
+
+void gles2_glReadPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum gltype, GLvoid* pixels)
+{
+ glReadPixels(x, y, width, height, format, gltype, pixels);
+}
+
+void gles2_glScissor(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ glScissor(x, y, width, height);
+}
+
+void gles2_glStencilFunc(void *_glfuncs, GLenum glfunc, GLint ref, GLuint mask)
+{
+ glStencilFunc(glfunc, ref, mask);
+}
+
+void gles2_glStencilMask(void *_glfuncs, GLuint mask)
+{
+ glStencilMask(mask);
+}
+
+void gles2_glStencilOp(void *_glfuncs, GLenum fail, GLenum zfail, GLenum zpass)
+{
+ glStencilOp(fail, zfail, zpass);
+}
+
+void gles2_glTexImage2D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ glTexImage2D(target, level, internalFormat, width, height, border, format, gltype, pixels);
+}
+
+void gles2_glTexParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param)
+{
+ glTexParameterf(target, pname, param);
+}
+
+void gles2_glTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params)
+{
+ glTexParameterfv(target, pname, params);
+}
+
+void gles2_glTexParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint param)
+{
+ glTexParameteri(target, pname, param);
+}
+
+void gles2_glTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params)
+{
+ glTexParameteriv(target, pname, params);
+}
+
+void gles2_glTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels)
+{
+ glTexSubImage2D(target, level, xoffset, yoffset, width, height, format, gltype, pixels);
+}
+
+void gles2_glViewport(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height)
+{
+ glViewport(x, y, width, height);
+}
+
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/es2/funcs.h b/Godeps/_workspace/src/github.com/obscuren/qml/gl/es2/funcs.h
new file mode 100644
index 000000000..7e9fd3534
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/es2/funcs.h
@@ -0,0 +1,182 @@
+
+// ** file automatically generated by glgen -- do not edit manually **
+
+#ifndef __cplusplus
+#include <inttypes.h>
+#include <stddef.h>
+typedef unsigned int GLenum;
+typedef unsigned char GLboolean;
+typedef unsigned int GLbitfield;
+typedef void GLvoid;
+typedef char GLchar;
+typedef signed char GLbyte; /* 1-byte signed */
+typedef short GLshort; /* 2-byte signed */
+typedef int GLint; /* 4-byte signed */
+typedef unsigned char GLubyte; /* 1-byte unsigned */
+typedef unsigned short GLushort; /* 2-byte unsigned */
+typedef unsigned int GLuint; /* 4-byte unsigned */
+typedef int GLsizei; /* 4-byte signed */
+typedef float GLfloat; /* single precision float */
+typedef float GLclampf; /* single precision float in [0,1] */
+typedef double GLdouble; /* double precision float */
+typedef double GLclampd; /* double precision float in [0,1] */
+typedef int64_t GLint64;
+typedef uint64_t GLuint64;
+typedef ptrdiff_t GLintptr;
+typedef ptrdiff_t GLsizeiptr;
+typedef ptrdiff_t GLintptrARB;
+typedef ptrdiff_t GLsizeiptrARB;
+typedef struct __GLsync *GLsync;
+#endif
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+void *gles2_funcs();
+
+void gles2_glActiveTexture(void *_glfuncs, GLenum texture);
+void gles2_glAttachShader(void *_glfuncs, GLuint program, GLuint shader);
+void gles2_glBindAttribLocation(void *_glfuncs, GLuint program, GLuint index, const GLchar* name);
+void gles2_glBindBuffer(void *_glfuncs, GLenum target, GLuint buffer);
+void gles2_glBindFramebuffer(void *_glfuncs, GLenum target, GLuint framebuffer);
+void gles2_glBindRenderbuffer(void *_glfuncs, GLenum target, GLuint renderbuffer);
+void gles2_glBlendColor(void *_glfuncs, GLclampf red, GLclampf green, GLclampf blue, GLclampf alpha);
+void gles2_glBlendEquation(void *_glfuncs, GLenum mode);
+void gles2_glBlendEquationSeparate(void *_glfuncs, GLenum modeRGB, GLenum modeAlpha);
+void gles2_glBlendFuncSeparate(void *_glfuncs, GLenum srcRGB, GLenum dstRGB, GLenum srcAlpha, GLenum dstAlpha);
+void gles2_glBufferData(void *_glfuncs, GLenum target, GLsizeiptr size, const GLvoid* data, GLenum usage);
+void gles2_glBufferSubData(void *_glfuncs, GLenum target, GLintptr offset, GLsizeiptr size, const GLvoid* data);
+GLenum gles2_glCheckFramebufferStatus(void *_glfuncs, GLenum target);
+void gles2_glClearDepthf(void *_glfuncs, GLclampf depth);
+void gles2_glCompileShader(void *_glfuncs, GLuint shader);
+void gles2_glCompressedTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLsizei width, GLsizei height, GLint border, GLsizei imageSize, const GLvoid* data);
+void gles2_glCompressedTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLsizei imageSize, const GLvoid* data);
+GLuint gles2_glCreateProgram(void *_glfuncs);
+GLuint gles2_glCreateShader(void *_glfuncs, GLenum gltype);
+void gles2_glDeleteBuffers(void *_glfuncs, GLsizei n, const GLuint* buffers);
+void gles2_glDeleteFramebuffers(void *_glfuncs, GLsizei n, const GLuint* framebuffers);
+void gles2_glDeleteProgram(void *_glfuncs, GLuint program);
+void gles2_glDeleteRenderbuffers(void *_glfuncs, GLsizei n, const GLuint* renderbuffers);
+void gles2_glDeleteShader(void *_glfuncs, GLuint shader);
+void gles2_glDepthRangef(void *_glfuncs, GLclampf zNear, GLclampf zFar);
+void gles2_glDetachShader(void *_glfuncs, GLuint program, GLuint shader);
+void gles2_glDisableVertexAttribArray(void *_glfuncs, GLuint index);
+void gles2_glEnableVertexAttribArray(void *_glfuncs, GLuint index);
+void gles2_glFramebufferRenderbuffer(void *_glfuncs, GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer);
+void gles2_glFramebufferTexture2D(void *_glfuncs, GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level);
+void gles2_glGenBuffers(void *_glfuncs, GLsizei n, GLuint* buffers);
+void gles2_glGenerateMipmap(void *_glfuncs, GLenum target);
+void gles2_glGenFramebuffers(void *_glfuncs, GLsizei n, GLuint* framebuffers);
+void gles2_glGenRenderbuffers(void *_glfuncs, GLsizei n, GLuint* renderbuffers);
+void gles2_glGetActiveAttrib(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name);
+void gles2_glGetActiveUniform(void *_glfuncs, GLuint program, GLuint index, GLsizei bufSize, GLsizei* length, GLint* size, GLenum* gltype, GLchar* name);
+void gles2_glGetAttachedShaders(void *_glfuncs, GLuint program, GLsizei maxcount, GLsizei* count, GLuint* shaders);
+GLint gles2_glGetAttribLocation(void *_glfuncs, GLuint program, const GLchar* name);
+void gles2_glGetBufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gles2_glGetFramebufferAttachmentParameteriv(void *_glfuncs, GLenum target, GLenum attachment, GLenum pname, GLint* params);
+void gles2_glGetProgramiv(void *_glfuncs, GLuint program, GLenum pname, GLint* params);
+void gles2_glGetProgramInfoLog(void *_glfuncs, GLuint program, GLsizei bufSize, GLsizei* length, GLchar* infoLog);
+void gles2_glGetRenderbufferParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gles2_glGetShaderiv(void *_glfuncs, GLuint shader, GLenum pname, GLint* params);
+void gles2_glGetShaderInfoLog(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* infoLog);
+void gles2_glGetShaderPrecisionFormat(void *_glfuncs, GLenum shadertype, GLenum precisionType, GLint* range_, GLint* precision);
+void gles2_glGetShaderSource(void *_glfuncs, GLuint shader, GLsizei bufSize, GLsizei* length, GLchar* source);
+void gles2_glGetUniformfv(void *_glfuncs, GLuint program, GLint location, GLfloat* params);
+void gles2_glGetUniformiv(void *_glfuncs, GLuint program, GLint location, GLint* params);
+GLint gles2_glGetUniformLocation(void *_glfuncs, GLuint program, const GLchar* name);
+void gles2_glGetVertexAttribfv(void *_glfuncs, GLuint index, GLenum pname, GLfloat* params);
+void gles2_glGetVertexAttribiv(void *_glfuncs, GLuint index, GLenum pname, GLint* params);
+GLboolean gles2_glIsBuffer(void *_glfuncs, GLuint buffer);
+GLboolean gles2_glIsFramebuffer(void *_glfuncs, GLuint framebuffer);
+GLboolean gles2_glIsProgram(void *_glfuncs, GLuint program);
+GLboolean gles2_glIsRenderbuffer(void *_glfuncs, GLuint renderbuffer);
+GLboolean gles2_glIsShader(void *_glfuncs, GLuint shader);
+void gles2_glLinkProgram(void *_glfuncs, GLuint program);
+void gles2_glReleaseShaderCompiler(void *_glfuncs);
+void gles2_glRenderbufferStorage(void *_glfuncs, GLenum target, GLenum internalFormat, GLsizei width, GLsizei height);
+void gles2_glSampleCoverage(void *_glfuncs, GLclampf value, GLboolean invert);
+void gles2_glShaderBinary(void *_glfuncs, GLint n, const GLuint* shaders, GLenum binaryFormat, const GLvoid* binary, GLint length);
+void gles2_glShaderSource(void *_glfuncs, GLuint shader, GLsizei count, const GLchar** source, const GLint* length);
+void gles2_glStencilFuncSeparate(void *_glfuncs, GLenum face, GLenum glfunc, GLint ref, GLuint mask);
+void gles2_glStencilMaskSeparate(void *_glfuncs, GLenum face, GLuint mask);
+void gles2_glStencilOpSeparate(void *_glfuncs, GLenum face, GLenum fail, GLenum zfail, GLenum zpass);
+void gles2_glUniform1f(void *_glfuncs, GLint location, GLfloat v0);
+void gles2_glUniform1fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gles2_glUniform1i(void *_glfuncs, GLint location, GLint v0);
+void gles2_glUniform1iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gles2_glUniform2f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1);
+void gles2_glUniform2fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gles2_glUniform2i(void *_glfuncs, GLint location, GLint v0, GLint v1);
+void gles2_glUniform2iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gles2_glUniform3f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2);
+void gles2_glUniform3fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gles2_glUniform3i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2);
+void gles2_glUniform3iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gles2_glUniform4f(void *_glfuncs, GLint location, GLfloat v0, GLfloat v1, GLfloat v2, GLfloat v3);
+void gles2_glUniform4fv(void *_glfuncs, GLint location, GLsizei count, const GLfloat* value);
+void gles2_glUniform4i(void *_glfuncs, GLint location, GLint v0, GLint v1, GLint v2, GLint v3);
+void gles2_glUniform4iv(void *_glfuncs, GLint location, GLsizei count, const GLint* value);
+void gles2_glUniformMatrix2fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gles2_glUniformMatrix3fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gles2_glUniformMatrix4fv(void *_glfuncs, GLint location, GLsizei count, GLboolean transpose, const GLfloat* value);
+void gles2_glUseProgram(void *_glfuncs, GLuint program);
+void gles2_glValidateProgram(void *_glfuncs, GLuint program);
+void gles2_glVertexAttrib1f(void *_glfuncs, GLuint index, GLfloat x);
+void gles2_glVertexAttrib1fv(void *_glfuncs, GLuint index, const GLfloat* values);
+void gles2_glVertexAttrib2f(void *_glfuncs, GLuint index, GLfloat x, GLfloat y);
+void gles2_glVertexAttrib2fv(void *_glfuncs, GLuint index, const GLfloat* values);
+void gles2_glVertexAttrib3f(void *_glfuncs, GLuint index, GLfloat x, GLfloat y, GLfloat z);
+void gles2_glVertexAttrib3fv(void *_glfuncs, GLuint index, const GLfloat* values);
+void gles2_glVertexAttrib4f(void *_glfuncs, GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+void gles2_glVertexAttrib4fv(void *_glfuncs, GLuint index, const GLfloat* values);
+void gles2_glVertexAttribPointer(void *_glfuncs, GLuint index, GLint size, GLenum gltype, GLboolean normalized, GLsizei stride, const GLvoid* offset);
+void gles2_glBindTexture(void *_glfuncs, GLenum target, GLuint texture);
+void gles2_glBlendFunc(void *_glfuncs, GLenum sfactor, GLenum dfactor);
+void gles2_glClear(void *_glfuncs, GLbitfield mask);
+void gles2_glClearColor(void *_glfuncs, GLclampf red, GLclampf green, GLclampf blue, GLclampf alpha);
+void gles2_glClearStencil(void *_glfuncs, GLint s);
+void gles2_glColorMask(void *_glfuncs, GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha);
+void gles2_glCopyTexImage2D(void *_glfuncs, GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border);
+void gles2_glCopyTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+void gles2_glCullFace(void *_glfuncs, GLenum mode);
+void gles2_glDeleteTextures(void *_glfuncs, GLsizei n, const GLuint* textures);
+void gles2_glDepthFunc(void *_glfuncs, GLenum glfunc);
+void gles2_glDepthMask(void *_glfuncs, GLboolean flag);
+void gles2_glDisable(void *_glfuncs, GLenum cap);
+void gles2_glDrawArrays(void *_glfuncs, GLenum mode, GLint first, GLsizei count);
+void gles2_glDrawElements(void *_glfuncs, GLenum mode, GLsizei count, GLenum gltype, const GLvoid* indices);
+void gles2_glEnable(void *_glfuncs, GLenum cap);
+void gles2_glFinish(void *_glfuncs);
+void gles2_glFlush(void *_glfuncs);
+void gles2_glFrontFace(void *_glfuncs, GLenum mode);
+void gles2_glGenTextures(void *_glfuncs, GLsizei n, GLuint* textures);
+void gles2_glGetBooleanv(void *_glfuncs, GLenum pname, GLboolean* params);
+GLenum gles2_glGetError(void *_glfuncs);
+void gles2_glGetFloatv(void *_glfuncs, GLenum pname, GLfloat* params);
+void gles2_glGetIntegerv(void *_glfuncs, GLenum pname, GLint* params);
+void gles2_glGetTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, GLfloat* params);
+void gles2_glGetTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, GLint* params);
+void gles2_glHint(void *_glfuncs, GLenum target, GLenum mode);
+GLboolean gles2_glIsEnabled(void *_glfuncs, GLenum cap);
+GLboolean gles2_glIsTexture(void *_glfuncs, GLuint texture);
+void gles2_glLineWidth(void *_glfuncs, GLfloat width);
+void gles2_glPixelStorei(void *_glfuncs, GLenum pname, GLint param);
+void gles2_glPolygonOffset(void *_glfuncs, GLfloat factor, GLfloat units);
+void gles2_glReadPixels(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum gltype, GLvoid* pixels);
+void gles2_glScissor(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height);
+void gles2_glStencilFunc(void *_glfuncs, GLenum glfunc, GLint ref, GLuint mask);
+void gles2_glStencilMask(void *_glfuncs, GLuint mask);
+void gles2_glStencilOp(void *_glfuncs, GLenum fail, GLenum zfail, GLenum zpass);
+void gles2_glTexImage2D(void *_glfuncs, GLenum target, GLint level, GLint internalFormat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gles2_glTexParameterf(void *_glfuncs, GLenum target, GLenum pname, GLfloat param);
+void gles2_glTexParameterfv(void *_glfuncs, GLenum target, GLenum pname, const GLfloat* params);
+void gles2_glTexParameteri(void *_glfuncs, GLenum target, GLenum pname, GLint param);
+void gles2_glTexParameteriv(void *_glfuncs, GLenum target, GLenum pname, const GLint* params);
+void gles2_glTexSubImage2D(void *_glfuncs, GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum gltype, const GLvoid* pixels);
+void gles2_glViewport(void *_glfuncs, GLint x, GLint y, GLsizei width, GLsizei height);
+
+
+#ifdef __cplusplus
+} // extern "C"
+#endif
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/es2/gl.go b/Godeps/_workspace/src/github.com/obscuren/qml/gl/es2/gl.go
new file mode 100644
index 000000000..82c9d77cf
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/es2/gl.go
@@ -0,0 +1,2990 @@
+// ** file automatically generated by glgen -- do not edit manually **
+
+package GL
+
+// #cgo CXXFLAGS: -std=c++0x -pedantic-errors -Wall -fno-strict-aliasing
+// #cgo LDFLAGS: -lstdc++
+// #cgo !darwin LDFLAGS: -lGL
+// #cgo darwin LDFLAGS: -framework OpenGL
+// #cgo pkg-config: Qt5Core Qt5OpenGL
+//
+// #include "funcs.h"
+//
+// void free(void*);
+//
+import "C"
+
+import (
+ "fmt"
+ "reflect"
+ "unsafe"
+
+ "gopkg.in/qml.v1/gl/glbase"
+)
+
+// API returns a value that offers methods matching the OpenGL version ES2 API.
+//
+// The returned API must not be used after the provided OpenGL context becomes invalid.
+func API(context glbase.Contexter) *GL {
+ gl := &GL{}
+ gl.funcs = C.gles2_funcs()
+ if gl.funcs == nil {
+ panic(fmt.Errorf("OpenGL version ES2 is not available"))
+ }
+ return gl
+}
+
+// GL implements the OpenGL version ES2 API. Values of this
+// type must be created via the API function, and it must not be used after
+// the associated OpenGL context becomes invalid.
+type GL struct {
+ funcs unsafe.Pointer
+}
+
+const (
+ FALSE = 0
+ TRUE = 1
+ NONE = 0
+
+ BYTE = 0x1400
+ UNSIGNED_BYTE = 0x1401
+ SHORT = 0x1402
+ UNSIGNED_SHORT = 0x1403
+ INT = 0x1404
+ UNSIGNED_INT = 0x1405
+ FLOAT = 0x1406
+ FIXED = 0x140C
+
+ COLOR_BUFFER_BIT = 0x00004000
+ DEPTH_BUFFER_BIT = 0x00000100
+ STENCIL_BUFFER_BIT = 0x00000400
+
+ ALWAYS = 0x0207
+ EQUAL = 0x0202
+ GEQUAL = 0x0206
+ GREATER = 0x0204
+ LEQUAL = 0x0203
+ LESS = 0x0201
+ NEVER = 0x0200
+ NOTEQUAL = 0x0205
+
+ DST_ALPHA = 0x0304
+ ONE = 1
+ ONE_MINUS_DST_ALPHA = 0x0305
+ ONE_MINUS_SRC_ALPHA = 0x0303
+ ONE_MINUS_SRC_COLOR = 0x0301
+ SRC_ALPHA = 0x0302
+ SRC_COLOR = 0x0300
+ ZERO = 0
+
+ DST_COLOR = 0x0306
+ ONE_MINUS_DST_COLOR = 0x0307
+ SRC_ALPHA_SATURATE = 0x0308
+
+ BACK = 0x0405
+ FRONT = 0x0404
+ FRONT_AND_BACK = 0x0408
+
+ BLEND = 0x0BE2
+ CULL_FACE = 0x0B44
+ DEPTH_TEST = 0x0B71
+ DITHER = 0x0BD0
+ POLYGON_OFFSET_FILL = 0x8037
+ SCISSOR_TEST = 0x0C11
+ STENCIL_TEST = 0x0B90
+ TEXTURE_2D = 0x0DE1
+
+ INVALID_ENUM = 0x0500
+ INVALID_FRAMEBUFFER_OPERATION = 0x0506
+ INVALID_OPERATION = 0x0502
+ INVALID_VALUE = 0x0501
+ NO_ERROR = 0
+ OUT_OF_MEMORY = 0x0505
+
+ LINEAR = 0x2601
+
+ CCW = 0x0901
+ CW = 0x0900
+
+ ALIASED_LINE_WIDTH_RANGE = 0x846E
+ ALIASED_POINT_SIZE_RANGE = 0x846D
+ ALPHA_BITS = 0x0D55
+ BLUE_BITS = 0x0D54
+ COLOR_CLEAR_VALUE = 0x0C22
+ COLOR_WRITEMASK = 0x0C23
+ CULL_FACE_MODE = 0x0B45
+ DEPTH_BITS = 0x0D56
+ DEPTH_CLEAR_VALUE = 0x0B73
+ DEPTH_FUNC = 0x0B74
+ DEPTH_RANGE = 0x0B70
+ DEPTH_WRITEMASK = 0x0B72
+ FRONT_FACE = 0x0B46
+ GREEN_BITS = 0x0D53
+ LINE_WIDTH = 0x0B21
+ MAX_TEXTURE_SIZE = 0x0D33
+ MAX_VIEWPORT_DIMS = 0x0D3A
+ PACK_ALIGNMENT = 0x0D05
+ POLYGON_OFFSET_FACTOR = 0x8038
+ POLYGON_OFFSET_UNITS = 0x2A00
+ RED_BITS = 0x0D52
+ SCISSOR_BOX = 0x0C10
+ STENCIL_BITS = 0x0D57
+ STENCIL_CLEAR_VALUE = 0x0B91
+ STENCIL_FAIL = 0x0B94
+ STENCIL_FUNC = 0x0B92
+ STENCIL_PASS_DEPTH_FAIL = 0x0B95
+ STENCIL_PASS_DEPTH_PASS = 0x0B96
+ STENCIL_REF = 0x0B97
+ STENCIL_VALUE_MASK = 0x0B93
+ STENCIL_WRITEMASK = 0x0B98
+ SUBPIXEL_BITS = 0x0D50
+ TEXTURE_BINDING_2D = 0x8069
+ UNPACK_ALIGNMENT = 0x0CF5
+ VIEWPORT = 0x0BA2
+
+ TEXTURE_MAG_FILTER = 0x2800
+ TEXTURE_MIN_FILTER = 0x2801
+ TEXTURE_WRAP_S = 0x2802
+ TEXTURE_WRAP_T = 0x2803
+
+ DONT_CARE = 0x1100
+ FASTEST = 0x1101
+ NICEST = 0x1102
+
+ GENERATE_MIPMAP_HINT = 0x8192
+
+ REPLACE = 0x1E01
+
+ INVERT = 0x150A
+
+ TEXTURE = 0x1702
+
+ ALPHA = 0x1906
+ DEPTH_COMPONENT = 0x1902
+ LUMINANCE = 0x1909
+ LUMINANCE_ALPHA = 0x190A
+ RGB = 0x1907
+ RGBA = 0x1908
+
+ RGB5_A1 = 0x8057
+ RGBA4 = 0x8056
+
+ UNSIGNED_SHORT_4_4_4_4 = 0x8033
+ UNSIGNED_SHORT_5_5_5_1 = 0x8034
+
+ LINES = 0x0001
+ LINE_LOOP = 0x0002
+ LINE_STRIP = 0x0003
+ POINTS = 0x0000
+ TRIANGLES = 0x0004
+ TRIANGLE_FAN = 0x0006
+ TRIANGLE_STRIP = 0x0005
+
+ DECR = 0x1E03
+ INCR = 0x1E02
+ KEEP = 0x1E00
+
+ EXTENSIONS = 0x1F03
+ RENDERER = 0x1F01
+ VENDOR = 0x1F00
+ VERSION = 0x1F02
+
+ NEAREST = 0x2600
+
+ LINEAR_MIPMAP_LINEAR = 0x2703
+ LINEAR_MIPMAP_NEAREST = 0x2701
+ NEAREST_MIPMAP_LINEAR = 0x2702
+ NEAREST_MIPMAP_NEAREST = 0x2700
+
+ CLAMP_TO_EDGE = 0x812F
+ REPEAT = 0x2901
+
+ CONSTANT_COLOR = 0x8001
+ ONE_MINUS_CONSTANT_COLOR = 0x8002
+ CONSTANT_ALPHA = 0x8003
+ ONE_MINUS_CONSTANT_ALPHA = 0x8004
+ BLEND_COLOR = 0x8005
+ FUNC_ADD = 0x8006
+ BLEND_EQUATION = 0x8009
+ BLEND_EQUATION_RGB = 0x8009
+ FUNC_SUBTRACT = 0x800A
+ FUNC_REVERSE_SUBTRACT = 0x800B
+ SAMPLE_ALPHA_TO_COVERAGE = 0x809E
+ SAMPLE_COVERAGE = 0x80A0
+ SAMPLE_BUFFERS = 0x80A8
+ SAMPLES = 0x80A9
+ SAMPLE_COVERAGE_VALUE = 0x80AA
+ SAMPLE_COVERAGE_INVERT = 0x80AB
+ BLEND_DST_RGB = 0x80C8
+ BLEND_SRC_RGB = 0x80C9
+ BLEND_DST_ALPHA = 0x80CA
+ BLEND_SRC_ALPHA = 0x80CB
+ DEPTH_COMPONENT16 = 0x81A5
+ UNSIGNED_SHORT_5_6_5 = 0x8363
+ MIRRORED_REPEAT = 0x8370
+ TEXTURE0 = 0x84C0
+ TEXTURE1 = 0x84C1
+ TEXTURE2 = 0x84C2
+ TEXTURE3 = 0x84C3
+ TEXTURE4 = 0x84C4
+ TEXTURE5 = 0x84C5
+ TEXTURE6 = 0x84C6
+ TEXTURE7 = 0x84C7
+ TEXTURE8 = 0x84C8
+ TEXTURE9 = 0x84C9
+ TEXTURE10 = 0x84CA
+ TEXTURE11 = 0x84CB
+ TEXTURE12 = 0x84CC
+ TEXTURE13 = 0x84CD
+ TEXTURE14 = 0x84CE
+ TEXTURE15 = 0x84CF
+ TEXTURE16 = 0x84D0
+ TEXTURE17 = 0x84D1
+ TEXTURE18 = 0x84D2
+ TEXTURE19 = 0x84D3
+ TEXTURE20 = 0x84D4
+ TEXTURE21 = 0x84D5
+ TEXTURE22 = 0x84D6
+ TEXTURE23 = 0x84D7
+ TEXTURE24 = 0x84D8
+ TEXTURE25 = 0x84D9
+ TEXTURE26 = 0x84DA
+ TEXTURE27 = 0x84DB
+ TEXTURE28 = 0x84DC
+ TEXTURE29 = 0x84DD
+ TEXTURE30 = 0x84DE
+ TEXTURE31 = 0x84DF
+ ACTIVE_TEXTURE = 0x84E0
+ MAX_RENDERBUFFER_SIZE = 0x84E8
+ INCR_WRAP = 0x8507
+ DECR_WRAP = 0x8508
+ TEXTURE_CUBE_MAP = 0x8513
+ TEXTURE_BINDING_CUBE_MAP = 0x8514
+ TEXTURE_CUBE_MAP_POSITIVE_X = 0x8515
+ TEXTURE_CUBE_MAP_NEGATIVE_X = 0x8516
+ TEXTURE_CUBE_MAP_POSITIVE_Y = 0x8517
+ TEXTURE_CUBE_MAP_NEGATIVE_Y = 0x8518
+ TEXTURE_CUBE_MAP_POSITIVE_Z = 0x8519
+ TEXTURE_CUBE_MAP_NEGATIVE_Z = 0x851A
+ MAX_CUBE_MAP_TEXTURE_SIZE = 0x851C
+ VERTEX_ATTRIB_ARRAY_ENABLED = 0x8622
+ VERTEX_ATTRIB_ARRAY_SIZE = 0x8623
+ VERTEX_ATTRIB_ARRAY_STRIDE = 0x8624
+ VERTEX_ATTRIB_ARRAY_TYPE = 0x8625
+ CURRENT_VERTEX_ATTRIB = 0x8626
+ VERTEX_ATTRIB_ARRAY_POINTER = 0x8645
+ NUM_COMPRESSED_TEXTURE_FORMATS = 0x86A2
+ COMPRESSED_TEXTURE_FORMATS = 0x86A3
+ BUFFER_SIZE = 0x8764
+ BUFFER_USAGE = 0x8765
+ STENCIL_BACK_FUNC = 0x8800
+ STENCIL_BACK_FAIL = 0x8801
+ STENCIL_BACK_PASS_DEPTH_FAIL = 0x8802
+ STENCIL_BACK_PASS_DEPTH_PASS = 0x8803
+ BLEND_EQUATION_ALPHA = 0x883D
+ MAX_VERTEX_ATTRIBS = 0x8869
+ VERTEX_ATTRIB_ARRAY_NORMALIZED = 0x886A
+ MAX_TEXTURE_IMAGE_UNITS = 0x8872
+ ARRAY_BUFFER = 0x8892
+ ELEMENT_ARRAY_BUFFER = 0x8893
+ ARRAY_BUFFER_BINDING = 0x8894
+ ELEMENT_ARRAY_BUFFER_BINDING = 0x8895
+ VERTEX_ATTRIB_ARRAY_BUFFER_BINDING = 0x889F
+ STREAM_DRAW = 0x88E0
+ STATIC_DRAW = 0x88E4
+ DYNAMIC_DRAW = 0x88E8
+ FRAGMENT_SHADER = 0x8B30
+ VERTEX_SHADER = 0x8B31
+ MAX_VERTEX_TEXTURE_IMAGE_UNITS = 0x8B4C
+ MAX_COMBINED_TEXTURE_IMAGE_UNITS = 0x8B4D
+ SHADER_TYPE = 0x8B4F
+ FLOAT_VEC2 = 0x8B50
+ FLOAT_VEC3 = 0x8B51
+ FLOAT_VEC4 = 0x8B52
+ INT_VEC2 = 0x8B53
+ INT_VEC3 = 0x8B54
+ INT_VEC4 = 0x8B55
+ BOOL = 0x8B56
+ BOOL_VEC2 = 0x8B57
+ BOOL_VEC3 = 0x8B58
+ BOOL_VEC4 = 0x8B59
+ FLOAT_MAT2 = 0x8B5A
+ FLOAT_MAT3 = 0x8B5B
+ FLOAT_MAT4 = 0x8B5C
+ SAMPLER_2D = 0x8B5E
+ SAMPLER_CUBE = 0x8B60
+ DELETE_STATUS = 0x8B80
+ COMPILE_STATUS = 0x8B81
+ LINK_STATUS = 0x8B82
+ VALIDATE_STATUS = 0x8B83
+ INFO_LOG_LENGTH = 0x8B84
+ ATTACHED_SHADERS = 0x8B85
+ ACTIVE_UNIFORMS = 0x8B86
+ ACTIVE_UNIFORM_MAX_LENGTH = 0x8B87
+ SHADER_SOURCE_LENGTH = 0x8B88
+ ACTIVE_ATTRIBUTES = 0x8B89
+ ACTIVE_ATTRIBUTE_MAX_LENGTH = 0x8B8A
+ SHADING_LANGUAGE_VERSION = 0x8B8C
+ CURRENT_PROGRAM = 0x8B8D
+ IMPLEMENTATION_COLOR_READ_TYPE = 0x8B9A
+ IMPLEMENTATION_COLOR_READ_FORMAT = 0x8B9B
+ STENCIL_BACK_REF = 0x8CA3
+ STENCIL_BACK_VALUE_MASK = 0x8CA4
+ STENCIL_BACK_WRITEMASK = 0x8CA5
+ FRAMEBUFFER_BINDING = 0x8CA6
+ RENDERBUFFER_BINDING = 0x8CA7
+ FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE = 0x8CD0
+ FRAMEBUFFER_ATTACHMENT_OBJECT_NAME = 0x8CD1
+ FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL = 0x8CD2
+ FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE = 0x8CD3
+ FRAMEBUFFER_COMPLETE = 0x8CD5
+ FRAMEBUFFER_INCOMPLETE_ATTACHMENT = 0x8CD6
+ FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT = 0x8CD7
+ FRAMEBUFFER_INCOMPLETE_DIMENSIONS = 0x8CD9
+ FRAMEBUFFER_UNSUPPORTED = 0x8CDD
+ COLOR_ATTACHMENT0 = 0x8CE0
+ DEPTH_ATTACHMENT = 0x8D00
+ STENCIL_ATTACHMENT = 0x8D20
+ FRAMEBUFFER = 0x8D40
+ RENDERBUFFER = 0x8D41
+ RENDERBUFFER_WIDTH = 0x8D42
+ RENDERBUFFER_HEIGHT = 0x8D43
+ RENDERBUFFER_INTERNAL_FORMAT = 0x8D44
+ STENCIL_INDEX8 = 0x8D48
+ RENDERBUFFER_RED_SIZE = 0x8D50
+ RENDERBUFFER_GREEN_SIZE = 0x8D51
+ RENDERBUFFER_BLUE_SIZE = 0x8D52
+ RENDERBUFFER_ALPHA_SIZE = 0x8D53
+ RENDERBUFFER_DEPTH_SIZE = 0x8D54
+ RENDERBUFFER_STENCIL_SIZE = 0x8D55
+ RGB565 = 0x8D62
+ LOW_FLOAT = 0x8DF0
+ MEDIUM_FLOAT = 0x8DF1
+ HIGH_FLOAT = 0x8DF2
+ LOW_INT = 0x8DF3
+ MEDIUM_INT = 0x8DF4
+ HIGH_INT = 0x8DF5
+ SHADER_BINARY_FORMATS = 0x8DF8
+ NUM_SHADER_BINARY_FORMATS = 0x8DF9
+ SHADER_COMPILER = 0x8DFA
+ MAX_VERTEX_UNIFORM_VECTORS = 0x8DFB
+ MAX_VARYING_VECTORS = 0x8DFC
+ MAX_FRAGMENT_UNIFORM_VECTORS = 0x8DFD
+)
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glActiveTexture.xml
+func (gl *GL) ActiveTexture(texture glbase.Enum) {
+ C.gles2_glActiveTexture(gl.funcs, C.GLenum(texture))
+}
+
+// AttachShader attaches a shader object to a program object.
+//
+// In order to create an executable, there must be a way to specify the list
+// of things that will be linked together. Program objects provide this
+// mechanism. Shaders that are to be linked together in a program object must
+// first be attached to that program object. This indicates that shader will
+// be included in link operations that will be performed on program.
+//
+// All operations that can be performed on a shader object are valid whether
+// or not the shader object is attached to a program object. It is
+// permissible to attach a shader object to a program object before source
+// code has been loaded into the shader object or before the shader object
+// has been compiled. It is permissible to attach multiple shader objects of
+// the same type because each may contain a portion of the complete shader.
+// It is also permissible to attach a shader object to more than one program
+// object. If a shader object is deleted while it is attached to a program
+// object, it will be flagged for deletion, and deletion will not occur until
+// DetachShader is called to detach it from all program objects to which it
+// is attached.
+//
+// Error GL.INVALID_VALUE is generated if either program or shader is not a
+// value generated by OpenGL. GL.INVALID_OPERATION is generated if program
+// is not a program object. GL.INVALID_OPERATION is generated if shader is
+// not a shader object. GL.INVALID_OPERATION is generated if shader is
+// already attached to program. GL.INVALID_OPERATION is generated if
+// AttachShader is executed between the execution of Begin and the
+// corresponding execution of End.
+//
+// AttachShader is available in GL version 2.0 or greater.
+func (gl *GL) AttachShader(program glbase.Program, shader glbase.Shader) {
+ C.gles2_glAttachShader(gl.funcs, C.GLuint(program), C.GLuint(shader))
+}
+
+// BindAttribLocation associates a user-defined attribute variable in the program
+// object specified by program with a generic vertex attribute index. The name
+// parameter specifies the name of the vertex shader attribute variable to
+// which index is to be bound. When program is made part of the current state,
+// values provided via the generic vertex attribute index will modify the
+// value of the user-defined attribute variable specified by name.
+//
+// If name refers to a matrix attribute variable, index refers to the first
+// column of the matrix. Other matrix columns are then automatically bound to
+// locations index+1 for a matrix of type mat2; index+1 and index+2 for a
+// matrix of type mat3; and index+1, index+2, and index+3 for a matrix of
+// type mat4.
+//
+// This command makes it possible for vertex shaders to use descriptive names
+// for attribute variables rather than generic variables that are numbered
+// from 0 to GL.MAX_VERTEX_ATTRIBS-1. The values sent to each generic
+// attribute index are part of current state, just like standard vertex
+// attributes such as color, normal, and vertex position. If a different
+// program object is made current by calling UseProgram, the generic vertex
+// attributes are tracked in such a way that the same values will be observed
+// by attributes in the new program object that are also bound to index.
+//
+// Attribute variable name-to-generic attribute index bindings for a program
+// object can be explicitly assigned at any time by calling
+// BindAttribLocation. Attribute bindings do not go into effect until
+// LinkProgram is called. After a program object has been linked
+// successfully, the index values for generic attributes remain fixed (and
+// their values can be queried) until the next link command occurs.
+//
+// Applications are not allowed to bind any of the standard OpenGL vertex
+// attributes using this command, as they are bound automatically when
+// needed. Any attribute binding that occurs after the program object has
+// been linked will not take effect until the next time the program object is
+// linked.
+//
+// If name was bound previously, that information is lost. Thus you cannot
+// bind one user-defined attribute variable to multiple indices, but you can
+// bind multiple user-defined attribute variables to the same index.
+//
+// Applications are allowed to bind more than one user-defined attribute
+// variable to the same generic vertex attribute index. This is called
+// aliasing, and it is allowed only if just one of the aliased attributes is
+// active in the executable program, or if no path through the shader
+// consumes more than one attribute of a set of attributes aliased to the
+// same location. The compiler and linker are allowed to assume that no
+// aliasing is done and are free to employ optimizations that work only in
+// the absence of aliasing. OpenGL implementations are not required to do
+// error checking to detect aliasing. Because there is no way to bind
+// standard attributes, it is not possible to alias generic attributes with
+// conventional ones (except for generic attribute 0).
+//
+// BindAttribLocation can be called before any vertex shader objects are
+// bound to the specified program object. It is also permissible to bind a
+// generic attribute index to an attribute variable name that is never used
+// in a vertex shader.
+//
+// Active attributes that are not explicitly bound will be bound by the
+// linker when LinkProgram is called. The locations assigned can be queried
+// by calling GetAttribLocation.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS.
+// GL.INVALID_OPERATION is generated if name starts with the reserved prefix "gl_".
+// GL.INVALID_VALUE is generated if program is not a value generated by OpenGL.
+// GL.INVALID_OPERATION is generated if program is not a program object.
+// GL.INVALID_OPERATION is generated if BindAttribLocation is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// BindAttribLocation is available in GL version 2.0 or greater.
+func (gl *GL) BindAttribLocation(program glbase.Program, index glbase.Attrib, name string) {
+ name_cstr := C.CString(name)
+ C.gles2_glBindAttribLocation(gl.funcs, C.GLuint(program), C.GLuint(index), (*C.GLchar)(name_cstr))
+ C.free(unsafe.Pointer(name_cstr))
+}
+
+// BindBuffer creates or puts in use a named buffer object.
+// Calling BindBuffer with target set to GL.ARRAY_BUFFER,
+// GL.ELEMENT_ARRAY_BUFFER, GL.PIXEL_PACK_BUFFER or GL.PIXEL_UNPACK_BUFFER
+// and buffer set to the name of the new buffer object binds the buffer
+// object name to the target. When a buffer object is bound to a target, the
+// previous binding for that target is automatically broken.
+//
+// Buffer object names are unsigned integers. The value zero is reserved, but
+// there is no default buffer object for each buffer object target. Instead,
+// buffer set to zero effectively unbinds any buffer object previously bound,
+// and restores client memory usage for that buffer object target. Buffer
+// object names and the corresponding buffer object contents are local to the
+// shared display-list space (see XCreateContext) of the current GL rendering
+// context; two rendering contexts share buffer object names only if they
+// also share display lists.
+//
+// GenBuffers may be called to generate a set of new buffer object names.
+//
+// The state of a buffer object immediately after it is first bound is an
+// unmapped zero-sized memory buffer with GL.READ_WRITE access and
+// GL.STATIC_DRAW usage.
+//
+// While a non-zero buffer object name is bound, GL operations on the target
+// to which it is bound affect the bound buffer object, and queries of the
+// target to which it is bound return state from the bound buffer object.
+// While buffer object name zero is bound, as in the initial state, attempts
+// to modify or query state on the target to which it is bound generates an
+// GL.INVALID_OPERATION error.
+//
+// When vertex array pointer state is changed, for example by a call to
+// NormalPointer, the current buffer object binding (GL.ARRAY_BUFFER_BINDING)
+// is copied into the corresponding client state for the vertex array type
+// being changed, for example GL.NORMAL_ARRAY_BUFFER_BINDING. While a
+// non-zero buffer object is bound to the GL.ARRAY_BUFFER target, the vertex
+// array pointer parameter that is traditionally interpreted as a pointer to
+// client-side memory is instead interpreted as an offset within the buffer
+// object measured in basic machine units.
+//
+// While a non-zero buffer object is bound to the GL.ELEMENT_ARRAY_BUFFER
+// target, the indices parameter of DrawElements, DrawRangeElements, or
+// MultiDrawElements that is traditionally interpreted as a pointer to
+// client-side memory is instead interpreted as an offset within the buffer
+// object measured in basic machine units.
+//
+// While a non-zero buffer object is bound to the GL.PIXEL_PACK_BUFFER
+// target, the following commands are affected: GetCompressedTexImage,
+// GetConvolutionFilter, GetHistogram, GetMinmax, GetPixelMap,
+// GetPolygonStipple, GetSeparableFilter, GetTexImage, and ReadPixels. The
+// pointer parameter that is traditionally interpreted as a pointer to
+// client-side memory where the pixels are to be packed is instead
+// interpreted as an offset within the buffer object measured in basic
+// machine units.
+//
+// While a non-zero buffer object is bound to the GL.PIXEL_UNPACK_BUFFER
+// target, the following commands are affected: Bitmap, ColorSubTable,
+// ColorTable, CompressedTexImage1D, CompressedTexImage2D,
+// CompressedTexImage3D, CompressedTexSubImage1D, CompressedTexSubImage2D,
+// CompressedTexSubImage3D, ConvolutionFilter1D, ConvolutionFilter2D,
+// DrawPixels, PixelMap, PolygonStipple, SeparableFilter2D, TexImage1D,
+// TexImage2D, TexImage3D, TexSubImage1D, TexSubImage2D, and TexSubImage3D.
+// The pointer parameter that is traditionally interpreted as a pointer to
+// client-side memory from which the pixels are to be unpacked is instead
+// interpreted as an offset within the buffer object measured in basic
+// machine units.
+//
+// A buffer object binding created with BindBuffer remains active until a
+// different buffer object name is bound to the same target, or until the
+// bound buffer object is deleted with DeleteBuffers.
+//
+// Once created, a named buffer object may be re-bound to any target as often
+// as needed. However, the GL implementation may make choices about how to
+// optimize the storage of a buffer object based on its initial binding
+// target.
+//
+// Error GL.INVALID_ENUM is generated if target is not one of the allowable
+// values. GL.INVALID_OPERATION is generated if BindBuffer is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// BindBuffer is available in GL version 1.5 or greater.
+func (gl *GL) BindBuffer(target glbase.Enum, buffer glbase.Buffer) {
+ C.gles2_glBindBuffer(gl.funcs, C.GLenum(target), C.GLuint(buffer))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBindFramebuffer.xml
+func (gl *GL) BindFramebuffer(target glbase.Enum, framebuffer glbase.Framebuffer) {
+ C.gles2_glBindFramebuffer(gl.funcs, C.GLenum(target), C.GLuint(framebuffer))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBindRenderbuffer.xml
+func (gl *GL) BindRenderbuffer(target glbase.Enum, renderbuffer glbase.Renderbuffer) {
+ C.gles2_glBindRenderbuffer(gl.funcs, C.GLenum(target), C.GLuint(renderbuffer))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBlendColor.xml
+func (gl *GL) BlendColor(red, green, blue, alpha glbase.Clampf) {
+ C.gles2_glBlendColor(gl.funcs, C.GLclampf(red), C.GLclampf(green), C.GLclampf(blue), C.GLclampf(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBlendEquation.xml
+func (gl *GL) BlendEquation(mode glbase.Enum) {
+ C.gles2_glBlendEquation(gl.funcs, C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBlendEquationSeparate.xml
+func (gl *GL) BlendEquationSeparate(modeRGB, modeAlpha glbase.Enum) {
+ C.gles2_glBlendEquationSeparate(gl.funcs, C.GLenum(modeRGB), C.GLenum(modeAlpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBlendFuncSeparate.xml
+func (gl *GL) BlendFuncSeparate(srcRGB, dstRGB, srcAlpha, dstAlpha glbase.Enum) {
+ C.gles2_glBlendFuncSeparate(gl.funcs, C.GLenum(srcRGB), C.GLenum(dstRGB), C.GLenum(srcAlpha), C.GLenum(dstAlpha))
+}
+
+// BufferData creates a new data store for the buffer object currently
+// bound to target. Any pre-existing data store is deleted. The new data
+// store is created with the specified size in bytes and usage. If data is
+// not nil, it must be a slice that is used to initialize the data store.
+// In that case the size parameter is ignored and the store size will match
+// the slice data size.
+//
+// In its initial state, the new data store is not mapped, it has a NULL
+// mapped pointer, and its mapped access is GL.READ_WRITE.
+//
+// The target constant must be one of GL.ARRAY_BUFFER, GL.COPY_READ_BUFFER,
+// GL.COPY_WRITE_BUFFER, GL.ELEMENT_ARRAY_BUFFER, GL.PIXEL_PACK_BUFFER,
+// GL.PIXEL_UNPACK_BUFFER, GL.TEXTURE_BUFFER, GL.TRANSFORM_FEEDBACK_BUFFER,
+// or GL.UNIFORM_BUFFER.
+//
+// The usage parameter is a hint to the GL implementation as to how a buffer
+// object's data store will be accessed. This enables the GL implementation
+// to make more intelligent decisions that may significantly impact buffer
+// object performance. It does not, however, constrain the actual usage of
+// the data store. usage can be broken down into two parts: first, the
+// frequency of access (modification and usage), and second, the nature of
+// that access.
+//
+// A usage frequency of STREAM and nature of DRAW is specified via the
+// constant GL.STREAM_DRAW, for example.
+//
+// The usage frequency of access may be one of:
+//
+// STREAM
+// The data store contents will be modified once and used at most a few times.
+//
+// STATIC
+// The data store contents will be modified once and used many times.
+//
+// DYNAMIC
+// The data store contents will be modified repeatedly and used many times.
+//
+// The usage nature of access may be one of:
+//
+// DRAW
+// The data store contents are modified by the application, and used as
+// the source for GL drawing and image specification commands.
+//
+// READ
+// The data store contents are modified by reading data from the GL,
+// and used to return that data when queried by the application.
+//
+// COPY
+// The data store contents are modified by reading data from the GL,
+// and used as the source for GL drawing and image specification
+// commands.
+//
+// Clients must align data elements consistent with the requirements of the
+// client platform, with an additional base-level requirement that an offset
+// within a buffer to a datum comprising N bytes be a multiple of N.
+//
+// Error GL.INVALID_ENUM is generated if target is not one of the accepted
+// buffer targets. GL.INVALID_ENUM is generated if usage is not
+// GL.STREAM_DRAW, GL.STREAM_READ, GL.STREAM_COPY, GL.STATIC_DRAW,
+// GL.STATIC_READ, GL.STATIC_COPY, GL.DYNAMIC_DRAW, GL.DYNAMIC_READ, or
+// GL.DYNAMIC_COPY. GL.INVALID_VALUE is generated if size is negative.
+// GL.INVALID_OPERATION is generated if the reserved buffer object name 0 is
+// bound to target. GL.OUT_OF_MEMORY is generated if the GL is unable to
+// create a data store with the specified size.
+func (gl *GL) BufferData(target glbase.Enum, size int, data interface{}, usage glbase.Enum) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ if data != nil {
+ size = int(data_v.Type().Size()) * data_v.Len()
+ }
+ C.gles2_glBufferData(gl.funcs, C.GLenum(target), C.GLsizeiptr(size), data_ptr, C.GLenum(usage))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBufferSubData.xml
+func (gl *GL) BufferSubData(target glbase.Enum, offset, size int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gles2_glBufferSubData(gl.funcs, C.GLenum(target), C.GLintptr(offset), C.GLsizeiptr(size), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCheckFramebufferStatus.xml
+func (gl *GL) CheckFramebufferStatus(target glbase.Enum) glbase.Enum {
+ glresult := C.gles2_glCheckFramebufferStatus(gl.funcs, C.GLenum(target))
+ return glbase.Enum(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClearDepthf.xml
+func (gl *GL) ClearDepthf(depth glbase.Clampf) {
+ C.gles2_glClearDepthf(gl.funcs, C.GLclampf(depth))
+}
+
+// CompileShader compiles the source code strings that have been stored in
+// the shader object specified by shader.
+//
+// The compilation status will be stored as part of the shader object's
+// state. This value will be set to GL.TRUE if the shader was compiled without
+// errors and is ready for use, and GL.FALSE otherwise. It can be queried by
+// calling GetShaderiv with arguments shader and GL.COMPILE_STATUS.
+//
+// Compilation of a shader can fail for a number of reasons as specified by
+// the OpenGL Shading Language Specification. Whether or not the compilation
+// was successful, information about the compilation can be obtained from the
+// shader object's information log by calling GetShaderInfoLog.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader is not a shader
+// object. GL.INVALID_OPERATION is generated if CompileShader is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// CompileShader is available in GL version 2.0 or greater.
+func (gl *GL) CompileShader(shader glbase.Shader) {
+ C.gles2_glCompileShader(gl.funcs, C.GLuint(shader))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCompressedTexImage2D.xml
+func (gl *GL) CompressedTexImage2D(target glbase.Enum, level int, internalFormat glbase.Enum, width, height, border, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gles2_glCompressedTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLint(border), C.GLsizei(imageSize), data_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCompressedTexSubImage2D.xml
+func (gl *GL) CompressedTexSubImage2D(target glbase.Enum, level, xoffset, yoffset, width, height int, format glbase.Enum, imageSize int, data interface{}) {
+ var data_ptr unsafe.Pointer
+ var data_v = reflect.ValueOf(data)
+ if data != nil && data_v.Kind() != reflect.Slice {
+ panic("parameter data must be a slice")
+ }
+ if data != nil {
+ data_ptr = unsafe.Pointer(data_v.Index(0).Addr().Pointer())
+ }
+ C.gles2_glCompressedTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLsizei(imageSize), data_ptr)
+}
+
+// CreateProgram creates an empty program object and returns a non-zero
+// value by which it can be referenced. A program object is an object to
+// which shader objects can be attached. This provides a mechanism to specify
+// the shader objects that will be linked to create a program. It also
+// provides a means for checking the compatibility of the shaders that will
+// be used to create a program (for instance, checking the compatibility
+// between a vertex shader and a fragment shader). When no longer needed as
+// part of a program object, shader objects can be detached.
+//
+// One or more executables are created in a program object by successfully
+// attaching shader objects to it with AttachShader, successfully compiling
+// the shader objects with CompileShader, and successfully linking the
+// program object with LinkProgram. These executables are made part of
+// current state when UseProgram is called. Program objects can be deleted
+// by calling DeleteProgram. The memory associated with the program object
+// will be deleted when it is no longer part of current rendering state for
+// any context.
+//
+// Like display lists and texture objects, the name space for program objects
+// may be shared across a set of contexts, as long as the server sides of the
+// contexts share the same address space. If the name space is shared across
+// contexts, any attached objects and the data associated with those attached
+// objects are shared as well.
+//
+// Applications are responsible for providing the synchronization across API
+// calls when objects are accessed from different execution threads.
+//
+// This function returns 0 if an error occurs creating the program object.
+//
+// Error GL.INVALID_OPERATION is generated if CreateProgram is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// CreateProgram is available in GL version 2.0 or greater.
+func (gl *GL) CreateProgram() glbase.Program {
+ glresult := C.gles2_glCreateProgram(gl.funcs)
+ return glbase.Program(glresult)
+}
+
+// CreateShader creates an empty shader object and returns a non-zero value
+// by which it can be referenced. A shader object is used to maintain the
+// source code strings that define a shader. shaderType indicates the type of
+// shader to be created.
+//
+// Two types of shaders are supported. A shader of type GL.VERTEX_SHADER is a
+// shader that is intended to run on the programmable vertex processor and
+// replace the fixed functionality vertex processing in OpenGL. A shader of
+// type GL.FRAGMENT_SHADER is a shader that is intended to run on the
+// programmable fragment processor and replace the fixed functionality
+// fragment processing in OpenGL.
+//
+// When created, a shader object's GL.SHADER_TYPE parameter is set to either
+// GL.VERTEX_SHADER or GL.FRAGMENT_SHADER, depending on the value of
+// shaderType.
+//
+// Like display lists and texture objects, the name space for shader objects
+// may be shared across a set of contexts, as long as the server sides of the
+// contexts share the same address space. If the name space is shared across
+// contexts, any attached objects and the data associated with those attached
+// objects are shared as well.
+//
+// This function returns 0 if an error occurs creating the shader object.
+//
+// Error GL.INVALID_ENUM is generated if shaderType is not an accepted value.
+// GL.INVALID_OPERATION is generated if CreateShader is executed between the
+// execution of Begin and the corresponding execution of End.
+//
+// CreateShader is available in GL version 2.0 or greater.
+func (gl *GL) CreateShader(gltype glbase.Enum) glbase.Shader {
+ glresult := C.gles2_glCreateShader(gl.funcs, C.GLenum(gltype))
+ return glbase.Shader(glresult)
+}
+
+// DeleteBuffers deletes the buffer objects whose names are stored in the
+// buffers slice.
+//
+// After a buffer object is deleted, it has no contents, and its name is free
+// for reuse (for example by GenBuffers). If a buffer object that is
+// currently bound is deleted, the binding reverts to 0 (the absence of any
+// buffer object, which reverts to client memory usage).
+//
+// DeleteBuffers silently ignores 0's and names that do not correspond to
+// existing buffer objects.
+//
+// Error GL.INVALID_VALUE is generated if n is negative. GL.INVALID_OPERATION
+// is generated if DeleteBuffers is executed between the execution of Begin
+// and the corresponding execution of End.
+//
+// DeleteBuffers is available in GL version 1.5 or greater.
+func (gl *GL) DeleteBuffers(buffers []glbase.Buffer) {
+ n := len(buffers)
+ if n == 0 {
+ return
+ }
+ C.gles2_glDeleteBuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&buffers[0])))
+}
+
+// DeleteFramebuffers deletes the framebuffer objects whose names are
+// stored in the framebuffers slice. The name zero is reserved by the GL and
+// is silently ignored, should it occur in framebuffers, as are other unused
+// names. Once a framebuffer object is deleted, its name is again unused and
+// it has no attachments. If a framebuffer that is currently bound to one or
+// more of the targets GL.DRAW_FRAMEBUFFER or GL.READ_FRAMEBUFFER is deleted,
+// it is as though BindFramebuffer had been executed with the corresponding
+// target and framebuffer zero.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// DeleteFramebuffers is available in GL version 3.0 or greater.
+func (gl *GL) DeleteFramebuffers(framebuffers []glbase.Framebuffer) {
+ n := len(framebuffers)
+ if n == 0 {
+ return
+ }
+ C.gles2_glDeleteFramebuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&framebuffers[0])))
+}
+
+// DeleteProgram frees the memory and invalidates the name associated with
+// the program object specified by program. This command effectively undoes
+// the effects of a call to CreateProgram.
+//
+// If a program object is in use as part of current rendering state, it will
+// be flagged for deletion, but it will not be deleted until it is no longer
+// part of current state for any rendering context. If a program object to be
+// deleted has shader objects attached to it, those shader objects will be
+// automatically detached but not deleted unless they have already been
+// flagged for deletion by a previous call to DeleteShader. A value of 0
+// for program will be silently ignored.
+//
+// To determine whether a program object has been flagged for deletion, call
+// GetProgram with arguments program and GL.DELETE_STATUS.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL.
+//
+// DeleteProgram is available in GL version 2.0 or greater.
+func (gl *GL) DeleteProgram(program glbase.Program) {
+ C.gles2_glDeleteProgram(gl.funcs, C.GLuint(program))
+}
+
+// DeleteRenderbuffers deletes the renderbuffer objects whose names are stored
+// in the renderbuffers slice. The name zero is reserved by the GL and
+// is silently ignored, should it occur in renderbuffers, as are other unused
+// names. Once a renderbuffer object is deleted, its name is again unused and
+// it has no contents. If a renderbuffer that is currently bound to the
+// target GL.RENDERBUFFER is deleted, it is as though BindRenderbuffer had
+// been executed with a target of GL.RENDERBUFFER and a name of zero.
+//
+// If a renderbuffer object is attached to one or more attachment points in
+// the currently bound framebuffer, then it as if FramebufferRenderbuffer
+// had been called, with a renderbuffer of zero for each attachment point to
+// which this image was attached in the currently bound framebuffer. In other
+// words, this renderbuffer object is first detached from all attachment
+// ponits in the currently bound framebuffer. Note that the renderbuffer
+// image is specifically not detached from any non-bound framebuffers.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// DeleteRenderbuffers is available in GL version 3.0 or greater.
+func (gl *GL) DeleteRenderbuffers(renderbuffers []glbase.Renderbuffer) {
+ n := len(renderbuffers)
+ if n == 0 {
+ return
+ }
+ C.gles2_glDeleteRenderbuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&renderbuffers[0])))
+}
+
+// DeleteShader frees the memory and invalidates the name associated with
+// the shader object specified by shader. This command effectively undoes the
+// effects of a call to CreateShader.
+//
+// If a shader object to be deleted is attached to a program object, it will
+// be flagged for deletion, but it will not be deleted until it is no longer
+// attached to any program object, for any rendering context (it must
+// be detached from wherever it was attached before it will be deleted). A
+// value of 0 for shader will be silently ignored.
+//
+// To determine whether an object has been flagged for deletion, call
+// GetShader with arguments shader and GL.DELETE_STATUS.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL.
+//
+// DeleteShader is available in GL version 2.0 or greater.
+func (gl *GL) DeleteShader(shader glbase.Shader) {
+ C.gles2_glDeleteShader(gl.funcs, C.GLuint(shader))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDepthRangef.xml
+func (gl *GL) DepthRangef(zNear, zFar glbase.Clampf) {
+ C.gles2_glDepthRangef(gl.funcs, C.GLclampf(zNear), C.GLclampf(zFar))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDetachShader.xml
+func (gl *GL) DetachShader(program glbase.Program, shader glbase.Shader) {
+ C.gles2_glDetachShader(gl.funcs, C.GLuint(program), C.GLuint(shader))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDisableVertexAttribArray.xml
+func (gl *GL) DisableVertexAttribArray(index glbase.Attrib) {
+ C.gles2_glDisableVertexAttribArray(gl.funcs, C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEnableVertexAttribArray.xml
+func (gl *GL) EnableVertexAttribArray(index glbase.Attrib) {
+ C.gles2_glEnableVertexAttribArray(gl.funcs, C.GLuint(index))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFramebufferRenderbuffer.xml
+func (gl *GL) FramebufferRenderbuffer(target, attachment, renderbuffertarget glbase.Enum, renderbuffer glbase.Renderbuffer) {
+ C.gles2_glFramebufferRenderbuffer(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(renderbuffertarget), C.GLuint(renderbuffer))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFramebufferTexture2D.xml
+func (gl *GL) FramebufferTexture2D(target, attachment, textarget glbase.Enum, texture glbase.Texture, level int) {
+ C.gles2_glFramebufferTexture2D(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(textarget), C.GLuint(texture), C.GLint(level))
+}
+
+// GenBuffers returns n buffer object names. There is no guarantee that
+// the names form a contiguous set of integers; however, it is guaranteed
+// that none of the returned names was in use immediately before the call to
+// GenBuffers.
+//
+// Buffer object names returned by a call to GenBuffers are not returned by
+// subsequent calls, unless they are first deleted with DeleteBuffers.
+//
+// No buffer objects are associated with the returned buffer object names
+// until they are first bound by calling BindBuffer.
+//
+// Error GL.INVALID_VALUE is generated if n is negative. GL.INVALID_OPERATION
+// is generated if GenBuffers is executed between the execution of Begin
+// and the corresponding execution of End.
+//
+// GenBuffers is available in GL version 1.5 or greater.
+func (gl *GL) GenBuffers(n int) []glbase.Buffer {
+ if n == 0 {
+ return nil
+ }
+ buffers := make([]glbase.Buffer, n)
+ C.gles2_glGenBuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&buffers[0])))
+ return buffers
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGenerateMipmap.xml
+func (gl *GL) GenerateMipmap(target glbase.Enum) {
+ C.gles2_glGenerateMipmap(gl.funcs, C.GLenum(target))
+}
+
+// GenFramebuffers returns n framebuffer object names in ids. There is no
+// guarantee that the names form a contiguous set of integers; however, it is
+// guaranteed that none of the returned names was in use immediately before
+// the call to GenFramebuffers.
+//
+// Framebuffer object names returned by a call to GenFramebuffers are not
+// returned by subsequent calls, unless they are first deleted with
+// DeleteFramebuffers.
+//
+// The names returned in ids are marked as used, for the purposes of
+// GenFramebuffers only, but they acquire state and type only when they are
+// first bound.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+func (gl *GL) GenFramebuffers(n int) []glbase.Framebuffer {
+ if n == 0 {
+ return nil
+ }
+ framebuffers := make([]glbase.Framebuffer, n)
+ C.gles2_glGenFramebuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&framebuffers[0])))
+ return framebuffers
+}
+
+// GenRenderbuffers returns n renderbuffer object names in renderbuffers.
+// There is no guarantee that the names form a contiguous set of integers;
+// however, it is guaranteed that none of the returned names was in use
+// immediately before the call to GenRenderbuffers.
+//
+// Renderbuffer object names returned by a call to GenRenderbuffers are not
+// returned by subsequent calls, unless they are first deleted with
+// DeleteRenderbuffers.
+//
+// The names returned in renderbuffers are marked as used, for the purposes
+// of GenRenderbuffers only, but they acquire state and type only when they
+// are first bound.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// GenRenderbuffers is available in GL version 3.0 or greater.
+func (gl *GL) GenRenderbuffers(n int) []glbase.Renderbuffer {
+ if n == 0 {
+ return nil
+ }
+ renderbuffers := make([]glbase.Renderbuffer, n)
+ C.gles2_glGenRenderbuffers(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&renderbuffers[0])))
+ return renderbuffers
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetActiveAttrib.xml
+func (gl *GL) GetActiveAttrib(program glbase.Program, index glbase.Attrib, bufSize int32, length []int32, size []int, gltype []glbase.Enum, name []byte) {
+ C.gles2_glGetActiveAttrib(gl.funcs, C.GLuint(program), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLint)(unsafe.Pointer(&size[0])), (*C.GLenum)(unsafe.Pointer(&gltype[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetActiveUniform.xml
+func (gl *GL) GetActiveUniform(program glbase.Program, index uint32, bufSize int32, length []int32, size []int, gltype []glbase.Enum, name []byte) {
+ C.gles2_glGetActiveUniform(gl.funcs, C.GLuint(program), C.GLuint(index), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLint)(unsafe.Pointer(&size[0])), (*C.GLenum)(unsafe.Pointer(&gltype[0])), (*C.GLchar)(unsafe.Pointer(&name[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetAttachedShaders.xml
+func (gl *GL) GetAttachedShaders(program glbase.Program, maxcount int32, count []int, shaders []glbase.Shader) {
+ C.gles2_glGetAttachedShaders(gl.funcs, C.GLuint(program), C.GLsizei(maxcount), (*C.GLsizei)(unsafe.Pointer(&count[0])), (*C.GLuint)(unsafe.Pointer(&shaders[0])))
+}
+
+// GetAttribLocation queries the previously linked program object specified
+// by program for the attribute variable specified by name and returns the
+// index of the generic vertex attribute that is bound to that attribute
+// variable. If name is a matrix attribute variable, the index of the first
+// column of the matrix is returned. If the named attribute variable is not
+// an active attribute in the specified program object or if name starts with
+// the reserved prefix "gl_", a value of -1 is returned.
+//
+// The association between an attribute variable name and a generic attribute
+// index can be specified at any time by calling BindAttribLocation.
+// Attribute bindings do not go into effect until LinkProgram is called.
+// After a program object has been linked successfully, the index values for
+// attribute variables remain fixed until the next link command occurs. The
+// attribute values can only be queried after a link if the link was
+// successful. GetAttribLocation returns the binding that actually went
+// into effect the last time LinkProgram was called for the specified
+// program object. Attribute bindings that have been specified since the last
+// link operation are not returned by GetAttribLocation.
+//
+// Error GL_INVALID_OPERATION is generated if program is not a value
+// generated by OpenGL. GL_INVALID_OPERATION is generated if program is not
+// a program object. GL_INVALID_OPERATION is generated if program has not
+// been successfully linked. GL_INVALID_OPERATION is generated if
+// GetAttribLocation is executed between the execution of Begin and the
+// corresponding execution of End.
+//
+// GetAttribLocation is available in GL version 2.0 or greater.
+func (gl *GL) GetAttribLocation(program glbase.Program, name string) glbase.Attrib {
+ name_cstr := C.CString(name)
+ glresult := C.gles2_glGetAttribLocation(gl.funcs, C.GLuint(program), (*C.GLchar)(name_cstr))
+ C.free(unsafe.Pointer(name_cstr))
+ return glbase.Attrib(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetBufferParameteriv.xml
+func (gl *GL) GetBufferParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gles2_glGetBufferParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetFramebufferAttachmentParameteriv.xml
+func (gl *GL) GetFramebufferAttachmentParameteriv(target, attachment, pname glbase.Enum, params []int32) {
+ C.gles2_glGetFramebufferAttachmentParameteriv(gl.funcs, C.GLenum(target), C.GLenum(attachment), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// GetProgramiv returns in params the value of a parameter for a specific
+// program object. The following parameters are defined:
+//
+// GL.DELETE_STATUS
+// params returns GL.TRUE if program is currently flagged for deletion,
+// and GL.FALSE otherwise.
+//
+// GL.LINK_STATUS
+// params returns GL.TRUE if the last link operation on program was
+// successful, and GL.FALSE otherwise.
+//
+// GL.VALIDATE_STATUS
+// params returns GL.TRUE or if the last validation operation on
+// program was successful, and GL.FALSE otherwise.
+//
+// GL.INFO_LOG_LENGTH
+// params returns the number of characters in the information log for
+// program including the null termination character (the size of
+// the character buffer required to store the information log). If
+// program has no information log, a value of 0 is returned.
+//
+// GL.ATTACHED_SHADERS
+// params returns the number of shader objects attached to program.
+//
+// GL.ACTIVE_ATTRIBUTES
+// params returns the number of active attribute variables for program.
+//
+// GL.ACTIVE_ATTRIBUTE_MAX_LENGTH
+// params returns the length of the longest active attribute name for
+// program, including the null termination character (the size of
+// the character buffer required to store the longest attribute name).
+// If no active attributes exist, 0 is returned.
+//
+// GL.ACTIVE_UNIFORMS
+// params returns the number of active uniform variables for program.
+//
+// GL.ACTIVE_UNIFORM_MAX_LENGTH
+// params returns the length of the longest active uniform variable
+// name for program, including the null termination character (i.e.,
+// the size of the character buffer required to store the longest
+// uniform variable name). If no active uniform variables exist, 0 is
+// returned.
+//
+// GL.TRANSFORM_FEEDBACK_BUFFER_MODE
+// params returns a symbolic constant indicating the buffer mode used
+// when transform feedback is active. This may be GL.SEPARATE_ATTRIBS
+// or GL.INTERLEAVED_ATTRIBS.
+//
+// GL.TRANSFORM_FEEDBACK_VARYINGS
+// params returns the number of varying variables to capture in transform
+// feedback mode for the program.
+//
+// GL.TRANSFORM_FEEDBACK_VARYING_MAX_LENGTH
+// params returns the length of the longest variable name to be used for
+// transform feedback, including the null-terminator.
+//
+// GL.GEOMETRY_VERTICES_OUT
+// params returns the maximum number of vertices that the geometry shader in
+// program will output.
+//
+// GL.GEOMETRY_INPUT_TYPE
+// params returns a symbolic constant indicating the primitive type accepted
+// as input to the geometry shader contained in program.
+//
+// GL.GEOMETRY_OUTPUT_TYPE
+// params returns a symbolic constant indicating the primitive type that will
+// be output by the geometry shader contained in program.
+//
+// GL.ACTIVE_UNIFORM_BLOCKS and GL.ACTIVE_UNIFORM_BLOCK_MAX_NAME_LENGTH are
+// available only if the GL version 3.1 or greater.
+//
+// GL.GEOMETRY_VERTICES_OUT, GL.GEOMETRY_INPUT_TYPE and
+// GL.GEOMETRY_OUTPUT_TYPE are accepted only if the GL version is 3.2 or
+// greater.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program does not refer to a
+// program object. GL.INVALID_OPERATION is generated if pname is
+// GL.GEOMETRY_VERTICES_OUT, GL.GEOMETRY_INPUT_TYPE, or
+// GL.GEOMETRY_OUTPUT_TYPE, and program does not contain a geometry shader.
+// GL.INVALID_ENUM is generated if pname is not an accepted value.
+func (gl *GL) GetProgramiv(program glbase.Program, pname glbase.Enum, params []int32) {
+ var params_c [4]int32
+ C.gles2_glGetProgramiv(gl.funcs, C.GLuint(program), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetProgramInfoLog returns the information log for the specified program
+// object. The information log for a program object is modified when the
+// program object is linked or validated.
+//
+// The information log for a program object is either an empty string, or a
+// string containing information about the last link operation, or a string
+// containing information about the last validation operation. It may contain
+// diagnostic messages, warning messages, and other information. When a
+// program object is created, its information log will be a string of length
+// 0, and the size of the current log can be obtained by calling GetProgramiv
+// with the value GL.INFO_LOG_LENGTH.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated
+// by OpenGL. GL.INVALID_OPERATION is generated if program is not a
+// program object.
+func (gl *GL) GetProgramInfoLog(program glbase.Program) []byte {
+ var params [1]int32
+ var length int32
+ gl.GetProgramiv(program, INFO_LOG_LENGTH, params[:])
+ bufSize := params[0]
+ infoLog := make([]byte, int(bufSize))
+ C.gles2_glGetProgramInfoLog(gl.funcs, C.GLuint(program), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length)), (*C.GLchar)(unsafe.Pointer(&infoLog[0])))
+ return infoLog
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetRenderbufferParameteriv.xml
+func (gl *GL) GetRenderbufferParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gles2_glGetRenderbufferParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// GetShaderiv GetShader returns in params the value of a parameter for a specific
+// shader object. The following parameters are defined:
+//
+// GL.SHADER_TYPE
+// params returns GL.VERTEX_SHADER if shader is a vertex shader object,
+// and GL.FRAGMENT_SHADER if shader is a fragment shader object.
+//
+// GL.DELETE_STATUS
+// params returns GL.TRUE if shader is currently flagged for deletion,
+// and GL.FALSE otherwise.
+//
+// GL.COMPILE_STATUS
+// params returns GL.TRUE if the last compile operation on shader was
+// successful, and GL.FALSE otherwise.
+//
+// GL.INFO_LOG_LENGTH
+// params returns the number of characters in the information log for
+// shader including the null termination character (the size of the
+// character buffer required to store the information log). If shader has
+// no information log, a value of 0 is returned.
+//
+// GL.SHADER_SOURCE_LENGTH
+// params returns the length of the concatenation of the source strings
+// that make up the shader source for the shader, including the null
+// termination character. (the size of the character buffer
+// required to store the shader source). If no source code exists, 0 is
+// returned.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader does not refer to a
+// shader object. GL.INVALID_ENUM is generated if pname is not an accepted
+// value. GL.INVALID_OPERATION is generated if GetShader is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// GetShaderiv is available in GL version 2.0 or greater.
+func (gl *GL) GetShaderiv(shader glbase.Shader, pname glbase.Enum, params []int32) {
+ var params_c [4]int32
+ C.gles2_glGetShaderiv(gl.funcs, C.GLuint(shader), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetShaderInfoLog returns the information log for the specified shader
+// object. The information log for a shader object is modified when the
+// shader is compiled.
+//
+// The information log for a shader object is a string that may contain
+// diagnostic messages, warning messages, and other information about the
+// last compile operation. When a shader object is created, its information
+// log will be a string of length 0, and the size of the current log can be
+// obtained by calling GetShaderiv with the value GL.INFO_LOG_LENGTH.
+//
+// The information log for a shader object is the OpenGL implementer's
+// primary mechanism for conveying information about the compilation process.
+// Therefore, the information log can be helpful to application developers
+// during the development process, even when compilation is successful.
+// Application developers should not expect different OpenGL implementations
+// to produce identical information logs.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader is not a shader
+// object. GL.INVALID_VALUE is generated if maxLength is less than 0.
+// GL.INVALID_OPERATION is generated if GetShaderInfoLog is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// GetShaderInfoLog is available in GL version 2.0 or greater.
+func (gl *GL) GetShaderInfoLog(shader glbase.Shader) []byte {
+ var params [1]int32
+ var length int32
+ gl.GetShaderiv(shader, INFO_LOG_LENGTH, params[:])
+ bufSize := params[0]
+ infoLog := make([]byte, int(bufSize))
+ C.gles2_glGetShaderInfoLog(gl.funcs, C.GLuint(shader), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length)), (*C.GLchar)(unsafe.Pointer(&infoLog[0])))
+ return infoLog
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetShaderPrecisionFormat.xml
+func (gl *GL) GetShaderPrecisionFormat(shadertype, precisionType glbase.Enum, range_, precision []int32) {
+ C.gles2_glGetShaderPrecisionFormat(gl.funcs, C.GLenum(shadertype), C.GLenum(precisionType), (*C.GLint)(unsafe.Pointer(&range_[0])), (*C.GLint)(unsafe.Pointer(&precision[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetShaderSource.xml
+func (gl *GL) GetShaderSource(shader glbase.Shader, bufSize int32, length []int32, source []byte) {
+ C.gles2_glGetShaderSource(gl.funcs, C.GLuint(shader), C.GLsizei(bufSize), (*C.GLsizei)(unsafe.Pointer(&length[0])), (*C.GLchar)(unsafe.Pointer(&source[0])))
+}
+
+// GetUniformfv returns in params the value of the specified uniform
+// variable. The type of the uniform variable specified by location
+// determines the number of values returned. If the uniform variable is
+// defined in the shader as a boolean, int, or float, a single value will be
+// returned. If it is defined as a vec2, ivec2, or bvec2, two values will be
+// returned. If it is defined as a vec3, ivec3, or bvec3, three values will
+// be returned, and so on. To query values stored in uniform variables
+// declared as arrays, call GetUniformfv for each element of the array. To
+// query values stored in uniform variables declared as structures, call
+// GetUniformfv for each field in the structure. The values for uniform
+// variables declared as a matrix will be returned in column major order.
+//
+// The locations assigned to uniform variables are not known until the
+// program object is linked. After linking has occurred, the command
+// GetUniformLocation can be used to obtain the location of a uniform
+// variable. This location value can then be passed to GetUniformfv in order
+// to query the current value of the uniform variable. After a program object
+// has been linked successfully, the index values for uniform variables
+// remain fixed until the next link command occurs. The uniform variable
+// values can only be queried after a link if the link was successful.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program
+// object. GL.INVALID_OPERATION is generated if program has not been
+// successfully linked. GL.INVALID_OPERATION is generated if location does
+// not correspond to a valid uniform variable location for the specified
+// program object. GL.INVALID_OPERATION is generated if GetUniformfv is
+// executed between the execution of Begin and the corresponding execution of
+// End.
+//
+// GetUniformfv is available in GL version 2.0 or greater.
+func (gl *GL) GetUniformfv(program glbase.Program, location glbase.Uniform, params []float32) {
+ var params_c [4]float32
+ C.gles2_glGetUniformfv(gl.funcs, C.GLuint(program), C.GLint(location), (*C.GLfloat)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetUniformiv returns in params the value of the specified uniform
+// variable. The type of the uniform variable specified by location
+// determines the number of values returned. If the uniform variable is
+// defined in the shader as a boolean, int, or float, a single value will be
+// returned. If it is defined as a vec2, ivec2, or bvec2, two values will be
+// returned. If it is defined as a vec3, ivec3, or bvec3, three values will
+// be returned, and so on. To query values stored in uniform variables
+// declared as arrays, call GetUniformiv for each element of the array. To
+// query values stored in uniform variables declared as structures, call
+// GetUniformiv for each field in the structure. The values for uniform
+// variables declared as a matrix will be returned in column major order.
+//
+// The locations assigned to uniform variables are not known until the
+// program object is linked. After linking has occurred, the command
+// GetUniformLocation can be used to obtain the location of a uniform
+// variable. This location value can then be passed to GetUniformiv in order
+// to query the current value of the uniform variable. After a program object
+// has been linked successfully, the index values for uniform variables
+// remain fixed until the next link command occurs. The uniform variable
+// values can only be queried after a link if the link was successful.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program
+// object. GL.INVALID_OPERATION is generated if program has not been
+// successfully linked. GL.INVALID_OPERATION is generated if location does
+// not correspond to a valid uniform variable location for the specified
+// program object. GL.INVALID_OPERATION is generated if GetUniformiv is
+// executed between the execution of Begin and the corresponding execution of
+// End.
+//
+// GetUniformiv is available in GL version 2.0 or greater.
+func (gl *GL) GetUniformiv(program glbase.Program, location glbase.Uniform, params []int32) {
+ var params_c [4]int32
+ C.gles2_glGetUniformiv(gl.funcs, C.GLuint(program), C.GLint(location), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetUniformLocation returns an integer that represents the location of a
+// specific uniform variable within a program object. name must be an active
+// uniform variable name in program that is not a structure, an array of
+// structures, or a subcomponent of a vector or a matrix. This function
+// returns -1 if name does not correspond to an active uniform variable in
+// program or if name starts with the reserved prefix "gl_".
+//
+// Uniform variables that are structures or arrays of structures may be
+// queried by calling GetUniformLocation for each field within the
+// structure. The array element operator "[]" and the structure field
+// operator "." may be used in name in order to select elements within an
+// array or fields within a structure. The result of using these operators is
+// not allowed to be another structure, an array of structures, or a
+// subcomponent of a vector or a matrix. Except if the last part of name
+// indicates a uniform variable array, the location of the first element of
+// an array can be retrieved by using the name of the array, or by using the
+// name appended by "[0]".
+//
+// The actual locations assigned to uniform variables are not known until the
+// program object is linked successfully. After linking has occurred, the
+// command GetUniformLocation can be used to obtain the location of a
+// uniform variable. This location value can then be passed to Uniform to
+// set the value of the uniform variable or to GetUniform in order to query
+// the current value of the uniform variable. After a program object has been
+// linked successfully, the index values for uniform variables remain fixed
+// until the next link command occurs. Uniform variable locations and values
+// can only be queried after a link if the link was successful.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program object.
+// GL.INVALID_OPERATION is generated if program has not been successfully
+// linked. GL.INVALID_OPERATION is generated if GetUniformLocation is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// GetUniformLocation is available in GL version 2.0 or greater.
+func (gl *GL) GetUniformLocation(program glbase.Program, name string) glbase.Uniform {
+ name_cstr := C.CString(name)
+ glresult := C.gles2_glGetUniformLocation(gl.funcs, C.GLuint(program), (*C.GLchar)(name_cstr))
+ C.free(unsafe.Pointer(name_cstr))
+ return glbase.Uniform(glresult)
+}
+
+// GetVertexAttribfv returns in params the value of a generic vertex attribute
+// parameter. The generic vertex attribute to be queried is specified by
+// index, and the parameter to be queried is specified by pname.
+//
+// The accepted parameter names are as follows:
+//
+// GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING
+// params returns a single value, the name of the buffer object
+// currently bound to the binding point corresponding to generic vertex
+// attribute array index. If no buffer object is bound, 0 is returned.
+// The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_ENABLED
+// params returns a single value that is non-zero (true) if the vertex
+// attribute array for index is enabled and 0 (false) if it is
+// disabled. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_SIZE
+// params returns a single value, the size of the vertex attribute
+// array for index. The size is the number of values for each element
+// of the vertex attribute array, and it will be 1, 2, 3, or 4. The
+// initial value is 4.
+//
+// GL.VERTEX_ATTRIB_ARRAY_STRIDE
+// params returns a single value, the array stride for (number of bytes
+// between successive elements in) the vertex attribute array for
+// index. A value of 0 indicates that the array elements are stored
+// sequentially in memory. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_TYPE
+// params returns a single value, a symbolic constant indicating the
+// array type for the vertex attribute array for index. Possible values
+// are GL.BYTE, GL.UNSIGNED_BYTE, GL.SHORT, GL.UNSIGNED_SHORT, GL.INT,
+// GL.UNSIGNED_INT, GL.FLOAT, and GL.DOUBLE. The initial value is
+// GL.FLOAT.
+//
+// GL.VERTEX_ATTRIB_ARRAY_NORMALIZED
+// params returns a single value that is non-zero (true) if fixed-point
+// data types for the vertex attribute array indicated by index are
+// normalized when they are converted to floating point, and 0 (false)
+// otherwise. The initial value is 0.
+//
+// GL.CURRENT_VERTEX_ATTRIB
+// params returns four values that represent the current value for the
+// generic vertex attribute specified by index. Generic vertex
+// attribute 0 is unique in that it has no current state, so an error
+// will be generated if index is 0. The initial value for all other
+// generic vertex attributes is (0,0,0,1).
+//
+// All of the parameters except GL.CURRENT_VERTEX_ATTRIB represent
+// client-side state.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_ENUM is generated if pname is not an
+// accepted value. GL.INVALID_OPERATION is generated if index is 0 and pname
+// is GL.CURRENT_VERTEX_ATTRIB.
+//
+// GetVertexAttribfv is available in GL version 2.0 or greater.
+func (gl *GL) GetVertexAttribfv(index glbase.Attrib, pname glbase.Enum, params []float32) {
+ var params_c [4]float32
+ C.gles2_glGetVertexAttribfv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// GetVertexAttribiv returns in params the value of a generic vertex attribute
+// parameter. The generic vertex attribute to be queried is specified by
+// index, and the parameter to be queried is specified by pname.
+//
+// The accepted parameter names are as follows:
+//
+// GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING
+// params returns a single value, the name of the buffer object
+// currently bound to the binding point corresponding to generic vertex
+// attribute array index. If no buffer object is bound, 0 is returned.
+// The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_ENABLED
+// params returns a single value that is non-zero (true) if the vertex
+// attribute array for index is enabled and 0 (false) if it is
+// disabled. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_SIZE
+// params returns a single value, the size of the vertex attribute
+// array for index. The size is the number of values for each element
+// of the vertex attribute array, and it will be 1, 2, 3, or 4. The
+// initial value is 4.
+//
+// GL.VERTEX_ATTRIB_ARRAY_STRIDE
+// params returns a single value, the array stride for (number of bytes
+// between successive elements in) the vertex attribute array for
+// index. A value of 0 indicates that the array elements are stored
+// sequentially in memory. The initial value is 0.
+//
+// GL.VERTEX_ATTRIB_ARRAY_TYPE
+// params returns a single value, a symbolic constant indicating the
+// array type for the vertex attribute array for index. Possible values
+// are GL.BYTE, GL.UNSIGNED_BYTE, GL.SHORT, GL.UNSIGNED_SHORT, GL.INT,
+// GL.UNSIGNED_INT, GL.FLOAT, and GL.DOUBLE. The initial value is
+// GL.FLOAT.
+//
+// GL.VERTEX_ATTRIB_ARRAY_NORMALIZED
+// params returns a single value that is non-zero (true) if fixed-point
+// data types for the vertex attribute array indicated by index are
+// normalized when they are converted to floating point, and 0 (false)
+// otherwise. The initial value is 0.
+//
+// GL.CURRENT_VERTEX_ATTRIB
+// params returns four values that represent the current value for the
+// generic vertex attribute specified by index. Generic vertex
+// attribute 0 is unique in that it has no current state, so an error
+// will be generated if index is 0. The initial value for all other
+// generic vertex attributes is (0,0,0,1).
+//
+// All of the parameters except GL.CURRENT_VERTEX_ATTRIB represent
+// client-side state.
+//
+// Error GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_ENUM is generated if pname is not an
+// accepted value. GL.INVALID_OPERATION is generated if index is 0 and pname
+// is GL.CURRENT_VERTEX_ATTRIB.
+//
+// GetVertexAttribiv is available in GL version 2.0 or greater.
+func (gl *GL) GetVertexAttribiv(index glbase.Attrib, pname glbase.Enum, params []int32) {
+ var params_c [4]int32
+ C.gles2_glGetVertexAttribiv(gl.funcs, C.GLuint(index), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params_c[0])))
+ copy(params, params_c[:])
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIsBuffer.xml
+func (gl *GL) IsBuffer(buffer glbase.Buffer) bool {
+ glresult := C.gles2_glIsBuffer(gl.funcs, C.GLuint(buffer))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIsFramebuffer.xml
+func (gl *GL) IsFramebuffer(framebuffer glbase.Framebuffer) bool {
+ glresult := C.gles2_glIsFramebuffer(gl.funcs, C.GLuint(framebuffer))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIsProgram.xml
+func (gl *GL) IsProgram(program glbase.Program) bool {
+ glresult := C.gles2_glIsProgram(gl.funcs, C.GLuint(program))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIsRenderbuffer.xml
+func (gl *GL) IsRenderbuffer(renderbuffer glbase.Renderbuffer) bool {
+ glresult := C.gles2_glIsRenderbuffer(gl.funcs, C.GLuint(renderbuffer))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIsShader.xml
+func (gl *GL) IsShader(shader glbase.Shader) bool {
+ glresult := C.gles2_glIsShader(gl.funcs, C.GLuint(shader))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// LinkProgram links the program object specified by program. If any shader
+// objects of type GL.VERTEX_SHADER are attached to program, they will be
+// used to create an executable that will run on the programmable vertex
+// processor. If any shader objects of type GL.FRAGMENT_SHADER are attached
+// to program, they will be used to create an executable that will run on the
+// programmable fragment processor.
+//
+// The status of the link operation will be stored as part of the program
+// object's state. This value will be set to GL.TRUE if the program object
+// was linked without errors and is ready for use, and GL.FALSE otherwise. It
+// can be queried by calling GetProgramiv with arguments program and
+// GL.LINK_STATUS.
+//
+// As a result of a successful link operation, all active user-defined
+// uniform variables belonging to program will be initialized to 0, and each
+// of the program object's active uniform variables will be assigned a
+// location that can be queried by calling GetUniformLocation. Also, any
+// active user-defined attribute variables that have not been bound to a
+// generic vertex attribute index will be bound to one at this time.
+//
+// Linking of a program object can fail for a number of reasons as specified
+// in the OpenGL Shading Language Specification. The following lists some of
+// the conditions that will cause a link error.
+//
+// - The number of active attribute variables supported by the
+// implementation has been exceeded.
+//
+// - The storage limit for uniform variables has been exceeded.
+//
+// - The number of active uniform variables supported by the implementation
+// has been exceeded.
+//
+// - The main function is missing for the vertex shader or the fragment
+// shader.
+//
+// - A varying variable actually used in the fragment shader is not
+// declared in the same way (or is not declared at all) in the vertex
+// shader.
+//
+// - A reference to a function or variable name is unresolved.
+//
+// - A shared global is declared with two different types or two different
+// initial values.
+//
+// - One or more of the attached shader objects has not been successfully
+// compiled.
+//
+// - Binding a generic attribute matrix caused some rows of the matrix to
+// fall outside the allowed maximum of GL.MAX_VERTEX_ATTRIBS.
+//
+// - Not enough contiguous vertex attribute slots could be found to bind
+// attribute matrices.
+//
+// When a program object has been successfully linked, the program object can
+// be made part of current state by calling UseProgram. Whether or not the
+// link operation was successful, the program object's information log will
+// be overwritten. The information log can be retrieved by calling
+// GetProgramInfoLog.
+//
+// LinkProgram will also install the generated executables as part of the
+// current rendering state if the link operation was successful and the
+// specified program object is already currently in use as a result of a
+// previous call to UseProgram. If the program object currently in use is
+// relinked unsuccessfully, its link status will be set to GL.FALSE , but the
+// executables and associated state will remain part of the current state
+// until a subsequent call to UseProgram removes it from use. After it is
+// removed from use, it cannot be made part of current state until it has
+// been successfully relinked.
+//
+// If program contains shader objects of type GL.VERTEX_SHADER but does not
+// contain shader objects of type GL.FRAGMENT_SHADER, the vertex shader will
+// be linked against the implicit interface for fixed functionality fragment
+// processing. Similarly, if program contains shader objects of type
+// GL.FRAGMENT_SHADER but it does not contain shader objects of type
+// GL.VERTEX_SHADER, the fragment shader will be linked against the implicit
+// interface for fixed functionality vertex processing.
+//
+// The program object's information log is updated and the program is
+// generated at the time of the link operation. After the link operation,
+// applications are free to modify attached shader objects, compile attached
+// shader objects, detach shader objects, delete shader objects, and attach
+// additional shader objects. None of these operations affects the
+// information log or the program that is part of the program object.
+//
+// If the link operation is unsuccessful, any information about a previous
+// link operation on program is lost (a failed link does not restore the
+// old state of program). Certain information can still be retrieved
+// from program even after an unsuccessful link operation. See for instance
+// GetActiveAttrib and GetActiveUniform.
+//
+// Error GL.INVALID_VALUE is generated if program is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if program is not a program
+// object. GL.INVALID_OPERATION is generated if LinkProgram is executed
+// between the execution of Begin and the corresponding execution of End.
+//
+// LinkProgram is available in GL version 2.0 or greater.
+func (gl *GL) LinkProgram(program glbase.Program) {
+ C.gles2_glLinkProgram(gl.funcs, C.GLuint(program))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glReleaseShaderCompiler.xml
+func (gl *GL) ReleaseShaderCompiler() {
+ C.gles2_glReleaseShaderCompiler(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glRenderbufferStorage.xml
+func (gl *GL) RenderbufferStorage(target, internalFormat glbase.Enum, width, height int) {
+ C.gles2_glRenderbufferStorage(gl.funcs, C.GLenum(target), C.GLenum(internalFormat), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glSampleCoverage.xml
+func (gl *GL) SampleCoverage(value glbase.Clampf, invert bool) {
+ C.gles2_glSampleCoverage(gl.funcs, C.GLclampf(value), *(*C.GLboolean)(unsafe.Pointer(&invert)))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glShaderBinary.xml
+func (gl *GL) ShaderBinary(n int, shaders []glbase.Shader, binaryFormat glbase.Enum, binary interface{}, length int32) {
+ var binary_ptr unsafe.Pointer
+ var binary_v = reflect.ValueOf(binary)
+ if binary != nil && binary_v.Kind() != reflect.Slice {
+ panic("parameter binary must be a slice")
+ }
+ if binary != nil {
+ binary_ptr = unsafe.Pointer(binary_v.Index(0).Addr().Pointer())
+ }
+ C.gles2_glShaderBinary(gl.funcs, C.GLint(n), (*C.GLuint)(unsafe.Pointer(&shaders[0])), C.GLenum(binaryFormat), binary_ptr, C.GLint(length))
+}
+
+// ShaderSource sets the source code in shader to the provided source code. Any source
+// code previously stored in the shader object is completely replaced.
+//
+// Error GL.INVALID_VALUE is generated if shader is not a value generated by
+// OpenGL. GL.INVALID_OPERATION is generated if shader is not a shader
+// object. GL.INVALID_VALUE is generated if count is less than 0.
+// GL.INVALID_OPERATION is generated if ShaderSource is executed between the
+// execution of Begin and the corresponding execution of End.
+//
+// ShaderSource is available in GL version 2.0 or greater.
+func (gl *GL) ShaderSource(shader glbase.Shader, source ...string) {
+ count := len(source)
+ length := make([]int32, count)
+ source_c := make([]unsafe.Pointer, count)
+ for i, src := range source {
+ length[i] = int32(len(src))
+ if len(src) > 0 {
+ source_c[i] = *(*unsafe.Pointer)(unsafe.Pointer(&src))
+ } else {
+ source_c[i] = unsafe.Pointer(uintptr(0))
+ }
+ }
+ C.gles2_glShaderSource(gl.funcs, C.GLuint(shader), C.GLsizei(count), (**C.GLchar)(unsafe.Pointer(&source_c[0])), (*C.GLint)(unsafe.Pointer(&length[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glStencilFuncSeparate.xml
+func (gl *GL) StencilFuncSeparate(face, glfunc glbase.Enum, ref int32, mask uint32) {
+ C.gles2_glStencilFuncSeparate(gl.funcs, C.GLenum(face), C.GLenum(glfunc), C.GLint(ref), C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glStencilMaskSeparate.xml
+func (gl *GL) StencilMaskSeparate(face glbase.Enum, mask uint32) {
+ C.gles2_glStencilMaskSeparate(gl.funcs, C.GLenum(face), C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glStencilOpSeparate.xml
+func (gl *GL) StencilOpSeparate(face, fail, zfail, zpass glbase.Enum) {
+ C.gles2_glStencilOpSeparate(gl.funcs, C.GLenum(face), C.GLenum(fail), C.GLenum(zfail), C.GLenum(zpass))
+}
+
+// Uniform1f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform1f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1f(location glbase.Uniform, v0 float32) {
+ C.gles2_glUniform1f(gl.funcs, C.GLint(location), C.GLfloat(v0))
+}
+
+// Uniform1fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform1fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ count := len(value)
+ C.gles2_glUniform1fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform1i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform1i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1i(location glbase.Uniform, v0 int32) {
+ C.gles2_glUniform1i(gl.funcs, C.GLint(location), C.GLint(v0))
+}
+
+// Uniform1iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform1iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform1iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ count := len(value)
+ C.gles2_glUniform1iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform2f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform2f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2f(location glbase.Uniform, v0, v1 float32) {
+ C.gles2_glUniform2f(gl.funcs, C.GLint(location), C.GLfloat(v0), C.GLfloat(v1))
+}
+
+// Uniform2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%2 != 0 {
+ panic("invalid value length for Uniform2fv")
+ }
+ count := len(value) / 2
+ C.gles2_glUniform2fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform2i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform2i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2i(location glbase.Uniform, v0, v1 int32) {
+ C.gles2_glUniform2i(gl.funcs, C.GLint(location), C.GLint(v0), C.GLint(v1))
+}
+
+// Uniform2iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform2iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform2iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%2 != 0 {
+ panic("invalid value length for Uniform2iv")
+ }
+ count := len(value) / 2
+ C.gles2_glUniform2iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform3f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform3f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3f(location glbase.Uniform, v0, v1, v2 float32) {
+ C.gles2_glUniform3f(gl.funcs, C.GLint(location), C.GLfloat(v0), C.GLfloat(v1), C.GLfloat(v2))
+}
+
+// Uniform3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%3 != 0 {
+ panic("invalid value length for Uniform3fv")
+ }
+ count := len(value) / 3
+ C.gles2_glUniform3fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform3i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform3i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3i(location glbase.Uniform, v0, v1, v2 int32) {
+ C.gles2_glUniform3i(gl.funcs, C.GLint(location), C.GLint(v0), C.GLint(v1), C.GLint(v2))
+}
+
+// Uniform3iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform3iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform3iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%3 != 0 {
+ panic("invalid value length for Uniform3iv")
+ }
+ count := len(value) / 3
+ C.gles2_glUniform3iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4f modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform4f operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4f(location glbase.Uniform, v0, v1, v2, v3 float32) {
+ C.gles2_glUniform4f(gl.funcs, C.GLint(location), C.GLfloat(v0), C.GLfloat(v1), C.GLfloat(v2), C.GLfloat(v3))
+}
+
+// Uniform4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4fv(location glbase.Uniform, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%4 != 0 {
+ panic("invalid value length for Uniform4fv")
+ }
+ count := len(value) / 4
+ C.gles2_glUniform4fv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// Uniform4i modifies the value of a single uniform variable.
+// The location of the uniform variable to be modified is specified by
+// location, which should be a value returned by GetUniformLocation.
+// Uniform4i operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+// uniform variable specified by location using the values passed as
+// arguments. The number specified in the function should match the number of
+// components in the data type of the specified uniform variable (1 for
+// float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+// The suffix f indicates that floating-point values are being passed; the
+// suffix i indicates that integer values are being passed; the suffix ui
+// indicates that unsigned integer values are being passed, and this type
+// should also match the data type of the specified uniform variable. The i
+// variants of this function should be used to provide values for uniform
+// variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+// variants of this function should be used to provide values for uniform
+// variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+// these. The f variants should be used to provide values for uniform
+// variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+// i, ui or f variants may be used to provide values for uniform variables of
+// type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+// will be set to false if the input value is 0 or 0.0f, and it will be set
+// to true otherwise.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4i(location glbase.Uniform, v0, v1, v2, v3 int32) {
+ C.gles2_glUniform4i(gl.funcs, C.GLint(location), C.GLint(v0), C.GLint(v1), C.GLint(v2), C.GLint(v3))
+}
+
+// Uniform4iv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// Uniform4iv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+// uniform variable or a uniform variable array. These functions receive a
+// slice with the values to be loaded into a uniform variable or a uniform
+// variable array. A slice with length 1 should be used if modifying the value
+// of a single uniform variable, and a length of 1 or greater can be used to
+// modify an entire array or part of an array. When loading n elements
+// starting at an arbitrary position m in a uniform variable array, elements
+// m + n - 1 in the array will be replaced with the new values. If m + n - 1
+// is larger than the size of the uniform variable array, values for all
+// array elements beyond the end of the array will be ignored. The number
+// specified in the name of the command indicates the number of components
+// for each element in value, and it should match the number of components in
+// the data type of the specified uniform variable (1 for float, int, bool;
+// 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+// of the command must match the data type for the specified uniform variable
+// as described for Uniform{1|2|3|4}{f|i|ui}.
+//
+// Uniform1i and Uniform1iv are the only two functions that may be used to
+// load uniform variables defined as sampler types. Loading samplers with any
+// other function will result in a GL.INVALID_OPERATION error.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) Uniform4iv(location glbase.Uniform, value []int32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%4 != 0 {
+ panic("invalid value length for Uniform4iv")
+ }
+ count := len(value) / 4
+ C.gles2_glUniform4iv(gl.funcs, C.GLint(location), C.GLsizei(count), (*C.GLint)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix2fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix2fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix2fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(2*2) != 0 {
+ panic("invalid value length for UniformMatrix2fv")
+ }
+ count := len(value) / (2 * 2)
+ C.gles2_glUniformMatrix2fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix3fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix3fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix3fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(3*3) != 0 {
+ panic("invalid value length for UniformMatrix3fv")
+ }
+ count := len(value) / (3 * 3)
+ C.gles2_glUniformMatrix3fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UniformMatrix4fv modifies the value of a uniform variable or a uniform
+// variable array. The location of the uniform variable to be modified is
+// specified by location, which should be a value returned by GetUniformLocation.
+// UniformMatrix4fv operates on the program object that was made part of
+// current state by calling UseProgram.
+//
+// The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+// modify a matrix or an array of matrices. The numbers in the function name
+// are interpreted as the dimensionality of the matrix. The number 2
+// indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+// values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+// matrix dimensionality is explicit, with the first number representing the
+// number of columns and the second number representing the number of rows.
+// For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+// values). The length of the provided slice must be a multiple of the number
+// of values per matrix, to update one or more consecutive matrices.
+//
+// If transpose is false, each matrix is assumed to be supplied in column
+// major order. If transpose is true, each matrix is assumed to be supplied
+// in row major order.
+//
+// All active uniform variables defined in a program object are initialized
+// to 0 when the program object is linked successfully. They retain the
+// values assigned to them by a call to Uniform* until the next successful
+// link operation occurs on the program object, when they are once again
+// initialized to 0.
+func (gl *GL) UniformMatrix4fv(location glbase.Uniform, transpose bool, value []float32) {
+ if len(value) == 0 {
+ return
+ }
+ if len(value)%(4*4) != 0 {
+ panic("invalid value length for UniformMatrix4fv")
+ }
+ count := len(value) / (4 * 4)
+ C.gles2_glUniformMatrix4fv(gl.funcs, C.GLint(location), C.GLsizei(count), *(*C.GLboolean)(unsafe.Pointer(&transpose)), (*C.GLfloat)(unsafe.Pointer(&value[0])))
+}
+
+// UseProgram installs the program object specified by program as part of
+// current rendering state. One or more executables are created in a program
+// object by successfully attaching shader objects to it with AttachShader,
+// successfully compiling the shader objects with CompileShader, and
+// successfully linking the program object with LinkProgram.
+//
+// A program object will contain an executable that will run on the vertex
+// processor if it contains one or more shader objects of type
+// GL.VERTEX_SHADER that have been successfully compiled and linked.
+// Similarly, a program object will contain an executable that will run on
+// the fragment processor if it contains one or more shader objects of type
+// GL.FRAGMENT_SHADER that have been successfully compiled and linked.
+//
+// Successfully installing an executable on a programmable processor will
+// cause the corresponding fixed functionality of OpenGL to be disabled.
+// Specifically, if an executable is installed on the vertex processor, the
+// OpenGL fixed functionality will be disabled as follows.
+//
+// - The modelview matrix is not applied to vertex coordinates.
+//
+// - The projection matrix is not applied to vertex coordinates.
+//
+// - The texture matrices are not applied to texture coordinates.
+//
+// - Normals are not transformed to eye coordinates.
+//
+// - Normals are not rescaled or normalized.
+//
+// - Normalization of GL.AUTO_NORMAL evaluated normals is not performed.
+//
+// - Texture coordinates are not generated automatically.
+//
+// - Per-vertex lighting is not performed.
+//
+// - Color material computations are not performed.
+//
+// - Color index lighting is not performed.
+//
+// - This list also applies when setting the current raster position.
+//
+// The executable that is installed on the vertex processor is expected to
+// implement any or all of the desired functionality from the preceding list.
+// Similarly, if an executable is installed on the fragment processor, the
+// OpenGL fixed functionality will be disabled as follows.
+//
+// - Texture environment and texture functions are not applied.
+//
+// - Texture application is not applied.
+//
+// - Color sum is not applied.
+//
+// - Fog is not applied.
+//
+// Again, the fragment shader that is installed is expected to implement any
+// or all of the desired functionality from the preceding list.
+//
+// While a program object is in use, applications are free to modify attached
+// shader objects, compile attached shader objects, attach additional shader
+// objects, and detach or delete shader objects. None of these operations
+// will affect the executables that are part of the current state. However,
+// relinking the program object that is currently in use will install the
+// program object as part of the current rendering state if the link
+// operation was successful (see LinkProgram). If the program object
+// currently in use is relinked unsuccessfully, its link status will be set
+// to GL.FALSE, but the executables and associated state will remain part of
+// the current state until a subsequent call to UseProgram removes it from
+// use. After it is removed from use, it cannot be made part of current state
+// until it has been successfully relinked.
+//
+// If program contains shader objects of type GL.VERTEX_SHADER but it does
+// not contain shader objects of type GL.FRAGMENT_SHADER, an executable will
+// be installed on the vertex processor, but fixed functionality will be used
+// for fragment processing. Similarly, if program contains shader objects of
+// type GL.FRAGMENT_SHADER but it does not contain shader objects of type
+// GL.VERTEX_SHADER, an executable will be installed on the fragment
+// processor, but fixed functionality will be used for vertex processing. If
+// program is 0, the programmable processors will be disabled, and fixed
+// functionality will be used for both vertex and fragment processing.
+//
+// While a program object is in use, the state that controls the disabled
+// fixed functionality may also be updated using the normal OpenGL calls.
+//
+// Like display lists and texture objects, the name space for program objects
+// may be shared across a set of contexts, as long as the server sides of the
+// contexts share the same address space. If the name space is shared across
+// contexts, any attached objects and the data associated with those attached
+// objects are shared as well.
+//
+// Applications are responsible for providing the synchronization across API
+// calls when objects are accessed from different execution threads.
+//
+// Error GL.INVALID_VALUE is generated if program is neither 0 nor a value
+// generated by OpenGL. GL.INVALID_OPERATION is generated if program is not
+// a program object. GL.INVALID_OPERATION is generated if program could not
+// be made part of current state. GL.INVALID_OPERATION is generated if
+// UseProgram is executed between the execution of Begin and the
+// corresponding execution of End.
+//
+// UseProgram is available in GL version 2.0 or greater.
+func (gl *GL) UseProgram(program glbase.Program) {
+ C.gles2_glUseProgram(gl.funcs, C.GLuint(program))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glValidateProgram.xml
+func (gl *GL) ValidateProgram(program glbase.Program) {
+ C.gles2_glValidateProgram(gl.funcs, C.GLuint(program))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib1f.xml
+func (gl *GL) VertexAttrib1f(index glbase.Attrib, x float32) {
+ C.gles2_glVertexAttrib1f(gl.funcs, C.GLuint(index), C.GLfloat(x))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib1fv.xml
+func (gl *GL) VertexAttrib1fv(index glbase.Attrib, values []float32) {
+ C.gles2_glVertexAttrib1fv(gl.funcs, C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib2f.xml
+func (gl *GL) VertexAttrib2f(index glbase.Attrib, x, y float32) {
+ C.gles2_glVertexAttrib2f(gl.funcs, C.GLuint(index), C.GLfloat(x), C.GLfloat(y))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib2fv.xml
+func (gl *GL) VertexAttrib2fv(index glbase.Attrib, values []float32) {
+ if len(values) != 2 {
+ panic("parameter values has incorrect length")
+ }
+ C.gles2_glVertexAttrib2fv(gl.funcs, C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib3f.xml
+func (gl *GL) VertexAttrib3f(index glbase.Attrib, x, y, z float32) {
+ C.gles2_glVertexAttrib3f(gl.funcs, C.GLuint(index), C.GLfloat(x), C.GLfloat(y), C.GLfloat(z))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib3fv.xml
+func (gl *GL) VertexAttrib3fv(index glbase.Attrib, values []float32) {
+ if len(values) != 3 {
+ panic("parameter values has incorrect length")
+ }
+ C.gles2_glVertexAttrib3fv(gl.funcs, C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&values[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib4f.xml
+func (gl *GL) VertexAttrib4f(index glbase.Attrib, x, y, z, w float32) {
+ C.gles2_glVertexAttrib4f(gl.funcs, C.GLuint(index), C.GLfloat(x), C.GLfloat(y), C.GLfloat(z), C.GLfloat(w))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glVertexAttrib4fv.xml
+func (gl *GL) VertexAttrib4fv(index glbase.Attrib, values []float32) {
+ if len(values) != 4 {
+ panic("parameter values has incorrect length")
+ }
+ C.gles2_glVertexAttrib4fv(gl.funcs, C.GLuint(index), (*C.GLfloat)(unsafe.Pointer(&values[0])))
+}
+
+// VertexAttribPointer specifies the location and data format of the array
+// of generic vertex attributes at index to use when rendering. size
+// specifies the number of components per attribute and must be 1, 2, 3, or
+// 4. type specifies the data type of each component, and stride specifies
+// the byte stride from one attribute to the next, allowing vertices and
+// attributes to be packed into a single array or stored in separate arrays.
+// normalized indicates whether the values stored in an integer format are
+// to be mapped to the range [-1,1] (for signed values) or [0,1]
+// (for unsigned values) when they are accessed and converted to floating
+// point; otherwise, values will be converted to floats directly without
+// normalization. offset is a byte offset into the buffer object's data
+// store, which must be bound to the GL.ARRAY_BUFFER target with BindBuffer.
+//
+// The buffer object binding (GL.ARRAY_BUFFER_BINDING) is saved as
+// generic vertex attribute array client-side state
+// (GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING) for the provided index.
+//
+// To enable and disable a generic vertex attribute array, call
+// EnableVertexAttribArray and DisableVertexAttribArray with index. If
+// enabled, the generic vertex attribute array is used when DrawArrays or
+// DrawElements is called. Each generic vertex attribute array is initially
+// disabled.
+//
+// VertexAttribPointer is typically implemented on the client side.
+//
+// Error GL.INVALID_ENUM is generated if type is not an accepted value.
+// GL.INVALID_VALUE is generated if index is greater than or equal to
+// GL.MAX_VERTEX_ATTRIBS. GL.INVALID_VALUE is generated if size is not 1, 2,
+// 3, or 4. GL.INVALID_VALUE is generated if stride is negative.
+func (gl *GL) VertexAttribPointer(index glbase.Attrib, size int, gltype glbase.Enum, normalized bool, stride int, offset uintptr) {
+ offset_ptr := unsafe.Pointer(offset)
+ C.gles2_glVertexAttribPointer(gl.funcs, C.GLuint(index), C.GLint(size), C.GLenum(gltype), *(*C.GLboolean)(unsafe.Pointer(&normalized)), C.GLsizei(stride), offset_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBindTexture.xml
+func (gl *GL) BindTexture(target glbase.Enum, texture glbase.Texture) {
+ C.gles2_glBindTexture(gl.funcs, C.GLenum(target), C.GLuint(texture))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glBlendFunc.xml
+func (gl *GL) BlendFunc(sfactor, dfactor glbase.Enum) {
+ C.gles2_glBlendFunc(gl.funcs, C.GLenum(sfactor), C.GLenum(dfactor))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClear.xml
+func (gl *GL) Clear(mask glbase.Bitfield) {
+ C.gles2_glClear(gl.funcs, C.GLbitfield(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClearColor.xml
+func (gl *GL) ClearColor(red, green, blue, alpha glbase.Clampf) {
+ C.gles2_glClearColor(gl.funcs, C.GLclampf(red), C.GLclampf(green), C.GLclampf(blue), C.GLclampf(alpha))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glClearStencil.xml
+func (gl *GL) ClearStencil(s int32) {
+ C.gles2_glClearStencil(gl.funcs, C.GLint(s))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glColorMask.xml
+func (gl *GL) ColorMask(red, green, blue, alpha bool) {
+ C.gles2_glColorMask(gl.funcs, *(*C.GLboolean)(unsafe.Pointer(&red)), *(*C.GLboolean)(unsafe.Pointer(&green)), *(*C.GLboolean)(unsafe.Pointer(&blue)), *(*C.GLboolean)(unsafe.Pointer(&alpha)))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyTexImage2D.xml
+func (gl *GL) CopyTexImage2D(target glbase.Enum, level int, internalFormat glbase.Enum, x, y, width, height, border int) {
+ C.gles2_glCopyTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLenum(internalFormat), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height), C.GLint(border))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCopyTexSubImage2D.xml
+func (gl *GL) CopyTexSubImage2D(target glbase.Enum, level, xoffset, yoffset, x, y, width, height int) {
+ C.gles2_glCopyTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glCullFace.xml
+func (gl *GL) CullFace(mode glbase.Enum) {
+ C.gles2_glCullFace(gl.funcs, C.GLenum(mode))
+}
+
+// DeleteTextures deletes the textures objects whose names are stored
+// in the textures slice. After a texture is deleted, it has no contents or
+// dimensionality, and its name is free for reuse (for example by
+// GenTextures). If a texture that is currently bound is deleted, the binding
+// reverts to 0 (the default texture).
+//
+// DeleteTextures silently ignores 0's and names that do not correspond to
+// existing textures.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// DeleteTextures is available in GL version 2.0 or greater.
+func (gl *GL) DeleteTextures(textures []glbase.Texture) {
+ n := len(textures)
+ if n == 0 {
+ return
+ }
+ C.gles2_glDeleteTextures(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDepthFunc.xml
+func (gl *GL) DepthFunc(glfunc glbase.Enum) {
+ C.gles2_glDepthFunc(gl.funcs, C.GLenum(glfunc))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDepthMask.xml
+func (gl *GL) DepthMask(flag bool) {
+ C.gles2_glDepthMask(gl.funcs, *(*C.GLboolean)(unsafe.Pointer(&flag)))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDisable.xml
+func (gl *GL) Disable(cap glbase.Enum) {
+ C.gles2_glDisable(gl.funcs, C.GLenum(cap))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDrawArrays.xml
+func (gl *GL) DrawArrays(mode glbase.Enum, first, count int) {
+ C.gles2_glDrawArrays(gl.funcs, C.GLenum(mode), C.GLint(first), C.GLsizei(count))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glDrawElements.xml
+func (gl *GL) DrawElements(mode glbase.Enum, count int, gltype glbase.Enum, indices interface{}) {
+ var indices_ptr unsafe.Pointer
+ var indices_v = reflect.ValueOf(indices)
+ if indices != nil && indices_v.Kind() != reflect.Slice {
+ panic("parameter indices must be a slice")
+ }
+ if indices != nil {
+ indices_ptr = unsafe.Pointer(indices_v.Index(0).Addr().Pointer())
+ }
+ C.gles2_glDrawElements(gl.funcs, C.GLenum(mode), C.GLsizei(count), C.GLenum(gltype), indices_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glEnable.xml
+func (gl *GL) Enable(cap glbase.Enum) {
+ C.gles2_glEnable(gl.funcs, C.GLenum(cap))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFinish.xml
+func (gl *GL) Finish() {
+ C.gles2_glFinish(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFlush.xml
+func (gl *GL) Flush() {
+ C.gles2_glFlush(gl.funcs)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glFrontFace.xml
+func (gl *GL) FrontFace(mode glbase.Enum) {
+ C.gles2_glFrontFace(gl.funcs, C.GLenum(mode))
+}
+
+// GenTextures returns n texture names in textures. There is no guarantee
+// that the names form a contiguous set of integers; however, it is
+// guaranteed that none of the returned names was in use immediately before
+// the call to GenTextures.
+//
+// The generated textures have no dimensionality; they assume the
+// dimensionality of the texture target to which they are first bound (see
+// BindTexture).
+//
+// Texture names returned by a call to GenTextures are not returned by
+// subsequent calls, unless they are first deleted with DeleteTextures.
+//
+// Error GL.INVALID_VALUE is generated if n is negative.
+//
+// GenTextures is available in GL version 2.0 or greater.
+func (gl *GL) GenTextures(n int) []glbase.Texture {
+ if n == 0 {
+ return nil
+ }
+ textures := make([]glbase.Texture, n)
+ C.gles2_glGenTextures(gl.funcs, C.GLsizei(n), (*C.GLuint)(unsafe.Pointer(&textures[0])))
+ return textures
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetBooleanv.xml
+func (gl *GL) GetBooleanv(pname glbase.Enum, params []bool) {
+ C.gles2_glGetBooleanv(gl.funcs, C.GLenum(pname), (*C.GLboolean)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetError.xml
+func (gl *GL) GetError() glbase.Enum {
+ glresult := C.gles2_glGetError(gl.funcs)
+ return glbase.Enum(glresult)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetFloatv.xml
+func (gl *GL) GetFloatv(pname glbase.Enum, params []float32) {
+ C.gles2_glGetFloatv(gl.funcs, C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetIntegerv.xml
+func (gl *GL) GetIntegerv(pname glbase.Enum, params []int32) {
+ C.gles2_glGetIntegerv(gl.funcs, C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexParameterfv.xml
+func (gl *GL) GetTexParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gles2_glGetTexParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glGetTexParameteriv.xml
+func (gl *GL) GetTexParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gles2_glGetTexParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glHint.xml
+func (gl *GL) Hint(target, mode glbase.Enum) {
+ C.gles2_glHint(gl.funcs, C.GLenum(target), C.GLenum(mode))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIsEnabled.xml
+func (gl *GL) IsEnabled(cap glbase.Enum) bool {
+ glresult := C.gles2_glIsEnabled(gl.funcs, C.GLenum(cap))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glIsTexture.xml
+func (gl *GL) IsTexture(texture glbase.Texture) bool {
+ glresult := C.gles2_glIsTexture(gl.funcs, C.GLuint(texture))
+ return *(*bool)(unsafe.Pointer(&glresult))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glLineWidth.xml
+func (gl *GL) LineWidth(width float32) {
+ C.gles2_glLineWidth(gl.funcs, C.GLfloat(width))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPixelStorei.xml
+func (gl *GL) PixelStorei(pname glbase.Enum, param int32) {
+ C.gles2_glPixelStorei(gl.funcs, C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glPolygonOffset.xml
+func (gl *GL) PolygonOffset(factor, units float32) {
+ C.gles2_glPolygonOffset(gl.funcs, C.GLfloat(factor), C.GLfloat(units))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glReadPixels.xml
+func (gl *GL) ReadPixels(x, y, width, height int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gles2_glReadPixels(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glScissor.xml
+func (gl *GL) Scissor(x, y, width, height int) {
+ C.gles2_glScissor(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glStencilFunc.xml
+func (gl *GL) StencilFunc(glfunc glbase.Enum, ref int32, mask uint32) {
+ C.gles2_glStencilFunc(gl.funcs, C.GLenum(glfunc), C.GLint(ref), C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glStencilMask.xml
+func (gl *GL) StencilMask(mask uint32) {
+ C.gles2_glStencilMask(gl.funcs, C.GLuint(mask))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glStencilOp.xml
+func (gl *GL) StencilOp(fail, zfail, zpass glbase.Enum) {
+ C.gles2_glStencilOp(gl.funcs, C.GLenum(fail), C.GLenum(zfail), C.GLenum(zpass))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexImage2D.xml
+func (gl *GL) TexImage2D(target glbase.Enum, level int, internalFormat int32, width, height, border int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gles2_glTexImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(internalFormat), C.GLsizei(width), C.GLsizei(height), C.GLint(border), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexParameterf.xml
+func (gl *GL) TexParameterf(target, pname glbase.Enum, param float32) {
+ C.gles2_glTexParameterf(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLfloat(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexParameterfv.xml
+func (gl *GL) TexParameterfv(target, pname glbase.Enum, params []float32) {
+ C.gles2_glTexParameterfv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLfloat)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexParameteri.xml
+func (gl *GL) TexParameteri(target, pname glbase.Enum, param int32) {
+ C.gles2_glTexParameteri(gl.funcs, C.GLenum(target), C.GLenum(pname), C.GLint(param))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexParameteriv.xml
+func (gl *GL) TexParameteriv(target, pname glbase.Enum, params []int32) {
+ C.gles2_glTexParameteriv(gl.funcs, C.GLenum(target), C.GLenum(pname), (*C.GLint)(unsafe.Pointer(&params[0])))
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glTexSubImage2D.xml
+func (gl *GL) TexSubImage2D(target glbase.Enum, level, xoffset, yoffset, width, height int, format, gltype glbase.Enum, pixels interface{}) {
+ var pixels_ptr unsafe.Pointer
+ var pixels_v = reflect.ValueOf(pixels)
+ if pixels != nil && pixels_v.Kind() != reflect.Slice {
+ panic("parameter pixels must be a slice")
+ }
+ if pixels != nil {
+ pixels_ptr = unsafe.Pointer(pixels_v.Index(0).Addr().Pointer())
+ }
+ C.gles2_glTexSubImage2D(gl.funcs, C.GLenum(target), C.GLint(level), C.GLint(xoffset), C.GLint(yoffset), C.GLsizei(width), C.GLsizei(height), C.GLenum(format), C.GLenum(gltype), pixels_ptr)
+}
+
+// https://www.opengl.org/sdk/docs/man2/xhtml/glViewport.xml
+func (gl *GL) Viewport(x, y, width, height int) {
+ C.gles2_glViewport(gl.funcs, C.GLint(x), C.GLint(y), C.GLsizei(width), C.GLsizei(height))
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/gengl/Makefile b/Godeps/_workspace/src/github.com/obscuren/qml/gl/gengl/Makefile
new file mode 100644
index 000000000..f814cceb1
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/gengl/Makefile
@@ -0,0 +1,9 @@
+
+gengl: main.go parseqt.go
+ go build
+
+%.go: %.rl
+ ragel -Z -G2 -o $@ $<
+
+run: gengl
+ ./gengl
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/gengl/funcs.go b/Godeps/_workspace/src/github.com/obscuren/qml/gl/gengl/funcs.go
new file mode 100644
index 000000000..994a3e91b
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/gengl/funcs.go
@@ -0,0 +1,1764 @@
+package main
+
+type funcTweak struct {
+ // name specifies the name of the Go function to be tweaked.
+ name string
+
+ // copy copies all the definitions for this function tweak from the named
+ // function. Templates are parsed under the new context.
+ copy string
+
+ // params specifies a map of zero or more tweaks for specific parameters.
+ params paramTweaks
+
+ // result defines the function result as presented at the end of the func line.
+ // Simple type changes are handled automatically. More involved multi-value
+ // results will require an appropriate after snippet to handle the return.
+ result string
+
+ // before is a code snippet to be injected before the C function call.
+ // It may use the following template variables and functions:
+ //
+ // . - dot holds the Func being tweaked
+ // {{copyDoc "Func"}} - replaced by the respective function documentation
+ // {{paramGoType . "param"}} - replaced by the respective parameter Go type
+ //
+ before string
+
+ // after is a code snippet to be injected after the C function call.
+ // It may use the same template functions as available for before.
+ after string
+
+ // doc defines the documentation for the function. It may use the same
+ // template functions as available for before and after.
+ doc string
+}
+
+type paramTweak struct {
+ // rename changes the parameter name in the Go function while keeping the C
+ // function call unchanged. The before snippet must define a proper variable
+ // to be used under the original name.
+ rename string
+
+ // replace changes the parameter name in the C function call to a variable
+ // named "<original name>_c", while keeping the Go parameter name unchanged.
+ // The before and after snippets must manipulate the two values as needed.
+ replace bool
+
+ // retype changes the Go parameter type.
+ retype string
+
+ // output flags the parameter as an output parameter, which causes it to be
+ // omitted from the input parameter list and added to the result list.
+ output bool
+
+ // unnamed causes the name of a result parameter to be omitted if possible.
+ unnamed bool
+
+ // single flags the parameter as carrying a single value rather than a slice,
+ // when the parameter is originally defined as a pointer.
+ single bool
+
+ // omit drops the parameter from the Go function. The before snippet must
+ // define a variable with the proper name for the C function call to use.
+ omit bool
+}
+
+type paramTweaks map[string]paramTweak
+
+var paramNameFixes = map[string]string{
+ "binaryformat": "binaryFormat",
+ "bufsize": "bufSize",
+ "indx": "index",
+ "infolog": "infoLog",
+ "internalformat": "internalFormat",
+ "precisiontype": "precisionType",
+ "ptr": "pointer",
+}
+
+var funcTweakList = []funcTweak{{
+ name: "Accum",
+ doc: `
+ executes an operation on the accumulation buffer.
+
+ Parameter op defines the accumulation buffer operation (GL.ACCUM, GL.LOAD,
+ GL.ADD, GL.MULT, or GL.RETURN) and specifies how the value parameter is
+ used.
+
+ The accumulation buffer is an extended-range color buffer. Images are not
+ rendered into it. Rather, images rendered into one of the color buffers
+ are added to the contents of the accumulation buffer after rendering.
+ Effects such as antialiasing (of points, lines, and polygons), motion
+ blur, and depth of field can be created by accumulating images generated
+ with different transformation matrices.
+
+ Each pixel in the accumulation buffer consists of red, green, blue, and
+ alpha values. The number of bits per component in the accumulation buffer
+ depends on the implementation. You can examine this number by calling
+ GetIntegerv four times, with arguments GL.ACCUM_RED_BITS,
+ GL.ACCUM_GREEN_BITS, GL.ACCUM_BLUE_BITS, and GL.ACCUM_ALPHA_BITS.
+ Regardless of the number of bits per component, the range of values stored
+ by each component is (-1, 1). The accumulation buffer pixels are mapped
+ one-to-one with frame buffer pixels.
+
+ All accumulation buffer operations are limited to the area of the current
+ scissor box and applied identically to the red, green, blue, and alpha
+ components of each pixel. If a Accum operation results in a value outside
+ the range (-1, 1), the contents of an accumulation buffer pixel component
+ are undefined.
+
+ The operations are as follows:
+
+ GL.ACCUM
+ Obtains R, G, B, and A values from the buffer currently selected for
+ reading (see ReadBuffer). Each component value is divided by 2 n -
+ 1 , where n is the number of bits allocated to each color component
+ in the currently selected buffer. The result is a floating-point
+ value in the range 0 1 , which is multiplied by value and added to
+ the corresponding pixel component in the accumulation buffer,
+ thereby updating the accumulation buffer.
+
+ GL.LOAD
+ Similar to GL.ACCUM, except that the current value in the
+ accumulation buffer is not used in the calculation of the new value.
+ That is, the R, G, B, and A values from the currently selected
+ buffer are divided by 2 n - 1 , multiplied by value, and then stored
+ in the corresponding accumulation buffer cell, overwriting the
+ current value.
+
+ GL.ADD
+ Adds value to each R, G, B, and A in the accumulation buffer.
+
+ GL.MULT
+ Multiplies each R, G, B, and A in the accumulation buffer by value
+ and returns the scaled component to its corresponding accumulation
+ buffer location.
+
+ GL.RETURN
+ Transfers accumulation buffer values to the color buffer or buffers
+ currently selected for writing. Each R, G, B, and A component is
+ multiplied by value, then multiplied by 2 n - 1 , clamped to the
+ range 0 2 n - 1 , and stored in the corresponding display buffer
+ cell. The only fragment operations that are applied to this transfer
+ are pixel ownership, scissor, dithering, and color writemasks.
+
+ To clear the accumulation buffer, call ClearAccum with R, G, B, and A
+ values to set it to, then call Clear with the accumulation buffer
+ enabled.
+
+ Error GL.INVALID_ENUM is generated if op is not an accepted value.
+ GL.INVALID_OPERATION is generated if there is no accumulation buffer.
+ GL.INVALID_OPERATION is generated if Accum is executed between the
+ execution of Begin and the corresponding execution of End.
+ `,
+}, {
+ name: "AttachShader",
+ doc: `
+ attaches a shader object to a program object.
+
+ In order to create an executable, there must be a way to specify the list
+ of things that will be linked together. Program objects provide this
+ mechanism. Shaders that are to be linked together in a program object must
+ first be attached to that program object. This indicates that shader will
+ be included in link operations that will be performed on program.
+
+ All operations that can be performed on a shader object are valid whether
+ or not the shader object is attached to a program object. It is
+ permissible to attach a shader object to a program object before source
+ code has been loaded into the shader object or before the shader object
+ has been compiled. It is permissible to attach multiple shader objects of
+ the same type because each may contain a portion of the complete shader.
+ It is also permissible to attach a shader object to more than one program
+ object. If a shader object is deleted while it is attached to a program
+ object, it will be flagged for deletion, and deletion will not occur until
+ DetachShader is called to detach it from all program objects to which it
+ is attached.
+
+ Error GL.INVALID_VALUE is generated if either program or shader is not a
+ value generated by OpenGL. GL.INVALID_OPERATION is generated if program
+ is not a program object. GL.INVALID_OPERATION is generated if shader is
+ not a shader object. GL.INVALID_OPERATION is generated if shader is
+ already attached to program. GL.INVALID_OPERATION is generated if
+ AttachShader is executed between the execution of Begin and the
+ corresponding execution of End.
+
+ {{funcSince . "2.0+"}}
+ `,
+}, {
+ name: "BindAttribLocation",
+ params: paramTweaks{
+ "name": {retype: "string"},
+ },
+ doc: `
+ associates a user-defined attribute variable in the program
+ object specified by program with a generic vertex attribute index. The name
+ parameter specifies the name of the vertex shader attribute variable to
+ which index is to be bound. When program is made part of the current state,
+ values provided via the generic vertex attribute index will modify the
+ value of the user-defined attribute variable specified by name.
+
+ If name refers to a matrix attribute variable, index refers to the first
+ column of the matrix. Other matrix columns are then automatically bound to
+ locations index+1 for a matrix of type mat2; index+1 and index+2 for a
+ matrix of type mat3; and index+1, index+2, and index+3 for a matrix of
+ type mat4.
+
+ This command makes it possible for vertex shaders to use descriptive names
+ for attribute variables rather than generic variables that are numbered
+ from 0 to GL.MAX_VERTEX_ATTRIBS-1. The values sent to each generic
+ attribute index are part of current state, just like standard vertex
+ attributes such as color, normal, and vertex position. If a different
+ program object is made current by calling UseProgram, the generic vertex
+ attributes are tracked in such a way that the same values will be observed
+ by attributes in the new program object that are also bound to index.
+
+ Attribute variable name-to-generic attribute index bindings for a program
+ object can be explicitly assigned at any time by calling
+ BindAttribLocation. Attribute bindings do not go into effect until
+ LinkProgram is called. After a program object has been linked
+ successfully, the index values for generic attributes remain fixed (and
+ their values can be queried) until the next link command occurs.
+
+ Applications are not allowed to bind any of the standard OpenGL vertex
+ attributes using this command, as they are bound automatically when
+ needed. Any attribute binding that occurs after the program object has
+ been linked will not take effect until the next time the program object is
+ linked.
+
+ If name was bound previously, that information is lost. Thus you cannot
+ bind one user-defined attribute variable to multiple indices, but you can
+ bind multiple user-defined attribute variables to the same index.
+
+ Applications are allowed to bind more than one user-defined attribute
+ variable to the same generic vertex attribute index. This is called
+ aliasing, and it is allowed only if just one of the aliased attributes is
+ active in the executable program, or if no path through the shader
+ consumes more than one attribute of a set of attributes aliased to the
+ same location. The compiler and linker are allowed to assume that no
+ aliasing is done and are free to employ optimizations that work only in
+ the absence of aliasing. OpenGL implementations are not required to do
+ error checking to detect aliasing. Because there is no way to bind
+ standard attributes, it is not possible to alias generic attributes with
+ conventional ones (except for generic attribute 0).
+
+ BindAttribLocation can be called before any vertex shader objects are
+ bound to the specified program object. It is also permissible to bind a
+ generic attribute index to an attribute variable name that is never used
+ in a vertex shader.
+
+ Active attributes that are not explicitly bound will be bound by the
+ linker when LinkProgram is called. The locations assigned can be queried
+ by calling GetAttribLocation.
+
+ Error GL.INVALID_VALUE is generated if index is greater than or equal to
+ GL.MAX_VERTEX_ATTRIBS.
+ GL.INVALID_OPERATION is generated if name starts with the reserved prefix "gl_".
+ GL.INVALID_VALUE is generated if program is not a value generated by OpenGL.
+ GL.INVALID_OPERATION is generated if program is not a program object.
+ GL.INVALID_OPERATION is generated if BindAttribLocation is executed
+ between the execution of Begin and the corresponding execution of End.
+
+ {{funcSince . "2.0+"}}
+ `,
+}, {
+ name: "BindBuffer",
+ doc: `
+ creates or puts in use a named buffer object.
+ Calling BindBuffer with target set to GL.ARRAY_BUFFER,
+ GL.ELEMENT_ARRAY_BUFFER, GL.PIXEL_PACK_BUFFER or GL.PIXEL_UNPACK_BUFFER
+ and buffer set to the name of the new buffer object binds the buffer
+ object name to the target. When a buffer object is bound to a target, the
+ previous binding for that target is automatically broken.
+
+ Buffer object names are unsigned integers. The value zero is reserved, but
+ there is no default buffer object for each buffer object target. Instead,
+ buffer set to zero effectively unbinds any buffer object previously bound,
+ and restores client memory usage for that buffer object target. Buffer
+ object names and the corresponding buffer object contents are local to the
+ shared display-list space (see XCreateContext) of the current GL rendering
+ context; two rendering contexts share buffer object names only if they
+ also share display lists.
+
+ GenBuffers may be called to generate a set of new buffer object names.
+
+ The state of a buffer object immediately after it is first bound is an
+ unmapped zero-sized memory buffer with GL.READ_WRITE access and
+ GL.STATIC_DRAW usage.
+
+ While a non-zero buffer object name is bound, GL operations on the target
+ to which it is bound affect the bound buffer object, and queries of the
+ target to which it is bound return state from the bound buffer object.
+ While buffer object name zero is bound, as in the initial state, attempts
+ to modify or query state on the target to which it is bound generates an
+ GL.INVALID_OPERATION error.
+
+ When vertex array pointer state is changed, for example by a call to
+ NormalPointer, the current buffer object binding (GL.ARRAY_BUFFER_BINDING)
+ is copied into the corresponding client state for the vertex array type
+ being changed, for example GL.NORMAL_ARRAY_BUFFER_BINDING. While a
+ non-zero buffer object is bound to the GL.ARRAY_BUFFER target, the vertex
+ array pointer parameter that is traditionally interpreted as a pointer to
+ client-side memory is instead interpreted as an offset within the buffer
+ object measured in basic machine units.
+
+ While a non-zero buffer object is bound to the GL.ELEMENT_ARRAY_BUFFER
+ target, the indices parameter of DrawElements, DrawRangeElements, or
+ MultiDrawElements that is traditionally interpreted as a pointer to
+ client-side memory is instead interpreted as an offset within the buffer
+ object measured in basic machine units.
+
+ While a non-zero buffer object is bound to the GL.PIXEL_PACK_BUFFER
+ target, the following commands are affected: GetCompressedTexImage,
+ GetConvolutionFilter, GetHistogram, GetMinmax, GetPixelMap,
+ GetPolygonStipple, GetSeparableFilter, GetTexImage, and ReadPixels. The
+ pointer parameter that is traditionally interpreted as a pointer to
+ client-side memory where the pixels are to be packed is instead
+ interpreted as an offset within the buffer object measured in basic
+ machine units.
+
+ While a non-zero buffer object is bound to the GL.PIXEL_UNPACK_BUFFER
+ target, the following commands are affected: Bitmap, ColorSubTable,
+ ColorTable, CompressedTexImage1D, CompressedTexImage2D,
+ CompressedTexImage3D, CompressedTexSubImage1D, CompressedTexSubImage2D,
+ CompressedTexSubImage3D, ConvolutionFilter1D, ConvolutionFilter2D,
+ DrawPixels, PixelMap, PolygonStipple, SeparableFilter2D, TexImage1D,
+ TexImage2D, TexImage3D, TexSubImage1D, TexSubImage2D, and TexSubImage3D.
+ The pointer parameter that is traditionally interpreted as a pointer to
+ client-side memory from which the pixels are to be unpacked is instead
+ interpreted as an offset within the buffer object measured in basic
+ machine units.
+
+ A buffer object binding created with BindBuffer remains active until a
+ different buffer object name is bound to the same target, or until the
+ bound buffer object is deleted with DeleteBuffers.
+
+ Once created, a named buffer object may be re-bound to any target as often
+ as needed. However, the GL implementation may make choices about how to
+ optimize the storage of a buffer object based on its initial binding
+ target.
+
+ Error GL.INVALID_ENUM is generated if target is not one of the allowable
+ values. GL.INVALID_OPERATION is generated if BindBuffer is executed
+ between the execution of Begin and the corresponding execution of End.
+
+ {{funcSince . "1.5+"}}
+ `,
+}, {
+ name: "BufferData",
+ before: `
+ if data != nil {
+ size = int(data_v.Type().Size()) * data_v.Len()
+ }
+ `,
+ doc: `
+ creates a new data store for the buffer object currently
+ bound to target. Any pre-existing data store is deleted. The new data
+ store is created with the specified size in bytes and usage. If data is
+ not nil, it must be a slice that is used to initialize the data store.
+ In that case the size parameter is ignored and the store size will match
+ the slice data size.
+
+ In its initial state, the new data store is not mapped, it has a NULL
+ mapped pointer, and its mapped access is GL.READ_WRITE.
+
+ The target constant must be one of GL.ARRAY_BUFFER, GL.COPY_READ_BUFFER,
+ GL.COPY_WRITE_BUFFER, GL.ELEMENT_ARRAY_BUFFER, GL.PIXEL_PACK_BUFFER,
+ GL.PIXEL_UNPACK_BUFFER, GL.TEXTURE_BUFFER, GL.TRANSFORM_FEEDBACK_BUFFER,
+ or GL.UNIFORM_BUFFER.
+
+ The usage parameter is a hint to the GL implementation as to how a buffer
+ object's data store will be accessed. This enables the GL implementation
+ to make more intelligent decisions that may significantly impact buffer
+ object performance. It does not, however, constrain the actual usage of
+ the data store. usage can be broken down into two parts: first, the
+ frequency of access (modification and usage), and second, the nature of
+ that access.
+
+ A usage frequency of STREAM and nature of DRAW is specified via the
+ constant GL.STREAM_DRAW, for example.
+
+ The usage frequency of access may be one of:
+
+ STREAM
+ The data store contents will be modified once and used at most a few times.
+
+ STATIC
+ The data store contents will be modified once and used many times.
+
+ DYNAMIC
+ The data store contents will be modified repeatedly and used many times.
+
+ The usage nature of access may be one of:
+
+ DRAW
+ The data store contents are modified by the application, and used as
+ the source for GL drawing and image specification commands.
+
+ READ
+ The data store contents are modified by reading data from the GL,
+ and used to return that data when queried by the application.
+
+ COPY
+ The data store contents are modified by reading data from the GL,
+ and used as the source for GL drawing and image specification
+ commands.
+
+ Clients must align data elements consistent with the requirements of the
+ client platform, with an additional base-level requirement that an offset
+ within a buffer to a datum comprising N bytes be a multiple of N.
+
+ Error GL.INVALID_ENUM is generated if target is not one of the accepted
+ buffer targets. GL.INVALID_ENUM is generated if usage is not
+ GL.STREAM_DRAW, GL.STREAM_READ, GL.STREAM_COPY, GL.STATIC_DRAW,
+ GL.STATIC_READ, GL.STATIC_COPY, GL.DYNAMIC_DRAW, GL.DYNAMIC_READ, or
+ GL.DYNAMIC_COPY. GL.INVALID_VALUE is generated if size is negative.
+ GL.INVALID_OPERATION is generated if the reserved buffer object name 0 is
+ bound to target. GL.OUT_OF_MEMORY is generated if the GL is unable to
+ create a data store with the specified size.
+ `,
+}, {
+ name: "CompileShader",
+ doc: `
+ compiles the source code strings that have been stored in
+ the shader object specified by shader.
+
+ The compilation status will be stored as part of the shader object's
+ state. This value will be set to GL.TRUE if the shader was compiled without
+ errors and is ready for use, and GL.FALSE otherwise. It can be queried by
+ calling GetShaderiv with arguments shader and GL.COMPILE_STATUS.
+
+ Compilation of a shader can fail for a number of reasons as specified by
+ the OpenGL Shading Language Specification. Whether or not the compilation
+ was successful, information about the compilation can be obtained from the
+ shader object's information log by calling GetShaderInfoLog.
+
+ Error GL.INVALID_VALUE is generated if shader is not a value generated by
+ OpenGL. GL.INVALID_OPERATION is generated if shader is not a shader
+ object. GL.INVALID_OPERATION is generated if CompileShader is executed
+ between the execution of Begin and the corresponding execution of End.
+
+ {{funcSince . "2.0+"}}
+ `,
+}, {
+ name: "CreateProgram",
+ result: "glbase.Program",
+ doc: `
+ creates an empty program object and returns a non-zero
+ value by which it can be referenced. A program object is an object to
+ which shader objects can be attached. This provides a mechanism to specify
+ the shader objects that will be linked to create a program. It also
+ provides a means for checking the compatibility of the shaders that will
+ be used to create a program (for instance, checking the compatibility
+ between a vertex shader and a fragment shader). When no longer needed as
+ part of a program object, shader objects can be detached.
+
+ One or more executables are created in a program object by successfully
+ attaching shader objects to it with AttachShader, successfully compiling
+ the shader objects with CompileShader, and successfully linking the
+ program object with LinkProgram. These executables are made part of
+ current state when UseProgram is called. Program objects can be deleted
+ by calling DeleteProgram. The memory associated with the program object
+ will be deleted when it is no longer part of current rendering state for
+ any context.
+
+ Like display lists and texture objects, the name space for program objects
+ may be shared across a set of contexts, as long as the server sides of the
+ contexts share the same address space. If the name space is shared across
+ contexts, any attached objects and the data associated with those attached
+ objects are shared as well.
+
+ Applications are responsible for providing the synchronization across API
+ calls when objects are accessed from different execution threads.
+
+ This function returns 0 if an error occurs creating the program object.
+
+ Error GL.INVALID_OPERATION is generated if CreateProgram is executed
+ between the execution of Begin and the corresponding execution of End.
+
+ {{funcSince . "2.0+"}}
+ `,
+}, {
+ name: "CreateShader",
+ result: "glbase.Shader",
+ doc: `
+ creates an empty shader object and returns a non-zero value
+ by which it can be referenced. A shader object is used to maintain the
+ source code strings that define a shader. shaderType indicates the type of
+ shader to be created.
+
+ Two types of shaders are supported. A shader of type GL.VERTEX_SHADER is a
+ shader that is intended to run on the programmable vertex processor and
+ replace the fixed functionality vertex processing in OpenGL. A shader of
+ type GL.FRAGMENT_SHADER is a shader that is intended to run on the
+ programmable fragment processor and replace the fixed functionality
+ fragment processing in OpenGL.
+
+ When created, a shader object's GL.SHADER_TYPE parameter is set to either
+ GL.VERTEX_SHADER or GL.FRAGMENT_SHADER, depending on the value of
+ shaderType.
+
+ Like display lists and texture objects, the name space for shader objects
+ may be shared across a set of contexts, as long as the server sides of the
+ contexts share the same address space. If the name space is shared across
+ contexts, any attached objects and the data associated with those attached
+ objects are shared as well.
+
+ This function returns 0 if an error occurs creating the shader object.
+
+ Error GL.INVALID_ENUM is generated if shaderType is not an accepted value.
+ GL.INVALID_OPERATION is generated if CreateShader is executed between the
+ execution of Begin and the corresponding execution of End.
+
+ {{funcSince . "2.0+"}}
+ `,
+}, {
+ name: "DeleteBuffers",
+ params: paramTweaks{
+ "n": {omit: true},
+ },
+ before: `
+ n := len(buffers)
+ if n == 0 { return }
+ `,
+ doc: `
+ deletes the buffer objects whose names are stored in the
+ buffers slice.
+
+ After a buffer object is deleted, it has no contents, and its name is free
+ for reuse (for example by GenBuffers). If a buffer object that is
+ currently bound is deleted, the binding reverts to 0 (the absence of any
+ buffer object, which reverts to client memory usage).
+
+ DeleteBuffers silently ignores 0's and names that do not correspond to
+ existing buffer objects.
+
+ Error GL.INVALID_VALUE is generated if n is negative. GL.INVALID_OPERATION
+ is generated if DeleteBuffers is executed between the execution of Begin
+ and the corresponding execution of End.
+
+ {{funcSince . "1.5+"}}
+ `,
+}, {
+ name: "DeleteFramebuffers",
+ params: paramTweaks{
+ "n": {omit: true},
+ },
+ before: `
+ n := len(framebuffers)
+ if n == 0 { return }
+ `,
+ doc: `
+ deletes the framebuffer objects whose names are
+ stored in the framebuffers slice. The name zero is reserved by the GL and
+ is silently ignored, should it occur in framebuffers, as are other unused
+ names. Once a framebuffer object is deleted, its name is again unused and
+ it has no attachments. If a framebuffer that is currently bound to one or
+ more of the targets GL.DRAW_FRAMEBUFFER or GL.READ_FRAMEBUFFER is deleted,
+ it is as though BindFramebuffer had been executed with the corresponding
+ target and framebuffer zero.
+
+ Error GL.INVALID_VALUE is generated if n is negative.
+
+ {{funcSince . "3.0+"}}
+ `,
+}, {
+ name: "DeleteProgram",
+ doc: `
+ frees the memory and invalidates the name associated with
+ the program object specified by program. This command effectively undoes
+ the effects of a call to CreateProgram.
+
+ If a program object is in use as part of current rendering state, it will
+ be flagged for deletion, but it will not be deleted until it is no longer
+ part of current state for any rendering context. If a program object to be
+ deleted has shader objects attached to it, those shader objects will be
+ automatically detached but not deleted unless they have already been
+ flagged for deletion by a previous call to DeleteShader. A value of 0
+ for program will be silently ignored.
+
+ To determine whether a program object has been flagged for deletion, call
+ GetProgram with arguments program and GL.DELETE_STATUS.
+
+ Error GL.INVALID_VALUE is generated if program is not a value generated by
+ OpenGL.
+
+ {{funcSince . "2.0+"}}
+ `,
+}, {
+ name: "DeleteRenderbuffers",
+ params: paramTweaks{
+ "n": {omit: true},
+ },
+ before: `
+ n := len(renderbuffers)
+ if n == 0 { return }
+ `,
+ doc: `
+ deletes the renderbuffer objects whose names are stored
+ in the renderbuffers slice. The name zero is reserved by the GL and
+ is silently ignored, should it occur in renderbuffers, as are other unused
+ names. Once a renderbuffer object is deleted, its name is again unused and
+ it has no contents. If a renderbuffer that is currently bound to the
+ target GL.RENDERBUFFER is deleted, it is as though BindRenderbuffer had
+ been executed with a target of GL.RENDERBUFFER and a name of zero.
+
+ If a renderbuffer object is attached to one or more attachment points in
+ the currently bound framebuffer, then it as if FramebufferRenderbuffer
+ had been called, with a renderbuffer of zero for each attachment point to
+ which this image was attached in the currently bound framebuffer. In other
+ words, this renderbuffer object is first detached from all attachment
+ ponits in the currently bound framebuffer. Note that the renderbuffer
+ image is specifically not detached from any non-bound framebuffers.
+
+ Error GL.INVALID_VALUE is generated if n is negative.
+
+ {{funcSince . "3.0+"}}
+ `,
+}, {
+ name: "DeleteShader",
+ doc: `
+ frees the memory and invalidates the name associated with
+ the shader object specified by shader. This command effectively undoes the
+ effects of a call to CreateShader.
+
+ If a shader object to be deleted is attached to a program object, it will
+ be flagged for deletion, but it will not be deleted until it is no longer
+ attached to any program object, for any rendering context (it must
+ be detached from wherever it was attached before it will be deleted). A
+ value of 0 for shader will be silently ignored.
+
+ To determine whether an object has been flagged for deletion, call
+ GetShader with arguments shader and GL.DELETE_STATUS.
+
+ Error GL.INVALID_VALUE is generated if shader is not a value generated by
+ OpenGL.
+
+ {{funcSince . "2.0+"}}
+ `,
+}, {
+ name: "DeleteTextures",
+ params: paramTweaks{
+ "n": {omit: true},
+ },
+ before: `
+ n := len(textures)
+ if n == 0 { return }
+ `,
+ doc: `
+ deletes the textures objects whose names are stored
+ in the textures slice. After a texture is deleted, it has no contents or
+ dimensionality, and its name is free for reuse (for example by
+ GenTextures). If a texture that is currently bound is deleted, the binding
+ reverts to 0 (the default texture).
+
+ DeleteTextures silently ignores 0's and names that do not correspond to
+ existing textures.
+
+ Error GL.INVALID_VALUE is generated if n is negative.
+
+ {{funcSince . "2.0+"}}
+ `,
+}, {
+ name: "DepthRange",
+ doc: `
+ specifies the mapping of depth values from normalized device
+ coordinates to window coordinates.
+
+ Parameter nearVal specifies the mapping of the near clipping plane to window
+ coordinates (defaults to 0), while farVal specifies the mapping of the far
+ clipping plane to window coordinates (defaults to 1).
+
+ After clipping and division by w, depth coordinates range from -1 to 1,
+ corresponding to the near and far clipping planes. DepthRange specifies a
+ linear mapping of the normalized depth coordinates in this range to window
+ depth coordinates. Regardless of the actual depth buffer implementation,
+ window coordinate depth values are treated as though they range from 0 through 1
+ (like color components). Thus, the values accepted by DepthRange are both
+ clamped to this range before they are accepted.
+
+ The default setting of (0, 1) maps the near plane to 0 and the far plane to 1.
+ With this mapping, the depth buffer range is fully utilized.
+
+ It is not necessary that nearVal be less than farVal. Reverse mappings such as
+ nearVal 1, and farVal 0 are acceptable.
+
+ GL.INVALID_OPERATION is generated if DepthRange is executed between the
+ execution of Begin and the corresponding execution of End.
+ `,
+}, {
+ name: "GenBuffers",
+ params: paramTweaks{
+ "buffers": {output: true, unnamed: true},
+ },
+ before: `
+ if n == 0 { return nil }
+ buffers := make([]glbase.Buffer, n)
+ `,
+ doc: `
+ returns n buffer object names. There is no guarantee that
+ the names form a contiguous set of integers; however, it is guaranteed
+ that none of the returned names was in use immediately before the call to
+ GenBuffers.
+
+ Buffer object names returned by a call to GenBuffers are not returned by
+ subsequent calls, unless they are first deleted with DeleteBuffers.
+
+ No buffer objects are associated with the returned buffer object names
+ until they are first bound by calling BindBuffer.
+
+ Error GL.INVALID_VALUE is generated if n is negative. GL.INVALID_OPERATION
+ is generated if GenBuffers is executed between the execution of Begin
+ and the corresponding execution of End.
+
+ {{funcSince . "1.5+"}}
+ `,
+}, {
+ name: "GenFramebuffers",
+ params: paramTweaks{
+ "framebuffers": {output: true, unnamed: true},
+ },
+ before: `
+ if n == 0 { return nil }
+ framebuffers := make([]glbase.Framebuffer, n)
+ `,
+ doc: `
+ returns n framebuffer object names in ids. There is no
+ guarantee that the names form a contiguous set of integers; however, it is
+ guaranteed that none of the returned names was in use immediately before
+ the call to GenFramebuffers.
+
+ Framebuffer object names returned by a call to GenFramebuffers are not
+ returned by subsequent calls, unless they are first deleted with
+ DeleteFramebuffers.
+
+ The names returned in ids are marked as used, for the purposes of
+ GenFramebuffers only, but they acquire state and type only when they are
+ first bound.
+
+ Error GL.INVALID_VALUE is generated if n is negative.
+ `,
+}, {
+ name: "GenRenderbuffers",
+ params: paramTweaks{
+ "renderbuffers": {output: true, unnamed: true},
+ },
+ before: `
+ if n == 0 { return nil }
+ renderbuffers := make([]glbase.Renderbuffer, n)
+ `,
+ doc: `
+ returns n renderbuffer object names in renderbuffers.
+ There is no guarantee that the names form a contiguous set of integers;
+ however, it is guaranteed that none of the returned names was in use
+ immediately before the call to GenRenderbuffers.
+
+ Renderbuffer object names returned by a call to GenRenderbuffers are not
+ returned by subsequent calls, unless they are first deleted with
+ DeleteRenderbuffers.
+
+ The names returned in renderbuffers are marked as used, for the purposes
+ of GenRenderbuffers only, but they acquire state and type only when they
+ are first bound.
+
+ Error GL.INVALID_VALUE is generated if n is negative.
+
+ {{funcSince . "3.0+"}}
+ `,
+}, {
+ name: "GenTextures",
+ params: paramTweaks{
+ "textures": {output: true, unnamed: true},
+ },
+ before: `
+ if n == 0 { return nil }
+ textures := make([]glbase.Texture, n)
+ `,
+ doc: `
+ returns n texture names in textures. There is no guarantee
+ that the names form a contiguous set of integers; however, it is
+ guaranteed that none of the returned names was in use immediately before
+ the call to GenTextures.
+
+ The generated textures have no dimensionality; they assume the
+ dimensionality of the texture target to which they are first bound (see
+ BindTexture).
+
+ Texture names returned by a call to GenTextures are not returned by
+ subsequent calls, unless they are first deleted with DeleteTextures.
+
+ Error GL.INVALID_VALUE is generated if n is negative.
+
+ {{funcSince . "2.0+"}}
+ `,
+}, {
+ name: "GetAttribLocation",
+ params: paramTweaks{
+ "name": {retype: "string"},
+ },
+ result: "glbase.Attrib",
+ doc: `
+ queries the previously linked program object specified
+ by program for the attribute variable specified by name and returns the
+ index of the generic vertex attribute that is bound to that attribute
+ variable. If name is a matrix attribute variable, the index of the first
+ column of the matrix is returned. If the named attribute variable is not
+ an active attribute in the specified program object or if name starts with
+ the reserved prefix "gl_", a value of -1 is returned.
+
+ The association between an attribute variable name and a generic attribute
+ index can be specified at any time by calling BindAttribLocation.
+ Attribute bindings do not go into effect until LinkProgram is called.
+ After a program object has been linked successfully, the index values for
+ attribute variables remain fixed until the next link command occurs. The
+ attribute values can only be queried after a link if the link was
+ successful. GetAttribLocation returns the binding that actually went
+ into effect the last time LinkProgram was called for the specified
+ program object. Attribute bindings that have been specified since the last
+ link operation are not returned by GetAttribLocation.
+
+ Error GL_INVALID_OPERATION is generated if program is not a value
+ generated by OpenGL. GL_INVALID_OPERATION is generated if program is not
+ a program object. GL_INVALID_OPERATION is generated if program has not
+ been successfully linked. GL_INVALID_OPERATION is generated if
+ GetAttribLocation is executed between the execution of Begin and the
+ corresponding execution of End.
+
+ {{funcSince . "2.0+"}}
+ `,
+}, {
+ name: "GetProgramInfoLog",
+ params: paramTweaks{
+ "bufSize": {omit: true},
+ "length": {omit: true, single: true},
+ "infoLog": {output: true, unnamed: true},
+ },
+ before: `
+ var params [1]int32
+ var length int32
+ gl.GetProgramiv(program, INFO_LOG_LENGTH, params[:])
+ bufSize := params[0]
+ infoLog := make([]byte, int(bufSize))
+ `,
+ doc: `
+ returns the information log for the specified program
+ object. The information log for a program object is modified when the
+ program object is linked or validated.
+
+ The information log for a program object is either an empty string, or a
+ string containing information about the last link operation, or a string
+ containing information about the last validation operation. It may contain
+ diagnostic messages, warning messages, and other information. When a
+ program object is created, its information log will be a string of length
+ 0, and the size of the current log can be obtained by calling GetProgramiv
+ with the value GL.INFO_LOG_LENGTH.
+
+ Error GL.INVALID_VALUE is generated if program is not a value generated
+ by OpenGL. GL.INVALID_OPERATION is generated if program is not a
+ program object.
+ `,
+}, {
+ name: "GetProgramiv",
+ params: paramTweaks{
+ "params": {replace: true},
+ },
+ before: `
+ var params_c [4]{{paramGoType . "params"}}
+ `,
+ after: `
+ copy(params, params_c[:])
+ `,
+ doc: `
+ returns in params the value of a parameter for a specific
+ program object. The following parameters are defined:
+
+ GL.DELETE_STATUS
+ params returns GL.TRUE if program is currently flagged for deletion,
+ and GL.FALSE otherwise.
+
+ GL.LINK_STATUS
+ params returns GL.TRUE if the last link operation on program was
+ successful, and GL.FALSE otherwise.
+
+ GL.VALIDATE_STATUS
+ params returns GL.TRUE or if the last validation operation on
+ program was successful, and GL.FALSE otherwise.
+
+ GL.INFO_LOG_LENGTH
+ params returns the number of characters in the information log for
+ program including the null termination character (the size of
+ the character buffer required to store the information log). If
+ program has no information log, a value of 0 is returned.
+
+ GL.ATTACHED_SHADERS
+ params returns the number of shader objects attached to program.
+
+ GL.ACTIVE_ATTRIBUTES
+ params returns the number of active attribute variables for program.
+
+ GL.ACTIVE_ATTRIBUTE_MAX_LENGTH
+ params returns the length of the longest active attribute name for
+ program, including the null termination character (the size of
+ the character buffer required to store the longest attribute name).
+ If no active attributes exist, 0 is returned.
+
+ GL.ACTIVE_UNIFORMS
+ params returns the number of active uniform variables for program.
+
+ GL.ACTIVE_UNIFORM_MAX_LENGTH
+ params returns the length of the longest active uniform variable
+ name for program, including the null termination character (i.e.,
+ the size of the character buffer required to store the longest
+ uniform variable name). If no active uniform variables exist, 0 is
+ returned.
+
+ GL.TRANSFORM_FEEDBACK_BUFFER_MODE
+ params returns a symbolic constant indicating the buffer mode used
+ when transform feedback is active. This may be GL.SEPARATE_ATTRIBS
+ or GL.INTERLEAVED_ATTRIBS.
+
+ GL.TRANSFORM_FEEDBACK_VARYINGS
+ params returns the number of varying variables to capture in transform
+ feedback mode for the program.
+
+ GL.TRANSFORM_FEEDBACK_VARYING_MAX_LENGTH
+ params returns the length of the longest variable name to be used for
+ transform feedback, including the null-terminator.
+
+ GL.GEOMETRY_VERTICES_OUT
+ params returns the maximum number of vertices that the geometry shader in
+ program will output.
+
+ GL.GEOMETRY_INPUT_TYPE
+ params returns a symbolic constant indicating the primitive type accepted
+ as input to the geometry shader contained in program.
+
+ GL.GEOMETRY_OUTPUT_TYPE
+ params returns a symbolic constant indicating the primitive type that will
+ be output by the geometry shader contained in program.
+
+ GL.ACTIVE_UNIFORM_BLOCKS and GL.ACTIVE_UNIFORM_BLOCK_MAX_NAME_LENGTH are
+ available only if the GL version 3.1 or greater.
+
+ GL.GEOMETRY_VERTICES_OUT, GL.GEOMETRY_INPUT_TYPE and
+ GL.GEOMETRY_OUTPUT_TYPE are accepted only if the GL version is 3.2 or
+ greater.
+
+ Error GL.INVALID_VALUE is generated if program is not a value generated by
+ OpenGL. GL.INVALID_OPERATION is generated if program does not refer to a
+ program object. GL.INVALID_OPERATION is generated if pname is
+ GL.GEOMETRY_VERTICES_OUT, GL.GEOMETRY_INPUT_TYPE, or
+ GL.GEOMETRY_OUTPUT_TYPE, and program does not contain a geometry shader.
+ GL.INVALID_ENUM is generated if pname is not an accepted value.
+ `,
+}, {
+ name: "GetShaderiv",
+ params: paramTweaks{
+ "params": {replace: true},
+ },
+ before: `
+ var params_c [4]{{paramGoType . "params"}}
+ `,
+ after: `
+ copy(params, params_c[:])
+ `,
+ doc: `
+ GetShader returns in params the value of a parameter for a specific
+ shader object. The following parameters are defined:
+
+ GL.SHADER_TYPE
+ params returns GL.VERTEX_SHADER if shader is a vertex shader object,
+ and GL.FRAGMENT_SHADER if shader is a fragment shader object.
+
+ GL.DELETE_STATUS
+ params returns GL.TRUE if shader is currently flagged for deletion,
+ and GL.FALSE otherwise.
+
+ GL.COMPILE_STATUS
+ params returns GL.TRUE if the last compile operation on shader was
+ successful, and GL.FALSE otherwise.
+
+ GL.INFO_LOG_LENGTH
+ params returns the number of characters in the information log for
+ shader including the null termination character (the size of the
+ character buffer required to store the information log). If shader has
+ no information log, a value of 0 is returned.
+
+ GL.SHADER_SOURCE_LENGTH
+ params returns the length of the concatenation of the source strings
+ that make up the shader source for the shader, including the null
+ termination character. (the size of the character buffer
+ required to store the shader source). If no source code exists, 0 is
+ returned.
+
+ Error GL.INVALID_VALUE is generated if shader is not a value generated by
+ OpenGL. GL.INVALID_OPERATION is generated if shader does not refer to a
+ shader object. GL.INVALID_ENUM is generated if pname is not an accepted
+ value. GL.INVALID_OPERATION is generated if GetShader is executed
+ between the execution of Begin and the corresponding execution of End.
+
+ {{funcSince . "2.0+"}}
+ `,
+}, {
+ name: "GetShaderInfoLog",
+ params: paramTweaks{
+ "bufSize": {omit: true},
+ "length": {omit: true, single: true},
+ "infoLog": {output: true, unnamed: true},
+ },
+ before: `
+ var params [1]int32
+ var length int32
+ gl.GetShaderiv(shader, INFO_LOG_LENGTH, params[:])
+ bufSize := params[0]
+ infoLog := make([]byte, int(bufSize))
+ `,
+ doc: `
+ returns the information log for the specified shader
+ object. The information log for a shader object is modified when the
+ shader is compiled.
+
+ The information log for a shader object is a string that may contain
+ diagnostic messages, warning messages, and other information about the
+ last compile operation. When a shader object is created, its information
+ log will be a string of length 0, and the size of the current log can be
+ obtained by calling GetShaderiv with the value GL.INFO_LOG_LENGTH.
+
+ The information log for a shader object is the OpenGL implementer's
+ primary mechanism for conveying information about the compilation process.
+ Therefore, the information log can be helpful to application developers
+ during the development process, even when compilation is successful.
+ Application developers should not expect different OpenGL implementations
+ to produce identical information logs.
+
+ Error GL.INVALID_VALUE is generated if shader is not a value generated by
+ OpenGL. GL.INVALID_OPERATION is generated if shader is not a shader
+ object. GL.INVALID_VALUE is generated if maxLength is less than 0.
+ GL.INVALID_OPERATION is generated if GetShaderInfoLog is executed
+ between the execution of Begin and the corresponding execution of End.
+
+ {{funcSince . "2.0+"}}
+ `,
+}, {
+ name: "GetUniformLocation",
+ params: paramTweaks{
+ "name": {retype: "string"},
+ },
+ result: "glbase.Uniform",
+ doc: `
+ returns an integer that represents the location of a
+ specific uniform variable within a program object. name must be an active
+ uniform variable name in program that is not a structure, an array of
+ structures, or a subcomponent of a vector or a matrix. This function
+ returns -1 if name does not correspond to an active uniform variable in
+ program or if name starts with the reserved prefix "gl_".
+
+ Uniform variables that are structures or arrays of structures may be
+ queried by calling GetUniformLocation for each field within the
+ structure. The array element operator "[]" and the structure field
+ operator "." may be used in name in order to select elements within an
+ array or fields within a structure. The result of using these operators is
+ not allowed to be another structure, an array of structures, or a
+ subcomponent of a vector or a matrix. Except if the last part of name
+ indicates a uniform variable array, the location of the first element of
+ an array can be retrieved by using the name of the array, or by using the
+ name appended by "[0]".
+
+ The actual locations assigned to uniform variables are not known until the
+ program object is linked successfully. After linking has occurred, the
+ command GetUniformLocation can be used to obtain the location of a
+ uniform variable. This location value can then be passed to Uniform to
+ set the value of the uniform variable or to GetUniform in order to query
+ the current value of the uniform variable. After a program object has been
+ linked successfully, the index values for uniform variables remain fixed
+ until the next link command occurs. Uniform variable locations and values
+ can only be queried after a link if the link was successful.
+
+ Error GL.INVALID_VALUE is generated if program is not a value generated by
+ OpenGL. GL.INVALID_OPERATION is generated if program is not a program object.
+ GL.INVALID_OPERATION is generated if program has not been successfully
+ linked. GL.INVALID_OPERATION is generated if GetUniformLocation is executed
+ between the execution of Begin and the corresponding execution of End.
+
+ {{funcSince . "2.0+"}}
+ `,
+}, {
+ name: "GetUniformfv",
+ copy: "GetUniformiv",
+}, {
+ name: "GetUniformiv",
+ params: paramTweaks{
+ "params": {replace: true},
+ },
+ before: `
+ var params_c [4]{{paramGoType . "params"}}
+ `,
+ after: `
+ copy(params, params_c[:])
+ `,
+ doc: `
+ returns in params the value of the specified uniform
+ variable. The type of the uniform variable specified by location
+ determines the number of values returned. If the uniform variable is
+ defined in the shader as a boolean, int, or float, a single value will be
+ returned. If it is defined as a vec2, ivec2, or bvec2, two values will be
+ returned. If it is defined as a vec3, ivec3, or bvec3, three values will
+ be returned, and so on. To query values stored in uniform variables
+ declared as arrays, call {{.GoName}} for each element of the array. To
+ query values stored in uniform variables declared as structures, call
+ {{.GoName}} for each field in the structure. The values for uniform
+ variables declared as a matrix will be returned in column major order.
+
+ The locations assigned to uniform variables are not known until the
+ program object is linked. After linking has occurred, the command
+ GetUniformLocation can be used to obtain the location of a uniform
+ variable. This location value can then be passed to {{.GoName}} in order
+ to query the current value of the uniform variable. After a program object
+ has been linked successfully, the index values for uniform variables
+ remain fixed until the next link command occurs. The uniform variable
+ values can only be queried after a link if the link was successful.
+
+ Error GL.INVALID_VALUE is generated if program is not a value generated by
+ OpenGL. GL.INVALID_OPERATION is generated if program is not a program
+ object. GL.INVALID_OPERATION is generated if program has not been
+ successfully linked. GL.INVALID_OPERATION is generated if location does
+ not correspond to a valid uniform variable location for the specified
+ program object. GL.INVALID_OPERATION is generated if {{.GoName}} is
+ executed between the execution of Begin and the corresponding execution of
+ End.
+
+ {{funcSince . "2.0+"}}
+ `,
+}, {
+ name: "GetVertexAttribdv",
+ copy: "GetVertexAttribiv",
+}, {
+ name: "GetVertexAttribfv",
+ copy: "GetVertexAttribiv",
+}, {
+ name: "GetVertexAttribiv",
+ params: paramTweaks{
+ "params": {replace: true},
+ },
+ before: `
+ var params_c [4]{{paramGoType . "params"}}
+ `,
+ after: `
+ copy(params, params_c[:])
+ `,
+ doc: `
+ returns in params the value of a generic vertex attribute
+ parameter. The generic vertex attribute to be queried is specified by
+ index, and the parameter to be queried is specified by pname.
+
+ The accepted parameter names are as follows:
+
+ GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING
+ params returns a single value, the name of the buffer object
+ currently bound to the binding point corresponding to generic vertex
+ attribute array index. If no buffer object is bound, 0 is returned.
+ The initial value is 0.
+
+ GL.VERTEX_ATTRIB_ARRAY_ENABLED
+ params returns a single value that is non-zero (true) if the vertex
+ attribute array for index is enabled and 0 (false) if it is
+ disabled. The initial value is 0.
+
+ GL.VERTEX_ATTRIB_ARRAY_SIZE
+ params returns a single value, the size of the vertex attribute
+ array for index. The size is the number of values for each element
+ of the vertex attribute array, and it will be 1, 2, 3, or 4. The
+ initial value is 4.
+
+ GL.VERTEX_ATTRIB_ARRAY_STRIDE
+ params returns a single value, the array stride for (number of bytes
+ between successive elements in) the vertex attribute array for
+ index. A value of 0 indicates that the array elements are stored
+ sequentially in memory. The initial value is 0.
+
+ GL.VERTEX_ATTRIB_ARRAY_TYPE
+ params returns a single value, a symbolic constant indicating the
+ array type for the vertex attribute array for index. Possible values
+ are GL.BYTE, GL.UNSIGNED_BYTE, GL.SHORT, GL.UNSIGNED_SHORT, GL.INT,
+ GL.UNSIGNED_INT, GL.FLOAT, and GL.DOUBLE. The initial value is
+ GL.FLOAT.
+
+ GL.VERTEX_ATTRIB_ARRAY_NORMALIZED
+ params returns a single value that is non-zero (true) if fixed-point
+ data types for the vertex attribute array indicated by index are
+ normalized when they are converted to floating point, and 0 (false)
+ otherwise. The initial value is 0.
+
+ GL.CURRENT_VERTEX_ATTRIB
+ params returns four values that represent the current value for the
+ generic vertex attribute specified by index. Generic vertex
+ attribute 0 is unique in that it has no current state, so an error
+ will be generated if index is 0. The initial value for all other
+ generic vertex attributes is (0,0,0,1).
+
+ All of the parameters except GL.CURRENT_VERTEX_ATTRIB represent
+ client-side state.
+
+ Error GL.INVALID_VALUE is generated if index is greater than or equal to
+ GL.MAX_VERTEX_ATTRIBS. GL.INVALID_ENUM is generated if pname is not an
+ accepted value. GL.INVALID_OPERATION is generated if index is 0 and pname
+ is GL.CURRENT_VERTEX_ATTRIB.
+
+ {{funcSince . "2.0+"}}
+ `,
+}, {
+ name: "LinkProgram",
+ doc: `
+ links the program object specified by program. If any shader
+ objects of type GL.VERTEX_SHADER are attached to program, they will be
+ used to create an executable that will run on the programmable vertex
+ processor. If any shader objects of type GL.FRAGMENT_SHADER are attached
+ to program, they will be used to create an executable that will run on the
+ programmable fragment processor.
+
+ The status of the link operation will be stored as part of the program
+ object's state. This value will be set to GL.TRUE if the program object
+ was linked without errors and is ready for use, and GL.FALSE otherwise. It
+ can be queried by calling GetProgramiv with arguments program and
+ GL.LINK_STATUS.
+
+ As a result of a successful link operation, all active user-defined
+ uniform variables belonging to program will be initialized to 0, and each
+ of the program object's active uniform variables will be assigned a
+ location that can be queried by calling GetUniformLocation. Also, any
+ active user-defined attribute variables that have not been bound to a
+ generic vertex attribute index will be bound to one at this time.
+
+ Linking of a program object can fail for a number of reasons as specified
+ in the OpenGL Shading Language Specification. The following lists some of
+ the conditions that will cause a link error.
+
+ - The number of active attribute variables supported by the
+ implementation has been exceeded.
+
+ - The storage limit for uniform variables has been exceeded.
+
+ - The number of active uniform variables supported by the implementation
+ has been exceeded.
+
+ - The main function is missing for the vertex shader or the fragment
+ shader.
+
+ - A varying variable actually used in the fragment shader is not
+ declared in the same way (or is not declared at all) in the vertex
+ shader.
+
+ - A reference to a function or variable name is unresolved.
+
+ - A shared global is declared with two different types or two different
+ initial values.
+
+ - One or more of the attached shader objects has not been successfully
+ compiled.
+
+ - Binding a generic attribute matrix caused some rows of the matrix to
+ fall outside the allowed maximum of GL.MAX_VERTEX_ATTRIBS.
+
+ - Not enough contiguous vertex attribute slots could be found to bind
+ attribute matrices.
+
+ When a program object has been successfully linked, the program object can
+ be made part of current state by calling UseProgram. Whether or not the
+ link operation was successful, the program object's information log will
+ be overwritten. The information log can be retrieved by calling
+ GetProgramInfoLog.
+
+ LinkProgram will also install the generated executables as part of the
+ current rendering state if the link operation was successful and the
+ specified program object is already currently in use as a result of a
+ previous call to UseProgram. If the program object currently in use is
+ relinked unsuccessfully, its link status will be set to GL.FALSE , but the
+ executables and associated state will remain part of the current state
+ until a subsequent call to UseProgram removes it from use. After it is
+ removed from use, it cannot be made part of current state until it has
+ been successfully relinked.
+
+ If program contains shader objects of type GL.VERTEX_SHADER but does not
+ contain shader objects of type GL.FRAGMENT_SHADER, the vertex shader will
+ be linked against the implicit interface for fixed functionality fragment
+ processing. Similarly, if program contains shader objects of type
+ GL.FRAGMENT_SHADER but it does not contain shader objects of type
+ GL.VERTEX_SHADER, the fragment shader will be linked against the implicit
+ interface for fixed functionality vertex processing.
+
+ The program object's information log is updated and the program is
+ generated at the time of the link operation. After the link operation,
+ applications are free to modify attached shader objects, compile attached
+ shader objects, detach shader objects, delete shader objects, and attach
+ additional shader objects. None of these operations affects the
+ information log or the program that is part of the program object.
+
+ If the link operation is unsuccessful, any information about a previous
+ link operation on program is lost (a failed link does not restore the
+ old state of program). Certain information can still be retrieved
+ from program even after an unsuccessful link operation. See for instance
+ GetActiveAttrib and GetActiveUniform.
+
+ Error GL.INVALID_VALUE is generated if program is not a value generated by
+ OpenGL. GL.INVALID_OPERATION is generated if program is not a program
+ object. GL.INVALID_OPERATION is generated if LinkProgram is executed
+ between the execution of Begin and the corresponding execution of End.
+
+ {{funcSince . "2.0+"}}
+ `,
+}, {
+ name: "MultMatrixd",
+ before: `
+ if len(m) != 16 {
+ panic("parameter m must have length 16 for the 4x4 matrix")
+ }
+ `,
+ doc: `
+ multiplies the current matrix with the provided matrix.
+
+ The m parameter must hold 16 consecutive elements of a 4x4 column-major matrix.
+
+ The current matrix is determined by the current matrix mode (see
+ MatrixMode). It is either the projection matrix, modelview matrix, or the
+ texture matrix.
+
+ For example, if the current matrix is C and the coordinates to be transformed
+ are v = (v[0], v[1], v[2], v[3]), then the current transformation is C × v, or
+
+ c[0] c[4] c[8] c[12] v[0]
+ c[1] c[5] c[9] c[13] v[1]
+ c[2] c[6] c[10] c[14] X v[2]
+ c[3] c[7] c[11] c[15] v[3]
+
+ Calling MultMatrix with an argument of m = m[0], m[1], ..., m[15]
+ replaces the current transformation with (C X M) x v, or
+
+ c[0] c[4] c[8] c[12] m[0] m[4] m[8] m[12] v[0]
+ c[1] c[5] c[9] c[13] m[1] m[5] m[9] m[13] v[1]
+ c[2] c[6] c[10] c[14] X m[2] m[6] m[10] m[14] X v[2]
+ c[3] c[7] c[11] c[15] m[3] m[7] m[11] m[15] v[3]
+
+ Where 'X' denotes matrix multiplication, and v is represented as a 4x1 matrix.
+
+ While the elements of the matrix may be specified with single or double
+ precision, the GL may store or operate on these values in less-than-single
+ precision.
+
+ In many computer languages, 4×4 arrays are represented in row-major
+ order. The transformations just described represent these matrices in
+ column-major order. The order of the multiplication is important. For
+ example, if the current transformation is a rotation, and MultMatrix is
+ called with a translation matrix, the translation is done directly on the
+ coordinates to be transformed, while the rotation is done on the results
+ of that translation.
+
+ GL.INVALID_OPERATION is generated if MultMatrix is executed between the
+ execution of Begin and the corresponding execution of End.
+ `,
+}, {
+ name: "MultMatrixf",
+ copy: "MultMatrixd",
+}, {
+ name: "ShaderSource",
+ params: paramTweaks{
+ "glstring": {rename: "source", retype: "...string", replace: true},
+ "length": {omit: true},
+ "count": {omit: true},
+ },
+ before: `
+ count := len(source)
+ length := make([]int32, count)
+ source_c := make([]unsafe.Pointer, count)
+ for i, src := range source {
+ length[i] = int32(len(src))
+ if len(src) > 0 {
+ source_c[i] = *(*unsafe.Pointer)(unsafe.Pointer(&src))
+ } else {
+ source_c[i] = unsafe.Pointer(uintptr(0))
+ }
+ }
+ `,
+ doc: `
+ sets the source code in shader to the provided source code. Any source
+ code previously stored in the shader object is completely replaced.
+
+ Error GL.INVALID_VALUE is generated if shader is not a value generated by
+ OpenGL. GL.INVALID_OPERATION is generated if shader is not a shader
+ object. GL.INVALID_VALUE is generated if count is less than 0.
+ GL.INVALID_OPERATION is generated if ShaderSource is executed between the
+ execution of Begin and the corresponding execution of End.
+
+ {{funcSince . "2.0+"}}
+ `,
+}, {
+ name: "Uniform1f",
+ copy: "Uniform4ui",
+}, {
+ name: "Uniform2f",
+ copy: "Uniform4ui",
+}, {
+ name: "Uniform3f",
+ copy: "Uniform4ui",
+}, {
+ name: "Uniform4f",
+ copy: "Uniform4ui",
+}, {
+ name: "Uniform1i",
+ copy: "Uniform4ui",
+}, {
+ name: "Uniform2i",
+ copy: "Uniform4ui",
+}, {
+ name: "Uniform3i",
+ copy: "Uniform4ui",
+}, {
+ name: "Uniform4i",
+ copy: "Uniform4ui",
+}, {
+ name: "Uniform1ui",
+ copy: "Uniform4ui",
+}, {
+ name: "Uniform2ui",
+ copy: "Uniform4ui",
+}, {
+ name: "Uniform3ui",
+ copy: "Uniform4ui",
+}, {
+ name: "Uniform4ui",
+ doc: `
+ modifies the value of a single uniform variable.
+ The location of the uniform variable to be modified is specified by
+ location, which should be a value returned by GetUniformLocation.
+ {{.GoName}} operates on the program object that was made part of
+ current state by calling UseProgram.
+
+ The functions Uniform{1|2|3|4}{f|i|ui} are used to change the value of the
+ uniform variable specified by location using the values passed as
+ arguments. The number specified in the function should match the number of
+ components in the data type of the specified uniform variable (1 for
+ float, int, unsigned int, bool; 2 for vec2, ivec2, uvec2, bvec2, etc.).
+ The suffix f indicates that floating-point values are being passed; the
+ suffix i indicates that integer values are being passed; the suffix ui
+ indicates that unsigned integer values are being passed, and this type
+ should also match the data type of the specified uniform variable. The i
+ variants of this function should be used to provide values for uniform
+ variables defined as int, ivec2, ivec3, ivec4, or arrays of these. The ui
+ variants of this function should be used to provide values for uniform
+ variables defined as unsigned int, uvec2, uvec3, uvec4, or arrays of
+ these. The f variants should be used to provide values for uniform
+ variables of type float, vec2, vec3, vec4, or arrays of these. Either the
+ i, ui or f variants may be used to provide values for uniform variables of
+ type bool, bvec2, bvec3, bvec4, or arrays of these. The uniform variable
+ will be set to false if the input value is 0 or 0.0f, and it will be set
+ to true otherwise.
+
+ Uniform1i and Uniform1iv are the only two functions that may be used to
+ load uniform variables defined as sampler types. Loading samplers with any
+ other function will result in a GL.INVALID_OPERATION error.
+
+ All active uniform variables defined in a program object are initialized
+ to 0 when the program object is linked successfully. They retain the
+ values assigned to them by a call to Uniform* until the next successful
+ link operation occurs on the program object, when they are once again
+ initialized to 0.
+ `,
+}, {
+ name: "Uniform1fv",
+ copy: "Uniform4uiv",
+}, {
+ name: "Uniform2fv",
+ copy: "Uniform4uiv",
+}, {
+ name: "Uniform3fv",
+ copy: "Uniform4uiv",
+}, {
+ name: "Uniform4fv",
+ copy: "Uniform4uiv",
+}, {
+ name: "Uniform1iv",
+ copy: "Uniform4uiv",
+}, {
+ name: "Uniform2iv",
+ copy: "Uniform4uiv",
+}, {
+ name: "Uniform3iv",
+ copy: "Uniform4uiv",
+}, {
+ name: "Uniform4iv",
+ copy: "Uniform4uiv",
+}, {
+ name: "Uniform1uiv",
+ copy: "Uniform4uiv",
+}, {
+ name: "Uniform2uiv",
+ copy: "Uniform4uiv",
+}, {
+ name: "Uniform3uiv",
+ copy: "Uniform4uiv",
+}, {
+ name: "Uniform4uiv",
+ params: paramTweaks{
+ "count": {omit: true},
+ },
+ before: `
+ if len(value) == 0 {
+ return
+ } {{with $n := substr .GoName 7 8}}{{if ne $n "1"}}
+ if len(value)%{{$n}} != 0 {
+ panic("invalid value length for {{$.GoName}}")
+ }
+ count := len(value)/{{$n}}
+ {{else}}
+ count := len(value)
+ {{end}}{{end}}
+ `,
+ doc: `
+ modifies the value of a uniform variable or a uniform
+ variable array. The location of the uniform variable to be modified is
+ specified by location, which should be a value returned by GetUniformLocation.
+ {{.GoName}} operates on the program object that was made part of
+ current state by calling UseProgram.
+
+ The functions Uniform{1|2|3|4}{f|i|ui}v can be used to modify a single
+ uniform variable or a uniform variable array. These functions receive a
+ slice with the values to be loaded into a uniform variable or a uniform
+ variable array. A slice with length 1 should be used if modifying the value
+ of a single uniform variable, and a length of 1 or greater can be used to
+ modify an entire array or part of an array. When loading n elements
+ starting at an arbitrary position m in a uniform variable array, elements
+ m + n - 1 in the array will be replaced with the new values. If m + n - 1
+ is larger than the size of the uniform variable array, values for all
+ array elements beyond the end of the array will be ignored. The number
+ specified in the name of the command indicates the number of components
+ for each element in value, and it should match the number of components in
+ the data type of the specified uniform variable (1 for float, int, bool;
+ 2 for vec2, ivec2, bvec2, etc.). The data type specified in the name
+ of the command must match the data type for the specified uniform variable
+ as described for Uniform{1|2|3|4}{f|i|ui}.
+
+ Uniform1i and Uniform1iv are the only two functions that may be used to
+ load uniform variables defined as sampler types. Loading samplers with any
+ other function will result in a GL.INVALID_OPERATION error.
+
+ All active uniform variables defined in a program object are initialized
+ to 0 when the program object is linked successfully. They retain the
+ values assigned to them by a call to Uniform* until the next successful
+ link operation occurs on the program object, when they are once again
+ initialized to 0.
+ `,
+}, {
+ name: "UniformMatrix2fv",
+ copy: "UniformMatrix4x3fv",
+}, {
+ name: "UniformMatrix2x3fv",
+ copy: "UniformMatrix4x3fv",
+}, {
+ name: "UniformMatrix2x4fv",
+ copy: "UniformMatrix4x3fv",
+}, {
+ name: "UniformMatrix3fv",
+ copy: "UniformMatrix4x3fv",
+}, {
+ name: "UniformMatrix3x2fv",
+ copy: "UniformMatrix4x3fv",
+}, {
+ name: "UniformMatrix3x4fv",
+ copy: "UniformMatrix4x3fv",
+}, {
+ name: "UniformMatrix4fv",
+ copy: "UniformMatrix4x3fv",
+}, {
+ name: "UniformMatrix4x2fv",
+ copy: "UniformMatrix4x3fv",
+}, {
+ name: "UniformMatrix4x3fv",
+ params: paramTweaks{
+ "count": {omit: true},
+ },
+ before: `
+ if len(value) == 0 {
+ return
+ } {{with $n := substr $.GoName 13 14}}{{with $m := substr $.GoName 15 16}}{{if eq $m "v"}}
+ if len(value)%({{$n}}*{{$n}}) != 0 {
+ panic("invalid value length for {{$.GoName}}")
+ }
+ count := len(value)/({{$n}}*{{$n}})
+ {{else}}
+ if len(value)%({{$n}}*{{$m}}) != 0 {
+ panic("invalid value length for {{$.GoName}}")
+ }
+ count := len(value)/({{$n}}*{{$m}})
+ {{end}}{{end}}{{end}}
+ `,
+ doc: `
+ modifies the value of a uniform variable or a uniform
+ variable array. The location of the uniform variable to be modified is
+ specified by location, which should be a value returned by GetUniformLocation.
+ {{.GoName}} operates on the program object that was made part of
+ current state by calling UseProgram.
+
+ The functions UniformMatrix{2|3|4|2x3|3x2|2x4|4x2|3x4|4x3}fv are used to
+ modify a matrix or an array of matrices. The numbers in the function name
+ are interpreted as the dimensionality of the matrix. The number 2
+ indicates a 2x2 matrix (4 values), the number 3 indicates a 3x3 matrix (9
+ values), and the number 4 indicates a 4x4 matrix (16 values). Non-square
+ matrix dimensionality is explicit, with the first number representing the
+ number of columns and the second number representing the number of rows.
+ For example, 2x4 indicates a 2x4 matrix with 2 columns and 4 rows (8
+ values). The length of the provided slice must be a multiple of the number
+ of values per matrix, to update one or more consecutive matrices.
+
+ If transpose is false, each matrix is assumed to be supplied in column
+ major order. If transpose is true, each matrix is assumed to be supplied
+ in row major order.
+
+ All active uniform variables defined in a program object are initialized
+ to 0 when the program object is linked successfully. They retain the
+ values assigned to them by a call to Uniform* until the next successful
+ link operation occurs on the program object, when they are once again
+ initialized to 0.
+ `,
+}, {
+ name: "UseProgram",
+ doc: `
+ installs the program object specified by program as part of
+ current rendering state. One or more executables are created in a program
+ object by successfully attaching shader objects to it with AttachShader,
+ successfully compiling the shader objects with CompileShader, and
+ successfully linking the program object with LinkProgram.
+
+ A program object will contain an executable that will run on the vertex
+ processor if it contains one or more shader objects of type
+ GL.VERTEX_SHADER that have been successfully compiled and linked.
+ Similarly, a program object will contain an executable that will run on
+ the fragment processor if it contains one or more shader objects of type
+ GL.FRAGMENT_SHADER that have been successfully compiled and linked.
+
+ Successfully installing an executable on a programmable processor will
+ cause the corresponding fixed functionality of OpenGL to be disabled.
+ Specifically, if an executable is installed on the vertex processor, the
+ OpenGL fixed functionality will be disabled as follows.
+
+ - The modelview matrix is not applied to vertex coordinates.
+
+ - The projection matrix is not applied to vertex coordinates.
+
+ - The texture matrices are not applied to texture coordinates.
+
+ - Normals are not transformed to eye coordinates.
+
+ - Normals are not rescaled or normalized.
+
+ - Normalization of GL.AUTO_NORMAL evaluated normals is not performed.
+
+ - Texture coordinates are not generated automatically.
+
+ - Per-vertex lighting is not performed.
+
+ - Color material computations are not performed.
+
+ - Color index lighting is not performed.
+
+ - This list also applies when setting the current raster position.
+
+ The executable that is installed on the vertex processor is expected to
+ implement any or all of the desired functionality from the preceding list.
+ Similarly, if an executable is installed on the fragment processor, the
+ OpenGL fixed functionality will be disabled as follows.
+
+ - Texture environment and texture functions are not applied.
+
+ - Texture application is not applied.
+
+ - Color sum is not applied.
+
+ - Fog is not applied.
+
+ Again, the fragment shader that is installed is expected to implement any
+ or all of the desired functionality from the preceding list.
+
+ While a program object is in use, applications are free to modify attached
+ shader objects, compile attached shader objects, attach additional shader
+ objects, and detach or delete shader objects. None of these operations
+ will affect the executables that are part of the current state. However,
+ relinking the program object that is currently in use will install the
+ program object as part of the current rendering state if the link
+ operation was successful (see LinkProgram). If the program object
+ currently in use is relinked unsuccessfully, its link status will be set
+ to GL.FALSE, but the executables and associated state will remain part of
+ the current state until a subsequent call to UseProgram removes it from
+ use. After it is removed from use, it cannot be made part of current state
+ until it has been successfully relinked.
+
+ If program contains shader objects of type GL.VERTEX_SHADER but it does
+ not contain shader objects of type GL.FRAGMENT_SHADER, an executable will
+ be installed on the vertex processor, but fixed functionality will be used
+ for fragment processing. Similarly, if program contains shader objects of
+ type GL.FRAGMENT_SHADER but it does not contain shader objects of type
+ GL.VERTEX_SHADER, an executable will be installed on the fragment
+ processor, but fixed functionality will be used for vertex processing. If
+ program is 0, the programmable processors will be disabled, and fixed
+ functionality will be used for both vertex and fragment processing.
+
+ While a program object is in use, the state that controls the disabled
+ fixed functionality may also be updated using the normal OpenGL calls.
+
+ Like display lists and texture objects, the name space for program objects
+ may be shared across a set of contexts, as long as the server sides of the
+ contexts share the same address space. If the name space is shared across
+ contexts, any attached objects and the data associated with those attached
+ objects are shared as well.
+
+ Applications are responsible for providing the synchronization across API
+ calls when objects are accessed from different execution threads.
+
+ Error GL.INVALID_VALUE is generated if program is neither 0 nor a value
+ generated by OpenGL. GL.INVALID_OPERATION is generated if program is not
+ a program object. GL.INVALID_OPERATION is generated if program could not
+ be made part of current state. GL.INVALID_OPERATION is generated if
+ UseProgram is executed between the execution of Begin and the
+ corresponding execution of End.
+
+ {{funcSince . "2.0+"}}
+ `,
+}, {
+ name: "VertexAttribPointer",
+ params: paramTweaks{
+ "pointer": {rename: "offset", retype: "uintptr"},
+ },
+ before: `
+ offset_ptr := unsafe.Pointer(offset)
+ `,
+ doc: `
+ specifies the location and data format of the array
+ of generic vertex attributes at index to use when rendering. size
+ specifies the number of components per attribute and must be 1, 2, 3, or
+ 4. type specifies the data type of each component, and stride specifies
+ the byte stride from one attribute to the next, allowing vertices and
+ attributes to be packed into a single array or stored in separate arrays.
+ normalized indicates whether the values stored in an integer format are
+ to be mapped to the range [-1,1] (for signed values) or [0,1]
+ (for unsigned values) when they are accessed and converted to floating
+ point; otherwise, values will be converted to floats directly without
+ normalization. offset is a byte offset into the buffer object's data
+ store, which must be bound to the GL.ARRAY_BUFFER target with BindBuffer.
+
+ The buffer object binding (GL.ARRAY_BUFFER_BINDING) is saved as
+ generic vertex attribute array client-side state
+ (GL.VERTEX_ATTRIB_ARRAY_BUFFER_BINDING) for the provided index.
+
+ To enable and disable a generic vertex attribute array, call
+ EnableVertexAttribArray and DisableVertexAttribArray with index. If
+ enabled, the generic vertex attribute array is used when DrawArrays or
+ DrawElements is called. Each generic vertex attribute array is initially
+ disabled.
+
+ VertexAttribPointer is typically implemented on the client side.
+
+ Error GL.INVALID_ENUM is generated if type is not an accepted value.
+ GL.INVALID_VALUE is generated if index is greater than or equal to
+ GL.MAX_VERTEX_ATTRIBS. GL.INVALID_VALUE is generated if size is not 1, 2,
+ 3, or 4. GL.INVALID_VALUE is generated if stride is negative.
+ `,
+}}
+
+// vim:ts=8:tw=90:noet
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/gengl/gl.xml b/Godeps/_workspace/src/github.com/obscuren/qml/gl/gengl/gl.xml
new file mode 100644
index 000000000..d5c920237
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/gengl/gl.xml
@@ -0,0 +1,43891 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<registry>
+ <comment>
+Copyright (c) 2013-2014 The Khronos Group Inc.
+
+Permission is hereby granted, free of charge, to any person obtaining a
+copy of this software and/or associated documentation files (the
+"Materials"), to deal in the Materials without restriction, including
+without limitation the rights to use, copy, modify, merge, publish,
+distribute, sublicense, and/or sell copies of the Materials, and to
+permit persons to whom the Materials are furnished to do so, subject to
+the following conditions:
+
+The above copyright notice and this permission notice shall be included
+in all copies or substantial portions of the Materials.
+
+THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
+IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
+CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
+TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
+
+------------------------------------------------------------------------
+
+This file, gl.xml, is the OpenGL and OpenGL API Registry. The older
+".spec" file format has been retired and will no longer be updated with
+new extensions and API versions. The canonical version of the registry,
+together with documentation, schema, and Python generator scripts used
+to generate C header files for OpenGL and OpenGL ES, can always be found
+in the Khronos Registry at
+ http://www.opengl.org/registry/
+ </comment>
+
+ <!-- SECTION: GL type definitions. -->
+ <types>
+ <!-- These are dependencies GL types require to be declared legally -->
+ <type name="stddef">#include &lt;stddef.h&gt;</type>
+ <type name="khrplatform">#include &lt;KHR/khrplatform.h&gt;</type>
+ <type name="inttypes">#ifndef GLEXT_64_TYPES_DEFINED
+/* This code block is duplicated in glxext.h, so must be protected */
+#define GLEXT_64_TYPES_DEFINED
+/* Define int32_t, int64_t, and uint64_t types for UST/MSC */
+/* (as used in the GL_EXT_timer_query extension). */
+#if defined(__STDC_VERSION__) &amp;&amp; __STDC_VERSION__ &gt;= 199901L
+#include &lt;inttypes.h&gt;
+#elif defined(__sun__) || defined(__digital__)
+#include &lt;inttypes.h&gt;
+#if defined(__STDC__)
+#if defined(__arch64__) || defined(_LP64)
+typedef long int int64_t;
+typedef unsigned long int uint64_t;
+#else
+typedef long long int int64_t;
+typedef unsigned long long int uint64_t;
+#endif /* __arch64__ */
+#endif /* __STDC__ */
+#elif defined( __VMS ) || defined(__sgi)
+#include &lt;inttypes.h&gt;
+#elif defined(__SCO__) || defined(__USLC__)
+#include &lt;stdint.h&gt;
+#elif defined(__UNIXOS2__) || defined(__SOL64__)
+typedef long int int32_t;
+typedef long long int int64_t;
+typedef unsigned long long int uint64_t;
+#elif defined(_WIN32) &amp;&amp; defined(__GNUC__)
+#include &lt;stdint.h&gt;
+#elif defined(_WIN32)
+typedef __int32 int32_t;
+typedef __int64 int64_t;
+typedef unsigned __int64 uint64_t;
+#else
+/* Fallback if nothing above works */
+#include &lt;inttypes.h&gt;
+#endif
+#endif</type>
+ <!-- These are actual GL types -->
+ <type>typedef unsigned int <name>GLenum</name>;</type>
+ <type>typedef unsigned char <name>GLboolean</name>;</type>
+ <type>typedef unsigned int <name>GLbitfield</name>;</type>
+ <type comment="Not an actual GL type, though used in headers in the past">typedef void <name>GLvoid</name>;</type>
+ <type>typedef signed char <name>GLbyte</name>;</type>
+ <type>typedef short <name>GLshort</name>;</type>
+ <type>typedef int <name>GLint</name>;</type>
+ <type>typedef int <name>GLclampx</name>;</type>
+ <type>typedef unsigned char <name>GLubyte</name>;</type>
+ <type>typedef unsigned short <name>GLushort</name>;</type>
+ <type>typedef unsigned int <name>GLuint</name>;</type>
+ <type>typedef int <name>GLsizei</name>;</type>
+ <type>typedef float <name>GLfloat</name>;</type>
+ <type>typedef float <name>GLclampf</name>;</type>
+ <type>typedef double <name>GLdouble</name>;</type>
+ <type>typedef double <name>GLclampd</name>;</type>
+ <type>typedef void *<name>GLeglImageOES</name>;</type>
+ <type>typedef char <name>GLchar</name>;</type>
+ <type>typedef char <name>GLcharARB</name>;</type>
+ <type name="GLhandleARB">#ifdef __APPLE__
+typedef void *GLhandleARB;
+#else
+typedef unsigned int GLhandleARB;
+#endif</type>
+ <type>typedef unsigned short <name>GLhalfARB</name>;</type>
+ <type>typedef unsigned short <name>GLhalf</name>;</type>
+ <type comment="Must be 32 bits">typedef GLint <name>GLfixed</name>;</type>
+ <type requires="stddef">typedef ptrdiff_t <name>GLintptr</name>;</type>
+ <type requires="stddef">typedef ptrdiff_t <name>GLsizeiptr</name>;</type>
+ <type requires="inttypes">typedef int64_t <name>GLint64</name>;</type>
+ <type requires="inttypes">typedef uint64_t <name>GLuint64</name>;</type>
+ <type requires="stddef">typedef ptrdiff_t <name>GLintptrARB</name>;</type>
+ <type requires="stddef">typedef ptrdiff_t <name>GLsizeiptrARB</name>;</type>
+ <type requires="inttypes">typedef int64_t <name>GLint64EXT</name>;</type>
+ <type requires="inttypes">typedef uint64_t <name>GLuint64EXT</name>;</type>
+ <type>typedef struct __GLsync *<name>GLsync</name>;</type>
+ <type comment="compatible with OpenCL cl_context"><name>struct _cl_context</name>;</type>
+ <type comment="compatible with OpenCL cl_event"><name>struct _cl_event</name>;</type>
+ <type>typedef void (<apientry/> *<name>GLDEBUGPROC</name>)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,const void *userParam);</type>
+ <type>typedef void (<apientry/> *<name>GLDEBUGPROCARB</name>)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,const void *userParam);</type>
+ <type>typedef void (<apientry/> *<name>GLDEBUGPROCKHR</name>)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,const void *userParam);</type>
+ <!-- GLES 1 types -->
+ <type api="gles1" requires="khrplatform">typedef khronos_int32_t <name>GLclampx</name>;</type>
+ <!-- GLES 1/2 types (tagged for GLES 1) -->
+ <type api="gles1" requires="khrplatform">typedef khronos_int8_t <name>GLbyte</name>;</type>
+ <type api="gles1" requires="khrplatform">typedef khronos_uint8_t <name>GLubyte</name>;</type>
+ <type api="gles1" requires="khrplatform">typedef khronos_float_t <name>GLfloat</name>;</type>
+ <type api="gles1" requires="khrplatform">typedef khronos_float_t <name>GLclampf</name>;</type>
+ <type api="gles1" requires="khrplatform">typedef khronos_int32_t <name>GLfixed</name>;</type>
+ <type api="gles1" requires="khrplatform">typedef khronos_int64_t <name>GLint64</name>;</type>
+ <type api="gles1" requires="khrplatform">typedef khronos_uint64_t <name>GLuint64</name>;</type>
+ <type api="gles1" requires="khrplatform">typedef khronos_intptr_t <name>GLintptr</name>;</type>
+ <type api="gles1" requires="khrplatform">typedef khronos_ssize_t <name>GLsizeiptr</name>;</type>
+ <!-- GLES 1/2 types (tagged for GLES 2 - attribute syntax is limited) -->
+ <type api="gles2" requires="khrplatform">typedef khronos_int8_t <name>GLbyte</name>;</type>
+ <type api="gles2" requires="khrplatform">typedef khronos_uint8_t <name>GLubyte</name>;</type>
+ <type api="gles2" requires="khrplatform">typedef khronos_float_t <name>GLfloat</name>;</type>
+ <type api="gles2" requires="khrplatform">typedef khronos_float_t <name>GLclampf</name>;</type>
+ <type api="gles2" requires="khrplatform">typedef khronos_int32_t <name>GLfixed</name>;</type>
+ <type api="gles2" requires="khrplatform">typedef khronos_int64_t <name>GLint64</name>;</type>
+ <type api="gles2" requires="khrplatform">typedef khronos_uint64_t <name>GLuint64</name>;</type>
+ <type api="gles2" requires="khrplatform">typedef khronos_int64_t <name>GLint64EXT</name>;</type>
+ <type api="gles2" requires="khrplatform">typedef khronos_uint64_t <name>GLuint64EXT</name>;</type>
+ <type api="gles2" requires="khrplatform">typedef khronos_intptr_t <name>GLintptr</name>;</type>
+ <type api="gles2" requires="khrplatform">typedef khronos_ssize_t <name>GLsizeiptr</name>;</type>
+ <!-- GLES 2 types (none currently) -->
+ <!-- Vendor extension types -->
+ <type>typedef void (<apientry/> *<name>GLDEBUGPROCAMD</name>)(GLuint id,GLenum category,GLenum severity,GLsizei length,const GLchar *message,void *userParam);</type>
+ <type>typedef unsigned short <name>GLhalfNV</name>;</type>
+ <type requires="GLintptr">typedef GLintptr <name>GLvdpauSurfaceNV</name>;</type>
+ </types>
+
+ <!-- SECTION: GL parameter class type definitions. -->
+
+ <groups>
+ <group name="AccumOp">
+ <enum name="GL_ACCUM"/>
+ <enum name="GL_LOAD"/>
+ <enum name="GL_RETURN"/>
+ <enum name="GL_MULT"/>
+ <enum name="GL_ADD"/>
+ </group>
+
+ <group name="AttribMask">
+ <enum name="GL_ACCUM_BUFFER_BIT"/>
+ <enum name="GL_ALL_ATTRIB_BITS"/>
+ <enum name="GL_COLOR_BUFFER_BIT"/>
+ <enum name="GL_CURRENT_BIT"/>
+ <enum name="GL_DEPTH_BUFFER_BIT"/>
+ <enum name="GL_ENABLE_BIT"/>
+ <enum name="GL_EVAL_BIT"/>
+ <enum name="GL_FOG_BIT"/>
+ <enum name="GL_HINT_BIT"/>
+ <enum name="GL_LIGHTING_BIT"/>
+ <enum name="GL_LINE_BIT"/>
+ <enum name="GL_LIST_BIT"/>
+ <enum name="GL_MULTISAMPLE_BIT"/>
+ <enum name="GL_MULTISAMPLE_BIT_3DFX"/>
+ <enum name="GL_MULTISAMPLE_BIT_ARB"/>
+ <enum name="GL_MULTISAMPLE_BIT_EXT"/>
+ <enum name="GL_PIXEL_MODE_BIT"/>
+ <enum name="GL_POINT_BIT"/>
+ <enum name="GL_POLYGON_BIT"/>
+ <enum name="GL_POLYGON_STIPPLE_BIT"/>
+ <enum name="GL_SCISSOR_BIT"/>
+ <enum name="GL_STENCIL_BUFFER_BIT"/>
+ <enum name="GL_TEXTURE_BIT"/>
+ <enum name="GL_TRANSFORM_BIT"/>
+ <enum name="GL_VIEWPORT_BIT"/>
+ </group>
+
+ <group name="AlphaFunction">
+ <enum name="GL_ALWAYS"/>
+ <enum name="GL_EQUAL"/>
+ <enum name="GL_GEQUAL"/>
+ <enum name="GL_GREATER"/>
+ <enum name="GL_LEQUAL"/>
+ <enum name="GL_LESS"/>
+ <enum name="GL_NEVER"/>
+ <enum name="GL_NOTEQUAL"/>
+ </group>
+
+ <group name="BlendEquationModeEXT">
+ <enum name="GL_ALPHA_MAX_SGIX"/>
+ <enum name="GL_ALPHA_MIN_SGIX"/>
+ <enum name="GL_FUNC_ADD_EXT"/>
+ <enum name="GL_FUNC_REVERSE_SUBTRACT_EXT"/>
+ <enum name="GL_FUNC_SUBTRACT_EXT"/>
+ <enum name="GL_LOGIC_OP"/>
+ <enum name="GL_MAX_EXT"/>
+ <enum name="GL_MIN_EXT"/>
+ </group>
+
+ <group name="BlendingFactorDest">
+ <enum name="GL_CONSTANT_ALPHA_EXT"/>
+ <enum name="GL_CONSTANT_COLOR_EXT"/>
+ <enum name="GL_DST_ALPHA"/>
+ <enum name="GL_ONE"/>
+ <enum name="GL_ONE_MINUS_CONSTANT_ALPHA_EXT"/>
+ <enum name="GL_ONE_MINUS_CONSTANT_COLOR_EXT"/>
+ <enum name="GL_ONE_MINUS_DST_ALPHA"/>
+ <enum name="GL_ONE_MINUS_SRC_ALPHA"/>
+ <enum name="GL_ONE_MINUS_SRC_COLOR"/>
+ <enum name="GL_SRC_ALPHA"/>
+ <enum name="GL_SRC_COLOR"/>
+ <enum name="GL_ZERO"/>
+ </group>
+
+ <group name="BlendingFactorSrc">
+ <enum name="GL_CONSTANT_ALPHA_EXT"/>
+ <enum name="GL_CONSTANT_COLOR_EXT"/>
+ <enum name="GL_DST_ALPHA"/>
+ <enum name="GL_DST_COLOR"/>
+ <enum name="GL_ONE"/>
+ <enum name="GL_ONE_MINUS_CONSTANT_ALPHA_EXT"/>
+ <enum name="GL_ONE_MINUS_CONSTANT_COLOR_EXT"/>
+ <enum name="GL_ONE_MINUS_DST_ALPHA"/>
+ <enum name="GL_ONE_MINUS_DST_COLOR"/>
+ <enum name="GL_ONE_MINUS_SRC_ALPHA"/>
+ <enum name="GL_SRC_ALPHA"/>
+ <enum name="GL_SRC_ALPHA_SATURATE"/>
+ <enum name="GL_ZERO"/>
+ </group>
+
+ <group name="Boolean">
+ <enum name="GL_FALSE"/>
+ <enum name="GL_TRUE"/>
+ </group>
+
+ <group name="ClearBufferMask">
+ <enum name="GL_ACCUM_BUFFER_BIT"/>
+ <enum name="GL_COLOR_BUFFER_BIT"/>
+ <enum name="GL_COVERAGE_BUFFER_BIT_NV"/>
+ <enum name="GL_DEPTH_BUFFER_BIT"/>
+ <enum name="GL_STENCIL_BUFFER_BIT"/>
+ </group>
+
+ <group name="ClientAttribMask">
+ <enum name="GL_CLIENT_ALL_ATTRIB_BITS"/>
+ <enum name="GL_CLIENT_PIXEL_STORE_BIT"/>
+ <enum name="GL_CLIENT_VERTEX_ARRAY_BIT"/>
+ </group>
+
+ <group name="ClipPlaneName">
+ <enum name="GL_CLIP_DISTANCE0"/>
+ <enum name="GL_CLIP_DISTANCE1"/>
+ <enum name="GL_CLIP_DISTANCE2"/>
+ <enum name="GL_CLIP_DISTANCE3"/>
+ <enum name="GL_CLIP_DISTANCE4"/>
+ <enum name="GL_CLIP_DISTANCE5"/>
+ <enum name="GL_CLIP_DISTANCE6"/>
+ <enum name="GL_CLIP_DISTANCE7"/>
+ <enum name="GL_CLIP_PLANE0"/>
+ <enum name="GL_CLIP_PLANE1"/>
+ <enum name="GL_CLIP_PLANE2"/>
+ <enum name="GL_CLIP_PLANE3"/>
+ <enum name="GL_CLIP_PLANE4"/>
+ <enum name="GL_CLIP_PLANE5"/>
+ </group>
+
+ <group name="ColorMaterialFace">
+ <enum name="GL_BACK"/>
+ <enum name="GL_FRONT"/>
+ <enum name="GL_FRONT_AND_BACK"/>
+ </group>
+
+ <group name="ColorMaterialParameter">
+ <enum name="GL_AMBIENT"/>
+ <enum name="GL_AMBIENT_AND_DIFFUSE"/>
+ <enum name="GL_DIFFUSE"/>
+ <enum name="GL_EMISSION"/>
+ <enum name="GL_SPECULAR"/>
+ </group>
+
+ <group name="ColorPointerType">
+ <enum name="GL_BYTE"/>
+ <enum name="GL_DOUBLE"/>
+ <enum name="GL_FLOAT"/>
+ <enum name="GL_INT"/>
+ <enum name="GL_SHORT"/>
+ <enum name="GL_UNSIGNED_BYTE"/>
+ <enum name="GL_UNSIGNED_INT"/>
+ <enum name="GL_UNSIGNED_SHORT"/>
+ </group>
+
+ <group name="ColorTableParameterPNameSGI">
+ <enum name="GL_COLOR_TABLE_BIAS"/>
+ <enum name="GL_COLOR_TABLE_BIAS_SGI"/>
+ <enum name="GL_COLOR_TABLE_SCALE"/>
+ <enum name="GL_COLOR_TABLE_SCALE_SGI"/>
+ </group>
+
+ <group name="ColorTableTargetSGI">
+ <enum name="GL_COLOR_TABLE"/>
+ <enum name="GL_COLOR_TABLE_SGI"/>
+ <enum name="GL_POST_COLOR_MATRIX_COLOR_TABLE"/>
+ <enum name="GL_POST_COLOR_MATRIX_COLOR_TABLE_SGI"/>
+ <enum name="GL_POST_CONVOLUTION_COLOR_TABLE"/>
+ <enum name="GL_POST_CONVOLUTION_COLOR_TABLE_SGI"/>
+ <enum name="GL_PROXY_COLOR_TABLE"/>
+ <enum name="GL_PROXY_COLOR_TABLE_SGI"/>
+ <enum name="GL_PROXY_POST_COLOR_MATRIX_COLOR_TABLE"/>
+ <enum name="GL_PROXY_POST_COLOR_MATRIX_COLOR_TABLE_SGI"/>
+ <enum name="GL_PROXY_POST_CONVOLUTION_COLOR_TABLE"/>
+ <enum name="GL_PROXY_POST_CONVOLUTION_COLOR_TABLE_SGI"/>
+ <enum name="GL_PROXY_TEXTURE_COLOR_TABLE_SGI"/>
+ <enum name="GL_TEXTURE_COLOR_TABLE_SGI"/>
+ </group>
+
+ <group name="ContextFlagMask">
+ <enum name="GL_CONTEXT_FLAG_DEBUG_BIT"/>
+ <enum name="GL_CONTEXT_FLAG_DEBUG_BIT_KHR"/>
+ <enum name="GL_CONTEXT_FLAG_FORWARD_COMPATIBLE_BIT"/>
+ <enum name="GL_CONTEXT_FLAG_ROBUST_ACCESS_BIT_ARB"/>
+ </group>
+
+ <group name="ContextProfileMask">
+ <enum name="GL_CONTEXT_COMPATIBILITY_PROFILE_BIT"/>
+ <enum name="GL_CONTEXT_CORE_PROFILE_BIT"/>
+ </group>
+
+ <group name="ConvolutionBorderModeEXT">
+ <enum name="GL_REDUCE"/>
+ <enum name="GL_REDUCE_EXT"/>
+ </group>
+
+ <group name="ConvolutionParameterEXT">
+ <enum name="GL_CONVOLUTION_BORDER_MODE"/>
+ <enum name="GL_CONVOLUTION_BORDER_MODE_EXT"/>
+ <enum name="GL_CONVOLUTION_FILTER_BIAS"/>
+ <enum name="GL_CONVOLUTION_FILTER_BIAS_EXT"/>
+ <enum name="GL_CONVOLUTION_FILTER_SCALE"/>
+ <enum name="GL_CONVOLUTION_FILTER_SCALE_EXT"/>
+ </group>
+
+ <group name="ConvolutionTargetEXT">
+ <enum name="GL_CONVOLUTION_1D"/>
+ <enum name="GL_CONVOLUTION_1D_EXT"/>
+ <enum name="GL_CONVOLUTION_2D"/>
+ <enum name="GL_CONVOLUTION_2D_EXT"/>
+ </group>
+
+ <group name="CullFaceMode">
+ <enum name="GL_BACK"/>
+ <enum name="GL_FRONT"/>
+ <enum name="GL_FRONT_AND_BACK"/>
+ </group>
+
+ <group name="DataType" comment="See enums block below"/>
+
+ <group name="DepthFunction">
+ <enum name="GL_ALWAYS"/>
+ <enum name="GL_EQUAL"/>
+ <enum name="GL_GEQUAL"/>
+ <enum name="GL_GREATER"/>
+ <enum name="GL_LEQUAL"/>
+ <enum name="GL_LESS"/>
+ <enum name="GL_NEVER"/>
+ <enum name="GL_NOTEQUAL"/>
+ </group>
+
+ <group name="DrawBufferMode">
+ <enum name="GL_AUX0"/>
+ <enum name="GL_AUX1"/>
+ <enum name="GL_AUX2"/>
+ <enum name="GL_AUX3"/>
+ <enum name="GL_BACK"/>
+ <enum name="GL_BACK_LEFT"/>
+ <enum name="GL_BACK_RIGHT"/>
+ <enum name="GL_FRONT"/>
+ <enum name="GL_FRONT_AND_BACK"/>
+ <enum name="GL_FRONT_LEFT"/>
+ <enum name="GL_FRONT_RIGHT"/>
+ <enum name="GL_LEFT"/>
+ <enum name="GL_NONE"/>
+ <enum name="GL_NONE_OES"/>
+ <enum name="GL_RIGHT"/>
+ </group>
+
+ <group name="EnableCap">
+ <enum name="GL_ALPHA_TEST"/>
+ <enum name="GL_ASYNC_DRAW_PIXELS_SGIX"/>
+ <enum name="GL_ASYNC_HISTOGRAM_SGIX"/>
+ <enum name="GL_ASYNC_READ_PIXELS_SGIX"/>
+ <enum name="GL_ASYNC_TEX_IMAGE_SGIX"/>
+ <enum name="GL_AUTO_NORMAL"/>
+ <enum name="GL_BLEND"/>
+ <enum name="GL_CALLIGRAPHIC_FRAGMENT_SGIX"/>
+ <enum name="GL_CLIP_PLANE0"/>
+ <enum name="GL_CLIP_PLANE1"/>
+ <enum name="GL_CLIP_PLANE2"/>
+ <enum name="GL_CLIP_PLANE3"/>
+ <enum name="GL_CLIP_PLANE4"/>
+ <enum name="GL_CLIP_PLANE5"/>
+ <enum name="GL_COLOR_ARRAY"/>
+ <enum name="GL_COLOR_LOGIC_OP"/>
+ <enum name="GL_COLOR_MATERIAL"/>
+ <enum name="GL_COLOR_TABLE_SGI"/>
+ <enum name="GL_CONVOLUTION_1D_EXT"/>
+ <enum name="GL_CONVOLUTION_2D_EXT"/>
+ <enum name="GL_CULL_FACE"/>
+ <enum name="GL_DEPTH_TEST"/>
+ <enum name="GL_DITHER"/>
+ <enum name="GL_EDGE_FLAG_ARRAY"/>
+ <enum name="GL_FOG"/>
+ <enum name="GL_FOG_OFFSET_SGIX"/>
+ <enum name="GL_FRAGMENT_COLOR_MATERIAL_SGIX"/>
+ <enum name="GL_FRAGMENT_LIGHT0_SGIX"/>
+ <enum name="GL_FRAGMENT_LIGHT1_SGIX"/>
+ <enum name="GL_FRAGMENT_LIGHT2_SGIX"/>
+ <enum name="GL_FRAGMENT_LIGHT3_SGIX"/>
+ <enum name="GL_FRAGMENT_LIGHT4_SGIX"/>
+ <enum name="GL_FRAGMENT_LIGHT5_SGIX"/>
+ <enum name="GL_FRAGMENT_LIGHT6_SGIX"/>
+ <enum name="GL_FRAGMENT_LIGHT7_SGIX"/>
+ <enum name="GL_FRAGMENT_LIGHTING_SGIX"/>
+ <enum name="GL_FRAMEZOOM_SGIX"/>
+ <enum name="GL_HISTOGRAM_EXT"/>
+ <enum name="GL_INDEX_ARRAY"/>
+ <enum name="GL_INDEX_LOGIC_OP"/>
+ <enum name="GL_INTERLACE_SGIX"/>
+ <enum name="GL_IR_INSTRUMENT1_SGIX"/>
+ <enum name="GL_LIGHT0"/>
+ <enum name="GL_LIGHT1"/>
+ <enum name="GL_LIGHT2"/>
+ <enum name="GL_LIGHT3"/>
+ <enum name="GL_LIGHT4"/>
+ <enum name="GL_LIGHT5"/>
+ <enum name="GL_LIGHT6"/>
+ <enum name="GL_LIGHT7"/>
+ <enum name="GL_LIGHTING"/>
+ <enum name="GL_LINE_SMOOTH"/>
+ <enum name="GL_LINE_STIPPLE"/>
+ <enum name="GL_MAP1_COLOR_4"/>
+ <enum name="GL_MAP1_INDEX"/>
+ <enum name="GL_MAP1_NORMAL"/>
+ <enum name="GL_MAP1_TEXTURE_COORD_1"/>
+ <enum name="GL_MAP1_TEXTURE_COORD_2"/>
+ <enum name="GL_MAP1_TEXTURE_COORD_3"/>
+ <enum name="GL_MAP1_TEXTURE_COORD_4"/>
+ <enum name="GL_MAP1_VERTEX_3"/>
+ <enum name="GL_MAP1_VERTEX_4"/>
+ <enum name="GL_MAP2_COLOR_4"/>
+ <enum name="GL_MAP2_INDEX"/>
+ <enum name="GL_MAP2_NORMAL"/>
+ <enum name="GL_MAP2_TEXTURE_COORD_1"/>
+ <enum name="GL_MAP2_TEXTURE_COORD_2"/>
+ <enum name="GL_MAP2_TEXTURE_COORD_3"/>
+ <enum name="GL_MAP2_TEXTURE_COORD_4"/>
+ <enum name="GL_MAP2_VERTEX_3"/>
+ <enum name="GL_MAP2_VERTEX_4"/>
+ <enum name="GL_MINMAX_EXT"/>
+ <enum name="GL_MULTISAMPLE_SGIS"/>
+ <enum name="GL_NORMALIZE"/>
+ <enum name="GL_NORMAL_ARRAY"/>
+ <enum name="GL_PIXEL_TEXTURE_SGIS"/>
+ <enum name="GL_PIXEL_TEX_GEN_SGIX"/>
+ <enum name="GL_POINT_SMOOTH"/>
+ <enum name="GL_POLYGON_OFFSET_FILL"/>
+ <enum name="GL_POLYGON_OFFSET_LINE"/>
+ <enum name="GL_POLYGON_OFFSET_POINT"/>
+ <enum name="GL_POLYGON_SMOOTH"/>
+ <enum name="GL_POLYGON_STIPPLE"/>
+ <enum name="GL_POST_COLOR_MATRIX_COLOR_TABLE_SGI"/>
+ <enum name="GL_POST_CONVOLUTION_COLOR_TABLE_SGI"/>
+ <enum name="GL_REFERENCE_PLANE_SGIX"/>
+ <enum name="GL_RESCALE_NORMAL_EXT"/>
+ <enum name="GL_SAMPLE_ALPHA_TO_MASK_SGIS"/>
+ <enum name="GL_SAMPLE_ALPHA_TO_ONE_SGIS"/>
+ <enum name="GL_SAMPLE_MASK_SGIS"/>
+ <enum name="GL_SCISSOR_TEST"/>
+ <enum name="GL_SEPARABLE_2D_EXT"/>
+ <enum name="GL_SHARED_TEXTURE_PALETTE_EXT"/>
+ <enum name="GL_SPRITE_SGIX"/>
+ <enum name="GL_STENCIL_TEST"/>
+ <enum name="GL_TEXTURE_1D"/>
+ <enum name="GL_TEXTURE_2D"/>
+ <enum name="GL_TEXTURE_3D_EXT"/>
+ <enum name="GL_TEXTURE_4D_SGIS"/>
+ <enum name="GL_TEXTURE_COLOR_TABLE_SGI"/>
+ <enum name="GL_TEXTURE_COORD_ARRAY"/>
+ <enum name="GL_TEXTURE_GEN_Q"/>
+ <enum name="GL_TEXTURE_GEN_R"/>
+ <enum name="GL_TEXTURE_GEN_S"/>
+ <enum name="GL_TEXTURE_GEN_T"/>
+ <enum name="GL_VERTEX_ARRAY"/>
+ </group>
+
+ <group name="ErrorCode">
+ <enum name="GL_INVALID_ENUM"/>
+ <enum name="GL_INVALID_FRAMEBUFFER_OPERATION"/>
+ <enum name="GL_INVALID_FRAMEBUFFER_OPERATION_EXT"/>
+ <enum name="GL_INVALID_FRAMEBUFFER_OPERATION_OES"/>
+ <enum name="GL_INVALID_OPERATION"/>
+ <enum name="GL_INVALID_VALUE"/>
+ <enum name="GL_NO_ERROR"/>
+ <enum name="GL_OUT_OF_MEMORY"/>
+ <enum name="GL_STACK_OVERFLOW"/>
+ <enum name="GL_STACK_UNDERFLOW"/>
+ <enum name="GL_TABLE_TOO_LARGE"/>
+ <enum name="GL_TABLE_TOO_LARGE_EXT"/>
+ <enum name="GL_TEXTURE_TOO_LARGE_EXT"/>
+ </group>
+
+ <group name="FeedbackType">
+ <enum name="GL_2D"/>
+ <enum name="GL_3D"/>
+ <enum name="GL_3D_COLOR"/>
+ <enum name="GL_3D_COLOR_TEXTURE"/>
+ <enum name="GL_4D_COLOR_TEXTURE"/>
+ </group>
+
+ <group name="FeedBackToken">
+ <enum name="GL_BITMAP_TOKEN"/>
+ <enum name="GL_COPY_PIXEL_TOKEN"/>
+ <enum name="GL_DRAW_PIXEL_TOKEN"/>
+ <enum name="GL_LINE_RESET_TOKEN"/>
+ <enum name="GL_LINE_TOKEN"/>
+ <enum name="GL_PASS_THROUGH_TOKEN"/>
+ <enum name="GL_POINT_TOKEN"/>
+ <enum name="GL_POLYGON_TOKEN"/>
+ </group>
+
+ <group name="FfdMaskSGIX" comment="See enums section below. Was SGIXFfdMask"/>
+
+ <group name="FfdTargetSGIX">
+ <enum name="GL_GEOMETRY_DEFORMATION_SGIX"/>
+ <enum name="GL_TEXTURE_DEFORMATION_SGIX"/>
+ </group>
+
+ <group name="FogCoordinatePointerType">
+ <enum name="GL_FLOAT"/>
+ <enum name="GL_DOUBLE"/>
+ </group>
+
+ <group name="FogMode">
+ <enum name="GL_EXP"/>
+ <enum name="GL_EXP2"/>
+ <enum name="GL_FOG_FUNC_SGIS"/>
+ <enum name="GL_LINEAR"/>
+ </group>
+
+ <group name="FogParameter">
+ <enum name="GL_FOG_COLOR"/>
+ <enum name="GL_FOG_DENSITY"/>
+ <enum name="GL_FOG_END"/>
+ <enum name="GL_FOG_INDEX"/>
+ <enum name="GL_FOG_MODE"/>
+ <enum name="GL_FOG_OFFSET_VALUE_SGIX"/>
+ <enum name="GL_FOG_START"/>
+ </group>
+
+ <group name="FogPointerTypeEXT">
+ <enum name="GL_FLOAT"/>
+ <enum name="GL_DOUBLE"/>
+ </group>
+
+ <group name="FogPointerTypeIBM">
+ <enum name="GL_FLOAT"/>
+ <enum name="GL_DOUBLE"/>
+ </group>
+
+ <group name="FragmentLightModelParameterSGIX">
+ <enum name="GL_FRAGMENT_LIGHT_MODEL_AMBIENT_SGIX"/>
+ <enum name="GL_FRAGMENT_LIGHT_MODEL_LOCAL_VIEWER_SGIX"/>
+ <enum name="GL_FRAGMENT_LIGHT_MODEL_NORMAL_INTERPOLATION_SGIX"/>
+ <enum name="GL_FRAGMENT_LIGHT_MODEL_TWO_SIDE_SGIX"/>
+ </group>
+
+ <group name="FrontFaceDirection">
+ <enum name="GL_CCW"/>
+ <enum name="GL_CW"/>
+ </group>
+
+ <group name="GetColorTableParameterPNameSGI">
+ <enum name="GL_COLOR_TABLE_ALPHA_SIZE_SGI"/>
+ <enum name="GL_COLOR_TABLE_BIAS_SGI"/>
+ <enum name="GL_COLOR_TABLE_BLUE_SIZE_SGI"/>
+ <enum name="GL_COLOR_TABLE_FORMAT_SGI"/>
+ <enum name="GL_COLOR_TABLE_GREEN_SIZE_SGI"/>
+ <enum name="GL_COLOR_TABLE_INTENSITY_SIZE_SGI"/>
+ <enum name="GL_COLOR_TABLE_LUMINANCE_SIZE_SGI"/>
+ <enum name="GL_COLOR_TABLE_RED_SIZE_SGI"/>
+ <enum name="GL_COLOR_TABLE_SCALE_SGI"/>
+ <enum name="GL_COLOR_TABLE_WIDTH_SGI"/>
+ </group>
+
+ <group name="GetConvolutionParameter">
+ <enum name="GL_CONVOLUTION_BORDER_MODE_EXT"/>
+ <enum name="GL_CONVOLUTION_FILTER_BIAS_EXT"/>
+ <enum name="GL_CONVOLUTION_FILTER_SCALE_EXT"/>
+ <enum name="GL_CONVOLUTION_FORMAT_EXT"/>
+ <enum name="GL_CONVOLUTION_HEIGHT_EXT"/>
+ <enum name="GL_CONVOLUTION_WIDTH_EXT"/>
+ <enum name="GL_MAX_CONVOLUTION_HEIGHT_EXT"/>
+ <enum name="GL_MAX_CONVOLUTION_WIDTH_EXT"/>
+ </group>
+
+ <group name="GetHistogramParameterPNameEXT">
+ <enum name="GL_HISTOGRAM_ALPHA_SIZE_EXT"/>
+ <enum name="GL_HISTOGRAM_BLUE_SIZE_EXT"/>
+ <enum name="GL_HISTOGRAM_FORMAT_EXT"/>
+ <enum name="GL_HISTOGRAM_GREEN_SIZE_EXT"/>
+ <enum name="GL_HISTOGRAM_LUMINANCE_SIZE_EXT"/>
+ <enum name="GL_HISTOGRAM_RED_SIZE_EXT"/>
+ <enum name="GL_HISTOGRAM_SINK_EXT"/>
+ <enum name="GL_HISTOGRAM_WIDTH_EXT"/>
+ </group>
+
+ <group name="GetMapQuery">
+ <enum name="GL_COEFF"/>
+ <enum name="GL_DOMAIN"/>
+ <enum name="GL_ORDER"/>
+ </group>
+
+ <group name="GetMinmaxParameterPNameEXT">
+ <enum name="GL_MINMAX_FORMAT"/>
+ <enum name="GL_MINMAX_FORMAT_EXT"/>
+ <enum name="GL_MINMAX_SINK"/>
+ <enum name="GL_MINMAX_SINK_EXT"/>
+ </group>
+
+ <group name="GetPixelMap">
+ <enum name="GL_PIXEL_MAP_A_TO_A"/>
+ <enum name="GL_PIXEL_MAP_B_TO_B"/>
+ <enum name="GL_PIXEL_MAP_G_TO_G"/>
+ <enum name="GL_PIXEL_MAP_I_TO_A"/>
+ <enum name="GL_PIXEL_MAP_I_TO_B"/>
+ <enum name="GL_PIXEL_MAP_I_TO_G"/>
+ <enum name="GL_PIXEL_MAP_I_TO_I"/>
+ <enum name="GL_PIXEL_MAP_I_TO_R"/>
+ <enum name="GL_PIXEL_MAP_R_TO_R"/>
+ <enum name="GL_PIXEL_MAP_S_TO_S"/>
+ </group>
+
+ <group name="GetPName">
+ <enum name="GL_ACCUM_ALPHA_BITS"/>
+ <enum name="GL_ACCUM_BLUE_BITS"/>
+ <enum name="GL_ACCUM_CLEAR_VALUE"/>
+ <enum name="GL_ACCUM_GREEN_BITS"/>
+ <enum name="GL_ACCUM_RED_BITS"/>
+ <enum name="GL_ALIASED_LINE_WIDTH_RANGE"/>
+ <enum name="GL_ALIASED_POINT_SIZE_RANGE"/>
+ <enum name="GL_ALPHA_BIAS"/>
+ <enum name="GL_ALPHA_BITS"/>
+ <enum name="GL_ALPHA_SCALE"/>
+ <enum name="GL_ALPHA_TEST"/>
+ <enum name="GL_ALPHA_TEST_FUNC"/>
+ <enum name="GL_ALPHA_TEST_FUNC_QCOM"/>
+ <enum name="GL_ALPHA_TEST_QCOM"/>
+ <enum name="GL_ALPHA_TEST_REF"/>
+ <enum name="GL_ALPHA_TEST_REF_QCOM"/>
+ <enum name="GL_ASYNC_DRAW_PIXELS_SGIX"/>
+ <enum name="GL_ASYNC_HISTOGRAM_SGIX"/>
+ <enum name="GL_ASYNC_MARKER_SGIX"/>
+ <enum name="GL_ASYNC_READ_PIXELS_SGIX"/>
+ <enum name="GL_ASYNC_TEX_IMAGE_SGIX"/>
+ <enum name="GL_ATTRIB_STACK_DEPTH"/>
+ <enum name="GL_AUTO_NORMAL"/>
+ <enum name="GL_AUX_BUFFERS"/>
+ <enum name="GL_BLEND"/>
+ <enum name="GL_BLEND_COLOR_EXT"/>
+ <enum name="GL_BLEND_DST"/>
+ <enum name="GL_BLEND_EQUATION_EXT"/>
+ <enum name="GL_BLEND_SRC"/>
+ <enum name="GL_BLUE_BIAS"/>
+ <enum name="GL_BLUE_BITS"/>
+ <enum name="GL_BLUE_SCALE"/>
+ <enum name="GL_CALLIGRAPHIC_FRAGMENT_SGIX"/>
+ <enum name="GL_CLIENT_ATTRIB_STACK_DEPTH"/>
+ <enum name="GL_CLIP_PLANE0"/>
+ <enum name="GL_CLIP_PLANE1"/>
+ <enum name="GL_CLIP_PLANE2"/>
+ <enum name="GL_CLIP_PLANE3"/>
+ <enum name="GL_CLIP_PLANE4"/>
+ <enum name="GL_CLIP_PLANE5"/>
+ <enum name="GL_COLOR_ARRAY"/>
+ <enum name="GL_COLOR_ARRAY_COUNT_EXT"/>
+ <enum name="GL_COLOR_ARRAY_SIZE"/>
+ <enum name="GL_COLOR_ARRAY_STRIDE"/>
+ <enum name="GL_COLOR_ARRAY_TYPE"/>
+ <enum name="GL_COLOR_CLEAR_VALUE"/>
+ <enum name="GL_COLOR_LOGIC_OP"/>
+ <enum name="GL_COLOR_MATERIAL"/>
+ <enum name="GL_COLOR_MATERIAL_FACE"/>
+ <enum name="GL_COLOR_MATERIAL_PARAMETER"/>
+ <enum name="GL_COLOR_MATRIX_SGI"/>
+ <enum name="GL_COLOR_MATRIX_STACK_DEPTH_SGI"/>
+ <enum name="GL_COLOR_TABLE_SGI"/>
+ <enum name="GL_COLOR_WRITEMASK"/>
+ <enum name="GL_CONVOLUTION_1D_EXT"/>
+ <enum name="GL_CONVOLUTION_2D_EXT"/>
+ <enum name="GL_CONVOLUTION_HINT_SGIX"/>
+ <enum name="GL_CULL_FACE"/>
+ <enum name="GL_CULL_FACE_MODE"/>
+ <enum name="GL_CURRENT_COLOR"/>
+ <enum name="GL_CURRENT_INDEX"/>
+ <enum name="GL_CURRENT_NORMAL"/>
+ <enum name="GL_CURRENT_RASTER_COLOR"/>
+ <enum name="GL_CURRENT_RASTER_DISTANCE"/>
+ <enum name="GL_CURRENT_RASTER_INDEX"/>
+ <enum name="GL_CURRENT_RASTER_POSITION"/>
+ <enum name="GL_CURRENT_RASTER_POSITION_VALID"/>
+ <enum name="GL_CURRENT_RASTER_TEXTURE_COORDS"/>
+ <enum name="GL_CURRENT_TEXTURE_COORDS"/>
+ <enum name="GL_DEFORMATIONS_MASK_SGIX"/>
+ <enum name="GL_DEPTH_BIAS"/>
+ <enum name="GL_DEPTH_BITS"/>
+ <enum name="GL_DEPTH_CLEAR_VALUE"/>
+ <enum name="GL_DEPTH_FUNC"/>
+ <enum name="GL_DEPTH_RANGE"/>
+ <enum name="GL_DEPTH_SCALE"/>
+ <enum name="GL_DEPTH_TEST"/>
+ <enum name="GL_DEPTH_WRITEMASK"/>
+ <enum name="GL_DETAIL_TEXTURE_2D_BINDING_SGIS"/>
+ <enum name="GL_DISTANCE_ATTENUATION_SGIS"/>
+ <enum name="GL_DITHER"/>
+ <enum name="GL_DOUBLEBUFFER"/>
+ <enum name="GL_DRAW_BUFFER"/>
+ <enum name="GL_DRAW_BUFFER_EXT"/>
+ <enum name="GL_EDGE_FLAG"/>
+ <enum name="GL_EDGE_FLAG_ARRAY"/>
+ <enum name="GL_EDGE_FLAG_ARRAY_COUNT_EXT"/>
+ <enum name="GL_EDGE_FLAG_ARRAY_STRIDE"/>
+ <enum name="GL_FEEDBACK_BUFFER_SIZE"/>
+ <enum name="GL_FEEDBACK_BUFFER_TYPE"/>
+ <enum name="GL_FOG"/>
+ <enum name="GL_FOG_COLOR"/>
+ <enum name="GL_FOG_DENSITY"/>
+ <enum name="GL_FOG_END"/>
+ <enum name="GL_FOG_FUNC_POINTS_SGIS"/>
+ <enum name="GL_FOG_HINT"/>
+ <enum name="GL_FOG_INDEX"/>
+ <enum name="GL_FOG_MODE"/>
+ <enum name="GL_FOG_OFFSET_SGIX"/>
+ <enum name="GL_FOG_OFFSET_VALUE_SGIX"/>
+ <enum name="GL_FOG_START"/>
+ <enum name="GL_FRAGMENT_COLOR_MATERIAL_FACE_SGIX"/>
+ <enum name="GL_FRAGMENT_COLOR_MATERIAL_PARAMETER_SGIX"/>
+ <enum name="GL_FRAGMENT_COLOR_MATERIAL_SGIX"/>
+ <enum name="GL_FRAGMENT_LIGHT0_SGIX"/>
+ <enum name="GL_FRAGMENT_LIGHTING_SGIX"/>
+ <enum name="GL_FRAGMENT_LIGHT_MODEL_AMBIENT_SGIX"/>
+ <enum name="GL_FRAGMENT_LIGHT_MODEL_LOCAL_VIEWER_SGIX"/>
+ <enum name="GL_FRAGMENT_LIGHT_MODEL_NORMAL_INTERPOLATION_SGIX"/>
+ <enum name="GL_FRAGMENT_LIGHT_MODEL_TWO_SIDE_SGIX"/>
+ <enum name="GL_FRAMEZOOM_FACTOR_SGIX"/>
+ <enum name="GL_FRAMEZOOM_SGIX"/>
+ <enum name="GL_FRONT_FACE"/>
+ <enum name="GL_GENERATE_MIPMAP_HINT_SGIS"/>
+ <enum name="GL_GREEN_BIAS"/>
+ <enum name="GL_GREEN_BITS"/>
+ <enum name="GL_GREEN_SCALE"/>
+ <enum name="GL_HISTOGRAM_EXT"/>
+ <enum name="GL_INDEX_ARRAY"/>
+ <enum name="GL_INDEX_ARRAY_COUNT_EXT"/>
+ <enum name="GL_INDEX_ARRAY_STRIDE"/>
+ <enum name="GL_INDEX_ARRAY_TYPE"/>
+ <enum name="GL_INDEX_BITS"/>
+ <enum name="GL_INDEX_CLEAR_VALUE"/>
+ <enum name="GL_INDEX_LOGIC_OP"/>
+ <enum name="GL_INDEX_MODE"/>
+ <enum name="GL_INDEX_OFFSET"/>
+ <enum name="GL_INDEX_SHIFT"/>
+ <enum name="GL_INDEX_WRITEMASK"/>
+ <enum name="GL_INSTRUMENT_MEASUREMENTS_SGIX"/>
+ <enum name="GL_INTERLACE_SGIX"/>
+ <enum name="GL_IR_INSTRUMENT1_SGIX"/>
+ <enum name="GL_LIGHT0"/>
+ <enum name="GL_LIGHT1"/>
+ <enum name="GL_LIGHT2"/>
+ <enum name="GL_LIGHT3"/>
+ <enum name="GL_LIGHT4"/>
+ <enum name="GL_LIGHT5"/>
+ <enum name="GL_LIGHT6"/>
+ <enum name="GL_LIGHT7"/>
+ <enum name="GL_LIGHTING"/>
+ <enum name="GL_LIGHT_ENV_MODE_SGIX"/>
+ <enum name="GL_LIGHT_MODEL_AMBIENT"/>
+ <enum name="GL_LIGHT_MODEL_COLOR_CONTROL"/>
+ <enum name="GL_LIGHT_MODEL_LOCAL_VIEWER"/>
+ <enum name="GL_LIGHT_MODEL_TWO_SIDE"/>
+ <enum name="GL_LINE_SMOOTH"/>
+ <enum name="GL_LINE_SMOOTH_HINT"/>
+ <enum name="GL_LINE_STIPPLE"/>
+ <enum name="GL_LINE_STIPPLE_PATTERN"/>
+ <enum name="GL_LINE_STIPPLE_REPEAT"/>
+ <enum name="GL_LINE_WIDTH"/>
+ <enum name="GL_LINE_WIDTH_GRANULARITY"/>
+ <enum name="GL_LINE_WIDTH_RANGE"/>
+ <enum name="GL_LIST_BASE"/>
+ <enum name="GL_LIST_INDEX"/>
+ <enum name="GL_LIST_MODE"/>
+ <enum name="GL_LOGIC_OP"/>
+ <enum name="GL_LOGIC_OP_MODE"/>
+ <enum name="GL_MAP1_COLOR_4"/>
+ <enum name="GL_MAP1_GRID_DOMAIN"/>
+ <enum name="GL_MAP1_GRID_SEGMENTS"/>
+ <enum name="GL_MAP1_INDEX"/>
+ <enum name="GL_MAP1_NORMAL"/>
+ <enum name="GL_MAP1_TEXTURE_COORD_1"/>
+ <enum name="GL_MAP1_TEXTURE_COORD_2"/>
+ <enum name="GL_MAP1_TEXTURE_COORD_3"/>
+ <enum name="GL_MAP1_TEXTURE_COORD_4"/>
+ <enum name="GL_MAP1_VERTEX_3"/>
+ <enum name="GL_MAP1_VERTEX_4"/>
+ <enum name="GL_MAP2_COLOR_4"/>
+ <enum name="GL_MAP2_GRID_DOMAIN"/>
+ <enum name="GL_MAP2_GRID_SEGMENTS"/>
+ <enum name="GL_MAP2_INDEX"/>
+ <enum name="GL_MAP2_NORMAL"/>
+ <enum name="GL_MAP2_TEXTURE_COORD_1"/>
+ <enum name="GL_MAP2_TEXTURE_COORD_2"/>
+ <enum name="GL_MAP2_TEXTURE_COORD_3"/>
+ <enum name="GL_MAP2_TEXTURE_COORD_4"/>
+ <enum name="GL_MAP2_VERTEX_3"/>
+ <enum name="GL_MAP2_VERTEX_4"/>
+ <enum name="GL_MAP_COLOR"/>
+ <enum name="GL_MAP_STENCIL"/>
+ <enum name="GL_MATRIX_MODE"/>
+ <enum name="GL_MAX_3D_TEXTURE_SIZE_EXT"/>
+ <enum name="GL_MAX_4D_TEXTURE_SIZE_SGIS"/>
+ <enum name="GL_MAX_ACTIVE_LIGHTS_SGIX"/>
+ <enum name="GL_MAX_ASYNC_DRAW_PIXELS_SGIX"/>
+ <enum name="GL_MAX_ASYNC_HISTOGRAM_SGIX"/>
+ <enum name="GL_MAX_ASYNC_READ_PIXELS_SGIX"/>
+ <enum name="GL_MAX_ASYNC_TEX_IMAGE_SGIX"/>
+ <enum name="GL_MAX_ATTRIB_STACK_DEPTH"/>
+ <enum name="GL_MAX_CLIENT_ATTRIB_STACK_DEPTH"/>
+ <enum name="GL_MAX_CLIPMAP_DEPTH_SGIX"/>
+ <enum name="GL_MAX_CLIPMAP_VIRTUAL_DEPTH_SGIX"/>
+ <enum name="GL_MAX_CLIP_DISTANCES"/>
+ <enum name="GL_MAX_CLIP_PLANES"/>
+ <enum name="GL_MAX_COLOR_MATRIX_STACK_DEPTH_SGI"/>
+ <enum name="GL_MAX_EVAL_ORDER"/>
+ <enum name="GL_MAX_FOG_FUNC_POINTS_SGIS"/>
+ <enum name="GL_MAX_FRAGMENT_LIGHTS_SGIX"/>
+ <enum name="GL_MAX_FRAMEZOOM_FACTOR_SGIX"/>
+ <enum name="GL_MAX_LIGHTS"/>
+ <enum name="GL_MAX_LIST_NESTING"/>
+ <enum name="GL_MAX_MODELVIEW_STACK_DEPTH"/>
+ <enum name="GL_MAX_NAME_STACK_DEPTH"/>
+ <enum name="GL_MAX_PIXEL_MAP_TABLE"/>
+ <enum name="GL_MAX_PROJECTION_STACK_DEPTH"/>
+ <enum name="GL_MAX_TEXTURE_SIZE"/>
+ <enum name="GL_MAX_TEXTURE_STACK_DEPTH"/>
+ <enum name="GL_MAX_VIEWPORT_DIMS"/>
+ <enum name="GL_MINMAX_EXT"/>
+ <enum name="GL_MODELVIEW0_MATRIX_EXT"/>
+ <enum name="GL_MODELVIEW0_STACK_DEPTH_EXT"/>
+ <enum name="GL_MODELVIEW_MATRIX"/>
+ <enum name="GL_MODELVIEW_STACK_DEPTH"/>
+ <enum name="GL_MULTISAMPLE_SGIS"/>
+ <enum name="GL_NAME_STACK_DEPTH"/>
+ <enum name="GL_NORMALIZE"/>
+ <enum name="GL_NORMAL_ARRAY"/>
+ <enum name="GL_NORMAL_ARRAY_COUNT_EXT"/>
+ <enum name="GL_NORMAL_ARRAY_STRIDE"/>
+ <enum name="GL_NORMAL_ARRAY_TYPE"/>
+ <enum name="GL_PACK_ALIGNMENT"/>
+ <enum name="GL_PACK_CMYK_HINT_EXT"/>
+ <enum name="GL_PACK_IMAGE_DEPTH_SGIS"/>
+ <enum name="GL_PACK_IMAGE_HEIGHT_EXT"/>
+ <enum name="GL_PACK_LSB_FIRST"/>
+ <enum name="GL_PACK_RESAMPLE_SGIX"/>
+ <enum name="GL_PACK_ROW_LENGTH"/>
+ <enum name="GL_PACK_SKIP_IMAGES_EXT"/>
+ <enum name="GL_PACK_SKIP_PIXELS"/>
+ <enum name="GL_PACK_SKIP_ROWS"/>
+ <enum name="GL_PACK_SKIP_VOLUMES_SGIS"/>
+ <enum name="GL_PACK_SUBSAMPLE_RATE_SGIX"/>
+ <enum name="GL_PACK_SWAP_BYTES"/>
+ <enum name="GL_PERSPECTIVE_CORRECTION_HINT"/>
+ <enum name="GL_PIXEL_MAP_A_TO_A_SIZE"/>
+ <enum name="GL_PIXEL_MAP_B_TO_B_SIZE"/>
+ <enum name="GL_PIXEL_MAP_G_TO_G_SIZE"/>
+ <enum name="GL_PIXEL_MAP_I_TO_A_SIZE"/>
+ <enum name="GL_PIXEL_MAP_I_TO_B_SIZE"/>
+ <enum name="GL_PIXEL_MAP_I_TO_G_SIZE"/>
+ <enum name="GL_PIXEL_MAP_I_TO_I_SIZE"/>
+ <enum name="GL_PIXEL_MAP_I_TO_R_SIZE"/>
+ <enum name="GL_PIXEL_MAP_R_TO_R_SIZE"/>
+ <enum name="GL_PIXEL_MAP_S_TO_S_SIZE"/>
+ <enum name="GL_PIXEL_TEXTURE_SGIS"/>
+ <enum name="GL_PIXEL_TEX_GEN_MODE_SGIX"/>
+ <enum name="GL_PIXEL_TEX_GEN_SGIX"/>
+ <enum name="GL_PIXEL_TILE_BEST_ALIGNMENT_SGIX"/>
+ <enum name="GL_PIXEL_TILE_CACHE_INCREMENT_SGIX"/>
+ <enum name="GL_PIXEL_TILE_CACHE_SIZE_SGIX"/>
+ <enum name="GL_PIXEL_TILE_GRID_DEPTH_SGIX"/>
+ <enum name="GL_PIXEL_TILE_GRID_HEIGHT_SGIX"/>
+ <enum name="GL_PIXEL_TILE_GRID_WIDTH_SGIX"/>
+ <enum name="GL_PIXEL_TILE_HEIGHT_SGIX"/>
+ <enum name="GL_PIXEL_TILE_WIDTH_SGIX"/>
+ <enum name="GL_POINT_FADE_THRESHOLD_SIZE_SGIS"/>
+ <enum name="GL_POINT_SIZE"/>
+ <enum name="GL_POINT_SIZE_GRANULARITY"/>
+ <enum name="GL_POINT_SIZE_MAX_SGIS"/>
+ <enum name="GL_POINT_SIZE_MIN_SGIS"/>
+ <enum name="GL_POINT_SIZE_RANGE"/>
+ <enum name="GL_POINT_SMOOTH"/>
+ <enum name="GL_POINT_SMOOTH_HINT"/>
+ <enum name="GL_POLYGON_MODE"/>
+ <enum name="GL_POLYGON_OFFSET_BIAS_EXT"/>
+ <enum name="GL_POLYGON_OFFSET_FACTOR"/>
+ <enum name="GL_POLYGON_OFFSET_FILL"/>
+ <enum name="GL_POLYGON_OFFSET_LINE"/>
+ <enum name="GL_POLYGON_OFFSET_POINT"/>
+ <enum name="GL_POLYGON_OFFSET_UNITS"/>
+ <enum name="GL_POLYGON_SMOOTH"/>
+ <enum name="GL_POLYGON_SMOOTH_HINT"/>
+ <enum name="GL_POLYGON_STIPPLE"/>
+ <enum name="GL_POST_COLOR_MATRIX_ALPHA_BIAS_SGI"/>
+ <enum name="GL_POST_COLOR_MATRIX_ALPHA_SCALE_SGI"/>
+ <enum name="GL_POST_COLOR_MATRIX_BLUE_BIAS_SGI"/>
+ <enum name="GL_POST_COLOR_MATRIX_BLUE_SCALE_SGI"/>
+ <enum name="GL_POST_COLOR_MATRIX_COLOR_TABLE_SGI"/>
+ <enum name="GL_POST_COLOR_MATRIX_GREEN_BIAS_SGI"/>
+ <enum name="GL_POST_COLOR_MATRIX_GREEN_SCALE_SGI"/>
+ <enum name="GL_POST_COLOR_MATRIX_RED_BIAS_SGI"/>
+ <enum name="GL_POST_COLOR_MATRIX_RED_SCALE_SGI"/>
+ <enum name="GL_POST_CONVOLUTION_ALPHA_BIAS_EXT"/>
+ <enum name="GL_POST_CONVOLUTION_ALPHA_SCALE_EXT"/>
+ <enum name="GL_POST_CONVOLUTION_BLUE_BIAS_EXT"/>
+ <enum name="GL_POST_CONVOLUTION_BLUE_SCALE_EXT"/>
+ <enum name="GL_POST_CONVOLUTION_COLOR_TABLE_SGI"/>
+ <enum name="GL_POST_CONVOLUTION_GREEN_BIAS_EXT"/>
+ <enum name="GL_POST_CONVOLUTION_GREEN_SCALE_EXT"/>
+ <enum name="GL_POST_CONVOLUTION_RED_BIAS_EXT"/>
+ <enum name="GL_POST_CONVOLUTION_RED_SCALE_EXT"/>
+ <enum name="GL_POST_TEXTURE_FILTER_BIAS_RANGE_SGIX"/>
+ <enum name="GL_POST_TEXTURE_FILTER_SCALE_RANGE_SGIX"/>
+ <enum name="GL_PROJECTION_MATRIX"/>
+ <enum name="GL_PROJECTION_STACK_DEPTH"/>
+ <enum name="GL_READ_BUFFER"/>
+ <enum name="GL_READ_BUFFER_EXT"/>
+ <enum name="GL_READ_BUFFER_NV"/>
+ <enum name="GL_RED_BIAS"/>
+ <enum name="GL_RED_BITS"/>
+ <enum name="GL_RED_SCALE"/>
+ <enum name="GL_REFERENCE_PLANE_EQUATION_SGIX"/>
+ <enum name="GL_REFERENCE_PLANE_SGIX"/>
+ <enum name="GL_RENDER_MODE"/>
+ <enum name="GL_RESCALE_NORMAL_EXT"/>
+ <enum name="GL_RGBA_MODE"/>
+ <enum name="GL_SAMPLES_SGIS"/>
+ <enum name="GL_SAMPLE_ALPHA_TO_MASK_SGIS"/>
+ <enum name="GL_SAMPLE_ALPHA_TO_ONE_SGIS"/>
+ <enum name="GL_SAMPLE_BUFFERS_SGIS"/>
+ <enum name="GL_SAMPLE_MASK_INVERT_SGIS"/>
+ <enum name="GL_SAMPLE_MASK_SGIS"/>
+ <enum name="GL_SAMPLE_MASK_VALUE_SGIS"/>
+ <enum name="GL_SAMPLE_PATTERN_SGIS"/>
+ <enum name="GL_SCISSOR_BOX"/>
+ <enum name="GL_SCISSOR_TEST"/>
+ <enum name="GL_SELECTION_BUFFER_SIZE"/>
+ <enum name="GL_SEPARABLE_2D_EXT"/>
+ <enum name="GL_SHADE_MODEL"/>
+ <enum name="GL_SHARED_TEXTURE_PALETTE_EXT"/>
+ <enum name="GL_SMOOTH_LINE_WIDTH_GRANULARITY"/>
+ <enum name="GL_SMOOTH_LINE_WIDTH_RANGE"/>
+ <enum name="GL_SMOOTH_POINT_SIZE_GRANULARITY"/>
+ <enum name="GL_SMOOTH_POINT_SIZE_RANGE"/>
+ <enum name="GL_SPRITE_AXIS_SGIX"/>
+ <enum name="GL_SPRITE_MODE_SGIX"/>
+ <enum name="GL_SPRITE_SGIX"/>
+ <enum name="GL_SPRITE_TRANSLATION_SGIX"/>
+ <enum name="GL_STENCIL_BITS"/>
+ <enum name="GL_STENCIL_CLEAR_VALUE"/>
+ <enum name="GL_STENCIL_FAIL"/>
+ <enum name="GL_STENCIL_FUNC"/>
+ <enum name="GL_STENCIL_PASS_DEPTH_FAIL"/>
+ <enum name="GL_STENCIL_PASS_DEPTH_PASS"/>
+ <enum name="GL_STENCIL_REF"/>
+ <enum name="GL_STENCIL_TEST"/>
+ <enum name="GL_STENCIL_VALUE_MASK"/>
+ <enum name="GL_STENCIL_WRITEMASK"/>
+ <enum name="GL_STEREO"/>
+ <enum name="GL_SUBPIXEL_BITS"/>
+ <enum name="GL_TEXTURE_1D"/>
+ <enum name="GL_TEXTURE_2D"/>
+ <enum name="GL_TEXTURE_3D_BINDING_EXT"/>
+ <enum name="GL_TEXTURE_3D_EXT"/>
+ <enum name="GL_TEXTURE_4D_BINDING_SGIS"/>
+ <enum name="GL_TEXTURE_4D_SGIS"/>
+ <enum name="GL_TEXTURE_BINDING_1D"/>
+ <enum name="GL_TEXTURE_BINDING_2D"/>
+ <enum name="GL_TEXTURE_BINDING_3D"/>
+ <enum name="GL_TEXTURE_COLOR_TABLE_SGI"/>
+ <enum name="GL_TEXTURE_COORD_ARRAY"/>
+ <enum name="GL_TEXTURE_COORD_ARRAY_COUNT_EXT"/>
+ <enum name="GL_TEXTURE_COORD_ARRAY_SIZE"/>
+ <enum name="GL_TEXTURE_COORD_ARRAY_STRIDE"/>
+ <enum name="GL_TEXTURE_COORD_ARRAY_TYPE"/>
+ <enum name="GL_TEXTURE_GEN_Q"/>
+ <enum name="GL_TEXTURE_GEN_R"/>
+ <enum name="GL_TEXTURE_GEN_S"/>
+ <enum name="GL_TEXTURE_GEN_T"/>
+ <enum name="GL_TEXTURE_MATRIX"/>
+ <enum name="GL_TEXTURE_STACK_DEPTH"/>
+ <enum name="GL_UNPACK_ALIGNMENT"/>
+ <enum name="GL_UNPACK_CMYK_HINT_EXT"/>
+ <enum name="GL_UNPACK_IMAGE_DEPTH_SGIS"/>
+ <enum name="GL_UNPACK_IMAGE_HEIGHT_EXT"/>
+ <enum name="GL_UNPACK_LSB_FIRST"/>
+ <enum name="GL_UNPACK_RESAMPLE_SGIX"/>
+ <enum name="GL_UNPACK_ROW_LENGTH"/>
+ <enum name="GL_UNPACK_SKIP_IMAGES_EXT"/>
+ <enum name="GL_UNPACK_SKIP_PIXELS"/>
+ <enum name="GL_UNPACK_SKIP_ROWS"/>
+ <enum name="GL_UNPACK_SKIP_VOLUMES_SGIS"/>
+ <enum name="GL_UNPACK_SUBSAMPLE_RATE_SGIX"/>
+ <enum name="GL_UNPACK_SWAP_BYTES"/>
+ <enum name="GL_VERTEX_ARRAY"/>
+ <enum name="GL_VERTEX_ARRAY_COUNT_EXT"/>
+ <enum name="GL_VERTEX_ARRAY_SIZE"/>
+ <enum name="GL_VERTEX_ARRAY_STRIDE"/>
+ <enum name="GL_VERTEX_ARRAY_TYPE"/>
+ <enum name="GL_VERTEX_PRECLIP_HINT_SGIX"/>
+ <enum name="GL_VERTEX_PRECLIP_SGIX"/>
+ <enum name="GL_VIEWPORT"/>
+ <enum name="GL_ZOOM_X"/>
+ <enum name="GL_ZOOM_Y"/>
+ </group>
+
+ <group name="GetPointervPName">
+ <enum name="GL_COLOR_ARRAY_POINTER"/>
+ <enum name="GL_COLOR_ARRAY_POINTER_EXT"/>
+ <enum name="GL_EDGE_FLAG_ARRAY_POINTER"/>
+ <enum name="GL_EDGE_FLAG_ARRAY_POINTER_EXT"/>
+ <enum name="GL_FEEDBACK_BUFFER_POINTER"/>
+ <enum name="GL_INDEX_ARRAY_POINTER"/>
+ <enum name="GL_INDEX_ARRAY_POINTER_EXT"/>
+ <enum name="GL_INSTRUMENT_BUFFER_POINTER_SGIX"/>
+ <enum name="GL_NORMAL_ARRAY_POINTER"/>
+ <enum name="GL_NORMAL_ARRAY_POINTER_EXT"/>
+ <enum name="GL_SELECTION_BUFFER_POINTER"/>
+ <enum name="GL_TEXTURE_COORD_ARRAY_POINTER"/>
+ <enum name="GL_TEXTURE_COORD_ARRAY_POINTER_EXT"/>
+ <enum name="GL_VERTEX_ARRAY_POINTER"/>
+ <enum name="GL_VERTEX_ARRAY_POINTER_EXT"/>
+ </group>
+
+ <group name="GetTextureParameter">
+ <enum name="GL_DETAIL_TEXTURE_FUNC_POINTS_SGIS"/>
+ <enum name="GL_DETAIL_TEXTURE_LEVEL_SGIS"/>
+ <enum name="GL_DETAIL_TEXTURE_MODE_SGIS"/>
+ <enum name="GL_DUAL_TEXTURE_SELECT_SGIS"/>
+ <enum name="GL_GENERATE_MIPMAP_SGIS"/>
+ <enum name="GL_POST_TEXTURE_FILTER_BIAS_SGIX"/>
+ <enum name="GL_POST_TEXTURE_FILTER_SCALE_SGIX"/>
+ <enum name="GL_QUAD_TEXTURE_SELECT_SGIS"/>
+ <enum name="GL_SHADOW_AMBIENT_SGIX"/>
+ <enum name="GL_SHARPEN_TEXTURE_FUNC_POINTS_SGIS"/>
+ <enum name="GL_TEXTURE_4DSIZE_SGIS"/>
+ <enum name="GL_TEXTURE_ALPHA_SIZE"/>
+ <enum name="GL_TEXTURE_BASE_LEVEL_SGIS"/>
+ <enum name="GL_TEXTURE_BLUE_SIZE"/>
+ <enum name="GL_TEXTURE_BORDER"/>
+ <enum name="GL_TEXTURE_BORDER_COLOR"/>
+ <enum name="GL_TEXTURE_BORDER_COLOR_NV"/>
+ <enum name="GL_TEXTURE_CLIPMAP_CENTER_SGIX"/>
+ <enum name="GL_TEXTURE_CLIPMAP_DEPTH_SGIX"/>
+ <enum name="GL_TEXTURE_CLIPMAP_FRAME_SGIX"/>
+ <enum name="GL_TEXTURE_CLIPMAP_LOD_OFFSET_SGIX"/>
+ <enum name="GL_TEXTURE_CLIPMAP_OFFSET_SGIX"/>
+ <enum name="GL_TEXTURE_CLIPMAP_VIRTUAL_DEPTH_SGIX"/>
+ <enum name="GL_TEXTURE_COMPARE_OPERATOR_SGIX"/>
+ <enum name="GL_TEXTURE_COMPARE_SGIX"/>
+ <enum name="GL_TEXTURE_COMPONENTS"/>
+ <enum name="GL_TEXTURE_DEPTH_EXT"/>
+ <enum name="GL_TEXTURE_FILTER4_SIZE_SGIS"/>
+ <enum name="GL_TEXTURE_GEQUAL_R_SGIX"/>
+ <enum name="GL_TEXTURE_GREEN_SIZE"/>
+ <enum name="GL_TEXTURE_HEIGHT"/>
+ <enum name="GL_TEXTURE_INTENSITY_SIZE"/>
+ <enum name="GL_TEXTURE_INTERNAL_FORMAT"/>
+ <enum name="GL_TEXTURE_LEQUAL_R_SGIX"/>
+ <enum name="GL_TEXTURE_LOD_BIAS_R_SGIX"/>
+ <enum name="GL_TEXTURE_LOD_BIAS_S_SGIX"/>
+ <enum name="GL_TEXTURE_LOD_BIAS_T_SGIX"/>
+ <enum name="GL_TEXTURE_LUMINANCE_SIZE"/>
+ <enum name="GL_TEXTURE_MAG_FILTER"/>
+ <enum name="GL_TEXTURE_MAX_CLAMP_R_SGIX"/>
+ <enum name="GL_TEXTURE_MAX_CLAMP_S_SGIX"/>
+ <enum name="GL_TEXTURE_MAX_CLAMP_T_SGIX"/>
+ <enum name="GL_TEXTURE_MAX_LEVEL_SGIS"/>
+ <enum name="GL_TEXTURE_MAX_LOD_SGIS"/>
+ <enum name="GL_TEXTURE_MIN_FILTER"/>
+ <enum name="GL_TEXTURE_MIN_LOD_SGIS"/>
+ <enum name="GL_TEXTURE_PRIORITY"/>
+ <enum name="GL_TEXTURE_RED_SIZE"/>
+ <enum name="GL_TEXTURE_RESIDENT"/>
+ <enum name="GL_TEXTURE_WIDTH"/>
+ <enum name="GL_TEXTURE_WRAP_Q_SGIS"/>
+ <enum name="GL_TEXTURE_WRAP_R_EXT"/>
+ <enum name="GL_TEXTURE_WRAP_S"/>
+ <enum name="GL_TEXTURE_WRAP_T"/>
+ </group>
+
+ <group name="HintMode">
+ <enum name="GL_DONT_CARE"/>
+ <enum name="GL_FASTEST"/>
+ <enum name="GL_NICEST"/>
+ </group>
+
+ <group name="HintTarget">
+ <enum name="GL_ALLOW_DRAW_FRG_HINT_PGI"/>
+ <enum name="GL_ALLOW_DRAW_MEM_HINT_PGI"/>
+ <enum name="GL_ALLOW_DRAW_OBJ_HINT_PGI"/>
+ <enum name="GL_ALLOW_DRAW_WIN_HINT_PGI"/>
+ <enum name="GL_ALWAYS_FAST_HINT_PGI"/>
+ <enum name="GL_ALWAYS_SOFT_HINT_PGI"/>
+ <enum name="GL_BACK_NORMALS_HINT_PGI"/>
+ <enum name="GL_BINNING_CONTROL_HINT_QCOM"/>
+ <enum name="GL_CLIP_FAR_HINT_PGI"/>
+ <enum name="GL_CLIP_NEAR_HINT_PGI"/>
+ <enum name="GL_CLIP_VOLUME_CLIPPING_HINT_EXT"/>
+ <enum name="GL_CONSERVE_MEMORY_HINT_PGI"/>
+ <enum name="GL_CONVOLUTION_HINT_SGIX"/>
+ <enum name="GL_FOG_HINT"/>
+ <enum name="GL_FRAGMENT_SHADER_DERIVATIVE_HINT"/>
+ <enum name="GL_FRAGMENT_SHADER_DERIVATIVE_HINT_ARB"/>
+ <enum name="GL_FRAGMENT_SHADER_DERIVATIVE_HINT_OES"/>
+ <enum name="GL_FULL_STIPPLE_HINT_PGI"/>
+ <enum name="GL_GENERATE_MIPMAP_HINT"/>
+ <enum name="GL_GENERATE_MIPMAP_HINT_SGIS"/>
+ <enum name="GL_LINE_QUALITY_HINT_SGIX"/>
+ <enum name="GL_LINE_SMOOTH_HINT"/>
+ <enum name="GL_MATERIAL_SIDE_HINT_PGI"/>
+ <enum name="GL_MAX_VERTEX_HINT_PGI"/>
+ <enum name="GL_MULTISAMPLE_FILTER_HINT_NV"/>
+ <enum name="GL_NATIVE_GRAPHICS_BEGIN_HINT_PGI"/>
+ <enum name="GL_NATIVE_GRAPHICS_END_HINT_PGI"/>
+ <enum name="GL_PACK_CMYK_HINT_EXT"/>
+ <enum name="GL_PERSPECTIVE_CORRECTION_HINT"/>
+ <enum name="GL_PHONG_HINT_WIN"/>
+ <enum name="GL_POINT_SMOOTH_HINT"/>
+ <enum name="GL_POLYGON_SMOOTH_HINT"/>
+ <enum name="GL_PREFER_DOUBLEBUFFER_HINT_PGI"/>
+ <enum name="GL_PROGRAM_BINARY_RETRIEVABLE_HINT"/>
+ <enum name="GL_RECLAIM_MEMORY_HINT_PGI"/>
+ <enum name="GL_SCALEBIAS_HINT_SGIX"/>
+ <enum name="GL_STRICT_DEPTHFUNC_HINT_PGI"/>
+ <enum name="GL_STRICT_LIGHTING_HINT_PGI"/>
+ <enum name="GL_STRICT_SCISSOR_HINT_PGI"/>
+ <enum name="GL_TEXTURE_COMPRESSION_HINT"/>
+ <enum name="GL_TEXTURE_COMPRESSION_HINT_ARB"/>
+ <enum name="GL_TEXTURE_MULTI_BUFFER_HINT_SGIX"/>
+ <enum name="GL_TEXTURE_STORAGE_HINT_APPLE"/>
+ <enum name="GL_TRANSFORM_HINT_APPLE"/>
+ <enum name="GL_UNPACK_CMYK_HINT_EXT"/>
+ <enum name="GL_VERTEX_ARRAY_STORAGE_HINT_APPLE"/>
+ <enum name="GL_VERTEX_CONSISTENT_HINT_PGI"/>
+ <enum name="GL_VERTEX_DATA_HINT_PGI"/>
+ <enum name="GL_VERTEX_PRECLIP_HINT_SGIX"/>
+ <enum name="GL_VERTEX_PRECLIP_SGIX"/>
+ <enum name="GL_WIDE_LINE_HINT_PGI"/>
+ </group>
+
+ <group name="HistogramTargetEXT">
+ <enum name="GL_HISTOGRAM"/>
+ <enum name="GL_HISTOGRAM_EXT"/>
+ <enum name="GL_PROXY_HISTOGRAM"/>
+ <enum name="GL_PROXY_HISTOGRAM_EXT"/>
+ </group>
+
+ <group name="IndexPointerType">
+ <enum name="GL_DOUBLE"/>
+ <enum name="GL_FLOAT"/>
+ <enum name="GL_INT"/>
+ <enum name="GL_SHORT"/>
+ </group>
+
+ <group name="InterleavedArrayFormat">
+ <enum name="GL_C3F_V3F"/>
+ <enum name="GL_C4F_N3F_V3F"/>
+ <enum name="GL_C4UB_V2F"/>
+ <enum name="GL_C4UB_V3F"/>
+ <enum name="GL_N3F_V3F"/>
+ <enum name="GL_T2F_C3F_V3F"/>
+ <enum name="GL_T2F_C4F_N3F_V3F"/>
+ <enum name="GL_T2F_C4UB_V3F"/>
+ <enum name="GL_T2F_N3F_V3F"/>
+ <enum name="GL_T2F_V3F"/>
+ <enum name="GL_T4F_C4F_N3F_V4F"/>
+ <enum name="GL_T4F_V4F"/>
+ <enum name="GL_V2F"/>
+ <enum name="GL_V3F"/>
+ </group>
+
+ <group name="LightEnvModeSGIX">
+ <enum name="GL_ADD"/>
+ <enum name="GL_MODULATE"/>
+ <enum name="GL_REPLACE"/>
+ </group>
+
+ <group name="LightEnvParameterSGIX">
+ <enum name="GL_LIGHT_ENV_MODE_SGIX"/>
+ </group>
+
+ <group name="LightModelColorControl">
+ <enum name="GL_SEPARATE_SPECULAR_COLOR"/>
+ <enum name="GL_SEPARATE_SPECULAR_COLOR_EXT"/>
+ <enum name="GL_SINGLE_COLOR"/>
+ <enum name="GL_SINGLE_COLOR_EXT"/>
+ </group>
+
+ <group name="LightModelParameter">
+ <enum name="GL_LIGHT_MODEL_AMBIENT"/>
+ <enum name="GL_LIGHT_MODEL_COLOR_CONTROL"/>
+ <enum name="GL_LIGHT_MODEL_COLOR_CONTROL_EXT"/>
+ <enum name="GL_LIGHT_MODEL_LOCAL_VIEWER"/>
+ <enum name="GL_LIGHT_MODEL_TWO_SIDE"/>
+ </group>
+
+ <group name="LightName">
+ <enum name="GL_FRAGMENT_LIGHT0_SGIX"/>
+ <enum name="GL_FRAGMENT_LIGHT1_SGIX"/>
+ <enum name="GL_FRAGMENT_LIGHT2_SGIX"/>
+ <enum name="GL_FRAGMENT_LIGHT3_SGIX"/>
+ <enum name="GL_FRAGMENT_LIGHT4_SGIX"/>
+ <enum name="GL_FRAGMENT_LIGHT5_SGIX"/>
+ <enum name="GL_FRAGMENT_LIGHT6_SGIX"/>
+ <enum name="GL_FRAGMENT_LIGHT7_SGIX"/>
+ <enum name="GL_LIGHT0"/>
+ <enum name="GL_LIGHT1"/>
+ <enum name="GL_LIGHT2"/>
+ <enum name="GL_LIGHT3"/>
+ <enum name="GL_LIGHT4"/>
+ <enum name="GL_LIGHT5"/>
+ <enum name="GL_LIGHT6"/>
+ <enum name="GL_LIGHT7"/>
+ </group>
+
+ <group name="LightParameter">
+ <enum name="GL_AMBIENT"/>
+ <enum name="GL_CONSTANT_ATTENUATION"/>
+ <enum name="GL_DIFFUSE"/>
+ <enum name="GL_LINEAR_ATTENUATION"/>
+ <enum name="GL_POSITION"/>
+ <enum name="GL_QUADRATIC_ATTENUATION"/>
+ <enum name="GL_SPECULAR"/>
+ <enum name="GL_SPOT_CUTOFF"/>
+ <enum name="GL_SPOT_DIRECTION"/>
+ <enum name="GL_SPOT_EXPONENT"/>
+ </group>
+
+ <group name="ListMode">
+ <enum name="GL_COMPILE"/>
+ <enum name="GL_COMPILE_AND_EXECUTE"/>
+ </group>
+
+ <group name="ListNameType">
+ <enum name="GL_2_BYTES"/>
+ <enum name="GL_3_BYTES"/>
+ <enum name="GL_4_BYTES"/>
+ <enum name="GL_BYTE"/>
+ <enum name="GL_FLOAT"/>
+ <enum name="GL_INT"/>
+ <enum name="GL_SHORT"/>
+ <enum name="GL_UNSIGNED_BYTE"/>
+ <enum name="GL_UNSIGNED_INT"/>
+ <enum name="GL_UNSIGNED_SHORT"/>
+ </group>
+
+ <group name="ListParameterName">
+ <enum name="GL_LIST_PRIORITY_SGIX"/>
+ </group>
+
+ <group name="LogicOp">
+ <enum name="GL_AND"/>
+ <enum name="GL_AND_INVERTED"/>
+ <enum name="GL_AND_REVERSE"/>
+ <enum name="GL_CLEAR"/>
+ <enum name="GL_COPY"/>
+ <enum name="GL_COPY_INVERTED"/>
+ <enum name="GL_EQUIV"/>
+ <enum name="GL_INVERT"/>
+ <enum name="GL_NAND"/>
+ <enum name="GL_NOOP"/>
+ <enum name="GL_NOR"/>
+ <enum name="GL_OR"/>
+ <enum name="GL_OR_INVERTED"/>
+ <enum name="GL_OR_REVERSE"/>
+ <enum name="GL_SET"/>
+ <enum name="GL_XOR"/>
+ </group>
+
+ <group name="MapBufferUsageMask">
+ <enum name="GL_CLIENT_STORAGE_BIT"/>
+ <enum name="GL_DYNAMIC_STORAGE_BIT"/>
+ <enum name="GL_MAP_COHERENT_BIT"/>
+ <enum name="GL_MAP_FLUSH_EXPLICIT_BIT"/>
+ <enum name="GL_MAP_FLUSH_EXPLICIT_BIT_EXT"/>
+ <enum name="GL_MAP_INVALIDATE_BUFFER_BIT"/>
+ <enum name="GL_MAP_INVALIDATE_BUFFER_BIT_EXT"/>
+ <enum name="GL_MAP_INVALIDATE_RANGE_BIT"/>
+ <enum name="GL_MAP_INVALIDATE_RANGE_BIT_EXT"/>
+ <enum name="GL_MAP_PERSISTENT_BIT"/>
+ <enum name="GL_MAP_READ_BIT"/>
+ <enum name="GL_MAP_READ_BIT_EXT"/>
+ <enum name="GL_MAP_UNSYNCHRONIZED_BIT"/>
+ <enum name="GL_MAP_UNSYNCHRONIZED_BIT_EXT"/>
+ <enum name="GL_MAP_WRITE_BIT"/>
+ <enum name="GL_MAP_WRITE_BIT_EXT"/>
+ </group>
+
+ <group name="MapTarget">
+ <enum name="GL_GEOMETRY_DEFORMATION_SGIX"/>
+ <enum name="GL_MAP1_COLOR_4"/>
+ <enum name="GL_MAP1_INDEX"/>
+ <enum name="GL_MAP1_NORMAL"/>
+ <enum name="GL_MAP1_TEXTURE_COORD_1"/>
+ <enum name="GL_MAP1_TEXTURE_COORD_2"/>
+ <enum name="GL_MAP1_TEXTURE_COORD_3"/>
+ <enum name="GL_MAP1_TEXTURE_COORD_4"/>
+ <enum name="GL_MAP1_VERTEX_3"/>
+ <enum name="GL_MAP1_VERTEX_4"/>
+ <enum name="GL_MAP2_COLOR_4"/>
+ <enum name="GL_MAP2_INDEX"/>
+ <enum name="GL_MAP2_NORMAL"/>
+ <enum name="GL_MAP2_TEXTURE_COORD_1"/>
+ <enum name="GL_MAP2_TEXTURE_COORD_2"/>
+ <enum name="GL_MAP2_TEXTURE_COORD_3"/>
+ <enum name="GL_MAP2_TEXTURE_COORD_4"/>
+ <enum name="GL_MAP2_VERTEX_3"/>
+ <enum name="GL_MAP2_VERTEX_4"/>
+ <enum name="GL_TEXTURE_DEFORMATION_SGIX"/>
+ </group>
+
+ <group name="MapTextureFormatINTEL">
+ <enum name="GL_LAYOUT_DEFAULT_INTEL"/>
+ <enum name="GL_LAYOUT_LINEAR_CPU_CACHED_INTEL"/>
+ <enum name="GL_LAYOUT_LINEAR_INTEL"/>
+ </group>
+
+ <group name="MaterialFace">
+ <enum name="GL_BACK"/>
+ <enum name="GL_FRONT"/>
+ <enum name="GL_FRONT_AND_BACK"/>
+ </group>
+
+ <group name="MaterialParameter">
+ <enum name="GL_AMBIENT"/>
+ <enum name="GL_AMBIENT_AND_DIFFUSE"/>
+ <enum name="GL_COLOR_INDEXES"/>
+ <enum name="GL_DIFFUSE"/>
+ <enum name="GL_EMISSION"/>
+ <enum name="GL_SHININESS"/>
+ <enum name="GL_SPECULAR"/>
+ </group>
+
+ <group name="MatrixMode">
+ <enum name="GL_MODELVIEW"/>
+ <enum name="GL_MODELVIEW0_EXT"/>
+ <enum name="GL_PROJECTION"/>
+ <enum name="GL_TEXTURE"/>
+ </group>
+
+ <group name="MemoryBarrierMask">
+ <enum name="GL_ALL_BARRIER_BITS"/>
+ <enum name="GL_ALL_BARRIER_BITS_EXT"/>
+ <enum name="GL_ATOMIC_COUNTER_BARRIER_BIT"/>
+ <enum name="GL_ATOMIC_COUNTER_BARRIER_BIT_EXT"/>
+ <enum name="GL_BUFFER_UPDATE_BARRIER_BIT"/>
+ <enum name="GL_BUFFER_UPDATE_BARRIER_BIT_EXT"/>
+ <enum name="GL_CLIENT_MAPPED_BUFFER_BARRIER_BIT"/>
+ <enum name="GL_COMMAND_BARRIER_BIT"/>
+ <enum name="GL_COMMAND_BARRIER_BIT_EXT"/>
+ <enum name="GL_ELEMENT_ARRAY_BARRIER_BIT"/>
+ <enum name="GL_ELEMENT_ARRAY_BARRIER_BIT_EXT"/>
+ <enum name="GL_FRAMEBUFFER_BARRIER_BIT"/>
+ <enum name="GL_FRAMEBUFFER_BARRIER_BIT_EXT"/>
+ <enum name="GL_PIXEL_BUFFER_BARRIER_BIT"/>
+ <enum name="GL_PIXEL_BUFFER_BARRIER_BIT_EXT"/>
+ <enum name="GL_QUERY_BUFFER_BARRIER_BIT"/>
+ <enum name="GL_SHADER_GLOBAL_ACCESS_BARRIER_BIT_NV"/>
+ <enum name="GL_SHADER_IMAGE_ACCESS_BARRIER_BIT"/>
+ <enum name="GL_SHADER_IMAGE_ACCESS_BARRIER_BIT_EXT"/>
+ <enum name="GL_SHADER_STORAGE_BARRIER_BIT"/>
+ <enum name="GL_TEXTURE_FETCH_BARRIER_BIT"/>
+ <enum name="GL_TEXTURE_FETCH_BARRIER_BIT_EXT"/>
+ <enum name="GL_TEXTURE_UPDATE_BARRIER_BIT"/>
+ <enum name="GL_TEXTURE_UPDATE_BARRIER_BIT_EXT"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_BARRIER_BIT"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_BARRIER_BIT_EXT"/>
+ <enum name="GL_UNIFORM_BARRIER_BIT"/>
+ <enum name="GL_UNIFORM_BARRIER_BIT_EXT"/>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY_BARRIER_BIT"/>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY_BARRIER_BIT_EXT"/>
+ </group>
+
+ <group name="MeshMode1">
+ <enum name="GL_LINE"/>
+ <enum name="GL_POINT"/>
+ </group>
+
+ <group name="MeshMode2">
+ <enum name="GL_FILL"/>
+ <enum name="GL_LINE"/>
+ <enum name="GL_POINT"/>
+ </group>
+
+ <group name="MinmaxTargetEXT">
+ <enum name="GL_MINMAX"/>
+ <enum name="GL_MINMAX_EXT"/>
+ </group>
+
+ <group name="NormalPointerType">
+ <enum name="GL_BYTE"/>
+ <enum name="GL_DOUBLE"/>
+ <enum name="GL_FLOAT"/>
+ <enum name="GL_INT"/>
+ <enum name="GL_SHORT"/>
+ </group>
+
+ <group name="PixelCopyType">
+ <enum name="GL_COLOR"/>
+ <enum name="GL_COLOR_EXT"/>
+ <enum name="GL_DEPTH"/>
+ <enum name="GL_DEPTH_EXT"/>
+ <enum name="GL_STENCIL"/>
+ <enum name="GL_STENCIL_EXT"/>
+ </group>
+
+ <group name="PixelFormat">
+ <enum name="GL_ABGR_EXT"/>
+ <enum name="GL_ALPHA"/>
+ <enum name="GL_BLUE"/>
+ <enum name="GL_CMYKA_EXT"/>
+ <enum name="GL_CMYK_EXT"/>
+ <enum name="GL_COLOR_INDEX"/>
+ <enum name="GL_DEPTH_COMPONENT"/>
+ <enum name="GL_GREEN"/>
+ <enum name="GL_LUMINANCE"/>
+ <enum name="GL_LUMINANCE_ALPHA"/>
+ <enum name="GL_RED"/>
+ <enum name="GL_RED_EXT"/>
+ <enum name="GL_RGB"/>
+ <enum name="GL_RGBA"/>
+ <enum name="GL_STENCIL_INDEX"/>
+ <enum name="GL_UNSIGNED_INT"/>
+ <enum name="GL_UNSIGNED_SHORT"/>
+ <enum name="GL_YCRCB_422_SGIX"/>
+ <enum name="GL_YCRCB_444_SGIX"/>
+ </group>
+
+ <group name="InternalFormat" comment="Was PixelInternalFormat">
+ <enum name="GL_ALPHA12"/>
+ <enum name="GL_ALPHA16"/>
+ <enum name="GL_ALPHA16_ICC_SGIX"/>
+ <enum name="GL_ALPHA4"/>
+ <enum name="GL_ALPHA8"/>
+ <enum name="GL_ALPHA_ICC_SGIX"/>
+ <enum name="GL_DEPTH_COMPONENT16_SGIX"/>
+ <enum name="GL_DEPTH_COMPONENT24_SGIX"/>
+ <enum name="GL_DEPTH_COMPONENT32_SGIX"/>
+ <enum name="GL_DUAL_ALPHA12_SGIS"/>
+ <enum name="GL_DUAL_ALPHA16_SGIS"/>
+ <enum name="GL_DUAL_ALPHA4_SGIS"/>
+ <enum name="GL_DUAL_ALPHA8_SGIS"/>
+ <enum name="GL_DUAL_INTENSITY12_SGIS"/>
+ <enum name="GL_DUAL_INTENSITY16_SGIS"/>
+ <enum name="GL_DUAL_INTENSITY4_SGIS"/>
+ <enum name="GL_DUAL_INTENSITY8_SGIS"/>
+ <enum name="GL_DUAL_LUMINANCE12_SGIS"/>
+ <enum name="GL_DUAL_LUMINANCE16_SGIS"/>
+ <enum name="GL_DUAL_LUMINANCE4_SGIS"/>
+ <enum name="GL_DUAL_LUMINANCE8_SGIS"/>
+ <enum name="GL_DUAL_LUMINANCE_ALPHA4_SGIS"/>
+ <enum name="GL_DUAL_LUMINANCE_ALPHA8_SGIS"/>
+ <enum name="GL_INTENSITY"/>
+ <enum name="GL_INTENSITY12"/>
+ <enum name="GL_INTENSITY16"/>
+ <enum name="GL_INTENSITY16_ICC_SGIX"/>
+ <enum name="GL_INTENSITY4"/>
+ <enum name="GL_INTENSITY8"/>
+ <enum name="GL_INTENSITY_ICC_SGIX"/>
+ <enum name="GL_LUMINANCE12"/>
+ <enum name="GL_LUMINANCE12_ALPHA12"/>
+ <enum name="GL_LUMINANCE12_ALPHA4"/>
+ <enum name="GL_LUMINANCE16"/>
+ <enum name="GL_LUMINANCE16_ALPHA16"/>
+ <enum name="GL_LUMINANCE16_ALPHA8_ICC_SGIX"/>
+ <enum name="GL_LUMINANCE16_ICC_SGIX"/>
+ <enum name="GL_LUMINANCE4"/>
+ <enum name="GL_LUMINANCE4_ALPHA4"/>
+ <enum name="GL_LUMINANCE6_ALPHA2"/>
+ <enum name="GL_LUMINANCE8"/>
+ <enum name="GL_LUMINANCE8_ALPHA8"/>
+ <enum name="GL_LUMINANCE_ALPHA_ICC_SGIX"/>
+ <enum name="GL_LUMINANCE_ICC_SGIX"/>
+ <enum name="GL_QUAD_ALPHA4_SGIS"/>
+ <enum name="GL_QUAD_ALPHA8_SGIS"/>
+ <enum name="GL_QUAD_INTENSITY4_SGIS"/>
+ <enum name="GL_QUAD_INTENSITY8_SGIS"/>
+ <enum name="GL_QUAD_LUMINANCE4_SGIS"/>
+ <enum name="GL_QUAD_LUMINANCE8_SGIS"/>
+ <enum name="GL_R3_G3_B2"/>
+ <enum name="GL_R5_G6_B5_A8_ICC_SGIX"/>
+ <enum name="GL_R5_G6_B5_ICC_SGIX"/>
+ <enum name="GL_RGB10"/>
+ <enum name="GL_RGB10_A2"/>
+ <enum name="GL_RGB12"/>
+ <enum name="GL_RGB16"/>
+ <enum name="GL_RGB2_EXT"/>
+ <enum name="GL_RGB4"/>
+ <enum name="GL_RGB5"/>
+ <enum name="GL_RGB5_A1"/>
+ <enum name="GL_RGB8"/>
+ <enum name="GL_RGBA12"/>
+ <enum name="GL_RGBA16"/>
+ <enum name="GL_RGBA2"/>
+ <enum name="GL_RGBA4"/>
+ <enum name="GL_RGBA8"/>
+ <enum name="GL_RGBA_ICC_SGIX"/>
+ <enum name="GL_RGB_ICC_SGIX"/>
+ </group>
+
+ <group name="PixelMap">
+ <enum name="GL_PIXEL_MAP_A_TO_A"/>
+ <enum name="GL_PIXEL_MAP_B_TO_B"/>
+ <enum name="GL_PIXEL_MAP_G_TO_G"/>
+ <enum name="GL_PIXEL_MAP_I_TO_A"/>
+ <enum name="GL_PIXEL_MAP_I_TO_B"/>
+ <enum name="GL_PIXEL_MAP_I_TO_G"/>
+ <enum name="GL_PIXEL_MAP_I_TO_I"/>
+ <enum name="GL_PIXEL_MAP_I_TO_R"/>
+ <enum name="GL_PIXEL_MAP_R_TO_R"/>
+ <enum name="GL_PIXEL_MAP_S_TO_S"/>
+ </group>
+
+ <group name="PixelStoreParameter">
+ <enum name="GL_PACK_ALIGNMENT"/>
+ <enum name="GL_PACK_IMAGE_DEPTH_SGIS"/>
+ <enum name="GL_PACK_IMAGE_HEIGHT"/>
+ <enum name="GL_PACK_IMAGE_HEIGHT_EXT"/>
+ <enum name="GL_PACK_LSB_FIRST"/>
+ <enum name="GL_PACK_RESAMPLE_OML"/>
+ <enum name="GL_PACK_RESAMPLE_SGIX"/>
+ <enum name="GL_PACK_ROW_LENGTH"/>
+ <enum name="GL_PACK_SKIP_IMAGES"/>
+ <enum name="GL_PACK_SKIP_IMAGES_EXT"/>
+ <enum name="GL_PACK_SKIP_PIXELS"/>
+ <enum name="GL_PACK_SKIP_ROWS"/>
+ <enum name="GL_PACK_SKIP_VOLUMES_SGIS"/>
+ <enum name="GL_PACK_SUBSAMPLE_RATE_SGIX"/>
+ <enum name="GL_PACK_SWAP_BYTES"/>
+ <enum name="GL_PIXEL_TILE_CACHE_SIZE_SGIX"/>
+ <enum name="GL_PIXEL_TILE_GRID_DEPTH_SGIX"/>
+ <enum name="GL_PIXEL_TILE_GRID_HEIGHT_SGIX"/>
+ <enum name="GL_PIXEL_TILE_GRID_WIDTH_SGIX"/>
+ <enum name="GL_PIXEL_TILE_HEIGHT_SGIX"/>
+ <enum name="GL_PIXEL_TILE_WIDTH_SGIX"/>
+ <enum name="GL_UNPACK_ALIGNMENT"/>
+ <enum name="GL_UNPACK_IMAGE_DEPTH_SGIS"/>
+ <enum name="GL_UNPACK_IMAGE_HEIGHT"/>
+ <enum name="GL_UNPACK_IMAGE_HEIGHT_EXT"/>
+ <enum name="GL_UNPACK_LSB_FIRST"/>
+ <enum name="GL_UNPACK_RESAMPLE_OML"/>
+ <enum name="GL_UNPACK_RESAMPLE_SGIX"/>
+ <enum name="GL_UNPACK_ROW_LENGTH"/>
+ <enum name="GL_UNPACK_ROW_LENGTH_EXT"/>
+ <enum name="GL_UNPACK_SKIP_IMAGES"/>
+ <enum name="GL_UNPACK_SKIP_IMAGES_EXT"/>
+ <enum name="GL_UNPACK_SKIP_PIXELS"/>
+ <enum name="GL_UNPACK_SKIP_PIXELS_EXT"/>
+ <enum name="GL_UNPACK_SKIP_ROWS"/>
+ <enum name="GL_UNPACK_SKIP_ROWS_EXT"/>
+ <enum name="GL_UNPACK_SKIP_VOLUMES_SGIS"/>
+ <enum name="GL_UNPACK_SUBSAMPLE_RATE_SGIX"/>
+ <enum name="GL_UNPACK_SWAP_BYTES"/>
+ </group>
+
+ <group name="PixelStoreResampleMode">
+ <enum name="GL_RESAMPLE_DECIMATE_SGIX"/>
+ <enum name="GL_RESAMPLE_REPLICATE_SGIX"/>
+ <enum name="GL_RESAMPLE_ZERO_FILL_SGIX"/>
+ </group>
+
+ <group name="PixelStoreSubsampleRate">
+ <enum name="GL_PIXEL_SUBSAMPLE_2424_SGIX"/>
+ <enum name="GL_PIXEL_SUBSAMPLE_4242_SGIX"/>
+ <enum name="GL_PIXEL_SUBSAMPLE_4444_SGIX"/>
+ </group>
+
+ <group name="PixelTexGenMode">
+ <enum name="GL_LUMINANCE"/>
+ <enum name="GL_LUMINANCE_ALPHA"/>
+ <enum name="GL_NONE"/>
+ <enum name="GL_PIXEL_TEX_GEN_ALPHA_LS_SGIX"/>
+ <enum name="GL_PIXEL_TEX_GEN_ALPHA_MS_SGIX"/>
+ <enum name="GL_PIXEL_TEX_GEN_ALPHA_NO_REPLACE_SGIX"/>
+ <enum name="GL_PIXEL_TEX_GEN_ALPHA_REPLACE_SGIX"/>
+ <enum name="GL_RGB"/>
+ <enum name="GL_RGBA"/>
+ </group>
+
+ <group name="PixelTexGenParameterNameSGIS">
+ <enum name="GL_PIXEL_FRAGMENT_ALPHA_SOURCE_SGIS"/>
+ <enum name="GL_PIXEL_FRAGMENT_RGB_SOURCE_SGIS"/>
+ </group>
+
+ <group name="PixelTransferParameter">
+ <enum name="GL_ALPHA_BIAS"/>
+ <enum name="GL_ALPHA_SCALE"/>
+ <enum name="GL_BLUE_BIAS"/>
+ <enum name="GL_BLUE_SCALE"/>
+ <enum name="GL_DEPTH_BIAS"/>
+ <enum name="GL_DEPTH_SCALE"/>
+ <enum name="GL_GREEN_BIAS"/>
+ <enum name="GL_GREEN_SCALE"/>
+ <enum name="GL_INDEX_OFFSET"/>
+ <enum name="GL_INDEX_SHIFT"/>
+ <enum name="GL_MAP_COLOR"/>
+ <enum name="GL_MAP_STENCIL"/>
+ <enum name="GL_POST_COLOR_MATRIX_ALPHA_BIAS"/>
+ <enum name="GL_POST_COLOR_MATRIX_ALPHA_BIAS_SGI"/>
+ <enum name="GL_POST_COLOR_MATRIX_ALPHA_SCALE"/>
+ <enum name="GL_POST_COLOR_MATRIX_ALPHA_SCALE_SGI"/>
+ <enum name="GL_POST_COLOR_MATRIX_BLUE_BIAS"/>
+ <enum name="GL_POST_COLOR_MATRIX_BLUE_BIAS_SGI"/>
+ <enum name="GL_POST_COLOR_MATRIX_BLUE_SCALE"/>
+ <enum name="GL_POST_COLOR_MATRIX_BLUE_SCALE_SGI"/>
+ <enum name="GL_POST_COLOR_MATRIX_GREEN_BIAS"/>
+ <enum name="GL_POST_COLOR_MATRIX_GREEN_BIAS_SGI"/>
+ <enum name="GL_POST_COLOR_MATRIX_GREEN_SCALE"/>
+ <enum name="GL_POST_COLOR_MATRIX_GREEN_SCALE_SGI"/>
+ <enum name="GL_POST_COLOR_MATRIX_RED_BIAS"/>
+ <enum name="GL_POST_COLOR_MATRIX_RED_BIAS_SGI"/>
+ <enum name="GL_POST_COLOR_MATRIX_RED_SCALE"/>
+ <enum name="GL_POST_COLOR_MATRIX_RED_SCALE_SGI"/>
+ <enum name="GL_POST_CONVOLUTION_ALPHA_BIAS"/>
+ <enum name="GL_POST_CONVOLUTION_ALPHA_BIAS_EXT"/>
+ <enum name="GL_POST_CONVOLUTION_ALPHA_SCALE"/>
+ <enum name="GL_POST_CONVOLUTION_ALPHA_SCALE_EXT"/>
+ <enum name="GL_POST_CONVOLUTION_BLUE_BIAS"/>
+ <enum name="GL_POST_CONVOLUTION_BLUE_BIAS_EXT"/>
+ <enum name="GL_POST_CONVOLUTION_BLUE_SCALE"/>
+ <enum name="GL_POST_CONVOLUTION_BLUE_SCALE_EXT"/>
+ <enum name="GL_POST_CONVOLUTION_GREEN_BIAS"/>
+ <enum name="GL_POST_CONVOLUTION_GREEN_BIAS_EXT"/>
+ <enum name="GL_POST_CONVOLUTION_GREEN_SCALE"/>
+ <enum name="GL_POST_CONVOLUTION_GREEN_SCALE_EXT"/>
+ <enum name="GL_POST_CONVOLUTION_RED_BIAS"/>
+ <enum name="GL_POST_CONVOLUTION_RED_BIAS_EXT"/>
+ <enum name="GL_POST_CONVOLUTION_RED_SCALE"/>
+ <enum name="GL_POST_CONVOLUTION_RED_SCALE_EXT"/>
+ <enum name="GL_RED_BIAS"/>
+ <enum name="GL_RED_SCALE"/>
+ </group>
+
+ <group name="PixelType">
+ <enum name="GL_BITMAP"/>
+ <enum name="GL_BYTE"/>
+ <enum name="GL_FLOAT"/>
+ <enum name="GL_INT"/>
+ <enum name="GL_SHORT"/>
+ <enum name="GL_UNSIGNED_BYTE"/>
+ <enum name="GL_UNSIGNED_BYTE_3_3_2"/>
+ <enum name="GL_UNSIGNED_BYTE_3_3_2_EXT"/>
+ <enum name="GL_UNSIGNED_INT"/>
+ <enum name="GL_UNSIGNED_INT_10_10_10_2"/>
+ <enum name="GL_UNSIGNED_INT_10_10_10_2_EXT"/>
+ <enum name="GL_UNSIGNED_INT_8_8_8_8"/>
+ <enum name="GL_UNSIGNED_INT_8_8_8_8_EXT"/>
+ <enum name="GL_UNSIGNED_SHORT"/>
+ <enum name="GL_UNSIGNED_SHORT_4_4_4_4"/>
+ <enum name="GL_UNSIGNED_SHORT_4_4_4_4_EXT"/>
+ <enum name="GL_UNSIGNED_SHORT_5_5_5_1"/>
+ <enum name="GL_UNSIGNED_SHORT_5_5_5_1_EXT"/>
+ </group>
+
+ <group name="PointParameterNameSGIS">
+ <enum name="GL_DISTANCE_ATTENUATION_EXT"/>
+ <enum name="GL_DISTANCE_ATTENUATION_SGIS"/>
+ <enum name="GL_POINT_DISTANCE_ATTENUATION"/>
+ <enum name="GL_POINT_DISTANCE_ATTENUATION_ARB"/>
+ <enum name="GL_POINT_FADE_THRESHOLD_SIZE"/>
+ <enum name="GL_POINT_FADE_THRESHOLD_SIZE_ARB"/>
+ <enum name="GL_POINT_FADE_THRESHOLD_SIZE_EXT"/>
+ <enum name="GL_POINT_FADE_THRESHOLD_SIZE_SGIS"/>
+ <enum name="GL_POINT_SIZE_MAX"/>
+ <enum name="GL_POINT_SIZE_MAX_ARB"/>
+ <enum name="GL_POINT_SIZE_MAX_EXT"/>
+ <enum name="GL_POINT_SIZE_MAX_SGIS"/>
+ <enum name="GL_POINT_SIZE_MIN"/>
+ <enum name="GL_POINT_SIZE_MIN_ARB"/>
+ <enum name="GL_POINT_SIZE_MIN_EXT"/>
+ <enum name="GL_POINT_SIZE_MIN_SGIS"/>
+ </group>
+
+ <group name="PolygonMode">
+ <enum name="GL_FILL"/>
+ <enum name="GL_LINE"/>
+ <enum name="GL_POINT"/>
+ </group>
+
+ <group name="PrimitiveType">
+ <enum name="GL_LINES"/>
+ <enum name="GL_LINES_ADJACENCY"/>
+ <enum name="GL_LINES_ADJACENCY_ARB"/>
+ <enum name="GL_LINES_ADJACENCY_EXT"/>
+ <enum name="GL_LINE_LOOP"/>
+ <enum name="GL_LINE_STRIP"/>
+ <enum name="GL_LINE_STRIP_ADJACENCY"/>
+ <enum name="GL_LINE_STRIP_ADJACENCY_ARB"/>
+ <enum name="GL_LINE_STRIP_ADJACENCY_EXT"/>
+ <enum name="GL_PATCHES"/>
+ <enum name="GL_PATCHES_EXT"/>
+ <enum name="GL_POINTS"/>
+ <enum name="GL_POLYGON"/>
+ <enum name="GL_QUADS"/>
+ <enum name="GL_QUADS_EXT"/>
+ <enum name="GL_QUAD_STRIP"/>
+ <enum name="GL_TRIANGLES"/>
+ <enum name="GL_TRIANGLES_ADJACENCY"/>
+ <enum name="GL_TRIANGLES_ADJACENCY_ARB"/>
+ <enum name="GL_TRIANGLES_ADJACENCY_EXT"/>
+ <enum name="GL_TRIANGLE_FAN"/>
+ <enum name="GL_TRIANGLE_STRIP"/>
+ <enum name="GL_TRIANGLE_STRIP_ADJACENCY"/>
+ <enum name="GL_TRIANGLE_STRIP_ADJACENCY_ARB"/>
+ <enum name="GL_TRIANGLE_STRIP_ADJACENCY_EXT"/>
+ </group>
+
+ <group name="OcclusionQueryEventMaskAMD">
+ <enum name="GL_QUERY_DEPTH_PASS_EVENT_BIT_AMD"/>
+ <enum name="GL_QUERY_DEPTH_FAIL_EVENT_BIT_AMD"/>
+ <enum name="GL_QUERY_STENCIL_FAIL_EVENT_BIT_AMD"/>
+ <enum name="GL_QUERY_DEPTH_BOUNDS_FAIL_EVENT_BIT_AMD"/>
+ <enum name="GL_QUERY_ALL_EVENT_BITS_AMD"/>
+ </group>
+
+ <group name="ReadBufferMode">
+ <enum name="GL_AUX0"/>
+ <enum name="GL_AUX1"/>
+ <enum name="GL_AUX2"/>
+ <enum name="GL_AUX3"/>
+ <enum name="GL_BACK"/>
+ <enum name="GL_BACK_LEFT"/>
+ <enum name="GL_BACK_RIGHT"/>
+ <enum name="GL_FRONT"/>
+ <enum name="GL_FRONT_LEFT"/>
+ <enum name="GL_FRONT_RIGHT"/>
+ <enum name="GL_LEFT"/>
+ <enum name="GL_RIGHT"/>
+ </group>
+
+ <group name="RenderingMode">
+ <enum name="GL_FEEDBACK"/>
+ <enum name="GL_RENDER"/>
+ <enum name="GL_SELECT"/>
+ </group>
+
+ <group name="SamplePatternSGIS">
+ <enum name="GL_1PASS_EXT"/>
+ <enum name="GL_1PASS_SGIS"/>
+ <enum name="GL_2PASS_0_EXT"/>
+ <enum name="GL_2PASS_0_SGIS"/>
+ <enum name="GL_2PASS_1_EXT"/>
+ <enum name="GL_2PASS_1_SGIS"/>
+ <enum name="GL_4PASS_0_EXT"/>
+ <enum name="GL_4PASS_0_SGIS"/>
+ <enum name="GL_4PASS_1_EXT"/>
+ <enum name="GL_4PASS_1_SGIS"/>
+ <enum name="GL_4PASS_2_EXT"/>
+ <enum name="GL_4PASS_2_SGIS"/>
+ <enum name="GL_4PASS_3_EXT"/>
+ <enum name="GL_4PASS_3_SGIS"/>
+ </group>
+
+ <group name="SeparableTargetEXT">
+ <enum name="GL_SEPARABLE_2D"/>
+ <enum name="GL_SEPARABLE_2D_EXT"/>
+ </group>
+
+ <group name="ShadingModel">
+ <enum name="GL_FLAT"/>
+ <enum name="GL_SMOOTH"/>
+ </group>
+
+ <group name="StencilFunction">
+ <enum name="GL_ALWAYS"/>
+ <enum name="GL_EQUAL"/>
+ <enum name="GL_GEQUAL"/>
+ <enum name="GL_GREATER"/>
+ <enum name="GL_LEQUAL"/>
+ <enum name="GL_LESS"/>
+ <enum name="GL_NEVER"/>
+ <enum name="GL_NOTEQUAL"/>
+ </group>
+
+ <group name="StencilOp">
+ <enum name="GL_DECR"/>
+ <enum name="GL_INCR"/>
+ <enum name="GL_INVERT"/>
+ <enum name="GL_KEEP"/>
+ <enum name="GL_REPLACE"/>
+ <enum name="GL_ZERO"/>
+ </group>
+
+ <group name="StringName">
+ <enum name="GL_EXTENSIONS"/>
+ <enum name="GL_RENDERER"/>
+ <enum name="GL_VENDOR"/>
+ <enum name="GL_VERSION"/>
+ </group>
+
+ <group name="TexCoordPointerType">
+ <enum name="GL_DOUBLE"/>
+ <enum name="GL_FLOAT"/>
+ <enum name="GL_INT"/>
+ <enum name="GL_SHORT"/>
+ </group>
+
+ <group name="TextureCoordName">
+ <enum name="GL_S"/>
+ <enum name="GL_T"/>
+ <enum name="GL_R"/>
+ <enum name="GL_Q"/>
+ </group>
+
+ <group name="TextureEnvMode">
+ <enum name="GL_ADD"/>
+ <enum name="GL_BLEND"/>
+ <enum name="GL_DECAL"/>
+ <enum name="GL_MODULATE"/>
+ <enum name="GL_REPLACE_EXT"/>
+ <enum name="GL_TEXTURE_ENV_BIAS_SGIX"/>
+ </group>
+
+ <group name="TextureEnvParameter">
+ <enum name="GL_TEXTURE_ENV_COLOR"/>
+ <enum name="GL_TEXTURE_ENV_MODE"/>
+ </group>
+
+ <group name="TextureEnvTarget">
+ <enum name="GL_TEXTURE_ENV"/>
+ </group>
+
+ <group name="TextureFilterFuncSGIS">
+ <enum name="GL_FILTER4_SGIS"/>
+ </group>
+
+ <group name="TextureGenMode">
+ <enum name="GL_EYE_DISTANCE_TO_LINE_SGIS"/>
+ <enum name="GL_EYE_DISTANCE_TO_POINT_SGIS"/>
+ <enum name="GL_EYE_LINEAR"/>
+ <enum name="GL_OBJECT_DISTANCE_TO_LINE_SGIS"/>
+ <enum name="GL_OBJECT_DISTANCE_TO_POINT_SGIS"/>
+ <enum name="GL_OBJECT_LINEAR"/>
+ <enum name="GL_SPHERE_MAP"/>
+ </group>
+
+ <group name="TextureGenParameter">
+ <enum name="GL_EYE_LINE_SGIS"/>
+ <enum name="GL_EYE_PLANE"/>
+ <enum name="GL_EYE_POINT_SGIS"/>
+ <enum name="GL_OBJECT_LINE_SGIS"/>
+ <enum name="GL_OBJECT_PLANE"/>
+ <enum name="GL_OBJECT_POINT_SGIS"/>
+ <enum name="GL_TEXTURE_GEN_MODE"/>
+ </group>
+
+ <group name="TextureMagFilter">
+ <enum name="GL_FILTER4_SGIS"/>
+ <enum name="GL_LINEAR"/>
+ <enum name="GL_LINEAR_DETAIL_ALPHA_SGIS"/>
+ <enum name="GL_LINEAR_DETAIL_COLOR_SGIS"/>
+ <enum name="GL_LINEAR_DETAIL_SGIS"/>
+ <enum name="GL_LINEAR_SHARPEN_ALPHA_SGIS"/>
+ <enum name="GL_LINEAR_SHARPEN_COLOR_SGIS"/>
+ <enum name="GL_LINEAR_SHARPEN_SGIS"/>
+ <enum name="GL_NEAREST"/>
+ <enum name="GL_PIXEL_TEX_GEN_Q_CEILING_SGIX"/>
+ <enum name="GL_PIXEL_TEX_GEN_Q_FLOOR_SGIX"/>
+ <enum name="GL_PIXEL_TEX_GEN_Q_ROUND_SGIX"/>
+ </group>
+
+ <group name="TextureMinFilter">
+ <enum name="GL_FILTER4_SGIS"/>
+ <enum name="GL_LINEAR"/>
+ <enum name="GL_LINEAR_CLIPMAP_LINEAR_SGIX"/>
+ <enum name="GL_LINEAR_CLIPMAP_NEAREST_SGIX"/>
+ <enum name="GL_LINEAR_MIPMAP_LINEAR"/>
+ <enum name="GL_LINEAR_MIPMAP_NEAREST"/>
+ <enum name="GL_NEAREST"/>
+ <enum name="GL_NEAREST_CLIPMAP_LINEAR_SGIX"/>
+ <enum name="GL_NEAREST_CLIPMAP_NEAREST_SGIX"/>
+ <enum name="GL_NEAREST_MIPMAP_LINEAR"/>
+ <enum name="GL_NEAREST_MIPMAP_NEAREST"/>
+ <enum name="GL_PIXEL_TEX_GEN_Q_CEILING_SGIX"/>
+ <enum name="GL_PIXEL_TEX_GEN_Q_FLOOR_SGIX"/>
+ <enum name="GL_PIXEL_TEX_GEN_Q_ROUND_SGIX"/>
+ </group>
+
+ <group name="TextureParameterName">
+ <enum name="GL_DETAIL_TEXTURE_LEVEL_SGIS"/>
+ <enum name="GL_DETAIL_TEXTURE_MODE_SGIS"/>
+ <enum name="GL_DUAL_TEXTURE_SELECT_SGIS"/>
+ <enum name="GL_GENERATE_MIPMAP"/>
+ <enum name="GL_GENERATE_MIPMAP_SGIS"/>
+ <enum name="GL_POST_TEXTURE_FILTER_BIAS_SGIX"/>
+ <enum name="GL_POST_TEXTURE_FILTER_SCALE_SGIX"/>
+ <enum name="GL_QUAD_TEXTURE_SELECT_SGIS"/>
+ <enum name="GL_SHADOW_AMBIENT_SGIX"/>
+ <enum name="GL_TEXTURE_BORDER_COLOR"/>
+ <enum name="GL_TEXTURE_CLIPMAP_CENTER_SGIX"/>
+ <enum name="GL_TEXTURE_CLIPMAP_DEPTH_SGIX"/>
+ <enum name="GL_TEXTURE_CLIPMAP_FRAME_SGIX"/>
+ <enum name="GL_TEXTURE_CLIPMAP_LOD_OFFSET_SGIX"/>
+ <enum name="GL_TEXTURE_CLIPMAP_OFFSET_SGIX"/>
+ <enum name="GL_TEXTURE_CLIPMAP_VIRTUAL_DEPTH_SGIX"/>
+ <enum name="GL_TEXTURE_COMPARE_SGIX"/>
+ <enum name="GL_TEXTURE_LOD_BIAS_R_SGIX"/>
+ <enum name="GL_TEXTURE_LOD_BIAS_S_SGIX"/>
+ <enum name="GL_TEXTURE_LOD_BIAS_T_SGIX"/>
+ <enum name="GL_TEXTURE_MAG_FILTER"/>
+ <enum name="GL_TEXTURE_MAX_CLAMP_R_SGIX"/>
+ <enum name="GL_TEXTURE_MAX_CLAMP_S_SGIX"/>
+ <enum name="GL_TEXTURE_MAX_CLAMP_T_SGIX"/>
+ <enum name="GL_TEXTURE_MIN_FILTER"/>
+ <enum name="GL_TEXTURE_PRIORITY"/>
+ <enum name="GL_TEXTURE_PRIORITY_EXT"/>
+ <enum name="GL_TEXTURE_WRAP_Q_SGIS"/>
+ <enum name="GL_TEXTURE_WRAP_R"/>
+ <enum name="GL_TEXTURE_WRAP_R_EXT"/>
+ <enum name="GL_TEXTURE_WRAP_R_OES"/>
+ <enum name="GL_TEXTURE_WRAP_S"/>
+ <enum name="GL_TEXTURE_WRAP_T"/>
+ </group>
+
+ <group name="TextureTarget">
+ <enum name="GL_DETAIL_TEXTURE_2D_SGIS"/>
+ <enum name="GL_PROXY_TEXTURE_1D"/>
+ <enum name="GL_PROXY_TEXTURE_1D_EXT"/>
+ <enum name="GL_PROXY_TEXTURE_2D"/>
+ <enum name="GL_PROXY_TEXTURE_2D_EXT"/>
+ <enum name="GL_PROXY_TEXTURE_3D"/>
+ <enum name="GL_PROXY_TEXTURE_3D_EXT"/>
+ <enum name="GL_PROXY_TEXTURE_4D_SGIS"/>
+ <enum name="GL_TEXTURE_1D"/>
+ <enum name="GL_TEXTURE_2D"/>
+ <enum name="GL_TEXTURE_3D"/>
+ <enum name="GL_TEXTURE_3D_EXT"/>
+ <enum name="GL_TEXTURE_3D_OES"/>
+ <enum name="GL_TEXTURE_4D_SGIS"/>
+ <enum name="GL_TEXTURE_BASE_LEVEL"/>
+ <enum name="GL_TEXTURE_BASE_LEVEL_SGIS"/>
+ <enum name="GL_TEXTURE_MAX_LEVEL"/>
+ <enum name="GL_TEXTURE_MAX_LEVEL_SGIS"/>
+ <enum name="GL_TEXTURE_MAX_LOD"/>
+ <enum name="GL_TEXTURE_MAX_LOD_SGIS"/>
+ <enum name="GL_TEXTURE_MIN_LOD"/>
+ <enum name="GL_TEXTURE_MIN_LOD_SGIS"/>
+ </group>
+
+ <group name="TextureWrapMode">
+ <enum name="GL_CLAMP"/>
+ <enum name="GL_CLAMP_TO_BORDER"/>
+ <enum name="GL_CLAMP_TO_BORDER_ARB"/>
+ <enum name="GL_CLAMP_TO_BORDER_NV"/>
+ <enum name="GL_CLAMP_TO_BORDER_SGIS"/>
+ <enum name="GL_CLAMP_TO_EDGE"/>
+ <enum name="GL_CLAMP_TO_EDGE_SGIS"/>
+ <enum name="GL_REPEAT"/>
+ </group>
+
+ <group name="UseProgramStageMask">
+ <enum name="GL_VERTEX_SHADER_BIT"/>
+ <enum name="GL_VERTEX_SHADER_BIT_EXT"/>
+ <enum name="GL_FRAGMENT_SHADER_BIT"/>
+ <enum name="GL_FRAGMENT_SHADER_BIT_EXT"/>
+ <enum name="GL_GEOMETRY_SHADER_BIT"/>
+ <enum name="GL_GEOMETRY_SHADER_BIT_EXT"/>
+ <enum name="GL_TESS_CONTROL_SHADER_BIT"/>
+ <enum name="GL_TESS_CONTROL_SHADER_BIT_EXT"/>
+ <enum name="GL_TESS_EVALUATION_SHADER_BIT"/>
+ <enum name="GL_TESS_EVALUATION_SHADER_BIT_EXT"/>
+ <enum name="GL_COMPUTE_SHADER_BIT"/>
+ <enum name="GL_ALL_SHADER_BITS"/>
+ <enum name="GL_ALL_SHADER_BITS_EXT"/>
+ </group>
+
+ <group name="VertexPointerType">
+ <enum name="GL_DOUBLE"/>
+ <enum name="GL_FLOAT"/>
+ <enum name="GL_INT"/>
+ <enum name="GL_SHORT"/>
+ </group>
+ </groups>
+
+ <!-- SECTION: GL enumerant (token) definitions. -->
+
+ <!-- Bitmasks each have their own namespace, although bits are
+ sometimes reused for other purposes -->
+
+ <enums namespace="GL" group="AttribMask" type="bitmask">
+ <enum value="0x00000001" name="GL_CURRENT_BIT"/>
+ <enum value="0x00000002" name="GL_POINT_BIT"/>
+ <enum value="0x00000004" name="GL_LINE_BIT"/>
+ <enum value="0x00000008" name="GL_POLYGON_BIT"/>
+ <enum value="0x00000010" name="GL_POLYGON_STIPPLE_BIT"/>
+ <enum value="0x00000020" name="GL_PIXEL_MODE_BIT"/>
+ <enum value="0x00000040" name="GL_LIGHTING_BIT"/>
+ <enum value="0x00000080" name="GL_FOG_BIT"/>
+ <enum value="0x00000100" name="GL_DEPTH_BUFFER_BIT"/>
+ <enum value="0x00000200" name="GL_ACCUM_BUFFER_BIT"/>
+ <enum value="0x00000400" name="GL_STENCIL_BUFFER_BIT"/>
+ <enum value="0x00000800" name="GL_VIEWPORT_BIT"/>
+ <enum value="0x00001000" name="GL_TRANSFORM_BIT"/>
+ <enum value="0x00002000" name="GL_ENABLE_BIT"/>
+ <enum value="0x00004000" name="GL_COLOR_BUFFER_BIT"/>
+ <enum value="0x00008000" name="GL_HINT_BIT"/>
+ <enum value="0x00010000" name="GL_EVAL_BIT"/>
+ <enum value="0x00020000" name="GL_LIST_BIT"/>
+ <enum value="0x00040000" name="GL_TEXTURE_BIT"/>
+ <enum value="0x00080000" name="GL_SCISSOR_BIT"/>
+ <enum value="0x20000000" name="GL_MULTISAMPLE_BIT"/>
+ <enum value="0x20000000" name="GL_MULTISAMPLE_BIT_ARB"/>
+ <enum value="0x20000000" name="GL_MULTISAMPLE_BIT_EXT"/>
+ <enum value="0x20000000" name="GL_MULTISAMPLE_BIT_3DFX"/>
+ <enum value="0xFFFFFFFF" name="GL_ALL_ATTRIB_BITS" comment="Guaranteed to mark all attribute groups at once"/>
+ </enums>
+
+ <enums namespace="GL" group="ClearBufferMask" type="bitmask" comment="GL_{DEPTH,ACCUM,STENCIL,COLOR}_BUFFER_BIT also lie in this namespace">
+ <enum value="0x00008000" name="GL_COVERAGE_BUFFER_BIT_NV" comment="Collides with AttribMask bit GL_HINT_BIT. OK since this token is for OpenGL ES 2, which doesn't have attribute groups."/>
+ <!-- Also used: 0x00004700 for bits reused from AttribMask above -->
+ </enums>
+
+ <enums namespace="GL" group="ClientAttribMask" type="bitmask">
+ <enum value="0x00000001" name="GL_CLIENT_PIXEL_STORE_BIT"/>
+ <enum value="0x00000002" name="GL_CLIENT_VERTEX_ARRAY_BIT"/>
+ <enum value="0xFFFFFFFF" name="GL_CLIENT_ALL_ATTRIB_BITS"/>
+ </enums>
+
+ <enums namespace="GL" group="ContextFlagMask" type="bitmask" comment="Should be shared with WGL/GLX, but aren't since the FORWARD_COMPATIBLE and DEBUG values are swapped vs. WGL/GLX.">
+ <enum value="0x00000001" name="GL_CONTEXT_FLAG_FORWARD_COMPATIBLE_BIT"/>
+ <enum value="0x00000002" name="GL_CONTEXT_FLAG_DEBUG_BIT"/>
+ <enum value="0x00000002" name="GL_CONTEXT_FLAG_DEBUG_BIT_KHR"/>
+ <enum value="0x00000004" name="GL_CONTEXT_FLAG_ROBUST_ACCESS_BIT_ARB"/>
+ <enum value="0x00000004" name="GL_CONTEXT_FLAG_ROBUST_ACCESS_BIT"/>
+ </enums>
+
+ <enums namespace="GL" group="ContextProfileMask" type="bitmask">
+ <enum value="0x00000001" name="GL_CONTEXT_CORE_PROFILE_BIT"/>
+ <enum value="0x00000002" name="GL_CONTEXT_COMPATIBILITY_PROFILE_BIT"/>
+ </enums>
+
+ <enums namespace="GL" group="MapBufferUsageMask" type="bitmask">
+ <enum value="0x0001" name="GL_MAP_READ_BIT"/>
+ <enum value="0x0001" name="GL_MAP_READ_BIT_EXT"/>
+ <enum value="0x0002" name="GL_MAP_WRITE_BIT"/>
+ <enum value="0x0002" name="GL_MAP_WRITE_BIT_EXT"/>
+ <enum value="0x0004" name="GL_MAP_INVALIDATE_RANGE_BIT"/>
+ <enum value="0x0004" name="GL_MAP_INVALIDATE_RANGE_BIT_EXT"/>
+ <enum value="0x0008" name="GL_MAP_INVALIDATE_BUFFER_BIT"/>
+ <enum value="0x0008" name="GL_MAP_INVALIDATE_BUFFER_BIT_EXT"/>
+ <enum value="0x0010" name="GL_MAP_FLUSH_EXPLICIT_BIT"/>
+ <enum value="0x0010" name="GL_MAP_FLUSH_EXPLICIT_BIT_EXT"/>
+ <enum value="0x0020" name="GL_MAP_UNSYNCHRONIZED_BIT"/>
+ <enum value="0x0020" name="GL_MAP_UNSYNCHRONIZED_BIT_EXT"/>
+ <enum value="0x0040" name="GL_MAP_PERSISTENT_BIT"/>
+ <enum value="0x0080" name="GL_MAP_COHERENT_BIT"/>
+ <enum value="0x0100" name="GL_DYNAMIC_STORAGE_BIT"/>
+ <enum value="0x0200" name="GL_CLIENT_STORAGE_BIT"/>
+ <enum value="0x0400" name="GL_SPARSE_STORAGE_BIT_ARB"/>
+ </enums>
+
+ <enums namespace="GL" group="MemoryBarrierMask" type="bitmask">
+ <enum value="0x00000001" name="GL_VERTEX_ATTRIB_ARRAY_BARRIER_BIT"/>
+ <enum value="0x00000001" name="GL_VERTEX_ATTRIB_ARRAY_BARRIER_BIT_EXT"/>
+ <enum value="0x00000002" name="GL_ELEMENT_ARRAY_BARRIER_BIT"/>
+ <enum value="0x00000002" name="GL_ELEMENT_ARRAY_BARRIER_BIT_EXT"/>
+ <enum value="0x00000004" name="GL_UNIFORM_BARRIER_BIT"/>
+ <enum value="0x00000004" name="GL_UNIFORM_BARRIER_BIT_EXT"/>
+ <enum value="0x00000008" name="GL_TEXTURE_FETCH_BARRIER_BIT"/>
+ <enum value="0x00000008" name="GL_TEXTURE_FETCH_BARRIER_BIT_EXT"/>
+ <enum value="0x00000010" name="GL_SHADER_GLOBAL_ACCESS_BARRIER_BIT_NV"/>
+ <enum value="0x00000020" name="GL_SHADER_IMAGE_ACCESS_BARRIER_BIT"/>
+ <enum value="0x00000020" name="GL_SHADER_IMAGE_ACCESS_BARRIER_BIT_EXT"/>
+ <enum value="0x00000040" name="GL_COMMAND_BARRIER_BIT"/>
+ <enum value="0x00000040" name="GL_COMMAND_BARRIER_BIT_EXT"/>
+ <enum value="0x00000080" name="GL_PIXEL_BUFFER_BARRIER_BIT"/>
+ <enum value="0x00000080" name="GL_PIXEL_BUFFER_BARRIER_BIT_EXT"/>
+ <enum value="0x00000100" name="GL_TEXTURE_UPDATE_BARRIER_BIT"/>
+ <enum value="0x00000100" name="GL_TEXTURE_UPDATE_BARRIER_BIT_EXT"/>
+ <enum value="0x00000200" name="GL_BUFFER_UPDATE_BARRIER_BIT"/>
+ <enum value="0x00000200" name="GL_BUFFER_UPDATE_BARRIER_BIT_EXT"/>
+ <enum value="0x00000400" name="GL_FRAMEBUFFER_BARRIER_BIT"/>
+ <enum value="0x00000400" name="GL_FRAMEBUFFER_BARRIER_BIT_EXT"/>
+ <enum value="0x00000800" name="GL_TRANSFORM_FEEDBACK_BARRIER_BIT"/>
+ <enum value="0x00000800" name="GL_TRANSFORM_FEEDBACK_BARRIER_BIT_EXT"/>
+ <enum value="0x00001000" name="GL_ATOMIC_COUNTER_BARRIER_BIT"/>
+ <enum value="0x00001000" name="GL_ATOMIC_COUNTER_BARRIER_BIT_EXT"/>
+ <enum value="0x00002000" name="GL_SHADER_STORAGE_BARRIER_BIT"/>
+ <enum value="0x00004000" name="GL_CLIENT_MAPPED_BUFFER_BARRIER_BIT"/>
+ <enum value="0x00008000" name="GL_QUERY_BUFFER_BARRIER_BIT"/>
+ <enum value="0xFFFFFFFF" name="GL_ALL_BARRIER_BITS"/>
+ <enum value="0xFFFFFFFF" name="GL_ALL_BARRIER_BITS_EXT"/>
+ </enums>
+
+ <enums namespace="OcclusionQueryEventMaskAMD">
+ <enum value="0x00000001" name="GL_QUERY_DEPTH_PASS_EVENT_BIT_AMD"/>
+ <enum value="0x00000002" name="GL_QUERY_DEPTH_FAIL_EVENT_BIT_AMD"/>
+ <enum value="0x00000004" name="GL_QUERY_STENCIL_FAIL_EVENT_BIT_AMD"/>
+ <enum value="0x00000008" name="GL_QUERY_DEPTH_BOUNDS_FAIL_EVENT_BIT_AMD"/>
+ <enum value="0xFFFFFFFF" name="GL_QUERY_ALL_EVENT_BITS_AMD"/>
+ </enums>
+
+ <enums namespace="GL" group="SyncObjectMask" type="bitmask">
+ <enum value="0x00000001" name="GL_SYNC_FLUSH_COMMANDS_BIT"/>
+ <enum value="0x00000001" name="GL_SYNC_FLUSH_COMMANDS_BIT_APPLE"/>
+ </enums>
+
+ <enums namespace="GL" group="UseProgramStageMask" type="bitmask">
+ <enum value="0x00000001" name="GL_VERTEX_SHADER_BIT"/>
+ <enum value="0x00000001" name="GL_VERTEX_SHADER_BIT_EXT"/>
+ <enum value="0x00000002" name="GL_FRAGMENT_SHADER_BIT"/>
+ <enum value="0x00000002" name="GL_FRAGMENT_SHADER_BIT_EXT"/>
+ <enum value="0x00000004" name="GL_GEOMETRY_SHADER_BIT"/>
+ <enum value="0x00000004" name="GL_GEOMETRY_SHADER_BIT_EXT"/>
+ <enum value="0x00000008" name="GL_TESS_CONTROL_SHADER_BIT"/>
+ <enum value="0x00000008" name="GL_TESS_CONTROL_SHADER_BIT_EXT"/>
+ <enum value="0x00000010" name="GL_TESS_EVALUATION_SHADER_BIT"/>
+ <enum value="0x00000010" name="GL_TESS_EVALUATION_SHADER_BIT_EXT"/>
+ <enum value="0x00000020" name="GL_COMPUTE_SHADER_BIT"/>
+ <enum value="0xFFFFFFFF" name="GL_ALL_SHADER_BITS"/>
+ <enum value="0xFFFFFFFF" name="GL_ALL_SHADER_BITS_EXT"/>
+ </enums>
+
+ <!-- Bitmasks defined by vendor extensions -->
+
+ <enums namespace="GL" group="TextureStorageMaskAMD" type="bitmask">
+ <enum value="0x00000001" name="GL_TEXTURE_STORAGE_SPARSE_BIT_AMD"/>
+ </enums>
+
+ <enums namespace="GL" group="FragmentShaderDestMaskATI" type="bitmask">
+ <enum value="0x00000001" name="GL_RED_BIT_ATI"/>
+ <enum value="0x00000002" name="GL_GREEN_BIT_ATI"/>
+ <enum value="0x00000004" name="GL_BLUE_BIT_ATI"/>
+ </enums>
+
+ <enums namespace="GL" group="FragmentShaderDestModMaskATI" type="bitmask">
+ <enum value="0x00000001" name="GL_2X_BIT_ATI"/>
+ <enum value="0x00000002" name="GL_4X_BIT_ATI"/>
+ <enum value="0x00000004" name="GL_8X_BIT_ATI"/>
+ <enum value="0x00000008" name="GL_HALF_BIT_ATI"/>
+ <enum value="0x00000010" name="GL_QUARTER_BIT_ATI"/>
+ <enum value="0x00000020" name="GL_EIGHTH_BIT_ATI"/>
+ <enum value="0x00000040" name="GL_SATURATE_BIT_ATI"/>
+ </enums>
+
+ <enums namespace="GL" group="FragmentShaderColorModMaskATI" type="bitmask">
+ <!-- Also used: 0x00000001 for GL_2X_BIT_ATI reused from FragmentShaderDestModMaskAT above -->
+ <enum value="0x00000002" name="GL_COMP_BIT_ATI"/>
+ <enum value="0x00000004" name="GL_NEGATE_BIT_ATI"/>
+ <enum value="0x00000008" name="GL_BIAS_BIT_ATI"/>
+ </enums>
+
+ <enums namespace="GL" group="TraceMaskMESA" type="bitmask">
+ <enum value="0x0001" name="GL_TRACE_OPERATIONS_BIT_MESA"/>
+ <enum value="0x0002" name="GL_TRACE_PRIMITIVES_BIT_MESA"/>
+ <enum value="0x0004" name="GL_TRACE_ARRAYS_BIT_MESA"/>
+ <enum value="0x0008" name="GL_TRACE_TEXTURES_BIT_MESA"/>
+ <enum value="0x0010" name="GL_TRACE_PIXELS_BIT_MESA"/>
+ <enum value="0x0020" name="GL_TRACE_ERRORS_BIT_MESA"/>
+ <enum value="0xFFFF" name="GL_TRACE_ALL_BITS_MESA"/>
+ </enums>
+
+ <enums namespace="GL" group="PathRenderingMaskNV" type="bitmask">
+ <enum value="0x01" name="GL_BOLD_BIT_NV"/>
+ <enum value="0x02" name="GL_ITALIC_BIT_NV"/>
+ <enum value="0x01" name="GL_GLYPH_WIDTH_BIT_NV"/>
+ <enum value="0x02" name="GL_GLYPH_HEIGHT_BIT_NV"/>
+ <enum value="0x04" name="GL_GLYPH_HORIZONTAL_BEARING_X_BIT_NV"/>
+ <enum value="0x08" name="GL_GLYPH_HORIZONTAL_BEARING_Y_BIT_NV"/>
+ <enum value="0x10" name="GL_GLYPH_HORIZONTAL_BEARING_ADVANCE_BIT_NV"/>
+ <enum value="0x20" name="GL_GLYPH_VERTICAL_BEARING_X_BIT_NV"/>
+ <enum value="0x40" name="GL_GLYPH_VERTICAL_BEARING_Y_BIT_NV"/>
+ <enum value="0x80" name="GL_GLYPH_VERTICAL_BEARING_ADVANCE_BIT_NV"/>
+ <enum value="0x100" name="GL_GLYPH_HAS_KERNING_BIT_NV"/>
+ <enum value="0x00010000" name="GL_FONT_X_MIN_BOUNDS_BIT_NV"/>
+ <enum value="0x00020000" name="GL_FONT_Y_MIN_BOUNDS_BIT_NV"/>
+ <enum value="0x00040000" name="GL_FONT_X_MAX_BOUNDS_BIT_NV"/>
+ <enum value="0x00080000" name="GL_FONT_Y_MAX_BOUNDS_BIT_NV"/>
+ <enum value="0x00100000" name="GL_FONT_UNITS_PER_EM_BIT_NV"/>
+ <enum value="0x00200000" name="GL_FONT_ASCENDER_BIT_NV"/>
+ <enum value="0x00400000" name="GL_FONT_DESCENDER_BIT_NV"/>
+ <enum value="0x00800000" name="GL_FONT_HEIGHT_BIT_NV"/>
+ <enum value="0x01000000" name="GL_FONT_MAX_ADVANCE_WIDTH_BIT_NV"/>
+ <enum value="0x02000000" name="GL_FONT_MAX_ADVANCE_HEIGHT_BIT_NV"/>
+ <enum value="0x04000000" name="GL_FONT_UNDERLINE_POSITION_BIT_NV"/>
+ <enum value="0x08000000" name="GL_FONT_UNDERLINE_THICKNESS_BIT_NV"/>
+ <enum value="0x10000000" name="GL_FONT_HAS_KERNING_BIT_NV"/>
+ <enum value="0x20000000" name="GL_FONT_NUM_GLYPH_INDICES_BIT_NV"/>
+ </enums>
+
+ <enums namespace="GL" group="PerformanceQueryCapsMaskINTEL" type="bitmask">
+ <enum value="0x00000000" name="GL_PERFQUERY_SINGLE_CONTEXT_INTEL"/>
+ <enum value="0x00000001" name="GL_PERFQUERY_GLOBAL_CONTEXT_INTEL"/>
+ </enums>
+
+ <enums namespace="GL" group="VertexHintsMaskPGI" type="bitmask">
+ <enum value="0x00000004" name="GL_VERTEX23_BIT_PGI"/>
+ <enum value="0x00000008" name="GL_VERTEX4_BIT_PGI"/>
+ <enum value="0x00010000" name="GL_COLOR3_BIT_PGI"/>
+ <enum value="0x00020000" name="GL_COLOR4_BIT_PGI"/>
+ <enum value="0x00040000" name="GL_EDGEFLAG_BIT_PGI"/>
+ <enum value="0x00080000" name="GL_INDEX_BIT_PGI"/>
+ <enum value="0x00100000" name="GL_MAT_AMBIENT_BIT_PGI"/>
+ <enum value="0x00200000" name="GL_MAT_AMBIENT_AND_DIFFUSE_BIT_PGI"/>
+ <enum value="0x00400000" name="GL_MAT_DIFFUSE_BIT_PGI"/>
+ <enum value="0x00800000" name="GL_MAT_EMISSION_BIT_PGI"/>
+ <enum value="0x01000000" name="GL_MAT_COLOR_INDEXES_BIT_PGI"/>
+ <enum value="0x02000000" name="GL_MAT_SHININESS_BIT_PGI"/>
+ <enum value="0x04000000" name="GL_MAT_SPECULAR_BIT_PGI"/>
+ <enum value="0x08000000" name="GL_NORMAL_BIT_PGI"/>
+ <enum value="0x10000000" name="GL_TEXCOORD1_BIT_PGI"/>
+ <enum value="0x20000000" name="GL_TEXCOORD2_BIT_PGI"/>
+ <enum value="0x40000000" name="GL_TEXCOORD3_BIT_PGI"/>
+ <enum value="0x80000000" name="GL_TEXCOORD4_BIT_PGI"/>
+ </enums>
+
+ <enums namespace="GL" group="BufferBitQCOM" type="bitmask">
+ <enum value="0x00000001" name="GL_COLOR_BUFFER_BIT0_QCOM"/>
+ <enum value="0x00000002" name="GL_COLOR_BUFFER_BIT1_QCOM"/>
+ <enum value="0x00000004" name="GL_COLOR_BUFFER_BIT2_QCOM"/>
+ <enum value="0x00000008" name="GL_COLOR_BUFFER_BIT3_QCOM"/>
+ <enum value="0x00000010" name="GL_COLOR_BUFFER_BIT4_QCOM"/>
+ <enum value="0x00000020" name="GL_COLOR_BUFFER_BIT5_QCOM"/>
+ <enum value="0x00000040" name="GL_COLOR_BUFFER_BIT6_QCOM"/>
+ <enum value="0x00000080" name="GL_COLOR_BUFFER_BIT7_QCOM"/>
+ <enum value="0x00000100" name="GL_DEPTH_BUFFER_BIT0_QCOM"/>
+ <enum value="0x00000200" name="GL_DEPTH_BUFFER_BIT1_QCOM"/>
+ <enum value="0x00000400" name="GL_DEPTH_BUFFER_BIT2_QCOM"/>
+ <enum value="0x00000800" name="GL_DEPTH_BUFFER_BIT3_QCOM"/>
+ <enum value="0x00001000" name="GL_DEPTH_BUFFER_BIT4_QCOM"/>
+ <enum value="0x00002000" name="GL_DEPTH_BUFFER_BIT5_QCOM"/>
+ <enum value="0x00004000" name="GL_DEPTH_BUFFER_BIT6_QCOM"/>
+ <enum value="0x00008000" name="GL_DEPTH_BUFFER_BIT7_QCOM"/>
+ <enum value="0x00010000" name="GL_STENCIL_BUFFER_BIT0_QCOM"/>
+ <enum value="0x00020000" name="GL_STENCIL_BUFFER_BIT1_QCOM"/>
+ <enum value="0x00040000" name="GL_STENCIL_BUFFER_BIT2_QCOM"/>
+ <enum value="0x00080000" name="GL_STENCIL_BUFFER_BIT3_QCOM"/>
+ <enum value="0x00100000" name="GL_STENCIL_BUFFER_BIT4_QCOM"/>
+ <enum value="0x00200000" name="GL_STENCIL_BUFFER_BIT5_QCOM"/>
+ <enum value="0x00400000" name="GL_STENCIL_BUFFER_BIT6_QCOM"/>
+ <enum value="0x00800000" name="GL_STENCIL_BUFFER_BIT7_QCOM"/>
+ <enum value="0x01000000" name="GL_MULTISAMPLE_BUFFER_BIT0_QCOM"/>
+ <enum value="0x02000000" name="GL_MULTISAMPLE_BUFFER_BIT1_QCOM"/>
+ <enum value="0x04000000" name="GL_MULTISAMPLE_BUFFER_BIT2_QCOM"/>
+ <enum value="0x08000000" name="GL_MULTISAMPLE_BUFFER_BIT3_QCOM"/>
+ <enum value="0x10000000" name="GL_MULTISAMPLE_BUFFER_BIT4_QCOM"/>
+ <enum value="0x20000000" name="GL_MULTISAMPLE_BUFFER_BIT5_QCOM"/>
+ <enum value="0x40000000" name="GL_MULTISAMPLE_BUFFER_BIT6_QCOM"/>
+ <enum value="0x80000000" name="GL_MULTISAMPLE_BUFFER_BIT7_QCOM"/>
+ </enums>
+
+ <enums namespace="GL" group="FfdMaskSGIX" type="bitmask">
+ <enum value="0x00000001" name="GL_TEXTURE_DEFORMATION_BIT_SGIX"/>
+ <enum value="0x00000002" name="GL_GEOMETRY_DEFORMATION_BIT_SGIX"/>
+ </enums>
+
+ <!-- Non-bitmask enums with their own namespace. Generally small numbers
+ used for indexed access. -->
+
+ <enums namespace="GL" group="TriangleListSUN" vendor="SUN">
+ <enum value="0x0001" name="GL_RESTART_SUN"/>
+ <enum value="0x0002" name="GL_REPLACE_MIDDLE_SUN"/>
+ <enum value="0x0003" name="GL_REPLACE_OLDEST_SUN"/>
+ </enums>
+
+ <enums namespace="GL" group="MapTextureFormatINTEL" vendor="INTEL" comment="Texture memory layouts for INTEL_map_texture">
+ <enum value="0" name="GL_LAYOUT_DEFAULT_INTEL"/>
+ <enum value="1" name="GL_LAYOUT_LINEAR_INTEL"/>
+ <enum value="2" name="GL_LAYOUT_LINEAR_CPU_CACHED_INTEL"/>
+ </enums>
+
+ <enums namespace="GL" group="TransformFeedbackTokenNV" vendor="NV" comment="For NV_transform_feedback. No clue why small negative values are used">
+ <enum value="-2" name="GL_NEXT_BUFFER_NV"/>
+ <enum value="-3" name="GL_SKIP_COMPONENTS4_NV"/>
+ <enum value="-4" name="GL_SKIP_COMPONENTS3_NV"/>
+ <enum value="-5" name="GL_SKIP_COMPONENTS2_NV"/>
+ <enum value="-6" name="GL_SKIP_COMPONENTS1_NV"/>
+ </enums>
+
+ <enums namespace="GL" group="PathRenderingTokenNV" vendor="NV">
+ <enum value="0x00" name="GL_CLOSE_PATH_NV"/>
+ <enum value="0x02" name="GL_MOVE_TO_NV"/>
+ <enum value="0x03" name="GL_RELATIVE_MOVE_TO_NV"/>
+ <enum value="0x04" name="GL_LINE_TO_NV"/>
+ <enum value="0x05" name="GL_RELATIVE_LINE_TO_NV"/>
+ <enum value="0x06" name="GL_HORIZONTAL_LINE_TO_NV"/>
+ <enum value="0x07" name="GL_RELATIVE_HORIZONTAL_LINE_TO_NV"/>
+ <enum value="0x08" name="GL_VERTICAL_LINE_TO_NV"/>
+ <enum value="0x09" name="GL_RELATIVE_VERTICAL_LINE_TO_NV"/>
+ <enum value="0x0A" name="GL_QUADRATIC_CURVE_TO_NV"/>
+ <enum value="0x0B" name="GL_RELATIVE_QUADRATIC_CURVE_TO_NV"/>
+ <enum value="0x0C" name="GL_CUBIC_CURVE_TO_NV"/>
+ <enum value="0x0D" name="GL_RELATIVE_CUBIC_CURVE_TO_NV"/>
+ <enum value="0x0E" name="GL_SMOOTH_QUADRATIC_CURVE_TO_NV"/>
+ <enum value="0x0F" name="GL_RELATIVE_SMOOTH_QUADRATIC_CURVE_TO_NV"/>
+ <enum value="0x10" name="GL_SMOOTH_CUBIC_CURVE_TO_NV"/>
+ <enum value="0x11" name="GL_RELATIVE_SMOOTH_CUBIC_CURVE_TO_NV"/>
+ <enum value="0x12" name="GL_SMALL_CCW_ARC_TO_NV"/>
+ <enum value="0x13" name="GL_RELATIVE_SMALL_CCW_ARC_TO_NV"/>
+ <enum value="0x14" name="GL_SMALL_CW_ARC_TO_NV"/>
+ <enum value="0x15" name="GL_RELATIVE_SMALL_CW_ARC_TO_NV"/>
+ <enum value="0x16" name="GL_LARGE_CCW_ARC_TO_NV"/>
+ <enum value="0x17" name="GL_RELATIVE_LARGE_CCW_ARC_TO_NV"/>
+ <enum value="0x18" name="GL_LARGE_CW_ARC_TO_NV"/>
+ <enum value="0x19" name="GL_RELATIVE_LARGE_CW_ARC_TO_NV"/>
+ <enum value="0x1A" name="GL_CONIC_CURVE_TO_NV"/>
+ <enum value="0x1B" name="GL_RELATIVE_CONIC_CURVE_TO_NV"/>
+ <unused start="0x1C" end="0xE7" comment="Unused for PathRenderingTokenNV"/>
+ <enum value="0xE8" name="GL_ROUNDED_RECT_NV"/>
+ <enum value="0xE9" name="GL_RELATIVE_ROUNDED_RECT_NV"/>
+ <enum value="0xEA" name="GL_ROUNDED_RECT2_NV"/>
+ <enum value="0xEB" name="GL_RELATIVE_ROUNDED_RECT2_NV"/>
+ <enum value="0xEC" name="GL_ROUNDED_RECT4_NV"/>
+ <enum value="0xED" name="GL_RELATIVE_ROUNDED_RECT4_NV"/>
+ <enum value="0xEE" name="GL_ROUNDED_RECT8_NV"/>
+ <enum value="0xEF" name="GL_RELATIVE_ROUNDED_RECT8_NV"/>
+ <enum value="0xF0" name="GL_RESTART_PATH_NV"/>
+ <enum value="0xF2" name="GL_DUP_FIRST_CUBIC_CURVE_TO_NV"/>
+ <enum value="0xF4" name="GL_DUP_LAST_CUBIC_CURVE_TO_NV"/>
+ <enum value="0xF6" name="GL_RECT_NV"/>
+ <enum value="0xF7" name="GL_RELATIVE_RECT_NV"/>
+ <enum value="0xF8" name="GL_CIRCULAR_CCW_ARC_TO_NV"/>
+ <enum value="0xFA" name="GL_CIRCULAR_CW_ARC_TO_NV"/>
+ <enum value="0xFC" name="GL_CIRCULAR_TANGENT_ARC_TO_NV"/>
+ <enum value="0xFE" name="GL_ARC_TO_NV"/>
+ <enum value="0xFF" name="GL_RELATIVE_ARC_TO_NV"/>
+ </enums>
+
+ <!-- The default ("API") enum namespace starts here. While some
+ assigned values may overlap, and different parts of the
+ namespace are reserved for different purposes, it is a single
+ namespace. The "class" attribute indicates some of the reserved
+ purposes but is by no means complete (and cannot be, since many
+ tokens are reused for different purposes in different
+ extensions and API versions). -->
+
+ <enums namespace="GL" group="SpecialNumbers" vendor="ARB" comment="Tokens whose numeric value is intrinsically meaningful">
+ <enum value="0" name="GL_FALSE"/>
+ <enum value="0" name="GL_NO_ERROR"/>
+ <enum value="0" name="GL_ZERO"/>
+ <enum value="0" name="GL_NONE"/>
+ <enum value="0" name="GL_NONE_OES"/>
+ <enum value="1" name="GL_TRUE"/>
+ <enum value="1" name="GL_ONE"/>
+ <enum value="0xFFFFFFFF" name="GL_INVALID_INDEX" type="u" comment="Tagged as uint"/>
+ <enum value="0xFFFFFFFFFFFFFFFF" name="GL_TIMEOUT_IGNORED" type="ull" comment="Tagged as uint64"/>
+ <enum value="0xFFFFFFFFFFFFFFFF" name="GL_TIMEOUT_IGNORED_APPLE" type="ull" comment="Tagged as uint64"/>
+ <enum value="1" name="GL_VERSION_ES_CL_1_0" comment="Not an API enum. API definition macro for ES 1.0/1.1 headers"/>
+ <enum value="1" name="GL_VERSION_ES_CM_1_1" comment="Not an API enum. API definition macro for ES 1.0/1.1 headers"/>
+ <enum value="1" name="GL_VERSION_ES_CL_1_1" comment="Not an API enum. API definition macro for ES 1.0/1.1 headers"/>
+ </enums>
+
+ <enums namespace="GL" start="0x0000" end="0x7FFF" vendor="ARB" comment="Mostly OpenGL 1.0/1.1 enum assignments. Unused ranges should generally remain unused.">
+ <enum value="0x0000" name="GL_POINTS"/>
+ <enum value="0x0001" name="GL_LINES"/>
+ <enum value="0x0002" name="GL_LINE_LOOP"/>
+ <enum value="0x0003" name="GL_LINE_STRIP"/>
+ <enum value="0x0004" name="GL_TRIANGLES"/>
+ <enum value="0x0005" name="GL_TRIANGLE_STRIP"/>
+ <enum value="0x0006" name="GL_TRIANGLE_FAN"/>
+ <enum value="0x0007" name="GL_QUADS"/>
+ <enum value="0x0007" name="GL_QUADS_EXT"/>
+ <enum value="0x0008" name="GL_QUAD_STRIP"/>
+ <enum value="0x0009" name="GL_POLYGON"/>
+ <enum value="0x000A" name="GL_LINES_ADJACENCY"/>
+ <enum value="0x000A" name="GL_LINES_ADJACENCY_ARB"/>
+ <enum value="0x000A" name="GL_LINES_ADJACENCY_EXT"/>
+ <enum value="0x000B" name="GL_LINE_STRIP_ADJACENCY"/>
+ <enum value="0x000B" name="GL_LINE_STRIP_ADJACENCY_ARB"/>
+ <enum value="0x000B" name="GL_LINE_STRIP_ADJACENCY_EXT"/>
+ <enum value="0x000C" name="GL_TRIANGLES_ADJACENCY"/>
+ <enum value="0x000C" name="GL_TRIANGLES_ADJACENCY_ARB"/>
+ <enum value="0x000C" name="GL_TRIANGLES_ADJACENCY_EXT"/>
+ <enum value="0x000D" name="GL_TRIANGLE_STRIP_ADJACENCY"/>
+ <enum value="0x000D" name="GL_TRIANGLE_STRIP_ADJACENCY_ARB"/>
+ <enum value="0x000D" name="GL_TRIANGLE_STRIP_ADJACENCY_EXT"/>
+ <enum value="0x000E" name="GL_PATCHES"/>
+ <enum value="0x000E" name="GL_PATCHES_EXT"/>
+ <unused start="0x000F" end="0x00FF" comment="Unused for PrimitiveType"/>
+ <enum value="0x0100" name="GL_ACCUM"/>
+ <enum value="0x0101" name="GL_LOAD"/>
+ <enum value="0x0102" name="GL_RETURN"/>
+ <enum value="0x0103" name="GL_MULT"/>
+ <enum value="0x0104" name="GL_ADD"/>
+ <unused start="0x0105" end="0x01FF" comment="Unused for AccumOp"/>
+ <enum value="0x0200" name="GL_NEVER"/>
+ <enum value="0x0201" name="GL_LESS"/>
+ <enum value="0x0202" name="GL_EQUAL"/>
+ <enum value="0x0203" name="GL_LEQUAL"/>
+ <enum value="0x0204" name="GL_GREATER"/>
+ <enum value="0x0205" name="GL_NOTEQUAL"/>
+ <enum value="0x0206" name="GL_GEQUAL"/>
+ <enum value="0x0207" name="GL_ALWAYS"/>
+ <unused start="0x0208" end="0x02FF" comment="Unused for AlphaFunction"/>
+ <enum value="0x0300" name="GL_SRC_COLOR"/>
+ <enum value="0x0301" name="GL_ONE_MINUS_SRC_COLOR"/>
+ <enum value="0x0302" name="GL_SRC_ALPHA"/>
+ <enum value="0x0303" name="GL_ONE_MINUS_SRC_ALPHA"/>
+ <enum value="0x0304" name="GL_DST_ALPHA"/>
+ <enum value="0x0305" name="GL_ONE_MINUS_DST_ALPHA"/>
+ <enum value="0x0306" name="GL_DST_COLOR"/>
+ <enum value="0x0307" name="GL_ONE_MINUS_DST_COLOR"/>
+ <enum value="0x0308" name="GL_SRC_ALPHA_SATURATE"/>
+ <unused start="0x0309" end="0x03FF" comment="Unused for BlendingFactor"/>
+ <enum value="0x0400" name="GL_FRONT_LEFT"/>
+ <enum value="0x0401" name="GL_FRONT_RIGHT"/>
+ <enum value="0x0402" name="GL_BACK_LEFT"/>
+ <enum value="0x0403" name="GL_BACK_RIGHT"/>
+ <enum value="0x0404" name="GL_FRONT"/>
+ <enum value="0x0405" name="GL_BACK"/>
+ <enum value="0x0406" name="GL_LEFT"/>
+ <enum value="0x0407" name="GL_RIGHT"/>
+ <enum value="0x0408" name="GL_FRONT_AND_BACK"/>
+ <enum value="0x0409" name="GL_AUX0"/>
+ <enum value="0x040A" name="GL_AUX1"/>
+ <enum value="0x040B" name="GL_AUX2"/>
+ <enum value="0x040C" name="GL_AUX3"/>
+ <unused start="0x040D" end="0x04FF" comment="Unused for DrawBufferMode"/>
+ <enum value="0x0500" name="GL_INVALID_ENUM"/>
+ <enum value="0x0501" name="GL_INVALID_VALUE"/>
+ <enum value="0x0502" name="GL_INVALID_OPERATION"/>
+ <enum value="0x0503" name="GL_STACK_OVERFLOW"/>
+ <enum value="0x0503" name="GL_STACK_OVERFLOW_KHR"/>
+ <enum value="0x0504" name="GL_STACK_UNDERFLOW"/>
+ <enum value="0x0504" name="GL_STACK_UNDERFLOW_KHR"/>
+ <enum value="0x0505" name="GL_OUT_OF_MEMORY"/>
+ <enum value="0x0506" name="GL_INVALID_FRAMEBUFFER_OPERATION"/>
+ <enum value="0x0506" name="GL_INVALID_FRAMEBUFFER_OPERATION_EXT"/>
+ <enum value="0x0506" name="GL_INVALID_FRAMEBUFFER_OPERATION_OES"/>
+ <enum value="0x0507" name="GL_CONTEXT_LOST"/>
+ <enum value="0x0507" name="GL_CONTEXT_LOST_KHR"/>
+ <unused start="0x0508" end="0x05FF" comment="Unused for ErrorCode"/>
+ <enum value="0x0600" name="GL_2D"/>
+ <enum value="0x0601" name="GL_3D"/>
+ <enum value="0x0602" name="GL_3D_COLOR"/>
+ <enum value="0x0603" name="GL_3D_COLOR_TEXTURE"/>
+ <enum value="0x0604" name="GL_4D_COLOR_TEXTURE"/>
+ <unused start="0x0605" end="0x06FF" comment="Unused for FeedbackType"/>
+ <enum value="0x0700" name="GL_PASS_THROUGH_TOKEN"/>
+ <enum value="0x0701" name="GL_POINT_TOKEN"/>
+ <enum value="0x0702" name="GL_LINE_TOKEN"/>
+ <enum value="0x0703" name="GL_POLYGON_TOKEN"/>
+ <enum value="0x0704" name="GL_BITMAP_TOKEN"/>
+ <enum value="0x0705" name="GL_DRAW_PIXEL_TOKEN"/>
+ <enum value="0x0706" name="GL_COPY_PIXEL_TOKEN"/>
+ <enum value="0x0707" name="GL_LINE_RESET_TOKEN"/>
+ <unused start="0x0708" end="0x07FF" comment="Unused for FeedbackToken"/>
+ <enum value="0x0800" name="GL_EXP"/>
+ <enum value="0x0801" name="GL_EXP2"/>
+ <unused start="0x0802" end="0x08FF" comment="Unused for FogMode"/>
+ <enum value="0x0900" name="GL_CW"/>
+ <enum value="0x0901" name="GL_CCW"/>
+ <unused start="0x0902" end="0x09FF" comment="Unused for FrontFaceDirection"/>
+ <enum value="0x0A00" name="GL_COEFF"/>
+ <enum value="0x0A01" name="GL_ORDER"/>
+ <enum value="0x0A02" name="GL_DOMAIN"/>
+ <unused start="0x0A03" end="0x0AFF" comment="Unused for GetMapQuery"/>
+ <enum value="0x0B00" name="GL_CURRENT_COLOR"/>
+ <enum value="0x0B01" name="GL_CURRENT_INDEX"/>
+ <enum value="0x0B02" name="GL_CURRENT_NORMAL"/>
+ <enum value="0x0B03" name="GL_CURRENT_TEXTURE_COORDS"/>
+ <enum value="0x0B04" name="GL_CURRENT_RASTER_COLOR"/>
+ <enum value="0x0B05" name="GL_CURRENT_RASTER_INDEX"/>
+ <enum value="0x0B06" name="GL_CURRENT_RASTER_TEXTURE_COORDS"/>
+ <enum value="0x0B07" name="GL_CURRENT_RASTER_POSITION"/>
+ <enum value="0x0B08" name="GL_CURRENT_RASTER_POSITION_VALID"/>
+ <enum value="0x0B09" name="GL_CURRENT_RASTER_DISTANCE"/>
+
+ <enum value="0x0B10" name="GL_POINT_SMOOTH"/>
+ <enum value="0x0B11" name="GL_POINT_SIZE"/>
+ <enum value="0x0B12" name="GL_POINT_SIZE_RANGE"/>
+ <enum value="0x0B12" name="GL_SMOOTH_POINT_SIZE_RANGE" alias="GL_POINT_SIZE_RANGE"/>
+ <enum value="0x0B13" name="GL_POINT_SIZE_GRANULARITY"/>
+ <enum value="0x0B13" name="GL_SMOOTH_POINT_SIZE_GRANULARITY" alias="GL_POINT_SIZE_GRANULARITY"/>
+
+ <enum value="0x0B20" name="GL_LINE_SMOOTH"/>
+ <enum value="0x0B21" name="GL_LINE_WIDTH"/>
+ <enum value="0x0B22" name="GL_LINE_WIDTH_RANGE"/>
+ <enum value="0x0B22" name="GL_SMOOTH_LINE_WIDTH_RANGE" alias="GL_LINE_WIDTH_RANGE"/>
+ <enum value="0x0B23" name="GL_LINE_WIDTH_GRANULARITY"/>
+ <enum value="0x0B23" name="GL_SMOOTH_LINE_WIDTH_GRANULARITY" alias="GL_LINE_WIDTH_GRANULARITY"/>
+ <enum value="0x0B24" name="GL_LINE_STIPPLE"/>
+ <enum value="0x0B25" name="GL_LINE_STIPPLE_PATTERN"/>
+ <enum value="0x0B26" name="GL_LINE_STIPPLE_REPEAT"/>
+
+ <enum value="0x0B30" name="GL_LIST_MODE"/>
+ <enum value="0x0B31" name="GL_MAX_LIST_NESTING"/>
+ <enum value="0x0B32" name="GL_LIST_BASE"/>
+ <enum value="0x0B33" name="GL_LIST_INDEX"/>
+
+ <enum value="0x0B40" name="GL_POLYGON_MODE"/>
+ <enum value="0x0B41" name="GL_POLYGON_SMOOTH"/>
+ <enum value="0x0B42" name="GL_POLYGON_STIPPLE"/>
+ <enum value="0x0B43" name="GL_EDGE_FLAG"/>
+ <enum value="0x0B44" name="GL_CULL_FACE"/>
+ <enum value="0x0B45" name="GL_CULL_FACE_MODE"/>
+ <enum value="0x0B46" name="GL_FRONT_FACE"/>
+
+ <enum value="0x0B50" name="GL_LIGHTING"/>
+ <enum value="0x0B51" name="GL_LIGHT_MODEL_LOCAL_VIEWER"/>
+ <enum value="0x0B52" name="GL_LIGHT_MODEL_TWO_SIDE"/>
+ <enum value="0x0B53" name="GL_LIGHT_MODEL_AMBIENT"/>
+ <enum value="0x0B54" name="GL_SHADE_MODEL"/>
+ <enum value="0x0B55" name="GL_COLOR_MATERIAL_FACE"/>
+ <enum value="0x0B56" name="GL_COLOR_MATERIAL_PARAMETER"/>
+ <enum value="0x0B57" name="GL_COLOR_MATERIAL"/>
+
+ <enum value="0x0B60" name="GL_FOG"/>
+ <enum value="0x0B61" name="GL_FOG_INDEX"/>
+ <enum value="0x0B62" name="GL_FOG_DENSITY"/>
+ <enum value="0x0B63" name="GL_FOG_START"/>
+ <enum value="0x0B64" name="GL_FOG_END"/>
+ <enum value="0x0B65" name="GL_FOG_MODE"/>
+ <enum value="0x0B66" name="GL_FOG_COLOR"/>
+
+ <enum value="0x0B70" name="GL_DEPTH_RANGE"/>
+ <enum value="0x0B71" name="GL_DEPTH_TEST"/>
+ <enum value="0x0B72" name="GL_DEPTH_WRITEMASK"/>
+ <enum value="0x0B73" name="GL_DEPTH_CLEAR_VALUE"/>
+ <enum value="0x0B74" name="GL_DEPTH_FUNC"/>
+
+ <enum value="0x0B80" name="GL_ACCUM_CLEAR_VALUE"/>
+
+ <enum value="0x0B90" name="GL_STENCIL_TEST"/>
+ <enum value="0x0B91" name="GL_STENCIL_CLEAR_VALUE"/>
+ <enum value="0x0B92" name="GL_STENCIL_FUNC"/>
+ <enum value="0x0B93" name="GL_STENCIL_VALUE_MASK"/>
+ <enum value="0x0B94" name="GL_STENCIL_FAIL"/>
+ <enum value="0x0B95" name="GL_STENCIL_PASS_DEPTH_FAIL"/>
+ <enum value="0x0B96" name="GL_STENCIL_PASS_DEPTH_PASS"/>
+ <enum value="0x0B97" name="GL_STENCIL_REF"/>
+ <enum value="0x0B98" name="GL_STENCIL_WRITEMASK"/>
+
+ <enum value="0x0BA0" name="GL_MATRIX_MODE"/>
+ <enum value="0x0BA1" name="GL_NORMALIZE"/>
+ <enum value="0x0BA2" name="GL_VIEWPORT"/>
+ <enum value="0x0BA3" name="GL_MODELVIEW_STACK_DEPTH"/>
+ <enum value="0x0BA3" name="GL_MODELVIEW0_STACK_DEPTH_EXT"/>
+ <enum value="0x0BA3" name="GL_PATH_MODELVIEW_STACK_DEPTH_NV"/>
+ <enum value="0x0BA4" name="GL_PROJECTION_STACK_DEPTH"/>
+ <enum value="0x0BA4" name="GL_PATH_PROJECTION_STACK_DEPTH_NV"/>
+ <enum value="0x0BA5" name="GL_TEXTURE_STACK_DEPTH"/>
+ <enum value="0x0BA6" name="GL_MODELVIEW_MATRIX"/>
+ <enum value="0x0BA6" name="GL_MODELVIEW0_MATRIX_EXT"/>
+ <enum value="0x0BA6" name="GL_PATH_MODELVIEW_MATRIX_NV"/>
+ <enum value="0x0BA7" name="GL_PROJECTION_MATRIX"/>
+ <enum value="0x0BA7" name="GL_PATH_PROJECTION_MATRIX_NV"/>
+ <enum value="0x0BA8" name="GL_TEXTURE_MATRIX"/>
+
+ <enum value="0x0BB0" name="GL_ATTRIB_STACK_DEPTH"/>
+ <enum value="0x0BB1" name="GL_CLIENT_ATTRIB_STACK_DEPTH"/>
+
+ <enum value="0x0BC0" name="GL_ALPHA_TEST"/>
+ <enum value="0x0BC0" name="GL_ALPHA_TEST_QCOM"/>
+ <enum value="0x0BC1" name="GL_ALPHA_TEST_FUNC"/>
+ <enum value="0x0BC1" name="GL_ALPHA_TEST_FUNC_QCOM"/>
+ <enum value="0x0BC2" name="GL_ALPHA_TEST_REF"/>
+ <enum value="0x0BC2" name="GL_ALPHA_TEST_REF_QCOM"/>
+
+ <enum value="0x0BD0" name="GL_DITHER"/>
+
+ <enum value="0x0BE0" name="GL_BLEND_DST"/>
+ <enum value="0x0BE1" name="GL_BLEND_SRC"/>
+ <enum value="0x0BE2" name="GL_BLEND"/>
+
+ <enum value="0x0BF0" name="GL_LOGIC_OP_MODE"/>
+ <enum value="0x0BF1" name="GL_INDEX_LOGIC_OP"/>
+ <enum value="0x0BF1" name="GL_LOGIC_OP"/>
+ <enum value="0x0BF2" name="GL_COLOR_LOGIC_OP"/>
+
+ <enum value="0x0C00" name="GL_AUX_BUFFERS"/>
+ <enum value="0x0C01" name="GL_DRAW_BUFFER"/>
+ <enum value="0x0C01" name="GL_DRAW_BUFFER_EXT"/>
+ <enum value="0x0C02" name="GL_READ_BUFFER"/>
+ <enum value="0x0C02" name="GL_READ_BUFFER_EXT"/>
+ <enum value="0x0C02" name="GL_READ_BUFFER_NV"/>
+
+ <enum value="0x0C10" name="GL_SCISSOR_BOX"/>
+ <enum value="0x0C11" name="GL_SCISSOR_TEST"/>
+
+ <enum value="0x0C20" name="GL_INDEX_CLEAR_VALUE"/>
+ <enum value="0x0C21" name="GL_INDEX_WRITEMASK"/>
+ <enum value="0x0C22" name="GL_COLOR_CLEAR_VALUE"/>
+ <enum value="0x0C23" name="GL_COLOR_WRITEMASK"/>
+
+ <enum value="0x0C30" name="GL_INDEX_MODE"/>
+ <enum value="0x0C31" name="GL_RGBA_MODE"/>
+ <enum value="0x0C32" name="GL_DOUBLEBUFFER"/>
+ <enum value="0x0C33" name="GL_STEREO"/>
+
+ <enum value="0x0C40" name="GL_RENDER_MODE"/>
+
+ <enum value="0x0C50" name="GL_PERSPECTIVE_CORRECTION_HINT"/>
+ <enum value="0x0C51" name="GL_POINT_SMOOTH_HINT"/>
+ <enum value="0x0C52" name="GL_LINE_SMOOTH_HINT"/>
+ <enum value="0x0C53" name="GL_POLYGON_SMOOTH_HINT"/>
+ <enum value="0x0C54" name="GL_FOG_HINT"/>
+
+ <enum value="0x0C60" name="GL_TEXTURE_GEN_S"/>
+ <enum value="0x0C61" name="GL_TEXTURE_GEN_T"/>
+ <enum value="0x0C62" name="GL_TEXTURE_GEN_R"/>
+ <enum value="0x0C63" name="GL_TEXTURE_GEN_Q"/>
+
+ <enum value="0x0C70" name="GL_PIXEL_MAP_I_TO_I"/>
+ <enum value="0x0C71" name="GL_PIXEL_MAP_S_TO_S"/>
+ <enum value="0x0C72" name="GL_PIXEL_MAP_I_TO_R"/>
+ <enum value="0x0C73" name="GL_PIXEL_MAP_I_TO_G"/>
+ <enum value="0x0C74" name="GL_PIXEL_MAP_I_TO_B"/>
+ <enum value="0x0C75" name="GL_PIXEL_MAP_I_TO_A"/>
+ <enum value="0x0C76" name="GL_PIXEL_MAP_R_TO_R"/>
+ <enum value="0x0C77" name="GL_PIXEL_MAP_G_TO_G"/>
+ <enum value="0x0C78" name="GL_PIXEL_MAP_B_TO_B"/>
+ <enum value="0x0C79" name="GL_PIXEL_MAP_A_TO_A"/>
+
+ <enum value="0x0CB0" name="GL_PIXEL_MAP_I_TO_I_SIZE"/>
+ <enum value="0x0CB1" name="GL_PIXEL_MAP_S_TO_S_SIZE"/>
+ <enum value="0x0CB2" name="GL_PIXEL_MAP_I_TO_R_SIZE"/>
+ <enum value="0x0CB3" name="GL_PIXEL_MAP_I_TO_G_SIZE"/>
+ <enum value="0x0CB4" name="GL_PIXEL_MAP_I_TO_B_SIZE"/>
+ <enum value="0x0CB5" name="GL_PIXEL_MAP_I_TO_A_SIZE"/>
+ <enum value="0x0CB6" name="GL_PIXEL_MAP_R_TO_R_SIZE"/>
+ <enum value="0x0CB7" name="GL_PIXEL_MAP_G_TO_G_SIZE"/>
+ <enum value="0x0CB8" name="GL_PIXEL_MAP_B_TO_B_SIZE"/>
+ <enum value="0x0CB9" name="GL_PIXEL_MAP_A_TO_A_SIZE"/>
+
+ <enum value="0x0CF0" name="GL_UNPACK_SWAP_BYTES"/>
+ <enum value="0x0CF1" name="GL_UNPACK_LSB_FIRST"/>
+ <enum value="0x0CF2" name="GL_UNPACK_ROW_LENGTH"/>
+ <enum value="0x0CF2" name="GL_UNPACK_ROW_LENGTH_EXT"/>
+ <enum value="0x0CF3" name="GL_UNPACK_SKIP_ROWS"/>
+ <enum value="0x0CF3" name="GL_UNPACK_SKIP_ROWS_EXT"/>
+ <enum value="0x0CF4" name="GL_UNPACK_SKIP_PIXELS"/>
+ <enum value="0x0CF4" name="GL_UNPACK_SKIP_PIXELS_EXT"/>
+ <enum value="0x0CF5" name="GL_UNPACK_ALIGNMENT"/>
+
+ <enum value="0x0D00" name="GL_PACK_SWAP_BYTES"/>
+ <enum value="0x0D01" name="GL_PACK_LSB_FIRST"/>
+ <enum value="0x0D02" name="GL_PACK_ROW_LENGTH"/>
+ <enum value="0x0D03" name="GL_PACK_SKIP_ROWS"/>
+ <enum value="0x0D04" name="GL_PACK_SKIP_PIXELS"/>
+ <enum value="0x0D05" name="GL_PACK_ALIGNMENT"/>
+
+ <enum value="0x0D10" name="GL_MAP_COLOR"/>
+ <enum value="0x0D11" name="GL_MAP_STENCIL"/>
+ <enum value="0x0D12" name="GL_INDEX_SHIFT"/>
+ <enum value="0x0D13" name="GL_INDEX_OFFSET"/>
+ <enum value="0x0D14" name="GL_RED_SCALE"/>
+ <enum value="0x0D15" name="GL_RED_BIAS"/>
+ <enum value="0x0D16" name="GL_ZOOM_X"/>
+ <enum value="0x0D17" name="GL_ZOOM_Y"/>
+ <enum value="0x0D18" name="GL_GREEN_SCALE"/>
+ <enum value="0x0D19" name="GL_GREEN_BIAS"/>
+ <enum value="0x0D1A" name="GL_BLUE_SCALE"/>
+ <enum value="0x0D1B" name="GL_BLUE_BIAS"/>
+ <enum value="0x0D1C" name="GL_ALPHA_SCALE"/>
+ <enum value="0x0D1D" name="GL_ALPHA_BIAS"/>
+ <enum value="0x0D1E" name="GL_DEPTH_SCALE"/>
+ <enum value="0x0D1F" name="GL_DEPTH_BIAS"/>
+
+ <enum value="0x0D30" name="GL_MAX_EVAL_ORDER"/>
+ <enum value="0x0D31" name="GL_MAX_LIGHTS"/>
+ <enum value="0x0D32" name="GL_MAX_CLIP_PLANES"/>
+ <enum value="0x0D32" name="GL_MAX_CLIP_PLANES_IMG"/>
+ <enum value="0x0D32" name="GL_MAX_CLIP_DISTANCES" alias="GL_MAX_CLIP_PLANES"/>
+ <enum value="0x0D33" name="GL_MAX_TEXTURE_SIZE"/>
+ <enum value="0x0D34" name="GL_MAX_PIXEL_MAP_TABLE"/>
+ <enum value="0x0D35" name="GL_MAX_ATTRIB_STACK_DEPTH"/>
+ <enum value="0x0D36" name="GL_MAX_MODELVIEW_STACK_DEPTH"/>
+ <enum value="0x0D36" name="GL_PATH_MAX_MODELVIEW_STACK_DEPTH_NV"/>
+ <enum value="0x0D37" name="GL_MAX_NAME_STACK_DEPTH"/>
+ <enum value="0x0D38" name="GL_MAX_PROJECTION_STACK_DEPTH"/>
+ <enum value="0x0D38" name="GL_PATH_MAX_PROJECTION_STACK_DEPTH_NV"/>
+ <enum value="0x0D39" name="GL_MAX_TEXTURE_STACK_DEPTH"/>
+ <enum value="0x0D3A" name="GL_MAX_VIEWPORT_DIMS"/>
+ <enum value="0x0D3B" name="GL_MAX_CLIENT_ATTRIB_STACK_DEPTH"/>
+
+ <enum value="0x0D50" name="GL_SUBPIXEL_BITS"/>
+ <enum value="0x0D51" name="GL_INDEX_BITS"/>
+ <enum value="0x0D52" name="GL_RED_BITS"/>
+ <enum value="0x0D53" name="GL_GREEN_BITS"/>
+ <enum value="0x0D54" name="GL_BLUE_BITS"/>
+ <enum value="0x0D55" name="GL_ALPHA_BITS"/>
+ <enum value="0x0D56" name="GL_DEPTH_BITS"/>
+ <enum value="0x0D57" name="GL_STENCIL_BITS"/>
+ <enum value="0x0D58" name="GL_ACCUM_RED_BITS"/>
+ <enum value="0x0D59" name="GL_ACCUM_GREEN_BITS"/>
+ <enum value="0x0D5A" name="GL_ACCUM_BLUE_BITS"/>
+ <enum value="0x0D5B" name="GL_ACCUM_ALPHA_BITS"/>
+
+ <enum value="0x0D70" name="GL_NAME_STACK_DEPTH"/>
+
+ <enum value="0x0D80" name="GL_AUTO_NORMAL"/>
+
+ <enum value="0x0D90" name="GL_MAP1_COLOR_4"/>
+ <enum value="0x0D91" name="GL_MAP1_INDEX"/>
+ <enum value="0x0D92" name="GL_MAP1_NORMAL"/>
+ <enum value="0x0D93" name="GL_MAP1_TEXTURE_COORD_1"/>
+ <enum value="0x0D94" name="GL_MAP1_TEXTURE_COORD_2"/>
+ <enum value="0x0D95" name="GL_MAP1_TEXTURE_COORD_3"/>
+ <enum value="0x0D96" name="GL_MAP1_TEXTURE_COORD_4"/>
+ <enum value="0x0D97" name="GL_MAP1_VERTEX_3"/>
+ <enum value="0x0D98" name="GL_MAP1_VERTEX_4"/>
+
+ <enum value="0x0DB0" name="GL_MAP2_COLOR_4"/>
+ <enum value="0x0DB1" name="GL_MAP2_INDEX"/>
+ <enum value="0x0DB2" name="GL_MAP2_NORMAL"/>
+ <enum value="0x0DB3" name="GL_MAP2_TEXTURE_COORD_1"/>
+ <enum value="0x0DB4" name="GL_MAP2_TEXTURE_COORD_2"/>
+ <enum value="0x0DB5" name="GL_MAP2_TEXTURE_COORD_3"/>
+ <enum value="0x0DB6" name="GL_MAP2_TEXTURE_COORD_4"/>
+ <enum value="0x0DB7" name="GL_MAP2_VERTEX_3"/>
+ <enum value="0x0DB8" name="GL_MAP2_VERTEX_4"/>
+
+ <enum value="0x0DD0" name="GL_MAP1_GRID_DOMAIN"/>
+ <enum value="0x0DD1" name="GL_MAP1_GRID_SEGMENTS"/>
+ <enum value="0x0DD2" name="GL_MAP2_GRID_DOMAIN"/>
+ <enum value="0x0DD3" name="GL_MAP2_GRID_SEGMENTS"/>
+
+ <enum value="0x0DE0" name="GL_TEXTURE_1D"/>
+ <enum value="0x0DE1" name="GL_TEXTURE_2D"/>
+
+ <enum value="0x0DF0" name="GL_FEEDBACK_BUFFER_POINTER"/>
+ <enum value="0x0DF1" name="GL_FEEDBACK_BUFFER_SIZE"/>
+ <enum value="0x0DF2" name="GL_FEEDBACK_BUFFER_TYPE"/>
+ <enum value="0x0DF3" name="GL_SELECTION_BUFFER_POINTER"/>
+ <enum value="0x0DF4" name="GL_SELECTION_BUFFER_SIZE"/>
+ <unused start="0x0DF5" end="0xFFFF" comment="Unused for GetPName"/>
+ <enum value="0x1000" name="GL_TEXTURE_WIDTH"/>
+ <enum value="0x1001" name="GL_TEXTURE_HEIGHT"/>
+ <enum value="0x1003" name="GL_TEXTURE_INTERNAL_FORMAT"/>
+ <enum value="0x1003" name="GL_TEXTURE_COMPONENTS"/>
+ <enum value="0x1004" name="GL_TEXTURE_BORDER_COLOR"/>
+ <enum value="0x1004" name="GL_TEXTURE_BORDER_COLOR_EXT"/>
+ <enum value="0x1004" name="GL_TEXTURE_BORDER_COLOR_NV"/>
+ <enum value="0x1005" name="GL_TEXTURE_BORDER"/>
+ <enum value="0x1006" name="GL_TEXTURE_TARGET"/>
+ <unused start="0x1007" end="0x10FF" comment="Unused for GetTextureParameter"/>
+ <enum value="0x1100" name="GL_DONT_CARE"/>
+ <enum value="0x1101" name="GL_FASTEST"/>
+ <enum value="0x1102" name="GL_NICEST"/>
+ <unused start="0x1103" end="0x11FF" comment="Unused for HintMode"/>
+ <enum value="0x1200" name="GL_AMBIENT"/>
+ <enum value="0x1201" name="GL_DIFFUSE"/>
+ <enum value="0x1202" name="GL_SPECULAR"/>
+ <enum value="0x1203" name="GL_POSITION"/>
+ <enum value="0x1204" name="GL_SPOT_DIRECTION"/>
+ <enum value="0x1205" name="GL_SPOT_EXPONENT"/>
+ <enum value="0x1206" name="GL_SPOT_CUTOFF"/>
+ <enum value="0x1207" name="GL_CONSTANT_ATTENUATION"/>
+ <enum value="0x1208" name="GL_LINEAR_ATTENUATION"/>
+ <enum value="0x1209" name="GL_QUADRATIC_ATTENUATION"/>
+ <unused start="0x1210" end="0x12FF" comment="Unused for LightParameter"/>
+ <enum value="0x1300" name="GL_COMPILE"/>
+ <enum value="0x1301" name="GL_COMPILE_AND_EXECUTE"/>
+ <unused start="0x1302" end="0x13FF" comment="Unused for ListMode"/>
+ <enum value="0x1400" name="GL_BYTE"/>
+ <enum value="0x1401" name="GL_UNSIGNED_BYTE"/>
+ <enum value="0x1402" name="GL_SHORT"/>
+ <enum value="0x1403" name="GL_UNSIGNED_SHORT"/>
+ <enum value="0x1404" name="GL_INT"/>
+ <enum value="0x1405" name="GL_UNSIGNED_INT"/>
+ <enum value="0x1406" name="GL_FLOAT"/>
+ <enum value="0x1407" name="GL_2_BYTES"/>
+ <enum value="0x1407" name="GL_2_BYTES_NV"/>
+ <enum value="0x1408" name="GL_3_BYTES"/>
+ <enum value="0x1408" name="GL_3_BYTES_NV"/>
+ <enum value="0x1409" name="GL_4_BYTES"/>
+ <enum value="0x1409" name="GL_4_BYTES_NV"/>
+ <enum value="0x140A" name="GL_DOUBLE"/>
+ <enum value="0x140A" name="GL_DOUBLE_EXT"/>
+ <enum value="0x140B" name="GL_HALF_FLOAT"/>
+ <enum value="0x140B" name="GL_HALF_FLOAT_ARB"/>
+ <enum value="0x140B" name="GL_HALF_FLOAT_NV"/>
+ <enum value="0x140B" name="GL_HALF_APPLE"/>
+ <enum value="0x140C" name="GL_FIXED"/>
+ <enum value="0x140C" name="GL_FIXED_OES"/>
+ <unused start="0x140D" comment="Leave gap to preserve even/odd int/uint token values"/>
+ <enum value="0x140E" name="GL_INT64_NV"/>
+ <enum value="0x140F" name="GL_UNSIGNED_INT64_ARB"/>
+ <enum value="0x140F" name="GL_UNSIGNED_INT64_NV"/>
+ <unused start="0x1410" end="0x14FF" comment="Unused for DataType"/>
+ <enum value="0x1500" name="GL_CLEAR"/>
+ <enum value="0x1501" name="GL_AND"/>
+ <enum value="0x1502" name="GL_AND_REVERSE"/>
+ <enum value="0x1503" name="GL_COPY"/>
+ <enum value="0x1504" name="GL_AND_INVERTED"/>
+ <enum value="0x1505" name="GL_NOOP"/>
+ <enum value="0x1506" name="GL_XOR"/>
+ <enum value="0x1506" name="GL_XOR_NV"/>
+ <enum value="0x1507" name="GL_OR"/>
+ <enum value="0x1508" name="GL_NOR"/>
+ <enum value="0x1509" name="GL_EQUIV"/>
+ <enum value="0x150A" name="GL_INVERT"/>
+ <enum value="0x150B" name="GL_OR_REVERSE"/>
+ <enum value="0x150C" name="GL_COPY_INVERTED"/>
+ <enum value="0x150D" name="GL_OR_INVERTED"/>
+ <enum value="0x150E" name="GL_NAND"/>
+ <enum value="0x150F" name="GL_SET"/>
+ <unused start="0x1510" end="0x15FF" comment="Unused for LogicOp"/>
+ <enum value="0x1600" name="GL_EMISSION"/>
+ <enum value="0x1601" name="GL_SHININESS"/>
+ <enum value="0x1602" name="GL_AMBIENT_AND_DIFFUSE"/>
+ <enum value="0x1603" name="GL_COLOR_INDEXES"/>
+ <unused start="0x1604" end="0x16FF" comment="Unused for MaterialParameter"/>
+ <enum value="0x1700" name="GL_MODELVIEW"/>
+ <enum value="0x1700" name="GL_MODELVIEW0_ARB"/>
+ <enum value="0x1700" name="GL_MODELVIEW0_EXT"/>
+ <enum value="0x1700" name="GL_PATH_MODELVIEW_NV"/>
+ <enum value="0x1701" name="GL_PROJECTION"/>
+ <enum value="0x1701" name="GL_PATH_PROJECTION_NV"/>
+ <enum value="0x1702" name="GL_TEXTURE"/>
+ <unused start="0x1703" end="0x17FF" comment="Unused for MatrixMode"/>
+ <enum value="0x1800" name="GL_COLOR"/>
+ <enum value="0x1800" name="GL_COLOR_EXT"/>
+ <enum value="0x1801" name="GL_DEPTH"/>
+ <enum value="0x1801" name="GL_DEPTH_EXT"/>
+ <enum value="0x1802" name="GL_STENCIL"/>
+ <enum value="0x1802" name="GL_STENCIL_EXT"/>
+ <unused start="0x1803" end="0x18FF" comment="Unused for PixelCopyType"/>
+ <enum value="0x1900" name="GL_COLOR_INDEX"/>
+ <enum value="0x1901" name="GL_STENCIL_INDEX"/>
+ <enum value="0x1901" name="GL_STENCIL_INDEX_OES"/>
+ <enum value="0x1902" name="GL_DEPTH_COMPONENT"/>
+ <enum value="0x1903" name="GL_RED"/>
+ <enum value="0x1903" name="GL_RED_EXT"/>
+ <enum value="0x1903" name="GL_RED_NV"/>
+ <enum value="0x1904" name="GL_GREEN"/>
+ <enum value="0x1904" name="GL_GREEN_NV"/>
+ <enum value="0x1905" name="GL_BLUE"/>
+ <enum value="0x1905" name="GL_BLUE_NV"/>
+ <enum value="0x1906" name="GL_ALPHA"/>
+ <enum value="0x1907" name="GL_RGB"/>
+ <enum value="0x1908" name="GL_RGBA"/>
+ <enum value="0x1909" name="GL_LUMINANCE"/>
+ <enum value="0x190A" name="GL_LUMINANCE_ALPHA"/>
+ <unused start="0x1910" end="0x19FF" comment="Unused for PixelFormat"/>
+ <enum value="0x1A00" name="GL_BITMAP"/>
+ <unused start="0x1A01" end="0x1AFF" comment="Unused for PixelType"/>
+ <enum value="0x1B00" name="GL_POINT"/>
+ <enum value="0x1B01" name="GL_LINE"/>
+ <enum value="0x1B02" name="GL_FILL"/>
+ <unused start="0x1B03" end="0x1BFF" comment="Unused for PolygonMode"/>
+ <enum value="0x1C00" name="GL_RENDER"/>
+ <enum value="0x1C01" name="GL_FEEDBACK"/>
+ <enum value="0x1C02" name="GL_SELECT"/>
+ <unused start="0x1C03" end="0x1CFF" comment="Unused for RenderingMode"/>
+ <enum value="0x1D00" name="GL_FLAT"/>
+ <enum value="0x1D01" name="GL_SMOOTH"/>
+ <unused start="0x1D02" end="0x1DFF" comment="Unused for ShadingModel"/>
+ <enum value="0x1E00" name="GL_KEEP"/>
+ <enum value="0x1E01" name="GL_REPLACE"/>
+ <enum value="0x1E02" name="GL_INCR"/>
+ <enum value="0x1E03" name="GL_DECR"/>
+ <unused start="0x1E04" end="0x1EFF" comment="Unused for StencilOp"/>
+ <enum value="0x1F00" name="GL_VENDOR"/>
+ <enum value="0x1F01" name="GL_RENDERER"/>
+ <enum value="0x1F02" name="GL_VERSION"/>
+ <enum value="0x1F03" name="GL_EXTENSIONS"/>
+ <unused start="0x1F04" end="0x1FFF" comment="Unused for StringName"/>
+ <enum value="0x2000" name="GL_S"/>
+ <enum value="0x2001" name="GL_T"/>
+ <enum value="0x2002" name="GL_R"/>
+ <enum value="0x2003" name="GL_Q"/>
+ <unused start="0x2004" end="0x20FF" comment="Unused for TextureCoordName"/>
+ <enum value="0x2100" name="GL_MODULATE"/>
+ <enum value="0x2101" name="GL_DECAL"/>
+ <unused start="0x2102" end="0x21FF" comment="Unused for TextureEnvMode"/>
+ <enum value="0x2200" name="GL_TEXTURE_ENV_MODE"/>
+ <enum value="0x2201" name="GL_TEXTURE_ENV_COLOR"/>
+ <unused start="0x2202" end="0x22FF" comment="Unused for TextureEnvParameter"/>
+ <enum value="0x2300" name="GL_TEXTURE_ENV"/>
+ <unused start="0x2301" end="0x23FF" comment="Unused for TextureEnvTarget"/>
+ <enum value="0x2400" name="GL_EYE_LINEAR"/>
+ <enum value="0x2400" name="GL_EYE_LINEAR_NV"/>
+ <enum value="0x2401" name="GL_OBJECT_LINEAR"/>
+ <enum value="0x2401" name="GL_OBJECT_LINEAR_NV"/>
+ <enum value="0x2402" name="GL_SPHERE_MAP"/>
+ <unused start="0x2403" end="0x24FF" comment="Unused for TextureGenMode"/>
+ <enum value="0x2500" name="GL_TEXTURE_GEN_MODE"/>
+ <enum value="0x2500" name="GL_TEXTURE_GEN_MODE_OES"/>
+ <enum value="0x2501" name="GL_OBJECT_PLANE"/>
+ <enum value="0x2502" name="GL_EYE_PLANE"/>
+ <unused start="0x2503" end="0x25FF" comment="Unused for TextureGenParameter"/>
+ <enum value="0x2600" name="GL_NEAREST"/>
+ <enum value="0x2601" name="GL_LINEAR"/>
+ <unused start="0x2602" end="0x26FF" comment="Unused for TextureMagFilter"/>
+ <enum value="0x2700" name="GL_NEAREST_MIPMAP_NEAREST"/>
+ <enum value="0x2701" name="GL_LINEAR_MIPMAP_NEAREST"/>
+ <enum value="0x2702" name="GL_NEAREST_MIPMAP_LINEAR"/>
+ <enum value="0x2703" name="GL_LINEAR_MIPMAP_LINEAR"/>
+ <unused start="0x2704" end="0x27FF" comment="Unused for TextureMinFilter"/>
+ <enum value="0x2800" name="GL_TEXTURE_MAG_FILTER"/>
+ <enum value="0x2801" name="GL_TEXTURE_MIN_FILTER"/>
+ <enum value="0x2802" name="GL_TEXTURE_WRAP_S"/>
+ <enum value="0x2803" name="GL_TEXTURE_WRAP_T"/>
+ <unused start="0x2804" end="0x28FF" comment="Unused for TextureParameterName"/>
+ <enum value="0x2900" name="GL_CLAMP"/>
+ <enum value="0x2901" name="GL_REPEAT"/>
+ <unused start="0x2902" end="0x29FF" comment="Unused for TextureWrapMode"/>
+ <enum value="0x2A00" name="GL_POLYGON_OFFSET_UNITS"/>
+ <enum value="0x2A01" name="GL_POLYGON_OFFSET_POINT"/>
+ <enum value="0x2A02" name="GL_POLYGON_OFFSET_LINE"/>
+ <unused start="0x2A03" end="0x2A09" comment="Unused for PolygonOffset"/>
+ <enum value="0x2A10" name="GL_R3_G3_B2"/>
+ <unused start="0x2A11" end="0x2A1F" comment="Unused for InternalFormat"/>
+ <enum value="0x2A20" name="GL_V2F"/>
+ <enum value="0x2A21" name="GL_V3F"/>
+ <enum value="0x2A22" name="GL_C4UB_V2F"/>
+ <enum value="0x2A23" name="GL_C4UB_V3F"/>
+ <enum value="0x2A24" name="GL_C3F_V3F"/>
+ <enum value="0x2A25" name="GL_N3F_V3F"/>
+ <enum value="0x2A26" name="GL_C4F_N3F_V3F"/>
+ <enum value="0x2A27" name="GL_T2F_V3F"/>
+ <enum value="0x2A28" name="GL_T4F_V4F"/>
+ <enum value="0x2A29" name="GL_T2F_C4UB_V3F"/>
+ <enum value="0x2A2A" name="GL_T2F_C3F_V3F"/>
+ <enum value="0x2A2B" name="GL_T2F_N3F_V3F"/>
+ <enum value="0x2A2C" name="GL_T2F_C4F_N3F_V3F"/>
+ <enum value="0x2A2D" name="GL_T4F_C4F_N3F_V4F"/>
+ <unused start="0x2A2E" end="0x2FFF" comment="Unused for InterleavedArrayFormat"/>
+ <enum value="0x3000" name="GL_CLIP_PLANE0"/>
+ <enum value="0x3000" name="GL_CLIP_PLANE0_IMG"/>
+ <enum value="0x3000" name="GL_CLIP_DISTANCE0" alias="GL_CLIP_PLANE0"/>
+ <enum value="0x3001" name="GL_CLIP_PLANE1"/>
+ <enum value="0x3001" name="GL_CLIP_PLANE1_IMG"/>
+ <enum value="0x3001" name="GL_CLIP_DISTANCE1" alias="GL_CLIP_PLANE1"/>
+ <enum value="0x3002" name="GL_CLIP_PLANE2"/>
+ <enum value="0x3002" name="GL_CLIP_PLANE2_IMG"/>
+ <enum value="0x3002" name="GL_CLIP_DISTANCE2" alias="GL_CLIP_PLANE2"/>
+ <enum value="0x3003" name="GL_CLIP_PLANE3"/>
+ <enum value="0x3003" name="GL_CLIP_PLANE3_IMG"/>
+ <enum value="0x3003" name="GL_CLIP_DISTANCE3" alias="GL_CLIP_PLANE3"/>
+ <enum value="0x3004" name="GL_CLIP_PLANE4"/>
+ <enum value="0x3004" name="GL_CLIP_PLANE4_IMG"/>
+ <enum value="0x3004" name="GL_CLIP_DISTANCE4" alias="GL_CLIP_PLANE4"/>
+ <enum value="0x3005" name="GL_CLIP_PLANE5"/>
+ <enum value="0x3005" name="GL_CLIP_PLANE5_IMG"/>
+ <enum value="0x3005" name="GL_CLIP_DISTANCE5" alias="GL_CLIP_PLANE5"/>
+ <enum value="0x3006" name="GL_CLIP_DISTANCE6"/>
+ <enum value="0x3007" name="GL_CLIP_DISTANCE7"/>
+ <unused start="0x3008" end="0x3FFF" comment="Unused for ClipPlaneName"/>
+ <enum value="0x4000" name="GL_LIGHT0"/>
+ <enum value="0x4001" name="GL_LIGHT1"/>
+ <enum value="0x4002" name="GL_LIGHT2"/>
+ <enum value="0x4003" name="GL_LIGHT3"/>
+ <enum value="0x4004" name="GL_LIGHT4"/>
+ <enum value="0x4005" name="GL_LIGHT5"/>
+ <enum value="0x4006" name="GL_LIGHT6"/>
+ <enum value="0x4007" name="GL_LIGHT7"/>
+ <unused start="0x4008" end="0x4FFF" comment="Unused for LightName"/>
+ <unused start="0x5000" end="0x5FFF" comment="Unused. Do not use."/>
+ <unused start="0x6000" end="0x6FFF" comment="Experimental (internal/test only) range. DO NOT SHIP VALUES IN THIS RANGE."/>
+ <unused start="0x7000" end="0x7FFF" comment="Unused. Do not use."/>
+ </enums>
+
+ <enums namespace="GL" start="0x8000" end="0x80BF" vendor="ARB" comment="The primary GL enumerant space begins here. All modern enum allocations are in this range. These enums are mostly assigned the default class since it's a great deal of not very useful work to be more specific">
+ <enum value="0x8000" name="GL_ABGR_EXT"/>
+ <enum value="0x8001" name="GL_CONSTANT_COLOR"/>
+ <enum value="0x8001" name="GL_CONSTANT_COLOR_EXT"/>
+ <enum value="0x8002" name="GL_ONE_MINUS_CONSTANT_COLOR"/>
+ <enum value="0x8002" name="GL_ONE_MINUS_CONSTANT_COLOR_EXT"/>
+ <enum value="0x8003" name="GL_CONSTANT_ALPHA"/>
+ <enum value="0x8003" name="GL_CONSTANT_ALPHA_EXT"/>
+ <enum value="0x8004" name="GL_ONE_MINUS_CONSTANT_ALPHA"/>
+ <enum value="0x8004" name="GL_ONE_MINUS_CONSTANT_ALPHA_EXT"/>
+ <enum value="0x8005" name="GL_BLEND_COLOR"/>
+ <enum value="0x8005" name="GL_BLEND_COLOR_EXT"/>
+ <enum value="0x8006" name="GL_FUNC_ADD"/>
+ <enum value="0x8006" name="GL_FUNC_ADD_EXT"/>
+ <enum value="0x8006" name="GL_FUNC_ADD_OES"/>
+ <enum value="0x8007" name="GL_MIN"/>
+ <enum value="0x8007" name="GL_MIN_EXT"/>
+ <enum value="0x8008" name="GL_MAX"/>
+ <enum value="0x8008" name="GL_MAX_EXT"/>
+ <enum value="0x8009" name="GL_BLEND_EQUATION"/>
+ <enum value="0x8009" name="GL_BLEND_EQUATION_EXT"/>
+ <enum value="0x8009" name="GL_BLEND_EQUATION_OES"/>
+ <enum value="0x8009" name="GL_BLEND_EQUATION_RGB"/>
+ <enum value="0x8009" name="GL_BLEND_EQUATION_RGB_EXT"/>
+ <enum value="0x8009" name="GL_BLEND_EQUATION_RGB_OES"/>
+ <enum value="0x800A" name="GL_FUNC_SUBTRACT"/>
+ <enum value="0x800A" name="GL_FUNC_SUBTRACT_EXT"/>
+ <enum value="0x800A" name="GL_FUNC_SUBTRACT_OES"/>
+ <enum value="0x800B" name="GL_FUNC_REVERSE_SUBTRACT"/>
+ <enum value="0x800B" name="GL_FUNC_REVERSE_SUBTRACT_EXT"/>
+ <enum value="0x800B" name="GL_FUNC_REVERSE_SUBTRACT_OES"/>
+ <enum value="0x800C" name="GL_CMYK_EXT"/>
+ <enum value="0x800D" name="GL_CMYKA_EXT"/>
+ <enum value="0x800E" name="GL_PACK_CMYK_HINT_EXT"/>
+ <enum value="0x800F" name="GL_UNPACK_CMYK_HINT_EXT"/>
+ <enum value="0x8010" name="GL_CONVOLUTION_1D"/>
+ <enum value="0x8010" name="GL_CONVOLUTION_1D_EXT"/>
+ <enum value="0x8011" name="GL_CONVOLUTION_2D"/>
+ <enum value="0x8011" name="GL_CONVOLUTION_2D_EXT"/>
+ <enum value="0x8012" name="GL_SEPARABLE_2D"/>
+ <enum value="0x8012" name="GL_SEPARABLE_2D_EXT"/>
+ <enum value="0x8013" name="GL_CONVOLUTION_BORDER_MODE"/>
+ <enum value="0x8013" name="GL_CONVOLUTION_BORDER_MODE_EXT"/>
+ <enum value="0x8014" name="GL_CONVOLUTION_FILTER_SCALE"/>
+ <enum value="0x8014" name="GL_CONVOLUTION_FILTER_SCALE_EXT"/>
+ <enum value="0x8015" name="GL_CONVOLUTION_FILTER_BIAS"/>
+ <enum value="0x8015" name="GL_CONVOLUTION_FILTER_BIAS_EXT"/>
+ <enum value="0x8016" name="GL_REDUCE"/>
+ <enum value="0x8016" name="GL_REDUCE_EXT"/>
+ <enum value="0x8017" name="GL_CONVOLUTION_FORMAT"/>
+ <enum value="0x8017" name="GL_CONVOLUTION_FORMAT_EXT"/>
+ <enum value="0x8018" name="GL_CONVOLUTION_WIDTH"/>
+ <enum value="0x8018" name="GL_CONVOLUTION_WIDTH_EXT"/>
+ <enum value="0x8019" name="GL_CONVOLUTION_HEIGHT"/>
+ <enum value="0x8019" name="GL_CONVOLUTION_HEIGHT_EXT"/>
+ <enum value="0x801A" name="GL_MAX_CONVOLUTION_WIDTH"/>
+ <enum value="0x801A" name="GL_MAX_CONVOLUTION_WIDTH_EXT"/>
+ <enum value="0x801B" name="GL_MAX_CONVOLUTION_HEIGHT"/>
+ <enum value="0x801B" name="GL_MAX_CONVOLUTION_HEIGHT_EXT"/>
+ <enum value="0x801C" name="GL_POST_CONVOLUTION_RED_SCALE"/>
+ <enum value="0x801C" name="GL_POST_CONVOLUTION_RED_SCALE_EXT"/>
+ <enum value="0x801D" name="GL_POST_CONVOLUTION_GREEN_SCALE"/>
+ <enum value="0x801D" name="GL_POST_CONVOLUTION_GREEN_SCALE_EXT"/>
+ <enum value="0x801E" name="GL_POST_CONVOLUTION_BLUE_SCALE"/>
+ <enum value="0x801E" name="GL_POST_CONVOLUTION_BLUE_SCALE_EXT"/>
+ <enum value="0x801F" name="GL_POST_CONVOLUTION_ALPHA_SCALE"/>
+ <enum value="0x801F" name="GL_POST_CONVOLUTION_ALPHA_SCALE_EXT"/>
+ <enum value="0x8020" name="GL_POST_CONVOLUTION_RED_BIAS"/>
+ <enum value="0x8020" name="GL_POST_CONVOLUTION_RED_BIAS_EXT"/>
+ <enum value="0x8021" name="GL_POST_CONVOLUTION_GREEN_BIAS"/>
+ <enum value="0x8021" name="GL_POST_CONVOLUTION_GREEN_BIAS_EXT"/>
+ <enum value="0x8022" name="GL_POST_CONVOLUTION_BLUE_BIAS"/>
+ <enum value="0x8022" name="GL_POST_CONVOLUTION_BLUE_BIAS_EXT"/>
+ <enum value="0x8023" name="GL_POST_CONVOLUTION_ALPHA_BIAS"/>
+ <enum value="0x8023" name="GL_POST_CONVOLUTION_ALPHA_BIAS_EXT"/>
+ <enum value="0x8024" name="GL_HISTOGRAM"/>
+ <enum value="0x8024" name="GL_HISTOGRAM_EXT"/>
+ <enum value="0x8025" name="GL_PROXY_HISTOGRAM"/>
+ <enum value="0x8025" name="GL_PROXY_HISTOGRAM_EXT"/>
+ <enum value="0x8026" name="GL_HISTOGRAM_WIDTH"/>
+ <enum value="0x8026" name="GL_HISTOGRAM_WIDTH_EXT"/>
+ <enum value="0x8027" name="GL_HISTOGRAM_FORMAT"/>
+ <enum value="0x8027" name="GL_HISTOGRAM_FORMAT_EXT"/>
+ <enum value="0x8028" name="GL_HISTOGRAM_RED_SIZE"/>
+ <enum value="0x8028" name="GL_HISTOGRAM_RED_SIZE_EXT"/>
+ <enum value="0x8029" name="GL_HISTOGRAM_GREEN_SIZE"/>
+ <enum value="0x8029" name="GL_HISTOGRAM_GREEN_SIZE_EXT"/>
+ <enum value="0x802A" name="GL_HISTOGRAM_BLUE_SIZE"/>
+ <enum value="0x802A" name="GL_HISTOGRAM_BLUE_SIZE_EXT"/>
+ <enum value="0x802B" name="GL_HISTOGRAM_ALPHA_SIZE"/>
+ <enum value="0x802B" name="GL_HISTOGRAM_ALPHA_SIZE_EXT"/>
+ <enum value="0x802C" name="GL_HISTOGRAM_LUMINANCE_SIZE"/>
+ <enum value="0x802C" name="GL_HISTOGRAM_LUMINANCE_SIZE_EXT"/>
+ <enum value="0x802D" name="GL_HISTOGRAM_SINK"/>
+ <enum value="0x802D" name="GL_HISTOGRAM_SINK_EXT"/>
+ <enum value="0x802E" name="GL_MINMAX"/>
+ <enum value="0x802E" name="GL_MINMAX_EXT"/>
+ <enum value="0x802F" name="GL_MINMAX_FORMAT"/>
+ <enum value="0x802F" name="GL_MINMAX_FORMAT_EXT"/>
+ <enum value="0x8030" name="GL_MINMAX_SINK"/>
+ <enum value="0x8030" name="GL_MINMAX_SINK_EXT"/>
+ <enum value="0x8031" name="GL_TABLE_TOO_LARGE_EXT"/>
+ <enum value="0x8031" name="GL_TABLE_TOO_LARGE"/>
+ <enum value="0x8032" name="GL_UNSIGNED_BYTE_3_3_2"/>
+ <enum value="0x8032" name="GL_UNSIGNED_BYTE_3_3_2_EXT"/>
+ <enum value="0x8033" name="GL_UNSIGNED_SHORT_4_4_4_4"/>
+ <enum value="0x8033" name="GL_UNSIGNED_SHORT_4_4_4_4_EXT"/>
+ <enum value="0x8034" name="GL_UNSIGNED_SHORT_5_5_5_1"/>
+ <enum value="0x8034" name="GL_UNSIGNED_SHORT_5_5_5_1_EXT"/>
+ <enum value="0x8035" name="GL_UNSIGNED_INT_8_8_8_8"/>
+ <enum value="0x8035" name="GL_UNSIGNED_INT_8_8_8_8_EXT"/>
+ <enum value="0x8036" name="GL_UNSIGNED_INT_10_10_10_2"/>
+ <enum value="0x8036" name="GL_UNSIGNED_INT_10_10_10_2_EXT"/>
+ <enum value="0x8037" name="GL_POLYGON_OFFSET_EXT"/>
+ <enum value="0x8037" name="GL_POLYGON_OFFSET_FILL"/>
+ <enum value="0x8038" name="GL_POLYGON_OFFSET_FACTOR"/>
+ <enum value="0x8038" name="GL_POLYGON_OFFSET_FACTOR_EXT"/>
+ <enum value="0x8039" name="GL_POLYGON_OFFSET_BIAS_EXT"/>
+ <enum value="0x803A" name="GL_RESCALE_NORMAL"/>
+ <enum value="0x803A" name="GL_RESCALE_NORMAL_EXT"/>
+ <enum value="0x803B" name="GL_ALPHA4"/>
+ <enum value="0x803B" name="GL_ALPHA4_EXT"/>
+ <enum value="0x803C" name="GL_ALPHA8"/>
+ <enum value="0x803C" name="GL_ALPHA8_EXT"/>
+ <enum value="0x803C" name="GL_ALPHA8_OES"/>
+ <enum value="0x803D" name="GL_ALPHA12"/>
+ <enum value="0x803D" name="GL_ALPHA12_EXT"/>
+ <enum value="0x803E" name="GL_ALPHA16"/>
+ <enum value="0x803E" name="GL_ALPHA16_EXT"/>
+ <enum value="0x803F" name="GL_LUMINANCE4"/>
+ <enum value="0x803F" name="GL_LUMINANCE4_EXT"/>
+ <enum value="0x8040" name="GL_LUMINANCE8"/>
+ <enum value="0x8040" name="GL_LUMINANCE8_EXT"/>
+ <enum value="0x8040" name="GL_LUMINANCE8_OES"/>
+ <enum value="0x8041" name="GL_LUMINANCE12"/>
+ <enum value="0x8041" name="GL_LUMINANCE12_EXT"/>
+ <enum value="0x8042" name="GL_LUMINANCE16"/>
+ <enum value="0x8042" name="GL_LUMINANCE16_EXT"/>
+ <enum value="0x8043" name="GL_LUMINANCE4_ALPHA4"/>
+ <enum value="0x8043" name="GL_LUMINANCE4_ALPHA4_EXT"/>
+ <enum value="0x8043" name="GL_LUMINANCE4_ALPHA4_OES"/>
+ <enum value="0x8044" name="GL_LUMINANCE6_ALPHA2"/>
+ <enum value="0x8044" name="GL_LUMINANCE6_ALPHA2_EXT"/>
+ <enum value="0x8045" name="GL_LUMINANCE8_ALPHA8"/>
+ <enum value="0x8045" name="GL_LUMINANCE8_ALPHA8_EXT"/>
+ <enum value="0x8045" name="GL_LUMINANCE8_ALPHA8_OES"/>
+ <enum value="0x8046" name="GL_LUMINANCE12_ALPHA4"/>
+ <enum value="0x8046" name="GL_LUMINANCE12_ALPHA4_EXT"/>
+ <enum value="0x8047" name="GL_LUMINANCE12_ALPHA12"/>
+ <enum value="0x8047" name="GL_LUMINANCE12_ALPHA12_EXT"/>
+ <enum value="0x8048" name="GL_LUMINANCE16_ALPHA16"/>
+ <enum value="0x8048" name="GL_LUMINANCE16_ALPHA16_EXT"/>
+ <enum value="0x8049" name="GL_INTENSITY"/>
+ <enum value="0x8049" name="GL_INTENSITY_EXT"/>
+ <enum value="0x804A" name="GL_INTENSITY4"/>
+ <enum value="0x804A" name="GL_INTENSITY4_EXT"/>
+ <enum value="0x804B" name="GL_INTENSITY8"/>
+ <enum value="0x804B" name="GL_INTENSITY8_EXT"/>
+ <enum value="0x804C" name="GL_INTENSITY12"/>
+ <enum value="0x804C" name="GL_INTENSITY12_EXT"/>
+ <enum value="0x804D" name="GL_INTENSITY16"/>
+ <enum value="0x804D" name="GL_INTENSITY16_EXT"/>
+ <enum value="0x804E" name="GL_RGB2_EXT"/>
+ <enum value="0x804F" name="GL_RGB4"/>
+ <enum value="0x804F" name="GL_RGB4_EXT"/>
+ <enum value="0x8050" name="GL_RGB5"/>
+ <enum value="0x8050" name="GL_RGB5_EXT"/>
+ <enum value="0x8051" name="GL_RGB8"/>
+ <enum value="0x8051" name="GL_RGB8_EXT"/>
+ <enum value="0x8051" name="GL_RGB8_OES"/>
+ <enum value="0x8052" name="GL_RGB10"/>
+ <enum value="0x8052" name="GL_RGB10_EXT"/>
+ <enum value="0x8053" name="GL_RGB12"/>
+ <enum value="0x8053" name="GL_RGB12_EXT"/>
+ <enum value="0x8054" name="GL_RGB16"/>
+ <enum value="0x8054" name="GL_RGB16_EXT"/>
+ <enum value="0x8055" name="GL_RGBA2"/>
+ <enum value="0x8055" name="GL_RGBA2_EXT"/>
+ <enum value="0x8056" name="GL_RGBA4"/>
+ <enum value="0x8056" name="GL_RGBA4_EXT"/>
+ <enum value="0x8056" name="GL_RGBA4_OES"/>
+ <enum value="0x8057" name="GL_RGB5_A1"/>
+ <enum value="0x8057" name="GL_RGB5_A1_EXT"/>
+ <enum value="0x8057" name="GL_RGB5_A1_OES"/>
+ <enum value="0x8058" name="GL_RGBA8"/>
+ <enum value="0x8058" name="GL_RGBA8_EXT"/>
+ <enum value="0x8058" name="GL_RGBA8_OES"/>
+ <enum value="0x8059" name="GL_RGB10_A2"/>
+ <enum value="0x8059" name="GL_RGB10_A2_EXT"/>
+ <enum value="0x805A" name="GL_RGBA12"/>
+ <enum value="0x805A" name="GL_RGBA12_EXT"/>
+ <enum value="0x805B" name="GL_RGBA16"/>
+ <enum value="0x805B" name="GL_RGBA16_EXT"/>
+ <enum value="0x805C" name="GL_TEXTURE_RED_SIZE"/>
+ <enum value="0x805C" name="GL_TEXTURE_RED_SIZE_EXT"/>
+ <enum value="0x805D" name="GL_TEXTURE_GREEN_SIZE"/>
+ <enum value="0x805D" name="GL_TEXTURE_GREEN_SIZE_EXT"/>
+ <enum value="0x805E" name="GL_TEXTURE_BLUE_SIZE"/>
+ <enum value="0x805E" name="GL_TEXTURE_BLUE_SIZE_EXT"/>
+ <enum value="0x805F" name="GL_TEXTURE_ALPHA_SIZE"/>
+ <enum value="0x805F" name="GL_TEXTURE_ALPHA_SIZE_EXT"/>
+ <enum value="0x8060" name="GL_TEXTURE_LUMINANCE_SIZE"/>
+ <enum value="0x8060" name="GL_TEXTURE_LUMINANCE_SIZE_EXT"/>
+ <enum value="0x8061" name="GL_TEXTURE_INTENSITY_SIZE"/>
+ <enum value="0x8061" name="GL_TEXTURE_INTENSITY_SIZE_EXT"/>
+ <enum value="0x8062" name="GL_REPLACE_EXT"/>
+ <enum value="0x8063" name="GL_PROXY_TEXTURE_1D"/>
+ <enum value="0x8063" name="GL_PROXY_TEXTURE_1D_EXT"/>
+ <enum value="0x8064" name="GL_PROXY_TEXTURE_2D"/>
+ <enum value="0x8064" name="GL_PROXY_TEXTURE_2D_EXT"/>
+ <enum value="0x8065" name="GL_TEXTURE_TOO_LARGE_EXT"/>
+ <enum value="0x8066" name="GL_TEXTURE_PRIORITY"/>
+ <enum value="0x8066" name="GL_TEXTURE_PRIORITY_EXT"/>
+ <enum value="0x8067" name="GL_TEXTURE_RESIDENT"/>
+ <enum value="0x8067" name="GL_TEXTURE_RESIDENT_EXT"/>
+ <enum value="0x8068" name="GL_TEXTURE_1D_BINDING_EXT"/>
+ <enum value="0x8068" name="GL_TEXTURE_BINDING_1D"/>
+ <enum value="0x8069" name="GL_TEXTURE_2D_BINDING_EXT"/>
+ <enum value="0x8069" name="GL_TEXTURE_BINDING_2D"/>
+ <enum value="0x806A" name="GL_TEXTURE_3D_BINDING_EXT"/>
+ <enum value="0x806A" name="GL_TEXTURE_3D_BINDING_OES"/>
+ <enum value="0x806A" name="GL_TEXTURE_BINDING_3D"/>
+ <enum value="0x806A" name="GL_TEXTURE_BINDING_3D_OES"/>
+ <enum value="0x806B" name="GL_PACK_SKIP_IMAGES"/>
+ <enum value="0x806B" name="GL_PACK_SKIP_IMAGES_EXT"/>
+ <enum value="0x806C" name="GL_PACK_IMAGE_HEIGHT"/>
+ <enum value="0x806C" name="GL_PACK_IMAGE_HEIGHT_EXT"/>
+ <enum value="0x806D" name="GL_UNPACK_SKIP_IMAGES"/>
+ <enum value="0x806D" name="GL_UNPACK_SKIP_IMAGES_EXT"/>
+ <enum value="0x806E" name="GL_UNPACK_IMAGE_HEIGHT"/>
+ <enum value="0x806E" name="GL_UNPACK_IMAGE_HEIGHT_EXT"/>
+ <enum value="0x806F" name="GL_TEXTURE_3D"/>
+ <enum value="0x806F" name="GL_TEXTURE_3D_EXT"/>
+ <enum value="0x806F" name="GL_TEXTURE_3D_OES"/>
+ <enum value="0x8070" name="GL_PROXY_TEXTURE_3D"/>
+ <enum value="0x8070" name="GL_PROXY_TEXTURE_3D_EXT"/>
+ <enum value="0x8071" name="GL_TEXTURE_DEPTH"/>
+ <enum value="0x8071" name="GL_TEXTURE_DEPTH_EXT"/>
+ <enum value="0x8072" name="GL_TEXTURE_WRAP_R"/>
+ <enum value="0x8072" name="GL_TEXTURE_WRAP_R_EXT"/>
+ <enum value="0x8072" name="GL_TEXTURE_WRAP_R_OES"/>
+ <enum value="0x8073" name="GL_MAX_3D_TEXTURE_SIZE"/>
+ <enum value="0x8073" name="GL_MAX_3D_TEXTURE_SIZE_EXT"/>
+ <enum value="0x8073" name="GL_MAX_3D_TEXTURE_SIZE_OES"/>
+ <enum value="0x8074" name="GL_VERTEX_ARRAY"/>
+ <enum value="0x8074" name="GL_VERTEX_ARRAY_EXT"/>
+ <enum value="0x8074" name="GL_VERTEX_ARRAY_KHR"/>
+ <enum value="0x8075" name="GL_NORMAL_ARRAY"/>
+ <enum value="0x8075" name="GL_NORMAL_ARRAY_EXT"/>
+ <enum value="0x8076" name="GL_COLOR_ARRAY"/>
+ <enum value="0x8076" name="GL_COLOR_ARRAY_EXT"/>
+ <enum value="0x8077" name="GL_INDEX_ARRAY"/>
+ <enum value="0x8077" name="GL_INDEX_ARRAY_EXT"/>
+ <enum value="0x8078" name="GL_TEXTURE_COORD_ARRAY"/>
+ <enum value="0x8078" name="GL_TEXTURE_COORD_ARRAY_EXT"/>
+ <enum value="0x8079" name="GL_EDGE_FLAG_ARRAY"/>
+ <enum value="0x8079" name="GL_EDGE_FLAG_ARRAY_EXT"/>
+ <enum value="0x807A" name="GL_VERTEX_ARRAY_SIZE"/>
+ <enum value="0x807A" name="GL_VERTEX_ARRAY_SIZE_EXT"/>
+ <enum value="0x807B" name="GL_VERTEX_ARRAY_TYPE"/>
+ <enum value="0x807B" name="GL_VERTEX_ARRAY_TYPE_EXT"/>
+ <enum value="0x807C" name="GL_VERTEX_ARRAY_STRIDE"/>
+ <enum value="0x807C" name="GL_VERTEX_ARRAY_STRIDE_EXT"/>
+ <enum value="0x807D" name="GL_VERTEX_ARRAY_COUNT_EXT"/>
+ <enum value="0x807E" name="GL_NORMAL_ARRAY_TYPE"/>
+ <enum value="0x807E" name="GL_NORMAL_ARRAY_TYPE_EXT"/>
+ <enum value="0x807F" name="GL_NORMAL_ARRAY_STRIDE"/>
+ <enum value="0x807F" name="GL_NORMAL_ARRAY_STRIDE_EXT"/>
+ <enum value="0x8080" name="GL_NORMAL_ARRAY_COUNT_EXT"/>
+ <enum value="0x8081" name="GL_COLOR_ARRAY_SIZE"/>
+ <enum value="0x8081" name="GL_COLOR_ARRAY_SIZE_EXT"/>
+ <enum value="0x8082" name="GL_COLOR_ARRAY_TYPE"/>
+ <enum value="0x8082" name="GL_COLOR_ARRAY_TYPE_EXT"/>
+ <enum value="0x8083" name="GL_COLOR_ARRAY_STRIDE"/>
+ <enum value="0x8083" name="GL_COLOR_ARRAY_STRIDE_EXT"/>
+ <enum value="0x8084" name="GL_COLOR_ARRAY_COUNT_EXT"/>
+ <enum value="0x8085" name="GL_INDEX_ARRAY_TYPE"/>
+ <enum value="0x8085" name="GL_INDEX_ARRAY_TYPE_EXT"/>
+ <enum value="0x8086" name="GL_INDEX_ARRAY_STRIDE"/>
+ <enum value="0x8086" name="GL_INDEX_ARRAY_STRIDE_EXT"/>
+ <enum value="0x8087" name="GL_INDEX_ARRAY_COUNT_EXT"/>
+ <enum value="0x8088" name="GL_TEXTURE_COORD_ARRAY_SIZE"/>
+ <enum value="0x8088" name="GL_TEXTURE_COORD_ARRAY_SIZE_EXT"/>
+ <enum value="0x8089" name="GL_TEXTURE_COORD_ARRAY_TYPE"/>
+ <enum value="0x8089" name="GL_TEXTURE_COORD_ARRAY_TYPE_EXT"/>
+ <enum value="0x808A" name="GL_TEXTURE_COORD_ARRAY_STRIDE"/>
+ <enum value="0x808A" name="GL_TEXTURE_COORD_ARRAY_STRIDE_EXT"/>
+ <enum value="0x808B" name="GL_TEXTURE_COORD_ARRAY_COUNT_EXT"/>
+ <enum value="0x808C" name="GL_EDGE_FLAG_ARRAY_STRIDE"/>
+ <enum value="0x808C" name="GL_EDGE_FLAG_ARRAY_STRIDE_EXT"/>
+ <enum value="0x808D" name="GL_EDGE_FLAG_ARRAY_COUNT_EXT"/>
+ <enum value="0x808E" name="GL_VERTEX_ARRAY_POINTER"/>
+ <enum value="0x808E" name="GL_VERTEX_ARRAY_POINTER_EXT"/>
+ <enum value="0x808F" name="GL_NORMAL_ARRAY_POINTER"/>
+ <enum value="0x808F" name="GL_NORMAL_ARRAY_POINTER_EXT"/>
+ <enum value="0x8090" name="GL_COLOR_ARRAY_POINTER"/>
+ <enum value="0x8090" name="GL_COLOR_ARRAY_POINTER_EXT"/>
+ <enum value="0x8091" name="GL_INDEX_ARRAY_POINTER"/>
+ <enum value="0x8091" name="GL_INDEX_ARRAY_POINTER_EXT"/>
+ <enum value="0x8092" name="GL_TEXTURE_COORD_ARRAY_POINTER"/>
+ <enum value="0x8092" name="GL_TEXTURE_COORD_ARRAY_POINTER_EXT"/>
+ <enum value="0x8093" name="GL_EDGE_FLAG_ARRAY_POINTER"/>
+ <enum value="0x8093" name="GL_EDGE_FLAG_ARRAY_POINTER_EXT"/>
+ <enum value="0x8094" name="GL_INTERLACE_SGIX"/>
+ <enum value="0x8095" name="GL_DETAIL_TEXTURE_2D_SGIS"/>
+ <enum value="0x8096" name="GL_DETAIL_TEXTURE_2D_BINDING_SGIS"/>
+ <enum value="0x8097" name="GL_LINEAR_DETAIL_SGIS"/>
+ <enum value="0x8098" name="GL_LINEAR_DETAIL_ALPHA_SGIS"/>
+ <enum value="0x8099" name="GL_LINEAR_DETAIL_COLOR_SGIS"/>
+ <enum value="0x809A" name="GL_DETAIL_TEXTURE_LEVEL_SGIS"/>
+ <enum value="0x809B" name="GL_DETAIL_TEXTURE_MODE_SGIS"/>
+ <enum value="0x809C" name="GL_DETAIL_TEXTURE_FUNC_POINTS_SGIS"/>
+ <enum value="0x809D" name="GL_MULTISAMPLE"/>
+ <enum value="0x809D" name="GL_MULTISAMPLE_ARB"/>
+ <enum value="0x809D" name="GL_MULTISAMPLE_EXT"/>
+ <enum value="0x809D" name="GL_MULTISAMPLE_SGIS"/>
+ <enum value="0x809E" name="GL_SAMPLE_ALPHA_TO_COVERAGE"/>
+ <enum value="0x809E" name="GL_SAMPLE_ALPHA_TO_COVERAGE_ARB"/>
+ <enum value="0x809E" name="GL_SAMPLE_ALPHA_TO_MASK_EXT"/>
+ <enum value="0x809E" name="GL_SAMPLE_ALPHA_TO_MASK_SGIS"/>
+ <enum value="0x809F" name="GL_SAMPLE_ALPHA_TO_ONE"/>
+ <enum value="0x809F" name="GL_SAMPLE_ALPHA_TO_ONE_ARB"/>
+ <enum value="0x809F" name="GL_SAMPLE_ALPHA_TO_ONE_EXT"/>
+ <enum value="0x809F" name="GL_SAMPLE_ALPHA_TO_ONE_SGIS"/>
+ <enum value="0x80A0" name="GL_SAMPLE_COVERAGE"/>
+ <enum value="0x80A0" name="GL_SAMPLE_COVERAGE_ARB"/>
+ <enum value="0x80A0" name="GL_SAMPLE_MASK_EXT"/>
+ <enum value="0x80A0" name="GL_SAMPLE_MASK_SGIS"/>
+ <enum value="0x80A1" name="GL_1PASS_EXT"/>
+ <enum value="0x80A1" name="GL_1PASS_SGIS"/>
+ <enum value="0x80A2" name="GL_2PASS_0_EXT"/>
+ <enum value="0x80A2" name="GL_2PASS_0_SGIS"/>
+ <enum value="0x80A3" name="GL_2PASS_1_EXT"/>
+ <enum value="0x80A3" name="GL_2PASS_1_SGIS"/>
+ <enum value="0x80A4" name="GL_4PASS_0_EXT"/>
+ <enum value="0x80A4" name="GL_4PASS_0_SGIS"/>
+ <enum value="0x80A5" name="GL_4PASS_1_EXT"/>
+ <enum value="0x80A5" name="GL_4PASS_1_SGIS"/>
+ <enum value="0x80A6" name="GL_4PASS_2_EXT"/>
+ <enum value="0x80A6" name="GL_4PASS_2_SGIS"/>
+ <enum value="0x80A7" name="GL_4PASS_3_EXT"/>
+ <enum value="0x80A7" name="GL_4PASS_3_SGIS"/>
+ <enum value="0x80A8" name="GL_SAMPLE_BUFFERS"/>
+ <enum value="0x80A8" name="GL_SAMPLE_BUFFERS_ARB"/>
+ <enum value="0x80A8" name="GL_SAMPLE_BUFFERS_EXT"/>
+ <enum value="0x80A8" name="GL_SAMPLE_BUFFERS_SGIS"/>
+ <enum value="0x80A9" name="GL_SAMPLES"/>
+ <enum value="0x80A9" name="GL_SAMPLES_ARB"/>
+ <enum value="0x80A9" name="GL_SAMPLES_EXT"/>
+ <enum value="0x80A9" name="GL_SAMPLES_SGIS"/>
+ <enum value="0x80AA" name="GL_SAMPLE_COVERAGE_VALUE"/>
+ <enum value="0x80AA" name="GL_SAMPLE_COVERAGE_VALUE_ARB"/>
+ <enum value="0x80AA" name="GL_SAMPLE_MASK_VALUE_EXT"/>
+ <enum value="0x80AA" name="GL_SAMPLE_MASK_VALUE_SGIS"/>
+ <enum value="0x80AB" name="GL_SAMPLE_COVERAGE_INVERT"/>
+ <enum value="0x80AB" name="GL_SAMPLE_COVERAGE_INVERT_ARB"/>
+ <enum value="0x80AB" name="GL_SAMPLE_MASK_INVERT_EXT"/>
+ <enum value="0x80AB" name="GL_SAMPLE_MASK_INVERT_SGIS"/>
+ <enum value="0x80AC" name="GL_SAMPLE_PATTERN_EXT"/>
+ <enum value="0x80AC" name="GL_SAMPLE_PATTERN_SGIS"/>
+ <enum value="0x80AD" name="GL_LINEAR_SHARPEN_SGIS"/>
+ <enum value="0x80AE" name="GL_LINEAR_SHARPEN_ALPHA_SGIS"/>
+ <enum value="0x80AF" name="GL_LINEAR_SHARPEN_COLOR_SGIS"/>
+ <enum value="0x80B0" name="GL_SHARPEN_TEXTURE_FUNC_POINTS_SGIS"/>
+ <enum value="0x80B1" name="GL_COLOR_MATRIX"/>
+ <enum value="0x80B1" name="GL_COLOR_MATRIX_SGI"/>
+ <enum value="0x80B2" name="GL_COLOR_MATRIX_STACK_DEPTH"/>
+ <enum value="0x80B2" name="GL_COLOR_MATRIX_STACK_DEPTH_SGI"/>
+ <enum value="0x80B3" name="GL_MAX_COLOR_MATRIX_STACK_DEPTH"/>
+ <enum value="0x80B3" name="GL_MAX_COLOR_MATRIX_STACK_DEPTH_SGI"/>
+ <enum value="0x80B4" name="GL_POST_COLOR_MATRIX_RED_SCALE"/>
+ <enum value="0x80B4" name="GL_POST_COLOR_MATRIX_RED_SCALE_SGI"/>
+ <enum value="0x80B5" name="GL_POST_COLOR_MATRIX_GREEN_SCALE"/>
+ <enum value="0x80B5" name="GL_POST_COLOR_MATRIX_GREEN_SCALE_SGI"/>
+ <enum value="0x80B6" name="GL_POST_COLOR_MATRIX_BLUE_SCALE"/>
+ <enum value="0x80B6" name="GL_POST_COLOR_MATRIX_BLUE_SCALE_SGI"/>
+ <enum value="0x80B7" name="GL_POST_COLOR_MATRIX_ALPHA_SCALE"/>
+ <enum value="0x80B7" name="GL_POST_COLOR_MATRIX_ALPHA_SCALE_SGI"/>
+ <enum value="0x80B8" name="GL_POST_COLOR_MATRIX_RED_BIAS"/>
+ <enum value="0x80B8" name="GL_POST_COLOR_MATRIX_RED_BIAS_SGI"/>
+ <enum value="0x80B9" name="GL_POST_COLOR_MATRIX_GREEN_BIAS"/>
+ <enum value="0x80B9" name="GL_POST_COLOR_MATRIX_GREEN_BIAS_SGI"/>
+ <enum value="0x80BA" name="GL_POST_COLOR_MATRIX_BLUE_BIAS"/>
+ <enum value="0x80BA" name="GL_POST_COLOR_MATRIX_BLUE_BIAS_SGI"/>
+ <enum value="0x80BB" name="GL_POST_COLOR_MATRIX_ALPHA_BIAS"/>
+ <enum value="0x80BB" name="GL_POST_COLOR_MATRIX_ALPHA_BIAS_SGI"/>
+ <enum value="0x80BC" name="GL_TEXTURE_COLOR_TABLE_SGI"/>
+ <enum value="0x80BD" name="GL_PROXY_TEXTURE_COLOR_TABLE_SGI"/>
+ <enum value="0x80BE" name="GL_TEXTURE_ENV_BIAS_SGIX"/>
+ <enum value="0x80BF" name="GL_SHADOW_AMBIENT_SGIX"/>
+ <enum value="0x80BF" name="GL_TEXTURE_COMPARE_FAIL_VALUE_ARB"/>
+ </enums>
+
+ <enums namespace="GL" start="0x80C0" end="0x80CF" vendor="ZiiLabs">
+ <unused start="0x80C0" end="0x80C7" vendor="ZiiLabs"/>
+ <enum value="0x80C8" name="GL_BLEND_DST_RGB"/>
+ <enum value="0x80C8" name="GL_BLEND_DST_RGB_EXT"/>
+ <enum value="0x80C8" name="GL_BLEND_DST_RGB_OES"/>
+ <enum value="0x80C9" name="GL_BLEND_SRC_RGB"/>
+ <enum value="0x80C9" name="GL_BLEND_SRC_RGB_EXT"/>
+ <enum value="0x80C9" name="GL_BLEND_SRC_RGB_OES"/>
+ <enum value="0x80CA" name="GL_BLEND_DST_ALPHA"/>
+ <enum value="0x80CA" name="GL_BLEND_DST_ALPHA_EXT"/>
+ <enum value="0x80CA" name="GL_BLEND_DST_ALPHA_OES"/>
+ <enum value="0x80CB" name="GL_BLEND_SRC_ALPHA"/>
+ <enum value="0x80CB" name="GL_BLEND_SRC_ALPHA_EXT"/>
+ <enum value="0x80CB" name="GL_BLEND_SRC_ALPHA_OES"/>
+ <enum value="0x80CC" name="GL_422_EXT"/>
+ <enum value="0x80CD" name="GL_422_REV_EXT"/>
+ <enum value="0x80CE" name="GL_422_AVERAGE_EXT"/>
+ <enum value="0x80CF" name="GL_422_REV_AVERAGE_EXT"/>
+ </enums>
+
+ <enums namespace="GL" start="0x80D0" end="0x80DF" vendor="SGI">
+ <enum value="0x80D0" name="GL_COLOR_TABLE"/>
+ <enum value="0x80D0" name="GL_COLOR_TABLE_SGI"/>
+ <enum value="0x80D1" name="GL_POST_CONVOLUTION_COLOR_TABLE"/>
+ <enum value="0x80D1" name="GL_POST_CONVOLUTION_COLOR_TABLE_SGI"/>
+ <enum value="0x80D2" name="GL_POST_COLOR_MATRIX_COLOR_TABLE"/>
+ <enum value="0x80D2" name="GL_POST_COLOR_MATRIX_COLOR_TABLE_SGI"/>
+ <enum value="0x80D3" name="GL_PROXY_COLOR_TABLE"/>
+ <enum value="0x80D3" name="GL_PROXY_COLOR_TABLE_SGI"/>
+ <enum value="0x80D4" name="GL_PROXY_POST_CONVOLUTION_COLOR_TABLE"/>
+ <enum value="0x80D4" name="GL_PROXY_POST_CONVOLUTION_COLOR_TABLE_SGI"/>
+ <enum value="0x80D5" name="GL_PROXY_POST_COLOR_MATRIX_COLOR_TABLE"/>
+ <enum value="0x80D5" name="GL_PROXY_POST_COLOR_MATRIX_COLOR_TABLE_SGI"/>
+ <enum value="0x80D6" name="GL_COLOR_TABLE_SCALE"/>
+ <enum value="0x80D6" name="GL_COLOR_TABLE_SCALE_SGI"/>
+ <enum value="0x80D7" name="GL_COLOR_TABLE_BIAS"/>
+ <enum value="0x80D7" name="GL_COLOR_TABLE_BIAS_SGI"/>
+ <enum value="0x80D8" name="GL_COLOR_TABLE_FORMAT"/>
+ <enum value="0x80D8" name="GL_COLOR_TABLE_FORMAT_SGI"/>
+ <enum value="0x80D9" name="GL_COLOR_TABLE_WIDTH"/>
+ <enum value="0x80D9" name="GL_COLOR_TABLE_WIDTH_SGI"/>
+ <enum value="0x80DA" name="GL_COLOR_TABLE_RED_SIZE"/>
+ <enum value="0x80DA" name="GL_COLOR_TABLE_RED_SIZE_SGI"/>
+ <enum value="0x80DB" name="GL_COLOR_TABLE_GREEN_SIZE"/>
+ <enum value="0x80DB" name="GL_COLOR_TABLE_GREEN_SIZE_SGI"/>
+ <enum value="0x80DC" name="GL_COLOR_TABLE_BLUE_SIZE"/>
+ <enum value="0x80DC" name="GL_COLOR_TABLE_BLUE_SIZE_SGI"/>
+ <enum value="0x80DD" name="GL_COLOR_TABLE_ALPHA_SIZE"/>
+ <enum value="0x80DD" name="GL_COLOR_TABLE_ALPHA_SIZE_SGI"/>
+ <enum value="0x80DE" name="GL_COLOR_TABLE_LUMINANCE_SIZE"/>
+ <enum value="0x80DE" name="GL_COLOR_TABLE_LUMINANCE_SIZE_SGI"/>
+ <enum value="0x80DF" name="GL_COLOR_TABLE_INTENSITY_SIZE"/>
+ <enum value="0x80DF" name="GL_COLOR_TABLE_INTENSITY_SIZE_SGI"/>
+ </enums>
+
+ <enums namespace="GL" start="0x80E0" end="0x810F" vendor="MS">
+ <enum value="0x80E0" name="GL_BGR"/>
+ <enum value="0x80E0" name="GL_BGR_EXT"/>
+ <enum value="0x80E1" name="GL_BGRA"/>
+ <enum value="0x80E1" name="GL_BGRA_EXT"/>
+ <enum value="0x80E1" name="GL_BGRA_IMG"/>
+ <enum value="0x80E2" name="GL_COLOR_INDEX1_EXT"/>
+ <enum value="0x80E3" name="GL_COLOR_INDEX2_EXT"/>
+ <enum value="0x80E4" name="GL_COLOR_INDEX4_EXT"/>
+ <enum value="0x80E5" name="GL_COLOR_INDEX8_EXT"/>
+ <enum value="0x80E6" name="GL_COLOR_INDEX12_EXT"/>
+ <enum value="0x80E7" name="GL_COLOR_INDEX16_EXT"/>
+ <enum value="0x80E8" name="GL_MAX_ELEMENTS_VERTICES"/>
+ <enum value="0x80E8" name="GL_MAX_ELEMENTS_VERTICES_EXT"/>
+ <enum value="0x80E9" name="GL_MAX_ELEMENTS_INDICES"/>
+ <enum value="0x80E9" name="GL_MAX_ELEMENTS_INDICES_EXT"/>
+ <enum value="0x80EA" name="GL_PHONG_WIN"/>
+ <enum value="0x80EB" name="GL_PHONG_HINT_WIN"/>
+ <enum value="0x80EC" name="GL_FOG_SPECULAR_TEXTURE_WIN"/>
+ <enum value="0x80ED" name="GL_TEXTURE_INDEX_SIZE_EXT"/>
+ <enum value="0x80EE" name="GL_PARAMETER_BUFFER_ARB"/>
+ <enum value="0x80EF" name="GL_PARAMETER_BUFFER_BINDING_ARB"/>
+ <enum value="0x80F0" name="GL_CLIP_VOLUME_CLIPPING_HINT_EXT"/>
+ <unused start="0x80F1" end="0x810F" vendor="MS"/>
+ </enums>
+
+ <enums namespace="GL" start="0x8110" end="0x814F" vendor="SGI">
+ <enum value="0x8110" name="GL_DUAL_ALPHA4_SGIS"/>
+ <enum value="0x8111" name="GL_DUAL_ALPHA8_SGIS"/>
+ <enum value="0x8112" name="GL_DUAL_ALPHA12_SGIS"/>
+ <enum value="0x8113" name="GL_DUAL_ALPHA16_SGIS"/>
+ <enum value="0x8114" name="GL_DUAL_LUMINANCE4_SGIS"/>
+ <enum value="0x8115" name="GL_DUAL_LUMINANCE8_SGIS"/>
+ <enum value="0x8116" name="GL_DUAL_LUMINANCE12_SGIS"/>
+ <enum value="0x8117" name="GL_DUAL_LUMINANCE16_SGIS"/>
+ <enum value="0x8118" name="GL_DUAL_INTENSITY4_SGIS"/>
+ <enum value="0x8119" name="GL_DUAL_INTENSITY8_SGIS"/>
+ <enum value="0x811A" name="GL_DUAL_INTENSITY12_SGIS"/>
+ <enum value="0x811B" name="GL_DUAL_INTENSITY16_SGIS"/>
+ <enum value="0x811C" name="GL_DUAL_LUMINANCE_ALPHA4_SGIS"/>
+ <enum value="0x811D" name="GL_DUAL_LUMINANCE_ALPHA8_SGIS"/>
+ <enum value="0x811E" name="GL_QUAD_ALPHA4_SGIS"/>
+ <enum value="0x811F" name="GL_QUAD_ALPHA8_SGIS"/>
+ <enum value="0x8120" name="GL_QUAD_LUMINANCE4_SGIS"/>
+ <enum value="0x8121" name="GL_QUAD_LUMINANCE8_SGIS"/>
+ <enum value="0x8122" name="GL_QUAD_INTENSITY4_SGIS"/>
+ <enum value="0x8123" name="GL_QUAD_INTENSITY8_SGIS"/>
+ <enum value="0x8124" name="GL_DUAL_TEXTURE_SELECT_SGIS"/>
+ <enum value="0x8125" name="GL_QUAD_TEXTURE_SELECT_SGIS"/>
+ <enum value="0x8126" name="GL_POINT_SIZE_MIN"/>
+ <enum value="0x8126" name="GL_POINT_SIZE_MIN_ARB"/>
+ <enum value="0x8126" name="GL_POINT_SIZE_MIN_EXT"/>
+ <enum value="0x8126" name="GL_POINT_SIZE_MIN_SGIS"/>
+ <enum value="0x8127" name="GL_POINT_SIZE_MAX"/>
+ <enum value="0x8127" name="GL_POINT_SIZE_MAX_ARB"/>
+ <enum value="0x8127" name="GL_POINT_SIZE_MAX_EXT"/>
+ <enum value="0x8127" name="GL_POINT_SIZE_MAX_SGIS"/>
+ <enum value="0x8128" name="GL_POINT_FADE_THRESHOLD_SIZE"/>
+ <enum value="0x8128" name="GL_POINT_FADE_THRESHOLD_SIZE_ARB"/>
+ <enum value="0x8128" name="GL_POINT_FADE_THRESHOLD_SIZE_EXT"/>
+ <enum value="0x8128" name="GL_POINT_FADE_THRESHOLD_SIZE_SGIS"/>
+ <enum value="0x8129" name="GL_DISTANCE_ATTENUATION_EXT"/>
+ <enum value="0x8129" name="GL_DISTANCE_ATTENUATION_SGIS"/>
+ <enum value="0x8129" name="GL_POINT_DISTANCE_ATTENUATION"/>
+ <enum value="0x8129" name="GL_POINT_DISTANCE_ATTENUATION_ARB"/>
+ <enum value="0x812A" name="GL_FOG_FUNC_SGIS"/>
+ <enum value="0x812B" name="GL_FOG_FUNC_POINTS_SGIS"/>
+ <enum value="0x812C" name="GL_MAX_FOG_FUNC_POINTS_SGIS"/>
+ <enum value="0x812D" name="GL_CLAMP_TO_BORDER"/>
+ <enum value="0x812D" name="GL_CLAMP_TO_BORDER_ARB"/>
+ <enum value="0x812D" name="GL_CLAMP_TO_BORDER_EXT"/>
+ <enum value="0x812D" name="GL_CLAMP_TO_BORDER_NV"/>
+ <enum value="0x812D" name="GL_CLAMP_TO_BORDER_SGIS"/>
+ <enum value="0x812E" name="GL_TEXTURE_MULTI_BUFFER_HINT_SGIX"/>
+ <enum value="0x812F" name="GL_CLAMP_TO_EDGE"/>
+ <enum value="0x812F" name="GL_CLAMP_TO_EDGE_SGIS"/>
+ <enum value="0x8130" name="GL_PACK_SKIP_VOLUMES_SGIS"/>
+ <enum value="0x8131" name="GL_PACK_IMAGE_DEPTH_SGIS"/>
+ <enum value="0x8132" name="GL_UNPACK_SKIP_VOLUMES_SGIS"/>
+ <enum value="0x8133" name="GL_UNPACK_IMAGE_DEPTH_SGIS"/>
+ <enum value="0x8134" name="GL_TEXTURE_4D_SGIS"/>
+ <enum value="0x8135" name="GL_PROXY_TEXTURE_4D_SGIS"/>
+ <enum value="0x8136" name="GL_TEXTURE_4DSIZE_SGIS"/>
+ <enum value="0x8137" name="GL_TEXTURE_WRAP_Q_SGIS"/>
+ <enum value="0x8138" name="GL_MAX_4D_TEXTURE_SIZE_SGIS"/>
+ <enum value="0x8139" name="GL_PIXEL_TEX_GEN_SGIX"/>
+ <enum value="0x813A" name="GL_TEXTURE_MIN_LOD"/>
+ <enum value="0x813A" name="GL_TEXTURE_MIN_LOD_SGIS"/>
+ <enum value="0x813B" name="GL_TEXTURE_MAX_LOD"/>
+ <enum value="0x813B" name="GL_TEXTURE_MAX_LOD_SGIS"/>
+ <enum value="0x813C" name="GL_TEXTURE_BASE_LEVEL"/>
+ <enum value="0x813C" name="GL_TEXTURE_BASE_LEVEL_SGIS"/>
+ <enum value="0x813D" name="GL_TEXTURE_MAX_LEVEL"/>
+ <enum value="0x813D" name="GL_TEXTURE_MAX_LEVEL_APPLE"/>
+ <enum value="0x813D" name="GL_TEXTURE_MAX_LEVEL_SGIS"/>
+ <enum value="0x813E" name="GL_PIXEL_TILE_BEST_ALIGNMENT_SGIX"/>
+ <enum value="0x813F" name="GL_PIXEL_TILE_CACHE_INCREMENT_SGIX"/>
+ <enum value="0x8140" name="GL_PIXEL_TILE_WIDTH_SGIX"/>
+ <enum value="0x8141" name="GL_PIXEL_TILE_HEIGHT_SGIX"/>
+ <enum value="0x8142" name="GL_PIXEL_TILE_GRID_WIDTH_SGIX"/>
+ <enum value="0x8143" name="GL_PIXEL_TILE_GRID_HEIGHT_SGIX"/>
+ <enum value="0x8144" name="GL_PIXEL_TILE_GRID_DEPTH_SGIX"/>
+ <enum value="0x8145" name="GL_PIXEL_TILE_CACHE_SIZE_SGIX"/>
+ <enum value="0x8146" name="GL_FILTER4_SGIS"/>
+ <enum value="0x8147" name="GL_TEXTURE_FILTER4_SIZE_SGIS"/>
+ <enum value="0x8148" name="GL_SPRITE_SGIX"/>
+ <enum value="0x8149" name="GL_SPRITE_MODE_SGIX"/>
+ <enum value="0x814A" name="GL_SPRITE_AXIS_SGIX"/>
+ <enum value="0x814B" name="GL_SPRITE_TRANSLATION_SGIX"/>
+ <enum value="0x814C" name="GL_SPRITE_AXIAL_SGIX"/>
+ <enum value="0x814D" name="GL_SPRITE_OBJECT_ALIGNED_SGIX"/>
+ <enum value="0x814E" name="GL_SPRITE_EYE_ALIGNED_SGIX"/>
+ <enum value="0x814F" name="GL_TEXTURE_4D_BINDING_SGIS"/>
+ </enums>
+
+ <enums namespace="GL" start="0x8150" end="0x816F" vendor="HP">
+ <enum value="0x8150" name="GL_IGNORE_BORDER_HP"/>
+ <enum value="0x8151" name="GL_CONSTANT_BORDER"/>
+ <enum value="0x8151" name="GL_CONSTANT_BORDER_HP"/>
+ <unused start="0x8152" vendor="HP" comment="GL_WRAP_BORDER = 0x8152 was proposed, but not actually promoted to core"/>
+ <enum value="0x8153" name="GL_REPLICATE_BORDER"/>
+ <enum value="0x8153" name="GL_REPLICATE_BORDER_HP"/>
+ <enum value="0x8154" name="GL_CONVOLUTION_BORDER_COLOR"/>
+ <enum value="0x8154" name="GL_CONVOLUTION_BORDER_COLOR_HP"/>
+ <enum value="0x8155" name="GL_IMAGE_SCALE_X_HP"/>
+ <enum value="0x8156" name="GL_IMAGE_SCALE_Y_HP"/>
+ <enum value="0x8157" name="GL_IMAGE_TRANSLATE_X_HP"/>
+ <enum value="0x8158" name="GL_IMAGE_TRANSLATE_Y_HP"/>
+ <enum value="0x8159" name="GL_IMAGE_ROTATE_ANGLE_HP"/>
+ <enum value="0x815A" name="GL_IMAGE_ROTATE_ORIGIN_X_HP"/>
+ <enum value="0x815B" name="GL_IMAGE_ROTATE_ORIGIN_Y_HP"/>
+ <enum value="0x815C" name="GL_IMAGE_MAG_FILTER_HP"/>
+ <enum value="0x815D" name="GL_IMAGE_MIN_FILTER_HP"/>
+ <enum value="0x815E" name="GL_IMAGE_CUBIC_WEIGHT_HP"/>
+ <enum value="0x815F" name="GL_CUBIC_HP"/>
+ <enum value="0x8160" name="GL_AVERAGE_HP"/>
+ <enum value="0x8161" name="GL_IMAGE_TRANSFORM_2D_HP"/>
+ <enum value="0x8162" name="GL_POST_IMAGE_TRANSFORM_COLOR_TABLE_HP"/>
+ <enum value="0x8163" name="GL_PROXY_POST_IMAGE_TRANSFORM_COLOR_TABLE_HP"/>
+ <unused start="0x8164" vendor="HP"/>
+ <enum value="0x8165" name="GL_OCCLUSION_TEST_HP"/>
+ <enum value="0x8166" name="GL_OCCLUSION_TEST_RESULT_HP"/>
+ <enum value="0x8167" name="GL_TEXTURE_LIGHTING_MODE_HP"/>
+ <enum value="0x8168" name="GL_TEXTURE_POST_SPECULAR_HP"/>
+ <enum value="0x8169" name="GL_TEXTURE_PRE_SPECULAR_HP"/>
+ <unused start="0x816A" end="0x816F" vendor="HP"/>
+ </enums>
+
+ <enums namespace="GL" start="0x8170" end="0x81CF" vendor="SGI">
+ <enum value="0x8170" name="GL_LINEAR_CLIPMAP_LINEAR_SGIX"/>
+ <enum value="0x8171" name="GL_TEXTURE_CLIPMAP_CENTER_SGIX"/>
+ <enum value="0x8172" name="GL_TEXTURE_CLIPMAP_FRAME_SGIX"/>
+ <enum value="0x8173" name="GL_TEXTURE_CLIPMAP_OFFSET_SGIX"/>
+ <enum value="0x8174" name="GL_TEXTURE_CLIPMAP_VIRTUAL_DEPTH_SGIX"/>
+ <enum value="0x8175" name="GL_TEXTURE_CLIPMAP_LOD_OFFSET_SGIX"/>
+ <enum value="0x8176" name="GL_TEXTURE_CLIPMAP_DEPTH_SGIX"/>
+ <enum value="0x8177" name="GL_MAX_CLIPMAP_DEPTH_SGIX"/>
+ <enum value="0x8178" name="GL_MAX_CLIPMAP_VIRTUAL_DEPTH_SGIX"/>
+ <enum value="0x8179" name="GL_POST_TEXTURE_FILTER_BIAS_SGIX"/>
+ <enum value="0x817A" name="GL_POST_TEXTURE_FILTER_SCALE_SGIX"/>
+ <enum value="0x817B" name="GL_POST_TEXTURE_FILTER_BIAS_RANGE_SGIX"/>
+ <enum value="0x817C" name="GL_POST_TEXTURE_FILTER_SCALE_RANGE_SGIX"/>
+ <enum value="0x817D" name="GL_REFERENCE_PLANE_SGIX"/>
+ <enum value="0x817E" name="GL_REFERENCE_PLANE_EQUATION_SGIX"/>
+ <enum value="0x817F" name="GL_IR_INSTRUMENT1_SGIX"/>
+ <enum value="0x8180" name="GL_INSTRUMENT_BUFFER_POINTER_SGIX"/>
+ <enum value="0x8181" name="GL_INSTRUMENT_MEASUREMENTS_SGIX"/>
+ <enum value="0x8182" name="GL_LIST_PRIORITY_SGIX"/>
+ <enum value="0x8183" name="GL_CALLIGRAPHIC_FRAGMENT_SGIX"/>
+ <enum value="0x8184" name="GL_PIXEL_TEX_GEN_Q_CEILING_SGIX"/>
+ <enum value="0x8185" name="GL_PIXEL_TEX_GEN_Q_ROUND_SGIX"/>
+ <enum value="0x8186" name="GL_PIXEL_TEX_GEN_Q_FLOOR_SGIX"/>
+ <enum value="0x8187" name="GL_PIXEL_TEX_GEN_ALPHA_REPLACE_SGIX"/>
+ <enum value="0x8188" name="GL_PIXEL_TEX_GEN_ALPHA_NO_REPLACE_SGIX"/>
+ <enum value="0x8189" name="GL_PIXEL_TEX_GEN_ALPHA_LS_SGIX"/>
+ <enum value="0x818A" name="GL_PIXEL_TEX_GEN_ALPHA_MS_SGIX"/>
+ <enum value="0x818B" name="GL_FRAMEZOOM_SGIX"/>
+ <enum value="0x818C" name="GL_FRAMEZOOM_FACTOR_SGIX"/>
+ <enum value="0x818D" name="GL_MAX_FRAMEZOOM_FACTOR_SGIX"/>
+ <enum value="0x818E" name="GL_TEXTURE_LOD_BIAS_S_SGIX"/>
+ <enum value="0x818F" name="GL_TEXTURE_LOD_BIAS_T_SGIX"/>
+ <enum value="0x8190" name="GL_TEXTURE_LOD_BIAS_R_SGIX"/>
+ <enum value="0x8191" name="GL_GENERATE_MIPMAP"/>
+ <enum value="0x8191" name="GL_GENERATE_MIPMAP_SGIS"/>
+ <enum value="0x8192" name="GL_GENERATE_MIPMAP_HINT"/>
+ <enum value="0x8192" name="GL_GENERATE_MIPMAP_HINT_SGIS"/>
+ <unused start="0x8193" end="0x8193" comment="Incomplete extension SGIX_spotlight_cutoff"/>
+ <!-- <enum value="0x8193" name="GL_SPOT_CUTOFF_DELTA_SGIX"/> -->
+ <enum value="0x8194" name="GL_GEOMETRY_DEFORMATION_SGIX"/>
+ <enum value="0x8195" name="GL_TEXTURE_DEFORMATION_SGIX"/>
+ <enum value="0x8196" name="GL_DEFORMATIONS_MASK_SGIX"/>
+ <enum value="0x8197" name="GL_MAX_DEFORMATION_ORDER_SGIX"/>
+ <enum value="0x8198" name="GL_FOG_OFFSET_SGIX"/>
+ <enum value="0x8199" name="GL_FOG_OFFSET_VALUE_SGIX"/>
+ <enum value="0x819A" name="GL_TEXTURE_COMPARE_SGIX"/>
+ <enum value="0x819B" name="GL_TEXTURE_COMPARE_OPERATOR_SGIX"/>
+ <enum value="0x819C" name="GL_TEXTURE_LEQUAL_R_SGIX"/>
+ <enum value="0x819D" name="GL_TEXTURE_GEQUAL_R_SGIX"/>
+ <unused start="0x819E" end="0x81A4" comment="Private (internal) extension SGIX_igloo_interface"/>
+ <!-- <enum value="0x819E" name="GL_IGLOO_FULLSCREEN_SGIX"/> -->
+ <!-- <enum value="0x819F" name="GL_IGLOO_VIEWPORT_OFFSET_SGIX"/> -->
+ <!-- <enum value="0x81A0" name="GL_IGLOO_SWAPTMESH_SGIX"/> -->
+ <!-- <enum value="0x81A1" name="GL_IGLOO_COLORNORMAL_SGIX"/> -->
+ <!-- <enum value="0x81A2" name="GL_IGLOO_IRISGL_MODE_SGIX"/> -->
+ <!-- <enum value="0x81A3" name="GL_IGLOO_LMC_COLOR_SGIX"/> -->
+ <!-- <enum value="0x81A4" name="GL_IGLOO_TMESHMODE_SGIX"/> -->
+ <enum value="0x81A5" name="GL_DEPTH_COMPONENT16"/>
+ <enum value="0x81A5" name="GL_DEPTH_COMPONENT16_ARB"/>
+ <enum value="0x81A5" name="GL_DEPTH_COMPONENT16_OES"/>
+ <enum value="0x81A5" name="GL_DEPTH_COMPONENT16_SGIX"/>
+ <enum value="0x81A6" name="GL_DEPTH_COMPONENT24"/>
+ <enum value="0x81A6" name="GL_DEPTH_COMPONENT24_ARB"/>
+ <enum value="0x81A6" name="GL_DEPTH_COMPONENT24_OES"/>
+ <enum value="0x81A6" name="GL_DEPTH_COMPONENT24_SGIX"/>
+ <enum value="0x81A7" name="GL_DEPTH_COMPONENT32"/>
+ <enum value="0x81A7" name="GL_DEPTH_COMPONENT32_ARB"/>
+ <enum value="0x81A7" name="GL_DEPTH_COMPONENT32_OES"/>
+ <enum value="0x81A7" name="GL_DEPTH_COMPONENT32_SGIX"/>
+ <enum value="0x81A8" name="GL_ARRAY_ELEMENT_LOCK_FIRST_EXT"/>
+ <enum value="0x81A9" name="GL_ARRAY_ELEMENT_LOCK_COUNT_EXT"/>
+ <enum value="0x81AA" name="GL_CULL_VERTEX_EXT"/>
+ <enum value="0x81AB" name="GL_CULL_VERTEX_EYE_POSITION_EXT"/>
+ <enum value="0x81AC" name="GL_CULL_VERTEX_OBJECT_POSITION_EXT"/>
+ <enum value="0x81AD" name="GL_IUI_V2F_EXT"/>
+ <enum value="0x81AE" name="GL_IUI_V3F_EXT"/>
+ <enum value="0x81AF" name="GL_IUI_N3F_V2F_EXT"/>
+ <enum value="0x81B0" name="GL_IUI_N3F_V3F_EXT"/>
+ <enum value="0x81B1" name="GL_T2F_IUI_V2F_EXT"/>
+ <enum value="0x81B2" name="GL_T2F_IUI_V3F_EXT"/>
+ <enum value="0x81B3" name="GL_T2F_IUI_N3F_V2F_EXT"/>
+ <enum value="0x81B4" name="GL_T2F_IUI_N3F_V3F_EXT"/>
+ <enum value="0x81B5" name="GL_INDEX_TEST_EXT"/>
+ <enum value="0x81B6" name="GL_INDEX_TEST_FUNC_EXT"/>
+ <enum value="0x81B7" name="GL_INDEX_TEST_REF_EXT"/>
+ <enum value="0x81B8" name="GL_INDEX_MATERIAL_EXT"/>
+ <enum value="0x81B9" name="GL_INDEX_MATERIAL_PARAMETER_EXT"/>
+ <enum value="0x81BA" name="GL_INDEX_MATERIAL_FACE_EXT"/>
+ <enum value="0x81BB" name="GL_YCRCB_422_SGIX"/>
+ <enum value="0x81BC" name="GL_YCRCB_444_SGIX"/>
+ <unused start="0x81BD" end="0x81C3" comment="Incomplete extension SGI_complex_type"/>
+ <!-- <enum value="0x81BD" name="GL_COMPLEX_UNSIGNED_BYTE_SGI"/> -->
+ <!-- <enum value="0x81BE" name="GL_COMPLEX_BYTE_SGI"/> -->
+ <!-- <enum value="0x81BF" name="GL_COMPLEX_UNSIGNED_SHORT_SGI"/> -->
+ <!-- <enum value="0x81C0" name="GL_COMPLEX_SHORT_SGI"/> -->
+ <!-- <enum value="0x81C1" name="GL_COMPLEX_UNSIGNED_INT_SGI"/> -->
+ <!-- <enum value="0x81C2" name="GL_COMPLEX_INT_SGI"/> -->
+ <!-- <enum value="0x81C3" name="GL_COMPLEX_FLOAT_SGI"/> -->
+ <unused start="0x81C4" end="0x81CA" comment="Incomplete extension SGI_fft"/>
+ <!-- <enum value="0x81C4" name="GL_PIXEL_TRANSFORM_OPERATOR_SGI"/> -->
+ <!-- <enum value="0x81C5" name="GL_CONVOLUTION_SGI"/> -->
+ <!-- <enum value="0x81C6" name="GL_FFT_1D_SGI"/> -->
+ <!-- <enum value="0x81C7" name="GL_PIXEL_TRANSFORM_SGI"/> -->
+ <!-- <enum value="0x81C8" name="GL_MAX_FFT_WIDTH_SGI"/> -->
+ <!-- <enum value="0x81C9" name="GL_SORT_SGI"/> -->
+ <!-- <enum value="0x81CA" name="GL_TRANSPOSE_SGI"/> -->
+ <unused start="0x81CB" end="0x81CF" comment="Incomplete extension SGIX_nurbs_eval"/>
+ <!-- <enum value="0x81CB" name="GL_MAP1_VERTEX_3_NURBS_SGIX"/> -->
+ <!-- <enum value="0x81CC" name="GL_MAP1_VERTEX_4_NURBS_SGIX"/> -->
+ <!-- <enum value="0x81CD" name="GL_MAP1_INDEX_NURBS_SGIX"/> -->
+ <!-- <enum value="0x81CE" name="GL_MAP1_COLOR_4_NURBS_SGIX"/> -->
+ <!-- <enum value="0x81CF" name="GL_MAP1_NORMAL_NURBS_SGIX"/> -->
+ </enums>
+
+ <enums namespace="GL" start="0x81D0" end="0x81DF" vendor="SUN">
+ <unused start="0x81D0" end="0x81D1" vendor="SUN"/>
+ <unused start="0x81D2" end="0x81D3" comment="No extension spec SUNX_surface_hint"/>
+ <!-- <enum value="0x81D2" name="GL_SURFACE_SIZE_HINT_SUNX"/> -->
+ <!-- <enum value="0x81D3" name="GL_LARGE_SUNX"/> -->
+ <enum value="0x81D4" name="GL_WRAP_BORDER_SUN"/>
+ <enum value="0x81D5" name="GL_UNPACK_CONSTANT_DATA_SUNX"/>
+ <enum value="0x81D6" name="GL_TEXTURE_CONSTANT_DATA_SUNX"/>
+ <enum value="0x81D7" name="GL_TRIANGLE_LIST_SUN"/>
+ <enum value="0x81D8" name="GL_REPLACEMENT_CODE_SUN"/>
+ <enum value="0x81D9" name="GL_GLOBAL_ALPHA_SUN"/>
+ <enum value="0x81DA" name="GL_GLOBAL_ALPHA_FACTOR_SUN"/>
+ <unused start="0x81DB" end="0x81DF" vendor="SUN"/>
+ </enums>
+
+ <enums namespace="GL" start="0x81E0" end="0x81FF" vendor="SGI">
+ <unused start="0x81E0" end="0x81EE" comment="Incomplete extension SGIX_nurbs_eval"/>
+ <!-- <enum value="0x81E0" name="GL_MAP1_TEXTURE_COORD_1_NURBS_SGIX"/> -->
+ <!-- <enum value="0x81E1" name="GL_MAP1_TEXTURE_COORD_2_NURBS_SGIX"/> -->
+ <!-- <enum value="0x81E2" name="GL_MAP1_TEXTURE_COORD_3_NURBS_SGIX"/> -->
+ <!-- <enum value="0x81E3" name="GL_MAP1_TEXTURE_COORD_4_NURBS_SGIX"/> -->
+ <!-- <enum value="0x81E4" name="GL_MAP2_VERTEX_3_NURBS_SGIX"/> -->
+ <!-- <enum value="0x81E5" name="GL_MAP2_VERTEX_4_NURBS_SGIX"/> -->
+ <!-- <enum value="0x81E6" name="GL_MAP2_INDEX_NURBS_SGIX"/> -->
+ <!-- <enum value="0x81E7" name="GL_MAP2_COLOR_4_NURBS_SGIX"/> -->
+ <!-- <enum value="0x81E8" name="GL_MAP2_NORMAL_NURBS_SGIX"/> -->
+ <!-- <enum value="0x81E9" name="GL_MAP2_TEXTURE_COORD_1_NURBS_SGIX"/> -->
+ <!-- <enum value="0x81EA" name="GL_MAP2_TEXTURE_COORD_2_NURBS_SGIX"/> -->
+ <!-- <enum value="0x81EB" name="GL_MAP2_TEXTURE_COORD_3_NURBS_SGIX"/> -->
+ <!-- <enum value="0x81EC" name="GL_MAP2_TEXTURE_COORD_4_NURBS_SGIX"/> -->
+ <!-- <enum value="0x81ED" name="GL_NURBS_KNOT_COUNT_SGIX"/> -->
+ <!-- <enum value="0x81EE" name="GL_NURBS_KNOT_VECTOR_SGIX"/> -->
+ <enum value="0x81EF" name="GL_TEXTURE_COLOR_WRITEMASK_SGIS"/>
+ <enum value="0x81F0" name="GL_EYE_DISTANCE_TO_POINT_SGIS"/>
+ <enum value="0x81F1" name="GL_OBJECT_DISTANCE_TO_POINT_SGIS"/>
+ <enum value="0x81F2" name="GL_EYE_DISTANCE_TO_LINE_SGIS"/>
+ <enum value="0x81F3" name="GL_OBJECT_DISTANCE_TO_LINE_SGIS"/>
+ <enum value="0x81F4" name="GL_EYE_POINT_SGIS"/>
+ <enum value="0x81F5" name="GL_OBJECT_POINT_SGIS"/>
+ <enum value="0x81F6" name="GL_EYE_LINE_SGIS"/>
+ <enum value="0x81F7" name="GL_OBJECT_LINE_SGIS"/>
+ <enum value="0x81F8" name="GL_LIGHT_MODEL_COLOR_CONTROL"/>
+ <enum value="0x81F8" name="GL_LIGHT_MODEL_COLOR_CONTROL_EXT"/>
+ <enum value="0x81F9" name="GL_SINGLE_COLOR"/>
+ <enum value="0x81F9" name="GL_SINGLE_COLOR_EXT"/>
+ <enum value="0x81FA" name="GL_SEPARATE_SPECULAR_COLOR"/>
+ <enum value="0x81FA" name="GL_SEPARATE_SPECULAR_COLOR_EXT"/>
+ <enum value="0x81FB" name="GL_SHARED_TEXTURE_PALETTE_EXT"/>
+ <unused start="0x81FC" end="0x81FD" comment="Incomplete extension SGIX_fog_scale"/>
+ <!-- <enum value="0x81FC" name="GL_FOG_SCALE_SGIX"/> -->
+ <!-- <enum value="0x81FD" name="GL_FOG_SCALE_VALUE_SGIX"/> -->
+ <unused start="0x81FE" end="0x81FF" comment="Incomplete extension SGIX_fog_blend"/>
+ <!-- <enum value="0x81FE" name="GL_FOG_BLEND_ALPHA_SGIX"/> -->
+ <!-- <enum value="0x81FF" name="GL_FOG_BLEND_COLOR_SGIX"/> -->
+ </enums>
+
+ <enums namespace="GL" start="0x8200" end="0x820F" vendor="AMD" comment="Range released by MS 2002/9/16">
+ <enum value="0x8200" name="GL_TEXT_FRAGMENT_SHADER_ATI"/>
+ <unused start="0x8201" end="0x820F" vendor="AMD"/>
+ </enums>
+
+ <enums namespace="GL" start="0x8210" end="0x823F" vendor="ARB">
+ <enum value="0x8210" name="GL_FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING"/>
+ <enum value="0x8210" name="GL_FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING_EXT"/>
+ <enum value="0x8211" name="GL_FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE"/>
+ <enum value="0x8211" name="GL_FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE_EXT"/>
+ <enum value="0x8212" name="GL_FRAMEBUFFER_ATTACHMENT_RED_SIZE"/>
+ <enum value="0x8213" name="GL_FRAMEBUFFER_ATTACHMENT_GREEN_SIZE"/>
+ <enum value="0x8214" name="GL_FRAMEBUFFER_ATTACHMENT_BLUE_SIZE"/>
+ <enum value="0x8215" name="GL_FRAMEBUFFER_ATTACHMENT_ALPHA_SIZE"/>
+ <enum value="0x8216" name="GL_FRAMEBUFFER_ATTACHMENT_DEPTH_SIZE"/>
+ <enum value="0x8217" name="GL_FRAMEBUFFER_ATTACHMENT_STENCIL_SIZE"/>
+ <enum value="0x8218" name="GL_FRAMEBUFFER_DEFAULT"/>
+ <enum value="0x8219" name="GL_FRAMEBUFFER_UNDEFINED"/>
+ <enum value="0x8219" name="GL_FRAMEBUFFER_UNDEFINED_OES"/>
+ <enum value="0x821A" name="GL_DEPTH_STENCIL_ATTACHMENT"/>
+ <enum value="0x821B" name="GL_MAJOR_VERSION"/>
+ <enum value="0x821C" name="GL_MINOR_VERSION"/>
+ <enum value="0x821D" name="GL_NUM_EXTENSIONS"/>
+ <enum value="0x821E" name="GL_CONTEXT_FLAGS"/>
+ <enum value="0x821F" name="GL_BUFFER_IMMUTABLE_STORAGE"/>
+ <enum value="0x8220" name="GL_BUFFER_STORAGE_FLAGS"/>
+ <enum value="0x8221" name="GL_PRIMITIVE_RESTART_FOR_PATCHES_SUPPORTED" comment="Proposed for Bug 10364"/>
+ <enum value="0x8222" name="GL_INDEX"/>
+ <unused start="0x8223" vendor="ARB" comment="GL_DEPTH_BUFFER = 0x8223 not actually used in the API"/>
+ <unused start="0x8224" vendor="ARB" comment="GL_STENCIL_BUFFER = 0x8224 not actually used in the API"/>
+ <enum value="0x8225" name="GL_COMPRESSED_RED"/>
+ <enum value="0x8226" name="GL_COMPRESSED_RG"/>
+ <enum value="0x8227" name="GL_RG"/>
+ <enum value="0x8227" name="GL_RG_EXT"/>
+ <enum value="0x8228" name="GL_RG_INTEGER"/>
+ <enum value="0x8229" name="GL_R8"/>
+ <enum value="0x8229" name="GL_R8_EXT"/>
+ <enum value="0x822A" name="GL_R16"/>
+ <enum value="0x822B" name="GL_RG8"/>
+ <enum value="0x822B" name="GL_RG8_EXT"/>
+ <enum value="0x822C" name="GL_RG16"/>
+ <enum value="0x822D" name="GL_R16F"/>
+ <enum value="0x822D" name="GL_R16F_EXT"/>
+ <enum value="0x822E" name="GL_R32F"/>
+ <enum value="0x822E" name="GL_R32F_EXT"/>
+ <enum value="0x822F" name="GL_RG16F"/>
+ <enum value="0x822F" name="GL_RG16F_EXT"/>
+ <enum value="0x8230" name="GL_RG32F"/>
+ <enum value="0x8230" name="GL_RG32F_EXT"/>
+ <enum value="0x8231" name="GL_R8I"/>
+ <enum value="0x8232" name="GL_R8UI"/>
+ <enum value="0x8233" name="GL_R16I"/>
+ <enum value="0x8234" name="GL_R16UI"/>
+ <enum value="0x8235" name="GL_R32I"/>
+ <enum value="0x8236" name="GL_R32UI"/>
+ <enum value="0x8237" name="GL_RG8I"/>
+ <enum value="0x8238" name="GL_RG8UI"/>
+ <enum value="0x8239" name="GL_RG16I"/>
+ <enum value="0x823A" name="GL_RG16UI"/>
+ <enum value="0x823B" name="GL_RG32I"/>
+ <enum value="0x823C" name="GL_RG32UI"/>
+ <unused start="0x823D" end="0x823F" vendor="ARB"/>
+ </enums>
+
+ <enums namespace="GL" start="0x8240" end="0x82AF" vendor="ARB" comment="Range released by MS on 2002/9/16">
+ <enum value="0x8240" name="GL_SYNC_CL_EVENT_ARB"/>
+ <enum value="0x8241" name="GL_SYNC_CL_EVENT_COMPLETE_ARB"/>
+ <enum value="0x8242" name="GL_DEBUG_OUTPUT_SYNCHRONOUS"/>
+ <enum value="0x8242" name="GL_DEBUG_OUTPUT_SYNCHRONOUS_ARB"/>
+ <enum value="0x8242" name="GL_DEBUG_OUTPUT_SYNCHRONOUS_KHR"/>
+ <enum value="0x8243" name="GL_DEBUG_NEXT_LOGGED_MESSAGE_LENGTH"/>
+ <enum value="0x8243" name="GL_DEBUG_NEXT_LOGGED_MESSAGE_LENGTH_ARB"/>
+ <enum value="0x8243" name="GL_DEBUG_NEXT_LOGGED_MESSAGE_LENGTH_KHR"/>
+ <enum value="0x8244" name="GL_DEBUG_CALLBACK_FUNCTION"/>
+ <enum value="0x8244" name="GL_DEBUG_CALLBACK_FUNCTION_ARB"/>
+ <enum value="0x8244" name="GL_DEBUG_CALLBACK_FUNCTION_KHR"/>
+ <enum value="0x8245" name="GL_DEBUG_CALLBACK_USER_PARAM"/>
+ <enum value="0x8245" name="GL_DEBUG_CALLBACK_USER_PARAM_ARB"/>
+ <enum value="0x8245" name="GL_DEBUG_CALLBACK_USER_PARAM_KHR"/>
+ <enum value="0x8246" name="GL_DEBUG_SOURCE_API"/>
+ <enum value="0x8246" name="GL_DEBUG_SOURCE_API_ARB"/>
+ <enum value="0x8246" name="GL_DEBUG_SOURCE_API_KHR"/>
+ <enum value="0x8247" name="GL_DEBUG_SOURCE_WINDOW_SYSTEM"/>
+ <enum value="0x8247" name="GL_DEBUG_SOURCE_WINDOW_SYSTEM_ARB"/>
+ <enum value="0x8247" name="GL_DEBUG_SOURCE_WINDOW_SYSTEM_KHR"/>
+ <enum value="0x8248" name="GL_DEBUG_SOURCE_SHADER_COMPILER"/>
+ <enum value="0x8248" name="GL_DEBUG_SOURCE_SHADER_COMPILER_ARB"/>
+ <enum value="0x8248" name="GL_DEBUG_SOURCE_SHADER_COMPILER_KHR"/>
+ <enum value="0x8249" name="GL_DEBUG_SOURCE_THIRD_PARTY"/>
+ <enum value="0x8249" name="GL_DEBUG_SOURCE_THIRD_PARTY_ARB"/>
+ <enum value="0x8249" name="GL_DEBUG_SOURCE_THIRD_PARTY_KHR"/>
+ <enum value="0x824A" name="GL_DEBUG_SOURCE_APPLICATION"/>
+ <enum value="0x824A" name="GL_DEBUG_SOURCE_APPLICATION_ARB"/>
+ <enum value="0x824A" name="GL_DEBUG_SOURCE_APPLICATION_KHR"/>
+ <enum value="0x824B" name="GL_DEBUG_SOURCE_OTHER"/>
+ <enum value="0x824B" name="GL_DEBUG_SOURCE_OTHER_ARB"/>
+ <enum value="0x824B" name="GL_DEBUG_SOURCE_OTHER_KHR"/>
+ <enum value="0x824C" name="GL_DEBUG_TYPE_ERROR"/>
+ <enum value="0x824C" name="GL_DEBUG_TYPE_ERROR_ARB"/>
+ <enum value="0x824C" name="GL_DEBUG_TYPE_ERROR_KHR"/>
+ <enum value="0x824D" name="GL_DEBUG_TYPE_DEPRECATED_BEHAVIOR"/>
+ <enum value="0x824D" name="GL_DEBUG_TYPE_DEPRECATED_BEHAVIOR_ARB"/>
+ <enum value="0x824D" name="GL_DEBUG_TYPE_DEPRECATED_BEHAVIOR_KHR"/>
+ <enum value="0x824E" name="GL_DEBUG_TYPE_UNDEFINED_BEHAVIOR"/>
+ <enum value="0x824E" name="GL_DEBUG_TYPE_UNDEFINED_BEHAVIOR_ARB"/>
+ <enum value="0x824E" name="GL_DEBUG_TYPE_UNDEFINED_BEHAVIOR_KHR"/>
+ <enum value="0x824F" name="GL_DEBUG_TYPE_PORTABILITY"/>
+ <enum value="0x824F" name="GL_DEBUG_TYPE_PORTABILITY_ARB"/>
+ <enum value="0x824F" name="GL_DEBUG_TYPE_PORTABILITY_KHR"/>
+ <enum value="0x8250" name="GL_DEBUG_TYPE_PERFORMANCE"/>
+ <enum value="0x8250" name="GL_DEBUG_TYPE_PERFORMANCE_ARB"/>
+ <enum value="0x8250" name="GL_DEBUG_TYPE_PERFORMANCE_KHR"/>
+ <enum value="0x8251" name="GL_DEBUG_TYPE_OTHER"/>
+ <enum value="0x8251" name="GL_DEBUG_TYPE_OTHER_ARB"/>
+ <enum value="0x8251" name="GL_DEBUG_TYPE_OTHER_KHR"/>
+ <enum value="0x8252" name="GL_LOSE_CONTEXT_ON_RESET"/>
+ <enum value="0x8252" name="GL_LOSE_CONTEXT_ON_RESET_ARB"/>
+ <enum value="0x8252" name="GL_LOSE_CONTEXT_ON_RESET_EXT"/>
+ <enum value="0x8252" name="GL_LOSE_CONTEXT_ON_RESET_KHR"/>
+ <enum value="0x8253" name="GL_GUILTY_CONTEXT_RESET"/>
+ <enum value="0x8253" name="GL_GUILTY_CONTEXT_RESET_ARB"/>
+ <enum value="0x8253" name="GL_GUILTY_CONTEXT_RESET_EXT"/>
+ <enum value="0x8253" name="GL_GUILTY_CONTEXT_RESET_KHR"/>
+ <enum value="0x8254" name="GL_INNOCENT_CONTEXT_RESET"/>
+ <enum value="0x8254" name="GL_INNOCENT_CONTEXT_RESET_ARB"/>
+ <enum value="0x8254" name="GL_INNOCENT_CONTEXT_RESET_EXT"/>
+ <enum value="0x8254" name="GL_INNOCENT_CONTEXT_RESET_KHR"/>
+ <enum value="0x8255" name="GL_UNKNOWN_CONTEXT_RESET"/>
+ <enum value="0x8255" name="GL_UNKNOWN_CONTEXT_RESET_ARB"/>
+ <enum value="0x8255" name="GL_UNKNOWN_CONTEXT_RESET_EXT"/>
+ <enum value="0x8255" name="GL_UNKNOWN_CONTEXT_RESET_KHR"/>
+ <enum value="0x8256" name="GL_RESET_NOTIFICATION_STRATEGY"/>
+ <enum value="0x8256" name="GL_RESET_NOTIFICATION_STRATEGY_ARB"/>
+ <enum value="0x8256" name="GL_RESET_NOTIFICATION_STRATEGY_EXT"/>
+ <enum value="0x8256" name="GL_RESET_NOTIFICATION_STRATEGY_KHR"/>
+ <enum value="0x8257" name="GL_PROGRAM_BINARY_RETRIEVABLE_HINT"/>
+ <enum value="0x8258" name="GL_PROGRAM_SEPARABLE"/>
+ <enum value="0x8258" name="GL_PROGRAM_SEPARABLE_EXT"/>
+ <enum value="0x8259" name="GL_ACTIVE_PROGRAM"/>
+ <enum value="0x8259" api="gles2" name="GL_ACTIVE_PROGRAM_EXT" comment="For the OpenGL ES version of EXT_separate_shader_objects"/>
+ <enum value="0x825A" name="GL_PROGRAM_PIPELINE_BINDING"/>
+ <enum value="0x825A" name="GL_PROGRAM_PIPELINE_BINDING_EXT"/>
+ <enum value="0x825B" name="GL_MAX_VIEWPORTS"/>
+ <enum value="0x825C" name="GL_VIEWPORT_SUBPIXEL_BITS"/>
+ <enum value="0x825D" name="GL_VIEWPORT_BOUNDS_RANGE"/>
+ <enum value="0x825E" name="GL_LAYER_PROVOKING_VERTEX"/>
+ <enum value="0x825E" name="GL_LAYER_PROVOKING_VERTEX_EXT"/>
+ <enum value="0x825F" name="GL_VIEWPORT_INDEX_PROVOKING_VERTEX"/>
+ <enum value="0x8260" name="GL_UNDEFINED_VERTEX"/>
+ <enum value="0x8260" name="GL_UNDEFINED_VERTEX_EXT"/>
+ <enum value="0x8261" name="GL_NO_RESET_NOTIFICATION"/>
+ <enum value="0x8261" name="GL_NO_RESET_NOTIFICATION_ARB"/>
+ <enum value="0x8261" name="GL_NO_RESET_NOTIFICATION_EXT"/>
+ <enum value="0x8261" name="GL_NO_RESET_NOTIFICATION_KHR"/>
+ <enum value="0x8262" name="GL_MAX_COMPUTE_SHARED_MEMORY_SIZE"/>
+ <enum value="0x8263" name="GL_MAX_COMPUTE_UNIFORM_COMPONENTS"/>
+ <enum value="0x8264" name="GL_MAX_COMPUTE_ATOMIC_COUNTER_BUFFERS"/>
+ <enum value="0x8265" name="GL_MAX_COMPUTE_ATOMIC_COUNTERS"/>
+ <enum value="0x8266" name="GL_MAX_COMBINED_COMPUTE_UNIFORM_COMPONENTS"/>
+ <enum value="0x8267" name="GL_COMPUTE_WORK_GROUP_SIZE"/>
+ <enum value="0x8268" name="GL_DEBUG_TYPE_MARKER"/>
+ <enum value="0x8268" name="GL_DEBUG_TYPE_MARKER_KHR"/>
+ <enum value="0x8269" name="GL_DEBUG_TYPE_PUSH_GROUP"/>
+ <enum value="0x8269" name="GL_DEBUG_TYPE_PUSH_GROUP_KHR"/>
+ <enum value="0x826A" name="GL_DEBUG_TYPE_POP_GROUP"/>
+ <enum value="0x826A" name="GL_DEBUG_TYPE_POP_GROUP_KHR"/>
+ <enum value="0x826B" name="GL_DEBUG_SEVERITY_NOTIFICATION"/>
+ <enum value="0x826B" name="GL_DEBUG_SEVERITY_NOTIFICATION_KHR"/>
+ <enum value="0x826C" name="GL_MAX_DEBUG_GROUP_STACK_DEPTH"/>
+ <enum value="0x826C" name="GL_MAX_DEBUG_GROUP_STACK_DEPTH_KHR"/>
+ <enum value="0x826D" name="GL_DEBUG_GROUP_STACK_DEPTH"/>
+ <enum value="0x826D" name="GL_DEBUG_GROUP_STACK_DEPTH_KHR"/>
+ <enum value="0x826E" name="GL_MAX_UNIFORM_LOCATIONS"/>
+ <enum value="0x826F" name="GL_INTERNALFORMAT_SUPPORTED"/>
+ <enum value="0x8270" name="GL_INTERNALFORMAT_PREFERRED"/>
+ <enum value="0x8271" name="GL_INTERNALFORMAT_RED_SIZE"/>
+ <enum value="0x8272" name="GL_INTERNALFORMAT_GREEN_SIZE"/>
+ <enum value="0x8273" name="GL_INTERNALFORMAT_BLUE_SIZE"/>
+ <enum value="0x8274" name="GL_INTERNALFORMAT_ALPHA_SIZE"/>
+ <enum value="0x8275" name="GL_INTERNALFORMAT_DEPTH_SIZE"/>
+ <enum value="0x8276" name="GL_INTERNALFORMAT_STENCIL_SIZE"/>
+ <enum value="0x8277" name="GL_INTERNALFORMAT_SHARED_SIZE"/>
+ <enum value="0x8278" name="GL_INTERNALFORMAT_RED_TYPE"/>
+ <enum value="0x8279" name="GL_INTERNALFORMAT_GREEN_TYPE"/>
+ <enum value="0x827A" name="GL_INTERNALFORMAT_BLUE_TYPE"/>
+ <enum value="0x827B" name="GL_INTERNALFORMAT_ALPHA_TYPE"/>
+ <enum value="0x827C" name="GL_INTERNALFORMAT_DEPTH_TYPE"/>
+ <enum value="0x827D" name="GL_INTERNALFORMAT_STENCIL_TYPE"/>
+ <enum value="0x827E" name="GL_MAX_WIDTH"/>
+ <enum value="0x827F" name="GL_MAX_HEIGHT"/>
+ <enum value="0x8280" name="GL_MAX_DEPTH"/>
+ <enum value="0x8281" name="GL_MAX_LAYERS"/>
+ <enum value="0x8282" name="GL_MAX_COMBINED_DIMENSIONS"/>
+ <enum value="0x8283" name="GL_COLOR_COMPONENTS"/>
+ <enum value="0x8284" name="GL_DEPTH_COMPONENTS"/>
+ <enum value="0x8285" name="GL_STENCIL_COMPONENTS"/>
+ <enum value="0x8286" name="GL_COLOR_RENDERABLE"/>
+ <enum value="0x8287" name="GL_DEPTH_RENDERABLE"/>
+ <enum value="0x8288" name="GL_STENCIL_RENDERABLE"/>
+ <enum value="0x8289" name="GL_FRAMEBUFFER_RENDERABLE"/>
+ <enum value="0x828A" name="GL_FRAMEBUFFER_RENDERABLE_LAYERED"/>
+ <enum value="0x828B" name="GL_FRAMEBUFFER_BLEND"/>
+ <enum value="0x828C" name="GL_READ_PIXELS"/>
+ <enum value="0x828D" name="GL_READ_PIXELS_FORMAT"/>
+ <enum value="0x828E" name="GL_READ_PIXELS_TYPE"/>
+ <enum value="0x828F" name="GL_TEXTURE_IMAGE_FORMAT"/>
+ <enum value="0x8290" name="GL_TEXTURE_IMAGE_TYPE"/>
+ <enum value="0x8291" name="GL_GET_TEXTURE_IMAGE_FORMAT"/>
+ <enum value="0x8292" name="GL_GET_TEXTURE_IMAGE_TYPE"/>
+ <enum value="0x8293" name="GL_MIPMAP"/>
+ <enum value="0x8294" name="GL_MANUAL_GENERATE_MIPMAP"/>
+ <enum value="0x8295" name="GL_AUTO_GENERATE_MIPMAP" comment="Should be deprecated"/>
+ <enum value="0x8296" name="GL_COLOR_ENCODING"/>
+ <enum value="0x8297" name="GL_SRGB_READ"/>
+ <enum value="0x8298" name="GL_SRGB_WRITE"/>
+ <enum value="0x8299" name="GL_SRGB_DECODE_ARB"/>
+ <enum value="0x829A" name="GL_FILTER"/>
+ <enum value="0x829B" name="GL_VERTEX_TEXTURE"/>
+ <enum value="0x829C" name="GL_TESS_CONTROL_TEXTURE"/>
+ <enum value="0x829D" name="GL_TESS_EVALUATION_TEXTURE"/>
+ <enum value="0x829E" name="GL_GEOMETRY_TEXTURE"/>
+ <enum value="0x829F" name="GL_FRAGMENT_TEXTURE"/>
+ <enum value="0x82A0" name="GL_COMPUTE_TEXTURE"/>
+ <enum value="0x82A1" name="GL_TEXTURE_SHADOW"/>
+ <enum value="0x82A2" name="GL_TEXTURE_GATHER"/>
+ <enum value="0x82A3" name="GL_TEXTURE_GATHER_SHADOW"/>
+ <enum value="0x82A4" name="GL_SHADER_IMAGE_LOAD"/>
+ <enum value="0x82A5" name="GL_SHADER_IMAGE_STORE"/>
+ <enum value="0x82A6" name="GL_SHADER_IMAGE_ATOMIC"/>
+ <enum value="0x82A7" name="GL_IMAGE_TEXEL_SIZE"/>
+ <enum value="0x82A8" name="GL_IMAGE_COMPATIBILITY_CLASS"/>
+ <enum value="0x82A9" name="GL_IMAGE_PIXEL_FORMAT"/>
+ <enum value="0x82AA" name="GL_IMAGE_PIXEL_TYPE"/>
+ <unused start="0x82AB" vendor="ARB"/>
+ <enum value="0x82AC" name="GL_SIMULTANEOUS_TEXTURE_AND_DEPTH_TEST"/>
+ <enum value="0x82AD" name="GL_SIMULTANEOUS_TEXTURE_AND_STENCIL_TEST"/>
+ <enum value="0x82AE" name="GL_SIMULTANEOUS_TEXTURE_AND_DEPTH_WRITE"/>
+ <enum value="0x82AF" name="GL_SIMULTANEOUS_TEXTURE_AND_STENCIL_WRITE"/>
+ </enums>
+
+ <enums namespace="GL" start="0x82B0" end="0x830F" vendor="ARB" comment="Range reclaimed from ADD on 2012/05/10">
+ <unused start="0x82B0" vendor="ARB"/>
+ <enum value="0x82B1" name="GL_TEXTURE_COMPRESSED_BLOCK_WIDTH"/>
+ <enum value="0x82B2" name="GL_TEXTURE_COMPRESSED_BLOCK_HEIGHT"/>
+ <enum value="0x82B3" name="GL_TEXTURE_COMPRESSED_BLOCK_SIZE"/>
+ <enum value="0x82B4" name="GL_CLEAR_BUFFER"/>
+ <enum value="0x82B5" name="GL_TEXTURE_VIEW"/>
+ <enum value="0x82B6" name="GL_VIEW_COMPATIBILITY_CLASS"/>
+ <enum value="0x82B7" name="GL_FULL_SUPPORT"/>
+ <enum value="0x82B8" name="GL_CAVEAT_SUPPORT"/>
+ <enum value="0x82B9" name="GL_IMAGE_CLASS_4_X_32"/>
+ <enum value="0x82BA" name="GL_IMAGE_CLASS_2_X_32"/>
+ <enum value="0x82BB" name="GL_IMAGE_CLASS_1_X_32"/>
+ <enum value="0x82BC" name="GL_IMAGE_CLASS_4_X_16"/>
+ <enum value="0x82BD" name="GL_IMAGE_CLASS_2_X_16"/>
+ <enum value="0x82BE" name="GL_IMAGE_CLASS_1_X_16"/>
+ <enum value="0x82BF" name="GL_IMAGE_CLASS_4_X_8"/>
+ <enum value="0x82C0" name="GL_IMAGE_CLASS_2_X_8"/>
+ <enum value="0x82C1" name="GL_IMAGE_CLASS_1_X_8"/>
+ <enum value="0x82C2" name="GL_IMAGE_CLASS_11_11_10"/>
+ <enum value="0x82C3" name="GL_IMAGE_CLASS_10_10_10_2"/>
+ <enum value="0x82C4" name="GL_VIEW_CLASS_128_BITS"/>
+ <enum value="0x82C5" name="GL_VIEW_CLASS_96_BITS"/>
+ <enum value="0x82C6" name="GL_VIEW_CLASS_64_BITS"/>
+ <enum value="0x82C7" name="GL_VIEW_CLASS_48_BITS"/>
+ <enum value="0x82C8" name="GL_VIEW_CLASS_32_BITS"/>
+ <enum value="0x82C9" name="GL_VIEW_CLASS_24_BITS"/>
+ <enum value="0x82CA" name="GL_VIEW_CLASS_16_BITS"/>
+ <enum value="0x82CB" name="GL_VIEW_CLASS_8_BITS"/>
+ <enum value="0x82CC" name="GL_VIEW_CLASS_S3TC_DXT1_RGB"/>
+ <enum value="0x82CD" name="GL_VIEW_CLASS_S3TC_DXT1_RGBA"/>
+ <enum value="0x82CE" name="GL_VIEW_CLASS_S3TC_DXT3_RGBA"/>
+ <enum value="0x82CF" name="GL_VIEW_CLASS_S3TC_DXT5_RGBA"/>
+ <enum value="0x82D0" name="GL_VIEW_CLASS_RGTC1_RED"/>
+ <enum value="0x82D1" name="GL_VIEW_CLASS_RGTC2_RG"/>
+ <enum value="0x82D2" name="GL_VIEW_CLASS_BPTC_UNORM"/>
+ <enum value="0x82D3" name="GL_VIEW_CLASS_BPTC_FLOAT"/>
+ <enum value="0x82D4" name="GL_VERTEX_ATTRIB_BINDING"/>
+ <enum value="0x82D5" name="GL_VERTEX_ATTRIB_RELATIVE_OFFSET"/>
+ <enum value="0x82D6" name="GL_VERTEX_BINDING_DIVISOR"/>
+ <enum value="0x82D7" name="GL_VERTEX_BINDING_OFFSET"/>
+ <enum value="0x82D8" name="GL_VERTEX_BINDING_STRIDE"/>
+ <enum value="0x82D9" name="GL_MAX_VERTEX_ATTRIB_RELATIVE_OFFSET"/>
+ <enum value="0x82DA" name="GL_MAX_VERTEX_ATTRIB_BINDINGS"/>
+ <enum value="0x82DB" name="GL_TEXTURE_VIEW_MIN_LEVEL"/>
+ <enum value="0x82DB" name="GL_TEXTURE_VIEW_MIN_LEVEL_EXT"/>
+ <enum value="0x82DC" name="GL_TEXTURE_VIEW_NUM_LEVELS"/>
+ <enum value="0x82DC" name="GL_TEXTURE_VIEW_NUM_LEVELS_EXT"/>
+ <enum value="0x82DD" name="GL_TEXTURE_VIEW_MIN_LAYER"/>
+ <enum value="0x82DD" name="GL_TEXTURE_VIEW_MIN_LAYER_EXT"/>
+ <enum value="0x82DE" name="GL_TEXTURE_VIEW_NUM_LAYERS"/>
+ <enum value="0x82DE" name="GL_TEXTURE_VIEW_NUM_LAYERS_EXT"/>
+ <enum value="0x82DF" name="GL_TEXTURE_IMMUTABLE_LEVELS"/>
+ <enum value="0x82E0" name="GL_BUFFER"/>
+ <enum value="0x82E0" name="GL_BUFFER_KHR"/>
+ <enum value="0x82E1" name="GL_SHADER"/>
+ <enum value="0x82E1" name="GL_SHADER_KHR"/>
+ <enum value="0x82E2" name="GL_PROGRAM"/>
+ <enum value="0x82E2" name="GL_PROGRAM_KHR"/>
+ <enum value="0x82E3" name="GL_QUERY"/>
+ <enum value="0x82E3" name="GL_QUERY_KHR"/>
+ <enum value="0x82E4" name="GL_PROGRAM_PIPELINE"/>
+ <enum value="0x82E5" name="GL_MAX_VERTEX_ATTRIB_STRIDE"/>
+ <enum value="0x82E6" name="GL_SAMPLER"/>
+ <enum value="0x82E6" name="GL_SAMPLER_KHR"/>
+ <enum value="0x82E7" name="GL_DISPLAY_LIST"/>
+ <enum value="0x82E8" name="GL_MAX_LABEL_LENGTH"/>
+ <enum value="0x82E8" name="GL_MAX_LABEL_LENGTH_KHR"/>
+ <enum value="0x82E9" name="GL_NUM_SHADING_LANGUAGE_VERSIONS"/>
+ <enum value="0x82EA" name="GL_QUERY_TARGET"/>
+ <enum value="0x82EB" name="GL_TEXTURE_BINDING"/>
+ <enum value="0x82EC" name="GL_TRANSFORM_FEEDBACK_OVERFLOW_ARB"/>
+ <enum value="0x82ED" name="GL_TRANSFORM_FEEDBACK_STREAM_OVERFLOW_ARB"/>
+ <enum value="0x82EE" name="GL_VERTICES_SUBMITTED_ARB"/>
+ <enum value="0x82EF" name="GL_PRIMITIVES_SUBMITTED_ARB"/>
+ <enum value="0x82F0" name="GL_VERTEX_SHADER_INVOCATIONS_ARB"/>
+ <enum value="0x82F1" name="GL_TESS_CONTROL_SHADER_PATCHES_ARB"/>
+ <enum value="0x82F2" name="GL_TESS_EVALUATION_SHADER_INVOCATIONS_ARB"/>
+ <enum value="0x82F3" name="GL_GEOMETRY_SHADER_PRIMITIVES_EMITTED_ARB"/>
+ <enum value="0x82F4" name="GL_FRAGMENT_SHADER_INVOCATIONS_ARB"/>
+ <enum value="0x82F5" name="GL_COMPUTE_SHADER_INVOCATIONS_ARB"/>
+ <enum value="0x82F6" name="GL_CLIPPING_INPUT_PRIMITIVES_ARB"/>
+ <enum value="0x82F7" name="GL_CLIPPING_OUTPUT_PRIMITIVES_ARB"/>
+ <enum value="0x82F8" name="GL_SPARSE_BUFFER_PAGE_SIZE_ARB"/>
+ <enum value="0x82F9" name="GL_MAX_CULL_DISTANCES"/>
+ <enum value="0x82FA" name="GL_MAX_COMBINED_CLIP_AND_CULL_DISTANCES"/>
+ <enum value="0x82FB" name="GL_CONTEXT_RELEASE_BEHAVIOR"/>
+ <enum value="0x82FB" name="GL_CONTEXT_RELEASE_BEHAVIOR_KHR"/>
+ <enum value="0x82FC" name="GL_CONTEXT_RELEASE_BEHAVIOR_FLUSH"/>
+ <enum value="0x82FC" name="GL_CONTEXT_RELEASE_BEHAVIOR_FLUSH_KHR"/>
+ <unused start="0x82FD" end="0x830F" vendor="ARB"/>
+ </enums>
+
+ <enums namespace="GL" start="0x8310" end="0x832F" vendor="SGI">
+ <enum value="0x8310" name="GL_DEPTH_PASS_INSTRUMENT_SGIX"/>
+ <enum value="0x8311" name="GL_DEPTH_PASS_INSTRUMENT_COUNTERS_SGIX"/>
+ <enum value="0x8312" name="GL_DEPTH_PASS_INSTRUMENT_MAX_SGIX"/>
+ <enum value="0x8313" name="GL_FRAGMENTS_INSTRUMENT_SGIX"/>
+ <enum value="0x8314" name="GL_FRAGMENTS_INSTRUMENT_COUNTERS_SGIX"/>
+ <enum value="0x8315" name="GL_FRAGMENTS_INSTRUMENT_MAX_SGIX"/>
+ <enum value="0x8316" name="GL_CONVOLUTION_HINT_SGIX"/>
+ <unused start="0x8317" comment="Incomplete extension SGIX_color_matrix_accuracy"/>
+ <!-- <enum value="0x8317" name="GL_COLOR_MATRIX_HINT"/> -->
+ <enum value="0x8318" name="GL_YCRCB_SGIX"/>
+ <enum value="0x8319" name="GL_YCRCBA_SGIX"/>
+ <enum value="0x831A" name="GL_UNPACK_COMPRESSED_SIZE_SGIX"/>
+ <enum value="0x831B" name="GL_PACK_MAX_COMPRESSED_SIZE_SGIX"/>
+ <enum value="0x831C" name="GL_PACK_COMPRESSED_SIZE_SGIX"/>
+ <enum value="0x831D" name="GL_SLIM8U_SGIX"/>
+ <enum value="0x831E" name="GL_SLIM10U_SGIX"/>
+ <enum value="0x831F" name="GL_SLIM12S_SGIX"/>
+ <enum value="0x8320" name="GL_ALPHA_MIN_SGIX"/>
+ <enum value="0x8321" name="GL_ALPHA_MAX_SGIX"/>
+ <enum value="0x8322" name="GL_SCALEBIAS_HINT_SGIX"/>
+ <unused start="0x8323" end="0x8328" comment="Incomplete extension SGIX_fog_layers"/>
+ <!-- <enum value="0x8323" name="GL_FOG_TYPE_SGIX"/> -->
+ <!-- <enum value="0x8324" name="GL_UNIFORM_SGIX"/> -->
+ <!-- <enum value="0x8325" name="GL_LAYERED_SGIX"/> -->
+ <!-- <enum value="0x8326" name="GL_FOG_GROUND_PLANE_SGIX"/> -->
+ <!-- <enum value="0x8327" name="GL_FOG_LAYERS_POINTS_SGIX"/> -->
+ <!-- <enum value="0x8328" name="GL_MAX_FOG_LAYERS_POINTS_SGIX"/> -->
+ <enum value="0x8329" name="GL_ASYNC_MARKER_SGIX"/>
+ <unused start="0x832A" comment="Incomplete extension SGIX_texture_phase"/>
+ <!-- <enum value="0x832A" name="GL_PHASE_SGIX"/> -->
+ <enum value="0x832B" name="GL_PIXEL_TEX_GEN_MODE_SGIX"/>
+ <enum value="0x832C" name="GL_ASYNC_HISTOGRAM_SGIX"/>
+ <enum value="0x832D" name="GL_MAX_ASYNC_HISTOGRAM_SGIX"/>
+ <unused start="0x832E" end="0x832F" comment="Incomplete extension SGIX_texture_mipmap_anisotropic"/>
+ <!-- <enum value="0x832E" name="GL_TEXTURE_MIPMAP_ANISOTROPY_SGIX"/> -->
+ <!-- <enum value="0x832F" name="GL_MAX_MIPMAP_ANISOTROPY_SGIX"/> -->
+ </enums>
+
+ <enums namespace="GL" start="0x8330" end="0x833F" vendor="SUN">
+ <enum value="0x8330" name="GL_PIXEL_TRANSFORM_2D_EXT"/>
+ <enum value="0x8331" name="GL_PIXEL_MAG_FILTER_EXT"/>
+ <enum value="0x8332" name="GL_PIXEL_MIN_FILTER_EXT"/>
+ <enum value="0x8333" name="GL_PIXEL_CUBIC_WEIGHT_EXT"/>
+ <enum value="0x8334" name="GL_CUBIC_EXT"/>
+ <enum value="0x8335" name="GL_AVERAGE_EXT"/>
+ <enum value="0x8336" name="GL_PIXEL_TRANSFORM_2D_STACK_DEPTH_EXT"/>
+ <enum value="0x8337" name="GL_MAX_PIXEL_TRANSFORM_2D_STACK_DEPTH_EXT"/>
+ <enum value="0x8338" name="GL_PIXEL_TRANSFORM_2D_MATRIX_EXT"/>
+ <unused start="0x8339" end="0x833F" vendor="SUN"/>
+ </enums>
+
+ <enums namespace="GL" start="0x8340" end="0x836F" vendor="SGI">
+ <unused start="0x8340" end="0x8348" comment="Incomplete extension SGIX_cube_map"/>
+ <!-- <enum value="0x8340" name="GL_ENV_MAP_SGIX"/> -->
+ <!-- <enum value="0x8341" name="GL_CUBE_MAP_SGIX"/> -->
+ <!-- <enum value="0x8342" name="GL_CUBE_MAP_ZP_SGIX"/> -->
+ <!-- <enum value="0x8343" name="GL_CUBE_MAP_ZN_SGIX"/> -->
+ <!-- <enum value="0x8344" name="GL_CUBE_MAP_XN_SGIX"/> -->
+ <!-- <enum value="0x8345" name="GL_CUBE_MAP_XP_SGIX"/> -->
+ <!-- <enum value="0x8346" name="GL_CUBE_MAP_YN_SGIX"/> -->
+ <!-- <enum value="0x8347" name="GL_CUBE_MAP_YP_SGIX"/> -->
+ <!-- <enum value="0x8348" name="GL_CUBE_MAP_BINDING_SGIX"/> -->
+ <enum value="0x8349" name="GL_FRAGMENT_MATERIAL_EXT"/>
+ <enum value="0x834A" name="GL_FRAGMENT_NORMAL_EXT"/>
+ <!-- Unfortunately, there was a collision promoting to EXT
+ from SGIX. Use fog_coord's value of 0x8452 instead of
+ the old assigned FRAGMENT_DEPTH_EXT (0x834B). -->
+ <enum value="0x834C" name="GL_FRAGMENT_COLOR_EXT"/>
+ <enum value="0x834D" name="GL_ATTENUATION_EXT"/>
+ <enum value="0x834E" name="GL_SHADOW_ATTENUATION_EXT"/>
+ <enum value="0x834F" name="GL_TEXTURE_APPLICATION_MODE_EXT"/>
+ <enum value="0x8350" name="GL_TEXTURE_LIGHT_EXT"/>
+ <enum value="0x8351" name="GL_TEXTURE_MATERIAL_FACE_EXT"/>
+ <enum value="0x8352" name="GL_TEXTURE_MATERIAL_PARAMETER_EXT"/>
+ <enum value="0x8353" name="GL_PIXEL_TEXTURE_SGIS"/>
+ <enum value="0x8354" name="GL_PIXEL_FRAGMENT_RGB_SOURCE_SGIS"/>
+ <enum value="0x8355" name="GL_PIXEL_FRAGMENT_ALPHA_SOURCE_SGIS"/>
+ <enum value="0x8356" name="GL_PIXEL_GROUP_COLOR_SGIS"/>
+ <unused start="0x8357" end="0x8359" comment="Incomplete extension SGIX_pixel_texture_bits"/>
+ <!-- <enum value="0x8357" name="GL_COLOR_TO_TEXTURE_COORD_SGIX"/> -->
+ <!-- <enum value="0x8358" name="GL_COLOR_BIT_PATTERN_SGIX"/> -->
+ <!-- <enum value="0x8359" name="GL_COLOR_VALUE_SGIX"/> -->
+ <unused start="0x835A" comment="Incomplete extension SGIX_pixel_texture_lod"/>
+ <!-- <enum value="0x835A" name="GL_PIXEL_TEX_GEN_LAMBDA_SOURCE_SGIX"/> -->
+ <enum value="0x835B" name="GL_LINE_QUALITY_HINT_SGIX"/>
+ <enum value="0x835C" name="GL_ASYNC_TEX_IMAGE_SGIX"/>
+ <enum value="0x835D" name="GL_ASYNC_DRAW_PIXELS_SGIX"/>
+ <enum value="0x835E" name="GL_ASYNC_READ_PIXELS_SGIX"/>
+ <enum value="0x835F" name="GL_MAX_ASYNC_TEX_IMAGE_SGIX"/>
+ <enum value="0x8360" name="GL_MAX_ASYNC_DRAW_PIXELS_SGIX"/>
+ <enum value="0x8361" name="GL_MAX_ASYNC_READ_PIXELS_SGIX"/>
+ <enum value="0x8362" name="GL_UNSIGNED_BYTE_2_3_3_REV"/>
+ <enum value="0x8362" name="GL_UNSIGNED_BYTE_2_3_3_REV_EXT"/>
+ <enum value="0x8363" name="GL_UNSIGNED_SHORT_5_6_5"/>
+ <enum value="0x8363" name="GL_UNSIGNED_SHORT_5_6_5_EXT"/>
+ <enum value="0x8364" name="GL_UNSIGNED_SHORT_5_6_5_REV"/>
+ <enum value="0x8364" name="GL_UNSIGNED_SHORT_5_6_5_REV_EXT"/>
+ <enum value="0x8365" name="GL_UNSIGNED_SHORT_4_4_4_4_REV"/>
+ <enum value="0x8365" name="GL_UNSIGNED_SHORT_4_4_4_4_REV_EXT"/>
+ <enum value="0x8365" name="GL_UNSIGNED_SHORT_4_4_4_4_REV_IMG"/>
+ <enum value="0x8366" name="GL_UNSIGNED_SHORT_1_5_5_5_REV"/>
+ <enum value="0x8366" name="GL_UNSIGNED_SHORT_1_5_5_5_REV_EXT"/>
+ <enum value="0x8367" name="GL_UNSIGNED_INT_8_8_8_8_REV"/>
+ <enum value="0x8367" name="GL_UNSIGNED_INT_8_8_8_8_REV_EXT"/>
+ <enum value="0x8368" name="GL_UNSIGNED_INT_2_10_10_10_REV"/>
+ <enum value="0x8368" name="GL_UNSIGNED_INT_2_10_10_10_REV_EXT"/>
+ <enum value="0x8369" name="GL_TEXTURE_MAX_CLAMP_S_SGIX"/>
+ <enum value="0x836A" name="GL_TEXTURE_MAX_CLAMP_T_SGIX"/>
+ <enum value="0x836B" name="GL_TEXTURE_MAX_CLAMP_R_SGIX"/>
+ <unused start="0x836C" end="0x836E" comment="Incomplete extension SGIX_fog_texture"/>
+ <!-- <enum value="0x836C" name="GL_FRAGMENT_FOG_SGIX"/> -->
+ <!-- <enum value="0x836D" name="GL_TEXTURE_FOG_SGIX"/> -->
+ <!-- <enum value="0x836E" name="GL_FOG_PATCHY_FACTOR_SGIX"/> -->
+ <unused start="0x836F" comment="Incomplete extension SGIX_fog_factor_to_alpha"/>
+ <!-- <enum value="0x836F" name="GL_FOG_FACTOR_TO_ALPHA_SGIX"/> -->
+ </enums>
+
+ <enums namespace="GL" start="0x8370" end="0x837F" vendor="HP">
+ <!-- NOTE: IBM is using values in this range, because of a
+ bobble when an employee left DEC for IBM at the same
+ time as they were assigned the range. their registry
+ became inconsistent. It's unknown whether HP has any
+ conflicts. They have never reported using any values in
+ this range. Lesson: assigned ranges belong to vendors,
+ not engineers! -->
+ <enum value="0x8370" name="GL_MIRRORED_REPEAT"/>
+ <enum value="0x8370" name="GL_MIRRORED_REPEAT_ARB"/>
+ <enum value="0x8370" name="GL_MIRRORED_REPEAT_IBM"/>
+ <enum value="0x8370" name="GL_MIRRORED_REPEAT_OES"/>
+ <unused start="0x8371" end="0x837F" vendor="HP"/>
+ </enums>
+
+ <enums namespace="GL" start="0x8380" end="0x839F" vendor="IBM">
+ <unused start="0x8380" end="0x839F" vendor="IBM"/>
+ </enums>
+
+ <enums namespace="GL" start="0x83A0" end="0x83BF" vendor="S3">
+ <enum value="0x83A0" name="GL_RGB_S3TC"/>
+ <enum value="0x83A1" name="GL_RGB4_S3TC"/>
+ <enum value="0x83A2" name="GL_RGBA_S3TC"/>
+ <enum value="0x83A3" name="GL_RGBA4_S3TC"/>
+ <enum value="0x83A4" name="GL_RGBA_DXT5_S3TC"/>
+ <enum value="0x83A5" name="GL_RGBA4_DXT5_S3TC"/>
+ <unused start="0x83A6" end="0x83BF" vendor="S3"/>
+ </enums>
+
+ <enums namespace="GL" start="0x83C0" end="0x83EF" vendor="SGI" comment="Most of this could be reclaimed">
+ <unused start="0x83C0" end="0x83CA" comment="Withdrawn extension SGIS_multitexture"/>
+ <!-- <enum value="0x83C0" name="GL_SELECTED_TEXTURE_SGIS"/> -->
+ <!-- <enum value="0x83C1" name="GL_SELECTED_TEXTURE_COORD_SET_SGIS"/> -->
+ <!-- <enum value="0x83C2" name="GL_SELECTED_TEXTURE_TRANSFORM_SGIS"/> -->
+ <!-- <enum value="0x83C3" name="GL_MAX_TEXTURES_SGIS"/> -->
+ <!-- <enum value="0x83C4" name="GL_MAX_TEXTURE_COORD_SETS_SGIS"/> -->
+ <!-- <enum value="0x83C5" name="GL_TEXTURE_COORD_SET_INTERLEAVE_FACTOR_SGIS"/> -->
+ <!-- <enum value="0x83C6" name="GL_TEXTURE_ENV_COORD_SET_SGIS"/> -->
+ <!-- <enum value="0x83C7" name="GL_TEXTURE0_SGIS"/> -->
+ <!-- <enum value="0x83C8" name="GL_TEXTURE1_SGIS"/> -->
+ <!-- <enum value="0x83C9" name="GL_TEXTURE2_SGIS"/> -->
+ <!-- <enum value="0x83CA" name="GL_TEXTURE3_SGIS"/> -->
+ <unused start="0x83CB" end="0x83E5" vendor="SGI"/>
+ <unused start="0x83E6" end="0x83E9" comment="Incomplete extension SGIX_bali_g_instruments"/>
+ <!-- <enum value="0x83E6" name="GL_BALI_NUM_TRIS_CULLED_INSTRUMENT_SGIX"/> -->
+ <!-- <enum value="0x83E7" name="GL_BALI_NUM_PRIMS_CLIPPED_INSTRUMENT_SGIX"/> -->
+ <!-- <enum value="0x83E8" name="GL_BALI_NUM_PRIMS_REJECT_INSTRUMENT_SGIX"/> -->
+ <!-- <enum value="0x83E9" name="GL_BALI_NUM_PRIMS_CLIP_RESULT_INSTRUMENT_SGIX"/> -->
+ <unused start="0x83EA" end="0x83EC" comment="Incomplete extension SGIX_bali_r_instruments"/>
+ <!-- <enum value="0x83EA" name="GL_BALI_FRAGMENTS_GENERATED_INSTRUMENT_SGIX"/> -->
+ <!-- <enum value="0x83EB" name="GL_BALI_DEPTH_PASS_INSTRUMENT_SGIX"/> -->
+ <!-- <enum value="0x83EC" name="GL_BALI_R_CHIP_COUNT_SGIX"/> -->
+ <unused start="0x83ED" comment="Incomplete extension SGIX_occlusion_instrument"/>
+ <!-- <enum value="0x83ED" name="GL_OCCLUSION_INSTRUMENT_SGIX"/> -->
+ <enum value="0x83EE" name="GL_VERTEX_PRECLIP_SGIX"/>
+ <enum value="0x83EF" name="GL_VERTEX_PRECLIP_HINT_SGIX"/>
+ </enums>
+
+ <enums namespace="GL" start="0x83F0" end="0x83FF" vendor="INTEL">
+ <!-- This block was reclaimed from NTP, who never shipped
+ it, and reassigned to Intel. -->
+ <enum value="0x83F0" name="GL_COMPRESSED_RGB_S3TC_DXT1_EXT"/>
+ <enum value="0x83F1" name="GL_COMPRESSED_RGBA_S3TC_DXT1_EXT"/>
+ <enum value="0x83F2" name="GL_COMPRESSED_RGBA_S3TC_DXT3_ANGLE"/>
+ <enum value="0x83F2" name="GL_COMPRESSED_RGBA_S3TC_DXT3_EXT"/>
+ <enum value="0x83F3" name="GL_COMPRESSED_RGBA_S3TC_DXT5_ANGLE"/>
+ <enum value="0x83F3" name="GL_COMPRESSED_RGBA_S3TC_DXT5_EXT"/>
+ <enum value="0x83F4" name="GL_PARALLEL_ARRAYS_INTEL"/>
+ <enum value="0x83F5" name="GL_VERTEX_ARRAY_PARALLEL_POINTERS_INTEL"/>
+ <enum value="0x83F6" name="GL_NORMAL_ARRAY_PARALLEL_POINTERS_INTEL"/>
+ <enum value="0x83F7" name="GL_COLOR_ARRAY_PARALLEL_POINTERS_INTEL"/>
+ <enum value="0x83F8" name="GL_TEXTURE_COORD_ARRAY_PARALLEL_POINTERS_INTEL"/>
+ <enum value="0x83F9" name="GL_PERFQUERY_DONOT_FLUSH_INTEL"/>
+ <enum value="0x83FA" name="GL_PERFQUERY_FLUSH_INTEL"/>
+ <enum value="0x83FB" name="GL_PERFQUERY_WAIT_INTEL"/>
+ <unused start="0x83FC" end="0x83FE" vendor="INTEL"/>
+ <enum value="0x83FF" name="GL_TEXTURE_MEMORY_LAYOUT_INTEL"/>
+ </enums>
+
+ <enums namespace="GL" start="0x8400" end="0x846F" vendor="SGI">
+ <enum value="0x8400" name="GL_FRAGMENT_LIGHTING_SGIX"/>
+ <enum value="0x8401" name="GL_FRAGMENT_COLOR_MATERIAL_SGIX"/>
+ <enum value="0x8402" name="GL_FRAGMENT_COLOR_MATERIAL_FACE_SGIX"/>
+ <enum value="0x8403" name="GL_FRAGMENT_COLOR_MATERIAL_PARAMETER_SGIX"/>
+ <enum value="0x8404" name="GL_MAX_FRAGMENT_LIGHTS_SGIX"/>
+ <enum value="0x8405" name="GL_MAX_ACTIVE_LIGHTS_SGIX"/>
+ <enum value="0x8406" name="GL_CURRENT_RASTER_NORMAL_SGIX"/>
+ <enum value="0x8407" name="GL_LIGHT_ENV_MODE_SGIX"/>
+ <enum value="0x8408" name="GL_FRAGMENT_LIGHT_MODEL_LOCAL_VIEWER_SGIX"/>
+ <enum value="0x8409" name="GL_FRAGMENT_LIGHT_MODEL_TWO_SIDE_SGIX"/>
+ <enum value="0x840A" name="GL_FRAGMENT_LIGHT_MODEL_AMBIENT_SGIX"/>
+ <enum value="0x840B" name="GL_FRAGMENT_LIGHT_MODEL_NORMAL_INTERPOLATION_SGIX"/>
+ <enum value="0x840C" name="GL_FRAGMENT_LIGHT0_SGIX"/>
+ <enum value="0x840D" name="GL_FRAGMENT_LIGHT1_SGIX"/>
+ <enum value="0x840E" name="GL_FRAGMENT_LIGHT2_SGIX"/>
+ <enum value="0x840F" name="GL_FRAGMENT_LIGHT3_SGIX"/>
+ <enum value="0x8410" name="GL_FRAGMENT_LIGHT4_SGIX"/>
+ <enum value="0x8411" name="GL_FRAGMENT_LIGHT5_SGIX"/>
+ <enum value="0x8412" name="GL_FRAGMENT_LIGHT6_SGIX"/>
+ <enum value="0x8413" name="GL_FRAGMENT_LIGHT7_SGIX"/>
+ <unused start="0x8414" end="0x842B" vendor="SGI"/>
+ <enum value="0x842C" name="GL_PACK_RESAMPLE_SGIX"/>
+ <enum value="0x842D" name="GL_UNPACK_RESAMPLE_SGIX"/>
+ <enum value="0x842E" name="GL_RESAMPLE_REPLICATE_SGIX"/>
+ <enum value="0x842F" name="GL_RESAMPLE_ZERO_FILL_SGIX"/>
+ <enum value="0x8430" name="GL_RESAMPLE_DECIMATE_SGIX"/>
+ <unused start="0x8431" end="0x8435" vendor="SGI"/>
+ <!-- Incomplete extension SGIX_fragment_lighting -->
+ <!-- <enum value="0x8436" name="GL_EYE_SPACE_SGIX"/> -->
+ <!-- <enum value="0x8437" name="GL_TANGENT_SPACE_SGIX"/> -->
+ <!-- <enum value="0x8438" name="GL_OBJECT_SPACE_SGIX"/> -->
+ <!-- <enum value="0x8439" name="GL_TANGENT_ARRAY_SGIX"/> -->
+ <!-- <enum value="0x843A" name="GL_BINORMAL_ARRAY_SGIX"/> -->
+ <!-- <enum value="0x843B" name="GL_CURRENT_TANGENT_SGIX"/> -->
+ <!-- <enum value="0x843C" name="GL_CURRENT_BINORMAL_SGIX"/> -->
+ <!-- <enum value="0x843D" name="GL_FRAGMENT_LIGHT_SPACE_SGIX"/> -->
+ <!-- <enum value="0x843E" name="GL_TANGENT_ARRAY_TYPE_SGIX"/> -->
+ <!-- <enum value="0x843F" name="GL_TANGENT_ARRAY_STRIDE_SGIX"/> -->
+ <!-- <enum value="0x8440" name="GL_TANGENT_ARRAY_COUNT_SGIX"/> -->
+ <!-- <enum value="0x8441" name="GL_BINORMAL_ARRAY_TYPE_SGIX"/> -->
+ <!-- <enum value="0x8442" name="GL_BINORMAL_ARRAY_STRIDE_SGIX"/> -->
+ <!-- <enum value="0x8443" name="GL_BINORMAL_ARRAY_COUNT_SGIX"/> -->
+ <!-- <enum value="0x8444" name="GL_TANGENT_ARRAY_POINTER_SGIX"/> -->
+ <!-- <enum value="0x8445" name="GL_BINORMAL_ARRAY_POINTER_SGIX"/> -->
+ <!-- <enum value="0x8446" name="GL_MAP1_TANGENT_SGIX"/> -->
+ <!-- <enum value="0x8447" name="GL_MAP2_TANGENT_SGIX"/> -->
+ <!-- <enum value="0x8448" name="GL_MAP1_BINORMAL_SGIX"/> -->
+ <!-- <enum value="0x8449" name="GL_MAP2_BINORMAL_SGIX"/> -->
+ <enum value="0x8439" name="GL_TANGENT_ARRAY_EXT"/>
+ <enum value="0x843A" name="GL_BINORMAL_ARRAY_EXT"/>
+ <enum value="0x843B" name="GL_CURRENT_TANGENT_EXT"/>
+ <enum value="0x843C" name="GL_CURRENT_BINORMAL_EXT"/>
+ <unused start="0x844D" vendor="SGI"/>
+ <enum value="0x843E" name="GL_TANGENT_ARRAY_TYPE_EXT"/>
+ <enum value="0x843F" name="GL_TANGENT_ARRAY_STRIDE_EXT"/>
+ <enum value="0x8440" name="GL_BINORMAL_ARRAY_TYPE_EXT"/>
+ <enum value="0x8441" name="GL_BINORMAL_ARRAY_STRIDE_EXT"/>
+ <enum value="0x8442" name="GL_TANGENT_ARRAY_POINTER_EXT"/>
+ <enum value="0x8443" name="GL_BINORMAL_ARRAY_POINTER_EXT"/>
+ <enum value="0x8444" name="GL_MAP1_TANGENT_EXT"/>
+ <enum value="0x8445" name="GL_MAP2_TANGENT_EXT"/>
+ <enum value="0x8446" name="GL_MAP1_BINORMAL_EXT"/>
+ <enum value="0x8447" name="GL_MAP2_BINORMAL_EXT"/>
+ <unused start="0x8448" end="0x8449" comment="Incomplete extension SGIX_fragment_lighting"/>
+ <unused start="0x844A" end="0x844C" comment="Incomplete extension SGIX_bali_timer_instruments"/>
+ <!-- <enum value="0x844A" name="GL_BALI_GEOM_TIMER_INSTRUMENT_SGIX"/> -->
+ <!-- <enum value="0x844B" name="GL_BALI_RASTER_TIMER_INSTRUMENT_SGIX"/> -->
+ <!-- <enum value="0x844C" name="GL_BALI_INSTRUMENT_TIME_UNIT_SGIX"/> -->
+ <enum value="0x844D" name="GL_NEAREST_CLIPMAP_NEAREST_SGIX"/>
+ <enum value="0x844E" name="GL_NEAREST_CLIPMAP_LINEAR_SGIX"/>
+ <enum value="0x844F" name="GL_LINEAR_CLIPMAP_NEAREST_SGIX"/>
+ <!-- 0x8450-0x845F range brokered for Id Software -->
+ <enum value="0x8450" name="GL_FOG_COORDINATE_SOURCE"/>
+ <enum value="0x8450" name="GL_FOG_COORDINATE_SOURCE_EXT"/>
+ <enum value="0x8450" name="GL_FOG_COORD_SRC" alias="GL_FOG_COORDINATE_SOURCE"/>
+ <enum value="0x8451" name="GL_FOG_COORDINATE"/>
+ <enum value="0x8451" name="GL_FOG_COORD" alias="GL_FOG_COORDINATE"/>
+ <enum value="0x8451" name="GL_FOG_COORDINATE_EXT"/>
+ <enum value="0x8452" name="GL_FRAGMENT_DEPTH"/>
+ <enum value="0x8452" name="GL_FRAGMENT_DEPTH_EXT"/>
+ <enum value="0x8453" name="GL_CURRENT_FOG_COORDINATE"/>
+ <enum value="0x8453" name="GL_CURRENT_FOG_COORD" alias="GL_CURRENT_FOG_COORDINATE"/>
+ <enum value="0x8453" name="GL_CURRENT_FOG_COORDINATE_EXT"/>
+ <enum value="0x8454" name="GL_FOG_COORDINATE_ARRAY_TYPE"/>
+ <enum value="0x8454" name="GL_FOG_COORDINATE_ARRAY_TYPE_EXT"/>
+ <enum value="0x8454" name="GL_FOG_COORD_ARRAY_TYPE" alias="GL_FOG_COORDINATE_ARRAY_TYPE"/>
+ <enum value="0x8455" name="GL_FOG_COORDINATE_ARRAY_STRIDE"/>
+ <enum value="0x8455" name="GL_FOG_COORDINATE_ARRAY_STRIDE_EXT"/>
+ <enum value="0x8455" name="GL_FOG_COORD_ARRAY_STRIDE" alias="GL_FOG_COORDINATE_ARRAY_STRIDE"/>
+ <enum value="0x8456" name="GL_FOG_COORDINATE_ARRAY_POINTER"/>
+ <enum value="0x8456" name="GL_FOG_COORDINATE_ARRAY_POINTER_EXT"/>
+ <enum value="0x8456" name="GL_FOG_COORD_ARRAY_POINTER" alias="GL_FOG_COORDINATE_ARRAY_POINTER"/>
+ <enum value="0x8457" name="GL_FOG_COORDINATE_ARRAY"/>
+ <enum value="0x8457" name="GL_FOG_COORDINATE_ARRAY_EXT"/>
+ <enum value="0x8457" name="GL_FOG_COORD_ARRAY" alias="GL_FOG_COORDINATE_ARRAY"/>
+ <enum value="0x8458" name="GL_COLOR_SUM"/>
+ <enum value="0x8458" name="GL_COLOR_SUM_ARB"/>
+ <enum value="0x8458" name="GL_COLOR_SUM_EXT"/>
+ <enum value="0x8459" name="GL_CURRENT_SECONDARY_COLOR"/>
+ <enum value="0x8459" name="GL_CURRENT_SECONDARY_COLOR_EXT"/>
+ <enum value="0x845A" name="GL_SECONDARY_COLOR_ARRAY_SIZE"/>
+ <enum value="0x845A" name="GL_SECONDARY_COLOR_ARRAY_SIZE_EXT"/>
+ <enum value="0x845B" name="GL_SECONDARY_COLOR_ARRAY_TYPE"/>
+ <enum value="0x845B" name="GL_SECONDARY_COLOR_ARRAY_TYPE_EXT"/>
+ <enum value="0x845C" name="GL_SECONDARY_COLOR_ARRAY_STRIDE"/>
+ <enum value="0x845C" name="GL_SECONDARY_COLOR_ARRAY_STRIDE_EXT"/>
+ <enum value="0x845D" name="GL_SECONDARY_COLOR_ARRAY_POINTER"/>
+ <enum value="0x845D" name="GL_SECONDARY_COLOR_ARRAY_POINTER_EXT"/>
+ <enum value="0x845E" name="GL_SECONDARY_COLOR_ARRAY"/>
+ <enum value="0x845E" name="GL_SECONDARY_COLOR_ARRAY_EXT"/>
+ <enum value="0x845F" name="GL_CURRENT_RASTER_SECONDARY_COLOR"/>
+ <unused start="0x8460" end="0x846B" comment="Incomplete extension SGIX_icc_texture"/>
+ <!-- <enum value="0x8460" name="GL_RGB_ICC_SGIX"/> -->
+ <!-- <enum value="0x8461" name="GL_RGBA_ICC_SGIX"/> -->
+ <!-- <enum value="0x8462" name="GL_ALPHA_ICC_SGIX"/> -->
+ <!-- <enum value="0x8463" name="GL_LUMINANCE_ICC_SGIX"/> -->
+ <!-- <enum value="0x8464" name="GL_INTENSITY_ICC_SGIX"/> -->
+ <!-- <enum value="0x8465" name="GL_LUMINANCE_ALPHA_ICC_SGIX"/> -->
+ <!-- <enum value="0x8466" name="GL_R5_G6_B5_ICC_SGIX"/> -->
+ <!-- <enum value="0x8467" name="GL_R5_G6_B5_A8_ICC_SGIX"/> -->
+ <!-- <enum value="0x8468" name="GL_ALPHA16_ICC_SGIX"/> -->
+ <!-- <enum value="0x8469" name="GL_LUMINANCE16_ICC_SGIX"/> -->
+ <!-- <enum value="0x846A" name="GL_INTENSITY16_ICC_SGIX"/> -->
+ <!-- <enum value="0x846B" name="GL_LUMINANCE16_ALPHA8_ICC_SGIX"/> -->
+ <unused start="0x846C" vendor="SGI"/>
+ <enum value="0x846D" name="GL_ALIASED_POINT_SIZE_RANGE"/>
+ <enum value="0x846E" name="GL_ALIASED_LINE_WIDTH_RANGE"/>
+ <unused start="0x846F" vendor="SGI"/>
+ </enums>
+
+ <enums namespace="GL" start="0x8470" end="0x848F" vendor="AMD">
+ <unused start="0x8470" end="0x848F" vendor="AMD"/>
+ </enums>
+
+ <enums namespace="GL" start="0x8490" end="0x849F" vendor="REND">
+ <enum value="0x8490" name="GL_SCREEN_COORDINATES_REND"/>
+ <enum value="0x8491" name="GL_INVERTED_SCREEN_W_REND"/>
+ <unused start="0x8492" end="0x849F" vendor="REND"/>
+ </enums>
+
+ <enums namespace="GL" start="0x84A0" end="0x84BF" vendor="AMD">
+ <unused start="0x84A0" end="0x84BF" vendor="AMD"/>
+ </enums>
+
+ <enums namespace="GL" start="0x84C0" end="0x84EF" vendor="ARB">
+ <enum value="0x84C0" name="GL_TEXTURE0"/>
+ <enum value="0x84C0" name="GL_TEXTURE0_ARB"/>
+ <enum value="0x84C1" name="GL_TEXTURE1"/>
+ <enum value="0x84C1" name="GL_TEXTURE1_ARB"/>
+ <enum value="0x84C2" name="GL_TEXTURE2"/>
+ <enum value="0x84C2" name="GL_TEXTURE2_ARB"/>
+ <enum value="0x84C3" name="GL_TEXTURE3"/>
+ <enum value="0x84C3" name="GL_TEXTURE3_ARB"/>
+ <enum value="0x84C4" name="GL_TEXTURE4"/>
+ <enum value="0x84C4" name="GL_TEXTURE4_ARB"/>
+ <enum value="0x84C5" name="GL_TEXTURE5"/>
+ <enum value="0x84C5" name="GL_TEXTURE5_ARB"/>
+ <enum value="0x84C6" name="GL_TEXTURE6"/>
+ <enum value="0x84C6" name="GL_TEXTURE6_ARB"/>
+ <enum value="0x84C7" name="GL_TEXTURE7"/>
+ <enum value="0x84C7" name="GL_TEXTURE7_ARB"/>
+ <enum value="0x84C8" name="GL_TEXTURE8"/>
+ <enum value="0x84C8" name="GL_TEXTURE8_ARB"/>
+ <enum value="0x84C9" name="GL_TEXTURE9"/>
+ <enum value="0x84C9" name="GL_TEXTURE9_ARB"/>
+ <enum value="0x84CA" name="GL_TEXTURE10"/>
+ <enum value="0x84CA" name="GL_TEXTURE10_ARB"/>
+ <enum value="0x84CB" name="GL_TEXTURE11"/>
+ <enum value="0x84CB" name="GL_TEXTURE11_ARB"/>
+ <enum value="0x84CC" name="GL_TEXTURE12"/>
+ <enum value="0x84CC" name="GL_TEXTURE12_ARB"/>
+ <enum value="0x84CD" name="GL_TEXTURE13"/>
+ <enum value="0x84CD" name="GL_TEXTURE13_ARB"/>
+ <enum value="0x84CE" name="GL_TEXTURE14"/>
+ <enum value="0x84CE" name="GL_TEXTURE14_ARB"/>
+ <enum value="0x84CF" name="GL_TEXTURE15"/>
+ <enum value="0x84CF" name="GL_TEXTURE15_ARB"/>
+ <enum value="0x84D0" name="GL_TEXTURE16"/>
+ <enum value="0x84D0" name="GL_TEXTURE16_ARB"/>
+ <enum value="0x84D1" name="GL_TEXTURE17"/>
+ <enum value="0x84D1" name="GL_TEXTURE17_ARB"/>
+ <enum value="0x84D2" name="GL_TEXTURE18"/>
+ <enum value="0x84D2" name="GL_TEXTURE18_ARB"/>
+ <enum value="0x84D3" name="GL_TEXTURE19"/>
+ <enum value="0x84D3" name="GL_TEXTURE19_ARB"/>
+ <enum value="0x84D4" name="GL_TEXTURE20"/>
+ <enum value="0x84D4" name="GL_TEXTURE20_ARB"/>
+ <enum value="0x84D5" name="GL_TEXTURE21"/>
+ <enum value="0x84D5" name="GL_TEXTURE21_ARB"/>
+ <enum value="0x84D6" name="GL_TEXTURE22"/>
+ <enum value="0x84D6" name="GL_TEXTURE22_ARB"/>
+ <enum value="0x84D7" name="GL_TEXTURE23"/>
+ <enum value="0x84D7" name="GL_TEXTURE23_ARB"/>
+ <enum value="0x84D8" name="GL_TEXTURE24"/>
+ <enum value="0x84D8" name="GL_TEXTURE24_ARB"/>
+ <enum value="0x84D9" name="GL_TEXTURE25"/>
+ <enum value="0x84D9" name="GL_TEXTURE25_ARB"/>
+ <enum value="0x84DA" name="GL_TEXTURE26"/>
+ <enum value="0x84DA" name="GL_TEXTURE26_ARB"/>
+ <enum value="0x84DB" name="GL_TEXTURE27"/>
+ <enum value="0x84DB" name="GL_TEXTURE27_ARB"/>
+ <enum value="0x84DC" name="GL_TEXTURE28"/>
+ <enum value="0x84DC" name="GL_TEXTURE28_ARB"/>
+ <enum value="0x84DD" name="GL_TEXTURE29"/>
+ <enum value="0x84DD" name="GL_TEXTURE29_ARB"/>
+ <enum value="0x84DE" name="GL_TEXTURE30"/>
+ <enum value="0x84DE" name="GL_TEXTURE30_ARB"/>
+ <enum value="0x84DF" name="GL_TEXTURE31"/>
+ <enum value="0x84DF" name="GL_TEXTURE31_ARB"/>
+ <enum value="0x84E0" name="GL_ACTIVE_TEXTURE"/>
+ <enum value="0x84E0" name="GL_ACTIVE_TEXTURE_ARB"/>
+ <enum value="0x84E1" name="GL_CLIENT_ACTIVE_TEXTURE"/>
+ <enum value="0x84E1" name="GL_CLIENT_ACTIVE_TEXTURE_ARB"/>
+ <enum value="0x84E2" name="GL_MAX_TEXTURE_UNITS"/>
+ <enum value="0x84E2" name="GL_MAX_TEXTURE_UNITS_ARB"/>
+ <enum value="0x84E3" name="GL_TRANSPOSE_MODELVIEW_MATRIX"/>
+ <enum value="0x84E3" name="GL_TRANSPOSE_MODELVIEW_MATRIX_ARB"/>
+ <enum value="0x84E3" name="GL_PATH_TRANSPOSE_MODELVIEW_MATRIX_NV"/>
+ <enum value="0x84E4" name="GL_TRANSPOSE_PROJECTION_MATRIX"/>
+ <enum value="0x84E4" name="GL_TRANSPOSE_PROJECTION_MATRIX_ARB"/>
+ <enum value="0x84E4" name="GL_PATH_TRANSPOSE_PROJECTION_MATRIX_NV"/>
+ <enum value="0x84E5" name="GL_TRANSPOSE_TEXTURE_MATRIX"/>
+ <enum value="0x84E5" name="GL_TRANSPOSE_TEXTURE_MATRIX_ARB"/>
+ <enum value="0x84E6" name="GL_TRANSPOSE_COLOR_MATRIX"/>
+ <enum value="0x84E6" name="GL_TRANSPOSE_COLOR_MATRIX_ARB"/>
+ <enum value="0x84E7" name="GL_SUBTRACT"/>
+ <enum value="0x84E7" name="GL_SUBTRACT_ARB"/>
+ <enum value="0x84E8" name="GL_MAX_RENDERBUFFER_SIZE"/>
+ <enum value="0x84E8" name="GL_MAX_RENDERBUFFER_SIZE_EXT"/>
+ <enum value="0x84E8" name="GL_MAX_RENDERBUFFER_SIZE_OES"/>
+ <enum value="0x84E9" name="GL_COMPRESSED_ALPHA"/>
+ <enum value="0x84E9" name="GL_COMPRESSED_ALPHA_ARB"/>
+ <enum value="0x84EA" name="GL_COMPRESSED_LUMINANCE"/>
+ <enum value="0x84EA" name="GL_COMPRESSED_LUMINANCE_ARB"/>
+ <enum value="0x84EB" name="GL_COMPRESSED_LUMINANCE_ALPHA"/>
+ <enum value="0x84EB" name="GL_COMPRESSED_LUMINANCE_ALPHA_ARB"/>
+ <enum value="0x84EC" name="GL_COMPRESSED_INTENSITY"/>
+ <enum value="0x84EC" name="GL_COMPRESSED_INTENSITY_ARB"/>
+ <enum value="0x84ED" name="GL_COMPRESSED_RGB"/>
+ <enum value="0x84ED" name="GL_COMPRESSED_RGB_ARB"/>
+ <enum value="0x84EE" name="GL_COMPRESSED_RGBA"/>
+ <enum value="0x84EE" name="GL_COMPRESSED_RGBA_ARB"/>
+ <enum value="0x84EF" name="GL_TEXTURE_COMPRESSION_HINT"/>
+ <enum value="0x84EF" name="GL_TEXTURE_COMPRESSION_HINT_ARB"/>
+ </enums>
+
+ <enums namespace="GL" start="0x84F0" end="0x855F" vendor="NV">
+ <enum value="0x84F0" name="GL_UNIFORM_BLOCK_REFERENCED_BY_TESS_CONTROL_SHADER"/>
+ <enum value="0x84F1" name="GL_UNIFORM_BLOCK_REFERENCED_BY_TESS_EVALUATION_SHADER"/>
+ <enum value="0x84F2" name="GL_ALL_COMPLETED_NV"/>
+ <enum value="0x84F3" name="GL_FENCE_STATUS_NV"/>
+ <enum value="0x84F4" name="GL_FENCE_CONDITION_NV"/>
+ <enum value="0x84F5" name="GL_TEXTURE_RECTANGLE"/>
+ <enum value="0x84F5" name="GL_TEXTURE_RECTANGLE_ARB"/>
+ <enum value="0x84F5" name="GL_TEXTURE_RECTANGLE_NV"/>
+ <enum value="0x84F6" name="GL_TEXTURE_BINDING_RECTANGLE"/>
+ <enum value="0x84F6" name="GL_TEXTURE_BINDING_RECTANGLE_ARB"/>
+ <enum value="0x84F6" name="GL_TEXTURE_BINDING_RECTANGLE_NV"/>
+ <enum value="0x84F7" name="GL_PROXY_TEXTURE_RECTANGLE"/>
+ <enum value="0x84F7" name="GL_PROXY_TEXTURE_RECTANGLE_ARB"/>
+ <enum value="0x84F7" name="GL_PROXY_TEXTURE_RECTANGLE_NV"/>
+ <enum value="0x84F8" name="GL_MAX_RECTANGLE_TEXTURE_SIZE"/>
+ <enum value="0x84F8" name="GL_MAX_RECTANGLE_TEXTURE_SIZE_ARB"/>
+ <enum value="0x84F8" name="GL_MAX_RECTANGLE_TEXTURE_SIZE_NV"/>
+ <enum value="0x84F9" name="GL_DEPTH_STENCIL"/>
+ <enum value="0x84F9" name="GL_DEPTH_STENCIL_EXT"/>
+ <enum value="0x84F9" name="GL_DEPTH_STENCIL_NV"/>
+ <enum value="0x84F9" name="GL_DEPTH_STENCIL_OES"/>
+ <enum value="0x84FA" name="GL_UNSIGNED_INT_24_8"/>
+ <enum value="0x84FA" name="GL_UNSIGNED_INT_24_8_EXT"/>
+ <enum value="0x84FA" name="GL_UNSIGNED_INT_24_8_NV"/>
+ <enum value="0x84FA" name="GL_UNSIGNED_INT_24_8_OES"/>
+ <unused start="0x84FB" end="0x84FC" vendor="NV"/>
+ <enum value="0x84FD" name="GL_MAX_TEXTURE_LOD_BIAS"/>
+ <enum value="0x84FD" name="GL_MAX_TEXTURE_LOD_BIAS_EXT"/>
+ <enum value="0x84FE" name="GL_TEXTURE_MAX_ANISOTROPY_EXT"/>
+ <enum value="0x84FF" name="GL_MAX_TEXTURE_MAX_ANISOTROPY_EXT"/>
+ <enum value="0x8500" name="GL_TEXTURE_FILTER_CONTROL"/>
+ <enum value="0x8500" name="GL_TEXTURE_FILTER_CONTROL_EXT"/>
+ <enum value="0x8501" name="GL_TEXTURE_LOD_BIAS"/>
+ <enum value="0x8501" name="GL_TEXTURE_LOD_BIAS_EXT"/>
+ <enum value="0x8502" name="GL_MODELVIEW1_STACK_DEPTH_EXT"/>
+ <enum value="0x8503" name="GL_COMBINE4_NV"/>
+ <enum value="0x8504" name="GL_MAX_SHININESS_NV"/>
+ <enum value="0x8505" name="GL_MAX_SPOT_EXPONENT_NV"/>
+ <enum value="0x8506" name="GL_MODELVIEW1_MATRIX_EXT"/>
+ <enum value="0x8507" name="GL_INCR_WRAP"/>
+ <enum value="0x8507" name="GL_INCR_WRAP_EXT"/>
+ <enum value="0x8507" name="GL_INCR_WRAP_OES"/>
+ <enum value="0x8508" name="GL_DECR_WRAP"/>
+ <enum value="0x8508" name="GL_DECR_WRAP_EXT"/>
+ <enum value="0x8508" name="GL_DECR_WRAP_OES"/>
+ <enum value="0x8509" name="GL_VERTEX_WEIGHTING_EXT"/>
+ <enum value="0x850A" name="GL_MODELVIEW1_ARB"/>
+ <enum value="0x850A" name="GL_MODELVIEW1_EXT"/>
+ <enum value="0x850B" name="GL_CURRENT_VERTEX_WEIGHT_EXT"/>
+ <enum value="0x850C" name="GL_VERTEX_WEIGHT_ARRAY_EXT"/>
+ <enum value="0x850D" name="GL_VERTEX_WEIGHT_ARRAY_SIZE_EXT"/>
+ <enum value="0x850E" name="GL_VERTEX_WEIGHT_ARRAY_TYPE_EXT"/>
+ <enum value="0x850F" name="GL_VERTEX_WEIGHT_ARRAY_STRIDE_EXT"/>
+ <enum value="0x8510" name="GL_VERTEX_WEIGHT_ARRAY_POINTER_EXT"/>
+ <enum value="0x8511" name="GL_NORMAL_MAP"/>
+ <enum value="0x8511" name="GL_NORMAL_MAP_ARB"/>
+ <enum value="0x8511" name="GL_NORMAL_MAP_EXT"/>
+ <enum value="0x8511" name="GL_NORMAL_MAP_NV"/>
+ <enum value="0x8511" name="GL_NORMAL_MAP_OES"/>
+ <enum value="0x8512" name="GL_REFLECTION_MAP"/>
+ <enum value="0x8512" name="GL_REFLECTION_MAP_ARB"/>
+ <enum value="0x8512" name="GL_REFLECTION_MAP_EXT"/>
+ <enum value="0x8512" name="GL_REFLECTION_MAP_NV"/>
+ <enum value="0x8512" name="GL_REFLECTION_MAP_OES"/>
+ <enum value="0x8513" name="GL_TEXTURE_CUBE_MAP"/>
+ <enum value="0x8513" name="GL_TEXTURE_CUBE_MAP_ARB"/>
+ <enum value="0x8513" name="GL_TEXTURE_CUBE_MAP_EXT"/>
+ <enum value="0x8513" name="GL_TEXTURE_CUBE_MAP_OES"/>
+ <enum value="0x8514" name="GL_TEXTURE_BINDING_CUBE_MAP"/>
+ <enum value="0x8514" name="GL_TEXTURE_BINDING_CUBE_MAP_ARB"/>
+ <enum value="0x8514" name="GL_TEXTURE_BINDING_CUBE_MAP_EXT"/>
+ <enum value="0x8514" name="GL_TEXTURE_BINDING_CUBE_MAP_OES"/>
+ <enum value="0x8515" name="GL_TEXTURE_CUBE_MAP_POSITIVE_X"/>
+ <enum value="0x8515" name="GL_TEXTURE_CUBE_MAP_POSITIVE_X_ARB"/>
+ <enum value="0x8515" name="GL_TEXTURE_CUBE_MAP_POSITIVE_X_EXT"/>
+ <enum value="0x8515" name="GL_TEXTURE_CUBE_MAP_POSITIVE_X_OES"/>
+ <enum value="0x8516" name="GL_TEXTURE_CUBE_MAP_NEGATIVE_X"/>
+ <enum value="0x8516" name="GL_TEXTURE_CUBE_MAP_NEGATIVE_X_ARB"/>
+ <enum value="0x8516" name="GL_TEXTURE_CUBE_MAP_NEGATIVE_X_EXT"/>
+ <enum value="0x8516" name="GL_TEXTURE_CUBE_MAP_NEGATIVE_X_OES"/>
+ <enum value="0x8517" name="GL_TEXTURE_CUBE_MAP_POSITIVE_Y"/>
+ <enum value="0x8517" name="GL_TEXTURE_CUBE_MAP_POSITIVE_Y_ARB"/>
+ <enum value="0x8517" name="GL_TEXTURE_CUBE_MAP_POSITIVE_Y_EXT"/>
+ <enum value="0x8517" name="GL_TEXTURE_CUBE_MAP_POSITIVE_Y_OES"/>
+ <enum value="0x8518" name="GL_TEXTURE_CUBE_MAP_NEGATIVE_Y"/>
+ <enum value="0x8518" name="GL_TEXTURE_CUBE_MAP_NEGATIVE_Y_ARB"/>
+ <enum value="0x8518" name="GL_TEXTURE_CUBE_MAP_NEGATIVE_Y_EXT"/>
+ <enum value="0x8518" name="GL_TEXTURE_CUBE_MAP_NEGATIVE_Y_OES"/>
+ <enum value="0x8519" name="GL_TEXTURE_CUBE_MAP_POSITIVE_Z"/>
+ <enum value="0x8519" name="GL_TEXTURE_CUBE_MAP_POSITIVE_Z_ARB"/>
+ <enum value="0x8519" name="GL_TEXTURE_CUBE_MAP_POSITIVE_Z_EXT"/>
+ <enum value="0x8519" name="GL_TEXTURE_CUBE_MAP_POSITIVE_Z_OES"/>
+ <enum value="0x851A" name="GL_TEXTURE_CUBE_MAP_NEGATIVE_Z"/>
+ <enum value="0x851A" name="GL_TEXTURE_CUBE_MAP_NEGATIVE_Z_ARB"/>
+ <enum value="0x851A" name="GL_TEXTURE_CUBE_MAP_NEGATIVE_Z_EXT"/>
+ <enum value="0x851A" name="GL_TEXTURE_CUBE_MAP_NEGATIVE_Z_OES"/>
+ <enum value="0x851B" name="GL_PROXY_TEXTURE_CUBE_MAP"/>
+ <enum value="0x851B" name="GL_PROXY_TEXTURE_CUBE_MAP_ARB"/>
+ <enum value="0x851B" name="GL_PROXY_TEXTURE_CUBE_MAP_EXT"/>
+ <enum value="0x851C" name="GL_MAX_CUBE_MAP_TEXTURE_SIZE"/>
+ <enum value="0x851C" name="GL_MAX_CUBE_MAP_TEXTURE_SIZE_ARB"/>
+ <enum value="0x851C" name="GL_MAX_CUBE_MAP_TEXTURE_SIZE_EXT"/>
+ <enum value="0x851C" name="GL_MAX_CUBE_MAP_TEXTURE_SIZE_OES"/>
+ <enum value="0x851D" name="GL_VERTEX_ARRAY_RANGE_APPLE"/>
+ <enum value="0x851D" name="GL_VERTEX_ARRAY_RANGE_NV"/>
+ <enum value="0x851E" name="GL_VERTEX_ARRAY_RANGE_LENGTH_APPLE"/>
+ <enum value="0x851E" name="GL_VERTEX_ARRAY_RANGE_LENGTH_NV"/>
+ <enum value="0x851F" name="GL_VERTEX_ARRAY_RANGE_VALID_NV"/>
+ <enum value="0x851F" name="GL_VERTEX_ARRAY_STORAGE_HINT_APPLE"/>
+ <enum value="0x8520" name="GL_MAX_VERTEX_ARRAY_RANGE_ELEMENT_NV"/>
+ <enum value="0x8521" name="GL_VERTEX_ARRAY_RANGE_POINTER_APPLE"/>
+ <enum value="0x8521" name="GL_VERTEX_ARRAY_RANGE_POINTER_NV"/>
+ <enum value="0x8522" name="GL_REGISTER_COMBINERS_NV"/>
+ <enum value="0x8523" name="GL_VARIABLE_A_NV"/>
+ <enum value="0x8524" name="GL_VARIABLE_B_NV"/>
+ <enum value="0x8525" name="GL_VARIABLE_C_NV"/>
+ <enum value="0x8526" name="GL_VARIABLE_D_NV"/>
+ <enum value="0x8527" name="GL_VARIABLE_E_NV"/>
+ <enum value="0x8528" name="GL_VARIABLE_F_NV"/>
+ <enum value="0x8529" name="GL_VARIABLE_G_NV"/>
+ <enum value="0x852A" name="GL_CONSTANT_COLOR0_NV"/>
+ <enum value="0x852B" name="GL_CONSTANT_COLOR1_NV"/>
+ <enum value="0x852C" name="GL_PRIMARY_COLOR_NV"/>
+ <enum value="0x852D" name="GL_SECONDARY_COLOR_NV"/>
+ <enum value="0x852E" name="GL_SPARE0_NV"/>
+ <enum value="0x852F" name="GL_SPARE1_NV"/>
+ <enum value="0x8530" name="GL_DISCARD_NV"/>
+ <enum value="0x8531" name="GL_E_TIMES_F_NV"/>
+ <enum value="0x8532" name="GL_SPARE0_PLUS_SECONDARY_COLOR_NV"/>
+ <enum value="0x8533" name="GL_VERTEX_ARRAY_RANGE_WITHOUT_FLUSH_NV"/>
+ <enum value="0x8534" name="GL_MULTISAMPLE_FILTER_HINT_NV"/>
+ <enum value="0x8535" name="GL_PER_STAGE_CONSTANTS_NV"/>
+ <enum value="0x8536" name="GL_UNSIGNED_IDENTITY_NV"/>
+ <enum value="0x8537" name="GL_UNSIGNED_INVERT_NV"/>
+ <enum value="0x8538" name="GL_EXPAND_NORMAL_NV"/>
+ <enum value="0x8539" name="GL_EXPAND_NEGATE_NV"/>
+ <enum value="0x853A" name="GL_HALF_BIAS_NORMAL_NV"/>
+ <enum value="0x853B" name="GL_HALF_BIAS_NEGATE_NV"/>
+ <enum value="0x853C" name="GL_SIGNED_IDENTITY_NV"/>
+ <enum value="0x853D" name="GL_SIGNED_NEGATE_NV"/>
+ <enum value="0x853E" name="GL_SCALE_BY_TWO_NV"/>
+ <enum value="0x853F" name="GL_SCALE_BY_FOUR_NV"/>
+ <enum value="0x8540" name="GL_SCALE_BY_ONE_HALF_NV"/>
+ <enum value="0x8541" name="GL_BIAS_BY_NEGATIVE_ONE_HALF_NV"/>
+ <enum value="0x8542" name="GL_COMBINER_INPUT_NV"/>
+ <enum value="0x8543" name="GL_COMBINER_MAPPING_NV"/>
+ <enum value="0x8544" name="GL_COMBINER_COMPONENT_USAGE_NV"/>
+ <enum value="0x8545" name="GL_COMBINER_AB_DOT_PRODUCT_NV"/>
+ <enum value="0x8546" name="GL_COMBINER_CD_DOT_PRODUCT_NV"/>
+ <enum value="0x8547" name="GL_COMBINER_MUX_SUM_NV"/>
+ <enum value="0x8548" name="GL_COMBINER_SCALE_NV"/>
+ <enum value="0x8549" name="GL_COMBINER_BIAS_NV"/>
+ <enum value="0x854A" name="GL_COMBINER_AB_OUTPUT_NV"/>
+ <enum value="0x854B" name="GL_COMBINER_CD_OUTPUT_NV"/>
+ <enum value="0x854C" name="GL_COMBINER_SUM_OUTPUT_NV"/>
+ <enum value="0x854D" name="GL_MAX_GENERAL_COMBINERS_NV"/>
+ <enum value="0x854E" name="GL_NUM_GENERAL_COMBINERS_NV"/>
+ <enum value="0x854F" name="GL_COLOR_SUM_CLAMP_NV"/>
+ <enum value="0x8550" name="GL_COMBINER0_NV"/>
+ <enum value="0x8551" name="GL_COMBINER1_NV"/>
+ <enum value="0x8552" name="GL_COMBINER2_NV"/>
+ <enum value="0x8553" name="GL_COMBINER3_NV"/>
+ <enum value="0x8554" name="GL_COMBINER4_NV"/>
+ <enum value="0x8555" name="GL_COMBINER5_NV"/>
+ <enum value="0x8556" name="GL_COMBINER6_NV"/>
+ <enum value="0x8557" name="GL_COMBINER7_NV"/>
+ <enum value="0x8558" name="GL_PRIMITIVE_RESTART_NV"/>
+ <enum value="0x8559" name="GL_PRIMITIVE_RESTART_INDEX_NV"/>
+ <enum value="0x855A" name="GL_FOG_DISTANCE_MODE_NV"/>
+ <enum value="0x855B" name="GL_EYE_RADIAL_NV"/>
+ <enum value="0x855C" name="GL_EYE_PLANE_ABSOLUTE_NV"/>
+ <enum value="0x855D" name="GL_EMBOSS_LIGHT_NV"/>
+ <enum value="0x855E" name="GL_EMBOSS_CONSTANT_NV"/>
+ <enum value="0x855F" name="GL_EMBOSS_MAP_NV"/>
+ </enums>
+
+ <enums namespace="GL" start="0x8560" end="0x856F" vendor="ZiiLabs">
+ <enum value="0x8560" name="GL_RED_MIN_CLAMP_INGR"/>
+ <enum value="0x8561" name="GL_GREEN_MIN_CLAMP_INGR"/>
+ <enum value="0x8562" name="GL_BLUE_MIN_CLAMP_INGR"/>
+ <enum value="0x8563" name="GL_ALPHA_MIN_CLAMP_INGR"/>
+ <enum value="0x8564" name="GL_RED_MAX_CLAMP_INGR"/>
+ <enum value="0x8565" name="GL_GREEN_MAX_CLAMP_INGR"/>
+ <enum value="0x8566" name="GL_BLUE_MAX_CLAMP_INGR"/>
+ <enum value="0x8567" name="GL_ALPHA_MAX_CLAMP_INGR"/>
+ <enum value="0x8568" name="GL_INTERLACE_READ_INGR"/>
+ <unused start="0x8569" end="0x856F" vendor="ZiiLabs"/>
+ </enums>
+
+ <enums namespace="GL" start="0x8570" end="0x859F" group="RegisterCombinerPname" vendor="AMD/NV">
+ <enum value="0x8570" name="GL_COMBINE"/>
+ <enum value="0x8570" name="GL_COMBINE_ARB"/>
+ <enum value="0x8570" name="GL_COMBINE_EXT"/>
+ <enum value="0x8571" name="GL_COMBINE_RGB"/>
+ <enum value="0x8571" name="GL_COMBINE_RGB_ARB"/>
+ <enum value="0x8571" name="GL_COMBINE_RGB_EXT"/>
+ <enum value="0x8572" name="GL_COMBINE_ALPHA"/>
+ <enum value="0x8572" name="GL_COMBINE_ALPHA_ARB"/>
+ <enum value="0x8572" name="GL_COMBINE_ALPHA_EXT"/>
+ <enum value="0x8573" name="GL_RGB_SCALE"/>
+ <enum value="0x8573" name="GL_RGB_SCALE_ARB"/>
+ <enum value="0x8573" name="GL_RGB_SCALE_EXT"/>
+ <enum value="0x8574" name="GL_ADD_SIGNED"/>
+ <enum value="0x8574" name="GL_ADD_SIGNED_ARB"/>
+ <enum value="0x8574" name="GL_ADD_SIGNED_EXT"/>
+ <enum value="0x8575" name="GL_INTERPOLATE"/>
+ <enum value="0x8575" name="GL_INTERPOLATE_ARB"/>
+ <enum value="0x8575" name="GL_INTERPOLATE_EXT"/>
+ <enum value="0x8576" name="GL_CONSTANT"/>
+ <enum value="0x8576" name="GL_CONSTANT_ARB"/>
+ <enum value="0x8576" name="GL_CONSTANT_EXT"/>
+ <enum value="0x8576" name="GL_CONSTANT_NV"/>
+ <enum value="0x8577" name="GL_PRIMARY_COLOR"/>
+ <enum value="0x8577" name="GL_PRIMARY_COLOR_ARB"/>
+ <enum value="0x8577" name="GL_PRIMARY_COLOR_EXT"/>
+ <enum value="0x8578" name="GL_PREVIOUS"/>
+ <enum value="0x8578" name="GL_PREVIOUS_ARB"/>
+ <enum value="0x8578" name="GL_PREVIOUS_EXT"/>
+ <unused start="0x8579" end="0x857F" comment="Additional combiner enums only"/>
+ <enum value="0x8580" name="GL_SOURCE0_RGB"/>
+ <enum value="0x8580" name="GL_SOURCE0_RGB_ARB"/>
+ <enum value="0x8580" name="GL_SOURCE0_RGB_EXT"/>
+ <enum value="0x8580" name="GL_SRC0_RGB" alias="GL_SOURCE0_RGB"/>
+ <enum value="0x8581" name="GL_SOURCE1_RGB"/>
+ <enum value="0x8581" name="GL_SOURCE1_RGB_ARB"/>
+ <enum value="0x8581" name="GL_SOURCE1_RGB_EXT"/>
+ <enum value="0x8581" name="GL_SRC1_RGB" alias="GL_SOURCE1_RGB"/>
+ <enum value="0x8582" name="GL_SOURCE2_RGB"/>
+ <enum value="0x8582" name="GL_SOURCE2_RGB_ARB"/>
+ <enum value="0x8582" name="GL_SOURCE2_RGB_EXT"/>
+ <enum value="0x8582" name="GL_SRC2_RGB" alias="GL_SOURCE2_RGB"/>
+ <enum value="0x8583" name="GL_SOURCE3_RGB_NV"/>
+ <unused start="0x8584" end="0x8587" comment="Additional combiner enums only"/>
+ <enum value="0x8588" name="GL_SOURCE0_ALPHA"/>
+ <enum value="0x8588" name="GL_SOURCE0_ALPHA_ARB"/>
+ <enum value="0x8588" name="GL_SOURCE0_ALPHA_EXT"/>
+ <enum value="0x8588" name="GL_SRC0_ALPHA" alias="GL_SOURCE0_ALPHA"/>
+ <enum value="0x8589" name="GL_SOURCE1_ALPHA"/>
+ <enum value="0x8589" name="GL_SOURCE1_ALPHA_ARB"/>
+ <enum value="0x8589" name="GL_SOURCE1_ALPHA_EXT"/>
+ <enum value="0x8589" name="GL_SRC1_ALPHA" alias="GL_SOURCE1_ALPHA"/>
+ <enum value="0x858A" name="GL_SOURCE2_ALPHA"/>
+ <enum value="0x858A" name="GL_SOURCE2_ALPHA_ARB"/>
+ <enum value="0x858A" name="GL_SOURCE2_ALPHA_EXT"/>
+ <enum value="0x858A" name="GL_SRC2_ALPHA" alias="GL_SOURCE2_ALPHA"/>
+ <enum value="0x858B" name="GL_SOURCE3_ALPHA_NV"/>
+ <unused start="0x858C" end="0x858F" comment="Additional combiner enums only"/>
+ <enum value="0x8590" name="GL_OPERAND0_RGB"/>
+ <enum value="0x8590" name="GL_OPERAND0_RGB_ARB"/>
+ <enum value="0x8590" name="GL_OPERAND0_RGB_EXT"/>
+ <enum value="0x8591" name="GL_OPERAND1_RGB"/>
+ <enum value="0x8591" name="GL_OPERAND1_RGB_ARB"/>
+ <enum value="0x8591" name="GL_OPERAND1_RGB_EXT"/>
+ <enum value="0x8592" name="GL_OPERAND2_RGB"/>
+ <enum value="0x8592" name="GL_OPERAND2_RGB_ARB"/>
+ <enum value="0x8592" name="GL_OPERAND2_RGB_EXT"/>
+ <enum value="0x8593" name="GL_OPERAND3_RGB_NV"/>
+ <unused start="0x8594" end="0x8597" comment="Additional combiner enums only"/>
+ <enum value="0x8598" name="GL_OPERAND0_ALPHA"/>
+ <enum value="0x8598" name="GL_OPERAND0_ALPHA_ARB"/>
+ <enum value="0x8598" name="GL_OPERAND0_ALPHA_EXT"/>
+ <enum value="0x8599" name="GL_OPERAND1_ALPHA"/>
+ <enum value="0x8599" name="GL_OPERAND1_ALPHA_ARB"/>
+ <enum value="0x8599" name="GL_OPERAND1_ALPHA_EXT"/>
+ <enum value="0x859A" name="GL_OPERAND2_ALPHA"/>
+ <enum value="0x859A" name="GL_OPERAND2_ALPHA_ARB"/>
+ <enum value="0x859A" name="GL_OPERAND2_ALPHA_EXT"/>
+ <enum value="0x859B" name="GL_OPERAND3_ALPHA_NV"/>
+ <unused start="0x859C" end="0x859F" comment="Additional combiner enums only"/>
+ </enums>
+
+ <enums namespace="GL" start="0x85A0" end="0x85AF" vendor="SGI">
+ <enum value="0x85A0" name="GL_PACK_SUBSAMPLE_RATE_SGIX"/>
+ <enum value="0x85A1" name="GL_UNPACK_SUBSAMPLE_RATE_SGIX"/>
+ <enum value="0x85A2" name="GL_PIXEL_SUBSAMPLE_4444_SGIX"/>
+ <enum value="0x85A3" name="GL_PIXEL_SUBSAMPLE_2424_SGIX"/>
+ <enum value="0x85A4" name="GL_PIXEL_SUBSAMPLE_4242_SGIX"/>
+ <unused start="0x85A5" end="0x85AD" comment="Incomplete extension SGIS_color_range"/>
+ <!-- <enum value="0x85A5" name="GL_EXTENDED_RANGE_SGIS"/> -->
+ <!-- <enum value="0x85A6" name="GL_MIN_RED_SGIS"/> -->
+ <!-- <enum value="0x85A7" name="GL_MAX_RED_SGIS"/> -->
+ <!-- <enum value="0x85A8" name="GL_MIN_GREEN_SGIS"/> -->
+ <!-- <enum value="0x85A9" name="GL_MAX_GREEN_SGIS"/> -->
+ <!-- <enum value="0x85AA" name="GL_MIN_BLUE_SGIS"/> -->
+ <!-- <enum value="0x85AB" name="GL_MAX_BLUE_SGIS"/> -->
+ <!-- <enum value="0x85AC" name="GL_MIN_ALPHA_SGIS"/> -->
+ <!-- <enum value="0x85AD" name="GL_MAX_ALPHA_SGIS"/> -->
+ <enum value="0x85AE" name="GL_PERTURB_EXT"/>
+ <enum value="0x85AF" name="GL_TEXTURE_NORMAL_EXT"/>
+ </enums>
+
+ <enums namespace="GL" start="0x85B0" end="0x85BF" vendor="APPLE">
+ <enum value="0x85B0" name="GL_LIGHT_MODEL_SPECULAR_VECTOR_APPLE"/>
+ <enum value="0x85B1" name="GL_TRANSFORM_HINT_APPLE"/>
+ <enum value="0x85B2" name="GL_UNPACK_CLIENT_STORAGE_APPLE"/>
+ <enum value="0x85B3" name="GL_BUFFER_OBJECT_APPLE"/>
+ <enum value="0x85B4" name="GL_STORAGE_CLIENT_APPLE"/>
+ <enum value="0x85B5" name="GL_VERTEX_ARRAY_BINDING"/>
+ <enum value="0x85B5" name="GL_VERTEX_ARRAY_BINDING_APPLE"/>
+ <enum value="0x85B5" name="GL_VERTEX_ARRAY_BINDING_OES"/>
+ <unused start="0x85B6" vendor="APPLE" comment="Unknown extension (Khronos bug 632)"/>
+ <!-- <enum value="0x85B6" name="GL_TEXTURE_MINIMIZE_STORAGE_APPLE"/> -->
+ <enum value="0x85B7" name="GL_TEXTURE_RANGE_LENGTH_APPLE"/>
+ <enum value="0x85B8" name="GL_TEXTURE_RANGE_POINTER_APPLE"/>
+ <enum value="0x85B9" name="GL_YCBCR_422_APPLE"/>
+ <enum value="0x85BA" name="GL_UNSIGNED_SHORT_8_8_APPLE"/>
+ <enum value="0x85BA" name="GL_UNSIGNED_SHORT_8_8_MESA"/>
+ <enum value="0x85BB" name="GL_UNSIGNED_SHORT_8_8_REV_APPLE"/>
+ <enum value="0x85BB" name="GL_UNSIGNED_SHORT_8_8_REV_MESA"/>
+ <enum value="0x85BC" name="GL_TEXTURE_STORAGE_HINT_APPLE"/>
+ <enum value="0x85BD" name="GL_STORAGE_PRIVATE_APPLE"/>
+ <enum value="0x85BE" name="GL_STORAGE_CACHED_APPLE"/>
+ <enum value="0x85BF" name="GL_STORAGE_SHARED_APPLE"/>
+ </enums>
+
+ <enums namespace="GL" start="0x85C0" end="0x85CF" vendor="SUN">
+ <enum value="0x85C0" name="GL_REPLACEMENT_CODE_ARRAY_SUN"/>
+ <enum value="0x85C1" name="GL_REPLACEMENT_CODE_ARRAY_TYPE_SUN"/>
+ <enum value="0x85C2" name="GL_REPLACEMENT_CODE_ARRAY_STRIDE_SUN"/>
+ <enum value="0x85C3" name="GL_REPLACEMENT_CODE_ARRAY_POINTER_SUN"/>
+ <enum value="0x85C4" name="GL_R1UI_V3F_SUN"/>
+ <enum value="0x85C5" name="GL_R1UI_C4UB_V3F_SUN"/>
+ <enum value="0x85C6" name="GL_R1UI_C3F_V3F_SUN"/>
+ <enum value="0x85C7" name="GL_R1UI_N3F_V3F_SUN"/>
+ <enum value="0x85C8" name="GL_R1UI_C4F_N3F_V3F_SUN"/>
+ <enum value="0x85C9" name="GL_R1UI_T2F_V3F_SUN"/>
+ <enum value="0x85CA" name="GL_R1UI_T2F_N3F_V3F_SUN"/>
+ <enum value="0x85CB" name="GL_R1UI_T2F_C4F_N3F_V3F_SUN"/>
+ <enum value="0x85CC" name="GL_SLICE_ACCUM_SUN"/>
+ <unused start="0x85CD" end="0x85CF" vendor="SUN"/>
+ </enums>
+
+ <enums namespace="GL" start="0x85D0" end="0x85DF" vendor="ZiiLabs" comment="3Dlabs private extension for Autodesk">
+ <unused start="0x85D0" end="0x85D1" comment="Unknown 3Dlabs private extension for Autodesk (but we know the enum values)"/>
+ <!-- <enum value="0x85D0" name="GL_FACET_NORMAL_AUTODESK"/> -->
+ <!-- <enum value="0x85D1" name="GL_FACET_NORMAL_ARRAY_AUTODESK"/> -->
+ <unused start="0x85D2" end="0x85DF" vendor="ZiiLabs"/>
+ </enums>
+
+ <enums namespace="GL" start="0x85E0" end="0x85FF" vendor="SGI">
+ <unused start="0x85E0" end="0x85FB" comment="Incomplete extension SGIX_texture_range"/>
+ <!-- <enum value="0x85E0" name="GL_RGB_SIGNED_SGIX"/> -->
+ <!-- <enum value="0x85E1" name="GL_RGBA_SIGNED_SGIX"/> -->
+ <!-- <enum value="0x85E2" name="GL_ALPHA_SIGNED_SGIX"/> -->
+ <!-- <enum value="0x85E3" name="GL_LUMINANCE_SIGNED_SGIX"/> -->
+ <!-- <enum value="0x85E4" name="GL_INTENSITY_SIGNED_SGIX"/> -->
+ <!-- <enum value="0x85E5" name="GL_LUMINANCE_ALPHA_SIGNED_SGIX"/> -->
+ <!-- <enum value="0x85E6" name="GL_RGB16_SIGNED_SGIX"/> -->
+ <!-- <enum value="0x85E7" name="GL_RGBA16_SIGNED_SGIX"/> -->
+ <!-- <enum value="0x85E8" name="GL_ALPHA16_SIGNED_SGIX"/> -->
+ <!-- <enum value="0x85E9" name="GL_LUMINANCE16_SIGNED_SGIX"/> -->
+ <!-- <enum value="0x85EA" name="GL_INTENSITY16_SIGNED_SGIX"/> -->
+ <!-- <enum value="0x85EB" name="GL_LUMINANCE16_ALPHA16_SIGNED_SGIX"/> -->
+ <!-- <enum value="0x85EC" name="GL_RGB_EXTENDED_RANGE_SGIX"/> -->
+ <!-- <enum value="0x85ED" name="GL_RGBA_EXTENDED_RANGE_SGIX"/> -->
+ <!-- <enum value="0x85EE" name="GL_ALPHA_EXTENDED_RANGE_SGIX"/> -->
+ <!-- <enum value="0x85EF" name="GL_LUMINANCE_EXTENDED_RANGE_SGIX"/> -->
+ <!-- <enum value="0x85F0" name="GL_INTENSITY_EXTENDED_RANGE_SGIX"/> -->
+ <!-- <enum value="0x85F1" name="GL_LUMINANCE_ALPHA_EXTENDED_RANGE_SGIX"/> -->
+ <!-- <enum value="0x85F2" name="GL_RGB16_EXTENDED_RANGE_SGIX"/> -->
+ <!-- <enum value="0x85F3" name="GL_RGBA16_EXTENDED_RANGE_SGIX"/> -->
+ <!-- <enum value="0x85F4" name="GL_ALPHA16_EXTENDED_RANGE_SGIX"/> -->
+ <!-- <enum value="0x85F5" name="GL_LUMINANCE16_EXTENDED_RANGE_SGIX"/> -->
+ <!-- <enum value="0x85F6" name="GL_INTENSITY16_EXTENDED_RANGE_SGIX"/> -->
+ <!-- <enum value="0x85F7" name="GL_LUMINANCE16_ALPHA16_EXTENDED_RANGE_SGIX"/> -->
+ <!-- <enum value="0x85F8" name="GL_MIN_LUMINANCE_SGIS"/> -->
+ <!-- <enum value="0x85F9" name="GL_MAX_LUMINANCE_SGIS"/> -->
+ <!-- <enum value="0x85FA" name="GL_MIN_INTENSITY_SGIS"/> -->
+ <!-- <enum value="0x85FB" name="GL_MAX_INTENSITY_SGIS"/> -->
+ <unused start="0x85FC" end="0x85FF" vendor="SGI"/>
+ </enums>
+
+ <enums namespace="GL" start="0x8600" end="0x861F" vendor="SUN">
+ <unused start="0x8600" end="0x8613" vendor="SUN"/>
+ <enum value="0x8614" name="GL_QUAD_MESH_SUN"/>
+ <enum value="0x8615" name="GL_TRIANGLE_MESH_SUN"/>
+ <unused start="0x8614" end="0x861F" vendor="SUN"/>
+ </enums>
+
+ <enums namespace="GL" start="0x8620" end="0x867F" vendor="NV">
+ <enum value="0x8620" name="GL_VERTEX_PROGRAM_ARB"/>
+ <enum value="0x8620" name="GL_VERTEX_PROGRAM_NV"/>
+ <enum value="0x8621" name="GL_VERTEX_STATE_PROGRAM_NV"/>
+ <enum value="0x8622" name="GL_VERTEX_ATTRIB_ARRAY_ENABLED"/>
+ <enum value="0x8622" name="GL_VERTEX_ATTRIB_ARRAY_ENABLED_ARB"/>
+ <enum value="0x8623" name="GL_ATTRIB_ARRAY_SIZE_NV"/>
+ <enum value="0x8623" name="GL_VERTEX_ATTRIB_ARRAY_SIZE"/>
+ <enum value="0x8623" name="GL_VERTEX_ATTRIB_ARRAY_SIZE_ARB"/>
+ <enum value="0x8624" name="GL_ATTRIB_ARRAY_STRIDE_NV"/>
+ <enum value="0x8624" name="GL_VERTEX_ATTRIB_ARRAY_STRIDE"/>
+ <enum value="0x8624" name="GL_VERTEX_ATTRIB_ARRAY_STRIDE_ARB"/>
+ <enum value="0x8625" name="GL_ATTRIB_ARRAY_TYPE_NV"/>
+ <enum value="0x8625" name="GL_VERTEX_ATTRIB_ARRAY_TYPE"/>
+ <enum value="0x8625" name="GL_VERTEX_ATTRIB_ARRAY_TYPE_ARB"/>
+ <enum value="0x8626" name="GL_CURRENT_ATTRIB_NV"/>
+ <enum value="0x8626" name="GL_CURRENT_VERTEX_ATTRIB"/>
+ <enum value="0x8626" name="GL_CURRENT_VERTEX_ATTRIB_ARB"/>
+ <enum value="0x8627" name="GL_PROGRAM_LENGTH_ARB"/>
+ <enum value="0x8627" name="GL_PROGRAM_LENGTH_NV"/>
+ <enum value="0x8628" name="GL_PROGRAM_STRING_ARB"/>
+ <enum value="0x8628" name="GL_PROGRAM_STRING_NV"/>
+ <enum value="0x8629" name="GL_MODELVIEW_PROJECTION_NV"/>
+ <enum value="0x862A" name="GL_IDENTITY_NV"/>
+ <enum value="0x862B" name="GL_INVERSE_NV"/>
+ <enum value="0x862C" name="GL_TRANSPOSE_NV"/>
+ <enum value="0x862D" name="GL_INVERSE_TRANSPOSE_NV"/>
+ <enum value="0x862E" name="GL_MAX_PROGRAM_MATRIX_STACK_DEPTH_ARB"/>
+ <enum value="0x862E" name="GL_MAX_TRACK_MATRIX_STACK_DEPTH_NV"/>
+ <enum value="0x862F" name="GL_MAX_PROGRAM_MATRICES_ARB"/>
+ <enum value="0x862F" name="GL_MAX_TRACK_MATRICES_NV"/>
+ <enum value="0x8630" name="GL_MATRIX0_NV"/>
+ <enum value="0x8631" name="GL_MATRIX1_NV"/>
+ <enum value="0x8632" name="GL_MATRIX2_NV"/>
+ <enum value="0x8633" name="GL_MATRIX3_NV"/>
+ <enum value="0x8634" name="GL_MATRIX4_NV"/>
+ <enum value="0x8635" name="GL_MATRIX5_NV"/>
+ <enum value="0x8636" name="GL_MATRIX6_NV"/>
+ <enum value="0x8637" name="GL_MATRIX7_NV"/>
+ <unused start="0x8638" end="0x863F" comment="Reserved for MATRIX{8-15}_NV"/>
+ <!-- <enum value="0x8638" name="GL_MATRIX8_NV"/> -->
+ <!-- <enum value="0x8639" name="GL_MATRIX9_NV"/> -->
+ <!-- <enum value="0x863A" name="GL_MATRIX10_NV"/> -->
+ <!-- <enum value="0x863B" name="GL_MATRIX11_NV"/> -->
+ <!-- <enum value="0x863C" name="GL_MATRIX12_NV"/> -->
+ <!-- <enum value="0x863D" name="GL_MATRIX13_NV"/> -->
+ <!-- <enum value="0x863E" name="GL_MATRIX14_NV"/> -->
+ <!-- <enum value="0x863F" name="GL_MATRIX15_NV"/> -->
+ <enum value="0x8640" name="GL_CURRENT_MATRIX_STACK_DEPTH_ARB"/>
+ <enum value="0x8640" name="GL_CURRENT_MATRIX_STACK_DEPTH_NV"/>
+ <enum value="0x8641" name="GL_CURRENT_MATRIX_ARB"/>
+ <enum value="0x8641" name="GL_CURRENT_MATRIX_NV"/>
+ <enum value="0x8642" name="GL_VERTEX_PROGRAM_POINT_SIZE"/>
+ <enum value="0x8642" name="GL_VERTEX_PROGRAM_POINT_SIZE_ARB"/>
+ <enum value="0x8642" name="GL_VERTEX_PROGRAM_POINT_SIZE_NV"/>
+ <enum value="0x8642" name="GL_PROGRAM_POINT_SIZE" alias="GL_VERTEX_PROGRAM_POINT_SIZE"/>
+ <enum value="0x8642" name="GL_PROGRAM_POINT_SIZE_ARB"/>
+ <enum value="0x8642" name="GL_PROGRAM_POINT_SIZE_EXT"/>
+ <enum value="0x8643" name="GL_VERTEX_PROGRAM_TWO_SIDE"/>
+ <enum value="0x8643" name="GL_VERTEX_PROGRAM_TWO_SIDE_ARB"/>
+ <enum value="0x8643" name="GL_VERTEX_PROGRAM_TWO_SIDE_NV"/>
+ <enum value="0x8644" name="GL_PROGRAM_PARAMETER_NV"/>
+ <enum value="0x8645" name="GL_ATTRIB_ARRAY_POINTER_NV"/>
+ <enum value="0x8645" name="GL_VERTEX_ATTRIB_ARRAY_POINTER"/>
+ <enum value="0x8645" name="GL_VERTEX_ATTRIB_ARRAY_POINTER_ARB"/>
+ <enum value="0x8646" name="GL_PROGRAM_TARGET_NV"/>
+ <enum value="0x8647" name="GL_PROGRAM_RESIDENT_NV"/>
+ <enum value="0x8648" name="GL_TRACK_MATRIX_NV"/>
+ <enum value="0x8649" name="GL_TRACK_MATRIX_TRANSFORM_NV"/>
+ <enum value="0x864A" name="GL_VERTEX_PROGRAM_BINDING_NV"/>
+ <enum value="0x864B" name="GL_PROGRAM_ERROR_POSITION_ARB"/>
+ <enum value="0x864B" name="GL_PROGRAM_ERROR_POSITION_NV"/>
+ <enum value="0x864C" name="GL_OFFSET_TEXTURE_RECTANGLE_NV"/>
+ <enum value="0x864D" name="GL_OFFSET_TEXTURE_RECTANGLE_SCALE_NV"/>
+ <enum value="0x864E" name="GL_DOT_PRODUCT_TEXTURE_RECTANGLE_NV"/>
+ <enum value="0x864F" name="GL_DEPTH_CLAMP"/>
+ <enum value="0x864F" name="GL_DEPTH_CLAMP_NV"/>
+ <enum value="0x8650" name="GL_VERTEX_ATTRIB_ARRAY0_NV"/>
+ <enum value="0x8651" name="GL_VERTEX_ATTRIB_ARRAY1_NV"/>
+ <enum value="0x8652" name="GL_VERTEX_ATTRIB_ARRAY2_NV"/>
+ <enum value="0x8653" name="GL_VERTEX_ATTRIB_ARRAY3_NV"/>
+ <enum value="0x8654" name="GL_VERTEX_ATTRIB_ARRAY4_NV"/>
+ <enum value="0x8655" name="GL_VERTEX_ATTRIB_ARRAY5_NV"/>
+ <enum value="0x8656" name="GL_VERTEX_ATTRIB_ARRAY6_NV"/>
+ <enum value="0x8657" name="GL_VERTEX_ATTRIB_ARRAY7_NV"/>
+ <enum value="0x8658" name="GL_VERTEX_ATTRIB_ARRAY8_NV"/>
+ <enum value="0x8659" name="GL_VERTEX_ATTRIB_ARRAY9_NV"/>
+ <enum value="0x865A" name="GL_VERTEX_ATTRIB_ARRAY10_NV"/>
+ <enum value="0x865B" name="GL_VERTEX_ATTRIB_ARRAY11_NV"/>
+ <enum value="0x865C" name="GL_VERTEX_ATTRIB_ARRAY12_NV"/>
+ <enum value="0x865D" name="GL_VERTEX_ATTRIB_ARRAY13_NV"/>
+ <enum value="0x865E" name="GL_VERTEX_ATTRIB_ARRAY14_NV"/>
+ <enum value="0x865F" name="GL_VERTEX_ATTRIB_ARRAY15_NV"/>
+ <enum value="0x8660" name="GL_MAP1_VERTEX_ATTRIB0_4_NV"/>
+ <enum value="0x8661" name="GL_MAP1_VERTEX_ATTRIB1_4_NV"/>
+ <enum value="0x8662" name="GL_MAP1_VERTEX_ATTRIB2_4_NV"/>
+ <enum value="0x8663" name="GL_MAP1_VERTEX_ATTRIB3_4_NV"/>
+ <enum value="0x8664" name="GL_MAP1_VERTEX_ATTRIB4_4_NV"/>
+ <enum value="0x8665" name="GL_MAP1_VERTEX_ATTRIB5_4_NV"/>
+ <enum value="0x8666" name="GL_MAP1_VERTEX_ATTRIB6_4_NV"/>
+ <enum value="0x8667" name="GL_MAP1_VERTEX_ATTRIB7_4_NV"/>
+ <enum value="0x8668" name="GL_MAP1_VERTEX_ATTRIB8_4_NV"/>
+ <enum value="0x8669" name="GL_MAP1_VERTEX_ATTRIB9_4_NV"/>
+ <enum value="0x866A" name="GL_MAP1_VERTEX_ATTRIB10_4_NV"/>
+ <enum value="0x866B" name="GL_MAP1_VERTEX_ATTRIB11_4_NV"/>
+ <enum value="0x866C" name="GL_MAP1_VERTEX_ATTRIB12_4_NV"/>
+ <enum value="0x866D" name="GL_MAP1_VERTEX_ATTRIB13_4_NV"/>
+ <enum value="0x866E" name="GL_MAP1_VERTEX_ATTRIB14_4_NV"/>
+ <enum value="0x866F" name="GL_MAP1_VERTEX_ATTRIB15_4_NV"/>
+ <enum value="0x8670" name="GL_MAP2_VERTEX_ATTRIB0_4_NV"/>
+ <enum value="0x8671" name="GL_MAP2_VERTEX_ATTRIB1_4_NV"/>
+ <enum value="0x8672" name="GL_MAP2_VERTEX_ATTRIB2_4_NV"/>
+ <enum value="0x8673" name="GL_MAP2_VERTEX_ATTRIB3_4_NV"/>
+ <enum value="0x8674" name="GL_MAP2_VERTEX_ATTRIB4_4_NV"/>
+ <enum value="0x8675" name="GL_MAP2_VERTEX_ATTRIB5_4_NV"/>
+ <enum value="0x8676" name="GL_MAP2_VERTEX_ATTRIB6_4_NV"/>
+ <enum value="0x8677" name="GL_MAP2_VERTEX_ATTRIB7_4_NV"/>
+ <enum value="0x8677" name="GL_PROGRAM_BINDING_ARB" comment="NOT an alias. Accidental reuse of GL_MAP2_VERTEX_ATTRIB7_4_NV"/>
+ <enum value="0x8678" name="GL_MAP2_VERTEX_ATTRIB8_4_NV"/>
+ <enum value="0x8679" name="GL_MAP2_VERTEX_ATTRIB9_4_NV"/>
+ <enum value="0x867A" name="GL_MAP2_VERTEX_ATTRIB10_4_NV"/>
+ <enum value="0x867B" name="GL_MAP2_VERTEX_ATTRIB11_4_NV"/>
+ <enum value="0x867C" name="GL_MAP2_VERTEX_ATTRIB12_4_NV"/>
+ <enum value="0x867D" name="GL_MAP2_VERTEX_ATTRIB13_4_NV"/>
+ <enum value="0x867E" name="GL_MAP2_VERTEX_ATTRIB14_4_NV"/>
+ <enum value="0x867F" name="GL_MAP2_VERTEX_ATTRIB15_4_NV"/>
+ </enums>
+
+ <enums namespace="GL" start="0x8680" end="0x869F" vendor="Pixelfusion">
+ <unused start="0x8680" end="0x869F" vendor="Pixelfusion"/>
+ </enums>
+
+ <enums namespace="GL" start="0x86A0" end="0x86AF" vendor="ARB">
+ <enum value="0x86A0" name="GL_TEXTURE_COMPRESSED_IMAGE_SIZE"/>
+ <enum value="0x86A0" name="GL_TEXTURE_COMPRESSED_IMAGE_SIZE_ARB"/>
+ <enum value="0x86A1" name="GL_TEXTURE_COMPRESSED"/>
+ <enum value="0x86A1" name="GL_TEXTURE_COMPRESSED_ARB"/>
+ <enum value="0x86A2" name="GL_NUM_COMPRESSED_TEXTURE_FORMATS"/>
+ <enum value="0x86A2" name="GL_NUM_COMPRESSED_TEXTURE_FORMATS_ARB"/>
+ <enum value="0x86A3" name="GL_COMPRESSED_TEXTURE_FORMATS"/>
+ <enum value="0x86A3" name="GL_COMPRESSED_TEXTURE_FORMATS_ARB"/>
+ <enum value="0x86A4" name="GL_MAX_VERTEX_UNITS_ARB"/>
+ <enum value="0x86A4" name="GL_MAX_VERTEX_UNITS_OES"/>
+ <enum value="0x86A5" name="GL_ACTIVE_VERTEX_UNITS_ARB"/>
+ <enum value="0x86A6" name="GL_WEIGHT_SUM_UNITY_ARB"/>
+ <enum value="0x86A7" name="GL_VERTEX_BLEND_ARB"/>
+ <enum value="0x86A8" name="GL_CURRENT_WEIGHT_ARB"/>
+ <enum value="0x86A9" name="GL_WEIGHT_ARRAY_TYPE_ARB"/>
+ <enum value="0x86A9" name="GL_WEIGHT_ARRAY_TYPE_OES"/>
+ <enum value="0x86AA" name="GL_WEIGHT_ARRAY_STRIDE_ARB"/>
+ <enum value="0x86AA" name="GL_WEIGHT_ARRAY_STRIDE_OES"/>
+ <enum value="0x86AB" name="GL_WEIGHT_ARRAY_SIZE_ARB"/>
+ <enum value="0x86AB" name="GL_WEIGHT_ARRAY_SIZE_OES"/>
+ <enum value="0x86AC" name="GL_WEIGHT_ARRAY_POINTER_ARB"/>
+ <enum value="0x86AC" name="GL_WEIGHT_ARRAY_POINTER_OES"/>
+ <enum value="0x86AD" name="GL_WEIGHT_ARRAY_ARB"/>
+ <enum value="0x86AD" name="GL_WEIGHT_ARRAY_OES"/>
+ <enum value="0x86AE" name="GL_DOT3_RGB"/>
+ <enum value="0x86AE" name="GL_DOT3_RGB_ARB"/>
+ <enum value="0x86AF" name="GL_DOT3_RGBA"/>
+ <enum value="0x86AF" name="GL_DOT3_RGBA_ARB"/>
+ <enum value="0x86AF" name="GL_DOT3_RGBA_IMG"/>
+ </enums>
+
+ <enums namespace="GL" start="0x86B0" end="0x86BF" vendor="3DFX">
+ <enum value="0x86B0" name="GL_COMPRESSED_RGB_FXT1_3DFX"/>
+ <enum value="0x86B1" name="GL_COMPRESSED_RGBA_FXT1_3DFX"/>
+ <enum value="0x86B2" name="GL_MULTISAMPLE_3DFX"/>
+ <enum value="0x86B3" name="GL_SAMPLE_BUFFERS_3DFX"/>
+ <enum value="0x86B4" name="GL_SAMPLES_3DFX"/>
+ <unused start="0x86B5" end="0x86BF" vendor="3DFX"/>
+ </enums>
+
+ <enums namespace="GL" start="0x86C0" end="0x871F" vendor="NV">
+ <enum value="0x86C0" name="GL_EVAL_2D_NV"/>
+ <enum value="0x86C1" name="GL_EVAL_TRIANGULAR_2D_NV"/>
+ <enum value="0x86C2" name="GL_MAP_TESSELLATION_NV"/>
+ <enum value="0x86C3" name="GL_MAP_ATTRIB_U_ORDER_NV"/>
+ <enum value="0x86C4" name="GL_MAP_ATTRIB_V_ORDER_NV"/>
+ <enum value="0x86C5" name="GL_EVAL_FRACTIONAL_TESSELLATION_NV"/>
+ <enum value="0x86C6" name="GL_EVAL_VERTEX_ATTRIB0_NV"/>
+ <enum value="0x86C7" name="GL_EVAL_VERTEX_ATTRIB1_NV"/>
+ <enum value="0x86C8" name="GL_EVAL_VERTEX_ATTRIB2_NV"/>
+ <enum value="0x86C9" name="GL_EVAL_VERTEX_ATTRIB3_NV"/>
+ <enum value="0x86CA" name="GL_EVAL_VERTEX_ATTRIB4_NV"/>
+ <enum value="0x86CB" name="GL_EVAL_VERTEX_ATTRIB5_NV"/>
+ <enum value="0x86CC" name="GL_EVAL_VERTEX_ATTRIB6_NV"/>
+ <enum value="0x86CD" name="GL_EVAL_VERTEX_ATTRIB7_NV"/>
+ <enum value="0x86CE" name="GL_EVAL_VERTEX_ATTRIB8_NV"/>
+ <enum value="0x86CF" name="GL_EVAL_VERTEX_ATTRIB9_NV"/>
+ <enum value="0x86D0" name="GL_EVAL_VERTEX_ATTRIB10_NV"/>
+ <enum value="0x86D1" name="GL_EVAL_VERTEX_ATTRIB11_NV"/>
+ <enum value="0x86D2" name="GL_EVAL_VERTEX_ATTRIB12_NV"/>
+ <enum value="0x86D3" name="GL_EVAL_VERTEX_ATTRIB13_NV"/>
+ <enum value="0x86D4" name="GL_EVAL_VERTEX_ATTRIB14_NV"/>
+ <enum value="0x86D5" name="GL_EVAL_VERTEX_ATTRIB15_NV"/>
+ <enum value="0x86D6" name="GL_MAX_MAP_TESSELLATION_NV"/>
+ <enum value="0x86D7" name="GL_MAX_RATIONAL_EVAL_ORDER_NV"/>
+ <enum value="0x86D8" name="GL_MAX_PROGRAM_PATCH_ATTRIBS_NV"/>
+ <enum value="0x86D9" name="GL_RGBA_UNSIGNED_DOT_PRODUCT_MAPPING_NV"/>
+ <enum value="0x86DA" name="GL_UNSIGNED_INT_S8_S8_8_8_NV"/>
+ <enum value="0x86DB" name="GL_UNSIGNED_INT_8_8_S8_S8_REV_NV"/>
+ <enum value="0x86DC" name="GL_DSDT_MAG_INTENSITY_NV"/>
+ <enum value="0x86DD" name="GL_SHADER_CONSISTENT_NV"/>
+ <enum value="0x86DE" name="GL_TEXTURE_SHADER_NV"/>
+ <enum value="0x86DF" name="GL_SHADER_OPERATION_NV"/>
+ <enum value="0x86E0" name="GL_CULL_MODES_NV"/>
+ <enum value="0x86E1" name="GL_OFFSET_TEXTURE_MATRIX_NV"/>
+ <enum value="0x86E1" name="GL_OFFSET_TEXTURE_2D_MATRIX_NV" alias="GL_OFFSET_TEXTURE_MATRIX_NV"/>
+ <enum value="0x86E2" name="GL_OFFSET_TEXTURE_SCALE_NV"/>
+ <enum value="0x86E2" name="GL_OFFSET_TEXTURE_2D_SCALE_NV" alias="GL_OFFSET_TEXTURE_SCALE_NV"/>
+ <enum value="0x86E3" name="GL_OFFSET_TEXTURE_BIAS_NV"/>
+ <enum value="0x86E3" name="GL_OFFSET_TEXTURE_2D_BIAS_NV" alias="GL_OFFSET_TEXTURE_BIAS_NV"/>
+ <enum value="0x86E4" name="GL_PREVIOUS_TEXTURE_INPUT_NV"/>
+ <enum value="0x86E5" name="GL_CONST_EYE_NV"/>
+ <enum value="0x86E6" name="GL_PASS_THROUGH_NV"/>
+ <enum value="0x86E7" name="GL_CULL_FRAGMENT_NV"/>
+ <enum value="0x86E8" name="GL_OFFSET_TEXTURE_2D_NV"/>
+ <enum value="0x86E9" name="GL_DEPENDENT_AR_TEXTURE_2D_NV"/>
+ <enum value="0x86EA" name="GL_DEPENDENT_GB_TEXTURE_2D_NV"/>
+ <enum value="0x86EB" name="GL_SURFACE_STATE_NV"/>
+ <enum value="0x86EC" name="GL_DOT_PRODUCT_NV"/>
+ <enum value="0x86ED" name="GL_DOT_PRODUCT_DEPTH_REPLACE_NV"/>
+ <enum value="0x86EE" name="GL_DOT_PRODUCT_TEXTURE_2D_NV"/>
+ <enum value="0x86EF" name="GL_DOT_PRODUCT_TEXTURE_3D_NV"/>
+ <enum value="0x86F0" name="GL_DOT_PRODUCT_TEXTURE_CUBE_MAP_NV"/>
+ <enum value="0x86F1" name="GL_DOT_PRODUCT_DIFFUSE_CUBE_MAP_NV"/>
+ <enum value="0x86F2" name="GL_DOT_PRODUCT_REFLECT_CUBE_MAP_NV"/>
+ <enum value="0x86F3" name="GL_DOT_PRODUCT_CONST_EYE_REFLECT_CUBE_MAP_NV"/>
+ <enum value="0x86F4" name="GL_HILO_NV"/>
+ <enum value="0x86F5" name="GL_DSDT_NV"/>
+ <enum value="0x86F6" name="GL_DSDT_MAG_NV"/>
+ <enum value="0x86F7" name="GL_DSDT_MAG_VIB_NV"/>
+ <enum value="0x86F8" name="GL_HILO16_NV"/>
+ <enum value="0x86F9" name="GL_SIGNED_HILO_NV"/>
+ <enum value="0x86FA" name="GL_SIGNED_HILO16_NV"/>
+ <enum value="0x86FB" name="GL_SIGNED_RGBA_NV"/>
+ <enum value="0x86FC" name="GL_SIGNED_RGBA8_NV"/>
+ <enum value="0x86FD" name="GL_SURFACE_REGISTERED_NV"/>
+ <enum value="0x86FE" name="GL_SIGNED_RGB_NV"/>
+ <enum value="0x86FF" name="GL_SIGNED_RGB8_NV"/>
+ <enum value="0x8700" name="GL_SURFACE_MAPPED_NV"/>
+ <enum value="0x8701" name="GL_SIGNED_LUMINANCE_NV"/>
+ <enum value="0x8702" name="GL_SIGNED_LUMINANCE8_NV"/>
+ <enum value="0x8703" name="GL_SIGNED_LUMINANCE_ALPHA_NV"/>
+ <enum value="0x8704" name="GL_SIGNED_LUMINANCE8_ALPHA8_NV"/>
+ <enum value="0x8705" name="GL_SIGNED_ALPHA_NV"/>
+ <enum value="0x8706" name="GL_SIGNED_ALPHA8_NV"/>
+ <enum value="0x8707" name="GL_SIGNED_INTENSITY_NV"/>
+ <enum value="0x8708" name="GL_SIGNED_INTENSITY8_NV"/>
+ <enum value="0x8709" name="GL_DSDT8_NV"/>
+ <enum value="0x870A" name="GL_DSDT8_MAG8_NV"/>
+ <enum value="0x870B" name="GL_DSDT8_MAG8_INTENSITY8_NV"/>
+ <enum value="0x870C" name="GL_SIGNED_RGB_UNSIGNED_ALPHA_NV"/>
+ <enum value="0x870D" name="GL_SIGNED_RGB8_UNSIGNED_ALPHA8_NV"/>
+ <enum value="0x870E" name="GL_HI_SCALE_NV"/>
+ <enum value="0x870F" name="GL_LO_SCALE_NV"/>
+ <enum value="0x8710" name="GL_DS_SCALE_NV"/>
+ <enum value="0x8711" name="GL_DT_SCALE_NV"/>
+ <enum value="0x8712" name="GL_MAGNITUDE_SCALE_NV"/>
+ <enum value="0x8713" name="GL_VIBRANCE_SCALE_NV"/>
+ <enum value="0x8714" name="GL_HI_BIAS_NV"/>
+ <enum value="0x8715" name="GL_LO_BIAS_NV"/>
+ <enum value="0x8716" name="GL_DS_BIAS_NV"/>
+ <enum value="0x8717" name="GL_DT_BIAS_NV"/>
+ <enum value="0x8718" name="GL_MAGNITUDE_BIAS_NV"/>
+ <enum value="0x8719" name="GL_VIBRANCE_BIAS_NV"/>
+ <enum value="0x871A" name="GL_TEXTURE_BORDER_VALUES_NV"/>
+ <enum value="0x871B" name="GL_TEXTURE_HI_SIZE_NV"/>
+ <enum value="0x871C" name="GL_TEXTURE_LO_SIZE_NV"/>
+ <enum value="0x871D" name="GL_TEXTURE_DS_SIZE_NV"/>
+ <enum value="0x871E" name="GL_TEXTURE_DT_SIZE_NV"/>
+ <enum value="0x871F" name="GL_TEXTURE_MAG_SIZE_NV"/>
+ </enums>
+
+ <enums namespace="GL" start="0x8720" end="0x873F" vendor="ARB">
+ <unused start="0x8720" end="0x8721" comment="MODELVIEW0/1 already exist"/>
+ <enum value="0x8722" name="GL_MODELVIEW2_ARB"/>
+ <enum value="0x8723" name="GL_MODELVIEW3_ARB"/>
+ <enum value="0x8724" name="GL_MODELVIEW4_ARB"/>
+ <enum value="0x8725" name="GL_MODELVIEW5_ARB"/>
+ <enum value="0x8726" name="GL_MODELVIEW6_ARB"/>
+ <enum value="0x8727" name="GL_MODELVIEW7_ARB"/>
+ <enum value="0x8728" name="GL_MODELVIEW8_ARB"/>
+ <enum value="0x8729" name="GL_MODELVIEW9_ARB"/>
+ <enum value="0x872A" name="GL_MODELVIEW10_ARB"/>
+ <enum value="0x872B" name="GL_MODELVIEW11_ARB"/>
+ <enum value="0x872C" name="GL_MODELVIEW12_ARB"/>
+ <enum value="0x872D" name="GL_MODELVIEW13_ARB"/>
+ <enum value="0x872E" name="GL_MODELVIEW14_ARB"/>
+ <enum value="0x872F" name="GL_MODELVIEW15_ARB"/>
+ <enum value="0x8730" name="GL_MODELVIEW16_ARB"/>
+ <enum value="0x8731" name="GL_MODELVIEW17_ARB"/>
+ <enum value="0x8732" name="GL_MODELVIEW18_ARB"/>
+ <enum value="0x8733" name="GL_MODELVIEW19_ARB"/>
+ <enum value="0x8734" name="GL_MODELVIEW20_ARB"/>
+ <enum value="0x8735" name="GL_MODELVIEW21_ARB"/>
+ <enum value="0x8736" name="GL_MODELVIEW22_ARB"/>
+ <enum value="0x8737" name="GL_MODELVIEW23_ARB"/>
+ <enum value="0x8738" name="GL_MODELVIEW24_ARB"/>
+ <enum value="0x8739" name="GL_MODELVIEW25_ARB"/>
+ <enum value="0x873A" name="GL_MODELVIEW26_ARB"/>
+ <enum value="0x873B" name="GL_MODELVIEW27_ARB"/>
+ <enum value="0x873C" name="GL_MODELVIEW28_ARB"/>
+ <enum value="0x873D" name="GL_MODELVIEW29_ARB"/>
+ <enum value="0x873E" name="GL_MODELVIEW30_ARB"/>
+ <enum value="0x873F" name="GL_MODELVIEW31_ARB"/>
+ </enums>
+
+ <enums namespace="GL" start="0x8740" end="0x874F" vendor="AMD">
+ <enum value="0x8740" name="GL_DOT3_RGB_EXT"/>
+ <enum value="0x8740" name="GL_Z400_BINARY_AMD" comment="NOT an alias. Accidental reuse of GL_DOT3_RGB_EXT"/>
+ <enum value="0x8741" name="GL_DOT3_RGBA_EXT"/>
+ <enum value="0x8741" name="GL_PROGRAM_BINARY_LENGTH_OES" comment="NOT an alias. Accidental reuse of GL_DOT3_RGBA_EXT"/>
+ <enum value="0x8741" name="GL_PROGRAM_BINARY_LENGTH"/>
+ <enum value="0x8742" name="GL_MIRROR_CLAMP_ATI"/>
+ <enum value="0x8742" name="GL_MIRROR_CLAMP_EXT"/>
+ <enum value="0x8743" name="GL_MIRROR_CLAMP_TO_EDGE"/>
+ <enum value="0x8743" name="GL_MIRROR_CLAMP_TO_EDGE_ATI"/>
+ <enum value="0x8743" name="GL_MIRROR_CLAMP_TO_EDGE_EXT"/>
+ <enum value="0x8744" name="GL_MODULATE_ADD_ATI"/>
+ <enum value="0x8745" name="GL_MODULATE_SIGNED_ADD_ATI"/>
+ <enum value="0x8746" name="GL_MODULATE_SUBTRACT_ATI"/>
+ <unused start="0x8747" end="0x8749" vendor="AMD"/>
+ <enum value="0x874A" name="GL_SET_AMD"/>
+ <enum value="0x874B" name="GL_REPLACE_VALUE_AMD"/>
+ <enum value="0x874C" name="GL_STENCIL_OP_VALUE_AMD"/>
+ <enum value="0x874D" name="GL_STENCIL_BACK_OP_VALUE_AMD"/>
+ <enum value="0x874E" name="GL_VERTEX_ATTRIB_ARRAY_LONG"/>
+ <enum value="0x874F" name="GL_OCCLUSION_QUERY_EVENT_MASK_AMD"/>
+ </enums>
+
+ <enums namespace="GL" start="0x8750" end="0x875F" vendor="MESA">
+ <enum value="0x8750" name="GL_DEPTH_STENCIL_MESA"/>
+ <enum value="0x8751" name="GL_UNSIGNED_INT_24_8_MESA"/>
+ <enum value="0x8752" name="GL_UNSIGNED_INT_8_24_REV_MESA"/>
+ <enum value="0x8753" name="GL_UNSIGNED_SHORT_15_1_MESA"/>
+ <enum value="0x8754" name="GL_UNSIGNED_SHORT_1_15_REV_MESA"/>
+ <enum value="0x8755" name="GL_TRACE_MASK_MESA"/>
+ <enum value="0x8756" name="GL_TRACE_NAME_MESA"/>
+ <enum value="0x8757" name="GL_YCBCR_MESA"/>
+ <enum value="0x8758" name="GL_PACK_INVERT_MESA"/>
+ <enum value="0x8759" name="GL_DEBUG_OBJECT_MESA" comment="NOT an alias. Accidental reuse of GL_TEXTURE_1D_STACK_MESAX"/>
+ <enum value="0x8759" name="GL_TEXTURE_1D_STACK_MESAX"/>
+ <enum value="0x875A" name="GL_DEBUG_PRINT_MESA" comment="NOT an alias. Accidental reuse of GL_TEXTURE_2D_STACK_MESAX"/>
+ <enum value="0x875A" name="GL_TEXTURE_2D_STACK_MESAX"/>
+ <enum value="0x875B" name="GL_DEBUG_ASSERT_MESA" comment="NOT an alias. Accidental reuse of GL_PROXY_TEXTURE_1D_STACK_MESAX"/>
+ <enum value="0x875B" name="GL_PROXY_TEXTURE_1D_STACK_MESAX"/>
+ <enum value="0x875C" name="GL_PROXY_TEXTURE_2D_STACK_MESAX"/>
+ <enum value="0x875D" name="GL_TEXTURE_1D_STACK_BINDING_MESAX"/>
+ <enum value="0x875E" name="GL_TEXTURE_2D_STACK_BINDING_MESAX"/>
+ <unused start="0x875F" vendor="MESA"/>
+ </enums>
+
+ <enums namespace="GL" start="0x8760" end="0x883F" vendor="AMD">
+ <enum value="0x8760" name="GL_STATIC_ATI"/>
+ <enum value="0x8761" name="GL_DYNAMIC_ATI"/>
+ <enum value="0x8762" name="GL_PRESERVE_ATI"/>
+ <enum value="0x8763" name="GL_DISCARD_ATI"/>
+ <enum value="0x8764" name="GL_BUFFER_SIZE"/>
+ <enum value="0x8764" name="GL_BUFFER_SIZE_ARB"/>
+ <enum value="0x8764" name="GL_OBJECT_BUFFER_SIZE_ATI"/>
+ <enum value="0x8765" name="GL_BUFFER_USAGE"/>
+ <enum value="0x8765" name="GL_BUFFER_USAGE_ARB"/>
+ <enum value="0x8765" name="GL_OBJECT_BUFFER_USAGE_ATI"/>
+ <enum value="0x8766" name="GL_ARRAY_OBJECT_BUFFER_ATI"/>
+ <enum value="0x8767" name="GL_ARRAY_OBJECT_OFFSET_ATI"/>
+ <enum value="0x8768" name="GL_ELEMENT_ARRAY_ATI"/>
+ <enum value="0x8769" name="GL_ELEMENT_ARRAY_TYPE_ATI"/>
+ <enum value="0x876A" name="GL_ELEMENT_ARRAY_POINTER_ATI"/>
+ <enum value="0x876B" name="GL_MAX_VERTEX_STREAMS_ATI"/>
+ <enum value="0x876C" name="GL_VERTEX_STREAM0_ATI"/>
+ <enum value="0x876D" name="GL_VERTEX_STREAM1_ATI"/>
+ <enum value="0x876E" name="GL_VERTEX_STREAM2_ATI"/>
+ <enum value="0x876F" name="GL_VERTEX_STREAM3_ATI"/>
+ <enum value="0x8770" name="GL_VERTEX_STREAM4_ATI"/>
+ <enum value="0x8771" name="GL_VERTEX_STREAM5_ATI"/>
+ <enum value="0x8772" name="GL_VERTEX_STREAM6_ATI"/>
+ <enum value="0x8773" name="GL_VERTEX_STREAM7_ATI"/>
+ <enum value="0x8774" name="GL_VERTEX_SOURCE_ATI"/>
+ <enum value="0x8775" name="GL_BUMP_ROT_MATRIX_ATI"/>
+ <enum value="0x8776" name="GL_BUMP_ROT_MATRIX_SIZE_ATI"/>
+ <enum value="0x8777" name="GL_BUMP_NUM_TEX_UNITS_ATI"/>
+ <enum value="0x8778" name="GL_BUMP_TEX_UNITS_ATI"/>
+ <enum value="0x8779" name="GL_DUDV_ATI"/>
+ <enum value="0x877A" name="GL_DU8DV8_ATI"/>
+ <enum value="0x877B" name="GL_BUMP_ENVMAP_ATI"/>
+ <enum value="0x877C" name="GL_BUMP_TARGET_ATI"/>
+ <unused start="0x877D" end="0x877F" vendor="AMD"/>
+ <enum value="0x8780" name="GL_VERTEX_SHADER_EXT"/>
+ <enum value="0x8781" name="GL_VERTEX_SHADER_BINDING_EXT"/>
+ <enum value="0x8782" name="GL_OP_INDEX_EXT"/>
+ <enum value="0x8783" name="GL_OP_NEGATE_EXT"/>
+ <enum value="0x8784" name="GL_OP_DOT3_EXT"/>
+ <enum value="0x8785" name="GL_OP_DOT4_EXT"/>
+ <enum value="0x8786" name="GL_OP_MUL_EXT"/>
+ <enum value="0x8787" name="GL_OP_ADD_EXT"/>
+ <enum value="0x8788" name="GL_OP_MADD_EXT"/>
+ <enum value="0x8789" name="GL_OP_FRAC_EXT"/>
+ <enum value="0x878A" name="GL_OP_MAX_EXT"/>
+ <enum value="0x878B" name="GL_OP_MIN_EXT"/>
+ <enum value="0x878C" name="GL_OP_SET_GE_EXT"/>
+ <enum value="0x878D" name="GL_OP_SET_LT_EXT"/>
+ <enum value="0x878E" name="GL_OP_CLAMP_EXT"/>
+ <enum value="0x878F" name="GL_OP_FLOOR_EXT"/>
+ <enum value="0x8790" name="GL_OP_ROUND_EXT"/>
+ <enum value="0x8791" name="GL_OP_EXP_BASE_2_EXT"/>
+ <enum value="0x8792" name="GL_OP_LOG_BASE_2_EXT"/>
+ <enum value="0x8793" name="GL_OP_POWER_EXT"/>
+ <enum value="0x8794" name="GL_OP_RECIP_EXT"/>
+ <enum value="0x8795" name="GL_OP_RECIP_SQRT_EXT"/>
+ <enum value="0x8796" name="GL_OP_SUB_EXT"/>
+ <enum value="0x8797" name="GL_OP_CROSS_PRODUCT_EXT"/>
+ <enum value="0x8798" name="GL_OP_MULTIPLY_MATRIX_EXT"/>
+ <enum value="0x8799" name="GL_OP_MOV_EXT"/>
+ <enum value="0x879A" name="GL_OUTPUT_VERTEX_EXT"/>
+ <enum value="0x879B" name="GL_OUTPUT_COLOR0_EXT"/>
+ <enum value="0x879C" name="GL_OUTPUT_COLOR1_EXT"/>
+ <enum value="0x879D" name="GL_OUTPUT_TEXTURE_COORD0_EXT"/>
+ <enum value="0x879E" name="GL_OUTPUT_TEXTURE_COORD1_EXT"/>
+ <enum value="0x879F" name="GL_OUTPUT_TEXTURE_COORD2_EXT"/>
+ <enum value="0x87A0" name="GL_OUTPUT_TEXTURE_COORD3_EXT"/>
+ <enum value="0x87A1" name="GL_OUTPUT_TEXTURE_COORD4_EXT"/>
+ <enum value="0x87A2" name="GL_OUTPUT_TEXTURE_COORD5_EXT"/>
+ <enum value="0x87A3" name="GL_OUTPUT_TEXTURE_COORD6_EXT"/>
+ <enum value="0x87A4" name="GL_OUTPUT_TEXTURE_COORD7_EXT"/>
+ <enum value="0x87A5" name="GL_OUTPUT_TEXTURE_COORD8_EXT"/>
+ <enum value="0x87A6" name="GL_OUTPUT_TEXTURE_COORD9_EXT"/>
+ <enum value="0x87A7" name="GL_OUTPUT_TEXTURE_COORD10_EXT"/>
+ <enum value="0x87A8" name="GL_OUTPUT_TEXTURE_COORD11_EXT"/>
+ <enum value="0x87A9" name="GL_OUTPUT_TEXTURE_COORD12_EXT"/>
+ <enum value="0x87AA" name="GL_OUTPUT_TEXTURE_COORD13_EXT"/>
+ <enum value="0x87AB" name="GL_OUTPUT_TEXTURE_COORD14_EXT"/>
+ <enum value="0x87AC" name="GL_OUTPUT_TEXTURE_COORD15_EXT"/>
+ <enum value="0x87AD" name="GL_OUTPUT_TEXTURE_COORD16_EXT"/>
+ <enum value="0x87AE" name="GL_OUTPUT_TEXTURE_COORD17_EXT"/>
+ <enum value="0x87AF" name="GL_OUTPUT_TEXTURE_COORD18_EXT"/>
+ <enum value="0x87B0" name="GL_OUTPUT_TEXTURE_COORD19_EXT"/>
+ <enum value="0x87B1" name="GL_OUTPUT_TEXTURE_COORD20_EXT"/>
+ <enum value="0x87B2" name="GL_OUTPUT_TEXTURE_COORD21_EXT"/>
+ <enum value="0x87B3" name="GL_OUTPUT_TEXTURE_COORD22_EXT"/>
+ <enum value="0x87B4" name="GL_OUTPUT_TEXTURE_COORD23_EXT"/>
+ <enum value="0x87B5" name="GL_OUTPUT_TEXTURE_COORD24_EXT"/>
+ <enum value="0x87B6" name="GL_OUTPUT_TEXTURE_COORD25_EXT"/>
+ <enum value="0x87B7" name="GL_OUTPUT_TEXTURE_COORD26_EXT"/>
+ <enum value="0x87B8" name="GL_OUTPUT_TEXTURE_COORD27_EXT"/>
+ <enum value="0x87B9" name="GL_OUTPUT_TEXTURE_COORD28_EXT"/>
+ <enum value="0x87BA" name="GL_OUTPUT_TEXTURE_COORD29_EXT"/>
+ <enum value="0x87BB" name="GL_OUTPUT_TEXTURE_COORD30_EXT"/>
+ <enum value="0x87BC" name="GL_OUTPUT_TEXTURE_COORD31_EXT"/>
+ <enum value="0x87BD" name="GL_OUTPUT_FOG_EXT"/>
+ <enum value="0x87BE" name="GL_SCALAR_EXT"/>
+ <enum value="0x87BF" name="GL_VECTOR_EXT"/>
+ <enum value="0x87C0" name="GL_MATRIX_EXT"/>
+ <enum value="0x87C1" name="GL_VARIANT_EXT"/>
+ <enum value="0x87C2" name="GL_INVARIANT_EXT"/>
+ <enum value="0x87C3" name="GL_LOCAL_CONSTANT_EXT"/>
+ <enum value="0x87C4" name="GL_LOCAL_EXT"/>
+ <enum value="0x87C5" name="GL_MAX_VERTEX_SHADER_INSTRUCTIONS_EXT"/>
+ <enum value="0x87C6" name="GL_MAX_VERTEX_SHADER_VARIANTS_EXT"/>
+ <enum value="0x87C7" name="GL_MAX_VERTEX_SHADER_INVARIANTS_EXT"/>
+ <enum value="0x87C8" name="GL_MAX_VERTEX_SHADER_LOCAL_CONSTANTS_EXT"/>
+ <enum value="0x87C9" name="GL_MAX_VERTEX_SHADER_LOCALS_EXT"/>
+ <enum value="0x87CA" name="GL_MAX_OPTIMIZED_VERTEX_SHADER_INSTRUCTIONS_EXT"/>
+ <enum value="0x87CB" name="GL_MAX_OPTIMIZED_VERTEX_SHADER_VARIANTS_EXT"/>
+ <enum value="0x87CC" name="GL_MAX_OPTIMIZED_VERTEX_SHADER_LOCAL_CONSTANTS_EXT"/>
+ <enum value="0x87CD" name="GL_MAX_OPTIMIZED_VERTEX_SHADER_INVARIANTS_EXT"/>
+ <enum value="0x87CE" name="GL_MAX_OPTIMIZED_VERTEX_SHADER_LOCALS_EXT"/>
+ <enum value="0x87CF" name="GL_VERTEX_SHADER_INSTRUCTIONS_EXT"/>
+ <enum value="0x87D0" name="GL_VERTEX_SHADER_VARIANTS_EXT"/>
+ <enum value="0x87D1" name="GL_VERTEX_SHADER_INVARIANTS_EXT"/>
+ <enum value="0x87D2" name="GL_VERTEX_SHADER_LOCAL_CONSTANTS_EXT"/>
+ <enum value="0x87D3" name="GL_VERTEX_SHADER_LOCALS_EXT"/>
+ <enum value="0x87D4" name="GL_VERTEX_SHADER_OPTIMIZED_EXT"/>
+ <enum value="0x87D5" name="GL_X_EXT"/>
+ <enum value="0x87D6" name="GL_Y_EXT"/>
+ <enum value="0x87D7" name="GL_Z_EXT"/>
+ <enum value="0x87D8" name="GL_W_EXT"/>
+ <enum value="0x87D9" name="GL_NEGATIVE_X_EXT"/>
+ <enum value="0x87DA" name="GL_NEGATIVE_Y_EXT"/>
+ <enum value="0x87DB" name="GL_NEGATIVE_Z_EXT"/>
+ <enum value="0x87DC" name="GL_NEGATIVE_W_EXT"/>
+ <enum value="0x87DD" name="GL_ZERO_EXT"/>
+ <enum value="0x87DE" name="GL_ONE_EXT"/>
+ <enum value="0x87DF" name="GL_NEGATIVE_ONE_EXT"/>
+ <enum value="0x87E0" name="GL_NORMALIZED_RANGE_EXT"/>
+ <enum value="0x87E1" name="GL_FULL_RANGE_EXT"/>
+ <enum value="0x87E2" name="GL_CURRENT_VERTEX_EXT"/>
+ <enum value="0x87E3" name="GL_MVP_MATRIX_EXT"/>
+ <enum value="0x87E4" name="GL_VARIANT_VALUE_EXT"/>
+ <enum value="0x87E5" name="GL_VARIANT_DATATYPE_EXT"/>
+ <enum value="0x87E6" name="GL_VARIANT_ARRAY_STRIDE_EXT"/>
+ <enum value="0x87E7" name="GL_VARIANT_ARRAY_TYPE_EXT"/>
+ <enum value="0x87E8" name="GL_VARIANT_ARRAY_EXT"/>
+ <enum value="0x87E9" name="GL_VARIANT_ARRAY_POINTER_EXT"/>
+ <enum value="0x87EA" name="GL_INVARIANT_VALUE_EXT"/>
+ <enum value="0x87EB" name="GL_INVARIANT_DATATYPE_EXT"/>
+ <enum value="0x87EC" name="GL_LOCAL_CONSTANT_VALUE_EXT"/>
+ <enum value="0x87ED" name="GL_LOCAL_CONSTANT_DATATYPE_EXT"/>
+ <enum value="0x87EE" name="GL_ATC_RGBA_INTERPOLATED_ALPHA_AMD"/>
+ <enum value="0x87F0" name="GL_PN_TRIANGLES_ATI"/>
+ <enum value="0x87F1" name="GL_MAX_PN_TRIANGLES_TESSELATION_LEVEL_ATI"/>
+ <enum value="0x87F2" name="GL_PN_TRIANGLES_POINT_MODE_ATI"/>
+ <enum value="0x87F3" name="GL_PN_TRIANGLES_NORMAL_MODE_ATI"/>
+ <enum value="0x87F4" name="GL_PN_TRIANGLES_TESSELATION_LEVEL_ATI"/>
+ <enum value="0x87F5" name="GL_PN_TRIANGLES_POINT_MODE_LINEAR_ATI"/>
+ <enum value="0x87F6" name="GL_PN_TRIANGLES_POINT_MODE_CUBIC_ATI"/>
+ <enum value="0x87F7" name="GL_PN_TRIANGLES_NORMAL_MODE_LINEAR_ATI"/>
+ <enum value="0x87F8" name="GL_PN_TRIANGLES_NORMAL_MODE_QUADRATIC_ATI"/>
+ <enum value="0x87F9" name="GL_3DC_X_AMD"/>
+ <enum value="0x87FA" name="GL_3DC_XY_AMD"/>
+ <enum value="0x87FB" name="GL_VBO_FREE_MEMORY_ATI"/>
+ <enum value="0x87FC" name="GL_TEXTURE_FREE_MEMORY_ATI"/>
+ <enum value="0x87FD" name="GL_RENDERBUFFER_FREE_MEMORY_ATI"/>
+ <enum value="0x87FE" name="GL_NUM_PROGRAM_BINARY_FORMATS"/>
+ <enum value="0x87FE" name="GL_NUM_PROGRAM_BINARY_FORMATS_OES"/>
+ <enum value="0x87FF" name="GL_PROGRAM_BINARY_FORMATS"/>
+ <enum value="0x87FF" name="GL_PROGRAM_BINARY_FORMATS_OES"/>
+ <enum value="0x8800" name="GL_STENCIL_BACK_FUNC"/>
+ <enum value="0x8800" name="GL_STENCIL_BACK_FUNC_ATI"/>
+ <enum value="0x8801" name="GL_STENCIL_BACK_FAIL"/>
+ <enum value="0x8801" name="GL_STENCIL_BACK_FAIL_ATI"/>
+ <enum value="0x8802" name="GL_STENCIL_BACK_PASS_DEPTH_FAIL"/>
+ <enum value="0x8802" name="GL_STENCIL_BACK_PASS_DEPTH_FAIL_ATI"/>
+ <enum value="0x8803" name="GL_STENCIL_BACK_PASS_DEPTH_PASS"/>
+ <enum value="0x8803" name="GL_STENCIL_BACK_PASS_DEPTH_PASS_ATI"/>
+ <enum value="0x8804" name="GL_FRAGMENT_PROGRAM_ARB"/>
+ <enum value="0x8805" name="GL_PROGRAM_ALU_INSTRUCTIONS_ARB"/>
+ <enum value="0x8806" name="GL_PROGRAM_TEX_INSTRUCTIONS_ARB"/>
+ <enum value="0x8807" name="GL_PROGRAM_TEX_INDIRECTIONS_ARB"/>
+ <enum value="0x8808" name="GL_PROGRAM_NATIVE_ALU_INSTRUCTIONS_ARB"/>
+ <enum value="0x8809" name="GL_PROGRAM_NATIVE_TEX_INSTRUCTIONS_ARB"/>
+ <enum value="0x880A" name="GL_PROGRAM_NATIVE_TEX_INDIRECTIONS_ARB"/>
+ <enum value="0x880B" name="GL_MAX_PROGRAM_ALU_INSTRUCTIONS_ARB"/>
+ <enum value="0x880C" name="GL_MAX_PROGRAM_TEX_INSTRUCTIONS_ARB"/>
+ <enum value="0x880D" name="GL_MAX_PROGRAM_TEX_INDIRECTIONS_ARB"/>
+ <enum value="0x880E" name="GL_MAX_PROGRAM_NATIVE_ALU_INSTRUCTIONS_ARB"/>
+ <enum value="0x880F" name="GL_MAX_PROGRAM_NATIVE_TEX_INSTRUCTIONS_ARB"/>
+ <enum value="0x8810" name="GL_MAX_PROGRAM_NATIVE_TEX_INDIRECTIONS_ARB"/>
+ <unused start="0x8811" end="0x8813" vendor="AMD"/>
+ <enum value="0x8814" name="GL_RGBA32F"/>
+ <enum value="0x8814" name="GL_RGBA32F_ARB"/>
+ <enum value="0x8814" name="GL_RGBA32F_EXT"/>
+ <enum value="0x8814" name="GL_RGBA_FLOAT32_APPLE"/>
+ <enum value="0x8814" name="GL_RGBA_FLOAT32_ATI"/>
+ <enum value="0x8815" name="GL_RGB32F"/>
+ <enum value="0x8815" name="GL_RGB32F_ARB"/>
+ <enum value="0x8815" name="GL_RGB32F_EXT"/>
+ <enum value="0x8815" name="GL_RGB_FLOAT32_APPLE"/>
+ <enum value="0x8815" name="GL_RGB_FLOAT32_ATI"/>
+ <enum value="0x8816" name="GL_ALPHA32F_ARB"/>
+ <enum value="0x8816" name="GL_ALPHA32F_EXT"/>
+ <enum value="0x8816" name="GL_ALPHA_FLOAT32_APPLE"/>
+ <enum value="0x8816" name="GL_ALPHA_FLOAT32_ATI"/>
+ <enum value="0x8817" name="GL_INTENSITY32F_ARB"/>
+ <enum value="0x8817" name="GL_INTENSITY_FLOAT32_APPLE"/>
+ <enum value="0x8817" name="GL_INTENSITY_FLOAT32_ATI"/>
+ <enum value="0x8818" name="GL_LUMINANCE32F_ARB"/>
+ <enum value="0x8818" name="GL_LUMINANCE32F_EXT"/>
+ <enum value="0x8818" name="GL_LUMINANCE_FLOAT32_APPLE"/>
+ <enum value="0x8818" name="GL_LUMINANCE_FLOAT32_ATI"/>
+ <enum value="0x8819" name="GL_LUMINANCE_ALPHA32F_ARB"/>
+ <enum value="0x8819" name="GL_LUMINANCE_ALPHA32F_EXT"/>
+ <enum value="0x8819" name="GL_LUMINANCE_ALPHA_FLOAT32_APPLE"/>
+ <enum value="0x8819" name="GL_LUMINANCE_ALPHA_FLOAT32_ATI"/>
+ <enum value="0x881A" name="GL_RGBA16F"/>
+ <enum value="0x881A" name="GL_RGBA16F_ARB"/>
+ <enum value="0x881A" name="GL_RGBA16F_EXT"/>
+ <enum value="0x881A" name="GL_RGBA_FLOAT16_APPLE"/>
+ <enum value="0x881A" name="GL_RGBA_FLOAT16_ATI"/>
+ <enum value="0x881B" name="GL_RGB16F"/>
+ <enum value="0x881B" name="GL_RGB16F_ARB"/>
+ <enum value="0x881B" name="GL_RGB16F_EXT"/>
+ <enum value="0x881B" name="GL_RGB_FLOAT16_APPLE"/>
+ <enum value="0x881B" name="GL_RGB_FLOAT16_ATI"/>
+ <enum value="0x881C" name="GL_ALPHA16F_ARB"/>
+ <enum value="0x881C" name="GL_ALPHA16F_EXT"/>
+ <enum value="0x881C" name="GL_ALPHA_FLOAT16_APPLE"/>
+ <enum value="0x881C" name="GL_ALPHA_FLOAT16_ATI"/>
+ <enum value="0x881D" name="GL_INTENSITY16F_ARB"/>
+ <enum value="0x881D" name="GL_INTENSITY_FLOAT16_APPLE"/>
+ <enum value="0x881D" name="GL_INTENSITY_FLOAT16_ATI"/>
+ <enum value="0x881E" name="GL_LUMINANCE16F_ARB"/>
+ <enum value="0x881E" name="GL_LUMINANCE16F_EXT"/>
+ <enum value="0x881E" name="GL_LUMINANCE_FLOAT16_APPLE"/>
+ <enum value="0x881E" name="GL_LUMINANCE_FLOAT16_ATI"/>
+ <enum value="0x881F" name="GL_LUMINANCE_ALPHA16F_ARB"/>
+ <enum value="0x881F" name="GL_LUMINANCE_ALPHA16F_EXT"/>
+ <enum value="0x881F" name="GL_LUMINANCE_ALPHA_FLOAT16_APPLE"/>
+ <enum value="0x881F" name="GL_LUMINANCE_ALPHA_FLOAT16_ATI"/>
+ <!-- RGBA_FLOAT_MODE_ARB equivalent to TYPE_RGBA_FLOAT_ATI -->
+ <enum value="0x8820" name="GL_RGBA_FLOAT_MODE_ARB"/>
+ <enum value="0x8820" name="GL_RGBA_FLOAT_MODE_ATI"/>
+ <unused start="0x8821" end="0x8822" vendor="AMD"/>
+ <enum value="0x8823" name="GL_WRITEONLY_RENDERING_QCOM"/>
+ <enum value="0x8824" name="GL_MAX_DRAW_BUFFERS"/>
+ <enum value="0x8824" name="GL_MAX_DRAW_BUFFERS_ARB"/>
+ <enum value="0x8824" name="GL_MAX_DRAW_BUFFERS_ATI"/>
+ <enum value="0x8824" name="GL_MAX_DRAW_BUFFERS_EXT"/>
+ <enum value="0x8824" name="GL_MAX_DRAW_BUFFERS_NV"/>
+ <enum value="0x8825" name="GL_DRAW_BUFFER0"/>
+ <enum value="0x8825" name="GL_DRAW_BUFFER0_ARB"/>
+ <enum value="0x8825" name="GL_DRAW_BUFFER0_ATI"/>
+ <enum value="0x8825" name="GL_DRAW_BUFFER0_EXT"/>
+ <enum value="0x8825" name="GL_DRAW_BUFFER0_NV"/>
+ <enum value="0x8826" name="GL_DRAW_BUFFER1"/>
+ <enum value="0x8826" name="GL_DRAW_BUFFER1_ARB"/>
+ <enum value="0x8826" name="GL_DRAW_BUFFER1_ATI"/>
+ <enum value="0x8826" name="GL_DRAW_BUFFER1_EXT"/>
+ <enum value="0x8826" name="GL_DRAW_BUFFER1_NV"/>
+ <enum value="0x8827" name="GL_DRAW_BUFFER2"/>
+ <enum value="0x8827" name="GL_DRAW_BUFFER2_ARB"/>
+ <enum value="0x8827" name="GL_DRAW_BUFFER2_ATI"/>
+ <enum value="0x8827" name="GL_DRAW_BUFFER2_EXT"/>
+ <enum value="0x8827" name="GL_DRAW_BUFFER2_NV"/>
+ <enum value="0x8828" name="GL_DRAW_BUFFER3"/>
+ <enum value="0x8828" name="GL_DRAW_BUFFER3_ARB"/>
+ <enum value="0x8828" name="GL_DRAW_BUFFER3_ATI"/>
+ <enum value="0x8828" name="GL_DRAW_BUFFER3_EXT"/>
+ <enum value="0x8828" name="GL_DRAW_BUFFER3_NV"/>
+ <enum value="0x8829" name="GL_DRAW_BUFFER4"/>
+ <enum value="0x8829" name="GL_DRAW_BUFFER4_ARB"/>
+ <enum value="0x8829" name="GL_DRAW_BUFFER4_ATI"/>
+ <enum value="0x8829" name="GL_DRAW_BUFFER4_EXT"/>
+ <enum value="0x8829" name="GL_DRAW_BUFFER4_NV"/>
+ <enum value="0x882A" name="GL_DRAW_BUFFER5"/>
+ <enum value="0x882A" name="GL_DRAW_BUFFER5_ARB"/>
+ <enum value="0x882A" name="GL_DRAW_BUFFER5_ATI"/>
+ <enum value="0x882A" name="GL_DRAW_BUFFER5_EXT"/>
+ <enum value="0x882A" name="GL_DRAW_BUFFER5_NV"/>
+ <enum value="0x882B" name="GL_DRAW_BUFFER6"/>
+ <enum value="0x882B" name="GL_DRAW_BUFFER6_ARB"/>
+ <enum value="0x882B" name="GL_DRAW_BUFFER6_ATI"/>
+ <enum value="0x882B" name="GL_DRAW_BUFFER6_EXT"/>
+ <enum value="0x882B" name="GL_DRAW_BUFFER6_NV"/>
+ <enum value="0x882C" name="GL_DRAW_BUFFER7"/>
+ <enum value="0x882C" name="GL_DRAW_BUFFER7_ARB"/>
+ <enum value="0x882C" name="GL_DRAW_BUFFER7_ATI"/>
+ <enum value="0x882C" name="GL_DRAW_BUFFER7_EXT"/>
+ <enum value="0x882C" name="GL_DRAW_BUFFER7_NV"/>
+ <enum value="0x882D" name="GL_DRAW_BUFFER8"/>
+ <enum value="0x882D" name="GL_DRAW_BUFFER8_ARB"/>
+ <enum value="0x882D" name="GL_DRAW_BUFFER8_ATI"/>
+ <enum value="0x882D" name="GL_DRAW_BUFFER8_EXT"/>
+ <enum value="0x882D" name="GL_DRAW_BUFFER8_NV"/>
+ <enum value="0x882E" name="GL_DRAW_BUFFER9"/>
+ <enum value="0x882E" name="GL_DRAW_BUFFER9_ARB"/>
+ <enum value="0x882E" name="GL_DRAW_BUFFER9_ATI"/>
+ <enum value="0x882E" name="GL_DRAW_BUFFER9_EXT"/>
+ <enum value="0x882E" name="GL_DRAW_BUFFER9_NV"/>
+ <enum value="0x882F" name="GL_DRAW_BUFFER10"/>
+ <enum value="0x882F" name="GL_DRAW_BUFFER10_ARB"/>
+ <enum value="0x882F" name="GL_DRAW_BUFFER10_ATI"/>
+ <enum value="0x882F" name="GL_DRAW_BUFFER10_EXT"/>
+ <enum value="0x882F" name="GL_DRAW_BUFFER10_NV"/>
+ <enum value="0x8830" name="GL_DRAW_BUFFER11"/>
+ <enum value="0x8830" name="GL_DRAW_BUFFER11_ARB"/>
+ <enum value="0x8830" name="GL_DRAW_BUFFER11_ATI"/>
+ <enum value="0x8830" name="GL_DRAW_BUFFER11_EXT"/>
+ <enum value="0x8830" name="GL_DRAW_BUFFER11_NV"/>
+ <enum value="0x8831" name="GL_DRAW_BUFFER12"/>
+ <enum value="0x8831" name="GL_DRAW_BUFFER12_ARB"/>
+ <enum value="0x8831" name="GL_DRAW_BUFFER12_ATI"/>
+ <enum value="0x8831" name="GL_DRAW_BUFFER12_EXT"/>
+ <enum value="0x8831" name="GL_DRAW_BUFFER12_NV"/>
+ <enum value="0x8832" name="GL_DRAW_BUFFER13"/>
+ <enum value="0x8832" name="GL_DRAW_BUFFER13_ARB"/>
+ <enum value="0x8832" name="GL_DRAW_BUFFER13_ATI"/>
+ <enum value="0x8832" name="GL_DRAW_BUFFER13_EXT"/>
+ <enum value="0x8832" name="GL_DRAW_BUFFER13_NV"/>
+ <enum value="0x8833" name="GL_DRAW_BUFFER14"/>
+ <enum value="0x8833" name="GL_DRAW_BUFFER14_ARB"/>
+ <enum value="0x8833" name="GL_DRAW_BUFFER14_ATI"/>
+ <enum value="0x8833" name="GL_DRAW_BUFFER14_EXT"/>
+ <enum value="0x8833" name="GL_DRAW_BUFFER14_NV"/>
+ <enum value="0x8834" name="GL_DRAW_BUFFER15"/>
+ <enum value="0x8834" name="GL_DRAW_BUFFER15_ARB"/>
+ <enum value="0x8834" name="GL_DRAW_BUFFER15_ATI"/>
+ <enum value="0x8834" name="GL_DRAW_BUFFER15_EXT"/>
+ <enum value="0x8834" name="GL_DRAW_BUFFER15_NV"/>
+ <enum value="0x8835" name="GL_COLOR_CLEAR_UNCLAMPED_VALUE_ATI"/>
+ <unused start="0x8836" vendor="AMD"/>
+ <enum value="0x8837" name="GL_COMPRESSED_LUMINANCE_ALPHA_3DC_ATI" comment="Defined by Mesa but not ATI"/>
+ <unused start="0x8838" end="0x883C" vendor="AMD"/>
+ <enum value="0x883D" name="GL_BLEND_EQUATION_ALPHA"/>
+ <enum value="0x883D" name="GL_BLEND_EQUATION_ALPHA_EXT"/>
+ <enum value="0x883D" name="GL_BLEND_EQUATION_ALPHA_OES"/>
+ <unused start="0x883E" vendor="AMD"/>
+ <enum value="0x883F" name="GL_SUBSAMPLE_DISTANCE_AMD"/>
+ </enums>
+
+ <enums namespace="GL" start="0x8840" end="0x884F" vendor="ARB">
+ <enum value="0x8840" name="GL_MATRIX_PALETTE_ARB"/>
+ <enum value="0x8840" name="GL_MATRIX_PALETTE_OES"/>
+ <enum value="0x8841" name="GL_MAX_MATRIX_PALETTE_STACK_DEPTH_ARB"/>
+ <enum value="0x8842" name="GL_MAX_PALETTE_MATRICES_ARB"/>
+ <enum value="0x8842" name="GL_MAX_PALETTE_MATRICES_OES"/>
+ <enum value="0x8843" name="GL_CURRENT_PALETTE_MATRIX_ARB"/>
+ <enum value="0x8843" name="GL_CURRENT_PALETTE_MATRIX_OES"/>
+ <enum value="0x8844" name="GL_MATRIX_INDEX_ARRAY_ARB"/>
+ <enum value="0x8844" name="GL_MATRIX_INDEX_ARRAY_OES"/>
+ <enum value="0x8845" name="GL_CURRENT_MATRIX_INDEX_ARB"/>
+ <enum value="0x8846" name="GL_MATRIX_INDEX_ARRAY_SIZE_ARB"/>
+ <enum value="0x8846" name="GL_MATRIX_INDEX_ARRAY_SIZE_OES"/>
+ <enum value="0x8847" name="GL_MATRIX_INDEX_ARRAY_TYPE_ARB"/>
+ <enum value="0x8847" name="GL_MATRIX_INDEX_ARRAY_TYPE_OES"/>
+ <enum value="0x8848" name="GL_MATRIX_INDEX_ARRAY_STRIDE_ARB"/>
+ <enum value="0x8848" name="GL_MATRIX_INDEX_ARRAY_STRIDE_OES"/>
+ <enum value="0x8849" name="GL_MATRIX_INDEX_ARRAY_POINTER_ARB"/>
+ <enum value="0x8849" name="GL_MATRIX_INDEX_ARRAY_POINTER_OES"/>
+ <enum value="0x884A" name="GL_TEXTURE_DEPTH_SIZE"/>
+ <enum value="0x884A" name="GL_TEXTURE_DEPTH_SIZE_ARB"/>
+ <enum value="0x884B" name="GL_DEPTH_TEXTURE_MODE"/>
+ <enum value="0x884B" name="GL_DEPTH_TEXTURE_MODE_ARB"/>
+ <enum value="0x884C" name="GL_TEXTURE_COMPARE_MODE"/>
+ <enum value="0x884C" name="GL_TEXTURE_COMPARE_MODE_ARB"/>
+ <enum value="0x884C" name="GL_TEXTURE_COMPARE_MODE_EXT"/>
+ <enum value="0x884D" name="GL_TEXTURE_COMPARE_FUNC"/>
+ <enum value="0x884D" name="GL_TEXTURE_COMPARE_FUNC_ARB"/>
+ <enum value="0x884D" name="GL_TEXTURE_COMPARE_FUNC_EXT"/>
+ <enum value="0x884E" name="GL_COMPARE_R_TO_TEXTURE"/>
+ <enum value="0x884E" name="GL_COMPARE_R_TO_TEXTURE_ARB"/>
+ <enum value="0x884E" name="GL_COMPARE_REF_DEPTH_TO_TEXTURE_EXT"/>
+ <enum value="0x884E" name="GL_COMPARE_REF_TO_TEXTURE" alias="GL_COMPARE_R_TO_TEXTURE"/>
+ <enum value="0x884E" name="GL_COMPARE_REF_TO_TEXTURE_EXT"/>
+ <enum value="0x884F" name="GL_TEXTURE_CUBE_MAP_SEAMLESS"/>
+ </enums>
+
+ <enums namespace="GL" start="0x8850" end="0x891F" vendor="NV">
+ <enum value="0x8850" name="GL_OFFSET_PROJECTIVE_TEXTURE_2D_NV"/>
+ <enum value="0x8851" name="GL_OFFSET_PROJECTIVE_TEXTURE_2D_SCALE_NV"/>
+ <enum value="0x8852" name="GL_OFFSET_PROJECTIVE_TEXTURE_RECTANGLE_NV"/>
+ <enum value="0x8853" name="GL_OFFSET_PROJECTIVE_TEXTURE_RECTANGLE_SCALE_NV"/>
+ <enum value="0x8854" name="GL_OFFSET_HILO_TEXTURE_2D_NV"/>
+ <enum value="0x8855" name="GL_OFFSET_HILO_TEXTURE_RECTANGLE_NV"/>
+ <enum value="0x8856" name="GL_OFFSET_HILO_PROJECTIVE_TEXTURE_2D_NV"/>
+ <enum value="0x8857" name="GL_OFFSET_HILO_PROJECTIVE_TEXTURE_RECTANGLE_NV"/>
+ <enum value="0x8858" name="GL_DEPENDENT_HILO_TEXTURE_2D_NV"/>
+ <enum value="0x8859" name="GL_DEPENDENT_RGB_TEXTURE_3D_NV"/>
+ <enum value="0x885A" name="GL_DEPENDENT_RGB_TEXTURE_CUBE_MAP_NV"/>
+ <enum value="0x885B" name="GL_DOT_PRODUCT_PASS_THROUGH_NV"/>
+ <enum value="0x885C" name="GL_DOT_PRODUCT_TEXTURE_1D_NV"/>
+ <enum value="0x885D" name="GL_DOT_PRODUCT_AFFINE_DEPTH_REPLACE_NV"/>
+ <enum value="0x885E" name="GL_HILO8_NV"/>
+ <enum value="0x885F" name="GL_SIGNED_HILO8_NV"/>
+ <enum value="0x8860" name="GL_FORCE_BLUE_TO_ONE_NV"/>
+ <enum value="0x8861" name="GL_POINT_SPRITE"/>
+ <enum value="0x8861" name="GL_POINT_SPRITE_ARB"/>
+ <enum value="0x8861" name="GL_POINT_SPRITE_NV"/>
+ <enum value="0x8861" name="GL_POINT_SPRITE_OES"/>
+ <enum value="0x8862" name="GL_COORD_REPLACE"/>
+ <enum value="0x8862" name="GL_COORD_REPLACE_ARB"/>
+ <enum value="0x8862" name="GL_COORD_REPLACE_NV"/>
+ <enum value="0x8862" name="GL_COORD_REPLACE_OES"/>
+ <enum value="0x8863" name="GL_POINT_SPRITE_R_MODE_NV"/>
+ <enum value="0x8864" name="GL_PIXEL_COUNTER_BITS_NV"/>
+ <enum value="0x8864" name="GL_QUERY_COUNTER_BITS"/>
+ <enum value="0x8864" name="GL_QUERY_COUNTER_BITS_ARB"/>
+ <enum value="0x8864" name="GL_QUERY_COUNTER_BITS_EXT"/>
+ <enum value="0x8865" name="GL_CURRENT_OCCLUSION_QUERY_ID_NV"/>
+ <enum value="0x8865" name="GL_CURRENT_QUERY"/>
+ <enum value="0x8865" name="GL_CURRENT_QUERY_ARB"/>
+ <enum value="0x8865" name="GL_CURRENT_QUERY_EXT"/>
+ <enum value="0x8866" name="GL_PIXEL_COUNT_NV"/>
+ <enum value="0x8866" name="GL_QUERY_RESULT"/>
+ <enum value="0x8866" name="GL_QUERY_RESULT_ARB"/>
+ <enum value="0x8866" name="GL_QUERY_RESULT_EXT"/>
+ <enum value="0x8867" name="GL_PIXEL_COUNT_AVAILABLE_NV"/>
+ <enum value="0x8867" name="GL_QUERY_RESULT_AVAILABLE"/>
+ <enum value="0x8867" name="GL_QUERY_RESULT_AVAILABLE_ARB"/>
+ <enum value="0x8867" name="GL_QUERY_RESULT_AVAILABLE_EXT"/>
+ <enum value="0x8868" name="GL_MAX_FRAGMENT_PROGRAM_LOCAL_PARAMETERS_NV"/>
+ <enum value="0x8869" name="GL_MAX_VERTEX_ATTRIBS"/>
+ <enum value="0x8869" name="GL_MAX_VERTEX_ATTRIBS_ARB"/>
+ <enum value="0x886A" name="GL_VERTEX_ATTRIB_ARRAY_NORMALIZED"/>
+ <enum value="0x886A" name="GL_VERTEX_ATTRIB_ARRAY_NORMALIZED_ARB"/>
+ <unused start="0x886B" vendor="NV"/>
+ <enum value="0x886C" name="GL_MAX_TESS_CONTROL_INPUT_COMPONENTS"/>
+ <enum value="0x886C" name="GL_MAX_TESS_CONTROL_INPUT_COMPONENTS_EXT"/>
+ <enum value="0x886D" name="GL_MAX_TESS_EVALUATION_INPUT_COMPONENTS"/>
+ <enum value="0x886D" name="GL_MAX_TESS_EVALUATION_INPUT_COMPONENTS_EXT"/>
+ <enum value="0x886E" name="GL_DEPTH_STENCIL_TO_RGBA_NV"/>
+ <enum value="0x886F" name="GL_DEPTH_STENCIL_TO_BGRA_NV"/>
+ <enum value="0x8870" name="GL_FRAGMENT_PROGRAM_NV"/>
+ <enum value="0x8871" name="GL_MAX_TEXTURE_COORDS"/>
+ <enum value="0x8871" name="GL_MAX_TEXTURE_COORDS_ARB"/>
+ <enum value="0x8871" name="GL_MAX_TEXTURE_COORDS_NV"/>
+ <enum value="0x8872" name="GL_MAX_TEXTURE_IMAGE_UNITS"/>
+ <enum value="0x8872" name="GL_MAX_TEXTURE_IMAGE_UNITS_ARB"/>
+ <enum value="0x8872" name="GL_MAX_TEXTURE_IMAGE_UNITS_NV"/>
+ <enum value="0x8873" name="GL_FRAGMENT_PROGRAM_BINDING_NV"/>
+ <enum value="0x8874" name="GL_PROGRAM_ERROR_STRING_ARB"/>
+ <enum value="0x8874" name="GL_PROGRAM_ERROR_STRING_NV"/>
+ <enum value="0x8875" name="GL_PROGRAM_FORMAT_ASCII_ARB"/>
+ <enum value="0x8876" name="GL_PROGRAM_FORMAT_ARB"/>
+ <unused start="0x8877" vendor="NV" comment="Should have been assigned to PROGRAM_BINDING_ARB"/>
+ <enum value="0x8878" name="GL_WRITE_PIXEL_DATA_RANGE_NV"/>
+ <enum value="0x8879" name="GL_READ_PIXEL_DATA_RANGE_NV"/>
+ <enum value="0x887A" name="GL_WRITE_PIXEL_DATA_RANGE_LENGTH_NV"/>
+ <enum value="0x887B" name="GL_READ_PIXEL_DATA_RANGE_LENGTH_NV"/>
+ <enum value="0x887C" name="GL_WRITE_PIXEL_DATA_RANGE_POINTER_NV"/>
+ <enum value="0x887D" name="GL_READ_PIXEL_DATA_RANGE_POINTER_NV"/>
+ <unused start="0x887E" vendor="NV"/>
+ <enum value="0x887F" name="GL_GEOMETRY_SHADER_INVOCATIONS"/>
+ <enum value="0x887F" name="GL_GEOMETRY_SHADER_INVOCATIONS_EXT"/>
+ <enum value="0x8880" name="GL_FLOAT_R_NV"/>
+ <enum value="0x8881" name="GL_FLOAT_RG_NV"/>
+ <enum value="0x8882" name="GL_FLOAT_RGB_NV"/>
+ <enum value="0x8883" name="GL_FLOAT_RGBA_NV"/>
+ <enum value="0x8884" name="GL_FLOAT_R16_NV"/>
+ <enum value="0x8885" name="GL_FLOAT_R32_NV"/>
+ <enum value="0x8886" name="GL_FLOAT_RG16_NV"/>
+ <enum value="0x8887" name="GL_FLOAT_RG32_NV"/>
+ <enum value="0x8888" name="GL_FLOAT_RGB16_NV"/>
+ <enum value="0x8889" name="GL_FLOAT_RGB32_NV"/>
+ <enum value="0x888A" name="GL_FLOAT_RGBA16_NV"/>
+ <enum value="0x888B" name="GL_FLOAT_RGBA32_NV"/>
+ <enum value="0x888C" name="GL_TEXTURE_FLOAT_COMPONENTS_NV"/>
+ <enum value="0x888D" name="GL_FLOAT_CLEAR_COLOR_VALUE_NV"/>
+ <enum value="0x888E" name="GL_FLOAT_RGBA_MODE_NV"/>
+ <enum value="0x888F" name="GL_TEXTURE_UNSIGNED_REMAP_MODE_NV"/>
+ <enum value="0x8890" name="GL_DEPTH_BOUNDS_TEST_EXT"/>
+ <enum value="0x8891" name="GL_DEPTH_BOUNDS_EXT"/>
+ <enum value="0x8892" name="GL_ARRAY_BUFFER"/>
+ <enum value="0x8892" name="GL_ARRAY_BUFFER_ARB"/>
+ <enum value="0x8893" name="GL_ELEMENT_ARRAY_BUFFER"/>
+ <enum value="0x8893" name="GL_ELEMENT_ARRAY_BUFFER_ARB"/>
+ <enum value="0x8894" name="GL_ARRAY_BUFFER_BINDING"/>
+ <enum value="0x8894" name="GL_ARRAY_BUFFER_BINDING_ARB"/>
+ <enum value="0x8895" name="GL_ELEMENT_ARRAY_BUFFER_BINDING"/>
+ <enum value="0x8895" name="GL_ELEMENT_ARRAY_BUFFER_BINDING_ARB"/>
+ <enum value="0x8896" name="GL_VERTEX_ARRAY_BUFFER_BINDING"/>
+ <enum value="0x8896" name="GL_VERTEX_ARRAY_BUFFER_BINDING_ARB"/>
+ <enum value="0x8897" name="GL_NORMAL_ARRAY_BUFFER_BINDING"/>
+ <enum value="0x8897" name="GL_NORMAL_ARRAY_BUFFER_BINDING_ARB"/>
+ <enum value="0x8898" name="GL_COLOR_ARRAY_BUFFER_BINDING"/>
+ <enum value="0x8898" name="GL_COLOR_ARRAY_BUFFER_BINDING_ARB"/>
+ <enum value="0x8899" name="GL_INDEX_ARRAY_BUFFER_BINDING"/>
+ <enum value="0x8899" name="GL_INDEX_ARRAY_BUFFER_BINDING_ARB"/>
+ <enum value="0x889A" name="GL_TEXTURE_COORD_ARRAY_BUFFER_BINDING"/>
+ <enum value="0x889A" name="GL_TEXTURE_COORD_ARRAY_BUFFER_BINDING_ARB"/>
+ <enum value="0x889B" name="GL_EDGE_FLAG_ARRAY_BUFFER_BINDING"/>
+ <enum value="0x889B" name="GL_EDGE_FLAG_ARRAY_BUFFER_BINDING_ARB"/>
+ <enum value="0x889C" name="GL_SECONDARY_COLOR_ARRAY_BUFFER_BINDING"/>
+ <enum value="0x889C" name="GL_SECONDARY_COLOR_ARRAY_BUFFER_BINDING_ARB"/>
+ <enum value="0x889D" name="GL_FOG_COORDINATE_ARRAY_BUFFER_BINDING_ARB"/>
+ <enum value="0x889D" name="GL_FOG_COORDINATE_ARRAY_BUFFER_BINDING"/>
+ <enum value="0x889D" name="GL_FOG_COORD_ARRAY_BUFFER_BINDING" alias="GL_FOG_COORDINATE_ARRAY_BUFFER_BINDING"/>
+ <enum value="0x889E" name="GL_WEIGHT_ARRAY_BUFFER_BINDING"/>
+ <enum value="0x889E" name="GL_WEIGHT_ARRAY_BUFFER_BINDING_ARB"/>
+ <enum value="0x889E" name="GL_WEIGHT_ARRAY_BUFFER_BINDING_OES"/>
+ <enum value="0x889F" name="GL_VERTEX_ATTRIB_ARRAY_BUFFER_BINDING"/>
+ <enum value="0x889F" name="GL_VERTEX_ATTRIB_ARRAY_BUFFER_BINDING_ARB"/>
+ <enum value="0x88A0" name="GL_PROGRAM_INSTRUCTIONS_ARB"/>
+ <enum value="0x88A1" name="GL_MAX_PROGRAM_INSTRUCTIONS_ARB"/>
+ <enum value="0x88A2" name="GL_PROGRAM_NATIVE_INSTRUCTIONS_ARB"/>
+ <enum value="0x88A3" name="GL_MAX_PROGRAM_NATIVE_INSTRUCTIONS_ARB"/>
+ <enum value="0x88A4" name="GL_PROGRAM_TEMPORARIES_ARB"/>
+ <enum value="0x88A5" name="GL_MAX_PROGRAM_TEMPORARIES_ARB"/>
+ <enum value="0x88A6" name="GL_PROGRAM_NATIVE_TEMPORARIES_ARB"/>
+ <enum value="0x88A7" name="GL_MAX_PROGRAM_NATIVE_TEMPORARIES_ARB"/>
+ <enum value="0x88A8" name="GL_PROGRAM_PARAMETERS_ARB"/>
+ <enum value="0x88A9" name="GL_MAX_PROGRAM_PARAMETERS_ARB"/>
+ <enum value="0x88AA" name="GL_PROGRAM_NATIVE_PARAMETERS_ARB"/>
+ <enum value="0x88AB" name="GL_MAX_PROGRAM_NATIVE_PARAMETERS_ARB"/>
+ <enum value="0x88AC" name="GL_PROGRAM_ATTRIBS_ARB"/>
+ <enum value="0x88AD" name="GL_MAX_PROGRAM_ATTRIBS_ARB"/>
+ <enum value="0x88AE" name="GL_PROGRAM_NATIVE_ATTRIBS_ARB"/>
+ <enum value="0x88AF" name="GL_MAX_PROGRAM_NATIVE_ATTRIBS_ARB"/>
+ <enum value="0x88B0" name="GL_PROGRAM_ADDRESS_REGISTERS_ARB"/>
+ <enum value="0x88B1" name="GL_MAX_PROGRAM_ADDRESS_REGISTERS_ARB"/>
+ <enum value="0x88B2" name="GL_PROGRAM_NATIVE_ADDRESS_REGISTERS_ARB"/>
+ <enum value="0x88B3" name="GL_MAX_PROGRAM_NATIVE_ADDRESS_REGISTERS_ARB"/>
+ <enum value="0x88B4" name="GL_MAX_PROGRAM_LOCAL_PARAMETERS_ARB"/>
+ <enum value="0x88B5" name="GL_MAX_PROGRAM_ENV_PARAMETERS_ARB"/>
+ <enum value="0x88B6" name="GL_PROGRAM_UNDER_NATIVE_LIMITS_ARB"/>
+ <enum value="0x88B7" name="GL_TRANSPOSE_CURRENT_MATRIX_ARB"/>
+ <enum value="0x88B8" name="GL_READ_ONLY"/>
+ <enum value="0x88B8" name="GL_READ_ONLY_ARB"/>
+ <enum value="0x88B9" name="GL_WRITE_ONLY"/>
+ <enum value="0x88B9" name="GL_WRITE_ONLY_ARB"/>
+ <enum value="0x88B9" name="GL_WRITE_ONLY_OES"/>
+ <enum value="0x88BA" name="GL_READ_WRITE"/>
+ <enum value="0x88BA" name="GL_READ_WRITE_ARB"/>
+ <enum value="0x88BB" name="GL_BUFFER_ACCESS"/>
+ <enum value="0x88BB" name="GL_BUFFER_ACCESS_ARB"/>
+ <enum value="0x88BB" name="GL_BUFFER_ACCESS_OES"/>
+ <enum value="0x88BC" name="GL_BUFFER_MAPPED"/>
+ <enum value="0x88BC" name="GL_BUFFER_MAPPED_ARB"/>
+ <enum value="0x88BC" name="GL_BUFFER_MAPPED_OES"/>
+ <enum value="0x88BD" name="GL_BUFFER_MAP_POINTER"/>
+ <enum value="0x88BD" name="GL_BUFFER_MAP_POINTER_ARB"/>
+ <enum value="0x88BD" name="GL_BUFFER_MAP_POINTER_OES"/>
+ <enum value="0x88BE" name="GL_WRITE_DISCARD_NV"/>
+ <enum value="0x88BF" name="GL_TIME_ELAPSED"/>
+ <enum value="0x88BF" name="GL_TIME_ELAPSED_EXT"/>
+ <enum value="0x88C0" name="GL_MATRIX0_ARB"/>
+ <enum value="0x88C1" name="GL_MATRIX1_ARB"/>
+ <enum value="0x88C2" name="GL_MATRIX2_ARB"/>
+ <enum value="0x88C3" name="GL_MATRIX3_ARB"/>
+ <enum value="0x88C4" name="GL_MATRIX4_ARB"/>
+ <enum value="0x88C5" name="GL_MATRIX5_ARB"/>
+ <enum value="0x88C6" name="GL_MATRIX6_ARB"/>
+ <enum value="0x88C7" name="GL_MATRIX7_ARB"/>
+ <enum value="0x88C8" name="GL_MATRIX8_ARB"/>
+ <enum value="0x88C9" name="GL_MATRIX9_ARB"/>
+ <enum value="0x88CA" name="GL_MATRIX10_ARB"/>
+ <enum value="0x88CB" name="GL_MATRIX11_ARB"/>
+ <enum value="0x88CC" name="GL_MATRIX12_ARB"/>
+ <enum value="0x88CD" name="GL_MATRIX13_ARB"/>
+ <enum value="0x88CE" name="GL_MATRIX14_ARB"/>
+ <enum value="0x88CF" name="GL_MATRIX15_ARB"/>
+ <enum value="0x88D0" name="GL_MATRIX16_ARB"/>
+ <enum value="0x88D1" name="GL_MATRIX17_ARB"/>
+ <enum value="0x88D2" name="GL_MATRIX18_ARB"/>
+ <enum value="0x88D3" name="GL_MATRIX19_ARB"/>
+ <enum value="0x88D4" name="GL_MATRIX20_ARB"/>
+ <enum value="0x88D5" name="GL_MATRIX21_ARB"/>
+ <enum value="0x88D6" name="GL_MATRIX22_ARB"/>
+ <enum value="0x88D7" name="GL_MATRIX23_ARB"/>
+ <enum value="0x88D8" name="GL_MATRIX24_ARB"/>
+ <enum value="0x88D9" name="GL_MATRIX25_ARB"/>
+ <enum value="0x88DA" name="GL_MATRIX26_ARB"/>
+ <enum value="0x88DB" name="GL_MATRIX27_ARB"/>
+ <enum value="0x88DC" name="GL_MATRIX28_ARB"/>
+ <enum value="0x88DD" name="GL_MATRIX29_ARB"/>
+ <enum value="0x88DE" name="GL_MATRIX30_ARB"/>
+ <enum value="0x88DF" name="GL_MATRIX31_ARB"/>
+ <enum value="0x88E0" name="GL_STREAM_DRAW"/>
+ <enum value="0x88E0" name="GL_STREAM_DRAW_ARB"/>
+ <enum value="0x88E1" name="GL_STREAM_READ"/>
+ <enum value="0x88E1" name="GL_STREAM_READ_ARB"/>
+ <enum value="0x88E2" name="GL_STREAM_COPY"/>
+ <enum value="0x88E2" name="GL_STREAM_COPY_ARB"/>
+ <unused start="0x88E3" vendor="NV" comment="To extend ARB_vbo"/>
+ <enum value="0x88E4" name="GL_STATIC_DRAW"/>
+ <enum value="0x88E4" name="GL_STATIC_DRAW_ARB"/>
+ <enum value="0x88E5" name="GL_STATIC_READ"/>
+ <enum value="0x88E5" name="GL_STATIC_READ_ARB"/>
+ <enum value="0x88E6" name="GL_STATIC_COPY"/>
+ <enum value="0x88E6" name="GL_STATIC_COPY_ARB"/>
+ <unused start="0x88E7" vendor="NV" comment="To extend ARB_vbo"/>
+ <enum value="0x88E8" name="GL_DYNAMIC_DRAW"/>
+ <enum value="0x88E8" name="GL_DYNAMIC_DRAW_ARB"/>
+ <enum value="0x88E9" name="GL_DYNAMIC_READ"/>
+ <enum value="0x88E9" name="GL_DYNAMIC_READ_ARB"/>
+ <enum value="0x88EA" name="GL_DYNAMIC_COPY"/>
+ <enum value="0x88EA" name="GL_DYNAMIC_COPY_ARB"/>
+ <enum value="0x88EB" name="GL_PIXEL_PACK_BUFFER"/>
+ <enum value="0x88EB" name="GL_PIXEL_PACK_BUFFER_ARB"/>
+ <enum value="0x88EB" name="GL_PIXEL_PACK_BUFFER_EXT"/>
+ <enum value="0x88EC" name="GL_PIXEL_UNPACK_BUFFER"/>
+ <enum value="0x88EC" name="GL_PIXEL_UNPACK_BUFFER_ARB"/>
+ <enum value="0x88EC" name="GL_PIXEL_UNPACK_BUFFER_EXT"/>
+ <enum value="0x88ED" name="GL_PIXEL_PACK_BUFFER_BINDING"/>
+ <enum value="0x88ED" name="GL_PIXEL_PACK_BUFFER_BINDING_ARB"/>
+ <enum value="0x88ED" name="GL_PIXEL_PACK_BUFFER_BINDING_EXT"/>
+ <enum value="0x88EE" name="GL_ETC1_SRGB8_NV"/>
+ <enum value="0x88EF" name="GL_PIXEL_UNPACK_BUFFER_BINDING"/>
+ <enum value="0x88EF" name="GL_PIXEL_UNPACK_BUFFER_BINDING_ARB"/>
+ <enum value="0x88EF" name="GL_PIXEL_UNPACK_BUFFER_BINDING_EXT"/>
+ <enum value="0x88F0" name="GL_DEPTH24_STENCIL8"/>
+ <enum value="0x88F0" name="GL_DEPTH24_STENCIL8_EXT"/>
+ <enum value="0x88F0" name="GL_DEPTH24_STENCIL8_OES"/>
+ <enum value="0x88F1" name="GL_TEXTURE_STENCIL_SIZE"/>
+ <enum value="0x88F1" name="GL_TEXTURE_STENCIL_SIZE_EXT"/>
+ <enum value="0x88F2" name="GL_STENCIL_TAG_BITS_EXT"/>
+ <enum value="0x88F3" name="GL_STENCIL_CLEAR_TAG_VALUE_EXT"/>
+ <enum value="0x88F4" name="GL_MAX_PROGRAM_EXEC_INSTRUCTIONS_NV"/>
+ <enum value="0x88F5" name="GL_MAX_PROGRAM_CALL_DEPTH_NV"/>
+ <enum value="0x88F6" name="GL_MAX_PROGRAM_IF_DEPTH_NV"/>
+ <enum value="0x88F7" name="GL_MAX_PROGRAM_LOOP_DEPTH_NV"/>
+ <enum value="0x88F8" name="GL_MAX_PROGRAM_LOOP_COUNT_NV"/>
+ <enum value="0x88F9" name="GL_SRC1_COLOR"/>
+ <enum value="0x88FA" name="GL_ONE_MINUS_SRC1_COLOR"/>
+ <enum value="0x88FB" name="GL_ONE_MINUS_SRC1_ALPHA"/>
+ <enum value="0x88FC" name="GL_MAX_DUAL_SOURCE_DRAW_BUFFERS"/>
+ <enum value="0x88FD" name="GL_VERTEX_ATTRIB_ARRAY_INTEGER"/>
+ <enum value="0x88FD" name="GL_VERTEX_ATTRIB_ARRAY_INTEGER_EXT"/>
+ <enum value="0x88FD" name="GL_VERTEX_ATTRIB_ARRAY_INTEGER_NV"/>
+ <enum value="0x88FE" name="GL_VERTEX_ATTRIB_ARRAY_DIVISOR"/>
+ <enum value="0x88FE" name="GL_VERTEX_ATTRIB_ARRAY_DIVISOR_ANGLE"/>
+ <enum value="0x88FE" name="GL_VERTEX_ATTRIB_ARRAY_DIVISOR_ARB"/>
+ <enum value="0x88FE" name="GL_VERTEX_ATTRIB_ARRAY_DIVISOR_EXT"/>
+ <enum value="0x88FE" name="GL_VERTEX_ATTRIB_ARRAY_DIVISOR_NV"/>
+ <enum value="0x88FF" name="GL_MAX_ARRAY_TEXTURE_LAYERS"/>
+ <enum value="0x88FF" name="GL_MAX_ARRAY_TEXTURE_LAYERS_EXT"/>
+ <enum value="0x8904" name="GL_MIN_PROGRAM_TEXEL_OFFSET"/>
+ <enum value="0x8904" name="GL_MIN_PROGRAM_TEXEL_OFFSET_EXT"/>
+ <enum value="0x8904" name="GL_MIN_PROGRAM_TEXEL_OFFSET_NV"/>
+ <enum value="0x8905" name="GL_MAX_PROGRAM_TEXEL_OFFSET"/>
+ <enum value="0x8905" name="GL_MAX_PROGRAM_TEXEL_OFFSET_EXT"/>
+ <enum value="0x8905" name="GL_MAX_PROGRAM_TEXEL_OFFSET_NV"/>
+ <enum value="0x8906" name="GL_PROGRAM_ATTRIB_COMPONENTS_NV"/>
+ <enum value="0x8907" name="GL_PROGRAM_RESULT_COMPONENTS_NV"/>
+ <enum value="0x8908" name="GL_MAX_PROGRAM_ATTRIB_COMPONENTS_NV"/>
+ <enum value="0x8909" name="GL_MAX_PROGRAM_RESULT_COMPONENTS_NV"/>
+ <enum value="0x8910" name="GL_STENCIL_TEST_TWO_SIDE_EXT"/>
+ <enum value="0x8911" name="GL_ACTIVE_STENCIL_FACE_EXT"/>
+ <enum value="0x8912" name="GL_MIRROR_CLAMP_TO_BORDER_EXT"/>
+ <unused start="0x8913" vendor="NV"/>
+ <enum value="0x8914" name="GL_SAMPLES_PASSED"/>
+ <enum value="0x8914" name="GL_SAMPLES_PASSED_ARB"/>
+ <unused start="0x8915" vendor="NV"/>
+ <enum value="0x8916" name="GL_GEOMETRY_VERTICES_OUT"/>
+ <enum value="0x8916" name="GL_GEOMETRY_LINKED_VERTICES_OUT_EXT"/>
+ <enum value="0x8917" name="GL_GEOMETRY_INPUT_TYPE"/>
+ <enum value="0x8917" name="GL_GEOMETRY_LINKED_INPUT_TYPE_EXT"/>
+ <enum value="0x8918" name="GL_GEOMETRY_OUTPUT_TYPE"/>
+ <enum value="0x8918" name="GL_GEOMETRY_LINKED_OUTPUT_TYPE_EXT"/>
+ <enum value="0x8919" name="GL_SAMPLER_BINDING"/>
+ <enum value="0x891A" name="GL_CLAMP_VERTEX_COLOR"/>
+ <enum value="0x891A" name="GL_CLAMP_VERTEX_COLOR_ARB"/>
+ <enum value="0x891B" name="GL_CLAMP_FRAGMENT_COLOR"/>
+ <enum value="0x891B" name="GL_CLAMP_FRAGMENT_COLOR_ARB"/>
+ <enum value="0x891C" name="GL_CLAMP_READ_COLOR"/>
+ <enum value="0x891C" name="GL_CLAMP_READ_COLOR_ARB"/>
+ <enum value="0x891D" name="GL_FIXED_ONLY"/>
+ <enum value="0x891D" name="GL_FIXED_ONLY_ARB"/>
+ <enum value="0x891E" name="GL_TESS_CONTROL_PROGRAM_NV"/>
+ <enum value="0x891F" name="GL_TESS_EVALUATION_PROGRAM_NV"/>
+ </enums>
+
+ <enums namespace="GL" start="0x8920" end="0x897F" vendor="AMD">
+ <enum value="0x8920" name="GL_FRAGMENT_SHADER_ATI"/>
+ <enum value="0x8921" name="GL_REG_0_ATI"/>
+ <enum value="0x8922" name="GL_REG_1_ATI"/>
+ <enum value="0x8923" name="GL_REG_2_ATI"/>
+ <enum value="0x8924" name="GL_REG_3_ATI"/>
+ <enum value="0x8925" name="GL_REG_4_ATI"/>
+ <enum value="0x8926" name="GL_REG_5_ATI"/>
+ <enum value="0x8927" name="GL_REG_6_ATI"/>
+ <enum value="0x8928" name="GL_REG_7_ATI"/>
+ <enum value="0x8929" name="GL_REG_8_ATI"/>
+ <enum value="0x892A" name="GL_REG_9_ATI"/>
+ <enum value="0x892B" name="GL_REG_10_ATI"/>
+ <enum value="0x892C" name="GL_REG_11_ATI"/>
+ <enum value="0x892D" name="GL_REG_12_ATI"/>
+ <enum value="0x892E" name="GL_REG_13_ATI"/>
+ <enum value="0x892F" name="GL_REG_14_ATI"/>
+ <enum value="0x8930" name="GL_REG_15_ATI"/>
+ <enum value="0x8931" name="GL_REG_16_ATI"/>
+ <enum value="0x8932" name="GL_REG_17_ATI"/>
+ <enum value="0x8933" name="GL_REG_18_ATI"/>
+ <enum value="0x8934" name="GL_REG_19_ATI"/>
+ <enum value="0x8935" name="GL_REG_20_ATI"/>
+ <enum value="0x8936" name="GL_REG_21_ATI"/>
+ <enum value="0x8937" name="GL_REG_22_ATI"/>
+ <enum value="0x8938" name="GL_REG_23_ATI"/>
+ <enum value="0x8939" name="GL_REG_24_ATI"/>
+ <enum value="0x893A" name="GL_REG_25_ATI"/>
+ <enum value="0x893B" name="GL_REG_26_ATI"/>
+ <enum value="0x893C" name="GL_REG_27_ATI"/>
+ <enum value="0x893D" name="GL_REG_28_ATI"/>
+ <enum value="0x893E" name="GL_REG_29_ATI"/>
+ <enum value="0x893F" name="GL_REG_30_ATI"/>
+ <enum value="0x8940" name="GL_REG_31_ATI"/>
+ <enum value="0x8941" name="GL_CON_0_ATI"/>
+ <enum value="0x8942" name="GL_CON_1_ATI"/>
+ <enum value="0x8943" name="GL_CON_2_ATI"/>
+ <enum value="0x8944" name="GL_CON_3_ATI"/>
+ <enum value="0x8945" name="GL_CON_4_ATI"/>
+ <enum value="0x8946" name="GL_CON_5_ATI"/>
+ <enum value="0x8947" name="GL_CON_6_ATI"/>
+ <enum value="0x8948" name="GL_CON_7_ATI"/>
+ <enum value="0x8949" name="GL_CON_8_ATI"/>
+ <enum value="0x894A" name="GL_CON_9_ATI"/>
+ <enum value="0x894B" name="GL_CON_10_ATI"/>
+ <enum value="0x894C" name="GL_CON_11_ATI"/>
+ <enum value="0x894D" name="GL_CON_12_ATI"/>
+ <enum value="0x894E" name="GL_CON_13_ATI"/>
+ <enum value="0x894F" name="GL_CON_14_ATI"/>
+ <enum value="0x8950" name="GL_CON_15_ATI"/>
+ <enum value="0x8951" name="GL_CON_16_ATI"/>
+ <enum value="0x8952" name="GL_CON_17_ATI"/>
+ <enum value="0x8953" name="GL_CON_18_ATI"/>
+ <enum value="0x8954" name="GL_CON_19_ATI"/>
+ <enum value="0x8955" name="GL_CON_20_ATI"/>
+ <enum value="0x8956" name="GL_CON_21_ATI"/>
+ <enum value="0x8957" name="GL_CON_22_ATI"/>
+ <enum value="0x8958" name="GL_CON_23_ATI"/>
+ <enum value="0x8959" name="GL_CON_24_ATI"/>
+ <enum value="0x895A" name="GL_CON_25_ATI"/>
+ <enum value="0x895B" name="GL_CON_26_ATI"/>
+ <enum value="0x895C" name="GL_CON_27_ATI"/>
+ <enum value="0x895D" name="GL_CON_28_ATI"/>
+ <enum value="0x895E" name="GL_CON_29_ATI"/>
+ <enum value="0x895F" name="GL_CON_30_ATI"/>
+ <enum value="0x8960" name="GL_CON_31_ATI"/>
+ <enum value="0x8961" name="GL_MOV_ATI"/>
+ <enum value="0x8963" name="GL_ADD_ATI"/>
+ <enum value="0x8964" name="GL_MUL_ATI"/>
+ <enum value="0x8965" name="GL_SUB_ATI"/>
+ <enum value="0x8966" name="GL_DOT3_ATI"/>
+ <enum value="0x8967" name="GL_DOT4_ATI"/>
+ <enum value="0x8968" name="GL_MAD_ATI"/>
+ <enum value="0x8969" name="GL_LERP_ATI"/>
+ <enum value="0x896A" name="GL_CND_ATI"/>
+ <enum value="0x896B" name="GL_CND0_ATI"/>
+ <enum value="0x896C" name="GL_DOT2_ADD_ATI"/>
+ <enum value="0x896D" name="GL_SECONDARY_INTERPOLATOR_ATI"/>
+ <enum value="0x896E" name="GL_NUM_FRAGMENT_REGISTERS_ATI"/>
+ <enum value="0x896F" name="GL_NUM_FRAGMENT_CONSTANTS_ATI"/>
+ <enum value="0x8970" name="GL_NUM_PASSES_ATI"/>
+ <enum value="0x8971" name="GL_NUM_INSTRUCTIONS_PER_PASS_ATI"/>
+ <enum value="0x8972" name="GL_NUM_INSTRUCTIONS_TOTAL_ATI"/>
+ <enum value="0x8973" name="GL_NUM_INPUT_INTERPOLATOR_COMPONENTS_ATI"/>
+ <enum value="0x8974" name="GL_NUM_LOOPBACK_COMPONENTS_ATI"/>
+ <enum value="0x8975" name="GL_COLOR_ALPHA_PAIRING_ATI"/>
+ <enum value="0x8976" name="GL_SWIZZLE_STR_ATI"/>
+ <enum value="0x8977" name="GL_SWIZZLE_STQ_ATI"/>
+ <enum value="0x8978" name="GL_SWIZZLE_STR_DR_ATI"/>
+ <enum value="0x8979" name="GL_SWIZZLE_STQ_DQ_ATI"/>
+ <enum value="0x897A" name="GL_SWIZZLE_STRQ_ATI"/>
+ <enum value="0x897B" name="GL_SWIZZLE_STRQ_DQ_ATI"/>
+ <unused start="0x897C" end="0x897F" vendor="AMD"/>
+ </enums>
+
+ <enums namespace="GL" start="0x8980" end="0x898F" vendor="OML">
+ <enum value="0x8980" name="GL_INTERLACE_OML"/>
+ <enum value="0x8981" name="GL_INTERLACE_READ_OML"/>
+ <enum value="0x8982" name="GL_FORMAT_SUBSAMPLE_24_24_OML"/>
+ <enum value="0x8983" name="GL_FORMAT_SUBSAMPLE_244_244_OML"/>
+ <enum value="0x8984" name="GL_PACK_RESAMPLE_OML"/>
+ <enum value="0x8985" name="GL_UNPACK_RESAMPLE_OML"/>
+ <enum value="0x8986" name="GL_RESAMPLE_REPLICATE_OML"/>
+ <enum value="0x8987" name="GL_RESAMPLE_ZERO_FILL_OML"/>
+ <enum value="0x8988" name="GL_RESAMPLE_AVERAGE_OML"/>
+ <enum value="0x8989" name="GL_RESAMPLE_DECIMATE_OML"/>
+ <enum value="0x898A" name="GL_POINT_SIZE_ARRAY_TYPE_OES"/>
+ <enum value="0x898B" name="GL_POINT_SIZE_ARRAY_STRIDE_OES"/>
+ <enum value="0x898C" name="GL_POINT_SIZE_ARRAY_POINTER_OES"/>
+ <enum value="0x898D" name="GL_MODELVIEW_MATRIX_FLOAT_AS_INT_BITS_OES"/>
+ <enum value="0x898E" name="GL_PROJECTION_MATRIX_FLOAT_AS_INT_BITS_OES"/>
+ <enum value="0x898F" name="GL_TEXTURE_MATRIX_FLOAT_AS_INT_BITS_OES"/>
+ </enums>
+
+ <enums namespace="GL" start="0x8990" end="0x899F" vendor="ZiiLabs">
+ <unused start="0x8990" end="0x899F" vendor="ZiiLabs"/>
+ </enums>
+
+ <enums namespace="GL" start="0x89A0" end="0x89FF" vendor="Matrox">
+ <unused start="0x89A0" end="0x89FF" vendor="Matrox"/>
+ </enums>
+
+ <enums namespace="GL" start="0x8A00" end="0x8A7F" vendor="APPLE">
+ <enum value="0x8A00" name="GL_VERTEX_ATTRIB_MAP1_APPLE"/>
+ <enum value="0x8A01" name="GL_VERTEX_ATTRIB_MAP2_APPLE"/>
+ <enum value="0x8A02" name="GL_VERTEX_ATTRIB_MAP1_SIZE_APPLE"/>
+ <enum value="0x8A03" name="GL_VERTEX_ATTRIB_MAP1_COEFF_APPLE"/>
+ <enum value="0x8A04" name="GL_VERTEX_ATTRIB_MAP1_ORDER_APPLE"/>
+ <enum value="0x8A05" name="GL_VERTEX_ATTRIB_MAP1_DOMAIN_APPLE"/>
+ <enum value="0x8A06" name="GL_VERTEX_ATTRIB_MAP2_SIZE_APPLE"/>
+ <enum value="0x8A07" name="GL_VERTEX_ATTRIB_MAP2_COEFF_APPLE"/>
+ <enum value="0x8A08" name="GL_VERTEX_ATTRIB_MAP2_ORDER_APPLE"/>
+ <enum value="0x8A09" name="GL_VERTEX_ATTRIB_MAP2_DOMAIN_APPLE"/>
+ <enum value="0x8A0A" name="GL_DRAW_PIXELS_APPLE"/>
+ <enum value="0x8A0B" name="GL_FENCE_APPLE"/>
+ <enum value="0x8A0C" name="GL_ELEMENT_ARRAY_APPLE"/>
+ <enum value="0x8A0D" name="GL_ELEMENT_ARRAY_TYPE_APPLE"/>
+ <enum value="0x8A0E" name="GL_ELEMENT_ARRAY_POINTER_APPLE"/>
+ <enum value="0x8A0F" name="GL_COLOR_FLOAT_APPLE"/>
+ <unused start="0x8A10" vendor="APPLE" comment="Unknown extension (Khronos bug 632)"/>
+ <!-- <enum value="0x8A10" name="GL_MIN_PBUFFER_VIEWPORT_DIMS_APPLE"/> -->
+ <enum value="0x8A11" name="GL_UNIFORM_BUFFER"/>
+ <enum value="0x8A12" name="GL_BUFFER_SERIALIZED_MODIFY_APPLE"/>
+ <enum value="0x8A13" name="GL_BUFFER_FLUSHING_UNMAP_APPLE"/>
+ <enum value="0x8A14" name="GL_AUX_DEPTH_STENCIL_APPLE"/>
+ <enum value="0x8A15" name="GL_PACK_ROW_BYTES_APPLE"/>
+ <enum value="0x8A16" name="GL_UNPACK_ROW_BYTES_APPLE"/>
+ <unused start="0x8A17" end="0x8A18" vendor="APPLE"/>
+ <enum value="0x8A19" name="GL_RELEASED_APPLE"/>
+ <enum value="0x8A1A" name="GL_VOLATILE_APPLE"/>
+ <enum value="0x8A1B" name="GL_RETAINED_APPLE"/>
+ <enum value="0x8A1C" name="GL_UNDEFINED_APPLE"/>
+ <enum value="0x8A1D" name="GL_PURGEABLE_APPLE"/>
+ <unused start="0x8A1E" vendor="APPLE"/>
+ <enum value="0x8A1F" name="GL_RGB_422_APPLE"/>
+ <unused start="0x8A20" end="0x8A27" vendor="APPLE"/>
+ <enum value="0x8A28" name="GL_UNIFORM_BUFFER_BINDING"/>
+ <enum value="0x8A29" name="GL_UNIFORM_BUFFER_START"/>
+ <enum value="0x8A2A" name="GL_UNIFORM_BUFFER_SIZE"/>
+ <enum value="0x8A2B" name="GL_MAX_VERTEX_UNIFORM_BLOCKS"/>
+ <enum value="0x8A2C" name="GL_MAX_GEOMETRY_UNIFORM_BLOCKS"/>
+ <enum value="0x8A2C" name="GL_MAX_GEOMETRY_UNIFORM_BLOCKS_EXT"/>
+ <enum value="0x8A2D" name="GL_MAX_FRAGMENT_UNIFORM_BLOCKS"/>
+ <enum value="0x8A2E" name="GL_MAX_COMBINED_UNIFORM_BLOCKS"/>
+ <enum value="0x8A2F" name="GL_MAX_UNIFORM_BUFFER_BINDINGS"/>
+ <enum value="0x8A30" name="GL_MAX_UNIFORM_BLOCK_SIZE"/>
+ <enum value="0x8A31" name="GL_MAX_COMBINED_VERTEX_UNIFORM_COMPONENTS"/>
+ <enum value="0x8A32" name="GL_MAX_COMBINED_GEOMETRY_UNIFORM_COMPONENTS"/>
+ <enum value="0x8A32" name="GL_MAX_COMBINED_GEOMETRY_UNIFORM_COMPONENTS_EXT"/>
+ <enum value="0x8A33" name="GL_MAX_COMBINED_FRAGMENT_UNIFORM_COMPONENTS"/>
+ <enum value="0x8A34" name="GL_UNIFORM_BUFFER_OFFSET_ALIGNMENT"/>
+ <enum value="0x8A35" name="GL_ACTIVE_UNIFORM_BLOCK_MAX_NAME_LENGTH"/>
+ <enum value="0x8A36" name="GL_ACTIVE_UNIFORM_BLOCKS"/>
+ <enum value="0x8A37" name="GL_UNIFORM_TYPE"/>
+ <enum value="0x8A38" name="GL_UNIFORM_SIZE"/>
+ <enum value="0x8A39" name="GL_UNIFORM_NAME_LENGTH"/>
+ <enum value="0x8A3A" name="GL_UNIFORM_BLOCK_INDEX"/>
+ <enum value="0x8A3B" name="GL_UNIFORM_OFFSET"/>
+ <enum value="0x8A3C" name="GL_UNIFORM_ARRAY_STRIDE"/>
+ <enum value="0x8A3D" name="GL_UNIFORM_MATRIX_STRIDE"/>
+ <enum value="0x8A3E" name="GL_UNIFORM_IS_ROW_MAJOR"/>
+ <enum value="0x8A3F" name="GL_UNIFORM_BLOCK_BINDING"/>
+ <enum value="0x8A40" name="GL_UNIFORM_BLOCK_DATA_SIZE"/>
+ <enum value="0x8A41" name="GL_UNIFORM_BLOCK_NAME_LENGTH"/>
+ <enum value="0x8A42" name="GL_UNIFORM_BLOCK_ACTIVE_UNIFORMS"/>
+ <enum value="0x8A43" name="GL_UNIFORM_BLOCK_ACTIVE_UNIFORM_INDICES"/>
+ <enum value="0x8A44" name="GL_UNIFORM_BLOCK_REFERENCED_BY_VERTEX_SHADER"/>
+ <enum value="0x8A45" name="GL_UNIFORM_BLOCK_REFERENCED_BY_GEOMETRY_SHADER"/>
+ <enum value="0x8A46" name="GL_UNIFORM_BLOCK_REFERENCED_BY_FRAGMENT_SHADER"/>
+ <unused start="0x8A47" vendor="APPLE"/>
+ <enum value="0x8A48" name="GL_TEXTURE_SRGB_DECODE_EXT"/>
+ <enum value="0x8A49" name="GL_DECODE_EXT"/>
+ <enum value="0x8A4A" name="GL_SKIP_DECODE_EXT"/>
+ <unused start="0x8A4B" end="0x8A4E" vendor="APPLE"/>
+ <enum value="0x8A4F" name="GL_PROGRAM_PIPELINE_OBJECT_EXT"/>
+ <unused start="0x8A50" vendor="APPLE"/>
+ <enum value="0x8A51" name="GL_RGB_RAW_422_APPLE"/>
+ <enum value="0x8A52" name="GL_FRAGMENT_SHADER_DISCARDS_SAMPLES_EXT"/>
+ <enum value="0x8A53" name="GL_SYNC_OBJECT_APPLE"/>
+ <enum value="0x8A54" name="GL_COMPRESSED_SRGB_PVRTC_2BPPV1_EXT"/>
+ <enum value="0x8A55" name="GL_COMPRESSED_SRGB_PVRTC_4BPPV1_EXT"/>
+ <enum value="0x8A56" name="GL_COMPRESSED_SRGB_ALPHA_PVRTC_2BPPV1_EXT"/>
+ <enum value="0x8A57" name="GL_COMPRESSED_SRGB_ALPHA_PVRTC_4BPPV1_EXT"/>
+ <unused start="0x8A58" end="0x8A7F" vendor="APPLE"/>
+ </enums>
+
+ <enums namespace="GL" start="0x8A80" end="0x8AEF" vendor="Matrox">
+ <unused start="0x8A80" end="0x8AEF" vendor="Matrox"/>
+ </enums>
+
+ <enums namespace="GL" start="0x8AF0" end="0x8B2F" vendor="Chromium" comment="For Brian Paul">
+ <unused start="0x8AF0" end="0x8B2F" vendor="Chromium"/>
+ </enums>
+
+ <enums namespace="GL" start="0x8B30" end="0x8B3F" group="ShaderType" vendor="ARB">
+ <enum value="0x8B30" name="GL_FRAGMENT_SHADER"/>
+ <enum value="0x8B30" name="GL_FRAGMENT_SHADER_ARB"/>
+ <enum value="0x8B31" name="GL_VERTEX_SHADER"/>
+ <enum value="0x8B31" name="GL_VERTEX_SHADER_ARB"/>
+ <unused start="0x8B32" end="0x8B3F" comment="For shader types"/>
+ </enums>
+
+ <enums namespace="GL" start="0x8B40" end="0x8B47" group="ContainerType" vendor="ARB">
+ <enum value="0x8B40" name="GL_PROGRAM_OBJECT_ARB"/>
+ <enum value="0x8B40" name="GL_PROGRAM_OBJECT_EXT"/>
+ <unused start="0x8B41" end="0x8B47" comment="For container types"/>
+ </enums>
+
+ <enums namespace="GL" start="0x8B48" end="0x8B4F" vendor="ARB">
+ <enum value="0x8B48" name="GL_SHADER_OBJECT_ARB"/>
+ <enum value="0x8B48" name="GL_SHADER_OBJECT_EXT"/>
+ <enum value="0x8B49" name="GL_MAX_FRAGMENT_UNIFORM_COMPONENTS"/>
+ <enum value="0x8B49" name="GL_MAX_FRAGMENT_UNIFORM_COMPONENTS_ARB"/>
+ <enum value="0x8B4A" name="GL_MAX_VERTEX_UNIFORM_COMPONENTS"/>
+ <enum value="0x8B4A" name="GL_MAX_VERTEX_UNIFORM_COMPONENTS_ARB"/>
+ <enum value="0x8B4B" name="GL_MAX_VARYING_FLOATS"/>
+ <enum value="0x8B4B" name="GL_MAX_VARYING_COMPONENTS" alias="MAX_VARYING_FLOATS"/>
+ <enum value="0x8B4B" name="GL_MAX_VARYING_COMPONENTS_EXT"/>
+ <enum value="0x8B4B" name="GL_MAX_VARYING_FLOATS_ARB"/>
+ <enum value="0x8B4C" name="GL_MAX_VERTEX_TEXTURE_IMAGE_UNITS"/>
+ <enum value="0x8B4C" name="GL_MAX_VERTEX_TEXTURE_IMAGE_UNITS_ARB"/>
+ <enum value="0x8B4D" name="GL_MAX_COMBINED_TEXTURE_IMAGE_UNITS"/>
+ <enum value="0x8B4D" name="GL_MAX_COMBINED_TEXTURE_IMAGE_UNITS_ARB"/>
+ <enum value="0x8B4E" name="GL_OBJECT_TYPE_ARB"/>
+ <enum value="0x8B4F" name="GL_SHADER_TYPE"/>
+ <enum value="0x8B4F" name="GL_OBJECT_SUBTYPE_ARB"/>
+ </enums>
+
+ <enums namespace="GL" start="0x8B50" end="0x8B7F" group="AttributeType" vendor="ARB">
+ <enum value="0x8B50" name="GL_FLOAT_VEC2"/>
+ <enum value="0x8B50" name="GL_FLOAT_VEC2_ARB"/>
+ <enum value="0x8B51" name="GL_FLOAT_VEC3"/>
+ <enum value="0x8B51" name="GL_FLOAT_VEC3_ARB"/>
+ <enum value="0x8B52" name="GL_FLOAT_VEC4"/>
+ <enum value="0x8B52" name="GL_FLOAT_VEC4_ARB"/>
+ <enum value="0x8B53" name="GL_INT_VEC2"/>
+ <enum value="0x8B53" name="GL_INT_VEC2_ARB"/>
+ <enum value="0x8B54" name="GL_INT_VEC3"/>
+ <enum value="0x8B54" name="GL_INT_VEC3_ARB"/>
+ <enum value="0x8B55" name="GL_INT_VEC4"/>
+ <enum value="0x8B55" name="GL_INT_VEC4_ARB"/>
+ <enum value="0x8B56" name="GL_BOOL"/>
+ <enum value="0x8B56" name="GL_BOOL_ARB"/>
+ <enum value="0x8B57" name="GL_BOOL_VEC2"/>
+ <enum value="0x8B57" name="GL_BOOL_VEC2_ARB"/>
+ <enum value="0x8B58" name="GL_BOOL_VEC3"/>
+ <enum value="0x8B58" name="GL_BOOL_VEC3_ARB"/>
+ <enum value="0x8B59" name="GL_BOOL_VEC4"/>
+ <enum value="0x8B59" name="GL_BOOL_VEC4_ARB"/>
+ <enum value="0x8B5A" name="GL_FLOAT_MAT2"/>
+ <enum value="0x8B5A" name="GL_FLOAT_MAT2_ARB"/>
+ <enum value="0x8B5B" name="GL_FLOAT_MAT3"/>
+ <enum value="0x8B5B" name="GL_FLOAT_MAT3_ARB"/>
+ <enum value="0x8B5C" name="GL_FLOAT_MAT4"/>
+ <enum value="0x8B5C" name="GL_FLOAT_MAT4_ARB"/>
+ <enum value="0x8B5D" name="GL_SAMPLER_1D"/>
+ <enum value="0x8B5D" name="GL_SAMPLER_1D_ARB"/>
+ <enum value="0x8B5E" name="GL_SAMPLER_2D"/>
+ <enum value="0x8B5E" name="GL_SAMPLER_2D_ARB"/>
+ <enum value="0x8B5F" name="GL_SAMPLER_3D"/>
+ <enum value="0x8B5F" name="GL_SAMPLER_3D_ARB"/>
+ <enum value="0x8B5F" name="GL_SAMPLER_3D_OES"/>
+ <enum value="0x8B60" name="GL_SAMPLER_CUBE"/>
+ <enum value="0x8B60" name="GL_SAMPLER_CUBE_ARB"/>
+ <enum value="0x8B61" name="GL_SAMPLER_1D_SHADOW"/>
+ <enum value="0x8B61" name="GL_SAMPLER_1D_SHADOW_ARB"/>
+ <enum value="0x8B62" name="GL_SAMPLER_2D_SHADOW"/>
+ <enum value="0x8B62" name="GL_SAMPLER_2D_SHADOW_ARB"/>
+ <enum value="0x8B62" name="GL_SAMPLER_2D_SHADOW_EXT"/>
+ <enum value="0x8B63" name="GL_SAMPLER_2D_RECT"/>
+ <enum value="0x8B63" name="GL_SAMPLER_2D_RECT_ARB"/>
+ <enum value="0x8B64" name="GL_SAMPLER_2D_RECT_SHADOW"/>
+ <enum value="0x8B64" name="GL_SAMPLER_2D_RECT_SHADOW_ARB"/>
+ <enum value="0x8B65" name="GL_FLOAT_MAT2x3"/>
+ <enum value="0x8B65" name="GL_FLOAT_MAT2x3_NV"/>
+ <enum value="0x8B66" name="GL_FLOAT_MAT2x4"/>
+ <enum value="0x8B66" name="GL_FLOAT_MAT2x4_NV"/>
+ <enum value="0x8B67" name="GL_FLOAT_MAT3x2"/>
+ <enum value="0x8B67" name="GL_FLOAT_MAT3x2_NV"/>
+ <enum value="0x8B68" name="GL_FLOAT_MAT3x4"/>
+ <enum value="0x8B68" name="GL_FLOAT_MAT3x4_NV"/>
+ <enum value="0x8B69" name="GL_FLOAT_MAT4x2"/>
+ <enum value="0x8B69" name="GL_FLOAT_MAT4x2_NV"/>
+ <enum value="0x8B6A" name="GL_FLOAT_MAT4x3"/>
+ <enum value="0x8B6A" name="GL_FLOAT_MAT4x3_NV"/>
+ <unused start="0x8B6B" end="0x8B7F" comment="For attribute types"/>
+ </enums>
+
+ <enums namespace="GL" start="0x8B80" end="0x8B8F" vendor="ARB">
+ <enum value="0x8B80" name="GL_DELETE_STATUS"/>
+ <enum value="0x8B80" name="GL_OBJECT_DELETE_STATUS_ARB"/>
+ <enum value="0x8B81" name="GL_COMPILE_STATUS"/>
+ <enum value="0x8B81" name="GL_OBJECT_COMPILE_STATUS_ARB"/>
+ <enum value="0x8B82" name="GL_LINK_STATUS"/>
+ <enum value="0x8B82" name="GL_OBJECT_LINK_STATUS_ARB"/>
+ <enum value="0x8B83" name="GL_VALIDATE_STATUS"/>
+ <enum value="0x8B83" name="GL_OBJECT_VALIDATE_STATUS_ARB"/>
+ <enum value="0x8B84" name="GL_INFO_LOG_LENGTH"/>
+ <enum value="0x8B84" name="GL_OBJECT_INFO_LOG_LENGTH_ARB"/>
+ <enum value="0x8B85" name="GL_ATTACHED_SHADERS"/>
+ <enum value="0x8B85" name="GL_OBJECT_ATTACHED_OBJECTS_ARB"/>
+ <enum value="0x8B86" name="GL_ACTIVE_UNIFORMS"/>
+ <enum value="0x8B86" name="GL_OBJECT_ACTIVE_UNIFORMS_ARB"/>
+ <enum value="0x8B87" name="GL_ACTIVE_UNIFORM_MAX_LENGTH"/>
+ <enum value="0x8B87" name="GL_OBJECT_ACTIVE_UNIFORM_MAX_LENGTH_ARB"/>
+ <enum value="0x8B88" name="GL_SHADER_SOURCE_LENGTH"/>
+ <enum value="0x8B88" name="GL_OBJECT_SHADER_SOURCE_LENGTH_ARB"/>
+ <enum value="0x8B89" name="GL_ACTIVE_ATTRIBUTES"/>
+ <enum value="0x8B89" name="GL_OBJECT_ACTIVE_ATTRIBUTES_ARB"/>
+ <enum value="0x8B8A" name="GL_ACTIVE_ATTRIBUTE_MAX_LENGTH"/>
+ <enum value="0x8B8A" name="GL_OBJECT_ACTIVE_ATTRIBUTE_MAX_LENGTH_ARB"/>
+ <enum value="0x8B8B" name="GL_FRAGMENT_SHADER_DERIVATIVE_HINT"/>
+ <enum value="0x8B8B" name="GL_FRAGMENT_SHADER_DERIVATIVE_HINT_ARB"/>
+ <enum value="0x8B8B" name="GL_FRAGMENT_SHADER_DERIVATIVE_HINT_OES"/>
+ <enum value="0x8B8C" name="GL_SHADING_LANGUAGE_VERSION"/>
+ <enum value="0x8B8C" name="GL_SHADING_LANGUAGE_VERSION_ARB"/>
+ <enum value="0x8B8D" name="GL_CURRENT_PROGRAM"/>
+ <enum value="0x8B8D" api="gl" name="GL_ACTIVE_PROGRAM_EXT" alias="GL_CURRENT_PROGRAM" comment="For the OpenGL version of EXT_separate_shader_objects"/>
+ <unused start="0x8B8E" end="0x8B8F" vendor="ARB"/>
+ </enums>
+
+ <enums namespace="GL" start="0x8B90" end="0x8B9F" vendor="OES">
+ <enum value="0x8B90" name="GL_PALETTE4_RGB8_OES"/>
+ <enum value="0x8B91" name="GL_PALETTE4_RGBA8_OES"/>
+ <enum value="0x8B92" name="GL_PALETTE4_R5_G6_B5_OES"/>
+ <enum value="0x8B93" name="GL_PALETTE4_RGBA4_OES"/>
+ <enum value="0x8B94" name="GL_PALETTE4_RGB5_A1_OES"/>
+ <enum value="0x8B95" name="GL_PALETTE8_RGB8_OES"/>
+ <enum value="0x8B96" name="GL_PALETTE8_RGBA8_OES"/>
+ <enum value="0x8B97" name="GL_PALETTE8_R5_G6_B5_OES"/>
+ <enum value="0x8B98" name="GL_PALETTE8_RGBA4_OES"/>
+ <enum value="0x8B99" name="GL_PALETTE8_RGB5_A1_OES"/>
+ <enum value="0x8B9A" name="GL_IMPLEMENTATION_COLOR_READ_TYPE"/>
+ <enum value="0x8B9A" name="GL_IMPLEMENTATION_COLOR_READ_TYPE_OES"/>
+ <enum value="0x8B9B" name="GL_IMPLEMENTATION_COLOR_READ_FORMAT"/>
+ <enum value="0x8B9B" name="GL_IMPLEMENTATION_COLOR_READ_FORMAT_OES"/>
+ <enum value="0x8B9C" name="GL_POINT_SIZE_ARRAY_OES"/>
+ <enum value="0x8B9D" name="GL_TEXTURE_CROP_RECT_OES"/>
+ <enum value="0x8B9E" name="GL_MATRIX_INDEX_ARRAY_BUFFER_BINDING_OES"/>
+ <enum value="0x8B9F" name="GL_POINT_SIZE_ARRAY_BUFFER_BINDING_OES"/>
+ </enums>
+
+ <enums namespace="GL" start="0x8BA0" end="0x8BAF" vendor="Seaweed">
+ <unused start="0x8BA0" end="0x8BAF" vendor="Seaweed"/>
+ </enums>
+
+ <enums namespace="GL" start="0x8BB0" end="0x8BBF" vendor="MESA">
+ <enum value="0x8BB0" name="GL_FRAGMENT_PROGRAM_POSITION_MESA"/>
+ <enum value="0x8BB1" name="GL_FRAGMENT_PROGRAM_CALLBACK_MESA"/>
+ <enum value="0x8BB2" name="GL_FRAGMENT_PROGRAM_CALLBACK_FUNC_MESA"/>
+ <enum value="0x8BB3" name="GL_FRAGMENT_PROGRAM_CALLBACK_DATA_MESA"/>
+ <enum value="0x8BB4" name="GL_VERTEX_PROGRAM_POSITION_MESA"/>
+ <enum value="0x8BB5" name="GL_VERTEX_PROGRAM_CALLBACK_MESA"/>
+ <enum value="0x8BB6" name="GL_VERTEX_PROGRAM_CALLBACK_FUNC_MESA"/>
+ <enum value="0x8BB7" name="GL_VERTEX_PROGRAM_CALLBACK_DATA_MESA"/>
+ </enums>
+
+ <enums namespace="GL" start="0x8BC0" end="0x8BFF" vendor="AMD">
+ <enum value="0x8BC0" name="GL_COUNTER_TYPE_AMD"/>
+ <enum value="0x8BC1" name="GL_COUNTER_RANGE_AMD"/>
+ <enum value="0x8BC2" name="GL_UNSIGNED_INT64_AMD"/>
+ <enum value="0x8BC3" name="GL_PERCENTAGE_AMD"/>
+ <enum value="0x8BC4" name="GL_PERFMON_RESULT_AVAILABLE_AMD"/>
+ <enum value="0x8BC5" name="GL_PERFMON_RESULT_SIZE_AMD"/>
+ <enum value="0x8BC6" name="GL_PERFMON_RESULT_AMD"/>
+ <unused start="0x8BC7" end="0x8BD1" vendor="AMD"/>
+ <enum value="0x8BD2" name="GL_TEXTURE_WIDTH_QCOM"/>
+ <enum value="0x8BD3" name="GL_TEXTURE_HEIGHT_QCOM"/>
+ <enum value="0x8BD4" name="GL_TEXTURE_DEPTH_QCOM"/>
+ <enum value="0x8BD5" name="GL_TEXTURE_INTERNAL_FORMAT_QCOM"/>
+ <enum value="0x8BD6" name="GL_TEXTURE_FORMAT_QCOM"/>
+ <enum value="0x8BD7" name="GL_TEXTURE_TYPE_QCOM"/>
+ <enum value="0x8BD8" name="GL_TEXTURE_IMAGE_VALID_QCOM"/>
+ <enum value="0x8BD9" name="GL_TEXTURE_NUM_LEVELS_QCOM"/>
+ <enum value="0x8BDA" name="GL_TEXTURE_TARGET_QCOM"/>
+ <enum value="0x8BDB" name="GL_TEXTURE_OBJECT_VALID_QCOM"/>
+ <enum value="0x8BDC" name="GL_STATE_RESTORE"/>
+ <unused start="0x8BDD" end="0x8BFF" vendor="AMD"/>
+ </enums>
+
+ <enums namespace="GL" start="0x8C00" end="0x8C0F" vendor="IMG">
+ <enum value="0x8C00" name="GL_COMPRESSED_RGB_PVRTC_4BPPV1_IMG"/>
+ <enum value="0x8C01" name="GL_COMPRESSED_RGB_PVRTC_2BPPV1_IMG"/>
+ <enum value="0x8C02" name="GL_COMPRESSED_RGBA_PVRTC_4BPPV1_IMG"/>
+ <enum value="0x8C03" name="GL_COMPRESSED_RGBA_PVRTC_2BPPV1_IMG"/>
+ <enum value="0x8C04" name="GL_MODULATE_COLOR_IMG"/>
+ <enum value="0x8C05" name="GL_RECIP_ADD_SIGNED_ALPHA_IMG"/>
+ <enum value="0x8C06" name="GL_TEXTURE_ALPHA_MODULATE_IMG"/>
+ <enum value="0x8C07" name="GL_FACTOR_ALPHA_MODULATE_IMG"/>
+ <enum value="0x8C08" name="GL_FRAGMENT_ALPHA_MODULATE_IMG"/>
+ <enum value="0x8C09" name="GL_ADD_BLEND_IMG"/>
+ <enum value="0x8C0A" name="GL_SGX_BINARY_IMG"/>
+ <unused start="0x8C0B" end="0x8C0F" vendor="IMG"/>
+ </enums>
+
+ <enums namespace="GL" start="0x8C10" end="0x8C8F" vendor="NV" comment="For Pat Brown">
+ <enum value="0x8C10" name="GL_TEXTURE_RED_TYPE"/>
+ <enum value="0x8C10" name="GL_TEXTURE_RED_TYPE_ARB"/>
+ <enum value="0x8C11" name="GL_TEXTURE_GREEN_TYPE"/>
+ <enum value="0x8C11" name="GL_TEXTURE_GREEN_TYPE_ARB"/>
+ <enum value="0x8C12" name="GL_TEXTURE_BLUE_TYPE"/>
+ <enum value="0x8C12" name="GL_TEXTURE_BLUE_TYPE_ARB"/>
+ <enum value="0x8C13" name="GL_TEXTURE_ALPHA_TYPE"/>
+ <enum value="0x8C13" name="GL_TEXTURE_ALPHA_TYPE_ARB"/>
+ <enum value="0x8C14" name="GL_TEXTURE_LUMINANCE_TYPE"/>
+ <enum value="0x8C14" name="GL_TEXTURE_LUMINANCE_TYPE_ARB"/>
+ <enum value="0x8C15" name="GL_TEXTURE_INTENSITY_TYPE"/>
+ <enum value="0x8C15" name="GL_TEXTURE_INTENSITY_TYPE_ARB"/>
+ <enum value="0x8C16" name="GL_TEXTURE_DEPTH_TYPE"/>
+ <enum value="0x8C16" name="GL_TEXTURE_DEPTH_TYPE_ARB"/>
+ <enum value="0x8C17" name="GL_UNSIGNED_NORMALIZED"/>
+ <enum value="0x8C17" name="GL_UNSIGNED_NORMALIZED_ARB"/>
+ <enum value="0x8C17" name="GL_UNSIGNED_NORMALIZED_EXT"/>
+ <enum value="0x8C18" name="GL_TEXTURE_1D_ARRAY"/>
+ <enum value="0x8C18" name="GL_TEXTURE_1D_ARRAY_EXT"/>
+ <enum value="0x8C19" name="GL_PROXY_TEXTURE_1D_ARRAY"/>
+ <enum value="0x8C19" name="GL_PROXY_TEXTURE_1D_ARRAY_EXT"/>
+ <enum value="0x8C1A" name="GL_TEXTURE_2D_ARRAY"/>
+ <enum value="0x8C1A" name="GL_TEXTURE_2D_ARRAY_EXT"/>
+ <enum value="0x8C1B" name="GL_PROXY_TEXTURE_2D_ARRAY"/>
+ <enum value="0x8C1B" name="GL_PROXY_TEXTURE_2D_ARRAY_EXT"/>
+ <enum value="0x8C1C" name="GL_TEXTURE_BINDING_1D_ARRAY"/>
+ <enum value="0x8C1C" name="GL_TEXTURE_BINDING_1D_ARRAY_EXT"/>
+ <enum value="0x8C1D" name="GL_TEXTURE_BINDING_2D_ARRAY"/>
+ <enum value="0x8C1D" name="GL_TEXTURE_BINDING_2D_ARRAY_EXT"/>
+ <unused start="0x8C1E" end="0x8C25" vendor="NV"/>
+ <enum value="0x8C26" name="GL_GEOMETRY_PROGRAM_NV"/>
+ <enum value="0x8C27" name="GL_MAX_PROGRAM_OUTPUT_VERTICES_NV"/>
+ <enum value="0x8C28" name="GL_MAX_PROGRAM_TOTAL_OUTPUT_COMPONENTS_NV"/>
+ <enum value="0x8C29" name="GL_MAX_GEOMETRY_TEXTURE_IMAGE_UNITS"/>
+ <enum value="0x8C29" name="GL_MAX_GEOMETRY_TEXTURE_IMAGE_UNITS_ARB"/>
+ <enum value="0x8C29" name="GL_MAX_GEOMETRY_TEXTURE_IMAGE_UNITS_EXT"/>
+ <enum value="0x8C2A" name="GL_TEXTURE_BUFFER"/>
+ <enum value="0x8C2A" name="GL_TEXTURE_BUFFER_ARB"/>
+ <enum value="0x8C2A" name="GL_TEXTURE_BUFFER_EXT"/>
+ <enum value="0x8C2A" name="GL_TEXTURE_BUFFER_BINDING" comment="Equivalent to GL_TEXTURE_BUFFER_ARB query, but named more consistently"/>
+ <enum value="0x8C2A" name="GL_TEXTURE_BUFFER_BINDING_EXT"/>
+ <enum value="0x8C2B" name="GL_MAX_TEXTURE_BUFFER_SIZE"/>
+ <enum value="0x8C2B" name="GL_MAX_TEXTURE_BUFFER_SIZE_ARB"/>
+ <enum value="0x8C2B" name="GL_MAX_TEXTURE_BUFFER_SIZE_EXT"/>
+ <enum value="0x8C2C" name="GL_TEXTURE_BINDING_BUFFER"/>
+ <enum value="0x8C2C" name="GL_TEXTURE_BINDING_BUFFER_ARB"/>
+ <enum value="0x8C2C" name="GL_TEXTURE_BINDING_BUFFER_EXT"/>
+ <enum value="0x8C2D" name="GL_TEXTURE_BUFFER_DATA_STORE_BINDING"/>
+ <enum value="0x8C2D" name="GL_TEXTURE_BUFFER_DATA_STORE_BINDING_ARB"/>
+ <enum value="0x8C2D" name="GL_TEXTURE_BUFFER_DATA_STORE_BINDING_EXT"/>
+ <enum value="0x8C2E" name="GL_TEXTURE_BUFFER_FORMAT_ARB"/>
+ <enum value="0x8C2E" name="GL_TEXTURE_BUFFER_FORMAT_EXT"/>
+ <enum value="0x8C2F" name="GL_ANY_SAMPLES_PASSED"/>
+ <enum value="0x8C2F" name="GL_ANY_SAMPLES_PASSED_EXT"/>
+ <unused start="0x8C30" end="0x8C35" vendor="NV"/>
+ <enum value="0x8C36" name="GL_SAMPLE_SHADING"/>
+ <enum value="0x8C36" name="GL_SAMPLE_SHADING_ARB"/>
+ <enum value="0x8C36" name="GL_SAMPLE_SHADING_OES"/>
+ <enum value="0x8C37" name="GL_MIN_SAMPLE_SHADING_VALUE"/>
+ <enum value="0x8C37" name="GL_MIN_SAMPLE_SHADING_VALUE_ARB"/>
+ <enum value="0x8C37" name="GL_MIN_SAMPLE_SHADING_VALUE_OES"/>
+ <unused start="0x8C38" end="0x8C39" vendor="NV"/>
+ <enum value="0x8C3A" name="GL_R11F_G11F_B10F"/>
+ <enum value="0x8C3A" name="GL_R11F_G11F_B10F_EXT"/>
+ <enum value="0x8C3B" name="GL_UNSIGNED_INT_10F_11F_11F_REV"/>
+ <enum value="0x8C3B" name="GL_UNSIGNED_INT_10F_11F_11F_REV_EXT"/>
+ <enum value="0x8C3C" name="GL_RGBA_SIGNED_COMPONENTS_EXT"/>
+ <enum value="0x8C3D" name="GL_RGB9_E5"/>
+ <enum value="0x8C3D" name="GL_RGB9_E5_EXT"/>
+ <enum value="0x8C3E" name="GL_UNSIGNED_INT_5_9_9_9_REV"/>
+ <enum value="0x8C3E" name="GL_UNSIGNED_INT_5_9_9_9_REV_EXT"/>
+ <enum value="0x8C3F" name="GL_TEXTURE_SHARED_SIZE"/>
+ <enum value="0x8C3F" name="GL_TEXTURE_SHARED_SIZE_EXT"/>
+ <enum value="0x8C40" name="GL_SRGB"/>
+ <enum value="0x8C40" name="GL_SRGB_EXT"/>
+ <enum value="0x8C41" name="GL_SRGB8"/>
+ <enum value="0x8C41" name="GL_SRGB8_EXT"/>
+ <enum value="0x8C41" name="GL_SRGB8_NV"/>
+ <enum value="0x8C42" name="GL_SRGB_ALPHA"/>
+ <enum value="0x8C42" name="GL_SRGB_ALPHA_EXT"/>
+ <enum value="0x8C43" name="GL_SRGB8_ALPHA8"/>
+ <enum value="0x8C43" name="GL_SRGB8_ALPHA8_EXT"/>
+ <enum value="0x8C44" name="GL_SLUMINANCE_ALPHA"/>
+ <enum value="0x8C44" name="GL_SLUMINANCE_ALPHA_EXT"/>
+ <enum value="0x8C44" name="GL_SLUMINANCE_ALPHA_NV"/>
+ <enum value="0x8C45" name="GL_SLUMINANCE8_ALPHA8"/>
+ <enum value="0x8C45" name="GL_SLUMINANCE8_ALPHA8_EXT"/>
+ <enum value="0x8C45" name="GL_SLUMINANCE8_ALPHA8_NV"/>
+ <enum value="0x8C46" name="GL_SLUMINANCE"/>
+ <enum value="0x8C46" name="GL_SLUMINANCE_EXT"/>
+ <enum value="0x8C46" name="GL_SLUMINANCE_NV"/>
+ <enum value="0x8C47" name="GL_SLUMINANCE8"/>
+ <enum value="0x8C47" name="GL_SLUMINANCE8_EXT"/>
+ <enum value="0x8C47" name="GL_SLUMINANCE8_NV"/>
+ <enum value="0x8C48" name="GL_COMPRESSED_SRGB"/>
+ <enum value="0x8C48" name="GL_COMPRESSED_SRGB_EXT"/>
+ <enum value="0x8C49" name="GL_COMPRESSED_SRGB_ALPHA"/>
+ <enum value="0x8C49" name="GL_COMPRESSED_SRGB_ALPHA_EXT"/>
+ <enum value="0x8C4A" name="GL_COMPRESSED_SLUMINANCE"/>
+ <enum value="0x8C4A" name="GL_COMPRESSED_SLUMINANCE_EXT"/>
+ <enum value="0x8C4B" name="GL_COMPRESSED_SLUMINANCE_ALPHA"/>
+ <enum value="0x8C4B" name="GL_COMPRESSED_SLUMINANCE_ALPHA_EXT"/>
+ <enum value="0x8C4C" name="GL_COMPRESSED_SRGB_S3TC_DXT1_EXT"/>
+ <enum value="0x8C4C" name="GL_COMPRESSED_SRGB_S3TC_DXT1_NV"/>
+ <enum value="0x8C4D" name="GL_COMPRESSED_SRGB_ALPHA_S3TC_DXT1_EXT"/>
+ <enum value="0x8C4D" name="GL_COMPRESSED_SRGB_ALPHA_S3TC_DXT1_NV"/>
+ <enum value="0x8C4E" name="GL_COMPRESSED_SRGB_ALPHA_S3TC_DXT3_EXT"/>
+ <enum value="0x8C4E" name="GL_COMPRESSED_SRGB_ALPHA_S3TC_DXT3_NV"/>
+ <enum value="0x8C4F" name="GL_COMPRESSED_SRGB_ALPHA_S3TC_DXT5_EXT"/>
+ <enum value="0x8C4F" name="GL_COMPRESSED_SRGB_ALPHA_S3TC_DXT5_NV"/>
+ <unused start="0x8C50" end="0x8C6F" vendor="NV"/>
+ <enum value="0x8C70" name="GL_COMPRESSED_LUMINANCE_LATC1_EXT"/>
+ <enum value="0x8C71" name="GL_COMPRESSED_SIGNED_LUMINANCE_LATC1_EXT"/>
+ <enum value="0x8C72" name="GL_COMPRESSED_LUMINANCE_ALPHA_LATC2_EXT"/>
+ <enum value="0x8C73" name="GL_COMPRESSED_SIGNED_LUMINANCE_ALPHA_LATC2_EXT"/>
+ <enum value="0x8C74" name="GL_TESS_CONTROL_PROGRAM_PARAMETER_BUFFER_NV"/>
+ <enum value="0x8C75" name="GL_TESS_EVALUATION_PROGRAM_PARAMETER_BUFFER_NV"/>
+ <enum value="0x8C76" name="GL_TRANSFORM_FEEDBACK_VARYING_MAX_LENGTH"/>
+ <enum value="0x8C76" name="GL_TRANSFORM_FEEDBACK_VARYING_MAX_LENGTH_EXT"/>
+ <enum value="0x8C77" name="GL_BACK_PRIMARY_COLOR_NV"/>
+ <enum value="0x8C78" name="GL_BACK_SECONDARY_COLOR_NV"/>
+ <enum value="0x8C79" name="GL_TEXTURE_COORD_NV"/>
+ <enum value="0x8C7A" name="GL_CLIP_DISTANCE_NV"/>
+ <enum value="0x8C7B" name="GL_VERTEX_ID_NV"/>
+ <enum value="0x8C7C" name="GL_PRIMITIVE_ID_NV"/>
+ <enum value="0x8C7D" name="GL_GENERIC_ATTRIB_NV"/>
+ <enum value="0x8C7E" name="GL_TRANSFORM_FEEDBACK_ATTRIBS_NV"/>
+ <enum value="0x8C7F" name="GL_TRANSFORM_FEEDBACK_BUFFER_MODE"/>
+ <enum value="0x8C7F" name="GL_TRANSFORM_FEEDBACK_BUFFER_MODE_EXT"/>
+ <enum value="0x8C7F" name="GL_TRANSFORM_FEEDBACK_BUFFER_MODE_NV"/>
+ <enum value="0x8C80" name="GL_MAX_TRANSFORM_FEEDBACK_SEPARATE_COMPONENTS"/>
+ <enum value="0x8C80" name="GL_MAX_TRANSFORM_FEEDBACK_SEPARATE_COMPONENTS_EXT"/>
+ <enum value="0x8C80" name="GL_MAX_TRANSFORM_FEEDBACK_SEPARATE_COMPONENTS_NV"/>
+ <enum value="0x8C81" name="GL_ACTIVE_VARYINGS_NV"/>
+ <enum value="0x8C82" name="GL_ACTIVE_VARYING_MAX_LENGTH_NV"/>
+ <enum value="0x8C83" name="GL_TRANSFORM_FEEDBACK_VARYINGS"/>
+ <enum value="0x8C83" name="GL_TRANSFORM_FEEDBACK_VARYINGS_EXT"/>
+ <enum value="0x8C83" name="GL_TRANSFORM_FEEDBACK_VARYINGS_NV"/>
+ <enum value="0x8C84" name="GL_TRANSFORM_FEEDBACK_BUFFER_START"/>
+ <enum value="0x8C84" name="GL_TRANSFORM_FEEDBACK_BUFFER_START_EXT"/>
+ <enum value="0x8C84" name="GL_TRANSFORM_FEEDBACK_BUFFER_START_NV"/>
+ <enum value="0x8C85" name="GL_TRANSFORM_FEEDBACK_BUFFER_SIZE"/>
+ <enum value="0x8C85" name="GL_TRANSFORM_FEEDBACK_BUFFER_SIZE_EXT"/>
+ <enum value="0x8C85" name="GL_TRANSFORM_FEEDBACK_BUFFER_SIZE_NV"/>
+ <enum value="0x8C86" name="GL_TRANSFORM_FEEDBACK_RECORD_NV"/>
+ <enum value="0x8C87" name="GL_PRIMITIVES_GENERATED"/>
+ <enum value="0x8C87" name="GL_PRIMITIVES_GENERATED_EXT"/>
+ <enum value="0x8C87" name="GL_PRIMITIVES_GENERATED_NV"/>
+ <enum value="0x8C88" name="GL_TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN"/>
+ <enum value="0x8C88" name="GL_TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN_EXT"/>
+ <enum value="0x8C88" name="GL_TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN_NV"/>
+ <enum value="0x8C89" name="GL_RASTERIZER_DISCARD"/>
+ <enum value="0x8C89" name="GL_RASTERIZER_DISCARD_EXT"/>
+ <enum value="0x8C89" name="GL_RASTERIZER_DISCARD_NV"/>
+ <enum value="0x8C8A" name="GL_MAX_TRANSFORM_FEEDBACK_INTERLEAVED_COMPONENTS"/>
+ <enum value="0x8C8A" name="GL_MAX_TRANSFORM_FEEDBACK_INTERLEAVED_COMPONENTS_EXT"/>
+ <enum value="0x8C8A" name="GL_MAX_TRANSFORM_FEEDBACK_INTERLEAVED_COMPONENTS_NV"/>
+ <enum value="0x8C8B" name="GL_MAX_TRANSFORM_FEEDBACK_SEPARATE_ATTRIBS"/>
+ <enum value="0x8C8B" name="GL_MAX_TRANSFORM_FEEDBACK_SEPARATE_ATTRIBS_EXT"/>
+ <enum value="0x8C8B" name="GL_MAX_TRANSFORM_FEEDBACK_SEPARATE_ATTRIBS_NV"/>
+ <enum value="0x8C8C" name="GL_INTERLEAVED_ATTRIBS"/>
+ <enum value="0x8C8C" name="GL_INTERLEAVED_ATTRIBS_EXT"/>
+ <enum value="0x8C8C" name="GL_INTERLEAVED_ATTRIBS_NV"/>
+ <enum value="0x8C8D" name="GL_SEPARATE_ATTRIBS"/>
+ <enum value="0x8C8D" name="GL_SEPARATE_ATTRIBS_EXT"/>
+ <enum value="0x8C8D" name="GL_SEPARATE_ATTRIBS_NV"/>
+ <enum value="0x8C8E" name="GL_TRANSFORM_FEEDBACK_BUFFER"/>
+ <enum value="0x8C8E" name="GL_TRANSFORM_FEEDBACK_BUFFER_EXT"/>
+ <enum value="0x8C8E" name="GL_TRANSFORM_FEEDBACK_BUFFER_NV"/>
+ <enum value="0x8C8F" name="GL_TRANSFORM_FEEDBACK_BUFFER_BINDING"/>
+ <enum value="0x8C8F" name="GL_TRANSFORM_FEEDBACK_BUFFER_BINDING_EXT"/>
+ <enum value="0x8C8F" name="GL_TRANSFORM_FEEDBACK_BUFFER_BINDING_NV"/>
+ </enums>
+
+ <enums namespace="GL" start="0x8C90" end="0x8C9F" vendor="QCOM" comment="For Affie Munshi, OpenGL ES extensions">
+ <!-- Reassigned from ATI to QCOM at time of
+ mobile/desktop split (bug 5874) -->
+ <unused start="0x8C90" end="0x8C91" vendor="QCOM"/>
+ <enum value="0x8C92" name="GL_ATC_RGB_AMD"/>
+ <enum value="0x8C93" name="GL_ATC_RGBA_EXPLICIT_ALPHA_AMD"/>
+ <unused start="0x8C94" end="0x8C9F" vendor="QCOM"/>
+ </enums>
+
+ <enums namespace="GL" start="0x8CA0" end="0x8CAF" vendor="ARB">
+ <enum value="0x8CA0" name="GL_POINT_SPRITE_COORD_ORIGIN"/>
+ <enum value="0x8CA1" name="GL_LOWER_LEFT"/>
+ <enum value="0x8CA2" name="GL_UPPER_LEFT"/>
+ <enum value="0x8CA3" name="GL_STENCIL_BACK_REF"/>
+ <enum value="0x8CA4" name="GL_STENCIL_BACK_VALUE_MASK"/>
+ <enum value="0x8CA5" name="GL_STENCIL_BACK_WRITEMASK"/>
+ <enum value="0x8CA6" name="GL_DRAW_FRAMEBUFFER_BINDING"/>
+ <enum value="0x8CA6" name="GL_DRAW_FRAMEBUFFER_BINDING_ANGLE"/>
+ <enum value="0x8CA6" name="GL_DRAW_FRAMEBUFFER_BINDING_APPLE"/>
+ <enum value="0x8CA6" name="GL_DRAW_FRAMEBUFFER_BINDING_EXT"/>
+ <enum value="0x8CA6" name="GL_DRAW_FRAMEBUFFER_BINDING_NV"/>
+ <enum value="0x8CA6" name="GL_FRAMEBUFFER_BINDING"/>
+ <enum value="0x8CA6" name="GL_FRAMEBUFFER_BINDING_ANGLE"/>
+ <enum value="0x8CA6" name="GL_FRAMEBUFFER_BINDING_EXT"/>
+ <enum value="0x8CA6" name="GL_FRAMEBUFFER_BINDING_OES"/>
+ <enum value="0x8CA7" name="GL_RENDERBUFFER_BINDING"/>
+ <enum value="0x8CA7" name="GL_RENDERBUFFER_BINDING_ANGLE"/>
+ <enum value="0x8CA7" name="GL_RENDERBUFFER_BINDING_EXT"/>
+ <enum value="0x8CA7" name="GL_RENDERBUFFER_BINDING_OES"/>
+ <enum value="0x8CA8" name="GL_READ_FRAMEBUFFER"/>
+ <enum value="0x8CA8" name="GL_READ_FRAMEBUFFER_ANGLE"/>
+ <enum value="0x8CA8" name="GL_READ_FRAMEBUFFER_APPLE"/>
+ <enum value="0x8CA8" name="GL_READ_FRAMEBUFFER_EXT"/>
+ <enum value="0x8CA8" name="GL_READ_FRAMEBUFFER_NV"/>
+ <enum value="0x8CA9" name="GL_DRAW_FRAMEBUFFER"/>
+ <enum value="0x8CA9" name="GL_DRAW_FRAMEBUFFER_ANGLE"/>
+ <enum value="0x8CA9" name="GL_DRAW_FRAMEBUFFER_APPLE"/>
+ <enum value="0x8CA9" name="GL_DRAW_FRAMEBUFFER_EXT"/>
+ <enum value="0x8CA9" name="GL_DRAW_FRAMEBUFFER_NV"/>
+ <enum value="0x8CAA" name="GL_READ_FRAMEBUFFER_BINDING"/>
+ <enum value="0x8CAA" name="GL_READ_FRAMEBUFFER_BINDING_ANGLE"/>
+ <enum value="0x8CAA" name="GL_READ_FRAMEBUFFER_BINDING_APPLE"/>
+ <enum value="0x8CAA" name="GL_READ_FRAMEBUFFER_BINDING_EXT"/>
+ <enum value="0x8CAA" name="GL_READ_FRAMEBUFFER_BINDING_NV"/>
+ <enum value="0x8CAB" name="GL_RENDERBUFFER_COVERAGE_SAMPLES_NV"/>
+ <enum value="0x8CAB" name="GL_RENDERBUFFER_SAMPLES"/>
+ <enum value="0x8CAB" name="GL_RENDERBUFFER_SAMPLES_ANGLE"/>
+ <enum value="0x8CAB" name="GL_RENDERBUFFER_SAMPLES_APPLE"/>
+ <enum value="0x8CAB" name="GL_RENDERBUFFER_SAMPLES_EXT"/>
+ <enum value="0x8CAB" name="GL_RENDERBUFFER_SAMPLES_NV"/>
+ <enum value="0x8CAC" name="GL_DEPTH_COMPONENT32F"/>
+ <enum value="0x8CAD" name="GL_DEPTH32F_STENCIL8"/>
+ <unused start="0x8CAE" end="0x8CAF" vendor="ARB"/>
+ </enums>
+
+ <enums namespace="GL" start="0x8CB0" end="0x8CCF" vendor="ZiiLabs" comment="For Barthold Lichtenbelt 2004/12/1">
+ <unused start="0x8CB0" end="0x8CCF" vendor="ZiiLabs"/>
+ </enums>
+
+ <enums namespace="GL" start="0x8CD0" end="0x8D5F" vendor="ARB" comment="Framebuffer object specification + headroom">
+ <enum value="0x8CD0" name="GL_FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE"/>
+ <enum value="0x8CD0" name="GL_FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE_EXT"/>
+ <enum value="0x8CD0" name="GL_FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE_OES"/>
+ <enum value="0x8CD1" name="GL_FRAMEBUFFER_ATTACHMENT_OBJECT_NAME"/>
+ <enum value="0x8CD1" name="GL_FRAMEBUFFER_ATTACHMENT_OBJECT_NAME_EXT"/>
+ <enum value="0x8CD1" name="GL_FRAMEBUFFER_ATTACHMENT_OBJECT_NAME_OES"/>
+ <enum value="0x8CD2" name="GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL"/>
+ <enum value="0x8CD2" name="GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL_EXT"/>
+ <enum value="0x8CD2" name="GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL_OES"/>
+ <enum value="0x8CD3" name="GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE"/>
+ <enum value="0x8CD3" name="GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE_EXT"/>
+ <enum value="0x8CD3" name="GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE_OES"/>
+ <enum value="0x8CD4" name="GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_3D_ZOFFSET_EXT"/>
+ <enum value="0x8CD4" name="GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_3D_ZOFFSET_OES"/>
+ <enum value="0x8CD4" name="GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER"/>
+ <enum value="0x8CD4" name="GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER_EXT"/>
+ <enum value="0x8CD5" name="GL_FRAMEBUFFER_COMPLETE"/>
+ <enum value="0x8CD5" name="GL_FRAMEBUFFER_COMPLETE_EXT"/>
+ <enum value="0x8CD5" name="GL_FRAMEBUFFER_COMPLETE_OES"/>
+ <enum value="0x8CD6" name="GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT"/>
+ <enum value="0x8CD6" name="GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT_EXT"/>
+ <enum value="0x8CD6" name="GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT_OES"/>
+ <enum value="0x8CD7" name="GL_FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT"/>
+ <enum value="0x8CD7" name="GL_FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT_EXT"/>
+ <enum value="0x8CD7" name="GL_FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT_OES"/>
+ <unused start="0x8CD8" vendor="ARB" comment="Removed 2005/09/26 in revision #117 of the FBO extension spec"/>
+ <!-- <enum value="0x8CD8" name="GL_FRAMEBUFFER_INCOMPLETE_DUPLICATE_ATTACHMENT_EXT"/> -->
+ <enum value="0x8CD9" name="GL_FRAMEBUFFER_INCOMPLETE_DIMENSIONS"/>
+ <enum value="0x8CD9" name="GL_FRAMEBUFFER_INCOMPLETE_DIMENSIONS_EXT"/>
+ <enum value="0x8CD9" name="GL_FRAMEBUFFER_INCOMPLETE_DIMENSIONS_OES"/>
+ <enum value="0x8CDA" name="GL_FRAMEBUFFER_INCOMPLETE_FORMATS_EXT"/>
+ <enum value="0x8CDA" name="GL_FRAMEBUFFER_INCOMPLETE_FORMATS_OES"/>
+ <enum value="0x8CDB" name="GL_FRAMEBUFFER_INCOMPLETE_DRAW_BUFFER"/>
+ <enum value="0x8CDB" name="GL_FRAMEBUFFER_INCOMPLETE_DRAW_BUFFER_EXT"/>
+ <enum value="0x8CDB" name="GL_FRAMEBUFFER_INCOMPLETE_DRAW_BUFFER_OES"/>
+ <enum value="0x8CDC" name="GL_FRAMEBUFFER_INCOMPLETE_READ_BUFFER"/>
+ <enum value="0x8CDC" name="GL_FRAMEBUFFER_INCOMPLETE_READ_BUFFER_EXT"/>
+ <enum value="0x8CDC" name="GL_FRAMEBUFFER_INCOMPLETE_READ_BUFFER_OES"/>
+ <enum value="0x8CDD" name="GL_FRAMEBUFFER_UNSUPPORTED"/>
+ <enum value="0x8CDD" name="GL_FRAMEBUFFER_UNSUPPORTED_EXT"/>
+ <enum value="0x8CDD" name="GL_FRAMEBUFFER_UNSUPPORTED_OES"/>
+ <unused start="0x8CDE" vendor="ARB" comment="Removed 2005/05/31 in revision #113 of the FBO extension spec"/>
+ <!-- <enum value="0x8CDE" name="GL_FRAMEBUFFER_STATUS_ERROR_EXT"/> -->
+ <enum value="0x8CDF" name="GL_MAX_COLOR_ATTACHMENTS"/>
+ <enum value="0x8CDF" name="GL_MAX_COLOR_ATTACHMENTS_EXT"/>
+ <enum value="0x8CDF" name="GL_MAX_COLOR_ATTACHMENTS_NV"/>
+ <enum value="0x8CE0" name="GL_COLOR_ATTACHMENT0"/>
+ <enum value="0x8CE0" name="GL_COLOR_ATTACHMENT0_EXT"/>
+ <enum value="0x8CE0" name="GL_COLOR_ATTACHMENT0_NV"/>
+ <enum value="0x8CE0" name="GL_COLOR_ATTACHMENT0_OES"/>
+ <enum value="0x8CE1" name="GL_COLOR_ATTACHMENT1"/>
+ <enum value="0x8CE1" name="GL_COLOR_ATTACHMENT1_EXT"/>
+ <enum value="0x8CE1" name="GL_COLOR_ATTACHMENT1_NV"/>
+ <enum value="0x8CE2" name="GL_COLOR_ATTACHMENT2"/>
+ <enum value="0x8CE2" name="GL_COLOR_ATTACHMENT2_EXT"/>
+ <enum value="0x8CE2" name="GL_COLOR_ATTACHMENT2_NV"/>
+ <enum value="0x8CE3" name="GL_COLOR_ATTACHMENT3"/>
+ <enum value="0x8CE3" name="GL_COLOR_ATTACHMENT3_EXT"/>
+ <enum value="0x8CE3" name="GL_COLOR_ATTACHMENT3_NV"/>
+ <enum value="0x8CE4" name="GL_COLOR_ATTACHMENT4"/>
+ <enum value="0x8CE4" name="GL_COLOR_ATTACHMENT4_EXT"/>
+ <enum value="0x8CE4" name="GL_COLOR_ATTACHMENT4_NV"/>
+ <enum value="0x8CE5" name="GL_COLOR_ATTACHMENT5"/>
+ <enum value="0x8CE5" name="GL_COLOR_ATTACHMENT5_EXT"/>
+ <enum value="0x8CE5" name="GL_COLOR_ATTACHMENT5_NV"/>
+ <enum value="0x8CE6" name="GL_COLOR_ATTACHMENT6"/>
+ <enum value="0x8CE6" name="GL_COLOR_ATTACHMENT6_EXT"/>
+ <enum value="0x8CE6" name="GL_COLOR_ATTACHMENT6_NV"/>
+ <enum value="0x8CE7" name="GL_COLOR_ATTACHMENT7"/>
+ <enum value="0x8CE7" name="GL_COLOR_ATTACHMENT7_EXT"/>
+ <enum value="0x8CE7" name="GL_COLOR_ATTACHMENT7_NV"/>
+ <enum value="0x8CE8" name="GL_COLOR_ATTACHMENT8"/>
+ <enum value="0x8CE8" name="GL_COLOR_ATTACHMENT8_EXT"/>
+ <enum value="0x8CE8" name="GL_COLOR_ATTACHMENT8_NV"/>
+ <enum value="0x8CE9" name="GL_COLOR_ATTACHMENT9"/>
+ <enum value="0x8CE9" name="GL_COLOR_ATTACHMENT9_EXT"/>
+ <enum value="0x8CE9" name="GL_COLOR_ATTACHMENT9_NV"/>
+ <enum value="0x8CEA" name="GL_COLOR_ATTACHMENT10"/>
+ <enum value="0x8CEA" name="GL_COLOR_ATTACHMENT10_EXT"/>
+ <enum value="0x8CEA" name="GL_COLOR_ATTACHMENT10_NV"/>
+ <enum value="0x8CEB" name="GL_COLOR_ATTACHMENT11"/>
+ <enum value="0x8CEB" name="GL_COLOR_ATTACHMENT11_EXT"/>
+ <enum value="0x8CEB" name="GL_COLOR_ATTACHMENT11_NV"/>
+ <enum value="0x8CEC" name="GL_COLOR_ATTACHMENT12"/>
+ <enum value="0x8CEC" name="GL_COLOR_ATTACHMENT12_EXT"/>
+ <enum value="0x8CEC" name="GL_COLOR_ATTACHMENT12_NV"/>
+ <enum value="0x8CED" name="GL_COLOR_ATTACHMENT13"/>
+ <enum value="0x8CED" name="GL_COLOR_ATTACHMENT13_EXT"/>
+ <enum value="0x8CED" name="GL_COLOR_ATTACHMENT13_NV"/>
+ <enum value="0x8CEE" name="GL_COLOR_ATTACHMENT14"/>
+ <enum value="0x8CEE" name="GL_COLOR_ATTACHMENT14_EXT"/>
+ <enum value="0x8CEE" name="GL_COLOR_ATTACHMENT14_NV"/>
+ <enum value="0x8CEF" name="GL_COLOR_ATTACHMENT15"/>
+ <enum value="0x8CEF" name="GL_COLOR_ATTACHMENT15_EXT"/>
+ <enum value="0x8CEF" name="GL_COLOR_ATTACHMENT15_NV"/>
+ <unused start="0x8CF0" end="0x8CFF" vendor="ARB" comment="For color attachments 16-31"/>
+ <enum value="0x8D00" name="GL_DEPTH_ATTACHMENT"/>
+ <enum value="0x8D00" name="GL_DEPTH_ATTACHMENT_EXT"/>
+ <enum value="0x8D00" name="GL_DEPTH_ATTACHMENT_OES"/>
+ <unused start="0x8D01" end="0x8D1F" vendor="ARB" comment="For depth attachments 16-31"/>
+ <enum value="0x8D20" name="GL_STENCIL_ATTACHMENT"/>
+ <enum value="0x8D20" name="GL_STENCIL_ATTACHMENT_EXT"/>
+ <enum value="0x8D20" name="GL_STENCIL_ATTACHMENT_OES"/>
+ <unused start="0x8D21" end="0x8D3F" vendor="ARB" comment="For stencil attachments 16-31"/>
+ <enum value="0x8D40" name="GL_FRAMEBUFFER"/>
+ <enum value="0x8D40" name="GL_FRAMEBUFFER_EXT"/>
+ <enum value="0x8D40" name="GL_FRAMEBUFFER_OES"/>
+ <enum value="0x8D41" name="GL_RENDERBUFFER"/>
+ <enum value="0x8D41" name="GL_RENDERBUFFER_EXT"/>
+ <enum value="0x8D41" name="GL_RENDERBUFFER_OES"/>
+ <enum value="0x8D42" name="GL_RENDERBUFFER_WIDTH"/>
+ <enum value="0x8D42" name="GL_RENDERBUFFER_WIDTH_EXT"/>
+ <enum value="0x8D42" name="GL_RENDERBUFFER_WIDTH_OES"/>
+ <enum value="0x8D43" name="GL_RENDERBUFFER_HEIGHT"/>
+ <enum value="0x8D43" name="GL_RENDERBUFFER_HEIGHT_EXT"/>
+ <enum value="0x8D43" name="GL_RENDERBUFFER_HEIGHT_OES"/>
+ <enum value="0x8D44" name="GL_RENDERBUFFER_INTERNAL_FORMAT"/>
+ <enum value="0x8D44" name="GL_RENDERBUFFER_INTERNAL_FORMAT_EXT"/>
+ <enum value="0x8D44" name="GL_RENDERBUFFER_INTERNAL_FORMAT_OES"/>
+ <unused start="0x8D45" vendor="ARB" comment="Was for GL_STENCIL_INDEX_EXT, but now use core STENCIL_INDEX instead"/>
+ <enum value="0x8D46" name="GL_STENCIL_INDEX1"/>
+ <enum value="0x8D46" name="GL_STENCIL_INDEX1_EXT"/>
+ <enum value="0x8D46" name="GL_STENCIL_INDEX1_OES"/>
+ <enum value="0x8D47" name="GL_STENCIL_INDEX4"/>
+ <enum value="0x8D47" name="GL_STENCIL_INDEX4_EXT"/>
+ <enum value="0x8D47" name="GL_STENCIL_INDEX4_OES"/>
+ <enum value="0x8D48" name="GL_STENCIL_INDEX8"/>
+ <enum value="0x8D48" name="GL_STENCIL_INDEX8_EXT"/>
+ <enum value="0x8D48" name="GL_STENCIL_INDEX8_OES"/>
+ <enum value="0x8D49" name="GL_STENCIL_INDEX16"/>
+ <enum value="0x8D49" name="GL_STENCIL_INDEX16_EXT"/>
+ <unused start="0x8D4A" end="0x8D4F" vendor="ARB" comment="For additional stencil formats"/>
+ <enum value="0x8D50" name="GL_RENDERBUFFER_RED_SIZE"/>
+ <enum value="0x8D50" name="GL_RENDERBUFFER_RED_SIZE_EXT"/>
+ <enum value="0x8D50" name="GL_RENDERBUFFER_RED_SIZE_OES"/>
+ <enum value="0x8D51" name="GL_RENDERBUFFER_GREEN_SIZE"/>
+ <enum value="0x8D51" name="GL_RENDERBUFFER_GREEN_SIZE_EXT"/>
+ <enum value="0x8D51" name="GL_RENDERBUFFER_GREEN_SIZE_OES"/>
+ <enum value="0x8D52" name="GL_RENDERBUFFER_BLUE_SIZE"/>
+ <enum value="0x8D52" name="GL_RENDERBUFFER_BLUE_SIZE_EXT"/>
+ <enum value="0x8D52" name="GL_RENDERBUFFER_BLUE_SIZE_OES"/>
+ <enum value="0x8D53" name="GL_RENDERBUFFER_ALPHA_SIZE"/>
+ <enum value="0x8D53" name="GL_RENDERBUFFER_ALPHA_SIZE_EXT"/>
+ <enum value="0x8D53" name="GL_RENDERBUFFER_ALPHA_SIZE_OES"/>
+ <enum value="0x8D54" name="GL_RENDERBUFFER_DEPTH_SIZE"/>
+ <enum value="0x8D54" name="GL_RENDERBUFFER_DEPTH_SIZE_EXT"/>
+ <enum value="0x8D54" name="GL_RENDERBUFFER_DEPTH_SIZE_OES"/>
+ <enum value="0x8D55" name="GL_RENDERBUFFER_STENCIL_SIZE"/>
+ <enum value="0x8D55" name="GL_RENDERBUFFER_STENCIL_SIZE_EXT"/>
+ <enum value="0x8D55" name="GL_RENDERBUFFER_STENCIL_SIZE_OES"/>
+ <enum value="0x8D56" name="GL_FRAMEBUFFER_INCOMPLETE_MULTISAMPLE"/>
+ <enum value="0x8D56" name="GL_FRAMEBUFFER_INCOMPLETE_MULTISAMPLE_ANGLE"/>
+ <enum value="0x8D56" name="GL_FRAMEBUFFER_INCOMPLETE_MULTISAMPLE_APPLE"/>
+ <enum value="0x8D56" name="GL_FRAMEBUFFER_INCOMPLETE_MULTISAMPLE_EXT"/>
+ <enum value="0x8D56" name="GL_FRAMEBUFFER_INCOMPLETE_MULTISAMPLE_NV"/>
+ <enum value="0x8D57" name="GL_MAX_SAMPLES"/>
+ <enum value="0x8D57" name="GL_MAX_SAMPLES_ANGLE"/>
+ <enum value="0x8D57" name="GL_MAX_SAMPLES_APPLE"/>
+ <enum value="0x8D57" name="GL_MAX_SAMPLES_EXT"/>
+ <enum value="0x8D57" name="GL_MAX_SAMPLES_NV"/>
+ <unused start="0x8D58" end="0x8D5F" vendor="ARB"/>
+ </enums>
+
+ <enums namespace="GL" start="0x8D60" end="0x8D6F" vendor="OES">
+ <enum value="0x8D60" name="GL_TEXTURE_GEN_STR_OES"/>
+ <enum value="0x8D61" name="GL_HALF_FLOAT_OES"/>
+ <enum value="0x8D62" name="GL_RGB565_OES"/>
+ <enum value="0x8D62" name="GL_RGB565"/>
+ <unused start="0x8D63" vendor="OES" comment="Was GL_TEXTURE_IMMUTABLE_LEVELS in draft ES 3.0 spec"/>
+ <enum value="0x8D64" name="GL_ETC1_RGB8_OES"/>
+ <enum value="0x8D65" name="GL_TEXTURE_EXTERNAL_OES"/>
+ <enum value="0x8D66" name="GL_SAMPLER_EXTERNAL_OES"/>
+ <enum value="0x8D67" name="GL_TEXTURE_BINDING_EXTERNAL_OES"/>
+ <enum value="0x8D68" name="GL_REQUIRED_TEXTURE_IMAGE_UNITS_OES"/>
+ <enum value="0x8D69" name="GL_PRIMITIVE_RESTART_FIXED_INDEX"/>
+ <enum value="0x8D6A" name="GL_ANY_SAMPLES_PASSED_CONSERVATIVE"/>
+ <enum value="0x8D6A" name="GL_ANY_SAMPLES_PASSED_CONSERVATIVE_EXT"/>
+ <enum value="0x8D6B" name="GL_MAX_ELEMENT_INDEX"/>
+ <enum value="0x8D6C" name="GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_SAMPLES_EXT"/>
+ <unused start="0x8D6D" end="0x8D6F" vendor="OES"/>
+ </enums>
+
+ <enums namespace="GL" start="0x8D70" end="0x8DEF" vendor="NV" comment="For Pat Brown 2005/10/13">
+ <enum value="0x8D70" name="GL_RGBA32UI"/>
+ <enum value="0x8D70" name="GL_RGBA32UI_EXT"/>
+ <enum value="0x8D71" name="GL_RGB32UI"/>
+ <enum value="0x8D71" name="GL_RGB32UI_EXT"/>
+ <enum value="0x8D72" name="GL_ALPHA32UI_EXT"/>
+ <enum value="0x8D73" name="GL_INTENSITY32UI_EXT"/>
+ <enum value="0x8D74" name="GL_LUMINANCE32UI_EXT"/>
+ <enum value="0x8D75" name="GL_LUMINANCE_ALPHA32UI_EXT"/>
+ <enum value="0x8D76" name="GL_RGBA16UI"/>
+ <enum value="0x8D76" name="GL_RGBA16UI_EXT"/>
+ <enum value="0x8D77" name="GL_RGB16UI"/>
+ <enum value="0x8D77" name="GL_RGB16UI_EXT"/>
+ <enum value="0x8D78" name="GL_ALPHA16UI_EXT"/>
+ <enum value="0x8D79" name="GL_INTENSITY16UI_EXT"/>
+ <enum value="0x8D7A" name="GL_LUMINANCE16UI_EXT"/>
+ <enum value="0x8D7B" name="GL_LUMINANCE_ALPHA16UI_EXT"/>
+ <enum value="0x8D7C" name="GL_RGBA8UI"/>
+ <enum value="0x8D7C" name="GL_RGBA8UI_EXT"/>
+ <enum value="0x8D7D" name="GL_RGB8UI"/>
+ <enum value="0x8D7D" name="GL_RGB8UI_EXT"/>
+ <enum value="0x8D7E" name="GL_ALPHA8UI_EXT"/>
+ <enum value="0x8D7F" name="GL_INTENSITY8UI_EXT"/>
+ <enum value="0x8D80" name="GL_LUMINANCE8UI_EXT"/>
+ <enum value="0x8D81" name="GL_LUMINANCE_ALPHA8UI_EXT"/>
+ <enum value="0x8D82" name="GL_RGBA32I"/>
+ <enum value="0x8D82" name="GL_RGBA32I_EXT"/>
+ <enum value="0x8D83" name="GL_RGB32I"/>
+ <enum value="0x8D83" name="GL_RGB32I_EXT"/>
+ <enum value="0x8D84" name="GL_ALPHA32I_EXT"/>
+ <enum value="0x8D85" name="GL_INTENSITY32I_EXT"/>
+ <enum value="0x8D86" name="GL_LUMINANCE32I_EXT"/>
+ <enum value="0x8D87" name="GL_LUMINANCE_ALPHA32I_EXT"/>
+ <enum value="0x8D88" name="GL_RGBA16I"/>
+ <enum value="0x8D88" name="GL_RGBA16I_EXT"/>
+ <enum value="0x8D89" name="GL_RGB16I"/>
+ <enum value="0x8D89" name="GL_RGB16I_EXT"/>
+ <enum value="0x8D8A" name="GL_ALPHA16I_EXT"/>
+ <enum value="0x8D8B" name="GL_INTENSITY16I_EXT"/>
+ <enum value="0x8D8C" name="GL_LUMINANCE16I_EXT"/>
+ <enum value="0x8D8D" name="GL_LUMINANCE_ALPHA16I_EXT"/>
+ <enum value="0x8D8E" name="GL_RGBA8I"/>
+ <enum value="0x8D8E" name="GL_RGBA8I_EXT"/>
+ <enum value="0x8D8F" name="GL_RGB8I"/>
+ <enum value="0x8D8F" name="GL_RGB8I_EXT"/>
+ <enum value="0x8D90" name="GL_ALPHA8I_EXT"/>
+ <enum value="0x8D91" name="GL_INTENSITY8I_EXT"/>
+ <enum value="0x8D92" name="GL_LUMINANCE8I_EXT"/>
+ <enum value="0x8D93" name="GL_LUMINANCE_ALPHA8I_EXT"/>
+ <enum value="0x8D94" name="GL_RED_INTEGER"/>
+ <enum value="0x8D94" name="GL_RED_INTEGER_EXT"/>
+ <enum value="0x8D95" name="GL_GREEN_INTEGER"/>
+ <enum value="0x8D95" name="GL_GREEN_INTEGER_EXT"/>
+ <enum value="0x8D96" name="GL_BLUE_INTEGER"/>
+ <enum value="0x8D96" name="GL_BLUE_INTEGER_EXT"/>
+ <enum value="0x8D97" name="GL_ALPHA_INTEGER"/>
+ <enum value="0x8D97" name="GL_ALPHA_INTEGER_EXT"/>
+ <enum value="0x8D98" name="GL_RGB_INTEGER"/>
+ <enum value="0x8D98" name="GL_RGB_INTEGER_EXT"/>
+ <enum value="0x8D99" name="GL_RGBA_INTEGER"/>
+ <enum value="0x8D99" name="GL_RGBA_INTEGER_EXT"/>
+ <enum value="0x8D9A" name="GL_BGR_INTEGER"/>
+ <enum value="0x8D9A" name="GL_BGR_INTEGER_EXT"/>
+ <enum value="0x8D9B" name="GL_BGRA_INTEGER"/>
+ <enum value="0x8D9B" name="GL_BGRA_INTEGER_EXT"/>
+ <enum value="0x8D9C" name="GL_LUMINANCE_INTEGER_EXT"/>
+ <enum value="0x8D9D" name="GL_LUMINANCE_ALPHA_INTEGER_EXT"/>
+ <enum value="0x8D9E" name="GL_RGBA_INTEGER_MODE_EXT"/>
+ <enum value="0x8D9F" name="GL_INT_2_10_10_10_REV"/>
+ <enum value="0x8DA0" name="GL_MAX_PROGRAM_PARAMETER_BUFFER_BINDINGS_NV"/>
+ <enum value="0x8DA1" name="GL_MAX_PROGRAM_PARAMETER_BUFFER_SIZE_NV"/>
+ <enum value="0x8DA2" name="GL_VERTEX_PROGRAM_PARAMETER_BUFFER_NV"/>
+ <enum value="0x8DA3" name="GL_GEOMETRY_PROGRAM_PARAMETER_BUFFER_NV"/>
+ <enum value="0x8DA4" name="GL_FRAGMENT_PROGRAM_PARAMETER_BUFFER_NV"/>
+ <enum value="0x8DA5" name="GL_MAX_PROGRAM_GENERIC_ATTRIBS_NV"/>
+ <enum value="0x8DA6" name="GL_MAX_PROGRAM_GENERIC_RESULTS_NV"/>
+ <enum value="0x8DA7" name="GL_FRAMEBUFFER_ATTACHMENT_LAYERED"/>
+ <enum value="0x8DA7" name="GL_FRAMEBUFFER_ATTACHMENT_LAYERED_ARB"/>
+ <enum value="0x8DA7" name="GL_FRAMEBUFFER_ATTACHMENT_LAYERED_EXT"/>
+ <enum value="0x8DA8" name="GL_FRAMEBUFFER_INCOMPLETE_LAYER_TARGETS"/>
+ <enum value="0x8DA8" name="GL_FRAMEBUFFER_INCOMPLETE_LAYER_TARGETS_ARB"/>
+ <enum value="0x8DA8" name="GL_FRAMEBUFFER_INCOMPLETE_LAYER_TARGETS_EXT"/>
+ <enum value="0x8DA9" name="GL_FRAMEBUFFER_INCOMPLETE_LAYER_COUNT_ARB"/>
+ <enum value="0x8DA9" name="GL_FRAMEBUFFER_INCOMPLETE_LAYER_COUNT_EXT"/>
+ <!-- Also see the odd namespace "NVTransformFeedbackToken" above -->
+ <enum value="0x8DAA" name="GL_LAYER_NV"/>
+ <enum value="0x8DAB" name="GL_DEPTH_COMPONENT32F_NV"/>
+ <enum value="0x8DAC" name="GL_DEPTH32F_STENCIL8_NV"/>
+ <enum value="0x8DAD" name="GL_FLOAT_32_UNSIGNED_INT_24_8_REV"/>
+ <enum value="0x8DAD" name="GL_FLOAT_32_UNSIGNED_INT_24_8_REV_NV"/>
+ <enum value="0x8DAE" name="GL_SHADER_INCLUDE_ARB"/>
+ <enum value="0x8DAF" name="GL_DEPTH_BUFFER_FLOAT_MODE_NV"/>
+ <unused start="0x8DB0" end="0x8DB8" vendor="NV"/>
+ <enum value="0x8DB9" name="GL_FRAMEBUFFER_SRGB"/>
+ <enum value="0x8DB9" name="GL_FRAMEBUFFER_SRGB_EXT"/>
+ <enum value="0x8DBA" name="GL_FRAMEBUFFER_SRGB_CAPABLE_EXT"/>
+ <enum value="0x8DBB" name="GL_COMPRESSED_RED_RGTC1"/>
+ <enum value="0x8DBB" name="GL_COMPRESSED_RED_RGTC1_EXT"/>
+ <enum value="0x8DBC" name="GL_COMPRESSED_SIGNED_RED_RGTC1"/>
+ <enum value="0x8DBC" name="GL_COMPRESSED_SIGNED_RED_RGTC1_EXT"/>
+ <enum value="0x8DBD" name="GL_COMPRESSED_RED_GREEN_RGTC2_EXT"/>
+ <enum value="0x8DBD" name="GL_COMPRESSED_RG_RGTC2"/>
+ <enum value="0x8DBE" name="GL_COMPRESSED_SIGNED_RED_GREEN_RGTC2_EXT"/>
+ <enum value="0x8DBE" name="GL_COMPRESSED_SIGNED_RG_RGTC2"/>
+ <enum value="0x8DC0" name="GL_SAMPLER_1D_ARRAY"/>
+ <enum value="0x8DC0" name="GL_SAMPLER_1D_ARRAY_EXT"/>
+ <enum value="0x8DC1" name="GL_SAMPLER_2D_ARRAY"/>
+ <enum value="0x8DC1" name="GL_SAMPLER_2D_ARRAY_EXT"/>
+ <enum value="0x8DC2" name="GL_SAMPLER_BUFFER"/>
+ <enum value="0x8DC2" name="GL_SAMPLER_BUFFER_EXT"/>
+ <enum value="0x8DC3" name="GL_SAMPLER_1D_ARRAY_SHADOW"/>
+ <enum value="0x8DC3" name="GL_SAMPLER_1D_ARRAY_SHADOW_EXT"/>
+ <enum value="0x8DC4" name="GL_SAMPLER_2D_ARRAY_SHADOW"/>
+ <enum value="0x8DC4" name="GL_SAMPLER_2D_ARRAY_SHADOW_EXT"/>
+ <enum value="0x8DC4" name="GL_SAMPLER_2D_ARRAY_SHADOW_NV"/>
+ <enum value="0x8DC5" name="GL_SAMPLER_CUBE_SHADOW"/>
+ <enum value="0x8DC5" name="GL_SAMPLER_CUBE_SHADOW_EXT"/>
+ <enum value="0x8DC5" name="GL_SAMPLER_CUBE_SHADOW_NV"/>
+ <enum value="0x8DC6" name="GL_UNSIGNED_INT_VEC2"/>
+ <enum value="0x8DC6" name="GL_UNSIGNED_INT_VEC2_EXT"/>
+ <enum value="0x8DC7" name="GL_UNSIGNED_INT_VEC3"/>
+ <enum value="0x8DC7" name="GL_UNSIGNED_INT_VEC3_EXT"/>
+ <enum value="0x8DC8" name="GL_UNSIGNED_INT_VEC4"/>
+ <enum value="0x8DC8" name="GL_UNSIGNED_INT_VEC4_EXT"/>
+ <enum value="0x8DC9" name="GL_INT_SAMPLER_1D"/>
+ <enum value="0x8DC9" name="GL_INT_SAMPLER_1D_EXT"/>
+ <enum value="0x8DCA" name="GL_INT_SAMPLER_2D"/>
+ <enum value="0x8DCA" name="GL_INT_SAMPLER_2D_EXT"/>
+ <enum value="0x8DCB" name="GL_INT_SAMPLER_3D"/>
+ <enum value="0x8DCB" name="GL_INT_SAMPLER_3D_EXT"/>
+ <enum value="0x8DCC" name="GL_INT_SAMPLER_CUBE"/>
+ <enum value="0x8DCC" name="GL_INT_SAMPLER_CUBE_EXT"/>
+ <enum value="0x8DCD" name="GL_INT_SAMPLER_2D_RECT"/>
+ <enum value="0x8DCD" name="GL_INT_SAMPLER_2D_RECT_EXT"/>
+ <enum value="0x8DCE" name="GL_INT_SAMPLER_1D_ARRAY"/>
+ <enum value="0x8DCE" name="GL_INT_SAMPLER_1D_ARRAY_EXT"/>
+ <enum value="0x8DCF" name="GL_INT_SAMPLER_2D_ARRAY"/>
+ <enum value="0x8DCF" name="GL_INT_SAMPLER_2D_ARRAY_EXT"/>
+ <enum value="0x8DD0" name="GL_INT_SAMPLER_BUFFER"/>
+ <enum value="0x8DD0" name="GL_INT_SAMPLER_BUFFER_EXT"/>
+ <enum value="0x8DD1" name="GL_UNSIGNED_INT_SAMPLER_1D"/>
+ <enum value="0x8DD1" name="GL_UNSIGNED_INT_SAMPLER_1D_EXT"/>
+ <enum value="0x8DD2" name="GL_UNSIGNED_INT_SAMPLER_2D"/>
+ <enum value="0x8DD2" name="GL_UNSIGNED_INT_SAMPLER_2D_EXT"/>
+ <enum value="0x8DD3" name="GL_UNSIGNED_INT_SAMPLER_3D"/>
+ <enum value="0x8DD3" name="GL_UNSIGNED_INT_SAMPLER_3D_EXT"/>
+ <enum value="0x8DD4" name="GL_UNSIGNED_INT_SAMPLER_CUBE"/>
+ <enum value="0x8DD4" name="GL_UNSIGNED_INT_SAMPLER_CUBE_EXT"/>
+ <enum value="0x8DD5" name="GL_UNSIGNED_INT_SAMPLER_2D_RECT"/>
+ <enum value="0x8DD5" name="GL_UNSIGNED_INT_SAMPLER_2D_RECT_EXT"/>
+ <enum value="0x8DD6" name="GL_UNSIGNED_INT_SAMPLER_1D_ARRAY"/>
+ <enum value="0x8DD6" name="GL_UNSIGNED_INT_SAMPLER_1D_ARRAY_EXT"/>
+ <enum value="0x8DD7" name="GL_UNSIGNED_INT_SAMPLER_2D_ARRAY"/>
+ <enum value="0x8DD7" name="GL_UNSIGNED_INT_SAMPLER_2D_ARRAY_EXT"/>
+ <enum value="0x8DD8" name="GL_UNSIGNED_INT_SAMPLER_BUFFER"/>
+ <enum value="0x8DD8" name="GL_UNSIGNED_INT_SAMPLER_BUFFER_EXT"/>
+ <enum value="0x8DD9" name="GL_GEOMETRY_SHADER"/>
+ <enum value="0x8DD9" name="GL_GEOMETRY_SHADER_ARB"/>
+ <enum value="0x8DD9" name="GL_GEOMETRY_SHADER_EXT"/>
+ <enum value="0x8DDA" name="GL_GEOMETRY_VERTICES_OUT_ARB"/>
+ <enum value="0x8DDA" name="GL_GEOMETRY_VERTICES_OUT_EXT"/>
+ <enum value="0x8DDB" name="GL_GEOMETRY_INPUT_TYPE_ARB"/>
+ <enum value="0x8DDB" name="GL_GEOMETRY_INPUT_TYPE_EXT"/>
+ <enum value="0x8DDC" name="GL_GEOMETRY_OUTPUT_TYPE_ARB"/>
+ <enum value="0x8DDC" name="GL_GEOMETRY_OUTPUT_TYPE_EXT"/>
+ <enum value="0x8DDD" name="GL_MAX_GEOMETRY_VARYING_COMPONENTS_ARB"/>
+ <enum value="0x8DDD" name="GL_MAX_GEOMETRY_VARYING_COMPONENTS_EXT"/>
+ <enum value="0x8DDE" name="GL_MAX_VERTEX_VARYING_COMPONENTS_ARB"/>
+ <enum value="0x8DDE" name="GL_MAX_VERTEX_VARYING_COMPONENTS_EXT"/>
+ <enum value="0x8DDF" name="GL_MAX_GEOMETRY_UNIFORM_COMPONENTS"/>
+ <enum value="0x8DDF" name="GL_MAX_GEOMETRY_UNIFORM_COMPONENTS_ARB"/>
+ <enum value="0x8DDF" name="GL_MAX_GEOMETRY_UNIFORM_COMPONENTS_EXT"/>
+ <enum value="0x8DE0" name="GL_MAX_GEOMETRY_OUTPUT_VERTICES"/>
+ <enum value="0x8DE0" name="GL_MAX_GEOMETRY_OUTPUT_VERTICES_ARB"/>
+ <enum value="0x8DE0" name="GL_MAX_GEOMETRY_OUTPUT_VERTICES_EXT"/>
+ <enum value="0x8DE1" name="GL_MAX_GEOMETRY_TOTAL_OUTPUT_COMPONENTS"/>
+ <enum value="0x8DE1" name="GL_MAX_GEOMETRY_TOTAL_OUTPUT_COMPONENTS_ARB"/>
+ <enum value="0x8DE1" name="GL_MAX_GEOMETRY_TOTAL_OUTPUT_COMPONENTS_EXT"/>
+ <enum value="0x8DE2" name="GL_MAX_VERTEX_BINDABLE_UNIFORMS_EXT"/>
+ <enum value="0x8DE3" name="GL_MAX_FRAGMENT_BINDABLE_UNIFORMS_EXT"/>
+ <enum value="0x8DE4" name="GL_MAX_GEOMETRY_BINDABLE_UNIFORMS_EXT"/>
+ <enum value="0x8DE5" name="GL_ACTIVE_SUBROUTINES"/>
+ <enum value="0x8DE6" name="GL_ACTIVE_SUBROUTINE_UNIFORMS"/>
+ <enum value="0x8DE7" name="GL_MAX_SUBROUTINES"/>
+ <enum value="0x8DE8" name="GL_MAX_SUBROUTINE_UNIFORM_LOCATIONS"/>
+ <enum value="0x8DE9" name="GL_NAMED_STRING_LENGTH_ARB"/>
+ <enum value="0x8DEA" name="GL_NAMED_STRING_TYPE_ARB"/>
+ <unused start="0x8DEB" end="0x8DEC" vendor="NV"/>
+ <enum value="0x8DED" name="GL_MAX_BINDABLE_UNIFORM_SIZE_EXT"/>
+ <enum value="0x8DEE" name="GL_UNIFORM_BUFFER_EXT"/>
+ <enum value="0x8DEF" name="GL_UNIFORM_BUFFER_BINDING_EXT"/>
+ </enums>
+
+ <enums namespace="GL" start="0x8DF0" end="0x8E0F" vendor="OES">
+ <enum value="0x8DF0" name="GL_LOW_FLOAT"/>
+ <enum value="0x8DF1" name="GL_MEDIUM_FLOAT"/>
+ <enum value="0x8DF2" name="GL_HIGH_FLOAT"/>
+ <enum value="0x8DF3" name="GL_LOW_INT"/>
+ <enum value="0x8DF4" name="GL_MEDIUM_INT"/>
+ <enum value="0x8DF5" name="GL_HIGH_INT"/>
+ <enum value="0x8DF6" name="GL_UNSIGNED_INT_10_10_10_2_OES"/>
+ <enum value="0x8DF7" name="GL_INT_10_10_10_2_OES"/>
+ <enum value="0x8DF8" name="GL_SHADER_BINARY_FORMATS"/>
+ <enum value="0x8DF9" name="GL_NUM_SHADER_BINARY_FORMATS"/>
+ <enum value="0x8DFA" name="GL_SHADER_COMPILER"/>
+ <enum value="0x8DFB" name="GL_MAX_VERTEX_UNIFORM_VECTORS"/>
+ <enum value="0x8DFC" name="GL_MAX_VARYING_VECTORS"/>
+ <enum value="0x8DFD" name="GL_MAX_FRAGMENT_UNIFORM_VECTORS"/>
+ <unused start="0x8DFE" end="0x8E0F" vendor="OES"/>
+ </enums>
+
+ <enums namespace="GL" start="0x8E10" end="0x8E8F" vendor="NV" comment="For Michael Gold 2006/08/07">
+ <enum value="0x8E10" name="GL_RENDERBUFFER_COLOR_SAMPLES_NV"/>
+ <enum value="0x8E11" name="GL_MAX_MULTISAMPLE_COVERAGE_MODES_NV"/>
+ <enum value="0x8E12" name="GL_MULTISAMPLE_COVERAGE_MODES_NV"/>
+ <enum value="0x8E13" name="GL_QUERY_WAIT"/>
+ <enum value="0x8E13" name="GL_QUERY_WAIT_NV"/>
+ <enum value="0x8E14" name="GL_QUERY_NO_WAIT"/>
+ <enum value="0x8E14" name="GL_QUERY_NO_WAIT_NV"/>
+ <enum value="0x8E15" name="GL_QUERY_BY_REGION_WAIT"/>
+ <enum value="0x8E15" name="GL_QUERY_BY_REGION_WAIT_NV"/>
+ <enum value="0x8E16" name="GL_QUERY_BY_REGION_NO_WAIT"/>
+ <enum value="0x8E16" name="GL_QUERY_BY_REGION_NO_WAIT_NV"/>
+ <enum value="0x8E17" name="GL_QUERY_WAIT_INVERTED"/>
+ <enum value="0x8E18" name="GL_QUERY_NO_WAIT_INVERTED"/>
+ <enum value="0x8E19" name="GL_QUERY_BY_REGION_WAIT_INVERTED"/>
+ <enum value="0x8E1A" name="GL_QUERY_BY_REGION_NO_WAIT_INVERTED"/>
+ <unused start="0x8E1B" end="0x8E1D" vendor="NV"/>
+ <enum value="0x8E1E" name="GL_MAX_COMBINED_TESS_CONTROL_UNIFORM_COMPONENTS"/>
+ <enum value="0x8E1E" name="GL_MAX_COMBINED_TESS_CONTROL_UNIFORM_COMPONENTS_EXT"/>
+ <enum value="0x8E1F" name="GL_MAX_COMBINED_TESS_EVALUATION_UNIFORM_COMPONENTS"/>
+ <enum value="0x8E1F" name="GL_MAX_COMBINED_TESS_EVALUATION_UNIFORM_COMPONENTS_EXT"/>
+ <enum value="0x8E20" name="GL_COLOR_SAMPLES_NV"/>
+ <unused start="0x8E21" vendor="NV"/>
+ <enum value="0x8E22" name="GL_TRANSFORM_FEEDBACK"/>
+ <enum value="0x8E22" name="GL_TRANSFORM_FEEDBACK_NV"/>
+ <enum value="0x8E23" name="GL_TRANSFORM_FEEDBACK_BUFFER_PAUSED"/>
+ <enum value="0x8E23" name="GL_TRANSFORM_FEEDBACK_PAUSED" alias="GL_TRANSFORM_FEEDBACK_BUFFER_PAUSED"/>
+ <enum value="0x8E23" name="GL_TRANSFORM_FEEDBACK_BUFFER_PAUSED_NV"/>
+ <enum value="0x8E24" name="GL_TRANSFORM_FEEDBACK_BUFFER_ACTIVE"/>
+ <enum value="0x8E24" name="GL_TRANSFORM_FEEDBACK_ACTIVE" alias="GL_TRANSFORM_FEEDBACK_BUFFER_ACTIVE"/>
+ <enum value="0x8E24" name="GL_TRANSFORM_FEEDBACK_BUFFER_ACTIVE_NV"/>
+ <enum value="0x8E25" name="GL_TRANSFORM_FEEDBACK_BINDING"/>
+ <enum value="0x8E25" name="GL_TRANSFORM_FEEDBACK_BINDING_NV"/>
+ <enum value="0x8E26" name="GL_FRAME_NV"/>
+ <enum value="0x8E27" name="GL_FIELDS_NV"/>
+ <enum value="0x8E28" name="GL_CURRENT_TIME_NV"/>
+ <enum value="0x8E28" name="GL_TIMESTAMP"/>
+ <enum value="0x8E28" name="GL_TIMESTAMP_EXT"/>
+ <enum value="0x8E29" name="GL_NUM_FILL_STREAMS_NV"/>
+ <enum value="0x8E2A" name="GL_PRESENT_TIME_NV"/>
+ <enum value="0x8E2B" name="GL_PRESENT_DURATION_NV"/>
+ <enum value="0x8E2C" name="GL_DEPTH_COMPONENT16_NONLINEAR_NV"/>
+ <enum value="0x8E2D" name="GL_PROGRAM_MATRIX_EXT"/>
+ <enum value="0x8E2E" name="GL_TRANSPOSE_PROGRAM_MATRIX_EXT"/>
+ <enum value="0x8E2F" name="GL_PROGRAM_MATRIX_STACK_DEPTH_EXT"/>
+ <unused start="0x8E30" end="0x8E41" vendor="NV"/>
+ <enum value="0x8E42" name="GL_TEXTURE_SWIZZLE_R"/>
+ <enum value="0x8E42" name="GL_TEXTURE_SWIZZLE_R_EXT"/>
+ <enum value="0x8E43" name="GL_TEXTURE_SWIZZLE_G"/>
+ <enum value="0x8E43" name="GL_TEXTURE_SWIZZLE_G_EXT"/>
+ <enum value="0x8E44" name="GL_TEXTURE_SWIZZLE_B"/>
+ <enum value="0x8E44" name="GL_TEXTURE_SWIZZLE_B_EXT"/>
+ <enum value="0x8E45" name="GL_TEXTURE_SWIZZLE_A"/>
+ <enum value="0x8E45" name="GL_TEXTURE_SWIZZLE_A_EXT"/>
+ <enum value="0x8E46" name="GL_TEXTURE_SWIZZLE_RGBA"/>
+ <enum value="0x8E46" name="GL_TEXTURE_SWIZZLE_RGBA_EXT"/>
+ <enum value="0x8E47" name="GL_ACTIVE_SUBROUTINE_UNIFORM_LOCATIONS"/>
+ <enum value="0x8E48" name="GL_ACTIVE_SUBROUTINE_MAX_LENGTH"/>
+ <enum value="0x8E49" name="GL_ACTIVE_SUBROUTINE_UNIFORM_MAX_LENGTH"/>
+ <enum value="0x8E4A" name="GL_NUM_COMPATIBLE_SUBROUTINES"/>
+ <enum value="0x8E4B" name="GL_COMPATIBLE_SUBROUTINES"/>
+ <enum value="0x8E4C" name="GL_QUADS_FOLLOW_PROVOKING_VERTEX_CONVENTION"/>
+ <enum value="0x8E4C" name="GL_QUADS_FOLLOW_PROVOKING_VERTEX_CONVENTION_EXT"/>
+ <enum value="0x8E4D" name="GL_FIRST_VERTEX_CONVENTION"/>
+ <enum value="0x8E4D" name="GL_FIRST_VERTEX_CONVENTION_EXT"/>
+ <enum value="0x8E4E" name="GL_LAST_VERTEX_CONVENTION"/>
+ <enum value="0x8E4E" name="GL_LAST_VERTEX_CONVENTION_EXT"/>
+ <enum value="0x8E4F" name="GL_PROVOKING_VERTEX"/>
+ <enum value="0x8E4F" name="GL_PROVOKING_VERTEX_EXT"/>
+ <enum value="0x8E50" name="GL_SAMPLE_POSITION"/>
+ <enum value="0x8E50" name="GL_SAMPLE_POSITION_NV"/>
+ <enum value="0x8E51" name="GL_SAMPLE_MASK"/>
+ <enum value="0x8E51" name="GL_SAMPLE_MASK_NV"/>
+ <enum value="0x8E52" name="GL_SAMPLE_MASK_VALUE"/>
+ <enum value="0x8E52" name="GL_SAMPLE_MASK_VALUE_NV"/>
+ <enum value="0x8E53" name="GL_TEXTURE_BINDING_RENDERBUFFER_NV"/>
+ <enum value="0x8E54" name="GL_TEXTURE_RENDERBUFFER_DATA_STORE_BINDING_NV"/>
+ <enum value="0x8E55" name="GL_TEXTURE_RENDERBUFFER_NV"/>
+ <enum value="0x8E56" name="GL_SAMPLER_RENDERBUFFER_NV"/>
+ <enum value="0x8E57" name="GL_INT_SAMPLER_RENDERBUFFER_NV"/>
+ <enum value="0x8E58" name="GL_UNSIGNED_INT_SAMPLER_RENDERBUFFER_NV"/>
+ <enum value="0x8E59" name="GL_MAX_SAMPLE_MASK_WORDS"/>
+ <enum value="0x8E59" name="GL_MAX_SAMPLE_MASK_WORDS_NV"/>
+ <enum value="0x8E5A" name="GL_MAX_GEOMETRY_PROGRAM_INVOCATIONS_NV"/>
+ <enum value="0x8E5A" name="GL_MAX_GEOMETRY_SHADER_INVOCATIONS"/>
+ <enum value="0x8E5A" name="GL_MAX_GEOMETRY_SHADER_INVOCATIONS_EXT"/>
+ <enum value="0x8E5B" name="GL_MIN_FRAGMENT_INTERPOLATION_OFFSET"/>
+ <enum value="0x8E5B" name="GL_MIN_FRAGMENT_INTERPOLATION_OFFSET_OES"/>
+ <enum value="0x8E5B" name="GL_MIN_FRAGMENT_INTERPOLATION_OFFSET_NV"/>
+ <enum value="0x8E5C" name="GL_MAX_FRAGMENT_INTERPOLATION_OFFSET"/>
+ <enum value="0x8E5C" name="GL_MAX_FRAGMENT_INTERPOLATION_OFFSET_OES"/>
+ <enum value="0x8E5C" name="GL_MAX_FRAGMENT_INTERPOLATION_OFFSET_NV"/>
+ <enum value="0x8E5D" name="GL_FRAGMENT_INTERPOLATION_OFFSET_BITS"/>
+ <enum value="0x8E5D" name="GL_FRAGMENT_INTERPOLATION_OFFSET_BITS_OES"/>
+ <enum value="0x8E5D" name="GL_FRAGMENT_PROGRAM_INTERPOLATION_OFFSET_BITS_NV"/>
+ <enum value="0x8E5E" name="GL_MIN_PROGRAM_TEXTURE_GATHER_OFFSET"/>
+ <enum value="0x8E5E" name="GL_MIN_PROGRAM_TEXTURE_GATHER_OFFSET_ARB"/>
+ <enum value="0x8E5E" name="GL_MIN_PROGRAM_TEXTURE_GATHER_OFFSET_NV"/>
+ <enum value="0x8E5F" name="GL_MAX_PROGRAM_TEXTURE_GATHER_OFFSET"/>
+ <enum value="0x8E5F" name="GL_MAX_PROGRAM_TEXTURE_GATHER_OFFSET_ARB"/>
+ <enum value="0x8E5F" name="GL_MAX_PROGRAM_TEXTURE_GATHER_OFFSET_NV"/>
+ <unused start="0x8E60" end="0x8E6F" vendor="NV"/>
+ <enum value="0x8E70" name="GL_MAX_TRANSFORM_FEEDBACK_BUFFERS"/>
+ <enum value="0x8E71" name="GL_MAX_VERTEX_STREAMS"/>
+ <enum value="0x8E72" name="GL_PATCH_VERTICES"/>
+ <enum value="0x8E72" name="GL_PATCH_VERTICES_EXT"/>
+ <enum value="0x8E73" name="GL_PATCH_DEFAULT_INNER_LEVEL"/>
+ <enum value="0x8E73" name="GL_PATCH_DEFAULT_INNER_LEVEL_EXT"/>
+ <enum value="0x8E74" name="GL_PATCH_DEFAULT_OUTER_LEVEL"/>
+ <enum value="0x8E74" name="GL_PATCH_DEFAULT_OUTER_LEVEL_EXT"/>
+ <enum value="0x8E75" name="GL_TESS_CONTROL_OUTPUT_VERTICES"/>
+ <enum value="0x8E75" name="GL_TESS_CONTROL_OUTPUT_VERTICES_EXT"/>
+ <enum value="0x8E76" name="GL_TESS_GEN_MODE"/>
+ <enum value="0x8E76" name="GL_TESS_GEN_MODE_EXT"/>
+ <enum value="0x8E77" name="GL_TESS_GEN_SPACING"/>
+ <enum value="0x8E77" name="GL_TESS_GEN_SPACING_EXT"/>
+ <enum value="0x8E78" name="GL_TESS_GEN_VERTEX_ORDER"/>
+ <enum value="0x8E78" name="GL_TESS_GEN_VERTEX_ORDER_EXT"/>
+ <enum value="0x8E79" name="GL_TESS_GEN_POINT_MODE"/>
+ <enum value="0x8E79" name="GL_TESS_GEN_POINT_MODE_EXT"/>
+ <enum value="0x8E7A" name="GL_ISOLINES"/>
+ <enum value="0x8E7A" name="GL_ISOLINES_EXT"/>
+ <enum value="0x8E7B" name="GL_FRACTIONAL_ODD"/>
+ <enum value="0x8E7B" name="GL_FRACTIONAL_ODD_EXT"/>
+ <enum value="0x8E7C" name="GL_FRACTIONAL_EVEN"/>
+ <enum value="0x8E7C" name="GL_FRACTIONAL_EVEN_EXT"/>
+ <enum value="0x8E7D" name="GL_MAX_PATCH_VERTICES"/>
+ <enum value="0x8E7D" name="GL_MAX_PATCH_VERTICES_EXT"/>
+ <enum value="0x8E7E" name="GL_MAX_TESS_GEN_LEVEL"/>
+ <enum value="0x8E7E" name="GL_MAX_TESS_GEN_LEVEL_EXT"/>
+ <enum value="0x8E7F" name="GL_MAX_TESS_CONTROL_UNIFORM_COMPONENTS"/>
+ <enum value="0x8E7F" name="GL_MAX_TESS_CONTROL_UNIFORM_COMPONENTS_EXT"/>
+ <enum value="0x8E80" name="GL_MAX_TESS_EVALUATION_UNIFORM_COMPONENTS"/>
+ <enum value="0x8E80" name="GL_MAX_TESS_EVALUATION_UNIFORM_COMPONENTS_EXT"/>
+ <enum value="0x8E81" name="GL_MAX_TESS_CONTROL_TEXTURE_IMAGE_UNITS"/>
+ <enum value="0x8E81" name="GL_MAX_TESS_CONTROL_TEXTURE_IMAGE_UNITS_EXT"/>
+ <enum value="0x8E82" name="GL_MAX_TESS_EVALUATION_TEXTURE_IMAGE_UNITS"/>
+ <enum value="0x8E82" name="GL_MAX_TESS_EVALUATION_TEXTURE_IMAGE_UNITS_EXT"/>
+ <enum value="0x8E83" name="GL_MAX_TESS_CONTROL_OUTPUT_COMPONENTS"/>
+ <enum value="0x8E83" name="GL_MAX_TESS_CONTROL_OUTPUT_COMPONENTS_EXT"/>
+ <enum value="0x8E84" name="GL_MAX_TESS_PATCH_COMPONENTS"/>
+ <enum value="0x8E84" name="GL_MAX_TESS_PATCH_COMPONENTS_EXT"/>
+ <enum value="0x8E85" name="GL_MAX_TESS_CONTROL_TOTAL_OUTPUT_COMPONENTS"/>
+ <enum value="0x8E85" name="GL_MAX_TESS_CONTROL_TOTAL_OUTPUT_COMPONENTS_EXT"/>
+ <enum value="0x8E86" name="GL_MAX_TESS_EVALUATION_OUTPUT_COMPONENTS"/>
+ <enum value="0x8E86" name="GL_MAX_TESS_EVALUATION_OUTPUT_COMPONENTS_EXT"/>
+ <enum value="0x8E87" name="GL_TESS_EVALUATION_SHADER"/>
+ <enum value="0x8E87" name="GL_TESS_EVALUATION_SHADER_EXT"/>
+ <enum value="0x8E88" name="GL_TESS_CONTROL_SHADER"/>
+ <enum value="0x8E88" name="GL_TESS_CONTROL_SHADER_EXT"/>
+ <enum value="0x8E89" name="GL_MAX_TESS_CONTROL_UNIFORM_BLOCKS"/>
+ <enum value="0x8E89" name="GL_MAX_TESS_CONTROL_UNIFORM_BLOCKS_EXT"/>
+ <enum value="0x8E8A" name="GL_MAX_TESS_EVALUATION_UNIFORM_BLOCKS"/>
+ <enum value="0x8E8A" name="GL_MAX_TESS_EVALUATION_UNIFORM_BLOCKS_EXT"/>
+ <unused start="0x8E8B" vendor="NV"/>
+ <enum value="0x8E8C" name="GL_COMPRESSED_RGBA_BPTC_UNORM"/>
+ <enum value="0x8E8C" name="GL_COMPRESSED_RGBA_BPTC_UNORM_ARB"/>
+ <enum value="0x8E8D" name="GL_COMPRESSED_SRGB_ALPHA_BPTC_UNORM"/>
+ <enum value="0x8E8D" name="GL_COMPRESSED_SRGB_ALPHA_BPTC_UNORM_ARB"/>
+ <enum value="0x8E8E" name="GL_COMPRESSED_RGB_BPTC_SIGNED_FLOAT"/>
+ <enum value="0x8E8E" name="GL_COMPRESSED_RGB_BPTC_SIGNED_FLOAT_ARB"/>
+ <enum value="0x8E8F" name="GL_COMPRESSED_RGB_BPTC_UNSIGNED_FLOAT"/>
+ <enum value="0x8E8F" name="GL_COMPRESSED_RGB_BPTC_UNSIGNED_FLOAT_ARB"/>
+ </enums>
+
+ <enums namespace="GL" start="0x8E90" end="0x8E9F" vendor="QNX" comment="For QNX_texture_tiling, QNX_complex_polygon, QNX_stippled_lines (Khronos bug 696)">
+ <unused start="0x8E90" end="0x8E9F" vendor="QNX"/>
+ </enums>
+
+ <enums namespace="GL" start="0x8EA0" end="0x8EAF" vendor="IMG">
+ <unused start="0x8EA0" end="0x8EAF" vendor="IMG"/>
+ </enums>
+
+ <enums namespace="GL" start="0x8EB0" end="0x8EBF" vendor="OES" comment="For Affie Munshi 2007/07/20">
+ <unused start="0x8EB0" end="0x8EBF" vendor="OES"/>
+ </enums>
+
+ <enums namespace="GL" start="0x8EC0" end="0x8ECF" vendor="Vincent">
+ <unused start="0x8EC0" end="0x8ECF" vendor="Vincent"/>
+ </enums>
+
+ <enums namespace="GL" start="0x8ED0" end="0x8F4F" vendor="NV" comment="For Pat Brown, Khronos bug 3191">
+ <enum value="0x8ED0" name="GL_COVERAGE_COMPONENT_NV"/>
+ <enum value="0x8ED1" name="GL_COVERAGE_COMPONENT4_NV"/>
+ <enum value="0x8ED2" name="GL_COVERAGE_ATTACHMENT_NV"/>
+ <enum value="0x8ED3" name="GL_COVERAGE_BUFFERS_NV"/>
+ <enum value="0x8ED4" name="GL_COVERAGE_SAMPLES_NV"/>
+ <enum value="0x8ED5" name="GL_COVERAGE_ALL_FRAGMENTS_NV"/>
+ <enum value="0x8ED6" name="GL_COVERAGE_EDGE_FRAGMENTS_NV"/>
+ <enum value="0x8ED7" name="GL_COVERAGE_AUTOMATIC_NV"/>
+ <unused start="0x8ED8" end="0x8F1C" vendor="NV"/>
+ <enum value="0x8F1D" name="GL_BUFFER_GPU_ADDRESS_NV"/>
+ <enum value="0x8F1E" name="GL_VERTEX_ATTRIB_ARRAY_UNIFIED_NV"/>
+ <enum value="0x8F1F" name="GL_ELEMENT_ARRAY_UNIFIED_NV"/>
+ <enum value="0x8F20" name="GL_VERTEX_ATTRIB_ARRAY_ADDRESS_NV"/>
+ <enum value="0x8F21" name="GL_VERTEX_ARRAY_ADDRESS_NV"/>
+ <enum value="0x8F22" name="GL_NORMAL_ARRAY_ADDRESS_NV"/>
+ <enum value="0x8F23" name="GL_COLOR_ARRAY_ADDRESS_NV"/>
+ <enum value="0x8F24" name="GL_INDEX_ARRAY_ADDRESS_NV"/>
+ <enum value="0x8F25" name="GL_TEXTURE_COORD_ARRAY_ADDRESS_NV"/>
+ <enum value="0x8F26" name="GL_EDGE_FLAG_ARRAY_ADDRESS_NV"/>
+ <enum value="0x8F27" name="GL_SECONDARY_COLOR_ARRAY_ADDRESS_NV"/>
+ <enum value="0x8F28" name="GL_FOG_COORD_ARRAY_ADDRESS_NV"/>
+ <enum value="0x8F29" name="GL_ELEMENT_ARRAY_ADDRESS_NV"/>
+ <enum value="0x8F2A" name="GL_VERTEX_ATTRIB_ARRAY_LENGTH_NV"/>
+ <enum value="0x8F2B" name="GL_VERTEX_ARRAY_LENGTH_NV"/>
+ <enum value="0x8F2C" name="GL_NORMAL_ARRAY_LENGTH_NV"/>
+ <enum value="0x8F2D" name="GL_COLOR_ARRAY_LENGTH_NV"/>
+ <enum value="0x8F2E" name="GL_INDEX_ARRAY_LENGTH_NV"/>
+ <enum value="0x8F2F" name="GL_TEXTURE_COORD_ARRAY_LENGTH_NV"/>
+ <enum value="0x8F30" name="GL_EDGE_FLAG_ARRAY_LENGTH_NV"/>
+ <enum value="0x8F31" name="GL_SECONDARY_COLOR_ARRAY_LENGTH_NV"/>
+ <enum value="0x8F32" name="GL_FOG_COORD_ARRAY_LENGTH_NV"/>
+ <enum value="0x8F33" name="GL_ELEMENT_ARRAY_LENGTH_NV"/>
+ <enum value="0x8F34" name="GL_GPU_ADDRESS_NV"/>
+ <enum value="0x8F35" name="GL_MAX_SHADER_BUFFER_ADDRESS_NV"/>
+ <enum value="0x8F36" name="GL_COPY_READ_BUFFER"/>
+ <enum value="0x8F36" name="GL_COPY_READ_BUFFER_NV"/>
+ <enum value="0x8F36" name="GL_COPY_READ_BUFFER_BINDING" alias="GL_COPY_READ_BUFFER"/>
+ <enum value="0x8F37" name="GL_COPY_WRITE_BUFFER"/>
+ <enum value="0x8F37" name="GL_COPY_WRITE_BUFFER_NV"/>
+ <enum value="0x8F37" name="GL_COPY_WRITE_BUFFER_BINDING" alias="GL_COPY_WRITE_BUFFER"/>
+ <enum value="0x8F38" name="GL_MAX_IMAGE_UNITS"/>
+ <enum value="0x8F38" name="GL_MAX_IMAGE_UNITS_EXT"/>
+ <enum value="0x8F39" name="GL_MAX_COMBINED_IMAGE_UNITS_AND_FRAGMENT_OUTPUTS"/>
+ <enum value="0x8F39" name="GL_MAX_COMBINED_IMAGE_UNITS_AND_FRAGMENT_OUTPUTS_EXT"/>
+ <enum value="0x8F39" name="GL_MAX_COMBINED_SHADER_OUTPUT_RESOURCES" alias="GL_MAX_COMBINED_IMAGE_UNITS_AND_FRAGMENT_OUTPUTS"/>
+ <enum value="0x8F3A" name="GL_IMAGE_BINDING_NAME"/>
+ <enum value="0x8F3A" name="GL_IMAGE_BINDING_NAME_EXT"/>
+ <enum value="0x8F3B" name="GL_IMAGE_BINDING_LEVEL"/>
+ <enum value="0x8F3B" name="GL_IMAGE_BINDING_LEVEL_EXT"/>
+ <enum value="0x8F3C" name="GL_IMAGE_BINDING_LAYERED"/>
+ <enum value="0x8F3C" name="GL_IMAGE_BINDING_LAYERED_EXT"/>
+ <enum value="0x8F3D" name="GL_IMAGE_BINDING_LAYER"/>
+ <enum value="0x8F3D" name="GL_IMAGE_BINDING_LAYER_EXT"/>
+ <enum value="0x8F3E" name="GL_IMAGE_BINDING_ACCESS"/>
+ <enum value="0x8F3E" name="GL_IMAGE_BINDING_ACCESS_EXT"/>
+ <enum value="0x8F3F" name="GL_DRAW_INDIRECT_BUFFER"/>
+ <enum value="0x8F40" name="GL_DRAW_INDIRECT_UNIFIED_NV"/>
+ <enum value="0x8F41" name="GL_DRAW_INDIRECT_ADDRESS_NV"/>
+ <enum value="0x8F42" name="GL_DRAW_INDIRECT_LENGTH_NV"/>
+ <enum value="0x8F43" name="GL_DRAW_INDIRECT_BUFFER_BINDING"/>
+ <enum value="0x8F44" name="GL_MAX_PROGRAM_SUBROUTINE_PARAMETERS_NV"/>
+ <enum value="0x8F45" name="GL_MAX_PROGRAM_SUBROUTINE_NUM_NV"/>
+ <enum value="0x8F46" name="GL_DOUBLE_MAT2"/>
+ <enum value="0x8F46" name="GL_DOUBLE_MAT2_EXT"/>
+ <enum value="0x8F47" name="GL_DOUBLE_MAT3"/>
+ <enum value="0x8F47" name="GL_DOUBLE_MAT3_EXT"/>
+ <enum value="0x8F48" name="GL_DOUBLE_MAT4"/>
+ <enum value="0x8F48" name="GL_DOUBLE_MAT4_EXT"/>
+ <enum value="0x8F49" name="GL_DOUBLE_MAT2x3"/>
+ <enum value="0x8F49" name="GL_DOUBLE_MAT2x3_EXT"/>
+ <enum value="0x8F4A" name="GL_DOUBLE_MAT2x4"/>
+ <enum value="0x8F4A" name="GL_DOUBLE_MAT2x4_EXT"/>
+ <enum value="0x8F4B" name="GL_DOUBLE_MAT3x2"/>
+ <enum value="0x8F4B" name="GL_DOUBLE_MAT3x2_EXT"/>
+ <enum value="0x8F4C" name="GL_DOUBLE_MAT3x4"/>
+ <enum value="0x8F4C" name="GL_DOUBLE_MAT3x4_EXT"/>
+ <enum value="0x8F4D" name="GL_DOUBLE_MAT4x2"/>
+ <enum value="0x8F4D" name="GL_DOUBLE_MAT4x2_EXT"/>
+ <enum value="0x8F4E" name="GL_DOUBLE_MAT4x3"/>
+ <enum value="0x8F4E" name="GL_DOUBLE_MAT4x3_EXT"/>
+ <enum value="0x8F4F" name="GL_VERTEX_BINDING_BUFFER"/>
+ </enums>
+
+ <enums namespace="GL" start="0x8F50" end="0x8F5F" vendor="ZiiLabs" comment="For Jon Kennedy, Khronos public bug 75">
+ <unused start="0x8F50" end="0x8F5F" vendor="ZiiLabs"/>
+ </enums>
+
+ <enums namespace="GL" start="0x8F60" end="0x8F6F" vendor="ARM" comment="For Remi Pedersen, Khronos bug 3745">
+ <enum value="0x8F60" name="GL_MALI_SHADER_BINARY_ARM"/>
+ <enum value="0x8F61" name="GL_MALI_PROGRAM_BINARY_ARM"/>
+ <unused start="0x8F62" vendor="ARM"/>
+ <enum value="0x8F63" name="GL_MAX_SHADER_PIXEL_LOCAL_STORAGE_FAST_SIZE_EXT"/>
+ <enum value="0x8F64" name="GL_SHADER_PIXEL_LOCAL_STORAGE_EXT"/>
+ <enum value="0x8F65" name="GL_FETCH_PER_SAMPLE_ARM"/>
+ <enum value="0x8F66" name="GL_FRAGMENT_SHADER_FRAMEBUFFER_FETCH_MRT_ARM"/>
+ <enum value="0x8F67" name="GL_MAX_SHADER_PIXEL_LOCAL_STORAGE_SIZE_EXT"/>
+ <unused start="0x8F68" end="0x8F6F" vendor="ARM"/>
+ </enums>
+
+ <enums namespace="GL" start="0x8F70" end="0x8F7F" vendor="HI" comment="For Mark Callow, Khronos bug 4055. Shared with EGL.">
+ <unused start="0x8F70" end="0x8F7F" vendor="HI"/>
+ </enums>
+
+ <enums namespace="GL" start="0x8F80" end="0x8F8F" vendor="Zebra" comment="For Mike Weiblen, public bug 910">
+ <unused start="0x8F80" end="0x8F8F" vendor="Zebra"/>
+ </enums>
+
+ <enums namespace="GL" start="0x8F90" end="0x8F9F" vendor="ARB">
+ <enum value="0x8F90" name="GL_RED_SNORM"/>
+ <enum value="0x8F91" name="GL_RG_SNORM"/>
+ <enum value="0x8F92" name="GL_RGB_SNORM"/>
+ <enum value="0x8F93" name="GL_RGBA_SNORM"/>
+ <enum value="0x8F94" name="GL_R8_SNORM"/>
+ <enum value="0x8F95" name="GL_RG8_SNORM"/>
+ <enum value="0x8F96" name="GL_RGB8_SNORM"/>
+ <enum value="0x8F97" name="GL_RGBA8_SNORM"/>
+ <enum value="0x8F98" name="GL_R16_SNORM"/>
+ <enum value="0x8F99" name="GL_RG16_SNORM"/>
+ <enum value="0x8F9A" name="GL_RGB16_SNORM"/>
+ <enum value="0x8F9B" name="GL_RGBA16_SNORM"/>
+ <enum value="0x8F9C" name="GL_SIGNED_NORMALIZED"/>
+ <enum value="0x8F9D" name="GL_PRIMITIVE_RESTART"/>
+ <enum value="0x8F9E" name="GL_PRIMITIVE_RESTART_INDEX"/>
+ <enum value="0x8F9F" name="GL_MAX_PROGRAM_TEXTURE_GATHER_COMPONENTS_ARB"/>
+ </enums>
+
+ <enums namespace="GL" start="0x8FA0" end="0x8FBF" vendor="QCOM" comment="For Maurice Ribble, bug 4512">
+ <enum value="0x8FA0" name="GL_PERFMON_GLOBAL_MODE_QCOM"/>
+ <unused start="0x8FA1" end="0x8FAF" vendor="QCOM"/>
+ <enum value="0x8FB0" name="GL_BINNING_CONTROL_HINT_QCOM"/>
+ <enum value="0x8FB1" name="GL_CPU_OPTIMIZED_QCOM"/>
+ <enum value="0x8FB2" name="GL_GPU_OPTIMIZED_QCOM"/>
+ <enum value="0x8FB3" name="GL_RENDER_DIRECT_TO_FRAMEBUFFER_QCOM"/>
+ <unused start="0x8FB4" end="0x8FBA" vendor="QCOM"/>
+ <enum value="0x8FBB" name="GL_GPU_DISJOINT_EXT"/>
+ <unused start="0x8FBC" end="0x8FBF" vendor="QCOM"/>
+ </enums>
+
+ <enums namespace="GL" start="0x8FC0" end="0x8FDF" vendor="VIV" comment="For Frido Garritsen, bug 4526">
+ <enum value="0x8FC4" name="GL_SHADER_BINARY_VIV"/>
+ </enums>
+
+ <enums namespace="GL" start="0x8FE0" end="0x8FFF" vendor="NV" comment="For Pat Brown, bug 4935">
+ <enum value="0x8FE0" name="GL_INT8_NV"/>
+ <enum value="0x8FE1" name="GL_INT8_VEC2_NV"/>
+ <enum value="0x8FE2" name="GL_INT8_VEC3_NV"/>
+ <enum value="0x8FE3" name="GL_INT8_VEC4_NV"/>
+ <enum value="0x8FE4" name="GL_INT16_NV"/>
+ <enum value="0x8FE5" name="GL_INT16_VEC2_NV"/>
+ <enum value="0x8FE6" name="GL_INT16_VEC3_NV"/>
+ <enum value="0x8FE7" name="GL_INT16_VEC4_NV"/>
+ <enum value="0x8FE9" name="GL_INT64_VEC2_NV"/>
+ <enum value="0x8FEA" name="GL_INT64_VEC3_NV"/>
+ <enum value="0x8FEB" name="GL_INT64_VEC4_NV"/>
+ <enum value="0x8FEC" name="GL_UNSIGNED_INT8_NV"/>
+ <enum value="0x8FED" name="GL_UNSIGNED_INT8_VEC2_NV"/>
+ <enum value="0x8FEE" name="GL_UNSIGNED_INT8_VEC3_NV"/>
+ <enum value="0x8FEF" name="GL_UNSIGNED_INT8_VEC4_NV"/>
+ <enum value="0x8FF0" name="GL_UNSIGNED_INT16_NV"/>
+ <enum value="0x8FF1" name="GL_UNSIGNED_INT16_VEC2_NV"/>
+ <enum value="0x8FF2" name="GL_UNSIGNED_INT16_VEC3_NV"/>
+ <enum value="0x8FF3" name="GL_UNSIGNED_INT16_VEC4_NV"/>
+ <enum value="0x8FF5" name="GL_UNSIGNED_INT64_VEC2_NV"/>
+ <enum value="0x8FF6" name="GL_UNSIGNED_INT64_VEC3_NV"/>
+ <enum value="0x8FF7" name="GL_UNSIGNED_INT64_VEC4_NV"/>
+ <enum value="0x8FF8" name="GL_FLOAT16_NV"/>
+ <enum value="0x8FF9" name="GL_FLOAT16_VEC2_NV"/>
+ <enum value="0x8FFA" name="GL_FLOAT16_VEC3_NV"/>
+ <enum value="0x8FFB" name="GL_FLOAT16_VEC4_NV"/>
+ <enum value="0x8FFC" name="GL_DOUBLE_VEC2"/>
+ <enum value="0x8FFC" name="GL_DOUBLE_VEC2_EXT"/>
+ <enum value="0x8FFD" name="GL_DOUBLE_VEC3"/>
+ <enum value="0x8FFD" name="GL_DOUBLE_VEC3_EXT"/>
+ <enum value="0x8FFE" name="GL_DOUBLE_VEC4"/>
+ <enum value="0x8FFE" name="GL_DOUBLE_VEC4_EXT"/>
+ <unused start="0x8FFF" vendor="NV"/>
+ </enums>
+
+ <enums namespace="GL" start="0x9000" end="0x901F" vendor="AMD" comment="For Bill Licea-Kane">
+ <enum value="0x9001" name="GL_SAMPLER_BUFFER_AMD"/>
+ <enum value="0x9002" name="GL_INT_SAMPLER_BUFFER_AMD"/>
+ <enum value="0x9003" name="GL_UNSIGNED_INT_SAMPLER_BUFFER_AMD"/>
+ <enum value="0x9004" name="GL_TESSELLATION_MODE_AMD"/>
+ <enum value="0x9005" name="GL_TESSELLATION_FACTOR_AMD"/>
+ <enum value="0x9006" name="GL_DISCRETE_AMD"/>
+ <enum value="0x9007" name="GL_CONTINUOUS_AMD"/>
+ <unused start="0x9008" vendor="AMD"/>
+ <enum value="0x9009" name="GL_TEXTURE_CUBE_MAP_ARRAY"/>
+ <enum value="0x9009" name="GL_TEXTURE_CUBE_MAP_ARRAY_ARB"/>
+ <enum value="0x9009" name="GL_TEXTURE_CUBE_MAP_ARRAY_EXT"/>
+ <enum value="0x900A" name="GL_TEXTURE_BINDING_CUBE_MAP_ARRAY"/>
+ <enum value="0x900A" name="GL_TEXTURE_BINDING_CUBE_MAP_ARRAY_ARB"/>
+ <enum value="0x900A" name="GL_TEXTURE_BINDING_CUBE_MAP_ARRAY_EXT"/>
+ <enum value="0x900B" name="GL_PROXY_TEXTURE_CUBE_MAP_ARRAY"/>
+ <enum value="0x900B" name="GL_PROXY_TEXTURE_CUBE_MAP_ARRAY_ARB"/>
+ <enum value="0x900C" name="GL_SAMPLER_CUBE_MAP_ARRAY"/>
+ <enum value="0x900C" name="GL_SAMPLER_CUBE_MAP_ARRAY_ARB"/>
+ <enum value="0x900C" name="GL_SAMPLER_CUBE_MAP_ARRAY_EXT"/>
+ <enum value="0x900D" name="GL_SAMPLER_CUBE_MAP_ARRAY_SHADOW"/>
+ <enum value="0x900D" name="GL_SAMPLER_CUBE_MAP_ARRAY_SHADOW_ARB"/>
+ <enum value="0x900D" name="GL_SAMPLER_CUBE_MAP_ARRAY_SHADOW_EXT"/>
+ <enum value="0x900E" name="GL_INT_SAMPLER_CUBE_MAP_ARRAY"/>
+ <enum value="0x900E" name="GL_INT_SAMPLER_CUBE_MAP_ARRAY_ARB"/>
+ <enum value="0x900E" name="GL_INT_SAMPLER_CUBE_MAP_ARRAY_EXT"/>
+ <enum value="0x900F" name="GL_UNSIGNED_INT_SAMPLER_CUBE_MAP_ARRAY"/>
+ <enum value="0x900F" name="GL_UNSIGNED_INT_SAMPLER_CUBE_MAP_ARRAY_ARB"/>
+ <enum value="0x900F" name="GL_UNSIGNED_INT_SAMPLER_CUBE_MAP_ARRAY_EXT"/>
+ <enum value="0x9010" name="GL_ALPHA_SNORM"/>
+ <enum value="0x9011" name="GL_LUMINANCE_SNORM"/>
+ <enum value="0x9012" name="GL_LUMINANCE_ALPHA_SNORM"/>
+ <enum value="0x9013" name="GL_INTENSITY_SNORM"/>
+ <enum value="0x9014" name="GL_ALPHA8_SNORM"/>
+ <enum value="0x9015" name="GL_LUMINANCE8_SNORM"/>
+ <enum value="0x9016" name="GL_LUMINANCE8_ALPHA8_SNORM"/>
+ <enum value="0x9017" name="GL_INTENSITY8_SNORM"/>
+ <enum value="0x9018" name="GL_ALPHA16_SNORM"/>
+ <enum value="0x9019" name="GL_LUMINANCE16_SNORM"/>
+ <enum value="0x901A" name="GL_LUMINANCE16_ALPHA16_SNORM"/>
+ <enum value="0x901B" name="GL_INTENSITY16_SNORM"/>
+ <enum value="0x901C" name="GL_FACTOR_MIN_AMD"/>
+ <enum value="0x901D" name="GL_FACTOR_MAX_AMD"/>
+ <enum value="0x901E" name="GL_DEPTH_CLAMP_NEAR_AMD"/>
+ <enum value="0x901F" name="GL_DEPTH_CLAMP_FAR_AMD"/>
+ </enums>
+
+ <enums namespace="GL" start="0x9020" end="0x90FF" vendor="NV" comment="For Pat Brown, bug 4935">
+ <enum value="0x9020" name="GL_VIDEO_BUFFER_NV"/>
+ <enum value="0x9021" name="GL_VIDEO_BUFFER_BINDING_NV"/>
+ <enum value="0x9022" name="GL_FIELD_UPPER_NV"/>
+ <enum value="0x9023" name="GL_FIELD_LOWER_NV"/>
+ <enum value="0x9024" name="GL_NUM_VIDEO_CAPTURE_STREAMS_NV"/>
+ <enum value="0x9025" name="GL_NEXT_VIDEO_CAPTURE_BUFFER_STATUS_NV"/>
+ <enum value="0x9026" name="GL_VIDEO_CAPTURE_TO_422_SUPPORTED_NV"/>
+ <enum value="0x9027" name="GL_LAST_VIDEO_CAPTURE_STATUS_NV"/>
+ <enum value="0x9028" name="GL_VIDEO_BUFFER_PITCH_NV"/>
+ <enum value="0x9029" name="GL_VIDEO_COLOR_CONVERSION_MATRIX_NV"/>
+ <enum value="0x902A" name="GL_VIDEO_COLOR_CONVERSION_MAX_NV"/>
+ <enum value="0x902B" name="GL_VIDEO_COLOR_CONVERSION_MIN_NV"/>
+ <enum value="0x902C" name="GL_VIDEO_COLOR_CONVERSION_OFFSET_NV"/>
+ <enum value="0x902D" name="GL_VIDEO_BUFFER_INTERNAL_FORMAT_NV"/>
+ <enum value="0x902E" name="GL_PARTIAL_SUCCESS_NV"/>
+ <enum value="0x902F" name="GL_SUCCESS_NV"/>
+ <enum value="0x9030" name="GL_FAILURE_NV"/>
+ <enum value="0x9031" name="GL_YCBYCR8_422_NV"/>
+ <enum value="0x9032" name="GL_YCBAYCR8A_4224_NV"/>
+ <enum value="0x9033" name="GL_Z6Y10Z6CB10Z6Y10Z6CR10_422_NV"/>
+ <enum value="0x9034" name="GL_Z6Y10Z6CB10Z6A10Z6Y10Z6CR10Z6A10_4224_NV"/>
+ <enum value="0x9035" name="GL_Z4Y12Z4CB12Z4Y12Z4CR12_422_NV"/>
+ <enum value="0x9036" name="GL_Z4Y12Z4CB12Z4A12Z4Y12Z4CR12Z4A12_4224_NV"/>
+ <enum value="0x9037" name="GL_Z4Y12Z4CB12Z4CR12_444_NV"/>
+ <enum value="0x9038" name="GL_VIDEO_CAPTURE_FRAME_WIDTH_NV"/>
+ <enum value="0x9039" name="GL_VIDEO_CAPTURE_FRAME_HEIGHT_NV"/>
+ <enum value="0x903A" name="GL_VIDEO_CAPTURE_FIELD_UPPER_HEIGHT_NV"/>
+ <enum value="0x903B" name="GL_VIDEO_CAPTURE_FIELD_LOWER_HEIGHT_NV"/>
+ <enum value="0x903C" name="GL_VIDEO_CAPTURE_SURFACE_ORIGIN_NV"/>
+ <unused start="0x903D" end="0x9044" vendor="NV"/>
+ <enum value="0x9045" name="GL_TEXTURE_COVERAGE_SAMPLES_NV"/>
+ <enum value="0x9046" name="GL_TEXTURE_COLOR_SAMPLES_NV"/>
+ <enum value="0x9047" name="GL_GPU_MEMORY_INFO_DEDICATED_VIDMEM_NVX"/>
+ <enum value="0x9048" name="GL_GPU_MEMORY_INFO_TOTAL_AVAILABLE_MEMORY_NVX"/>
+ <enum value="0x9049" name="GL_GPU_MEMORY_INFO_CURRENT_AVAILABLE_VIDMEM_NVX"/>
+ <enum value="0x904A" name="GL_GPU_MEMORY_INFO_EVICTION_COUNT_NVX"/>
+ <enum value="0x904B" name="GL_GPU_MEMORY_INFO_EVICTED_MEMORY_NVX"/>
+ <enum value="0x904C" name="GL_IMAGE_1D"/>
+ <enum value="0x904C" name="GL_IMAGE_1D_EXT"/>
+ <enum value="0x904D" name="GL_IMAGE_2D"/>
+ <enum value="0x904D" name="GL_IMAGE_2D_EXT"/>
+ <enum value="0x904E" name="GL_IMAGE_3D"/>
+ <enum value="0x904E" name="GL_IMAGE_3D_EXT"/>
+ <enum value="0x904F" name="GL_IMAGE_2D_RECT"/>
+ <enum value="0x904F" name="GL_IMAGE_2D_RECT_EXT"/>
+ <enum value="0x9050" name="GL_IMAGE_CUBE"/>
+ <enum value="0x9050" name="GL_IMAGE_CUBE_EXT"/>
+ <enum value="0x9051" name="GL_IMAGE_BUFFER"/>
+ <enum value="0x9051" name="GL_IMAGE_BUFFER_EXT"/>
+ <enum value="0x9052" name="GL_IMAGE_1D_ARRAY"/>
+ <enum value="0x9052" name="GL_IMAGE_1D_ARRAY_EXT"/>
+ <enum value="0x9053" name="GL_IMAGE_2D_ARRAY"/>
+ <enum value="0x9053" name="GL_IMAGE_2D_ARRAY_EXT"/>
+ <enum value="0x9054" name="GL_IMAGE_CUBE_MAP_ARRAY"/>
+ <enum value="0x9054" name="GL_IMAGE_CUBE_MAP_ARRAY_EXT"/>
+ <enum value="0x9055" name="GL_IMAGE_2D_MULTISAMPLE"/>
+ <enum value="0x9055" name="GL_IMAGE_2D_MULTISAMPLE_EXT"/>
+ <enum value="0x9056" name="GL_IMAGE_2D_MULTISAMPLE_ARRAY"/>
+ <enum value="0x9056" name="GL_IMAGE_2D_MULTISAMPLE_ARRAY_EXT"/>
+ <enum value="0x9057" name="GL_INT_IMAGE_1D"/>
+ <enum value="0x9057" name="GL_INT_IMAGE_1D_EXT"/>
+ <enum value="0x9058" name="GL_INT_IMAGE_2D"/>
+ <enum value="0x9058" name="GL_INT_IMAGE_2D_EXT"/>
+ <enum value="0x9059" name="GL_INT_IMAGE_3D"/>
+ <enum value="0x9059" name="GL_INT_IMAGE_3D_EXT"/>
+ <enum value="0x905A" name="GL_INT_IMAGE_2D_RECT"/>
+ <enum value="0x905A" name="GL_INT_IMAGE_2D_RECT_EXT"/>
+ <enum value="0x905B" name="GL_INT_IMAGE_CUBE"/>
+ <enum value="0x905B" name="GL_INT_IMAGE_CUBE_EXT"/>
+ <enum value="0x905C" name="GL_INT_IMAGE_BUFFER"/>
+ <enum value="0x905C" name="GL_INT_IMAGE_BUFFER_EXT"/>
+ <enum value="0x905D" name="GL_INT_IMAGE_1D_ARRAY"/>
+ <enum value="0x905D" name="GL_INT_IMAGE_1D_ARRAY_EXT"/>
+ <enum value="0x905E" name="GL_INT_IMAGE_2D_ARRAY"/>
+ <enum value="0x905E" name="GL_INT_IMAGE_2D_ARRAY_EXT"/>
+ <enum value="0x905F" name="GL_INT_IMAGE_CUBE_MAP_ARRAY"/>
+ <enum value="0x905F" name="GL_INT_IMAGE_CUBE_MAP_ARRAY_EXT"/>
+ <enum value="0x9060" name="GL_INT_IMAGE_2D_MULTISAMPLE"/>
+ <enum value="0x9060" name="GL_INT_IMAGE_2D_MULTISAMPLE_EXT"/>
+ <enum value="0x9061" name="GL_INT_IMAGE_2D_MULTISAMPLE_ARRAY"/>
+ <enum value="0x9061" name="GL_INT_IMAGE_2D_MULTISAMPLE_ARRAY_EXT"/>
+ <enum value="0x9062" name="GL_UNSIGNED_INT_IMAGE_1D"/>
+ <enum value="0x9062" name="GL_UNSIGNED_INT_IMAGE_1D_EXT"/>
+ <enum value="0x9063" name="GL_UNSIGNED_INT_IMAGE_2D"/>
+ <enum value="0x9063" name="GL_UNSIGNED_INT_IMAGE_2D_EXT"/>
+ <enum value="0x9064" name="GL_UNSIGNED_INT_IMAGE_3D"/>
+ <enum value="0x9064" name="GL_UNSIGNED_INT_IMAGE_3D_EXT"/>
+ <enum value="0x9065" name="GL_UNSIGNED_INT_IMAGE_2D_RECT"/>
+ <enum value="0x9065" name="GL_UNSIGNED_INT_IMAGE_2D_RECT_EXT"/>
+ <enum value="0x9066" name="GL_UNSIGNED_INT_IMAGE_CUBE"/>
+ <enum value="0x9066" name="GL_UNSIGNED_INT_IMAGE_CUBE_EXT"/>
+ <enum value="0x9067" name="GL_UNSIGNED_INT_IMAGE_BUFFER"/>
+ <enum value="0x9067" name="GL_UNSIGNED_INT_IMAGE_BUFFER_EXT"/>
+ <enum value="0x9068" name="GL_UNSIGNED_INT_IMAGE_1D_ARRAY"/>
+ <enum value="0x9068" name="GL_UNSIGNED_INT_IMAGE_1D_ARRAY_EXT"/>
+ <enum value="0x9069" name="GL_UNSIGNED_INT_IMAGE_2D_ARRAY"/>
+ <enum value="0x9069" name="GL_UNSIGNED_INT_IMAGE_2D_ARRAY_EXT"/>
+ <enum value="0x906A" name="GL_UNSIGNED_INT_IMAGE_CUBE_MAP_ARRAY"/>
+ <enum value="0x906A" name="GL_UNSIGNED_INT_IMAGE_CUBE_MAP_ARRAY_EXT"/>
+ <enum value="0x906B" name="GL_UNSIGNED_INT_IMAGE_2D_MULTISAMPLE"/>
+ <enum value="0x906B" name="GL_UNSIGNED_INT_IMAGE_2D_MULTISAMPLE_EXT"/>
+ <enum value="0x906C" name="GL_UNSIGNED_INT_IMAGE_2D_MULTISAMPLE_ARRAY"/>
+ <enum value="0x906C" name="GL_UNSIGNED_INT_IMAGE_2D_MULTISAMPLE_ARRAY_EXT"/>
+ <enum value="0x906D" name="GL_MAX_IMAGE_SAMPLES"/>
+ <enum value="0x906D" name="GL_MAX_IMAGE_SAMPLES_EXT"/>
+ <enum value="0x906E" name="GL_IMAGE_BINDING_FORMAT"/>
+ <enum value="0x906E" name="GL_IMAGE_BINDING_FORMAT_EXT"/>
+ <enum value="0x906F" name="GL_RGB10_A2UI"/>
+ <enum value="0x9070" name="GL_PATH_FORMAT_SVG_NV"/>
+ <enum value="0x9071" name="GL_PATH_FORMAT_PS_NV"/>
+ <enum value="0x9072" name="GL_STANDARD_FONT_NAME_NV"/>
+ <enum value="0x9073" name="GL_SYSTEM_FONT_NAME_NV"/>
+ <enum value="0x9074" name="GL_FILE_NAME_NV"/>
+ <enum value="0x9075" name="GL_PATH_STROKE_WIDTH_NV"/>
+ <enum value="0x9076" name="GL_PATH_END_CAPS_NV"/>
+ <enum value="0x9077" name="GL_PATH_INITIAL_END_CAP_NV"/>
+ <enum value="0x9078" name="GL_PATH_TERMINAL_END_CAP_NV"/>
+ <enum value="0x9079" name="GL_PATH_JOIN_STYLE_NV"/>
+ <enum value="0x907A" name="GL_PATH_MITER_LIMIT_NV"/>
+ <enum value="0x907B" name="GL_PATH_DASH_CAPS_NV"/>
+ <enum value="0x907C" name="GL_PATH_INITIAL_DASH_CAP_NV"/>
+ <enum value="0x907D" name="GL_PATH_TERMINAL_DASH_CAP_NV"/>
+ <enum value="0x907E" name="GL_PATH_DASH_OFFSET_NV"/>
+ <enum value="0x907F" name="GL_PATH_CLIENT_LENGTH_NV"/>
+ <enum value="0x9080" name="GL_PATH_FILL_MODE_NV"/>
+ <enum value="0x9081" name="GL_PATH_FILL_MASK_NV"/>
+ <enum value="0x9082" name="GL_PATH_FILL_COVER_MODE_NV"/>
+ <enum value="0x9083" name="GL_PATH_STROKE_COVER_MODE_NV"/>
+ <enum value="0x9084" name="GL_PATH_STROKE_MASK_NV"/>
+ <!-- <enum value="0x9085" name="GL_PATH_SAMPLE_QUALITY_NV" comment="Removed from extension"/> -->
+ <!-- <enum value="0x9086" name="GL_PATH_STROKE_BOUND_NV" comment="Removed from extension"/> -->
+ <!-- <enum value="0x9087" name="GL_PATH_STROKE_OVERSAMPLE_COUNT_NV" comment="Removed from extension"/> -->
+ <enum value="0x9088" name="GL_COUNT_UP_NV"/>
+ <enum value="0x9089" name="GL_COUNT_DOWN_NV"/>
+ <enum value="0x908A" name="GL_PATH_OBJECT_BOUNDING_BOX_NV"/>
+ <enum value="0x908B" name="GL_CONVEX_HULL_NV"/>
+ <!-- <enum value="0x908C" name="GL_MULTI_HULLS_NV" comment="Removed from extension"/> -->
+ <enum value="0x908D" name="GL_BOUNDING_BOX_NV"/>
+ <enum value="0x908E" name="GL_TRANSLATE_X_NV"/>
+ <enum value="0x908F" name="GL_TRANSLATE_Y_NV"/>
+ <enum value="0x9090" name="GL_TRANSLATE_2D_NV"/>
+ <enum value="0x9091" name="GL_TRANSLATE_3D_NV"/>
+ <enum value="0x9092" name="GL_AFFINE_2D_NV"/>
+ <!-- <enum value="0x9093" name="GL_PROJECTIVE_2D_NV" comment="Removed from extension"/> -->
+ <enum value="0x9094" name="GL_AFFINE_3D_NV"/>
+ <!-- <enum value="0x9095" name="GL_PROJECTIVE_3D_NV" comment="Removed from extension"/> -->
+ <enum value="0x9096" name="GL_TRANSPOSE_AFFINE_2D_NV"/>
+ <!-- <enum value="0x9097" name="GL_TRANSPOSE_PROJECTIVE_2D_NV" comment="Removed from extension"/> -->
+ <enum value="0x9098" name="GL_TRANSPOSE_AFFINE_3D_NV"/>
+ <!-- <enum value="0x9099" name="GL_TRANSPOSE_PROJECTIVE_3D_NV" comment="Removed from extension"/> -->
+ <enum value="0x909A" name="GL_UTF8_NV"/>
+ <enum value="0x909B" name="GL_UTF16_NV"/>
+ <enum value="0x909C" name="GL_BOUNDING_BOX_OF_BOUNDING_BOXES_NV"/>
+ <enum value="0x909D" name="GL_PATH_COMMAND_COUNT_NV"/>
+ <enum value="0x909E" name="GL_PATH_COORD_COUNT_NV"/>
+ <enum value="0x909F" name="GL_PATH_DASH_ARRAY_COUNT_NV"/>
+ <enum value="0x90A0" name="GL_PATH_COMPUTED_LENGTH_NV"/>
+ <enum value="0x90A1" name="GL_PATH_FILL_BOUNDING_BOX_NV"/>
+ <enum value="0x90A2" name="GL_PATH_STROKE_BOUNDING_BOX_NV"/>
+ <enum value="0x90A3" name="GL_SQUARE_NV"/>
+ <enum value="0x90A4" name="GL_ROUND_NV"/>
+ <enum value="0x90A5" name="GL_TRIANGULAR_NV"/>
+ <enum value="0x90A6" name="GL_BEVEL_NV"/>
+ <enum value="0x90A7" name="GL_MITER_REVERT_NV"/>
+ <enum value="0x90A8" name="GL_MITER_TRUNCATE_NV"/>
+ <enum value="0x90A9" name="GL_SKIP_MISSING_GLYPH_NV"/>
+ <enum value="0x90AA" name="GL_USE_MISSING_GLYPH_NV"/>
+ <enum value="0x90AB" name="GL_PATH_ERROR_POSITION_NV"/>
+ <enum value="0x90AC" name="GL_PATH_FOG_GEN_MODE_NV"/>
+ <enum value="0x90AD" name="GL_ACCUM_ADJACENT_PAIRS_NV"/>
+ <enum value="0x90AE" name="GL_ADJACENT_PAIRS_NV"/>
+ <enum value="0x90AF" name="GL_FIRST_TO_REST_NV"/>
+ <enum value="0x90B0" name="GL_PATH_GEN_MODE_NV"/>
+ <enum value="0x90B1" name="GL_PATH_GEN_COEFF_NV"/>
+ <enum value="0x90B2" name="GL_PATH_GEN_COLOR_FORMAT_NV"/>
+ <enum value="0x90B3" name="GL_PATH_GEN_COMPONENTS_NV"/>
+ <enum value="0x90B4" name="GL_PATH_DASH_OFFSET_RESET_NV"/>
+ <enum value="0x90B5" name="GL_MOVE_TO_RESETS_NV"/>
+ <enum value="0x90B6" name="GL_MOVE_TO_CONTINUES_NV"/>
+ <enum value="0x90B7" name="GL_PATH_STENCIL_FUNC_NV"/>
+ <enum value="0x90B8" name="GL_PATH_STENCIL_REF_NV"/>
+ <enum value="0x90B9" name="GL_PATH_STENCIL_VALUE_MASK_NV"/>
+ <enum value="0x90BA" name="GL_SCALED_RESOLVE_FASTEST_EXT"/>
+ <enum value="0x90BB" name="GL_SCALED_RESOLVE_NICEST_EXT"/>
+ <enum value="0x90BC" name="GL_MIN_MAP_BUFFER_ALIGNMENT"/>
+ <enum value="0x90BD" name="GL_PATH_STENCIL_DEPTH_OFFSET_FACTOR_NV"/>
+ <enum value="0x90BE" name="GL_PATH_STENCIL_DEPTH_OFFSET_UNITS_NV"/>
+ <enum value="0x90BF" name="GL_PATH_COVER_DEPTH_FUNC_NV"/>
+ <unused start="0x90C0" end="0x90C6" vendor="NV"/>
+ <enum value="0x90C7" name="GL_IMAGE_FORMAT_COMPATIBILITY_TYPE"/>
+ <enum value="0x90C8" name="GL_IMAGE_FORMAT_COMPATIBILITY_BY_SIZE"/>
+ <enum value="0x90C9" name="GL_IMAGE_FORMAT_COMPATIBILITY_BY_CLASS"/>
+ <enum value="0x90CA" name="GL_MAX_VERTEX_IMAGE_UNIFORMS"/>
+ <enum value="0x90CB" name="GL_MAX_TESS_CONTROL_IMAGE_UNIFORMS"/>
+ <enum value="0x90CB" name="GL_MAX_TESS_CONTROL_IMAGE_UNIFORMS_EXT"/>
+ <enum value="0x90CC" name="GL_MAX_TESS_EVALUATION_IMAGE_UNIFORMS"/>
+ <enum value="0x90CC" name="GL_MAX_TESS_EVALUATION_IMAGE_UNIFORMS_EXT"/>
+ <enum value="0x90CD" name="GL_MAX_GEOMETRY_IMAGE_UNIFORMS"/>
+ <enum value="0x90CD" name="GL_MAX_GEOMETRY_IMAGE_UNIFORMS_EXT"/>
+ <enum value="0x90CE" name="GL_MAX_FRAGMENT_IMAGE_UNIFORMS"/>
+ <enum value="0x90CF" name="GL_MAX_COMBINED_IMAGE_UNIFORMS"/>
+ <enum value="0x90D0" name="GL_MAX_DEEP_3D_TEXTURE_WIDTH_HEIGHT_NV"/>
+ <enum value="0x90D1" name="GL_MAX_DEEP_3D_TEXTURE_DEPTH_NV"/>
+ <enum value="0x90D2" name="GL_SHADER_STORAGE_BUFFER"/>
+ <enum value="0x90D3" name="GL_SHADER_STORAGE_BUFFER_BINDING"/>
+ <enum value="0x90D4" name="GL_SHADER_STORAGE_BUFFER_START"/>
+ <enum value="0x90D5" name="GL_SHADER_STORAGE_BUFFER_SIZE"/>
+ <enum value="0x90D6" name="GL_MAX_VERTEX_SHADER_STORAGE_BLOCKS"/>
+ <enum value="0x90D7" name="GL_MAX_GEOMETRY_SHADER_STORAGE_BLOCKS"/>
+ <enum value="0x90D7" name="GL_MAX_GEOMETRY_SHADER_STORAGE_BLOCKS_EXT"/>
+ <enum value="0x90D8" name="GL_MAX_TESS_CONTROL_SHADER_STORAGE_BLOCKS"/>
+ <enum value="0x90D8" name="GL_MAX_TESS_CONTROL_SHADER_STORAGE_BLOCKS_EXT"/>
+ <enum value="0x90D9" name="GL_MAX_TESS_EVALUATION_SHADER_STORAGE_BLOCKS"/>
+ <enum value="0x90D9" name="GL_MAX_TESS_EVALUATION_SHADER_STORAGE_BLOCKS_EXT"/>
+ <enum value="0x90DA" name="GL_MAX_FRAGMENT_SHADER_STORAGE_BLOCKS"/>
+ <enum value="0x90DB" name="GL_MAX_COMPUTE_SHADER_STORAGE_BLOCKS"/>
+ <enum value="0x90DC" name="GL_MAX_COMBINED_SHADER_STORAGE_BLOCKS"/>
+ <enum value="0x90DD" name="GL_MAX_SHADER_STORAGE_BUFFER_BINDINGS"/>
+ <enum value="0x90DE" name="GL_MAX_SHADER_STORAGE_BLOCK_SIZE"/>
+ <enum value="0x90DF" name="GL_SHADER_STORAGE_BUFFER_OFFSET_ALIGNMENT"/>
+ <unused start="0x90E0" vendor="NV"/>
+ <enum value="0x90E1" name="GL_SYNC_X11_FENCE_EXT"/>
+ <unused start="0x90E2" end="0x90E9" vendor="NV"/>
+ <enum value="0x90EA" name="GL_DEPTH_STENCIL_TEXTURE_MODE"/>
+ <enum value="0x90EB" name="GL_MAX_COMPUTE_WORK_GROUP_INVOCATIONS"/>
+ <enum value="0x90EB" name="GL_MAX_COMPUTE_FIXED_GROUP_INVOCATIONS_ARB" alias="GL_MAX_COMPUTE_WORK_GROUP_INVOCATIONS"/>
+ <enum value="0x90EC" name="GL_UNIFORM_BLOCK_REFERENCED_BY_COMPUTE_SHADER"/>
+ <enum value="0x90ED" name="GL_ATOMIC_COUNTER_BUFFER_REFERENCED_BY_COMPUTE_SHADER"/>
+ <enum value="0x90EE" name="GL_DISPATCH_INDIRECT_BUFFER"/>
+ <enum value="0x90EF" name="GL_DISPATCH_INDIRECT_BUFFER_BINDING"/>
+ <enum value="0x90F0" name="GL_COLOR_ATTACHMENT_EXT"/>
+ <enum value="0x90F1" name="GL_MULTIVIEW_EXT"/>
+ <enum value="0x90F2" name="GL_MAX_MULTIVIEW_BUFFERS_EXT"/>
+ <enum value="0x90F3" name="GL_CONTEXT_ROBUST_ACCESS"/>
+ <enum value="0x90F3" name="GL_CONTEXT_ROBUST_ACCESS_EXT"/>
+ <enum value="0x90F3" name="GL_CONTEXT_ROBUST_ACCESS_KHR"/>
+ <unused start="0x90F4" end="0x90FA" vendor="NV"/>
+ <enum value="0x90FB" name="GL_COMPUTE_PROGRAM_NV"/>
+ <enum value="0x90FC" name="GL_COMPUTE_PROGRAM_PARAMETER_BUFFER_NV"/>
+ <unused start="0x90FD" end="0x90FF" vendor="NV"/>
+ </enums>
+
+ <enums namespace="GL" start="0x9100" end="0x912F" vendor="ARB">
+ <enum value="0x9100" name="GL_TEXTURE_2D_MULTISAMPLE"/>
+ <enum value="0x9101" name="GL_PROXY_TEXTURE_2D_MULTISAMPLE"/>
+ <enum value="0x9102" name="GL_TEXTURE_2D_MULTISAMPLE_ARRAY"/>
+ <enum value="0x9102" name="GL_TEXTURE_2D_MULTISAMPLE_ARRAY_OES"/>
+ <enum value="0x9103" name="GL_PROXY_TEXTURE_2D_MULTISAMPLE_ARRAY"/>
+ <enum value="0x9104" name="GL_TEXTURE_BINDING_2D_MULTISAMPLE"/>
+ <enum value="0x9105" name="GL_TEXTURE_BINDING_2D_MULTISAMPLE_ARRAY"/>
+ <enum value="0x9105" name="GL_TEXTURE_BINDING_2D_MULTISAMPLE_ARRAY_OES"/>
+ <enum value="0x9106" name="GL_TEXTURE_SAMPLES"/>
+ <enum value="0x9107" name="GL_TEXTURE_FIXED_SAMPLE_LOCATIONS"/>
+ <enum value="0x9108" name="GL_SAMPLER_2D_MULTISAMPLE"/>
+ <enum value="0x9109" name="GL_INT_SAMPLER_2D_MULTISAMPLE"/>
+ <enum value="0x910A" name="GL_UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE"/>
+ <enum value="0x910B" name="GL_SAMPLER_2D_MULTISAMPLE_ARRAY"/>
+ <enum value="0x910B" name="GL_SAMPLER_2D_MULTISAMPLE_ARRAY_OES"/>
+ <enum value="0x910C" name="GL_INT_SAMPLER_2D_MULTISAMPLE_ARRAY"/>
+ <enum value="0x910C" name="GL_INT_SAMPLER_2D_MULTISAMPLE_ARRAY_OES"/>
+ <enum value="0x910D" name="GL_UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE_ARRAY"/>
+ <enum value="0x910D" name="GL_UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE_ARRAY_OES"/>
+ <enum value="0x910E" name="GL_MAX_COLOR_TEXTURE_SAMPLES"/>
+ <enum value="0x910F" name="GL_MAX_DEPTH_TEXTURE_SAMPLES"/>
+ <enum value="0x9110" name="GL_MAX_INTEGER_SAMPLES"/>
+ <enum value="0x9111" name="GL_MAX_SERVER_WAIT_TIMEOUT"/>
+ <enum value="0x9111" name="GL_MAX_SERVER_WAIT_TIMEOUT_APPLE"/>
+ <enum value="0x9112" name="GL_OBJECT_TYPE"/>
+ <enum value="0x9112" name="GL_OBJECT_TYPE_APPLE"/>
+ <enum value="0x9113" name="GL_SYNC_CONDITION"/>
+ <enum value="0x9113" name="GL_SYNC_CONDITION_APPLE"/>
+ <enum value="0x9114" name="GL_SYNC_STATUS"/>
+ <enum value="0x9114" name="GL_SYNC_STATUS_APPLE"/>
+ <enum value="0x9115" name="GL_SYNC_FLAGS"/>
+ <enum value="0x9115" name="GL_SYNC_FLAGS_APPLE"/>
+ <enum value="0x9116" name="GL_SYNC_FENCE"/>
+ <enum value="0x9116" name="GL_SYNC_FENCE_APPLE"/>
+ <enum value="0x9117" name="GL_SYNC_GPU_COMMANDS_COMPLETE"/>
+ <enum value="0x9117" name="GL_SYNC_GPU_COMMANDS_COMPLETE_APPLE"/>
+ <enum value="0x9118" name="GL_UNSIGNALED"/>
+ <enum value="0x9118" name="GL_UNSIGNALED_APPLE"/>
+ <enum value="0x9119" name="GL_SIGNALED"/>
+ <enum value="0x9119" name="GL_SIGNALED_APPLE"/>
+ <enum value="0x911A" name="GL_ALREADY_SIGNALED"/>
+ <enum value="0x911A" name="GL_ALREADY_SIGNALED_APPLE"/>
+ <enum value="0x911B" name="GL_TIMEOUT_EXPIRED"/>
+ <enum value="0x911B" name="GL_TIMEOUT_EXPIRED_APPLE"/>
+ <enum value="0x911C" name="GL_CONDITION_SATISFIED"/>
+ <enum value="0x911C" name="GL_CONDITION_SATISFIED_APPLE"/>
+ <enum value="0x911D" name="GL_WAIT_FAILED"/>
+ <enum value="0x911D" name="GL_WAIT_FAILED_APPLE"/>
+ <enum value="0x911F" name="GL_BUFFER_ACCESS_FLAGS"/>
+ <enum value="0x9120" name="GL_BUFFER_MAP_LENGTH"/>
+ <enum value="0x9121" name="GL_BUFFER_MAP_OFFSET"/>
+ <enum value="0x9122" name="GL_MAX_VERTEX_OUTPUT_COMPONENTS"/>
+ <enum value="0x9123" name="GL_MAX_GEOMETRY_INPUT_COMPONENTS"/>
+ <enum value="0x9123" name="GL_MAX_GEOMETRY_INPUT_COMPONENTS_EXT"/>
+ <enum value="0x9124" name="GL_MAX_GEOMETRY_OUTPUT_COMPONENTS"/>
+ <enum value="0x9124" name="GL_MAX_GEOMETRY_OUTPUT_COMPONENTS_EXT"/>
+ <enum value="0x9125" name="GL_MAX_FRAGMENT_INPUT_COMPONENTS"/>
+ <enum value="0x9126" name="GL_CONTEXT_PROFILE_MASK"/>
+ <enum value="0x9127" name="GL_UNPACK_COMPRESSED_BLOCK_WIDTH"/>
+ <enum value="0x9128" name="GL_UNPACK_COMPRESSED_BLOCK_HEIGHT"/>
+ <enum value="0x9129" name="GL_UNPACK_COMPRESSED_BLOCK_DEPTH"/>
+ <enum value="0x912A" name="GL_UNPACK_COMPRESSED_BLOCK_SIZE"/>
+ <enum value="0x912B" name="GL_PACK_COMPRESSED_BLOCK_WIDTH"/>
+ <enum value="0x912C" name="GL_PACK_COMPRESSED_BLOCK_HEIGHT"/>
+ <enum value="0x912D" name="GL_PACK_COMPRESSED_BLOCK_DEPTH"/>
+ <enum value="0x912E" name="GL_PACK_COMPRESSED_BLOCK_SIZE"/>
+ <enum value="0x912F" name="GL_TEXTURE_IMMUTABLE_FORMAT"/>
+ <enum value="0x912F" name="GL_TEXTURE_IMMUTABLE_FORMAT_EXT"/>
+ </enums>
+
+ <enums namespace="GL" start="0x9130" end="0x913F" vendor="IMG" comment="Khronos bug 882">
+ <enum value="0x9130" name="GL_SGX_PROGRAM_BINARY_IMG"/>
+ <unused start="0x9131" end="0x9132" vendor="IMG"/>
+ <enum value="0x9133" name="GL_RENDERBUFFER_SAMPLES_IMG"/>
+ <enum value="0x9134" name="GL_FRAMEBUFFER_INCOMPLETE_MULTISAMPLE_IMG"/>
+ <enum value="0x9135" name="GL_MAX_SAMPLES_IMG"/>
+ <enum value="0x9136" name="GL_TEXTURE_SAMPLES_IMG"/>
+ <enum value="0x9137" name="GL_COMPRESSED_RGBA_PVRTC_2BPPV2_IMG"/>
+ <enum value="0x9138" name="GL_COMPRESSED_RGBA_PVRTC_4BPPV2_IMG"/>
+ <unused start="0x9139" end="0x913F" vendor="IMG"/>
+ </enums>
+
+ <enums namespace="GL" start="0x9140" end="0x923F" vendor="AMD" comment="Khronos bugs 5899, 6004">
+ <unused start="0x9140" end="0x9142" vendor="AMD"/>
+ <enum value="0x9143" name="GL_MAX_DEBUG_MESSAGE_LENGTH"/>
+ <enum value="0x9143" name="GL_MAX_DEBUG_MESSAGE_LENGTH_AMD"/>
+ <enum value="0x9143" name="GL_MAX_DEBUG_MESSAGE_LENGTH_ARB"/>
+ <enum value="0x9143" name="GL_MAX_DEBUG_MESSAGE_LENGTH_KHR"/>
+ <enum value="0x9144" name="GL_MAX_DEBUG_LOGGED_MESSAGES"/>
+ <enum value="0x9144" name="GL_MAX_DEBUG_LOGGED_MESSAGES_AMD"/>
+ <enum value="0x9144" name="GL_MAX_DEBUG_LOGGED_MESSAGES_ARB"/>
+ <enum value="0x9144" name="GL_MAX_DEBUG_LOGGED_MESSAGES_KHR"/>
+ <enum value="0x9145" name="GL_DEBUG_LOGGED_MESSAGES"/>
+ <enum value="0x9145" name="GL_DEBUG_LOGGED_MESSAGES_AMD"/>
+ <enum value="0x9145" name="GL_DEBUG_LOGGED_MESSAGES_ARB"/>
+ <enum value="0x9145" name="GL_DEBUG_LOGGED_MESSAGES_KHR"/>
+ <enum value="0x9146" name="GL_DEBUG_SEVERITY_HIGH"/>
+ <enum value="0x9146" name="GL_DEBUG_SEVERITY_HIGH_AMD"/>
+ <enum value="0x9146" name="GL_DEBUG_SEVERITY_HIGH_ARB"/>
+ <enum value="0x9146" name="GL_DEBUG_SEVERITY_HIGH_KHR"/>
+ <enum value="0x9147" name="GL_DEBUG_SEVERITY_MEDIUM"/>
+ <enum value="0x9147" name="GL_DEBUG_SEVERITY_MEDIUM_AMD"/>
+ <enum value="0x9147" name="GL_DEBUG_SEVERITY_MEDIUM_ARB"/>
+ <enum value="0x9147" name="GL_DEBUG_SEVERITY_MEDIUM_KHR"/>
+ <enum value="0x9148" name="GL_DEBUG_SEVERITY_LOW"/>
+ <enum value="0x9148" name="GL_DEBUG_SEVERITY_LOW_AMD"/>
+ <enum value="0x9148" name="GL_DEBUG_SEVERITY_LOW_ARB"/>
+ <enum value="0x9148" name="GL_DEBUG_SEVERITY_LOW_KHR"/>
+ <enum value="0x9149" name="GL_DEBUG_CATEGORY_API_ERROR_AMD"/>
+ <enum value="0x914A" name="GL_DEBUG_CATEGORY_WINDOW_SYSTEM_AMD"/>
+ <enum value="0x914B" name="GL_DEBUG_CATEGORY_DEPRECATION_AMD"/>
+ <enum value="0x914C" name="GL_DEBUG_CATEGORY_UNDEFINED_BEHAVIOR_AMD"/>
+ <enum value="0x914D" name="GL_DEBUG_CATEGORY_PERFORMANCE_AMD"/>
+ <enum value="0x914E" name="GL_DEBUG_CATEGORY_SHADER_COMPILER_AMD"/>
+ <enum value="0x914F" name="GL_DEBUG_CATEGORY_APPLICATION_AMD"/>
+ <enum value="0x9150" name="GL_DEBUG_CATEGORY_OTHER_AMD"/>
+ <enum value="0x9151" name="GL_BUFFER_OBJECT_EXT"/>
+ <enum value="0x9151" name="GL_DATA_BUFFER_AMD"/>
+ <enum value="0x9152" name="GL_PERFORMANCE_MONITOR_AMD"/>
+ <enum value="0x9153" name="GL_QUERY_OBJECT_AMD"/>
+ <enum value="0x9153" name="GL_QUERY_OBJECT_EXT"/>
+ <enum value="0x9154" name="GL_VERTEX_ARRAY_OBJECT_AMD"/>
+ <enum value="0x9154" name="GL_VERTEX_ARRAY_OBJECT_EXT"/>
+ <enum value="0x9155" name="GL_SAMPLER_OBJECT_AMD"/>
+ <unused start="0x9156" end="0x915F" vendor="AMD"/>
+ <enum value="0x9160" name="GL_EXTERNAL_VIRTUAL_MEMORY_BUFFER_AMD"/>
+ <unused start="0x9161" vendor="AMD"/>
+ <enum value="0x9192" name="GL_QUERY_BUFFER"/>
+ <enum value="0x9192" name="GL_QUERY_BUFFER_AMD"/>
+ <enum value="0x9193" name="GL_QUERY_BUFFER_BINDING"/>
+ <enum value="0x9193" name="GL_QUERY_BUFFER_BINDING_AMD"/>
+ <enum value="0x9194" name="GL_QUERY_RESULT_NO_WAIT"/>
+ <enum value="0x9194" name="GL_QUERY_RESULT_NO_WAIT_AMD"/>
+ <enum value="0x9195" name="GL_VIRTUAL_PAGE_SIZE_X_ARB"/>
+ <enum value="0x9195" name="GL_VIRTUAL_PAGE_SIZE_X_AMD"/>
+ <enum value="0x9196" name="GL_VIRTUAL_PAGE_SIZE_Y_ARB"/>
+ <enum value="0x9196" name="GL_VIRTUAL_PAGE_SIZE_Y_AMD"/>
+ <enum value="0x9197" name="GL_VIRTUAL_PAGE_SIZE_Z_ARB"/>
+ <enum value="0x9197" name="GL_VIRTUAL_PAGE_SIZE_Z_AMD"/>
+ <enum value="0x9198" name="GL_MAX_SPARSE_TEXTURE_SIZE_ARB"/>
+ <enum value="0x9198" name="GL_MAX_SPARSE_TEXTURE_SIZE_AMD"/>
+ <enum value="0x9199" name="GL_MAX_SPARSE_3D_TEXTURE_SIZE_ARB"/>
+ <enum value="0x9199" name="GL_MAX_SPARSE_3D_TEXTURE_SIZE_AMD"/>
+ <enum value="0x919A" name="GL_MAX_SPARSE_ARRAY_TEXTURE_LAYERS_ARB"/>
+ <enum value="0x919A" name="GL_MAX_SPARSE_ARRAY_TEXTURE_LAYERS"/>
+ <enum value="0x919B" name="GL_MIN_SPARSE_LEVEL_ARB"/>
+ <enum value="0x919B" name="GL_MIN_SPARSE_LEVEL_AMD"/>
+ <enum value="0x919C" name="GL_MIN_LOD_WARNING_AMD"/>
+ <enum value="0x919D" name="GL_TEXTURE_BUFFER_OFFSET"/>
+ <enum value="0x919D" name="GL_TEXTURE_BUFFER_OFFSET_EXT"/>
+ <enum value="0x919E" name="GL_TEXTURE_BUFFER_SIZE"/>
+ <enum value="0x919E" name="GL_TEXTURE_BUFFER_SIZE_EXT"/>
+ <enum value="0x919F" name="GL_TEXTURE_BUFFER_OFFSET_ALIGNMENT"/>
+ <enum value="0x919F" name="GL_TEXTURE_BUFFER_OFFSET_ALIGNMENT_EXT"/>
+ <enum value="0x91A0" name="GL_STREAM_RASTERIZATION_AMD"/>
+ <unused start="0x91A1" end="0x91A3" vendor="AMD"/>
+ <enum value="0x91A4" name="GL_VERTEX_ELEMENT_SWIZZLE_AMD"/>
+ <enum value="0x91A5" name="GL_VERTEX_ID_SWIZZLE_AMD"/>
+ <enum value="0x91A6" name="GL_TEXTURE_SPARSE_ARB"/>
+ <enum value="0x91A7" name="GL_VIRTUAL_PAGE_SIZE_INDEX_ARB"/>
+ <enum value="0x91A8" name="GL_NUM_VIRTUAL_PAGE_SIZES_ARB"/>
+ <enum value="0x91A9" name="GL_SPARSE_TEXTURE_FULL_ARRAY_CUBE_MIPMAPS_ARB"/>
+ <unused start="0x91AA" end="0x91B8" vendor="AMD"/>
+ <enum value="0x91B9" name="GL_COMPUTE_SHADER"/>
+ <unused start="0x91BA" vendor="AMD"/>
+ <enum value="0x91BB" name="GL_MAX_COMPUTE_UNIFORM_BLOCKS"/>
+ <enum value="0x91BC" name="GL_MAX_COMPUTE_TEXTURE_IMAGE_UNITS"/>
+ <enum value="0x91BD" name="GL_MAX_COMPUTE_IMAGE_UNIFORMS"/>
+ <enum value="0x91BE" name="GL_MAX_COMPUTE_WORK_GROUP_COUNT"/>
+ <enum value="0x91BF" name="GL_MAX_COMPUTE_WORK_GROUP_SIZE"/>
+ <enum value="0x91BF" name="GL_MAX_COMPUTE_FIXED_GROUP_SIZE_ARB" alias="GL_MAX_COMPUTE_WORK_GROUP_SIZE"/>
+ <unused start="0x91C0" end="0x923F" vendor="AMD"/>
+ </enums>
+
+ <enums namespace="GL" start="0x9240" end="0x924F" vendor="WEBGL" comment="Khronos bug 6473,6884">
+ <enum value="0x9240" name="GL_UNPACK_FLIP_Y_WEBGL"/>
+ <enum value="0x9241" name="GL_UNPACK_PREMULTIPLY_ALPHA_WEBGL"/>
+ <enum value="0x9242" name="GL_CONTEXT_LOST_WEBGL"/>
+ <enum value="0x9243" name="GL_UNPACK_COLORSPACE_CONVERSION_WEBGL"/>
+ <enum value="0x9244" name="GL_BROWSER_DEFAULT_WEBGL"/>
+ <unused start="0x9245" end="0x924F" vendor="WEBGL"/>
+ </enums>
+
+ <enums namespace="GL" start="0x9250" end="0x925F" vendor="DMP" comment="For Eisaku Ohbuchi via email">
+ <enum value="0x9250" name="GL_SHADER_BINARY_DMP"/>
+ <unused start="0x9251" end="0x925F" vendor="DMP"/>
+ </enums>
+
+ <enums namespace="GL" start="0x9260" end="0x926F" vendor="FJ" comment="Khronos bug 7486">
+ <enum value="0x9260" name="GL_GCCSO_SHADER_BINARY_FJ"/>
+ <unused start="0x9261" end="0x926F" vendor="FJ"/>
+ </enums>
+
+ <enums namespace="GL" start="0x9270" end="0x927F" vendor="OES" comment="Khronos bug 7625">
+ <enum value="0x9270" name="GL_COMPRESSED_R11_EAC"/>
+ <enum value="0x9270" name="GL_COMPRESSED_R11_EAC_OES"/>
+ <enum value="0x9271" name="GL_COMPRESSED_SIGNED_R11_EAC"/>
+ <enum value="0x9271" name="GL_COMPRESSED_SIGNED_R11_EAC_OES"/>
+ <enum value="0x9272" name="GL_COMPRESSED_RG11_EAC"/>
+ <enum value="0x9272" name="GL_COMPRESSED_RG11_EAC_OES"/>
+ <enum value="0x9273" name="GL_COMPRESSED_SIGNED_RG11_EAC"/>
+ <enum value="0x9273" name="GL_COMPRESSED_SIGNED_RG11_EAC_OES"/>
+ <enum value="0x9274" name="GL_COMPRESSED_RGB8_ETC2"/>
+ <enum value="0x9274" name="GL_COMPRESSED_RGB8_ETC2_OES"/>
+ <enum value="0x9275" name="GL_COMPRESSED_SRGB8_ETC2"/>
+ <enum value="0x9275" name="GL_COMPRESSED_SRGB8_ETC2_OES"/>
+ <enum value="0x9276" name="GL_COMPRESSED_RGB8_PUNCHTHROUGH_ALPHA1_ETC2"/>
+ <enum value="0x9276" name="GL_COMPRESSED_RGB8_PUNCHTHROUGH_ALPHA1_ETC2_OES"/>
+ <enum value="0x9277" name="GL_COMPRESSED_SRGB8_PUNCHTHROUGH_ALPHA1_ETC2"/>
+ <enum value="0x9277" name="GL_COMPRESSED_SRGB8_PUNCHTHROUGH_ALPHA1_ETC2_OES"/>
+ <enum value="0x9278" name="GL_COMPRESSED_RGBA8_ETC2_EAC"/>
+ <enum value="0x9278" name="GL_COMPRESSED_RGBA8_ETC2_EAC_OES"/>
+ <enum value="0x9279" name="GL_COMPRESSED_SRGB8_ALPHA8_ETC2_EAC"/>
+ <enum value="0x9279" name="GL_COMPRESSED_SRGB8_ALPHA8_ETC2_EAC_OES"/>
+ <unused start="0x927A" end="0x927F" vendor="OES"/>
+ </enums>
+
+ <enums namespace="GL" start="0x9280" end="0x937F" vendor="NV" comment="Khronos bug 7658">
+ <enum value="0x9280" name="GL_BLEND_PREMULTIPLIED_SRC_NV"/>
+ <enum value="0x9281" name="GL_BLEND_OVERLAP_NV"/>
+ <enum value="0x9282" name="GL_UNCORRELATED_NV"/>
+ <enum value="0x9283" name="GL_DISJOINT_NV"/>
+ <enum value="0x9284" name="GL_CONJOINT_NV"/>
+ <enum value="0x9285" name="GL_BLEND_ADVANCED_COHERENT_KHR"/>
+ <enum value="0x9285" name="GL_BLEND_ADVANCED_COHERENT_NV"/>
+ <enum value="0x9286" name="GL_SRC_NV"/>
+ <enum value="0x9287" name="GL_DST_NV"/>
+ <enum value="0x9288" name="GL_SRC_OVER_NV"/>
+ <enum value="0x9289" name="GL_DST_OVER_NV"/>
+ <enum value="0x928A" name="GL_SRC_IN_NV"/>
+ <enum value="0x928B" name="GL_DST_IN_NV"/>
+ <enum value="0x928C" name="GL_SRC_OUT_NV"/>
+ <enum value="0x928D" name="GL_DST_OUT_NV"/>
+ <enum value="0x928E" name="GL_SRC_ATOP_NV"/>
+ <enum value="0x928F" name="GL_DST_ATOP_NV"/>
+ <unused start="0x9290" vendor="NV"/>
+ <enum value="0x9291" name="GL_PLUS_NV"/>
+ <enum value="0x9292" name="GL_PLUS_DARKER_NV"/>
+ <unused start="0x9293" vendor="NV"/>
+ <enum value="0x9294" name="GL_MULTIPLY_KHR"/>
+ <enum value="0x9294" name="GL_MULTIPLY_NV"/>
+ <enum value="0x9295" name="GL_SCREEN_KHR"/>
+ <enum value="0x9295" name="GL_SCREEN_NV"/>
+ <enum value="0x9296" name="GL_OVERLAY_KHR"/>
+ <enum value="0x9296" name="GL_OVERLAY_NV"/>
+ <enum value="0x9297" name="GL_DARKEN_KHR"/>
+ <enum value="0x9297" name="GL_DARKEN_NV"/>
+ <enum value="0x9298" name="GL_LIGHTEN_KHR"/>
+ <enum value="0x9298" name="GL_LIGHTEN_NV"/>
+ <enum value="0x9299" name="GL_COLORDODGE_KHR"/>
+ <enum value="0x9299" name="GL_COLORDODGE_NV"/>
+ <enum value="0x929A" name="GL_COLORBURN_KHR"/>
+ <enum value="0x929A" name="GL_COLORBURN_NV"/>
+ <enum value="0x929B" name="GL_HARDLIGHT_KHR"/>
+ <enum value="0x929B" name="GL_HARDLIGHT_NV"/>
+ <enum value="0x929C" name="GL_SOFTLIGHT_KHR"/>
+ <enum value="0x929C" name="GL_SOFTLIGHT_NV"/>
+ <unused start="0x929D" vendor="NV"/>
+ <enum value="0x929E" name="GL_DIFFERENCE_KHR"/>
+ <enum value="0x929E" name="GL_DIFFERENCE_NV"/>
+ <enum value="0x929F" name="GL_MINUS_NV"/>
+ <enum value="0x92A0" name="GL_EXCLUSION_KHR"/>
+ <enum value="0x92A0" name="GL_EXCLUSION_NV"/>
+ <enum value="0x92A1" name="GL_CONTRAST_NV"/>
+ <unused start="0x92A2" vendor="NV"/>
+ <enum value="0x92A3" name="GL_INVERT_RGB_NV"/>
+ <enum value="0x92A4" name="GL_LINEARDODGE_NV"/>
+ <enum value="0x92A5" name="GL_LINEARBURN_NV"/>
+ <enum value="0x92A6" name="GL_VIVIDLIGHT_NV"/>
+ <enum value="0x92A7" name="GL_LINEARLIGHT_NV"/>
+ <enum value="0x92A8" name="GL_PINLIGHT_NV"/>
+ <enum value="0x92A9" name="GL_HARDMIX_NV"/>
+ <unused start="0x92AA" end="0x92AC" vendor="NV"/>
+ <enum value="0x92AD" name="GL_HSL_HUE_KHR"/>
+ <enum value="0x92AD" name="GL_HSL_HUE_NV"/>
+ <enum value="0x92AE" name="GL_HSL_SATURATION_KHR"/>
+ <enum value="0x92AE" name="GL_HSL_SATURATION_NV"/>
+ <enum value="0x92AF" name="GL_HSL_COLOR_KHR"/>
+ <enum value="0x92AF" name="GL_HSL_COLOR_NV"/>
+ <enum value="0x92B0" name="GL_HSL_LUMINOSITY_KHR"/>
+ <enum value="0x92B0" name="GL_HSL_LUMINOSITY_NV"/>
+ <enum value="0x92B1" name="GL_PLUS_CLAMPED_NV"/>
+ <enum value="0x92B2" name="GL_PLUS_CLAMPED_ALPHA_NV"/>
+ <enum value="0x92B3" name="GL_MINUS_CLAMPED_NV"/>
+ <enum value="0x92B4" name="GL_INVERT_OVG_NV"/>
+ <unused start="0x92B5" end="0x92BD" vendor="NV"/>
+ <enum value="0x92BE" name="GL_PRIMITIVE_BOUNDING_BOX_EXT"/>
+ <unused start="0x92BF" vendor="NV"/>
+ <enum value="0x92C0" name="GL_ATOMIC_COUNTER_BUFFER"/>
+ <enum value="0x92C1" name="GL_ATOMIC_COUNTER_BUFFER_BINDING"/>
+ <enum value="0x92C2" name="GL_ATOMIC_COUNTER_BUFFER_START"/>
+ <enum value="0x92C3" name="GL_ATOMIC_COUNTER_BUFFER_SIZE"/>
+ <enum value="0x92C4" name="GL_ATOMIC_COUNTER_BUFFER_DATA_SIZE"/>
+ <enum value="0x92C5" name="GL_ATOMIC_COUNTER_BUFFER_ACTIVE_ATOMIC_COUNTERS"/>
+ <enum value="0x92C6" name="GL_ATOMIC_COUNTER_BUFFER_ACTIVE_ATOMIC_COUNTER_INDICES"/>
+ <enum value="0x92C7" name="GL_ATOMIC_COUNTER_BUFFER_REFERENCED_BY_VERTEX_SHADER"/>
+ <enum value="0x92C8" name="GL_ATOMIC_COUNTER_BUFFER_REFERENCED_BY_TESS_CONTROL_SHADER"/>
+ <enum value="0x92C9" name="GL_ATOMIC_COUNTER_BUFFER_REFERENCED_BY_TESS_EVALUATION_SHADER"/>
+ <enum value="0x92CA" name="GL_ATOMIC_COUNTER_BUFFER_REFERENCED_BY_GEOMETRY_SHADER"/>
+ <enum value="0x92CB" name="GL_ATOMIC_COUNTER_BUFFER_REFERENCED_BY_FRAGMENT_SHADER"/>
+ <enum value="0x92CC" name="GL_MAX_VERTEX_ATOMIC_COUNTER_BUFFERS"/>
+ <enum value="0x92CD" name="GL_MAX_TESS_CONTROL_ATOMIC_COUNTER_BUFFERS"/>
+ <enum value="0x92CD" name="GL_MAX_TESS_CONTROL_ATOMIC_COUNTER_BUFFERS_EXT"/>
+ <enum value="0x92CE" name="GL_MAX_TESS_EVALUATION_ATOMIC_COUNTER_BUFFERS"/>
+ <enum value="0x92CE" name="GL_MAX_TESS_EVALUATION_ATOMIC_COUNTER_BUFFERS_EXT"/>
+ <enum value="0x92CF" name="GL_MAX_GEOMETRY_ATOMIC_COUNTER_BUFFERS"/>
+ <enum value="0x92CF" name="GL_MAX_GEOMETRY_ATOMIC_COUNTER_BUFFERS_EXT"/>
+ <enum value="0x92D0" name="GL_MAX_FRAGMENT_ATOMIC_COUNTER_BUFFERS"/>
+ <enum value="0x92D1" name="GL_MAX_COMBINED_ATOMIC_COUNTER_BUFFERS"/>
+ <enum value="0x92D2" name="GL_MAX_VERTEX_ATOMIC_COUNTERS"/>
+ <enum value="0x92D3" name="GL_MAX_TESS_CONTROL_ATOMIC_COUNTERS"/>
+ <enum value="0x92D3" name="GL_MAX_TESS_CONTROL_ATOMIC_COUNTERS_EXT"/>
+ <enum value="0x92D4" name="GL_MAX_TESS_EVALUATION_ATOMIC_COUNTERS"/>
+ <enum value="0x92D4" name="GL_MAX_TESS_EVALUATION_ATOMIC_COUNTERS_EXT"/>
+ <enum value="0x92D5" name="GL_MAX_GEOMETRY_ATOMIC_COUNTERS"/>
+ <enum value="0x92D5" name="GL_MAX_GEOMETRY_ATOMIC_COUNTERS_EXT"/>
+ <enum value="0x92D6" name="GL_MAX_FRAGMENT_ATOMIC_COUNTERS"/>
+ <enum value="0x92D7" name="GL_MAX_COMBINED_ATOMIC_COUNTERS"/>
+ <enum value="0x92D8" name="GL_MAX_ATOMIC_COUNTER_BUFFER_SIZE"/>
+ <enum value="0x92D9" name="GL_ACTIVE_ATOMIC_COUNTER_BUFFERS"/>
+ <enum value="0x92DA" name="GL_UNIFORM_ATOMIC_COUNTER_BUFFER_INDEX"/>
+ <enum value="0x92DB" name="GL_UNSIGNED_INT_ATOMIC_COUNTER"/>
+ <enum value="0x92DC" name="GL_MAX_ATOMIC_COUNTER_BUFFER_BINDINGS"/>
+ <unused start="0x92DC" end="0x92DF" vendor="NV"/>
+ <enum value="0x92E0" name="GL_DEBUG_OUTPUT"/>
+ <enum value="0x92E0" name="GL_DEBUG_OUTPUT_KHR"/>
+ <enum value="0x92E1" name="GL_UNIFORM"/>
+ <enum value="0x92E2" name="GL_UNIFORM_BLOCK"/>
+ <enum value="0x92E3" name="GL_PROGRAM_INPUT"/>
+ <enum value="0x92E4" name="GL_PROGRAM_OUTPUT"/>
+ <enum value="0x92E5" name="GL_BUFFER_VARIABLE"/>
+ <enum value="0x92E6" name="GL_SHADER_STORAGE_BLOCK"/>
+ <enum value="0x92E7" name="GL_IS_PER_PATCH"/>
+ <enum value="0x92E7" name="GL_IS_PER_PATCH_EXT"/>
+ <enum value="0x92E8" name="GL_VERTEX_SUBROUTINE"/>
+ <enum value="0x92E9" name="GL_TESS_CONTROL_SUBROUTINE"/>
+ <enum value="0x92EA" name="GL_TESS_EVALUATION_SUBROUTINE"/>
+ <enum value="0x92EB" name="GL_GEOMETRY_SUBROUTINE"/>
+ <enum value="0x92EC" name="GL_FRAGMENT_SUBROUTINE"/>
+ <enum value="0x92ED" name="GL_COMPUTE_SUBROUTINE"/>
+ <enum value="0x92EE" name="GL_VERTEX_SUBROUTINE_UNIFORM"/>
+ <enum value="0x92EF" name="GL_TESS_CONTROL_SUBROUTINE_UNIFORM"/>
+ <enum value="0x92F0" name="GL_TESS_EVALUATION_SUBROUTINE_UNIFORM"/>
+ <enum value="0x92F1" name="GL_GEOMETRY_SUBROUTINE_UNIFORM"/>
+ <enum value="0x92F2" name="GL_FRAGMENT_SUBROUTINE_UNIFORM"/>
+ <enum value="0x92F3" name="GL_COMPUTE_SUBROUTINE_UNIFORM"/>
+ <enum value="0x92F4" name="GL_TRANSFORM_FEEDBACK_VARYING"/>
+ <enum value="0x92F5" name="GL_ACTIVE_RESOURCES"/>
+ <enum value="0x92F6" name="GL_MAX_NAME_LENGTH"/>
+ <enum value="0x92F7" name="GL_MAX_NUM_ACTIVE_VARIABLES"/>
+ <enum value="0x92F8" name="GL_MAX_NUM_COMPATIBLE_SUBROUTINES"/>
+ <enum value="0x92F9" name="GL_NAME_LENGTH"/>
+ <enum value="0x92FA" name="GL_TYPE"/>
+ <enum value="0x92FB" name="GL_ARRAY_SIZE"/>
+ <enum value="0x92FC" name="GL_OFFSET"/>
+ <enum value="0x92FD" name="GL_BLOCK_INDEX"/>
+ <enum value="0x92FE" name="GL_ARRAY_STRIDE"/>
+ <enum value="0x92FF" name="GL_MATRIX_STRIDE"/>
+ <enum value="0x9300" name="GL_IS_ROW_MAJOR"/>
+ <enum value="0x9301" name="GL_ATOMIC_COUNTER_BUFFER_INDEX"/>
+ <enum value="0x9302" name="GL_BUFFER_BINDING"/>
+ <enum value="0x9303" name="GL_BUFFER_DATA_SIZE"/>
+ <enum value="0x9304" name="GL_NUM_ACTIVE_VARIABLES"/>
+ <enum value="0x9305" name="GL_ACTIVE_VARIABLES"/>
+ <enum value="0x9306" name="GL_REFERENCED_BY_VERTEX_SHADER"/>
+ <enum value="0x9307" name="GL_REFERENCED_BY_TESS_CONTROL_SHADER"/>
+ <enum value="0x9307" name="GL_REFERENCED_BY_TESS_CONTROL_SHADER_EXT"/>
+ <enum value="0x9308" name="GL_REFERENCED_BY_TESS_EVALUATION_SHADER"/>
+ <enum value="0x9308" name="GL_REFERENCED_BY_TESS_EVALUATION_SHADER_EXT"/>
+ <enum value="0x9309" name="GL_REFERENCED_BY_GEOMETRY_SHADER"/>
+ <enum value="0x9309" name="GL_REFERENCED_BY_GEOMETRY_SHADER_EXT"/>
+ <enum value="0x930A" name="GL_REFERENCED_BY_FRAGMENT_SHADER"/>
+ <enum value="0x930B" name="GL_REFERENCED_BY_COMPUTE_SHADER"/>
+ <enum value="0x930C" name="GL_TOP_LEVEL_ARRAY_SIZE"/>
+ <enum value="0x930D" name="GL_TOP_LEVEL_ARRAY_STRIDE"/>
+ <enum value="0x930E" name="GL_LOCATION"/>
+ <enum value="0x930F" name="GL_LOCATION_INDEX"/>
+ <enum value="0x9310" name="GL_FRAMEBUFFER_DEFAULT_WIDTH"/>
+ <enum value="0x9311" name="GL_FRAMEBUFFER_DEFAULT_HEIGHT"/>
+ <enum value="0x9312" name="GL_FRAMEBUFFER_DEFAULT_LAYERS"/>
+ <enum value="0x9312" name="GL_FRAMEBUFFER_DEFAULT_LAYERS_EXT"/>
+ <enum value="0x9313" name="GL_FRAMEBUFFER_DEFAULT_SAMPLES"/>
+ <enum value="0x9314" name="GL_FRAMEBUFFER_DEFAULT_FIXED_SAMPLE_LOCATIONS"/>
+ <enum value="0x9315" name="GL_MAX_FRAMEBUFFER_WIDTH"/>
+ <enum value="0x9316" name="GL_MAX_FRAMEBUFFER_HEIGHT"/>
+ <enum value="0x9317" name="GL_MAX_FRAMEBUFFER_LAYERS"/>
+ <enum value="0x9317" name="GL_MAX_FRAMEBUFFER_LAYERS_EXT"/>
+ <enum value="0x9318" name="GL_MAX_FRAMEBUFFER_SAMPLES"/>
+ <unused start="0x9319" end="0x9338" vendor="NV"/>
+ <enum value="0x9339" name="GL_WARP_SIZE_NV"/>
+ <enum value="0x933A" name="GL_WARPS_PER_SM_NV"/>
+ <enum value="0x933B" name="GL_SM_COUNT_NV"/>
+ <unused start="0x933C" end="0x9343" vendor="NV"/>
+ <enum value="0x9344" name="GL_MAX_COMPUTE_VARIABLE_GROUP_INVOCATIONS_ARB"/>
+ <enum value="0x9345" name="GL_MAX_COMPUTE_VARIABLE_GROUP_SIZE_ARB"/>
+ <unused start="0x9346" end="0x9349" vendor="NV"/>
+ <enum value="0x934A" name="GL_LOCATION_COMPONENT"/>
+ <enum value="0x934B" name="GL_TRANSFORM_FEEDBACK_BUFFER_INDEX"/>
+ <enum value="0x934C" name="GL_TRANSFORM_FEEDBACK_BUFFER_STRIDE"/>
+ <unused start="0x934D" end="0x935B" vendor="NV"/>
+ <enum value="0x935C" name="GL_CLIP_ORIGIN"/>
+ <enum value="0x935D" name="GL_CLIP_DEPTH_MODE"/>
+ <enum value="0x935E" name="GL_NEGATIVE_ONE_TO_ONE"/>
+ <enum value="0x935F" name="GL_ZERO_TO_ONE"/>
+ <unused start="0x9360" end="0x9364" vendor="NV"/>
+ <enum value="0x9365" name="GL_CLEAR_TEXTURE"/>
+ <unused start="0x9366" end="0x9367" vendor="NV"/>
+ <enum value="0x9368" name="GL_FONT_GLYPHS_AVAILABLE_NV"/>
+ <enum value="0x9369" name="GL_FONT_TARGET_UNAVAILABLE_NV"/>
+ <enum value="0x936A" name="GL_FONT_UNAVAILABLE_NV"/>
+ <enum value="0x936B" name="GL_FONT_UNINTELLIGIBLE_NV"/>
+ <enum value="0x936C" name="GL_STANDARD_FONT_FORMAT_NV"/>
+ <enum value="0x936D" name="GL_FRAGMENT_INPUT_NV"/>
+ <unused start="0x936E" end="0x937F" vendor="NV"/>
+ </enums>
+
+ <enums namespace="GL" start="0x9380" end="0x939F" vendor="ARB">
+ <enum value="0x9380" name="GL_NUM_SAMPLE_COUNTS"/>
+ <unused start="0x9381" end="0x939F" vendor="ARB"/>
+ </enums>
+
+ <enums namespace="GL" start="0x93A0" end="0x93AF" vendor="ANGLE" comment="Khronos bug 8100">
+ <enum value="0x93A0" name="GL_TRANSLATED_SHADER_SOURCE_LENGTH_ANGLE"/>
+ <enum value="0x93A1" name="GL_BGRA8_EXT"/>
+ <enum value="0x93A2" name="GL_TEXTURE_USAGE_ANGLE"/>
+ <enum value="0x93A3" name="GL_FRAMEBUFFER_ATTACHMENT_ANGLE"/>
+ <enum value="0x93A4" name="GL_PACK_REVERSE_ROW_ORDER_ANGLE"/>
+ <unused start="0x93A5" vendor="ANGLE"/>
+ <enum value="0x93A6" name="GL_PROGRAM_BINARY_ANGLE"/>
+ <unused start="0x93A7" end="0x93AF" vendor="ANGLE"/>
+ </enums>
+
+ <enums namespace="GL" start="0x93B0" end="0x93EF" vendor="OES" comment="Khronos bug 8853">
+ <enum value="0x93B0" name="GL_COMPRESSED_RGBA_ASTC_4x4_KHR"/>
+ <enum value="0x93B1" name="GL_COMPRESSED_RGBA_ASTC_5x4_KHR"/>
+ <enum value="0x93B2" name="GL_COMPRESSED_RGBA_ASTC_5x5_KHR"/>
+ <enum value="0x93B3" name="GL_COMPRESSED_RGBA_ASTC_6x5_KHR"/>
+ <enum value="0x93B4" name="GL_COMPRESSED_RGBA_ASTC_6x6_KHR"/>
+ <enum value="0x93B5" name="GL_COMPRESSED_RGBA_ASTC_8x5_KHR"/>
+ <enum value="0x93B6" name="GL_COMPRESSED_RGBA_ASTC_8x6_KHR"/>
+ <enum value="0x93B7" name="GL_COMPRESSED_RGBA_ASTC_8x8_KHR"/>
+ <enum value="0x93B8" name="GL_COMPRESSED_RGBA_ASTC_10x5_KHR"/>
+ <enum value="0x93B9" name="GL_COMPRESSED_RGBA_ASTC_10x6_KHR"/>
+ <enum value="0x93BA" name="GL_COMPRESSED_RGBA_ASTC_10x8_KHR"/>
+ <enum value="0x93BB" name="GL_COMPRESSED_RGBA_ASTC_10x10_KHR"/>
+ <enum value="0x93BC" name="GL_COMPRESSED_RGBA_ASTC_12x10_KHR"/>
+ <enum value="0x93BD" name="GL_COMPRESSED_RGBA_ASTC_12x12_KHR"/>
+ <unused start="0x93BE" end="0x93BF" vendor="OES"/>
+ <enum value="0x93C0" name="GL_COMPRESSED_RGBA_ASTC_3x3x3_OES"/>
+ <enum value="0x93C1" name="GL_COMPRESSED_RGBA_ASTC_4x3x3_OES"/>
+ <enum value="0x93C2" name="GL_COMPRESSED_RGBA_ASTC_4x4x3_OES"/>
+ <enum value="0x93C3" name="GL_COMPRESSED_RGBA_ASTC_4x4x4_OES"/>
+ <enum value="0x93C4" name="GL_COMPRESSED_RGBA_ASTC_5x4x4_OES"/>
+ <enum value="0x93C5" name="GL_COMPRESSED_RGBA_ASTC_5x5x4_OES"/>
+ <enum value="0x93C6" name="GL_COMPRESSED_RGBA_ASTC_5x5x5_OES"/>
+ <enum value="0x93C7" name="GL_COMPRESSED_RGBA_ASTC_6x5x5_OES"/>
+ <enum value="0x93C8" name="GL_COMPRESSED_RGBA_ASTC_6x6x5_OES"/>
+ <enum value="0x93C9" name="GL_COMPRESSED_RGBA_ASTC_6x6x6_OES"/>
+ <unused start="0x93CA" end="0x93CF" vendor="OES"/>
+ <enum value="0x93D0" name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_4x4_KHR"/>
+ <enum value="0x93D1" name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_5x4_KHR"/>
+ <enum value="0x93D2" name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_5x5_KHR"/>
+ <enum value="0x93D3" name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_6x5_KHR"/>
+ <enum value="0x93D4" name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_6x6_KHR"/>
+ <enum value="0x93D5" name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_8x5_KHR"/>
+ <enum value="0x93D6" name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_8x6_KHR"/>
+ <enum value="0x93D7" name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_8x8_KHR"/>
+ <enum value="0x93D8" name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_10x5_KHR"/>
+ <enum value="0x93D9" name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_10x6_KHR"/>
+ <enum value="0x93DA" name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_10x8_KHR"/>
+ <enum value="0x93DB" name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_10x10_KHR"/>
+ <enum value="0x93DC" name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_12x10_KHR"/>
+ <enum value="0x93DD" name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_12x12_KHR"/>
+ <unused start="0x93DE" end="0x93DF" vendor="OES"/>
+ <enum value="0x93E0" name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_3x3x3_OES"/>
+ <enum value="0x93E1" name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_4x3x3_OES"/>
+ <enum value="0x93E2" name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_4x4x3_OES"/>
+ <enum value="0x93E3" name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_4x4x4_OES"/>
+ <enum value="0x93E4" name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_5x4x4_OES"/>
+ <enum value="0x93E5" name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_5x5x4_OES"/>
+ <enum value="0x93E6" name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_5x5x5_OES"/>
+ <enum value="0x93E7" name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_6x5x5_OES"/>
+ <enum value="0x93E8" name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_6x6x5_OES"/>
+ <enum value="0x93E9" name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_6x6x6_OES"/>
+ <unused start="0x93EA" end="0x93EF" vendor="OES"/>
+ </enums>
+
+ <enums namespace="GL" start="0x93F0" end="0x94EF" vendor="APPLE" comment="Khronos bug 10233">
+ <enum value="0x93F0" name="GL_COMPRESSED_SRGB_ALPHA_PVRTC_2BPPV2_IMG"/>
+ <enum value="0x93F1" name="GL_COMPRESSED_SRGB_ALPHA_PVRTC_4BPPV2_IMG"/>
+ <unused start="0x93F2" end="0x94EF" vendor="APPLE"/>
+ </enums>
+
+ <enums namespace="GL" start="0x94F0" end="0x950F" vendor="INTEL" comment="Khronos bug 11345">
+ <enum value="0x94F0" name="GL_PERFQUERY_COUNTER_EVENT_INTEL"/>
+ <enum value="0x94F1" name="GL_PERFQUERY_COUNTER_DURATION_NORM_INTEL"/>
+ <enum value="0x94F2" name="GL_PERFQUERY_COUNTER_DURATION_RAW_INTEL"/>
+ <enum value="0x94F3" name="GL_PERFQUERY_COUNTER_THROUGHPUT_INTEL"/>
+ <enum value="0x94F4" name="GL_PERFQUERY_COUNTER_RAW_INTEL"/>
+ <enum value="0x94F5" name="GL_PERFQUERY_COUNTER_TIMESTAMP_INTEL"/>
+ <unused start="0x94F6" end="0x94F7" vendor="INTEL"/>
+ <enum value="0x94F8" name="GL_PERFQUERY_COUNTER_DATA_UINT32_INTEL"/>
+ <enum value="0x94F9" name="GL_PERFQUERY_COUNTER_DATA_UINT64_INTEL"/>
+ <enum value="0x94FA" name="GL_PERFQUERY_COUNTER_DATA_FLOAT_INTEL"/>
+ <enum value="0x94FB" name="GL_PERFQUERY_COUNTER_DATA_DOUBLE_INTEL"/>
+ <enum value="0x94FC" name="GL_PERFQUERY_COUNTER_DATA_BOOL32_INTEL"/>
+ <enum value="0x94FD" name="GL_PERFQUERY_QUERY_NAME_LENGTH_MAX_INTEL"/>
+ <enum value="0x94FE" name="GL_PERFQUERY_COUNTER_NAME_LENGTH_MAX_INTEL"/>
+ <enum value="0x94FF" name="GL_PERFQUERY_COUNTER_DESC_LENGTH_MAX_INTEL"/>
+ <enum value="0x9500" name="GL_PERFQUERY_GPA_EXTENDED_COUNTERS_INTEL"/>
+ <unused start="0x9501" end="0x950F" vendor="INTEL"/>
+ </enums>
+
+ <enums namespace="GL" start="0x9510" end="0x952F" vendor="Broadcom" comment="Khronos bug 12203">
+ <unused start="0x9510" end="0x952F" vendor="Broadcom"/>
+ </enums>
+
+<!-- Enums reservable for future use. To reserve a new range, allocate one
+ or more multiples of 16 starting at the lowest available point in this
+ block and note it in a new <enums> block immediately above.
+
+ Please remember that new enumerant allocations must be obtained by
+ request to the Khronos API registrar (see comments at the top of this
+ file) File requests in the Khronos Bugzilla, OpenGL project, Registry
+ component. -->
+
+ <enums namespace="GL" start="0x9530" end="99999" vendor="ARB" comment="RESERVED FOR FUTURE ALLOCATIONS BY KHRONOS">
+ <unused start="0x9530" end="99999" comment="RESERVED"/>
+ </enums>
+
+<!-- Historical large block allocations, all unused except (in older days) by IBM -->
+ <enums namespace="GL" start="100000" end="100999" vendor="ARB" comment="GLU enums"/>
+ <enums namespace="GL" start="101000" end="101999" vendor="ARB" comment="Conformance test enums"/>
+ <enums namespace="GL" start="102000" end="102999" vendor="ARB" comment="Unused, unlikely to ever be used"/>
+
+ <enums namespace="GL" start="103000" end="103999" vendor="IBM" comment="IBM is out of the graphics hardware business. Most of this range will remain unused.">
+ <enum value="0x19262" name="GL_RASTER_POSITION_UNCLIPPED_IBM"/>
+ <enum value="103050" name="GL_CULL_VERTEX_IBM"/>
+ <enum value="103060" name="GL_ALL_STATIC_DATA_IBM"/>
+ <enum value="103061" name="GL_STATIC_VERTEX_ARRAY_IBM"/>
+ <enum value="103070" name="GL_VERTEX_ARRAY_LIST_IBM"/>
+ <enum value="103071" name="GL_NORMAL_ARRAY_LIST_IBM"/>
+ <enum value="103072" name="GL_COLOR_ARRAY_LIST_IBM"/>
+ <enum value="103073" name="GL_INDEX_ARRAY_LIST_IBM"/>
+ <enum value="103074" name="GL_TEXTURE_COORD_ARRAY_LIST_IBM"/>
+ <enum value="103075" name="GL_EDGE_FLAG_ARRAY_LIST_IBM"/>
+ <enum value="103076" name="GL_FOG_COORDINATE_ARRAY_LIST_IBM"/>
+ <enum value="103077" name="GL_SECONDARY_COLOR_ARRAY_LIST_IBM"/>
+ <enum value="103080" name="GL_VERTEX_ARRAY_LIST_STRIDE_IBM"/>
+ <enum value="103081" name="GL_NORMAL_ARRAY_LIST_STRIDE_IBM"/>
+ <enum value="103082" name="GL_COLOR_ARRAY_LIST_STRIDE_IBM"/>
+ <enum value="103083" name="GL_INDEX_ARRAY_LIST_STRIDE_IBM"/>
+ <enum value="103084" name="GL_TEXTURE_COORD_ARRAY_LIST_STRIDE_IBM"/>
+ <enum value="103085" name="GL_EDGE_FLAG_ARRAY_LIST_STRIDE_IBM"/>
+ <enum value="103086" name="GL_FOG_COORDINATE_ARRAY_LIST_STRIDE_IBM"/>
+ <enum value="103087" name="GL_SECONDARY_COLOR_ARRAY_LIST_STRIDE_IBM"/>
+ </enums>
+
+ <enums namespace="GL" start="104000" end="104999" vendor="NEC" comment="NEC may be out of the graphics hardware business?"/>
+ <enums namespace="GL" start="105000" end="105999" vendor="Compaq" comment="Compaq was acquired by HP"/>
+ <enums namespace="GL" start="106000" end="106999" vendor="KPC" comment="Kubota Pacific is out of business"/>
+ <enums namespace="GL" start="107000" end="107999" vendor="PGI" comment="Portland Graphics was acquired by Template Graphics, which is out of business">
+ <!-- lots of <unused> areas here which won't be computed yet -->
+ <enum value="0x1A1F8" name="GL_PREFER_DOUBLEBUFFER_HINT_PGI"/>
+ <enum value="0x1A1FD" name="GL_CONSERVE_MEMORY_HINT_PGI"/>
+ <enum value="0x1A1FE" name="GL_RECLAIM_MEMORY_HINT_PGI"/>
+ <enum value="0x1A202" name="GL_NATIVE_GRAPHICS_HANDLE_PGI"/>
+ <enum value="0x1A203" name="GL_NATIVE_GRAPHICS_BEGIN_HINT_PGI"/>
+ <enum value="0x1A204" name="GL_NATIVE_GRAPHICS_END_HINT_PGI"/>
+ <enum value="0x1A20C" name="GL_ALWAYS_FAST_HINT_PGI"/>
+ <enum value="0x1A20D" name="GL_ALWAYS_SOFT_HINT_PGI"/>
+ <enum value="0x1A20E" name="GL_ALLOW_DRAW_OBJ_HINT_PGI"/>
+ <enum value="0x1A20F" name="GL_ALLOW_DRAW_WIN_HINT_PGI"/>
+ <enum value="0x1A210" name="GL_ALLOW_DRAW_FRG_HINT_PGI"/>
+ <enum value="0x1A211" name="GL_ALLOW_DRAW_MEM_HINT_PGI"/>
+ <enum value="0x1A216" name="GL_STRICT_DEPTHFUNC_HINT_PGI"/>
+ <enum value="0x1A217" name="GL_STRICT_LIGHTING_HINT_PGI"/>
+ <enum value="0x1A218" name="GL_STRICT_SCISSOR_HINT_PGI"/>
+ <enum value="0x1A219" name="GL_FULL_STIPPLE_HINT_PGI"/>
+ <enum value="0x1A220" name="GL_CLIP_NEAR_HINT_PGI"/>
+ <enum value="0x1A221" name="GL_CLIP_FAR_HINT_PGI"/>
+ <enum value="0x1A222" name="GL_WIDE_LINE_HINT_PGI"/>
+ <enum value="0x1A223" name="GL_BACK_NORMALS_HINT_PGI"/>
+ <enum value="0x1A22A" name="GL_VERTEX_DATA_HINT_PGI"/>
+ <enum value="0x1A22B" name="GL_VERTEX_CONSISTENT_HINT_PGI"/>
+ <enum value="0x1A22C" name="GL_MATERIAL_SIDE_HINT_PGI"/>
+ <enum value="0x1A22D" name="GL_MAX_VERTEX_HINT_PGI"/>
+ </enums>
+
+ <enums namespace="GL" start="108000" end="108999" vendor="ES" comment="Evans and Sutherland is out of the graphics hardware business"/>
+
+ <!-- SECTION: GL command definitions. -->
+ <commands namespace="GL">
+ <command>
+ <proto>void <name>glAccum</name></proto>
+ <param group="AccumOp"><ptype>GLenum</ptype> <name>op</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>value</name></param>
+ <glx type="render" opcode="137"/>
+ </command>
+ <command>
+ <proto>void <name>glAccumxOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>op</name></param>
+ <param><ptype>GLfixed</ptype> <name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glActiveProgramEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ </command>
+ <command>
+ <proto>void <name>glActiveShaderProgram</name></proto>
+ <param><ptype>GLuint</ptype> <name>pipeline</name></param>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ </command>
+ <command>
+ <proto>void <name>glActiveShaderProgramEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>pipeline</name></param>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ </command>
+ <command>
+ <proto>void <name>glActiveStencilFaceEXT</name></proto>
+ <param group="StencilFaceDirection"><ptype>GLenum</ptype> <name>face</name></param>
+ <glx type="render" opcode="4220"/>
+ </command>
+ <command>
+ <proto>void <name>glActiveTexture</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>texture</name></param>
+ <glx type="render" opcode="197"/>
+ </command>
+ <command>
+ <proto>void <name>glActiveTextureARB</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>texture</name></param>
+ <alias name="glActiveTexture"/>
+ <glx type="render" opcode="197"/>
+ </command>
+ <command>
+ <proto>void <name>glActiveVaryingNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param len="COMPSIZE(name)">const <ptype>GLchar</ptype> *<name>name</name></param>
+ </command>
+ <command>
+ <proto>void <name>glAlphaFragmentOp1ATI</name></proto>
+ <param group="FragmentOpATI"><ptype>GLenum</ptype> <name>op</name></param>
+ <param><ptype>GLuint</ptype> <name>dst</name></param>
+ <param><ptype>GLuint</ptype> <name>dstMod</name></param>
+ <param><ptype>GLuint</ptype> <name>arg1</name></param>
+ <param><ptype>GLuint</ptype> <name>arg1Rep</name></param>
+ <param><ptype>GLuint</ptype> <name>arg1Mod</name></param>
+ </command>
+ <command>
+ <proto>void <name>glAlphaFragmentOp2ATI</name></proto>
+ <param group="FragmentOpATI"><ptype>GLenum</ptype> <name>op</name></param>
+ <param><ptype>GLuint</ptype> <name>dst</name></param>
+ <param><ptype>GLuint</ptype> <name>dstMod</name></param>
+ <param><ptype>GLuint</ptype> <name>arg1</name></param>
+ <param><ptype>GLuint</ptype> <name>arg1Rep</name></param>
+ <param><ptype>GLuint</ptype> <name>arg1Mod</name></param>
+ <param><ptype>GLuint</ptype> <name>arg2</name></param>
+ <param><ptype>GLuint</ptype> <name>arg2Rep</name></param>
+ <param><ptype>GLuint</ptype> <name>arg2Mod</name></param>
+ </command>
+ <command>
+ <proto>void <name>glAlphaFragmentOp3ATI</name></proto>
+ <param group="FragmentOpATI"><ptype>GLenum</ptype> <name>op</name></param>
+ <param><ptype>GLuint</ptype> <name>dst</name></param>
+ <param><ptype>GLuint</ptype> <name>dstMod</name></param>
+ <param><ptype>GLuint</ptype> <name>arg1</name></param>
+ <param><ptype>GLuint</ptype> <name>arg1Rep</name></param>
+ <param><ptype>GLuint</ptype> <name>arg1Mod</name></param>
+ <param><ptype>GLuint</ptype> <name>arg2</name></param>
+ <param><ptype>GLuint</ptype> <name>arg2Rep</name></param>
+ <param><ptype>GLuint</ptype> <name>arg2Mod</name></param>
+ <param><ptype>GLuint</ptype> <name>arg3</name></param>
+ <param><ptype>GLuint</ptype> <name>arg3Rep</name></param>
+ <param><ptype>GLuint</ptype> <name>arg3Mod</name></param>
+ </command>
+ <command>
+ <proto>void <name>glAlphaFunc</name></proto>
+ <param group="AlphaFunction"><ptype>GLenum</ptype> <name>func</name></param>
+ <param><ptype>GLfloat</ptype> <name>ref</name></param>
+ <glx type="render" opcode="159"/>
+ </command>
+ <command>
+ <proto>void <name>glAlphaFuncQCOM</name></proto>
+ <param><ptype>GLenum</ptype> <name>func</name></param>
+ <param><ptype>GLclampf</ptype> <name>ref</name></param>
+ </command>
+ <command>
+ <proto>void <name>glAlphaFuncx</name></proto>
+ <param><ptype>GLenum</ptype> <name>func</name></param>
+ <param><ptype>GLfixed</ptype> <name>ref</name></param>
+ </command>
+ <command>
+ <proto>void <name>glAlphaFuncxOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>func</name></param>
+ <param group="ClampedFixed"><ptype>GLfixed</ptype> <name>ref</name></param>
+ </command>
+ <command>
+ <proto>void <name>glApplyTextureEXT</name></proto>
+ <param group="LightTextureModeEXT"><ptype>GLenum</ptype> <name>mode</name></param>
+ </command>
+ <command>
+ <proto group="Boolean"><ptype>GLboolean</ptype> <name>glAreProgramsResidentNV</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param len="n">const <ptype>GLuint</ptype> *<name>programs</name></param>
+ <param group="Boolean" len="n"><ptype>GLboolean</ptype> *<name>residences</name></param>
+ <glx type="vendor" opcode="1293"/>
+ </command>
+ <command>
+ <proto group="Boolean"><ptype>GLboolean</ptype> <name>glAreTexturesResident</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param group="Texture" len="n">const <ptype>GLuint</ptype> *<name>textures</name></param>
+ <param group="Boolean" len="n"><ptype>GLboolean</ptype> *<name>residences</name></param>
+ <glx type="single" opcode="143"/>
+ </command>
+ <command>
+ <proto group="Boolean"><ptype>GLboolean</ptype> <name>glAreTexturesResidentEXT</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param group="Texture" len="n">const <ptype>GLuint</ptype> *<name>textures</name></param>
+ <param group="Boolean" len="n"><ptype>GLboolean</ptype> *<name>residences</name></param>
+ <glx type="vendor" opcode="11"/>
+ </command>
+ <command>
+ <proto>void <name>glArrayElement</name></proto>
+ <param><ptype>GLint</ptype> <name>i</name></param>
+ </command>
+ <command>
+ <proto>void <name>glArrayElementEXT</name></proto>
+ <param><ptype>GLint</ptype> <name>i</name></param>
+ <alias name="glArrayElement"/>
+ </command>
+ <command>
+ <proto>void <name>glArrayObjectATI</name></proto>
+ <param group="EnableCap"><ptype>GLenum</ptype> <name>array</name></param>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param group="ScalarType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <param><ptype>GLuint</ptype> <name>offset</name></param>
+ </command>
+ <command>
+ <proto>void <name>glAsyncMarkerSGIX</name></proto>
+ <param><ptype>GLuint</ptype> <name>marker</name></param>
+ </command>
+ <command>
+ <proto>void <name>glAttachObjectARB</name></proto>
+ <param group="handleARB"><ptype>GLhandleARB</ptype> <name>containerObj</name></param>
+ <param group="handleARB"><ptype>GLhandleARB</ptype> <name>obj</name></param>
+ <alias name="glAttachShader"/>
+ </command>
+ <command>
+ <proto>void <name>glAttachShader</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLuint</ptype> <name>shader</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBegin</name></proto>
+ <param group="PrimitiveType"><ptype>GLenum</ptype> <name>mode</name></param>
+ <glx type="render" opcode="4"/>
+ </command>
+ <command>
+ <proto>void <name>glBeginConditionalRender</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <param group="TypeEnum"><ptype>GLenum</ptype> <name>mode</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBeginConditionalRenderNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <param group="TypeEnum"><ptype>GLenum</ptype> <name>mode</name></param>
+ <alias name="glBeginConditionalRender"/>
+ <glx type="render" opcode="348"/>
+ </command>
+ <command>
+ <proto>void <name>glBeginConditionalRenderNVX</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBeginFragmentShaderATI</name></proto>
+ </command>
+ <command>
+ <proto>void <name>glBeginOcclusionQueryNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBeginPerfMonitorAMD</name></proto>
+ <param><ptype>GLuint</ptype> <name>monitor</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBeginPerfQueryINTEL</name></proto>
+ <param><ptype>GLuint</ptype> <name>queryHandle</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBeginQuery</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <glx type="render" opcode="231"/>
+ </command>
+ <command>
+ <proto>void <name>glBeginQueryARB</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <alias name="glBeginQuery"/>
+ </command>
+ <command>
+ <proto>void <name>glBeginQueryEXT</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBeginQueryIndexed</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBeginTransformFeedback</name></proto>
+ <param><ptype>GLenum</ptype> <name>primitiveMode</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBeginTransformFeedbackEXT</name></proto>
+ <param><ptype>GLenum</ptype> <name>primitiveMode</name></param>
+ <alias name="glBeginTransformFeedback"/>
+ </command>
+ <command>
+ <proto>void <name>glBeginTransformFeedbackNV</name></proto>
+ <param><ptype>GLenum</ptype> <name>primitiveMode</name></param>
+ <alias name="glBeginTransformFeedback"/>
+ </command>
+ <command>
+ <proto>void <name>glBeginVertexShaderEXT</name></proto>
+ </command>
+ <command>
+ <proto>void <name>glBeginVideoCaptureNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>video_capture_slot</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBindAttribLocation</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param>const <ptype>GLchar</ptype> *<name>name</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBindAttribLocationARB</name></proto>
+ <param group="handleARB"><ptype>GLhandleARB</ptype> <name>programObj</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param>const <ptype>GLcharARB</ptype> *<name>name</name></param>
+ <alias name="glBindAttribLocation"/>
+ </command>
+ <command>
+ <proto>void <name>glBindBuffer</name></proto>
+ <param group="BufferTargetARB"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBindBufferARB</name></proto>
+ <param group="BufferTargetARB"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <alias name="glBindBuffer"/>
+ </command>
+ <command>
+ <proto>void <name>glBindBufferBase</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBindBufferBaseEXT</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <alias name="glBindBufferBase"/>
+ </command>
+ <command>
+ <proto>void <name>glBindBufferBaseNV</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <alias name="glBindBufferBase"/>
+ </command>
+ <command>
+ <proto>void <name>glBindBufferOffsetEXT</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <param group="BufferOffset"><ptype>GLintptr</ptype> <name>offset</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBindBufferOffsetNV</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <param group="BufferOffset"><ptype>GLintptr</ptype> <name>offset</name></param>
+ <alias name="glBindBufferOffsetEXT"/>
+ </command>
+ <command>
+ <proto>void <name>glBindBufferRange</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <param group="BufferOffset"><ptype>GLintptr</ptype> <name>offset</name></param>
+ <param group="BufferSize"><ptype>GLsizeiptr</ptype> <name>size</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBindBufferRangeEXT</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <param group="BufferOffset"><ptype>GLintptr</ptype> <name>offset</name></param>
+ <param group="BufferSize"><ptype>GLsizeiptr</ptype> <name>size</name></param>
+ <alias name="glBindBufferRange"/>
+ </command>
+ <command>
+ <proto>void <name>glBindBufferRangeNV</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <param group="BufferOffset"><ptype>GLintptr</ptype> <name>offset</name></param>
+ <param group="BufferSize"><ptype>GLsizeiptr</ptype> <name>size</name></param>
+ <alias name="glBindBufferRange"/>
+ </command>
+ <command>
+ <proto>void <name>glBindBuffersBase</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>first</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count">const <ptype>GLuint</ptype> *<name>buffers</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBindBuffersRange</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>first</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count">const <ptype>GLuint</ptype> *<name>buffers</name></param>
+ <param len="count">const <ptype>GLintptr</ptype> *<name>offsets</name></param>
+ <param len="count">const <ptype>GLsizeiptr</ptype> *<name>sizes</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBindFragDataLocation</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLuint</ptype> <name>color</name></param>
+ <param len="COMPSIZE(name)">const <ptype>GLchar</ptype> *<name>name</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBindFragDataLocationEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLuint</ptype> <name>color</name></param>
+ <param len="COMPSIZE(name)">const <ptype>GLchar</ptype> *<name>name</name></param>
+ <alias name="glBindFragDataLocation"/>
+ </command>
+ <command>
+ <proto>void <name>glBindFragDataLocationIndexed</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLuint</ptype> <name>colorNumber</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param>const <ptype>GLchar</ptype> *<name>name</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBindFragmentShaderATI</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBindFramebuffer</name></proto>
+ <param group="FramebufferTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>framebuffer</name></param>
+ <glx type="render" opcode="236"/>
+ </command>
+ <command>
+ <proto>void <name>glBindFramebufferEXT</name></proto>
+ <param group="FramebufferTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>framebuffer</name></param>
+ <glx type="render" opcode="4319"/>
+ </command>
+ <command>
+ <proto>void <name>glBindFramebufferOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>framebuffer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBindImageTexture</name></proto>
+ <param><ptype>GLuint</ptype> <name>unit</name></param>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLint</ptype> <name>level</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>layered</name></param>
+ <param><ptype>GLint</ptype> <name>layer</name></param>
+ <param><ptype>GLenum</ptype> <name>access</name></param>
+ <param><ptype>GLenum</ptype> <name>format</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBindImageTextureEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLint</ptype> <name>level</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>layered</name></param>
+ <param><ptype>GLint</ptype> <name>layer</name></param>
+ <param><ptype>GLenum</ptype> <name>access</name></param>
+ <param><ptype>GLint</ptype> <name>format</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBindImageTextures</name></proto>
+ <param><ptype>GLuint</ptype> <name>first</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count">const <ptype>GLuint</ptype> *<name>textures</name></param>
+ </command>
+ <command>
+ <proto><ptype>GLuint</ptype> <name>glBindLightParameterEXT</name></proto>
+ <param group="LightName"><ptype>GLenum</ptype> <name>light</name></param>
+ <param group="LightParameter"><ptype>GLenum</ptype> <name>value</name></param>
+ </command>
+ <command>
+ <proto><ptype>GLuint</ptype> <name>glBindMaterialParameterEXT</name></proto>
+ <param group="MaterialFace"><ptype>GLenum</ptype> <name>face</name></param>
+ <param group="MaterialParameter"><ptype>GLenum</ptype> <name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBindMultiTextureEXT</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>texunit</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="Texture"><ptype>GLuint</ptype> <name>texture</name></param>
+ </command>
+ <command>
+ <proto><ptype>GLuint</ptype> <name>glBindParameterEXT</name></proto>
+ <param group="VertexShaderParameterEXT"><ptype>GLenum</ptype> <name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBindProgramARB</name></proto>
+ <param group="ProgramTargetARB"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <glx type="render" opcode="4180"/>
+ </command>
+ <command>
+ <proto>void <name>glBindProgramNV</name></proto>
+ <param group="VertexAttribEnumNV"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <alias name="glBindProgramARB"/>
+ <glx type="render" opcode="4180"/>
+ </command>
+ <command>
+ <proto>void <name>glBindProgramPipeline</name></proto>
+ <param><ptype>GLuint</ptype> <name>pipeline</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBindProgramPipelineEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>pipeline</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBindRenderbuffer</name></proto>
+ <param group="RenderbufferTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>renderbuffer</name></param>
+ <glx type="render" opcode="235"/>
+ </command>
+ <command>
+ <proto>void <name>glBindRenderbufferEXT</name></proto>
+ <param group="RenderbufferTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>renderbuffer</name></param>
+ <glx type="render" opcode="4316"/>
+ </command>
+ <command>
+ <proto>void <name>glBindRenderbufferOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>renderbuffer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBindSampler</name></proto>
+ <param><ptype>GLuint</ptype> <name>unit</name></param>
+ <param><ptype>GLuint</ptype> <name>sampler</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBindSamplers</name></proto>
+ <param><ptype>GLuint</ptype> <name>first</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count">const <ptype>GLuint</ptype> *<name>samplers</name></param>
+ </command>
+ <command>
+ <proto><ptype>GLuint</ptype> <name>glBindTexGenParameterEXT</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>unit</name></param>
+ <param group="TextureCoordName"><ptype>GLenum</ptype> <name>coord</name></param>
+ <param group="TextureGenParameter"><ptype>GLenum</ptype> <name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBindTexture</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="Texture"><ptype>GLuint</ptype> <name>texture</name></param>
+ <glx type="render" opcode="4117"/>
+ </command>
+ <command>
+ <proto>void <name>glBindTextureEXT</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="Texture"><ptype>GLuint</ptype> <name>texture</name></param>
+ <alias name="glBindTexture"/>
+ <glx type="render" opcode="4117"/>
+ </command>
+ <command>
+ <proto>void <name>glBindTextureUnit</name></proto>
+ <param><ptype>GLuint</ptype> <name>unit</name></param>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ </command>
+ <command>
+ <proto><ptype>GLuint</ptype> <name>glBindTextureUnitParameterEXT</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>unit</name></param>
+ <param group="VertexShaderTextureUnitParameter"><ptype>GLenum</ptype> <name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBindTextures</name></proto>
+ <param><ptype>GLuint</ptype> <name>first</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count">const <ptype>GLuint</ptype> *<name>textures</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBindTransformFeedback</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBindTransformFeedbackNV</name></proto>
+ <param group="BufferTargetARB"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBindVertexArray</name></proto>
+ <param><ptype>GLuint</ptype> <name>array</name></param>
+ <glx type="render" opcode="350"/>
+ </command>
+ <command>
+ <proto>void <name>glBindVertexArrayAPPLE</name></proto>
+ <param><ptype>GLuint</ptype> <name>array</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBindVertexArrayOES</name></proto>
+ <param><ptype>GLuint</ptype> <name>array</name></param>
+ <alias name="glBindVertexArray"/>
+ </command>
+ <command>
+ <proto>void <name>glBindVertexBuffer</name></proto>
+ <param><ptype>GLuint</ptype> <name>bindingindex</name></param>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <param group="BufferOffset"><ptype>GLintptr</ptype> <name>offset</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBindVertexBuffers</name></proto>
+ <param><ptype>GLuint</ptype> <name>first</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count">const <ptype>GLuint</ptype> *<name>buffers</name></param>
+ <param len="count">const <ptype>GLintptr</ptype> *<name>offsets</name></param>
+ <param len="count">const <ptype>GLsizei</ptype> *<name>strides</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBindVertexShaderEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBindVideoCaptureStreamBufferNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>video_capture_slot</name></param>
+ <param><ptype>GLuint</ptype> <name>stream</name></param>
+ <param><ptype>GLenum</ptype> <name>frame_region</name></param>
+ <param group="BufferOffsetARB"><ptype>GLintptrARB</ptype> <name>offset</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBindVideoCaptureStreamTextureNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>video_capture_slot</name></param>
+ <param><ptype>GLuint</ptype> <name>stream</name></param>
+ <param><ptype>GLenum</ptype> <name>frame_region</name></param>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBinormal3bEXT</name></proto>
+ <param><ptype>GLbyte</ptype> <name>bx</name></param>
+ <param><ptype>GLbyte</ptype> <name>by</name></param>
+ <param><ptype>GLbyte</ptype> <name>bz</name></param>
+ <vecequiv name="glBinormal3bvEXT"/>
+ </command>
+ <command>
+ <proto>void <name>glBinormal3bvEXT</name></proto>
+ <param len="3">const <ptype>GLbyte</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBinormal3dEXT</name></proto>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>bx</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>by</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>bz</name></param>
+ <vecequiv name="glBinormal3dvEXT"/>
+ </command>
+ <command>
+ <proto>void <name>glBinormal3dvEXT</name></proto>
+ <param group="CoordD" len="3">const <ptype>GLdouble</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBinormal3fEXT</name></proto>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>bx</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>by</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>bz</name></param>
+ <vecequiv name="glBinormal3fvEXT"/>
+ </command>
+ <command>
+ <proto>void <name>glBinormal3fvEXT</name></proto>
+ <param group="CoordF" len="3">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBinormal3iEXT</name></proto>
+ <param><ptype>GLint</ptype> <name>bx</name></param>
+ <param><ptype>GLint</ptype> <name>by</name></param>
+ <param><ptype>GLint</ptype> <name>bz</name></param>
+ <vecequiv name="glBinormal3ivEXT"/>
+ </command>
+ <command>
+ <proto>void <name>glBinormal3ivEXT</name></proto>
+ <param len="3">const <ptype>GLint</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBinormal3sEXT</name></proto>
+ <param><ptype>GLshort</ptype> <name>bx</name></param>
+ <param><ptype>GLshort</ptype> <name>by</name></param>
+ <param><ptype>GLshort</ptype> <name>bz</name></param>
+ <vecequiv name="glBinormal3svEXT"/>
+ </command>
+ <command>
+ <proto>void <name>glBinormal3svEXT</name></proto>
+ <param len="3">const <ptype>GLshort</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBinormalPointerEXT</name></proto>
+ <param group="BinormalPointerTypeEXT"><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ <param len="COMPSIZE(type,stride)">const void *<name>pointer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBitmap</name></proto>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>xorig</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>yorig</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>xmove</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>ymove</name></param>
+ <param len="COMPSIZE(width,height)">const <ptype>GLubyte</ptype> *<name>bitmap</name></param>
+ <glx type="render" opcode="5"/>
+ <glx type="render" opcode="311" name="glBitmapPBO" comment="PBO protocol"/>
+ </command>
+ <command>
+ <proto>void <name>glBitmapxOES</name></proto>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param><ptype>GLfixed</ptype> <name>xorig</name></param>
+ <param><ptype>GLfixed</ptype> <name>yorig</name></param>
+ <param><ptype>GLfixed</ptype> <name>xmove</name></param>
+ <param><ptype>GLfixed</ptype> <name>ymove</name></param>
+ <param len="COMPSIZE(width,height)">const <ptype>GLubyte</ptype> *<name>bitmap</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBlendBarrierKHR</name></proto>
+ </command>
+ <command>
+ <proto>void <name>glBlendBarrierNV</name></proto>
+ </command>
+ <command>
+ <proto>void <name>glBlendColor</name></proto>
+ <param group="ColorF"><ptype>GLfloat</ptype> <name>red</name></param>
+ <param group="ColorF"><ptype>GLfloat</ptype> <name>green</name></param>
+ <param group="ColorF"><ptype>GLfloat</ptype> <name>blue</name></param>
+ <param group="ColorF"><ptype>GLfloat</ptype> <name>alpha</name></param>
+ <glx type="render" opcode="4096"/>
+ </command>
+ <command>
+ <proto>void <name>glBlendColorEXT</name></proto>
+ <param group="ColorF"><ptype>GLfloat</ptype> <name>red</name></param>
+ <param group="ColorF"><ptype>GLfloat</ptype> <name>green</name></param>
+ <param group="ColorF"><ptype>GLfloat</ptype> <name>blue</name></param>
+ <param group="ColorF"><ptype>GLfloat</ptype> <name>alpha</name></param>
+ <alias name="glBlendColor"/>
+ <glx type="render" opcode="4096"/>
+ </command>
+ <command>
+ <proto>void <name>glBlendColorxOES</name></proto>
+ <param group="ClampedFixed"><ptype>GLfixed</ptype> <name>red</name></param>
+ <param group="ClampedFixed"><ptype>GLfixed</ptype> <name>green</name></param>
+ <param group="ClampedFixed"><ptype>GLfixed</ptype> <name>blue</name></param>
+ <param group="ClampedFixed"><ptype>GLfixed</ptype> <name>alpha</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBlendEquation</name></proto>
+ <param group="BlendEquationMode"><ptype>GLenum</ptype> <name>mode</name></param>
+ <glx type="render" opcode="4097"/>
+ </command>
+ <command>
+ <proto>void <name>glBlendEquationEXT</name></proto>
+ <param group="BlendEquationModeEXT"><ptype>GLenum</ptype> <name>mode</name></param>
+ <alias name="glBlendEquation"/>
+ <glx type="render" opcode="4097"/>
+ </command>
+ <command>
+ <proto>void <name>glBlendEquationIndexedAMD</name></proto>
+ <param><ptype>GLuint</ptype> <name>buf</name></param>
+ <param><ptype>GLenum</ptype> <name>mode</name></param>
+ <alias name="glBlendEquationi"/>
+ </command>
+ <command>
+ <proto>void <name>glBlendEquationOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>mode</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBlendEquationSeparate</name></proto>
+ <param group="BlendEquationModeEXT"><ptype>GLenum</ptype> <name>modeRGB</name></param>
+ <param group="BlendEquationModeEXT"><ptype>GLenum</ptype> <name>modeAlpha</name></param>
+ <glx type="render" opcode="4228"/>
+ </command>
+ <command>
+ <proto>void <name>glBlendEquationSeparateEXT</name></proto>
+ <param group="BlendEquationModeEXT"><ptype>GLenum</ptype> <name>modeRGB</name></param>
+ <param group="BlendEquationModeEXT"><ptype>GLenum</ptype> <name>modeAlpha</name></param>
+ <alias name="glBlendEquationSeparate"/>
+ <glx type="render" opcode="4228"/>
+ </command>
+ <command>
+ <proto>void <name>glBlendEquationSeparateIndexedAMD</name></proto>
+ <param><ptype>GLuint</ptype> <name>buf</name></param>
+ <param><ptype>GLenum</ptype> <name>modeRGB</name></param>
+ <param><ptype>GLenum</ptype> <name>modeAlpha</name></param>
+ <alias name="glBlendEquationSeparatei"/>
+ </command>
+ <command>
+ <proto>void <name>glBlendEquationSeparateOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>modeRGB</name></param>
+ <param><ptype>GLenum</ptype> <name>modeAlpha</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBlendEquationSeparatei</name></proto>
+ <param><ptype>GLuint</ptype> <name>buf</name></param>
+ <param><ptype>GLenum</ptype> <name>modeRGB</name></param>
+ <param><ptype>GLenum</ptype> <name>modeAlpha</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBlendEquationSeparateiARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>buf</name></param>
+ <param><ptype>GLenum</ptype> <name>modeRGB</name></param>
+ <param><ptype>GLenum</ptype> <name>modeAlpha</name></param>
+ <alias name="glBlendEquationSeparatei"/>
+ </command>
+ <command>
+ <proto>void <name>glBlendEquationSeparateiEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>buf</name></param>
+ <param><ptype>GLenum</ptype> <name>modeRGB</name></param>
+ <param><ptype>GLenum</ptype> <name>modeAlpha</name></param>
+ <alias name="glBlendEquationSeparatei"/>
+ </command>
+ <command>
+ <proto>void <name>glBlendEquationi</name></proto>
+ <param><ptype>GLuint</ptype> <name>buf</name></param>
+ <param><ptype>GLenum</ptype> <name>mode</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBlendEquationiARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>buf</name></param>
+ <param><ptype>GLenum</ptype> <name>mode</name></param>
+ <alias name="glBlendEquationi"/>
+ </command>
+ <command>
+ <proto>void <name>glBlendEquationiEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>buf</name></param>
+ <param><ptype>GLenum</ptype> <name>mode</name></param>
+ <alias name="glBlendEquationi"/>
+ </command>
+ <command>
+ <proto>void <name>glBlendFunc</name></proto>
+ <param group="BlendingFactorSrc"><ptype>GLenum</ptype> <name>sfactor</name></param>
+ <param group="BlendingFactorDest"><ptype>GLenum</ptype> <name>dfactor</name></param>
+ <glx type="render" opcode="160"/>
+ </command>
+ <command>
+ <proto>void <name>glBlendFuncIndexedAMD</name></proto>
+ <param><ptype>GLuint</ptype> <name>buf</name></param>
+ <param><ptype>GLenum</ptype> <name>src</name></param>
+ <param><ptype>GLenum</ptype> <name>dst</name></param>
+ <alias name="glBlendFunci"/>
+ </command>
+ <command>
+ <proto>void <name>glBlendFuncSeparate</name></proto>
+ <param group="BlendFuncSeparateParameterEXT"><ptype>GLenum</ptype> <name>sfactorRGB</name></param>
+ <param group="BlendFuncSeparateParameterEXT"><ptype>GLenum</ptype> <name>dfactorRGB</name></param>
+ <param group="BlendFuncSeparateParameterEXT"><ptype>GLenum</ptype> <name>sfactorAlpha</name></param>
+ <param group="BlendFuncSeparateParameterEXT"><ptype>GLenum</ptype> <name>dfactorAlpha</name></param>
+ <glx type="render" opcode="4134"/>
+ </command>
+ <command>
+ <proto>void <name>glBlendFuncSeparateEXT</name></proto>
+ <param group="BlendFuncSeparateParameterEXT"><ptype>GLenum</ptype> <name>sfactorRGB</name></param>
+ <param group="BlendFuncSeparateParameterEXT"><ptype>GLenum</ptype> <name>dfactorRGB</name></param>
+ <param group="BlendFuncSeparateParameterEXT"><ptype>GLenum</ptype> <name>sfactorAlpha</name></param>
+ <param group="BlendFuncSeparateParameterEXT"><ptype>GLenum</ptype> <name>dfactorAlpha</name></param>
+ <alias name="glBlendFuncSeparate"/>
+ <glx type="render" opcode="4134"/>
+ </command>
+ <command>
+ <proto>void <name>glBlendFuncSeparateINGR</name></proto>
+ <param group="BlendFuncSeparateParameterEXT"><ptype>GLenum</ptype> <name>sfactorRGB</name></param>
+ <param group="BlendFuncSeparateParameterEXT"><ptype>GLenum</ptype> <name>dfactorRGB</name></param>
+ <param group="BlendFuncSeparateParameterEXT"><ptype>GLenum</ptype> <name>sfactorAlpha</name></param>
+ <param group="BlendFuncSeparateParameterEXT"><ptype>GLenum</ptype> <name>dfactorAlpha</name></param>
+ <alias name="glBlendFuncSeparate"/>
+ <glx type="render" opcode="4134"/>
+ </command>
+ <command>
+ <proto>void <name>glBlendFuncSeparateIndexedAMD</name></proto>
+ <param><ptype>GLuint</ptype> <name>buf</name></param>
+ <param><ptype>GLenum</ptype> <name>srcRGB</name></param>
+ <param><ptype>GLenum</ptype> <name>dstRGB</name></param>
+ <param><ptype>GLenum</ptype> <name>srcAlpha</name></param>
+ <param><ptype>GLenum</ptype> <name>dstAlpha</name></param>
+ <alias name="glBlendFuncSeparatei"/>
+ </command>
+ <command>
+ <proto>void <name>glBlendFuncSeparateOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>srcRGB</name></param>
+ <param><ptype>GLenum</ptype> <name>dstRGB</name></param>
+ <param><ptype>GLenum</ptype> <name>srcAlpha</name></param>
+ <param><ptype>GLenum</ptype> <name>dstAlpha</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBlendFuncSeparatei</name></proto>
+ <param><ptype>GLuint</ptype> <name>buf</name></param>
+ <param><ptype>GLenum</ptype> <name>srcRGB</name></param>
+ <param><ptype>GLenum</ptype> <name>dstRGB</name></param>
+ <param><ptype>GLenum</ptype> <name>srcAlpha</name></param>
+ <param><ptype>GLenum</ptype> <name>dstAlpha</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBlendFuncSeparateiARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>buf</name></param>
+ <param><ptype>GLenum</ptype> <name>srcRGB</name></param>
+ <param><ptype>GLenum</ptype> <name>dstRGB</name></param>
+ <param><ptype>GLenum</ptype> <name>srcAlpha</name></param>
+ <param><ptype>GLenum</ptype> <name>dstAlpha</name></param>
+ <alias name="glBlendFuncSeparatei"/>
+ </command>
+ <command>
+ <proto>void <name>glBlendFuncSeparateiEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>buf</name></param>
+ <param><ptype>GLenum</ptype> <name>srcRGB</name></param>
+ <param><ptype>GLenum</ptype> <name>dstRGB</name></param>
+ <param><ptype>GLenum</ptype> <name>srcAlpha</name></param>
+ <param><ptype>GLenum</ptype> <name>dstAlpha</name></param>
+ <alias name="glBlendFuncSeparatei"/>
+ </command>
+ <command>
+ <proto>void <name>glBlendFunci</name></proto>
+ <param><ptype>GLuint</ptype> <name>buf</name></param>
+ <param><ptype>GLenum</ptype> <name>src</name></param>
+ <param><ptype>GLenum</ptype> <name>dst</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBlendFunciARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>buf</name></param>
+ <param><ptype>GLenum</ptype> <name>src</name></param>
+ <param><ptype>GLenum</ptype> <name>dst</name></param>
+ <alias name="glBlendFunci"/>
+ </command>
+ <command>
+ <proto>void <name>glBlendFunciEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>buf</name></param>
+ <param><ptype>GLenum</ptype> <name>src</name></param>
+ <param><ptype>GLenum</ptype> <name>dst</name></param>
+ <alias name="glBlendFunci"/>
+ </command>
+ <command>
+ <proto>void <name>glBlendParameteriNV</name></proto>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLint</ptype> <name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBlitFramebuffer</name></proto>
+ <param><ptype>GLint</ptype> <name>srcX0</name></param>
+ <param><ptype>GLint</ptype> <name>srcY0</name></param>
+ <param><ptype>GLint</ptype> <name>srcX1</name></param>
+ <param><ptype>GLint</ptype> <name>srcY1</name></param>
+ <param><ptype>GLint</ptype> <name>dstX0</name></param>
+ <param><ptype>GLint</ptype> <name>dstY0</name></param>
+ <param><ptype>GLint</ptype> <name>dstX1</name></param>
+ <param><ptype>GLint</ptype> <name>dstY1</name></param>
+ <param group="ClearBufferMask"><ptype>GLbitfield</ptype> <name>mask</name></param>
+ <param><ptype>GLenum</ptype> <name>filter</name></param>
+ <glx type="render" opcode="4330"/>
+ </command>
+ <command>
+ <proto>void <name>glBlitFramebufferANGLE</name></proto>
+ <param><ptype>GLint</ptype> <name>srcX0</name></param>
+ <param><ptype>GLint</ptype> <name>srcY0</name></param>
+ <param><ptype>GLint</ptype> <name>srcX1</name></param>
+ <param><ptype>GLint</ptype> <name>srcY1</name></param>
+ <param><ptype>GLint</ptype> <name>dstX0</name></param>
+ <param><ptype>GLint</ptype> <name>dstY0</name></param>
+ <param><ptype>GLint</ptype> <name>dstX1</name></param>
+ <param><ptype>GLint</ptype> <name>dstY1</name></param>
+ <param><ptype>GLbitfield</ptype> <name>mask</name></param>
+ <param><ptype>GLenum</ptype> <name>filter</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBlitFramebufferEXT</name></proto>
+ <param><ptype>GLint</ptype> <name>srcX0</name></param>
+ <param><ptype>GLint</ptype> <name>srcY0</name></param>
+ <param><ptype>GLint</ptype> <name>srcX1</name></param>
+ <param><ptype>GLint</ptype> <name>srcY1</name></param>
+ <param><ptype>GLint</ptype> <name>dstX0</name></param>
+ <param><ptype>GLint</ptype> <name>dstY0</name></param>
+ <param><ptype>GLint</ptype> <name>dstX1</name></param>
+ <param><ptype>GLint</ptype> <name>dstY1</name></param>
+ <param group="ClearBufferMask"><ptype>GLbitfield</ptype> <name>mask</name></param>
+ <param><ptype>GLenum</ptype> <name>filter</name></param>
+ <alias name="glBlitFramebuffer"/>
+ <glx type="render" opcode="4330"/>
+ </command>
+ <command>
+ <proto>void <name>glBlitFramebufferNV</name></proto>
+ <param><ptype>GLint</ptype> <name>srcX0</name></param>
+ <param><ptype>GLint</ptype> <name>srcY0</name></param>
+ <param><ptype>GLint</ptype> <name>srcX1</name></param>
+ <param><ptype>GLint</ptype> <name>srcY1</name></param>
+ <param><ptype>GLint</ptype> <name>dstX0</name></param>
+ <param><ptype>GLint</ptype> <name>dstY0</name></param>
+ <param><ptype>GLint</ptype> <name>dstX1</name></param>
+ <param><ptype>GLint</ptype> <name>dstY1</name></param>
+ <param><ptype>GLbitfield</ptype> <name>mask</name></param>
+ <param><ptype>GLenum</ptype> <name>filter</name></param>
+ <alias name="glBlitFramebuffer"/>
+ </command>
+ <command>
+ <proto>void <name>glBlitNamedFramebuffer</name></proto>
+ <param><ptype>GLuint</ptype> <name>readFramebuffer</name></param>
+ <param><ptype>GLuint</ptype> <name>drawFramebuffer</name></param>
+ <param><ptype>GLint</ptype> <name>srcX0</name></param>
+ <param><ptype>GLint</ptype> <name>srcY0</name></param>
+ <param><ptype>GLint</ptype> <name>srcX1</name></param>
+ <param><ptype>GLint</ptype> <name>srcY1</name></param>
+ <param><ptype>GLint</ptype> <name>dstX0</name></param>
+ <param><ptype>GLint</ptype> <name>dstY0</name></param>
+ <param><ptype>GLint</ptype> <name>dstX1</name></param>
+ <param><ptype>GLint</ptype> <name>dstY1</name></param>
+ <param><ptype>GLbitfield</ptype> <name>mask</name></param>
+ <param><ptype>GLenum</ptype> <name>filter</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBufferAddressRangeNV</name></proto>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLuint64EXT</ptype> <name>address</name></param>
+ <param group="BufferSize"><ptype>GLsizeiptr</ptype> <name>length</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBufferData</name></proto>
+ <param group="BufferTargetARB"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="BufferSize"><ptype>GLsizeiptr</ptype> <name>size</name></param>
+ <param len="size">const void *<name>data</name></param>
+ <param group="BufferUsageARB"><ptype>GLenum</ptype> <name>usage</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBufferDataARB</name></proto>
+ <param group="BufferTargetARB"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="BufferSizeARB"><ptype>GLsizeiptrARB</ptype> <name>size</name></param>
+ <param len="size">const void *<name>data</name></param>
+ <param group="BufferUsageARB"><ptype>GLenum</ptype> <name>usage</name></param>
+ <alias name="glBufferData"/>
+ </command>
+ <command>
+ <proto>void <name>glBufferPageCommitmentARB</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLintptr</ptype> <name>offset</name></param>
+ <param><ptype>GLsizei</ptype> <name>size</name></param>
+ <param><ptype>GLboolean</ptype> <name>commit</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBufferParameteriAPPLE</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLint</ptype> <name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBufferStorage</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLsizeiptr</ptype> <name>size</name></param>
+ <param len="size">const void *<name>data</name></param>
+ <param><ptype>GLbitfield</ptype> <name>flags</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBufferSubData</name></proto>
+ <param group="BufferTargetARB"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="BufferOffset"><ptype>GLintptr</ptype> <name>offset</name></param>
+ <param group="BufferSize"><ptype>GLsizeiptr</ptype> <name>size</name></param>
+ <param len="size">const void *<name>data</name></param>
+ </command>
+ <command>
+ <proto>void <name>glBufferSubDataARB</name></proto>
+ <param group="BufferTargetARB"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="BufferOffsetARB"><ptype>GLintptrARB</ptype> <name>offset</name></param>
+ <param group="BufferSizeARB"><ptype>GLsizeiptrARB</ptype> <name>size</name></param>
+ <param len="size">const void *<name>data</name></param>
+ <alias name="glBufferSubData"/>
+ </command>
+ <command>
+ <proto>void <name>glCallList</name></proto>
+ <param group="List"><ptype>GLuint</ptype> <name>list</name></param>
+ <glx type="render" opcode="1"/>
+ </command>
+ <command>
+ <proto>void <name>glCallLists</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param group="ListNameType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(n,type)">const void *<name>lists</name></param>
+ <glx type="render" opcode="2"/>
+ </command>
+ <command>
+ <proto><ptype>GLenum</ptype> <name>glCheckFramebufferStatus</name></proto>
+ <param group="FramebufferTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <glx type="vendor" opcode="1427"/>
+ </command>
+ <command>
+ <proto><ptype>GLenum</ptype> <name>glCheckFramebufferStatusEXT</name></proto>
+ <param group="FramebufferTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <alias name="glCheckFramebufferStatus"/>
+ <glx type="vendor" opcode="1427"/>
+ </command>
+ <command>
+ <proto><ptype>GLenum</ptype> <name>glCheckFramebufferStatusOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ </command>
+ <command>
+ <proto><ptype>GLenum</ptype> <name>glCheckNamedFramebufferStatus</name></proto>
+ <param><ptype>GLuint</ptype> <name>framebuffer</name></param>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ </command>
+ <command>
+ <proto group="FramebufferStatus"><ptype>GLenum</ptype> <name>glCheckNamedFramebufferStatusEXT</name></proto>
+ <param group="Framebuffer"><ptype>GLuint</ptype> <name>framebuffer</name></param>
+ <param group="FramebufferTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ </command>
+ <command>
+ <proto>void <name>glClampColor</name></proto>
+ <param group="ClampColorTargetARB"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="ClampColorModeARB"><ptype>GLenum</ptype> <name>clamp</name></param>
+ <glx type="render" opcode="234"/>
+ </command>
+ <command>
+ <proto>void <name>glClampColorARB</name></proto>
+ <param group="ClampColorTargetARB"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="ClampColorModeARB"><ptype>GLenum</ptype> <name>clamp</name></param>
+ <alias name="glClampColor"/>
+ <glx type="render" opcode="234"/>
+ </command>
+ <command>
+ <proto>void <name>glClear</name></proto>
+ <param group="ClearBufferMask"><ptype>GLbitfield</ptype> <name>mask</name></param>
+ <glx type="render" opcode="127"/>
+ </command>
+ <command>
+ <proto>void <name>glClearAccum</name></proto>
+ <param><ptype>GLfloat</ptype> <name>red</name></param>
+ <param><ptype>GLfloat</ptype> <name>green</name></param>
+ <param><ptype>GLfloat</ptype> <name>blue</name></param>
+ <param><ptype>GLfloat</ptype> <name>alpha</name></param>
+ <glx type="render" opcode="128"/>
+ </command>
+ <command>
+ <proto>void <name>glClearAccumxOES</name></proto>
+ <param group="ClampedFixed"><ptype>GLfixed</ptype> <name>red</name></param>
+ <param group="ClampedFixed"><ptype>GLfixed</ptype> <name>green</name></param>
+ <param group="ClampedFixed"><ptype>GLfixed</ptype> <name>blue</name></param>
+ <param group="ClampedFixed"><ptype>GLfixed</ptype> <name>alpha</name></param>
+ </command>
+ <command>
+ <proto>void <name>glClearBufferData</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLenum</ptype> <name>format</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(format,type)">const void *<name>data</name></param>
+ </command>
+ <command>
+ <proto>void <name>glClearBufferSubData</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param group="BufferOffset"><ptype>GLintptr</ptype> <name>offset</name></param>
+ <param group="BufferSize"><ptype>GLsizeiptr</ptype> <name>size</name></param>
+ <param><ptype>GLenum</ptype> <name>format</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(format,type)">const void *<name>data</name></param>
+ </command>
+ <command>
+ <proto>void <name>glClearBufferfi</name></proto>
+ <param><ptype>GLenum</ptype> <name>buffer</name></param>
+ <param group="DrawBufferName"><ptype>GLint</ptype> <name>drawbuffer</name></param>
+ <param><ptype>GLfloat</ptype> <name>depth</name></param>
+ <param><ptype>GLint</ptype> <name>stencil</name></param>
+ </command>
+ <command>
+ <proto>void <name>glClearBufferfv</name></proto>
+ <param><ptype>GLenum</ptype> <name>buffer</name></param>
+ <param group="DrawBufferName"><ptype>GLint</ptype> <name>drawbuffer</name></param>
+ <param len="COMPSIZE(buffer)">const <ptype>GLfloat</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glClearBufferiv</name></proto>
+ <param><ptype>GLenum</ptype> <name>buffer</name></param>
+ <param group="DrawBufferName"><ptype>GLint</ptype> <name>drawbuffer</name></param>
+ <param len="COMPSIZE(buffer)">const <ptype>GLint</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glClearBufferuiv</name></proto>
+ <param><ptype>GLenum</ptype> <name>buffer</name></param>
+ <param group="DrawBufferName"><ptype>GLint</ptype> <name>drawbuffer</name></param>
+ <param len="COMPSIZE(buffer)">const <ptype>GLuint</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glClearColor</name></proto>
+ <param group="ColorF"><ptype>GLfloat</ptype> <name>red</name></param>
+ <param group="ColorF"><ptype>GLfloat</ptype> <name>green</name></param>
+ <param group="ColorF"><ptype>GLfloat</ptype> <name>blue</name></param>
+ <param group="ColorF"><ptype>GLfloat</ptype> <name>alpha</name></param>
+ <glx type="render" opcode="130"/>
+ </command>
+ <command>
+ <proto>void <name>glClearColorIiEXT</name></proto>
+ <param><ptype>GLint</ptype> <name>red</name></param>
+ <param><ptype>GLint</ptype> <name>green</name></param>
+ <param><ptype>GLint</ptype> <name>blue</name></param>
+ <param><ptype>GLint</ptype> <name>alpha</name></param>
+ <glx type="render" opcode="4292"/>
+ </command>
+ <command>
+ <proto>void <name>glClearColorIuiEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>red</name></param>
+ <param><ptype>GLuint</ptype> <name>green</name></param>
+ <param><ptype>GLuint</ptype> <name>blue</name></param>
+ <param><ptype>GLuint</ptype> <name>alpha</name></param>
+ <glx type="render" opcode="4293"/>
+ </command>
+ <command>
+ <proto>void <name>glClearColorx</name></proto>
+ <param><ptype>GLfixed</ptype> <name>red</name></param>
+ <param><ptype>GLfixed</ptype> <name>green</name></param>
+ <param><ptype>GLfixed</ptype> <name>blue</name></param>
+ <param><ptype>GLfixed</ptype> <name>alpha</name></param>
+ </command>
+ <command>
+ <proto>void <name>glClearColorxOES</name></proto>
+ <param group="ClampedFixed"><ptype>GLfixed</ptype> <name>red</name></param>
+ <param group="ClampedFixed"><ptype>GLfixed</ptype> <name>green</name></param>
+ <param group="ClampedFixed"><ptype>GLfixed</ptype> <name>blue</name></param>
+ <param group="ClampedFixed"><ptype>GLfixed</ptype> <name>alpha</name></param>
+ </command>
+ <command>
+ <proto>void <name>glClearDepth</name></proto>
+ <param><ptype>GLdouble</ptype> <name>depth</name></param>
+ <glx type="render" opcode="132"/>
+ </command>
+ <command>
+ <proto>void <name>glClearDepthdNV</name></proto>
+ <param><ptype>GLdouble</ptype> <name>depth</name></param>
+ <glx type="render" opcode="4284"/>
+ </command>
+ <command>
+ <proto>void <name>glClearDepthf</name></proto>
+ <param><ptype>GLfloat</ptype> <name>d</name></param>
+ </command>
+ <command>
+ <proto>void <name>glClearDepthfOES</name></proto>
+ <param group="ClampedFloat32"><ptype>GLclampf</ptype> <name>depth</name></param>
+ <glx type="render" opcode="4308"/>
+ <alias name="glClearDepthf"/>
+ </command>
+ <command>
+ <proto>void <name>glClearDepthx</name></proto>
+ <param><ptype>GLfixed</ptype> <name>depth</name></param>
+ </command>
+ <command>
+ <proto>void <name>glClearDepthxOES</name></proto>
+ <param group="ClampedFixed"><ptype>GLfixed</ptype> <name>depth</name></param>
+ </command>
+ <command>
+ <proto>void <name>glClearIndex</name></proto>
+ <param group="MaskedColorIndexValueF"><ptype>GLfloat</ptype> <name>c</name></param>
+ <glx type="render" opcode="129"/>
+ </command>
+ <command>
+ <proto>void <name>glClearNamedBufferData</name></proto>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <param><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLenum</ptype> <name>format</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param>const void *<name>data</name></param>
+ </command>
+ <command>
+ <proto>void <name>glClearNamedBufferDataEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <param><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param group="PixelType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(format,type)">const void *<name>data</name></param>
+ </command>
+ <command>
+ <proto>void <name>glClearNamedBufferSubData</name></proto>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <param><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLintptr</ptype> <name>offset</name></param>
+ <param><ptype>GLsizei</ptype> <name>size</name></param>
+ <param><ptype>GLenum</ptype> <name>format</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param>const void *<name>data</name></param>
+ </command>
+ <command>
+ <proto>void <name>glClearNamedBufferSubDataEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <param><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param group="BufferSize"><ptype>GLsizeiptr</ptype> <name>offset</name></param>
+ <param group="BufferSize"><ptype>GLsizeiptr</ptype> <name>size</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param group="PixelType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(format,type)">const void *<name>data</name></param>
+ </command>
+ <command>
+ <proto>void <name>glClearNamedFramebufferfi</name></proto>
+ <param><ptype>GLuint</ptype> <name>framebuffer</name></param>
+ <param><ptype>GLenum</ptype> <name>buffer</name></param>
+ <param>const <ptype>GLfloat</ptype> <name>depth</name></param>
+ <param><ptype>GLint</ptype> <name>stencil</name></param>
+ </command>
+ <command>
+ <proto>void <name>glClearNamedFramebufferfv</name></proto>
+ <param><ptype>GLuint</ptype> <name>framebuffer</name></param>
+ <param><ptype>GLenum</ptype> <name>buffer</name></param>
+ <param><ptype>GLint</ptype> <name>drawbuffer</name></param>
+ <param>const <ptype>GLfloat</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glClearNamedFramebufferiv</name></proto>
+ <param><ptype>GLuint</ptype> <name>framebuffer</name></param>
+ <param><ptype>GLenum</ptype> <name>buffer</name></param>
+ <param><ptype>GLint</ptype> <name>drawbuffer</name></param>
+ <param>const <ptype>GLint</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glClearNamedFramebufferuiv</name></proto>
+ <param><ptype>GLuint</ptype> <name>framebuffer</name></param>
+ <param><ptype>GLenum</ptype> <name>buffer</name></param>
+ <param><ptype>GLint</ptype> <name>drawbuffer</name></param>
+ <param>const <ptype>GLuint</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glClearStencil</name></proto>
+ <param group="StencilValue"><ptype>GLint</ptype> <name>s</name></param>
+ <glx type="render" opcode="131"/>
+ </command>
+ <command>
+ <proto>void <name>glClearTexImage</name></proto>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLint</ptype> <name>level</name></param>
+ <param><ptype>GLenum</ptype> <name>format</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(format,type)">const void *<name>data</name></param>
+ </command>
+ <command>
+ <proto>void <name>glClearTexSubImage</name></proto>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLint</ptype> <name>level</name></param>
+ <param><ptype>GLint</ptype> <name>xoffset</name></param>
+ <param><ptype>GLint</ptype> <name>yoffset</name></param>
+ <param><ptype>GLint</ptype> <name>zoffset</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param><ptype>GLsizei</ptype> <name>depth</name></param>
+ <param><ptype>GLenum</ptype> <name>format</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(format,type)">const void *<name>data</name></param>
+ </command>
+ <command>
+ <proto>void <name>glClientActiveTexture</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>texture</name></param>
+ </command>
+ <command>
+ <proto>void <name>glClientActiveTextureARB</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>texture</name></param>
+ <alias name="glClientActiveTexture"/>
+ </command>
+ <command>
+ <proto>void <name>glClientActiveVertexStreamATI</name></proto>
+ <param group="VertexStreamATI"><ptype>GLenum</ptype> <name>stream</name></param>
+ </command>
+ <command>
+ <proto>void <name>glClientAttribDefaultEXT</name></proto>
+ <param group="ClientAttribMask"><ptype>GLbitfield</ptype> <name>mask</name></param>
+ </command>
+ <command>
+ <proto><ptype>GLenum</ptype> <name>glClientWaitSync</name></proto>
+ <param group="sync"><ptype>GLsync</ptype> <name>sync</name></param>
+ <param><ptype>GLbitfield</ptype> <name>flags</name></param>
+ <param><ptype>GLuint64</ptype> <name>timeout</name></param>
+ </command>
+ <command>
+ <proto><ptype>GLenum</ptype> <name>glClientWaitSyncAPPLE</name></proto>
+ <param><ptype>GLsync</ptype> <name>sync</name></param>
+ <param><ptype>GLbitfield</ptype> <name>flags</name></param>
+ <param><ptype>GLuint64</ptype> <name>timeout</name></param>
+ <alias name="glClientWaitSync"/>
+ </command>
+ <command>
+ <proto>void <name>glClipControl</name></proto>
+ <param><ptype>GLenum</ptype> <name>origin</name></param>
+ <param><ptype>GLenum</ptype> <name>depth</name></param>
+ </command>
+ <command>
+ <proto>void <name>glClipPlane</name></proto>
+ <param group="ClipPlaneName"><ptype>GLenum</ptype> <name>plane</name></param>
+ <param len="4">const <ptype>GLdouble</ptype> *<name>equation</name></param>
+ <glx type="render" opcode="77"/>
+ </command>
+ <command>
+ <proto>void <name>glClipPlanef</name></proto>
+ <param><ptype>GLenum</ptype> <name>p</name></param>
+ <param len="4">const <ptype>GLfloat</ptype> *<name>eqn</name></param>
+ </command>
+ <command>
+ <proto>void <name>glClipPlanefIMG</name></proto>
+ <param><ptype>GLenum</ptype> <name>p</name></param>
+ <param len="4">const <ptype>GLfloat</ptype> *<name>eqn</name></param>
+ </command>
+ <command>
+ <proto>void <name>glClipPlanefOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>plane</name></param>
+ <param len="4">const <ptype>GLfloat</ptype> *<name>equation</name></param>
+ <glx type="render" opcode="4312"/>
+ </command>
+ <command>
+ <proto>void <name>glClipPlanex</name></proto>
+ <param><ptype>GLenum</ptype> <name>plane</name></param>
+ <param len="4">const <ptype>GLfixed</ptype> *<name>equation</name></param>
+ </command>
+ <command>
+ <proto>void <name>glClipPlanexIMG</name></proto>
+ <param><ptype>GLenum</ptype> <name>p</name></param>
+ <param len="4">const <ptype>GLfixed</ptype> *<name>eqn</name></param>
+ </command>
+ <command>
+ <proto>void <name>glClipPlanexOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>plane</name></param>
+ <param len="4">const <ptype>GLfixed</ptype> *<name>equation</name></param>
+ </command>
+ <command>
+ <proto>void <name>glColor3b</name></proto>
+ <param group="ColorB"><ptype>GLbyte</ptype> <name>red</name></param>
+ <param group="ColorB"><ptype>GLbyte</ptype> <name>green</name></param>
+ <param group="ColorB"><ptype>GLbyte</ptype> <name>blue</name></param>
+ <vecequiv name="glColor3bv"/>
+ </command>
+ <command>
+ <proto>void <name>glColor3bv</name></proto>
+ <param group="ColorB" len="3">const <ptype>GLbyte</ptype> *<name>v</name></param>
+ <glx type="render" opcode="6"/>
+ </command>
+ <command>
+ <proto>void <name>glColor3d</name></proto>
+ <param group="ColorD"><ptype>GLdouble</ptype> <name>red</name></param>
+ <param group="ColorD"><ptype>GLdouble</ptype> <name>green</name></param>
+ <param group="ColorD"><ptype>GLdouble</ptype> <name>blue</name></param>
+ <vecequiv name="glColor3dv"/>
+ </command>
+ <command>
+ <proto>void <name>glColor3dv</name></proto>
+ <param group="ColorD" len="3">const <ptype>GLdouble</ptype> *<name>v</name></param>
+ <glx type="render" opcode="7"/>
+ </command>
+ <command>
+ <proto>void <name>glColor3f</name></proto>
+ <param group="ColorF"><ptype>GLfloat</ptype> <name>red</name></param>
+ <param group="ColorF"><ptype>GLfloat</ptype> <name>green</name></param>
+ <param group="ColorF"><ptype>GLfloat</ptype> <name>blue</name></param>
+ <vecequiv name="glColor3fv"/>
+ </command>
+ <command>
+ <proto>void <name>glColor3fVertex3fSUN</name></proto>
+ <param><ptype>GLfloat</ptype> <name>r</name></param>
+ <param><ptype>GLfloat</ptype> <name>g</name></param>
+ <param><ptype>GLfloat</ptype> <name>b</name></param>
+ <param><ptype>GLfloat</ptype> <name>x</name></param>
+ <param><ptype>GLfloat</ptype> <name>y</name></param>
+ <param><ptype>GLfloat</ptype> <name>z</name></param>
+ </command>
+ <command>
+ <proto>void <name>glColor3fVertex3fvSUN</name></proto>
+ <param len="3">const <ptype>GLfloat</ptype> *<name>c</name></param>
+ <param len="3">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glColor3fv</name></proto>
+ <param group="ColorF" len="3">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ <glx type="render" opcode="8"/>
+ </command>
+ <command>
+ <proto>void <name>glColor3hNV</name></proto>
+ <param group="Half16NV"><ptype>GLhalfNV</ptype> <name>red</name></param>
+ <param group="Half16NV"><ptype>GLhalfNV</ptype> <name>green</name></param>
+ <param group="Half16NV"><ptype>GLhalfNV</ptype> <name>blue</name></param>
+ <vecequiv name="glColor3hvNV"/>
+ </command>
+ <command>
+ <proto>void <name>glColor3hvNV</name></proto>
+ <param group="Half16NV" len="3">const <ptype>GLhalfNV</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4244"/>
+ </command>
+ <command>
+ <proto>void <name>glColor3i</name></proto>
+ <param group="ColorI"><ptype>GLint</ptype> <name>red</name></param>
+ <param group="ColorI"><ptype>GLint</ptype> <name>green</name></param>
+ <param group="ColorI"><ptype>GLint</ptype> <name>blue</name></param>
+ <vecequiv name="glColor3iv"/>
+ </command>
+ <command>
+ <proto>void <name>glColor3iv</name></proto>
+ <param group="ColorI" len="3">const <ptype>GLint</ptype> *<name>v</name></param>
+ <glx type="render" opcode="9"/>
+ </command>
+ <command>
+ <proto>void <name>glColor3s</name></proto>
+ <param group="ColorS"><ptype>GLshort</ptype> <name>red</name></param>
+ <param group="ColorS"><ptype>GLshort</ptype> <name>green</name></param>
+ <param group="ColorS"><ptype>GLshort</ptype> <name>blue</name></param>
+ <vecequiv name="glColor3sv"/>
+ </command>
+ <command>
+ <proto>void <name>glColor3sv</name></proto>
+ <param group="ColorS" len="3">const <ptype>GLshort</ptype> *<name>v</name></param>
+ <glx type="render" opcode="10"/>
+ </command>
+ <command>
+ <proto>void <name>glColor3ub</name></proto>
+ <param group="ColorUB"><ptype>GLubyte</ptype> <name>red</name></param>
+ <param group="ColorUB"><ptype>GLubyte</ptype> <name>green</name></param>
+ <param group="ColorUB"><ptype>GLubyte</ptype> <name>blue</name></param>
+ <vecequiv name="glColor3ubv"/>
+ </command>
+ <command>
+ <proto>void <name>glColor3ubv</name></proto>
+ <param group="ColorUB" len="3">const <ptype>GLubyte</ptype> *<name>v</name></param>
+ <glx type="render" opcode="11"/>
+ </command>
+ <command>
+ <proto>void <name>glColor3ui</name></proto>
+ <param group="ColorUI"><ptype>GLuint</ptype> <name>red</name></param>
+ <param group="ColorUI"><ptype>GLuint</ptype> <name>green</name></param>
+ <param group="ColorUI"><ptype>GLuint</ptype> <name>blue</name></param>
+ <vecequiv name="glColor3uiv"/>
+ </command>
+ <command>
+ <proto>void <name>glColor3uiv</name></proto>
+ <param group="ColorUI" len="3">const <ptype>GLuint</ptype> *<name>v</name></param>
+ <glx type="render" opcode="12"/>
+ </command>
+ <command>
+ <proto>void <name>glColor3us</name></proto>
+ <param group="ColorUS"><ptype>GLushort</ptype> <name>red</name></param>
+ <param group="ColorUS"><ptype>GLushort</ptype> <name>green</name></param>
+ <param group="ColorUS"><ptype>GLushort</ptype> <name>blue</name></param>
+ <vecequiv name="glColor3usv"/>
+ </command>
+ <command>
+ <proto>void <name>glColor3usv</name></proto>
+ <param group="ColorUS" len="3">const <ptype>GLushort</ptype> *<name>v</name></param>
+ <glx type="render" opcode="13"/>
+ </command>
+ <command>
+ <proto>void <name>glColor3xOES</name></proto>
+ <param><ptype>GLfixed</ptype> <name>red</name></param>
+ <param><ptype>GLfixed</ptype> <name>green</name></param>
+ <param><ptype>GLfixed</ptype> <name>blue</name></param>
+ </command>
+ <command>
+ <proto>void <name>glColor3xvOES</name></proto>
+ <param len="3">const <ptype>GLfixed</ptype> *<name>components</name></param>
+ </command>
+ <command>
+ <proto>void <name>glColor4b</name></proto>
+ <param group="ColorB"><ptype>GLbyte</ptype> <name>red</name></param>
+ <param group="ColorB"><ptype>GLbyte</ptype> <name>green</name></param>
+ <param group="ColorB"><ptype>GLbyte</ptype> <name>blue</name></param>
+ <param group="ColorB"><ptype>GLbyte</ptype> <name>alpha</name></param>
+ <vecequiv name="glColor4bv"/>
+ </command>
+ <command>
+ <proto>void <name>glColor4bv</name></proto>
+ <param group="ColorB" len="4">const <ptype>GLbyte</ptype> *<name>v</name></param>
+ <glx type="render" opcode="14"/>
+ </command>
+ <command>
+ <proto>void <name>glColor4d</name></proto>
+ <param group="ColorD"><ptype>GLdouble</ptype> <name>red</name></param>
+ <param group="ColorD"><ptype>GLdouble</ptype> <name>green</name></param>
+ <param group="ColorD"><ptype>GLdouble</ptype> <name>blue</name></param>
+ <param group="ColorD"><ptype>GLdouble</ptype> <name>alpha</name></param>
+ <vecequiv name="glColor4dv"/>
+ </command>
+ <command>
+ <proto>void <name>glColor4dv</name></proto>
+ <param group="ColorD" len="4">const <ptype>GLdouble</ptype> *<name>v</name></param>
+ <glx type="render" opcode="15"/>
+ </command>
+ <command>
+ <proto>void <name>glColor4f</name></proto>
+ <param group="ColorF"><ptype>GLfloat</ptype> <name>red</name></param>
+ <param group="ColorF"><ptype>GLfloat</ptype> <name>green</name></param>
+ <param group="ColorF"><ptype>GLfloat</ptype> <name>blue</name></param>
+ <param group="ColorF"><ptype>GLfloat</ptype> <name>alpha</name></param>
+ <vecequiv name="glColor4fv"/>
+ </command>
+ <command>
+ <proto>void <name>glColor4fNormal3fVertex3fSUN</name></proto>
+ <param><ptype>GLfloat</ptype> <name>r</name></param>
+ <param><ptype>GLfloat</ptype> <name>g</name></param>
+ <param><ptype>GLfloat</ptype> <name>b</name></param>
+ <param><ptype>GLfloat</ptype> <name>a</name></param>
+ <param><ptype>GLfloat</ptype> <name>nx</name></param>
+ <param><ptype>GLfloat</ptype> <name>ny</name></param>
+ <param><ptype>GLfloat</ptype> <name>nz</name></param>
+ <param><ptype>GLfloat</ptype> <name>x</name></param>
+ <param><ptype>GLfloat</ptype> <name>y</name></param>
+ <param><ptype>GLfloat</ptype> <name>z</name></param>
+ </command>
+ <command>
+ <proto>void <name>glColor4fNormal3fVertex3fvSUN</name></proto>
+ <param len="4">const <ptype>GLfloat</ptype> *<name>c</name></param>
+ <param len="3">const <ptype>GLfloat</ptype> *<name>n</name></param>
+ <param len="3">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glColor4fv</name></proto>
+ <param group="ColorF" len="4">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ <glx type="render" opcode="16"/>
+ </command>
+ <command>
+ <proto>void <name>glColor4hNV</name></proto>
+ <param group="Half16NV"><ptype>GLhalfNV</ptype> <name>red</name></param>
+ <param group="Half16NV"><ptype>GLhalfNV</ptype> <name>green</name></param>
+ <param group="Half16NV"><ptype>GLhalfNV</ptype> <name>blue</name></param>
+ <param group="Half16NV"><ptype>GLhalfNV</ptype> <name>alpha</name></param>
+ <vecequiv name="glColor4hvNV"/>
+ </command>
+ <command>
+ <proto>void <name>glColor4hvNV</name></proto>
+ <param group="Half16NV" len="4">const <ptype>GLhalfNV</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4245"/>
+ </command>
+ <command>
+ <proto>void <name>glColor4i</name></proto>
+ <param group="ColorI"><ptype>GLint</ptype> <name>red</name></param>
+ <param group="ColorI"><ptype>GLint</ptype> <name>green</name></param>
+ <param group="ColorI"><ptype>GLint</ptype> <name>blue</name></param>
+ <param group="ColorI"><ptype>GLint</ptype> <name>alpha</name></param>
+ <vecequiv name="glColor4iv"/>
+ </command>
+ <command>
+ <proto>void <name>glColor4iv</name></proto>
+ <param group="ColorI" len="4">const <ptype>GLint</ptype> *<name>v</name></param>
+ <glx type="render" opcode="17"/>
+ </command>
+ <command>
+ <proto>void <name>glColor4s</name></proto>
+ <param group="ColorS"><ptype>GLshort</ptype> <name>red</name></param>
+ <param group="ColorS"><ptype>GLshort</ptype> <name>green</name></param>
+ <param group="ColorS"><ptype>GLshort</ptype> <name>blue</name></param>
+ <param group="ColorS"><ptype>GLshort</ptype> <name>alpha</name></param>
+ <vecequiv name="glColor4sv"/>
+ </command>
+ <command>
+ <proto>void <name>glColor4sv</name></proto>
+ <param group="ColorS" len="4">const <ptype>GLshort</ptype> *<name>v</name></param>
+ <glx type="render" opcode="18"/>
+ </command>
+ <command>
+ <proto>void <name>glColor4ub</name></proto>
+ <param group="ColorUB"><ptype>GLubyte</ptype> <name>red</name></param>
+ <param group="ColorUB"><ptype>GLubyte</ptype> <name>green</name></param>
+ <param group="ColorUB"><ptype>GLubyte</ptype> <name>blue</name></param>
+ <param group="ColorUB"><ptype>GLubyte</ptype> <name>alpha</name></param>
+ <vecequiv name="glColor4ubv"/>
+ </command>
+ <command>
+ <proto>void <name>glColor4ubVertex2fSUN</name></proto>
+ <param><ptype>GLubyte</ptype> <name>r</name></param>
+ <param><ptype>GLubyte</ptype> <name>g</name></param>
+ <param><ptype>GLubyte</ptype> <name>b</name></param>
+ <param><ptype>GLubyte</ptype> <name>a</name></param>
+ <param><ptype>GLfloat</ptype> <name>x</name></param>
+ <param><ptype>GLfloat</ptype> <name>y</name></param>
+ </command>
+ <command>
+ <proto>void <name>glColor4ubVertex2fvSUN</name></proto>
+ <param len="4">const <ptype>GLubyte</ptype> *<name>c</name></param>
+ <param len="2">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glColor4ubVertex3fSUN</name></proto>
+ <param><ptype>GLubyte</ptype> <name>r</name></param>
+ <param><ptype>GLubyte</ptype> <name>g</name></param>
+ <param><ptype>GLubyte</ptype> <name>b</name></param>
+ <param><ptype>GLubyte</ptype> <name>a</name></param>
+ <param><ptype>GLfloat</ptype> <name>x</name></param>
+ <param><ptype>GLfloat</ptype> <name>y</name></param>
+ <param><ptype>GLfloat</ptype> <name>z</name></param>
+ </command>
+ <command>
+ <proto>void <name>glColor4ubVertex3fvSUN</name></proto>
+ <param len="4">const <ptype>GLubyte</ptype> *<name>c</name></param>
+ <param len="3">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glColor4ubv</name></proto>
+ <param group="ColorUB" len="4">const <ptype>GLubyte</ptype> *<name>v</name></param>
+ <glx type="render" opcode="19"/>
+ </command>
+ <command>
+ <proto>void <name>glColor4ui</name></proto>
+ <param group="ColorUI"><ptype>GLuint</ptype> <name>red</name></param>
+ <param group="ColorUI"><ptype>GLuint</ptype> <name>green</name></param>
+ <param group="ColorUI"><ptype>GLuint</ptype> <name>blue</name></param>
+ <param group="ColorUI"><ptype>GLuint</ptype> <name>alpha</name></param>
+ <vecequiv name="glColor4uiv"/>
+ </command>
+ <command>
+ <proto>void <name>glColor4uiv</name></proto>
+ <param group="ColorUI" len="4">const <ptype>GLuint</ptype> *<name>v</name></param>
+ <glx type="render" opcode="20"/>
+ </command>
+ <command>
+ <proto>void <name>glColor4us</name></proto>
+ <param group="ColorUS"><ptype>GLushort</ptype> <name>red</name></param>
+ <param group="ColorUS"><ptype>GLushort</ptype> <name>green</name></param>
+ <param group="ColorUS"><ptype>GLushort</ptype> <name>blue</name></param>
+ <param group="ColorUS"><ptype>GLushort</ptype> <name>alpha</name></param>
+ <vecequiv name="glColor4usv"/>
+ </command>
+ <command>
+ <proto>void <name>glColor4usv</name></proto>
+ <param group="ColorUS" len="4">const <ptype>GLushort</ptype> *<name>v</name></param>
+ <glx type="render" opcode="21"/>
+ </command>
+ <command>
+ <proto>void <name>glColor4x</name></proto>
+ <param><ptype>GLfixed</ptype> <name>red</name></param>
+ <param><ptype>GLfixed</ptype> <name>green</name></param>
+ <param><ptype>GLfixed</ptype> <name>blue</name></param>
+ <param><ptype>GLfixed</ptype> <name>alpha</name></param>
+ </command>
+ <command>
+ <proto>void <name>glColor4xOES</name></proto>
+ <param><ptype>GLfixed</ptype> <name>red</name></param>
+ <param><ptype>GLfixed</ptype> <name>green</name></param>
+ <param><ptype>GLfixed</ptype> <name>blue</name></param>
+ <param><ptype>GLfixed</ptype> <name>alpha</name></param>
+ </command>
+ <command>
+ <proto>void <name>glColor4xvOES</name></proto>
+ <param len="4">const <ptype>GLfixed</ptype> *<name>components</name></param>
+ </command>
+ <command>
+ <proto>void <name>glColorFormatNV</name></proto>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ </command>
+ <command>
+ <proto>void <name>glColorFragmentOp1ATI</name></proto>
+ <param group="FragmentOpATI"><ptype>GLenum</ptype> <name>op</name></param>
+ <param><ptype>GLuint</ptype> <name>dst</name></param>
+ <param><ptype>GLuint</ptype> <name>dstMask</name></param>
+ <param><ptype>GLuint</ptype> <name>dstMod</name></param>
+ <param><ptype>GLuint</ptype> <name>arg1</name></param>
+ <param><ptype>GLuint</ptype> <name>arg1Rep</name></param>
+ <param><ptype>GLuint</ptype> <name>arg1Mod</name></param>
+ </command>
+ <command>
+ <proto>void <name>glColorFragmentOp2ATI</name></proto>
+ <param group="FragmentOpATI"><ptype>GLenum</ptype> <name>op</name></param>
+ <param><ptype>GLuint</ptype> <name>dst</name></param>
+ <param><ptype>GLuint</ptype> <name>dstMask</name></param>
+ <param><ptype>GLuint</ptype> <name>dstMod</name></param>
+ <param><ptype>GLuint</ptype> <name>arg1</name></param>
+ <param><ptype>GLuint</ptype> <name>arg1Rep</name></param>
+ <param><ptype>GLuint</ptype> <name>arg1Mod</name></param>
+ <param><ptype>GLuint</ptype> <name>arg2</name></param>
+ <param><ptype>GLuint</ptype> <name>arg2Rep</name></param>
+ <param><ptype>GLuint</ptype> <name>arg2Mod</name></param>
+ </command>
+ <command>
+ <proto>void <name>glColorFragmentOp3ATI</name></proto>
+ <param group="FragmentOpATI"><ptype>GLenum</ptype> <name>op</name></param>
+ <param><ptype>GLuint</ptype> <name>dst</name></param>
+ <param><ptype>GLuint</ptype> <name>dstMask</name></param>
+ <param><ptype>GLuint</ptype> <name>dstMod</name></param>
+ <param><ptype>GLuint</ptype> <name>arg1</name></param>
+ <param><ptype>GLuint</ptype> <name>arg1Rep</name></param>
+ <param><ptype>GLuint</ptype> <name>arg1Mod</name></param>
+ <param><ptype>GLuint</ptype> <name>arg2</name></param>
+ <param><ptype>GLuint</ptype> <name>arg2Rep</name></param>
+ <param><ptype>GLuint</ptype> <name>arg2Mod</name></param>
+ <param><ptype>GLuint</ptype> <name>arg3</name></param>
+ <param><ptype>GLuint</ptype> <name>arg3Rep</name></param>
+ <param><ptype>GLuint</ptype> <name>arg3Mod</name></param>
+ </command>
+ <command>
+ <proto>void <name>glColorMask</name></proto>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>red</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>green</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>blue</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>alpha</name></param>
+ <glx type="render" opcode="134"/>
+ </command>
+ <command>
+ <proto>void <name>glColorMaskIndexedEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>r</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>g</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>b</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>a</name></param>
+ <alias name="glColorMaski"/>
+ </command>
+ <command>
+ <proto>void <name>glColorMaski</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>r</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>g</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>b</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>a</name></param>
+ </command>
+ <command>
+ <proto>void <name>glColorMaskiEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>r</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>g</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>b</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>a</name></param>
+ <alias name="glColorMaski"/>
+ </command>
+ <command>
+ <proto>void <name>glColorMaterial</name></proto>
+ <param group="MaterialFace"><ptype>GLenum</ptype> <name>face</name></param>
+ <param group="ColorMaterialParameter"><ptype>GLenum</ptype> <name>mode</name></param>
+ <glx type="render" opcode="78"/>
+ </command>
+ <command>
+ <proto>void <name>glColorP3ui</name></proto>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLuint</ptype> <name>color</name></param>
+ </command>
+ <command>
+ <proto>void <name>glColorP3uiv</name></proto>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="1">const <ptype>GLuint</ptype> *<name>color</name></param>
+ </command>
+ <command>
+ <proto>void <name>glColorP4ui</name></proto>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLuint</ptype> <name>color</name></param>
+ </command>
+ <command>
+ <proto>void <name>glColorP4uiv</name></proto>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="1">const <ptype>GLuint</ptype> *<name>color</name></param>
+ </command>
+ <command>
+ <proto>void <name>glColorPointer</name></proto>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param group="ColorPointerType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ <param len="COMPSIZE(size,type,stride)">const void *<name>pointer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glColorPointerEXT</name></proto>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param group="ColorPointerType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="COMPSIZE(size,type,stride,count)">const void *<name>pointer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glColorPointerListIBM</name></proto>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param group="ColorPointerType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLint</ptype> <name>stride</name></param>
+ <param len="COMPSIZE(size,type,stride)">const void **<name>pointer</name></param>
+ <param><ptype>GLint</ptype> <name>ptrstride</name></param>
+ </command>
+ <command>
+ <proto>void <name>glColorPointervINTEL</name></proto>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param group="VertexPointerType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="4">const void **<name>pointer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glColorSubTable</name></proto>
+ <param group="ColorTableTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLsizei</ptype> <name>start</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param group="PixelType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(format,type,count)">const void *<name>data</name></param>
+ <glx type="render" opcode="195"/>
+ <glx type="render" opcode="312" name="glColorSubTablePBO" comment="PBO protocol"/>
+ </command>
+ <command>
+ <proto>void <name>glColorSubTableEXT</name></proto>
+ <param group="ColorTableTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLsizei</ptype> <name>start</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param group="PixelType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(format,type,count)">const void *<name>data</name></param>
+ <alias name="glColorSubTable"/>
+ </command>
+ <command>
+ <proto>void <name>glColorTable</name></proto>
+ <param group="ColorTableTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="PixelInternalFormat"><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param group="PixelType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(format,type,width)">const void *<name>table</name></param>
+ <glx type="render" opcode="2053"/>
+ <glx type="render" opcode="313" name="glColorTablePBO" comment="PBO protocol"/>
+ </command>
+ <command>
+ <proto>void <name>glColorTableEXT</name></proto>
+ <param group="ColorTableTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="PixelInternalFormat"><ptype>GLenum</ptype> <name>internalFormat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param group="PixelType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(format,type,width)">const void *<name>table</name></param>
+ <alias name="glColorTable"/>
+ </command>
+ <command>
+ <proto>void <name>glColorTableParameterfv</name></proto>
+ <param group="ColorTableTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="ColorTableParameterPName"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedFloat32" len="COMPSIZE(pname)">const <ptype>GLfloat</ptype> *<name>params</name></param>
+ <glx type="render" opcode="2054"/>
+ </command>
+ <command>
+ <proto>void <name>glColorTableParameterfvSGI</name></proto>
+ <param group="ColorTableTargetSGI"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="ColorTableParameterPNameSGI"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedFloat32" len="COMPSIZE(pname)">const <ptype>GLfloat</ptype> *<name>params</name></param>
+ <alias name="glColorTableParameterfv"/>
+ <glx type="render" opcode="2054"/>
+ </command>
+ <command>
+ <proto>void <name>glColorTableParameteriv</name></proto>
+ <param group="ColorTableTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="ColorTableParameterPName"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedInt32" len="COMPSIZE(pname)">const <ptype>GLint</ptype> *<name>params</name></param>
+ <glx type="render" opcode="2055"/>
+ </command>
+ <command>
+ <proto>void <name>glColorTableParameterivSGI</name></proto>
+ <param group="ColorTableTargetSGI"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="ColorTableParameterPNameSGI"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedInt32" len="COMPSIZE(pname)">const <ptype>GLint</ptype> *<name>params</name></param>
+ <alias name="glColorTableParameteriv"/>
+ <glx type="render" opcode="2055"/>
+ </command>
+ <command>
+ <proto>void <name>glColorTableSGI</name></proto>
+ <param group="ColorTableTargetSGI"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="PixelInternalFormat"><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param group="PixelType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(format,type,width)">const void *<name>table</name></param>
+ <alias name="glColorTable"/>
+ <glx type="render" opcode="2053"/>
+ </command>
+ <command>
+ <proto>void <name>glCombinerInputNV</name></proto>
+ <param group="CombinerStageNV"><ptype>GLenum</ptype> <name>stage</name></param>
+ <param group="CombinerPortionNV"><ptype>GLenum</ptype> <name>portion</name></param>
+ <param group="CombinerVariableNV"><ptype>GLenum</ptype> <name>variable</name></param>
+ <param group="CombinerRegisterNV"><ptype>GLenum</ptype> <name>input</name></param>
+ <param group="CombinerMappingNV"><ptype>GLenum</ptype> <name>mapping</name></param>
+ <param group="CombinerComponentUsageNV"><ptype>GLenum</ptype> <name>componentUsage</name></param>
+ <glx type="render" opcode="4140"/>
+ </command>
+ <command>
+ <proto>void <name>glCombinerOutputNV</name></proto>
+ <param group="CombinerStageNV"><ptype>GLenum</ptype> <name>stage</name></param>
+ <param group="CombinerPortionNV"><ptype>GLenum</ptype> <name>portion</name></param>
+ <param group="CombinerRegisterNV"><ptype>GLenum</ptype> <name>abOutput</name></param>
+ <param group="CombinerRegisterNV"><ptype>GLenum</ptype> <name>cdOutput</name></param>
+ <param group="CombinerRegisterNV"><ptype>GLenum</ptype> <name>sumOutput</name></param>
+ <param group="CombinerScaleNV"><ptype>GLenum</ptype> <name>scale</name></param>
+ <param group="CombinerBiasNV"><ptype>GLenum</ptype> <name>bias</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>abDotProduct</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>cdDotProduct</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>muxSum</name></param>
+ <glx type="render" opcode="4141"/>
+ </command>
+ <command>
+ <proto>void <name>glCombinerParameterfNV</name></proto>
+ <param group="CombinerParameterNV"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLfloat</ptype> <name>param</name></param>
+ <glx type="render" opcode="4136"/>
+ </command>
+ <command>
+ <proto>void <name>glCombinerParameterfvNV</name></proto>
+ <param group="CombinerParameterNV"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedFloat32" len="COMPSIZE(pname)">const <ptype>GLfloat</ptype> *<name>params</name></param>
+ <glx type="render" opcode="4137"/>
+ </command>
+ <command>
+ <proto>void <name>glCombinerParameteriNV</name></proto>
+ <param group="CombinerParameterNV"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLint</ptype> <name>param</name></param>
+ <glx type="render" opcode="4138"/>
+ </command>
+ <command>
+ <proto>void <name>glCombinerParameterivNV</name></proto>
+ <param group="CombinerParameterNV"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedInt32" len="COMPSIZE(pname)">const <ptype>GLint</ptype> *<name>params</name></param>
+ <glx type="render" opcode="4139"/>
+ </command>
+ <command>
+ <proto>void <name>glCombinerStageParameterfvNV</name></proto>
+ <param group="CombinerStageNV"><ptype>GLenum</ptype> <name>stage</name></param>
+ <param group="CombinerParameterNV"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedFloat32" len="COMPSIZE(pname)">const <ptype>GLfloat</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glCompileShader</name></proto>
+ <param><ptype>GLuint</ptype> <name>shader</name></param>
+ </command>
+ <command>
+ <proto>void <name>glCompileShaderARB</name></proto>
+ <param group="handleARB"><ptype>GLhandleARB</ptype> <name>shaderObj</name></param>
+ <alias name="glCompileShader"/>
+ </command>
+ <command>
+ <proto>void <name>glCompileShaderIncludeARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>shader</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count">const <ptype>GLchar</ptype> *const*<name>path</name></param>
+ <param len="count">const <ptype>GLint</ptype> *<name>length</name></param>
+ </command>
+ <command>
+ <proto>void <name>glCompressedMultiTexImage1DEXT</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>texunit</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="TextureInternalFormat"><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>border</name></param>
+ <param><ptype>GLsizei</ptype> <name>imageSize</name></param>
+ <param len="imageSize">const void *<name>bits</name></param>
+ </command>
+ <command>
+ <proto>void <name>glCompressedMultiTexImage2DEXT</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>texunit</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="TextureInternalFormat"><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>border</name></param>
+ <param><ptype>GLsizei</ptype> <name>imageSize</name></param>
+ <param len="imageSize">const void *<name>bits</name></param>
+ </command>
+ <command>
+ <proto>void <name>glCompressedMultiTexImage3DEXT</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>texunit</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="TextureInternalFormat"><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param><ptype>GLsizei</ptype> <name>depth</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>border</name></param>
+ <param><ptype>GLsizei</ptype> <name>imageSize</name></param>
+ <param len="imageSize">const void *<name>bits</name></param>
+ </command>
+ <command>
+ <proto>void <name>glCompressedMultiTexSubImage1DEXT</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>texunit</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>xoffset</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param><ptype>GLsizei</ptype> <name>imageSize</name></param>
+ <param len="imageSize">const void *<name>bits</name></param>
+ </command>
+ <command>
+ <proto>void <name>glCompressedMultiTexSubImage2DEXT</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>texunit</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>xoffset</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>yoffset</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param><ptype>GLsizei</ptype> <name>imageSize</name></param>
+ <param len="imageSize">const void *<name>bits</name></param>
+ </command>
+ <command>
+ <proto>void <name>glCompressedMultiTexSubImage3DEXT</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>texunit</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>xoffset</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>yoffset</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>zoffset</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param><ptype>GLsizei</ptype> <name>depth</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param><ptype>GLsizei</ptype> <name>imageSize</name></param>
+ <param len="imageSize">const void *<name>bits</name></param>
+ </command>
+ <command>
+ <proto>void <name>glCompressedTexImage1D</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="PixelInternalFormat"><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>border</name></param>
+ <param><ptype>GLsizei</ptype> <name>imageSize</name></param>
+ <param group="CompressedTextureARB" len="imageSize">const void *<name>data</name></param>
+ <glx type="render" opcode="214"/>
+ <glx type="render" opcode="314" name="glCompressedTexImage1DPBO" comment="PBO protocol"/>
+ </command>
+ <command>
+ <proto>void <name>glCompressedTexImage1DARB</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="PixelInternalFormat"><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>border</name></param>
+ <param><ptype>GLsizei</ptype> <name>imageSize</name></param>
+ <param group="CompressedTextureARB" len="imageSize">const void *<name>data</name></param>
+ <alias name="glCompressedTexImage1D"/>
+ <glx type="render" opcode="214"/>
+ </command>
+ <command>
+ <proto>void <name>glCompressedTexImage2D</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="PixelInternalFormat"><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>border</name></param>
+ <param><ptype>GLsizei</ptype> <name>imageSize</name></param>
+ <param group="CompressedTextureARB" len="imageSize">const void *<name>data</name></param>
+ <glx type="render" opcode="215"/>
+ <glx type="render" opcode="315" name="glCompressedTexImage2DPBO" comment="PBO protocol"/>
+ </command>
+ <command>
+ <proto>void <name>glCompressedTexImage2DARB</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="PixelInternalFormat"><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>border</name></param>
+ <param><ptype>GLsizei</ptype> <name>imageSize</name></param>
+ <param group="CompressedTextureARB" len="imageSize">const void *<name>data</name></param>
+ <alias name="glCompressedTexImage2D"/>
+ <glx type="render" opcode="215"/>
+ </command>
+ <command>
+ <proto>void <name>glCompressedTexImage3D</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="PixelInternalFormat"><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param><ptype>GLsizei</ptype> <name>depth</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>border</name></param>
+ <param><ptype>GLsizei</ptype> <name>imageSize</name></param>
+ <param group="CompressedTextureARB" len="imageSize">const void *<name>data</name></param>
+ <glx type="render" opcode="216"/>
+ <glx type="render" opcode="316" name="glCompressedTexImage3DPBO" comment="PBO protocol"/>
+ </command>
+ <command>
+ <proto>void <name>glCompressedTexImage3DARB</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="PixelInternalFormat"><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param><ptype>GLsizei</ptype> <name>depth</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>border</name></param>
+ <param><ptype>GLsizei</ptype> <name>imageSize</name></param>
+ <param group="CompressedTextureARB" len="imageSize">const void *<name>data</name></param>
+ <alias name="glCompressedTexImage3D"/>
+ <glx type="render" opcode="216"/>
+ </command>
+ <command>
+ <proto>void <name>glCompressedTexImage3DOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLint</ptype> <name>level</name></param>
+ <param><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param><ptype>GLsizei</ptype> <name>depth</name></param>
+ <param><ptype>GLint</ptype> <name>border</name></param>
+ <param><ptype>GLsizei</ptype> <name>imageSize</name></param>
+ <param len="imageSize">const void *<name>data</name></param>
+ <alias name="glCompressedTexImage3D"/>
+ </command>
+ <command>
+ <proto>void <name>glCompressedTexSubImage1D</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>xoffset</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param><ptype>GLsizei</ptype> <name>imageSize</name></param>
+ <param group="CompressedTextureARB" len="imageSize">const void *<name>data</name></param>
+ <glx type="render" opcode="217"/>
+ <glx type="render" opcode="317" name="glCompressedTexSubImage1DPBO" comment="PBO protocol"/>
+ </command>
+ <command>
+ <proto>void <name>glCompressedTexSubImage1DARB</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>xoffset</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param><ptype>GLsizei</ptype> <name>imageSize</name></param>
+ <param group="CompressedTextureARB" len="imageSize">const void *<name>data</name></param>
+ <alias name="glCompressedTexSubImage1D"/>
+ <glx type="render" opcode="217"/>
+ </command>
+ <command>
+ <proto>void <name>glCompressedTexSubImage2D</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>xoffset</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>yoffset</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param><ptype>GLsizei</ptype> <name>imageSize</name></param>
+ <param group="CompressedTextureARB" len="imageSize">const void *<name>data</name></param>
+ <glx type="render" opcode="218"/>
+ <glx type="render" opcode="318" name="glCompressedTexSubImage2DPBO" comment="PBO protocol"/>
+ </command>
+ <command>
+ <proto>void <name>glCompressedTexSubImage2DARB</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>xoffset</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>yoffset</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param><ptype>GLsizei</ptype> <name>imageSize</name></param>
+ <param group="CompressedTextureARB" len="imageSize">const void *<name>data</name></param>
+ <alias name="glCompressedTexSubImage2D"/>
+ <glx type="render" opcode="218"/>
+ </command>
+ <command>
+ <proto>void <name>glCompressedTexSubImage3D</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>xoffset</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>yoffset</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>zoffset</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param><ptype>GLsizei</ptype> <name>depth</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param><ptype>GLsizei</ptype> <name>imageSize</name></param>
+ <param group="CompressedTextureARB" len="imageSize">const void *<name>data</name></param>
+ <glx type="render" opcode="219"/>
+ <glx type="render" opcode="319" name="glCompressedTexSubImage3DPBO" comment="PBO protocol"/>
+ </command>
+ <command>
+ <proto>void <name>glCompressedTexSubImage3DARB</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>xoffset</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>yoffset</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>zoffset</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param><ptype>GLsizei</ptype> <name>depth</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param><ptype>GLsizei</ptype> <name>imageSize</name></param>
+ <param group="CompressedTextureARB" len="imageSize">const void *<name>data</name></param>
+ <alias name="glCompressedTexSubImage3D"/>
+ <glx type="render" opcode="219"/>
+ </command>
+ <command>
+ <proto>void <name>glCompressedTexSubImage3DOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLint</ptype> <name>level</name></param>
+ <param><ptype>GLint</ptype> <name>xoffset</name></param>
+ <param><ptype>GLint</ptype> <name>yoffset</name></param>
+ <param><ptype>GLint</ptype> <name>zoffset</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param><ptype>GLsizei</ptype> <name>depth</name></param>
+ <param><ptype>GLenum</ptype> <name>format</name></param>
+ <param><ptype>GLsizei</ptype> <name>imageSize</name></param>
+ <param len="imageSize">const void *<name>data</name></param>
+ <alias name="glCompressedTexSubImage3D"/>
+ </command>
+ <command>
+ <proto>void <name>glCompressedTextureImage1DEXT</name></proto>
+ <param group="Texture"><ptype>GLuint</ptype> <name>texture</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="TextureInternalFormat"><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>border</name></param>
+ <param><ptype>GLsizei</ptype> <name>imageSize</name></param>
+ <param len="imageSize">const void *<name>bits</name></param>
+ </command>
+ <command>
+ <proto>void <name>glCompressedTextureImage2DEXT</name></proto>
+ <param group="Texture"><ptype>GLuint</ptype> <name>texture</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="TextureInternalFormat"><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>border</name></param>
+ <param><ptype>GLsizei</ptype> <name>imageSize</name></param>
+ <param len="imageSize">const void *<name>bits</name></param>
+ </command>
+ <command>
+ <proto>void <name>glCompressedTextureImage3DEXT</name></proto>
+ <param group="Texture"><ptype>GLuint</ptype> <name>texture</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="TextureInternalFormat"><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param><ptype>GLsizei</ptype> <name>depth</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>border</name></param>
+ <param><ptype>GLsizei</ptype> <name>imageSize</name></param>
+ <param len="imageSize">const void *<name>bits</name></param>
+ </command>
+ <command>
+ <proto>void <name>glCompressedTextureSubImage1D</name></proto>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLint</ptype> <name>level</name></param>
+ <param><ptype>GLint</ptype> <name>xoffset</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLenum</ptype> <name>format</name></param>
+ <param><ptype>GLsizei</ptype> <name>imageSize</name></param>
+ <param>const void *<name>data</name></param>
+ </command>
+ <command>
+ <proto>void <name>glCompressedTextureSubImage1DEXT</name></proto>
+ <param group="Texture"><ptype>GLuint</ptype> <name>texture</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>xoffset</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param><ptype>GLsizei</ptype> <name>imageSize</name></param>
+ <param len="imageSize">const void *<name>bits</name></param>
+ </command>
+ <command>
+ <proto>void <name>glCompressedTextureSubImage2D</name></proto>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLint</ptype> <name>level</name></param>
+ <param><ptype>GLint</ptype> <name>xoffset</name></param>
+ <param><ptype>GLint</ptype> <name>yoffset</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param><ptype>GLenum</ptype> <name>format</name></param>
+ <param><ptype>GLsizei</ptype> <name>imageSize</name></param>
+ <param>const void *<name>data</name></param>
+ </command>
+ <command>
+ <proto>void <name>glCompressedTextureSubImage2DEXT</name></proto>
+ <param group="Texture"><ptype>GLuint</ptype> <name>texture</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>xoffset</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>yoffset</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param><ptype>GLsizei</ptype> <name>imageSize</name></param>
+ <param len="imageSize">const void *<name>bits</name></param>
+ </command>
+ <command>
+ <proto>void <name>glCompressedTextureSubImage3D</name></proto>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLint</ptype> <name>level</name></param>
+ <param><ptype>GLint</ptype> <name>xoffset</name></param>
+ <param><ptype>GLint</ptype> <name>yoffset</name></param>
+ <param><ptype>GLint</ptype> <name>zoffset</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param><ptype>GLsizei</ptype> <name>depth</name></param>
+ <param><ptype>GLenum</ptype> <name>format</name></param>
+ <param><ptype>GLsizei</ptype> <name>imageSize</name></param>
+ <param>const void *<name>data</name></param>
+ </command>
+ <command>
+ <proto>void <name>glCompressedTextureSubImage3DEXT</name></proto>
+ <param group="Texture"><ptype>GLuint</ptype> <name>texture</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>xoffset</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>yoffset</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>zoffset</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param><ptype>GLsizei</ptype> <name>depth</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param><ptype>GLsizei</ptype> <name>imageSize</name></param>
+ <param len="imageSize">const void *<name>bits</name></param>
+ </command>
+ <command>
+ <proto>void <name>glConvolutionFilter1D</name></proto>
+ <param group="ConvolutionTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="PixelInternalFormat"><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param group="PixelType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(format,type,width)">const void *<name>image</name></param>
+ <glx type="render" opcode="4101"/>
+ <glx type="render" opcode="320" name="glConvolutionFilter1DPBO" comment="PBO protocol"/>
+ </command>
+ <command>
+ <proto>void <name>glConvolutionFilter1DEXT</name></proto>
+ <param group="ConvolutionTargetEXT"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="PixelInternalFormat"><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param group="PixelType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(format,type,width)">const void *<name>image</name></param>
+ <alias name="glConvolutionFilter1D"/>
+ <glx type="render" opcode="4101"/>
+ </command>
+ <command>
+ <proto>void <name>glConvolutionFilter2D</name></proto>
+ <param group="ConvolutionTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="PixelInternalFormat"><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param group="PixelType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(format,type,width,height)">const void *<name>image</name></param>
+ <glx type="render" opcode="4102"/>
+ <glx type="render" opcode="321" name="glConvolutionFilter2DPBO" comment="PBO protocol"/>
+ </command>
+ <command>
+ <proto>void <name>glConvolutionFilter2DEXT</name></proto>
+ <param group="ConvolutionTargetEXT"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="PixelInternalFormat"><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param group="PixelType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(format,type,width,height)">const void *<name>image</name></param>
+ <alias name="glConvolutionFilter2D"/>
+ <glx type="render" opcode="4102"/>
+ </command>
+ <command>
+ <proto>void <name>glConvolutionParameterf</name></proto>
+ <param group="ConvolutionTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="ConvolutionParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedFloat32"><ptype>GLfloat</ptype> <name>params</name></param>
+ <glx type="render" opcode="4103"/>
+ </command>
+ <command>
+ <proto>void <name>glConvolutionParameterfEXT</name></proto>
+ <param group="ConvolutionTargetEXT"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="ConvolutionParameterEXT"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedFloat32"><ptype>GLfloat</ptype> <name>params</name></param>
+ <alias name="glConvolutionParameterf"/>
+ <glx type="render" opcode="4103"/>
+ </command>
+ <command>
+ <proto>void <name>glConvolutionParameterfv</name></proto>
+ <param group="ConvolutionTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="ConvolutionParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedFloat32" len="COMPSIZE(pname)">const <ptype>GLfloat</ptype> *<name>params</name></param>
+ <glx type="render" opcode="4104"/>
+ </command>
+ <command>
+ <proto>void <name>glConvolutionParameterfvEXT</name></proto>
+ <param group="ConvolutionTargetEXT"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="ConvolutionParameterEXT"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedFloat32" len="COMPSIZE(pname)">const <ptype>GLfloat</ptype> *<name>params</name></param>
+ <alias name="glConvolutionParameterfv"/>
+ <glx type="render" opcode="4104"/>
+ </command>
+ <command>
+ <proto>void <name>glConvolutionParameteri</name></proto>
+ <param group="ConvolutionTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="ConvolutionParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>params</name></param>
+ <glx type="render" opcode="4105"/>
+ </command>
+ <command>
+ <proto>void <name>glConvolutionParameteriEXT</name></proto>
+ <param group="ConvolutionTargetEXT"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="ConvolutionParameterEXT"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>params</name></param>
+ <alias name="glConvolutionParameteri"/>
+ <glx type="render" opcode="4105"/>
+ </command>
+ <command>
+ <proto>void <name>glConvolutionParameteriv</name></proto>
+ <param group="ConvolutionTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="ConvolutionParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedInt32" len="COMPSIZE(pname)">const <ptype>GLint</ptype> *<name>params</name></param>
+ <glx type="render" opcode="4106"/>
+ </command>
+ <command>
+ <proto>void <name>glConvolutionParameterivEXT</name></proto>
+ <param group="ConvolutionTargetEXT"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="ConvolutionParameterEXT"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedInt32" len="COMPSIZE(pname)">const <ptype>GLint</ptype> *<name>params</name></param>
+ <alias name="glConvolutionParameteriv"/>
+ <glx type="render" opcode="4106"/>
+ </command>
+ <command>
+ <proto>void <name>glConvolutionParameterxOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLfixed</ptype> <name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glConvolutionParameterxvOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)">const <ptype>GLfixed</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glCopyBufferSubData</name></proto>
+ <param><ptype>GLenum</ptype> <name>readTarget</name></param>
+ <param><ptype>GLenum</ptype> <name>writeTarget</name></param>
+ <param group="BufferOffset"><ptype>GLintptr</ptype> <name>readOffset</name></param>
+ <param group="BufferOffset"><ptype>GLintptr</ptype> <name>writeOffset</name></param>
+ <param group="BufferSize"><ptype>GLsizeiptr</ptype> <name>size</name></param>
+ </command>
+ <command>
+ <proto>void <name>glCopyBufferSubDataNV</name></proto>
+ <param><ptype>GLenum</ptype> <name>readTarget</name></param>
+ <param><ptype>GLenum</ptype> <name>writeTarget</name></param>
+ <param group="BufferOffset"><ptype>GLintptr</ptype> <name>readOffset</name></param>
+ <param group="BufferOffset"><ptype>GLintptr</ptype> <name>writeOffset</name></param>
+ <param group="BufferSize"><ptype>GLsizeiptr</ptype> <name>size</name></param>
+ <alias name="glCopyBufferSubData"/>
+ </command>
+ <command>
+ <proto>void <name>glCopyColorSubTable</name></proto>
+ <param group="ColorTableTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLsizei</ptype> <name>start</name></param>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>x</name></param>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>y</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <glx type="render" opcode="196"/>
+ </command>
+ <command>
+ <proto>void <name>glCopyColorSubTableEXT</name></proto>
+ <param group="ColorTableTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLsizei</ptype> <name>start</name></param>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>x</name></param>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>y</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <alias name="glCopyColorSubTable"/>
+ </command>
+ <command>
+ <proto>void <name>glCopyColorTable</name></proto>
+ <param group="ColorTableTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="PixelInternalFormat"><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>x</name></param>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>y</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <glx type="render" opcode="2056"/>
+ </command>
+ <command>
+ <proto>void <name>glCopyColorTableSGI</name></proto>
+ <param group="ColorTableTargetSGI"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="PixelInternalFormat"><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>x</name></param>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>y</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <alias name="glCopyColorTable"/>
+ <glx type="render" opcode="2056"/>
+ </command>
+ <command>
+ <proto>void <name>glCopyConvolutionFilter1D</name></proto>
+ <param group="ConvolutionTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="PixelInternalFormat"><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>x</name></param>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>y</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <glx type="render" opcode="4107"/>
+ </command>
+ <command>
+ <proto>void <name>glCopyConvolutionFilter1DEXT</name></proto>
+ <param group="ConvolutionTargetEXT"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="PixelInternalFormat"><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>x</name></param>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>y</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <alias name="glCopyConvolutionFilter1D"/>
+ <glx type="render" opcode="4107"/>
+ </command>
+ <command>
+ <proto>void <name>glCopyConvolutionFilter2D</name></proto>
+ <param group="ConvolutionTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="PixelInternalFormat"><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>x</name></param>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>y</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <glx type="render" opcode="4108"/>
+ </command>
+ <command>
+ <proto>void <name>glCopyConvolutionFilter2DEXT</name></proto>
+ <param group="ConvolutionTargetEXT"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="PixelInternalFormat"><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>x</name></param>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>y</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <alias name="glCopyConvolutionFilter2D"/>
+ <glx type="render" opcode="4108"/>
+ </command>
+ <command>
+ <proto>void <name>glCopyImageSubData</name></proto>
+ <param><ptype>GLuint</ptype> <name>srcName</name></param>
+ <param><ptype>GLenum</ptype> <name>srcTarget</name></param>
+ <param><ptype>GLint</ptype> <name>srcLevel</name></param>
+ <param><ptype>GLint</ptype> <name>srcX</name></param>
+ <param><ptype>GLint</ptype> <name>srcY</name></param>
+ <param><ptype>GLint</ptype> <name>srcZ</name></param>
+ <param><ptype>GLuint</ptype> <name>dstName</name></param>
+ <param><ptype>GLenum</ptype> <name>dstTarget</name></param>
+ <param><ptype>GLint</ptype> <name>dstLevel</name></param>
+ <param><ptype>GLint</ptype> <name>dstX</name></param>
+ <param><ptype>GLint</ptype> <name>dstY</name></param>
+ <param><ptype>GLint</ptype> <name>dstZ</name></param>
+ <param><ptype>GLsizei</ptype> <name>srcWidth</name></param>
+ <param><ptype>GLsizei</ptype> <name>srcHeight</name></param>
+ <param><ptype>GLsizei</ptype> <name>srcDepth</name></param>
+ </command>
+ <command>
+ <proto>void <name>glCopyImageSubDataEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>srcName</name></param>
+ <param><ptype>GLenum</ptype> <name>srcTarget</name></param>
+ <param><ptype>GLint</ptype> <name>srcLevel</name></param>
+ <param><ptype>GLint</ptype> <name>srcX</name></param>
+ <param><ptype>GLint</ptype> <name>srcY</name></param>
+ <param><ptype>GLint</ptype> <name>srcZ</name></param>
+ <param><ptype>GLuint</ptype> <name>dstName</name></param>
+ <param><ptype>GLenum</ptype> <name>dstTarget</name></param>
+ <param><ptype>GLint</ptype> <name>dstLevel</name></param>
+ <param><ptype>GLint</ptype> <name>dstX</name></param>
+ <param><ptype>GLint</ptype> <name>dstY</name></param>
+ <param><ptype>GLint</ptype> <name>dstZ</name></param>
+ <param><ptype>GLsizei</ptype> <name>srcWidth</name></param>
+ <param><ptype>GLsizei</ptype> <name>srcHeight</name></param>
+ <param><ptype>GLsizei</ptype> <name>srcDepth</name></param>
+ <alias name="glCopyImageSubData"/>
+ </command>
+ <command>
+ <proto>void <name>glCopyImageSubDataNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>srcName</name></param>
+ <param><ptype>GLenum</ptype> <name>srcTarget</name></param>
+ <param><ptype>GLint</ptype> <name>srcLevel</name></param>
+ <param><ptype>GLint</ptype> <name>srcX</name></param>
+ <param><ptype>GLint</ptype> <name>srcY</name></param>
+ <param><ptype>GLint</ptype> <name>srcZ</name></param>
+ <param><ptype>GLuint</ptype> <name>dstName</name></param>
+ <param><ptype>GLenum</ptype> <name>dstTarget</name></param>
+ <param><ptype>GLint</ptype> <name>dstLevel</name></param>
+ <param><ptype>GLint</ptype> <name>dstX</name></param>
+ <param><ptype>GLint</ptype> <name>dstY</name></param>
+ <param><ptype>GLint</ptype> <name>dstZ</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param><ptype>GLsizei</ptype> <name>depth</name></param>
+ <glx type="render" opcode="4291"/>
+ </command>
+ <command>
+ <proto>void <name>glCopyMultiTexImage1DEXT</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>texunit</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="TextureInternalFormat"><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>x</name></param>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>y</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>border</name></param>
+ </command>
+ <command>
+ <proto>void <name>glCopyMultiTexImage2DEXT</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>texunit</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="TextureInternalFormat"><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>x</name></param>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>y</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>border</name></param>
+ </command>
+ <command>
+ <proto>void <name>glCopyMultiTexSubImage1DEXT</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>texunit</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>xoffset</name></param>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>x</name></param>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>y</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ </command>
+ <command>
+ <proto>void <name>glCopyMultiTexSubImage2DEXT</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>texunit</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>xoffset</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>yoffset</name></param>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>x</name></param>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>y</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ </command>
+ <command>
+ <proto>void <name>glCopyMultiTexSubImage3DEXT</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>texunit</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>xoffset</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>yoffset</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>zoffset</name></param>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>x</name></param>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>y</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ </command>
+ <command>
+ <proto>void <name>glCopyNamedBufferSubData</name></proto>
+ <param><ptype>GLuint</ptype> <name>readBuffer</name></param>
+ <param><ptype>GLuint</ptype> <name>writeBuffer</name></param>
+ <param><ptype>GLintptr</ptype> <name>readOffset</name></param>
+ <param><ptype>GLintptr</ptype> <name>writeOffset</name></param>
+ <param><ptype>GLsizei</ptype> <name>size</name></param>
+ </command>
+ <command>
+ <proto>void <name>glCopyPathNV</name></proto>
+ <param group="Path"><ptype>GLuint</ptype> <name>resultPath</name></param>
+ <param group="Path"><ptype>GLuint</ptype> <name>srcPath</name></param>
+ </command>
+ <command>
+ <proto>void <name>glCopyPixels</name></proto>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>x</name></param>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>y</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param group="PixelCopyType"><ptype>GLenum</ptype> <name>type</name></param>
+ <glx type="render" opcode="172"/>
+ </command>
+ <command>
+ <proto>void <name>glCopyTexImage1D</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="PixelInternalFormat"><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>x</name></param>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>y</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>border</name></param>
+ <glx type="render" opcode="4119"/>
+ </command>
+ <command>
+ <proto>void <name>glCopyTexImage1DEXT</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="PixelInternalFormat"><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>x</name></param>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>y</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>border</name></param>
+ <alias name="glCopyTexImage1D"/>
+ <glx type="render" opcode="4119"/>
+ </command>
+ <command>
+ <proto>void <name>glCopyTexImage2D</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="PixelInternalFormat"><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>x</name></param>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>y</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>border</name></param>
+ <glx type="render" opcode="4120"/>
+ </command>
+ <command>
+ <proto>void <name>glCopyTexImage2DEXT</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="PixelInternalFormat"><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>x</name></param>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>y</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>border</name></param>
+ <alias name="glCopyTexImage2D"/>
+ <glx type="render" opcode="4120"/>
+ </command>
+ <command>
+ <proto>void <name>glCopyTexSubImage1D</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>xoffset</name></param>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>x</name></param>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>y</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <glx type="render" opcode="4121"/>
+ </command>
+ <command>
+ <proto>void <name>glCopyTexSubImage1DEXT</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>xoffset</name></param>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>x</name></param>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>y</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <alias name="glCopyTexSubImage1D"/>
+ <glx type="render" opcode="4121"/>
+ </command>
+ <command>
+ <proto>void <name>glCopyTexSubImage2D</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>xoffset</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>yoffset</name></param>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>x</name></param>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>y</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <glx type="render" opcode="4122"/>
+ </command>
+ <command>
+ <proto>void <name>glCopyTexSubImage2DEXT</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>xoffset</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>yoffset</name></param>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>x</name></param>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>y</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <alias name="glCopyTexSubImage2D"/>
+ <glx type="render" opcode="4122"/>
+ </command>
+ <command>
+ <proto>void <name>glCopyTexSubImage3D</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>xoffset</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>yoffset</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>zoffset</name></param>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>x</name></param>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>y</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <glx type="render" opcode="4123"/>
+ </command>
+ <command>
+ <proto>void <name>glCopyTexSubImage3DEXT</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>xoffset</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>yoffset</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>zoffset</name></param>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>x</name></param>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>y</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <alias name="glCopyTexSubImage3D"/>
+ <glx type="render" opcode="4123"/>
+ </command>
+ <command>
+ <proto>void <name>glCopyTexSubImage3DOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLint</ptype> <name>level</name></param>
+ <param><ptype>GLint</ptype> <name>xoffset</name></param>
+ <param><ptype>GLint</ptype> <name>yoffset</name></param>
+ <param><ptype>GLint</ptype> <name>zoffset</name></param>
+ <param><ptype>GLint</ptype> <name>x</name></param>
+ <param><ptype>GLint</ptype> <name>y</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <alias name="glCopyTexSubImage3D"/>
+ </command>
+ <command>
+ <proto>void <name>glCopyTextureImage1DEXT</name></proto>
+ <param group="Texture"><ptype>GLuint</ptype> <name>texture</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="TextureInternalFormat"><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>x</name></param>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>y</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>border</name></param>
+ </command>
+ <command>
+ <proto>void <name>glCopyTextureImage2DEXT</name></proto>
+ <param group="Texture"><ptype>GLuint</ptype> <name>texture</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="TextureInternalFormat"><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>x</name></param>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>y</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>border</name></param>
+ </command>
+ <command>
+ <proto>void <name>glCopyTextureLevelsAPPLE</name></proto>
+ <param><ptype>GLuint</ptype> <name>destinationTexture</name></param>
+ <param><ptype>GLuint</ptype> <name>sourceTexture</name></param>
+ <param><ptype>GLint</ptype> <name>sourceBaseLevel</name></param>
+ <param><ptype>GLsizei</ptype> <name>sourceLevelCount</name></param>
+ </command>
+ <command>
+ <proto>void <name>glCopyTextureSubImage1D</name></proto>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLint</ptype> <name>level</name></param>
+ <param><ptype>GLint</ptype> <name>xoffset</name></param>
+ <param><ptype>GLint</ptype> <name>x</name></param>
+ <param><ptype>GLint</ptype> <name>y</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ </command>
+ <command>
+ <proto>void <name>glCopyTextureSubImage1DEXT</name></proto>
+ <param group="Texture"><ptype>GLuint</ptype> <name>texture</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>xoffset</name></param>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>x</name></param>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>y</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ </command>
+ <command>
+ <proto>void <name>glCopyTextureSubImage2D</name></proto>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLint</ptype> <name>level</name></param>
+ <param><ptype>GLint</ptype> <name>xoffset</name></param>
+ <param><ptype>GLint</ptype> <name>yoffset</name></param>
+ <param><ptype>GLint</ptype> <name>x</name></param>
+ <param><ptype>GLint</ptype> <name>y</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ </command>
+ <command>
+ <proto>void <name>glCopyTextureSubImage2DEXT</name></proto>
+ <param group="Texture"><ptype>GLuint</ptype> <name>texture</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>xoffset</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>yoffset</name></param>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>x</name></param>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>y</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ </command>
+ <command>
+ <proto>void <name>glCopyTextureSubImage3D</name></proto>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLint</ptype> <name>level</name></param>
+ <param><ptype>GLint</ptype> <name>xoffset</name></param>
+ <param><ptype>GLint</ptype> <name>yoffset</name></param>
+ <param><ptype>GLint</ptype> <name>zoffset</name></param>
+ <param><ptype>GLint</ptype> <name>x</name></param>
+ <param><ptype>GLint</ptype> <name>y</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ </command>
+ <command>
+ <proto>void <name>glCopyTextureSubImage3DEXT</name></proto>
+ <param group="Texture"><ptype>GLuint</ptype> <name>texture</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>xoffset</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>yoffset</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>zoffset</name></param>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>x</name></param>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>y</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ </command>
+ <command>
+ <proto>void <name>glCoverFillPathInstancedNV</name></proto>
+ <param><ptype>GLsizei</ptype> <name>numPaths</name></param>
+ <param group="PathElementType"><ptype>GLenum</ptype> <name>pathNameType</name></param>
+ <param group="PathElement" len="COMPSIZE(numPaths,pathNameType,paths)">const void *<name>paths</name></param>
+ <param group="Path"><ptype>GLuint</ptype> <name>pathBase</name></param>
+ <param group="PathCoverMode"><ptype>GLenum</ptype> <name>coverMode</name></param>
+ <param group="PathTransformType"><ptype>GLenum</ptype> <name>transformType</name></param>
+ <param len="COMPSIZE(numPaths,transformType)">const <ptype>GLfloat</ptype> *<name>transformValues</name></param>
+ </command>
+ <command>
+ <proto>void <name>glCoverFillPathNV</name></proto>
+ <param group="Path"><ptype>GLuint</ptype> <name>path</name></param>
+ <param group="PathCoverMode"><ptype>GLenum</ptype> <name>coverMode</name></param>
+ </command>
+ <command>
+ <proto>void <name>glCoverStrokePathInstancedNV</name></proto>
+ <param><ptype>GLsizei</ptype> <name>numPaths</name></param>
+ <param group="PathElementType"><ptype>GLenum</ptype> <name>pathNameType</name></param>
+ <param group="PathElement" len="COMPSIZE(numPaths,pathNameType,paths)">const void *<name>paths</name></param>
+ <param group="Path"><ptype>GLuint</ptype> <name>pathBase</name></param>
+ <param group="PathCoverMode"><ptype>GLenum</ptype> <name>coverMode</name></param>
+ <param group="PathTransformType"><ptype>GLenum</ptype> <name>transformType</name></param>
+ <param len="COMPSIZE(numPaths,transformType)">const <ptype>GLfloat</ptype> *<name>transformValues</name></param>
+ </command>
+ <command>
+ <proto>void <name>glCoverStrokePathNV</name></proto>
+ <param group="Path"><ptype>GLuint</ptype> <name>path</name></param>
+ <param group="PathCoverMode"><ptype>GLenum</ptype> <name>coverMode</name></param>
+ </command>
+ <command>
+ <proto>void <name>glCoverageMaskNV</name></proto>
+ <param><ptype>GLboolean</ptype> <name>mask</name></param>
+ </command>
+ <command>
+ <proto>void <name>glCoverageOperationNV</name></proto>
+ <param><ptype>GLenum</ptype> <name>operation</name></param>
+ </command>
+ <command>
+ <proto>void <name>glCreateBuffers</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param><ptype>GLuint</ptype> *<name>buffers</name></param>
+ </command>
+ <command>
+ <proto>void <name>glCreateFramebuffers</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param><ptype>GLuint</ptype> *<name>framebuffers</name></param>
+ </command>
+ <command>
+ <proto>void <name>glCreatePerfQueryINTEL</name></proto>
+ <param><ptype>GLuint</ptype> <name>queryId</name></param>
+ <param><ptype>GLuint</ptype> *<name>queryHandle</name></param>
+ </command>
+ <command>
+ <proto><ptype>GLuint</ptype> <name>glCreateProgram</name></proto>
+ </command>
+ <command>
+ <proto group="handleARB"><ptype>GLhandleARB</ptype> <name>glCreateProgramObjectARB</name></proto>
+ <alias name="glCreateProgram"/>
+ </command>
+ <command>
+ <proto>void <name>glCreateProgramPipelines</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param><ptype>GLuint</ptype> *<name>pipelines</name></param>
+ </command>
+ <command>
+ <proto>void <name>glCreateQueries</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param><ptype>GLuint</ptype> *<name>ids</name></param>
+ </command>
+ <command>
+ <proto>void <name>glCreateRenderbuffers</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param><ptype>GLuint</ptype> *<name>renderbuffers</name></param>
+ </command>
+ <command>
+ <proto>void <name>glCreateSamplers</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param><ptype>GLuint</ptype> *<name>samplers</name></param>
+ </command>
+ <command>
+ <proto><ptype>GLuint</ptype> <name>glCreateShader</name></proto>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ </command>
+ <command>
+ <proto group="handleARB"><ptype>GLhandleARB</ptype> <name>glCreateShaderObjectARB</name></proto>
+ <param><ptype>GLenum</ptype> <name>shaderType</name></param>
+ <alias name="glCreateShader"/>
+ </command>
+ <command>
+ <proto><ptype>GLuint</ptype> <name>glCreateShaderProgramEXT</name></proto>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param>const <ptype>GLchar</ptype> *<name>string</name></param>
+ </command>
+ <command>
+ <proto><ptype>GLuint</ptype> <name>glCreateShaderProgramv</name></proto>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count">const <ptype>GLchar</ptype> *const*<name>strings</name></param>
+ </command>
+ <command>
+ <proto><ptype>GLuint</ptype> <name>glCreateShaderProgramvEXT</name></proto>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count">const <ptype>GLchar</ptype> **<name>strings</name></param>
+ </command>
+ <command>
+ <proto group="sync"><ptype>GLsync</ptype> <name>glCreateSyncFromCLeventARB</name></proto>
+ <param group="cl_context"><ptype>struct _cl_context</ptype> *<name>context</name></param>
+ <param group="cl_event"><ptype>struct _cl_event</ptype> *<name>event</name></param>
+ <param><ptype>GLbitfield</ptype> <name>flags</name></param>
+ </command>
+ <command>
+ <proto>void <name>glCreateTextures</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param><ptype>GLuint</ptype> *<name>textures</name></param>
+ </command>
+ <command>
+ <proto>void <name>glCreateTransformFeedbacks</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param><ptype>GLuint</ptype> *<name>ids</name></param>
+ </command>
+ <command>
+ <proto>void <name>glCreateVertexArrays</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param><ptype>GLuint</ptype> *<name>arrays</name></param>
+ </command>
+ <command>
+ <proto>void <name>glCullFace</name></proto>
+ <param group="CullFaceMode"><ptype>GLenum</ptype> <name>mode</name></param>
+ <glx type="render" opcode="79"/>
+ </command>
+ <command>
+ <proto>void <name>glCullParameterdvEXT</name></proto>
+ <param group="CullParameterEXT"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="4"><ptype>GLdouble</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glCullParameterfvEXT</name></proto>
+ <param group="CullParameterEXT"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="4"><ptype>GLfloat</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glCurrentPaletteMatrixARB</name></proto>
+ <param><ptype>GLint</ptype> <name>index</name></param>
+ <glx type="render" opcode="4329"/>
+ </command>
+ <command>
+ <proto>void <name>glCurrentPaletteMatrixOES</name></proto>
+ <param><ptype>GLuint</ptype> <name>matrixpaletteindex</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDebugMessageCallback</name></proto>
+ <param><ptype>GLDEBUGPROC</ptype> <name>callback</name></param>
+ <param>const void *<name>userParam</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDebugMessageCallbackAMD</name></proto>
+ <param><ptype>GLDEBUGPROCAMD</ptype> <name>callback</name></param>
+ <param>void *<name>userParam</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDebugMessageCallbackARB</name></proto>
+ <param><ptype>GLDEBUGPROCARB</ptype> <name>callback</name></param>
+ <param len="COMPSIZE(callback)">const void *<name>userParam</name></param>
+ <alias name="glDebugMessageCallback"/>
+ </command>
+ <command>
+ <proto>void <name>glDebugMessageCallbackKHR</name></proto>
+ <param><ptype>GLDEBUGPROCKHR</ptype> <name>callback</name></param>
+ <param>const void *<name>userParam</name></param>
+ <alias name="glDebugMessageCallback"/>
+ </command>
+ <command>
+ <proto>void <name>glDebugMessageControl</name></proto>
+ <param><ptype>GLenum</ptype> <name>source</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLenum</ptype> <name>severity</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count">const <ptype>GLuint</ptype> *<name>ids</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>enabled</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDebugMessageControlARB</name></proto>
+ <param><ptype>GLenum</ptype> <name>source</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLenum</ptype> <name>severity</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count">const <ptype>GLuint</ptype> *<name>ids</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>enabled</name></param>
+ <alias name="glDebugMessageControl"/>
+ </command>
+ <command>
+ <proto>void <name>glDebugMessageControlKHR</name></proto>
+ <param><ptype>GLenum</ptype> <name>source</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLenum</ptype> <name>severity</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param>const <ptype>GLuint</ptype> *<name>ids</name></param>
+ <param><ptype>GLboolean</ptype> <name>enabled</name></param>
+ <alias name="glDebugMessageControl"/>
+ </command>
+ <command>
+ <proto>void <name>glDebugMessageEnableAMD</name></proto>
+ <param><ptype>GLenum</ptype> <name>category</name></param>
+ <param><ptype>GLenum</ptype> <name>severity</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count">const <ptype>GLuint</ptype> *<name>ids</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>enabled</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDebugMessageInsert</name></proto>
+ <param><ptype>GLenum</ptype> <name>source</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <param><ptype>GLenum</ptype> <name>severity</name></param>
+ <param><ptype>GLsizei</ptype> <name>length</name></param>
+ <param len="COMPSIZE(buf,length)">const <ptype>GLchar</ptype> *<name>buf</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDebugMessageInsertAMD</name></proto>
+ <param><ptype>GLenum</ptype> <name>category</name></param>
+ <param><ptype>GLenum</ptype> <name>severity</name></param>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <param><ptype>GLsizei</ptype> <name>length</name></param>
+ <param len="length">const <ptype>GLchar</ptype> *<name>buf</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDebugMessageInsertARB</name></proto>
+ <param><ptype>GLenum</ptype> <name>source</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <param><ptype>GLenum</ptype> <name>severity</name></param>
+ <param><ptype>GLsizei</ptype> <name>length</name></param>
+ <param len="length">const <ptype>GLchar</ptype> *<name>buf</name></param>
+ <alias name="glDebugMessageInsert"/>
+ </command>
+ <command>
+ <proto>void <name>glDebugMessageInsertKHR</name></proto>
+ <param><ptype>GLenum</ptype> <name>source</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <param><ptype>GLenum</ptype> <name>severity</name></param>
+ <param><ptype>GLsizei</ptype> <name>length</name></param>
+ <param>const <ptype>GLchar</ptype> *<name>buf</name></param>
+ <alias name="glDebugMessageInsert"/>
+ </command>
+ <command>
+ <proto>void <name>glDeformSGIX</name></proto>
+ <param group="FfdMaskSGIX"><ptype>GLbitfield</ptype> <name>mask</name></param>
+ <glx type="render" opcode="2075"/>
+ </command>
+ <command>
+ <proto>void <name>glDeformationMap3dSGIX</name></proto>
+ <param group="FfdTargetSGIX"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>u1</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>u2</name></param>
+ <param><ptype>GLint</ptype> <name>ustride</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>uorder</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>v1</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>v2</name></param>
+ <param><ptype>GLint</ptype> <name>vstride</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>vorder</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>w1</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>w2</name></param>
+ <param><ptype>GLint</ptype> <name>wstride</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>worder</name></param>
+ <param group="CoordD" len="COMPSIZE(target,ustride,uorder,vstride,vorder,wstride,worder)">const <ptype>GLdouble</ptype> *<name>points</name></param>
+ <glx type="render" opcode="2073"/>
+ </command>
+ <command>
+ <proto>void <name>glDeformationMap3fSGIX</name></proto>
+ <param group="FfdTargetSGIX"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>u1</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>u2</name></param>
+ <param><ptype>GLint</ptype> <name>ustride</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>uorder</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>v1</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>v2</name></param>
+ <param><ptype>GLint</ptype> <name>vstride</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>vorder</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>w1</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>w2</name></param>
+ <param><ptype>GLint</ptype> <name>wstride</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>worder</name></param>
+ <param group="CoordF" len="COMPSIZE(target,ustride,uorder,vstride,vorder,wstride,worder)">const <ptype>GLfloat</ptype> *<name>points</name></param>
+ <glx type="render" opcode="2074"/>
+ </command>
+ <command>
+ <proto>void <name>glDeleteAsyncMarkersSGIX</name></proto>
+ <param><ptype>GLuint</ptype> <name>marker</name></param>
+ <param><ptype>GLsizei</ptype> <name>range</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDeleteBuffers</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param len="n">const <ptype>GLuint</ptype> *<name>buffers</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDeleteBuffersARB</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param len="n">const <ptype>GLuint</ptype> *<name>buffers</name></param>
+ <alias name="glDeleteBuffers"/>
+ </command>
+ <command>
+ <proto>void <name>glDeleteFencesAPPLE</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param group="FenceNV" len="n">const <ptype>GLuint</ptype> *<name>fences</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDeleteFencesNV</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param group="FenceNV" len="n">const <ptype>GLuint</ptype> *<name>fences</name></param>
+ <glx type="vendor" opcode="1276"/>
+ </command>
+ <command>
+ <proto>void <name>glDeleteFragmentShaderATI</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDeleteFramebuffers</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param len="n">const <ptype>GLuint</ptype> *<name>framebuffers</name></param>
+ <glx type="render" opcode="4320"/>
+ </command>
+ <command>
+ <proto>void <name>glDeleteFramebuffersEXT</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param len="n">const <ptype>GLuint</ptype> *<name>framebuffers</name></param>
+ <alias name="glDeleteFramebuffers"/>
+ <glx type="render" opcode="4320"/>
+ </command>
+ <command>
+ <proto>void <name>glDeleteFramebuffersOES</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param len="n">const <ptype>GLuint</ptype> *<name>framebuffers</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDeleteLists</name></proto>
+ <param group="List"><ptype>GLuint</ptype> <name>list</name></param>
+ <param><ptype>GLsizei</ptype> <name>range</name></param>
+ <glx type="single" opcode="103"/>
+ </command>
+ <command>
+ <proto>void <name>glDeleteNamedStringARB</name></proto>
+ <param><ptype>GLint</ptype> <name>namelen</name></param>
+ <param len="namelen">const <ptype>GLchar</ptype> *<name>name</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDeleteNamesAMD</name></proto>
+ <param><ptype>GLenum</ptype> <name>identifier</name></param>
+ <param><ptype>GLuint</ptype> <name>num</name></param>
+ <param len="num">const <ptype>GLuint</ptype> *<name>names</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDeleteObjectARB</name></proto>
+ <param group="handleARB"><ptype>GLhandleARB</ptype> <name>obj</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDeleteOcclusionQueriesNV</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param len="n">const <ptype>GLuint</ptype> *<name>ids</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDeletePathsNV</name></proto>
+ <param group="Path"><ptype>GLuint</ptype> <name>path</name></param>
+ <param><ptype>GLsizei</ptype> <name>range</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDeletePerfMonitorsAMD</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param len="n"><ptype>GLuint</ptype> *<name>monitors</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDeletePerfQueryINTEL</name></proto>
+ <param><ptype>GLuint</ptype> <name>queryHandle</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDeleteProgram</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <glx type="single" opcode="202"/>
+ </command>
+ <command>
+ <proto>void <name>glDeleteProgramPipelines</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param len="n">const <ptype>GLuint</ptype> *<name>pipelines</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDeleteProgramPipelinesEXT</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param len="n">const <ptype>GLuint</ptype> *<name>pipelines</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDeleteProgramsARB</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param len="n">const <ptype>GLuint</ptype> *<name>programs</name></param>
+ <glx type="vendor" opcode="1294"/>
+ </command>
+ <command>
+ <proto>void <name>glDeleteProgramsNV</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param len="n">const <ptype>GLuint</ptype> *<name>programs</name></param>
+ <alias name="glDeleteProgramsARB"/>
+ <glx type="vendor" opcode="1294"/>
+ </command>
+ <command>
+ <proto>void <name>glDeleteQueries</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param len="n">const <ptype>GLuint</ptype> *<name>ids</name></param>
+ <glx type="single" opcode="161"/>
+ </command>
+ <command>
+ <proto>void <name>glDeleteQueriesARB</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param len="n">const <ptype>GLuint</ptype> *<name>ids</name></param>
+ <alias name="glDeleteQueries"/>
+ </command>
+ <command>
+ <proto>void <name>glDeleteQueriesEXT</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param len="n">const <ptype>GLuint</ptype> *<name>ids</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDeleteRenderbuffers</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param len="n">const <ptype>GLuint</ptype> *<name>renderbuffers</name></param>
+ <glx type="render" opcode="4317"/>
+ </command>
+ <command>
+ <proto>void <name>glDeleteRenderbuffersEXT</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param len="n">const <ptype>GLuint</ptype> *<name>renderbuffers</name></param>
+ <alias name="glDeleteRenderbuffers"/>
+ <glx type="render" opcode="4317"/>
+ </command>
+ <command>
+ <proto>void <name>glDeleteRenderbuffersOES</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param len="n">const <ptype>GLuint</ptype> *<name>renderbuffers</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDeleteSamplers</name></proto>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count">const <ptype>GLuint</ptype> *<name>samplers</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDeleteShader</name></proto>
+ <param><ptype>GLuint</ptype> <name>shader</name></param>
+ <glx type="single" opcode="195"/>
+ </command>
+ <command>
+ <proto>void <name>glDeleteSync</name></proto>
+ <param group="sync"><ptype>GLsync</ptype> <name>sync</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDeleteSyncAPPLE</name></proto>
+ <param><ptype>GLsync</ptype> <name>sync</name></param>
+ <alias name="glDeleteSync"/>
+ </command>
+ <command>
+ <proto>void <name>glDeleteTextures</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param group="Texture" len="n">const <ptype>GLuint</ptype> *<name>textures</name></param>
+ <glx type="single" opcode="144"/>
+ </command>
+ <command>
+ <proto>void <name>glDeleteTexturesEXT</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param group="Texture" len="n">const <ptype>GLuint</ptype> *<name>textures</name></param>
+ <glx type="vendor" opcode="12"/>
+ </command>
+ <command>
+ <proto>void <name>glDeleteTransformFeedbacks</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param len="n">const <ptype>GLuint</ptype> *<name>ids</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDeleteTransformFeedbacksNV</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param len="n">const <ptype>GLuint</ptype> *<name>ids</name></param>
+ <alias name="glDeleteTransformFeedbacks"/>
+ </command>
+ <command>
+ <proto>void <name>glDeleteVertexArrays</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param len="n">const <ptype>GLuint</ptype> *<name>arrays</name></param>
+ <glx type="render" opcode="351"/>
+ </command>
+ <command>
+ <proto>void <name>glDeleteVertexArraysAPPLE</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param len="n">const <ptype>GLuint</ptype> *<name>arrays</name></param>
+ <alias name="glDeleteVertexArrays"/>
+ </command>
+ <command>
+ <proto>void <name>glDeleteVertexArraysOES</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param len="n">const <ptype>GLuint</ptype> *<name>arrays</name></param>
+ <alias name="glDeleteVertexArrays"/>
+ </command>
+ <command>
+ <proto>void <name>glDeleteVertexShaderEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDepthBoundsEXT</name></proto>
+ <param group="ClampedFloat64"><ptype>GLclampd</ptype> <name>zmin</name></param>
+ <param group="ClampedFloat64"><ptype>GLclampd</ptype> <name>zmax</name></param>
+ <glx type="render" opcode="4229"/>
+ </command>
+ <command>
+ <proto>void <name>glDepthBoundsdNV</name></proto>
+ <param><ptype>GLdouble</ptype> <name>zmin</name></param>
+ <param><ptype>GLdouble</ptype> <name>zmax</name></param>
+ <glx type="render" opcode="4285"/>
+ </command>
+ <command>
+ <proto>void <name>glDepthFunc</name></proto>
+ <param group="DepthFunction"><ptype>GLenum</ptype> <name>func</name></param>
+ <glx type="render" opcode="164"/>
+ </command>
+ <command>
+ <proto>void <name>glDepthMask</name></proto>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>flag</name></param>
+ <glx type="render" opcode="135"/>
+ </command>
+ <command>
+ <proto>void <name>glDepthRange</name></proto>
+ <param><ptype>GLdouble</ptype> <name>near</name></param>
+ <param><ptype>GLdouble</ptype> <name>far</name></param>
+ <glx type="render" opcode="174"/>
+ </command>
+ <command>
+ <proto>void <name>glDepthRangeArrayv</name></proto>
+ <param><ptype>GLuint</ptype> <name>first</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="COMPSIZE(count)">const <ptype>GLdouble</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDepthRangeIndexed</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLdouble</ptype> <name>n</name></param>
+ <param><ptype>GLdouble</ptype> <name>f</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDepthRangedNV</name></proto>
+ <param><ptype>GLdouble</ptype> <name>zNear</name></param>
+ <param><ptype>GLdouble</ptype> <name>zFar</name></param>
+ <glx type="render" opcode="4283"/>
+ </command>
+ <command>
+ <proto>void <name>glDepthRangef</name></proto>
+ <param><ptype>GLfloat</ptype> <name>n</name></param>
+ <param><ptype>GLfloat</ptype> <name>f</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDepthRangefOES</name></proto>
+ <param group="ClampedFloat32"><ptype>GLclampf</ptype> <name>n</name></param>
+ <param group="ClampedFloat32"><ptype>GLclampf</ptype> <name>f</name></param>
+ <glx type="render" opcode="4309"/>
+ <alias name="glDepthRangef"/>
+ </command>
+ <command>
+ <proto>void <name>glDepthRangex</name></proto>
+ <param><ptype>GLfixed</ptype> <name>n</name></param>
+ <param><ptype>GLfixed</ptype> <name>f</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDepthRangexOES</name></proto>
+ <param group="ClampedFixed"><ptype>GLfixed</ptype> <name>n</name></param>
+ <param group="ClampedFixed"><ptype>GLfixed</ptype> <name>f</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDetachObjectARB</name></proto>
+ <param group="handleARB"><ptype>GLhandleARB</ptype> <name>containerObj</name></param>
+ <param group="handleARB"><ptype>GLhandleARB</ptype> <name>attachedObj</name></param>
+ <alias name="glDetachShader"/>
+ </command>
+ <command>
+ <proto>void <name>glDetachShader</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLuint</ptype> <name>shader</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDetailTexFuncSGIS</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param len="n*2">const <ptype>GLfloat</ptype> *<name>points</name></param>
+ <glx type="render" opcode="2051"/>
+ </command>
+ <command>
+ <proto>void <name>glDisable</name></proto>
+ <param group="EnableCap"><ptype>GLenum</ptype> <name>cap</name></param>
+ <glx type="render" opcode="138"/>
+ </command>
+ <command>
+ <proto>void <name>glDisableClientState</name></proto>
+ <param group="EnableCap"><ptype>GLenum</ptype> <name>array</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDisableClientStateIndexedEXT</name></proto>
+ <param group="EnableCap"><ptype>GLenum</ptype> <name>array</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDisableClientStateiEXT</name></proto>
+ <param group="EnableCap"><ptype>GLenum</ptype> <name>array</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDisableDriverControlQCOM</name></proto>
+ <param><ptype>GLuint</ptype> <name>driverControl</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDisableIndexedEXT</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <alias name="glDisablei"/>
+ </command>
+ <command>
+ <proto>void <name>glDisableVariantClientStateEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDisableVertexArrayAttrib</name></proto>
+ <param><ptype>GLuint</ptype> <name>vaobj</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDisableVertexArrayAttribEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>vaobj</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDisableVertexArrayEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>vaobj</name></param>
+ <param group="EnableCap"><ptype>GLenum</ptype> <name>array</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDisableVertexAttribAPPLE</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDisableVertexAttribArray</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDisableVertexAttribArrayARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <alias name="glDisableVertexAttribArray"/>
+ </command>
+ <command>
+ <proto>void <name>glDisablei</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDisableiEXT</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <alias name="glDisablei"/>
+ </command>
+ <command>
+ <proto>void <name>glDiscardFramebufferEXT</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLsizei</ptype> <name>numAttachments</name></param>
+ <param len="numAttachments">const <ptype>GLenum</ptype> *<name>attachments</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDispatchCompute</name></proto>
+ <param><ptype>GLuint</ptype> <name>num_groups_x</name></param>
+ <param><ptype>GLuint</ptype> <name>num_groups_y</name></param>
+ <param><ptype>GLuint</ptype> <name>num_groups_z</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDispatchComputeGroupSizeARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>num_groups_x</name></param>
+ <param><ptype>GLuint</ptype> <name>num_groups_y</name></param>
+ <param><ptype>GLuint</ptype> <name>num_groups_z</name></param>
+ <param><ptype>GLuint</ptype> <name>group_size_x</name></param>
+ <param><ptype>GLuint</ptype> <name>group_size_y</name></param>
+ <param><ptype>GLuint</ptype> <name>group_size_z</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDispatchComputeIndirect</name></proto>
+ <param group="BufferOffset"><ptype>GLintptr</ptype> <name>indirect</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDrawArrays</name></proto>
+ <param group="PrimitiveType"><ptype>GLenum</ptype> <name>mode</name></param>
+ <param><ptype>GLint</ptype> <name>first</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <glx type="render" opcode="193"/>
+ </command>
+ <command>
+ <proto>void <name>glDrawArraysEXT</name></proto>
+ <param group="PrimitiveType"><ptype>GLenum</ptype> <name>mode</name></param>
+ <param><ptype>GLint</ptype> <name>first</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <alias name="glDrawArrays"/>
+ <glx type="render" opcode="4116"/>
+ </command>
+ <command>
+ <proto>void <name>glDrawArraysIndirect</name></proto>
+ <param group="PrimitiveType"><ptype>GLenum</ptype> <name>mode</name></param>
+ <param>const void *<name>indirect</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDrawArraysInstanced</name></proto>
+ <param group="PrimitiveType"><ptype>GLenum</ptype> <name>mode</name></param>
+ <param><ptype>GLint</ptype> <name>first</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param><ptype>GLsizei</ptype> <name>instancecount</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDrawArraysInstancedANGLE</name></proto>
+ <param group="PrimitiveType"><ptype>GLenum</ptype> <name>mode</name></param>
+ <param><ptype>GLint</ptype> <name>first</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param><ptype>GLsizei</ptype> <name>primcount</name></param>
+ <alias name="glDrawArraysInstanced"/>
+ </command>
+ <command>
+ <proto>void <name>glDrawArraysInstancedARB</name></proto>
+ <param group="PrimitiveType"><ptype>GLenum</ptype> <name>mode</name></param>
+ <param><ptype>GLint</ptype> <name>first</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param><ptype>GLsizei</ptype> <name>primcount</name></param>
+ <alias name="glDrawArraysInstanced"/>
+ </command>
+ <command>
+ <proto>void <name>glDrawArraysInstancedBaseInstance</name></proto>
+ <param group="PrimitiveType"><ptype>GLenum</ptype> <name>mode</name></param>
+ <param><ptype>GLint</ptype> <name>first</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param><ptype>GLsizei</ptype> <name>instancecount</name></param>
+ <param><ptype>GLuint</ptype> <name>baseinstance</name></param>
+ </command>
+ <command comment="primcount should be renamed to instanceCount for OpenGL ES">
+ <proto>void <name>glDrawArraysInstancedEXT</name></proto>
+ <param group="PrimitiveType"><ptype>GLenum</ptype> <name>mode</name></param>
+ <param><ptype>GLint</ptype> <name>start</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param><ptype>GLsizei</ptype> <name>primcount</name></param>
+ <alias name="glDrawArraysInstanced"/>
+ </command>
+ <command>
+ <proto>void <name>glDrawArraysInstancedNV</name></proto>
+ <param group="PrimitiveType"><ptype>GLenum</ptype> <name>mode</name></param>
+ <param><ptype>GLint</ptype> <name>first</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param><ptype>GLsizei</ptype> <name>primcount</name></param>
+ <alias name="glDrawArraysInstanced"/>
+ </command>
+ <command>
+ <proto>void <name>glDrawBuffer</name></proto>
+ <param group="DrawBufferMode"><ptype>GLenum</ptype> <name>buf</name></param>
+ <glx type="render" opcode="126"/>
+ </command>
+ <command>
+ <proto>void <name>glDrawBuffers</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param group="DrawBufferModeATI" len="n">const <ptype>GLenum</ptype> *<name>bufs</name></param>
+ <glx type="render" opcode="233"/>
+ </command>
+ <command>
+ <proto>void <name>glDrawBuffersARB</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param group="DrawBufferModeATI" len="n">const <ptype>GLenum</ptype> *<name>bufs</name></param>
+ <alias name="glDrawBuffers"/>
+ </command>
+ <command>
+ <proto>void <name>glDrawBuffersATI</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param group="DrawBufferModeATI" len="n">const <ptype>GLenum</ptype> *<name>bufs</name></param>
+ <alias name="glDrawBuffers"/>
+ <glx type="render" opcode="233"/>
+ </command>
+ <command>
+ <proto>void <name>glDrawBuffersEXT</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param>const <ptype>GLenum</ptype> *<name>bufs</name></param>
+ <alias name="glDrawBuffers"/>
+ </command>
+ <command>
+ <proto>void <name>glDrawBuffersIndexedEXT</name></proto>
+ <param><ptype>GLint</ptype> <name>n</name></param>
+ <param len="n">const <ptype>GLenum</ptype> *<name>location</name></param>
+ <param len="n">const <ptype>GLint</ptype> *<name>indices</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDrawBuffersNV</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param len="n">const <ptype>GLenum</ptype> *<name>bufs</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDrawElementArrayAPPLE</name></proto>
+ <param group="PrimitiveType"><ptype>GLenum</ptype> <name>mode</name></param>
+ <param><ptype>GLint</ptype> <name>first</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDrawElementArrayATI</name></proto>
+ <param group="PrimitiveType"><ptype>GLenum</ptype> <name>mode</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDrawElements</name></proto>
+ <param group="PrimitiveType"><ptype>GLenum</ptype> <name>mode</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="DrawElementsType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(count,type)">const void *<name>indices</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDrawElementsBaseVertex</name></proto>
+ <param group="PrimitiveType"><ptype>GLenum</ptype> <name>mode</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="DrawElementsType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(count,type)">const void *<name>indices</name></param>
+ <param><ptype>GLint</ptype> <name>basevertex</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDrawElementsIndirect</name></proto>
+ <param group="PrimitiveType"><ptype>GLenum</ptype> <name>mode</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param>const void *<name>indirect</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDrawElementsInstanced</name></proto>
+ <param group="PrimitiveType"><ptype>GLenum</ptype> <name>mode</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="DrawElementsType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(count,type)">const void *<name>indices</name></param>
+ <param><ptype>GLsizei</ptype> <name>instancecount</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDrawElementsInstancedANGLE</name></proto>
+ <param group="PrimitiveType"><ptype>GLenum</ptype> <name>mode</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(count,type)">const void *<name>indices</name></param>
+ <param><ptype>GLsizei</ptype> <name>primcount</name></param>
+ <alias name="glDrawElementsInstanced"/>
+ </command>
+ <command>
+ <proto>void <name>glDrawElementsInstancedARB</name></proto>
+ <param group="PrimitiveType"><ptype>GLenum</ptype> <name>mode</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="DrawElementsType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(count,type)">const void *<name>indices</name></param>
+ <param><ptype>GLsizei</ptype> <name>primcount</name></param>
+ <alias name="glDrawElementsInstanced"/>
+ </command>
+ <command>
+ <proto>void <name>glDrawElementsInstancedBaseInstance</name></proto>
+ <param group="PrimitiveType"><ptype>GLenum</ptype> <name>mode</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="count">const void *<name>indices</name></param>
+ <param><ptype>GLsizei</ptype> <name>instancecount</name></param>
+ <param><ptype>GLuint</ptype> <name>baseinstance</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDrawElementsInstancedBaseVertex</name></proto>
+ <param group="PrimitiveType"><ptype>GLenum</ptype> <name>mode</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="DrawElementsType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(count,type)">const void *<name>indices</name></param>
+ <param><ptype>GLsizei</ptype> <name>instancecount</name></param>
+ <param><ptype>GLint</ptype> <name>basevertex</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDrawElementsInstancedBaseVertexBaseInstance</name></proto>
+ <param group="PrimitiveType"><ptype>GLenum</ptype> <name>mode</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="count">const void *<name>indices</name></param>
+ <param><ptype>GLsizei</ptype> <name>instancecount</name></param>
+ <param><ptype>GLint</ptype> <name>basevertex</name></param>
+ <param><ptype>GLuint</ptype> <name>baseinstance</name></param>
+ </command>
+ <command comment="primcount should be renamed to instanceCount for OpenGL ES">
+ <proto>void <name>glDrawElementsInstancedEXT</name></proto>
+ <param group="PrimitiveType"><ptype>GLenum</ptype> <name>mode</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="DrawElementsType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(count,type)">const void *<name>indices</name></param>
+ <param><ptype>GLsizei</ptype> <name>primcount</name></param>
+ <alias name="glDrawElementsInstanced"/>
+ </command>
+ <command>
+ <proto>void <name>glDrawElementsInstancedNV</name></proto>
+ <param group="PrimitiveType"><ptype>GLenum</ptype> <name>mode</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(count,type)">const void *<name>indices</name></param>
+ <param><ptype>GLsizei</ptype> <name>primcount</name></param>
+ <alias name="glDrawElementsInstanced"/>
+ </command>
+ <command>
+ <proto>void <name>glDrawMeshArraysSUN</name></proto>
+ <param group="PrimitiveType"><ptype>GLenum</ptype> <name>mode</name></param>
+ <param><ptype>GLint</ptype> <name>first</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDrawPixels</name></proto>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param group="PixelType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(format,type,width,height)">const void *<name>pixels</name></param>
+ <glx type="render" opcode="173"/>
+ <glx type="render" opcode="322" name="glDrawPixelsPBO" comment="PBO protocol"/>
+ </command>
+ <command>
+ <proto>void <name>glDrawRangeElementArrayAPPLE</name></proto>
+ <param group="PrimitiveType"><ptype>GLenum</ptype> <name>mode</name></param>
+ <param><ptype>GLuint</ptype> <name>start</name></param>
+ <param><ptype>GLuint</ptype> <name>end</name></param>
+ <param><ptype>GLint</ptype> <name>first</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDrawRangeElementArrayATI</name></proto>
+ <param group="PrimitiveType"><ptype>GLenum</ptype> <name>mode</name></param>
+ <param><ptype>GLuint</ptype> <name>start</name></param>
+ <param><ptype>GLuint</ptype> <name>end</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDrawRangeElements</name></proto>
+ <param group="PrimitiveType"><ptype>GLenum</ptype> <name>mode</name></param>
+ <param><ptype>GLuint</ptype> <name>start</name></param>
+ <param><ptype>GLuint</ptype> <name>end</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="DrawElementsType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(count,type)">const void *<name>indices</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDrawRangeElementsBaseVertex</name></proto>
+ <param group="PrimitiveType"><ptype>GLenum</ptype> <name>mode</name></param>
+ <param><ptype>GLuint</ptype> <name>start</name></param>
+ <param><ptype>GLuint</ptype> <name>end</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="DrawElementsType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(count,type)">const void *<name>indices</name></param>
+ <param><ptype>GLint</ptype> <name>basevertex</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDrawRangeElementsEXT</name></proto>
+ <param group="PrimitiveType"><ptype>GLenum</ptype> <name>mode</name></param>
+ <param><ptype>GLuint</ptype> <name>start</name></param>
+ <param><ptype>GLuint</ptype> <name>end</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="DrawElementsType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(count,type)">const void *<name>indices</name></param>
+ <alias name="glDrawRangeElements"/>
+ </command>
+ <command>
+ <proto>void <name>glDrawTexfOES</name></proto>
+ <param><ptype>GLfloat</ptype> <name>x</name></param>
+ <param><ptype>GLfloat</ptype> <name>y</name></param>
+ <param><ptype>GLfloat</ptype> <name>z</name></param>
+ <param><ptype>GLfloat</ptype> <name>width</name></param>
+ <param><ptype>GLfloat</ptype> <name>height</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDrawTexfvOES</name></proto>
+ <param>const <ptype>GLfloat</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDrawTexiOES</name></proto>
+ <param><ptype>GLint</ptype> <name>x</name></param>
+ <param><ptype>GLint</ptype> <name>y</name></param>
+ <param><ptype>GLint</ptype> <name>z</name></param>
+ <param><ptype>GLint</ptype> <name>width</name></param>
+ <param><ptype>GLint</ptype> <name>height</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDrawTexivOES</name></proto>
+ <param>const <ptype>GLint</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDrawTexsOES</name></proto>
+ <param><ptype>GLshort</ptype> <name>x</name></param>
+ <param><ptype>GLshort</ptype> <name>y</name></param>
+ <param><ptype>GLshort</ptype> <name>z</name></param>
+ <param><ptype>GLshort</ptype> <name>width</name></param>
+ <param><ptype>GLshort</ptype> <name>height</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDrawTexsvOES</name></proto>
+ <param>const <ptype>GLshort</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDrawTextureNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLuint</ptype> <name>sampler</name></param>
+ <param><ptype>GLfloat</ptype> <name>x0</name></param>
+ <param><ptype>GLfloat</ptype> <name>y0</name></param>
+ <param><ptype>GLfloat</ptype> <name>x1</name></param>
+ <param><ptype>GLfloat</ptype> <name>y1</name></param>
+ <param><ptype>GLfloat</ptype> <name>z</name></param>
+ <param><ptype>GLfloat</ptype> <name>s0</name></param>
+ <param><ptype>GLfloat</ptype> <name>t0</name></param>
+ <param><ptype>GLfloat</ptype> <name>s1</name></param>
+ <param><ptype>GLfloat</ptype> <name>t1</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDrawTexxOES</name></proto>
+ <param><ptype>GLfixed</ptype> <name>x</name></param>
+ <param><ptype>GLfixed</ptype> <name>y</name></param>
+ <param><ptype>GLfixed</ptype> <name>z</name></param>
+ <param><ptype>GLfixed</ptype> <name>width</name></param>
+ <param><ptype>GLfixed</ptype> <name>height</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDrawTexxvOES</name></proto>
+ <param>const <ptype>GLfixed</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDrawTransformFeedback</name></proto>
+ <param group="PrimitiveType"><ptype>GLenum</ptype> <name>mode</name></param>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDrawTransformFeedbackInstanced</name></proto>
+ <param group="PrimitiveType"><ptype>GLenum</ptype> <name>mode</name></param>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <param><ptype>GLsizei</ptype> <name>instancecount</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDrawTransformFeedbackNV</name></proto>
+ <param group="PrimitiveType"><ptype>GLenum</ptype> <name>mode</name></param>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <alias name="glDrawTransformFeedback"/>
+ </command>
+ <command>
+ <proto>void <name>glDrawTransformFeedbackStream</name></proto>
+ <param group="PrimitiveType"><ptype>GLenum</ptype> <name>mode</name></param>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <param><ptype>GLuint</ptype> <name>stream</name></param>
+ </command>
+ <command>
+ <proto>void <name>glDrawTransformFeedbackStreamInstanced</name></proto>
+ <param group="PrimitiveType"><ptype>GLenum</ptype> <name>mode</name></param>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <param><ptype>GLuint</ptype> <name>stream</name></param>
+ <param><ptype>GLsizei</ptype> <name>instancecount</name></param>
+ </command>
+ <command>
+ <proto>void <name>glEGLImageTargetRenderbufferStorageOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLeglImageOES</ptype> <name>image</name></param>
+ </command>
+ <command>
+ <proto>void <name>glEGLImageTargetTexture2DOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLeglImageOES</ptype> <name>image</name></param>
+ </command>
+ <command>
+ <proto>void <name>glEdgeFlag</name></proto>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>flag</name></param>
+ <vecequiv name="glEdgeFlagv"/>
+ </command>
+ <command>
+ <proto>void <name>glEdgeFlagFormatNV</name></proto>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ </command>
+ <command>
+ <proto>void <name>glEdgeFlagPointer</name></proto>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ <param len="COMPSIZE(stride)">const void *<name>pointer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glEdgeFlagPointerEXT</name></proto>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean" len="COMPSIZE(stride,count)">const <ptype>GLboolean</ptype> *<name>pointer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glEdgeFlagPointerListIBM</name></proto>
+ <param><ptype>GLint</ptype> <name>stride</name></param>
+ <param group="BooleanPointer" len="COMPSIZE(stride)">const <ptype>GLboolean</ptype> **<name>pointer</name></param>
+ <param><ptype>GLint</ptype> <name>ptrstride</name></param>
+ </command>
+ <command>
+ <proto>void <name>glEdgeFlagv</name></proto>
+ <param group="Boolean" len="1">const <ptype>GLboolean</ptype> *<name>flag</name></param>
+ <glx type="render" opcode="22"/>
+ </command>
+ <command>
+ <proto>void <name>glElementPointerAPPLE</name></proto>
+ <param group="ElementPointerTypeATI"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(type)">const void *<name>pointer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glElementPointerATI</name></proto>
+ <param group="ElementPointerTypeATI"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(type)">const void *<name>pointer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glEnable</name></proto>
+ <param group="EnableCap"><ptype>GLenum</ptype> <name>cap</name></param>
+ <glx type="render" opcode="139"/>
+ </command>
+ <command>
+ <proto>void <name>glEnableClientState</name></proto>
+ <param group="EnableCap"><ptype>GLenum</ptype> <name>array</name></param>
+ </command>
+ <command>
+ <proto>void <name>glEnableClientStateIndexedEXT</name></proto>
+ <param group="EnableCap"><ptype>GLenum</ptype> <name>array</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ </command>
+ <command>
+ <proto>void <name>glEnableClientStateiEXT</name></proto>
+ <param group="EnableCap"><ptype>GLenum</ptype> <name>array</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ </command>
+ <command>
+ <proto>void <name>glEnableDriverControlQCOM</name></proto>
+ <param><ptype>GLuint</ptype> <name>driverControl</name></param>
+ </command>
+ <command>
+ <proto>void <name>glEnableIndexedEXT</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <alias name="glEnablei"/>
+ </command>
+ <command>
+ <proto>void <name>glEnableVariantClientStateEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ </command>
+ <command>
+ <proto>void <name>glEnableVertexArrayAttrib</name></proto>
+ <param><ptype>GLuint</ptype> <name>vaobj</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ </command>
+ <command>
+ <proto>void <name>glEnableVertexArrayAttribEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>vaobj</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ </command>
+ <command>
+ <proto>void <name>glEnableVertexArrayEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>vaobj</name></param>
+ <param group="EnableCap"><ptype>GLenum</ptype> <name>array</name></param>
+ </command>
+ <command>
+ <proto>void <name>glEnableVertexAttribAPPLE</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ </command>
+ <command>
+ <proto>void <name>glEnableVertexAttribArray</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ </command>
+ <command>
+ <proto>void <name>glEnableVertexAttribArrayARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <alias name="glEnableVertexAttribArray"/>
+ </command>
+ <command>
+ <proto>void <name>glEnablei</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ </command>
+ <command>
+ <proto>void <name>glEnableiEXT</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <alias name="glEnablei"/>
+ </command>
+ <command>
+ <proto>void <name>glEnd</name></proto>
+ <glx type="render" opcode="23"/>
+ </command>
+ <command>
+ <proto>void <name>glEndConditionalRender</name></proto>
+ <glx type="render" opcode="349"/>
+ </command>
+ <command>
+ <proto>void <name>glEndConditionalRenderNV</name></proto>
+ <alias name="glEndConditionalRender"/>
+ </command>
+ <command>
+ <proto>void <name>glEndConditionalRenderNVX</name></proto>
+ <alias name="glEndConditionalRender"/>
+ </command>
+ <command>
+ <proto>void <name>glEndFragmentShaderATI</name></proto>
+ </command>
+ <command>
+ <proto>void <name>glEndList</name></proto>
+ <glx type="single" opcode="102"/>
+ </command>
+ <command>
+ <proto>void <name>glEndOcclusionQueryNV</name></proto>
+ </command>
+ <command>
+ <proto>void <name>glEndPerfMonitorAMD</name></proto>
+ <param><ptype>GLuint</ptype> <name>monitor</name></param>
+ </command>
+ <command>
+ <proto>void <name>glEndPerfQueryINTEL</name></proto>
+ <param><ptype>GLuint</ptype> <name>queryHandle</name></param>
+ </command>
+ <command>
+ <proto>void <name>glEndQuery</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <glx type="render" opcode="232"/>
+ </command>
+ <command>
+ <proto>void <name>glEndQueryARB</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <alias name="glEndQuery"/>
+ </command>
+ <command>
+ <proto>void <name>glEndQueryEXT</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ </command>
+ <command>
+ <proto>void <name>glEndQueryIndexed</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ </command>
+ <command>
+ <proto>void <name>glEndTilingQCOM</name></proto>
+ <param><ptype>GLbitfield</ptype> <name>preserveMask</name></param>
+ </command>
+ <command>
+ <proto>void <name>glEndTransformFeedback</name></proto>
+ </command>
+ <command>
+ <proto>void <name>glEndTransformFeedbackEXT</name></proto>
+ <alias name="glEndTransformFeedback"/>
+ </command>
+ <command>
+ <proto>void <name>glEndTransformFeedbackNV</name></proto>
+ <alias name="glEndTransformFeedback"/>
+ </command>
+ <command>
+ <proto>void <name>glEndVertexShaderEXT</name></proto>
+ </command>
+ <command>
+ <proto>void <name>glEndVideoCaptureNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>video_capture_slot</name></param>
+ </command>
+ <command>
+ <proto>void <name>glEvalCoord1d</name></proto>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>u</name></param>
+ <vecequiv name="glEvalCoord1dv"/>
+ </command>
+ <command>
+ <proto>void <name>glEvalCoord1dv</name></proto>
+ <param group="CoordD" len="1">const <ptype>GLdouble</ptype> *<name>u</name></param>
+ <glx type="render" opcode="151"/>
+ </command>
+ <command>
+ <proto>void <name>glEvalCoord1f</name></proto>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>u</name></param>
+ <vecequiv name="glEvalCoord1fv"/>
+ </command>
+ <command>
+ <proto>void <name>glEvalCoord1fv</name></proto>
+ <param group="CoordF" len="1">const <ptype>GLfloat</ptype> *<name>u</name></param>
+ <glx type="render" opcode="152"/>
+ </command>
+ <command>
+ <proto>void <name>glEvalCoord1xOES</name></proto>
+ <param><ptype>GLfixed</ptype> <name>u</name></param>
+ </command>
+ <command>
+ <proto>void <name>glEvalCoord1xvOES</name></proto>
+ <param len="1">const <ptype>GLfixed</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glEvalCoord2d</name></proto>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>u</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>v</name></param>
+ <vecequiv name="glEvalCoord2dv"/>
+ </command>
+ <command>
+ <proto>void <name>glEvalCoord2dv</name></proto>
+ <param group="CoordD" len="2">const <ptype>GLdouble</ptype> *<name>u</name></param>
+ <glx type="render" opcode="153"/>
+ </command>
+ <command>
+ <proto>void <name>glEvalCoord2f</name></proto>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>u</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>v</name></param>
+ <vecequiv name="glEvalCoord2fv"/>
+ </command>
+ <command>
+ <proto>void <name>glEvalCoord2fv</name></proto>
+ <param group="CoordF" len="2">const <ptype>GLfloat</ptype> *<name>u</name></param>
+ <glx type="render" opcode="154"/>
+ </command>
+ <command>
+ <proto>void <name>glEvalCoord2xOES</name></proto>
+ <param><ptype>GLfixed</ptype> <name>u</name></param>
+ <param><ptype>GLfixed</ptype> <name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glEvalCoord2xvOES</name></proto>
+ <param len="2">const <ptype>GLfixed</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glEvalMapsNV</name></proto>
+ <param group="EvalTargetNV"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="EvalMapsModeNV"><ptype>GLenum</ptype> <name>mode</name></param>
+ </command>
+ <command>
+ <proto>void <name>glEvalMesh1</name></proto>
+ <param group="MeshMode1"><ptype>GLenum</ptype> <name>mode</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>i1</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>i2</name></param>
+ <glx type="render" opcode="155"/>
+ </command>
+ <command>
+ <proto>void <name>glEvalMesh2</name></proto>
+ <param group="MeshMode2"><ptype>GLenum</ptype> <name>mode</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>i1</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>i2</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>j1</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>j2</name></param>
+ <glx type="render" opcode="157"/>
+ </command>
+ <command>
+ <proto>void <name>glEvalPoint1</name></proto>
+ <param><ptype>GLint</ptype> <name>i</name></param>
+ <glx type="render" opcode="156"/>
+ </command>
+ <command>
+ <proto>void <name>glEvalPoint2</name></proto>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>i</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>j</name></param>
+ <glx type="render" opcode="158"/>
+ </command>
+ <command>
+ <proto>void <name>glExecuteProgramNV</name></proto>
+ <param group="VertexAttribEnumNV"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <param len="4">const <ptype>GLfloat</ptype> *<name>params</name></param>
+ <glx type="render" opcode="4181"/>
+ </command>
+ <command>
+ <proto>void <name>glExtGetBufferPointervQCOM</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param>void **<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glExtGetBuffersQCOM</name></proto>
+ <param len="maxBuffers"><ptype>GLuint</ptype> *<name>buffers</name></param>
+ <param><ptype>GLint</ptype> <name>maxBuffers</name></param>
+ <param len="1"><ptype>GLint</ptype> *<name>numBuffers</name></param>
+ </command>
+ <command>
+ <proto>void <name>glExtGetFramebuffersQCOM</name></proto>
+ <param len="maxFramebuffers"><ptype>GLuint</ptype> *<name>framebuffers</name></param>
+ <param><ptype>GLint</ptype> <name>maxFramebuffers</name></param>
+ <param len="1"><ptype>GLint</ptype> *<name>numFramebuffers</name></param>
+ </command>
+ <command>
+ <proto>void <name>glExtGetProgramBinarySourceQCOM</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLenum</ptype> <name>shadertype</name></param>
+ <param><ptype>GLchar</ptype> *<name>source</name></param>
+ <param><ptype>GLint</ptype> *<name>length</name></param>
+ </command>
+ <command>
+ <proto>void <name>glExtGetProgramsQCOM</name></proto>
+ <param len="maxPrograms"><ptype>GLuint</ptype> *<name>programs</name></param>
+ <param><ptype>GLint</ptype> <name>maxPrograms</name></param>
+ <param len="1"><ptype>GLint</ptype> *<name>numPrograms</name></param>
+ </command>
+ <command>
+ <proto>void <name>glExtGetRenderbuffersQCOM</name></proto>
+ <param len="maxRenderbuffers"><ptype>GLuint</ptype> *<name>renderbuffers</name></param>
+ <param><ptype>GLint</ptype> <name>maxRenderbuffers</name></param>
+ <param len="1"><ptype>GLint</ptype> *<name>numRenderbuffers</name></param>
+ </command>
+ <command>
+ <proto>void <name>glExtGetShadersQCOM</name></proto>
+ <param len="maxShaders"><ptype>GLuint</ptype> *<name>shaders</name></param>
+ <param><ptype>GLint</ptype> <name>maxShaders</name></param>
+ <param len="1"><ptype>GLint</ptype> *<name>numShaders</name></param>
+ </command>
+ <command>
+ <proto>void <name>glExtGetTexLevelParameterivQCOM</name></proto>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLenum</ptype> <name>face</name></param>
+ <param><ptype>GLint</ptype> <name>level</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glExtGetTexSubImageQCOM</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLint</ptype> <name>level</name></param>
+ <param><ptype>GLint</ptype> <name>xoffset</name></param>
+ <param><ptype>GLint</ptype> <name>yoffset</name></param>
+ <param><ptype>GLint</ptype> <name>zoffset</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param><ptype>GLsizei</ptype> <name>depth</name></param>
+ <param><ptype>GLenum</ptype> <name>format</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param>void *<name>texels</name></param>
+ </command>
+ <command>
+ <proto>void <name>glExtGetTexturesQCOM</name></proto>
+ <param><ptype>GLuint</ptype> *<name>textures</name></param>
+ <param><ptype>GLint</ptype> <name>maxTextures</name></param>
+ <param><ptype>GLint</ptype> *<name>numTextures</name></param>
+ </command>
+ <command>
+ <proto><ptype>GLboolean</ptype> <name>glExtIsProgramBinaryQCOM</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ </command>
+ <command>
+ <proto>void <name>glExtTexObjectStateOverrideiQCOM</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLint</ptype> <name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glExtractComponentEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>res</name></param>
+ <param><ptype>GLuint</ptype> <name>src</name></param>
+ <param><ptype>GLuint</ptype> <name>num</name></param>
+ </command>
+ <command>
+ <proto>void <name>glFeedbackBuffer</name></proto>
+ <param><ptype>GLsizei</ptype> <name>size</name></param>
+ <param group="FeedbackType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param group="FeedbackElement" len="size"><ptype>GLfloat</ptype> *<name>buffer</name></param>
+ <glx type="single" opcode="105"/>
+ </command>
+ <command>
+ <proto>void <name>glFeedbackBufferxOES</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="n">const <ptype>GLfixed</ptype> *<name>buffer</name></param>
+ </command>
+ <command>
+ <proto group="sync"><ptype>GLsync</ptype> <name>glFenceSync</name></proto>
+ <param><ptype>GLenum</ptype> <name>condition</name></param>
+ <param><ptype>GLbitfield</ptype> <name>flags</name></param>
+ </command>
+ <command>
+ <proto><ptype>GLsync</ptype> <name>glFenceSyncAPPLE</name></proto>
+ <param><ptype>GLenum</ptype> <name>condition</name></param>
+ <param><ptype>GLbitfield</ptype> <name>flags</name></param>
+ <alias name="glFenceSync"/>
+ </command>
+ <command>
+ <proto>void <name>glFinalCombinerInputNV</name></proto>
+ <param group="CombinerVariableNV"><ptype>GLenum</ptype> <name>variable</name></param>
+ <param group="CombinerRegisterNV"><ptype>GLenum</ptype> <name>input</name></param>
+ <param group="CombinerMappingNV"><ptype>GLenum</ptype> <name>mapping</name></param>
+ <param group="CombinerComponentUsageNV"><ptype>GLenum</ptype> <name>componentUsage</name></param>
+ <glx type="render" opcode="4142"/>
+ </command>
+ <command>
+ <proto>void <name>glFinish</name></proto>
+ <glx type="single" opcode="108"/>
+ </command>
+ <command>
+ <proto><ptype>GLint</ptype> <name>glFinishAsyncSGIX</name></proto>
+ <param len="1"><ptype>GLuint</ptype> *<name>markerp</name></param>
+ </command>
+ <command>
+ <proto>void <name>glFinishFenceAPPLE</name></proto>
+ <param group="FenceNV"><ptype>GLuint</ptype> <name>fence</name></param>
+ </command>
+ <command>
+ <proto>void <name>glFinishFenceNV</name></proto>
+ <param group="FenceNV"><ptype>GLuint</ptype> <name>fence</name></param>
+ <glx type="vendor" opcode="1312"/>
+ </command>
+ <command>
+ <proto>void <name>glFinishObjectAPPLE</name></proto>
+ <param group="ObjectTypeAPPLE"><ptype>GLenum</ptype> <name>object</name></param>
+ <param><ptype>GLint</ptype> <name>name</name></param>
+ </command>
+ <command>
+ <proto>void <name>glFinishTextureSUNX</name></proto>
+ </command>
+ <command>
+ <proto>void <name>glFlush</name></proto>
+ <glx type="single" opcode="142"/>
+ </command>
+ <command>
+ <proto>void <name>glFlushMappedBufferRange</name></proto>
+ <param group="BufferTargetARB"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="BufferOffset"><ptype>GLintptr</ptype> <name>offset</name></param>
+ <param group="BufferSize"><ptype>GLsizeiptr</ptype> <name>length</name></param>
+ </command>
+ <command>
+ <proto>void <name>glFlushMappedBufferRangeAPPLE</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="BufferOffset"><ptype>GLintptr</ptype> <name>offset</name></param>
+ <param group="BufferSize"><ptype>GLsizeiptr</ptype> <name>size</name></param>
+ <alias name="glFlushMappedBufferRange"/>
+ </command>
+ <command>
+ <proto>void <name>glFlushMappedBufferRangeEXT</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLintptr</ptype> <name>offset</name></param>
+ <param><ptype>GLsizeiptr</ptype> <name>length</name></param>
+ <alias name="glFlushMappedBufferRange"/>
+ </command>
+ <command>
+ <proto>void <name>glFlushMappedNamedBufferRange</name></proto>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <param><ptype>GLintptr</ptype> <name>offset</name></param>
+ <param><ptype>GLsizei</ptype> <name>length</name></param>
+ </command>
+ <command>
+ <proto>void <name>glFlushMappedNamedBufferRangeEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <param><ptype>GLintptr</ptype> <name>offset</name></param>
+ <param><ptype>GLsizeiptr</ptype> <name>length</name></param>
+ </command>
+ <command>
+ <proto>void <name>glFlushPixelDataRangeNV</name></proto>
+ <param group="PixelDataRangeTargetNV"><ptype>GLenum</ptype> <name>target</name></param>
+ </command>
+ <command>
+ <proto>void <name>glFlushRasterSGIX</name></proto>
+ <glx type="vendor" opcode="4105"/>
+ </command>
+ <command>
+ <proto>void <name>glFlushStaticDataIBM</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ </command>
+ <command>
+ <proto>void <name>glFlushVertexArrayRangeAPPLE</name></proto>
+ <param><ptype>GLsizei</ptype> <name>length</name></param>
+ <param len="length">void *<name>pointer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glFlushVertexArrayRangeNV</name></proto>
+ </command>
+ <command>
+ <proto>void <name>glFogCoordFormatNV</name></proto>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ </command>
+ <command>
+ <proto>void <name>glFogCoordPointer</name></proto>
+ <param group="FogPointerTypeEXT"><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ <param len="COMPSIZE(type,stride)">const void *<name>pointer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glFogCoordPointerEXT</name></proto>
+ <param group="FogPointerTypeEXT"><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ <param len="COMPSIZE(type,stride)">const void *<name>pointer</name></param>
+ <alias name="glFogCoordPointer"/>
+ </command>
+ <command>
+ <proto>void <name>glFogCoordPointerListIBM</name></proto>
+ <param group="FogPointerTypeIBM"><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLint</ptype> <name>stride</name></param>
+ <param len="COMPSIZE(type,stride)">const void **<name>pointer</name></param>
+ <param><ptype>GLint</ptype> <name>ptrstride</name></param>
+ </command>
+ <command>
+ <proto>void <name>glFogCoordd</name></proto>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>coord</name></param>
+ <vecequiv name="glFogCoorddv"/>
+ </command>
+ <command>
+ <proto>void <name>glFogCoorddEXT</name></proto>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>coord</name></param>
+ <alias name="glFogCoordd"/>
+ <vecequiv name="glFogCoorddvEXT"/>
+ </command>
+ <command>
+ <proto>void <name>glFogCoorddv</name></proto>
+ <param group="CoordD" len="1">const <ptype>GLdouble</ptype> *<name>coord</name></param>
+ <glx type="render" opcode="4125"/>
+ </command>
+ <command>
+ <proto>void <name>glFogCoorddvEXT</name></proto>
+ <param group="CoordD" len="1">const <ptype>GLdouble</ptype> *<name>coord</name></param>
+ <alias name="glFogCoorddv"/>
+ <glx type="render" opcode="4125"/>
+ </command>
+ <command>
+ <proto>void <name>glFogCoordf</name></proto>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>coord</name></param>
+ <vecequiv name="glFogCoordfv"/>
+ </command>
+ <command>
+ <proto>void <name>glFogCoordfEXT</name></proto>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>coord</name></param>
+ <alias name="glFogCoordf"/>
+ <vecequiv name="glFogCoordfvEXT"/>
+ </command>
+ <command>
+ <proto>void <name>glFogCoordfv</name></proto>
+ <param group="CoordF" len="1">const <ptype>GLfloat</ptype> *<name>coord</name></param>
+ <glx type="render" opcode="4124"/>
+ </command>
+ <command>
+ <proto>void <name>glFogCoordfvEXT</name></proto>
+ <param group="CoordF" len="1">const <ptype>GLfloat</ptype> *<name>coord</name></param>
+ <alias name="glFogCoordfv"/>
+ <glx type="render" opcode="4124"/>
+ </command>
+ <command>
+ <proto>void <name>glFogCoordhNV</name></proto>
+ <param group="Half16NV"><ptype>GLhalfNV</ptype> <name>fog</name></param>
+ <vecequiv name="glFogCoordhvNV"/>
+ </command>
+ <command>
+ <proto>void <name>glFogCoordhvNV</name></proto>
+ <param group="Half16NV" len="1">const <ptype>GLhalfNV</ptype> *<name>fog</name></param>
+ <glx type="render" opcode="4254"/>
+ </command>
+ <command>
+ <proto>void <name>glFogFuncSGIS</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param len="n*2">const <ptype>GLfloat</ptype> *<name>points</name></param>
+ <glx type="render" opcode="2067"/>
+ </command>
+ <command>
+ <proto>void <name>glFogf</name></proto>
+ <param group="FogParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedFloat32"><ptype>GLfloat</ptype> <name>param</name></param>
+ <glx type="render" opcode="80"/>
+ </command>
+ <command>
+ <proto>void <name>glFogfv</name></proto>
+ <param group="FogParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedFloat32" len="COMPSIZE(pname)">const <ptype>GLfloat</ptype> *<name>params</name></param>
+ <glx type="render" opcode="81"/>
+ </command>
+ <command>
+ <proto>void <name>glFogi</name></proto>
+ <param group="FogParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>param</name></param>
+ <glx type="render" opcode="82"/>
+ </command>
+ <command>
+ <proto>void <name>glFogiv</name></proto>
+ <param group="FogParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedInt32" len="COMPSIZE(pname)">const <ptype>GLint</ptype> *<name>params</name></param>
+ <glx type="render" opcode="83"/>
+ </command>
+ <command>
+ <proto>void <name>glFogx</name></proto>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLfixed</ptype> <name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glFogxOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLfixed</ptype> <name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glFogxv</name></proto>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)">const <ptype>GLfixed</ptype> *<name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glFogxvOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)">const <ptype>GLfixed</ptype> *<name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glFragmentColorMaterialSGIX</name></proto>
+ <param group="MaterialFace"><ptype>GLenum</ptype> <name>face</name></param>
+ <param group="MaterialParameter"><ptype>GLenum</ptype> <name>mode</name></param>
+ </command>
+ <command>
+ <proto>void <name>glFragmentLightModelfSGIX</name></proto>
+ <param group="FragmentLightModelParameterSGIX"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedFloat32"><ptype>GLfloat</ptype> <name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glFragmentLightModelfvSGIX</name></proto>
+ <param group="FragmentLightModelParameterSGIX"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedFloat32" len="COMPSIZE(pname)">const <ptype>GLfloat</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glFragmentLightModeliSGIX</name></proto>
+ <param group="FragmentLightModelParameterSGIX"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glFragmentLightModelivSGIX</name></proto>
+ <param group="FragmentLightModelParameterSGIX"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedInt32" len="COMPSIZE(pname)">const <ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glFragmentLightfSGIX</name></proto>
+ <param group="FragmentLightNameSGIX"><ptype>GLenum</ptype> <name>light</name></param>
+ <param group="FragmentLightParameterSGIX"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedFloat32"><ptype>GLfloat</ptype> <name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glFragmentLightfvSGIX</name></proto>
+ <param group="FragmentLightNameSGIX"><ptype>GLenum</ptype> <name>light</name></param>
+ <param group="FragmentLightParameterSGIX"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedFloat32" len="COMPSIZE(pname)">const <ptype>GLfloat</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glFragmentLightiSGIX</name></proto>
+ <param group="FragmentLightNameSGIX"><ptype>GLenum</ptype> <name>light</name></param>
+ <param group="FragmentLightParameterSGIX"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glFragmentLightivSGIX</name></proto>
+ <param group="FragmentLightNameSGIX"><ptype>GLenum</ptype> <name>light</name></param>
+ <param group="FragmentLightParameterSGIX"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedInt32" len="COMPSIZE(pname)">const <ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glFragmentMaterialfSGIX</name></proto>
+ <param group="MaterialFace"><ptype>GLenum</ptype> <name>face</name></param>
+ <param group="MaterialParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedFloat32"><ptype>GLfloat</ptype> <name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glFragmentMaterialfvSGIX</name></proto>
+ <param group="MaterialFace"><ptype>GLenum</ptype> <name>face</name></param>
+ <param group="MaterialParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedFloat32" len="COMPSIZE(pname)">const <ptype>GLfloat</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glFragmentMaterialiSGIX</name></proto>
+ <param group="MaterialFace"><ptype>GLenum</ptype> <name>face</name></param>
+ <param group="MaterialParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glFragmentMaterialivSGIX</name></proto>
+ <param group="MaterialFace"><ptype>GLenum</ptype> <name>face</name></param>
+ <param group="MaterialParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedInt32" len="COMPSIZE(pname)">const <ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glFrameTerminatorGREMEDY</name></proto>
+ </command>
+ <command>
+ <proto>void <name>glFrameZoomSGIX</name></proto>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>factor</name></param>
+ <glx type="render" opcode="2072"/>
+ </command>
+ <command>
+ <proto>void <name>glFramebufferDrawBufferEXT</name></proto>
+ <param group="Framebuffer"><ptype>GLuint</ptype> <name>framebuffer</name></param>
+ <param group="DrawBufferMode"><ptype>GLenum</ptype> <name>mode</name></param>
+ </command>
+ <command>
+ <proto>void <name>glFramebufferDrawBuffersEXT</name></proto>
+ <param group="Framebuffer"><ptype>GLuint</ptype> <name>framebuffer</name></param>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param group="DrawBufferMode" len="n">const <ptype>GLenum</ptype> *<name>bufs</name></param>
+ </command>
+ <command>
+ <proto>void <name>glFramebufferParameteri</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLint</ptype> <name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glFramebufferReadBufferEXT</name></proto>
+ <param group="Framebuffer"><ptype>GLuint</ptype> <name>framebuffer</name></param>
+ <param group="ReadBufferMode"><ptype>GLenum</ptype> <name>mode</name></param>
+ </command>
+ <command>
+ <proto>void <name>glFramebufferRenderbuffer</name></proto>
+ <param group="FramebufferTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="FramebufferAttachment"><ptype>GLenum</ptype> <name>attachment</name></param>
+ <param group="RenderbufferTarget"><ptype>GLenum</ptype> <name>renderbuffertarget</name></param>
+ <param><ptype>GLuint</ptype> <name>renderbuffer</name></param>
+ <glx type="render" opcode="4324"/>
+ </command>
+ <command>
+ <proto>void <name>glFramebufferRenderbufferEXT</name></proto>
+ <param group="FramebufferTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="FramebufferAttachment"><ptype>GLenum</ptype> <name>attachment</name></param>
+ <param group="RenderbufferTarget"><ptype>GLenum</ptype> <name>renderbuffertarget</name></param>
+ <param><ptype>GLuint</ptype> <name>renderbuffer</name></param>
+ <alias name="glFramebufferRenderbuffer"/>
+ <glx type="render" opcode="4324"/>
+ </command>
+ <command>
+ <proto>void <name>glFramebufferRenderbufferOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>attachment</name></param>
+ <param><ptype>GLenum</ptype> <name>renderbuffertarget</name></param>
+ <param><ptype>GLuint</ptype> <name>renderbuffer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glFramebufferTexture</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>attachment</name></param>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLint</ptype> <name>level</name></param>
+ </command>
+ <command>
+ <proto>void <name>glFramebufferTexture1D</name></proto>
+ <param group="FramebufferTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="FramebufferAttachment"><ptype>GLenum</ptype> <name>attachment</name></param>
+ <param><ptype>GLenum</ptype> <name>textarget</name></param>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLint</ptype> <name>level</name></param>
+ <glx type="render" opcode="4321"/>
+ </command>
+ <command>
+ <proto>void <name>glFramebufferTexture1DEXT</name></proto>
+ <param group="FramebufferTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="FramebufferAttachment"><ptype>GLenum</ptype> <name>attachment</name></param>
+ <param><ptype>GLenum</ptype> <name>textarget</name></param>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLint</ptype> <name>level</name></param>
+ <alias name="glFramebufferTexture1D"/>
+ <glx type="render" opcode="4321"/>
+ </command>
+ <command>
+ <proto>void <name>glFramebufferTexture2D</name></proto>
+ <param group="FramebufferTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="FramebufferAttachment"><ptype>GLenum</ptype> <name>attachment</name></param>
+ <param><ptype>GLenum</ptype> <name>textarget</name></param>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLint</ptype> <name>level</name></param>
+ <glx type="render" opcode="4322"/>
+ </command>
+ <command>
+ <proto>void <name>glFramebufferTexture2DEXT</name></proto>
+ <param group="FramebufferTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="FramebufferAttachment"><ptype>GLenum</ptype> <name>attachment</name></param>
+ <param><ptype>GLenum</ptype> <name>textarget</name></param>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLint</ptype> <name>level</name></param>
+ <alias name="glFramebufferTexture2D"/>
+ <glx type="render" opcode="4322"/>
+ </command>
+ <command>
+ <proto>void <name>glFramebufferTexture2DMultisampleEXT</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>attachment</name></param>
+ <param><ptype>GLenum</ptype> <name>textarget</name></param>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLint</ptype> <name>level</name></param>
+ <param><ptype>GLsizei</ptype> <name>samples</name></param>
+ </command>
+ <command>
+ <proto>void <name>glFramebufferTexture2DMultisampleIMG</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>attachment</name></param>
+ <param><ptype>GLenum</ptype> <name>textarget</name></param>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLint</ptype> <name>level</name></param>
+ <param><ptype>GLsizei</ptype> <name>samples</name></param>
+ </command>
+ <command>
+ <proto>void <name>glFramebufferTexture2DOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>attachment</name></param>
+ <param><ptype>GLenum</ptype> <name>textarget</name></param>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLint</ptype> <name>level</name></param>
+ </command>
+ <command>
+ <proto>void <name>glFramebufferTexture3D</name></proto>
+ <param group="FramebufferTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="FramebufferAttachment"><ptype>GLenum</ptype> <name>attachment</name></param>
+ <param><ptype>GLenum</ptype> <name>textarget</name></param>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLint</ptype> <name>level</name></param>
+ <param><ptype>GLint</ptype> <name>zoffset</name></param>
+ <glx type="render" opcode="4323"/>
+ </command>
+ <command>
+ <proto>void <name>glFramebufferTexture3DEXT</name></proto>
+ <param group="FramebufferTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="FramebufferAttachment"><ptype>GLenum</ptype> <name>attachment</name></param>
+ <param><ptype>GLenum</ptype> <name>textarget</name></param>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLint</ptype> <name>level</name></param>
+ <param><ptype>GLint</ptype> <name>zoffset</name></param>
+ <alias name="glFramebufferTexture3D"/>
+ <glx type="render" opcode="4323"/>
+ </command>
+ <command>
+ <proto>void <name>glFramebufferTexture3DOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>attachment</name></param>
+ <param><ptype>GLenum</ptype> <name>textarget</name></param>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLint</ptype> <name>level</name></param>
+ <param><ptype>GLint</ptype> <name>zoffset</name></param>
+ <alias name="glFramebufferTexture3D"/>
+ </command>
+ <command>
+ <proto>void <name>glFramebufferTextureARB</name></proto>
+ <param group="FramebufferTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="FramebufferAttachment"><ptype>GLenum</ptype> <name>attachment</name></param>
+ <param group="Texture"><ptype>GLuint</ptype> <name>texture</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <alias name="glFramebufferTexture"/>
+ </command>
+ <command>
+ <proto>void <name>glFramebufferTextureEXT</name></proto>
+ <param group="FramebufferTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="FramebufferAttachment"><ptype>GLenum</ptype> <name>attachment</name></param>
+ <param group="Texture"><ptype>GLuint</ptype> <name>texture</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <alias name="glFramebufferTextureARB"/>
+ </command>
+ <command>
+ <proto>void <name>glFramebufferTextureFaceARB</name></proto>
+ <param group="FramebufferTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="FramebufferAttachment"><ptype>GLenum</ptype> <name>attachment</name></param>
+ <param group="Texture"><ptype>GLuint</ptype> <name>texture</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>face</name></param>
+ </command>
+ <command>
+ <proto>void <name>glFramebufferTextureFaceEXT</name></proto>
+ <param group="FramebufferTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="FramebufferAttachment"><ptype>GLenum</ptype> <name>attachment</name></param>
+ <param group="Texture"><ptype>GLuint</ptype> <name>texture</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>face</name></param>
+ <alias name="glFramebufferTextureFaceARB"/>
+ </command>
+ <command>
+ <proto>void <name>glFramebufferTextureLayer</name></proto>
+ <param group="FramebufferTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="FramebufferAttachment"><ptype>GLenum</ptype> <name>attachment</name></param>
+ <param group="Texture"><ptype>GLuint</ptype> <name>texture</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>layer</name></param>
+ <glx type="render" opcode="237"/>
+ </command>
+ <command>
+ <proto>void <name>glFramebufferTextureLayerARB</name></proto>
+ <param group="FramebufferTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="FramebufferAttachment"><ptype>GLenum</ptype> <name>attachment</name></param>
+ <param group="Texture"><ptype>GLuint</ptype> <name>texture</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>layer</name></param>
+ <alias name="glFramebufferTextureLayer"/>
+ </command>
+ <command>
+ <proto>void <name>glFramebufferTextureLayerEXT</name></proto>
+ <param group="FramebufferTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="FramebufferAttachment"><ptype>GLenum</ptype> <name>attachment</name></param>
+ <param group="Texture"><ptype>GLuint</ptype> <name>texture</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>layer</name></param>
+ <alias name="glFramebufferTextureLayer"/>
+ </command>
+ <command>
+ <proto>void <name>glFreeObjectBufferATI</name></proto>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glFrontFace</name></proto>
+ <param group="FrontFaceDirection"><ptype>GLenum</ptype> <name>mode</name></param>
+ <glx type="render" opcode="84"/>
+ </command>
+ <command>
+ <proto>void <name>glFrustum</name></proto>
+ <param><ptype>GLdouble</ptype> <name>left</name></param>
+ <param><ptype>GLdouble</ptype> <name>right</name></param>
+ <param><ptype>GLdouble</ptype> <name>bottom</name></param>
+ <param><ptype>GLdouble</ptype> <name>top</name></param>
+ <param><ptype>GLdouble</ptype> <name>zNear</name></param>
+ <param><ptype>GLdouble</ptype> <name>zFar</name></param>
+ <glx type="render" opcode="175"/>
+ </command>
+ <command>
+ <proto>void <name>glFrustumf</name></proto>
+ <param><ptype>GLfloat</ptype> <name>l</name></param>
+ <param><ptype>GLfloat</ptype> <name>r</name></param>
+ <param><ptype>GLfloat</ptype> <name>b</name></param>
+ <param><ptype>GLfloat</ptype> <name>t</name></param>
+ <param><ptype>GLfloat</ptype> <name>n</name></param>
+ <param><ptype>GLfloat</ptype> <name>f</name></param>
+ </command>
+ <command>
+ <proto>void <name>glFrustumfOES</name></proto>
+ <param><ptype>GLfloat</ptype> <name>l</name></param>
+ <param><ptype>GLfloat</ptype> <name>r</name></param>
+ <param><ptype>GLfloat</ptype> <name>b</name></param>
+ <param><ptype>GLfloat</ptype> <name>t</name></param>
+ <param><ptype>GLfloat</ptype> <name>n</name></param>
+ <param><ptype>GLfloat</ptype> <name>f</name></param>
+ <glx type="render" opcode="4310"/>
+ </command>
+ <command>
+ <proto>void <name>glFrustumx</name></proto>
+ <param><ptype>GLfixed</ptype> <name>l</name></param>
+ <param><ptype>GLfixed</ptype> <name>r</name></param>
+ <param><ptype>GLfixed</ptype> <name>b</name></param>
+ <param><ptype>GLfixed</ptype> <name>t</name></param>
+ <param><ptype>GLfixed</ptype> <name>n</name></param>
+ <param><ptype>GLfixed</ptype> <name>f</name></param>
+ </command>
+ <command>
+ <proto>void <name>glFrustumxOES</name></proto>
+ <param><ptype>GLfixed</ptype> <name>l</name></param>
+ <param><ptype>GLfixed</ptype> <name>r</name></param>
+ <param><ptype>GLfixed</ptype> <name>b</name></param>
+ <param><ptype>GLfixed</ptype> <name>t</name></param>
+ <param><ptype>GLfixed</ptype> <name>n</name></param>
+ <param><ptype>GLfixed</ptype> <name>f</name></param>
+ </command>
+ <command>
+ <proto><ptype>GLuint</ptype> <name>glGenAsyncMarkersSGIX</name></proto>
+ <param><ptype>GLsizei</ptype> <name>range</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGenBuffers</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param len="n"><ptype>GLuint</ptype> *<name>buffers</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGenBuffersARB</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param len="n"><ptype>GLuint</ptype> *<name>buffers</name></param>
+ <alias name="glGenBuffers"/>
+ </command>
+ <command>
+ <proto>void <name>glGenFencesAPPLE</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param group="FenceNV" len="n"><ptype>GLuint</ptype> *<name>fences</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGenFencesNV</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param group="FenceNV" len="n"><ptype>GLuint</ptype> *<name>fences</name></param>
+ <glx type="vendor" opcode="1277"/>
+ </command>
+ <command>
+ <proto><ptype>GLuint</ptype> <name>glGenFragmentShadersATI</name></proto>
+ <param><ptype>GLuint</ptype> <name>range</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGenFramebuffers</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param len="n"><ptype>GLuint</ptype> *<name>framebuffers</name></param>
+ <glx type="vendor" opcode="1426"/>
+ </command>
+ <command>
+ <proto>void <name>glGenFramebuffersEXT</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param len="n"><ptype>GLuint</ptype> *<name>framebuffers</name></param>
+ <alias name="glGenFramebuffers"/>
+ <glx type="vendor" opcode="1426"/>
+ </command>
+ <command>
+ <proto>void <name>glGenFramebuffersOES</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param len="n"><ptype>GLuint</ptype> *<name>framebuffers</name></param>
+ </command>
+ <command>
+ <proto group="List"><ptype>GLuint</ptype> <name>glGenLists</name></proto>
+ <param><ptype>GLsizei</ptype> <name>range</name></param>
+ <glx type="single" opcode="104"/>
+ </command>
+ <command>
+ <proto>void <name>glGenNamesAMD</name></proto>
+ <param><ptype>GLenum</ptype> <name>identifier</name></param>
+ <param><ptype>GLuint</ptype> <name>num</name></param>
+ <param len="num"><ptype>GLuint</ptype> *<name>names</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGenOcclusionQueriesNV</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param len="n"><ptype>GLuint</ptype> *<name>ids</name></param>
+ </command>
+ <command>
+ <proto group="Path"><ptype>GLuint</ptype> <name>glGenPathsNV</name></proto>
+ <param><ptype>GLsizei</ptype> <name>range</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGenPerfMonitorsAMD</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param len="n"><ptype>GLuint</ptype> *<name>monitors</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGenProgramPipelines</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param len="n"><ptype>GLuint</ptype> *<name>pipelines</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGenProgramPipelinesEXT</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param len="n"><ptype>GLuint</ptype> *<name>pipelines</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGenProgramsARB</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param len="n"><ptype>GLuint</ptype> *<name>programs</name></param>
+ <glx type="vendor" opcode="1295"/>
+ </command>
+ <command>
+ <proto>void <name>glGenProgramsNV</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param len="n"><ptype>GLuint</ptype> *<name>programs</name></param>
+ <alias name="glGenProgramsARB"/>
+ <glx type="vendor" opcode="1295"/>
+ </command>
+ <command>
+ <proto>void <name>glGenQueries</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param len="n"><ptype>GLuint</ptype> *<name>ids</name></param>
+ <glx type="single" opcode="162"/>
+ </command>
+ <command>
+ <proto>void <name>glGenQueriesARB</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param len="n"><ptype>GLuint</ptype> *<name>ids</name></param>
+ <alias name="glGenQueries"/>
+ </command>
+ <command>
+ <proto>void <name>glGenQueriesEXT</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param len="n"><ptype>GLuint</ptype> *<name>ids</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGenRenderbuffers</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param len="n"><ptype>GLuint</ptype> *<name>renderbuffers</name></param>
+ <glx type="vendor" opcode="1423"/>
+ </command>
+ <command>
+ <proto>void <name>glGenRenderbuffersEXT</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param len="n"><ptype>GLuint</ptype> *<name>renderbuffers</name></param>
+ <alias name="glGenRenderbuffers"/>
+ <glx type="vendor" opcode="1423"/>
+ </command>
+ <command>
+ <proto>void <name>glGenRenderbuffersOES</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param len="n"><ptype>GLuint</ptype> *<name>renderbuffers</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGenSamplers</name></proto>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count"><ptype>GLuint</ptype> *<name>samplers</name></param>
+ </command>
+ <command>
+ <proto><ptype>GLuint</ptype> <name>glGenSymbolsEXT</name></proto>
+ <param group="DataTypeEXT"><ptype>GLenum</ptype> <name>datatype</name></param>
+ <param group="VertexShaderStorageTypeEXT"><ptype>GLenum</ptype> <name>storagetype</name></param>
+ <param group="ParameterRangeEXT"><ptype>GLenum</ptype> <name>range</name></param>
+ <param><ptype>GLuint</ptype> <name>components</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGenTextures</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param group="Texture" len="n"><ptype>GLuint</ptype> *<name>textures</name></param>
+ <glx type="single" opcode="145"/>
+ </command>
+ <command>
+ <proto>void <name>glGenTexturesEXT</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param group="Texture" len="n"><ptype>GLuint</ptype> *<name>textures</name></param>
+ <glx type="vendor" opcode="13"/>
+ </command>
+ <command>
+ <proto>void <name>glGenTransformFeedbacks</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param len="n"><ptype>GLuint</ptype> *<name>ids</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGenTransformFeedbacksNV</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param len="n"><ptype>GLuint</ptype> *<name>ids</name></param>
+ <alias name="glGenTransformFeedbacks"/>
+ </command>
+ <command>
+ <proto>void <name>glGenVertexArrays</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param len="n"><ptype>GLuint</ptype> *<name>arrays</name></param>
+ <glx type="single" opcode="206"/>
+ </command>
+ <command>
+ <proto>void <name>glGenVertexArraysAPPLE</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param len="n"><ptype>GLuint</ptype> *<name>arrays</name></param>
+ <alias name="glGenVertexArrays"/>
+ </command>
+ <command>
+ <proto>void <name>glGenVertexArraysOES</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param len="n"><ptype>GLuint</ptype> *<name>arrays</name></param>
+ <alias name="glGenVertexArrays"/>
+ </command>
+ <command>
+ <proto><ptype>GLuint</ptype> <name>glGenVertexShadersEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>range</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGenerateMipmap</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <glx type="render" opcode="4325"/>
+ </command>
+ <command>
+ <proto>void <name>glGenerateMipmapEXT</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <alias name="glGenerateMipmap"/>
+ <glx type="render" opcode="4325"/>
+ </command>
+ <command>
+ <proto>void <name>glGenerateMipmapOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGenerateMultiTexMipmapEXT</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>texunit</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGenerateTextureMipmap</name></proto>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGenerateTextureMipmapEXT</name></proto>
+ <param group="Texture"><ptype>GLuint</ptype> <name>texture</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetActiveAtomicCounterBufferiv</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLuint</ptype> <name>bufferIndex</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetActiveAttrib</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param len="1"><ptype>GLsizei</ptype> *<name>length</name></param>
+ <param len="1"><ptype>GLint</ptype> *<name>size</name></param>
+ <param len="1"><ptype>GLenum</ptype> *<name>type</name></param>
+ <param len="bufSize"><ptype>GLchar</ptype> *<name>name</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetActiveAttribARB</name></proto>
+ <param group="handleARB"><ptype>GLhandleARB</ptype> <name>programObj</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLsizei</ptype> <name>maxLength</name></param>
+ <param len="1"><ptype>GLsizei</ptype> *<name>length</name></param>
+ <param len="1"><ptype>GLint</ptype> *<name>size</name></param>
+ <param len="1"><ptype>GLenum</ptype> *<name>type</name></param>
+ <param len="maxLength"><ptype>GLcharARB</ptype> *<name>name</name></param>
+ <alias name="glGetActiveAttrib"/>
+ </command>
+ <command>
+ <proto>void <name>glGetActiveSubroutineName</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLenum</ptype> <name>shadertype</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufsize</name></param>
+ <param len="1"><ptype>GLsizei</ptype> *<name>length</name></param>
+ <param len="bufsize"><ptype>GLchar</ptype> *<name>name</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetActiveSubroutineUniformName</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLenum</ptype> <name>shadertype</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufsize</name></param>
+ <param len="1"><ptype>GLsizei</ptype> *<name>length</name></param>
+ <param len="bufsize"><ptype>GLchar</ptype> *<name>name</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetActiveSubroutineUniformiv</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLenum</ptype> <name>shadertype</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>values</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetActiveUniform</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param len="1"><ptype>GLsizei</ptype> *<name>length</name></param>
+ <param len="1"><ptype>GLint</ptype> *<name>size</name></param>
+ <param len="1"><ptype>GLenum</ptype> *<name>type</name></param>
+ <param len="bufSize"><ptype>GLchar</ptype> *<name>name</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetActiveUniformARB</name></proto>
+ <param group="handleARB"><ptype>GLhandleARB</ptype> <name>programObj</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLsizei</ptype> <name>maxLength</name></param>
+ <param len="1"><ptype>GLsizei</ptype> *<name>length</name></param>
+ <param len="1"><ptype>GLint</ptype> *<name>size</name></param>
+ <param len="1"><ptype>GLenum</ptype> *<name>type</name></param>
+ <param len="maxLength"><ptype>GLcharARB</ptype> *<name>name</name></param>
+ <alias name="glGetActiveUniform"/>
+ </command>
+ <command>
+ <proto>void <name>glGetActiveUniformBlockName</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLuint</ptype> <name>uniformBlockIndex</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param len="1"><ptype>GLsizei</ptype> *<name>length</name></param>
+ <param len="bufSize"><ptype>GLchar</ptype> *<name>uniformBlockName</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetActiveUniformBlockiv</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLuint</ptype> <name>uniformBlockIndex</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(program, uniformBlockIndex, pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetActiveUniformName</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLuint</ptype> <name>uniformIndex</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param len="1"><ptype>GLsizei</ptype> *<name>length</name></param>
+ <param len="bufSize"><ptype>GLchar</ptype> *<name>uniformName</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetActiveUniformsiv</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLsizei</ptype> <name>uniformCount</name></param>
+ <param len="uniformCount">const <ptype>GLuint</ptype> *<name>uniformIndices</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(uniformCount, pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetActiveVaryingNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param len="1"><ptype>GLsizei</ptype> *<name>length</name></param>
+ <param len="1"><ptype>GLsizei</ptype> *<name>size</name></param>
+ <param len="1"><ptype>GLenum</ptype> *<name>type</name></param>
+ <param len="COMPSIZE(program,index,bufSize)"><ptype>GLchar</ptype> *<name>name</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetArrayObjectfvATI</name></proto>
+ <param group="EnableCap"><ptype>GLenum</ptype> <name>array</name></param>
+ <param group="ArrayObjectPNameATI"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="1"><ptype>GLfloat</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetArrayObjectivATI</name></proto>
+ <param group="EnableCap"><ptype>GLenum</ptype> <name>array</name></param>
+ <param group="ArrayObjectPNameATI"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="1"><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command comment="Could be an alias of glGetAttachedShaders except that GLhandleARB is different on MacOS X">
+ <proto>void <name>glGetAttachedObjectsARB</name></proto>
+ <param group="handleARB"><ptype>GLhandleARB</ptype> <name>containerObj</name></param>
+ <param><ptype>GLsizei</ptype> <name>maxCount</name></param>
+ <param len="1"><ptype>GLsizei</ptype> *<name>count</name></param>
+ <param group="handleARB" len="maxCount"><ptype>GLhandleARB</ptype> *<name>obj</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetAttachedShaders</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLsizei</ptype> <name>maxCount</name></param>
+ <param len="1"><ptype>GLsizei</ptype> *<name>count</name></param>
+ <param len="maxCount"><ptype>GLuint</ptype> *<name>shaders</name></param>
+ </command>
+ <command>
+ <proto><ptype>GLint</ptype> <name>glGetAttribLocation</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param>const <ptype>GLchar</ptype> *<name>name</name></param>
+ </command>
+ <command>
+ <proto><ptype>GLint</ptype> <name>glGetAttribLocationARB</name></proto>
+ <param group="handleARB"><ptype>GLhandleARB</ptype> <name>programObj</name></param>
+ <param>const <ptype>GLcharARB</ptype> *<name>name</name></param>
+ <alias name="glGetAttribLocation"/>
+ </command>
+ <command>
+ <proto>void <name>glGetBooleanIndexedvEXT</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param group="Boolean" len="COMPSIZE(target)"><ptype>GLboolean</ptype> *<name>data</name></param>
+ <alias name="glGetBooleani_v"/>
+ </command>
+ <command>
+ <proto>void <name>glGetBooleani_v</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param group="Boolean" len="COMPSIZE(target)"><ptype>GLboolean</ptype> *<name>data</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetBooleanv</name></proto>
+ <param group="GetPName"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="Boolean" len="COMPSIZE(pname)"><ptype>GLboolean</ptype> *<name>data</name></param>
+ <glx type="single" opcode="112"/>
+ </command>
+ <command>
+ <proto>void <name>glGetBufferParameteri64v</name></proto>
+ <param group="BufferTargetARB"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="BufferPNameARB"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint64</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetBufferParameteriv</name></proto>
+ <param group="BufferTargetARB"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="BufferPNameARB"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetBufferParameterivARB</name></proto>
+ <param group="BufferTargetARB"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="BufferPNameARB"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ <alias name="glGetBufferParameteriv"/>
+ </command>
+ <command>
+ <proto>void <name>glGetBufferParameterui64vNV</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLuint64EXT</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetBufferPointerv</name></proto>
+ <param group="BufferTargetARB"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="BufferPointerNameARB"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="1">void **<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetBufferPointervARB</name></proto>
+ <param group="BufferTargetARB"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="BufferPointerNameARB"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="1">void **<name>params</name></param>
+ <alias name="glGetBufferPointerv"/>
+ </command>
+ <command>
+ <proto>void <name>glGetBufferPointervOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param>void **<name>params</name></param>
+ <alias name="glGetBufferPointerv"/>
+ </command>
+ <command>
+ <proto>void <name>glGetBufferSubData</name></proto>
+ <param group="BufferTargetARB"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="BufferOffset"><ptype>GLintptr</ptype> <name>offset</name></param>
+ <param group="BufferSize"><ptype>GLsizeiptr</ptype> <name>size</name></param>
+ <param len="size">void *<name>data</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetBufferSubDataARB</name></proto>
+ <param group="BufferTargetARB"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="BufferOffsetARB"><ptype>GLintptrARB</ptype> <name>offset</name></param>
+ <param group="BufferSizeARB"><ptype>GLsizeiptrARB</ptype> <name>size</name></param>
+ <param len="size">void *<name>data</name></param>
+ <alias name="glGetBufferSubData"/>
+ </command>
+ <command>
+ <proto>void <name>glGetClipPlane</name></proto>
+ <param group="ClipPlaneName"><ptype>GLenum</ptype> <name>plane</name></param>
+ <param len="4"><ptype>GLdouble</ptype> *<name>equation</name></param>
+ <glx type="single" opcode="113"/>
+ </command>
+ <command>
+ <proto>void <name>glGetClipPlanef</name></proto>
+ <param><ptype>GLenum</ptype> <name>plane</name></param>
+ <param len="4"><ptype>GLfloat</ptype> *<name>equation</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetClipPlanefOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>plane</name></param>
+ <param len="4"><ptype>GLfloat</ptype> *<name>equation</name></param>
+ <glx type="vendor" opcode="1421"/>
+ </command>
+ <command>
+ <proto>void <name>glGetClipPlanex</name></proto>
+ <param><ptype>GLenum</ptype> <name>plane</name></param>
+ <param len="4"><ptype>GLfixed</ptype> *<name>equation</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetClipPlanexOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>plane</name></param>
+ <param len="4"><ptype>GLfixed</ptype> *<name>equation</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetColorTable</name></proto>
+ <param group="ColorTableTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param group="PixelType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(target,format,type)">void *<name>table</name></param>
+ <glx type="single" opcode="147"/>
+ <glx type="render" opcode="334" name="glGetColorTablePBO" comment="PBO protocol"/>
+ </command>
+ <command>
+ <proto>void <name>glGetColorTableEXT</name></proto>
+ <param group="ColorTableTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param group="PixelType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(target,format,type)">void *<name>data</name></param>
+ <alias name="glGetColorTable"/>
+ </command>
+ <command>
+ <proto>void <name>glGetColorTableParameterfv</name></proto>
+ <param group="ColorTableTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="GetColorTableParameterPName"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLfloat</ptype> *<name>params</name></param>
+ <glx type="single" opcode="148"/>
+ </command>
+ <command>
+ <proto>void <name>glGetColorTableParameterfvEXT</name></proto>
+ <param group="ColorTableTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="GetColorTableParameterPName"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLfloat</ptype> *<name>params</name></param>
+ <alias name="glGetColorTableParameterfv"/>
+ </command>
+ <command>
+ <proto>void <name>glGetColorTableParameterfvSGI</name></proto>
+ <param group="ColorTableTargetSGI"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="GetColorTableParameterPNameSGI"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLfloat</ptype> *<name>params</name></param>
+ <glx type="vendor" opcode="4099"/>
+ </command>
+ <command>
+ <proto>void <name>glGetColorTableParameteriv</name></proto>
+ <param group="ColorTableTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="GetColorTableParameterPName"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ <glx type="single" opcode="149"/>
+ </command>
+ <command>
+ <proto>void <name>glGetColorTableParameterivEXT</name></proto>
+ <param group="ColorTableTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="GetColorTableParameterPName"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ <alias name="glGetColorTableParameteriv"/>
+ </command>
+ <command>
+ <proto>void <name>glGetColorTableParameterivSGI</name></proto>
+ <param group="ColorTableTargetSGI"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="GetColorTableParameterPNameSGI"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ <glx type="vendor" opcode="4100"/>
+ </command>
+ <command>
+ <proto>void <name>glGetColorTableSGI</name></proto>
+ <param group="ColorTableTargetSGI"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param group="PixelType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(target,format,type)">void *<name>table</name></param>
+ <glx type="vendor" opcode="4098"/>
+ </command>
+ <command>
+ <proto>void <name>glGetCombinerInputParameterfvNV</name></proto>
+ <param group="CombinerStageNV"><ptype>GLenum</ptype> <name>stage</name></param>
+ <param group="CombinerPortionNV"><ptype>GLenum</ptype> <name>portion</name></param>
+ <param group="CombinerVariableNV"><ptype>GLenum</ptype> <name>variable</name></param>
+ <param group="CombinerParameterNV"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLfloat</ptype> *<name>params</name></param>
+ <glx type="vendor" opcode="1270"/>
+ </command>
+ <command>
+ <proto>void <name>glGetCombinerInputParameterivNV</name></proto>
+ <param group="CombinerStageNV"><ptype>GLenum</ptype> <name>stage</name></param>
+ <param group="CombinerPortionNV"><ptype>GLenum</ptype> <name>portion</name></param>
+ <param group="CombinerVariableNV"><ptype>GLenum</ptype> <name>variable</name></param>
+ <param group="CombinerParameterNV"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ <glx type="vendor" opcode="1271"/>
+ </command>
+ <command>
+ <proto>void <name>glGetCombinerOutputParameterfvNV</name></proto>
+ <param group="CombinerStageNV"><ptype>GLenum</ptype> <name>stage</name></param>
+ <param group="CombinerPortionNV"><ptype>GLenum</ptype> <name>portion</name></param>
+ <param group="CombinerParameterNV"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLfloat</ptype> *<name>params</name></param>
+ <glx type="vendor" opcode="1272"/>
+ </command>
+ <command>
+ <proto>void <name>glGetCombinerOutputParameterivNV</name></proto>
+ <param group="CombinerStageNV"><ptype>GLenum</ptype> <name>stage</name></param>
+ <param group="CombinerPortionNV"><ptype>GLenum</ptype> <name>portion</name></param>
+ <param group="CombinerParameterNV"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ <glx type="vendor" opcode="1273"/>
+ </command>
+ <command>
+ <proto>void <name>glGetCombinerStageParameterfvNV</name></proto>
+ <param group="CombinerStageNV"><ptype>GLenum</ptype> <name>stage</name></param>
+ <param group="CombinerParameterNV"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLfloat</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetCompressedMultiTexImageEXT</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>texunit</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>lod</name></param>
+ <param len="COMPSIZE(target,lod)">void *<name>img</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetCompressedTexImage</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="CompressedTextureARB" len="COMPSIZE(target,level)">void *<name>img</name></param>
+ <glx type="single" opcode="160"/>
+ <glx type="render" opcode="335" name="glGetCompressedTexImagePBO" comment="PBO protocol"/>
+ </command>
+ <command>
+ <proto>void <name>glGetCompressedTexImageARB</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="CompressedTextureARB" len="COMPSIZE(target,level)">void *<name>img</name></param>
+ <alias name="glGetCompressedTexImage"/>
+ <glx type="single" opcode="160"/>
+ </command>
+ <command>
+ <proto>void <name>glGetCompressedTextureImage</name></proto>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLint</ptype> <name>level</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param>void *<name>pixels</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetCompressedTextureImageEXT</name></proto>
+ <param group="Texture"><ptype>GLuint</ptype> <name>texture</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>lod</name></param>
+ <param len="COMPSIZE(target,lod)">void *<name>img</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetCompressedTextureSubImage</name></proto>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLint</ptype> <name>level</name></param>
+ <param><ptype>GLint</ptype> <name>xoffset</name></param>
+ <param><ptype>GLint</ptype> <name>yoffset</name></param>
+ <param><ptype>GLint</ptype> <name>zoffset</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param><ptype>GLsizei</ptype> <name>depth</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param>void *<name>pixels</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetConvolutionFilter</name></proto>
+ <param group="ConvolutionTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param group="PixelType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(target,format,type)">void *<name>image</name></param>
+ <glx type="single" opcode="150"/>
+ <glx type="render" opcode="336" name="glGetConvolutionFilterPBO" comment="PBO protocol"/>
+ </command>
+ <command>
+ <proto>void <name>glGetConvolutionFilterEXT</name></proto>
+ <param group="ConvolutionTargetEXT"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param group="PixelType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(target,format,type)">void *<name>image</name></param>
+ <glx type="vendor" opcode="1"/>
+ </command>
+ <command>
+ <proto>void <name>glGetConvolutionParameterfv</name></proto>
+ <param group="ConvolutionTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="GetConvolutionParameterPName"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLfloat</ptype> *<name>params</name></param>
+ <glx type="single" opcode="151"/>
+ </command>
+ <command>
+ <proto>void <name>glGetConvolutionParameterfvEXT</name></proto>
+ <param group="ConvolutionTargetEXT"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="ConvolutionParameterEXT"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLfloat</ptype> *<name>params</name></param>
+ <glx type="vendor" opcode="2"/>
+ </command>
+ <command>
+ <proto>void <name>glGetConvolutionParameteriv</name></proto>
+ <param group="ConvolutionTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="GetConvolutionParameterPName"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ <glx type="single" opcode="152"/>
+ </command>
+ <command>
+ <proto>void <name>glGetConvolutionParameterivEXT</name></proto>
+ <param group="ConvolutionTargetEXT"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="ConvolutionParameterEXT"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ <glx type="vendor" opcode="3"/>
+ </command>
+ <command>
+ <proto>void <name>glGetConvolutionParameterxvOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLfixed</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto><ptype>GLuint</ptype> <name>glGetDebugMessageLog</name></proto>
+ <param><ptype>GLuint</ptype> <name>count</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param len="count"><ptype>GLenum</ptype> *<name>sources</name></param>
+ <param len="count"><ptype>GLenum</ptype> *<name>types</name></param>
+ <param len="count"><ptype>GLuint</ptype> *<name>ids</name></param>
+ <param len="count"><ptype>GLenum</ptype> *<name>severities</name></param>
+ <param len="count"><ptype>GLsizei</ptype> *<name>lengths</name></param>
+ <param len="bufSize"><ptype>GLchar</ptype> *<name>messageLog</name></param>
+ </command>
+ <command>
+ <proto><ptype>GLuint</ptype> <name>glGetDebugMessageLogAMD</name></proto>
+ <param><ptype>GLuint</ptype> <name>count</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufsize</name></param>
+ <param len="count"><ptype>GLenum</ptype> *<name>categories</name></param>
+ <param len="count"><ptype>GLuint</ptype> *<name>severities</name></param>
+ <param len="count"><ptype>GLuint</ptype> *<name>ids</name></param>
+ <param len="count"><ptype>GLsizei</ptype> *<name>lengths</name></param>
+ <param len="bufsize"><ptype>GLchar</ptype> *<name>message</name></param>
+ </command>
+ <command>
+ <proto><ptype>GLuint</ptype> <name>glGetDebugMessageLogARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>count</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param len="count"><ptype>GLenum</ptype> *<name>sources</name></param>
+ <param len="count"><ptype>GLenum</ptype> *<name>types</name></param>
+ <param len="count"><ptype>GLuint</ptype> *<name>ids</name></param>
+ <param len="count"><ptype>GLenum</ptype> *<name>severities</name></param>
+ <param len="count"><ptype>GLsizei</ptype> *<name>lengths</name></param>
+ <param len="bufSize"><ptype>GLchar</ptype> *<name>messageLog</name></param>
+ <alias name="glGetDebugMessageLog"/>
+ </command>
+ <command>
+ <proto><ptype>GLuint</ptype> <name>glGetDebugMessageLogKHR</name></proto>
+ <param><ptype>GLuint</ptype> <name>count</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param len="count"><ptype>GLenum</ptype> *<name>sources</name></param>
+ <param len="count"><ptype>GLenum</ptype> *<name>types</name></param>
+ <param len="count"><ptype>GLuint</ptype> *<name>ids</name></param>
+ <param len="count"><ptype>GLenum</ptype> *<name>severities</name></param>
+ <param len="count"><ptype>GLsizei</ptype> *<name>lengths</name></param>
+ <param len="bufSize"><ptype>GLchar</ptype> *<name>messageLog</name></param>
+ <alias name="glGetDebugMessageLog"/>
+ </command>
+ <command>
+ <proto>void <name>glGetDetailTexFuncSGIS</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param len="COMPSIZE(target)"><ptype>GLfloat</ptype> *<name>points</name></param>
+ <glx type="vendor" opcode="4096"/>
+ </command>
+ <command>
+ <proto>void <name>glGetDoubleIndexedvEXT</name></proto>
+ <param group="TypeEnum"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="COMPSIZE(target)"><ptype>GLdouble</ptype> *<name>data</name></param>
+ <alias name="glGetDoublei_v"/>
+ </command>
+ <command>
+ <proto>void <name>glGetDoublei_v</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="COMPSIZE(target)"><ptype>GLdouble</ptype> *<name>data</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetDoublei_vEXT</name></proto>
+ <param group="TypeEnum"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="COMPSIZE(target)"><ptype>GLdouble</ptype> *<name>params</name></param>
+ <alias name="glGetDoublei_v"/>
+ </command>
+ <command>
+ <proto>void <name>glGetDoublev</name></proto>
+ <param group="GetPName"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLdouble</ptype> *<name>data</name></param>
+ <glx type="single" opcode="114"/>
+ </command>
+ <command>
+ <proto>void <name>glGetDriverControlStringQCOM</name></proto>
+ <param><ptype>GLuint</ptype> <name>driverControl</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param><ptype>GLsizei</ptype> *<name>length</name></param>
+ <param len="bufSize"><ptype>GLchar</ptype> *<name>driverControlString</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetDriverControlsQCOM</name></proto>
+ <param><ptype>GLint</ptype> *<name>num</name></param>
+ <param><ptype>GLsizei</ptype> <name>size</name></param>
+ <param len="size"><ptype>GLuint</ptype> *<name>driverControls</name></param>
+ </command>
+ <command>
+ <proto group="ErrorCode"><ptype>GLenum</ptype> <name>glGetError</name></proto>
+ <glx type="single" opcode="115"/>
+ </command>
+ <command>
+ <proto>void <name>glGetFenceivNV</name></proto>
+ <param group="FenceNV"><ptype>GLuint</ptype> <name>fence</name></param>
+ <param group="FenceParameterNameNV"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ <glx type="vendor" opcode="1280"/>
+ </command>
+ <command>
+ <proto>void <name>glGetFinalCombinerInputParameterfvNV</name></proto>
+ <param group="CombinerVariableNV"><ptype>GLenum</ptype> <name>variable</name></param>
+ <param group="CombinerParameterNV"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLfloat</ptype> *<name>params</name></param>
+ <glx type="vendor" opcode="1274"/>
+ </command>
+ <command>
+ <proto>void <name>glGetFinalCombinerInputParameterivNV</name></proto>
+ <param group="CombinerVariableNV"><ptype>GLenum</ptype> <name>variable</name></param>
+ <param group="CombinerParameterNV"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ <glx type="vendor" opcode="1275"/>
+ </command>
+ <command>
+ <proto>void <name>glGetFirstPerfQueryIdINTEL</name></proto>
+ <param><ptype>GLuint</ptype> *<name>queryId</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetFixedv</name></proto>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLfixed</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetFixedvOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLfixed</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetFloatIndexedvEXT</name></proto>
+ <param group="TypeEnum"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="COMPSIZE(target)"><ptype>GLfloat</ptype> *<name>data</name></param>
+ <alias name="glGetFloati_v"/>
+ </command>
+ <command>
+ <proto>void <name>glGetFloati_v</name></proto>
+ <param group="TypeEnum"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="COMPSIZE(target)"><ptype>GLfloat</ptype> *<name>data</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetFloati_vEXT</name></proto>
+ <param group="TypeEnum"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="COMPSIZE(target)"><ptype>GLfloat</ptype> *<name>params</name></param>
+ <alias name="glGetFloati_v"/>
+ </command>
+ <command>
+ <proto>void <name>glGetFloatv</name></proto>
+ <param group="GetPName"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLfloat</ptype> *<name>data</name></param>
+ <glx type="single" opcode="116"/>
+ </command>
+ <command>
+ <proto>void <name>glGetFogFuncSGIS</name></proto>
+ <param len="COMPSIZE()"><ptype>GLfloat</ptype> *<name>points</name></param>
+ </command>
+ <command>
+ <proto><ptype>GLint</ptype> <name>glGetFragDataIndex</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param>const <ptype>GLchar</ptype> *<name>name</name></param>
+ </command>
+ <command>
+ <proto><ptype>GLint</ptype> <name>glGetFragDataLocation</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param len="COMPSIZE(name)">const <ptype>GLchar</ptype> *<name>name</name></param>
+ </command>
+ <command>
+ <proto><ptype>GLint</ptype> <name>glGetFragDataLocationEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param len="COMPSIZE(name)">const <ptype>GLchar</ptype> *<name>name</name></param>
+ <alias name="glGetFragDataLocation"/>
+ </command>
+ <command>
+ <proto>void <name>glGetFragmentLightfvSGIX</name></proto>
+ <param group="FragmentLightNameSGIX"><ptype>GLenum</ptype> <name>light</name></param>
+ <param group="FragmentLightParameterSGIX"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLfloat</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetFragmentLightivSGIX</name></proto>
+ <param group="FragmentLightNameSGIX"><ptype>GLenum</ptype> <name>light</name></param>
+ <param group="FragmentLightParameterSGIX"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetFragmentMaterialfvSGIX</name></proto>
+ <param group="MaterialFace"><ptype>GLenum</ptype> <name>face</name></param>
+ <param group="MaterialParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLfloat</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetFragmentMaterialivSGIX</name></proto>
+ <param group="MaterialFace"><ptype>GLenum</ptype> <name>face</name></param>
+ <param group="MaterialParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetFramebufferAttachmentParameteriv</name></proto>
+ <param group="FramebufferTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="FramebufferAttachment"><ptype>GLenum</ptype> <name>attachment</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ <glx type="vendor" opcode="1428"/>
+ </command>
+ <command>
+ <proto>void <name>glGetFramebufferAttachmentParameterivEXT</name></proto>
+ <param group="FramebufferTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="FramebufferAttachment"><ptype>GLenum</ptype> <name>attachment</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ <alias name="glGetFramebufferAttachmentParameteriv"/>
+ <glx type="vendor" opcode="1428"/>
+ </command>
+ <command>
+ <proto>void <name>glGetFramebufferAttachmentParameterivOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>attachment</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetFramebufferParameteriv</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetFramebufferParameterivEXT</name></proto>
+ <param group="Framebuffer"><ptype>GLuint</ptype> <name>framebuffer</name></param>
+ <param group="GetFramebufferParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto><ptype>GLenum</ptype> <name>glGetGraphicsResetStatus</name></proto>
+ </command>
+ <command>
+ <proto><ptype>GLenum</ptype> <name>glGetGraphicsResetStatusARB</name></proto>
+ </command>
+ <command>
+ <proto><ptype>GLenum</ptype> <name>glGetGraphicsResetStatusEXT</name></proto>
+ </command>
+ <command>
+ <proto><ptype>GLenum</ptype> <name>glGetGraphicsResetStatusKHR</name></proto>
+ <alias name="glGetGraphicsResetStatus"/>
+ </command>
+ <command>
+ <proto group="handleARB"><ptype>GLhandleARB</ptype> <name>glGetHandleARB</name></proto>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetHistogram</name></proto>
+ <param group="HistogramTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>reset</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param group="PixelType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(target,format,type)">void *<name>values</name></param>
+ <glx type="single" opcode="154"/>
+ <glx type="render" opcode="337" name="glGetHistogramPBO" comment="PBO protocol"/>
+ </command>
+ <command>
+ <proto>void <name>glGetHistogramEXT</name></proto>
+ <param group="HistogramTargetEXT"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>reset</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param group="PixelType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(target,format,type)">void *<name>values</name></param>
+ <glx type="vendor" opcode="5"/>
+ </command>
+ <command>
+ <proto>void <name>glGetHistogramParameterfv</name></proto>
+ <param group="HistogramTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="GetHistogramParameterPName"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLfloat</ptype> *<name>params</name></param>
+ <glx type="single" opcode="155"/>
+ </command>
+ <command>
+ <proto>void <name>glGetHistogramParameterfvEXT</name></proto>
+ <param group="HistogramTargetEXT"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="GetHistogramParameterPNameEXT"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLfloat</ptype> *<name>params</name></param>
+ <glx type="vendor" opcode="6"/>
+ </command>
+ <command>
+ <proto>void <name>glGetHistogramParameteriv</name></proto>
+ <param group="HistogramTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="GetHistogramParameterPName"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ <glx type="single" opcode="156"/>
+ </command>
+ <command>
+ <proto>void <name>glGetHistogramParameterivEXT</name></proto>
+ <param group="HistogramTargetEXT"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="GetHistogramParameterPNameEXT"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ <glx type="vendor" opcode="7"/>
+ </command>
+ <command>
+ <proto>void <name>glGetHistogramParameterxvOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLfixed</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto><ptype>GLuint64</ptype> <name>glGetImageHandleARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLint</ptype> <name>level</name></param>
+ <param><ptype>GLboolean</ptype> <name>layered</name></param>
+ <param><ptype>GLint</ptype> <name>layer</name></param>
+ <param><ptype>GLenum</ptype> <name>format</name></param>
+ </command>
+ <command>
+ <proto><ptype>GLuint64</ptype> <name>glGetImageHandleNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLint</ptype> <name>level</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>layered</name></param>
+ <param><ptype>GLint</ptype> <name>layer</name></param>
+ <param><ptype>GLenum</ptype> <name>format</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetImageTransformParameterfvHP</name></proto>
+ <param group="ImageTransformTargetHP"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="ImageTransformPNameHP"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLfloat</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetImageTransformParameterivHP</name></proto>
+ <param group="ImageTransformTargetHP"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="ImageTransformPNameHP"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetInfoLogARB</name></proto>
+ <param group="handleARB"><ptype>GLhandleARB</ptype> <name>obj</name></param>
+ <param><ptype>GLsizei</ptype> <name>maxLength</name></param>
+ <param len="1"><ptype>GLsizei</ptype> *<name>length</name></param>
+ <param len="maxLength"><ptype>GLcharARB</ptype> *<name>infoLog</name></param>
+ </command>
+ <command>
+ <proto><ptype>GLint</ptype> <name>glGetInstrumentsSGIX</name></proto>
+ <glx type="vendor" opcode="4102"/>
+ </command>
+ <command>
+ <proto>void <name>glGetInteger64i_v</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="COMPSIZE(target)"><ptype>GLint64</ptype> *<name>data</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetInteger64v</name></proto>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint64</ptype> *<name>data</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetInteger64vAPPLE</name></proto>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLint64</ptype> *<name>params</name></param>
+ <alias name="glGetInteger64v"/>
+ </command>
+ <command>
+ <proto>void <name>glGetIntegerIndexedvEXT</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="COMPSIZE(target)"><ptype>GLint</ptype> *<name>data</name></param>
+ <alias name="glGetIntegeri_v"/>
+ </command>
+ <command>
+ <proto>void <name>glGetIntegeri_v</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="COMPSIZE(target)"><ptype>GLint</ptype> *<name>data</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetIntegeri_vEXT</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLint</ptype> *<name>data</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetIntegerui64i_vNV</name></proto>
+ <param><ptype>GLenum</ptype> <name>value</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="COMPSIZE(value)"><ptype>GLuint64EXT</ptype> *<name>result</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetIntegerui64vNV</name></proto>
+ <param><ptype>GLenum</ptype> <name>value</name></param>
+ <param len="COMPSIZE(value)"><ptype>GLuint64EXT</ptype> *<name>result</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetIntegerv</name></proto>
+ <param group="GetPName"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>data</name></param>
+ <glx type="single" opcode="117"/>
+ </command>
+ <command>
+ <proto>void <name>glGetInternalformati64v</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param len="bufSize"><ptype>GLint64</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetInternalformativ</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param len="bufSize"><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetInvariantBooleanvEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <param group="GetVariantValueEXT"><ptype>GLenum</ptype> <name>value</name></param>
+ <param group="Boolean" len="COMPSIZE(id)"><ptype>GLboolean</ptype> *<name>data</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetInvariantFloatvEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <param group="GetVariantValueEXT"><ptype>GLenum</ptype> <name>value</name></param>
+ <param len="COMPSIZE(id)"><ptype>GLfloat</ptype> *<name>data</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetInvariantIntegervEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <param group="GetVariantValueEXT"><ptype>GLenum</ptype> <name>value</name></param>
+ <param len="COMPSIZE(id)"><ptype>GLint</ptype> *<name>data</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetLightfv</name></proto>
+ <param group="LightName"><ptype>GLenum</ptype> <name>light</name></param>
+ <param group="LightParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLfloat</ptype> *<name>params</name></param>
+ <glx type="single" opcode="118"/>
+ </command>
+ <command>
+ <proto>void <name>glGetLightiv</name></proto>
+ <param group="LightName"><ptype>GLenum</ptype> <name>light</name></param>
+ <param group="LightParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ <glx type="single" opcode="119"/>
+ </command>
+ <command>
+ <proto>void <name>glGetLightxOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>light</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLfixed</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetLightxv</name></proto>
+ <param><ptype>GLenum</ptype> <name>light</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLfixed</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetLightxvOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>light</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLfixed</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetListParameterfvSGIX</name></proto>
+ <param group="List"><ptype>GLuint</ptype> <name>list</name></param>
+ <param group="ListParameterName"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedFloat32" len="COMPSIZE(pname)"><ptype>GLfloat</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetListParameterivSGIX</name></proto>
+ <param group="List"><ptype>GLuint</ptype> <name>list</name></param>
+ <param group="ListParameterName"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedInt32" len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetLocalConstantBooleanvEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <param group="GetVariantValueEXT"><ptype>GLenum</ptype> <name>value</name></param>
+ <param group="Boolean" len="COMPSIZE(id)"><ptype>GLboolean</ptype> *<name>data</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetLocalConstantFloatvEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <param group="GetVariantValueEXT"><ptype>GLenum</ptype> <name>value</name></param>
+ <param len="COMPSIZE(id)"><ptype>GLfloat</ptype> *<name>data</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetLocalConstantIntegervEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <param group="GetVariantValueEXT"><ptype>GLenum</ptype> <name>value</name></param>
+ <param len="COMPSIZE(id)"><ptype>GLint</ptype> *<name>data</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetMapAttribParameterfvNV</name></proto>
+ <param group="EvalTargetNV"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param group="MapAttribParameterNV"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLfloat</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetMapAttribParameterivNV</name></proto>
+ <param group="EvalTargetNV"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param group="MapAttribParameterNV"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetMapControlPointsNV</name></proto>
+ <param group="EvalTargetNV"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param group="MapTypeNV"><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>ustride</name></param>
+ <param><ptype>GLsizei</ptype> <name>vstride</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>packed</name></param>
+ <param len="COMPSIZE(target)">void *<name>points</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetMapParameterfvNV</name></proto>
+ <param group="EvalTargetNV"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="MapParameterNV"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(target,pname)"><ptype>GLfloat</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetMapParameterivNV</name></proto>
+ <param group="EvalTargetNV"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="MapParameterNV"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(target,pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetMapdv</name></proto>
+ <param group="MapTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="GetMapQuery"><ptype>GLenum</ptype> <name>query</name></param>
+ <param len="COMPSIZE(target,query)"><ptype>GLdouble</ptype> *<name>v</name></param>
+ <glx type="single" opcode="120"/>
+ </command>
+ <command>
+ <proto>void <name>glGetMapfv</name></proto>
+ <param group="MapTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="GetMapQuery"><ptype>GLenum</ptype> <name>query</name></param>
+ <param len="COMPSIZE(target,query)"><ptype>GLfloat</ptype> *<name>v</name></param>
+ <glx type="single" opcode="121"/>
+ </command>
+ <command>
+ <proto>void <name>glGetMapiv</name></proto>
+ <param group="MapTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="GetMapQuery"><ptype>GLenum</ptype> <name>query</name></param>
+ <param len="COMPSIZE(target,query)"><ptype>GLint</ptype> *<name>v</name></param>
+ <glx type="single" opcode="122"/>
+ </command>
+ <command>
+ <proto>void <name>glGetMapxvOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>query</name></param>
+ <param len="COMPSIZE(query)"><ptype>GLfixed</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetMaterialfv</name></proto>
+ <param group="MaterialFace"><ptype>GLenum</ptype> <name>face</name></param>
+ <param group="MaterialParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLfloat</ptype> *<name>params</name></param>
+ <glx type="single" opcode="123"/>
+ </command>
+ <command>
+ <proto>void <name>glGetMaterialiv</name></proto>
+ <param group="MaterialFace"><ptype>GLenum</ptype> <name>face</name></param>
+ <param group="MaterialParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ <glx type="single" opcode="124"/>
+ </command>
+ <command>
+ <proto>void <name>glGetMaterialxOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>face</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLfixed</ptype> <name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetMaterialxv</name></proto>
+ <param><ptype>GLenum</ptype> <name>face</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLfixed</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetMaterialxvOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>face</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLfixed</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetMinmax</name></proto>
+ <param group="MinmaxTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>reset</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param group="PixelType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(target,format,type)">void *<name>values</name></param>
+ <glx type="single" opcode="157"/>
+ <glx type="render" opcode="338" name="glGetMinmaxPBO" comment="PBO protocol"/>
+ </command>
+ <command>
+ <proto>void <name>glGetMinmaxEXT</name></proto>
+ <param group="MinmaxTargetEXT"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>reset</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param group="PixelType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(target,format,type)">void *<name>values</name></param>
+ <glx type="vendor" opcode="8"/>
+ </command>
+ <command>
+ <proto>void <name>glGetMinmaxParameterfv</name></proto>
+ <param group="MinmaxTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="GetMinmaxParameterPName"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLfloat</ptype> *<name>params</name></param>
+ <glx type="single" opcode="158"/>
+ </command>
+ <command>
+ <proto>void <name>glGetMinmaxParameterfvEXT</name></proto>
+ <param group="MinmaxTargetEXT"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="GetMinmaxParameterPNameEXT"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLfloat</ptype> *<name>params</name></param>
+ <glx type="vendor" opcode="9"/>
+ </command>
+ <command>
+ <proto>void <name>glGetMinmaxParameteriv</name></proto>
+ <param group="MinmaxTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="GetMinmaxParameterPName"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ <glx type="single" opcode="159"/>
+ </command>
+ <command>
+ <proto>void <name>glGetMinmaxParameterivEXT</name></proto>
+ <param group="MinmaxTargetEXT"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="GetMinmaxParameterPNameEXT"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ <glx type="vendor" opcode="10"/>
+ </command>
+ <command>
+ <proto>void <name>glGetMultiTexEnvfvEXT</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>texunit</name></param>
+ <param group="TextureEnvTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="TextureEnvParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLfloat</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetMultiTexEnvivEXT</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>texunit</name></param>
+ <param group="TextureEnvTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="TextureEnvParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetMultiTexGendvEXT</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>texunit</name></param>
+ <param group="TextureCoordName"><ptype>GLenum</ptype> <name>coord</name></param>
+ <param group="TextureGenParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLdouble</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetMultiTexGenfvEXT</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>texunit</name></param>
+ <param group="TextureCoordName"><ptype>GLenum</ptype> <name>coord</name></param>
+ <param group="TextureGenParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLfloat</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetMultiTexGenivEXT</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>texunit</name></param>
+ <param group="TextureCoordName"><ptype>GLenum</ptype> <name>coord</name></param>
+ <param group="TextureGenParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetMultiTexImageEXT</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>texunit</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param group="PixelType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(target,level,format,type)">void *<name>pixels</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetMultiTexLevelParameterfvEXT</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>texunit</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="GetTextureParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLfloat</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetMultiTexLevelParameterivEXT</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>texunit</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="GetTextureParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetMultiTexParameterIivEXT</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>texunit</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="GetTextureParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetMultiTexParameterIuivEXT</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>texunit</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="GetTextureParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLuint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetMultiTexParameterfvEXT</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>texunit</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="GetTextureParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLfloat</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetMultiTexParameterivEXT</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>texunit</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="GetTextureParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetMultisamplefv</name></proto>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLfloat</ptype> *<name>val</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetMultisamplefvNV</name></proto>
+ <param group="GetMultisamplePNameNV"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="2"><ptype>GLfloat</ptype> *<name>val</name></param>
+ <alias name="glGetMultisamplefv"/>
+ </command>
+ <command>
+ <proto>void <name>glGetNamedBufferParameteri64v</name></proto>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLint64</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetNamedBufferParameteriv</name></proto>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetNamedBufferParameterivEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <param group="VertexBufferObjectParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetNamedBufferParameterui64vNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <param group="VertexBufferObjectParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLuint64EXT</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetNamedBufferPointerv</name></proto>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param>void **<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetNamedBufferPointervEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <param group="VertexBufferObjectParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="1">void **<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetNamedBufferSubData</name></proto>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <param><ptype>GLintptr</ptype> <name>offset</name></param>
+ <param><ptype>GLsizei</ptype> <name>size</name></param>
+ <param>void *<name>data</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetNamedBufferSubDataEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <param><ptype>GLintptr</ptype> <name>offset</name></param>
+ <param><ptype>GLsizeiptr</ptype> <name>size</name></param>
+ <param len="COMPSIZE(size)">void *<name>data</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetNamedFramebufferAttachmentParameteriv</name></proto>
+ <param><ptype>GLuint</ptype> <name>framebuffer</name></param>
+ <param><ptype>GLenum</ptype> <name>attachment</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetNamedFramebufferAttachmentParameterivEXT</name></proto>
+ <param group="Framebuffer"><ptype>GLuint</ptype> <name>framebuffer</name></param>
+ <param group="FramebufferAttachment"><ptype>GLenum</ptype> <name>attachment</name></param>
+ <param group="FramebufferAttachmentParameterName"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetNamedFramebufferParameteriv</name></proto>
+ <param><ptype>GLuint</ptype> <name>framebuffer</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLint</ptype> *<name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetNamedFramebufferParameterivEXT</name></proto>
+ <param group="Framebuffer"><ptype>GLuint</ptype> <name>framebuffer</name></param>
+ <param group="GetFramebufferParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetNamedProgramLocalParameterIivEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param group="ProgramTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4"><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetNamedProgramLocalParameterIuivEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param group="ProgramTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4"><ptype>GLuint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetNamedProgramLocalParameterdvEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param group="ProgramTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4"><ptype>GLdouble</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetNamedProgramLocalParameterfvEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param group="ProgramTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4"><ptype>GLfloat</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetNamedProgramStringEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param group="ProgramTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="ProgramStringProperty"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(program,pname)">void *<name>string</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetNamedProgramivEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param group="ProgramTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="ProgramProperty"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="1"><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetNamedRenderbufferParameteriv</name></proto>
+ <param><ptype>GLuint</ptype> <name>renderbuffer</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetNamedRenderbufferParameterivEXT</name></proto>
+ <param group="Renderbuffer"><ptype>GLuint</ptype> <name>renderbuffer</name></param>
+ <param group="RenderbufferParameterName"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetNamedStringARB</name></proto>
+ <param><ptype>GLint</ptype> <name>namelen</name></param>
+ <param len="namelen">const <ptype>GLchar</ptype> *<name>name</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param len="1"><ptype>GLint</ptype> *<name>stringlen</name></param>
+ <param len="bufSize"><ptype>GLchar</ptype> *<name>string</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetNamedStringivARB</name></proto>
+ <param><ptype>GLint</ptype> <name>namelen</name></param>
+ <param len="namelen">const <ptype>GLchar</ptype> *<name>name</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetNextPerfQueryIdINTEL</name></proto>
+ <param><ptype>GLuint</ptype> <name>queryId</name></param>
+ <param><ptype>GLuint</ptype> *<name>nextQueryId</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetObjectBufferfvATI</name></proto>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <param group="ArrayObjectPNameATI"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="1"><ptype>GLfloat</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetObjectBufferivATI</name></proto>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <param group="ArrayObjectPNameATI"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="1"><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetObjectLabel</name></proto>
+ <param><ptype>GLenum</ptype> <name>identifier</name></param>
+ <param><ptype>GLuint</ptype> <name>name</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param len="1"><ptype>GLsizei</ptype> *<name>length</name></param>
+ <param len="bufSize"><ptype>GLchar</ptype> *<name>label</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetObjectLabelEXT</name></proto>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLuint</ptype> <name>object</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param len="1"><ptype>GLsizei</ptype> *<name>length</name></param>
+ <param len="bufSize"><ptype>GLchar</ptype> *<name>label</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetObjectLabelKHR</name></proto>
+ <param><ptype>GLenum</ptype> <name>identifier</name></param>
+ <param><ptype>GLuint</ptype> <name>name</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param><ptype>GLsizei</ptype> *<name>length</name></param>
+ <param len="bufSize"><ptype>GLchar</ptype> *<name>label</name></param>
+ <alias name="glGetObjectLabel"/>
+ </command>
+ <command>
+ <proto>void <name>glGetObjectParameterfvARB</name></proto>
+ <param group="handleARB"><ptype>GLhandleARB</ptype> <name>obj</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLfloat</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetObjectParameterivAPPLE</name></proto>
+ <param><ptype>GLenum</ptype> <name>objectType</name></param>
+ <param><ptype>GLuint</ptype> <name>name</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetObjectParameterivARB</name></proto>
+ <param group="handleARB"><ptype>GLhandleARB</ptype> <name>obj</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetObjectPtrLabel</name></proto>
+ <param>const void *<name>ptr</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param len="1"><ptype>GLsizei</ptype> *<name>length</name></param>
+ <param len="bufSize"><ptype>GLchar</ptype> *<name>label</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetObjectPtrLabelKHR</name></proto>
+ <param>const void *<name>ptr</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param len="1"><ptype>GLsizei</ptype> *<name>length</name></param>
+ <param len="bufSize"><ptype>GLchar</ptype> *<name>label</name></param>
+ <alias name="glGetObjectPtrLabel"/>
+ </command>
+ <command>
+ <proto>void <name>glGetOcclusionQueryivNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <param group="OcclusionQueryParameterNameNV"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetOcclusionQueryuivNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <param group="OcclusionQueryParameterNameNV"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLuint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetPathColorGenfvNV</name></proto>
+ <param group="PathColor"><ptype>GLenum</ptype> <name>color</name></param>
+ <param group="PathGenMode"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLfloat</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetPathColorGenivNV</name></proto>
+ <param group="PathColor"><ptype>GLenum</ptype> <name>color</name></param>
+ <param group="PathGenMode"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetPathCommandsNV</name></proto>
+ <param group="Path"><ptype>GLuint</ptype> <name>path</name></param>
+ <param group="PathCommand" len="COMPSIZE(path)"><ptype>GLubyte</ptype> *<name>commands</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetPathCoordsNV</name></proto>
+ <param group="Path"><ptype>GLuint</ptype> <name>path</name></param>
+ <param len="COMPSIZE(path)"><ptype>GLfloat</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetPathDashArrayNV</name></proto>
+ <param group="Path"><ptype>GLuint</ptype> <name>path</name></param>
+ <param len="COMPSIZE(path)"><ptype>GLfloat</ptype> *<name>dashArray</name></param>
+ </command>
+ <command>
+ <proto><ptype>GLfloat</ptype> <name>glGetPathLengthNV</name></proto>
+ <param group="Path"><ptype>GLuint</ptype> <name>path</name></param>
+ <param><ptype>GLsizei</ptype> <name>startSegment</name></param>
+ <param><ptype>GLsizei</ptype> <name>numSegments</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetPathMetricRangeNV</name></proto>
+ <param group="PathMetricMask"><ptype>GLbitfield</ptype> <name>metricQueryMask</name></param>
+ <param group="Path"><ptype>GLuint</ptype> <name>firstPathName</name></param>
+ <param><ptype>GLsizei</ptype> <name>numPaths</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ <param len="COMPSIZE(metricQueryMask,numPaths,stride)"><ptype>GLfloat</ptype> *<name>metrics</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetPathMetricsNV</name></proto>
+ <param group="PathMetricMask"><ptype>GLbitfield</ptype> <name>metricQueryMask</name></param>
+ <param><ptype>GLsizei</ptype> <name>numPaths</name></param>
+ <param group="PathElementType"><ptype>GLenum</ptype> <name>pathNameType</name></param>
+ <param group="PathElement" len="COMPSIZE(numPaths,pathNameType,paths)">const void *<name>paths</name></param>
+ <param group="Path"><ptype>GLuint</ptype> <name>pathBase</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ <param len="COMPSIZE(metricQueryMask,numPaths,stride)"><ptype>GLfloat</ptype> *<name>metrics</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetPathParameterfvNV</name></proto>
+ <param group="Path"><ptype>GLuint</ptype> <name>path</name></param>
+ <param group="PathParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="4"><ptype>GLfloat</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetPathParameterivNV</name></proto>
+ <param group="Path"><ptype>GLuint</ptype> <name>path</name></param>
+ <param group="PathParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="4"><ptype>GLint</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetPathSpacingNV</name></proto>
+ <param group="PathListMode"><ptype>GLenum</ptype> <name>pathListMode</name></param>
+ <param><ptype>GLsizei</ptype> <name>numPaths</name></param>
+ <param group="PathElementType"><ptype>GLenum</ptype> <name>pathNameType</name></param>
+ <param group="PathElement" len="COMPSIZE(numPaths,pathNameType,paths)">const void *<name>paths</name></param>
+ <param group="Path"><ptype>GLuint</ptype> <name>pathBase</name></param>
+ <param><ptype>GLfloat</ptype> <name>advanceScale</name></param>
+ <param><ptype>GLfloat</ptype> <name>kerningScale</name></param>
+ <param group="PathTransformType"><ptype>GLenum</ptype> <name>transformType</name></param>
+ <param len="COMPSIZE(pathListMode,numPaths)"><ptype>GLfloat</ptype> *<name>returnedSpacing</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetPathTexGenfvNV</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>texCoordSet</name></param>
+ <param group="PathGenMode"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLfloat</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetPathTexGenivNV</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>texCoordSet</name></param>
+ <param group="PathGenMode"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetPerfCounterInfoINTEL</name></proto>
+ <param><ptype>GLuint</ptype> <name>queryId</name></param>
+ <param><ptype>GLuint</ptype> <name>counterId</name></param>
+ <param><ptype>GLuint</ptype> <name>counterNameLength</name></param>
+ <param><ptype>GLchar</ptype> *<name>counterName</name></param>
+ <param><ptype>GLuint</ptype> <name>counterDescLength</name></param>
+ <param><ptype>GLchar</ptype> *<name>counterDesc</name></param>
+ <param><ptype>GLuint</ptype> *<name>counterOffset</name></param>
+ <param><ptype>GLuint</ptype> *<name>counterDataSize</name></param>
+ <param><ptype>GLuint</ptype> *<name>counterTypeEnum</name></param>
+ <param><ptype>GLuint</ptype> *<name>counterDataTypeEnum</name></param>
+ <param><ptype>GLuint64</ptype> *<name>rawCounterMaxValue</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetPerfMonitorCounterDataAMD</name></proto>
+ <param><ptype>GLuint</ptype> <name>monitor</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLsizei</ptype> <name>dataSize</name></param>
+ <param len="dataSize"><ptype>GLuint</ptype> *<name>data</name></param>
+ <param len="1"><ptype>GLint</ptype> *<name>bytesWritten</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetPerfMonitorCounterInfoAMD</name></proto>
+ <param><ptype>GLuint</ptype> <name>group</name></param>
+ <param><ptype>GLuint</ptype> <name>counter</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)">void *<name>data</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetPerfMonitorCounterStringAMD</name></proto>
+ <param><ptype>GLuint</ptype> <name>group</name></param>
+ <param><ptype>GLuint</ptype> <name>counter</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param len="1"><ptype>GLsizei</ptype> *<name>length</name></param>
+ <param len="bufSize"><ptype>GLchar</ptype> *<name>counterString</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetPerfMonitorCountersAMD</name></proto>
+ <param><ptype>GLuint</ptype> <name>group</name></param>
+ <param len="1"><ptype>GLint</ptype> *<name>numCounters</name></param>
+ <param len="1"><ptype>GLint</ptype> *<name>maxActiveCounters</name></param>
+ <param><ptype>GLsizei</ptype> <name>counterSize</name></param>
+ <param len="counterSize"><ptype>GLuint</ptype> *<name>counters</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetPerfMonitorGroupStringAMD</name></proto>
+ <param><ptype>GLuint</ptype> <name>group</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param len="1"><ptype>GLsizei</ptype> *<name>length</name></param>
+ <param len="bufSize"><ptype>GLchar</ptype> *<name>groupString</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetPerfMonitorGroupsAMD</name></proto>
+ <param len="1"><ptype>GLint</ptype> *<name>numGroups</name></param>
+ <param><ptype>GLsizei</ptype> <name>groupsSize</name></param>
+ <param len="groupsSize"><ptype>GLuint</ptype> *<name>groups</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetPerfQueryDataINTEL</name></proto>
+ <param><ptype>GLuint</ptype> <name>queryHandle</name></param>
+ <param><ptype>GLuint</ptype> <name>flags</name></param>
+ <param><ptype>GLsizei</ptype> <name>dataSize</name></param>
+ <param><ptype>GLvoid</ptype> *<name>data</name></param>
+ <param><ptype>GLuint</ptype> *<name>bytesWritten</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetPerfQueryIdByNameINTEL</name></proto>
+ <param><ptype>GLchar</ptype> *<name>queryName</name></param>
+ <param><ptype>GLuint</ptype> *<name>queryId</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetPerfQueryInfoINTEL</name></proto>
+ <param><ptype>GLuint</ptype> <name>queryId</name></param>
+ <param><ptype>GLuint</ptype> <name>queryNameLength</name></param>
+ <param><ptype>GLchar</ptype> *<name>queryName</name></param>
+ <param><ptype>GLuint</ptype> *<name>dataSize</name></param>
+ <param><ptype>GLuint</ptype> *<name>noCounters</name></param>
+ <param><ptype>GLuint</ptype> *<name>noInstances</name></param>
+ <param><ptype>GLuint</ptype> *<name>capsMask</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetPixelMapfv</name></proto>
+ <param group="PixelMap"><ptype>GLenum</ptype> <name>map</name></param>
+ <param len="COMPSIZE(map)"><ptype>GLfloat</ptype> *<name>values</name></param>
+ <glx type="single" opcode="125"/>
+ <glx type="render" opcode="339" name="glGetPixelMapfvPBO" comment="PBO protocol"/>
+ </command>
+ <command>
+ <proto>void <name>glGetPixelMapuiv</name></proto>
+ <param group="PixelMap"><ptype>GLenum</ptype> <name>map</name></param>
+ <param len="COMPSIZE(map)"><ptype>GLuint</ptype> *<name>values</name></param>
+ <glx type="single" opcode="126"/>
+ <glx type="render" opcode="340" name="glGetPixelMapuivPBO" comment="PBO protocol"/>
+ </command>
+ <command>
+ <proto>void <name>glGetPixelMapusv</name></proto>
+ <param group="PixelMap"><ptype>GLenum</ptype> <name>map</name></param>
+ <param len="COMPSIZE(map)"><ptype>GLushort</ptype> *<name>values</name></param>
+ <glx type="single" opcode="127"/>
+ <glx type="render" opcode="341" name="glGetPixelMapusvPBO" comment="PBO protocol"/>
+ </command>
+ <command>
+ <proto>void <name>glGetPixelMapxv</name></proto>
+ <param><ptype>GLenum</ptype> <name>map</name></param>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param len="size"><ptype>GLfixed</ptype> *<name>values</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetPixelTexGenParameterfvSGIS</name></proto>
+ <param group="PixelTexGenParameterNameSGIS"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedFloat32" len="COMPSIZE(pname)"><ptype>GLfloat</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetPixelTexGenParameterivSGIS</name></proto>
+ <param group="PixelTexGenParameterNameSGIS"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedInt32" len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetPixelTransformParameterfvEXT</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLfloat</ptype> *<name>params</name></param>
+ <glx type="vendor" opcode="2051"/>
+ </command>
+ <command>
+ <proto>void <name>glGetPixelTransformParameterivEXT</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ <glx type="vendor" opcode="2052"/>
+ </command>
+ <command>
+ <proto>void <name>glGetPointerIndexedvEXT</name></proto>
+ <param group="TypeEnum"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="1">void **<name>data</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetPointeri_vEXT</name></proto>
+ <param group="TypeEnum"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="1">void **<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetPointerv</name></proto>
+ <param group="GetPointervPName"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="1">void **<name>params</name></param>
+ <glx type="single" opcode="208"/>
+ </command>
+ <command>
+ <proto>void <name>glGetPointervEXT</name></proto>
+ <param group="GetPointervPName"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="1">void **<name>params</name></param>
+ <alias name="glGetPointerv"/>
+ </command>
+ <command>
+ <proto>void <name>glGetPointervKHR</name></proto>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param>void **<name>params</name></param>
+ <alias name="glGetPointerv"/>
+ </command>
+ <command>
+ <proto>void <name>glGetPolygonStipple</name></proto>
+ <param len="COMPSIZE()"><ptype>GLubyte</ptype> *<name>mask</name></param>
+ <glx type="single" opcode="128"/>
+ <glx type="render" opcode="342" name="glGetPolygonStipplePBO" comment="PBO protocol"/>
+ </command>
+ <command>
+ <proto>void <name>glGetProgramBinary</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param len="1"><ptype>GLsizei</ptype> *<name>length</name></param>
+ <param len="1"><ptype>GLenum</ptype> *<name>binaryFormat</name></param>
+ <param len="bufSize">void *<name>binary</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetProgramBinaryOES</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param len="1"><ptype>GLsizei</ptype> *<name>length</name></param>
+ <param len="1"><ptype>GLenum</ptype> *<name>binaryFormat</name></param>
+ <param len="bufSize">void *<name>binary</name></param>
+ <alias name="glGetProgramBinary"/>
+ </command>
+ <command>
+ <proto>void <name>glGetProgramEnvParameterIivNV</name></proto>
+ <param group="ProgramTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4"><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetProgramEnvParameterIuivNV</name></proto>
+ <param group="ProgramTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4"><ptype>GLuint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetProgramEnvParameterdvARB</name></proto>
+ <param group="ProgramTargetARB"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4"><ptype>GLdouble</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetProgramEnvParameterfvARB</name></proto>
+ <param group="ProgramTargetARB"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4"><ptype>GLfloat</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetProgramInfoLog</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param len="1"><ptype>GLsizei</ptype> *<name>length</name></param>
+ <param len="bufSize"><ptype>GLchar</ptype> *<name>infoLog</name></param>
+ <glx type="single" opcode="201"/>
+ </command>
+ <command>
+ <proto>void <name>glGetProgramInterfaceiv</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLenum</ptype> <name>programInterface</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetProgramLocalParameterIivNV</name></proto>
+ <param group="ProgramTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4"><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetProgramLocalParameterIuivNV</name></proto>
+ <param group="ProgramTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4"><ptype>GLuint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetProgramLocalParameterdvARB</name></proto>
+ <param group="ProgramTargetARB"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4"><ptype>GLdouble</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetProgramLocalParameterfvARB</name></proto>
+ <param group="ProgramTargetARB"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4"><ptype>GLfloat</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetProgramNamedParameterdvNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <param><ptype>GLsizei</ptype> <name>len</name></param>
+ <param len="1">const <ptype>GLubyte</ptype> *<name>name</name></param>
+ <param len="4"><ptype>GLdouble</ptype> *<name>params</name></param>
+ <glx type="vendor" opcode="1311"/>
+ </command>
+ <command>
+ <proto>void <name>glGetProgramNamedParameterfvNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <param><ptype>GLsizei</ptype> <name>len</name></param>
+ <param len="1">const <ptype>GLubyte</ptype> *<name>name</name></param>
+ <param len="4"><ptype>GLfloat</ptype> *<name>params</name></param>
+ <glx type="vendor" opcode="1310"/>
+ </command>
+ <command>
+ <proto>void <name>glGetProgramParameterdvNV</name></proto>
+ <param group="VertexAttribEnumNV"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param group="VertexAttribEnumNV"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="4"><ptype>GLdouble</ptype> *<name>params</name></param>
+ <glx type="vendor" opcode="1297"/>
+ </command>
+ <command>
+ <proto>void <name>glGetProgramParameterfvNV</name></proto>
+ <param group="VertexAttribEnumNV"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param group="VertexAttribEnumNV"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="4"><ptype>GLfloat</ptype> *<name>params</name></param>
+ <glx type="vendor" opcode="1296"/>
+ </command>
+ <command>
+ <proto>void <name>glGetProgramPipelineInfoLog</name></proto>
+ <param><ptype>GLuint</ptype> <name>pipeline</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param len="1"><ptype>GLsizei</ptype> *<name>length</name></param>
+ <param len="bufSize"><ptype>GLchar</ptype> *<name>infoLog</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetProgramPipelineInfoLogEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>pipeline</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param len="1"><ptype>GLsizei</ptype> *<name>length</name></param>
+ <param len="bufSize"><ptype>GLchar</ptype> *<name>infoLog</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetProgramPipelineiv</name></proto>
+ <param><ptype>GLuint</ptype> <name>pipeline</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetProgramPipelineivEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>pipeline</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto><ptype>GLuint</ptype> <name>glGetProgramResourceIndex</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLenum</ptype> <name>programInterface</name></param>
+ <param len="COMPSIZE(name)">const <ptype>GLchar</ptype> *<name>name</name></param>
+ </command>
+ <command>
+ <proto><ptype>GLint</ptype> <name>glGetProgramResourceLocation</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLenum</ptype> <name>programInterface</name></param>
+ <param len="COMPSIZE(name)">const <ptype>GLchar</ptype> *<name>name</name></param>
+ </command>
+ <command>
+ <proto><ptype>GLint</ptype> <name>glGetProgramResourceLocationIndex</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLenum</ptype> <name>programInterface</name></param>
+ <param len="COMPSIZE(name)">const <ptype>GLchar</ptype> *<name>name</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetProgramResourceName</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLenum</ptype> <name>programInterface</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param len="1"><ptype>GLsizei</ptype> *<name>length</name></param>
+ <param len="bufSize"><ptype>GLchar</ptype> *<name>name</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetProgramResourcefvNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLenum</ptype> <name>programInterface</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLsizei</ptype> <name>propCount</name></param>
+ <param>const <ptype>GLenum</ptype> *<name>props</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param><ptype>GLsizei</ptype> *<name>length</name></param>
+ <param><ptype>GLfloat</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetProgramResourceiv</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLenum</ptype> <name>programInterface</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLsizei</ptype> <name>propCount</name></param>
+ <param len="propCount">const <ptype>GLenum</ptype> *<name>props</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param len="1"><ptype>GLsizei</ptype> *<name>length</name></param>
+ <param len="bufSize"><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetProgramStageiv</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLenum</ptype> <name>shadertype</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="1"><ptype>GLint</ptype> *<name>values</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetProgramStringARB</name></proto>
+ <param group="ProgramTargetARB"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="ProgramStringPropertyARB"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(target,pname)">void *<name>string</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetProgramStringNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <param group="VertexAttribEnumNV"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="ProgramCharacterNV" len="COMPSIZE(id,pname)"><ptype>GLubyte</ptype> *<name>program</name></param>
+ <glx type="vendor" opcode="1299"/>
+ </command>
+ <command>
+ <proto>void <name>glGetProgramSubroutineParameteruivNV</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="COMPSIZE(target)"><ptype>GLuint</ptype> *<name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetProgramiv</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ <glx type="single" opcode="199"/>
+ </command>
+ <command>
+ <proto>void <name>glGetProgramivARB</name></proto>
+ <param group="ProgramTargetARB"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="ProgramPropertyARB"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="1"><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetProgramivNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <param group="VertexAttribEnumNV"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="4"><ptype>GLint</ptype> *<name>params</name></param>
+ <glx type="vendor" opcode="1298"/>
+ </command>
+ <command>
+ <proto>void <name>glGetQueryIndexediv</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetQueryObjecti64v</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint64</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetQueryObjecti64vEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint64</ptype> *<name>params</name></param>
+ <glx type="vendor" opcode="1328"/>
+ <alias name="glGetQueryObjecti64v"/>
+ </command>
+ <command>
+ <proto>void <name>glGetQueryObjectiv</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ <glx type="single" opcode="165"/>
+ </command>
+ <command>
+ <proto>void <name>glGetQueryObjectivARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ <alias name="glGetQueryObjectiv"/>
+ </command>
+ <command>
+ <proto>void <name>glGetQueryObjectivEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLint</ptype> *<name>params</name></param>
+ <alias name="glGetQueryObjectiv"/>
+ </command>
+ <command>
+ <proto>void <name>glGetQueryObjectui64v</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLuint64</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetQueryObjectui64vEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLuint64</ptype> *<name>params</name></param>
+ <glx type="vendor" opcode="1329"/>
+ <alias name="glGetQueryObjectui64v"/>
+ </command>
+ <command>
+ <proto>void <name>glGetQueryObjectuiv</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLuint</ptype> *<name>params</name></param>
+ <glx type="single" opcode="166"/>
+ </command>
+ <command>
+ <proto>void <name>glGetQueryObjectuivARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLuint</ptype> *<name>params</name></param>
+ <alias name="glGetQueryObjectuiv"/>
+ </command>
+ <command>
+ <proto>void <name>glGetQueryObjectuivEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLuint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetQueryiv</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ <glx type="single" opcode="164"/>
+ </command>
+ <command>
+ <proto>void <name>glGetQueryivARB</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ <alias name="glGetQueryiv"/>
+ </command>
+ <command>
+ <proto>void <name>glGetQueryivEXT</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetRenderbufferParameteriv</name></proto>
+ <param group="RenderbufferTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ <glx type="vendor" opcode="1424"/>
+ </command>
+ <command>
+ <proto>void <name>glGetRenderbufferParameterivEXT</name></proto>
+ <param group="RenderbufferTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ <alias name="glGetRenderbufferParameteriv"/>
+ <glx type="vendor" opcode="1424"/>
+ </command>
+ <command>
+ <proto>void <name>glGetRenderbufferParameterivOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetSamplerParameterIiv</name></proto>
+ <param><ptype>GLuint</ptype> <name>sampler</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetSamplerParameterIivEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>sampler</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ <alias name="glGetSamplerParameterIiv"/>
+ </command>
+ <command>
+ <proto>void <name>glGetSamplerParameterIuiv</name></proto>
+ <param><ptype>GLuint</ptype> <name>sampler</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLuint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetSamplerParameterIuivEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>sampler</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLuint</ptype> *<name>params</name></param>
+ <alias name="glGetSamplerParameterIuiv"/>
+ </command>
+ <command>
+ <proto>void <name>glGetSamplerParameterfv</name></proto>
+ <param><ptype>GLuint</ptype> <name>sampler</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLfloat</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetSamplerParameteriv</name></proto>
+ <param><ptype>GLuint</ptype> <name>sampler</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetSeparableFilter</name></proto>
+ <param group="SeparableTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param group="PixelType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(target,format,type)">void *<name>row</name></param>
+ <param len="COMPSIZE(target,format,type)">void *<name>column</name></param>
+ <param len="COMPSIZE(target,format,type)">void *<name>span</name></param>
+ <glx type="single" opcode="153"/>
+ <glx type="render" opcode="343" name="glGetSeparableFilterPBO" comment="PBO protocol"/>
+ </command>
+ <command>
+ <proto>void <name>glGetSeparableFilterEXT</name></proto>
+ <param group="SeparableTargetEXT"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param group="PixelType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(target,format,type)">void *<name>row</name></param>
+ <param len="COMPSIZE(target,format,type)">void *<name>column</name></param>
+ <param len="COMPSIZE(target,format,type)">void *<name>span</name></param>
+ <glx type="vendor" opcode="4"/>
+ </command>
+ <command>
+ <proto>void <name>glGetShaderInfoLog</name></proto>
+ <param><ptype>GLuint</ptype> <name>shader</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param len="1"><ptype>GLsizei</ptype> *<name>length</name></param>
+ <param len="bufSize"><ptype>GLchar</ptype> *<name>infoLog</name></param>
+ <glx type="single" opcode="200"/>
+ </command>
+ <command>
+ <proto>void <name>glGetShaderPrecisionFormat</name></proto>
+ <param><ptype>GLenum</ptype> <name>shadertype</name></param>
+ <param><ptype>GLenum</ptype> <name>precisiontype</name></param>
+ <param len="2"><ptype>GLint</ptype> *<name>range</name></param>
+ <param len="2"><ptype>GLint</ptype> *<name>precision</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetShaderSource</name></proto>
+ <param><ptype>GLuint</ptype> <name>shader</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param len="1"><ptype>GLsizei</ptype> *<name>length</name></param>
+ <param len="bufSize"><ptype>GLchar</ptype> *<name>source</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetShaderSourceARB</name></proto>
+ <param group="handleARB"><ptype>GLhandleARB</ptype> <name>obj</name></param>
+ <param><ptype>GLsizei</ptype> <name>maxLength</name></param>
+ <param len="1"><ptype>GLsizei</ptype> *<name>length</name></param>
+ <param len="maxLength"><ptype>GLcharARB</ptype> *<name>source</name></param>
+ <alias name="glGetShaderSource"/>
+ </command>
+ <command>
+ <proto>void <name>glGetShaderiv</name></proto>
+ <param><ptype>GLuint</ptype> <name>shader</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ <glx type="single" opcode="198"/>
+ </command>
+ <command>
+ <proto>void <name>glGetSharpenTexFuncSGIS</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param len="COMPSIZE(target)"><ptype>GLfloat</ptype> *<name>points</name></param>
+ <glx type="vendor" opcode="4097"/>
+ </command>
+ <command>
+ <proto group="String">const <ptype>GLubyte</ptype> *<name>glGetString</name></proto>
+ <param group="StringName"><ptype>GLenum</ptype> <name>name</name></param>
+ <glx type="single" opcode="129"/>
+ </command>
+ <command>
+ <proto group="String">const <ptype>GLubyte</ptype> *<name>glGetStringi</name></proto>
+ <param><ptype>GLenum</ptype> <name>name</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ </command>
+ <command>
+ <proto><ptype>GLuint</ptype> <name>glGetSubroutineIndex</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLenum</ptype> <name>shadertype</name></param>
+ <param>const <ptype>GLchar</ptype> *<name>name</name></param>
+ </command>
+ <command>
+ <proto><ptype>GLint</ptype> <name>glGetSubroutineUniformLocation</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLenum</ptype> <name>shadertype</name></param>
+ <param>const <ptype>GLchar</ptype> *<name>name</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetSynciv</name></proto>
+ <param group="sync"><ptype>GLsync</ptype> <name>sync</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param len="1"><ptype>GLsizei</ptype> *<name>length</name></param>
+ <param len="bufSize"><ptype>GLint</ptype> *<name>values</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetSyncivAPPLE</name></proto>
+ <param><ptype>GLsync</ptype> <name>sync</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param><ptype>GLsizei</ptype> *<name>length</name></param>
+ <param len="bufSize"><ptype>GLint</ptype> *<name>values</name></param>
+ <alias name="glGetSynciv"/>
+ </command>
+ <command>
+ <proto>void <name>glGetTexBumpParameterfvATI</name></proto>
+ <param group="GetTexBumpParameterATI"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLfloat</ptype> *<name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetTexBumpParameterivATI</name></proto>
+ <param group="GetTexBumpParameterATI"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetTexEnvfv</name></proto>
+ <param group="TextureEnvTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="TextureEnvParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLfloat</ptype> *<name>params</name></param>
+ <glx type="single" opcode="130"/>
+ </command>
+ <command>
+ <proto>void <name>glGetTexEnviv</name></proto>
+ <param group="TextureEnvTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="TextureEnvParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ <glx type="single" opcode="131"/>
+ </command>
+ <command>
+ <proto>void <name>glGetTexEnvxv</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLfixed</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetTexEnvxvOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLfixed</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetTexFilterFuncSGIS</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="TextureFilterSGIS"><ptype>GLenum</ptype> <name>filter</name></param>
+ <param len="COMPSIZE(target,filter)"><ptype>GLfloat</ptype> *<name>weights</name></param>
+ <glx type="vendor" opcode="4101"/>
+ </command>
+ <command>
+ <proto>void <name>glGetTexGendv</name></proto>
+ <param group="TextureCoordName"><ptype>GLenum</ptype> <name>coord</name></param>
+ <param group="TextureGenParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLdouble</ptype> *<name>params</name></param>
+ <glx type="single" opcode="132"/>
+ </command>
+ <command>
+ <proto>void <name>glGetTexGenfv</name></proto>
+ <param group="TextureCoordName"><ptype>GLenum</ptype> <name>coord</name></param>
+ <param group="TextureGenParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLfloat</ptype> *<name>params</name></param>
+ <glx type="single" opcode="133"/>
+ </command>
+ <command>
+ <proto>void <name>glGetTexGenfvOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>coord</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLfloat</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetTexGeniv</name></proto>
+ <param group="TextureCoordName"><ptype>GLenum</ptype> <name>coord</name></param>
+ <param group="TextureGenParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ <glx type="single" opcode="134"/>
+ </command>
+ <command>
+ <proto>void <name>glGetTexGenivOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>coord</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetTexGenxvOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>coord</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLfixed</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetTexImage</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param group="PixelType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(target,level,format,type)">void *<name>pixels</name></param>
+ <glx type="single" opcode="135"/>
+ <glx type="render" opcode="344" name="glGetTexImagePBO" comment="PBO protocol"/>
+ </command>
+ <command>
+ <proto>void <name>glGetTexLevelParameterfv</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="GetTextureParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLfloat</ptype> *<name>params</name></param>
+ <glx type="single" opcode="138"/>
+ </command>
+ <command>
+ <proto>void <name>glGetTexLevelParameteriv</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="GetTextureParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ <glx type="single" opcode="139"/>
+ </command>
+ <command>
+ <proto>void <name>glGetTexLevelParameterxvOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLint</ptype> <name>level</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLfixed</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetTexParameterIiv</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="GetTextureParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ <glx type="single" opcode="203"/>
+ </command>
+ <command>
+ <proto>void <name>glGetTexParameterIivEXT</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="GetTextureParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ <alias name="glGetTexParameterIiv"/>
+ </command>
+ <command>
+ <proto>void <name>glGetTexParameterIuiv</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="GetTextureParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLuint</ptype> *<name>params</name></param>
+ <glx type="single" opcode="204"/>
+ </command>
+ <command>
+ <proto>void <name>glGetTexParameterIuivEXT</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="GetTextureParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLuint</ptype> *<name>params</name></param>
+ <alias name="glGetTexParameterIuiv"/>
+ </command>
+ <command>
+ <proto>void <name>glGetTexParameterPointervAPPLE</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="1">void **<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetTexParameterfv</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="GetTextureParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLfloat</ptype> *<name>params</name></param>
+ <glx type="single" opcode="136"/>
+ </command>
+ <command>
+ <proto>void <name>glGetTexParameteriv</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="GetTextureParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ <glx type="single" opcode="137"/>
+ </command>
+ <command>
+ <proto>void <name>glGetTexParameterxv</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLfixed</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetTexParameterxvOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLfixed</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto><ptype>GLuint64</ptype> <name>glGetTextureHandleARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ </command>
+ <command>
+ <proto><ptype>GLuint64</ptype> <name>glGetTextureHandleNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetTextureImage</name></proto>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLint</ptype> <name>level</name></param>
+ <param><ptype>GLenum</ptype> <name>format</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param>void *<name>pixels</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetTextureImageEXT</name></proto>
+ <param group="Texture"><ptype>GLuint</ptype> <name>texture</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param group="PixelType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(target,level,format,type)">void *<name>pixels</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetTextureLevelParameterfv</name></proto>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLint</ptype> <name>level</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLfloat</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetTextureLevelParameterfvEXT</name></proto>
+ <param group="Texture"><ptype>GLuint</ptype> <name>texture</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="GetTextureParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLfloat</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetTextureLevelParameteriv</name></proto>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLint</ptype> <name>level</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetTextureLevelParameterivEXT</name></proto>
+ <param group="Texture"><ptype>GLuint</ptype> <name>texture</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="GetTextureParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetTextureParameterIiv</name></proto>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetTextureParameterIivEXT</name></proto>
+ <param group="Texture"><ptype>GLuint</ptype> <name>texture</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="GetTextureParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetTextureParameterIuiv</name></proto>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLuint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetTextureParameterIuivEXT</name></proto>
+ <param group="Texture"><ptype>GLuint</ptype> <name>texture</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="GetTextureParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLuint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetTextureParameterfv</name></proto>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLfloat</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetTextureParameterfvEXT</name></proto>
+ <param group="Texture"><ptype>GLuint</ptype> <name>texture</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="GetTextureParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLfloat</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetTextureParameteriv</name></proto>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetTextureParameterivEXT</name></proto>
+ <param group="Texture"><ptype>GLuint</ptype> <name>texture</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="GetTextureParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto><ptype>GLuint64</ptype> <name>glGetTextureSamplerHandleARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLuint</ptype> <name>sampler</name></param>
+ </command>
+ <command>
+ <proto><ptype>GLuint64</ptype> <name>glGetTextureSamplerHandleNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLuint</ptype> <name>sampler</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetTextureSubImage</name></proto>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLint</ptype> <name>level</name></param>
+ <param><ptype>GLint</ptype> <name>xoffset</name></param>
+ <param><ptype>GLint</ptype> <name>yoffset</name></param>
+ <param><ptype>GLint</ptype> <name>zoffset</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param><ptype>GLsizei</ptype> <name>depth</name></param>
+ <param><ptype>GLenum</ptype> <name>format</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param>void *<name>pixels</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetTrackMatrixivNV</name></proto>
+ <param group="VertexAttribEnumNV"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>address</name></param>
+ <param group="VertexAttribEnumNV"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="1"><ptype>GLint</ptype> *<name>params</name></param>
+ <glx type="vendor" opcode="1300"/>
+ </command>
+ <command>
+ <proto>void <name>glGetTransformFeedbackVarying</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param len="1"><ptype>GLsizei</ptype> *<name>length</name></param>
+ <param len="1"><ptype>GLsizei</ptype> *<name>size</name></param>
+ <param len="1"><ptype>GLenum</ptype> *<name>type</name></param>
+ <param len="bufSize"><ptype>GLchar</ptype> *<name>name</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetTransformFeedbackVaryingEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param len="1"><ptype>GLsizei</ptype> *<name>length</name></param>
+ <param len="1"><ptype>GLsizei</ptype> *<name>size</name></param>
+ <param len="1"><ptype>GLenum</ptype> *<name>type</name></param>
+ <param len="bufSize"><ptype>GLchar</ptype> *<name>name</name></param>
+ <alias name="glGetTransformFeedbackVarying"/>
+ </command>
+ <command>
+ <proto>void <name>glGetTransformFeedbackVaryingNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="1"><ptype>GLint</ptype> *<name>location</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetTransformFeedbacki64_v</name></proto>
+ <param><ptype>GLuint</ptype> <name>xfb</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLint64</ptype> *<name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetTransformFeedbacki_v</name></proto>
+ <param><ptype>GLuint</ptype> <name>xfb</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLint</ptype> *<name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetTransformFeedbackiv</name></proto>
+ <param><ptype>GLuint</ptype> <name>xfb</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLint</ptype> *<name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetTranslatedShaderSourceANGLE</name></proto>
+ <param><ptype>GLuint</ptype> <name>shader</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufsize</name></param>
+ <param len="1"><ptype>GLsizei</ptype> *<name>length</name></param>
+ <param><ptype>GLchar</ptype> *<name>source</name></param>
+ </command>
+ <command>
+ <proto><ptype>GLuint</ptype> <name>glGetUniformBlockIndex</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param len="COMPSIZE()">const <ptype>GLchar</ptype> *<name>uniformBlockName</name></param>
+ </command>
+ <command>
+ <proto><ptype>GLint</ptype> <name>glGetUniformBufferSizeEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetUniformIndices</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLsizei</ptype> <name>uniformCount</name></param>
+ <param len="COMPSIZE(uniformCount)">const <ptype>GLchar</ptype> *const*<name>uniformNames</name></param>
+ <param len="COMPSIZE(uniformCount)"><ptype>GLuint</ptype> *<name>uniformIndices</name></param>
+ </command>
+ <command>
+ <proto><ptype>GLint</ptype> <name>glGetUniformLocation</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param>const <ptype>GLchar</ptype> *<name>name</name></param>
+ </command>
+ <command>
+ <proto><ptype>GLint</ptype> <name>glGetUniformLocationARB</name></proto>
+ <param group="handleARB"><ptype>GLhandleARB</ptype> <name>programObj</name></param>
+ <param>const <ptype>GLcharARB</ptype> *<name>name</name></param>
+ <alias name="glGetUniformLocation"/>
+ </command>
+ <command>
+ <proto group="BufferOffset"><ptype>GLintptr</ptype> <name>glGetUniformOffsetEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetUniformSubroutineuiv</name></proto>
+ <param><ptype>GLenum</ptype> <name>shadertype</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param len="1"><ptype>GLuint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetUniformdv</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param len="COMPSIZE(program, location)"><ptype>GLdouble</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetUniformfv</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param len="COMPSIZE(program, location)"><ptype>GLfloat</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetUniformfvARB</name></proto>
+ <param group="handleARB"><ptype>GLhandleARB</ptype> <name>programObj</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param len="COMPSIZE(program, location)"><ptype>GLfloat</ptype> *<name>params</name></param>
+ <alias name="glGetUniformfv"/>
+ </command>
+ <command>
+ <proto>void <name>glGetUniformi64vNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param len="COMPSIZE(program, location)"><ptype>GLint64EXT</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetUniformiv</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param len="COMPSIZE(program, location)"><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetUniformivARB</name></proto>
+ <param group="handleARB"><ptype>GLhandleARB</ptype> <name>programObj</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param len="COMPSIZE(program, location)"><ptype>GLint</ptype> *<name>params</name></param>
+ <alias name="glGetUniformiv"/>
+ </command>
+ <command>
+ <proto>void <name>glGetUniformui64vNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param len="COMPSIZE(program,location)"><ptype>GLuint64EXT</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetUniformuiv</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param len="COMPSIZE(program,location)"><ptype>GLuint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetUniformuivEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param len="COMPSIZE(program,location)"><ptype>GLuint</ptype> *<name>params</name></param>
+ <alias name="glGetUniformuiv"/>
+ </command>
+ <command>
+ <proto>void <name>glGetVariantArrayObjectfvATI</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <param group="ArrayObjectPNameATI"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="1"><ptype>GLfloat</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetVariantArrayObjectivATI</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <param group="ArrayObjectPNameATI"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="1"><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetVariantBooleanvEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <param group="GetVariantValueEXT"><ptype>GLenum</ptype> <name>value</name></param>
+ <param group="Boolean" len="COMPSIZE(id)"><ptype>GLboolean</ptype> *<name>data</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetVariantFloatvEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <param group="GetVariantValueEXT"><ptype>GLenum</ptype> <name>value</name></param>
+ <param len="COMPSIZE(id)"><ptype>GLfloat</ptype> *<name>data</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetVariantIntegervEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <param group="GetVariantValueEXT"><ptype>GLenum</ptype> <name>value</name></param>
+ <param len="COMPSIZE(id)"><ptype>GLint</ptype> *<name>data</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetVariantPointervEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <param group="GetVariantValueEXT"><ptype>GLenum</ptype> <name>value</name></param>
+ <param len="COMPSIZE(id)">void **<name>data</name></param>
+ </command>
+ <command>
+ <proto><ptype>GLint</ptype> <name>glGetVaryingLocationNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param len="COMPSIZE(name)">const <ptype>GLchar</ptype> *<name>name</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetVertexArrayIndexed64iv</name></proto>
+ <param><ptype>GLuint</ptype> <name>vaobj</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLint64</ptype> *<name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetVertexArrayIndexediv</name></proto>
+ <param><ptype>GLuint</ptype> <name>vaobj</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLint</ptype> *<name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetVertexArrayIntegeri_vEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>vaobj</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLint</ptype> *<name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetVertexArrayIntegervEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>vaobj</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLint</ptype> *<name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetVertexArrayPointeri_vEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>vaobj</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param>void **<name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetVertexArrayPointervEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>vaobj</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="1">void **<name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetVertexArrayiv</name></proto>
+ <param><ptype>GLuint</ptype> <name>vaobj</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLint</ptype> *<name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetVertexAttribArrayObjectfvATI</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param group="ArrayObjectPNameATI"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLfloat</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetVertexAttribArrayObjectivATI</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param group="ArrayObjectPNameATI"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetVertexAttribIiv</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param group="VertexAttribEnum"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="1"><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetVertexAttribIivEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param group="VertexAttribEnum"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="1"><ptype>GLint</ptype> *<name>params</name></param>
+ <alias name="glGetVertexAttribIiv"/>
+ </command>
+ <command>
+ <proto>void <name>glGetVertexAttribIuiv</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param group="VertexAttribEnum"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="1"><ptype>GLuint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetVertexAttribIuivEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param group="VertexAttribEnum"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="1"><ptype>GLuint</ptype> *<name>params</name></param>
+ <alias name="glGetVertexAttribIuiv"/>
+ </command>
+ <command>
+ <proto>void <name>glGetVertexAttribLdv</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLdouble</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetVertexAttribLdvEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLdouble</ptype> *<name>params</name></param>
+ <alias name="glGetVertexAttribLdv"/>
+ </command>
+ <command>
+ <proto>void <name>glGetVertexAttribLi64vNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint64EXT</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetVertexAttribLui64vARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLuint64EXT</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetVertexAttribLui64vNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLuint64EXT</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetVertexAttribPointerv</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param group="VertexAttribPointerPropertyARB"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="1">void **<name>pointer</name></param>
+ <glx type="single" opcode="209"/>
+ </command>
+ <command>
+ <proto>void <name>glGetVertexAttribPointervARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param group="VertexAttribPointerPropertyARB"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="1">void **<name>pointer</name></param>
+ <alias name="glGetVertexAttribPointerv"/>
+ </command>
+ <command>
+ <proto>void <name>glGetVertexAttribPointervNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param group="VertexAttribEnumNV"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="1">void **<name>pointer</name></param>
+ <alias name="glGetVertexAttribPointerv"/>
+ </command>
+ <command>
+ <proto>void <name>glGetVertexAttribdv</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param group="VertexAttribPropertyARB"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="4"><ptype>GLdouble</ptype> *<name>params</name></param>
+ <glx type="vendor" opcode="1301"/>
+ </command>
+ <command>
+ <proto>void <name>glGetVertexAttribdvARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param group="VertexAttribPropertyARB"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="4"><ptype>GLdouble</ptype> *<name>params</name></param>
+ <alias name="glGetVertexAttribdv"/>
+ <glx type="vendor" opcode="1301"/>
+ </command>
+ <command>
+ <proto>void <name>glGetVertexAttribdvNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param group="VertexAttribEnumNV"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="1"><ptype>GLdouble</ptype> *<name>params</name></param>
+ <alias name="glGetVertexAttribdv"/>
+ <glx type="vendor" opcode="1301"/>
+ </command>
+ <command>
+ <proto>void <name>glGetVertexAttribfv</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param group="VertexAttribPropertyARB"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="4"><ptype>GLfloat</ptype> *<name>params</name></param>
+ <glx type="vendor" opcode="1302"/>
+ </command>
+ <command>
+ <proto>void <name>glGetVertexAttribfvARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param group="VertexAttribPropertyARB"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="4"><ptype>GLfloat</ptype> *<name>params</name></param>
+ <alias name="glGetVertexAttribfv"/>
+ <glx type="vendor" opcode="1302"/>
+ </command>
+ <command>
+ <proto>void <name>glGetVertexAttribfvNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param group="VertexAttribEnumNV"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="1"><ptype>GLfloat</ptype> *<name>params</name></param>
+ <alias name="glGetVertexAttribfv"/>
+ <glx type="vendor" opcode="1302"/>
+ </command>
+ <command>
+ <proto>void <name>glGetVertexAttribiv</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param group="VertexAttribPropertyARB"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="4"><ptype>GLint</ptype> *<name>params</name></param>
+ <glx type="vendor" opcode="1303"/>
+ </command>
+ <command>
+ <proto>void <name>glGetVertexAttribivARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param group="VertexAttribPropertyARB"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="4"><ptype>GLint</ptype> *<name>params</name></param>
+ <alias name="glGetVertexAttribiv"/>
+ <glx type="vendor" opcode="1303"/>
+ </command>
+ <command>
+ <proto>void <name>glGetVertexAttribivNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param group="VertexAttribEnumNV"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="1"><ptype>GLint</ptype> *<name>params</name></param>
+ <alias name="glGetVertexAttribiv"/>
+ <glx type="vendor" opcode="1303"/>
+ </command>
+ <command>
+ <proto>void <name>glGetVideoCaptureStreamdvNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>video_capture_slot</name></param>
+ <param><ptype>GLuint</ptype> <name>stream</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLdouble</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetVideoCaptureStreamfvNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>video_capture_slot</name></param>
+ <param><ptype>GLuint</ptype> <name>stream</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLfloat</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetVideoCaptureStreamivNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>video_capture_slot</name></param>
+ <param><ptype>GLuint</ptype> <name>stream</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetVideoCaptureivNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>video_capture_slot</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetVideoi64vNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>video_slot</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint64EXT</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetVideoivNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>video_slot</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetVideoui64vNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>video_slot</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLuint64EXT</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetVideouivNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>video_slot</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)"><ptype>GLuint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetnColorTable</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>format</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param>void *<name>table</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetnColorTableARB</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>format</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param len="bufSize">void *<name>table</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetnCompressedTexImage</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLint</ptype> <name>lod</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param>void *<name>pixels</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetnCompressedTexImageARB</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLint</ptype> <name>lod</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param len="bufSize">void *<name>img</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetnConvolutionFilter</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>format</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param>void *<name>image</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetnConvolutionFilterARB</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>format</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param len="bufSize">void *<name>image</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetnHistogram</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLboolean</ptype> <name>reset</name></param>
+ <param><ptype>GLenum</ptype> <name>format</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param>void *<name>values</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetnHistogramARB</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>reset</name></param>
+ <param><ptype>GLenum</ptype> <name>format</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param len="bufSize">void *<name>values</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetnMapdv</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>query</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param><ptype>GLdouble</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetnMapdvARB</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>query</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param len="bufSize"><ptype>GLdouble</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetnMapfv</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>query</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param><ptype>GLfloat</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetnMapfvARB</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>query</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param len="bufSize"><ptype>GLfloat</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetnMapiv</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>query</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param><ptype>GLint</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetnMapivARB</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>query</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param len="bufSize"><ptype>GLint</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetnMinmax</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLboolean</ptype> <name>reset</name></param>
+ <param><ptype>GLenum</ptype> <name>format</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param>void *<name>values</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetnMinmaxARB</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>reset</name></param>
+ <param><ptype>GLenum</ptype> <name>format</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param len="bufSize">void *<name>values</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetnPixelMapfv</name></proto>
+ <param><ptype>GLenum</ptype> <name>map</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param><ptype>GLfloat</ptype> *<name>values</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetnPixelMapfvARB</name></proto>
+ <param><ptype>GLenum</ptype> <name>map</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param len="bufSize"><ptype>GLfloat</ptype> *<name>values</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetnPixelMapuiv</name></proto>
+ <param><ptype>GLenum</ptype> <name>map</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param><ptype>GLuint</ptype> *<name>values</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetnPixelMapuivARB</name></proto>
+ <param><ptype>GLenum</ptype> <name>map</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param len="bufSize"><ptype>GLuint</ptype> *<name>values</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetnPixelMapusv</name></proto>
+ <param><ptype>GLenum</ptype> <name>map</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param><ptype>GLushort</ptype> *<name>values</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetnPixelMapusvARB</name></proto>
+ <param><ptype>GLenum</ptype> <name>map</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param len="bufSize"><ptype>GLushort</ptype> *<name>values</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetnPolygonStipple</name></proto>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param><ptype>GLubyte</ptype> *<name>pattern</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetnPolygonStippleARB</name></proto>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param len="bufSize"><ptype>GLubyte</ptype> *<name>pattern</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetnSeparableFilter</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>format</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>rowBufSize</name></param>
+ <param>void *<name>row</name></param>
+ <param><ptype>GLsizei</ptype> <name>columnBufSize</name></param>
+ <param>void *<name>column</name></param>
+ <param>void *<name>span</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetnSeparableFilterARB</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>format</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>rowBufSize</name></param>
+ <param len="rowBufSize">void *<name>row</name></param>
+ <param><ptype>GLsizei</ptype> <name>columnBufSize</name></param>
+ <param len="columnBufSize">void *<name>column</name></param>
+ <param len="0">void *<name>span</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetnTexImage</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLint</ptype> <name>level</name></param>
+ <param><ptype>GLenum</ptype> <name>format</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param>void *<name>pixels</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetnTexImageARB</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLint</ptype> <name>level</name></param>
+ <param><ptype>GLenum</ptype> <name>format</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param len="bufSize">void *<name>img</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetnUniformdv</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param><ptype>GLdouble</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetnUniformdvARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param len="bufSize"><ptype>GLdouble</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetnUniformfv</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param><ptype>GLfloat</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetnUniformfvARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param len="bufSize"><ptype>GLfloat</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetnUniformfvEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param len="bufSize"><ptype>GLfloat</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetnUniformfvKHR</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param><ptype>GLfloat</ptype> *<name>params</name></param>
+ <alias name="glGetnUniformfv"/>
+ </command>
+ <command>
+ <proto>void <name>glGetnUniformiv</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetnUniformivARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param len="bufSize"><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetnUniformivEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param len="bufSize"><ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetnUniformivKHR</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param><ptype>GLint</ptype> *<name>params</name></param>
+ <alias name="glGetnUniformiv"/>
+ </command>
+ <command>
+ <proto>void <name>glGetnUniformuiv</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param><ptype>GLuint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetnUniformuivARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param len="bufSize"><ptype>GLuint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGetnUniformuivKHR</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param><ptype>GLuint</ptype> *<name>params</name></param>
+ <alias name="glGetnUniformuiv"/>
+ </command>
+ <command>
+ <proto>void <name>glGlobalAlphaFactorbSUN</name></proto>
+ <param><ptype>GLbyte</ptype> <name>factor</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGlobalAlphaFactordSUN</name></proto>
+ <param><ptype>GLdouble</ptype> <name>factor</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGlobalAlphaFactorfSUN</name></proto>
+ <param><ptype>GLfloat</ptype> <name>factor</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGlobalAlphaFactoriSUN</name></proto>
+ <param><ptype>GLint</ptype> <name>factor</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGlobalAlphaFactorsSUN</name></proto>
+ <param><ptype>GLshort</ptype> <name>factor</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGlobalAlphaFactorubSUN</name></proto>
+ <param><ptype>GLubyte</ptype> <name>factor</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGlobalAlphaFactoruiSUN</name></proto>
+ <param><ptype>GLuint</ptype> <name>factor</name></param>
+ </command>
+ <command>
+ <proto>void <name>glGlobalAlphaFactorusSUN</name></proto>
+ <param><ptype>GLushort</ptype> <name>factor</name></param>
+ </command>
+ <command>
+ <proto>void <name>glHint</name></proto>
+ <param group="HintTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="HintMode"><ptype>GLenum</ptype> <name>mode</name></param>
+ <glx type="render" opcode="85"/>
+ </command>
+ <command>
+ <proto>void <name>glHintPGI</name></proto>
+ <param group="HintTargetPGI"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLint</ptype> <name>mode</name></param>
+ </command>
+ <command>
+ <proto>void <name>glHistogram</name></proto>
+ <param group="HistogramTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param group="PixelInternalFormat"><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>sink</name></param>
+ <glx type="render" opcode="4110"/>
+ </command>
+ <command>
+ <proto>void <name>glHistogramEXT</name></proto>
+ <param group="HistogramTargetEXT"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param group="PixelInternalFormat"><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>sink</name></param>
+ <alias name="glHistogram"/>
+ <glx type="render" opcode="4110"/>
+ </command>
+ <command>
+ <proto>void <name>glIglooInterfaceSGIX</name></proto>
+ <param group="IglooFunctionSelectSGIX"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="IglooParameterSGIX" len="COMPSIZE(pname)">const void *<name>params</name></param>
+ <glx type="render" opcode="200"/>
+ </command>
+ <command>
+ <proto>void <name>glImageTransformParameterfHP</name></proto>
+ <param group="ImageTransformTargetHP"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="ImageTransformPNameHP"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLfloat</ptype> <name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glImageTransformParameterfvHP</name></proto>
+ <param group="ImageTransformTargetHP"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="ImageTransformPNameHP"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)">const <ptype>GLfloat</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glImageTransformParameteriHP</name></proto>
+ <param group="ImageTransformTargetHP"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="ImageTransformPNameHP"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLint</ptype> <name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glImageTransformParameterivHP</name></proto>
+ <param group="ImageTransformTargetHP"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="ImageTransformPNameHP"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)">const <ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto group="sync"><ptype>GLsync</ptype> <name>glImportSyncEXT</name></proto>
+ <param><ptype>GLenum</ptype> <name>external_sync_type</name></param>
+ <param><ptype>GLintptr</ptype> <name>external_sync</name></param>
+ <param><ptype>GLbitfield</ptype> <name>flags</name></param>
+ </command>
+ <command>
+ <proto>void <name>glIndexFormatNV</name></proto>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ </command>
+ <command>
+ <proto>void <name>glIndexFuncEXT</name></proto>
+ <param group="IndexFunctionEXT"><ptype>GLenum</ptype> <name>func</name></param>
+ <param group="ClampedFloat32"><ptype>GLclampf</ptype> <name>ref</name></param>
+ </command>
+ <command>
+ <proto>void <name>glIndexMask</name></proto>
+ <param group="MaskedColorIndexValueI"><ptype>GLuint</ptype> <name>mask</name></param>
+ <glx type="render" opcode="136"/>
+ </command>
+ <command>
+ <proto>void <name>glIndexMaterialEXT</name></proto>
+ <param group="MaterialFace"><ptype>GLenum</ptype> <name>face</name></param>
+ <param group="IndexMaterialParameterEXT"><ptype>GLenum</ptype> <name>mode</name></param>
+ </command>
+ <command>
+ <proto>void <name>glIndexPointer</name></proto>
+ <param group="IndexPointerType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ <param len="COMPSIZE(type,stride)">const void *<name>pointer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glIndexPointerEXT</name></proto>
+ <param group="IndexPointerType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="COMPSIZE(type,stride,count)">const void *<name>pointer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glIndexPointerListIBM</name></proto>
+ <param group="IndexPointerType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLint</ptype> <name>stride</name></param>
+ <param len="COMPSIZE(type,stride)">const void **<name>pointer</name></param>
+ <param><ptype>GLint</ptype> <name>ptrstride</name></param>
+ </command>
+ <command>
+ <proto>void <name>glIndexd</name></proto>
+ <param group="ColorIndexValueD"><ptype>GLdouble</ptype> <name>c</name></param>
+ <vecequiv name="glIndexdv"/>
+ </command>
+ <command>
+ <proto>void <name>glIndexdv</name></proto>
+ <param group="ColorIndexValueD" len="1">const <ptype>GLdouble</ptype> *<name>c</name></param>
+ <glx type="render" opcode="24"/>
+ </command>
+ <command>
+ <proto>void <name>glIndexf</name></proto>
+ <param group="ColorIndexValueF"><ptype>GLfloat</ptype> <name>c</name></param>
+ <vecequiv name="glIndexfv"/>
+ </command>
+ <command>
+ <proto>void <name>glIndexfv</name></proto>
+ <param group="ColorIndexValueF" len="1">const <ptype>GLfloat</ptype> *<name>c</name></param>
+ <glx type="render" opcode="25"/>
+ </command>
+ <command>
+ <proto>void <name>glIndexi</name></proto>
+ <param group="ColorIndexValueI"><ptype>GLint</ptype> <name>c</name></param>
+ <vecequiv name="glIndexiv"/>
+ </command>
+ <command>
+ <proto>void <name>glIndexiv</name></proto>
+ <param group="ColorIndexValueI" len="1">const <ptype>GLint</ptype> *<name>c</name></param>
+ <glx type="render" opcode="26"/>
+ </command>
+ <command>
+ <proto>void <name>glIndexs</name></proto>
+ <param group="ColorIndexValueS"><ptype>GLshort</ptype> <name>c</name></param>
+ <vecequiv name="glIndexsv"/>
+ </command>
+ <command>
+ <proto>void <name>glIndexsv</name></proto>
+ <param group="ColorIndexValueS" len="1">const <ptype>GLshort</ptype> *<name>c</name></param>
+ <glx type="render" opcode="27"/>
+ </command>
+ <command>
+ <proto>void <name>glIndexub</name></proto>
+ <param group="ColorIndexValueUB"><ptype>GLubyte</ptype> <name>c</name></param>
+ <vecequiv name="glIndexubv"/>
+ </command>
+ <command>
+ <proto>void <name>glIndexubv</name></proto>
+ <param group="ColorIndexValueUB" len="1">const <ptype>GLubyte</ptype> *<name>c</name></param>
+ <glx type="render" opcode="194"/>
+ </command>
+ <command>
+ <proto>void <name>glIndexxOES</name></proto>
+ <param><ptype>GLfixed</ptype> <name>component</name></param>
+ </command>
+ <command>
+ <proto>void <name>glIndexxvOES</name></proto>
+ <param len="1">const <ptype>GLfixed</ptype> *<name>component</name></param>
+ </command>
+ <command>
+ <proto>void <name>glInitNames</name></proto>
+ <glx type="render" opcode="121"/>
+ </command>
+ <command>
+ <proto>void <name>glInsertComponentEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>res</name></param>
+ <param><ptype>GLuint</ptype> <name>src</name></param>
+ <param><ptype>GLuint</ptype> <name>num</name></param>
+ </command>
+ <command>
+ <proto>void <name>glInsertEventMarkerEXT</name></proto>
+ <param><ptype>GLsizei</ptype> <name>length</name></param>
+ <param>const <ptype>GLchar</ptype> *<name>marker</name></param>
+ </command>
+ <command>
+ <proto>void <name>glInstrumentsBufferSGIX</name></proto>
+ <param><ptype>GLsizei</ptype> <name>size</name></param>
+ <param len="size"><ptype>GLint</ptype> *<name>buffer</name></param>
+ <glx type="vendor" opcode="4103"/>
+ </command>
+ <command>
+ <proto>void <name>glInterleavedArrays</name></proto>
+ <param group="InterleavedArrayFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ <param len="COMPSIZE(format,stride)">const void *<name>pointer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glInterpolatePathsNV</name></proto>
+ <param group="Path"><ptype>GLuint</ptype> <name>resultPath</name></param>
+ <param group="Path"><ptype>GLuint</ptype> <name>pathA</name></param>
+ <param group="Path"><ptype>GLuint</ptype> <name>pathB</name></param>
+ <param><ptype>GLfloat</ptype> <name>weight</name></param>
+ </command>
+ <command>
+ <proto>void <name>glInvalidateBufferData</name></proto>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glInvalidateBufferSubData</name></proto>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <param group="BufferOffset"><ptype>GLintptr</ptype> <name>offset</name></param>
+ <param group="BufferSize"><ptype>GLsizeiptr</ptype> <name>length</name></param>
+ </command>
+ <command>
+ <proto>void <name>glInvalidateFramebuffer</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLsizei</ptype> <name>numAttachments</name></param>
+ <param len="numAttachments">const <ptype>GLenum</ptype> *<name>attachments</name></param>
+ </command>
+ <command>
+ <proto>void <name>glInvalidateNamedFramebufferData</name></proto>
+ <param><ptype>GLuint</ptype> <name>framebuffer</name></param>
+ <param><ptype>GLsizei</ptype> <name>numAttachments</name></param>
+ <param>const <ptype>GLenum</ptype> *<name>attachments</name></param>
+ </command>
+ <command>
+ <proto>void <name>glInvalidateNamedFramebufferSubData</name></proto>
+ <param><ptype>GLuint</ptype> <name>framebuffer</name></param>
+ <param><ptype>GLsizei</ptype> <name>numAttachments</name></param>
+ <param>const <ptype>GLenum</ptype> *<name>attachments</name></param>
+ <param><ptype>GLint</ptype> <name>x</name></param>
+ <param><ptype>GLint</ptype> <name>y</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ </command>
+ <command>
+ <proto>void <name>glInvalidateSubFramebuffer</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLsizei</ptype> <name>numAttachments</name></param>
+ <param len="numAttachments">const <ptype>GLenum</ptype> *<name>attachments</name></param>
+ <param><ptype>GLint</ptype> <name>x</name></param>
+ <param><ptype>GLint</ptype> <name>y</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ </command>
+ <command>
+ <proto>void <name>glInvalidateTexImage</name></proto>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLint</ptype> <name>level</name></param>
+ </command>
+ <command>
+ <proto>void <name>glInvalidateTexSubImage</name></proto>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLint</ptype> <name>level</name></param>
+ <param><ptype>GLint</ptype> <name>xoffset</name></param>
+ <param><ptype>GLint</ptype> <name>yoffset</name></param>
+ <param><ptype>GLint</ptype> <name>zoffset</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param><ptype>GLsizei</ptype> <name>depth</name></param>
+ </command>
+ <command>
+ <proto group="Boolean"><ptype>GLboolean</ptype> <name>glIsAsyncMarkerSGIX</name></proto>
+ <param><ptype>GLuint</ptype> <name>marker</name></param>
+ </command>
+ <command>
+ <proto group="Boolean"><ptype>GLboolean</ptype> <name>glIsBuffer</name></proto>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ </command>
+ <command>
+ <proto group="Boolean"><ptype>GLboolean</ptype> <name>glIsBufferARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <alias name="glIsBuffer"/>
+ </command>
+ <command>
+ <proto group="Boolean"><ptype>GLboolean</ptype> <name>glIsBufferResidentNV</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ </command>
+ <command>
+ <proto group="Boolean"><ptype>GLboolean</ptype> <name>glIsEnabled</name></proto>
+ <param group="EnableCap"><ptype>GLenum</ptype> <name>cap</name></param>
+ <glx type="single" opcode="140"/>
+ </command>
+ <command>
+ <proto group="Boolean"><ptype>GLboolean</ptype> <name>glIsEnabledIndexedEXT</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <alias name="glIsEnabledi"/>
+ </command>
+ <command>
+ <proto group="Boolean"><ptype>GLboolean</ptype> <name>glIsEnabledi</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ </command>
+ <command>
+ <proto group="Boolean"><ptype>GLboolean</ptype> <name>glIsEnablediEXT</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <alias name="glIsEnabledi"/>
+ </command>
+ <command>
+ <proto group="Boolean"><ptype>GLboolean</ptype> <name>glIsFenceAPPLE</name></proto>
+ <param group="FenceNV"><ptype>GLuint</ptype> <name>fence</name></param>
+ </command>
+ <command>
+ <proto group="Boolean"><ptype>GLboolean</ptype> <name>glIsFenceNV</name></proto>
+ <param group="FenceNV"><ptype>GLuint</ptype> <name>fence</name></param>
+ <glx type="vendor" opcode="1278"/>
+ </command>
+ <command>
+ <proto group="Boolean"><ptype>GLboolean</ptype> <name>glIsFramebuffer</name></proto>
+ <param><ptype>GLuint</ptype> <name>framebuffer</name></param>
+ <glx type="vendor" opcode="1425"/>
+ </command>
+ <command>
+ <proto group="Boolean"><ptype>GLboolean</ptype> <name>glIsFramebufferEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>framebuffer</name></param>
+ <alias name="glIsFramebuffer"/>
+ <glx type="vendor" opcode="1425"/>
+ </command>
+ <command>
+ <proto><ptype>GLboolean</ptype> <name>glIsFramebufferOES</name></proto>
+ <param><ptype>GLuint</ptype> <name>framebuffer</name></param>
+ </command>
+ <command>
+ <proto><ptype>GLboolean</ptype> <name>glIsImageHandleResidentARB</name></proto>
+ <param><ptype>GLuint64</ptype> <name>handle</name></param>
+ </command>
+ <command>
+ <proto group="Boolean"><ptype>GLboolean</ptype> <name>glIsImageHandleResidentNV</name></proto>
+ <param><ptype>GLuint64</ptype> <name>handle</name></param>
+ </command>
+ <command>
+ <proto group="Boolean"><ptype>GLboolean</ptype> <name>glIsList</name></proto>
+ <param group="List"><ptype>GLuint</ptype> <name>list</name></param>
+ <glx type="single" opcode="141"/>
+ </command>
+ <command>
+ <proto group="Boolean"><ptype>GLboolean</ptype> <name>glIsNameAMD</name></proto>
+ <param><ptype>GLenum</ptype> <name>identifier</name></param>
+ <param><ptype>GLuint</ptype> <name>name</name></param>
+ </command>
+ <command>
+ <proto group="Boolean"><ptype>GLboolean</ptype> <name>glIsNamedBufferResidentNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ </command>
+ <command>
+ <proto group="Boolean"><ptype>GLboolean</ptype> <name>glIsNamedStringARB</name></proto>
+ <param><ptype>GLint</ptype> <name>namelen</name></param>
+ <param len="namelen">const <ptype>GLchar</ptype> *<name>name</name></param>
+ </command>
+ <command>
+ <proto group="Boolean"><ptype>GLboolean</ptype> <name>glIsObjectBufferATI</name></proto>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ </command>
+ <command>
+ <proto group="Boolean"><ptype>GLboolean</ptype> <name>glIsOcclusionQueryNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ </command>
+ <command>
+ <proto group="Boolean"><ptype>GLboolean</ptype> <name>glIsPathNV</name></proto>
+ <param group="Path"><ptype>GLuint</ptype> <name>path</name></param>
+ </command>
+ <command>
+ <proto group="Boolean"><ptype>GLboolean</ptype> <name>glIsPointInFillPathNV</name></proto>
+ <param group="Path"><ptype>GLuint</ptype> <name>path</name></param>
+ <param group="MaskedStencilValue"><ptype>GLuint</ptype> <name>mask</name></param>
+ <param><ptype>GLfloat</ptype> <name>x</name></param>
+ <param><ptype>GLfloat</ptype> <name>y</name></param>
+ </command>
+ <command>
+ <proto group="Boolean"><ptype>GLboolean</ptype> <name>glIsPointInStrokePathNV</name></proto>
+ <param group="Path"><ptype>GLuint</ptype> <name>path</name></param>
+ <param><ptype>GLfloat</ptype> <name>x</name></param>
+ <param><ptype>GLfloat</ptype> <name>y</name></param>
+ </command>
+ <command>
+ <proto group="Boolean"><ptype>GLboolean</ptype> <name>glIsProgram</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <glx type="single" opcode="197"/>
+ </command>
+ <command>
+ <proto group="Boolean"><ptype>GLboolean</ptype> <name>glIsProgramARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <glx type="vendor" opcode="1304"/>
+ </command>
+ <command>
+ <proto group="Boolean"><ptype>GLboolean</ptype> <name>glIsProgramNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <alias name="glIsProgramARB"/>
+ <glx type="vendor" opcode="1304"/>
+ </command>
+ <command>
+ <proto group="Boolean"><ptype>GLboolean</ptype> <name>glIsProgramPipeline</name></proto>
+ <param><ptype>GLuint</ptype> <name>pipeline</name></param>
+ </command>
+ <command>
+ <proto><ptype>GLboolean</ptype> <name>glIsProgramPipelineEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>pipeline</name></param>
+ </command>
+ <command>
+ <proto group="Boolean"><ptype>GLboolean</ptype> <name>glIsQuery</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <glx type="single" opcode="163"/>
+ </command>
+ <command>
+ <proto group="Boolean"><ptype>GLboolean</ptype> <name>glIsQueryARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <alias name="glIsQuery"/>
+ </command>
+ <command>
+ <proto><ptype>GLboolean</ptype> <name>glIsQueryEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ </command>
+ <command>
+ <proto group="Boolean"><ptype>GLboolean</ptype> <name>glIsRenderbuffer</name></proto>
+ <param><ptype>GLuint</ptype> <name>renderbuffer</name></param>
+ <glx type="vendor" opcode="1422"/>
+ </command>
+ <command>
+ <proto group="Boolean"><ptype>GLboolean</ptype> <name>glIsRenderbufferEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>renderbuffer</name></param>
+ <alias name="glIsRenderbuffer"/>
+ <glx type="vendor" opcode="1422"/>
+ </command>
+ <command>
+ <proto><ptype>GLboolean</ptype> <name>glIsRenderbufferOES</name></proto>
+ <param><ptype>GLuint</ptype> <name>renderbuffer</name></param>
+ </command>
+ <command>
+ <proto group="Boolean"><ptype>GLboolean</ptype> <name>glIsSampler</name></proto>
+ <param><ptype>GLuint</ptype> <name>sampler</name></param>
+ </command>
+ <command>
+ <proto group="Boolean"><ptype>GLboolean</ptype> <name>glIsShader</name></proto>
+ <param><ptype>GLuint</ptype> <name>shader</name></param>
+ <glx type="single" opcode="196"/>
+ </command>
+ <command>
+ <proto group="Boolean"><ptype>GLboolean</ptype> <name>glIsSync</name></proto>
+ <param group="sync"><ptype>GLsync</ptype> <name>sync</name></param>
+ </command>
+ <command>
+ <proto><ptype>GLboolean</ptype> <name>glIsSyncAPPLE</name></proto>
+ <param><ptype>GLsync</ptype> <name>sync</name></param>
+ <alias name="glIsSync"/>
+ </command>
+ <command>
+ <proto group="Boolean"><ptype>GLboolean</ptype> <name>glIsTexture</name></proto>
+ <param group="Texture"><ptype>GLuint</ptype> <name>texture</name></param>
+ <glx type="single" opcode="146"/>
+ </command>
+ <command>
+ <proto group="Boolean"><ptype>GLboolean</ptype> <name>glIsTextureEXT</name></proto>
+ <param group="Texture"><ptype>GLuint</ptype> <name>texture</name></param>
+ <glx type="vendor" opcode="14"/>
+ </command>
+ <command>
+ <proto><ptype>GLboolean</ptype> <name>glIsTextureHandleResidentARB</name></proto>
+ <param><ptype>GLuint64</ptype> <name>handle</name></param>
+ </command>
+ <command>
+ <proto group="Boolean"><ptype>GLboolean</ptype> <name>glIsTextureHandleResidentNV</name></proto>
+ <param><ptype>GLuint64</ptype> <name>handle</name></param>
+ </command>
+ <command>
+ <proto group="Boolean"><ptype>GLboolean</ptype> <name>glIsTransformFeedback</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ </command>
+ <command>
+ <proto group="Boolean"><ptype>GLboolean</ptype> <name>glIsTransformFeedbackNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <alias name="glIsTransformFeedback"/>
+ </command>
+ <command>
+ <proto group="Boolean"><ptype>GLboolean</ptype> <name>glIsVariantEnabledEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <param group="VariantCapEXT"><ptype>GLenum</ptype> <name>cap</name></param>
+ </command>
+ <command>
+ <proto group="Boolean"><ptype>GLboolean</ptype> <name>glIsVertexArray</name></proto>
+ <param><ptype>GLuint</ptype> <name>array</name></param>
+ <glx type="single" opcode="207"/>
+ </command>
+ <command>
+ <proto group="Boolean"><ptype>GLboolean</ptype> <name>glIsVertexArrayAPPLE</name></proto>
+ <param><ptype>GLuint</ptype> <name>array</name></param>
+ <alias name="glIsVertexArray"/>
+ </command>
+ <command>
+ <proto><ptype>GLboolean</ptype> <name>glIsVertexArrayOES</name></proto>
+ <param><ptype>GLuint</ptype> <name>array</name></param>
+ <alias name="glIsVertexArray"/>
+ </command>
+ <command>
+ <proto group="Boolean"><ptype>GLboolean</ptype> <name>glIsVertexAttribEnabledAPPLE</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ </command>
+ <command>
+ <proto>void <name>glLabelObjectEXT</name></proto>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLuint</ptype> <name>object</name></param>
+ <param><ptype>GLsizei</ptype> <name>length</name></param>
+ <param>const <ptype>GLchar</ptype> *<name>label</name></param>
+ </command>
+ <command>
+ <proto>void <name>glLightEnviSGIX</name></proto>
+ <param group="LightEnvParameterSGIX"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glLightModelf</name></proto>
+ <param group="LightModelParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLfloat</ptype> <name>param</name></param>
+ <glx type="render" opcode="90"/>
+ </command>
+ <command>
+ <proto>void <name>glLightModelfv</name></proto>
+ <param group="LightModelParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)">const <ptype>GLfloat</ptype> *<name>params</name></param>
+ <glx type="render" opcode="91"/>
+ </command>
+ <command>
+ <proto>void <name>glLightModeli</name></proto>
+ <param group="LightModelParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLint</ptype> <name>param</name></param>
+ <glx type="render" opcode="92"/>
+ </command>
+ <command>
+ <proto>void <name>glLightModeliv</name></proto>
+ <param group="LightModelParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)">const <ptype>GLint</ptype> *<name>params</name></param>
+ <glx type="render" opcode="93"/>
+ </command>
+ <command>
+ <proto>void <name>glLightModelx</name></proto>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLfixed</ptype> <name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glLightModelxOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLfixed</ptype> <name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glLightModelxv</name></proto>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)">const <ptype>GLfixed</ptype> *<name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glLightModelxvOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)">const <ptype>GLfixed</ptype> *<name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glLightf</name></proto>
+ <param group="LightName"><ptype>GLenum</ptype> <name>light</name></param>
+ <param group="LightParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedFloat32"><ptype>GLfloat</ptype> <name>param</name></param>
+ <glx type="render" opcode="86"/>
+ </command>
+ <command>
+ <proto>void <name>glLightfv</name></proto>
+ <param group="LightName"><ptype>GLenum</ptype> <name>light</name></param>
+ <param group="LightParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedFloat32" len="COMPSIZE(pname)">const <ptype>GLfloat</ptype> *<name>params</name></param>
+ <glx type="render" opcode="87"/>
+ </command>
+ <command>
+ <proto>void <name>glLighti</name></proto>
+ <param group="LightName"><ptype>GLenum</ptype> <name>light</name></param>
+ <param group="LightParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>param</name></param>
+ <glx type="render" opcode="88"/>
+ </command>
+ <command>
+ <proto>void <name>glLightiv</name></proto>
+ <param group="LightName"><ptype>GLenum</ptype> <name>light</name></param>
+ <param group="LightParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedInt32" len="COMPSIZE(pname)">const <ptype>GLint</ptype> *<name>params</name></param>
+ <glx type="render" opcode="89"/>
+ </command>
+ <command>
+ <proto>void <name>glLightx</name></proto>
+ <param><ptype>GLenum</ptype> <name>light</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLfixed</ptype> <name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glLightxOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>light</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLfixed</ptype> <name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glLightxv</name></proto>
+ <param><ptype>GLenum</ptype> <name>light</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)">const <ptype>GLfixed</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glLightxvOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>light</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)">const <ptype>GLfixed</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glLineStipple</name></proto>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>factor</name></param>
+ <param group="LineStipple"><ptype>GLushort</ptype> <name>pattern</name></param>
+ <glx type="render" opcode="94"/>
+ </command>
+ <command>
+ <proto>void <name>glLineWidth</name></proto>
+ <param group="CheckedFloat32"><ptype>GLfloat</ptype> <name>width</name></param>
+ <glx type="render" opcode="95"/>
+ </command>
+ <command>
+ <proto>void <name>glLineWidthx</name></proto>
+ <param><ptype>GLfixed</ptype> <name>width</name></param>
+ </command>
+ <command>
+ <proto>void <name>glLineWidthxOES</name></proto>
+ <param><ptype>GLfixed</ptype> <name>width</name></param>
+ </command>
+ <command>
+ <proto>void <name>glLinkProgram</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ </command>
+ <command>
+ <proto>void <name>glLinkProgramARB</name></proto>
+ <param group="handleARB"><ptype>GLhandleARB</ptype> <name>programObj</name></param>
+ <alias name="glLinkProgram"/>
+ </command>
+ <command>
+ <proto>void <name>glListBase</name></proto>
+ <param group="List"><ptype>GLuint</ptype> <name>base</name></param>
+ <glx type="render" opcode="3"/>
+ </command>
+ <command>
+ <proto>void <name>glListParameterfSGIX</name></proto>
+ <param group="List"><ptype>GLuint</ptype> <name>list</name></param>
+ <param group="ListParameterName"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedFloat32"><ptype>GLfloat</ptype> <name>param</name></param>
+ <glx type="render" opcode="2078"/>
+ </command>
+ <command>
+ <proto>void <name>glListParameterfvSGIX</name></proto>
+ <param group="List"><ptype>GLuint</ptype> <name>list</name></param>
+ <param group="ListParameterName"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedFloat32" len="COMPSIZE(pname)">const <ptype>GLfloat</ptype> *<name>params</name></param>
+ <glx type="render" opcode="2079"/>
+ </command>
+ <command>
+ <proto>void <name>glListParameteriSGIX</name></proto>
+ <param group="List"><ptype>GLuint</ptype> <name>list</name></param>
+ <param group="ListParameterName"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>param</name></param>
+ <glx type="render" opcode="2080"/>
+ </command>
+ <command>
+ <proto>void <name>glListParameterivSGIX</name></proto>
+ <param group="List"><ptype>GLuint</ptype> <name>list</name></param>
+ <param group="ListParameterName"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedInt32" len="COMPSIZE(pname)">const <ptype>GLint</ptype> *<name>params</name></param>
+ <glx type="render" opcode="2081"/>
+ </command>
+ <command>
+ <proto>void <name>glLoadIdentity</name></proto>
+ <glx type="render" opcode="176"/>
+ </command>
+ <command>
+ <proto>void <name>glLoadIdentityDeformationMapSGIX</name></proto>
+ <param group="FfdMaskSGIX"><ptype>GLbitfield</ptype> <name>mask</name></param>
+ <glx type="render" opcode="2076"/>
+ </command>
+ <command>
+ <proto>void <name>glLoadMatrixd</name></proto>
+ <param len="16">const <ptype>GLdouble</ptype> *<name>m</name></param>
+ <glx type="render" opcode="178"/>
+ </command>
+ <command>
+ <proto>void <name>glLoadMatrixf</name></proto>
+ <param len="16">const <ptype>GLfloat</ptype> *<name>m</name></param>
+ <glx type="render" opcode="177"/>
+ </command>
+ <command>
+ <proto>void <name>glLoadMatrixx</name></proto>
+ <param len="16">const <ptype>GLfixed</ptype> *<name>m</name></param>
+ </command>
+ <command>
+ <proto>void <name>glLoadMatrixxOES</name></proto>
+ <param len="16">const <ptype>GLfixed</ptype> *<name>m</name></param>
+ </command>
+ <command>
+ <proto>void <name>glLoadName</name></proto>
+ <param group="SelectName"><ptype>GLuint</ptype> <name>name</name></param>
+ <glx type="render" opcode="122"/>
+ </command>
+ <command>
+ <proto>void <name>glLoadPaletteFromModelViewMatrixOES</name></proto>
+ </command>
+ <command>
+ <proto>void <name>glLoadProgramNV</name></proto>
+ <param group="VertexAttribEnumNV"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <param><ptype>GLsizei</ptype> <name>len</name></param>
+ <param len="len">const <ptype>GLubyte</ptype> *<name>program</name></param>
+ <glx type="render" opcode="4183"/>
+ </command>
+ <command>
+ <proto>void <name>glLoadTransposeMatrixd</name></proto>
+ <param len="16">const <ptype>GLdouble</ptype> *<name>m</name></param>
+ </command>
+ <command>
+ <proto>void <name>glLoadTransposeMatrixdARB</name></proto>
+ <param len="16">const <ptype>GLdouble</ptype> *<name>m</name></param>
+ <alias name="glLoadTransposeMatrixd"/>
+ </command>
+ <command>
+ <proto>void <name>glLoadTransposeMatrixf</name></proto>
+ <param len="16">const <ptype>GLfloat</ptype> *<name>m</name></param>
+ </command>
+ <command>
+ <proto>void <name>glLoadTransposeMatrixfARB</name></proto>
+ <param len="16">const <ptype>GLfloat</ptype> *<name>m</name></param>
+ <alias name="glLoadTransposeMatrixf"/>
+ </command>
+ <command>
+ <proto>void <name>glLoadTransposeMatrixxOES</name></proto>
+ <param len="16">const <ptype>GLfixed</ptype> *<name>m</name></param>
+ </command>
+ <command>
+ <proto>void <name>glLockArraysEXT</name></proto>
+ <param><ptype>GLint</ptype> <name>first</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ </command>
+ <command>
+ <proto>void <name>glLogicOp</name></proto>
+ <param group="LogicOp"><ptype>GLenum</ptype> <name>opcode</name></param>
+ <glx type="render" opcode="161"/>
+ </command>
+ <command>
+ <proto>void <name>glMakeBufferNonResidentNV</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMakeBufferResidentNV</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>access</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMakeImageHandleNonResidentARB</name></proto>
+ <param><ptype>GLuint64</ptype> <name>handle</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMakeImageHandleNonResidentNV</name></proto>
+ <param><ptype>GLuint64</ptype> <name>handle</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMakeImageHandleResidentARB</name></proto>
+ <param><ptype>GLuint64</ptype> <name>handle</name></param>
+ <param><ptype>GLenum</ptype> <name>access</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMakeImageHandleResidentNV</name></proto>
+ <param><ptype>GLuint64</ptype> <name>handle</name></param>
+ <param><ptype>GLenum</ptype> <name>access</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMakeNamedBufferNonResidentNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMakeNamedBufferResidentNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <param><ptype>GLenum</ptype> <name>access</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMakeTextureHandleNonResidentARB</name></proto>
+ <param><ptype>GLuint64</ptype> <name>handle</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMakeTextureHandleNonResidentNV</name></proto>
+ <param><ptype>GLuint64</ptype> <name>handle</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMakeTextureHandleResidentARB</name></proto>
+ <param><ptype>GLuint64</ptype> <name>handle</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMakeTextureHandleResidentNV</name></proto>
+ <param><ptype>GLuint64</ptype> <name>handle</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMap1d</name></proto>
+ <param group="MapTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>u1</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>u2</name></param>
+ <param><ptype>GLint</ptype> <name>stride</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>order</name></param>
+ <param group="CoordD" len="COMPSIZE(target,stride,order)">const <ptype>GLdouble</ptype> *<name>points</name></param>
+ <glx type="render" opcode="143"/>
+ </command>
+ <command>
+ <proto>void <name>glMap1f</name></proto>
+ <param group="MapTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>u1</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>u2</name></param>
+ <param><ptype>GLint</ptype> <name>stride</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>order</name></param>
+ <param group="CoordF" len="COMPSIZE(target,stride,order)">const <ptype>GLfloat</ptype> *<name>points</name></param>
+ <glx type="render" opcode="144"/>
+ </command>
+ <command>
+ <proto>void <name>glMap1xOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLfixed</ptype> <name>u1</name></param>
+ <param><ptype>GLfixed</ptype> <name>u2</name></param>
+ <param><ptype>GLint</ptype> <name>stride</name></param>
+ <param><ptype>GLint</ptype> <name>order</name></param>
+ <param><ptype>GLfixed</ptype> <name>points</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMap2d</name></proto>
+ <param group="MapTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>u1</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>u2</name></param>
+ <param><ptype>GLint</ptype> <name>ustride</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>uorder</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>v1</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>v2</name></param>
+ <param><ptype>GLint</ptype> <name>vstride</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>vorder</name></param>
+ <param group="CoordD" len="COMPSIZE(target,ustride,uorder,vstride,vorder)">const <ptype>GLdouble</ptype> *<name>points</name></param>
+ <glx type="render" opcode="145"/>
+ </command>
+ <command>
+ <proto>void <name>glMap2f</name></proto>
+ <param group="MapTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>u1</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>u2</name></param>
+ <param><ptype>GLint</ptype> <name>ustride</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>uorder</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>v1</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>v2</name></param>
+ <param><ptype>GLint</ptype> <name>vstride</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>vorder</name></param>
+ <param group="CoordF" len="COMPSIZE(target,ustride,uorder,vstride,vorder)">const <ptype>GLfloat</ptype> *<name>points</name></param>
+ <glx type="render" opcode="146"/>
+ </command>
+ <command>
+ <proto>void <name>glMap2xOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLfixed</ptype> <name>u1</name></param>
+ <param><ptype>GLfixed</ptype> <name>u2</name></param>
+ <param><ptype>GLint</ptype> <name>ustride</name></param>
+ <param><ptype>GLint</ptype> <name>uorder</name></param>
+ <param><ptype>GLfixed</ptype> <name>v1</name></param>
+ <param><ptype>GLfixed</ptype> <name>v2</name></param>
+ <param><ptype>GLint</ptype> <name>vstride</name></param>
+ <param><ptype>GLint</ptype> <name>vorder</name></param>
+ <param><ptype>GLfixed</ptype> <name>points</name></param>
+ </command>
+ <command>
+ <proto>void *<name>glMapBuffer</name></proto>
+ <param group="BufferTargetARB"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="BufferAccessARB"><ptype>GLenum</ptype> <name>access</name></param>
+ </command>
+ <command>
+ <proto>void *<name>glMapBufferARB</name></proto>
+ <param group="BufferTargetARB"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="BufferAccessARB"><ptype>GLenum</ptype> <name>access</name></param>
+ <alias name="glMapBuffer"/>
+ </command>
+ <command>
+ <proto>void *<name>glMapBufferOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>access</name></param>
+ <alias name="glMapBuffer"/>
+ </command>
+ <command>
+ <proto>void *<name>glMapBufferRange</name></proto>
+ <param group="BufferTargetARB"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="BufferOffset"><ptype>GLintptr</ptype> <name>offset</name></param>
+ <param group="BufferSize"><ptype>GLsizeiptr</ptype> <name>length</name></param>
+ <param group="BufferAccessMask"><ptype>GLbitfield</ptype> <name>access</name></param>
+ <glx type="single" opcode="205"/>
+ </command>
+ <command>
+ <proto>void *<name>glMapBufferRangeEXT</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLintptr</ptype> <name>offset</name></param>
+ <param><ptype>GLsizeiptr</ptype> <name>length</name></param>
+ <param><ptype>GLbitfield</ptype> <name>access</name></param>
+ <alias name="glMapBufferRange"/>
+ </command>
+ <command>
+ <proto>void <name>glMapControlPointsNV</name></proto>
+ <param group="EvalTargetNV"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param group="MapTypeNV"><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>ustride</name></param>
+ <param><ptype>GLsizei</ptype> <name>vstride</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>uorder</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>vorder</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>packed</name></param>
+ <param len="COMPSIZE(target,uorder,vorder)">const void *<name>points</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMapGrid1d</name></proto>
+ <param><ptype>GLint</ptype> <name>un</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>u1</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>u2</name></param>
+ <glx type="render" opcode="147"/>
+ </command>
+ <command>
+ <proto>void <name>glMapGrid1f</name></proto>
+ <param><ptype>GLint</ptype> <name>un</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>u1</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>u2</name></param>
+ <glx type="render" opcode="148"/>
+ </command>
+ <command>
+ <proto>void <name>glMapGrid1xOES</name></proto>
+ <param><ptype>GLint</ptype> <name>n</name></param>
+ <param><ptype>GLfixed</ptype> <name>u1</name></param>
+ <param><ptype>GLfixed</ptype> <name>u2</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMapGrid2d</name></proto>
+ <param><ptype>GLint</ptype> <name>un</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>u1</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>u2</name></param>
+ <param><ptype>GLint</ptype> <name>vn</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>v1</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>v2</name></param>
+ <glx type="render" opcode="149"/>
+ </command>
+ <command>
+ <proto>void <name>glMapGrid2f</name></proto>
+ <param><ptype>GLint</ptype> <name>un</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>u1</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>u2</name></param>
+ <param><ptype>GLint</ptype> <name>vn</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>v1</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>v2</name></param>
+ <glx type="render" opcode="150"/>
+ </command>
+ <command>
+ <proto>void <name>glMapGrid2xOES</name></proto>
+ <param><ptype>GLint</ptype> <name>n</name></param>
+ <param><ptype>GLfixed</ptype> <name>u1</name></param>
+ <param><ptype>GLfixed</ptype> <name>u2</name></param>
+ <param><ptype>GLfixed</ptype> <name>v1</name></param>
+ <param><ptype>GLfixed</ptype> <name>v2</name></param>
+ </command>
+ <command>
+ <proto>void *<name>glMapNamedBuffer</name></proto>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <param><ptype>GLenum</ptype> <name>access</name></param>
+ </command>
+ <command>
+ <proto>void *<name>glMapNamedBufferEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <param group="VertexBufferObjectAccess"><ptype>GLenum</ptype> <name>access</name></param>
+ </command>
+ <command>
+ <proto>void *<name>glMapNamedBufferRange</name></proto>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <param><ptype>GLintptr</ptype> <name>offset</name></param>
+ <param><ptype>GLsizei</ptype> <name>length</name></param>
+ <param><ptype>GLbitfield</ptype> <name>access</name></param>
+ </command>
+ <command>
+ <proto>void *<name>glMapNamedBufferRangeEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <param><ptype>GLintptr</ptype> <name>offset</name></param>
+ <param><ptype>GLsizeiptr</ptype> <name>length</name></param>
+ <param group="BufferAccessMask"><ptype>GLbitfield</ptype> <name>access</name></param>
+ </command>
+ <command>
+ <proto>void *<name>glMapObjectBufferATI</name></proto>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMapParameterfvNV</name></proto>
+ <param group="EvalTargetNV"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="MapParameterNV"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedFloat32" len="COMPSIZE(target,pname)">const <ptype>GLfloat</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMapParameterivNV</name></proto>
+ <param group="EvalTargetNV"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="MapParameterNV"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedInt32" len="COMPSIZE(target,pname)">const <ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void *<name>glMapTexture2DINTEL</name></proto>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLint</ptype> <name>level</name></param>
+ <param><ptype>GLbitfield</ptype> <name>access</name></param>
+ <param len="1"><ptype>GLint</ptype> *<name>stride</name></param>
+ <param len="1"><ptype>GLenum</ptype> *<name>layout</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMapVertexAttrib1dAPPLE</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLuint</ptype> <name>size</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>u1</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>u2</name></param>
+ <param><ptype>GLint</ptype> <name>stride</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>order</name></param>
+ <param group="CoordD" len="COMPSIZE(size,stride,order)">const <ptype>GLdouble</ptype> *<name>points</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMapVertexAttrib1fAPPLE</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLuint</ptype> <name>size</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>u1</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>u2</name></param>
+ <param><ptype>GLint</ptype> <name>stride</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>order</name></param>
+ <param group="CoordF" len="COMPSIZE(size,stride,order)">const <ptype>GLfloat</ptype> *<name>points</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMapVertexAttrib2dAPPLE</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLuint</ptype> <name>size</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>u1</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>u2</name></param>
+ <param><ptype>GLint</ptype> <name>ustride</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>uorder</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>v1</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>v2</name></param>
+ <param><ptype>GLint</ptype> <name>vstride</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>vorder</name></param>
+ <param group="CoordD" len="COMPSIZE(size,ustride,uorder,vstride,vorder)">const <ptype>GLdouble</ptype> *<name>points</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMapVertexAttrib2fAPPLE</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLuint</ptype> <name>size</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>u1</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>u2</name></param>
+ <param><ptype>GLint</ptype> <name>ustride</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>uorder</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>v1</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>v2</name></param>
+ <param><ptype>GLint</ptype> <name>vstride</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>vorder</name></param>
+ <param group="CoordF" len="COMPSIZE(size,ustride,uorder,vstride,vorder)">const <ptype>GLfloat</ptype> *<name>points</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMaterialf</name></proto>
+ <param group="MaterialFace"><ptype>GLenum</ptype> <name>face</name></param>
+ <param group="MaterialParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedFloat32"><ptype>GLfloat</ptype> <name>param</name></param>
+ <glx type="render" opcode="96"/>
+ </command>
+ <command>
+ <proto>void <name>glMaterialfv</name></proto>
+ <param group="MaterialFace"><ptype>GLenum</ptype> <name>face</name></param>
+ <param group="MaterialParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedFloat32" len="COMPSIZE(pname)">const <ptype>GLfloat</ptype> *<name>params</name></param>
+ <glx type="render" opcode="97"/>
+ </command>
+ <command>
+ <proto>void <name>glMateriali</name></proto>
+ <param group="MaterialFace"><ptype>GLenum</ptype> <name>face</name></param>
+ <param group="MaterialParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>param</name></param>
+ <glx type="render" opcode="98"/>
+ </command>
+ <command>
+ <proto>void <name>glMaterialiv</name></proto>
+ <param group="MaterialFace"><ptype>GLenum</ptype> <name>face</name></param>
+ <param group="MaterialParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedInt32" len="COMPSIZE(pname)">const <ptype>GLint</ptype> *<name>params</name></param>
+ <glx type="render" opcode="99"/>
+ </command>
+ <command>
+ <proto>void <name>glMaterialx</name></proto>
+ <param><ptype>GLenum</ptype> <name>face</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLfixed</ptype> <name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMaterialxOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>face</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLfixed</ptype> <name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMaterialxv</name></proto>
+ <param><ptype>GLenum</ptype> <name>face</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)">const <ptype>GLfixed</ptype> *<name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMaterialxvOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>face</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)">const <ptype>GLfixed</ptype> *<name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMatrixFrustumEXT</name></proto>
+ <param group="MatrixMode"><ptype>GLenum</ptype> <name>mode</name></param>
+ <param><ptype>GLdouble</ptype> <name>left</name></param>
+ <param><ptype>GLdouble</ptype> <name>right</name></param>
+ <param><ptype>GLdouble</ptype> <name>bottom</name></param>
+ <param><ptype>GLdouble</ptype> <name>top</name></param>
+ <param><ptype>GLdouble</ptype> <name>zNear</name></param>
+ <param><ptype>GLdouble</ptype> <name>zFar</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMatrixIndexPointerARB</name></proto>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param group="MatrixIndexPointerTypeARB"><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ <param len="COMPSIZE(size,type,stride)">const void *<name>pointer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMatrixIndexPointerOES</name></proto>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ <param len="COMPSIZE(size,type,stride)">const void *<name>pointer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMatrixIndexubvARB</name></proto>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param len="size">const <ptype>GLubyte</ptype> *<name>indices</name></param>
+ <glx type="render" opcode="4326"/>
+ </command>
+ <command>
+ <proto>void <name>glMatrixIndexuivARB</name></proto>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param len="size">const <ptype>GLuint</ptype> *<name>indices</name></param>
+ <glx type="render" opcode="4328"/>
+ </command>
+ <command>
+ <proto>void <name>glMatrixIndexusvARB</name></proto>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param len="size">const <ptype>GLushort</ptype> *<name>indices</name></param>
+ <glx type="render" opcode="4327"/>
+ </command>
+ <command>
+ <proto>void <name>glMatrixLoad3x2fNV</name></proto>
+ <param><ptype>GLenum</ptype> <name>matrixMode</name></param>
+ <param>const <ptype>GLfloat</ptype> *<name>m</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMatrixLoad3x3fNV</name></proto>
+ <param><ptype>GLenum</ptype> <name>matrixMode</name></param>
+ <param>const <ptype>GLfloat</ptype> *<name>m</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMatrixLoadIdentityEXT</name></proto>
+ <param group="MatrixMode"><ptype>GLenum</ptype> <name>mode</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMatrixLoadTranspose3x3fNV</name></proto>
+ <param><ptype>GLenum</ptype> <name>matrixMode</name></param>
+ <param>const <ptype>GLfloat</ptype> *<name>m</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMatrixLoadTransposedEXT</name></proto>
+ <param group="MatrixMode"><ptype>GLenum</ptype> <name>mode</name></param>
+ <param len="16">const <ptype>GLdouble</ptype> *<name>m</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMatrixLoadTransposefEXT</name></proto>
+ <param group="MatrixMode"><ptype>GLenum</ptype> <name>mode</name></param>
+ <param len="16">const <ptype>GLfloat</ptype> *<name>m</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMatrixLoaddEXT</name></proto>
+ <param group="MatrixMode"><ptype>GLenum</ptype> <name>mode</name></param>
+ <param len="16">const <ptype>GLdouble</ptype> *<name>m</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMatrixLoadfEXT</name></proto>
+ <param group="MatrixMode"><ptype>GLenum</ptype> <name>mode</name></param>
+ <param len="16">const <ptype>GLfloat</ptype> *<name>m</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMatrixMode</name></proto>
+ <param group="MatrixMode"><ptype>GLenum</ptype> <name>mode</name></param>
+ <glx type="render" opcode="179"/>
+ </command>
+ <command>
+ <proto>void <name>glMatrixMult3x2fNV</name></proto>
+ <param><ptype>GLenum</ptype> <name>matrixMode</name></param>
+ <param>const <ptype>GLfloat</ptype> *<name>m</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMatrixMult3x3fNV</name></proto>
+ <param><ptype>GLenum</ptype> <name>matrixMode</name></param>
+ <param>const <ptype>GLfloat</ptype> *<name>m</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMatrixMultTranspose3x3fNV</name></proto>
+ <param><ptype>GLenum</ptype> <name>matrixMode</name></param>
+ <param>const <ptype>GLfloat</ptype> *<name>m</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMatrixMultTransposedEXT</name></proto>
+ <param group="MatrixMode"><ptype>GLenum</ptype> <name>mode</name></param>
+ <param len="16">const <ptype>GLdouble</ptype> *<name>m</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMatrixMultTransposefEXT</name></proto>
+ <param group="MatrixMode"><ptype>GLenum</ptype> <name>mode</name></param>
+ <param len="16">const <ptype>GLfloat</ptype> *<name>m</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMatrixMultdEXT</name></proto>
+ <param group="MatrixMode"><ptype>GLenum</ptype> <name>mode</name></param>
+ <param len="16">const <ptype>GLdouble</ptype> *<name>m</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMatrixMultfEXT</name></proto>
+ <param group="MatrixMode"><ptype>GLenum</ptype> <name>mode</name></param>
+ <param len="16">const <ptype>GLfloat</ptype> *<name>m</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMatrixOrthoEXT</name></proto>
+ <param group="MatrixMode"><ptype>GLenum</ptype> <name>mode</name></param>
+ <param><ptype>GLdouble</ptype> <name>left</name></param>
+ <param><ptype>GLdouble</ptype> <name>right</name></param>
+ <param><ptype>GLdouble</ptype> <name>bottom</name></param>
+ <param><ptype>GLdouble</ptype> <name>top</name></param>
+ <param><ptype>GLdouble</ptype> <name>zNear</name></param>
+ <param><ptype>GLdouble</ptype> <name>zFar</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMatrixPopEXT</name></proto>
+ <param group="MatrixMode"><ptype>GLenum</ptype> <name>mode</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMatrixPushEXT</name></proto>
+ <param group="MatrixMode"><ptype>GLenum</ptype> <name>mode</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMatrixRotatedEXT</name></proto>
+ <param group="MatrixMode"><ptype>GLenum</ptype> <name>mode</name></param>
+ <param><ptype>GLdouble</ptype> <name>angle</name></param>
+ <param><ptype>GLdouble</ptype> <name>x</name></param>
+ <param><ptype>GLdouble</ptype> <name>y</name></param>
+ <param><ptype>GLdouble</ptype> <name>z</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMatrixRotatefEXT</name></proto>
+ <param group="MatrixMode"><ptype>GLenum</ptype> <name>mode</name></param>
+ <param><ptype>GLfloat</ptype> <name>angle</name></param>
+ <param><ptype>GLfloat</ptype> <name>x</name></param>
+ <param><ptype>GLfloat</ptype> <name>y</name></param>
+ <param><ptype>GLfloat</ptype> <name>z</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMatrixScaledEXT</name></proto>
+ <param group="MatrixMode"><ptype>GLenum</ptype> <name>mode</name></param>
+ <param><ptype>GLdouble</ptype> <name>x</name></param>
+ <param><ptype>GLdouble</ptype> <name>y</name></param>
+ <param><ptype>GLdouble</ptype> <name>z</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMatrixScalefEXT</name></proto>
+ <param group="MatrixMode"><ptype>GLenum</ptype> <name>mode</name></param>
+ <param><ptype>GLfloat</ptype> <name>x</name></param>
+ <param><ptype>GLfloat</ptype> <name>y</name></param>
+ <param><ptype>GLfloat</ptype> <name>z</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMatrixTranslatedEXT</name></proto>
+ <param group="MatrixMode"><ptype>GLenum</ptype> <name>mode</name></param>
+ <param><ptype>GLdouble</ptype> <name>x</name></param>
+ <param><ptype>GLdouble</ptype> <name>y</name></param>
+ <param><ptype>GLdouble</ptype> <name>z</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMatrixTranslatefEXT</name></proto>
+ <param group="MatrixMode"><ptype>GLenum</ptype> <name>mode</name></param>
+ <param><ptype>GLfloat</ptype> <name>x</name></param>
+ <param><ptype>GLfloat</ptype> <name>y</name></param>
+ <param><ptype>GLfloat</ptype> <name>z</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMemoryBarrier</name></proto>
+ <param><ptype>GLbitfield</ptype> <name>barriers</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMemoryBarrierByRegion</name></proto>
+ <param><ptype>GLbitfield</ptype> <name>barriers</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMemoryBarrierEXT</name></proto>
+ <param><ptype>GLbitfield</ptype> <name>barriers</name></param>
+ <alias name="glMemoryBarrier"/>
+ </command>
+ <command>
+ <proto>void <name>glMinSampleShading</name></proto>
+ <param group="ColorF"><ptype>GLfloat</ptype> <name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMinSampleShadingARB</name></proto>
+ <param group="ColorF"><ptype>GLfloat</ptype> <name>value</name></param>
+ <alias name="glMinSampleShading"/>
+ </command>
+ <command>
+ <proto>void <name>glMinSampleShadingOES</name></proto>
+ <param group="ColorF"><ptype>GLfloat</ptype> <name>value</name></param>
+ <alias name="glMinSampleShading"/>
+ </command>
+ <command>
+ <proto>void <name>glMinmax</name></proto>
+ <param group="MinmaxTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="PixelInternalFormat"><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>sink</name></param>
+ <glx type="render" opcode="4111"/>
+ </command>
+ <command>
+ <proto>void <name>glMinmaxEXT</name></proto>
+ <param group="MinmaxTargetEXT"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="PixelInternalFormat"><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>sink</name></param>
+ <alias name="glMinmax"/>
+ <glx type="render" opcode="4111"/>
+ </command>
+ <command>
+ <proto>void <name>glMultMatrixd</name></proto>
+ <param len="16">const <ptype>GLdouble</ptype> *<name>m</name></param>
+ <glx type="render" opcode="181"/>
+ </command>
+ <command>
+ <proto>void <name>glMultMatrixf</name></proto>
+ <param len="16">const <ptype>GLfloat</ptype> *<name>m</name></param>
+ <glx type="render" opcode="180"/>
+ </command>
+ <command>
+ <proto>void <name>glMultMatrixx</name></proto>
+ <param len="16">const <ptype>GLfixed</ptype> *<name>m</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultMatrixxOES</name></proto>
+ <param len="16">const <ptype>GLfixed</ptype> *<name>m</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultTransposeMatrixd</name></proto>
+ <param len="16">const <ptype>GLdouble</ptype> *<name>m</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultTransposeMatrixdARB</name></proto>
+ <param len="16">const <ptype>GLdouble</ptype> *<name>m</name></param>
+ <alias name="glMultTransposeMatrixd"/>
+ </command>
+ <command>
+ <proto>void <name>glMultTransposeMatrixf</name></proto>
+ <param len="16">const <ptype>GLfloat</ptype> *<name>m</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultTransposeMatrixfARB</name></proto>
+ <param len="16">const <ptype>GLfloat</ptype> *<name>m</name></param>
+ <alias name="glMultTransposeMatrixf"/>
+ </command>
+ <command>
+ <proto>void <name>glMultTransposeMatrixxOES</name></proto>
+ <param len="16">const <ptype>GLfixed</ptype> *<name>m</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultiDrawArrays</name></proto>
+ <param group="PrimitiveType"><ptype>GLenum</ptype> <name>mode</name></param>
+ <param len="COMPSIZE(count)">const <ptype>GLint</ptype> *<name>first</name></param>
+ <param len="COMPSIZE(drawcount)">const <ptype>GLsizei</ptype> *<name>count</name></param>
+ <param><ptype>GLsizei</ptype> <name>drawcount</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultiDrawArraysEXT</name></proto>
+ <param group="PrimitiveType"><ptype>GLenum</ptype> <name>mode</name></param>
+ <param len="COMPSIZE(primcount)">const <ptype>GLint</ptype> *<name>first</name></param>
+ <param len="COMPSIZE(primcount)">const <ptype>GLsizei</ptype> *<name>count</name></param>
+ <param><ptype>GLsizei</ptype> <name>primcount</name></param>
+ <alias name="glMultiDrawArrays"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiDrawArraysIndirect</name></proto>
+ <param><ptype>GLenum</ptype> <name>mode</name></param>
+ <param len="COMPSIZE(drawcount,stride)">const void *<name>indirect</name></param>
+ <param><ptype>GLsizei</ptype> <name>drawcount</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultiDrawArraysIndirectAMD</name></proto>
+ <param><ptype>GLenum</ptype> <name>mode</name></param>
+ <param>const void *<name>indirect</name></param>
+ <param><ptype>GLsizei</ptype> <name>primcount</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ <alias name="glMultiDrawArraysIndirect"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiDrawArraysIndirectBindlessCountNV</name></proto>
+ <param><ptype>GLenum</ptype> <name>mode</name></param>
+ <param>const void *<name>indirect</name></param>
+ <param><ptype>GLsizei</ptype> <name>drawCount</name></param>
+ <param><ptype>GLsizei</ptype> <name>maxDrawCount</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ <param><ptype>GLint</ptype> <name>vertexBufferCount</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultiDrawArraysIndirectBindlessNV</name></proto>
+ <param><ptype>GLenum</ptype> <name>mode</name></param>
+ <param>const void *<name>indirect</name></param>
+ <param><ptype>GLsizei</ptype> <name>drawCount</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ <param><ptype>GLint</ptype> <name>vertexBufferCount</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultiDrawArraysIndirectCountARB</name></proto>
+ <param><ptype>GLenum</ptype> <name>mode</name></param>
+ <param><ptype>GLintptr</ptype> <name>indirect</name></param>
+ <param><ptype>GLintptr</ptype> <name>drawcount</name></param>
+ <param><ptype>GLsizei</ptype> <name>maxdrawcount</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultiDrawElementArrayAPPLE</name></proto>
+ <param group="PrimitiveType"><ptype>GLenum</ptype> <name>mode</name></param>
+ <param len="primcount">const <ptype>GLint</ptype> *<name>first</name></param>
+ <param len="primcount">const <ptype>GLsizei</ptype> *<name>count</name></param>
+ <param><ptype>GLsizei</ptype> <name>primcount</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultiDrawElements</name></proto>
+ <param group="PrimitiveType"><ptype>GLenum</ptype> <name>mode</name></param>
+ <param len="COMPSIZE(drawcount)">const <ptype>GLsizei</ptype> *<name>count</name></param>
+ <param group="DrawElementsType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(drawcount)">const void *const*<name>indices</name></param>
+ <param><ptype>GLsizei</ptype> <name>drawcount</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultiDrawElementsBaseVertex</name></proto>
+ <param><ptype>GLenum</ptype> <name>mode</name></param>
+ <param len="COMPSIZE(drawcount)">const <ptype>GLsizei</ptype> *<name>count</name></param>
+ <param group="DrawElementsType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(drawcount)">const void *const*<name>indices</name></param>
+ <param><ptype>GLsizei</ptype> <name>drawcount</name></param>
+ <param len="COMPSIZE(drawcount)">const <ptype>GLint</ptype> *<name>basevertex</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultiDrawElementsEXT</name></proto>
+ <param group="PrimitiveType"><ptype>GLenum</ptype> <name>mode</name></param>
+ <param len="COMPSIZE(primcount)">const <ptype>GLsizei</ptype> *<name>count</name></param>
+ <param group="DrawElementsType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(primcount)">const void *const*<name>indices</name></param>
+ <param><ptype>GLsizei</ptype> <name>primcount</name></param>
+ <alias name="glMultiDrawElements"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiDrawElementsIndirect</name></proto>
+ <param><ptype>GLenum</ptype> <name>mode</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(drawcount,stride)">const void *<name>indirect</name></param>
+ <param><ptype>GLsizei</ptype> <name>drawcount</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultiDrawElementsIndirectAMD</name></proto>
+ <param><ptype>GLenum</ptype> <name>mode</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param>const void *<name>indirect</name></param>
+ <param><ptype>GLsizei</ptype> <name>primcount</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ <alias name="glMultiDrawElementsIndirect"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiDrawElementsIndirectBindlessCountNV</name></proto>
+ <param><ptype>GLenum</ptype> <name>mode</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param>const void *<name>indirect</name></param>
+ <param><ptype>GLsizei</ptype> <name>drawCount</name></param>
+ <param><ptype>GLsizei</ptype> <name>maxDrawCount</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ <param><ptype>GLint</ptype> <name>vertexBufferCount</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultiDrawElementsIndirectBindlessNV</name></proto>
+ <param><ptype>GLenum</ptype> <name>mode</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param>const void *<name>indirect</name></param>
+ <param><ptype>GLsizei</ptype> <name>drawCount</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ <param><ptype>GLint</ptype> <name>vertexBufferCount</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultiDrawElementsIndirectCountARB</name></proto>
+ <param><ptype>GLenum</ptype> <name>mode</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLintptr</ptype> <name>indirect</name></param>
+ <param><ptype>GLintptr</ptype> <name>drawcount</name></param>
+ <param><ptype>GLsizei</ptype> <name>maxdrawcount</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultiDrawRangeElementArrayAPPLE</name></proto>
+ <param group="PrimitiveType"><ptype>GLenum</ptype> <name>mode</name></param>
+ <param><ptype>GLuint</ptype> <name>start</name></param>
+ <param><ptype>GLuint</ptype> <name>end</name></param>
+ <param len="primcount">const <ptype>GLint</ptype> *<name>first</name></param>
+ <param len="primcount">const <ptype>GLsizei</ptype> *<name>count</name></param>
+ <param><ptype>GLsizei</ptype> <name>primcount</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultiModeDrawArraysIBM</name></proto>
+ <param group="PrimitiveType" len="COMPSIZE(primcount)">const <ptype>GLenum</ptype> *<name>mode</name></param>
+ <param len="COMPSIZE(primcount)">const <ptype>GLint</ptype> *<name>first</name></param>
+ <param len="COMPSIZE(primcount)">const <ptype>GLsizei</ptype> *<name>count</name></param>
+ <param><ptype>GLsizei</ptype> <name>primcount</name></param>
+ <param><ptype>GLint</ptype> <name>modestride</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultiModeDrawElementsIBM</name></proto>
+ <param group="PrimitiveType" len="COMPSIZE(primcount)">const <ptype>GLenum</ptype> *<name>mode</name></param>
+ <param len="COMPSIZE(primcount)">const <ptype>GLsizei</ptype> *<name>count</name></param>
+ <param group="DrawElementsType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(primcount)">const void *const*<name>indices</name></param>
+ <param><ptype>GLsizei</ptype> <name>primcount</name></param>
+ <param><ptype>GLint</ptype> <name>modestride</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexBufferEXT</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>texunit</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="TypeEnum"><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord1bOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>texture</name></param>
+ <param><ptype>GLbyte</ptype> <name>s</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord1bvOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>texture</name></param>
+ <param len="1">const <ptype>GLbyte</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord1d</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>s</name></param>
+ <vecequiv name="glMultiTexCoord1dv"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord1dARB</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>s</name></param>
+ <vecequiv name="glMultiTexCoord1dv"/>
+ <alias name="glMultiTexCoord1d"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord1dv</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordD" len="1">const <ptype>GLdouble</ptype> *<name>v</name></param>
+ <glx type="render" opcode="198"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord1dvARB</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordD" len="1">const <ptype>GLdouble</ptype> *<name>v</name></param>
+ <alias name="glMultiTexCoord1dv"/>
+ <glx type="render" opcode="198"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord1f</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>s</name></param>
+ <vecequiv name="glMultiTexCoord1fv"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord1fARB</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>s</name></param>
+ <vecequiv name="glMultiTexCoord1fv"/>
+ <alias name="glMultiTexCoord1f"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord1fv</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordF" len="1">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ <glx type="render" opcode="199"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord1fvARB</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordF" len="1">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ <alias name="glMultiTexCoord1fv"/>
+ <glx type="render" opcode="199"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord1hNV</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="Half16NV"><ptype>GLhalfNV</ptype> <name>s</name></param>
+ <vecequiv name="glMultiTexCoord1hvNV"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord1hvNV</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="Half16NV" len="1">const <ptype>GLhalfNV</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4250"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord1i</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordI"><ptype>GLint</ptype> <name>s</name></param>
+ <vecequiv name="glMultiTexCoord1iv"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord1iARB</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordI"><ptype>GLint</ptype> <name>s</name></param>
+ <vecequiv name="glMultiTexCoord1iv"/>
+ <alias name="glMultiTexCoord1i"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord1iv</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordI" len="1">const <ptype>GLint</ptype> *<name>v</name></param>
+ <glx type="render" opcode="200"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord1ivARB</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordI" len="1">const <ptype>GLint</ptype> *<name>v</name></param>
+ <alias name="glMultiTexCoord1iv"/>
+ <glx type="render" opcode="200"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord1s</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>s</name></param>
+ <vecequiv name="glMultiTexCoord1sv"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord1sARB</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>s</name></param>
+ <vecequiv name="glMultiTexCoord1sv"/>
+ <alias name="glMultiTexCoord1s"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord1sv</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordS" len="1">const <ptype>GLshort</ptype> *<name>v</name></param>
+ <glx type="render" opcode="201"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord1svARB</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordS" len="1">const <ptype>GLshort</ptype> *<name>v</name></param>
+ <alias name="glMultiTexCoord1sv"/>
+ <glx type="render" opcode="201"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord1xOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>texture</name></param>
+ <param><ptype>GLfixed</ptype> <name>s</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord1xvOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>texture</name></param>
+ <param len="1">const <ptype>GLfixed</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord2bOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>texture</name></param>
+ <param><ptype>GLbyte</ptype> <name>s</name></param>
+ <param><ptype>GLbyte</ptype> <name>t</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord2bvOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>texture</name></param>
+ <param len="2">const <ptype>GLbyte</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord2d</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>s</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>t</name></param>
+ <vecequiv name="glMultiTexCoord2dv"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord2dARB</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>s</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>t</name></param>
+ <vecequiv name="glMultiTexCoord2dv"/>
+ <alias name="glMultiTexCoord2d"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord2dv</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordD" len="2">const <ptype>GLdouble</ptype> *<name>v</name></param>
+ <glx type="render" opcode="202"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord2dvARB</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordD" len="2">const <ptype>GLdouble</ptype> *<name>v</name></param>
+ <alias name="glMultiTexCoord2dv"/>
+ <glx type="render" opcode="202"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord2f</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>s</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>t</name></param>
+ <vecequiv name="glMultiTexCoord2fv"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord2fARB</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>s</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>t</name></param>
+ <vecequiv name="glMultiTexCoord2fv"/>
+ <alias name="glMultiTexCoord2f"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord2fv</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordF" len="2">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ <glx type="render" opcode="203"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord2fvARB</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordF" len="2">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ <alias name="glMultiTexCoord2fv"/>
+ <glx type="render" opcode="203"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord2hNV</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="Half16NV"><ptype>GLhalfNV</ptype> <name>s</name></param>
+ <param group="Half16NV"><ptype>GLhalfNV</ptype> <name>t</name></param>
+ <vecequiv name="glMultiTexCoord2hvNV"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord2hvNV</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="Half16NV" len="2">const <ptype>GLhalfNV</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4251"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord2i</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordI"><ptype>GLint</ptype> <name>s</name></param>
+ <param group="CoordI"><ptype>GLint</ptype> <name>t</name></param>
+ <vecequiv name="glMultiTexCoord2iv"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord2iARB</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordI"><ptype>GLint</ptype> <name>s</name></param>
+ <param group="CoordI"><ptype>GLint</ptype> <name>t</name></param>
+ <vecequiv name="glMultiTexCoord2iv"/>
+ <alias name="glMultiTexCoord2i"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord2iv</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordI" len="2">const <ptype>GLint</ptype> *<name>v</name></param>
+ <glx type="render" opcode="204"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord2ivARB</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordI" len="2">const <ptype>GLint</ptype> *<name>v</name></param>
+ <alias name="glMultiTexCoord2iv"/>
+ <glx type="render" opcode="204"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord2s</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>s</name></param>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>t</name></param>
+ <vecequiv name="glMultiTexCoord2sv"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord2sARB</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>s</name></param>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>t</name></param>
+ <vecequiv name="glMultiTexCoord2sv"/>
+ <alias name="glMultiTexCoord2s"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord2sv</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordS" len="2">const <ptype>GLshort</ptype> *<name>v</name></param>
+ <glx type="render" opcode="205"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord2svARB</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordS" len="2">const <ptype>GLshort</ptype> *<name>v</name></param>
+ <alias name="glMultiTexCoord2sv"/>
+ <glx type="render" opcode="205"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord2xOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>texture</name></param>
+ <param><ptype>GLfixed</ptype> <name>s</name></param>
+ <param><ptype>GLfixed</ptype> <name>t</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord2xvOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>texture</name></param>
+ <param len="2">const <ptype>GLfixed</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord3bOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>texture</name></param>
+ <param><ptype>GLbyte</ptype> <name>s</name></param>
+ <param><ptype>GLbyte</ptype> <name>t</name></param>
+ <param><ptype>GLbyte</ptype> <name>r</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord3bvOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>texture</name></param>
+ <param len="3">const <ptype>GLbyte</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord3d</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>s</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>t</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>r</name></param>
+ <vecequiv name="glMultiTexCoord3dv"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord3dARB</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>s</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>t</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>r</name></param>
+ <vecequiv name="glMultiTexCoord3dv"/>
+ <alias name="glMultiTexCoord3d"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord3dv</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordD" len="3">const <ptype>GLdouble</ptype> *<name>v</name></param>
+ <glx type="render" opcode="206"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord3dvARB</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordD" len="3">const <ptype>GLdouble</ptype> *<name>v</name></param>
+ <alias name="glMultiTexCoord3dv"/>
+ <glx type="render" opcode="206"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord3f</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>s</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>t</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>r</name></param>
+ <vecequiv name="glMultiTexCoord3fv"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord3fARB</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>s</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>t</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>r</name></param>
+ <vecequiv name="glMultiTexCoord3fv"/>
+ <alias name="glMultiTexCoord3f"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord3fv</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordF" len="3">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ <glx type="render" opcode="207"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord3fvARB</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordF" len="3">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ <alias name="glMultiTexCoord3fv"/>
+ <glx type="render" opcode="207"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord3hNV</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="Half16NV"><ptype>GLhalfNV</ptype> <name>s</name></param>
+ <param group="Half16NV"><ptype>GLhalfNV</ptype> <name>t</name></param>
+ <param group="Half16NV"><ptype>GLhalfNV</ptype> <name>r</name></param>
+ <vecequiv name="glMultiTexCoord3hvNV"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord3hvNV</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="Half16NV" len="3">const <ptype>GLhalfNV</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4252"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord3i</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordI"><ptype>GLint</ptype> <name>s</name></param>
+ <param group="CoordI"><ptype>GLint</ptype> <name>t</name></param>
+ <param group="CoordI"><ptype>GLint</ptype> <name>r</name></param>
+ <vecequiv name="glMultiTexCoord3iv"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord3iARB</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordI"><ptype>GLint</ptype> <name>s</name></param>
+ <param group="CoordI"><ptype>GLint</ptype> <name>t</name></param>
+ <param group="CoordI"><ptype>GLint</ptype> <name>r</name></param>
+ <vecequiv name="glMultiTexCoord3iv"/>
+ <alias name="glMultiTexCoord3i"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord3iv</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordI" len="3">const <ptype>GLint</ptype> *<name>v</name></param>
+ <glx type="render" opcode="208"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord3ivARB</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordI" len="3">const <ptype>GLint</ptype> *<name>v</name></param>
+ <alias name="glMultiTexCoord3iv"/>
+ <glx type="render" opcode="208"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord3s</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>s</name></param>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>t</name></param>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>r</name></param>
+ <vecequiv name="glMultiTexCoord3sv"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord3sARB</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>s</name></param>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>t</name></param>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>r</name></param>
+ <vecequiv name="glMultiTexCoord3sv"/>
+ <alias name="glMultiTexCoord3s"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord3sv</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordS" len="3">const <ptype>GLshort</ptype> *<name>v</name></param>
+ <glx type="render" opcode="209"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord3svARB</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordS" len="3">const <ptype>GLshort</ptype> *<name>v</name></param>
+ <alias name="glMultiTexCoord3sv"/>
+ <glx type="render" opcode="209"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord3xOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>texture</name></param>
+ <param><ptype>GLfixed</ptype> <name>s</name></param>
+ <param><ptype>GLfixed</ptype> <name>t</name></param>
+ <param><ptype>GLfixed</ptype> <name>r</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord3xvOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>texture</name></param>
+ <param len="3">const <ptype>GLfixed</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord4bOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>texture</name></param>
+ <param><ptype>GLbyte</ptype> <name>s</name></param>
+ <param><ptype>GLbyte</ptype> <name>t</name></param>
+ <param><ptype>GLbyte</ptype> <name>r</name></param>
+ <param><ptype>GLbyte</ptype> <name>q</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord4bvOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>texture</name></param>
+ <param len="4">const <ptype>GLbyte</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord4d</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>s</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>t</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>r</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>q</name></param>
+ <vecequiv name="glMultiTexCoord4dv"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord4dARB</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>s</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>t</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>r</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>q</name></param>
+ <vecequiv name="glMultiTexCoord4dv"/>
+ <alias name="glMultiTexCoord4d"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord4dv</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordD" len="4">const <ptype>GLdouble</ptype> *<name>v</name></param>
+ <glx type="render" opcode="210"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord4dvARB</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordD" len="4">const <ptype>GLdouble</ptype> *<name>v</name></param>
+ <alias name="glMultiTexCoord4dv"/>
+ <glx type="render" opcode="210"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord4f</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>s</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>t</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>r</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>q</name></param>
+ <vecequiv name="glMultiTexCoord4fv"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord4fARB</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>s</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>t</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>r</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>q</name></param>
+ <vecequiv name="glMultiTexCoord4fv"/>
+ <alias name="glMultiTexCoord4f"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord4fv</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordF" len="4">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ <glx type="render" opcode="211"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord4fvARB</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordF" len="4">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ <alias name="glMultiTexCoord4fv"/>
+ <glx type="render" opcode="211"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord4hNV</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="Half16NV"><ptype>GLhalfNV</ptype> <name>s</name></param>
+ <param group="Half16NV"><ptype>GLhalfNV</ptype> <name>t</name></param>
+ <param group="Half16NV"><ptype>GLhalfNV</ptype> <name>r</name></param>
+ <param group="Half16NV"><ptype>GLhalfNV</ptype> <name>q</name></param>
+ <vecequiv name="glMultiTexCoord4hvNV"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord4hvNV</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="Half16NV" len="4">const <ptype>GLhalfNV</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4253"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord4i</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordI"><ptype>GLint</ptype> <name>s</name></param>
+ <param group="CoordI"><ptype>GLint</ptype> <name>t</name></param>
+ <param group="CoordI"><ptype>GLint</ptype> <name>r</name></param>
+ <param group="CoordI"><ptype>GLint</ptype> <name>q</name></param>
+ <vecequiv name="glMultiTexCoord4iv"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord4iARB</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordI"><ptype>GLint</ptype> <name>s</name></param>
+ <param group="CoordI"><ptype>GLint</ptype> <name>t</name></param>
+ <param group="CoordI"><ptype>GLint</ptype> <name>r</name></param>
+ <param group="CoordI"><ptype>GLint</ptype> <name>q</name></param>
+ <vecequiv name="glMultiTexCoord4iv"/>
+ <alias name="glMultiTexCoord4i"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord4iv</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordI" len="4">const <ptype>GLint</ptype> *<name>v</name></param>
+ <glx type="render" opcode="212"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord4ivARB</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordI" len="4">const <ptype>GLint</ptype> *<name>v</name></param>
+ <alias name="glMultiTexCoord4iv"/>
+ <glx type="render" opcode="212"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord4s</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>s</name></param>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>t</name></param>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>r</name></param>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>q</name></param>
+ <vecequiv name="glMultiTexCoord4sv"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord4sARB</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>s</name></param>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>t</name></param>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>r</name></param>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>q</name></param>
+ <vecequiv name="glMultiTexCoord4sv"/>
+ <alias name="glMultiTexCoord4s"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord4sv</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordS" len="4">const <ptype>GLshort</ptype> *<name>v</name></param>
+ <glx type="render" opcode="213"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord4svARB</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CoordS" len="4">const <ptype>GLshort</ptype> *<name>v</name></param>
+ <alias name="glMultiTexCoord4sv"/>
+ <glx type="render" opcode="213"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord4x</name></proto>
+ <param><ptype>GLenum</ptype> <name>texture</name></param>
+ <param><ptype>GLfixed</ptype> <name>s</name></param>
+ <param><ptype>GLfixed</ptype> <name>t</name></param>
+ <param><ptype>GLfixed</ptype> <name>r</name></param>
+ <param><ptype>GLfixed</ptype> <name>q</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord4xOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>texture</name></param>
+ <param><ptype>GLfixed</ptype> <name>s</name></param>
+ <param><ptype>GLfixed</ptype> <name>t</name></param>
+ <param><ptype>GLfixed</ptype> <name>r</name></param>
+ <param><ptype>GLfixed</ptype> <name>q</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoord4xvOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>texture</name></param>
+ <param len="4">const <ptype>GLfixed</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoordP1ui</name></proto>
+ <param><ptype>GLenum</ptype> <name>texture</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLuint</ptype> <name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoordP1uiv</name></proto>
+ <param><ptype>GLenum</ptype> <name>texture</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="1">const <ptype>GLuint</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoordP2ui</name></proto>
+ <param><ptype>GLenum</ptype> <name>texture</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLuint</ptype> <name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoordP2uiv</name></proto>
+ <param><ptype>GLenum</ptype> <name>texture</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="1">const <ptype>GLuint</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoordP3ui</name></proto>
+ <param><ptype>GLenum</ptype> <name>texture</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLuint</ptype> <name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoordP3uiv</name></proto>
+ <param><ptype>GLenum</ptype> <name>texture</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="1">const <ptype>GLuint</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoordP4ui</name></proto>
+ <param><ptype>GLenum</ptype> <name>texture</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLuint</ptype> <name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoordP4uiv</name></proto>
+ <param><ptype>GLenum</ptype> <name>texture</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="1">const <ptype>GLuint</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexCoordPointerEXT</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>texunit</name></param>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param group="TexCoordPointerType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ <param len="COMPSIZE(size,type,stride)">const void *<name>pointer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexEnvfEXT</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>texunit</name></param>
+ <param group="TextureEnvTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="TextureEnvParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedFloat32"><ptype>GLfloat</ptype> <name>param</name></param>
+ <vecequiv name="glMultiTexEnvfvEXT"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexEnvfvEXT</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>texunit</name></param>
+ <param group="TextureEnvTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="TextureEnvParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedFloat32" len="COMPSIZE(pname)">const <ptype>GLfloat</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexEnviEXT</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>texunit</name></param>
+ <param group="TextureEnvTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="TextureEnvParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>param</name></param>
+ <vecequiv name="glMultiTexEnvivEXT"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexEnvivEXT</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>texunit</name></param>
+ <param group="TextureEnvTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="TextureEnvParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedInt32" len="COMPSIZE(pname)">const <ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexGendEXT</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>texunit</name></param>
+ <param group="TextureCoordName"><ptype>GLenum</ptype> <name>coord</name></param>
+ <param group="TextureGenParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLdouble</ptype> <name>param</name></param>
+ <vecequiv name="glMultiTexGendvEXT"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexGendvEXT</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>texunit</name></param>
+ <param group="TextureCoordName"><ptype>GLenum</ptype> <name>coord</name></param>
+ <param group="TextureGenParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)">const <ptype>GLdouble</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexGenfEXT</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>texunit</name></param>
+ <param group="TextureCoordName"><ptype>GLenum</ptype> <name>coord</name></param>
+ <param group="TextureGenParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedFloat32"><ptype>GLfloat</ptype> <name>param</name></param>
+ <vecequiv name="glMultiTexGenfvEXT"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexGenfvEXT</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>texunit</name></param>
+ <param group="TextureCoordName"><ptype>GLenum</ptype> <name>coord</name></param>
+ <param group="TextureGenParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedFloat32" len="COMPSIZE(pname)">const <ptype>GLfloat</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexGeniEXT</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>texunit</name></param>
+ <param group="TextureCoordName"><ptype>GLenum</ptype> <name>coord</name></param>
+ <param group="TextureGenParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>param</name></param>
+ <vecequiv name="glMultiTexGenivEXT"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexGenivEXT</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>texunit</name></param>
+ <param group="TextureCoordName"><ptype>GLenum</ptype> <name>coord</name></param>
+ <param group="TextureGenParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedInt32" len="COMPSIZE(pname)">const <ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexImage1DEXT</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>texunit</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="TextureComponentCount"><ptype>GLint</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>border</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param group="PixelType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(format,type,width)">const void *<name>pixels</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexImage2DEXT</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>texunit</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="TextureComponentCount"><ptype>GLint</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>border</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param group="PixelType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(format,type,width,height)">const void *<name>pixels</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexImage3DEXT</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>texunit</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="TextureComponentCount"><ptype>GLint</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param><ptype>GLsizei</ptype> <name>depth</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>border</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param group="PixelType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(format,type,width,height,depth)">const void *<name>pixels</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexParameterIivEXT</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>texunit</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="TextureParameterName"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedInt32" len="COMPSIZE(pname)">const <ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexParameterIuivEXT</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>texunit</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="TextureParameterName"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)">const <ptype>GLuint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexParameterfEXT</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>texunit</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="TextureParameterName"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedFloat32"><ptype>GLfloat</ptype> <name>param</name></param>
+ <vecequiv name="glMultiTexParameterfvEXT"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexParameterfvEXT</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>texunit</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="TextureParameterName"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedFloat32" len="COMPSIZE(pname)">const <ptype>GLfloat</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexParameteriEXT</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>texunit</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="TextureParameterName"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>param</name></param>
+ <vecequiv name="glMultiTexParameterivEXT"/>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexParameterivEXT</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>texunit</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="TextureParameterName"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedInt32" len="COMPSIZE(pname)">const <ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexRenderbufferEXT</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>texunit</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>renderbuffer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexSubImage1DEXT</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>texunit</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>xoffset</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param group="PixelType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(format,type,width)">const void *<name>pixels</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexSubImage2DEXT</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>texunit</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>xoffset</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>yoffset</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param group="PixelType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(format,type,width,height)">const void *<name>pixels</name></param>
+ </command>
+ <command>
+ <proto>void <name>glMultiTexSubImage3DEXT</name></proto>
+ <param group="TextureUnit"><ptype>GLenum</ptype> <name>texunit</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>xoffset</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>yoffset</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>zoffset</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param><ptype>GLsizei</ptype> <name>depth</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param group="PixelType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(format,type,width,height,depth)">const void *<name>pixels</name></param>
+ </command>
+ <command>
+ <proto>void <name>glNamedBufferData</name></proto>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <param><ptype>GLsizei</ptype> <name>size</name></param>
+ <param>const void *<name>data</name></param>
+ <param><ptype>GLenum</ptype> <name>usage</name></param>
+ </command>
+ <command>
+ <proto>void <name>glNamedBufferDataEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <param><ptype>GLsizeiptr</ptype> <name>size</name></param>
+ <param len="COMPSIZE(size)">const void *<name>data</name></param>
+ <param group="VertexBufferObjectUsage"><ptype>GLenum</ptype> <name>usage</name></param>
+ </command>
+ <command>
+ <proto>void <name>glNamedBufferPageCommitmentARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <param><ptype>GLintptr</ptype> <name>offset</name></param>
+ <param><ptype>GLsizei</ptype> <name>size</name></param>
+ <param><ptype>GLboolean</ptype> <name>commit</name></param>
+ </command>
+ <command>
+ <proto>void <name>glNamedBufferPageCommitmentEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <param><ptype>GLintptr</ptype> <name>offset</name></param>
+ <param><ptype>GLsizei</ptype> <name>size</name></param>
+ <param><ptype>GLboolean</ptype> <name>commit</name></param>
+ </command>
+ <command>
+ <proto>void <name>glNamedBufferStorage</name></proto>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <param><ptype>GLsizei</ptype> <name>size</name></param>
+ <param>const void *<name>data</name></param>
+ <param><ptype>GLbitfield</ptype> <name>flags</name></param>
+ </command>
+ <command>
+ <proto>void <name>glNamedBufferStorageEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <param><ptype>GLsizeiptr</ptype> <name>size</name></param>
+ <param len="size">const void *<name>data</name></param>
+ <param><ptype>GLbitfield</ptype> <name>flags</name></param>
+ </command>
+ <command>
+ <proto>void <name>glNamedBufferSubData</name></proto>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <param><ptype>GLintptr</ptype> <name>offset</name></param>
+ <param><ptype>GLsizei</ptype> <name>size</name></param>
+ <param>const void *<name>data</name></param>
+ </command>
+ <command>
+ <proto>void <name>glNamedBufferSubDataEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <param><ptype>GLintptr</ptype> <name>offset</name></param>
+ <param><ptype>GLsizeiptr</ptype> <name>size</name></param>
+ <param len="COMPSIZE(size)">const void *<name>data</name></param>
+ </command>
+ <command>
+ <proto>void <name>glNamedCopyBufferSubDataEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>readBuffer</name></param>
+ <param><ptype>GLuint</ptype> <name>writeBuffer</name></param>
+ <param><ptype>GLintptr</ptype> <name>readOffset</name></param>
+ <param><ptype>GLintptr</ptype> <name>writeOffset</name></param>
+ <param><ptype>GLsizeiptr</ptype> <name>size</name></param>
+ </command>
+ <command>
+ <proto>void <name>glNamedFramebufferDrawBuffer</name></proto>
+ <param><ptype>GLuint</ptype> <name>framebuffer</name></param>
+ <param><ptype>GLenum</ptype> <name>buf</name></param>
+ </command>
+ <command>
+ <proto>void <name>glNamedFramebufferDrawBuffers</name></proto>
+ <param><ptype>GLuint</ptype> <name>framebuffer</name></param>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param>const <ptype>GLenum</ptype> *<name>bufs</name></param>
+ </command>
+ <command>
+ <proto>void <name>glNamedFramebufferParameteri</name></proto>
+ <param><ptype>GLuint</ptype> <name>framebuffer</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLint</ptype> <name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glNamedFramebufferParameteriEXT</name></proto>
+ <param group="Framebuffer"><ptype>GLuint</ptype> <name>framebuffer</name></param>
+ <param group="FramebufferParameterName"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLint</ptype> <name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glNamedFramebufferReadBuffer</name></proto>
+ <param><ptype>GLuint</ptype> <name>framebuffer</name></param>
+ <param><ptype>GLenum</ptype> <name>src</name></param>
+ </command>
+ <command>
+ <proto>void <name>glNamedFramebufferRenderbuffer</name></proto>
+ <param><ptype>GLuint</ptype> <name>framebuffer</name></param>
+ <param><ptype>GLenum</ptype> <name>attachment</name></param>
+ <param><ptype>GLenum</ptype> <name>renderbuffertarget</name></param>
+ <param><ptype>GLuint</ptype> <name>renderbuffer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glNamedFramebufferRenderbufferEXT</name></proto>
+ <param group="Framebuffer"><ptype>GLuint</ptype> <name>framebuffer</name></param>
+ <param group="FramebufferAttachment"><ptype>GLenum</ptype> <name>attachment</name></param>
+ <param group="RenderbufferTarget"><ptype>GLenum</ptype> <name>renderbuffertarget</name></param>
+ <param group="Renderbuffer"><ptype>GLuint</ptype> <name>renderbuffer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glNamedFramebufferTexture</name></proto>
+ <param><ptype>GLuint</ptype> <name>framebuffer</name></param>
+ <param><ptype>GLenum</ptype> <name>attachment</name></param>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLint</ptype> <name>level</name></param>
+ </command>
+ <command>
+ <proto>void <name>glNamedFramebufferTexture1DEXT</name></proto>
+ <param group="Framebuffer"><ptype>GLuint</ptype> <name>framebuffer</name></param>
+ <param group="FramebufferAttachment"><ptype>GLenum</ptype> <name>attachment</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>textarget</name></param>
+ <param group="Texture"><ptype>GLuint</ptype> <name>texture</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ </command>
+ <command>
+ <proto>void <name>glNamedFramebufferTexture2DEXT</name></proto>
+ <param group="Framebuffer"><ptype>GLuint</ptype> <name>framebuffer</name></param>
+ <param group="FramebufferAttachment"><ptype>GLenum</ptype> <name>attachment</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>textarget</name></param>
+ <param group="Texture"><ptype>GLuint</ptype> <name>texture</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ </command>
+ <command>
+ <proto>void <name>glNamedFramebufferTexture3DEXT</name></proto>
+ <param group="Framebuffer"><ptype>GLuint</ptype> <name>framebuffer</name></param>
+ <param group="FramebufferAttachment"><ptype>GLenum</ptype> <name>attachment</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>textarget</name></param>
+ <param group="Texture"><ptype>GLuint</ptype> <name>texture</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>zoffset</name></param>
+ </command>
+ <command>
+ <proto>void <name>glNamedFramebufferTextureEXT</name></proto>
+ <param group="Framebuffer"><ptype>GLuint</ptype> <name>framebuffer</name></param>
+ <param group="FramebufferAttachment"><ptype>GLenum</ptype> <name>attachment</name></param>
+ <param group="Texture"><ptype>GLuint</ptype> <name>texture</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ </command>
+ <command>
+ <proto>void <name>glNamedFramebufferTextureFaceEXT</name></proto>
+ <param group="Framebuffer"><ptype>GLuint</ptype> <name>framebuffer</name></param>
+ <param group="FramebufferAttachment"><ptype>GLenum</ptype> <name>attachment</name></param>
+ <param group="Texture"><ptype>GLuint</ptype> <name>texture</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>face</name></param>
+ </command>
+ <command>
+ <proto>void <name>glNamedFramebufferTextureLayer</name></proto>
+ <param><ptype>GLuint</ptype> <name>framebuffer</name></param>
+ <param><ptype>GLenum</ptype> <name>attachment</name></param>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLint</ptype> <name>level</name></param>
+ <param><ptype>GLint</ptype> <name>layer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glNamedFramebufferTextureLayerEXT</name></proto>
+ <param group="Framebuffer"><ptype>GLuint</ptype> <name>framebuffer</name></param>
+ <param group="FramebufferAttachment"><ptype>GLenum</ptype> <name>attachment</name></param>
+ <param group="Texture"><ptype>GLuint</ptype> <name>texture</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>layer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glNamedProgramLocalParameter4dEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param group="ProgramTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLdouble</ptype> <name>x</name></param>
+ <param><ptype>GLdouble</ptype> <name>y</name></param>
+ <param><ptype>GLdouble</ptype> <name>z</name></param>
+ <param><ptype>GLdouble</ptype> <name>w</name></param>
+ <vecequiv name="glNamedProgramLocalParameter4dvEXT"/>
+ </command>
+ <command>
+ <proto>void <name>glNamedProgramLocalParameter4dvEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param group="ProgramTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLdouble</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glNamedProgramLocalParameter4fEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param group="ProgramTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLfloat</ptype> <name>x</name></param>
+ <param><ptype>GLfloat</ptype> <name>y</name></param>
+ <param><ptype>GLfloat</ptype> <name>z</name></param>
+ <param><ptype>GLfloat</ptype> <name>w</name></param>
+ <vecequiv name="glNamedProgramLocalParameter4fvEXT"/>
+ </command>
+ <command>
+ <proto>void <name>glNamedProgramLocalParameter4fvEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param group="ProgramTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLfloat</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glNamedProgramLocalParameterI4iEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param group="ProgramTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLint</ptype> <name>x</name></param>
+ <param><ptype>GLint</ptype> <name>y</name></param>
+ <param><ptype>GLint</ptype> <name>z</name></param>
+ <param><ptype>GLint</ptype> <name>w</name></param>
+ <vecequiv name="glNamedProgramLocalParameterI4ivEXT"/>
+ </command>
+ <command>
+ <proto>void <name>glNamedProgramLocalParameterI4ivEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param group="ProgramTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glNamedProgramLocalParameterI4uiEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param group="ProgramTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLuint</ptype> <name>x</name></param>
+ <param><ptype>GLuint</ptype> <name>y</name></param>
+ <param><ptype>GLuint</ptype> <name>z</name></param>
+ <param><ptype>GLuint</ptype> <name>w</name></param>
+ <vecequiv name="glNamedProgramLocalParameterI4uivEXT"/>
+ </command>
+ <command>
+ <proto>void <name>glNamedProgramLocalParameterI4uivEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param group="ProgramTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLuint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glNamedProgramLocalParameters4fvEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param group="ProgramTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*4">const <ptype>GLfloat</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glNamedProgramLocalParametersI4ivEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param group="ProgramTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*4">const <ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glNamedProgramLocalParametersI4uivEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param group="ProgramTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*4">const <ptype>GLuint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glNamedProgramStringEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param group="ProgramTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="ProgramFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param><ptype>GLsizei</ptype> <name>len</name></param>
+ <param len="len">const void *<name>string</name></param>
+ </command>
+ <command>
+ <proto>void <name>glNamedRenderbufferStorage</name></proto>
+ <param><ptype>GLuint</ptype> <name>renderbuffer</name></param>
+ <param><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ </command>
+ <command>
+ <proto>void <name>glNamedRenderbufferStorageEXT</name></proto>
+ <param group="Renderbuffer"><ptype>GLuint</ptype> <name>renderbuffer</name></param>
+ <param group="PixelInternalFormat"><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ </command>
+ <command>
+ <proto>void <name>glNamedRenderbufferStorageMultisample</name></proto>
+ <param><ptype>GLuint</ptype> <name>renderbuffer</name></param>
+ <param><ptype>GLsizei</ptype> <name>samples</name></param>
+ <param><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ </command>
+ <command>
+ <proto>void <name>glNamedRenderbufferStorageMultisampleCoverageEXT</name></proto>
+ <param group="Renderbuffer"><ptype>GLuint</ptype> <name>renderbuffer</name></param>
+ <param><ptype>GLsizei</ptype> <name>coverageSamples</name></param>
+ <param><ptype>GLsizei</ptype> <name>colorSamples</name></param>
+ <param group="PixelInternalFormat"><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ </command>
+ <command>
+ <proto>void <name>glNamedRenderbufferStorageMultisampleEXT</name></proto>
+ <param group="Renderbuffer"><ptype>GLuint</ptype> <name>renderbuffer</name></param>
+ <param><ptype>GLsizei</ptype> <name>samples</name></param>
+ <param group="PixelInternalFormat"><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ </command>
+ <command>
+ <proto>void <name>glNamedStringARB</name></proto>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLint</ptype> <name>namelen</name></param>
+ <param len="namelen">const <ptype>GLchar</ptype> *<name>name</name></param>
+ <param><ptype>GLint</ptype> <name>stringlen</name></param>
+ <param len="stringlen">const <ptype>GLchar</ptype> *<name>string</name></param>
+ </command>
+ <command>
+ <proto>void <name>glNewList</name></proto>
+ <param group="List"><ptype>GLuint</ptype> <name>list</name></param>
+ <param group="ListMode"><ptype>GLenum</ptype> <name>mode</name></param>
+ <glx type="single" opcode="101"/>
+ </command>
+ <command>
+ <proto><ptype>GLuint</ptype> <name>glNewObjectBufferATI</name></proto>
+ <param><ptype>GLsizei</ptype> <name>size</name></param>
+ <param len="size">const void *<name>pointer</name></param>
+ <param group="ArrayObjectUsageATI"><ptype>GLenum</ptype> <name>usage</name></param>
+ </command>
+ <command>
+ <proto>void <name>glNormal3b</name></proto>
+ <param><ptype>GLbyte</ptype> <name>nx</name></param>
+ <param><ptype>GLbyte</ptype> <name>ny</name></param>
+ <param><ptype>GLbyte</ptype> <name>nz</name></param>
+ <vecequiv name="glNormal3bv"/>
+ </command>
+ <command>
+ <proto>void <name>glNormal3bv</name></proto>
+ <param len="3">const <ptype>GLbyte</ptype> *<name>v</name></param>
+ <glx type="render" opcode="28"/>
+ </command>
+ <command>
+ <proto>void <name>glNormal3d</name></proto>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>nx</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>ny</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>nz</name></param>
+ <vecequiv name="glNormal3dv"/>
+ </command>
+ <command>
+ <proto>void <name>glNormal3dv</name></proto>
+ <param group="CoordD" len="3">const <ptype>GLdouble</ptype> *<name>v</name></param>
+ <glx type="render" opcode="29"/>
+ </command>
+ <command>
+ <proto>void <name>glNormal3f</name></proto>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>nx</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>ny</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>nz</name></param>
+ <vecequiv name="glNormal3fv"/>
+ </command>
+ <command>
+ <proto>void <name>glNormal3fVertex3fSUN</name></proto>
+ <param><ptype>GLfloat</ptype> <name>nx</name></param>
+ <param><ptype>GLfloat</ptype> <name>ny</name></param>
+ <param><ptype>GLfloat</ptype> <name>nz</name></param>
+ <param><ptype>GLfloat</ptype> <name>x</name></param>
+ <param><ptype>GLfloat</ptype> <name>y</name></param>
+ <param><ptype>GLfloat</ptype> <name>z</name></param>
+ </command>
+ <command>
+ <proto>void <name>glNormal3fVertex3fvSUN</name></proto>
+ <param len="3">const <ptype>GLfloat</ptype> *<name>n</name></param>
+ <param len="3">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glNormal3fv</name></proto>
+ <param group="CoordF" len="3">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ <glx type="render" opcode="30"/>
+ </command>
+ <command>
+ <proto>void <name>glNormal3hNV</name></proto>
+ <param group="Half16NV"><ptype>GLhalfNV</ptype> <name>nx</name></param>
+ <param group="Half16NV"><ptype>GLhalfNV</ptype> <name>ny</name></param>
+ <param group="Half16NV"><ptype>GLhalfNV</ptype> <name>nz</name></param>
+ <vecequiv name="glNormal3hvNV"/>
+ </command>
+ <command>
+ <proto>void <name>glNormal3hvNV</name></proto>
+ <param group="Half16NV" len="3">const <ptype>GLhalfNV</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4243"/>
+ </command>
+ <command>
+ <proto>void <name>glNormal3i</name></proto>
+ <param><ptype>GLint</ptype> <name>nx</name></param>
+ <param><ptype>GLint</ptype> <name>ny</name></param>
+ <param><ptype>GLint</ptype> <name>nz</name></param>
+ <vecequiv name="glNormal3iv"/>
+ </command>
+ <command>
+ <proto>void <name>glNormal3iv</name></proto>
+ <param len="3">const <ptype>GLint</ptype> *<name>v</name></param>
+ <glx type="render" opcode="31"/>
+ </command>
+ <command>
+ <proto>void <name>glNormal3s</name></proto>
+ <param><ptype>GLshort</ptype> <name>nx</name></param>
+ <param><ptype>GLshort</ptype> <name>ny</name></param>
+ <param><ptype>GLshort</ptype> <name>nz</name></param>
+ <vecequiv name="glNormal3sv"/>
+ </command>
+ <command>
+ <proto>void <name>glNormal3sv</name></proto>
+ <param len="3">const <ptype>GLshort</ptype> *<name>v</name></param>
+ <glx type="render" opcode="32"/>
+ </command>
+ <command>
+ <proto>void <name>glNormal3x</name></proto>
+ <param><ptype>GLfixed</ptype> <name>nx</name></param>
+ <param><ptype>GLfixed</ptype> <name>ny</name></param>
+ <param><ptype>GLfixed</ptype> <name>nz</name></param>
+ </command>
+ <command>
+ <proto>void <name>glNormal3xOES</name></proto>
+ <param><ptype>GLfixed</ptype> <name>nx</name></param>
+ <param><ptype>GLfixed</ptype> <name>ny</name></param>
+ <param><ptype>GLfixed</ptype> <name>nz</name></param>
+ </command>
+ <command>
+ <proto>void <name>glNormal3xvOES</name></proto>
+ <param len="3">const <ptype>GLfixed</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glNormalFormatNV</name></proto>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ </command>
+ <command>
+ <proto>void <name>glNormalP3ui</name></proto>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLuint</ptype> <name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glNormalP3uiv</name></proto>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="1">const <ptype>GLuint</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glNormalPointer</name></proto>
+ <param group="NormalPointerType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ <param len="COMPSIZE(type,stride)">const void *<name>pointer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glNormalPointerEXT</name></proto>
+ <param group="NormalPointerType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="COMPSIZE(type,stride,count)">const void *<name>pointer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glNormalPointerListIBM</name></proto>
+ <param group="NormalPointerType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLint</ptype> <name>stride</name></param>
+ <param len="COMPSIZE(type,stride)">const void **<name>pointer</name></param>
+ <param><ptype>GLint</ptype> <name>ptrstride</name></param>
+ </command>
+ <command>
+ <proto>void <name>glNormalPointervINTEL</name></proto>
+ <param group="NormalPointerType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="4">const void **<name>pointer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glNormalStream3bATI</name></proto>
+ <param group="VertexStreamATI"><ptype>GLenum</ptype> <name>stream</name></param>
+ <param><ptype>GLbyte</ptype> <name>nx</name></param>
+ <param><ptype>GLbyte</ptype> <name>ny</name></param>
+ <param><ptype>GLbyte</ptype> <name>nz</name></param>
+ </command>
+ <command>
+ <proto>void <name>glNormalStream3bvATI</name></proto>
+ <param group="VertexStreamATI"><ptype>GLenum</ptype> <name>stream</name></param>
+ <param len="3">const <ptype>GLbyte</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glNormalStream3dATI</name></proto>
+ <param group="VertexStreamATI"><ptype>GLenum</ptype> <name>stream</name></param>
+ <param><ptype>GLdouble</ptype> <name>nx</name></param>
+ <param><ptype>GLdouble</ptype> <name>ny</name></param>
+ <param><ptype>GLdouble</ptype> <name>nz</name></param>
+ </command>
+ <command>
+ <proto>void <name>glNormalStream3dvATI</name></proto>
+ <param group="VertexStreamATI"><ptype>GLenum</ptype> <name>stream</name></param>
+ <param len="3">const <ptype>GLdouble</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glNormalStream3fATI</name></proto>
+ <param group="VertexStreamATI"><ptype>GLenum</ptype> <name>stream</name></param>
+ <param><ptype>GLfloat</ptype> <name>nx</name></param>
+ <param><ptype>GLfloat</ptype> <name>ny</name></param>
+ <param><ptype>GLfloat</ptype> <name>nz</name></param>
+ </command>
+ <command>
+ <proto>void <name>glNormalStream3fvATI</name></proto>
+ <param group="VertexStreamATI"><ptype>GLenum</ptype> <name>stream</name></param>
+ <param len="3">const <ptype>GLfloat</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glNormalStream3iATI</name></proto>
+ <param group="VertexStreamATI"><ptype>GLenum</ptype> <name>stream</name></param>
+ <param><ptype>GLint</ptype> <name>nx</name></param>
+ <param><ptype>GLint</ptype> <name>ny</name></param>
+ <param><ptype>GLint</ptype> <name>nz</name></param>
+ </command>
+ <command>
+ <proto>void <name>glNormalStream3ivATI</name></proto>
+ <param group="VertexStreamATI"><ptype>GLenum</ptype> <name>stream</name></param>
+ <param len="3">const <ptype>GLint</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glNormalStream3sATI</name></proto>
+ <param group="VertexStreamATI"><ptype>GLenum</ptype> <name>stream</name></param>
+ <param><ptype>GLshort</ptype> <name>nx</name></param>
+ <param><ptype>GLshort</ptype> <name>ny</name></param>
+ <param><ptype>GLshort</ptype> <name>nz</name></param>
+ </command>
+ <command>
+ <proto>void <name>glNormalStream3svATI</name></proto>
+ <param group="VertexStreamATI"><ptype>GLenum</ptype> <name>stream</name></param>
+ <param len="3">const <ptype>GLshort</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glObjectLabel</name></proto>
+ <param><ptype>GLenum</ptype> <name>identifier</name></param>
+ <param><ptype>GLuint</ptype> <name>name</name></param>
+ <param><ptype>GLsizei</ptype> <name>length</name></param>
+ <param len="COMPSIZE(label,length)">const <ptype>GLchar</ptype> *<name>label</name></param>
+ </command>
+ <command>
+ <proto>void <name>glObjectLabelKHR</name></proto>
+ <param><ptype>GLenum</ptype> <name>identifier</name></param>
+ <param><ptype>GLuint</ptype> <name>name</name></param>
+ <param><ptype>GLsizei</ptype> <name>length</name></param>
+ <param>const <ptype>GLchar</ptype> *<name>label</name></param>
+ <alias name="glObjectLabel"/>
+ </command>
+ <command>
+ <proto>void <name>glObjectPtrLabel</name></proto>
+ <param>const void *<name>ptr</name></param>
+ <param><ptype>GLsizei</ptype> <name>length</name></param>
+ <param len="COMPSIZE(label,length)">const <ptype>GLchar</ptype> *<name>label</name></param>
+ </command>
+ <command>
+ <proto>void <name>glObjectPtrLabelKHR</name></proto>
+ <param>const void *<name>ptr</name></param>
+ <param><ptype>GLsizei</ptype> <name>length</name></param>
+ <param>const <ptype>GLchar</ptype> *<name>label</name></param>
+ <alias name="glObjectPtrLabel"/>
+ </command>
+ <command>
+ <proto><ptype>GLenum</ptype> <name>glObjectPurgeableAPPLE</name></proto>
+ <param><ptype>GLenum</ptype> <name>objectType</name></param>
+ <param><ptype>GLuint</ptype> <name>name</name></param>
+ <param><ptype>GLenum</ptype> <name>option</name></param>
+ </command>
+ <command>
+ <proto><ptype>GLenum</ptype> <name>glObjectUnpurgeableAPPLE</name></proto>
+ <param><ptype>GLenum</ptype> <name>objectType</name></param>
+ <param><ptype>GLuint</ptype> <name>name</name></param>
+ <param><ptype>GLenum</ptype> <name>option</name></param>
+ </command>
+ <command>
+ <proto>void <name>glOrtho</name></proto>
+ <param><ptype>GLdouble</ptype> <name>left</name></param>
+ <param><ptype>GLdouble</ptype> <name>right</name></param>
+ <param><ptype>GLdouble</ptype> <name>bottom</name></param>
+ <param><ptype>GLdouble</ptype> <name>top</name></param>
+ <param><ptype>GLdouble</ptype> <name>zNear</name></param>
+ <param><ptype>GLdouble</ptype> <name>zFar</name></param>
+ <glx type="render" opcode="182"/>
+ </command>
+ <command>
+ <proto>void <name>glOrthof</name></proto>
+ <param><ptype>GLfloat</ptype> <name>l</name></param>
+ <param><ptype>GLfloat</ptype> <name>r</name></param>
+ <param><ptype>GLfloat</ptype> <name>b</name></param>
+ <param><ptype>GLfloat</ptype> <name>t</name></param>
+ <param><ptype>GLfloat</ptype> <name>n</name></param>
+ <param><ptype>GLfloat</ptype> <name>f</name></param>
+ </command>
+ <command>
+ <proto>void <name>glOrthofOES</name></proto>
+ <param><ptype>GLfloat</ptype> <name>l</name></param>
+ <param><ptype>GLfloat</ptype> <name>r</name></param>
+ <param><ptype>GLfloat</ptype> <name>b</name></param>
+ <param><ptype>GLfloat</ptype> <name>t</name></param>
+ <param><ptype>GLfloat</ptype> <name>n</name></param>
+ <param><ptype>GLfloat</ptype> <name>f</name></param>
+ <glx type="render" opcode="4311"/>
+ </command>
+ <command>
+ <proto>void <name>glOrthox</name></proto>
+ <param><ptype>GLfixed</ptype> <name>l</name></param>
+ <param><ptype>GLfixed</ptype> <name>r</name></param>
+ <param><ptype>GLfixed</ptype> <name>b</name></param>
+ <param><ptype>GLfixed</ptype> <name>t</name></param>
+ <param><ptype>GLfixed</ptype> <name>n</name></param>
+ <param><ptype>GLfixed</ptype> <name>f</name></param>
+ </command>
+ <command>
+ <proto>void <name>glOrthoxOES</name></proto>
+ <param><ptype>GLfixed</ptype> <name>l</name></param>
+ <param><ptype>GLfixed</ptype> <name>r</name></param>
+ <param><ptype>GLfixed</ptype> <name>b</name></param>
+ <param><ptype>GLfixed</ptype> <name>t</name></param>
+ <param><ptype>GLfixed</ptype> <name>n</name></param>
+ <param><ptype>GLfixed</ptype> <name>f</name></param>
+ </command>
+ <command>
+ <proto>void <name>glPNTrianglesfATI</name></proto>
+ <param group="PNTrianglesPNameATI"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLfloat</ptype> <name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glPNTrianglesiATI</name></proto>
+ <param group="PNTrianglesPNameATI"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLint</ptype> <name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glPassTexCoordATI</name></proto>
+ <param><ptype>GLuint</ptype> <name>dst</name></param>
+ <param><ptype>GLuint</ptype> <name>coord</name></param>
+ <param group="SwizzleOpATI"><ptype>GLenum</ptype> <name>swizzle</name></param>
+ </command>
+ <command>
+ <proto>void <name>glPassThrough</name></proto>
+ <param group="FeedbackElement"><ptype>GLfloat</ptype> <name>token</name></param>
+ <glx type="render" opcode="123"/>
+ </command>
+ <command>
+ <proto>void <name>glPassThroughxOES</name></proto>
+ <param><ptype>GLfixed</ptype> <name>token</name></param>
+ </command>
+ <command>
+ <proto>void <name>glPatchParameterfv</name></proto>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)">const <ptype>GLfloat</ptype> *<name>values</name></param>
+ </command>
+ <command>
+ <proto>void <name>glPatchParameteri</name></proto>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLint</ptype> <name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glPatchParameteriEXT</name></proto>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLint</ptype> <name>value</name></param>
+ <alias name="glPatchParameteri"/>
+ </command>
+ <command>
+ <proto>void <name>glPathColorGenNV</name></proto>
+ <param group="PathColor"><ptype>GLenum</ptype> <name>color</name></param>
+ <param group="PathGenMode"><ptype>GLenum</ptype> <name>genMode</name></param>
+ <param group="PathColorFormat"><ptype>GLenum</ptype> <name>colorFormat</name></param>
+ <param len="COMPSIZE(genMode,colorFormat)">const <ptype>GLfloat</ptype> *<name>coeffs</name></param>
+ </command>
+ <command>
+ <proto>void <name>glPathCommandsNV</name></proto>
+ <param group="Path"><ptype>GLuint</ptype> <name>path</name></param>
+ <param><ptype>GLsizei</ptype> <name>numCommands</name></param>
+ <param group="PathCommand" len="numCommands">const <ptype>GLubyte</ptype> *<name>commands</name></param>
+ <param><ptype>GLsizei</ptype> <name>numCoords</name></param>
+ <param group="PathCoordType"><ptype>GLenum</ptype> <name>coordType</name></param>
+ <param len="COMPSIZE(numCoords,coordType)">const void *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glPathCoordsNV</name></proto>
+ <param group="Path"><ptype>GLuint</ptype> <name>path</name></param>
+ <param><ptype>GLsizei</ptype> <name>numCoords</name></param>
+ <param group="PathCoordType"><ptype>GLenum</ptype> <name>coordType</name></param>
+ <param len="COMPSIZE(numCoords,coordType)">const void *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glPathCoverDepthFuncNV</name></proto>
+ <param group="DepthFunction"><ptype>GLenum</ptype> <name>func</name></param>
+ </command>
+ <command>
+ <proto>void <name>glPathDashArrayNV</name></proto>
+ <param group="Path"><ptype>GLuint</ptype> <name>path</name></param>
+ <param><ptype>GLsizei</ptype> <name>dashCount</name></param>
+ <param len="dashCount">const <ptype>GLfloat</ptype> *<name>dashArray</name></param>
+ </command>
+ <command>
+ <proto>void <name>glPathFogGenNV</name></proto>
+ <param group="PathGenMode"><ptype>GLenum</ptype> <name>genMode</name></param>
+ </command>
+ <command>
+ <proto><ptype>GLenum</ptype> <name>glPathGlyphIndexArrayNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>firstPathName</name></param>
+ <param><ptype>GLenum</ptype> <name>fontTarget</name></param>
+ <param>const void *<name>fontName</name></param>
+ <param><ptype>GLbitfield</ptype> <name>fontStyle</name></param>
+ <param><ptype>GLuint</ptype> <name>firstGlyphIndex</name></param>
+ <param><ptype>GLsizei</ptype> <name>numGlyphs</name></param>
+ <param><ptype>GLuint</ptype> <name>pathParameterTemplate</name></param>
+ <param><ptype>GLfloat</ptype> <name>emScale</name></param>
+ </command>
+ <command>
+ <proto><ptype>GLenum</ptype> <name>glPathGlyphIndexRangeNV</name></proto>
+ <param><ptype>GLenum</ptype> <name>fontTarget</name></param>
+ <param>const void *<name>fontName</name></param>
+ <param><ptype>GLbitfield</ptype> <name>fontStyle</name></param>
+ <param><ptype>GLuint</ptype> <name>pathParameterTemplate</name></param>
+ <param><ptype>GLfloat</ptype> <name>emScale</name></param>
+ <param><ptype>GLuint</ptype> <name>baseAndCount</name>[2]</param>
+ </command>
+ <command>
+ <proto>void <name>glPathGlyphRangeNV</name></proto>
+ <param group="Path"><ptype>GLuint</ptype> <name>firstPathName</name></param>
+ <param group="PathFontTarget"><ptype>GLenum</ptype> <name>fontTarget</name></param>
+ <param len="COMPSIZE(fontTarget,fontName)">const void *<name>fontName</name></param>
+ <param group="PathFontStyle"><ptype>GLbitfield</ptype> <name>fontStyle</name></param>
+ <param><ptype>GLuint</ptype> <name>firstGlyph</name></param>
+ <param><ptype>GLsizei</ptype> <name>numGlyphs</name></param>
+ <param group="PathHandleMissingGlyphs"><ptype>GLenum</ptype> <name>handleMissingGlyphs</name></param>
+ <param group="Path"><ptype>GLuint</ptype> <name>pathParameterTemplate</name></param>
+ <param><ptype>GLfloat</ptype> <name>emScale</name></param>
+ </command>
+ <command>
+ <proto>void <name>glPathGlyphsNV</name></proto>
+ <param group="Path"><ptype>GLuint</ptype> <name>firstPathName</name></param>
+ <param group="PathFontTarget"><ptype>GLenum</ptype> <name>fontTarget</name></param>
+ <param len="COMPSIZE(fontTarget,fontName)">const void *<name>fontName</name></param>
+ <param group="PathFontStyle"><ptype>GLbitfield</ptype> <name>fontStyle</name></param>
+ <param><ptype>GLsizei</ptype> <name>numGlyphs</name></param>
+ <param group="PathElementType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(numGlyphs,type,charcodes)">const void *<name>charcodes</name></param>
+ <param group="PathHandleMissingGlyphs"><ptype>GLenum</ptype> <name>handleMissingGlyphs</name></param>
+ <param group="Path"><ptype>GLuint</ptype> <name>pathParameterTemplate</name></param>
+ <param><ptype>GLfloat</ptype> <name>emScale</name></param>
+ </command>
+ <command>
+ <proto><ptype>GLenum</ptype> <name>glPathMemoryGlyphIndexArrayNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>firstPathName</name></param>
+ <param><ptype>GLenum</ptype> <name>fontTarget</name></param>
+ <param><ptype>GLsizeiptr</ptype> <name>fontSize</name></param>
+ <param>const void *<name>fontData</name></param>
+ <param><ptype>GLsizei</ptype> <name>faceIndex</name></param>
+ <param><ptype>GLuint</ptype> <name>firstGlyphIndex</name></param>
+ <param><ptype>GLsizei</ptype> <name>numGlyphs</name></param>
+ <param><ptype>GLuint</ptype> <name>pathParameterTemplate</name></param>
+ <param><ptype>GLfloat</ptype> <name>emScale</name></param>
+ </command>
+ <command>
+ <proto>void <name>glPathParameterfNV</name></proto>
+ <param group="Path"><ptype>GLuint</ptype> <name>path</name></param>
+ <param group="PathParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLfloat</ptype> <name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glPathParameterfvNV</name></proto>
+ <param group="Path"><ptype>GLuint</ptype> <name>path</name></param>
+ <param group="PathParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)">const <ptype>GLfloat</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glPathParameteriNV</name></proto>
+ <param group="Path"><ptype>GLuint</ptype> <name>path</name></param>
+ <param group="PathParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLint</ptype> <name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glPathParameterivNV</name></proto>
+ <param group="Path"><ptype>GLuint</ptype> <name>path</name></param>
+ <param group="PathParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)">const <ptype>GLint</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glPathStencilDepthOffsetNV</name></proto>
+ <param><ptype>GLfloat</ptype> <name>factor</name></param>
+ <param><ptype>GLfloat</ptype> <name>units</name></param>
+ </command>
+ <command>
+ <proto>void <name>glPathStencilFuncNV</name></proto>
+ <param group="StencilFunction"><ptype>GLenum</ptype> <name>func</name></param>
+ <param group="ClampedStencilValue"><ptype>GLint</ptype> <name>ref</name></param>
+ <param group="MaskedStencilValue"><ptype>GLuint</ptype> <name>mask</name></param>
+ </command>
+ <command>
+ <proto>void <name>glPathStringNV</name></proto>
+ <param group="Path"><ptype>GLuint</ptype> <name>path</name></param>
+ <param group="PathStringFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param><ptype>GLsizei</ptype> <name>length</name></param>
+ <param len="length">const void *<name>pathString</name></param>
+ </command>
+ <command>
+ <proto>void <name>glPathSubCommandsNV</name></proto>
+ <param group="Path"><ptype>GLuint</ptype> <name>path</name></param>
+ <param><ptype>GLsizei</ptype> <name>commandStart</name></param>
+ <param><ptype>GLsizei</ptype> <name>commandsToDelete</name></param>
+ <param><ptype>GLsizei</ptype> <name>numCommands</name></param>
+ <param group="PathCommand" len="numCommands">const <ptype>GLubyte</ptype> *<name>commands</name></param>
+ <param><ptype>GLsizei</ptype> <name>numCoords</name></param>
+ <param group="PathCoordType"><ptype>GLenum</ptype> <name>coordType</name></param>
+ <param len="COMPSIZE(numCoords,coordType)">const void *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glPathSubCoordsNV</name></proto>
+ <param group="Path"><ptype>GLuint</ptype> <name>path</name></param>
+ <param><ptype>GLsizei</ptype> <name>coordStart</name></param>
+ <param><ptype>GLsizei</ptype> <name>numCoords</name></param>
+ <param group="PathCoordType"><ptype>GLenum</ptype> <name>coordType</name></param>
+ <param len="COMPSIZE(numCoords,coordType)">const void *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glPathTexGenNV</name></proto>
+ <param group="PathColor"><ptype>GLenum</ptype> <name>texCoordSet</name></param>
+ <param group="PathGenMode"><ptype>GLenum</ptype> <name>genMode</name></param>
+ <param><ptype>GLint</ptype> <name>components</name></param>
+ <param len="COMPSIZE(genMode,components)">const <ptype>GLfloat</ptype> *<name>coeffs</name></param>
+ </command>
+ <command>
+ <proto>void <name>glPauseTransformFeedback</name></proto>
+ </command>
+ <command>
+ <proto>void <name>glPauseTransformFeedbackNV</name></proto>
+ <alias name="glPauseTransformFeedback"/>
+ </command>
+ <command>
+ <proto>void <name>glPixelDataRangeNV</name></proto>
+ <param group="PixelDataRangeTargetNV"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLsizei</ptype> <name>length</name></param>
+ <param len="length">const void *<name>pointer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glPixelMapfv</name></proto>
+ <param group="PixelMap"><ptype>GLenum</ptype> <name>map</name></param>
+ <param group="CheckedInt32"><ptype>GLsizei</ptype> <name>mapsize</name></param>
+ <param len="mapsize">const <ptype>GLfloat</ptype> *<name>values</name></param>
+ <glx type="render" opcode="168"/>
+ <glx type="render" opcode="323" name="glPixelMapfvPBO" comment="PBO protocol"/>
+ </command>
+ <command>
+ <proto>void <name>glPixelMapuiv</name></proto>
+ <param group="PixelMap"><ptype>GLenum</ptype> <name>map</name></param>
+ <param group="CheckedInt32"><ptype>GLsizei</ptype> <name>mapsize</name></param>
+ <param len="mapsize">const <ptype>GLuint</ptype> *<name>values</name></param>
+ <glx type="render" opcode="169"/>
+ <glx type="render" opcode="324" name="glPixelMapuivPBO" comment="PBO protocol"/>
+ </command>
+ <command>
+ <proto>void <name>glPixelMapusv</name></proto>
+ <param group="PixelMap"><ptype>GLenum</ptype> <name>map</name></param>
+ <param group="CheckedInt32"><ptype>GLsizei</ptype> <name>mapsize</name></param>
+ <param len="mapsize">const <ptype>GLushort</ptype> *<name>values</name></param>
+ <glx type="render" opcode="170"/>
+ <glx type="render" opcode="325" name="glPixelMapusvPBO" comment="PBO protocol"/>
+ </command>
+ <command>
+ <proto>void <name>glPixelMapx</name></proto>
+ <param><ptype>GLenum</ptype> <name>map</name></param>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param len="size">const <ptype>GLfixed</ptype> *<name>values</name></param>
+ </command>
+ <command>
+ <proto>void <name>glPixelStoref</name></proto>
+ <param group="PixelStoreParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedFloat32"><ptype>GLfloat</ptype> <name>param</name></param>
+ <glx type="single" opcode="109"/>
+ </command>
+ <command>
+ <proto>void <name>glPixelStorei</name></proto>
+ <param group="PixelStoreParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>param</name></param>
+ <glx type="single" opcode="110"/>
+ </command>
+ <command>
+ <proto>void <name>glPixelStorex</name></proto>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLfixed</ptype> <name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glPixelTexGenParameterfSGIS</name></proto>
+ <param group="PixelTexGenParameterNameSGIS"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedFloat32"><ptype>GLfloat</ptype> <name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glPixelTexGenParameterfvSGIS</name></proto>
+ <param group="PixelTexGenParameterNameSGIS"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedFloat32" len="COMPSIZE(pname)">const <ptype>GLfloat</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glPixelTexGenParameteriSGIS</name></proto>
+ <param group="PixelTexGenParameterNameSGIS"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glPixelTexGenParameterivSGIS</name></proto>
+ <param group="PixelTexGenParameterNameSGIS"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedInt32" len="COMPSIZE(pname)">const <ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glPixelTexGenSGIX</name></proto>
+ <param group="PixelTexGenModeSGIX"><ptype>GLenum</ptype> <name>mode</name></param>
+ <glx type="render" opcode="2059"/>
+ </command>
+ <command>
+ <proto>void <name>glPixelTransferf</name></proto>
+ <param group="PixelTransferParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedFloat32"><ptype>GLfloat</ptype> <name>param</name></param>
+ <glx type="render" opcode="166"/>
+ </command>
+ <command>
+ <proto>void <name>glPixelTransferi</name></proto>
+ <param group="PixelTransferParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>param</name></param>
+ <glx type="render" opcode="167"/>
+ </command>
+ <command>
+ <proto>void <name>glPixelTransferxOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLfixed</ptype> <name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glPixelTransformParameterfEXT</name></proto>
+ <param group="PixelTransformTargetEXT"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="PixelTransformPNameEXT"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLfloat</ptype> <name>param</name></param>
+ <glx type="render" opcode="16385"/>
+ </command>
+ <command>
+ <proto>void <name>glPixelTransformParameterfvEXT</name></proto>
+ <param group="PixelTransformTargetEXT"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="PixelTransformPNameEXT"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="1">const <ptype>GLfloat</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glPixelTransformParameteriEXT</name></proto>
+ <param group="PixelTransformTargetEXT"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="PixelTransformPNameEXT"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLint</ptype> <name>param</name></param>
+ <glx type="render" opcode="16386"/>
+ </command>
+ <command>
+ <proto>void <name>glPixelTransformParameterivEXT</name></proto>
+ <param group="PixelTransformTargetEXT"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="PixelTransformPNameEXT"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="1">const <ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glPixelZoom</name></proto>
+ <param><ptype>GLfloat</ptype> <name>xfactor</name></param>
+ <param><ptype>GLfloat</ptype> <name>yfactor</name></param>
+ <glx type="render" opcode="165"/>
+ </command>
+ <command>
+ <proto>void <name>glPixelZoomxOES</name></proto>
+ <param><ptype>GLfixed</ptype> <name>xfactor</name></param>
+ <param><ptype>GLfixed</ptype> <name>yfactor</name></param>
+ </command>
+ <command>
+ <proto group="Boolean"><ptype>GLboolean</ptype> <name>glPointAlongPathNV</name></proto>
+ <param group="Path"><ptype>GLuint</ptype> <name>path</name></param>
+ <param><ptype>GLsizei</ptype> <name>startSegment</name></param>
+ <param><ptype>GLsizei</ptype> <name>numSegments</name></param>
+ <param><ptype>GLfloat</ptype> <name>distance</name></param>
+ <param len="1"><ptype>GLfloat</ptype> *<name>x</name></param>
+ <param len="1"><ptype>GLfloat</ptype> *<name>y</name></param>
+ <param len="1"><ptype>GLfloat</ptype> *<name>tangentX</name></param>
+ <param len="1"><ptype>GLfloat</ptype> *<name>tangentY</name></param>
+ </command>
+ <command>
+ <proto>void <name>glPointParameterf</name></proto>
+ <param group="PointParameterNameARB"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedFloat32"><ptype>GLfloat</ptype> <name>param</name></param>
+ <glx type="render" opcode="2065"/>
+ </command>
+ <command>
+ <proto>void <name>glPointParameterfARB</name></proto>
+ <param group="PointParameterNameARB"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedFloat32"><ptype>GLfloat</ptype> <name>param</name></param>
+ <alias name="glPointParameterf"/>
+ <glx type="render" opcode="2065"/>
+ </command>
+ <command>
+ <proto>void <name>glPointParameterfEXT</name></proto>
+ <param group="PointParameterNameARB"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedFloat32"><ptype>GLfloat</ptype> <name>param</name></param>
+ <alias name="glPointParameterf"/>
+ </command>
+ <command>
+ <proto>void <name>glPointParameterfSGIS</name></proto>
+ <param group="PointParameterNameARB"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedFloat32"><ptype>GLfloat</ptype> <name>param</name></param>
+ <alias name="glPointParameterf"/>
+ </command>
+ <command>
+ <proto>void <name>glPointParameterfv</name></proto>
+ <param group="PointParameterNameARB"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedFloat32" len="COMPSIZE(pname)">const <ptype>GLfloat</ptype> *<name>params</name></param>
+ <glx type="render" opcode="2066"/>
+ </command>
+ <command>
+ <proto>void <name>glPointParameterfvARB</name></proto>
+ <param group="PointParameterNameARB"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedFloat32" len="COMPSIZE(pname)">const <ptype>GLfloat</ptype> *<name>params</name></param>
+ <alias name="glPointParameterfv"/>
+ <glx type="render" opcode="2066"/>
+ </command>
+ <command>
+ <proto>void <name>glPointParameterfvEXT</name></proto>
+ <param group="PointParameterNameARB"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedFloat32" len="COMPSIZE(pname)">const <ptype>GLfloat</ptype> *<name>params</name></param>
+ <alias name="glPointParameterfv"/>
+ </command>
+ <command>
+ <proto>void <name>glPointParameterfvSGIS</name></proto>
+ <param group="PointParameterNameARB"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedFloat32" len="COMPSIZE(pname)">const <ptype>GLfloat</ptype> *<name>params</name></param>
+ <alias name="glPointParameterfv"/>
+ </command>
+ <command>
+ <proto>void <name>glPointParameteri</name></proto>
+ <param group="PointParameterNameARB"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLint</ptype> <name>param</name></param>
+ <glx type="render" opcode="4221"/>
+ </command>
+ <command>
+ <proto>void <name>glPointParameteriNV</name></proto>
+ <param group="PointParameterNameARB"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLint</ptype> <name>param</name></param>
+ <alias name="glPointParameteri"/>
+ <glx type="render" opcode="4221"/>
+ </command>
+ <command>
+ <proto>void <name>glPointParameteriv</name></proto>
+ <param group="PointParameterNameARB"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)">const <ptype>GLint</ptype> *<name>params</name></param>
+ <glx type="render" opcode="4222"/>
+ </command>
+ <command>
+ <proto>void <name>glPointParameterivNV</name></proto>
+ <param group="PointParameterNameARB"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)">const <ptype>GLint</ptype> *<name>params</name></param>
+ <alias name="glPointParameteriv"/>
+ <glx type="render" opcode="4222"/>
+ </command>
+ <command>
+ <proto>void <name>glPointParameterx</name></proto>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLfixed</ptype> <name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glPointParameterxOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLfixed</ptype> <name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glPointParameterxv</name></proto>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)">const <ptype>GLfixed</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glPointParameterxvOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)">const <ptype>GLfixed</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glPointSize</name></proto>
+ <param group="CheckedFloat32"><ptype>GLfloat</ptype> <name>size</name></param>
+ <glx type="render" opcode="100"/>
+ </command>
+ <command>
+ <proto>void <name>glPointSizePointerOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ <param len="COMPSIZE(type,stride)">const void *<name>pointer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glPointSizex</name></proto>
+ <param><ptype>GLfixed</ptype> <name>size</name></param>
+ </command>
+ <command>
+ <proto>void <name>glPointSizexOES</name></proto>
+ <param><ptype>GLfixed</ptype> <name>size</name></param>
+ </command>
+ <command>
+ <proto><ptype>GLint</ptype> <name>glPollAsyncSGIX</name></proto>
+ <param len="1"><ptype>GLuint</ptype> *<name>markerp</name></param>
+ </command>
+ <command>
+ <proto><ptype>GLint</ptype> <name>glPollInstrumentsSGIX</name></proto>
+ <param len="1"><ptype>GLint</ptype> *<name>marker_p</name></param>
+ <glx type="vendor" opcode="4104"/>
+ </command>
+ <command>
+ <proto>void <name>glPolygonMode</name></proto>
+ <param group="MaterialFace"><ptype>GLenum</ptype> <name>face</name></param>
+ <param group="PolygonMode"><ptype>GLenum</ptype> <name>mode</name></param>
+ <glx type="render" opcode="101"/>
+ </command>
+ <command>
+ <proto>void <name>glPolygonOffset</name></proto>
+ <param><ptype>GLfloat</ptype> <name>factor</name></param>
+ <param><ptype>GLfloat</ptype> <name>units</name></param>
+ <glx type="render" opcode="192"/>
+ </command>
+ <command>
+ <proto>void <name>glPolygonOffsetEXT</name></proto>
+ <param><ptype>GLfloat</ptype> <name>factor</name></param>
+ <param><ptype>GLfloat</ptype> <name>bias</name></param>
+ <glx type="render" opcode="4098"/>
+ </command>
+ <command>
+ <proto>void <name>glPolygonOffsetx</name></proto>
+ <param><ptype>GLfixed</ptype> <name>factor</name></param>
+ <param><ptype>GLfixed</ptype> <name>units</name></param>
+ </command>
+ <command>
+ <proto>void <name>glPolygonOffsetxOES</name></proto>
+ <param><ptype>GLfixed</ptype> <name>factor</name></param>
+ <param><ptype>GLfixed</ptype> <name>units</name></param>
+ </command>
+ <command>
+ <proto>void <name>glPolygonStipple</name></proto>
+ <param len="COMPSIZE()">const <ptype>GLubyte</ptype> *<name>mask</name></param>
+ <glx type="render" opcode="102"/>
+ <glx type="render" opcode="326" name="glPolygonStipplePBO" comment="PBO protocol"/>
+ </command>
+ <command>
+ <proto>void <name>glPopAttrib</name></proto>
+ <glx type="render" opcode="141"/>
+ </command>
+ <command>
+ <proto>void <name>glPopClientAttrib</name></proto>
+ </command>
+ <command>
+ <proto>void <name>glPopDebugGroup</name></proto>
+ </command>
+ <command>
+ <proto>void <name>glPopDebugGroupKHR</name></proto>
+ <alias name="glPopDebugGroup"/>
+ </command>
+ <command>
+ <proto>void <name>glPopGroupMarkerEXT</name></proto>
+ </command>
+ <command>
+ <proto>void <name>glPopMatrix</name></proto>
+ <glx type="render" opcode="183"/>
+ </command>
+ <command>
+ <proto>void <name>glPopName</name></proto>
+ <glx type="render" opcode="124"/>
+ </command>
+ <command>
+ <proto>void <name>glPresentFrameDualFillNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>video_slot</name></param>
+ <param><ptype>GLuint64EXT</ptype> <name>minPresentTime</name></param>
+ <param><ptype>GLuint</ptype> <name>beginPresentTimeId</name></param>
+ <param><ptype>GLuint</ptype> <name>presentDurationId</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLenum</ptype> <name>target0</name></param>
+ <param><ptype>GLuint</ptype> <name>fill0</name></param>
+ <param><ptype>GLenum</ptype> <name>target1</name></param>
+ <param><ptype>GLuint</ptype> <name>fill1</name></param>
+ <param><ptype>GLenum</ptype> <name>target2</name></param>
+ <param><ptype>GLuint</ptype> <name>fill2</name></param>
+ <param><ptype>GLenum</ptype> <name>target3</name></param>
+ <param><ptype>GLuint</ptype> <name>fill3</name></param>
+ </command>
+ <command>
+ <proto>void <name>glPresentFrameKeyedNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>video_slot</name></param>
+ <param><ptype>GLuint64EXT</ptype> <name>minPresentTime</name></param>
+ <param><ptype>GLuint</ptype> <name>beginPresentTimeId</name></param>
+ <param><ptype>GLuint</ptype> <name>presentDurationId</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLenum</ptype> <name>target0</name></param>
+ <param><ptype>GLuint</ptype> <name>fill0</name></param>
+ <param><ptype>GLuint</ptype> <name>key0</name></param>
+ <param><ptype>GLenum</ptype> <name>target1</name></param>
+ <param><ptype>GLuint</ptype> <name>fill1</name></param>
+ <param><ptype>GLuint</ptype> <name>key1</name></param>
+ </command>
+ <command>
+ <proto>void <name>glPrimitiveBoundingBoxEXT</name></proto>
+ <param><ptype>GLfloat</ptype> <name>minX</name></param>
+ <param><ptype>GLfloat</ptype> <name>minY</name></param>
+ <param><ptype>GLfloat</ptype> <name>minZ</name></param>
+ <param><ptype>GLfloat</ptype> <name>minW</name></param>
+ <param><ptype>GLfloat</ptype> <name>maxX</name></param>
+ <param><ptype>GLfloat</ptype> <name>maxY</name></param>
+ <param><ptype>GLfloat</ptype> <name>maxZ</name></param>
+ <param><ptype>GLfloat</ptype> <name>maxW</name></param>
+ </command>
+ <command>
+ <proto>void <name>glPrimitiveRestartIndex</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ </command>
+ <command>
+ <proto>void <name>glPrimitiveRestartIndexNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ </command>
+ <command>
+ <proto>void <name>glPrimitiveRestartNV</name></proto>
+ </command>
+ <command>
+ <proto>void <name>glPrioritizeTextures</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param group="Texture" len="n">const <ptype>GLuint</ptype> *<name>textures</name></param>
+ <param len="n">const <ptype>GLfloat</ptype> *<name>priorities</name></param>
+ <glx type="render" opcode="4118"/>
+ </command>
+ <command>
+ <proto>void <name>glPrioritizeTexturesEXT</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param group="Texture" len="n">const <ptype>GLuint</ptype> *<name>textures</name></param>
+ <param group="ClampedFloat32" len="n">const <ptype>GLclampf</ptype> *<name>priorities</name></param>
+ <alias name="glPrioritizeTextures"/>
+ <glx type="render" opcode="4118"/>
+ </command>
+ <command>
+ <proto>void <name>glPrioritizeTexturesxOES</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param len="n">const <ptype>GLuint</ptype> *<name>textures</name></param>
+ <param group="ClampedFixed" len="n">const <ptype>GLfixed</ptype> *<name>priorities</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramBinary</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLenum</ptype> <name>binaryFormat</name></param>
+ <param len="length">const void *<name>binary</name></param>
+ <param><ptype>GLsizei</ptype> <name>length</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramBinaryOES</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLenum</ptype> <name>binaryFormat</name></param>
+ <param len="length">const void *<name>binary</name></param>
+ <param><ptype>GLint</ptype> <name>length</name></param>
+ <alias name="glProgramBinary"/>
+ </command>
+ <command>
+ <proto>void <name>glProgramBufferParametersIivNV</name></proto>
+ <param group="ProgramTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>bindingIndex</name></param>
+ <param><ptype>GLuint</ptype> <name>wordIndex</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count">const <ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramBufferParametersIuivNV</name></proto>
+ <param group="ProgramTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>bindingIndex</name></param>
+ <param><ptype>GLuint</ptype> <name>wordIndex</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count">const <ptype>GLuint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramBufferParametersfvNV</name></proto>
+ <param group="ProgramTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>bindingIndex</name></param>
+ <param><ptype>GLuint</ptype> <name>wordIndex</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count">const <ptype>GLfloat</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramEnvParameter4dARB</name></proto>
+ <param group="ProgramTargetARB"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLdouble</ptype> <name>x</name></param>
+ <param><ptype>GLdouble</ptype> <name>y</name></param>
+ <param><ptype>GLdouble</ptype> <name>z</name></param>
+ <param><ptype>GLdouble</ptype> <name>w</name></param>
+ <vecequiv name="glProgramEnvParameter4dvARB"/>
+ </command>
+ <command>
+ <proto>void <name>glProgramEnvParameter4dvARB</name></proto>
+ <param group="ProgramTargetARB"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLdouble</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramEnvParameter4fARB</name></proto>
+ <param group="ProgramTargetARB"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLfloat</ptype> <name>x</name></param>
+ <param><ptype>GLfloat</ptype> <name>y</name></param>
+ <param><ptype>GLfloat</ptype> <name>z</name></param>
+ <param><ptype>GLfloat</ptype> <name>w</name></param>
+ <vecequiv name="glProgramEnvParameter4fvARB"/>
+ </command>
+ <command>
+ <proto>void <name>glProgramEnvParameter4fvARB</name></proto>
+ <param group="ProgramTargetARB"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLfloat</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramEnvParameterI4iNV</name></proto>
+ <param group="ProgramTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLint</ptype> <name>x</name></param>
+ <param><ptype>GLint</ptype> <name>y</name></param>
+ <param><ptype>GLint</ptype> <name>z</name></param>
+ <param><ptype>GLint</ptype> <name>w</name></param>
+ <vecequiv name="glProgramEnvParameterI4ivNV"/>
+ </command>
+ <command>
+ <proto>void <name>glProgramEnvParameterI4ivNV</name></proto>
+ <param group="ProgramTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramEnvParameterI4uiNV</name></proto>
+ <param group="ProgramTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLuint</ptype> <name>x</name></param>
+ <param><ptype>GLuint</ptype> <name>y</name></param>
+ <param><ptype>GLuint</ptype> <name>z</name></param>
+ <param><ptype>GLuint</ptype> <name>w</name></param>
+ <vecequiv name="glProgramEnvParameterI4uivNV"/>
+ </command>
+ <command>
+ <proto>void <name>glProgramEnvParameterI4uivNV</name></proto>
+ <param group="ProgramTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLuint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramEnvParameters4fvEXT</name></proto>
+ <param group="ProgramTargetARB"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*4">const <ptype>GLfloat</ptype> *<name>params</name></param>
+ <glx type="render" opcode="4281"/>
+ </command>
+ <command>
+ <proto>void <name>glProgramEnvParametersI4ivNV</name></proto>
+ <param group="ProgramTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*4">const <ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramEnvParametersI4uivNV</name></proto>
+ <param group="ProgramTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*4">const <ptype>GLuint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramLocalParameter4dARB</name></proto>
+ <param group="ProgramTargetARB"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLdouble</ptype> <name>x</name></param>
+ <param><ptype>GLdouble</ptype> <name>y</name></param>
+ <param><ptype>GLdouble</ptype> <name>z</name></param>
+ <param><ptype>GLdouble</ptype> <name>w</name></param>
+ <vecequiv name="glProgramLocalParameter4dvARB"/>
+ </command>
+ <command>
+ <proto>void <name>glProgramLocalParameter4dvARB</name></proto>
+ <param group="ProgramTargetARB"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLdouble</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramLocalParameter4fARB</name></proto>
+ <param group="ProgramTargetARB"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLfloat</ptype> <name>x</name></param>
+ <param><ptype>GLfloat</ptype> <name>y</name></param>
+ <param><ptype>GLfloat</ptype> <name>z</name></param>
+ <param><ptype>GLfloat</ptype> <name>w</name></param>
+ <vecequiv name="glProgramLocalParameter4fvARB"/>
+ </command>
+ <command>
+ <proto>void <name>glProgramLocalParameter4fvARB</name></proto>
+ <param group="ProgramTargetARB"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLfloat</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramLocalParameterI4iNV</name></proto>
+ <param group="ProgramTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLint</ptype> <name>x</name></param>
+ <param><ptype>GLint</ptype> <name>y</name></param>
+ <param><ptype>GLint</ptype> <name>z</name></param>
+ <param><ptype>GLint</ptype> <name>w</name></param>
+ <vecequiv name="glProgramLocalParameterI4ivNV"/>
+ </command>
+ <command>
+ <proto>void <name>glProgramLocalParameterI4ivNV</name></proto>
+ <param group="ProgramTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramLocalParameterI4uiNV</name></proto>
+ <param group="ProgramTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLuint</ptype> <name>x</name></param>
+ <param><ptype>GLuint</ptype> <name>y</name></param>
+ <param><ptype>GLuint</ptype> <name>z</name></param>
+ <param><ptype>GLuint</ptype> <name>w</name></param>
+ <vecequiv name="glProgramLocalParameterI4uivNV"/>
+ </command>
+ <command>
+ <proto>void <name>glProgramLocalParameterI4uivNV</name></proto>
+ <param group="ProgramTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLuint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramLocalParameters4fvEXT</name></proto>
+ <param group="ProgramTargetARB"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*4">const <ptype>GLfloat</ptype> *<name>params</name></param>
+ <glx type="render" opcode="4282"/>
+ </command>
+ <command>
+ <proto>void <name>glProgramLocalParametersI4ivNV</name></proto>
+ <param group="ProgramTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*4">const <ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramLocalParametersI4uivNV</name></proto>
+ <param group="ProgramTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*4">const <ptype>GLuint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramNamedParameter4dNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <param><ptype>GLsizei</ptype> <name>len</name></param>
+ <param len="1">const <ptype>GLubyte</ptype> *<name>name</name></param>
+ <param><ptype>GLdouble</ptype> <name>x</name></param>
+ <param><ptype>GLdouble</ptype> <name>y</name></param>
+ <param><ptype>GLdouble</ptype> <name>z</name></param>
+ <param><ptype>GLdouble</ptype> <name>w</name></param>
+ <vecequiv name="glProgramNamedParameter4dvNV"/>
+ </command>
+ <command>
+ <proto>void <name>glProgramNamedParameter4dvNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <param><ptype>GLsizei</ptype> <name>len</name></param>
+ <param len="1">const <ptype>GLubyte</ptype> *<name>name</name></param>
+ <param len="4">const <ptype>GLdouble</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4219"/>
+ </command>
+ <command>
+ <proto>void <name>glProgramNamedParameter4fNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <param><ptype>GLsizei</ptype> <name>len</name></param>
+ <param len="1">const <ptype>GLubyte</ptype> *<name>name</name></param>
+ <param><ptype>GLfloat</ptype> <name>x</name></param>
+ <param><ptype>GLfloat</ptype> <name>y</name></param>
+ <param><ptype>GLfloat</ptype> <name>z</name></param>
+ <param><ptype>GLfloat</ptype> <name>w</name></param>
+ <vecequiv name="glProgramNamedParameter4fvNV"/>
+ </command>
+ <command>
+ <proto>void <name>glProgramNamedParameter4fvNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <param><ptype>GLsizei</ptype> <name>len</name></param>
+ <param len="1">const <ptype>GLubyte</ptype> *<name>name</name></param>
+ <param len="4">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4218"/>
+ </command>
+ <command>
+ <proto>void <name>glProgramParameter4dNV</name></proto>
+ <param group="VertexAttribEnumNV"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLdouble</ptype> <name>x</name></param>
+ <param><ptype>GLdouble</ptype> <name>y</name></param>
+ <param><ptype>GLdouble</ptype> <name>z</name></param>
+ <param><ptype>GLdouble</ptype> <name>w</name></param>
+ <vecequiv name="glProgramParameter4dvNV"/>
+ </command>
+ <command>
+ <proto>void <name>glProgramParameter4dvNV</name></proto>
+ <param group="VertexAttribEnumNV"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLdouble</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4185"/>
+ </command>
+ <command>
+ <proto>void <name>glProgramParameter4fNV</name></proto>
+ <param group="VertexAttribEnumNV"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLfloat</ptype> <name>x</name></param>
+ <param><ptype>GLfloat</ptype> <name>y</name></param>
+ <param><ptype>GLfloat</ptype> <name>z</name></param>
+ <param><ptype>GLfloat</ptype> <name>w</name></param>
+ <vecequiv name="glProgramParameter4fvNV"/>
+ </command>
+ <command>
+ <proto>void <name>glProgramParameter4fvNV</name></proto>
+ <param group="VertexAttribEnumNV"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4184"/>
+ </command>
+ <command>
+ <proto>void <name>glProgramParameteri</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param group="ProgramParameterPName"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLint</ptype> <name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramParameteriARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param group="ProgramParameterPName"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLint</ptype> <name>value</name></param>
+ <alias name="glProgramParameteri"/>
+ </command>
+ <command>
+ <proto>void <name>glProgramParameteriEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param group="ProgramParameterPName"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLint</ptype> <name>value</name></param>
+ <alias name="glProgramParameteri"/>
+ </command>
+ <command>
+ <proto>void <name>glProgramParameters4dvNV</name></proto>
+ <param group="VertexAttribEnumNV"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*4">const <ptype>GLdouble</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4187"/>
+ </command>
+ <command>
+ <proto>void <name>glProgramParameters4fvNV</name></proto>
+ <param group="VertexAttribEnumNV"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*4">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4186"/>
+ </command>
+ <command>
+ <proto>void <name>glProgramPathFragmentInputGenNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLenum</ptype> <name>genMode</name></param>
+ <param><ptype>GLint</ptype> <name>components</name></param>
+ <param>const <ptype>GLfloat</ptype> *<name>coeffs</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramStringARB</name></proto>
+ <param group="ProgramTargetARB"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="ProgramFormatARB"><ptype>GLenum</ptype> <name>format</name></param>
+ <param><ptype>GLsizei</ptype> <name>len</name></param>
+ <param len="len">const void *<name>string</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramSubroutineParametersuivNV</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count">const <ptype>GLuint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform1d</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLdouble</ptype> <name>v0</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform1dEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLdouble</ptype> <name>x</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform1dv</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="1">const <ptype>GLdouble</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform1dvEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count">const <ptype>GLdouble</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform1f</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLfloat</ptype> <name>v0</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform1fEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLfloat</ptype> <name>v0</name></param>
+ <alias name="glProgramUniform1f"/>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform1fv</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="1">const <ptype>GLfloat</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform1fvEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count">const <ptype>GLfloat</ptype> *<name>value</name></param>
+ <alias name="glProgramUniform1fv"/>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform1i</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLint</ptype> <name>v0</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform1i64NV</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLint64EXT</ptype> <name>x</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform1i64vNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count">const <ptype>GLint64EXT</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform1iEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLint</ptype> <name>v0</name></param>
+ <alias name="glProgramUniform1i"/>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform1iv</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="1">const <ptype>GLint</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform1ivEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count">const <ptype>GLint</ptype> *<name>value</name></param>
+ <alias name="glProgramUniform1iv"/>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform1ui</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLuint</ptype> <name>v0</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform1ui64NV</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLuint64EXT</ptype> <name>x</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform1ui64vNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count">const <ptype>GLuint64EXT</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform1uiEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLuint</ptype> <name>v0</name></param>
+ <alias name="glProgramUniform1ui"/>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform1uiv</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="1">const <ptype>GLuint</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform1uivEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count">const <ptype>GLuint</ptype> *<name>value</name></param>
+ <alias name="glProgramUniform1uiv"/>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform2d</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLdouble</ptype> <name>v0</name></param>
+ <param><ptype>GLdouble</ptype> <name>v1</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform2dEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLdouble</ptype> <name>x</name></param>
+ <param><ptype>GLdouble</ptype> <name>y</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform2dv</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="2">const <ptype>GLdouble</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform2dvEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count">const <ptype>GLdouble</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform2f</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLfloat</ptype> <name>v0</name></param>
+ <param><ptype>GLfloat</ptype> <name>v1</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform2fEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLfloat</ptype> <name>v0</name></param>
+ <param><ptype>GLfloat</ptype> <name>v1</name></param>
+ <alias name="glProgramUniform2f"/>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform2fv</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="2">const <ptype>GLfloat</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform2fvEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*2">const <ptype>GLfloat</ptype> *<name>value</name></param>
+ <alias name="glProgramUniform2fv"/>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform2i</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLint</ptype> <name>v0</name></param>
+ <param><ptype>GLint</ptype> <name>v1</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform2i64NV</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLint64EXT</ptype> <name>x</name></param>
+ <param><ptype>GLint64EXT</ptype> <name>y</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform2i64vNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*2">const <ptype>GLint64EXT</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform2iEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLint</ptype> <name>v0</name></param>
+ <param><ptype>GLint</ptype> <name>v1</name></param>
+ <alias name="glProgramUniform2i"/>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform2iv</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="2">const <ptype>GLint</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform2ivEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*2">const <ptype>GLint</ptype> *<name>value</name></param>
+ <alias name="glProgramUniform2iv"/>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform2ui</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLuint</ptype> <name>v0</name></param>
+ <param><ptype>GLuint</ptype> <name>v1</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform2ui64NV</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLuint64EXT</ptype> <name>x</name></param>
+ <param><ptype>GLuint64EXT</ptype> <name>y</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform2ui64vNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*2">const <ptype>GLuint64EXT</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform2uiEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLuint</ptype> <name>v0</name></param>
+ <param><ptype>GLuint</ptype> <name>v1</name></param>
+ <alias name="glProgramUniform2ui"/>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform2uiv</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="2">const <ptype>GLuint</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform2uivEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*2">const <ptype>GLuint</ptype> *<name>value</name></param>
+ <alias name="glProgramUniform2uiv"/>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform3d</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLdouble</ptype> <name>v0</name></param>
+ <param><ptype>GLdouble</ptype> <name>v1</name></param>
+ <param><ptype>GLdouble</ptype> <name>v2</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform3dEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLdouble</ptype> <name>x</name></param>
+ <param><ptype>GLdouble</ptype> <name>y</name></param>
+ <param><ptype>GLdouble</ptype> <name>z</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform3dv</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="3">const <ptype>GLdouble</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform3dvEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count">const <ptype>GLdouble</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform3f</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLfloat</ptype> <name>v0</name></param>
+ <param><ptype>GLfloat</ptype> <name>v1</name></param>
+ <param><ptype>GLfloat</ptype> <name>v2</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform3fEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLfloat</ptype> <name>v0</name></param>
+ <param><ptype>GLfloat</ptype> <name>v1</name></param>
+ <param><ptype>GLfloat</ptype> <name>v2</name></param>
+ <alias name="glProgramUniform3f"/>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform3fv</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="3">const <ptype>GLfloat</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform3fvEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*3">const <ptype>GLfloat</ptype> *<name>value</name></param>
+ <alias name="glProgramUniform3fv"/>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform3i</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLint</ptype> <name>v0</name></param>
+ <param><ptype>GLint</ptype> <name>v1</name></param>
+ <param><ptype>GLint</ptype> <name>v2</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform3i64NV</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLint64EXT</ptype> <name>x</name></param>
+ <param><ptype>GLint64EXT</ptype> <name>y</name></param>
+ <param><ptype>GLint64EXT</ptype> <name>z</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform3i64vNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*3">const <ptype>GLint64EXT</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform3iEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLint</ptype> <name>v0</name></param>
+ <param><ptype>GLint</ptype> <name>v1</name></param>
+ <param><ptype>GLint</ptype> <name>v2</name></param>
+ <alias name="glProgramUniform3i"/>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform3iv</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="3">const <ptype>GLint</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform3ivEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*3">const <ptype>GLint</ptype> *<name>value</name></param>
+ <alias name="glProgramUniform3iv"/>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform3ui</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLuint</ptype> <name>v0</name></param>
+ <param><ptype>GLuint</ptype> <name>v1</name></param>
+ <param><ptype>GLuint</ptype> <name>v2</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform3ui64NV</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLuint64EXT</ptype> <name>x</name></param>
+ <param><ptype>GLuint64EXT</ptype> <name>y</name></param>
+ <param><ptype>GLuint64EXT</ptype> <name>z</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform3ui64vNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*3">const <ptype>GLuint64EXT</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform3uiEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLuint</ptype> <name>v0</name></param>
+ <param><ptype>GLuint</ptype> <name>v1</name></param>
+ <param><ptype>GLuint</ptype> <name>v2</name></param>
+ <alias name="glProgramUniform3ui"/>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform3uiv</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="3">const <ptype>GLuint</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform3uivEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*3">const <ptype>GLuint</ptype> *<name>value</name></param>
+ <alias name="glProgramUniform3uiv"/>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform4d</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLdouble</ptype> <name>v0</name></param>
+ <param><ptype>GLdouble</ptype> <name>v1</name></param>
+ <param><ptype>GLdouble</ptype> <name>v2</name></param>
+ <param><ptype>GLdouble</ptype> <name>v3</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform4dEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLdouble</ptype> <name>x</name></param>
+ <param><ptype>GLdouble</ptype> <name>y</name></param>
+ <param><ptype>GLdouble</ptype> <name>z</name></param>
+ <param><ptype>GLdouble</ptype> <name>w</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform4dv</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="4">const <ptype>GLdouble</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform4dvEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count">const <ptype>GLdouble</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform4f</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLfloat</ptype> <name>v0</name></param>
+ <param><ptype>GLfloat</ptype> <name>v1</name></param>
+ <param><ptype>GLfloat</ptype> <name>v2</name></param>
+ <param><ptype>GLfloat</ptype> <name>v3</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform4fEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLfloat</ptype> <name>v0</name></param>
+ <param><ptype>GLfloat</ptype> <name>v1</name></param>
+ <param><ptype>GLfloat</ptype> <name>v2</name></param>
+ <param><ptype>GLfloat</ptype> <name>v3</name></param>
+ <alias name="glProgramUniform4f"/>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform4fv</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="4">const <ptype>GLfloat</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform4fvEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*4">const <ptype>GLfloat</ptype> *<name>value</name></param>
+ <alias name="glProgramUniform4fv"/>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform4i</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLint</ptype> <name>v0</name></param>
+ <param><ptype>GLint</ptype> <name>v1</name></param>
+ <param><ptype>GLint</ptype> <name>v2</name></param>
+ <param><ptype>GLint</ptype> <name>v3</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform4i64NV</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLint64EXT</ptype> <name>x</name></param>
+ <param><ptype>GLint64EXT</ptype> <name>y</name></param>
+ <param><ptype>GLint64EXT</ptype> <name>z</name></param>
+ <param><ptype>GLint64EXT</ptype> <name>w</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform4i64vNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*4">const <ptype>GLint64EXT</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform4iEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLint</ptype> <name>v0</name></param>
+ <param><ptype>GLint</ptype> <name>v1</name></param>
+ <param><ptype>GLint</ptype> <name>v2</name></param>
+ <param><ptype>GLint</ptype> <name>v3</name></param>
+ <alias name="glProgramUniform4i"/>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform4iv</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="4">const <ptype>GLint</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform4ivEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*4">const <ptype>GLint</ptype> *<name>value</name></param>
+ <alias name="glProgramUniform4iv"/>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform4ui</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLuint</ptype> <name>v0</name></param>
+ <param><ptype>GLuint</ptype> <name>v1</name></param>
+ <param><ptype>GLuint</ptype> <name>v2</name></param>
+ <param><ptype>GLuint</ptype> <name>v3</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform4ui64NV</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLuint64EXT</ptype> <name>x</name></param>
+ <param><ptype>GLuint64EXT</ptype> <name>y</name></param>
+ <param><ptype>GLuint64EXT</ptype> <name>z</name></param>
+ <param><ptype>GLuint64EXT</ptype> <name>w</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform4ui64vNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*4">const <ptype>GLuint64EXT</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform4uiEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLuint</ptype> <name>v0</name></param>
+ <param><ptype>GLuint</ptype> <name>v1</name></param>
+ <param><ptype>GLuint</ptype> <name>v2</name></param>
+ <param><ptype>GLuint</ptype> <name>v3</name></param>
+ <alias name="glProgramUniform4ui"/>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform4uiv</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="4">const <ptype>GLuint</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniform4uivEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*4">const <ptype>GLuint</ptype> *<name>value</name></param>
+ <alias name="glProgramUniform4uiv"/>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniformHandleui64ARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLuint64</ptype> <name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniformHandleui64NV</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLuint64</ptype> <name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniformHandleui64vARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count">const <ptype>GLuint64</ptype> *<name>values</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniformHandleui64vNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count">const <ptype>GLuint64</ptype> *<name>values</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniformMatrix2dv</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="2">const <ptype>GLdouble</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniformMatrix2dvEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="count">const <ptype>GLdouble</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniformMatrix2fv</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="2">const <ptype>GLfloat</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniformMatrix2fvEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="count*4">const <ptype>GLfloat</ptype> *<name>value</name></param>
+ <alias name="glProgramUniformMatrix2fv"/>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniformMatrix2x3dv</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="count">const <ptype>GLdouble</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniformMatrix2x3dvEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="count">const <ptype>GLdouble</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniformMatrix2x3fv</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="count">const <ptype>GLfloat</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniformMatrix2x3fvEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="count*6">const <ptype>GLfloat</ptype> *<name>value</name></param>
+ <alias name="glProgramUniformMatrix2x3fv"/>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniformMatrix2x4dv</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="count">const <ptype>GLdouble</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniformMatrix2x4dvEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="count">const <ptype>GLdouble</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniformMatrix2x4fv</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="count">const <ptype>GLfloat</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniformMatrix2x4fvEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="count*8">const <ptype>GLfloat</ptype> *<name>value</name></param>
+ <alias name="glProgramUniformMatrix2x4fv"/>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniformMatrix3dv</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="3">const <ptype>GLdouble</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniformMatrix3dvEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="count">const <ptype>GLdouble</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniformMatrix3fv</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="3">const <ptype>GLfloat</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniformMatrix3fvEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="count*9">const <ptype>GLfloat</ptype> *<name>value</name></param>
+ <alias name="glProgramUniformMatrix3fv"/>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniformMatrix3x2dv</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="count">const <ptype>GLdouble</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniformMatrix3x2dvEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="count">const <ptype>GLdouble</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniformMatrix3x2fv</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="count">const <ptype>GLfloat</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniformMatrix3x2fvEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="count*6">const <ptype>GLfloat</ptype> *<name>value</name></param>
+ <alias name="glProgramUniformMatrix3x2fv"/>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniformMatrix3x4dv</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="count">const <ptype>GLdouble</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniformMatrix3x4dvEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="count">const <ptype>GLdouble</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniformMatrix3x4fv</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="count">const <ptype>GLfloat</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniformMatrix3x4fvEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="count*12">const <ptype>GLfloat</ptype> *<name>value</name></param>
+ <alias name="glProgramUniformMatrix3x4fv"/>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniformMatrix4dv</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="4">const <ptype>GLdouble</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniformMatrix4dvEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="count">const <ptype>GLdouble</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniformMatrix4fv</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="4">const <ptype>GLfloat</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniformMatrix4fvEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="count*16">const <ptype>GLfloat</ptype> *<name>value</name></param>
+ <alias name="glProgramUniformMatrix4fv"/>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniformMatrix4x2dv</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="count">const <ptype>GLdouble</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniformMatrix4x2dvEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="count">const <ptype>GLdouble</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniformMatrix4x2fv</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="count">const <ptype>GLfloat</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniformMatrix4x2fvEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="count*8">const <ptype>GLfloat</ptype> *<name>value</name></param>
+ <alias name="glProgramUniformMatrix4x2fv"/>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniformMatrix4x3dv</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="count">const <ptype>GLdouble</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniformMatrix4x3dvEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="count">const <ptype>GLdouble</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniformMatrix4x3fv</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="count">const <ptype>GLfloat</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniformMatrix4x3fvEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="count*12">const <ptype>GLfloat</ptype> *<name>value</name></param>
+ <alias name="glProgramUniformMatrix4x3fv"/>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniformui64NV</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLuint64EXT</ptype> <name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramUniformui64vNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count">const <ptype>GLuint64EXT</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProgramVertexLimitNV</name></proto>
+ <param group="ProgramTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLint</ptype> <name>limit</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProvokingVertex</name></proto>
+ <param><ptype>GLenum</ptype> <name>mode</name></param>
+ </command>
+ <command>
+ <proto>void <name>glProvokingVertexEXT</name></proto>
+ <param><ptype>GLenum</ptype> <name>mode</name></param>
+ <alias name="glProvokingVertex"/>
+ </command>
+ <command>
+ <proto>void <name>glPushAttrib</name></proto>
+ <param group="AttribMask"><ptype>GLbitfield</ptype> <name>mask</name></param>
+ <glx type="render" opcode="142"/>
+ </command>
+ <command>
+ <proto>void <name>glPushClientAttrib</name></proto>
+ <param group="ClientAttribMask"><ptype>GLbitfield</ptype> <name>mask</name></param>
+ </command>
+ <command>
+ <proto>void <name>glPushClientAttribDefaultEXT</name></proto>
+ <param group="ClientAttribMask"><ptype>GLbitfield</ptype> <name>mask</name></param>
+ </command>
+ <command>
+ <proto>void <name>glPushDebugGroup</name></proto>
+ <param><ptype>GLenum</ptype> <name>source</name></param>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <param><ptype>GLsizei</ptype> <name>length</name></param>
+ <param len="COMPSIZE(message,length)">const <ptype>GLchar</ptype> *<name>message</name></param>
+ </command>
+ <command>
+ <proto>void <name>glPushDebugGroupKHR</name></proto>
+ <param><ptype>GLenum</ptype> <name>source</name></param>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <param><ptype>GLsizei</ptype> <name>length</name></param>
+ <param>const <ptype>GLchar</ptype> *<name>message</name></param>
+ <alias name="glPushDebugGroup"/>
+ </command>
+ <command>
+ <proto>void <name>glPushGroupMarkerEXT</name></proto>
+ <param><ptype>GLsizei</ptype> <name>length</name></param>
+ <param>const <ptype>GLchar</ptype> *<name>marker</name></param>
+ </command>
+ <command>
+ <proto>void <name>glPushMatrix</name></proto>
+ <glx type="render" opcode="184"/>
+ </command>
+ <command>
+ <proto>void <name>glPushName</name></proto>
+ <param group="SelectName"><ptype>GLuint</ptype> <name>name</name></param>
+ <glx type="render" opcode="125"/>
+ </command>
+ <command>
+ <proto>void <name>glQueryCounter</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ </command>
+ <command>
+ <proto>void <name>glQueryCounterEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <alias name="glQueryCounter"/>
+ </command>
+ <command>
+ <proto><ptype>GLbitfield</ptype> <name>glQueryMatrixxOES</name></proto>
+ <param len="16"><ptype>GLfixed</ptype> *<name>mantissa</name></param>
+ <param len="16"><ptype>GLint</ptype> *<name>exponent</name></param>
+ </command>
+ <command>
+ <proto>void <name>glQueryObjectParameteruiAMD</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="OcclusionQueryEventMaskAMD"><ptype>GLuint</ptype> <name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glRasterPos2d</name></proto>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>x</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>y</name></param>
+ <vecequiv name="glRasterPos2dv"/>
+ </command>
+ <command>
+ <proto>void <name>glRasterPos2dv</name></proto>
+ <param group="CoordD" len="2">const <ptype>GLdouble</ptype> *<name>v</name></param>
+ <glx type="render" opcode="33"/>
+ </command>
+ <command>
+ <proto>void <name>glRasterPos2f</name></proto>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>x</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>y</name></param>
+ <vecequiv name="glRasterPos2fv"/>
+ </command>
+ <command>
+ <proto>void <name>glRasterPos2fv</name></proto>
+ <param group="CoordF" len="2">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ <glx type="render" opcode="34"/>
+ </command>
+ <command>
+ <proto>void <name>glRasterPos2i</name></proto>
+ <param group="CoordI"><ptype>GLint</ptype> <name>x</name></param>
+ <param group="CoordI"><ptype>GLint</ptype> <name>y</name></param>
+ <vecequiv name="glRasterPos2iv"/>
+ </command>
+ <command>
+ <proto>void <name>glRasterPos2iv</name></proto>
+ <param group="CoordI" len="2">const <ptype>GLint</ptype> *<name>v</name></param>
+ <glx type="render" opcode="35"/>
+ </command>
+ <command>
+ <proto>void <name>glRasterPos2s</name></proto>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>x</name></param>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>y</name></param>
+ <vecequiv name="glRasterPos2sv"/>
+ </command>
+ <command>
+ <proto>void <name>glRasterPos2sv</name></proto>
+ <param group="CoordS" len="2">const <ptype>GLshort</ptype> *<name>v</name></param>
+ <glx type="render" opcode="36"/>
+ </command>
+ <command>
+ <proto>void <name>glRasterPos2xOES</name></proto>
+ <param><ptype>GLfixed</ptype> <name>x</name></param>
+ <param><ptype>GLfixed</ptype> <name>y</name></param>
+ </command>
+ <command>
+ <proto>void <name>glRasterPos2xvOES</name></proto>
+ <param len="2">const <ptype>GLfixed</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glRasterPos3d</name></proto>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>x</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>y</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>z</name></param>
+ <vecequiv name="glRasterPos3dv"/>
+ </command>
+ <command>
+ <proto>void <name>glRasterPos3dv</name></proto>
+ <param group="CoordD" len="3">const <ptype>GLdouble</ptype> *<name>v</name></param>
+ <glx type="render" opcode="37"/>
+ </command>
+ <command>
+ <proto>void <name>glRasterPos3f</name></proto>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>x</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>y</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>z</name></param>
+ <vecequiv name="glRasterPos3fv"/>
+ </command>
+ <command>
+ <proto>void <name>glRasterPos3fv</name></proto>
+ <param group="CoordF" len="3">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ <glx type="render" opcode="38"/>
+ </command>
+ <command>
+ <proto>void <name>glRasterPos3i</name></proto>
+ <param group="CoordI"><ptype>GLint</ptype> <name>x</name></param>
+ <param group="CoordI"><ptype>GLint</ptype> <name>y</name></param>
+ <param group="CoordI"><ptype>GLint</ptype> <name>z</name></param>
+ <vecequiv name="glRasterPos3iv"/>
+ </command>
+ <command>
+ <proto>void <name>glRasterPos3iv</name></proto>
+ <param group="CoordI" len="3">const <ptype>GLint</ptype> *<name>v</name></param>
+ <glx type="render" opcode="39"/>
+ </command>
+ <command>
+ <proto>void <name>glRasterPos3s</name></proto>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>x</name></param>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>y</name></param>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>z</name></param>
+ <vecequiv name="glRasterPos3sv"/>
+ </command>
+ <command>
+ <proto>void <name>glRasterPos3sv</name></proto>
+ <param group="CoordS" len="3">const <ptype>GLshort</ptype> *<name>v</name></param>
+ <glx type="render" opcode="40"/>
+ </command>
+ <command>
+ <proto>void <name>glRasterPos3xOES</name></proto>
+ <param><ptype>GLfixed</ptype> <name>x</name></param>
+ <param><ptype>GLfixed</ptype> <name>y</name></param>
+ <param><ptype>GLfixed</ptype> <name>z</name></param>
+ </command>
+ <command>
+ <proto>void <name>glRasterPos3xvOES</name></proto>
+ <param len="3">const <ptype>GLfixed</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glRasterPos4d</name></proto>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>x</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>y</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>z</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>w</name></param>
+ <vecequiv name="glRasterPos4dv"/>
+ </command>
+ <command>
+ <proto>void <name>glRasterPos4dv</name></proto>
+ <param group="CoordD" len="4">const <ptype>GLdouble</ptype> *<name>v</name></param>
+ <glx type="render" opcode="41"/>
+ </command>
+ <command>
+ <proto>void <name>glRasterPos4f</name></proto>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>x</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>y</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>z</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>w</name></param>
+ <vecequiv name="glRasterPos4fv"/>
+ </command>
+ <command>
+ <proto>void <name>glRasterPos4fv</name></proto>
+ <param group="CoordF" len="4">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ <glx type="render" opcode="42"/>
+ </command>
+ <command>
+ <proto>void <name>glRasterPos4i</name></proto>
+ <param group="CoordI"><ptype>GLint</ptype> <name>x</name></param>
+ <param group="CoordI"><ptype>GLint</ptype> <name>y</name></param>
+ <param group="CoordI"><ptype>GLint</ptype> <name>z</name></param>
+ <param group="CoordI"><ptype>GLint</ptype> <name>w</name></param>
+ <vecequiv name="glRasterPos4iv"/>
+ </command>
+ <command>
+ <proto>void <name>glRasterPos4iv</name></proto>
+ <param group="CoordI" len="4">const <ptype>GLint</ptype> *<name>v</name></param>
+ <glx type="render" opcode="43"/>
+ </command>
+ <command>
+ <proto>void <name>glRasterPos4s</name></proto>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>x</name></param>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>y</name></param>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>z</name></param>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>w</name></param>
+ <vecequiv name="glRasterPos4sv"/>
+ </command>
+ <command>
+ <proto>void <name>glRasterPos4sv</name></proto>
+ <param group="CoordS" len="4">const <ptype>GLshort</ptype> *<name>v</name></param>
+ <glx type="render" opcode="44"/>
+ </command>
+ <command>
+ <proto>void <name>glRasterPos4xOES</name></proto>
+ <param><ptype>GLfixed</ptype> <name>x</name></param>
+ <param><ptype>GLfixed</ptype> <name>y</name></param>
+ <param><ptype>GLfixed</ptype> <name>z</name></param>
+ <param><ptype>GLfixed</ptype> <name>w</name></param>
+ </command>
+ <command>
+ <proto>void <name>glRasterPos4xvOES</name></proto>
+ <param len="4">const <ptype>GLfixed</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glReadBuffer</name></proto>
+ <param group="ReadBufferMode"><ptype>GLenum</ptype> <name>src</name></param>
+ <glx type="render" opcode="171"/>
+ </command>
+ <command>
+ <proto>void <name>glReadBufferIndexedEXT</name></proto>
+ <param><ptype>GLenum</ptype> <name>src</name></param>
+ <param><ptype>GLint</ptype> <name>index</name></param>
+ </command>
+ <command>
+ <proto>void <name>glReadBufferNV</name></proto>
+ <param><ptype>GLenum</ptype> <name>mode</name></param>
+ </command>
+ <command>
+ <proto>void <name>glReadInstrumentsSGIX</name></proto>
+ <param><ptype>GLint</ptype> <name>marker</name></param>
+ <glx type="render" opcode="2077"/>
+ </command>
+ <command>
+ <proto>void <name>glReadPixels</name></proto>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>x</name></param>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>y</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param group="PixelType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(format,type,width,height)">void *<name>pixels</name></param>
+ <glx type="single" opcode="111"/>
+ <glx type="render" opcode="345" name="glReadPixelsPBO" comment="PBO protocol"/>
+ </command>
+ <command>
+ <proto>void <name>glReadnPixels</name></proto>
+ <param><ptype>GLint</ptype> <name>x</name></param>
+ <param><ptype>GLint</ptype> <name>y</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param><ptype>GLenum</ptype> <name>format</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param>void *<name>data</name></param>
+ </command>
+ <command>
+ <proto>void <name>glReadnPixelsARB</name></proto>
+ <param><ptype>GLint</ptype> <name>x</name></param>
+ <param><ptype>GLint</ptype> <name>y</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param><ptype>GLenum</ptype> <name>format</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param len="bufSize">void *<name>data</name></param>
+ <alias name="glReadnPixels"/>
+ </command>
+ <command>
+ <proto>void <name>glReadnPixelsEXT</name></proto>
+ <param><ptype>GLint</ptype> <name>x</name></param>
+ <param><ptype>GLint</ptype> <name>y</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param><ptype>GLenum</ptype> <name>format</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param len="bufSize">void *<name>data</name></param>
+ <alias name="glReadnPixels"/>
+ </command>
+ <command>
+ <proto>void <name>glReadnPixelsKHR</name></proto>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>x</name></param>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>y</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param group="PixelType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param len="bufSize">void *<name>data</name></param>
+ <alias name="glReadnPixels"/>
+ </command>
+ <command>
+ <proto>void <name>glRectd</name></proto>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>x1</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>y1</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>x2</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>y2</name></param>
+ <vecequiv name="glRectdv"/>
+ </command>
+ <command>
+ <proto>void <name>glRectdv</name></proto>
+ <param group="CoordD" len="2">const <ptype>GLdouble</ptype> *<name>v1</name></param>
+ <param group="CoordD" len="2">const <ptype>GLdouble</ptype> *<name>v2</name></param>
+ <glx type="render" opcode="45"/>
+ </command>
+ <command>
+ <proto>void <name>glRectf</name></proto>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>x1</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>y1</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>x2</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>y2</name></param>
+ <vecequiv name="glRectfv"/>
+ </command>
+ <command>
+ <proto>void <name>glRectfv</name></proto>
+ <param group="CoordF" len="2">const <ptype>GLfloat</ptype> *<name>v1</name></param>
+ <param group="CoordF" len="2">const <ptype>GLfloat</ptype> *<name>v2</name></param>
+ <glx type="render" opcode="46"/>
+ </command>
+ <command>
+ <proto>void <name>glRecti</name></proto>
+ <param group="CoordI"><ptype>GLint</ptype> <name>x1</name></param>
+ <param group="CoordI"><ptype>GLint</ptype> <name>y1</name></param>
+ <param group="CoordI"><ptype>GLint</ptype> <name>x2</name></param>
+ <param group="CoordI"><ptype>GLint</ptype> <name>y2</name></param>
+ <vecequiv name="glRectiv"/>
+ </command>
+ <command>
+ <proto>void <name>glRectiv</name></proto>
+ <param group="CoordI" len="2">const <ptype>GLint</ptype> *<name>v1</name></param>
+ <param group="CoordI" len="2">const <ptype>GLint</ptype> *<name>v2</name></param>
+ <glx type="render" opcode="47"/>
+ </command>
+ <command>
+ <proto>void <name>glRects</name></proto>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>x1</name></param>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>y1</name></param>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>x2</name></param>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>y2</name></param>
+ <vecequiv name="glRectsv"/>
+ </command>
+ <command>
+ <proto>void <name>glRectsv</name></proto>
+ <param group="CoordS" len="2">const <ptype>GLshort</ptype> *<name>v1</name></param>
+ <param group="CoordS" len="2">const <ptype>GLshort</ptype> *<name>v2</name></param>
+ <glx type="render" opcode="48"/>
+ </command>
+ <command>
+ <proto>void <name>glRectxOES</name></proto>
+ <param><ptype>GLfixed</ptype> <name>x1</name></param>
+ <param><ptype>GLfixed</ptype> <name>y1</name></param>
+ <param><ptype>GLfixed</ptype> <name>x2</name></param>
+ <param><ptype>GLfixed</ptype> <name>y2</name></param>
+ </command>
+ <command>
+ <proto>void <name>glRectxvOES</name></proto>
+ <param len="2">const <ptype>GLfixed</ptype> *<name>v1</name></param>
+ <param len="2">const <ptype>GLfixed</ptype> *<name>v2</name></param>
+ </command>
+ <command>
+ <proto>void <name>glReferencePlaneSGIX</name></proto>
+ <param len="4">const <ptype>GLdouble</ptype> *<name>equation</name></param>
+ <glx type="render" opcode="2071"/>
+ </command>
+ <command>
+ <proto>void <name>glReleaseShaderCompiler</name></proto>
+ </command>
+ <command>
+ <proto><ptype>GLint</ptype> <name>glRenderMode</name></proto>
+ <param group="RenderingMode"><ptype>GLenum</ptype> <name>mode</name></param>
+ <glx type="single" opcode="107"/>
+ </command>
+ <command>
+ <proto>void <name>glRenderbufferStorage</name></proto>
+ <param group="RenderbufferTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <glx type="render" opcode="4318"/>
+ </command>
+ <command>
+ <proto>void <name>glRenderbufferStorageEXT</name></proto>
+ <param group="RenderbufferTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <alias name="glRenderbufferStorage"/>
+ <glx type="render" opcode="4318"/>
+ </command>
+ <command>
+ <proto>void <name>glRenderbufferStorageMultisample</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLsizei</ptype> <name>samples</name></param>
+ <param><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <glx type="render" opcode="4331"/>
+ </command>
+ <command>
+ <proto>void <name>glRenderbufferStorageMultisampleANGLE</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLsizei</ptype> <name>samples</name></param>
+ <param><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ </command>
+ <command>
+ <proto>void <name>glRenderbufferStorageMultisampleAPPLE</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLsizei</ptype> <name>samples</name></param>
+ <param><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ </command>
+ <command>
+ <proto>void <name>glRenderbufferStorageMultisampleCoverageNV</name></proto>
+ <param group="RenderbufferTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLsizei</ptype> <name>coverageSamples</name></param>
+ <param><ptype>GLsizei</ptype> <name>colorSamples</name></param>
+ <param group="PixelInternalFormat"><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ </command>
+ <command>
+ <proto>void <name>glRenderbufferStorageMultisampleEXT</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLsizei</ptype> <name>samples</name></param>
+ <param><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <alias name="glRenderbufferStorageMultisample"/>
+ <glx type="render" opcode="4331"/>
+ </command>
+ <command>
+ <proto>void <name>glRenderbufferStorageMultisampleIMG</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLsizei</ptype> <name>samples</name></param>
+ <param><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ </command>
+ <command>
+ <proto>void <name>glRenderbufferStorageMultisampleNV</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLsizei</ptype> <name>samples</name></param>
+ <param><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <alias name="glRenderbufferStorageMultisample"/>
+ </command>
+ <command>
+ <proto>void <name>glRenderbufferStorageOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ </command>
+ <command>
+ <proto>void <name>glReplacementCodePointerSUN</name></proto>
+ <param group="ReplacementCodeTypeSUN"><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ <param len="COMPSIZE(type,stride)">const void **<name>pointer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glReplacementCodeubSUN</name></proto>
+ <param><ptype>GLubyte</ptype> <name>code</name></param>
+ </command>
+ <command>
+ <proto>void <name>glReplacementCodeubvSUN</name></proto>
+ <param len="COMPSIZE()">const <ptype>GLubyte</ptype> *<name>code</name></param>
+ </command>
+ <command>
+ <proto>void <name>glReplacementCodeuiColor3fVertex3fSUN</name></proto>
+ <param group="ReplacementCodeSUN"><ptype>GLuint</ptype> <name>rc</name></param>
+ <param><ptype>GLfloat</ptype> <name>r</name></param>
+ <param><ptype>GLfloat</ptype> <name>g</name></param>
+ <param><ptype>GLfloat</ptype> <name>b</name></param>
+ <param><ptype>GLfloat</ptype> <name>x</name></param>
+ <param><ptype>GLfloat</ptype> <name>y</name></param>
+ <param><ptype>GLfloat</ptype> <name>z</name></param>
+ </command>
+ <command>
+ <proto>void <name>glReplacementCodeuiColor3fVertex3fvSUN</name></proto>
+ <param group="ReplacementCodeSUN" len="1">const <ptype>GLuint</ptype> *<name>rc</name></param>
+ <param len="3">const <ptype>GLfloat</ptype> *<name>c</name></param>
+ <param len="3">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glReplacementCodeuiColor4fNormal3fVertex3fSUN</name></proto>
+ <param group="ReplacementCodeSUN"><ptype>GLuint</ptype> <name>rc</name></param>
+ <param><ptype>GLfloat</ptype> <name>r</name></param>
+ <param><ptype>GLfloat</ptype> <name>g</name></param>
+ <param><ptype>GLfloat</ptype> <name>b</name></param>
+ <param><ptype>GLfloat</ptype> <name>a</name></param>
+ <param><ptype>GLfloat</ptype> <name>nx</name></param>
+ <param><ptype>GLfloat</ptype> <name>ny</name></param>
+ <param><ptype>GLfloat</ptype> <name>nz</name></param>
+ <param><ptype>GLfloat</ptype> <name>x</name></param>
+ <param><ptype>GLfloat</ptype> <name>y</name></param>
+ <param><ptype>GLfloat</ptype> <name>z</name></param>
+ </command>
+ <command>
+ <proto>void <name>glReplacementCodeuiColor4fNormal3fVertex3fvSUN</name></proto>
+ <param group="ReplacementCodeSUN" len="1">const <ptype>GLuint</ptype> *<name>rc</name></param>
+ <param len="4">const <ptype>GLfloat</ptype> *<name>c</name></param>
+ <param len="3">const <ptype>GLfloat</ptype> *<name>n</name></param>
+ <param len="3">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glReplacementCodeuiColor4ubVertex3fSUN</name></proto>
+ <param group="ReplacementCodeSUN"><ptype>GLuint</ptype> <name>rc</name></param>
+ <param><ptype>GLubyte</ptype> <name>r</name></param>
+ <param><ptype>GLubyte</ptype> <name>g</name></param>
+ <param><ptype>GLubyte</ptype> <name>b</name></param>
+ <param><ptype>GLubyte</ptype> <name>a</name></param>
+ <param><ptype>GLfloat</ptype> <name>x</name></param>
+ <param><ptype>GLfloat</ptype> <name>y</name></param>
+ <param><ptype>GLfloat</ptype> <name>z</name></param>
+ </command>
+ <command>
+ <proto>void <name>glReplacementCodeuiColor4ubVertex3fvSUN</name></proto>
+ <param group="ReplacementCodeSUN" len="1">const <ptype>GLuint</ptype> *<name>rc</name></param>
+ <param len="4">const <ptype>GLubyte</ptype> *<name>c</name></param>
+ <param len="3">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glReplacementCodeuiNormal3fVertex3fSUN</name></proto>
+ <param group="ReplacementCodeSUN"><ptype>GLuint</ptype> <name>rc</name></param>
+ <param><ptype>GLfloat</ptype> <name>nx</name></param>
+ <param><ptype>GLfloat</ptype> <name>ny</name></param>
+ <param><ptype>GLfloat</ptype> <name>nz</name></param>
+ <param><ptype>GLfloat</ptype> <name>x</name></param>
+ <param><ptype>GLfloat</ptype> <name>y</name></param>
+ <param><ptype>GLfloat</ptype> <name>z</name></param>
+ </command>
+ <command>
+ <proto>void <name>glReplacementCodeuiNormal3fVertex3fvSUN</name></proto>
+ <param group="ReplacementCodeSUN" len="1">const <ptype>GLuint</ptype> *<name>rc</name></param>
+ <param len="3">const <ptype>GLfloat</ptype> *<name>n</name></param>
+ <param len="3">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glReplacementCodeuiSUN</name></proto>
+ <param><ptype>GLuint</ptype> <name>code</name></param>
+ </command>
+ <command>
+ <proto>void <name>glReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fSUN</name></proto>
+ <param group="ReplacementCodeSUN"><ptype>GLuint</ptype> <name>rc</name></param>
+ <param><ptype>GLfloat</ptype> <name>s</name></param>
+ <param><ptype>GLfloat</ptype> <name>t</name></param>
+ <param><ptype>GLfloat</ptype> <name>r</name></param>
+ <param><ptype>GLfloat</ptype> <name>g</name></param>
+ <param><ptype>GLfloat</ptype> <name>b</name></param>
+ <param><ptype>GLfloat</ptype> <name>a</name></param>
+ <param><ptype>GLfloat</ptype> <name>nx</name></param>
+ <param><ptype>GLfloat</ptype> <name>ny</name></param>
+ <param><ptype>GLfloat</ptype> <name>nz</name></param>
+ <param><ptype>GLfloat</ptype> <name>x</name></param>
+ <param><ptype>GLfloat</ptype> <name>y</name></param>
+ <param><ptype>GLfloat</ptype> <name>z</name></param>
+ </command>
+ <command>
+ <proto>void <name>glReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fvSUN</name></proto>
+ <param group="ReplacementCodeSUN" len="1">const <ptype>GLuint</ptype> *<name>rc</name></param>
+ <param len="2">const <ptype>GLfloat</ptype> *<name>tc</name></param>
+ <param len="4">const <ptype>GLfloat</ptype> *<name>c</name></param>
+ <param len="3">const <ptype>GLfloat</ptype> *<name>n</name></param>
+ <param len="3">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glReplacementCodeuiTexCoord2fNormal3fVertex3fSUN</name></proto>
+ <param group="ReplacementCodeSUN"><ptype>GLuint</ptype> <name>rc</name></param>
+ <param><ptype>GLfloat</ptype> <name>s</name></param>
+ <param><ptype>GLfloat</ptype> <name>t</name></param>
+ <param><ptype>GLfloat</ptype> <name>nx</name></param>
+ <param><ptype>GLfloat</ptype> <name>ny</name></param>
+ <param><ptype>GLfloat</ptype> <name>nz</name></param>
+ <param><ptype>GLfloat</ptype> <name>x</name></param>
+ <param><ptype>GLfloat</ptype> <name>y</name></param>
+ <param><ptype>GLfloat</ptype> <name>z</name></param>
+ </command>
+ <command>
+ <proto>void <name>glReplacementCodeuiTexCoord2fNormal3fVertex3fvSUN</name></proto>
+ <param group="ReplacementCodeSUN" len="1">const <ptype>GLuint</ptype> *<name>rc</name></param>
+ <param len="2">const <ptype>GLfloat</ptype> *<name>tc</name></param>
+ <param len="3">const <ptype>GLfloat</ptype> *<name>n</name></param>
+ <param len="3">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glReplacementCodeuiTexCoord2fVertex3fSUN</name></proto>
+ <param group="ReplacementCodeSUN"><ptype>GLuint</ptype> <name>rc</name></param>
+ <param><ptype>GLfloat</ptype> <name>s</name></param>
+ <param><ptype>GLfloat</ptype> <name>t</name></param>
+ <param><ptype>GLfloat</ptype> <name>x</name></param>
+ <param><ptype>GLfloat</ptype> <name>y</name></param>
+ <param><ptype>GLfloat</ptype> <name>z</name></param>
+ </command>
+ <command>
+ <proto>void <name>glReplacementCodeuiTexCoord2fVertex3fvSUN</name></proto>
+ <param group="ReplacementCodeSUN" len="1">const <ptype>GLuint</ptype> *<name>rc</name></param>
+ <param len="2">const <ptype>GLfloat</ptype> *<name>tc</name></param>
+ <param len="3">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glReplacementCodeuiVertex3fSUN</name></proto>
+ <param group="ReplacementCodeSUN"><ptype>GLuint</ptype> <name>rc</name></param>
+ <param><ptype>GLfloat</ptype> <name>x</name></param>
+ <param><ptype>GLfloat</ptype> <name>y</name></param>
+ <param><ptype>GLfloat</ptype> <name>z</name></param>
+ </command>
+ <command>
+ <proto>void <name>glReplacementCodeuiVertex3fvSUN</name></proto>
+ <param group="ReplacementCodeSUN" len="1">const <ptype>GLuint</ptype> *<name>rc</name></param>
+ <param len="3">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glReplacementCodeuivSUN</name></proto>
+ <param len="COMPSIZE()">const <ptype>GLuint</ptype> *<name>code</name></param>
+ </command>
+ <command>
+ <proto>void <name>glReplacementCodeusSUN</name></proto>
+ <param><ptype>GLushort</ptype> <name>code</name></param>
+ </command>
+ <command>
+ <proto>void <name>glReplacementCodeusvSUN</name></proto>
+ <param len="COMPSIZE()">const <ptype>GLushort</ptype> *<name>code</name></param>
+ </command>
+ <command>
+ <proto>void <name>glRequestResidentProgramsNV</name></proto>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param len="n">const <ptype>GLuint</ptype> *<name>programs</name></param>
+ <glx type="render" opcode="4182"/>
+ </command>
+ <command>
+ <proto>void <name>glResetHistogram</name></proto>
+ <param group="HistogramTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <glx type="render" opcode="4112"/>
+ </command>
+ <command>
+ <proto>void <name>glResetHistogramEXT</name></proto>
+ <param group="HistogramTargetEXT"><ptype>GLenum</ptype> <name>target</name></param>
+ <alias name="glResetHistogram"/>
+ <glx type="render" opcode="4112"/>
+ </command>
+ <command>
+ <proto>void <name>glResetMinmax</name></proto>
+ <param group="MinmaxTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <glx type="render" opcode="4113"/>
+ </command>
+ <command>
+ <proto>void <name>glResetMinmaxEXT</name></proto>
+ <param group="MinmaxTargetEXT"><ptype>GLenum</ptype> <name>target</name></param>
+ <alias name="glResetMinmax"/>
+ <glx type="render" opcode="4113"/>
+ </command>
+ <command>
+ <proto>void <name>glResizeBuffersMESA</name></proto>
+ </command>
+ <command>
+ <proto>void <name>glResolveMultisampleFramebufferAPPLE</name></proto>
+ </command>
+ <command>
+ <proto>void <name>glResumeTransformFeedback</name></proto>
+ </command>
+ <command>
+ <proto>void <name>glResumeTransformFeedbackNV</name></proto>
+ <alias name="glResumeTransformFeedback"/>
+ </command>
+ <command>
+ <proto>void <name>glRotated</name></proto>
+ <param><ptype>GLdouble</ptype> <name>angle</name></param>
+ <param><ptype>GLdouble</ptype> <name>x</name></param>
+ <param><ptype>GLdouble</ptype> <name>y</name></param>
+ <param><ptype>GLdouble</ptype> <name>z</name></param>
+ <glx type="render" opcode="185"/>
+ </command>
+ <command>
+ <proto>void <name>glRotatef</name></proto>
+ <param><ptype>GLfloat</ptype> <name>angle</name></param>
+ <param><ptype>GLfloat</ptype> <name>x</name></param>
+ <param><ptype>GLfloat</ptype> <name>y</name></param>
+ <param><ptype>GLfloat</ptype> <name>z</name></param>
+ <glx type="render" opcode="186"/>
+ </command>
+ <command>
+ <proto>void <name>glRotatex</name></proto>
+ <param><ptype>GLfixed</ptype> <name>angle</name></param>
+ <param><ptype>GLfixed</ptype> <name>x</name></param>
+ <param><ptype>GLfixed</ptype> <name>y</name></param>
+ <param><ptype>GLfixed</ptype> <name>z</name></param>
+ </command>
+ <command>
+ <proto>void <name>glRotatexOES</name></proto>
+ <param><ptype>GLfixed</ptype> <name>angle</name></param>
+ <param><ptype>GLfixed</ptype> <name>x</name></param>
+ <param><ptype>GLfixed</ptype> <name>y</name></param>
+ <param><ptype>GLfixed</ptype> <name>z</name></param>
+ </command>
+ <command>
+ <proto>void <name>glSampleCoverage</name></proto>
+ <param><ptype>GLfloat</ptype> <name>value</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>invert</name></param>
+ <glx type="render" opcode="229"/>
+ </command>
+ <command>
+ <proto>void <name>glSampleCoverageARB</name></proto>
+ <param><ptype>GLfloat</ptype> <name>value</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>invert</name></param>
+ <alias name="glSampleCoverage"/>
+ </command>
+ <command>
+ <proto>void <name>glSampleCoverageOES</name></proto>
+ <param group="ClampedFixed"><ptype>GLfixed</ptype> <name>value</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>invert</name></param>
+ </command>
+ <command>
+ <proto>void <name>glSampleCoveragex</name></proto>
+ <param><ptype>GLclampx</ptype> <name>value</name></param>
+ <param><ptype>GLboolean</ptype> <name>invert</name></param>
+ </command>
+ <command>
+ <proto>void <name>glSampleCoveragexOES</name></proto>
+ <param><ptype>GLclampx</ptype> <name>value</name></param>
+ <param><ptype>GLboolean</ptype> <name>invert</name></param>
+ </command>
+ <command>
+ <proto>void <name>glSampleMapATI</name></proto>
+ <param><ptype>GLuint</ptype> <name>dst</name></param>
+ <param><ptype>GLuint</ptype> <name>interp</name></param>
+ <param group="SwizzleOpATI"><ptype>GLenum</ptype> <name>swizzle</name></param>
+ </command>
+ <command>
+ <proto>void <name>glSampleMaskEXT</name></proto>
+ <param group="ClampedFloat32"><ptype>GLclampf</ptype> <name>value</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>invert</name></param>
+ </command>
+ <command>
+ <proto>void <name>glSampleMaskIndexedNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param group="SampleMaskNV"><ptype>GLbitfield</ptype> <name>mask</name></param>
+ </command>
+ <command>
+ <proto>void <name>glSampleMaskSGIS</name></proto>
+ <param group="ClampedFloat32"><ptype>GLclampf</ptype> <name>value</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>invert</name></param>
+ <alias name="glSampleMaskEXT"/>
+ <glx type="render" opcode="2048"/>
+ </command>
+ <command>
+ <proto>void <name>glSampleMaski</name></proto>
+ <param><ptype>GLuint</ptype> <name>maskNumber</name></param>
+ <param><ptype>GLbitfield</ptype> <name>mask</name></param>
+ </command>
+ <command>
+ <proto>void <name>glSamplePatternEXT</name></proto>
+ <param group="SamplePatternEXT"><ptype>GLenum</ptype> <name>pattern</name></param>
+ </command>
+ <command>
+ <proto>void <name>glSamplePatternSGIS</name></proto>
+ <param group="SamplePatternSGIS"><ptype>GLenum</ptype> <name>pattern</name></param>
+ <alias name="glSamplePatternEXT"/>
+ <glx type="render" opcode="2049"/>
+ </command>
+ <command>
+ <proto>void <name>glSamplerParameterIiv</name></proto>
+ <param><ptype>GLuint</ptype> <name>sampler</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)">const <ptype>GLint</ptype> *<name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glSamplerParameterIivEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>sampler</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)">const <ptype>GLint</ptype> *<name>param</name></param>
+ <alias name="glSamplerParameterIiv"/>
+ </command>
+ <command>
+ <proto>void <name>glSamplerParameterIuiv</name></proto>
+ <param><ptype>GLuint</ptype> <name>sampler</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)">const <ptype>GLuint</ptype> *<name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glSamplerParameterIuivEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>sampler</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)">const <ptype>GLuint</ptype> *<name>param</name></param>
+ <alias name="glSamplerParameterIuiv"/>
+ </command>
+ <command>
+ <proto>void <name>glSamplerParameterf</name></proto>
+ <param><ptype>GLuint</ptype> <name>sampler</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLfloat</ptype> <name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glSamplerParameterfv</name></proto>
+ <param><ptype>GLuint</ptype> <name>sampler</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)">const <ptype>GLfloat</ptype> *<name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glSamplerParameteri</name></proto>
+ <param><ptype>GLuint</ptype> <name>sampler</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLint</ptype> <name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glSamplerParameteriv</name></proto>
+ <param><ptype>GLuint</ptype> <name>sampler</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)">const <ptype>GLint</ptype> *<name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glScaled</name></proto>
+ <param><ptype>GLdouble</ptype> <name>x</name></param>
+ <param><ptype>GLdouble</ptype> <name>y</name></param>
+ <param><ptype>GLdouble</ptype> <name>z</name></param>
+ <glx type="render" opcode="187"/>
+ </command>
+ <command>
+ <proto>void <name>glScalef</name></proto>
+ <param><ptype>GLfloat</ptype> <name>x</name></param>
+ <param><ptype>GLfloat</ptype> <name>y</name></param>
+ <param><ptype>GLfloat</ptype> <name>z</name></param>
+ <glx type="render" opcode="188"/>
+ </command>
+ <command>
+ <proto>void <name>glScalex</name></proto>
+ <param><ptype>GLfixed</ptype> <name>x</name></param>
+ <param><ptype>GLfixed</ptype> <name>y</name></param>
+ <param><ptype>GLfixed</ptype> <name>z</name></param>
+ </command>
+ <command>
+ <proto>void <name>glScalexOES</name></proto>
+ <param><ptype>GLfixed</ptype> <name>x</name></param>
+ <param><ptype>GLfixed</ptype> <name>y</name></param>
+ <param><ptype>GLfixed</ptype> <name>z</name></param>
+ </command>
+ <command>
+ <proto>void <name>glScissor</name></proto>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>x</name></param>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>y</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <glx type="render" opcode="103"/>
+ </command>
+ <command>
+ <proto>void <name>glScissorArrayv</name></proto>
+ <param><ptype>GLuint</ptype> <name>first</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="COMPSIZE(count)">const <ptype>GLint</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glScissorIndexed</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLint</ptype> <name>left</name></param>
+ <param><ptype>GLint</ptype> <name>bottom</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ </command>
+ <command>
+ <proto>void <name>glScissorIndexedv</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLint</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glSecondaryColor3b</name></proto>
+ <param group="ColorB"><ptype>GLbyte</ptype> <name>red</name></param>
+ <param group="ColorB"><ptype>GLbyte</ptype> <name>green</name></param>
+ <param group="ColorB"><ptype>GLbyte</ptype> <name>blue</name></param>
+ <vecequiv name="glSecondaryColor3bv"/>
+ </command>
+ <command>
+ <proto>void <name>glSecondaryColor3bEXT</name></proto>
+ <param group="ColorB"><ptype>GLbyte</ptype> <name>red</name></param>
+ <param group="ColorB"><ptype>GLbyte</ptype> <name>green</name></param>
+ <param group="ColorB"><ptype>GLbyte</ptype> <name>blue</name></param>
+ <alias name="glSecondaryColor3b"/>
+ <vecequiv name="glSecondaryColor3bvEXT"/>
+ </command>
+ <command>
+ <proto>void <name>glSecondaryColor3bv</name></proto>
+ <param group="ColorB" len="3">const <ptype>GLbyte</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4126"/>
+ </command>
+ <command>
+ <proto>void <name>glSecondaryColor3bvEXT</name></proto>
+ <param group="ColorB" len="3">const <ptype>GLbyte</ptype> *<name>v</name></param>
+ <alias name="glSecondaryColor3bv"/>
+ <glx type="render" opcode="4126"/>
+ </command>
+ <command>
+ <proto>void <name>glSecondaryColor3d</name></proto>
+ <param group="ColorD"><ptype>GLdouble</ptype> <name>red</name></param>
+ <param group="ColorD"><ptype>GLdouble</ptype> <name>green</name></param>
+ <param group="ColorD"><ptype>GLdouble</ptype> <name>blue</name></param>
+ <vecequiv name="glSecondaryColor3dv"/>
+ </command>
+ <command>
+ <proto>void <name>glSecondaryColor3dEXT</name></proto>
+ <param group="ColorD"><ptype>GLdouble</ptype> <name>red</name></param>
+ <param group="ColorD"><ptype>GLdouble</ptype> <name>green</name></param>
+ <param group="ColorD"><ptype>GLdouble</ptype> <name>blue</name></param>
+ <alias name="glSecondaryColor3d"/>
+ <vecequiv name="glSecondaryColor3dvEXT"/>
+ </command>
+ <command>
+ <proto>void <name>glSecondaryColor3dv</name></proto>
+ <param group="ColorD" len="3">const <ptype>GLdouble</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4130"/>
+ </command>
+ <command>
+ <proto>void <name>glSecondaryColor3dvEXT</name></proto>
+ <param group="ColorD" len="3">const <ptype>GLdouble</ptype> *<name>v</name></param>
+ <alias name="glSecondaryColor3dv"/>
+ <glx type="render" opcode="4130"/>
+ </command>
+ <command>
+ <proto>void <name>glSecondaryColor3f</name></proto>
+ <param group="ColorF"><ptype>GLfloat</ptype> <name>red</name></param>
+ <param group="ColorF"><ptype>GLfloat</ptype> <name>green</name></param>
+ <param group="ColorF"><ptype>GLfloat</ptype> <name>blue</name></param>
+ <vecequiv name="glSecondaryColor3fv"/>
+ </command>
+ <command>
+ <proto>void <name>glSecondaryColor3fEXT</name></proto>
+ <param group="ColorF"><ptype>GLfloat</ptype> <name>red</name></param>
+ <param group="ColorF"><ptype>GLfloat</ptype> <name>green</name></param>
+ <param group="ColorF"><ptype>GLfloat</ptype> <name>blue</name></param>
+ <alias name="glSecondaryColor3f"/>
+ <vecequiv name="glSecondaryColor3fvEXT"/>
+ </command>
+ <command>
+ <proto>void <name>glSecondaryColor3fv</name></proto>
+ <param group="ColorF" len="3">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4129"/>
+ </command>
+ <command>
+ <proto>void <name>glSecondaryColor3fvEXT</name></proto>
+ <param group="ColorF" len="3">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ <alias name="glSecondaryColor3fv"/>
+ <glx type="render" opcode="4129"/>
+ </command>
+ <command>
+ <proto>void <name>glSecondaryColor3hNV</name></proto>
+ <param group="Half16NV"><ptype>GLhalfNV</ptype> <name>red</name></param>
+ <param group="Half16NV"><ptype>GLhalfNV</ptype> <name>green</name></param>
+ <param group="Half16NV"><ptype>GLhalfNV</ptype> <name>blue</name></param>
+ <vecequiv name="glSecondaryColor3hvNV"/>
+ </command>
+ <command>
+ <proto>void <name>glSecondaryColor3hvNV</name></proto>
+ <param group="Half16NV" len="3">const <ptype>GLhalfNV</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4255"/>
+ </command>
+ <command>
+ <proto>void <name>glSecondaryColor3i</name></proto>
+ <param group="ColorI"><ptype>GLint</ptype> <name>red</name></param>
+ <param group="ColorI"><ptype>GLint</ptype> <name>green</name></param>
+ <param group="ColorI"><ptype>GLint</ptype> <name>blue</name></param>
+ <vecequiv name="glSecondaryColor3iv"/>
+ </command>
+ <command>
+ <proto>void <name>glSecondaryColor3iEXT</name></proto>
+ <param group="ColorI"><ptype>GLint</ptype> <name>red</name></param>
+ <param group="ColorI"><ptype>GLint</ptype> <name>green</name></param>
+ <param group="ColorI"><ptype>GLint</ptype> <name>blue</name></param>
+ <alias name="glSecondaryColor3i"/>
+ <vecequiv name="glSecondaryColor3ivEXT"/>
+ </command>
+ <command>
+ <proto>void <name>glSecondaryColor3iv</name></proto>
+ <param group="ColorI" len="3">const <ptype>GLint</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4128"/>
+ </command>
+ <command>
+ <proto>void <name>glSecondaryColor3ivEXT</name></proto>
+ <param group="ColorI" len="3">const <ptype>GLint</ptype> *<name>v</name></param>
+ <alias name="glSecondaryColor3iv"/>
+ <glx type="render" opcode="4128"/>
+ </command>
+ <command>
+ <proto>void <name>glSecondaryColor3s</name></proto>
+ <param group="ColorS"><ptype>GLshort</ptype> <name>red</name></param>
+ <param group="ColorS"><ptype>GLshort</ptype> <name>green</name></param>
+ <param group="ColorS"><ptype>GLshort</ptype> <name>blue</name></param>
+ <vecequiv name="glSecondaryColor3sv"/>
+ </command>
+ <command>
+ <proto>void <name>glSecondaryColor3sEXT</name></proto>
+ <param group="ColorS"><ptype>GLshort</ptype> <name>red</name></param>
+ <param group="ColorS"><ptype>GLshort</ptype> <name>green</name></param>
+ <param group="ColorS"><ptype>GLshort</ptype> <name>blue</name></param>
+ <alias name="glSecondaryColor3s"/>
+ <vecequiv name="glSecondaryColor3svEXT"/>
+ </command>
+ <command>
+ <proto>void <name>glSecondaryColor3sv</name></proto>
+ <param group="ColorS" len="3">const <ptype>GLshort</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4127"/>
+ </command>
+ <command>
+ <proto>void <name>glSecondaryColor3svEXT</name></proto>
+ <param group="ColorS" len="3">const <ptype>GLshort</ptype> *<name>v</name></param>
+ <alias name="glSecondaryColor3sv"/>
+ <glx type="render" opcode="4127"/>
+ </command>
+ <command>
+ <proto>void <name>glSecondaryColor3ub</name></proto>
+ <param group="ColorUB"><ptype>GLubyte</ptype> <name>red</name></param>
+ <param group="ColorUB"><ptype>GLubyte</ptype> <name>green</name></param>
+ <param group="ColorUB"><ptype>GLubyte</ptype> <name>blue</name></param>
+ <vecequiv name="glSecondaryColor3ubv"/>
+ </command>
+ <command>
+ <proto>void <name>glSecondaryColor3ubEXT</name></proto>
+ <param group="ColorUB"><ptype>GLubyte</ptype> <name>red</name></param>
+ <param group="ColorUB"><ptype>GLubyte</ptype> <name>green</name></param>
+ <param group="ColorUB"><ptype>GLubyte</ptype> <name>blue</name></param>
+ <alias name="glSecondaryColor3ub"/>
+ <vecequiv name="glSecondaryColor3ubvEXT"/>
+ </command>
+ <command>
+ <proto>void <name>glSecondaryColor3ubv</name></proto>
+ <param group="ColorUB" len="3">const <ptype>GLubyte</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4131"/>
+ </command>
+ <command>
+ <proto>void <name>glSecondaryColor3ubvEXT</name></proto>
+ <param group="ColorUB" len="3">const <ptype>GLubyte</ptype> *<name>v</name></param>
+ <alias name="glSecondaryColor3ubv"/>
+ <glx type="render" opcode="4131"/>
+ </command>
+ <command>
+ <proto>void <name>glSecondaryColor3ui</name></proto>
+ <param group="ColorUI"><ptype>GLuint</ptype> <name>red</name></param>
+ <param group="ColorUI"><ptype>GLuint</ptype> <name>green</name></param>
+ <param group="ColorUI"><ptype>GLuint</ptype> <name>blue</name></param>
+ <vecequiv name="glSecondaryColor3uiv"/>
+ </command>
+ <command>
+ <proto>void <name>glSecondaryColor3uiEXT</name></proto>
+ <param group="ColorUI"><ptype>GLuint</ptype> <name>red</name></param>
+ <param group="ColorUI"><ptype>GLuint</ptype> <name>green</name></param>
+ <param group="ColorUI"><ptype>GLuint</ptype> <name>blue</name></param>
+ <alias name="glSecondaryColor3ui"/>
+ <vecequiv name="glSecondaryColor3uivEXT"/>
+ </command>
+ <command>
+ <proto>void <name>glSecondaryColor3uiv</name></proto>
+ <param group="ColorUI" len="3">const <ptype>GLuint</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4133"/>
+ </command>
+ <command>
+ <proto>void <name>glSecondaryColor3uivEXT</name></proto>
+ <param group="ColorUI" len="3">const <ptype>GLuint</ptype> *<name>v</name></param>
+ <alias name="glSecondaryColor3uiv"/>
+ <glx type="render" opcode="4133"/>
+ </command>
+ <command>
+ <proto>void <name>glSecondaryColor3us</name></proto>
+ <param group="ColorUS"><ptype>GLushort</ptype> <name>red</name></param>
+ <param group="ColorUS"><ptype>GLushort</ptype> <name>green</name></param>
+ <param group="ColorUS"><ptype>GLushort</ptype> <name>blue</name></param>
+ <vecequiv name="glSecondaryColor3usv"/>
+ </command>
+ <command>
+ <proto>void <name>glSecondaryColor3usEXT</name></proto>
+ <param group="ColorUS"><ptype>GLushort</ptype> <name>red</name></param>
+ <param group="ColorUS"><ptype>GLushort</ptype> <name>green</name></param>
+ <param group="ColorUS"><ptype>GLushort</ptype> <name>blue</name></param>
+ <alias name="glSecondaryColor3us"/>
+ <vecequiv name="glSecondaryColor3usvEXT"/>
+ </command>
+ <command>
+ <proto>void <name>glSecondaryColor3usv</name></proto>
+ <param group="ColorUS" len="3">const <ptype>GLushort</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4132"/>
+ </command>
+ <command>
+ <proto>void <name>glSecondaryColor3usvEXT</name></proto>
+ <param group="ColorUS" len="3">const <ptype>GLushort</ptype> *<name>v</name></param>
+ <alias name="glSecondaryColor3usv"/>
+ <glx type="render" opcode="4132"/>
+ </command>
+ <command>
+ <proto>void <name>glSecondaryColorFormatNV</name></proto>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ </command>
+ <command>
+ <proto>void <name>glSecondaryColorP3ui</name></proto>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLuint</ptype> <name>color</name></param>
+ </command>
+ <command>
+ <proto>void <name>glSecondaryColorP3uiv</name></proto>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="1">const <ptype>GLuint</ptype> *<name>color</name></param>
+ </command>
+ <command>
+ <proto>void <name>glSecondaryColorPointer</name></proto>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param group="ColorPointerType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ <param len="COMPSIZE(size,type,stride)">const void *<name>pointer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glSecondaryColorPointerEXT</name></proto>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param group="ColorPointerType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ <param len="COMPSIZE(size,type,stride)">const void *<name>pointer</name></param>
+ <alias name="glSecondaryColorPointer"/>
+ </command>
+ <command>
+ <proto>void <name>glSecondaryColorPointerListIBM</name></proto>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param group="SecondaryColorPointerTypeIBM"><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLint</ptype> <name>stride</name></param>
+ <param len="COMPSIZE(size,type,stride)">const void **<name>pointer</name></param>
+ <param><ptype>GLint</ptype> <name>ptrstride</name></param>
+ </command>
+ <command>
+ <proto>void <name>glSelectBuffer</name></proto>
+ <param><ptype>GLsizei</ptype> <name>size</name></param>
+ <param group="SelectName" len="size"><ptype>GLuint</ptype> *<name>buffer</name></param>
+ <glx type="single" opcode="106"/>
+ </command>
+ <command>
+ <proto>void <name>glSelectPerfMonitorCountersAMD</name></proto>
+ <param><ptype>GLuint</ptype> <name>monitor</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>enable</name></param>
+ <param><ptype>GLuint</ptype> <name>group</name></param>
+ <param><ptype>GLint</ptype> <name>numCounters</name></param>
+ <param len="numCounters"><ptype>GLuint</ptype> *<name>counterList</name></param>
+ </command>
+ <command>
+ <proto>void <name>glSeparableFilter2D</name></proto>
+ <param group="SeparableTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="PixelInternalFormat"><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param group="PixelType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(target,format,type,width)">const void *<name>row</name></param>
+ <param len="COMPSIZE(target,format,type,height)">const void *<name>column</name></param>
+ <glx type="render" opcode="4109"/>
+ <glx type="render" opcode="327" name="glSeparableFilter2DPBO" comment="PBO protocol"/>
+ </command>
+ <command>
+ <proto>void <name>glSeparableFilter2DEXT</name></proto>
+ <param group="SeparableTargetEXT"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="PixelInternalFormat"><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param group="PixelType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(target,format,type,width)">const void *<name>row</name></param>
+ <param len="COMPSIZE(target,format,type,height)">const void *<name>column</name></param>
+ <alias name="glSeparableFilter2D"/>
+ <glx type="render" opcode="4109"/>
+ </command>
+ <command>
+ <proto>void <name>glSetFenceAPPLE</name></proto>
+ <param group="FenceNV"><ptype>GLuint</ptype> <name>fence</name></param>
+ </command>
+ <command>
+ <proto>void <name>glSetFenceNV</name></proto>
+ <param group="FenceNV"><ptype>GLuint</ptype> <name>fence</name></param>
+ <param group="FenceConditionNV"><ptype>GLenum</ptype> <name>condition</name></param>
+ </command>
+ <command>
+ <proto>void <name>glSetFragmentShaderConstantATI</name></proto>
+ <param><ptype>GLuint</ptype> <name>dst</name></param>
+ <param len="4">const <ptype>GLfloat</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glSetInvariantEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <param group="ScalarType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(id,type)">const void *<name>addr</name></param>
+ </command>
+ <command>
+ <proto>void <name>glSetLocalConstantEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <param group="ScalarType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(id,type)">const void *<name>addr</name></param>
+ </command>
+ <command>
+ <proto>void <name>glSetMultisamplefvAMD</name></proto>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="2">const <ptype>GLfloat</ptype> *<name>val</name></param>
+ </command>
+ <command>
+ <proto>void <name>glShadeModel</name></proto>
+ <param group="ShadingModel"><ptype>GLenum</ptype> <name>mode</name></param>
+ <glx type="render" opcode="104"/>
+ </command>
+ <command>
+ <proto>void <name>glShaderBinary</name></proto>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count">const <ptype>GLuint</ptype> *<name>shaders</name></param>
+ <param><ptype>GLenum</ptype> <name>binaryformat</name></param>
+ <param len="length">const void *<name>binary</name></param>
+ <param><ptype>GLsizei</ptype> <name>length</name></param>
+ </command>
+ <command>
+ <proto>void <name>glShaderOp1EXT</name></proto>
+ <param group="VertexShaderOpEXT"><ptype>GLenum</ptype> <name>op</name></param>
+ <param><ptype>GLuint</ptype> <name>res</name></param>
+ <param><ptype>GLuint</ptype> <name>arg1</name></param>
+ </command>
+ <command>
+ <proto>void <name>glShaderOp2EXT</name></proto>
+ <param group="VertexShaderOpEXT"><ptype>GLenum</ptype> <name>op</name></param>
+ <param><ptype>GLuint</ptype> <name>res</name></param>
+ <param><ptype>GLuint</ptype> <name>arg1</name></param>
+ <param><ptype>GLuint</ptype> <name>arg2</name></param>
+ </command>
+ <command>
+ <proto>void <name>glShaderOp3EXT</name></proto>
+ <param group="VertexShaderOpEXT"><ptype>GLenum</ptype> <name>op</name></param>
+ <param><ptype>GLuint</ptype> <name>res</name></param>
+ <param><ptype>GLuint</ptype> <name>arg1</name></param>
+ <param><ptype>GLuint</ptype> <name>arg2</name></param>
+ <param><ptype>GLuint</ptype> <name>arg3</name></param>
+ </command>
+ <command>
+ <proto>void <name>glShaderSource</name></proto>
+ <param><ptype>GLuint</ptype> <name>shader</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count">const <ptype>GLchar</ptype> *const*<name>string</name></param>
+ <param len="count">const <ptype>GLint</ptype> *<name>length</name></param>
+ </command>
+ <command>
+ <proto>void <name>glShaderSourceARB</name></proto>
+ <param group="handleARB"><ptype>GLhandleARB</ptype> <name>shaderObj</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count">const <ptype>GLcharARB</ptype> **<name>string</name></param>
+ <param len="count">const <ptype>GLint</ptype> *<name>length</name></param>
+ <alias name="glShaderSource"/>
+ </command>
+ <command>
+ <proto>void <name>glShaderStorageBlockBinding</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLuint</ptype> <name>storageBlockIndex</name></param>
+ <param><ptype>GLuint</ptype> <name>storageBlockBinding</name></param>
+ </command>
+ <command>
+ <proto>void <name>glSharpenTexFuncSGIS</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param len="n*2">const <ptype>GLfloat</ptype> *<name>points</name></param>
+ <glx type="render" opcode="2052"/>
+ </command>
+ <command>
+ <proto>void <name>glSpriteParameterfSGIX</name></proto>
+ <param group="SpriteParameterNameSGIX"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedFloat32"><ptype>GLfloat</ptype> <name>param</name></param>
+ <glx type="render" opcode="2060"/>
+ </command>
+ <command>
+ <proto>void <name>glSpriteParameterfvSGIX</name></proto>
+ <param group="SpriteParameterNameSGIX"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedFloat32" len="COMPSIZE(pname)">const <ptype>GLfloat</ptype> *<name>params</name></param>
+ <glx type="render" opcode="2061"/>
+ </command>
+ <command>
+ <proto>void <name>glSpriteParameteriSGIX</name></proto>
+ <param group="SpriteParameterNameSGIX"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>param</name></param>
+ <glx type="render" opcode="2062"/>
+ </command>
+ <command>
+ <proto>void <name>glSpriteParameterivSGIX</name></proto>
+ <param group="SpriteParameterNameSGIX"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedInt32" len="COMPSIZE(pname)">const <ptype>GLint</ptype> *<name>params</name></param>
+ <glx type="render" opcode="2063"/>
+ </command>
+ <command>
+ <proto>void <name>glStartInstrumentsSGIX</name></proto>
+ <glx type="render" opcode="2069"/>
+ </command>
+ <command>
+ <proto>void <name>glStartTilingQCOM</name></proto>
+ <param><ptype>GLuint</ptype> <name>x</name></param>
+ <param><ptype>GLuint</ptype> <name>y</name></param>
+ <param><ptype>GLuint</ptype> <name>width</name></param>
+ <param><ptype>GLuint</ptype> <name>height</name></param>
+ <param><ptype>GLbitfield</ptype> <name>preserveMask</name></param>
+ </command>
+ <command>
+ <proto>void <name>glStencilClearTagEXT</name></proto>
+ <param><ptype>GLsizei</ptype> <name>stencilTagBits</name></param>
+ <param><ptype>GLuint</ptype> <name>stencilClearTag</name></param>
+ <glx type="render" opcode="4223"/>
+ </command>
+ <command>
+ <proto>void <name>glStencilFillPathInstancedNV</name></proto>
+ <param><ptype>GLsizei</ptype> <name>numPaths</name></param>
+ <param group="PathElementType"><ptype>GLenum</ptype> <name>pathNameType</name></param>
+ <param group="PathElement" len="COMPSIZE(numPaths,pathNameType,paths)">const void *<name>paths</name></param>
+ <param group="Path"><ptype>GLuint</ptype> <name>pathBase</name></param>
+ <param group="PathFillMode"><ptype>GLenum</ptype> <name>fillMode</name></param>
+ <param group="MaskedStencilValue"><ptype>GLuint</ptype> <name>mask</name></param>
+ <param group="PathTransformType"><ptype>GLenum</ptype> <name>transformType</name></param>
+ <param len="COMPSIZE(numPaths,transformType)">const <ptype>GLfloat</ptype> *<name>transformValues</name></param>
+ </command>
+ <command>
+ <proto>void <name>glStencilFillPathNV</name></proto>
+ <param group="Path"><ptype>GLuint</ptype> <name>path</name></param>
+ <param group="PathFillMode"><ptype>GLenum</ptype> <name>fillMode</name></param>
+ <param group="MaskedStencilValue"><ptype>GLuint</ptype> <name>mask</name></param>
+ </command>
+ <command>
+ <proto>void <name>glStencilFunc</name></proto>
+ <param group="StencilFunction"><ptype>GLenum</ptype> <name>func</name></param>
+ <param group="StencilValue"><ptype>GLint</ptype> <name>ref</name></param>
+ <param group="MaskedStencilValue"><ptype>GLuint</ptype> <name>mask</name></param>
+ <glx type="render" opcode="162"/>
+ </command>
+ <command>
+ <proto>void <name>glStencilFuncSeparate</name></proto>
+ <param group="StencilFaceDirection"><ptype>GLenum</ptype> <name>face</name></param>
+ <param group="StencilFunction"><ptype>GLenum</ptype> <name>func</name></param>
+ <param group="StencilValue"><ptype>GLint</ptype> <name>ref</name></param>
+ <param group="MaskedStencilValue"><ptype>GLuint</ptype> <name>mask</name></param>
+ </command>
+ <command>
+ <proto>void <name>glStencilFuncSeparateATI</name></proto>
+ <param group="StencilFunction"><ptype>GLenum</ptype> <name>frontfunc</name></param>
+ <param group="StencilFunction"><ptype>GLenum</ptype> <name>backfunc</name></param>
+ <param group="ClampedStencilValue"><ptype>GLint</ptype> <name>ref</name></param>
+ <param group="MaskedStencilValue"><ptype>GLuint</ptype> <name>mask</name></param>
+ </command>
+ <command>
+ <proto>void <name>glStencilMask</name></proto>
+ <param group="MaskedStencilValue"><ptype>GLuint</ptype> <name>mask</name></param>
+ <glx type="render" opcode="133"/>
+ </command>
+ <command>
+ <proto>void <name>glStencilMaskSeparate</name></proto>
+ <param group="StencilFaceDirection"><ptype>GLenum</ptype> <name>face</name></param>
+ <param group="MaskedStencilValue"><ptype>GLuint</ptype> <name>mask</name></param>
+ </command>
+ <command>
+ <proto>void <name>glStencilOp</name></proto>
+ <param group="StencilOp"><ptype>GLenum</ptype> <name>fail</name></param>
+ <param group="StencilOp"><ptype>GLenum</ptype> <name>zfail</name></param>
+ <param group="StencilOp"><ptype>GLenum</ptype> <name>zpass</name></param>
+ <glx type="render" opcode="163"/>
+ </command>
+ <command>
+ <proto>void <name>glStencilOpSeparate</name></proto>
+ <param group="StencilFaceDirection"><ptype>GLenum</ptype> <name>face</name></param>
+ <param group="StencilOp"><ptype>GLenum</ptype> <name>sfail</name></param>
+ <param group="StencilOp"><ptype>GLenum</ptype> <name>dpfail</name></param>
+ <param group="StencilOp"><ptype>GLenum</ptype> <name>dppass</name></param>
+ </command>
+ <command>
+ <proto>void <name>glStencilOpSeparateATI</name></proto>
+ <param group="StencilFaceDirection"><ptype>GLenum</ptype> <name>face</name></param>
+ <param group="StencilOp"><ptype>GLenum</ptype> <name>sfail</name></param>
+ <param group="StencilOp"><ptype>GLenum</ptype> <name>dpfail</name></param>
+ <param group="StencilOp"><ptype>GLenum</ptype> <name>dppass</name></param>
+ <alias name="glStencilOpSeparate"/>
+ </command>
+ <command>
+ <proto>void <name>glStencilOpValueAMD</name></proto>
+ <param group="StencilFaceDirection"><ptype>GLenum</ptype> <name>face</name></param>
+ <param><ptype>GLuint</ptype> <name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glStencilStrokePathInstancedNV</name></proto>
+ <param><ptype>GLsizei</ptype> <name>numPaths</name></param>
+ <param group="PathElementType"><ptype>GLenum</ptype> <name>pathNameType</name></param>
+ <param group="PathElement" len="COMPSIZE(numPaths,pathNameType,paths)">const void *<name>paths</name></param>
+ <param group="Path"><ptype>GLuint</ptype> <name>pathBase</name></param>
+ <param group="StencilValue"><ptype>GLint</ptype> <name>reference</name></param>
+ <param group="MaskedStencilValue"><ptype>GLuint</ptype> <name>mask</name></param>
+ <param group="PathTransformType"><ptype>GLenum</ptype> <name>transformType</name></param>
+ <param len="COMPSIZE(numPaths,transformType)">const <ptype>GLfloat</ptype> *<name>transformValues</name></param>
+ </command>
+ <command>
+ <proto>void <name>glStencilStrokePathNV</name></proto>
+ <param group="Path"><ptype>GLuint</ptype> <name>path</name></param>
+ <param group="StencilValue"><ptype>GLint</ptype> <name>reference</name></param>
+ <param group="MaskedStencilValue"><ptype>GLuint</ptype> <name>mask</name></param>
+ </command>
+ <command>
+ <proto>void <name>glStencilThenCoverFillPathInstancedNV</name></proto>
+ <param><ptype>GLsizei</ptype> <name>numPaths</name></param>
+ <param><ptype>GLenum</ptype> <name>pathNameType</name></param>
+ <param>const void *<name>paths</name></param>
+ <param><ptype>GLuint</ptype> <name>pathBase</name></param>
+ <param><ptype>GLenum</ptype> <name>fillMode</name></param>
+ <param><ptype>GLuint</ptype> <name>mask</name></param>
+ <param><ptype>GLenum</ptype> <name>coverMode</name></param>
+ <param><ptype>GLenum</ptype> <name>transformType</name></param>
+ <param>const <ptype>GLfloat</ptype> *<name>transformValues</name></param>
+ </command>
+ <command>
+ <proto>void <name>glStencilThenCoverFillPathNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>path</name></param>
+ <param><ptype>GLenum</ptype> <name>fillMode</name></param>
+ <param><ptype>GLuint</ptype> <name>mask</name></param>
+ <param><ptype>GLenum</ptype> <name>coverMode</name></param>
+ </command>
+ <command>
+ <proto>void <name>glStencilThenCoverStrokePathInstancedNV</name></proto>
+ <param><ptype>GLsizei</ptype> <name>numPaths</name></param>
+ <param><ptype>GLenum</ptype> <name>pathNameType</name></param>
+ <param>const void *<name>paths</name></param>
+ <param><ptype>GLuint</ptype> <name>pathBase</name></param>
+ <param><ptype>GLint</ptype> <name>reference</name></param>
+ <param><ptype>GLuint</ptype> <name>mask</name></param>
+ <param><ptype>GLenum</ptype> <name>coverMode</name></param>
+ <param><ptype>GLenum</ptype> <name>transformType</name></param>
+ <param>const <ptype>GLfloat</ptype> *<name>transformValues</name></param>
+ </command>
+ <command>
+ <proto>void <name>glStencilThenCoverStrokePathNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>path</name></param>
+ <param><ptype>GLint</ptype> <name>reference</name></param>
+ <param><ptype>GLuint</ptype> <name>mask</name></param>
+ <param><ptype>GLenum</ptype> <name>coverMode</name></param>
+ </command>
+ <command>
+ <proto>void <name>glStopInstrumentsSGIX</name></proto>
+ <param><ptype>GLint</ptype> <name>marker</name></param>
+ <glx type="render" opcode="2070"/>
+ </command>
+ <command>
+ <proto>void <name>glStringMarkerGREMEDY</name></proto>
+ <param><ptype>GLsizei</ptype> <name>len</name></param>
+ <param len="len">const void *<name>string</name></param>
+ </command>
+ <command>
+ <proto>void <name>glSwizzleEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>res</name></param>
+ <param><ptype>GLuint</ptype> <name>in</name></param>
+ <param group="VertexShaderCoordOutEXT"><ptype>GLenum</ptype> <name>outX</name></param>
+ <param group="VertexShaderCoordOutEXT"><ptype>GLenum</ptype> <name>outY</name></param>
+ <param group="VertexShaderCoordOutEXT"><ptype>GLenum</ptype> <name>outZ</name></param>
+ <param group="VertexShaderCoordOutEXT"><ptype>GLenum</ptype> <name>outW</name></param>
+ </command>
+ <command>
+ <proto>void <name>glSyncTextureINTEL</name></proto>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTagSampleBufferSGIX</name></proto>
+ <glx type="render" opcode="2050"/>
+ </command>
+ <command>
+ <proto>void <name>glTangent3bEXT</name></proto>
+ <param><ptype>GLbyte</ptype> <name>tx</name></param>
+ <param><ptype>GLbyte</ptype> <name>ty</name></param>
+ <param><ptype>GLbyte</ptype> <name>tz</name></param>
+ <vecequiv name="glTangent3bvEXT"/>
+ </command>
+ <command>
+ <proto>void <name>glTangent3bvEXT</name></proto>
+ <param len="3">const <ptype>GLbyte</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTangent3dEXT</name></proto>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>tx</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>ty</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>tz</name></param>
+ <vecequiv name="glTangent3dvEXT"/>
+ </command>
+ <command>
+ <proto>void <name>glTangent3dvEXT</name></proto>
+ <param group="CoordD" len="3">const <ptype>GLdouble</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTangent3fEXT</name></proto>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>tx</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>ty</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>tz</name></param>
+ <vecequiv name="glTangent3fvEXT"/>
+ </command>
+ <command>
+ <proto>void <name>glTangent3fvEXT</name></proto>
+ <param group="CoordF" len="3">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTangent3iEXT</name></proto>
+ <param><ptype>GLint</ptype> <name>tx</name></param>
+ <param><ptype>GLint</ptype> <name>ty</name></param>
+ <param><ptype>GLint</ptype> <name>tz</name></param>
+ <vecequiv name="glTangent3ivEXT"/>
+ </command>
+ <command>
+ <proto>void <name>glTangent3ivEXT</name></proto>
+ <param len="3">const <ptype>GLint</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTangent3sEXT</name></proto>
+ <param><ptype>GLshort</ptype> <name>tx</name></param>
+ <param><ptype>GLshort</ptype> <name>ty</name></param>
+ <param><ptype>GLshort</ptype> <name>tz</name></param>
+ <vecequiv name="glTangent3svEXT"/>
+ </command>
+ <command>
+ <proto>void <name>glTangent3svEXT</name></proto>
+ <param len="3">const <ptype>GLshort</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTangentPointerEXT</name></proto>
+ <param group="TangentPointerTypeEXT"><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ <param len="COMPSIZE(type,stride)">const void *<name>pointer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTbufferMask3DFX</name></proto>
+ <param><ptype>GLuint</ptype> <name>mask</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTessellationFactorAMD</name></proto>
+ <param><ptype>GLfloat</ptype> <name>factor</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTessellationModeAMD</name></proto>
+ <param><ptype>GLenum</ptype> <name>mode</name></param>
+ </command>
+ <command>
+ <proto group="Boolean"><ptype>GLboolean</ptype> <name>glTestFenceAPPLE</name></proto>
+ <param group="FenceNV"><ptype>GLuint</ptype> <name>fence</name></param>
+ </command>
+ <command>
+ <proto group="Boolean"><ptype>GLboolean</ptype> <name>glTestFenceNV</name></proto>
+ <param group="FenceNV"><ptype>GLuint</ptype> <name>fence</name></param>
+ <glx type="vendor" opcode="1279"/>
+ </command>
+ <command>
+ <proto group="Boolean"><ptype>GLboolean</ptype> <name>glTestObjectAPPLE</name></proto>
+ <param group="ObjectTypeAPPLE"><ptype>GLenum</ptype> <name>object</name></param>
+ <param><ptype>GLuint</ptype> <name>name</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexBuffer</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexBufferARB</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <alias name="glTexBuffer"/>
+ </command>
+ <command>
+ <proto>void <name>glTexBufferEXT</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <alias name="glTexBuffer"/>
+ </command>
+ <command>
+ <proto>void <name>glTexBufferRange</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <param group="BufferOffset"><ptype>GLintptr</ptype> <name>offset</name></param>
+ <param group="BufferSize"><ptype>GLsizeiptr</ptype> <name>size</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexBufferRangeEXT</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <param group="BufferOffset"><ptype>GLintptr</ptype> <name>offset</name></param>
+ <param group="BufferSize"><ptype>GLsizeiptr</ptype> <name>size</name></param>
+ <alias name="glTexBufferRange"/>
+ </command>
+ <command>
+ <proto>void <name>glTexBumpParameterfvATI</name></proto>
+ <param group="TexBumpParameterATI"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)">const <ptype>GLfloat</ptype> *<name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexBumpParameterivATI</name></proto>
+ <param group="TexBumpParameterATI"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)">const <ptype>GLint</ptype> *<name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord1bOES</name></proto>
+ <param><ptype>GLbyte</ptype> <name>s</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord1bvOES</name></proto>
+ <param len="1">const <ptype>GLbyte</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord1d</name></proto>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>s</name></param>
+ <vecequiv name="glTexCoord1dv"/>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord1dv</name></proto>
+ <param group="CoordD" len="1">const <ptype>GLdouble</ptype> *<name>v</name></param>
+ <glx type="render" opcode="49"/>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord1f</name></proto>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>s</name></param>
+ <vecequiv name="glTexCoord1fv"/>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord1fv</name></proto>
+ <param group="CoordF" len="1">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ <glx type="render" opcode="50"/>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord1hNV</name></proto>
+ <param group="Half16NV"><ptype>GLhalfNV</ptype> <name>s</name></param>
+ <vecequiv name="glTexCoord1hvNV"/>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord1hvNV</name></proto>
+ <param group="Half16NV" len="1">const <ptype>GLhalfNV</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4246"/>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord1i</name></proto>
+ <param group="CoordI"><ptype>GLint</ptype> <name>s</name></param>
+ <vecequiv name="glTexCoord1iv"/>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord1iv</name></proto>
+ <param group="CoordI" len="1">const <ptype>GLint</ptype> *<name>v</name></param>
+ <glx type="render" opcode="51"/>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord1s</name></proto>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>s</name></param>
+ <vecequiv name="glTexCoord1sv"/>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord1sv</name></proto>
+ <param group="CoordS" len="1">const <ptype>GLshort</ptype> *<name>v</name></param>
+ <glx type="render" opcode="52"/>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord1xOES</name></proto>
+ <param><ptype>GLfixed</ptype> <name>s</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord1xvOES</name></proto>
+ <param len="1">const <ptype>GLfixed</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord2bOES</name></proto>
+ <param><ptype>GLbyte</ptype> <name>s</name></param>
+ <param><ptype>GLbyte</ptype> <name>t</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord2bvOES</name></proto>
+ <param len="2">const <ptype>GLbyte</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord2d</name></proto>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>s</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>t</name></param>
+ <vecequiv name="glTexCoord2dv"/>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord2dv</name></proto>
+ <param group="CoordD" len="2">const <ptype>GLdouble</ptype> *<name>v</name></param>
+ <glx type="render" opcode="53"/>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord2f</name></proto>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>s</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>t</name></param>
+ <vecequiv name="glTexCoord2fv"/>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord2fColor3fVertex3fSUN</name></proto>
+ <param><ptype>GLfloat</ptype> <name>s</name></param>
+ <param><ptype>GLfloat</ptype> <name>t</name></param>
+ <param><ptype>GLfloat</ptype> <name>r</name></param>
+ <param><ptype>GLfloat</ptype> <name>g</name></param>
+ <param><ptype>GLfloat</ptype> <name>b</name></param>
+ <param><ptype>GLfloat</ptype> <name>x</name></param>
+ <param><ptype>GLfloat</ptype> <name>y</name></param>
+ <param><ptype>GLfloat</ptype> <name>z</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord2fColor3fVertex3fvSUN</name></proto>
+ <param len="2">const <ptype>GLfloat</ptype> *<name>tc</name></param>
+ <param len="3">const <ptype>GLfloat</ptype> *<name>c</name></param>
+ <param len="3">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord2fColor4fNormal3fVertex3fSUN</name></proto>
+ <param><ptype>GLfloat</ptype> <name>s</name></param>
+ <param><ptype>GLfloat</ptype> <name>t</name></param>
+ <param><ptype>GLfloat</ptype> <name>r</name></param>
+ <param><ptype>GLfloat</ptype> <name>g</name></param>
+ <param><ptype>GLfloat</ptype> <name>b</name></param>
+ <param><ptype>GLfloat</ptype> <name>a</name></param>
+ <param><ptype>GLfloat</ptype> <name>nx</name></param>
+ <param><ptype>GLfloat</ptype> <name>ny</name></param>
+ <param><ptype>GLfloat</ptype> <name>nz</name></param>
+ <param><ptype>GLfloat</ptype> <name>x</name></param>
+ <param><ptype>GLfloat</ptype> <name>y</name></param>
+ <param><ptype>GLfloat</ptype> <name>z</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord2fColor4fNormal3fVertex3fvSUN</name></proto>
+ <param len="2">const <ptype>GLfloat</ptype> *<name>tc</name></param>
+ <param len="4">const <ptype>GLfloat</ptype> *<name>c</name></param>
+ <param len="3">const <ptype>GLfloat</ptype> *<name>n</name></param>
+ <param len="3">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord2fColor4ubVertex3fSUN</name></proto>
+ <param><ptype>GLfloat</ptype> <name>s</name></param>
+ <param><ptype>GLfloat</ptype> <name>t</name></param>
+ <param><ptype>GLubyte</ptype> <name>r</name></param>
+ <param><ptype>GLubyte</ptype> <name>g</name></param>
+ <param><ptype>GLubyte</ptype> <name>b</name></param>
+ <param><ptype>GLubyte</ptype> <name>a</name></param>
+ <param><ptype>GLfloat</ptype> <name>x</name></param>
+ <param><ptype>GLfloat</ptype> <name>y</name></param>
+ <param><ptype>GLfloat</ptype> <name>z</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord2fColor4ubVertex3fvSUN</name></proto>
+ <param len="2">const <ptype>GLfloat</ptype> *<name>tc</name></param>
+ <param len="4">const <ptype>GLubyte</ptype> *<name>c</name></param>
+ <param len="3">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord2fNormal3fVertex3fSUN</name></proto>
+ <param><ptype>GLfloat</ptype> <name>s</name></param>
+ <param><ptype>GLfloat</ptype> <name>t</name></param>
+ <param><ptype>GLfloat</ptype> <name>nx</name></param>
+ <param><ptype>GLfloat</ptype> <name>ny</name></param>
+ <param><ptype>GLfloat</ptype> <name>nz</name></param>
+ <param><ptype>GLfloat</ptype> <name>x</name></param>
+ <param><ptype>GLfloat</ptype> <name>y</name></param>
+ <param><ptype>GLfloat</ptype> <name>z</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord2fNormal3fVertex3fvSUN</name></proto>
+ <param len="2">const <ptype>GLfloat</ptype> *<name>tc</name></param>
+ <param len="3">const <ptype>GLfloat</ptype> *<name>n</name></param>
+ <param len="3">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord2fVertex3fSUN</name></proto>
+ <param><ptype>GLfloat</ptype> <name>s</name></param>
+ <param><ptype>GLfloat</ptype> <name>t</name></param>
+ <param><ptype>GLfloat</ptype> <name>x</name></param>
+ <param><ptype>GLfloat</ptype> <name>y</name></param>
+ <param><ptype>GLfloat</ptype> <name>z</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord2fVertex3fvSUN</name></proto>
+ <param len="2">const <ptype>GLfloat</ptype> *<name>tc</name></param>
+ <param len="3">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord2fv</name></proto>
+ <param group="CoordF" len="2">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ <glx type="render" opcode="54"/>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord2hNV</name></proto>
+ <param group="Half16NV"><ptype>GLhalfNV</ptype> <name>s</name></param>
+ <param group="Half16NV"><ptype>GLhalfNV</ptype> <name>t</name></param>
+ <vecequiv name="glTexCoord2hvNV"/>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord2hvNV</name></proto>
+ <param group="Half16NV" len="2">const <ptype>GLhalfNV</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4247"/>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord2i</name></proto>
+ <param group="CoordI"><ptype>GLint</ptype> <name>s</name></param>
+ <param group="CoordI"><ptype>GLint</ptype> <name>t</name></param>
+ <vecequiv name="glTexCoord2iv"/>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord2iv</name></proto>
+ <param group="CoordI" len="2">const <ptype>GLint</ptype> *<name>v</name></param>
+ <glx type="render" opcode="55"/>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord2s</name></proto>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>s</name></param>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>t</name></param>
+ <vecequiv name="glTexCoord2sv"/>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord2sv</name></proto>
+ <param group="CoordS" len="2">const <ptype>GLshort</ptype> *<name>v</name></param>
+ <glx type="render" opcode="56"/>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord2xOES</name></proto>
+ <param><ptype>GLfixed</ptype> <name>s</name></param>
+ <param><ptype>GLfixed</ptype> <name>t</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord2xvOES</name></proto>
+ <param len="2">const <ptype>GLfixed</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord3bOES</name></proto>
+ <param><ptype>GLbyte</ptype> <name>s</name></param>
+ <param><ptype>GLbyte</ptype> <name>t</name></param>
+ <param><ptype>GLbyte</ptype> <name>r</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord3bvOES</name></proto>
+ <param len="3">const <ptype>GLbyte</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord3d</name></proto>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>s</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>t</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>r</name></param>
+ <vecequiv name="glTexCoord3dv"/>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord3dv</name></proto>
+ <param group="CoordD" len="3">const <ptype>GLdouble</ptype> *<name>v</name></param>
+ <glx type="render" opcode="57"/>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord3f</name></proto>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>s</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>t</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>r</name></param>
+ <vecequiv name="glTexCoord3fv"/>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord3fv</name></proto>
+ <param group="CoordF" len="3">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ <glx type="render" opcode="58"/>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord3hNV</name></proto>
+ <param group="Half16NV"><ptype>GLhalfNV</ptype> <name>s</name></param>
+ <param group="Half16NV"><ptype>GLhalfNV</ptype> <name>t</name></param>
+ <param group="Half16NV"><ptype>GLhalfNV</ptype> <name>r</name></param>
+ <vecequiv name="glTexCoord3hvNV"/>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord3hvNV</name></proto>
+ <param group="Half16NV" len="3">const <ptype>GLhalfNV</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4248"/>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord3i</name></proto>
+ <param group="CoordI"><ptype>GLint</ptype> <name>s</name></param>
+ <param group="CoordI"><ptype>GLint</ptype> <name>t</name></param>
+ <param group="CoordI"><ptype>GLint</ptype> <name>r</name></param>
+ <vecequiv name="glTexCoord3iv"/>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord3iv</name></proto>
+ <param group="CoordI" len="3">const <ptype>GLint</ptype> *<name>v</name></param>
+ <glx type="render" opcode="59"/>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord3s</name></proto>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>s</name></param>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>t</name></param>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>r</name></param>
+ <vecequiv name="glTexCoord3sv"/>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord3sv</name></proto>
+ <param group="CoordS" len="3">const <ptype>GLshort</ptype> *<name>v</name></param>
+ <glx type="render" opcode="60"/>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord3xOES</name></proto>
+ <param><ptype>GLfixed</ptype> <name>s</name></param>
+ <param><ptype>GLfixed</ptype> <name>t</name></param>
+ <param><ptype>GLfixed</ptype> <name>r</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord3xvOES</name></proto>
+ <param len="3">const <ptype>GLfixed</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord4bOES</name></proto>
+ <param><ptype>GLbyte</ptype> <name>s</name></param>
+ <param><ptype>GLbyte</ptype> <name>t</name></param>
+ <param><ptype>GLbyte</ptype> <name>r</name></param>
+ <param><ptype>GLbyte</ptype> <name>q</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord4bvOES</name></proto>
+ <param len="4">const <ptype>GLbyte</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord4d</name></proto>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>s</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>t</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>r</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>q</name></param>
+ <vecequiv name="glTexCoord4dv"/>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord4dv</name></proto>
+ <param group="CoordD" len="4">const <ptype>GLdouble</ptype> *<name>v</name></param>
+ <glx type="render" opcode="61"/>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord4f</name></proto>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>s</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>t</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>r</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>q</name></param>
+ <vecequiv name="glTexCoord4fv"/>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord4fColor4fNormal3fVertex4fSUN</name></proto>
+ <param><ptype>GLfloat</ptype> <name>s</name></param>
+ <param><ptype>GLfloat</ptype> <name>t</name></param>
+ <param><ptype>GLfloat</ptype> <name>p</name></param>
+ <param><ptype>GLfloat</ptype> <name>q</name></param>
+ <param><ptype>GLfloat</ptype> <name>r</name></param>
+ <param><ptype>GLfloat</ptype> <name>g</name></param>
+ <param><ptype>GLfloat</ptype> <name>b</name></param>
+ <param><ptype>GLfloat</ptype> <name>a</name></param>
+ <param><ptype>GLfloat</ptype> <name>nx</name></param>
+ <param><ptype>GLfloat</ptype> <name>ny</name></param>
+ <param><ptype>GLfloat</ptype> <name>nz</name></param>
+ <param><ptype>GLfloat</ptype> <name>x</name></param>
+ <param><ptype>GLfloat</ptype> <name>y</name></param>
+ <param><ptype>GLfloat</ptype> <name>z</name></param>
+ <param><ptype>GLfloat</ptype> <name>w</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord4fColor4fNormal3fVertex4fvSUN</name></proto>
+ <param len="4">const <ptype>GLfloat</ptype> *<name>tc</name></param>
+ <param len="4">const <ptype>GLfloat</ptype> *<name>c</name></param>
+ <param len="3">const <ptype>GLfloat</ptype> *<name>n</name></param>
+ <param len="4">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord4fVertex4fSUN</name></proto>
+ <param><ptype>GLfloat</ptype> <name>s</name></param>
+ <param><ptype>GLfloat</ptype> <name>t</name></param>
+ <param><ptype>GLfloat</ptype> <name>p</name></param>
+ <param><ptype>GLfloat</ptype> <name>q</name></param>
+ <param><ptype>GLfloat</ptype> <name>x</name></param>
+ <param><ptype>GLfloat</ptype> <name>y</name></param>
+ <param><ptype>GLfloat</ptype> <name>z</name></param>
+ <param><ptype>GLfloat</ptype> <name>w</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord4fVertex4fvSUN</name></proto>
+ <param len="4">const <ptype>GLfloat</ptype> *<name>tc</name></param>
+ <param len="4">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord4fv</name></proto>
+ <param group="CoordF" len="4">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ <glx type="render" opcode="62"/>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord4hNV</name></proto>
+ <param group="Half16NV"><ptype>GLhalfNV</ptype> <name>s</name></param>
+ <param group="Half16NV"><ptype>GLhalfNV</ptype> <name>t</name></param>
+ <param group="Half16NV"><ptype>GLhalfNV</ptype> <name>r</name></param>
+ <param group="Half16NV"><ptype>GLhalfNV</ptype> <name>q</name></param>
+ <vecequiv name="glTexCoord4hvNV"/>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord4hvNV</name></proto>
+ <param group="Half16NV" len="4">const <ptype>GLhalfNV</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4249"/>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord4i</name></proto>
+ <param group="CoordI"><ptype>GLint</ptype> <name>s</name></param>
+ <param group="CoordI"><ptype>GLint</ptype> <name>t</name></param>
+ <param group="CoordI"><ptype>GLint</ptype> <name>r</name></param>
+ <param group="CoordI"><ptype>GLint</ptype> <name>q</name></param>
+ <vecequiv name="glTexCoord4iv"/>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord4iv</name></proto>
+ <param group="CoordI" len="4">const <ptype>GLint</ptype> *<name>v</name></param>
+ <glx type="render" opcode="63"/>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord4s</name></proto>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>s</name></param>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>t</name></param>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>r</name></param>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>q</name></param>
+ <vecequiv name="glTexCoord4sv"/>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord4sv</name></proto>
+ <param group="CoordS" len="4">const <ptype>GLshort</ptype> *<name>v</name></param>
+ <glx type="render" opcode="64"/>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord4xOES</name></proto>
+ <param><ptype>GLfixed</ptype> <name>s</name></param>
+ <param><ptype>GLfixed</ptype> <name>t</name></param>
+ <param><ptype>GLfixed</ptype> <name>r</name></param>
+ <param><ptype>GLfixed</ptype> <name>q</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexCoord4xvOES</name></proto>
+ <param len="4">const <ptype>GLfixed</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexCoordFormatNV</name></proto>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexCoordP1ui</name></proto>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLuint</ptype> <name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexCoordP1uiv</name></proto>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="1">const <ptype>GLuint</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexCoordP2ui</name></proto>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLuint</ptype> <name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexCoordP2uiv</name></proto>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="1">const <ptype>GLuint</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexCoordP3ui</name></proto>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLuint</ptype> <name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexCoordP3uiv</name></proto>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="1">const <ptype>GLuint</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexCoordP4ui</name></proto>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLuint</ptype> <name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexCoordP4uiv</name></proto>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="1">const <ptype>GLuint</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexCoordPointer</name></proto>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param group="TexCoordPointerType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ <param len="COMPSIZE(size,type,stride)">const void *<name>pointer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexCoordPointerEXT</name></proto>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param group="TexCoordPointerType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="COMPSIZE(size,type,stride,count)">const void *<name>pointer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexCoordPointerListIBM</name></proto>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param group="TexCoordPointerType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLint</ptype> <name>stride</name></param>
+ <param len="COMPSIZE(size,type,stride)">const void **<name>pointer</name></param>
+ <param><ptype>GLint</ptype> <name>ptrstride</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexCoordPointervINTEL</name></proto>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param group="VertexPointerType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="4">const void **<name>pointer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexEnvf</name></proto>
+ <param group="TextureEnvTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="TextureEnvParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedFloat32"><ptype>GLfloat</ptype> <name>param</name></param>
+ <glx type="render" opcode="111"/>
+ </command>
+ <command>
+ <proto>void <name>glTexEnvfv</name></proto>
+ <param group="TextureEnvTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="TextureEnvParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedFloat32" len="COMPSIZE(pname)">const <ptype>GLfloat</ptype> *<name>params</name></param>
+ <glx type="render" opcode="112"/>
+ </command>
+ <command>
+ <proto>void <name>glTexEnvi</name></proto>
+ <param group="TextureEnvTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="TextureEnvParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>param</name></param>
+ <glx type="render" opcode="113"/>
+ </command>
+ <command>
+ <proto>void <name>glTexEnviv</name></proto>
+ <param group="TextureEnvTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="TextureEnvParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedInt32" len="COMPSIZE(pname)">const <ptype>GLint</ptype> *<name>params</name></param>
+ <glx type="render" opcode="114"/>
+ </command>
+ <command>
+ <proto>void <name>glTexEnvx</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLfixed</ptype> <name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexEnvxOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLfixed</ptype> <name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexEnvxv</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)">const <ptype>GLfixed</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexEnvxvOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)">const <ptype>GLfixed</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexFilterFuncSGIS</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="TextureFilterSGIS"><ptype>GLenum</ptype> <name>filter</name></param>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param len="n">const <ptype>GLfloat</ptype> *<name>weights</name></param>
+ <glx type="render" opcode="2064"/>
+ </command>
+ <command>
+ <proto>void <name>glTexGend</name></proto>
+ <param group="TextureCoordName"><ptype>GLenum</ptype> <name>coord</name></param>
+ <param group="TextureGenParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLdouble</ptype> <name>param</name></param>
+ <glx type="render" opcode="115"/>
+ </command>
+ <command>
+ <proto>void <name>glTexGendv</name></proto>
+ <param group="TextureCoordName"><ptype>GLenum</ptype> <name>coord</name></param>
+ <param group="TextureGenParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)">const <ptype>GLdouble</ptype> *<name>params</name></param>
+ <glx type="render" opcode="116"/>
+ </command>
+ <command>
+ <proto>void <name>glTexGenf</name></proto>
+ <param group="TextureCoordName"><ptype>GLenum</ptype> <name>coord</name></param>
+ <param group="TextureGenParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedFloat32"><ptype>GLfloat</ptype> <name>param</name></param>
+ <glx type="render" opcode="117"/>
+ </command>
+ <command>
+ <proto>void <name>glTexGenfOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>coord</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLfloat</ptype> <name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexGenfv</name></proto>
+ <param group="TextureCoordName"><ptype>GLenum</ptype> <name>coord</name></param>
+ <param group="TextureGenParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedFloat32" len="COMPSIZE(pname)">const <ptype>GLfloat</ptype> *<name>params</name></param>
+ <glx type="render" opcode="118"/>
+ </command>
+ <command>
+ <proto>void <name>glTexGenfvOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>coord</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)">const <ptype>GLfloat</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexGeni</name></proto>
+ <param group="TextureCoordName"><ptype>GLenum</ptype> <name>coord</name></param>
+ <param group="TextureGenParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>param</name></param>
+ <glx type="render" opcode="119"/>
+ </command>
+ <command>
+ <proto>void <name>glTexGeniOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>coord</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLint</ptype> <name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexGeniv</name></proto>
+ <param group="TextureCoordName"><ptype>GLenum</ptype> <name>coord</name></param>
+ <param group="TextureGenParameter"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedInt32" len="COMPSIZE(pname)">const <ptype>GLint</ptype> *<name>params</name></param>
+ <glx type="render" opcode="120"/>
+ </command>
+ <command>
+ <proto>void <name>glTexGenivOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>coord</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)">const <ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexGenxOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>coord</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLfixed</ptype> <name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexGenxvOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>coord</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)">const <ptype>GLfixed</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexImage1D</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="TextureComponentCount"><ptype>GLint</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>border</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param group="PixelType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(format,type,width)">const void *<name>pixels</name></param>
+ <glx type="render" opcode="109"/>
+ <glx type="render" opcode="328" name="glTexImage1DPBO" comment="PBO protocol"/>
+ </command>
+ <command>
+ <proto>void <name>glTexImage2D</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="TextureComponentCount"><ptype>GLint</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>border</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param group="PixelType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(format,type,width,height)">const void *<name>pixels</name></param>
+ <glx type="render" opcode="110"/>
+ <glx type="render" opcode="329" name="glTexImage2DPBO" comment="PBO protocol"/>
+ </command>
+ <command>
+ <proto>void <name>glTexImage2DMultisample</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLsizei</ptype> <name>samples</name></param>
+ <param><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>fixedsamplelocations</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexImage2DMultisampleCoverageNV</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLsizei</ptype> <name>coverageSamples</name></param>
+ <param><ptype>GLsizei</ptype> <name>colorSamples</name></param>
+ <param><ptype>GLint</ptype> <name>internalFormat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>fixedSampleLocations</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexImage3D</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="TextureComponentCount"><ptype>GLint</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param><ptype>GLsizei</ptype> <name>depth</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>border</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param group="PixelType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(format,type,width,height,depth)">const void *<name>pixels</name></param>
+ <glx type="render" opcode="4114"/>
+ <glx type="render" opcode="330" name="glTexImage3DPBO" comment="PBO protocol"/>
+ </command>
+ <command>
+ <proto>void <name>glTexImage3DEXT</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="PixelInternalFormat"><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param><ptype>GLsizei</ptype> <name>depth</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>border</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param group="PixelType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(format,type,width,height,depth)">const void *<name>pixels</name></param>
+ <alias name="glTexImage3D"/>
+ <glx type="render" opcode="4114"/>
+ </command>
+ <command>
+ <proto>void <name>glTexImage3DMultisample</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLsizei</ptype> <name>samples</name></param>
+ <param><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param><ptype>GLsizei</ptype> <name>depth</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>fixedsamplelocations</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexImage3DMultisampleCoverageNV</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLsizei</ptype> <name>coverageSamples</name></param>
+ <param><ptype>GLsizei</ptype> <name>colorSamples</name></param>
+ <param><ptype>GLint</ptype> <name>internalFormat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param><ptype>GLsizei</ptype> <name>depth</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>fixedSampleLocations</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexImage3DOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLint</ptype> <name>level</name></param>
+ <param><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param><ptype>GLsizei</ptype> <name>depth</name></param>
+ <param><ptype>GLint</ptype> <name>border</name></param>
+ <param><ptype>GLenum</ptype> <name>format</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(format,type,width,height,depth)">const void *<name>pixels</name></param>
+ <alias name="glTexImage3D"/>
+ </command>
+ <command>
+ <proto>void <name>glTexImage4DSGIS</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="PixelInternalFormat"><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param><ptype>GLsizei</ptype> <name>depth</name></param>
+ <param><ptype>GLsizei</ptype> <name>size4d</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>border</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param group="PixelType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(format,type,width,height,depth,size4d)">const void *<name>pixels</name></param>
+ <glx type="render" opcode="2057"/>
+ </command>
+ <command>
+ <proto>void <name>glTexPageCommitmentARB</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLint</ptype> <name>level</name></param>
+ <param><ptype>GLint</ptype> <name>xoffset</name></param>
+ <param><ptype>GLint</ptype> <name>yoffset</name></param>
+ <param><ptype>GLint</ptype> <name>zoffset</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param><ptype>GLsizei</ptype> <name>depth</name></param>
+ <param><ptype>GLboolean</ptype> <name>resident</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexParameterIiv</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="TextureParameterName"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)">const <ptype>GLint</ptype> *<name>params</name></param>
+ <glx type="render" opcode="346"/>
+ </command>
+ <command>
+ <proto>void <name>glTexParameterIivEXT</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="TextureParameterName"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)">const <ptype>GLint</ptype> *<name>params</name></param>
+ <alias name="glTexParameterIiv"/>
+ </command>
+ <command>
+ <proto>void <name>glTexParameterIuiv</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="TextureParameterName"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)">const <ptype>GLuint</ptype> *<name>params</name></param>
+ <glx type="render" opcode="347"/>
+ </command>
+ <command>
+ <proto>void <name>glTexParameterIuivEXT</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="TextureParameterName"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)">const <ptype>GLuint</ptype> *<name>params</name></param>
+ <alias name="glTexParameterIuiv"/>
+ </command>
+ <command>
+ <proto>void <name>glTexParameterf</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="TextureParameterName"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedFloat32"><ptype>GLfloat</ptype> <name>param</name></param>
+ <glx type="render" opcode="105"/>
+ </command>
+ <command>
+ <proto>void <name>glTexParameterfv</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="TextureParameterName"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedFloat32" len="COMPSIZE(pname)">const <ptype>GLfloat</ptype> *<name>params</name></param>
+ <glx type="render" opcode="106"/>
+ </command>
+ <command>
+ <proto>void <name>glTexParameteri</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="TextureParameterName"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>param</name></param>
+ <glx type="render" opcode="107"/>
+ </command>
+ <command>
+ <proto>void <name>glTexParameteriv</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="TextureParameterName"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedInt32" len="COMPSIZE(pname)">const <ptype>GLint</ptype> *<name>params</name></param>
+ <glx type="render" opcode="108"/>
+ </command>
+ <command>
+ <proto>void <name>glTexParameterx</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLfixed</ptype> <name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexParameterxOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLfixed</ptype> <name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexParameterxv</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)">const <ptype>GLfixed</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexParameterxvOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)">const <ptype>GLfixed</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexRenderbufferNV</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>renderbuffer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexStorage1D</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLsizei</ptype> <name>levels</name></param>
+ <param><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexStorage1DEXT</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLsizei</ptype> <name>levels</name></param>
+ <param><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <alias name="glTexStorage1D"/>
+ </command>
+ <command>
+ <proto>void <name>glTexStorage2D</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLsizei</ptype> <name>levels</name></param>
+ <param><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexStorage2DEXT</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLsizei</ptype> <name>levels</name></param>
+ <param><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <alias name="glTexStorage2D"/>
+ </command>
+ <command>
+ <proto>void <name>glTexStorage2DMultisample</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLsizei</ptype> <name>samples</name></param>
+ <param><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>fixedsamplelocations</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexStorage3D</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLsizei</ptype> <name>levels</name></param>
+ <param><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param><ptype>GLsizei</ptype> <name>depth</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexStorage3DEXT</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLsizei</ptype> <name>levels</name></param>
+ <param><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param><ptype>GLsizei</ptype> <name>depth</name></param>
+ <alias name="glTexStorage3D"/>
+ </command>
+ <command>
+ <proto>void <name>glTexStorage3DMultisample</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLsizei</ptype> <name>samples</name></param>
+ <param><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param><ptype>GLsizei</ptype> <name>depth</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>fixedsamplelocations</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexStorage3DMultisampleOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLsizei</ptype> <name>samples</name></param>
+ <param><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param><ptype>GLsizei</ptype> <name>depth</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>fixedsamplelocations</name></param>
+ <alias name="glTexStorage3DMultisample"/>
+ </command>
+ <command>
+ <proto>void <name>glTexStorageSparseAMD</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>internalFormat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param><ptype>GLsizei</ptype> <name>depth</name></param>
+ <param><ptype>GLsizei</ptype> <name>layers</name></param>
+ <param><ptype>GLbitfield</ptype> <name>flags</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexSubImage1D</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>xoffset</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param group="PixelType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(format,type,width)">const void *<name>pixels</name></param>
+ <glx type="render" opcode="4099"/>
+ <glx type="render" opcode="331" name="glTexSubImage1DPBO" comment="PBO protocol"/>
+ </command>
+ <command>
+ <proto>void <name>glTexSubImage1DEXT</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>xoffset</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param group="PixelType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(format,type,width)">const void *<name>pixels</name></param>
+ <alias name="glTexSubImage1D"/>
+ <glx type="render" opcode="4099"/>
+ </command>
+ <command>
+ <proto>void <name>glTexSubImage2D</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>xoffset</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>yoffset</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param group="PixelType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(format,type,width,height)">const void *<name>pixels</name></param>
+ <glx type="render" opcode="4100"/>
+ <glx type="render" opcode="332" name="glTexSubImage2DPBO" comment="PBO protocol"/>
+ </command>
+ <command>
+ <proto>void <name>glTexSubImage2DEXT</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>xoffset</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>yoffset</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param group="PixelType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(format,type,width,height)">const void *<name>pixels</name></param>
+ <alias name="glTexSubImage2D"/>
+ <glx type="render" opcode="4100"/>
+ </command>
+ <command>
+ <proto>void <name>glTexSubImage3D</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>xoffset</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>yoffset</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>zoffset</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param><ptype>GLsizei</ptype> <name>depth</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param group="PixelType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(format,type,width,height,depth)">const void *<name>pixels</name></param>
+ <glx type="render" opcode="4115"/>
+ <glx type="render" opcode="333" name="glTexSubImage3DPBO" comment="PBO protocol"/>
+ </command>
+ <command>
+ <proto>void <name>glTexSubImage3DEXT</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>xoffset</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>yoffset</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>zoffset</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param><ptype>GLsizei</ptype> <name>depth</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param group="PixelType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(format,type,width,height,depth)">const void *<name>pixels</name></param>
+ <alias name="glTexSubImage3D"/>
+ <glx type="render" opcode="4115"/>
+ </command>
+ <command>
+ <proto>void <name>glTexSubImage3DOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLint</ptype> <name>level</name></param>
+ <param><ptype>GLint</ptype> <name>xoffset</name></param>
+ <param><ptype>GLint</ptype> <name>yoffset</name></param>
+ <param><ptype>GLint</ptype> <name>zoffset</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param><ptype>GLsizei</ptype> <name>depth</name></param>
+ <param><ptype>GLenum</ptype> <name>format</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(format,type,width,height,depth)">const void *<name>pixels</name></param>
+ <alias name="glTexSubImage3D"/>
+ </command>
+ <command>
+ <proto>void <name>glTexSubImage4DSGIS</name></proto>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>xoffset</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>yoffset</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>zoffset</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>woffset</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param><ptype>GLsizei</ptype> <name>depth</name></param>
+ <param><ptype>GLsizei</ptype> <name>size4d</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param group="PixelType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(format,type,width,height,depth,size4d)">const void *<name>pixels</name></param>
+ <glx type="render" opcode="2058"/>
+ </command>
+ <command>
+ <proto>void <name>glTextureBarrier</name></proto>
+ </command>
+ <command>
+ <proto>void <name>glTextureBarrierNV</name></proto>
+ <glx type="render" opcode="4348"/>
+ </command>
+ <command>
+ <proto>void <name>glTextureBuffer</name></proto>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTextureBufferEXT</name></proto>
+ <param group="Texture"><ptype>GLuint</ptype> <name>texture</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="TextureInternalFormat"><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTextureBufferRange</name></proto>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <param><ptype>GLintptr</ptype> <name>offset</name></param>
+ <param><ptype>GLsizei</ptype> <name>size</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTextureBufferRangeEXT</name></proto>
+ <param group="Texture"><ptype>GLuint</ptype> <name>texture</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="TextureInternalFormat"><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <param group="BufferOffset"><ptype>GLintptr</ptype> <name>offset</name></param>
+ <param group="BufferSize"><ptype>GLsizeiptr</ptype> <name>size</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTextureColorMaskSGIS</name></proto>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>red</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>green</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>blue</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>alpha</name></param>
+ <glx type="render" opcode="2082"/>
+ </command>
+ <command>
+ <proto>void <name>glTextureImage1DEXT</name></proto>
+ <param group="Texture"><ptype>GLuint</ptype> <name>texture</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="TextureComponentCount"><ptype>GLint</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>border</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param group="PixelType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(format,type,width)">const void *<name>pixels</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTextureImage2DEXT</name></proto>
+ <param group="Texture"><ptype>GLuint</ptype> <name>texture</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="TextureComponentCount"><ptype>GLint</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>border</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param group="PixelType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(format,type,width,height)">const void *<name>pixels</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTextureImage2DMultisampleCoverageNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLsizei</ptype> <name>coverageSamples</name></param>
+ <param><ptype>GLsizei</ptype> <name>colorSamples</name></param>
+ <param><ptype>GLint</ptype> <name>internalFormat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>fixedSampleLocations</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTextureImage2DMultisampleNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLsizei</ptype> <name>samples</name></param>
+ <param><ptype>GLint</ptype> <name>internalFormat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>fixedSampleLocations</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTextureImage3DEXT</name></proto>
+ <param group="Texture"><ptype>GLuint</ptype> <name>texture</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="TextureComponentCount"><ptype>GLint</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param><ptype>GLsizei</ptype> <name>depth</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>border</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param group="PixelType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(format,type,width,height,depth)">const void *<name>pixels</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTextureImage3DMultisampleCoverageNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLsizei</ptype> <name>coverageSamples</name></param>
+ <param><ptype>GLsizei</ptype> <name>colorSamples</name></param>
+ <param><ptype>GLint</ptype> <name>internalFormat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param><ptype>GLsizei</ptype> <name>depth</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>fixedSampleLocations</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTextureImage3DMultisampleNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLsizei</ptype> <name>samples</name></param>
+ <param><ptype>GLint</ptype> <name>internalFormat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param><ptype>GLsizei</ptype> <name>depth</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>fixedSampleLocations</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTextureLightEXT</name></proto>
+ <param group="LightTexturePNameEXT"><ptype>GLenum</ptype> <name>pname</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTextureMaterialEXT</name></proto>
+ <param group="MaterialFace"><ptype>GLenum</ptype> <name>face</name></param>
+ <param group="MaterialParameter"><ptype>GLenum</ptype> <name>mode</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTextureNormalEXT</name></proto>
+ <param group="TextureNormalModeEXT"><ptype>GLenum</ptype> <name>mode</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTexturePageCommitmentEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLint</ptype> <name>level</name></param>
+ <param><ptype>GLint</ptype> <name>xoffset</name></param>
+ <param><ptype>GLint</ptype> <name>yoffset</name></param>
+ <param><ptype>GLint</ptype> <name>zoffset</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param><ptype>GLsizei</ptype> <name>depth</name></param>
+ <param><ptype>GLboolean</ptype> <name>resident</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTextureParameterIiv</name></proto>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param>const <ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTextureParameterIivEXT</name></proto>
+ <param group="Texture"><ptype>GLuint</ptype> <name>texture</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="TextureParameterName"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedInt32" len="COMPSIZE(pname)">const <ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTextureParameterIuiv</name></proto>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param>const <ptype>GLuint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTextureParameterIuivEXT</name></proto>
+ <param group="Texture"><ptype>GLuint</ptype> <name>texture</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="TextureParameterName"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)">const <ptype>GLuint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTextureParameterf</name></proto>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLfloat</ptype> <name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTextureParameterfEXT</name></proto>
+ <param group="Texture"><ptype>GLuint</ptype> <name>texture</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="TextureParameterName"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedFloat32"><ptype>GLfloat</ptype> <name>param</name></param>
+ <vecequiv name="glTextureParameterfvEXT"/>
+ </command>
+ <command>
+ <proto>void <name>glTextureParameterfv</name></proto>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param>const <ptype>GLfloat</ptype> *<name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTextureParameterfvEXT</name></proto>
+ <param group="Texture"><ptype>GLuint</ptype> <name>texture</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="TextureParameterName"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedFloat32" len="COMPSIZE(pname)">const <ptype>GLfloat</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTextureParameteri</name></proto>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLint</ptype> <name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTextureParameteriEXT</name></proto>
+ <param group="Texture"><ptype>GLuint</ptype> <name>texture</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="TextureParameterName"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>param</name></param>
+ <vecequiv name="glTextureParameterivEXT"/>
+ </command>
+ <command>
+ <proto>void <name>glTextureParameteriv</name></proto>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param>const <ptype>GLint</ptype> *<name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTextureParameterivEXT</name></proto>
+ <param group="Texture"><ptype>GLuint</ptype> <name>texture</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="TextureParameterName"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param group="CheckedInt32" len="COMPSIZE(pname)">const <ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTextureRangeAPPLE</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLsizei</ptype> <name>length</name></param>
+ <param len="length">const void *<name>pointer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTextureRenderbufferEXT</name></proto>
+ <param group="Texture"><ptype>GLuint</ptype> <name>texture</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>renderbuffer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTextureStorage1D</name></proto>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLsizei</ptype> <name>levels</name></param>
+ <param><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTextureStorage1DEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLsizei</ptype> <name>levels</name></param>
+ <param><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTextureStorage2D</name></proto>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLsizei</ptype> <name>levels</name></param>
+ <param><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTextureStorage2DEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLsizei</ptype> <name>levels</name></param>
+ <param><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTextureStorage2DMultisample</name></proto>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLsizei</ptype> <name>samples</name></param>
+ <param><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param><ptype>GLboolean</ptype> <name>fixedsamplelocations</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTextureStorage2DMultisampleEXT</name></proto>
+ <param group="Texture"><ptype>GLuint</ptype> <name>texture</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLsizei</ptype> <name>samples</name></param>
+ <param group="TextureInternalFormat"><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>fixedsamplelocations</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTextureStorage3D</name></proto>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLsizei</ptype> <name>levels</name></param>
+ <param><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param><ptype>GLsizei</ptype> <name>depth</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTextureStorage3DEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLsizei</ptype> <name>levels</name></param>
+ <param><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param><ptype>GLsizei</ptype> <name>depth</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTextureStorage3DMultisample</name></proto>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLsizei</ptype> <name>samples</name></param>
+ <param><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param><ptype>GLsizei</ptype> <name>depth</name></param>
+ <param><ptype>GLboolean</ptype> <name>fixedsamplelocations</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTextureStorage3DMultisampleEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLsizei</ptype> <name>samples</name></param>
+ <param><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param><ptype>GLsizei</ptype> <name>depth</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>fixedsamplelocations</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTextureStorageSparseAMD</name></proto>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLenum</ptype> <name>internalFormat</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param><ptype>GLsizei</ptype> <name>depth</name></param>
+ <param><ptype>GLsizei</ptype> <name>layers</name></param>
+ <param><ptype>GLbitfield</ptype> <name>flags</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTextureSubImage1D</name></proto>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLint</ptype> <name>level</name></param>
+ <param><ptype>GLint</ptype> <name>xoffset</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLenum</ptype> <name>format</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param>const void *<name>pixels</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTextureSubImage1DEXT</name></proto>
+ <param group="Texture"><ptype>GLuint</ptype> <name>texture</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>xoffset</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param group="PixelType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(format,type,width)">const void *<name>pixels</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTextureSubImage2D</name></proto>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLint</ptype> <name>level</name></param>
+ <param><ptype>GLint</ptype> <name>xoffset</name></param>
+ <param><ptype>GLint</ptype> <name>yoffset</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param><ptype>GLenum</ptype> <name>format</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param>const void *<name>pixels</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTextureSubImage2DEXT</name></proto>
+ <param group="Texture"><ptype>GLuint</ptype> <name>texture</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>xoffset</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>yoffset</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param group="PixelType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(format,type,width,height)">const void *<name>pixels</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTextureSubImage3D</name></proto>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLint</ptype> <name>level</name></param>
+ <param><ptype>GLint</ptype> <name>xoffset</name></param>
+ <param><ptype>GLint</ptype> <name>yoffset</name></param>
+ <param><ptype>GLint</ptype> <name>zoffset</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param><ptype>GLsizei</ptype> <name>depth</name></param>
+ <param><ptype>GLenum</ptype> <name>format</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param>const void *<name>pixels</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTextureSubImage3DEXT</name></proto>
+ <param group="Texture"><ptype>GLuint</ptype> <name>texture</name></param>
+ <param group="TextureTarget"><ptype>GLenum</ptype> <name>target</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>level</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>xoffset</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>yoffset</name></param>
+ <param group="CheckedInt32"><ptype>GLint</ptype> <name>zoffset</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <param><ptype>GLsizei</ptype> <name>depth</name></param>
+ <param group="PixelFormat"><ptype>GLenum</ptype> <name>format</name></param>
+ <param group="PixelType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="COMPSIZE(format,type,width,height,depth)">const void *<name>pixels</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTextureView</name></proto>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>origtexture</name></param>
+ <param><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLuint</ptype> <name>minlevel</name></param>
+ <param><ptype>GLuint</ptype> <name>numlevels</name></param>
+ <param><ptype>GLuint</ptype> <name>minlayer</name></param>
+ <param><ptype>GLuint</ptype> <name>numlayers</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTextureViewEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>origtexture</name></param>
+ <param><ptype>GLenum</ptype> <name>internalformat</name></param>
+ <param><ptype>GLuint</ptype> <name>minlevel</name></param>
+ <param><ptype>GLuint</ptype> <name>numlevels</name></param>
+ <param><ptype>GLuint</ptype> <name>minlayer</name></param>
+ <param><ptype>GLuint</ptype> <name>numlayers</name></param>
+ <alias name="glTextureView"/>
+ </command>
+ <command>
+ <proto>void <name>glTrackMatrixNV</name></proto>
+ <param group="VertexAttribEnumNV"><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLuint</ptype> <name>address</name></param>
+ <param group="VertexAttribEnumNV"><ptype>GLenum</ptype> <name>matrix</name></param>
+ <param group="VertexAttribEnumNV"><ptype>GLenum</ptype> <name>transform</name></param>
+ <glx type="render" opcode="4188"/>
+ </command>
+ <command>
+ <proto>void <name>glTransformFeedbackAttribsNV</name></proto>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="COMPSIZE(count)">const <ptype>GLint</ptype> *<name>attribs</name></param>
+ <param><ptype>GLenum</ptype> <name>bufferMode</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTransformFeedbackBufferBase</name></proto>
+ <param><ptype>GLuint</ptype> <name>xfb</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTransformFeedbackBufferRange</name></proto>
+ <param><ptype>GLuint</ptype> <name>xfb</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <param><ptype>GLintptr</ptype> <name>offset</name></param>
+ <param><ptype>GLsizei</ptype> <name>size</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTransformFeedbackStreamAttribsNV</name></proto>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count">const <ptype>GLint</ptype> *<name>attribs</name></param>
+ <param><ptype>GLsizei</ptype> <name>nbuffers</name></param>
+ <param len="nbuffers">const <ptype>GLint</ptype> *<name>bufstreams</name></param>
+ <param><ptype>GLenum</ptype> <name>bufferMode</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTransformFeedbackVaryings</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count">const <ptype>GLchar</ptype> *const*<name>varyings</name></param>
+ <param><ptype>GLenum</ptype> <name>bufferMode</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTransformFeedbackVaryingsEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count">const <ptype>GLchar</ptype> *const*<name>varyings</name></param>
+ <param><ptype>GLenum</ptype> <name>bufferMode</name></param>
+ <alias name="glTransformFeedbackVaryings"/>
+ </command>
+ <command>
+ <proto>void <name>glTransformFeedbackVaryingsNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count">const <ptype>GLint</ptype> *<name>locations</name></param>
+ <param><ptype>GLenum</ptype> <name>bufferMode</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTransformPathNV</name></proto>
+ <param group="Path"><ptype>GLuint</ptype> <name>resultPath</name></param>
+ <param group="Path"><ptype>GLuint</ptype> <name>srcPath</name></param>
+ <param group="PathTransformType"><ptype>GLenum</ptype> <name>transformType</name></param>
+ <param len="COMPSIZE(transformType)">const <ptype>GLfloat</ptype> *<name>transformValues</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTranslated</name></proto>
+ <param><ptype>GLdouble</ptype> <name>x</name></param>
+ <param><ptype>GLdouble</ptype> <name>y</name></param>
+ <param><ptype>GLdouble</ptype> <name>z</name></param>
+ <glx type="render" opcode="189"/>
+ </command>
+ <command>
+ <proto>void <name>glTranslatef</name></proto>
+ <param><ptype>GLfloat</ptype> <name>x</name></param>
+ <param><ptype>GLfloat</ptype> <name>y</name></param>
+ <param><ptype>GLfloat</ptype> <name>z</name></param>
+ <glx type="render" opcode="190"/>
+ </command>
+ <command>
+ <proto>void <name>glTranslatex</name></proto>
+ <param><ptype>GLfixed</ptype> <name>x</name></param>
+ <param><ptype>GLfixed</ptype> <name>y</name></param>
+ <param><ptype>GLfixed</ptype> <name>z</name></param>
+ </command>
+ <command>
+ <proto>void <name>glTranslatexOES</name></proto>
+ <param><ptype>GLfixed</ptype> <name>x</name></param>
+ <param><ptype>GLfixed</ptype> <name>y</name></param>
+ <param><ptype>GLfixed</ptype> <name>z</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniform1d</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLdouble</ptype> <name>x</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniform1dv</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*1">const <ptype>GLdouble</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniform1f</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLfloat</ptype> <name>v0</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniform1fARB</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLfloat</ptype> <name>v0</name></param>
+ <alias name="glUniform1f"/>
+ </command>
+ <command>
+ <proto>void <name>glUniform1fv</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*1">const <ptype>GLfloat</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniform1fvARB</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*1">const <ptype>GLfloat</ptype> *<name>value</name></param>
+ <alias name="glUniform1fv"/>
+ </command>
+ <command>
+ <proto>void <name>glUniform1i</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLint</ptype> <name>v0</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniform1i64NV</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLint64EXT</ptype> <name>x</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniform1i64vNV</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*1">const <ptype>GLint64EXT</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniform1iARB</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLint</ptype> <name>v0</name></param>
+ <alias name="glUniform1i"/>
+ </command>
+ <command>
+ <proto>void <name>glUniform1iv</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*1">const <ptype>GLint</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniform1ivARB</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*1">const <ptype>GLint</ptype> *<name>value</name></param>
+ <alias name="glUniform1iv"/>
+ </command>
+ <command>
+ <proto>void <name>glUniform1ui</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLuint</ptype> <name>v0</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniform1ui64NV</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLuint64EXT</ptype> <name>x</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniform1ui64vNV</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*1">const <ptype>GLuint64EXT</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniform1uiEXT</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLuint</ptype> <name>v0</name></param>
+ <alias name="glUniform1ui"/>
+ </command>
+ <command>
+ <proto>void <name>glUniform1uiv</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*1">const <ptype>GLuint</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniform1uivEXT</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*1">const <ptype>GLuint</ptype> *<name>value</name></param>
+ <alias name="glUniform1uiv"/>
+ </command>
+ <command>
+ <proto>void <name>glUniform2d</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLdouble</ptype> <name>x</name></param>
+ <param><ptype>GLdouble</ptype> <name>y</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniform2dv</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*2">const <ptype>GLdouble</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniform2f</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLfloat</ptype> <name>v0</name></param>
+ <param><ptype>GLfloat</ptype> <name>v1</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniform2fARB</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLfloat</ptype> <name>v0</name></param>
+ <param><ptype>GLfloat</ptype> <name>v1</name></param>
+ <alias name="glUniform2f"/>
+ </command>
+ <command>
+ <proto>void <name>glUniform2fv</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*2">const <ptype>GLfloat</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniform2fvARB</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*2">const <ptype>GLfloat</ptype> *<name>value</name></param>
+ <alias name="glUniform2fv"/>
+ </command>
+ <command>
+ <proto>void <name>glUniform2i</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLint</ptype> <name>v0</name></param>
+ <param><ptype>GLint</ptype> <name>v1</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniform2i64NV</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLint64EXT</ptype> <name>x</name></param>
+ <param><ptype>GLint64EXT</ptype> <name>y</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniform2i64vNV</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*2">const <ptype>GLint64EXT</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniform2iARB</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLint</ptype> <name>v0</name></param>
+ <param><ptype>GLint</ptype> <name>v1</name></param>
+ <alias name="glUniform2i"/>
+ </command>
+ <command>
+ <proto>void <name>glUniform2iv</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*2">const <ptype>GLint</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniform2ivARB</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*2">const <ptype>GLint</ptype> *<name>value</name></param>
+ <alias name="glUniform2iv"/>
+ </command>
+ <command>
+ <proto>void <name>glUniform2ui</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLuint</ptype> <name>v0</name></param>
+ <param><ptype>GLuint</ptype> <name>v1</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniform2ui64NV</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLuint64EXT</ptype> <name>x</name></param>
+ <param><ptype>GLuint64EXT</ptype> <name>y</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniform2ui64vNV</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*2">const <ptype>GLuint64EXT</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniform2uiEXT</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLuint</ptype> <name>v0</name></param>
+ <param><ptype>GLuint</ptype> <name>v1</name></param>
+ <alias name="glUniform2ui"/>
+ </command>
+ <command>
+ <proto>void <name>glUniform2uiv</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*2">const <ptype>GLuint</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniform2uivEXT</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*2">const <ptype>GLuint</ptype> *<name>value</name></param>
+ <alias name="glUniform2uiv"/>
+ </command>
+ <command>
+ <proto>void <name>glUniform3d</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLdouble</ptype> <name>x</name></param>
+ <param><ptype>GLdouble</ptype> <name>y</name></param>
+ <param><ptype>GLdouble</ptype> <name>z</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniform3dv</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*3">const <ptype>GLdouble</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniform3f</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLfloat</ptype> <name>v0</name></param>
+ <param><ptype>GLfloat</ptype> <name>v1</name></param>
+ <param><ptype>GLfloat</ptype> <name>v2</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniform3fARB</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLfloat</ptype> <name>v0</name></param>
+ <param><ptype>GLfloat</ptype> <name>v1</name></param>
+ <param><ptype>GLfloat</ptype> <name>v2</name></param>
+ <alias name="glUniform3f"/>
+ </command>
+ <command>
+ <proto>void <name>glUniform3fv</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*3">const <ptype>GLfloat</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniform3fvARB</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*3">const <ptype>GLfloat</ptype> *<name>value</name></param>
+ <alias name="glUniform3fv"/>
+ </command>
+ <command>
+ <proto>void <name>glUniform3i</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLint</ptype> <name>v0</name></param>
+ <param><ptype>GLint</ptype> <name>v1</name></param>
+ <param><ptype>GLint</ptype> <name>v2</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniform3i64NV</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLint64EXT</ptype> <name>x</name></param>
+ <param><ptype>GLint64EXT</ptype> <name>y</name></param>
+ <param><ptype>GLint64EXT</ptype> <name>z</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniform3i64vNV</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*3">const <ptype>GLint64EXT</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniform3iARB</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLint</ptype> <name>v0</name></param>
+ <param><ptype>GLint</ptype> <name>v1</name></param>
+ <param><ptype>GLint</ptype> <name>v2</name></param>
+ <alias name="glUniform3i"/>
+ </command>
+ <command>
+ <proto>void <name>glUniform3iv</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*3">const <ptype>GLint</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniform3ivARB</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*3">const <ptype>GLint</ptype> *<name>value</name></param>
+ <alias name="glUniform3iv"/>
+ </command>
+ <command>
+ <proto>void <name>glUniform3ui</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLuint</ptype> <name>v0</name></param>
+ <param><ptype>GLuint</ptype> <name>v1</name></param>
+ <param><ptype>GLuint</ptype> <name>v2</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniform3ui64NV</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLuint64EXT</ptype> <name>x</name></param>
+ <param><ptype>GLuint64EXT</ptype> <name>y</name></param>
+ <param><ptype>GLuint64EXT</ptype> <name>z</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniform3ui64vNV</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*3">const <ptype>GLuint64EXT</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniform3uiEXT</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLuint</ptype> <name>v0</name></param>
+ <param><ptype>GLuint</ptype> <name>v1</name></param>
+ <param><ptype>GLuint</ptype> <name>v2</name></param>
+ <alias name="glUniform3ui"/>
+ </command>
+ <command>
+ <proto>void <name>glUniform3uiv</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*3">const <ptype>GLuint</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniform3uivEXT</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*3">const <ptype>GLuint</ptype> *<name>value</name></param>
+ <alias name="glUniform3uiv"/>
+ </command>
+ <command>
+ <proto>void <name>glUniform4d</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLdouble</ptype> <name>x</name></param>
+ <param><ptype>GLdouble</ptype> <name>y</name></param>
+ <param><ptype>GLdouble</ptype> <name>z</name></param>
+ <param><ptype>GLdouble</ptype> <name>w</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniform4dv</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*4">const <ptype>GLdouble</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniform4f</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLfloat</ptype> <name>v0</name></param>
+ <param><ptype>GLfloat</ptype> <name>v1</name></param>
+ <param><ptype>GLfloat</ptype> <name>v2</name></param>
+ <param><ptype>GLfloat</ptype> <name>v3</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniform4fARB</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLfloat</ptype> <name>v0</name></param>
+ <param><ptype>GLfloat</ptype> <name>v1</name></param>
+ <param><ptype>GLfloat</ptype> <name>v2</name></param>
+ <param><ptype>GLfloat</ptype> <name>v3</name></param>
+ <alias name="glUniform4f"/>
+ </command>
+ <command>
+ <proto>void <name>glUniform4fv</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*4">const <ptype>GLfloat</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniform4fvARB</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*4">const <ptype>GLfloat</ptype> *<name>value</name></param>
+ <alias name="glUniform4fv"/>
+ </command>
+ <command>
+ <proto>void <name>glUniform4i</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLint</ptype> <name>v0</name></param>
+ <param><ptype>GLint</ptype> <name>v1</name></param>
+ <param><ptype>GLint</ptype> <name>v2</name></param>
+ <param><ptype>GLint</ptype> <name>v3</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniform4i64NV</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLint64EXT</ptype> <name>x</name></param>
+ <param><ptype>GLint64EXT</ptype> <name>y</name></param>
+ <param><ptype>GLint64EXT</ptype> <name>z</name></param>
+ <param><ptype>GLint64EXT</ptype> <name>w</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniform4i64vNV</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*4">const <ptype>GLint64EXT</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniform4iARB</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLint</ptype> <name>v0</name></param>
+ <param><ptype>GLint</ptype> <name>v1</name></param>
+ <param><ptype>GLint</ptype> <name>v2</name></param>
+ <param><ptype>GLint</ptype> <name>v3</name></param>
+ <alias name="glUniform4i"/>
+ </command>
+ <command>
+ <proto>void <name>glUniform4iv</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*4">const <ptype>GLint</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniform4ivARB</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*4">const <ptype>GLint</ptype> *<name>value</name></param>
+ <alias name="glUniform4iv"/>
+ </command>
+ <command>
+ <proto>void <name>glUniform4ui</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLuint</ptype> <name>v0</name></param>
+ <param><ptype>GLuint</ptype> <name>v1</name></param>
+ <param><ptype>GLuint</ptype> <name>v2</name></param>
+ <param><ptype>GLuint</ptype> <name>v3</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniform4ui64NV</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLuint64EXT</ptype> <name>x</name></param>
+ <param><ptype>GLuint64EXT</ptype> <name>y</name></param>
+ <param><ptype>GLuint64EXT</ptype> <name>z</name></param>
+ <param><ptype>GLuint64EXT</ptype> <name>w</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniform4ui64vNV</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*4">const <ptype>GLuint64EXT</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniform4uiEXT</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLuint</ptype> <name>v0</name></param>
+ <param><ptype>GLuint</ptype> <name>v1</name></param>
+ <param><ptype>GLuint</ptype> <name>v2</name></param>
+ <param><ptype>GLuint</ptype> <name>v3</name></param>
+ <alias name="glUniform4ui"/>
+ </command>
+ <command>
+ <proto>void <name>glUniform4uiv</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*4">const <ptype>GLuint</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniform4uivEXT</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*4">const <ptype>GLuint</ptype> *<name>value</name></param>
+ <alias name="glUniform4uiv"/>
+ </command>
+ <command>
+ <proto>void <name>glUniformBlockBinding</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLuint</ptype> <name>uniformBlockIndex</name></param>
+ <param><ptype>GLuint</ptype> <name>uniformBlockBinding</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniformBufferEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniformHandleui64ARB</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLuint64</ptype> <name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniformHandleui64NV</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLuint64</ptype> <name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniformHandleui64vARB</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count">const <ptype>GLuint64</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniformHandleui64vNV</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count">const <ptype>GLuint64</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniformMatrix2dv</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="count*4">const <ptype>GLdouble</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniformMatrix2fv</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="count*4">const <ptype>GLfloat</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniformMatrix2fvARB</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="count*4">const <ptype>GLfloat</ptype> *<name>value</name></param>
+ <alias name="glUniformMatrix2fv"/>
+ </command>
+ <command>
+ <proto>void <name>glUniformMatrix2x3dv</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="count*6">const <ptype>GLdouble</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniformMatrix2x3fv</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="count*6">const <ptype>GLfloat</ptype> *<name>value</name></param>
+ <glx type="render" opcode="305"/>
+ </command>
+ <command>
+ <proto>void <name>glUniformMatrix2x3fvNV</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="count*6">const <ptype>GLfloat</ptype> *<name>value</name></param>
+ <alias name="glUniformMatrix2x3fv"/>
+ </command>
+ <command>
+ <proto>void <name>glUniformMatrix2x4dv</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="count*8">const <ptype>GLdouble</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniformMatrix2x4fv</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="count*8">const <ptype>GLfloat</ptype> *<name>value</name></param>
+ <glx type="render" opcode="307"/>
+ </command>
+ <command>
+ <proto>void <name>glUniformMatrix2x4fvNV</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="count*8">const <ptype>GLfloat</ptype> *<name>value</name></param>
+ <alias name="glUniformMatrix2x4fv"/>
+ </command>
+ <command>
+ <proto>void <name>glUniformMatrix3dv</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="count*9">const <ptype>GLdouble</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniformMatrix3fv</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="count*9">const <ptype>GLfloat</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniformMatrix3fvARB</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="count*9">const <ptype>GLfloat</ptype> *<name>value</name></param>
+ <alias name="glUniformMatrix3fv"/>
+ </command>
+ <command>
+ <proto>void <name>glUniformMatrix3x2dv</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="count*6">const <ptype>GLdouble</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniformMatrix3x2fv</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="count*6">const <ptype>GLfloat</ptype> *<name>value</name></param>
+ <glx type="render" opcode="306"/>
+ </command>
+ <command>
+ <proto>void <name>glUniformMatrix3x2fvNV</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="count*6">const <ptype>GLfloat</ptype> *<name>value</name></param>
+ <alias name="glUniformMatrix3x2fv"/>
+ </command>
+ <command>
+ <proto>void <name>glUniformMatrix3x4dv</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="count*12">const <ptype>GLdouble</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniformMatrix3x4fv</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="count*12">const <ptype>GLfloat</ptype> *<name>value</name></param>
+ <glx type="render" opcode="309"/>
+ </command>
+ <command>
+ <proto>void <name>glUniformMatrix3x4fvNV</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="count*12">const <ptype>GLfloat</ptype> *<name>value</name></param>
+ <alias name="glUniformMatrix3x4fv"/>
+ </command>
+ <command>
+ <proto>void <name>glUniformMatrix4dv</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="count*16">const <ptype>GLdouble</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniformMatrix4fv</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="count*16">const <ptype>GLfloat</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniformMatrix4fvARB</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="count*16">const <ptype>GLfloat</ptype> *<name>value</name></param>
+ <alias name="glUniformMatrix4fv"/>
+ </command>
+ <command>
+ <proto>void <name>glUniformMatrix4x2dv</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="count*8">const <ptype>GLdouble</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniformMatrix4x2fv</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="count*8">const <ptype>GLfloat</ptype> *<name>value</name></param>
+ <glx type="render" opcode="308"/>
+ </command>
+ <command>
+ <proto>void <name>glUniformMatrix4x2fvNV</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="count*8">const <ptype>GLfloat</ptype> *<name>value</name></param>
+ <alias name="glUniformMatrix4x2fv"/>
+ </command>
+ <command>
+ <proto>void <name>glUniformMatrix4x3dv</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="count*12">const <ptype>GLdouble</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniformMatrix4x3fv</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="count*12">const <ptype>GLfloat</ptype> *<name>value</name></param>
+ <glx type="render" opcode="310"/>
+ </command>
+ <command>
+ <proto>void <name>glUniformMatrix4x3fvNV</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>transpose</name></param>
+ <param len="count*12">const <ptype>GLfloat</ptype> *<name>value</name></param>
+ <alias name="glUniformMatrix4x3fv"/>
+ </command>
+ <command>
+ <proto>void <name>glUniformSubroutinesuiv</name></proto>
+ <param><ptype>GLenum</ptype> <name>shadertype</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count">const <ptype>GLuint</ptype> *<name>indices</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniformui64NV</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLuint64EXT</ptype> <name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUniformui64vNV</name></proto>
+ <param><ptype>GLint</ptype> <name>location</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*1">const <ptype>GLuint64EXT</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUnlockArraysEXT</name></proto>
+ </command>
+ <command>
+ <proto group="Boolean"><ptype>GLboolean</ptype> <name>glUnmapBuffer</name></proto>
+ <param group="BufferTargetARB"><ptype>GLenum</ptype> <name>target</name></param>
+ </command>
+ <command>
+ <proto group="Boolean"><ptype>GLboolean</ptype> <name>glUnmapBufferARB</name></proto>
+ <param group="BufferTargetARB"><ptype>GLenum</ptype> <name>target</name></param>
+ <alias name="glUnmapBuffer"/>
+ </command>
+ <command>
+ <proto><ptype>GLboolean</ptype> <name>glUnmapBufferOES</name></proto>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <alias name="glUnmapBuffer"/>
+ </command>
+ <command>
+ <proto><ptype>GLboolean</ptype> <name>glUnmapNamedBuffer</name></proto>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ </command>
+ <command>
+ <proto group="Boolean"><ptype>GLboolean</ptype> <name>glUnmapNamedBufferEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUnmapObjectBufferATI</name></proto>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUnmapTexture2DINTEL</name></proto>
+ <param><ptype>GLuint</ptype> <name>texture</name></param>
+ <param><ptype>GLint</ptype> <name>level</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUpdateObjectBufferATI</name></proto>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <param><ptype>GLuint</ptype> <name>offset</name></param>
+ <param><ptype>GLsizei</ptype> <name>size</name></param>
+ <param len="size">const void *<name>pointer</name></param>
+ <param group="PreserveModeATI"><ptype>GLenum</ptype> <name>preserve</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUseProgram</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUseProgramObjectARB</name></proto>
+ <param group="handleARB"><ptype>GLhandleARB</ptype> <name>programObj</name></param>
+ <alias name="glUseProgram"/>
+ </command>
+ <command>
+ <proto>void <name>glUseProgramStages</name></proto>
+ <param><ptype>GLuint</ptype> <name>pipeline</name></param>
+ <param><ptype>GLbitfield</ptype> <name>stages</name></param>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUseProgramStagesEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>pipeline</name></param>
+ <param><ptype>GLbitfield</ptype> <name>stages</name></param>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ </command>
+ <command>
+ <proto>void <name>glUseShaderProgramEXT</name></proto>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVDPAUFiniNV</name></proto>
+ </command>
+ <command>
+ <proto>void <name>glVDPAUGetSurfaceivNV</name></proto>
+ <param group="vdpauSurfaceNV"><ptype>GLvdpauSurfaceNV</ptype> <name>surface</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLsizei</ptype> <name>bufSize</name></param>
+ <param><ptype>GLsizei</ptype> *<name>length</name></param>
+ <param len="bufSize"><ptype>GLint</ptype> *<name>values</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVDPAUInitNV</name></proto>
+ <param>const void *<name>vdpDevice</name></param>
+ <param>const void *<name>getProcAddress</name></param>
+ </command>
+ <command>
+ <proto><ptype>GLboolean</ptype> <name>glVDPAUIsSurfaceNV</name></proto>
+ <param group="vdpauSurfaceNV"><ptype>GLvdpauSurfaceNV</ptype> <name>surface</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVDPAUMapSurfacesNV</name></proto>
+ <param><ptype>GLsizei</ptype> <name>numSurfaces</name></param>
+ <param group="vdpauSurfaceNV" len="numSurfaces">const <ptype>GLvdpauSurfaceNV</ptype> *<name>surfaces</name></param>
+ </command>
+ <command>
+ <proto group="vdpauSurfaceNV"><ptype>GLvdpauSurfaceNV</ptype> <name>glVDPAURegisterOutputSurfaceNV</name></proto>
+ <param>const void *<name>vdpSurface</name></param>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLsizei</ptype> <name>numTextureNames</name></param>
+ <param len="numTextureNames">const <ptype>GLuint</ptype> *<name>textureNames</name></param>
+ </command>
+ <command>
+ <proto group="vdpauSurfaceNV"><ptype>GLvdpauSurfaceNV</ptype> <name>glVDPAURegisterVideoSurfaceNV</name></proto>
+ <param>const void *<name>vdpSurface</name></param>
+ <param><ptype>GLenum</ptype> <name>target</name></param>
+ <param><ptype>GLsizei</ptype> <name>numTextureNames</name></param>
+ <param len="numTextureNames">const <ptype>GLuint</ptype> *<name>textureNames</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVDPAUSurfaceAccessNV</name></proto>
+ <param group="vdpauSurfaceNV"><ptype>GLvdpauSurfaceNV</ptype> <name>surface</name></param>
+ <param><ptype>GLenum</ptype> <name>access</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVDPAUUnmapSurfacesNV</name></proto>
+ <param><ptype>GLsizei</ptype> <name>numSurface</name></param>
+ <param group="vdpauSurfaceNV" len="numSurface">const <ptype>GLvdpauSurfaceNV</ptype> *<name>surfaces</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVDPAUUnregisterSurfaceNV</name></proto>
+ <param group="vdpauSurfaceNV"><ptype>GLvdpauSurfaceNV</ptype> <name>surface</name></param>
+ </command>
+ <command>
+ <proto>void <name>glValidateProgram</name></proto>
+ <param><ptype>GLuint</ptype> <name>program</name></param>
+ </command>
+ <command>
+ <proto>void <name>glValidateProgramARB</name></proto>
+ <param group="handleARB"><ptype>GLhandleARB</ptype> <name>programObj</name></param>
+ <alias name="glValidateProgram"/>
+ </command>
+ <command>
+ <proto>void <name>glValidateProgramPipeline</name></proto>
+ <param><ptype>GLuint</ptype> <name>pipeline</name></param>
+ </command>
+ <command>
+ <proto>void <name>glValidateProgramPipelineEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>pipeline</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVariantArrayObjectATI</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <param group="ScalarType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <param><ptype>GLuint</ptype> <name>offset</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVariantPointerEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <param group="ScalarType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLuint</ptype> <name>stride</name></param>
+ <param len="COMPSIZE(id,type,stride)">const void *<name>addr</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVariantbvEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <param len="COMPSIZE(id)">const <ptype>GLbyte</ptype> *<name>addr</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVariantdvEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <param len="COMPSIZE(id)">const <ptype>GLdouble</ptype> *<name>addr</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVariantfvEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <param len="COMPSIZE(id)">const <ptype>GLfloat</ptype> *<name>addr</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVariantivEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <param len="COMPSIZE(id)">const <ptype>GLint</ptype> *<name>addr</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVariantsvEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <param len="COMPSIZE(id)">const <ptype>GLshort</ptype> *<name>addr</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVariantubvEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <param len="COMPSIZE(id)">const <ptype>GLubyte</ptype> *<name>addr</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVariantuivEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <param len="COMPSIZE(id)">const <ptype>GLuint</ptype> *<name>addr</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVariantusvEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>id</name></param>
+ <param len="COMPSIZE(id)">const <ptype>GLushort</ptype> *<name>addr</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertex2bOES</name></proto>
+ <param><ptype>GLbyte</ptype> <name>x</name></param>
+ <param><ptype>GLbyte</ptype> <name>y</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertex2bvOES</name></proto>
+ <param len="2">const <ptype>GLbyte</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertex2d</name></proto>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>x</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>y</name></param>
+ <vecequiv name="glVertex2dv"/>
+ </command>
+ <command>
+ <proto>void <name>glVertex2dv</name></proto>
+ <param group="CoordD" len="2">const <ptype>GLdouble</ptype> *<name>v</name></param>
+ <glx type="render" opcode="65"/>
+ </command>
+ <command>
+ <proto>void <name>glVertex2f</name></proto>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>x</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>y</name></param>
+ <vecequiv name="glVertex2fv"/>
+ </command>
+ <command>
+ <proto>void <name>glVertex2fv</name></proto>
+ <param group="CoordF" len="2">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ <glx type="render" opcode="66"/>
+ </command>
+ <command>
+ <proto>void <name>glVertex2hNV</name></proto>
+ <param group="Half16NV"><ptype>GLhalfNV</ptype> <name>x</name></param>
+ <param group="Half16NV"><ptype>GLhalfNV</ptype> <name>y</name></param>
+ <vecequiv name="glVertex2hvNV"/>
+ </command>
+ <command>
+ <proto>void <name>glVertex2hvNV</name></proto>
+ <param group="Half16NV" len="2">const <ptype>GLhalfNV</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4240"/>
+ </command>
+ <command>
+ <proto>void <name>glVertex2i</name></proto>
+ <param group="CoordI"><ptype>GLint</ptype> <name>x</name></param>
+ <param group="CoordI"><ptype>GLint</ptype> <name>y</name></param>
+ <vecequiv name="glVertex2iv"/>
+ </command>
+ <command>
+ <proto>void <name>glVertex2iv</name></proto>
+ <param group="CoordI" len="2">const <ptype>GLint</ptype> *<name>v</name></param>
+ <glx type="render" opcode="67"/>
+ </command>
+ <command>
+ <proto>void <name>glVertex2s</name></proto>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>x</name></param>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>y</name></param>
+ <vecequiv name="glVertex2sv"/>
+ </command>
+ <command>
+ <proto>void <name>glVertex2sv</name></proto>
+ <param group="CoordS" len="2">const <ptype>GLshort</ptype> *<name>v</name></param>
+ <glx type="render" opcode="68"/>
+ </command>
+ <command>
+ <proto>void <name>glVertex2xOES</name></proto>
+ <param><ptype>GLfixed</ptype> <name>x</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertex2xvOES</name></proto>
+ <param len="2">const <ptype>GLfixed</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertex3bOES</name></proto>
+ <param><ptype>GLbyte</ptype> <name>x</name></param>
+ <param><ptype>GLbyte</ptype> <name>y</name></param>
+ <param><ptype>GLbyte</ptype> <name>z</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertex3bvOES</name></proto>
+ <param len="3">const <ptype>GLbyte</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertex3d</name></proto>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>x</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>y</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>z</name></param>
+ <vecequiv name="glVertex3dv"/>
+ </command>
+ <command>
+ <proto>void <name>glVertex3dv</name></proto>
+ <param group="CoordD" len="3">const <ptype>GLdouble</ptype> *<name>v</name></param>
+ <glx type="render" opcode="69"/>
+ </command>
+ <command>
+ <proto>void <name>glVertex3f</name></proto>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>x</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>y</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>z</name></param>
+ <vecequiv name="glVertex3fv"/>
+ </command>
+ <command>
+ <proto>void <name>glVertex3fv</name></proto>
+ <param group="CoordF" len="3">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ <glx type="render" opcode="70"/>
+ </command>
+ <command>
+ <proto>void <name>glVertex3hNV</name></proto>
+ <param group="Half16NV"><ptype>GLhalfNV</ptype> <name>x</name></param>
+ <param group="Half16NV"><ptype>GLhalfNV</ptype> <name>y</name></param>
+ <param group="Half16NV"><ptype>GLhalfNV</ptype> <name>z</name></param>
+ <vecequiv name="glVertex3hvNV"/>
+ </command>
+ <command>
+ <proto>void <name>glVertex3hvNV</name></proto>
+ <param group="Half16NV" len="3">const <ptype>GLhalfNV</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4241"/>
+ </command>
+ <command>
+ <proto>void <name>glVertex3i</name></proto>
+ <param group="CoordI"><ptype>GLint</ptype> <name>x</name></param>
+ <param group="CoordI"><ptype>GLint</ptype> <name>y</name></param>
+ <param group="CoordI"><ptype>GLint</ptype> <name>z</name></param>
+ <vecequiv name="glVertex3iv"/>
+ </command>
+ <command>
+ <proto>void <name>glVertex3iv</name></proto>
+ <param group="CoordI" len="3">const <ptype>GLint</ptype> *<name>v</name></param>
+ <glx type="render" opcode="71"/>
+ </command>
+ <command>
+ <proto>void <name>glVertex3s</name></proto>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>x</name></param>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>y</name></param>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>z</name></param>
+ <vecequiv name="glVertex3sv"/>
+ </command>
+ <command>
+ <proto>void <name>glVertex3sv</name></proto>
+ <param group="CoordS" len="3">const <ptype>GLshort</ptype> *<name>v</name></param>
+ <glx type="render" opcode="72"/>
+ </command>
+ <command>
+ <proto>void <name>glVertex3xOES</name></proto>
+ <param><ptype>GLfixed</ptype> <name>x</name></param>
+ <param><ptype>GLfixed</ptype> <name>y</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertex3xvOES</name></proto>
+ <param len="3">const <ptype>GLfixed</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertex4bOES</name></proto>
+ <param><ptype>GLbyte</ptype> <name>x</name></param>
+ <param><ptype>GLbyte</ptype> <name>y</name></param>
+ <param><ptype>GLbyte</ptype> <name>z</name></param>
+ <param><ptype>GLbyte</ptype> <name>w</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertex4bvOES</name></proto>
+ <param len="4">const <ptype>GLbyte</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertex4d</name></proto>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>x</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>y</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>z</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>w</name></param>
+ <vecequiv name="glVertex4dv"/>
+ </command>
+ <command>
+ <proto>void <name>glVertex4dv</name></proto>
+ <param group="CoordD" len="4">const <ptype>GLdouble</ptype> *<name>v</name></param>
+ <glx type="render" opcode="73"/>
+ </command>
+ <command>
+ <proto>void <name>glVertex4f</name></proto>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>x</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>y</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>z</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>w</name></param>
+ <vecequiv name="glVertex4fv"/>
+ </command>
+ <command>
+ <proto>void <name>glVertex4fv</name></proto>
+ <param group="CoordF" len="4">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ <glx type="render" opcode="74"/>
+ </command>
+ <command>
+ <proto>void <name>glVertex4hNV</name></proto>
+ <param group="Half16NV"><ptype>GLhalfNV</ptype> <name>x</name></param>
+ <param group="Half16NV"><ptype>GLhalfNV</ptype> <name>y</name></param>
+ <param group="Half16NV"><ptype>GLhalfNV</ptype> <name>z</name></param>
+ <param group="Half16NV"><ptype>GLhalfNV</ptype> <name>w</name></param>
+ <vecequiv name="glVertex4hvNV"/>
+ </command>
+ <command>
+ <proto>void <name>glVertex4hvNV</name></proto>
+ <param group="Half16NV" len="4">const <ptype>GLhalfNV</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4242"/>
+ </command>
+ <command>
+ <proto>void <name>glVertex4i</name></proto>
+ <param group="CoordI"><ptype>GLint</ptype> <name>x</name></param>
+ <param group="CoordI"><ptype>GLint</ptype> <name>y</name></param>
+ <param group="CoordI"><ptype>GLint</ptype> <name>z</name></param>
+ <param group="CoordI"><ptype>GLint</ptype> <name>w</name></param>
+ <vecequiv name="glVertex4iv"/>
+ </command>
+ <command>
+ <proto>void <name>glVertex4iv</name></proto>
+ <param group="CoordI" len="4">const <ptype>GLint</ptype> *<name>v</name></param>
+ <glx type="render" opcode="75"/>
+ </command>
+ <command>
+ <proto>void <name>glVertex4s</name></proto>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>x</name></param>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>y</name></param>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>z</name></param>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>w</name></param>
+ <vecequiv name="glVertex4sv"/>
+ </command>
+ <command>
+ <proto>void <name>glVertex4sv</name></proto>
+ <param group="CoordS" len="4">const <ptype>GLshort</ptype> *<name>v</name></param>
+ <glx type="render" opcode="76"/>
+ </command>
+ <command>
+ <proto>void <name>glVertex4xOES</name></proto>
+ <param><ptype>GLfixed</ptype> <name>x</name></param>
+ <param><ptype>GLfixed</ptype> <name>y</name></param>
+ <param><ptype>GLfixed</ptype> <name>z</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertex4xvOES</name></proto>
+ <param len="4">const <ptype>GLfixed</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexArrayAttribBinding</name></proto>
+ <param><ptype>GLuint</ptype> <name>vaobj</name></param>
+ <param><ptype>GLuint</ptype> <name>attribindex</name></param>
+ <param><ptype>GLuint</ptype> <name>bindingindex</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexArrayAttribFormat</name></proto>
+ <param><ptype>GLuint</ptype> <name>vaobj</name></param>
+ <param><ptype>GLuint</ptype> <name>attribindex</name></param>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLboolean</ptype> <name>normalized</name></param>
+ <param><ptype>GLuint</ptype> <name>relativeoffset</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexArrayAttribIFormat</name></proto>
+ <param><ptype>GLuint</ptype> <name>vaobj</name></param>
+ <param><ptype>GLuint</ptype> <name>attribindex</name></param>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLuint</ptype> <name>relativeoffset</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexArrayAttribLFormat</name></proto>
+ <param><ptype>GLuint</ptype> <name>vaobj</name></param>
+ <param><ptype>GLuint</ptype> <name>attribindex</name></param>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLuint</ptype> <name>relativeoffset</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexArrayBindVertexBufferEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>vaobj</name></param>
+ <param><ptype>GLuint</ptype> <name>bindingindex</name></param>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <param group="BufferOffset"><ptype>GLintptr</ptype> <name>offset</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexArrayBindingDivisor</name></proto>
+ <param><ptype>GLuint</ptype> <name>vaobj</name></param>
+ <param><ptype>GLuint</ptype> <name>bindingindex</name></param>
+ <param><ptype>GLuint</ptype> <name>divisor</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexArrayColorOffsetEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>vaobj</name></param>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param group="ColorPointerType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ <param><ptype>GLintptr</ptype> <name>offset</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexArrayEdgeFlagOffsetEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>vaobj</name></param>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ <param><ptype>GLintptr</ptype> <name>offset</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexArrayElementBuffer</name></proto>
+ <param><ptype>GLuint</ptype> <name>vaobj</name></param>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexArrayFogCoordOffsetEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>vaobj</name></param>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <param group="FogCoordinatePointerType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ <param><ptype>GLintptr</ptype> <name>offset</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexArrayIndexOffsetEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>vaobj</name></param>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <param group="IndexPointerType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ <param><ptype>GLintptr</ptype> <name>offset</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexArrayMultiTexCoordOffsetEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>vaobj</name></param>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <param><ptype>GLenum</ptype> <name>texunit</name></param>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param group="TexCoordPointerType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ <param><ptype>GLintptr</ptype> <name>offset</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexArrayNormalOffsetEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>vaobj</name></param>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <param group="NormalPointerType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ <param><ptype>GLintptr</ptype> <name>offset</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexArrayParameteriAPPLE</name></proto>
+ <param group="VertexArrayPNameAPPLE"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLint</ptype> <name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexArrayRangeAPPLE</name></proto>
+ <param><ptype>GLsizei</ptype> <name>length</name></param>
+ <param len="length">void *<name>pointer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexArrayRangeNV</name></proto>
+ <param><ptype>GLsizei</ptype> <name>length</name></param>
+ <param len="COMPSIZE(length)">const void *<name>pointer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexArraySecondaryColorOffsetEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>vaobj</name></param>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param group="ColorPointerType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ <param><ptype>GLintptr</ptype> <name>offset</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexArrayTexCoordOffsetEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>vaobj</name></param>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param group="TexCoordPointerType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ <param><ptype>GLintptr</ptype> <name>offset</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexArrayVertexAttribBindingEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>vaobj</name></param>
+ <param><ptype>GLuint</ptype> <name>attribindex</name></param>
+ <param><ptype>GLuint</ptype> <name>bindingindex</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexArrayVertexAttribDivisorEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>vaobj</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLuint</ptype> <name>divisor</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexArrayVertexAttribFormatEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>vaobj</name></param>
+ <param><ptype>GLuint</ptype> <name>attribindex</name></param>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>normalized</name></param>
+ <param><ptype>GLuint</ptype> <name>relativeoffset</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexArrayVertexAttribIFormatEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>vaobj</name></param>
+ <param><ptype>GLuint</ptype> <name>attribindex</name></param>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLuint</ptype> <name>relativeoffset</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexArrayVertexAttribIOffsetEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>vaobj</name></param>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param group="VertexAttribEnum"><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ <param><ptype>GLintptr</ptype> <name>offset</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexArrayVertexAttribLFormatEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>vaobj</name></param>
+ <param><ptype>GLuint</ptype> <name>attribindex</name></param>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLuint</ptype> <name>relativeoffset</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexArrayVertexAttribLOffsetEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>vaobj</name></param>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ <param group="BufferOffset"><ptype>GLintptr</ptype> <name>offset</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexArrayVertexAttribOffsetEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>vaobj</name></param>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param group="VertexAttribPointerType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLboolean</ptype> <name>normalized</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ <param><ptype>GLintptr</ptype> <name>offset</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexArrayVertexBindingDivisorEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>vaobj</name></param>
+ <param><ptype>GLuint</ptype> <name>bindingindex</name></param>
+ <param><ptype>GLuint</ptype> <name>divisor</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexArrayVertexBuffer</name></proto>
+ <param><ptype>GLuint</ptype> <name>vaobj</name></param>
+ <param><ptype>GLuint</ptype> <name>bindingindex</name></param>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <param><ptype>GLintptr</ptype> <name>offset</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexArrayVertexBuffers</name></proto>
+ <param><ptype>GLuint</ptype> <name>vaobj</name></param>
+ <param><ptype>GLuint</ptype> <name>first</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param>const <ptype>GLuint</ptype> *<name>buffers</name></param>
+ <param>const <ptype>GLintptr</ptype> *<name>offsets</name></param>
+ <param>const <ptype>GLsizei</ptype> *<name>strides</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexArrayVertexOffsetEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>vaobj</name></param>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param group="VertexPointerType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ <param><ptype>GLintptr</ptype> <name>offset</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib1d</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLdouble</ptype> <name>x</name></param>
+ <vecequiv name="glVertexAttrib1dv"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib1dARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLdouble</ptype> <name>x</name></param>
+ <alias name="glVertexAttrib1d"/>
+ <vecequiv name="glVertexAttrib1dvARB"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib1dNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLdouble</ptype> <name>x</name></param>
+ <alias name="glVertexAttrib1d"/>
+ <vecequiv name="glVertexAttrib1dvNV"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib1dv</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="1">const <ptype>GLdouble</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4197"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib1dvARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="1">const <ptype>GLdouble</ptype> *<name>v</name></param>
+ <alias name="glVertexAttrib1dv"/>
+ <glx type="render" opcode="4197"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib1dvNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="1">const <ptype>GLdouble</ptype> *<name>v</name></param>
+ <alias name="glVertexAttrib1dv"/>
+ <glx type="render" opcode="4197"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib1f</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLfloat</ptype> <name>x</name></param>
+ <vecequiv name="glVertexAttrib1fv"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib1fARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLfloat</ptype> <name>x</name></param>
+ <alias name="glVertexAttrib1f"/>
+ <vecequiv name="glVertexAttrib1fvARB"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib1fNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLfloat</ptype> <name>x</name></param>
+ <alias name="glVertexAttrib1f"/>
+ <vecequiv name="glVertexAttrib1fvNV"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib1fv</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="1">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4193"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib1fvARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="1">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ <alias name="glVertexAttrib1fv"/>
+ <glx type="render" opcode="4193"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib1fvNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="1">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ <alias name="glVertexAttrib1fv"/>
+ <glx type="render" opcode="4193"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib1hNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param group="Half16NV"><ptype>GLhalfNV</ptype> <name>x</name></param>
+ <vecequiv name="glVertexAttrib1hvNV"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib1hvNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param group="Half16NV" len="1">const <ptype>GLhalfNV</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4257"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib1s</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLshort</ptype> <name>x</name></param>
+ <vecequiv name="glVertexAttrib1sv"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib1sARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLshort</ptype> <name>x</name></param>
+ <alias name="glVertexAttrib1s"/>
+ <vecequiv name="glVertexAttrib1svARB"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib1sNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLshort</ptype> <name>x</name></param>
+ <alias name="glVertexAttrib1s"/>
+ <vecequiv name="glVertexAttrib1svNV"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib1sv</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="1">const <ptype>GLshort</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4189"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib1svARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="1">const <ptype>GLshort</ptype> *<name>v</name></param>
+ <alias name="glVertexAttrib1sv"/>
+ <glx type="render" opcode="4189"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib1svNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="1">const <ptype>GLshort</ptype> *<name>v</name></param>
+ <alias name="glVertexAttrib1sv"/>
+ <glx type="render" opcode="4189"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib2d</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLdouble</ptype> <name>x</name></param>
+ <param><ptype>GLdouble</ptype> <name>y</name></param>
+ <vecequiv name="glVertexAttrib2dv"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib2dARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLdouble</ptype> <name>x</name></param>
+ <param><ptype>GLdouble</ptype> <name>y</name></param>
+ <alias name="glVertexAttrib2d"/>
+ <vecequiv name="glVertexAttrib2dvARB"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib2dNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLdouble</ptype> <name>x</name></param>
+ <param><ptype>GLdouble</ptype> <name>y</name></param>
+ <alias name="glVertexAttrib2d"/>
+ <vecequiv name="glVertexAttrib2dvNV"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib2dv</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="2">const <ptype>GLdouble</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4198"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib2dvARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="2">const <ptype>GLdouble</ptype> *<name>v</name></param>
+ <alias name="glVertexAttrib2dv"/>
+ <glx type="render" opcode="4198"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib2dvNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="2">const <ptype>GLdouble</ptype> *<name>v</name></param>
+ <alias name="glVertexAttrib2dv"/>
+ <glx type="render" opcode="4198"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib2f</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLfloat</ptype> <name>x</name></param>
+ <param><ptype>GLfloat</ptype> <name>y</name></param>
+ <vecequiv name="glVertexAttrib2fv"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib2fARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLfloat</ptype> <name>x</name></param>
+ <param><ptype>GLfloat</ptype> <name>y</name></param>
+ <alias name="glVertexAttrib2f"/>
+ <vecequiv name="glVertexAttrib2fvARB"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib2fNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLfloat</ptype> <name>x</name></param>
+ <param><ptype>GLfloat</ptype> <name>y</name></param>
+ <alias name="glVertexAttrib2f"/>
+ <vecequiv name="glVertexAttrib2fvNV"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib2fv</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="2">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4194"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib2fvARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="2">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ <alias name="glVertexAttrib2fv"/>
+ <glx type="render" opcode="4194"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib2fvNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="2">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ <alias name="glVertexAttrib2fv"/>
+ <glx type="render" opcode="4194"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib2hNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param group="Half16NV"><ptype>GLhalfNV</ptype> <name>x</name></param>
+ <param group="Half16NV"><ptype>GLhalfNV</ptype> <name>y</name></param>
+ <vecequiv name="glVertexAttrib2hvNV"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib2hvNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param group="Half16NV" len="2">const <ptype>GLhalfNV</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4258"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib2s</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLshort</ptype> <name>x</name></param>
+ <param><ptype>GLshort</ptype> <name>y</name></param>
+ <vecequiv name="glVertexAttrib2sv"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib2sARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLshort</ptype> <name>x</name></param>
+ <param><ptype>GLshort</ptype> <name>y</name></param>
+ <alias name="glVertexAttrib2s"/>
+ <vecequiv name="glVertexAttrib2svARB"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib2sNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLshort</ptype> <name>x</name></param>
+ <param><ptype>GLshort</ptype> <name>y</name></param>
+ <alias name="glVertexAttrib2s"/>
+ <vecequiv name="glVertexAttrib2svNV"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib2sv</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="2">const <ptype>GLshort</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4190"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib2svARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="2">const <ptype>GLshort</ptype> *<name>v</name></param>
+ <alias name="glVertexAttrib2sv"/>
+ <glx type="render" opcode="4190"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib2svNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="2">const <ptype>GLshort</ptype> *<name>v</name></param>
+ <alias name="glVertexAttrib2sv"/>
+ <glx type="render" opcode="4190"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib3d</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLdouble</ptype> <name>x</name></param>
+ <param><ptype>GLdouble</ptype> <name>y</name></param>
+ <param><ptype>GLdouble</ptype> <name>z</name></param>
+ <vecequiv name="glVertexAttrib3dv"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib3dARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLdouble</ptype> <name>x</name></param>
+ <param><ptype>GLdouble</ptype> <name>y</name></param>
+ <param><ptype>GLdouble</ptype> <name>z</name></param>
+ <alias name="glVertexAttrib3d"/>
+ <vecequiv name="glVertexAttrib3dvARB"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib3dNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLdouble</ptype> <name>x</name></param>
+ <param><ptype>GLdouble</ptype> <name>y</name></param>
+ <param><ptype>GLdouble</ptype> <name>z</name></param>
+ <alias name="glVertexAttrib3d"/>
+ <vecequiv name="glVertexAttrib3dvNV"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib3dv</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="3">const <ptype>GLdouble</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4199"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib3dvARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="3">const <ptype>GLdouble</ptype> *<name>v</name></param>
+ <alias name="glVertexAttrib3dv"/>
+ <glx type="render" opcode="4199"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib3dvNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="3">const <ptype>GLdouble</ptype> *<name>v</name></param>
+ <alias name="glVertexAttrib3dv"/>
+ <glx type="render" opcode="4199"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib3f</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLfloat</ptype> <name>x</name></param>
+ <param><ptype>GLfloat</ptype> <name>y</name></param>
+ <param><ptype>GLfloat</ptype> <name>z</name></param>
+ <vecequiv name="glVertexAttrib3fv"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib3fARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLfloat</ptype> <name>x</name></param>
+ <param><ptype>GLfloat</ptype> <name>y</name></param>
+ <param><ptype>GLfloat</ptype> <name>z</name></param>
+ <alias name="glVertexAttrib3f"/>
+ <vecequiv name="glVertexAttrib3fvARB"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib3fNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLfloat</ptype> <name>x</name></param>
+ <param><ptype>GLfloat</ptype> <name>y</name></param>
+ <param><ptype>GLfloat</ptype> <name>z</name></param>
+ <alias name="glVertexAttrib3f"/>
+ <vecequiv name="glVertexAttrib3fvNV"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib3fv</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="3">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4195"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib3fvARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="3">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ <alias name="glVertexAttrib3fv"/>
+ <glx type="render" opcode="4195"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib3fvNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="3">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ <alias name="glVertexAttrib3fv"/>
+ <glx type="render" opcode="4195"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib3hNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param group="Half16NV"><ptype>GLhalfNV</ptype> <name>x</name></param>
+ <param group="Half16NV"><ptype>GLhalfNV</ptype> <name>y</name></param>
+ <param group="Half16NV"><ptype>GLhalfNV</ptype> <name>z</name></param>
+ <vecequiv name="glVertexAttrib3hvNV"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib3hvNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param group="Half16NV" len="3">const <ptype>GLhalfNV</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4259"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib3s</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLshort</ptype> <name>x</name></param>
+ <param><ptype>GLshort</ptype> <name>y</name></param>
+ <param><ptype>GLshort</ptype> <name>z</name></param>
+ <vecequiv name="glVertexAttrib3sv"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib3sARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLshort</ptype> <name>x</name></param>
+ <param><ptype>GLshort</ptype> <name>y</name></param>
+ <param><ptype>GLshort</ptype> <name>z</name></param>
+ <alias name="glVertexAttrib3s"/>
+ <vecequiv name="glVertexAttrib3svARB"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib3sNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLshort</ptype> <name>x</name></param>
+ <param><ptype>GLshort</ptype> <name>y</name></param>
+ <param><ptype>GLshort</ptype> <name>z</name></param>
+ <alias name="glVertexAttrib3s"/>
+ <vecequiv name="glVertexAttrib3svNV"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib3sv</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="3">const <ptype>GLshort</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4191"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib3svARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="3">const <ptype>GLshort</ptype> *<name>v</name></param>
+ <alias name="glVertexAttrib3sv"/>
+ <glx type="render" opcode="4191"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib3svNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="3">const <ptype>GLshort</ptype> *<name>v</name></param>
+ <alias name="glVertexAttrib3sv"/>
+ <glx type="render" opcode="4191"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib4Nbv</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLbyte</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib4NbvARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLbyte</ptype> *<name>v</name></param>
+ <alias name="glVertexAttrib4Nbv"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib4Niv</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLint</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib4NivARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLint</ptype> *<name>v</name></param>
+ <alias name="glVertexAttrib4Niv"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib4Nsv</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLshort</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib4NsvARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLshort</ptype> *<name>v</name></param>
+ <alias name="glVertexAttrib4Nsv"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib4Nub</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLubyte</ptype> <name>x</name></param>
+ <param><ptype>GLubyte</ptype> <name>y</name></param>
+ <param><ptype>GLubyte</ptype> <name>z</name></param>
+ <param><ptype>GLubyte</ptype> <name>w</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib4NubARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLubyte</ptype> <name>x</name></param>
+ <param><ptype>GLubyte</ptype> <name>y</name></param>
+ <param><ptype>GLubyte</ptype> <name>z</name></param>
+ <param><ptype>GLubyte</ptype> <name>w</name></param>
+ <alias name="glVertexAttrib4Nub"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib4Nubv</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLubyte</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4201"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib4NubvARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLubyte</ptype> *<name>v</name></param>
+ <alias name="glVertexAttrib4Nubv"/>
+ <glx type="render" opcode="4201"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib4Nuiv</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLuint</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib4NuivARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLuint</ptype> *<name>v</name></param>
+ <alias name="glVertexAttrib4Nuiv"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib4Nusv</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLushort</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib4NusvARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLushort</ptype> *<name>v</name></param>
+ <alias name="glVertexAttrib4Nusv"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib4bv</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLbyte</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib4bvARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLbyte</ptype> *<name>v</name></param>
+ <alias name="glVertexAttrib4bv"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib4d</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLdouble</ptype> <name>x</name></param>
+ <param><ptype>GLdouble</ptype> <name>y</name></param>
+ <param><ptype>GLdouble</ptype> <name>z</name></param>
+ <param><ptype>GLdouble</ptype> <name>w</name></param>
+ <vecequiv name="glVertexAttrib4dv"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib4dARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLdouble</ptype> <name>x</name></param>
+ <param><ptype>GLdouble</ptype> <name>y</name></param>
+ <param><ptype>GLdouble</ptype> <name>z</name></param>
+ <param><ptype>GLdouble</ptype> <name>w</name></param>
+ <alias name="glVertexAttrib4d"/>
+ <vecequiv name="glVertexAttrib4dvARB"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib4dNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLdouble</ptype> <name>x</name></param>
+ <param><ptype>GLdouble</ptype> <name>y</name></param>
+ <param><ptype>GLdouble</ptype> <name>z</name></param>
+ <param><ptype>GLdouble</ptype> <name>w</name></param>
+ <alias name="glVertexAttrib4d"/>
+ <vecequiv name="glVertexAttrib4dvNV"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib4dv</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLdouble</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4200"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib4dvARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLdouble</ptype> *<name>v</name></param>
+ <alias name="glVertexAttrib4dv"/>
+ <glx type="render" opcode="4200"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib4dvNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLdouble</ptype> *<name>v</name></param>
+ <alias name="glVertexAttrib4dv"/>
+ <glx type="render" opcode="4200"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib4f</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLfloat</ptype> <name>x</name></param>
+ <param><ptype>GLfloat</ptype> <name>y</name></param>
+ <param><ptype>GLfloat</ptype> <name>z</name></param>
+ <param><ptype>GLfloat</ptype> <name>w</name></param>
+ <vecequiv name="glVertexAttrib4fv"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib4fARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLfloat</ptype> <name>x</name></param>
+ <param><ptype>GLfloat</ptype> <name>y</name></param>
+ <param><ptype>GLfloat</ptype> <name>z</name></param>
+ <param><ptype>GLfloat</ptype> <name>w</name></param>
+ <alias name="glVertexAttrib4f"/>
+ <vecequiv name="glVertexAttrib4fvARB"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib4fNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLfloat</ptype> <name>x</name></param>
+ <param><ptype>GLfloat</ptype> <name>y</name></param>
+ <param><ptype>GLfloat</ptype> <name>z</name></param>
+ <param><ptype>GLfloat</ptype> <name>w</name></param>
+ <alias name="glVertexAttrib4f"/>
+ <vecequiv name="glVertexAttrib4fvNV"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib4fv</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4196"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib4fvARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ <alias name="glVertexAttrib4fv"/>
+ <glx type="render" opcode="4196"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib4fvNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ <alias name="glVertexAttrib4fv"/>
+ <glx type="render" opcode="4196"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib4hNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param group="Half16NV"><ptype>GLhalfNV</ptype> <name>x</name></param>
+ <param group="Half16NV"><ptype>GLhalfNV</ptype> <name>y</name></param>
+ <param group="Half16NV"><ptype>GLhalfNV</ptype> <name>z</name></param>
+ <param group="Half16NV"><ptype>GLhalfNV</ptype> <name>w</name></param>
+ <vecequiv name="glVertexAttrib4hvNV"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib4hvNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param group="Half16NV" len="4">const <ptype>GLhalfNV</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4260"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib4iv</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLint</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib4ivARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLint</ptype> *<name>v</name></param>
+ <alias name="glVertexAttrib4iv"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib4s</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLshort</ptype> <name>x</name></param>
+ <param><ptype>GLshort</ptype> <name>y</name></param>
+ <param><ptype>GLshort</ptype> <name>z</name></param>
+ <param><ptype>GLshort</ptype> <name>w</name></param>
+ <vecequiv name="glVertexAttrib4sv"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib4sARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLshort</ptype> <name>x</name></param>
+ <param><ptype>GLshort</ptype> <name>y</name></param>
+ <param><ptype>GLshort</ptype> <name>z</name></param>
+ <param><ptype>GLshort</ptype> <name>w</name></param>
+ <alias name="glVertexAttrib4s"/>
+ <vecequiv name="glVertexAttrib4svARB"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib4sNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLshort</ptype> <name>x</name></param>
+ <param><ptype>GLshort</ptype> <name>y</name></param>
+ <param><ptype>GLshort</ptype> <name>z</name></param>
+ <param><ptype>GLshort</ptype> <name>w</name></param>
+ <alias name="glVertexAttrib4s"/>
+ <vecequiv name="glVertexAttrib4svNV"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib4sv</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLshort</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4192"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib4svARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLshort</ptype> *<name>v</name></param>
+ <alias name="glVertexAttrib4sv"/>
+ <glx type="render" opcode="4192"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib4svNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLshort</ptype> *<name>v</name></param>
+ <alias name="glVertexAttrib4sv"/>
+ <glx type="render" opcode="4192"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib4ubNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param group="ColorUB"><ptype>GLubyte</ptype> <name>x</name></param>
+ <param group="ColorUB"><ptype>GLubyte</ptype> <name>y</name></param>
+ <param group="ColorUB"><ptype>GLubyte</ptype> <name>z</name></param>
+ <param group="ColorUB"><ptype>GLubyte</ptype> <name>w</name></param>
+ <alias name="glVertexAttrib4Nub"/>
+ <vecequiv name="glVertexAttrib4ubvNV"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib4ubv</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLubyte</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib4ubvARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLubyte</ptype> *<name>v</name></param>
+ <alias name="glVertexAttrib4ubv"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib4ubvNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param group="ColorUB" len="4">const <ptype>GLubyte</ptype> *<name>v</name></param>
+ <alias name="glVertexAttrib4Nubv"/>
+ <glx type="render" opcode="4201"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib4uiv</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLuint</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib4uivARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLuint</ptype> *<name>v</name></param>
+ <alias name="glVertexAttrib4uiv"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib4usv</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLushort</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttrib4usvARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLushort</ptype> *<name>v</name></param>
+ <alias name="glVertexAttrib4usv"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribArrayObjectATI</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param group="VertexAttribPointerType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>normalized</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ <param><ptype>GLuint</ptype> <name>buffer</name></param>
+ <param><ptype>GLuint</ptype> <name>offset</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribBinding</name></proto>
+ <param><ptype>GLuint</ptype> <name>attribindex</name></param>
+ <param><ptype>GLuint</ptype> <name>bindingindex</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribDivisor</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLuint</ptype> <name>divisor</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribDivisorANGLE</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLuint</ptype> <name>divisor</name></param>
+ <alias name="glVertexAttribDivisor"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribDivisorARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLuint</ptype> <name>divisor</name></param>
+ <alias name="glVertexAttribDivisor"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribDivisorEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLuint</ptype> <name>divisor</name></param>
+ <alias name="glVertexAttribDivisor"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribDivisorNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLuint</ptype> <name>divisor</name></param>
+ <alias name="glVertexAttribDivisor"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribFormat</name></proto>
+ <param><ptype>GLuint</ptype> <name>attribindex</name></param>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>normalized</name></param>
+ <param><ptype>GLuint</ptype> <name>relativeoffset</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribFormatNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>normalized</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribI1i</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLint</ptype> <name>x</name></param>
+ <vecequiv name="glVertexAttribI1iv"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribI1iEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLint</ptype> <name>x</name></param>
+ <alias name="glVertexAttribI1i"/>
+ <vecequiv name="glVertexAttribI1ivEXT"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribI1iv</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="1">const <ptype>GLint</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribI1ivEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="1">const <ptype>GLint</ptype> *<name>v</name></param>
+ <alias name="glVertexAttribI1iv"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribI1ui</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLuint</ptype> <name>x</name></param>
+ <vecequiv name="glVertexAttribI1uiv"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribI1uiEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLuint</ptype> <name>x</name></param>
+ <alias name="glVertexAttribI1ui"/>
+ <vecequiv name="glVertexAttribI1uivEXT"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribI1uiv</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="1">const <ptype>GLuint</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribI1uivEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="1">const <ptype>GLuint</ptype> *<name>v</name></param>
+ <alias name="glVertexAttribI1uiv"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribI2i</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLint</ptype> <name>x</name></param>
+ <param><ptype>GLint</ptype> <name>y</name></param>
+ <vecequiv name="glVertexAttribI2iv"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribI2iEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLint</ptype> <name>x</name></param>
+ <param><ptype>GLint</ptype> <name>y</name></param>
+ <alias name="glVertexAttribI2i"/>
+ <vecequiv name="glVertexAttribI2ivEXT"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribI2iv</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="2">const <ptype>GLint</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribI2ivEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="2">const <ptype>GLint</ptype> *<name>v</name></param>
+ <alias name="glVertexAttribI2iv"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribI2ui</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLuint</ptype> <name>x</name></param>
+ <param><ptype>GLuint</ptype> <name>y</name></param>
+ <vecequiv name="glVertexAttribI2uiv"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribI2uiEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLuint</ptype> <name>x</name></param>
+ <param><ptype>GLuint</ptype> <name>y</name></param>
+ <alias name="glVertexAttribI2ui"/>
+ <vecequiv name="glVertexAttribI2uivEXT"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribI2uiv</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="2">const <ptype>GLuint</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribI2uivEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="2">const <ptype>GLuint</ptype> *<name>v</name></param>
+ <alias name="glVertexAttribI2uiv"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribI3i</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLint</ptype> <name>x</name></param>
+ <param><ptype>GLint</ptype> <name>y</name></param>
+ <param><ptype>GLint</ptype> <name>z</name></param>
+ <vecequiv name="glVertexAttribI3iv"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribI3iEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLint</ptype> <name>x</name></param>
+ <param><ptype>GLint</ptype> <name>y</name></param>
+ <param><ptype>GLint</ptype> <name>z</name></param>
+ <alias name="glVertexAttribI3i"/>
+ <vecequiv name="glVertexAttribI3ivEXT"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribI3iv</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="3">const <ptype>GLint</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribI3ivEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="3">const <ptype>GLint</ptype> *<name>v</name></param>
+ <alias name="glVertexAttribI3iv"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribI3ui</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLuint</ptype> <name>x</name></param>
+ <param><ptype>GLuint</ptype> <name>y</name></param>
+ <param><ptype>GLuint</ptype> <name>z</name></param>
+ <vecequiv name="glVertexAttribI3uiv"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribI3uiEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLuint</ptype> <name>x</name></param>
+ <param><ptype>GLuint</ptype> <name>y</name></param>
+ <param><ptype>GLuint</ptype> <name>z</name></param>
+ <alias name="glVertexAttribI3ui"/>
+ <vecequiv name="glVertexAttribI3uivEXT"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribI3uiv</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="3">const <ptype>GLuint</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribI3uivEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="3">const <ptype>GLuint</ptype> *<name>v</name></param>
+ <alias name="glVertexAttribI3uiv"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribI4bv</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLbyte</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribI4bvEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLbyte</ptype> *<name>v</name></param>
+ <alias name="glVertexAttribI4bv"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribI4i</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLint</ptype> <name>x</name></param>
+ <param><ptype>GLint</ptype> <name>y</name></param>
+ <param><ptype>GLint</ptype> <name>z</name></param>
+ <param><ptype>GLint</ptype> <name>w</name></param>
+ <vecequiv name="glVertexAttribI4iv"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribI4iEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLint</ptype> <name>x</name></param>
+ <param><ptype>GLint</ptype> <name>y</name></param>
+ <param><ptype>GLint</ptype> <name>z</name></param>
+ <param><ptype>GLint</ptype> <name>w</name></param>
+ <alias name="glVertexAttribI4i"/>
+ <vecequiv name="glVertexAttribI4ivEXT"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribI4iv</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLint</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribI4ivEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLint</ptype> *<name>v</name></param>
+ <alias name="glVertexAttribI4iv"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribI4sv</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLshort</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribI4svEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLshort</ptype> *<name>v</name></param>
+ <alias name="glVertexAttribI4sv"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribI4ubv</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLubyte</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribI4ubvEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLubyte</ptype> *<name>v</name></param>
+ <alias name="glVertexAttribI4ubv"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribI4ui</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLuint</ptype> <name>x</name></param>
+ <param><ptype>GLuint</ptype> <name>y</name></param>
+ <param><ptype>GLuint</ptype> <name>z</name></param>
+ <param><ptype>GLuint</ptype> <name>w</name></param>
+ <vecequiv name="glVertexAttribI4uiv"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribI4uiEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLuint</ptype> <name>x</name></param>
+ <param><ptype>GLuint</ptype> <name>y</name></param>
+ <param><ptype>GLuint</ptype> <name>z</name></param>
+ <param><ptype>GLuint</ptype> <name>w</name></param>
+ <alias name="glVertexAttribI4ui"/>
+ <vecequiv name="glVertexAttribI4uivEXT"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribI4uiv</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLuint</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribI4uivEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLuint</ptype> *<name>v</name></param>
+ <alias name="glVertexAttribI4uiv"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribI4usv</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLushort</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribI4usvEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLushort</ptype> *<name>v</name></param>
+ <alias name="glVertexAttribI4usv"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribIFormat</name></proto>
+ <param><ptype>GLuint</ptype> <name>attribindex</name></param>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLuint</ptype> <name>relativeoffset</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribIFormatNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribIPointer</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param group="VertexAttribEnum"><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ <param len="COMPSIZE(size,type,stride)">const void *<name>pointer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribIPointerEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param group="VertexAttribEnum"><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ <param len="COMPSIZE(size,type,stride)">const void *<name>pointer</name></param>
+ <alias name="glVertexAttribIPointer"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribL1d</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLdouble</ptype> <name>x</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribL1dEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLdouble</ptype> <name>x</name></param>
+ <alias name="glVertexAttribL1d"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribL1dv</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="1">const <ptype>GLdouble</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribL1dvEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="1">const <ptype>GLdouble</ptype> *<name>v</name></param>
+ <alias name="glVertexAttribL1dv"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribL1i64NV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLint64EXT</ptype> <name>x</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribL1i64vNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="1">const <ptype>GLint64EXT</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribL1ui64ARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLuint64EXT</ptype> <name>x</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribL1ui64NV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLuint64EXT</ptype> <name>x</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribL1ui64vARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param>const <ptype>GLuint64EXT</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribL1ui64vNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="1">const <ptype>GLuint64EXT</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribL2d</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLdouble</ptype> <name>x</name></param>
+ <param><ptype>GLdouble</ptype> <name>y</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribL2dEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLdouble</ptype> <name>x</name></param>
+ <param><ptype>GLdouble</ptype> <name>y</name></param>
+ <alias name="glVertexAttribL2d"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribL2dv</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="2">const <ptype>GLdouble</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribL2dvEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="2">const <ptype>GLdouble</ptype> *<name>v</name></param>
+ <alias name="glVertexAttribL2dv"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribL2i64NV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLint64EXT</ptype> <name>x</name></param>
+ <param><ptype>GLint64EXT</ptype> <name>y</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribL2i64vNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="2">const <ptype>GLint64EXT</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribL2ui64NV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLuint64EXT</ptype> <name>x</name></param>
+ <param><ptype>GLuint64EXT</ptype> <name>y</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribL2ui64vNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="2">const <ptype>GLuint64EXT</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribL3d</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLdouble</ptype> <name>x</name></param>
+ <param><ptype>GLdouble</ptype> <name>y</name></param>
+ <param><ptype>GLdouble</ptype> <name>z</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribL3dEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLdouble</ptype> <name>x</name></param>
+ <param><ptype>GLdouble</ptype> <name>y</name></param>
+ <param><ptype>GLdouble</ptype> <name>z</name></param>
+ <alias name="glVertexAttribL3d"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribL3dv</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="3">const <ptype>GLdouble</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribL3dvEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="3">const <ptype>GLdouble</ptype> *<name>v</name></param>
+ <alias name="glVertexAttribL3dv"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribL3i64NV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLint64EXT</ptype> <name>x</name></param>
+ <param><ptype>GLint64EXT</ptype> <name>y</name></param>
+ <param><ptype>GLint64EXT</ptype> <name>z</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribL3i64vNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="3">const <ptype>GLint64EXT</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribL3ui64NV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLuint64EXT</ptype> <name>x</name></param>
+ <param><ptype>GLuint64EXT</ptype> <name>y</name></param>
+ <param><ptype>GLuint64EXT</ptype> <name>z</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribL3ui64vNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="3">const <ptype>GLuint64EXT</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribL4d</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLdouble</ptype> <name>x</name></param>
+ <param><ptype>GLdouble</ptype> <name>y</name></param>
+ <param><ptype>GLdouble</ptype> <name>z</name></param>
+ <param><ptype>GLdouble</ptype> <name>w</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribL4dEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLdouble</ptype> <name>x</name></param>
+ <param><ptype>GLdouble</ptype> <name>y</name></param>
+ <param><ptype>GLdouble</ptype> <name>z</name></param>
+ <param><ptype>GLdouble</ptype> <name>w</name></param>
+ <alias name="glVertexAttribL4d"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribL4dv</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLdouble</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribL4dvEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLdouble</ptype> *<name>v</name></param>
+ <alias name="glVertexAttribL4dv"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribL4i64NV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLint64EXT</ptype> <name>x</name></param>
+ <param><ptype>GLint64EXT</ptype> <name>y</name></param>
+ <param><ptype>GLint64EXT</ptype> <name>z</name></param>
+ <param><ptype>GLint64EXT</ptype> <name>w</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribL4i64vNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLint64EXT</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribL4ui64NV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLuint64EXT</ptype> <name>x</name></param>
+ <param><ptype>GLuint64EXT</ptype> <name>y</name></param>
+ <param><ptype>GLuint64EXT</ptype> <name>z</name></param>
+ <param><ptype>GLuint64EXT</ptype> <name>w</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribL4ui64vNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLuint64EXT</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribLFormat</name></proto>
+ <param><ptype>GLuint</ptype> <name>attribindex</name></param>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLuint</ptype> <name>relativeoffset</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribLFormatNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribLPointer</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ <param len="size">const void *<name>pointer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribLPointerEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ <param len="size">const void *<name>pointer</name></param>
+ <alias name="glVertexAttribLPointer"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribP1ui</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>normalized</name></param>
+ <param><ptype>GLuint</ptype> <name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribP1uiv</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>normalized</name></param>
+ <param len="1">const <ptype>GLuint</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribP2ui</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>normalized</name></param>
+ <param><ptype>GLuint</ptype> <name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribP2uiv</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>normalized</name></param>
+ <param len="1">const <ptype>GLuint</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribP3ui</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>normalized</name></param>
+ <param><ptype>GLuint</ptype> <name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribP3uiv</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>normalized</name></param>
+ <param len="1">const <ptype>GLuint</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribP4ui</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>normalized</name></param>
+ <param><ptype>GLuint</ptype> <name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribP4uiv</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>normalized</name></param>
+ <param len="1">const <ptype>GLuint</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribParameteriAMD</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLint</ptype> <name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribPointer</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param group="VertexAttribPointerType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>normalized</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ <param len="COMPSIZE(size,type,stride)">const void *<name>pointer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribPointerARB</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param group="VertexAttribPointerType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param group="Boolean"><ptype>GLboolean</ptype> <name>normalized</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ <param len="COMPSIZE(size,type,stride)">const void *<name>pointer</name></param>
+ <alias name="glVertexAttribPointer"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribPointerNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLint</ptype> <name>fsize</name></param>
+ <param group="VertexAttribEnumNV"><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ <param len="COMPSIZE(fsize,type,stride)">const void *<name>pointer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribs1dvNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count">const <ptype>GLdouble</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4210"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribs1fvNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4206"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribs1hvNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param group="Half16NV" len="n">const <ptype>GLhalfNV</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4261"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribs1svNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count">const <ptype>GLshort</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4202"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribs2dvNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*2">const <ptype>GLdouble</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4211"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribs2fvNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*2">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4207"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribs2hvNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param group="Half16NV" len="n">const <ptype>GLhalfNV</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4262"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribs2svNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*2">const <ptype>GLshort</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4203"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribs3dvNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*3">const <ptype>GLdouble</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4212"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribs3fvNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*3">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4208"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribs3hvNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param group="Half16NV" len="n">const <ptype>GLhalfNV</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4263"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribs3svNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*3">const <ptype>GLshort</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4204"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribs4dvNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*4">const <ptype>GLdouble</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4213"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribs4fvNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*4">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4209"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribs4hvNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLsizei</ptype> <name>n</name></param>
+ <param group="Half16NV" len="n">const <ptype>GLhalfNV</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4264"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribs4svNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="count*4">const <ptype>GLshort</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4205"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexAttribs4ubvNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param group="ColorUB" len="count*4">const <ptype>GLubyte</ptype> *<name>v</name></param>
+ <glx type="render" opcode="4214"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexBindingDivisor</name></proto>
+ <param><ptype>GLuint</ptype> <name>bindingindex</name></param>
+ <param><ptype>GLuint</ptype> <name>divisor</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexBlendARB</name></proto>
+ <param><ptype>GLint</ptype> <name>count</name></param>
+ <glx type="render" opcode="226"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexBlendEnvfATI</name></proto>
+ <param group="VertexStreamATI"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLfloat</ptype> <name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexBlendEnviATI</name></proto>
+ <param group="VertexStreamATI"><ptype>GLenum</ptype> <name>pname</name></param>
+ <param><ptype>GLint</ptype> <name>param</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexFormatNV</name></proto>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexP2ui</name></proto>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLuint</ptype> <name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexP2uiv</name></proto>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="1">const <ptype>GLuint</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexP3ui</name></proto>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLuint</ptype> <name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexP3uiv</name></proto>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="1">const <ptype>GLuint</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexP4ui</name></proto>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLuint</ptype> <name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexP4uiv</name></proto>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="1">const <ptype>GLuint</ptype> *<name>value</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexPointer</name></proto>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param group="VertexPointerType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ <param len="COMPSIZE(size,type,stride)">const void *<name>pointer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexPointerEXT</name></proto>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param group="VertexPointerType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="COMPSIZE(size,type,stride,count)">const void *<name>pointer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexPointerListIBM</name></proto>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param group="VertexPointerType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLint</ptype> <name>stride</name></param>
+ <param len="COMPSIZE(size,type,stride)">const void **<name>pointer</name></param>
+ <param><ptype>GLint</ptype> <name>ptrstride</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexPointervINTEL</name></proto>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param group="VertexPointerType"><ptype>GLenum</ptype> <name>type</name></param>
+ <param len="4">const void **<name>pointer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexStream1dATI</name></proto>
+ <param group="VertexStreamATI"><ptype>GLenum</ptype> <name>stream</name></param>
+ <param><ptype>GLdouble</ptype> <name>x</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexStream1dvATI</name></proto>
+ <param group="VertexStreamATI"><ptype>GLenum</ptype> <name>stream</name></param>
+ <param len="1">const <ptype>GLdouble</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexStream1fATI</name></proto>
+ <param group="VertexStreamATI"><ptype>GLenum</ptype> <name>stream</name></param>
+ <param><ptype>GLfloat</ptype> <name>x</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexStream1fvATI</name></proto>
+ <param group="VertexStreamATI"><ptype>GLenum</ptype> <name>stream</name></param>
+ <param len="1">const <ptype>GLfloat</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexStream1iATI</name></proto>
+ <param group="VertexStreamATI"><ptype>GLenum</ptype> <name>stream</name></param>
+ <param><ptype>GLint</ptype> <name>x</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexStream1ivATI</name></proto>
+ <param group="VertexStreamATI"><ptype>GLenum</ptype> <name>stream</name></param>
+ <param len="1">const <ptype>GLint</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexStream1sATI</name></proto>
+ <param group="VertexStreamATI"><ptype>GLenum</ptype> <name>stream</name></param>
+ <param><ptype>GLshort</ptype> <name>x</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexStream1svATI</name></proto>
+ <param group="VertexStreamATI"><ptype>GLenum</ptype> <name>stream</name></param>
+ <param len="1">const <ptype>GLshort</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexStream2dATI</name></proto>
+ <param group="VertexStreamATI"><ptype>GLenum</ptype> <name>stream</name></param>
+ <param><ptype>GLdouble</ptype> <name>x</name></param>
+ <param><ptype>GLdouble</ptype> <name>y</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexStream2dvATI</name></proto>
+ <param group="VertexStreamATI"><ptype>GLenum</ptype> <name>stream</name></param>
+ <param len="2">const <ptype>GLdouble</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexStream2fATI</name></proto>
+ <param group="VertexStreamATI"><ptype>GLenum</ptype> <name>stream</name></param>
+ <param><ptype>GLfloat</ptype> <name>x</name></param>
+ <param><ptype>GLfloat</ptype> <name>y</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexStream2fvATI</name></proto>
+ <param group="VertexStreamATI"><ptype>GLenum</ptype> <name>stream</name></param>
+ <param len="2">const <ptype>GLfloat</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexStream2iATI</name></proto>
+ <param group="VertexStreamATI"><ptype>GLenum</ptype> <name>stream</name></param>
+ <param><ptype>GLint</ptype> <name>x</name></param>
+ <param><ptype>GLint</ptype> <name>y</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexStream2ivATI</name></proto>
+ <param group="VertexStreamATI"><ptype>GLenum</ptype> <name>stream</name></param>
+ <param len="2">const <ptype>GLint</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexStream2sATI</name></proto>
+ <param group="VertexStreamATI"><ptype>GLenum</ptype> <name>stream</name></param>
+ <param><ptype>GLshort</ptype> <name>x</name></param>
+ <param><ptype>GLshort</ptype> <name>y</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexStream2svATI</name></proto>
+ <param group="VertexStreamATI"><ptype>GLenum</ptype> <name>stream</name></param>
+ <param len="2">const <ptype>GLshort</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexStream3dATI</name></proto>
+ <param group="VertexStreamATI"><ptype>GLenum</ptype> <name>stream</name></param>
+ <param><ptype>GLdouble</ptype> <name>x</name></param>
+ <param><ptype>GLdouble</ptype> <name>y</name></param>
+ <param><ptype>GLdouble</ptype> <name>z</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexStream3dvATI</name></proto>
+ <param group="VertexStreamATI"><ptype>GLenum</ptype> <name>stream</name></param>
+ <param len="3">const <ptype>GLdouble</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexStream3fATI</name></proto>
+ <param group="VertexStreamATI"><ptype>GLenum</ptype> <name>stream</name></param>
+ <param><ptype>GLfloat</ptype> <name>x</name></param>
+ <param><ptype>GLfloat</ptype> <name>y</name></param>
+ <param><ptype>GLfloat</ptype> <name>z</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexStream3fvATI</name></proto>
+ <param group="VertexStreamATI"><ptype>GLenum</ptype> <name>stream</name></param>
+ <param len="3">const <ptype>GLfloat</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexStream3iATI</name></proto>
+ <param group="VertexStreamATI"><ptype>GLenum</ptype> <name>stream</name></param>
+ <param><ptype>GLint</ptype> <name>x</name></param>
+ <param><ptype>GLint</ptype> <name>y</name></param>
+ <param><ptype>GLint</ptype> <name>z</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexStream3ivATI</name></proto>
+ <param group="VertexStreamATI"><ptype>GLenum</ptype> <name>stream</name></param>
+ <param len="3">const <ptype>GLint</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexStream3sATI</name></proto>
+ <param group="VertexStreamATI"><ptype>GLenum</ptype> <name>stream</name></param>
+ <param><ptype>GLshort</ptype> <name>x</name></param>
+ <param><ptype>GLshort</ptype> <name>y</name></param>
+ <param><ptype>GLshort</ptype> <name>z</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexStream3svATI</name></proto>
+ <param group="VertexStreamATI"><ptype>GLenum</ptype> <name>stream</name></param>
+ <param len="3">const <ptype>GLshort</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexStream4dATI</name></proto>
+ <param group="VertexStreamATI"><ptype>GLenum</ptype> <name>stream</name></param>
+ <param><ptype>GLdouble</ptype> <name>x</name></param>
+ <param><ptype>GLdouble</ptype> <name>y</name></param>
+ <param><ptype>GLdouble</ptype> <name>z</name></param>
+ <param><ptype>GLdouble</ptype> <name>w</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexStream4dvATI</name></proto>
+ <param group="VertexStreamATI"><ptype>GLenum</ptype> <name>stream</name></param>
+ <param len="4">const <ptype>GLdouble</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexStream4fATI</name></proto>
+ <param group="VertexStreamATI"><ptype>GLenum</ptype> <name>stream</name></param>
+ <param><ptype>GLfloat</ptype> <name>x</name></param>
+ <param><ptype>GLfloat</ptype> <name>y</name></param>
+ <param><ptype>GLfloat</ptype> <name>z</name></param>
+ <param><ptype>GLfloat</ptype> <name>w</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexStream4fvATI</name></proto>
+ <param group="VertexStreamATI"><ptype>GLenum</ptype> <name>stream</name></param>
+ <param len="4">const <ptype>GLfloat</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexStream4iATI</name></proto>
+ <param group="VertexStreamATI"><ptype>GLenum</ptype> <name>stream</name></param>
+ <param><ptype>GLint</ptype> <name>x</name></param>
+ <param><ptype>GLint</ptype> <name>y</name></param>
+ <param><ptype>GLint</ptype> <name>z</name></param>
+ <param><ptype>GLint</ptype> <name>w</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexStream4ivATI</name></proto>
+ <param group="VertexStreamATI"><ptype>GLenum</ptype> <name>stream</name></param>
+ <param len="4">const <ptype>GLint</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexStream4sATI</name></proto>
+ <param group="VertexStreamATI"><ptype>GLenum</ptype> <name>stream</name></param>
+ <param><ptype>GLshort</ptype> <name>x</name></param>
+ <param><ptype>GLshort</ptype> <name>y</name></param>
+ <param><ptype>GLshort</ptype> <name>z</name></param>
+ <param><ptype>GLshort</ptype> <name>w</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexStream4svATI</name></proto>
+ <param group="VertexStreamATI"><ptype>GLenum</ptype> <name>stream</name></param>
+ <param len="4">const <ptype>GLshort</ptype> *<name>coords</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexWeightPointerEXT</name></proto>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param group="VertexWeightPointerTypeEXT"><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ <param len="COMPSIZE(type,stride)">const void *<name>pointer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVertexWeightfEXT</name></proto>
+ <param><ptype>GLfloat</ptype> <name>weight</name></param>
+ <vecequiv name="glVertexWeightfvEXT"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexWeightfvEXT</name></proto>
+ <param len="1">const <ptype>GLfloat</ptype> *<name>weight</name></param>
+ <glx type="render" opcode="4135"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexWeighthNV</name></proto>
+ <param group="Half16NV"><ptype>GLhalfNV</ptype> <name>weight</name></param>
+ <vecequiv name="glVertexWeighthvNV"/>
+ </command>
+ <command>
+ <proto>void <name>glVertexWeighthvNV</name></proto>
+ <param group="Half16NV" len="1">const <ptype>GLhalfNV</ptype> *<name>weight</name></param>
+ <glx type="render" opcode="4256"/>
+ </command>
+ <command>
+ <proto><ptype>GLenum</ptype> <name>glVideoCaptureNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>video_capture_slot</name></param>
+ <param><ptype>GLuint</ptype> *<name>sequence_num</name></param>
+ <param><ptype>GLuint64EXT</ptype> *<name>capture_time</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVideoCaptureStreamParameterdvNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>video_capture_slot</name></param>
+ <param><ptype>GLuint</ptype> <name>stream</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)">const <ptype>GLdouble</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVideoCaptureStreamParameterfvNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>video_capture_slot</name></param>
+ <param><ptype>GLuint</ptype> <name>stream</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)">const <ptype>GLfloat</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glVideoCaptureStreamParameterivNV</name></proto>
+ <param><ptype>GLuint</ptype> <name>video_capture_slot</name></param>
+ <param><ptype>GLuint</ptype> <name>stream</name></param>
+ <param><ptype>GLenum</ptype> <name>pname</name></param>
+ <param len="COMPSIZE(pname)">const <ptype>GLint</ptype> *<name>params</name></param>
+ </command>
+ <command>
+ <proto>void <name>glViewport</name></proto>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>x</name></param>
+ <param group="WinCoord"><ptype>GLint</ptype> <name>y</name></param>
+ <param><ptype>GLsizei</ptype> <name>width</name></param>
+ <param><ptype>GLsizei</ptype> <name>height</name></param>
+ <glx type="render" opcode="191"/>
+ </command>
+ <command>
+ <proto>void <name>glViewportArrayv</name></proto>
+ <param><ptype>GLuint</ptype> <name>first</name></param>
+ <param><ptype>GLsizei</ptype> <name>count</name></param>
+ <param len="COMPSIZE(count)">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glViewportIndexedf</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param><ptype>GLfloat</ptype> <name>x</name></param>
+ <param><ptype>GLfloat</ptype> <name>y</name></param>
+ <param><ptype>GLfloat</ptype> <name>w</name></param>
+ <param><ptype>GLfloat</ptype> <name>h</name></param>
+ </command>
+ <command>
+ <proto>void <name>glViewportIndexedfv</name></proto>
+ <param><ptype>GLuint</ptype> <name>index</name></param>
+ <param len="4">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glWaitSync</name></proto>
+ <param group="sync"><ptype>GLsync</ptype> <name>sync</name></param>
+ <param><ptype>GLbitfield</ptype> <name>flags</name></param>
+ <param><ptype>GLuint64</ptype> <name>timeout</name></param>
+ </command>
+ <command>
+ <proto>void <name>glWaitSyncAPPLE</name></proto>
+ <param><ptype>GLsync</ptype> <name>sync</name></param>
+ <param><ptype>GLbitfield</ptype> <name>flags</name></param>
+ <param><ptype>GLuint64</ptype> <name>timeout</name></param>
+ <alias name="glWaitSync"/>
+ </command>
+ <command>
+ <proto>void <name>glWeightPathsNV</name></proto>
+ <param group="Path"><ptype>GLuint</ptype> <name>resultPath</name></param>
+ <param><ptype>GLsizei</ptype> <name>numPaths</name></param>
+ <param group="Path" len="numPaths">const <ptype>GLuint</ptype> *<name>paths</name></param>
+ <param len="numPaths">const <ptype>GLfloat</ptype> *<name>weights</name></param>
+ </command>
+ <command>
+ <proto>void <name>glWeightPointerARB</name></proto>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param group="WeightPointerTypeARB"><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ <param len="COMPSIZE(type,stride)">const void *<name>pointer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glWeightPointerOES</name></proto>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param><ptype>GLenum</ptype> <name>type</name></param>
+ <param><ptype>GLsizei</ptype> <name>stride</name></param>
+ <param len="COMPSIZE(type,stride)">const void *<name>pointer</name></param>
+ </command>
+ <command>
+ <proto>void <name>glWeightbvARB</name></proto>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param len="size">const <ptype>GLbyte</ptype> *<name>weights</name></param>
+ <glx type="render" opcode="220"/>
+ </command>
+ <command>
+ <proto>void <name>glWeightdvARB</name></proto>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param len="size">const <ptype>GLdouble</ptype> *<name>weights</name></param>
+ <glx type="render" opcode="228"/>
+ </command>
+ <command>
+ <proto>void <name>glWeightfvARB</name></proto>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param len="size">const <ptype>GLfloat</ptype> *<name>weights</name></param>
+ <glx type="render" opcode="227"/>
+ </command>
+ <command>
+ <proto>void <name>glWeightivARB</name></proto>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param len="size">const <ptype>GLint</ptype> *<name>weights</name></param>
+ <glx type="render" opcode="224"/>
+ </command>
+ <command>
+ <proto>void <name>glWeightsvARB</name></proto>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param len="size">const <ptype>GLshort</ptype> *<name>weights</name></param>
+ <glx type="render" opcode="222"/>
+ </command>
+ <command>
+ <proto>void <name>glWeightubvARB</name></proto>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param len="size">const <ptype>GLubyte</ptype> *<name>weights</name></param>
+ <glx type="render" opcode="221"/>
+ </command>
+ <command>
+ <proto>void <name>glWeightuivARB</name></proto>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param len="size">const <ptype>GLuint</ptype> *<name>weights</name></param>
+ <glx type="render" opcode="225"/>
+ </command>
+ <command>
+ <proto>void <name>glWeightusvARB</name></proto>
+ <param><ptype>GLint</ptype> <name>size</name></param>
+ <param len="size">const <ptype>GLushort</ptype> *<name>weights</name></param>
+ <glx type="render" opcode="223"/>
+ </command>
+ <command>
+ <proto>void <name>glWindowPos2d</name></proto>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>x</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>y</name></param>
+ <vecequiv name="glWindowPos2dv"/>
+ </command>
+ <command>
+ <proto>void <name>glWindowPos2dARB</name></proto>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>x</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>y</name></param>
+ <alias name="glWindowPos2d"/>
+ <vecequiv name="glWindowPos2dvARB"/>
+ </command>
+ <command>
+ <proto>void <name>glWindowPos2dMESA</name></proto>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>x</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>y</name></param>
+ <alias name="glWindowPos2d"/>
+ <vecequiv name="glWindowPos2dvMESA"/>
+ </command>
+ <command>
+ <proto>void <name>glWindowPos2dv</name></proto>
+ <param group="CoordD" len="2">const <ptype>GLdouble</ptype> *<name>v</name></param>
+ <glx type="render" opcode="230"/>
+ </command>
+ <command>
+ <proto>void <name>glWindowPos2dvARB</name></proto>
+ <param group="CoordD" len="2">const <ptype>GLdouble</ptype> *<name>v</name></param>
+ <alias name="glWindowPos2dv"/>
+ <glx type="render" opcode="230"/>
+ </command>
+ <command>
+ <proto>void <name>glWindowPos2dvMESA</name></proto>
+ <param group="CoordD" len="2">const <ptype>GLdouble</ptype> *<name>v</name></param>
+ <alias name="glWindowPos2dv"/>
+ </command>
+ <command>
+ <proto>void <name>glWindowPos2f</name></proto>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>x</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>y</name></param>
+ <vecequiv name="glWindowPos2fv"/>
+ </command>
+ <command>
+ <proto>void <name>glWindowPos2fARB</name></proto>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>x</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>y</name></param>
+ <alias name="glWindowPos2f"/>
+ <vecequiv name="glWindowPos2fvARB"/>
+ </command>
+ <command>
+ <proto>void <name>glWindowPos2fMESA</name></proto>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>x</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>y</name></param>
+ <alias name="glWindowPos2f"/>
+ <vecequiv name="glWindowPos2fvMESA"/>
+ </command>
+ <command>
+ <proto>void <name>glWindowPos2fv</name></proto>
+ <param group="CoordF" len="2">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ <glx type="render" opcode="230"/>
+ </command>
+ <command>
+ <proto>void <name>glWindowPos2fvARB</name></proto>
+ <param group="CoordF" len="2">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ <alias name="glWindowPos2fv"/>
+ <glx type="render" opcode="230"/>
+ </command>
+ <command>
+ <proto>void <name>glWindowPos2fvMESA</name></proto>
+ <param group="CoordF" len="2">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ <alias name="glWindowPos2fv"/>
+ </command>
+ <command>
+ <proto>void <name>glWindowPos2i</name></proto>
+ <param group="CoordI"><ptype>GLint</ptype> <name>x</name></param>
+ <param group="CoordI"><ptype>GLint</ptype> <name>y</name></param>
+ <vecequiv name="glWindowPos2iv"/>
+ </command>
+ <command>
+ <proto>void <name>glWindowPos2iARB</name></proto>
+ <param group="CoordI"><ptype>GLint</ptype> <name>x</name></param>
+ <param group="CoordI"><ptype>GLint</ptype> <name>y</name></param>
+ <alias name="glWindowPos2i"/>
+ <vecequiv name="glWindowPos2ivARB"/>
+ </command>
+ <command>
+ <proto>void <name>glWindowPos2iMESA</name></proto>
+ <param group="CoordI"><ptype>GLint</ptype> <name>x</name></param>
+ <param group="CoordI"><ptype>GLint</ptype> <name>y</name></param>
+ <alias name="glWindowPos2i"/>
+ <vecequiv name="glWindowPos2ivMESA"/>
+ </command>
+ <command>
+ <proto>void <name>glWindowPos2iv</name></proto>
+ <param group="CoordI" len="2">const <ptype>GLint</ptype> *<name>v</name></param>
+ <glx type="render" opcode="230"/>
+ </command>
+ <command>
+ <proto>void <name>glWindowPos2ivARB</name></proto>
+ <param group="CoordI" len="2">const <ptype>GLint</ptype> *<name>v</name></param>
+ <alias name="glWindowPos2iv"/>
+ <glx type="render" opcode="230"/>
+ </command>
+ <command>
+ <proto>void <name>glWindowPos2ivMESA</name></proto>
+ <param group="CoordI" len="2">const <ptype>GLint</ptype> *<name>v</name></param>
+ <alias name="glWindowPos2iv"/>
+ </command>
+ <command>
+ <proto>void <name>glWindowPos2s</name></proto>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>x</name></param>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>y</name></param>
+ <vecequiv name="glWindowPos2sv"/>
+ </command>
+ <command>
+ <proto>void <name>glWindowPos2sARB</name></proto>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>x</name></param>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>y</name></param>
+ <alias name="glWindowPos2s"/>
+ <vecequiv name="glWindowPos2svARB"/>
+ </command>
+ <command>
+ <proto>void <name>glWindowPos2sMESA</name></proto>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>x</name></param>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>y</name></param>
+ <alias name="glWindowPos2s"/>
+ <vecequiv name="glWindowPos2svMESA"/>
+ </command>
+ <command>
+ <proto>void <name>glWindowPos2sv</name></proto>
+ <param group="CoordS" len="2">const <ptype>GLshort</ptype> *<name>v</name></param>
+ <glx type="render" opcode="230"/>
+ </command>
+ <command>
+ <proto>void <name>glWindowPos2svARB</name></proto>
+ <param group="CoordS" len="2">const <ptype>GLshort</ptype> *<name>v</name></param>
+ <alias name="glWindowPos2sv"/>
+ <glx type="render" opcode="230"/>
+ </command>
+ <command>
+ <proto>void <name>glWindowPos2svMESA</name></proto>
+ <param group="CoordS" len="2">const <ptype>GLshort</ptype> *<name>v</name></param>
+ <alias name="glWindowPos2sv"/>
+ </command>
+ <command>
+ <proto>void <name>glWindowPos3d</name></proto>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>x</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>y</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>z</name></param>
+ <vecequiv name="glWindowPos3dv"/>
+ </command>
+ <command>
+ <proto>void <name>glWindowPos3dARB</name></proto>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>x</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>y</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>z</name></param>
+ <alias name="glWindowPos3d"/>
+ <vecequiv name="glWindowPos3dvARB"/>
+ </command>
+ <command>
+ <proto>void <name>glWindowPos3dMESA</name></proto>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>x</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>y</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>z</name></param>
+ <alias name="glWindowPos3d"/>
+ <vecequiv name="glWindowPos3dvMESA"/>
+ </command>
+ <command>
+ <proto>void <name>glWindowPos3dv</name></proto>
+ <param group="CoordD" len="3">const <ptype>GLdouble</ptype> *<name>v</name></param>
+ <glx type="render" opcode="230"/>
+ </command>
+ <command>
+ <proto>void <name>glWindowPos3dvARB</name></proto>
+ <param group="CoordD" len="3">const <ptype>GLdouble</ptype> *<name>v</name></param>
+ <alias name="glWindowPos3dv"/>
+ <glx type="render" opcode="230"/>
+ </command>
+ <command>
+ <proto>void <name>glWindowPos3dvMESA</name></proto>
+ <param group="CoordD" len="3">const <ptype>GLdouble</ptype> *<name>v</name></param>
+ <alias name="glWindowPos3dv"/>
+ </command>
+ <command>
+ <proto>void <name>glWindowPos3f</name></proto>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>x</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>y</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>z</name></param>
+ <vecequiv name="glWindowPos3fv"/>
+ </command>
+ <command>
+ <proto>void <name>glWindowPos3fARB</name></proto>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>x</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>y</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>z</name></param>
+ <alias name="glWindowPos3f"/>
+ <vecequiv name="glWindowPos3fvARB"/>
+ </command>
+ <command>
+ <proto>void <name>glWindowPos3fMESA</name></proto>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>x</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>y</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>z</name></param>
+ <alias name="glWindowPos3f"/>
+ <vecequiv name="glWindowPos3fvMESA"/>
+ </command>
+ <command>
+ <proto>void <name>glWindowPos3fv</name></proto>
+ <param group="CoordF" len="3">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ <glx type="render" opcode="230"/>
+ </command>
+ <command>
+ <proto>void <name>glWindowPos3fvARB</name></proto>
+ <param group="CoordF" len="3">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ <alias name="glWindowPos3fv"/>
+ <glx type="render" opcode="230"/>
+ </command>
+ <command>
+ <proto>void <name>glWindowPos3fvMESA</name></proto>
+ <param group="CoordF" len="3">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ <alias name="glWindowPos3fv"/>
+ </command>
+ <command>
+ <proto>void <name>glWindowPos3i</name></proto>
+ <param group="CoordI"><ptype>GLint</ptype> <name>x</name></param>
+ <param group="CoordI"><ptype>GLint</ptype> <name>y</name></param>
+ <param group="CoordI"><ptype>GLint</ptype> <name>z</name></param>
+ <vecequiv name="glWindowPos3iv"/>
+ </command>
+ <command>
+ <proto>void <name>glWindowPos3iARB</name></proto>
+ <param group="CoordI"><ptype>GLint</ptype> <name>x</name></param>
+ <param group="CoordI"><ptype>GLint</ptype> <name>y</name></param>
+ <param group="CoordI"><ptype>GLint</ptype> <name>z</name></param>
+ <alias name="glWindowPos3i"/>
+ <vecequiv name="glWindowPos3ivARB"/>
+ </command>
+ <command>
+ <proto>void <name>glWindowPos3iMESA</name></proto>
+ <param group="CoordI"><ptype>GLint</ptype> <name>x</name></param>
+ <param group="CoordI"><ptype>GLint</ptype> <name>y</name></param>
+ <param group="CoordI"><ptype>GLint</ptype> <name>z</name></param>
+ <alias name="glWindowPos3i"/>
+ <vecequiv name="glWindowPos3ivMESA"/>
+ </command>
+ <command>
+ <proto>void <name>glWindowPos3iv</name></proto>
+ <param group="CoordI" len="3">const <ptype>GLint</ptype> *<name>v</name></param>
+ <glx type="render" opcode="230"/>
+ </command>
+ <command>
+ <proto>void <name>glWindowPos3ivARB</name></proto>
+ <param group="CoordI" len="3">const <ptype>GLint</ptype> *<name>v</name></param>
+ <alias name="glWindowPos3iv"/>
+ <glx type="render" opcode="230"/>
+ </command>
+ <command>
+ <proto>void <name>glWindowPos3ivMESA</name></proto>
+ <param group="CoordI" len="3">const <ptype>GLint</ptype> *<name>v</name></param>
+ <alias name="glWindowPos3iv"/>
+ </command>
+ <command>
+ <proto>void <name>glWindowPos3s</name></proto>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>x</name></param>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>y</name></param>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>z</name></param>
+ <vecequiv name="glWindowPos3sv"/>
+ </command>
+ <command>
+ <proto>void <name>glWindowPos3sARB</name></proto>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>x</name></param>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>y</name></param>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>z</name></param>
+ <alias name="glWindowPos3s"/>
+ <vecequiv name="glWindowPos3svARB"/>
+ </command>
+ <command>
+ <proto>void <name>glWindowPos3sMESA</name></proto>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>x</name></param>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>y</name></param>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>z</name></param>
+ <alias name="glWindowPos3s"/>
+ <vecequiv name="glWindowPos3svMESA"/>
+ </command>
+ <command>
+ <proto>void <name>glWindowPos3sv</name></proto>
+ <param group="CoordS" len="3">const <ptype>GLshort</ptype> *<name>v</name></param>
+ <glx type="render" opcode="230"/>
+ </command>
+ <command>
+ <proto>void <name>glWindowPos3svARB</name></proto>
+ <param group="CoordS" len="3">const <ptype>GLshort</ptype> *<name>v</name></param>
+ <alias name="glWindowPos3sv"/>
+ <glx type="render" opcode="230"/>
+ </command>
+ <command>
+ <proto>void <name>glWindowPos3svMESA</name></proto>
+ <param group="CoordS" len="3">const <ptype>GLshort</ptype> *<name>v</name></param>
+ <alias name="glWindowPos3sv"/>
+ </command>
+ <command>
+ <proto>void <name>glWindowPos4dMESA</name></proto>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>x</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>y</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>z</name></param>
+ <param group="CoordD"><ptype>GLdouble</ptype> <name>w</name></param>
+ <vecequiv name="glWindowPos4dvMESA"/>
+ </command>
+ <command>
+ <proto>void <name>glWindowPos4dvMESA</name></proto>
+ <param group="CoordD" len="4">const <ptype>GLdouble</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glWindowPos4fMESA</name></proto>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>x</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>y</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>z</name></param>
+ <param group="CoordF"><ptype>GLfloat</ptype> <name>w</name></param>
+ <vecequiv name="glWindowPos4fvMESA"/>
+ </command>
+ <command>
+ <proto>void <name>glWindowPos4fvMESA</name></proto>
+ <param group="CoordF" len="4">const <ptype>GLfloat</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glWindowPos4iMESA</name></proto>
+ <param group="CoordI"><ptype>GLint</ptype> <name>x</name></param>
+ <param group="CoordI"><ptype>GLint</ptype> <name>y</name></param>
+ <param group="CoordI"><ptype>GLint</ptype> <name>z</name></param>
+ <param group="CoordI"><ptype>GLint</ptype> <name>w</name></param>
+ <vecequiv name="glWindowPos4ivMESA"/>
+ </command>
+ <command>
+ <proto>void <name>glWindowPos4ivMESA</name></proto>
+ <param group="CoordI" len="4">const <ptype>GLint</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glWindowPos4sMESA</name></proto>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>x</name></param>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>y</name></param>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>z</name></param>
+ <param group="CoordS"><ptype>GLshort</ptype> <name>w</name></param>
+ <vecequiv name="glWindowPos4svMESA"/>
+ </command>
+ <command>
+ <proto>void <name>glWindowPos4svMESA</name></proto>
+ <param group="CoordS" len="4">const <ptype>GLshort</ptype> *<name>v</name></param>
+ </command>
+ <command>
+ <proto>void <name>glWriteMaskEXT</name></proto>
+ <param><ptype>GLuint</ptype> <name>res</name></param>
+ <param><ptype>GLuint</ptype> <name>in</name></param>
+ <param group="VertexShaderWriteMaskEXT"><ptype>GLenum</ptype> <name>outX</name></param>
+ <param group="VertexShaderWriteMaskEXT"><ptype>GLenum</ptype> <name>outY</name></param>
+ <param group="VertexShaderWriteMaskEXT"><ptype>GLenum</ptype> <name>outZ</name></param>
+ <param group="VertexShaderWriteMaskEXT"><ptype>GLenum</ptype> <name>outW</name></param>
+ </command>
+ </commands>
+
+ <!-- SECTION: GL API interface definitions. -->
+ <feature api="gl" name="GL_VERSION_1_0" number="1.0">
+ <require>
+ <type name="GLvoid" comment="No longer used in headers"/>
+ <command name="glCullFace"/>
+ <command name="glFrontFace"/>
+ <command name="glHint"/>
+ <command name="glLineWidth"/>
+ <command name="glPointSize"/>
+ <command name="glPolygonMode"/>
+ <command name="glScissor"/>
+ <command name="glTexParameterf"/>
+ <command name="glTexParameterfv"/>
+ <command name="glTexParameteri"/>
+ <command name="glTexParameteriv"/>
+ <command name="glTexImage1D"/>
+ <command name="glTexImage2D"/>
+ <command name="glDrawBuffer"/>
+ <command name="glClear"/>
+ <command name="glClearColor"/>
+ <command name="glClearStencil"/>
+ <command name="glClearDepth"/>
+ <command name="glStencilMask"/>
+ <command name="glColorMask"/>
+ <command name="glDepthMask"/>
+ <command name="glDisable"/>
+ <command name="glEnable"/>
+ <command name="glFinish"/>
+ <command name="glFlush"/>
+ <command name="glBlendFunc"/>
+ <command name="glLogicOp"/>
+ <command name="glStencilFunc"/>
+ <command name="glStencilOp"/>
+ <command name="glDepthFunc"/>
+ <command name="glPixelStoref"/>
+ <command name="glPixelStorei"/>
+ <command name="glReadBuffer"/>
+ <command name="glReadPixels"/>
+ <command name="glGetBooleanv"/>
+ <command name="glGetDoublev"/>
+ <command name="glGetError"/>
+ <command name="glGetFloatv"/>
+ <command name="glGetIntegerv"/>
+ <command name="glGetString"/>
+ <command name="glGetTexImage"/>
+ <command name="glGetTexParameterfv"/>
+ <command name="glGetTexParameteriv"/>
+ <command name="glGetTexLevelParameterfv"/>
+ <command name="glGetTexLevelParameteriv"/>
+ <command name="glIsEnabled"/>
+ <command name="glDepthRange"/>
+ <command name="glViewport"/>
+ <command name="glNewList"/>
+ <command name="glEndList"/>
+ <command name="glCallList"/>
+ <command name="glCallLists"/>
+ <command name="glDeleteLists"/>
+ <command name="glGenLists"/>
+ <command name="glListBase"/>
+ <command name="glBegin"/>
+ <command name="glBitmap"/>
+ <command name="glColor3b"/>
+ <command name="glColor3bv"/>
+ <command name="glColor3d"/>
+ <command name="glColor3dv"/>
+ <command name="glColor3f"/>
+ <command name="glColor3fv"/>
+ <command name="glColor3i"/>
+ <command name="glColor3iv"/>
+ <command name="glColor3s"/>
+ <command name="glColor3sv"/>
+ <command name="glColor3ub"/>
+ <command name="glColor3ubv"/>
+ <command name="glColor3ui"/>
+ <command name="glColor3uiv"/>
+ <command name="glColor3us"/>
+ <command name="glColor3usv"/>
+ <command name="glColor4b"/>
+ <command name="glColor4bv"/>
+ <command name="glColor4d"/>
+ <command name="glColor4dv"/>
+ <command name="glColor4f"/>
+ <command name="glColor4fv"/>
+ <command name="glColor4i"/>
+ <command name="glColor4iv"/>
+ <command name="glColor4s"/>
+ <command name="glColor4sv"/>
+ <command name="glColor4ub"/>
+ <command name="glColor4ubv"/>
+ <command name="glColor4ui"/>
+ <command name="glColor4uiv"/>
+ <command name="glColor4us"/>
+ <command name="glColor4usv"/>
+ <command name="glEdgeFlag"/>
+ <command name="glEdgeFlagv"/>
+ <command name="glEnd"/>
+ <command name="glIndexd"/>
+ <command name="glIndexdv"/>
+ <command name="glIndexf"/>
+ <command name="glIndexfv"/>
+ <command name="glIndexi"/>
+ <command name="glIndexiv"/>
+ <command name="glIndexs"/>
+ <command name="glIndexsv"/>
+ <command name="glNormal3b"/>
+ <command name="glNormal3bv"/>
+ <command name="glNormal3d"/>
+ <command name="glNormal3dv"/>
+ <command name="glNormal3f"/>
+ <command name="glNormal3fv"/>
+ <command name="glNormal3i"/>
+ <command name="glNormal3iv"/>
+ <command name="glNormal3s"/>
+ <command name="glNormal3sv"/>
+ <command name="glRasterPos2d"/>
+ <command name="glRasterPos2dv"/>
+ <command name="glRasterPos2f"/>
+ <command name="glRasterPos2fv"/>
+ <command name="glRasterPos2i"/>
+ <command name="glRasterPos2iv"/>
+ <command name="glRasterPos2s"/>
+ <command name="glRasterPos2sv"/>
+ <command name="glRasterPos3d"/>
+ <command name="glRasterPos3dv"/>
+ <command name="glRasterPos3f"/>
+ <command name="glRasterPos3fv"/>
+ <command name="glRasterPos3i"/>
+ <command name="glRasterPos3iv"/>
+ <command name="glRasterPos3s"/>
+ <command name="glRasterPos3sv"/>
+ <command name="glRasterPos4d"/>
+ <command name="glRasterPos4dv"/>
+ <command name="glRasterPos4f"/>
+ <command name="glRasterPos4fv"/>
+ <command name="glRasterPos4i"/>
+ <command name="glRasterPos4iv"/>
+ <command name="glRasterPos4s"/>
+ <command name="glRasterPos4sv"/>
+ <command name="glRectd"/>
+ <command name="glRectdv"/>
+ <command name="glRectf"/>
+ <command name="glRectfv"/>
+ <command name="glRecti"/>
+ <command name="glRectiv"/>
+ <command name="glRects"/>
+ <command name="glRectsv"/>
+ <command name="glTexCoord1d"/>
+ <command name="glTexCoord1dv"/>
+ <command name="glTexCoord1f"/>
+ <command name="glTexCoord1fv"/>
+ <command name="glTexCoord1i"/>
+ <command name="glTexCoord1iv"/>
+ <command name="glTexCoord1s"/>
+ <command name="glTexCoord1sv"/>
+ <command name="glTexCoord2d"/>
+ <command name="glTexCoord2dv"/>
+ <command name="glTexCoord2f"/>
+ <command name="glTexCoord2fv"/>
+ <command name="glTexCoord2i"/>
+ <command name="glTexCoord2iv"/>
+ <command name="glTexCoord2s"/>
+ <command name="glTexCoord2sv"/>
+ <command name="glTexCoord3d"/>
+ <command name="glTexCoord3dv"/>
+ <command name="glTexCoord3f"/>
+ <command name="glTexCoord3fv"/>
+ <command name="glTexCoord3i"/>
+ <command name="glTexCoord3iv"/>
+ <command name="glTexCoord3s"/>
+ <command name="glTexCoord3sv"/>
+ <command name="glTexCoord4d"/>
+ <command name="glTexCoord4dv"/>
+ <command name="glTexCoord4f"/>
+ <command name="glTexCoord4fv"/>
+ <command name="glTexCoord4i"/>
+ <command name="glTexCoord4iv"/>
+ <command name="glTexCoord4s"/>
+ <command name="glTexCoord4sv"/>
+ <command name="glVertex2d"/>
+ <command name="glVertex2dv"/>
+ <command name="glVertex2f"/>
+ <command name="glVertex2fv"/>
+ <command name="glVertex2i"/>
+ <command name="glVertex2iv"/>
+ <command name="glVertex2s"/>
+ <command name="glVertex2sv"/>
+ <command name="glVertex3d"/>
+ <command name="glVertex3dv"/>
+ <command name="glVertex3f"/>
+ <command name="glVertex3fv"/>
+ <command name="glVertex3i"/>
+ <command name="glVertex3iv"/>
+ <command name="glVertex3s"/>
+ <command name="glVertex3sv"/>
+ <command name="glVertex4d"/>
+ <command name="glVertex4dv"/>
+ <command name="glVertex4f"/>
+ <command name="glVertex4fv"/>
+ <command name="glVertex4i"/>
+ <command name="glVertex4iv"/>
+ <command name="glVertex4s"/>
+ <command name="glVertex4sv"/>
+ <command name="glClipPlane"/>
+ <command name="glColorMaterial"/>
+ <command name="glFogf"/>
+ <command name="glFogfv"/>
+ <command name="glFogi"/>
+ <command name="glFogiv"/>
+ <command name="glLightf"/>
+ <command name="glLightfv"/>
+ <command name="glLighti"/>
+ <command name="glLightiv"/>
+ <command name="glLightModelf"/>
+ <command name="glLightModelfv"/>
+ <command name="glLightModeli"/>
+ <command name="glLightModeliv"/>
+ <command name="glLineStipple"/>
+ <command name="glMaterialf"/>
+ <command name="glMaterialfv"/>
+ <command name="glMateriali"/>
+ <command name="glMaterialiv"/>
+ <command name="glPolygonStipple"/>
+ <command name="glShadeModel"/>
+ <command name="glTexEnvf"/>
+ <command name="glTexEnvfv"/>
+ <command name="glTexEnvi"/>
+ <command name="glTexEnviv"/>
+ <command name="glTexGend"/>
+ <command name="glTexGendv"/>
+ <command name="glTexGenf"/>
+ <command name="glTexGenfv"/>
+ <command name="glTexGeni"/>
+ <command name="glTexGeniv"/>
+ <command name="glFeedbackBuffer"/>
+ <command name="glSelectBuffer"/>
+ <command name="glRenderMode"/>
+ <command name="glInitNames"/>
+ <command name="glLoadName"/>
+ <command name="glPassThrough"/>
+ <command name="glPopName"/>
+ <command name="glPushName"/>
+ <command name="glClearAccum"/>
+ <command name="glClearIndex"/>
+ <command name="glIndexMask"/>
+ <command name="glAccum"/>
+ <command name="glPopAttrib"/>
+ <command name="glPushAttrib"/>
+ <command name="glMap1d"/>
+ <command name="glMap1f"/>
+ <command name="glMap2d"/>
+ <command name="glMap2f"/>
+ <command name="glMapGrid1d"/>
+ <command name="glMapGrid1f"/>
+ <command name="glMapGrid2d"/>
+ <command name="glMapGrid2f"/>
+ <command name="glEvalCoord1d"/>
+ <command name="glEvalCoord1dv"/>
+ <command name="glEvalCoord1f"/>
+ <command name="glEvalCoord1fv"/>
+ <command name="glEvalCoord2d"/>
+ <command name="glEvalCoord2dv"/>
+ <command name="glEvalCoord2f"/>
+ <command name="glEvalCoord2fv"/>
+ <command name="glEvalMesh1"/>
+ <command name="glEvalPoint1"/>
+ <command name="glEvalMesh2"/>
+ <command name="glEvalPoint2"/>
+ <command name="glAlphaFunc"/>
+ <command name="glPixelZoom"/>
+ <command name="glPixelTransferf"/>
+ <command name="glPixelTransferi"/>
+ <command name="glPixelMapfv"/>
+ <command name="glPixelMapuiv"/>
+ <command name="glPixelMapusv"/>
+ <command name="glCopyPixels"/>
+ <command name="glDrawPixels"/>
+ <command name="glGetClipPlane"/>
+ <command name="glGetLightfv"/>
+ <command name="glGetLightiv"/>
+ <command name="glGetMapdv"/>
+ <command name="glGetMapfv"/>
+ <command name="glGetMapiv"/>
+ <command name="glGetMaterialfv"/>
+ <command name="glGetMaterialiv"/>
+ <command name="glGetPixelMapfv"/>
+ <command name="glGetPixelMapuiv"/>
+ <command name="glGetPixelMapusv"/>
+ <command name="glGetPolygonStipple"/>
+ <command name="glGetTexEnvfv"/>
+ <command name="glGetTexEnviv"/>
+ <command name="glGetTexGendv"/>
+ <command name="glGetTexGenfv"/>
+ <command name="glGetTexGeniv"/>
+ <command name="glIsList"/>
+ <command name="glFrustum"/>
+ <command name="glLoadIdentity"/>
+ <command name="glLoadMatrixf"/>
+ <command name="glLoadMatrixd"/>
+ <command name="glMatrixMode"/>
+ <command name="glMultMatrixf"/>
+ <command name="glMultMatrixd"/>
+ <command name="glOrtho"/>
+ <command name="glPopMatrix"/>
+ <command name="glPushMatrix"/>
+ <command name="glRotated"/>
+ <command name="glRotatef"/>
+ <command name="glScaled"/>
+ <command name="glScalef"/>
+ <command name="glTranslated"/>
+ <command name="glTranslatef"/>
+ </require>
+ </feature>
+ <feature api="gl" name="GL_VERSION_1_1" number="1.1">
+ <require>
+ <type name="GLclampf" comment="No longer used in GL 1.1, but still defined in Mesa gl.h"/>
+ <type name="GLclampd" comment="No longer used in GL 1.1, but still defined in Mesa gl.h"/>
+ <!-- Many of these are really VERSION_1_0 enums -->
+ <enum name="GL_DEPTH_BUFFER_BIT"/>
+ <enum name="GL_STENCIL_BUFFER_BIT"/>
+ <enum name="GL_COLOR_BUFFER_BIT"/>
+ <enum name="GL_FALSE"/>
+ <enum name="GL_TRUE"/>
+ <enum name="GL_POINTS"/>
+ <enum name="GL_LINES"/>
+ <enum name="GL_LINE_LOOP"/>
+ <enum name="GL_LINE_STRIP"/>
+ <enum name="GL_TRIANGLES"/>
+ <enum name="GL_TRIANGLE_STRIP"/>
+ <enum name="GL_TRIANGLE_FAN"/>
+ <enum name="GL_QUADS"/>
+ <enum name="GL_NEVER"/>
+ <enum name="GL_LESS"/>
+ <enum name="GL_EQUAL"/>
+ <enum name="GL_LEQUAL"/>
+ <enum name="GL_GREATER"/>
+ <enum name="GL_NOTEQUAL"/>
+ <enum name="GL_GEQUAL"/>
+ <enum name="GL_ALWAYS"/>
+ <enum name="GL_ZERO"/>
+ <enum name="GL_ONE"/>
+ <enum name="GL_SRC_COLOR"/>
+ <enum name="GL_ONE_MINUS_SRC_COLOR"/>
+ <enum name="GL_SRC_ALPHA"/>
+ <enum name="GL_ONE_MINUS_SRC_ALPHA"/>
+ <enum name="GL_DST_ALPHA"/>
+ <enum name="GL_ONE_MINUS_DST_ALPHA"/>
+ <enum name="GL_DST_COLOR"/>
+ <enum name="GL_ONE_MINUS_DST_COLOR"/>
+ <enum name="GL_SRC_ALPHA_SATURATE"/>
+ <enum name="GL_NONE"/>
+ <enum name="GL_FRONT_LEFT"/>
+ <enum name="GL_FRONT_RIGHT"/>
+ <enum name="GL_BACK_LEFT"/>
+ <enum name="GL_BACK_RIGHT"/>
+ <enum name="GL_FRONT"/>
+ <enum name="GL_BACK"/>
+ <enum name="GL_LEFT"/>
+ <enum name="GL_RIGHT"/>
+ <enum name="GL_FRONT_AND_BACK"/>
+ <enum name="GL_NO_ERROR"/>
+ <enum name="GL_INVALID_ENUM"/>
+ <enum name="GL_INVALID_VALUE"/>
+ <enum name="GL_INVALID_OPERATION"/>
+ <enum name="GL_OUT_OF_MEMORY"/>
+ <enum name="GL_CW"/>
+ <enum name="GL_CCW"/>
+ <enum name="GL_POINT_SIZE"/>
+ <enum name="GL_POINT_SIZE_RANGE"/>
+ <enum name="GL_POINT_SIZE_GRANULARITY"/>
+ <enum name="GL_LINE_SMOOTH"/>
+ <enum name="GL_LINE_WIDTH"/>
+ <enum name="GL_LINE_WIDTH_RANGE"/>
+ <enum name="GL_LINE_WIDTH_GRANULARITY"/>
+ <enum name="GL_POLYGON_MODE"/>
+ <enum name="GL_POLYGON_SMOOTH"/>
+ <enum name="GL_CULL_FACE"/>
+ <enum name="GL_CULL_FACE_MODE"/>
+ <enum name="GL_FRONT_FACE"/>
+ <enum name="GL_DEPTH_RANGE"/>
+ <enum name="GL_DEPTH_TEST"/>
+ <enum name="GL_DEPTH_WRITEMASK"/>
+ <enum name="GL_DEPTH_CLEAR_VALUE"/>
+ <enum name="GL_DEPTH_FUNC"/>
+ <enum name="GL_STENCIL_TEST"/>
+ <enum name="GL_STENCIL_CLEAR_VALUE"/>
+ <enum name="GL_STENCIL_FUNC"/>
+ <enum name="GL_STENCIL_VALUE_MASK"/>
+ <enum name="GL_STENCIL_FAIL"/>
+ <enum name="GL_STENCIL_PASS_DEPTH_FAIL"/>
+ <enum name="GL_STENCIL_PASS_DEPTH_PASS"/>
+ <enum name="GL_STENCIL_REF"/>
+ <enum name="GL_STENCIL_WRITEMASK"/>
+ <enum name="GL_VIEWPORT"/>
+ <enum name="GL_DITHER"/>
+ <enum name="GL_BLEND_DST"/>
+ <enum name="GL_BLEND_SRC"/>
+ <enum name="GL_BLEND"/>
+ <enum name="GL_LOGIC_OP_MODE"/>
+ <enum name="GL_COLOR_LOGIC_OP"/>
+ <enum name="GL_DRAW_BUFFER"/>
+ <enum name="GL_READ_BUFFER"/>
+ <enum name="GL_SCISSOR_BOX"/>
+ <enum name="GL_SCISSOR_TEST"/>
+ <enum name="GL_COLOR_CLEAR_VALUE"/>
+ <enum name="GL_COLOR_WRITEMASK"/>
+ <enum name="GL_DOUBLEBUFFER"/>
+ <enum name="GL_STEREO"/>
+ <enum name="GL_LINE_SMOOTH_HINT"/>
+ <enum name="GL_POLYGON_SMOOTH_HINT"/>
+ <enum name="GL_UNPACK_SWAP_BYTES"/>
+ <enum name="GL_UNPACK_LSB_FIRST"/>
+ <enum name="GL_UNPACK_ROW_LENGTH"/>
+ <enum name="GL_UNPACK_SKIP_ROWS"/>
+ <enum name="GL_UNPACK_SKIP_PIXELS"/>
+ <enum name="GL_UNPACK_ALIGNMENT"/>
+ <enum name="GL_PACK_SWAP_BYTES"/>
+ <enum name="GL_PACK_LSB_FIRST"/>
+ <enum name="GL_PACK_ROW_LENGTH"/>
+ <enum name="GL_PACK_SKIP_ROWS"/>
+ <enum name="GL_PACK_SKIP_PIXELS"/>
+ <enum name="GL_PACK_ALIGNMENT"/>
+ <enum name="GL_MAX_TEXTURE_SIZE"/>
+ <enum name="GL_MAX_VIEWPORT_DIMS"/>
+ <enum name="GL_SUBPIXEL_BITS"/>
+ <enum name="GL_TEXTURE_1D"/>
+ <enum name="GL_TEXTURE_2D"/>
+ <enum name="GL_POLYGON_OFFSET_UNITS"/>
+ <enum name="GL_POLYGON_OFFSET_POINT"/>
+ <enum name="GL_POLYGON_OFFSET_LINE"/>
+ <enum name="GL_POLYGON_OFFSET_FILL"/>
+ <enum name="GL_POLYGON_OFFSET_FACTOR"/>
+ <enum name="GL_TEXTURE_BINDING_1D"/>
+ <enum name="GL_TEXTURE_BINDING_2D"/>
+ <enum name="GL_TEXTURE_WIDTH"/>
+ <enum name="GL_TEXTURE_HEIGHT"/>
+ <enum name="GL_TEXTURE_INTERNAL_FORMAT"/>
+ <enum name="GL_TEXTURE_BORDER_COLOR"/>
+ <enum name="GL_TEXTURE_RED_SIZE"/>
+ <enum name="GL_TEXTURE_GREEN_SIZE"/>
+ <enum name="GL_TEXTURE_BLUE_SIZE"/>
+ <enum name="GL_TEXTURE_ALPHA_SIZE"/>
+ <enum name="GL_DONT_CARE"/>
+ <enum name="GL_FASTEST"/>
+ <enum name="GL_NICEST"/>
+ <enum name="GL_BYTE"/>
+ <enum name="GL_UNSIGNED_BYTE"/>
+ <enum name="GL_SHORT"/>
+ <enum name="GL_UNSIGNED_SHORT"/>
+ <enum name="GL_INT"/>
+ <enum name="GL_UNSIGNED_INT"/>
+ <enum name="GL_FLOAT"/>
+ <enum name="GL_DOUBLE"/>
+ <enum name="GL_STACK_OVERFLOW"/>
+ <enum name="GL_STACK_UNDERFLOW"/>
+ <enum name="GL_CLEAR"/>
+ <enum name="GL_AND"/>
+ <enum name="GL_AND_REVERSE"/>
+ <enum name="GL_COPY"/>
+ <enum name="GL_AND_INVERTED"/>
+ <enum name="GL_NOOP"/>
+ <enum name="GL_XOR"/>
+ <enum name="GL_OR"/>
+ <enum name="GL_NOR"/>
+ <enum name="GL_EQUIV"/>
+ <enum name="GL_INVERT"/>
+ <enum name="GL_OR_REVERSE"/>
+ <enum name="GL_COPY_INVERTED"/>
+ <enum name="GL_OR_INVERTED"/>
+ <enum name="GL_NAND"/>
+ <enum name="GL_SET"/>
+ <enum name="GL_TEXTURE"/>
+ <enum name="GL_COLOR"/>
+ <enum name="GL_DEPTH"/>
+ <enum name="GL_STENCIL"/>
+ <enum name="GL_STENCIL_INDEX"/>
+ <enum name="GL_DEPTH_COMPONENT"/>
+ <enum name="GL_RED"/>
+ <enum name="GL_GREEN"/>
+ <enum name="GL_BLUE"/>
+ <enum name="GL_ALPHA"/>
+ <enum name="GL_RGB"/>
+ <enum name="GL_RGBA"/>
+ <enum name="GL_POINT"/>
+ <enum name="GL_LINE"/>
+ <enum name="GL_FILL"/>
+ <enum name="GL_KEEP"/>
+ <enum name="GL_REPLACE"/>
+ <enum name="GL_INCR"/>
+ <enum name="GL_DECR"/>
+ <enum name="GL_VENDOR"/>
+ <enum name="GL_RENDERER"/>
+ <enum name="GL_VERSION"/>
+ <enum name="GL_EXTENSIONS"/>
+ <enum name="GL_NEAREST"/>
+ <enum name="GL_LINEAR"/>
+ <enum name="GL_NEAREST_MIPMAP_NEAREST"/>
+ <enum name="GL_LINEAR_MIPMAP_NEAREST"/>
+ <enum name="GL_NEAREST_MIPMAP_LINEAR"/>
+ <enum name="GL_LINEAR_MIPMAP_LINEAR"/>
+ <enum name="GL_TEXTURE_MAG_FILTER"/>
+ <enum name="GL_TEXTURE_MIN_FILTER"/>
+ <enum name="GL_TEXTURE_WRAP_S"/>
+ <enum name="GL_TEXTURE_WRAP_T"/>
+ <enum name="GL_PROXY_TEXTURE_1D"/>
+ <enum name="GL_PROXY_TEXTURE_2D"/>
+ <enum name="GL_REPEAT"/>
+ <enum name="GL_R3_G3_B2"/>
+ <enum name="GL_RGB4"/>
+ <enum name="GL_RGB5"/>
+ <enum name="GL_RGB8"/>
+ <enum name="GL_RGB10"/>
+ <enum name="GL_RGB12"/>
+ <enum name="GL_RGB16"/>
+ <enum name="GL_RGBA2"/>
+ <enum name="GL_RGBA4"/>
+ <enum name="GL_RGB5_A1"/>
+ <enum name="GL_RGBA8"/>
+ <enum name="GL_RGB10_A2"/>
+ <enum name="GL_RGBA12"/>
+ <enum name="GL_RGBA16"/>
+ <enum name="GL_CURRENT_BIT"/>
+ <enum name="GL_POINT_BIT"/>
+ <enum name="GL_LINE_BIT"/>
+ <enum name="GL_POLYGON_BIT"/>
+ <enum name="GL_POLYGON_STIPPLE_BIT"/>
+ <enum name="GL_PIXEL_MODE_BIT"/>
+ <enum name="GL_LIGHTING_BIT"/>
+ <enum name="GL_FOG_BIT"/>
+ <enum name="GL_ACCUM_BUFFER_BIT"/>
+ <enum name="GL_VIEWPORT_BIT"/>
+ <enum name="GL_TRANSFORM_BIT"/>
+ <enum name="GL_ENABLE_BIT"/>
+ <enum name="GL_HINT_BIT"/>
+ <enum name="GL_EVAL_BIT"/>
+ <enum name="GL_LIST_BIT"/>
+ <enum name="GL_TEXTURE_BIT"/>
+ <enum name="GL_SCISSOR_BIT"/>
+ <enum name="GL_ALL_ATTRIB_BITS"/>
+ <enum name="GL_CLIENT_PIXEL_STORE_BIT"/>
+ <enum name="GL_CLIENT_VERTEX_ARRAY_BIT"/>
+ <enum name="GL_CLIENT_ALL_ATTRIB_BITS"/>
+ <enum name="GL_QUAD_STRIP"/>
+ <enum name="GL_POLYGON"/>
+ <enum name="GL_ACCUM"/>
+ <enum name="GL_LOAD"/>
+ <enum name="GL_RETURN"/>
+ <enum name="GL_MULT"/>
+ <enum name="GL_ADD"/>
+ <enum name="GL_AUX0"/>
+ <enum name="GL_AUX1"/>
+ <enum name="GL_AUX2"/>
+ <enum name="GL_AUX3"/>
+ <enum name="GL_2D"/>
+ <enum name="GL_3D"/>
+ <enum name="GL_3D_COLOR"/>
+ <enum name="GL_3D_COLOR_TEXTURE"/>
+ <enum name="GL_4D_COLOR_TEXTURE"/>
+ <enum name="GL_PASS_THROUGH_TOKEN"/>
+ <enum name="GL_POINT_TOKEN"/>
+ <enum name="GL_LINE_TOKEN"/>
+ <enum name="GL_POLYGON_TOKEN"/>
+ <enum name="GL_BITMAP_TOKEN"/>
+ <enum name="GL_DRAW_PIXEL_TOKEN"/>
+ <enum name="GL_COPY_PIXEL_TOKEN"/>
+ <enum name="GL_LINE_RESET_TOKEN"/>
+ <enum name="GL_EXP"/>
+ <enum name="GL_EXP2"/>
+ <enum name="GL_COEFF"/>
+ <enum name="GL_ORDER"/>
+ <enum name="GL_DOMAIN"/>
+ <enum name="GL_PIXEL_MAP_I_TO_I"/>
+ <enum name="GL_PIXEL_MAP_S_TO_S"/>
+ <enum name="GL_PIXEL_MAP_I_TO_R"/>
+ <enum name="GL_PIXEL_MAP_I_TO_G"/>
+ <enum name="GL_PIXEL_MAP_I_TO_B"/>
+ <enum name="GL_PIXEL_MAP_I_TO_A"/>
+ <enum name="GL_PIXEL_MAP_R_TO_R"/>
+ <enum name="GL_PIXEL_MAP_G_TO_G"/>
+ <enum name="GL_PIXEL_MAP_B_TO_B"/>
+ <enum name="GL_PIXEL_MAP_A_TO_A"/>
+ <enum name="GL_VERTEX_ARRAY_POINTER"/>
+ <enum name="GL_NORMAL_ARRAY_POINTER"/>
+ <enum name="GL_COLOR_ARRAY_POINTER"/>
+ <enum name="GL_INDEX_ARRAY_POINTER"/>
+ <enum name="GL_TEXTURE_COORD_ARRAY_POINTER"/>
+ <enum name="GL_EDGE_FLAG_ARRAY_POINTER"/>
+ <enum name="GL_FEEDBACK_BUFFER_POINTER"/>
+ <enum name="GL_SELECTION_BUFFER_POINTER"/>
+ <enum name="GL_CURRENT_COLOR"/>
+ <enum name="GL_CURRENT_INDEX"/>
+ <enum name="GL_CURRENT_NORMAL"/>
+ <enum name="GL_CURRENT_TEXTURE_COORDS"/>
+ <enum name="GL_CURRENT_RASTER_COLOR"/>
+ <enum name="GL_CURRENT_RASTER_INDEX"/>
+ <enum name="GL_CURRENT_RASTER_TEXTURE_COORDS"/>
+ <enum name="GL_CURRENT_RASTER_POSITION"/>
+ <enum name="GL_CURRENT_RASTER_POSITION_VALID"/>
+ <enum name="GL_CURRENT_RASTER_DISTANCE"/>
+ <enum name="GL_POINT_SMOOTH"/>
+ <enum name="GL_LINE_STIPPLE"/>
+ <enum name="GL_LINE_STIPPLE_PATTERN"/>
+ <enum name="GL_LINE_STIPPLE_REPEAT"/>
+ <enum name="GL_LIST_MODE"/>
+ <enum name="GL_MAX_LIST_NESTING"/>
+ <enum name="GL_LIST_BASE"/>
+ <enum name="GL_LIST_INDEX"/>
+ <enum name="GL_POLYGON_STIPPLE"/>
+ <enum name="GL_EDGE_FLAG"/>
+ <enum name="GL_LIGHTING"/>
+ <enum name="GL_LIGHT_MODEL_LOCAL_VIEWER"/>
+ <enum name="GL_LIGHT_MODEL_TWO_SIDE"/>
+ <enum name="GL_LIGHT_MODEL_AMBIENT"/>
+ <enum name="GL_SHADE_MODEL"/>
+ <enum name="GL_COLOR_MATERIAL_FACE"/>
+ <enum name="GL_COLOR_MATERIAL_PARAMETER"/>
+ <enum name="GL_COLOR_MATERIAL"/>
+ <enum name="GL_FOG"/>
+ <enum name="GL_FOG_INDEX"/>
+ <enum name="GL_FOG_DENSITY"/>
+ <enum name="GL_FOG_START"/>
+ <enum name="GL_FOG_END"/>
+ <enum name="GL_FOG_MODE"/>
+ <enum name="GL_FOG_COLOR"/>
+ <enum name="GL_ACCUM_CLEAR_VALUE"/>
+ <enum name="GL_MATRIX_MODE"/>
+ <enum name="GL_NORMALIZE"/>
+ <enum name="GL_MODELVIEW_STACK_DEPTH"/>
+ <enum name="GL_PROJECTION_STACK_DEPTH"/>
+ <enum name="GL_TEXTURE_STACK_DEPTH"/>
+ <enum name="GL_MODELVIEW_MATRIX"/>
+ <enum name="GL_PROJECTION_MATRIX"/>
+ <enum name="GL_TEXTURE_MATRIX"/>
+ <enum name="GL_ATTRIB_STACK_DEPTH"/>
+ <enum name="GL_CLIENT_ATTRIB_STACK_DEPTH"/>
+ <enum name="GL_ALPHA_TEST"/>
+ <enum name="GL_ALPHA_TEST_FUNC"/>
+ <enum name="GL_ALPHA_TEST_REF"/>
+ <enum name="GL_INDEX_LOGIC_OP"/>
+ <enum name="GL_LOGIC_OP"/>
+ <enum name="GL_AUX_BUFFERS"/>
+ <enum name="GL_INDEX_CLEAR_VALUE"/>
+ <enum name="GL_INDEX_WRITEMASK"/>
+ <enum name="GL_INDEX_MODE"/>
+ <enum name="GL_RGBA_MODE"/>
+ <enum name="GL_RENDER_MODE"/>
+ <enum name="GL_PERSPECTIVE_CORRECTION_HINT"/>
+ <enum name="GL_POINT_SMOOTH_HINT"/>
+ <enum name="GL_FOG_HINT"/>
+ <enum name="GL_TEXTURE_GEN_S"/>
+ <enum name="GL_TEXTURE_GEN_T"/>
+ <enum name="GL_TEXTURE_GEN_R"/>
+ <enum name="GL_TEXTURE_GEN_Q"/>
+ <enum name="GL_PIXEL_MAP_I_TO_I_SIZE"/>
+ <enum name="GL_PIXEL_MAP_S_TO_S_SIZE"/>
+ <enum name="GL_PIXEL_MAP_I_TO_R_SIZE"/>
+ <enum name="GL_PIXEL_MAP_I_TO_G_SIZE"/>
+ <enum name="GL_PIXEL_MAP_I_TO_B_SIZE"/>
+ <enum name="GL_PIXEL_MAP_I_TO_A_SIZE"/>
+ <enum name="GL_PIXEL_MAP_R_TO_R_SIZE"/>
+ <enum name="GL_PIXEL_MAP_G_TO_G_SIZE"/>
+ <enum name="GL_PIXEL_MAP_B_TO_B_SIZE"/>
+ <enum name="GL_PIXEL_MAP_A_TO_A_SIZE"/>
+ <enum name="GL_MAP_COLOR"/>
+ <enum name="GL_MAP_STENCIL"/>
+ <enum name="GL_INDEX_SHIFT"/>
+ <enum name="GL_INDEX_OFFSET"/>
+ <enum name="GL_RED_SCALE"/>
+ <enum name="GL_RED_BIAS"/>
+ <enum name="GL_ZOOM_X"/>
+ <enum name="GL_ZOOM_Y"/>
+ <enum name="GL_GREEN_SCALE"/>
+ <enum name="GL_GREEN_BIAS"/>
+ <enum name="GL_BLUE_SCALE"/>
+ <enum name="GL_BLUE_BIAS"/>
+ <enum name="GL_ALPHA_SCALE"/>
+ <enum name="GL_ALPHA_BIAS"/>
+ <enum name="GL_DEPTH_SCALE"/>
+ <enum name="GL_DEPTH_BIAS"/>
+ <enum name="GL_MAX_EVAL_ORDER"/>
+ <enum name="GL_MAX_LIGHTS"/>
+ <enum name="GL_MAX_CLIP_PLANES"/>
+ <enum name="GL_MAX_PIXEL_MAP_TABLE"/>
+ <enum name="GL_MAX_ATTRIB_STACK_DEPTH"/>
+ <enum name="GL_MAX_MODELVIEW_STACK_DEPTH"/>
+ <enum name="GL_MAX_NAME_STACK_DEPTH"/>
+ <enum name="GL_MAX_PROJECTION_STACK_DEPTH"/>
+ <enum name="GL_MAX_TEXTURE_STACK_DEPTH"/>
+ <enum name="GL_MAX_CLIENT_ATTRIB_STACK_DEPTH"/>
+ <enum name="GL_INDEX_BITS"/>
+ <enum name="GL_RED_BITS"/>
+ <enum name="GL_GREEN_BITS"/>
+ <enum name="GL_BLUE_BITS"/>
+ <enum name="GL_ALPHA_BITS"/>
+ <enum name="GL_DEPTH_BITS"/>
+ <enum name="GL_STENCIL_BITS"/>
+ <enum name="GL_ACCUM_RED_BITS"/>
+ <enum name="GL_ACCUM_GREEN_BITS"/>
+ <enum name="GL_ACCUM_BLUE_BITS"/>
+ <enum name="GL_ACCUM_ALPHA_BITS"/>
+ <enum name="GL_NAME_STACK_DEPTH"/>
+ <enum name="GL_AUTO_NORMAL"/>
+ <enum name="GL_MAP1_COLOR_4"/>
+ <enum name="GL_MAP1_INDEX"/>
+ <enum name="GL_MAP1_NORMAL"/>
+ <enum name="GL_MAP1_TEXTURE_COORD_1"/>
+ <enum name="GL_MAP1_TEXTURE_COORD_2"/>
+ <enum name="GL_MAP1_TEXTURE_COORD_3"/>
+ <enum name="GL_MAP1_TEXTURE_COORD_4"/>
+ <enum name="GL_MAP1_VERTEX_3"/>
+ <enum name="GL_MAP1_VERTEX_4"/>
+ <enum name="GL_MAP2_COLOR_4"/>
+ <enum name="GL_MAP2_INDEX"/>
+ <enum name="GL_MAP2_NORMAL"/>
+ <enum name="GL_MAP2_TEXTURE_COORD_1"/>
+ <enum name="GL_MAP2_TEXTURE_COORD_2"/>
+ <enum name="GL_MAP2_TEXTURE_COORD_3"/>
+ <enum name="GL_MAP2_TEXTURE_COORD_4"/>
+ <enum name="GL_MAP2_VERTEX_3"/>
+ <enum name="GL_MAP2_VERTEX_4"/>
+ <enum name="GL_MAP1_GRID_DOMAIN"/>
+ <enum name="GL_MAP1_GRID_SEGMENTS"/>
+ <enum name="GL_MAP2_GRID_DOMAIN"/>
+ <enum name="GL_MAP2_GRID_SEGMENTS"/>
+ <enum name="GL_FEEDBACK_BUFFER_SIZE"/>
+ <enum name="GL_FEEDBACK_BUFFER_TYPE"/>
+ <enum name="GL_SELECTION_BUFFER_SIZE"/>
+ <enum name="GL_VERTEX_ARRAY"/>
+ <enum name="GL_NORMAL_ARRAY"/>
+ <enum name="GL_COLOR_ARRAY"/>
+ <enum name="GL_INDEX_ARRAY"/>
+ <enum name="GL_TEXTURE_COORD_ARRAY"/>
+ <enum name="GL_EDGE_FLAG_ARRAY"/>
+ <enum name="GL_VERTEX_ARRAY_SIZE"/>
+ <enum name="GL_VERTEX_ARRAY_TYPE"/>
+ <enum name="GL_VERTEX_ARRAY_STRIDE"/>
+ <enum name="GL_NORMAL_ARRAY_TYPE"/>
+ <enum name="GL_NORMAL_ARRAY_STRIDE"/>
+ <enum name="GL_COLOR_ARRAY_SIZE"/>
+ <enum name="GL_COLOR_ARRAY_TYPE"/>
+ <enum name="GL_COLOR_ARRAY_STRIDE"/>
+ <enum name="GL_INDEX_ARRAY_TYPE"/>
+ <enum name="GL_INDEX_ARRAY_STRIDE"/>
+ <enum name="GL_TEXTURE_COORD_ARRAY_SIZE"/>
+ <enum name="GL_TEXTURE_COORD_ARRAY_TYPE"/>
+ <enum name="GL_TEXTURE_COORD_ARRAY_STRIDE"/>
+ <enum name="GL_EDGE_FLAG_ARRAY_STRIDE"/>
+ <enum name="GL_TEXTURE_COMPONENTS"/>
+ <enum name="GL_TEXTURE_BORDER"/>
+ <enum name="GL_TEXTURE_LUMINANCE_SIZE"/>
+ <enum name="GL_TEXTURE_INTENSITY_SIZE"/>
+ <enum name="GL_TEXTURE_PRIORITY"/>
+ <enum name="GL_TEXTURE_RESIDENT"/>
+ <enum name="GL_AMBIENT"/>
+ <enum name="GL_DIFFUSE"/>
+ <enum name="GL_SPECULAR"/>
+ <enum name="GL_POSITION"/>
+ <enum name="GL_SPOT_DIRECTION"/>
+ <enum name="GL_SPOT_EXPONENT"/>
+ <enum name="GL_SPOT_CUTOFF"/>
+ <enum name="GL_CONSTANT_ATTENUATION"/>
+ <enum name="GL_LINEAR_ATTENUATION"/>
+ <enum name="GL_QUADRATIC_ATTENUATION"/>
+ <enum name="GL_COMPILE"/>
+ <enum name="GL_COMPILE_AND_EXECUTE"/>
+ <enum name="GL_2_BYTES"/>
+ <enum name="GL_3_BYTES"/>
+ <enum name="GL_4_BYTES"/>
+ <enum name="GL_EMISSION"/>
+ <enum name="GL_SHININESS"/>
+ <enum name="GL_AMBIENT_AND_DIFFUSE"/>
+ <enum name="GL_COLOR_INDEXES"/>
+ <enum name="GL_MODELVIEW"/>
+ <enum name="GL_PROJECTION"/>
+ <enum name="GL_COLOR_INDEX"/>
+ <enum name="GL_LUMINANCE"/>
+ <enum name="GL_LUMINANCE_ALPHA"/>
+ <enum name="GL_BITMAP"/>
+ <enum name="GL_RENDER"/>
+ <enum name="GL_FEEDBACK"/>
+ <enum name="GL_SELECT"/>
+ <enum name="GL_FLAT"/>
+ <enum name="GL_SMOOTH"/>
+ <enum name="GL_S"/>
+ <enum name="GL_T"/>
+ <enum name="GL_R"/>
+ <enum name="GL_Q"/>
+ <enum name="GL_MODULATE"/>
+ <enum name="GL_DECAL"/>
+ <enum name="GL_TEXTURE_ENV_MODE"/>
+ <enum name="GL_TEXTURE_ENV_COLOR"/>
+ <enum name="GL_TEXTURE_ENV"/>
+ <enum name="GL_EYE_LINEAR"/>
+ <enum name="GL_OBJECT_LINEAR"/>
+ <enum name="GL_SPHERE_MAP"/>
+ <enum name="GL_TEXTURE_GEN_MODE"/>
+ <enum name="GL_OBJECT_PLANE"/>
+ <enum name="GL_EYE_PLANE"/>
+ <enum name="GL_CLAMP"/>
+ <enum name="GL_ALPHA4"/>
+ <enum name="GL_ALPHA8"/>
+ <enum name="GL_ALPHA12"/>
+ <enum name="GL_ALPHA16"/>
+ <enum name="GL_LUMINANCE4"/>
+ <enum name="GL_LUMINANCE8"/>
+ <enum name="GL_LUMINANCE12"/>
+ <enum name="GL_LUMINANCE16"/>
+ <enum name="GL_LUMINANCE4_ALPHA4"/>
+ <enum name="GL_LUMINANCE6_ALPHA2"/>
+ <enum name="GL_LUMINANCE8_ALPHA8"/>
+ <enum name="GL_LUMINANCE12_ALPHA4"/>
+ <enum name="GL_LUMINANCE12_ALPHA12"/>
+ <enum name="GL_LUMINANCE16_ALPHA16"/>
+ <enum name="GL_INTENSITY"/>
+ <enum name="GL_INTENSITY4"/>
+ <enum name="GL_INTENSITY8"/>
+ <enum name="GL_INTENSITY12"/>
+ <enum name="GL_INTENSITY16"/>
+ <enum name="GL_V2F"/>
+ <enum name="GL_V3F"/>
+ <enum name="GL_C4UB_V2F"/>
+ <enum name="GL_C4UB_V3F"/>
+ <enum name="GL_C3F_V3F"/>
+ <enum name="GL_N3F_V3F"/>
+ <enum name="GL_C4F_N3F_V3F"/>
+ <enum name="GL_T2F_V3F"/>
+ <enum name="GL_T4F_V4F"/>
+ <enum name="GL_T2F_C4UB_V3F"/>
+ <enum name="GL_T2F_C3F_V3F"/>
+ <enum name="GL_T2F_N3F_V3F"/>
+ <enum name="GL_T2F_C4F_N3F_V3F"/>
+ <enum name="GL_T4F_C4F_N3F_V4F"/>
+ <enum name="GL_CLIP_PLANE0"/>
+ <enum name="GL_CLIP_PLANE1"/>
+ <enum name="GL_CLIP_PLANE2"/>
+ <enum name="GL_CLIP_PLANE3"/>
+ <enum name="GL_CLIP_PLANE4"/>
+ <enum name="GL_CLIP_PLANE5"/>
+ <enum name="GL_LIGHT0"/>
+ <enum name="GL_LIGHT1"/>
+ <enum name="GL_LIGHT2"/>
+ <enum name="GL_LIGHT3"/>
+ <enum name="GL_LIGHT4"/>
+ <enum name="GL_LIGHT5"/>
+ <enum name="GL_LIGHT6"/>
+ <enum name="GL_LIGHT7"/>
+ <command name="glDrawArrays"/>
+ <command name="glDrawElements"/>
+ <command name="glGetPointerv"/>
+ <command name="glPolygonOffset"/>
+ <command name="glCopyTexImage1D"/>
+ <command name="glCopyTexImage2D"/>
+ <command name="glCopyTexSubImage1D"/>
+ <command name="glCopyTexSubImage2D"/>
+ <command name="glTexSubImage1D"/>
+ <command name="glTexSubImage2D"/>
+ <command name="glBindTexture"/>
+ <command name="glDeleteTextures"/>
+ <command name="glGenTextures"/>
+ <command name="glIsTexture"/>
+ <command name="glArrayElement"/>
+ <command name="glColorPointer"/>
+ <command name="glDisableClientState"/>
+ <command name="glEdgeFlagPointer"/>
+ <command name="glEnableClientState"/>
+ <command name="glIndexPointer"/>
+ <command name="glInterleavedArrays"/>
+ <command name="glNormalPointer"/>
+ <command name="glTexCoordPointer"/>
+ <command name="glVertexPointer"/>
+ <command name="glAreTexturesResident"/>
+ <command name="glPrioritizeTextures"/>
+ <command name="glIndexub"/>
+ <command name="glIndexubv"/>
+ <command name="glPopClientAttrib"/>
+ <command name="glPushClientAttrib"/>
+ </require>
+ </feature>
+ <feature api="gl" name="GL_VERSION_1_2" number="1.2">
+ <require>
+ <enum name="GL_UNSIGNED_BYTE_3_3_2"/>
+ <enum name="GL_UNSIGNED_SHORT_4_4_4_4"/>
+ <enum name="GL_UNSIGNED_SHORT_5_5_5_1"/>
+ <enum name="GL_UNSIGNED_INT_8_8_8_8"/>
+ <enum name="GL_UNSIGNED_INT_10_10_10_2"/>
+ <enum name="GL_TEXTURE_BINDING_3D"/>
+ <enum name="GL_PACK_SKIP_IMAGES"/>
+ <enum name="GL_PACK_IMAGE_HEIGHT"/>
+ <enum name="GL_UNPACK_SKIP_IMAGES"/>
+ <enum name="GL_UNPACK_IMAGE_HEIGHT"/>
+ <enum name="GL_TEXTURE_3D"/>
+ <enum name="GL_PROXY_TEXTURE_3D"/>
+ <enum name="GL_TEXTURE_DEPTH"/>
+ <enum name="GL_TEXTURE_WRAP_R"/>
+ <enum name="GL_MAX_3D_TEXTURE_SIZE"/>
+ <enum name="GL_UNSIGNED_BYTE_2_3_3_REV"/>
+ <enum name="GL_UNSIGNED_SHORT_5_6_5"/>
+ <enum name="GL_UNSIGNED_SHORT_5_6_5_REV"/>
+ <enum name="GL_UNSIGNED_SHORT_4_4_4_4_REV"/>
+ <enum name="GL_UNSIGNED_SHORT_1_5_5_5_REV"/>
+ <enum name="GL_UNSIGNED_INT_8_8_8_8_REV"/>
+ <enum name="GL_UNSIGNED_INT_2_10_10_10_REV"/>
+ <enum name="GL_BGR"/>
+ <enum name="GL_BGRA"/>
+ <enum name="GL_MAX_ELEMENTS_VERTICES"/>
+ <enum name="GL_MAX_ELEMENTS_INDICES"/>
+ <enum name="GL_CLAMP_TO_EDGE"/>
+ <enum name="GL_TEXTURE_MIN_LOD"/>
+ <enum name="GL_TEXTURE_MAX_LOD"/>
+ <enum name="GL_TEXTURE_BASE_LEVEL"/>
+ <enum name="GL_TEXTURE_MAX_LEVEL"/>
+ <enum name="GL_SMOOTH_POINT_SIZE_RANGE"/>
+ <enum name="GL_SMOOTH_POINT_SIZE_GRANULARITY"/>
+ <enum name="GL_SMOOTH_LINE_WIDTH_RANGE"/>
+ <enum name="GL_SMOOTH_LINE_WIDTH_GRANULARITY"/>
+ <enum name="GL_ALIASED_LINE_WIDTH_RANGE"/>
+ <enum name="GL_RESCALE_NORMAL"/>
+ <enum name="GL_LIGHT_MODEL_COLOR_CONTROL"/>
+ <enum name="GL_SINGLE_COLOR"/>
+ <enum name="GL_SEPARATE_SPECULAR_COLOR"/>
+ <enum name="GL_ALIASED_POINT_SIZE_RANGE"/>
+ <command name="glDrawRangeElements"/>
+ <command name="glTexImage3D"/>
+ <command name="glTexSubImage3D"/>
+ <command name="glCopyTexSubImage3D"/>
+ </require>
+ </feature>
+ <feature api="gl" name="GL_VERSION_1_3" number="1.3">
+ <require>
+ <enum name="GL_TEXTURE0"/>
+ <enum name="GL_TEXTURE1"/>
+ <enum name="GL_TEXTURE2"/>
+ <enum name="GL_TEXTURE3"/>
+ <enum name="GL_TEXTURE4"/>
+ <enum name="GL_TEXTURE5"/>
+ <enum name="GL_TEXTURE6"/>
+ <enum name="GL_TEXTURE7"/>
+ <enum name="GL_TEXTURE8"/>
+ <enum name="GL_TEXTURE9"/>
+ <enum name="GL_TEXTURE10"/>
+ <enum name="GL_TEXTURE11"/>
+ <enum name="GL_TEXTURE12"/>
+ <enum name="GL_TEXTURE13"/>
+ <enum name="GL_TEXTURE14"/>
+ <enum name="GL_TEXTURE15"/>
+ <enum name="GL_TEXTURE16"/>
+ <enum name="GL_TEXTURE17"/>
+ <enum name="GL_TEXTURE18"/>
+ <enum name="GL_TEXTURE19"/>
+ <enum name="GL_TEXTURE20"/>
+ <enum name="GL_TEXTURE21"/>
+ <enum name="GL_TEXTURE22"/>
+ <enum name="GL_TEXTURE23"/>
+ <enum name="GL_TEXTURE24"/>
+ <enum name="GL_TEXTURE25"/>
+ <enum name="GL_TEXTURE26"/>
+ <enum name="GL_TEXTURE27"/>
+ <enum name="GL_TEXTURE28"/>
+ <enum name="GL_TEXTURE29"/>
+ <enum name="GL_TEXTURE30"/>
+ <enum name="GL_TEXTURE31"/>
+ <enum name="GL_ACTIVE_TEXTURE"/>
+ <enum name="GL_MULTISAMPLE"/>
+ <enum name="GL_SAMPLE_ALPHA_TO_COVERAGE"/>
+ <enum name="GL_SAMPLE_ALPHA_TO_ONE"/>
+ <enum name="GL_SAMPLE_COVERAGE"/>
+ <enum name="GL_SAMPLE_BUFFERS"/>
+ <enum name="GL_SAMPLES"/>
+ <enum name="GL_SAMPLE_COVERAGE_VALUE"/>
+ <enum name="GL_SAMPLE_COVERAGE_INVERT"/>
+ <enum name="GL_TEXTURE_CUBE_MAP"/>
+ <enum name="GL_TEXTURE_BINDING_CUBE_MAP"/>
+ <enum name="GL_TEXTURE_CUBE_MAP_POSITIVE_X"/>
+ <enum name="GL_TEXTURE_CUBE_MAP_NEGATIVE_X"/>
+ <enum name="GL_TEXTURE_CUBE_MAP_POSITIVE_Y"/>
+ <enum name="GL_TEXTURE_CUBE_MAP_NEGATIVE_Y"/>
+ <enum name="GL_TEXTURE_CUBE_MAP_POSITIVE_Z"/>
+ <enum name="GL_TEXTURE_CUBE_MAP_NEGATIVE_Z"/>
+ <enum name="GL_PROXY_TEXTURE_CUBE_MAP"/>
+ <enum name="GL_MAX_CUBE_MAP_TEXTURE_SIZE"/>
+ <enum name="GL_COMPRESSED_RGB"/>
+ <enum name="GL_COMPRESSED_RGBA"/>
+ <enum name="GL_TEXTURE_COMPRESSION_HINT"/>
+ <enum name="GL_TEXTURE_COMPRESSED_IMAGE_SIZE"/>
+ <enum name="GL_TEXTURE_COMPRESSED"/>
+ <enum name="GL_NUM_COMPRESSED_TEXTURE_FORMATS"/>
+ <enum name="GL_COMPRESSED_TEXTURE_FORMATS"/>
+ <enum name="GL_CLAMP_TO_BORDER"/>
+ <enum name="GL_CLIENT_ACTIVE_TEXTURE"/>
+ <enum name="GL_MAX_TEXTURE_UNITS"/>
+ <enum name="GL_TRANSPOSE_MODELVIEW_MATRIX"/>
+ <enum name="GL_TRANSPOSE_PROJECTION_MATRIX"/>
+ <enum name="GL_TRANSPOSE_TEXTURE_MATRIX"/>
+ <enum name="GL_TRANSPOSE_COLOR_MATRIX"/>
+ <enum name="GL_MULTISAMPLE_BIT"/>
+ <enum name="GL_NORMAL_MAP"/>
+ <enum name="GL_REFLECTION_MAP"/>
+ <enum name="GL_COMPRESSED_ALPHA"/>
+ <enum name="GL_COMPRESSED_LUMINANCE"/>
+ <enum name="GL_COMPRESSED_LUMINANCE_ALPHA"/>
+ <enum name="GL_COMPRESSED_INTENSITY"/>
+ <enum name="GL_COMBINE"/>
+ <enum name="GL_COMBINE_RGB"/>
+ <enum name="GL_COMBINE_ALPHA"/>
+ <enum name="GL_SOURCE0_RGB"/>
+ <enum name="GL_SOURCE1_RGB"/>
+ <enum name="GL_SOURCE2_RGB"/>
+ <enum name="GL_SOURCE0_ALPHA"/>
+ <enum name="GL_SOURCE1_ALPHA"/>
+ <enum name="GL_SOURCE2_ALPHA"/>
+ <enum name="GL_OPERAND0_RGB"/>
+ <enum name="GL_OPERAND1_RGB"/>
+ <enum name="GL_OPERAND2_RGB"/>
+ <enum name="GL_OPERAND0_ALPHA"/>
+ <enum name="GL_OPERAND1_ALPHA"/>
+ <enum name="GL_OPERAND2_ALPHA"/>
+ <enum name="GL_RGB_SCALE"/>
+ <enum name="GL_ADD_SIGNED"/>
+ <enum name="GL_INTERPOLATE"/>
+ <enum name="GL_SUBTRACT"/>
+ <enum name="GL_CONSTANT"/>
+ <enum name="GL_PRIMARY_COLOR"/>
+ <enum name="GL_PREVIOUS"/>
+ <enum name="GL_DOT3_RGB"/>
+ <enum name="GL_DOT3_RGBA"/>
+ <command name="glActiveTexture"/>
+ <command name="glSampleCoverage"/>
+ <command name="glCompressedTexImage3D"/>
+ <command name="glCompressedTexImage2D"/>
+ <command name="glCompressedTexImage1D"/>
+ <command name="glCompressedTexSubImage3D"/>
+ <command name="glCompressedTexSubImage2D"/>
+ <command name="glCompressedTexSubImage1D"/>
+ <command name="glGetCompressedTexImage"/>
+ <command name="glClientActiveTexture"/>
+ <command name="glMultiTexCoord1d"/>
+ <command name="glMultiTexCoord1dv"/>
+ <command name="glMultiTexCoord1f"/>
+ <command name="glMultiTexCoord1fv"/>
+ <command name="glMultiTexCoord1i"/>
+ <command name="glMultiTexCoord1iv"/>
+ <command name="glMultiTexCoord1s"/>
+ <command name="glMultiTexCoord1sv"/>
+ <command name="glMultiTexCoord2d"/>
+ <command name="glMultiTexCoord2dv"/>
+ <command name="glMultiTexCoord2f"/>
+ <command name="glMultiTexCoord2fv"/>
+ <command name="glMultiTexCoord2i"/>
+ <command name="glMultiTexCoord2iv"/>
+ <command name="glMultiTexCoord2s"/>
+ <command name="glMultiTexCoord2sv"/>
+ <command name="glMultiTexCoord3d"/>
+ <command name="glMultiTexCoord3dv"/>
+ <command name="glMultiTexCoord3f"/>
+ <command name="glMultiTexCoord3fv"/>
+ <command name="glMultiTexCoord3i"/>
+ <command name="glMultiTexCoord3iv"/>
+ <command name="glMultiTexCoord3s"/>
+ <command name="glMultiTexCoord3sv"/>
+ <command name="glMultiTexCoord4d"/>
+ <command name="glMultiTexCoord4dv"/>
+ <command name="glMultiTexCoord4f"/>
+ <command name="glMultiTexCoord4fv"/>
+ <command name="glMultiTexCoord4i"/>
+ <command name="glMultiTexCoord4iv"/>
+ <command name="glMultiTexCoord4s"/>
+ <command name="glMultiTexCoord4sv"/>
+ <command name="glLoadTransposeMatrixf"/>
+ <command name="glLoadTransposeMatrixd"/>
+ <command name="glMultTransposeMatrixf"/>
+ <command name="glMultTransposeMatrixd"/>
+ </require>
+ </feature>
+ <feature api="gl" name="GL_VERSION_1_4" number="1.4">
+ <require>
+ <enum name="GL_BLEND_DST_RGB"/>
+ <enum name="GL_BLEND_SRC_RGB"/>
+ <enum name="GL_BLEND_DST_ALPHA"/>
+ <enum name="GL_BLEND_SRC_ALPHA"/>
+ <enum name="GL_POINT_FADE_THRESHOLD_SIZE"/>
+ <enum name="GL_DEPTH_COMPONENT16"/>
+ <enum name="GL_DEPTH_COMPONENT24"/>
+ <enum name="GL_DEPTH_COMPONENT32"/>
+ <enum name="GL_MIRRORED_REPEAT"/>
+ <enum name="GL_MAX_TEXTURE_LOD_BIAS"/>
+ <enum name="GL_TEXTURE_LOD_BIAS"/>
+ <enum name="GL_INCR_WRAP"/>
+ <enum name="GL_DECR_WRAP"/>
+ <enum name="GL_TEXTURE_DEPTH_SIZE"/>
+ <enum name="GL_TEXTURE_COMPARE_MODE"/>
+ <enum name="GL_TEXTURE_COMPARE_FUNC"/>
+ <enum name="GL_POINT_SIZE_MIN"/>
+ <enum name="GL_POINT_SIZE_MAX"/>
+ <enum name="GL_POINT_DISTANCE_ATTENUATION"/>
+ <enum name="GL_GENERATE_MIPMAP"/>
+ <enum name="GL_GENERATE_MIPMAP_HINT"/>
+ <enum name="GL_FOG_COORDINATE_SOURCE"/>
+ <enum name="GL_FOG_COORDINATE"/>
+ <enum name="GL_FRAGMENT_DEPTH"/>
+ <enum name="GL_CURRENT_FOG_COORDINATE"/>
+ <enum name="GL_FOG_COORDINATE_ARRAY_TYPE"/>
+ <enum name="GL_FOG_COORDINATE_ARRAY_STRIDE"/>
+ <enum name="GL_FOG_COORDINATE_ARRAY_POINTER"/>
+ <enum name="GL_FOG_COORDINATE_ARRAY"/>
+ <enum name="GL_COLOR_SUM"/>
+ <enum name="GL_CURRENT_SECONDARY_COLOR"/>
+ <enum name="GL_SECONDARY_COLOR_ARRAY_SIZE"/>
+ <enum name="GL_SECONDARY_COLOR_ARRAY_TYPE"/>
+ <enum name="GL_SECONDARY_COLOR_ARRAY_STRIDE"/>
+ <enum name="GL_SECONDARY_COLOR_ARRAY_POINTER"/>
+ <enum name="GL_SECONDARY_COLOR_ARRAY"/>
+ <enum name="GL_TEXTURE_FILTER_CONTROL"/>
+ <enum name="GL_DEPTH_TEXTURE_MODE"/>
+ <enum name="GL_COMPARE_R_TO_TEXTURE"/>
+ <command name="glBlendFuncSeparate"/>
+ <command name="glMultiDrawArrays"/>
+ <command name="glMultiDrawElements"/>
+ <command name="glPointParameterf"/>
+ <command name="glPointParameterfv"/>
+ <command name="glPointParameteri"/>
+ <command name="glPointParameteriv"/>
+ <command name="glFogCoordf"/>
+ <command name="glFogCoordfv"/>
+ <command name="glFogCoordd"/>
+ <command name="glFogCoorddv"/>
+ <command name="glFogCoordPointer"/>
+ <command name="glSecondaryColor3b"/>
+ <command name="glSecondaryColor3bv"/>
+ <command name="glSecondaryColor3d"/>
+ <command name="glSecondaryColor3dv"/>
+ <command name="glSecondaryColor3f"/>
+ <command name="glSecondaryColor3fv"/>
+ <command name="glSecondaryColor3i"/>
+ <command name="glSecondaryColor3iv"/>
+ <command name="glSecondaryColor3s"/>
+ <command name="glSecondaryColor3sv"/>
+ <command name="glSecondaryColor3ub"/>
+ <command name="glSecondaryColor3ubv"/>
+ <command name="glSecondaryColor3ui"/>
+ <command name="glSecondaryColor3uiv"/>
+ <command name="glSecondaryColor3us"/>
+ <command name="glSecondaryColor3usv"/>
+ <command name="glSecondaryColorPointer"/>
+ <command name="glWindowPos2d"/>
+ <command name="glWindowPos2dv"/>
+ <command name="glWindowPos2f"/>
+ <command name="glWindowPos2fv"/>
+ <command name="glWindowPos2i"/>
+ <command name="glWindowPos2iv"/>
+ <command name="glWindowPos2s"/>
+ <command name="glWindowPos2sv"/>
+ <command name="glWindowPos3d"/>
+ <command name="glWindowPos3dv"/>
+ <command name="glWindowPos3f"/>
+ <command name="glWindowPos3fv"/>
+ <command name="glWindowPos3i"/>
+ <command name="glWindowPos3iv"/>
+ <command name="glWindowPos3s"/>
+ <command name="glWindowPos3sv"/>
+ </require>
+ <require comment="Promoted from ARB_imaging subset to core">
+ <enum name="GL_FUNC_ADD"/>
+ <enum name="GL_FUNC_SUBTRACT"/>
+ <enum name="GL_FUNC_REVERSE_SUBTRACT"/>
+ <enum name="GL_MIN"/>
+ <enum name="GL_MAX"/>
+ <enum name="GL_CONSTANT_COLOR"/>
+ <enum name="GL_ONE_MINUS_CONSTANT_COLOR"/>
+ <enum name="GL_CONSTANT_ALPHA"/>
+ <enum name="GL_ONE_MINUS_CONSTANT_ALPHA"/>
+ <command name="glBlendColor"/>
+ <command name="glBlendEquation"/>
+ </require>
+ </feature>
+ <feature api="gl" name="GL_VERSION_1_5" number="1.5">
+ <require>
+ <enum name="GL_BUFFER_SIZE"/>
+ <enum name="GL_BUFFER_USAGE"/>
+ <enum name="GL_QUERY_COUNTER_BITS"/>
+ <enum name="GL_CURRENT_QUERY"/>
+ <enum name="GL_QUERY_RESULT"/>
+ <enum name="GL_QUERY_RESULT_AVAILABLE"/>
+ <enum name="GL_ARRAY_BUFFER"/>
+ <enum name="GL_ELEMENT_ARRAY_BUFFER"/>
+ <enum name="GL_ARRAY_BUFFER_BINDING"/>
+ <enum name="GL_ELEMENT_ARRAY_BUFFER_BINDING"/>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY_BUFFER_BINDING"/>
+ <enum name="GL_READ_ONLY"/>
+ <enum name="GL_WRITE_ONLY"/>
+ <enum name="GL_READ_WRITE"/>
+ <enum name="GL_BUFFER_ACCESS"/>
+ <enum name="GL_BUFFER_MAPPED"/>
+ <enum name="GL_BUFFER_MAP_POINTER"/>
+ <enum name="GL_STREAM_DRAW"/>
+ <enum name="GL_STREAM_READ"/>
+ <enum name="GL_STREAM_COPY"/>
+ <enum name="GL_STATIC_DRAW"/>
+ <enum name="GL_STATIC_READ"/>
+ <enum name="GL_STATIC_COPY"/>
+ <enum name="GL_DYNAMIC_DRAW"/>
+ <enum name="GL_DYNAMIC_READ"/>
+ <enum name="GL_DYNAMIC_COPY"/>
+ <enum name="GL_SAMPLES_PASSED"/>
+ <enum name="GL_SRC1_ALPHA"/>
+ <enum name="GL_VERTEX_ARRAY_BUFFER_BINDING"/>
+ <enum name="GL_NORMAL_ARRAY_BUFFER_BINDING"/>
+ <enum name="GL_COLOR_ARRAY_BUFFER_BINDING"/>
+ <enum name="GL_INDEX_ARRAY_BUFFER_BINDING"/>
+ <enum name="GL_TEXTURE_COORD_ARRAY_BUFFER_BINDING"/>
+ <enum name="GL_EDGE_FLAG_ARRAY_BUFFER_BINDING"/>
+ <enum name="GL_SECONDARY_COLOR_ARRAY_BUFFER_BINDING"/>
+ <enum name="GL_FOG_COORDINATE_ARRAY_BUFFER_BINDING"/>
+ <enum name="GL_WEIGHT_ARRAY_BUFFER_BINDING"/>
+ <enum name="GL_FOG_COORD_SRC"/>
+ <enum name="GL_FOG_COORD"/>
+ <enum name="GL_CURRENT_FOG_COORD"/>
+ <enum name="GL_FOG_COORD_ARRAY_TYPE"/>
+ <enum name="GL_FOG_COORD_ARRAY_STRIDE"/>
+ <enum name="GL_FOG_COORD_ARRAY_POINTER"/>
+ <enum name="GL_FOG_COORD_ARRAY"/>
+ <enum name="GL_FOG_COORD_ARRAY_BUFFER_BINDING"/>
+ <enum name="GL_SRC0_RGB"/>
+ <enum name="GL_SRC1_RGB"/>
+ <enum name="GL_SRC2_RGB"/>
+ <enum name="GL_SRC0_ALPHA"/>
+ <enum name="GL_SRC2_ALPHA"/>
+ <command name="glGenQueries"/>
+ <command name="glDeleteQueries"/>
+ <command name="glIsQuery"/>
+ <command name="glBeginQuery"/>
+ <command name="glEndQuery"/>
+ <command name="glGetQueryiv"/>
+ <command name="glGetQueryObjectiv"/>
+ <command name="glGetQueryObjectuiv"/>
+ <command name="glBindBuffer"/>
+ <command name="glDeleteBuffers"/>
+ <command name="glGenBuffers"/>
+ <command name="glIsBuffer"/>
+ <command name="glBufferData"/>
+ <command name="glBufferSubData"/>
+ <command name="glGetBufferSubData"/>
+ <command name="glMapBuffer"/>
+ <command name="glUnmapBuffer"/>
+ <command name="glGetBufferParameteriv"/>
+ <command name="glGetBufferPointerv"/>
+ </require>
+ </feature>
+ <feature api="gl" name="GL_VERSION_2_0" number="2.0">
+ <require>
+ <enum name="GL_BLEND_EQUATION_RGB"/>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY_ENABLED"/>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY_SIZE"/>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY_STRIDE"/>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY_TYPE"/>
+ <enum name="GL_CURRENT_VERTEX_ATTRIB"/>
+ <enum name="GL_VERTEX_PROGRAM_POINT_SIZE"/>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY_POINTER"/>
+ <enum name="GL_STENCIL_BACK_FUNC"/>
+ <enum name="GL_STENCIL_BACK_FAIL"/>
+ <enum name="GL_STENCIL_BACK_PASS_DEPTH_FAIL"/>
+ <enum name="GL_STENCIL_BACK_PASS_DEPTH_PASS"/>
+ <enum name="GL_MAX_DRAW_BUFFERS"/>
+ <enum name="GL_DRAW_BUFFER0"/>
+ <enum name="GL_DRAW_BUFFER1"/>
+ <enum name="GL_DRAW_BUFFER2"/>
+ <enum name="GL_DRAW_BUFFER3"/>
+ <enum name="GL_DRAW_BUFFER4"/>
+ <enum name="GL_DRAW_BUFFER5"/>
+ <enum name="GL_DRAW_BUFFER6"/>
+ <enum name="GL_DRAW_BUFFER7"/>
+ <enum name="GL_DRAW_BUFFER8"/>
+ <enum name="GL_DRAW_BUFFER9"/>
+ <enum name="GL_DRAW_BUFFER10"/>
+ <enum name="GL_DRAW_BUFFER11"/>
+ <enum name="GL_DRAW_BUFFER12"/>
+ <enum name="GL_DRAW_BUFFER13"/>
+ <enum name="GL_DRAW_BUFFER14"/>
+ <enum name="GL_DRAW_BUFFER15"/>
+ <enum name="GL_BLEND_EQUATION_ALPHA"/>
+ <enum name="GL_MAX_VERTEX_ATTRIBS"/>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY_NORMALIZED"/>
+ <enum name="GL_MAX_TEXTURE_IMAGE_UNITS"/>
+ <enum name="GL_FRAGMENT_SHADER"/>
+ <enum name="GL_VERTEX_SHADER"/>
+ <enum name="GL_MAX_FRAGMENT_UNIFORM_COMPONENTS"/>
+ <enum name="GL_MAX_VERTEX_UNIFORM_COMPONENTS"/>
+ <enum name="GL_MAX_VARYING_FLOATS"/>
+ <enum name="GL_MAX_VERTEX_TEXTURE_IMAGE_UNITS"/>
+ <enum name="GL_MAX_COMBINED_TEXTURE_IMAGE_UNITS"/>
+ <enum name="GL_SHADER_TYPE"/>
+ <enum name="GL_FLOAT_VEC2"/>
+ <enum name="GL_FLOAT_VEC3"/>
+ <enum name="GL_FLOAT_VEC4"/>
+ <enum name="GL_INT_VEC2"/>
+ <enum name="GL_INT_VEC3"/>
+ <enum name="GL_INT_VEC4"/>
+ <enum name="GL_BOOL"/>
+ <enum name="GL_BOOL_VEC2"/>
+ <enum name="GL_BOOL_VEC3"/>
+ <enum name="GL_BOOL_VEC4"/>
+ <enum name="GL_FLOAT_MAT2"/>
+ <enum name="GL_FLOAT_MAT3"/>
+ <enum name="GL_FLOAT_MAT4"/>
+ <enum name="GL_SAMPLER_1D"/>
+ <enum name="GL_SAMPLER_2D"/>
+ <enum name="GL_SAMPLER_3D"/>
+ <enum name="GL_SAMPLER_CUBE"/>
+ <enum name="GL_SAMPLER_1D_SHADOW"/>
+ <enum name="GL_SAMPLER_2D_SHADOW"/>
+ <enum name="GL_DELETE_STATUS"/>
+ <enum name="GL_COMPILE_STATUS"/>
+ <enum name="GL_LINK_STATUS"/>
+ <enum name="GL_VALIDATE_STATUS"/>
+ <enum name="GL_INFO_LOG_LENGTH"/>
+ <enum name="GL_ATTACHED_SHADERS"/>
+ <enum name="GL_ACTIVE_UNIFORMS"/>
+ <enum name="GL_ACTIVE_UNIFORM_MAX_LENGTH"/>
+ <enum name="GL_SHADER_SOURCE_LENGTH"/>
+ <enum name="GL_ACTIVE_ATTRIBUTES"/>
+ <enum name="GL_ACTIVE_ATTRIBUTE_MAX_LENGTH"/>
+ <enum name="GL_FRAGMENT_SHADER_DERIVATIVE_HINT"/>
+ <enum name="GL_SHADING_LANGUAGE_VERSION"/>
+ <enum name="GL_CURRENT_PROGRAM"/>
+ <enum name="GL_POINT_SPRITE_COORD_ORIGIN"/>
+ <enum name="GL_LOWER_LEFT"/>
+ <enum name="GL_UPPER_LEFT"/>
+ <enum name="GL_STENCIL_BACK_REF"/>
+ <enum name="GL_STENCIL_BACK_VALUE_MASK"/>
+ <enum name="GL_STENCIL_BACK_WRITEMASK"/>
+ <enum name="GL_VERTEX_PROGRAM_TWO_SIDE"/>
+ <enum name="GL_POINT_SPRITE"/>
+ <enum name="GL_COORD_REPLACE"/>
+ <enum name="GL_MAX_TEXTURE_COORDS"/>
+ <command name="glBlendEquationSeparate"/>
+ <command name="glDrawBuffers"/>
+ <command name="glStencilOpSeparate"/>
+ <command name="glStencilFuncSeparate"/>
+ <command name="glStencilMaskSeparate"/>
+ <command name="glAttachShader"/>
+ <command name="glBindAttribLocation"/>
+ <command name="glCompileShader"/>
+ <command name="glCreateProgram"/>
+ <command name="glCreateShader"/>
+ <command name="glDeleteProgram"/>
+ <command name="glDeleteShader"/>
+ <command name="glDetachShader"/>
+ <command name="glDisableVertexAttribArray"/>
+ <command name="glEnableVertexAttribArray"/>
+ <command name="glGetActiveAttrib"/>
+ <command name="glGetActiveUniform"/>
+ <command name="glGetAttachedShaders"/>
+ <command name="glGetAttribLocation"/>
+ <command name="glGetProgramiv"/>
+ <command name="glGetProgramInfoLog"/>
+ <command name="glGetShaderiv"/>
+ <command name="glGetShaderInfoLog"/>
+ <command name="glGetShaderSource"/>
+ <command name="glGetUniformLocation"/>
+ <command name="glGetUniformfv"/>
+ <command name="glGetUniformiv"/>
+ <command name="glGetVertexAttribdv"/>
+ <command name="glGetVertexAttribfv"/>
+ <command name="glGetVertexAttribiv"/>
+ <command name="glGetVertexAttribPointerv"/>
+ <command name="glIsProgram"/>
+ <command name="glIsShader"/>
+ <command name="glLinkProgram"/>
+ <command name="glShaderSource"/>
+ <command name="glUseProgram"/>
+ <command name="glUniform1f"/>
+ <command name="glUniform2f"/>
+ <command name="glUniform3f"/>
+ <command name="glUniform4f"/>
+ <command name="glUniform1i"/>
+ <command name="glUniform2i"/>
+ <command name="glUniform3i"/>
+ <command name="glUniform4i"/>
+ <command name="glUniform1fv"/>
+ <command name="glUniform2fv"/>
+ <command name="glUniform3fv"/>
+ <command name="glUniform4fv"/>
+ <command name="glUniform1iv"/>
+ <command name="glUniform2iv"/>
+ <command name="glUniform3iv"/>
+ <command name="glUniform4iv"/>
+ <command name="glUniformMatrix2fv"/>
+ <command name="glUniformMatrix3fv"/>
+ <command name="glUniformMatrix4fv"/>
+ <command name="glValidateProgram"/>
+ <command name="glVertexAttrib1d"/>
+ <command name="glVertexAttrib1dv"/>
+ <command name="glVertexAttrib1f"/>
+ <command name="glVertexAttrib1fv"/>
+ <command name="glVertexAttrib1s"/>
+ <command name="glVertexAttrib1sv"/>
+ <command name="glVertexAttrib2d"/>
+ <command name="glVertexAttrib2dv"/>
+ <command name="glVertexAttrib2f"/>
+ <command name="glVertexAttrib2fv"/>
+ <command name="glVertexAttrib2s"/>
+ <command name="glVertexAttrib2sv"/>
+ <command name="glVertexAttrib3d"/>
+ <command name="glVertexAttrib3dv"/>
+ <command name="glVertexAttrib3f"/>
+ <command name="glVertexAttrib3fv"/>
+ <command name="glVertexAttrib3s"/>
+ <command name="glVertexAttrib3sv"/>
+ <command name="glVertexAttrib4Nbv"/>
+ <command name="glVertexAttrib4Niv"/>
+ <command name="glVertexAttrib4Nsv"/>
+ <command name="glVertexAttrib4Nub"/>
+ <command name="glVertexAttrib4Nubv"/>
+ <command name="glVertexAttrib4Nuiv"/>
+ <command name="glVertexAttrib4Nusv"/>
+ <command name="glVertexAttrib4bv"/>
+ <command name="glVertexAttrib4d"/>
+ <command name="glVertexAttrib4dv"/>
+ <command name="glVertexAttrib4f"/>
+ <command name="glVertexAttrib4fv"/>
+ <command name="glVertexAttrib4iv"/>
+ <command name="glVertexAttrib4s"/>
+ <command name="glVertexAttrib4sv"/>
+ <command name="glVertexAttrib4ubv"/>
+ <command name="glVertexAttrib4uiv"/>
+ <command name="glVertexAttrib4usv"/>
+ <command name="glVertexAttribPointer"/>
+ </require>
+ </feature>
+ <feature api="gl" name="GL_VERSION_2_1" number="2.1">
+ <require>
+ <enum name="GL_PIXEL_PACK_BUFFER"/>
+ <enum name="GL_PIXEL_UNPACK_BUFFER"/>
+ <enum name="GL_PIXEL_PACK_BUFFER_BINDING"/>
+ <enum name="GL_PIXEL_UNPACK_BUFFER_BINDING"/>
+ <enum name="GL_FLOAT_MAT2x3"/>
+ <enum name="GL_FLOAT_MAT2x4"/>
+ <enum name="GL_FLOAT_MAT3x2"/>
+ <enum name="GL_FLOAT_MAT3x4"/>
+ <enum name="GL_FLOAT_MAT4x2"/>
+ <enum name="GL_FLOAT_MAT4x3"/>
+ <enum name="GL_SRGB"/>
+ <enum name="GL_SRGB8"/>
+ <enum name="GL_SRGB_ALPHA"/>
+ <enum name="GL_SRGB8_ALPHA8"/>
+ <enum name="GL_COMPRESSED_SRGB"/>
+ <enum name="GL_COMPRESSED_SRGB_ALPHA"/>
+ <enum name="GL_CURRENT_RASTER_SECONDARY_COLOR"/>
+ <enum name="GL_SLUMINANCE_ALPHA"/>
+ <enum name="GL_SLUMINANCE8_ALPHA8"/>
+ <enum name="GL_SLUMINANCE"/>
+ <enum name="GL_SLUMINANCE8"/>
+ <enum name="GL_COMPRESSED_SLUMINANCE"/>
+ <enum name="GL_COMPRESSED_SLUMINANCE_ALPHA"/>
+ <command name="glUniformMatrix2x3fv"/>
+ <command name="glUniformMatrix3x2fv"/>
+ <command name="glUniformMatrix2x4fv"/>
+ <command name="glUniformMatrix4x2fv"/>
+ <command name="glUniformMatrix3x4fv"/>
+ <command name="glUniformMatrix4x3fv"/>
+ </require>
+ </feature>
+ <feature api="gl" name="GL_VERSION_3_0" number="3.0">
+ <require>
+ <enum name="GL_COMPARE_REF_TO_TEXTURE"/>
+ <enum name="GL_CLIP_DISTANCE0"/>
+ <enum name="GL_CLIP_DISTANCE1"/>
+ <enum name="GL_CLIP_DISTANCE2"/>
+ <enum name="GL_CLIP_DISTANCE3"/>
+ <enum name="GL_CLIP_DISTANCE4"/>
+ <enum name="GL_CLIP_DISTANCE5"/>
+ <enum name="GL_CLIP_DISTANCE6"/>
+ <enum name="GL_CLIP_DISTANCE7"/>
+ <enum name="GL_MAX_CLIP_DISTANCES"/>
+ <enum name="GL_MAJOR_VERSION"/>
+ <enum name="GL_MINOR_VERSION"/>
+ <enum name="GL_NUM_EXTENSIONS"/>
+ <enum name="GL_CONTEXT_FLAGS"/>
+ <enum name="GL_COMPRESSED_RED"/>
+ <enum name="GL_COMPRESSED_RG"/>
+ <enum name="GL_CONTEXT_FLAG_FORWARD_COMPATIBLE_BIT"/>
+ <enum name="GL_RGBA32F"/>
+ <enum name="GL_RGB32F"/>
+ <enum name="GL_RGBA16F"/>
+ <enum name="GL_RGB16F"/>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY_INTEGER"/>
+ <enum name="GL_MAX_ARRAY_TEXTURE_LAYERS"/>
+ <enum name="GL_MIN_PROGRAM_TEXEL_OFFSET"/>
+ <enum name="GL_MAX_PROGRAM_TEXEL_OFFSET"/>
+ <enum name="GL_CLAMP_READ_COLOR"/>
+ <enum name="GL_FIXED_ONLY"/>
+ <enum name="GL_MAX_VARYING_COMPONENTS"/>
+ <enum name="GL_TEXTURE_1D_ARRAY"/>
+ <enum name="GL_PROXY_TEXTURE_1D_ARRAY"/>
+ <enum name="GL_TEXTURE_2D_ARRAY"/>
+ <enum name="GL_PROXY_TEXTURE_2D_ARRAY"/>
+ <enum name="GL_TEXTURE_BINDING_1D_ARRAY"/>
+ <enum name="GL_TEXTURE_BINDING_2D_ARRAY"/>
+ <enum name="GL_R11F_G11F_B10F"/>
+ <enum name="GL_UNSIGNED_INT_10F_11F_11F_REV"/>
+ <enum name="GL_RGB9_E5"/>
+ <enum name="GL_UNSIGNED_INT_5_9_9_9_REV"/>
+ <enum name="GL_TEXTURE_SHARED_SIZE"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_VARYING_MAX_LENGTH"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_BUFFER_MODE"/>
+ <enum name="GL_MAX_TRANSFORM_FEEDBACK_SEPARATE_COMPONENTS"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_VARYINGS"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_BUFFER_START"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_BUFFER_SIZE"/>
+ <enum name="GL_PRIMITIVES_GENERATED"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN"/>
+ <enum name="GL_RASTERIZER_DISCARD"/>
+ <enum name="GL_MAX_TRANSFORM_FEEDBACK_INTERLEAVED_COMPONENTS"/>
+ <enum name="GL_MAX_TRANSFORM_FEEDBACK_SEPARATE_ATTRIBS"/>
+ <enum name="GL_INTERLEAVED_ATTRIBS"/>
+ <enum name="GL_SEPARATE_ATTRIBS"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_BUFFER"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_BUFFER_BINDING"/>
+ <enum name="GL_RGBA32UI"/>
+ <enum name="GL_RGB32UI"/>
+ <enum name="GL_RGBA16UI"/>
+ <enum name="GL_RGB16UI"/>
+ <enum name="GL_RGBA8UI"/>
+ <enum name="GL_RGB8UI"/>
+ <enum name="GL_RGBA32I"/>
+ <enum name="GL_RGB32I"/>
+ <enum name="GL_RGBA16I"/>
+ <enum name="GL_RGB16I"/>
+ <enum name="GL_RGBA8I"/>
+ <enum name="GL_RGB8I"/>
+ <enum name="GL_RED_INTEGER"/>
+ <enum name="GL_GREEN_INTEGER"/>
+ <enum name="GL_BLUE_INTEGER"/>
+ <enum name="GL_RGB_INTEGER"/>
+ <enum name="GL_RGBA_INTEGER"/>
+ <enum name="GL_BGR_INTEGER"/>
+ <enum name="GL_BGRA_INTEGER"/>
+ <enum name="GL_SAMPLER_1D_ARRAY"/>
+ <enum name="GL_SAMPLER_2D_ARRAY"/>
+ <enum name="GL_SAMPLER_1D_ARRAY_SHADOW"/>
+ <enum name="GL_SAMPLER_2D_ARRAY_SHADOW"/>
+ <enum name="GL_SAMPLER_CUBE_SHADOW"/>
+ <enum name="GL_UNSIGNED_INT_VEC2"/>
+ <enum name="GL_UNSIGNED_INT_VEC3"/>
+ <enum name="GL_UNSIGNED_INT_VEC4"/>
+ <enum name="GL_INT_SAMPLER_1D"/>
+ <enum name="GL_INT_SAMPLER_2D"/>
+ <enum name="GL_INT_SAMPLER_3D"/>
+ <enum name="GL_INT_SAMPLER_CUBE"/>
+ <enum name="GL_INT_SAMPLER_1D_ARRAY"/>
+ <enum name="GL_INT_SAMPLER_2D_ARRAY"/>
+ <enum name="GL_UNSIGNED_INT_SAMPLER_1D"/>
+ <enum name="GL_UNSIGNED_INT_SAMPLER_2D"/>
+ <enum name="GL_UNSIGNED_INT_SAMPLER_3D"/>
+ <enum name="GL_UNSIGNED_INT_SAMPLER_CUBE"/>
+ <enum name="GL_UNSIGNED_INT_SAMPLER_1D_ARRAY"/>
+ <enum name="GL_UNSIGNED_INT_SAMPLER_2D_ARRAY"/>
+ <enum name="GL_QUERY_WAIT"/>
+ <enum name="GL_QUERY_NO_WAIT"/>
+ <enum name="GL_QUERY_BY_REGION_WAIT"/>
+ <enum name="GL_QUERY_BY_REGION_NO_WAIT"/>
+ <enum name="GL_BUFFER_ACCESS_FLAGS"/>
+ <enum name="GL_BUFFER_MAP_LENGTH"/>
+ <enum name="GL_BUFFER_MAP_OFFSET"/>
+ <command name="glColorMaski"/>
+ <command name="glGetBooleani_v"/>
+ <command name="glGetIntegeri_v"/>
+ <command name="glEnablei"/>
+ <command name="glDisablei"/>
+ <command name="glIsEnabledi"/>
+ <command name="glBeginTransformFeedback"/>
+ <command name="glEndTransformFeedback"/>
+ <command name="glBindBufferRange"/>
+ <command name="glBindBufferBase"/>
+ <command name="glTransformFeedbackVaryings"/>
+ <command name="glGetTransformFeedbackVarying"/>
+ <command name="glClampColor"/>
+ <command name="glBeginConditionalRender"/>
+ <command name="glEndConditionalRender"/>
+ <command name="glVertexAttribIPointer"/>
+ <command name="glGetVertexAttribIiv"/>
+ <command name="glGetVertexAttribIuiv"/>
+ <command name="glVertexAttribI1i"/>
+ <command name="glVertexAttribI2i"/>
+ <command name="glVertexAttribI3i"/>
+ <command name="glVertexAttribI4i"/>
+ <command name="glVertexAttribI1ui"/>
+ <command name="glVertexAttribI2ui"/>
+ <command name="glVertexAttribI3ui"/>
+ <command name="glVertexAttribI4ui"/>
+ <command name="glVertexAttribI1iv"/>
+ <command name="glVertexAttribI2iv"/>
+ <command name="glVertexAttribI3iv"/>
+ <command name="glVertexAttribI4iv"/>
+ <command name="glVertexAttribI1uiv"/>
+ <command name="glVertexAttribI2uiv"/>
+ <command name="glVertexAttribI3uiv"/>
+ <command name="glVertexAttribI4uiv"/>
+ <command name="glVertexAttribI4bv"/>
+ <command name="glVertexAttribI4sv"/>
+ <command name="glVertexAttribI4ubv"/>
+ <command name="glVertexAttribI4usv"/>
+ <command name="glGetUniformuiv"/>
+ <command name="glBindFragDataLocation"/>
+ <command name="glGetFragDataLocation"/>
+ <command name="glUniform1ui"/>
+ <command name="glUniform2ui"/>
+ <command name="glUniform3ui"/>
+ <command name="glUniform4ui"/>
+ <command name="glUniform1uiv"/>
+ <command name="glUniform2uiv"/>
+ <command name="glUniform3uiv"/>
+ <command name="glUniform4uiv"/>
+ <command name="glTexParameterIiv"/>
+ <command name="glTexParameterIuiv"/>
+ <command name="glGetTexParameterIiv"/>
+ <command name="glGetTexParameterIuiv"/>
+ <command name="glClearBufferiv"/>
+ <command name="glClearBufferuiv"/>
+ <command name="glClearBufferfv"/>
+ <command name="glClearBufferfi"/>
+ <command name="glGetStringi"/>
+ </require>
+ <require comment="Reuse ARB_depth_buffer_float">
+ <enum name="GL_DEPTH_COMPONENT32F"/>
+ <enum name="GL_DEPTH32F_STENCIL8"/>
+ <enum name="GL_FLOAT_32_UNSIGNED_INT_24_8_REV"/>
+ </require>
+ <require comment="Reuse ARB_framebuffer_object">
+ <enum name="GL_INVALID_FRAMEBUFFER_OPERATION"/>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING"/>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE"/>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_RED_SIZE"/>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_GREEN_SIZE"/>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_BLUE_SIZE"/>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_ALPHA_SIZE"/>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_DEPTH_SIZE"/>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_STENCIL_SIZE"/>
+ <enum name="GL_FRAMEBUFFER_DEFAULT"/>
+ <enum name="GL_FRAMEBUFFER_UNDEFINED"/>
+ <enum name="GL_DEPTH_STENCIL_ATTACHMENT"/>
+ <enum name="GL_MAX_RENDERBUFFER_SIZE"/>
+ <enum name="GL_DEPTH_STENCIL"/>
+ <enum name="GL_UNSIGNED_INT_24_8"/>
+ <enum name="GL_DEPTH24_STENCIL8"/>
+ <enum name="GL_TEXTURE_STENCIL_SIZE"/>
+ <enum name="GL_TEXTURE_RED_TYPE"/>
+ <enum name="GL_TEXTURE_GREEN_TYPE"/>
+ <enum name="GL_TEXTURE_BLUE_TYPE"/>
+ <enum name="GL_TEXTURE_ALPHA_TYPE"/>
+ <enum name="GL_TEXTURE_DEPTH_TYPE"/>
+ <enum name="GL_UNSIGNED_NORMALIZED"/>
+ <enum name="GL_FRAMEBUFFER_BINDING"/>
+ <enum name="GL_DRAW_FRAMEBUFFER_BINDING"/>
+ <enum name="GL_RENDERBUFFER_BINDING"/>
+ <enum name="GL_READ_FRAMEBUFFER"/>
+ <enum name="GL_DRAW_FRAMEBUFFER"/>
+ <enum name="GL_READ_FRAMEBUFFER_BINDING"/>
+ <enum name="GL_RENDERBUFFER_SAMPLES"/>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE"/>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_OBJECT_NAME"/>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL"/>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE"/>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER"/>
+ <enum name="GL_FRAMEBUFFER_COMPLETE"/>
+ <enum name="GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT"/>
+ <enum name="GL_FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT"/>
+ <enum name="GL_FRAMEBUFFER_INCOMPLETE_DRAW_BUFFER"/>
+ <enum name="GL_FRAMEBUFFER_INCOMPLETE_READ_BUFFER"/>
+ <enum name="GL_FRAMEBUFFER_UNSUPPORTED"/>
+ <enum name="GL_MAX_COLOR_ATTACHMENTS"/>
+ <enum name="GL_COLOR_ATTACHMENT0"/>
+ <enum name="GL_COLOR_ATTACHMENT1"/>
+ <enum name="GL_COLOR_ATTACHMENT2"/>
+ <enum name="GL_COLOR_ATTACHMENT3"/>
+ <enum name="GL_COLOR_ATTACHMENT4"/>
+ <enum name="GL_COLOR_ATTACHMENT5"/>
+ <enum name="GL_COLOR_ATTACHMENT6"/>
+ <enum name="GL_COLOR_ATTACHMENT7"/>
+ <enum name="GL_COLOR_ATTACHMENT8"/>
+ <enum name="GL_COLOR_ATTACHMENT9"/>
+ <enum name="GL_COLOR_ATTACHMENT10"/>
+ <enum name="GL_COLOR_ATTACHMENT11"/>
+ <enum name="GL_COLOR_ATTACHMENT12"/>
+ <enum name="GL_COLOR_ATTACHMENT13"/>
+ <enum name="GL_COLOR_ATTACHMENT14"/>
+ <enum name="GL_COLOR_ATTACHMENT15"/>
+ <enum name="GL_DEPTH_ATTACHMENT"/>
+ <enum name="GL_STENCIL_ATTACHMENT"/>
+ <enum name="GL_FRAMEBUFFER"/>
+ <enum name="GL_RENDERBUFFER"/>
+ <enum name="GL_RENDERBUFFER_WIDTH"/>
+ <enum name="GL_RENDERBUFFER_HEIGHT"/>
+ <enum name="GL_RENDERBUFFER_INTERNAL_FORMAT"/>
+ <enum name="GL_STENCIL_INDEX1"/>
+ <enum name="GL_STENCIL_INDEX4"/>
+ <enum name="GL_STENCIL_INDEX8"/>
+ <enum name="GL_STENCIL_INDEX16"/>
+ <enum name="GL_RENDERBUFFER_RED_SIZE"/>
+ <enum name="GL_RENDERBUFFER_GREEN_SIZE"/>
+ <enum name="GL_RENDERBUFFER_BLUE_SIZE"/>
+ <enum name="GL_RENDERBUFFER_ALPHA_SIZE"/>
+ <enum name="GL_RENDERBUFFER_DEPTH_SIZE"/>
+ <enum name="GL_RENDERBUFFER_STENCIL_SIZE"/>
+ <enum name="GL_FRAMEBUFFER_INCOMPLETE_MULTISAMPLE"/>
+ <enum name="GL_MAX_SAMPLES"/>
+ <command name="glIsRenderbuffer"/>
+ <command name="glBindRenderbuffer"/>
+ <command name="glDeleteRenderbuffers"/>
+ <command name="glGenRenderbuffers"/>
+ <command name="glRenderbufferStorage"/>
+ <command name="glGetRenderbufferParameteriv"/>
+ <command name="glIsFramebuffer"/>
+ <command name="glBindFramebuffer"/>
+ <command name="glDeleteFramebuffers"/>
+ <command name="glGenFramebuffers"/>
+ <command name="glCheckFramebufferStatus"/>
+ <command name="glFramebufferTexture1D"/>
+ <command name="glFramebufferTexture2D"/>
+ <command name="glFramebufferTexture3D"/>
+ <command name="glFramebufferRenderbuffer"/>
+ <command name="glGetFramebufferAttachmentParameteriv"/>
+ <command name="glGenerateMipmap"/>
+ <command name="glBlitFramebuffer"/>
+ <command name="glRenderbufferStorageMultisample"/>
+ <command name="glFramebufferTextureLayer"/>
+ </require>
+ <require profile="compatibility" comment="Reuse ARB_framebuffer_object compatibility profile">
+ <enum name="GL_INDEX"/>
+ <enum name="GL_TEXTURE_LUMINANCE_TYPE"/>
+ <enum name="GL_TEXTURE_INTENSITY_TYPE"/>
+ </require>
+ <require comment="Reuse ARB_framebuffer_sRGB">
+ <enum name="GL_FRAMEBUFFER_SRGB"/>
+ </require>
+ <require comment="Reuse ARB_half_float_vertex">
+ <type name="GLhalf"/>
+ <enum name="GL_HALF_FLOAT"/>
+ </require>
+ <require comment="Reuse ARB_map_buffer_range">
+ <enum name="GL_MAP_READ_BIT"/>
+ <enum name="GL_MAP_WRITE_BIT"/>
+ <enum name="GL_MAP_INVALIDATE_RANGE_BIT"/>
+ <enum name="GL_MAP_INVALIDATE_BUFFER_BIT"/>
+ <enum name="GL_MAP_FLUSH_EXPLICIT_BIT"/>
+ <enum name="GL_MAP_UNSYNCHRONIZED_BIT"/>
+ <command name="glMapBufferRange"/>
+ <command name="glFlushMappedBufferRange"/>
+ </require>
+ <require comment="Reuse ARB_texture_compression_rgtc">
+ <enum name="GL_COMPRESSED_RED_RGTC1"/>
+ <enum name="GL_COMPRESSED_SIGNED_RED_RGTC1"/>
+ <enum name="GL_COMPRESSED_RG_RGTC2"/>
+ <enum name="GL_COMPRESSED_SIGNED_RG_RGTC2"/>
+ </require>
+ <require comment="Reuse ARB_texture_rg">
+ <enum name="GL_RG"/>
+ <enum name="GL_RG_INTEGER"/>
+ <enum name="GL_R8"/>
+ <enum name="GL_R16"/>
+ <enum name="GL_RG8"/>
+ <enum name="GL_RG16"/>
+ <enum name="GL_R16F"/>
+ <enum name="GL_R32F"/>
+ <enum name="GL_RG16F"/>
+ <enum name="GL_RG32F"/>
+ <enum name="GL_R8I"/>
+ <enum name="GL_R8UI"/>
+ <enum name="GL_R16I"/>
+ <enum name="GL_R16UI"/>
+ <enum name="GL_R32I"/>
+ <enum name="GL_R32UI"/>
+ <enum name="GL_RG8I"/>
+ <enum name="GL_RG8UI"/>
+ <enum name="GL_RG16I"/>
+ <enum name="GL_RG16UI"/>
+ <enum name="GL_RG32I"/>
+ <enum name="GL_RG32UI"/>
+ </require>
+ <require comment="Reuse ARB_vertex_array_object">
+ <enum name="GL_VERTEX_ARRAY_BINDING"/>
+ <enum name="GL_CLAMP_VERTEX_COLOR"/>
+ <enum name="GL_CLAMP_FRAGMENT_COLOR"/>
+ <enum name="GL_ALPHA_INTEGER"/>
+ <command name="glBindVertexArray"/>
+ <command name="glDeleteVertexArrays"/>
+ <command name="glGenVertexArrays"/>
+ <command name="glIsVertexArray"/>
+ </require>
+ </feature>
+ <feature api="gl" name="GL_VERSION_3_1" number="3.1">
+ <require>
+ <enum name="GL_SAMPLER_2D_RECT"/>
+ <enum name="GL_SAMPLER_2D_RECT_SHADOW"/>
+ <enum name="GL_SAMPLER_BUFFER"/>
+ <enum name="GL_INT_SAMPLER_2D_RECT"/>
+ <enum name="GL_INT_SAMPLER_BUFFER"/>
+ <enum name="GL_UNSIGNED_INT_SAMPLER_2D_RECT"/>
+ <enum name="GL_UNSIGNED_INT_SAMPLER_BUFFER"/>
+ <enum name="GL_TEXTURE_BUFFER"/>
+ <enum name="GL_MAX_TEXTURE_BUFFER_SIZE"/>
+ <enum name="GL_TEXTURE_BINDING_BUFFER"/>
+ <enum name="GL_TEXTURE_BUFFER_DATA_STORE_BINDING"/>
+ <enum name="GL_TEXTURE_RECTANGLE"/>
+ <enum name="GL_TEXTURE_BINDING_RECTANGLE"/>
+ <enum name="GL_PROXY_TEXTURE_RECTANGLE"/>
+ <enum name="GL_MAX_RECTANGLE_TEXTURE_SIZE"/>
+ <enum name="GL_R8_SNORM"/>
+ <enum name="GL_RG8_SNORM"/>
+ <enum name="GL_RGB8_SNORM"/>
+ <enum name="GL_RGBA8_SNORM"/>
+ <enum name="GL_R16_SNORM"/>
+ <enum name="GL_RG16_SNORM"/>
+ <enum name="GL_RGB16_SNORM"/>
+ <enum name="GL_RGBA16_SNORM"/>
+ <enum name="GL_SIGNED_NORMALIZED"/>
+ <enum name="GL_PRIMITIVE_RESTART"/>
+ <enum name="GL_PRIMITIVE_RESTART_INDEX"/>
+ <command name="glDrawArraysInstanced"/>
+ <command name="glDrawElementsInstanced"/>
+ <command name="glTexBuffer"/>
+ <command name="glPrimitiveRestartIndex"/>
+ </require>
+ <require comment="Reuse ARB_copy_buffer">
+ <enum name="GL_COPY_READ_BUFFER"/>
+ <enum name="GL_COPY_WRITE_BUFFER"/>
+ <command name="glCopyBufferSubData"/>
+ </require>
+ <require comment="Reuse ARB_uniform_buffer_object">
+ <enum name="GL_UNIFORM_BUFFER"/>
+ <enum name="GL_UNIFORM_BUFFER_BINDING"/>
+ <enum name="GL_UNIFORM_BUFFER_START"/>
+ <enum name="GL_UNIFORM_BUFFER_SIZE"/>
+ <enum name="GL_MAX_VERTEX_UNIFORM_BLOCKS"/>
+ <enum name="GL_MAX_GEOMETRY_UNIFORM_BLOCKS"/>
+ <enum name="GL_MAX_FRAGMENT_UNIFORM_BLOCKS"/>
+ <enum name="GL_MAX_COMBINED_UNIFORM_BLOCKS"/>
+ <enum name="GL_MAX_UNIFORM_BUFFER_BINDINGS"/>
+ <enum name="GL_MAX_UNIFORM_BLOCK_SIZE"/>
+ <enum name="GL_MAX_COMBINED_VERTEX_UNIFORM_COMPONENTS"/>
+ <enum name="GL_MAX_COMBINED_GEOMETRY_UNIFORM_COMPONENTS"/>
+ <enum name="GL_MAX_COMBINED_FRAGMENT_UNIFORM_COMPONENTS"/>
+ <enum name="GL_UNIFORM_BUFFER_OFFSET_ALIGNMENT"/>
+ <enum name="GL_ACTIVE_UNIFORM_BLOCK_MAX_NAME_LENGTH"/>
+ <enum name="GL_ACTIVE_UNIFORM_BLOCKS"/>
+ <enum name="GL_UNIFORM_TYPE"/>
+ <enum name="GL_UNIFORM_SIZE"/>
+ <enum name="GL_UNIFORM_NAME_LENGTH"/>
+ <enum name="GL_UNIFORM_BLOCK_INDEX"/>
+ <enum name="GL_UNIFORM_OFFSET"/>
+ <enum name="GL_UNIFORM_ARRAY_STRIDE"/>
+ <enum name="GL_UNIFORM_MATRIX_STRIDE"/>
+ <enum name="GL_UNIFORM_IS_ROW_MAJOR"/>
+ <enum name="GL_UNIFORM_BLOCK_BINDING"/>
+ <enum name="GL_UNIFORM_BLOCK_DATA_SIZE"/>
+ <enum name="GL_UNIFORM_BLOCK_NAME_LENGTH"/>
+ <enum name="GL_UNIFORM_BLOCK_ACTIVE_UNIFORMS"/>
+ <enum name="GL_UNIFORM_BLOCK_ACTIVE_UNIFORM_INDICES"/>
+ <enum name="GL_UNIFORM_BLOCK_REFERENCED_BY_VERTEX_SHADER"/>
+ <enum name="GL_UNIFORM_BLOCK_REFERENCED_BY_GEOMETRY_SHADER"/>
+ <enum name="GL_UNIFORM_BLOCK_REFERENCED_BY_FRAGMENT_SHADER"/>
+ <enum name="GL_INVALID_INDEX"/>
+ <command name="glGetUniformIndices"/>
+ <command name="glGetActiveUniformsiv"/>
+ <command name="glGetActiveUniformName"/>
+ <command name="glGetUniformBlockIndex"/>
+ <command name="glGetActiveUniformBlockiv"/>
+ <command name="glGetActiveUniformBlockName"/>
+ <command name="glUniformBlockBinding"/>
+ </require>
+ </feature>
+ <feature api="gl" name="GL_VERSION_3_2" number="3.2">
+ <require>
+ <enum name="GL_CONTEXT_CORE_PROFILE_BIT"/>
+ <enum name="GL_CONTEXT_COMPATIBILITY_PROFILE_BIT"/>
+ <enum name="GL_LINES_ADJACENCY"/>
+ <enum name="GL_LINE_STRIP_ADJACENCY"/>
+ <enum name="GL_TRIANGLES_ADJACENCY"/>
+ <enum name="GL_TRIANGLE_STRIP_ADJACENCY"/>
+ <enum name="GL_PROGRAM_POINT_SIZE"/>
+ <enum name="GL_MAX_GEOMETRY_TEXTURE_IMAGE_UNITS"/>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_LAYERED"/>
+ <enum name="GL_FRAMEBUFFER_INCOMPLETE_LAYER_TARGETS"/>
+ <enum name="GL_GEOMETRY_SHADER"/>
+ <enum name="GL_GEOMETRY_VERTICES_OUT"/>
+ <enum name="GL_GEOMETRY_INPUT_TYPE"/>
+ <enum name="GL_GEOMETRY_OUTPUT_TYPE"/>
+ <enum name="GL_MAX_GEOMETRY_UNIFORM_COMPONENTS"/>
+ <enum name="GL_MAX_GEOMETRY_OUTPUT_VERTICES"/>
+ <enum name="GL_MAX_GEOMETRY_TOTAL_OUTPUT_COMPONENTS"/>
+ <enum name="GL_MAX_VERTEX_OUTPUT_COMPONENTS"/>
+ <enum name="GL_MAX_GEOMETRY_INPUT_COMPONENTS"/>
+ <enum name="GL_MAX_GEOMETRY_OUTPUT_COMPONENTS"/>
+ <enum name="GL_MAX_FRAGMENT_INPUT_COMPONENTS"/>
+ <enum name="GL_CONTEXT_PROFILE_MASK"/>
+ </require>
+ <require comment="Reuse ARB_depth_clamp">
+ <enum name="GL_DEPTH_CLAMP"/>
+ </require>
+ <require comment="Reuse ARB_draw_elements_base_vertex">
+ <command name="glDrawElementsBaseVertex"/>
+ <command name="glDrawRangeElementsBaseVertex"/>
+ <command name="glDrawElementsInstancedBaseVertex"/>
+ <command name="glMultiDrawElementsBaseVertex"/>
+ </require>
+ <require comment="Reuse ARB_fragment_coord_conventions (none)">
+ </require>
+ <require comment="Reuse ARB_provoking_vertex">
+ <enum name="GL_QUADS_FOLLOW_PROVOKING_VERTEX_CONVENTION"/>
+ <enum name="GL_FIRST_VERTEX_CONVENTION"/>
+ <enum name="GL_LAST_VERTEX_CONVENTION"/>
+ <enum name="GL_PROVOKING_VERTEX"/>
+ <command name="glProvokingVertex"/>
+ </require>
+ <require comment="Reuse ARB_seamless_cube_map">
+ <enum name="GL_TEXTURE_CUBE_MAP_SEAMLESS"/>
+ </require>
+ <require comment="Reuse ARB_sync">
+ <enum name="GL_MAX_SERVER_WAIT_TIMEOUT"/>
+ <enum name="GL_OBJECT_TYPE"/>
+ <enum name="GL_SYNC_CONDITION"/>
+ <enum name="GL_SYNC_STATUS"/>
+ <enum name="GL_SYNC_FLAGS"/>
+ <enum name="GL_SYNC_FENCE"/>
+ <enum name="GL_SYNC_GPU_COMMANDS_COMPLETE"/>
+ <enum name="GL_UNSIGNALED"/>
+ <enum name="GL_SIGNALED"/>
+ <enum name="GL_ALREADY_SIGNALED"/>
+ <enum name="GL_TIMEOUT_EXPIRED"/>
+ <enum name="GL_CONDITION_SATISFIED"/>
+ <enum name="GL_WAIT_FAILED"/>
+ <enum name="GL_TIMEOUT_IGNORED"/>
+ <enum name="GL_SYNC_FLUSH_COMMANDS_BIT"/>
+ <command name="glFenceSync"/>
+ <command name="glIsSync"/>
+ <command name="glDeleteSync"/>
+ <command name="glClientWaitSync"/>
+ <command name="glWaitSync"/>
+ <command name="glGetInteger64v"/>
+ <command name="glGetSynciv"/>
+ </require>
+ <require comment="Reuse ARB_texture_multisample">
+ <enum name="GL_SAMPLE_POSITION"/>
+ <enum name="GL_SAMPLE_MASK"/>
+ <enum name="GL_SAMPLE_MASK_VALUE"/>
+ <enum name="GL_MAX_SAMPLE_MASK_WORDS"/>
+ <enum name="GL_TEXTURE_2D_MULTISAMPLE"/>
+ <enum name="GL_PROXY_TEXTURE_2D_MULTISAMPLE"/>
+ <enum name="GL_TEXTURE_2D_MULTISAMPLE_ARRAY"/>
+ <enum name="GL_PROXY_TEXTURE_2D_MULTISAMPLE_ARRAY"/>
+ <enum name="GL_TEXTURE_BINDING_2D_MULTISAMPLE"/>
+ <enum name="GL_TEXTURE_BINDING_2D_MULTISAMPLE_ARRAY"/>
+ <enum name="GL_TEXTURE_SAMPLES"/>
+ <enum name="GL_TEXTURE_FIXED_SAMPLE_LOCATIONS"/>
+ <enum name="GL_SAMPLER_2D_MULTISAMPLE"/>
+ <enum name="GL_INT_SAMPLER_2D_MULTISAMPLE"/>
+ <enum name="GL_UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE"/>
+ <enum name="GL_SAMPLER_2D_MULTISAMPLE_ARRAY"/>
+ <enum name="GL_INT_SAMPLER_2D_MULTISAMPLE_ARRAY"/>
+ <enum name="GL_UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE_ARRAY"/>
+ <enum name="GL_MAX_COLOR_TEXTURE_SAMPLES"/>
+ <enum name="GL_MAX_DEPTH_TEXTURE_SAMPLES"/>
+ <enum name="GL_MAX_INTEGER_SAMPLES"/>
+ <!-- /* Don't need to reuse tokens from ARB_vertex_array_bgra since they're already in 1.2 core */ -->
+ <command name="glGetInteger64i_v"/>
+ <command name="glGetBufferParameteri64v"/>
+ <command name="glFramebufferTexture"/>
+ <command name="glTexImage2DMultisample"/>
+ <command name="glTexImage3DMultisample"/>
+ <command name="glGetMultisamplefv"/>
+ <command name="glSampleMaski"/>
+ </require>
+ <!-- OpenGL 3.2 is where core and compatibility profiles were first
+ introduced, so many, many things were removed from the core
+ profile in this version. A few were reintroduced later (e.g.
+ GetPointerv / STACK_{UNDER,OVER}FLOW by OpenGL 4.3 for debug
+ functionality). -->
+ <remove profile="core" comment="Compatibility-only GL 1.0 features removed from GL 3.2">
+ <command name="glNewList"/>
+ <command name="glEndList"/>
+ <command name="glCallList"/>
+ <command name="glCallLists"/>
+ <command name="glDeleteLists"/>
+ <command name="glGenLists"/>
+ <command name="glListBase"/>
+ <command name="glBegin"/>
+ <command name="glBitmap"/>
+ <command name="glColor3b"/>
+ <command name="glColor3bv"/>
+ <command name="glColor3d"/>
+ <command name="glColor3dv"/>
+ <command name="glColor3f"/>
+ <command name="glColor3fv"/>
+ <command name="glColor3i"/>
+ <command name="glColor3iv"/>
+ <command name="glColor3s"/>
+ <command name="glColor3sv"/>
+ <command name="glColor3ub"/>
+ <command name="glColor3ubv"/>
+ <command name="glColor3ui"/>
+ <command name="glColor3uiv"/>
+ <command name="glColor3us"/>
+ <command name="glColor3usv"/>
+ <command name="glColor4b"/>
+ <command name="glColor4bv"/>
+ <command name="glColor4d"/>
+ <command name="glColor4dv"/>
+ <command name="glColor4f"/>
+ <command name="glColor4fv"/>
+ <command name="glColor4i"/>
+ <command name="glColor4iv"/>
+ <command name="glColor4s"/>
+ <command name="glColor4sv"/>
+ <command name="glColor4ub"/>
+ <command name="glColor4ubv"/>
+ <command name="glColor4ui"/>
+ <command name="glColor4uiv"/>
+ <command name="glColor4us"/>
+ <command name="glColor4usv"/>
+ <command name="glEdgeFlag"/>
+ <command name="glEdgeFlagv"/>
+ <command name="glEnd"/>
+ <command name="glIndexd"/>
+ <command name="glIndexdv"/>
+ <command name="glIndexf"/>
+ <command name="glIndexfv"/>
+ <command name="glIndexi"/>
+ <command name="glIndexiv"/>
+ <command name="glIndexs"/>
+ <command name="glIndexsv"/>
+ <command name="glNormal3b"/>
+ <command name="glNormal3bv"/>
+ <command name="glNormal3d"/>
+ <command name="glNormal3dv"/>
+ <command name="glNormal3f"/>
+ <command name="glNormal3fv"/>
+ <command name="glNormal3i"/>
+ <command name="glNormal3iv"/>
+ <command name="glNormal3s"/>
+ <command name="glNormal3sv"/>
+ <command name="glRasterPos2d"/>
+ <command name="glRasterPos2dv"/>
+ <command name="glRasterPos2f"/>
+ <command name="glRasterPos2fv"/>
+ <command name="glRasterPos2i"/>
+ <command name="glRasterPos2iv"/>
+ <command name="glRasterPos2s"/>
+ <command name="glRasterPos2sv"/>
+ <command name="glRasterPos3d"/>
+ <command name="glRasterPos3dv"/>
+ <command name="glRasterPos3f"/>
+ <command name="glRasterPos3fv"/>
+ <command name="glRasterPos3i"/>
+ <command name="glRasterPos3iv"/>
+ <command name="glRasterPos3s"/>
+ <command name="glRasterPos3sv"/>
+ <command name="glRasterPos4d"/>
+ <command name="glRasterPos4dv"/>
+ <command name="glRasterPos4f"/>
+ <command name="glRasterPos4fv"/>
+ <command name="glRasterPos4i"/>
+ <command name="glRasterPos4iv"/>
+ <command name="glRasterPos4s"/>
+ <command name="glRasterPos4sv"/>
+ <command name="glRectd"/>
+ <command name="glRectdv"/>
+ <command name="glRectf"/>
+ <command name="glRectfv"/>
+ <command name="glRecti"/>
+ <command name="glRectiv"/>
+ <command name="glRects"/>
+ <command name="glRectsv"/>
+ <command name="glTexCoord1d"/>
+ <command name="glTexCoord1dv"/>
+ <command name="glTexCoord1f"/>
+ <command name="glTexCoord1fv"/>
+ <command name="glTexCoord1i"/>
+ <command name="glTexCoord1iv"/>
+ <command name="glTexCoord1s"/>
+ <command name="glTexCoord1sv"/>
+ <command name="glTexCoord2d"/>
+ <command name="glTexCoord2dv"/>
+ <command name="glTexCoord2f"/>
+ <command name="glTexCoord2fv"/>
+ <command name="glTexCoord2i"/>
+ <command name="glTexCoord2iv"/>
+ <command name="glTexCoord2s"/>
+ <command name="glTexCoord2sv"/>
+ <command name="glTexCoord3d"/>
+ <command name="glTexCoord3dv"/>
+ <command name="glTexCoord3f"/>
+ <command name="glTexCoord3fv"/>
+ <command name="glTexCoord3i"/>
+ <command name="glTexCoord3iv"/>
+ <command name="glTexCoord3s"/>
+ <command name="glTexCoord3sv"/>
+ <command name="glTexCoord4d"/>
+ <command name="glTexCoord4dv"/>
+ <command name="glTexCoord4f"/>
+ <command name="glTexCoord4fv"/>
+ <command name="glTexCoord4i"/>
+ <command name="glTexCoord4iv"/>
+ <command name="glTexCoord4s"/>
+ <command name="glTexCoord4sv"/>
+ <command name="glVertex2d"/>
+ <command name="glVertex2dv"/>
+ <command name="glVertex2f"/>
+ <command name="glVertex2fv"/>
+ <command name="glVertex2i"/>
+ <command name="glVertex2iv"/>
+ <command name="glVertex2s"/>
+ <command name="glVertex2sv"/>
+ <command name="glVertex3d"/>
+ <command name="glVertex3dv"/>
+ <command name="glVertex3f"/>
+ <command name="glVertex3fv"/>
+ <command name="glVertex3i"/>
+ <command name="glVertex3iv"/>
+ <command name="glVertex3s"/>
+ <command name="glVertex3sv"/>
+ <command name="glVertex4d"/>
+ <command name="glVertex4dv"/>
+ <command name="glVertex4f"/>
+ <command name="glVertex4fv"/>
+ <command name="glVertex4i"/>
+ <command name="glVertex4iv"/>
+ <command name="glVertex4s"/>
+ <command name="glVertex4sv"/>
+ <command name="glClipPlane"/>
+ <command name="glColorMaterial"/>
+ <command name="glFogf"/>
+ <command name="glFogfv"/>
+ <command name="glFogi"/>
+ <command name="glFogiv"/>
+ <command name="glLightf"/>
+ <command name="glLightfv"/>
+ <command name="glLighti"/>
+ <command name="glLightiv"/>
+ <command name="glLightModelf"/>
+ <command name="glLightModelfv"/>
+ <command name="glLightModeli"/>
+ <command name="glLightModeliv"/>
+ <command name="glLineStipple"/>
+ <command name="glMaterialf"/>
+ <command name="glMaterialfv"/>
+ <command name="glMateriali"/>
+ <command name="glMaterialiv"/>
+ <command name="glPolygonStipple"/>
+ <command name="glShadeModel"/>
+ <command name="glTexEnvf"/>
+ <command name="glTexEnvfv"/>
+ <command name="glTexEnvi"/>
+ <command name="glTexEnviv"/>
+ <command name="glTexGend"/>
+ <command name="glTexGendv"/>
+ <command name="glTexGenf"/>
+ <command name="glTexGenfv"/>
+ <command name="glTexGeni"/>
+ <command name="glTexGeniv"/>
+ <command name="glFeedbackBuffer"/>
+ <command name="glSelectBuffer"/>
+ <command name="glRenderMode"/>
+ <command name="glInitNames"/>
+ <command name="glLoadName"/>
+ <command name="glPassThrough"/>
+ <command name="glPopName"/>
+ <command name="glPushName"/>
+ <command name="glClearAccum"/>
+ <command name="glClearIndex"/>
+ <command name="glIndexMask"/>
+ <command name="glAccum"/>
+ <command name="glPopAttrib"/>
+ <command name="glPushAttrib"/>
+ <command name="glMap1d"/>
+ <command name="glMap1f"/>
+ <command name="glMap2d"/>
+ <command name="glMap2f"/>
+ <command name="glMapGrid1d"/>
+ <command name="glMapGrid1f"/>
+ <command name="glMapGrid2d"/>
+ <command name="glMapGrid2f"/>
+ <command name="glEvalCoord1d"/>
+ <command name="glEvalCoord1dv"/>
+ <command name="glEvalCoord1f"/>
+ <command name="glEvalCoord1fv"/>
+ <command name="glEvalCoord2d"/>
+ <command name="glEvalCoord2dv"/>
+ <command name="glEvalCoord2f"/>
+ <command name="glEvalCoord2fv"/>
+ <command name="glEvalMesh1"/>
+ <command name="glEvalPoint1"/>
+ <command name="glEvalMesh2"/>
+ <command name="glEvalPoint2"/>
+ <command name="glAlphaFunc"/>
+ <command name="glPixelZoom"/>
+ <command name="glPixelTransferf"/>
+ <command name="glPixelTransferi"/>
+ <command name="glPixelMapfv"/>
+ <command name="glPixelMapuiv"/>
+ <command name="glPixelMapusv"/>
+ <command name="glCopyPixels"/>
+ <command name="glDrawPixels"/>
+ <command name="glGetClipPlane"/>
+ <command name="glGetLightfv"/>
+ <command name="glGetLightiv"/>
+ <command name="glGetMapdv"/>
+ <command name="glGetMapfv"/>
+ <command name="glGetMapiv"/>
+ <command name="glGetMaterialfv"/>
+ <command name="glGetMaterialiv"/>
+ <command name="glGetPixelMapfv"/>
+ <command name="glGetPixelMapuiv"/>
+ <command name="glGetPixelMapusv"/>
+ <command name="glGetPolygonStipple"/>
+ <command name="glGetTexEnvfv"/>
+ <command name="glGetTexEnviv"/>
+ <command name="glGetTexGendv"/>
+ <command name="glGetTexGenfv"/>
+ <command name="glGetTexGeniv"/>
+ <command name="glIsList"/>
+ <command name="glFrustum"/>
+ <command name="glLoadIdentity"/>
+ <command name="glLoadMatrixf"/>
+ <command name="glLoadMatrixd"/>
+ <command name="glMatrixMode"/>
+ <command name="glMultMatrixf"/>
+ <command name="glMultMatrixd"/>
+ <command name="glOrtho"/>
+ <command name="glPopMatrix"/>
+ <command name="glPushMatrix"/>
+ <command name="glRotated"/>
+ <command name="glRotatef"/>
+ <command name="glScaled"/>
+ <command name="glScalef"/>
+ <command name="glTranslated"/>
+ <command name="glTranslatef"/>
+ </remove>
+ <remove profile="core" comment="Compatibility-only GL 1.1 features removed from GL 3.2">
+ <enum name="GL_CURRENT_BIT"/>
+ <enum name="GL_POINT_BIT"/>
+ <enum name="GL_LINE_BIT"/>
+ <enum name="GL_POLYGON_BIT"/>
+ <enum name="GL_POLYGON_STIPPLE_BIT"/>
+ <enum name="GL_PIXEL_MODE_BIT"/>
+ <enum name="GL_LIGHTING_BIT"/>
+ <enum name="GL_FOG_BIT"/>
+ <enum name="GL_ACCUM_BUFFER_BIT"/>
+ <enum name="GL_VIEWPORT_BIT"/>
+ <enum name="GL_TRANSFORM_BIT"/>
+ <enum name="GL_ENABLE_BIT"/>
+ <enum name="GL_HINT_BIT"/>
+ <enum name="GL_EVAL_BIT"/>
+ <enum name="GL_LIST_BIT"/>
+ <enum name="GL_TEXTURE_BIT"/>
+ <enum name="GL_SCISSOR_BIT"/>
+ <enum name="GL_ALL_ATTRIB_BITS"/>
+ <enum name="GL_CLIENT_PIXEL_STORE_BIT"/>
+ <enum name="GL_CLIENT_VERTEX_ARRAY_BIT"/>
+ <enum name="GL_CLIENT_ALL_ATTRIB_BITS"/>
+ <enum name="GL_QUAD_STRIP"/>
+ <enum name="GL_QUADS"/>
+ <enum name="GL_POLYGON"/>
+ <enum name="GL_ACCUM"/>
+ <enum name="GL_LOAD"/>
+ <enum name="GL_RETURN"/>
+ <enum name="GL_MULT"/>
+ <enum name="GL_ADD"/>
+ <enum name="GL_STACK_OVERFLOW"/>
+ <enum name="GL_STACK_UNDERFLOW"/>
+ <enum name="GL_AUX0"/>
+ <enum name="GL_AUX1"/>
+ <enum name="GL_AUX2"/>
+ <enum name="GL_AUX3"/>
+ <enum name="GL_2D"/>
+ <enum name="GL_3D"/>
+ <enum name="GL_3D_COLOR"/>
+ <enum name="GL_3D_COLOR_TEXTURE"/>
+ <enum name="GL_4D_COLOR_TEXTURE"/>
+ <enum name="GL_PASS_THROUGH_TOKEN"/>
+ <enum name="GL_POINT_TOKEN"/>
+ <enum name="GL_LINE_TOKEN"/>
+ <enum name="GL_POLYGON_TOKEN"/>
+ <enum name="GL_BITMAP_TOKEN"/>
+ <enum name="GL_DRAW_PIXEL_TOKEN"/>
+ <enum name="GL_COPY_PIXEL_TOKEN"/>
+ <enum name="GL_LINE_RESET_TOKEN"/>
+ <enum name="GL_EXP"/>
+ <enum name="GL_EXP2"/>
+ <enum name="GL_COEFF"/>
+ <enum name="GL_ORDER"/>
+ <enum name="GL_DOMAIN"/>
+ <enum name="GL_PIXEL_MAP_I_TO_I"/>
+ <enum name="GL_PIXEL_MAP_S_TO_S"/>
+ <enum name="GL_PIXEL_MAP_I_TO_R"/>
+ <enum name="GL_PIXEL_MAP_I_TO_G"/>
+ <enum name="GL_PIXEL_MAP_I_TO_B"/>
+ <enum name="GL_PIXEL_MAP_I_TO_A"/>
+ <enum name="GL_PIXEL_MAP_R_TO_R"/>
+ <enum name="GL_PIXEL_MAP_G_TO_G"/>
+ <enum name="GL_PIXEL_MAP_B_TO_B"/>
+ <enum name="GL_PIXEL_MAP_A_TO_A"/>
+ <enum name="GL_VERTEX_ARRAY_POINTER"/>
+ <enum name="GL_NORMAL_ARRAY_POINTER"/>
+ <enum name="GL_COLOR_ARRAY_POINTER"/>
+ <enum name="GL_INDEX_ARRAY_POINTER"/>
+ <enum name="GL_TEXTURE_COORD_ARRAY_POINTER"/>
+ <enum name="GL_EDGE_FLAG_ARRAY_POINTER"/>
+ <enum name="GL_FEEDBACK_BUFFER_POINTER"/>
+ <enum name="GL_SELECTION_BUFFER_POINTER"/>
+ <enum name="GL_CURRENT_COLOR"/>
+ <enum name="GL_CURRENT_INDEX"/>
+ <enum name="GL_CURRENT_NORMAL"/>
+ <enum name="GL_CURRENT_TEXTURE_COORDS"/>
+ <enum name="GL_CURRENT_RASTER_COLOR"/>
+ <enum name="GL_CURRENT_RASTER_INDEX"/>
+ <enum name="GL_CURRENT_RASTER_TEXTURE_COORDS"/>
+ <enum name="GL_CURRENT_RASTER_POSITION"/>
+ <enum name="GL_CURRENT_RASTER_POSITION_VALID"/>
+ <enum name="GL_CURRENT_RASTER_DISTANCE"/>
+ <enum name="GL_POINT_SMOOTH"/>
+ <enum name="GL_LINE_STIPPLE"/>
+ <enum name="GL_LINE_STIPPLE_PATTERN"/>
+ <enum name="GL_LINE_STIPPLE_REPEAT"/>
+ <enum name="GL_LIST_MODE"/>
+ <enum name="GL_MAX_LIST_NESTING"/>
+ <enum name="GL_LIST_BASE"/>
+ <enum name="GL_LIST_INDEX"/>
+ <enum name="GL_POLYGON_STIPPLE"/>
+ <enum name="GL_EDGE_FLAG"/>
+ <enum name="GL_LIGHTING"/>
+ <enum name="GL_LIGHT_MODEL_LOCAL_VIEWER"/>
+ <enum name="GL_LIGHT_MODEL_TWO_SIDE"/>
+ <enum name="GL_LIGHT_MODEL_AMBIENT"/>
+ <enum name="GL_SHADE_MODEL"/>
+ <enum name="GL_COLOR_MATERIAL_FACE"/>
+ <enum name="GL_COLOR_MATERIAL_PARAMETER"/>
+ <enum name="GL_COLOR_MATERIAL"/>
+ <enum name="GL_FOG"/>
+ <enum name="GL_FOG_INDEX"/>
+ <enum name="GL_FOG_DENSITY"/>
+ <enum name="GL_FOG_START"/>
+ <enum name="GL_FOG_END"/>
+ <enum name="GL_FOG_MODE"/>
+ <enum name="GL_FOG_COLOR"/>
+ <enum name="GL_ACCUM_CLEAR_VALUE"/>
+ <enum name="GL_MATRIX_MODE"/>
+ <enum name="GL_NORMALIZE"/>
+ <enum name="GL_MODELVIEW_STACK_DEPTH"/>
+ <enum name="GL_PROJECTION_STACK_DEPTH"/>
+ <enum name="GL_TEXTURE_STACK_DEPTH"/>
+ <enum name="GL_MODELVIEW_MATRIX"/>
+ <enum name="GL_PROJECTION_MATRIX"/>
+ <enum name="GL_TEXTURE_MATRIX"/>
+ <enum name="GL_ATTRIB_STACK_DEPTH"/>
+ <enum name="GL_CLIENT_ATTRIB_STACK_DEPTH"/>
+ <enum name="GL_ALPHA_TEST"/>
+ <enum name="GL_ALPHA_TEST_FUNC"/>
+ <enum name="GL_ALPHA_TEST_REF"/>
+ <enum name="GL_INDEX_LOGIC_OP"/>
+ <enum name="GL_LOGIC_OP"/>
+ <enum name="GL_AUX_BUFFERS"/>
+ <enum name="GL_INDEX_CLEAR_VALUE"/>
+ <enum name="GL_INDEX_WRITEMASK"/>
+ <enum name="GL_INDEX_MODE"/>
+ <enum name="GL_RGBA_MODE"/>
+ <enum name="GL_RENDER_MODE"/>
+ <enum name="GL_PERSPECTIVE_CORRECTION_HINT"/>
+ <enum name="GL_POINT_SMOOTH_HINT"/>
+ <enum name="GL_FOG_HINT"/>
+ <enum name="GL_TEXTURE_GEN_S"/>
+ <enum name="GL_TEXTURE_GEN_T"/>
+ <enum name="GL_TEXTURE_GEN_R"/>
+ <enum name="GL_TEXTURE_GEN_Q"/>
+ <enum name="GL_PIXEL_MAP_I_TO_I_SIZE"/>
+ <enum name="GL_PIXEL_MAP_S_TO_S_SIZE"/>
+ <enum name="GL_PIXEL_MAP_I_TO_R_SIZE"/>
+ <enum name="GL_PIXEL_MAP_I_TO_G_SIZE"/>
+ <enum name="GL_PIXEL_MAP_I_TO_B_SIZE"/>
+ <enum name="GL_PIXEL_MAP_I_TO_A_SIZE"/>
+ <enum name="GL_PIXEL_MAP_R_TO_R_SIZE"/>
+ <enum name="GL_PIXEL_MAP_G_TO_G_SIZE"/>
+ <enum name="GL_PIXEL_MAP_B_TO_B_SIZE"/>
+ <enum name="GL_PIXEL_MAP_A_TO_A_SIZE"/>
+ <enum name="GL_MAP_COLOR"/>
+ <enum name="GL_MAP_STENCIL"/>
+ <enum name="GL_INDEX_SHIFT"/>
+ <enum name="GL_INDEX_OFFSET"/>
+ <enum name="GL_RED_SCALE"/>
+ <enum name="GL_RED_BIAS"/>
+ <enum name="GL_ZOOM_X"/>
+ <enum name="GL_ZOOM_Y"/>
+ <enum name="GL_GREEN_SCALE"/>
+ <enum name="GL_GREEN_BIAS"/>
+ <enum name="GL_BLUE_SCALE"/>
+ <enum name="GL_BLUE_BIAS"/>
+ <enum name="GL_ALPHA_SCALE"/>
+ <enum name="GL_ALPHA_BIAS"/>
+ <enum name="GL_DEPTH_SCALE"/>
+ <enum name="GL_DEPTH_BIAS"/>
+ <enum name="GL_MAX_EVAL_ORDER"/>
+ <enum name="GL_MAX_LIGHTS"/>
+ <enum name="GL_MAX_CLIP_PLANES"/>
+ <enum name="GL_MAX_PIXEL_MAP_TABLE"/>
+ <enum name="GL_MAX_ATTRIB_STACK_DEPTH"/>
+ <enum name="GL_MAX_MODELVIEW_STACK_DEPTH"/>
+ <enum name="GL_MAX_NAME_STACK_DEPTH"/>
+ <enum name="GL_MAX_PROJECTION_STACK_DEPTH"/>
+ <enum name="GL_MAX_TEXTURE_STACK_DEPTH"/>
+ <enum name="GL_MAX_CLIENT_ATTRIB_STACK_DEPTH"/>
+ <enum name="GL_INDEX_BITS"/>
+ <enum name="GL_RED_BITS"/>
+ <enum name="GL_GREEN_BITS"/>
+ <enum name="GL_BLUE_BITS"/>
+ <enum name="GL_ALPHA_BITS"/>
+ <enum name="GL_DEPTH_BITS"/>
+ <enum name="GL_STENCIL_BITS"/>
+ <enum name="GL_ACCUM_RED_BITS"/>
+ <enum name="GL_ACCUM_GREEN_BITS"/>
+ <enum name="GL_ACCUM_BLUE_BITS"/>
+ <enum name="GL_ACCUM_ALPHA_BITS"/>
+ <enum name="GL_NAME_STACK_DEPTH"/>
+ <enum name="GL_AUTO_NORMAL"/>
+ <enum name="GL_MAP1_COLOR_4"/>
+ <enum name="GL_MAP1_INDEX"/>
+ <enum name="GL_MAP1_NORMAL"/>
+ <enum name="GL_MAP1_TEXTURE_COORD_1"/>
+ <enum name="GL_MAP1_TEXTURE_COORD_2"/>
+ <enum name="GL_MAP1_TEXTURE_COORD_3"/>
+ <enum name="GL_MAP1_TEXTURE_COORD_4"/>
+ <enum name="GL_MAP1_VERTEX_3"/>
+ <enum name="GL_MAP1_VERTEX_4"/>
+ <enum name="GL_MAP2_COLOR_4"/>
+ <enum name="GL_MAP2_INDEX"/>
+ <enum name="GL_MAP2_NORMAL"/>
+ <enum name="GL_MAP2_TEXTURE_COORD_1"/>
+ <enum name="GL_MAP2_TEXTURE_COORD_2"/>
+ <enum name="GL_MAP2_TEXTURE_COORD_3"/>
+ <enum name="GL_MAP2_TEXTURE_COORD_4"/>
+ <enum name="GL_MAP2_VERTEX_3"/>
+ <enum name="GL_MAP2_VERTEX_4"/>
+ <enum name="GL_MAP1_GRID_DOMAIN"/>
+ <enum name="GL_MAP1_GRID_SEGMENTS"/>
+ <enum name="GL_MAP2_GRID_DOMAIN"/>
+ <enum name="GL_MAP2_GRID_SEGMENTS"/>
+ <enum name="GL_FEEDBACK_BUFFER_SIZE"/>
+ <enum name="GL_FEEDBACK_BUFFER_TYPE"/>
+ <enum name="GL_SELECTION_BUFFER_SIZE"/>
+ <enum name="GL_VERTEX_ARRAY"/>
+ <enum name="GL_NORMAL_ARRAY"/>
+ <enum name="GL_COLOR_ARRAY"/>
+ <enum name="GL_INDEX_ARRAY"/>
+ <enum name="GL_TEXTURE_COORD_ARRAY"/>
+ <enum name="GL_EDGE_FLAG_ARRAY"/>
+ <enum name="GL_VERTEX_ARRAY_SIZE"/>
+ <enum name="GL_VERTEX_ARRAY_TYPE"/>
+ <enum name="GL_VERTEX_ARRAY_STRIDE"/>
+ <enum name="GL_NORMAL_ARRAY_TYPE"/>
+ <enum name="GL_NORMAL_ARRAY_STRIDE"/>
+ <enum name="GL_COLOR_ARRAY_SIZE"/>
+ <enum name="GL_COLOR_ARRAY_TYPE"/>
+ <enum name="GL_COLOR_ARRAY_STRIDE"/>
+ <enum name="GL_INDEX_ARRAY_TYPE"/>
+ <enum name="GL_INDEX_ARRAY_STRIDE"/>
+ <enum name="GL_TEXTURE_COORD_ARRAY_SIZE"/>
+ <enum name="GL_TEXTURE_COORD_ARRAY_TYPE"/>
+ <enum name="GL_TEXTURE_COORD_ARRAY_STRIDE"/>
+ <enum name="GL_EDGE_FLAG_ARRAY_STRIDE"/>
+ <enum name="GL_TEXTURE_COMPONENTS"/>
+ <enum name="GL_TEXTURE_BORDER"/>
+ <enum name="GL_TEXTURE_LUMINANCE_SIZE"/>
+ <enum name="GL_TEXTURE_INTENSITY_SIZE"/>
+ <enum name="GL_TEXTURE_PRIORITY"/>
+ <enum name="GL_TEXTURE_RESIDENT"/>
+ <enum name="GL_AMBIENT"/>
+ <enum name="GL_DIFFUSE"/>
+ <enum name="GL_SPECULAR"/>
+ <enum name="GL_POSITION"/>
+ <enum name="GL_SPOT_DIRECTION"/>
+ <enum name="GL_SPOT_EXPONENT"/>
+ <enum name="GL_SPOT_CUTOFF"/>
+ <enum name="GL_CONSTANT_ATTENUATION"/>
+ <enum name="GL_LINEAR_ATTENUATION"/>
+ <enum name="GL_QUADRATIC_ATTENUATION"/>
+ <enum name="GL_COMPILE"/>
+ <enum name="GL_COMPILE_AND_EXECUTE"/>
+ <enum name="GL_2_BYTES"/>
+ <enum name="GL_3_BYTES"/>
+ <enum name="GL_4_BYTES"/>
+ <enum name="GL_EMISSION"/>
+ <enum name="GL_SHININESS"/>
+ <enum name="GL_AMBIENT_AND_DIFFUSE"/>
+ <enum name="GL_COLOR_INDEXES"/>
+ <enum name="GL_MODELVIEW"/>
+ <enum name="GL_PROJECTION"/>
+ <enum name="GL_COLOR_INDEX"/>
+ <enum name="GL_LUMINANCE"/>
+ <enum name="GL_LUMINANCE_ALPHA"/>
+ <enum name="GL_BITMAP"/>
+ <enum name="GL_RENDER"/>
+ <enum name="GL_FEEDBACK"/>
+ <enum name="GL_SELECT"/>
+ <enum name="GL_FLAT"/>
+ <enum name="GL_SMOOTH"/>
+ <enum name="GL_S"/>
+ <enum name="GL_T"/>
+ <enum name="GL_R"/>
+ <enum name="GL_Q"/>
+ <enum name="GL_MODULATE"/>
+ <enum name="GL_DECAL"/>
+ <enum name="GL_TEXTURE_ENV_MODE"/>
+ <enum name="GL_TEXTURE_ENV_COLOR"/>
+ <enum name="GL_TEXTURE_ENV"/>
+ <enum name="GL_EYE_LINEAR"/>
+ <enum name="GL_OBJECT_LINEAR"/>
+ <enum name="GL_SPHERE_MAP"/>
+ <enum name="GL_TEXTURE_GEN_MODE"/>
+ <enum name="GL_OBJECT_PLANE"/>
+ <enum name="GL_EYE_PLANE"/>
+ <enum name="GL_CLAMP"/>
+ <enum name="GL_ALPHA4"/>
+ <enum name="GL_ALPHA8"/>
+ <enum name="GL_ALPHA12"/>
+ <enum name="GL_ALPHA16"/>
+ <enum name="GL_LUMINANCE4"/>
+ <enum name="GL_LUMINANCE8"/>
+ <enum name="GL_LUMINANCE12"/>
+ <enum name="GL_LUMINANCE16"/>
+ <enum name="GL_LUMINANCE4_ALPHA4"/>
+ <enum name="GL_LUMINANCE6_ALPHA2"/>
+ <enum name="GL_LUMINANCE8_ALPHA8"/>
+ <enum name="GL_LUMINANCE12_ALPHA4"/>
+ <enum name="GL_LUMINANCE12_ALPHA12"/>
+ <enum name="GL_LUMINANCE16_ALPHA16"/>
+ <enum name="GL_INTENSITY"/>
+ <enum name="GL_INTENSITY4"/>
+ <enum name="GL_INTENSITY8"/>
+ <enum name="GL_INTENSITY12"/>
+ <enum name="GL_INTENSITY16"/>
+ <enum name="GL_V2F"/>
+ <enum name="GL_V3F"/>
+ <enum name="GL_C4UB_V2F"/>
+ <enum name="GL_C4UB_V3F"/>
+ <enum name="GL_C3F_V3F"/>
+ <enum name="GL_N3F_V3F"/>
+ <enum name="GL_C4F_N3F_V3F"/>
+ <enum name="GL_T2F_V3F"/>
+ <enum name="GL_T4F_V4F"/>
+ <enum name="GL_T2F_C4UB_V3F"/>
+ <enum name="GL_T2F_C3F_V3F"/>
+ <enum name="GL_T2F_N3F_V3F"/>
+ <enum name="GL_T2F_C4F_N3F_V3F"/>
+ <enum name="GL_T4F_C4F_N3F_V4F"/>
+ <enum name="GL_CLIP_PLANE0"/>
+ <enum name="GL_CLIP_PLANE1"/>
+ <enum name="GL_CLIP_PLANE2"/>
+ <enum name="GL_CLIP_PLANE3"/>
+ <enum name="GL_CLIP_PLANE4"/>
+ <enum name="GL_CLIP_PLANE5"/>
+ <enum name="GL_LIGHT0"/>
+ <enum name="GL_LIGHT1"/>
+ <enum name="GL_LIGHT2"/>
+ <enum name="GL_LIGHT3"/>
+ <enum name="GL_LIGHT4"/>
+ <enum name="GL_LIGHT5"/>
+ <enum name="GL_LIGHT6"/>
+ <enum name="GL_LIGHT7"/>
+ <command name="glArrayElement"/>
+ <command name="glColorPointer"/>
+ <command name="glDisableClientState"/>
+ <command name="glEdgeFlagPointer"/>
+ <command name="glEnableClientState"/>
+ <command name="glIndexPointer"/>
+ <command name="glGetPointerv"/>
+ <command name="glInterleavedArrays"/>
+ <command name="glNormalPointer"/>
+ <command name="glTexCoordPointer"/>
+ <command name="glVertexPointer"/>
+ <command name="glAreTexturesResident"/>
+ <command name="glPrioritizeTextures"/>
+ <command name="glIndexub"/>
+ <command name="glIndexubv"/>
+ <command name="glPopClientAttrib"/>
+ <command name="glPushClientAttrib"/>
+ </remove>
+ <remove profile="core" comment="Compatibility-only GL 1.2 features removed from GL 3.2">
+ <enum name="GL_RESCALE_NORMAL"/>
+ <enum name="GL_LIGHT_MODEL_COLOR_CONTROL"/>
+ <enum name="GL_SINGLE_COLOR"/>
+ <enum name="GL_SEPARATE_SPECULAR_COLOR"/>
+ <enum name="GL_ALIASED_POINT_SIZE_RANGE"/>
+ </remove>
+ <remove profile="core" comment="Compatibility-only GL 1.3 features removed from GL 3.2">
+ <enum name="GL_CLIENT_ACTIVE_TEXTURE"/>
+ <enum name="GL_MAX_TEXTURE_UNITS"/>
+ <enum name="GL_TRANSPOSE_MODELVIEW_MATRIX"/>
+ <enum name="GL_TRANSPOSE_PROJECTION_MATRIX"/>
+ <enum name="GL_TRANSPOSE_TEXTURE_MATRIX"/>
+ <enum name="GL_TRANSPOSE_COLOR_MATRIX"/>
+ <enum name="GL_MULTISAMPLE_BIT"/>
+ <enum name="GL_NORMAL_MAP"/>
+ <enum name="GL_REFLECTION_MAP"/>
+ <enum name="GL_COMPRESSED_ALPHA"/>
+ <enum name="GL_COMPRESSED_LUMINANCE"/>
+ <enum name="GL_COMPRESSED_LUMINANCE_ALPHA"/>
+ <enum name="GL_COMPRESSED_INTENSITY"/>
+ <enum name="GL_COMBINE"/>
+ <enum name="GL_COMBINE_RGB"/>
+ <enum name="GL_COMBINE_ALPHA"/>
+ <enum name="GL_SOURCE0_RGB"/>
+ <enum name="GL_SOURCE1_RGB"/>
+ <enum name="GL_SOURCE2_RGB"/>
+ <enum name="GL_SOURCE0_ALPHA"/>
+ <enum name="GL_SOURCE1_ALPHA"/>
+ <enum name="GL_SOURCE2_ALPHA"/>
+ <enum name="GL_OPERAND0_RGB"/>
+ <enum name="GL_OPERAND1_RGB"/>
+ <enum name="GL_OPERAND2_RGB"/>
+ <enum name="GL_OPERAND0_ALPHA"/>
+ <enum name="GL_OPERAND1_ALPHA"/>
+ <enum name="GL_OPERAND2_ALPHA"/>
+ <enum name="GL_RGB_SCALE"/>
+ <enum name="GL_ADD_SIGNED"/>
+ <enum name="GL_INTERPOLATE"/>
+ <enum name="GL_SUBTRACT"/>
+ <enum name="GL_CONSTANT"/>
+ <enum name="GL_PRIMARY_COLOR"/>
+ <enum name="GL_PREVIOUS"/>
+ <enum name="GL_DOT3_RGB"/>
+ <enum name="GL_DOT3_RGBA"/>
+ <command name="glClientActiveTexture"/>
+ <command name="glMultiTexCoord1d"/>
+ <command name="glMultiTexCoord1dv"/>
+ <command name="glMultiTexCoord1f"/>
+ <command name="glMultiTexCoord1fv"/>
+ <command name="glMultiTexCoord1i"/>
+ <command name="glMultiTexCoord1iv"/>
+ <command name="glMultiTexCoord1s"/>
+ <command name="glMultiTexCoord1sv"/>
+ <command name="glMultiTexCoord2d"/>
+ <command name="glMultiTexCoord2dv"/>
+ <command name="glMultiTexCoord2f"/>
+ <command name="glMultiTexCoord2fv"/>
+ <command name="glMultiTexCoord2i"/>
+ <command name="glMultiTexCoord2iv"/>
+ <command name="glMultiTexCoord2s"/>
+ <command name="glMultiTexCoord2sv"/>
+ <command name="glMultiTexCoord3d"/>
+ <command name="glMultiTexCoord3dv"/>
+ <command name="glMultiTexCoord3f"/>
+ <command name="glMultiTexCoord3fv"/>
+ <command name="glMultiTexCoord3i"/>
+ <command name="glMultiTexCoord3iv"/>
+ <command name="glMultiTexCoord3s"/>
+ <command name="glMultiTexCoord3sv"/>
+ <command name="glMultiTexCoord4d"/>
+ <command name="glMultiTexCoord4dv"/>
+ <command name="glMultiTexCoord4f"/>
+ <command name="glMultiTexCoord4fv"/>
+ <command name="glMultiTexCoord4i"/>
+ <command name="glMultiTexCoord4iv"/>
+ <command name="glMultiTexCoord4s"/>
+ <command name="glMultiTexCoord4sv"/>
+ <command name="glLoadTransposeMatrixf"/>
+ <command name="glLoadTransposeMatrixd"/>
+ <command name="glMultTransposeMatrixf"/>
+ <command name="glMultTransposeMatrixd"/>
+ </remove>
+ <remove profile="core" comment="Compatibility-only GL 1.4 features removed from GL 3.2">
+ <enum name="GL_POINT_SIZE_MIN"/>
+ <enum name="GL_POINT_SIZE_MAX"/>
+ <enum name="GL_POINT_DISTANCE_ATTENUATION"/>
+ <enum name="GL_GENERATE_MIPMAP"/>
+ <enum name="GL_GENERATE_MIPMAP_HINT"/>
+ <enum name="GL_FOG_COORDINATE_SOURCE"/>
+ <enum name="GL_FOG_COORDINATE"/>
+ <enum name="GL_FRAGMENT_DEPTH"/>
+ <enum name="GL_CURRENT_FOG_COORDINATE"/>
+ <enum name="GL_FOG_COORDINATE_ARRAY_TYPE"/>
+ <enum name="GL_FOG_COORDINATE_ARRAY_STRIDE"/>
+ <enum name="GL_FOG_COORDINATE_ARRAY_POINTER"/>
+ <enum name="GL_FOG_COORDINATE_ARRAY"/>
+ <enum name="GL_COLOR_SUM"/>
+ <enum name="GL_CURRENT_SECONDARY_COLOR"/>
+ <enum name="GL_SECONDARY_COLOR_ARRAY_SIZE"/>
+ <enum name="GL_SECONDARY_COLOR_ARRAY_TYPE"/>
+ <enum name="GL_SECONDARY_COLOR_ARRAY_STRIDE"/>
+ <enum name="GL_SECONDARY_COLOR_ARRAY_POINTER"/>
+ <enum name="GL_SECONDARY_COLOR_ARRAY"/>
+ <enum name="GL_TEXTURE_FILTER_CONTROL"/>
+ <enum name="GL_DEPTH_TEXTURE_MODE"/>
+ <enum name="GL_COMPARE_R_TO_TEXTURE"/>
+ <command name="glFogCoordf"/>
+ <command name="glFogCoordfv"/>
+ <command name="glFogCoordd"/>
+ <command name="glFogCoorddv"/>
+ <command name="glFogCoordPointer"/>
+ <command name="glSecondaryColor3b"/>
+ <command name="glSecondaryColor3bv"/>
+ <command name="glSecondaryColor3d"/>
+ <command name="glSecondaryColor3dv"/>
+ <command name="glSecondaryColor3f"/>
+ <command name="glSecondaryColor3fv"/>
+ <command name="glSecondaryColor3i"/>
+ <command name="glSecondaryColor3iv"/>
+ <command name="glSecondaryColor3s"/>
+ <command name="glSecondaryColor3sv"/>
+ <command name="glSecondaryColor3ub"/>
+ <command name="glSecondaryColor3ubv"/>
+ <command name="glSecondaryColor3ui"/>
+ <command name="glSecondaryColor3uiv"/>
+ <command name="glSecondaryColor3us"/>
+ <command name="glSecondaryColor3usv"/>
+ <command name="glSecondaryColorPointer"/>
+ <command name="glWindowPos2d"/>
+ <command name="glWindowPos2dv"/>
+ <command name="glWindowPos2f"/>
+ <command name="glWindowPos2fv"/>
+ <command name="glWindowPos2i"/>
+ <command name="glWindowPos2iv"/>
+ <command name="glWindowPos2s"/>
+ <command name="glWindowPos2sv"/>
+ <command name="glWindowPos3d"/>
+ <command name="glWindowPos3dv"/>
+ <command name="glWindowPos3f"/>
+ <command name="glWindowPos3fv"/>
+ <command name="glWindowPos3i"/>
+ <command name="glWindowPos3iv"/>
+ <command name="glWindowPos3s"/>
+ <command name="glWindowPos3sv"/>
+ </remove>
+ <remove profile="core" comment="Compatibility-only GL 1.5 features removed from GL 3.2">
+ <enum name="GL_VERTEX_ARRAY_BUFFER_BINDING"/>
+ <enum name="GL_NORMAL_ARRAY_BUFFER_BINDING"/>
+ <enum name="GL_COLOR_ARRAY_BUFFER_BINDING"/>
+ <enum name="GL_INDEX_ARRAY_BUFFER_BINDING"/>
+ <enum name="GL_TEXTURE_COORD_ARRAY_BUFFER_BINDING"/>
+ <enum name="GL_EDGE_FLAG_ARRAY_BUFFER_BINDING"/>
+ <enum name="GL_SECONDARY_COLOR_ARRAY_BUFFER_BINDING"/>
+ <enum name="GL_FOG_COORDINATE_ARRAY_BUFFER_BINDING"/>
+ <enum name="GL_WEIGHT_ARRAY_BUFFER_BINDING"/>
+ <enum name="GL_FOG_COORD_SRC"/>
+ <enum name="GL_FOG_COORD"/>
+ <enum name="GL_CURRENT_FOG_COORD"/>
+ <enum name="GL_FOG_COORD_ARRAY_TYPE"/>
+ <enum name="GL_FOG_COORD_ARRAY_STRIDE"/>
+ <enum name="GL_FOG_COORD_ARRAY_POINTER"/>
+ <enum name="GL_FOG_COORD_ARRAY"/>
+ <enum name="GL_FOG_COORD_ARRAY_BUFFER_BINDING"/>
+ <enum name="GL_SRC0_RGB"/>
+ <enum name="GL_SRC1_RGB"/>
+ <enum name="GL_SRC2_RGB"/>
+ <enum name="GL_SRC0_ALPHA"/>
+ <enum name="GL_SRC2_ALPHA"/>
+ </remove>
+ <remove profile="core" comment="Compatibility-only GL 2.0 features removed from GL 3.2">
+ <enum name="GL_VERTEX_PROGRAM_TWO_SIDE"/>
+ <enum name="GL_POINT_SPRITE"/>
+ <enum name="GL_COORD_REPLACE"/>
+ <enum name="GL_MAX_TEXTURE_COORDS"/>
+ </remove>
+ <remove profile="core" comment="Compatibility-only GL 2.1 features removed from GL 3.2">
+ <enum name="GL_CURRENT_RASTER_SECONDARY_COLOR"/>
+ <enum name="GL_SLUMINANCE_ALPHA"/>
+ <enum name="GL_SLUMINANCE8_ALPHA8"/>
+ <enum name="GL_SLUMINANCE"/>
+ <enum name="GL_SLUMINANCE8"/>
+ <enum name="GL_COMPRESSED_SLUMINANCE"/>
+ <enum name="GL_COMPRESSED_SLUMINANCE_ALPHA"/>
+ </remove>
+ <remove profile="core" comment="Compatibility-only GL 3.0 features removed from GL 3.2">
+ <enum name="GL_CLAMP_VERTEX_COLOR"/>
+ <enum name="GL_CLAMP_FRAGMENT_COLOR"/>
+ <enum name="GL_ALPHA_INTEGER"/>
+ <enum name="GL_TEXTURE_LUMINANCE_TYPE"/>
+ <enum name="GL_TEXTURE_INTENSITY_TYPE"/>
+ </remove>
+ <!-- Deprecated (not removed) in OpenGL 3.2 core;
+ deprecate tag not defined/supported yet
+ <deprecate profile="core">
+ <enum name="GL_MAX_VARYING_FLOATS"/>
+ <enum name="GL_MAX_VARYING_COMPONENTS"/>
+ </deprecate>
+ -->
+ </feature>
+ <feature api="gl" name="GL_VERSION_3_3" number="3.3">
+ <require>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY_DIVISOR"/>
+ </require>
+ <require comment="Reuse ARB_blend_func_extended">
+ <enum name="GL_SRC1_COLOR"/>
+ <enum name="GL_ONE_MINUS_SRC1_COLOR"/>
+ <enum name="GL_ONE_MINUS_SRC1_ALPHA"/>
+ <enum name="GL_MAX_DUAL_SOURCE_DRAW_BUFFERS"/>
+ <command name="glBindFragDataLocationIndexed"/>
+ <command name="glGetFragDataIndex"/>
+ </require>
+ <require comment="Reuse ARB_explicit_attrib_location (none)">
+ </require>
+ <require comment="Reuse ARB_occlusion_query2">
+ <enum name="GL_ANY_SAMPLES_PASSED"/>
+ </require>
+ <require comment="Reuse ARB_sampler_objects">
+ <enum name="GL_SAMPLER_BINDING"/>
+ <command name="glGenSamplers"/>
+ <command name="glDeleteSamplers"/>
+ <command name="glIsSampler"/>
+ <command name="glBindSampler"/>
+ <command name="glSamplerParameteri"/>
+ <command name="glSamplerParameteriv"/>
+ <command name="glSamplerParameterf"/>
+ <command name="glSamplerParameterfv"/>
+ <command name="glSamplerParameterIiv"/>
+ <command name="glSamplerParameterIuiv"/>
+ <command name="glGetSamplerParameteriv"/>
+ <command name="glGetSamplerParameterIiv"/>
+ <command name="glGetSamplerParameterfv"/>
+ <command name="glGetSamplerParameterIuiv"/>
+ </require>
+ <require comment="Reuse ARB_shader_bit_encoding (none)">
+ </require>
+ <require comment="Reuse ARB_texture_rgb10_a2ui">
+ <enum name="GL_RGB10_A2UI"/>
+ </require>
+ <require comment="Reuse ARB_texture_swizzle">
+ <enum name="GL_TEXTURE_SWIZZLE_R"/>
+ <enum name="GL_TEXTURE_SWIZZLE_G"/>
+ <enum name="GL_TEXTURE_SWIZZLE_B"/>
+ <enum name="GL_TEXTURE_SWIZZLE_A"/>
+ <enum name="GL_TEXTURE_SWIZZLE_RGBA"/>
+ </require>
+ <require comment="Reuse ARB_timer_query">
+ <enum name="GL_TIME_ELAPSED"/>
+ <enum name="GL_TIMESTAMP"/>
+ <command name="glQueryCounter"/>
+ <command name="glGetQueryObjecti64v"/>
+ <command name="glGetQueryObjectui64v"/>
+ </require>
+ <require comment="Reuse ARB_vertex_type_2_10_10_10_rev">
+ <enum name="GL_INT_2_10_10_10_REV"/>
+ <command name="glVertexAttribDivisor"/>
+ <command name="glVertexAttribP1ui"/>
+ <command name="glVertexAttribP1uiv"/>
+ <command name="glVertexAttribP2ui"/>
+ <command name="glVertexAttribP2uiv"/>
+ <command name="glVertexAttribP3ui"/>
+ <command name="glVertexAttribP3uiv"/>
+ <command name="glVertexAttribP4ui"/>
+ <command name="glVertexAttribP4uiv"/>
+ </require>
+ <require profile="compatibility" comment="Reuse ARB_vertex_type_2_10_10_10_rev compatibility profile">
+ <command name="glVertexP2ui"/>
+ <command name="glVertexP2uiv"/>
+ <command name="glVertexP3ui"/>
+ <command name="glVertexP3uiv"/>
+ <command name="glVertexP4ui"/>
+ <command name="glVertexP4uiv"/>
+ <command name="glTexCoordP1ui"/>
+ <command name="glTexCoordP1uiv"/>
+ <command name="glTexCoordP2ui"/>
+ <command name="glTexCoordP2uiv"/>
+ <command name="glTexCoordP3ui"/>
+ <command name="glTexCoordP3uiv"/>
+ <command name="glTexCoordP4ui"/>
+ <command name="glTexCoordP4uiv"/>
+ <command name="glMultiTexCoordP1ui"/>
+ <command name="glMultiTexCoordP1uiv"/>
+ <command name="glMultiTexCoordP2ui"/>
+ <command name="glMultiTexCoordP2uiv"/>
+ <command name="glMultiTexCoordP3ui"/>
+ <command name="glMultiTexCoordP3uiv"/>
+ <command name="glMultiTexCoordP4ui"/>
+ <command name="glMultiTexCoordP4uiv"/>
+ <command name="glNormalP3ui"/>
+ <command name="glNormalP3uiv"/>
+ <command name="glColorP3ui"/>
+ <command name="glColorP3uiv"/>
+ <command name="glColorP4ui"/>
+ <command name="glColorP4uiv"/>
+ <command name="glSecondaryColorP3ui"/>
+ <command name="glSecondaryColorP3uiv"/>
+ </require>
+ </feature>
+ <feature api="gl" name="GL_VERSION_4_0" number="4.0">
+ <require>
+ <enum name="GL_SAMPLE_SHADING"/>
+ <enum name="GL_MIN_SAMPLE_SHADING_VALUE"/>
+ <enum name="GL_MIN_PROGRAM_TEXTURE_GATHER_OFFSET"/>
+ <enum name="GL_MAX_PROGRAM_TEXTURE_GATHER_OFFSET"/>
+ <enum name="GL_TEXTURE_CUBE_MAP_ARRAY"/>
+ <enum name="GL_TEXTURE_BINDING_CUBE_MAP_ARRAY"/>
+ <enum name="GL_PROXY_TEXTURE_CUBE_MAP_ARRAY"/>
+ <enum name="GL_SAMPLER_CUBE_MAP_ARRAY"/>
+ <enum name="GL_SAMPLER_CUBE_MAP_ARRAY_SHADOW"/>
+ <enum name="GL_INT_SAMPLER_CUBE_MAP_ARRAY"/>
+ <enum name="GL_UNSIGNED_INT_SAMPLER_CUBE_MAP_ARRAY"/>
+ <command name="glMinSampleShading"/>
+ <command name="glBlendEquationi"/>
+ <command name="glBlendEquationSeparatei"/>
+ <command name="glBlendFunci"/>
+ <command name="glBlendFuncSeparatei"/>
+ </require>
+ <require comment="Reuse ARB_draw_buffers_blend (none)">
+ </require>
+ <require comment="Reuse ARB_draw_indirect">
+ <enum name="GL_DRAW_INDIRECT_BUFFER"/>
+ <enum name="GL_DRAW_INDIRECT_BUFFER_BINDING"/>
+ <command name="glDrawArraysIndirect"/>
+ <command name="glDrawElementsIndirect"/>
+ </require>
+ <require comment="Reuse ARB_gpu_shader5">
+ <enum name="GL_GEOMETRY_SHADER_INVOCATIONS"/>
+ <enum name="GL_MAX_GEOMETRY_SHADER_INVOCATIONS"/>
+ <enum name="GL_MIN_FRAGMENT_INTERPOLATION_OFFSET"/>
+ <enum name="GL_MAX_FRAGMENT_INTERPOLATION_OFFSET"/>
+ <enum name="GL_FRAGMENT_INTERPOLATION_OFFSET_BITS"/>
+ <enum name="GL_MAX_VERTEX_STREAMS"/>
+ </require>
+ <require comment="Reuse ARB_gpu_shader_fp64">
+ <enum name="GL_DOUBLE_VEC2"/>
+ <enum name="GL_DOUBLE_VEC3"/>
+ <enum name="GL_DOUBLE_VEC4"/>
+ <enum name="GL_DOUBLE_MAT2"/>
+ <enum name="GL_DOUBLE_MAT3"/>
+ <enum name="GL_DOUBLE_MAT4"/>
+ <enum name="GL_DOUBLE_MAT2x3"/>
+ <enum name="GL_DOUBLE_MAT2x4"/>
+ <enum name="GL_DOUBLE_MAT3x2"/>
+ <enum name="GL_DOUBLE_MAT3x4"/>
+ <enum name="GL_DOUBLE_MAT4x2"/>
+ <enum name="GL_DOUBLE_MAT4x3"/>
+ <command name="glUniform1d"/>
+ <command name="glUniform2d"/>
+ <command name="glUniform3d"/>
+ <command name="glUniform4d"/>
+ <command name="glUniform1dv"/>
+ <command name="glUniform2dv"/>
+ <command name="glUniform3dv"/>
+ <command name="glUniform4dv"/>
+ <command name="glUniformMatrix2dv"/>
+ <command name="glUniformMatrix3dv"/>
+ <command name="glUniformMatrix4dv"/>
+ <command name="glUniformMatrix2x3dv"/>
+ <command name="glUniformMatrix2x4dv"/>
+ <command name="glUniformMatrix3x2dv"/>
+ <command name="glUniformMatrix3x4dv"/>
+ <command name="glUniformMatrix4x2dv"/>
+ <command name="glUniformMatrix4x3dv"/>
+ <command name="glGetUniformdv"/>
+ </require>
+ <require comment="Reuse ARB_shader_subroutine">
+ <enum name="GL_ACTIVE_SUBROUTINES"/>
+ <enum name="GL_ACTIVE_SUBROUTINE_UNIFORMS"/>
+ <enum name="GL_ACTIVE_SUBROUTINE_UNIFORM_LOCATIONS"/>
+ <enum name="GL_ACTIVE_SUBROUTINE_MAX_LENGTH"/>
+ <enum name="GL_ACTIVE_SUBROUTINE_UNIFORM_MAX_LENGTH"/>
+ <enum name="GL_MAX_SUBROUTINES"/>
+ <enum name="GL_MAX_SUBROUTINE_UNIFORM_LOCATIONS"/>
+ <enum name="GL_NUM_COMPATIBLE_SUBROUTINES"/>
+ <enum name="GL_COMPATIBLE_SUBROUTINES"/>
+ <command name="glGetSubroutineUniformLocation"/>
+ <command name="glGetSubroutineIndex"/>
+ <command name="glGetActiveSubroutineUniformiv"/>
+ <command name="glGetActiveSubroutineUniformName"/>
+ <command name="glGetActiveSubroutineName"/>
+ <command name="glUniformSubroutinesuiv"/>
+ <command name="glGetUniformSubroutineuiv"/>
+ <command name="glGetProgramStageiv"/>
+ </require>
+ <require comment="Reuse ARB_tessellation_shader">
+ <enum name="GL_PATCHES"/>
+ <enum name="GL_PATCH_VERTICES"/>
+ <enum name="GL_PATCH_DEFAULT_INNER_LEVEL"/>
+ <enum name="GL_PATCH_DEFAULT_OUTER_LEVEL"/>
+ <enum name="GL_TESS_CONTROL_OUTPUT_VERTICES"/>
+ <enum name="GL_TESS_GEN_MODE"/>
+ <enum name="GL_TESS_GEN_SPACING"/>
+ <enum name="GL_TESS_GEN_VERTEX_ORDER"/>
+ <enum name="GL_TESS_GEN_POINT_MODE"/>
+ <enum name="GL_ISOLINES"/>
+ <enum name="GL_QUADS"/>
+ <enum name="GL_FRACTIONAL_ODD"/>
+ <enum name="GL_FRACTIONAL_EVEN"/>
+ <enum name="GL_MAX_PATCH_VERTICES"/>
+ <enum name="GL_MAX_TESS_GEN_LEVEL"/>
+ <enum name="GL_MAX_TESS_CONTROL_UNIFORM_COMPONENTS"/>
+ <enum name="GL_MAX_TESS_EVALUATION_UNIFORM_COMPONENTS"/>
+ <enum name="GL_MAX_TESS_CONTROL_TEXTURE_IMAGE_UNITS"/>
+ <enum name="GL_MAX_TESS_EVALUATION_TEXTURE_IMAGE_UNITS"/>
+ <enum name="GL_MAX_TESS_CONTROL_OUTPUT_COMPONENTS"/>
+ <enum name="GL_MAX_TESS_PATCH_COMPONENTS"/>
+ <enum name="GL_MAX_TESS_CONTROL_TOTAL_OUTPUT_COMPONENTS"/>
+ <enum name="GL_MAX_TESS_EVALUATION_OUTPUT_COMPONENTS"/>
+ <enum name="GL_MAX_TESS_CONTROL_UNIFORM_BLOCKS"/>
+ <enum name="GL_MAX_TESS_EVALUATION_UNIFORM_BLOCKS"/>
+ <enum name="GL_MAX_TESS_CONTROL_INPUT_COMPONENTS"/>
+ <enum name="GL_MAX_TESS_EVALUATION_INPUT_COMPONENTS"/>
+ <enum name="GL_MAX_COMBINED_TESS_CONTROL_UNIFORM_COMPONENTS"/>
+ <enum name="GL_MAX_COMBINED_TESS_EVALUATION_UNIFORM_COMPONENTS"/>
+ <enum name="GL_UNIFORM_BLOCK_REFERENCED_BY_TESS_CONTROL_SHADER"/>
+ <enum name="GL_UNIFORM_BLOCK_REFERENCED_BY_TESS_EVALUATION_SHADER"/>
+ <enum name="GL_TESS_EVALUATION_SHADER"/>
+ <enum name="GL_TESS_CONTROL_SHADER"/>
+ <command name="glPatchParameteri"/>
+ <command name="glPatchParameterfv"/>
+ </require>
+ <require comment="Reuse ARB_texture_buffer_object_rgb32 (none)">
+ </require>
+ <require comment="Reuse ARB_texture_cube_map_array (none)">
+ </require>
+ <require comment="Reuse ARB_texture_gather (none)">
+ </require>
+ <require comment="Reuse ARB_texture_query_lod (none)">
+ </require>
+ <require comment="Reuse ARB_transform_feedback2">
+ <enum name="GL_TRANSFORM_FEEDBACK"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_BUFFER_PAUSED"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_BUFFER_ACTIVE"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_BINDING"/>
+ <command name="glBindTransformFeedback"/>
+ <command name="glDeleteTransformFeedbacks"/>
+ <command name="glGenTransformFeedbacks"/>
+ <command name="glIsTransformFeedback"/>
+ <command name="glPauseTransformFeedback"/>
+ <command name="glResumeTransformFeedback"/>
+ <command name="glDrawTransformFeedback"/>
+ </require>
+ <require comment="Reuse ARB_transform_feedback3">
+ <enum name="GL_MAX_TRANSFORM_FEEDBACK_BUFFERS"/>
+ <enum name="GL_MAX_VERTEX_STREAMS"/>
+ <command name="glDrawTransformFeedbackStream"/>
+ <command name="glBeginQueryIndexed"/>
+ <command name="glEndQueryIndexed"/>
+ <command name="glGetQueryIndexediv"/>
+ </require>
+ </feature>
+ <feature api="gl" name="GL_VERSION_4_1" number="4.1">
+ <require comment="Reuse tokens from ARB_ES2_compatibility">
+ <enum name="GL_FIXED"/>
+ <enum name="GL_IMPLEMENTATION_COLOR_READ_TYPE"/>
+ <enum name="GL_IMPLEMENTATION_COLOR_READ_FORMAT"/>
+ <enum name="GL_LOW_FLOAT"/>
+ <enum name="GL_MEDIUM_FLOAT"/>
+ <enum name="GL_HIGH_FLOAT"/>
+ <enum name="GL_LOW_INT"/>
+ <enum name="GL_MEDIUM_INT"/>
+ <enum name="GL_HIGH_INT"/>
+ <enum name="GL_SHADER_COMPILER"/>
+ <enum name="GL_SHADER_BINARY_FORMATS"/>
+ <enum name="GL_NUM_SHADER_BINARY_FORMATS"/>
+ <enum name="GL_MAX_VERTEX_UNIFORM_VECTORS"/>
+ <enum name="GL_MAX_VARYING_VECTORS"/>
+ <enum name="GL_MAX_FRAGMENT_UNIFORM_VECTORS"/>
+ <enum name="GL_RGB565"/>
+ </require>
+ <require comment="Reuse tokens from ARB_get_program_binary">
+ <enum name="GL_PROGRAM_BINARY_RETRIEVABLE_HINT"/>
+ <enum name="GL_PROGRAM_BINARY_LENGTH"/>
+ <enum name="GL_NUM_PROGRAM_BINARY_FORMATS"/>
+ <enum name="GL_PROGRAM_BINARY_FORMATS"/>
+ </require>
+ <require comment="Reuse tokens from ARB_separate_shader_objects">
+ <enum name="GL_VERTEX_SHADER_BIT"/>
+ <enum name="GL_FRAGMENT_SHADER_BIT"/>
+ <enum name="GL_GEOMETRY_SHADER_BIT"/>
+ <enum name="GL_TESS_CONTROL_SHADER_BIT"/>
+ <enum name="GL_TESS_EVALUATION_SHADER_BIT"/>
+ <enum name="GL_ALL_SHADER_BITS"/>
+ <enum name="GL_PROGRAM_SEPARABLE"/>
+ <enum name="GL_ACTIVE_PROGRAM"/>
+ <enum name="GL_PROGRAM_PIPELINE_BINDING"/>
+ </require>
+ <require comment="Reuse tokens from ARB_shader_precision (none)">
+ </require>
+ <require comment="Reuse tokens from ARB_vertex_attrib_64bit - all are in GL 3.0 and 4.0 already">
+ </require>
+ <require comment="Reuse tokens from ARB_viewport_array - some are in GL 1.1 and ARB_provoking_vertex already">
+ <enum name="GL_MAX_VIEWPORTS"/>
+ <enum name="GL_VIEWPORT_SUBPIXEL_BITS"/>
+ <enum name="GL_VIEWPORT_BOUNDS_RANGE"/>
+ <enum name="GL_LAYER_PROVOKING_VERTEX"/>
+ <enum name="GL_VIEWPORT_INDEX_PROVOKING_VERTEX"/>
+ <enum name="GL_UNDEFINED_VERTEX"/>
+ </require>
+ <require comment="Reuse commands from ARB_ES2_compatibility">
+ <command name="glReleaseShaderCompiler"/>
+ <command name="glShaderBinary"/>
+ <command name="glGetShaderPrecisionFormat"/>
+ <command name="glDepthRangef"/>
+ <command name="glClearDepthf"/>
+ </require>
+ <require comment="Reuse commands from ARB_get_program_binary">
+ <command name="glGetProgramBinary"/>
+ <command name="glProgramBinary"/>
+ <command name="glProgramParameteri"/>
+ </require>
+ <require comment="Reuse commands from ARB_separate_shader_objects">
+ <command name="glUseProgramStages"/>
+ <command name="glActiveShaderProgram"/>
+ <command name="glCreateShaderProgramv"/>
+ <command name="glBindProgramPipeline"/>
+ <command name="glDeleteProgramPipelines"/>
+ <command name="glGenProgramPipelines"/>
+ <command name="glIsProgramPipeline"/>
+ <command name="glGetProgramPipelineiv"/>
+ <command name="glProgramUniform1i"/>
+ <command name="glProgramUniform1iv"/>
+ <command name="glProgramUniform1f"/>
+ <command name="glProgramUniform1fv"/>
+ <command name="glProgramUniform1d"/>
+ <command name="glProgramUniform1dv"/>
+ <command name="glProgramUniform1ui"/>
+ <command name="glProgramUniform1uiv"/>
+ <command name="glProgramUniform2i"/>
+ <command name="glProgramUniform2iv"/>
+ <command name="glProgramUniform2f"/>
+ <command name="glProgramUniform2fv"/>
+ <command name="glProgramUniform2d"/>
+ <command name="glProgramUniform2dv"/>
+ <command name="glProgramUniform2ui"/>
+ <command name="glProgramUniform2uiv"/>
+ <command name="glProgramUniform3i"/>
+ <command name="glProgramUniform3iv"/>
+ <command name="glProgramUniform3f"/>
+ <command name="glProgramUniform3fv"/>
+ <command name="glProgramUniform3d"/>
+ <command name="glProgramUniform3dv"/>
+ <command name="glProgramUniform3ui"/>
+ <command name="glProgramUniform3uiv"/>
+ <command name="glProgramUniform4i"/>
+ <command name="glProgramUniform4iv"/>
+ <command name="glProgramUniform4f"/>
+ <command name="glProgramUniform4fv"/>
+ <command name="glProgramUniform4d"/>
+ <command name="glProgramUniform4dv"/>
+ <command name="glProgramUniform4ui"/>
+ <command name="glProgramUniform4uiv"/>
+ <command name="glProgramUniformMatrix2fv"/>
+ <command name="glProgramUniformMatrix3fv"/>
+ <command name="glProgramUniformMatrix4fv"/>
+ <command name="glProgramUniformMatrix2dv"/>
+ <command name="glProgramUniformMatrix3dv"/>
+ <command name="glProgramUniformMatrix4dv"/>
+ <command name="glProgramUniformMatrix2x3fv"/>
+ <command name="glProgramUniformMatrix3x2fv"/>
+ <command name="glProgramUniformMatrix2x4fv"/>
+ <command name="glProgramUniformMatrix4x2fv"/>
+ <command name="glProgramUniformMatrix3x4fv"/>
+ <command name="glProgramUniformMatrix4x3fv"/>
+ <command name="glProgramUniformMatrix2x3dv"/>
+ <command name="glProgramUniformMatrix3x2dv"/>
+ <command name="glProgramUniformMatrix2x4dv"/>
+ <command name="glProgramUniformMatrix4x2dv"/>
+ <command name="glProgramUniformMatrix3x4dv"/>
+ <command name="glProgramUniformMatrix4x3dv"/>
+ <command name="glValidateProgramPipeline"/>
+ <command name="glGetProgramPipelineInfoLog"/>
+ </require>
+ <require comment="Reuse commands from ARB_shader_precision (none)">
+ </require>
+ <require comment="Reuse commands from ARB_vertex_attrib_64bit">
+ <command name="glVertexAttribL1d"/>
+ <command name="glVertexAttribL2d"/>
+ <command name="glVertexAttribL3d"/>
+ <command name="glVertexAttribL4d"/>
+ <command name="glVertexAttribL1dv"/>
+ <command name="glVertexAttribL2dv"/>
+ <command name="glVertexAttribL3dv"/>
+ <command name="glVertexAttribL4dv"/>
+ <command name="glVertexAttribLPointer"/>
+ <command name="glGetVertexAttribLdv"/>
+ </require>
+ <require comment="Reuse commands from ARB_viewport_array">
+ <command name="glViewportArrayv"/>
+ <command name="glViewportIndexedf"/>
+ <command name="glViewportIndexedfv"/>
+ <command name="glScissorArrayv"/>
+ <command name="glScissorIndexed"/>
+ <command name="glScissorIndexedv"/>
+ <command name="glDepthRangeArrayv"/>
+ <command name="glDepthRangeIndexed"/>
+ <command name="glGetFloati_v"/>
+ <command name="glGetDoublei_v"/>
+ </require>
+ </feature>
+ <feature api="gl" name="GL_VERSION_4_2" number="4.2">
+ <require comment="Reuse tokens from ARB_base_instance (none)">
+ </require>
+ <require comment="Reuse tokens from ARB_shading_language_420pack (none)">
+ </require>
+ <require comment="Reuse tokens from ARB_transform_feedback_instanced (none)">
+ </require>
+ <require comment="Reuse tokens from ARB_compressed_texture_pixel_storage">
+ <enum name="GL_UNPACK_COMPRESSED_BLOCK_WIDTH"/>
+ <enum name="GL_UNPACK_COMPRESSED_BLOCK_HEIGHT"/>
+ <enum name="GL_UNPACK_COMPRESSED_BLOCK_DEPTH"/>
+ <enum name="GL_UNPACK_COMPRESSED_BLOCK_SIZE"/>
+ <enum name="GL_PACK_COMPRESSED_BLOCK_WIDTH"/>
+ <enum name="GL_PACK_COMPRESSED_BLOCK_HEIGHT"/>
+ <enum name="GL_PACK_COMPRESSED_BLOCK_DEPTH"/>
+ <enum name="GL_PACK_COMPRESSED_BLOCK_SIZE"/>
+ </require>
+ <require comment="Reuse tokens from ARB_conservative_depth (none)">
+ </require>
+ <require comment="Reuse tokens from ARB_internalformat_query">
+ <enum name="GL_NUM_SAMPLE_COUNTS"/>
+ </require>
+ <require comment="Reuse tokens from ARB_map_buffer_alignment">
+ <enum name="GL_MIN_MAP_BUFFER_ALIGNMENT"/>
+ </require>
+ <require comment="Reuse tokens from ARB_shader_atomic_counters">
+ <enum name="GL_ATOMIC_COUNTER_BUFFER"/>
+ <enum name="GL_ATOMIC_COUNTER_BUFFER_BINDING"/>
+ <enum name="GL_ATOMIC_COUNTER_BUFFER_START"/>
+ <enum name="GL_ATOMIC_COUNTER_BUFFER_SIZE"/>
+ <enum name="GL_ATOMIC_COUNTER_BUFFER_DATA_SIZE"/>
+ <enum name="GL_ATOMIC_COUNTER_BUFFER_ACTIVE_ATOMIC_COUNTERS"/>
+ <enum name="GL_ATOMIC_COUNTER_BUFFER_ACTIVE_ATOMIC_COUNTER_INDICES"/>
+ <enum name="GL_ATOMIC_COUNTER_BUFFER_REFERENCED_BY_VERTEX_SHADER"/>
+ <enum name="GL_ATOMIC_COUNTER_BUFFER_REFERENCED_BY_TESS_CONTROL_SHADER"/>
+ <enum name="GL_ATOMIC_COUNTER_BUFFER_REFERENCED_BY_TESS_EVALUATION_SHADER"/>
+ <enum name="GL_ATOMIC_COUNTER_BUFFER_REFERENCED_BY_GEOMETRY_SHADER"/>
+ <enum name="GL_ATOMIC_COUNTER_BUFFER_REFERENCED_BY_FRAGMENT_SHADER"/>
+ <enum name="GL_MAX_VERTEX_ATOMIC_COUNTER_BUFFERS"/>
+ <enum name="GL_MAX_TESS_CONTROL_ATOMIC_COUNTER_BUFFERS"/>
+ <enum name="GL_MAX_TESS_EVALUATION_ATOMIC_COUNTER_BUFFERS"/>
+ <enum name="GL_MAX_GEOMETRY_ATOMIC_COUNTER_BUFFERS"/>
+ <enum name="GL_MAX_FRAGMENT_ATOMIC_COUNTER_BUFFERS"/>
+ <enum name="GL_MAX_COMBINED_ATOMIC_COUNTER_BUFFERS"/>
+ <enum name="GL_MAX_VERTEX_ATOMIC_COUNTERS"/>
+ <enum name="GL_MAX_TESS_CONTROL_ATOMIC_COUNTERS"/>
+ <enum name="GL_MAX_TESS_EVALUATION_ATOMIC_COUNTERS"/>
+ <enum name="GL_MAX_GEOMETRY_ATOMIC_COUNTERS"/>
+ <enum name="GL_MAX_FRAGMENT_ATOMIC_COUNTERS"/>
+ <enum name="GL_MAX_COMBINED_ATOMIC_COUNTERS"/>
+ <enum name="GL_MAX_ATOMIC_COUNTER_BUFFER_SIZE"/>
+ <enum name="GL_MAX_ATOMIC_COUNTER_BUFFER_BINDINGS"/>
+ <enum name="GL_ACTIVE_ATOMIC_COUNTER_BUFFERS"/>
+ <enum name="GL_UNIFORM_ATOMIC_COUNTER_BUFFER_INDEX"/>
+ <enum name="GL_UNSIGNED_INT_ATOMIC_COUNTER"/>
+ </require>
+ <require comment="Reuse tokens from ARB_shader_image_load_store">
+ <enum name="GL_VERTEX_ATTRIB_ARRAY_BARRIER_BIT"/>
+ <enum name="GL_ELEMENT_ARRAY_BARRIER_BIT"/>
+ <enum name="GL_UNIFORM_BARRIER_BIT"/>
+ <enum name="GL_TEXTURE_FETCH_BARRIER_BIT"/>
+ <enum name="GL_SHADER_IMAGE_ACCESS_BARRIER_BIT"/>
+ <enum name="GL_COMMAND_BARRIER_BIT"/>
+ <enum name="GL_PIXEL_BUFFER_BARRIER_BIT"/>
+ <enum name="GL_TEXTURE_UPDATE_BARRIER_BIT"/>
+ <enum name="GL_BUFFER_UPDATE_BARRIER_BIT"/>
+ <enum name="GL_FRAMEBUFFER_BARRIER_BIT"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_BARRIER_BIT"/>
+ <enum name="GL_ATOMIC_COUNTER_BARRIER_BIT"/>
+ <enum name="GL_ALL_BARRIER_BITS"/>
+ <enum name="GL_MAX_IMAGE_UNITS"/>
+ <enum name="GL_MAX_COMBINED_IMAGE_UNITS_AND_FRAGMENT_OUTPUTS"/>
+ <enum name="GL_IMAGE_BINDING_NAME"/>
+ <enum name="GL_IMAGE_BINDING_LEVEL"/>
+ <enum name="GL_IMAGE_BINDING_LAYERED"/>
+ <enum name="GL_IMAGE_BINDING_LAYER"/>
+ <enum name="GL_IMAGE_BINDING_ACCESS"/>
+ <enum name="GL_IMAGE_1D"/>
+ <enum name="GL_IMAGE_2D"/>
+ <enum name="GL_IMAGE_3D"/>
+ <enum name="GL_IMAGE_2D_RECT"/>
+ <enum name="GL_IMAGE_CUBE"/>
+ <enum name="GL_IMAGE_BUFFER"/>
+ <enum name="GL_IMAGE_1D_ARRAY"/>
+ <enum name="GL_IMAGE_2D_ARRAY"/>
+ <enum name="GL_IMAGE_CUBE_MAP_ARRAY"/>
+ <enum name="GL_IMAGE_2D_MULTISAMPLE"/>
+ <enum name="GL_IMAGE_2D_MULTISAMPLE_ARRAY"/>
+ <enum name="GL_INT_IMAGE_1D"/>
+ <enum name="GL_INT_IMAGE_2D"/>
+ <enum name="GL_INT_IMAGE_3D"/>
+ <enum name="GL_INT_IMAGE_2D_RECT"/>
+ <enum name="GL_INT_IMAGE_CUBE"/>
+ <enum name="GL_INT_IMAGE_BUFFER"/>
+ <enum name="GL_INT_IMAGE_1D_ARRAY"/>
+ <enum name="GL_INT_IMAGE_2D_ARRAY"/>
+ <enum name="GL_INT_IMAGE_CUBE_MAP_ARRAY"/>
+ <enum name="GL_INT_IMAGE_2D_MULTISAMPLE"/>
+ <enum name="GL_INT_IMAGE_2D_MULTISAMPLE_ARRAY"/>
+ <enum name="GL_UNSIGNED_INT_IMAGE_1D"/>
+ <enum name="GL_UNSIGNED_INT_IMAGE_2D"/>
+ <enum name="GL_UNSIGNED_INT_IMAGE_3D"/>
+ <enum name="GL_UNSIGNED_INT_IMAGE_2D_RECT"/>
+ <enum name="GL_UNSIGNED_INT_IMAGE_CUBE"/>
+ <enum name="GL_UNSIGNED_INT_IMAGE_BUFFER"/>
+ <enum name="GL_UNSIGNED_INT_IMAGE_1D_ARRAY"/>
+ <enum name="GL_UNSIGNED_INT_IMAGE_2D_ARRAY"/>
+ <enum name="GL_UNSIGNED_INT_IMAGE_CUBE_MAP_ARRAY"/>
+ <enum name="GL_UNSIGNED_INT_IMAGE_2D_MULTISAMPLE"/>
+ <enum name="GL_UNSIGNED_INT_IMAGE_2D_MULTISAMPLE_ARRAY"/>
+ <enum name="GL_MAX_IMAGE_SAMPLES"/>
+ <enum name="GL_IMAGE_BINDING_FORMAT"/>
+ <enum name="GL_IMAGE_FORMAT_COMPATIBILITY_TYPE"/>
+ <enum name="GL_IMAGE_FORMAT_COMPATIBILITY_BY_SIZE"/>
+ <enum name="GL_IMAGE_FORMAT_COMPATIBILITY_BY_CLASS"/>
+ <enum name="GL_MAX_VERTEX_IMAGE_UNIFORMS"/>
+ <enum name="GL_MAX_TESS_CONTROL_IMAGE_UNIFORMS"/>
+ <enum name="GL_MAX_TESS_EVALUATION_IMAGE_UNIFORMS"/>
+ <enum name="GL_MAX_GEOMETRY_IMAGE_UNIFORMS"/>
+ <enum name="GL_MAX_FRAGMENT_IMAGE_UNIFORMS"/>
+ <enum name="GL_MAX_COMBINED_IMAGE_UNIFORMS"/>
+ </require>
+ <require comment="Reuse tokens from ARB_shading_language_packing (none)">
+ </require>
+ <require comment="Reuse tokens from ARB_texture_compression_bptc">
+ <enum name="GL_COMPRESSED_RGBA_BPTC_UNORM"/>
+ <enum name="GL_COMPRESSED_SRGB_ALPHA_BPTC_UNORM"/>
+ <enum name="GL_COMPRESSED_RGB_BPTC_SIGNED_FLOAT"/>
+ <enum name="GL_COMPRESSED_RGB_BPTC_UNSIGNED_FLOAT"/>
+ </require>
+ <require comment="Reuse tokens from ARB_texture_storage">
+ <enum name="GL_TEXTURE_IMMUTABLE_FORMAT"/>
+ </require>
+ <require comment="Reuse commands from ARB_base_instance">
+ <command name="glDrawArraysInstancedBaseInstance"/>
+ <command name="glDrawElementsInstancedBaseInstance"/>
+ <command name="glDrawElementsInstancedBaseVertexBaseInstance"/>
+ </require>
+ <require comment="Reuse commands from ARB_compressed_texture_pixel_storage (none)">
+ </require>
+ <require comment="Reuse commands from ARB_conservative_depth (none)">
+ </require>
+ <require comment="Reuse commands from ARB_internalformat_query">
+ <command name="glGetInternalformativ"/>
+ </require>
+ <require comment="Reuse commands from ARB_map_buffer_alignment (none)">
+ </require>
+ <require comment="Reuse commands from ARB_shader_atomic_counters">
+ <command name="glGetActiveAtomicCounterBufferiv"/>
+ </require>
+ <require comment="Reuse commands from ARB_shader_image_load_store">
+ <command name="glBindImageTexture"/>
+ <command name="glMemoryBarrier"/>
+ </require>
+ <require comment="Reuse commands from ARB_shading_language_420pack (none)">
+ </require>
+ <require comment="Reuse commands from ARB_shading_language_packing (none)">
+ </require>
+ <require comment="Reuse commands from ARB_texture_storage">
+ <command name="glTexStorage1D"/>
+ <command name="glTexStorage2D"/>
+ <command name="glTexStorage3D"/>
+ </require>
+ <require comment="Reuse commands from ARB_transform_feedback_instanced">
+ <command name="glDrawTransformFeedbackInstanced"/>
+ <command name="glDrawTransformFeedbackStreamInstanced"/>
+ </require>
+ <!-- Deprecated in OpenGL 4.2 core;
+ deprecate tag not defined/supported yet
+ <deprecate profile="core">
+ <enum name="GL_NUM_COMPRESSED_TEXTURE_FORMATS"/>
+ <enum name="GL_COMPRESSED_TEXTURE_FORMATS"/>
+ </deprecate>
+ -->
+ </feature>
+ <feature api="gl" name="GL_VERSION_4_3" number="4.3">
+ <require>
+ <enum name="GL_NUM_SHADING_LANGUAGE_VERSIONS"/>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY_LONG"/>
+ </require>
+ <require comment="Reuse tokens from ARB_arrays_of_arrays (none, GLSL only)">
+ </require>
+ <require comment="Reuse tokens from ARB_fragment_layer_viewport (none, GLSL only)">
+ </require>
+ <require comment="Reuse tokens from ARB_shader_image_size (none, GLSL only)">
+ </require>
+ <require comment="Reuse tokens from ARB_ES3_compatibility">
+ <enum name="GL_COMPRESSED_RGB8_ETC2"/>
+ <enum name="GL_COMPRESSED_SRGB8_ETC2"/>
+ <enum name="GL_COMPRESSED_RGB8_PUNCHTHROUGH_ALPHA1_ETC2"/>
+ <enum name="GL_COMPRESSED_SRGB8_PUNCHTHROUGH_ALPHA1_ETC2"/>
+ <enum name="GL_COMPRESSED_RGBA8_ETC2_EAC"/>
+ <enum name="GL_COMPRESSED_SRGB8_ALPHA8_ETC2_EAC"/>
+ <enum name="GL_COMPRESSED_R11_EAC"/>
+ <enum name="GL_COMPRESSED_SIGNED_R11_EAC"/>
+ <enum name="GL_COMPRESSED_RG11_EAC"/>
+ <enum name="GL_COMPRESSED_SIGNED_RG11_EAC"/>
+ <enum name="GL_PRIMITIVE_RESTART_FIXED_INDEX"/>
+ <enum name="GL_ANY_SAMPLES_PASSED_CONSERVATIVE"/>
+ <enum name="GL_MAX_ELEMENT_INDEX"/>
+ </require>
+ <require comment="Reuse tokens from ARB_clear_buffer_object (none)">
+ </require>
+ <require comment="Reuse tokens from ARB_compute_shader">
+ <enum name="GL_COMPUTE_SHADER"/>
+ <enum name="GL_MAX_COMPUTE_UNIFORM_BLOCKS"/>
+ <enum name="GL_MAX_COMPUTE_TEXTURE_IMAGE_UNITS"/>
+ <enum name="GL_MAX_COMPUTE_IMAGE_UNIFORMS"/>
+ <enum name="GL_MAX_COMPUTE_SHARED_MEMORY_SIZE"/>
+ <enum name="GL_MAX_COMPUTE_UNIFORM_COMPONENTS"/>
+ <enum name="GL_MAX_COMPUTE_ATOMIC_COUNTER_BUFFERS"/>
+ <enum name="GL_MAX_COMPUTE_ATOMIC_COUNTERS"/>
+ <enum name="GL_MAX_COMBINED_COMPUTE_UNIFORM_COMPONENTS"/>
+ <enum name="GL_MAX_COMPUTE_WORK_GROUP_INVOCATIONS"/>
+ <enum name="GL_MAX_COMPUTE_WORK_GROUP_COUNT"/>
+ <enum name="GL_MAX_COMPUTE_WORK_GROUP_SIZE"/>
+ <enum name="GL_COMPUTE_WORK_GROUP_SIZE"/>
+ <enum name="GL_UNIFORM_BLOCK_REFERENCED_BY_COMPUTE_SHADER"/>
+ <enum name="GL_ATOMIC_COUNTER_BUFFER_REFERENCED_BY_COMPUTE_SHADER"/>
+ <enum name="GL_DISPATCH_INDIRECT_BUFFER"/>
+ <enum name="GL_DISPATCH_INDIRECT_BUFFER_BINDING"/>
+ <enum name="GL_COMPUTE_SHADER_BIT"/>
+ </require>
+ <require comment="Reuse tokens from ARB_copy_image (none)">
+ </require>
+ <require comment="Reuse tokens from KHR_debug">
+ <enum name="GL_DEBUG_OUTPUT_SYNCHRONOUS"/>
+ <enum name="GL_DEBUG_NEXT_LOGGED_MESSAGE_LENGTH"/>
+ <enum name="GL_DEBUG_CALLBACK_FUNCTION"/>
+ <enum name="GL_DEBUG_CALLBACK_USER_PARAM"/>
+ <enum name="GL_DEBUG_SOURCE_API"/>
+ <enum name="GL_DEBUG_SOURCE_WINDOW_SYSTEM"/>
+ <enum name="GL_DEBUG_SOURCE_SHADER_COMPILER"/>
+ <enum name="GL_DEBUG_SOURCE_THIRD_PARTY"/>
+ <enum name="GL_DEBUG_SOURCE_APPLICATION"/>
+ <enum name="GL_DEBUG_SOURCE_OTHER"/>
+ <enum name="GL_DEBUG_TYPE_ERROR"/>
+ <enum name="GL_DEBUG_TYPE_DEPRECATED_BEHAVIOR"/>
+ <enum name="GL_DEBUG_TYPE_UNDEFINED_BEHAVIOR"/>
+ <enum name="GL_DEBUG_TYPE_PORTABILITY"/>
+ <enum name="GL_DEBUG_TYPE_PERFORMANCE"/>
+ <enum name="GL_DEBUG_TYPE_OTHER"/>
+ <enum name="GL_MAX_DEBUG_MESSAGE_LENGTH"/>
+ <enum name="GL_MAX_DEBUG_LOGGED_MESSAGES"/>
+ <enum name="GL_DEBUG_LOGGED_MESSAGES"/>
+ <enum name="GL_DEBUG_SEVERITY_HIGH"/>
+ <enum name="GL_DEBUG_SEVERITY_MEDIUM"/>
+ <enum name="GL_DEBUG_SEVERITY_LOW"/>
+ <enum name="GL_DEBUG_TYPE_MARKER"/>
+ <enum name="GL_DEBUG_TYPE_PUSH_GROUP"/>
+ <enum name="GL_DEBUG_TYPE_POP_GROUP"/>
+ <enum name="GL_DEBUG_SEVERITY_NOTIFICATION"/>
+ <enum name="GL_MAX_DEBUG_GROUP_STACK_DEPTH"/>
+ <enum name="GL_DEBUG_GROUP_STACK_DEPTH"/>
+ <enum name="GL_BUFFER"/>
+ <enum name="GL_SHADER"/>
+ <enum name="GL_PROGRAM"/>
+ <enum name="GL_VERTEX_ARRAY"/>
+ <enum name="GL_QUERY"/>
+ <enum name="GL_PROGRAM_PIPELINE"/>
+ <enum name="GL_SAMPLER"/>
+ <enum name="GL_MAX_LABEL_LENGTH"/>
+ <enum name="GL_DEBUG_OUTPUT"/>
+ <enum name="GL_CONTEXT_FLAG_DEBUG_BIT"/>
+ </require>
+ <require comment="Reuse tokens from ARB_explicit_uniform_location">
+ <enum name="GL_MAX_UNIFORM_LOCATIONS"/>
+ </require>
+ <require comment="Reuse tokens from ARB_framebuffer_no_attachments">
+ <enum name="GL_FRAMEBUFFER_DEFAULT_WIDTH"/>
+ <enum name="GL_FRAMEBUFFER_DEFAULT_HEIGHT"/>
+ <enum name="GL_FRAMEBUFFER_DEFAULT_LAYERS"/>
+ <enum name="GL_FRAMEBUFFER_DEFAULT_SAMPLES"/>
+ <enum name="GL_FRAMEBUFFER_DEFAULT_FIXED_SAMPLE_LOCATIONS"/>
+ <enum name="GL_MAX_FRAMEBUFFER_WIDTH"/>
+ <enum name="GL_MAX_FRAMEBUFFER_HEIGHT"/>
+ <enum name="GL_MAX_FRAMEBUFFER_LAYERS"/>
+ <enum name="GL_MAX_FRAMEBUFFER_SAMPLES"/>
+ </require>
+ <require comment="Reuse tokens from ARB_internalformat_query2">
+ <enum name="GL_INTERNALFORMAT_SUPPORTED"/>
+ <enum name="GL_INTERNALFORMAT_PREFERRED"/>
+ <enum name="GL_INTERNALFORMAT_RED_SIZE"/>
+ <enum name="GL_INTERNALFORMAT_GREEN_SIZE"/>
+ <enum name="GL_INTERNALFORMAT_BLUE_SIZE"/>
+ <enum name="GL_INTERNALFORMAT_ALPHA_SIZE"/>
+ <enum name="GL_INTERNALFORMAT_DEPTH_SIZE"/>
+ <enum name="GL_INTERNALFORMAT_STENCIL_SIZE"/>
+ <enum name="GL_INTERNALFORMAT_SHARED_SIZE"/>
+ <enum name="GL_INTERNALFORMAT_RED_TYPE"/>
+ <enum name="GL_INTERNALFORMAT_GREEN_TYPE"/>
+ <enum name="GL_INTERNALFORMAT_BLUE_TYPE"/>
+ <enum name="GL_INTERNALFORMAT_ALPHA_TYPE"/>
+ <enum name="GL_INTERNALFORMAT_DEPTH_TYPE"/>
+ <enum name="GL_INTERNALFORMAT_STENCIL_TYPE"/>
+ <enum name="GL_MAX_WIDTH"/>
+ <enum name="GL_MAX_HEIGHT"/>
+ <enum name="GL_MAX_DEPTH"/>
+ <enum name="GL_MAX_LAYERS"/>
+ <enum name="GL_MAX_COMBINED_DIMENSIONS"/>
+ <enum name="GL_COLOR_COMPONENTS"/>
+ <enum name="GL_DEPTH_COMPONENTS"/>
+ <enum name="GL_STENCIL_COMPONENTS"/>
+ <enum name="GL_COLOR_RENDERABLE"/>
+ <enum name="GL_DEPTH_RENDERABLE"/>
+ <enum name="GL_STENCIL_RENDERABLE"/>
+ <enum name="GL_FRAMEBUFFER_RENDERABLE"/>
+ <enum name="GL_FRAMEBUFFER_RENDERABLE_LAYERED"/>
+ <enum name="GL_FRAMEBUFFER_BLEND"/>
+ <enum name="GL_READ_PIXELS"/>
+ <enum name="GL_READ_PIXELS_FORMAT"/>
+ <enum name="GL_READ_PIXELS_TYPE"/>
+ <enum name="GL_TEXTURE_IMAGE_FORMAT"/>
+ <enum name="GL_TEXTURE_IMAGE_TYPE"/>
+ <enum name="GL_GET_TEXTURE_IMAGE_FORMAT"/>
+ <enum name="GL_GET_TEXTURE_IMAGE_TYPE"/>
+ <enum name="GL_MIPMAP"/>
+ <enum name="GL_MANUAL_GENERATE_MIPMAP"/>
+ <enum name="GL_AUTO_GENERATE_MIPMAP"/>
+ <enum name="GL_COLOR_ENCODING"/>
+ <enum name="GL_SRGB_READ"/>
+ <enum name="GL_SRGB_WRITE"/>
+ <enum name="GL_FILTER"/>
+ <enum name="GL_VERTEX_TEXTURE"/>
+ <enum name="GL_TESS_CONTROL_TEXTURE"/>
+ <enum name="GL_TESS_EVALUATION_TEXTURE"/>
+ <enum name="GL_GEOMETRY_TEXTURE"/>
+ <enum name="GL_FRAGMENT_TEXTURE"/>
+ <enum name="GL_COMPUTE_TEXTURE"/>
+ <enum name="GL_TEXTURE_SHADOW"/>
+ <enum name="GL_TEXTURE_GATHER"/>
+ <enum name="GL_TEXTURE_GATHER_SHADOW"/>
+ <enum name="GL_SHADER_IMAGE_LOAD"/>
+ <enum name="GL_SHADER_IMAGE_STORE"/>
+ <enum name="GL_SHADER_IMAGE_ATOMIC"/>
+ <enum name="GL_IMAGE_TEXEL_SIZE"/>
+ <enum name="GL_IMAGE_COMPATIBILITY_CLASS"/>
+ <enum name="GL_IMAGE_PIXEL_FORMAT"/>
+ <enum name="GL_IMAGE_PIXEL_TYPE"/>
+ <enum name="GL_SIMULTANEOUS_TEXTURE_AND_DEPTH_TEST"/>
+ <enum name="GL_SIMULTANEOUS_TEXTURE_AND_STENCIL_TEST"/>
+ <enum name="GL_SIMULTANEOUS_TEXTURE_AND_DEPTH_WRITE"/>
+ <enum name="GL_SIMULTANEOUS_TEXTURE_AND_STENCIL_WRITE"/>
+ <enum name="GL_TEXTURE_COMPRESSED_BLOCK_WIDTH"/>
+ <enum name="GL_TEXTURE_COMPRESSED_BLOCK_HEIGHT"/>
+ <enum name="GL_TEXTURE_COMPRESSED_BLOCK_SIZE"/>
+ <enum name="GL_CLEAR_BUFFER"/>
+ <enum name="GL_TEXTURE_VIEW"/>
+ <enum name="GL_VIEW_COMPATIBILITY_CLASS"/>
+ <enum name="GL_FULL_SUPPORT"/>
+ <enum name="GL_CAVEAT_SUPPORT"/>
+ <enum name="GL_IMAGE_CLASS_4_X_32"/>
+ <enum name="GL_IMAGE_CLASS_2_X_32"/>
+ <enum name="GL_IMAGE_CLASS_1_X_32"/>
+ <enum name="GL_IMAGE_CLASS_4_X_16"/>
+ <enum name="GL_IMAGE_CLASS_2_X_16"/>
+ <enum name="GL_IMAGE_CLASS_1_X_16"/>
+ <enum name="GL_IMAGE_CLASS_4_X_8"/>
+ <enum name="GL_IMAGE_CLASS_2_X_8"/>
+ <enum name="GL_IMAGE_CLASS_1_X_8"/>
+ <enum name="GL_IMAGE_CLASS_11_11_10"/>
+ <enum name="GL_IMAGE_CLASS_10_10_10_2"/>
+ <enum name="GL_VIEW_CLASS_128_BITS"/>
+ <enum name="GL_VIEW_CLASS_96_BITS"/>
+ <enum name="GL_VIEW_CLASS_64_BITS"/>
+ <enum name="GL_VIEW_CLASS_48_BITS"/>
+ <enum name="GL_VIEW_CLASS_32_BITS"/>
+ <enum name="GL_VIEW_CLASS_24_BITS"/>
+ <enum name="GL_VIEW_CLASS_16_BITS"/>
+ <enum name="GL_VIEW_CLASS_8_BITS"/>
+ <enum name="GL_VIEW_CLASS_S3TC_DXT1_RGB"/>
+ <enum name="GL_VIEW_CLASS_S3TC_DXT1_RGBA"/>
+ <enum name="GL_VIEW_CLASS_S3TC_DXT3_RGBA"/>
+ <enum name="GL_VIEW_CLASS_S3TC_DXT5_RGBA"/>
+ <enum name="GL_VIEW_CLASS_RGTC1_RED"/>
+ <enum name="GL_VIEW_CLASS_RGTC2_RG"/>
+ <enum name="GL_VIEW_CLASS_BPTC_UNORM"/>
+ <enum name="GL_VIEW_CLASS_BPTC_FLOAT"/>
+ </require>
+ <require comment="Reuse tokens from ARB_invalidate_subdata (none)">
+ </require>
+ <require comment="Reuse tokens from ARB_multi_draw_indirect (none)">
+ </require>
+ <require comment="Reuse tokens from ARB_program_interface_query">
+ <enum name="GL_UNIFORM"/>
+ <enum name="GL_UNIFORM_BLOCK"/>
+ <enum name="GL_PROGRAM_INPUT"/>
+ <enum name="GL_PROGRAM_OUTPUT"/>
+ <enum name="GL_BUFFER_VARIABLE"/>
+ <enum name="GL_SHADER_STORAGE_BLOCK"/>
+ <enum name="GL_VERTEX_SUBROUTINE"/>
+ <enum name="GL_TESS_CONTROL_SUBROUTINE"/>
+ <enum name="GL_TESS_EVALUATION_SUBROUTINE"/>
+ <enum name="GL_GEOMETRY_SUBROUTINE"/>
+ <enum name="GL_FRAGMENT_SUBROUTINE"/>
+ <enum name="GL_COMPUTE_SUBROUTINE"/>
+ <enum name="GL_VERTEX_SUBROUTINE_UNIFORM"/>
+ <enum name="GL_TESS_CONTROL_SUBROUTINE_UNIFORM"/>
+ <enum name="GL_TESS_EVALUATION_SUBROUTINE_UNIFORM"/>
+ <enum name="GL_GEOMETRY_SUBROUTINE_UNIFORM"/>
+ <enum name="GL_FRAGMENT_SUBROUTINE_UNIFORM"/>
+ <enum name="GL_COMPUTE_SUBROUTINE_UNIFORM"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_VARYING"/>
+ <enum name="GL_ACTIVE_RESOURCES"/>
+ <enum name="GL_MAX_NAME_LENGTH"/>
+ <enum name="GL_MAX_NUM_ACTIVE_VARIABLES"/>
+ <enum name="GL_MAX_NUM_COMPATIBLE_SUBROUTINES"/>
+ <enum name="GL_NAME_LENGTH"/>
+ <enum name="GL_TYPE"/>
+ <enum name="GL_ARRAY_SIZE"/>
+ <enum name="GL_OFFSET"/>
+ <enum name="GL_BLOCK_INDEX"/>
+ <enum name="GL_ARRAY_STRIDE"/>
+ <enum name="GL_MATRIX_STRIDE"/>
+ <enum name="GL_IS_ROW_MAJOR"/>
+ <enum name="GL_ATOMIC_COUNTER_BUFFER_INDEX"/>
+ <enum name="GL_BUFFER_BINDING"/>
+ <enum name="GL_BUFFER_DATA_SIZE"/>
+ <enum name="GL_NUM_ACTIVE_VARIABLES"/>
+ <enum name="GL_ACTIVE_VARIABLES"/>
+ <enum name="GL_REFERENCED_BY_VERTEX_SHADER"/>
+ <enum name="GL_REFERENCED_BY_TESS_CONTROL_SHADER"/>
+ <enum name="GL_REFERENCED_BY_TESS_EVALUATION_SHADER"/>
+ <enum name="GL_REFERENCED_BY_GEOMETRY_SHADER"/>
+ <enum name="GL_REFERENCED_BY_FRAGMENT_SHADER"/>
+ <enum name="GL_REFERENCED_BY_COMPUTE_SHADER"/>
+ <enum name="GL_TOP_LEVEL_ARRAY_SIZE"/>
+ <enum name="GL_TOP_LEVEL_ARRAY_STRIDE"/>
+ <enum name="GL_LOCATION"/>
+ <enum name="GL_LOCATION_INDEX"/>
+ <enum name="GL_IS_PER_PATCH"/>
+ </require>
+ <require comment="Reuse tokens from ARB_robust_buffer_access_behavior (none)">
+ </require>
+ <require comment="Reuse tokens from ARB_shader_storage_buffer_object">
+ <enum name="GL_SHADER_STORAGE_BUFFER"/>
+ <enum name="GL_SHADER_STORAGE_BUFFER_BINDING"/>
+ <enum name="GL_SHADER_STORAGE_BUFFER_START"/>
+ <enum name="GL_SHADER_STORAGE_BUFFER_SIZE"/>
+ <enum name="GL_MAX_VERTEX_SHADER_STORAGE_BLOCKS"/>
+ <enum name="GL_MAX_GEOMETRY_SHADER_STORAGE_BLOCKS"/>
+ <enum name="GL_MAX_TESS_CONTROL_SHADER_STORAGE_BLOCKS"/>
+ <enum name="GL_MAX_TESS_EVALUATION_SHADER_STORAGE_BLOCKS"/>
+ <enum name="GL_MAX_FRAGMENT_SHADER_STORAGE_BLOCKS"/>
+ <enum name="GL_MAX_COMPUTE_SHADER_STORAGE_BLOCKS"/>
+ <enum name="GL_MAX_COMBINED_SHADER_STORAGE_BLOCKS"/>
+ <enum name="GL_MAX_SHADER_STORAGE_BUFFER_BINDINGS"/>
+ <enum name="GL_MAX_SHADER_STORAGE_BLOCK_SIZE"/>
+ <enum name="GL_SHADER_STORAGE_BUFFER_OFFSET_ALIGNMENT"/>
+ <enum name="GL_SHADER_STORAGE_BARRIER_BIT"/>
+ <enum name="GL_MAX_COMBINED_SHADER_OUTPUT_RESOURCES"/>
+ </require>
+ <require comment="Reuse tokens from ARB_stencil_texturing">
+ <enum name="GL_DEPTH_STENCIL_TEXTURE_MODE"/>
+ </require>
+ <require comment="Reuse tokens from ARB_texture_buffer_range">
+ <enum name="GL_TEXTURE_BUFFER_OFFSET"/>
+ <enum name="GL_TEXTURE_BUFFER_SIZE"/>
+ <enum name="GL_TEXTURE_BUFFER_OFFSET_ALIGNMENT"/>
+ </require>
+ <require comment="Reuse tokens from ARB_texture_query_levels (none)">
+ </require>
+ <require comment="Reuse tokens from ARB_texture_storage_multisample (none)">
+ </require>
+ <require comment="Reuse tokens from ARB_texture_view">
+ <enum name="GL_TEXTURE_VIEW_MIN_LEVEL"/>
+ <enum name="GL_TEXTURE_VIEW_NUM_LEVELS"/>
+ <enum name="GL_TEXTURE_VIEW_MIN_LAYER"/>
+ <enum name="GL_TEXTURE_VIEW_NUM_LAYERS"/>
+ <enum name="GL_TEXTURE_IMMUTABLE_LEVELS"/>
+ </require>
+ <require comment="Reuse tokens from ARB_vertex_attrib_binding">
+ <enum name="GL_VERTEX_ATTRIB_BINDING"/>
+ <enum name="GL_VERTEX_ATTRIB_RELATIVE_OFFSET"/>
+ <enum name="GL_VERTEX_BINDING_DIVISOR"/>
+ <enum name="GL_VERTEX_BINDING_OFFSET"/>
+ <enum name="GL_VERTEX_BINDING_STRIDE"/>
+ <enum name="GL_MAX_VERTEX_ATTRIB_RELATIVE_OFFSET"/>
+ <enum name="GL_MAX_VERTEX_ATTRIB_BINDINGS"/>
+ <enum name="GL_VERTEX_BINDING_BUFFER" comment="Added in 2013/10/22 update to the spec"/>
+ </require>
+ <require comment="Reuse commands from ARB_arrays_of_arrays (none, GLSL only)">
+ </require>
+ <require comment="Reuse commands from ARB_clear_buffer_object">
+ <command name="glClearBufferData"/>
+ <command name="glClearBufferSubData"/>
+ </require>
+ <require comment="Reuse commands from ARB_compute_shader">
+ <command name="glDispatchCompute"/>
+ <command name="glDispatchComputeIndirect"/>
+ </require>
+ <require comment="Reuse commands from ARB_copy_image">
+ <command name="glCopyImageSubData"/>
+ </require>
+ <require comment="Reuse commands from ARB_ES3_compatibility (none)">
+ </require>
+ <require comment="Reuse commands from ARB_explicit_uniform_location (none)">
+ </require>
+ <require comment="Reuse commands from ARB_fragment_layer_viewport (none, GLSL only)">
+ </require>
+ <require comment="Reuse commands from ARB_framebuffer_no_attachments">
+ <command name="glFramebufferParameteri"/>
+ <command name="glGetFramebufferParameteriv"/>
+ </require>
+ <require comment="Reuse commands from ARB_internalformat_query2">
+ <command name="glGetInternalformati64v"/>
+ </require>
+ <require comment="Reuse commands from ARB_invalidate_subdata">
+ <command name="glInvalidateTexSubImage"/>
+ <command name="glInvalidateTexImage"/>
+ <command name="glInvalidateBufferSubData"/>
+ <command name="glInvalidateBufferData"/>
+ <command name="glInvalidateFramebuffer"/>
+ <command name="glInvalidateSubFramebuffer"/>
+ </require>
+ <require comment="Reuse commands from ARB_multi_draw_indirect">
+ <command name="glMultiDrawArraysIndirect"/>
+ <command name="glMultiDrawElementsIndirect"/>
+ </require>
+ <require comment="Reuse commands from ARB_program_interface_query">
+ <command name="glGetProgramInterfaceiv"/>
+ <command name="glGetProgramResourceIndex"/>
+ <command name="glGetProgramResourceName"/>
+ <command name="glGetProgramResourceiv"/>
+ <command name="glGetProgramResourceLocation"/>
+ <command name="glGetProgramResourceLocationIndex"/>
+ </require>
+ <require comment="Reuse commands from ARB_robust_buffer_access_behavior (none)">
+ </require>
+ <require comment="Reuse commands from ARB_shader_image_size (none, GLSL only)">
+ </require>
+ <require comment="Reuse commands from ARB_shader_storage_buffer_object">
+ <command name="glShaderStorageBlockBinding"/>
+ </require>
+ <require comment="Reuse commands from ARB_stencil_texturing (none)">
+ </require>
+ <require comment="Reuse commands from ARB_texture_buffer_range">
+ <command name="glTexBufferRange"/>
+ </require>
+ <require comment="Reuse commands from ARB_texture_query_levels (none)">
+ </require>
+ <require comment="Reuse commands from ARB_texture_storage_multisample">
+ <command name="glTexStorage2DMultisample"/>
+ <command name="glTexStorage3DMultisample"/>
+ </require>
+ <require comment="Reuse commands from ARB_texture_view">
+ <command name="glTextureView"/>
+ </require>
+ <require comment="Reuse commands from ARB_vertex_attrib_binding">
+ <command name="glBindVertexBuffer"/>
+ <command name="glVertexAttribFormat"/>
+ <command name="glVertexAttribIFormat"/>
+ <command name="glVertexAttribLFormat"/>
+ <command name="glVertexAttribBinding"/>
+ <command name="glVertexBindingDivisor"/>
+ </require>
+ <require comment="Reuse commands from KHR_debug (includes ARB_debug_output commands promoted to KHR without suffixes)">
+ <command name="glDebugMessageControl"/>
+ <command name="glDebugMessageInsert"/>
+ <command name="glDebugMessageCallback"/>
+ <command name="glGetDebugMessageLog"/>
+ <command name="glPushDebugGroup"/>
+ <command name="glPopDebugGroup"/>
+ <command name="glObjectLabel"/>
+ <command name="glGetObjectLabel"/>
+ <command name="glObjectPtrLabel"/>
+ <command name="glGetObjectPtrLabel"/>
+ <command name="glGetPointerv"/>
+ </require>
+ <require profile="compatibility" comment="KHR_debug functionality not supported in core profile">
+ <enum name="GL_DISPLAY_LIST"/>
+ </require>
+ <require profile="core" comment="Restore functionality removed in GL 3.2 core to GL 4.3. Needed for debug interface.">
+ <enum name="GL_STACK_UNDERFLOW"/>
+ <enum name="GL_STACK_OVERFLOW"/>
+ <command name="glGetPointerv"/>
+ </require>
+ <!-- Deprecated in OpenGL 4.3 core;
+ deprecate tag not defined/supported yet
+ <deprecate profile="core">
+ <enum name="GL_UNPACK_LSB_FIRST"/>
+ <enum name="GL_PACK_LSB_FIRST"/>
+ </deprecate>
+ -->
+ </feature>
+ <feature api="gl" name="GL_VERSION_4_4" number="4.4">
+ <require>
+ <enum name="GL_MAX_VERTEX_ATTRIB_STRIDE"/>
+ <enum name="GL_PRIMITIVE_RESTART_FOR_PATCHES_SUPPORTED"/>
+ <enum name="GL_TEXTURE_BUFFER_BINDING"/>
+ </require>
+ <require comment="Reuse GL_ARB_buffer_storage">
+ <enum name="GL_MAP_READ_BIT"/>
+ <enum name="GL_MAP_WRITE_BIT"/>
+ <enum name="GL_MAP_PERSISTENT_BIT"/>
+ <enum name="GL_MAP_COHERENT_BIT"/>
+ <enum name="GL_DYNAMIC_STORAGE_BIT"/>
+ <enum name="GL_CLIENT_STORAGE_BIT"/>
+ <enum name="GL_CLIENT_MAPPED_BUFFER_BARRIER_BIT"/>
+ <enum name="GL_BUFFER_IMMUTABLE_STORAGE"/>
+ <enum name="GL_BUFFER_STORAGE_FLAGS"/>
+ <command name="glBufferStorage"/>
+ </require>
+ <require comment="Reuse GL_ARB_clear_texture">
+ <enum name="GL_CLEAR_TEXTURE"/>
+ <command name="glClearTexImage"/>
+ <command name="glClearTexSubImage"/>
+ </require>
+ <require comment="Reuse GL_ARB_enhanced_layouts">
+ <enum name="GL_LOCATION_COMPONENT"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_BUFFER"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_BUFFER_INDEX"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_BUFFER_STRIDE"/>
+ </require>
+ <require comment="Reuse GL_ARB_multi_bind (none)">
+ <command name="glBindBuffersBase"/>
+ <command name="glBindBuffersRange"/>
+ <command name="glBindTextures"/>
+ <command name="glBindSamplers"/>
+ <command name="glBindImageTextures"/>
+ <command name="glBindVertexBuffers"/>
+ </require>
+ <require comment="Reuse GL_ARB_query_buffer_object">
+ <enum name="GL_QUERY_BUFFER"/>
+ <enum name="GL_QUERY_BUFFER_BARRIER_BIT"/>
+ <enum name="GL_QUERY_BUFFER_BINDING"/>
+ <enum name="GL_QUERY_RESULT_NO_WAIT"/>
+ </require>
+ <require comment="Reuse GL_ARB_texture_mirror_clamp_to_edge">
+ <enum name="GL_MIRROR_CLAMP_TO_EDGE"/>
+ </require>
+ <require comment="Reuse GL_ARB_texture_stencil8">
+ <enum name="GL_STENCIL_INDEX"/>
+ <enum name="GL_STENCIL_INDEX8"/>
+ </require>
+ <require comment="Reuse GL_ARB_vertex_type_10f_11f_11f_rev">
+ <enum name="GL_UNSIGNED_INT_10F_11F_11F_REV"/>
+ </require>
+ </feature>
+ <feature api="gl" name="GL_VERSION_4_5" number="4.5">
+ <require comment="Added robustness functionality">
+ <enum name="GL_CONTEXT_LOST"/>
+ </require>
+ <require comment="Reuse GL_ARB_clip_control">
+ <command name="glClipControl"/>
+ <enum name="GL_LOWER_LEFT"/>
+ <enum name="GL_UPPER_LEFT"/>
+ <enum name="GL_NEGATIVE_ONE_TO_ONE"/>
+ <enum name="GL_ZERO_TO_ONE"/>
+ <enum name="GL_CLIP_ORIGIN"/>
+ <enum name="GL_CLIP_DEPTH_MODE"/>
+ </require>
+ <require comment="Reuse GL_ARB_conditional_render_inverted">
+ <enum name="GL_QUERY_WAIT_INVERTED"/>
+ <enum name="GL_QUERY_NO_WAIT_INVERTED"/>
+ <enum name="GL_QUERY_BY_REGION_WAIT_INVERTED"/>
+ <enum name="GL_QUERY_BY_REGION_NO_WAIT_INVERTED"/>
+ </require>
+ <require comment="Reuse GL_ARB_cull_distance">
+ <enum name="GL_MAX_CULL_DISTANCES"/>
+ <enum name="GL_MAX_COMBINED_CLIP_AND_CULL_DISTANCES"/>
+ </require>
+ <require comment="Reuse GL_ARB_direct_state_access">
+ <enum name="GL_TEXTURE_TARGET"/>
+ <enum name="GL_QUERY_TARGET"/>
+ <enum name="GL_TEXTURE_BINDING_1D"/>
+ <enum name="GL_TEXTURE_BINDING_1D_ARRAY"/>
+ <enum name="GL_TEXTURE_BINDING_2D"/>
+ <enum name="GL_TEXTURE_BINDING_2D_ARRAY"/>
+ <enum name="GL_TEXTURE_BINDING_2D_MULTISAMPLE"/>
+ <enum name="GL_TEXTURE_BINDING_2D_MULTISAMPLE_ARRAY"/>
+ <enum name="GL_TEXTURE_BINDING_3D"/>
+ <enum name="GL_TEXTURE_BINDING_BUFFER"/>
+ <enum name="GL_TEXTURE_BINDING_CUBE_MAP"/>
+ <enum name="GL_TEXTURE_BINDING_CUBE_MAP_ARRAY"/>
+ <enum name="GL_TEXTURE_BINDING_RECTANGLE"/>
+ <enum name="GL_TEXTURE_BINDING"/>
+ <command name="glCreateTransformFeedbacks"/>
+ <command name="glTransformFeedbackBufferBase"/>
+ <command name="glTransformFeedbackBufferRange"/>
+ <command name="glGetTransformFeedbackiv"/>
+ <command name="glGetTransformFeedbacki_v"/>
+ <command name="glGetTransformFeedbacki64_v"/>
+ <command name="glCreateBuffers"/>
+ <command name="glNamedBufferStorage"/>
+ <command name="glNamedBufferData"/>
+ <command name="glNamedBufferSubData"/>
+ <command name="glCopyNamedBufferSubData"/>
+ <command name="glClearNamedBufferData"/>
+ <command name="glClearNamedBufferSubData"/>
+ <command name="glMapNamedBuffer"/>
+ <command name="glMapNamedBufferRange"/>
+ <command name="glUnmapNamedBuffer"/>
+ <command name="glFlushMappedNamedBufferRange"/>
+ <command name="glGetNamedBufferParameteriv"/>
+ <command name="glGetNamedBufferParameteri64v"/>
+ <command name="glGetNamedBufferPointerv"/>
+ <command name="glGetNamedBufferSubData"/>
+ <command name="glCreateFramebuffers"/>
+ <command name="glNamedFramebufferRenderbuffer"/>
+ <command name="glNamedFramebufferParameteri"/>
+ <command name="glNamedFramebufferTexture"/>
+ <command name="glNamedFramebufferTextureLayer"/>
+ <command name="glNamedFramebufferDrawBuffer"/>
+ <command name="glNamedFramebufferDrawBuffers"/>
+ <command name="glNamedFramebufferReadBuffer"/>
+ <command name="glInvalidateNamedFramebufferData"/>
+ <command name="glInvalidateNamedFramebufferSubData"/>
+ <command name="glClearNamedFramebufferiv"/>
+ <command name="glClearNamedFramebufferuiv"/>
+ <command name="glClearNamedFramebufferfv"/>
+ <command name="glClearNamedFramebufferfi"/>
+ <command name="glBlitNamedFramebuffer"/>
+ <command name="glCheckNamedFramebufferStatus"/>
+ <command name="glGetNamedFramebufferParameteriv"/>
+ <command name="glGetNamedFramebufferAttachmentParameteriv"/>
+ <command name="glCreateRenderbuffers"/>
+ <command name="glNamedRenderbufferStorage"/>
+ <command name="glNamedRenderbufferStorageMultisample"/>
+ <command name="glGetNamedRenderbufferParameteriv"/>
+ <command name="glCreateTextures"/>
+ <command name="glTextureBuffer"/>
+ <command name="glTextureBufferRange"/>
+ <command name="glTextureStorage1D"/>
+ <command name="glTextureStorage2D"/>
+ <command name="glTextureStorage3D"/>
+ <command name="glTextureStorage2DMultisample"/>
+ <command name="glTextureStorage3DMultisample"/>
+ <command name="glTextureSubImage1D"/>
+ <command name="glTextureSubImage2D"/>
+ <command name="glTextureSubImage3D"/>
+ <command name="glCompressedTextureSubImage1D"/>
+ <command name="glCompressedTextureSubImage2D"/>
+ <command name="glCompressedTextureSubImage3D"/>
+ <command name="glCopyTextureSubImage1D"/>
+ <command name="glCopyTextureSubImage2D"/>
+ <command name="glCopyTextureSubImage3D"/>
+ <command name="glTextureParameterf"/>
+ <command name="glTextureParameterfv"/>
+ <command name="glTextureParameteri"/>
+ <command name="glTextureParameterIiv"/>
+ <command name="glTextureParameterIuiv"/>
+ <command name="glTextureParameteriv"/>
+ <command name="glGenerateTextureMipmap"/>
+ <command name="glBindTextureUnit"/>
+ <command name="glGetTextureImage"/>
+ <command name="glGetCompressedTextureImage"/>
+ <command name="glGetTextureLevelParameterfv"/>
+ <command name="glGetTextureLevelParameteriv"/>
+ <command name="glGetTextureParameterfv"/>
+ <command name="glGetTextureParameterIiv"/>
+ <command name="glGetTextureParameterIuiv"/>
+ <command name="glGetTextureParameteriv"/>
+ <command name="glCreateVertexArrays"/>
+ <command name="glDisableVertexArrayAttrib"/>
+ <command name="glEnableVertexArrayAttrib"/>
+ <command name="glVertexArrayElementBuffer"/>
+ <command name="glVertexArrayVertexBuffer"/>
+ <command name="glVertexArrayVertexBuffers"/>
+ <command name="glVertexArrayAttribBinding"/>
+ <command name="glVertexArrayAttribFormat"/>
+ <command name="glVertexArrayAttribIFormat"/>
+ <command name="glVertexArrayAttribLFormat"/>
+ <command name="glVertexArrayBindingDivisor"/>
+ <command name="glGetVertexArrayiv"/>
+ <command name="glGetVertexArrayIndexediv"/>
+ <command name="glGetVertexArrayIndexed64iv"/>
+ <command name="glCreateSamplers"/>
+ <command name="glCreateProgramPipelines"/>
+ <command name="glCreateQueries"/>
+ </require>
+ <require comment="Reuse GL_ARB_ES3_1_compatibility">
+ <command name="glMemoryBarrierByRegion"/>
+ </require>
+ <require comment="Reuse GL_ARB_get_texture_sub_image">
+ <command name="glGetTextureSubImage"/>
+ <command name="glGetCompressedTextureSubImage"/>
+ </require>
+ <require comment="Reuse GL_ARB_robustness">
+ <enum name="GL_NO_ERROR"/>
+ <enum name="GL_GUILTY_CONTEXT_RESET"/>
+ <enum name="GL_INNOCENT_CONTEXT_RESET"/>
+ <enum name="GL_UNKNOWN_CONTEXT_RESET"/>
+ <enum name="GL_RESET_NOTIFICATION_STRATEGY"/>
+ <enum name="GL_LOSE_CONTEXT_ON_RESET"/>
+ <enum name="GL_NO_RESET_NOTIFICATION"/>
+ <enum name="GL_CONTEXT_FLAG_ROBUST_ACCESS_BIT"/>
+ <enum name="GL_CONTEXT_LOST"/>
+ <command name="glGetGraphicsResetStatus"/>
+ <command name="glGetnCompressedTexImage"/>
+ <command name="glGetnTexImage"/>
+ <command name="glGetnUniformdv"/>
+ <command name="glGetnUniformfv"/>
+ <command name="glGetnUniformiv"/>
+ <command name="glGetnUniformuiv"/>
+ <command name="glReadnPixels"/>
+ </require>
+ <require profile="compatibility" comment="Reuse GL_ARB_robustness">
+ <command name="glGetnMapdv"/>
+ <command name="glGetnMapfv"/>
+ <command name="glGetnMapiv"/>
+ <command name="glGetnPixelMapfv"/>
+ <command name="glGetnPixelMapuiv"/>
+ <command name="glGetnPixelMapusv"/>
+ <command name="glGetnPolygonStipple"/>
+ <command name="glGetnColorTable"/>
+ <command name="glGetnConvolutionFilter"/>
+ <command name="glGetnSeparableFilter"/>
+ <command name="glGetnHistogram"/>
+ <command name="glGetnMinmax"/>
+ </require>
+ <require comment="Reuse GL_ARB_texture_barrier">
+ <command name="glTextureBarrier"/>
+ </require>
+ <require comment="Reuse GL_KHR_context_flush_control">
+ <enum name="GL_CONTEXT_RELEASE_BEHAVIOR"/>
+ <enum name="GL_NONE"/>
+ <enum name="GL_CONTEXT_RELEASE_BEHAVIOR_FLUSH"/>
+ </require>
+ </feature>
+
+ <!-- SECTION: OpenGL ES 1.0/1.1 API interface definitions. -->
+ <feature api="gles1" name="GL_VERSION_ES_CM_1_0" number="1.0">
+ <require>
+ <!-- Additional API definition macros - ES 1.0/1.1, common/common-lite all in one header -->
+ <enum name="GL_VERSION_ES_CL_1_0"/>
+ <enum name="GL_VERSION_ES_CM_1_1"/>
+ <enum name="GL_VERSION_ES_CL_1_1"/>
+ <type name="GLvoid" comment="No longer used in headers"/>
+ <enum name="GL_DEPTH_BUFFER_BIT"/>
+ <enum name="GL_STENCIL_BUFFER_BIT"/>
+ <enum name="GL_COLOR_BUFFER_BIT"/>
+ <enum name="GL_FALSE"/>
+ <enum name="GL_TRUE"/>
+ <enum name="GL_POINTS"/>
+ <enum name="GL_LINES"/>
+ <enum name="GL_LINE_LOOP"/>
+ <enum name="GL_LINE_STRIP"/>
+ <enum name="GL_TRIANGLES"/>
+ <enum name="GL_TRIANGLE_STRIP"/>
+ <enum name="GL_TRIANGLE_FAN"/>
+ <enum name="GL_NEVER"/>
+ <enum name="GL_LESS"/>
+ <enum name="GL_EQUAL"/>
+ <enum name="GL_LEQUAL"/>
+ <enum name="GL_GREATER"/>
+ <enum name="GL_NOTEQUAL"/>
+ <enum name="GL_GEQUAL"/>
+ <enum name="GL_ALWAYS"/>
+ <enum name="GL_ZERO"/>
+ <enum name="GL_ONE"/>
+ <enum name="GL_SRC_COLOR"/>
+ <enum name="GL_ONE_MINUS_SRC_COLOR"/>
+ <enum name="GL_SRC_ALPHA"/>
+ <enum name="GL_ONE_MINUS_SRC_ALPHA"/>
+ <enum name="GL_DST_ALPHA"/>
+ <enum name="GL_ONE_MINUS_DST_ALPHA"/>
+ <enum name="GL_DST_COLOR"/>
+ <enum name="GL_ONE_MINUS_DST_COLOR"/>
+ <enum name="GL_SRC_ALPHA_SATURATE"/>
+ <enum name="GL_CLIP_PLANE0"/>
+ <enum name="GL_CLIP_PLANE1"/>
+ <enum name="GL_CLIP_PLANE2"/>
+ <enum name="GL_CLIP_PLANE3"/>
+ <enum name="GL_CLIP_PLANE4"/>
+ <enum name="GL_CLIP_PLANE5"/>
+ <enum name="GL_FRONT"/>
+ <enum name="GL_BACK"/>
+ <enum name="GL_FRONT_AND_BACK"/>
+ <enum name="GL_FOG"/>
+ <enum name="GL_LIGHTING"/>
+ <enum name="GL_TEXTURE_2D"/>
+ <enum name="GL_CULL_FACE"/>
+ <enum name="GL_ALPHA_TEST"/>
+ <enum name="GL_BLEND"/>
+ <enum name="GL_COLOR_LOGIC_OP"/>
+ <enum name="GL_DITHER"/>
+ <enum name="GL_STENCIL_TEST"/>
+ <enum name="GL_DEPTH_TEST"/>
+ <enum name="GL_POINT_SMOOTH"/>
+ <enum name="GL_LINE_SMOOTH"/>
+ <enum name="GL_SCISSOR_TEST"/>
+ <enum name="GL_COLOR_MATERIAL"/>
+ <enum name="GL_NORMALIZE"/>
+ <enum name="GL_RESCALE_NORMAL"/>
+ <enum name="GL_VERTEX_ARRAY"/>
+ <enum name="GL_NORMAL_ARRAY"/>
+ <enum name="GL_COLOR_ARRAY"/>
+ <enum name="GL_TEXTURE_COORD_ARRAY"/>
+ <enum name="GL_MULTISAMPLE"/>
+ <enum name="GL_SAMPLE_ALPHA_TO_COVERAGE"/>
+ <enum name="GL_SAMPLE_ALPHA_TO_ONE"/>
+ <enum name="GL_SAMPLE_COVERAGE"/>
+ <enum name="GL_NO_ERROR"/>
+ <enum name="GL_INVALID_ENUM"/>
+ <enum name="GL_INVALID_VALUE"/>
+ <enum name="GL_INVALID_OPERATION"/>
+ <enum name="GL_STACK_OVERFLOW"/>
+ <enum name="GL_STACK_UNDERFLOW"/>
+ <enum name="GL_OUT_OF_MEMORY"/>
+ <enum name="GL_EXP"/>
+ <enum name="GL_EXP2"/>
+ <enum name="GL_FOG_DENSITY"/>
+ <enum name="GL_FOG_START"/>
+ <enum name="GL_FOG_END"/>
+ <enum name="GL_FOG_MODE"/>
+ <enum name="GL_FOG_COLOR"/>
+ <enum name="GL_CW"/>
+ <enum name="GL_CCW"/>
+ <enum name="GL_CURRENT_COLOR"/>
+ <enum name="GL_CURRENT_NORMAL"/>
+ <enum name="GL_CURRENT_TEXTURE_COORDS"/>
+ <enum name="GL_POINT_SIZE"/>
+ <enum name="GL_POINT_SIZE_MIN"/>
+ <enum name="GL_POINT_SIZE_MAX"/>
+ <enum name="GL_POINT_FADE_THRESHOLD_SIZE"/>
+ <enum name="GL_POINT_DISTANCE_ATTENUATION"/>
+ <enum name="GL_SMOOTH_POINT_SIZE_RANGE"/>
+ <enum name="GL_LINE_WIDTH"/>
+ <enum name="GL_SMOOTH_LINE_WIDTH_RANGE"/>
+ <enum name="GL_ALIASED_POINT_SIZE_RANGE"/>
+ <enum name="GL_ALIASED_LINE_WIDTH_RANGE"/>
+ <enum name="GL_CULL_FACE_MODE"/>
+ <enum name="GL_FRONT_FACE"/>
+ <enum name="GL_SHADE_MODEL"/>
+ <enum name="GL_DEPTH_RANGE"/>
+ <enum name="GL_DEPTH_WRITEMASK"/>
+ <enum name="GL_DEPTH_CLEAR_VALUE"/>
+ <enum name="GL_DEPTH_FUNC"/>
+ <enum name="GL_STENCIL_CLEAR_VALUE"/>
+ <enum name="GL_STENCIL_FUNC"/>
+ <enum name="GL_STENCIL_VALUE_MASK"/>
+ <enum name="GL_STENCIL_FAIL"/>
+ <enum name="GL_STENCIL_PASS_DEPTH_FAIL"/>
+ <enum name="GL_STENCIL_PASS_DEPTH_PASS"/>
+ <enum name="GL_STENCIL_REF"/>
+ <enum name="GL_STENCIL_WRITEMASK"/>
+ <enum name="GL_MATRIX_MODE"/>
+ <enum name="GL_VIEWPORT"/>
+ <enum name="GL_MODELVIEW_STACK_DEPTH"/>
+ <enum name="GL_PROJECTION_STACK_DEPTH"/>
+ <enum name="GL_TEXTURE_STACK_DEPTH"/>
+ <enum name="GL_MODELVIEW_MATRIX"/>
+ <enum name="GL_PROJECTION_MATRIX"/>
+ <enum name="GL_TEXTURE_MATRIX"/>
+ <enum name="GL_ALPHA_TEST_FUNC"/>
+ <enum name="GL_ALPHA_TEST_REF"/>
+ <enum name="GL_BLEND_DST"/>
+ <enum name="GL_BLEND_SRC"/>
+ <enum name="GL_LOGIC_OP_MODE"/>
+ <enum name="GL_SCISSOR_BOX"/>
+ <enum name="GL_COLOR_CLEAR_VALUE"/>
+ <enum name="GL_COLOR_WRITEMASK"/>
+ <enum name="GL_MAX_LIGHTS"/>
+ <enum name="GL_MAX_CLIP_PLANES"/>
+ <enum name="GL_MAX_TEXTURE_SIZE"/>
+ <enum name="GL_MAX_MODELVIEW_STACK_DEPTH"/>
+ <enum name="GL_MAX_PROJECTION_STACK_DEPTH"/>
+ <enum name="GL_MAX_TEXTURE_STACK_DEPTH"/>
+ <enum name="GL_MAX_VIEWPORT_DIMS"/>
+ <enum name="GL_MAX_TEXTURE_UNITS"/>
+ <enum name="GL_SUBPIXEL_BITS"/>
+ <enum name="GL_RED_BITS"/>
+ <enum name="GL_GREEN_BITS"/>
+ <enum name="GL_BLUE_BITS"/>
+ <enum name="GL_ALPHA_BITS"/>
+ <enum name="GL_DEPTH_BITS"/>
+ <enum name="GL_STENCIL_BITS"/>
+ <enum name="GL_POLYGON_OFFSET_UNITS"/>
+ <enum name="GL_POLYGON_OFFSET_FILL"/>
+ <enum name="GL_POLYGON_OFFSET_FACTOR"/>
+ <enum name="GL_TEXTURE_BINDING_2D"/>
+ <enum name="GL_VERTEX_ARRAY_SIZE"/>
+ <enum name="GL_VERTEX_ARRAY_TYPE"/>
+ <enum name="GL_VERTEX_ARRAY_STRIDE"/>
+ <enum name="GL_NORMAL_ARRAY_TYPE"/>
+ <enum name="GL_NORMAL_ARRAY_STRIDE"/>
+ <enum name="GL_COLOR_ARRAY_SIZE"/>
+ <enum name="GL_COLOR_ARRAY_TYPE"/>
+ <enum name="GL_COLOR_ARRAY_STRIDE"/>
+ <enum name="GL_TEXTURE_COORD_ARRAY_SIZE"/>
+ <enum name="GL_TEXTURE_COORD_ARRAY_TYPE"/>
+ <enum name="GL_TEXTURE_COORD_ARRAY_STRIDE"/>
+ <enum name="GL_VERTEX_ARRAY_POINTER"/>
+ <enum name="GL_NORMAL_ARRAY_POINTER"/>
+ <enum name="GL_COLOR_ARRAY_POINTER"/>
+ <enum name="GL_TEXTURE_COORD_ARRAY_POINTER"/>
+ <enum name="GL_SAMPLE_BUFFERS"/>
+ <enum name="GL_SAMPLES"/>
+ <enum name="GL_SAMPLE_COVERAGE_VALUE"/>
+ <enum name="GL_SAMPLE_COVERAGE_INVERT"/>
+ <enum name="GL_NUM_COMPRESSED_TEXTURE_FORMATS"/>
+ <enum name="GL_COMPRESSED_TEXTURE_FORMATS"/>
+ <enum name="GL_DONT_CARE"/>
+ <enum name="GL_FASTEST"/>
+ <enum name="GL_NICEST"/>
+ <enum name="GL_PERSPECTIVE_CORRECTION_HINT"/>
+ <enum name="GL_POINT_SMOOTH_HINT"/>
+ <enum name="GL_LINE_SMOOTH_HINT"/>
+ <enum name="GL_FOG_HINT"/>
+ <enum name="GL_GENERATE_MIPMAP_HINT"/>
+ <enum name="GL_LIGHT_MODEL_AMBIENT"/>
+ <enum name="GL_LIGHT_MODEL_TWO_SIDE"/>
+ <enum name="GL_AMBIENT"/>
+ <enum name="GL_DIFFUSE"/>
+ <enum name="GL_SPECULAR"/>
+ <enum name="GL_POSITION"/>
+ <enum name="GL_SPOT_DIRECTION"/>
+ <enum name="GL_SPOT_EXPONENT"/>
+ <enum name="GL_SPOT_CUTOFF"/>
+ <enum name="GL_CONSTANT_ATTENUATION"/>
+ <enum name="GL_LINEAR_ATTENUATION"/>
+ <enum name="GL_QUADRATIC_ATTENUATION"/>
+ <enum name="GL_BYTE"/>
+ <enum name="GL_UNSIGNED_BYTE"/>
+ <enum name="GL_SHORT"/>
+ <enum name="GL_UNSIGNED_SHORT"/>
+ <enum name="GL_FLOAT"/>
+ <enum name="GL_FIXED"/>
+ <enum name="GL_CLEAR"/>
+ <enum name="GL_AND"/>
+ <enum name="GL_AND_REVERSE"/>
+ <enum name="GL_COPY"/>
+ <enum name="GL_AND_INVERTED"/>
+ <enum name="GL_NOOP"/>
+ <enum name="GL_XOR"/>
+ <enum name="GL_OR"/>
+ <enum name="GL_NOR"/>
+ <enum name="GL_EQUIV"/>
+ <enum name="GL_INVERT"/>
+ <enum name="GL_OR_REVERSE"/>
+ <enum name="GL_COPY_INVERTED"/>
+ <enum name="GL_OR_INVERTED"/>
+ <enum name="GL_NAND"/>
+ <enum name="GL_SET"/>
+ <enum name="GL_EMISSION"/>
+ <enum name="GL_SHININESS"/>
+ <enum name="GL_AMBIENT_AND_DIFFUSE"/>
+ <enum name="GL_MODELVIEW"/>
+ <enum name="GL_PROJECTION"/>
+ <enum name="GL_TEXTURE"/>
+ <enum name="GL_ALPHA"/>
+ <enum name="GL_RGB"/>
+ <enum name="GL_RGBA"/>
+ <enum name="GL_LUMINANCE"/>
+ <enum name="GL_LUMINANCE_ALPHA"/>
+ <enum name="GL_UNPACK_ALIGNMENT"/>
+ <enum name="GL_PACK_ALIGNMENT"/>
+ <enum name="GL_UNSIGNED_SHORT_4_4_4_4"/>
+ <enum name="GL_UNSIGNED_SHORT_5_5_5_1"/>
+ <enum name="GL_UNSIGNED_SHORT_5_6_5"/>
+ <enum name="GL_FLAT"/>
+ <enum name="GL_SMOOTH"/>
+ <enum name="GL_KEEP"/>
+ <enum name="GL_REPLACE"/>
+ <enum name="GL_INCR"/>
+ <enum name="GL_DECR"/>
+ <enum name="GL_VENDOR"/>
+ <enum name="GL_RENDERER"/>
+ <enum name="GL_VERSION"/>
+ <enum name="GL_EXTENSIONS"/>
+ <enum name="GL_MODULATE"/>
+ <enum name="GL_DECAL"/>
+ <enum name="GL_ADD"/>
+ <enum name="GL_TEXTURE_ENV_MODE"/>
+ <enum name="GL_TEXTURE_ENV_COLOR"/>
+ <enum name="GL_TEXTURE_ENV"/>
+ <enum name="GL_NEAREST"/>
+ <enum name="GL_LINEAR"/>
+ <enum name="GL_NEAREST_MIPMAP_NEAREST"/>
+ <enum name="GL_LINEAR_MIPMAP_NEAREST"/>
+ <enum name="GL_NEAREST_MIPMAP_LINEAR"/>
+ <enum name="GL_LINEAR_MIPMAP_LINEAR"/>
+ <enum name="GL_TEXTURE_MAG_FILTER"/>
+ <enum name="GL_TEXTURE_MIN_FILTER"/>
+ <enum name="GL_TEXTURE_WRAP_S"/>
+ <enum name="GL_TEXTURE_WRAP_T"/>
+ <enum name="GL_GENERATE_MIPMAP"/>
+ <enum name="GL_TEXTURE0"/>
+ <enum name="GL_TEXTURE1"/>
+ <enum name="GL_TEXTURE2"/>
+ <enum name="GL_TEXTURE3"/>
+ <enum name="GL_TEXTURE4"/>
+ <enum name="GL_TEXTURE5"/>
+ <enum name="GL_TEXTURE6"/>
+ <enum name="GL_TEXTURE7"/>
+ <enum name="GL_TEXTURE8"/>
+ <enum name="GL_TEXTURE9"/>
+ <enum name="GL_TEXTURE10"/>
+ <enum name="GL_TEXTURE11"/>
+ <enum name="GL_TEXTURE12"/>
+ <enum name="GL_TEXTURE13"/>
+ <enum name="GL_TEXTURE14"/>
+ <enum name="GL_TEXTURE15"/>
+ <enum name="GL_TEXTURE16"/>
+ <enum name="GL_TEXTURE17"/>
+ <enum name="GL_TEXTURE18"/>
+ <enum name="GL_TEXTURE19"/>
+ <enum name="GL_TEXTURE20"/>
+ <enum name="GL_TEXTURE21"/>
+ <enum name="GL_TEXTURE22"/>
+ <enum name="GL_TEXTURE23"/>
+ <enum name="GL_TEXTURE24"/>
+ <enum name="GL_TEXTURE25"/>
+ <enum name="GL_TEXTURE26"/>
+ <enum name="GL_TEXTURE27"/>
+ <enum name="GL_TEXTURE28"/>
+ <enum name="GL_TEXTURE29"/>
+ <enum name="GL_TEXTURE30"/>
+ <enum name="GL_TEXTURE31"/>
+ <enum name="GL_ACTIVE_TEXTURE"/>
+ <enum name="GL_CLIENT_ACTIVE_TEXTURE"/>
+ <enum name="GL_REPEAT"/>
+ <enum name="GL_CLAMP_TO_EDGE"/>
+ <enum name="GL_LIGHT0"/>
+ <enum name="GL_LIGHT1"/>
+ <enum name="GL_LIGHT2"/>
+ <enum name="GL_LIGHT3"/>
+ <enum name="GL_LIGHT4"/>
+ <enum name="GL_LIGHT5"/>
+ <enum name="GL_LIGHT6"/>
+ <enum name="GL_LIGHT7"/>
+ <enum name="GL_ARRAY_BUFFER"/>
+ <enum name="GL_ELEMENT_ARRAY_BUFFER"/>
+ <enum name="GL_ARRAY_BUFFER_BINDING"/>
+ <enum name="GL_ELEMENT_ARRAY_BUFFER_BINDING"/>
+ <enum name="GL_VERTEX_ARRAY_BUFFER_BINDING"/>
+ <enum name="GL_NORMAL_ARRAY_BUFFER_BINDING"/>
+ <enum name="GL_COLOR_ARRAY_BUFFER_BINDING"/>
+ <enum name="GL_TEXTURE_COORD_ARRAY_BUFFER_BINDING"/>
+ <enum name="GL_STATIC_DRAW"/>
+ <enum name="GL_DYNAMIC_DRAW"/>
+ <enum name="GL_BUFFER_SIZE"/>
+ <enum name="GL_BUFFER_USAGE"/>
+ <enum name="GL_SUBTRACT"/>
+ <enum name="GL_COMBINE"/>
+ <enum name="GL_COMBINE_RGB"/>
+ <enum name="GL_COMBINE_ALPHA"/>
+ <enum name="GL_RGB_SCALE"/>
+ <enum name="GL_ADD_SIGNED"/>
+ <enum name="GL_INTERPOLATE"/>
+ <enum name="GL_CONSTANT"/>
+ <enum name="GL_PRIMARY_COLOR"/>
+ <enum name="GL_PREVIOUS"/>
+ <enum name="GL_OPERAND0_RGB"/>
+ <enum name="GL_OPERAND1_RGB"/>
+ <enum name="GL_OPERAND2_RGB"/>
+ <enum name="GL_OPERAND0_ALPHA"/>
+ <enum name="GL_OPERAND1_ALPHA"/>
+ <enum name="GL_OPERAND2_ALPHA"/>
+ <enum name="GL_ALPHA_SCALE"/>
+ <enum name="GL_SRC0_RGB"/>
+ <enum name="GL_SRC1_RGB"/>
+ <enum name="GL_SRC2_RGB"/>
+ <enum name="GL_SRC0_ALPHA"/>
+ <enum name="GL_SRC1_ALPHA"/>
+ <enum name="GL_SRC2_ALPHA"/>
+ <enum name="GL_DOT3_RGB"/>
+ <enum name="GL_DOT3_RGBA"/>
+ </require>
+ <require profile="common">
+ <command name="glAlphaFunc"/>
+ <command name="glClearColor"/>
+ <command name="glClearDepthf"/>
+ <command name="glClipPlanef"/>
+ <command name="glColor4f"/>
+ <command name="glDepthRangef"/>
+ <command name="glFogf"/>
+ <command name="glFogfv"/>
+ <command name="glFrustumf"/>
+ <command name="glGetClipPlanef"/>
+ <command name="glGetFloatv"/>
+ <command name="glGetLightfv"/>
+ <command name="glGetMaterialfv"/>
+ <command name="glGetTexEnvfv"/>
+ <command name="glGetTexParameterfv"/>
+ <command name="glLightModelf"/>
+ <command name="glLightModelfv"/>
+ <command name="glLightf"/>
+ <command name="glLightfv"/>
+ <command name="glLineWidth"/>
+ <command name="glLoadMatrixf"/>
+ <command name="glMaterialf"/>
+ <command name="glMaterialfv"/>
+ <command name="glMultMatrixf"/>
+ <command name="glMultiTexCoord4f"/>
+ <command name="glNormal3f"/>
+ <command name="glOrthof"/>
+ <command name="glPointParameterf"/>
+ <command name="glPointParameterfv"/>
+ <command name="glPointSize"/>
+ <command name="glPolygonOffset"/>
+ <command name="glRotatef"/>
+ <command name="glScalef"/>
+ <command name="glTexEnvf"/>
+ <command name="glTexEnvfv"/>
+ <command name="glTexParameterf"/>
+ <command name="glTexParameterfv"/>
+ <command name="glTranslatef"/>
+ </require>
+ <require>
+ <command name="glActiveTexture"/>
+ <command name="glAlphaFuncx"/>
+ <command name="glBindBuffer"/>
+ <command name="glBindTexture"/>
+ <command name="glBlendFunc"/>
+ <command name="glBufferData"/>
+ <command name="glBufferSubData"/>
+ <command name="glClear"/>
+ <command name="glClearColorx"/>
+ <command name="glClearDepthx"/>
+ <command name="glClearStencil"/>
+ <command name="glClientActiveTexture"/>
+ <command name="glClipPlanex"/>
+ <command name="glColor4ub"/>
+ <command name="glColor4x"/>
+ <command name="glColorMask"/>
+ <command name="glColorPointer"/>
+ <command name="glCompressedTexImage2D"/>
+ <command name="glCompressedTexSubImage2D"/>
+ <command name="glCopyTexImage2D"/>
+ <command name="glCopyTexSubImage2D"/>
+ <command name="glCullFace"/>
+ <command name="glDeleteBuffers"/>
+ <command name="glDeleteTextures"/>
+ <command name="glDepthFunc"/>
+ <command name="glDepthMask"/>
+ <command name="glDepthRangex"/>
+ <command name="glDisable"/>
+ <command name="glDisableClientState"/>
+ <command name="glDrawArrays"/>
+ <command name="glDrawElements"/>
+ <command name="glEnable"/>
+ <command name="glEnableClientState"/>
+ <command name="glFinish"/>
+ <command name="glFlush"/>
+ <command name="glFogx"/>
+ <command name="glFogxv"/>
+ <command name="glFrontFace"/>
+ <command name="glFrustumx"/>
+ <command name="glGetBooleanv"/>
+ <command name="glGetBufferParameteriv"/>
+ <command name="glGetClipPlanex"/>
+ <command name="glGenBuffers"/>
+ <command name="glGenTextures"/>
+ <command name="glGetError"/>
+ <command name="glGetFixedv"/>
+ <command name="glGetIntegerv"/>
+ <command name="glGetLightxv"/>
+ <command name="glGetMaterialxv"/>
+ <command name="glGetPointerv"/>
+ <command name="glGetString"/>
+ <command name="glGetTexEnviv"/>
+ <command name="glGetTexEnvxv"/>
+ <command name="glGetTexParameteriv"/>
+ <command name="glGetTexParameterxv"/>
+ <command name="glHint"/>
+ <command name="glIsBuffer"/>
+ <command name="glIsEnabled"/>
+ <command name="glIsTexture"/>
+ <command name="glLightModelx"/>
+ <command name="glLightModelxv"/>
+ <command name="glLightx"/>
+ <command name="glLightxv"/>
+ <command name="glLineWidthx"/>
+ <command name="glLoadIdentity"/>
+ <command name="glLoadMatrixx"/>
+ <command name="glLogicOp"/>
+ <command name="glMaterialx"/>
+ <command name="glMaterialxv"/>
+ <command name="glMatrixMode"/>
+ <command name="glMultMatrixx"/>
+ <command name="glMultiTexCoord4x"/>
+ <command name="glNormal3x"/>
+ <command name="glNormalPointer"/>
+ <command name="glOrthox"/>
+ <command name="glPixelStorei"/>
+ <command name="glPointParameterx"/>
+ <command name="glPointParameterxv"/>
+ <command name="glPointSizex"/>
+ <command name="glPolygonOffsetx"/>
+ <command name="glPopMatrix"/>
+ <command name="glPushMatrix"/>
+ <command name="glReadPixels"/>
+ <command name="glRotatex"/>
+ <command name="glSampleCoverage"/>
+ <command name="glSampleCoveragex"/>
+ <command name="glScalex"/>
+ <command name="glScissor"/>
+ <command name="glShadeModel"/>
+ <command name="glStencilFunc"/>
+ <command name="glStencilMask"/>
+ <command name="glStencilOp"/>
+ <command name="glTexCoordPointer"/>
+ <command name="glTexEnvi"/>
+ <command name="glTexEnvx"/>
+ <command name="glTexEnviv"/>
+ <command name="glTexEnvxv"/>
+ <command name="glTexImage2D"/>
+ <command name="glTexParameteri"/>
+ <command name="glTexParameterx"/>
+ <command name="glTexParameteriv"/>
+ <command name="glTexParameterxv"/>
+ <command name="glTexSubImage2D"/>
+ <command name="glTranslatex"/>
+ <command name="glVertexPointer"/>
+ <command name="glViewport"/>
+ </require>
+ </feature>
+ <feature api="gles2" name="GL_ES_VERSION_2_0" number="2.0">
+ <require comment="Not used by the API, for compatibility with old gl2.h">
+ <type name="GLbyte"/>
+ <type name="GLclampf"/>
+ <type name="GLfixed"/>
+ <type name="GLshort"/>
+ <type name="GLushort"/>
+ <type name="GLvoid" comment="No longer used in headers"/>
+ </require>
+ <require comment="Not used by the API; put here so this type doesn't need to be declared in gl2ext.h">
+ <type name="GLsync"/>
+ <type name="GLint64"/>
+ <type name="GLuint64"/>
+ </require>
+ <require>
+ <enum name="GL_DEPTH_BUFFER_BIT"/>
+ <enum name="GL_STENCIL_BUFFER_BIT"/>
+ <enum name="GL_COLOR_BUFFER_BIT"/>
+ <enum name="GL_FALSE"/>
+ <enum name="GL_TRUE"/>
+ <enum name="GL_POINTS"/>
+ <enum name="GL_LINES"/>
+ <enum name="GL_LINE_LOOP"/>
+ <enum name="GL_LINE_STRIP"/>
+ <enum name="GL_TRIANGLES"/>
+ <enum name="GL_TRIANGLE_STRIP"/>
+ <enum name="GL_TRIANGLE_FAN"/>
+ <enum name="GL_ZERO"/>
+ <enum name="GL_ONE"/>
+ <enum name="GL_SRC_COLOR"/>
+ <enum name="GL_ONE_MINUS_SRC_COLOR"/>
+ <enum name="GL_SRC_ALPHA"/>
+ <enum name="GL_ONE_MINUS_SRC_ALPHA"/>
+ <enum name="GL_DST_ALPHA"/>
+ <enum name="GL_ONE_MINUS_DST_ALPHA"/>
+ <enum name="GL_DST_COLOR"/>
+ <enum name="GL_ONE_MINUS_DST_COLOR"/>
+ <enum name="GL_SRC_ALPHA_SATURATE"/>
+ <enum name="GL_FUNC_ADD"/>
+ <enum name="GL_BLEND_EQUATION"/>
+ <enum name="GL_BLEND_EQUATION_RGB"/>
+ <enum name="GL_BLEND_EQUATION_ALPHA"/>
+ <enum name="GL_FUNC_SUBTRACT"/>
+ <enum name="GL_FUNC_REVERSE_SUBTRACT"/>
+ <enum name="GL_BLEND_DST_RGB"/>
+ <enum name="GL_BLEND_SRC_RGB"/>
+ <enum name="GL_BLEND_DST_ALPHA"/>
+ <enum name="GL_BLEND_SRC_ALPHA"/>
+ <enum name="GL_CONSTANT_COLOR"/>
+ <enum name="GL_ONE_MINUS_CONSTANT_COLOR"/>
+ <enum name="GL_CONSTANT_ALPHA"/>
+ <enum name="GL_ONE_MINUS_CONSTANT_ALPHA"/>
+ <enum name="GL_BLEND_COLOR"/>
+ <enum name="GL_ARRAY_BUFFER"/>
+ <enum name="GL_ELEMENT_ARRAY_BUFFER"/>
+ <enum name="GL_ARRAY_BUFFER_BINDING"/>
+ <enum name="GL_ELEMENT_ARRAY_BUFFER_BINDING"/>
+ <enum name="GL_STREAM_DRAW"/>
+ <enum name="GL_STATIC_DRAW"/>
+ <enum name="GL_DYNAMIC_DRAW"/>
+ <enum name="GL_BUFFER_SIZE"/>
+ <enum name="GL_BUFFER_USAGE"/>
+ <enum name="GL_CURRENT_VERTEX_ATTRIB"/>
+ <enum name="GL_FRONT"/>
+ <enum name="GL_BACK"/>
+ <enum name="GL_FRONT_AND_BACK"/>
+ <enum name="GL_TEXTURE_2D"/>
+ <enum name="GL_CULL_FACE"/>
+ <enum name="GL_BLEND"/>
+ <enum name="GL_DITHER"/>
+ <enum name="GL_STENCIL_TEST"/>
+ <enum name="GL_DEPTH_TEST"/>
+ <enum name="GL_SCISSOR_TEST"/>
+ <enum name="GL_POLYGON_OFFSET_FILL"/>
+ <enum name="GL_SAMPLE_ALPHA_TO_COVERAGE"/>
+ <enum name="GL_SAMPLE_COVERAGE"/>
+ <enum name="GL_NO_ERROR"/>
+ <enum name="GL_INVALID_ENUM"/>
+ <enum name="GL_INVALID_VALUE"/>
+ <enum name="GL_INVALID_OPERATION"/>
+ <enum name="GL_OUT_OF_MEMORY"/>
+ <enum name="GL_CW"/>
+ <enum name="GL_CCW"/>
+ <enum name="GL_LINE_WIDTH"/>
+ <enum name="GL_ALIASED_POINT_SIZE_RANGE"/>
+ <enum name="GL_ALIASED_LINE_WIDTH_RANGE"/>
+ <enum name="GL_CULL_FACE_MODE"/>
+ <enum name="GL_FRONT_FACE"/>
+ <enum name="GL_DEPTH_RANGE"/>
+ <enum name="GL_DEPTH_WRITEMASK"/>
+ <enum name="GL_DEPTH_CLEAR_VALUE"/>
+ <enum name="GL_DEPTH_FUNC"/>
+ <enum name="GL_STENCIL_CLEAR_VALUE"/>
+ <enum name="GL_STENCIL_FUNC"/>
+ <enum name="GL_STENCIL_FAIL"/>
+ <enum name="GL_STENCIL_PASS_DEPTH_FAIL"/>
+ <enum name="GL_STENCIL_PASS_DEPTH_PASS"/>
+ <enum name="GL_STENCIL_REF"/>
+ <enum name="GL_STENCIL_VALUE_MASK"/>
+ <enum name="GL_STENCIL_WRITEMASK"/>
+ <enum name="GL_STENCIL_BACK_FUNC"/>
+ <enum name="GL_STENCIL_BACK_FAIL"/>
+ <enum name="GL_STENCIL_BACK_PASS_DEPTH_FAIL"/>
+ <enum name="GL_STENCIL_BACK_PASS_DEPTH_PASS"/>
+ <enum name="GL_STENCIL_BACK_REF"/>
+ <enum name="GL_STENCIL_BACK_VALUE_MASK"/>
+ <enum name="GL_STENCIL_BACK_WRITEMASK"/>
+ <enum name="GL_VIEWPORT"/>
+ <enum name="GL_SCISSOR_BOX"/>
+ <enum name="GL_COLOR_CLEAR_VALUE"/>
+ <enum name="GL_COLOR_WRITEMASK"/>
+ <enum name="GL_UNPACK_ALIGNMENT"/>
+ <enum name="GL_PACK_ALIGNMENT"/>
+ <enum name="GL_MAX_TEXTURE_SIZE"/>
+ <enum name="GL_MAX_VIEWPORT_DIMS"/>
+ <enum name="GL_SUBPIXEL_BITS"/>
+ <enum name="GL_RED_BITS"/>
+ <enum name="GL_GREEN_BITS"/>
+ <enum name="GL_BLUE_BITS"/>
+ <enum name="GL_ALPHA_BITS"/>
+ <enum name="GL_DEPTH_BITS"/>
+ <enum name="GL_STENCIL_BITS"/>
+ <enum name="GL_POLYGON_OFFSET_UNITS"/>
+ <enum name="GL_POLYGON_OFFSET_FACTOR"/>
+ <enum name="GL_TEXTURE_BINDING_2D"/>
+ <enum name="GL_SAMPLE_BUFFERS"/>
+ <enum name="GL_SAMPLES"/>
+ <enum name="GL_SAMPLE_COVERAGE_VALUE"/>
+ <enum name="GL_SAMPLE_COVERAGE_INVERT"/>
+ <enum name="GL_NUM_COMPRESSED_TEXTURE_FORMATS"/>
+ <enum name="GL_COMPRESSED_TEXTURE_FORMATS"/>
+ <enum name="GL_DONT_CARE"/>
+ <enum name="GL_FASTEST"/>
+ <enum name="GL_NICEST"/>
+ <enum name="GL_GENERATE_MIPMAP_HINT"/>
+ <enum name="GL_BYTE"/>
+ <enum name="GL_UNSIGNED_BYTE"/>
+ <enum name="GL_SHORT"/>
+ <enum name="GL_UNSIGNED_SHORT"/>
+ <enum name="GL_INT"/>
+ <enum name="GL_UNSIGNED_INT"/>
+ <enum name="GL_FLOAT"/>
+ <enum name="GL_FIXED"/>
+ <enum name="GL_DEPTH_COMPONENT"/>
+ <enum name="GL_ALPHA"/>
+ <enum name="GL_RGB"/>
+ <enum name="GL_RGBA"/>
+ <enum name="GL_LUMINANCE"/>
+ <enum name="GL_LUMINANCE_ALPHA"/>
+ <enum name="GL_UNSIGNED_SHORT_4_4_4_4"/>
+ <enum name="GL_UNSIGNED_SHORT_5_5_5_1"/>
+ <enum name="GL_UNSIGNED_SHORT_5_6_5"/>
+ <enum name="GL_FRAGMENT_SHADER"/>
+ <enum name="GL_VERTEX_SHADER"/>
+ <enum name="GL_MAX_VERTEX_ATTRIBS"/>
+ <enum name="GL_MAX_VERTEX_UNIFORM_VECTORS"/>
+ <enum name="GL_MAX_VARYING_VECTORS"/>
+ <enum name="GL_MAX_COMBINED_TEXTURE_IMAGE_UNITS"/>
+ <enum name="GL_MAX_VERTEX_TEXTURE_IMAGE_UNITS"/>
+ <enum name="GL_MAX_TEXTURE_IMAGE_UNITS"/>
+ <enum name="GL_MAX_FRAGMENT_UNIFORM_VECTORS"/>
+ <enum name="GL_SHADER_TYPE"/>
+ <enum name="GL_DELETE_STATUS"/>
+ <enum name="GL_LINK_STATUS"/>
+ <enum name="GL_VALIDATE_STATUS"/>
+ <enum name="GL_ATTACHED_SHADERS"/>
+ <enum name="GL_ACTIVE_UNIFORMS"/>
+ <enum name="GL_ACTIVE_UNIFORM_MAX_LENGTH"/>
+ <enum name="GL_ACTIVE_ATTRIBUTES"/>
+ <enum name="GL_ACTIVE_ATTRIBUTE_MAX_LENGTH"/>
+ <enum name="GL_SHADING_LANGUAGE_VERSION"/>
+ <enum name="GL_CURRENT_PROGRAM"/>
+ <enum name="GL_NEVER"/>
+ <enum name="GL_LESS"/>
+ <enum name="GL_EQUAL"/>
+ <enum name="GL_LEQUAL"/>
+ <enum name="GL_GREATER"/>
+ <enum name="GL_NOTEQUAL"/>
+ <enum name="GL_GEQUAL"/>
+ <enum name="GL_ALWAYS"/>
+ <enum name="GL_KEEP"/>
+ <enum name="GL_REPLACE"/>
+ <enum name="GL_INCR"/>
+ <enum name="GL_DECR"/>
+ <enum name="GL_INVERT"/>
+ <enum name="GL_INCR_WRAP"/>
+ <enum name="GL_DECR_WRAP"/>
+ <enum name="GL_VENDOR"/>
+ <enum name="GL_RENDERER"/>
+ <enum name="GL_VERSION"/>
+ <enum name="GL_EXTENSIONS"/>
+ <enum name="GL_NEAREST"/>
+ <enum name="GL_LINEAR"/>
+ <enum name="GL_NEAREST_MIPMAP_NEAREST"/>
+ <enum name="GL_LINEAR_MIPMAP_NEAREST"/>
+ <enum name="GL_NEAREST_MIPMAP_LINEAR"/>
+ <enum name="GL_LINEAR_MIPMAP_LINEAR"/>
+ <enum name="GL_TEXTURE_MAG_FILTER"/>
+ <enum name="GL_TEXTURE_MIN_FILTER"/>
+ <enum name="GL_TEXTURE_WRAP_S"/>
+ <enum name="GL_TEXTURE_WRAP_T"/>
+ <enum name="GL_TEXTURE"/>
+ <enum name="GL_TEXTURE_CUBE_MAP"/>
+ <enum name="GL_TEXTURE_BINDING_CUBE_MAP"/>
+ <enum name="GL_TEXTURE_CUBE_MAP_POSITIVE_X"/>
+ <enum name="GL_TEXTURE_CUBE_MAP_NEGATIVE_X"/>
+ <enum name="GL_TEXTURE_CUBE_MAP_POSITIVE_Y"/>
+ <enum name="GL_TEXTURE_CUBE_MAP_NEGATIVE_Y"/>
+ <enum name="GL_TEXTURE_CUBE_MAP_POSITIVE_Z"/>
+ <enum name="GL_TEXTURE_CUBE_MAP_NEGATIVE_Z"/>
+ <enum name="GL_MAX_CUBE_MAP_TEXTURE_SIZE"/>
+ <enum name="GL_TEXTURE0"/>
+ <enum name="GL_TEXTURE1"/>
+ <enum name="GL_TEXTURE2"/>
+ <enum name="GL_TEXTURE3"/>
+ <enum name="GL_TEXTURE4"/>
+ <enum name="GL_TEXTURE5"/>
+ <enum name="GL_TEXTURE6"/>
+ <enum name="GL_TEXTURE7"/>
+ <enum name="GL_TEXTURE8"/>
+ <enum name="GL_TEXTURE9"/>
+ <enum name="GL_TEXTURE10"/>
+ <enum name="GL_TEXTURE11"/>
+ <enum name="GL_TEXTURE12"/>
+ <enum name="GL_TEXTURE13"/>
+ <enum name="GL_TEXTURE14"/>
+ <enum name="GL_TEXTURE15"/>
+ <enum name="GL_TEXTURE16"/>
+ <enum name="GL_TEXTURE17"/>
+ <enum name="GL_TEXTURE18"/>
+ <enum name="GL_TEXTURE19"/>
+ <enum name="GL_TEXTURE20"/>
+ <enum name="GL_TEXTURE21"/>
+ <enum name="GL_TEXTURE22"/>
+ <enum name="GL_TEXTURE23"/>
+ <enum name="GL_TEXTURE24"/>
+ <enum name="GL_TEXTURE25"/>
+ <enum name="GL_TEXTURE26"/>
+ <enum name="GL_TEXTURE27"/>
+ <enum name="GL_TEXTURE28"/>
+ <enum name="GL_TEXTURE29"/>
+ <enum name="GL_TEXTURE30"/>
+ <enum name="GL_TEXTURE31"/>
+ <enum name="GL_ACTIVE_TEXTURE"/>
+ <enum name="GL_REPEAT"/>
+ <enum name="GL_CLAMP_TO_EDGE"/>
+ <enum name="GL_MIRRORED_REPEAT"/>
+ <enum name="GL_FLOAT_VEC2"/>
+ <enum name="GL_FLOAT_VEC3"/>
+ <enum name="GL_FLOAT_VEC4"/>
+ <enum name="GL_INT_VEC2"/>
+ <enum name="GL_INT_VEC3"/>
+ <enum name="GL_INT_VEC4"/>
+ <enum name="GL_BOOL"/>
+ <enum name="GL_BOOL_VEC2"/>
+ <enum name="GL_BOOL_VEC3"/>
+ <enum name="GL_BOOL_VEC4"/>
+ <enum name="GL_FLOAT_MAT2"/>
+ <enum name="GL_FLOAT_MAT3"/>
+ <enum name="GL_FLOAT_MAT4"/>
+ <enum name="GL_SAMPLER_2D"/>
+ <enum name="GL_SAMPLER_CUBE"/>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY_ENABLED"/>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY_SIZE"/>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY_STRIDE"/>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY_TYPE"/>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY_NORMALIZED"/>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY_POINTER"/>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY_BUFFER_BINDING"/>
+ <enum name="GL_IMPLEMENTATION_COLOR_READ_TYPE"/>
+ <enum name="GL_IMPLEMENTATION_COLOR_READ_FORMAT"/>
+ <enum name="GL_COMPILE_STATUS"/>
+ <enum name="GL_INFO_LOG_LENGTH"/>
+ <enum name="GL_SHADER_SOURCE_LENGTH"/>
+ <enum name="GL_SHADER_COMPILER"/>
+ <enum name="GL_SHADER_BINARY_FORMATS"/>
+ <enum name="GL_NUM_SHADER_BINARY_FORMATS"/>
+ <enum name="GL_LOW_FLOAT"/>
+ <enum name="GL_MEDIUM_FLOAT"/>
+ <enum name="GL_HIGH_FLOAT"/>
+ <enum name="GL_LOW_INT"/>
+ <enum name="GL_MEDIUM_INT"/>
+ <enum name="GL_HIGH_INT"/>
+ <enum name="GL_FRAMEBUFFER"/>
+ <enum name="GL_RENDERBUFFER"/>
+ <enum name="GL_RGBA4"/>
+ <enum name="GL_RGB5_A1"/>
+ <enum name="GL_RGB565"/>
+ <enum name="GL_DEPTH_COMPONENT16"/>
+ <enum name="GL_STENCIL_INDEX8"/>
+ <enum name="GL_RENDERBUFFER_WIDTH"/>
+ <enum name="GL_RENDERBUFFER_HEIGHT"/>
+ <enum name="GL_RENDERBUFFER_INTERNAL_FORMAT"/>
+ <enum name="GL_RENDERBUFFER_RED_SIZE"/>
+ <enum name="GL_RENDERBUFFER_GREEN_SIZE"/>
+ <enum name="GL_RENDERBUFFER_BLUE_SIZE"/>
+ <enum name="GL_RENDERBUFFER_ALPHA_SIZE"/>
+ <enum name="GL_RENDERBUFFER_DEPTH_SIZE"/>
+ <enum name="GL_RENDERBUFFER_STENCIL_SIZE"/>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE"/>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_OBJECT_NAME"/>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL"/>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE"/>
+ <enum name="GL_COLOR_ATTACHMENT0"/>
+ <enum name="GL_DEPTH_ATTACHMENT"/>
+ <enum name="GL_STENCIL_ATTACHMENT"/>
+ <enum name="GL_NONE"/>
+ <enum name="GL_FRAMEBUFFER_COMPLETE"/>
+ <enum name="GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT"/>
+ <enum name="GL_FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT"/>
+ <enum name="GL_FRAMEBUFFER_INCOMPLETE_DIMENSIONS"/>
+ <enum name="GL_FRAMEBUFFER_UNSUPPORTED"/>
+ <enum name="GL_FRAMEBUFFER_BINDING"/>
+ <enum name="GL_RENDERBUFFER_BINDING"/>
+ <enum name="GL_MAX_RENDERBUFFER_SIZE"/>
+ <enum name="GL_INVALID_FRAMEBUFFER_OPERATION"/>
+ <command name="glActiveTexture"/>
+ <command name="glAttachShader"/>
+ <command name="glBindAttribLocation"/>
+ <command name="glBindBuffer"/>
+ <command name="glBindFramebuffer"/>
+ <command name="glBindRenderbuffer"/>
+ <command name="glBindTexture"/>
+ <command name="glBlendColor"/>
+ <command name="glBlendEquation"/>
+ <command name="glBlendEquationSeparate"/>
+ <command name="glBlendFunc"/>
+ <command name="glBlendFuncSeparate"/>
+ <command name="glBufferData"/>
+ <command name="glBufferSubData"/>
+ <command name="glCheckFramebufferStatus"/>
+ <command name="glClear"/>
+ <command name="glClearColor"/>
+ <command name="glClearDepthf"/>
+ <command name="glClearStencil"/>
+ <command name="glColorMask"/>
+ <command name="glCompileShader"/>
+ <command name="glCompressedTexImage2D"/>
+ <command name="glCompressedTexSubImage2D"/>
+ <command name="glCopyTexImage2D"/>
+ <command name="glCopyTexSubImage2D"/>
+ <command name="glCreateProgram"/>
+ <command name="glCreateShader"/>
+ <command name="glCullFace"/>
+ <command name="glDeleteBuffers"/>
+ <command name="glDeleteFramebuffers"/>
+ <command name="glDeleteProgram"/>
+ <command name="glDeleteRenderbuffers"/>
+ <command name="glDeleteShader"/>
+ <command name="glDeleteTextures"/>
+ <command name="glDepthFunc"/>
+ <command name="glDepthMask"/>
+ <command name="glDepthRangef"/>
+ <command name="glDetachShader"/>
+ <command name="glDisable"/>
+ <command name="glDisableVertexAttribArray"/>
+ <command name="glDrawArrays"/>
+ <command name="glDrawElements"/>
+ <command name="glEnable"/>
+ <command name="glEnableVertexAttribArray"/>
+ <command name="glFinish"/>
+ <command name="glFlush"/>
+ <command name="glFramebufferRenderbuffer"/>
+ <command name="glFramebufferTexture2D"/>
+ <command name="glFrontFace"/>
+ <command name="glGenBuffers"/>
+ <command name="glGenerateMipmap"/>
+ <command name="glGenFramebuffers"/>
+ <command name="glGenRenderbuffers"/>
+ <command name="glGenTextures"/>
+ <command name="glGetActiveAttrib"/>
+ <command name="glGetActiveUniform"/>
+ <command name="glGetAttachedShaders"/>
+ <command name="glGetAttribLocation"/>
+ <command name="glGetBooleanv"/>
+ <command name="glGetBufferParameteriv"/>
+ <command name="glGetError"/>
+ <command name="glGetFloatv"/>
+ <command name="glGetFramebufferAttachmentParameteriv"/>
+ <command name="glGetIntegerv"/>
+ <command name="glGetProgramiv"/>
+ <command name="glGetProgramInfoLog"/>
+ <command name="glGetRenderbufferParameteriv"/>
+ <command name="glGetShaderiv"/>
+ <command name="glGetShaderInfoLog"/>
+ <command name="glGetShaderPrecisionFormat"/>
+ <command name="glGetShaderSource"/>
+ <command name="glGetString"/>
+ <command name="glGetTexParameterfv"/>
+ <command name="glGetTexParameteriv"/>
+ <command name="glGetUniformfv"/>
+ <command name="glGetUniformiv"/>
+ <command name="glGetUniformLocation"/>
+ <command name="glGetVertexAttribfv"/>
+ <command name="glGetVertexAttribiv"/>
+ <command name="glGetVertexAttribPointerv"/>
+ <command name="glHint"/>
+ <command name="glIsBuffer"/>
+ <command name="glIsEnabled"/>
+ <command name="glIsFramebuffer"/>
+ <command name="glIsProgram"/>
+ <command name="glIsRenderbuffer"/>
+ <command name="glIsShader"/>
+ <command name="glIsTexture"/>
+ <command name="glLineWidth"/>
+ <command name="glLinkProgram"/>
+ <command name="glPixelStorei"/>
+ <command name="glPolygonOffset"/>
+ <command name="glReadPixels"/>
+ <command name="glReleaseShaderCompiler"/>
+ <command name="glRenderbufferStorage"/>
+ <command name="glSampleCoverage"/>
+ <command name="glScissor"/>
+ <command name="glShaderBinary"/>
+ <command name="glShaderSource"/>
+ <command name="glStencilFunc"/>
+ <command name="glStencilFuncSeparate"/>
+ <command name="glStencilMask"/>
+ <command name="glStencilMaskSeparate"/>
+ <command name="glStencilOp"/>
+ <command name="glStencilOpSeparate"/>
+ <command name="glTexImage2D"/>
+ <command name="glTexParameterf"/>
+ <command name="glTexParameterfv"/>
+ <command name="glTexParameteri"/>
+ <command name="glTexParameteriv"/>
+ <command name="glTexSubImage2D"/>
+ <command name="glUniform1f"/>
+ <command name="glUniform1fv"/>
+ <command name="glUniform1i"/>
+ <command name="glUniform1iv"/>
+ <command name="glUniform2f"/>
+ <command name="glUniform2fv"/>
+ <command name="glUniform2i"/>
+ <command name="glUniform2iv"/>
+ <command name="glUniform3f"/>
+ <command name="glUniform3fv"/>
+ <command name="glUniform3i"/>
+ <command name="glUniform3iv"/>
+ <command name="glUniform4f"/>
+ <command name="glUniform4fv"/>
+ <command name="glUniform4i"/>
+ <command name="glUniform4iv"/>
+ <command name="glUniformMatrix2fv"/>
+ <command name="glUniformMatrix3fv"/>
+ <command name="glUniformMatrix4fv"/>
+ <command name="glUseProgram"/>
+ <command name="glValidateProgram"/>
+ <command name="glVertexAttrib1f"/>
+ <command name="glVertexAttrib1fv"/>
+ <command name="glVertexAttrib2f"/>
+ <command name="glVertexAttrib2fv"/>
+ <command name="glVertexAttrib3f"/>
+ <command name="glVertexAttrib3fv"/>
+ <command name="glVertexAttrib4f"/>
+ <command name="glVertexAttrib4fv"/>
+ <command name="glVertexAttribPointer"/>
+ <command name="glViewport"/>
+ </require>
+ </feature>
+ <feature api="gles2" name="GL_ES_VERSION_3_0" number="3.0">
+ <require comment="Not used by the API, for compatibility with old gl2.h">
+ <type name="GLhalf"/>
+ </require>
+ <require>
+ <enum name="GL_READ_BUFFER"/>
+ <enum name="GL_UNPACK_ROW_LENGTH"/>
+ <enum name="GL_UNPACK_SKIP_ROWS"/>
+ <enum name="GL_UNPACK_SKIP_PIXELS"/>
+ <enum name="GL_PACK_ROW_LENGTH"/>
+ <enum name="GL_PACK_SKIP_ROWS"/>
+ <enum name="GL_PACK_SKIP_PIXELS"/>
+ <enum name="GL_COLOR"/>
+ <enum name="GL_DEPTH"/>
+ <enum name="GL_STENCIL"/>
+ <enum name="GL_RED"/>
+ <enum name="GL_RGB8"/>
+ <enum name="GL_RGBA8"/>
+ <enum name="GL_RGB10_A2"/>
+ <enum name="GL_TEXTURE_BINDING_3D"/>
+ <enum name="GL_UNPACK_SKIP_IMAGES"/>
+ <enum name="GL_UNPACK_IMAGE_HEIGHT"/>
+ <enum name="GL_TEXTURE_3D"/>
+ <enum name="GL_TEXTURE_WRAP_R"/>
+ <enum name="GL_MAX_3D_TEXTURE_SIZE"/>
+ <enum name="GL_UNSIGNED_INT_2_10_10_10_REV"/>
+ <enum name="GL_MAX_ELEMENTS_VERTICES"/>
+ <enum name="GL_MAX_ELEMENTS_INDICES"/>
+ <enum name="GL_TEXTURE_MIN_LOD"/>
+ <enum name="GL_TEXTURE_MAX_LOD"/>
+ <enum name="GL_TEXTURE_BASE_LEVEL"/>
+ <enum name="GL_TEXTURE_MAX_LEVEL"/>
+ <enum name="GL_MIN"/>
+ <enum name="GL_MAX"/>
+ <enum name="GL_DEPTH_COMPONENT24"/>
+ <enum name="GL_MAX_TEXTURE_LOD_BIAS"/>
+ <enum name="GL_TEXTURE_COMPARE_MODE"/>
+ <enum name="GL_TEXTURE_COMPARE_FUNC"/>
+ <enum name="GL_CURRENT_QUERY"/>
+ <enum name="GL_QUERY_RESULT"/>
+ <enum name="GL_QUERY_RESULT_AVAILABLE"/>
+ <enum name="GL_BUFFER_MAPPED"/>
+ <enum name="GL_BUFFER_MAP_POINTER"/>
+ <enum name="GL_STREAM_READ"/>
+ <enum name="GL_STREAM_COPY"/>
+ <enum name="GL_STATIC_READ"/>
+ <enum name="GL_STATIC_COPY"/>
+ <enum name="GL_DYNAMIC_READ"/>
+ <enum name="GL_DYNAMIC_COPY"/>
+ <enum name="GL_MAX_DRAW_BUFFERS"/>
+ <enum name="GL_DRAW_BUFFER0"/>
+ <enum name="GL_DRAW_BUFFER1"/>
+ <enum name="GL_DRAW_BUFFER2"/>
+ <enum name="GL_DRAW_BUFFER3"/>
+ <enum name="GL_DRAW_BUFFER4"/>
+ <enum name="GL_DRAW_BUFFER5"/>
+ <enum name="GL_DRAW_BUFFER6"/>
+ <enum name="GL_DRAW_BUFFER7"/>
+ <enum name="GL_DRAW_BUFFER8"/>
+ <enum name="GL_DRAW_BUFFER9"/>
+ <enum name="GL_DRAW_BUFFER10"/>
+ <enum name="GL_DRAW_BUFFER11"/>
+ <enum name="GL_DRAW_BUFFER12"/>
+ <enum name="GL_DRAW_BUFFER13"/>
+ <enum name="GL_DRAW_BUFFER14"/>
+ <enum name="GL_DRAW_BUFFER15"/>
+ <enum name="GL_MAX_FRAGMENT_UNIFORM_COMPONENTS"/>
+ <enum name="GL_MAX_VERTEX_UNIFORM_COMPONENTS"/>
+ <enum name="GL_SAMPLER_3D"/>
+ <enum name="GL_SAMPLER_2D_SHADOW"/>
+ <enum name="GL_FRAGMENT_SHADER_DERIVATIVE_HINT"/>
+ <enum name="GL_PIXEL_PACK_BUFFER"/>
+ <enum name="GL_PIXEL_UNPACK_BUFFER"/>
+ <enum name="GL_PIXEL_PACK_BUFFER_BINDING"/>
+ <enum name="GL_PIXEL_UNPACK_BUFFER_BINDING"/>
+ <enum name="GL_FLOAT_MAT2x3"/>
+ <enum name="GL_FLOAT_MAT2x4"/>
+ <enum name="GL_FLOAT_MAT3x2"/>
+ <enum name="GL_FLOAT_MAT3x4"/>
+ <enum name="GL_FLOAT_MAT4x2"/>
+ <enum name="GL_FLOAT_MAT4x3"/>
+ <enum name="GL_SRGB"/>
+ <enum name="GL_SRGB8"/>
+ <enum name="GL_SRGB8_ALPHA8"/>
+ <enum name="GL_COMPARE_REF_TO_TEXTURE"/>
+ <enum name="GL_MAJOR_VERSION"/>
+ <enum name="GL_MINOR_VERSION"/>
+ <enum name="GL_NUM_EXTENSIONS"/>
+ <enum name="GL_RGBA32F"/>
+ <enum name="GL_RGB32F"/>
+ <enum name="GL_RGBA16F"/>
+ <enum name="GL_RGB16F"/>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY_INTEGER"/>
+ <enum name="GL_MAX_ARRAY_TEXTURE_LAYERS"/>
+ <enum name="GL_MIN_PROGRAM_TEXEL_OFFSET"/>
+ <enum name="GL_MAX_PROGRAM_TEXEL_OFFSET"/>
+ <enum name="GL_MAX_VARYING_COMPONENTS"/>
+ <enum name="GL_TEXTURE_2D_ARRAY"/>
+ <enum name="GL_TEXTURE_BINDING_2D_ARRAY"/>
+ <enum name="GL_R11F_G11F_B10F"/>
+ <enum name="GL_UNSIGNED_INT_10F_11F_11F_REV"/>
+ <enum name="GL_RGB9_E5"/>
+ <enum name="GL_UNSIGNED_INT_5_9_9_9_REV"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_VARYING_MAX_LENGTH"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_BUFFER_MODE"/>
+ <enum name="GL_MAX_TRANSFORM_FEEDBACK_SEPARATE_COMPONENTS"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_VARYINGS"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_BUFFER_START"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_BUFFER_SIZE"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN"/>
+ <enum name="GL_RASTERIZER_DISCARD"/>
+ <enum name="GL_MAX_TRANSFORM_FEEDBACK_INTERLEAVED_COMPONENTS"/>
+ <enum name="GL_MAX_TRANSFORM_FEEDBACK_SEPARATE_ATTRIBS"/>
+ <enum name="GL_INTERLEAVED_ATTRIBS"/>
+ <enum name="GL_SEPARATE_ATTRIBS"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_BUFFER"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_BUFFER_BINDING"/>
+ <enum name="GL_RGBA32UI"/>
+ <enum name="GL_RGB32UI"/>
+ <enum name="GL_RGBA16UI"/>
+ <enum name="GL_RGB16UI"/>
+ <enum name="GL_RGBA8UI"/>
+ <enum name="GL_RGB8UI"/>
+ <enum name="GL_RGBA32I"/>
+ <enum name="GL_RGB32I"/>
+ <enum name="GL_RGBA16I"/>
+ <enum name="GL_RGB16I"/>
+ <enum name="GL_RGBA8I"/>
+ <enum name="GL_RGB8I"/>
+ <enum name="GL_RED_INTEGER"/>
+ <enum name="GL_RGB_INTEGER"/>
+ <enum name="GL_RGBA_INTEGER"/>
+ <enum name="GL_SAMPLER_2D_ARRAY"/>
+ <enum name="GL_SAMPLER_2D_ARRAY_SHADOW"/>
+ <enum name="GL_SAMPLER_CUBE_SHADOW"/>
+ <enum name="GL_UNSIGNED_INT_VEC2"/>
+ <enum name="GL_UNSIGNED_INT_VEC3"/>
+ <enum name="GL_UNSIGNED_INT_VEC4"/>
+ <enum name="GL_INT_SAMPLER_2D"/>
+ <enum name="GL_INT_SAMPLER_3D"/>
+ <enum name="GL_INT_SAMPLER_CUBE"/>
+ <enum name="GL_INT_SAMPLER_2D_ARRAY"/>
+ <enum name="GL_UNSIGNED_INT_SAMPLER_2D"/>
+ <enum name="GL_UNSIGNED_INT_SAMPLER_3D"/>
+ <enum name="GL_UNSIGNED_INT_SAMPLER_CUBE"/>
+ <enum name="GL_UNSIGNED_INT_SAMPLER_2D_ARRAY"/>
+ <enum name="GL_BUFFER_ACCESS_FLAGS"/>
+ <enum name="GL_BUFFER_MAP_LENGTH"/>
+ <enum name="GL_BUFFER_MAP_OFFSET"/>
+ <enum name="GL_DEPTH_COMPONENT32F"/>
+ <enum name="GL_DEPTH32F_STENCIL8"/>
+ <enum name="GL_FLOAT_32_UNSIGNED_INT_24_8_REV"/>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING"/>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE"/>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_RED_SIZE"/>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_GREEN_SIZE"/>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_BLUE_SIZE"/>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_ALPHA_SIZE"/>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_DEPTH_SIZE"/>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_STENCIL_SIZE"/>
+ <enum name="GL_FRAMEBUFFER_DEFAULT"/>
+ <enum name="GL_FRAMEBUFFER_UNDEFINED"/>
+ <enum name="GL_DEPTH_STENCIL_ATTACHMENT"/>
+ <enum name="GL_DEPTH_STENCIL"/>
+ <enum name="GL_UNSIGNED_INT_24_8"/>
+ <enum name="GL_DEPTH24_STENCIL8"/>
+ <enum name="GL_UNSIGNED_NORMALIZED"/>
+ <enum name="GL_DRAW_FRAMEBUFFER_BINDING"/>
+ <enum name="GL_READ_FRAMEBUFFER"/>
+ <enum name="GL_DRAW_FRAMEBUFFER"/>
+ <enum name="GL_READ_FRAMEBUFFER_BINDING"/>
+ <enum name="GL_RENDERBUFFER_SAMPLES"/>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER"/>
+ <enum name="GL_MAX_COLOR_ATTACHMENTS"/>
+ <enum name="GL_COLOR_ATTACHMENT1"/>
+ <enum name="GL_COLOR_ATTACHMENT2"/>
+ <enum name="GL_COLOR_ATTACHMENT3"/>
+ <enum name="GL_COLOR_ATTACHMENT4"/>
+ <enum name="GL_COLOR_ATTACHMENT5"/>
+ <enum name="GL_COLOR_ATTACHMENT6"/>
+ <enum name="GL_COLOR_ATTACHMENT7"/>
+ <enum name="GL_COLOR_ATTACHMENT8"/>
+ <enum name="GL_COLOR_ATTACHMENT9"/>
+ <enum name="GL_COLOR_ATTACHMENT10"/>
+ <enum name="GL_COLOR_ATTACHMENT11"/>
+ <enum name="GL_COLOR_ATTACHMENT12"/>
+ <enum name="GL_COLOR_ATTACHMENT13"/>
+ <enum name="GL_COLOR_ATTACHMENT14"/>
+ <enum name="GL_COLOR_ATTACHMENT15"/>
+ <enum name="GL_FRAMEBUFFER_INCOMPLETE_MULTISAMPLE"/>
+ <enum name="GL_MAX_SAMPLES"/>
+ <enum name="GL_HALF_FLOAT"/>
+ <enum name="GL_MAP_READ_BIT"/>
+ <enum name="GL_MAP_WRITE_BIT"/>
+ <enum name="GL_MAP_INVALIDATE_RANGE_BIT"/>
+ <enum name="GL_MAP_INVALIDATE_BUFFER_BIT"/>
+ <enum name="GL_MAP_FLUSH_EXPLICIT_BIT"/>
+ <enum name="GL_MAP_UNSYNCHRONIZED_BIT"/>
+ <enum name="GL_RG"/>
+ <enum name="GL_RG_INTEGER"/>
+ <enum name="GL_R8"/>
+ <enum name="GL_RG8"/>
+ <enum name="GL_R16F"/>
+ <enum name="GL_R32F"/>
+ <enum name="GL_RG16F"/>
+ <enum name="GL_RG32F"/>
+ <enum name="GL_R8I"/>
+ <enum name="GL_R8UI"/>
+ <enum name="GL_R16I"/>
+ <enum name="GL_R16UI"/>
+ <enum name="GL_R32I"/>
+ <enum name="GL_R32UI"/>
+ <enum name="GL_RG8I"/>
+ <enum name="GL_RG8UI"/>
+ <enum name="GL_RG16I"/>
+ <enum name="GL_RG16UI"/>
+ <enum name="GL_RG32I"/>
+ <enum name="GL_RG32UI"/>
+ <enum name="GL_VERTEX_ARRAY_BINDING"/>
+ <enum name="GL_R8_SNORM"/>
+ <enum name="GL_RG8_SNORM"/>
+ <enum name="GL_RGB8_SNORM"/>
+ <enum name="GL_RGBA8_SNORM"/>
+ <enum name="GL_SIGNED_NORMALIZED"/>
+ <enum name="GL_PRIMITIVE_RESTART_FIXED_INDEX"/>
+ <enum name="GL_COPY_READ_BUFFER"/>
+ <enum name="GL_COPY_WRITE_BUFFER"/>
+ <enum name="GL_COPY_READ_BUFFER_BINDING"/>
+ <enum name="GL_COPY_WRITE_BUFFER_BINDING"/>
+ <enum name="GL_UNIFORM_BUFFER"/>
+ <enum name="GL_UNIFORM_BUFFER_BINDING"/>
+ <enum name="GL_UNIFORM_BUFFER_START"/>
+ <enum name="GL_UNIFORM_BUFFER_SIZE"/>
+ <enum name="GL_MAX_VERTEX_UNIFORM_BLOCKS"/>
+ <enum name="GL_MAX_FRAGMENT_UNIFORM_BLOCKS"/>
+ <enum name="GL_MAX_COMBINED_UNIFORM_BLOCKS"/>
+ <enum name="GL_MAX_UNIFORM_BUFFER_BINDINGS"/>
+ <enum name="GL_MAX_UNIFORM_BLOCK_SIZE"/>
+ <enum name="GL_MAX_COMBINED_VERTEX_UNIFORM_COMPONENTS"/>
+ <enum name="GL_MAX_COMBINED_FRAGMENT_UNIFORM_COMPONENTS"/>
+ <enum name="GL_UNIFORM_BUFFER_OFFSET_ALIGNMENT"/>
+ <enum name="GL_ACTIVE_UNIFORM_BLOCK_MAX_NAME_LENGTH"/>
+ <enum name="GL_ACTIVE_UNIFORM_BLOCKS"/>
+ <enum name="GL_UNIFORM_TYPE"/>
+ <enum name="GL_UNIFORM_SIZE"/>
+ <enum name="GL_UNIFORM_NAME_LENGTH"/>
+ <enum name="GL_UNIFORM_BLOCK_INDEX"/>
+ <enum name="GL_UNIFORM_OFFSET"/>
+ <enum name="GL_UNIFORM_ARRAY_STRIDE"/>
+ <enum name="GL_UNIFORM_MATRIX_STRIDE"/>
+ <enum name="GL_UNIFORM_IS_ROW_MAJOR"/>
+ <enum name="GL_UNIFORM_BLOCK_BINDING"/>
+ <enum name="GL_UNIFORM_BLOCK_DATA_SIZE"/>
+ <enum name="GL_UNIFORM_BLOCK_NAME_LENGTH"/>
+ <enum name="GL_UNIFORM_BLOCK_ACTIVE_UNIFORMS"/>
+ <enum name="GL_UNIFORM_BLOCK_ACTIVE_UNIFORM_INDICES"/>
+ <enum name="GL_UNIFORM_BLOCK_REFERENCED_BY_VERTEX_SHADER"/>
+ <enum name="GL_UNIFORM_BLOCK_REFERENCED_BY_FRAGMENT_SHADER"/>
+ <enum name="GL_INVALID_INDEX"/>
+ <enum name="GL_MAX_VERTEX_OUTPUT_COMPONENTS"/>
+ <enum name="GL_MAX_FRAGMENT_INPUT_COMPONENTS"/>
+ <enum name="GL_MAX_SERVER_WAIT_TIMEOUT"/>
+ <enum name="GL_OBJECT_TYPE"/>
+ <enum name="GL_SYNC_CONDITION"/>
+ <enum name="GL_SYNC_STATUS"/>
+ <enum name="GL_SYNC_FLAGS"/>
+ <enum name="GL_SYNC_FENCE"/>
+ <enum name="GL_SYNC_GPU_COMMANDS_COMPLETE"/>
+ <enum name="GL_UNSIGNALED"/>
+ <enum name="GL_SIGNALED"/>
+ <enum name="GL_ALREADY_SIGNALED"/>
+ <enum name="GL_TIMEOUT_EXPIRED"/>
+ <enum name="GL_CONDITION_SATISFIED"/>
+ <enum name="GL_WAIT_FAILED"/>
+ <enum name="GL_SYNC_FLUSH_COMMANDS_BIT"/>
+ <enum name="GL_TIMEOUT_IGNORED"/>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY_DIVISOR"/>
+ <enum name="GL_ANY_SAMPLES_PASSED"/>
+ <enum name="GL_ANY_SAMPLES_PASSED_CONSERVATIVE"/>
+ <enum name="GL_SAMPLER_BINDING"/>
+ <enum name="GL_RGB10_A2UI"/>
+ <enum name="GL_TEXTURE_SWIZZLE_R"/>
+ <enum name="GL_TEXTURE_SWIZZLE_G"/>
+ <enum name="GL_TEXTURE_SWIZZLE_B"/>
+ <enum name="GL_TEXTURE_SWIZZLE_A"/>
+ <enum name="GL_GREEN"/>
+ <enum name="GL_BLUE"/>
+ <enum name="GL_INT_2_10_10_10_REV"/>
+ <enum name="GL_TRANSFORM_FEEDBACK"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_PAUSED"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_ACTIVE"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_BINDING"/>
+ <enum name="GL_PROGRAM_BINARY_RETRIEVABLE_HINT"/>
+ <enum name="GL_PROGRAM_BINARY_LENGTH"/>
+ <enum name="GL_NUM_PROGRAM_BINARY_FORMATS"/>
+ <enum name="GL_PROGRAM_BINARY_FORMATS"/>
+ <enum name="GL_COMPRESSED_R11_EAC"/>
+ <enum name="GL_COMPRESSED_SIGNED_R11_EAC"/>
+ <enum name="GL_COMPRESSED_RG11_EAC"/>
+ <enum name="GL_COMPRESSED_SIGNED_RG11_EAC"/>
+ <enum name="GL_COMPRESSED_RGB8_ETC2"/>
+ <enum name="GL_COMPRESSED_SRGB8_ETC2"/>
+ <enum name="GL_COMPRESSED_RGB8_PUNCHTHROUGH_ALPHA1_ETC2"/>
+ <enum name="GL_COMPRESSED_SRGB8_PUNCHTHROUGH_ALPHA1_ETC2"/>
+ <enum name="GL_COMPRESSED_RGBA8_ETC2_EAC"/>
+ <enum name="GL_COMPRESSED_SRGB8_ALPHA8_ETC2_EAC"/>
+ <enum name="GL_TEXTURE_IMMUTABLE_FORMAT"/>
+ <enum name="GL_MAX_ELEMENT_INDEX"/>
+ <enum name="GL_NUM_SAMPLE_COUNTS"/>
+ <enum name="GL_TEXTURE_IMMUTABLE_LEVELS"/>
+ <command name="glReadBuffer"/>
+ <command name="glDrawRangeElements"/>
+ <command name="glTexImage3D"/>
+ <command name="glTexSubImage3D"/>
+ <command name="glCopyTexSubImage3D"/>
+ <command name="glCompressedTexImage3D"/>
+ <command name="glCompressedTexSubImage3D"/>
+ <command name="glGenQueries"/>
+ <command name="glDeleteQueries"/>
+ <command name="glIsQuery"/>
+ <command name="glBeginQuery"/>
+ <command name="glEndQuery"/>
+ <command name="glGetQueryiv"/>
+ <command name="glGetQueryObjectuiv"/>
+ <command name="glUnmapBuffer"/>
+ <command name="glGetBufferPointerv"/>
+ <command name="glDrawBuffers"/>
+ <command name="glUniformMatrix2x3fv"/>
+ <command name="glUniformMatrix3x2fv"/>
+ <command name="glUniformMatrix2x4fv"/>
+ <command name="glUniformMatrix4x2fv"/>
+ <command name="glUniformMatrix3x4fv"/>
+ <command name="glUniformMatrix4x3fv"/>
+ <command name="glBlitFramebuffer"/>
+ <command name="glRenderbufferStorageMultisample"/>
+ <command name="glFramebufferTextureLayer"/>
+ <command name="glMapBufferRange"/>
+ <command name="glFlushMappedBufferRange"/>
+ <command name="glBindVertexArray"/>
+ <command name="glDeleteVertexArrays"/>
+ <command name="glGenVertexArrays"/>
+ <command name="glIsVertexArray"/>
+ <command name="glGetIntegeri_v"/>
+ <command name="glBeginTransformFeedback"/>
+ <command name="glEndTransformFeedback"/>
+ <command name="glBindBufferRange"/>
+ <command name="glBindBufferBase"/>
+ <command name="glTransformFeedbackVaryings"/>
+ <command name="glGetTransformFeedbackVarying"/>
+ <command name="glVertexAttribIPointer"/>
+ <command name="glGetVertexAttribIiv"/>
+ <command name="glGetVertexAttribIuiv"/>
+ <command name="glVertexAttribI4i"/>
+ <command name="glVertexAttribI4ui"/>
+ <command name="glVertexAttribI4iv"/>
+ <command name="glVertexAttribI4uiv"/>
+ <command name="glGetUniformuiv"/>
+ <command name="glGetFragDataLocation"/>
+ <command name="glUniform1ui"/>
+ <command name="glUniform2ui"/>
+ <command name="glUniform3ui"/>
+ <command name="glUniform4ui"/>
+ <command name="glUniform1uiv"/>
+ <command name="glUniform2uiv"/>
+ <command name="glUniform3uiv"/>
+ <command name="glUniform4uiv"/>
+ <command name="glClearBufferiv"/>
+ <command name="glClearBufferuiv"/>
+ <command name="glClearBufferfv"/>
+ <command name="glClearBufferfi"/>
+ <command name="glGetStringi"/>
+ <command name="glCopyBufferSubData"/>
+ <command name="glGetUniformIndices"/>
+ <command name="glGetActiveUniformsiv"/>
+ <command name="glGetUniformBlockIndex"/>
+ <command name="glGetActiveUniformBlockiv"/>
+ <command name="glGetActiveUniformBlockName"/>
+ <command name="glUniformBlockBinding"/>
+ <command name="glDrawArraysInstanced"/>
+ <command name="glDrawElementsInstanced"/>
+ <command name="glFenceSync"/>
+ <command name="glIsSync"/>
+ <command name="glDeleteSync"/>
+ <command name="glClientWaitSync"/>
+ <command name="glWaitSync"/>
+ <command name="glGetInteger64v"/>
+ <command name="glGetSynciv"/>
+ <command name="glGetInteger64i_v"/>
+ <command name="glGetBufferParameteri64v"/>
+ <command name="glGenSamplers"/>
+ <command name="glDeleteSamplers"/>
+ <command name="glIsSampler"/>
+ <command name="glBindSampler"/>
+ <command name="glSamplerParameteri"/>
+ <command name="glSamplerParameteriv"/>
+ <command name="glSamplerParameterf"/>
+ <command name="glSamplerParameterfv"/>
+ <command name="glGetSamplerParameteriv"/>
+ <command name="glGetSamplerParameterfv"/>
+ <command name="glVertexAttribDivisor"/>
+ <command name="glBindTransformFeedback"/>
+ <command name="glDeleteTransformFeedbacks"/>
+ <command name="glGenTransformFeedbacks"/>
+ <command name="glIsTransformFeedback"/>
+ <command name="glPauseTransformFeedback"/>
+ <command name="glResumeTransformFeedback"/>
+ <command name="glGetProgramBinary"/>
+ <command name="glProgramBinary"/>
+ <command name="glProgramParameteri"/>
+ <command name="glInvalidateFramebuffer"/>
+ <command name="glInvalidateSubFramebuffer"/>
+ <command name="glTexStorage2D"/>
+ <command name="glTexStorage3D"/>
+ <command name="glGetInternalformativ"/>
+ </require>
+ </feature>
+ <feature api="gles2" name="GL_ES_VERSION_3_1" number="3.1">
+ <!-- arrays_of_arrays features -->
+ <require/>
+ <!-- compute_shader features -->
+ <require>
+ <command name="glDispatchCompute"/>
+ <command name="glDispatchComputeIndirect"/>
+ <enum name="GL_COMPUTE_SHADER"/>
+ <enum name="GL_MAX_COMPUTE_UNIFORM_BLOCKS"/>
+ <enum name="GL_MAX_COMPUTE_TEXTURE_IMAGE_UNITS"/>
+ <enum name="GL_MAX_COMPUTE_IMAGE_UNIFORMS"/>
+ <enum name="GL_MAX_COMPUTE_SHARED_MEMORY_SIZE"/>
+ <enum name="GL_MAX_COMPUTE_UNIFORM_COMPONENTS"/>
+ <enum name="GL_MAX_COMPUTE_ATOMIC_COUNTER_BUFFERS"/>
+ <enum name="GL_MAX_COMPUTE_ATOMIC_COUNTERS"/>
+ <enum name="GL_MAX_COMBINED_COMPUTE_UNIFORM_COMPONENTS"/>
+ <enum name="GL_MAX_COMPUTE_WORK_GROUP_INVOCATIONS"/>
+ <enum name="GL_MAX_COMPUTE_WORK_GROUP_COUNT"/>
+ <enum name="GL_MAX_COMPUTE_WORK_GROUP_SIZE"/>
+ <enum name="GL_COMPUTE_WORK_GROUP_SIZE"/>
+ <enum name="GL_DISPATCH_INDIRECT_BUFFER"/>
+ <enum name="GL_DISPATCH_INDIRECT_BUFFER_BINDING"/>
+ <enum name="GL_COMPUTE_SHADER_BIT"/>
+ </require>
+ <!-- draw_indirect features -->
+ <require>
+ <command name="glDrawArraysIndirect"/>
+ <command name="glDrawElementsIndirect"/>
+ <enum name="GL_DRAW_INDIRECT_BUFFER"/>
+ <enum name="GL_DRAW_INDIRECT_BUFFER_BINDING"/>
+ </require>
+ <!-- explicit_uniform_location features -->
+ <require>
+ <enum name="GL_MAX_UNIFORM_LOCATIONS"/>
+ </require>
+ <!-- framebuffer_no_attachments features -->
+ <require>
+ <command name="glFramebufferParameteri"/>
+ <command name="glGetFramebufferParameteriv"/>
+ <enum name="GL_FRAMEBUFFER_DEFAULT_WIDTH"/>
+ <enum name="GL_FRAMEBUFFER_DEFAULT_HEIGHT"/>
+ <enum name="GL_FRAMEBUFFER_DEFAULT_SAMPLES"/>
+ <enum name="GL_FRAMEBUFFER_DEFAULT_FIXED_SAMPLE_LOCATIONS"/>
+ <enum name="GL_MAX_FRAMEBUFFER_WIDTH"/>
+ <enum name="GL_MAX_FRAMEBUFFER_HEIGHT"/>
+ <enum name="GL_MAX_FRAMEBUFFER_SAMPLES"/>
+ </require>
+ <!-- program_interface_query features -->
+ <require>
+ <command name="glGetProgramInterfaceiv"/>
+ <command name="glGetProgramResourceIndex"/>
+ <command name="glGetProgramResourceName"/>
+ <command name="glGetProgramResourceiv"/>
+ <command name="glGetProgramResourceLocation"/>
+ <enum name="GL_UNIFORM"/>
+ <enum name="GL_UNIFORM_BLOCK"/>
+ <enum name="GL_PROGRAM_INPUT"/>
+ <enum name="GL_PROGRAM_OUTPUT"/>
+ <enum name="GL_BUFFER_VARIABLE"/>
+ <enum name="GL_SHADER_STORAGE_BLOCK"/>
+ <enum name="GL_ATOMIC_COUNTER_BUFFER"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_VARYING"/>
+ <enum name="GL_ACTIVE_RESOURCES"/>
+ <enum name="GL_MAX_NAME_LENGTH"/>
+ <enum name="GL_MAX_NUM_ACTIVE_VARIABLES"/>
+ <enum name="GL_NAME_LENGTH"/>
+ <enum name="GL_TYPE"/>
+ <enum name="GL_ARRAY_SIZE"/>
+ <enum name="GL_OFFSET"/>
+ <enum name="GL_BLOCK_INDEX"/>
+ <enum name="GL_ARRAY_STRIDE"/>
+ <enum name="GL_MATRIX_STRIDE"/>
+ <enum name="GL_IS_ROW_MAJOR"/>
+ <enum name="GL_ATOMIC_COUNTER_BUFFER_INDEX"/>
+ <enum name="GL_BUFFER_BINDING"/>
+ <enum name="GL_BUFFER_DATA_SIZE"/>
+ <enum name="GL_NUM_ACTIVE_VARIABLES"/>
+ <enum name="GL_ACTIVE_VARIABLES"/>
+ <enum name="GL_REFERENCED_BY_VERTEX_SHADER"/>
+ <enum name="GL_REFERENCED_BY_FRAGMENT_SHADER"/>
+ <enum name="GL_REFERENCED_BY_COMPUTE_SHADER"/>
+ <enum name="GL_TOP_LEVEL_ARRAY_SIZE"/>
+ <enum name="GL_TOP_LEVEL_ARRAY_STRIDE"/>
+ <enum name="GL_LOCATION"/>
+ </require>
+ <!-- separate_shader_objects features -->
+ <require>
+ <command name="glUseProgramStages"/>
+ <command name="glActiveShaderProgram"/>
+ <command name="glCreateShaderProgramv"/>
+ <command name="glBindProgramPipeline"/>
+ <command name="glDeleteProgramPipelines"/>
+ <command name="glGenProgramPipelines"/>
+ <command name="glIsProgramPipeline"/>
+ <command name="glGetProgramPipelineiv"/>
+ <command name="glProgramUniform1i"/>
+ <command name="glProgramUniform2i"/>
+ <command name="glProgramUniform3i"/>
+ <command name="glProgramUniform4i"/>
+ <command name="glProgramUniform1ui"/>
+ <command name="glProgramUniform2ui"/>
+ <command name="glProgramUniform3ui"/>
+ <command name="glProgramUniform4ui"/>
+ <command name="glProgramUniform1f"/>
+ <command name="glProgramUniform2f"/>
+ <command name="glProgramUniform3f"/>
+ <command name="glProgramUniform4f"/>
+ <command name="glProgramUniform1iv"/>
+ <command name="glProgramUniform2iv"/>
+ <command name="glProgramUniform3iv"/>
+ <command name="glProgramUniform4iv"/>
+ <command name="glProgramUniform1uiv"/>
+ <command name="glProgramUniform2uiv"/>
+ <command name="glProgramUniform3uiv"/>
+ <command name="glProgramUniform4uiv"/>
+ <command name="glProgramUniform1fv"/>
+ <command name="glProgramUniform2fv"/>
+ <command name="glProgramUniform3fv"/>
+ <command name="glProgramUniform4fv"/>
+ <command name="glProgramUniformMatrix2fv"/>
+ <command name="glProgramUniformMatrix3fv"/>
+ <command name="glProgramUniformMatrix4fv"/>
+ <command name="glProgramUniformMatrix2x3fv"/>
+ <command name="glProgramUniformMatrix3x2fv"/>
+ <command name="glProgramUniformMatrix2x4fv"/>
+ <command name="glProgramUniformMatrix4x2fv"/>
+ <command name="glProgramUniformMatrix3x4fv"/>
+ <command name="glProgramUniformMatrix4x3fv"/>
+ <command name="glValidateProgramPipeline"/>
+ <command name="glGetProgramPipelineInfoLog"/>
+ <enum name="GL_VERTEX_SHADER_BIT"/>
+ <enum name="GL_FRAGMENT_SHADER_BIT"/>
+ <enum name="GL_ALL_SHADER_BITS"/>
+ <enum name="GL_PROGRAM_SEPARABLE"/>
+ <enum name="GL_ACTIVE_PROGRAM"/>
+ <enum name="GL_PROGRAM_PIPELINE_BINDING"/>
+ </require>
+ <!-- shader_atomic_counters features -->
+ <require>
+ <enum name="GL_ATOMIC_COUNTER_BUFFER"/>
+ <enum name="GL_ATOMIC_COUNTER_BUFFER_BINDING"/>
+ <enum name="GL_ATOMIC_COUNTER_BUFFER_START"/>
+ <enum name="GL_ATOMIC_COUNTER_BUFFER_SIZE"/>
+ <enum name="GL_MAX_VERTEX_ATOMIC_COUNTER_BUFFERS"/>
+ <enum name="GL_MAX_FRAGMENT_ATOMIC_COUNTER_BUFFERS"/>
+ <enum name="GL_MAX_COMPUTE_ATOMIC_COUNTER_BUFFERS"/>
+ <enum name="GL_MAX_COMBINED_ATOMIC_COUNTER_BUFFERS"/>
+ <enum name="GL_MAX_VERTEX_ATOMIC_COUNTERS"/>
+ <enum name="GL_MAX_FRAGMENT_ATOMIC_COUNTERS"/>
+ <enum name="GL_MAX_COMPUTE_ATOMIC_COUNTERS"/>
+ <enum name="GL_MAX_COMBINED_ATOMIC_COUNTERS"/>
+ <enum name="GL_MAX_ATOMIC_COUNTER_BUFFER_SIZE"/>
+ <enum name="GL_MAX_ATOMIC_COUNTER_BUFFER_BINDINGS"/>
+ <enum name="GL_ACTIVE_ATOMIC_COUNTER_BUFFERS"/>
+ <enum name="GL_UNSIGNED_INT_ATOMIC_COUNTER"/>
+ </require>
+ <!-- shader_bitfield_operations features -->
+ <require/>
+ <!-- shader_image_load_store features -->
+ <require>
+ <command name="glBindImageTexture"/>
+ <command name="glGetBooleani_v"/>
+ <command name="glMemoryBarrier"/>
+ <command name="glMemoryBarrierByRegion"/>
+ <enum name="GL_MAX_IMAGE_UNITS"/>
+ <enum name="GL_MAX_VERTEX_IMAGE_UNIFORMS"/>
+ <enum name="GL_MAX_FRAGMENT_IMAGE_UNIFORMS"/>
+ <enum name="GL_MAX_COMPUTE_IMAGE_UNIFORMS"/>
+ <enum name="GL_MAX_COMBINED_IMAGE_UNIFORMS"/>
+ <enum name="GL_IMAGE_BINDING_NAME"/>
+ <enum name="GL_IMAGE_BINDING_LEVEL"/>
+ <enum name="GL_IMAGE_BINDING_LAYERED"/>
+ <enum name="GL_IMAGE_BINDING_LAYER"/>
+ <enum name="GL_IMAGE_BINDING_ACCESS"/>
+ <enum name="GL_IMAGE_BINDING_FORMAT"/>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY_BARRIER_BIT"/>
+ <enum name="GL_ELEMENT_ARRAY_BARRIER_BIT"/>
+ <enum name="GL_UNIFORM_BARRIER_BIT"/>
+ <enum name="GL_TEXTURE_FETCH_BARRIER_BIT"/>
+ <enum name="GL_SHADER_IMAGE_ACCESS_BARRIER_BIT"/>
+ <enum name="GL_COMMAND_BARRIER_BIT"/>
+ <enum name="GL_PIXEL_BUFFER_BARRIER_BIT"/>
+ <enum name="GL_TEXTURE_UPDATE_BARRIER_BIT"/>
+ <enum name="GL_BUFFER_UPDATE_BARRIER_BIT"/>
+ <enum name="GL_FRAMEBUFFER_BARRIER_BIT"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_BARRIER_BIT"/>
+ <enum name="GL_ATOMIC_COUNTER_BARRIER_BIT"/>
+ <enum name="GL_ALL_BARRIER_BITS"/>
+ <enum name="GL_IMAGE_2D"/>
+ <enum name="GL_IMAGE_3D"/>
+ <enum name="GL_IMAGE_CUBE"/>
+ <enum name="GL_IMAGE_2D_ARRAY"/>
+ <enum name="GL_INT_IMAGE_2D"/>
+ <enum name="GL_INT_IMAGE_3D"/>
+ <enum name="GL_INT_IMAGE_CUBE"/>
+ <enum name="GL_INT_IMAGE_2D_ARRAY"/>
+ <enum name="GL_UNSIGNED_INT_IMAGE_2D"/>
+ <enum name="GL_UNSIGNED_INT_IMAGE_3D"/>
+ <enum name="GL_UNSIGNED_INT_IMAGE_CUBE"/>
+ <enum name="GL_UNSIGNED_INT_IMAGE_2D_ARRAY"/>
+ <enum name="GL_IMAGE_FORMAT_COMPATIBILITY_TYPE"/>
+ <enum name="GL_IMAGE_FORMAT_COMPATIBILITY_BY_SIZE"/>
+ <enum name="GL_IMAGE_FORMAT_COMPATIBILITY_BY_CLASS"/>
+ <enum name="GL_READ_ONLY"/>
+ <enum name="GL_WRITE_ONLY"/>
+ <enum name="GL_READ_WRITE"/>
+ </require>
+ <!-- shader_layout_binding features -->
+ <require/>
+ <!-- shader_storage_buffer_object features -->
+ <require>
+ <enum name="GL_SHADER_STORAGE_BUFFER"/>
+ <enum name="GL_SHADER_STORAGE_BUFFER_BINDING"/>
+ <enum name="GL_SHADER_STORAGE_BUFFER_START"/>
+ <enum name="GL_SHADER_STORAGE_BUFFER_SIZE"/>
+ <enum name="GL_MAX_VERTEX_SHADER_STORAGE_BLOCKS"/>
+ <enum name="GL_MAX_FRAGMENT_SHADER_STORAGE_BLOCKS"/>
+ <enum name="GL_MAX_COMPUTE_SHADER_STORAGE_BLOCKS"/>
+ <enum name="GL_MAX_COMBINED_SHADER_STORAGE_BLOCKS"/>
+ <enum name="GL_MAX_SHADER_STORAGE_BUFFER_BINDINGS"/>
+ <enum name="GL_MAX_SHADER_STORAGE_BLOCK_SIZE"/>
+ <enum name="GL_SHADER_STORAGE_BUFFER_OFFSET_ALIGNMENT"/>
+ <enum name="GL_SHADER_STORAGE_BARRIER_BIT"/>
+ <enum name="GL_MAX_COMBINED_SHADER_OUTPUT_RESOURCES"/>
+ </require>
+ <!-- stencil_texturing features -->
+ <require>
+ <enum name="GL_DEPTH_STENCIL_TEXTURE_MODE"/>
+ <enum name="GL_STENCIL_INDEX"/>
+ </require>
+ <!-- texture_gather features -->
+ <require>
+ <enum name="GL_MIN_PROGRAM_TEXTURE_GATHER_OFFSET"/>
+ <enum name="GL_MAX_PROGRAM_TEXTURE_GATHER_OFFSET"/>
+ </require>
+ <!-- texture_storage_multisample features -->
+ <require>
+ <command name="glTexStorage2DMultisample"/>
+ <command name="glGetMultisamplefv"/>
+ <command name="glSampleMaski"/>
+ <command name="glGetTexLevelParameteriv"/>
+ <command name="glGetTexLevelParameterfv"/>
+ <enum name="GL_SAMPLE_POSITION"/>
+ <enum name="GL_SAMPLE_MASK"/>
+ <enum name="GL_SAMPLE_MASK_VALUE"/>
+ <enum name="GL_TEXTURE_2D_MULTISAMPLE"/>
+ <enum name="GL_MAX_SAMPLE_MASK_WORDS"/>
+ <enum name="GL_MAX_COLOR_TEXTURE_SAMPLES"/>
+ <enum name="GL_MAX_DEPTH_TEXTURE_SAMPLES"/>
+ <enum name="GL_MAX_INTEGER_SAMPLES"/>
+ <enum name="GL_TEXTURE_BINDING_2D_MULTISAMPLE"/>
+ <enum name="GL_TEXTURE_SAMPLES"/>
+ <enum name="GL_TEXTURE_FIXED_SAMPLE_LOCATIONS"/>
+ <enum name="GL_TEXTURE_WIDTH"/>
+ <enum name="GL_TEXTURE_HEIGHT"/>
+ <enum name="GL_TEXTURE_DEPTH"/>
+ <enum name="GL_TEXTURE_INTERNAL_FORMAT"/>
+ <enum name="GL_TEXTURE_RED_SIZE"/>
+ <enum name="GL_TEXTURE_GREEN_SIZE"/>
+ <enum name="GL_TEXTURE_BLUE_SIZE"/>
+ <enum name="GL_TEXTURE_ALPHA_SIZE"/>
+ <enum name="GL_TEXTURE_DEPTH_SIZE"/>
+ <enum name="GL_TEXTURE_STENCIL_SIZE"/>
+ <enum name="GL_TEXTURE_SHARED_SIZE"/>
+ <enum name="GL_TEXTURE_RED_TYPE"/>
+ <enum name="GL_TEXTURE_GREEN_TYPE"/>
+ <enum name="GL_TEXTURE_BLUE_TYPE"/>
+ <enum name="GL_TEXTURE_ALPHA_TYPE"/>
+ <enum name="GL_TEXTURE_DEPTH_TYPE"/>
+ <enum name="GL_TEXTURE_COMPRESSED"/>
+ <enum name="GL_SAMPLER_2D_MULTISAMPLE"/>
+ <enum name="GL_INT_SAMPLER_2D_MULTISAMPLE"/>
+ <enum name="GL_UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE"/>
+ </require>
+ <!-- vertex_attrib_binding features -->
+ <require>
+ <command name="glBindVertexBuffer"/>
+ <command name="glVertexAttribFormat"/>
+ <command name="glVertexAttribIFormat"/>
+ <command name="glVertexAttribBinding"/>
+ <command name="glVertexBindingDivisor"/>
+ <enum name="GL_VERTEX_ATTRIB_BINDING"/>
+ <enum name="GL_VERTEX_ATTRIB_RELATIVE_OFFSET"/>
+ <enum name="GL_VERTEX_BINDING_DIVISOR"/>
+ <enum name="GL_VERTEX_BINDING_OFFSET"/>
+ <enum name="GL_VERTEX_BINDING_STRIDE"/>
+ <enum name="GL_VERTEX_BINDING_BUFFER"/>
+ <enum name="GL_MAX_VERTEX_ATTRIB_RELATIVE_OFFSET"/>
+ <enum name="GL_MAX_VERTEX_ATTRIB_BINDINGS"/>
+ <enum name="GL_MAX_VERTEX_ATTRIB_STRIDE"/>
+ </require>
+ </feature>
+
+ <!-- SECTION: OpenGL / OpenGL ES extension interface definitions -->
+ <extensions>
+ <extension name="GL_3DFX_multisample" supported="gl">
+ <require>
+ <enum name="GL_MULTISAMPLE_3DFX"/>
+ <enum name="GL_SAMPLE_BUFFERS_3DFX"/>
+ <enum name="GL_SAMPLES_3DFX"/>
+ <enum name="GL_MULTISAMPLE_BIT_3DFX"/>
+ </require>
+ </extension>
+ <extension name="GL_3DFX_tbuffer" supported="gl">
+ <require>
+ <command name="glTbufferMask3DFX"/>
+ </require>
+ </extension>
+ <extension name="GL_3DFX_texture_compression_FXT1" supported="gl">
+ <require>
+ <enum name="GL_COMPRESSED_RGB_FXT1_3DFX"/>
+ <enum name="GL_COMPRESSED_RGBA_FXT1_3DFX"/>
+ </require>
+ </extension>
+ <extension name="GL_AMD_blend_minmax_factor" supported="gl">
+ <require>
+ <enum name="GL_FACTOR_MIN_AMD"/>
+ <enum name="GL_FACTOR_MAX_AMD"/>
+ </require>
+ </extension>
+ <extension name="GL_AMD_compressed_3DC_texture" supported="gles1|gles2">
+ <require>
+ <enum name="GL_3DC_X_AMD"/>
+ <enum name="GL_3DC_XY_AMD"/>
+ </require>
+ </extension>
+ <extension name="GL_AMD_compressed_ATC_texture" supported="gles1|gles2">
+ <require>
+ <enum name="GL_ATC_RGB_AMD"/>
+ <enum name="GL_ATC_RGBA_EXPLICIT_ALPHA_AMD"/>
+ <enum name="GL_ATC_RGBA_INTERPOLATED_ALPHA_AMD"/>
+ </require>
+ </extension>
+ <extension name="GL_AMD_conservative_depth" supported="gl"/>
+ <extension name="GL_AMD_debug_output" supported="gl">
+ <require>
+ <enum name="GL_MAX_DEBUG_MESSAGE_LENGTH_AMD"/>
+ <enum name="GL_MAX_DEBUG_LOGGED_MESSAGES_AMD"/>
+ <enum name="GL_DEBUG_LOGGED_MESSAGES_AMD"/>
+ <enum name="GL_DEBUG_SEVERITY_HIGH_AMD"/>
+ <enum name="GL_DEBUG_SEVERITY_MEDIUM_AMD"/>
+ <enum name="GL_DEBUG_SEVERITY_LOW_AMD"/>
+ <enum name="GL_DEBUG_CATEGORY_API_ERROR_AMD"/>
+ <enum name="GL_DEBUG_CATEGORY_WINDOW_SYSTEM_AMD"/>
+ <enum name="GL_DEBUG_CATEGORY_DEPRECATION_AMD"/>
+ <enum name="GL_DEBUG_CATEGORY_UNDEFINED_BEHAVIOR_AMD"/>
+ <enum name="GL_DEBUG_CATEGORY_PERFORMANCE_AMD"/>
+ <enum name="GL_DEBUG_CATEGORY_SHADER_COMPILER_AMD"/>
+ <enum name="GL_DEBUG_CATEGORY_APPLICATION_AMD"/>
+ <enum name="GL_DEBUG_CATEGORY_OTHER_AMD"/>
+ <command name="glDebugMessageEnableAMD"/>
+ <command name="glDebugMessageInsertAMD"/>
+ <command name="glDebugMessageCallbackAMD"/>
+ <command name="glGetDebugMessageLogAMD"/>
+ </require>
+ </extension>
+ <extension name="GL_AMD_depth_clamp_separate" supported="gl">
+ <require>
+ <enum name="GL_DEPTH_CLAMP_NEAR_AMD"/>
+ <enum name="GL_DEPTH_CLAMP_FAR_AMD"/>
+ </require>
+ </extension>
+ <extension name="GL_AMD_draw_buffers_blend" supported="gl">
+ <require>
+ <command name="glBlendFuncIndexedAMD"/>
+ <command name="glBlendFuncSeparateIndexedAMD"/>
+ <command name="glBlendEquationIndexedAMD"/>
+ <command name="glBlendEquationSeparateIndexedAMD"/>
+ </require>
+ </extension>
+ <extension name="GL_AMD_gcn_shader" supported="gl"/>
+ <extension name="GL_AMD_gpu_shader_int64" supported="gl">
+ <require>
+ <enum name="GL_INT64_NV"/>
+ <enum name="GL_UNSIGNED_INT64_NV"/>
+ <enum name="GL_INT8_NV"/>
+ <enum name="GL_INT8_VEC2_NV"/>
+ <enum name="GL_INT8_VEC3_NV"/>
+ <enum name="GL_INT8_VEC4_NV"/>
+ <enum name="GL_INT16_NV"/>
+ <enum name="GL_INT16_VEC2_NV"/>
+ <enum name="GL_INT16_VEC3_NV"/>
+ <enum name="GL_INT16_VEC4_NV"/>
+ <enum name="GL_INT64_VEC2_NV"/>
+ <enum name="GL_INT64_VEC3_NV"/>
+ <enum name="GL_INT64_VEC4_NV"/>
+ <enum name="GL_UNSIGNED_INT8_NV"/>
+ <enum name="GL_UNSIGNED_INT8_VEC2_NV"/>
+ <enum name="GL_UNSIGNED_INT8_VEC3_NV"/>
+ <enum name="GL_UNSIGNED_INT8_VEC4_NV"/>
+ <enum name="GL_UNSIGNED_INT16_NV"/>
+ <enum name="GL_UNSIGNED_INT16_VEC2_NV"/>
+ <enum name="GL_UNSIGNED_INT16_VEC3_NV"/>
+ <enum name="GL_UNSIGNED_INT16_VEC4_NV"/>
+ <enum name="GL_UNSIGNED_INT64_VEC2_NV"/>
+ <enum name="GL_UNSIGNED_INT64_VEC3_NV"/>
+ <enum name="GL_UNSIGNED_INT64_VEC4_NV"/>
+ <enum name="GL_FLOAT16_NV"/>
+ <enum name="GL_FLOAT16_VEC2_NV"/>
+ <enum name="GL_FLOAT16_VEC3_NV"/>
+ <enum name="GL_FLOAT16_VEC4_NV"/>
+ <command name="glUniform1i64NV"/>
+ <command name="glUniform2i64NV"/>
+ <command name="glUniform3i64NV"/>
+ <command name="glUniform4i64NV"/>
+ <command name="glUniform1i64vNV"/>
+ <command name="glUniform2i64vNV"/>
+ <command name="glUniform3i64vNV"/>
+ <command name="glUniform4i64vNV"/>
+ <command name="glUniform1ui64NV"/>
+ <command name="glUniform2ui64NV"/>
+ <command name="glUniform3ui64NV"/>
+ <command name="glUniform4ui64NV"/>
+ <command name="glUniform1ui64vNV"/>
+ <command name="glUniform2ui64vNV"/>
+ <command name="glUniform3ui64vNV"/>
+ <command name="glUniform4ui64vNV"/>
+ <command name="glGetUniformi64vNV"/>
+ <command name="glGetUniformui64vNV"/>
+ </require>
+ <require comment="Supported only if GL_EXT_direct_state_access is supported">
+ <command name="glProgramUniform1i64NV"/>
+ <command name="glProgramUniform2i64NV"/>
+ <command name="glProgramUniform3i64NV"/>
+ <command name="glProgramUniform4i64NV"/>
+ <command name="glProgramUniform1i64vNV"/>
+ <command name="glProgramUniform2i64vNV"/>
+ <command name="glProgramUniform3i64vNV"/>
+ <command name="glProgramUniform4i64vNV"/>
+ <command name="glProgramUniform1ui64NV"/>
+ <command name="glProgramUniform2ui64NV"/>
+ <command name="glProgramUniform3ui64NV"/>
+ <command name="glProgramUniform4ui64NV"/>
+ <command name="glProgramUniform1ui64vNV"/>
+ <command name="glProgramUniform2ui64vNV"/>
+ <command name="glProgramUniform3ui64vNV"/>
+ <command name="glProgramUniform4ui64vNV"/>
+ </require>
+ </extension>
+ <extension name="GL_AMD_interleaved_elements" supported="gl">
+ <require>
+ <enum name="GL_VERTEX_ELEMENT_SWIZZLE_AMD"/>
+ <enum name="GL_VERTEX_ID_SWIZZLE_AMD"/>
+ <enum name="GL_RED"/>
+ <enum name="GL_GREEN"/>
+ <enum name="GL_BLUE"/>
+ <enum name="GL_ALPHA"/>
+ <enum name="GL_RG8UI"/>
+ <enum name="GL_RG16UI"/>
+ <enum name="GL_RGBA8UI"/>
+ <command name="glVertexAttribParameteriAMD"/>
+ </require>
+ </extension>
+ <extension name="GL_AMD_multi_draw_indirect" supported="gl">
+ <require>
+ <command name="glMultiDrawArraysIndirectAMD"/>
+ <command name="glMultiDrawElementsIndirectAMD"/>
+ </require>
+ </extension>
+ <extension name="GL_AMD_name_gen_delete" supported="gl">
+ <require>
+ <enum name="GL_DATA_BUFFER_AMD"/>
+ <enum name="GL_PERFORMANCE_MONITOR_AMD"/>
+ <enum name="GL_QUERY_OBJECT_AMD"/>
+ <enum name="GL_VERTEX_ARRAY_OBJECT_AMD"/>
+ <enum name="GL_SAMPLER_OBJECT_AMD"/>
+ <command name="glGenNamesAMD"/>
+ <command name="glDeleteNamesAMD"/>
+ <command name="glIsNameAMD"/>
+ </require>
+ </extension>
+ <extension name="GL_AMD_occlusion_query_event" supported="gl">
+ <require>
+ <enum name="GL_OCCLUSION_QUERY_EVENT_MASK_AMD"/>
+ <enum name="GL_QUERY_DEPTH_PASS_EVENT_BIT_AMD"/>
+ <enum name="GL_QUERY_DEPTH_FAIL_EVENT_BIT_AMD"/>
+ <enum name="GL_QUERY_STENCIL_FAIL_EVENT_BIT_AMD"/>
+ <enum name="GL_QUERY_DEPTH_BOUNDS_FAIL_EVENT_BIT_AMD"/>
+ <enum name="GL_QUERY_ALL_EVENT_BITS_AMD"/>
+ <command name="glQueryObjectParameteruiAMD"/>
+ </require>
+ </extension>
+ <extension name="GL_AMD_performance_monitor" supported="gl|gles2">
+ <require>
+ <enum name="GL_COUNTER_TYPE_AMD"/>
+ <enum name="GL_COUNTER_RANGE_AMD"/>
+ <enum name="GL_UNSIGNED_INT64_AMD"/>
+ <enum name="GL_PERCENTAGE_AMD"/>
+ <enum name="GL_PERFMON_RESULT_AVAILABLE_AMD"/>
+ <enum name="GL_PERFMON_RESULT_SIZE_AMD"/>
+ <enum name="GL_PERFMON_RESULT_AMD"/>
+ <command name="glGetPerfMonitorGroupsAMD"/>
+ <command name="glGetPerfMonitorCountersAMD"/>
+ <command name="glGetPerfMonitorGroupStringAMD"/>
+ <command name="glGetPerfMonitorCounterStringAMD"/>
+ <command name="glGetPerfMonitorCounterInfoAMD"/>
+ <command name="glGenPerfMonitorsAMD"/>
+ <command name="glDeletePerfMonitorsAMD"/>
+ <command name="glSelectPerfMonitorCountersAMD"/>
+ <command name="glBeginPerfMonitorAMD"/>
+ <command name="glEndPerfMonitorAMD"/>
+ <command name="glGetPerfMonitorCounterDataAMD"/>
+ </require>
+ </extension>
+ <extension name="GL_AMD_pinned_memory" supported="gl">
+ <require>
+ <enum name="GL_EXTERNAL_VIRTUAL_MEMORY_BUFFER_AMD"/>
+ </require>
+ </extension>
+ <extension name="GL_AMD_program_binary_Z400" supported="gles2">
+ <require>
+ <enum name="GL_Z400_BINARY_AMD"/>
+ </require>
+ </extension>
+ <extension name="GL_AMD_query_buffer_object" supported="gl">
+ <require>
+ <enum name="GL_QUERY_BUFFER_AMD"/>
+ <enum name="GL_QUERY_BUFFER_BINDING_AMD"/>
+ <enum name="GL_QUERY_RESULT_NO_WAIT_AMD"/>
+ </require>
+ </extension>
+ <extension name="GL_AMD_sample_positions" supported="gl">
+ <require>
+ <enum name="GL_SUBSAMPLE_DISTANCE_AMD"/>
+ <command name="glSetMultisamplefvAMD"/>
+ </require>
+ </extension>
+ <extension name="GL_AMD_seamless_cubemap_per_texture" supported="gl">
+ <require>
+ <enum name="GL_TEXTURE_CUBE_MAP_SEAMLESS"/>
+ </require>
+ </extension>
+ <extension name="GL_AMD_shader_atomic_counter_ops" supported="gl"/>
+ <extension name="GL_AMD_shader_stencil_export" supported="gl"/>
+ <extension name="GL_AMD_shader_trinary_minmax" supported="gl"/>
+ <extension name="GL_AMD_sparse_texture" supported="gl">
+ <require>
+ <enum name="GL_VIRTUAL_PAGE_SIZE_X_AMD"/>
+ <enum name="GL_VIRTUAL_PAGE_SIZE_Y_AMD"/>
+ <enum name="GL_VIRTUAL_PAGE_SIZE_Z_AMD"/>
+ <enum name="GL_MAX_SPARSE_TEXTURE_SIZE_AMD"/>
+ <enum name="GL_MAX_SPARSE_3D_TEXTURE_SIZE_AMD"/>
+ <enum name="GL_MAX_SPARSE_ARRAY_TEXTURE_LAYERS"/>
+ <enum name="GL_MIN_SPARSE_LEVEL_AMD"/>
+ <enum name="GL_MIN_LOD_WARNING_AMD"/>
+ <enum name="GL_TEXTURE_STORAGE_SPARSE_BIT_AMD"/>
+ <command name="glTexStorageSparseAMD"/>
+ <command name="glTextureStorageSparseAMD"/>
+ </require>
+ </extension>
+ <extension name="GL_AMD_stencil_operation_extended" supported="gl">
+ <require>
+ <enum name="GL_SET_AMD"/>
+ <enum name="GL_REPLACE_VALUE_AMD"/>
+ <enum name="GL_STENCIL_OP_VALUE_AMD"/>
+ <enum name="GL_STENCIL_BACK_OP_VALUE_AMD"/>
+ <command name="glStencilOpValueAMD"/>
+ </require>
+ </extension>
+ <extension name="GL_AMD_texture_texture4" supported="gl"/>
+ <extension name="GL_AMD_transform_feedback3_lines_triangles" supported="gl"/>
+ <extension name="GL_AMD_transform_feedback4" supported="gl">
+ <require>
+ <enum name="GL_STREAM_RASTERIZATION_AMD"/>
+ </require>
+ </extension>
+ <extension name="GL_AMD_vertex_shader_layer" supported="gl"/>
+ <extension name="GL_AMD_vertex_shader_tessellator" supported="gl">
+ <require>
+ <enum name="GL_SAMPLER_BUFFER_AMD"/>
+ <enum name="GL_INT_SAMPLER_BUFFER_AMD"/>
+ <enum name="GL_UNSIGNED_INT_SAMPLER_BUFFER_AMD"/>
+ <enum name="GL_TESSELLATION_MODE_AMD"/>
+ <enum name="GL_TESSELLATION_FACTOR_AMD"/>
+ <enum name="GL_DISCRETE_AMD"/>
+ <enum name="GL_CONTINUOUS_AMD"/>
+ <command name="glTessellationFactorAMD"/>
+ <command name="glTessellationModeAMD"/>
+ </require>
+ </extension>
+ <extension name="GL_AMD_vertex_shader_viewport_index" supported="gl"/>
+ <extension name="GL_ANDROID_extension_pack_es31a" supported="gles2">
+ <require comment="This is an alias for the following extensions. At present gl.xml doesn't actually replicate all their interfaces here.">
+ <!--
+ KHR_debug
+ KHR_texture_compression_astc_ldr
+ KHR_blend_equation_advanced
+ OES_sample_shading
+ OES_sample_variables
+ OES_shader_image_atomic
+ OES_shader_multisample_interpolation
+ OES_texture_stencil8
+ OES_texture_storage_multisample_2d_array
+ EXT_copy_image
+ EXT_draw_buffers_indexed
+ EXT_geometry_shader
+ EXT_gpu_shader5
+ EXT_primitive_bounding_box
+ EXT_shader_io_blocks
+ EXT_tessellation_shader
+ EXT_texture_border_clamp
+ EXT_texture_buffer
+ EXT_texture_cube_map_array
+ EXT_texture_srgb_decode
+ -->
+ </require>
+ </extension>
+ <extension name="GL_ANGLE_depth_texture" supported="gles2">
+ <require>
+ <enum name="GL_DEPTH_COMPONENT"/>
+ <enum name="GL_DEPTH_STENCIL_OES"/>
+ <enum name="GL_UNSIGNED_SHORT"/>
+ <enum name="GL_UNSIGNED_INT"/>
+ <enum name="GL_UNSIGNED_INT_24_8_OES"/>
+ <enum name="GL_DEPTH_COMPONENT16"/>
+ <enum name="GL_DEPTH_COMPONENT32_OES"/>
+ <enum name="GL_DEPTH24_STENCIL8_OES"/>
+ </require>
+ </extension>
+ <extension name="GL_ANGLE_framebuffer_blit" supported="gles2">
+ <require>
+ <enum name="GL_READ_FRAMEBUFFER_ANGLE"/>
+ <enum name="GL_DRAW_FRAMEBUFFER_ANGLE"/>
+ <enum name="GL_DRAW_FRAMEBUFFER_BINDING_ANGLE"/>
+ <enum name="GL_READ_FRAMEBUFFER_BINDING_ANGLE"/>
+ <command name="glBlitFramebufferANGLE"/>
+ </require>
+ </extension>
+ <extension name="GL_ANGLE_framebuffer_multisample" supported="gles2">
+ <require>
+ <enum name="GL_RENDERBUFFER_SAMPLES_ANGLE"/>
+ <enum name="GL_FRAMEBUFFER_INCOMPLETE_MULTISAMPLE_ANGLE"/>
+ <enum name="GL_MAX_SAMPLES_ANGLE"/>
+ <command name="glRenderbufferStorageMultisampleANGLE"/>
+ </require>
+ </extension>
+ <extension name="GL_ANGLE_instanced_arrays" supported="gles2">
+ <require>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY_DIVISOR_ANGLE"/>
+ <command name="glDrawArraysInstancedANGLE"/>
+ <command name="glDrawElementsInstancedANGLE"/>
+ <command name="glVertexAttribDivisorANGLE"/>
+ </require>
+ </extension>
+ <extension name="GL_ANGLE_pack_reverse_row_order" supported="gles2">
+ <require>
+ <enum name="GL_PACK_REVERSE_ROW_ORDER_ANGLE"/>
+ </require>
+ </extension>
+ <extension name="GL_ANGLE_program_binary" supported="gles2">
+ <require>
+ <enum name="GL_PROGRAM_BINARY_ANGLE"/>
+ </require>
+ </extension>
+ <extension name="GL_ANGLE_texture_compression_dxt3" supported="gles2">
+ <require>
+ <enum name="GL_COMPRESSED_RGBA_S3TC_DXT3_ANGLE"/>
+ </require>
+ </extension>
+ <extension name="GL_ANGLE_texture_compression_dxt5" supported="gles2">
+ <require>
+ <enum name="GL_COMPRESSED_RGBA_S3TC_DXT5_ANGLE"/>
+ </require>
+ </extension>
+ <extension name="GL_ANGLE_texture_usage" supported="gles2">
+ <require>
+ <enum name="GL_TEXTURE_USAGE_ANGLE"/>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_ANGLE"/>
+ </require>
+ </extension>
+ <extension name="GL_ANGLE_translated_shader_source" supported="gles2">
+ <require>
+ <enum name="GL_TRANSLATED_SHADER_SOURCE_LENGTH_ANGLE"/>
+ <command name="glGetTranslatedShaderSourceANGLE"/>
+ </require>
+ </extension>
+ <extension name="GL_APPLE_aux_depth_stencil" supported="gl">
+ <require>
+ <enum name="GL_AUX_DEPTH_STENCIL_APPLE"/>
+ </require>
+ </extension>
+ <extension name="GL_APPLE_client_storage" supported="gl">
+ <require>
+ <enum name="GL_UNPACK_CLIENT_STORAGE_APPLE"/>
+ </require>
+ </extension>
+ <extension name="GL_APPLE_copy_texture_levels" supported="gles1|gles2">
+ <require>
+ <command name="glCopyTextureLevelsAPPLE"/>
+ </require>
+ </extension>
+ <extension name="GL_APPLE_element_array" supported="gl">
+ <require>
+ <enum name="GL_ELEMENT_ARRAY_APPLE"/>
+ <enum name="GL_ELEMENT_ARRAY_TYPE_APPLE"/>
+ <enum name="GL_ELEMENT_ARRAY_POINTER_APPLE"/>
+ <command name="glElementPointerAPPLE"/>
+ <command name="glDrawElementArrayAPPLE"/>
+ <command name="glDrawRangeElementArrayAPPLE"/>
+ <command name="glMultiDrawElementArrayAPPLE"/>
+ <command name="glMultiDrawRangeElementArrayAPPLE"/>
+ </require>
+ </extension>
+ <extension name="GL_APPLE_fence" supported="gl">
+ <require>
+ <enum name="GL_DRAW_PIXELS_APPLE"/>
+ <enum name="GL_FENCE_APPLE"/>
+ <command name="glGenFencesAPPLE"/>
+ <command name="glDeleteFencesAPPLE"/>
+ <command name="glSetFenceAPPLE"/>
+ <command name="glIsFenceAPPLE"/>
+ <command name="glTestFenceAPPLE"/>
+ <command name="glFinishFenceAPPLE"/>
+ <command name="glTestObjectAPPLE"/>
+ <command name="glFinishObjectAPPLE"/>
+ </require>
+ </extension>
+ <extension name="GL_APPLE_float_pixels" supported="gl">
+ <require>
+ <enum name="GL_HALF_APPLE"/>
+ <enum name="GL_RGBA_FLOAT32_APPLE"/>
+ <enum name="GL_RGB_FLOAT32_APPLE"/>
+ <enum name="GL_ALPHA_FLOAT32_APPLE"/>
+ <enum name="GL_INTENSITY_FLOAT32_APPLE"/>
+ <enum name="GL_LUMINANCE_FLOAT32_APPLE"/>
+ <enum name="GL_LUMINANCE_ALPHA_FLOAT32_APPLE"/>
+ <enum name="GL_RGBA_FLOAT16_APPLE"/>
+ <enum name="GL_RGB_FLOAT16_APPLE"/>
+ <enum name="GL_ALPHA_FLOAT16_APPLE"/>
+ <enum name="GL_INTENSITY_FLOAT16_APPLE"/>
+ <enum name="GL_LUMINANCE_FLOAT16_APPLE"/>
+ <enum name="GL_LUMINANCE_ALPHA_FLOAT16_APPLE"/>
+ <enum name="GL_COLOR_FLOAT_APPLE"/>
+ </require>
+ </extension>
+ <extension name="GL_APPLE_flush_buffer_range" supported="gl">
+ <require>
+ <enum name="GL_BUFFER_SERIALIZED_MODIFY_APPLE"/>
+ <enum name="GL_BUFFER_FLUSHING_UNMAP_APPLE"/>
+ <command name="glBufferParameteriAPPLE"/>
+ <command name="glFlushMappedBufferRangeAPPLE"/>
+ </require>
+ </extension>
+ <extension name="GL_APPLE_framebuffer_multisample" supported="gles1|gles2">
+ <require>
+ <enum name="GL_RENDERBUFFER_SAMPLES_APPLE"/>
+ <enum name="GL_FRAMEBUFFER_INCOMPLETE_MULTISAMPLE_APPLE"/>
+ <enum name="GL_MAX_SAMPLES_APPLE"/>
+ <enum name="GL_READ_FRAMEBUFFER_APPLE"/>
+ <enum name="GL_DRAW_FRAMEBUFFER_APPLE"/>
+ <enum name="GL_DRAW_FRAMEBUFFER_BINDING_APPLE"/>
+ <enum name="GL_READ_FRAMEBUFFER_BINDING_APPLE"/>
+ <command name="glRenderbufferStorageMultisampleAPPLE"/>
+ <command name="glResolveMultisampleFramebufferAPPLE"/>
+ </require>
+ </extension>
+ <extension name="GL_APPLE_object_purgeable" supported="gl">
+ <require>
+ <enum name="GL_BUFFER_OBJECT_APPLE"/>
+ <enum name="GL_RELEASED_APPLE"/>
+ <enum name="GL_VOLATILE_APPLE"/>
+ <enum name="GL_RETAINED_APPLE"/>
+ <enum name="GL_UNDEFINED_APPLE"/>
+ <enum name="GL_PURGEABLE_APPLE"/>
+ <command name="glObjectPurgeableAPPLE"/>
+ <command name="glObjectUnpurgeableAPPLE"/>
+ <command name="glGetObjectParameterivAPPLE"/>
+ </require>
+ </extension>
+ <extension name="GL_APPLE_rgb_422" supported="gl|gles2">
+ <require>
+ <enum name="GL_RGB_422_APPLE"/>
+ <enum name="GL_UNSIGNED_SHORT_8_8_APPLE"/>
+ <enum name="GL_UNSIGNED_SHORT_8_8_REV_APPLE"/>
+ </require>
+ <require comment="Depends on TexStorage* (EXT_texture_storage / ES 3.0 / GL 4.4 / etc.)">
+ <enum name="GL_RGB_RAW_422_APPLE"/>
+ </require>
+ </extension>
+ <extension name="GL_APPLE_row_bytes" supported="gl">
+ <require>
+ <enum name="GL_PACK_ROW_BYTES_APPLE"/>
+ <enum name="GL_UNPACK_ROW_BYTES_APPLE"/>
+ </require>
+ </extension>
+ <extension name="GL_APPLE_specular_vector" supported="gl">
+ <require>
+ <enum name="GL_LIGHT_MODEL_SPECULAR_VECTOR_APPLE"/>
+ </require>
+ </extension>
+ <extension name="GL_APPLE_sync" supported="gles1|gles2">
+ <require>
+ <enum name="GL_SYNC_OBJECT_APPLE"/>
+ <enum name="GL_MAX_SERVER_WAIT_TIMEOUT_APPLE"/>
+ <enum name="GL_OBJECT_TYPE_APPLE"/>
+ <enum name="GL_SYNC_CONDITION_APPLE"/>
+ <enum name="GL_SYNC_STATUS_APPLE"/>
+ <enum name="GL_SYNC_FLAGS_APPLE"/>
+ <enum name="GL_SYNC_FENCE_APPLE"/>
+ <enum name="GL_SYNC_GPU_COMMANDS_COMPLETE_APPLE"/>
+ <enum name="GL_UNSIGNALED_APPLE"/>
+ <enum name="GL_SIGNALED_APPLE"/>
+ <enum name="GL_ALREADY_SIGNALED_APPLE"/>
+ <enum name="GL_TIMEOUT_EXPIRED_APPLE"/>
+ <enum name="GL_CONDITION_SATISFIED_APPLE"/>
+ <enum name="GL_WAIT_FAILED_APPLE"/>
+ <enum name="GL_SYNC_FLUSH_COMMANDS_BIT_APPLE"/>
+ <enum name="GL_TIMEOUT_IGNORED_APPLE"/>
+ <command name="glFenceSyncAPPLE"/>
+ <command name="glIsSyncAPPLE"/>
+ <command name="glDeleteSyncAPPLE"/>
+ <command name="glClientWaitSyncAPPLE"/>
+ <command name="glWaitSyncAPPLE"/>
+ <command name="glGetInteger64vAPPLE"/>
+ <command name="glGetSyncivAPPLE"/>
+ </require>
+ </extension>
+ <extension name="GL_APPLE_texture_2D_limited_npot" supported="gles1"/>
+ <extension name="GL_APPLE_texture_format_BGRA8888" supported="gles1|gles2">
+ <require>
+ <enum name="GL_BGRA_EXT"/>
+ </require>
+ <require comment="Depends on TexStorage* (EXT_texture_storage / ES 3.0 / GL 4.4 / etc.)">
+ <enum name="GL_BGRA8_EXT"/>
+ </require>
+ </extension>
+ <extension name="GL_APPLE_texture_max_level" supported="gles1|gles2">
+ <require>
+ <enum name="GL_TEXTURE_MAX_LEVEL_APPLE"/>
+ </require>
+ </extension>
+ <extension name="GL_APPLE_texture_range" supported="gl">
+ <require>
+ <enum name="GL_TEXTURE_RANGE_LENGTH_APPLE"/>
+ <enum name="GL_TEXTURE_RANGE_POINTER_APPLE"/>
+ <enum name="GL_TEXTURE_STORAGE_HINT_APPLE"/>
+ <enum name="GL_STORAGE_PRIVATE_APPLE"/>
+ <enum name="GL_STORAGE_CACHED_APPLE"/>
+ <enum name="GL_STORAGE_SHARED_APPLE"/>
+ <command name="glTextureRangeAPPLE"/>
+ <command name="glGetTexParameterPointervAPPLE"/>
+ </require>
+ </extension>
+ <extension name="GL_APPLE_transform_hint" supported="gl">
+ <require>
+ <enum name="GL_TRANSFORM_HINT_APPLE"/>
+ </require>
+ </extension>
+ <extension name="GL_APPLE_vertex_array_object" supported="gl">
+ <require>
+ <enum name="GL_VERTEX_ARRAY_BINDING_APPLE"/>
+ <command name="glBindVertexArrayAPPLE"/>
+ <command name="glDeleteVertexArraysAPPLE"/>
+ <command name="glGenVertexArraysAPPLE"/>
+ <command name="glIsVertexArrayAPPLE"/>
+ </require>
+ </extension>
+ <extension name="GL_APPLE_vertex_array_range" supported="gl">
+ <require>
+ <enum name="GL_VERTEX_ARRAY_RANGE_APPLE"/>
+ <enum name="GL_VERTEX_ARRAY_RANGE_LENGTH_APPLE"/>
+ <enum name="GL_VERTEX_ARRAY_STORAGE_HINT_APPLE"/>
+ <enum name="GL_VERTEX_ARRAY_RANGE_POINTER_APPLE"/>
+ <enum name="GL_STORAGE_CLIENT_APPLE"/>
+ <enum name="GL_STORAGE_CACHED_APPLE"/>
+ <enum name="GL_STORAGE_SHARED_APPLE"/>
+ <command name="glVertexArrayRangeAPPLE"/>
+ <command name="glFlushVertexArrayRangeAPPLE"/>
+ <command name="glVertexArrayParameteriAPPLE"/>
+ </require>
+ </extension>
+ <extension name="GL_APPLE_vertex_program_evaluators" supported="gl">
+ <require>
+ <enum name="GL_VERTEX_ATTRIB_MAP1_APPLE"/>
+ <enum name="GL_VERTEX_ATTRIB_MAP2_APPLE"/>
+ <enum name="GL_VERTEX_ATTRIB_MAP1_SIZE_APPLE"/>
+ <enum name="GL_VERTEX_ATTRIB_MAP1_COEFF_APPLE"/>
+ <enum name="GL_VERTEX_ATTRIB_MAP1_ORDER_APPLE"/>
+ <enum name="GL_VERTEX_ATTRIB_MAP1_DOMAIN_APPLE"/>
+ <enum name="GL_VERTEX_ATTRIB_MAP2_SIZE_APPLE"/>
+ <enum name="GL_VERTEX_ATTRIB_MAP2_COEFF_APPLE"/>
+ <enum name="GL_VERTEX_ATTRIB_MAP2_ORDER_APPLE"/>
+ <enum name="GL_VERTEX_ATTRIB_MAP2_DOMAIN_APPLE"/>
+ <command name="glEnableVertexAttribAPPLE"/>
+ <command name="glDisableVertexAttribAPPLE"/>
+ <command name="glIsVertexAttribEnabledAPPLE"/>
+ <command name="glMapVertexAttrib1dAPPLE"/>
+ <command name="glMapVertexAttrib1fAPPLE"/>
+ <command name="glMapVertexAttrib2dAPPLE"/>
+ <command name="glMapVertexAttrib2fAPPLE"/>
+ </require>
+ </extension>
+ <extension name="GL_APPLE_ycbcr_422" supported="gl">
+ <require>
+ <enum name="GL_YCBCR_422_APPLE"/>
+ <enum name="GL_UNSIGNED_SHORT_8_8_APPLE"/>
+ <enum name="GL_UNSIGNED_SHORT_8_8_REV_APPLE"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_ES2_compatibility" supported="gl|glcore">
+ <require>
+ <enum name="GL_FIXED"/>
+ <enum name="GL_IMPLEMENTATION_COLOR_READ_TYPE"/>
+ <enum name="GL_IMPLEMENTATION_COLOR_READ_FORMAT"/>
+ <enum name="GL_LOW_FLOAT"/>
+ <enum name="GL_MEDIUM_FLOAT"/>
+ <enum name="GL_HIGH_FLOAT"/>
+ <enum name="GL_LOW_INT"/>
+ <enum name="GL_MEDIUM_INT"/>
+ <enum name="GL_HIGH_INT"/>
+ <enum name="GL_SHADER_COMPILER"/>
+ <enum name="GL_SHADER_BINARY_FORMATS"/>
+ <enum name="GL_NUM_SHADER_BINARY_FORMATS"/>
+ <enum name="GL_MAX_VERTEX_UNIFORM_VECTORS"/>
+ <enum name="GL_MAX_VARYING_VECTORS"/>
+ <enum name="GL_MAX_FRAGMENT_UNIFORM_VECTORS"/>
+ <enum name="GL_RGB565"/>
+ <command name="glReleaseShaderCompiler"/>
+ <command name="glShaderBinary"/>
+ <command name="glGetShaderPrecisionFormat"/>
+ <command name="glDepthRangef"/>
+ <command name="glClearDepthf"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_ES3_1_compatibility" supported="gl|glcore">
+ <require>
+ <command name="glMemoryBarrierByRegion"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_ES3_compatibility" supported="gl|glcore">
+ <require>
+ <enum name="GL_COMPRESSED_RGB8_ETC2"/>
+ <enum name="GL_COMPRESSED_SRGB8_ETC2"/>
+ <enum name="GL_COMPRESSED_RGB8_PUNCHTHROUGH_ALPHA1_ETC2"/>
+ <enum name="GL_COMPRESSED_SRGB8_PUNCHTHROUGH_ALPHA1_ETC2"/>
+ <enum name="GL_COMPRESSED_RGBA8_ETC2_EAC"/>
+ <enum name="GL_COMPRESSED_SRGB8_ALPHA8_ETC2_EAC"/>
+ <enum name="GL_COMPRESSED_R11_EAC"/>
+ <enum name="GL_COMPRESSED_SIGNED_R11_EAC"/>
+ <enum name="GL_COMPRESSED_RG11_EAC"/>
+ <enum name="GL_COMPRESSED_SIGNED_RG11_EAC"/>
+ <enum name="GL_PRIMITIVE_RESTART_FIXED_INDEX"/>
+ <enum name="GL_ANY_SAMPLES_PASSED_CONSERVATIVE"/>
+ <enum name="GL_MAX_ELEMENT_INDEX"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_arrays_of_arrays" supported="gl|glcore"/>
+ <extension name="GL_ARB_base_instance" supported="gl|glcore">
+ <require>
+ <command name="glDrawArraysInstancedBaseInstance"/>
+ <command name="glDrawElementsInstancedBaseInstance"/>
+ <command name="glDrawElementsInstancedBaseVertexBaseInstance"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_bindless_texture" supported="gl|glcore">
+ <require>
+ <enum name="GL_UNSIGNED_INT64_ARB"/>
+ <command name="glGetTextureHandleARB"/>
+ <command name="glGetTextureSamplerHandleARB"/>
+ <command name="glMakeTextureHandleResidentARB"/>
+ <command name="glMakeTextureHandleNonResidentARB"/>
+ <command name="glGetImageHandleARB"/>
+ <command name="glMakeImageHandleResidentARB"/>
+ <command name="glMakeImageHandleNonResidentARB"/>
+ <command name="glUniformHandleui64ARB"/>
+ <command name="glUniformHandleui64vARB"/>
+ <command name="glProgramUniformHandleui64ARB"/>
+ <command name="glProgramUniformHandleui64vARB"/>
+ <command name="glIsTextureHandleResidentARB"/>
+ <command name="glIsImageHandleResidentARB"/>
+ <command name="glVertexAttribL1ui64ARB"/>
+ <command name="glVertexAttribL1ui64vARB"/>
+ <command name="glGetVertexAttribLui64vARB"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_blend_func_extended" supported="gl|glcore">
+ <require>
+ <enum name="GL_SRC1_COLOR"/>
+ <enum name="GL_SRC1_ALPHA"/>
+ <enum name="GL_ONE_MINUS_SRC1_COLOR"/>
+ <enum name="GL_ONE_MINUS_SRC1_ALPHA"/>
+ <enum name="GL_MAX_DUAL_SOURCE_DRAW_BUFFERS"/>
+ <command name="glBindFragDataLocationIndexed"/>
+ <command name="glGetFragDataIndex"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_buffer_storage" supported="gl|glcore">
+ <require>
+ <enum name="GL_MAP_READ_BIT"/>
+ <enum name="GL_MAP_WRITE_BIT"/>
+ <enum name="GL_MAP_PERSISTENT_BIT"/>
+ <enum name="GL_MAP_COHERENT_BIT"/>
+ <enum name="GL_DYNAMIC_STORAGE_BIT"/>
+ <enum name="GL_CLIENT_STORAGE_BIT"/>
+ <enum name="GL_CLIENT_MAPPED_BUFFER_BARRIER_BIT"/>
+ <enum name="GL_BUFFER_IMMUTABLE_STORAGE"/>
+ <enum name="GL_BUFFER_STORAGE_FLAGS"/>
+ <command name="glBufferStorage"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_cl_event" supported="gl|glcore">
+ <require>
+ <enum name="GL_SYNC_CL_EVENT_ARB"/>
+ <enum name="GL_SYNC_CL_EVENT_COMPLETE_ARB"/>
+ <command name="glCreateSyncFromCLeventARB"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_clear_buffer_object" supported="gl|glcore">
+ <require>
+ <command name="glClearBufferData"/>
+ <command name="glClearBufferSubData"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_clear_texture" supported="gl|glcore">
+ <require>
+ <enum name="GL_CLEAR_TEXTURE"/>
+ <command name="glClearTexImage"/>
+ <command name="glClearTexSubImage"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_clip_control" supported="gl|glcore">
+ <require>
+ <command name="glClipControl"/>
+ <enum name="GL_LOWER_LEFT"/>
+ <enum name="GL_UPPER_LEFT"/>
+ <enum name="GL_NEGATIVE_ONE_TO_ONE"/>
+ <enum name="GL_ZERO_TO_ONE"/>
+ <enum name="GL_CLIP_ORIGIN"/>
+ <enum name="GL_CLIP_DEPTH_MODE"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_color_buffer_float" supported="gl">
+ <require>
+ <enum name="GL_RGBA_FLOAT_MODE_ARB"/>
+ <enum name="GL_CLAMP_VERTEX_COLOR_ARB"/>
+ <enum name="GL_CLAMP_FRAGMENT_COLOR_ARB"/>
+ <enum name="GL_CLAMP_READ_COLOR_ARB"/>
+ <enum name="GL_FIXED_ONLY_ARB"/>
+ <command name="glClampColorARB"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_compatibility" supported="gl">
+ <require comment="Defines features from OpenGL 3.0 that were removed in OpenGL 3.1 - not enumerated here yet">
+ </require>
+ </extension>
+ <extension name="GL_ARB_compressed_texture_pixel_storage" supported="gl|glcore">
+ <require>
+ <enum name="GL_UNPACK_COMPRESSED_BLOCK_WIDTH"/>
+ <enum name="GL_UNPACK_COMPRESSED_BLOCK_HEIGHT"/>
+ <enum name="GL_UNPACK_COMPRESSED_BLOCK_DEPTH"/>
+ <enum name="GL_UNPACK_COMPRESSED_BLOCK_SIZE"/>
+ <enum name="GL_PACK_COMPRESSED_BLOCK_WIDTH"/>
+ <enum name="GL_PACK_COMPRESSED_BLOCK_HEIGHT"/>
+ <enum name="GL_PACK_COMPRESSED_BLOCK_DEPTH"/>
+ <enum name="GL_PACK_COMPRESSED_BLOCK_SIZE"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_compute_shader" supported="gl|glcore">
+ <require>
+ <enum name="GL_COMPUTE_SHADER"/>
+ <enum name="GL_MAX_COMPUTE_UNIFORM_BLOCKS"/>
+ <enum name="GL_MAX_COMPUTE_TEXTURE_IMAGE_UNITS"/>
+ <enum name="GL_MAX_COMPUTE_IMAGE_UNIFORMS"/>
+ <enum name="GL_MAX_COMPUTE_SHARED_MEMORY_SIZE"/>
+ <enum name="GL_MAX_COMPUTE_UNIFORM_COMPONENTS"/>
+ <enum name="GL_MAX_COMPUTE_ATOMIC_COUNTER_BUFFERS"/>
+ <enum name="GL_MAX_COMPUTE_ATOMIC_COUNTERS"/>
+ <enum name="GL_MAX_COMBINED_COMPUTE_UNIFORM_COMPONENTS"/>
+ <enum name="GL_MAX_COMPUTE_WORK_GROUP_INVOCATIONS"/>
+ <enum name="GL_MAX_COMPUTE_WORK_GROUP_COUNT"/>
+ <enum name="GL_MAX_COMPUTE_WORK_GROUP_SIZE"/>
+ <enum name="GL_COMPUTE_WORK_GROUP_SIZE"/>
+ <enum name="GL_UNIFORM_BLOCK_REFERENCED_BY_COMPUTE_SHADER"/>
+ <enum name="GL_ATOMIC_COUNTER_BUFFER_REFERENCED_BY_COMPUTE_SHADER"/>
+ <enum name="GL_DISPATCH_INDIRECT_BUFFER"/>
+ <enum name="GL_DISPATCH_INDIRECT_BUFFER_BINDING"/>
+ <enum name="GL_COMPUTE_SHADER_BIT"/>
+ <command name="glDispatchCompute"/>
+ <command name="glDispatchComputeIndirect"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_compute_variable_group_size" supported="gl|glcore">
+ <require>
+ <enum name="GL_MAX_COMPUTE_VARIABLE_GROUP_INVOCATIONS_ARB"/>
+ <enum name="GL_MAX_COMPUTE_FIXED_GROUP_INVOCATIONS_ARB"/>
+ <enum name="GL_MAX_COMPUTE_VARIABLE_GROUP_SIZE_ARB"/>
+ <enum name="GL_MAX_COMPUTE_FIXED_GROUP_SIZE_ARB"/>
+ <command name="glDispatchComputeGroupSizeARB"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_conditional_render_inverted" supported="gl|glcore">
+ <require>
+ <enum name="GL_QUERY_WAIT_INVERTED"/>
+ <enum name="GL_QUERY_NO_WAIT_INVERTED"/>
+ <enum name="GL_QUERY_BY_REGION_WAIT_INVERTED"/>
+ <enum name="GL_QUERY_BY_REGION_NO_WAIT_INVERTED"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_conservative_depth" supported="gl|glcore"/>
+ <extension name="GL_ARB_copy_buffer" supported="gl|glcore">
+ <require>
+ <enum name="GL_COPY_READ_BUFFER_BINDING"/>
+ <enum name="GL_COPY_READ_BUFFER"/>
+ <enum name="GL_COPY_WRITE_BUFFER_BINDING"/>
+ <enum name="GL_COPY_WRITE_BUFFER"/>
+ <command name="glCopyBufferSubData"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_copy_image" supported="gl|glcore">
+ <require>
+ <command name="glCopyImageSubData"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_cull_distance" supported="gl|glcore">
+ <require>
+ <enum name="GL_MAX_CULL_DISTANCES"/>
+ <enum name="GL_MAX_COMBINED_CLIP_AND_CULL_DISTANCES"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_debug_output" supported="gl|glcore">
+ <require>
+ <enum name="GL_DEBUG_OUTPUT_SYNCHRONOUS_ARB"/>
+ <enum name="GL_DEBUG_NEXT_LOGGED_MESSAGE_LENGTH_ARB"/>
+ <enum name="GL_DEBUG_CALLBACK_FUNCTION_ARB"/>
+ <enum name="GL_DEBUG_CALLBACK_USER_PARAM_ARB"/>
+ <enum name="GL_DEBUG_SOURCE_API_ARB"/>
+ <enum name="GL_DEBUG_SOURCE_WINDOW_SYSTEM_ARB"/>
+ <enum name="GL_DEBUG_SOURCE_SHADER_COMPILER_ARB"/>
+ <enum name="GL_DEBUG_SOURCE_THIRD_PARTY_ARB"/>
+ <enum name="GL_DEBUG_SOURCE_APPLICATION_ARB"/>
+ <enum name="GL_DEBUG_SOURCE_OTHER_ARB"/>
+ <enum name="GL_DEBUG_TYPE_ERROR_ARB"/>
+ <enum name="GL_DEBUG_TYPE_DEPRECATED_BEHAVIOR_ARB"/>
+ <enum name="GL_DEBUG_TYPE_UNDEFINED_BEHAVIOR_ARB"/>
+ <enum name="GL_DEBUG_TYPE_PORTABILITY_ARB"/>
+ <enum name="GL_DEBUG_TYPE_PERFORMANCE_ARB"/>
+ <enum name="GL_DEBUG_TYPE_OTHER_ARB"/>
+ <enum name="GL_MAX_DEBUG_MESSAGE_LENGTH_ARB"/>
+ <enum name="GL_MAX_DEBUG_LOGGED_MESSAGES_ARB"/>
+ <enum name="GL_DEBUG_LOGGED_MESSAGES_ARB"/>
+ <enum name="GL_DEBUG_SEVERITY_HIGH_ARB"/>
+ <enum name="GL_DEBUG_SEVERITY_MEDIUM_ARB"/>
+ <enum name="GL_DEBUG_SEVERITY_LOW_ARB"/>
+ <command name="glDebugMessageControlARB"/>
+ <command name="glDebugMessageInsertARB"/>
+ <command name="glDebugMessageCallbackARB"/>
+ <command name="glGetDebugMessageLogARB"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_depth_buffer_float" supported="gl|glcore">
+ <require>
+ <enum name="GL_DEPTH_COMPONENT32F"/>
+ <enum name="GL_DEPTH32F_STENCIL8"/>
+ <enum name="GL_FLOAT_32_UNSIGNED_INT_24_8_REV"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_depth_clamp" supported="gl|glcore">
+ <require>
+ <enum name="GL_DEPTH_CLAMP"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_depth_texture" supported="gl">
+ <require>
+ <enum name="GL_DEPTH_COMPONENT16_ARB"/>
+ <enum name="GL_DEPTH_COMPONENT24_ARB"/>
+ <enum name="GL_DEPTH_COMPONENT32_ARB"/>
+ <enum name="GL_TEXTURE_DEPTH_SIZE_ARB"/>
+ <enum name="GL_DEPTH_TEXTURE_MODE_ARB"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_derivative_control" supported="gl|glcore"/>
+ <extension name="GL_ARB_direct_state_access" supported="gl|glcore">
+ <require>
+ <enum name="GL_TEXTURE_TARGET"/>
+ <enum name="GL_QUERY_TARGET"/>
+ <enum name="GL_TEXTURE_BINDING_1D"/>
+ <enum name="GL_TEXTURE_BINDING_1D_ARRAY"/>
+ <enum name="GL_TEXTURE_BINDING_2D"/>
+ <enum name="GL_TEXTURE_BINDING_2D_ARRAY"/>
+ <enum name="GL_TEXTURE_BINDING_2D_MULTISAMPLE"/>
+ <enum name="GL_TEXTURE_BINDING_2D_MULTISAMPLE_ARRAY"/>
+ <enum name="GL_TEXTURE_BINDING_3D"/>
+ <enum name="GL_TEXTURE_BINDING_BUFFER"/>
+ <enum name="GL_TEXTURE_BINDING_CUBE_MAP"/>
+ <enum name="GL_TEXTURE_BINDING_CUBE_MAP_ARRAY"/>
+ <enum name="GL_TEXTURE_BINDING_RECTANGLE"/>
+ <enum name="GL_TEXTURE_BINDING"/>
+ </require>
+ <require comment="Transform Feedback object functions">
+ <command name="glCreateTransformFeedbacks"/>
+ <command name="glTransformFeedbackBufferBase"/>
+ <command name="glTransformFeedbackBufferRange"/>
+ <command name="glGetTransformFeedbackiv"/>
+ <command name="glGetTransformFeedbacki_v"/>
+ <command name="glGetTransformFeedbacki64_v"/>
+ </require>
+ <require comment="Buffer object functions">
+ <command name="glCreateBuffers"/>
+ <command name="glNamedBufferStorage"/>
+ <command name="glNamedBufferData"/>
+ <command name="glNamedBufferSubData"/>
+ <command name="glCopyNamedBufferSubData"/>
+ <command name="glClearNamedBufferData"/>
+ <command name="glClearNamedBufferSubData"/>
+ <command name="glMapNamedBuffer"/>
+ <command name="glMapNamedBufferRange"/>
+ <command name="glUnmapNamedBuffer"/>
+ <command name="glFlushMappedNamedBufferRange"/>
+ <command name="glGetNamedBufferParameteriv"/>
+ <command name="glGetNamedBufferParameteri64v"/>
+ <command name="glGetNamedBufferPointerv"/>
+ <command name="glGetNamedBufferSubData"/>
+ </require>
+ <require comment="Framebuffer object functions">
+ <command name="glCreateFramebuffers"/>
+ <command name="glNamedFramebufferRenderbuffer"/>
+ <command name="glNamedFramebufferParameteri"/>
+ <command name="glNamedFramebufferTexture"/>
+ <command name="glNamedFramebufferTextureLayer"/>
+ <command name="glNamedFramebufferDrawBuffer"/>
+ <command name="glNamedFramebufferDrawBuffers"/>
+ <command name="glNamedFramebufferReadBuffer"/>
+ <command name="glInvalidateNamedFramebufferData"/>
+ <command name="glInvalidateNamedFramebufferSubData"/>
+ <command name="glClearNamedFramebufferiv"/>
+ <command name="glClearNamedFramebufferuiv"/>
+ <command name="glClearNamedFramebufferfv"/>
+ <command name="glClearNamedFramebufferfi"/>
+ <command name="glBlitNamedFramebuffer"/>
+ <command name="glCheckNamedFramebufferStatus"/>
+ <command name="glGetNamedFramebufferParameteriv"/>
+ <command name="glGetNamedFramebufferAttachmentParameteriv"/>
+ </require>
+ <require comment="Renderbuffer object functions">
+ <command name="glCreateRenderbuffers"/>
+ <command name="glNamedRenderbufferStorage"/>
+ <command name="glNamedRenderbufferStorageMultisample"/>
+ <command name="glGetNamedRenderbufferParameteriv"/>
+ </require>
+ <require comment="Texture object functions">
+ <command name="glCreateTextures"/>
+ <command name="glTextureBuffer"/>
+ <command name="glTextureBufferRange"/>
+ <command name="glTextureStorage1D"/>
+ <command name="glTextureStorage2D"/>
+ <command name="glTextureStorage3D"/>
+ <command name="glTextureStorage2DMultisample"/>
+ <command name="glTextureStorage3DMultisample"/>
+ <command name="glTextureSubImage1D"/>
+ <command name="glTextureSubImage2D"/>
+ <command name="glTextureSubImage3D"/>
+ <command name="glCompressedTextureSubImage1D"/>
+ <command name="glCompressedTextureSubImage2D"/>
+ <command name="glCompressedTextureSubImage3D"/>
+ <command name="glCopyTextureSubImage1D"/>
+ <command name="glCopyTextureSubImage2D"/>
+ <command name="glCopyTextureSubImage3D"/>
+ <command name="glTextureParameterf"/>
+ <command name="glTextureParameterfv"/>
+ <command name="glTextureParameteri"/>
+ <command name="glTextureParameterIiv"/>
+ <command name="glTextureParameterIuiv"/>
+ <command name="glTextureParameteriv"/>
+ <command name="glGenerateTextureMipmap"/>
+ <command name="glBindTextureUnit"/>
+ <command name="glGetTextureImage"/>
+ <command name="glGetCompressedTextureImage"/>
+ <command name="glGetTextureLevelParameterfv"/>
+ <command name="glGetTextureLevelParameteriv"/>
+ <command name="glGetTextureParameterfv"/>
+ <command name="glGetTextureParameterIiv"/>
+ <command name="glGetTextureParameterIuiv"/>
+ <command name="glGetTextureParameteriv"/>
+ </require>
+ <require comment="Vertex Array object functions">
+ <command name="glCreateVertexArrays"/>
+ <command name="glDisableVertexArrayAttrib"/>
+ <command name="glEnableVertexArrayAttrib"/>
+ <command name="glVertexArrayElementBuffer"/>
+ <command name="glVertexArrayVertexBuffer"/>
+ <command name="glVertexArrayVertexBuffers"/>
+ <command name="glVertexArrayAttribBinding"/>
+ <command name="glVertexArrayAttribFormat"/>
+ <command name="glVertexArrayAttribIFormat"/>
+ <command name="glVertexArrayAttribLFormat"/>
+ <command name="glVertexArrayBindingDivisor"/>
+ <command name="glGetVertexArrayiv"/>
+ <command name="glGetVertexArrayIndexediv"/>
+ <command name="glGetVertexArrayIndexed64iv"/>
+ </require>
+ <require comment="Sampler object functions">
+ <command name="glCreateSamplers"/>
+ </require>
+ <require comment="Program Pipeline object functions">
+ <command name="glCreateProgramPipelines"/>
+ </require>
+ <require comment="Query object functions">
+ <command name="glCreateQueries"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_draw_buffers" supported="gl">
+ <require>
+ <enum name="GL_MAX_DRAW_BUFFERS_ARB"/>
+ <enum name="GL_DRAW_BUFFER0_ARB"/>
+ <enum name="GL_DRAW_BUFFER1_ARB"/>
+ <enum name="GL_DRAW_BUFFER2_ARB"/>
+ <enum name="GL_DRAW_BUFFER3_ARB"/>
+ <enum name="GL_DRAW_BUFFER4_ARB"/>
+ <enum name="GL_DRAW_BUFFER5_ARB"/>
+ <enum name="GL_DRAW_BUFFER6_ARB"/>
+ <enum name="GL_DRAW_BUFFER7_ARB"/>
+ <enum name="GL_DRAW_BUFFER8_ARB"/>
+ <enum name="GL_DRAW_BUFFER9_ARB"/>
+ <enum name="GL_DRAW_BUFFER10_ARB"/>
+ <enum name="GL_DRAW_BUFFER11_ARB"/>
+ <enum name="GL_DRAW_BUFFER12_ARB"/>
+ <enum name="GL_DRAW_BUFFER13_ARB"/>
+ <enum name="GL_DRAW_BUFFER14_ARB"/>
+ <enum name="GL_DRAW_BUFFER15_ARB"/>
+ <command name="glDrawBuffersARB"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_draw_buffers_blend" supported="gl|glcore">
+ <require>
+ <command name="glBlendEquationiARB"/>
+ <command name="glBlendEquationSeparateiARB"/>
+ <command name="glBlendFunciARB"/>
+ <command name="glBlendFuncSeparateiARB"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_draw_elements_base_vertex" supported="gl|glcore">
+ <require>
+ <command name="glDrawElementsBaseVertex"/>
+ <command name="glDrawRangeElementsBaseVertex"/>
+ <command name="glDrawElementsInstancedBaseVertex"/>
+ <command name="glMultiDrawElementsBaseVertex"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_draw_indirect" supported="gl|glcore">
+ <require>
+ <enum name="GL_DRAW_INDIRECT_BUFFER"/>
+ <enum name="GL_DRAW_INDIRECT_BUFFER_BINDING"/>
+ <command name="glDrawArraysIndirect"/>
+ <command name="glDrawElementsIndirect"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_draw_instanced" supported="gl">
+ <require>
+ <command name="glDrawArraysInstancedARB"/>
+ <command name="glDrawElementsInstancedARB"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_enhanced_layouts" supported="gl|glcore">
+ <require>
+ <enum name="GL_LOCATION_COMPONENT"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_BUFFER"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_BUFFER_INDEX"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_BUFFER_STRIDE"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_explicit_attrib_location" supported="gl|glcore"/>
+ <extension name="GL_ARB_explicit_uniform_location" supported="gl|glcore">
+ <require>
+ <enum name="GL_MAX_UNIFORM_LOCATIONS"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_fragment_coord_conventions" supported="gl|glcore"/>
+ <extension name="GL_ARB_fragment_layer_viewport" supported="gl|glcore"/>
+ <extension name="GL_ARB_fragment_program" supported="gl">
+ <require>
+ <enum name="GL_FRAGMENT_PROGRAM_ARB"/>
+ <enum name="GL_PROGRAM_FORMAT_ASCII_ARB"/>
+ <enum name="GL_PROGRAM_LENGTH_ARB"/>
+ <enum name="GL_PROGRAM_FORMAT_ARB"/>
+ <enum name="GL_PROGRAM_BINDING_ARB"/>
+ <enum name="GL_PROGRAM_INSTRUCTIONS_ARB"/>
+ <enum name="GL_MAX_PROGRAM_INSTRUCTIONS_ARB"/>
+ <enum name="GL_PROGRAM_NATIVE_INSTRUCTIONS_ARB"/>
+ <enum name="GL_MAX_PROGRAM_NATIVE_INSTRUCTIONS_ARB"/>
+ <enum name="GL_PROGRAM_TEMPORARIES_ARB"/>
+ <enum name="GL_MAX_PROGRAM_TEMPORARIES_ARB"/>
+ <enum name="GL_PROGRAM_NATIVE_TEMPORARIES_ARB"/>
+ <enum name="GL_MAX_PROGRAM_NATIVE_TEMPORARIES_ARB"/>
+ <enum name="GL_PROGRAM_PARAMETERS_ARB"/>
+ <enum name="GL_MAX_PROGRAM_PARAMETERS_ARB"/>
+ <enum name="GL_PROGRAM_NATIVE_PARAMETERS_ARB"/>
+ <enum name="GL_MAX_PROGRAM_NATIVE_PARAMETERS_ARB"/>
+ <enum name="GL_PROGRAM_ATTRIBS_ARB"/>
+ <enum name="GL_MAX_PROGRAM_ATTRIBS_ARB"/>
+ <enum name="GL_PROGRAM_NATIVE_ATTRIBS_ARB"/>
+ <enum name="GL_MAX_PROGRAM_NATIVE_ATTRIBS_ARB"/>
+ <enum name="GL_MAX_PROGRAM_LOCAL_PARAMETERS_ARB"/>
+ <enum name="GL_MAX_PROGRAM_ENV_PARAMETERS_ARB"/>
+ <enum name="GL_PROGRAM_UNDER_NATIVE_LIMITS_ARB"/>
+ <enum name="GL_PROGRAM_ALU_INSTRUCTIONS_ARB"/>
+ <enum name="GL_PROGRAM_TEX_INSTRUCTIONS_ARB"/>
+ <enum name="GL_PROGRAM_TEX_INDIRECTIONS_ARB"/>
+ <enum name="GL_PROGRAM_NATIVE_ALU_INSTRUCTIONS_ARB"/>
+ <enum name="GL_PROGRAM_NATIVE_TEX_INSTRUCTIONS_ARB"/>
+ <enum name="GL_PROGRAM_NATIVE_TEX_INDIRECTIONS_ARB"/>
+ <enum name="GL_MAX_PROGRAM_ALU_INSTRUCTIONS_ARB"/>
+ <enum name="GL_MAX_PROGRAM_TEX_INSTRUCTIONS_ARB"/>
+ <enum name="GL_MAX_PROGRAM_TEX_INDIRECTIONS_ARB"/>
+ <enum name="GL_MAX_PROGRAM_NATIVE_ALU_INSTRUCTIONS_ARB"/>
+ <enum name="GL_MAX_PROGRAM_NATIVE_TEX_INSTRUCTIONS_ARB"/>
+ <enum name="GL_MAX_PROGRAM_NATIVE_TEX_INDIRECTIONS_ARB"/>
+ <enum name="GL_PROGRAM_STRING_ARB"/>
+ <enum name="GL_PROGRAM_ERROR_POSITION_ARB"/>
+ <enum name="GL_CURRENT_MATRIX_ARB"/>
+ <enum name="GL_TRANSPOSE_CURRENT_MATRIX_ARB"/>
+ <enum name="GL_CURRENT_MATRIX_STACK_DEPTH_ARB"/>
+ <enum name="GL_MAX_PROGRAM_MATRICES_ARB"/>
+ <enum name="GL_MAX_PROGRAM_MATRIX_STACK_DEPTH_ARB"/>
+ <enum name="GL_MAX_TEXTURE_COORDS_ARB"/>
+ <enum name="GL_MAX_TEXTURE_IMAGE_UNITS_ARB"/>
+ <enum name="GL_PROGRAM_ERROR_STRING_ARB"/>
+ <enum name="GL_MATRIX0_ARB"/>
+ <enum name="GL_MATRIX1_ARB"/>
+ <enum name="GL_MATRIX2_ARB"/>
+ <enum name="GL_MATRIX3_ARB"/>
+ <enum name="GL_MATRIX4_ARB"/>
+ <enum name="GL_MATRIX5_ARB"/>
+ <enum name="GL_MATRIX6_ARB"/>
+ <enum name="GL_MATRIX7_ARB"/>
+ <enum name="GL_MATRIX8_ARB"/>
+ <enum name="GL_MATRIX9_ARB"/>
+ <enum name="GL_MATRIX10_ARB"/>
+ <enum name="GL_MATRIX11_ARB"/>
+ <enum name="GL_MATRIX12_ARB"/>
+ <enum name="GL_MATRIX13_ARB"/>
+ <enum name="GL_MATRIX14_ARB"/>
+ <enum name="GL_MATRIX15_ARB"/>
+ <enum name="GL_MATRIX16_ARB"/>
+ <enum name="GL_MATRIX17_ARB"/>
+ <enum name="GL_MATRIX18_ARB"/>
+ <enum name="GL_MATRIX19_ARB"/>
+ <enum name="GL_MATRIX20_ARB"/>
+ <enum name="GL_MATRIX21_ARB"/>
+ <enum name="GL_MATRIX22_ARB"/>
+ <enum name="GL_MATRIX23_ARB"/>
+ <enum name="GL_MATRIX24_ARB"/>
+ <enum name="GL_MATRIX25_ARB"/>
+ <enum name="GL_MATRIX26_ARB"/>
+ <enum name="GL_MATRIX27_ARB"/>
+ <enum name="GL_MATRIX28_ARB"/>
+ <enum name="GL_MATRIX29_ARB"/>
+ <enum name="GL_MATRIX30_ARB"/>
+ <enum name="GL_MATRIX31_ARB"/>
+ </require>
+ <require comment="Shared with ARB_vertex_program">
+ <command name="glProgramStringARB"/>
+ <command name="glBindProgramARB"/>
+ <command name="glDeleteProgramsARB"/>
+ <command name="glGenProgramsARB"/>
+ <command name="glProgramEnvParameter4dARB"/>
+ <command name="glProgramEnvParameter4dvARB"/>
+ <command name="glProgramEnvParameter4fARB"/>
+ <command name="glProgramEnvParameter4fvARB"/>
+ <command name="glProgramLocalParameter4dARB"/>
+ <command name="glProgramLocalParameter4dvARB"/>
+ <command name="glProgramLocalParameter4fARB"/>
+ <command name="glProgramLocalParameter4fvARB"/>
+ <command name="glGetProgramEnvParameterdvARB"/>
+ <command name="glGetProgramEnvParameterfvARB"/>
+ <command name="glGetProgramLocalParameterdvARB"/>
+ <command name="glGetProgramLocalParameterfvARB"/>
+ <command name="glGetProgramivARB"/>
+ <command name="glGetProgramStringARB"/>
+ <command name="glIsProgramARB"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_fragment_program_shadow" supported="gl"/>
+ <extension name="GL_ARB_fragment_shader" supported="gl">
+ <require>
+ <enum name="GL_FRAGMENT_SHADER_ARB"/>
+ <enum name="GL_MAX_FRAGMENT_UNIFORM_COMPONENTS_ARB"/>
+ <enum name="GL_FRAGMENT_SHADER_DERIVATIVE_HINT_ARB"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_framebuffer_no_attachments" supported="gl|glcore">
+ <require>
+ <enum name="GL_FRAMEBUFFER_DEFAULT_WIDTH"/>
+ <enum name="GL_FRAMEBUFFER_DEFAULT_HEIGHT"/>
+ <enum name="GL_FRAMEBUFFER_DEFAULT_LAYERS"/>
+ <enum name="GL_FRAMEBUFFER_DEFAULT_SAMPLES"/>
+ <enum name="GL_FRAMEBUFFER_DEFAULT_FIXED_SAMPLE_LOCATIONS"/>
+ <enum name="GL_MAX_FRAMEBUFFER_WIDTH"/>
+ <enum name="GL_MAX_FRAMEBUFFER_HEIGHT"/>
+ <enum name="GL_MAX_FRAMEBUFFER_LAYERS"/>
+ <enum name="GL_MAX_FRAMEBUFFER_SAMPLES"/>
+ <command name="glFramebufferParameteri"/>
+ <command name="glGetFramebufferParameteriv"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_framebuffer_object" supported="gl|glcore">
+ <require>
+ <enum name="GL_INVALID_FRAMEBUFFER_OPERATION"/>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING"/>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE"/>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_RED_SIZE"/>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_GREEN_SIZE"/>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_BLUE_SIZE"/>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_ALPHA_SIZE"/>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_DEPTH_SIZE"/>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_STENCIL_SIZE"/>
+ <enum name="GL_FRAMEBUFFER_DEFAULT"/>
+ <enum name="GL_FRAMEBUFFER_UNDEFINED"/>
+ <enum name="GL_DEPTH_STENCIL_ATTACHMENT"/>
+ <enum name="GL_MAX_RENDERBUFFER_SIZE"/>
+ <enum name="GL_DEPTH_STENCIL"/>
+ <enum name="GL_UNSIGNED_INT_24_8"/>
+ <enum name="GL_DEPTH24_STENCIL8"/>
+ <enum name="GL_TEXTURE_STENCIL_SIZE"/>
+ <enum name="GL_TEXTURE_RED_TYPE"/>
+ <enum name="GL_TEXTURE_GREEN_TYPE"/>
+ <enum name="GL_TEXTURE_BLUE_TYPE"/>
+ <enum name="GL_TEXTURE_ALPHA_TYPE"/>
+ <enum name="GL_TEXTURE_DEPTH_TYPE"/>
+ <enum name="GL_UNSIGNED_NORMALIZED"/>
+ <enum name="GL_FRAMEBUFFER_BINDING"/>
+ <enum name="GL_DRAW_FRAMEBUFFER_BINDING"/>
+ <enum name="GL_RENDERBUFFER_BINDING"/>
+ <enum name="GL_READ_FRAMEBUFFER"/>
+ <enum name="GL_DRAW_FRAMEBUFFER"/>
+ <enum name="GL_READ_FRAMEBUFFER_BINDING"/>
+ <enum name="GL_RENDERBUFFER_SAMPLES"/>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE"/>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_OBJECT_NAME"/>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL"/>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE"/>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER"/>
+ <enum name="GL_FRAMEBUFFER_COMPLETE"/>
+ <enum name="GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT"/>
+ <enum name="GL_FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT"/>
+ <enum name="GL_FRAMEBUFFER_INCOMPLETE_DRAW_BUFFER"/>
+ <enum name="GL_FRAMEBUFFER_INCOMPLETE_READ_BUFFER"/>
+ <enum name="GL_FRAMEBUFFER_UNSUPPORTED"/>
+ <enum name="GL_MAX_COLOR_ATTACHMENTS"/>
+ <enum name="GL_COLOR_ATTACHMENT0"/>
+ <enum name="GL_COLOR_ATTACHMENT1"/>
+ <enum name="GL_COLOR_ATTACHMENT2"/>
+ <enum name="GL_COLOR_ATTACHMENT3"/>
+ <enum name="GL_COLOR_ATTACHMENT4"/>
+ <enum name="GL_COLOR_ATTACHMENT5"/>
+ <enum name="GL_COLOR_ATTACHMENT6"/>
+ <enum name="GL_COLOR_ATTACHMENT7"/>
+ <enum name="GL_COLOR_ATTACHMENT8"/>
+ <enum name="GL_COLOR_ATTACHMENT9"/>
+ <enum name="GL_COLOR_ATTACHMENT10"/>
+ <enum name="GL_COLOR_ATTACHMENT11"/>
+ <enum name="GL_COLOR_ATTACHMENT12"/>
+ <enum name="GL_COLOR_ATTACHMENT13"/>
+ <enum name="GL_COLOR_ATTACHMENT14"/>
+ <enum name="GL_COLOR_ATTACHMENT15"/>
+ <enum name="GL_DEPTH_ATTACHMENT"/>
+ <enum name="GL_STENCIL_ATTACHMENT"/>
+ <enum name="GL_FRAMEBUFFER"/>
+ <enum name="GL_RENDERBUFFER"/>
+ <enum name="GL_RENDERBUFFER_WIDTH"/>
+ <enum name="GL_RENDERBUFFER_HEIGHT"/>
+ <enum name="GL_RENDERBUFFER_INTERNAL_FORMAT"/>
+ <enum name="GL_STENCIL_INDEX1"/>
+ <enum name="GL_STENCIL_INDEX4"/>
+ <enum name="GL_STENCIL_INDEX8"/>
+ <enum name="GL_STENCIL_INDEX16"/>
+ <enum name="GL_RENDERBUFFER_RED_SIZE"/>
+ <enum name="GL_RENDERBUFFER_GREEN_SIZE"/>
+ <enum name="GL_RENDERBUFFER_BLUE_SIZE"/>
+ <enum name="GL_RENDERBUFFER_ALPHA_SIZE"/>
+ <enum name="GL_RENDERBUFFER_DEPTH_SIZE"/>
+ <enum name="GL_RENDERBUFFER_STENCIL_SIZE"/>
+ <enum name="GL_FRAMEBUFFER_INCOMPLETE_MULTISAMPLE"/>
+ <enum name="GL_MAX_SAMPLES"/>
+ <command name="glIsRenderbuffer"/>
+ <command name="glBindRenderbuffer"/>
+ <command name="glDeleteRenderbuffers"/>
+ <command name="glGenRenderbuffers"/>
+ <command name="glRenderbufferStorage"/>
+ <command name="glGetRenderbufferParameteriv"/>
+ <command name="glIsFramebuffer"/>
+ <command name="glBindFramebuffer"/>
+ <command name="glDeleteFramebuffers"/>
+ <command name="glGenFramebuffers"/>
+ <command name="glCheckFramebufferStatus"/>
+ <command name="glFramebufferTexture1D"/>
+ <command name="glFramebufferTexture2D"/>
+ <command name="glFramebufferTexture3D"/>
+ <command name="glFramebufferRenderbuffer"/>
+ <command name="glGetFramebufferAttachmentParameteriv"/>
+ <command name="glGenerateMipmap"/>
+ <command name="glBlitFramebuffer"/>
+ <command name="glRenderbufferStorageMultisample"/>
+ <command name="glFramebufferTextureLayer"/>
+ </require>
+ <require api="gl" profile="compatibility">
+ <enum name="GL_INDEX"/>
+ <enum name="GL_TEXTURE_LUMINANCE_TYPE"/>
+ <enum name="GL_TEXTURE_INTENSITY_TYPE"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_framebuffer_sRGB" supported="gl|glcore">
+ <require>
+ <enum name="GL_FRAMEBUFFER_SRGB"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_geometry_shader4" supported="gl">
+ <require>
+ <enum name="GL_LINES_ADJACENCY_ARB"/>
+ <enum name="GL_LINE_STRIP_ADJACENCY_ARB"/>
+ <enum name="GL_TRIANGLES_ADJACENCY_ARB"/>
+ <enum name="GL_TRIANGLE_STRIP_ADJACENCY_ARB"/>
+ <enum name="GL_PROGRAM_POINT_SIZE_ARB"/>
+ <enum name="GL_MAX_GEOMETRY_TEXTURE_IMAGE_UNITS_ARB"/>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_LAYERED_ARB"/>
+ <enum name="GL_FRAMEBUFFER_INCOMPLETE_LAYER_TARGETS_ARB"/>
+ <enum name="GL_FRAMEBUFFER_INCOMPLETE_LAYER_COUNT_ARB"/>
+ <enum name="GL_GEOMETRY_SHADER_ARB"/>
+ <enum name="GL_GEOMETRY_VERTICES_OUT_ARB"/>
+ <enum name="GL_GEOMETRY_INPUT_TYPE_ARB"/>
+ <enum name="GL_GEOMETRY_OUTPUT_TYPE_ARB"/>
+ <enum name="GL_MAX_GEOMETRY_VARYING_COMPONENTS_ARB"/>
+ <enum name="GL_MAX_VERTEX_VARYING_COMPONENTS_ARB"/>
+ <enum name="GL_MAX_GEOMETRY_UNIFORM_COMPONENTS_ARB"/>
+ <enum name="GL_MAX_GEOMETRY_OUTPUT_VERTICES_ARB"/>
+ <enum name="GL_MAX_GEOMETRY_TOTAL_OUTPUT_COMPONENTS_ARB"/>
+ <enum name="GL_MAX_VARYING_COMPONENTS"/>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER"/>
+ <command name="glProgramParameteriARB"/>
+ <command name="glFramebufferTextureARB"/>
+ <command name="glFramebufferTextureLayerARB"/>
+ <command name="glFramebufferTextureFaceARB"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_get_program_binary" supported="gl|glcore">
+ <require>
+ <enum name="GL_PROGRAM_BINARY_RETRIEVABLE_HINT"/>
+ <enum name="GL_PROGRAM_BINARY_LENGTH"/>
+ <enum name="GL_NUM_PROGRAM_BINARY_FORMATS"/>
+ <enum name="GL_PROGRAM_BINARY_FORMATS"/>
+ <command name="glGetProgramBinary"/>
+ <command name="glProgramBinary"/>
+ <command name="glProgramParameteri"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_get_texture_sub_image" supported="gl|glcore">
+ <require>
+ <command name="glGetTextureSubImage"/>
+ <command name="glGetCompressedTextureSubImage"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_gpu_shader5" supported="gl|glcore">
+ <require>
+ <enum name="GL_GEOMETRY_SHADER_INVOCATIONS"/>
+ <enum name="GL_MAX_GEOMETRY_SHADER_INVOCATIONS"/>
+ <enum name="GL_MIN_FRAGMENT_INTERPOLATION_OFFSET"/>
+ <enum name="GL_MAX_FRAGMENT_INTERPOLATION_OFFSET"/>
+ <enum name="GL_FRAGMENT_INTERPOLATION_OFFSET_BITS"/>
+ <enum name="GL_MAX_VERTEX_STREAMS"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_gpu_shader_fp64" supported="gl|glcore">
+ <require>
+ <enum name="GL_DOUBLE"/>
+ <enum name="GL_DOUBLE_VEC2"/>
+ <enum name="GL_DOUBLE_VEC3"/>
+ <enum name="GL_DOUBLE_VEC4"/>
+ <enum name="GL_DOUBLE_MAT2"/>
+ <enum name="GL_DOUBLE_MAT3"/>
+ <enum name="GL_DOUBLE_MAT4"/>
+ <enum name="GL_DOUBLE_MAT2x3"/>
+ <enum name="GL_DOUBLE_MAT2x4"/>
+ <enum name="GL_DOUBLE_MAT3x2"/>
+ <enum name="GL_DOUBLE_MAT3x4"/>
+ <enum name="GL_DOUBLE_MAT4x2"/>
+ <enum name="GL_DOUBLE_MAT4x3"/>
+ <command name="glUniform1d"/>
+ <command name="glUniform2d"/>
+ <command name="glUniform3d"/>
+ <command name="glUniform4d"/>
+ <command name="glUniform1dv"/>
+ <command name="glUniform2dv"/>
+ <command name="glUniform3dv"/>
+ <command name="glUniform4dv"/>
+ <command name="glUniformMatrix2dv"/>
+ <command name="glUniformMatrix3dv"/>
+ <command name="glUniformMatrix4dv"/>
+ <command name="glUniformMatrix2x3dv"/>
+ <command name="glUniformMatrix2x4dv"/>
+ <command name="glUniformMatrix3x2dv"/>
+ <command name="glUniformMatrix3x4dv"/>
+ <command name="glUniformMatrix4x2dv"/>
+ <command name="glUniformMatrix4x3dv"/>
+ <command name="glGetUniformdv"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_half_float_pixel" supported="gl">
+ <require>
+ <type name="GLhalfARB"/>
+ <enum name="GL_HALF_FLOAT_ARB"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_half_float_vertex" supported="gl|glcore">
+ <require>
+ <type name="GLhalf"/>
+ <enum name="GL_HALF_FLOAT"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_imaging" supported="gl|glcore" comment="Now treating ARB_imaging as an extension, not a GL API version">
+ <require>
+ <enum name="GL_CONSTANT_COLOR"/>
+ <enum name="GL_ONE_MINUS_CONSTANT_COLOR"/>
+ <enum name="GL_CONSTANT_ALPHA"/>
+ <enum name="GL_ONE_MINUS_CONSTANT_ALPHA"/>
+ <enum name="GL_BLEND_COLOR"/>
+ <enum name="GL_FUNC_ADD"/>
+ <enum name="GL_MIN"/>
+ <enum name="GL_MAX"/>
+ <enum name="GL_BLEND_EQUATION"/>
+ <enum name="GL_FUNC_SUBTRACT"/>
+ <enum name="GL_FUNC_REVERSE_SUBTRACT"/>
+ <command name="glBlendColor"/>
+ <command name="glBlendEquation"/>
+ </require>
+ <require api="gl" profile="compatibility">
+ <enum name="GL_CONVOLUTION_1D"/>
+ <enum name="GL_CONVOLUTION_2D"/>
+ <enum name="GL_SEPARABLE_2D"/>
+ <enum name="GL_CONVOLUTION_BORDER_MODE"/>
+ <enum name="GL_CONVOLUTION_FILTER_SCALE"/>
+ <enum name="GL_CONVOLUTION_FILTER_BIAS"/>
+ <enum name="GL_REDUCE"/>
+ <enum name="GL_CONVOLUTION_FORMAT"/>
+ <enum name="GL_CONVOLUTION_WIDTH"/>
+ <enum name="GL_CONVOLUTION_HEIGHT"/>
+ <enum name="GL_MAX_CONVOLUTION_WIDTH"/>
+ <enum name="GL_MAX_CONVOLUTION_HEIGHT"/>
+ <enum name="GL_POST_CONVOLUTION_RED_SCALE"/>
+ <enum name="GL_POST_CONVOLUTION_GREEN_SCALE"/>
+ <enum name="GL_POST_CONVOLUTION_BLUE_SCALE"/>
+ <enum name="GL_POST_CONVOLUTION_ALPHA_SCALE"/>
+ <enum name="GL_POST_CONVOLUTION_RED_BIAS"/>
+ <enum name="GL_POST_CONVOLUTION_GREEN_BIAS"/>
+ <enum name="GL_POST_CONVOLUTION_BLUE_BIAS"/>
+ <enum name="GL_POST_CONVOLUTION_ALPHA_BIAS"/>
+ <enum name="GL_HISTOGRAM"/>
+ <enum name="GL_PROXY_HISTOGRAM"/>
+ <enum name="GL_HISTOGRAM_WIDTH"/>
+ <enum name="GL_HISTOGRAM_FORMAT"/>
+ <enum name="GL_HISTOGRAM_RED_SIZE"/>
+ <enum name="GL_HISTOGRAM_GREEN_SIZE"/>
+ <enum name="GL_HISTOGRAM_BLUE_SIZE"/>
+ <enum name="GL_HISTOGRAM_ALPHA_SIZE"/>
+ <enum name="GL_HISTOGRAM_LUMINANCE_SIZE"/>
+ <enum name="GL_HISTOGRAM_SINK"/>
+ <enum name="GL_MINMAX"/>
+ <enum name="GL_MINMAX_FORMAT"/>
+ <enum name="GL_MINMAX_SINK"/>
+ <enum name="GL_TABLE_TOO_LARGE"/>
+ <enum name="GL_COLOR_MATRIX"/>
+ <enum name="GL_COLOR_MATRIX_STACK_DEPTH"/>
+ <enum name="GL_MAX_COLOR_MATRIX_STACK_DEPTH"/>
+ <enum name="GL_POST_COLOR_MATRIX_RED_SCALE"/>
+ <enum name="GL_POST_COLOR_MATRIX_GREEN_SCALE"/>
+ <enum name="GL_POST_COLOR_MATRIX_BLUE_SCALE"/>
+ <enum name="GL_POST_COLOR_MATRIX_ALPHA_SCALE"/>
+ <enum name="GL_POST_COLOR_MATRIX_RED_BIAS"/>
+ <enum name="GL_POST_COLOR_MATRIX_GREEN_BIAS"/>
+ <enum name="GL_POST_COLOR_MATRIX_BLUE_BIAS"/>
+ <enum name="GL_POST_COLOR_MATRIX_ALPHA_BIAS"/>
+ <enum name="GL_COLOR_TABLE"/>
+ <enum name="GL_POST_CONVOLUTION_COLOR_TABLE"/>
+ <enum name="GL_POST_COLOR_MATRIX_COLOR_TABLE"/>
+ <enum name="GL_PROXY_COLOR_TABLE"/>
+ <enum name="GL_PROXY_POST_CONVOLUTION_COLOR_TABLE"/>
+ <enum name="GL_PROXY_POST_COLOR_MATRIX_COLOR_TABLE"/>
+ <enum name="GL_COLOR_TABLE_SCALE"/>
+ <enum name="GL_COLOR_TABLE_BIAS"/>
+ <enum name="GL_COLOR_TABLE_FORMAT"/>
+ <enum name="GL_COLOR_TABLE_WIDTH"/>
+ <enum name="GL_COLOR_TABLE_RED_SIZE"/>
+ <enum name="GL_COLOR_TABLE_GREEN_SIZE"/>
+ <enum name="GL_COLOR_TABLE_BLUE_SIZE"/>
+ <enum name="GL_COLOR_TABLE_ALPHA_SIZE"/>
+ <enum name="GL_COLOR_TABLE_LUMINANCE_SIZE"/>
+ <enum name="GL_COLOR_TABLE_INTENSITY_SIZE"/>
+ <enum name="GL_CONSTANT_BORDER"/>
+ <enum name="GL_REPLICATE_BORDER"/>
+ <enum name="GL_CONVOLUTION_BORDER_COLOR"/>
+ <command name="glColorTable"/>
+ <command name="glColorTableParameterfv"/>
+ <command name="glColorTableParameteriv"/>
+ <command name="glCopyColorTable"/>
+ <command name="glGetColorTable"/>
+ <command name="glGetColorTableParameterfv"/>
+ <command name="glGetColorTableParameteriv"/>
+ <command name="glColorSubTable"/>
+ <command name="glCopyColorSubTable"/>
+ <command name="glConvolutionFilter1D"/>
+ <command name="glConvolutionFilter2D"/>
+ <command name="glConvolutionParameterf"/>
+ <command name="glConvolutionParameterfv"/>
+ <command name="glConvolutionParameteri"/>
+ <command name="glConvolutionParameteriv"/>
+ <command name="glCopyConvolutionFilter1D"/>
+ <command name="glCopyConvolutionFilter2D"/>
+ <command name="glGetConvolutionFilter"/>
+ <command name="glGetConvolutionParameterfv"/>
+ <command name="glGetConvolutionParameteriv"/>
+ <command name="glGetSeparableFilter"/>
+ <command name="glSeparableFilter2D"/>
+ <command name="glGetHistogram"/>
+ <command name="glGetHistogramParameterfv"/>
+ <command name="glGetHistogramParameteriv"/>
+ <command name="glGetMinmax"/>
+ <command name="glGetMinmaxParameterfv"/>
+ <command name="glGetMinmaxParameteriv"/>
+ <command name="glHistogram"/>
+ <command name="glMinmax"/>
+ <command name="glResetHistogram"/>
+ <command name="glResetMinmax"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_indirect_parameters" supported="gl|glcore">
+ <require>
+ <enum name="GL_PARAMETER_BUFFER_ARB"/>
+ <enum name="GL_PARAMETER_BUFFER_BINDING_ARB"/>
+ <command name="glMultiDrawArraysIndirectCountARB"/>
+ <command name="glMultiDrawElementsIndirectCountARB"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_instanced_arrays" supported="gl">
+ <require>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY_DIVISOR_ARB"/>
+ <command name="glVertexAttribDivisorARB"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_internalformat_query" supported="gl|glcore">
+ <require>
+ <enum name="GL_NUM_SAMPLE_COUNTS"/>
+ <command name="glGetInternalformativ"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_internalformat_query2" supported="gl|glcore">
+ <require>
+ <enum name="GL_IMAGE_FORMAT_COMPATIBILITY_TYPE"/>
+ <enum name="GL_NUM_SAMPLE_COUNTS"/>
+ <enum name="GL_RENDERBUFFER"/>
+ <enum name="GL_SAMPLES"/>
+ <enum name="GL_TEXTURE_1D"/>
+ <enum name="GL_TEXTURE_1D_ARRAY"/>
+ <enum name="GL_TEXTURE_2D"/>
+ <enum name="GL_TEXTURE_2D_ARRAY"/>
+ <enum name="GL_TEXTURE_3D"/>
+ <enum name="GL_TEXTURE_CUBE_MAP"/>
+ <enum name="GL_TEXTURE_CUBE_MAP_ARRAY"/>
+ <enum name="GL_TEXTURE_RECTANGLE"/>
+ <enum name="GL_TEXTURE_BUFFER"/>
+ <enum name="GL_TEXTURE_2D_MULTISAMPLE"/>
+ <enum name="GL_TEXTURE_2D_MULTISAMPLE_ARRAY"/>
+ <enum name="GL_TEXTURE_COMPRESSED"/>
+ <enum name="GL_INTERNALFORMAT_SUPPORTED"/>
+ <enum name="GL_INTERNALFORMAT_PREFERRED"/>
+ <enum name="GL_INTERNALFORMAT_RED_SIZE"/>
+ <enum name="GL_INTERNALFORMAT_GREEN_SIZE"/>
+ <enum name="GL_INTERNALFORMAT_BLUE_SIZE"/>
+ <enum name="GL_INTERNALFORMAT_ALPHA_SIZE"/>
+ <enum name="GL_INTERNALFORMAT_DEPTH_SIZE"/>
+ <enum name="GL_INTERNALFORMAT_STENCIL_SIZE"/>
+ <enum name="GL_INTERNALFORMAT_SHARED_SIZE"/>
+ <enum name="GL_INTERNALFORMAT_RED_TYPE"/>
+ <enum name="GL_INTERNALFORMAT_GREEN_TYPE"/>
+ <enum name="GL_INTERNALFORMAT_BLUE_TYPE"/>
+ <enum name="GL_INTERNALFORMAT_ALPHA_TYPE"/>
+ <enum name="GL_INTERNALFORMAT_DEPTH_TYPE"/>
+ <enum name="GL_INTERNALFORMAT_STENCIL_TYPE"/>
+ <enum name="GL_MAX_WIDTH"/>
+ <enum name="GL_MAX_HEIGHT"/>
+ <enum name="GL_MAX_DEPTH"/>
+ <enum name="GL_MAX_LAYERS"/>
+ <enum name="GL_MAX_COMBINED_DIMENSIONS"/>
+ <enum name="GL_COLOR_COMPONENTS"/>
+ <enum name="GL_DEPTH_COMPONENTS"/>
+ <enum name="GL_STENCIL_COMPONENTS"/>
+ <enum name="GL_COLOR_RENDERABLE"/>
+ <enum name="GL_DEPTH_RENDERABLE"/>
+ <enum name="GL_STENCIL_RENDERABLE"/>
+ <enum name="GL_FRAMEBUFFER_RENDERABLE"/>
+ <enum name="GL_FRAMEBUFFER_RENDERABLE_LAYERED"/>
+ <enum name="GL_FRAMEBUFFER_BLEND"/>
+ <enum name="GL_READ_PIXELS"/>
+ <enum name="GL_READ_PIXELS_FORMAT"/>
+ <enum name="GL_READ_PIXELS_TYPE"/>
+ <enum name="GL_TEXTURE_IMAGE_FORMAT"/>
+ <enum name="GL_TEXTURE_IMAGE_TYPE"/>
+ <enum name="GL_GET_TEXTURE_IMAGE_FORMAT"/>
+ <enum name="GL_GET_TEXTURE_IMAGE_TYPE"/>
+ <enum name="GL_MIPMAP"/>
+ <enum name="GL_MANUAL_GENERATE_MIPMAP"/>
+ <enum name="GL_AUTO_GENERATE_MIPMAP"/>
+ <enum name="GL_COLOR_ENCODING"/>
+ <enum name="GL_SRGB_READ"/>
+ <enum name="GL_SRGB_WRITE"/>
+ <enum name="GL_SRGB_DECODE_ARB"/>
+ <enum name="GL_FILTER"/>
+ <enum name="GL_VERTEX_TEXTURE"/>
+ <enum name="GL_TESS_CONTROL_TEXTURE"/>
+ <enum name="GL_TESS_EVALUATION_TEXTURE"/>
+ <enum name="GL_GEOMETRY_TEXTURE"/>
+ <enum name="GL_FRAGMENT_TEXTURE"/>
+ <enum name="GL_COMPUTE_TEXTURE"/>
+ <enum name="GL_TEXTURE_SHADOW"/>
+ <enum name="GL_TEXTURE_GATHER"/>
+ <enum name="GL_TEXTURE_GATHER_SHADOW"/>
+ <enum name="GL_SHADER_IMAGE_LOAD"/>
+ <enum name="GL_SHADER_IMAGE_STORE"/>
+ <enum name="GL_SHADER_IMAGE_ATOMIC"/>
+ <enum name="GL_IMAGE_TEXEL_SIZE"/>
+ <enum name="GL_IMAGE_COMPATIBILITY_CLASS"/>
+ <enum name="GL_IMAGE_PIXEL_FORMAT"/>
+ <enum name="GL_IMAGE_PIXEL_TYPE"/>
+ <enum name="GL_SIMULTANEOUS_TEXTURE_AND_DEPTH_TEST"/>
+ <enum name="GL_SIMULTANEOUS_TEXTURE_AND_STENCIL_TEST"/>
+ <enum name="GL_SIMULTANEOUS_TEXTURE_AND_DEPTH_WRITE"/>
+ <enum name="GL_SIMULTANEOUS_TEXTURE_AND_STENCIL_WRITE"/>
+ <enum name="GL_TEXTURE_COMPRESSED_BLOCK_WIDTH"/>
+ <enum name="GL_TEXTURE_COMPRESSED_BLOCK_HEIGHT"/>
+ <enum name="GL_TEXTURE_COMPRESSED_BLOCK_SIZE"/>
+ <enum name="GL_CLEAR_BUFFER"/>
+ <enum name="GL_TEXTURE_VIEW"/>
+ <enum name="GL_VIEW_COMPATIBILITY_CLASS"/>
+ <enum name="GL_FULL_SUPPORT"/>
+ <enum name="GL_CAVEAT_SUPPORT"/>
+ <enum name="GL_IMAGE_CLASS_4_X_32"/>
+ <enum name="GL_IMAGE_CLASS_2_X_32"/>
+ <enum name="GL_IMAGE_CLASS_1_X_32"/>
+ <enum name="GL_IMAGE_CLASS_4_X_16"/>
+ <enum name="GL_IMAGE_CLASS_2_X_16"/>
+ <enum name="GL_IMAGE_CLASS_1_X_16"/>
+ <enum name="GL_IMAGE_CLASS_4_X_8"/>
+ <enum name="GL_IMAGE_CLASS_2_X_8"/>
+ <enum name="GL_IMAGE_CLASS_1_X_8"/>
+ <enum name="GL_IMAGE_CLASS_11_11_10"/>
+ <enum name="GL_IMAGE_CLASS_10_10_10_2"/>
+ <enum name="GL_VIEW_CLASS_128_BITS"/>
+ <enum name="GL_VIEW_CLASS_96_BITS"/>
+ <enum name="GL_VIEW_CLASS_64_BITS"/>
+ <enum name="GL_VIEW_CLASS_48_BITS"/>
+ <enum name="GL_VIEW_CLASS_32_BITS"/>
+ <enum name="GL_VIEW_CLASS_24_BITS"/>
+ <enum name="GL_VIEW_CLASS_16_BITS"/>
+ <enum name="GL_VIEW_CLASS_8_BITS"/>
+ <enum name="GL_VIEW_CLASS_S3TC_DXT1_RGB"/>
+ <enum name="GL_VIEW_CLASS_S3TC_DXT1_RGBA"/>
+ <enum name="GL_VIEW_CLASS_S3TC_DXT3_RGBA"/>
+ <enum name="GL_VIEW_CLASS_S3TC_DXT5_RGBA"/>
+ <enum name="GL_VIEW_CLASS_RGTC1_RED"/>
+ <enum name="GL_VIEW_CLASS_RGTC2_RG"/>
+ <enum name="GL_VIEW_CLASS_BPTC_UNORM"/>
+ <enum name="GL_VIEW_CLASS_BPTC_FLOAT"/>
+ <command name="glGetInternalformati64v"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_invalidate_subdata" supported="gl|glcore">
+ <require>
+ <command name="glInvalidateTexSubImage"/>
+ <command name="glInvalidateTexImage"/>
+ <command name="glInvalidateBufferSubData"/>
+ <command name="glInvalidateBufferData"/>
+ <command name="glInvalidateFramebuffer"/>
+ <command name="glInvalidateSubFramebuffer"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_map_buffer_alignment" supported="gl|glcore">
+ <require>
+ <enum name="GL_MIN_MAP_BUFFER_ALIGNMENT"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_map_buffer_range" supported="gl|glcore">
+ <require>
+ <enum name="GL_MAP_READ_BIT"/>
+ <enum name="GL_MAP_WRITE_BIT"/>
+ <enum name="GL_MAP_INVALIDATE_RANGE_BIT"/>
+ <enum name="GL_MAP_INVALIDATE_BUFFER_BIT"/>
+ <enum name="GL_MAP_FLUSH_EXPLICIT_BIT"/>
+ <enum name="GL_MAP_UNSYNCHRONIZED_BIT"/>
+ <command name="glMapBufferRange"/>
+ <command name="glFlushMappedBufferRange"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_matrix_palette" supported="gl">
+ <require>
+ <enum name="GL_MATRIX_PALETTE_ARB"/>
+ <enum name="GL_MAX_MATRIX_PALETTE_STACK_DEPTH_ARB"/>
+ <enum name="GL_MAX_PALETTE_MATRICES_ARB"/>
+ <enum name="GL_CURRENT_PALETTE_MATRIX_ARB"/>
+ <enum name="GL_MATRIX_INDEX_ARRAY_ARB"/>
+ <enum name="GL_CURRENT_MATRIX_INDEX_ARB"/>
+ <enum name="GL_MATRIX_INDEX_ARRAY_SIZE_ARB"/>
+ <enum name="GL_MATRIX_INDEX_ARRAY_TYPE_ARB"/>
+ <enum name="GL_MATRIX_INDEX_ARRAY_STRIDE_ARB"/>
+ <enum name="GL_MATRIX_INDEX_ARRAY_POINTER_ARB"/>
+ <command name="glCurrentPaletteMatrixARB"/>
+ <command name="glMatrixIndexubvARB"/>
+ <command name="glMatrixIndexusvARB"/>
+ <command name="glMatrixIndexuivARB"/>
+ <command name="glMatrixIndexPointerARB"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_multi_bind" supported="gl|glcore">
+ <require>
+ <command name="glBindBuffersBase"/>
+ <command name="glBindBuffersRange"/>
+ <command name="glBindTextures"/>
+ <command name="glBindSamplers"/>
+ <command name="glBindImageTextures"/>
+ <command name="glBindVertexBuffers"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_multi_draw_indirect" supported="gl|glcore">
+ <require>
+ <command name="glMultiDrawArraysIndirect"/>
+ <command name="glMultiDrawElementsIndirect"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_multisample" supported="gl">
+ <require>
+ <enum name="GL_MULTISAMPLE_ARB"/>
+ <enum name="GL_SAMPLE_ALPHA_TO_COVERAGE_ARB"/>
+ <enum name="GL_SAMPLE_ALPHA_TO_ONE_ARB"/>
+ <enum name="GL_SAMPLE_COVERAGE_ARB"/>
+ <enum name="GL_SAMPLE_BUFFERS_ARB"/>
+ <enum name="GL_SAMPLES_ARB"/>
+ <enum name="GL_SAMPLE_COVERAGE_VALUE_ARB"/>
+ <enum name="GL_SAMPLE_COVERAGE_INVERT_ARB"/>
+ <enum name="GL_MULTISAMPLE_BIT_ARB"/>
+ <command name="glSampleCoverageARB"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_multitexture" supported="gl">
+ <require>
+ <enum name="GL_TEXTURE0_ARB"/>
+ <enum name="GL_TEXTURE1_ARB"/>
+ <enum name="GL_TEXTURE2_ARB"/>
+ <enum name="GL_TEXTURE3_ARB"/>
+ <enum name="GL_TEXTURE4_ARB"/>
+ <enum name="GL_TEXTURE5_ARB"/>
+ <enum name="GL_TEXTURE6_ARB"/>
+ <enum name="GL_TEXTURE7_ARB"/>
+ <enum name="GL_TEXTURE8_ARB"/>
+ <enum name="GL_TEXTURE9_ARB"/>
+ <enum name="GL_TEXTURE10_ARB"/>
+ <enum name="GL_TEXTURE11_ARB"/>
+ <enum name="GL_TEXTURE12_ARB"/>
+ <enum name="GL_TEXTURE13_ARB"/>
+ <enum name="GL_TEXTURE14_ARB"/>
+ <enum name="GL_TEXTURE15_ARB"/>
+ <enum name="GL_TEXTURE16_ARB"/>
+ <enum name="GL_TEXTURE17_ARB"/>
+ <enum name="GL_TEXTURE18_ARB"/>
+ <enum name="GL_TEXTURE19_ARB"/>
+ <enum name="GL_TEXTURE20_ARB"/>
+ <enum name="GL_TEXTURE21_ARB"/>
+ <enum name="GL_TEXTURE22_ARB"/>
+ <enum name="GL_TEXTURE23_ARB"/>
+ <enum name="GL_TEXTURE24_ARB"/>
+ <enum name="GL_TEXTURE25_ARB"/>
+ <enum name="GL_TEXTURE26_ARB"/>
+ <enum name="GL_TEXTURE27_ARB"/>
+ <enum name="GL_TEXTURE28_ARB"/>
+ <enum name="GL_TEXTURE29_ARB"/>
+ <enum name="GL_TEXTURE30_ARB"/>
+ <enum name="GL_TEXTURE31_ARB"/>
+ <enum name="GL_ACTIVE_TEXTURE_ARB"/>
+ <enum name="GL_CLIENT_ACTIVE_TEXTURE_ARB"/>
+ <enum name="GL_MAX_TEXTURE_UNITS_ARB"/>
+ <command name="glActiveTextureARB"/>
+ <command name="glClientActiveTextureARB"/>
+ <command name="glMultiTexCoord1dARB"/>
+ <command name="glMultiTexCoord1dvARB"/>
+ <command name="glMultiTexCoord1fARB"/>
+ <command name="glMultiTexCoord1fvARB"/>
+ <command name="glMultiTexCoord1iARB"/>
+ <command name="glMultiTexCoord1ivARB"/>
+ <command name="glMultiTexCoord1sARB"/>
+ <command name="glMultiTexCoord1svARB"/>
+ <command name="glMultiTexCoord2dARB"/>
+ <command name="glMultiTexCoord2dvARB"/>
+ <command name="glMultiTexCoord2fARB"/>
+ <command name="glMultiTexCoord2fvARB"/>
+ <command name="glMultiTexCoord2iARB"/>
+ <command name="glMultiTexCoord2ivARB"/>
+ <command name="glMultiTexCoord2sARB"/>
+ <command name="glMultiTexCoord2svARB"/>
+ <command name="glMultiTexCoord3dARB"/>
+ <command name="glMultiTexCoord3dvARB"/>
+ <command name="glMultiTexCoord3fARB"/>
+ <command name="glMultiTexCoord3fvARB"/>
+ <command name="glMultiTexCoord3iARB"/>
+ <command name="glMultiTexCoord3ivARB"/>
+ <command name="glMultiTexCoord3sARB"/>
+ <command name="glMultiTexCoord3svARB"/>
+ <command name="glMultiTexCoord4dARB"/>
+ <command name="glMultiTexCoord4dvARB"/>
+ <command name="glMultiTexCoord4fARB"/>
+ <command name="glMultiTexCoord4fvARB"/>
+ <command name="glMultiTexCoord4iARB"/>
+ <command name="glMultiTexCoord4ivARB"/>
+ <command name="glMultiTexCoord4sARB"/>
+ <command name="glMultiTexCoord4svARB"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_occlusion_query" supported="gl">
+ <require>
+ <enum name="GL_QUERY_COUNTER_BITS_ARB"/>
+ <enum name="GL_CURRENT_QUERY_ARB"/>
+ <enum name="GL_QUERY_RESULT_ARB"/>
+ <enum name="GL_QUERY_RESULT_AVAILABLE_ARB"/>
+ <enum name="GL_SAMPLES_PASSED_ARB"/>
+ <command name="glGenQueriesARB"/>
+ <command name="glDeleteQueriesARB"/>
+ <command name="glIsQueryARB"/>
+ <command name="glBeginQueryARB"/>
+ <command name="glEndQueryARB"/>
+ <command name="glGetQueryivARB"/>
+ <command name="glGetQueryObjectivARB"/>
+ <command name="glGetQueryObjectuivARB"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_occlusion_query2" supported="gl|glcore">
+ <require>
+ <enum name="GL_ANY_SAMPLES_PASSED"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_pipeline_statistics_query" supported="gl|glcore">
+ <require>
+ <enum name="GL_VERTICES_SUBMITTED_ARB"/>
+ <enum name="GL_PRIMITIVES_SUBMITTED_ARB"/>
+ <enum name="GL_VERTEX_SHADER_INVOCATIONS_ARB"/>
+ <enum name="GL_TESS_CONTROL_SHADER_PATCHES_ARB"/>
+ <enum name="GL_TESS_EVALUATION_SHADER_INVOCATIONS_ARB"/>
+ <enum name="GL_GEOMETRY_SHADER_INVOCATIONS"/>
+ <enum name="GL_GEOMETRY_SHADER_PRIMITIVES_EMITTED_ARB"/>
+ <enum name="GL_FRAGMENT_SHADER_INVOCATIONS_ARB"/>
+ <enum name="GL_COMPUTE_SHADER_INVOCATIONS_ARB"/>
+ <enum name="GL_CLIPPING_INPUT_PRIMITIVES_ARB"/>
+ <enum name="GL_CLIPPING_OUTPUT_PRIMITIVES_ARB"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_pixel_buffer_object" supported="gl">
+ <require>
+ <enum name="GL_PIXEL_PACK_BUFFER_ARB"/>
+ <enum name="GL_PIXEL_UNPACK_BUFFER_ARB"/>
+ <enum name="GL_PIXEL_PACK_BUFFER_BINDING_ARB"/>
+ <enum name="GL_PIXEL_UNPACK_BUFFER_BINDING_ARB"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_point_parameters" supported="gl">
+ <require>
+ <enum name="GL_POINT_SIZE_MIN_ARB"/>
+ <enum name="GL_POINT_SIZE_MAX_ARB"/>
+ <enum name="GL_POINT_FADE_THRESHOLD_SIZE_ARB"/>
+ <enum name="GL_POINT_DISTANCE_ATTENUATION_ARB"/>
+ <command name="glPointParameterfARB"/>
+ <command name="glPointParameterfvARB"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_point_sprite" supported="gl">
+ <require>
+ <enum name="GL_POINT_SPRITE_ARB"/>
+ <enum name="GL_COORD_REPLACE_ARB"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_program_interface_query" supported="gl|glcore">
+ <require>
+ <enum name="GL_UNIFORM"/>
+ <enum name="GL_UNIFORM_BLOCK"/>
+ <enum name="GL_PROGRAM_INPUT"/>
+ <enum name="GL_PROGRAM_OUTPUT"/>
+ <enum name="GL_BUFFER_VARIABLE"/>
+ <enum name="GL_SHADER_STORAGE_BLOCK"/>
+ <enum name="GL_ATOMIC_COUNTER_BUFFER"/>
+ <enum name="GL_VERTEX_SUBROUTINE"/>
+ <enum name="GL_TESS_CONTROL_SUBROUTINE"/>
+ <enum name="GL_TESS_EVALUATION_SUBROUTINE"/>
+ <enum name="GL_GEOMETRY_SUBROUTINE"/>
+ <enum name="GL_FRAGMENT_SUBROUTINE"/>
+ <enum name="GL_COMPUTE_SUBROUTINE"/>
+ <enum name="GL_VERTEX_SUBROUTINE_UNIFORM"/>
+ <enum name="GL_TESS_CONTROL_SUBROUTINE_UNIFORM"/>
+ <enum name="GL_TESS_EVALUATION_SUBROUTINE_UNIFORM"/>
+ <enum name="GL_GEOMETRY_SUBROUTINE_UNIFORM"/>
+ <enum name="GL_FRAGMENT_SUBROUTINE_UNIFORM"/>
+ <enum name="GL_COMPUTE_SUBROUTINE_UNIFORM"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_VARYING"/>
+ <enum name="GL_ACTIVE_RESOURCES"/>
+ <enum name="GL_MAX_NAME_LENGTH"/>
+ <enum name="GL_MAX_NUM_ACTIVE_VARIABLES"/>
+ <enum name="GL_MAX_NUM_COMPATIBLE_SUBROUTINES"/>
+ <enum name="GL_NAME_LENGTH"/>
+ <enum name="GL_TYPE"/>
+ <enum name="GL_ARRAY_SIZE"/>
+ <enum name="GL_OFFSET"/>
+ <enum name="GL_BLOCK_INDEX"/>
+ <enum name="GL_ARRAY_STRIDE"/>
+ <enum name="GL_MATRIX_STRIDE"/>
+ <enum name="GL_IS_ROW_MAJOR"/>
+ <enum name="GL_ATOMIC_COUNTER_BUFFER_INDEX"/>
+ <enum name="GL_BUFFER_BINDING"/>
+ <enum name="GL_BUFFER_DATA_SIZE"/>
+ <enum name="GL_NUM_ACTIVE_VARIABLES"/>
+ <enum name="GL_ACTIVE_VARIABLES"/>
+ <enum name="GL_REFERENCED_BY_VERTEX_SHADER"/>
+ <enum name="GL_REFERENCED_BY_TESS_CONTROL_SHADER"/>
+ <enum name="GL_REFERENCED_BY_TESS_EVALUATION_SHADER"/>
+ <enum name="GL_REFERENCED_BY_GEOMETRY_SHADER"/>
+ <enum name="GL_REFERENCED_BY_FRAGMENT_SHADER"/>
+ <enum name="GL_REFERENCED_BY_COMPUTE_SHADER"/>
+ <enum name="GL_TOP_LEVEL_ARRAY_SIZE"/>
+ <enum name="GL_TOP_LEVEL_ARRAY_STRIDE"/>
+ <enum name="GL_LOCATION"/>
+ <enum name="GL_LOCATION_INDEX"/>
+ <enum name="GL_IS_PER_PATCH"/>
+ <enum name="GL_NUM_COMPATIBLE_SUBROUTINES"/>
+ <enum name="GL_COMPATIBLE_SUBROUTINES"/>
+ <command name="glGetProgramInterfaceiv"/>
+ <command name="glGetProgramResourceIndex"/>
+ <command name="glGetProgramResourceName"/>
+ <command name="glGetProgramResourceiv"/>
+ <command name="glGetProgramResourceLocation"/>
+ <command name="glGetProgramResourceLocationIndex"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_provoking_vertex" supported="gl|glcore">
+ <require>
+ <enum name="GL_QUADS_FOLLOW_PROVOKING_VERTEX_CONVENTION"/>
+ <enum name="GL_FIRST_VERTEX_CONVENTION"/>
+ <enum name="GL_LAST_VERTEX_CONVENTION"/>
+ <enum name="GL_PROVOKING_VERTEX"/>
+ <command name="glProvokingVertex"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_query_buffer_object" supported="gl|glcore">
+ <require>
+ <enum name="GL_QUERY_BUFFER"/>
+ <enum name="GL_QUERY_BUFFER_BARRIER_BIT"/>
+ <enum name="GL_QUERY_BUFFER_BINDING"/>
+ <enum name="GL_QUERY_RESULT_NO_WAIT"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_robust_buffer_access_behavior" supported="gl|glcore"/>
+ <extension name="GL_ARB_robustness" supported="gl|glcore">
+ <require>
+ <enum name="GL_NO_ERROR"/>
+ <enum name="GL_CONTEXT_FLAG_ROBUST_ACCESS_BIT_ARB"/>
+ <enum name="GL_LOSE_CONTEXT_ON_RESET_ARB"/>
+ <enum name="GL_GUILTY_CONTEXT_RESET_ARB"/>
+ <enum name="GL_INNOCENT_CONTEXT_RESET_ARB"/>
+ <enum name="GL_UNKNOWN_CONTEXT_RESET_ARB"/>
+ <enum name="GL_RESET_NOTIFICATION_STRATEGY_ARB"/>
+ <enum name="GL_NO_RESET_NOTIFICATION_ARB"/>
+ <command name="glGetGraphicsResetStatusARB"/>
+ <command name="glGetnTexImageARB"/>
+ <command name="glReadnPixelsARB"/>
+ <command name="glGetnCompressedTexImageARB"/>
+ <command name="glGetnUniformfvARB"/>
+ <command name="glGetnUniformivARB"/>
+ <command name="glGetnUniformuivARB"/>
+ <command name="glGetnUniformdvARB"/>
+ </require>
+ <require api="gl" profile="compatibility">
+ <command name="glGetnMapdvARB"/>
+ <command name="glGetnMapfvARB"/>
+ <command name="glGetnMapivARB"/>
+ <command name="glGetnPixelMapfvARB"/>
+ <command name="glGetnPixelMapuivARB"/>
+ <command name="glGetnPixelMapusvARB"/>
+ <command name="glGetnPolygonStippleARB"/>
+ <command name="glGetnColorTableARB"/>
+ <command name="glGetnConvolutionFilterARB"/>
+ <command name="glGetnSeparableFilterARB"/>
+ <command name="glGetnHistogramARB"/>
+ <command name="glGetnMinmaxARB"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_robustness_isolation" supported="gl|glcore"/>
+ <extension name="GL_ARB_sample_shading" supported="gl|glcore">
+ <require>
+ <enum name="GL_SAMPLE_SHADING_ARB"/>
+ <enum name="GL_MIN_SAMPLE_SHADING_VALUE_ARB"/>
+ <command name="glMinSampleShadingARB"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_sampler_objects" supported="gl|glcore">
+ <require>
+ <enum name="GL_SAMPLER_BINDING"/>
+ <command name="glGenSamplers"/>
+ <command name="glDeleteSamplers"/>
+ <command name="glIsSampler"/>
+ <command name="glBindSampler"/>
+ <command name="glSamplerParameteri"/>
+ <command name="glSamplerParameteriv"/>
+ <command name="glSamplerParameterf"/>
+ <command name="glSamplerParameterfv"/>
+ <command name="glSamplerParameterIiv"/>
+ <command name="glSamplerParameterIuiv"/>
+ <command name="glGetSamplerParameteriv"/>
+ <command name="glGetSamplerParameterIiv"/>
+ <command name="glGetSamplerParameterfv"/>
+ <command name="glGetSamplerParameterIuiv"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_seamless_cube_map" supported="gl|glcore">
+ <require>
+ <enum name="GL_TEXTURE_CUBE_MAP_SEAMLESS"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_seamless_cubemap_per_texture" supported="gl|glcore">
+ <require>
+ <enum name="GL_TEXTURE_CUBE_MAP_SEAMLESS"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_separate_shader_objects" supported="gl|glcore">
+ <require>
+ <enum name="GL_VERTEX_SHADER_BIT"/>
+ <enum name="GL_FRAGMENT_SHADER_BIT"/>
+ <enum name="GL_GEOMETRY_SHADER_BIT"/>
+ <enum name="GL_TESS_CONTROL_SHADER_BIT"/>
+ <enum name="GL_TESS_EVALUATION_SHADER_BIT"/>
+ <enum name="GL_ALL_SHADER_BITS"/>
+ <enum name="GL_PROGRAM_SEPARABLE"/>
+ <enum name="GL_ACTIVE_PROGRAM"/>
+ <enum name="GL_PROGRAM_PIPELINE_BINDING"/>
+ <command name="glUseProgramStages"/>
+ <command name="glActiveShaderProgram"/>
+ <command name="glCreateShaderProgramv"/>
+ <command name="glBindProgramPipeline"/>
+ <command name="glDeleteProgramPipelines"/>
+ <command name="glGenProgramPipelines"/>
+ <command name="glIsProgramPipeline"/>
+ <command name="glGetProgramPipelineiv"/>
+ <command name="glProgramUniform1i"/>
+ <command name="glProgramUniform1iv"/>
+ <command name="glProgramUniform1f"/>
+ <command name="glProgramUniform1fv"/>
+ <command name="glProgramUniform1d"/>
+ <command name="glProgramUniform1dv"/>
+ <command name="glProgramUniform1ui"/>
+ <command name="glProgramUniform1uiv"/>
+ <command name="glProgramUniform2i"/>
+ <command name="glProgramUniform2iv"/>
+ <command name="glProgramUniform2f"/>
+ <command name="glProgramUniform2fv"/>
+ <command name="glProgramUniform2d"/>
+ <command name="glProgramUniform2dv"/>
+ <command name="glProgramUniform2ui"/>
+ <command name="glProgramUniform2uiv"/>
+ <command name="glProgramUniform3i"/>
+ <command name="glProgramUniform3iv"/>
+ <command name="glProgramUniform3f"/>
+ <command name="glProgramUniform3fv"/>
+ <command name="glProgramUniform3d"/>
+ <command name="glProgramUniform3dv"/>
+ <command name="glProgramUniform3ui"/>
+ <command name="glProgramUniform3uiv"/>
+ <command name="glProgramUniform4i"/>
+ <command name="glProgramUniform4iv"/>
+ <command name="glProgramUniform4f"/>
+ <command name="glProgramUniform4fv"/>
+ <command name="glProgramUniform4d"/>
+ <command name="glProgramUniform4dv"/>
+ <command name="glProgramUniform4ui"/>
+ <command name="glProgramUniform4uiv"/>
+ <command name="glProgramUniformMatrix2fv"/>
+ <command name="glProgramUniformMatrix3fv"/>
+ <command name="glProgramUniformMatrix4fv"/>
+ <command name="glProgramUniformMatrix2dv"/>
+ <command name="glProgramUniformMatrix3dv"/>
+ <command name="glProgramUniformMatrix4dv"/>
+ <command name="glProgramUniformMatrix2x3fv"/>
+ <command name="glProgramUniformMatrix3x2fv"/>
+ <command name="glProgramUniformMatrix2x4fv"/>
+ <command name="glProgramUniformMatrix4x2fv"/>
+ <command name="glProgramUniformMatrix3x4fv"/>
+ <command name="glProgramUniformMatrix4x3fv"/>
+ <command name="glProgramUniformMatrix2x3dv"/>
+ <command name="glProgramUniformMatrix3x2dv"/>
+ <command name="glProgramUniformMatrix2x4dv"/>
+ <command name="glProgramUniformMatrix4x2dv"/>
+ <command name="glProgramUniformMatrix3x4dv"/>
+ <command name="glProgramUniformMatrix4x3dv"/>
+ <command name="glValidateProgramPipeline"/>
+ <command name="glGetProgramPipelineInfoLog"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_shader_atomic_counters" supported="gl|glcore">
+ <require>
+ <enum name="GL_ATOMIC_COUNTER_BUFFER"/>
+ <enum name="GL_ATOMIC_COUNTER_BUFFER_BINDING"/>
+ <enum name="GL_ATOMIC_COUNTER_BUFFER_START"/>
+ <enum name="GL_ATOMIC_COUNTER_BUFFER_SIZE"/>
+ <enum name="GL_ATOMIC_COUNTER_BUFFER_DATA_SIZE"/>
+ <enum name="GL_ATOMIC_COUNTER_BUFFER_ACTIVE_ATOMIC_COUNTERS"/>
+ <enum name="GL_ATOMIC_COUNTER_BUFFER_ACTIVE_ATOMIC_COUNTER_INDICES"/>
+ <enum name="GL_ATOMIC_COUNTER_BUFFER_REFERENCED_BY_VERTEX_SHADER"/>
+ <enum name="GL_ATOMIC_COUNTER_BUFFER_REFERENCED_BY_TESS_CONTROL_SHADER"/>
+ <enum name="GL_ATOMIC_COUNTER_BUFFER_REFERENCED_BY_TESS_EVALUATION_SHADER"/>
+ <enum name="GL_ATOMIC_COUNTER_BUFFER_REFERENCED_BY_GEOMETRY_SHADER"/>
+ <enum name="GL_ATOMIC_COUNTER_BUFFER_REFERENCED_BY_FRAGMENT_SHADER"/>
+ <enum name="GL_MAX_VERTEX_ATOMIC_COUNTER_BUFFERS"/>
+ <enum name="GL_MAX_TESS_CONTROL_ATOMIC_COUNTER_BUFFERS"/>
+ <enum name="GL_MAX_TESS_EVALUATION_ATOMIC_COUNTER_BUFFERS"/>
+ <enum name="GL_MAX_GEOMETRY_ATOMIC_COUNTER_BUFFERS"/>
+ <enum name="GL_MAX_FRAGMENT_ATOMIC_COUNTER_BUFFERS"/>
+ <enum name="GL_MAX_COMBINED_ATOMIC_COUNTER_BUFFERS"/>
+ <enum name="GL_MAX_VERTEX_ATOMIC_COUNTERS"/>
+ <enum name="GL_MAX_TESS_CONTROL_ATOMIC_COUNTERS"/>
+ <enum name="GL_MAX_TESS_EVALUATION_ATOMIC_COUNTERS"/>
+ <enum name="GL_MAX_GEOMETRY_ATOMIC_COUNTERS"/>
+ <enum name="GL_MAX_FRAGMENT_ATOMIC_COUNTERS"/>
+ <enum name="GL_MAX_COMBINED_ATOMIC_COUNTERS"/>
+ <enum name="GL_MAX_ATOMIC_COUNTER_BUFFER_SIZE"/>
+ <enum name="GL_MAX_ATOMIC_COUNTER_BUFFER_BINDINGS"/>
+ <enum name="GL_ACTIVE_ATOMIC_COUNTER_BUFFERS"/>
+ <enum name="GL_UNIFORM_ATOMIC_COUNTER_BUFFER_INDEX"/>
+ <enum name="GL_UNSIGNED_INT_ATOMIC_COUNTER"/>
+ <command name="glGetActiveAtomicCounterBufferiv"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_shader_bit_encoding" supported="gl|glcore"/>
+ <extension name="GL_ARB_shader_draw_parameters" supported="gl|glcore"/>
+ <extension name="GL_ARB_shader_group_vote" supported="gl|glcore"/>
+ <extension name="GL_ARB_shader_image_load_store" supported="gl|glcore">
+ <require>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY_BARRIER_BIT"/>
+ <enum name="GL_ELEMENT_ARRAY_BARRIER_BIT"/>
+ <enum name="GL_UNIFORM_BARRIER_BIT"/>
+ <enum name="GL_TEXTURE_FETCH_BARRIER_BIT"/>
+ <enum name="GL_SHADER_IMAGE_ACCESS_BARRIER_BIT"/>
+ <enum name="GL_COMMAND_BARRIER_BIT"/>
+ <enum name="GL_PIXEL_BUFFER_BARRIER_BIT"/>
+ <enum name="GL_TEXTURE_UPDATE_BARRIER_BIT"/>
+ <enum name="GL_BUFFER_UPDATE_BARRIER_BIT"/>
+ <enum name="GL_FRAMEBUFFER_BARRIER_BIT"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_BARRIER_BIT"/>
+ <enum name="GL_ATOMIC_COUNTER_BARRIER_BIT"/>
+ <enum name="GL_ALL_BARRIER_BITS"/>
+ <enum name="GL_MAX_IMAGE_UNITS"/>
+ <enum name="GL_MAX_COMBINED_IMAGE_UNITS_AND_FRAGMENT_OUTPUTS"/>
+ <enum name="GL_IMAGE_BINDING_NAME"/>
+ <enum name="GL_IMAGE_BINDING_LEVEL"/>
+ <enum name="GL_IMAGE_BINDING_LAYERED"/>
+ <enum name="GL_IMAGE_BINDING_LAYER"/>
+ <enum name="GL_IMAGE_BINDING_ACCESS"/>
+ <enum name="GL_IMAGE_1D"/>
+ <enum name="GL_IMAGE_2D"/>
+ <enum name="GL_IMAGE_3D"/>
+ <enum name="GL_IMAGE_2D_RECT"/>
+ <enum name="GL_IMAGE_CUBE"/>
+ <enum name="GL_IMAGE_BUFFER"/>
+ <enum name="GL_IMAGE_1D_ARRAY"/>
+ <enum name="GL_IMAGE_2D_ARRAY"/>
+ <enum name="GL_IMAGE_CUBE_MAP_ARRAY"/>
+ <enum name="GL_IMAGE_2D_MULTISAMPLE"/>
+ <enum name="GL_IMAGE_2D_MULTISAMPLE_ARRAY"/>
+ <enum name="GL_INT_IMAGE_1D"/>
+ <enum name="GL_INT_IMAGE_2D"/>
+ <enum name="GL_INT_IMAGE_3D"/>
+ <enum name="GL_INT_IMAGE_2D_RECT"/>
+ <enum name="GL_INT_IMAGE_CUBE"/>
+ <enum name="GL_INT_IMAGE_BUFFER"/>
+ <enum name="GL_INT_IMAGE_1D_ARRAY"/>
+ <enum name="GL_INT_IMAGE_2D_ARRAY"/>
+ <enum name="GL_INT_IMAGE_CUBE_MAP_ARRAY"/>
+ <enum name="GL_INT_IMAGE_2D_MULTISAMPLE"/>
+ <enum name="GL_INT_IMAGE_2D_MULTISAMPLE_ARRAY"/>
+ <enum name="GL_UNSIGNED_INT_IMAGE_1D"/>
+ <enum name="GL_UNSIGNED_INT_IMAGE_2D"/>
+ <enum name="GL_UNSIGNED_INT_IMAGE_3D"/>
+ <enum name="GL_UNSIGNED_INT_IMAGE_2D_RECT"/>
+ <enum name="GL_UNSIGNED_INT_IMAGE_CUBE"/>
+ <enum name="GL_UNSIGNED_INT_IMAGE_BUFFER"/>
+ <enum name="GL_UNSIGNED_INT_IMAGE_1D_ARRAY"/>
+ <enum name="GL_UNSIGNED_INT_IMAGE_2D_ARRAY"/>
+ <enum name="GL_UNSIGNED_INT_IMAGE_CUBE_MAP_ARRAY"/>
+ <enum name="GL_UNSIGNED_INT_IMAGE_2D_MULTISAMPLE"/>
+ <enum name="GL_UNSIGNED_INT_IMAGE_2D_MULTISAMPLE_ARRAY"/>
+ <enum name="GL_MAX_IMAGE_SAMPLES"/>
+ <enum name="GL_IMAGE_BINDING_FORMAT"/>
+ <enum name="GL_IMAGE_FORMAT_COMPATIBILITY_TYPE"/>
+ <enum name="GL_IMAGE_FORMAT_COMPATIBILITY_BY_SIZE"/>
+ <enum name="GL_IMAGE_FORMAT_COMPATIBILITY_BY_CLASS"/>
+ <enum name="GL_MAX_VERTEX_IMAGE_UNIFORMS"/>
+ <enum name="GL_MAX_TESS_CONTROL_IMAGE_UNIFORMS"/>
+ <enum name="GL_MAX_TESS_EVALUATION_IMAGE_UNIFORMS"/>
+ <enum name="GL_MAX_GEOMETRY_IMAGE_UNIFORMS"/>
+ <enum name="GL_MAX_FRAGMENT_IMAGE_UNIFORMS"/>
+ <enum name="GL_MAX_COMBINED_IMAGE_UNIFORMS"/>
+ <command name="glBindImageTexture"/>
+ <command name="glMemoryBarrier"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_shader_image_size" supported="gl|glcore"/>
+ <extension name="GL_ARB_shader_objects" supported="gl">
+ <require>
+ <enum name="GL_PROGRAM_OBJECT_ARB"/>
+ <enum name="GL_SHADER_OBJECT_ARB"/>
+ <enum name="GL_OBJECT_TYPE_ARB"/>
+ <enum name="GL_OBJECT_SUBTYPE_ARB"/>
+ <enum name="GL_FLOAT_VEC2_ARB"/>
+ <enum name="GL_FLOAT_VEC3_ARB"/>
+ <enum name="GL_FLOAT_VEC4_ARB"/>
+ <enum name="GL_INT_VEC2_ARB"/>
+ <enum name="GL_INT_VEC3_ARB"/>
+ <enum name="GL_INT_VEC4_ARB"/>
+ <enum name="GL_BOOL_ARB"/>
+ <enum name="GL_BOOL_VEC2_ARB"/>
+ <enum name="GL_BOOL_VEC3_ARB"/>
+ <enum name="GL_BOOL_VEC4_ARB"/>
+ <enum name="GL_FLOAT_MAT2_ARB"/>
+ <enum name="GL_FLOAT_MAT3_ARB"/>
+ <enum name="GL_FLOAT_MAT4_ARB"/>
+ <enum name="GL_SAMPLER_1D_ARB"/>
+ <enum name="GL_SAMPLER_2D_ARB"/>
+ <enum name="GL_SAMPLER_3D_ARB"/>
+ <enum name="GL_SAMPLER_CUBE_ARB"/>
+ <enum name="GL_SAMPLER_1D_SHADOW_ARB"/>
+ <enum name="GL_SAMPLER_2D_SHADOW_ARB"/>
+ <enum name="GL_SAMPLER_2D_RECT_ARB"/>
+ <enum name="GL_SAMPLER_2D_RECT_SHADOW_ARB"/>
+ <enum name="GL_OBJECT_DELETE_STATUS_ARB"/>
+ <enum name="GL_OBJECT_COMPILE_STATUS_ARB"/>
+ <enum name="GL_OBJECT_LINK_STATUS_ARB"/>
+ <enum name="GL_OBJECT_VALIDATE_STATUS_ARB"/>
+ <enum name="GL_OBJECT_INFO_LOG_LENGTH_ARB"/>
+ <enum name="GL_OBJECT_ATTACHED_OBJECTS_ARB"/>
+ <enum name="GL_OBJECT_ACTIVE_UNIFORMS_ARB"/>
+ <enum name="GL_OBJECT_ACTIVE_UNIFORM_MAX_LENGTH_ARB"/>
+ <enum name="GL_OBJECT_SHADER_SOURCE_LENGTH_ARB"/>
+ <command name="glDeleteObjectARB"/>
+ <command name="glGetHandleARB"/>
+ <command name="glDetachObjectARB"/>
+ <command name="glCreateShaderObjectARB"/>
+ <command name="glShaderSourceARB"/>
+ <command name="glCompileShaderARB"/>
+ <command name="glCreateProgramObjectARB"/>
+ <command name="glAttachObjectARB"/>
+ <command name="glLinkProgramARB"/>
+ <command name="glUseProgramObjectARB"/>
+ <command name="glValidateProgramARB"/>
+ <command name="glUniform1fARB"/>
+ <command name="glUniform2fARB"/>
+ <command name="glUniform3fARB"/>
+ <command name="glUniform4fARB"/>
+ <command name="glUniform1iARB"/>
+ <command name="glUniform2iARB"/>
+ <command name="glUniform3iARB"/>
+ <command name="glUniform4iARB"/>
+ <command name="glUniform1fvARB"/>
+ <command name="glUniform2fvARB"/>
+ <command name="glUniform3fvARB"/>
+ <command name="glUniform4fvARB"/>
+ <command name="glUniform1ivARB"/>
+ <command name="glUniform2ivARB"/>
+ <command name="glUniform3ivARB"/>
+ <command name="glUniform4ivARB"/>
+ <command name="glUniformMatrix2fvARB"/>
+ <command name="glUniformMatrix3fvARB"/>
+ <command name="glUniformMatrix4fvARB"/>
+ <command name="glGetObjectParameterfvARB"/>
+ <command name="glGetObjectParameterivARB"/>
+ <command name="glGetInfoLogARB"/>
+ <command name="glGetAttachedObjectsARB"/>
+ <command name="glGetUniformLocationARB"/>
+ <command name="glGetActiveUniformARB"/>
+ <command name="glGetUniformfvARB"/>
+ <command name="glGetUniformivARB"/>
+ <command name="glGetShaderSourceARB"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_shader_precision" supported="gl|glcore"/>
+ <extension name="GL_ARB_shader_stencil_export" supported="gl|glcore"/>
+ <extension name="GL_ARB_shader_storage_buffer_object" supported="gl|glcore">
+ <require>
+ <enum name="GL_SHADER_STORAGE_BUFFER"/>
+ <enum name="GL_SHADER_STORAGE_BUFFER_BINDING"/>
+ <enum name="GL_SHADER_STORAGE_BUFFER_START"/>
+ <enum name="GL_SHADER_STORAGE_BUFFER_SIZE"/>
+ <enum name="GL_MAX_VERTEX_SHADER_STORAGE_BLOCKS"/>
+ <enum name="GL_MAX_GEOMETRY_SHADER_STORAGE_BLOCKS"/>
+ <enum name="GL_MAX_TESS_CONTROL_SHADER_STORAGE_BLOCKS"/>
+ <enum name="GL_MAX_TESS_EVALUATION_SHADER_STORAGE_BLOCKS"/>
+ <enum name="GL_MAX_FRAGMENT_SHADER_STORAGE_BLOCKS"/>
+ <enum name="GL_MAX_COMPUTE_SHADER_STORAGE_BLOCKS"/>
+ <enum name="GL_MAX_COMBINED_SHADER_STORAGE_BLOCKS"/>
+ <enum name="GL_MAX_SHADER_STORAGE_BUFFER_BINDINGS"/>
+ <enum name="GL_MAX_SHADER_STORAGE_BLOCK_SIZE"/>
+ <enum name="GL_SHADER_STORAGE_BUFFER_OFFSET_ALIGNMENT"/>
+ <enum name="GL_SHADER_STORAGE_BARRIER_BIT"/>
+ <enum name="GL_MAX_COMBINED_SHADER_OUTPUT_RESOURCES"/>
+ <enum name="GL_MAX_COMBINED_IMAGE_UNITS_AND_FRAGMENT_OUTPUTS"/>
+ <command name="glShaderStorageBlockBinding"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_shader_subroutine" supported="gl|glcore">
+ <require>
+ <enum name="GL_ACTIVE_SUBROUTINES"/>
+ <enum name="GL_ACTIVE_SUBROUTINE_UNIFORMS"/>
+ <enum name="GL_ACTIVE_SUBROUTINE_UNIFORM_LOCATIONS"/>
+ <enum name="GL_ACTIVE_SUBROUTINE_MAX_LENGTH"/>
+ <enum name="GL_ACTIVE_SUBROUTINE_UNIFORM_MAX_LENGTH"/>
+ <enum name="GL_MAX_SUBROUTINES"/>
+ <enum name="GL_MAX_SUBROUTINE_UNIFORM_LOCATIONS"/>
+ <enum name="GL_NUM_COMPATIBLE_SUBROUTINES"/>
+ <enum name="GL_COMPATIBLE_SUBROUTINES"/>
+ <enum name="GL_UNIFORM_SIZE"/>
+ <enum name="GL_UNIFORM_NAME_LENGTH"/>
+ <command name="glGetSubroutineUniformLocation"/>
+ <command name="glGetSubroutineIndex"/>
+ <command name="glGetActiveSubroutineUniformiv"/>
+ <command name="glGetActiveSubroutineUniformName"/>
+ <command name="glGetActiveSubroutineName"/>
+ <command name="glUniformSubroutinesuiv"/>
+ <command name="glGetUniformSubroutineuiv"/>
+ <command name="glGetProgramStageiv"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_shader_texture_image_samples" supported="gl|glcore"/>
+ <extension name="GL_ARB_shader_texture_lod" supported="gl"/>
+ <extension name="GL_ARB_shading_language_100" supported="gl">
+ <require>
+ <enum name="GL_SHADING_LANGUAGE_VERSION_ARB"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_shading_language_420pack" supported="gl|glcore"/>
+ <extension name="GL_ARB_shading_language_include" supported="gl|glcore">
+ <require>
+ <enum name="GL_SHADER_INCLUDE_ARB"/>
+ <enum name="GL_NAMED_STRING_LENGTH_ARB"/>
+ <enum name="GL_NAMED_STRING_TYPE_ARB"/>
+ <command name="glNamedStringARB"/>
+ <command name="glDeleteNamedStringARB"/>
+ <command name="glCompileShaderIncludeARB"/>
+ <command name="glIsNamedStringARB"/>
+ <command name="glGetNamedStringARB"/>
+ <command name="glGetNamedStringivARB"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_shading_language_packing" supported="gl|glcore"/>
+ <extension name="GL_ARB_shadow" supported="gl">
+ <require>
+ <enum name="GL_TEXTURE_COMPARE_MODE_ARB"/>
+ <enum name="GL_TEXTURE_COMPARE_FUNC_ARB"/>
+ <enum name="GL_COMPARE_R_TO_TEXTURE_ARB"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_shadow_ambient" supported="gl">
+ <require>
+ <enum name="GL_TEXTURE_COMPARE_FAIL_VALUE_ARB"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_sparse_buffer" supported="gl|glcore">
+ <require>
+ <enum name="GL_SPARSE_STORAGE_BIT_ARB"/>
+ <enum name="GL_SPARSE_BUFFER_PAGE_SIZE_ARB"/>
+ <command name="glBufferPageCommitmentARB"/>
+ </require>
+ <require comment="Supported only if GL_EXT_direct_state_access is supported">
+ <command name="glNamedBufferPageCommitmentEXT"/>
+ </require>
+ <require comment="Supported only if GL_ARb_direct_state_access or GL 4.5 is supported">
+ <command name="glNamedBufferPageCommitmentARB"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_sparse_texture" supported="gl|glcore">
+ <require>
+ <enum name="GL_TEXTURE_SPARSE_ARB"/>
+ <enum name="GL_VIRTUAL_PAGE_SIZE_INDEX_ARB"/>
+ <enum name="GL_MIN_SPARSE_LEVEL_ARB"/>
+ <enum name="GL_NUM_VIRTUAL_PAGE_SIZES_ARB"/>
+ <enum name="GL_VIRTUAL_PAGE_SIZE_X_ARB"/>
+ <enum name="GL_VIRTUAL_PAGE_SIZE_Y_ARB"/>
+ <enum name="GL_VIRTUAL_PAGE_SIZE_Z_ARB"/>
+ <enum name="GL_MAX_SPARSE_TEXTURE_SIZE_ARB"/>
+ <enum name="GL_MAX_SPARSE_3D_TEXTURE_SIZE_ARB"/>
+ <enum name="GL_MAX_SPARSE_ARRAY_TEXTURE_LAYERS_ARB"/>
+ <enum name="GL_SPARSE_TEXTURE_FULL_ARRAY_CUBE_MIPMAPS_ARB"/>
+ <command name="glTexPageCommitmentARB"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_stencil_texturing" supported="gl|glcore">
+ <require>
+ <enum name="GL_DEPTH_STENCIL_TEXTURE_MODE"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_sync" supported="gl|glcore">
+ <require>
+ <enum name="GL_MAX_SERVER_WAIT_TIMEOUT"/>
+ <enum name="GL_OBJECT_TYPE"/>
+ <enum name="GL_SYNC_CONDITION"/>
+ <enum name="GL_SYNC_STATUS"/>
+ <enum name="GL_SYNC_FLAGS"/>
+ <enum name="GL_SYNC_FENCE"/>
+ <enum name="GL_SYNC_GPU_COMMANDS_COMPLETE"/>
+ <enum name="GL_UNSIGNALED"/>
+ <enum name="GL_SIGNALED"/>
+ <enum name="GL_ALREADY_SIGNALED"/>
+ <enum name="GL_TIMEOUT_EXPIRED"/>
+ <enum name="GL_CONDITION_SATISFIED"/>
+ <enum name="GL_WAIT_FAILED"/>
+ <enum name="GL_SYNC_FLUSH_COMMANDS_BIT"/>
+ <enum name="GL_TIMEOUT_IGNORED"/>
+ <command name="glFenceSync"/>
+ <command name="glIsSync"/>
+ <command name="glDeleteSync"/>
+ <command name="glClientWaitSync"/>
+ <command name="glWaitSync"/>
+ <command name="glGetInteger64v"/>
+ <command name="glGetSynciv"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_tessellation_shader" supported="gl|glcore">
+ <require>
+ <enum name="GL_PATCHES"/>
+ <enum name="GL_PATCH_VERTICES"/>
+ <enum name="GL_PATCH_DEFAULT_INNER_LEVEL"/>
+ <enum name="GL_PATCH_DEFAULT_OUTER_LEVEL"/>
+ <enum name="GL_TESS_CONTROL_OUTPUT_VERTICES"/>
+ <enum name="GL_TESS_GEN_MODE"/>
+ <enum name="GL_TESS_GEN_SPACING"/>
+ <enum name="GL_TESS_GEN_VERTEX_ORDER"/>
+ <enum name="GL_TESS_GEN_POINT_MODE"/>
+ <enum name="GL_TRIANGLES"/>
+ <enum name="GL_ISOLINES"/>
+ <enum name="GL_QUADS"/>
+ <enum name="GL_EQUAL"/>
+ <enum name="GL_FRACTIONAL_ODD"/>
+ <enum name="GL_FRACTIONAL_EVEN"/>
+ <enum name="GL_CCW"/>
+ <enum name="GL_CW"/>
+ <enum name="GL_MAX_PATCH_VERTICES"/>
+ <enum name="GL_MAX_TESS_GEN_LEVEL"/>
+ <enum name="GL_MAX_TESS_CONTROL_UNIFORM_COMPONENTS"/>
+ <enum name="GL_MAX_TESS_EVALUATION_UNIFORM_COMPONENTS"/>
+ <enum name="GL_MAX_TESS_CONTROL_TEXTURE_IMAGE_UNITS"/>
+ <enum name="GL_MAX_TESS_EVALUATION_TEXTURE_IMAGE_UNITS"/>
+ <enum name="GL_MAX_TESS_CONTROL_OUTPUT_COMPONENTS"/>
+ <enum name="GL_MAX_TESS_PATCH_COMPONENTS"/>
+ <enum name="GL_MAX_TESS_CONTROL_TOTAL_OUTPUT_COMPONENTS"/>
+ <enum name="GL_MAX_TESS_EVALUATION_OUTPUT_COMPONENTS"/>
+ <enum name="GL_MAX_TESS_CONTROL_UNIFORM_BLOCKS"/>
+ <enum name="GL_MAX_TESS_EVALUATION_UNIFORM_BLOCKS"/>
+ <enum name="GL_MAX_TESS_CONTROL_INPUT_COMPONENTS"/>
+ <enum name="GL_MAX_TESS_EVALUATION_INPUT_COMPONENTS"/>
+ <enum name="GL_MAX_COMBINED_TESS_CONTROL_UNIFORM_COMPONENTS"/>
+ <enum name="GL_MAX_COMBINED_TESS_EVALUATION_UNIFORM_COMPONENTS"/>
+ <enum name="GL_UNIFORM_BLOCK_REFERENCED_BY_TESS_CONTROL_SHADER"/>
+ <enum name="GL_UNIFORM_BLOCK_REFERENCED_BY_TESS_EVALUATION_SHADER"/>
+ <enum name="GL_TESS_EVALUATION_SHADER"/>
+ <enum name="GL_TESS_CONTROL_SHADER"/>
+ <command name="glPatchParameteri"/>
+ <command name="glPatchParameterfv"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_texture_barrier" supported="gl|glcore">
+ <require>
+ <command name="glTextureBarrier"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_texture_border_clamp" supported="gl">
+ <require>
+ <enum name="GL_CLAMP_TO_BORDER_ARB"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_texture_buffer_object" supported="gl">
+ <require>
+ <enum name="GL_TEXTURE_BUFFER_ARB"/>
+ <enum name="GL_MAX_TEXTURE_BUFFER_SIZE_ARB"/>
+ <enum name="GL_TEXTURE_BINDING_BUFFER_ARB"/>
+ <enum name="GL_TEXTURE_BUFFER_DATA_STORE_BINDING_ARB"/>
+ <enum name="GL_TEXTURE_BUFFER_FORMAT_ARB"/>
+ <command name="glTexBufferARB"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_texture_buffer_object_rgb32" supported="gl|glcore">
+ <require>
+ <enum name="GL_RGB32F"/>
+ <enum name="GL_RGB32UI"/>
+ <enum name="GL_RGB32I"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_texture_buffer_range" supported="gl|glcore">
+ <require>
+ <enum name="GL_TEXTURE_BUFFER_OFFSET"/>
+ <enum name="GL_TEXTURE_BUFFER_SIZE"/>
+ <enum name="GL_TEXTURE_BUFFER_OFFSET_ALIGNMENT"/>
+ <command name="glTexBufferRange"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_texture_compression" supported="gl">
+ <require>
+ <enum name="GL_COMPRESSED_ALPHA_ARB"/>
+ <enum name="GL_COMPRESSED_LUMINANCE_ARB"/>
+ <enum name="GL_COMPRESSED_LUMINANCE_ALPHA_ARB"/>
+ <enum name="GL_COMPRESSED_INTENSITY_ARB"/>
+ <enum name="GL_COMPRESSED_RGB_ARB"/>
+ <enum name="GL_COMPRESSED_RGBA_ARB"/>
+ <enum name="GL_TEXTURE_COMPRESSION_HINT_ARB"/>
+ <enum name="GL_TEXTURE_COMPRESSED_IMAGE_SIZE_ARB"/>
+ <enum name="GL_TEXTURE_COMPRESSED_ARB"/>
+ <enum name="GL_NUM_COMPRESSED_TEXTURE_FORMATS_ARB"/>
+ <enum name="GL_COMPRESSED_TEXTURE_FORMATS_ARB"/>
+ <command name="glCompressedTexImage3DARB"/>
+ <command name="glCompressedTexImage2DARB"/>
+ <command name="glCompressedTexImage1DARB"/>
+ <command name="glCompressedTexSubImage3DARB"/>
+ <command name="glCompressedTexSubImage2DARB"/>
+ <command name="glCompressedTexSubImage1DARB"/>
+ <command name="glGetCompressedTexImageARB"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_texture_compression_bptc" supported="gl|glcore">
+ <require>
+ <enum name="GL_COMPRESSED_RGBA_BPTC_UNORM_ARB"/>
+ <enum name="GL_COMPRESSED_SRGB_ALPHA_BPTC_UNORM_ARB"/>
+ <enum name="GL_COMPRESSED_RGB_BPTC_SIGNED_FLOAT_ARB"/>
+ <enum name="GL_COMPRESSED_RGB_BPTC_UNSIGNED_FLOAT_ARB"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_texture_compression_rgtc" supported="gl|glcore">
+ <require>
+ <enum name="GL_COMPRESSED_RED_RGTC1"/>
+ <enum name="GL_COMPRESSED_SIGNED_RED_RGTC1"/>
+ <enum name="GL_COMPRESSED_RG_RGTC2"/>
+ <enum name="GL_COMPRESSED_SIGNED_RG_RGTC2"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_texture_cube_map" supported="gl">
+ <require>
+ <enum name="GL_NORMAL_MAP_ARB"/>
+ <enum name="GL_REFLECTION_MAP_ARB"/>
+ <enum name="GL_TEXTURE_CUBE_MAP_ARB"/>
+ <enum name="GL_TEXTURE_BINDING_CUBE_MAP_ARB"/>
+ <enum name="GL_TEXTURE_CUBE_MAP_POSITIVE_X_ARB"/>
+ <enum name="GL_TEXTURE_CUBE_MAP_NEGATIVE_X_ARB"/>
+ <enum name="GL_TEXTURE_CUBE_MAP_POSITIVE_Y_ARB"/>
+ <enum name="GL_TEXTURE_CUBE_MAP_NEGATIVE_Y_ARB"/>
+ <enum name="GL_TEXTURE_CUBE_MAP_POSITIVE_Z_ARB"/>
+ <enum name="GL_TEXTURE_CUBE_MAP_NEGATIVE_Z_ARB"/>
+ <enum name="GL_PROXY_TEXTURE_CUBE_MAP_ARB"/>
+ <enum name="GL_MAX_CUBE_MAP_TEXTURE_SIZE_ARB"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_texture_cube_map_array" supported="gl|glcore">
+ <require>
+ <enum name="GL_TEXTURE_CUBE_MAP_ARRAY_ARB"/>
+ <enum name="GL_TEXTURE_BINDING_CUBE_MAP_ARRAY_ARB"/>
+ <enum name="GL_PROXY_TEXTURE_CUBE_MAP_ARRAY_ARB"/>
+ <enum name="GL_SAMPLER_CUBE_MAP_ARRAY_ARB"/>
+ <enum name="GL_SAMPLER_CUBE_MAP_ARRAY_SHADOW_ARB"/>
+ <enum name="GL_INT_SAMPLER_CUBE_MAP_ARRAY_ARB"/>
+ <enum name="GL_UNSIGNED_INT_SAMPLER_CUBE_MAP_ARRAY_ARB"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_texture_env_add" supported="gl"/>
+ <extension name="GL_ARB_texture_env_combine" supported="gl">
+ <require>
+ <enum name="GL_COMBINE_ARB"/>
+ <enum name="GL_COMBINE_RGB_ARB"/>
+ <enum name="GL_COMBINE_ALPHA_ARB"/>
+ <enum name="GL_SOURCE0_RGB_ARB"/>
+ <enum name="GL_SOURCE1_RGB_ARB"/>
+ <enum name="GL_SOURCE2_RGB_ARB"/>
+ <enum name="GL_SOURCE0_ALPHA_ARB"/>
+ <enum name="GL_SOURCE1_ALPHA_ARB"/>
+ <enum name="GL_SOURCE2_ALPHA_ARB"/>
+ <enum name="GL_OPERAND0_RGB_ARB"/>
+ <enum name="GL_OPERAND1_RGB_ARB"/>
+ <enum name="GL_OPERAND2_RGB_ARB"/>
+ <enum name="GL_OPERAND0_ALPHA_ARB"/>
+ <enum name="GL_OPERAND1_ALPHA_ARB"/>
+ <enum name="GL_OPERAND2_ALPHA_ARB"/>
+ <enum name="GL_RGB_SCALE_ARB"/>
+ <enum name="GL_ADD_SIGNED_ARB"/>
+ <enum name="GL_INTERPOLATE_ARB"/>
+ <enum name="GL_SUBTRACT_ARB"/>
+ <enum name="GL_CONSTANT_ARB"/>
+ <enum name="GL_PRIMARY_COLOR_ARB"/>
+ <enum name="GL_PREVIOUS_ARB"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_texture_env_crossbar" supported="gl"/>
+ <extension name="GL_ARB_texture_env_dot3" supported="gl">
+ <require>
+ <enum name="GL_DOT3_RGB_ARB"/>
+ <enum name="GL_DOT3_RGBA_ARB"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_texture_float" supported="gl">
+ <require>
+ <enum name="GL_TEXTURE_RED_TYPE_ARB"/>
+ <enum name="GL_TEXTURE_GREEN_TYPE_ARB"/>
+ <enum name="GL_TEXTURE_BLUE_TYPE_ARB"/>
+ <enum name="GL_TEXTURE_ALPHA_TYPE_ARB"/>
+ <enum name="GL_TEXTURE_LUMINANCE_TYPE_ARB"/>
+ <enum name="GL_TEXTURE_INTENSITY_TYPE_ARB"/>
+ <enum name="GL_TEXTURE_DEPTH_TYPE_ARB"/>
+ <enum name="GL_UNSIGNED_NORMALIZED_ARB"/>
+ <enum name="GL_RGBA32F_ARB"/>
+ <enum name="GL_RGB32F_ARB"/>
+ <enum name="GL_ALPHA32F_ARB"/>
+ <enum name="GL_INTENSITY32F_ARB"/>
+ <enum name="GL_LUMINANCE32F_ARB"/>
+ <enum name="GL_LUMINANCE_ALPHA32F_ARB"/>
+ <enum name="GL_RGBA16F_ARB"/>
+ <enum name="GL_RGB16F_ARB"/>
+ <enum name="GL_ALPHA16F_ARB"/>
+ <enum name="GL_INTENSITY16F_ARB"/>
+ <enum name="GL_LUMINANCE16F_ARB"/>
+ <enum name="GL_LUMINANCE_ALPHA16F_ARB"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_texture_gather" supported="gl|glcore">
+ <require>
+ <enum name="GL_MIN_PROGRAM_TEXTURE_GATHER_OFFSET_ARB"/>
+ <enum name="GL_MAX_PROGRAM_TEXTURE_GATHER_OFFSET_ARB"/>
+ <enum name="GL_MAX_PROGRAM_TEXTURE_GATHER_COMPONENTS_ARB"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_texture_mirror_clamp_to_edge" supported="gl|glcore">
+ <require>
+ <enum name="GL_MIRROR_CLAMP_TO_EDGE"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_texture_mirrored_repeat" supported="gl">
+ <require>
+ <enum name="GL_MIRRORED_REPEAT_ARB"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_texture_multisample" supported="gl|glcore">
+ <require>
+ <enum name="GL_SAMPLE_POSITION"/>
+ <enum name="GL_SAMPLE_MASK"/>
+ <enum name="GL_SAMPLE_MASK_VALUE"/>
+ <enum name="GL_MAX_SAMPLE_MASK_WORDS"/>
+ <enum name="GL_TEXTURE_2D_MULTISAMPLE"/>
+ <enum name="GL_PROXY_TEXTURE_2D_MULTISAMPLE"/>
+ <enum name="GL_TEXTURE_2D_MULTISAMPLE_ARRAY"/>
+ <enum name="GL_PROXY_TEXTURE_2D_MULTISAMPLE_ARRAY"/>
+ <enum name="GL_TEXTURE_BINDING_2D_MULTISAMPLE"/>
+ <enum name="GL_TEXTURE_BINDING_2D_MULTISAMPLE_ARRAY"/>
+ <enum name="GL_TEXTURE_SAMPLES"/>
+ <enum name="GL_TEXTURE_FIXED_SAMPLE_LOCATIONS"/>
+ <enum name="GL_SAMPLER_2D_MULTISAMPLE"/>
+ <enum name="GL_INT_SAMPLER_2D_MULTISAMPLE"/>
+ <enum name="GL_UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE"/>
+ <enum name="GL_SAMPLER_2D_MULTISAMPLE_ARRAY"/>
+ <enum name="GL_INT_SAMPLER_2D_MULTISAMPLE_ARRAY"/>
+ <enum name="GL_UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE_ARRAY"/>
+ <enum name="GL_MAX_COLOR_TEXTURE_SAMPLES"/>
+ <enum name="GL_MAX_DEPTH_TEXTURE_SAMPLES"/>
+ <enum name="GL_MAX_INTEGER_SAMPLES"/>
+ <command name="glTexImage2DMultisample"/>
+ <command name="glTexImage3DMultisample"/>
+ <command name="glGetMultisamplefv"/>
+ <command name="glSampleMaski"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_texture_non_power_of_two" supported="gl"/>
+ <extension name="GL_ARB_texture_query_levels" supported="gl|glcore"/>
+ <extension name="GL_ARB_texture_query_lod" supported="gl|glcore"/>
+ <extension name="GL_ARB_texture_rectangle" supported="gl">
+ <require>
+ <enum name="GL_TEXTURE_RECTANGLE_ARB"/>
+ <enum name="GL_TEXTURE_BINDING_RECTANGLE_ARB"/>
+ <enum name="GL_PROXY_TEXTURE_RECTANGLE_ARB"/>
+ <enum name="GL_MAX_RECTANGLE_TEXTURE_SIZE_ARB"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_texture_rg" supported="gl|glcore">
+ <require>
+ <enum name="GL_RG"/>
+ <enum name="GL_RG_INTEGER"/>
+ <enum name="GL_R8"/>
+ <enum name="GL_R16"/>
+ <enum name="GL_RG8"/>
+ <enum name="GL_RG16"/>
+ <enum name="GL_R16F"/>
+ <enum name="GL_R32F"/>
+ <enum name="GL_RG16F"/>
+ <enum name="GL_RG32F"/>
+ <enum name="GL_R8I"/>
+ <enum name="GL_R8UI"/>
+ <enum name="GL_R16I"/>
+ <enum name="GL_R16UI"/>
+ <enum name="GL_R32I"/>
+ <enum name="GL_R32UI"/>
+ <enum name="GL_RG8I"/>
+ <enum name="GL_RG8UI"/>
+ <enum name="GL_RG16I"/>
+ <enum name="GL_RG16UI"/>
+ <enum name="GL_RG32I"/>
+ <enum name="GL_RG32UI"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_texture_rgb10_a2ui" supported="gl|glcore">
+ <require>
+ <enum name="GL_RGB10_A2UI"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_texture_stencil8" supported="gl|glcore">
+ <require>
+ <enum name="GL_STENCIL_INDEX"/>
+ <enum name="GL_STENCIL_INDEX8"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_texture_storage" supported="gl|glcore">
+ <require>
+ <enum name="GL_TEXTURE_IMMUTABLE_FORMAT"/>
+ <command name="glTexStorage1D"/>
+ <command name="glTexStorage2D"/>
+ <command name="glTexStorage3D"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_texture_storage_multisample" supported="gl|glcore">
+ <require>
+ <command name="glTexStorage2DMultisample"/>
+ <command name="glTexStorage3DMultisample"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_texture_swizzle" supported="gl|glcore">
+ <require>
+ <enum name="GL_TEXTURE_SWIZZLE_R"/>
+ <enum name="GL_TEXTURE_SWIZZLE_G"/>
+ <enum name="GL_TEXTURE_SWIZZLE_B"/>
+ <enum name="GL_TEXTURE_SWIZZLE_A"/>
+ <enum name="GL_TEXTURE_SWIZZLE_RGBA"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_texture_view" supported="gl|glcore">
+ <require>
+ <enum name="GL_TEXTURE_VIEW_MIN_LEVEL"/>
+ <enum name="GL_TEXTURE_VIEW_NUM_LEVELS"/>
+ <enum name="GL_TEXTURE_VIEW_MIN_LAYER"/>
+ <enum name="GL_TEXTURE_VIEW_NUM_LAYERS"/>
+ <enum name="GL_TEXTURE_IMMUTABLE_LEVELS"/>
+ <command name="glTextureView"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_timer_query" supported="gl|glcore">
+ <require>
+ <enum name="GL_TIME_ELAPSED"/>
+ <enum name="GL_TIMESTAMP"/>
+ <command name="glQueryCounter"/>
+ <command name="glGetQueryObjecti64v"/>
+ <command name="glGetQueryObjectui64v"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_transform_feedback2" supported="gl|glcore">
+ <require>
+ <enum name="GL_TRANSFORM_FEEDBACK"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_PAUSED"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_BUFFER_PAUSED"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_ACTIVE"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_BUFFER_ACTIVE"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_BINDING"/>
+ <command name="glBindTransformFeedback"/>
+ <command name="glDeleteTransformFeedbacks"/>
+ <command name="glGenTransformFeedbacks"/>
+ <command name="glIsTransformFeedback"/>
+ <command name="glPauseTransformFeedback"/>
+ <command name="glResumeTransformFeedback"/>
+ <command name="glDrawTransformFeedback"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_transform_feedback3" supported="gl|glcore">
+ <require>
+ <enum name="GL_MAX_TRANSFORM_FEEDBACK_BUFFERS"/>
+ <enum name="GL_MAX_VERTEX_STREAMS"/>
+ <command name="glDrawTransformFeedbackStream"/>
+ <command name="glBeginQueryIndexed"/>
+ <command name="glEndQueryIndexed"/>
+ <command name="glGetQueryIndexediv"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_transform_feedback_instanced" supported="gl|glcore">
+ <require>
+ <command name="glDrawTransformFeedbackInstanced"/>
+ <command name="glDrawTransformFeedbackStreamInstanced"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_transform_feedback_overflow_query" supported="gl|glcore">
+ <require>
+ <enum name="GL_TRANSFORM_FEEDBACK_OVERFLOW_ARB"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_STREAM_OVERFLOW_ARB"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_transpose_matrix" supported="gl">
+ <require>
+ <enum name="GL_TRANSPOSE_MODELVIEW_MATRIX_ARB"/>
+ <enum name="GL_TRANSPOSE_PROJECTION_MATRIX_ARB"/>
+ <enum name="GL_TRANSPOSE_TEXTURE_MATRIX_ARB"/>
+ <enum name="GL_TRANSPOSE_COLOR_MATRIX_ARB"/>
+ <command name="glLoadTransposeMatrixfARB"/>
+ <command name="glLoadTransposeMatrixdARB"/>
+ <command name="glMultTransposeMatrixfARB"/>
+ <command name="glMultTransposeMatrixdARB"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_uniform_buffer_object" supported="gl|glcore">
+ <require>
+ <enum name="GL_UNIFORM_BUFFER"/>
+ <enum name="GL_UNIFORM_BUFFER_BINDING"/>
+ <enum name="GL_UNIFORM_BUFFER_START"/>
+ <enum name="GL_UNIFORM_BUFFER_SIZE"/>
+ <enum name="GL_MAX_VERTEX_UNIFORM_BLOCKS"/>
+ <enum name="GL_MAX_GEOMETRY_UNIFORM_BLOCKS"/>
+ <enum name="GL_MAX_FRAGMENT_UNIFORM_BLOCKS"/>
+ <enum name="GL_MAX_COMBINED_UNIFORM_BLOCKS"/>
+ <enum name="GL_MAX_UNIFORM_BUFFER_BINDINGS"/>
+ <enum name="GL_MAX_UNIFORM_BLOCK_SIZE"/>
+ <enum name="GL_MAX_COMBINED_VERTEX_UNIFORM_COMPONENTS"/>
+ <enum name="GL_MAX_COMBINED_GEOMETRY_UNIFORM_COMPONENTS"/>
+ <enum name="GL_MAX_COMBINED_FRAGMENT_UNIFORM_COMPONENTS"/>
+ <enum name="GL_UNIFORM_BUFFER_OFFSET_ALIGNMENT"/>
+ <enum name="GL_ACTIVE_UNIFORM_BLOCK_MAX_NAME_LENGTH"/>
+ <enum name="GL_ACTIVE_UNIFORM_BLOCKS"/>
+ <enum name="GL_UNIFORM_TYPE"/>
+ <enum name="GL_UNIFORM_SIZE"/>
+ <enum name="GL_UNIFORM_NAME_LENGTH"/>
+ <enum name="GL_UNIFORM_BLOCK_INDEX"/>
+ <enum name="GL_UNIFORM_OFFSET"/>
+ <enum name="GL_UNIFORM_ARRAY_STRIDE"/>
+ <enum name="GL_UNIFORM_MATRIX_STRIDE"/>
+ <enum name="GL_UNIFORM_IS_ROW_MAJOR"/>
+ <enum name="GL_UNIFORM_BLOCK_BINDING"/>
+ <enum name="GL_UNIFORM_BLOCK_DATA_SIZE"/>
+ <enum name="GL_UNIFORM_BLOCK_NAME_LENGTH"/>
+ <enum name="GL_UNIFORM_BLOCK_ACTIVE_UNIFORMS"/>
+ <enum name="GL_UNIFORM_BLOCK_ACTIVE_UNIFORM_INDICES"/>
+ <enum name="GL_UNIFORM_BLOCK_REFERENCED_BY_VERTEX_SHADER"/>
+ <enum name="GL_UNIFORM_BLOCK_REFERENCED_BY_GEOMETRY_SHADER"/>
+ <enum name="GL_UNIFORM_BLOCK_REFERENCED_BY_FRAGMENT_SHADER"/>
+ <enum name="GL_INVALID_INDEX"/>
+ <command name="glGetUniformIndices"/>
+ <command name="glGetActiveUniformsiv"/>
+ <command name="glGetActiveUniformName"/>
+ <command name="glGetUniformBlockIndex"/>
+ <command name="glGetActiveUniformBlockiv"/>
+ <command name="glGetActiveUniformBlockName"/>
+ <command name="glUniformBlockBinding"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_vertex_array_bgra" supported="gl|glcore">
+ <require>
+ <enum name="GL_BGRA"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_vertex_array_object" supported="gl|glcore">
+ <require>
+ <enum name="GL_VERTEX_ARRAY_BINDING"/>
+ <command name="glBindVertexArray"/>
+ <command name="glDeleteVertexArrays"/>
+ <command name="glGenVertexArrays"/>
+ <command name="glIsVertexArray"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_vertex_attrib_64bit" supported="gl|glcore">
+ <require>
+ <enum name="GL_RGB32I"/>
+ <enum name="GL_DOUBLE_VEC2"/>
+ <enum name="GL_DOUBLE_VEC3"/>
+ <enum name="GL_DOUBLE_VEC4"/>
+ <enum name="GL_DOUBLE_MAT2"/>
+ <enum name="GL_DOUBLE_MAT3"/>
+ <enum name="GL_DOUBLE_MAT4"/>
+ <enum name="GL_DOUBLE_MAT2x3"/>
+ <enum name="GL_DOUBLE_MAT2x4"/>
+ <enum name="GL_DOUBLE_MAT3x2"/>
+ <enum name="GL_DOUBLE_MAT3x4"/>
+ <enum name="GL_DOUBLE_MAT4x2"/>
+ <enum name="GL_DOUBLE_MAT4x3"/>
+ <command name="glVertexAttribL1d"/>
+ <command name="glVertexAttribL2d"/>
+ <command name="glVertexAttribL3d"/>
+ <command name="glVertexAttribL4d"/>
+ <command name="glVertexAttribL1dv"/>
+ <command name="glVertexAttribL2dv"/>
+ <command name="glVertexAttribL3dv"/>
+ <command name="glVertexAttribL4dv"/>
+ <command name="glVertexAttribLPointer"/>
+ <command name="glGetVertexAttribLdv"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_vertex_attrib_binding" supported="gl|glcore">
+ <require>
+ <enum name="GL_VERTEX_ATTRIB_BINDING"/>
+ <enum name="GL_VERTEX_ATTRIB_RELATIVE_OFFSET"/>
+ <enum name="GL_VERTEX_BINDING_DIVISOR"/>
+ <enum name="GL_VERTEX_BINDING_OFFSET"/>
+ <enum name="GL_VERTEX_BINDING_STRIDE"/>
+ <enum name="GL_MAX_VERTEX_ATTRIB_RELATIVE_OFFSET"/>
+ <enum name="GL_MAX_VERTEX_ATTRIB_BINDINGS"/>
+ <command name="glBindVertexBuffer"/>
+ <command name="glVertexAttribFormat"/>
+ <command name="glVertexAttribIFormat"/>
+ <command name="glVertexAttribLFormat"/>
+ <command name="glVertexAttribBinding"/>
+ <command name="glVertexBindingDivisor"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_vertex_blend" supported="gl">
+ <require>
+ <enum name="GL_MAX_VERTEX_UNITS_ARB"/>
+ <enum name="GL_ACTIVE_VERTEX_UNITS_ARB"/>
+ <enum name="GL_WEIGHT_SUM_UNITY_ARB"/>
+ <enum name="GL_VERTEX_BLEND_ARB"/>
+ <enum name="GL_CURRENT_WEIGHT_ARB"/>
+ <enum name="GL_WEIGHT_ARRAY_TYPE_ARB"/>
+ <enum name="GL_WEIGHT_ARRAY_STRIDE_ARB"/>
+ <enum name="GL_WEIGHT_ARRAY_SIZE_ARB"/>
+ <enum name="GL_WEIGHT_ARRAY_POINTER_ARB"/>
+ <enum name="GL_WEIGHT_ARRAY_ARB"/>
+ <enum name="GL_MODELVIEW0_ARB"/>
+ <enum name="GL_MODELVIEW1_ARB"/>
+ <enum name="GL_MODELVIEW2_ARB"/>
+ <enum name="GL_MODELVIEW3_ARB"/>
+ <enum name="GL_MODELVIEW4_ARB"/>
+ <enum name="GL_MODELVIEW5_ARB"/>
+ <enum name="GL_MODELVIEW6_ARB"/>
+ <enum name="GL_MODELVIEW7_ARB"/>
+ <enum name="GL_MODELVIEW8_ARB"/>
+ <enum name="GL_MODELVIEW9_ARB"/>
+ <enum name="GL_MODELVIEW10_ARB"/>
+ <enum name="GL_MODELVIEW11_ARB"/>
+ <enum name="GL_MODELVIEW12_ARB"/>
+ <enum name="GL_MODELVIEW13_ARB"/>
+ <enum name="GL_MODELVIEW14_ARB"/>
+ <enum name="GL_MODELVIEW15_ARB"/>
+ <enum name="GL_MODELVIEW16_ARB"/>
+ <enum name="GL_MODELVIEW17_ARB"/>
+ <enum name="GL_MODELVIEW18_ARB"/>
+ <enum name="GL_MODELVIEW19_ARB"/>
+ <enum name="GL_MODELVIEW20_ARB"/>
+ <enum name="GL_MODELVIEW21_ARB"/>
+ <enum name="GL_MODELVIEW22_ARB"/>
+ <enum name="GL_MODELVIEW23_ARB"/>
+ <enum name="GL_MODELVIEW24_ARB"/>
+ <enum name="GL_MODELVIEW25_ARB"/>
+ <enum name="GL_MODELVIEW26_ARB"/>
+ <enum name="GL_MODELVIEW27_ARB"/>
+ <enum name="GL_MODELVIEW28_ARB"/>
+ <enum name="GL_MODELVIEW29_ARB"/>
+ <enum name="GL_MODELVIEW30_ARB"/>
+ <enum name="GL_MODELVIEW31_ARB"/>
+ <command name="glWeightbvARB"/>
+ <command name="glWeightsvARB"/>
+ <command name="glWeightivARB"/>
+ <command name="glWeightfvARB"/>
+ <command name="glWeightdvARB"/>
+ <command name="glWeightubvARB"/>
+ <command name="glWeightusvARB"/>
+ <command name="glWeightuivARB"/>
+ <command name="glWeightPointerARB"/>
+ <command name="glVertexBlendARB"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_vertex_buffer_object" supported="gl">
+ <require>
+ <enum name="GL_BUFFER_SIZE_ARB"/>
+ <enum name="GL_BUFFER_USAGE_ARB"/>
+ <enum name="GL_ARRAY_BUFFER_ARB"/>
+ <enum name="GL_ELEMENT_ARRAY_BUFFER_ARB"/>
+ <enum name="GL_ARRAY_BUFFER_BINDING_ARB"/>
+ <enum name="GL_ELEMENT_ARRAY_BUFFER_BINDING_ARB"/>
+ <enum name="GL_VERTEX_ARRAY_BUFFER_BINDING_ARB"/>
+ <enum name="GL_NORMAL_ARRAY_BUFFER_BINDING_ARB"/>
+ <enum name="GL_COLOR_ARRAY_BUFFER_BINDING_ARB"/>
+ <enum name="GL_INDEX_ARRAY_BUFFER_BINDING_ARB"/>
+ <enum name="GL_TEXTURE_COORD_ARRAY_BUFFER_BINDING_ARB"/>
+ <enum name="GL_EDGE_FLAG_ARRAY_BUFFER_BINDING_ARB"/>
+ <enum name="GL_SECONDARY_COLOR_ARRAY_BUFFER_BINDING_ARB"/>
+ <enum name="GL_FOG_COORDINATE_ARRAY_BUFFER_BINDING_ARB"/>
+ <enum name="GL_WEIGHT_ARRAY_BUFFER_BINDING_ARB"/>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY_BUFFER_BINDING_ARB"/>
+ <enum name="GL_READ_ONLY_ARB"/>
+ <enum name="GL_WRITE_ONLY_ARB"/>
+ <enum name="GL_READ_WRITE_ARB"/>
+ <enum name="GL_BUFFER_ACCESS_ARB"/>
+ <enum name="GL_BUFFER_MAPPED_ARB"/>
+ <enum name="GL_BUFFER_MAP_POINTER_ARB"/>
+ <enum name="GL_STREAM_DRAW_ARB"/>
+ <enum name="GL_STREAM_READ_ARB"/>
+ <enum name="GL_STREAM_COPY_ARB"/>
+ <enum name="GL_STATIC_DRAW_ARB"/>
+ <enum name="GL_STATIC_READ_ARB"/>
+ <enum name="GL_STATIC_COPY_ARB"/>
+ <enum name="GL_DYNAMIC_DRAW_ARB"/>
+ <enum name="GL_DYNAMIC_READ_ARB"/>
+ <enum name="GL_DYNAMIC_COPY_ARB"/>
+ <command name="glBindBufferARB"/>
+ <command name="glDeleteBuffersARB"/>
+ <command name="glGenBuffersARB"/>
+ <command name="glIsBufferARB"/>
+ <command name="glBufferDataARB"/>
+ <command name="glBufferSubDataARB"/>
+ <command name="glGetBufferSubDataARB"/>
+ <command name="glMapBufferARB"/>
+ <command name="glUnmapBufferARB"/>
+ <command name="glGetBufferParameterivARB"/>
+ <command name="glGetBufferPointervARB"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_vertex_program" supported="gl">
+ <require>
+ <enum name="GL_COLOR_SUM_ARB"/>
+ <enum name="GL_VERTEX_PROGRAM_ARB"/>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY_ENABLED_ARB"/>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY_SIZE_ARB"/>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY_STRIDE_ARB"/>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY_TYPE_ARB"/>
+ <enum name="GL_CURRENT_VERTEX_ATTRIB_ARB"/>
+ <enum name="GL_PROGRAM_LENGTH_ARB"/>
+ <enum name="GL_PROGRAM_STRING_ARB"/>
+ <enum name="GL_MAX_PROGRAM_MATRIX_STACK_DEPTH_ARB"/>
+ <enum name="GL_MAX_PROGRAM_MATRICES_ARB"/>
+ <enum name="GL_CURRENT_MATRIX_STACK_DEPTH_ARB"/>
+ <enum name="GL_CURRENT_MATRIX_ARB"/>
+ <enum name="GL_VERTEX_PROGRAM_POINT_SIZE_ARB"/>
+ <enum name="GL_VERTEX_PROGRAM_TWO_SIDE_ARB"/>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY_POINTER_ARB"/>
+ <enum name="GL_PROGRAM_ERROR_POSITION_ARB"/>
+ <enum name="GL_PROGRAM_BINDING_ARB"/>
+ <enum name="GL_MAX_VERTEX_ATTRIBS_ARB"/>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY_NORMALIZED_ARB"/>
+ <enum name="GL_PROGRAM_ERROR_STRING_ARB"/>
+ <enum name="GL_PROGRAM_FORMAT_ASCII_ARB"/>
+ <enum name="GL_PROGRAM_FORMAT_ARB"/>
+ <enum name="GL_PROGRAM_INSTRUCTIONS_ARB"/>
+ <enum name="GL_MAX_PROGRAM_INSTRUCTIONS_ARB"/>
+ <enum name="GL_PROGRAM_NATIVE_INSTRUCTIONS_ARB"/>
+ <enum name="GL_MAX_PROGRAM_NATIVE_INSTRUCTIONS_ARB"/>
+ <enum name="GL_PROGRAM_TEMPORARIES_ARB"/>
+ <enum name="GL_MAX_PROGRAM_TEMPORARIES_ARB"/>
+ <enum name="GL_PROGRAM_NATIVE_TEMPORARIES_ARB"/>
+ <enum name="GL_MAX_PROGRAM_NATIVE_TEMPORARIES_ARB"/>
+ <enum name="GL_PROGRAM_PARAMETERS_ARB"/>
+ <enum name="GL_MAX_PROGRAM_PARAMETERS_ARB"/>
+ <enum name="GL_PROGRAM_NATIVE_PARAMETERS_ARB"/>
+ <enum name="GL_MAX_PROGRAM_NATIVE_PARAMETERS_ARB"/>
+ <enum name="GL_PROGRAM_ATTRIBS_ARB"/>
+ <enum name="GL_MAX_PROGRAM_ATTRIBS_ARB"/>
+ <enum name="GL_PROGRAM_NATIVE_ATTRIBS_ARB"/>
+ <enum name="GL_MAX_PROGRAM_NATIVE_ATTRIBS_ARB"/>
+ <enum name="GL_PROGRAM_ADDRESS_REGISTERS_ARB"/>
+ <enum name="GL_MAX_PROGRAM_ADDRESS_REGISTERS_ARB"/>
+ <enum name="GL_PROGRAM_NATIVE_ADDRESS_REGISTERS_ARB"/>
+ <enum name="GL_MAX_PROGRAM_NATIVE_ADDRESS_REGISTERS_ARB"/>
+ <enum name="GL_MAX_PROGRAM_LOCAL_PARAMETERS_ARB"/>
+ <enum name="GL_MAX_PROGRAM_ENV_PARAMETERS_ARB"/>
+ <enum name="GL_PROGRAM_UNDER_NATIVE_LIMITS_ARB"/>
+ <enum name="GL_TRANSPOSE_CURRENT_MATRIX_ARB"/>
+ <enum name="GL_MATRIX0_ARB"/>
+ <enum name="GL_MATRIX1_ARB"/>
+ <enum name="GL_MATRIX2_ARB"/>
+ <enum name="GL_MATRIX3_ARB"/>
+ <enum name="GL_MATRIX4_ARB"/>
+ <enum name="GL_MATRIX5_ARB"/>
+ <enum name="GL_MATRIX6_ARB"/>
+ <enum name="GL_MATRIX7_ARB"/>
+ <enum name="GL_MATRIX8_ARB"/>
+ <enum name="GL_MATRIX9_ARB"/>
+ <enum name="GL_MATRIX10_ARB"/>
+ <enum name="GL_MATRIX11_ARB"/>
+ <enum name="GL_MATRIX12_ARB"/>
+ <enum name="GL_MATRIX13_ARB"/>
+ <enum name="GL_MATRIX14_ARB"/>
+ <enum name="GL_MATRIX15_ARB"/>
+ <enum name="GL_MATRIX16_ARB"/>
+ <enum name="GL_MATRIX17_ARB"/>
+ <enum name="GL_MATRIX18_ARB"/>
+ <enum name="GL_MATRIX19_ARB"/>
+ <enum name="GL_MATRIX20_ARB"/>
+ <enum name="GL_MATRIX21_ARB"/>
+ <enum name="GL_MATRIX22_ARB"/>
+ <enum name="GL_MATRIX23_ARB"/>
+ <enum name="GL_MATRIX24_ARB"/>
+ <enum name="GL_MATRIX25_ARB"/>
+ <enum name="GL_MATRIX26_ARB"/>
+ <enum name="GL_MATRIX27_ARB"/>
+ <enum name="GL_MATRIX28_ARB"/>
+ <enum name="GL_MATRIX29_ARB"/>
+ <enum name="GL_MATRIX30_ARB"/>
+ <enum name="GL_MATRIX31_ARB"/>
+ <command name="glVertexAttrib1dARB"/>
+ <command name="glVertexAttrib1dvARB"/>
+ <command name="glVertexAttrib1fARB"/>
+ <command name="glVertexAttrib1fvARB"/>
+ <command name="glVertexAttrib1sARB"/>
+ <command name="glVertexAttrib1svARB"/>
+ <command name="glVertexAttrib2dARB"/>
+ <command name="glVertexAttrib2dvARB"/>
+ <command name="glVertexAttrib2fARB"/>
+ <command name="glVertexAttrib2fvARB"/>
+ <command name="glVertexAttrib2sARB"/>
+ <command name="glVertexAttrib2svARB"/>
+ <command name="glVertexAttrib3dARB"/>
+ <command name="glVertexAttrib3dvARB"/>
+ <command name="glVertexAttrib3fARB"/>
+ <command name="glVertexAttrib3fvARB"/>
+ <command name="glVertexAttrib3sARB"/>
+ <command name="glVertexAttrib3svARB"/>
+ <command name="glVertexAttrib4NbvARB"/>
+ <command name="glVertexAttrib4NivARB"/>
+ <command name="glVertexAttrib4NsvARB"/>
+ <command name="glVertexAttrib4NubARB"/>
+ <command name="glVertexAttrib4NubvARB"/>
+ <command name="glVertexAttrib4NuivARB"/>
+ <command name="glVertexAttrib4NusvARB"/>
+ <command name="glVertexAttrib4bvARB"/>
+ <command name="glVertexAttrib4dARB"/>
+ <command name="glVertexAttrib4dvARB"/>
+ <command name="glVertexAttrib4fARB"/>
+ <command name="glVertexAttrib4fvARB"/>
+ <command name="glVertexAttrib4ivARB"/>
+ <command name="glVertexAttrib4sARB"/>
+ <command name="glVertexAttrib4svARB"/>
+ <command name="glVertexAttrib4ubvARB"/>
+ <command name="glVertexAttrib4uivARB"/>
+ <command name="glVertexAttrib4usvARB"/>
+ <command name="glVertexAttribPointerARB"/>
+ <command name="glEnableVertexAttribArrayARB"/>
+ <command name="glDisableVertexAttribArrayARB"/>
+ <command name="glProgramStringARB"/>
+ <command name="glBindProgramARB"/>
+ <command name="glDeleteProgramsARB"/>
+ <command name="glGenProgramsARB"/>
+ <command name="glProgramEnvParameter4dARB"/>
+ <command name="glProgramEnvParameter4dvARB"/>
+ <command name="glProgramEnvParameter4fARB"/>
+ <command name="glProgramEnvParameter4fvARB"/>
+ <command name="glProgramLocalParameter4dARB"/>
+ <command name="glProgramLocalParameter4dvARB"/>
+ <command name="glProgramLocalParameter4fARB"/>
+ <command name="glProgramLocalParameter4fvARB"/>
+ <command name="glGetProgramEnvParameterdvARB"/>
+ <command name="glGetProgramEnvParameterfvARB"/>
+ <command name="glGetProgramLocalParameterdvARB"/>
+ <command name="glGetProgramLocalParameterfvARB"/>
+ <command name="glGetProgramivARB"/>
+ <command name="glGetProgramStringARB"/>
+ <command name="glGetVertexAttribdvARB"/>
+ <command name="glGetVertexAttribfvARB"/>
+ <command name="glGetVertexAttribivARB"/>
+ <command name="glGetVertexAttribPointervARB"/>
+ <command name="glIsProgramARB"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_vertex_shader" supported="gl">
+ <require>
+ <enum name="GL_VERTEX_SHADER_ARB"/>
+ <enum name="GL_MAX_VERTEX_UNIFORM_COMPONENTS_ARB"/>
+ <enum name="GL_MAX_VARYING_FLOATS_ARB"/>
+ <enum name="GL_MAX_VERTEX_TEXTURE_IMAGE_UNITS_ARB"/>
+ <enum name="GL_MAX_COMBINED_TEXTURE_IMAGE_UNITS_ARB"/>
+ <enum name="GL_OBJECT_ACTIVE_ATTRIBUTES_ARB"/>
+ <enum name="GL_OBJECT_ACTIVE_ATTRIBUTE_MAX_LENGTH_ARB"/>
+ <enum name="GL_MAX_VERTEX_ATTRIBS_ARB"/>
+ <enum name="GL_MAX_TEXTURE_IMAGE_UNITS_ARB"/>
+ <enum name="GL_MAX_TEXTURE_COORDS_ARB"/>
+ <enum name="GL_VERTEX_PROGRAM_POINT_SIZE_ARB"/>
+ <enum name="GL_VERTEX_PROGRAM_TWO_SIDE_ARB"/>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY_ENABLED_ARB"/>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY_SIZE_ARB"/>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY_STRIDE_ARB"/>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY_TYPE_ARB"/>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY_NORMALIZED_ARB"/>
+ <enum name="GL_CURRENT_VERTEX_ATTRIB_ARB"/>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY_POINTER_ARB"/>
+ <enum name="GL_FLOAT"/>
+ <enum name="GL_FLOAT_VEC2_ARB"/>
+ <enum name="GL_FLOAT_VEC3_ARB"/>
+ <enum name="GL_FLOAT_VEC4_ARB"/>
+ <enum name="GL_FLOAT_MAT2_ARB"/>
+ <enum name="GL_FLOAT_MAT3_ARB"/>
+ <enum name="GL_FLOAT_MAT4_ARB"/>
+ <command name="glVertexAttrib1fARB"/>
+ <command name="glVertexAttrib1sARB"/>
+ <command name="glVertexAttrib1dARB"/>
+ <command name="glVertexAttrib2fARB"/>
+ <command name="glVertexAttrib2sARB"/>
+ <command name="glVertexAttrib2dARB"/>
+ <command name="glVertexAttrib3fARB"/>
+ <command name="glVertexAttrib3sARB"/>
+ <command name="glVertexAttrib3dARB"/>
+ <command name="glVertexAttrib4fARB"/>
+ <command name="glVertexAttrib4sARB"/>
+ <command name="glVertexAttrib4dARB"/>
+ <command name="glVertexAttrib4NubARB"/>
+ <command name="glVertexAttrib1fvARB"/>
+ <command name="glVertexAttrib1svARB"/>
+ <command name="glVertexAttrib1dvARB"/>
+ <command name="glVertexAttrib2fvARB"/>
+ <command name="glVertexAttrib2svARB"/>
+ <command name="glVertexAttrib2dvARB"/>
+ <command name="glVertexAttrib3fvARB"/>
+ <command name="glVertexAttrib3svARB"/>
+ <command name="glVertexAttrib3dvARB"/>
+ <command name="glVertexAttrib4fvARB"/>
+ <command name="glVertexAttrib4svARB"/>
+ <command name="glVertexAttrib4dvARB"/>
+ <command name="glVertexAttrib4ivARB"/>
+ <command name="glVertexAttrib4bvARB"/>
+ <command name="glVertexAttrib4ubvARB"/>
+ <command name="glVertexAttrib4usvARB"/>
+ <command name="glVertexAttrib4uivARB"/>
+ <command name="glVertexAttrib4NbvARB"/>
+ <command name="glVertexAttrib4NsvARB"/>
+ <command name="glVertexAttrib4NivARB"/>
+ <command name="glVertexAttrib4NubvARB"/>
+ <command name="glVertexAttrib4NusvARB"/>
+ <command name="glVertexAttrib4NuivARB"/>
+ <command name="glVertexAttribPointerARB"/>
+ <command name="glEnableVertexAttribArrayARB"/>
+ <command name="glDisableVertexAttribArrayARB"/>
+ <command name="glBindAttribLocationARB"/>
+ <command name="glGetActiveAttribARB"/>
+ <command name="glGetAttribLocationARB"/>
+ <command name="glGetVertexAttribdvARB"/>
+ <command name="glGetVertexAttribfvARB"/>
+ <command name="glGetVertexAttribivARB"/>
+ <command name="glGetVertexAttribPointervARB"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_vertex_type_10f_11f_11f_rev" supported="gl|glcore">
+ <require>
+ <enum name="GL_UNSIGNED_INT_10F_11F_11F_REV"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_vertex_type_2_10_10_10_rev" supported="gl|glcore">
+ <require>
+ <enum name="GL_UNSIGNED_INT_2_10_10_10_REV"/>
+ <enum name="GL_INT_2_10_10_10_REV"/>
+ <command name="glVertexAttribP1ui"/>
+ <command name="glVertexAttribP1uiv"/>
+ <command name="glVertexAttribP2ui"/>
+ <command name="glVertexAttribP2uiv"/>
+ <command name="glVertexAttribP3ui"/>
+ <command name="glVertexAttribP3uiv"/>
+ <command name="glVertexAttribP4ui"/>
+ <command name="glVertexAttribP4uiv"/>
+ </require>
+ <require api="gl" profile="compatibility">
+ <command name="glVertexP2ui"/>
+ <command name="glVertexP2uiv"/>
+ <command name="glVertexP3ui"/>
+ <command name="glVertexP3uiv"/>
+ <command name="glVertexP4ui"/>
+ <command name="glVertexP4uiv"/>
+ <command name="glTexCoordP1ui"/>
+ <command name="glTexCoordP1uiv"/>
+ <command name="glTexCoordP2ui"/>
+ <command name="glTexCoordP2uiv"/>
+ <command name="glTexCoordP3ui"/>
+ <command name="glTexCoordP3uiv"/>
+ <command name="glTexCoordP4ui"/>
+ <command name="glTexCoordP4uiv"/>
+ <command name="glMultiTexCoordP1ui"/>
+ <command name="glMultiTexCoordP1uiv"/>
+ <command name="glMultiTexCoordP2ui"/>
+ <command name="glMultiTexCoordP2uiv"/>
+ <command name="glMultiTexCoordP3ui"/>
+ <command name="glMultiTexCoordP3uiv"/>
+ <command name="glMultiTexCoordP4ui"/>
+ <command name="glMultiTexCoordP4uiv"/>
+ <command name="glNormalP3ui"/>
+ <command name="glNormalP3uiv"/>
+ <command name="glColorP3ui"/>
+ <command name="glColorP3uiv"/>
+ <command name="glColorP4ui"/>
+ <command name="glColorP4uiv"/>
+ <command name="glSecondaryColorP3ui"/>
+ <command name="glSecondaryColorP3uiv"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_viewport_array" supported="gl|glcore">
+ <require>
+ <enum name="GL_SCISSOR_BOX"/>
+ <enum name="GL_VIEWPORT"/>
+ <enum name="GL_DEPTH_RANGE"/>
+ <enum name="GL_SCISSOR_TEST"/>
+ <enum name="GL_MAX_VIEWPORTS"/>
+ <enum name="GL_VIEWPORT_SUBPIXEL_BITS"/>
+ <enum name="GL_VIEWPORT_BOUNDS_RANGE"/>
+ <enum name="GL_LAYER_PROVOKING_VERTEX"/>
+ <enum name="GL_VIEWPORT_INDEX_PROVOKING_VERTEX"/>
+ <enum name="GL_UNDEFINED_VERTEX"/>
+ <enum name="GL_FIRST_VERTEX_CONVENTION"/>
+ <enum name="GL_LAST_VERTEX_CONVENTION"/>
+ <enum name="GL_PROVOKING_VERTEX"/>
+ <command name="glViewportArrayv"/>
+ <command name="glViewportIndexedf"/>
+ <command name="glViewportIndexedfv"/>
+ <command name="glScissorArrayv"/>
+ <command name="glScissorIndexed"/>
+ <command name="glScissorIndexedv"/>
+ <command name="glDepthRangeArrayv"/>
+ <command name="glDepthRangeIndexed"/>
+ <command name="glGetFloati_v"/>
+ <command name="glGetDoublei_v"/>
+ </require>
+ </extension>
+ <extension name="GL_ARB_window_pos" supported="gl">
+ <require>
+ <command name="glWindowPos2dARB"/>
+ <command name="glWindowPos2dvARB"/>
+ <command name="glWindowPos2fARB"/>
+ <command name="glWindowPos2fvARB"/>
+ <command name="glWindowPos2iARB"/>
+ <command name="glWindowPos2ivARB"/>
+ <command name="glWindowPos2sARB"/>
+ <command name="glWindowPos2svARB"/>
+ <command name="glWindowPos3dARB"/>
+ <command name="glWindowPos3dvARB"/>
+ <command name="glWindowPos3fARB"/>
+ <command name="glWindowPos3fvARB"/>
+ <command name="glWindowPos3iARB"/>
+ <command name="glWindowPos3ivARB"/>
+ <command name="glWindowPos3sARB"/>
+ <command name="glWindowPos3svARB"/>
+ </require>
+ </extension>
+ <extension name="GL_ARM_mali_program_binary" supported="gles2">
+ <require>
+ <enum name="GL_MALI_PROGRAM_BINARY_ARM"/>
+ </require>
+ </extension>
+ <extension name="GL_ARM_mali_shader_binary" supported="gles2">
+ <require>
+ <enum name="GL_MALI_SHADER_BINARY_ARM"/>
+ </require>
+ </extension>
+ <extension name="GL_ARM_rgba8" supported="gles1|gles2"/>
+ <extension name="GL_ARM_shader_framebuffer_fetch" supported="gles2">
+ <require>
+ <enum name="GL_FETCH_PER_SAMPLE_ARM"/>
+ <enum name="GL_FRAGMENT_SHADER_FRAMEBUFFER_FETCH_MRT_ARM"/>
+ </require>
+ </extension>
+ <extension name="GL_ARM_shader_framebuffer_fetch_depth_stencil" supported="gles2"/>
+ <extension name="GL_ATI_draw_buffers" supported="gl">
+ <require>
+ <enum name="GL_MAX_DRAW_BUFFERS_ATI"/>
+ <enum name="GL_DRAW_BUFFER0_ATI"/>
+ <enum name="GL_DRAW_BUFFER1_ATI"/>
+ <enum name="GL_DRAW_BUFFER2_ATI"/>
+ <enum name="GL_DRAW_BUFFER3_ATI"/>
+ <enum name="GL_DRAW_BUFFER4_ATI"/>
+ <enum name="GL_DRAW_BUFFER5_ATI"/>
+ <enum name="GL_DRAW_BUFFER6_ATI"/>
+ <enum name="GL_DRAW_BUFFER7_ATI"/>
+ <enum name="GL_DRAW_BUFFER8_ATI"/>
+ <enum name="GL_DRAW_BUFFER9_ATI"/>
+ <enum name="GL_DRAW_BUFFER10_ATI"/>
+ <enum name="GL_DRAW_BUFFER11_ATI"/>
+ <enum name="GL_DRAW_BUFFER12_ATI"/>
+ <enum name="GL_DRAW_BUFFER13_ATI"/>
+ <enum name="GL_DRAW_BUFFER14_ATI"/>
+ <enum name="GL_DRAW_BUFFER15_ATI"/>
+ <command name="glDrawBuffersATI"/>
+ </require>
+ </extension>
+ <extension name="GL_ATI_element_array" supported="gl">
+ <require>
+ <enum name="GL_ELEMENT_ARRAY_ATI"/>
+ <enum name="GL_ELEMENT_ARRAY_TYPE_ATI"/>
+ <enum name="GL_ELEMENT_ARRAY_POINTER_ATI"/>
+ <command name="glElementPointerATI"/>
+ <command name="glDrawElementArrayATI"/>
+ <command name="glDrawRangeElementArrayATI"/>
+ </require>
+ </extension>
+ <extension name="GL_ATI_envmap_bumpmap" supported="gl">
+ <require>
+ <enum name="GL_BUMP_ROT_MATRIX_ATI"/>
+ <enum name="GL_BUMP_ROT_MATRIX_SIZE_ATI"/>
+ <enum name="GL_BUMP_NUM_TEX_UNITS_ATI"/>
+ <enum name="GL_BUMP_TEX_UNITS_ATI"/>
+ <enum name="GL_DUDV_ATI"/>
+ <enum name="GL_DU8DV8_ATI"/>
+ <enum name="GL_BUMP_ENVMAP_ATI"/>
+ <enum name="GL_BUMP_TARGET_ATI"/>
+ <command name="glTexBumpParameterivATI"/>
+ <command name="glTexBumpParameterfvATI"/>
+ <command name="glGetTexBumpParameterivATI"/>
+ <command name="glGetTexBumpParameterfvATI"/>
+ </require>
+ </extension>
+ <extension name="GL_ATI_fragment_shader" supported="gl">
+ <require>
+ <enum name="GL_FRAGMENT_SHADER_ATI"/>
+ <enum name="GL_REG_0_ATI"/>
+ <enum name="GL_REG_1_ATI"/>
+ <enum name="GL_REG_2_ATI"/>
+ <enum name="GL_REG_3_ATI"/>
+ <enum name="GL_REG_4_ATI"/>
+ <enum name="GL_REG_5_ATI"/>
+ <enum name="GL_REG_6_ATI"/>
+ <enum name="GL_REG_7_ATI"/>
+ <enum name="GL_REG_8_ATI"/>
+ <enum name="GL_REG_9_ATI"/>
+ <enum name="GL_REG_10_ATI"/>
+ <enum name="GL_REG_11_ATI"/>
+ <enum name="GL_REG_12_ATI"/>
+ <enum name="GL_REG_13_ATI"/>
+ <enum name="GL_REG_14_ATI"/>
+ <enum name="GL_REG_15_ATI"/>
+ <enum name="GL_REG_16_ATI"/>
+ <enum name="GL_REG_17_ATI"/>
+ <enum name="GL_REG_18_ATI"/>
+ <enum name="GL_REG_19_ATI"/>
+ <enum name="GL_REG_20_ATI"/>
+ <enum name="GL_REG_21_ATI"/>
+ <enum name="GL_REG_22_ATI"/>
+ <enum name="GL_REG_23_ATI"/>
+ <enum name="GL_REG_24_ATI"/>
+ <enum name="GL_REG_25_ATI"/>
+ <enum name="GL_REG_26_ATI"/>
+ <enum name="GL_REG_27_ATI"/>
+ <enum name="GL_REG_28_ATI"/>
+ <enum name="GL_REG_29_ATI"/>
+ <enum name="GL_REG_30_ATI"/>
+ <enum name="GL_REG_31_ATI"/>
+ <enum name="GL_CON_0_ATI"/>
+ <enum name="GL_CON_1_ATI"/>
+ <enum name="GL_CON_2_ATI"/>
+ <enum name="GL_CON_3_ATI"/>
+ <enum name="GL_CON_4_ATI"/>
+ <enum name="GL_CON_5_ATI"/>
+ <enum name="GL_CON_6_ATI"/>
+ <enum name="GL_CON_7_ATI"/>
+ <enum name="GL_CON_8_ATI"/>
+ <enum name="GL_CON_9_ATI"/>
+ <enum name="GL_CON_10_ATI"/>
+ <enum name="GL_CON_11_ATI"/>
+ <enum name="GL_CON_12_ATI"/>
+ <enum name="GL_CON_13_ATI"/>
+ <enum name="GL_CON_14_ATI"/>
+ <enum name="GL_CON_15_ATI"/>
+ <enum name="GL_CON_16_ATI"/>
+ <enum name="GL_CON_17_ATI"/>
+ <enum name="GL_CON_18_ATI"/>
+ <enum name="GL_CON_19_ATI"/>
+ <enum name="GL_CON_20_ATI"/>
+ <enum name="GL_CON_21_ATI"/>
+ <enum name="GL_CON_22_ATI"/>
+ <enum name="GL_CON_23_ATI"/>
+ <enum name="GL_CON_24_ATI"/>
+ <enum name="GL_CON_25_ATI"/>
+ <enum name="GL_CON_26_ATI"/>
+ <enum name="GL_CON_27_ATI"/>
+ <enum name="GL_CON_28_ATI"/>
+ <enum name="GL_CON_29_ATI"/>
+ <enum name="GL_CON_30_ATI"/>
+ <enum name="GL_CON_31_ATI"/>
+ <enum name="GL_MOV_ATI"/>
+ <enum name="GL_ADD_ATI"/>
+ <enum name="GL_MUL_ATI"/>
+ <enum name="GL_SUB_ATI"/>
+ <enum name="GL_DOT3_ATI"/>
+ <enum name="GL_DOT4_ATI"/>
+ <enum name="GL_MAD_ATI"/>
+ <enum name="GL_LERP_ATI"/>
+ <enum name="GL_CND_ATI"/>
+ <enum name="GL_CND0_ATI"/>
+ <enum name="GL_DOT2_ADD_ATI"/>
+ <enum name="GL_SECONDARY_INTERPOLATOR_ATI"/>
+ <enum name="GL_NUM_FRAGMENT_REGISTERS_ATI"/>
+ <enum name="GL_NUM_FRAGMENT_CONSTANTS_ATI"/>
+ <enum name="GL_NUM_PASSES_ATI"/>
+ <enum name="GL_NUM_INSTRUCTIONS_PER_PASS_ATI"/>
+ <enum name="GL_NUM_INSTRUCTIONS_TOTAL_ATI"/>
+ <enum name="GL_NUM_INPUT_INTERPOLATOR_COMPONENTS_ATI"/>
+ <enum name="GL_NUM_LOOPBACK_COMPONENTS_ATI"/>
+ <enum name="GL_COLOR_ALPHA_PAIRING_ATI"/>
+ <enum name="GL_SWIZZLE_STR_ATI"/>
+ <enum name="GL_SWIZZLE_STQ_ATI"/>
+ <enum name="GL_SWIZZLE_STR_DR_ATI"/>
+ <enum name="GL_SWIZZLE_STQ_DQ_ATI"/>
+ <enum name="GL_SWIZZLE_STRQ_ATI"/>
+ <enum name="GL_SWIZZLE_STRQ_DQ_ATI"/>
+ <enum name="GL_RED_BIT_ATI"/>
+ <enum name="GL_GREEN_BIT_ATI"/>
+ <enum name="GL_BLUE_BIT_ATI"/>
+ <enum name="GL_2X_BIT_ATI"/>
+ <enum name="GL_4X_BIT_ATI"/>
+ <enum name="GL_8X_BIT_ATI"/>
+ <enum name="GL_HALF_BIT_ATI"/>
+ <enum name="GL_QUARTER_BIT_ATI"/>
+ <enum name="GL_EIGHTH_BIT_ATI"/>
+ <enum name="GL_SATURATE_BIT_ATI"/>
+ <enum name="GL_COMP_BIT_ATI"/>
+ <enum name="GL_NEGATE_BIT_ATI"/>
+ <enum name="GL_BIAS_BIT_ATI"/>
+ <command name="glGenFragmentShadersATI"/>
+ <command name="glBindFragmentShaderATI"/>
+ <command name="glDeleteFragmentShaderATI"/>
+ <command name="glBeginFragmentShaderATI"/>
+ <command name="glEndFragmentShaderATI"/>
+ <command name="glPassTexCoordATI"/>
+ <command name="glSampleMapATI"/>
+ <command name="glColorFragmentOp1ATI"/>
+ <command name="glColorFragmentOp2ATI"/>
+ <command name="glColorFragmentOp3ATI"/>
+ <command name="glAlphaFragmentOp1ATI"/>
+ <command name="glAlphaFragmentOp2ATI"/>
+ <command name="glAlphaFragmentOp3ATI"/>
+ <command name="glSetFragmentShaderConstantATI"/>
+ </require>
+ </extension>
+ <extension name="GL_ATI_map_object_buffer" supported="gl">
+ <require>
+ <command name="glMapObjectBufferATI"/>
+ <command name="glUnmapObjectBufferATI"/>
+ </require>
+ </extension>
+ <extension name="GL_ATI_meminfo" supported="gl">
+ <require>
+ <enum name="GL_VBO_FREE_MEMORY_ATI"/>
+ <enum name="GL_TEXTURE_FREE_MEMORY_ATI"/>
+ <enum name="GL_RENDERBUFFER_FREE_MEMORY_ATI"/>
+ </require>
+ </extension>
+ <extension name="GL_ATI_pixel_format_float" supported="gl" comment="WGL extension defining some associated GL enums. ATI does not export this extension.">
+ <require>
+ <enum name="GL_RGBA_FLOAT_MODE_ATI"/>
+ <enum name="GL_COLOR_CLEAR_UNCLAMPED_VALUE_ATI"/>
+ </require>
+ </extension>
+ <extension name="GL_ATI_pn_triangles" supported="gl">
+ <require>
+ <enum name="GL_PN_TRIANGLES_ATI"/>
+ <enum name="GL_MAX_PN_TRIANGLES_TESSELATION_LEVEL_ATI"/>
+ <enum name="GL_PN_TRIANGLES_POINT_MODE_ATI"/>
+ <enum name="GL_PN_TRIANGLES_NORMAL_MODE_ATI"/>
+ <enum name="GL_PN_TRIANGLES_TESSELATION_LEVEL_ATI"/>
+ <enum name="GL_PN_TRIANGLES_POINT_MODE_LINEAR_ATI"/>
+ <enum name="GL_PN_TRIANGLES_POINT_MODE_CUBIC_ATI"/>
+ <enum name="GL_PN_TRIANGLES_NORMAL_MODE_LINEAR_ATI"/>
+ <enum name="GL_PN_TRIANGLES_NORMAL_MODE_QUADRATIC_ATI"/>
+ <command name="glPNTrianglesiATI"/>
+ <command name="glPNTrianglesfATI"/>
+ </require>
+ </extension>
+ <extension name="GL_ATI_separate_stencil" supported="gl">
+ <require>
+ <enum name="GL_STENCIL_BACK_FUNC_ATI"/>
+ <enum name="GL_STENCIL_BACK_FAIL_ATI"/>
+ <enum name="GL_STENCIL_BACK_PASS_DEPTH_FAIL_ATI"/>
+ <enum name="GL_STENCIL_BACK_PASS_DEPTH_PASS_ATI"/>
+ <command name="glStencilOpSeparateATI"/>
+ <command name="glStencilFuncSeparateATI"/>
+ </require>
+ </extension>
+ <extension name="GL_ATI_text_fragment_shader" supported="gl">
+ <require>
+ <enum name="GL_TEXT_FRAGMENT_SHADER_ATI"/>
+ </require>
+ </extension>
+ <extension name="GL_ATI_texture_env_combine3" supported="gl">
+ <require>
+ <enum name="GL_MODULATE_ADD_ATI"/>
+ <enum name="GL_MODULATE_SIGNED_ADD_ATI"/>
+ <enum name="GL_MODULATE_SUBTRACT_ATI"/>
+ </require>
+ </extension>
+ <extension name="GL_ATI_texture_float" supported="gl">
+ <require>
+ <enum name="GL_RGBA_FLOAT32_ATI"/>
+ <enum name="GL_RGB_FLOAT32_ATI"/>
+ <enum name="GL_ALPHA_FLOAT32_ATI"/>
+ <enum name="GL_INTENSITY_FLOAT32_ATI"/>
+ <enum name="GL_LUMINANCE_FLOAT32_ATI"/>
+ <enum name="GL_LUMINANCE_ALPHA_FLOAT32_ATI"/>
+ <enum name="GL_RGBA_FLOAT16_ATI"/>
+ <enum name="GL_RGB_FLOAT16_ATI"/>
+ <enum name="GL_ALPHA_FLOAT16_ATI"/>
+ <enum name="GL_INTENSITY_FLOAT16_ATI"/>
+ <enum name="GL_LUMINANCE_FLOAT16_ATI"/>
+ <enum name="GL_LUMINANCE_ALPHA_FLOAT16_ATI"/>
+ </require>
+ </extension>
+ <extension name="GL_ATI_texture_mirror_once" supported="gl">
+ <require>
+ <enum name="GL_MIRROR_CLAMP_ATI"/>
+ <enum name="GL_MIRROR_CLAMP_TO_EDGE_ATI"/>
+ </require>
+ </extension>
+ <extension name="GL_ATI_vertex_array_object" supported="gl">
+ <require>
+ <enum name="GL_STATIC_ATI"/>
+ <enum name="GL_DYNAMIC_ATI"/>
+ <enum name="GL_PRESERVE_ATI"/>
+ <enum name="GL_DISCARD_ATI"/>
+ <enum name="GL_OBJECT_BUFFER_SIZE_ATI"/>
+ <enum name="GL_OBJECT_BUFFER_USAGE_ATI"/>
+ <enum name="GL_ARRAY_OBJECT_BUFFER_ATI"/>
+ <enum name="GL_ARRAY_OBJECT_OFFSET_ATI"/>
+ <command name="glNewObjectBufferATI"/>
+ <command name="glIsObjectBufferATI"/>
+ <command name="glUpdateObjectBufferATI"/>
+ <command name="glGetObjectBufferfvATI"/>
+ <command name="glGetObjectBufferivATI"/>
+ <command name="glFreeObjectBufferATI"/>
+ <command name="glArrayObjectATI"/>
+ <command name="glGetArrayObjectfvATI"/>
+ <command name="glGetArrayObjectivATI"/>
+ <command name="glVariantArrayObjectATI"/>
+ <command name="glGetVariantArrayObjectfvATI"/>
+ <command name="glGetVariantArrayObjectivATI"/>
+ </require>
+ </extension>
+ <extension name="GL_ATI_vertex_attrib_array_object" supported="gl">
+ <require>
+ <command name="glVertexAttribArrayObjectATI"/>
+ <command name="glGetVertexAttribArrayObjectfvATI"/>
+ <command name="glGetVertexAttribArrayObjectivATI"/>
+ </require>
+ </extension>
+ <extension name="GL_ATI_vertex_streams" supported="gl">
+ <require>
+ <enum name="GL_MAX_VERTEX_STREAMS_ATI"/>
+ <enum name="GL_VERTEX_STREAM0_ATI"/>
+ <enum name="GL_VERTEX_STREAM1_ATI"/>
+ <enum name="GL_VERTEX_STREAM2_ATI"/>
+ <enum name="GL_VERTEX_STREAM3_ATI"/>
+ <enum name="GL_VERTEX_STREAM4_ATI"/>
+ <enum name="GL_VERTEX_STREAM5_ATI"/>
+ <enum name="GL_VERTEX_STREAM6_ATI"/>
+ <enum name="GL_VERTEX_STREAM7_ATI"/>
+ <enum name="GL_VERTEX_SOURCE_ATI"/>
+ <command name="glVertexStream1sATI"/>
+ <command name="glVertexStream1svATI"/>
+ <command name="glVertexStream1iATI"/>
+ <command name="glVertexStream1ivATI"/>
+ <command name="glVertexStream1fATI"/>
+ <command name="glVertexStream1fvATI"/>
+ <command name="glVertexStream1dATI"/>
+ <command name="glVertexStream1dvATI"/>
+ <command name="glVertexStream2sATI"/>
+ <command name="glVertexStream2svATI"/>
+ <command name="glVertexStream2iATI"/>
+ <command name="glVertexStream2ivATI"/>
+ <command name="glVertexStream2fATI"/>
+ <command name="glVertexStream2fvATI"/>
+ <command name="glVertexStream2dATI"/>
+ <command name="glVertexStream2dvATI"/>
+ <command name="glVertexStream3sATI"/>
+ <command name="glVertexStream3svATI"/>
+ <command name="glVertexStream3iATI"/>
+ <command name="glVertexStream3ivATI"/>
+ <command name="glVertexStream3fATI"/>
+ <command name="glVertexStream3fvATI"/>
+ <command name="glVertexStream3dATI"/>
+ <command name="glVertexStream3dvATI"/>
+ <command name="glVertexStream4sATI"/>
+ <command name="glVertexStream4svATI"/>
+ <command name="glVertexStream4iATI"/>
+ <command name="glVertexStream4ivATI"/>
+ <command name="glVertexStream4fATI"/>
+ <command name="glVertexStream4fvATI"/>
+ <command name="glVertexStream4dATI"/>
+ <command name="glVertexStream4dvATI"/>
+ <command name="glNormalStream3bATI"/>
+ <command name="glNormalStream3bvATI"/>
+ <command name="glNormalStream3sATI"/>
+ <command name="glNormalStream3svATI"/>
+ <command name="glNormalStream3iATI"/>
+ <command name="glNormalStream3ivATI"/>
+ <command name="glNormalStream3fATI"/>
+ <command name="glNormalStream3fvATI"/>
+ <command name="glNormalStream3dATI"/>
+ <command name="glNormalStream3dvATI"/>
+ <command name="glClientActiveVertexStreamATI"/>
+ <command name="glVertexBlendEnviATI"/>
+ <command name="glVertexBlendEnvfATI"/>
+ </require>
+ </extension>
+ <extension name="GL_DMP_shader_binary" supported="gles2">
+ <require>
+ <enum name="GL_SHADER_BINARY_DMP"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_422_pixels" supported="gl">
+ <require>
+ <enum name="GL_422_EXT"/>
+ <enum name="GL_422_REV_EXT"/>
+ <enum name="GL_422_AVERAGE_EXT"/>
+ <enum name="GL_422_REV_AVERAGE_EXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_abgr" supported="gl">
+ <require>
+ <enum name="GL_ABGR_EXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_bgra" supported="gl">
+ <require>
+ <enum name="GL_BGR_EXT"/>
+ <enum name="GL_BGRA_EXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_bindable_uniform" supported="gl">
+ <require>
+ <enum name="GL_MAX_VERTEX_BINDABLE_UNIFORMS_EXT"/>
+ <enum name="GL_MAX_FRAGMENT_BINDABLE_UNIFORMS_EXT"/>
+ <enum name="GL_MAX_GEOMETRY_BINDABLE_UNIFORMS_EXT"/>
+ <enum name="GL_MAX_BINDABLE_UNIFORM_SIZE_EXT"/>
+ <enum name="GL_UNIFORM_BUFFER_EXT"/>
+ <enum name="GL_UNIFORM_BUFFER_BINDING_EXT"/>
+ <command name="glUniformBufferEXT"/>
+ <command name="glGetUniformBufferSizeEXT"/>
+ <command name="glGetUniformOffsetEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_blend_color" supported="gl">
+ <require>
+ <enum name="GL_CONSTANT_COLOR_EXT"/>
+ <enum name="GL_ONE_MINUS_CONSTANT_COLOR_EXT"/>
+ <enum name="GL_CONSTANT_ALPHA_EXT"/>
+ <enum name="GL_ONE_MINUS_CONSTANT_ALPHA_EXT"/>
+ <enum name="GL_BLEND_COLOR_EXT"/>
+ <command name="glBlendColorEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_blend_equation_separate" supported="gl">
+ <require>
+ <enum name="GL_BLEND_EQUATION_RGB_EXT"/>
+ <enum name="GL_BLEND_EQUATION_ALPHA_EXT"/>
+ <command name="glBlendEquationSeparateEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_blend_func_separate" supported="gl">
+ <require>
+ <enum name="GL_BLEND_DST_RGB_EXT"/>
+ <enum name="GL_BLEND_SRC_RGB_EXT"/>
+ <enum name="GL_BLEND_DST_ALPHA_EXT"/>
+ <enum name="GL_BLEND_SRC_ALPHA_EXT"/>
+ <command name="glBlendFuncSeparateEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_blend_logic_op" supported="gl"/>
+ <extension name="GL_EXT_blend_minmax" supported="gl|gles1|gles2">
+ <require>
+ <enum name="GL_MIN_EXT"/>
+ <enum name="GL_MAX_EXT"/>
+ </require>
+ <require api="gl">
+ <enum name="GL_FUNC_ADD_EXT"/>
+ <enum name="GL_BLEND_EQUATION_EXT"/>
+ <command name="glBlendEquationEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_blend_subtract" supported="gl">
+ <require>
+ <enum name="GL_FUNC_SUBTRACT_EXT"/>
+ <enum name="GL_FUNC_REVERSE_SUBTRACT_EXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_clip_volume_hint" supported="gl">
+ <require>
+ <enum name="GL_CLIP_VOLUME_CLIPPING_HINT_EXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_cmyka" supported="gl">
+ <require>
+ <enum name="GL_CMYK_EXT"/>
+ <enum name="GL_CMYKA_EXT"/>
+ <enum name="GL_PACK_CMYK_HINT_EXT"/>
+ <enum name="GL_UNPACK_CMYK_HINT_EXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_color_buffer_half_float" supported="gles2">
+ <require>
+ <enum name="GL_RGBA16F_EXT"/>
+ <enum name="GL_RGB16F_EXT"/>
+ <enum name="GL_RG16F_EXT"/>
+ <enum name="GL_R16F_EXT"/>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE_EXT"/>
+ <enum name="GL_UNSIGNED_NORMALIZED_EXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_color_subtable" supported="gl">
+ <require>
+ <command name="glColorSubTableEXT"/>
+ <command name="glCopyColorSubTableEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_compiled_vertex_array" supported="gl">
+ <require>
+ <enum name="GL_ARRAY_ELEMENT_LOCK_FIRST_EXT"/>
+ <enum name="GL_ARRAY_ELEMENT_LOCK_COUNT_EXT"/>
+ <command name="glLockArraysEXT"/>
+ <command name="glUnlockArraysEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_convolution" supported="gl">
+ <require>
+ <enum name="GL_CONVOLUTION_1D_EXT"/>
+ <enum name="GL_CONVOLUTION_2D_EXT"/>
+ <enum name="GL_SEPARABLE_2D_EXT"/>
+ <enum name="GL_CONVOLUTION_BORDER_MODE_EXT"/>
+ <enum name="GL_CONVOLUTION_FILTER_SCALE_EXT"/>
+ <enum name="GL_CONVOLUTION_FILTER_BIAS_EXT"/>
+ <enum name="GL_REDUCE_EXT"/>
+ <enum name="GL_CONVOLUTION_FORMAT_EXT"/>
+ <enum name="GL_CONVOLUTION_WIDTH_EXT"/>
+ <enum name="GL_CONVOLUTION_HEIGHT_EXT"/>
+ <enum name="GL_MAX_CONVOLUTION_WIDTH_EXT"/>
+ <enum name="GL_MAX_CONVOLUTION_HEIGHT_EXT"/>
+ <enum name="GL_POST_CONVOLUTION_RED_SCALE_EXT"/>
+ <enum name="GL_POST_CONVOLUTION_GREEN_SCALE_EXT"/>
+ <enum name="GL_POST_CONVOLUTION_BLUE_SCALE_EXT"/>
+ <enum name="GL_POST_CONVOLUTION_ALPHA_SCALE_EXT"/>
+ <enum name="GL_POST_CONVOLUTION_RED_BIAS_EXT"/>
+ <enum name="GL_POST_CONVOLUTION_GREEN_BIAS_EXT"/>
+ <enum name="GL_POST_CONVOLUTION_BLUE_BIAS_EXT"/>
+ <enum name="GL_POST_CONVOLUTION_ALPHA_BIAS_EXT"/>
+ <command name="glConvolutionFilter1DEXT"/>
+ <command name="glConvolutionFilter2DEXT"/>
+ <command name="glConvolutionParameterfEXT"/>
+ <command name="glConvolutionParameterfvEXT"/>
+ <command name="glConvolutionParameteriEXT"/>
+ <command name="glConvolutionParameterivEXT"/>
+ <command name="glCopyConvolutionFilter1DEXT"/>
+ <command name="glCopyConvolutionFilter2DEXT"/>
+ <command name="glGetConvolutionFilterEXT"/>
+ <command name="glGetConvolutionParameterfvEXT"/>
+ <command name="glGetConvolutionParameterivEXT"/>
+ <command name="glGetSeparableFilterEXT"/>
+ <command name="glSeparableFilter2DEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_coordinate_frame" supported="gl">
+ <require>
+ <enum name="GL_TANGENT_ARRAY_EXT"/>
+ <enum name="GL_BINORMAL_ARRAY_EXT"/>
+ <enum name="GL_CURRENT_TANGENT_EXT"/>
+ <enum name="GL_CURRENT_BINORMAL_EXT"/>
+ <enum name="GL_TANGENT_ARRAY_TYPE_EXT"/>
+ <enum name="GL_TANGENT_ARRAY_STRIDE_EXT"/>
+ <enum name="GL_BINORMAL_ARRAY_TYPE_EXT"/>
+ <enum name="GL_BINORMAL_ARRAY_STRIDE_EXT"/>
+ <enum name="GL_TANGENT_ARRAY_POINTER_EXT"/>
+ <enum name="GL_BINORMAL_ARRAY_POINTER_EXT"/>
+ <enum name="GL_MAP1_TANGENT_EXT"/>
+ <enum name="GL_MAP2_TANGENT_EXT"/>
+ <enum name="GL_MAP1_BINORMAL_EXT"/>
+ <enum name="GL_MAP2_BINORMAL_EXT"/>
+ <command name="glTangent3bEXT"/>
+ <command name="glTangent3bvEXT"/>
+ <command name="glTangent3dEXT"/>
+ <command name="glTangent3dvEXT"/>
+ <command name="glTangent3fEXT"/>
+ <command name="glTangent3fvEXT"/>
+ <command name="glTangent3iEXT"/>
+ <command name="glTangent3ivEXT"/>
+ <command name="glTangent3sEXT"/>
+ <command name="glTangent3svEXT"/>
+ <command name="glBinormal3bEXT"/>
+ <command name="glBinormal3bvEXT"/>
+ <command name="glBinormal3dEXT"/>
+ <command name="glBinormal3dvEXT"/>
+ <command name="glBinormal3fEXT"/>
+ <command name="glBinormal3fvEXT"/>
+ <command name="glBinormal3iEXT"/>
+ <command name="glBinormal3ivEXT"/>
+ <command name="glBinormal3sEXT"/>
+ <command name="glBinormal3svEXT"/>
+ <command name="glTangentPointerEXT"/>
+ <command name="glBinormalPointerEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_copy_image" supported="gles2">
+ <require>
+ <command name="glCopyImageSubDataEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_copy_texture" supported="gl">
+ <require>
+ <command name="glCopyTexImage1DEXT"/>
+ <command name="glCopyTexImage2DEXT"/>
+ <command name="glCopyTexSubImage1DEXT"/>
+ <command name="glCopyTexSubImage2DEXT"/>
+ <command name="glCopyTexSubImage3DEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_cull_vertex" supported="gl">
+ <require>
+ <enum name="GL_CULL_VERTEX_EXT"/>
+ <enum name="GL_CULL_VERTEX_EYE_POSITION_EXT"/>
+ <enum name="GL_CULL_VERTEX_OBJECT_POSITION_EXT"/>
+ <command name="glCullParameterdvEXT"/>
+ <command name="glCullParameterfvEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_debug_label" supported="gl|gles2">
+ <require>
+ <enum name="GL_PROGRAM_PIPELINE_OBJECT_EXT"/>
+ <enum name="GL_PROGRAM_OBJECT_EXT"/>
+ <enum name="GL_SHADER_OBJECT_EXT"/>
+ <enum name="GL_BUFFER_OBJECT_EXT"/>
+ <enum name="GL_QUERY_OBJECT_EXT"/>
+ <enum name="GL_VERTEX_ARRAY_OBJECT_EXT"/>
+ <command name="glLabelObjectEXT"/>
+ <command name="glGetObjectLabelEXT"/>
+ </require>
+ <require comment="Depends on OpenGL ES 3.0">
+ <enum name="GL_SAMPLER"/>
+ <enum name="GL_TRANSFORM_FEEDBACK"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_debug_marker" supported="gl|gles2">
+ <require>
+ <command name="glInsertEventMarkerEXT"/>
+ <command name="glPushGroupMarkerEXT"/>
+ <command name="glPopGroupMarkerEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_depth_bounds_test" supported="gl">
+ <require>
+ <enum name="GL_DEPTH_BOUNDS_TEST_EXT"/>
+ <enum name="GL_DEPTH_BOUNDS_EXT"/>
+ <command name="glDepthBoundsEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_direct_state_access" supported="gl" comment="DSA extension doesn't identify which interfaces are core profile and keeps getting expanded. This is in sync with revision 34, 2010/09/07">
+ <require>
+ <enum name="GL_PROGRAM_MATRIX_EXT"/>
+ <enum name="GL_TRANSPOSE_PROGRAM_MATRIX_EXT"/>
+ <enum name="GL_PROGRAM_MATRIX_STACK_DEPTH_EXT"/>
+ </require>
+ <require comment="OpenGL 1.0: New matrix commands">
+ <command name="glMatrixLoadfEXT"/>
+ <command name="glMatrixLoaddEXT"/>
+ <command name="glMatrixMultfEXT"/>
+ <command name="glMatrixMultdEXT"/>
+ <command name="glMatrixLoadIdentityEXT"/>
+ <command name="glMatrixRotatefEXT"/>
+ <command name="glMatrixRotatedEXT"/>
+ <command name="glMatrixScalefEXT"/>
+ <command name="glMatrixScaledEXT"/>
+ <command name="glMatrixTranslatefEXT"/>
+ <command name="glMatrixTranslatedEXT"/>
+ <command name="glMatrixFrustumEXT"/>
+ <command name="glMatrixOrthoEXT"/>
+ <command name="glMatrixPopEXT"/>
+ <command name="glMatrixPushEXT"/>
+ </require>
+ <require comment="OpenGL 1.1: New client commands">
+ <command name="glClientAttribDefaultEXT"/>
+ <command name="glPushClientAttribDefaultEXT"/>
+ </require>
+ <require comment="OpenGL 1.1: New texture object commands">
+ <command name="glTextureParameterfEXT"/>
+ <command name="glTextureParameterfvEXT"/>
+ <command name="glTextureParameteriEXT"/>
+ <command name="glTextureParameterivEXT"/>
+ <command name="glTextureImage1DEXT"/>
+ <command name="glTextureImage2DEXT"/>
+ <command name="glTextureSubImage1DEXT"/>
+ <command name="glTextureSubImage2DEXT"/>
+ <command name="glCopyTextureImage1DEXT"/>
+ <command name="glCopyTextureImage2DEXT"/>
+ <command name="glCopyTextureSubImage1DEXT"/>
+ <command name="glCopyTextureSubImage2DEXT"/>
+ <command name="glGetTextureImageEXT"/>
+ <command name="glGetTextureParameterfvEXT"/>
+ <command name="glGetTextureParameterivEXT"/>
+ <command name="glGetTextureLevelParameterfvEXT"/>
+ <command name="glGetTextureLevelParameterivEXT"/>
+ </require>
+ <require comment="OpenGL 1.2: New 3D texture object commands">
+ <command name="glTextureImage3DEXT"/>
+ <command name="glTextureSubImage3DEXT"/>
+ <command name="glCopyTextureSubImage3DEXT"/>
+ </require>
+ <require comment="OpenGL 1.2.1: New multitexture commands">
+ <command name="glBindMultiTextureEXT"/>
+ <command name="glMultiTexCoordPointerEXT"/>
+ <command name="glMultiTexEnvfEXT"/>
+ <command name="glMultiTexEnvfvEXT"/>
+ <command name="glMultiTexEnviEXT"/>
+ <command name="glMultiTexEnvivEXT"/>
+ <command name="glMultiTexGendEXT"/>
+ <command name="glMultiTexGendvEXT"/>
+ <command name="glMultiTexGenfEXT"/>
+ <command name="glMultiTexGenfvEXT"/>
+ <command name="glMultiTexGeniEXT"/>
+ <command name="glMultiTexGenivEXT"/>
+ <command name="glGetMultiTexEnvfvEXT"/>
+ <command name="glGetMultiTexEnvivEXT"/>
+ <command name="glGetMultiTexGendvEXT"/>
+ <command name="glGetMultiTexGenfvEXT"/>
+ <command name="glGetMultiTexGenivEXT"/>
+ <command name="glMultiTexParameteriEXT"/>
+ <command name="glMultiTexParameterivEXT"/>
+ <command name="glMultiTexParameterfEXT"/>
+ <command name="glMultiTexParameterfvEXT"/>
+ <command name="glMultiTexImage1DEXT"/>
+ <command name="glMultiTexImage2DEXT"/>
+ <command name="glMultiTexSubImage1DEXT"/>
+ <command name="glMultiTexSubImage2DEXT"/>
+ <command name="glCopyMultiTexImage1DEXT"/>
+ <command name="glCopyMultiTexImage2DEXT"/>
+ <command name="glCopyMultiTexSubImage1DEXT"/>
+ <command name="glCopyMultiTexSubImage2DEXT"/>
+ <command name="glGetMultiTexImageEXT"/>
+ <command name="glGetMultiTexParameterfvEXT"/>
+ <command name="glGetMultiTexParameterivEXT"/>
+ <command name="glGetMultiTexLevelParameterfvEXT"/>
+ <command name="glGetMultiTexLevelParameterivEXT"/>
+ <command name="glMultiTexImage3DEXT"/>
+ <command name="glMultiTexSubImage3DEXT"/>
+ <command name="glCopyMultiTexSubImage3DEXT"/>
+ </require>
+ <require comment="OpenGL 1.2.1: New indexed texture commands">
+ <command name="glEnableClientStateIndexedEXT"/>
+ <command name="glDisableClientStateIndexedEXT"/>
+ </require>
+ <require comment="OpenGL 1.2.1: New indexed generic queries">
+ <command name="glGetFloatIndexedvEXT"/>
+ <command name="glGetDoubleIndexedvEXT"/>
+ <command name="glGetPointerIndexedvEXT"/>
+ </require>
+ <require comment="OpenGL 1.2.1: Extend EXT_draw_buffers2 commands">
+ <command name="glEnableIndexedEXT"/>
+ <command name="glDisableIndexedEXT"/>
+ <command name="glIsEnabledIndexedEXT"/>
+ <command name="glGetIntegerIndexedvEXT"/>
+ <command name="glGetBooleanIndexedvEXT"/>
+ </require>
+ <require comment="OpenGL 1.3: New compressed texture object commands">
+ <command name="glCompressedTextureImage3DEXT"/>
+ <command name="glCompressedTextureImage2DEXT"/>
+ <command name="glCompressedTextureImage1DEXT"/>
+ <command name="glCompressedTextureSubImage3DEXT"/>
+ <command name="glCompressedTextureSubImage2DEXT"/>
+ <command name="glCompressedTextureSubImage1DEXT"/>
+ <command name="glGetCompressedTextureImageEXT"/>
+ </require>
+ <require comment="OpenGL 1.3: New multitexture compressed texture commands">
+ <command name="glCompressedMultiTexImage3DEXT"/>
+ <command name="glCompressedMultiTexImage2DEXT"/>
+ <command name="glCompressedMultiTexImage1DEXT"/>
+ <command name="glCompressedMultiTexSubImage3DEXT"/>
+ <command name="glCompressedMultiTexSubImage2DEXT"/>
+ <command name="glCompressedMultiTexSubImage1DEXT"/>
+ <command name="glGetCompressedMultiTexImageEXT"/>
+ </require>
+ <require comment="OpenGL 1.3: New transpose matrix commands">
+ <command name="glMatrixLoadTransposefEXT"/>
+ <command name="glMatrixLoadTransposedEXT"/>
+ <command name="glMatrixMultTransposefEXT"/>
+ <command name="glMatrixMultTransposedEXT"/>
+ </require>
+ <require comment="OpenGL 1.5: New buffer commands">
+ <command name="glNamedBufferDataEXT"/>
+ <command name="glNamedBufferSubDataEXT"/>
+ <command name="glMapNamedBufferEXT"/>
+ <command name="glUnmapNamedBufferEXT"/>
+ <command name="glGetNamedBufferParameterivEXT"/>
+ <command name="glGetNamedBufferPointervEXT"/>
+ <command name="glGetNamedBufferSubDataEXT"/>
+ </require>
+ <require comment="OpenGL 2.0: New uniform commands">
+ <command name="glProgramUniform1fEXT"/>
+ <command name="glProgramUniform2fEXT"/>
+ <command name="glProgramUniform3fEXT"/>
+ <command name="glProgramUniform4fEXT"/>
+ <command name="glProgramUniform1iEXT"/>
+ <command name="glProgramUniform2iEXT"/>
+ <command name="glProgramUniform3iEXT"/>
+ <command name="glProgramUniform4iEXT"/>
+ <command name="glProgramUniform1fvEXT"/>
+ <command name="glProgramUniform2fvEXT"/>
+ <command name="glProgramUniform3fvEXT"/>
+ <command name="glProgramUniform4fvEXT"/>
+ <command name="glProgramUniform1ivEXT"/>
+ <command name="glProgramUniform2ivEXT"/>
+ <command name="glProgramUniform3ivEXT"/>
+ <command name="glProgramUniform4ivEXT"/>
+ <command name="glProgramUniformMatrix2fvEXT"/>
+ <command name="glProgramUniformMatrix3fvEXT"/>
+ <command name="glProgramUniformMatrix4fvEXT"/>
+ </require>
+ <require comment="OpenGL 2.1: New uniform matrix commands">
+ <command name="glProgramUniformMatrix2x3fvEXT"/>
+ <command name="glProgramUniformMatrix3x2fvEXT"/>
+ <command name="glProgramUniformMatrix2x4fvEXT"/>
+ <command name="glProgramUniformMatrix4x2fvEXT"/>
+ <command name="glProgramUniformMatrix3x4fvEXT"/>
+ <command name="glProgramUniformMatrix4x3fvEXT"/>
+ </require>
+ <require comment="Extend EXT_texture_buffer_object commands">
+ <command name="glTextureBufferEXT"/>
+ <command name="glMultiTexBufferEXT"/>
+ </require>
+ <require comment="Extend EXT_texture_integer commands">
+ <command name="glTextureParameterIivEXT"/>
+ <command name="glTextureParameterIuivEXT"/>
+ <command name="glGetTextureParameterIivEXT"/>
+ <command name="glGetTextureParameterIuivEXT"/>
+ <command name="glMultiTexParameterIivEXT"/>
+ <command name="glMultiTexParameterIuivEXT"/>
+ <command name="glGetMultiTexParameterIivEXT"/>
+ <command name="glGetMultiTexParameterIuivEXT"/>
+ </require>
+ <require comment="Extend EXT_gpu_shader4 commands">
+ <command name="glProgramUniform1uiEXT"/>
+ <command name="glProgramUniform2uiEXT"/>
+ <command name="glProgramUniform3uiEXT"/>
+ <command name="glProgramUniform4uiEXT"/>
+ <command name="glProgramUniform1uivEXT"/>
+ <command name="glProgramUniform2uivEXT"/>
+ <command name="glProgramUniform3uivEXT"/>
+ <command name="glProgramUniform4uivEXT"/>
+ </require>
+ <require comment="Extend EXT_gpu_program_parameters commands">
+ <command name="glNamedProgramLocalParameters4fvEXT"/>
+ </require>
+ <require comment="Extend NV_gpu_program4 commands">
+ <command name="glNamedProgramLocalParameterI4iEXT"/>
+ <command name="glNamedProgramLocalParameterI4ivEXT"/>
+ <command name="glNamedProgramLocalParametersI4ivEXT"/>
+ <command name="glNamedProgramLocalParameterI4uiEXT"/>
+ <command name="glNamedProgramLocalParameterI4uivEXT"/>
+ <command name="glNamedProgramLocalParametersI4uivEXT"/>
+ <command name="glGetNamedProgramLocalParameterIivEXT"/>
+ <command name="glGetNamedProgramLocalParameterIuivEXT"/>
+ </require>
+ <require comment="OpenGL 3.0: New indexed texture commands">
+ <command name="glEnableClientStateiEXT"/>
+ <command name="glDisableClientStateiEXT"/>
+ </require>
+ <require comment="OpenGL 3.0: New indexed generic queries">
+ <command name="glGetFloati_vEXT"/>
+ <command name="glGetDoublei_vEXT"/>
+ <command name="glGetPointeri_vEXT"/>
+ </require>
+ <require comment="Extend GL_ARB_vertex_program commands">
+ <command name="glNamedProgramStringEXT"/>
+ <command name="glNamedProgramLocalParameter4dEXT"/>
+ <command name="glNamedProgramLocalParameter4dvEXT"/>
+ <command name="glNamedProgramLocalParameter4fEXT"/>
+ <command name="glNamedProgramLocalParameter4fvEXT"/>
+ <command name="glGetNamedProgramLocalParameterdvEXT"/>
+ <command name="glGetNamedProgramLocalParameterfvEXT"/>
+ <command name="glGetNamedProgramivEXT"/>
+ <command name="glGetNamedProgramStringEXT"/>
+ </require>
+ <require comment="OpenGL 3.0: New renderbuffer commands">
+ <command name="glNamedRenderbufferStorageEXT"/>
+ <command name="glGetNamedRenderbufferParameterivEXT"/>
+ <command name="glNamedRenderbufferStorageMultisampleEXT"/>
+ </require>
+ <require comment="Extend NV_framebuffer_multisample_coverage">
+ <command name="glNamedRenderbufferStorageMultisampleCoverageEXT"/>
+ </require>
+ <require comment="OpenGL 3.0: New framebuffer commands">
+ <command name="glCheckNamedFramebufferStatusEXT"/>
+ <command name="glNamedFramebufferTexture1DEXT"/>
+ <command name="glNamedFramebufferTexture2DEXT"/>
+ <command name="glNamedFramebufferTexture3DEXT"/>
+ <command name="glNamedFramebufferRenderbufferEXT"/>
+ <command name="glGetNamedFramebufferAttachmentParameterivEXT"/>
+ </require>
+ <require comment="OpenGL 3.0: New texture commands">
+ <command name="glGenerateTextureMipmapEXT"/>
+ <command name="glGenerateMultiTexMipmapEXT"/>
+ </require>
+ <require comment="OpenGL 3.0: New framebuffer commands">
+ <command name="glFramebufferDrawBufferEXT"/>
+ <command name="glFramebufferDrawBuffersEXT"/>
+ <command name="glFramebufferReadBufferEXT"/>
+ <command name="glGetFramebufferParameterivEXT"/>
+ </require>
+ <require comment="OpenGL 3.0: New buffer data copy command">
+ <command name="glNamedCopyBufferSubDataEXT"/>
+ </require>
+ <require comment="Extend EXT_geometry_shader4 or NV_gpu_program4">
+ <command name="glNamedFramebufferTextureEXT"/>
+ <command name="glNamedFramebufferTextureLayerEXT"/>
+ <command name="glNamedFramebufferTextureFaceEXT"/>
+ </require>
+ <require comment="Extend NV_explicit_multisample">
+ <command name="glTextureRenderbufferEXT"/>
+ <command name="glMultiTexRenderbufferEXT"/>
+ </require>
+ <require comment="OpenGL 3.0: New vertex array specification commands for VAO">
+ <command name="glVertexArrayVertexOffsetEXT"/>
+ <command name="glVertexArrayColorOffsetEXT"/>
+ <command name="glVertexArrayEdgeFlagOffsetEXT"/>
+ <command name="glVertexArrayIndexOffsetEXT"/>
+ <command name="glVertexArrayNormalOffsetEXT"/>
+ <command name="glVertexArrayTexCoordOffsetEXT"/>
+ <command name="glVertexArrayMultiTexCoordOffsetEXT"/>
+ <command name="glVertexArrayFogCoordOffsetEXT"/>
+ <command name="glVertexArraySecondaryColorOffsetEXT"/>
+ <command name="glVertexArrayVertexAttribOffsetEXT"/>
+ <command name="glVertexArrayVertexAttribIOffsetEXT"/>
+ </require>
+ <require comment="OpenGL 3.0: New vertex array enable commands for VAO">
+ <command name="glEnableVertexArrayEXT"/>
+ <command name="glDisableVertexArrayEXT"/>
+ </require>
+ <require comment="OpenGL 3.0: New vertex attrib array enable commands for VAO">
+ <command name="glEnableVertexArrayAttribEXT"/>
+ <command name="glDisableVertexArrayAttribEXT"/>
+ </require>
+ <require comment="OpenGL 3.0: New queries for VAO">
+ <command name="glGetVertexArrayIntegervEXT"/>
+ <command name="glGetVertexArrayPointervEXT"/>
+ <command name="glGetVertexArrayIntegeri_vEXT"/>
+ <command name="glGetVertexArrayPointeri_vEXT"/>
+ </require>
+ <require comment="OpenGL 3.0: New buffer commands">
+ <command name="glMapNamedBufferRangeEXT"/>
+ <command name="glFlushMappedNamedBufferRangeEXT"/>
+ </require>
+ <require comment="Extended by GL_ARB_buffer_storage">
+ <command name="glNamedBufferStorageEXT"/>
+ </require>
+ <require comment="Extended by GL_ARB_clear_buffer_object">
+ <command name="glClearNamedBufferDataEXT"/>
+ <command name="glClearNamedBufferSubDataEXT"/>
+ </require>
+ <require comment="Extended by GL_ARB_framebuffer_no_attachments">
+ <command name="glNamedFramebufferParameteriEXT"/>
+ <command name="glGetNamedFramebufferParameterivEXT"/>
+ </require>
+ <require comment="Extended by GL_ARB_gpu_shader_fp64">
+ <command name="glProgramUniform1dEXT"/>
+ <command name="glProgramUniform2dEXT"/>
+ <command name="glProgramUniform3dEXT"/>
+ <command name="glProgramUniform4dEXT"/>
+ <command name="glProgramUniform1dvEXT"/>
+ <command name="glProgramUniform2dvEXT"/>
+ <command name="glProgramUniform3dvEXT"/>
+ <command name="glProgramUniform4dvEXT"/>
+ <command name="glProgramUniformMatrix2dvEXT"/>
+ <command name="glProgramUniformMatrix3dvEXT"/>
+ <command name="glProgramUniformMatrix4dvEXT"/>
+ <command name="glProgramUniformMatrix2x3dvEXT"/>
+ <command name="glProgramUniformMatrix2x4dvEXT"/>
+ <command name="glProgramUniformMatrix3x2dvEXT"/>
+ <command name="glProgramUniformMatrix3x4dvEXT"/>
+ <command name="glProgramUniformMatrix4x2dvEXT"/>
+ <command name="glProgramUniformMatrix4x3dvEXT"/>
+ </require>
+ <require comment="Extended by GL_ARB_texture_buffer_range">
+ <command name="glTextureBufferRangeEXT"/>
+ </require>
+ <require comment="Extended by GL_ARB_texture_storage">
+ <command name="glTextureStorage1DEXT"/>
+ <command name="glTextureStorage2DEXT"/>
+ <command name="glTextureStorage3DEXT"/>
+ </require>
+ <require comment="Extended by GL_ARB_texture_storage_multisample">
+ <command name="glTextureStorage2DMultisampleEXT"/>
+ <command name="glTextureStorage3DMultisampleEXT"/>
+ </require>
+ <require comment="Extended by GL_ARB_vertex_attrib_binding">
+ <command name="glVertexArrayBindVertexBufferEXT"/>
+ <command name="glVertexArrayVertexAttribFormatEXT"/>
+ <command name="glVertexArrayVertexAttribIFormatEXT"/>
+ <command name="glVertexArrayVertexAttribLFormatEXT"/>
+ <command name="glVertexArrayVertexAttribBindingEXT"/>
+ <command name="glVertexArrayVertexBindingDivisorEXT"/>
+ </require>
+ <require comment="Extended by GL_EXT_vertex_attrib_64bit">
+ <command name="glVertexArrayVertexAttribLOffsetEXT"/>
+ </require>
+ <require comment="Extended by GL_ARB_sparse_texture">
+ <command name="glTexturePageCommitmentEXT"/>
+ </require>
+ <require comment="Extended by GL_ARB_instanced_arrays">
+ <command name="glVertexArrayVertexAttribDivisorEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_discard_framebuffer" supported="gles1|gles2">
+ <require>
+ <enum name="GL_COLOR_EXT"/>
+ <enum name="GL_DEPTH_EXT"/>
+ <enum name="GL_STENCIL_EXT"/>
+ <command name="glDiscardFramebufferEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_disjoint_timer_query" supported="gles2">
+ <require>
+ <enum name="GL_QUERY_COUNTER_BITS_EXT"/>
+ <enum name="GL_CURRENT_QUERY_EXT"/>
+ <enum name="GL_QUERY_RESULT_EXT"/>
+ <enum name="GL_QUERY_RESULT_AVAILABLE_EXT"/>
+ <enum name="GL_TIME_ELAPSED_EXT"/>
+ <enum name="GL_TIMESTAMP_EXT"/>
+ <enum name="GL_GPU_DISJOINT_EXT"/>
+ <command name="glGenQueriesEXT"/>
+ <command name="glDeleteQueriesEXT"/>
+ <command name="glIsQueryEXT"/>
+ <command name="glBeginQueryEXT"/>
+ <command name="glEndQueryEXT"/>
+ <command name="glQueryCounterEXT"/>
+ <command name="glGetQueryivEXT"/>
+ <command name="glGetQueryObjectivEXT"/>
+ <command name="glGetQueryObjectuivEXT"/>
+ <command name="glGetQueryObjecti64vEXT"/>
+ <command name="glGetQueryObjectui64vEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_draw_buffers" supported="gles2">
+ <require>
+ <enum name="GL_MAX_COLOR_ATTACHMENTS_EXT"/>
+ <enum name="GL_MAX_DRAW_BUFFERS_EXT"/>
+ <enum name="GL_DRAW_BUFFER0_EXT"/>
+ <enum name="GL_DRAW_BUFFER1_EXT"/>
+ <enum name="GL_DRAW_BUFFER2_EXT"/>
+ <enum name="GL_DRAW_BUFFER3_EXT"/>
+ <enum name="GL_DRAW_BUFFER4_EXT"/>
+ <enum name="GL_DRAW_BUFFER5_EXT"/>
+ <enum name="GL_DRAW_BUFFER6_EXT"/>
+ <enum name="GL_DRAW_BUFFER7_EXT"/>
+ <enum name="GL_DRAW_BUFFER8_EXT"/>
+ <enum name="GL_DRAW_BUFFER9_EXT"/>
+ <enum name="GL_DRAW_BUFFER10_EXT"/>
+ <enum name="GL_DRAW_BUFFER11_EXT"/>
+ <enum name="GL_DRAW_BUFFER12_EXT"/>
+ <enum name="GL_DRAW_BUFFER13_EXT"/>
+ <enum name="GL_DRAW_BUFFER14_EXT"/>
+ <enum name="GL_DRAW_BUFFER15_EXT"/>
+ <enum name="GL_COLOR_ATTACHMENT0_EXT"/>
+ <enum name="GL_COLOR_ATTACHMENT1_EXT"/>
+ <enum name="GL_COLOR_ATTACHMENT2_EXT"/>
+ <enum name="GL_COLOR_ATTACHMENT3_EXT"/>
+ <enum name="GL_COLOR_ATTACHMENT4_EXT"/>
+ <enum name="GL_COLOR_ATTACHMENT5_EXT"/>
+ <enum name="GL_COLOR_ATTACHMENT6_EXT"/>
+ <enum name="GL_COLOR_ATTACHMENT7_EXT"/>
+ <enum name="GL_COLOR_ATTACHMENT8_EXT"/>
+ <enum name="GL_COLOR_ATTACHMENT9_EXT"/>
+ <enum name="GL_COLOR_ATTACHMENT10_EXT"/>
+ <enum name="GL_COLOR_ATTACHMENT11_EXT"/>
+ <enum name="GL_COLOR_ATTACHMENT12_EXT"/>
+ <enum name="GL_COLOR_ATTACHMENT13_EXT"/>
+ <enum name="GL_COLOR_ATTACHMENT14_EXT"/>
+ <enum name="GL_COLOR_ATTACHMENT15_EXT"/>
+ <command name="glDrawBuffersEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_draw_buffers2" supported="gl">
+ <require>
+ <command name="glColorMaskIndexedEXT"/>
+ <command name="glGetBooleanIndexedvEXT"/>
+ <command name="glGetIntegerIndexedvEXT"/>
+ <command name="glEnableIndexedEXT"/>
+ <command name="glDisableIndexedEXT"/>
+ <command name="glIsEnabledIndexedEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_draw_buffers_indexed" supported="gles2">
+ <require>
+ <enum name="GL_BLEND_EQUATION_RGB"/>
+ <enum name="GL_BLEND_EQUATION_ALPHA"/>
+ <enum name="GL_BLEND_SRC_RGB"/>
+ <enum name="GL_BLEND_SRC_ALPHA"/>
+ <enum name="GL_BLEND_DST_RGB"/>
+ <enum name="GL_BLEND_DST_ALPHA"/>
+ <enum name="GL_COLOR_WRITEMASK"/>
+ <enum name="GL_BLEND"/>
+ <enum name="GL_FUNC_ADD"/>
+ <enum name="GL_FUNC_SUBTRACT"/>
+ <enum name="GL_FUNC_REVERSE_SUBTRACT"/>
+ <enum name="GL_MIN"/>
+ <enum name="GL_MAX"/>
+ <enum name="GL_ZERO"/>
+ <enum name="GL_ONE"/>
+ <enum name="GL_SRC_COLOR"/>
+ <enum name="GL_ONE_MINUS_SRC_COLOR"/>
+ <enum name="GL_DST_COLOR"/>
+ <enum name="GL_ONE_MINUS_DST_COLOR"/>
+ <enum name="GL_SRC_ALPHA"/>
+ <enum name="GL_ONE_MINUS_SRC_ALPHA"/>
+ <enum name="GL_DST_ALPHA"/>
+ <enum name="GL_ONE_MINUS_DST_ALPHA"/>
+ <enum name="GL_CONSTANT_COLOR"/>
+ <enum name="GL_ONE_MINUS_CONSTANT_COLOR"/>
+ <enum name="GL_CONSTANT_ALPHA"/>
+ <enum name="GL_ONE_MINUS_CONSTANT_ALPHA"/>
+ <enum name="GL_SRC_ALPHA_SATURATE"/>
+ <command name="glEnableiEXT"/>
+ <command name="glDisableiEXT"/>
+ <command name="glBlendEquationiEXT"/>
+ <command name="glBlendEquationSeparateiEXT"/>
+ <command name="glBlendFunciEXT"/>
+ <command name="glBlendFuncSeparateiEXT"/>
+ <command name="glColorMaskiEXT"/>
+ <command name="glIsEnablediEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_draw_instanced" supported="gl|gles2">
+ <require>
+ <command name="glDrawArraysInstancedEXT"/>
+ <command name="glDrawElementsInstancedEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_draw_range_elements" supported="gl">
+ <require>
+ <enum name="GL_MAX_ELEMENTS_VERTICES_EXT"/>
+ <enum name="GL_MAX_ELEMENTS_INDICES_EXT"/>
+ <command name="glDrawRangeElementsEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_fog_coord" supported="gl">
+ <require>
+ <enum name="GL_FOG_COORDINATE_SOURCE_EXT"/>
+ <enum name="GL_FOG_COORDINATE_EXT"/>
+ <enum name="GL_FRAGMENT_DEPTH_EXT"/>
+ <enum name="GL_CURRENT_FOG_COORDINATE_EXT"/>
+ <enum name="GL_FOG_COORDINATE_ARRAY_TYPE_EXT"/>
+ <enum name="GL_FOG_COORDINATE_ARRAY_STRIDE_EXT"/>
+ <enum name="GL_FOG_COORDINATE_ARRAY_POINTER_EXT"/>
+ <enum name="GL_FOG_COORDINATE_ARRAY_EXT"/>
+ <command name="glFogCoordfEXT"/>
+ <command name="glFogCoordfvEXT"/>
+ <command name="glFogCoorddEXT"/>
+ <command name="glFogCoorddvEXT"/>
+ <command name="glFogCoordPointerEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_framebuffer_blit" supported="gl">
+ <require>
+ <enum name="GL_READ_FRAMEBUFFER_EXT"/>
+ <enum name="GL_DRAW_FRAMEBUFFER_EXT"/>
+ <enum name="GL_DRAW_FRAMEBUFFER_BINDING_EXT"/>
+ <enum name="GL_READ_FRAMEBUFFER_BINDING_EXT"/>
+ <command name="glBlitFramebufferEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_framebuffer_multisample" supported="gl">
+ <require>
+ <enum name="GL_RENDERBUFFER_SAMPLES_EXT"/>
+ <enum name="GL_FRAMEBUFFER_INCOMPLETE_MULTISAMPLE_EXT"/>
+ <enum name="GL_MAX_SAMPLES_EXT"/>
+ <command name="glRenderbufferStorageMultisampleEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_framebuffer_multisample_blit_scaled" supported="gl">
+ <require>
+ <enum name="GL_SCALED_RESOLVE_FASTEST_EXT"/>
+ <enum name="GL_SCALED_RESOLVE_NICEST_EXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_framebuffer_object" supported="gl">
+ <require>
+ <enum name="GL_INVALID_FRAMEBUFFER_OPERATION_EXT"/>
+ <enum name="GL_MAX_RENDERBUFFER_SIZE_EXT"/>
+ <enum name="GL_FRAMEBUFFER_BINDING_EXT"/>
+ <enum name="GL_RENDERBUFFER_BINDING_EXT"/>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE_EXT"/>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_OBJECT_NAME_EXT"/>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL_EXT"/>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE_EXT"/>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_3D_ZOFFSET_EXT"/>
+ <enum name="GL_FRAMEBUFFER_COMPLETE_EXT"/>
+ <enum name="GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT_EXT"/>
+ <enum name="GL_FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT_EXT"/>
+ <enum name="GL_FRAMEBUFFER_INCOMPLETE_DIMENSIONS_EXT"/>
+ <enum name="GL_FRAMEBUFFER_INCOMPLETE_FORMATS_EXT"/>
+ <enum name="GL_FRAMEBUFFER_INCOMPLETE_DRAW_BUFFER_EXT"/>
+ <enum name="GL_FRAMEBUFFER_INCOMPLETE_READ_BUFFER_EXT"/>
+ <enum name="GL_FRAMEBUFFER_UNSUPPORTED_EXT"/>
+ <enum name="GL_MAX_COLOR_ATTACHMENTS_EXT"/>
+ <enum name="GL_COLOR_ATTACHMENT0_EXT"/>
+ <enum name="GL_COLOR_ATTACHMENT1_EXT"/>
+ <enum name="GL_COLOR_ATTACHMENT2_EXT"/>
+ <enum name="GL_COLOR_ATTACHMENT3_EXT"/>
+ <enum name="GL_COLOR_ATTACHMENT4_EXT"/>
+ <enum name="GL_COLOR_ATTACHMENT5_EXT"/>
+ <enum name="GL_COLOR_ATTACHMENT6_EXT"/>
+ <enum name="GL_COLOR_ATTACHMENT7_EXT"/>
+ <enum name="GL_COLOR_ATTACHMENT8_EXT"/>
+ <enum name="GL_COLOR_ATTACHMENT9_EXT"/>
+ <enum name="GL_COLOR_ATTACHMENT10_EXT"/>
+ <enum name="GL_COLOR_ATTACHMENT11_EXT"/>
+ <enum name="GL_COLOR_ATTACHMENT12_EXT"/>
+ <enum name="GL_COLOR_ATTACHMENT13_EXT"/>
+ <enum name="GL_COLOR_ATTACHMENT14_EXT"/>
+ <enum name="GL_COLOR_ATTACHMENT15_EXT"/>
+ <enum name="GL_DEPTH_ATTACHMENT_EXT"/>
+ <enum name="GL_STENCIL_ATTACHMENT_EXT"/>
+ <enum name="GL_FRAMEBUFFER_EXT"/>
+ <enum name="GL_RENDERBUFFER_EXT"/>
+ <enum name="GL_RENDERBUFFER_WIDTH_EXT"/>
+ <enum name="GL_RENDERBUFFER_HEIGHT_EXT"/>
+ <enum name="GL_RENDERBUFFER_INTERNAL_FORMAT_EXT"/>
+ <enum name="GL_STENCIL_INDEX1_EXT"/>
+ <enum name="GL_STENCIL_INDEX4_EXT"/>
+ <enum name="GL_STENCIL_INDEX8_EXT"/>
+ <enum name="GL_STENCIL_INDEX16_EXT"/>
+ <enum name="GL_RENDERBUFFER_RED_SIZE_EXT"/>
+ <enum name="GL_RENDERBUFFER_GREEN_SIZE_EXT"/>
+ <enum name="GL_RENDERBUFFER_BLUE_SIZE_EXT"/>
+ <enum name="GL_RENDERBUFFER_ALPHA_SIZE_EXT"/>
+ <enum name="GL_RENDERBUFFER_DEPTH_SIZE_EXT"/>
+ <enum name="GL_RENDERBUFFER_STENCIL_SIZE_EXT"/>
+ <command name="glIsRenderbufferEXT"/>
+ <command name="glBindRenderbufferEXT"/>
+ <command name="glDeleteRenderbuffersEXT"/>
+ <command name="glGenRenderbuffersEXT"/>
+ <command name="glRenderbufferStorageEXT"/>
+ <command name="glGetRenderbufferParameterivEXT"/>
+ <command name="glIsFramebufferEXT"/>
+ <command name="glBindFramebufferEXT"/>
+ <command name="glDeleteFramebuffersEXT"/>
+ <command name="glGenFramebuffersEXT"/>
+ <command name="glCheckFramebufferStatusEXT"/>
+ <command name="glFramebufferTexture1DEXT"/>
+ <command name="glFramebufferTexture2DEXT"/>
+ <command name="glFramebufferTexture3DEXT"/>
+ <command name="glFramebufferRenderbufferEXT"/>
+ <command name="glGetFramebufferAttachmentParameterivEXT"/>
+ <command name="glGenerateMipmapEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_framebuffer_sRGB" supported="gl">
+ <require>
+ <enum name="GL_FRAMEBUFFER_SRGB_EXT"/>
+ <enum name="GL_FRAMEBUFFER_SRGB_CAPABLE_EXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_geometry_point_size" supported="gles2"/>
+ <extension name="GL_EXT_geometry_shader" supported="gles2">
+ <require>
+ <enum name="GL_GEOMETRY_SHADER_EXT"/>
+ <enum name="GL_GEOMETRY_SHADER_BIT_EXT"/>
+ <enum name="GL_GEOMETRY_LINKED_VERTICES_OUT_EXT"/>
+ <enum name="GL_GEOMETRY_LINKED_INPUT_TYPE_EXT"/>
+ <enum name="GL_GEOMETRY_LINKED_OUTPUT_TYPE_EXT"/>
+ <enum name="GL_GEOMETRY_SHADER_INVOCATIONS_EXT"/>
+ <enum name="GL_LAYER_PROVOKING_VERTEX_EXT"/>
+ <enum name="GL_LINES_ADJACENCY_EXT"/>
+ <enum name="GL_LINE_STRIP_ADJACENCY_EXT"/>
+ <enum name="GL_TRIANGLES_ADJACENCY_EXT"/>
+ <enum name="GL_TRIANGLE_STRIP_ADJACENCY_EXT"/>
+ <enum name="GL_MAX_GEOMETRY_UNIFORM_COMPONENTS_EXT"/>
+ <enum name="GL_MAX_GEOMETRY_UNIFORM_BLOCKS_EXT"/>
+ <enum name="GL_MAX_COMBINED_GEOMETRY_UNIFORM_COMPONENTS_EXT"/>
+ <enum name="GL_MAX_GEOMETRY_INPUT_COMPONENTS_EXT"/>
+ <enum name="GL_MAX_GEOMETRY_OUTPUT_COMPONENTS_EXT"/>
+ <enum name="GL_MAX_GEOMETRY_OUTPUT_VERTICES_EXT"/>
+ <enum name="GL_MAX_GEOMETRY_TOTAL_OUTPUT_COMPONENTS_EXT"/>
+ <enum name="GL_MAX_GEOMETRY_SHADER_INVOCATIONS_EXT"/>
+ <enum name="GL_MAX_GEOMETRY_TEXTURE_IMAGE_UNITS_EXT"/>
+ <enum name="GL_MAX_GEOMETRY_ATOMIC_COUNTER_BUFFERS_EXT"/>
+ <enum name="GL_MAX_GEOMETRY_ATOMIC_COUNTERS_EXT"/>
+ <enum name="GL_MAX_GEOMETRY_IMAGE_UNIFORMS_EXT"/>
+ <enum name="GL_MAX_GEOMETRY_SHADER_STORAGE_BLOCKS_EXT"/>
+ <enum name="GL_FIRST_VERTEX_CONVENTION_EXT"/>
+ <enum name="GL_LAST_VERTEX_CONVENTION_EXT"/>
+ <enum name="GL_UNDEFINED_VERTEX_EXT"/>
+ <enum name="GL_PRIMITIVES_GENERATED_EXT"/>
+ <enum name="GL_FRAMEBUFFER_DEFAULT_LAYERS_EXT"/>
+ <enum name="GL_MAX_FRAMEBUFFER_LAYERS_EXT"/>
+ <enum name="GL_FRAMEBUFFER_INCOMPLETE_LAYER_TARGETS_EXT"/>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_LAYERED_EXT"/>
+ <enum name="GL_REFERENCED_BY_GEOMETRY_SHADER_EXT"/>
+ <command name="glFramebufferTextureEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_geometry_shader4" supported="gl">
+ <require>
+ <enum name="GL_GEOMETRY_SHADER_EXT"/>
+ <enum name="GL_GEOMETRY_VERTICES_OUT_EXT"/>
+ <enum name="GL_GEOMETRY_INPUT_TYPE_EXT"/>
+ <enum name="GL_GEOMETRY_OUTPUT_TYPE_EXT"/>
+ <enum name="GL_MAX_GEOMETRY_TEXTURE_IMAGE_UNITS_EXT"/>
+ <enum name="GL_MAX_GEOMETRY_VARYING_COMPONENTS_EXT"/>
+ <enum name="GL_MAX_VERTEX_VARYING_COMPONENTS_EXT"/>
+ <enum name="GL_MAX_VARYING_COMPONENTS_EXT"/>
+ <enum name="GL_MAX_GEOMETRY_UNIFORM_COMPONENTS_EXT"/>
+ <enum name="GL_MAX_GEOMETRY_OUTPUT_VERTICES_EXT"/>
+ <enum name="GL_MAX_GEOMETRY_TOTAL_OUTPUT_COMPONENTS_EXT"/>
+ <enum name="GL_LINES_ADJACENCY_EXT"/>
+ <enum name="GL_LINE_STRIP_ADJACENCY_EXT"/>
+ <enum name="GL_TRIANGLES_ADJACENCY_EXT"/>
+ <enum name="GL_TRIANGLE_STRIP_ADJACENCY_EXT"/>
+ <enum name="GL_FRAMEBUFFER_INCOMPLETE_LAYER_TARGETS_EXT"/>
+ <enum name="GL_FRAMEBUFFER_INCOMPLETE_LAYER_COUNT_EXT"/>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_LAYERED_EXT"/>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER_EXT"/>
+ <enum name="GL_PROGRAM_POINT_SIZE_EXT"/>
+ <command name="glProgramParameteriEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_gpu_program_parameters" supported="gl">
+ <require>
+ <command name="glProgramEnvParameters4fvEXT"/>
+ <command name="glProgramLocalParameters4fvEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_gpu_shader4" supported="gl">
+ <require>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY_INTEGER_EXT"/>
+ <enum name="GL_SAMPLER_1D_ARRAY_EXT"/>
+ <enum name="GL_SAMPLER_2D_ARRAY_EXT"/>
+ <enum name="GL_SAMPLER_BUFFER_EXT"/>
+ <enum name="GL_SAMPLER_1D_ARRAY_SHADOW_EXT"/>
+ <enum name="GL_SAMPLER_2D_ARRAY_SHADOW_EXT"/>
+ <enum name="GL_SAMPLER_CUBE_SHADOW_EXT"/>
+ <enum name="GL_UNSIGNED_INT_VEC2_EXT"/>
+ <enum name="GL_UNSIGNED_INT_VEC3_EXT"/>
+ <enum name="GL_UNSIGNED_INT_VEC4_EXT"/>
+ <enum name="GL_INT_SAMPLER_1D_EXT"/>
+ <enum name="GL_INT_SAMPLER_2D_EXT"/>
+ <enum name="GL_INT_SAMPLER_3D_EXT"/>
+ <enum name="GL_INT_SAMPLER_CUBE_EXT"/>
+ <enum name="GL_INT_SAMPLER_2D_RECT_EXT"/>
+ <enum name="GL_INT_SAMPLER_1D_ARRAY_EXT"/>
+ <enum name="GL_INT_SAMPLER_2D_ARRAY_EXT"/>
+ <enum name="GL_INT_SAMPLER_BUFFER_EXT"/>
+ <enum name="GL_UNSIGNED_INT_SAMPLER_1D_EXT"/>
+ <enum name="GL_UNSIGNED_INT_SAMPLER_2D_EXT"/>
+ <enum name="GL_UNSIGNED_INT_SAMPLER_3D_EXT"/>
+ <enum name="GL_UNSIGNED_INT_SAMPLER_CUBE_EXT"/>
+ <enum name="GL_UNSIGNED_INT_SAMPLER_2D_RECT_EXT"/>
+ <enum name="GL_UNSIGNED_INT_SAMPLER_1D_ARRAY_EXT"/>
+ <enum name="GL_UNSIGNED_INT_SAMPLER_2D_ARRAY_EXT"/>
+ <enum name="GL_UNSIGNED_INT_SAMPLER_BUFFER_EXT"/>
+ <enum name="GL_MIN_PROGRAM_TEXEL_OFFSET_EXT"/>
+ <enum name="GL_MAX_PROGRAM_TEXEL_OFFSET_EXT"/>
+ <command name="glGetUniformuivEXT"/>
+ <command name="glBindFragDataLocationEXT"/>
+ <command name="glGetFragDataLocationEXT"/>
+ <command name="glUniform1uiEXT"/>
+ <command name="glUniform2uiEXT"/>
+ <command name="glUniform3uiEXT"/>
+ <command name="glUniform4uiEXT"/>
+ <command name="glUniform1uivEXT"/>
+ <command name="glUniform2uivEXT"/>
+ <command name="glUniform3uivEXT"/>
+ <command name="glUniform4uivEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_gpu_shader5" supported="gles2">
+ <require/>
+ </extension>
+ <extension name="GL_EXT_histogram" supported="gl">
+ <require>
+ <enum name="GL_HISTOGRAM_EXT"/>
+ <enum name="GL_PROXY_HISTOGRAM_EXT"/>
+ <enum name="GL_HISTOGRAM_WIDTH_EXT"/>
+ <enum name="GL_HISTOGRAM_FORMAT_EXT"/>
+ <enum name="GL_HISTOGRAM_RED_SIZE_EXT"/>
+ <enum name="GL_HISTOGRAM_GREEN_SIZE_EXT"/>
+ <enum name="GL_HISTOGRAM_BLUE_SIZE_EXT"/>
+ <enum name="GL_HISTOGRAM_ALPHA_SIZE_EXT"/>
+ <enum name="GL_HISTOGRAM_LUMINANCE_SIZE_EXT"/>
+ <enum name="GL_HISTOGRAM_SINK_EXT"/>
+ <enum name="GL_MINMAX_EXT"/>
+ <enum name="GL_MINMAX_FORMAT_EXT"/>
+ <enum name="GL_MINMAX_SINK_EXT"/>
+ <enum name="GL_TABLE_TOO_LARGE_EXT"/>
+ <command name="glGetHistogramEXT"/>
+ <command name="glGetHistogramParameterfvEXT"/>
+ <command name="glGetHistogramParameterivEXT"/>
+ <command name="glGetMinmaxEXT"/>
+ <command name="glGetMinmaxParameterfvEXT"/>
+ <command name="glGetMinmaxParameterivEXT"/>
+ <command name="glHistogramEXT"/>
+ <command name="glMinmaxEXT"/>
+ <command name="glResetHistogramEXT"/>
+ <command name="glResetMinmaxEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_index_array_formats" supported="gl">
+ <require>
+ <enum name="GL_IUI_V2F_EXT"/>
+ <enum name="GL_IUI_V3F_EXT"/>
+ <enum name="GL_IUI_N3F_V2F_EXT"/>
+ <enum name="GL_IUI_N3F_V3F_EXT"/>
+ <enum name="GL_T2F_IUI_V2F_EXT"/>
+ <enum name="GL_T2F_IUI_V3F_EXT"/>
+ <enum name="GL_T2F_IUI_N3F_V2F_EXT"/>
+ <enum name="GL_T2F_IUI_N3F_V3F_EXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_index_func" supported="gl">
+ <require>
+ <enum name="GL_INDEX_TEST_EXT"/>
+ <enum name="GL_INDEX_TEST_FUNC_EXT"/>
+ <enum name="GL_INDEX_TEST_REF_EXT"/>
+ <command name="glIndexFuncEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_index_material" supported="gl">
+ <require>
+ <enum name="GL_INDEX_MATERIAL_EXT"/>
+ <enum name="GL_INDEX_MATERIAL_PARAMETER_EXT"/>
+ <enum name="GL_INDEX_MATERIAL_FACE_EXT"/>
+ <command name="glIndexMaterialEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_index_texture" supported="gl"/>
+ <extension name="GL_EXT_instanced_arrays" supported="gles2">
+ <require>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY_DIVISOR_EXT"/>
+ <command name="glDrawArraysInstancedEXT"/>
+ <command name="glDrawElementsInstancedEXT"/>
+ <command name="glVertexAttribDivisorEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_light_texture" supported="gl">
+ <require>
+ <enum name="GL_FRAGMENT_MATERIAL_EXT"/>
+ <enum name="GL_FRAGMENT_NORMAL_EXT"/>
+ <enum name="GL_FRAGMENT_COLOR_EXT"/>
+ <enum name="GL_ATTENUATION_EXT"/>
+ <enum name="GL_SHADOW_ATTENUATION_EXT"/>
+ <enum name="GL_TEXTURE_APPLICATION_MODE_EXT"/>
+ <enum name="GL_TEXTURE_LIGHT_EXT"/>
+ <enum name="GL_TEXTURE_MATERIAL_FACE_EXT"/>
+ <enum name="GL_TEXTURE_MATERIAL_PARAMETER_EXT"/>
+ <enum name="GL_FRAGMENT_DEPTH_EXT"/>
+ <command name="glApplyTextureEXT"/>
+ <command name="glTextureLightEXT"/>
+ <command name="glTextureMaterialEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_map_buffer_range" supported="gles1|gles2">
+ <require>
+ <enum name="GL_MAP_READ_BIT_EXT"/>
+ <enum name="GL_MAP_WRITE_BIT_EXT"/>
+ <enum name="GL_MAP_INVALIDATE_RANGE_BIT_EXT"/>
+ <enum name="GL_MAP_INVALIDATE_BUFFER_BIT_EXT"/>
+ <enum name="GL_MAP_FLUSH_EXPLICIT_BIT_EXT"/>
+ <enum name="GL_MAP_UNSYNCHRONIZED_BIT_EXT"/>
+ <command name="glMapBufferRangeEXT"/>
+ <command name="glFlushMappedBufferRangeEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_misc_attribute" supported="gl"/>
+ <extension name="GL_EXT_multi_draw_arrays" supported="gl|gles1|gles2">
+ <require>
+ <command name="glMultiDrawArraysEXT"/>
+ <command name="glMultiDrawElementsEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_multisample" supported="gl">
+ <require>
+ <enum name="GL_MULTISAMPLE_EXT"/>
+ <enum name="GL_SAMPLE_ALPHA_TO_MASK_EXT"/>
+ <enum name="GL_SAMPLE_ALPHA_TO_ONE_EXT"/>
+ <enum name="GL_SAMPLE_MASK_EXT"/>
+ <enum name="GL_1PASS_EXT"/>
+ <enum name="GL_2PASS_0_EXT"/>
+ <enum name="GL_2PASS_1_EXT"/>
+ <enum name="GL_4PASS_0_EXT"/>
+ <enum name="GL_4PASS_1_EXT"/>
+ <enum name="GL_4PASS_2_EXT"/>
+ <enum name="GL_4PASS_3_EXT"/>
+ <enum name="GL_SAMPLE_BUFFERS_EXT"/>
+ <enum name="GL_SAMPLES_EXT"/>
+ <enum name="GL_SAMPLE_MASK_VALUE_EXT"/>
+ <enum name="GL_SAMPLE_MASK_INVERT_EXT"/>
+ <enum name="GL_SAMPLE_PATTERN_EXT"/>
+ <enum name="GL_MULTISAMPLE_BIT_EXT"/>
+ <command name="glSampleMaskEXT"/>
+ <command name="glSamplePatternEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_multisampled_render_to_texture" supported="gles1|gles2">
+ <require>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_SAMPLES_EXT"/>
+ <enum name="GL_RENDERBUFFER_SAMPLES_EXT"/>
+ <enum name="GL_FRAMEBUFFER_INCOMPLETE_MULTISAMPLE_EXT"/>
+ <enum name="GL_MAX_SAMPLES_EXT"/>
+ <command name="glRenderbufferStorageMultisampleEXT"/>
+ <command name="glFramebufferTexture2DMultisampleEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_multiview_draw_buffers" supported="gles2">
+ <require>
+ <enum name="GL_COLOR_ATTACHMENT_EXT"/>
+ <enum name="GL_MULTIVIEW_EXT"/>
+ <enum name="GL_DRAW_BUFFER_EXT"/>
+ <enum name="GL_READ_BUFFER_EXT"/>
+ <enum name="GL_MAX_MULTIVIEW_BUFFERS_EXT"/>
+ <command name="glReadBufferIndexedEXT"/>
+ <command name="glDrawBuffersIndexedEXT"/>
+ <command name="glGetIntegeri_vEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_occlusion_query_boolean" supported="gles2">
+ <require>
+ <enum name="GL_ANY_SAMPLES_PASSED_EXT"/>
+ <enum name="GL_ANY_SAMPLES_PASSED_CONSERVATIVE_EXT"/>
+ <enum name="GL_CURRENT_QUERY_EXT"/>
+ <enum name="GL_QUERY_RESULT_EXT"/>
+ <enum name="GL_QUERY_RESULT_AVAILABLE_EXT"/>
+ <command name="glGenQueriesEXT"/>
+ <command name="glDeleteQueriesEXT"/>
+ <command name="glIsQueryEXT"/>
+ <command name="glBeginQueryEXT"/>
+ <command name="glEndQueryEXT"/>
+ <command name="glGetQueryivEXT"/>
+ <command name="glGetQueryObjectuivEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_packed_depth_stencil" supported="gl">
+ <require>
+ <enum name="GL_DEPTH_STENCIL_EXT"/>
+ <enum name="GL_UNSIGNED_INT_24_8_EXT"/>
+ <enum name="GL_DEPTH24_STENCIL8_EXT"/>
+ <enum name="GL_TEXTURE_STENCIL_SIZE_EXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_packed_float" supported="gl">
+ <require>
+ <enum name="GL_R11F_G11F_B10F_EXT"/>
+ <enum name="GL_UNSIGNED_INT_10F_11F_11F_REV_EXT"/>
+ <enum name="GL_RGBA_SIGNED_COMPONENTS_EXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_packed_pixels" supported="gl">
+ <require>
+ <enum name="GL_UNSIGNED_BYTE_3_3_2_EXT"/>
+ <enum name="GL_UNSIGNED_SHORT_4_4_4_4_EXT"/>
+ <enum name="GL_UNSIGNED_SHORT_5_5_5_1_EXT"/>
+ <enum name="GL_UNSIGNED_INT_8_8_8_8_EXT"/>
+ <enum name="GL_UNSIGNED_INT_10_10_10_2_EXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_paletted_texture" supported="gl">
+ <require>
+ <enum name="GL_COLOR_INDEX1_EXT"/>
+ <enum name="GL_COLOR_INDEX2_EXT"/>
+ <enum name="GL_COLOR_INDEX4_EXT"/>
+ <enum name="GL_COLOR_INDEX8_EXT"/>
+ <enum name="GL_COLOR_INDEX12_EXT"/>
+ <enum name="GL_COLOR_INDEX16_EXT"/>
+ <enum name="GL_TEXTURE_INDEX_SIZE_EXT"/>
+ <command name="glColorTableEXT"/>
+ <command name="glGetColorTableEXT"/>
+ <command name="glGetColorTableParameterivEXT"/>
+ <command name="glGetColorTableParameterfvEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_pixel_buffer_object" supported="gl">
+ <require>
+ <enum name="GL_PIXEL_PACK_BUFFER_EXT"/>
+ <enum name="GL_PIXEL_UNPACK_BUFFER_EXT"/>
+ <enum name="GL_PIXEL_PACK_BUFFER_BINDING_EXT"/>
+ <enum name="GL_PIXEL_UNPACK_BUFFER_BINDING_EXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_pixel_transform" supported="gl">
+ <require>
+ <enum name="GL_PIXEL_TRANSFORM_2D_EXT"/>
+ <enum name="GL_PIXEL_MAG_FILTER_EXT"/>
+ <enum name="GL_PIXEL_MIN_FILTER_EXT"/>
+ <enum name="GL_PIXEL_CUBIC_WEIGHT_EXT"/>
+ <enum name="GL_CUBIC_EXT"/>
+ <enum name="GL_AVERAGE_EXT"/>
+ <enum name="GL_PIXEL_TRANSFORM_2D_STACK_DEPTH_EXT"/>
+ <enum name="GL_MAX_PIXEL_TRANSFORM_2D_STACK_DEPTH_EXT"/>
+ <enum name="GL_PIXEL_TRANSFORM_2D_MATRIX_EXT"/>
+ <command name="glPixelTransformParameteriEXT"/>
+ <command name="glPixelTransformParameterfEXT"/>
+ <command name="glPixelTransformParameterivEXT"/>
+ <command name="glPixelTransformParameterfvEXT"/>
+ <command name="glGetPixelTransformParameterivEXT"/>
+ <command name="glGetPixelTransformParameterfvEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_pixel_transform_color_table" supported="gl"/>
+ <extension name="GL_EXT_point_parameters" supported="gl">
+ <require>
+ <enum name="GL_POINT_SIZE_MIN_EXT"/>
+ <enum name="GL_POINT_SIZE_MAX_EXT"/>
+ <enum name="GL_POINT_FADE_THRESHOLD_SIZE_EXT"/>
+ <enum name="GL_DISTANCE_ATTENUATION_EXT"/>
+ <command name="glPointParameterfEXT"/>
+ <command name="glPointParameterfvEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_polygon_offset" supported="gl">
+ <require>
+ <enum name="GL_POLYGON_OFFSET_EXT"/>
+ <enum name="GL_POLYGON_OFFSET_FACTOR_EXT"/>
+ <enum name="GL_POLYGON_OFFSET_BIAS_EXT"/>
+ <command name="glPolygonOffsetEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_primitive_bounding_box" supported="gles2">
+ <require>
+ <enum name="GL_PRIMITIVE_BOUNDING_BOX_EXT"/>
+ <command name="glPrimitiveBoundingBoxEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_provoking_vertex" supported="gl">
+ <require>
+ <enum name="GL_QUADS_FOLLOW_PROVOKING_VERTEX_CONVENTION_EXT"/>
+ <enum name="GL_FIRST_VERTEX_CONVENTION_EXT"/>
+ <enum name="GL_LAST_VERTEX_CONVENTION_EXT"/>
+ <enum name="GL_PROVOKING_VERTEX_EXT"/>
+ <command name="glProvokingVertexEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_pvrtc_sRGB" supported="gles2">
+ <require>
+ <enum name="GL_COMPRESSED_SRGB_PVRTC_2BPPV1_EXT"/>
+ <enum name="GL_COMPRESSED_SRGB_PVRTC_4BPPV1_EXT"/>
+ <enum name="GL_COMPRESSED_SRGB_ALPHA_PVRTC_2BPPV1_EXT"/>
+ <enum name="GL_COMPRESSED_SRGB_ALPHA_PVRTC_4BPPV1_EXT"/>
+ <enum name="GL_COMPRESSED_SRGB_ALPHA_PVRTC_2BPPV2_IMG"/>
+ <enum name="GL_COMPRESSED_SRGB_ALPHA_PVRTC_4BPPV2_IMG"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_read_format_bgra" supported="gles1|gles2">
+ <require>
+ <enum name="GL_BGRA_EXT"/>
+ <enum name="GL_UNSIGNED_SHORT_4_4_4_4_REV_EXT"/>
+ <enum name="GL_UNSIGNED_SHORT_1_5_5_5_REV_EXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_rescale_normal" supported="gl">
+ <require>
+ <enum name="GL_RESCALE_NORMAL_EXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_robustness" supported="gles1|gles2">
+ <require>
+ <enum name="GL_NO_ERROR"/>
+ <enum name="GL_GUILTY_CONTEXT_RESET_EXT"/>
+ <enum name="GL_INNOCENT_CONTEXT_RESET_EXT"/>
+ <enum name="GL_UNKNOWN_CONTEXT_RESET_EXT"/>
+ <enum name="GL_CONTEXT_ROBUST_ACCESS_EXT"/>
+ <enum name="GL_RESET_NOTIFICATION_STRATEGY_EXT"/>
+ <enum name="GL_LOSE_CONTEXT_ON_RESET_EXT"/>
+ <enum name="GL_NO_RESET_NOTIFICATION_EXT"/>
+ <command name="glGetGraphicsResetStatusEXT"/>
+ <command name="glReadnPixelsEXT"/>
+ <command name="glGetnUniformfvEXT"/>
+ <command name="glGetnUniformivEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_sRGB" supported="gles1|gles2">
+ <require>
+ <enum name="GL_SRGB_EXT"/>
+ <enum name="GL_SRGB_ALPHA_EXT"/>
+ <enum name="GL_SRGB8_ALPHA8_EXT"/>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING_EXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_sRGB_write_control" supported="gles2">
+ <require>
+ <enum name="GL_FRAMEBUFFER_SRGB_EXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_secondary_color" supported="gl">
+ <require>
+ <enum name="GL_COLOR_SUM_EXT"/>
+ <enum name="GL_CURRENT_SECONDARY_COLOR_EXT"/>
+ <enum name="GL_SECONDARY_COLOR_ARRAY_SIZE_EXT"/>
+ <enum name="GL_SECONDARY_COLOR_ARRAY_TYPE_EXT"/>
+ <enum name="GL_SECONDARY_COLOR_ARRAY_STRIDE_EXT"/>
+ <enum name="GL_SECONDARY_COLOR_ARRAY_POINTER_EXT"/>
+ <enum name="GL_SECONDARY_COLOR_ARRAY_EXT"/>
+ <command name="glSecondaryColor3bEXT"/>
+ <command name="glSecondaryColor3bvEXT"/>
+ <command name="glSecondaryColor3dEXT"/>
+ <command name="glSecondaryColor3dvEXT"/>
+ <command name="glSecondaryColor3fEXT"/>
+ <command name="glSecondaryColor3fvEXT"/>
+ <command name="glSecondaryColor3iEXT"/>
+ <command name="glSecondaryColor3ivEXT"/>
+ <command name="glSecondaryColor3sEXT"/>
+ <command name="glSecondaryColor3svEXT"/>
+ <command name="glSecondaryColor3ubEXT"/>
+ <command name="glSecondaryColor3ubvEXT"/>
+ <command name="glSecondaryColor3uiEXT"/>
+ <command name="glSecondaryColor3uivEXT"/>
+ <command name="glSecondaryColor3usEXT"/>
+ <command name="glSecondaryColor3usvEXT"/>
+ <command name="glSecondaryColorPointerEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_separate_shader_objects" supported="gl|gles2">
+ <require api="gl" comment="The OpenGL version of this extension is completely unrelated to the OpenGL ES version">
+ <enum name="GL_ACTIVE_PROGRAM_EXT"/>
+ <command name="glUseShaderProgramEXT"/>
+ <command name="glActiveProgramEXT"/>
+ <command name="glCreateShaderProgramEXT"/>
+ </require>
+ <require api="gles2" comment="The OpenGL ES version of this extension is completely unrelated to the OpenGL version">
+ <enum name="GL_VERTEX_SHADER_BIT_EXT"/>
+ <enum name="GL_FRAGMENT_SHADER_BIT_EXT"/>
+ <enum name="GL_ALL_SHADER_BITS_EXT"/>
+ <enum name="GL_PROGRAM_SEPARABLE_EXT"/>
+ <enum name="GL_ACTIVE_PROGRAM_EXT"/>
+ <enum name="GL_PROGRAM_PIPELINE_BINDING_EXT"/>
+ <command name="glActiveShaderProgramEXT"/>
+ <command name="glBindProgramPipelineEXT"/>
+ <command name="glCreateShaderProgramvEXT"/>
+ <command name="glDeleteProgramPipelinesEXT"/>
+ <command name="glGenProgramPipelinesEXT"/>
+ <command name="glGetProgramPipelineInfoLogEXT"/>
+ <command name="glGetProgramPipelineivEXT"/>
+ <command name="glIsProgramPipelineEXT"/>
+ <command name="glProgramParameteriEXT"/>
+ <command name="glProgramUniform1fEXT"/>
+ <command name="glProgramUniform1fvEXT"/>
+ <command name="glProgramUniform1iEXT"/>
+ <command name="glProgramUniform1ivEXT"/>
+ <command name="glProgramUniform2fEXT"/>
+ <command name="glProgramUniform2fvEXT"/>
+ <command name="glProgramUniform2iEXT"/>
+ <command name="glProgramUniform2ivEXT"/>
+ <command name="glProgramUniform3fEXT"/>
+ <command name="glProgramUniform3fvEXT"/>
+ <command name="glProgramUniform3iEXT"/>
+ <command name="glProgramUniform3ivEXT"/>
+ <command name="glProgramUniform4fEXT"/>
+ <command name="glProgramUniform4fvEXT"/>
+ <command name="glProgramUniform4iEXT"/>
+ <command name="glProgramUniform4ivEXT"/>
+ <command name="glProgramUniformMatrix2fvEXT"/>
+ <command name="glProgramUniformMatrix3fvEXT"/>
+ <command name="glProgramUniformMatrix4fvEXT"/>
+ <command name="glUseProgramStagesEXT"/>
+ <command name="glValidateProgramPipelineEXT"/>
+ </require>
+ <require api="gles2" comment="Depends on OpenGL ES 3.0 or GL_NV_non_square_matrices">
+ <command name="glProgramUniform1uiEXT"/>
+ <command name="glProgramUniform2uiEXT"/>
+ <command name="glProgramUniform3uiEXT"/>
+ <command name="glProgramUniform4uiEXT"/>
+ <command name="glProgramUniform1uivEXT"/>
+ <command name="glProgramUniform2uivEXT"/>
+ <command name="glProgramUniform3uivEXT"/>
+ <command name="glProgramUniform4uivEXT"/>
+ <command name="glProgramUniformMatrix4fvEXT"/>
+ <command name="glProgramUniformMatrix2x3fvEXT"/>
+ <command name="glProgramUniformMatrix3x2fvEXT"/>
+ <command name="glProgramUniformMatrix2x4fvEXT"/>
+ <command name="glProgramUniformMatrix4x2fvEXT"/>
+ <command name="glProgramUniformMatrix3x4fvEXT"/>
+ <command name="glProgramUniformMatrix4x3fvEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_separate_specular_color" supported="gl">
+ <require>
+ <enum name="GL_LIGHT_MODEL_COLOR_CONTROL_EXT"/>
+ <enum name="GL_SINGLE_COLOR_EXT"/>
+ <enum name="GL_SEPARATE_SPECULAR_COLOR_EXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_shader_framebuffer_fetch" supported="gles2">
+ <require>
+ <enum name="GL_FRAGMENT_SHADER_DISCARDS_SAMPLES_EXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_shader_image_load_formatted" supported="gl"/>
+ <extension name="GL_EXT_shader_image_load_store" supported="gl">
+ <require>
+ <enum name="GL_MAX_IMAGE_UNITS_EXT"/>
+ <enum name="GL_MAX_COMBINED_IMAGE_UNITS_AND_FRAGMENT_OUTPUTS_EXT"/>
+ <enum name="GL_IMAGE_BINDING_NAME_EXT"/>
+ <enum name="GL_IMAGE_BINDING_LEVEL_EXT"/>
+ <enum name="GL_IMAGE_BINDING_LAYERED_EXT"/>
+ <enum name="GL_IMAGE_BINDING_LAYER_EXT"/>
+ <enum name="GL_IMAGE_BINDING_ACCESS_EXT"/>
+ <enum name="GL_IMAGE_1D_EXT"/>
+ <enum name="GL_IMAGE_2D_EXT"/>
+ <enum name="GL_IMAGE_3D_EXT"/>
+ <enum name="GL_IMAGE_2D_RECT_EXT"/>
+ <enum name="GL_IMAGE_CUBE_EXT"/>
+ <enum name="GL_IMAGE_BUFFER_EXT"/>
+ <enum name="GL_IMAGE_1D_ARRAY_EXT"/>
+ <enum name="GL_IMAGE_2D_ARRAY_EXT"/>
+ <enum name="GL_IMAGE_CUBE_MAP_ARRAY_EXT"/>
+ <enum name="GL_IMAGE_2D_MULTISAMPLE_EXT"/>
+ <enum name="GL_IMAGE_2D_MULTISAMPLE_ARRAY_EXT"/>
+ <enum name="GL_INT_IMAGE_1D_EXT"/>
+ <enum name="GL_INT_IMAGE_2D_EXT"/>
+ <enum name="GL_INT_IMAGE_3D_EXT"/>
+ <enum name="GL_INT_IMAGE_2D_RECT_EXT"/>
+ <enum name="GL_INT_IMAGE_CUBE_EXT"/>
+ <enum name="GL_INT_IMAGE_BUFFER_EXT"/>
+ <enum name="GL_INT_IMAGE_1D_ARRAY_EXT"/>
+ <enum name="GL_INT_IMAGE_2D_ARRAY_EXT"/>
+ <enum name="GL_INT_IMAGE_CUBE_MAP_ARRAY_EXT"/>
+ <enum name="GL_INT_IMAGE_2D_MULTISAMPLE_EXT"/>
+ <enum name="GL_INT_IMAGE_2D_MULTISAMPLE_ARRAY_EXT"/>
+ <enum name="GL_UNSIGNED_INT_IMAGE_1D_EXT"/>
+ <enum name="GL_UNSIGNED_INT_IMAGE_2D_EXT"/>
+ <enum name="GL_UNSIGNED_INT_IMAGE_3D_EXT"/>
+ <enum name="GL_UNSIGNED_INT_IMAGE_2D_RECT_EXT"/>
+ <enum name="GL_UNSIGNED_INT_IMAGE_CUBE_EXT"/>
+ <enum name="GL_UNSIGNED_INT_IMAGE_BUFFER_EXT"/>
+ <enum name="GL_UNSIGNED_INT_IMAGE_1D_ARRAY_EXT"/>
+ <enum name="GL_UNSIGNED_INT_IMAGE_2D_ARRAY_EXT"/>
+ <enum name="GL_UNSIGNED_INT_IMAGE_CUBE_MAP_ARRAY_EXT"/>
+ <enum name="GL_UNSIGNED_INT_IMAGE_2D_MULTISAMPLE_EXT"/>
+ <enum name="GL_UNSIGNED_INT_IMAGE_2D_MULTISAMPLE_ARRAY_EXT"/>
+ <enum name="GL_MAX_IMAGE_SAMPLES_EXT"/>
+ <enum name="GL_IMAGE_BINDING_FORMAT_EXT"/>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY_BARRIER_BIT_EXT"/>
+ <enum name="GL_ELEMENT_ARRAY_BARRIER_BIT_EXT"/>
+ <enum name="GL_UNIFORM_BARRIER_BIT_EXT"/>
+ <enum name="GL_TEXTURE_FETCH_BARRIER_BIT_EXT"/>
+ <enum name="GL_SHADER_IMAGE_ACCESS_BARRIER_BIT_EXT"/>
+ <enum name="GL_COMMAND_BARRIER_BIT_EXT"/>
+ <enum name="GL_PIXEL_BUFFER_BARRIER_BIT_EXT"/>
+ <enum name="GL_TEXTURE_UPDATE_BARRIER_BIT_EXT"/>
+ <enum name="GL_BUFFER_UPDATE_BARRIER_BIT_EXT"/>
+ <enum name="GL_FRAMEBUFFER_BARRIER_BIT_EXT"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_BARRIER_BIT_EXT"/>
+ <enum name="GL_ATOMIC_COUNTER_BARRIER_BIT_EXT"/>
+ <enum name="GL_ALL_BARRIER_BITS_EXT"/>
+ <command name="glBindImageTextureEXT"/>
+ <command name="glMemoryBarrierEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_shader_implicit_conversions" supported="gles2"/>
+ <extension name="GL_EXT_shader_integer_mix" supported="gl|gles2"/>
+ <extension name="GL_EXT_shader_io_blocks" supported="gles2"/>
+ <extension name="GL_EXT_shader_pixel_local_storage" supported="gles2">
+ <require>
+ <enum name="GL_MAX_SHADER_PIXEL_LOCAL_STORAGE_FAST_SIZE_EXT"/>
+ <enum name="GL_MAX_SHADER_PIXEL_LOCAL_STORAGE_SIZE_EXT"/>
+ <enum name="GL_SHADER_PIXEL_LOCAL_STORAGE_EXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_shader_texture_lod" supported="gles2"/>
+ <extension name="GL_EXT_shadow_funcs" supported="gl"/>
+ <extension name="GL_EXT_shadow_samplers" supported="gles2">
+ <require>
+ <enum name="GL_TEXTURE_COMPARE_MODE_EXT"/>
+ <enum name="GL_TEXTURE_COMPARE_FUNC_EXT"/>
+ <enum name="GL_COMPARE_REF_TO_TEXTURE_EXT"/>
+ <enum name="GL_SAMPLER_2D_SHADOW_EXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_shared_texture_palette" supported="gl">
+ <require>
+ <enum name="GL_SHARED_TEXTURE_PALETTE_EXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_stencil_clear_tag" supported="gl">
+ <require>
+ <enum name="GL_STENCIL_TAG_BITS_EXT"/>
+ <enum name="GL_STENCIL_CLEAR_TAG_VALUE_EXT"/>
+ <command name="glStencilClearTagEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_stencil_two_side" supported="gl">
+ <require>
+ <enum name="GL_STENCIL_TEST_TWO_SIDE_EXT"/>
+ <enum name="GL_ACTIVE_STENCIL_FACE_EXT"/>
+ <command name="glActiveStencilFaceEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_stencil_wrap" supported="gl">
+ <require>
+ <enum name="GL_INCR_WRAP_EXT"/>
+ <enum name="GL_DECR_WRAP_EXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_subtexture" supported="gl">
+ <require>
+ <command name="glTexSubImage1DEXT"/>
+ <command name="glTexSubImage2DEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_tessellation_point_size" supported="gles2"/>
+ <extension name="GL_EXT_tessellation_shader" supported="gles2">
+ <require>
+ <enum name="GL_PATCHES_EXT"/>
+ <enum name="GL_PATCH_VERTICES_EXT"/>
+ <enum name="GL_TESS_CONTROL_OUTPUT_VERTICES_EXT"/>
+ <enum name="GL_TESS_GEN_MODE_EXT"/>
+ <enum name="GL_TESS_GEN_SPACING_EXT"/>
+ <enum name="GL_TESS_GEN_VERTEX_ORDER_EXT"/>
+ <enum name="GL_TESS_GEN_POINT_MODE_EXT"/>
+ <enum name="GL_TRIANGLES"/>
+ <enum name="GL_ISOLINES_EXT"/>
+ <enum name="GL_QUADS_EXT"/>
+ <enum name="GL_EQUAL"/>
+ <enum name="GL_FRACTIONAL_ODD_EXT"/>
+ <enum name="GL_FRACTIONAL_EVEN_EXT"/>
+ <enum name="GL_CCW"/>
+ <enum name="GL_CW"/>
+ <enum name="GL_MAX_PATCH_VERTICES_EXT"/>
+ <enum name="GL_MAX_TESS_GEN_LEVEL_EXT"/>
+ <enum name="GL_MAX_TESS_CONTROL_UNIFORM_COMPONENTS_EXT"/>
+ <enum name="GL_MAX_TESS_EVALUATION_UNIFORM_COMPONENTS_EXT"/>
+ <enum name="GL_MAX_TESS_CONTROL_TEXTURE_IMAGE_UNITS_EXT"/>
+ <enum name="GL_MAX_TESS_EVALUATION_TEXTURE_IMAGE_UNITS_EXT"/>
+ <enum name="GL_MAX_TESS_CONTROL_OUTPUT_COMPONENTS_EXT"/>
+ <enum name="GL_MAX_TESS_PATCH_COMPONENTS_EXT"/>
+ <enum name="GL_MAX_TESS_CONTROL_TOTAL_OUTPUT_COMPONENTS_EXT"/>
+ <enum name="GL_MAX_TESS_EVALUATION_OUTPUT_COMPONENTS_EXT"/>
+ <enum name="GL_MAX_TESS_CONTROL_UNIFORM_BLOCKS_EXT"/>
+ <enum name="GL_MAX_TESS_EVALUATION_UNIFORM_BLOCKS_EXT"/>
+ <enum name="GL_MAX_TESS_CONTROL_INPUT_COMPONENTS_EXT"/>
+ <enum name="GL_MAX_TESS_EVALUATION_INPUT_COMPONENTS_EXT"/>
+ <enum name="GL_MAX_COMBINED_TESS_CONTROL_UNIFORM_COMPONENTS_EXT"/>
+ <enum name="GL_MAX_COMBINED_TESS_EVALUATION_UNIFORM_COMPONENTS_EXT"/>
+ <enum name="GL_MAX_TESS_CONTROL_ATOMIC_COUNTER_BUFFERS_EXT"/>
+ <enum name="GL_MAX_TESS_EVALUATION_ATOMIC_COUNTER_BUFFERS_EXT"/>
+ <enum name="GL_MAX_TESS_CONTROL_ATOMIC_COUNTERS_EXT"/>
+ <enum name="GL_MAX_TESS_EVALUATION_ATOMIC_COUNTERS_EXT"/>
+ <enum name="GL_MAX_TESS_CONTROL_IMAGE_UNIFORMS_EXT"/>
+ <enum name="GL_MAX_TESS_EVALUATION_IMAGE_UNIFORMS_EXT"/>
+ <enum name="GL_MAX_TESS_CONTROL_SHADER_STORAGE_BLOCKS_EXT"/>
+ <enum name="GL_MAX_TESS_EVALUATION_SHADER_STORAGE_BLOCKS_EXT"/>
+ <enum name="GL_PRIMITIVE_RESTART_FOR_PATCHES_SUPPORTED"/>
+ <enum name="GL_IS_PER_PATCH_EXT"/>
+ <enum name="GL_REFERENCED_BY_TESS_CONTROL_SHADER_EXT"/>
+ <enum name="GL_REFERENCED_BY_TESS_EVALUATION_SHADER_EXT"/>
+ <enum name="GL_TESS_CONTROL_SHADER_EXT"/>
+ <enum name="GL_TESS_EVALUATION_SHADER_EXT"/>
+ <enum name="GL_TESS_CONTROL_SHADER_BIT_EXT"/>
+ <enum name="GL_TESS_EVALUATION_SHADER_BIT_EXT"/>
+ <command name="glPatchParameteriEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_texture" supported="gl">
+ <require>
+ <enum name="GL_ALPHA4_EXT"/>
+ <enum name="GL_ALPHA8_EXT"/>
+ <enum name="GL_ALPHA12_EXT"/>
+ <enum name="GL_ALPHA16_EXT"/>
+ <enum name="GL_LUMINANCE4_EXT"/>
+ <enum name="GL_LUMINANCE8_EXT"/>
+ <enum name="GL_LUMINANCE12_EXT"/>
+ <enum name="GL_LUMINANCE16_EXT"/>
+ <enum name="GL_LUMINANCE4_ALPHA4_EXT"/>
+ <enum name="GL_LUMINANCE6_ALPHA2_EXT"/>
+ <enum name="GL_LUMINANCE8_ALPHA8_EXT"/>
+ <enum name="GL_LUMINANCE12_ALPHA4_EXT"/>
+ <enum name="GL_LUMINANCE12_ALPHA12_EXT"/>
+ <enum name="GL_LUMINANCE16_ALPHA16_EXT"/>
+ <enum name="GL_INTENSITY_EXT"/>
+ <enum name="GL_INTENSITY4_EXT"/>
+ <enum name="GL_INTENSITY8_EXT"/>
+ <enum name="GL_INTENSITY12_EXT"/>
+ <enum name="GL_INTENSITY16_EXT"/>
+ <enum name="GL_RGB2_EXT"/>
+ <enum name="GL_RGB4_EXT"/>
+ <enum name="GL_RGB5_EXT"/>
+ <enum name="GL_RGB8_EXT"/>
+ <enum name="GL_RGB10_EXT"/>
+ <enum name="GL_RGB12_EXT"/>
+ <enum name="GL_RGB16_EXT"/>
+ <enum name="GL_RGBA2_EXT"/>
+ <enum name="GL_RGBA4_EXT"/>
+ <enum name="GL_RGB5_A1_EXT"/>
+ <enum name="GL_RGBA8_EXT"/>
+ <enum name="GL_RGB10_A2_EXT"/>
+ <enum name="GL_RGBA12_EXT"/>
+ <enum name="GL_RGBA16_EXT"/>
+ <enum name="GL_TEXTURE_RED_SIZE_EXT"/>
+ <enum name="GL_TEXTURE_GREEN_SIZE_EXT"/>
+ <enum name="GL_TEXTURE_BLUE_SIZE_EXT"/>
+ <enum name="GL_TEXTURE_ALPHA_SIZE_EXT"/>
+ <enum name="GL_TEXTURE_LUMINANCE_SIZE_EXT"/>
+ <enum name="GL_TEXTURE_INTENSITY_SIZE_EXT"/>
+ <enum name="GL_REPLACE_EXT"/>
+ <enum name="GL_PROXY_TEXTURE_1D_EXT"/>
+ <enum name="GL_PROXY_TEXTURE_2D_EXT"/>
+ <enum name="GL_TEXTURE_TOO_LARGE_EXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_texture3D" supported="gl">
+ <require>
+ <enum name="GL_PACK_SKIP_IMAGES_EXT"/>
+ <enum name="GL_PACK_IMAGE_HEIGHT_EXT"/>
+ <enum name="GL_UNPACK_SKIP_IMAGES_EXT"/>
+ <enum name="GL_UNPACK_IMAGE_HEIGHT_EXT"/>
+ <enum name="GL_TEXTURE_3D_EXT"/>
+ <enum name="GL_PROXY_TEXTURE_3D_EXT"/>
+ <enum name="GL_TEXTURE_DEPTH_EXT"/>
+ <enum name="GL_TEXTURE_WRAP_R_EXT"/>
+ <enum name="GL_MAX_3D_TEXTURE_SIZE_EXT"/>
+ <command name="glTexImage3DEXT"/>
+ <command name="glTexSubImage3DEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_texture_array" supported="gl">
+ <require>
+ <enum name="GL_TEXTURE_1D_ARRAY_EXT"/>
+ <enum name="GL_PROXY_TEXTURE_1D_ARRAY_EXT"/>
+ <enum name="GL_TEXTURE_2D_ARRAY_EXT"/>
+ <enum name="GL_PROXY_TEXTURE_2D_ARRAY_EXT"/>
+ <enum name="GL_TEXTURE_BINDING_1D_ARRAY_EXT"/>
+ <enum name="GL_TEXTURE_BINDING_2D_ARRAY_EXT"/>
+ <enum name="GL_MAX_ARRAY_TEXTURE_LAYERS_EXT"/>
+ <enum name="GL_COMPARE_REF_DEPTH_TO_TEXTURE_EXT"/>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER_EXT"/>
+ <command name="glFramebufferTextureLayerEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_texture_border_clamp" supported="gles2">
+ <require>
+ <enum name="GL_TEXTURE_BORDER_COLOR_EXT"/>
+ <enum name="GL_CLAMP_TO_BORDER_EXT"/>
+ <command name="glTexParameterIivEXT"/>
+ <command name="glTexParameterIuivEXT"/>
+ <command name="glGetTexParameterIivEXT"/>
+ <command name="glGetTexParameterIuivEXT"/>
+ <command name="glSamplerParameterIivEXT"/>
+ <command name="glSamplerParameterIuivEXT"/>
+ <command name="glGetSamplerParameterIivEXT"/>
+ <command name="glGetSamplerParameterIuivEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_texture_buffer" supported="gles2">
+ <require>
+ <enum name="GL_TEXTURE_BUFFER_EXT"/>
+ <enum name="GL_TEXTURE_BUFFER_BINDING_EXT"/>
+ <enum name="GL_MAX_TEXTURE_BUFFER_SIZE_EXT"/>
+ <enum name="GL_TEXTURE_BINDING_BUFFER_EXT"/>
+ <enum name="GL_TEXTURE_BUFFER_DATA_STORE_BINDING_EXT"/>
+ <enum name="GL_TEXTURE_BUFFER_OFFSET_ALIGNMENT_EXT"/>
+ <enum name="GL_SAMPLER_BUFFER_EXT"/>
+ <enum name="GL_INT_SAMPLER_BUFFER_EXT"/>
+ <enum name="GL_UNSIGNED_INT_SAMPLER_BUFFER_EXT"/>
+ <enum name="GL_IMAGE_BUFFER_EXT"/>
+ <enum name="GL_INT_IMAGE_BUFFER_EXT"/>
+ <enum name="GL_UNSIGNED_INT_IMAGE_BUFFER_EXT"/>
+ <enum name="GL_TEXTURE_BUFFER_OFFSET_EXT"/>
+ <enum name="GL_TEXTURE_BUFFER_SIZE_EXT"/>
+ <command name="glTexBufferEXT"/>
+ <command name="glTexBufferRangeEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_texture_buffer_object" supported="gl">
+ <require>
+ <enum name="GL_TEXTURE_BUFFER_EXT"/>
+ <enum name="GL_MAX_TEXTURE_BUFFER_SIZE_EXT"/>
+ <enum name="GL_TEXTURE_BINDING_BUFFER_EXT"/>
+ <enum name="GL_TEXTURE_BUFFER_DATA_STORE_BINDING_EXT"/>
+ <enum name="GL_TEXTURE_BUFFER_FORMAT_EXT"/>
+ <command name="glTexBufferEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_texture_compression_dxt1" supported="gles1|gles2">
+ <require>
+ <enum name="GL_COMPRESSED_RGB_S3TC_DXT1_EXT"/>
+ <enum name="GL_COMPRESSED_RGBA_S3TC_DXT1_EXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_texture_compression_latc" supported="gl">
+ <require>
+ <enum name="GL_COMPRESSED_LUMINANCE_LATC1_EXT"/>
+ <enum name="GL_COMPRESSED_SIGNED_LUMINANCE_LATC1_EXT"/>
+ <enum name="GL_COMPRESSED_LUMINANCE_ALPHA_LATC2_EXT"/>
+ <enum name="GL_COMPRESSED_SIGNED_LUMINANCE_ALPHA_LATC2_EXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_texture_compression_rgtc" supported="gl">
+ <require>
+ <enum name="GL_COMPRESSED_RED_RGTC1_EXT"/>
+ <enum name="GL_COMPRESSED_SIGNED_RED_RGTC1_EXT"/>
+ <enum name="GL_COMPRESSED_RED_GREEN_RGTC2_EXT"/>
+ <enum name="GL_COMPRESSED_SIGNED_RED_GREEN_RGTC2_EXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_texture_compression_s3tc" supported="gl|gles2">
+ <require>
+ <enum name="GL_COMPRESSED_RGB_S3TC_DXT1_EXT"/>
+ <enum name="GL_COMPRESSED_RGBA_S3TC_DXT1_EXT"/>
+ <enum name="GL_COMPRESSED_RGBA_S3TC_DXT3_EXT"/>
+ <enum name="GL_COMPRESSED_RGBA_S3TC_DXT5_EXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_texture_cube_map" supported="gl" comment="Replaced by ARB_texture_cube_map, but was apparently shipped anyway?">
+ <require>
+ <enum name="GL_NORMAL_MAP_EXT"/>
+ <enum name="GL_REFLECTION_MAP_EXT"/>
+ <enum name="GL_TEXTURE_CUBE_MAP_EXT"/>
+ <enum name="GL_TEXTURE_BINDING_CUBE_MAP_EXT"/>
+ <enum name="GL_TEXTURE_CUBE_MAP_POSITIVE_X_EXT"/>
+ <enum name="GL_TEXTURE_CUBE_MAP_NEGATIVE_X_EXT"/>
+ <enum name="GL_TEXTURE_CUBE_MAP_POSITIVE_Y_EXT"/>
+ <enum name="GL_TEXTURE_CUBE_MAP_NEGATIVE_Y_EXT"/>
+ <enum name="GL_TEXTURE_CUBE_MAP_POSITIVE_Z_EXT"/>
+ <enum name="GL_TEXTURE_CUBE_MAP_NEGATIVE_Z_EXT"/>
+ <enum name="GL_PROXY_TEXTURE_CUBE_MAP_EXT"/>
+ <enum name="GL_MAX_CUBE_MAP_TEXTURE_SIZE_EXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_texture_cube_map_array" supported="gles2">
+ <require>
+ <enum name="GL_TEXTURE_CUBE_MAP_ARRAY_EXT"/>
+ <enum name="GL_TEXTURE_BINDING_CUBE_MAP_ARRAY_EXT"/>
+ <enum name="GL_SAMPLER_CUBE_MAP_ARRAY_EXT"/>
+ <enum name="GL_SAMPLER_CUBE_MAP_ARRAY_SHADOW_EXT"/>
+ <enum name="GL_INT_SAMPLER_CUBE_MAP_ARRAY_EXT"/>
+ <enum name="GL_UNSIGNED_INT_SAMPLER_CUBE_MAP_ARRAY_EXT"/>
+ <enum name="GL_IMAGE_CUBE_MAP_ARRAY_EXT"/>
+ <enum name="GL_INT_IMAGE_CUBE_MAP_ARRAY_EXT"/>
+ <enum name="GL_UNSIGNED_INT_IMAGE_CUBE_MAP_ARRAY_EXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_texture_env_add" supported="gl"/>
+ <extension name="GL_EXT_texture_env_combine" supported="gl">
+ <require>
+ <enum name="GL_COMBINE_EXT"/>
+ <enum name="GL_COMBINE_RGB_EXT"/>
+ <enum name="GL_COMBINE_ALPHA_EXT"/>
+ <enum name="GL_RGB_SCALE_EXT"/>
+ <enum name="GL_ADD_SIGNED_EXT"/>
+ <enum name="GL_INTERPOLATE_EXT"/>
+ <enum name="GL_CONSTANT_EXT"/>
+ <enum name="GL_PRIMARY_COLOR_EXT"/>
+ <enum name="GL_PREVIOUS_EXT"/>
+ <enum name="GL_SOURCE0_RGB_EXT"/>
+ <enum name="GL_SOURCE1_RGB_EXT"/>
+ <enum name="GL_SOURCE2_RGB_EXT"/>
+ <enum name="GL_SOURCE0_ALPHA_EXT"/>
+ <enum name="GL_SOURCE1_ALPHA_EXT"/>
+ <enum name="GL_SOURCE2_ALPHA_EXT"/>
+ <enum name="GL_OPERAND0_RGB_EXT"/>
+ <enum name="GL_OPERAND1_RGB_EXT"/>
+ <enum name="GL_OPERAND2_RGB_EXT"/>
+ <enum name="GL_OPERAND0_ALPHA_EXT"/>
+ <enum name="GL_OPERAND1_ALPHA_EXT"/>
+ <enum name="GL_OPERAND2_ALPHA_EXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_texture_env_dot3" supported="gl">
+ <require>
+ <enum name="GL_DOT3_RGB_EXT"/>
+ <enum name="GL_DOT3_RGBA_EXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_texture_filter_anisotropic" supported="gl|gles1|gles2">
+ <require>
+ <enum name="GL_TEXTURE_MAX_ANISOTROPY_EXT"/>
+ <enum name="GL_MAX_TEXTURE_MAX_ANISOTROPY_EXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_texture_format_BGRA8888" supported="gles1|gles2">
+ <require>
+ <enum name="GL_BGRA_EXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_texture_integer" supported="gl">
+ <require>
+ <enum name="GL_RGBA32UI_EXT"/>
+ <enum name="GL_RGB32UI_EXT"/>
+ <enum name="GL_ALPHA32UI_EXT"/>
+ <enum name="GL_INTENSITY32UI_EXT"/>
+ <enum name="GL_LUMINANCE32UI_EXT"/>
+ <enum name="GL_LUMINANCE_ALPHA32UI_EXT"/>
+ <enum name="GL_RGBA16UI_EXT"/>
+ <enum name="GL_RGB16UI_EXT"/>
+ <enum name="GL_ALPHA16UI_EXT"/>
+ <enum name="GL_INTENSITY16UI_EXT"/>
+ <enum name="GL_LUMINANCE16UI_EXT"/>
+ <enum name="GL_LUMINANCE_ALPHA16UI_EXT"/>
+ <enum name="GL_RGBA8UI_EXT"/>
+ <enum name="GL_RGB8UI_EXT"/>
+ <enum name="GL_ALPHA8UI_EXT"/>
+ <enum name="GL_INTENSITY8UI_EXT"/>
+ <enum name="GL_LUMINANCE8UI_EXT"/>
+ <enum name="GL_LUMINANCE_ALPHA8UI_EXT"/>
+ <enum name="GL_RGBA32I_EXT"/>
+ <enum name="GL_RGB32I_EXT"/>
+ <enum name="GL_ALPHA32I_EXT"/>
+ <enum name="GL_INTENSITY32I_EXT"/>
+ <enum name="GL_LUMINANCE32I_EXT"/>
+ <enum name="GL_LUMINANCE_ALPHA32I_EXT"/>
+ <enum name="GL_RGBA16I_EXT"/>
+ <enum name="GL_RGB16I_EXT"/>
+ <enum name="GL_ALPHA16I_EXT"/>
+ <enum name="GL_INTENSITY16I_EXT"/>
+ <enum name="GL_LUMINANCE16I_EXT"/>
+ <enum name="GL_LUMINANCE_ALPHA16I_EXT"/>
+ <enum name="GL_RGBA8I_EXT"/>
+ <enum name="GL_RGB8I_EXT"/>
+ <enum name="GL_ALPHA8I_EXT"/>
+ <enum name="GL_INTENSITY8I_EXT"/>
+ <enum name="GL_LUMINANCE8I_EXT"/>
+ <enum name="GL_LUMINANCE_ALPHA8I_EXT"/>
+ <enum name="GL_RED_INTEGER_EXT"/>
+ <enum name="GL_GREEN_INTEGER_EXT"/>
+ <enum name="GL_BLUE_INTEGER_EXT"/>
+ <enum name="GL_ALPHA_INTEGER_EXT"/>
+ <enum name="GL_RGB_INTEGER_EXT"/>
+ <enum name="GL_RGBA_INTEGER_EXT"/>
+ <enum name="GL_BGR_INTEGER_EXT"/>
+ <enum name="GL_BGRA_INTEGER_EXT"/>
+ <enum name="GL_LUMINANCE_INTEGER_EXT"/>
+ <enum name="GL_LUMINANCE_ALPHA_INTEGER_EXT"/>
+ <enum name="GL_RGBA_INTEGER_MODE_EXT"/>
+ <command name="glTexParameterIivEXT"/>
+ <command name="glTexParameterIuivEXT"/>
+ <command name="glGetTexParameterIivEXT"/>
+ <command name="glGetTexParameterIuivEXT"/>
+ <command name="glClearColorIiEXT"/>
+ <command name="glClearColorIuiEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_texture_lod_bias" supported="gl|gles1">
+ <require>
+ <enum name="GL_MAX_TEXTURE_LOD_BIAS_EXT"/>
+ <enum name="GL_TEXTURE_FILTER_CONTROL_EXT"/>
+ <enum name="GL_TEXTURE_LOD_BIAS_EXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_texture_mirror_clamp" supported="gl">
+ <require>
+ <enum name="GL_MIRROR_CLAMP_EXT"/>
+ <enum name="GL_MIRROR_CLAMP_TO_EDGE_EXT"/>
+ <enum name="GL_MIRROR_CLAMP_TO_BORDER_EXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_texture_object" supported="gl">
+ <require>
+ <enum name="GL_TEXTURE_PRIORITY_EXT"/>
+ <enum name="GL_TEXTURE_RESIDENT_EXT"/>
+ <enum name="GL_TEXTURE_1D_BINDING_EXT"/>
+ <enum name="GL_TEXTURE_2D_BINDING_EXT"/>
+ <enum name="GL_TEXTURE_3D_BINDING_EXT"/>
+ <command name="glAreTexturesResidentEXT"/>
+ <command name="glBindTextureEXT"/>
+ <command name="glDeleteTexturesEXT"/>
+ <command name="glGenTexturesEXT"/>
+ <command name="glIsTextureEXT"/>
+ <command name="glPrioritizeTexturesEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_texture_perturb_normal" supported="gl">
+ <require>
+ <enum name="GL_PERTURB_EXT"/>
+ <enum name="GL_TEXTURE_NORMAL_EXT"/>
+ <command name="glTextureNormalEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_texture_rg" supported="gles2">
+ <require>
+ <enum name="GL_RED_EXT"/>
+ <enum name="GL_RG_EXT"/>
+ <enum name="GL_R8_EXT"/>
+ <enum name="GL_RG8_EXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_texture_sRGB" supported="gl">
+ <require>
+ <enum name="GL_SRGB_EXT"/>
+ <enum name="GL_SRGB8_EXT"/>
+ <enum name="GL_SRGB_ALPHA_EXT"/>
+ <enum name="GL_SRGB8_ALPHA8_EXT"/>
+ <enum name="GL_SLUMINANCE_ALPHA_EXT"/>
+ <enum name="GL_SLUMINANCE8_ALPHA8_EXT"/>
+ <enum name="GL_SLUMINANCE_EXT"/>
+ <enum name="GL_SLUMINANCE8_EXT"/>
+ <enum name="GL_COMPRESSED_SRGB_EXT"/>
+ <enum name="GL_COMPRESSED_SRGB_ALPHA_EXT"/>
+ <enum name="GL_COMPRESSED_SLUMINANCE_EXT"/>
+ <enum name="GL_COMPRESSED_SLUMINANCE_ALPHA_EXT"/>
+ <enum name="GL_COMPRESSED_SRGB_S3TC_DXT1_EXT"/>
+ <enum name="GL_COMPRESSED_SRGB_ALPHA_S3TC_DXT1_EXT"/>
+ <enum name="GL_COMPRESSED_SRGB_ALPHA_S3TC_DXT3_EXT"/>
+ <enum name="GL_COMPRESSED_SRGB_ALPHA_S3TC_DXT5_EXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_texture_sRGB_decode" supported="gl|gles2">
+ <require>
+ <enum name="GL_TEXTURE_SRGB_DECODE_EXT"/>
+ <enum name="GL_DECODE_EXT"/>
+ <enum name="GL_SKIP_DECODE_EXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_texture_shared_exponent" supported="gl">
+ <require>
+ <enum name="GL_RGB9_E5_EXT"/>
+ <enum name="GL_UNSIGNED_INT_5_9_9_9_REV_EXT"/>
+ <enum name="GL_TEXTURE_SHARED_SIZE_EXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_texture_snorm" supported="gl">
+ <require>
+ <enum name="GL_ALPHA_SNORM"/>
+ <enum name="GL_LUMINANCE_SNORM"/>
+ <enum name="GL_LUMINANCE_ALPHA_SNORM"/>
+ <enum name="GL_INTENSITY_SNORM"/>
+ <enum name="GL_ALPHA8_SNORM"/>
+ <enum name="GL_LUMINANCE8_SNORM"/>
+ <enum name="GL_LUMINANCE8_ALPHA8_SNORM"/>
+ <enum name="GL_INTENSITY8_SNORM"/>
+ <enum name="GL_ALPHA16_SNORM"/>
+ <enum name="GL_LUMINANCE16_SNORM"/>
+ <enum name="GL_LUMINANCE16_ALPHA16_SNORM"/>
+ <enum name="GL_INTENSITY16_SNORM"/>
+ <enum name="GL_RED_SNORM"/>
+ <enum name="GL_RG_SNORM"/>
+ <enum name="GL_RGB_SNORM"/>
+ <enum name="GL_RGBA_SNORM"/>
+ <enum name="GL_R8_SNORM"/>
+ <enum name="GL_RG8_SNORM"/>
+ <enum name="GL_RGB8_SNORM"/>
+ <enum name="GL_RGBA8_SNORM"/>
+ <enum name="GL_R16_SNORM"/>
+ <enum name="GL_RG16_SNORM"/>
+ <enum name="GL_RGB16_SNORM"/>
+ <enum name="GL_RGBA16_SNORM"/>
+ <enum name="GL_SIGNED_NORMALIZED"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_texture_storage" supported="gles1|gles2">
+ <require comment="Not clear all of these enums should be here for OpenGL ES. Many are only defined if other extensions also requiring them are supported">
+ <enum name="GL_TEXTURE_IMMUTABLE_FORMAT_EXT"/>
+ <enum name="GL_ALPHA8_EXT"/>
+ <enum name="GL_LUMINANCE8_EXT"/>
+ <enum name="GL_LUMINANCE8_ALPHA8_EXT"/>
+ <enum name="GL_RGBA32F_EXT"/>
+ <enum name="GL_RGB32F_EXT"/>
+ <enum name="GL_ALPHA32F_EXT"/>
+ <enum name="GL_LUMINANCE32F_EXT"/>
+ <enum name="GL_LUMINANCE_ALPHA32F_EXT"/>
+ <enum name="GL_RGBA16F_EXT"/>
+ <enum name="GL_RGB16F_EXT"/>
+ <enum name="GL_ALPHA16F_EXT"/>
+ <enum name="GL_LUMINANCE16F_EXT"/>
+ <enum name="GL_LUMINANCE_ALPHA16F_EXT"/>
+ <enum name="GL_RGB10_A2_EXT"/>
+ <enum name="GL_RGB10_EXT"/>
+ <enum name="GL_BGRA8_EXT"/>
+ <enum name="GL_R8_EXT"/>
+ <enum name="GL_RG8_EXT"/>
+ <enum name="GL_R32F_EXT"/>
+ <enum name="GL_RG32F_EXT"/>
+ <enum name="GL_R16F_EXT"/>
+ <enum name="GL_RG16F_EXT"/>
+ <command name="glTexStorage1DEXT"/>
+ <command name="glTexStorage2DEXT"/>
+ <command name="glTexStorage3DEXT"/>
+ </require>
+ <require comment="Supported only if GL_EXT_direct_state_access is supported">
+ <command name="glTextureStorage1DEXT"/>
+ <command name="glTextureStorage2DEXT"/>
+ <command name="glTextureStorage3DEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_texture_swizzle" supported="gl">
+ <require>
+ <enum name="GL_TEXTURE_SWIZZLE_R_EXT"/>
+ <enum name="GL_TEXTURE_SWIZZLE_G_EXT"/>
+ <enum name="GL_TEXTURE_SWIZZLE_B_EXT"/>
+ <enum name="GL_TEXTURE_SWIZZLE_A_EXT"/>
+ <enum name="GL_TEXTURE_SWIZZLE_RGBA_EXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_texture_type_2_10_10_10_REV" supported="gles2">
+ <require>
+ <enum name="GL_UNSIGNED_INT_2_10_10_10_REV_EXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_texture_view" supported="gles2">
+ <require>
+ <enum name="GL_TEXTURE_VIEW_MIN_LEVEL_EXT"/>
+ <enum name="GL_TEXTURE_VIEW_NUM_LEVELS_EXT"/>
+ <enum name="GL_TEXTURE_VIEW_MIN_LAYER_EXT"/>
+ <enum name="GL_TEXTURE_VIEW_NUM_LAYERS_EXT"/>
+ <enum name="GL_TEXTURE_IMMUTABLE_LEVELS"/>
+ <command name="glTextureViewEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_timer_query" supported="gl">
+ <require>
+ <enum name="GL_TIME_ELAPSED_EXT"/>
+ <command name="glGetQueryObjecti64vEXT"/>
+ <command name="glGetQueryObjectui64vEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_transform_feedback" supported="gl">
+ <require>
+ <enum name="GL_TRANSFORM_FEEDBACK_BUFFER_EXT"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_BUFFER_START_EXT"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_BUFFER_SIZE_EXT"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_BUFFER_BINDING_EXT"/>
+ <enum name="GL_INTERLEAVED_ATTRIBS_EXT"/>
+ <enum name="GL_SEPARATE_ATTRIBS_EXT"/>
+ <enum name="GL_PRIMITIVES_GENERATED_EXT"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN_EXT"/>
+ <enum name="GL_RASTERIZER_DISCARD_EXT"/>
+ <enum name="GL_MAX_TRANSFORM_FEEDBACK_INTERLEAVED_COMPONENTS_EXT"/>
+ <enum name="GL_MAX_TRANSFORM_FEEDBACK_SEPARATE_ATTRIBS_EXT"/>
+ <enum name="GL_MAX_TRANSFORM_FEEDBACK_SEPARATE_COMPONENTS_EXT"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_VARYINGS_EXT"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_BUFFER_MODE_EXT"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_VARYING_MAX_LENGTH_EXT"/>
+ <command name="glBeginTransformFeedbackEXT"/>
+ <command name="glEndTransformFeedbackEXT"/>
+ <command name="glBindBufferRangeEXT"/>
+ <command name="glBindBufferOffsetEXT"/>
+ <command name="glBindBufferBaseEXT"/>
+ <command name="glTransformFeedbackVaryingsEXT"/>
+ <command name="glGetTransformFeedbackVaryingEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_unpack_subimage" supported="gles2">
+ <require>
+ <enum name="GL_UNPACK_ROW_LENGTH_EXT"/>
+ <enum name="GL_UNPACK_SKIP_ROWS_EXT"/>
+ <enum name="GL_UNPACK_SKIP_PIXELS_EXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_vertex_array" supported="gl">
+ <require>
+ <enum name="GL_VERTEX_ARRAY_EXT"/>
+ <enum name="GL_NORMAL_ARRAY_EXT"/>
+ <enum name="GL_COLOR_ARRAY_EXT"/>
+ <enum name="GL_INDEX_ARRAY_EXT"/>
+ <enum name="GL_TEXTURE_COORD_ARRAY_EXT"/>
+ <enum name="GL_EDGE_FLAG_ARRAY_EXT"/>
+ <enum name="GL_VERTEX_ARRAY_SIZE_EXT"/>
+ <enum name="GL_VERTEX_ARRAY_TYPE_EXT"/>
+ <enum name="GL_VERTEX_ARRAY_STRIDE_EXT"/>
+ <enum name="GL_VERTEX_ARRAY_COUNT_EXT"/>
+ <enum name="GL_NORMAL_ARRAY_TYPE_EXT"/>
+ <enum name="GL_NORMAL_ARRAY_STRIDE_EXT"/>
+ <enum name="GL_NORMAL_ARRAY_COUNT_EXT"/>
+ <enum name="GL_COLOR_ARRAY_SIZE_EXT"/>
+ <enum name="GL_COLOR_ARRAY_TYPE_EXT"/>
+ <enum name="GL_COLOR_ARRAY_STRIDE_EXT"/>
+ <enum name="GL_COLOR_ARRAY_COUNT_EXT"/>
+ <enum name="GL_INDEX_ARRAY_TYPE_EXT"/>
+ <enum name="GL_INDEX_ARRAY_STRIDE_EXT"/>
+ <enum name="GL_INDEX_ARRAY_COUNT_EXT"/>
+ <enum name="GL_TEXTURE_COORD_ARRAY_SIZE_EXT"/>
+ <enum name="GL_TEXTURE_COORD_ARRAY_TYPE_EXT"/>
+ <enum name="GL_TEXTURE_COORD_ARRAY_STRIDE_EXT"/>
+ <enum name="GL_TEXTURE_COORD_ARRAY_COUNT_EXT"/>
+ <enum name="GL_EDGE_FLAG_ARRAY_STRIDE_EXT"/>
+ <enum name="GL_EDGE_FLAG_ARRAY_COUNT_EXT"/>
+ <enum name="GL_VERTEX_ARRAY_POINTER_EXT"/>
+ <enum name="GL_NORMAL_ARRAY_POINTER_EXT"/>
+ <enum name="GL_COLOR_ARRAY_POINTER_EXT"/>
+ <enum name="GL_INDEX_ARRAY_POINTER_EXT"/>
+ <enum name="GL_TEXTURE_COORD_ARRAY_POINTER_EXT"/>
+ <enum name="GL_EDGE_FLAG_ARRAY_POINTER_EXT"/>
+ <command name="glArrayElementEXT"/>
+ <command name="glColorPointerEXT"/>
+ <command name="glDrawArraysEXT"/>
+ <command name="glEdgeFlagPointerEXT"/>
+ <command name="glGetPointervEXT"/>
+ <command name="glIndexPointerEXT"/>
+ <command name="glNormalPointerEXT"/>
+ <command name="glTexCoordPointerEXT"/>
+ <command name="glVertexPointerEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_vertex_array_bgra" supported="gl">
+ <require>
+ <enum name="GL_BGRA"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_vertex_attrib_64bit" supported="gl">
+ <require>
+ <enum name="GL_DOUBLE"/>
+ <enum name="GL_DOUBLE_VEC2_EXT"/>
+ <enum name="GL_DOUBLE_VEC3_EXT"/>
+ <enum name="GL_DOUBLE_VEC4_EXT"/>
+ <enum name="GL_DOUBLE_MAT2_EXT"/>
+ <enum name="GL_DOUBLE_MAT3_EXT"/>
+ <enum name="GL_DOUBLE_MAT4_EXT"/>
+ <enum name="GL_DOUBLE_MAT2x3_EXT"/>
+ <enum name="GL_DOUBLE_MAT2x4_EXT"/>
+ <enum name="GL_DOUBLE_MAT3x2_EXT"/>
+ <enum name="GL_DOUBLE_MAT3x4_EXT"/>
+ <enum name="GL_DOUBLE_MAT4x2_EXT"/>
+ <enum name="GL_DOUBLE_MAT4x3_EXT"/>
+ <command name="glVertexAttribL1dEXT"/>
+ <command name="glVertexAttribL2dEXT"/>
+ <command name="glVertexAttribL3dEXT"/>
+ <command name="glVertexAttribL4dEXT"/>
+ <command name="glVertexAttribL1dvEXT"/>
+ <command name="glVertexAttribL2dvEXT"/>
+ <command name="glVertexAttribL3dvEXT"/>
+ <command name="glVertexAttribL4dvEXT"/>
+ <command name="glVertexAttribLPointerEXT"/>
+ <command name="glGetVertexAttribLdvEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_vertex_shader" supported="gl">
+ <require>
+ <enum name="GL_VERTEX_SHADER_EXT"/>
+ <enum name="GL_VERTEX_SHADER_BINDING_EXT"/>
+ <enum name="GL_OP_INDEX_EXT"/>
+ <enum name="GL_OP_NEGATE_EXT"/>
+ <enum name="GL_OP_DOT3_EXT"/>
+ <enum name="GL_OP_DOT4_EXT"/>
+ <enum name="GL_OP_MUL_EXT"/>
+ <enum name="GL_OP_ADD_EXT"/>
+ <enum name="GL_OP_MADD_EXT"/>
+ <enum name="GL_OP_FRAC_EXT"/>
+ <enum name="GL_OP_MAX_EXT"/>
+ <enum name="GL_OP_MIN_EXT"/>
+ <enum name="GL_OP_SET_GE_EXT"/>
+ <enum name="GL_OP_SET_LT_EXT"/>
+ <enum name="GL_OP_CLAMP_EXT"/>
+ <enum name="GL_OP_FLOOR_EXT"/>
+ <enum name="GL_OP_ROUND_EXT"/>
+ <enum name="GL_OP_EXP_BASE_2_EXT"/>
+ <enum name="GL_OP_LOG_BASE_2_EXT"/>
+ <enum name="GL_OP_POWER_EXT"/>
+ <enum name="GL_OP_RECIP_EXT"/>
+ <enum name="GL_OP_RECIP_SQRT_EXT"/>
+ <enum name="GL_OP_SUB_EXT"/>
+ <enum name="GL_OP_CROSS_PRODUCT_EXT"/>
+ <enum name="GL_OP_MULTIPLY_MATRIX_EXT"/>
+ <enum name="GL_OP_MOV_EXT"/>
+ <enum name="GL_OUTPUT_VERTEX_EXT"/>
+ <enum name="GL_OUTPUT_COLOR0_EXT"/>
+ <enum name="GL_OUTPUT_COLOR1_EXT"/>
+ <enum name="GL_OUTPUT_TEXTURE_COORD0_EXT"/>
+ <enum name="GL_OUTPUT_TEXTURE_COORD1_EXT"/>
+ <enum name="GL_OUTPUT_TEXTURE_COORD2_EXT"/>
+ <enum name="GL_OUTPUT_TEXTURE_COORD3_EXT"/>
+ <enum name="GL_OUTPUT_TEXTURE_COORD4_EXT"/>
+ <enum name="GL_OUTPUT_TEXTURE_COORD5_EXT"/>
+ <enum name="GL_OUTPUT_TEXTURE_COORD6_EXT"/>
+ <enum name="GL_OUTPUT_TEXTURE_COORD7_EXT"/>
+ <enum name="GL_OUTPUT_TEXTURE_COORD8_EXT"/>
+ <enum name="GL_OUTPUT_TEXTURE_COORD9_EXT"/>
+ <enum name="GL_OUTPUT_TEXTURE_COORD10_EXT"/>
+ <enum name="GL_OUTPUT_TEXTURE_COORD11_EXT"/>
+ <enum name="GL_OUTPUT_TEXTURE_COORD12_EXT"/>
+ <enum name="GL_OUTPUT_TEXTURE_COORD13_EXT"/>
+ <enum name="GL_OUTPUT_TEXTURE_COORD14_EXT"/>
+ <enum name="GL_OUTPUT_TEXTURE_COORD15_EXT"/>
+ <enum name="GL_OUTPUT_TEXTURE_COORD16_EXT"/>
+ <enum name="GL_OUTPUT_TEXTURE_COORD17_EXT"/>
+ <enum name="GL_OUTPUT_TEXTURE_COORD18_EXT"/>
+ <enum name="GL_OUTPUT_TEXTURE_COORD19_EXT"/>
+ <enum name="GL_OUTPUT_TEXTURE_COORD20_EXT"/>
+ <enum name="GL_OUTPUT_TEXTURE_COORD21_EXT"/>
+ <enum name="GL_OUTPUT_TEXTURE_COORD22_EXT"/>
+ <enum name="GL_OUTPUT_TEXTURE_COORD23_EXT"/>
+ <enum name="GL_OUTPUT_TEXTURE_COORD24_EXT"/>
+ <enum name="GL_OUTPUT_TEXTURE_COORD25_EXT"/>
+ <enum name="GL_OUTPUT_TEXTURE_COORD26_EXT"/>
+ <enum name="GL_OUTPUT_TEXTURE_COORD27_EXT"/>
+ <enum name="GL_OUTPUT_TEXTURE_COORD28_EXT"/>
+ <enum name="GL_OUTPUT_TEXTURE_COORD29_EXT"/>
+ <enum name="GL_OUTPUT_TEXTURE_COORD30_EXT"/>
+ <enum name="GL_OUTPUT_TEXTURE_COORD31_EXT"/>
+ <enum name="GL_OUTPUT_FOG_EXT"/>
+ <enum name="GL_SCALAR_EXT"/>
+ <enum name="GL_VECTOR_EXT"/>
+ <enum name="GL_MATRIX_EXT"/>
+ <enum name="GL_VARIANT_EXT"/>
+ <enum name="GL_INVARIANT_EXT"/>
+ <enum name="GL_LOCAL_CONSTANT_EXT"/>
+ <enum name="GL_LOCAL_EXT"/>
+ <enum name="GL_MAX_VERTEX_SHADER_INSTRUCTIONS_EXT"/>
+ <enum name="GL_MAX_VERTEX_SHADER_VARIANTS_EXT"/>
+ <enum name="GL_MAX_VERTEX_SHADER_INVARIANTS_EXT"/>
+ <enum name="GL_MAX_VERTEX_SHADER_LOCAL_CONSTANTS_EXT"/>
+ <enum name="GL_MAX_VERTEX_SHADER_LOCALS_EXT"/>
+ <enum name="GL_MAX_OPTIMIZED_VERTEX_SHADER_INSTRUCTIONS_EXT"/>
+ <enum name="GL_MAX_OPTIMIZED_VERTEX_SHADER_VARIANTS_EXT"/>
+ <enum name="GL_MAX_OPTIMIZED_VERTEX_SHADER_LOCAL_CONSTANTS_EXT"/>
+ <enum name="GL_MAX_OPTIMIZED_VERTEX_SHADER_INVARIANTS_EXT"/>
+ <enum name="GL_MAX_OPTIMIZED_VERTEX_SHADER_LOCALS_EXT"/>
+ <enum name="GL_VERTEX_SHADER_INSTRUCTIONS_EXT"/>
+ <enum name="GL_VERTEX_SHADER_VARIANTS_EXT"/>
+ <enum name="GL_VERTEX_SHADER_INVARIANTS_EXT"/>
+ <enum name="GL_VERTEX_SHADER_LOCAL_CONSTANTS_EXT"/>
+ <enum name="GL_VERTEX_SHADER_LOCALS_EXT"/>
+ <enum name="GL_VERTEX_SHADER_OPTIMIZED_EXT"/>
+ <enum name="GL_X_EXT"/>
+ <enum name="GL_Y_EXT"/>
+ <enum name="GL_Z_EXT"/>
+ <enum name="GL_W_EXT"/>
+ <enum name="GL_NEGATIVE_X_EXT"/>
+ <enum name="GL_NEGATIVE_Y_EXT"/>
+ <enum name="GL_NEGATIVE_Z_EXT"/>
+ <enum name="GL_NEGATIVE_W_EXT"/>
+ <enum name="GL_ZERO_EXT"/>
+ <enum name="GL_ONE_EXT"/>
+ <enum name="GL_NEGATIVE_ONE_EXT"/>
+ <enum name="GL_NORMALIZED_RANGE_EXT"/>
+ <enum name="GL_FULL_RANGE_EXT"/>
+ <enum name="GL_CURRENT_VERTEX_EXT"/>
+ <enum name="GL_MVP_MATRIX_EXT"/>
+ <enum name="GL_VARIANT_VALUE_EXT"/>
+ <enum name="GL_VARIANT_DATATYPE_EXT"/>
+ <enum name="GL_VARIANT_ARRAY_STRIDE_EXT"/>
+ <enum name="GL_VARIANT_ARRAY_TYPE_EXT"/>
+ <enum name="GL_VARIANT_ARRAY_EXT"/>
+ <enum name="GL_VARIANT_ARRAY_POINTER_EXT"/>
+ <enum name="GL_INVARIANT_VALUE_EXT"/>
+ <enum name="GL_INVARIANT_DATATYPE_EXT"/>
+ <enum name="GL_LOCAL_CONSTANT_VALUE_EXT"/>
+ <enum name="GL_LOCAL_CONSTANT_DATATYPE_EXT"/>
+ <command name="glBeginVertexShaderEXT"/>
+ <command name="glEndVertexShaderEXT"/>
+ <command name="glBindVertexShaderEXT"/>
+ <command name="glGenVertexShadersEXT"/>
+ <command name="glDeleteVertexShaderEXT"/>
+ <command name="glShaderOp1EXT"/>
+ <command name="glShaderOp2EXT"/>
+ <command name="glShaderOp3EXT"/>
+ <command name="glSwizzleEXT"/>
+ <command name="glWriteMaskEXT"/>
+ <command name="glInsertComponentEXT"/>
+ <command name="glExtractComponentEXT"/>
+ <command name="glGenSymbolsEXT"/>
+ <command name="glSetInvariantEXT"/>
+ <command name="glSetLocalConstantEXT"/>
+ <command name="glVariantbvEXT"/>
+ <command name="glVariantsvEXT"/>
+ <command name="glVariantivEXT"/>
+ <command name="glVariantfvEXT"/>
+ <command name="glVariantdvEXT"/>
+ <command name="glVariantubvEXT"/>
+ <command name="glVariantusvEXT"/>
+ <command name="glVariantuivEXT"/>
+ <command name="glVariantPointerEXT"/>
+ <command name="glEnableVariantClientStateEXT"/>
+ <command name="glDisableVariantClientStateEXT"/>
+ <command name="glBindLightParameterEXT"/>
+ <command name="glBindMaterialParameterEXT"/>
+ <command name="glBindTexGenParameterEXT"/>
+ <command name="glBindTextureUnitParameterEXT"/>
+ <command name="glBindParameterEXT"/>
+ <command name="glIsVariantEnabledEXT"/>
+ <command name="glGetVariantBooleanvEXT"/>
+ <command name="glGetVariantIntegervEXT"/>
+ <command name="glGetVariantFloatvEXT"/>
+ <command name="glGetVariantPointervEXT"/>
+ <command name="glGetInvariantBooleanvEXT"/>
+ <command name="glGetInvariantIntegervEXT"/>
+ <command name="glGetInvariantFloatvEXT"/>
+ <command name="glGetLocalConstantBooleanvEXT"/>
+ <command name="glGetLocalConstantIntegervEXT"/>
+ <command name="glGetLocalConstantFloatvEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_vertex_weighting" supported="gl">
+ <require>
+ <enum name="GL_MODELVIEW0_STACK_DEPTH_EXT"/>
+ <enum name="GL_MODELVIEW1_STACK_DEPTH_EXT"/>
+ <enum name="GL_MODELVIEW0_MATRIX_EXT"/>
+ <enum name="GL_MODELVIEW1_MATRIX_EXT"/>
+ <enum name="GL_VERTEX_WEIGHTING_EXT"/>
+ <enum name="GL_MODELVIEW0_EXT"/>
+ <enum name="GL_MODELVIEW1_EXT"/>
+ <enum name="GL_CURRENT_VERTEX_WEIGHT_EXT"/>
+ <enum name="GL_VERTEX_WEIGHT_ARRAY_EXT"/>
+ <enum name="GL_VERTEX_WEIGHT_ARRAY_SIZE_EXT"/>
+ <enum name="GL_VERTEX_WEIGHT_ARRAY_TYPE_EXT"/>
+ <enum name="GL_VERTEX_WEIGHT_ARRAY_STRIDE_EXT"/>
+ <enum name="GL_VERTEX_WEIGHT_ARRAY_POINTER_EXT"/>
+ <command name="glVertexWeightfEXT"/>
+ <command name="glVertexWeightfvEXT"/>
+ <command name="glVertexWeightPointerEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_EXT_x11_sync_object" supported="gl">
+ <require>
+ <enum name="GL_SYNC_X11_FENCE_EXT"/>
+ <command name="glImportSyncEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_FJ_shader_binary_GCCSO" supported="gles2">
+ <require>
+ <enum name="GL_GCCSO_SHADER_BINARY_FJ"/>
+ </require>
+ </extension>
+ <extension name="GL_GREMEDY_frame_terminator" supported="gl">
+ <require>
+ <command name="glFrameTerminatorGREMEDY"/>
+ </require>
+ </extension>
+ <extension name="GL_GREMEDY_string_marker" supported="gl">
+ <require>
+ <command name="glStringMarkerGREMEDY"/>
+ </require>
+ </extension>
+ <extension name="GL_HP_convolution_border_modes" supported="gl">
+ <require>
+ <enum name="GL_IGNORE_BORDER_HP"/>
+ <enum name="GL_CONSTANT_BORDER_HP"/>
+ <enum name="GL_REPLICATE_BORDER_HP"/>
+ <enum name="GL_CONVOLUTION_BORDER_COLOR_HP"/>
+ </require>
+ </extension>
+ <extension name="GL_HP_image_transform" supported="gl">
+ <require>
+ <enum name="GL_IMAGE_SCALE_X_HP"/>
+ <enum name="GL_IMAGE_SCALE_Y_HP"/>
+ <enum name="GL_IMAGE_TRANSLATE_X_HP"/>
+ <enum name="GL_IMAGE_TRANSLATE_Y_HP"/>
+ <enum name="GL_IMAGE_ROTATE_ANGLE_HP"/>
+ <enum name="GL_IMAGE_ROTATE_ORIGIN_X_HP"/>
+ <enum name="GL_IMAGE_ROTATE_ORIGIN_Y_HP"/>
+ <enum name="GL_IMAGE_MAG_FILTER_HP"/>
+ <enum name="GL_IMAGE_MIN_FILTER_HP"/>
+ <enum name="GL_IMAGE_CUBIC_WEIGHT_HP"/>
+ <enum name="GL_CUBIC_HP"/>
+ <enum name="GL_AVERAGE_HP"/>
+ <enum name="GL_IMAGE_TRANSFORM_2D_HP"/>
+ <enum name="GL_POST_IMAGE_TRANSFORM_COLOR_TABLE_HP"/>
+ <enum name="GL_PROXY_POST_IMAGE_TRANSFORM_COLOR_TABLE_HP"/>
+ <command name="glImageTransformParameteriHP"/>
+ <command name="glImageTransformParameterfHP"/>
+ <command name="glImageTransformParameterivHP"/>
+ <command name="glImageTransformParameterfvHP"/>
+ <command name="glGetImageTransformParameterivHP"/>
+ <command name="glGetImageTransformParameterfvHP"/>
+ </require>
+ </extension>
+ <extension name="GL_HP_occlusion_test" supported="gl">
+ <require>
+ <enum name="GL_OCCLUSION_TEST_HP"/>
+ <enum name="GL_OCCLUSION_TEST_RESULT_HP"/>
+ </require>
+ </extension>
+ <extension name="GL_HP_texture_lighting" supported="gl">
+ <require>
+ <enum name="GL_TEXTURE_LIGHTING_MODE_HP"/>
+ <enum name="GL_TEXTURE_POST_SPECULAR_HP"/>
+ <enum name="GL_TEXTURE_PRE_SPECULAR_HP"/>
+ </require>
+ </extension>
+ <extension name="GL_IBM_cull_vertex" supported="gl">
+ <require>
+ <enum name="GL_CULL_VERTEX_IBM"/>
+ </require>
+ </extension>
+ <extension name="GL_IBM_multimode_draw_arrays" supported="gl">
+ <require>
+ <command name="glMultiModeDrawArraysIBM"/>
+ <command name="glMultiModeDrawElementsIBM"/>
+ </require>
+ </extension>
+ <extension name="GL_IBM_rasterpos_clip" supported="gl">
+ <require>
+ <enum name="GL_RASTER_POSITION_UNCLIPPED_IBM"/>
+ </require>
+ </extension>
+ <extension name="GL_IBM_static_data" supported="gl">
+ <require>
+ <enum name="GL_ALL_STATIC_DATA_IBM"/>
+ <enum name="GL_STATIC_VERTEX_ARRAY_IBM"/>
+ <command name="glFlushStaticDataIBM"/>
+ </require>
+ </extension>
+ <extension name="GL_IBM_texture_mirrored_repeat" supported="gl">
+ <require>
+ <enum name="GL_MIRRORED_REPEAT_IBM"/>
+ </require>
+ </extension>
+ <extension name="GL_IBM_vertex_array_lists" supported="gl">
+ <require>
+ <enum name="GL_VERTEX_ARRAY_LIST_IBM"/>
+ <enum name="GL_NORMAL_ARRAY_LIST_IBM"/>
+ <enum name="GL_COLOR_ARRAY_LIST_IBM"/>
+ <enum name="GL_INDEX_ARRAY_LIST_IBM"/>
+ <enum name="GL_TEXTURE_COORD_ARRAY_LIST_IBM"/>
+ <enum name="GL_EDGE_FLAG_ARRAY_LIST_IBM"/>
+ <enum name="GL_FOG_COORDINATE_ARRAY_LIST_IBM"/>
+ <enum name="GL_SECONDARY_COLOR_ARRAY_LIST_IBM"/>
+ <enum name="GL_VERTEX_ARRAY_LIST_STRIDE_IBM"/>
+ <enum name="GL_NORMAL_ARRAY_LIST_STRIDE_IBM"/>
+ <enum name="GL_COLOR_ARRAY_LIST_STRIDE_IBM"/>
+ <enum name="GL_INDEX_ARRAY_LIST_STRIDE_IBM"/>
+ <enum name="GL_TEXTURE_COORD_ARRAY_LIST_STRIDE_IBM"/>
+ <enum name="GL_EDGE_FLAG_ARRAY_LIST_STRIDE_IBM"/>
+ <enum name="GL_FOG_COORDINATE_ARRAY_LIST_STRIDE_IBM"/>
+ <enum name="GL_SECONDARY_COLOR_ARRAY_LIST_STRIDE_IBM"/>
+ <command name="glColorPointerListIBM"/>
+ <command name="glSecondaryColorPointerListIBM"/>
+ <command name="glEdgeFlagPointerListIBM"/>
+ <command name="glFogCoordPointerListIBM"/>
+ <command name="glIndexPointerListIBM"/>
+ <command name="glNormalPointerListIBM"/>
+ <command name="glTexCoordPointerListIBM"/>
+ <command name="glVertexPointerListIBM"/>
+ </require>
+ </extension>
+ <extension name="GL_IMG_multisampled_render_to_texture" supported="gles1|gles2">
+ <require>
+ <enum name="GL_RENDERBUFFER_SAMPLES_IMG"/>
+ <enum name="GL_FRAMEBUFFER_INCOMPLETE_MULTISAMPLE_IMG"/>
+ <enum name="GL_MAX_SAMPLES_IMG"/>
+ <enum name="GL_TEXTURE_SAMPLES_IMG"/>
+ <command name="glRenderbufferStorageMultisampleIMG"/>
+ <command name="glFramebufferTexture2DMultisampleIMG"/>
+ </require>
+ </extension>
+ <extension name="GL_IMG_program_binary" supported="gles2">
+ <require>
+ <enum name="GL_SGX_PROGRAM_BINARY_IMG"/>
+ </require>
+ </extension>
+ <extension name="GL_IMG_read_format" supported="gles1|gles2">
+ <require>
+ <enum name="GL_BGRA_IMG"/>
+ <enum name="GL_UNSIGNED_SHORT_4_4_4_4_REV_IMG"/>
+ </require>
+ </extension>
+ <extension name="GL_IMG_shader_binary" supported="gles2">
+ <require>
+ <enum name="GL_SGX_BINARY_IMG"/>
+ </require>
+ </extension>
+ <extension name="GL_IMG_texture_compression_pvrtc" supported="gles1|gles2">
+ <require>
+ <enum name="GL_COMPRESSED_RGB_PVRTC_4BPPV1_IMG"/>
+ <enum name="GL_COMPRESSED_RGB_PVRTC_2BPPV1_IMG"/>
+ <enum name="GL_COMPRESSED_RGBA_PVRTC_4BPPV1_IMG"/>
+ <enum name="GL_COMPRESSED_RGBA_PVRTC_2BPPV1_IMG"/>
+ </require>
+ </extension>
+ <extension name="GL_IMG_texture_compression_pvrtc2" supported="gles2">
+ <require>
+ <enum name="GL_COMPRESSED_RGBA_PVRTC_2BPPV2_IMG"/>
+ <enum name="GL_COMPRESSED_RGBA_PVRTC_4BPPV2_IMG"/>
+ </require>
+ </extension>
+ <extension name="GL_IMG_texture_env_enhanced_fixed_function" supported="gles1">
+ <require>
+ <enum name="GL_MODULATE_COLOR_IMG"/>
+ <enum name="GL_RECIP_ADD_SIGNED_ALPHA_IMG"/>
+ <enum name="GL_TEXTURE_ALPHA_MODULATE_IMG"/>
+ <enum name="GL_FACTOR_ALPHA_MODULATE_IMG"/>
+ <enum name="GL_FRAGMENT_ALPHA_MODULATE_IMG"/>
+ <enum name="GL_ADD_BLEND_IMG"/>
+ <enum name="GL_DOT3_RGBA_IMG"/>
+ </require>
+ </extension>
+ <extension name="GL_IMG_user_clip_plane" supported="gles1">
+ <require>
+ <enum name="GL_CLIP_PLANE0_IMG"/>
+ <enum name="GL_CLIP_PLANE1_IMG"/>
+ <enum name="GL_CLIP_PLANE2_IMG"/>
+ <enum name="GL_CLIP_PLANE3_IMG"/>
+ <enum name="GL_CLIP_PLANE4_IMG"/>
+ <enum name="GL_CLIP_PLANE5_IMG"/>
+ <enum name="GL_MAX_CLIP_PLANES_IMG"/>
+ <command name="glClipPlanefIMG"/>
+ <command name="glClipPlanexIMG"/>
+ </require>
+ </extension>
+ <extension name="GL_INGR_blend_func_separate" supported="gl">
+ <require>
+ <command name="glBlendFuncSeparateINGR"/>
+ </require>
+ </extension>
+ <extension name="GL_INGR_color_clamp" supported="gl">
+ <require>
+ <enum name="GL_RED_MIN_CLAMP_INGR"/>
+ <enum name="GL_GREEN_MIN_CLAMP_INGR"/>
+ <enum name="GL_BLUE_MIN_CLAMP_INGR"/>
+ <enum name="GL_ALPHA_MIN_CLAMP_INGR"/>
+ <enum name="GL_RED_MAX_CLAMP_INGR"/>
+ <enum name="GL_GREEN_MAX_CLAMP_INGR"/>
+ <enum name="GL_BLUE_MAX_CLAMP_INGR"/>
+ <enum name="GL_ALPHA_MAX_CLAMP_INGR"/>
+ </require>
+ </extension>
+ <extension name="GL_INGR_interlace_read" supported="gl">
+ <require>
+ <enum name="GL_INTERLACE_READ_INGR"/>
+ </require>
+ </extension>
+ <extension name="GL_INTEL_fragment_shader_ordering" supported="gl"/>
+ <extension name="GL_INTEL_map_texture" supported="gl">
+ <require>
+ <enum name="GL_TEXTURE_MEMORY_LAYOUT_INTEL"/>
+ <enum name="GL_LAYOUT_DEFAULT_INTEL"/>
+ <enum name="GL_LAYOUT_LINEAR_INTEL"/>
+ <enum name="GL_LAYOUT_LINEAR_CPU_CACHED_INTEL"/>
+ <command name="glSyncTextureINTEL"/>
+ <command name="glUnmapTexture2DINTEL"/>
+ <command name="glMapTexture2DINTEL"/>
+ </require>
+ </extension>
+ <extension name="GL_INTEL_parallel_arrays" supported="gl">
+ <require>
+ <enum name="GL_PARALLEL_ARRAYS_INTEL"/>
+ <enum name="GL_VERTEX_ARRAY_PARALLEL_POINTERS_INTEL"/>
+ <enum name="GL_NORMAL_ARRAY_PARALLEL_POINTERS_INTEL"/>
+ <enum name="GL_COLOR_ARRAY_PARALLEL_POINTERS_INTEL"/>
+ <enum name="GL_TEXTURE_COORD_ARRAY_PARALLEL_POINTERS_INTEL"/>
+ <command name="glVertexPointervINTEL"/>
+ <command name="glNormalPointervINTEL"/>
+ <command name="glColorPointervINTEL"/>
+ <command name="glTexCoordPointervINTEL"/>
+ </require>
+ </extension>
+ <extension name="GL_INTEL_performance_query" supported="gl|gles2">
+ <require>
+ <enum name="GL_PERFQUERY_SINGLE_CONTEXT_INTEL"/>
+ <enum name="GL_PERFQUERY_GLOBAL_CONTEXT_INTEL"/>
+ <enum name="GL_PERFQUERY_WAIT_INTEL"/>
+ <enum name="GL_PERFQUERY_FLUSH_INTEL"/>
+ <enum name="GL_PERFQUERY_DONOT_FLUSH_INTEL"/>
+ <enum name="GL_PERFQUERY_COUNTER_EVENT_INTEL"/>
+ <enum name="GL_PERFQUERY_COUNTER_DURATION_NORM_INTEL"/>
+ <enum name="GL_PERFQUERY_COUNTER_DURATION_RAW_INTEL"/>
+ <enum name="GL_PERFQUERY_COUNTER_THROUGHPUT_INTEL"/>
+ <enum name="GL_PERFQUERY_COUNTER_RAW_INTEL"/>
+ <enum name="GL_PERFQUERY_COUNTER_TIMESTAMP_INTEL"/>
+ <enum name="GL_PERFQUERY_COUNTER_DATA_UINT32_INTEL"/>
+ <enum name="GL_PERFQUERY_COUNTER_DATA_UINT64_INTEL"/>
+ <enum name="GL_PERFQUERY_COUNTER_DATA_FLOAT_INTEL"/>
+ <enum name="GL_PERFQUERY_COUNTER_DATA_DOUBLE_INTEL"/>
+ <enum name="GL_PERFQUERY_COUNTER_DATA_BOOL32_INTEL"/>
+ <enum name="GL_PERFQUERY_QUERY_NAME_LENGTH_MAX_INTEL"/>
+ <enum name="GL_PERFQUERY_COUNTER_NAME_LENGTH_MAX_INTEL"/>
+ <enum name="GL_PERFQUERY_COUNTER_DESC_LENGTH_MAX_INTEL"/>
+ <enum name="GL_PERFQUERY_GPA_EXTENDED_COUNTERS_INTEL"/>
+ <command name="glBeginPerfQueryINTEL"/>
+ <command name="glCreatePerfQueryINTEL"/>
+ <command name="glDeletePerfQueryINTEL"/>
+ <command name="glEndPerfQueryINTEL"/>
+ <command name="glGetFirstPerfQueryIdINTEL"/>
+ <command name="glGetNextPerfQueryIdINTEL"/>
+ <command name="glGetPerfCounterInfoINTEL"/>
+ <command name="glGetPerfQueryDataINTEL"/>
+ <command name="glGetPerfQueryIdByNameINTEL"/>
+ <command name="glGetPerfQueryInfoINTEL"/>
+ </require>
+ </extension>
+ <extension name="GL_KHR_blend_equation_advanced" supported="gl|gles2">
+ <require>
+ <command name="glBlendBarrierKHR"/>
+ <enum name="GL_MULTIPLY_KHR"/>
+ <enum name="GL_SCREEN_KHR"/>
+ <enum name="GL_OVERLAY_KHR"/>
+ <enum name="GL_DARKEN_KHR"/>
+ <enum name="GL_LIGHTEN_KHR"/>
+ <enum name="GL_COLORDODGE_KHR"/>
+ <enum name="GL_COLORBURN_KHR"/>
+ <enum name="GL_HARDLIGHT_KHR"/>
+ <enum name="GL_SOFTLIGHT_KHR"/>
+ <enum name="GL_DIFFERENCE_KHR"/>
+ <enum name="GL_EXCLUSION_KHR"/>
+ <enum name="GL_HSL_HUE_KHR"/>
+ <enum name="GL_HSL_SATURATION_KHR"/>
+ <enum name="GL_HSL_COLOR_KHR"/>
+ <enum name="GL_HSL_LUMINOSITY_KHR"/>
+ </require>
+ </extension>
+ <extension name="GL_KHR_blend_equation_advanced_coherent" supported="gl|gles2">
+ <require comment="Otherwise identical to GL_KHR_blend_equation_advanced, just different semantic behavior">
+ <enum name="GL_BLEND_ADVANCED_COHERENT_KHR"/>
+ </require>
+ </extension>
+ <extension name="GL_KHR_context_flush_control" supported="gl|glcore|gles2">
+ <require api="gl" comment="KHR extensions *mandate* suffixes for ES, unlike for GL">
+ <enum name="GL_CONTEXT_RELEASE_BEHAVIOR"/>
+ <enum name="GL_CONTEXT_RELEASE_BEHAVIOR_FLUSH"/>
+ <enum name="GL_NONE"/>
+ </require>
+ <require api="gles2">
+ <enum name="GL_CONTEXT_RELEASE_BEHAVIOR_KHR"/>
+ <enum name="GL_CONTEXT_RELEASE_BEHAVIOR_FLUSH_KHR"/>
+ <enum name="GL_NONE"/>
+ </require>
+ </extension>
+ <extension name="GL_KHR_debug" supported="gl|glcore|gles2">
+ <require api="gl" comment="KHR extensions *mandate* suffixes for ES, unlike for GL">
+ <enum name="GL_DEBUG_OUTPUT_SYNCHRONOUS"/>
+ <enum name="GL_DEBUG_NEXT_LOGGED_MESSAGE_LENGTH"/>
+ <enum name="GL_DEBUG_CALLBACK_FUNCTION"/>
+ <enum name="GL_DEBUG_CALLBACK_USER_PARAM"/>
+ <enum name="GL_DEBUG_SOURCE_API"/>
+ <enum name="GL_DEBUG_SOURCE_WINDOW_SYSTEM"/>
+ <enum name="GL_DEBUG_SOURCE_SHADER_COMPILER"/>
+ <enum name="GL_DEBUG_SOURCE_THIRD_PARTY"/>
+ <enum name="GL_DEBUG_SOURCE_APPLICATION"/>
+ <enum name="GL_DEBUG_SOURCE_OTHER"/>
+ <enum name="GL_DEBUG_TYPE_ERROR"/>
+ <enum name="GL_DEBUG_TYPE_DEPRECATED_BEHAVIOR"/>
+ <enum name="GL_DEBUG_TYPE_UNDEFINED_BEHAVIOR"/>
+ <enum name="GL_DEBUG_TYPE_PORTABILITY"/>
+ <enum name="GL_DEBUG_TYPE_PERFORMANCE"/>
+ <enum name="GL_DEBUG_TYPE_OTHER"/>
+ <enum name="GL_DEBUG_TYPE_MARKER"/>
+ <enum name="GL_DEBUG_TYPE_PUSH_GROUP"/>
+ <enum name="GL_DEBUG_TYPE_POP_GROUP"/>
+ <enum name="GL_DEBUG_SEVERITY_NOTIFICATION"/>
+ <enum name="GL_MAX_DEBUG_GROUP_STACK_DEPTH"/>
+ <enum name="GL_DEBUG_GROUP_STACK_DEPTH"/>
+ <enum name="GL_BUFFER"/>
+ <enum name="GL_SHADER"/>
+ <enum name="GL_PROGRAM"/>
+ <enum name="GL_VERTEX_ARRAY"/>
+ <enum name="GL_QUERY"/>
+ <enum name="GL_SAMPLER"/>
+ <enum name="GL_MAX_LABEL_LENGTH"/>
+ <enum name="GL_MAX_DEBUG_MESSAGE_LENGTH"/>
+ <enum name="GL_MAX_DEBUG_LOGGED_MESSAGES"/>
+ <enum name="GL_DEBUG_LOGGED_MESSAGES"/>
+ <enum name="GL_DEBUG_SEVERITY_HIGH"/>
+ <enum name="GL_DEBUG_SEVERITY_MEDIUM"/>
+ <enum name="GL_DEBUG_SEVERITY_LOW"/>
+ <enum name="GL_DEBUG_OUTPUT"/>
+ <enum name="GL_CONTEXT_FLAG_DEBUG_BIT"/>
+ <enum name="GL_STACK_OVERFLOW"/>
+ <enum name="GL_STACK_UNDERFLOW"/>
+ <command name="glDebugMessageControl"/>
+ <command name="glDebugMessageInsert"/>
+ <command name="glDebugMessageCallback"/>
+ <command name="glGetDebugMessageLog"/>
+ <command name="glPushDebugGroup"/>
+ <command name="glPopDebugGroup"/>
+ <command name="glObjectLabel"/>
+ <command name="glGetObjectLabel"/>
+ <command name="glObjectPtrLabel"/>
+ <command name="glGetObjectPtrLabel"/>
+ <command name="glGetPointerv"/>
+ </require>
+ <require api="gles2">
+ <enum name="GL_DEBUG_OUTPUT_SYNCHRONOUS_KHR"/>
+ <enum name="GL_DEBUG_NEXT_LOGGED_MESSAGE_LENGTH_KHR"/>
+ <enum name="GL_DEBUG_CALLBACK_FUNCTION_KHR"/>
+ <enum name="GL_DEBUG_CALLBACK_USER_PARAM_KHR"/>
+ <enum name="GL_DEBUG_SOURCE_API_KHR"/>
+ <enum name="GL_DEBUG_SOURCE_WINDOW_SYSTEM_KHR"/>
+ <enum name="GL_DEBUG_SOURCE_SHADER_COMPILER_KHR"/>
+ <enum name="GL_DEBUG_SOURCE_THIRD_PARTY_KHR"/>
+ <enum name="GL_DEBUG_SOURCE_APPLICATION_KHR"/>
+ <enum name="GL_DEBUG_SOURCE_OTHER_KHR"/>
+ <enum name="GL_DEBUG_TYPE_ERROR_KHR"/>
+ <enum name="GL_DEBUG_TYPE_DEPRECATED_BEHAVIOR_KHR"/>
+ <enum name="GL_DEBUG_TYPE_UNDEFINED_BEHAVIOR_KHR"/>
+ <enum name="GL_DEBUG_TYPE_PORTABILITY_KHR"/>
+ <enum name="GL_DEBUG_TYPE_PERFORMANCE_KHR"/>
+ <enum name="GL_DEBUG_TYPE_OTHER_KHR"/>
+ <enum name="GL_DEBUG_TYPE_MARKER_KHR"/>
+ <enum name="GL_DEBUG_TYPE_PUSH_GROUP_KHR"/>
+ <enum name="GL_DEBUG_TYPE_POP_GROUP_KHR"/>
+ <enum name="GL_DEBUG_SEVERITY_NOTIFICATION_KHR"/>
+ <enum name="GL_MAX_DEBUG_GROUP_STACK_DEPTH_KHR"/>
+ <enum name="GL_DEBUG_GROUP_STACK_DEPTH_KHR"/>
+ <enum name="GL_BUFFER_KHR"/>
+ <enum name="GL_SHADER_KHR"/>
+ <enum name="GL_PROGRAM_KHR"/>
+ <enum name="GL_VERTEX_ARRAY_KHR"/>
+ <enum name="GL_QUERY_KHR"/>
+ <enum name="GL_SAMPLER_KHR"/>
+ <enum name="GL_MAX_LABEL_LENGTH_KHR"/>
+ <enum name="GL_MAX_DEBUG_MESSAGE_LENGTH_KHR"/>
+ <enum name="GL_MAX_DEBUG_LOGGED_MESSAGES_KHR"/>
+ <enum name="GL_DEBUG_LOGGED_MESSAGES_KHR"/>
+ <enum name="GL_DEBUG_SEVERITY_HIGH_KHR"/>
+ <enum name="GL_DEBUG_SEVERITY_MEDIUM_KHR"/>
+ <enum name="GL_DEBUG_SEVERITY_LOW_KHR"/>
+ <enum name="GL_DEBUG_OUTPUT_KHR"/>
+ <enum name="GL_CONTEXT_FLAG_DEBUG_BIT_KHR"/>
+ <enum name="GL_STACK_OVERFLOW_KHR"/>
+ <enum name="GL_STACK_UNDERFLOW_KHR"/>
+ <command name="glDebugMessageControlKHR"/>
+ <command name="glDebugMessageInsertKHR"/>
+ <command name="glDebugMessageCallbackKHR"/>
+ <command name="glGetDebugMessageLogKHR"/>
+ <command name="glPushDebugGroupKHR"/>
+ <command name="glPopDebugGroupKHR"/>
+ <command name="glObjectLabelKHR"/>
+ <command name="glGetObjectLabelKHR"/>
+ <command name="glObjectPtrLabelKHR"/>
+ <command name="glGetObjectPtrLabelKHR"/>
+ <command name="glGetPointervKHR"/>
+ </require>
+ <require api="gl" comment="Could benefit from api/profile attributes at enum tag level">
+ <enum name="GL_PROGRAM_PIPELINE"/>
+ </require>
+ <require api="gl" profile="compatibility">
+ <enum name="GL_DISPLAY_LIST"/>
+ </require>
+ </extension>
+ <extension name="GL_KHR_robust_buffer_access_behavior" supported="gl|glcore|gles2"/>
+ <extension name="GL_KHR_robustness" supported="gl|glcore|gles2">
+ <require api="gl" comment="KHR extensions *mandate* suffixes for ES, unlike for GL">
+ <enum name="GL_NO_ERROR"/>
+ <enum name="GL_CONTEXT_ROBUST_ACCESS"/>
+ <enum name="GL_LOSE_CONTEXT_ON_RESET"/>
+ <enum name="GL_GUILTY_CONTEXT_RESET"/>
+ <enum name="GL_INNOCENT_CONTEXT_RESET"/>
+ <enum name="GL_UNKNOWN_CONTEXT_RESET"/>
+ <enum name="GL_RESET_NOTIFICATION_STRATEGY"/>
+ <enum name="GL_NO_RESET_NOTIFICATION"/>
+ <enum name="GL_CONTEXT_LOST"/>
+ <command name="glGetGraphicsResetStatus"/>
+ <command name="glReadnPixels"/>
+ <command name="glGetnUniformfv"/>
+ <command name="glGetnUniformiv"/>
+ <command name="glGetnUniformuiv"/>
+ </require>
+ <require api="gles2">
+ <enum name="GL_NO_ERROR"/>
+ <enum name="GL_CONTEXT_ROBUST_ACCESS_KHR"/>
+ <enum name="GL_LOSE_CONTEXT_ON_RESET_KHR"/>
+ <enum name="GL_GUILTY_CONTEXT_RESET_KHR"/>
+ <enum name="GL_INNOCENT_CONTEXT_RESET_KHR"/>
+ <enum name="GL_UNKNOWN_CONTEXT_RESET_KHR"/>
+ <enum name="GL_RESET_NOTIFICATION_STRATEGY_KHR"/>
+ <enum name="GL_NO_RESET_NOTIFICATION_KHR"/>
+ <enum name="GL_CONTEXT_LOST_KHR"/>
+ <command name="glGetGraphicsResetStatusKHR"/>
+ <command name="glReadnPixelsKHR"/>
+ <command name="glGetnUniformfvKHR"/>
+ <command name="glGetnUniformivKHR"/>
+ <command name="glGetnUniformuivKHR"/>
+ </require>
+ </extension>
+ <extension name="GL_KHR_texture_compression_astc_hdr" supported="gl|glcore|gles2">
+ <require>
+ <enum name="GL_COMPRESSED_RGBA_ASTC_4x4_KHR"/>
+ <enum name="GL_COMPRESSED_RGBA_ASTC_5x4_KHR"/>
+ <enum name="GL_COMPRESSED_RGBA_ASTC_5x5_KHR"/>
+ <enum name="GL_COMPRESSED_RGBA_ASTC_6x5_KHR"/>
+ <enum name="GL_COMPRESSED_RGBA_ASTC_6x6_KHR"/>
+ <enum name="GL_COMPRESSED_RGBA_ASTC_8x5_KHR"/>
+ <enum name="GL_COMPRESSED_RGBA_ASTC_8x6_KHR"/>
+ <enum name="GL_COMPRESSED_RGBA_ASTC_8x8_KHR"/>
+ <enum name="GL_COMPRESSED_RGBA_ASTC_10x5_KHR"/>
+ <enum name="GL_COMPRESSED_RGBA_ASTC_10x6_KHR"/>
+ <enum name="GL_COMPRESSED_RGBA_ASTC_10x8_KHR"/>
+ <enum name="GL_COMPRESSED_RGBA_ASTC_10x10_KHR"/>
+ <enum name="GL_COMPRESSED_RGBA_ASTC_12x10_KHR"/>
+ <enum name="GL_COMPRESSED_RGBA_ASTC_12x12_KHR"/>
+ <enum name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_4x4_KHR"/>
+ <enum name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_5x4_KHR"/>
+ <enum name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_5x5_KHR"/>
+ <enum name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_6x5_KHR"/>
+ <enum name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_6x6_KHR"/>
+ <enum name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_8x5_KHR"/>
+ <enum name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_8x6_KHR"/>
+ <enum name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_8x8_KHR"/>
+ <enum name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_10x5_KHR"/>
+ <enum name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_10x6_KHR"/>
+ <enum name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_10x8_KHR"/>
+ <enum name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_10x10_KHR"/>
+ <enum name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_12x10_KHR"/>
+ <enum name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_12x12_KHR"/>
+ </require>
+ </extension>
+ <extension name="GL_KHR_texture_compression_astc_ldr" supported="gl|glcore|gles2" comment="API is identical to GL_KHR_texture_compression_astc_hdr extension">
+ <require>
+ <enum name="GL_COMPRESSED_RGBA_ASTC_4x4_KHR"/>
+ <enum name="GL_COMPRESSED_RGBA_ASTC_5x4_KHR"/>
+ <enum name="GL_COMPRESSED_RGBA_ASTC_5x5_KHR"/>
+ <enum name="GL_COMPRESSED_RGBA_ASTC_6x5_KHR"/>
+ <enum name="GL_COMPRESSED_RGBA_ASTC_6x6_KHR"/>
+ <enum name="GL_COMPRESSED_RGBA_ASTC_8x5_KHR"/>
+ <enum name="GL_COMPRESSED_RGBA_ASTC_8x6_KHR"/>
+ <enum name="GL_COMPRESSED_RGBA_ASTC_8x8_KHR"/>
+ <enum name="GL_COMPRESSED_RGBA_ASTC_10x5_KHR"/>
+ <enum name="GL_COMPRESSED_RGBA_ASTC_10x6_KHR"/>
+ <enum name="GL_COMPRESSED_RGBA_ASTC_10x8_KHR"/>
+ <enum name="GL_COMPRESSED_RGBA_ASTC_10x10_KHR"/>
+ <enum name="GL_COMPRESSED_RGBA_ASTC_12x10_KHR"/>
+ <enum name="GL_COMPRESSED_RGBA_ASTC_12x12_KHR"/>
+ <enum name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_4x4_KHR"/>
+ <enum name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_5x4_KHR"/>
+ <enum name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_5x5_KHR"/>
+ <enum name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_6x5_KHR"/>
+ <enum name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_6x6_KHR"/>
+ <enum name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_8x5_KHR"/>
+ <enum name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_8x6_KHR"/>
+ <enum name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_8x8_KHR"/>
+ <enum name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_10x5_KHR"/>
+ <enum name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_10x6_KHR"/>
+ <enum name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_10x8_KHR"/>
+ <enum name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_10x10_KHR"/>
+ <enum name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_12x10_KHR"/>
+ <enum name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_12x12_KHR"/>
+ </require>
+ </extension>
+ <extension name="GL_MESAX_texture_stack" supported="gl">
+ <require>
+ <enum name="GL_TEXTURE_1D_STACK_MESAX"/>
+ <enum name="GL_TEXTURE_2D_STACK_MESAX"/>
+ <enum name="GL_PROXY_TEXTURE_1D_STACK_MESAX"/>
+ <enum name="GL_PROXY_TEXTURE_2D_STACK_MESAX"/>
+ <enum name="GL_TEXTURE_1D_STACK_BINDING_MESAX"/>
+ <enum name="GL_TEXTURE_2D_STACK_BINDING_MESAX"/>
+ </require>
+ </extension>
+ <extension name="GL_MESA_pack_invert" supported="gl">
+ <require>
+ <enum name="GL_PACK_INVERT_MESA"/>
+ </require>
+ </extension>
+ <extension name="GL_MESA_resize_buffers" supported="gl">
+ <require>
+ <command name="glResizeBuffersMESA"/>
+ </require>
+ </extension>
+ <extension name="GL_MESA_window_pos" supported="gl">
+ <require>
+ <command name="glWindowPos2dMESA"/>
+ <command name="glWindowPos2dvMESA"/>
+ <command name="glWindowPos2fMESA"/>
+ <command name="glWindowPos2fvMESA"/>
+ <command name="glWindowPos2iMESA"/>
+ <command name="glWindowPos2ivMESA"/>
+ <command name="glWindowPos2sMESA"/>
+ <command name="glWindowPos2svMESA"/>
+ <command name="glWindowPos3dMESA"/>
+ <command name="glWindowPos3dvMESA"/>
+ <command name="glWindowPos3fMESA"/>
+ <command name="glWindowPos3fvMESA"/>
+ <command name="glWindowPos3iMESA"/>
+ <command name="glWindowPos3ivMESA"/>
+ <command name="glWindowPos3sMESA"/>
+ <command name="glWindowPos3svMESA"/>
+ <command name="glWindowPos4dMESA"/>
+ <command name="glWindowPos4dvMESA"/>
+ <command name="glWindowPos4fMESA"/>
+ <command name="glWindowPos4fvMESA"/>
+ <command name="glWindowPos4iMESA"/>
+ <command name="glWindowPos4ivMESA"/>
+ <command name="glWindowPos4sMESA"/>
+ <command name="glWindowPos4svMESA"/>
+ </require>
+ </extension>
+ <extension name="GL_MESA_ycbcr_texture" supported="gl">
+ <require>
+ <enum name="GL_UNSIGNED_SHORT_8_8_MESA"/>
+ <enum name="GL_UNSIGNED_SHORT_8_8_REV_MESA"/>
+ <enum name="GL_YCBCR_MESA"/>
+ </require>
+ </extension>
+ <extension name="GL_NVX_conditional_render" supported="gl">
+ <require>
+ <command name="glBeginConditionalRenderNVX"/>
+ <command name="glEndConditionalRenderNVX"/>
+ </require>
+ </extension>
+ <extension name="GL_NVX_gpu_memory_info" supported="gl">
+ <require>
+ <enum name="GL_GPU_MEMORY_INFO_DEDICATED_VIDMEM_NVX"/>
+ <enum name="GL_GPU_MEMORY_INFO_TOTAL_AVAILABLE_MEMORY_NVX"/>
+ <enum name="GL_GPU_MEMORY_INFO_CURRENT_AVAILABLE_VIDMEM_NVX"/>
+ <enum name="GL_GPU_MEMORY_INFO_EVICTION_COUNT_NVX"/>
+ <enum name="GL_GPU_MEMORY_INFO_EVICTED_MEMORY_NVX"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_bindless_multi_draw_indirect" supported="gl">
+ <require>
+ <command name="glMultiDrawArraysIndirectBindlessNV"/>
+ <command name="glMultiDrawElementsIndirectBindlessNV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_bindless_multi_draw_indirect_count" supported="gl">
+ <require>
+ <command name="glMultiDrawArraysIndirectBindlessCountNV"/>
+ <command name="glMultiDrawElementsIndirectBindlessCountNV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_bindless_texture" supported="gl">
+ <require>
+ <command name="glGetTextureHandleNV"/>
+ <command name="glGetTextureSamplerHandleNV"/>
+ <command name="glMakeTextureHandleResidentNV"/>
+ <command name="glMakeTextureHandleNonResidentNV"/>
+ <command name="glGetImageHandleNV"/>
+ <command name="glMakeImageHandleResidentNV"/>
+ <command name="glMakeImageHandleNonResidentNV"/>
+ <command name="glUniformHandleui64NV"/>
+ <command name="glUniformHandleui64vNV"/>
+ <command name="glProgramUniformHandleui64NV"/>
+ <command name="glProgramUniformHandleui64vNV"/>
+ <command name="glIsTextureHandleResidentNV"/>
+ <command name="glIsImageHandleResidentNV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_blend_equation_advanced" supported="gl|gles2">
+ <require>
+ <enum name="GL_BLEND_OVERLAP_NV"/>
+ <enum name="GL_BLEND_PREMULTIPLIED_SRC_NV"/>
+ <enum name="GL_BLUE_NV"/>
+ <enum name="GL_COLORBURN_NV"/>
+ <enum name="GL_COLORDODGE_NV"/>
+ <enum name="GL_CONJOINT_NV"/>
+ <enum name="GL_CONTRAST_NV"/>
+ <enum name="GL_DARKEN_NV"/>
+ <enum name="GL_DIFFERENCE_NV"/>
+ <enum name="GL_DISJOINT_NV"/>
+ <enum name="GL_DST_ATOP_NV"/>
+ <enum name="GL_DST_IN_NV"/>
+ <enum name="GL_DST_NV"/>
+ <enum name="GL_DST_OUT_NV"/>
+ <enum name="GL_DST_OVER_NV"/>
+ <enum name="GL_EXCLUSION_NV"/>
+ <enum name="GL_GREEN_NV"/>
+ <enum name="GL_HARDLIGHT_NV"/>
+ <enum name="GL_HARDMIX_NV"/>
+ <enum name="GL_HSL_COLOR_NV"/>
+ <enum name="GL_HSL_HUE_NV"/>
+ <enum name="GL_HSL_LUMINOSITY_NV"/>
+ <enum name="GL_HSL_SATURATION_NV"/>
+ <enum name="GL_INVERT"/>
+ <enum name="GL_INVERT_OVG_NV"/>
+ <enum name="GL_INVERT_RGB_NV"/>
+ <enum name="GL_LIGHTEN_NV"/>
+ <enum name="GL_LINEARBURN_NV"/>
+ <enum name="GL_LINEARDODGE_NV"/>
+ <enum name="GL_LINEARLIGHT_NV"/>
+ <enum name="GL_MINUS_CLAMPED_NV"/>
+ <enum name="GL_MINUS_NV"/>
+ <enum name="GL_MULTIPLY_NV"/>
+ <enum name="GL_OVERLAY_NV"/>
+ <enum name="GL_PINLIGHT_NV"/>
+ <enum name="GL_PLUS_CLAMPED_ALPHA_NV"/>
+ <enum name="GL_PLUS_CLAMPED_NV"/>
+ <enum name="GL_PLUS_DARKER_NV"/>
+ <enum name="GL_PLUS_NV"/>
+ <enum name="GL_RED_NV"/>
+ <enum name="GL_SCREEN_NV"/>
+ <enum name="GL_SOFTLIGHT_NV"/>
+ <enum name="GL_SRC_ATOP_NV"/>
+ <enum name="GL_SRC_IN_NV"/>
+ <enum name="GL_SRC_NV"/>
+ <enum name="GL_SRC_OUT_NV"/>
+ <enum name="GL_SRC_OVER_NV"/>
+ <enum name="GL_UNCORRELATED_NV"/>
+ <enum name="GL_VIVIDLIGHT_NV"/>
+ <enum name="GL_XOR_NV"/>
+ <enum name="GL_ZERO"/>
+ <command name="glBlendParameteriNV"/>
+ <command name="glBlendBarrierNV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_blend_equation_advanced_coherent" supported="gl|gles2">
+ <require comment="Otherwise identical to GL_NV_blend_equation_advanced, just different semantic behavior">
+ <enum name="GL_BLEND_ADVANCED_COHERENT_NV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_blend_square" supported="gl"/>
+ <extension name="GL_NV_compute_program5" supported="gl">
+ <require>
+ <enum name="GL_COMPUTE_PROGRAM_NV"/>
+ <enum name="GL_COMPUTE_PROGRAM_PARAMETER_BUFFER_NV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_conditional_render" supported="gl">
+ <require>
+ <enum name="GL_QUERY_WAIT_NV"/>
+ <enum name="GL_QUERY_NO_WAIT_NV"/>
+ <enum name="GL_QUERY_BY_REGION_WAIT_NV"/>
+ <enum name="GL_QUERY_BY_REGION_NO_WAIT_NV"/>
+ <command name="glBeginConditionalRenderNV"/>
+ <command name="glEndConditionalRenderNV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_copy_buffer" supported="gles2">
+ <require>
+ <enum name="GL_COPY_READ_BUFFER_NV"/>
+ <enum name="GL_COPY_WRITE_BUFFER_NV"/>
+ <command name="glCopyBufferSubDataNV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_copy_depth_to_color" supported="gl">
+ <require>
+ <enum name="GL_DEPTH_STENCIL_TO_RGBA_NV"/>
+ <enum name="GL_DEPTH_STENCIL_TO_BGRA_NV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_copy_image" supported="gl">
+ <require>
+ <command name="glCopyImageSubDataNV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_coverage_sample" supported="gles2">
+ <require>
+ <enum name="GL_COVERAGE_COMPONENT_NV"/>
+ <enum name="GL_COVERAGE_COMPONENT4_NV"/>
+ <enum name="GL_COVERAGE_ATTACHMENT_NV"/>
+ <enum name="GL_COVERAGE_BUFFERS_NV"/>
+ <enum name="GL_COVERAGE_SAMPLES_NV"/>
+ <enum name="GL_COVERAGE_ALL_FRAGMENTS_NV"/>
+ <enum name="GL_COVERAGE_EDGE_FRAGMENTS_NV"/>
+ <enum name="GL_COVERAGE_AUTOMATIC_NV"/>
+ <enum name="GL_COVERAGE_BUFFER_BIT_NV"/>
+ <command name="glCoverageMaskNV"/>
+ <command name="glCoverageOperationNV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_deep_texture3D" supported="gl">
+ <require>
+ <enum name="GL_MAX_DEEP_3D_TEXTURE_WIDTH_HEIGHT_NV"/>
+ <enum name="GL_MAX_DEEP_3D_TEXTURE_DEPTH_NV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_depth_buffer_float" supported="gl">
+ <require>
+ <enum name="GL_DEPTH_COMPONENT32F_NV"/>
+ <enum name="GL_DEPTH32F_STENCIL8_NV"/>
+ <enum name="GL_FLOAT_32_UNSIGNED_INT_24_8_REV_NV"/>
+ <enum name="GL_DEPTH_BUFFER_FLOAT_MODE_NV"/>
+ <command name="glDepthRangedNV"/>
+ <command name="glClearDepthdNV"/>
+ <command name="glDepthBoundsdNV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_depth_clamp" supported="gl">
+ <require>
+ <enum name="GL_DEPTH_CLAMP_NV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_depth_nonlinear" supported="gles2">
+ <require>
+ <enum name="GL_DEPTH_COMPONENT16_NONLINEAR_NV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_draw_buffers" supported="gles2">
+ <require>
+ <enum name="GL_MAX_DRAW_BUFFERS_NV"/>
+ <enum name="GL_DRAW_BUFFER0_NV"/>
+ <enum name="GL_DRAW_BUFFER1_NV"/>
+ <enum name="GL_DRAW_BUFFER2_NV"/>
+ <enum name="GL_DRAW_BUFFER3_NV"/>
+ <enum name="GL_DRAW_BUFFER4_NV"/>
+ <enum name="GL_DRAW_BUFFER5_NV"/>
+ <enum name="GL_DRAW_BUFFER6_NV"/>
+ <enum name="GL_DRAW_BUFFER7_NV"/>
+ <enum name="GL_DRAW_BUFFER8_NV"/>
+ <enum name="GL_DRAW_BUFFER9_NV"/>
+ <enum name="GL_DRAW_BUFFER10_NV"/>
+ <enum name="GL_DRAW_BUFFER11_NV"/>
+ <enum name="GL_DRAW_BUFFER12_NV"/>
+ <enum name="GL_DRAW_BUFFER13_NV"/>
+ <enum name="GL_DRAW_BUFFER14_NV"/>
+ <enum name="GL_DRAW_BUFFER15_NV"/>
+ <enum name="GL_COLOR_ATTACHMENT0_NV"/>
+ <enum name="GL_COLOR_ATTACHMENT1_NV"/>
+ <enum name="GL_COLOR_ATTACHMENT2_NV"/>
+ <enum name="GL_COLOR_ATTACHMENT3_NV"/>
+ <enum name="GL_COLOR_ATTACHMENT4_NV"/>
+ <enum name="GL_COLOR_ATTACHMENT5_NV"/>
+ <enum name="GL_COLOR_ATTACHMENT6_NV"/>
+ <enum name="GL_COLOR_ATTACHMENT7_NV"/>
+ <enum name="GL_COLOR_ATTACHMENT8_NV"/>
+ <enum name="GL_COLOR_ATTACHMENT9_NV"/>
+ <enum name="GL_COLOR_ATTACHMENT10_NV"/>
+ <enum name="GL_COLOR_ATTACHMENT11_NV"/>
+ <enum name="GL_COLOR_ATTACHMENT12_NV"/>
+ <enum name="GL_COLOR_ATTACHMENT13_NV"/>
+ <enum name="GL_COLOR_ATTACHMENT14_NV"/>
+ <enum name="GL_COLOR_ATTACHMENT15_NV"/>
+ <command name="glDrawBuffersNV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_draw_instanced" supported="gles2">
+ <require>
+ <command name="glDrawArraysInstancedNV"/>
+ <command name="glDrawElementsInstancedNV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_draw_texture" supported="gl">
+ <require>
+ <command name="glDrawTextureNV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_evaluators" supported="gl">
+ <require>
+ <enum name="GL_EVAL_2D_NV"/>
+ <enum name="GL_EVAL_TRIANGULAR_2D_NV"/>
+ <enum name="GL_MAP_TESSELLATION_NV"/>
+ <enum name="GL_MAP_ATTRIB_U_ORDER_NV"/>
+ <enum name="GL_MAP_ATTRIB_V_ORDER_NV"/>
+ <enum name="GL_EVAL_FRACTIONAL_TESSELLATION_NV"/>
+ <enum name="GL_EVAL_VERTEX_ATTRIB0_NV"/>
+ <enum name="GL_EVAL_VERTEX_ATTRIB1_NV"/>
+ <enum name="GL_EVAL_VERTEX_ATTRIB2_NV"/>
+ <enum name="GL_EVAL_VERTEX_ATTRIB3_NV"/>
+ <enum name="GL_EVAL_VERTEX_ATTRIB4_NV"/>
+ <enum name="GL_EVAL_VERTEX_ATTRIB5_NV"/>
+ <enum name="GL_EVAL_VERTEX_ATTRIB6_NV"/>
+ <enum name="GL_EVAL_VERTEX_ATTRIB7_NV"/>
+ <enum name="GL_EVAL_VERTEX_ATTRIB8_NV"/>
+ <enum name="GL_EVAL_VERTEX_ATTRIB9_NV"/>
+ <enum name="GL_EVAL_VERTEX_ATTRIB10_NV"/>
+ <enum name="GL_EVAL_VERTEX_ATTRIB11_NV"/>
+ <enum name="GL_EVAL_VERTEX_ATTRIB12_NV"/>
+ <enum name="GL_EVAL_VERTEX_ATTRIB13_NV"/>
+ <enum name="GL_EVAL_VERTEX_ATTRIB14_NV"/>
+ <enum name="GL_EVAL_VERTEX_ATTRIB15_NV"/>
+ <enum name="GL_MAX_MAP_TESSELLATION_NV"/>
+ <enum name="GL_MAX_RATIONAL_EVAL_ORDER_NV"/>
+ <command name="glMapControlPointsNV"/>
+ <command name="glMapParameterivNV"/>
+ <command name="glMapParameterfvNV"/>
+ <command name="glGetMapControlPointsNV"/>
+ <command name="glGetMapParameterivNV"/>
+ <command name="glGetMapParameterfvNV"/>
+ <command name="glGetMapAttribParameterivNV"/>
+ <command name="glGetMapAttribParameterfvNV"/>
+ <command name="glEvalMapsNV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_explicit_attrib_location" supported="gles2"/>
+ <extension name="GL_NV_explicit_multisample" supported="gl">
+ <require>
+ <enum name="GL_SAMPLE_POSITION_NV"/>
+ <enum name="GL_SAMPLE_MASK_NV"/>
+ <enum name="GL_SAMPLE_MASK_VALUE_NV"/>
+ <enum name="GL_TEXTURE_BINDING_RENDERBUFFER_NV"/>
+ <enum name="GL_TEXTURE_RENDERBUFFER_DATA_STORE_BINDING_NV"/>
+ <enum name="GL_TEXTURE_RENDERBUFFER_NV"/>
+ <enum name="GL_SAMPLER_RENDERBUFFER_NV"/>
+ <enum name="GL_INT_SAMPLER_RENDERBUFFER_NV"/>
+ <enum name="GL_UNSIGNED_INT_SAMPLER_RENDERBUFFER_NV"/>
+ <enum name="GL_MAX_SAMPLE_MASK_WORDS_NV"/>
+ <command name="glGetMultisamplefvNV"/>
+ <command name="glSampleMaskIndexedNV"/>
+ <command name="glTexRenderbufferNV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_fbo_color_attachments" supported="gles2">
+ <require>
+ <enum name="GL_MAX_COLOR_ATTACHMENTS_NV"/>
+ <enum name="GL_COLOR_ATTACHMENT0_NV"/>
+ <enum name="GL_COLOR_ATTACHMENT1_NV"/>
+ <enum name="GL_COLOR_ATTACHMENT2_NV"/>
+ <enum name="GL_COLOR_ATTACHMENT3_NV"/>
+ <enum name="GL_COLOR_ATTACHMENT4_NV"/>
+ <enum name="GL_COLOR_ATTACHMENT5_NV"/>
+ <enum name="GL_COLOR_ATTACHMENT6_NV"/>
+ <enum name="GL_COLOR_ATTACHMENT7_NV"/>
+ <enum name="GL_COLOR_ATTACHMENT8_NV"/>
+ <enum name="GL_COLOR_ATTACHMENT9_NV"/>
+ <enum name="GL_COLOR_ATTACHMENT10_NV"/>
+ <enum name="GL_COLOR_ATTACHMENT11_NV"/>
+ <enum name="GL_COLOR_ATTACHMENT12_NV"/>
+ <enum name="GL_COLOR_ATTACHMENT13_NV"/>
+ <enum name="GL_COLOR_ATTACHMENT14_NV"/>
+ <enum name="GL_COLOR_ATTACHMENT15_NV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_fence" supported="gl|gles1|gles2">
+ <require>
+ <enum name="GL_ALL_COMPLETED_NV"/>
+ <enum name="GL_FENCE_STATUS_NV"/>
+ <enum name="GL_FENCE_CONDITION_NV"/>
+ <command name="glDeleteFencesNV"/>
+ <command name="glGenFencesNV"/>
+ <command name="glIsFenceNV"/>
+ <command name="glTestFenceNV"/>
+ <command name="glGetFenceivNV"/>
+ <command name="glFinishFenceNV"/>
+ <command name="glSetFenceNV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_float_buffer" supported="gl">
+ <require>
+ <enum name="GL_FLOAT_R_NV"/>
+ <enum name="GL_FLOAT_RG_NV"/>
+ <enum name="GL_FLOAT_RGB_NV"/>
+ <enum name="GL_FLOAT_RGBA_NV"/>
+ <enum name="GL_FLOAT_R16_NV"/>
+ <enum name="GL_FLOAT_R32_NV"/>
+ <enum name="GL_FLOAT_RG16_NV"/>
+ <enum name="GL_FLOAT_RG32_NV"/>
+ <enum name="GL_FLOAT_RGB16_NV"/>
+ <enum name="GL_FLOAT_RGB32_NV"/>
+ <enum name="GL_FLOAT_RGBA16_NV"/>
+ <enum name="GL_FLOAT_RGBA32_NV"/>
+ <enum name="GL_TEXTURE_FLOAT_COMPONENTS_NV"/>
+ <enum name="GL_FLOAT_CLEAR_COLOR_VALUE_NV"/>
+ <enum name="GL_FLOAT_RGBA_MODE_NV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_fog_distance" supported="gl">
+ <require>
+ <enum name="GL_FOG_DISTANCE_MODE_NV"/>
+ <enum name="GL_EYE_RADIAL_NV"/>
+ <enum name="GL_EYE_PLANE_ABSOLUTE_NV"/>
+ <enum name="GL_EYE_PLANE"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_fragment_program" supported="gl">
+ <require>
+ <enum name="GL_MAX_FRAGMENT_PROGRAM_LOCAL_PARAMETERS_NV"/>
+ <enum name="GL_FRAGMENT_PROGRAM_NV"/>
+ <enum name="GL_MAX_TEXTURE_COORDS_NV"/>
+ <enum name="GL_MAX_TEXTURE_IMAGE_UNITS_NV"/>
+ <enum name="GL_FRAGMENT_PROGRAM_BINDING_NV"/>
+ <enum name="GL_PROGRAM_ERROR_STRING_NV"/>
+ </require>
+ <require comment="Some NV_fragment_program entry points are shared with ARB_vertex_program">
+ <command name="glProgramNamedParameter4fNV"/>
+ <command name="glProgramNamedParameter4fvNV"/>
+ <command name="glProgramNamedParameter4dNV"/>
+ <command name="glProgramNamedParameter4dvNV"/>
+ <command name="glGetProgramNamedParameterfvNV"/>
+ <command name="glGetProgramNamedParameterdvNV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_fragment_program2" supported="gl">
+ <require>
+ <enum name="GL_MAX_PROGRAM_EXEC_INSTRUCTIONS_NV"/>
+ <enum name="GL_MAX_PROGRAM_CALL_DEPTH_NV"/>
+ <enum name="GL_MAX_PROGRAM_IF_DEPTH_NV"/>
+ <enum name="GL_MAX_PROGRAM_LOOP_DEPTH_NV"/>
+ <enum name="GL_MAX_PROGRAM_LOOP_COUNT_NV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_fragment_program4" supported="gl"/>
+ <extension name="GL_NV_fragment_program_option" supported="gl"/>
+ <extension name="GL_NV_framebuffer_blit" supported="gles2">
+ <require>
+ <enum name="GL_READ_FRAMEBUFFER_NV"/>
+ <enum name="GL_DRAW_FRAMEBUFFER_NV"/>
+ <enum name="GL_DRAW_FRAMEBUFFER_BINDING_NV"/>
+ <enum name="GL_READ_FRAMEBUFFER_BINDING_NV"/>
+ <command name="glBlitFramebufferNV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_framebuffer_multisample" supported="gles2">
+ <require>
+ <enum name="GL_RENDERBUFFER_SAMPLES_NV"/>
+ <enum name="GL_FRAMEBUFFER_INCOMPLETE_MULTISAMPLE_NV"/>
+ <enum name="GL_MAX_SAMPLES_NV"/>
+ <command name="glRenderbufferStorageMultisampleNV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_framebuffer_multisample_coverage" supported="gl">
+ <require>
+ <enum name="GL_RENDERBUFFER_COVERAGE_SAMPLES_NV"/>
+ <enum name="GL_RENDERBUFFER_COLOR_SAMPLES_NV"/>
+ <enum name="GL_MAX_MULTISAMPLE_COVERAGE_MODES_NV"/>
+ <enum name="GL_MULTISAMPLE_COVERAGE_MODES_NV"/>
+ <command name="glRenderbufferStorageMultisampleCoverageNV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_generate_mipmap_sRGB" supported="gles2"/>
+ <extension name="GL_NV_geometry_program4" supported="gl">
+ <require>
+ <enum name="GL_LINES_ADJACENCY_EXT"/>
+ <enum name="GL_LINE_STRIP_ADJACENCY_EXT"/>
+ <enum name="GL_TRIANGLES_ADJACENCY_EXT"/>
+ <enum name="GL_TRIANGLE_STRIP_ADJACENCY_EXT"/>
+ <enum name="GL_GEOMETRY_PROGRAM_NV"/>
+ <enum name="GL_MAX_PROGRAM_OUTPUT_VERTICES_NV"/>
+ <enum name="GL_MAX_PROGRAM_TOTAL_OUTPUT_COMPONENTS_NV"/>
+ <enum name="GL_GEOMETRY_VERTICES_OUT_EXT"/>
+ <enum name="GL_GEOMETRY_INPUT_TYPE_EXT"/>
+ <enum name="GL_GEOMETRY_OUTPUT_TYPE_EXT"/>
+ <enum name="GL_MAX_GEOMETRY_TEXTURE_IMAGE_UNITS_EXT"/>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_LAYERED_EXT"/>
+ <enum name="GL_FRAMEBUFFER_INCOMPLETE_LAYER_TARGETS_EXT"/>
+ <enum name="GL_FRAMEBUFFER_INCOMPLETE_LAYER_COUNT_EXT"/>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER_EXT"/>
+ <enum name="GL_PROGRAM_POINT_SIZE_EXT"/>
+ <command name="glProgramVertexLimitNV"/>
+ <command name="glFramebufferTextureEXT"/>
+ <command name="glFramebufferTextureLayerEXT"/>
+ <command name="glFramebufferTextureFaceEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_geometry_shader4" supported="gl"/>
+ <extension name="GL_NV_gpu_program4" supported="gl">
+ <require>
+ <enum name="GL_MIN_PROGRAM_TEXEL_OFFSET_NV"/>
+ <enum name="GL_MAX_PROGRAM_TEXEL_OFFSET_NV"/>
+ <enum name="GL_PROGRAM_ATTRIB_COMPONENTS_NV"/>
+ <enum name="GL_PROGRAM_RESULT_COMPONENTS_NV"/>
+ <enum name="GL_MAX_PROGRAM_ATTRIB_COMPONENTS_NV"/>
+ <enum name="GL_MAX_PROGRAM_RESULT_COMPONENTS_NV"/>
+ <enum name="GL_MAX_PROGRAM_GENERIC_ATTRIBS_NV"/>
+ <enum name="GL_MAX_PROGRAM_GENERIC_RESULTS_NV"/>
+ <command name="glProgramLocalParameterI4iNV"/>
+ <command name="glProgramLocalParameterI4ivNV"/>
+ <command name="glProgramLocalParametersI4ivNV"/>
+ <command name="glProgramLocalParameterI4uiNV"/>
+ <command name="glProgramLocalParameterI4uivNV"/>
+ <command name="glProgramLocalParametersI4uivNV"/>
+ <command name="glProgramEnvParameterI4iNV"/>
+ <command name="glProgramEnvParameterI4ivNV"/>
+ <command name="glProgramEnvParametersI4ivNV"/>
+ <command name="glProgramEnvParameterI4uiNV"/>
+ <command name="glProgramEnvParameterI4uivNV"/>
+ <command name="glProgramEnvParametersI4uivNV"/>
+ <command name="glGetProgramLocalParameterIivNV"/>
+ <command name="glGetProgramLocalParameterIuivNV"/>
+ <command name="glGetProgramEnvParameterIivNV"/>
+ <command name="glGetProgramEnvParameterIuivNV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_gpu_program5" supported="gl">
+ <require>
+ <enum name="GL_MAX_GEOMETRY_PROGRAM_INVOCATIONS_NV"/>
+ <enum name="GL_MIN_FRAGMENT_INTERPOLATION_OFFSET_NV"/>
+ <enum name="GL_MAX_FRAGMENT_INTERPOLATION_OFFSET_NV"/>
+ <enum name="GL_FRAGMENT_PROGRAM_INTERPOLATION_OFFSET_BITS_NV"/>
+ <enum name="GL_MIN_PROGRAM_TEXTURE_GATHER_OFFSET_NV"/>
+ <enum name="GL_MAX_PROGRAM_TEXTURE_GATHER_OFFSET_NV"/>
+ <enum name="GL_MAX_PROGRAM_SUBROUTINE_PARAMETERS_NV"/>
+ <enum name="GL_MAX_PROGRAM_SUBROUTINE_NUM_NV"/>
+ <command name="glProgramSubroutineParametersuivNV"/>
+ <command name="glGetProgramSubroutineParameteruivNV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_gpu_program5_mem_extended" supported="gl"/>
+ <extension name="GL_NV_gpu_shader5" supported="gl">
+ <require>
+ <enum name="GL_INT64_NV"/>
+ <enum name="GL_UNSIGNED_INT64_NV"/>
+ <enum name="GL_INT8_NV"/>
+ <enum name="GL_INT8_VEC2_NV"/>
+ <enum name="GL_INT8_VEC3_NV"/>
+ <enum name="GL_INT8_VEC4_NV"/>
+ <enum name="GL_INT16_NV"/>
+ <enum name="GL_INT16_VEC2_NV"/>
+ <enum name="GL_INT16_VEC3_NV"/>
+ <enum name="GL_INT16_VEC4_NV"/>
+ <enum name="GL_INT64_VEC2_NV"/>
+ <enum name="GL_INT64_VEC3_NV"/>
+ <enum name="GL_INT64_VEC4_NV"/>
+ <enum name="GL_UNSIGNED_INT8_NV"/>
+ <enum name="GL_UNSIGNED_INT8_VEC2_NV"/>
+ <enum name="GL_UNSIGNED_INT8_VEC3_NV"/>
+ <enum name="GL_UNSIGNED_INT8_VEC4_NV"/>
+ <enum name="GL_UNSIGNED_INT16_NV"/>
+ <enum name="GL_UNSIGNED_INT16_VEC2_NV"/>
+ <enum name="GL_UNSIGNED_INT16_VEC3_NV"/>
+ <enum name="GL_UNSIGNED_INT16_VEC4_NV"/>
+ <enum name="GL_UNSIGNED_INT64_VEC2_NV"/>
+ <enum name="GL_UNSIGNED_INT64_VEC3_NV"/>
+ <enum name="GL_UNSIGNED_INT64_VEC4_NV"/>
+ <enum name="GL_FLOAT16_NV"/>
+ <enum name="GL_FLOAT16_VEC2_NV"/>
+ <enum name="GL_FLOAT16_VEC3_NV"/>
+ <enum name="GL_FLOAT16_VEC4_NV"/>
+ <enum name="GL_PATCHES"/>
+ <command name="glUniform1i64NV"/>
+ <command name="glUniform2i64NV"/>
+ <command name="glUniform3i64NV"/>
+ <command name="glUniform4i64NV"/>
+ <command name="glUniform1i64vNV"/>
+ <command name="glUniform2i64vNV"/>
+ <command name="glUniform3i64vNV"/>
+ <command name="glUniform4i64vNV"/>
+ <command name="glUniform1ui64NV"/>
+ <command name="glUniform2ui64NV"/>
+ <command name="glUniform3ui64NV"/>
+ <command name="glUniform4ui64NV"/>
+ <command name="glUniform1ui64vNV"/>
+ <command name="glUniform2ui64vNV"/>
+ <command name="glUniform3ui64vNV"/>
+ <command name="glUniform4ui64vNV"/>
+ <command name="glGetUniformi64vNV"/>
+ </require>
+ <require comment="Supported only if GL_EXT_direct_state_access is supported">
+ <command name="glProgramUniform1i64NV"/>
+ <command name="glProgramUniform2i64NV"/>
+ <command name="glProgramUniform3i64NV"/>
+ <command name="glProgramUniform4i64NV"/>
+ <command name="glProgramUniform1i64vNV"/>
+ <command name="glProgramUniform2i64vNV"/>
+ <command name="glProgramUniform3i64vNV"/>
+ <command name="glProgramUniform4i64vNV"/>
+ <command name="glProgramUniform1ui64NV"/>
+ <command name="glProgramUniform2ui64NV"/>
+ <command name="glProgramUniform3ui64NV"/>
+ <command name="glProgramUniform4ui64NV"/>
+ <command name="glProgramUniform1ui64vNV"/>
+ <command name="glProgramUniform2ui64vNV"/>
+ <command name="glProgramUniform3ui64vNV"/>
+ <command name="glProgramUniform4ui64vNV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_half_float" supported="gl">
+ <require>
+ <enum name="GL_HALF_FLOAT_NV"/>
+ <command name="glVertex2hNV"/>
+ <command name="glVertex2hvNV"/>
+ <command name="glVertex3hNV"/>
+ <command name="glVertex3hvNV"/>
+ <command name="glVertex4hNV"/>
+ <command name="glVertex4hvNV"/>
+ <command name="glNormal3hNV"/>
+ <command name="glNormal3hvNV"/>
+ <command name="glColor3hNV"/>
+ <command name="glColor3hvNV"/>
+ <command name="glColor4hNV"/>
+ <command name="glColor4hvNV"/>
+ <command name="glTexCoord1hNV"/>
+ <command name="glTexCoord1hvNV"/>
+ <command name="glTexCoord2hNV"/>
+ <command name="glTexCoord2hvNV"/>
+ <command name="glTexCoord3hNV"/>
+ <command name="glTexCoord3hvNV"/>
+ <command name="glTexCoord4hNV"/>
+ <command name="glTexCoord4hvNV"/>
+ <command name="glMultiTexCoord1hNV"/>
+ <command name="glMultiTexCoord1hvNV"/>
+ <command name="glMultiTexCoord2hNV"/>
+ <command name="glMultiTexCoord2hvNV"/>
+ <command name="glMultiTexCoord3hNV"/>
+ <command name="glMultiTexCoord3hvNV"/>
+ <command name="glMultiTexCoord4hNV"/>
+ <command name="glMultiTexCoord4hvNV"/>
+ <command name="glFogCoordhNV"/>
+ <command name="glFogCoordhvNV"/>
+ <command name="glSecondaryColor3hNV"/>
+ <command name="glSecondaryColor3hvNV"/>
+ <command name="glVertexWeighthNV"/>
+ <command name="glVertexWeighthvNV"/>
+ <command name="glVertexAttrib1hNV"/>
+ <command name="glVertexAttrib1hvNV"/>
+ <command name="glVertexAttrib2hNV"/>
+ <command name="glVertexAttrib2hvNV"/>
+ <command name="glVertexAttrib3hNV"/>
+ <command name="glVertexAttrib3hvNV"/>
+ <command name="glVertexAttrib4hNV"/>
+ <command name="glVertexAttrib4hvNV"/>
+ <command name="glVertexAttribs1hvNV"/>
+ <command name="glVertexAttribs2hvNV"/>
+ <command name="glVertexAttribs3hvNV"/>
+ <command name="glVertexAttribs4hvNV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_instanced_arrays" supported="gles2">
+ <require>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY_DIVISOR_NV"/>
+ <command name="glVertexAttribDivisorNV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_light_max_exponent" supported="gl">
+ <require>
+ <enum name="GL_MAX_SHININESS_NV"/>
+ <enum name="GL_MAX_SPOT_EXPONENT_NV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_multisample_coverage" supported="gl">
+ <require>
+ <enum name="GL_SAMPLES_ARB"/>
+ <enum name="GL_COLOR_SAMPLES_NV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_multisample_filter_hint" supported="gl">
+ <require>
+ <enum name="GL_MULTISAMPLE_FILTER_HINT_NV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_non_square_matrices" supported="gles2">
+ <require>
+ <enum name="GL_FLOAT_MAT2x3_NV"/>
+ <enum name="GL_FLOAT_MAT2x4_NV"/>
+ <enum name="GL_FLOAT_MAT3x2_NV"/>
+ <enum name="GL_FLOAT_MAT3x4_NV"/>
+ <enum name="GL_FLOAT_MAT4x2_NV"/>
+ <enum name="GL_FLOAT_MAT4x3_NV"/>
+ <command name="glUniformMatrix2x3fvNV"/>
+ <command name="glUniformMatrix3x2fvNV"/>
+ <command name="glUniformMatrix2x4fvNV"/>
+ <command name="glUniformMatrix4x2fvNV"/>
+ <command name="glUniformMatrix3x4fvNV"/>
+ <command name="glUniformMatrix4x3fvNV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_occlusion_query" supported="gl">
+ <require>
+ <enum name="GL_PIXEL_COUNTER_BITS_NV"/>
+ <enum name="GL_CURRENT_OCCLUSION_QUERY_ID_NV"/>
+ <enum name="GL_PIXEL_COUNT_NV"/>
+ <enum name="GL_PIXEL_COUNT_AVAILABLE_NV"/>
+ <command name="glGenOcclusionQueriesNV"/>
+ <command name="glDeleteOcclusionQueriesNV"/>
+ <command name="glIsOcclusionQueryNV"/>
+ <command name="glBeginOcclusionQueryNV"/>
+ <command name="glEndOcclusionQueryNV"/>
+ <command name="glGetOcclusionQueryivNV"/>
+ <command name="glGetOcclusionQueryuivNV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_packed_depth_stencil" supported="gl">
+ <require>
+ <enum name="GL_DEPTH_STENCIL_NV"/>
+ <enum name="GL_UNSIGNED_INT_24_8_NV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_parameter_buffer_object" supported="gl">
+ <require>
+ <enum name="GL_MAX_PROGRAM_PARAMETER_BUFFER_BINDINGS_NV"/>
+ <enum name="GL_MAX_PROGRAM_PARAMETER_BUFFER_SIZE_NV"/>
+ <enum name="GL_VERTEX_PROGRAM_PARAMETER_BUFFER_NV"/>
+ <enum name="GL_GEOMETRY_PROGRAM_PARAMETER_BUFFER_NV"/>
+ <enum name="GL_FRAGMENT_PROGRAM_PARAMETER_BUFFER_NV"/>
+ <command name="glProgramBufferParametersfvNV"/>
+ <command name="glProgramBufferParametersIivNV"/>
+ <command name="glProgramBufferParametersIuivNV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_parameter_buffer_object2" supported="gl"/>
+ <extension name="GL_NV_path_rendering" supported="gl">
+ <require>
+ <enum name="GL_PATH_FORMAT_SVG_NV"/>
+ <enum name="GL_PATH_FORMAT_PS_NV"/>
+ <enum name="GL_STANDARD_FONT_NAME_NV"/>
+ <enum name="GL_SYSTEM_FONT_NAME_NV"/>
+ <enum name="GL_FILE_NAME_NV"/>
+ <enum name="GL_PATH_STROKE_WIDTH_NV"/>
+ <enum name="GL_PATH_END_CAPS_NV"/>
+ <enum name="GL_PATH_INITIAL_END_CAP_NV"/>
+ <enum name="GL_PATH_TERMINAL_END_CAP_NV"/>
+ <enum name="GL_PATH_JOIN_STYLE_NV"/>
+ <enum name="GL_PATH_MITER_LIMIT_NV"/>
+ <enum name="GL_PATH_DASH_CAPS_NV"/>
+ <enum name="GL_PATH_INITIAL_DASH_CAP_NV"/>
+ <enum name="GL_PATH_TERMINAL_DASH_CAP_NV"/>
+ <enum name="GL_PATH_DASH_OFFSET_NV"/>
+ <enum name="GL_PATH_CLIENT_LENGTH_NV"/>
+ <enum name="GL_PATH_FILL_MODE_NV"/>
+ <enum name="GL_PATH_FILL_MASK_NV"/>
+ <enum name="GL_PATH_FILL_COVER_MODE_NV"/>
+ <enum name="GL_PATH_STROKE_COVER_MODE_NV"/>
+ <enum name="GL_PATH_STROKE_MASK_NV"/>
+ <enum name="GL_COUNT_UP_NV"/>
+ <enum name="GL_COUNT_DOWN_NV"/>
+ <enum name="GL_PATH_OBJECT_BOUNDING_BOX_NV"/>
+ <enum name="GL_CONVEX_HULL_NV"/>
+ <enum name="GL_BOUNDING_BOX_NV"/>
+ <enum name="GL_TRANSLATE_X_NV"/>
+ <enum name="GL_TRANSLATE_Y_NV"/>
+ <enum name="GL_TRANSLATE_2D_NV"/>
+ <enum name="GL_TRANSLATE_3D_NV"/>
+ <enum name="GL_AFFINE_2D_NV"/>
+ <enum name="GL_AFFINE_3D_NV"/>
+ <enum name="GL_TRANSPOSE_AFFINE_2D_NV"/>
+ <enum name="GL_TRANSPOSE_AFFINE_3D_NV"/>
+ <enum name="GL_UTF8_NV"/>
+ <enum name="GL_UTF16_NV"/>
+ <enum name="GL_BOUNDING_BOX_OF_BOUNDING_BOXES_NV"/>
+ <enum name="GL_PATH_COMMAND_COUNT_NV"/>
+ <enum name="GL_PATH_COORD_COUNT_NV"/>
+ <enum name="GL_PATH_DASH_ARRAY_COUNT_NV"/>
+ <enum name="GL_PATH_COMPUTED_LENGTH_NV"/>
+ <enum name="GL_PATH_FILL_BOUNDING_BOX_NV"/>
+ <enum name="GL_PATH_STROKE_BOUNDING_BOX_NV"/>
+ <enum name="GL_SQUARE_NV"/>
+ <enum name="GL_ROUND_NV"/>
+ <enum name="GL_TRIANGULAR_NV"/>
+ <enum name="GL_BEVEL_NV"/>
+ <enum name="GL_MITER_REVERT_NV"/>
+ <enum name="GL_MITER_TRUNCATE_NV"/>
+ <enum name="GL_SKIP_MISSING_GLYPH_NV"/>
+ <enum name="GL_USE_MISSING_GLYPH_NV"/>
+ <enum name="GL_PATH_ERROR_POSITION_NV"/>
+ <enum name="GL_PATH_FOG_GEN_MODE_NV"/>
+ <enum name="GL_ACCUM_ADJACENT_PAIRS_NV"/>
+ <enum name="GL_ADJACENT_PAIRS_NV"/>
+ <enum name="GL_FIRST_TO_REST_NV"/>
+ <enum name="GL_PATH_GEN_MODE_NV"/>
+ <enum name="GL_PATH_GEN_COEFF_NV"/>
+ <enum name="GL_PATH_GEN_COLOR_FORMAT_NV"/>
+ <enum name="GL_PATH_GEN_COMPONENTS_NV"/>
+ <enum name="GL_PATH_STENCIL_FUNC_NV"/>
+ <enum name="GL_PATH_STENCIL_REF_NV"/>
+ <enum name="GL_PATH_STENCIL_VALUE_MASK_NV"/>
+ <enum name="GL_PATH_STENCIL_DEPTH_OFFSET_FACTOR_NV"/>
+ <enum name="GL_PATH_STENCIL_DEPTH_OFFSET_UNITS_NV"/>
+ <enum name="GL_PATH_COVER_DEPTH_FUNC_NV"/>
+ <enum name="GL_PATH_DASH_OFFSET_RESET_NV"/>
+ <enum name="GL_MOVE_TO_RESETS_NV"/>
+ <enum name="GL_MOVE_TO_CONTINUES_NV"/>
+ <enum name="GL_CLOSE_PATH_NV"/>
+ <enum name="GL_MOVE_TO_NV"/>
+ <enum name="GL_RELATIVE_MOVE_TO_NV"/>
+ <enum name="GL_LINE_TO_NV"/>
+ <enum name="GL_RELATIVE_LINE_TO_NV"/>
+ <enum name="GL_HORIZONTAL_LINE_TO_NV"/>
+ <enum name="GL_RELATIVE_HORIZONTAL_LINE_TO_NV"/>
+ <enum name="GL_VERTICAL_LINE_TO_NV"/>
+ <enum name="GL_RELATIVE_VERTICAL_LINE_TO_NV"/>
+ <enum name="GL_QUADRATIC_CURVE_TO_NV"/>
+ <enum name="GL_RELATIVE_QUADRATIC_CURVE_TO_NV"/>
+ <enum name="GL_CUBIC_CURVE_TO_NV"/>
+ <enum name="GL_RELATIVE_CUBIC_CURVE_TO_NV"/>
+ <enum name="GL_SMOOTH_QUADRATIC_CURVE_TO_NV"/>
+ <enum name="GL_RELATIVE_SMOOTH_QUADRATIC_CURVE_TO_NV"/>
+ <enum name="GL_SMOOTH_CUBIC_CURVE_TO_NV"/>
+ <enum name="GL_RELATIVE_SMOOTH_CUBIC_CURVE_TO_NV"/>
+ <enum name="GL_SMALL_CCW_ARC_TO_NV"/>
+ <enum name="GL_RELATIVE_SMALL_CCW_ARC_TO_NV"/>
+ <enum name="GL_SMALL_CW_ARC_TO_NV"/>
+ <enum name="GL_RELATIVE_SMALL_CW_ARC_TO_NV"/>
+ <enum name="GL_LARGE_CCW_ARC_TO_NV"/>
+ <enum name="GL_RELATIVE_LARGE_CCW_ARC_TO_NV"/>
+ <enum name="GL_LARGE_CW_ARC_TO_NV"/>
+ <enum name="GL_RELATIVE_LARGE_CW_ARC_TO_NV"/>
+ <enum name="GL_RESTART_PATH_NV"/>
+ <enum name="GL_DUP_FIRST_CUBIC_CURVE_TO_NV"/>
+ <enum name="GL_DUP_LAST_CUBIC_CURVE_TO_NV"/>
+ <enum name="GL_RECT_NV"/>
+ <enum name="GL_CIRCULAR_CCW_ARC_TO_NV"/>
+ <enum name="GL_CIRCULAR_CW_ARC_TO_NV"/>
+ <enum name="GL_CIRCULAR_TANGENT_ARC_TO_NV"/>
+ <enum name="GL_ARC_TO_NV"/>
+ <enum name="GL_RELATIVE_ARC_TO_NV"/>
+ <enum name="GL_BOLD_BIT_NV"/>
+ <enum name="GL_ITALIC_BIT_NV"/>
+ <enum name="GL_GLYPH_WIDTH_BIT_NV"/>
+ <enum name="GL_GLYPH_HEIGHT_BIT_NV"/>
+ <enum name="GL_GLYPH_HORIZONTAL_BEARING_X_BIT_NV"/>
+ <enum name="GL_GLYPH_HORIZONTAL_BEARING_Y_BIT_NV"/>
+ <enum name="GL_GLYPH_HORIZONTAL_BEARING_ADVANCE_BIT_NV"/>
+ <enum name="GL_GLYPH_VERTICAL_BEARING_X_BIT_NV"/>
+ <enum name="GL_GLYPH_VERTICAL_BEARING_Y_BIT_NV"/>
+ <enum name="GL_GLYPH_VERTICAL_BEARING_ADVANCE_BIT_NV"/>
+ <enum name="GL_GLYPH_HAS_KERNING_BIT_NV"/>
+ <enum name="GL_FONT_X_MIN_BOUNDS_BIT_NV"/>
+ <enum name="GL_FONT_Y_MIN_BOUNDS_BIT_NV"/>
+ <enum name="GL_FONT_X_MAX_BOUNDS_BIT_NV"/>
+ <enum name="GL_FONT_Y_MAX_BOUNDS_BIT_NV"/>
+ <enum name="GL_FONT_UNITS_PER_EM_BIT_NV"/>
+ <enum name="GL_FONT_ASCENDER_BIT_NV"/>
+ <enum name="GL_FONT_DESCENDER_BIT_NV"/>
+ <enum name="GL_FONT_HEIGHT_BIT_NV"/>
+ <enum name="GL_FONT_MAX_ADVANCE_WIDTH_BIT_NV"/>
+ <enum name="GL_FONT_MAX_ADVANCE_HEIGHT_BIT_NV"/>
+ <enum name="GL_FONT_UNDERLINE_POSITION_BIT_NV"/>
+ <enum name="GL_FONT_UNDERLINE_THICKNESS_BIT_NV"/>
+ <enum name="GL_FONT_HAS_KERNING_BIT_NV"/>
+ <enum name="GL_PRIMARY_COLOR"/>
+ <enum name="GL_PRIMARY_COLOR_NV"/>
+ <enum name="GL_SECONDARY_COLOR_NV"/>
+ <command name="glGenPathsNV"/>
+ <command name="glDeletePathsNV"/>
+ <command name="glIsPathNV"/>
+ <command name="glPathCommandsNV"/>
+ <command name="glPathCoordsNV"/>
+ <command name="glPathSubCommandsNV"/>
+ <command name="glPathSubCoordsNV"/>
+ <command name="glPathStringNV"/>
+ <command name="glPathGlyphsNV"/>
+ <command name="glPathGlyphRangeNV"/>
+ <command name="glWeightPathsNV"/>
+ <command name="glCopyPathNV"/>
+ <command name="glInterpolatePathsNV"/>
+ <command name="glTransformPathNV"/>
+ <command name="glPathParameterivNV"/>
+ <command name="glPathParameteriNV"/>
+ <command name="glPathParameterfvNV"/>
+ <command name="glPathParameterfNV"/>
+ <command name="glPathDashArrayNV"/>
+ <command name="glPathStencilFuncNV"/>
+ <command name="glPathStencilDepthOffsetNV"/>
+ <command name="glStencilFillPathNV"/>
+ <command name="glStencilStrokePathNV"/>
+ <command name="glStencilFillPathInstancedNV"/>
+ <command name="glStencilStrokePathInstancedNV"/>
+ <command name="glPathCoverDepthFuncNV"/>
+ <command name="glPathColorGenNV"/>
+ <command name="glPathTexGenNV"/>
+ <command name="glPathFogGenNV"/>
+ <command name="glCoverFillPathNV"/>
+ <command name="glCoverStrokePathNV"/>
+ <command name="glCoverFillPathInstancedNV"/>
+ <command name="glCoverStrokePathInstancedNV"/>
+ <command name="glGetPathParameterivNV"/>
+ <command name="glGetPathParameterfvNV"/>
+ <command name="glGetPathCommandsNV"/>
+ <command name="glGetPathCoordsNV"/>
+ <command name="glGetPathDashArrayNV"/>
+ <command name="glGetPathMetricsNV"/>
+ <command name="glGetPathMetricRangeNV"/>
+ <command name="glGetPathSpacingNV"/>
+ <command name="glGetPathColorGenivNV"/>
+ <command name="glGetPathColorGenfvNV"/>
+ <command name="glGetPathTexGenivNV"/>
+ <command name="glGetPathTexGenfvNV"/>
+ <command name="glIsPointInFillPathNV"/>
+ <command name="glIsPointInStrokePathNV"/>
+ <command name="glGetPathLengthNV"/>
+ <command name="glPointAlongPathNV"/>
+ </require>
+ <require comment="API revision 1.2">
+ <enum name="GL_ROUNDED_RECT_NV"/>
+ <enum name="GL_RELATIVE_ROUNDED_RECT_NV"/>
+ <enum name="GL_ROUNDED_RECT2_NV"/>
+ <enum name="GL_RELATIVE_ROUNDED_RECT2_NV"/>
+ <enum name="GL_ROUNDED_RECT4_NV"/>
+ <enum name="GL_RELATIVE_ROUNDED_RECT4_NV"/>
+ <enum name="GL_ROUNDED_RECT8_NV"/>
+ <enum name="GL_RELATIVE_ROUNDED_RECT8_NV"/>
+ <enum name="GL_RELATIVE_RECT_NV"/>
+ <enum name="GL_FONT_GLYPHS_AVAILABLE_NV"/>
+ <enum name="GL_FONT_TARGET_UNAVAILABLE_NV"/>
+ <enum name="GL_FONT_UNAVAILABLE_NV"/>
+ <enum name="GL_FONT_UNINTELLIGIBLE_NV"/>
+ <command name="glMatrixLoad3x2fNV"/>
+ <command name="glMatrixLoad3x3fNV"/>
+ <command name="glMatrixLoadTranspose3x3fNV"/>
+ <command name="glMatrixMult3x2fNV"/>
+ <command name="glMatrixMult3x3fNV"/>
+ <command name="glMatrixMultTranspose3x3fNV"/>
+ <command name="glStencilThenCoverFillPathNV"/>
+ <command name="glStencilThenCoverStrokePathNV"/>
+ <command name="glStencilThenCoverFillPathInstancedNV"/>
+ <command name="glStencilThenCoverStrokePathInstancedNV"/>
+ <command name="glPathGlyphIndexRangeNV"/>
+ </require>
+ <require comment="API revision 1.3">
+ <enum name="GL_CONIC_CURVE_TO_NV"/>
+ <enum name="GL_RELATIVE_CONIC_CURVE_TO_NV"/>
+ <enum name="GL_FONT_NUM_GLYPH_INDICES_BIT_NV"/>
+ <enum name="GL_STANDARD_FONT_FORMAT_NV"/>
+ <command name="glPathGlyphIndexArrayNV"/>
+ <command name="glPathMemoryGlyphIndexArrayNV"/>
+ <command name="glProgramPathFragmentInputGenNV"/>
+ <command name="glGetProgramResourcefvNV"/>
+ </require>
+ <require api="gl" profile="compatibility">
+ <enum name="GL_2_BYTES_NV"/>
+ <enum name="GL_3_BYTES_NV"/>
+ <enum name="GL_4_BYTES_NV"/>
+ <enum name="GL_EYE_LINEAR_NV"/>
+ <enum name="GL_OBJECT_LINEAR_NV"/>
+ <enum name="GL_CONSTANT_NV"/>
+ </require>
+ <require comment="Other API additions of unknown history">
+ <enum name="GL_PATH_PROJECTION_NV"/>
+ <enum name="GL_PATH_MODELVIEW_NV"/>
+ <enum name="GL_PATH_MODELVIEW_STACK_DEPTH_NV"/>
+ <enum name="GL_PATH_MODELVIEW_MATRIX_NV"/>
+ <enum name="GL_PATH_MAX_MODELVIEW_STACK_DEPTH_NV"/>
+ <enum name="GL_PATH_TRANSPOSE_MODELVIEW_MATRIX_NV"/>
+ <enum name="GL_PATH_PROJECTION_STACK_DEPTH_NV"/>
+ <enum name="GL_PATH_PROJECTION_MATRIX_NV"/>
+ <enum name="GL_PATH_MAX_PROJECTION_STACK_DEPTH_NV"/>
+ <enum name="GL_PATH_TRANSPOSE_PROJECTION_MATRIX_NV"/>
+ <enum name="GL_FRAGMENT_INPUT_NV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_pixel_data_range" supported="gl">
+ <require>
+ <enum name="GL_WRITE_PIXEL_DATA_RANGE_NV"/>
+ <enum name="GL_READ_PIXEL_DATA_RANGE_NV"/>
+ <enum name="GL_WRITE_PIXEL_DATA_RANGE_LENGTH_NV"/>
+ <enum name="GL_READ_PIXEL_DATA_RANGE_LENGTH_NV"/>
+ <enum name="GL_WRITE_PIXEL_DATA_RANGE_POINTER_NV"/>
+ <enum name="GL_READ_PIXEL_DATA_RANGE_POINTER_NV"/>
+ <command name="glPixelDataRangeNV"/>
+ <command name="glFlushPixelDataRangeNV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_point_sprite" supported="gl">
+ <require>
+ <enum name="GL_POINT_SPRITE_NV"/>
+ <enum name="GL_COORD_REPLACE_NV"/>
+ <enum name="GL_POINT_SPRITE_R_MODE_NV"/>
+ <command name="glPointParameteriNV"/>
+ <command name="glPointParameterivNV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_present_video" supported="gl">
+ <require>
+ <enum name="GL_FRAME_NV"/>
+ <enum name="GL_FIELDS_NV"/>
+ <enum name="GL_CURRENT_TIME_NV"/>
+ <enum name="GL_NUM_FILL_STREAMS_NV"/>
+ <enum name="GL_PRESENT_TIME_NV"/>
+ <enum name="GL_PRESENT_DURATION_NV"/>
+ <command name="glPresentFrameKeyedNV"/>
+ <command name="glPresentFrameDualFillNV"/>
+ <command name="glGetVideoivNV"/>
+ <command name="glGetVideouivNV"/>
+ <command name="glGetVideoi64vNV"/>
+ <command name="glGetVideoui64vNV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_primitive_restart" supported="gl">
+ <require>
+ <enum name="GL_PRIMITIVE_RESTART_NV"/>
+ <enum name="GL_PRIMITIVE_RESTART_INDEX_NV"/>
+ <command name="glPrimitiveRestartNV"/>
+ <command name="glPrimitiveRestartIndexNV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_read_buffer" supported="gles2">
+ <require>
+ <enum name="GL_READ_BUFFER_NV"/>
+ <command name="glReadBufferNV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_read_buffer_front" supported="gles2"/>
+ <extension name="GL_NV_read_depth" supported="gles2"/>
+ <extension name="GL_NV_read_depth_stencil" supported="gles2"/>
+ <extension name="GL_NV_read_stencil" supported="gles2"/>
+ <extension name="GL_NV_register_combiners" supported="gl">
+ <require>
+ <enum name="GL_REGISTER_COMBINERS_NV"/>
+ <enum name="GL_VARIABLE_A_NV"/>
+ <enum name="GL_VARIABLE_B_NV"/>
+ <enum name="GL_VARIABLE_C_NV"/>
+ <enum name="GL_VARIABLE_D_NV"/>
+ <enum name="GL_VARIABLE_E_NV"/>
+ <enum name="GL_VARIABLE_F_NV"/>
+ <enum name="GL_VARIABLE_G_NV"/>
+ <enum name="GL_CONSTANT_COLOR0_NV"/>
+ <enum name="GL_CONSTANT_COLOR1_NV"/>
+ <enum name="GL_PRIMARY_COLOR_NV"/>
+ <enum name="GL_SECONDARY_COLOR_NV"/>
+ <enum name="GL_SPARE0_NV"/>
+ <enum name="GL_SPARE1_NV"/>
+ <enum name="GL_DISCARD_NV"/>
+ <enum name="GL_E_TIMES_F_NV"/>
+ <enum name="GL_SPARE0_PLUS_SECONDARY_COLOR_NV"/>
+ <enum name="GL_UNSIGNED_IDENTITY_NV"/>
+ <enum name="GL_UNSIGNED_INVERT_NV"/>
+ <enum name="GL_EXPAND_NORMAL_NV"/>
+ <enum name="GL_EXPAND_NEGATE_NV"/>
+ <enum name="GL_HALF_BIAS_NORMAL_NV"/>
+ <enum name="GL_HALF_BIAS_NEGATE_NV"/>
+ <enum name="GL_SIGNED_IDENTITY_NV"/>
+ <enum name="GL_SIGNED_NEGATE_NV"/>
+ <enum name="GL_SCALE_BY_TWO_NV"/>
+ <enum name="GL_SCALE_BY_FOUR_NV"/>
+ <enum name="GL_SCALE_BY_ONE_HALF_NV"/>
+ <enum name="GL_BIAS_BY_NEGATIVE_ONE_HALF_NV"/>
+ <enum name="GL_COMBINER_INPUT_NV"/>
+ <enum name="GL_COMBINER_MAPPING_NV"/>
+ <enum name="GL_COMBINER_COMPONENT_USAGE_NV"/>
+ <enum name="GL_COMBINER_AB_DOT_PRODUCT_NV"/>
+ <enum name="GL_COMBINER_CD_DOT_PRODUCT_NV"/>
+ <enum name="GL_COMBINER_MUX_SUM_NV"/>
+ <enum name="GL_COMBINER_SCALE_NV"/>
+ <enum name="GL_COMBINER_BIAS_NV"/>
+ <enum name="GL_COMBINER_AB_OUTPUT_NV"/>
+ <enum name="GL_COMBINER_CD_OUTPUT_NV"/>
+ <enum name="GL_COMBINER_SUM_OUTPUT_NV"/>
+ <enum name="GL_MAX_GENERAL_COMBINERS_NV"/>
+ <enum name="GL_NUM_GENERAL_COMBINERS_NV"/>
+ <enum name="GL_COLOR_SUM_CLAMP_NV"/>
+ <enum name="GL_COMBINER0_NV"/>
+ <enum name="GL_COMBINER1_NV"/>
+ <enum name="GL_COMBINER2_NV"/>
+ <enum name="GL_COMBINER3_NV"/>
+ <enum name="GL_COMBINER4_NV"/>
+ <enum name="GL_COMBINER5_NV"/>
+ <enum name="GL_COMBINER6_NV"/>
+ <enum name="GL_COMBINER7_NV"/>
+ <enum name="GL_TEXTURE0_ARB"/>
+ <enum name="GL_TEXTURE1_ARB"/>
+ <enum name="GL_ZERO"/>
+ <enum name="GL_NONE"/>
+ <enum name="GL_FOG"/>
+ <command name="glCombinerParameterfvNV"/>
+ <command name="glCombinerParameterfNV"/>
+ <command name="glCombinerParameterivNV"/>
+ <command name="glCombinerParameteriNV"/>
+ <command name="glCombinerInputNV"/>
+ <command name="glCombinerOutputNV"/>
+ <command name="glFinalCombinerInputNV"/>
+ <command name="glGetCombinerInputParameterfvNV"/>
+ <command name="glGetCombinerInputParameterivNV"/>
+ <command name="glGetCombinerOutputParameterfvNV"/>
+ <command name="glGetCombinerOutputParameterivNV"/>
+ <command name="glGetFinalCombinerInputParameterfvNV"/>
+ <command name="glGetFinalCombinerInputParameterivNV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_register_combiners2" supported="gl">
+ <require>
+ <enum name="GL_PER_STAGE_CONSTANTS_NV"/>
+ <command name="glCombinerStageParameterfvNV"/>
+ <command name="glGetCombinerStageParameterfvNV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_sRGB_formats" supported="gles2">
+ <require>
+ <enum name="GL_SLUMINANCE_NV"/>
+ <enum name="GL_SLUMINANCE_ALPHA_NV"/>
+ <enum name="GL_SRGB8_NV"/>
+ <enum name="GL_SLUMINANCE8_NV"/>
+ <enum name="GL_SLUMINANCE8_ALPHA8_NV"/>
+ <enum name="GL_COMPRESSED_SRGB_S3TC_DXT1_NV"/>
+ <enum name="GL_COMPRESSED_SRGB_ALPHA_S3TC_DXT1_NV"/>
+ <enum name="GL_COMPRESSED_SRGB_ALPHA_S3TC_DXT3_NV"/>
+ <enum name="GL_COMPRESSED_SRGB_ALPHA_S3TC_DXT5_NV"/>
+ <enum name="GL_ETC1_SRGB8_NV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_shader_atomic_counters" supported="gl"/>
+ <extension name="GL_NV_shader_atomic_float" supported="gl"/>
+ <extension name="GL_NV_shader_atomic_int64" supported="gl"/>
+ <extension name="GL_NV_shader_buffer_load" supported="gl">
+ <require>
+ <enum name="GL_BUFFER_GPU_ADDRESS_NV"/>
+ <enum name="GL_GPU_ADDRESS_NV"/>
+ <enum name="GL_MAX_SHADER_BUFFER_ADDRESS_NV"/>
+ <command name="glMakeBufferResidentNV"/>
+ <command name="glMakeBufferNonResidentNV"/>
+ <command name="glIsBufferResidentNV"/>
+ <command name="glMakeNamedBufferResidentNV"/>
+ <command name="glMakeNamedBufferNonResidentNV"/>
+ <command name="glIsNamedBufferResidentNV"/>
+ <command name="glGetBufferParameterui64vNV"/>
+ <command name="glGetNamedBufferParameterui64vNV"/>
+ <command name="glGetIntegerui64vNV"/>
+ <command name="glUniformui64NV"/>
+ <command name="glUniformui64vNV"/>
+ <command name="glGetUniformui64vNV"/>
+ <command name="glProgramUniformui64NV"/>
+ <command name="glProgramUniformui64vNV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_shader_buffer_store" supported="gl">
+ <require>
+ <enum name="GL_SHADER_GLOBAL_ACCESS_BARRIER_BIT_NV"/>
+ <enum name="GL_READ_WRITE"/>
+ <enum name="GL_WRITE_ONLY"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_shader_storage_buffer_object" supported="gl"/>
+ <extension name="GL_NV_shader_thread_group" supported="gl">
+ <require>
+ <enum name="GL_WARP_SIZE_NV"/>
+ <enum name="GL_WARPS_PER_SM_NV"/>
+ <enum name="GL_SM_COUNT_NV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_shader_thread_shuffle" supported="gl"/>
+ <extension name="GL_NV_shadow_samplers_array" supported="gles2">
+ <require>
+ <enum name="GL_SAMPLER_2D_ARRAY_SHADOW_NV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_shadow_samplers_cube" supported="gles2">
+ <require>
+ <enum name="GL_SAMPLER_CUBE_SHADOW_NV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_tessellation_program5" supported="gl">
+ <require>
+ <enum name="GL_MAX_PROGRAM_PATCH_ATTRIBS_NV"/>
+ <enum name="GL_TESS_CONTROL_PROGRAM_NV"/>
+ <enum name="GL_TESS_EVALUATION_PROGRAM_NV"/>
+ <enum name="GL_TESS_CONTROL_PROGRAM_PARAMETER_BUFFER_NV"/>
+ <enum name="GL_TESS_EVALUATION_PROGRAM_PARAMETER_BUFFER_NV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_texgen_emboss" supported="gl">
+ <require>
+ <enum name="GL_EMBOSS_LIGHT_NV"/>
+ <enum name="GL_EMBOSS_CONSTANT_NV"/>
+ <enum name="GL_EMBOSS_MAP_NV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_texgen_reflection" supported="gl">
+ <require>
+ <enum name="GL_NORMAL_MAP_NV"/>
+ <enum name="GL_REFLECTION_MAP_NV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_texture_barrier" supported="gl">
+ <require>
+ <command name="glTextureBarrierNV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_texture_border_clamp" supported="gles2">
+ <require>
+ <enum name="GL_TEXTURE_BORDER_COLOR_NV"/>
+ <enum name="GL_CLAMP_TO_BORDER_NV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_texture_compression_s3tc_update" supported="gles2"/>
+ <extension name="GL_NV_texture_compression_vtc" supported="gl"/>
+ <extension name="GL_NV_texture_env_combine4" supported="gl">
+ <require>
+ <enum name="GL_COMBINE4_NV"/>
+ <enum name="GL_SOURCE3_RGB_NV"/>
+ <enum name="GL_SOURCE3_ALPHA_NV"/>
+ <enum name="GL_OPERAND3_RGB_NV"/>
+ <enum name="GL_OPERAND3_ALPHA_NV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_texture_expand_normal" supported="gl">
+ <require>
+ <enum name="GL_TEXTURE_UNSIGNED_REMAP_MODE_NV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_texture_multisample" supported="gl">
+ <require>
+ <enum name="GL_TEXTURE_COVERAGE_SAMPLES_NV"/>
+ <enum name="GL_TEXTURE_COLOR_SAMPLES_NV"/>
+ <command name="glTexImage2DMultisampleCoverageNV"/>
+ <command name="glTexImage3DMultisampleCoverageNV"/>
+ </require>
+ <require comment="Supported only if GL_EXT_direct_state_access is supported">
+ <command name="glTextureImage2DMultisampleNV"/>
+ <command name="glTextureImage3DMultisampleNV"/>
+ <command name="glTextureImage2DMultisampleCoverageNV"/>
+ <command name="glTextureImage3DMultisampleCoverageNV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_texture_npot_2D_mipmap" supported="gles2"/>
+ <extension name="GL_NV_texture_rectangle" supported="gl">
+ <require>
+ <enum name="GL_TEXTURE_RECTANGLE_NV"/>
+ <enum name="GL_TEXTURE_BINDING_RECTANGLE_NV"/>
+ <enum name="GL_PROXY_TEXTURE_RECTANGLE_NV"/>
+ <enum name="GL_MAX_RECTANGLE_TEXTURE_SIZE_NV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_texture_shader" supported="gl">
+ <require>
+ <enum name="GL_OFFSET_TEXTURE_RECTANGLE_NV"/>
+ <enum name="GL_OFFSET_TEXTURE_RECTANGLE_SCALE_NV"/>
+ <enum name="GL_DOT_PRODUCT_TEXTURE_RECTANGLE_NV"/>
+ <enum name="GL_RGBA_UNSIGNED_DOT_PRODUCT_MAPPING_NV"/>
+ <enum name="GL_UNSIGNED_INT_S8_S8_8_8_NV"/>
+ <enum name="GL_UNSIGNED_INT_8_8_S8_S8_REV_NV"/>
+ <enum name="GL_DSDT_MAG_INTENSITY_NV"/>
+ <enum name="GL_SHADER_CONSISTENT_NV"/>
+ <enum name="GL_TEXTURE_SHADER_NV"/>
+ <enum name="GL_SHADER_OPERATION_NV"/>
+ <enum name="GL_CULL_MODES_NV"/>
+ <enum name="GL_OFFSET_TEXTURE_MATRIX_NV"/>
+ <enum name="GL_OFFSET_TEXTURE_SCALE_NV"/>
+ <enum name="GL_OFFSET_TEXTURE_BIAS_NV"/>
+ <enum name="GL_OFFSET_TEXTURE_2D_MATRIX_NV"/>
+ <enum name="GL_OFFSET_TEXTURE_2D_SCALE_NV"/>
+ <enum name="GL_OFFSET_TEXTURE_2D_BIAS_NV"/>
+ <enum name="GL_PREVIOUS_TEXTURE_INPUT_NV"/>
+ <enum name="GL_CONST_EYE_NV"/>
+ <enum name="GL_PASS_THROUGH_NV"/>
+ <enum name="GL_CULL_FRAGMENT_NV"/>
+ <enum name="GL_OFFSET_TEXTURE_2D_NV"/>
+ <enum name="GL_DEPENDENT_AR_TEXTURE_2D_NV"/>
+ <enum name="GL_DEPENDENT_GB_TEXTURE_2D_NV"/>
+ <enum name="GL_DOT_PRODUCT_NV"/>
+ <enum name="GL_DOT_PRODUCT_DEPTH_REPLACE_NV"/>
+ <enum name="GL_DOT_PRODUCT_TEXTURE_2D_NV"/>
+ <enum name="GL_DOT_PRODUCT_TEXTURE_CUBE_MAP_NV"/>
+ <enum name="GL_DOT_PRODUCT_DIFFUSE_CUBE_MAP_NV"/>
+ <enum name="GL_DOT_PRODUCT_REFLECT_CUBE_MAP_NV"/>
+ <enum name="GL_DOT_PRODUCT_CONST_EYE_REFLECT_CUBE_MAP_NV"/>
+ <enum name="GL_HILO_NV"/>
+ <enum name="GL_DSDT_NV"/>
+ <enum name="GL_DSDT_MAG_NV"/>
+ <enum name="GL_DSDT_MAG_VIB_NV"/>
+ <enum name="GL_HILO16_NV"/>
+ <enum name="GL_SIGNED_HILO_NV"/>
+ <enum name="GL_SIGNED_HILO16_NV"/>
+ <enum name="GL_SIGNED_RGBA_NV"/>
+ <enum name="GL_SIGNED_RGBA8_NV"/>
+ <enum name="GL_SIGNED_RGB_NV"/>
+ <enum name="GL_SIGNED_RGB8_NV"/>
+ <enum name="GL_SIGNED_LUMINANCE_NV"/>
+ <enum name="GL_SIGNED_LUMINANCE8_NV"/>
+ <enum name="GL_SIGNED_LUMINANCE_ALPHA_NV"/>
+ <enum name="GL_SIGNED_LUMINANCE8_ALPHA8_NV"/>
+ <enum name="GL_SIGNED_ALPHA_NV"/>
+ <enum name="GL_SIGNED_ALPHA8_NV"/>
+ <enum name="GL_SIGNED_INTENSITY_NV"/>
+ <enum name="GL_SIGNED_INTENSITY8_NV"/>
+ <enum name="GL_DSDT8_NV"/>
+ <enum name="GL_DSDT8_MAG8_NV"/>
+ <enum name="GL_DSDT8_MAG8_INTENSITY8_NV"/>
+ <enum name="GL_SIGNED_RGB_UNSIGNED_ALPHA_NV"/>
+ <enum name="GL_SIGNED_RGB8_UNSIGNED_ALPHA8_NV"/>
+ <enum name="GL_HI_SCALE_NV"/>
+ <enum name="GL_LO_SCALE_NV"/>
+ <enum name="GL_DS_SCALE_NV"/>
+ <enum name="GL_DT_SCALE_NV"/>
+ <enum name="GL_MAGNITUDE_SCALE_NV"/>
+ <enum name="GL_VIBRANCE_SCALE_NV"/>
+ <enum name="GL_HI_BIAS_NV"/>
+ <enum name="GL_LO_BIAS_NV"/>
+ <enum name="GL_DS_BIAS_NV"/>
+ <enum name="GL_DT_BIAS_NV"/>
+ <enum name="GL_MAGNITUDE_BIAS_NV"/>
+ <enum name="GL_VIBRANCE_BIAS_NV"/>
+ <enum name="GL_TEXTURE_BORDER_VALUES_NV"/>
+ <enum name="GL_TEXTURE_HI_SIZE_NV"/>
+ <enum name="GL_TEXTURE_LO_SIZE_NV"/>
+ <enum name="GL_TEXTURE_DS_SIZE_NV"/>
+ <enum name="GL_TEXTURE_DT_SIZE_NV"/>
+ <enum name="GL_TEXTURE_MAG_SIZE_NV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_texture_shader2" supported="gl">
+ <require>
+ <enum name="GL_DOT_PRODUCT_TEXTURE_3D_NV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_texture_shader3" supported="gl">
+ <require>
+ <enum name="GL_OFFSET_PROJECTIVE_TEXTURE_2D_NV"/>
+ <enum name="GL_OFFSET_PROJECTIVE_TEXTURE_2D_SCALE_NV"/>
+ <enum name="GL_OFFSET_PROJECTIVE_TEXTURE_RECTANGLE_NV"/>
+ <enum name="GL_OFFSET_PROJECTIVE_TEXTURE_RECTANGLE_SCALE_NV"/>
+ <enum name="GL_OFFSET_HILO_TEXTURE_2D_NV"/>
+ <enum name="GL_OFFSET_HILO_TEXTURE_RECTANGLE_NV"/>
+ <enum name="GL_OFFSET_HILO_PROJECTIVE_TEXTURE_2D_NV"/>
+ <enum name="GL_OFFSET_HILO_PROJECTIVE_TEXTURE_RECTANGLE_NV"/>
+ <enum name="GL_DEPENDENT_HILO_TEXTURE_2D_NV"/>
+ <enum name="GL_DEPENDENT_RGB_TEXTURE_3D_NV"/>
+ <enum name="GL_DEPENDENT_RGB_TEXTURE_CUBE_MAP_NV"/>
+ <enum name="GL_DOT_PRODUCT_PASS_THROUGH_NV"/>
+ <enum name="GL_DOT_PRODUCT_TEXTURE_1D_NV"/>
+ <enum name="GL_DOT_PRODUCT_AFFINE_DEPTH_REPLACE_NV"/>
+ <enum name="GL_HILO8_NV"/>
+ <enum name="GL_SIGNED_HILO8_NV"/>
+ <enum name="GL_FORCE_BLUE_TO_ONE_NV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_transform_feedback" supported="gl">
+ <require>
+ <enum name="GL_BACK_PRIMARY_COLOR_NV"/>
+ <enum name="GL_BACK_SECONDARY_COLOR_NV"/>
+ <enum name="GL_TEXTURE_COORD_NV"/>
+ <enum name="GL_CLIP_DISTANCE_NV"/>
+ <enum name="GL_VERTEX_ID_NV"/>
+ <enum name="GL_PRIMITIVE_ID_NV"/>
+ <enum name="GL_GENERIC_ATTRIB_NV"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_ATTRIBS_NV"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_BUFFER_MODE_NV"/>
+ <enum name="GL_MAX_TRANSFORM_FEEDBACK_SEPARATE_COMPONENTS_NV"/>
+ <enum name="GL_ACTIVE_VARYINGS_NV"/>
+ <enum name="GL_ACTIVE_VARYING_MAX_LENGTH_NV"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_VARYINGS_NV"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_BUFFER_START_NV"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_BUFFER_SIZE_NV"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_RECORD_NV"/>
+ <enum name="GL_PRIMITIVES_GENERATED_NV"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN_NV"/>
+ <enum name="GL_RASTERIZER_DISCARD_NV"/>
+ <enum name="GL_MAX_TRANSFORM_FEEDBACK_INTERLEAVED_COMPONENTS_NV"/>
+ <enum name="GL_MAX_TRANSFORM_FEEDBACK_SEPARATE_ATTRIBS_NV"/>
+ <enum name="GL_INTERLEAVED_ATTRIBS_NV"/>
+ <enum name="GL_SEPARATE_ATTRIBS_NV"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_BUFFER_NV"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_BUFFER_BINDING_NV"/>
+ <enum name="GL_LAYER_NV"/>
+ <command name="glBeginTransformFeedbackNV"/>
+ <command name="glEndTransformFeedbackNV"/>
+ <command name="glTransformFeedbackAttribsNV"/>
+ <command name="glBindBufferRangeNV"/>
+ <command name="glBindBufferOffsetNV"/>
+ <command name="glBindBufferBaseNV"/>
+ <command name="glTransformFeedbackVaryingsNV"/>
+ <command name="glActiveVaryingNV"/>
+ <command name="glGetVaryingLocationNV"/>
+ <command name="glGetActiveVaryingNV"/>
+ <command name="glGetTransformFeedbackVaryingNV"/>
+ </require>
+ <require comment="Extended by GL_ARB_transform_feedback3">
+ <enum name="GL_NEXT_BUFFER_NV"/>
+ <enum name="GL_SKIP_COMPONENTS4_NV"/>
+ <enum name="GL_SKIP_COMPONENTS3_NV"/>
+ <enum name="GL_SKIP_COMPONENTS2_NV"/>
+ <enum name="GL_SKIP_COMPONENTS1_NV"/>
+ <command name="glTransformFeedbackStreamAttribsNV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_transform_feedback2" supported="gl">
+ <require>
+ <enum name="GL_TRANSFORM_FEEDBACK_NV"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_BUFFER_PAUSED_NV"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_BUFFER_ACTIVE_NV"/>
+ <enum name="GL_TRANSFORM_FEEDBACK_BINDING_NV"/>
+ <command name="glBindTransformFeedbackNV"/>
+ <command name="glDeleteTransformFeedbacksNV"/>
+ <command name="glGenTransformFeedbacksNV"/>
+ <command name="glIsTransformFeedbackNV"/>
+ <command name="glPauseTransformFeedbackNV"/>
+ <command name="glResumeTransformFeedbackNV"/>
+ <command name="glDrawTransformFeedbackNV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_vdpau_interop" supported="gl">
+ <require>
+ <enum name="GL_SURFACE_STATE_NV"/>
+ <enum name="GL_SURFACE_REGISTERED_NV"/>
+ <enum name="GL_SURFACE_MAPPED_NV"/>
+ <enum name="GL_WRITE_DISCARD_NV"/>
+ <command name="glVDPAUInitNV"/>
+ <command name="glVDPAUFiniNV"/>
+ <command name="glVDPAURegisterVideoSurfaceNV"/>
+ <command name="glVDPAURegisterOutputSurfaceNV"/>
+ <command name="glVDPAUIsSurfaceNV"/>
+ <command name="glVDPAUUnregisterSurfaceNV"/>
+ <command name="glVDPAUGetSurfaceivNV"/>
+ <command name="glVDPAUSurfaceAccessNV"/>
+ <command name="glVDPAUMapSurfacesNV"/>
+ <command name="glVDPAUUnmapSurfacesNV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_vertex_array_range" supported="gl">
+ <require>
+ <enum name="GL_VERTEX_ARRAY_RANGE_NV"/>
+ <enum name="GL_VERTEX_ARRAY_RANGE_LENGTH_NV"/>
+ <enum name="GL_VERTEX_ARRAY_RANGE_VALID_NV"/>
+ <enum name="GL_MAX_VERTEX_ARRAY_RANGE_ELEMENT_NV"/>
+ <enum name="GL_VERTEX_ARRAY_RANGE_POINTER_NV"/>
+ <command name="glFlushVertexArrayRangeNV"/>
+ <command name="glVertexArrayRangeNV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_vertex_array_range2" supported="gl">
+ <require>
+ <enum name="GL_VERTEX_ARRAY_RANGE_WITHOUT_FLUSH_NV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_vertex_attrib_integer_64bit" supported="gl">
+ <require>
+ <enum name="GL_INT64_NV"/>
+ <enum name="GL_UNSIGNED_INT64_NV"/>
+ <command name="glVertexAttribL1i64NV"/>
+ <command name="glVertexAttribL2i64NV"/>
+ <command name="glVertexAttribL3i64NV"/>
+ <command name="glVertexAttribL4i64NV"/>
+ <command name="glVertexAttribL1i64vNV"/>
+ <command name="glVertexAttribL2i64vNV"/>
+ <command name="glVertexAttribL3i64vNV"/>
+ <command name="glVertexAttribL4i64vNV"/>
+ <command name="glVertexAttribL1ui64NV"/>
+ <command name="glVertexAttribL2ui64NV"/>
+ <command name="glVertexAttribL3ui64NV"/>
+ <command name="glVertexAttribL4ui64NV"/>
+ <command name="glVertexAttribL1ui64vNV"/>
+ <command name="glVertexAttribL2ui64vNV"/>
+ <command name="glVertexAttribL3ui64vNV"/>
+ <command name="glVertexAttribL4ui64vNV"/>
+ <command name="glGetVertexAttribLi64vNV"/>
+ <command name="glGetVertexAttribLui64vNV"/>
+ <command name="glVertexAttribLFormatNV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_vertex_buffer_unified_memory" supported="gl">
+ <require>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY_UNIFIED_NV"/>
+ <enum name="GL_ELEMENT_ARRAY_UNIFIED_NV"/>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY_ADDRESS_NV"/>
+ <enum name="GL_VERTEX_ARRAY_ADDRESS_NV"/>
+ <enum name="GL_NORMAL_ARRAY_ADDRESS_NV"/>
+ <enum name="GL_COLOR_ARRAY_ADDRESS_NV"/>
+ <enum name="GL_INDEX_ARRAY_ADDRESS_NV"/>
+ <enum name="GL_TEXTURE_COORD_ARRAY_ADDRESS_NV"/>
+ <enum name="GL_EDGE_FLAG_ARRAY_ADDRESS_NV"/>
+ <enum name="GL_SECONDARY_COLOR_ARRAY_ADDRESS_NV"/>
+ <enum name="GL_FOG_COORD_ARRAY_ADDRESS_NV"/>
+ <enum name="GL_ELEMENT_ARRAY_ADDRESS_NV"/>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY_LENGTH_NV"/>
+ <enum name="GL_VERTEX_ARRAY_LENGTH_NV"/>
+ <enum name="GL_NORMAL_ARRAY_LENGTH_NV"/>
+ <enum name="GL_COLOR_ARRAY_LENGTH_NV"/>
+ <enum name="GL_INDEX_ARRAY_LENGTH_NV"/>
+ <enum name="GL_TEXTURE_COORD_ARRAY_LENGTH_NV"/>
+ <enum name="GL_EDGE_FLAG_ARRAY_LENGTH_NV"/>
+ <enum name="GL_SECONDARY_COLOR_ARRAY_LENGTH_NV"/>
+ <enum name="GL_FOG_COORD_ARRAY_LENGTH_NV"/>
+ <enum name="GL_ELEMENT_ARRAY_LENGTH_NV"/>
+ <enum name="GL_DRAW_INDIRECT_UNIFIED_NV"/>
+ <enum name="GL_DRAW_INDIRECT_ADDRESS_NV"/>
+ <enum name="GL_DRAW_INDIRECT_LENGTH_NV"/>
+ <command name="glBufferAddressRangeNV"/>
+ <command name="glVertexFormatNV"/>
+ <command name="glNormalFormatNV"/>
+ <command name="glColorFormatNV"/>
+ <command name="glIndexFormatNV"/>
+ <command name="glTexCoordFormatNV"/>
+ <command name="glEdgeFlagFormatNV"/>
+ <command name="glSecondaryColorFormatNV"/>
+ <command name="glFogCoordFormatNV"/>
+ <command name="glVertexAttribFormatNV"/>
+ <command name="glVertexAttribIFormatNV"/>
+ <command name="glGetIntegerui64i_vNV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_vertex_program" supported="gl">
+ <require>
+ <enum name="GL_VERTEX_PROGRAM_NV"/>
+ <enum name="GL_VERTEX_STATE_PROGRAM_NV"/>
+ <enum name="GL_ATTRIB_ARRAY_SIZE_NV"/>
+ <enum name="GL_ATTRIB_ARRAY_STRIDE_NV"/>
+ <enum name="GL_ATTRIB_ARRAY_TYPE_NV"/>
+ <enum name="GL_CURRENT_ATTRIB_NV"/>
+ <enum name="GL_PROGRAM_LENGTH_NV"/>
+ <enum name="GL_PROGRAM_STRING_NV"/>
+ <enum name="GL_MODELVIEW_PROJECTION_NV"/>
+ <enum name="GL_IDENTITY_NV"/>
+ <enum name="GL_INVERSE_NV"/>
+ <enum name="GL_TRANSPOSE_NV"/>
+ <enum name="GL_INVERSE_TRANSPOSE_NV"/>
+ <enum name="GL_MAX_TRACK_MATRIX_STACK_DEPTH_NV"/>
+ <enum name="GL_MAX_TRACK_MATRICES_NV"/>
+ <enum name="GL_MATRIX0_NV"/>
+ <enum name="GL_MATRIX1_NV"/>
+ <enum name="GL_MATRIX2_NV"/>
+ <enum name="GL_MATRIX3_NV"/>
+ <enum name="GL_MATRIX4_NV"/>
+ <enum name="GL_MATRIX5_NV"/>
+ <enum name="GL_MATRIX6_NV"/>
+ <enum name="GL_MATRIX7_NV"/>
+ <enum name="GL_CURRENT_MATRIX_STACK_DEPTH_NV"/>
+ <enum name="GL_CURRENT_MATRIX_NV"/>
+ <enum name="GL_VERTEX_PROGRAM_POINT_SIZE_NV"/>
+ <enum name="GL_VERTEX_PROGRAM_TWO_SIDE_NV"/>
+ <enum name="GL_PROGRAM_PARAMETER_NV"/>
+ <enum name="GL_ATTRIB_ARRAY_POINTER_NV"/>
+ <enum name="GL_PROGRAM_TARGET_NV"/>
+ <enum name="GL_PROGRAM_RESIDENT_NV"/>
+ <enum name="GL_TRACK_MATRIX_NV"/>
+ <enum name="GL_TRACK_MATRIX_TRANSFORM_NV"/>
+ <enum name="GL_VERTEX_PROGRAM_BINDING_NV"/>
+ <enum name="GL_PROGRAM_ERROR_POSITION_NV"/>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY0_NV"/>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY1_NV"/>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY2_NV"/>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY3_NV"/>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY4_NV"/>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY5_NV"/>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY6_NV"/>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY7_NV"/>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY8_NV"/>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY9_NV"/>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY10_NV"/>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY11_NV"/>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY12_NV"/>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY13_NV"/>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY14_NV"/>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY15_NV"/>
+ <enum name="GL_MAP1_VERTEX_ATTRIB0_4_NV"/>
+ <enum name="GL_MAP1_VERTEX_ATTRIB1_4_NV"/>
+ <enum name="GL_MAP1_VERTEX_ATTRIB2_4_NV"/>
+ <enum name="GL_MAP1_VERTEX_ATTRIB3_4_NV"/>
+ <enum name="GL_MAP1_VERTEX_ATTRIB4_4_NV"/>
+ <enum name="GL_MAP1_VERTEX_ATTRIB5_4_NV"/>
+ <enum name="GL_MAP1_VERTEX_ATTRIB6_4_NV"/>
+ <enum name="GL_MAP1_VERTEX_ATTRIB7_4_NV"/>
+ <enum name="GL_MAP1_VERTEX_ATTRIB8_4_NV"/>
+ <enum name="GL_MAP1_VERTEX_ATTRIB9_4_NV"/>
+ <enum name="GL_MAP1_VERTEX_ATTRIB10_4_NV"/>
+ <enum name="GL_MAP1_VERTEX_ATTRIB11_4_NV"/>
+ <enum name="GL_MAP1_VERTEX_ATTRIB12_4_NV"/>
+ <enum name="GL_MAP1_VERTEX_ATTRIB13_4_NV"/>
+ <enum name="GL_MAP1_VERTEX_ATTRIB14_4_NV"/>
+ <enum name="GL_MAP1_VERTEX_ATTRIB15_4_NV"/>
+ <enum name="GL_MAP2_VERTEX_ATTRIB0_4_NV"/>
+ <enum name="GL_MAP2_VERTEX_ATTRIB1_4_NV"/>
+ <enum name="GL_MAP2_VERTEX_ATTRIB2_4_NV"/>
+ <enum name="GL_MAP2_VERTEX_ATTRIB3_4_NV"/>
+ <enum name="GL_MAP2_VERTEX_ATTRIB4_4_NV"/>
+ <enum name="GL_MAP2_VERTEX_ATTRIB5_4_NV"/>
+ <enum name="GL_MAP2_VERTEX_ATTRIB6_4_NV"/>
+ <enum name="GL_MAP2_VERTEX_ATTRIB7_4_NV"/>
+ <enum name="GL_MAP2_VERTEX_ATTRIB8_4_NV"/>
+ <enum name="GL_MAP2_VERTEX_ATTRIB9_4_NV"/>
+ <enum name="GL_MAP2_VERTEX_ATTRIB10_4_NV"/>
+ <enum name="GL_MAP2_VERTEX_ATTRIB11_4_NV"/>
+ <enum name="GL_MAP2_VERTEX_ATTRIB12_4_NV"/>
+ <enum name="GL_MAP2_VERTEX_ATTRIB13_4_NV"/>
+ <enum name="GL_MAP2_VERTEX_ATTRIB14_4_NV"/>
+ <enum name="GL_MAP2_VERTEX_ATTRIB15_4_NV"/>
+ <command name="glAreProgramsResidentNV"/>
+ <command name="glBindProgramNV"/>
+ <command name="glDeleteProgramsNV"/>
+ <command name="glExecuteProgramNV"/>
+ <command name="glGenProgramsNV"/>
+ <command name="glGetProgramParameterdvNV"/>
+ <command name="glGetProgramParameterfvNV"/>
+ <command name="glGetProgramivNV"/>
+ <command name="glGetProgramStringNV"/>
+ <command name="glGetTrackMatrixivNV"/>
+ <command name="glGetVertexAttribdvNV"/>
+ <command name="glGetVertexAttribfvNV"/>
+ <command name="glGetVertexAttribivNV"/>
+ <command name="glGetVertexAttribPointervNV"/>
+ <command name="glIsProgramNV"/>
+ <command name="glLoadProgramNV"/>
+ <command name="glProgramParameter4dNV"/>
+ <command name="glProgramParameter4dvNV"/>
+ <command name="glProgramParameter4fNV"/>
+ <command name="glProgramParameter4fvNV"/>
+ <command name="glProgramParameters4dvNV"/>
+ <command name="glProgramParameters4fvNV"/>
+ <command name="glRequestResidentProgramsNV"/>
+ <command name="glTrackMatrixNV"/>
+ <command name="glVertexAttribPointerNV"/>
+ <command name="glVertexAttrib1dNV"/>
+ <command name="glVertexAttrib1dvNV"/>
+ <command name="glVertexAttrib1fNV"/>
+ <command name="glVertexAttrib1fvNV"/>
+ <command name="glVertexAttrib1sNV"/>
+ <command name="glVertexAttrib1svNV"/>
+ <command name="glVertexAttrib2dNV"/>
+ <command name="glVertexAttrib2dvNV"/>
+ <command name="glVertexAttrib2fNV"/>
+ <command name="glVertexAttrib2fvNV"/>
+ <command name="glVertexAttrib2sNV"/>
+ <command name="glVertexAttrib2svNV"/>
+ <command name="glVertexAttrib3dNV"/>
+ <command name="glVertexAttrib3dvNV"/>
+ <command name="glVertexAttrib3fNV"/>
+ <command name="glVertexAttrib3fvNV"/>
+ <command name="glVertexAttrib3sNV"/>
+ <command name="glVertexAttrib3svNV"/>
+ <command name="glVertexAttrib4dNV"/>
+ <command name="glVertexAttrib4dvNV"/>
+ <command name="glVertexAttrib4fNV"/>
+ <command name="glVertexAttrib4fvNV"/>
+ <command name="glVertexAttrib4sNV"/>
+ <command name="glVertexAttrib4svNV"/>
+ <command name="glVertexAttrib4ubNV"/>
+ <command name="glVertexAttrib4ubvNV"/>
+ <command name="glVertexAttribs1dvNV"/>
+ <command name="glVertexAttribs1fvNV"/>
+ <command name="glVertexAttribs1svNV"/>
+ <command name="glVertexAttribs2dvNV"/>
+ <command name="glVertexAttribs2fvNV"/>
+ <command name="glVertexAttribs2svNV"/>
+ <command name="glVertexAttribs3dvNV"/>
+ <command name="glVertexAttribs3fvNV"/>
+ <command name="glVertexAttribs3svNV"/>
+ <command name="glVertexAttribs4dvNV"/>
+ <command name="glVertexAttribs4fvNV"/>
+ <command name="glVertexAttribs4svNV"/>
+ <command name="glVertexAttribs4ubvNV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_vertex_program1_1" supported="gl"/>
+ <extension name="GL_NV_vertex_program2" supported="gl"/>
+ <extension name="GL_NV_vertex_program2_option" supported="gl">
+ <require>
+ <enum name="GL_MAX_PROGRAM_EXEC_INSTRUCTIONS_NV"/>
+ <enum name="GL_MAX_PROGRAM_CALL_DEPTH_NV"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_vertex_program3" supported="gl">
+ <require>
+ <enum name="GL_MAX_VERTEX_TEXTURE_IMAGE_UNITS_ARB"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_vertex_program4" supported="gl">
+ <require>
+ <enum name="GL_VERTEX_ATTRIB_ARRAY_INTEGER_NV"/>
+ <command name="glVertexAttribI1iEXT"/>
+ <command name="glVertexAttribI2iEXT"/>
+ <command name="glVertexAttribI3iEXT"/>
+ <command name="glVertexAttribI4iEXT"/>
+ <command name="glVertexAttribI1uiEXT"/>
+ <command name="glVertexAttribI2uiEXT"/>
+ <command name="glVertexAttribI3uiEXT"/>
+ <command name="glVertexAttribI4uiEXT"/>
+ <command name="glVertexAttribI1ivEXT"/>
+ <command name="glVertexAttribI2ivEXT"/>
+ <command name="glVertexAttribI3ivEXT"/>
+ <command name="glVertexAttribI4ivEXT"/>
+ <command name="glVertexAttribI1uivEXT"/>
+ <command name="glVertexAttribI2uivEXT"/>
+ <command name="glVertexAttribI3uivEXT"/>
+ <command name="glVertexAttribI4uivEXT"/>
+ <command name="glVertexAttribI4bvEXT"/>
+ <command name="glVertexAttribI4svEXT"/>
+ <command name="glVertexAttribI4ubvEXT"/>
+ <command name="glVertexAttribI4usvEXT"/>
+ <command name="glVertexAttribIPointerEXT"/>
+ <command name="glGetVertexAttribIivEXT"/>
+ <command name="glGetVertexAttribIuivEXT"/>
+ </require>
+ </extension>
+ <extension name="GL_NV_video_capture" supported="gl">
+ <require>
+ <enum name="GL_VIDEO_BUFFER_NV"/>
+ <enum name="GL_VIDEO_BUFFER_BINDING_NV"/>
+ <enum name="GL_FIELD_UPPER_NV"/>
+ <enum name="GL_FIELD_LOWER_NV"/>
+ <enum name="GL_NUM_VIDEO_CAPTURE_STREAMS_NV"/>
+ <enum name="GL_NEXT_VIDEO_CAPTURE_BUFFER_STATUS_NV"/>
+ <enum name="GL_VIDEO_CAPTURE_TO_422_SUPPORTED_NV"/>
+ <enum name="GL_LAST_VIDEO_CAPTURE_STATUS_NV"/>
+ <enum name="GL_VIDEO_BUFFER_PITCH_NV"/>
+ <enum name="GL_VIDEO_COLOR_CONVERSION_MATRIX_NV"/>
+ <enum name="GL_VIDEO_COLOR_CONVERSION_MAX_NV"/>
+ <enum name="GL_VIDEO_COLOR_CONVERSION_MIN_NV"/>
+ <enum name="GL_VIDEO_COLOR_CONVERSION_OFFSET_NV"/>
+ <enum name="GL_VIDEO_BUFFER_INTERNAL_FORMAT_NV"/>
+ <enum name="GL_PARTIAL_SUCCESS_NV"/>
+ <enum name="GL_SUCCESS_NV"/>
+ <enum name="GL_FAILURE_NV"/>
+ <enum name="GL_YCBYCR8_422_NV"/>
+ <enum name="GL_YCBAYCR8A_4224_NV"/>
+ <enum name="GL_Z6Y10Z6CB10Z6Y10Z6CR10_422_NV"/>
+ <enum name="GL_Z6Y10Z6CB10Z6A10Z6Y10Z6CR10Z6A10_4224_NV"/>
+ <enum name="GL_Z4Y12Z4CB12Z4Y12Z4CR12_422_NV"/>
+ <enum name="GL_Z4Y12Z4CB12Z4A12Z4Y12Z4CR12Z4A12_4224_NV"/>
+ <enum name="GL_Z4Y12Z4CB12Z4CR12_444_NV"/>
+ <enum name="GL_VIDEO_CAPTURE_FRAME_WIDTH_NV"/>
+ <enum name="GL_VIDEO_CAPTURE_FRAME_HEIGHT_NV"/>
+ <enum name="GL_VIDEO_CAPTURE_FIELD_UPPER_HEIGHT_NV"/>
+ <enum name="GL_VIDEO_CAPTURE_FIELD_LOWER_HEIGHT_NV"/>
+ <enum name="GL_VIDEO_CAPTURE_SURFACE_ORIGIN_NV"/>
+ <command name="glBeginVideoCaptureNV"/>
+ <command name="glBindVideoCaptureStreamBufferNV"/>
+ <command name="glBindVideoCaptureStreamTextureNV"/>
+ <command name="glEndVideoCaptureNV"/>
+ <command name="glGetVideoCaptureivNV"/>
+ <command name="glGetVideoCaptureStreamivNV"/>
+ <command name="glGetVideoCaptureStreamfvNV"/>
+ <command name="glGetVideoCaptureStreamdvNV"/>
+ <command name="glVideoCaptureNV"/>
+ <command name="glVideoCaptureStreamParameterivNV"/>
+ <command name="glVideoCaptureStreamParameterfvNV"/>
+ <command name="glVideoCaptureStreamParameterdvNV"/>
+ </require>
+ </extension>
+ <extension name="GL_OES_EGL_image" supported="gles1|gles2">
+ <require>
+ <type name="GLeglImageOES"/>
+ <command name="glEGLImageTargetTexture2DOES"/>
+ <command name="glEGLImageTargetRenderbufferStorageOES"/>
+ </require>
+ </extension>
+ <extension name="GL_OES_EGL_image_external" supported="gles1|gles2">
+ <require>
+ <type name="GLeglImageOES"/>
+ <enum name="GL_TEXTURE_EXTERNAL_OES"/>
+ <enum name="GL_TEXTURE_BINDING_EXTERNAL_OES"/>
+ <enum name="GL_REQUIRED_TEXTURE_IMAGE_UNITS_OES"/>
+ </require>
+ <require api="gles2">
+ <enum name="GL_SAMPLER_EXTERNAL_OES"/>
+ </require>
+ </extension>
+ <extension name="GL_OES_blend_equation_separate" supported="gles1">
+ <require>
+ <enum name="GL_BLEND_EQUATION_RGB_OES"/>
+ <enum name="GL_BLEND_EQUATION_ALPHA_OES"/>
+ <command name="glBlendEquationSeparateOES"/>
+ </require>
+ </extension>
+ <extension name="GL_OES_blend_func_separate" supported="gles1">
+ <require>
+ <enum name="GL_BLEND_DST_RGB_OES"/>
+ <enum name="GL_BLEND_SRC_RGB_OES"/>
+ <enum name="GL_BLEND_DST_ALPHA_OES"/>
+ <enum name="GL_BLEND_SRC_ALPHA_OES"/>
+ <command name="glBlendFuncSeparateOES"/>
+ </require>
+ </extension>
+ <extension name="GL_OES_blend_subtract" supported="gles1">
+ <require>
+ <enum name="GL_BLEND_EQUATION_OES"/>
+ <enum name="GL_FUNC_ADD_OES"/>
+ <enum name="GL_FUNC_SUBTRACT_OES"/>
+ <enum name="GL_FUNC_REVERSE_SUBTRACT_OES"/>
+ <command name="glBlendEquationOES"/>
+ </require>
+ </extension>
+ <extension name="GL_OES_byte_coordinates" supported="gl|gles1">
+ <require>
+ <type name="GLbyte"/>
+ <enum name="GL_BYTE"/>
+ </require>
+ <require api="gl" comment="Immediate-mode entry points don't exist in ES 1.x">
+ <command name="glMultiTexCoord1bOES"/>
+ <command name="glMultiTexCoord1bvOES"/>
+ <command name="glMultiTexCoord2bOES"/>
+ <command name="glMultiTexCoord2bvOES"/>
+ <command name="glMultiTexCoord3bOES"/>
+ <command name="glMultiTexCoord3bvOES"/>
+ <command name="glMultiTexCoord4bOES"/>
+ <command name="glMultiTexCoord4bvOES"/>
+ <command name="glTexCoord1bOES"/>
+ <command name="glTexCoord1bvOES"/>
+ <command name="glTexCoord2bOES"/>
+ <command name="glTexCoord2bvOES"/>
+ <command name="glTexCoord3bOES"/>
+ <command name="glTexCoord3bvOES"/>
+ <command name="glTexCoord4bOES"/>
+ <command name="glTexCoord4bvOES"/>
+ <command name="glVertex2bOES"/>
+ <command name="glVertex2bvOES"/>
+ <command name="glVertex3bOES"/>
+ <command name="glVertex3bvOES"/>
+ <command name="glVertex4bOES"/>
+ <command name="glVertex4bvOES"/>
+ </require>
+ </extension>
+ <extension name="GL_OES_compressed_ETC1_RGB8_sub_texture" supported="gles1|gles2"/>
+ <extension name="GL_OES_compressed_ETC1_RGB8_texture" supported="gles1|gles2">
+ <require>
+ <enum name="GL_ETC1_RGB8_OES"/>
+ </require>
+ </extension>
+ <extension name="GL_OES_compressed_paletted_texture" supported="gl|gles1|gles2">
+ <require>
+ <enum name="GL_PALETTE4_RGB8_OES"/>
+ <enum name="GL_PALETTE4_RGBA8_OES"/>
+ <enum name="GL_PALETTE4_R5_G6_B5_OES"/>
+ <enum name="GL_PALETTE4_RGBA4_OES"/>
+ <enum name="GL_PALETTE4_RGB5_A1_OES"/>
+ <enum name="GL_PALETTE8_RGB8_OES"/>
+ <enum name="GL_PALETTE8_RGBA8_OES"/>
+ <enum name="GL_PALETTE8_R5_G6_B5_OES"/>
+ <enum name="GL_PALETTE8_RGBA4_OES"/>
+ <enum name="GL_PALETTE8_RGB5_A1_OES"/>
+ </require>
+ </extension>
+ <extension name="GL_OES_depth24" supported="gles1|gles2">
+ <require>
+ <enum name="GL_DEPTH_COMPONENT24_OES"/>
+ </require>
+ </extension>
+ <extension name="GL_OES_depth32" supported="gles1|gles2">
+ <require>
+ <enum name="GL_DEPTH_COMPONENT32_OES"/>
+ </require>
+ </extension>
+ <extension name="GL_OES_depth_texture" supported="gles2">
+ <require>
+ <enum name="GL_DEPTH_COMPONENT"/>
+ <enum name="GL_UNSIGNED_SHORT"/>
+ <enum name="GL_UNSIGNED_INT"/>
+ </require>
+ </extension>
+ <extension name="GL_OES_draw_texture" supported="gles1">
+ <require>
+ <enum name="GL_TEXTURE_CROP_RECT_OES"/>
+ <command name="glDrawTexsOES"/>
+ <command name="glDrawTexiOES"/>
+ <command name="glDrawTexxOES"/>
+ <command name="glDrawTexsvOES"/>
+ <command name="glDrawTexivOES"/>
+ <command name="glDrawTexxvOES"/>
+ <command name="glDrawTexfOES"/>
+ <command name="glDrawTexfvOES"/>
+ </require>
+ </extension>
+ <extension name="GL_OES_element_index_uint" supported="gles1|gles2">
+ <require>
+ <enum name="GL_UNSIGNED_INT"/>
+ </require>
+ </extension>
+ <extension name="GL_OES_extended_matrix_palette" supported="gles1"/>
+ <extension name="GL_OES_fbo_render_mipmap" supported="gles1|gles2"/>
+ <extension name="GL_OES_fixed_point" supported="gl|gles1">
+ <require>
+ <enum name="GL_FIXED_OES"/>
+ <command name="glAlphaFuncxOES"/>
+ <command name="glClearColorxOES"/>
+ <command name="glClearDepthxOES"/>
+ <command name="glClipPlanexOES"/>
+ <command name="glColor4xOES"/>
+ <command name="glDepthRangexOES"/>
+ <command name="glFogxOES"/>
+ <command name="glFogxvOES"/>
+ <command name="glFrustumxOES"/>
+ <command name="glGetClipPlanexOES"/>
+ <command name="glGetFixedvOES"/>
+ <command name="glGetTexEnvxvOES"/>
+ <command name="glGetTexParameterxvOES"/>
+ <command name="glLightModelxOES"/>
+ <command name="glLightModelxvOES"/>
+ <command name="glLightxOES"/>
+ <command name="glLightxvOES"/>
+ <command name="glLineWidthxOES"/>
+ <command name="glLoadMatrixxOES"/>
+ <command name="glMaterialxOES"/>
+ <command name="glMaterialxvOES"/>
+ <command name="glMultMatrixxOES"/>
+ <command name="glMultiTexCoord4xOES"/>
+ <command name="glNormal3xOES"/>
+ <command name="glOrthoxOES"/>
+ <command name="glPointParameterxvOES"/>
+ <command name="glPointSizexOES"/>
+ <command name="glPolygonOffsetxOES"/>
+ <command name="glRotatexOES"/>
+ <command name="glSampleCoverageOES"/>
+ <command name="glScalexOES"/>
+ <command name="glTexEnvxOES"/>
+ <command name="glTexEnvxvOES"/>
+ <command name="glTexParameterxOES"/>
+ <command name="glTexParameterxvOES"/>
+ <command name="glTranslatexOES"/>
+ </require>
+ <require api="gles1" comment="Entry points not in the extension spec, but in the Khronos glext.h. Included for backward compatibility.">
+ <command name="glGetLightxvOES"/>
+ <command name="glGetMaterialxvOES"/>
+ <command name="glPointParameterxOES"/>
+ <command name="glSampleCoveragexOES"/>
+ </require>
+ <require api="gl" comment="Entry points in the extension spec, but not the Khronos glext.h. Correspond to GL-only features it's unlikely were ever implemented against ES 1.x.">
+ <command name="glAccumxOES"/>
+ <command name="glBitmapxOES"/>
+ <command name="glBlendColorxOES"/>
+ <command name="glClearAccumxOES"/>
+ <command name="glColor3xOES"/>
+ <command name="glColor3xvOES"/>
+ <command name="glColor4xvOES"/>
+ <command name="glConvolutionParameterxOES"/>
+ <command name="glConvolutionParameterxvOES"/>
+ <command name="glEvalCoord1xOES"/>
+ <command name="glEvalCoord1xvOES"/>
+ <command name="glEvalCoord2xOES"/>
+ <command name="glEvalCoord2xvOES"/>
+ <command name="glFeedbackBufferxOES"/>
+ <command name="glGetConvolutionParameterxvOES"/>
+ <command name="glGetHistogramParameterxvOES"/>
+ <command name="glGetLightxOES"/>
+ <command name="glGetMapxvOES"/>
+ <command name="glGetMaterialxOES"/>
+ <command name="glGetPixelMapxv"/>
+ <command name="glGetTexGenxvOES"/>
+ <command name="glGetTexLevelParameterxvOES"/>
+ <command name="glIndexxOES"/>
+ <command name="glIndexxvOES"/>
+ <command name="glLoadTransposeMatrixxOES"/>
+ <command name="glMap1xOES"/>
+ <command name="glMap2xOES"/>
+ <command name="glMapGrid1xOES"/>
+ <command name="glMapGrid2xOES"/>
+ <command name="glMultTransposeMatrixxOES"/>
+ <command name="glMultiTexCoord1xOES"/>
+ <command name="glMultiTexCoord1xvOES"/>
+ <command name="glMultiTexCoord2xOES"/>
+ <command name="glMultiTexCoord2xvOES"/>
+ <command name="glMultiTexCoord3xOES"/>
+ <command name="glMultiTexCoord3xvOES"/>
+ <command name="glMultiTexCoord4xvOES"/>
+ <command name="glNormal3xvOES"/>
+ <command name="glPassThroughxOES"/>
+ <command name="glPixelMapx"/>
+ <command name="glPixelStorex"/>
+ <command name="glPixelTransferxOES"/>
+ <command name="glPixelZoomxOES"/>
+ <command name="glPrioritizeTexturesxOES"/>
+ <command name="glRasterPos2xOES"/>
+ <command name="glRasterPos2xvOES"/>
+ <command name="glRasterPos3xOES"/>
+ <command name="glRasterPos3xvOES"/>
+ <command name="glRasterPos4xOES"/>
+ <command name="glRasterPos4xvOES"/>
+ <command name="glRectxOES"/>
+ <command name="glRectxvOES"/>
+ <command name="glTexCoord1xOES"/>
+ <command name="glTexCoord1xvOES"/>
+ <command name="glTexCoord2xOES"/>
+ <command name="glTexCoord2xvOES"/>
+ <command name="glTexCoord3xOES"/>
+ <command name="glTexCoord3xvOES"/>
+ <command name="glTexCoord4xOES"/>
+ <command name="glTexCoord4xvOES"/>
+ <command name="glTexGenxOES"/>
+ <command name="glTexGenxvOES"/>
+ <command name="glVertex2xOES"/>
+ <command name="glVertex2xvOES"/>
+ <command name="glVertex3xOES"/>
+ <command name="glVertex3xvOES"/>
+ <command name="glVertex4xOES"/>
+ <command name="glVertex4xvOES"/>
+ </require>
+ </extension>
+ <extension name="GL_OES_fragment_precision_high" supported="gles2">
+ <require>
+ </require>
+ </extension>
+ <extension name="GL_OES_framebuffer_object" supported="gles1">
+ <require>
+ <enum name="GL_NONE_OES"/>
+ <enum name="GL_FRAMEBUFFER_OES"/>
+ <enum name="GL_RENDERBUFFER_OES"/>
+ <enum name="GL_RGBA4_OES"/>
+ <enum name="GL_RGB5_A1_OES"/>
+ <enum name="GL_RGB565_OES"/>
+ <enum name="GL_DEPTH_COMPONENT16_OES"/>
+ <enum name="GL_RENDERBUFFER_WIDTH_OES"/>
+ <enum name="GL_RENDERBUFFER_HEIGHT_OES"/>
+ <enum name="GL_RENDERBUFFER_INTERNAL_FORMAT_OES"/>
+ <enum name="GL_RENDERBUFFER_RED_SIZE_OES"/>
+ <enum name="GL_RENDERBUFFER_GREEN_SIZE_OES"/>
+ <enum name="GL_RENDERBUFFER_BLUE_SIZE_OES"/>
+ <enum name="GL_RENDERBUFFER_ALPHA_SIZE_OES"/>
+ <enum name="GL_RENDERBUFFER_DEPTH_SIZE_OES"/>
+ <enum name="GL_RENDERBUFFER_STENCIL_SIZE_OES"/>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE_OES"/>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_OBJECT_NAME_OES"/>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL_OES"/>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE_OES"/>
+ <enum name="GL_COLOR_ATTACHMENT0_OES"/>
+ <enum name="GL_DEPTH_ATTACHMENT_OES"/>
+ <enum name="GL_STENCIL_ATTACHMENT_OES"/>
+ <enum name="GL_FRAMEBUFFER_COMPLETE_OES"/>
+ <enum name="GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT_OES"/>
+ <enum name="GL_FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT_OES"/>
+ <enum name="GL_FRAMEBUFFER_INCOMPLETE_DIMENSIONS_OES"/>
+ <enum name="GL_FRAMEBUFFER_INCOMPLETE_FORMATS_OES"/>
+ <enum name="GL_FRAMEBUFFER_UNSUPPORTED_OES"/>
+ <enum name="GL_FRAMEBUFFER_BINDING_OES"/>
+ <enum name="GL_RENDERBUFFER_BINDING_OES"/>
+ <enum name="GL_MAX_RENDERBUFFER_SIZE_OES"/>
+ <enum name="GL_INVALID_FRAMEBUFFER_OPERATION_OES"/>
+ <command name="glIsRenderbufferOES"/>
+ <command name="glBindRenderbufferOES"/>
+ <command name="glDeleteRenderbuffersOES"/>
+ <command name="glGenRenderbuffersOES"/>
+ <command name="glRenderbufferStorageOES"/>
+ <command name="glGetRenderbufferParameterivOES"/>
+ <command name="glIsFramebufferOES"/>
+ <command name="glBindFramebufferOES"/>
+ <command name="glDeleteFramebuffersOES"/>
+ <command name="glGenFramebuffersOES"/>
+ <command name="glCheckFramebufferStatusOES"/>
+ <command name="glFramebufferRenderbufferOES"/>
+ <command name="glFramebufferTexture2DOES"/>
+ <command name="glGetFramebufferAttachmentParameterivOES"/>
+ <command name="glGenerateMipmapOES"/>
+ </require>
+ </extension>
+ <extension name="GL_OES_get_program_binary" supported="gles2">
+ <require>
+ <enum name="GL_PROGRAM_BINARY_LENGTH_OES"/>
+ <enum name="GL_NUM_PROGRAM_BINARY_FORMATS_OES"/>
+ <enum name="GL_PROGRAM_BINARY_FORMATS_OES"/>
+ <command name="glGetProgramBinaryOES"/>
+ <command name="glProgramBinaryOES"/>
+ </require>
+ </extension>
+ <extension name="GL_OES_mapbuffer" supported="gles1|gles2">
+ <require>
+ <enum name="GL_WRITE_ONLY_OES"/>
+ <enum name="GL_BUFFER_ACCESS_OES"/>
+ <enum name="GL_BUFFER_MAPPED_OES"/>
+ <enum name="GL_BUFFER_MAP_POINTER_OES"/>
+ <command name="glMapBufferOES"/>
+ <command name="glUnmapBufferOES"/>
+ <command name="glGetBufferPointervOES"/>
+ </require>
+ </extension>
+ <extension name="GL_OES_matrix_get" supported="gles1">
+ <require>
+ <enum name="GL_MODELVIEW_MATRIX_FLOAT_AS_INT_BITS_OES"/>
+ <enum name="GL_PROJECTION_MATRIX_FLOAT_AS_INT_BITS_OES"/>
+ <enum name="GL_TEXTURE_MATRIX_FLOAT_AS_INT_BITS_OES"/>
+ </require>
+ </extension>
+ <extension name="GL_OES_matrix_palette" supported="gles1">
+ <require>
+ <enum name="GL_MAX_VERTEX_UNITS_OES"/>
+ <enum name="GL_MAX_PALETTE_MATRICES_OES"/>
+ <enum name="GL_MATRIX_PALETTE_OES"/>
+ <enum name="GL_MATRIX_INDEX_ARRAY_OES"/>
+ <enum name="GL_WEIGHT_ARRAY_OES"/>
+ <enum name="GL_CURRENT_PALETTE_MATRIX_OES"/>
+ <enum name="GL_MATRIX_INDEX_ARRAY_SIZE_OES"/>
+ <enum name="GL_MATRIX_INDEX_ARRAY_TYPE_OES"/>
+ <enum name="GL_MATRIX_INDEX_ARRAY_STRIDE_OES"/>
+ <enum name="GL_MATRIX_INDEX_ARRAY_POINTER_OES"/>
+ <enum name="GL_MATRIX_INDEX_ARRAY_BUFFER_BINDING_OES"/>
+ <enum name="GL_WEIGHT_ARRAY_SIZE_OES"/>
+ <enum name="GL_WEIGHT_ARRAY_TYPE_OES"/>
+ <enum name="GL_WEIGHT_ARRAY_STRIDE_OES"/>
+ <enum name="GL_WEIGHT_ARRAY_POINTER_OES"/>
+ <enum name="GL_WEIGHT_ARRAY_BUFFER_BINDING_OES"/>
+ <command name="glCurrentPaletteMatrixOES"/>
+ <command name="glLoadPaletteFromModelViewMatrixOES"/>
+ <command name="glMatrixIndexPointerOES"/>
+ <command name="glWeightPointerOES"/>
+ </require>
+ </extension>
+ <extension name="GL_OES_packed_depth_stencil" supported="gles1|gles2">
+ <require>
+ <enum name="GL_DEPTH_STENCIL_OES"/>
+ <enum name="GL_UNSIGNED_INT_24_8_OES"/>
+ <enum name="GL_DEPTH24_STENCIL8_OES"/>
+ </require>
+ </extension>
+ <extension name="GL_OES_point_size_array" supported="gles1">
+ <require>
+ <enum name="GL_POINT_SIZE_ARRAY_OES"/>
+ <enum name="GL_POINT_SIZE_ARRAY_TYPE_OES"/>
+ <enum name="GL_POINT_SIZE_ARRAY_STRIDE_OES"/>
+ <enum name="GL_POINT_SIZE_ARRAY_POINTER_OES"/>
+ <enum name="GL_POINT_SIZE_ARRAY_BUFFER_BINDING_OES"/>
+ <command name="glPointSizePointerOES"/>
+ </require>
+ </extension>
+ <extension name="GL_OES_point_sprite" supported="gles1">
+ <require>
+ <enum name="GL_POINT_SPRITE_OES"/>
+ <enum name="GL_COORD_REPLACE_OES"/>
+ </require>
+ </extension>
+ <extension name="GL_OES_query_matrix" supported="gl|gles1">
+ <require>
+ <command name="glQueryMatrixxOES"/>
+ </require>
+ </extension>
+ <extension name="GL_OES_read_format" supported="gl|gles1">
+ <require>
+ <enum name="GL_IMPLEMENTATION_COLOR_READ_TYPE_OES"/>
+ <enum name="GL_IMPLEMENTATION_COLOR_READ_FORMAT_OES"/>
+ </require>
+ </extension>
+ <extension name="GL_OES_required_internalformat" supported="gles1|gles2">
+ <require>
+ <enum name="GL_ALPHA8_OES"/>
+ <enum name="GL_DEPTH_COMPONENT16_OES"/>
+ <enum name="GL_DEPTH_COMPONENT24_OES"/>
+ <enum name="GL_DEPTH24_STENCIL8_OES"/>
+ <enum name="GL_DEPTH_COMPONENT32_OES"/>
+ <enum name="GL_LUMINANCE4_ALPHA4_OES"/>
+ <enum name="GL_LUMINANCE8_ALPHA8_OES"/>
+ <enum name="GL_LUMINANCE8_OES"/>
+ <enum name="GL_RGBA4_OES"/>
+ <enum name="GL_RGB5_A1_OES"/>
+ <enum name="GL_RGB565_OES"/>
+ <enum name="GL_RGB8_OES"/>
+ <enum name="GL_RGBA8_OES"/>
+ <enum name="GL_RGB10_EXT"/>
+ <enum name="GL_RGB10_A2_EXT"/>
+ </require>
+ </extension>
+ <extension name="GL_OES_rgb8_rgba8" supported="gles1|gles2">
+ <require>
+ <enum name="GL_RGB8_OES"/>
+ <enum name="GL_RGBA8_OES"/>
+ </require>
+ </extension>
+ <extension name="GL_OES_sample_shading" supported="gles2">
+ <require>
+ <command name="glMinSampleShadingOES"/>
+ <enum name="GL_SAMPLE_SHADING_OES"/>
+ <enum name="GL_MIN_SAMPLE_SHADING_VALUE_OES"/>
+ </require>
+ </extension>
+ <extension name="GL_OES_sample_variables" supported="gles2"/>
+ <extension name="GL_OES_shader_image_atomic" supported="gles2"/>
+ <extension name="GL_OES_shader_multisample_interpolation" supported="gles2">
+ <require>
+ <enum name="GL_MIN_FRAGMENT_INTERPOLATION_OFFSET_OES"/>
+ <enum name="GL_MAX_FRAGMENT_INTERPOLATION_OFFSET_OES"/>
+ <enum name="GL_FRAGMENT_INTERPOLATION_OFFSET_BITS_OES"/>
+ </require>
+ </extension>
+ <extension name="GL_OES_single_precision" supported="gl|gles1">
+ <require>
+ <command name="glClearDepthfOES"/>
+ <command name="glClipPlanefOES"/>
+ <command name="glDepthRangefOES"/>
+ <command name="glFrustumfOES"/>
+ <command name="glGetClipPlanefOES"/>
+ <command name="glOrthofOES"/>
+ </require>
+ </extension>
+ <extension name="GL_OES_standard_derivatives" supported="gles2">
+ <require>
+ <enum name="GL_FRAGMENT_SHADER_DERIVATIVE_HINT_OES"/>
+ </require>
+ </extension>
+ <extension name="GL_OES_stencil1" supported="gles1|gles2">
+ <require>
+ <enum name="GL_STENCIL_INDEX1_OES"/>
+ </require>
+ </extension>
+ <extension name="GL_OES_stencil4" supported="gles1|gles2">
+ <require>
+ <enum name="GL_STENCIL_INDEX4_OES"/>
+ </require>
+ </extension>
+ <extension name="GL_OES_stencil8" supported="gles1">
+ <require>
+ <enum name="GL_STENCIL_INDEX8_OES"/>
+ </require>
+ </extension>
+ <extension name="GL_OES_stencil_wrap" supported="gles1">
+ <require>
+ <enum name="GL_INCR_WRAP_OES"/>
+ <enum name="GL_DECR_WRAP_OES"/>
+ </require>
+ </extension>
+ <extension name="GL_OES_surfaceless_context" supported="gles2">
+ <require>
+ <enum name="GL_FRAMEBUFFER_UNDEFINED_OES"/>
+ </require>
+ </extension>
+ <extension name="GL_OES_texture_3D" supported="gles2">
+ <require>
+ <enum name="GL_TEXTURE_WRAP_R_OES"/>
+ <enum name="GL_TEXTURE_3D_OES"/>
+ <enum name="GL_TEXTURE_BINDING_3D_OES"/>
+ <enum name="GL_MAX_3D_TEXTURE_SIZE_OES"/>
+ <enum name="GL_SAMPLER_3D_OES"/>
+ <enum name="GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_3D_ZOFFSET_OES"/>
+ <command name="glTexImage3DOES"/>
+ <command name="glTexSubImage3DOES"/>
+ <command name="glCopyTexSubImage3DOES"/>
+ <command name="glCompressedTexImage3DOES"/>
+ <command name="glCompressedTexSubImage3DOES"/>
+ <command name="glFramebufferTexture3DOES"/>
+ </require>
+ </extension>
+ <extension name="GL_OES_texture_compression_astc" supported="gles2" comment="API is identical to GL_KHR_texture_compression_astc_hdr extension">
+ <require>
+ <enum name="GL_COMPRESSED_RGBA_ASTC_4x4_KHR"/>
+ <enum name="GL_COMPRESSED_RGBA_ASTC_5x4_KHR"/>
+ <enum name="GL_COMPRESSED_RGBA_ASTC_5x5_KHR"/>
+ <enum name="GL_COMPRESSED_RGBA_ASTC_6x5_KHR"/>
+ <enum name="GL_COMPRESSED_RGBA_ASTC_6x6_KHR"/>
+ <enum name="GL_COMPRESSED_RGBA_ASTC_8x5_KHR"/>
+ <enum name="GL_COMPRESSED_RGBA_ASTC_8x6_KHR"/>
+ <enum name="GL_COMPRESSED_RGBA_ASTC_8x8_KHR"/>
+ <enum name="GL_COMPRESSED_RGBA_ASTC_10x5_KHR"/>
+ <enum name="GL_COMPRESSED_RGBA_ASTC_10x6_KHR"/>
+ <enum name="GL_COMPRESSED_RGBA_ASTC_10x8_KHR"/>
+ <enum name="GL_COMPRESSED_RGBA_ASTC_10x10_KHR"/>
+ <enum name="GL_COMPRESSED_RGBA_ASTC_12x10_KHR"/>
+ <enum name="GL_COMPRESSED_RGBA_ASTC_12x12_KHR"/>
+ <enum name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_4x4_KHR"/>
+ <enum name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_5x4_KHR"/>
+ <enum name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_5x5_KHR"/>
+ <enum name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_6x5_KHR"/>
+ <enum name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_6x6_KHR"/>
+ <enum name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_8x5_KHR"/>
+ <enum name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_8x6_KHR"/>
+ <enum name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_8x8_KHR"/>
+ <enum name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_10x5_KHR"/>
+ <enum name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_10x6_KHR"/>
+ <enum name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_10x8_KHR"/>
+ <enum name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_10x10_KHR"/>
+ <enum name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_12x10_KHR"/>
+ <enum name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_12x12_KHR"/>
+ <enum name="GL_COMPRESSED_RGBA_ASTC_3x3x3_OES"/>
+ <enum name="GL_COMPRESSED_RGBA_ASTC_4x3x3_OES"/>
+ <enum name="GL_COMPRESSED_RGBA_ASTC_4x4x3_OES"/>
+ <enum name="GL_COMPRESSED_RGBA_ASTC_4x4x4_OES"/>
+ <enum name="GL_COMPRESSED_RGBA_ASTC_5x4x4_OES"/>
+ <enum name="GL_COMPRESSED_RGBA_ASTC_5x5x4_OES"/>
+ <enum name="GL_COMPRESSED_RGBA_ASTC_5x5x5_OES"/>
+ <enum name="GL_COMPRESSED_RGBA_ASTC_6x5x5_OES"/>
+ <enum name="GL_COMPRESSED_RGBA_ASTC_6x6x5_OES"/>
+ <enum name="GL_COMPRESSED_RGBA_ASTC_6x6x6_OES"/>
+ <enum name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_3x3x3_OES"/>
+ <enum name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_4x3x3_OES"/>
+ <enum name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_4x4x3_OES"/>
+ <enum name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_4x4x4_OES"/>
+ <enum name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_5x4x4_OES"/>
+ <enum name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_5x5x4_OES"/>
+ <enum name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_5x5x5_OES"/>
+ <enum name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_6x5x5_OES"/>
+ <enum name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_6x6x5_OES"/>
+ <enum name="GL_COMPRESSED_SRGB8_ALPHA8_ASTC_6x6x6_OES"/>
+ </require>
+ </extension>
+ <extension name="GL_OES_texture_cube_map" supported="gles1">
+ <require>
+ <enum name="GL_NORMAL_MAP_OES"/>
+ <enum name="GL_REFLECTION_MAP_OES"/>
+ <enum name="GL_TEXTURE_CUBE_MAP_OES"/>
+ <enum name="GL_TEXTURE_BINDING_CUBE_MAP_OES"/>
+ <enum name="GL_TEXTURE_CUBE_MAP_POSITIVE_X_OES"/>
+ <enum name="GL_TEXTURE_CUBE_MAP_NEGATIVE_X_OES"/>
+ <enum name="GL_TEXTURE_CUBE_MAP_POSITIVE_Y_OES"/>
+ <enum name="GL_TEXTURE_CUBE_MAP_NEGATIVE_Y_OES"/>
+ <enum name="GL_TEXTURE_CUBE_MAP_POSITIVE_Z_OES"/>
+ <enum name="GL_TEXTURE_CUBE_MAP_NEGATIVE_Z_OES"/>
+ <enum name="GL_MAX_CUBE_MAP_TEXTURE_SIZE_OES"/>
+ <enum name="GL_TEXTURE_GEN_MODE_OES"/>
+ <enum name="GL_TEXTURE_GEN_STR_OES"/>
+ <command name="glTexGenfOES"/>
+ <command name="glTexGenfvOES"/>
+ <command name="glTexGeniOES"/>
+ <command name="glTexGenivOES"/>
+ <command name="glTexGenxOES"/>
+ <command name="glTexGenxvOES"/>
+ <command name="glGetTexGenfvOES"/>
+ <command name="glGetTexGenivOES"/>
+ <command name="glGetTexGenxvOES"/>
+ </require>
+ </extension>
+ <extension name="GL_OES_texture_env_crossbar" supported="gles1"/>
+ <extension name="GL_OES_texture_float" supported="gles2">
+ <require>
+ <enum name="GL_FLOAT"/>
+ </require>
+ </extension>
+ <extension name="GL_OES_texture_float_linear" supported="gles2"/>
+ <extension name="GL_OES_texture_half_float" supported="gles2">
+ <require>
+ <enum name="GL_HALF_FLOAT_OES"/>
+ </require>
+ </extension>
+ <extension name="GL_OES_texture_half_float_linear" supported="gles2"/>
+ <extension name="GL_OES_texture_mirrored_repeat" supported="gles1">
+ <require>
+ <enum name="GL_MIRRORED_REPEAT_OES"/>
+ </require>
+ </extension>
+ <extension name="GL_OES_texture_npot" supported="gles2"/>
+ <extension name="GL_OES_texture_stencil8" supported="gles2">
+ <require>
+ <enum name="GL_STENCIL_INDEX_OES"/>
+ <enum name="GL_STENCIL_INDEX8_OES"/>
+ </require>
+ </extension>
+ <extension name="GL_OES_texture_storage_multisample_2d_array" supported="gles2">
+ <require>
+ <command name="glTexStorage3DMultisampleOES"/>
+ <enum name="GL_TEXTURE_2D_MULTISAMPLE_ARRAY_OES"/>
+ <enum name="GL_TEXTURE_BINDING_2D_MULTISAMPLE_ARRAY_OES"/>
+ <enum name="GL_SAMPLER_2D_MULTISAMPLE_ARRAY_OES"/>
+ <enum name="GL_INT_SAMPLER_2D_MULTISAMPLE_ARRAY_OES"/>
+ <enum name="GL_UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE_ARRAY_OES"/>
+ </require>
+ </extension>
+ <extension name="GL_OES_vertex_array_object" supported="gles1|gles2">
+ <require>
+ <enum name="GL_VERTEX_ARRAY_BINDING_OES"/>
+ <command name="glBindVertexArrayOES"/>
+ <command name="glDeleteVertexArraysOES"/>
+ <command name="glGenVertexArraysOES"/>
+ <command name="glIsVertexArrayOES"/>
+ </require>
+ </extension>
+ <extension name="GL_OES_vertex_half_float" supported="gles2">
+ <require>
+ <enum name="GL_HALF_FLOAT_OES"/>
+ </require>
+ </extension>
+ <extension name="GL_OES_vertex_type_10_10_10_2" supported="gles2">
+ <require>
+ <enum name="GL_UNSIGNED_INT_10_10_10_2_OES"/>
+ <enum name="GL_INT_10_10_10_2_OES"/>
+ </require>
+ </extension>
+ <extension name="GL_OML_interlace" supported="gl">
+ <require>
+ <enum name="GL_INTERLACE_OML"/>
+ <enum name="GL_INTERLACE_READ_OML"/>
+ </require>
+ </extension>
+ <extension name="GL_OML_resample" supported="gl">
+ <require>
+ <enum name="GL_PACK_RESAMPLE_OML"/>
+ <enum name="GL_UNPACK_RESAMPLE_OML"/>
+ <enum name="GL_RESAMPLE_REPLICATE_OML"/>
+ <enum name="GL_RESAMPLE_ZERO_FILL_OML"/>
+ <enum name="GL_RESAMPLE_AVERAGE_OML"/>
+ <enum name="GL_RESAMPLE_DECIMATE_OML"/>
+ </require>
+ </extension>
+ <extension name="GL_OML_subsample" supported="gl">
+ <require>
+ <enum name="GL_FORMAT_SUBSAMPLE_24_24_OML"/>
+ <enum name="GL_FORMAT_SUBSAMPLE_244_244_OML"/>
+ </require>
+ </extension>
+ <extension name="GL_PGI_misc_hints" supported="gl">
+ <require>
+ <enum name="GL_PREFER_DOUBLEBUFFER_HINT_PGI"/>
+ <enum name="GL_CONSERVE_MEMORY_HINT_PGI"/>
+ <enum name="GL_RECLAIM_MEMORY_HINT_PGI"/>
+ <enum name="GL_NATIVE_GRAPHICS_HANDLE_PGI"/>
+ <enum name="GL_NATIVE_GRAPHICS_BEGIN_HINT_PGI"/>
+ <enum name="GL_NATIVE_GRAPHICS_END_HINT_PGI"/>
+ <enum name="GL_ALWAYS_FAST_HINT_PGI"/>
+ <enum name="GL_ALWAYS_SOFT_HINT_PGI"/>
+ <enum name="GL_ALLOW_DRAW_OBJ_HINT_PGI"/>
+ <enum name="GL_ALLOW_DRAW_WIN_HINT_PGI"/>
+ <enum name="GL_ALLOW_DRAW_FRG_HINT_PGI"/>
+ <enum name="GL_ALLOW_DRAW_MEM_HINT_PGI"/>
+ <enum name="GL_STRICT_DEPTHFUNC_HINT_PGI"/>
+ <enum name="GL_STRICT_LIGHTING_HINT_PGI"/>
+ <enum name="GL_STRICT_SCISSOR_HINT_PGI"/>
+ <enum name="GL_FULL_STIPPLE_HINT_PGI"/>
+ <enum name="GL_CLIP_NEAR_HINT_PGI"/>
+ <enum name="GL_CLIP_FAR_HINT_PGI"/>
+ <enum name="GL_WIDE_LINE_HINT_PGI"/>
+ <enum name="GL_BACK_NORMALS_HINT_PGI"/>
+ <command name="glHintPGI"/>
+ </require>
+ </extension>
+ <extension name="GL_PGI_vertex_hints" supported="gl">
+ <require>
+ <enum name="GL_VERTEX_DATA_HINT_PGI"/>
+ <enum name="GL_VERTEX_CONSISTENT_HINT_PGI"/>
+ <enum name="GL_MATERIAL_SIDE_HINT_PGI"/>
+ <enum name="GL_MAX_VERTEX_HINT_PGI"/>
+ <enum name="GL_COLOR3_BIT_PGI"/>
+ <enum name="GL_COLOR4_BIT_PGI"/>
+ <enum name="GL_EDGEFLAG_BIT_PGI"/>
+ <enum name="GL_INDEX_BIT_PGI"/>
+ <enum name="GL_MAT_AMBIENT_BIT_PGI"/>
+ <enum name="GL_MAT_AMBIENT_AND_DIFFUSE_BIT_PGI"/>
+ <enum name="GL_MAT_DIFFUSE_BIT_PGI"/>
+ <enum name="GL_MAT_EMISSION_BIT_PGI"/>
+ <enum name="GL_MAT_COLOR_INDEXES_BIT_PGI"/>
+ <enum name="GL_MAT_SHININESS_BIT_PGI"/>
+ <enum name="GL_MAT_SPECULAR_BIT_PGI"/>
+ <enum name="GL_NORMAL_BIT_PGI"/>
+ <enum name="GL_TEXCOORD1_BIT_PGI"/>
+ <enum name="GL_TEXCOORD2_BIT_PGI"/>
+ <enum name="GL_TEXCOORD3_BIT_PGI"/>
+ <enum name="GL_TEXCOORD4_BIT_PGI"/>
+ <enum name="GL_VERTEX23_BIT_PGI"/>
+ <enum name="GL_VERTEX4_BIT_PGI"/>
+ </require>
+ </extension>
+ <extension name="GL_QCOM_alpha_test" supported="gles2">
+ <require>
+ <enum name="GL_ALPHA_TEST_QCOM"/>
+ <enum name="GL_ALPHA_TEST_FUNC_QCOM"/>
+ <enum name="GL_ALPHA_TEST_REF_QCOM"/>
+ <command name="glAlphaFuncQCOM"/>
+ </require>
+ </extension>
+ <extension name="GL_QCOM_binning_control" supported="gles2">
+ <require>
+ <enum name="GL_BINNING_CONTROL_HINT_QCOM"/>
+ <enum name="GL_CPU_OPTIMIZED_QCOM"/>
+ <enum name="GL_GPU_OPTIMIZED_QCOM"/>
+ <enum name="GL_RENDER_DIRECT_TO_FRAMEBUFFER_QCOM"/>
+ </require>
+ </extension>
+ <extension name="GL_QCOM_driver_control" supported="gles1|gles2">
+ <require>
+ <command name="glGetDriverControlsQCOM"/>
+ <command name="glGetDriverControlStringQCOM"/>
+ <command name="glEnableDriverControlQCOM"/>
+ <command name="glDisableDriverControlQCOM"/>
+ </require>
+ </extension>
+ <extension name="GL_QCOM_extended_get" supported="gles1|gles2">
+ <require>
+ <enum name="GL_TEXTURE_WIDTH_QCOM"/>
+ <enum name="GL_TEXTURE_HEIGHT_QCOM"/>
+ <enum name="GL_TEXTURE_DEPTH_QCOM"/>
+ <enum name="GL_TEXTURE_INTERNAL_FORMAT_QCOM"/>
+ <enum name="GL_TEXTURE_FORMAT_QCOM"/>
+ <enum name="GL_TEXTURE_TYPE_QCOM"/>
+ <enum name="GL_TEXTURE_IMAGE_VALID_QCOM"/>
+ <enum name="GL_TEXTURE_NUM_LEVELS_QCOM"/>
+ <enum name="GL_TEXTURE_TARGET_QCOM"/>
+ <enum name="GL_TEXTURE_OBJECT_VALID_QCOM"/>
+ <enum name="GL_STATE_RESTORE"/>
+ <command name="glExtGetTexturesQCOM"/>
+ <command name="glExtGetBuffersQCOM"/>
+ <command name="glExtGetRenderbuffersQCOM"/>
+ <command name="glExtGetFramebuffersQCOM"/>
+ <command name="glExtGetTexLevelParameterivQCOM"/>
+ <command name="glExtTexObjectStateOverrideiQCOM"/>
+ <command name="glExtGetTexSubImageQCOM"/>
+ <command name="glExtGetBufferPointervQCOM"/>
+ </require>
+ </extension>
+ <extension name="GL_QCOM_extended_get2" supported="gles1|gles2">
+ <require>
+ <command name="glExtGetShadersQCOM"/>
+ <command name="glExtGetProgramsQCOM"/>
+ <command name="glExtIsProgramBinaryQCOM"/>
+ <command name="glExtGetProgramBinarySourceQCOM"/>
+ </require>
+ </extension>
+ <extension name="GL_QCOM_perfmon_global_mode" supported="gles1|gles2">
+ <require>
+ <enum name="GL_PERFMON_GLOBAL_MODE_QCOM"/>
+ </require>
+ </extension>
+ <extension name="GL_QCOM_tiled_rendering" supported="gles1|gles2">
+ <require>
+ <enum name="GL_COLOR_BUFFER_BIT0_QCOM"/>
+ <enum name="GL_COLOR_BUFFER_BIT1_QCOM"/>
+ <enum name="GL_COLOR_BUFFER_BIT2_QCOM"/>
+ <enum name="GL_COLOR_BUFFER_BIT3_QCOM"/>
+ <enum name="GL_COLOR_BUFFER_BIT4_QCOM"/>
+ <enum name="GL_COLOR_BUFFER_BIT5_QCOM"/>
+ <enum name="GL_COLOR_BUFFER_BIT6_QCOM"/>
+ <enum name="GL_COLOR_BUFFER_BIT7_QCOM"/>
+ <enum name="GL_DEPTH_BUFFER_BIT0_QCOM"/>
+ <enum name="GL_DEPTH_BUFFER_BIT1_QCOM"/>
+ <enum name="GL_DEPTH_BUFFER_BIT2_QCOM"/>
+ <enum name="GL_DEPTH_BUFFER_BIT3_QCOM"/>
+ <enum name="GL_DEPTH_BUFFER_BIT4_QCOM"/>
+ <enum name="GL_DEPTH_BUFFER_BIT5_QCOM"/>
+ <enum name="GL_DEPTH_BUFFER_BIT6_QCOM"/>
+ <enum name="GL_DEPTH_BUFFER_BIT7_QCOM"/>
+ <enum name="GL_STENCIL_BUFFER_BIT0_QCOM"/>
+ <enum name="GL_STENCIL_BUFFER_BIT1_QCOM"/>
+ <enum name="GL_STENCIL_BUFFER_BIT2_QCOM"/>
+ <enum name="GL_STENCIL_BUFFER_BIT3_QCOM"/>
+ <enum name="GL_STENCIL_BUFFER_BIT4_QCOM"/>
+ <enum name="GL_STENCIL_BUFFER_BIT5_QCOM"/>
+ <enum name="GL_STENCIL_BUFFER_BIT6_QCOM"/>
+ <enum name="GL_STENCIL_BUFFER_BIT7_QCOM"/>
+ <enum name="GL_MULTISAMPLE_BUFFER_BIT0_QCOM"/>
+ <enum name="GL_MULTISAMPLE_BUFFER_BIT1_QCOM"/>
+ <enum name="GL_MULTISAMPLE_BUFFER_BIT2_QCOM"/>
+ <enum name="GL_MULTISAMPLE_BUFFER_BIT3_QCOM"/>
+ <enum name="GL_MULTISAMPLE_BUFFER_BIT4_QCOM"/>
+ <enum name="GL_MULTISAMPLE_BUFFER_BIT5_QCOM"/>
+ <enum name="GL_MULTISAMPLE_BUFFER_BIT6_QCOM"/>
+ <enum name="GL_MULTISAMPLE_BUFFER_BIT7_QCOM"/>
+ <command name="glStartTilingQCOM"/>
+ <command name="glEndTilingQCOM"/>
+ </require>
+ </extension>
+ <extension name="GL_QCOM_writeonly_rendering" supported="gles1|gles2">
+ <require>
+ <enum name="GL_WRITEONLY_RENDERING_QCOM"/>
+ </require>
+ </extension>
+ <extension name="GL_REND_screen_coordinates" supported="gl">
+ <require>
+ <enum name="GL_SCREEN_COORDINATES_REND"/>
+ <enum name="GL_INVERTED_SCREEN_W_REND"/>
+ </require>
+ </extension>
+ <extension name="GL_S3_s3tc" supported="gl">
+ <require>
+ <enum name="GL_RGB_S3TC"/>
+ <enum name="GL_RGB4_S3TC"/>
+ <enum name="GL_RGBA_S3TC"/>
+ <enum name="GL_RGBA4_S3TC"/>
+ <enum name="GL_RGBA_DXT5_S3TC"/>
+ <enum name="GL_RGBA4_DXT5_S3TC"/>
+ </require>
+ </extension>
+ <extension name="GL_SGIS_detail_texture" supported="gl">
+ <require>
+ <enum name="GL_DETAIL_TEXTURE_2D_SGIS"/>
+ <enum name="GL_DETAIL_TEXTURE_2D_BINDING_SGIS"/>
+ <enum name="GL_LINEAR_DETAIL_SGIS"/>
+ <enum name="GL_LINEAR_DETAIL_ALPHA_SGIS"/>
+ <enum name="GL_LINEAR_DETAIL_COLOR_SGIS"/>
+ <enum name="GL_DETAIL_TEXTURE_LEVEL_SGIS"/>
+ <enum name="GL_DETAIL_TEXTURE_MODE_SGIS"/>
+ <enum name="GL_DETAIL_TEXTURE_FUNC_POINTS_SGIS"/>
+ <command name="glDetailTexFuncSGIS"/>
+ <command name="glGetDetailTexFuncSGIS"/>
+ </require>
+ </extension>
+ <extension name="GL_SGIS_fog_function" supported="gl">
+ <require>
+ <enum name="GL_FOG_FUNC_SGIS"/>
+ <enum name="GL_FOG_FUNC_POINTS_SGIS"/>
+ <enum name="GL_MAX_FOG_FUNC_POINTS_SGIS"/>
+ <command name="glFogFuncSGIS"/>
+ <command name="glGetFogFuncSGIS"/>
+ </require>
+ </extension>
+ <extension name="GL_SGIS_generate_mipmap" supported="gl">
+ <require>
+ <enum name="GL_GENERATE_MIPMAP_SGIS"/>
+ <enum name="GL_GENERATE_MIPMAP_HINT_SGIS"/>
+ </require>
+ </extension>
+ <extension name="GL_SGIS_multisample" supported="gl">
+ <require>
+ <enum name="GL_MULTISAMPLE_SGIS"/>
+ <enum name="GL_SAMPLE_ALPHA_TO_MASK_SGIS"/>
+ <enum name="GL_SAMPLE_ALPHA_TO_ONE_SGIS"/>
+ <enum name="GL_SAMPLE_MASK_SGIS"/>
+ <enum name="GL_1PASS_SGIS"/>
+ <enum name="GL_2PASS_0_SGIS"/>
+ <enum name="GL_2PASS_1_SGIS"/>
+ <enum name="GL_4PASS_0_SGIS"/>
+ <enum name="GL_4PASS_1_SGIS"/>
+ <enum name="GL_4PASS_2_SGIS"/>
+ <enum name="GL_4PASS_3_SGIS"/>
+ <enum name="GL_SAMPLE_BUFFERS_SGIS"/>
+ <enum name="GL_SAMPLES_SGIS"/>
+ <enum name="GL_SAMPLE_MASK_VALUE_SGIS"/>
+ <enum name="GL_SAMPLE_MASK_INVERT_SGIS"/>
+ <enum name="GL_SAMPLE_PATTERN_SGIS"/>
+ <command name="glSampleMaskSGIS"/>
+ <command name="glSamplePatternSGIS"/>
+ </require>
+ </extension>
+ <extension name="GL_SGIS_pixel_texture" supported="gl">
+ <require>
+ <enum name="GL_PIXEL_TEXTURE_SGIS"/>
+ <enum name="GL_PIXEL_FRAGMENT_RGB_SOURCE_SGIS"/>
+ <enum name="GL_PIXEL_FRAGMENT_ALPHA_SOURCE_SGIS"/>
+ <enum name="GL_PIXEL_GROUP_COLOR_SGIS"/>
+ <command name="glPixelTexGenParameteriSGIS"/>
+ <command name="glPixelTexGenParameterivSGIS"/>
+ <command name="glPixelTexGenParameterfSGIS"/>
+ <command name="glPixelTexGenParameterfvSGIS"/>
+ <command name="glGetPixelTexGenParameterivSGIS"/>
+ <command name="glGetPixelTexGenParameterfvSGIS"/>
+ </require>
+ </extension>
+ <extension name="GL_SGIS_point_line_texgen" supported="gl">
+ <require>
+ <enum name="GL_EYE_DISTANCE_TO_POINT_SGIS"/>
+ <enum name="GL_OBJECT_DISTANCE_TO_POINT_SGIS"/>
+ <enum name="GL_EYE_DISTANCE_TO_LINE_SGIS"/>
+ <enum name="GL_OBJECT_DISTANCE_TO_LINE_SGIS"/>
+ <enum name="GL_EYE_POINT_SGIS"/>
+ <enum name="GL_OBJECT_POINT_SGIS"/>
+ <enum name="GL_EYE_LINE_SGIS"/>
+ <enum name="GL_OBJECT_LINE_SGIS"/>
+ </require>
+ </extension>
+ <extension name="GL_SGIS_point_parameters" supported="gl">
+ <require>
+ <enum name="GL_POINT_SIZE_MIN_SGIS"/>
+ <enum name="GL_POINT_SIZE_MAX_SGIS"/>
+ <enum name="GL_POINT_FADE_THRESHOLD_SIZE_SGIS"/>
+ <enum name="GL_DISTANCE_ATTENUATION_SGIS"/>
+ <command name="glPointParameterfSGIS"/>
+ <command name="glPointParameterfvSGIS"/>
+ </require>
+ </extension>
+ <extension name="GL_SGIS_sharpen_texture" supported="gl">
+ <require>
+ <enum name="GL_LINEAR_SHARPEN_SGIS"/>
+ <enum name="GL_LINEAR_SHARPEN_ALPHA_SGIS"/>
+ <enum name="GL_LINEAR_SHARPEN_COLOR_SGIS"/>
+ <enum name="GL_SHARPEN_TEXTURE_FUNC_POINTS_SGIS"/>
+ <command name="glSharpenTexFuncSGIS"/>
+ <command name="glGetSharpenTexFuncSGIS"/>
+ </require>
+ </extension>
+ <extension name="GL_SGIS_texture4D" supported="gl">
+ <require>
+ <enum name="GL_PACK_SKIP_VOLUMES_SGIS"/>
+ <enum name="GL_PACK_IMAGE_DEPTH_SGIS"/>
+ <enum name="GL_UNPACK_SKIP_VOLUMES_SGIS"/>
+ <enum name="GL_UNPACK_IMAGE_DEPTH_SGIS"/>
+ <enum name="GL_TEXTURE_4D_SGIS"/>
+ <enum name="GL_PROXY_TEXTURE_4D_SGIS"/>
+ <enum name="GL_TEXTURE_4DSIZE_SGIS"/>
+ <enum name="GL_TEXTURE_WRAP_Q_SGIS"/>
+ <enum name="GL_MAX_4D_TEXTURE_SIZE_SGIS"/>
+ <enum name="GL_TEXTURE_4D_BINDING_SGIS"/>
+ <command name="glTexImage4DSGIS"/>
+ <command name="glTexSubImage4DSGIS"/>
+ </require>
+ </extension>
+ <extension name="GL_SGIS_texture_border_clamp" supported="gl">
+ <require>
+ <enum name="GL_CLAMP_TO_BORDER_SGIS"/>
+ </require>
+ </extension>
+ <extension name="GL_SGIS_texture_color_mask" supported="gl">
+ <require>
+ <enum name="GL_TEXTURE_COLOR_WRITEMASK_SGIS"/>
+ <command name="glTextureColorMaskSGIS"/>
+ </require>
+ </extension>
+ <extension name="GL_SGIS_texture_edge_clamp" supported="gl">
+ <require>
+ <enum name="GL_CLAMP_TO_EDGE_SGIS"/>
+ </require>
+ </extension>
+ <extension name="GL_SGIS_texture_filter4" supported="gl">
+ <require>
+ <enum name="GL_FILTER4_SGIS"/>
+ <enum name="GL_TEXTURE_FILTER4_SIZE_SGIS"/>
+ <command name="glGetTexFilterFuncSGIS"/>
+ <command name="glTexFilterFuncSGIS"/>
+ </require>
+ </extension>
+ <extension name="GL_SGIS_texture_lod" supported="gl">
+ <require>
+ <enum name="GL_TEXTURE_MIN_LOD_SGIS"/>
+ <enum name="GL_TEXTURE_MAX_LOD_SGIS"/>
+ <enum name="GL_TEXTURE_BASE_LEVEL_SGIS"/>
+ <enum name="GL_TEXTURE_MAX_LEVEL_SGIS"/>
+ </require>
+ </extension>
+ <extension name="GL_SGIS_texture_select" supported="gl">
+ <require>
+ <enum name="GL_DUAL_ALPHA4_SGIS"/>
+ <enum name="GL_DUAL_ALPHA8_SGIS"/>
+ <enum name="GL_DUAL_ALPHA12_SGIS"/>
+ <enum name="GL_DUAL_ALPHA16_SGIS"/>
+ <enum name="GL_DUAL_LUMINANCE4_SGIS"/>
+ <enum name="GL_DUAL_LUMINANCE8_SGIS"/>
+ <enum name="GL_DUAL_LUMINANCE12_SGIS"/>
+ <enum name="GL_DUAL_LUMINANCE16_SGIS"/>
+ <enum name="GL_DUAL_INTENSITY4_SGIS"/>
+ <enum name="GL_DUAL_INTENSITY8_SGIS"/>
+ <enum name="GL_DUAL_INTENSITY12_SGIS"/>
+ <enum name="GL_DUAL_INTENSITY16_SGIS"/>
+ <enum name="GL_DUAL_LUMINANCE_ALPHA4_SGIS"/>
+ <enum name="GL_DUAL_LUMINANCE_ALPHA8_SGIS"/>
+ <enum name="GL_QUAD_ALPHA4_SGIS"/>
+ <enum name="GL_QUAD_ALPHA8_SGIS"/>
+ <enum name="GL_QUAD_LUMINANCE4_SGIS"/>
+ <enum name="GL_QUAD_LUMINANCE8_SGIS"/>
+ <enum name="GL_QUAD_INTENSITY4_SGIS"/>
+ <enum name="GL_QUAD_INTENSITY8_SGIS"/>
+ <enum name="GL_DUAL_TEXTURE_SELECT_SGIS"/>
+ <enum name="GL_QUAD_TEXTURE_SELECT_SGIS"/>
+ </require>
+ </extension>
+ <extension name="GL_SGIX_async" supported="gl">
+ <require>
+ <enum name="GL_ASYNC_MARKER_SGIX"/>
+ <command name="glAsyncMarkerSGIX"/>
+ <command name="glFinishAsyncSGIX"/>
+ <command name="glPollAsyncSGIX"/>
+ <command name="glGenAsyncMarkersSGIX"/>
+ <command name="glDeleteAsyncMarkersSGIX"/>
+ <command name="glIsAsyncMarkerSGIX"/>
+ </require>
+ </extension>
+ <extension name="GL_SGIX_async_histogram" supported="gl">
+ <require>
+ <enum name="GL_ASYNC_HISTOGRAM_SGIX"/>
+ <enum name="GL_MAX_ASYNC_HISTOGRAM_SGIX"/>
+ </require>
+ </extension>
+ <extension name="GL_SGIX_async_pixel" supported="gl">
+ <require>
+ <enum name="GL_ASYNC_TEX_IMAGE_SGIX"/>
+ <enum name="GL_ASYNC_DRAW_PIXELS_SGIX"/>
+ <enum name="GL_ASYNC_READ_PIXELS_SGIX"/>
+ <enum name="GL_MAX_ASYNC_TEX_IMAGE_SGIX"/>
+ <enum name="GL_MAX_ASYNC_DRAW_PIXELS_SGIX"/>
+ <enum name="GL_MAX_ASYNC_READ_PIXELS_SGIX"/>
+ </require>
+ </extension>
+ <extension name="GL_SGIX_blend_alpha_minmax" supported="gl">
+ <require>
+ <enum name="GL_ALPHA_MIN_SGIX"/>
+ <enum name="GL_ALPHA_MAX_SGIX"/>
+ </require>
+ </extension>
+ <extension name="GL_SGIX_calligraphic_fragment" supported="gl">
+ <require>
+ <enum name="GL_CALLIGRAPHIC_FRAGMENT_SGIX"/>
+ </require>
+ </extension>
+ <extension name="GL_SGIX_clipmap" supported="gl">
+ <require>
+ <enum name="GL_LINEAR_CLIPMAP_LINEAR_SGIX"/>
+ <enum name="GL_TEXTURE_CLIPMAP_CENTER_SGIX"/>
+ <enum name="GL_TEXTURE_CLIPMAP_FRAME_SGIX"/>
+ <enum name="GL_TEXTURE_CLIPMAP_OFFSET_SGIX"/>
+ <enum name="GL_TEXTURE_CLIPMAP_VIRTUAL_DEPTH_SGIX"/>
+ <enum name="GL_TEXTURE_CLIPMAP_LOD_OFFSET_SGIX"/>
+ <enum name="GL_TEXTURE_CLIPMAP_DEPTH_SGIX"/>
+ <enum name="GL_MAX_CLIPMAP_DEPTH_SGIX"/>
+ <enum name="GL_MAX_CLIPMAP_VIRTUAL_DEPTH_SGIX"/>
+ <enum name="GL_NEAREST_CLIPMAP_NEAREST_SGIX"/>
+ <enum name="GL_NEAREST_CLIPMAP_LINEAR_SGIX"/>
+ <enum name="GL_LINEAR_CLIPMAP_NEAREST_SGIX"/>
+ </require>
+ </extension>
+ <extension name="GL_SGIX_convolution_accuracy" supported="gl">
+ <require>
+ <enum name="GL_CONVOLUTION_HINT_SGIX"/>
+ </require>
+ </extension>
+ <extension name="GL_SGIX_depth_pass_instrument" supported="gl"/>
+ <extension name="GL_SGIX_depth_texture" supported="gl">
+ <require>
+ <enum name="GL_DEPTH_COMPONENT16_SGIX"/>
+ <enum name="GL_DEPTH_COMPONENT24_SGIX"/>
+ <enum name="GL_DEPTH_COMPONENT32_SGIX"/>
+ </require>
+ </extension>
+ <extension name="GL_SGIX_flush_raster" supported="gl">
+ <require>
+ <command name="glFlushRasterSGIX"/>
+ </require>
+ </extension>
+ <extension name="GL_SGIX_fog_offset" supported="gl">
+ <require>
+ <enum name="GL_FOG_OFFSET_SGIX"/>
+ <enum name="GL_FOG_OFFSET_VALUE_SGIX"/>
+ </require>
+ </extension>
+ <extension name="GL_SGIX_fragment_lighting" supported="gl" comment="Incomplete extension">
+ <require>
+ <enum name="GL_FRAGMENT_LIGHTING_SGIX"/>
+ <enum name="GL_FRAGMENT_COLOR_MATERIAL_SGIX"/>
+ <enum name="GL_FRAGMENT_COLOR_MATERIAL_FACE_SGIX"/>
+ <enum name="GL_FRAGMENT_COLOR_MATERIAL_PARAMETER_SGIX"/>
+ <enum name="GL_MAX_FRAGMENT_LIGHTS_SGIX"/>
+ <enum name="GL_MAX_ACTIVE_LIGHTS_SGIX"/>
+ <enum name="GL_CURRENT_RASTER_NORMAL_SGIX"/>
+ <enum name="GL_LIGHT_ENV_MODE_SGIX"/>
+ <enum name="GL_FRAGMENT_LIGHT_MODEL_LOCAL_VIEWER_SGIX"/>
+ <enum name="GL_FRAGMENT_LIGHT_MODEL_TWO_SIDE_SGIX"/>
+ <enum name="GL_FRAGMENT_LIGHT_MODEL_AMBIENT_SGIX"/>
+ <enum name="GL_FRAGMENT_LIGHT_MODEL_NORMAL_INTERPOLATION_SGIX"/>
+ <enum name="GL_FRAGMENT_LIGHT0_SGIX"/>
+ <enum name="GL_FRAGMENT_LIGHT1_SGIX"/>
+ <enum name="GL_FRAGMENT_LIGHT2_SGIX"/>
+ <enum name="GL_FRAGMENT_LIGHT3_SGIX"/>
+ <enum name="GL_FRAGMENT_LIGHT4_SGIX"/>
+ <enum name="GL_FRAGMENT_LIGHT5_SGIX"/>
+ <enum name="GL_FRAGMENT_LIGHT6_SGIX"/>
+ <enum name="GL_FRAGMENT_LIGHT7_SGIX"/>
+ <command name="glFragmentColorMaterialSGIX"/>
+ <command name="glFragmentLightfSGIX"/>
+ <command name="glFragmentLightfvSGIX"/>
+ <command name="glFragmentLightiSGIX"/>
+ <command name="glFragmentLightivSGIX"/>
+ <command name="glFragmentLightModelfSGIX"/>
+ <command name="glFragmentLightModelfvSGIX"/>
+ <command name="glFragmentLightModeliSGIX"/>
+ <command name="glFragmentLightModelivSGIX"/>
+ <command name="glFragmentMaterialfSGIX"/>
+ <command name="glFragmentMaterialfvSGIX"/>
+ <command name="glFragmentMaterialiSGIX"/>
+ <command name="glFragmentMaterialivSGIX"/>
+ <command name="glGetFragmentLightfvSGIX"/>
+ <command name="glGetFragmentLightivSGIX"/>
+ <command name="glGetFragmentMaterialfvSGIX"/>
+ <command name="glGetFragmentMaterialivSGIX"/>
+ <command name="glLightEnviSGIX"/>
+ </require>
+ </extension>
+ <extension name="GL_SGIX_framezoom" supported="gl">
+ <require>
+ <enum name="GL_FRAMEZOOM_SGIX"/>
+ <enum name="GL_FRAMEZOOM_FACTOR_SGIX"/>
+ <enum name="GL_MAX_FRAMEZOOM_FACTOR_SGIX"/>
+ <command name="glFrameZoomSGIX"/>
+ </require>
+ </extension>
+ <extension name="GL_SGIX_igloo_interface" supported="gl">
+ <require>
+ <command name="glIglooInterfaceSGIX"/>
+ </require>
+ </extension>
+ <extension name="GL_SGIX_instruments" supported="gl">
+ <require>
+ <enum name="GL_INSTRUMENT_BUFFER_POINTER_SGIX"/>
+ <enum name="GL_INSTRUMENT_MEASUREMENTS_SGIX"/>
+ <command name="glGetInstrumentsSGIX"/>
+ <command name="glInstrumentsBufferSGIX"/>
+ <command name="glPollInstrumentsSGIX"/>
+ <command name="glReadInstrumentsSGIX"/>
+ <command name="glStartInstrumentsSGIX"/>
+ <command name="glStopInstrumentsSGIX"/>
+ </require>
+ </extension>
+ <extension name="GL_SGIX_interlace" supported="gl">
+ <require>
+ <enum name="GL_INTERLACE_SGIX"/>
+ </require>
+ </extension>
+ <extension name="GL_SGIX_ir_instrument1" supported="gl">
+ <require>
+ <enum name="GL_IR_INSTRUMENT1_SGIX"/>
+ </require>
+ </extension>
+ <extension name="GL_SGIX_list_priority" supported="gl">
+ <require>
+ <enum name="GL_LIST_PRIORITY_SGIX"/>
+ <command name="glGetListParameterfvSGIX"/>
+ <command name="glGetListParameterivSGIX"/>
+ <command name="glListParameterfSGIX"/>
+ <command name="glListParameterfvSGIX"/>
+ <command name="glListParameteriSGIX"/>
+ <command name="glListParameterivSGIX"/>
+ </require>
+ </extension>
+ <extension name="GL_SGIX_pixel_texture" supported="gl">
+ <require>
+ <enum name="GL_PIXEL_TEX_GEN_SGIX"/>
+ <enum name="GL_PIXEL_TEX_GEN_MODE_SGIX"/>
+ <command name="glPixelTexGenSGIX"/>
+ </require>
+ </extension>
+ <extension name="GL_SGIX_pixel_tiles" supported="gl">
+ <require>
+ <enum name="GL_PIXEL_TILE_BEST_ALIGNMENT_SGIX"/>
+ <enum name="GL_PIXEL_TILE_CACHE_INCREMENT_SGIX"/>
+ <enum name="GL_PIXEL_TILE_WIDTH_SGIX"/>
+ <enum name="GL_PIXEL_TILE_HEIGHT_SGIX"/>
+ <enum name="GL_PIXEL_TILE_GRID_WIDTH_SGIX"/>
+ <enum name="GL_PIXEL_TILE_GRID_HEIGHT_SGIX"/>
+ <enum name="GL_PIXEL_TILE_GRID_DEPTH_SGIX"/>
+ <enum name="GL_PIXEL_TILE_CACHE_SIZE_SGIX"/>
+ </require>
+ </extension>
+ <extension name="GL_SGIX_polynomial_ffd" supported="gl">
+ <require>
+ <enum name="GL_TEXTURE_DEFORMATION_BIT_SGIX"/>
+ <enum name="GL_GEOMETRY_DEFORMATION_BIT_SGIX"/>
+ <enum name="GL_GEOMETRY_DEFORMATION_SGIX"/>
+ <enum name="GL_TEXTURE_DEFORMATION_SGIX"/>
+ <enum name="GL_DEFORMATIONS_MASK_SGIX"/>
+ <enum name="GL_MAX_DEFORMATION_ORDER_SGIX"/>
+ <command name="glDeformationMap3dSGIX"/>
+ <command name="glDeformationMap3fSGIX"/>
+ <command name="glDeformSGIX"/>
+ <command name="glLoadIdentityDeformationMapSGIX"/>
+ </require>
+ </extension>
+ <extension name="GL_SGIX_reference_plane" supported="gl">
+ <require>
+ <enum name="GL_REFERENCE_PLANE_SGIX"/>
+ <enum name="GL_REFERENCE_PLANE_EQUATION_SGIX"/>
+ <command name="glReferencePlaneSGIX"/>
+ </require>
+ </extension>
+ <extension name="GL_SGIX_resample" supported="gl">
+ <require>
+ <enum name="GL_PACK_RESAMPLE_SGIX"/>
+ <enum name="GL_UNPACK_RESAMPLE_SGIX"/>
+ <enum name="GL_RESAMPLE_REPLICATE_SGIX"/>
+ <enum name="GL_RESAMPLE_ZERO_FILL_SGIX"/>
+ <enum name="GL_RESAMPLE_DECIMATE_SGIX"/>
+ </require>
+ </extension>
+ <extension name="GL_SGIX_scalebias_hint" supported="gl">
+ <require>
+ <enum name="GL_SCALEBIAS_HINT_SGIX"/>
+ </require>
+ </extension>
+ <extension name="GL_SGIX_shadow" supported="gl">
+ <require>
+ <enum name="GL_TEXTURE_COMPARE_SGIX"/>
+ <enum name="GL_TEXTURE_COMPARE_OPERATOR_SGIX"/>
+ <enum name="GL_TEXTURE_LEQUAL_R_SGIX"/>
+ <enum name="GL_TEXTURE_GEQUAL_R_SGIX"/>
+ </require>
+ </extension>
+ <extension name="GL_SGIX_shadow_ambient" supported="gl">
+ <require>
+ <enum name="GL_SHADOW_AMBIENT_SGIX"/>
+ </require>
+ </extension>
+ <extension name="GL_SGIX_sprite" supported="gl">
+ <require>
+ <enum name="GL_SPRITE_SGIX"/>
+ <enum name="GL_SPRITE_MODE_SGIX"/>
+ <enum name="GL_SPRITE_AXIS_SGIX"/>
+ <enum name="GL_SPRITE_TRANSLATION_SGIX"/>
+ <enum name="GL_SPRITE_AXIAL_SGIX"/>
+ <enum name="GL_SPRITE_OBJECT_ALIGNED_SGIX"/>
+ <enum name="GL_SPRITE_EYE_ALIGNED_SGIX"/>
+ <command name="glSpriteParameterfSGIX"/>
+ <command name="glSpriteParameterfvSGIX"/>
+ <command name="glSpriteParameteriSGIX"/>
+ <command name="glSpriteParameterivSGIX"/>
+ </require>
+ </extension>
+ <extension name="GL_SGIX_subsample" supported="gl">
+ <require>
+ <enum name="GL_PACK_SUBSAMPLE_RATE_SGIX"/>
+ <enum name="GL_UNPACK_SUBSAMPLE_RATE_SGIX"/>
+ <enum name="GL_PIXEL_SUBSAMPLE_4444_SGIX"/>
+ <enum name="GL_PIXEL_SUBSAMPLE_2424_SGIX"/>
+ <enum name="GL_PIXEL_SUBSAMPLE_4242_SGIX"/>
+ </require>
+ </extension>
+ <extension name="GL_SGIX_tag_sample_buffer" supported="gl">
+ <require>
+ <command name="glTagSampleBufferSGIX"/>
+ </require>
+ </extension>
+ <extension name="GL_SGIX_texture_add_env" supported="gl">
+ <require>
+ <enum name="GL_TEXTURE_ENV_BIAS_SGIX"/>
+ </require>
+ </extension>
+ <extension name="GL_SGIX_texture_coordinate_clamp" supported="gl">
+ <require>
+ <enum name="GL_TEXTURE_MAX_CLAMP_S_SGIX"/>
+ <enum name="GL_TEXTURE_MAX_CLAMP_T_SGIX"/>
+ <enum name="GL_TEXTURE_MAX_CLAMP_R_SGIX"/>
+ </require>
+ </extension>
+ <extension name="GL_SGIX_texture_lod_bias" supported="gl">
+ <require>
+ <enum name="GL_TEXTURE_LOD_BIAS_S_SGIX"/>
+ <enum name="GL_TEXTURE_LOD_BIAS_T_SGIX"/>
+ <enum name="GL_TEXTURE_LOD_BIAS_R_SGIX"/>
+ </require>
+ </extension>
+ <extension name="GL_SGIX_texture_multi_buffer" supported="gl">
+ <require>
+ <enum name="GL_TEXTURE_MULTI_BUFFER_HINT_SGIX"/>
+ </require>
+ </extension>
+ <extension name="GL_SGIX_texture_scale_bias" supported="gl">
+ <require>
+ <enum name="GL_POST_TEXTURE_FILTER_BIAS_SGIX"/>
+ <enum name="GL_POST_TEXTURE_FILTER_SCALE_SGIX"/>
+ <enum name="GL_POST_TEXTURE_FILTER_BIAS_RANGE_SGIX"/>
+ <enum name="GL_POST_TEXTURE_FILTER_SCALE_RANGE_SGIX"/>
+ </require>
+ </extension>
+ <extension name="GL_SGIX_vertex_preclip" supported="gl">
+ <require>
+ <enum name="GL_VERTEX_PRECLIP_SGIX"/>
+ <enum name="GL_VERTEX_PRECLIP_HINT_SGIX"/>
+ </require>
+ </extension>
+ <extension name="GL_SGIX_ycrcb" supported="gl">
+ <require>
+ <enum name="GL_YCRCB_422_SGIX"/>
+ <enum name="GL_YCRCB_444_SGIX"/>
+ </require>
+ </extension>
+ <extension name="GL_SGIX_ycrcb_subsample" supported="gl"/>
+ <extension name="GL_SGIX_ycrcba" supported="gl">
+ <require>
+ <enum name="GL_YCRCB_SGIX"/>
+ <enum name="GL_YCRCBA_SGIX"/>
+ </require>
+ </extension>
+ <extension name="GL_SGI_color_matrix" supported="gl">
+ <require>
+ <enum name="GL_COLOR_MATRIX_SGI"/>
+ <enum name="GL_COLOR_MATRIX_STACK_DEPTH_SGI"/>
+ <enum name="GL_MAX_COLOR_MATRIX_STACK_DEPTH_SGI"/>
+ <enum name="GL_POST_COLOR_MATRIX_RED_SCALE_SGI"/>
+ <enum name="GL_POST_COLOR_MATRIX_GREEN_SCALE_SGI"/>
+ <enum name="GL_POST_COLOR_MATRIX_BLUE_SCALE_SGI"/>
+ <enum name="GL_POST_COLOR_MATRIX_ALPHA_SCALE_SGI"/>
+ <enum name="GL_POST_COLOR_MATRIX_RED_BIAS_SGI"/>
+ <enum name="GL_POST_COLOR_MATRIX_GREEN_BIAS_SGI"/>
+ <enum name="GL_POST_COLOR_MATRIX_BLUE_BIAS_SGI"/>
+ <enum name="GL_POST_COLOR_MATRIX_ALPHA_BIAS_SGI"/>
+ </require>
+ </extension>
+ <extension name="GL_SGI_color_table" supported="gl">
+ <require>
+ <enum name="GL_COLOR_TABLE_SGI"/>
+ <enum name="GL_POST_CONVOLUTION_COLOR_TABLE_SGI"/>
+ <enum name="GL_POST_COLOR_MATRIX_COLOR_TABLE_SGI"/>
+ <enum name="GL_PROXY_COLOR_TABLE_SGI"/>
+ <enum name="GL_PROXY_POST_CONVOLUTION_COLOR_TABLE_SGI"/>
+ <enum name="GL_PROXY_POST_COLOR_MATRIX_COLOR_TABLE_SGI"/>
+ <enum name="GL_COLOR_TABLE_SCALE_SGI"/>
+ <enum name="GL_COLOR_TABLE_BIAS_SGI"/>
+ <enum name="GL_COLOR_TABLE_FORMAT_SGI"/>
+ <enum name="GL_COLOR_TABLE_WIDTH_SGI"/>
+ <enum name="GL_COLOR_TABLE_RED_SIZE_SGI"/>
+ <enum name="GL_COLOR_TABLE_GREEN_SIZE_SGI"/>
+ <enum name="GL_COLOR_TABLE_BLUE_SIZE_SGI"/>
+ <enum name="GL_COLOR_TABLE_ALPHA_SIZE_SGI"/>
+ <enum name="GL_COLOR_TABLE_LUMINANCE_SIZE_SGI"/>
+ <enum name="GL_COLOR_TABLE_INTENSITY_SIZE_SGI"/>
+ <command name="glColorTableSGI"/>
+ <command name="glColorTableParameterfvSGI"/>
+ <command name="glColorTableParameterivSGI"/>
+ <command name="glCopyColorTableSGI"/>
+ <command name="glGetColorTableSGI"/>
+ <command name="glGetColorTableParameterfvSGI"/>
+ <command name="glGetColorTableParameterivSGI"/>
+ </require>
+ </extension>
+ <extension name="GL_SGI_texture_color_table" supported="gl">
+ <require>
+ <enum name="GL_TEXTURE_COLOR_TABLE_SGI"/>
+ <enum name="GL_PROXY_TEXTURE_COLOR_TABLE_SGI"/>
+ </require>
+ </extension>
+ <extension name="GL_SUNX_constant_data" supported="gl">
+ <require>
+ <enum name="GL_UNPACK_CONSTANT_DATA_SUNX"/>
+ <enum name="GL_TEXTURE_CONSTANT_DATA_SUNX"/>
+ <command name="glFinishTextureSUNX"/>
+ </require>
+ </extension>
+ <extension name="GL_SUN_convolution_border_modes" supported="gl">
+ <require>
+ <enum name="GL_WRAP_BORDER_SUN"/>
+ </require>
+ </extension>
+ <extension name="GL_SUN_global_alpha" supported="gl">
+ <require>
+ <enum name="GL_GLOBAL_ALPHA_SUN"/>
+ <enum name="GL_GLOBAL_ALPHA_FACTOR_SUN"/>
+ <command name="glGlobalAlphaFactorbSUN"/>
+ <command name="glGlobalAlphaFactorsSUN"/>
+ <command name="glGlobalAlphaFactoriSUN"/>
+ <command name="glGlobalAlphaFactorfSUN"/>
+ <command name="glGlobalAlphaFactordSUN"/>
+ <command name="glGlobalAlphaFactorubSUN"/>
+ <command name="glGlobalAlphaFactorusSUN"/>
+ <command name="glGlobalAlphaFactoruiSUN"/>
+ </require>
+ </extension>
+ <extension name="GL_SUN_mesh_array" supported="gl">
+ <require>
+ <enum name="GL_QUAD_MESH_SUN"/>
+ <enum name="GL_TRIANGLE_MESH_SUN"/>
+ <command name="glDrawMeshArraysSUN"/>
+ </require>
+ </extension>
+ <extension name="GL_SUN_slice_accum" supported="gl">
+ <require>
+ <enum name="GL_SLICE_ACCUM_SUN"/>
+ </require>
+ </extension>
+ <extension name="GL_SUN_triangle_list" supported="gl">
+ <require>
+ <enum name="GL_RESTART_SUN"/>
+ <enum name="GL_REPLACE_MIDDLE_SUN"/>
+ <enum name="GL_REPLACE_OLDEST_SUN"/>
+ <enum name="GL_TRIANGLE_LIST_SUN"/>
+ <enum name="GL_REPLACEMENT_CODE_SUN"/>
+ <enum name="GL_REPLACEMENT_CODE_ARRAY_SUN"/>
+ <enum name="GL_REPLACEMENT_CODE_ARRAY_TYPE_SUN"/>
+ <enum name="GL_REPLACEMENT_CODE_ARRAY_STRIDE_SUN"/>
+ <enum name="GL_REPLACEMENT_CODE_ARRAY_POINTER_SUN"/>
+ <enum name="GL_R1UI_V3F_SUN"/>
+ <enum name="GL_R1UI_C4UB_V3F_SUN"/>
+ <enum name="GL_R1UI_C3F_V3F_SUN"/>
+ <enum name="GL_R1UI_N3F_V3F_SUN"/>
+ <enum name="GL_R1UI_C4F_N3F_V3F_SUN"/>
+ <enum name="GL_R1UI_T2F_V3F_SUN"/>
+ <enum name="GL_R1UI_T2F_N3F_V3F_SUN"/>
+ <enum name="GL_R1UI_T2F_C4F_N3F_V3F_SUN"/>
+ <command name="glReplacementCodeuiSUN"/>
+ <command name="glReplacementCodeusSUN"/>
+ <command name="glReplacementCodeubSUN"/>
+ <command name="glReplacementCodeuivSUN"/>
+ <command name="glReplacementCodeusvSUN"/>
+ <command name="glReplacementCodeubvSUN"/>
+ <command name="glReplacementCodePointerSUN"/>
+ </require>
+ </extension>
+ <extension name="GL_SUN_vertex" supported="gl">
+ <require>
+ <command name="glColor4ubVertex2fSUN"/>
+ <command name="glColor4ubVertex2fvSUN"/>
+ <command name="glColor4ubVertex3fSUN"/>
+ <command name="glColor4ubVertex3fvSUN"/>
+ <command name="glColor3fVertex3fSUN"/>
+ <command name="glColor3fVertex3fvSUN"/>
+ <command name="glNormal3fVertex3fSUN"/>
+ <command name="glNormal3fVertex3fvSUN"/>
+ <command name="glColor4fNormal3fVertex3fSUN"/>
+ <command name="glColor4fNormal3fVertex3fvSUN"/>
+ <command name="glTexCoord2fVertex3fSUN"/>
+ <command name="glTexCoord2fVertex3fvSUN"/>
+ <command name="glTexCoord4fVertex4fSUN"/>
+ <command name="glTexCoord4fVertex4fvSUN"/>
+ <command name="glTexCoord2fColor4ubVertex3fSUN"/>
+ <command name="glTexCoord2fColor4ubVertex3fvSUN"/>
+ <command name="glTexCoord2fColor3fVertex3fSUN"/>
+ <command name="glTexCoord2fColor3fVertex3fvSUN"/>
+ <command name="glTexCoord2fNormal3fVertex3fSUN"/>
+ <command name="glTexCoord2fNormal3fVertex3fvSUN"/>
+ <command name="glTexCoord2fColor4fNormal3fVertex3fSUN"/>
+ <command name="glTexCoord2fColor4fNormal3fVertex3fvSUN"/>
+ <command name="glTexCoord4fColor4fNormal3fVertex4fSUN"/>
+ <command name="glTexCoord4fColor4fNormal3fVertex4fvSUN"/>
+ <command name="glReplacementCodeuiVertex3fSUN"/>
+ <command name="glReplacementCodeuiVertex3fvSUN"/>
+ <command name="glReplacementCodeuiColor4ubVertex3fSUN"/>
+ <command name="glReplacementCodeuiColor4ubVertex3fvSUN"/>
+ <command name="glReplacementCodeuiColor3fVertex3fSUN"/>
+ <command name="glReplacementCodeuiColor3fVertex3fvSUN"/>
+ <command name="glReplacementCodeuiNormal3fVertex3fSUN"/>
+ <command name="glReplacementCodeuiNormal3fVertex3fvSUN"/>
+ <command name="glReplacementCodeuiColor4fNormal3fVertex3fSUN"/>
+ <command name="glReplacementCodeuiColor4fNormal3fVertex3fvSUN"/>
+ <command name="glReplacementCodeuiTexCoord2fVertex3fSUN"/>
+ <command name="glReplacementCodeuiTexCoord2fVertex3fvSUN"/>
+ <command name="glReplacementCodeuiTexCoord2fNormal3fVertex3fSUN"/>
+ <command name="glReplacementCodeuiTexCoord2fNormal3fVertex3fvSUN"/>
+ <command name="glReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fSUN"/>
+ <command name="glReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fvSUN"/>
+ </require>
+ </extension>
+ <extension name="GL_VIV_shader_binary" supported="gles2">
+ <require>
+ <enum name="GL_SHADER_BINARY_VIV"/>
+ </require>
+ </extension>
+ <extension name="GL_WIN_phong_shading" supported="gl">
+ <require>
+ <enum name="GL_PHONG_WIN"/>
+ <enum name="GL_PHONG_HINT_WIN"/>
+ </require>
+ </extension>
+ <extension name="GL_WIN_specular_fog" supported="gl">
+ <require>
+ <enum name="GL_FOG_SPECULAR_TEXTURE_WIN"/>
+ </require>
+ </extension>
+ </extensions>
+</registry>
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/gengl/main.go b/Godeps/_workspace/src/github.com/obscuren/qml/gl/gengl/main.go
new file mode 100644
index 000000000..e92e861f7
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/gengl/main.go
@@ -0,0 +1,1283 @@
+package main
+
+import (
+ "bufio"
+ "bytes"
+ "encoding/xml"
+ "flag"
+ "fmt"
+ "go/format"
+ "go/token"
+ "io/ioutil"
+ "os"
+ "path/filepath"
+ "regexp"
+ "strconv"
+ "strings"
+ "text/template"
+)
+
+type Header struct {
+ Class string
+ Const []Const
+ Func []Func
+ Type []Type
+
+ FeatureFlags []Const
+
+ GLVersionName string
+ GLVersionLabel string
+}
+
+type Const struct {
+ Name string
+ Value string
+ Heading string
+ Comment string
+ LineBlock int
+ Disabled bool
+
+ GoName string
+}
+
+type Func struct {
+ Name string
+ Type string
+ Addr int
+ Param []Param
+
+ GoName string
+ GoType string
+ DocName string
+
+ Missing bool
+}
+
+type Param struct {
+ Name string
+ Type string
+ Addr int
+ Array int
+ Const bool
+
+ GoName string
+ GoNameOrig string
+ GoType string
+}
+
+type Type struct {
+ Name string
+ Type string
+ Comment string
+
+ GoName string
+}
+
+type glVersion struct {
+ api, number, profile string
+}
+
+var glVersions = []glVersion{
+ {"gl", "1.0", ""},
+ {"gl", "1.1", ""},
+ {"gl", "1.2", ""},
+ {"gl", "1.3", ""},
+ {"gl", "1.4", ""},
+ {"gl", "1.5", ""},
+ {"gl", "2.0", ""},
+ {"gl", "2.1", ""},
+ {"gl", "3.0", ""},
+ {"gl", "3.1", ""},
+ {"gl", "3.2", "core"},
+ {"gl", "3.2", "compatibility"},
+ {"gl", "3.3", "core"},
+ {"gl", "3.3", "compatibility"},
+ {"gl", "4.0", "core"},
+ {"gl", "4.0", "compatibility"},
+ {"gl", "4.1", "core"},
+ {"gl", "4.1", "compatibility"},
+ {"gl", "4.2", "core"},
+ {"gl", "4.2", "compatibility"},
+ {"gl", "4.3", "core"},
+ {"gl", "4.3", "compatibility"},
+ {"gles2", "2.0", ""},
+}
+
+func (v glVersion) name() string {
+ if v.api == "gles2" {
+ return "ES2"
+ }
+ return v.number
+}
+
+func (v glVersion) label() string {
+ if v.api == "gles2" {
+ return "es2"
+ }
+ name := strings.Replace(v.number, ".", "_", -1)
+ if v.profile == "compatibility" {
+ return name + "compat"
+ }
+ return name + v.profile
+}
+
+func (v glVersion) qtheader() string {
+ if v.api == "gles2" {
+ return "qopenglfunctions.h"
+ }
+ s := "qopenglfunctions_" + strings.Replace(v.number, ".", "_", -1)
+ if v.profile != "" {
+ s += "_" + v.profile
+ }
+ return s + ".h"
+}
+
+func main() {
+ flag.Parse()
+ args := flag.Args()
+ if len(args) != 2 {
+ fmt.Fprintf(os.Stderr, "usage: gengl <qt base include path> <output base path>\n")
+ os.Exit(1)
+ }
+ if err := run(args[0], args[1]); err != nil {
+ fmt.Fprintf(os.Stderr, "error: %v\n", err)
+ os.Exit(1)
+ }
+}
+
+func dirnames(path string) ([]string, error) {
+ dir, err := os.Open(path)
+ if err != nil {
+ return nil, err
+ }
+ list, err := dir.Readdirnames(0)
+ dir.Close()
+ return list, err
+}
+
+func parseQtHeader(filename string) (*Header, error) {
+ classData, err := ioutil.ReadFile(filename)
+ if err != nil {
+ return nil, fmt.Errorf("cannot read qt header file: %v", err)
+ }
+ var header Header
+ err = parseQt(string(classData), &header)
+ if err != nil {
+ return nil, err
+ }
+ return &header, nil
+}
+
+func borrowFuncs(header *Header, filename string) error {
+ bheader, err := parseQtHeader(filename)
+ if err != nil {
+ return err
+ }
+
+ seen := make(map[string]bool)
+ for _, f := range header.Func {
+ seen[f.Name] = true
+ }
+ for _, f := range bheader.Func {
+ if !seen[f.Name] {
+ f.Missing = true
+ header.Func = append(header.Func, f)
+ }
+ }
+ return nil
+}
+
+func run(qtdir, outdir string) error {
+ consts, err := parseConsts("gl.xml")
+ if err != nil {
+ return err
+ }
+
+ for _, glVersion := range glVersions {
+ header, err := parseQtHeader(filepath.Join(qtdir, "QtGui", glVersion.qtheader()))
+ if err != nil {
+ return err
+ }
+
+ header.GLVersionLabel = glVersion.label()
+ header.GLVersionName = glVersion.name()
+ header.Const = consts[glVersion]
+
+ if glVersion.api == "gles2" {
+ // Qt < 5.3 misses several ES2 entries in QOpenGLFunctions. As a workaround,
+ // find the missing entries from the pure ES2 class and use them directly.
+ err := borrowFuncs(header, filepath.Join(qtdir, "QtGui", "qopenglfunctions_es2.h"))
+ if err != nil {
+ return err
+ }
+ }
+
+ err = prepareHeader(header)
+ if err != nil {
+ return err
+ }
+
+ fileContent := make(map[string][]byte)
+ for _, pkgFile := range packageFiles {
+ var buf bytes.Buffer
+ err = pkgFile.Template.Execute(&buf, header)
+ if err != nil {
+ return fmt.Errorf("cannot execute template: %v", err)
+ }
+ data := buf.Bytes()
+ if strings.HasSuffix(pkgFile.Name, ".go") {
+ newdata, err := format.Source(data)
+ if err != nil {
+ return fmt.Errorf("\n%s\ncannot format generated Go code: %v\n", data, err)
+ }
+ data = newdata
+ }
+ fileContent[pkgFile.Name] = data
+ }
+
+ glDir := filepath.Join(outdir, strings.Replace(header.GLVersionLabel, "_", ".", -1))
+ err = os.MkdirAll(glDir, 0755)
+ if err != nil {
+ return fmt.Errorf("cannot make package directory at %s: %v", glDir, err)
+ }
+ oldNames, err := dirnames(glDir)
+ if err != nil {
+ return fmt.Errorf("cannot list contents of directory %s: %v", glDir, err)
+ }
+ for _, oldName := range oldNames {
+ oldPath := filepath.Join(glDir, oldName)
+ if err := os.Remove(oldPath); err != nil {
+ return fmt.Errorf("cannot remove previous file in %s: %v", glDir, err)
+ }
+ }
+ for name, data := range fileContent {
+ err = ioutil.WriteFile(filepath.Join(glDir, name), data, 0644)
+ if err != nil {
+ return err
+ }
+ }
+ }
+ return nil
+}
+
+type glRegistry struct {
+ Enums []glEnum `xml:"enums>enum"`
+ Groups []glGroup `xml:"groups>group"`
+ Features []glFeature `xml:"feature"`
+}
+
+type glFeature struct {
+ API string `xml:"api,attr"`
+ Number string `xml:"number,attr"`
+ Requires []glChange `xml:"require"`
+ Removes []glChange `xml:"remove"`
+}
+
+type glChange struct {
+ Profile string `xml:"profile,attr"`
+ Enums []glEnum `xml:"enum"`
+}
+
+type glGroup struct {
+ Name string `xml:"name,attr"`
+ Enums []glEnum `xml:"enum"`
+}
+
+type glEnum struct {
+ API string `xml:"api,attr"`
+ Name string `xml:"name,attr"`
+ Value string `xml:"value,attr"`
+}
+
+type groupTweak struct {
+ group string
+ rename string
+ replace []string
+ append []string
+ reorder bool
+}
+
+var groupTweaks = []groupTweak{{
+ group: "Boolean",
+ reorder: true,
+ append: []string{"GL_NONE"},
+}, {
+ group: "DataType",
+ reorder: true,
+ replace: []string{
+ "GL_BYTE",
+ "GL_UNSIGNED_BYTE",
+ "GL_SHORT",
+ "GL_UNSIGNED_SHORT",
+ "GL_INT",
+ "GL_UNSIGNED_INT",
+ "GL_FLOAT",
+ "GL_2_BYTES",
+ "GL_2_BYTES_NV",
+ "GL_3_BYTES",
+ "GL_3_BYTES_NV",
+ "GL_4_BYTES",
+ "GL_4_BYTES_NV",
+ "GL_DOUBLE",
+ "GL_DOUBLE_EXT",
+ "GL_HALF_FLOAT",
+ "GL_HALF_FLOAT_ARB",
+ "GL_HALF_FLOAT_NV",
+ "GL_HALF_APPLE",
+ "GL_FIXED",
+ "GL_FIXED_OES",
+ "GL_INT64_NV",
+ "GL_UNSIGNED_INT64_ARB",
+ "GL_UNSIGNED_INT64_NV",
+ },
+}, {
+ group: "BlendingFactorSrc",
+ replace: []string{
+ "GL_CONSTANT_ALPHA_EXT",
+ "GL_CONSTANT_COLOR_EXT",
+ "GL_DST_ALPHA",
+ "GL_DST_COLOR",
+ "GL_ONE",
+ "GL_ONE_MINUS_DST_ALPHA",
+ "GL_ONE_MINUS_DST_COLOR",
+ "GL_ONE_MINUS_SRC_ALPHA",
+ "GL_ONE_MINUS_SRC_COLOR",
+ "GL_SRC_ALPHA",
+ "GL_SRC_COLOR",
+ "GL_SRC_ALPHA_SATURATE",
+ "GL_ZERO",
+ },
+}, {
+ group: "AttribMask",
+ append: []string{
+ "GL_COVERAGE_BUFFER_BIT_NV",
+ },
+}}
+
+func tweakGroups(groups []glGroup) {
+ tweaks := make(map[string]groupTweak)
+ reorder := make(map[string]int)
+ top := 0
+ for _, tweak := range groupTweaks {
+ tweaks[tweak.group] = tweak
+ if tweak.reorder {
+ reorder[tweak.group] = top
+ top++
+ }
+ }
+
+ // Take reordered groups out, leaving space at the start.
+ stash := make([]glGroup, top)
+ for i, group := range groups {
+ newi, ok := reorder[group.Name]
+ if !ok {
+ continue
+ }
+ stash[newi] = group
+ copy(groups[1:i+1], groups[0:i])
+ }
+ // Put reordered groups back, in the proper order.
+ copy(groups, stash)
+
+ for i, group := range groups {
+ tweak, ok := tweaks[group.Name]
+ if !ok {
+ continue
+ }
+ if tweak.rename != "" {
+ group.Name = tweak.rename
+ }
+ if tweak.replace != nil {
+ group.Enums = group.Enums[:0]
+ for _, name := range tweak.replace {
+ group.Enums = append(group.Enums, glEnum{Name: name})
+ }
+ }
+ if tweak.append != nil {
+ for _, name := range tweak.append {
+ group.Enums = append(group.Enums, glEnum{Name: name})
+ }
+ }
+ groups[i] = group
+ }
+}
+
+func parseConsts(filename string) (map[glVersion][]Const, error) {
+ f, err := os.Open(filename)
+ if err != nil {
+ return nil, fmt.Errorf("cannot open %s: %v", filename, err)
+ }
+ defer f.Close()
+
+ var registry glRegistry
+ err = xml.NewDecoder(f).Decode(&registry)
+ if err != nil {
+ return nil, fmt.Errorf("cannot parse %s: %v", filename, err)
+ }
+
+ var all = make(map[glVersion]map[string]bool)
+ var last = make(map[string]map[string]bool)
+ for _, feature := range registry.Features {
+ for _, profile := range []string{"", "core", "compatibility"} {
+ required := make(map[string]bool)
+ for name := range last[feature.API+":"+profile] {
+ required[name] = true
+ }
+ if profile != "" {
+ for name := range last[feature.API+":"] {
+ required[name] = true
+ }
+ }
+
+ for _, require := range feature.Requires {
+ if require.Profile == profile || require.Profile == "" {
+ for _, enum := range require.Enums {
+ required[enum.Name] = true
+ }
+ }
+ }
+ for _, remove := range feature.Removes {
+ if remove.Profile == profile || remove.Profile == "" {
+ for _, enum := range remove.Enums {
+ delete(required, enum.Name)
+ }
+ }
+ }
+
+ all[glVersion{feature.API, feature.Number, profile}] = required
+ last[feature.API+":"+profile] = required
+ }
+ }
+
+ // Enums in groups and requires/removes have no values.
+ enums := make(map[string]glEnum)
+ for _, enum := range registry.Enums {
+ enums[enum.Name] = enum
+ }
+
+ tweakGroups(registry.Groups)
+
+ consts := make(map[glVersion][]Const)
+ for _, glVersion := range glVersions {
+ var required = all[glVersion]
+ var done = make(map[string]bool)
+ var lineblock = 0
+ var vconsts []Const
+ for _, group := range registry.Groups {
+ for _, enum := range group.Enums {
+ if required[enum.Name] && !done[enum.Name] {
+ done[enum.Name] = true
+ c := Const{
+ Name: enum.Name,
+ Value: enums[enum.Name].Value,
+ LineBlock: lineblock,
+ }
+ vconsts = append(vconsts, c)
+ }
+ }
+ lineblock++
+ }
+ // Everything else not found in groups.
+ for _, enum := range registry.Enums {
+ if required[enum.Name] && !done[enum.Name] {
+ done[enum.Name] = true
+ c := Const{
+ Name: enum.Name,
+ Value: enum.Value,
+ LineBlock: lineblock,
+ }
+ vconsts = append(vconsts, c)
+ }
+ }
+ consts[glVersion] = vconsts
+ }
+ // Version 1.0 has no enums. Copy from 1.1.
+ consts[glVersion{"gl", "1.0", ""}] = consts[glVersion{"gl", "1.1", ""}]
+ return consts, nil
+}
+
+func prepareHeader(header *Header) error {
+ funcNameDocCount := make(map[string]int)
+
+ for fi, f := range header.Func {
+ docPrefix := funcNameDocPrefix(f.Name)
+ if docPrefix != f.Name {
+ funcNameDocCount[docPrefix]++
+ }
+ if !strings.HasPrefix(f.Name, "gl") || len(f.Name) < 3 {
+ panic("unexpected C function name: " + f.Name)
+ }
+ f.GoName = f.Name[2:]
+ if f.Type == "int" {
+ // Some consistency. It's in a gl* function after all.
+ f.Type = "GLint"
+ }
+ if f.Type != "void" {
+ f.GoType = goTypeName(f.Type)
+ }
+ tweaks := funcTweaks[f.GoName]
+ if tweaks.result != "" {
+ f.GoType = tweaks.result
+ }
+ for pi := range f.Param {
+ f.Param[pi] = prepareParam(f, pi)
+ }
+ header.Func[fi] = f
+ }
+
+ for fi, f := range header.Func {
+ prefix := funcNameDocPrefix(f.Name)
+ if funcNameDocCount[prefix] > 1 {
+ f.DocName = prefix
+ } else {
+ f.DocName = f.Name
+ }
+ header.Func[fi] = f
+ }
+
+ for ti, t := range header.Type {
+ t.GoName = goTypeName(t.Name)
+ header.Type[ti] = t
+ }
+
+ for ci, c := range header.Const {
+ if !strings.HasPrefix(c.Name, "GL") || len(c.Name) < 3 {
+ panic("unexpected C define name: " + c.Name)
+ }
+ if c.Name[3] >= '0' && c.Name[3] <= '9' {
+ c.GoName = "N" + c.Name[3:]
+ } else {
+ c.GoName = c.Name[3:]
+ }
+ header.Const[ci] = c
+ }
+
+ return nil
+}
+
+func goTypeName(ctypeName string) string {
+ // These types carry very little meaning, so it's more
+ // convenient to have their native counterparts instead.
+ switch ctypeName {
+ case "GLboolean":
+ return "bool"
+ case "GLbyte", "GLchar":
+ return "byte"
+ case "GLubyte":
+ return "uint8"
+ case "GLshort":
+ return "int16"
+ case "GLushort":
+ return "uint16"
+ case "GLint", "GLsizei":
+ return "int32"
+ case "GLuint":
+ return "uint32"
+ case "GLint64":
+ return "int64"
+ case "GLuint64":
+ return "uint64"
+ case "GLintptr", "GLsizeiptr":
+ return "int"
+ case "GLuintptr":
+ return "uintptr"
+ case "GLfloat":
+ return "float32"
+ case "GLdouble":
+ return "float64"
+ }
+ if !strings.HasPrefix(ctypeName, "GL") || len(ctypeName) < 3 {
+ panic("unexpected C type name: " + ctypeName)
+ }
+ return "glbase." + string(ctypeName[2]-('a'-'A')) + ctypeName[3:]
+}
+
+func prepareParam(f Func, pi int) Param {
+ p := f.Param[pi]
+
+ // Qt seems to have gratuitously changed some names.
+ if name, ok := paramNameFixes[p.Name]; ok {
+ p.Name = name
+ }
+ if pi > 0 && strings.HasPrefix(f.GoName, "Uniform") && p.Name != "count" && p.Name != "transpose" {
+ if strings.HasSuffix(f.GoName, "v") {
+ p.Name = "value"
+ } else if f.Param[1].Name == "count" {
+ p.Name = "v" + string('0' + pi-2)
+ } else {
+ p.Name = "v" + string('0' + pi-1)
+ }
+ }
+
+ // Other names conflict with Go keywords.
+ switch p.Name {
+ case "type", "func", "map", "string":
+ p.GoName = "gl" + p.Name
+ default:
+ if token.Lookup(p.Name) != token.IDENT {
+ p.GoName = p.Name + "_"
+ } else {
+ p.GoName = p.Name
+ }
+ }
+
+ // Some consistency. Those are a gl* function after all.
+ switch p.Type {
+ case "void":
+ p.Type = "GLvoid"
+ case "char":
+ p.Type = "GLchar"
+ case "qopengl_GLsizeiptr", "qopengl_GLintptr":
+ p.Type = p.Type[8:]
+ }
+
+ // Prepare the parameter type.
+ p.GoType = goTypeName(p.Type)
+ switch p.GoType {
+ case "uint32":
+ switch p.GoName {
+ case "program", "programs":
+ p.GoType = "glbase.Program"
+ case "shader", "shaders":
+ p.GoType = "glbase.Shader"
+ case "buffer", "buffers":
+ p.GoType = "glbase.Buffer"
+ case "texture", "textures":
+ p.GoType = "glbase.Texture"
+ case "framebuffer", "framebuffers":
+ p.GoType = "glbase.Framebuffer"
+ case "renderbuffer", "renderbuffers":
+ p.GoType = "glbase.Renderbuffer"
+ case "index":
+ if strings.Contains(f.Name, "Attrib") {
+ p.GoType = "glbase.Attrib"
+ }
+ }
+ case "int32":
+ switch p.GoName {
+ case "size", "count", "stride", "offset", "xoffset", "yoffset", "order", "level":
+ p.GoType = "int"
+ case "n", "first", "width", "height", "border", "imageSize":
+ p.GoType = "int"
+ case "x", "y", "z", "w":
+ if !strings.HasPrefix(f.GoName, "Uniform") {
+ p.GoType = "int"
+ }
+ case "location":
+ if strings.Contains(f.Name, "Uniform") {
+ p.GoType = "glbase.Uniform"
+ }
+ }
+ }
+
+ // Save the original name so that future tweaks can still refer
+ // to it, and apply the tweaks.
+ p.GoNameOrig = p.GoName
+ tweak := funcTweaks[f.GoName].params[p.GoNameOrig]
+ if tweak.retype != "" {
+ p.GoType = tweak.retype
+ }
+ if tweak.rename != "" {
+ p.GoName = tweak.rename
+ }
+
+ return p
+}
+
+func funcNameDocPrefix(cfuncName string) string {
+ k := len(cfuncName) - 1
+ if cfuncName[k] == 'v' {
+ k--
+ }
+ switch cfuncName[k] {
+ case 'i', 'f', 'd', 's', 'b':
+ k--
+ if cfuncName[k] == 'u' {
+ k--
+ }
+ switch cfuncName[k] {
+ case '1', '2', '3', '4':
+ k--
+ }
+ }
+ return cfuncName[:k+1]
+}
+
+var constLineBlock = -1
+
+func constNewLine(lineBlock int) bool {
+ if lineBlock == constLineBlock {
+ return false
+ }
+ constLineBlock = lineBlock
+ return true
+}
+
+func substr(s string, i ...int) string {
+ switch len(i) {
+ case 1:
+ return s[i[0]:]
+ case 2:
+ return s[i[0]:i[1]]
+ }
+ panic("invalid number of arguments for substr")
+}
+
+var funcTweaks = make(map[string]funcTweak)
+
+func init() {
+ var re = regexp.MustCompile(`\bcopy:([a-zA-Z0-9]+)\b`)
+ for _, tweak := range funcTweakList {
+ funcTweaks[tweak.name] = tweak
+ }
+ for _, tweak := range funcTweakList {
+ if tweak.copy != "" {
+ doc := tweak.doc
+ name := tweak.name
+ tweak = funcTweaks[tweak.copy]
+ tweak.name = name
+ if doc != "" {
+ tweak.doc = doc
+ }
+ }
+ tweak.doc = re.ReplaceAllStringFunc(tweak.doc, func(match string) string {
+ return funcTweaks[match[5:]].doc
+ })
+ funcTweaks[tweak.name] = tweak
+ }
+}
+
+func funcComment(header *Header, f Func) string {
+ var doc = funcTweaks[f.GoName].doc
+ doc = strings.TrimRight(execTemplate(f.GoName+":doc", doc, f), "\n\t ")
+ var buf bytes.Buffer
+ if doc != "" {
+ var scanner = bufio.NewScanner(bytes.NewBufferString(doc))
+ var started bool
+ var prefix string
+ for scanner.Scan() {
+ line := scanner.Text()
+ if !started {
+ if line == "" {
+ continue
+ }
+ started = true
+ trimmed := strings.TrimLeft(line, "\t ")
+ prefix = line[:len(line)-len(trimmed)]
+ line = f.GoName + " " + trimmed
+ } else {
+ line = strings.TrimPrefix(line, prefix)
+ }
+ buf.WriteString("// ")
+ buf.WriteString(line)
+ buf.WriteByte('\n')
+ }
+ }
+ if buf.Len() > 0 {
+ return strings.TrimSuffix(buf.String(), "\n")
+ }
+ var manNum = 2
+ if header.GLVersionName[0] >= '2' && header.GLVersionName[0] <= '4' {
+ manNum = int(header.GLVersionName[0] - '0')
+ }
+ return fmt.Sprintf("// https://www.opengl.org/sdk/docs/man%d/xhtml/%s.xml", manNum, f.Name)
+}
+
+type paramItem struct {
+ GoName string
+ GoType string
+}
+
+func appendResultList(list []paramItem, f Func) []paramItem {
+ var tweaks = funcTweaks[f.GoName]
+ var buf bytes.Buffer
+ tweak := tweaks.params["result"]
+ if f.GoType != "" && !tweak.omit {
+ var item paramItem
+ if tweak.rename != "" {
+ item.GoName = tweak.rename
+ } else {
+ item.GoName = "result"
+ }
+ if tweak.retype != "" {
+ item.GoType = tweak.retype
+ } else {
+ for i := 0; i < f.Addr; i++ {
+ buf.WriteString("[]")
+ }
+ buf.WriteString(f.GoType)
+ item.GoType = buf.String()
+ }
+ list = append(list, item)
+ }
+ return list
+}
+
+func appendParamsList(list []paramItem, f Func, output bool) []paramItem {
+ var tweaks = funcTweaks[f.GoName]
+ var buf bytes.Buffer
+ for _, param := range f.Param {
+ tweak := tweaks.params[param.GoNameOrig]
+ if tweak.omit || tweak.output != output {
+ continue
+ }
+ item := paramItem{GoName: param.GoName}
+ if tweak.retype != "" {
+ item.GoType = param.GoType
+ } else if param.Addr == 1 && param.Type == "GLvoid" {
+ item.GoType = "interface{}"
+ } else if tweak.single {
+ item.GoType = param.GoType
+ } else {
+ buf.Truncate(0)
+ for j := 0; j < param.Addr; j++ {
+ buf.WriteString("[]")
+ }
+ if param.Array > 0 {
+ buf.WriteByte('[')
+ buf.WriteString(strconv.Itoa(param.Array))
+ buf.WriteByte(']')
+ }
+ buf.WriteString(param.GoType)
+ item.GoType = buf.String()
+ }
+ list = append(list, item)
+ }
+ return list
+}
+
+func formatParamsList(list []paramItem) string {
+ var buf bytes.Buffer
+ for i, item := range list {
+ if i > 0 {
+ buf.WriteString(", ")
+ }
+ buf.WriteString(item.GoName)
+ if i == len(list)-1 || item.GoType != list[i+1].GoType {
+ buf.WriteByte(' ')
+ buf.WriteString(item.GoType)
+ }
+ }
+ return buf.String()
+}
+
+func funcParams(f Func) string {
+ list := appendParamsList(nil, f, false)
+ return formatParamsList(list)
+}
+
+func funcResult(f Func) string {
+ list := appendResultList(nil, f)
+ list = appendParamsList(list, f, true)
+ if len(list) == 0 {
+ return ""
+ }
+ if len(list) == 1 && (list[0].GoName == "result" || funcTweaks[f.GoName].params[list[0].GoName].unnamed) {
+ return list[0].GoType
+ }
+ return "(" + formatParamsList(list) + ")"
+}
+
+func funcBefore(f Func) string {
+ content := funcTweaks[f.GoName].before
+ return strings.TrimSpace(execTemplate(f.GoName+":before", content, f))
+}
+
+func funcAfter(f Func) string {
+ content := funcTweaks[f.GoName].after
+ return strings.TrimSpace(execTemplate(f.GoName+":after", content, f))
+}
+
+func funcCallParams(f Func) string {
+ tweaks := funcTweaks[f.GoName]
+ var buf bytes.Buffer
+ for i, param := range f.Param {
+ if i > 0 {
+ buf.WriteString(", ")
+ }
+ tweak := tweaks.params[param.GoNameOrig]
+ name := param.GoName
+ if tweak.replace {
+ name += "_c"
+ }
+ if param.Addr == 1 && param.Type == "GLvoid" {
+ buf.WriteString(name)
+ buf.WriteString("_ptr")
+ } else if param.Addr == 1 && param.Type == "GLchar" && param.GoType == "string" {
+ buf.WriteString("(*C.GLchar)(")
+ buf.WriteString(name)
+ buf.WriteString("_cstr)")
+ } else if param.Addr > 0 {
+ buf.WriteByte('(')
+ for i := 0; i < param.Addr; i++ {
+ buf.WriteByte('*')
+ }
+ buf.WriteString("C.")
+ buf.WriteString(param.Type)
+ buf.WriteString(")(unsafe.Pointer(&")
+ buf.WriteString(name)
+ if !tweak.single {
+ buf.WriteString("[0]")
+ }
+ buf.WriteString("))")
+
+ } else if param.Type == "GLboolean" {
+ buf.WriteString("*(*C.GLboolean)(unsafe.Pointer(&")
+ buf.WriteString(name)
+ buf.WriteString("))")
+ } else if param.Type == "GLsync" {
+ buf.WriteString("C.GLsync(unsafe.Pointer(")
+ buf.WriteString(name)
+ buf.WriteString("))")
+ } else {
+ buf.WriteString("C.")
+ buf.WriteString(param.Type)
+ buf.WriteByte('(')
+ buf.WriteString(name)
+ buf.WriteByte(')')
+ }
+ }
+ return buf.String()
+}
+
+func funcCallParamsPrep(f Func) string {
+ var buf bytes.Buffer
+ for _, param := range f.Param {
+ name := param.GoName
+ if param.Addr == 1 && param.Type == "GLchar" && param.GoType == "string" {
+ fmt.Fprintf(&buf, "%s_cstr := C.CString(%s)\n", name, name)
+ }
+ if param.Addr == 1 && param.Type == "GLvoid" && param.GoType == "glbase.Void" {
+ fmt.Fprintf(&buf, "var %s_ptr unsafe.Pointer\n", name)
+ fmt.Fprintf(&buf, "var %s_v = reflect.ValueOf(%s)\n", name, name)
+ fmt.Fprintf(&buf, "if %s != nil && %s_v.Kind() != reflect.Slice { panic(\"parameter %s must be a slice\") }\n", name, name, name)
+ fmt.Fprintf(&buf, "if %s != nil { %s_ptr = unsafe.Pointer(%s_v.Index(0).Addr().Pointer()) }\n", name, name, name)
+ }
+ if plen := funcParamLen(f, param); plen > 0 {
+ fmt.Fprintf(&buf, "if len(%s) != %d { panic(\"parameter %s has incorrect length\") }\n", name, plen, name)
+ }
+ }
+ return buf.String()
+}
+
+func funcCallParamsPost(f Func) string {
+ var buf bytes.Buffer
+ for _, param := range f.Param {
+ if param.Addr == 1 && param.Type == "GLchar" && param.GoType == "string" {
+ buf.WriteString("C.free(unsafe.Pointer(")
+ buf.WriteString(param.GoName)
+ buf.WriteString("_cstr))\n")
+ }
+ }
+ return buf.String()
+}
+
+func funcReturnResult(f Func) string {
+ tweaks := funcTweaks[f.GoName]
+ var buf bytes.Buffer
+ if f.GoType != "" {
+ if f.Type == "GLboolean" {
+ buf.WriteString("*(*bool)(unsafe.Pointer(&glresult))")
+ } else if f.Type == "GLsync" {
+ buf.WriteString("glbase.Sync(unsafe.Pointer(glresult))")
+ } else {
+ buf.WriteString(f.GoType)
+ buf.WriteString("(glresult)")
+ }
+ }
+ for _, param := range f.Param {
+ tweak := tweaks.params[param.GoNameOrig]
+ if tweak.omit || !tweak.output {
+ continue
+ }
+ if buf.Len() > 0 {
+ buf.WriteString(", ")
+ }
+ buf.WriteString(param.GoName)
+ }
+ return buf.String()
+}
+
+func funcCParams(f Func) string {
+ var buf bytes.Buffer
+ for i, param := range f.Param {
+ if i > 0 {
+ buf.WriteString(", ")
+ }
+ if param.Const {
+ buf.WriteString("const ")
+ }
+ buf.WriteString(param.Type)
+ for j := 0; j < param.Addr; j++ {
+ buf.WriteString("*")
+ }
+ if param.Array > 0 {
+ buf.WriteByte('[')
+ buf.WriteString(strconv.Itoa(param.Array))
+ buf.WriteByte(']')
+ }
+ buf.WriteByte(' ')
+ buf.WriteString(param.GoName)
+ }
+ return buf.String()
+}
+
+func funcCCallParams(f Func) string {
+ var buf bytes.Buffer
+ for i, param := range f.Param {
+ if i > 0 {
+ buf.WriteString(", ")
+ }
+ buf.WriteString(param.GoName)
+ }
+ return buf.String()
+}
+
+func funcParamLen(f Func, param Param) int {
+ if strings.HasPrefix(f.GoName, "Uniform") {
+ return 0
+ }
+ if param.Addr == 0 || len(f.Name) < 3 || f.Name[len(f.Name)-1] != 'v' {
+ return 0
+ }
+ switch f.Name[len(f.Name)-2] {
+ case 'i', 'f', 'd', 's':
+ switch c := f.Name[len(f.Name)-3]; c {
+ case '2', '3', '4':
+ return int(c - '0')
+ }
+ }
+ return 0
+}
+
+// funcSupported returns whether the given function has wrapping
+// properly implemented already.
+func funcSupported(f Func) bool {
+ if _, ok := funcTweaks[f.GoName]; ok {
+ return true
+ }
+ if f.Addr > 0 {
+ return false
+ }
+ for _, param := range f.Param {
+ if param.Array > 0 {
+ return false
+ }
+ if param.Addr > 1 {
+ return false
+ }
+ }
+ return true
+}
+
+func copyDoc(name string) string {
+ return funcTweaks[name].doc
+}
+
+func paramGoType(f Func, name string) string {
+ for _, param := range f.Param {
+ if param.GoName == name {
+ return param.GoType
+ }
+ }
+ panic(fmt.Sprintf("parameter %q not found in function %s", name, f.GoName))
+}
+
+func funcSince(f Func, since string) string {
+ if strings.HasSuffix(since, "+") {
+ return f.GoName + " is available in GL version " + since[:len(since)-1] + " or greater."
+ }
+ return f.GoName + " is available in GL version " + since + "."
+}
+
+func execTemplate(name, content string, dot interface{}) string {
+ if !strings.Contains(content, "{{") {
+ return content
+ }
+ var buf bytes.Buffer
+ tmpl := template.Must(template.New(name).Funcs(funcs).Parse(content))
+ if err := tmpl.Execute(&buf, dot); err != nil {
+ panic(err)
+ }
+ return buf.String()
+}
+
+func buildTemplate(name, content string) *template.Template {
+ return template.Must(template.New(name).Funcs(funcs).Parse(content))
+}
+
+var funcs template.FuncMap
+
+type packageFile struct {
+ Name string
+ Template *template.Template
+}
+
+var packageFiles []packageFile
+
+func init() {
+ funcs = template.FuncMap{
+ "copyDoc": copyDoc,
+ "paramGoType": paramGoType,
+ "funcSince": funcSince,
+
+ "constNewLine": constNewLine,
+ "lower": strings.ToLower,
+ "substr": substr,
+
+ "funcSupported": funcSupported,
+ "funcComment": funcComment,
+ "funcParams": funcParams,
+ "funcResult": funcResult,
+ "funcBefore": funcBefore,
+ "funcCallParams": funcCallParams,
+ "funcCallParamsPrep": funcCallParamsPrep,
+ "funcCallParamsPost": funcCallParamsPost,
+ "funcAfter": funcAfter,
+ "funcReturnResult": funcReturnResult,
+ "funcCParams": funcCParams,
+ "funcCCallParams": funcCCallParams,
+ }
+
+ packageFiles = []packageFile{
+ {"gl.go", buildTemplate("gl.go", tmplGo)},
+ {"funcs.cpp", buildTemplate("funcs.cpp", tmplFuncsCpp)},
+ {"funcs.h", buildTemplate("funcs.h", tmplFuncsH)},
+ }
+}
+
+var tmplGo = `
+// ** file automatically generated by glgen -- do not edit manually **
+
+package GL
+
+// #cgo CXXFLAGS: -std=c++0x -pedantic-errors -Wall -fno-strict-aliasing
+// #cgo LDFLAGS: -lstdc++
+{{if eq $.GLVersionName "ES2"}}// #cgo !darwin LDFLAGS: -lGL
+// #cgo darwin LDFLAGS: -framework OpenGL
+{{end}}// #cgo pkg-config: Qt5Core Qt5OpenGL
+//
+// #include "funcs.h"
+//
+// void free(void*);
+//
+import "C"
+
+import (
+ "fmt"
+ "reflect"
+ "unsafe"
+
+ "gopkg.in/qml.v1/gl/glbase"
+)
+
+// API returns a value that offers methods matching the OpenGL version {{$.GLVersionName}} API.
+//
+// The returned API must not be used after the provided OpenGL context becomes invalid.
+func API(context glbase.Contexter) *GL {
+ gl := &GL{}
+ gl.funcs = C.gl{{$.GLVersionLabel}}_funcs()
+ if gl.funcs == nil {
+ panic(fmt.Errorf("OpenGL version {{$.GLVersionName}} is not available"))
+ }
+ return gl
+}
+
+// GL implements the OpenGL version {{$.GLVersionName}} API. Values of this
+// type must be created via the API function, and it must not be used after
+// the associated OpenGL context becomes invalid.
+type GL struct {
+ funcs unsafe.Pointer
+}
+
+const ({{range $const := $.Const}}{{if $const.LineBlock | constNewLine}}
+{{end}}{{if $const.Heading}} // {{$const.Heading}}
+{{end}} {{if $const.Disabled}}//{{end}}{{$const.GoName}} = {{$const.Value}}{{if $const.Comment}} // {{$const.Comment}}{{end}}
+{{end}})
+
+{{ range $func := $.Func }}{{if $func | funcSupported}}
+{{funcComment $ $func}}
+func (gl *GL) {{$func.GoName}}({{funcParams $func}}) {{funcResult $func}} {
+ {{funcCallParamsPrep $func}} {{/*
+*/}} {{with $code := funcBefore $func}}{{$code}}
+ {{end}} {{/*
+*/}} {{if ne $func.Type "void"}}glresult := {{end}}C.gl{{$.GLVersionLabel}}_{{$func.Name}}(gl.funcs{{if $func.Param}}, {{funcCallParams $func}}{{end}})
+ {{with $code := funcAfter $func}}{{$code}}
+ {{end}} {{/*
+*/}} {{funcCallParamsPost $func}} {{/*
+*/}} {{with $code := funcReturnResult $func}}return {{$code}}
+ {{end}} {{/*
+*/}} }
+{{end}}{{end}}
+`
+
+var tmplFuncsCpp = `
+// ** file automatically generated by glgen -- do not edit manually **
+
+#include <QOpenGLContext>
+#include <QtGui/{{lower $.Class}}.h>
+
+#include "funcs.h"
+
+void *gl{{$.GLVersionLabel}}_funcs() {
+ {{$.Class}}* funcs = QOpenGLContext::currentContext()->{{if eq $.Class "QOpenGLFunctions"}}functions{{else}}versionFunctions<{{$.Class}}>{{end}}();
+ if (!funcs) {
+ return 0;
+ }{{if ne $.Class "QOpenGLFunctions"}}
+ funcs->initializeOpenGLFunctions();{{end}}
+ return funcs;
+}
+
+{{ range $func := $.Func }}{{if $func | funcSupported}}
+{{$func.Type}} gl{{$.GLVersionLabel}}_{{$func.Name}}(void *_glfuncs{{if $func.Param}}, {{funcCParams $func}}{{end}})
+{
+ {{if not $func.Missing}}{{$.Class}}* _qglfuncs = reinterpret_cast<{{$.Class}}*>(_glfuncs);
+ {{end}}{{if $func.GoType}}return {{end}}{{if not $func.Missing}}_qglfuncs->{{end}}{{$func.Name}}({{funcCCallParams $func}});
+}
+{{end}}{{end}}
+`
+
+var tmplFuncsH = `
+// ** file automatically generated by glgen -- do not edit manually **
+
+#ifndef __cplusplus
+#include <inttypes.h>
+#include <stddef.h>
+typedef unsigned int GLenum;
+typedef unsigned char GLboolean;
+typedef unsigned int GLbitfield;
+typedef void GLvoid;
+typedef char GLchar;
+typedef signed char GLbyte; /* 1-byte signed */
+typedef short GLshort; /* 2-byte signed */
+typedef int GLint; /* 4-byte signed */
+typedef unsigned char GLubyte; /* 1-byte unsigned */
+typedef unsigned short GLushort; /* 2-byte unsigned */
+typedef unsigned int GLuint; /* 4-byte unsigned */
+typedef int GLsizei; /* 4-byte signed */
+typedef float GLfloat; /* single precision float */
+typedef float GLclampf; /* single precision float in [0,1] */
+typedef double GLdouble; /* double precision float */
+typedef double GLclampd; /* double precision float in [0,1] */
+typedef int64_t GLint64;
+typedef uint64_t GLuint64;
+typedef ptrdiff_t GLintptr;
+typedef ptrdiff_t GLsizeiptr;
+typedef ptrdiff_t GLintptrARB;
+typedef ptrdiff_t GLsizeiptrARB;
+typedef struct __GLsync *GLsync;
+#endif
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+void *gl{{$.GLVersionLabel}}_funcs();
+
+{{ range $func := $.Func }}{{if $func | funcSupported}}{{$func.Type}} gl{{$.GLVersionLabel}}_{{$func.Name}}(void *_glfuncs{{if $func.Param}}, {{funcCParams $func}}{{end}});
+{{end}}{{end}}
+
+#ifdef __cplusplus
+} // extern "C"
+#endif
+`
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/gengl/parseqt.go b/Godeps/_workspace/src/github.com/obscuren/qml/gl/gengl/parseqt.go
new file mode 100644
index 000000000..a4a882dd9
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/gengl/parseqt.go
@@ -0,0 +1,13904 @@
+
+// line 1 "parseqt.rl"
+//
+// To compile:
+//
+// ragel -Z -G2 -o parseqt.go parseqt.rl
+//
+// To show a diagram of the state machine:
+//
+// ragel -V -G2 -p -o parseqt.dot parseqt.rl
+// dot -Tsvg -o parseqt.svg parseqt.dot
+// chrome parseqt.svg
+//
+
+package main
+
+import (
+ "fmt"
+)
+
+
+// line 23 "parseqt.go"
+const parseqt_start int = 447
+const parseqt_first_final int = 447
+const parseqt_error int = 0
+
+const parseqt_en_main int = 447
+const parseqt_en_inclass int = 450
+const parseqt_en_skiperror int = 446
+
+
+// line 23 "parseqt.rl"
+
+
+func parseQt(data string, header *Header) error {
+ var cs, p, pe int
+ var ts, te, act, eof int
+
+ pe = len(data)
+ eof = len(data)
+
+ _, _, _ = ts, te, act
+
+ //stack := make([]int, 32)
+ //top := 0
+
+ var curline = 1
+
+ var m0, m1, m2, m3, m4, m5, m6 int
+ var foundclass int
+ var inpublic bool
+ var heading string
+ var lineblock int
+ var f Func
+
+
+// line 58 "parseqt.go"
+ {
+ cs = parseqt_start
+ ts = 0
+ te = 0
+ act = 0
+ }
+
+// line 66 "parseqt.go"
+ {
+ if p == pe {
+ goto _test_eof
+ }
+ switch cs {
+ case 447:
+ goto st_case_447
+ case 1:
+ goto st_case_1
+ case 2:
+ goto st_case_2
+ case 3:
+ goto st_case_3
+ case 4:
+ goto st_case_4
+ case 5:
+ goto st_case_5
+ case 6:
+ goto st_case_6
+ case 7:
+ goto st_case_7
+ case 8:
+ goto st_case_8
+ case 9:
+ goto st_case_9
+ case 10:
+ goto st_case_10
+ case 11:
+ goto st_case_11
+ case 12:
+ goto st_case_12
+ case 13:
+ goto st_case_13
+ case 14:
+ goto st_case_14
+ case 15:
+ goto st_case_15
+ case 16:
+ goto st_case_16
+ case 17:
+ goto st_case_17
+ case 18:
+ goto st_case_18
+ case 19:
+ goto st_case_19
+ case 20:
+ goto st_case_20
+ case 21:
+ goto st_case_21
+ case 448:
+ goto st_case_448
+ case 22:
+ goto st_case_22
+ case 23:
+ goto st_case_23
+ case 24:
+ goto st_case_24
+ case 25:
+ goto st_case_25
+ case 26:
+ goto st_case_26
+ case 27:
+ goto st_case_27
+ case 28:
+ goto st_case_28
+ case 29:
+ goto st_case_29
+ case 30:
+ goto st_case_30
+ case 31:
+ goto st_case_31
+ case 32:
+ goto st_case_32
+ case 33:
+ goto st_case_33
+ case 34:
+ goto st_case_34
+ case 35:
+ goto st_case_35
+ case 36:
+ goto st_case_36
+ case 37:
+ goto st_case_37
+ case 38:
+ goto st_case_38
+ case 39:
+ goto st_case_39
+ case 40:
+ goto st_case_40
+ case 41:
+ goto st_case_41
+ case 42:
+ goto st_case_42
+ case 43:
+ goto st_case_43
+ case 44:
+ goto st_case_44
+ case 45:
+ goto st_case_45
+ case 46:
+ goto st_case_46
+ case 47:
+ goto st_case_47
+ case 48:
+ goto st_case_48
+ case 49:
+ goto st_case_49
+ case 50:
+ goto st_case_50
+ case 51:
+ goto st_case_51
+ case 52:
+ goto st_case_52
+ case 53:
+ goto st_case_53
+ case 54:
+ goto st_case_54
+ case 55:
+ goto st_case_55
+ case 56:
+ goto st_case_56
+ case 449:
+ goto st_case_449
+ case 57:
+ goto st_case_57
+ case 446:
+ goto st_case_446
+ case 453:
+ goto st_case_453
+ case 0:
+ goto st_case_0
+ case 454:
+ goto st_case_454
+ case 450:
+ goto st_case_450
+ case 58:
+ goto st_case_58
+ case 59:
+ goto st_case_59
+ case 60:
+ goto st_case_60
+ case 61:
+ goto st_case_61
+ case 62:
+ goto st_case_62
+ case 63:
+ goto st_case_63
+ case 64:
+ goto st_case_64
+ case 65:
+ goto st_case_65
+ case 66:
+ goto st_case_66
+ case 67:
+ goto st_case_67
+ case 68:
+ goto st_case_68
+ case 69:
+ goto st_case_69
+ case 70:
+ goto st_case_70
+ case 71:
+ goto st_case_71
+ case 72:
+ goto st_case_72
+ case 73:
+ goto st_case_73
+ case 74:
+ goto st_case_74
+ case 75:
+ goto st_case_75
+ case 76:
+ goto st_case_76
+ case 77:
+ goto st_case_77
+ case 78:
+ goto st_case_78
+ case 79:
+ goto st_case_79
+ case 80:
+ goto st_case_80
+ case 81:
+ goto st_case_81
+ case 82:
+ goto st_case_82
+ case 83:
+ goto st_case_83
+ case 84:
+ goto st_case_84
+ case 85:
+ goto st_case_85
+ case 86:
+ goto st_case_86
+ case 87:
+ goto st_case_87
+ case 88:
+ goto st_case_88
+ case 89:
+ goto st_case_89
+ case 90:
+ goto st_case_90
+ case 91:
+ goto st_case_91
+ case 92:
+ goto st_case_92
+ case 93:
+ goto st_case_93
+ case 94:
+ goto st_case_94
+ case 95:
+ goto st_case_95
+ case 96:
+ goto st_case_96
+ case 97:
+ goto st_case_97
+ case 98:
+ goto st_case_98
+ case 99:
+ goto st_case_99
+ case 100:
+ goto st_case_100
+ case 101:
+ goto st_case_101
+ case 102:
+ goto st_case_102
+ case 103:
+ goto st_case_103
+ case 104:
+ goto st_case_104
+ case 105:
+ goto st_case_105
+ case 106:
+ goto st_case_106
+ case 107:
+ goto st_case_107
+ case 108:
+ goto st_case_108
+ case 109:
+ goto st_case_109
+ case 110:
+ goto st_case_110
+ case 111:
+ goto st_case_111
+ case 112:
+ goto st_case_112
+ case 113:
+ goto st_case_113
+ case 114:
+ goto st_case_114
+ case 115:
+ goto st_case_115
+ case 116:
+ goto st_case_116
+ case 117:
+ goto st_case_117
+ case 118:
+ goto st_case_118
+ case 119:
+ goto st_case_119
+ case 120:
+ goto st_case_120
+ case 121:
+ goto st_case_121
+ case 122:
+ goto st_case_122
+ case 123:
+ goto st_case_123
+ case 124:
+ goto st_case_124
+ case 125:
+ goto st_case_125
+ case 126:
+ goto st_case_126
+ case 127:
+ goto st_case_127
+ case 128:
+ goto st_case_128
+ case 129:
+ goto st_case_129
+ case 130:
+ goto st_case_130
+ case 131:
+ goto st_case_131
+ case 132:
+ goto st_case_132
+ case 133:
+ goto st_case_133
+ case 134:
+ goto st_case_134
+ case 135:
+ goto st_case_135
+ case 136:
+ goto st_case_136
+ case 137:
+ goto st_case_137
+ case 138:
+ goto st_case_138
+ case 139:
+ goto st_case_139
+ case 140:
+ goto st_case_140
+ case 141:
+ goto st_case_141
+ case 142:
+ goto st_case_142
+ case 143:
+ goto st_case_143
+ case 144:
+ goto st_case_144
+ case 145:
+ goto st_case_145
+ case 451:
+ goto st_case_451
+ case 146:
+ goto st_case_146
+ case 147:
+ goto st_case_147
+ case 148:
+ goto st_case_148
+ case 149:
+ goto st_case_149
+ case 150:
+ goto st_case_150
+ case 151:
+ goto st_case_151
+ case 152:
+ goto st_case_152
+ case 153:
+ goto st_case_153
+ case 154:
+ goto st_case_154
+ case 155:
+ goto st_case_155
+ case 156:
+ goto st_case_156
+ case 157:
+ goto st_case_157
+ case 158:
+ goto st_case_158
+ case 159:
+ goto st_case_159
+ case 160:
+ goto st_case_160
+ case 452:
+ goto st_case_452
+ case 161:
+ goto st_case_161
+ case 162:
+ goto st_case_162
+ case 163:
+ goto st_case_163
+ case 164:
+ goto st_case_164
+ case 165:
+ goto st_case_165
+ case 166:
+ goto st_case_166
+ case 167:
+ goto st_case_167
+ case 168:
+ goto st_case_168
+ case 169:
+ goto st_case_169
+ case 170:
+ goto st_case_170
+ case 171:
+ goto st_case_171
+ case 172:
+ goto st_case_172
+ case 173:
+ goto st_case_173
+ case 174:
+ goto st_case_174
+ case 175:
+ goto st_case_175
+ case 176:
+ goto st_case_176
+ case 177:
+ goto st_case_177
+ case 178:
+ goto st_case_178
+ case 179:
+ goto st_case_179
+ case 180:
+ goto st_case_180
+ case 181:
+ goto st_case_181
+ case 182:
+ goto st_case_182
+ case 183:
+ goto st_case_183
+ case 184:
+ goto st_case_184
+ case 185:
+ goto st_case_185
+ case 186:
+ goto st_case_186
+ case 187:
+ goto st_case_187
+ case 188:
+ goto st_case_188
+ case 189:
+ goto st_case_189
+ case 190:
+ goto st_case_190
+ case 191:
+ goto st_case_191
+ case 192:
+ goto st_case_192
+ case 193:
+ goto st_case_193
+ case 194:
+ goto st_case_194
+ case 195:
+ goto st_case_195
+ case 196:
+ goto st_case_196
+ case 197:
+ goto st_case_197
+ case 198:
+ goto st_case_198
+ case 199:
+ goto st_case_199
+ case 200:
+ goto st_case_200
+ case 201:
+ goto st_case_201
+ case 202:
+ goto st_case_202
+ case 203:
+ goto st_case_203
+ case 204:
+ goto st_case_204
+ case 205:
+ goto st_case_205
+ case 206:
+ goto st_case_206
+ case 207:
+ goto st_case_207
+ case 208:
+ goto st_case_208
+ case 209:
+ goto st_case_209
+ case 210:
+ goto st_case_210
+ case 211:
+ goto st_case_211
+ case 212:
+ goto st_case_212
+ case 213:
+ goto st_case_213
+ case 214:
+ goto st_case_214
+ case 215:
+ goto st_case_215
+ case 216:
+ goto st_case_216
+ case 217:
+ goto st_case_217
+ case 218:
+ goto st_case_218
+ case 219:
+ goto st_case_219
+ case 220:
+ goto st_case_220
+ case 221:
+ goto st_case_221
+ case 222:
+ goto st_case_222
+ case 223:
+ goto st_case_223
+ case 224:
+ goto st_case_224
+ case 225:
+ goto st_case_225
+ case 226:
+ goto st_case_226
+ case 227:
+ goto st_case_227
+ case 228:
+ goto st_case_228
+ case 229:
+ goto st_case_229
+ case 230:
+ goto st_case_230
+ case 231:
+ goto st_case_231
+ case 232:
+ goto st_case_232
+ case 233:
+ goto st_case_233
+ case 234:
+ goto st_case_234
+ case 235:
+ goto st_case_235
+ case 236:
+ goto st_case_236
+ case 237:
+ goto st_case_237
+ case 238:
+ goto st_case_238
+ case 239:
+ goto st_case_239
+ case 240:
+ goto st_case_240
+ case 241:
+ goto st_case_241
+ case 242:
+ goto st_case_242
+ case 243:
+ goto st_case_243
+ case 244:
+ goto st_case_244
+ case 245:
+ goto st_case_245
+ case 246:
+ goto st_case_246
+ case 247:
+ goto st_case_247
+ case 248:
+ goto st_case_248
+ case 249:
+ goto st_case_249
+ case 250:
+ goto st_case_250
+ case 251:
+ goto st_case_251
+ case 252:
+ goto st_case_252
+ case 253:
+ goto st_case_253
+ case 254:
+ goto st_case_254
+ case 255:
+ goto st_case_255
+ case 256:
+ goto st_case_256
+ case 257:
+ goto st_case_257
+ case 258:
+ goto st_case_258
+ case 259:
+ goto st_case_259
+ case 260:
+ goto st_case_260
+ case 261:
+ goto st_case_261
+ case 262:
+ goto st_case_262
+ case 263:
+ goto st_case_263
+ case 264:
+ goto st_case_264
+ case 265:
+ goto st_case_265
+ case 266:
+ goto st_case_266
+ case 267:
+ goto st_case_267
+ case 268:
+ goto st_case_268
+ case 269:
+ goto st_case_269
+ case 270:
+ goto st_case_270
+ case 271:
+ goto st_case_271
+ case 272:
+ goto st_case_272
+ case 273:
+ goto st_case_273
+ case 274:
+ goto st_case_274
+ case 275:
+ goto st_case_275
+ case 276:
+ goto st_case_276
+ case 277:
+ goto st_case_277
+ case 278:
+ goto st_case_278
+ case 279:
+ goto st_case_279
+ case 280:
+ goto st_case_280
+ case 281:
+ goto st_case_281
+ case 282:
+ goto st_case_282
+ case 283:
+ goto st_case_283
+ case 284:
+ goto st_case_284
+ case 285:
+ goto st_case_285
+ case 286:
+ goto st_case_286
+ case 287:
+ goto st_case_287
+ case 288:
+ goto st_case_288
+ case 289:
+ goto st_case_289
+ case 290:
+ goto st_case_290
+ case 291:
+ goto st_case_291
+ case 292:
+ goto st_case_292
+ case 293:
+ goto st_case_293
+ case 294:
+ goto st_case_294
+ case 295:
+ goto st_case_295
+ case 296:
+ goto st_case_296
+ case 297:
+ goto st_case_297
+ case 298:
+ goto st_case_298
+ case 299:
+ goto st_case_299
+ case 300:
+ goto st_case_300
+ case 301:
+ goto st_case_301
+ case 302:
+ goto st_case_302
+ case 303:
+ goto st_case_303
+ case 304:
+ goto st_case_304
+ case 305:
+ goto st_case_305
+ case 306:
+ goto st_case_306
+ case 307:
+ goto st_case_307
+ case 308:
+ goto st_case_308
+ case 309:
+ goto st_case_309
+ case 310:
+ goto st_case_310
+ case 311:
+ goto st_case_311
+ case 312:
+ goto st_case_312
+ case 313:
+ goto st_case_313
+ case 314:
+ goto st_case_314
+ case 315:
+ goto st_case_315
+ case 316:
+ goto st_case_316
+ case 317:
+ goto st_case_317
+ case 318:
+ goto st_case_318
+ case 319:
+ goto st_case_319
+ case 320:
+ goto st_case_320
+ case 321:
+ goto st_case_321
+ case 322:
+ goto st_case_322
+ case 323:
+ goto st_case_323
+ case 324:
+ goto st_case_324
+ case 325:
+ goto st_case_325
+ case 326:
+ goto st_case_326
+ case 327:
+ goto st_case_327
+ case 328:
+ goto st_case_328
+ case 329:
+ goto st_case_329
+ case 330:
+ goto st_case_330
+ case 331:
+ goto st_case_331
+ case 332:
+ goto st_case_332
+ case 333:
+ goto st_case_333
+ case 334:
+ goto st_case_334
+ case 335:
+ goto st_case_335
+ case 336:
+ goto st_case_336
+ case 337:
+ goto st_case_337
+ case 338:
+ goto st_case_338
+ case 339:
+ goto st_case_339
+ case 340:
+ goto st_case_340
+ case 341:
+ goto st_case_341
+ case 342:
+ goto st_case_342
+ case 343:
+ goto st_case_343
+ case 344:
+ goto st_case_344
+ case 345:
+ goto st_case_345
+ case 346:
+ goto st_case_346
+ case 347:
+ goto st_case_347
+ case 348:
+ goto st_case_348
+ case 349:
+ goto st_case_349
+ case 350:
+ goto st_case_350
+ case 351:
+ goto st_case_351
+ case 352:
+ goto st_case_352
+ case 353:
+ goto st_case_353
+ case 354:
+ goto st_case_354
+ case 355:
+ goto st_case_355
+ case 356:
+ goto st_case_356
+ case 357:
+ goto st_case_357
+ case 358:
+ goto st_case_358
+ case 359:
+ goto st_case_359
+ case 360:
+ goto st_case_360
+ case 361:
+ goto st_case_361
+ case 362:
+ goto st_case_362
+ case 363:
+ goto st_case_363
+ case 364:
+ goto st_case_364
+ case 365:
+ goto st_case_365
+ case 366:
+ goto st_case_366
+ case 367:
+ goto st_case_367
+ case 368:
+ goto st_case_368
+ case 369:
+ goto st_case_369
+ case 370:
+ goto st_case_370
+ case 371:
+ goto st_case_371
+ case 372:
+ goto st_case_372
+ case 373:
+ goto st_case_373
+ case 374:
+ goto st_case_374
+ case 375:
+ goto st_case_375
+ case 376:
+ goto st_case_376
+ case 377:
+ goto st_case_377
+ case 378:
+ goto st_case_378
+ case 379:
+ goto st_case_379
+ case 380:
+ goto st_case_380
+ case 381:
+ goto st_case_381
+ case 382:
+ goto st_case_382
+ case 383:
+ goto st_case_383
+ case 384:
+ goto st_case_384
+ case 385:
+ goto st_case_385
+ case 386:
+ goto st_case_386
+ case 387:
+ goto st_case_387
+ case 388:
+ goto st_case_388
+ case 389:
+ goto st_case_389
+ case 390:
+ goto st_case_390
+ case 391:
+ goto st_case_391
+ case 392:
+ goto st_case_392
+ case 393:
+ goto st_case_393
+ case 394:
+ goto st_case_394
+ case 395:
+ goto st_case_395
+ case 396:
+ goto st_case_396
+ case 397:
+ goto st_case_397
+ case 398:
+ goto st_case_398
+ case 399:
+ goto st_case_399
+ case 400:
+ goto st_case_400
+ case 401:
+ goto st_case_401
+ case 402:
+ goto st_case_402
+ case 403:
+ goto st_case_403
+ case 404:
+ goto st_case_404
+ case 405:
+ goto st_case_405
+ case 406:
+ goto st_case_406
+ case 407:
+ goto st_case_407
+ case 408:
+ goto st_case_408
+ case 409:
+ goto st_case_409
+ case 410:
+ goto st_case_410
+ case 411:
+ goto st_case_411
+ case 412:
+ goto st_case_412
+ case 413:
+ goto st_case_413
+ case 414:
+ goto st_case_414
+ case 415:
+ goto st_case_415
+ case 416:
+ goto st_case_416
+ case 417:
+ goto st_case_417
+ case 418:
+ goto st_case_418
+ case 419:
+ goto st_case_419
+ case 420:
+ goto st_case_420
+ case 421:
+ goto st_case_421
+ case 422:
+ goto st_case_422
+ case 423:
+ goto st_case_423
+ case 424:
+ goto st_case_424
+ case 425:
+ goto st_case_425
+ case 426:
+ goto st_case_426
+ case 427:
+ goto st_case_427
+ case 428:
+ goto st_case_428
+ case 429:
+ goto st_case_429
+ case 430:
+ goto st_case_430
+ case 431:
+ goto st_case_431
+ case 432:
+ goto st_case_432
+ case 433:
+ goto st_case_433
+ case 434:
+ goto st_case_434
+ case 435:
+ goto st_case_435
+ case 436:
+ goto st_case_436
+ case 437:
+ goto st_case_437
+ case 438:
+ goto st_case_438
+ case 439:
+ goto st_case_439
+ case 440:
+ goto st_case_440
+ case 441:
+ goto st_case_441
+ case 442:
+ goto st_case_442
+ case 443:
+ goto st_case_443
+ case 444:
+ goto st_case_444
+ case 445:
+ goto st_case_445
+ }
+ goto st_out
+tr1:
+// line 47 "parseqt.rl"
+
+ curline++
+// line 71 "parseqt.rl"
+
+te = p+1
+
+ goto st447
+tr24:
+// line 71 "parseqt.rl"
+
+p = (te) - 1
+
+ goto st447
+tr25:
+// line 47 "parseqt.rl"
+
+ curline++
+// line 62 "parseqt.rl"
+
+te = p+1
+{
+ if data[m0:m1] == "QOpenGLFunctions" {
+ header.Class = data[m0:m1]
+ foundclass++
+ }
+ {goto st450 }
+ }
+ goto st447
+tr60:
+// line 47 "parseqt.rl"
+
+ curline++
+// line 55 "parseqt.rl"
+
+te = p+1
+{
+ header.Class = data[m0:m1]
+ foundclass++
+ {goto st450 }
+ }
+ goto st447
+tr529:
+// line 71 "parseqt.rl"
+
+te = p
+p--
+
+ goto st447
+ st447:
+// line 1 "NONE"
+
+ts = 0
+
+ if p++; p == pe {
+ goto _test_eof447
+ }
+ st_case_447:
+// line 1 "NONE"
+
+ts = p
+
+// line 1047 "parseqt.go"
+ switch data[p] {
+ case 10:
+ goto tr1
+ case 99:
+ goto st2
+ }
+ goto st1
+ st1:
+ if p++; p == pe {
+ goto _test_eof1
+ }
+ st_case_1:
+ if data[p] == 10 {
+ goto tr1
+ }
+ goto st1
+ st2:
+ if p++; p == pe {
+ goto _test_eof2
+ }
+ st_case_2:
+ switch data[p] {
+ case 10:
+ goto tr1
+ case 108:
+ goto st3
+ }
+ goto st1
+ st3:
+ if p++; p == pe {
+ goto _test_eof3
+ }
+ st_case_3:
+ switch data[p] {
+ case 10:
+ goto tr1
+ case 97:
+ goto st4
+ }
+ goto st1
+ st4:
+ if p++; p == pe {
+ goto _test_eof4
+ }
+ st_case_4:
+ switch data[p] {
+ case 10:
+ goto tr1
+ case 115:
+ goto st5
+ }
+ goto st1
+ st5:
+ if p++; p == pe {
+ goto _test_eof5
+ }
+ st_case_5:
+ switch data[p] {
+ case 10:
+ goto tr1
+ case 115:
+ goto st6
+ }
+ goto st1
+ st6:
+ if p++; p == pe {
+ goto _test_eof6
+ }
+ st_case_6:
+ switch data[p] {
+ case 10:
+ goto tr1
+ case 32:
+ goto st7
+ }
+ goto st1
+ st7:
+ if p++; p == pe {
+ goto _test_eof7
+ }
+ st_case_7:
+ switch data[p] {
+ case 10:
+ goto tr1
+ case 81:
+ goto st8
+ }
+ goto st1
+ st8:
+ if p++; p == pe {
+ goto _test_eof8
+ }
+ st_case_8:
+ switch data[p] {
+ case 10:
+ goto tr1
+ case 95:
+ goto st9
+ }
+ goto st1
+ st9:
+ if p++; p == pe {
+ goto _test_eof9
+ }
+ st_case_9:
+ switch data[p] {
+ case 10:
+ goto tr1
+ case 71:
+ goto st10
+ }
+ goto st1
+ st10:
+ if p++; p == pe {
+ goto _test_eof10
+ }
+ st_case_10:
+ switch data[p] {
+ case 10:
+ goto tr1
+ case 85:
+ goto st11
+ }
+ goto st1
+ st11:
+ if p++; p == pe {
+ goto _test_eof11
+ }
+ st_case_11:
+ switch data[p] {
+ case 10:
+ goto tr1
+ case 73:
+ goto st12
+ }
+ goto st1
+ st12:
+ if p++; p == pe {
+ goto _test_eof12
+ }
+ st_case_12:
+ switch data[p] {
+ case 10:
+ goto tr1
+ case 95:
+ goto st13
+ }
+ goto st1
+ st13:
+ if p++; p == pe {
+ goto _test_eof13
+ }
+ st_case_13:
+ switch data[p] {
+ case 10:
+ goto tr1
+ case 69:
+ goto st14
+ }
+ goto st1
+ st14:
+ if p++; p == pe {
+ goto _test_eof14
+ }
+ st_case_14:
+ switch data[p] {
+ case 10:
+ goto tr1
+ case 88:
+ goto st15
+ }
+ goto st1
+ st15:
+ if p++; p == pe {
+ goto _test_eof15
+ }
+ st_case_15:
+ switch data[p] {
+ case 10:
+ goto tr1
+ case 80:
+ goto st16
+ }
+ goto st1
+ st16:
+ if p++; p == pe {
+ goto _test_eof16
+ }
+ st_case_16:
+ switch data[p] {
+ case 10:
+ goto tr1
+ case 79:
+ goto st17
+ }
+ goto st1
+ st17:
+ if p++; p == pe {
+ goto _test_eof17
+ }
+ st_case_17:
+ switch data[p] {
+ case 10:
+ goto tr1
+ case 82:
+ goto st18
+ }
+ goto st1
+ st18:
+ if p++; p == pe {
+ goto _test_eof18
+ }
+ st_case_18:
+ switch data[p] {
+ case 10:
+ goto tr1
+ case 84:
+ goto st19
+ }
+ goto st1
+ st19:
+ if p++; p == pe {
+ goto _test_eof19
+ }
+ st_case_19:
+ switch data[p] {
+ case 10:
+ goto tr1
+ case 32:
+ goto st20
+ }
+ goto st1
+ st20:
+ if p++; p == pe {
+ goto _test_eof20
+ }
+ st_case_20:
+ switch data[p] {
+ case 10:
+ goto tr1
+ case 95:
+ goto tr20
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto tr20
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto tr20
+ }
+ default:
+ goto tr20
+ }
+ goto st1
+tr20:
+// line 54 "parseqt.rl"
+
+ m0 = p
+// line 61 "parseqt.rl"
+
+ m0 = p
+ goto st21
+ st21:
+ if p++; p == pe {
+ goto _test_eof21
+ }
+ st_case_21:
+// line 1317 "parseqt.go"
+ switch data[p] {
+ case 10:
+ goto tr21
+ case 32:
+ goto tr22
+ case 95:
+ goto st21
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st21
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st21
+ }
+ default:
+ goto st21
+ }
+ goto st1
+tr21:
+// line 1 "NONE"
+
+te = p+1
+
+// line 61 "parseqt.rl"
+
+ m1 = p
+// line 47 "parseqt.rl"
+
+ curline++
+ goto st448
+ st448:
+ if p++; p == pe {
+ goto _test_eof448
+ }
+ st_case_448:
+// line 1356 "parseqt.go"
+ if data[p] == 123 {
+ goto st22
+ }
+ goto tr529
+ st22:
+ if p++; p == pe {
+ goto _test_eof22
+ }
+ st_case_22:
+ if data[p] == 10 {
+ goto tr25
+ }
+ goto tr24
+tr22:
+// line 54 "parseqt.rl"
+
+ m1 = p
+ goto st23
+ st23:
+ if p++; p == pe {
+ goto _test_eof23
+ }
+ st_case_23:
+// line 1380 "parseqt.go"
+ switch data[p] {
+ case 10:
+ goto tr1
+ case 58:
+ goto st24
+ }
+ goto st1
+ st24:
+ if p++; p == pe {
+ goto _test_eof24
+ }
+ st_case_24:
+ switch data[p] {
+ case 10:
+ goto tr1
+ case 32:
+ goto st25
+ }
+ goto st1
+ st25:
+ if p++; p == pe {
+ goto _test_eof25
+ }
+ st_case_25:
+ switch data[p] {
+ case 10:
+ goto tr1
+ case 112:
+ goto st26
+ }
+ goto st1
+ st26:
+ if p++; p == pe {
+ goto _test_eof26
+ }
+ st_case_26:
+ switch data[p] {
+ case 10:
+ goto tr1
+ case 117:
+ goto st27
+ }
+ goto st1
+ st27:
+ if p++; p == pe {
+ goto _test_eof27
+ }
+ st_case_27:
+ switch data[p] {
+ case 10:
+ goto tr1
+ case 98:
+ goto st28
+ }
+ goto st1
+ st28:
+ if p++; p == pe {
+ goto _test_eof28
+ }
+ st_case_28:
+ switch data[p] {
+ case 10:
+ goto tr1
+ case 108:
+ goto st29
+ }
+ goto st1
+ st29:
+ if p++; p == pe {
+ goto _test_eof29
+ }
+ st_case_29:
+ switch data[p] {
+ case 10:
+ goto tr1
+ case 105:
+ goto st30
+ }
+ goto st1
+ st30:
+ if p++; p == pe {
+ goto _test_eof30
+ }
+ st_case_30:
+ switch data[p] {
+ case 10:
+ goto tr1
+ case 99:
+ goto st31
+ }
+ goto st1
+ st31:
+ if p++; p == pe {
+ goto _test_eof31
+ }
+ st_case_31:
+ switch data[p] {
+ case 10:
+ goto tr1
+ case 32:
+ goto st32
+ }
+ goto st1
+ st32:
+ if p++; p == pe {
+ goto _test_eof32
+ }
+ st_case_32:
+ switch data[p] {
+ case 10:
+ goto tr1
+ case 81:
+ goto st33
+ }
+ goto st1
+ st33:
+ if p++; p == pe {
+ goto _test_eof33
+ }
+ st_case_33:
+ switch data[p] {
+ case 10:
+ goto tr1
+ case 65:
+ goto st34
+ }
+ goto st1
+ st34:
+ if p++; p == pe {
+ goto _test_eof34
+ }
+ st_case_34:
+ switch data[p] {
+ case 10:
+ goto tr1
+ case 98:
+ goto st35
+ }
+ goto st1
+ st35:
+ if p++; p == pe {
+ goto _test_eof35
+ }
+ st_case_35:
+ switch data[p] {
+ case 10:
+ goto tr1
+ case 115:
+ goto st36
+ }
+ goto st1
+ st36:
+ if p++; p == pe {
+ goto _test_eof36
+ }
+ st_case_36:
+ switch data[p] {
+ case 10:
+ goto tr1
+ case 116:
+ goto st37
+ }
+ goto st1
+ st37:
+ if p++; p == pe {
+ goto _test_eof37
+ }
+ st_case_37:
+ switch data[p] {
+ case 10:
+ goto tr1
+ case 114:
+ goto st38
+ }
+ goto st1
+ st38:
+ if p++; p == pe {
+ goto _test_eof38
+ }
+ st_case_38:
+ switch data[p] {
+ case 10:
+ goto tr1
+ case 97:
+ goto st39
+ }
+ goto st1
+ st39:
+ if p++; p == pe {
+ goto _test_eof39
+ }
+ st_case_39:
+ switch data[p] {
+ case 10:
+ goto tr1
+ case 99:
+ goto st40
+ }
+ goto st1
+ st40:
+ if p++; p == pe {
+ goto _test_eof40
+ }
+ st_case_40:
+ switch data[p] {
+ case 10:
+ goto tr1
+ case 116:
+ goto st41
+ }
+ goto st1
+ st41:
+ if p++; p == pe {
+ goto _test_eof41
+ }
+ st_case_41:
+ switch data[p] {
+ case 10:
+ goto tr1
+ case 79:
+ goto st42
+ }
+ goto st1
+ st42:
+ if p++; p == pe {
+ goto _test_eof42
+ }
+ st_case_42:
+ switch data[p] {
+ case 10:
+ goto tr1
+ case 112:
+ goto st43
+ }
+ goto st1
+ st43:
+ if p++; p == pe {
+ goto _test_eof43
+ }
+ st_case_43:
+ switch data[p] {
+ case 10:
+ goto tr1
+ case 101:
+ goto st44
+ }
+ goto st1
+ st44:
+ if p++; p == pe {
+ goto _test_eof44
+ }
+ st_case_44:
+ switch data[p] {
+ case 10:
+ goto tr1
+ case 110:
+ goto st45
+ }
+ goto st1
+ st45:
+ if p++; p == pe {
+ goto _test_eof45
+ }
+ st_case_45:
+ switch data[p] {
+ case 10:
+ goto tr1
+ case 71:
+ goto st46
+ }
+ goto st1
+ st46:
+ if p++; p == pe {
+ goto _test_eof46
+ }
+ st_case_46:
+ switch data[p] {
+ case 10:
+ goto tr1
+ case 76:
+ goto st47
+ }
+ goto st1
+ st47:
+ if p++; p == pe {
+ goto _test_eof47
+ }
+ st_case_47:
+ switch data[p] {
+ case 10:
+ goto tr1
+ case 70:
+ goto st48
+ }
+ goto st1
+ st48:
+ if p++; p == pe {
+ goto _test_eof48
+ }
+ st_case_48:
+ switch data[p] {
+ case 10:
+ goto tr1
+ case 117:
+ goto st49
+ }
+ goto st1
+ st49:
+ if p++; p == pe {
+ goto _test_eof49
+ }
+ st_case_49:
+ switch data[p] {
+ case 10:
+ goto tr1
+ case 110:
+ goto st50
+ }
+ goto st1
+ st50:
+ if p++; p == pe {
+ goto _test_eof50
+ }
+ st_case_50:
+ switch data[p] {
+ case 10:
+ goto tr1
+ case 99:
+ goto st51
+ }
+ goto st1
+ st51:
+ if p++; p == pe {
+ goto _test_eof51
+ }
+ st_case_51:
+ switch data[p] {
+ case 10:
+ goto tr1
+ case 116:
+ goto st52
+ }
+ goto st1
+ st52:
+ if p++; p == pe {
+ goto _test_eof52
+ }
+ st_case_52:
+ switch data[p] {
+ case 10:
+ goto tr1
+ case 105:
+ goto st53
+ }
+ goto st1
+ st53:
+ if p++; p == pe {
+ goto _test_eof53
+ }
+ st_case_53:
+ switch data[p] {
+ case 10:
+ goto tr1
+ case 111:
+ goto st54
+ }
+ goto st1
+ st54:
+ if p++; p == pe {
+ goto _test_eof54
+ }
+ st_case_54:
+ switch data[p] {
+ case 10:
+ goto tr1
+ case 110:
+ goto st55
+ }
+ goto st1
+ st55:
+ if p++; p == pe {
+ goto _test_eof55
+ }
+ st_case_55:
+ switch data[p] {
+ case 10:
+ goto tr1
+ case 115:
+ goto st56
+ }
+ goto st1
+ st56:
+ if p++; p == pe {
+ goto _test_eof56
+ }
+ st_case_56:
+ if data[p] == 10 {
+ goto tr59
+ }
+ goto st1
+tr59:
+// line 1 "NONE"
+
+te = p+1
+
+// line 47 "parseqt.rl"
+
+ curline++
+ goto st449
+ st449:
+ if p++; p == pe {
+ goto _test_eof449
+ }
+ st_case_449:
+// line 1795 "parseqt.go"
+ if data[p] == 123 {
+ goto st57
+ }
+ goto tr529
+ st57:
+ if p++; p == pe {
+ goto _test_eof57
+ }
+ st_case_57:
+ if data[p] == 10 {
+ goto tr60
+ }
+ goto tr24
+ st446:
+// line 1 "NONE"
+
+ts = 0
+
+ if p++; p == pe {
+ goto _test_eof446
+ }
+ st_case_446:
+// line 1818 "parseqt.go"
+ switch data[p] {
+ case 10:
+ goto tr526
+ case 59:
+ goto tr527
+ }
+ goto st446
+tr526:
+// line 47 "parseqt.rl"
+
+ curline++
+// line 157 "parseqt.rl"
+
+ {goto st447 }
+ goto st453
+ st453:
+ if p++; p == pe {
+ goto _test_eof453
+ }
+ st_case_453:
+// line 1839 "parseqt.go"
+ goto st0
+st_case_0:
+ st0:
+ cs = 0
+ goto _out
+tr527:
+// line 157 "parseqt.rl"
+
+ {goto st447 }
+ goto st454
+ st454:
+ if p++; p == pe {
+ goto _test_eof454
+ }
+ st_case_454:
+// line 1855 "parseqt.go"
+ switch data[p] {
+ case 10:
+ goto tr526
+ case 59:
+ goto tr527
+ }
+ goto st446
+tr63:
+// line 47 "parseqt.rl"
+
+ curline++
+// line 147 "parseqt.rl"
+
+te = p+1
+{
+ // Reset heading comment.
+ heading = ""
+
+ // Start new line block.
+ lineblock++
+ }
+ goto st450
+tr79:
+// line 76 "parseqt.rl"
+
+ m0 = p
+// line 47 "parseqt.rl"
+
+ curline++
+// line 77 "parseqt.rl"
+
+te = p+1
+{
+ heading = data[m0:m1]
+ _ = heading
+ lineblock++
+ }
+ goto st450
+tr81:
+// line 47 "parseqt.rl"
+
+ curline++
+// line 77 "parseqt.rl"
+
+te = p+1
+{
+ heading = data[m0:m1]
+ _ = heading
+ lineblock++
+ }
+ goto st450
+tr96:
+// line 47 "parseqt.rl"
+
+ curline++
+// line 128 "parseqt.rl"
+
+te = p+1
+
+ goto st450
+tr102:
+// line 1 "NONE"
+
+ switch act {
+ case 0:
+ {{goto st0 }}
+ case 10:
+ {p = (te) - 1
+
+ if (inpublic) {
+ header.Func = append(header.Func, f)
+ }
+ }
+ }
+
+ goto st450
+tr130:
+// line 114 "parseqt.rl"
+
+te = p+1
+{
+ if (inpublic) {
+ header.Func = append(header.Func, f)
+ }
+ }
+ goto st450
+tr250:
+// line 47 "parseqt.rl"
+
+ curline++
+// line 84 "parseqt.rl"
+
+te = p+1
+{
+ if data[m0:m1] != header.Class {
+ {p++; cs = 450; goto _out }
+ }
+ }
+ goto st450
+tr279:
+// line 47 "parseqt.rl"
+
+ curline++
+// line 131 "parseqt.rl"
+
+te = p+1
+
+ goto st450
+tr315:
+// line 47 "parseqt.rl"
+
+ curline++
+// line 91 "parseqt.rl"
+
+te = p+1
+
+ goto st450
+tr398:
+// line 47 "parseqt.rl"
+
+ curline++
+// line 124 "parseqt.rl"
+
+te = p+1
+
+ goto st450
+tr416:
+// line 47 "parseqt.rl"
+
+ curline++
+// line 94 "parseqt.rl"
+
+te = p+1
+
+ goto st450
+tr433:
+// line 47 "parseqt.rl"
+
+ curline++
+// line 102 "parseqt.rl"
+
+te = p+1
+{
+ inpublic = false
+ }
+ goto st450
+tr445:
+// line 47 "parseqt.rl"
+
+ curline++
+// line 98 "parseqt.rl"
+
+te = p+1
+{
+ inpublic = true
+ }
+ goto st450
+tr481:
+// line 47 "parseqt.rl"
+
+ curline++
+// line 140 "parseqt.rl"
+
+te = p+1
+{
+ foundclass++;
+ {goto st447 }
+ }
+ goto st450
+tr519:
+// line 47 "parseqt.rl"
+
+ curline++
+// line 136 "parseqt.rl"
+
+te = p+1
+
+ goto st450
+tr533:
+// line 114 "parseqt.rl"
+
+te = p
+p--
+{
+ if (inpublic) {
+ header.Func = append(header.Func, f)
+ }
+ }
+ goto st450
+ st450:
+// line 1 "NONE"
+
+ts = 0
+
+// line 1 "NONE"
+
+act = 0
+
+ if p++; p == pe {
+ goto _test_eof450
+ }
+ st_case_450:
+// line 1 "NONE"
+
+ts = p
+
+// line 2062 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto st58
+ case 10:
+ goto tr63
+ case 32:
+ goto st58
+ case 35:
+ goto st405
+ case 47:
+ goto st59
+ case 58:
+ goto st188
+ case 81:
+ goto tr67
+ case 95:
+ goto tr65
+ case 98:
+ goto tr68
+ case 99:
+ goto tr69
+ case 101:
+ goto tr70
+ case 102:
+ goto tr71
+ case 112:
+ goto tr72
+ case 115:
+ goto tr73
+ case 125:
+ goto st401
+ case 126:
+ goto st403
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto tr65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto tr65
+ }
+ default:
+ goto tr65
+ }
+ goto st0
+ st58:
+ if p++; p == pe {
+ goto _test_eof58
+ }
+ st_case_58:
+ switch data[p] {
+ case 9:
+ goto st58
+ case 10:
+ goto tr63
+ case 32:
+ goto st58
+ case 47:
+ goto st59
+ case 58:
+ goto st188
+ case 81:
+ goto tr67
+ case 95:
+ goto tr65
+ case 98:
+ goto tr68
+ case 99:
+ goto tr69
+ case 101:
+ goto tr70
+ case 102:
+ goto tr71
+ case 112:
+ goto tr72
+ case 115:
+ goto tr73
+ case 125:
+ goto st401
+ case 126:
+ goto st403
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto tr65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto tr65
+ }
+ default:
+ goto tr65
+ }
+ goto st0
+ st59:
+ if p++; p == pe {
+ goto _test_eof59
+ }
+ st_case_59:
+ if data[p] == 47 {
+ goto st60
+ }
+ goto st0
+tr78:
+// line 76 "parseqt.rl"
+
+ m0 = p
+// line 76 "parseqt.rl"
+
+ m1 = p
+ goto st60
+ st60:
+ if p++; p == pe {
+ goto _test_eof60
+ }
+ st_case_60:
+// line 2182 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto tr78
+ case 10:
+ goto tr79
+ case 32:
+ goto tr78
+ }
+ goto tr77
+tr77:
+// line 76 "parseqt.rl"
+
+ m0 = p
+// line 76 "parseqt.rl"
+
+ m1 = p
+ goto st61
+tr80:
+// line 76 "parseqt.rl"
+
+ m1 = p
+ goto st61
+ st61:
+ if p++; p == pe {
+ goto _test_eof61
+ }
+ st_case_61:
+// line 2210 "parseqt.go"
+ if data[p] == 10 {
+ goto tr81
+ }
+ goto tr80
+tr65:
+// line 84 "parseqt.rl"
+
+ m0 = p
+// line 107 "parseqt.rl"
+
+ m0 = p
+ goto st62
+ st62:
+ if p++; p == pe {
+ goto _test_eof62
+ }
+ st_case_62:
+// line 2228 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto tr82
+ case 32:
+ goto tr82
+ case 40:
+ goto tr83
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 95:
+ goto st62
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st62
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st62
+ }
+ default:
+ goto st62
+ }
+ goto st0
+tr82:
+// line 107 "parseqt.rl"
+
+ m1 = p; m4 = 0
+ goto st63
+ st63:
+ if p++; p == pe {
+ goto _test_eof63
+ }
+ st_case_63:
+// line 2266 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto st63
+ case 32:
+ goto st63
+ case 42:
+ goto tr87
+ case 95:
+ goto st65
+ case 99:
+ goto st134
+ case 103:
+ goto tr90
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+tr84:
+// line 107 "parseqt.rl"
+
+ m1 = p; m4 = 0
+// line 107 "parseqt.rl"
+
+ m4++
+// line 127 "parseqt.rl"
+
+ m4++
+ goto st64
+tr87:
+// line 107 "parseqt.rl"
+
+ m4++
+// line 127 "parseqt.rl"
+
+ m4++
+ goto st64
+ st64:
+ if p++; p == pe {
+ goto _test_eof64
+ }
+ st_case_64:
+// line 2318 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto st63
+ case 32:
+ goto st63
+ case 42:
+ goto tr87
+ case 95:
+ goto st65
+ case 103:
+ goto tr90
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st65:
+ if p++; p == pe {
+ goto _test_eof65
+ }
+ st_case_65:
+ switch data[p] {
+ case 9:
+ goto st66
+ case 32:
+ goto st66
+ case 40:
+ goto st75
+ case 59:
+ goto st67
+ case 95:
+ goto st65
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st66:
+ if p++; p == pe {
+ goto _test_eof66
+ }
+ st_case_66:
+ switch data[p] {
+ case 9:
+ goto st66
+ case 32:
+ goto st66
+ case 59:
+ goto st67
+ case 99:
+ goto st68
+ case 123:
+ goto st73
+ }
+ goto st0
+ st67:
+ if p++; p == pe {
+ goto _test_eof67
+ }
+ st_case_67:
+ switch data[p] {
+ case 9:
+ goto st67
+ case 10:
+ goto tr96
+ case 32:
+ goto st67
+ }
+ goto st0
+ st68:
+ if p++; p == pe {
+ goto _test_eof68
+ }
+ st_case_68:
+ if data[p] == 111 {
+ goto st69
+ }
+ goto st0
+ st69:
+ if p++; p == pe {
+ goto _test_eof69
+ }
+ st_case_69:
+ if data[p] == 110 {
+ goto st70
+ }
+ goto st0
+ st70:
+ if p++; p == pe {
+ goto _test_eof70
+ }
+ st_case_70:
+ if data[p] == 115 {
+ goto st71
+ }
+ goto st0
+ st71:
+ if p++; p == pe {
+ goto _test_eof71
+ }
+ st_case_71:
+ if data[p] == 116 {
+ goto st72
+ }
+ goto st0
+ st72:
+ if p++; p == pe {
+ goto _test_eof72
+ }
+ st_case_72:
+ switch data[p] {
+ case 9:
+ goto st72
+ case 32:
+ goto st72
+ case 59:
+ goto st67
+ case 123:
+ goto st73
+ }
+ goto st0
+ st73:
+ if p++; p == pe {
+ goto _test_eof73
+ }
+ st_case_73:
+ switch data[p] {
+ case 10:
+ goto st0
+ case 125:
+ goto st74
+ }
+ goto st73
+ st74:
+ if p++; p == pe {
+ goto _test_eof74
+ }
+ st_case_74:
+ switch data[p] {
+ case 9:
+ goto st74
+ case 10:
+ goto tr96
+ case 32:
+ goto st74
+ case 125:
+ goto st74
+ }
+ goto st73
+ st75:
+ if p++; p == pe {
+ goto _test_eof75
+ }
+ st_case_75:
+ switch data[p] {
+ case 10:
+ goto tr102
+ case 41:
+ goto st76
+ }
+ goto st75
+ st76:
+ if p++; p == pe {
+ goto _test_eof76
+ }
+ st_case_76:
+ switch data[p] {
+ case 9:
+ goto st76
+ case 10:
+ goto tr102
+ case 32:
+ goto st76
+ case 41:
+ goto st76
+ case 59:
+ goto st77
+ case 99:
+ goto st78
+ case 123:
+ goto st83
+ }
+ goto st75
+ st77:
+ if p++; p == pe {
+ goto _test_eof77
+ }
+ st_case_77:
+ switch data[p] {
+ case 9:
+ goto st77
+ case 10:
+ goto tr96
+ case 32:
+ goto st77
+ case 41:
+ goto st76
+ }
+ goto st75
+ st78:
+ if p++; p == pe {
+ goto _test_eof78
+ }
+ st_case_78:
+ switch data[p] {
+ case 10:
+ goto tr102
+ case 41:
+ goto st76
+ case 111:
+ goto st79
+ }
+ goto st75
+ st79:
+ if p++; p == pe {
+ goto _test_eof79
+ }
+ st_case_79:
+ switch data[p] {
+ case 10:
+ goto tr102
+ case 41:
+ goto st76
+ case 110:
+ goto st80
+ }
+ goto st75
+ st80:
+ if p++; p == pe {
+ goto _test_eof80
+ }
+ st_case_80:
+ switch data[p] {
+ case 10:
+ goto tr102
+ case 41:
+ goto st76
+ case 115:
+ goto st81
+ }
+ goto st75
+ st81:
+ if p++; p == pe {
+ goto _test_eof81
+ }
+ st_case_81:
+ switch data[p] {
+ case 10:
+ goto tr102
+ case 41:
+ goto st76
+ case 116:
+ goto st82
+ }
+ goto st75
+ st82:
+ if p++; p == pe {
+ goto _test_eof82
+ }
+ st_case_82:
+ switch data[p] {
+ case 9:
+ goto st82
+ case 10:
+ goto tr102
+ case 32:
+ goto st82
+ case 41:
+ goto st76
+ case 59:
+ goto st77
+ case 123:
+ goto st83
+ }
+ goto st75
+ st83:
+ if p++; p == pe {
+ goto _test_eof83
+ }
+ st_case_83:
+ switch data[p] {
+ case 10:
+ goto tr102
+ case 41:
+ goto st84
+ case 125:
+ goto st85
+ }
+ goto st83
+ st84:
+ if p++; p == pe {
+ goto _test_eof84
+ }
+ st_case_84:
+ switch data[p] {
+ case 9:
+ goto st84
+ case 10:
+ goto tr102
+ case 32:
+ goto st84
+ case 41:
+ goto st84
+ case 59:
+ goto st85
+ case 99:
+ goto st86
+ case 125:
+ goto st85
+ }
+ goto st83
+ st85:
+ if p++; p == pe {
+ goto _test_eof85
+ }
+ st_case_85:
+ switch data[p] {
+ case 9:
+ goto st85
+ case 10:
+ goto tr96
+ case 32:
+ goto st85
+ case 41:
+ goto st84
+ case 125:
+ goto st85
+ }
+ goto st83
+ st86:
+ if p++; p == pe {
+ goto _test_eof86
+ }
+ st_case_86:
+ switch data[p] {
+ case 10:
+ goto tr102
+ case 41:
+ goto st84
+ case 111:
+ goto st87
+ case 125:
+ goto st85
+ }
+ goto st83
+ st87:
+ if p++; p == pe {
+ goto _test_eof87
+ }
+ st_case_87:
+ switch data[p] {
+ case 10:
+ goto tr102
+ case 41:
+ goto st84
+ case 110:
+ goto st88
+ case 125:
+ goto st85
+ }
+ goto st83
+ st88:
+ if p++; p == pe {
+ goto _test_eof88
+ }
+ st_case_88:
+ switch data[p] {
+ case 10:
+ goto tr102
+ case 41:
+ goto st84
+ case 115:
+ goto st89
+ case 125:
+ goto st85
+ }
+ goto st83
+ st89:
+ if p++; p == pe {
+ goto _test_eof89
+ }
+ st_case_89:
+ switch data[p] {
+ case 10:
+ goto tr102
+ case 41:
+ goto st84
+ case 116:
+ goto st90
+ case 125:
+ goto st85
+ }
+ goto st83
+ st90:
+ if p++; p == pe {
+ goto _test_eof90
+ }
+ st_case_90:
+ switch data[p] {
+ case 9:
+ goto st90
+ case 10:
+ goto tr102
+ case 32:
+ goto st90
+ case 41:
+ goto st84
+ case 59:
+ goto st85
+ case 125:
+ goto st85
+ }
+ goto st83
+tr90:
+// line 109 "parseqt.rl"
+
+ m2 = p
+ goto st91
+ st91:
+ if p++; p == pe {
+ goto _test_eof91
+ }
+ st_case_91:
+// line 2762 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto st66
+ case 32:
+ goto st66
+ case 40:
+ goto st75
+ case 59:
+ goto st67
+ case 95:
+ goto st65
+ case 108:
+ goto st92
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st92:
+ if p++; p == pe {
+ goto _test_eof92
+ }
+ st_case_92:
+ switch data[p] {
+ case 9:
+ goto st66
+ case 32:
+ goto st66
+ case 40:
+ goto st75
+ case 59:
+ goto st67
+ case 95:
+ goto st93
+ case 99:
+ goto st128
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st93
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st93
+ }
+ default:
+ goto st93
+ }
+ goto st0
+ st93:
+ if p++; p == pe {
+ goto _test_eof93
+ }
+ st_case_93:
+ switch data[p] {
+ case 9:
+ goto tr121
+ case 32:
+ goto tr121
+ case 40:
+ goto tr122
+ case 95:
+ goto st93
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st93
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st93
+ }
+ default:
+ goto st93
+ }
+ goto st0
+tr121:
+// line 109 "parseqt.rl"
+
+ m3 = p; f = Func{Name: data[m2:m3], Type: data[m0:m1], Addr: m4}
+ goto st94
+ st94:
+ if p++; p == pe {
+ goto _test_eof94
+ }
+ st_case_94:
+// line 2864 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto st94
+ case 32:
+ goto st94
+ case 40:
+ goto tr124
+ }
+ goto st0
+tr122:
+// line 109 "parseqt.rl"
+
+ m3 = p; f = Func{Name: data[m2:m3], Type: data[m0:m1], Addr: m4}
+// line 109 "parseqt.rl"
+
+ m6 = 0
+ goto st95
+tr124:
+// line 109 "parseqt.rl"
+
+ m6 = 0
+ goto st95
+ st95:
+ if p++; p == pe {
+ goto _test_eof95
+ }
+ st_case_95:
+// line 2892 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto st95
+ case 32:
+ goto st95
+ case 41:
+ goto st96
+ case 95:
+ goto tr127
+ case 99:
+ goto tr128
+ case 118:
+ goto tr129
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto tr127
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto tr127
+ }
+ default:
+ goto tr127
+ }
+ goto st0
+ st96:
+ if p++; p == pe {
+ goto _test_eof96
+ }
+ st_case_96:
+ switch data[p] {
+ case 9:
+ goto st96
+ case 32:
+ goto st96
+ case 59:
+ goto tr130
+ }
+ goto st0
+tr127:
+// line 111 "parseqt.rl"
+
+ m0 = p
+ goto st97
+ st97:
+ if p++; p == pe {
+ goto _test_eof97
+ }
+ st_case_97:
+// line 2944 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto tr131
+ case 32:
+ goto tr131
+ case 42:
+ goto tr132
+ case 95:
+ goto st97
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st97
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st97
+ }
+ default:
+ goto st97
+ }
+ goto st0
+tr131:
+// line 111 "parseqt.rl"
+
+ m1 = p; m4 = 0
+ goto st98
+ st98:
+ if p++; p == pe {
+ goto _test_eof98
+ }
+ st_case_98:
+// line 2978 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto st98
+ case 32:
+ goto st98
+ case 42:
+ goto tr135
+ case 95:
+ goto tr136
+ case 99:
+ goto tr137
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto tr136
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto tr136
+ }
+ default:
+ goto tr136
+ }
+ goto st0
+tr132:
+// line 111 "parseqt.rl"
+
+ m1 = p; m4 = 0
+// line 111 "parseqt.rl"
+
+ m4++
+ goto st99
+tr135:
+// line 111 "parseqt.rl"
+
+ m4++
+ goto st99
+ st99:
+ if p++; p == pe {
+ goto _test_eof99
+ }
+ st_case_99:
+// line 3022 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto st98
+ case 32:
+ goto st98
+ case 42:
+ goto tr135
+ case 95:
+ goto tr136
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto tr136
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto tr136
+ }
+ default:
+ goto tr136
+ }
+ goto st0
+tr136:
+// line 111 "parseqt.rl"
+
+ m2 = p; m5 = 0
+ goto st100
+ st100:
+ if p++; p == pe {
+ goto _test_eof100
+ }
+ st_case_100:
+// line 3056 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto tr138
+ case 32:
+ goto tr138
+ case 41:
+ goto tr139
+ case 44:
+ goto tr139
+ case 91:
+ goto tr141
+ case 95:
+ goto st100
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st100
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st100
+ }
+ default:
+ goto st100
+ }
+ goto st0
+tr138:
+// line 111 "parseqt.rl"
+
+ m3 = p
+ goto st101
+ st101:
+ if p++; p == pe {
+ goto _test_eof101
+ }
+ st_case_101:
+// line 3094 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto st101
+ case 32:
+ goto st101
+ case 41:
+ goto tr143
+ case 44:
+ goto tr143
+ }
+ goto st0
+tr139:
+// line 111 "parseqt.rl"
+
+ m3 = p
+// line 112 "parseqt.rl"
+
+ f.Param = append(f.Param, Param{Name: data[m2:m3], Type: data[m0:m1], Addr: m4, Array: m5, Const: m6 > 0}); m6 = 0
+ goto st102
+tr143:
+// line 112 "parseqt.rl"
+
+ f.Param = append(f.Param, Param{Name: data[m2:m3], Type: data[m0:m1], Addr: m4, Array: m5, Const: m6 > 0}); m6 = 0
+ goto st102
+ st102:
+ if p++; p == pe {
+ goto _test_eof102
+ }
+ st_case_102:
+// line 3124 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto st102
+ case 32:
+ goto st102
+ case 59:
+ goto tr130
+ case 95:
+ goto tr127
+ case 99:
+ goto tr128
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto tr127
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto tr127
+ }
+ default:
+ goto tr127
+ }
+ goto st0
+tr128:
+// line 111 "parseqt.rl"
+
+ m0 = p
+ goto st103
+ st103:
+ if p++; p == pe {
+ goto _test_eof103
+ }
+ st_case_103:
+// line 3160 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto tr131
+ case 32:
+ goto tr131
+ case 42:
+ goto tr132
+ case 95:
+ goto st97
+ case 111:
+ goto st104
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st97
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st97
+ }
+ default:
+ goto st97
+ }
+ goto st0
+ st104:
+ if p++; p == pe {
+ goto _test_eof104
+ }
+ st_case_104:
+ switch data[p] {
+ case 9:
+ goto tr131
+ case 32:
+ goto tr131
+ case 42:
+ goto tr132
+ case 95:
+ goto st97
+ case 110:
+ goto st105
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st97
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st97
+ }
+ default:
+ goto st97
+ }
+ goto st0
+ st105:
+ if p++; p == pe {
+ goto _test_eof105
+ }
+ st_case_105:
+ switch data[p] {
+ case 9:
+ goto tr131
+ case 32:
+ goto tr131
+ case 42:
+ goto tr132
+ case 95:
+ goto st97
+ case 115:
+ goto st106
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st97
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st97
+ }
+ default:
+ goto st97
+ }
+ goto st0
+ st106:
+ if p++; p == pe {
+ goto _test_eof106
+ }
+ st_case_106:
+ switch data[p] {
+ case 9:
+ goto tr131
+ case 32:
+ goto tr131
+ case 42:
+ goto tr132
+ case 95:
+ goto st97
+ case 116:
+ goto st107
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st97
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st97
+ }
+ default:
+ goto st97
+ }
+ goto st0
+ st107:
+ if p++; p == pe {
+ goto _test_eof107
+ }
+ st_case_107:
+ switch data[p] {
+ case 9:
+ goto tr149
+ case 32:
+ goto tr149
+ case 42:
+ goto tr132
+ case 95:
+ goto st97
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st97
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st97
+ }
+ default:
+ goto st97
+ }
+ goto st0
+tr149:
+// line 111 "parseqt.rl"
+
+ m6 = 1
+// line 111 "parseqt.rl"
+
+ m1 = p; m4 = 0
+ goto st108
+ st108:
+ if p++; p == pe {
+ goto _test_eof108
+ }
+ st_case_108:
+// line 3317 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto st108
+ case 32:
+ goto st108
+ case 42:
+ goto tr135
+ case 95:
+ goto tr151
+ case 99:
+ goto tr152
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto tr151
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto tr151
+ }
+ default:
+ goto tr151
+ }
+ goto st0
+tr166:
+// line 111 "parseqt.rl"
+
+ m2 = p; m5 = 0
+ goto st109
+tr151:
+// line 111 "parseqt.rl"
+
+ m0 = p
+// line 111 "parseqt.rl"
+
+ m2 = p; m5 = 0
+ goto st109
+ st109:
+ if p++; p == pe {
+ goto _test_eof109
+ }
+ st_case_109:
+// line 3361 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto tr153
+ case 32:
+ goto tr153
+ case 41:
+ goto tr139
+ case 42:
+ goto tr132
+ case 44:
+ goto tr139
+ case 91:
+ goto tr141
+ case 95:
+ goto st109
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st109
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st109
+ }
+ default:
+ goto st109
+ }
+ goto st0
+tr161:
+// line 111 "parseqt.rl"
+
+ m3 = p
+ goto st110
+tr153:
+// line 111 "parseqt.rl"
+
+ m1 = p; m4 = 0
+// line 111 "parseqt.rl"
+
+ m3 = p
+ goto st110
+ st110:
+ if p++; p == pe {
+ goto _test_eof110
+ }
+ st_case_110:
+// line 3409 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto st110
+ case 32:
+ goto st110
+ case 41:
+ goto tr143
+ case 42:
+ goto tr135
+ case 44:
+ goto tr143
+ case 95:
+ goto tr136
+ case 99:
+ goto tr137
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto tr136
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto tr136
+ }
+ default:
+ goto tr136
+ }
+ goto st0
+tr137:
+// line 111 "parseqt.rl"
+
+ m2 = p; m5 = 0
+ goto st111
+ st111:
+ if p++; p == pe {
+ goto _test_eof111
+ }
+ st_case_111:
+// line 3449 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto tr138
+ case 32:
+ goto tr138
+ case 41:
+ goto tr139
+ case 44:
+ goto tr139
+ case 91:
+ goto tr141
+ case 95:
+ goto st100
+ case 111:
+ goto st114
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st100
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st100
+ }
+ default:
+ goto st100
+ }
+ goto st0
+tr141:
+// line 111 "parseqt.rl"
+
+ m3 = p
+ goto st112
+ st112:
+ if p++; p == pe {
+ goto _test_eof112
+ }
+ st_case_112:
+// line 3489 "parseqt.go"
+ if 48 <= data[p] && data[p] <= 57 {
+ goto tr157
+ }
+ goto st0
+tr157:
+// line 111 "parseqt.rl"
+
+ m5 = m5*10 + (int(data[p]) - '0')
+ goto st113
+ st113:
+ if p++; p == pe {
+ goto _test_eof113
+ }
+ st_case_113:
+// line 3504 "parseqt.go"
+ if data[p] == 93 {
+ goto st101
+ }
+ if 48 <= data[p] && data[p] <= 57 {
+ goto tr157
+ }
+ goto st0
+ st114:
+ if p++; p == pe {
+ goto _test_eof114
+ }
+ st_case_114:
+ switch data[p] {
+ case 9:
+ goto tr138
+ case 32:
+ goto tr138
+ case 41:
+ goto tr139
+ case 44:
+ goto tr139
+ case 91:
+ goto tr141
+ case 95:
+ goto st100
+ case 110:
+ goto st115
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st100
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st100
+ }
+ default:
+ goto st100
+ }
+ goto st0
+ st115:
+ if p++; p == pe {
+ goto _test_eof115
+ }
+ st_case_115:
+ switch data[p] {
+ case 9:
+ goto tr138
+ case 32:
+ goto tr138
+ case 41:
+ goto tr139
+ case 44:
+ goto tr139
+ case 91:
+ goto tr141
+ case 95:
+ goto st100
+ case 115:
+ goto st116
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st100
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st100
+ }
+ default:
+ goto st100
+ }
+ goto st0
+ st116:
+ if p++; p == pe {
+ goto _test_eof116
+ }
+ st_case_116:
+ switch data[p] {
+ case 9:
+ goto tr138
+ case 32:
+ goto tr138
+ case 41:
+ goto tr139
+ case 44:
+ goto tr139
+ case 91:
+ goto tr141
+ case 95:
+ goto st100
+ case 116:
+ goto st117
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st100
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st100
+ }
+ default:
+ goto st100
+ }
+ goto st0
+ st117:
+ if p++; p == pe {
+ goto _test_eof117
+ }
+ st_case_117:
+ switch data[p] {
+ case 9:
+ goto tr161
+ case 32:
+ goto tr161
+ case 41:
+ goto tr139
+ case 42:
+ goto tr135
+ case 44:
+ goto tr139
+ case 91:
+ goto tr141
+ case 95:
+ goto tr136
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto tr136
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto tr136
+ }
+ default:
+ goto tr136
+ }
+ goto st0
+tr152:
+// line 111 "parseqt.rl"
+
+ m0 = p
+// line 111 "parseqt.rl"
+
+ m2 = p; m5 = 0
+ goto st118
+ st118:
+ if p++; p == pe {
+ goto _test_eof118
+ }
+ st_case_118:
+// line 3661 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto tr153
+ case 32:
+ goto tr153
+ case 41:
+ goto tr139
+ case 42:
+ goto tr132
+ case 44:
+ goto tr139
+ case 91:
+ goto tr141
+ case 95:
+ goto st109
+ case 111:
+ goto st119
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st109
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st109
+ }
+ default:
+ goto st109
+ }
+ goto st0
+ st119:
+ if p++; p == pe {
+ goto _test_eof119
+ }
+ st_case_119:
+ switch data[p] {
+ case 9:
+ goto tr153
+ case 32:
+ goto tr153
+ case 41:
+ goto tr139
+ case 42:
+ goto tr132
+ case 44:
+ goto tr139
+ case 91:
+ goto tr141
+ case 95:
+ goto st109
+ case 110:
+ goto st120
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st109
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st109
+ }
+ default:
+ goto st109
+ }
+ goto st0
+ st120:
+ if p++; p == pe {
+ goto _test_eof120
+ }
+ st_case_120:
+ switch data[p] {
+ case 9:
+ goto tr153
+ case 32:
+ goto tr153
+ case 41:
+ goto tr139
+ case 42:
+ goto tr132
+ case 44:
+ goto tr139
+ case 91:
+ goto tr141
+ case 95:
+ goto st109
+ case 115:
+ goto st121
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st109
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st109
+ }
+ default:
+ goto st109
+ }
+ goto st0
+ st121:
+ if p++; p == pe {
+ goto _test_eof121
+ }
+ st_case_121:
+ switch data[p] {
+ case 9:
+ goto tr153
+ case 32:
+ goto tr153
+ case 41:
+ goto tr139
+ case 42:
+ goto tr132
+ case 44:
+ goto tr139
+ case 91:
+ goto tr141
+ case 95:
+ goto st109
+ case 116:
+ goto st122
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st109
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st109
+ }
+ default:
+ goto st109
+ }
+ goto st0
+ st122:
+ if p++; p == pe {
+ goto _test_eof122
+ }
+ st_case_122:
+ switch data[p] {
+ case 9:
+ goto tr153
+ case 32:
+ goto tr153
+ case 41:
+ goto tr139
+ case 42:
+ goto tr132
+ case 44:
+ goto tr139
+ case 91:
+ goto tr141
+ case 95:
+ goto tr166
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto tr166
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto tr166
+ }
+ default:
+ goto tr166
+ }
+ goto st0
+tr129:
+// line 111 "parseqt.rl"
+
+ m0 = p
+ goto st123
+ st123:
+ if p++; p == pe {
+ goto _test_eof123
+ }
+ st_case_123:
+// line 3845 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto tr131
+ case 32:
+ goto tr131
+ case 42:
+ goto tr132
+ case 95:
+ goto st97
+ case 111:
+ goto st124
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st97
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st97
+ }
+ default:
+ goto st97
+ }
+ goto st0
+ st124:
+ if p++; p == pe {
+ goto _test_eof124
+ }
+ st_case_124:
+ switch data[p] {
+ case 9:
+ goto tr131
+ case 32:
+ goto tr131
+ case 42:
+ goto tr132
+ case 95:
+ goto st97
+ case 105:
+ goto st125
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st97
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st97
+ }
+ default:
+ goto st97
+ }
+ goto st0
+ st125:
+ if p++; p == pe {
+ goto _test_eof125
+ }
+ st_case_125:
+ switch data[p] {
+ case 9:
+ goto tr131
+ case 32:
+ goto tr131
+ case 42:
+ goto tr132
+ case 95:
+ goto st97
+ case 100:
+ goto st126
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st97
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st97
+ }
+ default:
+ goto st97
+ }
+ goto st0
+ st126:
+ if p++; p == pe {
+ goto _test_eof126
+ }
+ st_case_126:
+ switch data[p] {
+ case 9:
+ goto tr170
+ case 32:
+ goto tr170
+ case 41:
+ goto st96
+ case 42:
+ goto tr132
+ case 95:
+ goto st97
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st97
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st97
+ }
+ default:
+ goto st97
+ }
+ goto st0
+tr170:
+// line 111 "parseqt.rl"
+
+ m1 = p; m4 = 0
+ goto st127
+ st127:
+ if p++; p == pe {
+ goto _test_eof127
+ }
+ st_case_127:
+// line 3971 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto st127
+ case 32:
+ goto st127
+ case 41:
+ goto st96
+ case 42:
+ goto tr135
+ case 95:
+ goto tr136
+ case 99:
+ goto tr137
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto tr136
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto tr136
+ }
+ default:
+ goto tr136
+ }
+ goto st0
+ st128:
+ if p++; p == pe {
+ goto _test_eof128
+ }
+ st_case_128:
+ switch data[p] {
+ case 9:
+ goto tr121
+ case 32:
+ goto tr121
+ case 40:
+ goto tr122
+ case 95:
+ goto st93
+ case 111:
+ goto st129
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st93
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st93
+ }
+ default:
+ goto st93
+ }
+ goto st0
+ st129:
+ if p++; p == pe {
+ goto _test_eof129
+ }
+ st_case_129:
+ switch data[p] {
+ case 9:
+ goto tr121
+ case 32:
+ goto tr121
+ case 40:
+ goto tr122
+ case 95:
+ goto st93
+ case 110:
+ goto st130
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st93
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st93
+ }
+ default:
+ goto st93
+ }
+ goto st0
+ st130:
+ if p++; p == pe {
+ goto _test_eof130
+ }
+ st_case_130:
+ switch data[p] {
+ case 9:
+ goto tr121
+ case 32:
+ goto tr121
+ case 40:
+ goto tr122
+ case 95:
+ goto st93
+ case 115:
+ goto st131
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st93
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st93
+ }
+ default:
+ goto st93
+ }
+ goto st0
+ st131:
+ if p++; p == pe {
+ goto _test_eof131
+ }
+ st_case_131:
+ switch data[p] {
+ case 9:
+ goto tr121
+ case 32:
+ goto tr121
+ case 40:
+ goto tr122
+ case 95:
+ goto st93
+ case 116:
+ goto st132
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st93
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st93
+ }
+ default:
+ goto st93
+ }
+ goto st0
+ st132:
+ if p++; p == pe {
+ goto _test_eof132
+ }
+ st_case_132:
+ switch data[p] {
+ case 9:
+ goto tr176
+ case 32:
+ goto tr176
+ case 40:
+ goto tr122
+ case 59:
+ goto st67
+ case 95:
+ goto st93
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st93
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st93
+ }
+ default:
+ goto st93
+ }
+ goto st0
+tr176:
+// line 109 "parseqt.rl"
+
+ m3 = p; f = Func{Name: data[m2:m3], Type: data[m0:m1], Addr: m4}
+ goto st133
+ st133:
+ if p++; p == pe {
+ goto _test_eof133
+ }
+ st_case_133:
+// line 4161 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto st133
+ case 32:
+ goto st133
+ case 40:
+ goto tr124
+ case 59:
+ goto st67
+ case 123:
+ goto st73
+ }
+ goto st0
+ st134:
+ if p++; p == pe {
+ goto _test_eof134
+ }
+ st_case_134:
+ switch data[p] {
+ case 9:
+ goto st66
+ case 32:
+ goto st66
+ case 40:
+ goto st75
+ case 59:
+ goto st67
+ case 95:
+ goto st65
+ case 111:
+ goto st135
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st135:
+ if p++; p == pe {
+ goto _test_eof135
+ }
+ st_case_135:
+ switch data[p] {
+ case 9:
+ goto st66
+ case 32:
+ goto st66
+ case 40:
+ goto st75
+ case 59:
+ goto st67
+ case 95:
+ goto st65
+ case 110:
+ goto st136
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st136:
+ if p++; p == pe {
+ goto _test_eof136
+ }
+ st_case_136:
+ switch data[p] {
+ case 9:
+ goto st66
+ case 32:
+ goto st66
+ case 40:
+ goto st75
+ case 59:
+ goto st67
+ case 95:
+ goto st65
+ case 115:
+ goto st137
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st137:
+ if p++; p == pe {
+ goto _test_eof137
+ }
+ st_case_137:
+ switch data[p] {
+ case 9:
+ goto st66
+ case 32:
+ goto st66
+ case 40:
+ goto st75
+ case 59:
+ goto st67
+ case 95:
+ goto st65
+ case 116:
+ goto st138
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st138:
+ if p++; p == pe {
+ goto _test_eof138
+ }
+ st_case_138:
+ switch data[p] {
+ case 9:
+ goto st139
+ case 32:
+ goto st139
+ case 40:
+ goto st75
+ case 42:
+ goto tr87
+ case 59:
+ goto st67
+ case 95:
+ goto st65
+ case 103:
+ goto tr183
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+tr339:
+// line 107 "parseqt.rl"
+
+ m1 = p; m4 = 0
+ goto st139
+ st139:
+ if p++; p == pe {
+ goto _test_eof139
+ }
+ st_case_139:
+// line 4357 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto st139
+ case 32:
+ goto st139
+ case 42:
+ goto tr87
+ case 59:
+ goto st67
+ case 95:
+ goto st65
+ case 99:
+ goto st134
+ case 103:
+ goto tr90
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+tr183:
+// line 109 "parseqt.rl"
+
+ m2 = p
+ goto st140
+ st140:
+ if p++; p == pe {
+ goto _test_eof140
+ }
+ st_case_140:
+// line 4399 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto st66
+ case 32:
+ goto st66
+ case 40:
+ goto st75
+ case 59:
+ goto st67
+ case 95:
+ goto st65
+ case 108:
+ goto st141
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st141:
+ if p++; p == pe {
+ goto _test_eof141
+ }
+ st_case_141:
+ switch data[p] {
+ case 9:
+ goto st66
+ case 32:
+ goto st66
+ case 40:
+ goto st75
+ case 59:
+ goto st67
+ case 95:
+ goto st142
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st142
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st142
+ }
+ default:
+ goto st142
+ }
+ goto st0
+ st142:
+ if p++; p == pe {
+ goto _test_eof142
+ }
+ st_case_142:
+ switch data[p] {
+ case 9:
+ goto tr186
+ case 32:
+ goto tr186
+ case 40:
+ goto tr187
+ case 59:
+ goto st67
+ case 95:
+ goto st142
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st142
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st142
+ }
+ default:
+ goto st142
+ }
+ goto st0
+tr186:
+// line 109 "parseqt.rl"
+
+ m3 = p; f = Func{Name: data[m2:m3], Type: data[m0:m1], Addr: m4}
+ goto st143
+ st143:
+ if p++; p == pe {
+ goto _test_eof143
+ }
+ st_case_143:
+// line 4503 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto st143
+ case 32:
+ goto st143
+ case 40:
+ goto tr124
+ case 59:
+ goto st67
+ case 99:
+ goto st68
+ case 123:
+ goto st73
+ }
+ goto st0
+tr187:
+// line 109 "parseqt.rl"
+
+ m3 = p; f = Func{Name: data[m2:m3], Type: data[m0:m1], Addr: m4}
+// line 109 "parseqt.rl"
+
+ m6 = 0
+ goto st144
+ st144:
+ if p++; p == pe {
+ goto _test_eof144
+ }
+ st_case_144:
+// line 4532 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto st144
+ case 10:
+ goto st0
+ case 32:
+ goto st144
+ case 41:
+ goto st145
+ case 95:
+ goto tr191
+ case 99:
+ goto tr192
+ case 118:
+ goto tr193
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto tr191
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto tr191
+ }
+ default:
+ goto tr191
+ }
+ goto st75
+ st145:
+ if p++; p == pe {
+ goto _test_eof145
+ }
+ st_case_145:
+ switch data[p] {
+ case 9:
+ goto st145
+ case 10:
+ goto st0
+ case 32:
+ goto st145
+ case 41:
+ goto st76
+ case 59:
+ goto tr194
+ case 99:
+ goto st78
+ case 123:
+ goto st83
+ }
+ goto st75
+tr194:
+// line 1 "NONE"
+
+te = p+1
+
+// line 114 "parseqt.rl"
+
+act = 10;
+ goto st451
+ st451:
+ if p++; p == pe {
+ goto _test_eof451
+ }
+ st_case_451:
+// line 4598 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto st77
+ case 10:
+ goto tr96
+ case 32:
+ goto st77
+ case 41:
+ goto st76
+ }
+ goto st75
+tr191:
+// line 111 "parseqt.rl"
+
+ m0 = p
+ goto st146
+ st146:
+ if p++; p == pe {
+ goto _test_eof146
+ }
+ st_case_146:
+// line 4620 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto tr195
+ case 10:
+ goto st0
+ case 32:
+ goto tr195
+ case 41:
+ goto st76
+ case 42:
+ goto tr196
+ case 95:
+ goto st146
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st146
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st146
+ }
+ default:
+ goto st146
+ }
+ goto st75
+tr195:
+// line 111 "parseqt.rl"
+
+ m1 = p; m4 = 0
+ goto st147
+ st147:
+ if p++; p == pe {
+ goto _test_eof147
+ }
+ st_case_147:
+// line 4658 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto st147
+ case 10:
+ goto st0
+ case 32:
+ goto st147
+ case 41:
+ goto st76
+ case 42:
+ goto tr199
+ case 95:
+ goto tr200
+ case 99:
+ goto tr201
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto tr200
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto tr200
+ }
+ default:
+ goto tr200
+ }
+ goto st75
+tr196:
+// line 111 "parseqt.rl"
+
+ m1 = p; m4 = 0
+// line 111 "parseqt.rl"
+
+ m4++
+ goto st148
+tr199:
+// line 111 "parseqt.rl"
+
+ m4++
+ goto st148
+ st148:
+ if p++; p == pe {
+ goto _test_eof148
+ }
+ st_case_148:
+// line 4706 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto st147
+ case 10:
+ goto st0
+ case 32:
+ goto st147
+ case 41:
+ goto st76
+ case 42:
+ goto tr199
+ case 95:
+ goto tr200
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto tr200
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto tr200
+ }
+ default:
+ goto tr200
+ }
+ goto st75
+tr200:
+// line 111 "parseqt.rl"
+
+ m2 = p; m5 = 0
+ goto st149
+ st149:
+ if p++; p == pe {
+ goto _test_eof149
+ }
+ st_case_149:
+// line 4744 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto tr202
+ case 10:
+ goto st0
+ case 32:
+ goto tr202
+ case 41:
+ goto tr203
+ case 44:
+ goto tr204
+ case 91:
+ goto tr206
+ case 95:
+ goto st149
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st149
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st149
+ }
+ default:
+ goto st149
+ }
+ goto st75
+tr202:
+// line 111 "parseqt.rl"
+
+ m3 = p
+ goto st150
+ st150:
+ if p++; p == pe {
+ goto _test_eof150
+ }
+ st_case_150:
+// line 4784 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto st150
+ case 10:
+ goto st0
+ case 32:
+ goto st150
+ case 41:
+ goto tr208
+ case 44:
+ goto tr209
+ }
+ goto st75
+tr203:
+// line 111 "parseqt.rl"
+
+ m3 = p
+// line 112 "parseqt.rl"
+
+ f.Param = append(f.Param, Param{Name: data[m2:m3], Type: data[m0:m1], Addr: m4, Array: m5, Const: m6 > 0}); m6 = 0
+ goto st151
+tr208:
+// line 112 "parseqt.rl"
+
+ f.Param = append(f.Param, Param{Name: data[m2:m3], Type: data[m0:m1], Addr: m4, Array: m5, Const: m6 > 0}); m6 = 0
+ goto st151
+ st151:
+ if p++; p == pe {
+ goto _test_eof151
+ }
+ st_case_151:
+// line 4816 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto st151
+ case 10:
+ goto st0
+ case 32:
+ goto st151
+ case 41:
+ goto st76
+ case 59:
+ goto tr194
+ case 95:
+ goto tr191
+ case 99:
+ goto tr211
+ case 123:
+ goto st83
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto tr191
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto tr191
+ }
+ default:
+ goto tr191
+ }
+ goto st75
+tr211:
+// line 111 "parseqt.rl"
+
+ m0 = p
+ goto st152
+ st152:
+ if p++; p == pe {
+ goto _test_eof152
+ }
+ st_case_152:
+// line 4858 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto tr195
+ case 10:
+ goto st0
+ case 32:
+ goto tr195
+ case 41:
+ goto st76
+ case 42:
+ goto tr196
+ case 95:
+ goto st146
+ case 111:
+ goto st153
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st146
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st146
+ }
+ default:
+ goto st146
+ }
+ goto st75
+ st153:
+ if p++; p == pe {
+ goto _test_eof153
+ }
+ st_case_153:
+ switch data[p] {
+ case 9:
+ goto tr195
+ case 10:
+ goto st0
+ case 32:
+ goto tr195
+ case 41:
+ goto st76
+ case 42:
+ goto tr196
+ case 95:
+ goto st146
+ case 110:
+ goto st154
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st146
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st146
+ }
+ default:
+ goto st146
+ }
+ goto st75
+ st154:
+ if p++; p == pe {
+ goto _test_eof154
+ }
+ st_case_154:
+ switch data[p] {
+ case 9:
+ goto tr195
+ case 10:
+ goto st0
+ case 32:
+ goto tr195
+ case 41:
+ goto st76
+ case 42:
+ goto tr196
+ case 95:
+ goto st146
+ case 115:
+ goto st155
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st146
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st146
+ }
+ default:
+ goto st146
+ }
+ goto st75
+ st155:
+ if p++; p == pe {
+ goto _test_eof155
+ }
+ st_case_155:
+ switch data[p] {
+ case 9:
+ goto tr195
+ case 10:
+ goto st0
+ case 32:
+ goto tr195
+ case 41:
+ goto st76
+ case 42:
+ goto tr196
+ case 95:
+ goto st146
+ case 116:
+ goto st156
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st146
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st146
+ }
+ default:
+ goto st146
+ }
+ goto st75
+ st156:
+ if p++; p == pe {
+ goto _test_eof156
+ }
+ st_case_156:
+ switch data[p] {
+ case 9:
+ goto tr216
+ case 10:
+ goto st0
+ case 32:
+ goto tr216
+ case 41:
+ goto st76
+ case 42:
+ goto tr196
+ case 59:
+ goto st77
+ case 95:
+ goto st146
+ case 123:
+ goto st83
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st146
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st146
+ }
+ default:
+ goto st146
+ }
+ goto st75
+tr216:
+// line 111 "parseqt.rl"
+
+ m6 = 1
+// line 111 "parseqt.rl"
+
+ m1 = p; m4 = 0
+ goto st157
+ st157:
+ if p++; p == pe {
+ goto _test_eof157
+ }
+ st_case_157:
+// line 5039 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto st157
+ case 10:
+ goto st0
+ case 32:
+ goto st157
+ case 41:
+ goto st76
+ case 42:
+ goto tr199
+ case 59:
+ goto st77
+ case 95:
+ goto tr218
+ case 99:
+ goto tr219
+ case 123:
+ goto st83
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto tr218
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto tr218
+ }
+ default:
+ goto tr218
+ }
+ goto st75
+tr236:
+// line 111 "parseqt.rl"
+
+ m2 = p; m5 = 0
+ goto st158
+tr218:
+// line 111 "parseqt.rl"
+
+ m0 = p
+// line 111 "parseqt.rl"
+
+ m2 = p; m5 = 0
+ goto st158
+ st158:
+ if p++; p == pe {
+ goto _test_eof158
+ }
+ st_case_158:
+// line 5091 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto tr220
+ case 10:
+ goto st0
+ case 32:
+ goto tr220
+ case 41:
+ goto tr203
+ case 42:
+ goto tr196
+ case 44:
+ goto tr204
+ case 91:
+ goto tr206
+ case 95:
+ goto st158
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st158
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st158
+ }
+ default:
+ goto st158
+ }
+ goto st75
+tr241:
+// line 111 "parseqt.rl"
+
+ m3 = p
+ goto st159
+tr220:
+// line 111 "parseqt.rl"
+
+ m1 = p; m4 = 0
+// line 111 "parseqt.rl"
+
+ m3 = p
+ goto st159
+ st159:
+ if p++; p == pe {
+ goto _test_eof159
+ }
+ st_case_159:
+// line 5141 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto st159
+ case 10:
+ goto st0
+ case 32:
+ goto st159
+ case 41:
+ goto tr208
+ case 42:
+ goto tr199
+ case 44:
+ goto tr209
+ case 95:
+ goto tr200
+ case 99:
+ goto tr201
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto tr200
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto tr200
+ }
+ default:
+ goto tr200
+ }
+ goto st75
+tr204:
+// line 111 "parseqt.rl"
+
+ m3 = p
+// line 112 "parseqt.rl"
+
+ f.Param = append(f.Param, Param{Name: data[m2:m3], Type: data[m0:m1], Addr: m4, Array: m5, Const: m6 > 0}); m6 = 0
+ goto st160
+tr209:
+// line 112 "parseqt.rl"
+
+ f.Param = append(f.Param, Param{Name: data[m2:m3], Type: data[m0:m1], Addr: m4, Array: m5, Const: m6 > 0}); m6 = 0
+ goto st160
+ st160:
+ if p++; p == pe {
+ goto _test_eof160
+ }
+ st_case_160:
+// line 5191 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto st160
+ case 10:
+ goto st0
+ case 32:
+ goto st160
+ case 41:
+ goto st76
+ case 59:
+ goto tr224
+ case 95:
+ goto tr191
+ case 99:
+ goto tr192
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto tr191
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto tr191
+ }
+ default:
+ goto tr191
+ }
+ goto st75
+tr224:
+// line 1 "NONE"
+
+te = p+1
+
+// line 114 "parseqt.rl"
+
+act = 10;
+ goto st452
+ st452:
+ if p++; p == pe {
+ goto _test_eof452
+ }
+ st_case_452:
+// line 5235 "parseqt.go"
+ switch data[p] {
+ case 10:
+ goto tr533
+ case 41:
+ goto st76
+ }
+ goto st75
+tr192:
+// line 111 "parseqt.rl"
+
+ m0 = p
+ goto st161
+ st161:
+ if p++; p == pe {
+ goto _test_eof161
+ }
+ st_case_161:
+// line 5253 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto tr195
+ case 10:
+ goto st0
+ case 32:
+ goto tr195
+ case 41:
+ goto st76
+ case 42:
+ goto tr196
+ case 95:
+ goto st146
+ case 111:
+ goto st162
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st146
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st146
+ }
+ default:
+ goto st146
+ }
+ goto st75
+ st162:
+ if p++; p == pe {
+ goto _test_eof162
+ }
+ st_case_162:
+ switch data[p] {
+ case 9:
+ goto tr195
+ case 10:
+ goto st0
+ case 32:
+ goto tr195
+ case 41:
+ goto st76
+ case 42:
+ goto tr196
+ case 95:
+ goto st146
+ case 110:
+ goto st163
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st146
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st146
+ }
+ default:
+ goto st146
+ }
+ goto st75
+ st163:
+ if p++; p == pe {
+ goto _test_eof163
+ }
+ st_case_163:
+ switch data[p] {
+ case 9:
+ goto tr195
+ case 10:
+ goto st0
+ case 32:
+ goto tr195
+ case 41:
+ goto st76
+ case 42:
+ goto tr196
+ case 95:
+ goto st146
+ case 115:
+ goto st164
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st146
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st146
+ }
+ default:
+ goto st146
+ }
+ goto st75
+ st164:
+ if p++; p == pe {
+ goto _test_eof164
+ }
+ st_case_164:
+ switch data[p] {
+ case 9:
+ goto tr195
+ case 10:
+ goto st0
+ case 32:
+ goto tr195
+ case 41:
+ goto st76
+ case 42:
+ goto tr196
+ case 95:
+ goto st146
+ case 116:
+ goto st165
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st146
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st146
+ }
+ default:
+ goto st146
+ }
+ goto st75
+ st165:
+ if p++; p == pe {
+ goto _test_eof165
+ }
+ st_case_165:
+ switch data[p] {
+ case 9:
+ goto tr229
+ case 10:
+ goto st0
+ case 32:
+ goto tr229
+ case 41:
+ goto st76
+ case 42:
+ goto tr196
+ case 95:
+ goto st146
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st146
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st146
+ }
+ default:
+ goto st146
+ }
+ goto st75
+tr229:
+// line 111 "parseqt.rl"
+
+ m6 = 1
+// line 111 "parseqt.rl"
+
+ m1 = p; m4 = 0
+ goto st166
+ st166:
+ if p++; p == pe {
+ goto _test_eof166
+ }
+ st_case_166:
+// line 5430 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto st166
+ case 10:
+ goto st0
+ case 32:
+ goto st166
+ case 41:
+ goto st76
+ case 42:
+ goto tr199
+ case 95:
+ goto tr218
+ case 99:
+ goto tr219
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto tr218
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto tr218
+ }
+ default:
+ goto tr218
+ }
+ goto st75
+tr219:
+// line 111 "parseqt.rl"
+
+ m0 = p
+// line 111 "parseqt.rl"
+
+ m2 = p; m5 = 0
+ goto st167
+ st167:
+ if p++; p == pe {
+ goto _test_eof167
+ }
+ st_case_167:
+// line 5473 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto tr220
+ case 10:
+ goto st0
+ case 32:
+ goto tr220
+ case 41:
+ goto tr203
+ case 42:
+ goto tr196
+ case 44:
+ goto tr204
+ case 91:
+ goto tr206
+ case 95:
+ goto st158
+ case 111:
+ goto st170
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st158
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st158
+ }
+ default:
+ goto st158
+ }
+ goto st75
+tr206:
+// line 111 "parseqt.rl"
+
+ m3 = p
+ goto st168
+ st168:
+ if p++; p == pe {
+ goto _test_eof168
+ }
+ st_case_168:
+// line 5517 "parseqt.go"
+ switch data[p] {
+ case 10:
+ goto st0
+ case 41:
+ goto st76
+ }
+ if 48 <= data[p] && data[p] <= 57 {
+ goto tr232
+ }
+ goto st75
+tr232:
+// line 111 "parseqt.rl"
+
+ m5 = m5*10 + (int(data[p]) - '0')
+ goto st169
+ st169:
+ if p++; p == pe {
+ goto _test_eof169
+ }
+ st_case_169:
+// line 5538 "parseqt.go"
+ switch data[p] {
+ case 10:
+ goto st0
+ case 41:
+ goto st76
+ case 93:
+ goto st150
+ }
+ if 48 <= data[p] && data[p] <= 57 {
+ goto tr232
+ }
+ goto st75
+ st170:
+ if p++; p == pe {
+ goto _test_eof170
+ }
+ st_case_170:
+ switch data[p] {
+ case 9:
+ goto tr220
+ case 10:
+ goto st0
+ case 32:
+ goto tr220
+ case 41:
+ goto tr203
+ case 42:
+ goto tr196
+ case 44:
+ goto tr204
+ case 91:
+ goto tr206
+ case 95:
+ goto st158
+ case 110:
+ goto st171
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st158
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st158
+ }
+ default:
+ goto st158
+ }
+ goto st75
+ st171:
+ if p++; p == pe {
+ goto _test_eof171
+ }
+ st_case_171:
+ switch data[p] {
+ case 9:
+ goto tr220
+ case 10:
+ goto st0
+ case 32:
+ goto tr220
+ case 41:
+ goto tr203
+ case 42:
+ goto tr196
+ case 44:
+ goto tr204
+ case 91:
+ goto tr206
+ case 95:
+ goto st158
+ case 115:
+ goto st172
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st158
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st158
+ }
+ default:
+ goto st158
+ }
+ goto st75
+ st172:
+ if p++; p == pe {
+ goto _test_eof172
+ }
+ st_case_172:
+ switch data[p] {
+ case 9:
+ goto tr220
+ case 10:
+ goto st0
+ case 32:
+ goto tr220
+ case 41:
+ goto tr203
+ case 42:
+ goto tr196
+ case 44:
+ goto tr204
+ case 91:
+ goto tr206
+ case 95:
+ goto st158
+ case 116:
+ goto st173
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st158
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st158
+ }
+ default:
+ goto st158
+ }
+ goto st75
+ st173:
+ if p++; p == pe {
+ goto _test_eof173
+ }
+ st_case_173:
+ switch data[p] {
+ case 9:
+ goto tr220
+ case 10:
+ goto st0
+ case 32:
+ goto tr220
+ case 41:
+ goto tr203
+ case 42:
+ goto tr196
+ case 44:
+ goto tr204
+ case 91:
+ goto tr206
+ case 95:
+ goto tr236
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto tr236
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto tr236
+ }
+ default:
+ goto tr236
+ }
+ goto st75
+tr201:
+// line 111 "parseqt.rl"
+
+ m2 = p; m5 = 0
+ goto st174
+ st174:
+ if p++; p == pe {
+ goto _test_eof174
+ }
+ st_case_174:
+// line 5711 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto tr202
+ case 10:
+ goto st0
+ case 32:
+ goto tr202
+ case 41:
+ goto tr203
+ case 44:
+ goto tr204
+ case 91:
+ goto tr206
+ case 95:
+ goto st149
+ case 111:
+ goto st175
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st149
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st149
+ }
+ default:
+ goto st149
+ }
+ goto st75
+ st175:
+ if p++; p == pe {
+ goto _test_eof175
+ }
+ st_case_175:
+ switch data[p] {
+ case 9:
+ goto tr202
+ case 10:
+ goto st0
+ case 32:
+ goto tr202
+ case 41:
+ goto tr203
+ case 44:
+ goto tr204
+ case 91:
+ goto tr206
+ case 95:
+ goto st149
+ case 110:
+ goto st176
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st149
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st149
+ }
+ default:
+ goto st149
+ }
+ goto st75
+ st176:
+ if p++; p == pe {
+ goto _test_eof176
+ }
+ st_case_176:
+ switch data[p] {
+ case 9:
+ goto tr202
+ case 10:
+ goto st0
+ case 32:
+ goto tr202
+ case 41:
+ goto tr203
+ case 44:
+ goto tr204
+ case 91:
+ goto tr206
+ case 95:
+ goto st149
+ case 115:
+ goto st177
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st149
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st149
+ }
+ default:
+ goto st149
+ }
+ goto st75
+ st177:
+ if p++; p == pe {
+ goto _test_eof177
+ }
+ st_case_177:
+ switch data[p] {
+ case 9:
+ goto tr202
+ case 10:
+ goto st0
+ case 32:
+ goto tr202
+ case 41:
+ goto tr203
+ case 44:
+ goto tr204
+ case 91:
+ goto tr206
+ case 95:
+ goto st149
+ case 116:
+ goto st178
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st149
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st149
+ }
+ default:
+ goto st149
+ }
+ goto st75
+ st178:
+ if p++; p == pe {
+ goto _test_eof178
+ }
+ st_case_178:
+ switch data[p] {
+ case 9:
+ goto tr241
+ case 10:
+ goto st0
+ case 32:
+ goto tr241
+ case 41:
+ goto tr203
+ case 42:
+ goto tr199
+ case 44:
+ goto tr204
+ case 91:
+ goto tr206
+ case 95:
+ goto tr200
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto tr200
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto tr200
+ }
+ default:
+ goto tr200
+ }
+ goto st75
+tr193:
+// line 111 "parseqt.rl"
+
+ m0 = p
+ goto st179
+ st179:
+ if p++; p == pe {
+ goto _test_eof179
+ }
+ st_case_179:
+// line 5897 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto tr195
+ case 10:
+ goto st0
+ case 32:
+ goto tr195
+ case 41:
+ goto st76
+ case 42:
+ goto tr196
+ case 95:
+ goto st146
+ case 111:
+ goto st180
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st146
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st146
+ }
+ default:
+ goto st146
+ }
+ goto st75
+ st180:
+ if p++; p == pe {
+ goto _test_eof180
+ }
+ st_case_180:
+ switch data[p] {
+ case 9:
+ goto tr195
+ case 10:
+ goto st0
+ case 32:
+ goto tr195
+ case 41:
+ goto st76
+ case 42:
+ goto tr196
+ case 95:
+ goto st146
+ case 105:
+ goto st181
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st146
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st146
+ }
+ default:
+ goto st146
+ }
+ goto st75
+ st181:
+ if p++; p == pe {
+ goto _test_eof181
+ }
+ st_case_181:
+ switch data[p] {
+ case 9:
+ goto tr195
+ case 10:
+ goto st0
+ case 32:
+ goto tr195
+ case 41:
+ goto st76
+ case 42:
+ goto tr196
+ case 95:
+ goto st146
+ case 100:
+ goto st182
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st146
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st146
+ }
+ default:
+ goto st146
+ }
+ goto st75
+ st182:
+ if p++; p == pe {
+ goto _test_eof182
+ }
+ st_case_182:
+ switch data[p] {
+ case 9:
+ goto tr245
+ case 10:
+ goto st0
+ case 32:
+ goto tr245
+ case 41:
+ goto st145
+ case 42:
+ goto tr196
+ case 95:
+ goto st146
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st146
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st146
+ }
+ default:
+ goto st146
+ }
+ goto st75
+tr245:
+// line 111 "parseqt.rl"
+
+ m1 = p; m4 = 0
+ goto st183
+ st183:
+ if p++; p == pe {
+ goto _test_eof183
+ }
+ st_case_183:
+// line 6037 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto st183
+ case 10:
+ goto st0
+ case 32:
+ goto st183
+ case 41:
+ goto st145
+ case 42:
+ goto tr199
+ case 95:
+ goto tr200
+ case 99:
+ goto tr201
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto tr200
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto tr200
+ }
+ default:
+ goto tr200
+ }
+ goto st75
+tr83:
+// line 84 "parseqt.rl"
+
+ m1 = p
+ goto st184
+ st184:
+ if p++; p == pe {
+ goto _test_eof184
+ }
+ st_case_184:
+// line 6077 "parseqt.go"
+ if data[p] == 41 {
+ goto st185
+ }
+ goto st0
+ st185:
+ if p++; p == pe {
+ goto _test_eof185
+ }
+ st_case_185:
+ switch data[p] {
+ case 9:
+ goto st185
+ case 32:
+ goto st185
+ case 59:
+ goto st186
+ case 123:
+ goto st187
+ }
+ goto st0
+ st186:
+ if p++; p == pe {
+ goto _test_eof186
+ }
+ st_case_186:
+ switch data[p] {
+ case 9:
+ goto st186
+ case 10:
+ goto tr250
+ case 32:
+ goto st186
+ }
+ goto st0
+ st187:
+ if p++; p == pe {
+ goto _test_eof187
+ }
+ st_case_187:
+ if data[p] == 125 {
+ goto st186
+ }
+ goto st0
+ st188:
+ if p++; p == pe {
+ goto _test_eof188
+ }
+ st_case_188:
+ switch data[p] {
+ case 9:
+ goto st189
+ case 32:
+ goto st189
+ case 42:
+ goto tr252
+ case 95:
+ goto st188
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 58 {
+ goto st188
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st188
+ }
+ default:
+ goto st188
+ }
+ goto st0
+ st189:
+ if p++; p == pe {
+ goto _test_eof189
+ }
+ st_case_189:
+ switch data[p] {
+ case 9:
+ goto st189
+ case 32:
+ goto st189
+ case 42:
+ goto tr252
+ case 95:
+ goto st65
+ case 99:
+ goto st193
+ case 103:
+ goto st191
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+tr252:
+// line 127 "parseqt.rl"
+
+ m4++
+ goto st190
+ st190:
+ if p++; p == pe {
+ goto _test_eof190
+ }
+ st_case_190:
+// line 6191 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto st189
+ case 32:
+ goto st189
+ case 42:
+ goto tr252
+ case 95:
+ goto st65
+ case 103:
+ goto st191
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st191:
+ if p++; p == pe {
+ goto _test_eof191
+ }
+ st_case_191:
+ switch data[p] {
+ case 9:
+ goto st66
+ case 32:
+ goto st66
+ case 40:
+ goto st75
+ case 59:
+ goto st67
+ case 95:
+ goto st65
+ case 108:
+ goto st192
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st192:
+ if p++; p == pe {
+ goto _test_eof192
+ }
+ st_case_192:
+ switch data[p] {
+ case 9:
+ goto st66
+ case 32:
+ goto st66
+ case 40:
+ goto st75
+ case 59:
+ goto st67
+ case 99:
+ goto st68
+ case 123:
+ goto st73
+ }
+ goto st0
+ st193:
+ if p++; p == pe {
+ goto _test_eof193
+ }
+ st_case_193:
+ switch data[p] {
+ case 9:
+ goto st66
+ case 32:
+ goto st66
+ case 40:
+ goto st75
+ case 59:
+ goto st67
+ case 95:
+ goto st65
+ case 111:
+ goto st194
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st194:
+ if p++; p == pe {
+ goto _test_eof194
+ }
+ st_case_194:
+ switch data[p] {
+ case 9:
+ goto st66
+ case 32:
+ goto st66
+ case 40:
+ goto st75
+ case 59:
+ goto st67
+ case 95:
+ goto st65
+ case 110:
+ goto st195
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st195:
+ if p++; p == pe {
+ goto _test_eof195
+ }
+ st_case_195:
+ switch data[p] {
+ case 9:
+ goto st66
+ case 32:
+ goto st66
+ case 40:
+ goto st75
+ case 59:
+ goto st67
+ case 95:
+ goto st65
+ case 115:
+ goto st196
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st196:
+ if p++; p == pe {
+ goto _test_eof196
+ }
+ st_case_196:
+ switch data[p] {
+ case 9:
+ goto st66
+ case 32:
+ goto st66
+ case 40:
+ goto st75
+ case 59:
+ goto st67
+ case 95:
+ goto st65
+ case 116:
+ goto st197
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st197:
+ if p++; p == pe {
+ goto _test_eof197
+ }
+ st_case_197:
+ switch data[p] {
+ case 9:
+ goto st198
+ case 32:
+ goto st198
+ case 40:
+ goto st75
+ case 42:
+ goto tr252
+ case 59:
+ goto st67
+ case 95:
+ goto st65
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st198:
+ if p++; p == pe {
+ goto _test_eof198
+ }
+ st_case_198:
+ switch data[p] {
+ case 9:
+ goto st198
+ case 32:
+ goto st198
+ case 42:
+ goto tr252
+ case 59:
+ goto st67
+ case 95:
+ goto st65
+ case 99:
+ goto st193
+ case 103:
+ goto st191
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+tr67:
+// line 84 "parseqt.rl"
+
+ m0 = p
+// line 107 "parseqt.rl"
+
+ m0 = p
+ goto st199
+ st199:
+ if p++; p == pe {
+ goto _test_eof199
+ }
+ st_case_199:
+// line 6490 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto tr82
+ case 32:
+ goto tr82
+ case 40:
+ goto tr83
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 95:
+ goto st200
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st62
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st62
+ }
+ default:
+ goto st62
+ }
+ goto st0
+ st200:
+ if p++; p == pe {
+ goto _test_eof200
+ }
+ st_case_200:
+ switch data[p] {
+ case 9:
+ goto tr82
+ case 32:
+ goto tr82
+ case 40:
+ goto tr83
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 68:
+ goto st201
+ case 95:
+ goto st62
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st62
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st62
+ }
+ default:
+ goto st62
+ }
+ goto st0
+ st201:
+ if p++; p == pe {
+ goto _test_eof201
+ }
+ st_case_201:
+ switch data[p] {
+ case 9:
+ goto tr82
+ case 32:
+ goto tr82
+ case 40:
+ goto tr83
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 69:
+ goto st202
+ case 95:
+ goto st62
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st62
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st62
+ }
+ default:
+ goto st62
+ }
+ goto st0
+ st202:
+ if p++; p == pe {
+ goto _test_eof202
+ }
+ st_case_202:
+ switch data[p] {
+ case 9:
+ goto tr82
+ case 32:
+ goto tr82
+ case 40:
+ goto tr83
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 67:
+ goto st203
+ case 95:
+ goto st62
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st62
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st62
+ }
+ default:
+ goto st62
+ }
+ goto st0
+ st203:
+ if p++; p == pe {
+ goto _test_eof203
+ }
+ st_case_203:
+ switch data[p] {
+ case 9:
+ goto tr82
+ case 32:
+ goto tr82
+ case 40:
+ goto tr83
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 76:
+ goto st204
+ case 95:
+ goto st62
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st62
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st62
+ }
+ default:
+ goto st62
+ }
+ goto st0
+ st204:
+ if p++; p == pe {
+ goto _test_eof204
+ }
+ st_case_204:
+ switch data[p] {
+ case 9:
+ goto tr82
+ case 32:
+ goto tr82
+ case 40:
+ goto tr83
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 65:
+ goto st205
+ case 95:
+ goto st62
+ }
+ switch {
+ case data[p] < 66:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st62
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st62
+ }
+ default:
+ goto st62
+ }
+ goto st0
+ st205:
+ if p++; p == pe {
+ goto _test_eof205
+ }
+ st_case_205:
+ switch data[p] {
+ case 9:
+ goto tr82
+ case 32:
+ goto tr82
+ case 40:
+ goto tr83
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 82:
+ goto st206
+ case 95:
+ goto st62
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st62
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st62
+ }
+ default:
+ goto st62
+ }
+ goto st0
+ st206:
+ if p++; p == pe {
+ goto _test_eof206
+ }
+ st_case_206:
+ switch data[p] {
+ case 9:
+ goto tr82
+ case 32:
+ goto tr82
+ case 40:
+ goto tr83
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 69:
+ goto st207
+ case 95:
+ goto st62
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st62
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st62
+ }
+ default:
+ goto st62
+ }
+ goto st0
+ st207:
+ if p++; p == pe {
+ goto _test_eof207
+ }
+ st_case_207:
+ switch data[p] {
+ case 9:
+ goto tr82
+ case 32:
+ goto tr82
+ case 40:
+ goto tr83
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 95:
+ goto st208
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st62
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st62
+ }
+ default:
+ goto st62
+ }
+ goto st0
+ st208:
+ if p++; p == pe {
+ goto _test_eof208
+ }
+ st_case_208:
+ switch data[p] {
+ case 9:
+ goto tr82
+ case 32:
+ goto tr82
+ case 40:
+ goto tr83
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 70:
+ goto st209
+ case 95:
+ goto st62
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st62
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st62
+ }
+ default:
+ goto st62
+ }
+ goto st0
+ st209:
+ if p++; p == pe {
+ goto _test_eof209
+ }
+ st_case_209:
+ switch data[p] {
+ case 9:
+ goto tr82
+ case 32:
+ goto tr82
+ case 40:
+ goto tr83
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 76:
+ goto st210
+ case 95:
+ goto st62
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st62
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st62
+ }
+ default:
+ goto st62
+ }
+ goto st0
+ st210:
+ if p++; p == pe {
+ goto _test_eof210
+ }
+ st_case_210:
+ switch data[p] {
+ case 9:
+ goto tr82
+ case 32:
+ goto tr82
+ case 40:
+ goto tr83
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 65:
+ goto st211
+ case 95:
+ goto st62
+ }
+ switch {
+ case data[p] < 66:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st62
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st62
+ }
+ default:
+ goto st62
+ }
+ goto st0
+ st211:
+ if p++; p == pe {
+ goto _test_eof211
+ }
+ st_case_211:
+ switch data[p] {
+ case 9:
+ goto tr82
+ case 32:
+ goto tr82
+ case 40:
+ goto tr83
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 71:
+ goto st212
+ case 95:
+ goto st62
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st62
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st62
+ }
+ default:
+ goto st62
+ }
+ goto st0
+ st212:
+ if p++; p == pe {
+ goto _test_eof212
+ }
+ st_case_212:
+ switch data[p] {
+ case 9:
+ goto tr82
+ case 32:
+ goto tr82
+ case 40:
+ goto tr83
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 83:
+ goto st213
+ case 95:
+ goto st62
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st62
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st62
+ }
+ default:
+ goto st62
+ }
+ goto st0
+ st213:
+ if p++; p == pe {
+ goto _test_eof213
+ }
+ st_case_213:
+ switch data[p] {
+ case 9:
+ goto tr82
+ case 32:
+ goto tr82
+ case 40:
+ goto tr275
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 95:
+ goto st62
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st62
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st62
+ }
+ default:
+ goto st62
+ }
+ goto st0
+tr275:
+// line 84 "parseqt.rl"
+
+ m1 = p
+ goto st214
+ st214:
+ if p++; p == pe {
+ goto _test_eof214
+ }
+ st_case_214:
+// line 7000 "parseqt.go"
+ switch data[p] {
+ case 10:
+ goto st0
+ case 41:
+ goto st217
+ }
+ goto st215
+ st215:
+ if p++; p == pe {
+ goto _test_eof215
+ }
+ st_case_215:
+ switch data[p] {
+ case 10:
+ goto st0
+ case 41:
+ goto st216
+ }
+ goto st215
+ st216:
+ if p++; p == pe {
+ goto _test_eof216
+ }
+ st_case_216:
+ switch data[p] {
+ case 9:
+ goto st216
+ case 10:
+ goto tr279
+ case 32:
+ goto st216
+ case 41:
+ goto st216
+ }
+ goto st215
+ st217:
+ if p++; p == pe {
+ goto _test_eof217
+ }
+ st_case_217:
+ switch data[p] {
+ case 9:
+ goto st217
+ case 10:
+ goto st0
+ case 32:
+ goto st217
+ case 41:
+ goto st216
+ case 59:
+ goto st218
+ case 123:
+ goto st219
+ }
+ goto st215
+ st218:
+ if p++; p == pe {
+ goto _test_eof218
+ }
+ st_case_218:
+ switch data[p] {
+ case 9:
+ goto st218
+ case 10:
+ goto tr250
+ case 32:
+ goto st218
+ case 41:
+ goto st216
+ }
+ goto st215
+ st219:
+ if p++; p == pe {
+ goto _test_eof219
+ }
+ st_case_219:
+ switch data[p] {
+ case 10:
+ goto st0
+ case 41:
+ goto st216
+ case 125:
+ goto st218
+ }
+ goto st215
+tr68:
+// line 84 "parseqt.rl"
+
+ m0 = p
+// line 107 "parseqt.rl"
+
+ m0 = p
+ goto st220
+ st220:
+ if p++; p == pe {
+ goto _test_eof220
+ }
+ st_case_220:
+// line 7099 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto tr82
+ case 32:
+ goto tr82
+ case 40:
+ goto tr83
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 95:
+ goto st62
+ case 111:
+ goto st221
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st62
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st62
+ }
+ default:
+ goto st62
+ }
+ goto st0
+ st221:
+ if p++; p == pe {
+ goto _test_eof221
+ }
+ st_case_221:
+ switch data[p] {
+ case 9:
+ goto tr82
+ case 32:
+ goto tr82
+ case 40:
+ goto tr83
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 95:
+ goto st62
+ case 111:
+ goto st222
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st62
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st62
+ }
+ default:
+ goto st62
+ }
+ goto st0
+ st222:
+ if p++; p == pe {
+ goto _test_eof222
+ }
+ st_case_222:
+ switch data[p] {
+ case 9:
+ goto tr82
+ case 32:
+ goto tr82
+ case 40:
+ goto tr83
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 95:
+ goto st62
+ case 108:
+ goto st223
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st62
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st62
+ }
+ default:
+ goto st62
+ }
+ goto st0
+ st223:
+ if p++; p == pe {
+ goto _test_eof223
+ }
+ st_case_223:
+ switch data[p] {
+ case 9:
+ goto tr285
+ case 32:
+ goto tr285
+ case 40:
+ goto tr83
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 95:
+ goto st62
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st62
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st62
+ }
+ default:
+ goto st62
+ }
+ goto st0
+tr285:
+// line 107 "parseqt.rl"
+
+ m1 = p; m4 = 0
+ goto st224
+ st224:
+ if p++; p == pe {
+ goto _test_eof224
+ }
+ st_case_224:
+// line 7239 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto st224
+ case 32:
+ goto st224
+ case 42:
+ goto tr87
+ case 95:
+ goto st65
+ case 99:
+ goto st134
+ case 103:
+ goto tr90
+ case 105:
+ goto st225
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st225:
+ if p++; p == pe {
+ goto _test_eof225
+ }
+ st_case_225:
+ switch data[p] {
+ case 9:
+ goto st66
+ case 32:
+ goto st66
+ case 40:
+ goto st75
+ case 59:
+ goto st67
+ case 95:
+ goto st65
+ case 110:
+ goto st226
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st226:
+ if p++; p == pe {
+ goto _test_eof226
+ }
+ st_case_226:
+ switch data[p] {
+ case 9:
+ goto st66
+ case 32:
+ goto st66
+ case 40:
+ goto st75
+ case 59:
+ goto st67
+ case 95:
+ goto st65
+ case 105:
+ goto st227
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st227:
+ if p++; p == pe {
+ goto _test_eof227
+ }
+ st_case_227:
+ switch data[p] {
+ case 9:
+ goto st66
+ case 32:
+ goto st66
+ case 40:
+ goto st75
+ case 59:
+ goto st67
+ case 95:
+ goto st65
+ case 116:
+ goto st228
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st228:
+ if p++; p == pe {
+ goto _test_eof228
+ }
+ st_case_228:
+ switch data[p] {
+ case 9:
+ goto st66
+ case 32:
+ goto st66
+ case 40:
+ goto st75
+ case 59:
+ goto st67
+ case 95:
+ goto st65
+ case 105:
+ goto st229
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st229:
+ if p++; p == pe {
+ goto _test_eof229
+ }
+ st_case_229:
+ switch data[p] {
+ case 9:
+ goto st66
+ case 32:
+ goto st66
+ case 40:
+ goto st75
+ case 59:
+ goto st67
+ case 95:
+ goto st65
+ case 97:
+ goto st230
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 98 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st230:
+ if p++; p == pe {
+ goto _test_eof230
+ }
+ st_case_230:
+ switch data[p] {
+ case 9:
+ goto st66
+ case 32:
+ goto st66
+ case 40:
+ goto st75
+ case 59:
+ goto st67
+ case 95:
+ goto st65
+ case 108:
+ goto st231
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st231:
+ if p++; p == pe {
+ goto _test_eof231
+ }
+ st_case_231:
+ switch data[p] {
+ case 9:
+ goto st66
+ case 32:
+ goto st66
+ case 40:
+ goto st75
+ case 59:
+ goto st67
+ case 95:
+ goto st65
+ case 105:
+ goto st232
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st232:
+ if p++; p == pe {
+ goto _test_eof232
+ }
+ st_case_232:
+ switch data[p] {
+ case 9:
+ goto st66
+ case 32:
+ goto st66
+ case 40:
+ goto st75
+ case 59:
+ goto st67
+ case 95:
+ goto st65
+ case 122:
+ goto st233
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 121 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st233:
+ if p++; p == pe {
+ goto _test_eof233
+ }
+ st_case_233:
+ switch data[p] {
+ case 9:
+ goto st66
+ case 32:
+ goto st66
+ case 40:
+ goto st75
+ case 59:
+ goto st67
+ case 95:
+ goto st65
+ case 101:
+ goto st234
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st234:
+ if p++; p == pe {
+ goto _test_eof234
+ }
+ st_case_234:
+ switch data[p] {
+ case 9:
+ goto st66
+ case 32:
+ goto st66
+ case 40:
+ goto st75
+ case 59:
+ goto st67
+ case 79:
+ goto st235
+ case 95:
+ goto st65
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st235:
+ if p++; p == pe {
+ goto _test_eof235
+ }
+ st_case_235:
+ switch data[p] {
+ case 9:
+ goto st66
+ case 32:
+ goto st66
+ case 40:
+ goto st75
+ case 59:
+ goto st67
+ case 95:
+ goto st65
+ case 112:
+ goto st236
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st236:
+ if p++; p == pe {
+ goto _test_eof236
+ }
+ st_case_236:
+ switch data[p] {
+ case 9:
+ goto st66
+ case 32:
+ goto st66
+ case 40:
+ goto st75
+ case 59:
+ goto st67
+ case 95:
+ goto st65
+ case 101:
+ goto st237
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st237:
+ if p++; p == pe {
+ goto _test_eof237
+ }
+ st_case_237:
+ switch data[p] {
+ case 9:
+ goto st66
+ case 32:
+ goto st66
+ case 40:
+ goto st75
+ case 59:
+ goto st67
+ case 95:
+ goto st65
+ case 110:
+ goto st238
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st238:
+ if p++; p == pe {
+ goto _test_eof238
+ }
+ st_case_238:
+ switch data[p] {
+ case 9:
+ goto st66
+ case 32:
+ goto st66
+ case 40:
+ goto st75
+ case 59:
+ goto st67
+ case 71:
+ goto st239
+ case 95:
+ goto st65
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st239:
+ if p++; p == pe {
+ goto _test_eof239
+ }
+ st_case_239:
+ switch data[p] {
+ case 9:
+ goto st66
+ case 32:
+ goto st66
+ case 40:
+ goto st75
+ case 59:
+ goto st67
+ case 76:
+ goto st240
+ case 95:
+ goto st65
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st240:
+ if p++; p == pe {
+ goto _test_eof240
+ }
+ st_case_240:
+ switch data[p] {
+ case 9:
+ goto st66
+ case 32:
+ goto st66
+ case 40:
+ goto st75
+ case 59:
+ goto st67
+ case 70:
+ goto st241
+ case 95:
+ goto st65
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st241:
+ if p++; p == pe {
+ goto _test_eof241
+ }
+ st_case_241:
+ switch data[p] {
+ case 9:
+ goto st66
+ case 32:
+ goto st66
+ case 40:
+ goto st75
+ case 59:
+ goto st67
+ case 95:
+ goto st65
+ case 117:
+ goto st242
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st242:
+ if p++; p == pe {
+ goto _test_eof242
+ }
+ st_case_242:
+ switch data[p] {
+ case 9:
+ goto st66
+ case 32:
+ goto st66
+ case 40:
+ goto st75
+ case 59:
+ goto st67
+ case 95:
+ goto st65
+ case 110:
+ goto st243
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st243:
+ if p++; p == pe {
+ goto _test_eof243
+ }
+ st_case_243:
+ switch data[p] {
+ case 9:
+ goto st66
+ case 32:
+ goto st66
+ case 40:
+ goto st75
+ case 59:
+ goto st67
+ case 95:
+ goto st65
+ case 99:
+ goto st244
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st244:
+ if p++; p == pe {
+ goto _test_eof244
+ }
+ st_case_244:
+ switch data[p] {
+ case 9:
+ goto st66
+ case 32:
+ goto st66
+ case 40:
+ goto st75
+ case 59:
+ goto st67
+ case 95:
+ goto st65
+ case 116:
+ goto st245
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st245:
+ if p++; p == pe {
+ goto _test_eof245
+ }
+ st_case_245:
+ switch data[p] {
+ case 9:
+ goto st66
+ case 32:
+ goto st66
+ case 40:
+ goto st75
+ case 59:
+ goto st67
+ case 95:
+ goto st65
+ case 105:
+ goto st246
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st246:
+ if p++; p == pe {
+ goto _test_eof246
+ }
+ st_case_246:
+ switch data[p] {
+ case 9:
+ goto st66
+ case 32:
+ goto st66
+ case 40:
+ goto st75
+ case 59:
+ goto st67
+ case 95:
+ goto st65
+ case 111:
+ goto st247
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st247:
+ if p++; p == pe {
+ goto _test_eof247
+ }
+ st_case_247:
+ switch data[p] {
+ case 9:
+ goto st66
+ case 32:
+ goto st66
+ case 40:
+ goto st75
+ case 59:
+ goto st67
+ case 95:
+ goto st65
+ case 110:
+ goto st248
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st248:
+ if p++; p == pe {
+ goto _test_eof248
+ }
+ st_case_248:
+ switch data[p] {
+ case 9:
+ goto st66
+ case 32:
+ goto st66
+ case 40:
+ goto st75
+ case 59:
+ goto st67
+ case 95:
+ goto st65
+ case 115:
+ goto st249
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st249:
+ if p++; p == pe {
+ goto _test_eof249
+ }
+ st_case_249:
+ switch data[p] {
+ case 9:
+ goto st66
+ case 32:
+ goto st66
+ case 40:
+ goto st250
+ case 59:
+ goto st67
+ case 95:
+ goto st65
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st250:
+ if p++; p == pe {
+ goto _test_eof250
+ }
+ st_case_250:
+ switch data[p] {
+ case 10:
+ goto st0
+ case 41:
+ goto st251
+ }
+ goto st75
+ st251:
+ if p++; p == pe {
+ goto _test_eof251
+ }
+ st_case_251:
+ switch data[p] {
+ case 9:
+ goto st251
+ case 10:
+ goto tr315
+ case 32:
+ goto st251
+ case 41:
+ goto st251
+ case 59:
+ goto st253
+ case 99:
+ goto st254
+ case 123:
+ goto st259
+ }
+ goto st252
+ st252:
+ if p++; p == pe {
+ goto _test_eof252
+ }
+ st_case_252:
+ switch data[p] {
+ case 10:
+ goto tr315
+ case 41:
+ goto st251
+ }
+ goto st252
+ st253:
+ if p++; p == pe {
+ goto _test_eof253
+ }
+ st_case_253:
+ switch data[p] {
+ case 9:
+ goto st253
+ case 10:
+ goto tr315
+ case 32:
+ goto st253
+ case 41:
+ goto st251
+ }
+ goto st252
+ st254:
+ if p++; p == pe {
+ goto _test_eof254
+ }
+ st_case_254:
+ switch data[p] {
+ case 10:
+ goto tr315
+ case 41:
+ goto st251
+ case 111:
+ goto st255
+ }
+ goto st252
+ st255:
+ if p++; p == pe {
+ goto _test_eof255
+ }
+ st_case_255:
+ switch data[p] {
+ case 10:
+ goto tr315
+ case 41:
+ goto st251
+ case 110:
+ goto st256
+ }
+ goto st252
+ st256:
+ if p++; p == pe {
+ goto _test_eof256
+ }
+ st_case_256:
+ switch data[p] {
+ case 10:
+ goto tr315
+ case 41:
+ goto st251
+ case 115:
+ goto st257
+ }
+ goto st252
+ st257:
+ if p++; p == pe {
+ goto _test_eof257
+ }
+ st_case_257:
+ switch data[p] {
+ case 10:
+ goto tr315
+ case 41:
+ goto st251
+ case 116:
+ goto st258
+ }
+ goto st252
+ st258:
+ if p++; p == pe {
+ goto _test_eof258
+ }
+ st_case_258:
+ switch data[p] {
+ case 9:
+ goto st258
+ case 10:
+ goto tr315
+ case 32:
+ goto st258
+ case 41:
+ goto st251
+ case 59:
+ goto st253
+ case 123:
+ goto st259
+ }
+ goto st252
+ st259:
+ if p++; p == pe {
+ goto _test_eof259
+ }
+ st_case_259:
+ switch data[p] {
+ case 10:
+ goto tr315
+ case 41:
+ goto st260
+ case 125:
+ goto st261
+ }
+ goto st259
+ st260:
+ if p++; p == pe {
+ goto _test_eof260
+ }
+ st_case_260:
+ switch data[p] {
+ case 9:
+ goto st260
+ case 10:
+ goto tr315
+ case 32:
+ goto st260
+ case 41:
+ goto st260
+ case 59:
+ goto st261
+ case 99:
+ goto st262
+ case 125:
+ goto st261
+ }
+ goto st259
+ st261:
+ if p++; p == pe {
+ goto _test_eof261
+ }
+ st_case_261:
+ switch data[p] {
+ case 9:
+ goto st261
+ case 10:
+ goto tr315
+ case 32:
+ goto st261
+ case 41:
+ goto st260
+ case 125:
+ goto st261
+ }
+ goto st259
+ st262:
+ if p++; p == pe {
+ goto _test_eof262
+ }
+ st_case_262:
+ switch data[p] {
+ case 10:
+ goto tr315
+ case 41:
+ goto st260
+ case 111:
+ goto st263
+ case 125:
+ goto st261
+ }
+ goto st259
+ st263:
+ if p++; p == pe {
+ goto _test_eof263
+ }
+ st_case_263:
+ switch data[p] {
+ case 10:
+ goto tr315
+ case 41:
+ goto st260
+ case 110:
+ goto st264
+ case 125:
+ goto st261
+ }
+ goto st259
+ st264:
+ if p++; p == pe {
+ goto _test_eof264
+ }
+ st_case_264:
+ switch data[p] {
+ case 10:
+ goto tr315
+ case 41:
+ goto st260
+ case 115:
+ goto st265
+ case 125:
+ goto st261
+ }
+ goto st259
+ st265:
+ if p++; p == pe {
+ goto _test_eof265
+ }
+ st_case_265:
+ switch data[p] {
+ case 10:
+ goto tr315
+ case 41:
+ goto st260
+ case 116:
+ goto st266
+ case 125:
+ goto st261
+ }
+ goto st259
+ st266:
+ if p++; p == pe {
+ goto _test_eof266
+ }
+ st_case_266:
+ switch data[p] {
+ case 9:
+ goto st266
+ case 10:
+ goto tr315
+ case 32:
+ goto st266
+ case 41:
+ goto st260
+ case 59:
+ goto st261
+ case 125:
+ goto st261
+ }
+ goto st259
+tr69:
+// line 84 "parseqt.rl"
+
+ m0 = p
+// line 107 "parseqt.rl"
+
+ m0 = p
+ goto st267
+ st267:
+ if p++; p == pe {
+ goto _test_eof267
+ }
+ st_case_267:
+// line 8406 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto tr82
+ case 32:
+ goto tr82
+ case 40:
+ goto tr83
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 95:
+ goto st62
+ case 111:
+ goto st268
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st62
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st62
+ }
+ default:
+ goto st62
+ }
+ goto st0
+ st268:
+ if p++; p == pe {
+ goto _test_eof268
+ }
+ st_case_268:
+ switch data[p] {
+ case 9:
+ goto tr82
+ case 32:
+ goto tr82
+ case 40:
+ goto tr83
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 95:
+ goto st62
+ case 110:
+ goto st269
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st62
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st62
+ }
+ default:
+ goto st62
+ }
+ goto st0
+ st269:
+ if p++; p == pe {
+ goto _test_eof269
+ }
+ st_case_269:
+ switch data[p] {
+ case 9:
+ goto tr82
+ case 32:
+ goto tr82
+ case 40:
+ goto tr83
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 95:
+ goto st62
+ case 115:
+ goto st270
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st62
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st62
+ }
+ default:
+ goto st62
+ }
+ goto st0
+ st270:
+ if p++; p == pe {
+ goto _test_eof270
+ }
+ st_case_270:
+ switch data[p] {
+ case 9:
+ goto tr82
+ case 32:
+ goto tr82
+ case 40:
+ goto tr83
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 95:
+ goto st62
+ case 116:
+ goto st271
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st62
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st62
+ }
+ default:
+ goto st62
+ }
+ goto st0
+ st271:
+ if p++; p == pe {
+ goto _test_eof271
+ }
+ st_case_271:
+ switch data[p] {
+ case 9:
+ goto tr334
+ case 32:
+ goto tr334
+ case 40:
+ goto tr83
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 95:
+ goto st62
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st62
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st62
+ }
+ default:
+ goto st62
+ }
+ goto st0
+tr334:
+// line 107 "parseqt.rl"
+
+ m1 = p; m4 = 0
+ goto st272
+ st272:
+ if p++; p == pe {
+ goto _test_eof272
+ }
+ st_case_272:
+// line 8580 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto st272
+ case 32:
+ goto st272
+ case 42:
+ goto tr87
+ case 58:
+ goto st188
+ case 95:
+ goto tr336
+ case 99:
+ goto tr337
+ case 103:
+ goto tr338
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto tr336
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto tr336
+ }
+ default:
+ goto tr336
+ }
+ goto st0
+tr336:
+// line 107 "parseqt.rl"
+
+ m0 = p
+ goto st273
+ st273:
+ if p++; p == pe {
+ goto _test_eof273
+ }
+ st_case_273:
+// line 8620 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto tr339
+ case 32:
+ goto tr339
+ case 40:
+ goto st75
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 59:
+ goto st67
+ case 95:
+ goto st273
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st273
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st273
+ }
+ default:
+ goto st273
+ }
+ goto st0
+tr337:
+// line 107 "parseqt.rl"
+
+ m0 = p
+ goto st274
+ st274:
+ if p++; p == pe {
+ goto _test_eof274
+ }
+ st_case_274:
+// line 8662 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto tr339
+ case 32:
+ goto tr339
+ case 40:
+ goto st75
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 59:
+ goto st67
+ case 95:
+ goto st273
+ case 111:
+ goto st275
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st273
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st273
+ }
+ default:
+ goto st273
+ }
+ goto st0
+ st275:
+ if p++; p == pe {
+ goto _test_eof275
+ }
+ st_case_275:
+ switch data[p] {
+ case 9:
+ goto tr339
+ case 32:
+ goto tr339
+ case 40:
+ goto st75
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 59:
+ goto st67
+ case 95:
+ goto st273
+ case 110:
+ goto st276
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st273
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st273
+ }
+ default:
+ goto st273
+ }
+ goto st0
+ st276:
+ if p++; p == pe {
+ goto _test_eof276
+ }
+ st_case_276:
+ switch data[p] {
+ case 9:
+ goto tr339
+ case 32:
+ goto tr339
+ case 40:
+ goto st75
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 59:
+ goto st67
+ case 95:
+ goto st273
+ case 115:
+ goto st277
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st273
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st273
+ }
+ default:
+ goto st273
+ }
+ goto st0
+ st277:
+ if p++; p == pe {
+ goto _test_eof277
+ }
+ st_case_277:
+ switch data[p] {
+ case 9:
+ goto tr339
+ case 32:
+ goto tr339
+ case 40:
+ goto st75
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 59:
+ goto st67
+ case 95:
+ goto st273
+ case 116:
+ goto st278
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st273
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st273
+ }
+ default:
+ goto st273
+ }
+ goto st0
+ st278:
+ if p++; p == pe {
+ goto _test_eof278
+ }
+ st_case_278:
+ switch data[p] {
+ case 9:
+ goto tr339
+ case 32:
+ goto tr339
+ case 40:
+ goto st75
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 59:
+ goto st67
+ case 95:
+ goto st273
+ case 103:
+ goto tr345
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st273
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st273
+ }
+ default:
+ goto st273
+ }
+ goto st0
+tr345:
+// line 109 "parseqt.rl"
+
+ m2 = p
+ goto st279
+ st279:
+ if p++; p == pe {
+ goto _test_eof279
+ }
+ st_case_279:
+// line 8858 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto tr339
+ case 32:
+ goto tr339
+ case 40:
+ goto st75
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 59:
+ goto st67
+ case 95:
+ goto st273
+ case 108:
+ goto st280
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st273
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st273
+ }
+ default:
+ goto st273
+ }
+ goto st0
+ st280:
+ if p++; p == pe {
+ goto _test_eof280
+ }
+ st_case_280:
+ switch data[p] {
+ case 9:
+ goto tr339
+ case 32:
+ goto tr339
+ case 40:
+ goto st75
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 59:
+ goto st67
+ case 95:
+ goto st281
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st281
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st281
+ }
+ default:
+ goto st281
+ }
+ goto st0
+ st281:
+ if p++; p == pe {
+ goto _test_eof281
+ }
+ st_case_281:
+ switch data[p] {
+ case 9:
+ goto tr348
+ case 32:
+ goto tr348
+ case 40:
+ goto tr187
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 59:
+ goto st67
+ case 95:
+ goto st281
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st281
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st281
+ }
+ default:
+ goto st281
+ }
+ goto st0
+tr348:
+// line 107 "parseqt.rl"
+
+ m1 = p; m4 = 0
+// line 109 "parseqt.rl"
+
+ m3 = p; f = Func{Name: data[m2:m3], Type: data[m0:m1], Addr: m4}
+ goto st282
+ st282:
+ if p++; p == pe {
+ goto _test_eof282
+ }
+ st_case_282:
+// line 8977 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto st282
+ case 32:
+ goto st282
+ case 40:
+ goto tr124
+ case 42:
+ goto tr87
+ case 59:
+ goto st67
+ case 95:
+ goto st65
+ case 99:
+ goto st134
+ case 103:
+ goto tr90
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+tr338:
+// line 107 "parseqt.rl"
+
+ m0 = p
+// line 109 "parseqt.rl"
+
+ m2 = p
+ goto st283
+ st283:
+ if p++; p == pe {
+ goto _test_eof283
+ }
+ st_case_283:
+// line 9024 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto tr339
+ case 32:
+ goto tr339
+ case 40:
+ goto st75
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 59:
+ goto st67
+ case 95:
+ goto st273
+ case 108:
+ goto st284
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st273
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st273
+ }
+ default:
+ goto st273
+ }
+ goto st0
+ st284:
+ if p++; p == pe {
+ goto _test_eof284
+ }
+ st_case_284:
+ switch data[p] {
+ case 9:
+ goto tr339
+ case 32:
+ goto tr339
+ case 40:
+ goto st75
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 59:
+ goto st67
+ case 95:
+ goto st285
+ case 99:
+ goto st287
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st285
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st285
+ }
+ default:
+ goto st285
+ }
+ goto st0
+ st285:
+ if p++; p == pe {
+ goto _test_eof285
+ }
+ st_case_285:
+ switch data[p] {
+ case 9:
+ goto tr353
+ case 32:
+ goto tr353
+ case 40:
+ goto tr122
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 95:
+ goto st285
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st285
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st285
+ }
+ default:
+ goto st285
+ }
+ goto st0
+tr353:
+// line 107 "parseqt.rl"
+
+ m1 = p; m4 = 0
+// line 109 "parseqt.rl"
+
+ m3 = p; f = Func{Name: data[m2:m3], Type: data[m0:m1], Addr: m4}
+ goto st286
+ st286:
+ if p++; p == pe {
+ goto _test_eof286
+ }
+ st_case_286:
+// line 9141 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto st286
+ case 32:
+ goto st286
+ case 40:
+ goto tr124
+ case 42:
+ goto tr87
+ case 95:
+ goto st65
+ case 99:
+ goto st134
+ case 103:
+ goto tr90
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st287:
+ if p++; p == pe {
+ goto _test_eof287
+ }
+ st_case_287:
+ switch data[p] {
+ case 9:
+ goto tr353
+ case 32:
+ goto tr353
+ case 40:
+ goto tr122
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 95:
+ goto st285
+ case 111:
+ goto st288
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st285
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st285
+ }
+ default:
+ goto st285
+ }
+ goto st0
+ st288:
+ if p++; p == pe {
+ goto _test_eof288
+ }
+ st_case_288:
+ switch data[p] {
+ case 9:
+ goto tr353
+ case 32:
+ goto tr353
+ case 40:
+ goto tr122
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 95:
+ goto st285
+ case 110:
+ goto st289
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st285
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st285
+ }
+ default:
+ goto st285
+ }
+ goto st0
+ st289:
+ if p++; p == pe {
+ goto _test_eof289
+ }
+ st_case_289:
+ switch data[p] {
+ case 9:
+ goto tr353
+ case 32:
+ goto tr353
+ case 40:
+ goto tr122
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 95:
+ goto st285
+ case 115:
+ goto st290
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st285
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st285
+ }
+ default:
+ goto st285
+ }
+ goto st0
+ st290:
+ if p++; p == pe {
+ goto _test_eof290
+ }
+ st_case_290:
+ switch data[p] {
+ case 9:
+ goto tr353
+ case 32:
+ goto tr353
+ case 40:
+ goto tr122
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 95:
+ goto st285
+ case 116:
+ goto st291
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st285
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st285
+ }
+ default:
+ goto st285
+ }
+ goto st0
+ st291:
+ if p++; p == pe {
+ goto _test_eof291
+ }
+ st_case_291:
+ switch data[p] {
+ case 9:
+ goto tr348
+ case 32:
+ goto tr348
+ case 40:
+ goto tr122
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 59:
+ goto st67
+ case 95:
+ goto st285
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st285
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st285
+ }
+ default:
+ goto st285
+ }
+ goto st0
+tr70:
+// line 84 "parseqt.rl"
+
+ m0 = p
+// line 107 "parseqt.rl"
+
+ m0 = p
+ goto st292
+ st292:
+ if p++; p == pe {
+ goto _test_eof292
+ }
+ st_case_292:
+// line 9356 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto tr82
+ case 32:
+ goto tr82
+ case 40:
+ goto tr83
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 95:
+ goto st62
+ case 110:
+ goto st293
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st62
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st62
+ }
+ default:
+ goto st62
+ }
+ goto st0
+ st293:
+ if p++; p == pe {
+ goto _test_eof293
+ }
+ st_case_293:
+ switch data[p] {
+ case 9:
+ goto tr82
+ case 32:
+ goto tr82
+ case 40:
+ goto tr83
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 95:
+ goto st62
+ case 117:
+ goto st294
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st62
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st62
+ }
+ default:
+ goto st62
+ }
+ goto st0
+ st294:
+ if p++; p == pe {
+ goto _test_eof294
+ }
+ st_case_294:
+ switch data[p] {
+ case 9:
+ goto tr82
+ case 32:
+ goto tr82
+ case 40:
+ goto tr83
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 95:
+ goto st62
+ case 109:
+ goto st295
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st62
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st62
+ }
+ default:
+ goto st62
+ }
+ goto st0
+ st295:
+ if p++; p == pe {
+ goto _test_eof295
+ }
+ st_case_295:
+ switch data[p] {
+ case 9:
+ goto tr82
+ case 32:
+ goto tr362
+ case 40:
+ goto tr83
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 95:
+ goto st62
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st62
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st62
+ }
+ default:
+ goto st62
+ }
+ goto st0
+tr362:
+// line 107 "parseqt.rl"
+
+ m1 = p; m4 = 0
+ goto st296
+ st296:
+ if p++; p == pe {
+ goto _test_eof296
+ }
+ st_case_296:
+// line 9496 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto st63
+ case 32:
+ goto st63
+ case 42:
+ goto tr87
+ case 79:
+ goto st297
+ case 95:
+ goto st65
+ case 99:
+ goto st134
+ case 103:
+ goto tr90
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st297:
+ if p++; p == pe {
+ goto _test_eof297
+ }
+ st_case_297:
+ switch data[p] {
+ case 9:
+ goto st66
+ case 32:
+ goto st66
+ case 40:
+ goto st75
+ case 59:
+ goto st67
+ case 95:
+ goto st65
+ case 112:
+ goto st298
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st298:
+ if p++; p == pe {
+ goto _test_eof298
+ }
+ st_case_298:
+ switch data[p] {
+ case 9:
+ goto st66
+ case 32:
+ goto st66
+ case 40:
+ goto st75
+ case 59:
+ goto st67
+ case 95:
+ goto st65
+ case 101:
+ goto st299
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st299:
+ if p++; p == pe {
+ goto _test_eof299
+ }
+ st_case_299:
+ switch data[p] {
+ case 9:
+ goto st66
+ case 32:
+ goto st66
+ case 40:
+ goto st75
+ case 59:
+ goto st67
+ case 95:
+ goto st65
+ case 110:
+ goto st300
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st300:
+ if p++; p == pe {
+ goto _test_eof300
+ }
+ st_case_300:
+ switch data[p] {
+ case 9:
+ goto st66
+ case 32:
+ goto st66
+ case 40:
+ goto st75
+ case 59:
+ goto st67
+ case 71:
+ goto st301
+ case 95:
+ goto st65
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st301:
+ if p++; p == pe {
+ goto _test_eof301
+ }
+ st_case_301:
+ switch data[p] {
+ case 9:
+ goto st66
+ case 32:
+ goto st66
+ case 40:
+ goto st75
+ case 59:
+ goto st67
+ case 76:
+ goto st302
+ case 95:
+ goto st65
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st302:
+ if p++; p == pe {
+ goto _test_eof302
+ }
+ st_case_302:
+ switch data[p] {
+ case 9:
+ goto st66
+ case 32:
+ goto st66
+ case 40:
+ goto st75
+ case 59:
+ goto st67
+ case 70:
+ goto st303
+ case 95:
+ goto st65
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st303:
+ if p++; p == pe {
+ goto _test_eof303
+ }
+ st_case_303:
+ switch data[p] {
+ case 9:
+ goto st66
+ case 32:
+ goto st66
+ case 40:
+ goto st75
+ case 59:
+ goto st67
+ case 95:
+ goto st65
+ case 101:
+ goto st304
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st304:
+ if p++; p == pe {
+ goto _test_eof304
+ }
+ st_case_304:
+ switch data[p] {
+ case 9:
+ goto st66
+ case 32:
+ goto st66
+ case 40:
+ goto st75
+ case 59:
+ goto st67
+ case 95:
+ goto st65
+ case 97:
+ goto st305
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 98 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st305:
+ if p++; p == pe {
+ goto _test_eof305
+ }
+ st_case_305:
+ switch data[p] {
+ case 9:
+ goto st66
+ case 32:
+ goto st66
+ case 40:
+ goto st75
+ case 59:
+ goto st67
+ case 95:
+ goto st65
+ case 116:
+ goto st306
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st306:
+ if p++; p == pe {
+ goto _test_eof306
+ }
+ st_case_306:
+ switch data[p] {
+ case 9:
+ goto st66
+ case 32:
+ goto st66
+ case 40:
+ goto st75
+ case 59:
+ goto st67
+ case 95:
+ goto st65
+ case 117:
+ goto st307
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st307:
+ if p++; p == pe {
+ goto _test_eof307
+ }
+ st_case_307:
+ switch data[p] {
+ case 9:
+ goto st66
+ case 32:
+ goto st66
+ case 40:
+ goto st75
+ case 59:
+ goto st67
+ case 95:
+ goto st65
+ case 114:
+ goto st308
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st308:
+ if p++; p == pe {
+ goto _test_eof308
+ }
+ st_case_308:
+ switch data[p] {
+ case 9:
+ goto st66
+ case 32:
+ goto st66
+ case 40:
+ goto st75
+ case 59:
+ goto st67
+ case 95:
+ goto st65
+ case 101:
+ goto st309
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st309:
+ if p++; p == pe {
+ goto _test_eof309
+ }
+ st_case_309:
+ switch data[p] {
+ case 9:
+ goto st310
+ case 10:
+ goto tr377
+ case 32:
+ goto st310
+ case 40:
+ goto st75
+ case 59:
+ goto st67
+ case 95:
+ goto st65
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st310:
+ if p++; p == pe {
+ goto _test_eof310
+ }
+ st_case_310:
+ switch data[p] {
+ case 9:
+ goto st310
+ case 10:
+ goto tr377
+ case 32:
+ goto st310
+ case 59:
+ goto st67
+ case 99:
+ goto st68
+ case 123:
+ goto st73
+ }
+ goto st0
+tr377:
+// line 47 "parseqt.rl"
+
+ curline++
+ goto st311
+ st311:
+ if p++; p == pe {
+ goto _test_eof311
+ }
+ st_case_311:
+// line 9998 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto st311
+ case 32:
+ goto st311
+ case 123:
+ goto st312
+ }
+ goto st0
+ st312:
+ if p++; p == pe {
+ goto _test_eof312
+ }
+ st_case_312:
+ switch data[p] {
+ case 9:
+ goto st312
+ case 10:
+ goto tr380
+ case 32:
+ goto st312
+ }
+ goto st0
+tr380:
+// line 47 "parseqt.rl"
+
+ curline++
+ goto st313
+ st313:
+ if p++; p == pe {
+ goto _test_eof313
+ }
+ st_case_313:
+// line 10032 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto st313
+ case 32:
+ goto st313
+ case 95:
+ goto tr382
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto tr382
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto tr382
+ }
+ default:
+ goto tr382
+ }
+ goto st0
+tr382:
+// line 122 "parseqt.rl"
+
+ m0 = p
+ goto st314
+ st314:
+ if p++; p == pe {
+ goto _test_eof314
+ }
+ st_case_314:
+// line 10064 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto tr383
+ case 32:
+ goto tr383
+ case 61:
+ goto tr385
+ case 95:
+ goto st314
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st314
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st314
+ }
+ default:
+ goto st314
+ }
+ goto st0
+tr383:
+// line 122 "parseqt.rl"
+
+ m1 = p
+ goto st315
+ st315:
+ if p++; p == pe {
+ goto _test_eof315
+ }
+ st_case_315:
+// line 10098 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto st315
+ case 32:
+ goto st315
+ case 61:
+ goto st316
+ }
+ goto st0
+tr385:
+// line 122 "parseqt.rl"
+
+ m1 = p
+ goto st316
+ st316:
+ if p++; p == pe {
+ goto _test_eof316
+ }
+ st_case_316:
+// line 10118 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto st316
+ case 32:
+ goto st316
+ case 48:
+ goto tr388
+ }
+ goto st0
+tr388:
+// line 122 "parseqt.rl"
+
+ m2 = p
+ goto st317
+ st317:
+ if p++; p == pe {
+ goto _test_eof317
+ }
+ st_case_317:
+// line 10138 "parseqt.go"
+ if data[p] == 120 {
+ goto st318
+ }
+ goto st0
+ st318:
+ if p++; p == pe {
+ goto _test_eof318
+ }
+ st_case_318:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st319
+ }
+ goto st0
+ st319:
+ if p++; p == pe {
+ goto _test_eof319
+ }
+ st_case_319:
+ switch data[p] {
+ case 9:
+ goto tr391
+ case 10:
+ goto tr392
+ case 32:
+ goto tr391
+ case 44:
+ goto tr391
+ }
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st319
+ }
+ goto st0
+tr391:
+// line 122 "parseqt.rl"
+
+ m3 = p
+ goto st320
+ st320:
+ if p++; p == pe {
+ goto _test_eof320
+ }
+ st_case_320:
+// line 10181 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto st320
+ case 10:
+ goto tr394
+ case 32:
+ goto st320
+ }
+ goto st0
+tr392:
+// line 122 "parseqt.rl"
+
+ m3 = p
+// line 123 "parseqt.rl"
+
+ header.FeatureFlags = append(header.FeatureFlags, Const{Name: data[m0:m1], Value: data[m2:m3]})
+// line 47 "parseqt.rl"
+
+ curline++
+ goto st321
+tr394:
+// line 123 "parseqt.rl"
+
+ header.FeatureFlags = append(header.FeatureFlags, Const{Name: data[m0:m1], Value: data[m2:m3]})
+// line 47 "parseqt.rl"
+
+ curline++
+ goto st321
+ st321:
+ if p++; p == pe {
+ goto _test_eof321
+ }
+ st_case_321:
+// line 10215 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto st321
+ case 32:
+ goto st321
+ case 95:
+ goto tr382
+ case 125:
+ goto st322
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto tr382
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto tr382
+ }
+ default:
+ goto tr382
+ }
+ goto st0
+ st322:
+ if p++; p == pe {
+ goto _test_eof322
+ }
+ st_case_322:
+ if data[p] == 59 {
+ goto st323
+ }
+ goto st0
+ st323:
+ if p++; p == pe {
+ goto _test_eof323
+ }
+ st_case_323:
+ if data[p] == 10 {
+ goto tr398
+ }
+ goto st0
+tr71:
+// line 84 "parseqt.rl"
+
+ m0 = p
+// line 107 "parseqt.rl"
+
+ m0 = p
+ goto st324
+ st324:
+ if p++; p == pe {
+ goto _test_eof324
+ }
+ st_case_324:
+// line 10270 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto tr82
+ case 32:
+ goto tr82
+ case 40:
+ goto tr83
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 95:
+ goto st62
+ case 114:
+ goto st325
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st62
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st62
+ }
+ default:
+ goto st62
+ }
+ goto st0
+ st325:
+ if p++; p == pe {
+ goto _test_eof325
+ }
+ st_case_325:
+ switch data[p] {
+ case 9:
+ goto tr82
+ case 32:
+ goto tr82
+ case 40:
+ goto tr83
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 95:
+ goto st62
+ case 105:
+ goto st326
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st62
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st62
+ }
+ default:
+ goto st62
+ }
+ goto st0
+ st326:
+ if p++; p == pe {
+ goto _test_eof326
+ }
+ st_case_326:
+ switch data[p] {
+ case 9:
+ goto tr82
+ case 32:
+ goto tr82
+ case 40:
+ goto tr83
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 95:
+ goto st62
+ case 101:
+ goto st327
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st62
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st62
+ }
+ default:
+ goto st62
+ }
+ goto st0
+ st327:
+ if p++; p == pe {
+ goto _test_eof327
+ }
+ st_case_327:
+ switch data[p] {
+ case 9:
+ goto tr82
+ case 32:
+ goto tr82
+ case 40:
+ goto tr83
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 95:
+ goto st62
+ case 110:
+ goto st328
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st62
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st62
+ }
+ default:
+ goto st62
+ }
+ goto st0
+ st328:
+ if p++; p == pe {
+ goto _test_eof328
+ }
+ st_case_328:
+ switch data[p] {
+ case 9:
+ goto tr82
+ case 32:
+ goto tr82
+ case 40:
+ goto tr83
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 95:
+ goto st62
+ case 100:
+ goto st329
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st62
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st62
+ }
+ default:
+ goto st62
+ }
+ goto st0
+ st329:
+ if p++; p == pe {
+ goto _test_eof329
+ }
+ st_case_329:
+ switch data[p] {
+ case 9:
+ goto tr404
+ case 32:
+ goto tr404
+ case 40:
+ goto tr83
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 95:
+ goto st62
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st62
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st62
+ }
+ default:
+ goto st62
+ }
+ goto st0
+tr404:
+// line 107 "parseqt.rl"
+
+ m1 = p; m4 = 0
+ goto st330
+ st330:
+ if p++; p == pe {
+ goto _test_eof330
+ }
+ st_case_330:
+// line 10478 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto st330
+ case 32:
+ goto st330
+ case 42:
+ goto tr87
+ case 95:
+ goto st65
+ case 99:
+ goto st331
+ case 103:
+ goto tr90
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st331:
+ if p++; p == pe {
+ goto _test_eof331
+ }
+ st_case_331:
+ switch data[p] {
+ case 9:
+ goto st66
+ case 32:
+ goto st66
+ case 40:
+ goto st75
+ case 59:
+ goto st67
+ case 95:
+ goto st65
+ case 108:
+ goto st332
+ case 111:
+ goto st135
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st332:
+ if p++; p == pe {
+ goto _test_eof332
+ }
+ st_case_332:
+ switch data[p] {
+ case 9:
+ goto st66
+ case 32:
+ goto st66
+ case 40:
+ goto st75
+ case 59:
+ goto st67
+ case 95:
+ goto st65
+ case 97:
+ goto st333
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 98 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st333:
+ if p++; p == pe {
+ goto _test_eof333
+ }
+ st_case_333:
+ switch data[p] {
+ case 9:
+ goto st66
+ case 32:
+ goto st66
+ case 40:
+ goto st75
+ case 59:
+ goto st67
+ case 95:
+ goto st65
+ case 115:
+ goto st334
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st334:
+ if p++; p == pe {
+ goto _test_eof334
+ }
+ st_case_334:
+ switch data[p] {
+ case 9:
+ goto st66
+ case 32:
+ goto st66
+ case 40:
+ goto st75
+ case 59:
+ goto st67
+ case 95:
+ goto st65
+ case 115:
+ goto st335
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st335:
+ if p++; p == pe {
+ goto _test_eof335
+ }
+ st_case_335:
+ switch data[p] {
+ case 9:
+ goto st336
+ case 32:
+ goto st336
+ case 40:
+ goto st75
+ case 59:
+ goto st67
+ case 95:
+ goto st65
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st336:
+ if p++; p == pe {
+ goto _test_eof336
+ }
+ st_case_336:
+ switch data[p] {
+ case 9:
+ goto st336
+ case 32:
+ goto st336
+ case 59:
+ goto st67
+ case 95:
+ goto st337
+ case 99:
+ goto st340
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st337
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st337
+ }
+ default:
+ goto st337
+ }
+ goto st0
+ st337:
+ if p++; p == pe {
+ goto _test_eof337
+ }
+ st_case_337:
+ switch data[p] {
+ case 9:
+ goto st338
+ case 32:
+ goto st338
+ case 59:
+ goto st339
+ case 95:
+ goto st337
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st337
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st337
+ }
+ default:
+ goto st337
+ }
+ goto st0
+ st338:
+ if p++; p == pe {
+ goto _test_eof338
+ }
+ st_case_338:
+ switch data[p] {
+ case 9:
+ goto st338
+ case 32:
+ goto st338
+ case 59:
+ goto st339
+ }
+ goto st0
+ st339:
+ if p++; p == pe {
+ goto _test_eof339
+ }
+ st_case_339:
+ switch data[p] {
+ case 9:
+ goto st339
+ case 10:
+ goto tr416
+ case 32:
+ goto st339
+ }
+ goto st0
+ st340:
+ if p++; p == pe {
+ goto _test_eof340
+ }
+ st_case_340:
+ switch data[p] {
+ case 9:
+ goto st338
+ case 32:
+ goto st338
+ case 59:
+ goto st339
+ case 95:
+ goto st337
+ case 111:
+ goto st341
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st337
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st337
+ }
+ default:
+ goto st337
+ }
+ goto st0
+ st341:
+ if p++; p == pe {
+ goto _test_eof341
+ }
+ st_case_341:
+ switch data[p] {
+ case 9:
+ goto st338
+ case 32:
+ goto st338
+ case 59:
+ goto st339
+ case 95:
+ goto st337
+ case 110:
+ goto st342
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st337
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st337
+ }
+ default:
+ goto st337
+ }
+ goto st0
+ st342:
+ if p++; p == pe {
+ goto _test_eof342
+ }
+ st_case_342:
+ switch data[p] {
+ case 9:
+ goto st338
+ case 32:
+ goto st338
+ case 59:
+ goto st339
+ case 95:
+ goto st337
+ case 115:
+ goto st343
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st337
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st337
+ }
+ default:
+ goto st337
+ }
+ goto st0
+ st343:
+ if p++; p == pe {
+ goto _test_eof343
+ }
+ st_case_343:
+ switch data[p] {
+ case 9:
+ goto st338
+ case 32:
+ goto st338
+ case 59:
+ goto st339
+ case 95:
+ goto st337
+ case 116:
+ goto st344
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st337
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st337
+ }
+ default:
+ goto st337
+ }
+ goto st0
+ st344:
+ if p++; p == pe {
+ goto _test_eof344
+ }
+ st_case_344:
+ switch data[p] {
+ case 9:
+ goto st345
+ case 32:
+ goto st345
+ case 59:
+ goto st346
+ case 95:
+ goto st337
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st337
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st337
+ }
+ default:
+ goto st337
+ }
+ goto st0
+ st345:
+ if p++; p == pe {
+ goto _test_eof345
+ }
+ st_case_345:
+ switch data[p] {
+ case 9:
+ goto st345
+ case 32:
+ goto st345
+ case 59:
+ goto st346
+ case 123:
+ goto st73
+ }
+ goto st0
+ st346:
+ if p++; p == pe {
+ goto _test_eof346
+ }
+ st_case_346:
+ switch data[p] {
+ case 9:
+ goto st346
+ case 10:
+ goto tr416
+ case 32:
+ goto st346
+ }
+ goto st0
+tr72:
+// line 84 "parseqt.rl"
+
+ m0 = p
+// line 107 "parseqt.rl"
+
+ m0 = p
+ goto st347
+ st347:
+ if p++; p == pe {
+ goto _test_eof347
+ }
+ st_case_347:
+// line 10957 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto tr82
+ case 32:
+ goto tr82
+ case 40:
+ goto tr83
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 95:
+ goto st62
+ case 114:
+ goto st348
+ case 117:
+ goto st362
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st62
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st62
+ }
+ default:
+ goto st62
+ }
+ goto st0
+ st348:
+ if p++; p == pe {
+ goto _test_eof348
+ }
+ st_case_348:
+ switch data[p] {
+ case 9:
+ goto tr82
+ case 32:
+ goto tr82
+ case 40:
+ goto tr83
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 95:
+ goto st62
+ case 105:
+ goto st349
+ case 111:
+ goto st356
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st62
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st62
+ }
+ default:
+ goto st62
+ }
+ goto st0
+ st349:
+ if p++; p == pe {
+ goto _test_eof349
+ }
+ st_case_349:
+ switch data[p] {
+ case 9:
+ goto tr82
+ case 32:
+ goto tr82
+ case 40:
+ goto tr83
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 95:
+ goto st62
+ case 118:
+ goto st350
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st62
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st62
+ }
+ default:
+ goto st62
+ }
+ goto st0
+ st350:
+ if p++; p == pe {
+ goto _test_eof350
+ }
+ st_case_350:
+ switch data[p] {
+ case 9:
+ goto tr82
+ case 32:
+ goto tr82
+ case 40:
+ goto tr83
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 95:
+ goto st62
+ case 97:
+ goto st351
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st62
+ }
+ case data[p] > 90:
+ if 98 <= data[p] && data[p] <= 122 {
+ goto st62
+ }
+ default:
+ goto st62
+ }
+ goto st0
+ st351:
+ if p++; p == pe {
+ goto _test_eof351
+ }
+ st_case_351:
+ switch data[p] {
+ case 9:
+ goto tr82
+ case 32:
+ goto tr82
+ case 40:
+ goto tr83
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 95:
+ goto st62
+ case 116:
+ goto st352
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st62
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st62
+ }
+ default:
+ goto st62
+ }
+ goto st0
+ st352:
+ if p++; p == pe {
+ goto _test_eof352
+ }
+ st_case_352:
+ switch data[p] {
+ case 9:
+ goto tr82
+ case 32:
+ goto tr82
+ case 40:
+ goto tr83
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 95:
+ goto st62
+ case 101:
+ goto st353
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st62
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st62
+ }
+ default:
+ goto st62
+ }
+ goto st0
+ st353:
+ if p++; p == pe {
+ goto _test_eof353
+ }
+ st_case_353:
+ switch data[p] {
+ case 9:
+ goto tr82
+ case 32:
+ goto tr82
+ case 40:
+ goto tr83
+ case 42:
+ goto tr84
+ case 58:
+ goto st354
+ case 95:
+ goto st62
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st62
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st62
+ }
+ default:
+ goto st62
+ }
+ goto st0
+ st354:
+ if p++; p == pe {
+ goto _test_eof354
+ }
+ st_case_354:
+ switch data[p] {
+ case 9:
+ goto st355
+ case 10:
+ goto tr433
+ case 32:
+ goto st355
+ case 42:
+ goto tr252
+ case 95:
+ goto st188
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 58 {
+ goto st188
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st188
+ }
+ default:
+ goto st188
+ }
+ goto st0
+ st355:
+ if p++; p == pe {
+ goto _test_eof355
+ }
+ st_case_355:
+ switch data[p] {
+ case 9:
+ goto st355
+ case 10:
+ goto tr433
+ case 32:
+ goto st355
+ case 42:
+ goto tr252
+ case 95:
+ goto st65
+ case 99:
+ goto st193
+ case 103:
+ goto st191
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st356:
+ if p++; p == pe {
+ goto _test_eof356
+ }
+ st_case_356:
+ switch data[p] {
+ case 9:
+ goto tr82
+ case 32:
+ goto tr82
+ case 40:
+ goto tr83
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 95:
+ goto st62
+ case 116:
+ goto st357
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st62
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st62
+ }
+ default:
+ goto st62
+ }
+ goto st0
+ st357:
+ if p++; p == pe {
+ goto _test_eof357
+ }
+ st_case_357:
+ switch data[p] {
+ case 9:
+ goto tr82
+ case 32:
+ goto tr82
+ case 40:
+ goto tr83
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 95:
+ goto st62
+ case 101:
+ goto st358
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st62
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st62
+ }
+ default:
+ goto st62
+ }
+ goto st0
+ st358:
+ if p++; p == pe {
+ goto _test_eof358
+ }
+ st_case_358:
+ switch data[p] {
+ case 9:
+ goto tr82
+ case 32:
+ goto tr82
+ case 40:
+ goto tr83
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 95:
+ goto st62
+ case 99:
+ goto st359
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st62
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st62
+ }
+ default:
+ goto st62
+ }
+ goto st0
+ st359:
+ if p++; p == pe {
+ goto _test_eof359
+ }
+ st_case_359:
+ switch data[p] {
+ case 9:
+ goto tr82
+ case 32:
+ goto tr82
+ case 40:
+ goto tr83
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 95:
+ goto st62
+ case 116:
+ goto st360
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st62
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st62
+ }
+ default:
+ goto st62
+ }
+ goto st0
+ st360:
+ if p++; p == pe {
+ goto _test_eof360
+ }
+ st_case_360:
+ switch data[p] {
+ case 9:
+ goto tr82
+ case 32:
+ goto tr82
+ case 40:
+ goto tr83
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 95:
+ goto st62
+ case 101:
+ goto st361
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st62
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st62
+ }
+ default:
+ goto st62
+ }
+ goto st0
+ st361:
+ if p++; p == pe {
+ goto _test_eof361
+ }
+ st_case_361:
+ switch data[p] {
+ case 9:
+ goto tr82
+ case 32:
+ goto tr82
+ case 40:
+ goto tr83
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 95:
+ goto st62
+ case 100:
+ goto st353
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st62
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st62
+ }
+ default:
+ goto st62
+ }
+ goto st0
+ st362:
+ if p++; p == pe {
+ goto _test_eof362
+ }
+ st_case_362:
+ switch data[p] {
+ case 9:
+ goto tr82
+ case 32:
+ goto tr82
+ case 40:
+ goto tr83
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 95:
+ goto st62
+ case 98:
+ goto st363
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st62
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st62
+ }
+ default:
+ goto st62
+ }
+ goto st0
+ st363:
+ if p++; p == pe {
+ goto _test_eof363
+ }
+ st_case_363:
+ switch data[p] {
+ case 9:
+ goto tr82
+ case 32:
+ goto tr82
+ case 40:
+ goto tr83
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 95:
+ goto st62
+ case 108:
+ goto st364
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st62
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st62
+ }
+ default:
+ goto st62
+ }
+ goto st0
+ st364:
+ if p++; p == pe {
+ goto _test_eof364
+ }
+ st_case_364:
+ switch data[p] {
+ case 9:
+ goto tr82
+ case 32:
+ goto tr82
+ case 40:
+ goto tr83
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 95:
+ goto st62
+ case 105:
+ goto st365
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st62
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st62
+ }
+ default:
+ goto st62
+ }
+ goto st0
+ st365:
+ if p++; p == pe {
+ goto _test_eof365
+ }
+ st_case_365:
+ switch data[p] {
+ case 9:
+ goto tr82
+ case 32:
+ goto tr82
+ case 40:
+ goto tr83
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 95:
+ goto st62
+ case 99:
+ goto st366
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st62
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st62
+ }
+ default:
+ goto st62
+ }
+ goto st0
+ st366:
+ if p++; p == pe {
+ goto _test_eof366
+ }
+ st_case_366:
+ switch data[p] {
+ case 9:
+ goto tr82
+ case 32:
+ goto tr82
+ case 40:
+ goto tr83
+ case 42:
+ goto tr84
+ case 58:
+ goto st367
+ case 95:
+ goto st62
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st62
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st62
+ }
+ default:
+ goto st62
+ }
+ goto st0
+ st367:
+ if p++; p == pe {
+ goto _test_eof367
+ }
+ st_case_367:
+ switch data[p] {
+ case 9:
+ goto st368
+ case 10:
+ goto tr445
+ case 32:
+ goto st368
+ case 42:
+ goto tr252
+ case 95:
+ goto st188
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 58 {
+ goto st188
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st188
+ }
+ default:
+ goto st188
+ }
+ goto st0
+ st368:
+ if p++; p == pe {
+ goto _test_eof368
+ }
+ st_case_368:
+ switch data[p] {
+ case 9:
+ goto st368
+ case 10:
+ goto tr445
+ case 32:
+ goto st368
+ case 42:
+ goto tr252
+ case 95:
+ goto st65
+ case 99:
+ goto st193
+ case 103:
+ goto st191
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+tr73:
+// line 84 "parseqt.rl"
+
+ m0 = p
+// line 107 "parseqt.rl"
+
+ m0 = p
+ goto st369
+ st369:
+ if p++; p == pe {
+ goto _test_eof369
+ }
+ st_case_369:
+// line 11706 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto tr82
+ case 32:
+ goto tr82
+ case 40:
+ goto tr83
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 95:
+ goto st62
+ case 116:
+ goto st370
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st62
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st62
+ }
+ default:
+ goto st62
+ }
+ goto st0
+ st370:
+ if p++; p == pe {
+ goto _test_eof370
+ }
+ st_case_370:
+ switch data[p] {
+ case 9:
+ goto tr82
+ case 32:
+ goto tr82
+ case 40:
+ goto tr83
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 95:
+ goto st62
+ case 97:
+ goto st371
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st62
+ }
+ case data[p] > 90:
+ if 98 <= data[p] && data[p] <= 122 {
+ goto st62
+ }
+ default:
+ goto st62
+ }
+ goto st0
+ st371:
+ if p++; p == pe {
+ goto _test_eof371
+ }
+ st_case_371:
+ switch data[p] {
+ case 9:
+ goto tr82
+ case 32:
+ goto tr82
+ case 40:
+ goto tr83
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 95:
+ goto st62
+ case 116:
+ goto st372
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st62
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st62
+ }
+ default:
+ goto st62
+ }
+ goto st0
+ st372:
+ if p++; p == pe {
+ goto _test_eof372
+ }
+ st_case_372:
+ switch data[p] {
+ case 9:
+ goto tr82
+ case 32:
+ goto tr82
+ case 40:
+ goto tr83
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 95:
+ goto st62
+ case 105:
+ goto st373
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st62
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st62
+ }
+ default:
+ goto st62
+ }
+ goto st0
+ st373:
+ if p++; p == pe {
+ goto _test_eof373
+ }
+ st_case_373:
+ switch data[p] {
+ case 9:
+ goto tr82
+ case 32:
+ goto tr82
+ case 40:
+ goto tr83
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 95:
+ goto st62
+ case 99:
+ goto st374
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st62
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st62
+ }
+ default:
+ goto st62
+ }
+ goto st0
+ st374:
+ if p++; p == pe {
+ goto _test_eof374
+ }
+ st_case_374:
+ switch data[p] {
+ case 9:
+ goto tr451
+ case 32:
+ goto tr451
+ case 40:
+ goto tr83
+ case 42:
+ goto tr84
+ case 58:
+ goto st188
+ case 95:
+ goto st62
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st62
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st62
+ }
+ default:
+ goto st62
+ }
+ goto st0
+tr451:
+// line 107 "parseqt.rl"
+
+ m1 = p; m4 = 0
+ goto st375
+ st375:
+ if p++; p == pe {
+ goto _test_eof375
+ }
+ st_case_375:
+// line 11914 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto st375
+ case 32:
+ goto st375
+ case 42:
+ goto tr87
+ case 58:
+ goto st188
+ case 95:
+ goto st376
+ case 99:
+ goto st377
+ case 103:
+ goto tr455
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st376
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st376
+ }
+ default:
+ goto st376
+ }
+ goto st0
+ st376:
+ if p++; p == pe {
+ goto _test_eof376
+ }
+ st_case_376:
+ switch data[p] {
+ case 9:
+ goto st198
+ case 32:
+ goto st198
+ case 40:
+ goto st75
+ case 42:
+ goto tr252
+ case 58:
+ goto st188
+ case 59:
+ goto st67
+ case 95:
+ goto st376
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st376
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st376
+ }
+ default:
+ goto st376
+ }
+ goto st0
+ st377:
+ if p++; p == pe {
+ goto _test_eof377
+ }
+ st_case_377:
+ switch data[p] {
+ case 9:
+ goto st198
+ case 32:
+ goto st198
+ case 40:
+ goto st75
+ case 42:
+ goto tr252
+ case 58:
+ goto st188
+ case 59:
+ goto st67
+ case 95:
+ goto st376
+ case 111:
+ goto st378
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st376
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st376
+ }
+ default:
+ goto st376
+ }
+ goto st0
+ st378:
+ if p++; p == pe {
+ goto _test_eof378
+ }
+ st_case_378:
+ switch data[p] {
+ case 9:
+ goto st198
+ case 32:
+ goto st198
+ case 40:
+ goto st75
+ case 42:
+ goto tr252
+ case 58:
+ goto st188
+ case 59:
+ goto st67
+ case 95:
+ goto st376
+ case 110:
+ goto st379
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st376
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st376
+ }
+ default:
+ goto st376
+ }
+ goto st0
+ st379:
+ if p++; p == pe {
+ goto _test_eof379
+ }
+ st_case_379:
+ switch data[p] {
+ case 9:
+ goto st198
+ case 32:
+ goto st198
+ case 40:
+ goto st75
+ case 42:
+ goto tr252
+ case 58:
+ goto st188
+ case 59:
+ goto st67
+ case 95:
+ goto st376
+ case 115:
+ goto st380
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st376
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st376
+ }
+ default:
+ goto st376
+ }
+ goto st0
+ st380:
+ if p++; p == pe {
+ goto _test_eof380
+ }
+ st_case_380:
+ switch data[p] {
+ case 9:
+ goto st198
+ case 32:
+ goto st198
+ case 40:
+ goto st75
+ case 42:
+ goto tr252
+ case 58:
+ goto st188
+ case 59:
+ goto st67
+ case 95:
+ goto st376
+ case 116:
+ goto st381
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st376
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st376
+ }
+ default:
+ goto st376
+ }
+ goto st0
+ st381:
+ if p++; p == pe {
+ goto _test_eof381
+ }
+ st_case_381:
+ switch data[p] {
+ case 9:
+ goto st382
+ case 32:
+ goto st382
+ case 40:
+ goto st75
+ case 42:
+ goto tr87
+ case 58:
+ goto st188
+ case 59:
+ goto st67
+ case 95:
+ goto st376
+ case 103:
+ goto tr461
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st376
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st376
+ }
+ default:
+ goto st376
+ }
+ goto st0
+ st382:
+ if p++; p == pe {
+ goto _test_eof382
+ }
+ st_case_382:
+ switch data[p] {
+ case 9:
+ goto st382
+ case 32:
+ goto st382
+ case 42:
+ goto tr87
+ case 58:
+ goto st188
+ case 59:
+ goto st67
+ case 95:
+ goto st376
+ case 99:
+ goto st383
+ case 103:
+ goto tr455
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st376
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st376
+ }
+ default:
+ goto st376
+ }
+ goto st0
+ st383:
+ if p++; p == pe {
+ goto _test_eof383
+ }
+ st_case_383:
+ switch data[p] {
+ case 9:
+ goto st198
+ case 32:
+ goto st198
+ case 40:
+ goto st75
+ case 42:
+ goto tr252
+ case 58:
+ goto st188
+ case 59:
+ goto st67
+ case 95:
+ goto st376
+ case 111:
+ goto st384
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st376
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st376
+ }
+ default:
+ goto st376
+ }
+ goto st0
+ st384:
+ if p++; p == pe {
+ goto _test_eof384
+ }
+ st_case_384:
+ switch data[p] {
+ case 9:
+ goto st198
+ case 32:
+ goto st198
+ case 40:
+ goto st75
+ case 42:
+ goto tr252
+ case 58:
+ goto st188
+ case 59:
+ goto st67
+ case 95:
+ goto st376
+ case 110:
+ goto st385
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st376
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st376
+ }
+ default:
+ goto st376
+ }
+ goto st0
+ st385:
+ if p++; p == pe {
+ goto _test_eof385
+ }
+ st_case_385:
+ switch data[p] {
+ case 9:
+ goto st198
+ case 32:
+ goto st198
+ case 40:
+ goto st75
+ case 42:
+ goto tr252
+ case 58:
+ goto st188
+ case 59:
+ goto st67
+ case 95:
+ goto st376
+ case 115:
+ goto st386
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st376
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st376
+ }
+ default:
+ goto st376
+ }
+ goto st0
+ st386:
+ if p++; p == pe {
+ goto _test_eof386
+ }
+ st_case_386:
+ switch data[p] {
+ case 9:
+ goto st198
+ case 32:
+ goto st198
+ case 40:
+ goto st75
+ case 42:
+ goto tr252
+ case 58:
+ goto st188
+ case 59:
+ goto st67
+ case 95:
+ goto st376
+ case 116:
+ goto st387
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st376
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st376
+ }
+ default:
+ goto st376
+ }
+ goto st0
+ st387:
+ if p++; p == pe {
+ goto _test_eof387
+ }
+ st_case_387:
+ switch data[p] {
+ case 9:
+ goto st139
+ case 32:
+ goto st139
+ case 40:
+ goto st75
+ case 42:
+ goto tr87
+ case 58:
+ goto st188
+ case 59:
+ goto st67
+ case 95:
+ goto st376
+ case 103:
+ goto tr461
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st376
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st376
+ }
+ default:
+ goto st376
+ }
+ goto st0
+tr461:
+// line 109 "parseqt.rl"
+
+ m2 = p
+ goto st388
+ st388:
+ if p++; p == pe {
+ goto _test_eof388
+ }
+ st_case_388:
+// line 12408 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto st198
+ case 32:
+ goto st198
+ case 40:
+ goto st75
+ case 42:
+ goto tr252
+ case 58:
+ goto st188
+ case 59:
+ goto st67
+ case 95:
+ goto st376
+ case 108:
+ goto st389
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st376
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st376
+ }
+ default:
+ goto st376
+ }
+ goto st0
+ st389:
+ if p++; p == pe {
+ goto _test_eof389
+ }
+ st_case_389:
+ switch data[p] {
+ case 9:
+ goto st198
+ case 32:
+ goto st198
+ case 40:
+ goto st75
+ case 42:
+ goto tr252
+ case 58:
+ goto st188
+ case 59:
+ goto st67
+ case 95:
+ goto st390
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st390
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st390
+ }
+ default:
+ goto st390
+ }
+ goto st0
+ st390:
+ if p++; p == pe {
+ goto _test_eof390
+ }
+ st_case_390:
+ switch data[p] {
+ case 9:
+ goto tr469
+ case 32:
+ goto tr469
+ case 40:
+ goto tr187
+ case 42:
+ goto tr252
+ case 58:
+ goto st188
+ case 59:
+ goto st67
+ case 95:
+ goto st390
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st390
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st390
+ }
+ default:
+ goto st390
+ }
+ goto st0
+tr469:
+// line 109 "parseqt.rl"
+
+ m3 = p; f = Func{Name: data[m2:m3], Type: data[m0:m1], Addr: m4}
+ goto st391
+ st391:
+ if p++; p == pe {
+ goto _test_eof391
+ }
+ st_case_391:
+// line 12524 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto st391
+ case 32:
+ goto st391
+ case 40:
+ goto tr124
+ case 42:
+ goto tr252
+ case 59:
+ goto st67
+ case 95:
+ goto st65
+ case 99:
+ goto st193
+ case 103:
+ goto st191
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+tr455:
+// line 109 "parseqt.rl"
+
+ m2 = p
+ goto st392
+ st392:
+ if p++; p == pe {
+ goto _test_eof392
+ }
+ st_case_392:
+// line 12568 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto st198
+ case 32:
+ goto st198
+ case 40:
+ goto st75
+ case 42:
+ goto tr252
+ case 58:
+ goto st188
+ case 59:
+ goto st67
+ case 95:
+ goto st376
+ case 108:
+ goto st393
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st376
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st376
+ }
+ default:
+ goto st376
+ }
+ goto st0
+ st393:
+ if p++; p == pe {
+ goto _test_eof393
+ }
+ st_case_393:
+ switch data[p] {
+ case 9:
+ goto st198
+ case 32:
+ goto st198
+ case 40:
+ goto st75
+ case 42:
+ goto tr252
+ case 58:
+ goto st188
+ case 59:
+ goto st67
+ case 95:
+ goto st394
+ case 99:
+ goto st396
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st394
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st394
+ }
+ default:
+ goto st394
+ }
+ goto st0
+ st394:
+ if p++; p == pe {
+ goto _test_eof394
+ }
+ st_case_394:
+ switch data[p] {
+ case 9:
+ goto tr474
+ case 32:
+ goto tr474
+ case 40:
+ goto tr122
+ case 42:
+ goto tr252
+ case 58:
+ goto st188
+ case 95:
+ goto st394
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st394
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st394
+ }
+ default:
+ goto st394
+ }
+ goto st0
+tr474:
+// line 109 "parseqt.rl"
+
+ m3 = p; f = Func{Name: data[m2:m3], Type: data[m0:m1], Addr: m4}
+ goto st395
+ st395:
+ if p++; p == pe {
+ goto _test_eof395
+ }
+ st_case_395:
+// line 12682 "parseqt.go"
+ switch data[p] {
+ case 9:
+ goto st395
+ case 32:
+ goto st395
+ case 40:
+ goto tr124
+ case 42:
+ goto tr252
+ case 95:
+ goto st65
+ case 99:
+ goto st193
+ case 103:
+ goto st191
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st65
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st65
+ }
+ default:
+ goto st65
+ }
+ goto st0
+ st396:
+ if p++; p == pe {
+ goto _test_eof396
+ }
+ st_case_396:
+ switch data[p] {
+ case 9:
+ goto tr474
+ case 32:
+ goto tr474
+ case 40:
+ goto tr122
+ case 42:
+ goto tr252
+ case 58:
+ goto st188
+ case 95:
+ goto st394
+ case 111:
+ goto st397
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st394
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st394
+ }
+ default:
+ goto st394
+ }
+ goto st0
+ st397:
+ if p++; p == pe {
+ goto _test_eof397
+ }
+ st_case_397:
+ switch data[p] {
+ case 9:
+ goto tr474
+ case 32:
+ goto tr474
+ case 40:
+ goto tr122
+ case 42:
+ goto tr252
+ case 58:
+ goto st188
+ case 95:
+ goto st394
+ case 110:
+ goto st398
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st394
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st394
+ }
+ default:
+ goto st394
+ }
+ goto st0
+ st398:
+ if p++; p == pe {
+ goto _test_eof398
+ }
+ st_case_398:
+ switch data[p] {
+ case 9:
+ goto tr474
+ case 32:
+ goto tr474
+ case 40:
+ goto tr122
+ case 42:
+ goto tr252
+ case 58:
+ goto st188
+ case 95:
+ goto st394
+ case 115:
+ goto st399
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st394
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st394
+ }
+ default:
+ goto st394
+ }
+ goto st0
+ st399:
+ if p++; p == pe {
+ goto _test_eof399
+ }
+ st_case_399:
+ switch data[p] {
+ case 9:
+ goto tr474
+ case 32:
+ goto tr474
+ case 40:
+ goto tr122
+ case 42:
+ goto tr252
+ case 58:
+ goto st188
+ case 95:
+ goto st394
+ case 116:
+ goto st400
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st394
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st394
+ }
+ default:
+ goto st394
+ }
+ goto st0
+ st400:
+ if p++; p == pe {
+ goto _test_eof400
+ }
+ st_case_400:
+ switch data[p] {
+ case 9:
+ goto tr469
+ case 32:
+ goto tr469
+ case 40:
+ goto tr122
+ case 42:
+ goto tr252
+ case 58:
+ goto st188
+ case 59:
+ goto st67
+ case 95:
+ goto st394
+ case 123:
+ goto st73
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st394
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st394
+ }
+ default:
+ goto st394
+ }
+ goto st0
+ st401:
+ if p++; p == pe {
+ goto _test_eof401
+ }
+ st_case_401:
+ switch data[p] {
+ case 9:
+ goto st401
+ case 32:
+ goto st401
+ case 59:
+ goto st402
+ }
+ goto st0
+ st402:
+ if p++; p == pe {
+ goto _test_eof402
+ }
+ st_case_402:
+ if data[p] == 10 {
+ goto tr481
+ }
+ goto st0
+ st403:
+ if p++; p == pe {
+ goto _test_eof403
+ }
+ st_case_403:
+ if data[p] == 95 {
+ goto tr482
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto tr482
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto tr482
+ }
+ default:
+ goto tr482
+ }
+ goto st0
+tr482:
+// line 84 "parseqt.rl"
+
+ m0 = p
+ goto st404
+ st404:
+ if p++; p == pe {
+ goto _test_eof404
+ }
+ st_case_404:
+// line 12938 "parseqt.go"
+ switch data[p] {
+ case 40:
+ goto tr83
+ case 95:
+ goto st404
+ }
+ switch {
+ case data[p] < 65:
+ if 48 <= data[p] && data[p] <= 57 {
+ goto st404
+ }
+ case data[p] > 90:
+ if 97 <= data[p] && data[p] <= 122 {
+ goto st404
+ }
+ default:
+ goto st404
+ }
+ goto st0
+ st405:
+ if p++; p == pe {
+ goto _test_eof405
+ }
+ st_case_405:
+ if data[p] == 105 {
+ goto st406
+ }
+ goto st0
+ st406:
+ if p++; p == pe {
+ goto _test_eof406
+ }
+ st_case_406:
+ if data[p] == 102 {
+ goto st407
+ }
+ goto st0
+ st407:
+ if p++; p == pe {
+ goto _test_eof407
+ }
+ st_case_407:
+ if data[p] == 32 {
+ goto st408
+ }
+ goto st0
+ st408:
+ if p++; p == pe {
+ goto _test_eof408
+ }
+ st_case_408:
+ if data[p] == 81 {
+ goto st409
+ }
+ goto st0
+ st409:
+ if p++; p == pe {
+ goto _test_eof409
+ }
+ st_case_409:
+ if data[p] == 84 {
+ goto st410
+ }
+ goto st0
+ st410:
+ if p++; p == pe {
+ goto _test_eof410
+ }
+ st_case_410:
+ if data[p] == 95 {
+ goto st411
+ }
+ goto st0
+ st411:
+ if p++; p == pe {
+ goto _test_eof411
+ }
+ st_case_411:
+ if data[p] == 68 {
+ goto st412
+ }
+ goto st0
+ st412:
+ if p++; p == pe {
+ goto _test_eof412
+ }
+ st_case_412:
+ if data[p] == 69 {
+ goto st413
+ }
+ goto st0
+ st413:
+ if p++; p == pe {
+ goto _test_eof413
+ }
+ st_case_413:
+ if data[p] == 80 {
+ goto st414
+ }
+ goto st0
+ st414:
+ if p++; p == pe {
+ goto _test_eof414
+ }
+ st_case_414:
+ if data[p] == 82 {
+ goto st415
+ }
+ goto st0
+ st415:
+ if p++; p == pe {
+ goto _test_eof415
+ }
+ st_case_415:
+ if data[p] == 69 {
+ goto st416
+ }
+ goto st0
+ st416:
+ if p++; p == pe {
+ goto _test_eof416
+ }
+ st_case_416:
+ if data[p] == 67 {
+ goto st417
+ }
+ goto st0
+ st417:
+ if p++; p == pe {
+ goto _test_eof417
+ }
+ st_case_417:
+ if data[p] == 65 {
+ goto st418
+ }
+ goto st0
+ st418:
+ if p++; p == pe {
+ goto _test_eof418
+ }
+ st_case_418:
+ if data[p] == 84 {
+ goto st419
+ }
+ goto st0
+ st419:
+ if p++; p == pe {
+ goto _test_eof419
+ }
+ st_case_419:
+ if data[p] == 69 {
+ goto st420
+ }
+ goto st0
+ st420:
+ if p++; p == pe {
+ goto _test_eof420
+ }
+ st_case_420:
+ if data[p] == 68 {
+ goto st421
+ }
+ goto st0
+ st421:
+ if p++; p == pe {
+ goto _test_eof421
+ }
+ st_case_421:
+ if data[p] == 95 {
+ goto st422
+ }
+ goto st0
+ st422:
+ if p++; p == pe {
+ goto _test_eof422
+ }
+ st_case_422:
+ if data[p] == 83 {
+ goto st423
+ }
+ goto st0
+ st423:
+ if p++; p == pe {
+ goto _test_eof423
+ }
+ st_case_423:
+ if data[p] == 73 {
+ goto st424
+ }
+ goto st0
+ st424:
+ if p++; p == pe {
+ goto _test_eof424
+ }
+ st_case_424:
+ if data[p] == 78 {
+ goto st425
+ }
+ goto st0
+ st425:
+ if p++; p == pe {
+ goto _test_eof425
+ }
+ st_case_425:
+ if data[p] == 67 {
+ goto st426
+ }
+ goto st0
+ st426:
+ if p++; p == pe {
+ goto _test_eof426
+ }
+ st_case_426:
+ if data[p] == 69 {
+ goto st427
+ }
+ goto st0
+ st427:
+ if p++; p == pe {
+ goto _test_eof427
+ }
+ st_case_427:
+ if data[p] == 40 {
+ goto st428
+ }
+ goto st0
+ st428:
+ if p++; p == pe {
+ goto _test_eof428
+ }
+ st_case_428:
+ if data[p] == 10 {
+ goto st0
+ }
+ goto st429
+ st429:
+ if p++; p == pe {
+ goto _test_eof429
+ }
+ st_case_429:
+ switch data[p] {
+ case 10:
+ goto st0
+ case 41:
+ goto st430
+ }
+ goto st429
+ st430:
+ if p++; p == pe {
+ goto _test_eof430
+ }
+ st_case_430:
+ switch data[p] {
+ case 9:
+ goto st430
+ case 10:
+ goto tr509
+ case 32:
+ goto st430
+ case 41:
+ goto st430
+ }
+ goto st429
+tr509:
+// line 47 "parseqt.rl"
+
+ curline++
+ goto st431
+ st431:
+ if p++; p == pe {
+ goto _test_eof431
+ }
+ st_case_431:
+// line 13212 "parseqt.go"
+ switch data[p] {
+ case 10:
+ goto tr511
+ case 35:
+ goto st440
+ }
+ goto st432
+ st432:
+ if p++; p == pe {
+ goto _test_eof432
+ }
+ st_case_432:
+ if data[p] == 10 {
+ goto tr511
+ }
+ goto st432
+tr511:
+// line 47 "parseqt.rl"
+
+ curline++
+ goto st433
+ st433:
+ if p++; p == pe {
+ goto _test_eof433
+ }
+ st_case_433:
+// line 13239 "parseqt.go"
+ if data[p] == 35 {
+ goto st434
+ }
+ goto st0
+ st434:
+ if p++; p == pe {
+ goto _test_eof434
+ }
+ st_case_434:
+ if data[p] == 101 {
+ goto st435
+ }
+ goto st0
+ st435:
+ if p++; p == pe {
+ goto _test_eof435
+ }
+ st_case_435:
+ if data[p] == 110 {
+ goto st436
+ }
+ goto st0
+ st436:
+ if p++; p == pe {
+ goto _test_eof436
+ }
+ st_case_436:
+ if data[p] == 100 {
+ goto st437
+ }
+ goto st0
+ st437:
+ if p++; p == pe {
+ goto _test_eof437
+ }
+ st_case_437:
+ if data[p] == 105 {
+ goto st438
+ }
+ goto st0
+ st438:
+ if p++; p == pe {
+ goto _test_eof438
+ }
+ st_case_438:
+ if data[p] == 102 {
+ goto st439
+ }
+ goto st0
+ st439:
+ if p++; p == pe {
+ goto _test_eof439
+ }
+ st_case_439:
+ switch data[p] {
+ case 9:
+ goto st439
+ case 10:
+ goto tr519
+ case 32:
+ goto st439
+ }
+ goto st0
+ st440:
+ if p++; p == pe {
+ goto _test_eof440
+ }
+ st_case_440:
+ switch data[p] {
+ case 10:
+ goto tr511
+ case 101:
+ goto st441
+ }
+ goto st432
+ st441:
+ if p++; p == pe {
+ goto _test_eof441
+ }
+ st_case_441:
+ switch data[p] {
+ case 10:
+ goto tr511
+ case 110:
+ goto st442
+ }
+ goto st432
+ st442:
+ if p++; p == pe {
+ goto _test_eof442
+ }
+ st_case_442:
+ switch data[p] {
+ case 10:
+ goto tr511
+ case 100:
+ goto st443
+ }
+ goto st432
+ st443:
+ if p++; p == pe {
+ goto _test_eof443
+ }
+ st_case_443:
+ switch data[p] {
+ case 10:
+ goto tr511
+ case 105:
+ goto st444
+ }
+ goto st432
+ st444:
+ if p++; p == pe {
+ goto _test_eof444
+ }
+ st_case_444:
+ switch data[p] {
+ case 10:
+ goto tr511
+ case 102:
+ goto st445
+ }
+ goto st432
+ st445:
+ if p++; p == pe {
+ goto _test_eof445
+ }
+ st_case_445:
+ if data[p] == 10 {
+ goto st0
+ }
+ goto st432
+ st_out:
+ _test_eof447: cs = 447; goto _test_eof
+ _test_eof1: cs = 1; goto _test_eof
+ _test_eof2: cs = 2; goto _test_eof
+ _test_eof3: cs = 3; goto _test_eof
+ _test_eof4: cs = 4; goto _test_eof
+ _test_eof5: cs = 5; goto _test_eof
+ _test_eof6: cs = 6; goto _test_eof
+ _test_eof7: cs = 7; goto _test_eof
+ _test_eof8: cs = 8; goto _test_eof
+ _test_eof9: cs = 9; goto _test_eof
+ _test_eof10: cs = 10; goto _test_eof
+ _test_eof11: cs = 11; goto _test_eof
+ _test_eof12: cs = 12; goto _test_eof
+ _test_eof13: cs = 13; goto _test_eof
+ _test_eof14: cs = 14; goto _test_eof
+ _test_eof15: cs = 15; goto _test_eof
+ _test_eof16: cs = 16; goto _test_eof
+ _test_eof17: cs = 17; goto _test_eof
+ _test_eof18: cs = 18; goto _test_eof
+ _test_eof19: cs = 19; goto _test_eof
+ _test_eof20: cs = 20; goto _test_eof
+ _test_eof21: cs = 21; goto _test_eof
+ _test_eof448: cs = 448; goto _test_eof
+ _test_eof22: cs = 22; goto _test_eof
+ _test_eof23: cs = 23; goto _test_eof
+ _test_eof24: cs = 24; goto _test_eof
+ _test_eof25: cs = 25; goto _test_eof
+ _test_eof26: cs = 26; goto _test_eof
+ _test_eof27: cs = 27; goto _test_eof
+ _test_eof28: cs = 28; goto _test_eof
+ _test_eof29: cs = 29; goto _test_eof
+ _test_eof30: cs = 30; goto _test_eof
+ _test_eof31: cs = 31; goto _test_eof
+ _test_eof32: cs = 32; goto _test_eof
+ _test_eof33: cs = 33; goto _test_eof
+ _test_eof34: cs = 34; goto _test_eof
+ _test_eof35: cs = 35; goto _test_eof
+ _test_eof36: cs = 36; goto _test_eof
+ _test_eof37: cs = 37; goto _test_eof
+ _test_eof38: cs = 38; goto _test_eof
+ _test_eof39: cs = 39; goto _test_eof
+ _test_eof40: cs = 40; goto _test_eof
+ _test_eof41: cs = 41; goto _test_eof
+ _test_eof42: cs = 42; goto _test_eof
+ _test_eof43: cs = 43; goto _test_eof
+ _test_eof44: cs = 44; goto _test_eof
+ _test_eof45: cs = 45; goto _test_eof
+ _test_eof46: cs = 46; goto _test_eof
+ _test_eof47: cs = 47; goto _test_eof
+ _test_eof48: cs = 48; goto _test_eof
+ _test_eof49: cs = 49; goto _test_eof
+ _test_eof50: cs = 50; goto _test_eof
+ _test_eof51: cs = 51; goto _test_eof
+ _test_eof52: cs = 52; goto _test_eof
+ _test_eof53: cs = 53; goto _test_eof
+ _test_eof54: cs = 54; goto _test_eof
+ _test_eof55: cs = 55; goto _test_eof
+ _test_eof56: cs = 56; goto _test_eof
+ _test_eof449: cs = 449; goto _test_eof
+ _test_eof57: cs = 57; goto _test_eof
+ _test_eof446: cs = 446; goto _test_eof
+ _test_eof453: cs = 453; goto _test_eof
+ _test_eof454: cs = 454; goto _test_eof
+ _test_eof450: cs = 450; goto _test_eof
+ _test_eof58: cs = 58; goto _test_eof
+ _test_eof59: cs = 59; goto _test_eof
+ _test_eof60: cs = 60; goto _test_eof
+ _test_eof61: cs = 61; goto _test_eof
+ _test_eof62: cs = 62; goto _test_eof
+ _test_eof63: cs = 63; goto _test_eof
+ _test_eof64: cs = 64; goto _test_eof
+ _test_eof65: cs = 65; goto _test_eof
+ _test_eof66: cs = 66; goto _test_eof
+ _test_eof67: cs = 67; goto _test_eof
+ _test_eof68: cs = 68; goto _test_eof
+ _test_eof69: cs = 69; goto _test_eof
+ _test_eof70: cs = 70; goto _test_eof
+ _test_eof71: cs = 71; goto _test_eof
+ _test_eof72: cs = 72; goto _test_eof
+ _test_eof73: cs = 73; goto _test_eof
+ _test_eof74: cs = 74; goto _test_eof
+ _test_eof75: cs = 75; goto _test_eof
+ _test_eof76: cs = 76; goto _test_eof
+ _test_eof77: cs = 77; goto _test_eof
+ _test_eof78: cs = 78; goto _test_eof
+ _test_eof79: cs = 79; goto _test_eof
+ _test_eof80: cs = 80; goto _test_eof
+ _test_eof81: cs = 81; goto _test_eof
+ _test_eof82: cs = 82; goto _test_eof
+ _test_eof83: cs = 83; goto _test_eof
+ _test_eof84: cs = 84; goto _test_eof
+ _test_eof85: cs = 85; goto _test_eof
+ _test_eof86: cs = 86; goto _test_eof
+ _test_eof87: cs = 87; goto _test_eof
+ _test_eof88: cs = 88; goto _test_eof
+ _test_eof89: cs = 89; goto _test_eof
+ _test_eof90: cs = 90; goto _test_eof
+ _test_eof91: cs = 91; goto _test_eof
+ _test_eof92: cs = 92; goto _test_eof
+ _test_eof93: cs = 93; goto _test_eof
+ _test_eof94: cs = 94; goto _test_eof
+ _test_eof95: cs = 95; goto _test_eof
+ _test_eof96: cs = 96; goto _test_eof
+ _test_eof97: cs = 97; goto _test_eof
+ _test_eof98: cs = 98; goto _test_eof
+ _test_eof99: cs = 99; goto _test_eof
+ _test_eof100: cs = 100; goto _test_eof
+ _test_eof101: cs = 101; goto _test_eof
+ _test_eof102: cs = 102; goto _test_eof
+ _test_eof103: cs = 103; goto _test_eof
+ _test_eof104: cs = 104; goto _test_eof
+ _test_eof105: cs = 105; goto _test_eof
+ _test_eof106: cs = 106; goto _test_eof
+ _test_eof107: cs = 107; goto _test_eof
+ _test_eof108: cs = 108; goto _test_eof
+ _test_eof109: cs = 109; goto _test_eof
+ _test_eof110: cs = 110; goto _test_eof
+ _test_eof111: cs = 111; goto _test_eof
+ _test_eof112: cs = 112; goto _test_eof
+ _test_eof113: cs = 113; goto _test_eof
+ _test_eof114: cs = 114; goto _test_eof
+ _test_eof115: cs = 115; goto _test_eof
+ _test_eof116: cs = 116; goto _test_eof
+ _test_eof117: cs = 117; goto _test_eof
+ _test_eof118: cs = 118; goto _test_eof
+ _test_eof119: cs = 119; goto _test_eof
+ _test_eof120: cs = 120; goto _test_eof
+ _test_eof121: cs = 121; goto _test_eof
+ _test_eof122: cs = 122; goto _test_eof
+ _test_eof123: cs = 123; goto _test_eof
+ _test_eof124: cs = 124; goto _test_eof
+ _test_eof125: cs = 125; goto _test_eof
+ _test_eof126: cs = 126; goto _test_eof
+ _test_eof127: cs = 127; goto _test_eof
+ _test_eof128: cs = 128; goto _test_eof
+ _test_eof129: cs = 129; goto _test_eof
+ _test_eof130: cs = 130; goto _test_eof
+ _test_eof131: cs = 131; goto _test_eof
+ _test_eof132: cs = 132; goto _test_eof
+ _test_eof133: cs = 133; goto _test_eof
+ _test_eof134: cs = 134; goto _test_eof
+ _test_eof135: cs = 135; goto _test_eof
+ _test_eof136: cs = 136; goto _test_eof
+ _test_eof137: cs = 137; goto _test_eof
+ _test_eof138: cs = 138; goto _test_eof
+ _test_eof139: cs = 139; goto _test_eof
+ _test_eof140: cs = 140; goto _test_eof
+ _test_eof141: cs = 141; goto _test_eof
+ _test_eof142: cs = 142; goto _test_eof
+ _test_eof143: cs = 143; goto _test_eof
+ _test_eof144: cs = 144; goto _test_eof
+ _test_eof145: cs = 145; goto _test_eof
+ _test_eof451: cs = 451; goto _test_eof
+ _test_eof146: cs = 146; goto _test_eof
+ _test_eof147: cs = 147; goto _test_eof
+ _test_eof148: cs = 148; goto _test_eof
+ _test_eof149: cs = 149; goto _test_eof
+ _test_eof150: cs = 150; goto _test_eof
+ _test_eof151: cs = 151; goto _test_eof
+ _test_eof152: cs = 152; goto _test_eof
+ _test_eof153: cs = 153; goto _test_eof
+ _test_eof154: cs = 154; goto _test_eof
+ _test_eof155: cs = 155; goto _test_eof
+ _test_eof156: cs = 156; goto _test_eof
+ _test_eof157: cs = 157; goto _test_eof
+ _test_eof158: cs = 158; goto _test_eof
+ _test_eof159: cs = 159; goto _test_eof
+ _test_eof160: cs = 160; goto _test_eof
+ _test_eof452: cs = 452; goto _test_eof
+ _test_eof161: cs = 161; goto _test_eof
+ _test_eof162: cs = 162; goto _test_eof
+ _test_eof163: cs = 163; goto _test_eof
+ _test_eof164: cs = 164; goto _test_eof
+ _test_eof165: cs = 165; goto _test_eof
+ _test_eof166: cs = 166; goto _test_eof
+ _test_eof167: cs = 167; goto _test_eof
+ _test_eof168: cs = 168; goto _test_eof
+ _test_eof169: cs = 169; goto _test_eof
+ _test_eof170: cs = 170; goto _test_eof
+ _test_eof171: cs = 171; goto _test_eof
+ _test_eof172: cs = 172; goto _test_eof
+ _test_eof173: cs = 173; goto _test_eof
+ _test_eof174: cs = 174; goto _test_eof
+ _test_eof175: cs = 175; goto _test_eof
+ _test_eof176: cs = 176; goto _test_eof
+ _test_eof177: cs = 177; goto _test_eof
+ _test_eof178: cs = 178; goto _test_eof
+ _test_eof179: cs = 179; goto _test_eof
+ _test_eof180: cs = 180; goto _test_eof
+ _test_eof181: cs = 181; goto _test_eof
+ _test_eof182: cs = 182; goto _test_eof
+ _test_eof183: cs = 183; goto _test_eof
+ _test_eof184: cs = 184; goto _test_eof
+ _test_eof185: cs = 185; goto _test_eof
+ _test_eof186: cs = 186; goto _test_eof
+ _test_eof187: cs = 187; goto _test_eof
+ _test_eof188: cs = 188; goto _test_eof
+ _test_eof189: cs = 189; goto _test_eof
+ _test_eof190: cs = 190; goto _test_eof
+ _test_eof191: cs = 191; goto _test_eof
+ _test_eof192: cs = 192; goto _test_eof
+ _test_eof193: cs = 193; goto _test_eof
+ _test_eof194: cs = 194; goto _test_eof
+ _test_eof195: cs = 195; goto _test_eof
+ _test_eof196: cs = 196; goto _test_eof
+ _test_eof197: cs = 197; goto _test_eof
+ _test_eof198: cs = 198; goto _test_eof
+ _test_eof199: cs = 199; goto _test_eof
+ _test_eof200: cs = 200; goto _test_eof
+ _test_eof201: cs = 201; goto _test_eof
+ _test_eof202: cs = 202; goto _test_eof
+ _test_eof203: cs = 203; goto _test_eof
+ _test_eof204: cs = 204; goto _test_eof
+ _test_eof205: cs = 205; goto _test_eof
+ _test_eof206: cs = 206; goto _test_eof
+ _test_eof207: cs = 207; goto _test_eof
+ _test_eof208: cs = 208; goto _test_eof
+ _test_eof209: cs = 209; goto _test_eof
+ _test_eof210: cs = 210; goto _test_eof
+ _test_eof211: cs = 211; goto _test_eof
+ _test_eof212: cs = 212; goto _test_eof
+ _test_eof213: cs = 213; goto _test_eof
+ _test_eof214: cs = 214; goto _test_eof
+ _test_eof215: cs = 215; goto _test_eof
+ _test_eof216: cs = 216; goto _test_eof
+ _test_eof217: cs = 217; goto _test_eof
+ _test_eof218: cs = 218; goto _test_eof
+ _test_eof219: cs = 219; goto _test_eof
+ _test_eof220: cs = 220; goto _test_eof
+ _test_eof221: cs = 221; goto _test_eof
+ _test_eof222: cs = 222; goto _test_eof
+ _test_eof223: cs = 223; goto _test_eof
+ _test_eof224: cs = 224; goto _test_eof
+ _test_eof225: cs = 225; goto _test_eof
+ _test_eof226: cs = 226; goto _test_eof
+ _test_eof227: cs = 227; goto _test_eof
+ _test_eof228: cs = 228; goto _test_eof
+ _test_eof229: cs = 229; goto _test_eof
+ _test_eof230: cs = 230; goto _test_eof
+ _test_eof231: cs = 231; goto _test_eof
+ _test_eof232: cs = 232; goto _test_eof
+ _test_eof233: cs = 233; goto _test_eof
+ _test_eof234: cs = 234; goto _test_eof
+ _test_eof235: cs = 235; goto _test_eof
+ _test_eof236: cs = 236; goto _test_eof
+ _test_eof237: cs = 237; goto _test_eof
+ _test_eof238: cs = 238; goto _test_eof
+ _test_eof239: cs = 239; goto _test_eof
+ _test_eof240: cs = 240; goto _test_eof
+ _test_eof241: cs = 241; goto _test_eof
+ _test_eof242: cs = 242; goto _test_eof
+ _test_eof243: cs = 243; goto _test_eof
+ _test_eof244: cs = 244; goto _test_eof
+ _test_eof245: cs = 245; goto _test_eof
+ _test_eof246: cs = 246; goto _test_eof
+ _test_eof247: cs = 247; goto _test_eof
+ _test_eof248: cs = 248; goto _test_eof
+ _test_eof249: cs = 249; goto _test_eof
+ _test_eof250: cs = 250; goto _test_eof
+ _test_eof251: cs = 251; goto _test_eof
+ _test_eof252: cs = 252; goto _test_eof
+ _test_eof253: cs = 253; goto _test_eof
+ _test_eof254: cs = 254; goto _test_eof
+ _test_eof255: cs = 255; goto _test_eof
+ _test_eof256: cs = 256; goto _test_eof
+ _test_eof257: cs = 257; goto _test_eof
+ _test_eof258: cs = 258; goto _test_eof
+ _test_eof259: cs = 259; goto _test_eof
+ _test_eof260: cs = 260; goto _test_eof
+ _test_eof261: cs = 261; goto _test_eof
+ _test_eof262: cs = 262; goto _test_eof
+ _test_eof263: cs = 263; goto _test_eof
+ _test_eof264: cs = 264; goto _test_eof
+ _test_eof265: cs = 265; goto _test_eof
+ _test_eof266: cs = 266; goto _test_eof
+ _test_eof267: cs = 267; goto _test_eof
+ _test_eof268: cs = 268; goto _test_eof
+ _test_eof269: cs = 269; goto _test_eof
+ _test_eof270: cs = 270; goto _test_eof
+ _test_eof271: cs = 271; goto _test_eof
+ _test_eof272: cs = 272; goto _test_eof
+ _test_eof273: cs = 273; goto _test_eof
+ _test_eof274: cs = 274; goto _test_eof
+ _test_eof275: cs = 275; goto _test_eof
+ _test_eof276: cs = 276; goto _test_eof
+ _test_eof277: cs = 277; goto _test_eof
+ _test_eof278: cs = 278; goto _test_eof
+ _test_eof279: cs = 279; goto _test_eof
+ _test_eof280: cs = 280; goto _test_eof
+ _test_eof281: cs = 281; goto _test_eof
+ _test_eof282: cs = 282; goto _test_eof
+ _test_eof283: cs = 283; goto _test_eof
+ _test_eof284: cs = 284; goto _test_eof
+ _test_eof285: cs = 285; goto _test_eof
+ _test_eof286: cs = 286; goto _test_eof
+ _test_eof287: cs = 287; goto _test_eof
+ _test_eof288: cs = 288; goto _test_eof
+ _test_eof289: cs = 289; goto _test_eof
+ _test_eof290: cs = 290; goto _test_eof
+ _test_eof291: cs = 291; goto _test_eof
+ _test_eof292: cs = 292; goto _test_eof
+ _test_eof293: cs = 293; goto _test_eof
+ _test_eof294: cs = 294; goto _test_eof
+ _test_eof295: cs = 295; goto _test_eof
+ _test_eof296: cs = 296; goto _test_eof
+ _test_eof297: cs = 297; goto _test_eof
+ _test_eof298: cs = 298; goto _test_eof
+ _test_eof299: cs = 299; goto _test_eof
+ _test_eof300: cs = 300; goto _test_eof
+ _test_eof301: cs = 301; goto _test_eof
+ _test_eof302: cs = 302; goto _test_eof
+ _test_eof303: cs = 303; goto _test_eof
+ _test_eof304: cs = 304; goto _test_eof
+ _test_eof305: cs = 305; goto _test_eof
+ _test_eof306: cs = 306; goto _test_eof
+ _test_eof307: cs = 307; goto _test_eof
+ _test_eof308: cs = 308; goto _test_eof
+ _test_eof309: cs = 309; goto _test_eof
+ _test_eof310: cs = 310; goto _test_eof
+ _test_eof311: cs = 311; goto _test_eof
+ _test_eof312: cs = 312; goto _test_eof
+ _test_eof313: cs = 313; goto _test_eof
+ _test_eof314: cs = 314; goto _test_eof
+ _test_eof315: cs = 315; goto _test_eof
+ _test_eof316: cs = 316; goto _test_eof
+ _test_eof317: cs = 317; goto _test_eof
+ _test_eof318: cs = 318; goto _test_eof
+ _test_eof319: cs = 319; goto _test_eof
+ _test_eof320: cs = 320; goto _test_eof
+ _test_eof321: cs = 321; goto _test_eof
+ _test_eof322: cs = 322; goto _test_eof
+ _test_eof323: cs = 323; goto _test_eof
+ _test_eof324: cs = 324; goto _test_eof
+ _test_eof325: cs = 325; goto _test_eof
+ _test_eof326: cs = 326; goto _test_eof
+ _test_eof327: cs = 327; goto _test_eof
+ _test_eof328: cs = 328; goto _test_eof
+ _test_eof329: cs = 329; goto _test_eof
+ _test_eof330: cs = 330; goto _test_eof
+ _test_eof331: cs = 331; goto _test_eof
+ _test_eof332: cs = 332; goto _test_eof
+ _test_eof333: cs = 333; goto _test_eof
+ _test_eof334: cs = 334; goto _test_eof
+ _test_eof335: cs = 335; goto _test_eof
+ _test_eof336: cs = 336; goto _test_eof
+ _test_eof337: cs = 337; goto _test_eof
+ _test_eof338: cs = 338; goto _test_eof
+ _test_eof339: cs = 339; goto _test_eof
+ _test_eof340: cs = 340; goto _test_eof
+ _test_eof341: cs = 341; goto _test_eof
+ _test_eof342: cs = 342; goto _test_eof
+ _test_eof343: cs = 343; goto _test_eof
+ _test_eof344: cs = 344; goto _test_eof
+ _test_eof345: cs = 345; goto _test_eof
+ _test_eof346: cs = 346; goto _test_eof
+ _test_eof347: cs = 347; goto _test_eof
+ _test_eof348: cs = 348; goto _test_eof
+ _test_eof349: cs = 349; goto _test_eof
+ _test_eof350: cs = 350; goto _test_eof
+ _test_eof351: cs = 351; goto _test_eof
+ _test_eof352: cs = 352; goto _test_eof
+ _test_eof353: cs = 353; goto _test_eof
+ _test_eof354: cs = 354; goto _test_eof
+ _test_eof355: cs = 355; goto _test_eof
+ _test_eof356: cs = 356; goto _test_eof
+ _test_eof357: cs = 357; goto _test_eof
+ _test_eof358: cs = 358; goto _test_eof
+ _test_eof359: cs = 359; goto _test_eof
+ _test_eof360: cs = 360; goto _test_eof
+ _test_eof361: cs = 361; goto _test_eof
+ _test_eof362: cs = 362; goto _test_eof
+ _test_eof363: cs = 363; goto _test_eof
+ _test_eof364: cs = 364; goto _test_eof
+ _test_eof365: cs = 365; goto _test_eof
+ _test_eof366: cs = 366; goto _test_eof
+ _test_eof367: cs = 367; goto _test_eof
+ _test_eof368: cs = 368; goto _test_eof
+ _test_eof369: cs = 369; goto _test_eof
+ _test_eof370: cs = 370; goto _test_eof
+ _test_eof371: cs = 371; goto _test_eof
+ _test_eof372: cs = 372; goto _test_eof
+ _test_eof373: cs = 373; goto _test_eof
+ _test_eof374: cs = 374; goto _test_eof
+ _test_eof375: cs = 375; goto _test_eof
+ _test_eof376: cs = 376; goto _test_eof
+ _test_eof377: cs = 377; goto _test_eof
+ _test_eof378: cs = 378; goto _test_eof
+ _test_eof379: cs = 379; goto _test_eof
+ _test_eof380: cs = 380; goto _test_eof
+ _test_eof381: cs = 381; goto _test_eof
+ _test_eof382: cs = 382; goto _test_eof
+ _test_eof383: cs = 383; goto _test_eof
+ _test_eof384: cs = 384; goto _test_eof
+ _test_eof385: cs = 385; goto _test_eof
+ _test_eof386: cs = 386; goto _test_eof
+ _test_eof387: cs = 387; goto _test_eof
+ _test_eof388: cs = 388; goto _test_eof
+ _test_eof389: cs = 389; goto _test_eof
+ _test_eof390: cs = 390; goto _test_eof
+ _test_eof391: cs = 391; goto _test_eof
+ _test_eof392: cs = 392; goto _test_eof
+ _test_eof393: cs = 393; goto _test_eof
+ _test_eof394: cs = 394; goto _test_eof
+ _test_eof395: cs = 395; goto _test_eof
+ _test_eof396: cs = 396; goto _test_eof
+ _test_eof397: cs = 397; goto _test_eof
+ _test_eof398: cs = 398; goto _test_eof
+ _test_eof399: cs = 399; goto _test_eof
+ _test_eof400: cs = 400; goto _test_eof
+ _test_eof401: cs = 401; goto _test_eof
+ _test_eof402: cs = 402; goto _test_eof
+ _test_eof403: cs = 403; goto _test_eof
+ _test_eof404: cs = 404; goto _test_eof
+ _test_eof405: cs = 405; goto _test_eof
+ _test_eof406: cs = 406; goto _test_eof
+ _test_eof407: cs = 407; goto _test_eof
+ _test_eof408: cs = 408; goto _test_eof
+ _test_eof409: cs = 409; goto _test_eof
+ _test_eof410: cs = 410; goto _test_eof
+ _test_eof411: cs = 411; goto _test_eof
+ _test_eof412: cs = 412; goto _test_eof
+ _test_eof413: cs = 413; goto _test_eof
+ _test_eof414: cs = 414; goto _test_eof
+ _test_eof415: cs = 415; goto _test_eof
+ _test_eof416: cs = 416; goto _test_eof
+ _test_eof417: cs = 417; goto _test_eof
+ _test_eof418: cs = 418; goto _test_eof
+ _test_eof419: cs = 419; goto _test_eof
+ _test_eof420: cs = 420; goto _test_eof
+ _test_eof421: cs = 421; goto _test_eof
+ _test_eof422: cs = 422; goto _test_eof
+ _test_eof423: cs = 423; goto _test_eof
+ _test_eof424: cs = 424; goto _test_eof
+ _test_eof425: cs = 425; goto _test_eof
+ _test_eof426: cs = 426; goto _test_eof
+ _test_eof427: cs = 427; goto _test_eof
+ _test_eof428: cs = 428; goto _test_eof
+ _test_eof429: cs = 429; goto _test_eof
+ _test_eof430: cs = 430; goto _test_eof
+ _test_eof431: cs = 431; goto _test_eof
+ _test_eof432: cs = 432; goto _test_eof
+ _test_eof433: cs = 433; goto _test_eof
+ _test_eof434: cs = 434; goto _test_eof
+ _test_eof435: cs = 435; goto _test_eof
+ _test_eof436: cs = 436; goto _test_eof
+ _test_eof437: cs = 437; goto _test_eof
+ _test_eof438: cs = 438; goto _test_eof
+ _test_eof439: cs = 439; goto _test_eof
+ _test_eof440: cs = 440; goto _test_eof
+ _test_eof441: cs = 441; goto _test_eof
+ _test_eof442: cs = 442; goto _test_eof
+ _test_eof443: cs = 443; goto _test_eof
+ _test_eof444: cs = 444; goto _test_eof
+ _test_eof445: cs = 445; goto _test_eof
+
+ _test_eof: {}
+ if p == eof {
+ switch cs {
+ case 448:
+ goto tr529
+ case 22:
+ goto tr24
+ case 449:
+ goto tr529
+ case 57:
+ goto tr24
+ case 75:
+ goto tr102
+ case 76:
+ goto tr102
+ case 77:
+ goto tr102
+ case 78:
+ goto tr102
+ case 79:
+ goto tr102
+ case 80:
+ goto tr102
+ case 81:
+ goto tr102
+ case 82:
+ goto tr102
+ case 83:
+ goto tr102
+ case 84:
+ goto tr102
+ case 85:
+ goto tr102
+ case 86:
+ goto tr102
+ case 87:
+ goto tr102
+ case 88:
+ goto tr102
+ case 89:
+ goto tr102
+ case 90:
+ goto tr102
+ case 451:
+ goto tr533
+ case 452:
+ goto tr533
+ }
+ }
+
+ _out: {}
+ }
+
+// line 161 "parseqt.rl"
+
+
+ if p < pe {
+ m0, m1 = p, p
+ for m0 > 0 && data[m0-1] != '\n' {
+ m0--
+ }
+ for m1 < len(data) && data[m1] != '\n' {
+ m1++
+ }
+ return fmt.Errorf("cannot parse header file:%d:%d: %s", curline, p-m0, data[m0:m1])
+ }
+
+ if foundclass == 0 {
+ return fmt.Errorf("cannot find C++ class in header file")
+ }
+ if foundclass == 1 {
+ return fmt.Errorf("cannot find end of C++ class in header file")
+ }
+ if foundclass > 2 {
+ return fmt.Errorf("found too many C++ classes in header file")
+ }
+ return nil
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/gengl/parseqt.rl b/Godeps/_workspace/src/github.com/obscuren/qml/gl/gengl/parseqt.rl
new file mode 100644
index 000000000..4aa4a1345
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/gengl/parseqt.rl
@@ -0,0 +1,184 @@
+//
+// To compile:
+//
+// ragel -Z -G2 -o parseqt.go parseqt.rl
+//
+// To show a diagram of the state machine:
+//
+// ragel -V -G2 -p -o parseqt.dot parseqt.rl
+// dot -Tsvg -o parseqt.svg parseqt.dot
+// chrome parseqt.svg
+//
+
+package main
+
+import (
+ "fmt"
+)
+
+%%{
+ machine parseqt;
+
+ write data;
+}%%
+
+func parseQt(data string, header *Header) error {
+ var cs, p, pe int
+ var ts, te, act, eof int
+
+ pe = len(data)
+ eof = len(data)
+
+ _, _, _ = ts, te, act
+
+ //stack := make([]int, 32)
+ //top := 0
+
+ var curline = 1
+
+ var m0, m1, m2, m3, m4, m5, m6 int
+ var foundclass int
+ var inpublic bool
+ var heading string
+ var lineblock int
+ var f Func
+
+ %%{
+ nl = '\n' @{ curline++ };
+ cd = [^\n];
+ sp = [ \t];
+ id = [A-Za-z0-9_]+;
+ spnl = ( sp | nl );
+
+ main := |*
+ 'class Q_GUI_EXPORT ' id >{ m0 = p } %{ m1 = p } ' : public QAbstractOpenGLFunctions' nl '{' nl
+ {
+ header.Class = data[m0:m1]
+ foundclass++
+ fgoto inclass;
+ };
+
+ 'class Q_GUI_EXPORT ' id >{ m0 = p } %{ m1 = p } nl '{' nl
+ {
+ if data[m0:m1] == "QOpenGLFunctions" {
+ header.Class = data[m0:m1]
+ foundclass++
+ }
+ fgoto inclass;
+ };
+
+ # Ignore any other line.
+ cd* nl;
+ *|;
+
+ inclass := |*
+ # Track heading comments.
+ sp* '//' sp* cd* >{ m0 = p } @{ m1 = p } sp* nl
+ {
+ heading = data[m0:m1]
+ _ = heading
+ lineblock++
+ };
+
+ # Ignore constructor/destructor.
+ sp* '~'? id >{ m0 = p } %{ m1 = p } '()' sp* ( ';' | '{}' ) sp* nl {
+ if data[m0:m1] != header.Class {
+ fbreak;
+ }
+ };
+
+ # Ignore initialization function.
+ sp* 'bool' sp+ 'initializeOpenGLFunctions()' cd* nl;
+
+ # Ignore friend classes.
+ sp* 'friend' sp+ 'class' sp+ id sp* ';' sp* nl;
+
+ # Track public/private to ignore whatever isn't public.
+ sp* 'public:' sp* nl
+ {
+ inpublic = true
+ };
+ sp* ( 'private:' | 'protected:' ) sp* nl
+ {
+ inpublic = false
+ };
+
+ # Record function prototypes.
+ sp* ( 'const' sp+ )? id >{ m0 = p } %{ m1 = p; m4 = 0 } ( sp 'const'? | '*'+ ${ m4++ } )+
+ # Name
+ 'gl' >{ m2 = p } id %{ m3 = p; f = Func{Name: data[m2:m3], Type: data[m0:m1], Addr: m4} } sp* '(' >{ m6 = 0 } sp*
+ # Parameters
+ ( 'void'? sp* ')' | ( ( 'const' %{ m6 = 1 } sp+ )? id >{ m0 = p } %{ m1 = p; m4 = 0 } ( sp 'const'? | '*' ${ m4++ } )+ id >{ m2 = p; m5 = 0 } %{ m3 = p } ( '[' [0-9]+ ${ m5 = m5*10 + (int(data[p]) - '0') } ']' )? sp* [,)]
+ >{ f.Param = append(f.Param, Param{Name: data[m2:m3], Type: data[m0:m1], Addr: m4, Array: m5, Const: m6 > 0}); m6 = 0 } sp* )+ )
+ sp* ';'
+ {
+ if (inpublic) {
+ header.Func = append(header.Func, f)
+ }
+ };
+
+ # Record feature flags.
+ sp* 'enum OpenGLFeature' sp* nl sp* '{' sp* nl
+ ( sp* id >{ m0 = p } %{ m1 = p } sp* '=' sp* '0x' >{ m2 = p } [0-9]+ %{ m3 = p } ','? sp* nl
+ >{ header.FeatureFlags = append(header.FeatureFlags, Const{Name: data[m0:m1], Value: data[m2:m3]}) } )+
+ sp* '};' nl;
+
+ # Ignore non-gl functions and fields.
+ sp* ( 'static' sp+ )? ( 'const' sp+ )? [A-Za-z0-9_:]+ ( sp 'const'? | '*'+ ${ m4++ } )+ ( id - ( 'gl' id ) ) ( '(' cd* ')' )? sp* 'const'?
+ sp* ( ';' | '{' cd* '}' ) sp* nl;
+
+ # Ignore Q_DECLARE_FLAGS
+ sp* 'Q_DECLARE_FLAGS(' cd+ ')' sp* nl;
+
+ # Ignore deprecated functionality.
+ '#if QT_DEPRECATED_SINCE(' cd+ ')' sp* nl
+ ( cd* - '#endif' ) sp* nl
+ '#endif' sp* nl;
+
+ # Done.
+ sp* '}' sp* ';' nl
+ {
+ foundclass++;
+ fgoto main;
+ };
+
+ # Reset relevant states on empty lines.
+ sp* nl
+ {
+ // Reset heading comment.
+ heading = ""
+
+ // Start new line block.
+ lineblock++
+ };
+
+ *|;
+
+ skiperror := [^\n]* (';' | nl ) @{ fgoto main; };
+
+ write init;
+ write exec;
+ }%%
+
+ if p < pe {
+ m0, m1 = p, p
+ for m0 > 0 && data[m0-1] != '\n' {
+ m0--
+ }
+ for m1 < len(data) && data[m1] != '\n' {
+ m1++
+ }
+ return fmt.Errorf("cannot parse header file:%d:%d: %s", curline, p-m0, data[m0:m1])
+ }
+
+ if foundclass == 0 {
+ return fmt.Errorf("cannot find C++ class in header file")
+ }
+ if foundclass == 1 {
+ return fmt.Errorf("cannot find end of C++ class in header file")
+ }
+ if foundclass > 2 {
+ return fmt.Errorf("found too many C++ classes in header file")
+ }
+ return nil
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/gl/glbase/glbase.go b/Godeps/_workspace/src/github.com/obscuren/qml/gl/glbase/glbase.go
new file mode 100644
index 000000000..c483b15a2
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/gl/glbase/glbase.go
@@ -0,0 +1,33 @@
+package glbase
+
+// A Context represents an OpenGL context that may be rendered on by the
+// version-specific APIs under this package.
+type Context struct {
+ // This is just a marker at the moment, as the GL.API functions will
+ // initialize their GL context from the current context in the
+ // renderer thread. The design supports proper expansion and fixes for
+ // upstream changes that break that model, though.
+ private struct{}
+}
+
+// Contexter is implemented by values that have an assigned OpenGL context.
+type Contexter interface {
+ GLContext() *Context
+}
+
+type (
+ Bitfield uint32
+ Enum uint32
+ Sync uintptr
+ Clampf float32
+ Clampd float64
+
+ Uniform int32
+ Attrib int32
+ Texture uint32
+ Program uint32
+ Shader uint32
+ Buffer uint32
+ Framebuffer uint32
+ Renderbuffer uint32
+)
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/log.go b/Godeps/_workspace/src/github.com/obscuren/qml/log.go
new file mode 100644
index 000000000..5301e63b0
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/log.go
@@ -0,0 +1,157 @@
+package qml
+
+// #include "capi.h"
+//
+import "C"
+
+import (
+ "fmt"
+ "log"
+ "path/filepath"
+ "strings"
+)
+
+// SetLogger sets the target for messages logged by the qml package,
+// including console.log and related calls from within qml code.
+//
+// The logger value must implement either the StdLogger interface,
+// which is satisfied by the standard *log.Logger type, or the QmlLogger
+// interface, which offers more control over the logged message.
+//
+// If no logger is provided, the qml package will send messages to the
+// default log package logger. This behavior may also be restored by
+// providing a nil logger to this function.
+func SetLogger(logger interface{}) {
+ if logger == nil {
+ logHandler = defaultLogger{}
+ return
+ }
+ if qmll, ok := logger.(QmlLogger); ok {
+ logHandler = qmll
+ return
+ }
+ if stdl, ok := logger.(StdLogger); ok {
+ logHandler = wrappedStdLogger{stdl}
+ return
+ }
+ panic("unsupported logger interface")
+}
+
+// The QmlLogger interface may be implemented to better control how
+// log messages from the qml package are handled. Values that
+// implement either StdLogger or QmlLogger may be provided to the
+// SetLogger function.
+type QmlLogger interface {
+ // QmlOutput is called whenever a new message is available for logging.
+ // The message value must not be used after the method returns.
+ QmlOutput(message LogMessage) error
+}
+
+// The StdLogger interface is implemented by standard *log.Logger values.
+// Values that implement either StdLogger or QmlLogger may be provided
+// to the SetLogger function.
+type StdLogger interface {
+ // Output is called whenever a new message is available for logging.
+ // See the standard log.Logger type for more details.
+ Output(calldepth int, s string) error
+}
+
+// NOTE: LogMessage is an interface to avoid allocating and copying
+// several strings for each logged message.
+
+// LogMessage is implemented by values provided to QmlLogger.QmlOutput.
+type LogMessage interface {
+ Severity() LogSeverity
+ Text() string
+ File() string
+ Line() int
+
+ String() string // returns "file:line: text"
+
+ privateMarker()
+}
+
+type LogSeverity int
+
+const (
+ LogDebug LogSeverity = iota
+ LogWarning
+ LogCritical
+ LogFatal
+)
+
+var logHandler QmlLogger = defaultLogger{}
+
+type defaultLogger struct{}
+
+func (defaultLogger) QmlOutput(msg LogMessage) error {
+ log.Println(msg.String())
+ return nil
+}
+
+func init() {
+ // Install the C++ log handler that diverts calls to the hook below.
+ C.installLogHandler()
+}
+
+//export hookLogHandler
+func hookLogHandler(cmsg *C.LogMessage) {
+ // Workarund for QTBUG-35943
+ text := unsafeString(cmsg.text, cmsg.textLen)
+ if strings.HasPrefix(text, `"Qt Warning: Compose file:`) {
+ return
+ }
+ msg := logMessage{c: cmsg}
+ logHandler.QmlOutput(&msg)
+ msg.invalid = true
+}
+
+type wrappedStdLogger struct {
+ StdLogger
+}
+
+func (l wrappedStdLogger) QmlOutput(msg LogMessage) error {
+ return l.Output(0, msg.String())
+}
+
+type logMessage struct {
+ c *C.LogMessage
+
+ // invalid flags that cmsg points to unreliable memory,
+ // since the log hook has already returned.
+ invalid bool
+}
+
+func (m *logMessage) assertValid() {
+ if m.invalid {
+ panic("attempted to use log message outside of log hook")
+ }
+}
+
+func (m *logMessage) Severity() LogSeverity {
+ return LogSeverity(m.c.severity)
+}
+
+func (m *logMessage) Line() int {
+ m.assertValid()
+ return int(m.c.line)
+}
+
+func (m *logMessage) String() string {
+ m.assertValid()
+ file := unsafeString(m.c.file, m.c.fileLen)
+ text := unsafeString(m.c.text, m.c.textLen)
+ return fmt.Sprintf("%s:%d: %s", filepath.Base(file), m.c.line, text)
+}
+
+func (m *logMessage) File() string {
+ m.assertValid()
+ return C.GoStringN(m.c.file, m.c.fileLen)
+}
+
+func (m *logMessage) Text() string {
+ m.assertValid()
+ return C.GoStringN(m.c.text, m.c.line)
+}
+
+func (*logMessage) privateMarker() {}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/qml.go b/Godeps/_workspace/src/github.com/obscuren/qml/qml.go
new file mode 100644
index 000000000..1fa8f8ad4
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/qml.go
@@ -0,0 +1,1109 @@
+package qml
+
+// #include <stdlib.h>
+//
+// #include "capi.h"
+//
+import "C"
+
+import (
+ "errors"
+ "fmt"
+ "gopkg.in/qml.v1/gl/glbase"
+ "image"
+ "image/color"
+ "io"
+ "io/ioutil"
+ "os"
+ "path/filepath"
+ "reflect"
+ "strings"
+ "sync"
+ "unsafe"
+)
+
+// Engine provides an environment for instantiating QML components.
+type Engine struct {
+ Common
+ values map[interface{}]*valueFold
+ destroyed bool
+
+ imageProviders map[string]*func(imageId string, width, height int) image.Image
+}
+
+var engines = make(map[unsafe.Pointer]*Engine)
+
+// NewEngine returns a new QML engine.
+//
+// The Destory method must be called to finalize the engine and
+// release any resources used.
+func NewEngine() *Engine {
+ engine := &Engine{values: make(map[interface{}]*valueFold)}
+ RunMain(func() {
+ engine.addr = C.newEngine(nil)
+ engine.engine = engine
+ engine.imageProviders = make(map[string]*func(imageId string, width, height int) image.Image)
+ engines[engine.addr] = engine
+ stats.enginesAlive(+1)
+ })
+ return engine
+}
+
+func (e *Engine) assertValid() {
+ if e.destroyed {
+ panic("engine already destroyed")
+ }
+}
+
+// Destroy finalizes the engine and releases any resources used.
+// The engine must not be used after calling this method.
+//
+// It is safe to call Destroy more than once.
+func (e *Engine) Destroy() {
+ if !e.destroyed {
+ RunMain(func() {
+ if !e.destroyed {
+ e.destroyed = true
+ C.delObjectLater(e.addr)
+ if len(e.values) == 0 {
+ delete(engines, e.addr)
+ } else {
+ // The engine reference keeps those values alive.
+ // The last value destroyed will clear it.
+ }
+ stats.enginesAlive(-1)
+ }
+ })
+ }
+}
+
+// Load loads a new component with the provided location and with the
+// content read from r. The location informs the resource name for
+// logged messages, and its path is used to locate any other resources
+// referenced by the QML content.
+//
+// Once a component is loaded, component instances may be created from
+// the resulting object via its Create and CreateWindow methods.
+func (e *Engine) Load(location string, r io.Reader) (Object, error) {
+ var cdata *C.char
+ var cdatalen C.int
+
+ qrc := strings.HasPrefix(location, "qrc:")
+ if qrc {
+ if r != nil {
+ return nil, fmt.Errorf("cannot load qrc resource while providing data: %s", location)
+ }
+ } else {
+ data, err := ioutil.ReadAll(r)
+ if err != nil {
+ return nil, err
+ }
+ if colon, slash := strings.Index(location, ":"), strings.Index(location, "/"); colon == -1 || slash <= colon {
+ if filepath.IsAbs(location) {
+ location = "file:///" + filepath.ToSlash(location)
+ } else {
+ dir, err := os.Getwd()
+ if err != nil {
+ return nil, fmt.Errorf("cannot obtain absolute path: %v", err)
+ }
+ location = "file:///" + filepath.ToSlash(filepath.Join(dir, location))
+ }
+ }
+
+ // Workaround issue #84 (QTBUG-41193) by not refering to an existent file.
+ if s := strings.TrimPrefix(location, "file:///"); s != location {
+ if _, err := os.Stat(filepath.FromSlash(s)); err == nil {
+ location = location + "."
+ }
+ }
+
+ cdata, cdatalen = unsafeBytesData(data)
+ }
+
+ var err error
+ cloc, cloclen := unsafeStringData(location)
+ comp := &Common{engine: e}
+ RunMain(func() {
+ // TODO The component's parent should probably be the engine.
+ comp.addr = C.newComponent(e.addr, nilPtr)
+ if qrc {
+ C.componentLoadURL(comp.addr, cloc, cloclen)
+ } else {
+ C.componentSetData(comp.addr, cdata, cdatalen, cloc, cloclen)
+ }
+ message := C.componentErrorString(comp.addr)
+ if message != nilCharPtr {
+ err = errors.New(strings.TrimRight(C.GoString(message), "\n"))
+ C.free(unsafe.Pointer(message))
+ }
+ })
+ if err != nil {
+ return nil, err
+ }
+ return comp, nil
+}
+
+// LoadFile loads a component from the provided QML file.
+// Resources referenced by the QML content will be resolved relative to its path.
+//
+// Once a component is loaded, component instances may be created from
+// the resulting object via its Create and CreateWindow methods.
+func (e *Engine) LoadFile(path string) (Object, error) {
+ if strings.HasPrefix(path, "qrc:") {
+ return e.Load(path, nil)
+ }
+ // TODO Test this.
+ f, err := os.Open(path)
+ if err != nil {
+ return nil, err
+ }
+ defer f.Close()
+ return e.Load(path, f)
+}
+
+// LoadString loads a component from the provided QML string.
+// The location informs the resource name for logged messages, and its
+// path is used to locate any other resources referenced by the QML content.
+//
+// Once a component is loaded, component instances may be created from
+// the resulting object via its Create and CreateWindow methods.
+func (e *Engine) LoadString(location, qml string) (Object, error) {
+ return e.Load(location, strings.NewReader(qml))
+}
+
+// Context returns the engine's root context.
+func (e *Engine) Context() *Context {
+ e.assertValid()
+ var ctx Context
+ ctx.engine = e
+ RunMain(func() {
+ ctx.addr = C.engineRootContext(e.addr)
+ })
+ return &ctx
+}
+
+// TODO ObjectOf is probably still worth it, but turned out unnecessary
+// for GL functionality. Test it properly before introducing it.
+
+// ObjectOf returns the QML Object representation of the provided Go value
+// within the e engine.
+//func (e *Engine) ObjectOf(value interface{}) Object {
+// // TODO Would be good to preserve identity on the Go side. See unpackDataValue as well.
+// return &Common{
+// engine: e,
+// addr: wrapGoValue(e, value, cppOwner),
+// }
+//}
+
+// Painter is provided to Paint methods on Go types that have displayable content.
+type Painter struct {
+ engine *Engine
+ obj Object
+ glctxt glbase.Context
+}
+
+// Object returns the underlying object being painted.
+func (p *Painter) Object() Object {
+ return p.obj
+}
+
+// GLContext returns the OpenGL context for this painter.
+func (p *Painter) GLContext() *glbase.Context {
+ return &p.glctxt
+}
+
+// AddImageProvider registers f to be called when an image is requested by QML code
+// with the specified provider identifier. It is a runtime error to register the same
+// provider identifier multiple times.
+//
+// The imgId provided to f is the requested image source, with the "image:" scheme
+// and provider identifier removed. For example, with an image image source of
+// "image://myprovider/icons/home.ext", the respective imgId would be "icons/home.ext".
+//
+// If either the width or the height parameters provided to f are zero, no specific
+// size for the image was requested. If non-zero, the returned image should have the
+// the provided size, and will be resized if the returned image has a different size.
+//
+// See the documentation for more details on image providers:
+//
+// http://qt-project.org/doc/qt-5.0/qtquick/qquickimageprovider.html
+//
+func (e *Engine) AddImageProvider(prvId string, f func(imgId string, width, height int) image.Image) {
+ if _, ok := e.imageProviders[prvId]; ok {
+ panic(fmt.Sprintf("engine already has an image provider with id %q", prvId))
+ }
+ e.imageProviders[prvId] = &f
+ cprvId, cprvIdLen := unsafeStringData(prvId)
+ RunMain(func() {
+ qprvId := C.newString(cprvId, cprvIdLen)
+ defer C.delString(qprvId)
+ C.engineAddImageProvider(e.addr, qprvId, unsafe.Pointer(&f))
+ })
+}
+
+//export hookRequestImage
+func hookRequestImage(imageFunc unsafe.Pointer, cid *C.char, cidLen, cwidth, cheight C.int) unsafe.Pointer {
+ f := *(*func(imgId string, width, height int) image.Image)(imageFunc)
+
+ id := unsafeString(cid, cidLen)
+ width := int(cwidth)
+ height := int(cheight)
+
+ img := f(id, width, height)
+
+ var cimage unsafe.Pointer
+
+ rect := img.Bounds()
+ width = rect.Max.X - rect.Min.X
+ height = rect.Max.Y - rect.Min.Y
+ cimage = C.newImage(C.int(width), C.int(height))
+
+ var cbits []byte
+ cbitsh := (*reflect.SliceHeader)((unsafe.Pointer)(&cbits))
+ cbitsh.Data = (uintptr)((unsafe.Pointer)(C.imageBits(cimage)))
+ cbitsh.Len = width * height * 4 // RGBA
+ cbitsh.Cap = cbitsh.Len
+
+ i := 0
+ for y := 0; y < height; y++ {
+ for x := 0; x < width; x++ {
+ r, g, b, a := img.At(x, y).RGBA()
+ *(*uint32)(unsafe.Pointer(&cbits[i])) = (a>>8)<<24 | (r>>8)<<16 | (g>>8)<<8 | (b >> 8)
+ i += 4
+ }
+ }
+ return cimage
+}
+
+// Context represents a QML context that can hold variables visible
+// to logic running within it.
+type Context struct {
+ Common
+}
+
+// SetVar makes the provided value available as a variable with the
+// given name for QML code executed within the c context.
+//
+// If value is a struct, its exported fields are also made accessible to
+// QML code as attributes of the named object. The attribute name in the
+// object has the same name of the Go field name, except for the first
+// letter which is lowercased. This is conventional and enforced by
+// the QML implementation.
+//
+// The engine will hold a reference to the provided value, so it will
+// not be garbage collected until the engine is destroyed, even if the
+// value is unused or changed.
+func (ctx *Context) SetVar(name string, value interface{}) {
+ cname, cnamelen := unsafeStringData(name)
+ RunMain(func() {
+ var dvalue C.DataValue
+ packDataValue(value, &dvalue, ctx.engine, cppOwner)
+
+ qname := C.newString(cname, cnamelen)
+ defer C.delString(qname)
+
+ C.contextSetProperty(ctx.addr, qname, &dvalue)
+ })
+}
+
+// SetVars makes the exported fields of the provided value available as
+// variables for QML code executed within the c context. The variable names
+// will have the same name of the Go field names, except for the first
+// letter which is lowercased. This is conventional and enforced by
+// the QML implementation.
+//
+// The engine will hold a reference to the provided value, so it will
+// not be garbage collected until the engine is destroyed, even if the
+// value is unused or changed.
+func (ctx *Context) SetVars(value interface{}) {
+ RunMain(func() {
+ C.contextSetObject(ctx.addr, wrapGoValue(ctx.engine, value, cppOwner))
+ })
+}
+
+// Var returns the context variable with the given name.
+func (ctx *Context) Var(name string) interface{} {
+ cname, cnamelen := unsafeStringData(name)
+
+ var dvalue C.DataValue
+ RunMain(func() {
+ qname := C.newString(cname, cnamelen)
+ defer C.delString(qname)
+
+ C.contextGetProperty(ctx.addr, qname, &dvalue)
+ })
+ return unpackDataValue(&dvalue, ctx.engine)
+}
+
+// Spawn creates a new context that has ctx as a parent.
+func (ctx *Context) Spawn() *Context {
+ var result Context
+ result.engine = ctx.engine
+ RunMain(func() {
+ result.addr = C.contextSpawn(ctx.addr)
+ })
+ return &result
+}
+
+// Object is the common interface implemented by all QML types.
+//
+// See the documentation of Common for details about this interface.
+type Object interface {
+ Common() *Common
+ Addr() uintptr
+ TypeName() string
+ Interface() interface{}
+ Set(property string, value interface{})
+ Property(name string) interface{}
+ Int(property string) int
+ Int64(property string) int64
+ Float64(property string) float64
+ Bool(property string) bool
+ String(property string) string
+ Color(property string) color.RGBA
+ Object(property string) Object
+ Map(property string) *Map
+ List(property string) *List
+ ObjectByName(objectName string) Object
+ Call(method string, params ...interface{}) interface{}
+ Create(ctx *Context) Object
+ CreateWindow(ctx *Context) *Window
+ Destroy()
+ On(signal string, function interface{})
+}
+
+// List holds a QML list which may be converted to a Go slice of an
+// appropriate type via Convert.
+//
+// In the future this will also be able to hold a reference
+// to QML-owned maps, so they can be mutated in place.
+type List struct {
+ // In the future this will be able to hold a reference to QML-owned
+ // lists, so they can be mutated.
+ data []interface{}
+}
+
+// Len returns the number of elements in the list.
+func (l *List) Len() int {
+ return len(l.data)
+}
+
+// Convert allocates a new slice and copies the list content into it,
+// performing type conversions as possible, and then assigns the result
+// to the slice pointed to by sliceAddr.
+// Convert panics if the list values are not compatible with the
+// provided slice.
+func (l *List) Convert(sliceAddr interface{}) {
+ toPtr := reflect.ValueOf(sliceAddr)
+ if toPtr.Kind() != reflect.Ptr || toPtr.Type().Elem().Kind() != reflect.Slice {
+ panic(fmt.Sprintf("List.Convert got a sliceAddr parameter that is not a slice address: %#v", sliceAddr))
+ }
+ err := convertAndSet(toPtr.Elem(), reflect.ValueOf(l), reflect.Value{})
+ if err != nil {
+ panic(err.Error())
+ }
+}
+
+// Map holds a QML map which may be converted to a Go map of an
+// appropriate type via Convert.
+//
+// In the future this will also be able to hold a reference
+// to QML-owned maps, so they can be mutated in place.
+type Map struct {
+ data []interface{}
+}
+
+// Len returns the number of pairs in the map.
+func (m *Map) Len() int {
+ return len(m.data) / 2
+}
+
+// Convert allocates a new map and copies the content of m property to it,
+// performing type conversions as possible, and then assigns the result to
+// the map pointed to by mapAddr. Map panics if m contains values that
+// cannot be converted to the type of the map at mapAddr.
+func (m *Map) Convert(mapAddr interface{}) {
+ toPtr := reflect.ValueOf(mapAddr)
+ if toPtr.Kind() != reflect.Ptr || toPtr.Type().Elem().Kind() != reflect.Map {
+ panic(fmt.Sprintf("Map.Convert got a mapAddr parameter that is not a map address: %#v", mapAddr))
+ }
+ err := convertAndSet(toPtr.Elem(), reflect.ValueOf(m), reflect.Value{})
+ if err != nil {
+ panic(err.Error())
+ }
+}
+
+// Common implements the common behavior of all QML objects.
+// It implements the Object interface.
+type Common struct {
+ addr unsafe.Pointer
+ engine *Engine
+}
+
+var _ Object = (*Common)(nil)
+
+// CommonOf returns the Common QML value for the QObject at addr.
+//
+// This is meant for extensions that integrate directly with the
+// underlying QML logic.
+func CommonOf(addr unsafe.Pointer, engine *Engine) *Common {
+ return &Common{addr, engine}
+}
+
+// Common returns obj itself.
+//
+// This provides access to the underlying *Common for types that
+// embed it, when these are used via the Object interface.
+func (obj *Common) Common() *Common {
+ return obj
+}
+
+// TypeName returns the underlying type name for the held value.
+func (obj *Common) TypeName() string {
+ var name string
+ RunMain(func() {
+ name = C.GoString(C.objectTypeName(obj.addr))
+ })
+ return name
+}
+
+// Addr returns the QML object address.
+//
+// This is meant for extensions that integrate directly with the
+// underlying QML logic.
+func (obj *Common) Addr() uintptr {
+ return uintptr(obj.addr)
+}
+
+// Interface returns the underlying Go value that is being held by
+// the object wrapper.
+//
+// It is a runtime error to call Interface on values that are not
+// backed by a Go value.
+func (obj *Common) Interface() interface{} {
+ var result interface{}
+ var cerr *C.error
+ RunMain(func() {
+ var fold *valueFold
+ if cerr = C.objectGoAddr(obj.addr, (*unsafe.Pointer)(unsafe.Pointer(&fold))); cerr == nil {
+ result = fold.gvalue
+ }
+ })
+ cmust(cerr)
+ return result
+}
+
+// Set changes the named object property to the given value.
+func (obj *Common) Set(property string, value interface{}) {
+ cproperty := C.CString(property)
+ defer C.free(unsafe.Pointer(cproperty))
+ var cerr *C.error
+ RunMain(func() {
+ var dvalue C.DataValue
+ packDataValue(value, &dvalue, obj.engine, cppOwner)
+ cerr = C.objectSetProperty(obj.addr, cproperty, &dvalue)
+ })
+ cmust(cerr)
+}
+
+// Property returns the current value for a property of the object.
+// If the property type is known, type-specific methods such as Int
+// and String are more convenient to use.
+// Property panics if the property does not exist.
+func (obj *Common) Property(name string) interface{} {
+ cname := C.CString(name)
+ defer C.free(unsafe.Pointer(cname))
+
+ var dvalue C.DataValue
+ var found C.int
+ RunMain(func() {
+ found = C.objectGetProperty(obj.addr, cname, &dvalue)
+ })
+ if found == 0 {
+ panic(fmt.Sprintf("object does not have a %q property", name))
+ }
+ return unpackDataValue(&dvalue, obj.engine)
+}
+
+// Int returns the int value of the named property.
+// Int panics if the property cannot be represented as an int.
+func (obj *Common) Int(property string) int {
+ switch value := obj.Property(property).(type) {
+ case int64:
+ return int(value)
+ case int:
+ return value
+ case uint64:
+ return int(value)
+ case uint32:
+ return int(value)
+ case uintptr:
+ return int(value)
+ case float32:
+ return int(value)
+ case float64:
+ return int(value)
+ default:
+ panic(fmt.Sprintf("value of property %q cannot be represented as an int: %#v", property, value))
+ }
+}
+
+// Int64 returns the int64 value of the named property.
+// Int64 panics if the property cannot be represented as an int64.
+func (obj *Common) Int64(property string) int64 {
+ switch value := obj.Property(property).(type) {
+ case int64:
+ return value
+ case int:
+ return int64(value)
+ case uint64:
+ return int64(value)
+ case uint32:
+ return int64(value)
+ case uintptr:
+ return int64(value)
+ case float32:
+ return int64(value)
+ case float64:
+ return int64(value)
+ default:
+ panic(fmt.Sprintf("value of property %q cannot be represented as an int64: %#v", property, value))
+ }
+}
+
+// Float64 returns the float64 value of the named property.
+// Float64 panics if the property cannot be represented as float64.
+func (obj *Common) Float64(property string) float64 {
+ switch value := obj.Property(property).(type) {
+ case int64:
+ return float64(value)
+ case int:
+ return float64(value)
+ case uint64:
+ return float64(value)
+ case uint32:
+ return float64(value)
+ case uintptr:
+ return float64(value)
+ case float32:
+ return float64(value)
+ case float64:
+ return value
+ default:
+ panic(fmt.Sprintf("value of property %q cannot be represented as a float64: %#v", property, value))
+ }
+}
+
+// Bool returns the bool value of the named property.
+// Bool panics if the property is not a bool.
+func (obj *Common) Bool(property string) bool {
+ value := obj.Property(property)
+ if b, ok := value.(bool); ok {
+ return b
+ }
+ panic(fmt.Sprintf("value of property %q is not a bool: %#v", property, value))
+}
+
+// String returns the string value of the named property.
+// String panics if the property is not a string.
+func (obj *Common) String(property string) string {
+ value := obj.Property(property)
+ if s, ok := value.(string); ok {
+ return s
+ }
+ panic(fmt.Sprintf("value of property %q is not a string: %#v", property, value))
+}
+
+// Color returns the RGBA value of the named property.
+// Color panics if the property is not a color.
+func (obj *Common) Color(property string) color.RGBA {
+ value := obj.Property(property)
+ c, ok := value.(color.RGBA)
+ if !ok {
+ panic(fmt.Sprintf("value of property %q is not a color: %#v", property, value))
+ }
+ return c
+}
+
+// Object returns the object value of the named property.
+// Object panics if the property is not a QML object.
+func (obj *Common) Object(property string) Object {
+ value := obj.Property(property)
+ object, ok := value.(Object)
+ if !ok {
+ panic(fmt.Sprintf("value of property %q is not a QML object: %#v", property, value))
+ }
+ return object
+}
+
+// List returns the list value of the named property.
+// List panics if the property is not a list.
+func (obj *Common) List(property string) *List {
+ value := obj.Property(property)
+ m, ok := value.(*List)
+ if !ok {
+ panic(fmt.Sprintf("value of property %q is not a QML list: %#v", property, value))
+ }
+ return m
+}
+
+// Map returns the map value of the named property.
+// Map panics if the property is not a map.
+func (obj *Common) Map(property string) *Map {
+ value := obj.Property(property)
+ m, ok := value.(*Map)
+ if !ok {
+ panic(fmt.Sprintf("value of property %q is not a QML map: %#v", property, value))
+ }
+ return m
+}
+
+// ObjectByName returns the Object value of the descendant object that
+// was defined with the objectName property set to the provided value.
+// ObjectByName panics if the object is not found.
+func (obj *Common) ObjectByName(objectName string) Object {
+ cname, cnamelen := unsafeStringData(objectName)
+ var dvalue C.DataValue
+ var object Object
+ RunMain(func() {
+ qname := C.newString(cname, cnamelen)
+ defer C.delString(qname)
+ C.objectFindChild(obj.addr, qname, &dvalue)
+ // unpackDataValue will also initialize the Go type, if necessary.
+ value := unpackDataValue(&dvalue, obj.engine)
+ if dvalue.dataType == C.DTGoAddr {
+ datap := unsafe.Pointer(&dvalue.data)
+ fold := (*(**valueFold)(datap))
+ if fold.init.IsValid() {
+ panic("internal error: custom Go type not initialized")
+ }
+ object = &Common{fold.cvalue, fold.engine}
+ } else {
+ object, _ = value.(Object)
+ }
+ })
+ if object == nil {
+ panic(fmt.Sprintf("cannot find descendant with objectName == %q", objectName))
+ }
+ return object
+}
+
+// Call calls the given object method with the provided parameters.
+// Call panics if the method does not exist.
+func (obj *Common) Call(method string, params ...interface{}) interface{} {
+ if len(params) > len(dataValueArray) {
+ panic("too many parameters")
+ }
+ cmethod, cmethodLen := unsafeStringData(method)
+ var result C.DataValue
+ var cerr *C.error
+ RunMain(func() {
+ for i, param := range params {
+ packDataValue(param, &dataValueArray[i], obj.engine, jsOwner)
+ }
+ cerr = C.objectInvoke(obj.addr, cmethod, cmethodLen, &result, &dataValueArray[0], C.int(len(params)))
+ })
+ cmust(cerr)
+ return unpackDataValue(&result, obj.engine)
+}
+
+// Create creates a new instance of the component held by obj.
+// The component instance runs under the ctx context. If ctx is nil,
+// it runs under the same context as obj.
+//
+// The Create method panics if called on an object that does not
+// represent a QML component.
+func (obj *Common) Create(ctx *Context) Object {
+ if C.objectIsComponent(obj.addr) == 0 {
+ panic("object is not a component")
+ }
+ var root Common
+ root.engine = obj.engine
+ RunMain(func() {
+ ctxaddr := nilPtr
+ if ctx != nil {
+ ctxaddr = ctx.addr
+ }
+ root.addr = C.componentCreate(obj.addr, ctxaddr)
+ })
+ return &root
+}
+
+// CreateWindow creates a new instance of the component held by obj,
+// and creates a new window holding the instance as its root object.
+// The component instance runs under the ctx context. If ctx is nil,
+// it runs under the same context as obj.
+//
+// The CreateWindow method panics if called on an object that
+// does not represent a QML component.
+func (obj *Common) CreateWindow(ctx *Context) *Window {
+ if C.objectIsComponent(obj.addr) == 0 {
+ panic("object is not a component")
+ }
+ var win Window
+ win.engine = obj.engine
+ RunMain(func() {
+ ctxaddr := nilPtr
+ if ctx != nil {
+ ctxaddr = ctx.addr
+ }
+ win.addr = C.componentCreateWindow(obj.addr, ctxaddr)
+ })
+ return &win
+}
+
+// Destroy finalizes the value and releases any resources used.
+// The value must not be used after calling this method.
+func (obj *Common) Destroy() {
+ // TODO We might hook into the destroyed signal, and prevent this object
+ // from being used in post-destruction crash-prone ways.
+ RunMain(func() {
+ if obj.addr != nilPtr {
+ C.delObjectLater(obj.addr)
+ obj.addr = nilPtr
+ }
+ })
+}
+
+var connectedFunction = make(map[*interface{}]bool)
+
+// On connects the named signal from obj with the provided function, so that
+// when obj next emits that signal, the function is called with the parameters
+// the signal carries.
+//
+// The provided function must accept a number of parameters that is equal to
+// or less than the number of parameters provided by the signal, and the
+// resepctive parameter types must match exactly or be conversible according
+// to normal Go rules.
+//
+// For example:
+//
+// obj.On("clicked", func() { fmt.Println("obj got a click") })
+//
+// Note that Go uses the real signal name, rather than the one used when
+// defining QML signal handlers ("clicked" rather than "onClicked").
+//
+// For more details regarding signals and QML see:
+//
+// http://qt-project.org/doc/qt-5.0/qtqml/qml-qtquick2-connections.html
+//
+func (obj *Common) On(signal string, function interface{}) {
+ funcv := reflect.ValueOf(function)
+ funct := funcv.Type()
+ if funcv.Kind() != reflect.Func {
+ panic("function provided to On is not a function or method")
+ }
+ if funct.NumIn() > C.MaxParams {
+ panic("function takes too many arguments")
+ }
+ csignal, csignallen := unsafeStringData(signal)
+ var cerr *C.error
+ RunMain(func() {
+ cerr = C.objectConnect(obj.addr, csignal, csignallen, obj.engine.addr, unsafe.Pointer(&function), C.int(funcv.Type().NumIn()))
+ if cerr == nil {
+ connectedFunction[&function] = true
+ stats.connectionsAlive(+1)
+ }
+ })
+ cmust(cerr)
+}
+
+//export hookSignalDisconnect
+func hookSignalDisconnect(funcp unsafe.Pointer) {
+ before := len(connectedFunction)
+ delete(connectedFunction, (*interface{})(funcp))
+ if before == len(connectedFunction) {
+ panic("disconnecting unknown signal function")
+ }
+ stats.connectionsAlive(-1)
+}
+
+//export hookSignalCall
+func hookSignalCall(enginep unsafe.Pointer, funcp unsafe.Pointer, args *C.DataValue) {
+ engine := engines[enginep]
+ if engine == nil {
+ panic("signal called after engine was destroyed")
+ }
+ funcv := reflect.ValueOf(*(*interface{})(funcp))
+ funct := funcv.Type()
+ numIn := funct.NumIn()
+ var params [C.MaxParams]reflect.Value
+ for i := 0; i < numIn; i++ {
+ arg := (*C.DataValue)(unsafe.Pointer(uintptr(unsafe.Pointer(args)) + uintptr(i)*dataValueSize))
+ param := reflect.ValueOf(unpackDataValue(arg, engine))
+ if paramt := funct.In(i); param.Type() != paramt {
+ // TODO Provide a better error message when this fails.
+ param = param.Convert(paramt)
+ }
+ params[i] = param
+ }
+ funcv.Call(params[:numIn])
+}
+
+func cerror(cerr *C.error) error {
+ err := errors.New(C.GoString((*C.char)(unsafe.Pointer(cerr))))
+ C.free(unsafe.Pointer(cerr))
+ return err
+}
+
+func cmust(cerr *C.error) {
+ if cerr != nil {
+ panic(cerror(cerr).Error())
+ }
+}
+
+// TODO Signal emitting support for go values.
+
+// Window represents a QML window where components are rendered.
+type Window struct {
+ Common
+}
+
+// Show exposes the window.
+func (win *Window) Show() {
+ RunMain(func() {
+ C.windowShow(win.addr)
+ })
+}
+
+// Hide hides the window.
+func (win *Window) Hide() {
+ RunMain(func() {
+ C.windowHide(win.addr)
+ })
+}
+
+// PlatformId returns the window's platform id.
+//
+// For platforms where this id might be useful, the value returned will
+// uniquely represent the window inside the corresponding screen.
+func (win *Window) PlatformId() uintptr {
+ var id uintptr
+ RunMain(func() {
+ id = uintptr(C.windowPlatformId(win.addr))
+ })
+ return id
+}
+
+// Root returns the root object being rendered.
+//
+// If the window was defined in QML code, the root object is the window itself.
+func (win *Window) Root() Object {
+ var obj Common
+ obj.engine = win.engine
+ RunMain(func() {
+ obj.addr = C.windowRootObject(win.addr)
+ })
+ return &obj
+}
+
+// Wait blocks the current goroutine until the window is closed.
+func (win *Window) Wait() {
+ // XXX Test this.
+ var m sync.Mutex
+ m.Lock()
+ RunMain(func() {
+ // TODO Must be able to wait for the same Window from multiple goroutines.
+ // TODO If the window is not visible, must return immediately.
+ waitingWindows[win.addr] = &m
+ C.windowConnectHidden(win.addr)
+ })
+ m.Lock()
+}
+
+var waitingWindows = make(map[unsafe.Pointer]*sync.Mutex)
+
+//export hookWindowHidden
+func hookWindowHidden(addr unsafe.Pointer) {
+ m, ok := waitingWindows[addr]
+ if !ok {
+ panic("window is not waiting")
+ }
+ delete(waitingWindows, addr)
+ m.Unlock()
+}
+
+// Snapshot returns an image with the visible contents of the window.
+// The main GUI thread is paused while the data is being acquired.
+func (win *Window) Snapshot() image.Image {
+ // TODO Test this.
+ var cimage unsafe.Pointer
+ RunMain(func() {
+ cimage = C.windowGrabWindow(win.addr)
+ })
+ defer C.delImage(cimage)
+
+ // This should be safe to be done out of the main GUI thread.
+ var cwidth, cheight C.int
+ C.imageSize(cimage, &cwidth, &cheight)
+
+ var cbits []byte
+ cbitsh := (*reflect.SliceHeader)((unsafe.Pointer)(&cbits))
+ cbitsh.Data = (uintptr)((unsafe.Pointer)(C.imageConstBits(cimage)))
+ cbitsh.Len = int(cwidth * cheight * 8) // ARGB
+ cbitsh.Cap = cbitsh.Len
+
+ image := image.NewRGBA(image.Rect(0, 0, int(cwidth), int(cheight)))
+ l := int(cwidth * cheight * 4)
+ for i := 0; i < l; i += 4 {
+ var c uint32 = *(*uint32)(unsafe.Pointer(&cbits[i]))
+ image.Pix[i+0] = byte(c >> 16)
+ image.Pix[i+1] = byte(c >> 8)
+ image.Pix[i+2] = byte(c)
+ image.Pix[i+3] = byte(c >> 24)
+ }
+ return image
+}
+
+// TypeSpec holds the specification of a QML type that is backed by Go logic.
+//
+// The type specification must be registered with the RegisterTypes function
+// before it will be visible to QML code, as in:
+//
+// qml.RegisterTypes("GoExtensions", 1, 0, []qml.TypeSpec{{
+// Init: func(p *Person, obj qml.Object) {},
+// }})
+//
+// See the package documentation for more details.
+//
+type TypeSpec struct {
+ // Init must be set to a function that is called when QML code requests
+ // the creation of a new value of this type. The provided function must
+ // have the following type:
+ //
+ // func(value *CustomType, object qml.Object)
+ //
+ // Where CustomType is the custom type being registered. The function will
+ // be called with a newly created *CustomType and its respective qml.Object.
+ Init interface{}
+
+ // Name optionally holds the identifier the type is known as within QML code,
+ // when the registered extension module is imported. If not specified, the
+ // name of the Go type provided as the first argument of Init is used instead.
+ Name string
+
+ // Singleton defines whether a single instance of the type should be used
+ // for all accesses, as a singleton value. If true, all properties of the
+ // singleton value are directly accessible under the type name.
+ Singleton bool
+
+ private struct{} // Force use of fields by name.
+}
+
+var types []*TypeSpec
+
+// RegisterTypes registers the provided list of type specifications for use
+// by QML code. To access the registered types, they must be imported from the
+// provided location and major.minor version numbers.
+//
+// For example, with a location "GoExtensions", major 4, and minor 2, this statement
+// imports all the registered types in the module's namespace:
+//
+// import GoExtensions 4.2
+//
+// See the documentation on QML import statements for details on these:
+//
+// http://qt-project.org/doc/qt-5.0/qtqml/qtqml-syntax-imports.html
+//
+func RegisterTypes(location string, major, minor int, types []TypeSpec) {
+ for i := range types {
+ err := registerType(location, major, minor, &types[i])
+ if err != nil {
+ panic(err)
+ }
+ }
+}
+
+func registerType(location string, major, minor int, spec *TypeSpec) error {
+ // Copy and hold a reference to the spec data.
+ localSpec := *spec
+
+ f := reflect.ValueOf(localSpec.Init)
+ ft := f.Type()
+ if ft.Kind() != reflect.Func {
+ return fmt.Errorf("TypeSpec.Init must be a function, got %#v", localSpec.Init)
+ }
+ if ft.NumIn() != 2 {
+ return fmt.Errorf("TypeSpec.Init's function must accept two arguments: %s", ft)
+ }
+ firstArg := ft.In(0)
+ if firstArg.Kind() != reflect.Ptr || firstArg.Elem().Kind() == reflect.Ptr {
+ return fmt.Errorf("TypeSpec.Init's function must take a pointer type as the second argument: %s", ft)
+ }
+ if ft.In(1) != typeObject {
+ return fmt.Errorf("TypeSpec.Init's function must take qml.Object as the second argument: %s", ft)
+ }
+ customType := typeInfo(reflect.New(firstArg.Elem()).Interface())
+ if localSpec.Name == "" {
+ localSpec.Name = firstArg.Elem().Name()
+ if localSpec.Name == "" {
+ panic("cannot determine registered type name; please provide one explicitly")
+ }
+ }
+
+ var err error
+ RunMain(func() {
+ cloc := C.CString(location)
+ cname := C.CString(localSpec.Name)
+ cres := C.int(0)
+ if localSpec.Singleton {
+ cres = C.registerSingleton(cloc, C.int(major), C.int(minor), cname, customType, unsafe.Pointer(&localSpec))
+ } else {
+ cres = C.registerType(cloc, C.int(major), C.int(minor), cname, customType, unsafe.Pointer(&localSpec))
+ }
+ // It doesn't look like it keeps references to these, but it's undocumented and unclear.
+ C.free(unsafe.Pointer(cloc))
+ C.free(unsafe.Pointer(cname))
+ if cres == -1 {
+ err = fmt.Errorf("QML engine failed to register type; invalid type location or name?")
+ } else {
+ types = append(types, &localSpec)
+ }
+ })
+
+ return err
+}
+
+// RegisterConverter registers the convereter function to be called when a
+// value with the provided type name is obtained from QML logic. The function
+// must return the new value to be used in place of the original value.
+func RegisterConverter(typeName string, converter func(engine *Engine, obj Object) interface{}) {
+ if converter == nil {
+ delete(converters, typeName)
+ } else {
+ converters[typeName] = converter
+ }
+}
+
+var converters = make(map[string]func(engine *Engine, obj Object) interface{})
+
+// LoadResources registers all resources in the provided resources collection,
+// making them available to be loaded by any Engine and QML file.
+// Registered resources are made available under "qrc:///some/path", where
+// "some/path" is the path the resource was added with.
+func LoadResources(r *Resources) {
+ var base unsafe.Pointer
+ if len(r.sdata) > 0 {
+ base = *(*unsafe.Pointer)(unsafe.Pointer(&r.sdata))
+ } else if len(r.bdata) > 0 {
+ base = *(*unsafe.Pointer)(unsafe.Pointer(&r.bdata))
+ }
+ tree := (*C.char)(unsafe.Pointer(uintptr(base)+uintptr(r.treeOffset)))
+ name := (*C.char)(unsafe.Pointer(uintptr(base)+uintptr(r.nameOffset)))
+ data := (*C.char)(unsafe.Pointer(uintptr(base)+uintptr(r.dataOffset)))
+ C.registerResourceData(C.int(r.version), tree, name, data)
+}
+
+// UnloadResources unregisters all previously registered resources from r.
+func UnloadResources(r *Resources) {
+ var base unsafe.Pointer
+ if len(r.sdata) > 0 {
+ base = *(*unsafe.Pointer)(unsafe.Pointer(&r.sdata))
+ } else if len(r.bdata) > 0 {
+ base = *(*unsafe.Pointer)(unsafe.Pointer(&r.bdata))
+ }
+ tree := (*C.char)(unsafe.Pointer(uintptr(base)+uintptr(r.treeOffset)))
+ name := (*C.char)(unsafe.Pointer(uintptr(base)+uintptr(r.nameOffset)))
+ data := (*C.char)(unsafe.Pointer(uintptr(base)+uintptr(r.dataOffset)))
+ C.unregisterResourceData(C.int(r.version), tree, name, data)
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/qml_test.go b/Godeps/_workspace/src/github.com/obscuren/qml/qml_test.go
new file mode 100644
index 000000000..2db23cd23
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/qml_test.go
@@ -0,0 +1,1436 @@
+package qml_test
+
+import (
+ "encoding/base64"
+ "flag"
+ "fmt"
+ "image"
+ "image/color"
+ "io/ioutil"
+ "os"
+ "reflect"
+ "regexp"
+ "runtime"
+ "strings"
+ "testing"
+ "time"
+
+ . "gopkg.in/check.v1"
+ "gopkg.in/qml.v1"
+ "gopkg.in/qml.v1/cpptest"
+ "gopkg.in/qml.v1/gl/2.0"
+ "path/filepath"
+)
+
+func init() { qml.SetupTesting() }
+
+func Test(t *testing.T) { TestingT(t) }
+
+type S struct {
+ engine *qml.Engine
+ context *qml.Context
+}
+
+var _ = Suite(&S{})
+
+func (s *S) SetUpTest(c *C) {
+ qml.SetLogger(c)
+ qml.CollectStats(true)
+ qml.ResetStats()
+
+ stats := qml.Stats()
+ if stats.EnginesAlive > 0 || stats.ValuesAlive > 0 || stats.ConnectionsAlive > 0 {
+ panic(fmt.Sprintf("Test started with values alive: %#v\n", stats))
+ }
+
+ s.engine = qml.NewEngine()
+ s.context = s.engine.Context()
+}
+
+func (s *S) TearDownTest(c *C) {
+ s.engine.Destroy()
+
+ retries := 30 // Three seconds top.
+ for {
+ // Do not call qml.Flush here. It creates a nested event loop
+ // that attempts to process the deferred object deletes and cannot,
+ // because deferred deletes are only processed at the same loop level.
+ // So it *reposts* the deferred deletion event, in practice *preventing*
+ // these objects from being deleted.
+ runtime.GC()
+ stats := qml.Stats()
+ if stats.EnginesAlive == 0 && stats.ValuesAlive == 0 && stats.ConnectionsAlive == 0 {
+ break
+ }
+ if retries == 0 {
+ panic(fmt.Sprintf("there are values alive:\n%#v\n", stats))
+ }
+ retries--
+ time.Sleep(100 * time.Millisecond)
+ if retries%10 == 0 {
+ c.Logf("There are still objects alive; waiting for them to die: %#v\n", stats)
+ }
+ }
+
+ qml.SetLogger(nil)
+}
+
+type GoRect struct {
+ PaintCount int
+}
+
+func (r *GoRect) Paint(p *qml.Painter) {
+ r.PaintCount++
+
+ obj := p.Object()
+
+ gl := GL.API(p)
+
+ width := float32(obj.Int("width"))
+ height := float32(obj.Int("height"))
+
+ gl.Color3f(1.0, 0.0, 0.0)
+ gl.Begin(GL.QUADS)
+ gl.Vertex2f(0, 0)
+ gl.Vertex2f(width, 0)
+ gl.Vertex2f(width, height)
+ gl.Vertex2f(0, height)
+ gl.End()
+}
+
+type GoType struct {
+ private bool // Besides being private, also adds a gap in the reflect field index.
+
+ StringValue string
+ StringAddrValue *string
+ BoolValue bool
+ IntValue int
+ Int64Value int64
+ Int32Value int32
+ Uint32Value uint32
+ Float64Value float64
+ Float32Value float32
+ AnyValue interface{}
+ ObjectValue qml.Object
+ ColorValue color.RGBA
+ IntsValue []int
+ ObjectsValue []qml.Object
+ MapValue map[string]interface{}
+
+ SetterStringValue string
+ SetterObjectsValue []qml.Object
+
+ setterStringValueChanged int
+ setterStringValueSet string
+ setterObjectsValueChanged int
+ setterObjectsValueSet []qml.Object
+
+ getterStringValue string
+ getterStringValueChanged int
+
+ // The object representing this value, on custom type tests.
+ object qml.Object
+}
+
+// Force a gap in the reflect method index and ensure the handling
+// of private methods is being done properly.
+func (ts *GoType) privateMethod() {}
+
+func (ts *GoType) StringMethod() string {
+ return ts.StringValue
+}
+
+func (ts *GoType) SetSetterStringValue(s string) {
+ ts.setterStringValueChanged++
+ ts.setterStringValueSet = s
+}
+
+func (ts *GoType) SetSetterObjectsValue(v []qml.Object) {
+ ts.setterObjectsValueChanged++
+ ts.setterObjectsValueSet = v
+}
+
+func (ts *GoType) GetterStringValue() string {
+ return ts.getterStringValue
+}
+
+func (ts *GoType) SetGetterStringValue(s string) {
+ ts.getterStringValueChanged++
+ ts.getterStringValue = s
+}
+
+func (ts *GoType) SetMapValue(m map[string]interface{}) {
+ ts.MapValue = m
+}
+
+func (ts *GoType) Mod(dividend, divisor int) (int, error) {
+ if divisor == 0 {
+ return 0, fmt.Errorf("<division by zero>")
+ }
+ return dividend % divisor, nil
+}
+
+func (ts *GoType) ChangeString(new string) (old string) {
+ old = ts.StringValue
+ ts.StringValue = new
+ return
+}
+
+func (ts *GoType) NotifyStringChanged() {
+ qml.Changed(ts, &ts.StringValue)
+}
+
+func (ts *GoType) IncrementInt() {
+ ts.IntValue++
+}
+
+func (s *S) TestEngineDestroyedUse(c *C) {
+ s.engine.Destroy()
+ s.engine.Destroy()
+ c.Assert(s.engine.Context, PanicMatches, "engine already destroyed")
+}
+
+var same = "<same>"
+
+var getSetTests = []struct{ set, get interface{} }{
+ {"value", same},
+ {true, same},
+ {false, same},
+ {int(42), same},
+ {int32(42), int(42)},
+ {int64(42), same},
+ {uint32(42), same},
+ {uint64(42), same},
+ {float64(42), same},
+ {float32(42), same},
+ {new(GoType), same},
+ {nil, same},
+ {42, same},
+}
+
+func (s *S) TestContextGetSet(c *C) {
+ for i, t := range getSetTests {
+ want := t.get
+ if t.get == same {
+ want = t.set
+ }
+ s.context.SetVar("key", t.set)
+ c.Assert(s.context.Var("key"), Equals, want,
+ Commentf("entry %d is {%v (%T), %v (%T)}", i, t.set, t.set, t.get, t.get))
+ }
+}
+
+func (s *S) TestContextGetMissing(c *C) {
+ c.Assert(s.context.Var("missing"), Equals, nil)
+}
+
+func (s *S) TestContextSetVars(c *C) {
+ component, err := s.engine.LoadString("file.qml", "import QtQuick 2.0\nItem { width: 42 }")
+ c.Assert(err, IsNil)
+ root := component.Create(nil)
+
+ vars := GoType{
+ StringValue: "<content>",
+ BoolValue: true,
+ IntValue: 42,
+ Int64Value: 42,
+ Int32Value: 42,
+ Float64Value: 4.2,
+ Float32Value: 4.2,
+ AnyValue: nil,
+ ObjectValue: root,
+ }
+ s.context.SetVars(&vars)
+
+ c.Assert(s.context.Var("stringValue"), Equals, "<content>")
+ c.Assert(s.context.Var("boolValue"), Equals, true)
+ c.Assert(s.context.Var("intValue"), Equals, 42)
+ c.Assert(s.context.Var("int64Value"), Equals, int64(42))
+ c.Assert(s.context.Var("int32Value"), Equals, 42)
+ c.Assert(s.context.Var("float64Value"), Equals, float64(4.2))
+ c.Assert(s.context.Var("float32Value"), Equals, float32(4.2))
+ c.Assert(s.context.Var("anyValue"), Equals, nil)
+
+ vars.AnyValue = 42
+ c.Assert(s.context.Var("anyValue"), Equals, 42)
+
+ c.Assert(s.context.Var("objectValue").(qml.Object).Int("width"), Equals, 42)
+}
+
+func (s *S) TestComponentSetDataError(c *C) {
+ _, err := s.engine.LoadString("file.qml", "Item{}")
+ c.Assert(err, ErrorMatches, "file:.*/file.qml:1 Item is not a type")
+}
+
+func (s *S) TestComponentCreateWindow(c *C) {
+ data := `
+ import QtQuick 2.0
+ Item { width: 300; height: 200; }
+ `
+ component, err := s.engine.LoadString("file.qml", data)
+ c.Assert(err, IsNil)
+
+ // TODO How to test this more effectively?
+ window := component.CreateWindow(nil)
+ window.Show()
+
+ // Just a smoke test, as there isn't much to assert.
+ c.Assert(window.PlatformId(), Not(Equals), uintptr(0))
+
+ // Qt doesn't hide the Window if we call it too quickly. :-(
+ time.Sleep(100 * time.Millisecond)
+ window.Hide()
+}
+
+func (s *S) TestContextSpawn(c *C) {
+ context1 := s.engine.Context()
+ context2 := context1.Spawn()
+
+ context1.SetVar("mystr", "context1")
+ context2.SetVar("mystr", "context2")
+
+ data := `
+ import QtQuick 2.0
+ Item { property var s: mystr }
+ `
+ component, err := s.engine.LoadString("file.qml", data)
+ c.Assert(err, IsNil)
+
+ obj1 := component.Create(context1)
+ obj2 := component.Create(context2)
+
+ c.Assert(obj1.String("s"), Equals, "context1")
+ c.Assert(obj2.String("s"), Equals, "context2")
+}
+
+func (s *S) TestReadVoidAddrProperty(c *C) {
+ obj := cpptest.NewTestType(s.engine)
+ addr := obj.Property("voidAddr").(uintptr)
+ c.Assert(addr, Equals, uintptr(42))
+}
+
+func (s *S) TestRegisterConverterPlainObject(c *C) {
+ qml.RegisterConverter("PlainTestType", func(engine *qml.Engine, obj qml.Object) interface{} {
+ c.Check(engine, Equals, s.engine)
+ c.Check(obj.String("plainType"), Matches, "(const )?PlainTestType[&*]?")
+ c.Check(obj.Property("plainAddr"), FitsTypeOf, uintptr(0))
+ c.Check(cpptest.PlainTestTypeN(obj), Equals, 42)
+ return "<converted>"
+ })
+ obj := cpptest.NewTestType(s.engine)
+ defer obj.Destroy()
+
+ var calls int
+ obj.On("plainEmittedCpy", func(s string) {
+ c.Check(s, Equals, "<converted>")
+ calls++
+ })
+ obj.On("plainEmittedRef", func(s string) {
+ c.Check(s, Equals, "<converted>")
+ calls++
+ })
+ obj.On("plainEmittedPtr", func(s string) {
+ c.Check(s, Equals, "<converted>")
+ calls++
+ })
+ obj.Call("emitPlain")
+ c.Assert(calls, Equals, 3)
+}
+
+func (s *S) TestIssue84(c *C) {
+ // Regression test for issue #84 (QTBUG-41193).
+ data := `
+ import QtQuick 2.0
+ Item {
+ id: item
+ property string s1: "<before>"
+ property string s2: "<after>"
+ states: State {
+ name: "after";
+ PropertyChanges { target: item; s1: s2 }
+ }
+ Component.onCompleted: state = "after"
+ }
+ `
+ filename := filepath.Join(c.MkDir(), "file.qml")
+ err := ioutil.WriteFile(filename, []byte(data), 0644)
+ c.Assert(err, IsNil)
+
+ component, err := s.engine.LoadString(filename, data)
+ c.Assert(err, IsNil)
+
+ root := component.Create(nil)
+ defer root.Destroy()
+
+ c.Assert(root.String("s1"), Equals, "<after>")
+}
+
+func (s *S) TestResources(c *C) {
+ var rp qml.ResourcesPacker
+ rp.Add("sub/path/Foo.qml", []byte("import QtQuick 2.0\nItem { Component.onCompleted: console.log('<Foo>') }"))
+ rp.AddString("sub/path/Bar.qml", "import QtQuick 2.0\nItem { Component.onCompleted: console.log('<Bar>') }")
+ rp.AddString("/sub/Main.qml", "import QtQuick 2.0\nimport \"./path\"\nItem {\nFoo{}\nBar{}\n}")
+
+ r := rp.Pack()
+ qml.LoadResources(r)
+ testResourcesLoaded(c, true)
+ qml.UnloadResources(r)
+ testResourcesLoaded(c, false)
+
+ data := r.Bytes()
+
+ rb, err := qml.ParseResources(data)
+ c.Assert(err, IsNil)
+ qml.LoadResources(rb)
+ testResourcesLoaded(c, true)
+ qml.UnloadResources(rb)
+ testResourcesLoaded(c, false)
+
+ rs, err := qml.ParseResourcesString(string(data))
+ c.Assert(err, IsNil)
+ qml.LoadResources(rs)
+ testResourcesLoaded(c, true)
+ qml.UnloadResources(rs)
+ testResourcesLoaded(c, false)
+}
+
+func testResourcesLoaded(c *C, loaded bool) {
+ engine := qml.NewEngine()
+ defer engine.Destroy()
+ component, err := engine.LoadFile("qrc:///sub/Main.qml")
+ if loaded {
+ c.Assert(err, IsNil)
+ } else {
+ c.Assert(err, ErrorMatches, "qrc:///sub/Main.qml:-1 File not found")
+ return
+ }
+ root := component.Create(nil)
+ defer root.Destroy()
+ c.Assert(c.GetTestLog(), Matches, "(?s).*(<Foo>.*<Bar>|<Bar>.*<Foo>).*")
+}
+
+func (s *S) TestResourcesIssue107(c *C) {
+ var rp qml.ResourcesPacker
+
+ rp.Add("a/Foo.qml", []byte("import QtQuick 2.0\nItem { Component.onCompleted: console.log('<Foo>') }"))
+ rp.Add("b/Bar.qml", []byte("import QtQuick 2.0\nItem { Component.onCompleted: console.log('<Bar>') }"))
+ rp.Add("c/Baz.qml", []byte("import QtQuick 2.0\nItem { Component.onCompleted: console.log('<Baz>') }"))
+ rp.Add("d/Buz.qml", []byte("import QtQuick 2.0\nItem { Component.onCompleted: console.log('<Buz>') }"))
+
+ r := rp.Pack()
+ qml.LoadResources(r)
+
+ for _, name := range []string{"a/Foo", "b/Bar", "c/Baz", "d/Buz"} {
+ component, err := s.engine.LoadFile("qrc:///" + name + ".qml")
+ c.Assert(err, IsNil)
+ root := component.Create(nil)
+ defer root.Destroy()
+ }
+ c.Assert(c.GetTestLog(), Matches, "(?s).*<Foo>.*<Bar>.*<Baz>.*<Buz>.*")
+}
+
+type TestData struct {
+ *C
+ engine *qml.Engine
+ context *qml.Context
+ component qml.Object
+ root qml.Object
+ value *GoType
+ createdValue []*GoType
+ createdRect []*GoRect
+ createdSingleton []*GoType
+}
+
+var tests = []struct {
+ Summary string
+ Value GoType
+ Rect GoRect
+
+ Init func(d *TestData)
+
+ // The QML provided is run with the initial state above, and
+ // then checks are made to ensure the provided state is found.
+ QML string
+ QMLLog string
+ QMLValue GoType
+
+ // The function provided is run with the post-QML state above,
+ // and then checks are made to ensure the provided state is found.
+ Done func(c *TestData)
+ DoneLog string
+ DoneValue GoType
+}{
+ {
+ Summary: "Read a context variable and its fields",
+ Value: GoType{StringValue: "<content>", IntValue: 42},
+ QML: `
+ Item {
+ Component.onCompleted: {
+ console.log("String is", value.stringValue)
+ console.log("Int is", value.intValue)
+ console.log("Any is", value.anyValue)
+ }
+ }
+ `,
+ QMLLog: "String is <content>.*Int is 42.*Any is undefined",
+ },
+ {
+ Summary: "Read a nested field via a value (not pointer) in an interface",
+ Value: GoType{AnyValue: struct{ StringValue string }{"<content>"}},
+ QML: `Item { Component.onCompleted: console.log("String is", value.anyValue.stringValue) }`,
+ QMLLog: "String is <content>",
+ },
+ {
+ Summary: "Read a native property",
+ QML: `Item { width: 123 }`,
+ Done: func(c *TestData) { c.Check(c.root.Int("width"), Equals, 123) },
+ },
+ {
+ Summary: "Read object properties",
+ QML: `
+ Item {
+ property bool boolp: true
+ property int intp: 1
+ property var int64p: 4294967296
+ property real float32p: 1.1
+ property double float64p: 1.1
+ property string stringp: "<content>"
+ property var objectp: Rectangle { width: 123 }
+ property var nilp: null
+ }
+ `,
+ Done: func(c *TestData) {
+ obj := c.root
+ c.Check(obj.Bool("boolp"), Equals, true)
+ c.Check(obj.Int("intp"), Equals, 1)
+ c.Check(obj.Int64("intp"), Equals, int64(1))
+ c.Check(obj.Int64("int64p"), Equals, int64(4294967296))
+ c.Check(obj.Float64("intp"), Equals, float64(1))
+ c.Check(obj.Float64("int64p"), Equals, float64(4294967296))
+ c.Check(obj.Float64("float32p"), Equals, float64(1.1))
+ c.Check(obj.Float64("float64p"), Equals, float64(1.1))
+ c.Check(obj.String("stringp"), Equals, "<content>")
+ c.Check(obj.Object("objectp").Int("width"), Equals, 123)
+ c.Check(obj.Property("nilp"), Equals, nil)
+
+ c.Check(func() { obj.Bool("intp") }, Panics, `value of property "intp" is not a bool: 1`)
+ c.Check(func() { obj.Int("boolp") }, Panics, `value of property "boolp" cannot be represented as an int: true`)
+ c.Check(func() { obj.Int64("boolp") }, Panics, `value of property "boolp" cannot be represented as an int64: true`)
+ c.Check(func() { obj.Float64("boolp") }, Panics, `value of property "boolp" cannot be represented as a float64: true`)
+ c.Check(func() { obj.String("boolp") }, Panics, `value of property "boolp" is not a string: true`)
+ c.Check(func() { obj.Object("boolp") }, Panics, `value of property "boolp" is not a QML object: true`)
+ c.Check(func() { obj.Property("missing") }, Panics, `object does not have a "missing" property`)
+ },
+ },
+ {
+ Summary: "Lowercasing of object properties",
+ Init: func(c *TestData) {
+ obj := struct{ THE, THEName, Name, N string }{"<a>", "<b>", "<c>", "<d>"}
+ c.context.SetVar("obj", &obj)
+ },
+ QML: `Item { Component.onCompleted: console.log("Names are", obj.the, obj.theName, obj.name, obj.n) }`,
+ QMLLog: "Names are <a> <b> <c> <d>",
+ },
+ {
+ Summary: "No access to private fields",
+ Value: GoType{private: true},
+ QML: `Item { Component.onCompleted: console.log("Private is", value.private); }`,
+ QMLLog: "Private is undefined",
+ },
+ {
+ Summary: "Set a custom property",
+ QML: `
+ Item {
+ property var obj: null
+
+ onObjChanged: console.log("String is", obj.stringValue)
+ onWidthChanged: console.log("Width is", width)
+ onHeightChanged: console.log("Height is", height)
+ }
+ `,
+ Done: func(c *TestData) {
+ value := GoType{StringValue: "<content>"}
+ c.root.Set("obj", &value)
+ c.root.Set("width", 300)
+ c.root.Set("height", 200)
+ },
+ DoneLog: "String is <content>.*Width is 300.*Height is 200",
+ },
+ {
+ Summary: "Read and set a QUrl property",
+ QML: `import QtWebKit 3.0; WebView {}`,
+ Done: func(c *TestData) {
+ c.Check(c.root.String("url"), Equals, "")
+ url := "http://localhost:54321"
+ c.root.Set("url", url)
+ c.Check(c.root.String("url"), Equals, url)
+ },
+ },
+ {
+ Summary: "Read and set a QColor property",
+ QML: `Text{ color: Qt.rgba(1/16, 1/8, 1/4, 1/2); function hasColor(c) { return Qt.colorEqual(color, c) }}`,
+ Done: func(c *TestData) {
+ c.Assert(c.root.Color("color"), Equals, color.RGBA{256 / 16, 256 / 8, 256 / 4, 256 / 2})
+ c.root.Set("color", color.RGBA{256 / 2, 256 / 4, 256 / 8, 256 / 16})
+ c.Assert(c.root.Call("hasColor", color.RGBA{256 / 2, 256 / 4, 256 / 8, 256 / 16}), Equals, true)
+ },
+ },
+ {
+ Summary: "Read and set a QColor property from a Go field",
+ Init: func(c *TestData) { c.value.ColorValue = color.RGBA{256 / 16, 256 / 8, 256 / 4, 256 / 2} },
+ QML: `Text{ property var c: value.colorValue; Component.onCompleted: { console.log(value.colorValue); } }`,
+ Done: func(c *TestData) {
+ c.Assert(c.root.Color("c"), Equals, color.RGBA{256 / 16, 256 / 8, 256 / 4, 256 / 2})
+ },
+ },
+ {
+ Summary: "Read a QQmlListProperty property into a Go slice",
+ QML: `
+ Item {
+ states: [
+ State { id: on; name: "on" },
+ State { id: off; name: "off" }
+ ]
+ }
+ `,
+ Done: func(c *TestData) {
+ var states []qml.Object
+ c.root.List("states").Convert(&states)
+ c.Assert(states[0].String("name"), Equals, "on")
+ c.Assert(states[1].String("name"), Equals, "off")
+ c.Assert(len(states), Equals, 2)
+ c.Assert(c.root.Property("states").(*qml.List).Len(), Equals, 2)
+ },
+ },
+ {
+ Summary: "Read a QQmlListReference property into a Go slice",
+ QML: `
+ Item {
+ property list<State> mystates: [
+ State { id: on; name: "on" },
+ State { id: off; name: "off" }
+ ]
+ Component.onCompleted: value.objectsValue = mystates
+ }
+ `,
+ Done: func(c *TestData) {
+ var states []qml.Object
+ c.root.List("mystates").Convert(&states)
+ c.Assert(states[0].String("name"), Equals, "on")
+ c.Assert(states[1].String("name"), Equals, "off")
+ c.Assert(len(states), Equals, 2)
+ c.Assert(len(c.value.ObjectsValue), Equals, 2)
+ },
+ },
+ {
+ Summary: "Read a QVariantList property into a Go slice",
+ QML: `
+ Item {
+ State { id: on; name: "on" }
+ State { id: off; name: "off" }
+ property var mystates: [on, off]
+ }
+ `,
+ Done: func(c *TestData) {
+ var states []qml.Object
+ c.root.List("mystates").Convert(&states)
+ c.Assert(states[0].String("name"), Equals, "on")
+ c.Assert(states[1].String("name"), Equals, "off")
+ c.Assert(len(states), Equals, 2)
+ },
+ },
+ {
+ Summary: "Set a Go slice property",
+ QML: `Item { Component.onCompleted: value.intsValue = [1, 2, 3.5] }`,
+ QMLValue: GoType{IntsValue: []int{1, 2, 3}},
+ },
+ {
+ Summary: "Set a Go slice property with objects",
+ QML: `
+ Item {
+ State { id: on; name: "on" }
+ State { id: off; name: "off" }
+ Component.onCompleted: value.objectsValue = [on, off]
+ }
+ `,
+ Done: func(c *TestData) {
+ c.Assert(c.value.ObjectsValue[0].String("name"), Equals, "on")
+ c.Assert(c.value.ObjectsValue[1].String("name"), Equals, "off")
+ c.Assert(len(c.value.ObjectsValue), Equals, 2)
+ },
+ },
+ {
+ Summary: "Call a method with a JSON object (issue #48)",
+ QML: `Item { Component.onCompleted: value.setMapValue({a: 1, b: 2}) }`,
+ QMLValue: GoType{MapValue: map[string]interface{}{"a": 1, "b": 2}},
+ },
+ {
+ Summary: "Read a map from a QML property",
+ QML: `Item { property var m: {"a": 1, "b": 2} }`,
+ Done: func(c *TestData) {
+ var m1 map[string]interface{}
+ var m2 map[string]int
+ m := c.root.Map("m")
+ m.Convert(&m1)
+ m.Convert(&m2)
+ c.Assert(m1, DeepEquals, map[string]interface{}{"a": 1, "b": 2})
+ c.Assert(m2, DeepEquals, map[string]int{"a": 1, "b": 2})
+ c.Assert(m.Len(), Equals, 2)
+ },
+ },
+ {
+ Summary: "Identical values remain identical when possible",
+ Init: func(c *TestData) {
+ c.context.SetVar("a", c.value)
+ c.context.SetVar("b", c.value)
+ },
+ QML: `Item { Component.onCompleted: console.log('Identical:', a === b); }`,
+ QMLLog: "Identical: true",
+ },
+ {
+ Summary: "Object finding via ObjectByName",
+ QML: `Item { Item { objectName: "subitem"; property string s: "<found>" } }`,
+ Done: func(c *TestData) {
+ obj := c.root.ObjectByName("subitem")
+ c.Check(obj.String("s"), Equals, "<found>")
+ c.Check(func() { c.root.ObjectByName("foo") }, Panics, `cannot find descendant with objectName == "foo"`)
+ },
+ },
+ {
+ Summary: "Object finding via ObjectByName on GoType",
+ QML: `Item { GoType { objectName: "subitem"; property string s: "<found>" } }`,
+ Done: func(c *TestData) {
+ obj := c.root.ObjectByName("subitem")
+ c.Check(obj.String("s"), Equals, "<found>")
+ c.Check(func() { c.root.ObjectByName("foo") }, Panics, `cannot find descendant with objectName == "foo"`)
+ },
+ },
+ {
+ Summary: "Register Go type",
+ QML: `GoType { objectName: "test"; Component.onCompleted: console.log("String is", stringValue) }`,
+ QMLLog: "String is <initial>",
+ Done: func(c *TestData) {
+ c.Assert(c.createdValue, HasLen, 1)
+ c.Assert(c.createdValue[0].object.String("objectName"), Equals, "test")
+ },
+ },
+ {
+ Summary: "Register Go type with an explicit name",
+ QML: `NamedGoType { objectName: "test"; Component.onCompleted: console.log("String is", stringValue) }`,
+ QMLLog: "String is <initial>",
+ Done: func(c *TestData) {
+ c.Assert(c.createdValue, HasLen, 1)
+ c.Assert(c.createdValue[0].object.String("objectName"), Equals, "test")
+ },
+ },
+ {
+ Summary: "Write Go type property",
+ QML: `GoType { stringValue: "<content>"; intValue: 300 }`,
+ Done: func(c *TestData) {
+ c.Assert(c.createdValue, HasLen, 1)
+ c.Assert(c.createdValue[0].StringValue, Equals, "<content>")
+ c.Assert(c.createdValue[0].IntValue, Equals, 300)
+ },
+ },
+ {
+ Summary: "Write Go type property that has a setter",
+ QML: `GoType { setterStringValue: "<content>" }`,
+ Done: func(c *TestData) {
+ c.Assert(c.createdValue, HasLen, 1)
+ c.Assert(c.createdValue[0].SetterStringValue, Equals, "")
+ c.Assert(c.createdValue[0].setterStringValueChanged, Equals, 1)
+ c.Assert(c.createdValue[0].setterStringValueSet, Equals, "<content>")
+ },
+ },
+ {
+ Summary: "Write Go type property that has a setter and a getter",
+ QML: `
+ GoType {
+ getterStringValue: "<content>"
+ Component.onCompleted: console.log("Getter returned", getterStringValue)
+ }
+ `,
+ QMLLog: `Getter returned <content>`,
+ Done: func(c *TestData) {
+ c.Assert(c.createdValue, HasLen, 1)
+ c.Assert(c.createdValue[0].getterStringValue, Equals, "<content>")
+ c.Assert(c.createdValue[0].getterStringValueChanged, Equals, 1)
+ },
+ },
+ {
+ Summary: "Write an inline object list to a Go type property",
+ QML: `
+ GoType {
+ objectsValue: [State{ name: "on" }, State{ name: "off" }]
+ Component.onCompleted: {
+ console.log("Length:", objectsValue.length)
+ console.log("Name:", objectsValue[0].name)
+ }
+ }
+ `,
+ QMLLog: "Length: 2.*Name: on",
+ Done: func(c *TestData) {
+ c.Assert(c.createdValue, HasLen, 1)
+ c.Assert(c.createdValue[0].ObjectsValue[0].String("name"), Equals, "on")
+ c.Assert(c.createdValue[0].ObjectsValue[1].String("name"), Equals, "off")
+ c.Assert(c.createdValue[0].ObjectsValue, HasLen, 2)
+ },
+ },
+ {
+ Summary: "Write an inline object list to a Go type property that has a setter",
+ QML: `GoType { setterObjectsValue: [State{ name: "on" }, State{ name: "off" }] }`,
+ Done: func(c *TestData) {
+ // Note that the setter is not actually updating the field value, for testing purposes.
+ c.Assert(c.createdValue, HasLen, 1)
+ c.Assert(c.createdValue[0].SetterObjectsValue, IsNil)
+ c.Assert(c.createdValue[0].setterObjectsValueChanged, Equals, 2)
+ c.Assert(c.createdValue[0].setterObjectsValueSet, HasLen, 1)
+ c.Assert(c.createdValue[0].setterObjectsValueSet[0].String("name"), Equals, "off")
+ },
+ },
+ {
+ Summary: "Clear an object list in a Go type property",
+ QML: `
+ GoType {
+ objectsValue: [State{ name: "on" }, State{ name: "off" }]
+ Component.onCompleted: objectsValue = []
+ }
+ `,
+ Done: func(c *TestData) {
+ c.Assert(c.createdValue, HasLen, 1)
+ c.Assert(c.createdValue[0].ObjectsValue, HasLen, 0)
+ },
+ },
+ {
+ Summary: "Clear an object list in a Go type property that has a setter",
+ Value: GoType{SetterObjectsValue: []qml.Object{nil, nil}},
+ QML: `
+ GoType {
+ objectsValue: [State{ name: "on" }, State{ name: "off" }]
+ function clear() { setterObjectsValue = [] }
+ }
+ `,
+ Done: func(c *TestData) {
+ // Note that the setter is not actually updating the field value, for testing purposes.
+ c.Assert(c.createdValue, HasLen, 1)
+ c.createdValue[0].SetterObjectsValue = c.createdValue[0].ObjectsValue
+
+ c.createdValue[0].object.Call("clear")
+
+ c.Assert(c.createdValue[0].SetterObjectsValue, HasLen, 2)
+ c.Assert(c.createdValue[0].setterObjectsValueChanged, Equals, 1)
+ c.Assert(c.createdValue[0].setterObjectsValueSet, DeepEquals, []qml.Object{})
+ c.Assert(&c.createdValue[0].SetterObjectsValue[0], Equals, &c.createdValue[0].ObjectsValue[0])
+ },
+ },
+ {
+ Summary: "Access underlying Go value with Interface",
+ QML: `GoType { stringValue: "<content>" }`,
+ Done: func(c *TestData) {
+ c.Assert(c.root.Interface().(*GoType).StringValue, Equals, "<content>")
+ c.Assert(c.context.Interface, Panics, "QML object is not backed by a Go value")
+ },
+ },
+ {
+ Summary: "Notification signals on custom Go type",
+ QML: `
+ GoType {
+ id: custom
+ stringValue: "<old>"
+ onStringValueChanged: if (custom.stringValue != "<newest>") { custom.stringValue = "<newest>" }
+ Component.onCompleted: custom.stringValue = "<new>"
+ }
+ `,
+ Done: func(c *TestData) {
+ c.Assert(c.createdValue, HasLen, 1)
+ c.Assert(c.createdValue[0].StringValue, Equals, "<newest>")
+ },
+ },
+ {
+ Summary: "Singleton type registration",
+ QML: `Item { Component.onCompleted: console.log("String is", GoSingleton.stringValue) }`,
+ QMLLog: "String is <initial>",
+ },
+ {
+ Summary: "qml.Changed on unknown value is okay",
+ Value: GoType{StringValue: "<old>"},
+ Init: func(c *TestData) {
+ value := &GoType{}
+ qml.Changed(&value, &value.StringValue)
+ },
+ QML: `Item{}`,
+ },
+ {
+ Summary: "qml.Changed triggers a QML slot",
+ QML: `
+ GoType {
+ stringValue: "<old>"
+ onStringValueChanged: console.log("String is", stringValue)
+ onStringAddrValueChanged: console.log("String at addr is", stringAddrValue)
+ }
+ `,
+ QMLLog: "!String is",
+ Done: func(c *TestData) {
+ c.Assert(c.createdValue, HasLen, 1)
+ value := c.createdValue[0]
+ s := "<new at addr>"
+ value.StringValue = "<new>"
+ value.StringAddrValue = &s
+ qml.Changed(value, &value.StringValue)
+ qml.Changed(value, &value.StringAddrValue)
+ },
+ DoneLog: "String is <new>.*String at addr is <new at addr>",
+ },
+ {
+ Summary: "qml.Changed must not trigger on the wrong field",
+ QML: `
+ GoType {
+ stringValue: "<old>"
+ onStringValueChanged: console.log("String is", stringValue)
+ }
+ `,
+ Done: func(c *TestData) {
+ c.Assert(c.createdValue, HasLen, 1)
+ value := c.createdValue[0]
+ value.StringValue = "<new>"
+ qml.Changed(value, &value.IntValue)
+ },
+ DoneLog: "!String is",
+ },
+ {
+ Summary: "qml.Changed updates bindings",
+ Value: GoType{StringValue: "<old>"},
+ QML: `Item { property string s: "String is " + value.stringValue }`,
+ Done: func(c *TestData) {
+ c.value.StringValue = "<new>"
+ qml.Changed(c.value, &c.value.StringValue)
+ c.Check(c.root.String("s"), Equals, "String is <new>")
+ },
+ },
+ {
+ Summary: "Call a Go method without arguments or result",
+ Value: GoType{IntValue: 42},
+ QML: `Item { Component.onCompleted: console.log("Undefined is", value.incrementInt()); }`,
+ QMLLog: "Undefined is undefined",
+ QMLValue: GoType{IntValue: 43},
+ },
+ {
+ Summary: "Call a Go method with one argument and one result",
+ Value: GoType{StringValue: "<old>"},
+ QML: `Item { Component.onCompleted: console.log("String was", value.changeString("<new>")); }`,
+ QMLLog: "String was <old>",
+ QMLValue: GoType{StringValue: "<new>"},
+ },
+ {
+ Summary: "Call a Go method with multiple results",
+ QML: `
+ Item {
+ Component.onCompleted: {
+ var r = value.mod(42, 4);
+ console.log("mod is", r[0], "and err is", r[1]);
+ }
+ }
+ `,
+ QMLLog: `mod is 2 and err is undefined`,
+ },
+ {
+ Summary: "Call a Go method that returns an error",
+ QML: `
+ Item {
+ Component.onCompleted: {
+ var r = value.mod(0, 0);
+ console.log("err is", r[1].error());
+ }
+ }
+ `,
+ QMLLog: `err is <division by zero>`,
+ },
+ {
+ Summary: "Call a Go method that recurses back into the GUI thread",
+ QML: `
+ Item {
+ Connections {
+ target: value
+ onStringValueChanged: console.log("Notification arrived")
+ }
+ Component.onCompleted: {
+ value.notifyStringChanged()
+ }
+ }
+ `,
+ QMLLog: "Notification arrived",
+ },
+ {
+ Summary: "Connect a QML signal to a Go method",
+ Value: GoType{StringValue: "<old>"},
+ QML: `
+ Item {
+ id: item
+ signal testSignal(string s)
+ Component.onCompleted: {
+ item.testSignal.connect(value.changeString)
+ item.testSignal("<new>")
+ }
+ }
+ `,
+ QMLValue: GoType{StringValue: "<new>"},
+ },
+ {
+ Summary: "Call a QML method with no result or parameters from Go",
+ QML: `Item { function f() { console.log("f was called"); } }`,
+ Done: func(c *TestData) { c.Check(c.root.Call("f"), IsNil) },
+ DoneLog: "f was called",
+ },
+ {
+ Summary: "Call a QML method with result and parameters from Go",
+ QML: `Item { function add(a, b) { return a+b; } }`,
+ Done: func(c *TestData) { c.Check(c.root.Call("add", 1, 2.1), Equals, float64(3.1)) },
+ },
+ {
+ Summary: "Call a QML method with a custom type",
+ Value: GoType{StringValue: "<content>"},
+ QML: `Item { function log(value) { console.log("String is", value.stringValue) } }`,
+ Done: func(c *TestData) { c.root.Call("log", c.value) },
+ DoneLog: "String is <content>",
+ },
+ {
+ Summary: "Call a QML method that returns a QML object",
+ QML: `
+ Item {
+ property var custom: Rectangle { width: 300; }
+ function f() { return custom }
+ }
+ `,
+ Done: func(c *TestData) {
+ c.Check(c.root.Call("f").(qml.Object).Int("width"), Equals, 300)
+ },
+ },
+ {
+ Summary: "Call a QML method that holds a custom type past the return point",
+ QML: `
+ Item {
+ property var held
+ function hold(v) { held = v; gc(); gc(); }
+ function log() { console.log("String is", held.stringValue) }
+ }`,
+ Done: func(c *TestData) {
+ value := GoType{StringValue: "<content>"}
+ stats := qml.Stats()
+ c.root.Call("hold", &value)
+ c.Check(qml.Stats().ValuesAlive, Equals, stats.ValuesAlive+1)
+ c.root.Call("log")
+ c.root.Call("hold", nil)
+ c.Check(qml.Stats().ValuesAlive, Equals, stats.ValuesAlive)
+ },
+ DoneLog: "String is <content>",
+ },
+ {
+ Summary: "Call a non-existent QML method",
+ QML: `Item {}`,
+ Done: func(c *TestData) {
+ c.Check(func() { c.root.Call("add", 1, 2) }, Panics, `object does not expose a method "add"`)
+ },
+ },
+ {
+ Summary: "Ensure URL of provided file is correct by loading a local file",
+ Init: func(c *TestData) {
+ data, err := base64.StdEncoding.DecodeString("R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw==")
+ c.Assert(err, IsNil)
+ err = ioutil.WriteFile("test.gif", data, 0644)
+ c.Check(err, IsNil)
+ },
+ QML: `Image { source: "test.gif"; Component.onCompleted: console.log("Ready:", status == Image.Ready) }`,
+ QMLLog: "Ready: true",
+ Done: func(c *TestData) { os.Remove("test.gif") },
+ },
+ {
+ Summary: "Create window with non-window root object",
+ QML: `Rectangle { width: 300; height: 200; function inc(x) { return x+1 } }`,
+ Done: func(c *TestData) {
+ win := c.component.CreateWindow(nil)
+ root := win.Root()
+ c.Check(root.Int("width"), Equals, 300)
+ c.Check(root.Int("height"), Equals, 200)
+ c.Check(root.Call("inc", 42.5), Equals, float64(43.5))
+ root.Destroy()
+ },
+ },
+ {
+ Summary: "Create window with window root object",
+ QML: `
+ import QtQuick.Window 2.0
+ Window { title: "<title>"; width: 300; height: 200 }
+ `,
+ Done: func(c *TestData) {
+ win := c.component.CreateWindow(nil)
+ root := win.Root()
+ c.Check(root.String("title"), Equals, "<title>")
+ c.Check(root.Int("width"), Equals, 300)
+ c.Check(root.Int("height"), Equals, 200)
+ },
+ },
+ {
+ Summary: "Window is object",
+ QML: `Item {}`,
+ Done: func(c *TestData) {
+ win := c.component.CreateWindow(nil)
+ c.Assert(win.Int("status"), Equals, 1) // Ready
+ },
+ },
+ {
+ Summary: "Pass a *Value back into a method",
+ QML: `Rectangle { width: 300; function log(r) { console.log("Width is", r.width) } }`,
+ Done: func(c *TestData) { c.root.Call("log", c.root) },
+ DoneLog: "Width is 300",
+ },
+ {
+ Summary: "Create a QML-defined component in Go",
+ QML: `Item { property var comp: Component { Rectangle { width: 300 } } }`,
+ Done: func(c *TestData) {
+ rect := c.root.Object("comp").Create(nil)
+ c.Check(rect.Int("width"), Equals, 300)
+ c.Check(func() { c.root.Create(nil) }, Panics, "object is not a component")
+ c.Check(func() { c.root.CreateWindow(nil) }, Panics, "object is not a component")
+ },
+ },
+ {
+ Summary: "Call a Qt method that has no result",
+ QML: `Item { Component.onDestruction: console.log("item destroyed") }`,
+ Done: func(c *TestData) {
+ // Create a local instance to avoid double-destroying it.
+ root := c.component.Create(nil)
+ root.Call("deleteLater")
+ time.Sleep(100 * time.Millisecond)
+ },
+ DoneLog: "item destroyed",
+ },
+ {
+ Summary: "Errors connecting to QML signals",
+ QML: `Item { signal doIt() }`,
+ Done: func(c *TestData) {
+ c.Check(func() { c.root.On("missing", func() {}) }, Panics, `object does not expose a "missing" signal`)
+ c.Check(func() { c.root.On("doIt", func(s string) {}) }, Panics, `signal "doIt" has too few parameters for provided function`)
+ },
+ },
+ {
+ Summary: "Connect to a QML signal without parameters",
+ QML: `
+ Item {
+ id: item
+ signal doIt()
+ function emitDoIt() { item.doIt() }
+ }
+ `,
+ Done: func(c *TestData) {
+ itWorks := false
+ c.root.On("doIt", func() { itWorks = true })
+ c.Check(itWorks, Equals, false)
+ c.root.Call("emitDoIt")
+ c.Check(itWorks, Equals, true)
+ },
+ },
+ {
+ Summary: "Connect to a QML signal with a parameters",
+ QML: `
+ Item {
+ id: item
+ signal doIt(string s, int n)
+ function emitDoIt() { item.doIt("<arg>", 123) }
+ }
+ `,
+ Done: func(c *TestData) {
+ var stack []interface{}
+ c.root.On("doIt", func() { stack = append(stack, "A") })
+ c.root.On("doIt", func(s string) { stack = append(stack, "B", s) })
+ c.root.On("doIt", func(s string, i int) { stack = append(stack, "C", s, i) })
+ c.Check(stack, IsNil)
+ c.root.Call("emitDoIt")
+ c.Check(stack, DeepEquals, []interface{}{"A", "B", "<arg>", "C", "<arg>", 123})
+ },
+ },
+ {
+ Summary: "Connect to a QML signal with an object parameter",
+ QML: `import QtWebKit 3.0; WebView{}`,
+ Done: func(c *TestData) {
+ url := "http://localhost:54321/"
+ done := make(chan bool)
+ c.root.On("navigationRequested", func(request qml.Object) {
+ c.Check(request.String("url"), Equals, url)
+ done <- true
+ })
+ c.root.Set("url", url)
+ <-done
+ },
+ },
+ {
+ Summary: "Load image from Go provider",
+ Init: func(c *TestData) {
+ c.engine.AddImageProvider("myprov", func(id string, width, height int) image.Image {
+ return image.NewRGBA(image.Rect(0, 0, 200, 100))
+ })
+ },
+ QML: `
+ Image {
+ source: "image://myprov/myid.png"
+ Component.onCompleted: console.log("Size:", width, height)
+ }
+ `,
+ QMLLog: "Size: 200 100",
+ },
+ {
+ Summary: "TypeName",
+ QML: `Item{}`,
+ Done: func(c *TestData) { c.Assert(c.root.TypeName(), Equals, "QQuickItem") },
+ },
+ {
+ Summary: "Custom Go type with painting",
+ QML: `
+ Rectangle {
+ width: 200; height: 200
+ color: "black"
+ GoRect {
+ width: 100; height: 100; x: 50; y: 50
+ }
+ }
+ `,
+ Done: func(c *TestData) {
+ c.Assert(c.createdRect, HasLen, 0)
+
+ window := c.component.CreateWindow(nil)
+ defer window.Destroy()
+ window.Show()
+
+ // Qt doesn't hide the Window if we call it too quickly. :-(
+ time.Sleep(100 * time.Millisecond)
+
+ c.Assert(c.createdRect, HasLen, 1)
+ c.Assert(c.createdRect[0].PaintCount, Equals, 1)
+
+ image := window.Snapshot()
+ c.Assert(image.At(25, 25), Equals, color.RGBA{0, 0, 0, 255})
+ c.Assert(image.At(100, 100), Equals, color.RGBA{255, 0, 0, 255})
+ },
+ },
+ {
+ Summary: "Set a property with the wrong type",
+ QML: `
+ import QtQuick.Window 2.0
+ Window { Rectangle { objectName: "rect" } }
+ `,
+ Done: func(c *TestData) {
+ window := c.component.CreateWindow(nil)
+ defer window.Destroy()
+
+ root := window.Root() // It's the window itself in this case
+ rect := root.ObjectByName("rect")
+
+ c.Assert(func() { rect.Set("parent", root) }, Panics,
+ `cannot set property "parent" with type QQuickItem* to value of QQuickWindow*`)
+ c.Assert(func() { rect.Set("parent", 42) }, Panics,
+ `cannot set property "parent" with type QQuickItem* to value of int`)
+ c.Assert(func() { rect.Set("non_existent", 0) }, Panics,
+ `cannot set non-existent property "non_existent" on type QQuickRectangle`)
+ },
+ },
+ {
+ Summary: "Register a type converter for a signal parameter",
+ QML: `
+ Item {
+ id: item
+ property Item self
+ signal testSignal(Item obj)
+ function emitSignal() { item.testSignal(item) }
+ function getSelf() { return item }
+ Component.onCompleted: { self = item }
+ }
+ `,
+ Done: func(c *TestData) {
+ type Wrapper struct{ Item qml.Object }
+ qml.RegisterConverter(c.root.TypeName(), func(engine *qml.Engine, item qml.Object) interface{} {
+ return &Wrapper{item}
+ })
+ defer qml.RegisterConverter(c.root.TypeName(), nil)
+
+ // Check that it works on signal parameters...
+ c.root.On("testSignal", func(wrapped *Wrapper) {
+ c.Check(wrapped.Item.Addr(), Equals, c.root.Addr())
+ c.Logf("Signal has run.")
+ })
+ c.root.Call("emitSignal")
+
+ // ... on properties ...
+ wrapped, ok := c.root.Property("self").(*Wrapper)
+ if c.Check(ok, Equals, true) {
+ c.Check(wrapped.Item.Addr(), Equals, c.root.Addr())
+ }
+
+ // ... and on results.
+ wrapped, ok = c.root.Call("getSelf").(*Wrapper)
+ if c.Check(ok, Equals, true) {
+ c.Check(wrapped.Item.Addr(), Equals, c.root.Addr())
+ }
+
+ // Now unregister and ensure it got disabled.
+ qml.RegisterConverter(c.root.TypeName(), nil)
+ _, ok = c.root.Property("self").(*qml.Common)
+ c.Check(ok, Equals, true)
+ },
+ DoneLog: "Signal has run.",
+ },
+ {
+ Summary: "References handed out must not be GCd (issue #68)",
+ Init: func(c *TestData) {
+ type B struct{ S string }
+ type A struct{ B *B }
+ c.context.SetVar("a", &A{&B{}})
+ },
+ QML: `Item { function f() { var x = [[],[],[]]; gc(); if (!a.b) console.log("BUG"); } }`,
+ Done: func(c *TestData) {
+ for i := 0; i < 100; i++ {
+ c.root.Call("f")
+ }
+ },
+ DoneLog: "!BUG",
+ },
+}
+
+var tablef = flag.String("tablef", "", "if provided, TestTable only runs tests with a summary matching the regexp")
+
+func (s *S) TestTable(c *C) {
+ var testData TestData
+
+ types := []qml.TypeSpec{{
+ Init: func(v *GoType, obj qml.Object) {
+ v.object = obj
+ v.StringValue = "<initial>"
+ testData.createdValue = append(testData.createdValue, v)
+ },
+ }, {
+ Name: "NamedGoType",
+ Init: func(v *GoType, obj qml.Object) {
+ v.object = obj
+ v.StringValue = "<initial>"
+ testData.createdValue = append(testData.createdValue, v)
+ },
+ }, {
+ Name: "GoSingleton",
+ Init: func(v *GoType, obj qml.Object) {
+ v.object = obj
+ v.StringValue = "<initial>"
+ testData.createdSingleton = append(testData.createdSingleton, v)
+ },
+ Singleton: true,
+ }, {
+ Init: func(v *GoRect, obj qml.Object) {
+ testData.createdRect = append(testData.createdRect, v)
+ },
+ }}
+
+ qml.RegisterTypes("GoTypes", 4, 2, types)
+
+ filter := regexp.MustCompile("")
+ if tablef != nil {
+ filter = regexp.MustCompile(*tablef)
+ }
+
+ for i := range tests {
+ s.TearDownTest(c)
+ t := &tests[i]
+ header := fmt.Sprintf("----- Running table test %d: %s -----", i, t.Summary)
+ if !filter.MatchString(header) {
+ continue
+ }
+ c.Log(header)
+ s.SetUpTest(c)
+
+ value := t.Value
+ s.context.SetVar("value", &value)
+
+ testData = TestData{
+ C: c,
+ value: &value,
+ engine: s.engine,
+ context: s.context,
+ }
+
+ if t.Init != nil {
+ t.Init(&testData)
+ if c.Failed() {
+ c.FailNow()
+ }
+ }
+
+ component, err := s.engine.LoadString("file.qml", "import QtQuick 2.0\nimport GoTypes 4.2\n"+strings.TrimSpace(t.QML))
+ c.Assert(err, IsNil)
+
+ logMark := c.GetTestLog()
+
+ // The component instance is destroyed before the loop ends below,
+ // but do a defer to ensure it will be destroyed if the test fails.
+ root := component.Create(nil)
+ defer root.Destroy()
+
+ testData.component = component
+ testData.root = root
+
+ if t.QMLLog != "" {
+ logged := c.GetTestLog()[len(logMark):]
+ if t.QMLLog[0] == '!' {
+ c.Check(logged, Not(Matches), "(?s).*"+t.QMLLog[1:]+".*")
+ } else {
+ c.Check(logged, Matches, "(?s).*"+t.QMLLog+".*")
+ }
+ }
+
+ if !reflect.DeepEqual(t.QMLValue, GoType{}) {
+ c.Check(value.StringValue, Equals, t.QMLValue.StringValue)
+ c.Check(value.StringAddrValue, Equals, t.QMLValue.StringAddrValue)
+ c.Check(value.BoolValue, Equals, t.QMLValue.BoolValue)
+ c.Check(value.IntValue, Equals, t.QMLValue.IntValue)
+ c.Check(value.Int64Value, Equals, t.QMLValue.Int64Value)
+ c.Check(value.Int32Value, Equals, t.QMLValue.Int32Value)
+ c.Check(value.Float64Value, Equals, t.QMLValue.Float64Value)
+ c.Check(value.Float32Value, Equals, t.QMLValue.Float32Value)
+ c.Check(value.AnyValue, Equals, t.QMLValue.AnyValue)
+ c.Check(value.IntsValue, DeepEquals, t.QMLValue.IntsValue)
+ c.Check(value.MapValue, DeepEquals, t.QMLValue.MapValue)
+ }
+
+ if !c.Failed() {
+ logMark := c.GetTestLog()
+
+ if t.Done != nil {
+ t.Done(&testData)
+ }
+
+ if t.DoneLog != "" {
+ logged := c.GetTestLog()[len(logMark):]
+ if t.DoneLog[0] == '!' {
+ c.Check(logged, Not(Matches), "(?s).*"+t.DoneLog[1:]+".*")
+ } else {
+ c.Check(logged, Matches, "(?s).*"+t.DoneLog+".*")
+ }
+ }
+
+ if !reflect.DeepEqual(t.DoneValue, GoType{}) {
+ c.Check(value.StringValue, Equals, t.DoneValue.StringValue)
+ c.Check(value.StringAddrValue, Equals, t.DoneValue.StringAddrValue)
+ c.Check(value.BoolValue, Equals, t.DoneValue.BoolValue)
+ c.Check(value.IntValue, Equals, t.DoneValue.IntValue)
+ c.Check(value.Int64Value, Equals, t.DoneValue.Int64Value)
+ c.Check(value.Int32Value, Equals, t.DoneValue.Int32Value)
+ c.Check(value.Float64Value, Equals, t.DoneValue.Float64Value)
+ c.Check(value.Float32Value, Equals, t.DoneValue.Float32Value)
+ c.Check(value.AnyValue, Equals, t.DoneValue.AnyValue)
+ c.Check(value.IntsValue, DeepEquals, t.DoneValue.IntsValue)
+ c.Check(value.MapValue, DeepEquals, t.DoneValue.MapValue)
+ }
+ }
+
+ root.Destroy()
+
+ if c.Failed() {
+ c.FailNow() // So relevant logs are at the bottom.
+ }
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/resources.go b/Godeps/_workspace/src/github.com/obscuren/qml/resources.go
new file mode 100644
index 000000000..3809c1135
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/resources.go
@@ -0,0 +1,375 @@
+package qml
+
+import (
+ "bytes"
+ "fmt"
+ "sort"
+ "strings"
+)
+
+// ParseResources parses the resources collection serialized in data.
+func ParseResources(data []byte) (*Resources, error) {
+ if len(data) < 20 || string(data[:4]) != "qres" {
+ return nil, fmt.Errorf("invalid resources data")
+ }
+ r, err := parseResourcesHeader(data[:20], len(data))
+ if err != nil {
+ return nil, err
+ }
+ r.bdata = data
+ return r, nil
+}
+
+// ParseResourcesString parses the resources collection serialized in data.
+func ParseResourcesString(data string) (*Resources, error) {
+ if len(data) < 20 || data[:4] != "qres" {
+ return nil, fmt.Errorf("invalid resources data")
+ }
+ r, err := parseResourcesHeader([]byte(data[:20]), len(data))
+ if err != nil {
+ return nil, err
+ }
+ r.sdata = data
+ return r, nil
+}
+
+func parseResourcesHeader(h []byte, size int) (*Resources, error) {
+ r := &Resources{
+ version: read32(h[4:]),
+ treeOffset: read32(h[8:]),
+ dataOffset: read32(h[12:]),
+ nameOffset: read32(h[16:]),
+ }
+ if r.version != resVersion {
+ return nil, fmt.Errorf("unsupported resources version: %d", r.version)
+ }
+ // Ideally this would do a full validation, but it's a good start.
+ if !(20 <= r.treeOffset && r.treeOffset < size &&
+ 20 <= r.dataOffset && r.dataOffset < size &&
+ 20 <= r.nameOffset && r.nameOffset < size) {
+ return nil, fmt.Errorf("corrupted resources data")
+ }
+ return r, nil
+}
+
+func read32(b []byte) int {
+ return int(uint32(b[0])<<24 | uint32(b[1])<<16 | uint32(b[2])<<8 | uint32(b[3]))
+}
+
+// Resources is a compact representation of a collection of resources
+// (images, qml files, etc) that may be loaded by an Engine and referenced
+// by QML at "qrc:///some/path", where "some/path" is the path the
+// resource was added with.
+//
+// Resources must be registered with LoadResources to become available.
+type Resources struct {
+ sdata string
+ bdata []byte
+
+ version int
+ treeOffset int
+ dataOffset int
+ nameOffset int
+}
+
+// Bytes returns a binary representation of the resources collection that
+// may be parsed back with ParseResources or ParseResourcesString.
+func (r *Resources) Bytes() []byte {
+ if len(r.sdata) > 0 {
+ return []byte(r.sdata)
+ }
+ return r.bdata
+}
+
+// ResourcesPacker builds a Resources collection with provided resources.
+type ResourcesPacker struct {
+ root resFile
+}
+
+// Pack builds a resources collection with all resources previously added.
+func (rp *ResourcesPacker) Pack() *Resources {
+ rw := newResourcesWriter(rp)
+ rw.write()
+ return &Resources{
+ bdata: rw.out.Bytes(),
+ version: resVersion,
+ dataOffset: rw.dataOffset,
+ nameOffset: rw.nameOffset,
+ treeOffset: rw.treeOffset,
+ }
+}
+
+type resFile struct {
+ name string
+ sdata string
+ bdata []byte
+
+ children resFiles
+}
+
+// Add adds a resource with the provided data under "qrc:///"+path.
+func (rp *ResourcesPacker) Add(path string, data []byte) {
+ file := rp.addFile(path)
+ file.bdata = data
+}
+
+// AddString adds a resource with the provided data under "qrc:///"+path.
+func (rp *ResourcesPacker) AddString(path, data string) {
+ file := rp.addFile(path)
+ file.sdata = data
+}
+
+func (rp *ResourcesPacker) addFile(path string) *resFile {
+ file := &rp.root
+ names := strings.Split(path, "/")
+ if len(names[0]) == 0 {
+ names = names[1:]
+ }
+NextItem:
+ for _, name := range names {
+ for i := range file.children {
+ child := &file.children[i]
+ if child.name == name {
+ file = child
+ continue NextItem
+ }
+ }
+ file.children = append(file.children, resFile{name: name})
+ file = &file.children[len(file.children)-1]
+ }
+ if len(file.children) > 0 || file.sdata != "" || file.bdata != nil {
+ panic("cannot add same resources path twice: " + path)
+ }
+ return file
+}
+
+type resWriter struct {
+ root *resFile
+
+ treeOffset int
+ dataOffset int
+ nameOffset int
+
+ treeOffsets map[*resFile]int
+ dataOffsets map[*resFile]int
+ nameOffsets map[string]int
+
+ pending []*resFile
+ out bytes.Buffer
+}
+
+func newResourcesWriter(rp *ResourcesPacker) *resWriter {
+ rw := &resWriter{
+ root: &rp.root,
+ treeOffsets: make(map[*resFile]int),
+ dataOffsets: make(map[*resFile]int),
+ nameOffsets: make(map[string]int),
+ pending: make([]*resFile, maxPending(&rp.root)),
+ }
+
+ pending := rw.pending
+ pending[0] = rw.root
+ n := 1
+ for n > 0 {
+ n--
+ file := pending[n]
+ sort.Sort(file.children)
+ for i := range file.children {
+ child := &file.children[i]
+ if len(child.children) > 0 {
+ pending[n] = child
+ n++
+ }
+ }
+ }
+ return rw
+}
+
+func maxPending(file *resFile) int {
+ max := 1
+ for i := range file.children {
+ if len(file.children) > 0 {
+ max += maxPending(&file.children[i])
+ }
+ }
+ return max
+}
+
+func (rw *resWriter) write() {
+ rw.writeHeader()
+ rw.writeDataBlobs()
+ rw.writeDataNames()
+ rw.writeDataTree()
+ rw.finishHeader()
+}
+
+func (rw *resWriter) writeHeader() {
+ rw.out.WriteString("qres\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00")
+}
+
+func (rw *resWriter) finishHeader() {
+ rw.write32at(4, resVersion)
+ rw.write32at(8, uint32(rw.treeOffset))
+ rw.write32at(12, uint32(rw.dataOffset))
+ rw.write32at(16, uint32(rw.nameOffset))
+}
+
+func (rw *resWriter) writeDataBlobs() {
+ rw.dataOffset = rw.out.Len()
+ pending := rw.pending
+ pending[0] = rw.root
+ n := 1
+ for n > 0 {
+ n--
+ file := pending[n]
+ for i := range file.children {
+ child := &file.children[i]
+ if len(child.children) > 0 {
+ pending[n] = child
+ n++
+ } else {
+ rw.dataOffsets[child] = rw.out.Len() - rw.dataOffset
+ rw.writeDataBlob(child)
+ }
+ }
+ }
+}
+
+func (rw *resWriter) writeDataBlob(file *resFile) {
+ if len(file.sdata) > 0 {
+ rw.write32(uint32(len(file.sdata)))
+ rw.out.WriteString(file.sdata)
+ } else {
+ rw.write32(uint32(len(file.bdata)))
+ rw.out.Write(file.bdata)
+ }
+}
+
+func (rw *resWriter) writeDataNames() {
+ rw.nameOffset = rw.out.Len()
+ pending := rw.pending
+ pending[0] = rw.root
+ n := 1
+ for n > 0 {
+ n--
+ file := pending[n]
+ for i := range file.children {
+ child := &file.children[i]
+ if len(child.children) > 0 {
+ pending[n] = child
+ n++
+ }
+ if _, ok := rw.nameOffsets[child.name]; !ok {
+ rw.nameOffsets[child.name] = rw.out.Len() - rw.nameOffset
+ rw.writeDataName(child.name)
+ }
+ }
+ }
+}
+
+func (rw *resWriter) writeDataName(name string) {
+ rw.write16(uint16(len(name)))
+ rw.write32(qt_hash(name))
+ for _, r := range name {
+ rw.write16(uint16(r))
+ }
+}
+
+func (rw *resWriter) writeDataTree() {
+ rw.treeOffset = rw.out.Len()
+
+ // Compute first child offset for each parent.
+ pending := rw.pending
+ pending[0] = rw.root
+ n := 1
+ offset := 1
+ for n > 0 {
+ n--
+ file := pending[n]
+ rw.treeOffsets[file] = offset
+ for i := range file.children {
+ child := &file.children[i]
+ offset++
+ if len(child.children) > 0 {
+ pending[n] = child
+ n++
+ }
+ }
+ }
+
+ // Actually write it out.
+ rw.writeDataInfo(rw.root)
+ pending[0] = rw.root
+ n = 1
+ for n > 0 {
+ n--
+ file := pending[n]
+ for i := range file.children {
+ child := &file.children[i]
+ rw.writeDataInfo(child)
+ if len(child.children) > 0 {
+ pending[n] = child
+ n++
+ }
+ }
+ }
+}
+
+func (rw *resWriter) writeDataInfo(file *resFile) {
+ rw.write32(uint32(rw.nameOffsets[file.name]))
+ if len(file.children) > 0 {
+ rw.write16(uint16(resDirectory))
+ rw.write32(uint32(len(file.children)))
+ rw.write32(uint32(rw.treeOffsets[file]))
+ } else {
+ rw.write16(uint16(resNone))
+ rw.write16(0) // QLocale::AnyCountry
+ rw.write16(1) // QLocale::C
+ rw.write32(uint32(rw.dataOffsets[file]))
+ }
+}
+
+const (
+ resVersion = 1
+
+ resNone = 0
+ resCompressed = 1
+ resDirectory = 2
+)
+
+func (rw *resWriter) write16(v uint16) {
+ rw.out.Write([]byte{byte(v >> 8), byte(v)})
+}
+
+func (rw *resWriter) write32(v uint32) {
+ rw.out.Write([]byte{byte(v >> 24), byte(v >> 16), byte(v >> 8), byte(v)})
+}
+
+func (rw *resWriter) write32at(index int, v uint32) {
+ b := rw.out.Bytes()
+ b[index+0] = byte(v >> 24)
+ b[index+1] = byte(v >> 16)
+ b[index+2] = byte(v >> 8)
+ b[index+3] = byte(v)
+}
+
+type resFiles []resFile
+
+func (rf resFiles) Len() int { return len(rf) }
+func (rf resFiles) Less(i, j int) bool { return qt_hash(rf[i].name) < qt_hash(rf[j].name) }
+func (rf resFiles) Swap(i, j int) { rf[i], rf[j] = rf[j], rf[i] }
+
+// qt_hash returns the hash of p as determined by the internal qt_hash function in Qt.
+//
+// According to the documentation in qhash.cpp this algorithm is used whenever
+// the hash may be stored or reused across Qt versions, and must not change.
+// The algorithm in qHash (used in QString, etc) is different and may change.
+func qt_hash(p string) uint32 {
+ var h uint32
+ for _, r := range p {
+ h = (h << 4) + uint32(r)
+ h ^= (h & 0xf0000000) >> 23
+ h &= 0x0fffffff
+ }
+ return h
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/stats.go b/Godeps/_workspace/src/github.com/obscuren/qml/stats.go
new file mode 100644
index 000000000..9f6e94d83
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/stats.go
@@ -0,0 +1,68 @@
+package qml
+
+import (
+ "sync"
+)
+
+var stats *Statistics
+var statsMutex sync.Mutex
+
+func Stats() (snapshot Statistics) {
+ statsMutex.Lock()
+ snapshot = *stats
+ statsMutex.Unlock()
+ return
+}
+
+func CollectStats(enabled bool) {
+ statsMutex.Lock()
+ if enabled {
+ if stats == nil {
+ stats = &Statistics{}
+ }
+ } else {
+ stats = nil
+ }
+ statsMutex.Unlock()
+}
+
+func ResetStats() {
+ statsMutex.Lock()
+ old := stats
+ stats = &Statistics{}
+ // These are absolute values:
+ stats.EnginesAlive = old.EnginesAlive
+ stats.ValuesAlive = old.ValuesAlive
+ statsMutex.Unlock()
+ return
+}
+
+type Statistics struct {
+ EnginesAlive int
+ ValuesAlive int
+ ConnectionsAlive int
+}
+
+func (stats *Statistics) enginesAlive(delta int) {
+ if stats != nil {
+ statsMutex.Lock()
+ stats.EnginesAlive += delta
+ statsMutex.Unlock()
+ }
+}
+
+func (stats *Statistics) valuesAlive(delta int) {
+ if stats != nil {
+ statsMutex.Lock()
+ stats.ValuesAlive += delta
+ statsMutex.Unlock()
+ }
+}
+
+func (stats *Statistics) connectionsAlive(delta int) {
+ if stats != nil {
+ statsMutex.Lock()
+ stats.ConnectionsAlive += delta
+ statsMutex.Unlock()
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/obscuren/qml/testing.go b/Godeps/_workspace/src/github.com/obscuren/qml/testing.go
new file mode 100644
index 000000000..39a2a691d
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/obscuren/qml/testing.go
@@ -0,0 +1,69 @@
+package qml
+
+// #include <stdlib.h>
+// int mprotect(void *addr, size_t len, int prot);
+import "C"
+
+import (
+ "bytes"
+ "encoding/binary"
+ "gopkg.in/qml.v1/cdata"
+ "reflect"
+ "unsafe"
+)
+
+const pageSize = 4096
+
+func qmain() {
+ Run(func() error { tmain(); return nil })
+}
+
+func tmain() { tstub() }
+func tstub() { tstub() }
+
+func SetupTesting() {
+ ptr := func(f func()) uintptr { return reflect.ValueOf(f).Pointer() }
+ rmain, mmain := cdata.Addrs()
+ fset(rmain, mmain, ptr(qmain))
+ fset(ptr(tmain), ptr(tstub), mmain)
+}
+
+const (
+ protREAD = 1
+ protWRITE = 2
+ protEXEC = 4
+)
+
+func fset(target, old, new uintptr) {
+ pageOffset := target % pageSize
+ pageAddr := target - pageOffset
+
+ var mem []byte
+ memh := (*reflect.SliceHeader)(unsafe.Pointer(&mem))
+ memh.Data = pageAddr
+ memh.Len = pageSize * 2
+ memh.Cap = pageSize * 2
+
+ oldAddr := make([]byte, 8)
+ newAddr := make([]byte, 8)
+
+ binary.LittleEndian.PutUint64(oldAddr, uint64(old))
+ binary.LittleEndian.PutUint64(newAddr, uint64(new))
+
+ // BSD's syscall package misses Mprotect. Use cgo instead.
+ C.mprotect(unsafe.Pointer(pageAddr), C.size_t(len(mem)), protEXEC|protREAD|protWRITE)
+ defer C.mprotect(unsafe.Pointer(pageAddr), C.size_t(len(mem)), protEXEC|protREAD)
+
+ delta := make([]byte, 4)
+ for i, c := range mem[pageOffset:] {
+ if c == 0xe8 && int(pageOffset)+i+5 < len(mem) {
+ instrAddr := pageAddr + pageOffset + uintptr(i)
+ binary.LittleEndian.PutUint32(delta, uint32(old-instrAddr-5))
+ if bytes.Equal(mem[int(pageOffset)+i+1:int(pageOffset)+i+5], delta) {
+ binary.LittleEndian.PutUint32(mem[int(pageOffset)+i+1:], uint32(new-instrAddr-5))
+ return
+ }
+ }
+ }
+ panic("cannot setup qml package for testing")
+}
diff --git a/Godeps/_workspace/src/github.com/peterh/liner/COPYING b/Godeps/_workspace/src/github.com/peterh/liner/COPYING
new file mode 100644
index 000000000..9e8c9f206
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/peterh/liner/COPYING
@@ -0,0 +1,21 @@
+Copyright © 2012 Peter Harris
+
+Permission is hereby granted, free of charge, to any person obtaining a
+copy of this software and associated documentation files (the "Software"),
+to deal in the Software without restriction, including without limitation
+the rights to use, copy, modify, merge, publish, distribute, sublicense,
+and/or sell copies of the Software, and to permit persons to whom the
+Software is furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice (including the next
+paragraph) shall be included in all copies or substantial portions of the
+Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
+THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
+DEALINGS IN THE SOFTWARE.
+
diff --git a/Godeps/_workspace/src/github.com/peterh/liner/README.md b/Godeps/_workspace/src/github.com/peterh/liner/README.md
new file mode 100644
index 000000000..99027c6e2
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/peterh/liner/README.md
@@ -0,0 +1,95 @@
+Liner
+=====
+
+Liner is a command line editor with history. It was inspired by linenoise;
+everything Unix-like is a VT100 (or is trying very hard to be). If your
+terminal is not pretending to be a VT100, change it. Liner also support
+Windows.
+
+Liner is released under the X11 license (which is similar to the new BSD
+license).
+
+Line Editing
+------------
+
+The following line editing commands are supported on platforms and terminals
+that Liner supports:
+
+Keystroke | Action
+--------- | ------
+Ctrl-A, Home | Move cursor to beginning of line
+Ctrl-E, End | Move cursor to end of line
+Ctrl-B, Left | Move cursor one character left
+Ctrl-F, Right| Move cursor one character right
+Ctrl-Left | Move cursor to previous word
+Ctrl-Right | Move cursor to next word
+Ctrl-D, Del | (if line is *not* empty) Delete character under cursor
+Ctrl-D | (if line *is* empty) End of File - usually quits application
+Ctrl-C | Reset input (create new empty prompt)
+Ctrl-L | Clear screen (line is unmodified)
+Ctrl-T | Transpose previous character with current character
+Ctrl-H, BackSpace | Delete character before cursor
+Ctrl-W | Delete word leading up to cursor
+Ctrl-K | Delete from cursor to end of line
+Ctrl-U | Delete from start of line to cursor
+Ctrl-P, Up | Previous match from history
+Ctrl-N, Down | Next match from history
+Ctrl-R | Reverse Search history (Ctrl-S forward, Ctrl-G cancel)
+Ctrl-Y | Paste from Yank buffer (Alt-Y to paste next yank instead)
+Tab | Next completion
+Shift-Tab | (after Tab) Previous completion
+
+Getting started
+-----------------
+
+```go
+package main
+
+import (
+ "log"
+ "os"
+ "strings"
+
+ "github.com/peterh/liner"
+)
+
+var (
+ history_fn = "/tmp/.liner_history"
+ names = []string{"john", "james", "mary", "nancy"}
+)
+
+func main() {
+ line := liner.NewLiner()
+ defer line.Close()
+
+ line.SetCompleter(func(line string) (c []string) {
+ for _, n := range names {
+ if strings.HasPrefix(n, strings.ToLower(line)) {
+ c = append(c, n)
+ }
+ }
+ return
+ })
+
+ if f, err := os.Open(history_fn); err == nil {
+ line.ReadHistory(f)
+ f.Close()
+ }
+
+ if name, err := line.Prompt("What is your name? "); err != nil {
+ log.Print("Error reading line: ", err)
+ } else {
+ log.Print("Got: ", name)
+ line.AppendHistory(name)
+ }
+
+ if f, err := os.Create(history_fn); err != nil {
+ log.Print("Error writing history file: ", err)
+ } else {
+ line.WriteHistory(f)
+ f.Close()
+ }
+}
+```
+
+For documentation, see http://godoc.org/github.com/peterh/liner
diff --git a/Godeps/_workspace/src/github.com/peterh/liner/bsdinput.go b/Godeps/_workspace/src/github.com/peterh/liner/bsdinput.go
new file mode 100644
index 000000000..4b552d44d
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/peterh/liner/bsdinput.go
@@ -0,0 +1,39 @@
+// +build openbsd freebsd netbsd
+
+package liner
+
+import "syscall"
+
+const (
+ getTermios = syscall.TIOCGETA
+ setTermios = syscall.TIOCSETA
+)
+
+const (
+ // Input flags
+ inpck = 0x010
+ istrip = 0x020
+ icrnl = 0x100
+ ixon = 0x200
+
+ // Output flags
+ opost = 0x1
+
+ // Control flags
+ cs8 = 0x300
+
+ // Local flags
+ isig = 0x080
+ icanon = 0x100
+ iexten = 0x400
+)
+
+type termios struct {
+ Iflag uint32
+ Oflag uint32
+ Cflag uint32
+ Lflag uint32
+ Cc [20]byte
+ Ispeed int32
+ Ospeed int32
+}
diff --git a/Godeps/_workspace/src/github.com/peterh/liner/common.go b/Godeps/_workspace/src/github.com/peterh/liner/common.go
new file mode 100644
index 000000000..f8753a195
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/peterh/liner/common.go
@@ -0,0 +1,219 @@
+/*
+Package liner implements a simple command line editor, inspired by linenoise
+(https://github.com/antirez/linenoise/). This package supports WIN32 in
+addition to the xterm codes supported by everything else.
+*/
+package liner
+
+import (
+ "bufio"
+ "bytes"
+ "container/ring"
+ "errors"
+ "fmt"
+ "io"
+ "strings"
+ "sync"
+ "unicode/utf8"
+)
+
+type commonState struct {
+ terminalSupported bool
+ outputRedirected bool
+ inputRedirected bool
+ history []string
+ historyMutex sync.RWMutex
+ completer WordCompleter
+ columns int
+ killRing *ring.Ring
+ ctrlCAborts bool
+ r *bufio.Reader
+ tabStyle TabStyle
+}
+
+// TabStyle is used to select how tab completions are displayed.
+type TabStyle int
+
+// Two tab styles are currently available:
+//
+// TabCircular cycles through each completion item and displays it directly on
+// the prompt
+//
+// TabPrints prints the list of completion items to the screen after a second
+// tab key is pressed. This behaves similar to GNU readline and BASH (which
+// uses readline)
+const (
+ TabCircular TabStyle = iota
+ TabPrints
+)
+
+// ErrPromptAborted is returned from Prompt or PasswordPrompt when the user presses Ctrl-C
+// if SetCtrlCAborts(true) has been called on the State
+var ErrPromptAborted = errors.New("prompt aborted")
+
+// ErrNotTerminalOutput is returned from Prompt or PasswordPrompt if the
+// platform is normally supported, but stdout has been redirected
+var ErrNotTerminalOutput = errors.New("standard output is not a terminal")
+
+// Max elements to save on the killring
+const KillRingMax = 60
+
+// HistoryLimit is the maximum number of entries saved in the scrollback history.
+const HistoryLimit = 1000
+
+// ReadHistory reads scrollback history from r. Returns the number of lines
+// read, and any read error (except io.EOF).
+func (s *State) ReadHistory(r io.Reader) (num int, err error) {
+ s.historyMutex.Lock()
+ defer s.historyMutex.Unlock()
+
+ in := bufio.NewReader(r)
+ num = 0
+ for {
+ line, part, err := in.ReadLine()
+ if err == io.EOF {
+ break
+ }
+ if err != nil {
+ return num, err
+ }
+ if part {
+ return num, fmt.Errorf("line %d is too long", num+1)
+ }
+ if !utf8.Valid(line) {
+ return num, fmt.Errorf("invalid string at line %d", num+1)
+ }
+ num++
+ s.history = append(s.history, string(line))
+ if len(s.history) > HistoryLimit {
+ s.history = s.history[1:]
+ }
+ }
+ return num, nil
+}
+
+// WriteHistory writes scrollback history to w. Returns the number of lines
+// successfully written, and any write error.
+//
+// Unlike the rest of liner's API, WriteHistory is safe to call
+// from another goroutine while Prompt is in progress.
+// This exception is to facilitate the saving of the history buffer
+// during an unexpected exit (for example, due to Ctrl-C being invoked)
+func (s *State) WriteHistory(w io.Writer) (num int, err error) {
+ s.historyMutex.RLock()
+ defer s.historyMutex.RUnlock()
+
+ for _, item := range s.history {
+ _, err := fmt.Fprintln(w, item)
+ if err != nil {
+ return num, err
+ }
+ num++
+ }
+ return num, nil
+}
+
+// AppendHistory appends an entry to the scrollback history. AppendHistory
+// should be called iff Prompt returns a valid command.
+func (s *State) AppendHistory(item string) {
+ s.historyMutex.Lock()
+ defer s.historyMutex.Unlock()
+
+ if len(s.history) > 0 {
+ if item == s.history[len(s.history)-1] {
+ return
+ }
+ }
+ s.history = append(s.history, item)
+ if len(s.history) > HistoryLimit {
+ s.history = s.history[1:]
+ }
+}
+
+// Returns the history lines starting with prefix
+func (s *State) getHistoryByPrefix(prefix string) (ph []string) {
+ for _, h := range s.history {
+ if strings.HasPrefix(h, prefix) {
+ ph = append(ph, h)
+ }
+ }
+ return
+}
+
+// Returns the history lines matching the inteligent search
+func (s *State) getHistoryByPattern(pattern string) (ph []string, pos []int) {
+ if pattern == "" {
+ return
+ }
+ for _, h := range s.history {
+ if i := strings.Index(h, pattern); i >= 0 {
+ ph = append(ph, h)
+ pos = append(pos, i)
+ }
+ }
+ return
+}
+
+// Completer takes the currently edited line content at the left of the cursor
+// and returns a list of completion candidates.
+// If the line is "Hello, wo!!!" and the cursor is before the first '!', "Hello, wo" is passed
+// to the completer which may return {"Hello, world", "Hello, Word"} to have "Hello, world!!!".
+type Completer func(line string) []string
+
+// WordCompleter takes the currently edited line with the cursor position and
+// returns the completion candidates for the partial word to be completed.
+// If the line is "Hello, wo!!!" and the cursor is before the first '!', ("Hello, wo!!!", 9) is passed
+// to the completer which may returns ("Hello, ", {"world", "Word"}, "!!!") to have "Hello, world!!!".
+type WordCompleter func(line string, pos int) (head string, completions []string, tail string)
+
+// SetCompleter sets the completion function that Liner will call to
+// fetch completion candidates when the user presses tab.
+func (s *State) SetCompleter(f Completer) {
+ if f == nil {
+ s.completer = nil
+ return
+ }
+ s.completer = func(line string, pos int) (string, []string, string) {
+ return "", f(line[:pos]), line[pos:]
+ }
+}
+
+// SetWordCompleter sets the completion function that Liner will call to
+// fetch completion candidates when the user presses tab.
+func (s *State) SetWordCompleter(f WordCompleter) {
+ s.completer = f
+}
+
+// SetTabCompletionStyle sets the behvavior when the Tab key is pressed
+// for auto-completion. TabCircular is the default behavior and cycles
+// through the list of candidates at the prompt. TabPrints will print
+// the available completion candidates to the screen similar to BASH
+// and GNU Readline
+func (s *State) SetTabCompletionStyle(tabStyle TabStyle) {
+ s.tabStyle = tabStyle
+}
+
+// ModeApplier is the interface that wraps a representation of the terminal
+// mode. ApplyMode sets the terminal to this mode.
+type ModeApplier interface {
+ ApplyMode() error
+}
+
+// SetCtrlCAborts sets whether Prompt on a supported terminal will return an
+// ErrPromptAborted when Ctrl-C is pressed. The default is false (will not
+// return when Ctrl-C is pressed). Unsupported terminals typically raise SIGINT
+// (and Prompt does not return) regardless of the value passed to SetCtrlCAborts.
+func (s *State) SetCtrlCAborts(aborts bool) {
+ s.ctrlCAborts = aborts
+}
+
+func (s *State) promptUnsupported(p string) (string, error) {
+ if !s.inputRedirected {
+ fmt.Print(p)
+ }
+ linebuf, _, err := s.r.ReadLine()
+ if err != nil {
+ return "", err
+ }
+ return string(bytes.TrimSpace(linebuf)), nil
+}
diff --git a/Godeps/_workspace/src/github.com/peterh/liner/fallbackinput.go b/Godeps/_workspace/src/github.com/peterh/liner/fallbackinput.go
new file mode 100644
index 000000000..d9eb79d9e
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/peterh/liner/fallbackinput.go
@@ -0,0 +1,57 @@
+// +build !windows,!linux,!darwin,!openbsd,!freebsd,!netbsd
+
+package liner
+
+import (
+ "bufio"
+ "errors"
+ "os"
+)
+
+// State represents an open terminal
+type State struct {
+ commonState
+}
+
+// Prompt displays p, and then waits for user input. Prompt does not support
+// line editing on this operating system.
+func (s *State) Prompt(p string) (string, error) {
+ return s.promptUnsupported(p)
+}
+
+// PasswordPrompt is not supported in this OS.
+func (s *State) PasswordPrompt(p string) (string, error) {
+ return "", errors.New("liner: function not supported in this terminal")
+}
+
+// NewLiner initializes a new *State
+//
+// Note that this operating system uses a fallback mode without line
+// editing. Patches welcome.
+func NewLiner() *State {
+ var s State
+ s.r = bufio.NewReader(os.Stdin)
+ return &s
+}
+
+// Close returns the terminal to its previous mode
+func (s *State) Close() error {
+ return nil
+}
+
+// TerminalSupported returns false because line editing is not
+// supported on this platform.
+func TerminalSupported() bool {
+ return false
+}
+
+type noopMode struct{}
+
+func (n noopMode) ApplyMode() error {
+ return nil
+}
+
+// TerminalMode returns a noop InputModeSetter on this platform.
+func TerminalMode() (ModeApplier, error) {
+ return noopMode{}, nil
+}
diff --git a/Godeps/_workspace/src/github.com/peterh/liner/input.go b/Godeps/_workspace/src/github.com/peterh/liner/input.go
new file mode 100644
index 000000000..cf71d2bce
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/peterh/liner/input.go
@@ -0,0 +1,359 @@
+// +build linux darwin openbsd freebsd netbsd
+
+package liner
+
+import (
+ "bufio"
+ "errors"
+ "os"
+ "os/signal"
+ "strconv"
+ "strings"
+ "syscall"
+ "time"
+)
+
+type nexter struct {
+ r rune
+ err error
+}
+
+// State represents an open terminal
+type State struct {
+ commonState
+ origMode termios
+ defaultMode termios
+ next <-chan nexter
+ winch chan os.Signal
+ pending []rune
+ useCHA bool
+}
+
+// NewLiner initializes a new *State, and sets the terminal into raw mode. To
+// restore the terminal to its previous state, call State.Close().
+//
+// Note if you are still using Go 1.0: NewLiner handles SIGWINCH, so it will
+// leak a channel every time you call it. Therefore, it is recommened that you
+// upgrade to a newer release of Go, or ensure that NewLiner is only called
+// once.
+func NewLiner() *State {
+ var s State
+ s.r = bufio.NewReader(os.Stdin)
+
+ s.terminalSupported = TerminalSupported()
+ if m, err := TerminalMode(); err == nil {
+ s.origMode = *m.(*termios)
+ } else {
+ s.terminalSupported = false
+ s.inputRedirected = true
+ }
+ if _, err := getMode(syscall.Stdout); err != 0 {
+ s.terminalSupported = false
+ s.outputRedirected = true
+ }
+ if s.terminalSupported {
+ mode := s.origMode
+ mode.Iflag &^= icrnl | inpck | istrip | ixon
+ mode.Cflag |= cs8
+ mode.Lflag &^= syscall.ECHO | icanon | iexten
+ mode.ApplyMode()
+
+ winch := make(chan os.Signal, 1)
+ signal.Notify(winch, syscall.SIGWINCH)
+ s.winch = winch
+
+ s.checkOutput()
+ }
+
+ if !s.outputRedirected {
+ s.getColumns()
+ s.outputRedirected = s.columns <= 0
+ }
+
+ return &s
+}
+
+var errTimedOut = errors.New("timeout")
+
+func (s *State) startPrompt() {
+ if s.terminalSupported {
+ if m, err := TerminalMode(); err == nil {
+ s.defaultMode = *m.(*termios)
+ mode := s.defaultMode
+ mode.Lflag &^= isig
+ mode.ApplyMode()
+ }
+ }
+ s.restartPrompt()
+}
+
+func (s *State) restartPrompt() {
+ next := make(chan nexter)
+ go func() {
+ for {
+ var n nexter
+ n.r, _, n.err = s.r.ReadRune()
+ next <- n
+ // Shut down nexter loop when an end condition has been reached
+ if n.err != nil || n.r == '\n' || n.r == '\r' || n.r == ctrlC || n.r == ctrlD {
+ close(next)
+ return
+ }
+ }
+ }()
+ s.next = next
+}
+
+func (s *State) stopPrompt() {
+ if s.terminalSupported {
+ s.defaultMode.ApplyMode()
+ }
+}
+
+func (s *State) nextPending(timeout <-chan time.Time) (rune, error) {
+ select {
+ case thing, ok := <-s.next:
+ if !ok {
+ return 0, errors.New("liner: internal error")
+ }
+ if thing.err != nil {
+ return 0, thing.err
+ }
+ s.pending = append(s.pending, thing.r)
+ return thing.r, nil
+ case <-timeout:
+ rv := s.pending[0]
+ s.pending = s.pending[1:]
+ return rv, errTimedOut
+ }
+ // not reached
+ return 0, nil
+}
+
+func (s *State) readNext() (interface{}, error) {
+ if len(s.pending) > 0 {
+ rv := s.pending[0]
+ s.pending = s.pending[1:]
+ return rv, nil
+ }
+ var r rune
+ select {
+ case thing, ok := <-s.next:
+ if !ok {
+ return 0, errors.New("liner: internal error")
+ }
+ if thing.err != nil {
+ return nil, thing.err
+ }
+ r = thing.r
+ case <-s.winch:
+ s.getColumns()
+ return winch, nil
+ }
+ if r != esc {
+ return r, nil
+ }
+ s.pending = append(s.pending, r)
+
+ // Wait at most 50 ms for the rest of the escape sequence
+ // If nothing else arrives, it was an actual press of the esc key
+ timeout := time.After(50 * time.Millisecond)
+ flag, err := s.nextPending(timeout)
+ if err != nil {
+ if err == errTimedOut {
+ return flag, nil
+ }
+ return unknown, err
+ }
+
+ switch flag {
+ case '[':
+ code, err := s.nextPending(timeout)
+ if err != nil {
+ if err == errTimedOut {
+ return code, nil
+ }
+ return unknown, err
+ }
+ switch code {
+ case 'A':
+ s.pending = s.pending[:0] // escape code complete
+ return up, nil
+ case 'B':
+ s.pending = s.pending[:0] // escape code complete
+ return down, nil
+ case 'C':
+ s.pending = s.pending[:0] // escape code complete
+ return right, nil
+ case 'D':
+ s.pending = s.pending[:0] // escape code complete
+ return left, nil
+ case 'F':
+ s.pending = s.pending[:0] // escape code complete
+ return end, nil
+ case 'H':
+ s.pending = s.pending[:0] // escape code complete
+ return home, nil
+ case 'Z':
+ s.pending = s.pending[:0] // escape code complete
+ return shiftTab, nil
+ case '0', '1', '2', '3', '4', '5', '6', '7', '8', '9':
+ num := []rune{code}
+ for {
+ code, err := s.nextPending(timeout)
+ if err != nil {
+ if err == errTimedOut {
+ return code, nil
+ }
+ return nil, err
+ }
+ switch code {
+ case '0', '1', '2', '3', '4', '5', '6', '7', '8', '9':
+ num = append(num, code)
+ case ';':
+ // Modifier code to follow
+ // This only supports Ctrl-left and Ctrl-right for now
+ x, _ := strconv.ParseInt(string(num), 10, 32)
+ if x != 1 {
+ // Can't be left or right
+ rv := s.pending[0]
+ s.pending = s.pending[1:]
+ return rv, nil
+ }
+ num = num[:0]
+ for {
+ code, err = s.nextPending(timeout)
+ if err != nil {
+ if err == errTimedOut {
+ rv := s.pending[0]
+ s.pending = s.pending[1:]
+ return rv, nil
+ }
+ return nil, err
+ }
+ switch code {
+ case '0', '1', '2', '3', '4', '5', '6', '7', '8', '9':
+ num = append(num, code)
+ case 'C', 'D':
+ // right, left
+ mod, _ := strconv.ParseInt(string(num), 10, 32)
+ if mod != 5 {
+ // Not bare Ctrl
+ rv := s.pending[0]
+ s.pending = s.pending[1:]
+ return rv, nil
+ }
+ s.pending = s.pending[:0] // escape code complete
+ if code == 'C' {
+ return wordRight, nil
+ }
+ return wordLeft, nil
+ default:
+ // Not left or right
+ rv := s.pending[0]
+ s.pending = s.pending[1:]
+ return rv, nil
+ }
+ }
+ case '~':
+ s.pending = s.pending[:0] // escape code complete
+ x, _ := strconv.ParseInt(string(num), 10, 32)
+ switch x {
+ case 2:
+ return insert, nil
+ case 3:
+ return del, nil
+ case 5:
+ return pageUp, nil
+ case 6:
+ return pageDown, nil
+ case 7:
+ return home, nil
+ case 8:
+ return end, nil
+ case 15:
+ return f5, nil
+ case 17:
+ return f6, nil
+ case 18:
+ return f7, nil
+ case 19:
+ return f8, nil
+ case 20:
+ return f9, nil
+ case 21:
+ return f10, nil
+ case 23:
+ return f11, nil
+ case 24:
+ return f12, nil
+ default:
+ return unknown, nil
+ }
+ default:
+ // unrecognized escape code
+ rv := s.pending[0]
+ s.pending = s.pending[1:]
+ return rv, nil
+ }
+ }
+ }
+
+ case 'O':
+ code, err := s.nextPending(timeout)
+ if err != nil {
+ if err == errTimedOut {
+ return code, nil
+ }
+ return nil, err
+ }
+ s.pending = s.pending[:0] // escape code complete
+ switch code {
+ case 'c':
+ return wordRight, nil
+ case 'd':
+ return wordLeft, nil
+ case 'H':
+ return home, nil
+ case 'F':
+ return end, nil
+ case 'P':
+ return f1, nil
+ case 'Q':
+ return f2, nil
+ case 'R':
+ return f3, nil
+ case 'S':
+ return f4, nil
+ default:
+ return unknown, nil
+ }
+ case 'y':
+ s.pending = s.pending[:0] // escape code complete
+ return altY, nil
+ default:
+ rv := s.pending[0]
+ s.pending = s.pending[1:]
+ return rv, nil
+ }
+
+ // not reached
+ return r, nil
+}
+
+// Close returns the terminal to its previous mode
+func (s *State) Close() error {
+ stopSignal(s.winch)
+ if s.terminalSupported {
+ s.origMode.ApplyMode()
+ }
+ return nil
+}
+
+// TerminalSupported returns true if the current terminal supports
+// line editing features, and false if liner will use the 'dumb'
+// fallback for input.
+func TerminalSupported() bool {
+ bad := map[string]bool{"": true, "dumb": true, "cons25": true}
+ return !bad[strings.ToLower(os.Getenv("TERM"))]
+}
diff --git a/Godeps/_workspace/src/github.com/peterh/liner/input_darwin.go b/Godeps/_workspace/src/github.com/peterh/liner/input_darwin.go
new file mode 100644
index 000000000..23c9c5da0
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/peterh/liner/input_darwin.go
@@ -0,0 +1,39 @@
+// +build darwin
+
+package liner
+
+import "syscall"
+
+const (
+ getTermios = syscall.TIOCGETA
+ setTermios = syscall.TIOCSETA
+)
+
+const (
+ // Input flags
+ inpck = 0x010
+ istrip = 0x020
+ icrnl = 0x100
+ ixon = 0x200
+
+ // Output flags
+ opost = 0x1
+
+ // Control flags
+ cs8 = 0x300
+
+ // Local flags
+ isig = 0x080
+ icanon = 0x100
+ iexten = 0x400
+)
+
+type termios struct {
+ Iflag uintptr
+ Oflag uintptr
+ Cflag uintptr
+ Lflag uintptr
+ Cc [20]byte
+ Ispeed uintptr
+ Ospeed uintptr
+}
diff --git a/Godeps/_workspace/src/github.com/peterh/liner/input_linux.go b/Godeps/_workspace/src/github.com/peterh/liner/input_linux.go
new file mode 100644
index 000000000..6ca87124e
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/peterh/liner/input_linux.go
@@ -0,0 +1,26 @@
+// +build linux
+
+package liner
+
+import "syscall"
+
+const (
+ getTermios = syscall.TCGETS
+ setTermios = syscall.TCSETS
+)
+
+const (
+ icrnl = syscall.ICRNL
+ inpck = syscall.INPCK
+ istrip = syscall.ISTRIP
+ ixon = syscall.IXON
+ opost = syscall.OPOST
+ cs8 = syscall.CS8
+ isig = syscall.ISIG
+ icanon = syscall.ICANON
+ iexten = syscall.IEXTEN
+)
+
+type termios struct {
+ syscall.Termios
+}
diff --git a/Godeps/_workspace/src/github.com/peterh/liner/input_test.go b/Godeps/_workspace/src/github.com/peterh/liner/input_test.go
new file mode 100644
index 000000000..e515a4894
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/peterh/liner/input_test.go
@@ -0,0 +1,61 @@
+// +build !windows
+
+package liner
+
+import (
+ "bufio"
+ "bytes"
+ "testing"
+)
+
+func (s *State) expectRune(t *testing.T, r rune) {
+ item, err := s.readNext()
+ if err != nil {
+ t.Fatalf("Expected rune '%c', got error %s\n", r, err)
+ }
+ if v, ok := item.(rune); !ok {
+ t.Fatalf("Expected rune '%c', got non-rune %v\n", r, v)
+ } else {
+ if v != r {
+ t.Fatalf("Expected rune '%c', got rune '%c'\n", r, v)
+ }
+ }
+}
+
+func (s *State) expectAction(t *testing.T, a action) {
+ item, err := s.readNext()
+ if err != nil {
+ t.Fatalf("Expected Action %d, got error %s\n", a, err)
+ }
+ if v, ok := item.(action); !ok {
+ t.Fatalf("Expected Action %d, got non-Action %v\n", a, v)
+ } else {
+ if v != a {
+ t.Fatalf("Expected Action %d, got Action %d\n", a, v)
+ }
+ }
+}
+
+func TestTypes(t *testing.T) {
+ input := []byte{'A', 27, 'B', 27, 91, 68, 27, '[', '1', ';', '5', 'D', 'e'}
+ var s State
+ s.r = bufio.NewReader(bytes.NewBuffer(input))
+
+ next := make(chan nexter)
+ go func() {
+ for {
+ var n nexter
+ n.r, _, n.err = s.r.ReadRune()
+ next <- n
+ }
+ }()
+ s.next = next
+
+ s.expectRune(t, 'A')
+ s.expectRune(t, 27)
+ s.expectRune(t, 'B')
+ s.expectAction(t, left)
+ s.expectAction(t, wordLeft)
+
+ s.expectRune(t, 'e')
+}
diff --git a/Godeps/_workspace/src/github.com/peterh/liner/input_windows.go b/Godeps/_workspace/src/github.com/peterh/liner/input_windows.go
new file mode 100644
index 000000000..cc98719c1
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/peterh/liner/input_windows.go
@@ -0,0 +1,313 @@
+package liner
+
+import (
+ "bufio"
+ "os"
+ "syscall"
+ "unsafe"
+)
+
+var (
+ kernel32 = syscall.NewLazyDLL("kernel32.dll")
+
+ procGetStdHandle = kernel32.NewProc("GetStdHandle")
+ procReadConsoleInput = kernel32.NewProc("ReadConsoleInputW")
+ procGetConsoleMode = kernel32.NewProc("GetConsoleMode")
+ procSetConsoleMode = kernel32.NewProc("SetConsoleMode")
+ procSetConsoleCursorPosition = kernel32.NewProc("SetConsoleCursorPosition")
+ procGetConsoleScreenBufferInfo = kernel32.NewProc("GetConsoleScreenBufferInfo")
+ procFillConsoleOutputCharacter = kernel32.NewProc("FillConsoleOutputCharacterW")
+)
+
+// These names are from the Win32 api, so they use underscores (contrary to
+// what golint suggests)
+const (
+ std_input_handle = uint32(-10 & 0xFFFFFFFF)
+ std_output_handle = uint32(-11 & 0xFFFFFFFF)
+ std_error_handle = uint32(-12 & 0xFFFFFFFF)
+ invalid_handle_value = ^uintptr(0)
+)
+
+type inputMode uint32
+
+// State represents an open terminal
+type State struct {
+ commonState
+ handle syscall.Handle
+ hOut syscall.Handle
+ origMode inputMode
+ defaultMode inputMode
+ key interface{}
+ repeat uint16
+}
+
+const (
+ enableEchoInput = 0x4
+ enableInsertMode = 0x20
+ enableLineInput = 0x2
+ enableMouseInput = 0x10
+ enableProcessedInput = 0x1
+ enableQuickEditMode = 0x40
+ enableWindowInput = 0x8
+)
+
+// NewLiner initializes a new *State, and sets the terminal into raw mode. To
+// restore the terminal to its previous state, call State.Close().
+func NewLiner() *State {
+ var s State
+ hIn, _, _ := procGetStdHandle.Call(uintptr(std_input_handle))
+ s.handle = syscall.Handle(hIn)
+ hOut, _, _ := procGetStdHandle.Call(uintptr(std_output_handle))
+ s.hOut = syscall.Handle(hOut)
+
+ s.terminalSupported = true
+ if m, err := TerminalMode(); err == nil {
+ s.origMode = m.(inputMode)
+ mode := s.origMode
+ mode &^= enableEchoInput
+ mode &^= enableInsertMode
+ mode &^= enableLineInput
+ mode &^= enableMouseInput
+ mode |= enableWindowInput
+ mode.ApplyMode()
+ } else {
+ s.inputRedirected = true
+ s.r = bufio.NewReader(os.Stdin)
+ }
+
+ s.getColumns()
+ s.outputRedirected = s.columns <= 0
+
+ return &s
+}
+
+// These names are from the Win32 api, so they use underscores (contrary to
+// what golint suggests)
+const (
+ focus_event = 0x0010
+ key_event = 0x0001
+ menu_event = 0x0008
+ mouse_event = 0x0002
+ window_buffer_size_event = 0x0004
+)
+
+type input_record struct {
+ eventType uint16
+ pad uint16
+ blob [16]byte
+}
+
+type key_event_record struct {
+ KeyDown int32
+ RepeatCount uint16
+ VirtualKeyCode uint16
+ VirtualScanCode uint16
+ Char int16
+ ControlKeyState uint32
+}
+
+// These names are from the Win32 api, so they use underscores (contrary to
+// what golint suggests)
+const (
+ vk_tab = 0x09
+ vk_prior = 0x21
+ vk_next = 0x22
+ vk_end = 0x23
+ vk_home = 0x24
+ vk_left = 0x25
+ vk_up = 0x26
+ vk_right = 0x27
+ vk_down = 0x28
+ vk_insert = 0x2d
+ vk_delete = 0x2e
+ vk_f1 = 0x70
+ vk_f2 = 0x71
+ vk_f3 = 0x72
+ vk_f4 = 0x73
+ vk_f5 = 0x74
+ vk_f6 = 0x75
+ vk_f7 = 0x76
+ vk_f8 = 0x77
+ vk_f9 = 0x78
+ vk_f10 = 0x79
+ vk_f11 = 0x7a
+ vk_f12 = 0x7b
+ yKey = 0x59
+)
+
+const (
+ shiftPressed = 0x0010
+ leftAltPressed = 0x0002
+ leftCtrlPressed = 0x0008
+ rightAltPressed = 0x0001
+ rightCtrlPressed = 0x0004
+
+ modKeys = shiftPressed | leftAltPressed | rightAltPressed | leftCtrlPressed | rightCtrlPressed
+)
+
+func (s *State) readNext() (interface{}, error) {
+ if s.repeat > 0 {
+ s.repeat--
+ return s.key, nil
+ }
+
+ var input input_record
+ pbuf := uintptr(unsafe.Pointer(&input))
+ var rv uint32
+ prv := uintptr(unsafe.Pointer(&rv))
+
+ for {
+ ok, _, err := procReadConsoleInput.Call(uintptr(s.handle), pbuf, 1, prv)
+
+ if ok == 0 {
+ return nil, err
+ }
+
+ if input.eventType == window_buffer_size_event {
+ xy := (*coord)(unsafe.Pointer(&input.blob[0]))
+ s.columns = int(xy.x)
+ return winch, nil
+ }
+ if input.eventType != key_event {
+ continue
+ }
+ ke := (*key_event_record)(unsafe.Pointer(&input.blob[0]))
+ if ke.KeyDown == 0 {
+ continue
+ }
+
+ if ke.VirtualKeyCode == vk_tab && ke.ControlKeyState&modKeys == shiftPressed {
+ s.key = shiftTab
+ } else if ke.VirtualKeyCode == yKey && (ke.ControlKeyState&modKeys == leftAltPressed ||
+ ke.ControlKeyState&modKeys == rightAltPressed) {
+ s.key = altY
+ } else if ke.Char > 0 {
+ s.key = rune(ke.Char)
+ } else {
+ switch ke.VirtualKeyCode {
+ case vk_prior:
+ s.key = pageUp
+ case vk_next:
+ s.key = pageDown
+ case vk_end:
+ s.key = end
+ case vk_home:
+ s.key = home
+ case vk_left:
+ s.key = left
+ if ke.ControlKeyState&(leftCtrlPressed|rightCtrlPressed) != 0 {
+ if ke.ControlKeyState&modKeys == ke.ControlKeyState&(leftCtrlPressed|rightCtrlPressed) {
+ s.key = wordLeft
+ }
+ }
+ case vk_right:
+ s.key = right
+ if ke.ControlKeyState&(leftCtrlPressed|rightCtrlPressed) != 0 {
+ if ke.ControlKeyState&modKeys == ke.ControlKeyState&(leftCtrlPressed|rightCtrlPressed) {
+ s.key = wordRight
+ }
+ }
+ case vk_up:
+ s.key = up
+ case vk_down:
+ s.key = down
+ case vk_insert:
+ s.key = insert
+ case vk_delete:
+ s.key = del
+ case vk_f1:
+ s.key = f1
+ case vk_f2:
+ s.key = f2
+ case vk_f3:
+ s.key = f3
+ case vk_f4:
+ s.key = f4
+ case vk_f5:
+ s.key = f5
+ case vk_f6:
+ s.key = f6
+ case vk_f7:
+ s.key = f7
+ case vk_f8:
+ s.key = f8
+ case vk_f9:
+ s.key = f9
+ case vk_f10:
+ s.key = f10
+ case vk_f11:
+ s.key = f11
+ case vk_f12:
+ s.key = f12
+ default:
+ // Eat modifier keys
+ // TODO: return Action(Unknown) if the key isn't a
+ // modifier.
+ continue
+ }
+ }
+
+ if ke.RepeatCount > 1 {
+ s.repeat = ke.RepeatCount - 1
+ }
+ return s.key, nil
+ }
+ return unknown, nil
+}
+
+// Close returns the terminal to its previous mode
+func (s *State) Close() error {
+ s.origMode.ApplyMode()
+ return nil
+}
+
+func (s *State) startPrompt() {
+ if m, err := TerminalMode(); err == nil {
+ s.defaultMode = m.(inputMode)
+ mode := s.defaultMode
+ mode &^= enableProcessedInput
+ mode.ApplyMode()
+ }
+}
+
+func (s *State) restartPrompt() {
+}
+
+func (s *State) stopPrompt() {
+ s.defaultMode.ApplyMode()
+}
+
+// TerminalSupported returns true because line editing is always
+// supported on Windows.
+func TerminalSupported() bool {
+ return true
+}
+
+func (mode inputMode) ApplyMode() error {
+ hIn, _, err := procGetStdHandle.Call(uintptr(std_input_handle))
+ if hIn == invalid_handle_value || hIn == 0 {
+ return err
+ }
+ ok, _, err := procSetConsoleMode.Call(hIn, uintptr(mode))
+ if ok != 0 {
+ err = nil
+ }
+ return err
+}
+
+// TerminalMode returns the current terminal input mode as an InputModeSetter.
+//
+// This function is provided for convenience, and should
+// not be necessary for most users of liner.
+func TerminalMode() (ModeApplier, error) {
+ var mode inputMode
+ hIn, _, err := procGetStdHandle.Call(uintptr(std_input_handle))
+ if hIn == invalid_handle_value || hIn == 0 {
+ return nil, err
+ }
+ ok, _, err := procGetConsoleMode.Call(hIn, uintptr(unsafe.Pointer(&mode)))
+ if ok != 0 {
+ err = nil
+ }
+ return mode, err
+}
diff --git a/Godeps/_workspace/src/github.com/peterh/liner/line.go b/Godeps/_workspace/src/github.com/peterh/liner/line.go
new file mode 100644
index 000000000..a70fb59e5
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/peterh/liner/line.go
@@ -0,0 +1,864 @@
+// +build windows linux darwin openbsd freebsd netbsd
+
+package liner
+
+import (
+ "container/ring"
+ "errors"
+ "fmt"
+ "io"
+ "strings"
+ "unicode"
+ "unicode/utf8"
+)
+
+type action int
+
+const (
+ left action = iota
+ right
+ up
+ down
+ home
+ end
+ insert
+ del
+ pageUp
+ pageDown
+ f1
+ f2
+ f3
+ f4
+ f5
+ f6
+ f7
+ f8
+ f9
+ f10
+ f11
+ f12
+ altY
+ shiftTab
+ wordLeft
+ wordRight
+ winch
+ unknown
+)
+
+const (
+ ctrlA = 1
+ ctrlB = 2
+ ctrlC = 3
+ ctrlD = 4
+ ctrlE = 5
+ ctrlF = 6
+ ctrlG = 7
+ ctrlH = 8
+ tab = 9
+ lf = 10
+ ctrlK = 11
+ ctrlL = 12
+ cr = 13
+ ctrlN = 14
+ ctrlO = 15
+ ctrlP = 16
+ ctrlQ = 17
+ ctrlR = 18
+ ctrlS = 19
+ ctrlT = 20
+ ctrlU = 21
+ ctrlV = 22
+ ctrlW = 23
+ ctrlX = 24
+ ctrlY = 25
+ ctrlZ = 26
+ esc = 27
+ bs = 127
+)
+
+const (
+ beep = "\a"
+)
+
+type tabDirection int
+
+const (
+ tabForward tabDirection = iota
+ tabReverse
+)
+
+func (s *State) refresh(prompt []rune, buf []rune, pos int) error {
+ s.cursorPos(0)
+ _, err := fmt.Print(string(prompt))
+ if err != nil {
+ return err
+ }
+
+ pLen := countGlyphs(prompt)
+ bLen := countGlyphs(buf)
+ pos = countGlyphs(buf[:pos])
+ if pLen+bLen < s.columns {
+ _, err = fmt.Print(string(buf))
+ s.eraseLine()
+ s.cursorPos(pLen + pos)
+ } else {
+ // Find space available
+ space := s.columns - pLen
+ space-- // space for cursor
+ start := pos - space/2
+ end := start + space
+ if end > bLen {
+ end = bLen
+ start = end - space
+ }
+ if start < 0 {
+ start = 0
+ end = space
+ }
+ pos -= start
+
+ // Leave space for markers
+ if start > 0 {
+ start++
+ }
+ if end < bLen {
+ end--
+ }
+ startRune := len(getPrefixGlyphs(buf, start))
+ line := getPrefixGlyphs(buf[startRune:], end-start)
+
+ // Output
+ if start > 0 {
+ fmt.Print("{")
+ }
+ fmt.Print(string(line))
+ if end < bLen {
+ fmt.Print("}")
+ }
+
+ // Set cursor position
+ s.eraseLine()
+ s.cursorPos(pLen + pos)
+ }
+ return err
+}
+
+func longestCommonPrefix(strs []string) string {
+ if len(strs) == 0 {
+ return ""
+ }
+ longest := strs[0]
+
+ for _, str := range strs[1:] {
+ for !strings.HasPrefix(str, longest) {
+ longest = longest[:len(longest)-1]
+ }
+ }
+ // Remove trailing partial runes
+ longest = strings.TrimRight(longest, "\uFFFD")
+ return longest
+}
+
+func (s *State) circularTabs(items []string) func(tabDirection) (string, error) {
+ item := -1
+ return func(direction tabDirection) (string, error) {
+ if direction == tabForward {
+ if item < len(items)-1 {
+ item++
+ } else {
+ item = 0
+ }
+ } else if direction == tabReverse {
+ if item > 0 {
+ item--
+ } else {
+ item = len(items) - 1
+ }
+ }
+ return items[item], nil
+ }
+}
+
+func (s *State) printedTabs(items []string) func(tabDirection) (string, error) {
+ numTabs := 1
+ prefix := longestCommonPrefix(items)
+ return func(direction tabDirection) (string, error) {
+ if len(items) == 1 {
+ return items[0], nil
+ }
+
+ if numTabs == 2 {
+ if len(items) > 100 {
+ fmt.Printf("\nDisplay all %d possibilities? (y or n) ", len(items))
+ for {
+ next, err := s.readNext()
+ if err != nil {
+ return prefix, err
+ }
+
+ if key, ok := next.(rune); ok {
+ if unicode.ToLower(key) == 'n' {
+ return prefix, nil
+ } else if unicode.ToLower(key) == 'y' {
+ break
+ }
+ }
+ }
+ }
+ fmt.Println("")
+ maxWidth := 0
+ for _, item := range items {
+ if len(item) >= maxWidth {
+ maxWidth = len(item) + 1
+ }
+ }
+
+ numColumns := s.columns / maxWidth
+ numRows := len(items) / numColumns
+ if len(items)%numColumns > 0 {
+ numRows++
+ }
+
+ if len(items) <= numColumns {
+ maxWidth = 0
+ }
+ for i := 0; i < numRows; i++ {
+ for j := 0; j < numColumns*numRows; j += numRows {
+ if i+j < len(items) {
+ if maxWidth > 0 {
+ fmt.Printf("%-*s", maxWidth, items[i+j])
+ } else {
+ fmt.Printf("%v ", items[i+j])
+ }
+ }
+ }
+ fmt.Println("")
+ }
+ } else {
+ numTabs++
+ }
+ return prefix, nil
+ }
+}
+
+func (s *State) tabComplete(p []rune, line []rune, pos int) ([]rune, int, interface{}, error) {
+ if s.completer == nil {
+ return line, pos, rune(esc), nil
+ }
+ head, list, tail := s.completer(string(line), pos)
+ if len(list) <= 0 {
+ return line, pos, rune(esc), nil
+ }
+ hl := utf8.RuneCountInString(head)
+ if len(list) == 1 {
+ s.refresh(p, []rune(head+list[0]+tail), hl+utf8.RuneCountInString(list[0]))
+ return []rune(head + list[0] + tail), hl + utf8.RuneCountInString(list[0]), rune(esc), nil
+ }
+
+ direction := tabForward
+ tabPrinter := s.circularTabs(list)
+ if s.tabStyle == TabPrints {
+ tabPrinter = s.printedTabs(list)
+ }
+
+ for {
+ pick, err := tabPrinter(direction)
+ if err != nil {
+ return line, pos, rune(esc), err
+ }
+ s.refresh(p, []rune(head+pick+tail), hl+utf8.RuneCountInString(pick))
+
+ next, err := s.readNext()
+ if err != nil {
+ return line, pos, rune(esc), err
+ }
+ if key, ok := next.(rune); ok {
+ if key == tab {
+ direction = tabForward
+ continue
+ }
+ if key == esc {
+ return line, pos, rune(esc), nil
+ }
+ }
+ if a, ok := next.(action); ok && a == shiftTab {
+ direction = tabReverse
+ continue
+ }
+ return []rune(head + pick + tail), hl + utf8.RuneCountInString(pick), next, nil
+ }
+ // Not reached
+ return line, pos, rune(esc), nil
+}
+
+// reverse intelligent search, implements a bash-like history search.
+func (s *State) reverseISearch(origLine []rune, origPos int) ([]rune, int, interface{}, error) {
+ p := "(reverse-i-search)`': "
+ s.refresh([]rune(p), origLine, origPos)
+
+ line := []rune{}
+ pos := 0
+ foundLine := string(origLine)
+ foundPos := origPos
+
+ getLine := func() ([]rune, []rune, int) {
+ search := string(line)
+ prompt := "(reverse-i-search)`%s': "
+ return []rune(fmt.Sprintf(prompt, search)), []rune(foundLine), foundPos
+ }
+
+ history, positions := s.getHistoryByPattern(string(line))
+ historyPos := len(history) - 1
+
+ for {
+ next, err := s.readNext()
+ if err != nil {
+ return []rune(foundLine), foundPos, rune(esc), err
+ }
+
+ switch v := next.(type) {
+ case rune:
+ switch v {
+ case ctrlR: // Search backwards
+ if historyPos > 0 && historyPos < len(history) {
+ historyPos--
+ foundLine = history[historyPos]
+ foundPos = positions[historyPos]
+ } else {
+ fmt.Print(beep)
+ }
+ case ctrlS: // Search forward
+ if historyPos < len(history)-1 && historyPos >= 0 {
+ historyPos++
+ foundLine = history[historyPos]
+ foundPos = positions[historyPos]
+ } else {
+ fmt.Print(beep)
+ }
+ case ctrlH, bs: // Backspace
+ if pos <= 0 {
+ fmt.Print(beep)
+ } else {
+ n := len(getSuffixGlyphs(line[:pos], 1))
+ line = append(line[:pos-n], line[pos:]...)
+ pos -= n
+
+ // For each char deleted, display the last matching line of history
+ history, positions := s.getHistoryByPattern(string(line))
+ historyPos = len(history) - 1
+ if len(history) > 0 {
+ foundLine = history[historyPos]
+ foundPos = positions[historyPos]
+ } else {
+ foundLine = ""
+ foundPos = 0
+ }
+ }
+ case ctrlG: // Cancel
+ return origLine, origPos, rune(esc), err
+
+ case tab, cr, lf, ctrlA, ctrlB, ctrlD, ctrlE, ctrlF, ctrlK,
+ ctrlL, ctrlN, ctrlO, ctrlP, ctrlQ, ctrlT, ctrlU, ctrlV, ctrlW, ctrlX, ctrlY, ctrlZ:
+ fallthrough
+ case 0, ctrlC, esc, 28, 29, 30, 31:
+ return []rune(foundLine), foundPos, next, err
+ default:
+ line = append(line[:pos], append([]rune{v}, line[pos:]...)...)
+ pos++
+
+ // For each keystroke typed, display the last matching line of history
+ history, positions = s.getHistoryByPattern(string(line))
+ historyPos = len(history) - 1
+ if len(history) > 0 {
+ foundLine = history[historyPos]
+ foundPos = positions[historyPos]
+ } else {
+ foundLine = ""
+ foundPos = 0
+ }
+ }
+ case action:
+ return []rune(foundLine), foundPos, next, err
+ }
+ s.refresh(getLine())
+ }
+}
+
+// addToKillRing adds some text to the kill ring. If mode is 0 it adds it to a
+// new node in the end of the kill ring, and move the current pointer to the new
+// node. If mode is 1 or 2 it appends or prepends the text to the current entry
+// of the killRing.
+func (s *State) addToKillRing(text []rune, mode int) {
+ // Don't use the same underlying array as text
+ killLine := make([]rune, len(text))
+ copy(killLine, text)
+
+ // Point killRing to a newNode, procedure depends on the killring state and
+ // append mode.
+ if mode == 0 { // Add new node to killRing
+ if s.killRing == nil { // if killring is empty, create a new one
+ s.killRing = ring.New(1)
+ } else if s.killRing.Len() >= KillRingMax { // if killring is "full"
+ s.killRing = s.killRing.Next()
+ } else { // Normal case
+ s.killRing.Link(ring.New(1))
+ s.killRing = s.killRing.Next()
+ }
+ } else {
+ if s.killRing == nil { // if killring is empty, create a new one
+ s.killRing = ring.New(1)
+ s.killRing.Value = []rune{}
+ }
+ if mode == 1 { // Append to last entry
+ killLine = append(s.killRing.Value.([]rune), killLine...)
+ } else if mode == 2 { // Prepend to last entry
+ killLine = append(killLine, s.killRing.Value.([]rune)...)
+ }
+ }
+
+ // Save text in the current killring node
+ s.killRing.Value = killLine
+}
+
+func (s *State) yank(p []rune, text []rune, pos int) ([]rune, int, interface{}, error) {
+ if s.killRing == nil {
+ return text, pos, rune(esc), nil
+ }
+
+ lineStart := text[:pos]
+ lineEnd := text[pos:]
+ var line []rune
+
+ for {
+ value := s.killRing.Value.([]rune)
+ line = make([]rune, 0)
+ line = append(line, lineStart...)
+ line = append(line, value...)
+ line = append(line, lineEnd...)
+
+ pos = len(lineStart) + len(value)
+ s.refresh(p, line, pos)
+
+ next, err := s.readNext()
+ if err != nil {
+ return line, pos, next, err
+ }
+
+ switch v := next.(type) {
+ case rune:
+ return line, pos, next, nil
+ case action:
+ switch v {
+ case altY:
+ s.killRing = s.killRing.Prev()
+ default:
+ return line, pos, next, nil
+ }
+ }
+ }
+
+ return line, pos, esc, nil
+}
+
+// Prompt displays p, and then waits for user input. Prompt allows line editing
+// if the terminal supports it.
+func (s *State) Prompt(prompt string) (string, error) {
+ if s.inputRedirected {
+ return s.promptUnsupported(prompt)
+ }
+ if s.outputRedirected {
+ return "", ErrNotTerminalOutput
+ }
+ if !s.terminalSupported {
+ return s.promptUnsupported(prompt)
+ }
+
+ s.historyMutex.RLock()
+ defer s.historyMutex.RUnlock()
+
+ s.startPrompt()
+ defer s.stopPrompt()
+ s.getColumns()
+
+ fmt.Print(prompt)
+ p := []rune(prompt)
+ var line []rune
+ pos := 0
+ historyEnd := ""
+ prefixHistory := s.getHistoryByPrefix(string(line))
+ historyPos := len(prefixHistory)
+ historyAction := false // used to mark history related actions
+ killAction := 0 // used to mark kill related actions
+mainLoop:
+ for {
+ next, err := s.readNext()
+ haveNext:
+ if err != nil {
+ return "", err
+ }
+
+ historyAction = false
+ switch v := next.(type) {
+ case rune:
+ switch v {
+ case cr, lf:
+ fmt.Println()
+ break mainLoop
+ case ctrlA: // Start of line
+ pos = 0
+ s.refresh(p, line, pos)
+ case ctrlE: // End of line
+ pos = len(line)
+ s.refresh(p, line, pos)
+ case ctrlB: // left
+ if pos > 0 {
+ pos -= len(getSuffixGlyphs(line[:pos], 1))
+ s.refresh(p, line, pos)
+ } else {
+ fmt.Print(beep)
+ }
+ case ctrlF: // right
+ if pos < len(line) {
+ pos += len(getPrefixGlyphs(line[pos:], 1))
+ s.refresh(p, line, pos)
+ } else {
+ fmt.Print(beep)
+ }
+ case ctrlD: // del
+ if pos == 0 && len(line) == 0 {
+ // exit
+ return "", io.EOF
+ }
+
+ // ctrlD is a potential EOF, so the rune reader shuts down.
+ // Therefore, if it isn't actually an EOF, we must re-startPrompt.
+ s.restartPrompt()
+
+ if pos >= len(line) {
+ fmt.Print(beep)
+ } else {
+ n := len(getPrefixGlyphs(line[pos:], 1))
+ line = append(line[:pos], line[pos+n:]...)
+ s.refresh(p, line, pos)
+ }
+ case ctrlK: // delete remainder of line
+ if pos >= len(line) {
+ fmt.Print(beep)
+ } else {
+ if killAction > 0 {
+ s.addToKillRing(line[pos:], 1) // Add in apend mode
+ } else {
+ s.addToKillRing(line[pos:], 0) // Add in normal mode
+ }
+
+ killAction = 2 // Mark that there was a kill action
+ line = line[:pos]
+ s.refresh(p, line, pos)
+ }
+ case ctrlP: // up
+ historyAction = true
+ if historyPos > 0 {
+ if historyPos == len(prefixHistory) {
+ historyEnd = string(line)
+ }
+ historyPos--
+ line = []rune(prefixHistory[historyPos])
+ pos = len(line)
+ s.refresh(p, line, pos)
+ } else {
+ fmt.Print(beep)
+ }
+ case ctrlN: // down
+ historyAction = true
+ if historyPos < len(prefixHistory) {
+ historyPos++
+ if historyPos == len(prefixHistory) {
+ line = []rune(historyEnd)
+ } else {
+ line = []rune(prefixHistory[historyPos])
+ }
+ pos = len(line)
+ s.refresh(p, line, pos)
+ } else {
+ fmt.Print(beep)
+ }
+ case ctrlT: // transpose prev glyph with glyph under cursor
+ if len(line) < 2 || pos < 1 {
+ fmt.Print(beep)
+ } else {
+ if pos == len(line) {
+ pos -= len(getSuffixGlyphs(line, 1))
+ }
+ prev := getSuffixGlyphs(line[:pos], 1)
+ next := getPrefixGlyphs(line[pos:], 1)
+ scratch := make([]rune, len(prev))
+ copy(scratch, prev)
+ copy(line[pos-len(prev):], next)
+ copy(line[pos-len(prev)+len(next):], scratch)
+ pos += len(next)
+ s.refresh(p, line, pos)
+ }
+ case ctrlL: // clear screen
+ s.eraseScreen()
+ s.refresh(p, line, pos)
+ case ctrlC: // reset
+ fmt.Println("^C")
+ if s.ctrlCAborts {
+ return "", ErrPromptAborted
+ }
+ line = line[:0]
+ pos = 0
+ fmt.Print(prompt)
+ s.restartPrompt()
+ case ctrlH, bs: // Backspace
+ if pos <= 0 {
+ fmt.Print(beep)
+ } else {
+ n := len(getSuffixGlyphs(line[:pos], 1))
+ line = append(line[:pos-n], line[pos:]...)
+ pos -= n
+ s.refresh(p, line, pos)
+ }
+ case ctrlU: // Erase line before cursor
+ if killAction > 0 {
+ s.addToKillRing(line[:pos], 2) // Add in prepend mode
+ } else {
+ s.addToKillRing(line[:pos], 0) // Add in normal mode
+ }
+
+ killAction = 2 // Mark that there was some killing
+ line = line[pos:]
+ pos = 0
+ s.refresh(p, line, pos)
+ case ctrlW: // Erase word
+ if pos == 0 {
+ fmt.Print(beep)
+ break
+ }
+ // Remove whitespace to the left
+ var buf []rune // Store the deleted chars in a buffer
+ for {
+ if pos == 0 || !unicode.IsSpace(line[pos-1]) {
+ break
+ }
+ buf = append(buf, line[pos-1])
+ line = append(line[:pos-1], line[pos:]...)
+ pos--
+ }
+ // Remove non-whitespace to the left
+ for {
+ if pos == 0 || unicode.IsSpace(line[pos-1]) {
+ break
+ }
+ buf = append(buf, line[pos-1])
+ line = append(line[:pos-1], line[pos:]...)
+ pos--
+ }
+ // Invert the buffer and save the result on the killRing
+ var newBuf []rune
+ for i := len(buf) - 1; i >= 0; i-- {
+ newBuf = append(newBuf, buf[i])
+ }
+ if killAction > 0 {
+ s.addToKillRing(newBuf, 2) // Add in prepend mode
+ } else {
+ s.addToKillRing(newBuf, 0) // Add in normal mode
+ }
+ killAction = 2 // Mark that there was some killing
+
+ s.refresh(p, line, pos)
+ case ctrlY: // Paste from Yank buffer
+ line, pos, next, err = s.yank(p, line, pos)
+ goto haveNext
+ case ctrlR: // Reverse Search
+ line, pos, next, err = s.reverseISearch(line, pos)
+ s.refresh(p, line, pos)
+ goto haveNext
+ case tab: // Tab completion
+ line, pos, next, err = s.tabComplete(p, line, pos)
+ goto haveNext
+ // Catch keys that do nothing, but you don't want them to beep
+ case esc:
+ // DO NOTHING
+ // Unused keys
+ case ctrlG, ctrlO, ctrlQ, ctrlS, ctrlV, ctrlX, ctrlZ:
+ fallthrough
+ // Catch unhandled control codes (anything <= 31)
+ case 0, 28, 29, 30, 31:
+ fmt.Print(beep)
+ default:
+ if pos == len(line) && len(p)+len(line) < s.columns-1 {
+ line = append(line, v)
+ fmt.Printf("%c", v)
+ pos++
+ } else {
+ line = append(line[:pos], append([]rune{v}, line[pos:]...)...)
+ pos++
+ s.refresh(p, line, pos)
+ }
+ }
+ case action:
+ switch v {
+ case del:
+ if pos >= len(line) {
+ fmt.Print(beep)
+ } else {
+ n := len(getPrefixGlyphs(line[pos:], 1))
+ line = append(line[:pos], line[pos+n:]...)
+ }
+ case left:
+ if pos > 0 {
+ pos -= len(getSuffixGlyphs(line[:pos], 1))
+ } else {
+ fmt.Print(beep)
+ }
+ case wordLeft:
+ if pos > 0 {
+ for {
+ pos--
+ if pos == 0 || unicode.IsSpace(line[pos-1]) {
+ break
+ }
+ }
+ } else {
+ fmt.Print(beep)
+ }
+ case right:
+ if pos < len(line) {
+ pos += len(getPrefixGlyphs(line[pos:], 1))
+ } else {
+ fmt.Print(beep)
+ }
+ case wordRight:
+ if pos < len(line) {
+ for {
+ pos++
+ if pos == len(line) || unicode.IsSpace(line[pos]) {
+ break
+ }
+ }
+ } else {
+ fmt.Print(beep)
+ }
+ case up:
+ historyAction = true
+ if historyPos > 0 {
+ if historyPos == len(prefixHistory) {
+ historyEnd = string(line)
+ }
+ historyPos--
+ line = []rune(prefixHistory[historyPos])
+ pos = len(line)
+ } else {
+ fmt.Print(beep)
+ }
+ case down:
+ historyAction = true
+ if historyPos < len(prefixHistory) {
+ historyPos++
+ if historyPos == len(prefixHistory) {
+ line = []rune(historyEnd)
+ } else {
+ line = []rune(prefixHistory[historyPos])
+ }
+ pos = len(line)
+ } else {
+ fmt.Print(beep)
+ }
+ case home: // Start of line
+ pos = 0
+ case end: // End of line
+ pos = len(line)
+ }
+ s.refresh(p, line, pos)
+ }
+ if !historyAction {
+ prefixHistory = s.getHistoryByPrefix(string(line))
+ historyPos = len(prefixHistory)
+ }
+ if killAction > 0 {
+ killAction--
+ }
+ }
+ return string(line), nil
+}
+
+// PasswordPrompt displays p, and then waits for user input. The input typed by
+// the user is not displayed in the terminal.
+func (s *State) PasswordPrompt(prompt string) (string, error) {
+ if s.inputRedirected {
+ return s.promptUnsupported(prompt)
+ }
+ if s.outputRedirected {
+ return "", ErrNotTerminalOutput
+ }
+ if !s.terminalSupported {
+ return "", errors.New("liner: function not supported in this terminal")
+ }
+
+ s.startPrompt()
+ defer s.stopPrompt()
+ s.getColumns()
+
+ fmt.Print(prompt)
+ p := []rune(prompt)
+ var line []rune
+ pos := 0
+
+mainLoop:
+ for {
+ next, err := s.readNext()
+ if err != nil {
+ return "", err
+ }
+
+ switch v := next.(type) {
+ case rune:
+ switch v {
+ case cr, lf:
+ fmt.Println()
+ break mainLoop
+ case ctrlD: // del
+ if pos == 0 && len(line) == 0 {
+ // exit
+ return "", io.EOF
+ }
+
+ // ctrlD is a potential EOF, so the rune reader shuts down.
+ // Therefore, if it isn't actually an EOF, we must re-startPrompt.
+ s.restartPrompt()
+ case ctrlL: // clear screen
+ s.eraseScreen()
+ s.refresh(p, []rune{}, 0)
+ case ctrlH, bs: // Backspace
+ if pos <= 0 {
+ fmt.Print(beep)
+ } else {
+ n := len(getSuffixGlyphs(line[:pos], 1))
+ line = append(line[:pos-n], line[pos:]...)
+ pos -= n
+ }
+ case ctrlC:
+ fmt.Println("^C")
+ if s.ctrlCAborts {
+ return "", ErrPromptAborted
+ }
+ line = line[:0]
+ pos = 0
+ fmt.Print(prompt)
+ s.restartPrompt()
+ // Unused keys
+ case esc, tab, ctrlA, ctrlB, ctrlE, ctrlF, ctrlG, ctrlK, ctrlN, ctrlO, ctrlP, ctrlQ, ctrlR, ctrlS,
+ ctrlT, ctrlU, ctrlV, ctrlW, ctrlX, ctrlY, ctrlZ:
+ fallthrough
+ // Catch unhandled control codes (anything <= 31)
+ case 0, 28, 29, 30, 31:
+ fmt.Print(beep)
+ default:
+ line = append(line[:pos], append([]rune{v}, line[pos:]...)...)
+ pos++
+ }
+ }
+ }
+ return string(line), nil
+}
diff --git a/Godeps/_workspace/src/github.com/peterh/liner/line_test.go b/Godeps/_workspace/src/github.com/peterh/liner/line_test.go
new file mode 100644
index 000000000..727da6ce7
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/peterh/liner/line_test.go
@@ -0,0 +1,90 @@
+package liner
+
+import (
+ "bytes"
+ "strings"
+ "testing"
+)
+
+func TestAppend(t *testing.T) {
+ var s State
+ s.AppendHistory("foo")
+ s.AppendHistory("bar")
+
+ var out bytes.Buffer
+ num, err := s.WriteHistory(&out)
+ if err != nil {
+ t.Fatal("Unexpected error writing history", err)
+ }
+ if num != 2 {
+ t.Fatalf("Expected 2 history entries, got %d", num)
+ }
+
+ s.AppendHistory("baz")
+ num, err = s.WriteHistory(&out)
+ if err != nil {
+ t.Fatal("Unexpected error writing history", err)
+ }
+ if num != 3 {
+ t.Fatalf("Expected 3 history entries, got %d", num)
+ }
+
+ s.AppendHistory("baz")
+ num, err = s.WriteHistory(&out)
+ if err != nil {
+ t.Fatal("Unexpected error writing history", err)
+ }
+ if num != 3 {
+ t.Fatalf("Expected 3 history entries after duplicate append, got %d", num)
+ }
+
+ s.AppendHistory("baz")
+
+}
+
+func TestHistory(t *testing.T) {
+ input := `foo
+bar
+baz
+quux
+dingle`
+
+ var s State
+ num, err := s.ReadHistory(strings.NewReader(input))
+ if err != nil {
+ t.Fatal("Unexpected error reading history", err)
+ }
+ if num != 5 {
+ t.Fatal("Wrong number of history entries read")
+ }
+
+ var out bytes.Buffer
+ num, err = s.WriteHistory(&out)
+ if err != nil {
+ t.Fatal("Unexpected error writing history", err)
+ }
+ if num != 5 {
+ t.Fatal("Wrong number of history entries written")
+ }
+ if strings.TrimSpace(out.String()) != input {
+ t.Fatal("Round-trip failure")
+ }
+
+ // Test reading with a trailing newline present
+ var s2 State
+ num, err = s2.ReadHistory(&out)
+ if err != nil {
+ t.Fatal("Unexpected error reading history the 2nd time", err)
+ }
+ if num != 5 {
+ t.Fatal("Wrong number of history entries read the 2nd time")
+ }
+
+ num, err = s.ReadHistory(strings.NewReader(input + "\n\xff"))
+ if err == nil {
+ t.Fatal("Unexpected success reading corrupted history", err)
+ }
+ if num != 5 {
+ t.Fatal("Wrong number of history entries read the 3rd time")
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/peterh/liner/output.go b/Godeps/_workspace/src/github.com/peterh/liner/output.go
new file mode 100644
index 000000000..e91f4ea81
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/peterh/liner/output.go
@@ -0,0 +1,63 @@
+// +build linux darwin openbsd freebsd netbsd
+
+package liner
+
+import (
+ "fmt"
+ "os"
+ "strings"
+ "syscall"
+ "unsafe"
+)
+
+func (s *State) cursorPos(x int) {
+ if s.useCHA {
+ // 'G' is "Cursor Character Absolute (CHA)"
+ fmt.Printf("\x1b[%dG", x+1)
+ } else {
+ // 'C' is "Cursor Forward (CUF)"
+ fmt.Print("\r")
+ if x > 0 {
+ fmt.Printf("\x1b[%dC", x)
+ }
+ }
+}
+
+func (s *State) eraseLine() {
+ fmt.Print("\x1b[0K")
+}
+
+func (s *State) eraseScreen() {
+ fmt.Print("\x1b[H\x1b[2J")
+}
+
+type winSize struct {
+ row, col uint16
+ xpixel, ypixel uint16
+}
+
+func (s *State) getColumns() {
+ var ws winSize
+ ok, _, _ := syscall.Syscall(syscall.SYS_IOCTL, uintptr(syscall.Stdout),
+ syscall.TIOCGWINSZ, uintptr(unsafe.Pointer(&ws)))
+ if ok < 0 {
+ s.columns = 80
+ }
+ s.columns = int(ws.col)
+}
+
+func (s *State) checkOutput() {
+ // xterm is known to support CHA
+ if strings.Contains(strings.ToLower(os.Getenv("TERM")), "xterm") {
+ s.useCHA = true
+ return
+ }
+
+ // The test for functional ANSI CHA is unreliable (eg the Windows
+ // telnet command does not support reading the cursor position with
+ // an ANSI DSR request, despite setting TERM=ansi)
+
+ // Assume CHA isn't supported (which should be safe, although it
+ // does result in occasional visible cursor jitter)
+ s.useCHA = false
+}
diff --git a/Godeps/_workspace/src/github.com/peterh/liner/output_windows.go b/Godeps/_workspace/src/github.com/peterh/liner/output_windows.go
new file mode 100644
index 000000000..27ae55a14
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/peterh/liner/output_windows.go
@@ -0,0 +1,54 @@
+package liner
+
+import (
+ "unsafe"
+)
+
+type coord struct {
+ x, y int16
+}
+type smallRect struct {
+ left, top, right, bottom int16
+}
+
+type consoleScreenBufferInfo struct {
+ dwSize coord
+ dwCursorPosition coord
+ wAttributes int16
+ srWindow smallRect
+ dwMaximumWindowSize coord
+}
+
+func (s *State) cursorPos(x int) {
+ var sbi consoleScreenBufferInfo
+ procGetConsoleScreenBufferInfo.Call(uintptr(s.hOut), uintptr(unsafe.Pointer(&sbi)))
+ procSetConsoleCursorPosition.Call(uintptr(s.hOut),
+ uintptr(int(x)&0xFFFF|int(sbi.dwCursorPosition.y)<<16))
+}
+
+func (s *State) eraseLine() {
+ var sbi consoleScreenBufferInfo
+ procGetConsoleScreenBufferInfo.Call(uintptr(s.hOut), uintptr(unsafe.Pointer(&sbi)))
+ var numWritten uint32
+ procFillConsoleOutputCharacter.Call(uintptr(s.hOut), uintptr(' '),
+ uintptr(sbi.dwSize.x-sbi.dwCursorPosition.x),
+ uintptr(int(sbi.dwCursorPosition.x)&0xFFFF|int(sbi.dwCursorPosition.y)<<16),
+ uintptr(unsafe.Pointer(&numWritten)))
+}
+
+func (s *State) eraseScreen() {
+ var sbi consoleScreenBufferInfo
+ procGetConsoleScreenBufferInfo.Call(uintptr(s.hOut), uintptr(unsafe.Pointer(&sbi)))
+ var numWritten uint32
+ procFillConsoleOutputCharacter.Call(uintptr(s.hOut), uintptr(' '),
+ uintptr(sbi.dwSize.x)*uintptr(sbi.dwSize.y),
+ 0,
+ uintptr(unsafe.Pointer(&numWritten)))
+ procSetConsoleCursorPosition.Call(uintptr(s.hOut), 0)
+}
+
+func (s *State) getColumns() {
+ var sbi consoleScreenBufferInfo
+ procGetConsoleScreenBufferInfo.Call(uintptr(s.hOut), uintptr(unsafe.Pointer(&sbi)))
+ s.columns = int(sbi.dwSize.x)
+}
diff --git a/Godeps/_workspace/src/github.com/peterh/liner/prefix_test.go b/Godeps/_workspace/src/github.com/peterh/liner/prefix_test.go
new file mode 100644
index 000000000..c826d6c3b
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/peterh/liner/prefix_test.go
@@ -0,0 +1,37 @@
+// +build windows linux darwin openbsd freebsd netbsd
+
+package liner
+
+import "testing"
+
+type testItem struct {
+ list []string
+ prefix string
+}
+
+func TestPrefix(t *testing.T) {
+ list := []testItem{
+ {[]string{"food", "foot"}, "foo"},
+ {[]string{"foo", "foot"}, "foo"},
+ {[]string{"food", "foo"}, "foo"},
+ {[]string{"food", "foe", "foot"}, "fo"},
+ {[]string{"food", "foot", "barbeque"}, ""},
+ {[]string{"cafeteria", "café"}, "caf"},
+ {[]string{"cafe", "café"}, "caf"},
+ {[]string{"cafè", "café"}, "caf"},
+ {[]string{"cafés", "café"}, "café"},
+ {[]string{"áéíóú", "áéíóú"}, "áéíóú"},
+ {[]string{"éclairs", "éclairs"}, "éclairs"},
+ {[]string{"éclairs are the best", "éclairs are great", "éclairs"}, "éclairs"},
+ {[]string{"éclair", "éclairs"}, "éclair"},
+ {[]string{"éclairs", "éclair"}, "éclair"},
+ {[]string{"éclair", "élan"}, "é"},
+ }
+
+ for _, test := range list {
+ lcp := longestCommonPrefix(test.list)
+ if lcp != test.prefix {
+ t.Errorf("%s != %s for %+v", lcp, test.prefix, test.list)
+ }
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/peterh/liner/race_test.go b/Godeps/_workspace/src/github.com/peterh/liner/race_test.go
new file mode 100644
index 000000000..e320849c7
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/peterh/liner/race_test.go
@@ -0,0 +1,44 @@
+// +build race
+
+package liner
+
+import (
+ "io/ioutil"
+ "os"
+ "sync"
+ "testing"
+)
+
+func TestWriteHistory(t *testing.T) {
+ oldout := os.Stdout
+ defer func() { os.Stdout = oldout }()
+ oldin := os.Stdout
+ defer func() { os.Stdin = oldin }()
+
+ newinr, newinw, err := os.Pipe()
+ if err != nil {
+ t.Fatal(err)
+ }
+ os.Stdin = newinr
+ newoutr, newoutw, err := os.Pipe()
+ if err != nil {
+ t.Fatal(err)
+ }
+ defer newoutr.Close()
+ os.Stdout = newoutw
+
+ var wait sync.WaitGroup
+ wait.Add(1)
+ s := NewLiner()
+ go func() {
+ s.AppendHistory("foo")
+ s.AppendHistory("bar")
+ s.Prompt("")
+ wait.Done()
+ }()
+
+ s.WriteHistory(ioutil.Discard)
+
+ newinw.Close()
+ wait.Wait()
+}
diff --git a/Godeps/_workspace/src/github.com/peterh/liner/signal.go b/Godeps/_workspace/src/github.com/peterh/liner/signal.go
new file mode 100644
index 000000000..0cba79e7f
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/peterh/liner/signal.go
@@ -0,0 +1,12 @@
+// +build go1.1,!windows
+
+package liner
+
+import (
+ "os"
+ "os/signal"
+)
+
+func stopSignal(c chan<- os.Signal) {
+ signal.Stop(c)
+}
diff --git a/Godeps/_workspace/src/github.com/peterh/liner/signal_legacy.go b/Godeps/_workspace/src/github.com/peterh/liner/signal_legacy.go
new file mode 100644
index 000000000..fa3672daa
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/peterh/liner/signal_legacy.go
@@ -0,0 +1,11 @@
+// +build !go1.1,!windows
+
+package liner
+
+import (
+ "os"
+)
+
+func stopSignal(c chan<- os.Signal) {
+ // signal.Stop does not exist before Go 1.1
+}
diff --git a/Godeps/_workspace/src/github.com/peterh/liner/unixmode.go b/Godeps/_workspace/src/github.com/peterh/liner/unixmode.go
new file mode 100644
index 000000000..9838923f5
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/peterh/liner/unixmode.go
@@ -0,0 +1,37 @@
+// +build linux darwin freebsd openbsd netbsd
+
+package liner
+
+import (
+ "syscall"
+ "unsafe"
+)
+
+func (mode *termios) ApplyMode() error {
+ _, _, errno := syscall.Syscall(syscall.SYS_IOCTL, uintptr(syscall.Stdin), setTermios, uintptr(unsafe.Pointer(mode)))
+
+ if errno != 0 {
+ return errno
+ }
+ return nil
+}
+
+// TerminalMode returns the current terminal input mode as an InputModeSetter.
+//
+// This function is provided for convenience, and should
+// not be necessary for most users of liner.
+func TerminalMode() (ModeApplier, error) {
+ mode, errno := getMode(syscall.Stdin)
+
+ if errno != 0 {
+ return nil, errno
+ }
+ return mode, nil
+}
+
+func getMode(handle int) (*termios, syscall.Errno) {
+ var mode termios
+ _, _, errno := syscall.Syscall(syscall.SYS_IOCTL, uintptr(handle), getTermios, uintptr(unsafe.Pointer(&mode)))
+
+ return &mode, errno
+}
diff --git a/Godeps/_workspace/src/github.com/peterh/liner/width.go b/Godeps/_workspace/src/github.com/peterh/liner/width.go
new file mode 100644
index 000000000..02cfb5e1b
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/peterh/liner/width.go
@@ -0,0 +1,47 @@
+package liner
+
+import "unicode"
+
+// These character classes are mostly zero width (when combined).
+// A few might not be, depending on the user's font. Fixing this
+// is non-trivial, given that some terminals don't support
+// ANSI DSR/CPR
+var zeroWidth = []*unicode.RangeTable{
+ unicode.Mn,
+ unicode.Me,
+ unicode.Cc,
+ unicode.Cf,
+}
+
+func countGlyphs(s []rune) int {
+ n := 0
+ for _, r := range s {
+ if !unicode.IsOneOf(zeroWidth, r) {
+ n++
+ }
+ }
+ return n
+}
+
+func getPrefixGlyphs(s []rune, num int) []rune {
+ p := 0
+ for n := 0; n < num && p < len(s); p++ {
+ if !unicode.IsOneOf(zeroWidth, s[p]) {
+ n++
+ }
+ }
+ for p < len(s) && unicode.IsOneOf(zeroWidth, s[p]) {
+ p++
+ }
+ return s[:p]
+}
+
+func getSuffixGlyphs(s []rune, num int) []rune {
+ p := len(s)
+ for n := 0; n < num && p > 0; p-- {
+ if !unicode.IsOneOf(zeroWidth, s[p-1]) {
+ n++
+ }
+ }
+ return s[p:]
+}
diff --git a/Godeps/_workspace/src/github.com/peterh/liner/width_test.go b/Godeps/_workspace/src/github.com/peterh/liner/width_test.go
new file mode 100644
index 000000000..134920a4b
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/peterh/liner/width_test.go
@@ -0,0 +1,87 @@
+package liner
+
+import (
+ "strconv"
+ "testing"
+)
+
+func accent(in []rune) []rune {
+ var out []rune
+ for _, r := range in {
+ out = append(out, r)
+ out = append(out, '\u0301')
+ }
+ return out
+}
+
+var testString = []rune("query")
+
+func TestCountGlyphs(t *testing.T) {
+ count := countGlyphs(testString)
+ if count != len(testString) {
+ t.Errorf("ASCII count incorrect. %d != %d", count, len(testString))
+ }
+ count = countGlyphs(accent(testString))
+ if count != len(testString) {
+ t.Errorf("Accent count incorrect. %d != %d", count, len(testString))
+ }
+}
+
+func compare(a, b []rune, name string, t *testing.T) {
+ if len(a) != len(b) {
+ t.Errorf(`"%s" != "%s" in %s"`, string(a), string(b), name)
+ return
+ }
+ for i := range a {
+ if a[i] != b[i] {
+ t.Errorf(`"%s" != "%s" in %s"`, string(a), string(b), name)
+ return
+ }
+ }
+}
+
+func TestPrefixGlyphs(t *testing.T) {
+ for i := 0; i <= len(testString); i++ {
+ iter := strconv.Itoa(i)
+ out := getPrefixGlyphs(testString, i)
+ compare(out, testString[:i], "ascii prefix "+iter, t)
+ out = getPrefixGlyphs(accent(testString), i)
+ compare(out, accent(testString[:i]), "accent prefix "+iter, t)
+ }
+ out := getPrefixGlyphs(testString, 999)
+ compare(out, testString, "ascii prefix overflow", t)
+ out = getPrefixGlyphs(accent(testString), 999)
+ compare(out, accent(testString), "accent prefix overflow", t)
+
+ out = getPrefixGlyphs(testString, -3)
+ if len(out) != 0 {
+ t.Error("ascii prefix negative")
+ }
+ out = getPrefixGlyphs(accent(testString), -3)
+ if len(out) != 0 {
+ t.Error("accent prefix negative")
+ }
+}
+
+func TestSuffixGlyphs(t *testing.T) {
+ for i := 0; i <= len(testString); i++ {
+ iter := strconv.Itoa(i)
+ out := getSuffixGlyphs(testString, i)
+ compare(out, testString[len(testString)-i:], "ascii suffix "+iter, t)
+ out = getSuffixGlyphs(accent(testString), i)
+ compare(out, accent(testString[len(testString)-i:]), "accent suffix "+iter, t)
+ }
+ out := getSuffixGlyphs(testString, 999)
+ compare(out, testString, "ascii suffix overflow", t)
+ out = getSuffixGlyphs(accent(testString), 999)
+ compare(out, accent(testString), "accent suffix overflow", t)
+
+ out = getSuffixGlyphs(testString, -3)
+ if len(out) != 0 {
+ t.Error("ascii suffix negative")
+ }
+ out = getSuffixGlyphs(accent(testString), -3)
+ if len(out) != 0 {
+ t.Error("accent suffix negative")
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/rakyll/globalconf/.travis.yml b/Godeps/_workspace/src/github.com/rakyll/globalconf/.travis.yml
new file mode 100644
index 000000000..fb9efcb9a
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/rakyll/globalconf/.travis.yml
@@ -0,0 +1,2 @@
+language: go
+go: 1.2
diff --git a/Godeps/_workspace/src/github.com/rakyll/globalconf/README.md b/Godeps/_workspace/src/github.com/rakyll/globalconf/README.md
new file mode 100644
index 000000000..dcbf4ddf0
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/rakyll/globalconf/README.md
@@ -0,0 +1,144 @@
+# globalconf
+
+[![Build Status](https://travis-ci.org/rakyll/globalconf.png?branch=master)](https://travis-ci.org/rakyll/globalconf)
+
+Effortlessly persist/retrieve flags of your Golang programs. If you need global configuration instead of requiring user always to set command line flags, you are looking at the right package. `globalconf` allows your users to not only provide flags, but config files and environment variables as well.
+
+## Usage
+
+~~~ go
+import "github.com/rakyll/globalconf"
+~~~
+
+### Loading a config file
+
+By default, globalconf provides you a config file under `~/.config/<yourappname>/config.ini`.
+
+~~~ go
+globalconf.New("appname") // loads from ~/.config/<appname>/config.ini
+~~~
+
+If you don't prefer the default location you can load from a specified path as well.
+
+~~~ go
+globalconf.NewWithOptions(&globalconf.Options{
+ Filename: "/path/to/config/file",
+})
+~~~
+
+You may like to override configuration with env variables. See "Environment variables" header to see how to it works.
+
+~~~ go
+globalconf.NewWithOptions(&globalconf.Options{
+ Filename: "/path/to/config/file",
+ EnvPrefix: "APPCONF_",
+})
+~~~
+
+### Parsing flag values
+
+`globalconf` populates flags with data in the config file if they are not already set.
+
+~~~ go
+var (
+ flagName = flag.String("name", "", "Name of the person.")
+ flagAddress = flag.String("addr", "", "Address of the person.")
+)
+~~~
+
+Assume the configuration file to be loaded contains the following lines.
+
+ name = Burcu
+ addr = Brandschenkestrasse 110, 8002
+
+And your program is being started, `$ myapp -name=Jane`
+~~~ go
+conf, err := globalconf.New("myapp")
+conf.ParseAll()
+~~~
+
+`*flagName` is going to be equal to `Jane`, whereas `*flagAddress` is `Brandschenkestrasse 110, 8002`, what is provided in the configuration file.
+
+### Custom flag sets
+
+Custom flagsets are supported, but required registration before parse is done. The default flagset `flag.CommandLine` is automatically registered.
+
+~~~ go
+globalconf.Register("termopts", termOptsFlagSet)
+conf.ParseAll() // parses command line and all registered flag sets
+~~~
+
+Custom flagset values should be provided in their own segment. Getting back to the sample ini config file, termopts values will have their own segment.
+
+ name = Burcu
+ addr = Brandschenkestrasse 110, 8002
+
+ [termopts]
+ color = true
+ background = ff0000
+
+### Environment variables
+
+If an EnvPrefix is provided, environment variables will take precedence over values in the configuration file.
+Set the `EnvPrefix` option when calling `globalconf.NewWithOptions`.
+An `EnvPrefix` will only be used if it is a non-empty string.
+Command line flags will override the environment variables.
+
+~~~ go
+opts := globalconf.Options{
+ EnvPrefix: "MYAPP_",
+ Filename: "/path/to/config",
+}
+conf, err := globalconf.NewWithOptions(&opts)
+conf.ParseAll()
+~~~
+
+With environment variables:
+
+ APPCONF_NAME = Burcu
+
+and configuration:
+
+ name = Jane
+ addr = Brandschenkestrasse 110, 8002
+
+`name` will be set to "burcu" and `addr` will be set to "Brandschenkestrasse 110, 8002".
+
+### Modifying stored flags
+
+Modifications are persisted as long as you set a new flag and your GlobalConf
+object was configured with a filename.
+
+~~~ go
+f := &flag.Flag{Name: "name", Value: val}
+conf.Set("", f) // if you are modifying a command line flag
+
+f := &flag.Flag{Name: "color", Value: val}
+conf.Set("termopts", color) // if you are modifying a custom flag set flag
+~~~
+
+### Deleting stored flags
+
+Like Set, Deletions are persisted as long as you delete a flag's value and your
+GlobalConf object was configured with a filename.
+
+~~~ go
+conf.Delete("", "name") // removes command line flag "name"s value from config
+conf.Delete("termopts", "color") // removes "color"s value from the custom flag set
+~~~
+
+## License
+
+Copyright 2014 Google Inc. All Rights Reserved.
+
+Licensed under the Apache License, Version 2.0 (the "License");
+you may not use this file except in compliance with the License.
+You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing, software
+distributed under the License is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+See the License for the specific language governing permissions and
+limitations under the License. ![Analytics](https://ga-beacon.appspot.com/UA-46881978-1/globalconf?pixel)
diff --git a/Godeps/_workspace/src/github.com/rakyll/globalconf/globalconf.go b/Godeps/_workspace/src/github.com/rakyll/globalconf/globalconf.go
new file mode 100644
index 000000000..57d5dd42a
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/rakyll/globalconf/globalconf.go
@@ -0,0 +1,179 @@
+package globalconf
+
+import (
+ "flag"
+ "io/ioutil"
+ "os"
+ "os/user"
+ "path"
+ "strings"
+
+ ini "github.com/rakyll/goini"
+)
+
+const (
+ defaultConfigFileName = "config.ini"
+)
+
+var flags map[string]*flag.FlagSet = make(map[string]*flag.FlagSet)
+
+// Represents a GlobalConf context.
+type GlobalConf struct {
+ Filename string
+ EnvPrefix string
+ dict *ini.Dict
+}
+
+type Options struct {
+ Filename string
+ EnvPrefix string
+}
+
+// NewWithOptions creates a GlobalConf from the provided
+// Options. The caller is responsible for creating any
+// referenced config files.
+func NewWithOptions(opts *Options) (g *GlobalConf, err error) {
+ Register("", flag.CommandLine)
+
+ var dict ini.Dict
+ if opts.Filename != "" {
+ dict, err = ini.Load(opts.Filename)
+ if err != nil {
+ return nil, err
+ }
+ } else {
+ dict = make(ini.Dict, 0)
+ }
+
+ return &GlobalConf{
+ Filename: opts.Filename,
+ EnvPrefix: opts.EnvPrefix,
+ dict: &dict,
+ }, nil
+}
+
+// Opens/creates a config file for the specified appName.
+// The path to config file is ~/.config/appName/config.ini.
+func New(appName string) (g *GlobalConf, err error) {
+ var u *user.User
+ if u, err = user.Current(); u == nil {
+ return
+ }
+ // Create config file's directory.
+ dirPath := path.Join(u.HomeDir, ".config", appName)
+ if err = os.MkdirAll(dirPath, 0755); err != nil {
+ return
+ }
+ // Touch a config file if it doesn't exit.
+ filePath := path.Join(dirPath, defaultConfigFileName)
+ if _, err = os.Stat(filePath); err != nil {
+ if !os.IsNotExist(err) {
+ return
+ }
+ // create file
+ if err = ioutil.WriteFile(filePath, []byte{}, 0644); err != nil {
+ return
+ }
+ }
+ opts := Options{Filename: filePath}
+ return NewWithOptions(&opts)
+}
+
+// Sets a flag's value and persists the changes to the disk.
+func (g *GlobalConf) Set(flagSetName string, f *flag.Flag) error {
+ g.dict.SetString(flagSetName, f.Name, f.Value.String())
+ if g.Filename != "" {
+ return ini.Write(g.Filename, g.dict)
+ }
+ return nil
+}
+
+// Deletes a flag from config file and persists the changes
+// to the disk.
+func (g *GlobalConf) Delete(flagSetName, flagName string) error {
+ g.dict.Delete(flagSetName, flagName)
+ if g.Filename != "" {
+ return ini.Write(g.Filename, g.dict)
+ }
+ return nil
+}
+
+// Parses the config file for the provided flag set.
+// If the flags are already set, values are overwritten
+// by the values in the config file. Defaults are not set
+// if the flag is not in the file.
+func (g *GlobalConf) ParseSet(flagSetName string, set *flag.FlagSet) {
+ set.VisitAll(func(f *flag.Flag) {
+ val := getEnv(g.EnvPrefix, flagSetName, f.Name)
+ if val != "" {
+ set.Set(f.Name, val)
+ return
+ }
+
+ val, found := g.dict.GetString(flagSetName, f.Name)
+ if found {
+ set.Set(f.Name, val)
+ }
+ })
+}
+
+// Parses all the registered flag sets, including the command
+// line set and sets values from the config file if they are
+// not already set.
+func (g *GlobalConf) Parse() {
+ for name, set := range flags {
+ alreadySet := make(map[string]bool)
+ set.Visit(func(f *flag.Flag) {
+ alreadySet[f.Name] = true
+ })
+ set.VisitAll(func(f *flag.Flag) {
+ // if not already set, set it from dict if exists
+ if alreadySet[f.Name] {
+ return
+ }
+
+ val := getEnv(g.EnvPrefix, name, f.Name)
+ if val != "" {
+ set.Set(f.Name, val)
+ return
+ }
+
+ val, found := g.dict.GetString(name, f.Name)
+ if found {
+ set.Set(f.Name, val)
+ }
+ })
+ }
+}
+
+// Parses command line flags and then, all of the registered
+// flag sets with the values provided in the config file.
+func (g *GlobalConf) ParseAll() {
+ if !flag.Parsed() {
+ flag.Parse()
+ }
+ g.Parse()
+}
+
+// Looks up variable in environment
+func getEnv(envPrefix, flagSetName, flagName string) string {
+ // If we haven't set an EnvPrefix, don't lookup vals in the ENV
+ if envPrefix == "" {
+ return ""
+ }
+ // Append a _ to flagSetName if it exists.
+ if flagSetName != "" {
+ flagSetName += "_"
+ }
+ flagName = strings.Replace(flagName, ".", "_", -1)
+ flagName = strings.Replace(flagName, "-", "_", -1)
+ envKey := strings.ToUpper(envPrefix + flagSetName + flagName)
+ return os.Getenv(envKey)
+}
+
+// Registers a flag set to be parsed. Register all flag sets
+// before calling this function. flag.CommandLine is automatically
+// registered.
+func Register(flagSetName string, set *flag.FlagSet) {
+ flags[flagSetName] = set
+}
diff --git a/Godeps/_workspace/src/github.com/rakyll/globalconf/globalconf_test.go b/Godeps/_workspace/src/github.com/rakyll/globalconf/globalconf_test.go
new file mode 100644
index 000000000..f36f74cea
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/rakyll/globalconf/globalconf_test.go
@@ -0,0 +1,267 @@
+package globalconf
+
+import (
+ "flag"
+ "io/ioutil"
+ "os"
+ "testing"
+)
+
+const envTestPrefix = "CONFTEST_"
+
+func TestNewWithOptionsNoFilename(t *testing.T) {
+ opts := Options{EnvPrefix: envTestPrefix}
+
+ os.Setenv(envTestPrefix+"D", "EnvD")
+
+ flagD := flag.String("d", "default", "")
+ flagE := flag.Bool("e", true, "")
+
+ conf, err := NewWithOptions(&opts)
+ if err != nil {
+ t.Fatal(err)
+ }
+ conf.ParseAll()
+
+ if *flagD != "EnvD" {
+ t.Errorf("flagD found %v, expected 'EnvD'", *flagD)
+ }
+ if !*flagE {
+ t.Errorf("flagE found %v, expected true", *flagE)
+ }
+}
+
+func TestParse_Global(t *testing.T) {
+ resetForTesting("")
+
+ os.Setenv(envTestPrefix+"D", "EnvD")
+ os.Setenv(envTestPrefix+"E", "true")
+ os.Setenv(envTestPrefix+"F", "5.5")
+
+ flagA := flag.Bool("a", false, "")
+ flagB := flag.Float64("b", 0.0, "")
+ flagC := flag.String("c", "", "")
+
+ flagD := flag.String("d", "", "")
+ flagE := flag.Bool("e", false, "")
+ flagF := flag.Float64("f", 0.0, "")
+
+ parse(t, "./testdata/global.ini", envTestPrefix)
+ if !*flagA {
+ t.Errorf("flagA found %v, expected true", *flagA)
+ }
+ if *flagB != 5.6 {
+ t.Errorf("flagB found %v, expected 5.6", *flagB)
+ }
+ if *flagC != "Hello world" {
+ t.Errorf("flagC found %v, expected 'Hello world'", *flagC)
+ }
+ if *flagD != "EnvD" {
+ t.Errorf("flagD found %v, expected 'EnvD'", *flagD)
+ }
+ if !*flagE {
+ t.Errorf("flagE found %v, expected true", *flagE)
+ }
+ if *flagF != 5.5 {
+ t.Errorf("flagF found %v, expected 5.5", *flagF)
+ }
+}
+
+func TestParse_DashConversion(t *testing.T) {
+ resetForTesting("")
+
+ flagFooBar := flag.String("foo-bar", "", "")
+ os.Setenv("PREFIX_FOO_BAR", "baz")
+
+ opts := Options{EnvPrefix: "PREFIX_"}
+ conf, err := NewWithOptions(&opts)
+ if err != nil {
+ t.Fatal(err)
+ }
+ conf.ParseAll()
+
+ if *flagFooBar != "baz" {
+ t.Errorf("flagFooBar found %v, expected 5.5", *flagFooBar)
+ }
+}
+
+func TestParse_GlobalWithDottedFlagname(t *testing.T) {
+ resetForTesting("")
+ os.Setenv(envTestPrefix+"SOME_VALUE", "some-value")
+ flagSomeValue := flag.String("some.value", "", "")
+
+ parse(t, "./testdata/global.ini", envTestPrefix)
+ if *flagSomeValue != "some-value" {
+ t.Errorf("flagSomeValue found %v, some-value expected", *flagSomeValue)
+ }
+}
+
+func TestParse_GlobalOverwrite(t *testing.T) {
+ resetForTesting("-b=7.6")
+ flagB := flag.Float64("b", 0.0, "")
+
+ parse(t, "./testdata/global.ini", "")
+ if *flagB != 7.6 {
+ t.Errorf("flagB found %v, expected 7.6", *flagB)
+ }
+}
+
+func TestParse_Custom(t *testing.T) {
+ resetForTesting("")
+
+ os.Setenv(envTestPrefix+"CUSTOM_E", "Hello Env")
+
+ flagB := flag.Float64("b", 5.0, "")
+
+ name := "custom"
+ custom := flag.NewFlagSet(name, flag.ExitOnError)
+ flagD := custom.String("d", "dd", "")
+ flagE := custom.String("e", "ee", "")
+
+ Register(name, custom)
+ parse(t, "./testdata/custom.ini", envTestPrefix)
+ if *flagB != 5.0 {
+ t.Errorf("flagB found %v, expected 5.0", *flagB)
+ }
+ if *flagD != "Hello d" {
+ t.Errorf("flagD found %v, expected 'Hello d'", *flagD)
+ }
+ if *flagE != "Hello Env" {
+ t.Errorf("flagE found %v, expected 'Hello Env'", *flagE)
+ }
+}
+
+func TestParse_CustomOverwrite(t *testing.T) {
+ resetForTesting("-b=6")
+ flagB := flag.Float64("b", 5.0, "")
+
+ name := "custom"
+ custom := flag.NewFlagSet(name, flag.ExitOnError)
+ flagD := custom.String("d", "dd", "")
+
+ Register(name, custom)
+ parse(t, "./testdata/custom.ini", "")
+ if *flagB != 6.0 {
+ t.Errorf("flagB found %v, expected 6.0", *flagB)
+ }
+ if *flagD != "Hello d" {
+ t.Errorf("flagD found %v, expected 'Hello d'", *flagD)
+ }
+}
+
+func TestParse_GlobalAndCustom(t *testing.T) {
+ resetForTesting("")
+ flagA := flag.Bool("a", false, "")
+ flagB := flag.Float64("b", 0.0, "")
+ flagC := flag.String("c", "", "")
+
+ name := "custom"
+ custom := flag.NewFlagSet(name, flag.ExitOnError)
+ flagD := custom.String("d", "", "")
+
+ Register(name, custom)
+ parse(t, "./testdata/globalandcustom.ini", "")
+ if !*flagA {
+ t.Errorf("flagA found %v, expected true", *flagA)
+ }
+ if *flagB != 5.6 {
+ t.Errorf("flagB found %v, expected 5.6", *flagB)
+ }
+ if *flagC != "Hello world" {
+ t.Errorf("flagC found %v, expected 'Hello world'", *flagC)
+ }
+ if *flagD != "Hello d" {
+ t.Errorf("flagD found %v, expected 'Hello d'", *flagD)
+ }
+}
+
+func TestParse_GlobalAndCustomOverwrite(t *testing.T) {
+ resetForTesting("-a=true", "-b=5", "-c=Hello")
+ flagA := flag.Bool("a", false, "")
+ flagB := flag.Float64("b", 0.0, "")
+ flagC := flag.String("c", "", "")
+
+ name := "custom"
+ custom := flag.NewFlagSet(name, flag.ExitOnError)
+ flagD := custom.String("d", "", "")
+
+ Register(name, custom)
+ parse(t, "./testdata/globalandcustom.ini", "")
+ if !*flagA {
+ t.Errorf("flagA found %v, expected true", *flagA)
+ }
+ if *flagB != 5.0 {
+ t.Errorf("flagB found %v, expected 5.0", *flagB)
+ }
+ if *flagC != "Hello" {
+ t.Errorf("flagC found %v, expected 'Hello'", *flagC)
+ }
+ if *flagD != "Hello d" {
+ t.Errorf("flagD found %v, expected 'Hello d'", *flagD)
+ }
+}
+
+func TestSet(t *testing.T) {
+ resetForTesting()
+ file, _ := ioutil.TempFile("", "")
+ conf := parse(t, file.Name(), "")
+ conf.Set("", &flag.Flag{Name: "a", Value: newFlagValue("test")})
+
+ flagA := flag.String("a", "", "")
+ parse(t, file.Name(), "")
+ if *flagA != "test" {
+ t.Errorf("flagA found %v, expected 'test'", *flagA)
+ }
+}
+
+func TestDelete(t *testing.T) {
+ resetForTesting()
+ file, _ := ioutil.TempFile("", "")
+ conf := parse(t, file.Name(), "")
+ conf.Set("", &flag.Flag{Name: "a", Value: newFlagValue("test")})
+ conf.Delete("", "a")
+
+ flagA := flag.String("a", "", "")
+ parse(t, file.Name(), "")
+ if *flagA != "" {
+ t.Errorf("flagNewA found %v, expected ''", *flagA)
+ }
+}
+
+func parse(t *testing.T, filename, envPrefix string) *GlobalConf {
+ opts := Options{
+ Filename: filename,
+ EnvPrefix: envPrefix,
+ }
+ conf, err := NewWithOptions(&opts)
+ if err != nil {
+ t.Error(err)
+ }
+ conf.ParseAll()
+ return conf
+}
+
+// Resets os.Args and the default flag set.
+func resetForTesting(args ...string) {
+ os.Clearenv()
+
+ os.Args = append([]string{"cmd"}, args...)
+ flag.CommandLine = flag.NewFlagSet(os.Args[0], flag.ExitOnError)
+}
+
+type flagValue struct {
+ str string
+}
+
+func (f *flagValue) String() string {
+ return f.str
+}
+
+func (f *flagValue) Set(value string) error {
+ f.str = value
+ return nil
+}
+
+func newFlagValue(val string) *flagValue {
+ return &flagValue{str: val}
+}
diff --git a/Godeps/_workspace/src/github.com/rakyll/globalconf/testdata/custom.ini b/Godeps/_workspace/src/github.com/rakyll/globalconf/testdata/custom.ini
new file mode 100644
index 000000000..23795a1f0
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/rakyll/globalconf/testdata/custom.ini
@@ -0,0 +1,2 @@
+[custom]
+d = Hello d
diff --git a/Godeps/_workspace/src/github.com/rakyll/globalconf/testdata/global.ini b/Godeps/_workspace/src/github.com/rakyll/globalconf/testdata/global.ini
new file mode 100644
index 000000000..126888858
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/rakyll/globalconf/testdata/global.ini
@@ -0,0 +1,3 @@
+a = true
+b = 5.6
+c = Hello world
diff --git a/Godeps/_workspace/src/github.com/rakyll/globalconf/testdata/globalandcustom.ini b/Godeps/_workspace/src/github.com/rakyll/globalconf/testdata/globalandcustom.ini
new file mode 100644
index 000000000..c48a933ed
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/rakyll/globalconf/testdata/globalandcustom.ini
@@ -0,0 +1,6 @@
+a = true
+b = 5.6
+c = Hello world
+
+[custom]
+d = Hello d
diff --git a/Godeps/_workspace/src/github.com/rakyll/goini/.gitignore b/Godeps/_workspace/src/github.com/rakyll/goini/.gitignore
new file mode 100644
index 000000000..6facd5a72
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/rakyll/goini/.gitignore
@@ -0,0 +1,8 @@
+.*.swp
+
+*.[689]
+[689].out
+
+_obj
+_test
+_testmain.go
diff --git a/Godeps/_workspace/src/github.com/rakyll/goini/Makefile b/Godeps/_workspace/src/github.com/rakyll/goini/Makefile
new file mode 100644
index 000000000..bc67d570d
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/rakyll/goini/Makefile
@@ -0,0 +1,7 @@
+test:
+ go test
+
+format:
+ gofmt -w *.go
+
+.PHONY: format test
diff --git a/Godeps/_workspace/src/github.com/rakyll/goini/empty.ini b/Godeps/_workspace/src/github.com/rakyll/goini/empty.ini
new file mode 100644
index 000000000..e69de29bb
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/rakyll/goini/empty.ini
diff --git a/Godeps/_workspace/src/github.com/rakyll/goini/example.ini b/Godeps/_workspace/src/github.com/rakyll/goini/example.ini
new file mode 100644
index 000000000..1a21f8e37
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/rakyll/goini/example.ini
@@ -0,0 +1,18 @@
+#
+# This is an example of ini file
+#
+
+[Pizza]
+
+Ham = yes;
+Mushrooms = TRUE;
+Capres = 0;
+Cheese = Non;
+
+
+[Wine]
+
+Grape = Cabernet Sauvignon;
+Year = 1989;
+Country = Spain;
+Alcohol = 12.5;
diff --git a/Godeps/_workspace/src/github.com/rakyll/goini/ini.go b/Godeps/_workspace/src/github.com/rakyll/goini/ini.go
new file mode 100644
index 000000000..54b81f18b
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/rakyll/goini/ini.go
@@ -0,0 +1,241 @@
+package ini
+
+import (
+ "bufio"
+ "bytes"
+ "fmt"
+ "io/ioutil"
+ "os"
+ "regexp"
+ "strconv"
+ "strings"
+ "unicode"
+)
+
+type Dict map[string]map[string]string
+
+type Error string
+
+var (
+ regDoubleQuote = regexp.MustCompile("^([^= \t]+)[ \t]*=[ \t]*\"([^\"]*)\"$")
+ regSingleQuote = regexp.MustCompile("^([^= \t]+)[ \t]*=[ \t]*'([^']*)'$")
+ regNoQuote = regexp.MustCompile("^([^= \t]+)[ \t]*=[ \t]*([^#;]+)")
+ regNoValue = regexp.MustCompile("^([^= \t]+)[ \t]*=[ \t]*([#;].*)?")
+)
+
+func Load(filename string) (dict Dict, err error) {
+ file, err := os.Open(filename)
+ if err != nil {
+ return nil, err
+ }
+ defer file.Close()
+
+ dict = make(map[string]map[string]string)
+ reader := bufio.NewReader(file)
+ lineno := 0
+ section := ""
+ dict[section] = make(map[string]string)
+
+ for err == nil {
+ l, _, err := reader.ReadLine()
+ if err != nil {
+ break
+ }
+ lineno++
+ if len(l) == 0 {
+ continue
+ }
+ line := strings.TrimFunc(string(l), unicode.IsSpace)
+
+ for line[len(line)-1] == '\\' {
+ line = line[:len(line)-1]
+ l, _, err := reader.ReadLine()
+ if err != nil {
+ return nil, err
+ }
+ line += strings.TrimFunc(string(l), unicode.IsSpace)
+ }
+
+ section, err = dict.parseLine(section, line)
+ if err != nil {
+ return nil, newError(
+ err.Error() + fmt.Sprintf("'%s:%d'.", filename, lineno))
+ }
+ }
+
+ return
+}
+
+func Write(filename string, dict *Dict) error {
+ buffer := dict.format()
+ return ioutil.WriteFile(filename, buffer.Bytes(), 0644)
+}
+
+func (e Error) Error() string {
+ return string(e)
+}
+func (dict Dict) parseLine(section, line string) (string, error) {
+ // commets
+ if line[0] == '#' || line[0] == ';' {
+ return section, nil
+ }
+
+ // section name
+ if line[0] == '[' && line[len(line)-1] == ']' {
+ section := strings.TrimFunc(line[1:len(line)-1], unicode.IsSpace)
+ section = strings.ToLower(section)
+ dict[section] = make(map[string]string)
+ return section, nil
+ }
+
+ // key = value
+ if m := regDoubleQuote.FindAllStringSubmatch(line, 1); m != nil {
+ dict.add(section, m[0][1], m[0][2])
+ return section, nil
+ } else if m = regSingleQuote.FindAllStringSubmatch(line, 1); m != nil {
+ dict.add(section, m[0][1], m[0][2])
+ return section, nil
+ } else if m = regNoQuote.FindAllStringSubmatch(line, 1); m != nil {
+ dict.add(section, m[0][1], strings.TrimFunc(m[0][2], unicode.IsSpace))
+ return section, nil
+ } else if m = regNoValue.FindAllStringSubmatch(line, 1); m != nil {
+ dict.add(section, m[0][1], "")
+ return section, nil
+ }
+
+ return section, newError("iniparser: syntax error at ")
+}
+
+func (dict Dict) add(section, key, value string) {
+ key = strings.ToLower(key)
+ dict[section][key] = value
+}
+
+func (dict Dict) GetBool(section, key string) (bool, bool) {
+ sec, ok := dict[section]
+ if !ok {
+ return false, false
+ }
+ value, ok := sec[key]
+ if !ok {
+ return false, false
+ }
+ v := value[0]
+ if v == 'y' || v == 'Y' || v == '1' || v == 't' || v == 'T' {
+ return true, true
+ }
+ if v == 'n' || v == 'N' || v == '0' || v == 'f' || v == 'F' {
+ return false, true
+ }
+ return false, false
+}
+
+func (dict Dict) SetBool(section, key string, value bool) {
+ dict.SetString(section, key, strconv.FormatBool(value))
+}
+
+func (dict Dict) GetString(section, key string) (string, bool) {
+ sec, ok := dict[section]
+ if !ok {
+ return "", false
+ }
+ value, ok := sec[key]
+ if !ok {
+ return "", false
+ }
+ return value, true
+}
+
+func (dict Dict) SetString(section, key, value string) {
+ _, ok := dict[section]
+ if !ok {
+ dict[section] = make(map[string]string)
+ }
+ dict[section][key] = value
+}
+
+func (dict Dict) GetInt(section, key string) (int, bool) {
+ sec, ok := dict[section]
+ if !ok {
+ return 0, false
+ }
+ value, ok := sec[key]
+ if !ok {
+ return 0, false
+ }
+ i, err := strconv.Atoi(value)
+ if err != nil {
+ return 0, false
+ }
+ return i, true
+}
+
+func (dict Dict) SetInt(section, key string, value int) {
+ dict.SetString(section, key, strconv.FormatInt(int64(value), 10))
+}
+
+func (dict Dict) GetDouble(section, key string) (float64, bool) {
+ sec, ok := dict[section]
+ if !ok {
+ return 0, false
+ }
+ value, ok := sec[key]
+ if !ok {
+ return 0, false
+ }
+ d, err := strconv.ParseFloat(value, 64)
+ if err != nil {
+ return 0, false
+ }
+ return d, true
+}
+
+func (dict Dict) SetDouble(section, key string, value float64) {
+ dict.SetString(section, key, strconv.FormatFloat(value, 'f', -1, 64))
+}
+
+func (dict Dict) Delete(section, key string) {
+ _, ok := dict[section]
+ if !ok {
+ return
+ }
+ delete(dict[section], key)
+ // If there are no items left in the section,
+ // delete the section.
+ if len(dict[section]) == 0 {
+ delete(dict, section)
+ }
+}
+
+func (dict Dict) GetSections() []string {
+ size := len(dict)
+ sections := make([]string, size)
+ i := 0
+ for section, _ := range dict {
+ sections[i] = section
+ i++
+ }
+ return sections
+}
+
+func (dict Dict) String() string {
+ return (*dict.format()).String()
+}
+
+func (dict Dict) format() *bytes.Buffer {
+ var buffer bytes.Buffer
+ for section, vals := range dict {
+ if section != "" {
+ buffer.WriteString(fmt.Sprintf("[%s]\n", section))
+ }
+ for key, val := range vals {
+ buffer.WriteString(fmt.Sprintf("%s = %s\n", key, val))
+ }
+ buffer.WriteString("\n")
+ }
+ return &buffer
+}
+
+func newError(message string) (e error) {
+ return Error(message)
+}
diff --git a/Godeps/_workspace/src/github.com/rakyll/goini/ini_test.go b/Godeps/_workspace/src/github.com/rakyll/goini/ini_test.go
new file mode 100644
index 000000000..8a15eea4c
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/rakyll/goini/ini_test.go
@@ -0,0 +1,169 @@
+package ini
+
+import (
+ "io/ioutil"
+ "testing"
+)
+
+const (
+ exampleStr = `key1 = true
+
+[section1]
+key1 = value2
+key2 = 5
+key3 = 1.3
+
+[section2]
+key1 = 5
+
+`
+)
+
+var (
+ dict Dict
+ err error
+)
+
+func init() {
+ dict, err = Load("example.ini")
+}
+
+func TestLoad(t *testing.T) {
+ if err != nil {
+ t.Error("Example: load error:", err)
+ }
+}
+
+func TestWrite(t *testing.T) {
+ d, err := Load("empty.ini")
+ if err != nil {
+ t.Error("Example: load error:", err)
+ }
+ d.SetString("", "key", "value")
+ tempFile, err := ioutil.TempFile("", "")
+ if err != nil {
+ t.Error("Write: Couldn't create temp file.", err)
+ }
+ err = Write(tempFile.Name(), &d)
+ if err != nil {
+ t.Error("Write: Couldn't write to temp config file.", err)
+ }
+ contents, err := ioutil.ReadFile(tempFile.Name())
+ if err != nil {
+ t.Error("Write: Couldn't read from the temp config file.", err)
+ }
+ if string(contents) != "key = value\n\n" {
+ t.Error("Write: Contents of the config file doesn't match the expected.")
+ }
+}
+
+func TestGetBool(t *testing.T) {
+ b, found := dict.GetBool("pizza", "ham")
+ if !found || !b {
+ t.Error("Example: parse error for key ham of section pizza.")
+ }
+ b, found = dict.GetBool("pizza", "mushrooms")
+ if !found || !b {
+ t.Error("Example: parse error for key mushrooms of section pizza.")
+ }
+ b, found = dict.GetBool("pizza", "capres")
+ if !found || b {
+ t.Error("Example: parse error for key capres of section pizza.")
+ }
+ b, found = dict.GetBool("pizza", "cheese")
+ if !found || b {
+ t.Error("Example: parse error for key cheese of section pizza.")
+ }
+}
+
+func TestGetStringIntAndDouble(t *testing.T) {
+ str, found := dict.GetString("wine", "grape")
+ if !found || str != "Cabernet Sauvignon" {
+ t.Error("Example: parse error for key grape of section wine.")
+ }
+ i, found := dict.GetInt("wine", "year")
+ if !found || i != 1989 {
+ t.Error("Example: parse error for key year of section wine.")
+ }
+ str, found = dict.GetString("wine", "country")
+ if !found || str != "Spain" {
+ t.Error("Example: parse error for key grape of section wine.")
+ }
+ d, found := dict.GetDouble("wine", "alcohol")
+ if !found || d != 12.5 {
+ t.Error("Example: parse error for key grape of section wine.")
+ }
+}
+
+func TestSetBoolAndStringAndIntAndDouble(t *testing.T) {
+ dict.SetBool("pizza", "ham", false)
+ b, found := dict.GetBool("pizza", "ham")
+ if !found || b {
+ t.Error("Example: bool set error for key ham of section pizza.")
+ }
+ dict.SetString("pizza", "ham", "no")
+ n, found := dict.GetString("pizza", "ham")
+ if !found || n != "no" {
+ t.Error("Example: string set error for key ham of section pizza.")
+ }
+ dict.SetInt("wine", "year", 1978)
+ i, found := dict.GetInt("wine", "year")
+ if !found || i != 1978 {
+ t.Error("Example: int set error for key year of section wine.")
+ }
+ dict.SetDouble("wine", "not-exists", 5.6)
+ d, found := dict.GetDouble("wine", "not-exists")
+ if !found || d != 5.6 {
+ t.Error("Example: float set error for not existing key for wine.")
+ }
+}
+
+func TestDelete(t *testing.T) {
+ d, err := Load("empty.ini")
+ if err != nil {
+ t.Error("Example: load error:", err)
+ }
+ d.SetString("pizza", "ham", "yes")
+ d.Delete("pizza", "ham")
+ _, found := d.GetString("pizza", "ham")
+ if found {
+ t.Error("Example: delete error for key ham of section pizza.")
+ }
+ if len(d.GetSections()) > 1 {
+ t.Error("Only a single section should exist after deletion.")
+ }
+}
+
+func TestGetNotExist(t *testing.T) {
+ _, found := dict.GetString("not", "exist")
+ if found {
+ t.Error("There is no key exist of section not.")
+ }
+}
+
+func TestGetSections(t *testing.T) {
+ sections := dict.GetSections()
+ if len(sections) != 3 {
+ t.Error("The number of sections is wrong:", len(sections))
+ }
+ for _, section := range sections {
+ if section != "" && section != "pizza" && section != "wine" {
+ t.Errorf("Section '%s' should not be exist.", section)
+ }
+ }
+}
+
+func TestString(t *testing.T) {
+ d, err := Load("empty.ini")
+ if err != nil {
+ t.Error("Example: load error:", err)
+ }
+ d.SetBool("", "key1", true)
+ d.SetString("section1", "key1", "value2")
+ d.SetInt("section1", "key2", 5)
+ d.SetDouble("section1", "key3", 1.3)
+ d.SetDouble("section2", "key1", 5.0)
+ if d.String() != exampleStr {
+ t.Errorf("Dict cannot be stringified as expected.")
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/.gitignore b/Godeps/_workspace/src/github.com/robertkrimen/otto/.gitignore
new file mode 100644
index 000000000..8c2a16949
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/.gitignore
@@ -0,0 +1,5 @@
+/.test
+/otto/otto
+/otto/otto-*
+/test/test-*.js
+/test/tester
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/DESIGN.markdown b/Godeps/_workspace/src/github.com/robertkrimen/otto/DESIGN.markdown
new file mode 100644
index 000000000..288752987
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/DESIGN.markdown
@@ -0,0 +1 @@
+* Designate the filename of "anonymous" source code by the hash (md5/sha1, etc.)
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/LICENSE b/Godeps/_workspace/src/github.com/robertkrimen/otto/LICENSE
new file mode 100644
index 000000000..b6179fe38
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/LICENSE
@@ -0,0 +1,7 @@
+Copyright (c) 2012 Robert Krimen
+
+Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/Makefile b/Godeps/_workspace/src/github.com/robertkrimen/otto/Makefile
new file mode 100644
index 000000000..8d74038eb
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/Makefile
@@ -0,0 +1,63 @@
+.PHONY: test test-race test-release release release-check test-262
+.PHONY: parser
+.PHONY: otto assets underscore
+
+TESTS := \
+ ~
+
+TEST := -v --run
+TEST := -v
+TEST := -v --run Test\($(subst $(eval) ,\|,$(TESTS))\)
+TEST := .
+
+test: parser inline.go
+ go test -i
+ go test $(TEST)
+ @echo PASS
+
+parser:
+ $(MAKE) -C parser
+
+inline.go: inline
+ ./$< > $@
+
+#################
+# release, test #
+#################
+
+release: test-race test-release
+ for package in . parser token ast file underscore registry; do (cd $$package && godocdown --signature > README.markdown); done
+ @echo \*\*\* make release-check
+ @echo PASS
+
+release-check: .test
+ $(MAKE) -C test build test
+ $(MAKE) -C .test/test262 build test
+ @echo PASS
+
+test-262: .test
+ $(MAKE) -C .test/test262 build test
+ @echo PASS
+
+test-release:
+ go test -i
+ go test
+
+test-race:
+ go test -race -i
+ go test -race
+
+#################################
+# otto, assets, underscore, ... #
+#################################
+
+otto:
+ $(MAKE) -C otto
+
+assets:
+ mkdir -p .assets
+ for file in underscore/test/*.js; do tr "\`" "_" < $$file > .assets/`basename $$file`; done
+
+underscore:
+ $(MAKE) -C $@
+
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/README.markdown b/Godeps/_workspace/src/github.com/robertkrimen/otto/README.markdown
new file mode 100644
index 000000000..571743bf1
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/README.markdown
@@ -0,0 +1,825 @@
+# otto
+--
+ import "github.com/robertkrimen/otto"
+
+Package otto is a JavaScript parser and interpreter written natively in Go.
+
+http://godoc.org/github.com/robertkrimen/otto
+
+ import (
+ "github.com/robertkrimen/otto"
+ )
+
+Run something in the VM
+
+ vm := otto.New()
+ vm.Run(`
+ abc = 2 + 2;
+ console.log("The value of abc is " + abc); // 4
+ `)
+
+Get a value out of the VM
+
+ value, err := vm.Get("abc")
+ value, _ := value.ToInteger()
+ }
+
+Set a number
+
+ vm.Set("def", 11)
+ vm.Run(`
+ console.log("The value of def is " + def);
+ // The value of def is 11
+ `)
+
+Set a string
+
+ vm.Set("xyzzy", "Nothing happens.")
+ vm.Run(`
+ console.log(xyzzy.length); // 16
+ `)
+
+Get the value of an expression
+
+ value, _ = vm.Run("xyzzy.length")
+ {
+ // value is an int64 with a value of 16
+ value, _ := value.ToInteger()
+ }
+
+An error happens
+
+ value, err = vm.Run("abcdefghijlmnopqrstuvwxyz.length")
+ if err != nil {
+ // err = ReferenceError: abcdefghijlmnopqrstuvwxyz is not defined
+ // If there is an error, then value.IsUndefined() is true
+ ...
+ }
+
+Set a Go function
+
+ vm.Set("sayHello", func(call otto.FunctionCall) otto.Value {
+ fmt.Printf("Hello, %s.\n", call.Argument(0).String())
+ return otto.Value{}
+ })
+
+Set a Go function that returns something useful
+
+ vm.Set("twoPlus", func(call otto.FunctionCall) otto.Value {
+ right, _ := call.Argument(0).ToInteger()
+ result, _ := vm.ToValue(2 + right)
+ return result
+ })
+
+Use the functions in JavaScript
+
+ result, _ = vm.Run(`
+ sayHello("Xyzzy"); // Hello, Xyzzy.
+ sayHello(); // Hello, undefined
+
+ result = twoPlus(2.0); // 4
+ `)
+
+
+### Parser
+
+A separate parser is available in the parser package if you're just interested
+in building an AST.
+
+http://godoc.org/github.com/robertkrimen/otto/parser
+
+Parse and return an AST
+
+ filename := "" // A filename is optional
+ src := `
+ // Sample xyzzy example
+ (function(){
+ if (3.14159 > 0) {
+ console.log("Hello, World.");
+ return;
+ }
+
+ var xyzzy = NaN;
+ console.log("Nothing happens.");
+ return xyzzy;
+ })();
+ `
+
+ // Parse some JavaScript, yielding a *ast.Program and/or an ErrorList
+ program, err := parser.ParseFile(nil, filename, src, 0)
+
+### otto
+
+You can run (Go) JavaScript from the commandline with:
+http://github.com/robertkrimen/otto/tree/master/otto
+
+ $ go get -v github.com/robertkrimen/otto/otto
+
+Run JavaScript by entering some source on stdin or by giving otto a filename:
+
+ $ otto example.js
+
+### underscore
+
+Optionally include the JavaScript utility-belt library, underscore, with this
+import:
+
+ import (
+ "github.com/robertkrimen/otto"
+ _ "github.com/robertkrimen/otto/underscore"
+ )
+
+ // Now every otto runtime will come loaded with underscore
+
+For more information: http://github.com/robertkrimen/otto/tree/master/underscore
+
+
+### Caveat Emptor
+
+The following are some limitations with otto:
+
+ * "use strict" will parse, but does nothing.
+ * The regular expression engine (re2/regexp) is not fully compatible with the ECMA5 specification.
+
+
+### Regular Expression Incompatibility
+
+Go translates JavaScript-style regular expressions into something that is
+"regexp" compatible via `parser.TransformRegExp`. Unfortunately, RegExp requires
+backtracking for some patterns, and backtracking is not supported by the
+standard Go engine: https://code.google.com/p/re2/wiki/Syntax
+
+Therefore, the following syntax is incompatible:
+
+ (?=) // Lookahead (positive), currently a parsing error
+ (?!) // Lookahead (backhead), currently a parsing error
+ \1 // Backreference (\1, \2, \3, ...), currently a parsing error
+
+A brief discussion of these limitations: "Regexp (?!re)"
+https://groups.google.com/forum/?fromgroups=#%21topic/golang-nuts/7qgSDWPIh_E
+
+More information about re2: https://code.google.com/p/re2/
+
+In addition to the above, re2 (Go) has a different definition for \s: [\t\n\f\r
+]. The JavaScript definition, on the other hand, also includes \v, Unicode
+"Separator, Space", etc.
+
+
+### Halting Problem
+
+If you want to stop long running executions (like third-party code), you can use
+the interrupt channel to do this:
+
+ package main
+
+ import (
+ "errors"
+ "fmt"
+ "os"
+ "time"
+
+ "github.com/robertkrimen/otto"
+ )
+
+ var halt = errors.New("Stahp")
+
+ func main() {
+ runUnsafe(`var abc = [];`)
+ runUnsafe(`
+ while (true) {
+ // Loop forever
+ }`)
+ }
+
+ func runUnsafe(unsafe string) {
+ start := time.Now()
+ defer func() {
+ duration := time.Since(start)
+ if caught := recover(); caught != nil {
+ if caught == halt {
+ fmt.Fprintf(os.Stderr, "Some code took to long! Stopping after: %v\n", duration)
+ return
+ }
+ panic(caught) // Something else happened, repanic!
+ }
+ fmt.Fprintf(os.Stderr, "Ran code successfully: %v\n", duration)
+ }()
+
+ vm := otto.New()
+ vm.Interrupt = make(chan func(), 1) // The buffer prevents blocking
+
+ go func() {
+ time.Sleep(2 * time.Second) // Stop after two seconds
+ vm.Interrupt <- func() {
+ panic(halt)
+ }
+ }()
+
+ vm.Run(unsafe) // Here be dragons (risky code)
+ }
+
+Where is setTimeout/setInterval?
+
+These timing functions are not actually part of the ECMA-262 specification.
+Typically, they belong to the `windows` object (in the browser). It would not be
+difficult to provide something like these via Go, but you probably want to wrap
+otto in an event loop in that case.
+
+For an example of how this could be done in Go with otto, see natto:
+
+http://github.com/robertkrimen/natto
+
+Here is some more discussion of the issue:
+
+* http://book.mixu.net/node/ch2.html
+
+* http://en.wikipedia.org/wiki/Reentrancy_%28computing%29
+
+* http://aaroncrane.co.uk/2009/02/perl_safe_signals/
+
+## Usage
+
+```go
+var ErrVersion = errors.New("version mismatch")
+```
+
+#### type Error
+
+```go
+type Error struct {
+}
+```
+
+An Error represents a runtime error, e.g. a TypeError, a ReferenceError, etc.
+
+#### func (Error) Error
+
+```go
+func (err Error) Error() string
+```
+Error returns a description of the error
+
+ TypeError: 'def' is not a function
+
+#### func (Error) String
+
+```go
+func (err Error) String() string
+```
+String returns a description of the error and a trace of where the error
+occurred.
+
+ TypeError: 'def' is not a function
+ at xyz (<anonymous>:3:9)
+ at <anonymous>:7:1/
+
+#### type FunctionCall
+
+```go
+type FunctionCall struct {
+ This Value
+ ArgumentList []Value
+ Otto *Otto
+}
+```
+
+FunctionCall is an encapsulation of a JavaScript function call.
+
+#### func (FunctionCall) Argument
+
+```go
+func (self FunctionCall) Argument(index int) Value
+```
+Argument will return the value of the argument at the given index.
+
+If no such argument exists, undefined is returned.
+
+#### type Object
+
+```go
+type Object struct {
+}
+```
+
+Object is the representation of a JavaScript object.
+
+#### func (Object) Call
+
+```go
+func (self Object) Call(name string, argumentList ...interface{}) (Value, error)
+```
+Call a method on the object.
+
+It is essentially equivalent to:
+
+ var method, _ := object.Get(name)
+ method.Call(object, argumentList...)
+
+An undefined value and an error will result if:
+
+ 1. There is an error during conversion of the argument list
+ 2. The property is not actually a function
+ 3. An (uncaught) exception is thrown
+
+#### func (Object) Class
+
+```go
+func (self Object) Class() string
+```
+Class will return the class string of the object.
+
+The return value will (generally) be one of:
+
+ Object
+ Function
+ Array
+ String
+ Number
+ Boolean
+ Date
+ RegExp
+
+#### func (Object) Get
+
+```go
+func (self Object) Get(name string) (Value, error)
+```
+Get the value of the property with the given name.
+
+#### func (Object) Keys
+
+```go
+func (self Object) Keys() []string
+```
+Get the keys for the object
+
+Equivalent to calling Object.keys on the object
+
+#### func (Object) Set
+
+```go
+func (self Object) Set(name string, value interface{}) error
+```
+Set the property of the given name to the given value.
+
+An error will result if the setting the property triggers an exception (i.e.
+read-only), or there is an error during conversion of the given value.
+
+#### func (Object) Value
+
+```go
+func (self Object) Value() Value
+```
+Value will return self as a value.
+
+#### type Otto
+
+```go
+type Otto struct {
+ // Interrupt is a channel for interrupting the runtime. You can use this to halt a long running execution, for example.
+ // See "Halting Problem" for more information.
+ Interrupt chan func()
+}
+```
+
+Otto is the representation of the JavaScript runtime. Each instance of Otto has
+a self-contained namespace.
+
+#### func New
+
+```go
+func New() *Otto
+```
+New will allocate a new JavaScript runtime
+
+#### func Run
+
+```go
+func Run(src interface{}) (*Otto, Value, error)
+```
+Run will allocate a new JavaScript runtime, run the given source on the
+allocated runtime, and return the runtime, resulting value, and error (if any).
+
+src may be a string, a byte slice, a bytes.Buffer, or an io.Reader, but it MUST
+always be in UTF-8.
+
+src may also be a Script.
+
+src may also be a Program, but if the AST has been modified, then runtime
+behavior is undefined.
+
+#### func (Otto) Call
+
+```go
+func (self Otto) Call(source string, this interface{}, argumentList ...interface{}) (Value, error)
+```
+Call the given JavaScript with a given this and arguments.
+
+If this is nil, then some special handling takes place to determine the proper
+this value, falling back to a "standard" invocation if necessary (where this is
+undefined).
+
+If source begins with "new " (A lowercase new followed by a space), then Call
+will invoke the function constructor rather than performing a function call. In
+this case, the this argument has no effect.
+
+ // value is a String object
+ value, _ := vm.Call("Object", nil, "Hello, World.")
+
+ // Likewise...
+ value, _ := vm.Call("new Object", nil, "Hello, World.")
+
+ // This will perform a concat on the given array and return the result
+ // value is [ 1, 2, 3, undefined, 4, 5, 6, 7, "abc" ]
+ value, _ := vm.Call(`[ 1, 2, 3, undefined, 4 ].concat`, nil, 5, 6, 7, "abc")
+
+#### func (*Otto) Compile
+
+```go
+func (self *Otto) Compile(filename string, src interface{}) (*Script, error)
+```
+Compile will parse the given source and return a Script value or nil and an
+error if there was a problem during compilation.
+
+ script, err := vm.Compile("", `var abc; if (!abc) abc = 0; abc += 2; abc;`)
+ vm.Run(script)
+
+#### func (*Otto) Copy
+
+```go
+func (in *Otto) Copy() *Otto
+```
+Copy will create a copy/clone of the runtime.
+
+Copy is useful for saving some time when creating many similar runtimes.
+
+This method works by walking the original runtime and cloning each object,
+scope, stash, etc. into a new runtime.
+
+Be on the lookout for memory leaks or inadvertent sharing of resources.
+
+#### func (Otto) Get
+
+```go
+func (self Otto) Get(name string) (Value, error)
+```
+Get the value of the top-level binding of the given name.
+
+If there is an error (like the binding does not exist), then the value will be
+undefined.
+
+#### func (Otto) Object
+
+```go
+func (self Otto) Object(source string) (*Object, error)
+```
+Object will run the given source and return the result as an object.
+
+For example, accessing an existing object:
+
+ object, _ := vm.Object(`Number`)
+
+Or, creating a new object:
+
+ object, _ := vm.Object(`({ xyzzy: "Nothing happens." })`)
+
+Or, creating and assigning an object:
+
+ object, _ := vm.Object(`xyzzy = {}`)
+ object.Set("volume", 11)
+
+If there is an error (like the source does not result in an object), then nil
+and an error is returned.
+
+#### func (Otto) Run
+
+```go
+func (self Otto) Run(src interface{}) (Value, error)
+```
+Run will run the given source (parsing it first if necessary), returning the
+resulting value and error (if any)
+
+src may be a string, a byte slice, a bytes.Buffer, or an io.Reader, but it MUST
+always be in UTF-8.
+
+If the runtime is unable to parse source, then this function will return
+undefined and the parse error (nothing will be evaluated in this case).
+
+src may also be a Script.
+
+src may also be a Program, but if the AST has been modified, then runtime
+behavior is undefined.
+
+#### func (Otto) Set
+
+```go
+func (self Otto) Set(name string, value interface{}) error
+```
+Set the top-level binding of the given name to the given value.
+
+Set will automatically apply ToValue to the given value in order to convert it
+to a JavaScript value (type Value).
+
+If there is an error (like the binding is read-only, or the ToValue conversion
+fails), then an error is returned.
+
+If the top-level binding does not exist, it will be created.
+
+#### func (Otto) ToValue
+
+```go
+func (self Otto) ToValue(value interface{}) (Value, error)
+```
+ToValue will convert an interface{} value to a value digestible by
+otto/JavaScript.
+
+#### type Script
+
+```go
+type Script struct {
+}
+```
+
+Script is a handle for some (reusable) JavaScript. Passing a Script value to a
+run method will evaluate the JavaScript.
+
+#### func (*Script) String
+
+```go
+func (self *Script) String() string
+```
+
+#### type Value
+
+```go
+type Value struct {
+}
+```
+
+Value is the representation of a JavaScript value.
+
+#### func FalseValue
+
+```go
+func FalseValue() Value
+```
+FalseValue will return a value representing false.
+
+It is equivalent to:
+
+ ToValue(false)
+
+#### func NaNValue
+
+```go
+func NaNValue() Value
+```
+NaNValue will return a value representing NaN.
+
+It is equivalent to:
+
+ ToValue(math.NaN())
+
+#### func NullValue
+
+```go
+func NullValue() Value
+```
+NullValue will return a Value representing null.
+
+#### func ToValue
+
+```go
+func ToValue(value interface{}) (Value, error)
+```
+ToValue will convert an interface{} value to a value digestible by
+otto/JavaScript
+
+This function will not work for advanced types (struct, map, slice/array, etc.)
+and you should use Otto.ToValue instead.
+
+#### func TrueValue
+
+```go
+func TrueValue() Value
+```
+TrueValue will return a value representing true.
+
+It is equivalent to:
+
+ ToValue(true)
+
+#### func UndefinedValue
+
+```go
+func UndefinedValue() Value
+```
+UndefinedValue will return a Value representing undefined.
+
+#### func (Value) Call
+
+```go
+func (value Value) Call(this Value, argumentList ...interface{}) (Value, error)
+```
+Call the value as a function with the given this value and argument list and
+return the result of invocation. It is essentially equivalent to:
+
+ value.apply(thisValue, argumentList)
+
+An undefined value and an error will result if:
+
+ 1. There is an error during conversion of the argument list
+ 2. The value is not actually a function
+ 3. An (uncaught) exception is thrown
+
+#### func (Value) Class
+
+```go
+func (value Value) Class() string
+```
+Class will return the class string of the value or the empty string if value is
+not an object.
+
+The return value will (generally) be one of:
+
+ Object
+ Function
+ Array
+ String
+ Number
+ Boolean
+ Date
+ RegExp
+
+#### func (Value) Export
+
+```go
+func (self Value) Export() (interface{}, error)
+```
+Export will attempt to convert the value to a Go representation and return it
+via an interface{} kind.
+
+Export returns an error, but it will always be nil. It is present for backwards
+compatibility.
+
+If a reasonable conversion is not possible, then the original value is returned.
+
+ undefined -> nil (FIXME?: Should be Value{})
+ null -> nil
+ boolean -> bool
+ number -> A number type (int, float32, uint64, ...)
+ string -> string
+ Array -> []interface{}
+ Object -> map[string]interface{}
+
+#### func (Value) IsBoolean
+
+```go
+func (value Value) IsBoolean() bool
+```
+IsBoolean will return true if value is a boolean (primitive).
+
+#### func (Value) IsDefined
+
+```go
+func (value Value) IsDefined() bool
+```
+IsDefined will return false if the value is undefined, and true otherwise.
+
+#### func (Value) IsFunction
+
+```go
+func (value Value) IsFunction() bool
+```
+IsFunction will return true if value is a function.
+
+#### func (Value) IsNaN
+
+```go
+func (value Value) IsNaN() bool
+```
+IsNaN will return true if value is NaN (or would convert to NaN).
+
+#### func (Value) IsNull
+
+```go
+func (value Value) IsNull() bool
+```
+IsNull will return true if the value is null, and false otherwise.
+
+#### func (Value) IsNumber
+
+```go
+func (value Value) IsNumber() bool
+```
+IsNumber will return true if value is a number (primitive).
+
+#### func (Value) IsObject
+
+```go
+func (value Value) IsObject() bool
+```
+IsObject will return true if value is an object.
+
+#### func (Value) IsPrimitive
+
+```go
+func (value Value) IsPrimitive() bool
+```
+IsPrimitive will return true if value is a primitive (any kind of primitive).
+
+#### func (Value) IsString
+
+```go
+func (value Value) IsString() bool
+```
+IsString will return true if value is a string (primitive).
+
+#### func (Value) IsUndefined
+
+```go
+func (value Value) IsUndefined() bool
+```
+IsUndefined will return true if the value is undefined, and false otherwise.
+
+#### func (Value) Object
+
+```go
+func (value Value) Object() *Object
+```
+Object will return the object of the value, or nil if value is not an object.
+
+This method will not do any implicit conversion. For example, calling this
+method on a string primitive value will not return a String object.
+
+#### func (Value) String
+
+```go
+func (value Value) String() string
+```
+String will return the value as a string.
+
+This method will make return the empty string if there is an error.
+
+#### func (Value) ToBoolean
+
+```go
+func (value Value) ToBoolean() (bool, error)
+```
+ToBoolean will convert the value to a boolean (bool).
+
+ ToValue(0).ToBoolean() => false
+ ToValue("").ToBoolean() => false
+ ToValue(true).ToBoolean() => true
+ ToValue(1).ToBoolean() => true
+ ToValue("Nothing happens").ToBoolean() => true
+
+If there is an error during the conversion process (like an uncaught exception),
+then the result will be false and an error.
+
+#### func (Value) ToFloat
+
+```go
+func (value Value) ToFloat() (float64, error)
+```
+ToFloat will convert the value to a number (float64).
+
+ ToValue(0).ToFloat() => 0.
+ ToValue(1.1).ToFloat() => 1.1
+ ToValue("11").ToFloat() => 11.
+
+If there is an error during the conversion process (like an uncaught exception),
+then the result will be 0 and an error.
+
+#### func (Value) ToInteger
+
+```go
+func (value Value) ToInteger() (int64, error)
+```
+ToInteger will convert the value to a number (int64).
+
+ ToValue(0).ToInteger() => 0
+ ToValue(1.1).ToInteger() => 1
+ ToValue("11").ToInteger() => 11
+
+If there is an error during the conversion process (like an uncaught exception),
+then the result will be 0 and an error.
+
+#### func (Value) ToString
+
+```go
+func (value Value) ToString() (string, error)
+```
+ToString will convert the value to a string (string).
+
+ ToValue(0).ToString() => "0"
+ ToValue(false).ToString() => "false"
+ ToValue(1.1).ToString() => "1.1"
+ ToValue("11").ToString() => "11"
+ ToValue('Nothing happens.').ToString() => "Nothing happens."
+
+If there is an error during the conversion process (like an uncaught exception),
+then the result will be the empty string ("") and an error.
+
+--
+**godocdown** http://github.com/robertkrimen/godocdown
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/array_test.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/array_test.go
new file mode 100644
index 000000000..06f481bd4
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/array_test.go
@@ -0,0 +1,716 @@
+package otto
+
+import (
+ "testing"
+)
+
+func TestArray(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ var abc = [ undefined, "Nothing happens." ];
+ abc.length;
+ `, 2)
+
+ test(`
+ abc = ""+[0, 1, 2, 3];
+ def = [].toString();
+ ghi = [null, 4, "null"].toString();
+ [ abc, def, ghi ];
+ `, "0,1,2,3,,,4,null")
+
+ test(`new Array(0).length`, 0)
+
+ test(`new Array(11).length`, 11)
+
+ test(`new Array(11, 1).length`, 2)
+
+ test(`
+ abc = [0, 1, 2, 3];
+ abc.xyzzy = "Nothing happens.";
+ delete abc[1];
+ var xyzzy = delete abc.xyzzy;
+ [ abc, xyzzy, abc.xyzzy ];
+ `, "0,,2,3,true,")
+
+ test(`
+ var abc = [0, 1, 2, 3, 4];
+ abc.length = 2;
+ abc;
+ `, "0,1")
+
+ test(`raise:
+ [].length = 3.14159;
+ `, "RangeError")
+
+ test(`raise:
+ new Array(3.14159);
+ `, "RangeError")
+
+ test(`
+ Object.defineProperty(Array.prototype, "0", {
+ value: 100,
+ writable: false,
+ configurable: true
+ });
+ abc = [101];
+ abc.hasOwnProperty("0") && abc[0] === 101;
+ `, true)
+
+ test(`
+ abc = [,,undefined];
+ [ abc.hasOwnProperty(0), abc.hasOwnProperty(1), abc.hasOwnProperty(2) ];
+ `, "false,false,true")
+
+ test(`
+ abc = Object.getOwnPropertyDescriptor(Array, "prototype");
+ [ [ typeof Array.prototype ],
+ [ abc.writable, abc.enumerable, abc.configurable ] ];
+ `, "object,false,false,false")
+ })
+}
+
+func TestArray_toString(t *testing.T) {
+ tt(t, func() {
+ {
+ test(`
+ Array.prototype.toString = function() {
+ return "Nothing happens.";
+ }
+ abc = Array.prototype.toString();
+ def = [].toString();
+ ghi = [null, 4, "null"].toString();
+
+ [ abc, def, ghi ].join(",");
+ `, "Nothing happens.,Nothing happens.,Nothing happens.")
+ }
+
+ {
+ test(`
+ Array.prototype.join = undefined
+ abc = Array.prototype.toString()
+ def = [].toString()
+ ghi = [null, 4, "null"].toString()
+
+ abc + "," + def + "," + ghi;
+ `, "[object Array],[object Array],[object Array]")
+ }
+ })
+}
+
+func TestArray_toLocaleString(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ defer mockUTC()()
+
+ test(`
+ [ 3.14159, "abc", undefined, new Date(0) ].toLocaleString();
+ `, "3.14159,abc,,1970-01-01 00:00:00")
+
+ test(`raise:
+ [ { toLocaleString: undefined } ].toLocaleString();
+ `, "TypeError")
+ })
+}
+
+func TestArray_concat(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ abc = [0, 1, 2];
+ def = [-1, -2, -3];
+ ghi = abc.concat(def);
+ jkl = abc.concat(def, 3, 4, 5);
+ mno = def.concat(-4, -5, abc);
+
+ [ ghi, jkl, mno ].join(";");
+ `, "0,1,2,-1,-2,-3;0,1,2,-1,-2,-3,3,4,5;-1,-2,-3,-4,-5,0,1,2")
+
+ test(`
+ var abc = [,1];
+ var def = abc.concat([], [,]);
+
+ def.getClass = Object.prototype.toString;
+
+ [ def.getClass(), typeof def[0], def[1], typeof def[2], def.length ];
+ `, "[object Array],undefined,1,undefined,3")
+
+ test(`
+ Object.defineProperty(Array.prototype, "0", {
+ value: 100,
+ writable: false,
+ configurable: true
+ });
+
+ var abc = Array.prototype.concat.call(101);
+
+ var hasProperty = abc.hasOwnProperty("0");
+ var instanceOfVerify = typeof abc[0] === "object";
+ var verifyValue = false;
+ verifyValue = abc[0] == 101;
+
+ var verifyEnumerable = false;
+ for (var property in abc) {
+ if (property === "0" && abc.hasOwnProperty("0")) {
+ verifyEnumerable = true;
+ }
+ }
+
+ var verifyWritable = false;
+ abc[0] = 12;
+ verifyWritable = abc[0] === 12;
+
+ var verifyConfigurable = false;
+ delete abc[0];
+ verifyConfigurable = abc.hasOwnProperty("0");
+
+ [ hasProperty, instanceOfVerify, verifyValue, !verifyConfigurable, verifyEnumerable, verifyWritable ];
+ `, "true,true,true,true,true,true")
+ })
+}
+
+func TestArray_splice(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ abc = [0, 1, 2];
+ def = abc.splice(1, 2, 3, 4, 5);
+ ghi = [].concat(abc);
+ jkl = ghi.splice(17, 21, 7, 8, 9);
+ [ abc, def, ghi, jkl ].join(";");
+ `, "0,3,4,5;1,2;0,3,4,5,7,8,9;")
+ })
+}
+
+func TestArray_shift(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ abc = [0, 1, 2];
+ def = abc.shift();
+ ghi = [].concat(abc);
+ jkl = abc.shift();
+ mno = [].concat(abc);
+ pqr = abc.shift();
+ stu = [].concat(abc);
+ vwx = abc.shift();
+
+ [ abc, def, ghi, jkl, mno, pqr, stu, vwx ].join(";");
+ `, ";0;1,2;1;2;2;;")
+ })
+}
+
+func TestArray_push(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ abc = [0];
+ def = abc.push(1);
+ ghi = [].concat(abc);
+ jkl = abc.push(2,3,4);
+
+ [ abc, def, ghi, jkl ].join(";");
+ `, "0,1,2,3,4;2;0,1;5")
+ })
+}
+
+func TestArray_pop(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ abc = [0,1];
+ def = abc.pop();
+ ghi = [].concat(abc);
+ jkl = abc.pop();
+ mno = [].concat(abc);
+ pqr = abc.pop();
+
+ [ abc, def, ghi, jkl, mno, pqr ].join(";");
+ `, ";1;0;0;;")
+ })
+}
+
+func TestArray_slice(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ abc = [0,1,2,3];
+ def = abc.slice();
+ ghi = abc.slice(1);
+ jkl = abc.slice(3,-1);
+ mno = abc.slice(2,-1);
+ pqr = abc.slice(-1, -10);
+
+ [ abc, def, ghi, jkl, mno, pqr ].join(";");
+ `, "0,1,2,3;0,1,2,3;1,2,3;;2;")
+
+ // Array.protoype.slice is generic
+ test(`
+ abc = { 0: 0, 1: 1, 2: 2, 3: 3 };
+ abc.length = 4;
+ def = Array.prototype.slice.call(abc);
+ ghi = Array.prototype.slice.call(abc,1);
+ jkl = Array.prototype.slice.call(abc,3,-1);
+ mno = Array.prototype.slice.call(abc,2,-1);
+ pqr = Array.prototype.slice.call(abc,-1,-10);
+
+ [ abc, def, ghi, jkl, pqr ].join(";");
+ `, "[object Object];0,1,2,3;1,2,3;;")
+ })
+}
+
+func TestArray_sliceArguments(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ (function(){
+ return Array.prototype.slice.call(arguments, 1)
+ })({}, 1, 2, 3);
+ `, "1,2,3")
+ })
+}
+
+func TestArray_unshift(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ abc = [];
+ def = abc.unshift(0);
+ ghi = [].concat(abc);
+ jkl = abc.unshift(1,2,3,4);
+
+ [ abc, def, ghi, jkl ].join(";");
+ `, "1,2,3,4,0;1;0;5")
+ })
+}
+
+func TestArray_reverse(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ abc = [0,1,2,3].reverse();
+ def = [0,1,2].reverse();
+
+ [ abc, def ];
+ `, "3,2,1,0,2,1,0")
+ })
+}
+
+func TestArray_sort(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ abc = [0,1,2,3].sort();
+ def = [3,2,1,0].sort();
+ ghi = [].sort();
+ jkl = [0].sort();
+ mno = [1,0].sort();
+ pqr = [1,5,-10, 100, 8, 72, 401, 0.05].sort();
+ stu = [1,5,-10, 100, 8, 72, 401, 0.05].sort(function(x, y){
+ return x == y ? 0 : x < y ? -1 : 1
+ });
+
+ [ abc, def, ghi, jkl, mno, pqr, stu ].join(";");
+ `, "0,1,2,3;0,1,2,3;;0;0,1;-10,0.05,1,100,401,5,72,8;-10,0.05,1,5,8,72,100,401")
+
+ test(`Array.prototype.sort.length`, 1)
+ })
+}
+
+func TestArray_isArray(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ [ Array.isArray.length, Array.isArray(), Array.isArray([]), Array.isArray({}) ];
+ `, "1,false,true,false")
+
+ test(`Array.isArray(Math)`, false)
+ })
+}
+
+func TestArray_indexOf(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`['a', 'b', 'c', 'b'].indexOf('b')`, 1)
+
+ test(`['a', 'b', 'c', 'b'].indexOf('b', 2)`, 3)
+
+ test(`['a', 'b', 'c', 'b'].indexOf('b', -2)`, 3)
+
+ test(`
+ Object.prototype.indexOf = Array.prototype.indexOf;
+ var abc = {0: 'a', 1: 'b', 2: 'c', length: 3};
+ abc.indexOf('c');
+ `, 2)
+
+ test(`[true].indexOf(true, "-Infinity")`, 0)
+
+ test(`
+ var target = {};
+ Math[3] = target;
+ Math.length = 5;
+ Array.prototype.indexOf.call(Math, target) === 3;
+ `, true)
+
+ test(`
+ var _NaN = NaN;
+ var abc = new Array("NaN", undefined, 0, false, null, {toString:function(){return NaN}}, "false", _NaN, NaN);
+ abc.indexOf(NaN);
+ `, -1)
+
+ test(`
+ var abc = {toString:function (){return 0}};
+ var def = 1;
+ var ghi = -(4/3);
+ var jkl = new Array(false, undefined, null, "0", abc, -1.3333333333333, "string", -0, true, +0, def, 1, 0, false, ghi, -(4/3));
+ [ jkl.indexOf(-(4/3)), jkl.indexOf(0), jkl.indexOf(-0), jkl.indexOf(1) ];
+ `, "14,7,7,10")
+ })
+}
+
+func TestArray_lastIndexOf(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`['a', 'b', 'c', 'b'].lastIndexOf('b')`, 3)
+
+ test(`['a', 'b', 'c', 'b'].lastIndexOf('b', 2)`, 1)
+
+ test(`['a', 'b', 'c', 'b'].lastIndexOf('b', -2)`, 1)
+
+ test(`
+ Object.prototype.lastIndexOf = Array.prototype.lastIndexOf;
+ var abc = {0: 'a', 1: 'b', 2: 'c', 3: 'b', length: 4};
+ abc.lastIndexOf('b');
+ `, 3)
+
+ test(`
+ var target = {};
+ Math[3] = target;
+ Math.length = 5;
+ [ Array.prototype.lastIndexOf.call(Math, target) === 3 ];
+ `, "true")
+
+ test(`
+ var _NaN = NaN;
+ var abc = new Array("NaN", undefined, 0, false, null, {toString:function(){return NaN}}, "false", _NaN, NaN);
+ abc.lastIndexOf(NaN);
+ `, -1)
+
+ test(`
+ var abc = {toString:function (){return 0}};
+ var def = 1;
+ var ghi = -(4/3);
+ var jkl = new Array(false, undefined, null, "0", abc, -1.3333333333333, "string", -0, true, +0, def, 1, 0, false, ghi, -(4/3));
+ [ jkl.lastIndexOf(-(4/3)), jkl.indexOf(0), jkl.indexOf(-0), jkl.indexOf(1) ];
+ `, "15,7,7,10")
+ })
+}
+
+func TestArray_every(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`raise: [].every()`, "TypeError")
+
+ test(`raise: [].every("abc")`, "TypeError")
+
+ test(`[].every(function() { return false })`, true)
+
+ test(`[1,2,3].every(function() { return false })`, false)
+
+ test(`[1,2,3].every(function() { return true })`, true)
+
+ test(`[1,2,3].every(function(_, index) { if (index === 1) return true })`, false)
+
+ test(`
+ var abc = function(value, index, object) {
+ return ('[object Math]' !== Object.prototype.toString.call(object));
+ };
+
+ Math.length = 1;
+ Math[0] = 1;
+ !Array.prototype.every.call(Math, abc);
+ `, true)
+
+ test(`
+ var def = false;
+
+ var abc = function(value, index, object) {
+ def = true;
+ return this === Math;
+ };
+
+ [11].every(abc, Math) && def;
+ `, true)
+
+ test(`
+ var def = false;
+
+ var abc = function(value, index, object) {
+ def = true;
+ return Math;
+ };
+
+ [11].every(abc) && def;
+ `, true)
+ })
+}
+
+func TestArray_some(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`raise: [].some("abc")`, "TypeError")
+
+ test(`[].some(function() { return true })`, false)
+
+ test(`[1,2,3].some(function() { return false })`, false)
+
+ test(`[1,2,3].some(function() { return true })`, true)
+
+ test(`[1,2,3].some(function(_, index) { if (index === 1) return true })`, true)
+
+ test(`
+ var abc = function(value, index, object) {
+ return ('[object Math]' !== Object.prototype.toString.call(object));
+ };
+
+ Math.length = 1;
+ Math[0] = 1;
+ !Array.prototype.some.call(Math, abc);
+ `, true)
+
+ test(`
+ var abc = function(value, index, object) {
+ return this === Math;
+ };
+
+ [11].some(abc, Math);
+ `, true)
+
+ test(`
+ var abc = function(value, index, object) {
+ return Math;
+ };
+
+ [11].some(abc);
+ `, true)
+ })
+}
+
+func TestArray_forEach(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`raise: [].forEach("abc")`, "TypeError")
+
+ test(`
+ var abc = 0;
+ [].forEach(function(value) {
+ abc += value;
+ });
+ abc;
+ `, 0)
+
+ test(`
+ abc = 0;
+ var def = [];
+ [1,2,3].forEach(function(value, index) {
+ abc += value;
+ def.push(index);
+ });
+ [ abc, def ];
+ `, "6,0,1,2")
+
+ test(`
+ var def = false;
+ var abc = function(value, index, object) {
+ def = ('[object Math]' === Object.prototype.toString.call(object));
+ };
+
+ Math.length = 1;
+ Math[0] = 1;
+ Array.prototype.forEach.call(Math, abc);
+ def;
+ `, true)
+
+ test(`
+ var def = false;
+ var abc = function(value, index, object) {
+ def = this === Math;
+ };
+
+ [11].forEach(abc, Math);
+ def;
+ `, true)
+ })
+}
+
+func TestArray_indexing(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ var abc = new Array(0, 1);
+ var def = abc.length;
+ abc[4294967296] = 10; // 2^32 => 0
+ abc[4294967297] = 11; // 2^32+1 => 1
+ [ def, abc.length, abc[0], abc[1], abc[4294967296] ];
+ `, "2,2,0,1,10")
+
+ test(`
+ abc = new Array(0, 1);
+ def = abc.length;
+ abc[4294967295] = 10;
+ var ghi = abc.length;
+ abc[4294967299] = 12;
+ var jkl = abc.length;
+ abc[4294967294] = 11;
+ [ def, ghi, jkl, abc.length, abc[4294967295], abc[4294967299] ];
+ `, "2,2,2,4294967295,10,12")
+ })
+}
+
+func TestArray_map(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`raise: [].map("abc")`, "TypeError")
+
+ test(`[].map(function() { return 1 }).length`, 0)
+
+ test(`[1,2,3].map(function(value) { return value * value })`, "1,4,9")
+
+ test(`[1,2,3].map(function(value) { return 1 })`, "1,1,1")
+
+ test(`
+ var abc = function(value, index, object) {
+ return ('[object Math]' === Object.prototype.toString.call(object));
+ };
+
+ Math.length = 1;
+ Math[0] = 1;
+ Array.prototype.map.call(Math, abc)[0];
+ `, true)
+
+ test(`
+ var abc = function(value, index, object) {
+ return this === Math;
+ };
+
+ [11].map(abc, Math)[0];
+ `, true)
+ })
+}
+
+func TestArray_filter(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`raise: [].filter("abc")`, "TypeError")
+
+ test(`[].filter(function() { return 1 }).length`, 0)
+
+ test(`[1,2,3].filter(function() { return false }).length`, 0)
+
+ test(`[1,2,3].filter(function() { return true })`, "1,2,3")
+ })
+}
+
+func TestArray_reduce(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`raise: [].reduce("abc")`, "TypeError")
+
+ test(`raise: [].reduce(function() {})`, "TypeError")
+
+ test(`[].reduce(function() {}, 0)`, 0)
+
+ test(`[].reduce(function() {}, undefined)`, "undefined")
+
+ test(`['a','b','c'].reduce(function(result, value) { return result+', '+value })`, "a, b, c")
+
+ test(`[1,2,3].reduce(function(result, value) { return result + value }, 4)`, 10)
+
+ test(`[1,2,3].reduce(function(result, value) { return result + value })`, 6)
+ })
+}
+
+func TestArray_reduceRight(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`raise: [].reduceRight("abc")`, "TypeError")
+
+ test(`raise: [].reduceRight(function() {})`, "TypeError")
+
+ test(`[].reduceRight(function() {}, 0)`, 0)
+
+ test(`[].reduceRight(function() {}, undefined)`, "undefined")
+
+ test(`['a','b','c'].reduceRight(function(result, value) { return result+', '+value })`, "c, b, a")
+
+ test(`[1,2,3].reduceRight(function(result, value) { return result + value }, 4)`, 10)
+
+ test(`[1,2,3].reduceRight(function(result, value) { return result + value })`, 6)
+ })
+}
+
+func TestArray_defineOwnProperty(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ var abc = [];
+ Object.defineProperty(abc, "length", {
+ writable: false
+ });
+ abc.length;
+ `, 0)
+
+ test(`raise:
+ var abc = [];
+ var exception;
+ Object.defineProperty(abc, "length", {
+ writable: false
+ });
+ Object.defineProperty(abc, "length", {
+ writable: true
+ });
+ `, "TypeError")
+ })
+}
+
+func TestArray_new(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ var abc = new Array(null);
+ var def = new Array(undefined);
+ [ abc.length, abc[0] === null, def.length, def[0] === undefined ]
+ `, "1,true,1,true")
+
+ test(`
+ var abc = new Array(new Number(0));
+ var def = new Array(new Number(4294967295));
+ [ abc.length, typeof abc[0], abc[0] == 0, def.length, typeof def[0], def[0] == 4294967295 ]
+ `, "1,object,true,1,object,true")
+ })
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/ast/README.markdown b/Godeps/_workspace/src/github.com/robertkrimen/otto/ast/README.markdown
new file mode 100644
index 000000000..a785da911
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/ast/README.markdown
@@ -0,0 +1,1068 @@
+# ast
+--
+ import "github.com/robertkrimen/otto/ast"
+
+Package ast declares types representing a JavaScript AST.
+
+
+### Warning
+
+The parser and AST interfaces are still works-in-progress (particularly where
+node types are concerned) and may change in the future.
+
+## Usage
+
+#### type ArrayLiteral
+
+```go
+type ArrayLiteral struct {
+ LeftBracket file.Idx
+ RightBracket file.Idx
+ Value []Expression
+}
+```
+
+
+#### func (*ArrayLiteral) Idx0
+
+```go
+func (self *ArrayLiteral) Idx0() file.Idx
+```
+
+#### func (*ArrayLiteral) Idx1
+
+```go
+func (self *ArrayLiteral) Idx1() file.Idx
+```
+
+#### type AssignExpression
+
+```go
+type AssignExpression struct {
+ Operator token.Token
+ Left Expression
+ Right Expression
+}
+```
+
+
+#### func (*AssignExpression) Idx0
+
+```go
+func (self *AssignExpression) Idx0() file.Idx
+```
+
+#### func (*AssignExpression) Idx1
+
+```go
+func (self *AssignExpression) Idx1() file.Idx
+```
+
+#### type BadExpression
+
+```go
+type BadExpression struct {
+ From file.Idx
+ To file.Idx
+}
+```
+
+
+#### func (*BadExpression) Idx0
+
+```go
+func (self *BadExpression) Idx0() file.Idx
+```
+
+#### func (*BadExpression) Idx1
+
+```go
+func (self *BadExpression) Idx1() file.Idx
+```
+
+#### type BadStatement
+
+```go
+type BadStatement struct {
+ From file.Idx
+ To file.Idx
+}
+```
+
+
+#### func (*BadStatement) Idx0
+
+```go
+func (self *BadStatement) Idx0() file.Idx
+```
+
+#### func (*BadStatement) Idx1
+
+```go
+func (self *BadStatement) Idx1() file.Idx
+```
+
+#### type BinaryExpression
+
+```go
+type BinaryExpression struct {
+ Operator token.Token
+ Left Expression
+ Right Expression
+ Comparison bool
+}
+```
+
+
+#### func (*BinaryExpression) Idx0
+
+```go
+func (self *BinaryExpression) Idx0() file.Idx
+```
+
+#### func (*BinaryExpression) Idx1
+
+```go
+func (self *BinaryExpression) Idx1() file.Idx
+```
+
+#### type BlockStatement
+
+```go
+type BlockStatement struct {
+ LeftBrace file.Idx
+ List []Statement
+ RightBrace file.Idx
+}
+```
+
+
+#### func (*BlockStatement) Idx0
+
+```go
+func (self *BlockStatement) Idx0() file.Idx
+```
+
+#### func (*BlockStatement) Idx1
+
+```go
+func (self *BlockStatement) Idx1() file.Idx
+```
+
+#### type BooleanLiteral
+
+```go
+type BooleanLiteral struct {
+ Idx file.Idx
+ Literal string
+ Value bool
+}
+```
+
+
+#### func (*BooleanLiteral) Idx0
+
+```go
+func (self *BooleanLiteral) Idx0() file.Idx
+```
+
+#### func (*BooleanLiteral) Idx1
+
+```go
+func (self *BooleanLiteral) Idx1() file.Idx
+```
+
+#### type BracketExpression
+
+```go
+type BracketExpression struct {
+ Left Expression
+ Member Expression
+ LeftBracket file.Idx
+ RightBracket file.Idx
+}
+```
+
+
+#### func (*BracketExpression) Idx0
+
+```go
+func (self *BracketExpression) Idx0() file.Idx
+```
+
+#### func (*BracketExpression) Idx1
+
+```go
+func (self *BracketExpression) Idx1() file.Idx
+```
+
+#### type BranchStatement
+
+```go
+type BranchStatement struct {
+ Idx file.Idx
+ Token token.Token
+ Label *Identifier
+}
+```
+
+
+#### func (*BranchStatement) Idx0
+
+```go
+func (self *BranchStatement) Idx0() file.Idx
+```
+
+#### func (*BranchStatement) Idx1
+
+```go
+func (self *BranchStatement) Idx1() file.Idx
+```
+
+#### type CallExpression
+
+```go
+type CallExpression struct {
+ Callee Expression
+ LeftParenthesis file.Idx
+ ArgumentList []Expression
+ RightParenthesis file.Idx
+}
+```
+
+
+#### func (*CallExpression) Idx0
+
+```go
+func (self *CallExpression) Idx0() file.Idx
+```
+
+#### func (*CallExpression) Idx1
+
+```go
+func (self *CallExpression) Idx1() file.Idx
+```
+
+#### type CaseStatement
+
+```go
+type CaseStatement struct {
+ Case file.Idx
+ Test Expression
+ Consequent []Statement
+}
+```
+
+
+#### func (*CaseStatement) Idx0
+
+```go
+func (self *CaseStatement) Idx0() file.Idx
+```
+
+#### func (*CaseStatement) Idx1
+
+```go
+func (self *CaseStatement) Idx1() file.Idx
+```
+
+#### type CatchStatement
+
+```go
+type CatchStatement struct {
+ Catch file.Idx
+ Parameter *Identifier
+ Body Statement
+}
+```
+
+
+#### func (*CatchStatement) Idx0
+
+```go
+func (self *CatchStatement) Idx0() file.Idx
+```
+
+#### func (*CatchStatement) Idx1
+
+```go
+func (self *CatchStatement) Idx1() file.Idx
+```
+
+#### type ConditionalExpression
+
+```go
+type ConditionalExpression struct {
+ Test Expression
+ Consequent Expression
+ Alternate Expression
+}
+```
+
+
+#### func (*ConditionalExpression) Idx0
+
+```go
+func (self *ConditionalExpression) Idx0() file.Idx
+```
+
+#### func (*ConditionalExpression) Idx1
+
+```go
+func (self *ConditionalExpression) Idx1() file.Idx
+```
+
+#### type DebuggerStatement
+
+```go
+type DebuggerStatement struct {
+ Debugger file.Idx
+}
+```
+
+
+#### func (*DebuggerStatement) Idx0
+
+```go
+func (self *DebuggerStatement) Idx0() file.Idx
+```
+
+#### func (*DebuggerStatement) Idx1
+
+```go
+func (self *DebuggerStatement) Idx1() file.Idx
+```
+
+#### type Declaration
+
+```go
+type Declaration interface {
+ // contains filtered or unexported methods
+}
+```
+
+All declaration nodes implement the Declaration interface.
+
+#### type DoWhileStatement
+
+```go
+type DoWhileStatement struct {
+ Do file.Idx
+ Test Expression
+ Body Statement
+}
+```
+
+
+#### func (*DoWhileStatement) Idx0
+
+```go
+func (self *DoWhileStatement) Idx0() file.Idx
+```
+
+#### func (*DoWhileStatement) Idx1
+
+```go
+func (self *DoWhileStatement) Idx1() file.Idx
+```
+
+#### type DotExpression
+
+```go
+type DotExpression struct {
+ Left Expression
+ Identifier Identifier
+}
+```
+
+
+#### func (*DotExpression) Idx0
+
+```go
+func (self *DotExpression) Idx0() file.Idx
+```
+
+#### func (*DotExpression) Idx1
+
+```go
+func (self *DotExpression) Idx1() file.Idx
+```
+
+#### type EmptyStatement
+
+```go
+type EmptyStatement struct {
+ Semicolon file.Idx
+}
+```
+
+
+#### func (*EmptyStatement) Idx0
+
+```go
+func (self *EmptyStatement) Idx0() file.Idx
+```
+
+#### func (*EmptyStatement) Idx1
+
+```go
+func (self *EmptyStatement) Idx1() file.Idx
+```
+
+#### type Expression
+
+```go
+type Expression interface {
+ Node
+ // contains filtered or unexported methods
+}
+```
+
+All expression nodes implement the Expression interface.
+
+#### type ExpressionStatement
+
+```go
+type ExpressionStatement struct {
+ Expression Expression
+}
+```
+
+
+#### func (*ExpressionStatement) Idx0
+
+```go
+func (self *ExpressionStatement) Idx0() file.Idx
+```
+
+#### func (*ExpressionStatement) Idx1
+
+```go
+func (self *ExpressionStatement) Idx1() file.Idx
+```
+
+#### type ForInStatement
+
+```go
+type ForInStatement struct {
+ For file.Idx
+ Into Expression
+ Source Expression
+ Body Statement
+}
+```
+
+
+#### func (*ForInStatement) Idx0
+
+```go
+func (self *ForInStatement) Idx0() file.Idx
+```
+
+#### func (*ForInStatement) Idx1
+
+```go
+func (self *ForInStatement) Idx1() file.Idx
+```
+
+#### type ForStatement
+
+```go
+type ForStatement struct {
+ For file.Idx
+ Initializer Expression
+ Update Expression
+ Test Expression
+ Body Statement
+}
+```
+
+
+#### func (*ForStatement) Idx0
+
+```go
+func (self *ForStatement) Idx0() file.Idx
+```
+
+#### func (*ForStatement) Idx1
+
+```go
+func (self *ForStatement) Idx1() file.Idx
+```
+
+#### type FunctionDeclaration
+
+```go
+type FunctionDeclaration struct {
+ Function *FunctionLiteral
+}
+```
+
+
+#### type FunctionLiteral
+
+```go
+type FunctionLiteral struct {
+ Function file.Idx
+ Name *Identifier
+ ParameterList *ParameterList
+ Body Statement
+ Source string
+
+ DeclarationList []Declaration
+}
+```
+
+
+#### func (*FunctionLiteral) Idx0
+
+```go
+func (self *FunctionLiteral) Idx0() file.Idx
+```
+
+#### func (*FunctionLiteral) Idx1
+
+```go
+func (self *FunctionLiteral) Idx1() file.Idx
+```
+
+#### type Identifier
+
+```go
+type Identifier struct {
+ Name string
+ Idx file.Idx
+}
+```
+
+
+#### func (*Identifier) Idx0
+
+```go
+func (self *Identifier) Idx0() file.Idx
+```
+
+#### func (*Identifier) Idx1
+
+```go
+func (self *Identifier) Idx1() file.Idx
+```
+
+#### type IfStatement
+
+```go
+type IfStatement struct {
+ If file.Idx
+ Test Expression
+ Consequent Statement
+ Alternate Statement
+}
+```
+
+
+#### func (*IfStatement) Idx0
+
+```go
+func (self *IfStatement) Idx0() file.Idx
+```
+
+#### func (*IfStatement) Idx1
+
+```go
+func (self *IfStatement) Idx1() file.Idx
+```
+
+#### type LabelledStatement
+
+```go
+type LabelledStatement struct {
+ Label *Identifier
+ Colon file.Idx
+ Statement Statement
+}
+```
+
+
+#### func (*LabelledStatement) Idx0
+
+```go
+func (self *LabelledStatement) Idx0() file.Idx
+```
+
+#### func (*LabelledStatement) Idx1
+
+```go
+func (self *LabelledStatement) Idx1() file.Idx
+```
+
+#### type NewExpression
+
+```go
+type NewExpression struct {
+ New file.Idx
+ Callee Expression
+ LeftParenthesis file.Idx
+ ArgumentList []Expression
+ RightParenthesis file.Idx
+}
+```
+
+
+#### func (*NewExpression) Idx0
+
+```go
+func (self *NewExpression) Idx0() file.Idx
+```
+
+#### func (*NewExpression) Idx1
+
+```go
+func (self *NewExpression) Idx1() file.Idx
+```
+
+#### type Node
+
+```go
+type Node interface {
+ Idx0() file.Idx // The index of the first character belonging to the node
+ Idx1() file.Idx // The index of the first character immediately after the node
+}
+```
+
+All nodes implement the Node interface.
+
+#### type NullLiteral
+
+```go
+type NullLiteral struct {
+ Idx file.Idx
+ Literal string
+}
+```
+
+
+#### func (*NullLiteral) Idx0
+
+```go
+func (self *NullLiteral) Idx0() file.Idx
+```
+
+#### func (*NullLiteral) Idx1
+
+```go
+func (self *NullLiteral) Idx1() file.Idx
+```
+
+#### type NumberLiteral
+
+```go
+type NumberLiteral struct {
+ Idx file.Idx
+ Literal string
+ Value interface{}
+}
+```
+
+
+#### func (*NumberLiteral) Idx0
+
+```go
+func (self *NumberLiteral) Idx0() file.Idx
+```
+
+#### func (*NumberLiteral) Idx1
+
+```go
+func (self *NumberLiteral) Idx1() file.Idx
+```
+
+#### type ObjectLiteral
+
+```go
+type ObjectLiteral struct {
+ LeftBrace file.Idx
+ RightBrace file.Idx
+ Value []Property
+}
+```
+
+
+#### func (*ObjectLiteral) Idx0
+
+```go
+func (self *ObjectLiteral) Idx0() file.Idx
+```
+
+#### func (*ObjectLiteral) Idx1
+
+```go
+func (self *ObjectLiteral) Idx1() file.Idx
+```
+
+#### type ParameterList
+
+```go
+type ParameterList struct {
+ Opening file.Idx
+ List []*Identifier
+ Closing file.Idx
+}
+```
+
+
+#### type Program
+
+```go
+type Program struct {
+ Body []Statement
+
+ DeclarationList []Declaration
+
+ File *file.File
+}
+```
+
+
+#### func (*Program) Idx0
+
+```go
+func (self *Program) Idx0() file.Idx
+```
+
+#### func (*Program) Idx1
+
+```go
+func (self *Program) Idx1() file.Idx
+```
+
+#### type Property
+
+```go
+type Property struct {
+ Key string
+ Kind string
+ Value Expression
+}
+```
+
+
+#### type RegExpLiteral
+
+```go
+type RegExpLiteral struct {
+ Idx file.Idx
+ Literal string
+ Pattern string
+ Flags string
+ Value string
+}
+```
+
+
+#### func (*RegExpLiteral) Idx0
+
+```go
+func (self *RegExpLiteral) Idx0() file.Idx
+```
+
+#### func (*RegExpLiteral) Idx1
+
+```go
+func (self *RegExpLiteral) Idx1() file.Idx
+```
+
+#### type ReturnStatement
+
+```go
+type ReturnStatement struct {
+ Return file.Idx
+ Argument Expression
+}
+```
+
+
+#### func (*ReturnStatement) Idx0
+
+```go
+func (self *ReturnStatement) Idx0() file.Idx
+```
+
+#### func (*ReturnStatement) Idx1
+
+```go
+func (self *ReturnStatement) Idx1() file.Idx
+```
+
+#### type SequenceExpression
+
+```go
+type SequenceExpression struct {
+ Sequence []Expression
+}
+```
+
+
+#### func (*SequenceExpression) Idx0
+
+```go
+func (self *SequenceExpression) Idx0() file.Idx
+```
+
+#### func (*SequenceExpression) Idx1
+
+```go
+func (self *SequenceExpression) Idx1() file.Idx
+```
+
+#### type Statement
+
+```go
+type Statement interface {
+ Node
+ // contains filtered or unexported methods
+}
+```
+
+All statement nodes implement the Statement interface.
+
+#### type StringLiteral
+
+```go
+type StringLiteral struct {
+ Idx file.Idx
+ Literal string
+ Value string
+}
+```
+
+
+#### func (*StringLiteral) Idx0
+
+```go
+func (self *StringLiteral) Idx0() file.Idx
+```
+
+#### func (*StringLiteral) Idx1
+
+```go
+func (self *StringLiteral) Idx1() file.Idx
+```
+
+#### type SwitchStatement
+
+```go
+type SwitchStatement struct {
+ Switch file.Idx
+ Discriminant Expression
+ Default int
+ Body []*CaseStatement
+}
+```
+
+
+#### func (*SwitchStatement) Idx0
+
+```go
+func (self *SwitchStatement) Idx0() file.Idx
+```
+
+#### func (*SwitchStatement) Idx1
+
+```go
+func (self *SwitchStatement) Idx1() file.Idx
+```
+
+#### type ThisExpression
+
+```go
+type ThisExpression struct {
+ Idx file.Idx
+}
+```
+
+
+#### func (*ThisExpression) Idx0
+
+```go
+func (self *ThisExpression) Idx0() file.Idx
+```
+
+#### func (*ThisExpression) Idx1
+
+```go
+func (self *ThisExpression) Idx1() file.Idx
+```
+
+#### type ThrowStatement
+
+```go
+type ThrowStatement struct {
+ Throw file.Idx
+ Argument Expression
+}
+```
+
+
+#### func (*ThrowStatement) Idx0
+
+```go
+func (self *ThrowStatement) Idx0() file.Idx
+```
+
+#### func (*ThrowStatement) Idx1
+
+```go
+func (self *ThrowStatement) Idx1() file.Idx
+```
+
+#### type TryStatement
+
+```go
+type TryStatement struct {
+ Try file.Idx
+ Body Statement
+ Catch *CatchStatement
+ Finally Statement
+}
+```
+
+
+#### func (*TryStatement) Idx0
+
+```go
+func (self *TryStatement) Idx0() file.Idx
+```
+
+#### func (*TryStatement) Idx1
+
+```go
+func (self *TryStatement) Idx1() file.Idx
+```
+
+#### type UnaryExpression
+
+```go
+type UnaryExpression struct {
+ Operator token.Token
+ Idx file.Idx // If a prefix operation
+ Operand Expression
+ Postfix bool
+}
+```
+
+
+#### func (*UnaryExpression) Idx0
+
+```go
+func (self *UnaryExpression) Idx0() file.Idx
+```
+
+#### func (*UnaryExpression) Idx1
+
+```go
+func (self *UnaryExpression) Idx1() file.Idx
+```
+
+#### type VariableDeclaration
+
+```go
+type VariableDeclaration struct {
+ Var file.Idx
+ List []*VariableExpression
+}
+```
+
+
+#### type VariableExpression
+
+```go
+type VariableExpression struct {
+ Name string
+ Idx file.Idx
+ Initializer Expression
+}
+```
+
+
+#### func (*VariableExpression) Idx0
+
+```go
+func (self *VariableExpression) Idx0() file.Idx
+```
+
+#### func (*VariableExpression) Idx1
+
+```go
+func (self *VariableExpression) Idx1() file.Idx
+```
+
+#### type VariableStatement
+
+```go
+type VariableStatement struct {
+ Var file.Idx
+ List []Expression
+}
+```
+
+
+#### func (*VariableStatement) Idx0
+
+```go
+func (self *VariableStatement) Idx0() file.Idx
+```
+
+#### func (*VariableStatement) Idx1
+
+```go
+func (self *VariableStatement) Idx1() file.Idx
+```
+
+#### type WhileStatement
+
+```go
+type WhileStatement struct {
+ While file.Idx
+ Test Expression
+ Body Statement
+}
+```
+
+
+#### func (*WhileStatement) Idx0
+
+```go
+func (self *WhileStatement) Idx0() file.Idx
+```
+
+#### func (*WhileStatement) Idx1
+
+```go
+func (self *WhileStatement) Idx1() file.Idx
+```
+
+#### type WithStatement
+
+```go
+type WithStatement struct {
+ With file.Idx
+ Object Expression
+ Body Statement
+}
+```
+
+
+#### func (*WithStatement) Idx0
+
+```go
+func (self *WithStatement) Idx0() file.Idx
+```
+
+#### func (*WithStatement) Idx1
+
+```go
+func (self *WithStatement) Idx1() file.Idx
+```
+
+--
+**godocdown** http://github.com/robertkrimen/godocdown
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/ast/node.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/ast/node.go
new file mode 100644
index 000000000..eb46f8601
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/ast/node.go
@@ -0,0 +1,498 @@
+/*
+Package ast declares types representing a JavaScript AST.
+
+Warning
+
+The parser and AST interfaces are still works-in-progress (particularly where
+node types are concerned) and may change in the future.
+
+*/
+package ast
+
+import (
+ "github.com/robertkrimen/otto/file"
+ "github.com/robertkrimen/otto/token"
+)
+
+// All nodes implement the Node interface.
+type Node interface {
+ Idx0() file.Idx // The index of the first character belonging to the node
+ Idx1() file.Idx // The index of the first character immediately after the node
+}
+
+// ========== //
+// Expression //
+// ========== //
+
+type (
+ // All expression nodes implement the Expression interface.
+ Expression interface {
+ Node
+ _expressionNode()
+ }
+
+ ArrayLiteral struct {
+ LeftBracket file.Idx
+ RightBracket file.Idx
+ Value []Expression
+ }
+
+ AssignExpression struct {
+ Operator token.Token
+ Left Expression
+ Right Expression
+ }
+
+ BadExpression struct {
+ From file.Idx
+ To file.Idx
+ }
+
+ BinaryExpression struct {
+ Operator token.Token
+ Left Expression
+ Right Expression
+ Comparison bool
+ }
+
+ BooleanLiteral struct {
+ Idx file.Idx
+ Literal string
+ Value bool
+ }
+
+ BracketExpression struct {
+ Left Expression
+ Member Expression
+ LeftBracket file.Idx
+ RightBracket file.Idx
+ }
+
+ CallExpression struct {
+ Callee Expression
+ LeftParenthesis file.Idx
+ ArgumentList []Expression
+ RightParenthesis file.Idx
+ }
+
+ ConditionalExpression struct {
+ Test Expression
+ Consequent Expression
+ Alternate Expression
+ }
+
+ DotExpression struct {
+ Left Expression
+ Identifier Identifier
+ }
+
+ FunctionLiteral struct {
+ Function file.Idx
+ Name *Identifier
+ ParameterList *ParameterList
+ Body Statement
+ Source string
+
+ DeclarationList []Declaration
+ }
+
+ Identifier struct {
+ Name string
+ Idx file.Idx
+ }
+
+ NewExpression struct {
+ New file.Idx
+ Callee Expression
+ LeftParenthesis file.Idx
+ ArgumentList []Expression
+ RightParenthesis file.Idx
+ }
+
+ NullLiteral struct {
+ Idx file.Idx
+ Literal string
+ }
+
+ NumberLiteral struct {
+ Idx file.Idx
+ Literal string
+ Value interface{}
+ }
+
+ ObjectLiteral struct {
+ LeftBrace file.Idx
+ RightBrace file.Idx
+ Value []Property
+ }
+
+ ParameterList struct {
+ Opening file.Idx
+ List []*Identifier
+ Closing file.Idx
+ }
+
+ Property struct {
+ Key string
+ Kind string
+ Value Expression
+ }
+
+ RegExpLiteral struct {
+ Idx file.Idx
+ Literal string
+ Pattern string
+ Flags string
+ Value string
+ }
+
+ SequenceExpression struct {
+ Sequence []Expression
+ }
+
+ StringLiteral struct {
+ Idx file.Idx
+ Literal string
+ Value string
+ }
+
+ ThisExpression struct {
+ Idx file.Idx
+ }
+
+ UnaryExpression struct {
+ Operator token.Token
+ Idx file.Idx // If a prefix operation
+ Operand Expression
+ Postfix bool
+ }
+
+ VariableExpression struct {
+ Name string
+ Idx file.Idx
+ Initializer Expression
+ }
+)
+
+// _expressionNode
+
+func (*ArrayLiteral) _expressionNode() {}
+func (*AssignExpression) _expressionNode() {}
+func (*BadExpression) _expressionNode() {}
+func (*BinaryExpression) _expressionNode() {}
+func (*BooleanLiteral) _expressionNode() {}
+func (*BracketExpression) _expressionNode() {}
+func (*CallExpression) _expressionNode() {}
+func (*ConditionalExpression) _expressionNode() {}
+func (*DotExpression) _expressionNode() {}
+func (*FunctionLiteral) _expressionNode() {}
+func (*Identifier) _expressionNode() {}
+func (*NewExpression) _expressionNode() {}
+func (*NullLiteral) _expressionNode() {}
+func (*NumberLiteral) _expressionNode() {}
+func (*ObjectLiteral) _expressionNode() {}
+func (*RegExpLiteral) _expressionNode() {}
+func (*SequenceExpression) _expressionNode() {}
+func (*StringLiteral) _expressionNode() {}
+func (*ThisExpression) _expressionNode() {}
+func (*UnaryExpression) _expressionNode() {}
+func (*VariableExpression) _expressionNode() {}
+
+// ========= //
+// Statement //
+// ========= //
+
+type (
+ // All statement nodes implement the Statement interface.
+ Statement interface {
+ Node
+ _statementNode()
+ }
+
+ BadStatement struct {
+ From file.Idx
+ To file.Idx
+ }
+
+ BlockStatement struct {
+ LeftBrace file.Idx
+ List []Statement
+ RightBrace file.Idx
+ }
+
+ BranchStatement struct {
+ Idx file.Idx
+ Token token.Token
+ Label *Identifier
+ }
+
+ CaseStatement struct {
+ Case file.Idx
+ Test Expression
+ Consequent []Statement
+ }
+
+ CatchStatement struct {
+ Catch file.Idx
+ Parameter *Identifier
+ Body Statement
+ }
+
+ DebuggerStatement struct {
+ Debugger file.Idx
+ }
+
+ DoWhileStatement struct {
+ Do file.Idx
+ Test Expression
+ Body Statement
+ }
+
+ EmptyStatement struct {
+ Semicolon file.Idx
+ }
+
+ ExpressionStatement struct {
+ Expression Expression
+ }
+
+ ForInStatement struct {
+ For file.Idx
+ Into Expression
+ Source Expression
+ Body Statement
+ }
+
+ ForStatement struct {
+ For file.Idx
+ Initializer Expression
+ Update Expression
+ Test Expression
+ Body Statement
+ }
+
+ IfStatement struct {
+ If file.Idx
+ Test Expression
+ Consequent Statement
+ Alternate Statement
+ }
+
+ LabelledStatement struct {
+ Label *Identifier
+ Colon file.Idx
+ Statement Statement
+ }
+
+ ReturnStatement struct {
+ Return file.Idx
+ Argument Expression
+ }
+
+ SwitchStatement struct {
+ Switch file.Idx
+ Discriminant Expression
+ Default int
+ Body []*CaseStatement
+ }
+
+ ThrowStatement struct {
+ Throw file.Idx
+ Argument Expression
+ }
+
+ TryStatement struct {
+ Try file.Idx
+ Body Statement
+ Catch *CatchStatement
+ Finally Statement
+ }
+
+ VariableStatement struct {
+ Var file.Idx
+ List []Expression
+ }
+
+ WhileStatement struct {
+ While file.Idx
+ Test Expression
+ Body Statement
+ }
+
+ WithStatement struct {
+ With file.Idx
+ Object Expression
+ Body Statement
+ }
+)
+
+// _statementNode
+
+func (*BadStatement) _statementNode() {}
+func (*BlockStatement) _statementNode() {}
+func (*BranchStatement) _statementNode() {}
+func (*CaseStatement) _statementNode() {}
+func (*CatchStatement) _statementNode() {}
+func (*DebuggerStatement) _statementNode() {}
+func (*DoWhileStatement) _statementNode() {}
+func (*EmptyStatement) _statementNode() {}
+func (*ExpressionStatement) _statementNode() {}
+func (*ForInStatement) _statementNode() {}
+func (*ForStatement) _statementNode() {}
+func (*IfStatement) _statementNode() {}
+func (*LabelledStatement) _statementNode() {}
+func (*ReturnStatement) _statementNode() {}
+func (*SwitchStatement) _statementNode() {}
+func (*ThrowStatement) _statementNode() {}
+func (*TryStatement) _statementNode() {}
+func (*VariableStatement) _statementNode() {}
+func (*WhileStatement) _statementNode() {}
+func (*WithStatement) _statementNode() {}
+
+// =========== //
+// Declaration //
+// =========== //
+
+type (
+ // All declaration nodes implement the Declaration interface.
+ Declaration interface {
+ _declarationNode()
+ }
+
+ FunctionDeclaration struct {
+ Function *FunctionLiteral
+ }
+
+ VariableDeclaration struct {
+ Var file.Idx
+ List []*VariableExpression
+ }
+)
+
+// _declarationNode
+
+func (*FunctionDeclaration) _declarationNode() {}
+func (*VariableDeclaration) _declarationNode() {}
+
+// ==== //
+// Node //
+// ==== //
+
+type Program struct {
+ Body []Statement
+
+ DeclarationList []Declaration
+
+ File *file.File
+}
+
+// ==== //
+// Idx0 //
+// ==== //
+
+func (self *ArrayLiteral) Idx0() file.Idx { return self.LeftBracket }
+func (self *AssignExpression) Idx0() file.Idx { return self.Left.Idx0() }
+func (self *BadExpression) Idx0() file.Idx { return self.From }
+func (self *BinaryExpression) Idx0() file.Idx { return self.Left.Idx0() }
+func (self *BooleanLiteral) Idx0() file.Idx { return self.Idx }
+func (self *BracketExpression) Idx0() file.Idx { return self.Left.Idx0() }
+func (self *CallExpression) Idx0() file.Idx { return self.Callee.Idx0() }
+func (self *ConditionalExpression) Idx0() file.Idx { return self.Test.Idx0() }
+func (self *DotExpression) Idx0() file.Idx { return self.Left.Idx0() }
+func (self *FunctionLiteral) Idx0() file.Idx { return self.Function }
+func (self *Identifier) Idx0() file.Idx { return self.Idx }
+func (self *NewExpression) Idx0() file.Idx { return self.New }
+func (self *NullLiteral) Idx0() file.Idx { return self.Idx }
+func (self *NumberLiteral) Idx0() file.Idx { return self.Idx }
+func (self *ObjectLiteral) Idx0() file.Idx { return self.LeftBrace }
+func (self *RegExpLiteral) Idx0() file.Idx { return self.Idx }
+func (self *SequenceExpression) Idx0() file.Idx { return self.Sequence[0].Idx0() }
+func (self *StringLiteral) Idx0() file.Idx { return self.Idx }
+func (self *ThisExpression) Idx0() file.Idx { return self.Idx }
+func (self *UnaryExpression) Idx0() file.Idx { return self.Idx }
+func (self *VariableExpression) Idx0() file.Idx { return self.Idx }
+
+func (self *BadStatement) Idx0() file.Idx { return self.From }
+func (self *BlockStatement) Idx0() file.Idx { return self.LeftBrace }
+func (self *BranchStatement) Idx0() file.Idx { return self.Idx }
+func (self *CaseStatement) Idx0() file.Idx { return self.Case }
+func (self *CatchStatement) Idx0() file.Idx { return self.Catch }
+func (self *DebuggerStatement) Idx0() file.Idx { return self.Debugger }
+func (self *DoWhileStatement) Idx0() file.Idx { return self.Do }
+func (self *EmptyStatement) Idx0() file.Idx { return self.Semicolon }
+func (self *ExpressionStatement) Idx0() file.Idx { return self.Expression.Idx0() }
+func (self *ForInStatement) Idx0() file.Idx { return self.For }
+func (self *ForStatement) Idx0() file.Idx { return self.For }
+func (self *IfStatement) Idx0() file.Idx { return self.If }
+func (self *LabelledStatement) Idx0() file.Idx { return self.Label.Idx0() }
+func (self *Program) Idx0() file.Idx { return self.Body[0].Idx0() }
+func (self *ReturnStatement) Idx0() file.Idx { return self.Return }
+func (self *SwitchStatement) Idx0() file.Idx { return self.Switch }
+func (self *ThrowStatement) Idx0() file.Idx { return self.Throw }
+func (self *TryStatement) Idx0() file.Idx { return self.Try }
+func (self *VariableStatement) Idx0() file.Idx { return self.Var }
+func (self *WhileStatement) Idx0() file.Idx { return self.While }
+func (self *WithStatement) Idx0() file.Idx { return self.With }
+
+// ==== //
+// Idx1 //
+// ==== //
+
+func (self *ArrayLiteral) Idx1() file.Idx { return self.RightBracket }
+func (self *AssignExpression) Idx1() file.Idx { return self.Right.Idx1() }
+func (self *BadExpression) Idx1() file.Idx { return self.To }
+func (self *BinaryExpression) Idx1() file.Idx { return self.Right.Idx1() }
+func (self *BooleanLiteral) Idx1() file.Idx { return file.Idx(int(self.Idx) + len(self.Literal)) }
+func (self *BracketExpression) Idx1() file.Idx { return self.RightBracket + 1 }
+func (self *CallExpression) Idx1() file.Idx { return self.RightParenthesis + 1 }
+func (self *ConditionalExpression) Idx1() file.Idx { return self.Test.Idx1() }
+func (self *DotExpression) Idx1() file.Idx { return self.Identifier.Idx1() }
+func (self *FunctionLiteral) Idx1() file.Idx { return self.Body.Idx1() }
+func (self *Identifier) Idx1() file.Idx { return file.Idx(int(self.Idx) + len(self.Name)) }
+func (self *NewExpression) Idx1() file.Idx { return self.RightParenthesis + 1 }
+func (self *NullLiteral) Idx1() file.Idx { return file.Idx(int(self.Idx) + 4) } // "null"
+func (self *NumberLiteral) Idx1() file.Idx { return file.Idx(int(self.Idx) + len(self.Literal)) }
+func (self *ObjectLiteral) Idx1() file.Idx { return self.RightBrace }
+func (self *RegExpLiteral) Idx1() file.Idx { return file.Idx(int(self.Idx) + len(self.Literal)) }
+func (self *SequenceExpression) Idx1() file.Idx { return self.Sequence[0].Idx1() }
+func (self *StringLiteral) Idx1() file.Idx { return file.Idx(int(self.Idx) + len(self.Literal)) }
+func (self *ThisExpression) Idx1() file.Idx { return self.Idx }
+func (self *UnaryExpression) Idx1() file.Idx {
+ if self.Postfix {
+ return self.Operand.Idx1() + 2 // ++ --
+ }
+ return self.Operand.Idx1()
+}
+func (self *VariableExpression) Idx1() file.Idx {
+ if self.Initializer == nil {
+ return file.Idx(int(self.Idx) + len(self.Name) + 1)
+ }
+ return self.Initializer.Idx1()
+}
+
+func (self *BadStatement) Idx1() file.Idx { return self.To }
+func (self *BlockStatement) Idx1() file.Idx { return self.RightBrace + 1 }
+func (self *BranchStatement) Idx1() file.Idx { return self.Idx }
+func (self *CaseStatement) Idx1() file.Idx { return self.Consequent[len(self.Consequent)-1].Idx1() }
+func (self *CatchStatement) Idx1() file.Idx { return self.Body.Idx1() }
+func (self *DebuggerStatement) Idx1() file.Idx { return self.Debugger + 8 }
+func (self *DoWhileStatement) Idx1() file.Idx { return self.Test.Idx1() }
+func (self *EmptyStatement) Idx1() file.Idx { return self.Semicolon + 1 }
+func (self *ExpressionStatement) Idx1() file.Idx { return self.Expression.Idx1() }
+func (self *ForInStatement) Idx1() file.Idx { return self.Body.Idx1() }
+func (self *ForStatement) Idx1() file.Idx { return self.Body.Idx1() }
+func (self *IfStatement) Idx1() file.Idx {
+ if self.Alternate != nil {
+ return self.Alternate.Idx1()
+ }
+ return self.Consequent.Idx1()
+}
+func (self *LabelledStatement) Idx1() file.Idx { return self.Colon + 1 }
+func (self *Program) Idx1() file.Idx { return self.Body[len(self.Body)-1].Idx1() }
+func (self *ReturnStatement) Idx1() file.Idx { return self.Return }
+func (self *SwitchStatement) Idx1() file.Idx { return self.Body[len(self.Body)-1].Idx1() }
+func (self *ThrowStatement) Idx1() file.Idx { return self.Throw }
+func (self *TryStatement) Idx1() file.Idx { return self.Try }
+func (self *VariableStatement) Idx1() file.Idx { return self.List[len(self.List)-1].Idx1() }
+func (self *WhileStatement) Idx1() file.Idx { return self.Body.Idx1() }
+func (self *WithStatement) Idx1() file.Idx { return self.Body.Idx1() }
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/bug_test.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/bug_test.go
new file mode 100644
index 000000000..5e4d90bae
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/bug_test.go
@@ -0,0 +1,617 @@
+package otto
+
+import (
+ "testing"
+ "time"
+)
+
+func Test_262(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ // 11.13.1-1-1
+ test(`raise:
+ eval("42 = 42;");
+ `, "ReferenceError: Invalid left-hand side in assignment")
+ })
+}
+
+func Test_issue5(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`'abc' === 'def'`, false)
+ test(`'\t' === '\r'`, false)
+ })
+}
+
+func Test_issue13(t *testing.T) {
+ tt(t, func() {
+ test, tester := test()
+ vm := tester.vm
+
+ value, err := vm.ToValue(map[string]interface{}{
+ "string": "Xyzzy",
+ "number": 42,
+ "array": []string{"def", "ghi"},
+ })
+ if err != nil {
+ t.Error(err)
+ t.FailNow()
+ }
+
+ fn, err := vm.Object(`
+ (function(value){
+ return ""+[value.string, value.number, value.array]
+ })
+ `)
+ if err != nil {
+ t.Error(err)
+ t.FailNow()
+ }
+
+ result, err := fn.Value().Call(fn.Value(), value)
+ if err != nil {
+ t.Error(err)
+ t.FailNow()
+ }
+ is(result.string(), "Xyzzy,42,def,ghi")
+
+ anything := struct {
+ Abc interface{}
+ }{
+ Abc: map[string]interface{}{
+ "def": []interface{}{
+ []interface{}{
+ "a", "b", "c", "", "d", "e",
+ },
+ map[string]interface{}{
+ "jkl": "Nothing happens.",
+ },
+ },
+ "ghi": -1,
+ },
+ }
+
+ vm.Set("anything", anything)
+ test(`
+ [
+ anything,
+ "~",
+ anything.Abc,
+ "~",
+ anything.Abc.def,
+ "~",
+ anything.Abc.def[1].jkl,
+ "~",
+ anything.Abc.ghi,
+ ];
+ `, "[object Object],~,[object Object],~,a,b,c,,d,e,[object Object],~,Nothing happens.,~,-1")
+ })
+}
+
+func Test_issue16(t *testing.T) {
+ tt(t, func() {
+ test, vm := test()
+
+ test(`
+ var def = {
+ "abc": ["abc"],
+ "xyz": ["xyz"]
+ };
+ def.abc.concat(def.xyz);
+ `, "abc,xyz")
+
+ vm.Set("ghi", []string{"jkl", "mno"})
+
+ test(`
+ def.abc.concat(def.xyz).concat(ghi);
+ `, "abc,xyz,jkl,mno")
+
+ test(`
+ ghi.concat(def.abc.concat(def.xyz));
+ `, "jkl,mno,abc,xyz")
+
+ vm.Set("pqr", []interface{}{"jkl", 42, 3.14159, true})
+
+ test(`
+ pqr.concat(ghi, def.abc, def, def.xyz);
+ `, "jkl,42,3.14159,true,jkl,mno,abc,[object Object],xyz")
+
+ test(`
+ pqr.concat(ghi, def.abc, def, def.xyz).length;
+ `, 9)
+ })
+}
+
+func Test_issue21(t *testing.T) {
+ tt(t, func() {
+ vm1 := New()
+ vm1.Run(`
+ abc = {}
+ abc.ghi = "Nothing happens.";
+ var jkl = 0;
+ abc.def = function() {
+ jkl += 1;
+ return 1;
+ }
+ `)
+ abc, err := vm1.Get("abc")
+ is(err, nil)
+
+ vm2 := New()
+ vm2.Set("cba", abc)
+ _, err = vm2.Run(`
+ var pqr = 0;
+ cba.mno = function() {
+ pqr -= 1;
+ return 1;
+ }
+ cba.def();
+ cba.def();
+ cba.def();
+ `)
+ is(err, nil)
+
+ jkl, err := vm1.Get("jkl")
+ is(err, nil)
+ is(jkl, 3)
+
+ _, err = vm1.Run(`
+ abc.mno();
+ abc.mno();
+ abc.mno();
+ `)
+ is(err, nil)
+
+ pqr, err := vm2.Get("pqr")
+ is(err, nil)
+ is(pqr, -3)
+ })
+}
+
+func Test_issue24(t *testing.T) {
+ tt(t, func() {
+ _, vm := test()
+
+ {
+ vm.Set("abc", []string{"abc", "def", "ghi"})
+ value, err := vm.Get("abc")
+ is(err, nil)
+ export, _ := value.Export()
+ {
+ value, valid := export.([]string)
+ is(valid, true)
+
+ is(value[0], "abc")
+ is(value[2], "ghi")
+ }
+ }
+
+ {
+ vm.Set("abc", [...]string{"abc", "def", "ghi"})
+ value, err := vm.Get("abc")
+ is(err, nil)
+ export, _ := value.Export()
+ {
+ value, valid := export.([3]string)
+ is(valid, true)
+
+ is(value[0], "abc")
+ is(value[2], "ghi")
+ }
+ }
+
+ {
+ vm.Set("abc", &[...]string{"abc", "def", "ghi"})
+ value, err := vm.Get("abc")
+ is(err, nil)
+ export, _ := value.Export()
+ {
+ value, valid := export.(*[3]string)
+ is(valid, true)
+
+ is(value[0], "abc")
+ is(value[2], "ghi")
+ }
+ }
+
+ {
+ vm.Set("abc", map[int]string{0: "abc", 1: "def", 2: "ghi"})
+ value, err := vm.Get("abc")
+ is(err, nil)
+ export, _ := value.Export()
+ {
+ value, valid := export.(map[int]string)
+ is(valid, true)
+
+ is(value[0], "abc")
+ is(value[2], "ghi")
+ }
+ }
+
+ {
+ vm.Set("abc", _abcStruct{Abc: true, Ghi: "Nothing happens."})
+ value, err := vm.Get("abc")
+ is(err, nil)
+ export, _ := value.Export()
+ {
+ value, valid := export.(_abcStruct)
+ is(valid, true)
+
+ is(value.Abc, true)
+ is(value.Ghi, "Nothing happens.")
+ }
+ }
+
+ {
+ vm.Set("abc", &_abcStruct{Abc: true, Ghi: "Nothing happens."})
+ value, err := vm.Get("abc")
+ is(err, nil)
+ export, _ := value.Export()
+ {
+ value, valid := export.(*_abcStruct)
+ is(valid, true)
+
+ is(value.Abc, true)
+ is(value.Ghi, "Nothing happens.")
+ }
+ }
+ })
+}
+
+func Test_issue39(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ var abc = 0, def = [], ghi = function() {
+ if (abc < 10) return ++abc;
+ return undefined;
+ }
+ for (var jkl; (jkl = ghi());) def.push(jkl);
+ def;
+ `, "1,2,3,4,5,6,7,8,9,10")
+
+ test(`
+ var abc = ["1", "2", "3", "4"];
+ var def = [];
+ for (var ghi; (ghi = abc.shift());) {
+ def.push(ghi);
+ }
+ def;
+ `, "1,2,3,4")
+ })
+}
+
+func Test_issue64(t *testing.T) {
+ tt(t, func() {
+ test, vm := test()
+
+ defer mockTimeLocal(time.UTC)()
+
+ abc := map[string]interface{}{
+ "time": time.Unix(0, 0),
+ }
+ vm.Set("abc", abc)
+
+ def := struct {
+ Public string
+ private string
+ }{
+ "Public", "private",
+ }
+ vm.Set("def", def)
+
+ test(`"sec" in abc.time`, false)
+
+ test(`
+ [ "Public" in def, "private" in def, def.Public, def.private ];
+ `, "true,false,Public,")
+
+ test(`JSON.stringify(abc)`, `{"time":"1970-01-01T00:00:00Z"}`)
+ })
+}
+
+func Test_issue73(t *testing.T) {
+ tt(t, func() {
+ test, vm := test()
+
+ vm.Set("abc", [4]int{3, 2, 1, 0})
+
+ test(`
+ var def = [ 0, 1, 2, 3 ];
+ JSON.stringify(def) + JSON.stringify(abc);
+ `, "[0,1,2,3][3,2,1,0]")
+ })
+}
+
+func Test_7_3_1(t *testing.T) {
+ tt(t, func() {
+ test(`
+ eval("var test7_3_1\u2028abc = 66;");
+ [ abc, typeof test7_3_1 ];
+ `, "66,undefined")
+ })
+}
+
+func Test_7_3_3(t *testing.T) {
+ tt(t, func() {
+ test(`raise:
+ eval("//\u2028 =;");
+ `, "SyntaxError: Unexpected token =")
+ })
+}
+
+func Test_S7_3_A2_1_T1(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`raise:
+ eval("'\u000Astr\u000Aing\u000A'")
+ `, "SyntaxError: Unexpected token ILLEGAL")
+ })
+}
+
+func Test_S7_8_3_A2_1_T1(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ [ .0 === 0.0, .0, .1 === 0.1, .1 ]
+ `, "true,0,true,0.1")
+ })
+}
+
+func Test_S7_8_4_A4_2_T3(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ "\a"
+ `, "a")
+ })
+}
+
+func Test_S7_9_A1(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ var def;
+ abc: for (var i = 0; i <= 0; i++) {
+ for (var j = 0; j <= 1; j++) {
+ if (j === 0) {
+ continue abc;
+ } else {
+ def = true;
+ }
+ }
+ }
+ [ def, i, j ];
+ `, ",1,0")
+ })
+}
+
+func Test_S7_9_A3(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ (function(){
+ return
+ 1;
+ })()
+ `, "undefined")
+ })
+}
+
+func Test_7_3_10(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ eval("var \u0061\u0062\u0063 = 3.14159;");
+ abc;
+ `, 3.14159)
+
+ test(`
+ abc = undefined;
+ eval("var \\u0061\\u0062\\u0063 = 3.14159;");
+ abc;
+ `, 3.14159)
+ })
+}
+
+func Test_bug(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ // 10.4.2-1-5
+ test(`
+ "abc\
+def"
+ `, "abcdef")
+
+ test(`
+ eval("'abc';\
+ 'def'")
+ `, "def")
+
+ // S12.6.1_A10
+ test(`
+ var abc = 0;
+ do {
+ if(typeof(def) === "function"){
+ abc = -1;
+ break;
+ } else {
+ abc = 1;
+ break;
+ }
+ } while(function def(){});
+ abc;
+ `, 1)
+
+ // S12.7_A7
+ test(`raise:
+ abc:
+ while (true) {
+ eval("continue abc");
+ }
+ `, "SyntaxError: Undefined label 'abc'")
+
+ // S15.1.2.1_A3.3_T3
+ test(`raise:
+ eval("return");
+ `, "SyntaxError: Illegal return statement")
+
+ // 15.2.3.3-2-33
+ test(`
+ var abc = { "AB\n\\cd": 1 };
+ Object.getOwnPropertyDescriptor(abc, "AB\n\\cd").value;
+ `, 1)
+
+ // S15.3_A2_T1
+ test(`raise:
+ Function.call(this, "var x / = 1;");
+ `, "SyntaxError: Unexpected token /")
+
+ // ?
+ test(`
+ (function(){
+ var abc = [];
+ (function(){
+ abc.push(0);
+ abc.push(1);
+ })(undefined);
+ if ((function(){ return true; })()) {
+ (function(){
+ abc.push(2);
+ })();
+ }
+ return abc;
+ })();
+ `, "0,1,2")
+
+ if false {
+ // 15.9.5.43-0-10
+ // Should be an invalid date
+ test(`
+ date = new Date(1970, 0, -99999999, 0, 0, 0, 1);
+ `, "")
+ }
+
+ // S7.8.3_A1.2_T1
+ test(`
+ [ 0e1, 1e1, 2e1, 3e1, 4e1, 5e1, 6e1, 7e1, 8e1, 9e1 ];
+ `, "0,10,20,30,40,50,60,70,80,90")
+
+ // S15.10.2.7_A3_T2
+ test(`
+ var abc = /\s+abc\s+/.exec("\t abc def");
+ [ abc.length, abc.index, abc.input, abc ];
+ `, "1,0,\t abc def,\t abc ")
+ })
+}
+
+func Test_issue79(t *testing.T) {
+ tt(t, func() {
+ test, vm := test()
+
+ vm.Set("abc", []_abcStruct{
+ {
+ Ghi: "一",
+ Def: 1,
+ },
+ {
+ Def: 3,
+ Ghi: "三",
+ },
+ {
+ Def: 2,
+ Ghi: "二",
+ },
+ {
+ Def: 4,
+ Ghi: "四",
+ },
+ })
+
+ test(`
+ abc.sort(function(a,b){ return b.Def-a.Def });
+ def = [];
+ for (i = 0; i < abc.length; i++) {
+ def.push(abc[i].String())
+ }
+ def;
+ `, "四,三,二,一")
+ })
+}
+
+func Test_issue80(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ JSON.stringify([
+ 1401868959,
+ 14018689591,
+ 140186895901,
+ 1401868959001,
+ 14018689590001,
+ 140186895900001,
+ 1401868959000001,
+ 1401868959000001.5,
+ 14018689590000001,
+ 140186895900000001,
+ 1401868959000000001,
+ 14018689590000000001,
+ 140186895900000000001,
+ 140186895900000000001.5
+ ]);
+ `, "[1401868959,14018689591,140186895901,1401868959001,14018689590001,140186895900001,1401868959000001,1.4018689590000015e+15,14018689590000001,140186895900000001,1401868959000000001,1.401868959e+19,1.401868959e+20,1.401868959e+20]")
+ })
+}
+
+func Test_issue87(t *testing.T) {
+ tt(t, func() {
+ test, vm := test()
+
+ test(`
+ var def = 0;
+ abc: {
+ for (;;) {
+ def = !1;
+ break abc;
+ }
+ def = !0;
+ }
+ def;
+ `, false)
+
+ _, err := vm.Run(`
+/*
+CryptoJS v3.1.2
+code.google.com/p/crypto-js
+(c) 2009-2013 by Jeff Mott. All rights reserved.
+code.google.com/p/crypto-js/wiki/License
+*/
+var CryptoJS=CryptoJS||function(h,s){var f={},g=f.lib={},q=function(){},m=g.Base={extend:function(a){q.prototype=this;var c=new q;a&&c.mixIn(a);c.hasOwnProperty("init")||(c.init=function(){c.$super.init.apply(this,arguments)});c.init.prototype=c;c.$super=this;return c},create:function(){var a=this.extend();a.init.apply(a,arguments);return a},init:function(){},mixIn:function(a){for(var c in a)a.hasOwnProperty(c)&&(this[c]=a[c]);a.hasOwnProperty("toString")&&(this.toString=a.toString)},clone:function(){return this.init.prototype.extend(this)}},
+r=g.WordArray=m.extend({init:function(a,c){a=this.words=a||[];this.sigBytes=c!=s?c:4*a.length},toString:function(a){return(a||k).stringify(this)},concat:function(a){var c=this.words,d=a.words,b=this.sigBytes;a=a.sigBytes;this.clamp();if(b%4)for(var e=0;e<a;e++)c[b+e>>>2]|=(d[e>>>2]>>>24-8*(e%4)&255)<<24-8*((b+e)%4);else if(65535<d.length)for(e=0;e<a;e+=4)c[b+e>>>2]=d[e>>>2];else c.push.apply(c,d);this.sigBytes+=a;return this},clamp:function(){var a=this.words,c=this.sigBytes;a[c>>>2]&=4294967295<<
+32-8*(c%4);a.length=h.ceil(c/4)},clone:function(){var a=m.clone.call(this);a.words=this.words.slice(0);return a},random:function(a){for(var c=[],d=0;d<a;d+=4)c.push(4294967296*h.random()|0);return new r.init(c,a)}}),l=f.enc={},k=l.Hex={stringify:function(a){var c=a.words;a=a.sigBytes;for(var d=[],b=0;b<a;b++){var e=c[b>>>2]>>>24-8*(b%4)&255;d.push((e>>>4).toString(16));d.push((e&15).toString(16))}return d.join("")},parse:function(a){for(var c=a.length,d=[],b=0;b<c;b+=2)d[b>>>3]|=parseInt(a.substr(b,
+2),16)<<24-4*(b%8);return new r.init(d,c/2)}},n=l.Latin1={stringify:function(a){var c=a.words;a=a.sigBytes;for(var d=[],b=0;b<a;b++)d.push(String.fromCharCode(c[b>>>2]>>>24-8*(b%4)&255));return d.join("")},parse:function(a){for(var c=a.length,d=[],b=0;b<c;b++)d[b>>>2]|=(a.charCodeAt(b)&255)<<24-8*(b%4);return new r.init(d,c)}},j=l.Utf8={stringify:function(a){try{return decodeURIComponent(escape(n.stringify(a)))}catch(c){throw Error("Malformed UTF-8 data");}},parse:function(a){return n.parse(unescape(encodeURIComponent(a)))}},
+u=g.BufferedBlockAlgorithm=m.extend({reset:function(){this._data=new r.init;this._nDataBytes=0},_append:function(a){"string"==typeof a&&(a=j.parse(a));this._data.concat(a);this._nDataBytes+=a.sigBytes},_process:function(a){var c=this._data,d=c.words,b=c.sigBytes,e=this.blockSize,f=b/(4*e),f=a?h.ceil(f):h.max((f|0)-this._minBufferSize,0);a=f*e;b=h.min(4*a,b);if(a){for(var g=0;g<a;g+=e)this._doProcessBlock(d,g);g=d.splice(0,a);c.sigBytes-=b}return new r.init(g,b)},clone:function(){var a=m.clone.call(this);
+a._data=this._data.clone();return a},_minBufferSize:0});g.Hasher=u.extend({cfg:m.extend(),init:function(a){this.cfg=this.cfg.extend(a);this.reset()},reset:function(){u.reset.call(this);this._doReset()},update:function(a){this._append(a);this._process();return this},finalize:function(a){a&&this._append(a);return this._doFinalize()},blockSize:16,_createHelper:function(a){return function(c,d){return(new a.init(d)).finalize(c)}},_createHmacHelper:function(a){return function(c,d){return(new t.HMAC.init(a,
+d)).finalize(c)}}});var t=f.algo={};return f}(Math);
+(function(h){for(var s=CryptoJS,f=s.lib,g=f.WordArray,q=f.Hasher,f=s.algo,m=[],r=[],l=function(a){return 4294967296*(a-(a|0))|0},k=2,n=0;64>n;){var j;a:{j=k;for(var u=h.sqrt(j),t=2;t<=u;t++)if(!(j%t)){j=!1;break a}j=!0}j&&(8>n&&(m[n]=l(h.pow(k,0.5))),r[n]=l(h.pow(k,1/3)),n++);k++}var a=[],f=f.SHA256=q.extend({_doReset:function(){this._hash=new g.init(m.slice(0))},_doProcessBlock:function(c,d){for(var b=this._hash.words,e=b[0],f=b[1],g=b[2],j=b[3],h=b[4],m=b[5],n=b[6],q=b[7],p=0;64>p;p++){if(16>p)a[p]=
+c[d+p]|0;else{var k=a[p-15],l=a[p-2];a[p]=((k<<25|k>>>7)^(k<<14|k>>>18)^k>>>3)+a[p-7]+((l<<15|l>>>17)^(l<<13|l>>>19)^l>>>10)+a[p-16]}k=q+((h<<26|h>>>6)^(h<<21|h>>>11)^(h<<7|h>>>25))+(h&m^~h&n)+r[p]+a[p];l=((e<<30|e>>>2)^(e<<19|e>>>13)^(e<<10|e>>>22))+(e&f^e&g^f&g);q=n;n=m;m=h;h=j+k|0;j=g;g=f;f=e;e=k+l|0}b[0]=b[0]+e|0;b[1]=b[1]+f|0;b[2]=b[2]+g|0;b[3]=b[3]+j|0;b[4]=b[4]+h|0;b[5]=b[5]+m|0;b[6]=b[6]+n|0;b[7]=b[7]+q|0},_doFinalize:function(){var a=this._data,d=a.words,b=8*this._nDataBytes,e=8*a.sigBytes;
+d[e>>>5]|=128<<24-e%32;d[(e+64>>>9<<4)+14]=h.floor(b/4294967296);d[(e+64>>>9<<4)+15]=b;a.sigBytes=4*d.length;this._process();return this._hash},clone:function(){var a=q.clone.call(this);a._hash=this._hash.clone();return a}});s.SHA256=q._createHelper(f);s.HmacSHA256=q._createHmacHelper(f)})(Math);
+(function(){var h=CryptoJS,s=h.enc.Utf8;h.algo.HMAC=h.lib.Base.extend({init:function(f,g){f=this._hasher=new f.init;"string"==typeof g&&(g=s.parse(g));var h=f.blockSize,m=4*h;g.sigBytes>m&&(g=f.finalize(g));g.clamp();for(var r=this._oKey=g.clone(),l=this._iKey=g.clone(),k=r.words,n=l.words,j=0;j<h;j++)k[j]^=1549556828,n[j]^=909522486;r.sigBytes=l.sigBytes=m;this.reset()},reset:function(){var f=this._hasher;f.reset();f.update(this._iKey)},update:function(f){this._hasher.update(f);return this},finalize:function(f){var g=
+this._hasher;f=g.finalize(f);g.reset();return g.finalize(this._oKey.clone().concat(f))}})})();
+ `)
+ is(err, nil)
+
+ test(`CryptoJS.HmacSHA256("Message", "secret");`, "aa747c502a898200f9e4fa21bac68136f886a0e27aec70ba06daf2e2a5cb5597")
+ })
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/builtin.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/builtin.go
new file mode 100644
index 000000000..c3375a108
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/builtin.go
@@ -0,0 +1,353 @@
+package otto
+
+import (
+ "encoding/hex"
+ "math"
+ "net/url"
+ "regexp"
+ "strconv"
+ "strings"
+ "unicode/utf16"
+ "unicode/utf8"
+)
+
+// Global
+func builtinGlobal_eval(call FunctionCall) Value {
+ src := call.Argument(0)
+ if !src.IsString() {
+ return src
+ }
+ runtime := call.runtime
+ program := runtime.cmpl_parseOrThrow(src.string())
+ if !call.eval {
+ // Not a direct call to eval, so we enter the global ExecutionContext
+ runtime.enterGlobalScope()
+ defer runtime.leaveScope()
+ }
+ returnValue := runtime.cmpl_evaluate_nodeProgram(program, true)
+ if returnValue.isEmpty() {
+ return Value{}
+ }
+ return returnValue
+}
+
+func builtinGlobal_isNaN(call FunctionCall) Value {
+ value := call.Argument(0).float64()
+ return toValue_bool(math.IsNaN(value))
+}
+
+func builtinGlobal_isFinite(call FunctionCall) Value {
+ value := call.Argument(0).float64()
+ return toValue_bool(!math.IsNaN(value) && !math.IsInf(value, 0))
+}
+
+// radix 3 => 2 (ASCII 50) +47
+// radix 11 => A/a (ASCII 65/97) +54/+86
+var parseInt_alphabetTable = func() []string {
+ table := []string{"", "", "01"}
+ for radix := 3; radix <= 36; radix += 1 {
+ alphabet := table[radix-1]
+ if radix <= 10 {
+ alphabet += string(radix + 47)
+ } else {
+ alphabet += string(radix+54) + string(radix+86)
+ }
+ table = append(table, alphabet)
+ }
+ return table
+}()
+
+func digitValue(chr rune) int {
+ switch {
+ case '0' <= chr && chr <= '9':
+ return int(chr - '0')
+ case 'a' <= chr && chr <= 'z':
+ return int(chr - 'a' + 10)
+ case 'A' <= chr && chr <= 'Z':
+ return int(chr - 'A' + 10)
+ }
+ return 36 // Larger than any legal digit value
+}
+
+func builtinGlobal_parseInt(call FunctionCall) Value {
+ input := strings.TrimSpace(call.Argument(0).string())
+ if len(input) == 0 {
+ return NaNValue()
+ }
+
+ radix := int(toInt32(call.Argument(1)))
+
+ negative := false
+ switch input[0] {
+ case '+':
+ input = input[1:]
+ case '-':
+ negative = true
+ input = input[1:]
+ }
+
+ strip := true
+ if radix == 0 {
+ radix = 10
+ } else {
+ if radix < 2 || radix > 36 {
+ return NaNValue()
+ } else if radix != 16 {
+ strip = false
+ }
+ }
+
+ switch len(input) {
+ case 0:
+ return NaNValue()
+ case 1:
+ default:
+ if strip {
+ if input[0] == '0' && (input[1] == 'x' || input[1] == 'X') {
+ input = input[2:]
+ radix = 16
+ }
+ }
+ }
+
+ base := radix
+ index := 0
+ for ; index < len(input); index++ {
+ digit := digitValue(rune(input[index])) // If not ASCII, then an error anyway
+ if digit >= base {
+ break
+ }
+ }
+ input = input[0:index]
+
+ value, err := strconv.ParseInt(input, radix, 64)
+ if err != nil {
+ if err.(*strconv.NumError).Err == strconv.ErrRange {
+ base := float64(base)
+ // Could just be a very large number (e.g. 0x8000000000000000)
+ var value float64
+ for _, chr := range input {
+ digit := float64(digitValue(chr))
+ if digit >= base {
+ goto error
+ }
+ value = value*base + digit
+ }
+ if negative {
+ value *= -1
+ }
+ return toValue_float64(value)
+ }
+ error:
+ return NaNValue()
+ }
+ if negative {
+ value *= -1
+ }
+
+ return toValue_int64(value)
+}
+
+var parseFloat_matchBadSpecial = regexp.MustCompile(`[\+\-]?(?:[Ii]nf$|infinity)`)
+var parseFloat_matchValid = regexp.MustCompile(`[0-9eE\+\-\.]|Infinity`)
+
+func builtinGlobal_parseFloat(call FunctionCall) Value {
+ // Caveat emptor: This implementation does NOT match the specification
+ input := strings.TrimSpace(call.Argument(0).string())
+ if parseFloat_matchBadSpecial.MatchString(input) {
+ return NaNValue()
+ }
+ value, err := strconv.ParseFloat(input, 64)
+ if err != nil {
+ for end := len(input); end > 0; end -= 1 {
+ input := input[0:end]
+ if !parseFloat_matchValid.MatchString(input) {
+ return NaNValue()
+ }
+ value, err = strconv.ParseFloat(input, 64)
+ if err == nil {
+ break
+ }
+ }
+ if err != nil {
+ return NaNValue()
+ }
+ }
+ return toValue_float64(value)
+}
+
+// encodeURI/decodeURI
+
+func _builtinGlobal_encodeURI(call FunctionCall, escape *regexp.Regexp) Value {
+ value := call.Argument(0)
+ var input []uint16
+ switch vl := value.value.(type) {
+ case []uint16:
+ input = vl
+ default:
+ input = utf16.Encode([]rune(value.string()))
+ }
+ if len(input) == 0 {
+ return toValue_string("")
+ }
+ output := []byte{}
+ length := len(input)
+ encode := make([]byte, 4)
+ for index := 0; index < length; {
+ value := input[index]
+ decode := utf16.Decode(input[index : index+1])
+ if value >= 0xDC00 && value <= 0xDFFF {
+ panic(call.runtime.panicURIError("URI malformed"))
+ }
+ if value >= 0xD800 && value <= 0xDBFF {
+ index += 1
+ if index >= length {
+ panic(call.runtime.panicURIError("URI malformed"))
+ }
+ // input = ..., value, value1, ...
+ value1 := input[index]
+ if value1 < 0xDC00 || value1 > 0xDFFF {
+ panic(call.runtime.panicURIError("URI malformed"))
+ }
+ decode = []rune{((rune(value) - 0xD800) * 0x400) + (rune(value1) - 0xDC00) + 0x10000}
+ }
+ index += 1
+ size := utf8.EncodeRune(encode, decode[0])
+ encode := encode[0:size]
+ output = append(output, encode...)
+ }
+ {
+ value := escape.ReplaceAllFunc(output, func(target []byte) []byte {
+ // Probably a better way of doing this
+ if target[0] == ' ' {
+ return []byte("%20")
+ }
+ return []byte(url.QueryEscape(string(target)))
+ })
+ return toValue_string(string(value))
+ }
+}
+
+var encodeURI_Regexp = regexp.MustCompile(`([^~!@#$&*()=:/,;?+'])`)
+
+func builtinGlobal_encodeURI(call FunctionCall) Value {
+ return _builtinGlobal_encodeURI(call, encodeURI_Regexp)
+}
+
+var encodeURIComponent_Regexp = regexp.MustCompile(`([^~!*()'])`)
+
+func builtinGlobal_encodeURIComponent(call FunctionCall) Value {
+ return _builtinGlobal_encodeURI(call, encodeURIComponent_Regexp)
+}
+
+// 3B/2F/3F/3A/40/26/3D/2B/24/2C/23
+var decodeURI_guard = regexp.MustCompile(`(?i)(?:%)(3B|2F|3F|3A|40|26|3D|2B|24|2C|23)`)
+
+func _decodeURI(input string, reserve bool) (string, bool) {
+ if reserve {
+ input = decodeURI_guard.ReplaceAllString(input, "%25$1")
+ }
+ input = strings.Replace(input, "+", "%2B", -1) // Ugly hack to make QueryUnescape work with our use case
+ output, err := url.QueryUnescape(input)
+ if err != nil || !utf8.ValidString(output) {
+ return "", true
+ }
+ return output, false
+}
+
+func builtinGlobal_decodeURI(call FunctionCall) Value {
+ output, err := _decodeURI(call.Argument(0).string(), true)
+ if err {
+ panic(call.runtime.panicURIError("URI malformed"))
+ }
+ return toValue_string(output)
+}
+
+func builtinGlobal_decodeURIComponent(call FunctionCall) Value {
+ output, err := _decodeURI(call.Argument(0).string(), false)
+ if err {
+ panic(call.runtime.panicURIError("URI malformed"))
+ }
+ return toValue_string(output)
+}
+
+// escape/unescape
+
+func builtin_shouldEscape(chr byte) bool {
+ if 'A' <= chr && chr <= 'Z' || 'a' <= chr && chr <= 'z' || '0' <= chr && chr <= '9' {
+ return false
+ }
+ return !strings.ContainsRune("*_+-./", rune(chr))
+}
+
+const escapeBase16 = "0123456789ABCDEF"
+
+func builtin_escape(input string) string {
+ output := make([]byte, 0, len(input))
+ length := len(input)
+ for index := 0; index < length; {
+ if builtin_shouldEscape(input[index]) {
+ chr, width := utf8.DecodeRuneInString(input[index:])
+ chr16 := utf16.Encode([]rune{chr})[0]
+ if 256 > chr16 {
+ output = append(output, '%',
+ escapeBase16[chr16>>4],
+ escapeBase16[chr16&15],
+ )
+ } else {
+ output = append(output, '%', 'u',
+ escapeBase16[chr16>>12],
+ escapeBase16[(chr16>>8)&15],
+ escapeBase16[(chr16>>4)&15],
+ escapeBase16[chr16&15],
+ )
+ }
+ index += width
+
+ } else {
+ output = append(output, input[index])
+ index += 1
+ }
+ }
+ return string(output)
+}
+
+func builtin_unescape(input string) string {
+ output := make([]rune, 0, len(input))
+ length := len(input)
+ for index := 0; index < length; {
+ if input[index] == '%' {
+ if index <= length-6 && input[index+1] == 'u' {
+ byte16, err := hex.DecodeString(input[index+2 : index+6])
+ if err == nil {
+ value := uint16(byte16[0])<<8 + uint16(byte16[1])
+ chr := utf16.Decode([]uint16{value})[0]
+ output = append(output, chr)
+ index += 6
+ continue
+ }
+ }
+ if index <= length-3 {
+ byte8, err := hex.DecodeString(input[index+1 : index+3])
+ if err == nil {
+ value := uint16(byte8[0])
+ chr := utf16.Decode([]uint16{value})[0]
+ output = append(output, chr)
+ index += 3
+ continue
+ }
+ }
+ }
+ output = append(output, rune(input[index]))
+ index += 1
+ }
+ return string(output)
+}
+
+func builtinGlobal_escape(call FunctionCall) Value {
+ return toValue_string(builtin_escape(call.Argument(0).string()))
+}
+
+func builtinGlobal_unescape(call FunctionCall) Value {
+ return toValue_string(builtin_unescape(call.Argument(0).string()))
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/builtin_array.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/builtin_array.go
new file mode 100644
index 000000000..44bf88569
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/builtin_array.go
@@ -0,0 +1,672 @@
+package otto
+
+import (
+ "strconv"
+ "strings"
+)
+
+// Array
+
+func builtinArray(call FunctionCall) Value {
+ return toValue_object(builtinNewArrayNative(call.runtime, call.ArgumentList))
+}
+
+func builtinNewArray(self *_object, argumentList []Value) Value {
+ return toValue_object(builtinNewArrayNative(self.runtime, argumentList))
+}
+
+func builtinNewArrayNative(runtime *_runtime, argumentList []Value) *_object {
+ if len(argumentList) == 1 {
+ firstArgument := argumentList[0]
+ if firstArgument.IsNumber() {
+ return runtime.newArray(arrayUint32(runtime, firstArgument))
+ }
+ }
+ return runtime.newArrayOf(argumentList)
+}
+
+func builtinArray_toString(call FunctionCall) Value {
+ thisObject := call.thisObject()
+ join := thisObject.get("join")
+ if join.isCallable() {
+ join := join._object()
+ return join.call(call.This, call.ArgumentList, false, nativeFrame)
+ }
+ return builtinObject_toString(call)
+}
+
+func builtinArray_toLocaleString(call FunctionCall) Value {
+ separator := ","
+ thisObject := call.thisObject()
+ length := int64(toUint32(thisObject.get("length")))
+ if length == 0 {
+ return toValue_string("")
+ }
+ stringList := make([]string, 0, length)
+ for index := int64(0); index < length; index += 1 {
+ value := thisObject.get(arrayIndexToString(index))
+ stringValue := ""
+ switch value.kind {
+ case valueEmpty, valueUndefined, valueNull:
+ default:
+ object := call.runtime.toObject(value)
+ toLocaleString := object.get("toLocaleString")
+ if !toLocaleString.isCallable() {
+ panic(call.runtime.panicTypeError())
+ }
+ stringValue = toLocaleString.call(call.runtime, toValue_object(object)).string()
+ }
+ stringList = append(stringList, stringValue)
+ }
+ return toValue_string(strings.Join(stringList, separator))
+}
+
+func builtinArray_concat(call FunctionCall) Value {
+ thisObject := call.thisObject()
+ valueArray := []Value{}
+ source := append([]Value{toValue_object(thisObject)}, call.ArgumentList...)
+ for _, item := range source {
+ switch item.kind {
+ case valueObject:
+ object := item._object()
+ if isArray(object) {
+ length := object.get("length").number().int64
+ for index := int64(0); index < length; index += 1 {
+ name := strconv.FormatInt(index, 10)
+ if object.hasProperty(name) {
+ valueArray = append(valueArray, object.get(name))
+ } else {
+ valueArray = append(valueArray, Value{})
+ }
+ }
+ continue
+ }
+ fallthrough
+ default:
+ valueArray = append(valueArray, item)
+ }
+ }
+ return toValue_object(call.runtime.newArrayOf(valueArray))
+}
+
+func builtinArray_shift(call FunctionCall) Value {
+ thisObject := call.thisObject()
+ length := int64(toUint32(thisObject.get("length")))
+ if 0 == length {
+ thisObject.put("length", toValue_int64(0), true)
+ return Value{}
+ }
+ first := thisObject.get("0")
+ for index := int64(1); index < length; index++ {
+ from := arrayIndexToString(index)
+ to := arrayIndexToString(index - 1)
+ if thisObject.hasProperty(from) {
+ thisObject.put(to, thisObject.get(from), true)
+ } else {
+ thisObject.delete(to, true)
+ }
+ }
+ thisObject.delete(arrayIndexToString(length-1), true)
+ thisObject.put("length", toValue_int64(length-1), true)
+ return first
+}
+
+func builtinArray_push(call FunctionCall) Value {
+ thisObject := call.thisObject()
+ itemList := call.ArgumentList
+ index := int64(toUint32(thisObject.get("length")))
+ for len(itemList) > 0 {
+ thisObject.put(arrayIndexToString(index), itemList[0], true)
+ itemList = itemList[1:]
+ index += 1
+ }
+ length := toValue_int64(index)
+ thisObject.put("length", length, true)
+ return length
+}
+
+func builtinArray_pop(call FunctionCall) Value {
+ thisObject := call.thisObject()
+ length := int64(toUint32(thisObject.get("length")))
+ if 0 == length {
+ thisObject.put("length", toValue_uint32(0), true)
+ return Value{}
+ }
+ last := thisObject.get(arrayIndexToString(length - 1))
+ thisObject.delete(arrayIndexToString(length-1), true)
+ thisObject.put("length", toValue_int64(length-1), true)
+ return last
+}
+
+func builtinArray_join(call FunctionCall) Value {
+ separator := ","
+ {
+ argument := call.Argument(0)
+ if argument.IsDefined() {
+ separator = argument.string()
+ }
+ }
+ thisObject := call.thisObject()
+ length := int64(toUint32(thisObject.get("length")))
+ if length == 0 {
+ return toValue_string("")
+ }
+ stringList := make([]string, 0, length)
+ for index := int64(0); index < length; index += 1 {
+ value := thisObject.get(arrayIndexToString(index))
+ stringValue := ""
+ switch value.kind {
+ case valueEmpty, valueUndefined, valueNull:
+ default:
+ stringValue = value.string()
+ }
+ stringList = append(stringList, stringValue)
+ }
+ return toValue_string(strings.Join(stringList, separator))
+}
+
+func builtinArray_splice(call FunctionCall) Value {
+ thisObject := call.thisObject()
+ length := int64(toUint32(thisObject.get("length")))
+
+ start := valueToRangeIndex(call.Argument(0), length, false)
+ deleteCount := valueToRangeIndex(call.Argument(1), int64(length)-start, true)
+ valueArray := make([]Value, deleteCount)
+
+ for index := int64(0); index < deleteCount; index++ {
+ indexString := arrayIndexToString(int64(start + index))
+ if thisObject.hasProperty(indexString) {
+ valueArray[index] = thisObject.get(indexString)
+ }
+ }
+
+ // 0, <1, 2, 3, 4>, 5, 6, 7
+ // a, b
+ // length 8 - delete 4 @ start 1
+
+ itemList := []Value{}
+ itemCount := int64(len(call.ArgumentList))
+ if itemCount > 2 {
+ itemCount -= 2 // Less the first two arguments
+ itemList = call.ArgumentList[2:]
+ } else {
+ itemCount = 0
+ }
+ if itemCount < deleteCount {
+ // The Object/Array is shrinking
+ stop := int64(length) - deleteCount
+ // The new length of the Object/Array before
+ // appending the itemList remainder
+ // Stopping at the lower bound of the insertion:
+ // Move an item from the after the deleted portion
+ // to a position after the inserted portion
+ for index := start; index < stop; index++ {
+ from := arrayIndexToString(index + deleteCount) // Position just after deletion
+ to := arrayIndexToString(index + itemCount) // Position just after splice (insertion)
+ if thisObject.hasProperty(from) {
+ thisObject.put(to, thisObject.get(from), true)
+ } else {
+ thisObject.delete(to, true)
+ }
+ }
+ // Delete off the end
+ // We don't bother to delete below <stop + itemCount> (if any) since those
+ // will be overwritten anyway
+ for index := int64(length); index > (stop + itemCount); index-- {
+ thisObject.delete(arrayIndexToString(index-1), true)
+ }
+ } else if itemCount > deleteCount {
+ // The Object/Array is growing
+ // The itemCount is greater than the deleteCount, so we do
+ // not have to worry about overwriting what we should be moving
+ // ---
+ // Starting from the upper bound of the deletion:
+ // Move an item from the after the deleted portion
+ // to a position after the inserted portion
+ for index := int64(length) - deleteCount; index > start; index-- {
+ from := arrayIndexToString(index + deleteCount - 1)
+ to := arrayIndexToString(index + itemCount - 1)
+ if thisObject.hasProperty(from) {
+ thisObject.put(to, thisObject.get(from), true)
+ } else {
+ thisObject.delete(to, true)
+ }
+ }
+ }
+
+ for index := int64(0); index < itemCount; index++ {
+ thisObject.put(arrayIndexToString(index+start), itemList[index], true)
+ }
+ thisObject.put("length", toValue_int64(int64(length)+itemCount-deleteCount), true)
+
+ return toValue_object(call.runtime.newArrayOf(valueArray))
+}
+
+func builtinArray_slice(call FunctionCall) Value {
+ thisObject := call.thisObject()
+
+ length := int64(toUint32(thisObject.get("length")))
+ start, end := rangeStartEnd(call.ArgumentList, length, false)
+
+ if start >= end {
+ // Always an empty array
+ return toValue_object(call.runtime.newArray(0))
+ }
+ sliceLength := end - start
+ sliceValueArray := make([]Value, sliceLength)
+
+ for index := int64(0); index < sliceLength; index++ {
+ from := arrayIndexToString(index + start)
+ if thisObject.hasProperty(from) {
+ sliceValueArray[index] = thisObject.get(from)
+ }
+ }
+
+ return toValue_object(call.runtime.newArrayOf(sliceValueArray))
+}
+
+func builtinArray_unshift(call FunctionCall) Value {
+ thisObject := call.thisObject()
+ length := int64(toUint32(thisObject.get("length")))
+ itemList := call.ArgumentList
+ itemCount := int64(len(itemList))
+
+ for index := length; index > 0; index-- {
+ from := arrayIndexToString(index - 1)
+ to := arrayIndexToString(index + itemCount - 1)
+ if thisObject.hasProperty(from) {
+ thisObject.put(to, thisObject.get(from), true)
+ } else {
+ thisObject.delete(to, true)
+ }
+ }
+
+ for index := int64(0); index < itemCount; index++ {
+ thisObject.put(arrayIndexToString(index), itemList[index], true)
+ }
+
+ newLength := toValue_int64(length + itemCount)
+ thisObject.put("length", newLength, true)
+ return newLength
+}
+
+func builtinArray_reverse(call FunctionCall) Value {
+ thisObject := call.thisObject()
+ length := int64(toUint32(thisObject.get("length")))
+
+ lower := struct {
+ name string
+ index int64
+ exists bool
+ }{}
+ upper := lower
+
+ lower.index = 0
+ middle := length / 2 // Division will floor
+
+ for lower.index != middle {
+ lower.name = arrayIndexToString(lower.index)
+ upper.index = length - lower.index - 1
+ upper.name = arrayIndexToString(upper.index)
+
+ lower.exists = thisObject.hasProperty(lower.name)
+ upper.exists = thisObject.hasProperty(upper.name)
+
+ if lower.exists && upper.exists {
+ lowerValue := thisObject.get(lower.name)
+ upperValue := thisObject.get(upper.name)
+ thisObject.put(lower.name, upperValue, true)
+ thisObject.put(upper.name, lowerValue, true)
+ } else if !lower.exists && upper.exists {
+ value := thisObject.get(upper.name)
+ thisObject.delete(upper.name, true)
+ thisObject.put(lower.name, value, true)
+ } else if lower.exists && !upper.exists {
+ value := thisObject.get(lower.name)
+ thisObject.delete(lower.name, true)
+ thisObject.put(upper.name, value, true)
+ } else {
+ // Nothing happens.
+ }
+
+ lower.index += 1
+ }
+
+ return call.This
+}
+
+func sortCompare(thisObject *_object, index0, index1 uint, compare *_object) int {
+ j := struct {
+ name string
+ exists bool
+ defined bool
+ value string
+ }{}
+ k := j
+ j.name = arrayIndexToString(int64(index0))
+ j.exists = thisObject.hasProperty(j.name)
+ k.name = arrayIndexToString(int64(index1))
+ k.exists = thisObject.hasProperty(k.name)
+
+ if !j.exists && !k.exists {
+ return 0
+ } else if !j.exists {
+ return 1
+ } else if !k.exists {
+ return -1
+ }
+
+ x := thisObject.get(j.name)
+ y := thisObject.get(k.name)
+ j.defined = x.IsDefined()
+ k.defined = y.IsDefined()
+
+ if !j.defined && !k.defined {
+ return 0
+ } else if !j.defined {
+ return 1
+ } else if !k.defined {
+ return -1
+ }
+
+ if compare == nil {
+ j.value = x.string()
+ k.value = y.string()
+
+ if j.value == k.value {
+ return 0
+ } else if j.value < k.value {
+ return -1
+ }
+
+ return 1
+ }
+
+ return int(toInt32(compare.call(Value{}, []Value{x, y}, false, nativeFrame)))
+}
+
+func arraySortSwap(thisObject *_object, index0, index1 uint) {
+
+ j := struct {
+ name string
+ exists bool
+ }{}
+ k := j
+
+ j.name = arrayIndexToString(int64(index0))
+ j.exists = thisObject.hasProperty(j.name)
+ k.name = arrayIndexToString(int64(index1))
+ k.exists = thisObject.hasProperty(k.name)
+
+ if j.exists && k.exists {
+ jValue := thisObject.get(j.name)
+ kValue := thisObject.get(k.name)
+ thisObject.put(j.name, kValue, true)
+ thisObject.put(k.name, jValue, true)
+ } else if !j.exists && k.exists {
+ value := thisObject.get(k.name)
+ thisObject.delete(k.name, true)
+ thisObject.put(j.name, value, true)
+ } else if j.exists && !k.exists {
+ value := thisObject.get(j.name)
+ thisObject.delete(j.name, true)
+ thisObject.put(k.name, value, true)
+ } else {
+ // Nothing happens.
+ }
+}
+
+func arraySortQuickPartition(thisObject *_object, left, right, pivot uint, compare *_object) uint {
+ arraySortSwap(thisObject, pivot, right) // Right is now the pivot value
+ cursor := left
+ for index := left; index < right; index++ {
+ if sortCompare(thisObject, index, right, compare) == -1 { // Compare to the pivot value
+ arraySortSwap(thisObject, index, cursor)
+ cursor += 1
+ }
+ }
+ arraySortSwap(thisObject, cursor, right)
+ return cursor
+}
+
+func arraySortQuickSort(thisObject *_object, left, right uint, compare *_object) {
+ if left < right {
+ pivot := left + (right-left)/2
+ pivot = arraySortQuickPartition(thisObject, left, right, pivot, compare)
+ if pivot > 0 {
+ arraySortQuickSort(thisObject, left, pivot-1, compare)
+ }
+ arraySortQuickSort(thisObject, pivot+1, right, compare)
+ }
+}
+
+func builtinArray_sort(call FunctionCall) Value {
+ thisObject := call.thisObject()
+ length := uint(toUint32(thisObject.get("length")))
+ compareValue := call.Argument(0)
+ compare := compareValue._object()
+ if compareValue.IsUndefined() {
+ } else if !compareValue.isCallable() {
+ panic(call.runtime.panicTypeError())
+ }
+ if length > 1 {
+ arraySortQuickSort(thisObject, 0, length-1, compare)
+ }
+ return call.This
+}
+
+func builtinArray_isArray(call FunctionCall) Value {
+ return toValue_bool(isArray(call.Argument(0)._object()))
+}
+
+func builtinArray_indexOf(call FunctionCall) Value {
+ thisObject, matchValue := call.thisObject(), call.Argument(0)
+ if length := int64(toUint32(thisObject.get("length"))); length > 0 {
+ index := int64(0)
+ if len(call.ArgumentList) > 1 {
+ index = call.Argument(1).number().int64
+ }
+ if index < 0 {
+ if index += length; index < 0 {
+ index = 0
+ }
+ } else if index >= length {
+ index = -1
+ }
+ for ; index >= 0 && index < length; index++ {
+ name := arrayIndexToString(int64(index))
+ if !thisObject.hasProperty(name) {
+ continue
+ }
+ value := thisObject.get(name)
+ if strictEqualityComparison(matchValue, value) {
+ return toValue_uint32(uint32(index))
+ }
+ }
+ }
+ return toValue_int(-1)
+}
+
+func builtinArray_lastIndexOf(call FunctionCall) Value {
+ thisObject, matchValue := call.thisObject(), call.Argument(0)
+ length := int64(toUint32(thisObject.get("length")))
+ index := length - 1
+ if len(call.ArgumentList) > 1 {
+ index = call.Argument(1).number().int64
+ }
+ if 0 > index {
+ index += length
+ }
+ if index > length {
+ index = length - 1
+ } else if 0 > index {
+ return toValue_int(-1)
+ }
+ for ; index >= 0; index-- {
+ name := arrayIndexToString(int64(index))
+ if !thisObject.hasProperty(name) {
+ continue
+ }
+ value := thisObject.get(name)
+ if strictEqualityComparison(matchValue, value) {
+ return toValue_uint32(uint32(index))
+ }
+ }
+ return toValue_int(-1)
+}
+
+func builtinArray_every(call FunctionCall) Value {
+ thisObject := call.thisObject()
+ this := toValue_object(thisObject)
+ if iterator := call.Argument(0); iterator.isCallable() {
+ length := int64(toUint32(thisObject.get("length")))
+ callThis := call.Argument(1)
+ for index := int64(0); index < length; index++ {
+ if key := arrayIndexToString(index); thisObject.hasProperty(key) {
+ if value := thisObject.get(key); iterator.call(call.runtime, callThis, value, toValue_int64(index), this).bool() {
+ continue
+ }
+ return falseValue
+ }
+ }
+ return trueValue
+ }
+ panic(call.runtime.panicTypeError())
+}
+
+func builtinArray_some(call FunctionCall) Value {
+ thisObject := call.thisObject()
+ this := toValue_object(thisObject)
+ if iterator := call.Argument(0); iterator.isCallable() {
+ length := int64(toUint32(thisObject.get("length")))
+ callThis := call.Argument(1)
+ for index := int64(0); index < length; index++ {
+ if key := arrayIndexToString(index); thisObject.hasProperty(key) {
+ if value := thisObject.get(key); iterator.call(call.runtime, callThis, value, toValue_int64(index), this).bool() {
+ return trueValue
+ }
+ }
+ }
+ return falseValue
+ }
+ panic(call.runtime.panicTypeError())
+}
+
+func builtinArray_forEach(call FunctionCall) Value {
+ thisObject := call.thisObject()
+ this := toValue_object(thisObject)
+ if iterator := call.Argument(0); iterator.isCallable() {
+ length := int64(toUint32(thisObject.get("length")))
+ callThis := call.Argument(1)
+ for index := int64(0); index < length; index++ {
+ if key := arrayIndexToString(index); thisObject.hasProperty(key) {
+ iterator.call(call.runtime, callThis, thisObject.get(key), toValue_int64(index), this)
+ }
+ }
+ return Value{}
+ }
+ panic(call.runtime.panicTypeError())
+}
+
+func builtinArray_map(call FunctionCall) Value {
+ thisObject := call.thisObject()
+ this := toValue_object(thisObject)
+ if iterator := call.Argument(0); iterator.isCallable() {
+ length := int64(toUint32(thisObject.get("length")))
+ callThis := call.Argument(1)
+ values := make([]Value, length)
+ for index := int64(0); index < length; index++ {
+ if key := arrayIndexToString(index); thisObject.hasProperty(key) {
+ values[index] = iterator.call(call.runtime, callThis, thisObject.get(key), index, this)
+ } else {
+ values[index] = Value{}
+ }
+ }
+ return toValue_object(call.runtime.newArrayOf(values))
+ }
+ panic(call.runtime.panicTypeError())
+}
+
+func builtinArray_filter(call FunctionCall) Value {
+ thisObject := call.thisObject()
+ this := toValue_object(thisObject)
+ if iterator := call.Argument(0); iterator.isCallable() {
+ length := int64(toUint32(thisObject.get("length")))
+ callThis := call.Argument(1)
+ values := make([]Value, 0)
+ for index := int64(0); index < length; index++ {
+ if key := arrayIndexToString(index); thisObject.hasProperty(key) {
+ value := thisObject.get(key)
+ if iterator.call(call.runtime, callThis, value, index, this).bool() {
+ values = append(values, value)
+ }
+ }
+ }
+ return toValue_object(call.runtime.newArrayOf(values))
+ }
+ panic(call.runtime.panicTypeError())
+}
+
+func builtinArray_reduce(call FunctionCall) Value {
+ thisObject := call.thisObject()
+ this := toValue_object(thisObject)
+ if iterator := call.Argument(0); iterator.isCallable() {
+ initial := len(call.ArgumentList) > 1
+ start := call.Argument(1)
+ length := int64(toUint32(thisObject.get("length")))
+ index := int64(0)
+ if length > 0 || initial {
+ var accumulator Value
+ if !initial {
+ for ; index < length; index++ {
+ if key := arrayIndexToString(index); thisObject.hasProperty(key) {
+ accumulator = thisObject.get(key)
+ index++
+ break
+ }
+ }
+ } else {
+ accumulator = start
+ }
+ for ; index < length; index++ {
+ if key := arrayIndexToString(index); thisObject.hasProperty(key) {
+ accumulator = iterator.call(call.runtime, Value{}, accumulator, thisObject.get(key), key, this)
+ }
+ }
+ return accumulator
+ }
+ }
+ panic(call.runtime.panicTypeError())
+}
+
+func builtinArray_reduceRight(call FunctionCall) Value {
+ thisObject := call.thisObject()
+ this := toValue_object(thisObject)
+ if iterator := call.Argument(0); iterator.isCallable() {
+ initial := len(call.ArgumentList) > 1
+ start := call.Argument(1)
+ length := int64(toUint32(thisObject.get("length")))
+ if length > 0 || initial {
+ index := length - 1
+ var accumulator Value
+ if !initial {
+ for ; index >= 0; index-- {
+ if key := arrayIndexToString(index); thisObject.hasProperty(key) {
+ accumulator = thisObject.get(key)
+ index -= 1
+ break
+ }
+ }
+ } else {
+ accumulator = start
+ }
+ for ; index >= 0; index-- {
+ if key := arrayIndexToString(index); thisObject.hasProperty(key) {
+ accumulator = iterator.call(call.runtime, Value{}, accumulator, thisObject.get(key), key, this)
+ }
+ }
+ return accumulator
+ }
+ }
+ panic(call.runtime.panicTypeError())
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/builtin_boolean.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/builtin_boolean.go
new file mode 100644
index 000000000..59b8e789b
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/builtin_boolean.go
@@ -0,0 +1,28 @@
+package otto
+
+// Boolean
+
+func builtinBoolean(call FunctionCall) Value {
+ return toValue_bool(call.Argument(0).bool())
+}
+
+func builtinNewBoolean(self *_object, argumentList []Value) Value {
+ return toValue_object(self.runtime.newBoolean(valueOfArrayIndex(argumentList, 0)))
+}
+
+func builtinBoolean_toString(call FunctionCall) Value {
+ value := call.This
+ if !value.IsBoolean() {
+ // Will throw a TypeError if ThisObject is not a Boolean
+ value = call.thisClassObject("Boolean").primitiveValue()
+ }
+ return toValue_string(value.string())
+}
+
+func builtinBoolean_valueOf(call FunctionCall) Value {
+ value := call.This
+ if !value.IsBoolean() {
+ value = call.thisClassObject("Boolean").primitiveValue()
+ }
+ return value
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/builtin_date.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/builtin_date.go
new file mode 100644
index 000000000..f20bf8e3f
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/builtin_date.go
@@ -0,0 +1,615 @@
+package otto
+
+import (
+ "math"
+ Time "time"
+)
+
+// Date
+
+const (
+ // TODO Be like V8?
+ // builtinDate_goDateTimeLayout = "Mon Jan 2 2006 15:04:05 GMT-0700 (MST)"
+ builtinDate_goDateTimeLayout = Time.RFC1123 // "Mon, 02 Jan 2006 15:04:05 MST"
+ builtinDate_goDateLayout = "Mon, 02 Jan 2006"
+ builtinDate_goTimeLayout = "15:04:05 MST"
+)
+
+func builtinDate(call FunctionCall) Value {
+ date := &_dateObject{}
+ date.Set(newDateTime([]Value{}, Time.Local))
+ return toValue_string(date.Time().Format(builtinDate_goDateTimeLayout))
+}
+
+func builtinNewDate(self *_object, argumentList []Value) Value {
+ return toValue_object(self.runtime.newDate(newDateTime(argumentList, Time.Local)))
+}
+
+func builtinDate_toString(call FunctionCall) Value {
+ date := dateObjectOf(call.runtime, call.thisObject())
+ if date.isNaN {
+ return toValue_string("Invalid Date")
+ }
+ return toValue_string(date.Time().Local().Format(builtinDate_goDateTimeLayout))
+}
+
+func builtinDate_toDateString(call FunctionCall) Value {
+ date := dateObjectOf(call.runtime, call.thisObject())
+ if date.isNaN {
+ return toValue_string("Invalid Date")
+ }
+ return toValue_string(date.Time().Local().Format(builtinDate_goDateLayout))
+}
+
+func builtinDate_toTimeString(call FunctionCall) Value {
+ date := dateObjectOf(call.runtime, call.thisObject())
+ if date.isNaN {
+ return toValue_string("Invalid Date")
+ }
+ return toValue_string(date.Time().Local().Format(builtinDate_goTimeLayout))
+}
+
+func builtinDate_toUTCString(call FunctionCall) Value {
+ date := dateObjectOf(call.runtime, call.thisObject())
+ if date.isNaN {
+ return toValue_string("Invalid Date")
+ }
+ return toValue_string(date.Time().Format(builtinDate_goDateTimeLayout))
+}
+
+func builtinDate_toISOString(call FunctionCall) Value {
+ date := dateObjectOf(call.runtime, call.thisObject())
+ if date.isNaN {
+ return toValue_string("Invalid Date")
+ }
+ return toValue_string(date.Time().Format("2006-01-02T15:04:05.000Z"))
+}
+
+func builtinDate_toJSON(call FunctionCall) Value {
+ object := call.thisObject()
+ value := object.DefaultValue(defaultValueHintNumber) // FIXME object.primitiveNumberValue
+ { // FIXME value.isFinite
+ value := value.float64()
+ if math.IsNaN(value) || math.IsInf(value, 0) {
+ return nullValue
+ }
+ }
+ toISOString := object.get("toISOString")
+ if !toISOString.isCallable() {
+ // FIXME
+ panic(call.runtime.panicTypeError())
+ }
+ return toISOString.call(call.runtime, toValue_object(object), []Value{})
+}
+
+func builtinDate_toGMTString(call FunctionCall) Value {
+ date := dateObjectOf(call.runtime, call.thisObject())
+ if date.isNaN {
+ return toValue_string("Invalid Date")
+ }
+ return toValue_string(date.Time().Format("Mon, 02 Jan 2006 15:04:05 GMT"))
+}
+
+func builtinDate_getTime(call FunctionCall) Value {
+ date := dateObjectOf(call.runtime, call.thisObject())
+ if date.isNaN {
+ return NaNValue()
+ }
+ // We do this (convert away from a float) so the user
+ // does not get something back in exponential notation
+ return toValue_int64(int64(date.Epoch()))
+}
+
+func builtinDate_setTime(call FunctionCall) Value {
+ object := call.thisObject()
+ date := dateObjectOf(call.runtime, call.thisObject())
+ date.Set(call.Argument(0).float64())
+ object.value = date
+ return date.Value()
+}
+
+func _builtinDate_beforeSet(call FunctionCall, argumentLimit int, timeLocal bool) (*_object, *_dateObject, *_ecmaTime, []int) {
+ object := call.thisObject()
+ date := dateObjectOf(call.runtime, call.thisObject())
+ if date.isNaN {
+ return nil, nil, nil, nil
+ }
+
+ if argumentLimit > len(call.ArgumentList) {
+ argumentLimit = len(call.ArgumentList)
+ }
+
+ if argumentLimit == 0 {
+ object.value = invalidDateObject
+ return nil, nil, nil, nil
+ }
+
+ valueList := make([]int, argumentLimit)
+ for index := 0; index < argumentLimit; index++ {
+ value := call.ArgumentList[index]
+ nm := value.number()
+ switch nm.kind {
+ case numberInteger, numberFloat:
+ default:
+ object.value = invalidDateObject
+ return nil, nil, nil, nil
+ }
+ valueList[index] = int(nm.int64)
+ }
+ baseTime := date.Time()
+ if timeLocal {
+ baseTime = baseTime.Local()
+ }
+ ecmaTime := ecmaTime(baseTime)
+ return object, &date, &ecmaTime, valueList
+}
+
+func builtinDate_parse(call FunctionCall) Value {
+ date := call.Argument(0).string()
+ return toValue_float64(dateParse(date))
+}
+
+func builtinDate_UTC(call FunctionCall) Value {
+ return toValue_float64(newDateTime(call.ArgumentList, Time.UTC))
+}
+
+func builtinDate_now(call FunctionCall) Value {
+ call.ArgumentList = []Value(nil)
+ return builtinDate_UTC(call)
+}
+
+// This is a placeholder
+func builtinDate_toLocaleString(call FunctionCall) Value {
+ date := dateObjectOf(call.runtime, call.thisObject())
+ if date.isNaN {
+ return toValue_string("Invalid Date")
+ }
+ return toValue_string(date.Time().Local().Format("2006-01-02 15:04:05"))
+}
+
+// This is a placeholder
+func builtinDate_toLocaleDateString(call FunctionCall) Value {
+ date := dateObjectOf(call.runtime, call.thisObject())
+ if date.isNaN {
+ return toValue_string("Invalid Date")
+ }
+ return toValue_string(date.Time().Local().Format("2006-01-02"))
+}
+
+// This is a placeholder
+func builtinDate_toLocaleTimeString(call FunctionCall) Value {
+ date := dateObjectOf(call.runtime, call.thisObject())
+ if date.isNaN {
+ return toValue_string("Invalid Date")
+ }
+ return toValue_string(date.Time().Local().Format("15:04:05"))
+}
+
+func builtinDate_valueOf(call FunctionCall) Value {
+ date := dateObjectOf(call.runtime, call.thisObject())
+ if date.isNaN {
+ return NaNValue()
+ }
+ return date.Value()
+}
+
+func builtinDate_getYear(call FunctionCall) Value {
+ // Will throw a TypeError is ThisObject is nil or
+ // does not have Class of "Date"
+ date := dateObjectOf(call.runtime, call.thisObject())
+ if date.isNaN {
+ return NaNValue()
+ }
+ return toValue_int(date.Time().Local().Year() - 1900)
+}
+
+func builtinDate_getFullYear(call FunctionCall) Value {
+ // Will throw a TypeError is ThisObject is nil or
+ // does not have Class of "Date"
+ date := dateObjectOf(call.runtime, call.thisObject())
+ if date.isNaN {
+ return NaNValue()
+ }
+ return toValue_int(date.Time().Local().Year())
+}
+
+func builtinDate_getUTCFullYear(call FunctionCall) Value {
+ date := dateObjectOf(call.runtime, call.thisObject())
+ if date.isNaN {
+ return NaNValue()
+ }
+ return toValue_int(date.Time().Year())
+}
+
+func builtinDate_getMonth(call FunctionCall) Value {
+ date := dateObjectOf(call.runtime, call.thisObject())
+ if date.isNaN {
+ return NaNValue()
+ }
+ return toValue_int(dateFromGoMonth(date.Time().Local().Month()))
+}
+
+func builtinDate_getUTCMonth(call FunctionCall) Value {
+ date := dateObjectOf(call.runtime, call.thisObject())
+ if date.isNaN {
+ return NaNValue()
+ }
+ return toValue_int(dateFromGoMonth(date.Time().Month()))
+}
+
+func builtinDate_getDate(call FunctionCall) Value {
+ date := dateObjectOf(call.runtime, call.thisObject())
+ if date.isNaN {
+ return NaNValue()
+ }
+ return toValue_int(date.Time().Local().Day())
+}
+
+func builtinDate_getUTCDate(call FunctionCall) Value {
+ date := dateObjectOf(call.runtime, call.thisObject())
+ if date.isNaN {
+ return NaNValue()
+ }
+ return toValue_int(date.Time().Day())
+}
+
+func builtinDate_getDay(call FunctionCall) Value {
+ // Actually day of the week
+ date := dateObjectOf(call.runtime, call.thisObject())
+ if date.isNaN {
+ return NaNValue()
+ }
+ return toValue_int(dateFromGoDay(date.Time().Local().Weekday()))
+}
+
+func builtinDate_getUTCDay(call FunctionCall) Value {
+ date := dateObjectOf(call.runtime, call.thisObject())
+ if date.isNaN {
+ return NaNValue()
+ }
+ return toValue_int(dateFromGoDay(date.Time().Weekday()))
+}
+
+func builtinDate_getHours(call FunctionCall) Value {
+ date := dateObjectOf(call.runtime, call.thisObject())
+ if date.isNaN {
+ return NaNValue()
+ }
+ return toValue_int(date.Time().Local().Hour())
+}
+
+func builtinDate_getUTCHours(call FunctionCall) Value {
+ date := dateObjectOf(call.runtime, call.thisObject())
+ if date.isNaN {
+ return NaNValue()
+ }
+ return toValue_int(date.Time().Hour())
+}
+
+func builtinDate_getMinutes(call FunctionCall) Value {
+ date := dateObjectOf(call.runtime, call.thisObject())
+ if date.isNaN {
+ return NaNValue()
+ }
+ return toValue_int(date.Time().Local().Minute())
+}
+
+func builtinDate_getUTCMinutes(call FunctionCall) Value {
+ date := dateObjectOf(call.runtime, call.thisObject())
+ if date.isNaN {
+ return NaNValue()
+ }
+ return toValue_int(date.Time().Minute())
+}
+
+func builtinDate_getSeconds(call FunctionCall) Value {
+ date := dateObjectOf(call.runtime, call.thisObject())
+ if date.isNaN {
+ return NaNValue()
+ }
+ return toValue_int(date.Time().Local().Second())
+}
+
+func builtinDate_getUTCSeconds(call FunctionCall) Value {
+ date := dateObjectOf(call.runtime, call.thisObject())
+ if date.isNaN {
+ return NaNValue()
+ }
+ return toValue_int(date.Time().Second())
+}
+
+func builtinDate_getMilliseconds(call FunctionCall) Value {
+ date := dateObjectOf(call.runtime, call.thisObject())
+ if date.isNaN {
+ return NaNValue()
+ }
+ return toValue_int(date.Time().Local().Nanosecond() / (100 * 100 * 100))
+}
+
+func builtinDate_getUTCMilliseconds(call FunctionCall) Value {
+ date := dateObjectOf(call.runtime, call.thisObject())
+ if date.isNaN {
+ return NaNValue()
+ }
+ return toValue_int(date.Time().Nanosecond() / (100 * 100 * 100))
+}
+
+func builtinDate_getTimezoneOffset(call FunctionCall) Value {
+ date := dateObjectOf(call.runtime, call.thisObject())
+ if date.isNaN {
+ return NaNValue()
+ }
+ timeLocal := date.Time().Local()
+ // Is this kosher?
+ timeLocalAsUTC := Time.Date(
+ timeLocal.Year(),
+ timeLocal.Month(),
+ timeLocal.Day(),
+ timeLocal.Hour(),
+ timeLocal.Minute(),
+ timeLocal.Second(),
+ timeLocal.Nanosecond(),
+ Time.UTC,
+ )
+ return toValue_float64(date.Time().Sub(timeLocalAsUTC).Seconds() / 60)
+}
+
+func builtinDate_setMilliseconds(call FunctionCall) Value {
+ object, date, ecmaTime, value := _builtinDate_beforeSet(call, 1, true)
+ if ecmaTime == nil {
+ return NaNValue()
+ }
+
+ ecmaTime.millisecond = value[0]
+
+ date.SetTime(ecmaTime.goTime())
+ object.value = *date
+ return date.Value()
+}
+
+func builtinDate_setUTCMilliseconds(call FunctionCall) Value {
+ object, date, ecmaTime, value := _builtinDate_beforeSet(call, 1, false)
+ if ecmaTime == nil {
+ return NaNValue()
+ }
+
+ ecmaTime.millisecond = value[0]
+
+ date.SetTime(ecmaTime.goTime())
+ object.value = *date
+ return date.Value()
+}
+
+func builtinDate_setSeconds(call FunctionCall) Value {
+ object, date, ecmaTime, value := _builtinDate_beforeSet(call, 2, true)
+ if ecmaTime == nil {
+ return NaNValue()
+ }
+
+ if len(value) > 1 {
+ ecmaTime.millisecond = value[1]
+ }
+ ecmaTime.second = value[0]
+
+ date.SetTime(ecmaTime.goTime())
+ object.value = *date
+ return date.Value()
+}
+
+func builtinDate_setUTCSeconds(call FunctionCall) Value {
+ object, date, ecmaTime, value := _builtinDate_beforeSet(call, 2, false)
+ if ecmaTime == nil {
+ return NaNValue()
+ }
+
+ if len(value) > 1 {
+ ecmaTime.millisecond = value[1]
+ }
+ ecmaTime.second = value[0]
+
+ date.SetTime(ecmaTime.goTime())
+ object.value = *date
+ return date.Value()
+}
+
+func builtinDate_setMinutes(call FunctionCall) Value {
+ object, date, ecmaTime, value := _builtinDate_beforeSet(call, 3, true)
+ if ecmaTime == nil {
+ return NaNValue()
+ }
+
+ if len(value) > 2 {
+ ecmaTime.millisecond = value[2]
+ ecmaTime.second = value[1]
+ } else if len(value) > 1 {
+ ecmaTime.second = value[1]
+ }
+ ecmaTime.minute = value[0]
+
+ date.SetTime(ecmaTime.goTime())
+ object.value = *date
+ return date.Value()
+}
+
+func builtinDate_setUTCMinutes(call FunctionCall) Value {
+ object, date, ecmaTime, value := _builtinDate_beforeSet(call, 3, false)
+ if ecmaTime == nil {
+ return NaNValue()
+ }
+
+ if len(value) > 2 {
+ ecmaTime.millisecond = value[2]
+ ecmaTime.second = value[1]
+ } else if len(value) > 1 {
+ ecmaTime.second = value[1]
+ }
+ ecmaTime.minute = value[0]
+
+ date.SetTime(ecmaTime.goTime())
+ object.value = *date
+ return date.Value()
+}
+
+func builtinDate_setHours(call FunctionCall) Value {
+ object, date, ecmaTime, value := _builtinDate_beforeSet(call, 4, true)
+ if ecmaTime == nil {
+ return NaNValue()
+ }
+
+ if len(value) > 3 {
+ ecmaTime.millisecond = value[3]
+ ecmaTime.second = value[2]
+ ecmaTime.minute = value[1]
+ } else if len(value) > 2 {
+ ecmaTime.second = value[2]
+ ecmaTime.minute = value[1]
+ } else if len(value) > 1 {
+ ecmaTime.minute = value[1]
+ }
+ ecmaTime.hour = value[0]
+
+ date.SetTime(ecmaTime.goTime())
+ object.value = *date
+ return date.Value()
+}
+
+func builtinDate_setUTCHours(call FunctionCall) Value {
+ object, date, ecmaTime, value := _builtinDate_beforeSet(call, 4, false)
+ if ecmaTime == nil {
+ return NaNValue()
+ }
+
+ if len(value) > 3 {
+ ecmaTime.millisecond = value[3]
+ ecmaTime.second = value[2]
+ ecmaTime.minute = value[1]
+ } else if len(value) > 2 {
+ ecmaTime.second = value[2]
+ ecmaTime.minute = value[1]
+ } else if len(value) > 1 {
+ ecmaTime.minute = value[1]
+ }
+ ecmaTime.hour = value[0]
+
+ date.SetTime(ecmaTime.goTime())
+ object.value = *date
+ return date.Value()
+}
+
+func builtinDate_setDate(call FunctionCall) Value {
+ object, date, ecmaTime, value := _builtinDate_beforeSet(call, 1, true)
+ if ecmaTime == nil {
+ return NaNValue()
+ }
+
+ ecmaTime.day = value[0]
+
+ date.SetTime(ecmaTime.goTime())
+ object.value = *date
+ return date.Value()
+}
+
+func builtinDate_setUTCDate(call FunctionCall) Value {
+ object, date, ecmaTime, value := _builtinDate_beforeSet(call, 1, false)
+ if ecmaTime == nil {
+ return NaNValue()
+ }
+
+ ecmaTime.day = value[0]
+
+ date.SetTime(ecmaTime.goTime())
+ object.value = *date
+ return date.Value()
+}
+
+func builtinDate_setMonth(call FunctionCall) Value {
+ object, date, ecmaTime, value := _builtinDate_beforeSet(call, 2, true)
+ if ecmaTime == nil {
+ return NaNValue()
+ }
+
+ if len(value) > 1 {
+ ecmaTime.day = value[1]
+ }
+ ecmaTime.month = value[0]
+
+ date.SetTime(ecmaTime.goTime())
+ object.value = *date
+ return date.Value()
+}
+
+func builtinDate_setUTCMonth(call FunctionCall) Value {
+ object, date, ecmaTime, value := _builtinDate_beforeSet(call, 2, false)
+ if ecmaTime == nil {
+ return NaNValue()
+ }
+
+ if len(value) > 1 {
+ ecmaTime.day = value[1]
+ }
+ ecmaTime.month = value[0]
+
+ date.SetTime(ecmaTime.goTime())
+ object.value = *date
+ return date.Value()
+}
+
+func builtinDate_setYear(call FunctionCall) Value {
+ object, date, ecmaTime, value := _builtinDate_beforeSet(call, 1, true)
+ if ecmaTime == nil {
+ return NaNValue()
+ }
+
+ year := value[0]
+ if 0 <= year && year <= 99 {
+ year += 1900
+ }
+ ecmaTime.year = year
+
+ date.SetTime(ecmaTime.goTime())
+ object.value = *date
+ return date.Value()
+}
+
+func builtinDate_setFullYear(call FunctionCall) Value {
+ object, date, ecmaTime, value := _builtinDate_beforeSet(call, 3, true)
+ if ecmaTime == nil {
+ return NaNValue()
+ }
+
+ if len(value) > 2 {
+ ecmaTime.day = value[2]
+ ecmaTime.month = value[1]
+ } else if len(value) > 1 {
+ ecmaTime.month = value[1]
+ }
+ ecmaTime.year = value[0]
+
+ date.SetTime(ecmaTime.goTime())
+ object.value = *date
+ return date.Value()
+}
+
+func builtinDate_setUTCFullYear(call FunctionCall) Value {
+ object, date, ecmaTime, value := _builtinDate_beforeSet(call, 3, false)
+ if ecmaTime == nil {
+ return NaNValue()
+ }
+
+ if len(value) > 2 {
+ ecmaTime.day = value[2]
+ ecmaTime.month = value[1]
+ } else if len(value) > 1 {
+ ecmaTime.month = value[1]
+ }
+ ecmaTime.year = value[0]
+
+ date.SetTime(ecmaTime.goTime())
+ object.value = *date
+ return date.Value()
+}
+
+// toUTCString
+// toISOString
+// toJSONString
+// toJSON
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/builtin_error.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/builtin_error.go
new file mode 100644
index 000000000..4c054fbea
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/builtin_error.go
@@ -0,0 +1,126 @@
+package otto
+
+import (
+ "fmt"
+)
+
+func builtinError(call FunctionCall) Value {
+ return toValue_object(call.runtime.newError("", call.Argument(0)))
+}
+
+func builtinNewError(self *_object, argumentList []Value) Value {
+ return toValue_object(self.runtime.newError("", valueOfArrayIndex(argumentList, 0)))
+}
+
+func builtinError_toString(call FunctionCall) Value {
+ thisObject := call.thisObject()
+ if thisObject == nil {
+ panic(call.runtime.panicTypeError())
+ }
+
+ name := "Error"
+ nameValue := thisObject.get("name")
+ if nameValue.IsDefined() {
+ name = nameValue.string()
+ }
+
+ message := ""
+ messageValue := thisObject.get("message")
+ if messageValue.IsDefined() {
+ message = messageValue.string()
+ }
+
+ if len(name) == 0 {
+ return toValue_string(message)
+ }
+
+ if len(message) == 0 {
+ return toValue_string(name)
+ }
+
+ return toValue_string(fmt.Sprintf("%s: %s", name, message))
+}
+
+func (runtime *_runtime) newEvalError(message Value) *_object {
+ self := runtime.newErrorObject("EvalError", message)
+ self.prototype = runtime.global.EvalErrorPrototype
+ return self
+}
+
+func builtinEvalError(call FunctionCall) Value {
+ return toValue_object(call.runtime.newEvalError(call.Argument(0)))
+}
+
+func builtinNewEvalError(self *_object, argumentList []Value) Value {
+ return toValue_object(self.runtime.newEvalError(valueOfArrayIndex(argumentList, 0)))
+}
+
+func (runtime *_runtime) newTypeError(message Value) *_object {
+ self := runtime.newErrorObject("TypeError", message)
+ self.prototype = runtime.global.TypeErrorPrototype
+ return self
+}
+
+func builtinTypeError(call FunctionCall) Value {
+ return toValue_object(call.runtime.newTypeError(call.Argument(0)))
+}
+
+func builtinNewTypeError(self *_object, argumentList []Value) Value {
+ return toValue_object(self.runtime.newTypeError(valueOfArrayIndex(argumentList, 0)))
+}
+
+func (runtime *_runtime) newRangeError(message Value) *_object {
+ self := runtime.newErrorObject("RangeError", message)
+ self.prototype = runtime.global.RangeErrorPrototype
+ return self
+}
+
+func builtinRangeError(call FunctionCall) Value {
+ return toValue_object(call.runtime.newRangeError(call.Argument(0)))
+}
+
+func builtinNewRangeError(self *_object, argumentList []Value) Value {
+ return toValue_object(self.runtime.newRangeError(valueOfArrayIndex(argumentList, 0)))
+}
+
+func (runtime *_runtime) newURIError(message Value) *_object {
+ self := runtime.newErrorObject("URIError", message)
+ self.prototype = runtime.global.URIErrorPrototype
+ return self
+}
+
+func (runtime *_runtime) newReferenceError(message Value) *_object {
+ self := runtime.newErrorObject("ReferenceError", message)
+ self.prototype = runtime.global.ReferenceErrorPrototype
+ return self
+}
+
+func builtinReferenceError(call FunctionCall) Value {
+ return toValue_object(call.runtime.newReferenceError(call.Argument(0)))
+}
+
+func builtinNewReferenceError(self *_object, argumentList []Value) Value {
+ return toValue_object(self.runtime.newReferenceError(valueOfArrayIndex(argumentList, 0)))
+}
+
+func (runtime *_runtime) newSyntaxError(message Value) *_object {
+ self := runtime.newErrorObject("SyntaxError", message)
+ self.prototype = runtime.global.SyntaxErrorPrototype
+ return self
+}
+
+func builtinSyntaxError(call FunctionCall) Value {
+ return toValue_object(call.runtime.newSyntaxError(call.Argument(0)))
+}
+
+func builtinNewSyntaxError(self *_object, argumentList []Value) Value {
+ return toValue_object(self.runtime.newSyntaxError(valueOfArrayIndex(argumentList, 0)))
+}
+
+func builtinURIError(call FunctionCall) Value {
+ return toValue_object(call.runtime.newURIError(call.Argument(0)))
+}
+
+func builtinNewURIError(self *_object, argumentList []Value) Value {
+ return toValue_object(self.runtime.newURIError(valueOfArrayIndex(argumentList, 0)))
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/builtin_function.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/builtin_function.go
new file mode 100644
index 000000000..3d07566c6
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/builtin_function.go
@@ -0,0 +1,129 @@
+package otto
+
+import (
+ "fmt"
+ "regexp"
+ "strings"
+ "unicode"
+
+ "github.com/robertkrimen/otto/parser"
+)
+
+// Function
+
+func builtinFunction(call FunctionCall) Value {
+ return toValue_object(builtinNewFunctionNative(call.runtime, call.ArgumentList))
+}
+
+func builtinNewFunction(self *_object, argumentList []Value) Value {
+ return toValue_object(builtinNewFunctionNative(self.runtime, argumentList))
+}
+
+func argumentList2parameterList(argumentList []Value) []string {
+ parameterList := make([]string, 0, len(argumentList))
+ for _, value := range argumentList {
+ tmp := strings.FieldsFunc(value.string(), func(chr rune) bool {
+ return chr == ',' || unicode.IsSpace(chr)
+ })
+ parameterList = append(parameterList, tmp...)
+ }
+ return parameterList
+}
+
+var matchIdentifier = regexp.MustCompile(`^[$_\p{L}][$_\p{L}\d}]*$`)
+
+func builtinNewFunctionNative(runtime *_runtime, argumentList []Value) *_object {
+ var parameterList, body string
+ count := len(argumentList)
+ if count > 0 {
+ tmp := make([]string, 0, count-1)
+ for _, value := range argumentList[0 : count-1] {
+ tmp = append(tmp, value.string())
+ }
+ parameterList = strings.Join(tmp, ",")
+ body = argumentList[count-1].string()
+ }
+
+ // FIXME
+ function, err := parser.ParseFunction(parameterList, body)
+ runtime.parseThrow(err) // Will panic/throw appropriately
+ cmpl := _compiler{}
+ cmpl_function := cmpl.parseExpression(function)
+
+ return runtime.newNodeFunction(cmpl_function.(*_nodeFunctionLiteral), runtime.globalStash)
+}
+
+func builtinFunction_toString(call FunctionCall) Value {
+ object := call.thisClassObject("Function") // Should throw a TypeError unless Function
+ switch fn := object.value.(type) {
+ case _nativeFunctionObject:
+ return toValue_string(fmt.Sprintf("function %s() { [native code] }", fn.name))
+ case _nodeFunctionObject:
+ return toValue_string(fn.node.source)
+ case _bindFunctionObject:
+ return toValue_string("function () { [native code] }")
+ }
+
+ panic(call.runtime.panicTypeError("Function.toString()"))
+}
+
+func builtinFunction_apply(call FunctionCall) Value {
+ if !call.This.isCallable() {
+ panic(call.runtime.panicTypeError())
+ }
+ this := call.Argument(0)
+ if this.IsUndefined() {
+ // FIXME Not ECMA5
+ this = toValue_object(call.runtime.globalObject)
+ }
+ argumentList := call.Argument(1)
+ switch argumentList.kind {
+ case valueUndefined, valueNull:
+ return call.thisObject().call(this, nil, false, nativeFrame)
+ case valueObject:
+ default:
+ panic(call.runtime.panicTypeError())
+ }
+
+ arrayObject := argumentList._object()
+ thisObject := call.thisObject()
+ length := int64(toUint32(arrayObject.get("length")))
+ valueArray := make([]Value, length)
+ for index := int64(0); index < length; index++ {
+ valueArray[index] = arrayObject.get(arrayIndexToString(index))
+ }
+ return thisObject.call(this, valueArray, false, nativeFrame)
+}
+
+func builtinFunction_call(call FunctionCall) Value {
+ if !call.This.isCallable() {
+ panic(call.runtime.panicTypeError())
+ }
+ thisObject := call.thisObject()
+ this := call.Argument(0)
+ if this.IsUndefined() {
+ // FIXME Not ECMA5
+ this = toValue_object(call.runtime.globalObject)
+ }
+ if len(call.ArgumentList) >= 1 {
+ return thisObject.call(this, call.ArgumentList[1:], false, nativeFrame)
+ }
+ return thisObject.call(this, nil, false, nativeFrame)
+}
+
+func builtinFunction_bind(call FunctionCall) Value {
+ target := call.This
+ if !target.isCallable() {
+ panic(call.runtime.panicTypeError())
+ }
+ targetObject := target._object()
+
+ this := call.Argument(0)
+ argumentList := call.slice(1)
+ if this.IsUndefined() {
+ // FIXME Do this elsewhere?
+ this = toValue_object(call.runtime.globalObject)
+ }
+
+ return toValue_object(call.runtime.newBoundFunction(targetObject, this, argumentList))
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/builtin_json.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/builtin_json.go
new file mode 100644
index 000000000..aed54bf12
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/builtin_json.go
@@ -0,0 +1,299 @@
+package otto
+
+import (
+ "bytes"
+ "encoding/json"
+ "fmt"
+ "strings"
+)
+
+type _builtinJSON_parseContext struct {
+ call FunctionCall
+ reviver Value
+}
+
+func builtinJSON_parse(call FunctionCall) Value {
+ ctx := _builtinJSON_parseContext{
+ call: call,
+ }
+ revive := false
+ if reviver := call.Argument(1); reviver.isCallable() {
+ revive = true
+ ctx.reviver = reviver
+ }
+
+ var root interface{}
+ err := json.Unmarshal([]byte(call.Argument(0).string()), &root)
+ if err != nil {
+ panic(call.runtime.panicSyntaxError(err.Error()))
+ }
+ value, exists := builtinJSON_parseWalk(ctx, root)
+ if !exists {
+ value = Value{}
+ }
+ if revive {
+ root := ctx.call.runtime.newObject()
+ root.put("", value, false)
+ return builtinJSON_reviveWalk(ctx, root, "")
+ }
+ return value
+}
+
+func builtinJSON_reviveWalk(ctx _builtinJSON_parseContext, holder *_object, name string) Value {
+ value := holder.get(name)
+ if object := value._object(); object != nil {
+ if isArray(object) {
+ length := int64(objectLength(object))
+ for index := int64(0); index < length; index += 1 {
+ name := arrayIndexToString(index)
+ value := builtinJSON_reviveWalk(ctx, object, name)
+ if value.IsUndefined() {
+ object.delete(name, false)
+ } else {
+ object.defineProperty(name, value, 0111, false)
+ }
+ }
+ } else {
+ object.enumerate(false, func(name string) bool {
+ value := builtinJSON_reviveWalk(ctx, object, name)
+ if value.IsUndefined() {
+ object.delete(name, false)
+ } else {
+ object.defineProperty(name, value, 0111, false)
+ }
+ return true
+ })
+ }
+ }
+ return ctx.reviver.call(ctx.call.runtime, toValue_object(holder), name, value)
+}
+
+func builtinJSON_parseWalk(ctx _builtinJSON_parseContext, rawValue interface{}) (Value, bool) {
+ switch value := rawValue.(type) {
+ case nil:
+ return nullValue, true
+ case bool:
+ return toValue_bool(value), true
+ case string:
+ return toValue_string(value), true
+ case float64:
+ return toValue_float64(value), true
+ case []interface{}:
+ arrayValue := make([]Value, len(value))
+ for index, rawValue := range value {
+ if value, exists := builtinJSON_parseWalk(ctx, rawValue); exists {
+ arrayValue[index] = value
+ }
+ }
+ return toValue_object(ctx.call.runtime.newArrayOf(arrayValue)), true
+ case map[string]interface{}:
+ object := ctx.call.runtime.newObject()
+ for name, rawValue := range value {
+ if value, exists := builtinJSON_parseWalk(ctx, rawValue); exists {
+ object.put(name, value, false)
+ }
+ }
+ return toValue_object(object), true
+ }
+ return Value{}, false
+}
+
+type _builtinJSON_stringifyContext struct {
+ call FunctionCall
+ stack []*_object
+ propertyList []string
+ replacerFunction *Value
+ gap string
+}
+
+func builtinJSON_stringify(call FunctionCall) Value {
+ ctx := _builtinJSON_stringifyContext{
+ call: call,
+ stack: []*_object{nil},
+ }
+ replacer := call.Argument(1)._object()
+ if replacer != nil {
+ if isArray(replacer) {
+ length := objectLength(replacer)
+ seen := map[string]bool{}
+ propertyList := make([]string, length)
+ length = 0
+ for index, _ := range propertyList {
+ value := replacer.get(arrayIndexToString(int64(index)))
+ switch value.kind {
+ case valueObject:
+ switch value.value.(*_object).class {
+ case "String":
+ case "Number":
+ default:
+ continue
+ }
+ case valueString:
+ case valueNumber:
+ default:
+ continue
+ }
+ name := value.string()
+ if seen[name] {
+ continue
+ }
+ seen[name] = true
+ length += 1
+ propertyList[index] = name
+ }
+ ctx.propertyList = propertyList[0:length]
+ } else if replacer.class == "Function" {
+ value := toValue_object(replacer)
+ ctx.replacerFunction = &value
+ }
+ }
+ if spaceValue, exists := call.getArgument(2); exists {
+ if spaceValue.kind == valueObject {
+ switch spaceValue.value.(*_object).class {
+ case "String":
+ spaceValue = toValue_string(spaceValue.string())
+ case "Number":
+ spaceValue = spaceValue.numberValue()
+ }
+ }
+ switch spaceValue.kind {
+ case valueString:
+ value := spaceValue.string()
+ if len(value) > 10 {
+ ctx.gap = value[0:10]
+ } else {
+ ctx.gap = value
+ }
+ case valueNumber:
+ value := spaceValue.number().int64
+ if value > 10 {
+ value = 10
+ } else if value < 0 {
+ value = 0
+ }
+ ctx.gap = strings.Repeat(" ", int(value))
+ }
+ }
+ holder := call.runtime.newObject()
+ holder.put("", call.Argument(0), false)
+ value, exists := builtinJSON_stringifyWalk(ctx, "", holder)
+ if !exists {
+ return Value{}
+ }
+ valueJSON, err := json.Marshal(value)
+ if err != nil {
+ panic(call.runtime.panicTypeError(err.Error()))
+ }
+ if ctx.gap != "" {
+ valueJSON1 := bytes.Buffer{}
+ json.Indent(&valueJSON1, valueJSON, "", ctx.gap)
+ valueJSON = valueJSON1.Bytes()
+ }
+ return toValue_string(string(valueJSON))
+}
+
+func builtinJSON_stringifyWalk(ctx _builtinJSON_stringifyContext, key string, holder *_object) (interface{}, bool) {
+ value := holder.get(key)
+
+ if value.IsObject() {
+ object := value._object()
+ if toJSON := object.get("toJSON"); toJSON.IsFunction() {
+ value = toJSON.call(ctx.call.runtime, value, key)
+ } else {
+ // If the object is a GoStruct or something that implements json.Marshaler
+ if object.objectClass.marshalJSON != nil {
+ marshaler := object.objectClass.marshalJSON(object)
+ if marshaler != nil {
+ return marshaler, true
+ }
+ }
+ }
+ }
+
+ if ctx.replacerFunction != nil {
+ value = (*ctx.replacerFunction).call(ctx.call.runtime, toValue_object(holder), key, value)
+ }
+
+ if value.kind == valueObject {
+ switch value.value.(*_object).class {
+ case "Boolean":
+ value = value._object().value.(Value)
+ case "String":
+ value = toValue_string(value.string())
+ case "Number":
+ value = value.numberValue()
+ }
+ }
+
+ switch value.kind {
+ case valueBoolean:
+ return value.bool(), true
+ case valueString:
+ return value.string(), true
+ case valueNumber:
+ integer := value.number()
+ switch integer.kind {
+ case numberInteger:
+ return integer.int64, true
+ case numberFloat:
+ return integer.float64, true
+ default:
+ return nil, true
+ }
+ case valueNull:
+ return nil, true
+ case valueObject:
+ holder := value._object()
+ if value := value._object(); nil != value {
+ for _, object := range ctx.stack {
+ if holder == object {
+ panic(ctx.call.runtime.panicTypeError("Converting circular structure to JSON"))
+ }
+ }
+ ctx.stack = append(ctx.stack, value)
+ defer func() { ctx.stack = ctx.stack[:len(ctx.stack)-1] }()
+ }
+ if isArray(holder) {
+ var length uint32
+ switch value := holder.get("length").value.(type) {
+ case uint32:
+ length = value
+ case int:
+ if value >= 0 {
+ length = uint32(value)
+ }
+ default:
+ panic(ctx.call.runtime.panicTypeError(fmt.Sprintf("JSON.stringify: invalid length: %v (%[1]T)", value)))
+ }
+ array := make([]interface{}, length)
+ for index, _ := range array {
+ name := arrayIndexToString(int64(index))
+ value, _ := builtinJSON_stringifyWalk(ctx, name, holder)
+ array[index] = value
+ }
+ return array, true
+ } else if holder.class != "Function" {
+ object := map[string]interface{}{}
+ if ctx.propertyList != nil {
+ for _, name := range ctx.propertyList {
+ value, exists := builtinJSON_stringifyWalk(ctx, name, holder)
+ if exists {
+ object[name] = value
+ }
+ }
+ } else {
+ // Go maps are without order, so this doesn't conform to the ECMA ordering
+ // standard, but oh well...
+ holder.enumerate(false, func(name string) bool {
+ value, exists := builtinJSON_stringifyWalk(ctx, name, holder)
+ if exists {
+ object[name] = value
+ }
+ return true
+ })
+ }
+ return object, true
+ }
+ }
+ return nil, false
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/builtin_math.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/builtin_math.go
new file mode 100644
index 000000000..a9f4a55c1
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/builtin_math.go
@@ -0,0 +1,145 @@
+package otto
+
+import (
+ "math"
+ "math/rand"
+)
+
+// Math
+
+func builtinMath_abs(call FunctionCall) Value {
+ number := call.Argument(0).float64()
+ return toValue_float64(math.Abs(number))
+}
+
+func builtinMath_acos(call FunctionCall) Value {
+ number := call.Argument(0).float64()
+ return toValue_float64(math.Acos(number))
+}
+
+func builtinMath_asin(call FunctionCall) Value {
+ number := call.Argument(0).float64()
+ return toValue_float64(math.Asin(number))
+}
+
+func builtinMath_atan(call FunctionCall) Value {
+ number := call.Argument(0).float64()
+ return toValue_float64(math.Atan(number))
+}
+
+func builtinMath_atan2(call FunctionCall) Value {
+ y := call.Argument(0).float64()
+ if math.IsNaN(y) {
+ return NaNValue()
+ }
+ x := call.Argument(1).float64()
+ if math.IsNaN(x) {
+ return NaNValue()
+ }
+ return toValue_float64(math.Atan2(y, x))
+}
+
+func builtinMath_cos(call FunctionCall) Value {
+ number := call.Argument(0).float64()
+ return toValue_float64(math.Cos(number))
+}
+
+func builtinMath_ceil(call FunctionCall) Value {
+ number := call.Argument(0).float64()
+ return toValue_float64(math.Ceil(number))
+}
+
+func builtinMath_exp(call FunctionCall) Value {
+ number := call.Argument(0).float64()
+ return toValue_float64(math.Exp(number))
+}
+
+func builtinMath_floor(call FunctionCall) Value {
+ number := call.Argument(0).float64()
+ return toValue_float64(math.Floor(number))
+}
+
+func builtinMath_log(call FunctionCall) Value {
+ number := call.Argument(0).float64()
+ return toValue_float64(math.Log(number))
+}
+
+func builtinMath_max(call FunctionCall) Value {
+ switch len(call.ArgumentList) {
+ case 0:
+ return negativeInfinityValue()
+ case 1:
+ return toValue_float64(call.ArgumentList[0].float64())
+ }
+ result := call.ArgumentList[0].float64()
+ if math.IsNaN(result) {
+ return NaNValue()
+ }
+ for _, value := range call.ArgumentList[1:] {
+ value := value.float64()
+ if math.IsNaN(value) {
+ return NaNValue()
+ }
+ result = math.Max(result, value)
+ }
+ return toValue_float64(result)
+}
+
+func builtinMath_min(call FunctionCall) Value {
+ switch len(call.ArgumentList) {
+ case 0:
+ return positiveInfinityValue()
+ case 1:
+ return toValue_float64(call.ArgumentList[0].float64())
+ }
+ result := call.ArgumentList[0].float64()
+ if math.IsNaN(result) {
+ return NaNValue()
+ }
+ for _, value := range call.ArgumentList[1:] {
+ value := value.float64()
+ if math.IsNaN(value) {
+ return NaNValue()
+ }
+ result = math.Min(result, value)
+ }
+ return toValue_float64(result)
+}
+
+func builtinMath_pow(call FunctionCall) Value {
+ // TODO Make sure this works according to the specification (15.8.2.13)
+ x := call.Argument(0).float64()
+ y := call.Argument(1).float64()
+ if math.Abs(x) == 1 && math.IsInf(y, 0) {
+ return NaNValue()
+ }
+ return toValue_float64(math.Pow(x, y))
+}
+
+func builtinMath_random(call FunctionCall) Value {
+ return toValue_float64(rand.Float64())
+}
+
+func builtinMath_round(call FunctionCall) Value {
+ number := call.Argument(0).float64()
+ value := math.Floor(number + 0.5)
+ if value == 0 {
+ value = math.Copysign(0, number)
+ }
+ return toValue_float64(value)
+}
+
+func builtinMath_sin(call FunctionCall) Value {
+ number := call.Argument(0).float64()
+ return toValue_float64(math.Sin(number))
+}
+
+func builtinMath_sqrt(call FunctionCall) Value {
+ number := call.Argument(0).float64()
+ return toValue_float64(math.Sqrt(number))
+}
+
+func builtinMath_tan(call FunctionCall) Value {
+ number := call.Argument(0).float64()
+ return toValue_float64(math.Tan(number))
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/builtin_number.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/builtin_number.go
new file mode 100644
index 000000000..26a03e7b6
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/builtin_number.go
@@ -0,0 +1,93 @@
+package otto
+
+import (
+ "math"
+ "strconv"
+)
+
+// Number
+
+func numberValueFromNumberArgumentList(argumentList []Value) Value {
+ if len(argumentList) > 0 {
+ return argumentList[0].numberValue()
+ }
+ return toValue_int(0)
+}
+
+func builtinNumber(call FunctionCall) Value {
+ return numberValueFromNumberArgumentList(call.ArgumentList)
+}
+
+func builtinNewNumber(self *_object, argumentList []Value) Value {
+ return toValue_object(self.runtime.newNumber(numberValueFromNumberArgumentList(argumentList)))
+}
+
+func builtinNumber_toString(call FunctionCall) Value {
+ // Will throw a TypeError if ThisObject is not a Number
+ value := call.thisClassObject("Number").primitiveValue()
+ radix := 10
+ radixArgument := call.Argument(0)
+ if radixArgument.IsDefined() {
+ integer := toIntegerFloat(radixArgument)
+ if integer < 2 || integer > 36 {
+ panic(call.runtime.panicRangeError("RangeError: toString() radix must be between 2 and 36"))
+ }
+ radix = int(integer)
+ }
+ if radix == 10 {
+ return toValue_string(value.string())
+ }
+ return toValue_string(numberToStringRadix(value, radix))
+}
+
+func builtinNumber_valueOf(call FunctionCall) Value {
+ return call.thisClassObject("Number").primitiveValue()
+}
+
+func builtinNumber_toFixed(call FunctionCall) Value {
+ precision := toIntegerFloat(call.Argument(0))
+ if 20 < precision || 0 > precision {
+ panic(call.runtime.panicRangeError("toFixed() precision must be between 0 and 20"))
+ }
+ if call.This.IsNaN() {
+ return toValue_string("NaN")
+ }
+ value := call.This.float64()
+ if math.Abs(value) >= 1e21 {
+ return toValue_string(floatToString(value, 64))
+ }
+ return toValue_string(strconv.FormatFloat(call.This.float64(), 'f', int(precision), 64))
+}
+
+func builtinNumber_toExponential(call FunctionCall) Value {
+ if call.This.IsNaN() {
+ return toValue_string("NaN")
+ }
+ precision := float64(-1)
+ if value := call.Argument(0); value.IsDefined() {
+ precision = toIntegerFloat(value)
+ if 0 > precision {
+ panic(call.runtime.panicRangeError("RangeError: toString() radix must be between 2 and 36"))
+ }
+ }
+ return toValue_string(strconv.FormatFloat(call.This.float64(), 'e', int(precision), 64))
+}
+
+func builtinNumber_toPrecision(call FunctionCall) Value {
+ if call.This.IsNaN() {
+ return toValue_string("NaN")
+ }
+ value := call.Argument(0)
+ if value.IsUndefined() {
+ return toValue_string(call.This.string())
+ }
+ precision := toIntegerFloat(value)
+ if 1 > precision {
+ panic(call.runtime.panicRangeError("RangeError: toPrecision() precision must be greater than 1"))
+ }
+ return toValue_string(strconv.FormatFloat(call.This.float64(), 'g', int(precision), 64))
+}
+
+func builtinNumber_toLocaleString(call FunctionCall) Value {
+ return builtinNumber_toString(call)
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/builtin_object.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/builtin_object.go
new file mode 100644
index 000000000..c2433f7be
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/builtin_object.go
@@ -0,0 +1,289 @@
+package otto
+
+import (
+ "fmt"
+)
+
+// Object
+
+func builtinObject(call FunctionCall) Value {
+ value := call.Argument(0)
+ switch value.kind {
+ case valueUndefined, valueNull:
+ return toValue_object(call.runtime.newObject())
+ }
+
+ return toValue_object(call.runtime.toObject(value))
+}
+
+func builtinNewObject(self *_object, argumentList []Value) Value {
+ value := valueOfArrayIndex(argumentList, 0)
+ switch value.kind {
+ case valueNull, valueUndefined:
+ case valueNumber, valueString, valueBoolean:
+ return toValue_object(self.runtime.toObject(value))
+ case valueObject:
+ return value
+ default:
+ }
+ return toValue_object(self.runtime.newObject())
+}
+
+func builtinObject_valueOf(call FunctionCall) Value {
+ return toValue_object(call.thisObject())
+}
+
+func builtinObject_hasOwnProperty(call FunctionCall) Value {
+ propertyName := call.Argument(0).string()
+ thisObject := call.thisObject()
+ return toValue_bool(thisObject.hasOwnProperty(propertyName))
+}
+
+func builtinObject_isPrototypeOf(call FunctionCall) Value {
+ value := call.Argument(0)
+ if !value.IsObject() {
+ return falseValue
+ }
+ prototype := call.toObject(value).prototype
+ thisObject := call.thisObject()
+ for prototype != nil {
+ if thisObject == prototype {
+ return trueValue
+ }
+ prototype = prototype.prototype
+ }
+ return falseValue
+}
+
+func builtinObject_propertyIsEnumerable(call FunctionCall) Value {
+ propertyName := call.Argument(0).string()
+ thisObject := call.thisObject()
+ property := thisObject.getOwnProperty(propertyName)
+ if property != nil && property.enumerable() {
+ return trueValue
+ }
+ return falseValue
+}
+
+func builtinObject_toString(call FunctionCall) Value {
+ result := ""
+ if call.This.IsUndefined() {
+ result = "[object Undefined]"
+ } else if call.This.IsNull() {
+ result = "[object Null]"
+ } else {
+ result = fmt.Sprintf("[object %s]", call.thisObject().class)
+ }
+ return toValue_string(result)
+}
+
+func builtinObject_toLocaleString(call FunctionCall) Value {
+ toString := call.thisObject().get("toString")
+ if !toString.isCallable() {
+ panic(call.runtime.panicTypeError())
+ }
+ return toString.call(call.runtime, call.This)
+}
+
+func builtinObject_getPrototypeOf(call FunctionCall) Value {
+ objectValue := call.Argument(0)
+ object := objectValue._object()
+ if object == nil {
+ panic(call.runtime.panicTypeError())
+ }
+
+ if object.prototype == nil {
+ return nullValue
+ }
+
+ return toValue_object(object.prototype)
+}
+
+func builtinObject_getOwnPropertyDescriptor(call FunctionCall) Value {
+ objectValue := call.Argument(0)
+ object := objectValue._object()
+ if object == nil {
+ panic(call.runtime.panicTypeError())
+ }
+
+ name := call.Argument(1).string()
+ descriptor := object.getOwnProperty(name)
+ if descriptor == nil {
+ return Value{}
+ }
+ return toValue_object(call.runtime.fromPropertyDescriptor(*descriptor))
+}
+
+func builtinObject_defineProperty(call FunctionCall) Value {
+ objectValue := call.Argument(0)
+ object := objectValue._object()
+ if object == nil {
+ panic(call.runtime.panicTypeError())
+ }
+ name := call.Argument(1).string()
+ descriptor := toPropertyDescriptor(call.runtime, call.Argument(2))
+ object.defineOwnProperty(name, descriptor, true)
+ return objectValue
+}
+
+func builtinObject_defineProperties(call FunctionCall) Value {
+ objectValue := call.Argument(0)
+ object := objectValue._object()
+ if object == nil {
+ panic(call.runtime.panicTypeError())
+ }
+
+ properties := call.runtime.toObject(call.Argument(1))
+ properties.enumerate(false, func(name string) bool {
+ descriptor := toPropertyDescriptor(call.runtime, properties.get(name))
+ object.defineOwnProperty(name, descriptor, true)
+ return true
+ })
+
+ return objectValue
+}
+
+func builtinObject_create(call FunctionCall) Value {
+ prototypeValue := call.Argument(0)
+ if !prototypeValue.IsNull() && !prototypeValue.IsObject() {
+ panic(call.runtime.panicTypeError())
+ }
+
+ object := call.runtime.newObject()
+ object.prototype = prototypeValue._object()
+
+ propertiesValue := call.Argument(1)
+ if propertiesValue.IsDefined() {
+ properties := call.runtime.toObject(propertiesValue)
+ properties.enumerate(false, func(name string) bool {
+ descriptor := toPropertyDescriptor(call.runtime, properties.get(name))
+ object.defineOwnProperty(name, descriptor, true)
+ return true
+ })
+ }
+
+ return toValue_object(object)
+}
+
+func builtinObject_isExtensible(call FunctionCall) Value {
+ object := call.Argument(0)
+ if object := object._object(); object != nil {
+ return toValue_bool(object.extensible)
+ }
+ panic(call.runtime.panicTypeError())
+}
+
+func builtinObject_preventExtensions(call FunctionCall) Value {
+ object := call.Argument(0)
+ if object := object._object(); object != nil {
+ object.extensible = false
+ } else {
+ panic(call.runtime.panicTypeError())
+ }
+ return object
+}
+
+func builtinObject_isSealed(call FunctionCall) Value {
+ object := call.Argument(0)
+ if object := object._object(); object != nil {
+ if object.extensible {
+ return toValue_bool(false)
+ }
+ result := true
+ object.enumerate(true, func(name string) bool {
+ property := object.getProperty(name)
+ if property.configurable() {
+ result = false
+ }
+ return true
+ })
+ return toValue_bool(result)
+ }
+ panic(call.runtime.panicTypeError())
+}
+
+func builtinObject_seal(call FunctionCall) Value {
+ object := call.Argument(0)
+ if object := object._object(); object != nil {
+ object.enumerate(true, func(name string) bool {
+ if property := object.getOwnProperty(name); nil != property && property.configurable() {
+ property.configureOff()
+ object.defineOwnProperty(name, *property, true)
+ }
+ return true
+ })
+ object.extensible = false
+ } else {
+ panic(call.runtime.panicTypeError())
+ }
+ return object
+}
+
+func builtinObject_isFrozen(call FunctionCall) Value {
+ object := call.Argument(0)
+ if object := object._object(); object != nil {
+ if object.extensible {
+ return toValue_bool(false)
+ }
+ result := true
+ object.enumerate(true, func(name string) bool {
+ property := object.getProperty(name)
+ if property.configurable() || property.writable() {
+ result = false
+ }
+ return true
+ })
+ return toValue_bool(result)
+ }
+ panic(call.runtime.panicTypeError())
+}
+
+func builtinObject_freeze(call FunctionCall) Value {
+ object := call.Argument(0)
+ if object := object._object(); object != nil {
+ object.enumerate(true, func(name string) bool {
+ if property, update := object.getOwnProperty(name), false; nil != property {
+ if property.isDataDescriptor() && property.writable() {
+ property.writeOff()
+ update = true
+ }
+ if property.configurable() {
+ property.configureOff()
+ update = true
+ }
+ if update {
+ object.defineOwnProperty(name, *property, true)
+ }
+ }
+ return true
+ })
+ object.extensible = false
+ } else {
+ panic(call.runtime.panicTypeError())
+ }
+ return object
+}
+
+func builtinObject_keys(call FunctionCall) Value {
+ if object, keys := call.Argument(0)._object(), []Value(nil); nil != object {
+ object.enumerate(false, func(name string) bool {
+ keys = append(keys, toValue_string(name))
+ return true
+ })
+ return toValue_object(call.runtime.newArrayOf(keys))
+ }
+ panic(call.runtime.panicTypeError())
+}
+
+func builtinObject_getOwnPropertyNames(call FunctionCall) Value {
+ if object, propertyNames := call.Argument(0)._object(), []Value(nil); nil != object {
+ object.enumerate(true, func(name string) bool {
+ if object.hasOwnProperty(name) {
+ propertyNames = append(propertyNames, toValue_string(name))
+ }
+ return true
+ })
+ return toValue_object(call.runtime.newArrayOf(propertyNames))
+ }
+ panic(call.runtime.panicTypeError())
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/builtin_regexp.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/builtin_regexp.go
new file mode 100644
index 000000000..99422510d
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/builtin_regexp.go
@@ -0,0 +1,65 @@
+package otto
+
+import (
+ "fmt"
+)
+
+// RegExp
+
+func builtinRegExp(call FunctionCall) Value {
+ pattern := call.Argument(0)
+ flags := call.Argument(1)
+ if object := pattern._object(); object != nil {
+ if object.class == "RegExp" && flags.IsUndefined() {
+ return pattern
+ }
+ }
+ return toValue_object(call.runtime.newRegExp(pattern, flags))
+}
+
+func builtinNewRegExp(self *_object, argumentList []Value) Value {
+ return toValue_object(self.runtime.newRegExp(
+ valueOfArrayIndex(argumentList, 0),
+ valueOfArrayIndex(argumentList, 1),
+ ))
+}
+
+func builtinRegExp_toString(call FunctionCall) Value {
+ thisObject := call.thisObject()
+ source := thisObject.get("source").string()
+ flags := []byte{}
+ if thisObject.get("global").bool() {
+ flags = append(flags, 'g')
+ }
+ if thisObject.get("ignoreCase").bool() {
+ flags = append(flags, 'i')
+ }
+ if thisObject.get("multiline").bool() {
+ flags = append(flags, 'm')
+ }
+ return toValue_string(fmt.Sprintf("/%s/%s", source, flags))
+}
+
+func builtinRegExp_exec(call FunctionCall) Value {
+ thisObject := call.thisObject()
+ target := call.Argument(0).string()
+ match, result := execRegExp(thisObject, target)
+ if !match {
+ return nullValue
+ }
+ return toValue_object(execResultToArray(call.runtime, target, result))
+}
+
+func builtinRegExp_test(call FunctionCall) Value {
+ thisObject := call.thisObject()
+ target := call.Argument(0).string()
+ match, _ := execRegExp(thisObject, target)
+ return toValue_bool(match)
+}
+
+func builtinRegExp_compile(call FunctionCall) Value {
+ // This (useless) function is deprecated, but is here to provide some
+ // semblance of compatibility.
+ // Caveat emptor: it may not be around for long.
+ return Value{}
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/builtin_string.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/builtin_string.go
new file mode 100644
index 000000000..6a1718458
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/builtin_string.go
@@ -0,0 +1,500 @@
+package otto
+
+import (
+ "bytes"
+ "regexp"
+ "strconv"
+ "strings"
+ "unicode/utf8"
+)
+
+// String
+
+func stringValueFromStringArgumentList(argumentList []Value) Value {
+ if len(argumentList) > 0 {
+ return toValue_string(argumentList[0].string())
+ }
+ return toValue_string("")
+}
+
+func builtinString(call FunctionCall) Value {
+ return stringValueFromStringArgumentList(call.ArgumentList)
+}
+
+func builtinNewString(self *_object, argumentList []Value) Value {
+ return toValue_object(self.runtime.newString(stringValueFromStringArgumentList(argumentList)))
+}
+
+func builtinString_toString(call FunctionCall) Value {
+ return call.thisClassObject("String").primitiveValue()
+}
+func builtinString_valueOf(call FunctionCall) Value {
+ return call.thisClassObject("String").primitiveValue()
+}
+
+func builtinString_fromCharCode(call FunctionCall) Value {
+ chrList := make([]uint16, len(call.ArgumentList))
+ for index, value := range call.ArgumentList {
+ chrList[index] = toUint16(value)
+ }
+ return toValue_string16(chrList)
+}
+
+func builtinString_charAt(call FunctionCall) Value {
+ checkObjectCoercible(call.runtime, call.This)
+ idx := int(call.Argument(0).number().int64)
+ chr := stringAt(call.This._object().stringValue(), idx)
+ if chr == utf8.RuneError {
+ return toValue_string("")
+ }
+ return toValue_string(string(chr))
+}
+
+func builtinString_charCodeAt(call FunctionCall) Value {
+ checkObjectCoercible(call.runtime, call.This)
+ idx := int(call.Argument(0).number().int64)
+ chr := stringAt(call.This._object().stringValue(), idx)
+ if chr == utf8.RuneError {
+ return NaNValue()
+ }
+ return toValue_uint16(uint16(chr))
+}
+
+func builtinString_concat(call FunctionCall) Value {
+ checkObjectCoercible(call.runtime, call.This)
+ var value bytes.Buffer
+ value.WriteString(call.This.string())
+ for _, item := range call.ArgumentList {
+ value.WriteString(item.string())
+ }
+ return toValue_string(value.String())
+}
+
+func builtinString_indexOf(call FunctionCall) Value {
+ checkObjectCoercible(call.runtime, call.This)
+ value := call.This.string()
+ target := call.Argument(0).string()
+ if 2 > len(call.ArgumentList) {
+ return toValue_int(strings.Index(value, target))
+ }
+ start := toIntegerFloat(call.Argument(1))
+ if 0 > start {
+ start = 0
+ } else if start >= float64(len(value)) {
+ if target == "" {
+ return toValue_int(len(value))
+ }
+ return toValue_int(-1)
+ }
+ index := strings.Index(value[int(start):], target)
+ if index >= 0 {
+ index += int(start)
+ }
+ return toValue_int(index)
+}
+
+func builtinString_lastIndexOf(call FunctionCall) Value {
+ checkObjectCoercible(call.runtime, call.This)
+ value := call.This.string()
+ target := call.Argument(0).string()
+ if 2 > len(call.ArgumentList) || call.ArgumentList[1].IsUndefined() {
+ return toValue_int(strings.LastIndex(value, target))
+ }
+ length := len(value)
+ if length == 0 {
+ return toValue_int(strings.LastIndex(value, target))
+ }
+ start := call.ArgumentList[1].number()
+ if start.kind == numberInfinity { // FIXME
+ // startNumber is infinity, so start is the end of string (start = length)
+ return toValue_int(strings.LastIndex(value, target))
+ }
+ if 0 > start.int64 {
+ start.int64 = 0
+ }
+ end := int(start.int64) + len(target)
+ if end > length {
+ end = length
+ }
+ return toValue_int(strings.LastIndex(value[:end], target))
+}
+
+func builtinString_match(call FunctionCall) Value {
+ checkObjectCoercible(call.runtime, call.This)
+ target := call.This.string()
+ matcherValue := call.Argument(0)
+ matcher := matcherValue._object()
+ if !matcherValue.IsObject() || matcher.class != "RegExp" {
+ matcher = call.runtime.newRegExp(matcherValue, Value{})
+ }
+ global := matcher.get("global").bool()
+ if !global {
+ match, result := execRegExp(matcher, target)
+ if !match {
+ return nullValue
+ }
+ return toValue_object(execResultToArray(call.runtime, target, result))
+ }
+
+ {
+ result := matcher.regExpValue().regularExpression.FindAllStringIndex(target, -1)
+ matchCount := len(result)
+ if result == nil {
+ matcher.put("lastIndex", toValue_int(0), true)
+ return Value{} // !match
+ }
+ matchCount = len(result)
+ valueArray := make([]Value, matchCount)
+ for index := 0; index < matchCount; index++ {
+ valueArray[index] = toValue_string(target[result[index][0]:result[index][1]])
+ }
+ matcher.put("lastIndex", toValue_int(result[matchCount-1][1]), true)
+ return toValue_object(call.runtime.newArrayOf(valueArray))
+ }
+}
+
+var builtinString_replace_Regexp = regexp.MustCompile("\\$(?:[\\$\\&\\'\\`1-9]|0[1-9]|[1-9][0-9])")
+
+func builtinString_findAndReplaceString(input []byte, lastIndex int, match []int, target []byte, replaceValue []byte) (output []byte) {
+ matchCount := len(match) / 2
+ output = input
+ if match[0] != lastIndex {
+ output = append(output, target[lastIndex:match[0]]...)
+ }
+ replacement := builtinString_replace_Regexp.ReplaceAllFunc(replaceValue, func(part []byte) []byte {
+ // TODO Check if match[0] or match[1] can be -1 in this scenario
+ switch part[1] {
+ case '$':
+ return []byte{'$'}
+ case '&':
+ return target[match[0]:match[1]]
+ case '`':
+ return target[:match[0]]
+ case '\'':
+ return target[match[1]:len(target)]
+ }
+ matchNumberParse, error := strconv.ParseInt(string(part[1:]), 10, 64)
+ matchNumber := int(matchNumberParse)
+ if error != nil || matchNumber >= matchCount {
+ return []byte{}
+ }
+ offset := 2 * matchNumber
+ if match[offset] != -1 {
+ return target[match[offset]:match[offset+1]]
+ }
+ return []byte{} // The empty string
+ })
+ output = append(output, replacement...)
+ return output
+}
+
+func builtinString_replace(call FunctionCall) Value {
+ checkObjectCoercible(call.runtime, call.This)
+ target := []byte(call.This.string())
+ searchValue := call.Argument(0)
+ searchObject := searchValue._object()
+
+ // TODO If a capture is -1?
+ var search *regexp.Regexp
+ global := false
+ find := 1
+ if searchValue.IsObject() && searchObject.class == "RegExp" {
+ regExp := searchObject.regExpValue()
+ search = regExp.regularExpression
+ if regExp.global {
+ find = -1
+ }
+ } else {
+ search = regexp.MustCompile(regexp.QuoteMeta(searchValue.string()))
+ }
+
+ found := search.FindAllSubmatchIndex(target, find)
+ if found == nil {
+ return toValue_string(string(target)) // !match
+ }
+
+ {
+ lastIndex := 0
+ result := []byte{}
+
+ replaceValue := call.Argument(1)
+ if replaceValue.isCallable() {
+ target := string(target)
+ replace := replaceValue._object()
+ for _, match := range found {
+ if match[0] != lastIndex {
+ result = append(result, target[lastIndex:match[0]]...)
+ }
+ matchCount := len(match) / 2
+ argumentList := make([]Value, matchCount+2)
+ for index := 0; index < matchCount; index++ {
+ offset := 2 * index
+ if match[offset] != -1 {
+ argumentList[index] = toValue_string(target[match[offset]:match[offset+1]])
+ } else {
+ argumentList[index] = Value{}
+ }
+ }
+ argumentList[matchCount+0] = toValue_int(match[0])
+ argumentList[matchCount+1] = toValue_string(target)
+ replacement := replace.call(Value{}, argumentList, false, nativeFrame).string()
+ result = append(result, []byte(replacement)...)
+ lastIndex = match[1]
+ }
+
+ } else {
+ replace := []byte(replaceValue.string())
+ for _, match := range found {
+ result = builtinString_findAndReplaceString(result, lastIndex, match, target, replace)
+ lastIndex = match[1]
+ }
+ }
+
+ if lastIndex != len(target) {
+ result = append(result, target[lastIndex:]...)
+ }
+
+ if global && searchObject != nil {
+ searchObject.put("lastIndex", toValue_int(lastIndex), true)
+ }
+
+ return toValue_string(string(result))
+ }
+}
+
+func builtinString_search(call FunctionCall) Value {
+ checkObjectCoercible(call.runtime, call.This)
+ target := call.This.string()
+ searchValue := call.Argument(0)
+ search := searchValue._object()
+ if !searchValue.IsObject() || search.class != "RegExp" {
+ search = call.runtime.newRegExp(searchValue, Value{})
+ }
+ result := search.regExpValue().regularExpression.FindStringIndex(target)
+ if result == nil {
+ return toValue_int(-1)
+ }
+ return toValue_int(result[0])
+}
+
+func stringSplitMatch(target string, targetLength int64, index uint, search string, searchLength int64) (bool, uint) {
+ if int64(index)+searchLength > searchLength {
+ return false, 0
+ }
+ found := strings.Index(target[index:], search)
+ if 0 > found {
+ return false, 0
+ }
+ return true, uint(found)
+}
+
+func builtinString_split(call FunctionCall) Value {
+ checkObjectCoercible(call.runtime, call.This)
+ target := call.This.string()
+
+ separatorValue := call.Argument(0)
+ limitValue := call.Argument(1)
+ limit := -1
+ if limitValue.IsDefined() {
+ limit = int(toUint32(limitValue))
+ }
+
+ if limit == 0 {
+ return toValue_object(call.runtime.newArray(0))
+ }
+
+ if separatorValue.IsUndefined() {
+ return toValue_object(call.runtime.newArrayOf([]Value{toValue_string(target)}))
+ }
+
+ if separatorValue.isRegExp() {
+ targetLength := len(target)
+ search := separatorValue._object().regExpValue().regularExpression
+ valueArray := []Value{}
+ result := search.FindAllStringSubmatchIndex(target, -1)
+ lastIndex := 0
+ found := 0
+
+ for _, match := range result {
+ if match[0] == match[1] {
+ // FIXME Ugh, this is a hack
+ if match[0] == 0 || match[0] == targetLength {
+ continue
+ }
+ }
+
+ if lastIndex != match[0] {
+ valueArray = append(valueArray, toValue_string(target[lastIndex:match[0]]))
+ found++
+ } else if lastIndex == match[0] {
+ if lastIndex != -1 {
+ valueArray = append(valueArray, toValue_string(""))
+ found++
+ }
+ }
+
+ lastIndex = match[1]
+ if found == limit {
+ goto RETURN
+ }
+
+ captureCount := len(match) / 2
+ for index := 1; index < captureCount; index++ {
+ offset := index * 2
+ value := Value{}
+ if match[offset] != -1 {
+ value = toValue_string(target[match[offset]:match[offset+1]])
+ }
+ valueArray = append(valueArray, value)
+ found++
+ if found == limit {
+ goto RETURN
+ }
+ }
+ }
+
+ if found != limit {
+ if lastIndex != targetLength {
+ valueArray = append(valueArray, toValue_string(target[lastIndex:targetLength]))
+ } else {
+ valueArray = append(valueArray, toValue_string(""))
+ }
+ }
+
+ RETURN:
+ return toValue_object(call.runtime.newArrayOf(valueArray))
+
+ } else {
+ separator := separatorValue.string()
+
+ splitLimit := limit
+ excess := false
+ if limit > 0 {
+ splitLimit = limit + 1
+ excess = true
+ }
+
+ split := strings.SplitN(target, separator, splitLimit)
+
+ if excess && len(split) > limit {
+ split = split[:limit]
+ }
+
+ valueArray := make([]Value, len(split))
+ for index, value := range split {
+ valueArray[index] = toValue_string(value)
+ }
+
+ return toValue_object(call.runtime.newArrayOf(valueArray))
+ }
+}
+
+func builtinString_slice(call FunctionCall) Value {
+ checkObjectCoercible(call.runtime, call.This)
+ target := call.This.string()
+
+ length := int64(len(target))
+ start, end := rangeStartEnd(call.ArgumentList, length, false)
+ if end-start <= 0 {
+ return toValue_string("")
+ }
+ return toValue_string(target[start:end])
+}
+
+func builtinString_substring(call FunctionCall) Value {
+ checkObjectCoercible(call.runtime, call.This)
+ target := call.This.string()
+
+ length := int64(len(target))
+ start, end := rangeStartEnd(call.ArgumentList, length, true)
+ if start > end {
+ start, end = end, start
+ }
+ return toValue_string(target[start:end])
+}
+
+func builtinString_substr(call FunctionCall) Value {
+ target := call.This.string()
+
+ size := int64(len(target))
+ start, length := rangeStartLength(call.ArgumentList, size)
+
+ if start >= size {
+ return toValue_string("")
+ }
+
+ if length <= 0 {
+ return toValue_string("")
+ }
+
+ if start+length >= size {
+ // Cap length to be to the end of the string
+ // start = 3, length = 5, size = 4 [0, 1, 2, 3]
+ // 4 - 3 = 1
+ // target[3:4]
+ length = size - start
+ }
+
+ return toValue_string(target[start : start+length])
+}
+
+func builtinString_toLowerCase(call FunctionCall) Value {
+ checkObjectCoercible(call.runtime, call.This)
+ return toValue_string(strings.ToLower(call.This.string()))
+}
+
+func builtinString_toUpperCase(call FunctionCall) Value {
+ checkObjectCoercible(call.runtime, call.This)
+ return toValue_string(strings.ToUpper(call.This.string()))
+}
+
+// 7.2 Table 2 — Whitespace Characters & 7.3 Table 3 - Line Terminator Characters
+const builtinString_trim_whitespace = "\u0009\u000A\u000B\u000C\u000D\u0020\u00A0\u1680\u180E\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200A\u2028\u2029\u202F\u205F\u3000\uFEFF"
+
+func builtinString_trim(call FunctionCall) Value {
+ checkObjectCoercible(call.runtime, call.This)
+ return toValue(strings.Trim(call.This.string(),
+ builtinString_trim_whitespace))
+}
+
+// Mozilla extension, not ECMAScript 5
+func builtinString_trimLeft(call FunctionCall) Value {
+ checkObjectCoercible(call.runtime, call.This)
+ return toValue(strings.TrimLeft(call.This.string(),
+ builtinString_trim_whitespace))
+}
+
+// Mozilla extension, not ECMAScript 5
+func builtinString_trimRight(call FunctionCall) Value {
+ checkObjectCoercible(call.runtime, call.This)
+ return toValue(strings.TrimRight(call.This.string(),
+ builtinString_trim_whitespace))
+}
+
+func builtinString_localeCompare(call FunctionCall) Value {
+ checkObjectCoercible(call.runtime, call.This)
+ this := call.This.string()
+ that := call.Argument(0).string()
+ if this < that {
+ return toValue_int(-1)
+ } else if this == that {
+ return toValue_int(0)
+ }
+ return toValue_int(1)
+}
+
+/*
+An alternate version of String.trim
+func builtinString_trim(call FunctionCall) Value {
+ checkObjectCoercible(call.This)
+ return toValue_string(strings.TrimFunc(call.string(.This), isWhiteSpaceOrLineTerminator))
+}
+*/
+
+func builtinString_toLocaleLowerCase(call FunctionCall) Value {
+ return builtinString_toLowerCase(call)
+}
+
+func builtinString_toLocaleUpperCase(call FunctionCall) Value {
+ return builtinString_toUpperCase(call)
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/builtin_test.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/builtin_test.go
new file mode 100644
index 000000000..f5be00ab6
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/builtin_test.go
@@ -0,0 +1,136 @@
+package otto
+
+import (
+ "testing"
+)
+
+func TestString_substr(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ [
+ "abc".substr(0,1), // "a"
+ "abc".substr(0,2), // "ab"
+ "abc".substr(0,3), // "abc"
+ "abc".substr(0,4), // "abc"
+ "abc".substr(0,9), // "abc"
+ ];
+ `, "a,ab,abc,abc,abc")
+
+ test(`
+ [
+ "abc".substr(1,1), // "b"
+ "abc".substr(1,2), // "bc"
+ "abc".substr(1,3), // "bc"
+ "abc".substr(1,4), // "bc"
+ "abc".substr(1,9), // "bc"
+ ];
+ `, "b,bc,bc,bc,bc")
+
+ test(`
+ [
+ "abc".substr(2,1), // "c"
+ "abc".substr(2,2), // "c"
+ "abc".substr(2,3), // "c"
+ "abc".substr(2,4), // "c"
+ "abc".substr(2,9), // "c"
+ ];
+ `, "c,c,c,c,c")
+
+ test(`
+ [
+ "abc".substr(3,1), // ""
+ "abc".substr(3,2), // ""
+ "abc".substr(3,3), // ""
+ "abc".substr(3,4), // ""
+ "abc".substr(3,9), // ""
+ ];
+ `, ",,,,")
+
+ test(`
+ [
+ "abc".substr(0), // "abc"
+ "abc".substr(1), // "bc"
+ "abc".substr(2), // "c"
+ "abc".substr(3), // ""
+ "abc".substr(9), // ""
+ ];
+ `, "abc,bc,c,,")
+
+ test(`
+ [
+ "abc".substr(-9), // "abc"
+ "abc".substr(-3), // "abc"
+ "abc".substr(-2), // "bc"
+ "abc".substr(-1), // "c"
+ ];
+ `, "abc,abc,bc,c")
+
+ test(`
+ [
+ "abc".substr(-9, 1), // "a"
+ "abc".substr(-3, 1), // "a"
+ "abc".substr(-2, 1), // "b"
+ "abc".substr(-1, 1), // "c"
+ "abc".substr(-1, 2), // "c"
+ ];
+ `, "a,a,b,c,c")
+
+ test(`"abcd".substr(3, 5)`, "d")
+ })
+}
+
+func Test_builtin_escape(t *testing.T) {
+ tt(t, func() {
+ is(builtin_escape("abc"), "abc")
+
+ is(builtin_escape("="), "%3D")
+
+ is(builtin_escape("abc=%+32"), "abc%3D%25+32")
+
+ is(builtin_escape("世界"), "%u4E16%u754C")
+ })
+}
+
+func Test_builtin_unescape(t *testing.T) {
+ tt(t, func() {
+ is(builtin_unescape("abc"), "abc")
+
+ is(builtin_unescape("=%3D"), "==")
+
+ is(builtin_unescape("abc%3D%25+32"), "abc=%+32")
+
+ is(builtin_unescape("%u4E16%u754C"), "世界")
+ })
+}
+
+func TestGlobal_escape(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ [
+ escape("abc"), // "abc"
+ escape("="), // "%3D"
+ escape("abc=%+32"), // "abc%3D%25+32"
+ escape("\u4e16\u754c"), // "%u4E16%u754C"
+ ];
+ `, "abc,%3D,abc%3D%25+32,%u4E16%u754C")
+ })
+}
+
+func TestGlobal_unescape(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ [
+ unescape("abc"), // "abc"
+ unescape("=%3D"), // "=="
+ unescape("abc%3D%25+32"), // "abc=%+32"
+ unescape("%u4E16%u754C"), // "世界"
+ ];
+ `, "abc,==,abc=%+32,世界")
+ })
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/clone.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/clone.go
new file mode 100644
index 000000000..f79901b35
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/clone.go
@@ -0,0 +1,155 @@
+package otto
+
+import (
+ "fmt"
+)
+
+type _clone struct {
+ runtime *_runtime
+ _object map[*_object]*_object
+ _objectStash map[*_objectStash]*_objectStash
+ _dclStash map[*_dclStash]*_dclStash
+ _fnStash map[*_fnStash]*_fnStash
+}
+
+func (in *_runtime) clone() *_runtime {
+
+ in.lck.Lock()
+ defer in.lck.Unlock()
+
+ out := &_runtime{}
+ clone := _clone{
+ runtime: out,
+ _object: make(map[*_object]*_object),
+ _objectStash: make(map[*_objectStash]*_objectStash),
+ _dclStash: make(map[*_dclStash]*_dclStash),
+ _fnStash: make(map[*_fnStash]*_fnStash),
+ }
+
+ globalObject := clone.object(in.globalObject)
+ out.globalStash = out.newObjectStash(globalObject, nil)
+ out.globalObject = globalObject
+ out.global = _global{
+ clone.object(in.global.Object),
+ clone.object(in.global.Function),
+ clone.object(in.global.Array),
+ clone.object(in.global.String),
+ clone.object(in.global.Boolean),
+ clone.object(in.global.Number),
+ clone.object(in.global.Math),
+ clone.object(in.global.Date),
+ clone.object(in.global.RegExp),
+ clone.object(in.global.Error),
+ clone.object(in.global.EvalError),
+ clone.object(in.global.TypeError),
+ clone.object(in.global.RangeError),
+ clone.object(in.global.ReferenceError),
+ clone.object(in.global.SyntaxError),
+ clone.object(in.global.URIError),
+ clone.object(in.global.JSON),
+
+ clone.object(in.global.ObjectPrototype),
+ clone.object(in.global.FunctionPrototype),
+ clone.object(in.global.ArrayPrototype),
+ clone.object(in.global.StringPrototype),
+ clone.object(in.global.BooleanPrototype),
+ clone.object(in.global.NumberPrototype),
+ clone.object(in.global.DatePrototype),
+ clone.object(in.global.RegExpPrototype),
+ clone.object(in.global.ErrorPrototype),
+ clone.object(in.global.EvalErrorPrototype),
+ clone.object(in.global.TypeErrorPrototype),
+ clone.object(in.global.RangeErrorPrototype),
+ clone.object(in.global.ReferenceErrorPrototype),
+ clone.object(in.global.SyntaxErrorPrototype),
+ clone.object(in.global.URIErrorPrototype),
+ }
+
+ out.eval = out.globalObject.property["eval"].value.(Value).value.(*_object)
+ out.globalObject.prototype = out.global.ObjectPrototype
+
+ // Not sure if this is necessary, but give some help to the GC
+ clone.runtime = nil
+ clone._object = nil
+ clone._objectStash = nil
+ clone._dclStash = nil
+ clone._fnStash = nil
+
+ return out
+}
+
+func (clone *_clone) object(in *_object) *_object {
+ if out, exists := clone._object[in]; exists {
+ return out
+ }
+ out := &_object{}
+ clone._object[in] = out
+ return in.objectClass.clone(in, out, clone)
+}
+
+func (clone *_clone) dclStash(in *_dclStash) (*_dclStash, bool) {
+ if out, exists := clone._dclStash[in]; exists {
+ return out, true
+ }
+ out := &_dclStash{}
+ clone._dclStash[in] = out
+ return out, false
+}
+
+func (clone *_clone) objectStash(in *_objectStash) (*_objectStash, bool) {
+ if out, exists := clone._objectStash[in]; exists {
+ return out, true
+ }
+ out := &_objectStash{}
+ clone._objectStash[in] = out
+ return out, false
+}
+
+func (clone *_clone) fnStash(in *_fnStash) (*_fnStash, bool) {
+ if out, exists := clone._fnStash[in]; exists {
+ return out, true
+ }
+ out := &_fnStash{}
+ clone._fnStash[in] = out
+ return out, false
+}
+
+func (clone *_clone) value(in Value) Value {
+ out := in
+ switch value := in.value.(type) {
+ case *_object:
+ out.value = clone.object(value)
+ }
+ return out
+}
+
+func (clone *_clone) valueArray(in []Value) []Value {
+ out := make([]Value, len(in))
+ for index, value := range in {
+ out[index] = clone.value(value)
+ }
+ return out
+}
+
+func (clone *_clone) stash(in _stash) _stash {
+ if in == nil {
+ return nil
+ }
+ return in.clone(clone)
+}
+
+func (clone *_clone) property(in _property) _property {
+ out := in
+ if value, valid := in.value.(Value); valid {
+ out.value = clone.value(value)
+ } else {
+ panic(fmt.Errorf("in.value.(Value) != true"))
+ }
+ return out
+}
+
+func (clone *_clone) dclProperty(in _dclProperty) _dclProperty {
+ out := in
+ out.value = clone.value(in.value)
+ return out
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/cmpl.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/cmpl.go
new file mode 100644
index 000000000..c191b4527
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/cmpl.go
@@ -0,0 +1,24 @@
+package otto
+
+import (
+ "github.com/robertkrimen/otto/ast"
+ "github.com/robertkrimen/otto/file"
+)
+
+type _file struct {
+ name string
+ src string
+ base int // This will always be 1 or greater
+}
+
+type _compiler struct {
+ file *file.File
+ program *ast.Program
+}
+
+func (cmpl *_compiler) parse() *_nodeProgram {
+ if cmpl.program != nil {
+ cmpl.file = cmpl.program.File
+ }
+ return cmpl._parse(cmpl.program)
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/cmpl_evaluate.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/cmpl_evaluate.go
new file mode 100644
index 000000000..6741bf394
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/cmpl_evaluate.go
@@ -0,0 +1,96 @@
+package otto
+
+import (
+ "strconv"
+)
+
+func (self *_runtime) cmpl_evaluate_nodeProgram(node *_nodeProgram, eval bool) Value {
+ if !eval {
+ self.enterGlobalScope()
+ defer func() {
+ self.leaveScope()
+ }()
+ }
+ self.cmpl_functionDeclaration(node.functionList)
+ self.cmpl_variableDeclaration(node.varList)
+ self.scope.frame.file = node.file
+ return self.cmpl_evaluate_nodeStatementList(node.body)
+}
+
+func (self *_runtime) cmpl_call_nodeFunction(function *_object, stash *_fnStash, node *_nodeFunctionLiteral, this Value, argumentList []Value) Value {
+
+ indexOfParameterName := make([]string, len(argumentList))
+ // function(abc, def, ghi)
+ // indexOfParameterName[0] = "abc"
+ // indexOfParameterName[1] = "def"
+ // indexOfParameterName[2] = "ghi"
+ // ...
+
+ argumentsFound := false
+ for index, name := range node.parameterList {
+ if name == "arguments" {
+ argumentsFound = true
+ }
+ value := Value{}
+ if index < len(argumentList) {
+ value = argumentList[index]
+ indexOfParameterName[index] = name
+ }
+ // strict = false
+ self.scope.lexical.setValue(name, value, false)
+ }
+
+ if !argumentsFound {
+ arguments := self.newArgumentsObject(indexOfParameterName, stash, len(argumentList))
+ arguments.defineProperty("callee", toValue_object(function), 0101, false)
+ stash.arguments = arguments
+ // strict = false
+ self.scope.lexical.setValue("arguments", toValue_object(arguments), false)
+ for index, _ := range argumentList {
+ if index < len(node.parameterList) {
+ continue
+ }
+ indexAsString := strconv.FormatInt(int64(index), 10)
+ arguments.defineProperty(indexAsString, argumentList[index], 0111, false)
+ }
+ }
+
+ self.cmpl_functionDeclaration(node.functionList)
+ self.cmpl_variableDeclaration(node.varList)
+
+ result := self.cmpl_evaluate_nodeStatement(node.body)
+ if result.kind == valueResult {
+ return result
+ }
+
+ return Value{}
+}
+
+func (self *_runtime) cmpl_functionDeclaration(list []*_nodeFunctionLiteral) {
+ executionContext := self.scope
+ eval := executionContext.eval
+ stash := executionContext.variable
+
+ for _, function := range list {
+ name := function.name
+ value := self.cmpl_evaluate_nodeExpression(function)
+ if !stash.hasBinding(name) {
+ stash.createBinding(name, eval == true, value)
+ } else {
+ // TODO 10.5.5.e
+ stash.setBinding(name, value, false) // TODO strict
+ }
+ }
+}
+
+func (self *_runtime) cmpl_variableDeclaration(list []string) {
+ executionContext := self.scope
+ eval := executionContext.eval
+ stash := executionContext.variable
+
+ for _, name := range list {
+ if !stash.hasBinding(name) {
+ stash.createBinding(name, eval == true, Value{}) // TODO strict?
+ }
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/cmpl_evaluate_expression.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/cmpl_evaluate_expression.go
new file mode 100644
index 000000000..34449970e
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/cmpl_evaluate_expression.go
@@ -0,0 +1,456 @@
+package otto
+
+import (
+ "fmt"
+ "math"
+ "runtime"
+
+ "github.com/robertkrimen/otto/token"
+)
+
+func (self *_runtime) cmpl_evaluate_nodeExpression(node _nodeExpression) Value {
+ // Allow interpreter interruption
+ // If the Interrupt channel is nil, then
+ // we avoid runtime.Gosched() overhead (if any)
+ // FIXME: Test this
+ if self.otto.Interrupt != nil {
+ runtime.Gosched()
+ select {
+ case value := <-self.otto.Interrupt:
+ value()
+ default:
+ }
+ }
+
+ switch node := node.(type) {
+
+ case *_nodeArrayLiteral:
+ return self.cmpl_evaluate_nodeArrayLiteral(node)
+
+ case *_nodeAssignExpression:
+ return self.cmpl_evaluate_nodeAssignExpression(node)
+
+ case *_nodeBinaryExpression:
+ if node.comparison {
+ return self.cmpl_evaluate_nodeBinaryExpression_comparison(node)
+ } else {
+ return self.cmpl_evaluate_nodeBinaryExpression(node)
+ }
+
+ case *_nodeBracketExpression:
+ return self.cmpl_evaluate_nodeBracketExpression(node)
+
+ case *_nodeCallExpression:
+ return self.cmpl_evaluate_nodeCallExpression(node, nil)
+
+ case *_nodeConditionalExpression:
+ return self.cmpl_evaluate_nodeConditionalExpression(node)
+
+ case *_nodeDotExpression:
+ return self.cmpl_evaluate_nodeDotExpression(node)
+
+ case *_nodeFunctionLiteral:
+ var local = self.scope.lexical
+ if node.name != "" {
+ local = self.newDeclarationStash(local)
+ }
+
+ value := toValue_object(self.newNodeFunction(node, local))
+ if node.name != "" {
+ local.createBinding(node.name, false, value)
+ }
+ return value
+
+ case *_nodeIdentifier:
+ name := node.name
+ // TODO Should be true or false (strictness) depending on context
+ // getIdentifierReference should not return nil, but we check anyway and panic
+ // so as not to propagate the nil into something else
+ reference := getIdentifierReference(self, self.scope.lexical, name, false, _at(node.idx))
+ if reference == nil {
+ // Should never get here!
+ panic(hereBeDragons("referenceError == nil: " + name))
+ }
+ return toValue(reference)
+
+ case *_nodeLiteral:
+ return node.value
+
+ case *_nodeNewExpression:
+ return self.cmpl_evaluate_nodeNewExpression(node)
+
+ case *_nodeObjectLiteral:
+ return self.cmpl_evaluate_nodeObjectLiteral(node)
+
+ case *_nodeRegExpLiteral:
+ return toValue_object(self._newRegExp(node.pattern, node.flags))
+
+ case *_nodeSequenceExpression:
+ return self.cmpl_evaluate_nodeSequenceExpression(node)
+
+ case *_nodeThisExpression:
+ return toValue_object(self.scope.this)
+
+ case *_nodeUnaryExpression:
+ return self.cmpl_evaluate_nodeUnaryExpression(node)
+
+ case *_nodeVariableExpression:
+ return self.cmpl_evaluate_nodeVariableExpression(node)
+ }
+
+ panic(fmt.Errorf("Here be dragons: evaluate_nodeExpression(%T)", node))
+}
+
+func (self *_runtime) cmpl_evaluate_nodeArrayLiteral(node *_nodeArrayLiteral) Value {
+
+ valueArray := []Value{}
+
+ for _, node := range node.value {
+ if node == nil {
+ valueArray = append(valueArray, emptyValue)
+ } else {
+ valueArray = append(valueArray, self.cmpl_evaluate_nodeExpression(node).resolve())
+ }
+ }
+
+ result := self.newArrayOf(valueArray)
+
+ return toValue_object(result)
+}
+
+func (self *_runtime) cmpl_evaluate_nodeAssignExpression(node *_nodeAssignExpression) Value {
+
+ left := self.cmpl_evaluate_nodeExpression(node.left)
+ right := self.cmpl_evaluate_nodeExpression(node.right)
+ rightValue := right.resolve()
+
+ result := rightValue
+ if node.operator != token.ASSIGN {
+ result = self.calculateBinaryExpression(node.operator, left, rightValue)
+ }
+
+ self.putValue(left.reference(), result)
+
+ return result
+}
+
+func (self *_runtime) cmpl_evaluate_nodeBinaryExpression(node *_nodeBinaryExpression) Value {
+
+ left := self.cmpl_evaluate_nodeExpression(node.left)
+ leftValue := left.resolve()
+
+ switch node.operator {
+ // Logical
+ case token.LOGICAL_AND:
+ if !leftValue.bool() {
+ return leftValue
+ }
+ right := self.cmpl_evaluate_nodeExpression(node.right)
+ return right.resolve()
+ case token.LOGICAL_OR:
+ if leftValue.bool() {
+ return leftValue
+ }
+ right := self.cmpl_evaluate_nodeExpression(node.right)
+ return right.resolve()
+ }
+
+ return self.calculateBinaryExpression(node.operator, leftValue, self.cmpl_evaluate_nodeExpression(node.right))
+}
+
+func (self *_runtime) cmpl_evaluate_nodeBinaryExpression_comparison(node *_nodeBinaryExpression) Value {
+
+ left := self.cmpl_evaluate_nodeExpression(node.left).resolve()
+ right := self.cmpl_evaluate_nodeExpression(node.right).resolve()
+
+ return toValue_bool(self.calculateComparison(node.operator, left, right))
+}
+
+func (self *_runtime) cmpl_evaluate_nodeBracketExpression(node *_nodeBracketExpression) Value {
+ target := self.cmpl_evaluate_nodeExpression(node.left)
+ targetValue := target.resolve()
+ member := self.cmpl_evaluate_nodeExpression(node.member)
+ memberValue := member.resolve()
+
+ // TODO Pass in base value as-is, and defer toObject till later?
+ return toValue(newPropertyReference(self, self.toObject(targetValue), memberValue.string(), false, _at(node.idx)))
+}
+
+func (self *_runtime) cmpl_evaluate_nodeCallExpression(node *_nodeCallExpression, withArgumentList []interface{}) Value {
+ rt := self
+ this := Value{}
+ callee := self.cmpl_evaluate_nodeExpression(node.callee)
+
+ argumentList := []Value{}
+ if withArgumentList != nil {
+ argumentList = self.toValueArray(withArgumentList...)
+ } else {
+ for _, argumentNode := range node.argumentList {
+ argumentList = append(argumentList, self.cmpl_evaluate_nodeExpression(argumentNode).resolve())
+ }
+ }
+
+ rf := callee.reference()
+ vl := callee.resolve()
+
+ eval := false // Whether this call is a (candidate for) direct call to eval
+ name := ""
+ if rf != nil {
+ switch rf := rf.(type) {
+ case *_propertyReference:
+ name = rf.name
+ object := rf.base
+ this = toValue_object(object)
+ eval = rf.name == "eval" // Possible direct eval
+ case *_stashReference:
+ // TODO ImplicitThisValue
+ name = rf.name
+ eval = rf.name == "eval" // Possible direct eval
+ default:
+ // FIXME?
+ panic(rt.panicTypeError("Here be dragons"))
+ }
+ }
+
+ at := _at(-1)
+ switch callee := node.callee.(type) {
+ case *_nodeIdentifier:
+ at = _at(callee.idx)
+ case *_nodeDotExpression:
+ at = _at(callee.idx)
+ case *_nodeBracketExpression:
+ at = _at(callee.idx)
+ }
+
+ frame := _frame{
+ callee: name,
+ file: self.scope.frame.file,
+ }
+
+ if !vl.IsFunction() {
+ if name == "" {
+ // FIXME Maybe typeof?
+ panic(rt.panicTypeError("%v is not a function", vl, at))
+ }
+ panic(rt.panicTypeError("'%s' is not a function", name, at))
+ }
+
+ self.scope.frame.offset = int(at)
+
+ return vl._object().call(this, argumentList, eval, frame)
+}
+
+func (self *_runtime) cmpl_evaluate_nodeConditionalExpression(node *_nodeConditionalExpression) Value {
+ test := self.cmpl_evaluate_nodeExpression(node.test)
+ testValue := test.resolve()
+ if testValue.bool() {
+ return self.cmpl_evaluate_nodeExpression(node.consequent)
+ }
+ return self.cmpl_evaluate_nodeExpression(node.alternate)
+}
+
+func (self *_runtime) cmpl_evaluate_nodeDotExpression(node *_nodeDotExpression) Value {
+ target := self.cmpl_evaluate_nodeExpression(node.left)
+ targetValue := target.resolve()
+ // TODO Pass in base value as-is, and defer toObject till later?
+ object, err := self.objectCoerce(targetValue)
+ if err != nil {
+ panic(self.panicTypeError("Cannot access member '%s' of %s", node.identifier, err.Error()))
+ }
+ return toValue(newPropertyReference(self, object, node.identifier, false, _at(node.idx)))
+}
+
+func (self *_runtime) cmpl_evaluate_nodeNewExpression(node *_nodeNewExpression) Value {
+ rt := self
+ callee := self.cmpl_evaluate_nodeExpression(node.callee)
+
+ argumentList := []Value{}
+ for _, argumentNode := range node.argumentList {
+ argumentList = append(argumentList, self.cmpl_evaluate_nodeExpression(argumentNode).resolve())
+ }
+
+ rf := callee.reference()
+ vl := callee.resolve()
+
+ name := ""
+ if rf != nil {
+ switch rf := rf.(type) {
+ case *_propertyReference:
+ name = rf.name
+ case *_stashReference:
+ name = rf.name
+ default:
+ panic(rt.panicTypeError("Here be dragons"))
+ }
+ }
+
+ at := _at(-1)
+ switch callee := node.callee.(type) {
+ case *_nodeIdentifier:
+ at = _at(callee.idx)
+ case *_nodeDotExpression:
+ at = _at(callee.idx)
+ case *_nodeBracketExpression:
+ at = _at(callee.idx)
+ }
+
+ if !vl.IsFunction() {
+ if name == "" {
+ // FIXME Maybe typeof?
+ panic(rt.panicTypeError("%v is not a function", vl, at))
+ }
+ panic(rt.panicTypeError("'%s' is not a function", name, at))
+ }
+
+ self.scope.frame.offset = int(at)
+
+ return vl._object().construct(argumentList)
+}
+
+func (self *_runtime) cmpl_evaluate_nodeObjectLiteral(node *_nodeObjectLiteral) Value {
+
+ result := self.newObject()
+
+ for _, property := range node.value {
+ switch property.kind {
+ case "value":
+ result.defineProperty(property.key, self.cmpl_evaluate_nodeExpression(property.value).resolve(), 0111, false)
+ case "get":
+ getter := self.newNodeFunction(property.value.(*_nodeFunctionLiteral), self.scope.lexical)
+ descriptor := _property{}
+ descriptor.mode = 0211
+ descriptor.value = _propertyGetSet{getter, nil}
+ result.defineOwnProperty(property.key, descriptor, false)
+ case "set":
+ setter := self.newNodeFunction(property.value.(*_nodeFunctionLiteral), self.scope.lexical)
+ descriptor := _property{}
+ descriptor.mode = 0211
+ descriptor.value = _propertyGetSet{nil, setter}
+ result.defineOwnProperty(property.key, descriptor, false)
+ default:
+ panic(fmt.Errorf("Here be dragons: evaluate_nodeObjectLiteral: invalid property.Kind: %v", property.kind))
+ }
+ }
+
+ return toValue_object(result)
+}
+
+func (self *_runtime) cmpl_evaluate_nodeSequenceExpression(node *_nodeSequenceExpression) Value {
+ var result Value
+ for _, node := range node.sequence {
+ result = self.cmpl_evaluate_nodeExpression(node)
+ result = result.resolve()
+ }
+ return result
+}
+
+func (self *_runtime) cmpl_evaluate_nodeUnaryExpression(node *_nodeUnaryExpression) Value {
+
+ target := self.cmpl_evaluate_nodeExpression(node.operand)
+ switch node.operator {
+ case token.TYPEOF, token.DELETE:
+ if target.kind == valueReference && target.reference().invalid() {
+ if node.operator == token.TYPEOF {
+ return toValue_string("undefined")
+ }
+ return trueValue
+ }
+ }
+
+ switch node.operator {
+ case token.NOT:
+ targetValue := target.resolve()
+ if targetValue.bool() {
+ return falseValue
+ }
+ return trueValue
+ case token.BITWISE_NOT:
+ targetValue := target.resolve()
+ integerValue := toInt32(targetValue)
+ return toValue_int32(^integerValue)
+ case token.PLUS:
+ targetValue := target.resolve()
+ return toValue_float64(targetValue.float64())
+ case token.MINUS:
+ targetValue := target.resolve()
+ value := targetValue.float64()
+ // TODO Test this
+ sign := float64(-1)
+ if math.Signbit(value) {
+ sign = 1
+ }
+ return toValue_float64(math.Copysign(value, sign))
+ case token.INCREMENT:
+ targetValue := target.resolve()
+ if node.postfix {
+ // Postfix++
+ oldValue := targetValue.float64()
+ newValue := toValue_float64(+1 + oldValue)
+ self.putValue(target.reference(), newValue)
+ return toValue_float64(oldValue)
+ } else {
+ // ++Prefix
+ newValue := toValue_float64(+1 + targetValue.float64())
+ self.putValue(target.reference(), newValue)
+ return newValue
+ }
+ case token.DECREMENT:
+ targetValue := target.resolve()
+ if node.postfix {
+ // Postfix--
+ oldValue := targetValue.float64()
+ newValue := toValue_float64(-1 + oldValue)
+ self.putValue(target.reference(), newValue)
+ return toValue_float64(oldValue)
+ } else {
+ // --Prefix
+ newValue := toValue_float64(-1 + targetValue.float64())
+ self.putValue(target.reference(), newValue)
+ return newValue
+ }
+ case token.VOID:
+ target.resolve() // FIXME Side effect?
+ return Value{}
+ case token.DELETE:
+ reference := target.reference()
+ if reference == nil {
+ return trueValue
+ }
+ return toValue_bool(target.reference().delete())
+ case token.TYPEOF:
+ targetValue := target.resolve()
+ switch targetValue.kind {
+ case valueUndefined:
+ return toValue_string("undefined")
+ case valueNull:
+ return toValue_string("object")
+ case valueBoolean:
+ return toValue_string("boolean")
+ case valueNumber:
+ return toValue_string("number")
+ case valueString:
+ return toValue_string("string")
+ case valueObject:
+ if targetValue._object().isCall() {
+ return toValue_string("function")
+ }
+ return toValue_string("object")
+ default:
+ // FIXME ?
+ }
+ }
+
+ panic(hereBeDragons())
+}
+
+func (self *_runtime) cmpl_evaluate_nodeVariableExpression(node *_nodeVariableExpression) Value {
+ if node.initializer != nil {
+ // FIXME If reference is nil
+ left := getIdentifierReference(self, self.scope.lexical, node.name, false, _at(node.idx))
+ right := self.cmpl_evaluate_nodeExpression(node.initializer)
+ rightValue := right.resolve()
+
+ self.putValue(left, rightValue)
+ }
+ return toValue_string(node.name)
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/cmpl_evaluate_statement.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/cmpl_evaluate_statement.go
new file mode 100644
index 000000000..7be158487
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/cmpl_evaluate_statement.go
@@ -0,0 +1,421 @@
+package otto
+
+import (
+ "fmt"
+ "runtime"
+
+ "github.com/robertkrimen/otto/token"
+)
+
+func (self *_runtime) cmpl_evaluate_nodeStatement(node _nodeStatement) Value {
+ // Allow interpreter interruption
+ // If the Interrupt channel is nil, then
+ // we avoid runtime.Gosched() overhead (if any)
+ // FIXME: Test this
+ if self.otto.Interrupt != nil {
+ runtime.Gosched()
+ select {
+ case value := <-self.otto.Interrupt:
+ value()
+ default:
+ }
+ }
+
+ switch node := node.(type) {
+
+ case *_nodeBlockStatement:
+ labels := self.labels
+ self.labels = nil
+
+ value := self.cmpl_evaluate_nodeStatementList(node.list)
+ switch value.kind {
+ case valueResult:
+ switch value.evaluateBreak(labels) {
+ case resultBreak:
+ return emptyValue
+ }
+ }
+ return value
+
+ case *_nodeBranchStatement:
+ target := node.label
+ switch node.branch { // FIXME Maybe node.kind? node.operator?
+ case token.BREAK:
+ return toValue(newBreakResult(target))
+ case token.CONTINUE:
+ return toValue(newContinueResult(target))
+ }
+
+ case *_nodeDebuggerStatement:
+ return emptyValue // Nothing happens.
+
+ case *_nodeDoWhileStatement:
+ return self.cmpl_evaluate_nodeDoWhileStatement(node)
+
+ case *_nodeEmptyStatement:
+ return emptyValue
+
+ case *_nodeExpressionStatement:
+ return self.cmpl_evaluate_nodeExpression(node.expression)
+
+ case *_nodeForInStatement:
+ return self.cmpl_evaluate_nodeForInStatement(node)
+
+ case *_nodeForStatement:
+ return self.cmpl_evaluate_nodeForStatement(node)
+
+ case *_nodeIfStatement:
+ return self.cmpl_evaluate_nodeIfStatement(node)
+
+ case *_nodeLabelledStatement:
+ self.labels = append(self.labels, node.label)
+ defer func() {
+ if len(self.labels) > 0 {
+ self.labels = self.labels[:len(self.labels)-1] // Pop the label
+ } else {
+ self.labels = nil
+ }
+ }()
+ return self.cmpl_evaluate_nodeStatement(node.statement)
+
+ case *_nodeReturnStatement:
+ if node.argument != nil {
+ return toValue(newReturnResult(self.cmpl_evaluate_nodeExpression(node.argument).resolve()))
+ }
+ return toValue(newReturnResult(Value{}))
+
+ case *_nodeSwitchStatement:
+ return self.cmpl_evaluate_nodeSwitchStatement(node)
+
+ case *_nodeThrowStatement:
+ value := self.cmpl_evaluate_nodeExpression(node.argument).resolve()
+ panic(newException(value))
+
+ case *_nodeTryStatement:
+ return self.cmpl_evaluate_nodeTryStatement(node)
+
+ case *_nodeVariableStatement:
+ // Variables are already defined, this is initialization only
+ for _, variable := range node.list {
+ self.cmpl_evaluate_nodeVariableExpression(variable.(*_nodeVariableExpression))
+ }
+ return emptyValue
+
+ case *_nodeWhileStatement:
+ return self.cmpl_evaluate_nodeWhileStatement(node)
+
+ case *_nodeWithStatement:
+ return self.cmpl_evaluate_nodeWithStatement(node)
+
+ }
+
+ panic(fmt.Errorf("Here be dragons: evaluate_nodeStatement(%T)", node))
+}
+
+func (self *_runtime) cmpl_evaluate_nodeStatementList(list []_nodeStatement) Value {
+ var result Value
+ for _, node := range list {
+ value := self.cmpl_evaluate_nodeStatement(node)
+ switch value.kind {
+ case valueResult:
+ return value
+ case valueEmpty:
+ default:
+ // We have getValue here to (for example) trigger a
+ // ReferenceError (of the not defined variety)
+ // Not sure if this is the best way to error out early
+ // for such errors or if there is a better way
+ // TODO Do we still need this?
+ result = value.resolve()
+ }
+ }
+ return result
+}
+
+func (self *_runtime) cmpl_evaluate_nodeDoWhileStatement(node *_nodeDoWhileStatement) Value {
+
+ labels := append(self.labels, "")
+ self.labels = nil
+
+ test := node.test
+
+ result := emptyValue
+resultBreak:
+ for {
+ for _, node := range node.body {
+ value := self.cmpl_evaluate_nodeStatement(node)
+ switch value.kind {
+ case valueResult:
+ switch value.evaluateBreakContinue(labels) {
+ case resultReturn:
+ return value
+ case resultBreak:
+ break resultBreak
+ case resultContinue:
+ goto resultContinue
+ }
+ case valueEmpty:
+ default:
+ result = value
+ }
+ }
+ resultContinue:
+ if !self.cmpl_evaluate_nodeExpression(test).resolve().bool() {
+ // Stahp: do ... while (false)
+ break
+ }
+ }
+ return result
+}
+
+func (self *_runtime) cmpl_evaluate_nodeForInStatement(node *_nodeForInStatement) Value {
+
+ labels := append(self.labels, "")
+ self.labels = nil
+
+ source := self.cmpl_evaluate_nodeExpression(node.source)
+ sourceValue := source.resolve()
+
+ switch sourceValue.kind {
+ case valueUndefined, valueNull:
+ return emptyValue
+ }
+
+ sourceObject := self.toObject(sourceValue)
+
+ into := node.into
+ body := node.body
+
+ result := emptyValue
+ object := sourceObject
+ for object != nil {
+ enumerateValue := emptyValue
+ object.enumerate(false, func(name string) bool {
+ into := self.cmpl_evaluate_nodeExpression(into)
+ // In the case of: for (var abc in def) ...
+ if into.reference() == nil {
+ identifier := into.string()
+ // TODO Should be true or false (strictness) depending on context
+ into = toValue(getIdentifierReference(self, self.scope.lexical, identifier, false, -1))
+ }
+ self.putValue(into.reference(), toValue_string(name))
+ for _, node := range body {
+ value := self.cmpl_evaluate_nodeStatement(node)
+ switch value.kind {
+ case valueResult:
+ switch value.evaluateBreakContinue(labels) {
+ case resultReturn:
+ enumerateValue = value
+ return false
+ case resultBreak:
+ object = nil
+ return false
+ case resultContinue:
+ return true
+ }
+ case valueEmpty:
+ default:
+ enumerateValue = value
+ }
+ }
+ return true
+ })
+ if object == nil {
+ break
+ }
+ object = object.prototype
+ if !enumerateValue.isEmpty() {
+ result = enumerateValue
+ }
+ }
+ return result
+}
+
+func (self *_runtime) cmpl_evaluate_nodeForStatement(node *_nodeForStatement) Value {
+
+ labels := append(self.labels, "")
+ self.labels = nil
+
+ initializer := node.initializer
+ test := node.test
+ update := node.update
+ body := node.body
+
+ if initializer != nil {
+ initialResult := self.cmpl_evaluate_nodeExpression(initializer)
+ initialResult.resolve() // Side-effect trigger
+ }
+
+ result := emptyValue
+resultBreak:
+ for {
+ if test != nil {
+ testResult := self.cmpl_evaluate_nodeExpression(test)
+ testResultValue := testResult.resolve()
+ if testResultValue.bool() == false {
+ break
+ }
+ }
+ for _, node := range body {
+ value := self.cmpl_evaluate_nodeStatement(node)
+ switch value.kind {
+ case valueResult:
+ switch value.evaluateBreakContinue(labels) {
+ case resultReturn:
+ return value
+ case resultBreak:
+ break resultBreak
+ case resultContinue:
+ goto resultContinue
+ }
+ case valueEmpty:
+ default:
+ result = value
+ }
+ }
+ resultContinue:
+ if update != nil {
+ updateResult := self.cmpl_evaluate_nodeExpression(update)
+ updateResult.resolve() // Side-effect trigger
+ }
+ }
+ return result
+}
+
+func (self *_runtime) cmpl_evaluate_nodeIfStatement(node *_nodeIfStatement) Value {
+ test := self.cmpl_evaluate_nodeExpression(node.test)
+ testValue := test.resolve()
+ if testValue.bool() {
+ return self.cmpl_evaluate_nodeStatement(node.consequent)
+ } else if node.alternate != nil {
+ return self.cmpl_evaluate_nodeStatement(node.alternate)
+ }
+
+ return emptyValue
+}
+
+func (self *_runtime) cmpl_evaluate_nodeSwitchStatement(node *_nodeSwitchStatement) Value {
+
+ labels := append(self.labels, "")
+ self.labels = nil
+
+ discriminantResult := self.cmpl_evaluate_nodeExpression(node.discriminant)
+ target := node.default_
+
+ for index, clause := range node.body {
+ test := clause.test
+ if test != nil {
+ if self.calculateComparison(token.STRICT_EQUAL, discriminantResult, self.cmpl_evaluate_nodeExpression(test)) {
+ target = index
+ break
+ }
+ }
+ }
+
+ result := emptyValue
+ if target != -1 {
+ for _, clause := range node.body[target:] {
+ for _, statement := range clause.consequent {
+ value := self.cmpl_evaluate_nodeStatement(statement)
+ switch value.kind {
+ case valueResult:
+ switch value.evaluateBreak(labels) {
+ case resultReturn:
+ return value
+ case resultBreak:
+ return emptyValue
+ }
+ case valueEmpty:
+ default:
+ result = value
+ }
+ }
+ }
+ }
+
+ return result
+}
+
+func (self *_runtime) cmpl_evaluate_nodeTryStatement(node *_nodeTryStatement) Value {
+ tryCatchValue, exception := self.tryCatchEvaluate(func() Value {
+ return self.cmpl_evaluate_nodeStatement(node.body)
+ })
+
+ if exception && node.catch != nil {
+ outer := self.scope.lexical
+ self.scope.lexical = self.newDeclarationStash(outer)
+ defer func() {
+ self.scope.lexical = outer
+ }()
+ // TODO If necessary, convert TypeError<runtime> => TypeError
+ // That, is, such errors can be thrown despite not being JavaScript "native"
+ // strict = false
+ self.scope.lexical.setValue(node.catch.parameter, tryCatchValue, false)
+
+ // FIXME node.CatchParameter
+ // FIXME node.Catch
+ tryCatchValue, exception = self.tryCatchEvaluate(func() Value {
+ return self.cmpl_evaluate_nodeStatement(node.catch.body)
+ })
+ }
+
+ if node.finally != nil {
+ finallyValue := self.cmpl_evaluate_nodeStatement(node.finally)
+ if finallyValue.kind == valueResult {
+ return finallyValue
+ }
+ }
+
+ if exception {
+ panic(newException(tryCatchValue))
+ }
+
+ return tryCatchValue
+}
+
+func (self *_runtime) cmpl_evaluate_nodeWhileStatement(node *_nodeWhileStatement) Value {
+
+ test := node.test
+ body := node.body
+ labels := append(self.labels, "")
+ self.labels = nil
+
+ result := emptyValue
+resultBreakContinue:
+ for {
+ if !self.cmpl_evaluate_nodeExpression(test).resolve().bool() {
+ // Stahp: while (false) ...
+ break
+ }
+ for _, node := range body {
+ value := self.cmpl_evaluate_nodeStatement(node)
+ switch value.kind {
+ case valueResult:
+ switch value.evaluateBreakContinue(labels) {
+ case resultReturn:
+ return value
+ case resultBreak:
+ break resultBreakContinue
+ case resultContinue:
+ continue resultBreakContinue
+ }
+ case valueEmpty:
+ default:
+ result = value
+ }
+ }
+ }
+ return result
+}
+
+func (self *_runtime) cmpl_evaluate_nodeWithStatement(node *_nodeWithStatement) Value {
+ object := self.cmpl_evaluate_nodeExpression(node.object)
+ outer := self.scope.lexical
+ lexical := self.newObjectStash(self.toObject(object.resolve()), outer)
+ self.scope.lexical = lexical
+ defer func() {
+ self.scope.lexical = outer
+ }()
+
+ return self.cmpl_evaluate_nodeStatement(node.body)
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/cmpl_parse.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/cmpl_parse.go
new file mode 100644
index 000000000..e758a5230
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/cmpl_parse.go
@@ -0,0 +1,650 @@
+package otto
+
+import (
+ "fmt"
+ "regexp"
+
+ "github.com/robertkrimen/otto/ast"
+ "github.com/robertkrimen/otto/file"
+ "github.com/robertkrimen/otto/token"
+)
+
+var trueLiteral = &_nodeLiteral{value: toValue_bool(true)}
+var falseLiteral = &_nodeLiteral{value: toValue_bool(false)}
+var nullLiteral = &_nodeLiteral{value: nullValue}
+var emptyStatement = &_nodeEmptyStatement{}
+
+func (cmpl *_compiler) parseExpression(in ast.Expression) _nodeExpression {
+ if in == nil {
+ return nil
+ }
+
+ switch in := in.(type) {
+
+ case *ast.ArrayLiteral:
+ out := &_nodeArrayLiteral{
+ value: make([]_nodeExpression, len(in.Value)),
+ }
+ for i, value := range in.Value {
+ out.value[i] = cmpl.parseExpression(value)
+ }
+ return out
+
+ case *ast.AssignExpression:
+ return &_nodeAssignExpression{
+ operator: in.Operator,
+ left: cmpl.parseExpression(in.Left),
+ right: cmpl.parseExpression(in.Right),
+ }
+
+ case *ast.BinaryExpression:
+ return &_nodeBinaryExpression{
+ operator: in.Operator,
+ left: cmpl.parseExpression(in.Left),
+ right: cmpl.parseExpression(in.Right),
+ comparison: in.Comparison,
+ }
+
+ case *ast.BooleanLiteral:
+ if in.Value {
+ return trueLiteral
+ }
+ return falseLiteral
+
+ case *ast.BracketExpression:
+ return &_nodeBracketExpression{
+ idx: in.Left.Idx0(),
+ left: cmpl.parseExpression(in.Left),
+ member: cmpl.parseExpression(in.Member),
+ }
+
+ case *ast.CallExpression:
+ out := &_nodeCallExpression{
+ callee: cmpl.parseExpression(in.Callee),
+ argumentList: make([]_nodeExpression, len(in.ArgumentList)),
+ }
+ for i, value := range in.ArgumentList {
+ out.argumentList[i] = cmpl.parseExpression(value)
+ }
+ return out
+
+ case *ast.ConditionalExpression:
+ return &_nodeConditionalExpression{
+ test: cmpl.parseExpression(in.Test),
+ consequent: cmpl.parseExpression(in.Consequent),
+ alternate: cmpl.parseExpression(in.Alternate),
+ }
+
+ case *ast.DotExpression:
+ return &_nodeDotExpression{
+ idx: in.Left.Idx0(),
+ left: cmpl.parseExpression(in.Left),
+ identifier: in.Identifier.Name,
+ }
+
+ case *ast.FunctionLiteral:
+ name := ""
+ if in.Name != nil {
+ name = in.Name.Name
+ }
+ out := &_nodeFunctionLiteral{
+ name: name,
+ body: cmpl.parseStatement(in.Body),
+ source: in.Source,
+ file: cmpl.file,
+ }
+ if in.ParameterList != nil {
+ list := in.ParameterList.List
+ out.parameterList = make([]string, len(list))
+ for i, value := range list {
+ out.parameterList[i] = value.Name
+ }
+ }
+ for _, value := range in.DeclarationList {
+ switch value := value.(type) {
+ case *ast.FunctionDeclaration:
+ out.functionList = append(out.functionList, cmpl.parseExpression(value.Function).(*_nodeFunctionLiteral))
+ case *ast.VariableDeclaration:
+ for _, value := range value.List {
+ out.varList = append(out.varList, value.Name)
+ }
+ default:
+ panic(fmt.Errorf("Here be dragons: parseProgram.declaration(%T)", value))
+ }
+ }
+ return out
+
+ case *ast.Identifier:
+ return &_nodeIdentifier{
+ idx: in.Idx,
+ name: in.Name,
+ }
+
+ case *ast.NewExpression:
+ out := &_nodeNewExpression{
+ callee: cmpl.parseExpression(in.Callee),
+ argumentList: make([]_nodeExpression, len(in.ArgumentList)),
+ }
+ for i, value := range in.ArgumentList {
+ out.argumentList[i] = cmpl.parseExpression(value)
+ }
+ return out
+
+ case *ast.NullLiteral:
+ return nullLiteral
+
+ case *ast.NumberLiteral:
+ return &_nodeLiteral{
+ value: toValue(in.Value),
+ }
+
+ case *ast.ObjectLiteral:
+ out := &_nodeObjectLiteral{
+ value: make([]_nodeProperty, len(in.Value)),
+ }
+ for i, value := range in.Value {
+ out.value[i] = _nodeProperty{
+ key: value.Key,
+ kind: value.Kind,
+ value: cmpl.parseExpression(value.Value),
+ }
+ }
+ return out
+
+ case *ast.RegExpLiteral:
+ return &_nodeRegExpLiteral{
+ flags: in.Flags,
+ pattern: in.Pattern,
+ }
+
+ case *ast.SequenceExpression:
+ out := &_nodeSequenceExpression{
+ sequence: make([]_nodeExpression, len(in.Sequence)),
+ }
+ for i, value := range in.Sequence {
+ out.sequence[i] = cmpl.parseExpression(value)
+ }
+ return out
+
+ case *ast.StringLiteral:
+ return &_nodeLiteral{
+ value: toValue_string(in.Value),
+ }
+
+ case *ast.ThisExpression:
+ return &_nodeThisExpression{}
+
+ case *ast.UnaryExpression:
+ return &_nodeUnaryExpression{
+ operator: in.Operator,
+ operand: cmpl.parseExpression(in.Operand),
+ postfix: in.Postfix,
+ }
+
+ case *ast.VariableExpression:
+ return &_nodeVariableExpression{
+ idx: in.Idx0(),
+ name: in.Name,
+ initializer: cmpl.parseExpression(in.Initializer),
+ }
+
+ }
+
+ panic(fmt.Errorf("Here be dragons: cmpl.parseExpression(%T)", in))
+}
+
+func (cmpl *_compiler) parseStatement(in ast.Statement) _nodeStatement {
+ if in == nil {
+ return nil
+ }
+
+ switch in := in.(type) {
+
+ case *ast.BlockStatement:
+ out := &_nodeBlockStatement{
+ list: make([]_nodeStatement, len(in.List)),
+ }
+ for i, value := range in.List {
+ out.list[i] = cmpl.parseStatement(value)
+ }
+ return out
+
+ case *ast.BranchStatement:
+ out := &_nodeBranchStatement{
+ branch: in.Token,
+ }
+ if in.Label != nil {
+ out.label = in.Label.Name
+ }
+ return out
+
+ case *ast.DebuggerStatement:
+ return &_nodeDebuggerStatement{}
+
+ case *ast.DoWhileStatement:
+ out := &_nodeDoWhileStatement{
+ test: cmpl.parseExpression(in.Test),
+ }
+ body := cmpl.parseStatement(in.Body)
+ if block, ok := body.(*_nodeBlockStatement); ok {
+ out.body = block.list
+ } else {
+ out.body = append(out.body, body)
+ }
+ return out
+
+ case *ast.EmptyStatement:
+ return emptyStatement
+
+ case *ast.ExpressionStatement:
+ return &_nodeExpressionStatement{
+ expression: cmpl.parseExpression(in.Expression),
+ }
+
+ case *ast.ForInStatement:
+ out := &_nodeForInStatement{
+ into: cmpl.parseExpression(in.Into),
+ source: cmpl.parseExpression(in.Source),
+ }
+ body := cmpl.parseStatement(in.Body)
+ if block, ok := body.(*_nodeBlockStatement); ok {
+ out.body = block.list
+ } else {
+ out.body = append(out.body, body)
+ }
+ return out
+
+ case *ast.ForStatement:
+ out := &_nodeForStatement{
+ initializer: cmpl.parseExpression(in.Initializer),
+ update: cmpl.parseExpression(in.Update),
+ test: cmpl.parseExpression(in.Test),
+ }
+ body := cmpl.parseStatement(in.Body)
+ if block, ok := body.(*_nodeBlockStatement); ok {
+ out.body = block.list
+ } else {
+ out.body = append(out.body, body)
+ }
+ return out
+
+ case *ast.IfStatement:
+ return &_nodeIfStatement{
+ test: cmpl.parseExpression(in.Test),
+ consequent: cmpl.parseStatement(in.Consequent),
+ alternate: cmpl.parseStatement(in.Alternate),
+ }
+
+ case *ast.LabelledStatement:
+ return &_nodeLabelledStatement{
+ label: in.Label.Name,
+ statement: cmpl.parseStatement(in.Statement),
+ }
+
+ case *ast.ReturnStatement:
+ return &_nodeReturnStatement{
+ argument: cmpl.parseExpression(in.Argument),
+ }
+
+ case *ast.SwitchStatement:
+ out := &_nodeSwitchStatement{
+ discriminant: cmpl.parseExpression(in.Discriminant),
+ default_: in.Default,
+ body: make([]*_nodeCaseStatement, len(in.Body)),
+ }
+ for i, clause := range in.Body {
+ out.body[i] = &_nodeCaseStatement{
+ test: cmpl.parseExpression(clause.Test),
+ consequent: make([]_nodeStatement, len(clause.Consequent)),
+ }
+ for j, value := range clause.Consequent {
+ out.body[i].consequent[j] = cmpl.parseStatement(value)
+ }
+ }
+ return out
+
+ case *ast.ThrowStatement:
+ return &_nodeThrowStatement{
+ argument: cmpl.parseExpression(in.Argument),
+ }
+
+ case *ast.TryStatement:
+ out := &_nodeTryStatement{
+ body: cmpl.parseStatement(in.Body),
+ finally: cmpl.parseStatement(in.Finally),
+ }
+ if in.Catch != nil {
+ out.catch = &_nodeCatchStatement{
+ parameter: in.Catch.Parameter.Name,
+ body: cmpl.parseStatement(in.Catch.Body),
+ }
+ }
+ return out
+
+ case *ast.VariableStatement:
+ out := &_nodeVariableStatement{
+ list: make([]_nodeExpression, len(in.List)),
+ }
+ for i, value := range in.List {
+ out.list[i] = cmpl.parseExpression(value)
+ }
+ return out
+
+ case *ast.WhileStatement:
+ out := &_nodeWhileStatement{
+ test: cmpl.parseExpression(in.Test),
+ }
+ body := cmpl.parseStatement(in.Body)
+ if block, ok := body.(*_nodeBlockStatement); ok {
+ out.body = block.list
+ } else {
+ out.body = append(out.body, body)
+ }
+ return out
+
+ case *ast.WithStatement:
+ return &_nodeWithStatement{
+ object: cmpl.parseExpression(in.Object),
+ body: cmpl.parseStatement(in.Body),
+ }
+
+ }
+
+ panic(fmt.Errorf("Here be dragons: cmpl.parseStatement(%T)", in))
+}
+
+func cmpl_parse(in *ast.Program) *_nodeProgram {
+ cmpl := _compiler{
+ program: in,
+ }
+ return cmpl.parse()
+}
+
+func (cmpl *_compiler) _parse(in *ast.Program) *_nodeProgram {
+ out := &_nodeProgram{
+ body: make([]_nodeStatement, len(in.Body)),
+ file: in.File,
+ }
+ for i, value := range in.Body {
+ out.body[i] = cmpl.parseStatement(value)
+ }
+ for _, value := range in.DeclarationList {
+ switch value := value.(type) {
+ case *ast.FunctionDeclaration:
+ out.functionList = append(out.functionList, cmpl.parseExpression(value.Function).(*_nodeFunctionLiteral))
+ case *ast.VariableDeclaration:
+ for _, value := range value.List {
+ out.varList = append(out.varList, value.Name)
+ }
+ default:
+ panic(fmt.Errorf("Here be dragons: cmpl.parseProgram.DeclarationList(%T)", value))
+ }
+ }
+ return out
+}
+
+type _nodeProgram struct {
+ body []_nodeStatement
+
+ varList []string
+ functionList []*_nodeFunctionLiteral
+
+ variableList []_nodeDeclaration
+
+ file *file.File
+}
+
+type _nodeDeclaration struct {
+ name string
+ definition _node
+}
+
+type _node interface {
+}
+
+type (
+ _nodeExpression interface {
+ _node
+ _expressionNode()
+ }
+
+ _nodeArrayLiteral struct {
+ value []_nodeExpression
+ }
+
+ _nodeAssignExpression struct {
+ operator token.Token
+ left _nodeExpression
+ right _nodeExpression
+ }
+
+ _nodeBinaryExpression struct {
+ operator token.Token
+ left _nodeExpression
+ right _nodeExpression
+ comparison bool
+ }
+
+ _nodeBracketExpression struct {
+ idx file.Idx
+ left _nodeExpression
+ member _nodeExpression
+ }
+
+ _nodeCallExpression struct {
+ callee _nodeExpression
+ argumentList []_nodeExpression
+ }
+
+ _nodeConditionalExpression struct {
+ test _nodeExpression
+ consequent _nodeExpression
+ alternate _nodeExpression
+ }
+
+ _nodeDotExpression struct {
+ idx file.Idx
+ left _nodeExpression
+ identifier string
+ }
+
+ _nodeFunctionLiteral struct {
+ name string
+ body _nodeStatement
+ source string
+ parameterList []string
+ varList []string
+ functionList []*_nodeFunctionLiteral
+ file *file.File
+ }
+
+ _nodeIdentifier struct {
+ idx file.Idx
+ name string
+ }
+
+ _nodeLiteral struct {
+ value Value
+ }
+
+ _nodeNewExpression struct {
+ callee _nodeExpression
+ argumentList []_nodeExpression
+ }
+
+ _nodeObjectLiteral struct {
+ value []_nodeProperty
+ }
+
+ _nodeProperty struct {
+ key string
+ kind string
+ value _nodeExpression
+ }
+
+ _nodeRegExpLiteral struct {
+ flags string
+ pattern string // Value?
+ regexp *regexp.Regexp
+ }
+
+ _nodeSequenceExpression struct {
+ sequence []_nodeExpression
+ }
+
+ _nodeThisExpression struct {
+ }
+
+ _nodeUnaryExpression struct {
+ operator token.Token
+ operand _nodeExpression
+ postfix bool
+ }
+
+ _nodeVariableExpression struct {
+ idx file.Idx
+ name string
+ initializer _nodeExpression
+ }
+)
+
+type (
+ _nodeStatement interface {
+ _node
+ _statementNode()
+ }
+
+ _nodeBlockStatement struct {
+ list []_nodeStatement
+ }
+
+ _nodeBranchStatement struct {
+ branch token.Token
+ label string
+ }
+
+ _nodeCaseStatement struct {
+ test _nodeExpression
+ consequent []_nodeStatement
+ }
+
+ _nodeCatchStatement struct {
+ parameter string
+ body _nodeStatement
+ }
+
+ _nodeDebuggerStatement struct {
+ }
+
+ _nodeDoWhileStatement struct {
+ test _nodeExpression
+ body []_nodeStatement
+ }
+
+ _nodeEmptyStatement struct {
+ }
+
+ _nodeExpressionStatement struct {
+ expression _nodeExpression
+ }
+
+ _nodeForInStatement struct {
+ into _nodeExpression
+ source _nodeExpression
+ body []_nodeStatement
+ }
+
+ _nodeForStatement struct {
+ initializer _nodeExpression
+ update _nodeExpression
+ test _nodeExpression
+ body []_nodeStatement
+ }
+
+ _nodeIfStatement struct {
+ test _nodeExpression
+ consequent _nodeStatement
+ alternate _nodeStatement
+ }
+
+ _nodeLabelledStatement struct {
+ label string
+ statement _nodeStatement
+ }
+
+ _nodeReturnStatement struct {
+ argument _nodeExpression
+ }
+
+ _nodeSwitchStatement struct {
+ discriminant _nodeExpression
+ default_ int
+ body []*_nodeCaseStatement
+ }
+
+ _nodeThrowStatement struct {
+ argument _nodeExpression
+ }
+
+ _nodeTryStatement struct {
+ body _nodeStatement
+ catch *_nodeCatchStatement
+ finally _nodeStatement
+ }
+
+ _nodeVariableStatement struct {
+ list []_nodeExpression
+ }
+
+ _nodeWhileStatement struct {
+ test _nodeExpression
+ body []_nodeStatement
+ }
+
+ _nodeWithStatement struct {
+ object _nodeExpression
+ body _nodeStatement
+ }
+)
+
+// _expressionNode
+
+func (*_nodeArrayLiteral) _expressionNode() {}
+func (*_nodeAssignExpression) _expressionNode() {}
+func (*_nodeBinaryExpression) _expressionNode() {}
+func (*_nodeBracketExpression) _expressionNode() {}
+func (*_nodeCallExpression) _expressionNode() {}
+func (*_nodeConditionalExpression) _expressionNode() {}
+func (*_nodeDotExpression) _expressionNode() {}
+func (*_nodeFunctionLiteral) _expressionNode() {}
+func (*_nodeIdentifier) _expressionNode() {}
+func (*_nodeLiteral) _expressionNode() {}
+func (*_nodeNewExpression) _expressionNode() {}
+func (*_nodeObjectLiteral) _expressionNode() {}
+func (*_nodeRegExpLiteral) _expressionNode() {}
+func (*_nodeSequenceExpression) _expressionNode() {}
+func (*_nodeThisExpression) _expressionNode() {}
+func (*_nodeUnaryExpression) _expressionNode() {}
+func (*_nodeVariableExpression) _expressionNode() {}
+
+// _statementNode
+
+func (*_nodeBlockStatement) _statementNode() {}
+func (*_nodeBranchStatement) _statementNode() {}
+func (*_nodeCaseStatement) _statementNode() {}
+func (*_nodeCatchStatement) _statementNode() {}
+func (*_nodeDebuggerStatement) _statementNode() {}
+func (*_nodeDoWhileStatement) _statementNode() {}
+func (*_nodeEmptyStatement) _statementNode() {}
+func (*_nodeExpressionStatement) _statementNode() {}
+func (*_nodeForInStatement) _statementNode() {}
+func (*_nodeForStatement) _statementNode() {}
+func (*_nodeIfStatement) _statementNode() {}
+func (*_nodeLabelledStatement) _statementNode() {}
+func (*_nodeReturnStatement) _statementNode() {}
+func (*_nodeSwitchStatement) _statementNode() {}
+func (*_nodeThrowStatement) _statementNode() {}
+func (*_nodeTryStatement) _statementNode() {}
+func (*_nodeVariableStatement) _statementNode() {}
+func (*_nodeWhileStatement) _statementNode() {}
+func (*_nodeWithStatement) _statementNode() {}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/cmpl_test.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/cmpl_test.go
new file mode 100644
index 000000000..34b050f00
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/cmpl_test.go
@@ -0,0 +1,54 @@
+package otto
+
+import (
+ "testing"
+
+ "github.com/robertkrimen/otto/parser"
+)
+
+func Test_cmpl(t *testing.T) {
+ tt(t, func() {
+ vm := New()
+
+ test := func(src string, expect ...interface{}) {
+ program, err := parser.ParseFile(nil, "", src, 0)
+ is(err, nil)
+ {
+ program := cmpl_parse(program)
+ value := vm.runtime.cmpl_evaluate_nodeProgram(program, false)
+ if len(expect) > 0 {
+ is(value, expect[0])
+ }
+ }
+ }
+
+ test(``, Value{})
+
+ test(`var abc = 1; abc;`, 1)
+
+ test(`var abc = 1 + 1; abc;`, 2)
+
+ test(`1 + 2;`, 3)
+ })
+}
+
+func TestParse_cmpl(t *testing.T) {
+ tt(t, func() {
+
+ test := func(src string) {
+ program, err := parser.ParseFile(nil, "", src, 0)
+ is(err, nil)
+ is(cmpl_parse(program), "!=", nil)
+ }
+
+ test(``)
+
+ test(`var abc = 1; abc;`)
+
+ test(`
+ function abc() {
+ return;
+ }
+ `)
+ })
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/console.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/console.go
new file mode 100644
index 000000000..948face77
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/console.go
@@ -0,0 +1,51 @@
+package otto
+
+import (
+ "fmt"
+ "os"
+ "strings"
+)
+
+func formatForConsole(argumentList []Value) string {
+ output := []string{}
+ for _, argument := range argumentList {
+ output = append(output, fmt.Sprintf("%v", argument))
+ }
+ return strings.Join(output, " ")
+}
+
+func builtinConsole_log(call FunctionCall) Value {
+ fmt.Fprintln(os.Stdout, formatForConsole(call.ArgumentList))
+ return Value{}
+}
+
+func builtinConsole_error(call FunctionCall) Value {
+ fmt.Fprintln(os.Stdout, formatForConsole(call.ArgumentList))
+ return Value{}
+}
+
+// Nothing happens.
+func builtinConsole_dir(call FunctionCall) Value {
+ return Value{}
+}
+
+func builtinConsole_time(call FunctionCall) Value {
+ return Value{}
+}
+
+func builtinConsole_timeEnd(call FunctionCall) Value {
+ return Value{}
+}
+
+func builtinConsole_trace(call FunctionCall) Value {
+ return Value{}
+}
+
+func builtinConsole_assert(call FunctionCall) Value {
+ return Value{}
+}
+
+func (runtime *_runtime) newConsole() *_object {
+
+ return newConsoleObject(runtime)
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/date_test.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/date_test.go
new file mode 100644
index 000000000..a9c71edde
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/date_test.go
@@ -0,0 +1,481 @@
+package otto
+
+import (
+ "math"
+ "testing"
+ "time"
+)
+
+func mockTimeLocal(location *time.Location) func() {
+ local := time.Local
+ time.Local = location
+ return func() {
+ time.Local = local
+ }
+}
+
+// Passing or failing should not be dependent on what time zone we're in
+func mockUTC() func() {
+ return mockTimeLocal(time.UTC)
+}
+
+func TestDate(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ defer mockUTC()()
+
+ time0 := time.Unix(1348616313, 47*1000*1000).Local()
+
+ test(`Date`, "function Date() { [native code] }")
+ test(`new Date(0).toUTCString()`, "Thu, 01 Jan 1970 00:00:00 UTC")
+ test(`new Date(0).toGMTString()`, "Thu, 01 Jan 1970 00:00:00 GMT")
+ if false {
+ // TODO toLocale{Date,Time}String
+ test(`new Date(0).toLocaleString()`, "")
+ test(`new Date(0).toLocaleDateString()`, "")
+ test(`new Date(0).toLocaleTimeString()`, "")
+ }
+ test(`new Date(1348616313).getTime()`, 1348616313)
+ test(`new Date(1348616313).toUTCString()`, "Fri, 16 Jan 1970 14:36:56 UTC")
+ test(`abc = new Date(1348616313047); abc.toUTCString()`, "Tue, 25 Sep 2012 23:38:33 UTC")
+ test(`abc.getYear()`, time0.Year()-1900)
+ test(`abc.getFullYear()`, time0.Year())
+ test(`abc.getUTCFullYear()`, 2012)
+ test(`abc.getMonth()`, int(time0.Month())-1) // Remember, the JavaScript month is 0-based
+ test(`abc.getUTCMonth()`, 8)
+ test(`abc.getDate()`, time0.Day())
+ test(`abc.getUTCDate()`, 25)
+ test(`abc.getDay()`, int(time0.Weekday()))
+ test(`abc.getUTCDay()`, 2)
+ test(`abc.getHours()`, time0.Hour())
+ test(`abc.getUTCHours()`, 23)
+ test(`abc.getMinutes()`, time0.Minute())
+ test(`abc.getUTCMinutes()`, 38)
+ test(`abc.getSeconds()`, time0.Second())
+ test(`abc.getUTCSeconds()`, 33)
+ test(`abc.getMilliseconds()`, time0.Nanosecond()/(1000*1000)) // In honor of the 47%
+ test(`abc.getUTCMilliseconds()`, 47)
+ _, offset := time0.Zone()
+ test(`abc.getTimezoneOffset()`, offset/-60)
+
+ test(`new Date("Xyzzy").getTime()`, math.NaN())
+
+ test(`abc.setFullYear(2011); abc.toUTCString()`, "Sun, 25 Sep 2011 23:38:33 UTC")
+ test(`new Date(12564504e5).toUTCString()`, "Sun, 25 Oct 2009 06:00:00 UTC")
+ test(`new Date(2009, 9, 25).toUTCString()`, "Sun, 25 Oct 2009 00:00:00 UTC")
+ test(`+(new Date(2009, 9, 25))`, 1256428800000)
+
+ format := "Mon, 2 Jan 2006 15:04:05 MST"
+
+ time1 := time.Unix(1256450400, 0)
+ time0 = time.Date(time1.Year(), time1.Month(), time1.Day(), time1.Hour(), time1.Minute(), time1.Second(), time1.Nanosecond(), time1.Location()).UTC()
+
+ time0 = time.Date(time1.Year(), time1.Month(), time1.Day(), time1.Hour(), time1.Minute(), time1.Second(), 2001*1000*1000, time1.Location()).UTC()
+ test(`abc = new Date(12564504e5); abc.setMilliseconds(2001); abc.toUTCString()`, time0.Format(format))
+
+ time0 = time.Date(time1.Year(), time1.Month(), time1.Day(), time1.Hour(), time1.Minute(), 61, time1.Nanosecond(), time1.Location()).UTC()
+ test(`abc = new Date(12564504e5); abc.setSeconds("61"); abc.toUTCString()`, time0.Format(format))
+
+ time0 = time.Date(time1.Year(), time1.Month(), time1.Day(), time1.Hour(), 61, time1.Second(), time1.Nanosecond(), time1.Location()).UTC()
+ test(`abc = new Date(12564504e5); abc.setMinutes("61"); abc.toUTCString()`, time0.Format(format))
+
+ time0 = time.Date(time1.Year(), time1.Month(), time1.Day(), 5, time1.Minute(), time1.Second(), time1.Nanosecond(), time1.Location()).UTC()
+ test(`abc = new Date(12564504e5); abc.setHours("5"); abc.toUTCString()`, time0.Format(format))
+
+ time0 = time.Date(time1.Year(), time1.Month(), 26, time1.Hour(), time1.Minute(), time1.Second(), time1.Nanosecond(), time1.Location()).UTC()
+ test(`abc = new Date(12564504e5); abc.setDate("26"); abc.toUTCString()`, time0.Format(format))
+
+ time0 = time.Date(time1.Year(), 10, time1.Day(), time1.Hour(), time1.Minute(), time1.Second(), time1.Nanosecond(), time1.Location()).UTC()
+ test(`abc = new Date(12564504e5); abc.setMonth(9); abc.toUTCString()`, time0.Format(format))
+ test(`abc = new Date(12564504e5); abc.setMonth("09"); abc.toUTCString()`, time0.Format(format))
+
+ time0 = time.Date(time1.Year(), 11, time1.Day(), time1.Hour(), time1.Minute(), time1.Second(), time1.Nanosecond(), time1.Location()).UTC()
+ test(`abc = new Date(12564504e5); abc.setMonth("10"); abc.toUTCString()`, time0.Format(format))
+
+ time0 = time.Date(2010, time1.Month(), time1.Day(), time1.Hour(), time1.Minute(), time1.Second(), time1.Nanosecond(), time1.Location()).UTC()
+ test(`abc = new Date(12564504e5); abc.setFullYear(2010); abc.toUTCString()`, time0.Format(format))
+
+ test(`new Date("2001-01-01T10:01:02.000").getTime()`, 978343262000)
+
+ // Date()
+ test(`typeof Date()`, "string")
+ test(`typeof Date(2006, 1, 2)`, "string")
+
+ test(`
+ abc = Object.getOwnPropertyDescriptor(Date, "parse");
+ [ abc.value === Date.parse, abc.writable, abc.enumerable, abc.configurable ];
+ `, "true,true,false,true")
+
+ test(`
+ abc = Object.getOwnPropertyDescriptor(Date.prototype, "toTimeString");
+ [ abc.value === Date.prototype.toTimeString, abc.writable, abc.enumerable, abc.configurable ];
+ `, "true,true,false,true")
+
+ test(`
+ var abc = Object.getOwnPropertyDescriptor(Date, "prototype");
+ [ [ typeof Date.prototype ],
+ [ abc.writable, abc.enumerable, abc.configurable ] ];
+ `, "object,false,false,false")
+ })
+}
+
+func TestDate_parse(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ defer mockUTC()()
+
+ test(`Date.parse("2001-01-01T10:01:02.000")`, 978343262000)
+
+ test(`Date.parse("2006-01-02T15:04:05.000")`, 1136214245000)
+
+ test(`Date.parse("2006")`, 1136073600000)
+
+ test(`Date.parse("1970-01-16T14:36:56+00:00")`, 1348616000)
+
+ test(`Date.parse("1970-01-16T14:36:56.313+00:00")`, 1348616313)
+
+ test(`Date.parse("1970-01-16T14:36:56.000")`, 1348616000)
+
+ test(`Date.parse.length`, 1)
+ })
+}
+
+func TestDate_UTC(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ defer mockUTC()()
+
+ test(`Date.UTC(2009, 9, 25)`, 1256428800000)
+
+ test(`Date.UTC.length`, 7)
+ })
+}
+
+func TestDate_now(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ defer mockUTC()()
+
+ // FIXME I think this too risky
+ test(`+(""+Date.now()).substr(0, 10)`, float64(epochToInteger(timeToEpoch(time.Now()))/1000))
+
+ test(`Date.now() - Date.now(1,2,3) < 24 * 60 * 60`, true)
+ })
+}
+
+func TestDate_toISOString(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ defer mockUTC()()
+
+ test(`new Date(0).toISOString()`, "1970-01-01T00:00:00.000Z")
+ })
+}
+
+func TestDate_toJSON(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ defer mockUTC()()
+
+ test(`new Date(0).toJSON()`, "1970-01-01T00:00:00.000Z")
+ })
+}
+
+func TestDate_setYear(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ defer mockUTC()()
+
+ test(`new Date(12564504e5).setYear(96)`, 846223200000)
+
+ test(`new Date(12564504e5).setYear(1996)`, 846223200000)
+
+ test(`new Date(12564504e5).setYear(2000)`, 972453600000)
+ })
+}
+
+func TestDateDefaultValue(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ defer mockUTC()()
+
+ test(`
+ var date = new Date();
+ date + 0 === date.toString() + "0";
+ `, true)
+ })
+}
+
+func TestDate_April1978(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ defer mockUTC()()
+
+ test(`
+ var abc = new Date(1978,3);
+ [ abc.getYear(), abc.getMonth(), abc.valueOf() ];
+ `, "78,3,260236800000")
+ })
+}
+
+func TestDate_setMilliseconds(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ defer mockUTC()()
+
+ test(`
+ abc = new Date();
+ def = abc.setMilliseconds();
+ [ abc, def ];
+ `, "Invalid Date,NaN")
+ })
+}
+
+func TestDate_new(t *testing.T) {
+ // FIXME?
+ // This is probably incorrect, due to differences in Go date/time handling
+ // versus ECMA date/time handling, but we'll leave this here for
+ // future reference
+
+ if true {
+ return
+ }
+
+ tt(t, func() {
+ test, _ := test()
+
+ defer mockUTC()()
+
+ test(`
+ [
+ new Date(1899, 11).valueOf(),
+ new Date(1899, 12).valueOf(),
+ new Date(1900, 0).valueOf()
+ ]
+ `, "-2211638400000,-2208960000000,-2208960000000")
+ })
+}
+
+func TestDateComparison(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ defer mockUTC()()
+
+ test(`
+ var now0 = Date.now();
+ var now1 = (new Date()).toString();
+ [ now0 === now1, Math.abs(now0 - Date.parse(now1)) <= 1000 ];
+ `, "false,true")
+ })
+}
+
+func TestDate_setSeconds(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ defer mockUTC()()
+
+ test(`
+ abc = new Date(1980, 10);
+ def = new Date(abc);
+
+ abc.setSeconds(10, 12);
+
+ def.setSeconds(10);
+ def.setMilliseconds(12);
+
+ abc.valueOf() === def.valueOf();
+ `, true)
+
+ test(`
+ abc = new Date(1980, 10);
+ def = new Date(abc);
+
+ abc.setUTCSeconds(10, 12);
+
+ def.setUTCSeconds(10);
+ def.setUTCMilliseconds(12);
+
+ abc.valueOf() === def.valueOf();
+ `, true)
+
+ test(`Date.prototype.setSeconds.length`, 2)
+ test(`Date.prototype.setUTCSeconds.length`, 2)
+ })
+}
+
+func TestDate_setMinutes(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ defer mockUTC()()
+
+ test(`
+ abc = new Date(1980, 10);
+ def = new Date(abc);
+
+ abc.setMinutes(8, 10, 12);
+
+ def.setMinutes(8);
+ def.setSeconds(10);
+ def.setMilliseconds(12);
+
+ abc.valueOf() === def.valueOf();
+ `, true)
+
+ test(`
+ abc = new Date(1980, 10);
+ def = new Date(abc);
+
+ abc.setUTCMinutes(8, 10, 12);
+
+ def.setUTCMinutes(8);
+ def.setUTCSeconds(10);
+ def.setUTCMilliseconds(12);
+
+ abc.valueOf() === def.valueOf();
+ `, true)
+
+ test(`Date.prototype.setMinutes.length`, 3)
+ test(`Date.prototype.setUTCMinutes.length`, 3)
+ })
+}
+
+func TestDate_setHours(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ defer mockUTC()()
+
+ test(`
+ abc = new Date(1980, 10);
+ def = new Date(abc);
+
+ abc.setHours(6, 8, 10, 12);
+
+ def.setHours(6);
+ def.setMinutes(8);
+ def.setSeconds(10);
+ def.setMilliseconds(12);
+
+ abc.valueOf() === def.valueOf();
+ `, true)
+
+ test(`
+ abc = new Date(1980, 10);
+ def = new Date(abc);
+
+ abc.setUTCHours(6, 8, 10, 12);
+
+ def.setUTCHours(6);
+ def.setUTCMinutes(8);
+ def.setUTCSeconds(10);
+ def.setUTCMilliseconds(12);
+
+ abc.valueOf() === def.valueOf();
+ `, true)
+
+ test(`Date.prototype.setHours.length`, 4)
+ test(`Date.prototype.setUTCHours.length`, 4)
+ })
+}
+
+func TestDate_setMonth(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ defer mockUTC()()
+
+ test(`
+ abc = new Date(1980, 10);
+ def = new Date(abc);
+
+ abc.setMonth(6, 8);
+
+ def.setMonth(6);
+ def.setDate(8);
+
+ abc.valueOf() === def.valueOf();
+ `, true)
+
+ test(`
+ abc = new Date(1980, 10);
+ def = new Date(abc);
+
+ abc.setUTCMonth(6, 8);
+
+ def.setUTCMonth(6);
+ def.setUTCDate(8);
+
+ abc.valueOf() === def.valueOf();
+ `, true)
+
+ test(`Date.prototype.setMonth.length`, 2)
+ test(`Date.prototype.setUTCMonth.length`, 2)
+ })
+}
+
+func TestDate_setFullYear(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ defer mockUTC()()
+
+ test(`
+ abc = new Date(1980, 10);
+ def = new Date(abc);
+
+ abc.setFullYear(1981, 6, 8);
+
+ def.setFullYear(1981);
+ def.setMonth(6);
+ def.setDate(8);
+
+ abc.valueOf() === def.valueOf();
+ `, true)
+
+ test(`
+ abc = new Date(1980, 10);
+ def = new Date(abc);
+
+ abc.setUTCFullYear(1981, 6, 8);
+
+ def.setUTCFullYear(1981);
+ def.setUTCMonth(6);
+ def.setUTCDate(8);
+
+ abc.valueOf() === def.valueOf();
+ `, true)
+
+ test(`Date.prototype.setFullYear.length`, 3)
+ test(`Date.prototype.setUTCFullYear.length`, 3)
+ })
+}
+
+func TestDate_setTime(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ defer mockUTC()()
+
+ test(`
+ var abc = new Date(1999, 6, 1);
+ var def = new Date();
+ def.setTime(abc.getTime());
+ [ def, abc.valueOf() == def.valueOf() ];
+ `, "Thu, 01 Jul 1999 00:00:00 UTC,true")
+
+ test(`Date.prototype.setTime.length`, 1)
+ })
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/dbg.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/dbg.go
new file mode 100644
index 000000000..51fbdc206
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/dbg.go
@@ -0,0 +1,9 @@
+// This file was AUTOMATICALLY GENERATED by dbg-import (smuggol) for github.com/robertkrimen/dbg
+
+package otto
+
+import (
+ Dbg "github.com/robertkrimen/otto/dbg"
+)
+
+var dbg, dbgf = Dbg.New()
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/dbg/dbg.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/dbg/dbg.go
new file mode 100644
index 000000000..83bf6c573
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/dbg/dbg.go
@@ -0,0 +1,387 @@
+// This file was AUTOMATICALLY GENERATED by dbg-import (smuggol) from github.com/robertkrimen/dbg
+
+/*
+Package dbg is a println/printf/log-debugging utility library.
+
+ import (
+ Dbg "github.com/robertkrimen/dbg"
+ )
+
+ dbg, dbgf := Dbg.New()
+
+ dbg("Emit some debug stuff", []byte{120, 121, 122, 122, 121}, math.Pi)
+ # "2013/01/28 16:50:03 Emit some debug stuff [120 121 122 122 121] 3.141592653589793"
+
+ dbgf("With a %s formatting %.2f", "little", math.Pi)
+ # "2013/01/28 16:51:55 With a little formatting (3.14)"
+
+ dbgf("%/fatal//A fatal debug statement: should not be here")
+ # "A fatal debug statement: should not be here"
+ # ...and then, os.Exit(1)
+
+ dbgf("%/panic//Can also panic %s", "this")
+ # "Can also panic this"
+ # ...as a panic, equivalent to: panic("Can also panic this")
+
+ dbgf("Any %s arguments without a corresponding %%", "extra", "are treated like arguments to dbg()")
+ # "2013/01/28 17:14:40 Any extra arguments (without a corresponding %) are treated like arguments to dbg()"
+
+ dbgf("%d %d", 1, 2, 3, 4, 5)
+ # "2013/01/28 17:16:32 Another example: 1 2 3 4 5"
+
+ dbgf("%@: Include the function name for a little context (via %s)", "%@")
+ # "2013... github.com/robertkrimen/dbg.TestSynopsis: Include the function name for a little context (via %@)"
+
+By default, dbg uses log (log.Println, log.Printf, log.Panic, etc.) for output.
+However, you can also provide your own output destination by invoking dbg.New with
+a customization function:
+
+ import (
+ "bytes"
+ Dbg "github.com/robertkrimen/dbg"
+ "os"
+ )
+
+ # dbg to os.Stderr
+ dbg, dbgf := Dbg.New(func(dbgr *Dbgr) {
+ dbgr.SetOutput(os.Stderr)
+ })
+
+ # A slightly contrived example:
+ var buffer bytes.Buffer
+ dbg, dbgf := New(func(dbgr *Dbgr) {
+ dbgr.SetOutput(&buffer)
+ })
+
+*/
+package dbg
+
+import (
+ "bytes"
+ "fmt"
+ "io"
+ "log"
+ "os"
+ "regexp"
+ "runtime"
+ "strings"
+ "unicode"
+)
+
+type _frmt struct {
+ ctl string
+ format string
+ operandCount int
+ panic bool
+ fatal bool
+ check bool
+}
+
+var (
+ ctlTest = regexp.MustCompile(`^\s*%/`)
+ ctlScan = regexp.MustCompile(`%?/(panic|fatal|check)(?:\s|$)`)
+)
+
+func operandCount(format string) int {
+ count := 0
+ end := len(format)
+ for at := 0; at < end; {
+ for at < end && format[at] != '%' {
+ at++
+ }
+ at++
+ if at < end {
+ if format[at] != '%' && format[at] != '@' {
+ count++
+ }
+ at++
+ }
+ }
+ return count
+}
+
+func parseFormat(format string) (frmt _frmt) {
+ if ctlTest.MatchString(format) {
+ format = strings.TrimLeftFunc(format, unicode.IsSpace)
+ index := strings.Index(format, "//")
+ if index != -1 {
+ frmt.ctl = format[0:index]
+ format = format[index+2:] // Skip the second slash via +2 (instead of +1)
+ } else {
+ frmt.ctl = format
+ format = ""
+ }
+ for _, tmp := range ctlScan.FindAllStringSubmatch(frmt.ctl, -1) {
+ for _, value := range tmp[1:] {
+ switch value {
+ case "panic":
+ frmt.panic = true
+ case "fatal":
+ frmt.fatal = true
+ case "check":
+ frmt.check = true
+ }
+ }
+ }
+ }
+ frmt.format = format
+ frmt.operandCount = operandCount(format)
+ return
+}
+
+type Dbgr struct {
+ emit _emit
+}
+
+type DbgFunction func(values ...interface{})
+
+func NewDbgr() *Dbgr {
+ self := &Dbgr{}
+ return self
+}
+
+/*
+New will create and return a pair of debugging functions. You can customize where
+they output to by passing in an (optional) customization function:
+
+ import (
+ Dbg "github.com/robertkrimen/dbg"
+ "os"
+ )
+
+ # dbg to os.Stderr
+ dbg, dbgf := Dbg.New(func(dbgr *Dbgr) {
+ dbgr.SetOutput(os.Stderr)
+ })
+
+*/
+func New(options ...interface{}) (dbg DbgFunction, dbgf DbgFunction) {
+ dbgr := NewDbgr()
+ if len(options) > 0 {
+ if fn, ok := options[0].(func(*Dbgr)); ok {
+ fn(dbgr)
+ }
+ }
+ return dbgr.DbgDbgf()
+}
+
+func (self Dbgr) Dbg(values ...interface{}) {
+ self.getEmit().emit(_frmt{}, "", values...)
+}
+
+func (self Dbgr) Dbgf(values ...interface{}) {
+ self.dbgf(values...)
+}
+
+func (self Dbgr) DbgDbgf() (dbg DbgFunction, dbgf DbgFunction) {
+ dbg = func(vl ...interface{}) {
+ self.Dbg(vl...)
+ }
+ dbgf = func(vl ...interface{}) {
+ self.dbgf(vl...)
+ }
+ return dbg, dbgf // Redundant, but...
+}
+
+func (self Dbgr) dbgf(values ...interface{}) {
+
+ var frmt _frmt
+ if len(values) > 0 {
+ tmp := fmt.Sprint(values[0])
+ frmt = parseFormat(tmp)
+ values = values[1:]
+ }
+
+ buffer_f := bytes.Buffer{}
+ format := frmt.format
+ end := len(format)
+ for at := 0; at < end; {
+ last := at
+ for at < end && format[at] != '%' {
+ at++
+ }
+ if at > last {
+ buffer_f.WriteString(format[last:at])
+ }
+ if at >= end {
+ break
+ }
+ // format[at] == '%'
+ at++
+ // format[at] == ?
+ if format[at] == '@' {
+ depth := 2
+ pc, _, _, _ := runtime.Caller(depth)
+ name := runtime.FuncForPC(pc).Name()
+ buffer_f.WriteString(name)
+ } else {
+ buffer_f.WriteString(format[at-1 : at+1])
+ }
+ at++
+ }
+
+ //values_f := append([]interface{}{}, values[0:frmt.operandCount]...)
+ values_f := values[0:frmt.operandCount]
+ values_dbg := values[frmt.operandCount:]
+ if len(values_dbg) > 0 {
+ // Adjust frmt.format:
+ // (%v instead of %s because: frmt.check)
+ {
+ tmp := format
+ if len(tmp) > 0 {
+ if unicode.IsSpace(rune(tmp[len(tmp)-1])) {
+ buffer_f.WriteString("%v")
+ } else {
+ buffer_f.WriteString(" %v")
+ }
+ } else if frmt.check {
+ // Performing a check, so no output
+ } else {
+ buffer_f.WriteString("%v")
+ }
+ }
+
+ // Adjust values_f:
+ if !frmt.check {
+ tmp := []string{}
+ for _, value := range values_dbg {
+ tmp = append(tmp, fmt.Sprintf("%v", value))
+ }
+ // First, make a copy of values_f, so we avoid overwriting values_dbg when appending
+ values_f = append([]interface{}{}, values_f...)
+ values_f = append(values_f, strings.Join(tmp, " "))
+ }
+ }
+
+ format = buffer_f.String()
+ if frmt.check {
+ // We do not actually emit to the log, but panic if
+ // a non-nil value is detected (e.g. a non-nil error)
+ for _, value := range values_dbg {
+ if value != nil {
+ if format == "" {
+ panic(value)
+ } else {
+ panic(fmt.Sprintf(format, append(values_f, value)...))
+ }
+ }
+ }
+ } else {
+ self.getEmit().emit(frmt, format, values_f...)
+ }
+}
+
+// Idiot-proof &Dbgr{}, etc.
+func (self *Dbgr) getEmit() _emit {
+ if self.emit == nil {
+ self.emit = standardEmit()
+ }
+ return self.emit
+}
+
+// SetOutput will accept the following as a destination for output:
+//
+// *log.Logger Print*/Panic*/Fatal* of the logger
+// io.Writer -
+// nil Reset to the default output (os.Stderr)
+// "log" Print*/Panic*/Fatal* via the "log" package
+//
+func (self *Dbgr) SetOutput(output interface{}) {
+ if output == nil {
+ self.emit = standardEmit()
+ return
+ }
+ switch output := output.(type) {
+ case *log.Logger:
+ self.emit = _emitLogger{
+ logger: output,
+ }
+ return
+ case io.Writer:
+ self.emit = _emitWriter{
+ writer: output,
+ }
+ return
+ case string:
+ if output == "log" {
+ self.emit = _emitLog{}
+ return
+ }
+ }
+ panic(output)
+}
+
+// ======== //
+// = emit = //
+// ======== //
+
+func standardEmit() _emit {
+ return _emitWriter{
+ writer: os.Stderr,
+ }
+}
+
+func ln(tmp string) string {
+ length := len(tmp)
+ if length > 0 && tmp[length-1] != '\n' {
+ return tmp + "\n"
+ }
+ return tmp
+}
+
+type _emit interface {
+ emit(_frmt, string, ...interface{})
+}
+
+type _emitWriter struct {
+ writer io.Writer
+}
+
+func (self _emitWriter) emit(frmt _frmt, format string, values ...interface{}) {
+ if format == "" {
+ fmt.Fprintln(self.writer, values...)
+ } else {
+ if frmt.panic {
+ panic(fmt.Sprintf(format, values...))
+ }
+ fmt.Fprintf(self.writer, ln(format), values...)
+ if frmt.fatal {
+ os.Exit(1)
+ }
+ }
+}
+
+type _emitLogger struct {
+ logger *log.Logger
+}
+
+func (self _emitLogger) emit(frmt _frmt, format string, values ...interface{}) {
+ if format == "" {
+ self.logger.Println(values...)
+ } else {
+ if frmt.panic {
+ self.logger.Panicf(format, values...)
+ } else if frmt.fatal {
+ self.logger.Fatalf(format, values...)
+ } else {
+ self.logger.Printf(format, values...)
+ }
+ }
+}
+
+type _emitLog struct {
+}
+
+func (self _emitLog) emit(frmt _frmt, format string, values ...interface{}) {
+ if format == "" {
+ log.Println(values...)
+ } else {
+ if frmt.panic {
+ log.Panicf(format, values...)
+ } else if frmt.fatal {
+ log.Fatalf(format, values...)
+ } else {
+ log.Printf(format, values...)
+ }
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/documentation_test.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/documentation_test.go
new file mode 100644
index 000000000..04646117f
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/documentation_test.go
@@ -0,0 +1,95 @@
+package otto
+
+import (
+ "fmt"
+)
+
+func ExampleSynopsis() {
+
+ vm := New()
+ vm.Run(`
+ abc = 2 + 2;
+ console.log("The value of abc is " + abc); // 4
+ `)
+
+ value, _ := vm.Get("abc")
+ {
+ value, _ := value.ToInteger()
+ fmt.Println(value)
+ }
+
+ vm.Set("def", 11)
+ vm.Run(`
+ console.log("The value of def is " + def);
+ `)
+
+ vm.Set("xyzzy", "Nothing happens.")
+ vm.Run(`
+ console.log(xyzzy.length);
+ `)
+
+ value, _ = vm.Run("xyzzy.length")
+ {
+ value, _ := value.ToInteger()
+ fmt.Println(value)
+ }
+
+ value, err := vm.Run("abcdefghijlmnopqrstuvwxyz.length")
+ fmt.Println(value)
+ fmt.Println(err)
+
+ vm.Set("sayHello", func(call FunctionCall) Value {
+ fmt.Printf("Hello, %s.\n", call.Argument(0).String())
+ return UndefinedValue()
+ })
+
+ vm.Set("twoPlus", func(call FunctionCall) Value {
+ right, _ := call.Argument(0).ToInteger()
+ result, _ := vm.ToValue(2 + right)
+ return result
+ })
+
+ value, _ = vm.Run(`
+ sayHello("Xyzzy");
+ sayHello();
+
+ result = twoPlus(2.0);
+ `)
+ fmt.Println(value)
+
+ // Output:
+ // The value of abc is 4
+ // 4
+ // The value of def is 11
+ // 16
+ // 16
+ // undefined
+ // ReferenceError: 'abcdefghijlmnopqrstuvwxyz' is not defined
+ // Hello, Xyzzy.
+ // Hello, undefined.
+ // 4
+}
+
+func ExampleConsole() {
+
+ vm := New()
+ console := map[string]interface{}{
+ "log": func(call FunctionCall) Value {
+ fmt.Println("console.log:", formatForConsole(call.ArgumentList))
+ return UndefinedValue()
+ },
+ }
+
+ err := vm.Set("console", console)
+
+ value, err := vm.Run(`
+ console.log("Hello, World.");
+ `)
+ fmt.Println(value)
+ fmt.Println(err)
+
+ // Output:
+ // console.log: Hello, World.
+ // undefined
+ // <nil>
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/error.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/error.go
new file mode 100644
index 000000000..111471044
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/error.go
@@ -0,0 +1,245 @@
+package otto
+
+import (
+ "errors"
+ "fmt"
+ "strings"
+
+ "github.com/robertkrimen/otto/file"
+)
+
+type _exception struct {
+ value interface{}
+}
+
+func newException(value interface{}) *_exception {
+ return &_exception{
+ value: value,
+ }
+}
+
+func (self *_exception) eject() interface{} {
+ value := self.value
+ self.value = nil // Prevent Go from holding on to the value, whatever it is
+ return value
+}
+
+type _error struct {
+ name string
+ message string
+ trace []_frame
+
+ offset int
+}
+
+type _frame struct {
+ file *file.File
+ offset int
+ callee string
+}
+
+var (
+ nativeFrame = _frame{}
+)
+
+type _at int
+
+func (fr _frame) location() string {
+ if fr.file == nil {
+ return "<unknown>"
+ }
+ path := fr.file.Name()
+ line, column := _position(fr.file, fr.offset)
+
+ if path == "" {
+ path = "<anonymous>"
+ }
+
+ str := fmt.Sprintf("%s:%d:%d", path, line, column)
+
+ if fr.callee != "" {
+ str = fmt.Sprintf("%s (%s)", fr.callee, str)
+ }
+
+ return str
+}
+
+func _position(file *file.File, offset int) (line, column int) {
+ {
+ offset := offset - file.Base()
+ if offset < 0 {
+ return -offset, -1
+ }
+
+ src := file.Source()
+ if offset >= len(src) {
+ return -offset, -len(src)
+ }
+ src = src[:offset]
+
+ line := 1 + strings.Count(src, "\n")
+ column := 0
+ if index := strings.LastIndex(src, "\n"); index >= 0 {
+ column = offset - index
+ } else {
+ column = 1 + len(src)
+ }
+ return line, column
+ }
+}
+
+// An Error represents a runtime error, e.g. a TypeError, a ReferenceError, etc.
+type Error struct {
+ _error
+}
+
+// Error returns a description of the error
+//
+// TypeError: 'def' is not a function
+//
+func (err Error) Error() string {
+ if len(err.name) == 0 {
+ return err.message
+ }
+ if len(err.message) == 0 {
+ return err.name
+ }
+ return fmt.Sprintf("%s: %s", err.name, err.message)
+}
+
+// String returns a description of the error and a trace of where the
+// error occurred.
+//
+// TypeError: 'def' is not a function
+// at xyz (<anonymous>:3:9)
+// at <anonymous>:7:1/
+//
+func (err Error) String() string {
+ str := err.Error() + "\n"
+ for _, frame := range err.trace {
+ str += " at " + frame.location() + "\n"
+ }
+ return str
+}
+
+func (err _error) describe(format string, in ...interface{}) string {
+ return fmt.Sprintf(format, in...)
+}
+
+func (self _error) messageValue() Value {
+ if self.message == "" {
+ return Value{}
+ }
+ return toValue_string(self.message)
+}
+
+func (rt *_runtime) typeErrorResult(throw bool) bool {
+ if throw {
+ panic(rt.panicTypeError())
+ }
+ return false
+}
+
+func newError(rt *_runtime, name string, in ...interface{}) _error {
+ err := _error{
+ name: name,
+ offset: -1,
+ }
+ description := ""
+ length := len(in)
+
+ if rt != nil {
+ scope := rt.scope
+ frame := scope.frame
+ if length > 0 {
+ if at, ok := in[length-1].(_at); ok {
+ in = in[0 : length-1]
+ if scope != nil {
+ frame.offset = int(at)
+ }
+ length -= 1
+ }
+ if length > 0 {
+ description, in = in[0].(string), in[1:]
+ }
+ }
+ limit := 10
+ err.trace = append(err.trace, frame)
+ if scope != nil {
+ for limit > 0 {
+ scope = scope.outer
+ if scope == nil {
+ break
+ }
+ if scope.frame.offset >= 0 {
+ err.trace = append(err.trace, scope.frame)
+ }
+ limit--
+ }
+ }
+ } else {
+ if length > 0 {
+ description, in = in[0].(string), in[1:]
+ }
+ }
+ err.message = err.describe(description, in...)
+ return err
+}
+
+func (rt *_runtime) panicTypeError(argumentList ...interface{}) *_exception {
+ return &_exception{
+ value: newError(rt, "TypeError", argumentList...),
+ }
+}
+
+func (rt *_runtime) panicReferenceError(argumentList ...interface{}) *_exception {
+ return &_exception{
+ value: newError(rt, "ReferenceError", argumentList...),
+ }
+}
+
+func (rt *_runtime) panicURIError(argumentList ...interface{}) *_exception {
+ return &_exception{
+ value: newError(rt, "URIError", argumentList...),
+ }
+}
+
+func (rt *_runtime) panicSyntaxError(argumentList ...interface{}) *_exception {
+ return &_exception{
+ value: newError(rt, "SyntaxError", argumentList...),
+ }
+}
+
+func (rt *_runtime) panicRangeError(argumentList ...interface{}) *_exception {
+ return &_exception{
+ value: newError(rt, "RangeError", argumentList...),
+ }
+}
+
+func catchPanic(function func()) (err error) {
+ defer func() {
+ if caught := recover(); caught != nil {
+ if exception, ok := caught.(*_exception); ok {
+ caught = exception.eject()
+ }
+ switch caught := caught.(type) {
+ case _error:
+ err = &Error{caught}
+ return
+ case Value:
+ if vl := caught._object(); vl != nil {
+ switch vl := vl.value.(type) {
+ case _error:
+ err = &Error{vl}
+ return
+ }
+ }
+ err = errors.New(caught.string())
+ return
+ }
+ panic(caught)
+ }
+ }()
+ function()
+ return nil
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/error_test.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/error_test.go
new file mode 100644
index 000000000..7f1b16af7
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/error_test.go
@@ -0,0 +1,192 @@
+package otto
+
+import (
+ "testing"
+)
+
+func TestError(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ [ Error.prototype.name, Error.prototype.message, Error.prototype.hasOwnProperty("message") ];
+ `, "Error,,true")
+ })
+}
+
+func TestError_instanceof(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`(new TypeError()) instanceof Error`, true)
+ })
+}
+
+func TestPanicValue(t *testing.T) {
+ tt(t, func() {
+ test, vm := test()
+
+ vm.Set("abc", func(call FunctionCall) Value {
+ value, err := call.Otto.Run(`({ def: 3.14159 })`)
+ is(err, nil)
+ panic(value)
+ })
+
+ test(`
+ try {
+ abc();
+ }
+ catch (err) {
+ error = err;
+ }
+ [ error instanceof Error, error.message, error.def ];
+ `, "false,,3.14159")
+ })
+}
+
+func Test_catchPanic(t *testing.T) {
+ tt(t, func() {
+ vm := New()
+
+ _, err := vm.Run(`
+ A syntax error that
+ does not define
+ var;
+ abc;
+ `)
+ is(err, "!=", nil)
+
+ _, err = vm.Call(`abc.def`, nil)
+ is(err, "!=", nil)
+ })
+}
+
+func TestErrorContext(t *testing.T) {
+ tt(t, func() {
+ vm := New()
+
+ _, err := vm.Run(`
+ undefined();
+ `)
+ {
+ err := err.(*Error)
+ is(err.message, "'undefined' is not a function")
+ is(len(err.trace), 1)
+ is(err.trace[0].location(), "<anonymous>:2:13")
+ }
+
+ _, err = vm.Run(`
+ ({}).abc();
+ `)
+ {
+ err := err.(*Error)
+ is(err.message, "'abc' is not a function")
+ is(len(err.trace), 1)
+ is(err.trace[0].location(), "<anonymous>:2:14")
+ }
+
+ _, err = vm.Run(`
+ ("abc").abc();
+ `)
+ {
+ err := err.(*Error)
+ is(err.message, "'abc' is not a function")
+ is(len(err.trace), 1)
+ is(err.trace[0].location(), "<anonymous>:2:14")
+ }
+
+ _, err = vm.Run(`
+ var ghi = "ghi";
+ ghi();
+ `)
+ {
+ err := err.(*Error)
+ is(err.message, "'ghi' is not a function")
+ is(len(err.trace), 1)
+ is(err.trace[0].location(), "<anonymous>:3:13")
+ }
+
+ _, err = vm.Run(`
+ function def() {
+ undefined();
+ }
+ function abc() {
+ def();
+ }
+ abc();
+ `)
+ {
+ err := err.(*Error)
+ is(err.message, "'undefined' is not a function")
+ is(len(err.trace), 3)
+ is(err.trace[0].location(), "def (<anonymous>:3:17)")
+ is(err.trace[1].location(), "abc (<anonymous>:6:17)")
+ is(err.trace[2].location(), "<anonymous>:8:13")
+ }
+
+ _, err = vm.Run(`
+ function abc() {
+ xyz();
+ }
+ abc();
+ `)
+ {
+ err := err.(*Error)
+ is(err.message, "'xyz' is not defined")
+ is(len(err.trace), 2)
+ is(err.trace[0].location(), "abc (<anonymous>:3:17)")
+ is(err.trace[1].location(), "<anonymous>:5:13")
+ }
+
+ _, err = vm.Run(`
+ mno + 1;
+ `)
+ {
+ err := err.(*Error)
+ is(err.message, "'mno' is not defined")
+ is(len(err.trace), 1)
+ is(err.trace[0].location(), "<anonymous>:2:13")
+ }
+
+ _, err = vm.Run(`
+ eval("xyz();");
+ `)
+ {
+ err := err.(*Error)
+ is(err.message, "'xyz' is not defined")
+ is(len(err.trace), 1)
+ is(err.trace[0].location(), "<anonymous>:1:1")
+ }
+
+ _, err = vm.Run(`
+ xyzzy = "Nothing happens."
+ eval("xyzzy();");
+ `)
+ {
+ err := err.(*Error)
+ is(err.message, "'xyzzy' is not a function")
+ is(len(err.trace), 1)
+ is(err.trace[0].location(), "<anonymous>:1:1")
+ }
+
+ _, err = vm.Run(`
+ throw Error("xyzzy");
+ `)
+ {
+ err := err.(*Error)
+ is(err.message, "xyzzy")
+ is(len(err.trace), 1)
+ is(err.trace[0].location(), "<anonymous>:2:19")
+ }
+
+ _, err = vm.Run(`
+ throw new Error("xyzzy");
+ `)
+ {
+ err := err.(*Error)
+ is(err.message, "xyzzy")
+ is(len(err.trace), 1)
+ is(err.trace[0].location(), "<anonymous>:2:23")
+ }
+ })
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/evaluate.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/evaluate.go
new file mode 100644
index 000000000..093054cc3
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/evaluate.go
@@ -0,0 +1,318 @@
+package otto
+
+import (
+ "fmt"
+ "math"
+ "strings"
+
+ "github.com/robertkrimen/otto/token"
+)
+
+func (self *_runtime) evaluateMultiply(left float64, right float64) Value {
+ // TODO 11.5.1
+ return Value{}
+}
+
+func (self *_runtime) evaluateDivide(left float64, right float64) Value {
+ if math.IsNaN(left) || math.IsNaN(right) {
+ return NaNValue()
+ }
+ if math.IsInf(left, 0) && math.IsInf(right, 0) {
+ return NaNValue()
+ }
+ if left == 0 && right == 0 {
+ return NaNValue()
+ }
+ if math.IsInf(left, 0) {
+ if math.Signbit(left) == math.Signbit(right) {
+ return positiveInfinityValue()
+ } else {
+ return negativeInfinityValue()
+ }
+ }
+ if math.IsInf(right, 0) {
+ if math.Signbit(left) == math.Signbit(right) {
+ return positiveZeroValue()
+ } else {
+ return negativeZeroValue()
+ }
+ }
+ if right == 0 {
+ if math.Signbit(left) == math.Signbit(right) {
+ return positiveInfinityValue()
+ } else {
+ return negativeInfinityValue()
+ }
+ }
+ return toValue_float64(left / right)
+}
+
+func (self *_runtime) evaluateModulo(left float64, right float64) Value {
+ // TODO 11.5.3
+ return Value{}
+}
+
+func (self *_runtime) calculateBinaryExpression(operator token.Token, left Value, right Value) Value {
+
+ leftValue := left.resolve()
+
+ switch operator {
+
+ // Additive
+ case token.PLUS:
+ leftValue = toPrimitive(leftValue)
+ rightValue := right.resolve()
+ rightValue = toPrimitive(rightValue)
+
+ if leftValue.IsString() || rightValue.IsString() {
+ return toValue_string(strings.Join([]string{leftValue.string(), rightValue.string()}, ""))
+ } else {
+ return toValue_float64(leftValue.float64() + rightValue.float64())
+ }
+ case token.MINUS:
+ rightValue := right.resolve()
+ return toValue_float64(leftValue.float64() - rightValue.float64())
+
+ // Multiplicative
+ case token.MULTIPLY:
+ rightValue := right.resolve()
+ return toValue_float64(leftValue.float64() * rightValue.float64())
+ case token.SLASH:
+ rightValue := right.resolve()
+ return self.evaluateDivide(leftValue.float64(), rightValue.float64())
+ case token.REMAINDER:
+ rightValue := right.resolve()
+ return toValue_float64(math.Mod(leftValue.float64(), rightValue.float64()))
+
+ // Logical
+ case token.LOGICAL_AND:
+ left := leftValue.bool()
+ if !left {
+ return falseValue
+ }
+ return toValue_bool(right.resolve().bool())
+ case token.LOGICAL_OR:
+ left := leftValue.bool()
+ if left {
+ return trueValue
+ }
+ return toValue_bool(right.resolve().bool())
+
+ // Bitwise
+ case token.AND:
+ rightValue := right.resolve()
+ return toValue_int32(toInt32(leftValue) & toInt32(rightValue))
+ case token.OR:
+ rightValue := right.resolve()
+ return toValue_int32(toInt32(leftValue) | toInt32(rightValue))
+ case token.EXCLUSIVE_OR:
+ rightValue := right.resolve()
+ return toValue_int32(toInt32(leftValue) ^ toInt32(rightValue))
+
+ // Shift
+ // (Masking of 0x1f is to restrict the shift to a maximum of 31 places)
+ case token.SHIFT_LEFT:
+ rightValue := right.resolve()
+ return toValue_int32(toInt32(leftValue) << (toUint32(rightValue) & 0x1f))
+ case token.SHIFT_RIGHT:
+ rightValue := right.resolve()
+ return toValue_int32(toInt32(leftValue) >> (toUint32(rightValue) & 0x1f))
+ case token.UNSIGNED_SHIFT_RIGHT:
+ rightValue := right.resolve()
+ // Shifting an unsigned integer is a logical shift
+ return toValue_uint32(toUint32(leftValue) >> (toUint32(rightValue) & 0x1f))
+
+ case token.INSTANCEOF:
+ rightValue := right.resolve()
+ if !rightValue.IsObject() {
+ panic(self.panicTypeError("Expecting a function in instanceof check, but got: %v", rightValue))
+ }
+ return toValue_bool(rightValue._object().hasInstance(leftValue))
+
+ case token.IN:
+ rightValue := right.resolve()
+ if !rightValue.IsObject() {
+ panic(self.panicTypeError())
+ }
+ return toValue_bool(rightValue._object().hasProperty(leftValue.string()))
+ }
+
+ panic(hereBeDragons(operator))
+}
+
+func valueKindDispatchKey(left _valueKind, right _valueKind) int {
+ return (int(left) << 2) + int(right)
+}
+
+var equalDispatch map[int](func(Value, Value) bool) = makeEqualDispatch()
+
+func makeEqualDispatch() map[int](func(Value, Value) bool) {
+ key := valueKindDispatchKey
+ return map[int](func(Value, Value) bool){
+
+ key(valueNumber, valueObject): func(x Value, y Value) bool { return x.float64() == y.float64() },
+ key(valueString, valueObject): func(x Value, y Value) bool { return x.float64() == y.float64() },
+ key(valueObject, valueNumber): func(x Value, y Value) bool { return x.float64() == y.float64() },
+ key(valueObject, valueString): func(x Value, y Value) bool { return x.float64() == y.float64() },
+ }
+}
+
+type _lessThanResult int
+
+const (
+ lessThanFalse _lessThanResult = iota
+ lessThanTrue
+ lessThanUndefined
+)
+
+func calculateLessThan(left Value, right Value, leftFirst bool) _lessThanResult {
+
+ x := Value{}
+ y := x
+
+ if leftFirst {
+ x = toNumberPrimitive(left)
+ y = toNumberPrimitive(right)
+ } else {
+ y = toNumberPrimitive(right)
+ x = toNumberPrimitive(left)
+ }
+
+ result := false
+ if x.kind != valueString || y.kind != valueString {
+ x, y := x.float64(), y.float64()
+ if math.IsNaN(x) || math.IsNaN(y) {
+ return lessThanUndefined
+ }
+ result = x < y
+ } else {
+ x, y := x.string(), y.string()
+ result = x < y
+ }
+
+ if result {
+ return lessThanTrue
+ }
+
+ return lessThanFalse
+}
+
+// FIXME Probably a map is not the most efficient way to do this
+var lessThanTable [4](map[_lessThanResult]bool) = [4](map[_lessThanResult]bool){
+ // <
+ map[_lessThanResult]bool{
+ lessThanFalse: false,
+ lessThanTrue: true,
+ lessThanUndefined: false,
+ },
+
+ // >
+ map[_lessThanResult]bool{
+ lessThanFalse: false,
+ lessThanTrue: true,
+ lessThanUndefined: false,
+ },
+
+ // <=
+ map[_lessThanResult]bool{
+ lessThanFalse: true,
+ lessThanTrue: false,
+ lessThanUndefined: false,
+ },
+
+ // >=
+ map[_lessThanResult]bool{
+ lessThanFalse: true,
+ lessThanTrue: false,
+ lessThanUndefined: false,
+ },
+}
+
+func (self *_runtime) calculateComparison(comparator token.Token, left Value, right Value) bool {
+
+ // FIXME Use strictEqualityComparison?
+ // TODO This might be redundant now (with regards to evaluateComparison)
+ x := left.resolve()
+ y := right.resolve()
+
+ kindEqualKind := false
+ result := true
+ negate := false
+
+ switch comparator {
+ case token.LESS:
+ result = lessThanTable[0][calculateLessThan(x, y, true)]
+ case token.GREATER:
+ result = lessThanTable[1][calculateLessThan(y, x, false)]
+ case token.LESS_OR_EQUAL:
+ result = lessThanTable[2][calculateLessThan(y, x, false)]
+ case token.GREATER_OR_EQUAL:
+ result = lessThanTable[3][calculateLessThan(x, y, true)]
+ case token.STRICT_NOT_EQUAL:
+ negate = true
+ fallthrough
+ case token.STRICT_EQUAL:
+ if x.kind != y.kind {
+ result = false
+ } else {
+ kindEqualKind = true
+ }
+ case token.NOT_EQUAL:
+ negate = true
+ fallthrough
+ case token.EQUAL:
+ if x.kind == y.kind {
+ kindEqualKind = true
+ } else if x.kind <= valueNull && y.kind <= valueNull {
+ result = true
+ } else if x.kind <= valueNull || y.kind <= valueNull {
+ result = false
+ } else if x.kind <= valueString && y.kind <= valueString {
+ result = x.float64() == y.float64()
+ } else if x.kind == valueBoolean {
+ result = self.calculateComparison(token.EQUAL, toValue_float64(x.float64()), y)
+ } else if y.kind == valueBoolean {
+ result = self.calculateComparison(token.EQUAL, x, toValue_float64(y.float64()))
+ } else if x.kind == valueObject {
+ result = self.calculateComparison(token.EQUAL, toPrimitive(x), y)
+ } else if y.kind == valueObject {
+ result = self.calculateComparison(token.EQUAL, x, toPrimitive(y))
+ } else {
+ panic(hereBeDragons("Unable to test for equality: %v ==? %v", x, y))
+ }
+ default:
+ panic(fmt.Errorf("Unknown comparator %s", comparator.String()))
+ }
+
+ if kindEqualKind {
+ switch x.kind {
+ case valueUndefined, valueNull:
+ result = true
+ case valueNumber:
+ x := x.float64()
+ y := y.float64()
+ if math.IsNaN(x) || math.IsNaN(y) {
+ result = false
+ } else {
+ result = x == y
+ }
+ case valueString:
+ result = x.string() == y.string()
+ case valueBoolean:
+ result = x.bool() == y.bool()
+ case valueObject:
+ result = x._object() == y._object()
+ default:
+ goto ERROR
+ }
+ }
+
+ if negate {
+ result = !result
+ }
+
+ return result
+
+ERROR:
+ panic(hereBeDragons("%v (%v) %s %v (%v)", x, x.kind, comparator, y, y.kind))
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/file/README.markdown b/Godeps/_workspace/src/github.com/robertkrimen/otto/file/README.markdown
new file mode 100644
index 000000000..79757baa8
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/file/README.markdown
@@ -0,0 +1,110 @@
+# file
+--
+ import "github.com/robertkrimen/otto/file"
+
+Package file encapsulates the file abstractions used by the ast & parser.
+
+## Usage
+
+#### type File
+
+```go
+type File struct {
+}
+```
+
+
+#### func NewFile
+
+```go
+func NewFile(filename, src string, base int) *File
+```
+
+#### func (*File) Base
+
+```go
+func (fl *File) Base() int
+```
+
+#### func (*File) Name
+
+```go
+func (fl *File) Name() string
+```
+
+#### func (*File) Source
+
+```go
+func (fl *File) Source() string
+```
+
+#### type FileSet
+
+```go
+type FileSet struct {
+}
+```
+
+A FileSet represents a set of source files.
+
+#### func (*FileSet) AddFile
+
+```go
+func (self *FileSet) AddFile(filename, src string) int
+```
+AddFile adds a new file with the given filename and src.
+
+This an internal method, but exported for cross-package use.
+
+#### func (*FileSet) File
+
+```go
+func (self *FileSet) File(idx Idx) *File
+```
+
+#### func (*FileSet) Position
+
+```go
+func (self *FileSet) Position(idx Idx) *Position
+```
+Position converts an Idx in the FileSet into a Position.
+
+#### type Idx
+
+```go
+type Idx int
+```
+
+Idx is a compact encoding of a source position within a file set. It can be
+converted into a Position for a more convenient, but much larger,
+representation.
+
+#### type Position
+
+```go
+type Position struct {
+ Filename string // The filename where the error occurred, if any
+ Offset int // The src offset
+ Line int // The line number, starting at 1
+ Column int // The column number, starting at 1 (The character count)
+
+}
+```
+
+Position describes an arbitrary source position including the filename, line,
+and column location.
+
+#### func (*Position) String
+
+```go
+func (self *Position) String() string
+```
+String returns a string in one of several forms:
+
+ file:line:column A valid position with filename
+ line:column A valid position without filename
+ file An invalid position with filename
+ - An invalid position without filename
+
+--
+**godocdown** http://github.com/robertkrimen/godocdown
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/file/file.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/file/file.go
new file mode 100644
index 000000000..76524ac39
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/file/file.go
@@ -0,0 +1,135 @@
+// Package file encapsulates the file abstractions used by the ast & parser.
+//
+package file
+
+import (
+ "fmt"
+ "strings"
+)
+
+// Idx is a compact encoding of a source position within a file set.
+// It can be converted into a Position for a more convenient, but much
+// larger, representation.
+type Idx int
+
+// Position describes an arbitrary source position
+// including the filename, line, and column location.
+type Position struct {
+ Filename string // The filename where the error occurred, if any
+ Offset int // The src offset
+ Line int // The line number, starting at 1
+ Column int // The column number, starting at 1 (The character count)
+
+}
+
+// A Position is valid if the line number is > 0.
+
+func (self *Position) isValid() bool {
+ return self.Line > 0
+}
+
+// String returns a string in one of several forms:
+//
+// file:line:column A valid position with filename
+// line:column A valid position without filename
+// file An invalid position with filename
+// - An invalid position without filename
+//
+func (self *Position) String() string {
+ str := self.Filename
+ if self.isValid() {
+ if str != "" {
+ str += ":"
+ }
+ str += fmt.Sprintf("%d:%d", self.Line, self.Column)
+ }
+ if str == "" {
+ str = "-"
+ }
+ return str
+}
+
+// FileSet
+
+// A FileSet represents a set of source files.
+type FileSet struct {
+ files []*File
+ last *File
+}
+
+// AddFile adds a new file with the given filename and src.
+//
+// This an internal method, but exported for cross-package use.
+func (self *FileSet) AddFile(filename, src string) int {
+ base := self.nextBase()
+ file := &File{
+ name: filename,
+ src: src,
+ base: base,
+ }
+ self.files = append(self.files, file)
+ self.last = file
+ return base
+}
+
+func (self *FileSet) nextBase() int {
+ if self.last == nil {
+ return 1
+ }
+ return self.last.base + len(self.last.src) + 1
+}
+
+func (self *FileSet) File(idx Idx) *File {
+ for _, file := range self.files {
+ if idx <= Idx(file.base+len(file.src)) {
+ return file
+ }
+ }
+ return nil
+}
+
+// Position converts an Idx in the FileSet into a Position.
+func (self *FileSet) Position(idx Idx) *Position {
+ position := &Position{}
+ for _, file := range self.files {
+ if idx <= Idx(file.base+len(file.src)) {
+ offset := int(idx) - file.base
+ src := file.src[:offset]
+ position.Filename = file.name
+ position.Offset = offset
+ position.Line = 1 + strings.Count(src, "\n")
+ if index := strings.LastIndex(src, "\n"); index >= 0 {
+ position.Column = offset - index
+ } else {
+ position.Column = 1 + len(src)
+ }
+ }
+ }
+ return position
+}
+
+type File struct {
+ name string
+ src string
+ base int // This will always be 1 or greater
+}
+
+func NewFile(filename, src string, base int) *File {
+ return &File{
+ name: filename,
+ src: src,
+ base: base,
+ }
+}
+
+func (fl *File) Name() string {
+ return fl.name
+}
+
+func (fl *File) Source() string {
+ return fl.src
+}
+
+func (fl *File) Base() int {
+ return fl.base
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/function_test.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/function_test.go
new file mode 100644
index 000000000..c10bf8592
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/function_test.go
@@ -0,0 +1,280 @@
+package otto
+
+import (
+ "testing"
+)
+
+func TestFunction(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ var abc = Object.getOwnPropertyDescriptor(Function, "prototype");
+ [ [ typeof Function.prototype, typeof Function.prototype.length, Function.prototype.length ],
+ [ abc.writable, abc.enumerable, abc.configurable ] ];
+ `, "function,number,0,false,false,false")
+ })
+}
+
+func Test_argumentList2parameterList(t *testing.T) {
+ tt(t, func() {
+ is(argumentList2parameterList([]Value{toValue("abc, def"), toValue("ghi")}), []string{"abc", "def", "ghi"})
+ })
+}
+
+func TestFunction_new(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`raise:
+ new Function({});
+ `, "SyntaxError: Unexpected identifier")
+
+ test(`
+ var abc = Function("def, ghi", "jkl", "return def+ghi+jkl");
+ [ typeof abc, abc instanceof Function, abc("ab", "ba", 1) ];
+ `, "function,true,abba1")
+
+ test(`raise:
+ var abc = {
+ toString: function() { throw 1; }
+ };
+ var def = {
+ toString: function() { throw 2; }
+ };
+ var ghi = new Function(abc, def);
+ ghi;
+ `, "1")
+
+ // S15.3.2.1_A3_T10
+ test(`raise:
+ var abc = {
+ toString: function() { return "z;x"; }
+ };
+ var def = "return this";
+ var ghi = new Function(abc, def);
+ ghi;
+ `, "SyntaxError: Unexpected token ;")
+
+ test(`raise:
+ var abc;
+ var def = "return true";
+ var ghi = new Function(null, def);
+ ghi;
+ `, "SyntaxError: Unexpected token null")
+ })
+}
+
+func TestFunction_apply(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`Function.prototype.apply.length`, 2)
+ test(`String.prototype.substring.apply("abc", [1, 11])`, "bc")
+ })
+}
+
+func TestFunction_call(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`Function.prototype.call.length`, 1)
+ test(`String.prototype.substring.call("abc", 1, 11)`, "bc")
+ })
+}
+
+func TestFunctionArguments(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ // Should not be able to delete arguments
+ test(`
+ function abc(def, arguments){
+ delete def;
+ return def;
+ }
+ abc(1);
+ `, 1)
+
+ // Again, should not be able to delete arguments
+ test(`
+ function abc(def){
+ delete def;
+ return def;
+ }
+ abc(1);
+ `, 1)
+
+ // Test typeof of a function argument
+ test(`
+ function abc(def, ghi, jkl){
+ return typeof jkl
+ }
+ abc("1st", "2nd", "3rd", "4th", "5th");
+ `, "string")
+
+ test(`
+ function abc(def, ghi, jkl){
+ arguments[0] = 3.14;
+ arguments[1] = 'Nothing happens';
+ arguments[2] = 42;
+ if (3.14 === def && 'Nothing happens' === ghi && 42 === jkl)
+ return true;
+ }
+ abc(-1, 4.2, 314);
+ `, true)
+ })
+}
+
+func TestFunctionDeclarationInFunction(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ // Function declarations happen AFTER parameter/argument declarations
+ // That is, a function declared within a function will shadow/overwrite
+ // declared parameters
+
+ test(`
+ function abc(def){
+ return def;
+ function def(){
+ return 1;
+ }
+ }
+ typeof abc();
+ `, "function")
+ })
+}
+
+func TestArguments_defineOwnProperty(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ var abc;
+ var def = true;
+ var ghi = {};
+ (function (a, b, c) {
+ Object.defineProperty(arguments, "0", {
+ value: 42,
+ writable: false,
+ enumerable: false,
+ configurable: false
+ });
+ Object.defineProperty(arguments, "1", {
+ value: 3.14,
+ configurable: true,
+ enumerable: true
+ });
+ abc = Object.getOwnPropertyDescriptor(arguments, "0");
+ for (var name in arguments) {
+ ghi[name] = (ghi[name] || 0) + 1;
+ if (name === "0") {
+ def = false;
+ }
+ }
+ }(0, 1, 2));
+ [ abc.value, abc.writable, abc.enumerable, abc.configurable, def, ghi["1"] ];
+ `, "42,false,false,false,true,1")
+ })
+}
+
+func TestFunction_bind(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ defer mockUTC()()
+
+ test(`
+ abc = function(){
+ return "abc";
+ };
+ def = abc.bind();
+ [ typeof def.prototype, typeof def.hasOwnProperty, def.hasOwnProperty("caller"), def.hasOwnProperty("arguments"), def() ];
+ `, "object,function,true,true,abc")
+
+ test(`
+ abc = function(){
+ return arguments[1];
+ };
+ def = abc.bind(undefined, "abc");
+ ghi = abc.bind(undefined, "abc", "ghi");
+ [ def(), def("def"), ghi("def") ];
+ `, ",def,ghi")
+
+ test(`
+ var abc = function () {};
+ var ghi;
+ try {
+ Object.defineProperty(Function.prototype, "xyzzy", {
+ value: 1001,
+ writable: true,
+ enumerable: true,
+ configurable: true
+ });
+ var def = abc.bind({});
+ ghi = !def.hasOwnProperty("xyzzy") && ghi.xyzzy === 1001;
+ } finally {
+ delete Function.prototype.xyzzy;
+ }
+ [ ghi ];
+ `, "true")
+
+ test(`
+ var abc = function (def, ghi) {};
+ var jkl = abc.bind({});
+ var mno = abc.bind({}, 1, 2);
+ [ jkl.length, mno.length ];
+ `, "2,0")
+
+ test(`raise:
+ Math.bind();
+ `, "TypeError: 'bind' is not a function")
+
+ test(`
+ function construct(fn, arguments) {
+ var bound = Function.prototype.bind.apply(fn, [null].concat(arguments));
+ return new bound();
+ }
+ var abc = construct(Date, [1957, 4, 27]);
+ Object.prototype.toString.call(abc);
+ `, "[object Date]")
+
+ test(`
+ var fn = function (x, y, z) {
+ var result = {};
+ result.abc = x + y + z;
+ result.def = arguments[0] === "a" && arguments.length === 3;
+ return result;
+ };
+ var newFn = Function.prototype.bind.call(fn, {}, "a", "b", "c");
+ var result = new newFn();
+ [ result.hasOwnProperty("abc"), result.hasOwnProperty("def"), result.abc, result.def ];
+ `, "true,true,abc,true")
+
+ test(`
+ abc = function(){
+ return "abc";
+ };
+ def = abc.bind();
+ def.toString();
+ `, "function () { [native code] }")
+ })
+}
+
+func TestFunction_toString(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`raise:
+ Function.prototype.toString.call(undefined);
+ `, "TypeError")
+
+ test(`
+ abc = function() { return -1 ;
+}
+ 1;
+ abc.toString();
+ `, "function() { return -1 ;\n}")
+ })
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/global.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/global.go
new file mode 100644
index 000000000..4f035314a
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/global.go
@@ -0,0 +1,221 @@
+package otto
+
+import (
+ "strconv"
+ "time"
+)
+
+var (
+ prototypeValueObject = interface{}(nil)
+ prototypeValueFunction = _nativeFunctionObject{
+ call: func(_ FunctionCall) Value {
+ return Value{}
+ },
+ }
+ prototypeValueString = _stringASCII("")
+ // TODO Make this just false?
+ prototypeValueBoolean = Value{
+ kind: valueBoolean,
+ value: false,
+ }
+ prototypeValueNumber = Value{
+ kind: valueNumber,
+ value: 0,
+ }
+ prototypeValueDate = _dateObject{
+ epoch: 0,
+ isNaN: false,
+ time: time.Unix(0, 0).UTC(),
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ }
+ prototypeValueRegExp = _regExpObject{
+ regularExpression: nil,
+ global: false,
+ ignoreCase: false,
+ multiline: false,
+ source: "",
+ flags: "",
+ }
+)
+
+func newContext() *_runtime {
+
+ self := &_runtime{}
+
+ self.globalStash = self.newObjectStash(nil, nil)
+ self.globalObject = self.globalStash.object
+
+ _newContext(self)
+
+ self.eval = self.globalObject.property["eval"].value.(Value).value.(*_object)
+ self.globalObject.prototype = self.global.ObjectPrototype
+
+ return self
+}
+
+func (runtime *_runtime) newBaseObject() *_object {
+ self := newObject(runtime, "")
+ return self
+}
+
+func (runtime *_runtime) newClassObject(class string) *_object {
+ return newObject(runtime, class)
+}
+
+func (runtime *_runtime) newPrimitiveObject(class string, value Value) *_object {
+ self := runtime.newClassObject(class)
+ self.value = value
+ return self
+}
+
+func (self *_object) primitiveValue() Value {
+ switch value := self.value.(type) {
+ case Value:
+ return value
+ case _stringObject:
+ return toValue_string(value.String())
+ }
+ return Value{}
+}
+
+func (self *_object) hasPrimitive() bool {
+ switch self.value.(type) {
+ case Value, _stringObject:
+ return true
+ }
+ return false
+}
+
+func (runtime *_runtime) newObject() *_object {
+ self := runtime.newClassObject("Object")
+ self.prototype = runtime.global.ObjectPrototype
+ return self
+}
+
+func (runtime *_runtime) newArray(length uint32) *_object {
+ self := runtime.newArrayObject(length)
+ self.prototype = runtime.global.ArrayPrototype
+ return self
+}
+
+func (runtime *_runtime) newArrayOf(valueArray []Value) *_object {
+ self := runtime.newArray(uint32(len(valueArray)))
+ for index, value := range valueArray {
+ if value.isEmpty() {
+ continue
+ }
+ self.defineProperty(strconv.FormatInt(int64(index), 10), value, 0111, false)
+ }
+ return self
+}
+
+func (runtime *_runtime) newString(value Value) *_object {
+ self := runtime.newStringObject(value)
+ self.prototype = runtime.global.StringPrototype
+ return self
+}
+
+func (runtime *_runtime) newBoolean(value Value) *_object {
+ self := runtime.newBooleanObject(value)
+ self.prototype = runtime.global.BooleanPrototype
+ return self
+}
+
+func (runtime *_runtime) newNumber(value Value) *_object {
+ self := runtime.newNumberObject(value)
+ self.prototype = runtime.global.NumberPrototype
+ return self
+}
+
+func (runtime *_runtime) newRegExp(patternValue Value, flagsValue Value) *_object {
+
+ pattern := ""
+ flags := ""
+ if object := patternValue._object(); object != nil && object.class == "RegExp" {
+ if flagsValue.IsDefined() {
+ panic(runtime.panicTypeError("Cannot supply flags when constructing one RegExp from another"))
+ }
+ regExp := object.regExpValue()
+ pattern = regExp.source
+ flags = regExp.flags
+ } else {
+ if patternValue.IsDefined() {
+ pattern = patternValue.string()
+ }
+ if flagsValue.IsDefined() {
+ flags = flagsValue.string()
+ }
+ }
+
+ return runtime._newRegExp(pattern, flags)
+}
+
+func (runtime *_runtime) _newRegExp(pattern string, flags string) *_object {
+ self := runtime.newRegExpObject(pattern, flags)
+ self.prototype = runtime.global.RegExpPrototype
+ return self
+}
+
+// TODO Should (probably) be one argument, right? This is redundant
+func (runtime *_runtime) newDate(epoch float64) *_object {
+ self := runtime.newDateObject(epoch)
+ self.prototype = runtime.global.DatePrototype
+ return self
+}
+
+func (runtime *_runtime) newError(name string, message Value) *_object {
+ var self *_object
+ switch name {
+ case "EvalError":
+ return runtime.newEvalError(message)
+ case "TypeError":
+ return runtime.newTypeError(message)
+ case "RangeError":
+ return runtime.newRangeError(message)
+ case "ReferenceError":
+ return runtime.newReferenceError(message)
+ case "SyntaxError":
+ return runtime.newSyntaxError(message)
+ case "URIError":
+ return runtime.newURIError(message)
+ }
+
+ self = runtime.newErrorObject(name, message)
+ self.prototype = runtime.global.ErrorPrototype
+ if name != "" {
+ self.defineProperty("name", toValue_string(name), 0111, false)
+ }
+ return self
+}
+
+func (runtime *_runtime) newNativeFunction(name string, _nativeFunction _nativeFunction) *_object {
+ self := runtime.newNativeFunctionObject(name, _nativeFunction, 0)
+ self.prototype = runtime.global.FunctionPrototype
+ prototype := runtime.newObject()
+ self.defineProperty("prototype", toValue_object(prototype), 0100, false)
+ prototype.defineProperty("constructor", toValue_object(self), 0100, false)
+ return self
+}
+
+func (runtime *_runtime) newNodeFunction(node *_nodeFunctionLiteral, scopeEnvironment _stash) *_object {
+ // TODO Implement 13.2 fully
+ self := runtime.newNodeFunctionObject(node, scopeEnvironment)
+ self.prototype = runtime.global.FunctionPrototype
+ prototype := runtime.newObject()
+ self.defineProperty("prototype", toValue_object(prototype), 0100, false)
+ prototype.defineProperty("constructor", toValue_object(self), 0101, false)
+ return self
+}
+
+// FIXME Only in one place...
+func (runtime *_runtime) newBoundFunction(target *_object, this Value, argumentList []Value) *_object {
+ self := runtime.newBoundFunctionObject(target, this, argumentList)
+ self.prototype = runtime.global.FunctionPrototype
+ prototype := runtime.newObject()
+ self.defineProperty("prototype", toValue_object(prototype), 0100, false)
+ prototype.defineProperty("constructor", toValue_object(self), 0100, false)
+ return self
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/global_test.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/global_test.go
new file mode 100644
index 000000000..9257b58c3
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/global_test.go
@@ -0,0 +1,355 @@
+package otto
+
+import (
+ "fmt"
+ "math"
+ "strings"
+ "testing"
+)
+
+func TestGlobal(t *testing.T) {
+ tt(t, func() {
+ test, vm := test()
+
+ runtime := vm.vm.runtime
+
+ {
+ call := func(object interface{}, src string, argumentList ...interface{}) Value {
+ var tgt *Object
+ switch object := object.(type) {
+ case Value:
+ tgt = object.Object()
+ case *Object:
+ tgt = object
+ case *_object:
+ tgt = toValue_object(object).Object()
+ default:
+ panic("Here be dragons.")
+ }
+ value, err := tgt.Call(src, argumentList...)
+ is(err, nil)
+ return value
+ }
+
+ // FIXME enterGlobalScope
+ if false {
+ value := runtime.scope.lexical.getBinding("Object", false)._object().call(UndefinedValue(), []Value{toValue(runtime.newObject())}, false, nativeFrame)
+ is(value.IsObject(), true)
+ is(value, "[object Object]")
+ is(value._object().prototype == runtime.global.ObjectPrototype, true)
+ is(value._object().prototype == runtime.global.Object.get("prototype")._object(), true)
+ is(value._object().get("toString"), "function toString() { [native code] }")
+ is(call(value.Object(), "hasOwnProperty", "hasOwnProperty"), false)
+
+ is(call(value._object().get("toString")._object().prototype, "toString"), "function () { [native code] }") // TODO Is this right?
+ is(value._object().get("toString")._object().get("toString"), "function toString() { [native code] }")
+ is(value._object().get("toString")._object().get("toString")._object(), "function toString() { [native code] }")
+
+ is(call(value._object(), "propertyIsEnumerable", "isPrototypeOf"), false)
+ value._object().put("xyzzy", toValue_string("Nothing happens."), false)
+ is(call(value, "propertyIsEnumerable", "isPrototypeOf"), false)
+ is(call(value, "propertyIsEnumerable", "xyzzy"), true)
+ is(value._object().get("xyzzy"), "Nothing happens.")
+
+ is(call(runtime.scope.lexical.getBinding("Object", false), "isPrototypeOf", value), false)
+ is(call(runtime.scope.lexical.getBinding("Object", false)._object().get("prototype"), "isPrototypeOf", value), true)
+ is(call(runtime.scope.lexical.getBinding("Function", false), "isPrototypeOf", value), false)
+
+ is(runtime.newObject().prototype == runtime.global.Object.get("prototype")._object(), true)
+
+ abc := runtime.newBoolean(toValue_bool(true))
+ is(toValue_object(abc), "true") // TODO Call primitive?
+
+ //def := runtime.localGet("Boolean")._object().Construct(UndefinedValue(), []Value{})
+ //is(def, "false") // TODO Call primitive?
+ }
+ }
+
+ test(`new Number().constructor == Number`, true)
+
+ test(`this.hasOwnProperty`, "function hasOwnProperty() { [native code] }")
+
+ test(`eval.length === 1`, true)
+ test(`eval.prototype === undefined`, true)
+ test(`raise: new eval()`, "TypeError: function eval() { [native code] } is not a constructor")
+
+ test(`
+ [
+ [ delete undefined, undefined ],
+ [ delete NaN, NaN ],
+ [ delete Infinity, Infinity ],
+ ];
+ `, "false,,false,NaN,false,Infinity")
+
+ test(`
+ Object.getOwnPropertyNames(Function('return this')()).sort();
+ `, "Array,Boolean,Date,Error,EvalError,Function,Infinity,JSON,Math,NaN,Number,Object,RangeError,ReferenceError,RegExp,String,SyntaxError,TypeError,URIError,console,decodeURI,decodeURIComponent,encodeURI,encodeURIComponent,escape,eval,isFinite,isNaN,parseFloat,parseInt,undefined,unescape")
+
+ // __defineGetter__,__defineSetter__,__lookupGetter__,__lookupSetter__,constructor,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,toLocaleString,toString,valueOf
+ test(`
+ Object.getOwnPropertyNames(Object.prototype).sort();
+ `, "constructor,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,toLocaleString,toString,valueOf")
+
+ // arguments,caller,length,name,prototype
+ test(`
+ Object.getOwnPropertyNames(EvalError).sort();
+ `, "length,prototype")
+
+ test(`
+ var abc = [];
+ var def = [EvalError, RangeError, ReferenceError, SyntaxError, TypeError, URIError];
+ for (constructor in def) {
+ abc.push(def[constructor] === def[constructor].prototype.constructor);
+ }
+ def = [Array, Boolean, Date, Function, Number, Object, RegExp, String, SyntaxError];
+ for (constructor in def) {
+ abc.push(def[constructor] === def[constructor].prototype.constructor);
+ }
+ abc;
+ `, "true,true,true,true,true,true,true,true,true,true,true,true,true,true,true")
+
+ test(`
+ [ Array.prototype.constructor === Array, Array.constructor === Function ];
+ `, "true,true")
+
+ test(`
+ [ Number.prototype.constructor === Number, Number.constructor === Function ];
+ `, "true,true")
+
+ test(`
+ [ Function.prototype.constructor === Function, Function.constructor === Function ];
+ `, "true,true")
+ })
+}
+
+func TestGlobalLength(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ [ Object.length, Function.length, RegExp.length, Math.length ];
+ `, "1,1,2,")
+ })
+}
+
+func TestGlobalError(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ [ TypeError.length, TypeError(), TypeError("Nothing happens.") ];
+ `, "1,TypeError,TypeError: Nothing happens.")
+
+ test(`
+ [ URIError.length, URIError(), URIError("Nothing happens.") ];
+ `, "1,URIError,URIError: Nothing happens.")
+ })
+}
+
+func TestGlobalReadOnly(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`Number.POSITIVE_INFINITY`, math.Inf(1))
+
+ test(`
+ Number.POSITIVE_INFINITY = 1;
+ `, 1)
+
+ test(`Number.POSITIVE_INFINITY`, math.Inf(1))
+
+ test(`
+ Number.POSITIVE_INFINITY = 1;
+ Number.POSITIVE_INFINITY;
+ `, math.Inf(1))
+ })
+}
+
+func Test_isNaN(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`isNaN(0)`, false)
+ test(`isNaN("Xyzzy")`, true)
+ test(`isNaN()`, true)
+ test(`isNaN(NaN)`, true)
+ test(`isNaN(Infinity)`, false)
+
+ test(`isNaN.length === 1`, true)
+ test(`isNaN.prototype === undefined`, true)
+ })
+}
+
+func Test_isFinite(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`isFinite(0)`, true)
+ test(`isFinite("Xyzzy")`, false)
+ test(`isFinite()`, false)
+ test(`isFinite(NaN)`, false)
+ test(`isFinite(Infinity)`, false)
+ test(`isFinite(new Number(451));`, true)
+
+ test(`isFinite.length === 1`, true)
+ test(`isFinite.prototype === undefined`, true)
+ })
+}
+
+func Test_parseInt(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`parseInt("0")`, 0)
+ test(`parseInt("11")`, 11)
+ test(`parseInt(" 11")`, 11)
+ test(`parseInt("11 ")`, 11)
+ test(`parseInt(" 11 ")`, 11)
+ test(`parseInt(" 11\n")`, 11)
+ test(`parseInt(" 11\n", 16)`, 17)
+
+ test(`parseInt("Xyzzy")`, _NaN)
+
+ test(`parseInt(" 0x11\n", 16)`, 17)
+ test(`parseInt("0x0aXyzzy", 16)`, 10)
+ test(`parseInt("0x1", 0)`, 1)
+ test(`parseInt("0x10000000000000000000", 16)`, float64(75557863725914323419136))
+
+ test(`parseInt.length === 2`, true)
+ test(`parseInt.prototype === undefined`, true)
+ })
+}
+
+func Test_parseFloat(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`parseFloat("0")`, 0)
+ test(`parseFloat("11")`, 11)
+ test(`parseFloat(" 11")`, 11)
+ test(`parseFloat("11 ")`, 11)
+ test(`parseFloat(" 11 ")`, 11)
+ test(`parseFloat(" 11\n")`, 11)
+ test(`parseFloat(" 11\n", 16)`, 11)
+ test(`parseFloat("11.1")`, 11.1)
+
+ test(`parseFloat("Xyzzy")`, _NaN)
+
+ test(`parseFloat(" 0x11\n", 16)`, 0)
+ test(`parseFloat("0x0a")`, 0)
+ test(`parseFloat("0x0aXyzzy")`, 0)
+ test(`parseFloat("Infinity")`, _Infinity)
+ test(`parseFloat("infinity")`, _NaN)
+ test(`parseFloat("0x")`, 0)
+ test(`parseFloat("11x")`, 11)
+ test(`parseFloat("Infinity1")`, _Infinity)
+
+ test(`parseFloat.length === 1`, true)
+ test(`parseFloat.prototype === undefined`, true)
+ })
+}
+
+func Test_encodeURI(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`encodeURI("http://example.com/ Nothing happens.")`, "http://example.com/%20Nothing%20happens.")
+ test(`encodeURI("http://example.com/ _^#")`, "http://example.com/%20_%5E#")
+ test(`encodeURI(String.fromCharCode("0xE000"))`, "%EE%80%80")
+ test(`encodeURI(String.fromCharCode("0xFFFD"))`, "%EF%BF%BD")
+ test(`raise: encodeURI(String.fromCharCode("0xDC00"))`, "URIError: URI malformed")
+
+ test(`encodeURI.length === 1`, true)
+ test(`encodeURI.prototype === undefined`, true)
+ })
+}
+
+func Test_encodeURIComponent(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`encodeURIComponent("http://example.com/ Nothing happens.")`, "http%3A%2F%2Fexample.com%2F%20Nothing%20happens.")
+ test(`encodeURIComponent("http://example.com/ _^#")`, "http%3A%2F%2Fexample.com%2F%20_%5E%23")
+ })
+}
+
+func Test_decodeURI(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`decodeURI(encodeURI("http://example.com/ Nothing happens."))`, "http://example.com/ Nothing happens.")
+ test(`decodeURI(encodeURI("http://example.com/ _^#"))`, "http://example.com/ _^#")
+ test(`raise: decodeURI("http://example.com/ _^#%")`, "URIError: URI malformed")
+ test(`raise: decodeURI("%DF%7F")`, "URIError: URI malformed")
+ for _, check := range strings.Fields("+ %3B %2F %3F %3A %40 %26 %3D %2B %24 %2C %23") {
+ test(fmt.Sprintf(`decodeURI("%s")`, check), check)
+ }
+
+ test(`decodeURI.length === 1`, true)
+ test(`decodeURI.prototype === undefined`, true)
+ })
+}
+
+func Test_decodeURIComponent(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`decodeURIComponent(encodeURI("http://example.com/ Nothing happens."))`, "http://example.com/ Nothing happens.")
+ test(`decodeURIComponent(encodeURI("http://example.com/ _^#"))`, "http://example.com/ _^#")
+
+ test(`decodeURIComponent.length === 1`, true)
+ test(`decodeURIComponent.prototype === undefined`, true)
+
+ test(`
+ var global = Function('return this')();
+ var abc = Object.getOwnPropertyDescriptor(global, "decodeURIComponent");
+ [ abc.value === global.decodeURIComponent, abc.writable, abc.enumerable, abc.configurable ];
+ `, "true,true,false,true")
+ })
+}
+
+func TestGlobal_skipEnumeration(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ var found = [];
+ for (var test in this) {
+ if (false ||
+ test === 'NaN' ||
+ test === 'undefined' ||
+ test === 'Infinity' ||
+ false) {
+ found.push(test)
+ }
+ }
+ found.length;
+ `, 0)
+
+ test(`
+ var found = [];
+ for (var test in this) {
+ if (false ||
+ test === 'Object' ||
+ test === 'Function' ||
+ test === 'String' ||
+ test === 'Number' ||
+ test === 'Array' ||
+ test === 'Boolean' ||
+ test === 'Date' ||
+ test === 'RegExp' ||
+ test === 'Error' ||
+ test === 'EvalError' ||
+ test === 'RangeError' ||
+ test === 'ReferenceError' ||
+ test === 'SyntaxError' ||
+ test === 'TypeError' ||
+ test === 'URIError' ||
+ false) {
+ found.push(test)
+ }
+ }
+ found.length;
+ `, 0)
+ })
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/inline b/Godeps/_workspace/src/github.com/robertkrimen/otto/inline
new file mode 100644
index 000000000..c3620b4a2
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/inline
@@ -0,0 +1,1086 @@
+#!/usr/bin/env perl
+
+my $_fmt;
+$_fmt = "gofmt";
+$_fmt = "cat -n" if "cat" eq ($ARGV[0] || "");
+
+use strict;
+use warnings;
+use IO::File;
+
+my $self = __PACKAGE__;
+
+sub functionLabel ($) {
+ return "$_[0]_function";
+}
+
+sub trim ($) {
+ local $_ = shift;
+ s/^\s*//, s/\s*$// for $_;
+ return $_;
+}
+
+open my $fmt, "|-", "$_fmt" or die $!;
+
+$fmt->print(<<_END_);
+package otto
+
+import (
+ "math"
+)
+
+func _newContext(runtime *_runtime) {
+@{[ join "\n", $self->newContext() ]}
+}
+
+func newConsoleObject(runtime *_runtime) *_object {
+@{[ join "\n", $self->newConsoleObject() ]}
+}
+_END_
+
+for (qw/int int8 int16 int32 int64 uint uint8 uint16 uint32 uint64 float32 float64/) {
+ $fmt->print(<<_END_);
+
+func toValue_$_(value $_) Value {
+ return Value{
+ kind: valueNumber,
+ value: value,
+ }
+}
+_END_
+}
+
+$fmt->print(<<_END_);
+
+func toValue_string(value string) Value {
+ return Value{
+ kind: valueString,
+ value: value,
+ }
+}
+
+func toValue_string16(value []uint16) Value {
+ return Value{
+ kind: valueString,
+ value: value,
+ }
+}
+
+func toValue_bool(value bool) Value {
+ return Value{
+ kind: valueBoolean,
+ value: value,
+ }
+}
+
+func toValue_object(value *_object) Value {
+ return Value{
+ kind: valueObject,
+ value: value,
+ }
+}
+_END_
+
+close $fmt;
+
+sub newConsoleObject {
+ my $self = shift;
+
+ return
+ $self->block(sub {
+ my $class = "Console";
+ my @got = $self->functionDeclare(
+ $class,
+ "log", 0,
+ "debug:log", 0,
+ "info:log", 0,
+ "error", 0,
+ "warn:error", 0,
+ "dir", 0,
+ "time", 0,
+ "timeEnd", 0,
+ "trace", 0,
+ "assert", 0,
+ );
+ return
+ "return @{[ $self->newObject(@got) ]}"
+ }),
+ ;
+}
+
+sub newContext {
+ my $self = shift;
+ return
+ # ObjectPrototype
+ $self->block(sub {
+ my $class = "Object";
+ return
+ ".${class}Prototype =",
+ $self->globalPrototype(
+ $class,
+ "_classObject",
+ undef,
+ "prototypeValueObject",
+ ),
+ }),
+
+ # FunctionPrototype
+ $self->block(sub {
+ my $class = "Function";
+ return
+ ".${class}Prototype =",
+ $self->globalPrototype(
+ $class,
+ "_classObject",
+ ".ObjectPrototype",
+ "prototypeValueFunction",
+ ),
+ }),
+
+ # ObjectPrototype
+ $self->block(sub {
+ my $class = "Object";
+ my @got = $self->functionDeclare(
+ $class,
+ "valueOf", 0,
+ "toString", 0,
+ "toLocaleString", 0,
+ "hasOwnProperty", 1,
+ "isPrototypeOf", 1,
+ "propertyIsEnumerable", 1,
+ );
+ my @propertyMap = $self->propertyMap(
+ @got,
+ $self->property("constructor", undef),
+ );
+ my $propertyOrder = $self->propertyOrder(@propertyMap);
+ $propertyOrder =~ s/^propertyOrder: //;
+ return
+ ".${class}Prototype.property =", @propertyMap,
+ ".${class}Prototype.propertyOrder =", $propertyOrder,
+ }),
+
+ # FunctionPrototype
+ $self->block(sub {
+ my $class = "Function";
+ my @got = $self->functionDeclare(
+ $class,
+ "toString", 0,
+ "apply", 2,
+ "call", 1,
+ "bind", 1,
+ );
+ my @propertyMap = $self->propertyMap(
+ @got,
+ $self->property("constructor", undef),
+ $self->property("length", $self->numberValue(0), "0"),
+ );
+ my $propertyOrder = $self->propertyOrder(@propertyMap);
+ $propertyOrder =~ s/^propertyOrder: //;
+ return
+ ".${class}Prototype.property =", @propertyMap,
+ ".${class}Prototype.propertyOrder =", $propertyOrder,
+ }),
+
+ # Object
+ $self->block(sub {
+ my $class = "Object";
+ return
+ ".$class =",
+ $self->globalFunction(
+ $class,
+ 1,
+ $self->functionDeclare(
+ $class,
+ "getPrototypeOf", 1,
+ "getOwnPropertyDescriptor", 2,
+ "defineProperty", 3,
+ "defineProperties", 2,
+ "create", 2,
+ "isExtensible", 1,
+ "preventExtensions", 1,
+ "isSealed", 1,
+ "seal", 1,
+ "isFrozen", 1,
+ "freeze", 1,
+ "keys", 1,
+ "getOwnPropertyNames", 1,
+ ),
+ ),
+ }),
+
+ # Function
+ $self->block(sub {
+ my $class = "Function";
+ return
+ "Function :=",
+ $self->globalFunction(
+ $class,
+ 1,
+ ),
+ ".$class = Function",
+ }),
+
+ # Array
+ $self->block(sub {
+ my $class = "Array";
+ my @got = $self->functionDeclare(
+ $class,
+ "toString", 0,
+ "toLocaleString", 0,
+ "concat", 1,
+ "join", 1,
+ "splice", 2,
+ "shift", 0,
+ "pop", 0,
+ "push", 1,
+ "slice", 2,
+ "unshift", 1,
+ "reverse", 0,
+ "sort", 1,
+ "indexOf", 1,
+ "lastIndexOf", 1,
+ "every", 1,
+ "some", 1,
+ "forEach", 1,
+ "map", 1,
+ "filter", 1,
+ "reduce", 1,
+ "reduceRight", 1,
+ );
+ return
+ ".${class}Prototype =",
+ $self->globalPrototype(
+ $class,
+ "_classArray",
+ ".ObjectPrototype",
+ undef,
+ $self->property("length", $self->numberValue("uint32(0)"), "0100"),
+ @got,
+ ),
+ ".$class =",
+ $self->globalFunction(
+ $class,
+ 1,
+ $self->functionDeclare(
+ $class,
+ "isArray", 1,
+ ),
+ ),
+ }),
+
+ # String
+ $self->block(sub {
+ my $class = "String";
+ my @got = $self->functionDeclare(
+ $class,
+ "toString", 0,
+ "valueOf", 0,
+ "charAt", 1,
+ "charCodeAt", 1,
+ "concat", 1,
+ "indexOf", 1,
+ "lastIndexOf", 1,
+ "match", 1,
+ "replace", 2,
+ "search", 1,
+ "split", 2,
+ "slice", 2,
+ "substring", 2,
+ "toLowerCase", 0,
+ "toUpperCase", 0,
+ "substr", 2,
+ "trim", 0,
+ "trimLeft", 0,
+ "trimRight", 0,
+ "localeCompare", 1,
+ "toLocaleLowerCase", 0,
+ "toLocaleUpperCase", 0,
+ );
+ return
+ ".${class}Prototype =",
+ $self->globalPrototype(
+ $class,
+ "_classString",
+ ".ObjectPrototype",
+ "prototypeValueString",
+ $self->property("length", $self->numberValue("int(0)"), "0"),
+ @got,
+ ),
+ ".$class =",
+ $self->globalFunction(
+ $class,
+ 1,
+ $self->functionDeclare(
+ $class,
+ "fromCharCode", 1,
+ ),
+ ),
+ }),
+
+ # Boolean
+ $self->block(sub {
+ my $class = "Boolean";
+ my @got = $self->functionDeclare(
+ $class,
+ "toString", 0,
+ "valueOf", 0,
+ );
+ return
+ ".${class}Prototype =",
+ $self->globalPrototype(
+ $class,
+ "_classObject",
+ ".ObjectPrototype",
+ "prototypeValueBoolean",
+ @got,
+ ),
+ ".$class =",
+ $self->globalFunction(
+ $class,
+ 1,
+ $self->functionDeclare(
+ $class,
+ ),
+ ),
+ }),
+
+ # Number
+ $self->block(sub {
+ my $class = "Number";
+ my @got = $self->functionDeclare(
+ $class,
+ "toString", 0,
+ "valueOf", 0,
+ "toFixed", 1,
+ "toExponential", 1,
+ "toPrecision", 1,
+ "toLocaleString", 1,
+ );
+ return
+ ".${class}Prototype =",
+ $self->globalPrototype(
+ $class,
+ "_classObject",
+ ".ObjectPrototype",
+ "prototypeValueNumber",
+ @got,
+ ),
+ ".$class =",
+ $self->globalFunction(
+ $class,
+ 1,
+ $self->functionDeclare(
+ $class,
+ ),
+ $self->numberConstantDeclare(
+ "MAX_VALUE", "math.MaxFloat64",
+ "MIN_VALUE", "math.SmallestNonzeroFloat64",
+ "NaN", "math.NaN()",
+ "NEGATIVE_INFINITY", "math.Inf(-1)",
+ "POSITIVE_INFINITY", "math.Inf(+1)",
+ ),
+ ),
+ }),
+
+ # Math
+ $self->block(sub {
+ my $class = "Math";
+ return
+ ".$class =",
+ $self->globalObject(
+ $class,
+ $self->functionDeclare(
+ $class,
+ "abs", 1,
+ "acos", 1,
+ "asin", 1,
+ "atan", 1,
+ "atan2", 1,
+ "ceil", 1,
+ "cos", 1,
+ "exp", 1,
+ "floor", 1,
+ "log", 1,
+ "max", 2,
+ "min", 2,
+ "pow", 2,
+ "random", 0,
+ "round", 1,
+ "sin", 1,
+ "sqrt", 1,
+ "tan", 1,
+ ),
+ $self->numberConstantDeclare(
+ "E", "math.E",
+ "LN10", "math.Ln10",
+ "LN2", "math.Ln2",
+ "LOG2E", "math.Log2E",
+ "LOG10E", "math.Log10E",
+ "PI", "math.Pi",
+ "SQRT1_2", "sqrt1_2",
+ "SQRT2", "math.Sqrt2",
+ )
+ ),
+ }),
+
+ # Date
+ $self->block(sub {
+ my $class = "Date";
+ my @got = $self->functionDeclare(
+ $class,
+ "toString", 0,
+ "toDateString", 0,
+ "toTimeString", 0,
+ "toUTCString", 0,
+ "toISOString", 0,
+ "toJSON", 1,
+ "toGMTString", 0,
+ "toLocaleString", 0,
+ "toLocaleDateString", 0,
+ "toLocaleTimeString", 0,
+ "valueOf", 0,
+ "getTime", 0,
+ "getYear", 0,
+ "getFullYear", 0,
+ "getUTCFullYear", 0,
+ "getMonth", 0,
+ "getUTCMonth", 0,
+ "getDate", 0,
+ "getUTCDate", 0,
+ "getDay", 0,
+ "getUTCDay", 0,
+ "getHours", 0,
+ "getUTCHours", 0,
+ "getMinutes", 0,
+ "getUTCMinutes", 0,
+ "getSeconds", 0,
+ "getUTCSeconds", 0,
+ "getMilliseconds", 0,
+ "getUTCMilliseconds", 0,
+ "getTimezoneOffset", 0,
+ "setTime", 1,
+ "setMilliseconds", 1,
+ "setUTCMilliseconds", 1,
+ "setSeconds", 2,
+ "setUTCSeconds", 2,
+ "setMinutes", 3,
+ "setUTCMinutes", 3,
+ "setHours", 4,
+ "setUTCHours", 4,
+ "setDate", 1,
+ "setUTCDate", 1,
+ "setMonth", 2,
+ "setUTCMonth", 2,
+ "setYear", 1,
+ "setFullYear", 3,
+ "setUTCFullYear", 3,
+ );
+ return
+ ".${class}Prototype =",
+ $self->globalPrototype(
+ $class,
+ "_classObject",
+ ".ObjectPrototype",
+ "prototypeValueDate",
+ @got,
+ ),
+ ".$class =",
+ $self->globalFunction(
+ $class,
+ 7,
+ $self->functionDeclare(
+ $class,
+ "parse", 1,
+ "UTC", 7,
+ "now", 0,
+ ),
+ ),
+ }),
+
+ # RegExp
+ $self->block(sub {
+ my $class = "RegExp";
+ my @got = $self->functionDeclare(
+ $class,
+ "toString", 0,
+ "exec", 1,
+ "test", 1,
+ "compile", 1,
+ );
+ return
+ ".${class}Prototype =",
+ $self->globalPrototype(
+ $class,
+ "_classObject",
+ ".ObjectPrototype",
+ "prototypeValueRegExp",
+ @got,
+ ),
+ ".$class =",
+ $self->globalFunction(
+ $class,
+ 2,
+ $self->functionDeclare(
+ $class,
+ ),
+ ),
+ }),
+
+ # Error
+ $self->block(sub {
+ my $class = "Error";
+ my @got = $self->functionDeclare(
+ $class,
+ "toString", 0,
+ );
+ return
+ ".${class}Prototype =",
+ $self->globalPrototype(
+ $class,
+ "_classObject",
+ ".ObjectPrototype",
+ undef,
+ @got,
+ $self->property("name", $self->stringValue("Error")),
+ $self->property("message", $self->stringValue("")),
+ ),
+ ".$class =",
+ $self->globalFunction(
+ $class,
+ 1,
+ $self->functionDeclare(
+ $class,
+ ),
+ ),
+ }),
+
+ (map {
+ my $class = "${_}Error";
+ $self->block(sub {
+ my @got = $self->functionDeclare(
+ $class,
+ );
+ return
+ ".${class}Prototype =",
+ $self->globalPrototype(
+ $class,
+ "_classObject",
+ ".ErrorPrototype",
+ undef,
+ @got,
+ $self->property("name", $self->stringValue($class)),
+ ),
+ ".$class =",
+ $self->globalFunction(
+ $class,
+ 1,
+ $self->functionDeclare(
+ $class,
+ ),
+ ),
+ });
+ } qw/Eval Type Range Reference Syntax URI/),
+
+ # JSON
+ $self->block(sub {
+ my $class = "JSON";
+ return
+ ".$class =",
+ $self->globalObject(
+ $class,
+ $self->functionDeclare(
+ $class,
+ "parse", 2,
+ "stringify", 3,
+ ),
+ ),
+ }),
+
+ # Global
+ $self->block(sub {
+ my $class = "Global";
+ my @got = $self->functionDeclare(
+ $class,
+ "eval", 1,
+ "parseInt", 2,
+ "parseFloat", 1,
+ "isNaN", 1,
+ "isFinite", 1,
+ "decodeURI", 1,
+ "decodeURIComponent", 1,
+ "encodeURI", 1,
+ "encodeURIComponent", 1,
+ "escape", 1,
+ "unescape", 1,
+ );
+ my @propertyMap = $self->propertyMap(
+ @got,
+ $self->globalDeclare(
+ "Object",
+ "Function",
+ "Array",
+ "String",
+ "Boolean",
+ "Number",
+ "Math",
+ "Date",
+ "RegExp",
+ "Error",
+ "EvalError",
+ "TypeError",
+ "RangeError",
+ "ReferenceError",
+ "SyntaxError",
+ "URIError",
+ "JSON",
+ ),
+ $self->property("undefined", $self->undefinedValue(), "0"),
+ $self->property("NaN", $self->numberValue("math.NaN()"), "0"),
+ $self->property("Infinity", $self->numberValue("math.Inf(+1)"), "0"),
+ );
+ my $propertyOrder = $self->propertyOrder(@propertyMap);
+ $propertyOrder =~ s/^propertyOrder: //;
+ return
+ "runtime.globalObject.property =",
+ @propertyMap,
+ "runtime.globalObject.propertyOrder =",
+ $propertyOrder,
+ ;
+ }),
+ ;
+}
+
+sub propertyMap {
+ my $self = shift;
+ return "map[string]_property{", (join ",\n", @_, ""), "}",
+}
+
+our (@preblock, @postblock);
+sub block {
+ my $self = shift;
+ local @preblock = ();
+ local @postblock = ();
+ my @input = $_[0]->();
+ my @output;
+ while (@input) {
+ local $_ = shift @input;
+ if (m/^\./) {
+ $_ = "runtime.global$_";
+ }
+ if (m/ :?=$/) {
+ $_ .= shift @input;
+ }
+ push @output, $_;
+ }
+ return
+ "{",
+ @preblock,
+ @output,
+ @postblock,
+ "}",
+ ;
+}
+
+sub numberConstantDeclare {
+ my $self = shift;
+ my @got;
+ while (@_) {
+ my $name = shift;
+ my $value = shift;
+ push @got, $self->property($name, $self->numberValue($value), "0"),
+ }
+ return @got;
+}
+
+sub functionDeclare {
+ my $self = shift;
+ my $class = shift;
+ my $builtin = "builtin${class}";
+ my @got;
+ while (@_) {
+ my $name = shift;
+ my $length = shift;
+ $name = $self->newFunction($name, "${builtin}_", $length);
+ push @got, $self->functionProperty($name),
+ }
+ return @got;
+}
+
+sub globalDeclare {
+ my $self = shift;
+ my @got;
+ while (@_) {
+ my $name = shift;
+ push @got, $self->property($name, $self->objectValue("runtime.global.$name"), "0101"),
+ }
+ return @got;
+}
+
+sub propertyOrder {
+ my $self = shift;
+ my $propertyMap = join "", @_;
+
+ my (@keys) = $propertyMap =~ m/("\w+"):/g;
+ my $propertyOrder =
+ join "\n", "propertyOrder: []string{", (join ",\n", @keys, ""), "}";
+ return $propertyOrder;
+}
+
+sub globalObject {
+ my $self = shift;
+ my $name = shift;
+
+ my $propertyMap = "";
+ if (@_) {
+ $propertyMap = join "\n", $self->propertyMap(@_);
+ my $propertyOrder = $self->propertyOrder($propertyMap);
+ $propertyMap = "property: $propertyMap,\n$propertyOrder,";
+ }
+
+ return trim <<_END_;
+&_object{
+ runtime: runtime,
+ class: "$name",
+ objectClass: _classObject,
+ prototype: runtime.global.ObjectPrototype,
+ extensible: true,
+ $propertyMap
+}
+_END_
+}
+
+sub globalFunction {
+ my $self = shift;
+ my $name = shift;
+ my $length = shift;
+
+ my $builtin = "builtin${name}";
+ my $builtinNew = "builtinNew${name}";
+ my $prototype = "runtime.global.${name}Prototype";
+ my $propertyMap = "";
+ unshift @_,
+ $self->property("length", $self->numberValue($length), "0"),
+ $self->property("prototype", $self->objectValue($prototype), "0"),
+ ;
+
+ if (@_) {
+ $propertyMap = join "\n", $self->propertyMap(@_);
+ my $propertyOrder = $self->propertyOrder($propertyMap);
+ $propertyMap = "property: $propertyMap,\n$propertyOrder,";
+ }
+
+ push @postblock, $self->statement(
+ "$prototype.property[\"constructor\"] =",
+ $self->property(undef, $self->objectValue("runtime.global.${name}"), "0101"),
+ );
+
+ return trim <<_END_;
+&_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ value: @{[ $self->nativeFunctionOf($name, $builtin, $builtinNew) ]},
+ $propertyMap
+}
+_END_
+}
+
+sub nativeCallFunction {
+ my $self = shift;
+ my $name = shift;
+ my $func = shift;
+ return trim <<_END_;
+_nativeCallFunction{ "$name", $func }
+_END_
+}
+
+sub globalPrototype {
+ my $self = shift;
+ my $class = shift;
+ my $classObject = shift;
+ my $prototype = shift;
+ my $value = shift;
+
+ if (!defined $prototype) {
+ $prototype = "nil";
+ }
+
+ if (!defined $value) {
+ $value = "nil";
+ }
+
+ if ($prototype =~ m/^\./) {
+ $prototype = "runtime.global$prototype";
+ }
+
+ my $propertyMap = "";
+ if (@_) {
+ $propertyMap = join "\n", $self->propertyMap(@_);
+ my $propertyOrder = $self->propertyOrder($propertyMap);
+ $propertyMap = "property: $propertyMap,\n$propertyOrder,";
+ }
+
+ return trim <<_END_;
+&_object{
+ runtime: runtime,
+ class: "$class",
+ objectClass: $classObject,
+ prototype: $prototype,
+ extensible: true,
+ value: $value,
+ $propertyMap
+}
+_END_
+}
+
+sub newFunction {
+ my $self = shift;
+ my $name = shift;
+ my $func = shift;
+ my $length = shift;
+
+ my @name = ($name, $name);
+ if ($name =~ m/^(\w+):(\w+)$/) {
+ @name = ($1, $2);
+ $name = $name[0];
+ }
+
+ if ($func =~ m/^builtin\w+_$/) {
+ $func = "$func$name[1]";
+ }
+
+ my $propertyOrder = "";
+ my @propertyMap = (
+ $self->property("length", $self->numberValue($length), "0"),
+ );
+
+ if (@propertyMap) {
+ $propertyOrder = $self->propertyOrder(@propertyMap);
+ $propertyOrder = "$propertyOrder,";
+ }
+
+ my $label = functionLabel($name);
+ push @preblock, $self->statement(
+ "$label := @{[ trim <<_END_ ]}",
+&_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: @{[ join "\n", $self->propertyMap(@propertyMap) ]},
+ $propertyOrder
+ value: @{[ $self->nativeFunctionOf($name, $func) ]},
+}
+_END_
+ );
+
+ return $name;
+}
+
+sub newObject {
+ my $self = shift;
+
+ my $propertyMap = join "\n", $self->propertyMap(@_);
+ my $propertyOrder = $self->propertyOrder($propertyMap);
+
+ return trim <<_END_;
+&_object{
+ runtime: runtime,
+ class: "Object",
+ objectClass: _classObject,
+ prototype: runtime.global.ObjectPrototype,
+ extensible: true,
+ property: $propertyMap,
+ $propertyOrder,
+}
+_END_
+}
+
+sub newPrototypeObject {
+ my $self = shift;
+ my $class = shift;
+ my $objectClass = shift;
+ my $value = shift;
+ if (defined $value) {
+ $value = "value: $value,";
+ }
+
+ my $propertyMap = join "\n", $self->propertyMap(@_);
+ my $propertyOrder = $self->propertyOrder($propertyMap);
+
+ return trim <<_END_;
+&_object{
+ runtime: runtime,
+ class: "$class",
+ objectClass: $objectClass,
+ prototype: runtime.global.ObjectPrototype,
+ extensible: true,
+ property: $propertyMap,
+ $propertyOrder,
+ $value
+}
+_END_
+}
+
+sub functionProperty {
+ my $self = shift;
+ my $name = shift;
+
+ return $self->property(
+ $name,
+ $self->objectValue(functionLabel($name))
+ );
+}
+
+sub statement {
+ my $self = shift;
+ return join "\n", @_;
+}
+
+sub functionOf {
+ my $self = shift;
+ my $call = shift;
+ my $construct = shift;
+ if ($construct) {
+ $construct = "construct: $construct,";
+ } else {
+ $construct = "";
+ }
+
+ return trim <<_END_
+_functionObject{
+ call: $call,
+ $construct
+}
+_END_
+}
+
+sub nativeFunctionOf {
+ my $self = shift;
+ my $name = shift;
+ my $call = shift;
+ my $construct = shift;
+ if ($construct) {
+ $construct = "construct: $construct,";
+ } else {
+ $construct = "";
+ }
+
+ return trim <<_END_
+_nativeFunctionObject{
+ name: "$name",
+ call: $call,
+ $construct
+}
+_END_
+}
+
+sub nameProperty {
+ my $self = shift;
+ my $name = shift;
+ my $value = shift;
+
+ return trim <<_END_;
+"$name": _property{
+ mode: 0101,
+ value: $value,
+}
+_END_
+}
+
+sub numberValue {
+ my $self = shift;
+ my $value = shift;
+ return trim <<_END_;
+Value{
+ kind: valueNumber,
+ value: $value,
+}
+_END_
+}
+
+sub property {
+ my $self = shift;
+ my $name = shift;
+ my $value = shift;
+ my $mode = shift;
+ $mode = "0101" unless defined $mode;
+ if (! defined $value) {
+ $value = "Value{}";
+ }
+ if (defined $name) {
+ return trim <<_END_;
+"$name": _property{
+ mode: $mode,
+ value: $value,
+}
+_END_
+ } else {
+ return trim <<_END_;
+_property{
+ mode: $mode,
+ value: $value,
+}
+_END_
+ }
+
+}
+
+sub objectProperty {
+ my $self = shift;
+ my $name = shift;
+ my $value = shift;
+
+ return trim <<_END_;
+"$name": _property{
+ mode: 0101,
+ value: @{[ $self->objectValue($value)]},
+}
+_END_
+}
+
+sub objectValue {
+ my $self = shift;
+ my $value = shift;
+ return trim <<_END_
+Value{
+ kind: valueObject,
+ value: $value,
+}
+_END_
+}
+
+sub stringValue {
+ my $self = shift;
+ my $value = shift;
+ return trim <<_END_
+Value{
+ kind: valueString,
+ value: "$value",
+}
+_END_
+}
+
+sub booleanValue {
+ my $self = shift;
+ my $value = shift;
+ return trim <<_END_
+Value{
+ kind: valueBoolean,
+ value: $value,
+}
+_END_
+}
+
+sub undefinedValue {
+ my $self = shift;
+ return trim <<_END_
+Value{
+ kind: valueUndefined,
+}
+_END_
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/inline.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/inline.go
new file mode 100644
index 000000000..6e5df8393
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/inline.go
@@ -0,0 +1,6649 @@
+package otto
+
+import (
+ "math"
+)
+
+func _newContext(runtime *_runtime) {
+ {
+ runtime.global.ObjectPrototype = &_object{
+ runtime: runtime,
+ class: "Object",
+ objectClass: _classObject,
+ prototype: nil,
+ extensible: true,
+ value: prototypeValueObject,
+ }
+ }
+ {
+ runtime.global.FunctionPrototype = &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.ObjectPrototype,
+ extensible: true,
+ value: prototypeValueFunction,
+ }
+ }
+ {
+ valueOf_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "valueOf",
+ call: builtinObject_valueOf,
+ },
+ }
+ toString_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "toString",
+ call: builtinObject_toString,
+ },
+ }
+ toLocaleString_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "toLocaleString",
+ call: builtinObject_toLocaleString,
+ },
+ }
+ hasOwnProperty_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "hasOwnProperty",
+ call: builtinObject_hasOwnProperty,
+ },
+ }
+ isPrototypeOf_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "isPrototypeOf",
+ call: builtinObject_isPrototypeOf,
+ },
+ }
+ propertyIsEnumerable_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "propertyIsEnumerable",
+ call: builtinObject_propertyIsEnumerable,
+ },
+ }
+ runtime.global.ObjectPrototype.property = map[string]_property{
+ "valueOf": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: valueOf_function,
+ },
+ },
+ "toString": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: toString_function,
+ },
+ },
+ "toLocaleString": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: toLocaleString_function,
+ },
+ },
+ "hasOwnProperty": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: hasOwnProperty_function,
+ },
+ },
+ "isPrototypeOf": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: isPrototypeOf_function,
+ },
+ },
+ "propertyIsEnumerable": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: propertyIsEnumerable_function,
+ },
+ },
+ "constructor": _property{
+ mode: 0101,
+ value: Value{},
+ },
+ }
+ runtime.global.ObjectPrototype.propertyOrder = []string{
+ "valueOf",
+ "toString",
+ "toLocaleString",
+ "hasOwnProperty",
+ "isPrototypeOf",
+ "propertyIsEnumerable",
+ "constructor",
+ }
+ }
+ {
+ toString_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "toString",
+ call: builtinFunction_toString,
+ },
+ }
+ apply_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 2,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "apply",
+ call: builtinFunction_apply,
+ },
+ }
+ call_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "call",
+ call: builtinFunction_call,
+ },
+ }
+ bind_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "bind",
+ call: builtinFunction_bind,
+ },
+ }
+ runtime.global.FunctionPrototype.property = map[string]_property{
+ "toString": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: toString_function,
+ },
+ },
+ "apply": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: apply_function,
+ },
+ },
+ "call": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: call_function,
+ },
+ },
+ "bind": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: bind_function,
+ },
+ },
+ "constructor": _property{
+ mode: 0101,
+ value: Value{},
+ },
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ }
+ runtime.global.FunctionPrototype.propertyOrder = []string{
+ "toString",
+ "apply",
+ "call",
+ "bind",
+ "constructor",
+ "length",
+ }
+ }
+ {
+ getPrototypeOf_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "getPrototypeOf",
+ call: builtinObject_getPrototypeOf,
+ },
+ }
+ getOwnPropertyDescriptor_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 2,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "getOwnPropertyDescriptor",
+ call: builtinObject_getOwnPropertyDescriptor,
+ },
+ }
+ defineProperty_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 3,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "defineProperty",
+ call: builtinObject_defineProperty,
+ },
+ }
+ defineProperties_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 2,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "defineProperties",
+ call: builtinObject_defineProperties,
+ },
+ }
+ create_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 2,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "create",
+ call: builtinObject_create,
+ },
+ }
+ isExtensible_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "isExtensible",
+ call: builtinObject_isExtensible,
+ },
+ }
+ preventExtensions_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "preventExtensions",
+ call: builtinObject_preventExtensions,
+ },
+ }
+ isSealed_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "isSealed",
+ call: builtinObject_isSealed,
+ },
+ }
+ seal_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "seal",
+ call: builtinObject_seal,
+ },
+ }
+ isFrozen_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "isFrozen",
+ call: builtinObject_isFrozen,
+ },
+ }
+ freeze_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "freeze",
+ call: builtinObject_freeze,
+ },
+ }
+ keys_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "keys",
+ call: builtinObject_keys,
+ },
+ }
+ getOwnPropertyNames_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "getOwnPropertyNames",
+ call: builtinObject_getOwnPropertyNames,
+ },
+ }
+ runtime.global.Object = &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ value: _nativeFunctionObject{
+ name: "Object",
+ call: builtinObject,
+ construct: builtinNewObject,
+ },
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ "prototype": _property{
+ mode: 0,
+ value: Value{
+ kind: valueObject,
+ value: runtime.global.ObjectPrototype,
+ },
+ },
+ "getPrototypeOf": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: getPrototypeOf_function,
+ },
+ },
+ "getOwnPropertyDescriptor": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: getOwnPropertyDescriptor_function,
+ },
+ },
+ "defineProperty": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: defineProperty_function,
+ },
+ },
+ "defineProperties": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: defineProperties_function,
+ },
+ },
+ "create": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: create_function,
+ },
+ },
+ "isExtensible": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: isExtensible_function,
+ },
+ },
+ "preventExtensions": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: preventExtensions_function,
+ },
+ },
+ "isSealed": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: isSealed_function,
+ },
+ },
+ "seal": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: seal_function,
+ },
+ },
+ "isFrozen": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: isFrozen_function,
+ },
+ },
+ "freeze": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: freeze_function,
+ },
+ },
+ "keys": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: keys_function,
+ },
+ },
+ "getOwnPropertyNames": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: getOwnPropertyNames_function,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ "prototype",
+ "getPrototypeOf",
+ "getOwnPropertyDescriptor",
+ "defineProperty",
+ "defineProperties",
+ "create",
+ "isExtensible",
+ "preventExtensions",
+ "isSealed",
+ "seal",
+ "isFrozen",
+ "freeze",
+ "keys",
+ "getOwnPropertyNames",
+ },
+ }
+ runtime.global.ObjectPrototype.property["constructor"] =
+ _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: runtime.global.Object,
+ },
+ }
+ }
+ {
+ Function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ value: _nativeFunctionObject{
+ name: "Function",
+ call: builtinFunction,
+ construct: builtinNewFunction,
+ },
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ "prototype": _property{
+ mode: 0,
+ value: Value{
+ kind: valueObject,
+ value: runtime.global.FunctionPrototype,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ "prototype",
+ },
+ }
+ runtime.global.Function = Function
+ runtime.global.FunctionPrototype.property["constructor"] =
+ _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: runtime.global.Function,
+ },
+ }
+ }
+ {
+ toString_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "toString",
+ call: builtinArray_toString,
+ },
+ }
+ toLocaleString_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "toLocaleString",
+ call: builtinArray_toLocaleString,
+ },
+ }
+ concat_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "concat",
+ call: builtinArray_concat,
+ },
+ }
+ join_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "join",
+ call: builtinArray_join,
+ },
+ }
+ splice_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 2,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "splice",
+ call: builtinArray_splice,
+ },
+ }
+ shift_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "shift",
+ call: builtinArray_shift,
+ },
+ }
+ pop_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "pop",
+ call: builtinArray_pop,
+ },
+ }
+ push_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "push",
+ call: builtinArray_push,
+ },
+ }
+ slice_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 2,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "slice",
+ call: builtinArray_slice,
+ },
+ }
+ unshift_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "unshift",
+ call: builtinArray_unshift,
+ },
+ }
+ reverse_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "reverse",
+ call: builtinArray_reverse,
+ },
+ }
+ sort_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "sort",
+ call: builtinArray_sort,
+ },
+ }
+ indexOf_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "indexOf",
+ call: builtinArray_indexOf,
+ },
+ }
+ lastIndexOf_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "lastIndexOf",
+ call: builtinArray_lastIndexOf,
+ },
+ }
+ every_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "every",
+ call: builtinArray_every,
+ },
+ }
+ some_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "some",
+ call: builtinArray_some,
+ },
+ }
+ forEach_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "forEach",
+ call: builtinArray_forEach,
+ },
+ }
+ map_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "map",
+ call: builtinArray_map,
+ },
+ }
+ filter_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "filter",
+ call: builtinArray_filter,
+ },
+ }
+ reduce_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "reduce",
+ call: builtinArray_reduce,
+ },
+ }
+ reduceRight_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "reduceRight",
+ call: builtinArray_reduceRight,
+ },
+ }
+ isArray_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "isArray",
+ call: builtinArray_isArray,
+ },
+ }
+ runtime.global.ArrayPrototype = &_object{
+ runtime: runtime,
+ class: "Array",
+ objectClass: _classArray,
+ prototype: runtime.global.ObjectPrototype,
+ extensible: true,
+ value: nil,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0100,
+ value: Value{
+ kind: valueNumber,
+ value: uint32(0),
+ },
+ },
+ "toString": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: toString_function,
+ },
+ },
+ "toLocaleString": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: toLocaleString_function,
+ },
+ },
+ "concat": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: concat_function,
+ },
+ },
+ "join": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: join_function,
+ },
+ },
+ "splice": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: splice_function,
+ },
+ },
+ "shift": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: shift_function,
+ },
+ },
+ "pop": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: pop_function,
+ },
+ },
+ "push": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: push_function,
+ },
+ },
+ "slice": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: slice_function,
+ },
+ },
+ "unshift": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: unshift_function,
+ },
+ },
+ "reverse": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: reverse_function,
+ },
+ },
+ "sort": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: sort_function,
+ },
+ },
+ "indexOf": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: indexOf_function,
+ },
+ },
+ "lastIndexOf": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: lastIndexOf_function,
+ },
+ },
+ "every": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: every_function,
+ },
+ },
+ "some": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: some_function,
+ },
+ },
+ "forEach": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: forEach_function,
+ },
+ },
+ "map": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: map_function,
+ },
+ },
+ "filter": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: filter_function,
+ },
+ },
+ "reduce": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: reduce_function,
+ },
+ },
+ "reduceRight": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: reduceRight_function,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ "toString",
+ "toLocaleString",
+ "concat",
+ "join",
+ "splice",
+ "shift",
+ "pop",
+ "push",
+ "slice",
+ "unshift",
+ "reverse",
+ "sort",
+ "indexOf",
+ "lastIndexOf",
+ "every",
+ "some",
+ "forEach",
+ "map",
+ "filter",
+ "reduce",
+ "reduceRight",
+ },
+ }
+ runtime.global.Array = &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ value: _nativeFunctionObject{
+ name: "Array",
+ call: builtinArray,
+ construct: builtinNewArray,
+ },
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ "prototype": _property{
+ mode: 0,
+ value: Value{
+ kind: valueObject,
+ value: runtime.global.ArrayPrototype,
+ },
+ },
+ "isArray": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: isArray_function,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ "prototype",
+ "isArray",
+ },
+ }
+ runtime.global.ArrayPrototype.property["constructor"] =
+ _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: runtime.global.Array,
+ },
+ }
+ }
+ {
+ toString_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "toString",
+ call: builtinString_toString,
+ },
+ }
+ valueOf_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "valueOf",
+ call: builtinString_valueOf,
+ },
+ }
+ charAt_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "charAt",
+ call: builtinString_charAt,
+ },
+ }
+ charCodeAt_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "charCodeAt",
+ call: builtinString_charCodeAt,
+ },
+ }
+ concat_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "concat",
+ call: builtinString_concat,
+ },
+ }
+ indexOf_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "indexOf",
+ call: builtinString_indexOf,
+ },
+ }
+ lastIndexOf_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "lastIndexOf",
+ call: builtinString_lastIndexOf,
+ },
+ }
+ match_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "match",
+ call: builtinString_match,
+ },
+ }
+ replace_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 2,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "replace",
+ call: builtinString_replace,
+ },
+ }
+ search_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "search",
+ call: builtinString_search,
+ },
+ }
+ split_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 2,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "split",
+ call: builtinString_split,
+ },
+ }
+ slice_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 2,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "slice",
+ call: builtinString_slice,
+ },
+ }
+ substring_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 2,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "substring",
+ call: builtinString_substring,
+ },
+ }
+ toLowerCase_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "toLowerCase",
+ call: builtinString_toLowerCase,
+ },
+ }
+ toUpperCase_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "toUpperCase",
+ call: builtinString_toUpperCase,
+ },
+ }
+ substr_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 2,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "substr",
+ call: builtinString_substr,
+ },
+ }
+ trim_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "trim",
+ call: builtinString_trim,
+ },
+ }
+ trimLeft_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "trimLeft",
+ call: builtinString_trimLeft,
+ },
+ }
+ trimRight_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "trimRight",
+ call: builtinString_trimRight,
+ },
+ }
+ localeCompare_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "localeCompare",
+ call: builtinString_localeCompare,
+ },
+ }
+ toLocaleLowerCase_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "toLocaleLowerCase",
+ call: builtinString_toLocaleLowerCase,
+ },
+ }
+ toLocaleUpperCase_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "toLocaleUpperCase",
+ call: builtinString_toLocaleUpperCase,
+ },
+ }
+ fromCharCode_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "fromCharCode",
+ call: builtinString_fromCharCode,
+ },
+ }
+ runtime.global.StringPrototype = &_object{
+ runtime: runtime,
+ class: "String",
+ objectClass: _classString,
+ prototype: runtime.global.ObjectPrototype,
+ extensible: true,
+ value: prototypeValueString,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: int(0),
+ },
+ },
+ "toString": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: toString_function,
+ },
+ },
+ "valueOf": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: valueOf_function,
+ },
+ },
+ "charAt": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: charAt_function,
+ },
+ },
+ "charCodeAt": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: charCodeAt_function,
+ },
+ },
+ "concat": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: concat_function,
+ },
+ },
+ "indexOf": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: indexOf_function,
+ },
+ },
+ "lastIndexOf": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: lastIndexOf_function,
+ },
+ },
+ "match": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: match_function,
+ },
+ },
+ "replace": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: replace_function,
+ },
+ },
+ "search": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: search_function,
+ },
+ },
+ "split": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: split_function,
+ },
+ },
+ "slice": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: slice_function,
+ },
+ },
+ "substring": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: substring_function,
+ },
+ },
+ "toLowerCase": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: toLowerCase_function,
+ },
+ },
+ "toUpperCase": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: toUpperCase_function,
+ },
+ },
+ "substr": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: substr_function,
+ },
+ },
+ "trim": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: trim_function,
+ },
+ },
+ "trimLeft": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: trimLeft_function,
+ },
+ },
+ "trimRight": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: trimRight_function,
+ },
+ },
+ "localeCompare": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: localeCompare_function,
+ },
+ },
+ "toLocaleLowerCase": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: toLocaleLowerCase_function,
+ },
+ },
+ "toLocaleUpperCase": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: toLocaleUpperCase_function,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ "toString",
+ "valueOf",
+ "charAt",
+ "charCodeAt",
+ "concat",
+ "indexOf",
+ "lastIndexOf",
+ "match",
+ "replace",
+ "search",
+ "split",
+ "slice",
+ "substring",
+ "toLowerCase",
+ "toUpperCase",
+ "substr",
+ "trim",
+ "trimLeft",
+ "trimRight",
+ "localeCompare",
+ "toLocaleLowerCase",
+ "toLocaleUpperCase",
+ },
+ }
+ runtime.global.String = &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ value: _nativeFunctionObject{
+ name: "String",
+ call: builtinString,
+ construct: builtinNewString,
+ },
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ "prototype": _property{
+ mode: 0,
+ value: Value{
+ kind: valueObject,
+ value: runtime.global.StringPrototype,
+ },
+ },
+ "fromCharCode": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: fromCharCode_function,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ "prototype",
+ "fromCharCode",
+ },
+ }
+ runtime.global.StringPrototype.property["constructor"] =
+ _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: runtime.global.String,
+ },
+ }
+ }
+ {
+ toString_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "toString",
+ call: builtinBoolean_toString,
+ },
+ }
+ valueOf_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "valueOf",
+ call: builtinBoolean_valueOf,
+ },
+ }
+ runtime.global.BooleanPrototype = &_object{
+ runtime: runtime,
+ class: "Boolean",
+ objectClass: _classObject,
+ prototype: runtime.global.ObjectPrototype,
+ extensible: true,
+ value: prototypeValueBoolean,
+ property: map[string]_property{
+ "toString": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: toString_function,
+ },
+ },
+ "valueOf": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: valueOf_function,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "toString",
+ "valueOf",
+ },
+ }
+ runtime.global.Boolean = &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ value: _nativeFunctionObject{
+ name: "Boolean",
+ call: builtinBoolean,
+ construct: builtinNewBoolean,
+ },
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ "prototype": _property{
+ mode: 0,
+ value: Value{
+ kind: valueObject,
+ value: runtime.global.BooleanPrototype,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ "prototype",
+ },
+ }
+ runtime.global.BooleanPrototype.property["constructor"] =
+ _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: runtime.global.Boolean,
+ },
+ }
+ }
+ {
+ toString_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "toString",
+ call: builtinNumber_toString,
+ },
+ }
+ valueOf_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "valueOf",
+ call: builtinNumber_valueOf,
+ },
+ }
+ toFixed_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "toFixed",
+ call: builtinNumber_toFixed,
+ },
+ }
+ toExponential_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "toExponential",
+ call: builtinNumber_toExponential,
+ },
+ }
+ toPrecision_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "toPrecision",
+ call: builtinNumber_toPrecision,
+ },
+ }
+ toLocaleString_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "toLocaleString",
+ call: builtinNumber_toLocaleString,
+ },
+ }
+ runtime.global.NumberPrototype = &_object{
+ runtime: runtime,
+ class: "Number",
+ objectClass: _classObject,
+ prototype: runtime.global.ObjectPrototype,
+ extensible: true,
+ value: prototypeValueNumber,
+ property: map[string]_property{
+ "toString": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: toString_function,
+ },
+ },
+ "valueOf": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: valueOf_function,
+ },
+ },
+ "toFixed": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: toFixed_function,
+ },
+ },
+ "toExponential": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: toExponential_function,
+ },
+ },
+ "toPrecision": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: toPrecision_function,
+ },
+ },
+ "toLocaleString": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: toLocaleString_function,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "toString",
+ "valueOf",
+ "toFixed",
+ "toExponential",
+ "toPrecision",
+ "toLocaleString",
+ },
+ }
+ runtime.global.Number = &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ value: _nativeFunctionObject{
+ name: "Number",
+ call: builtinNumber,
+ construct: builtinNewNumber,
+ },
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ "prototype": _property{
+ mode: 0,
+ value: Value{
+ kind: valueObject,
+ value: runtime.global.NumberPrototype,
+ },
+ },
+ "MAX_VALUE": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: math.MaxFloat64,
+ },
+ },
+ "MIN_VALUE": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: math.SmallestNonzeroFloat64,
+ },
+ },
+ "NaN": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: math.NaN(),
+ },
+ },
+ "NEGATIVE_INFINITY": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: math.Inf(-1),
+ },
+ },
+ "POSITIVE_INFINITY": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: math.Inf(+1),
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ "prototype",
+ "MAX_VALUE",
+ "MIN_VALUE",
+ "NaN",
+ "NEGATIVE_INFINITY",
+ "POSITIVE_INFINITY",
+ },
+ }
+ runtime.global.NumberPrototype.property["constructor"] =
+ _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: runtime.global.Number,
+ },
+ }
+ }
+ {
+ abs_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "abs",
+ call: builtinMath_abs,
+ },
+ }
+ acos_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "acos",
+ call: builtinMath_acos,
+ },
+ }
+ asin_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "asin",
+ call: builtinMath_asin,
+ },
+ }
+ atan_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "atan",
+ call: builtinMath_atan,
+ },
+ }
+ atan2_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "atan2",
+ call: builtinMath_atan2,
+ },
+ }
+ ceil_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "ceil",
+ call: builtinMath_ceil,
+ },
+ }
+ cos_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "cos",
+ call: builtinMath_cos,
+ },
+ }
+ exp_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "exp",
+ call: builtinMath_exp,
+ },
+ }
+ floor_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "floor",
+ call: builtinMath_floor,
+ },
+ }
+ log_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "log",
+ call: builtinMath_log,
+ },
+ }
+ max_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 2,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "max",
+ call: builtinMath_max,
+ },
+ }
+ min_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 2,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "min",
+ call: builtinMath_min,
+ },
+ }
+ pow_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 2,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "pow",
+ call: builtinMath_pow,
+ },
+ }
+ random_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "random",
+ call: builtinMath_random,
+ },
+ }
+ round_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "round",
+ call: builtinMath_round,
+ },
+ }
+ sin_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "sin",
+ call: builtinMath_sin,
+ },
+ }
+ sqrt_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "sqrt",
+ call: builtinMath_sqrt,
+ },
+ }
+ tan_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "tan",
+ call: builtinMath_tan,
+ },
+ }
+ runtime.global.Math = &_object{
+ runtime: runtime,
+ class: "Math",
+ objectClass: _classObject,
+ prototype: runtime.global.ObjectPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "abs": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: abs_function,
+ },
+ },
+ "acos": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: acos_function,
+ },
+ },
+ "asin": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: asin_function,
+ },
+ },
+ "atan": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: atan_function,
+ },
+ },
+ "atan2": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: atan2_function,
+ },
+ },
+ "ceil": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: ceil_function,
+ },
+ },
+ "cos": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: cos_function,
+ },
+ },
+ "exp": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: exp_function,
+ },
+ },
+ "floor": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: floor_function,
+ },
+ },
+ "log": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: log_function,
+ },
+ },
+ "max": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: max_function,
+ },
+ },
+ "min": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: min_function,
+ },
+ },
+ "pow": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: pow_function,
+ },
+ },
+ "random": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: random_function,
+ },
+ },
+ "round": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: round_function,
+ },
+ },
+ "sin": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: sin_function,
+ },
+ },
+ "sqrt": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: sqrt_function,
+ },
+ },
+ "tan": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: tan_function,
+ },
+ },
+ "E": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: math.E,
+ },
+ },
+ "LN10": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: math.Ln10,
+ },
+ },
+ "LN2": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: math.Ln2,
+ },
+ },
+ "LOG2E": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: math.Log2E,
+ },
+ },
+ "LOG10E": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: math.Log10E,
+ },
+ },
+ "PI": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: math.Pi,
+ },
+ },
+ "SQRT1_2": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: sqrt1_2,
+ },
+ },
+ "SQRT2": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: math.Sqrt2,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "abs",
+ "acos",
+ "asin",
+ "atan",
+ "atan2",
+ "ceil",
+ "cos",
+ "exp",
+ "floor",
+ "log",
+ "max",
+ "min",
+ "pow",
+ "random",
+ "round",
+ "sin",
+ "sqrt",
+ "tan",
+ "E",
+ "LN10",
+ "LN2",
+ "LOG2E",
+ "LOG10E",
+ "PI",
+ "SQRT1_2",
+ "SQRT2",
+ },
+ }
+ }
+ {
+ toString_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "toString",
+ call: builtinDate_toString,
+ },
+ }
+ toDateString_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "toDateString",
+ call: builtinDate_toDateString,
+ },
+ }
+ toTimeString_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "toTimeString",
+ call: builtinDate_toTimeString,
+ },
+ }
+ toUTCString_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "toUTCString",
+ call: builtinDate_toUTCString,
+ },
+ }
+ toISOString_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "toISOString",
+ call: builtinDate_toISOString,
+ },
+ }
+ toJSON_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "toJSON",
+ call: builtinDate_toJSON,
+ },
+ }
+ toGMTString_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "toGMTString",
+ call: builtinDate_toGMTString,
+ },
+ }
+ toLocaleString_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "toLocaleString",
+ call: builtinDate_toLocaleString,
+ },
+ }
+ toLocaleDateString_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "toLocaleDateString",
+ call: builtinDate_toLocaleDateString,
+ },
+ }
+ toLocaleTimeString_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "toLocaleTimeString",
+ call: builtinDate_toLocaleTimeString,
+ },
+ }
+ valueOf_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "valueOf",
+ call: builtinDate_valueOf,
+ },
+ }
+ getTime_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "getTime",
+ call: builtinDate_getTime,
+ },
+ }
+ getYear_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "getYear",
+ call: builtinDate_getYear,
+ },
+ }
+ getFullYear_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "getFullYear",
+ call: builtinDate_getFullYear,
+ },
+ }
+ getUTCFullYear_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "getUTCFullYear",
+ call: builtinDate_getUTCFullYear,
+ },
+ }
+ getMonth_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "getMonth",
+ call: builtinDate_getMonth,
+ },
+ }
+ getUTCMonth_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "getUTCMonth",
+ call: builtinDate_getUTCMonth,
+ },
+ }
+ getDate_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "getDate",
+ call: builtinDate_getDate,
+ },
+ }
+ getUTCDate_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "getUTCDate",
+ call: builtinDate_getUTCDate,
+ },
+ }
+ getDay_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "getDay",
+ call: builtinDate_getDay,
+ },
+ }
+ getUTCDay_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "getUTCDay",
+ call: builtinDate_getUTCDay,
+ },
+ }
+ getHours_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "getHours",
+ call: builtinDate_getHours,
+ },
+ }
+ getUTCHours_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "getUTCHours",
+ call: builtinDate_getUTCHours,
+ },
+ }
+ getMinutes_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "getMinutes",
+ call: builtinDate_getMinutes,
+ },
+ }
+ getUTCMinutes_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "getUTCMinutes",
+ call: builtinDate_getUTCMinutes,
+ },
+ }
+ getSeconds_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "getSeconds",
+ call: builtinDate_getSeconds,
+ },
+ }
+ getUTCSeconds_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "getUTCSeconds",
+ call: builtinDate_getUTCSeconds,
+ },
+ }
+ getMilliseconds_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "getMilliseconds",
+ call: builtinDate_getMilliseconds,
+ },
+ }
+ getUTCMilliseconds_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "getUTCMilliseconds",
+ call: builtinDate_getUTCMilliseconds,
+ },
+ }
+ getTimezoneOffset_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "getTimezoneOffset",
+ call: builtinDate_getTimezoneOffset,
+ },
+ }
+ setTime_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "setTime",
+ call: builtinDate_setTime,
+ },
+ }
+ setMilliseconds_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "setMilliseconds",
+ call: builtinDate_setMilliseconds,
+ },
+ }
+ setUTCMilliseconds_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "setUTCMilliseconds",
+ call: builtinDate_setUTCMilliseconds,
+ },
+ }
+ setSeconds_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 2,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "setSeconds",
+ call: builtinDate_setSeconds,
+ },
+ }
+ setUTCSeconds_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 2,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "setUTCSeconds",
+ call: builtinDate_setUTCSeconds,
+ },
+ }
+ setMinutes_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 3,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "setMinutes",
+ call: builtinDate_setMinutes,
+ },
+ }
+ setUTCMinutes_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 3,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "setUTCMinutes",
+ call: builtinDate_setUTCMinutes,
+ },
+ }
+ setHours_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 4,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "setHours",
+ call: builtinDate_setHours,
+ },
+ }
+ setUTCHours_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 4,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "setUTCHours",
+ call: builtinDate_setUTCHours,
+ },
+ }
+ setDate_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "setDate",
+ call: builtinDate_setDate,
+ },
+ }
+ setUTCDate_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "setUTCDate",
+ call: builtinDate_setUTCDate,
+ },
+ }
+ setMonth_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 2,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "setMonth",
+ call: builtinDate_setMonth,
+ },
+ }
+ setUTCMonth_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 2,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "setUTCMonth",
+ call: builtinDate_setUTCMonth,
+ },
+ }
+ setYear_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "setYear",
+ call: builtinDate_setYear,
+ },
+ }
+ setFullYear_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 3,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "setFullYear",
+ call: builtinDate_setFullYear,
+ },
+ }
+ setUTCFullYear_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 3,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "setUTCFullYear",
+ call: builtinDate_setUTCFullYear,
+ },
+ }
+ parse_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "parse",
+ call: builtinDate_parse,
+ },
+ }
+ UTC_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 7,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "UTC",
+ call: builtinDate_UTC,
+ },
+ }
+ now_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "now",
+ call: builtinDate_now,
+ },
+ }
+ runtime.global.DatePrototype = &_object{
+ runtime: runtime,
+ class: "Date",
+ objectClass: _classObject,
+ prototype: runtime.global.ObjectPrototype,
+ extensible: true,
+ value: prototypeValueDate,
+ property: map[string]_property{
+ "toString": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: toString_function,
+ },
+ },
+ "toDateString": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: toDateString_function,
+ },
+ },
+ "toTimeString": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: toTimeString_function,
+ },
+ },
+ "toUTCString": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: toUTCString_function,
+ },
+ },
+ "toISOString": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: toISOString_function,
+ },
+ },
+ "toJSON": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: toJSON_function,
+ },
+ },
+ "toGMTString": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: toGMTString_function,
+ },
+ },
+ "toLocaleString": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: toLocaleString_function,
+ },
+ },
+ "toLocaleDateString": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: toLocaleDateString_function,
+ },
+ },
+ "toLocaleTimeString": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: toLocaleTimeString_function,
+ },
+ },
+ "valueOf": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: valueOf_function,
+ },
+ },
+ "getTime": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: getTime_function,
+ },
+ },
+ "getYear": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: getYear_function,
+ },
+ },
+ "getFullYear": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: getFullYear_function,
+ },
+ },
+ "getUTCFullYear": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: getUTCFullYear_function,
+ },
+ },
+ "getMonth": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: getMonth_function,
+ },
+ },
+ "getUTCMonth": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: getUTCMonth_function,
+ },
+ },
+ "getDate": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: getDate_function,
+ },
+ },
+ "getUTCDate": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: getUTCDate_function,
+ },
+ },
+ "getDay": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: getDay_function,
+ },
+ },
+ "getUTCDay": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: getUTCDay_function,
+ },
+ },
+ "getHours": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: getHours_function,
+ },
+ },
+ "getUTCHours": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: getUTCHours_function,
+ },
+ },
+ "getMinutes": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: getMinutes_function,
+ },
+ },
+ "getUTCMinutes": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: getUTCMinutes_function,
+ },
+ },
+ "getSeconds": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: getSeconds_function,
+ },
+ },
+ "getUTCSeconds": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: getUTCSeconds_function,
+ },
+ },
+ "getMilliseconds": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: getMilliseconds_function,
+ },
+ },
+ "getUTCMilliseconds": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: getUTCMilliseconds_function,
+ },
+ },
+ "getTimezoneOffset": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: getTimezoneOffset_function,
+ },
+ },
+ "setTime": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: setTime_function,
+ },
+ },
+ "setMilliseconds": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: setMilliseconds_function,
+ },
+ },
+ "setUTCMilliseconds": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: setUTCMilliseconds_function,
+ },
+ },
+ "setSeconds": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: setSeconds_function,
+ },
+ },
+ "setUTCSeconds": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: setUTCSeconds_function,
+ },
+ },
+ "setMinutes": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: setMinutes_function,
+ },
+ },
+ "setUTCMinutes": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: setUTCMinutes_function,
+ },
+ },
+ "setHours": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: setHours_function,
+ },
+ },
+ "setUTCHours": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: setUTCHours_function,
+ },
+ },
+ "setDate": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: setDate_function,
+ },
+ },
+ "setUTCDate": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: setUTCDate_function,
+ },
+ },
+ "setMonth": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: setMonth_function,
+ },
+ },
+ "setUTCMonth": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: setUTCMonth_function,
+ },
+ },
+ "setYear": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: setYear_function,
+ },
+ },
+ "setFullYear": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: setFullYear_function,
+ },
+ },
+ "setUTCFullYear": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: setUTCFullYear_function,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "toString",
+ "toDateString",
+ "toTimeString",
+ "toUTCString",
+ "toISOString",
+ "toJSON",
+ "toGMTString",
+ "toLocaleString",
+ "toLocaleDateString",
+ "toLocaleTimeString",
+ "valueOf",
+ "getTime",
+ "getYear",
+ "getFullYear",
+ "getUTCFullYear",
+ "getMonth",
+ "getUTCMonth",
+ "getDate",
+ "getUTCDate",
+ "getDay",
+ "getUTCDay",
+ "getHours",
+ "getUTCHours",
+ "getMinutes",
+ "getUTCMinutes",
+ "getSeconds",
+ "getUTCSeconds",
+ "getMilliseconds",
+ "getUTCMilliseconds",
+ "getTimezoneOffset",
+ "setTime",
+ "setMilliseconds",
+ "setUTCMilliseconds",
+ "setSeconds",
+ "setUTCSeconds",
+ "setMinutes",
+ "setUTCMinutes",
+ "setHours",
+ "setUTCHours",
+ "setDate",
+ "setUTCDate",
+ "setMonth",
+ "setUTCMonth",
+ "setYear",
+ "setFullYear",
+ "setUTCFullYear",
+ },
+ }
+ runtime.global.Date = &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ value: _nativeFunctionObject{
+ name: "Date",
+ call: builtinDate,
+ construct: builtinNewDate,
+ },
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 7,
+ },
+ },
+ "prototype": _property{
+ mode: 0,
+ value: Value{
+ kind: valueObject,
+ value: runtime.global.DatePrototype,
+ },
+ },
+ "parse": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: parse_function,
+ },
+ },
+ "UTC": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: UTC_function,
+ },
+ },
+ "now": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: now_function,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ "prototype",
+ "parse",
+ "UTC",
+ "now",
+ },
+ }
+ runtime.global.DatePrototype.property["constructor"] =
+ _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: runtime.global.Date,
+ },
+ }
+ }
+ {
+ toString_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "toString",
+ call: builtinRegExp_toString,
+ },
+ }
+ exec_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "exec",
+ call: builtinRegExp_exec,
+ },
+ }
+ test_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "test",
+ call: builtinRegExp_test,
+ },
+ }
+ compile_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "compile",
+ call: builtinRegExp_compile,
+ },
+ }
+ runtime.global.RegExpPrototype = &_object{
+ runtime: runtime,
+ class: "RegExp",
+ objectClass: _classObject,
+ prototype: runtime.global.ObjectPrototype,
+ extensible: true,
+ value: prototypeValueRegExp,
+ property: map[string]_property{
+ "toString": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: toString_function,
+ },
+ },
+ "exec": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: exec_function,
+ },
+ },
+ "test": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: test_function,
+ },
+ },
+ "compile": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: compile_function,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "toString",
+ "exec",
+ "test",
+ "compile",
+ },
+ }
+ runtime.global.RegExp = &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ value: _nativeFunctionObject{
+ name: "RegExp",
+ call: builtinRegExp,
+ construct: builtinNewRegExp,
+ },
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 2,
+ },
+ },
+ "prototype": _property{
+ mode: 0,
+ value: Value{
+ kind: valueObject,
+ value: runtime.global.RegExpPrototype,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ "prototype",
+ },
+ }
+ runtime.global.RegExpPrototype.property["constructor"] =
+ _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: runtime.global.RegExp,
+ },
+ }
+ }
+ {
+ toString_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "toString",
+ call: builtinError_toString,
+ },
+ }
+ runtime.global.ErrorPrototype = &_object{
+ runtime: runtime,
+ class: "Error",
+ objectClass: _classObject,
+ prototype: runtime.global.ObjectPrototype,
+ extensible: true,
+ value: nil,
+ property: map[string]_property{
+ "toString": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: toString_function,
+ },
+ },
+ "name": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueString,
+ value: "Error",
+ },
+ },
+ "message": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueString,
+ value: "",
+ },
+ },
+ },
+ propertyOrder: []string{
+ "toString",
+ "name",
+ "message",
+ },
+ }
+ runtime.global.Error = &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ value: _nativeFunctionObject{
+ name: "Error",
+ call: builtinError,
+ construct: builtinNewError,
+ },
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ "prototype": _property{
+ mode: 0,
+ value: Value{
+ kind: valueObject,
+ value: runtime.global.ErrorPrototype,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ "prototype",
+ },
+ }
+ runtime.global.ErrorPrototype.property["constructor"] =
+ _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: runtime.global.Error,
+ },
+ }
+ }
+ {
+ runtime.global.EvalErrorPrototype = &_object{
+ runtime: runtime,
+ class: "EvalError",
+ objectClass: _classObject,
+ prototype: runtime.global.ErrorPrototype,
+ extensible: true,
+ value: nil,
+ property: map[string]_property{
+ "name": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueString,
+ value: "EvalError",
+ },
+ },
+ },
+ propertyOrder: []string{
+ "name",
+ },
+ }
+ runtime.global.EvalError = &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ value: _nativeFunctionObject{
+ name: "EvalError",
+ call: builtinEvalError,
+ construct: builtinNewEvalError,
+ },
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ "prototype": _property{
+ mode: 0,
+ value: Value{
+ kind: valueObject,
+ value: runtime.global.EvalErrorPrototype,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ "prototype",
+ },
+ }
+ runtime.global.EvalErrorPrototype.property["constructor"] =
+ _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: runtime.global.EvalError,
+ },
+ }
+ }
+ {
+ runtime.global.TypeErrorPrototype = &_object{
+ runtime: runtime,
+ class: "TypeError",
+ objectClass: _classObject,
+ prototype: runtime.global.ErrorPrototype,
+ extensible: true,
+ value: nil,
+ property: map[string]_property{
+ "name": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueString,
+ value: "TypeError",
+ },
+ },
+ },
+ propertyOrder: []string{
+ "name",
+ },
+ }
+ runtime.global.TypeError = &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ value: _nativeFunctionObject{
+ name: "TypeError",
+ call: builtinTypeError,
+ construct: builtinNewTypeError,
+ },
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ "prototype": _property{
+ mode: 0,
+ value: Value{
+ kind: valueObject,
+ value: runtime.global.TypeErrorPrototype,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ "prototype",
+ },
+ }
+ runtime.global.TypeErrorPrototype.property["constructor"] =
+ _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: runtime.global.TypeError,
+ },
+ }
+ }
+ {
+ runtime.global.RangeErrorPrototype = &_object{
+ runtime: runtime,
+ class: "RangeError",
+ objectClass: _classObject,
+ prototype: runtime.global.ErrorPrototype,
+ extensible: true,
+ value: nil,
+ property: map[string]_property{
+ "name": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueString,
+ value: "RangeError",
+ },
+ },
+ },
+ propertyOrder: []string{
+ "name",
+ },
+ }
+ runtime.global.RangeError = &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ value: _nativeFunctionObject{
+ name: "RangeError",
+ call: builtinRangeError,
+ construct: builtinNewRangeError,
+ },
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ "prototype": _property{
+ mode: 0,
+ value: Value{
+ kind: valueObject,
+ value: runtime.global.RangeErrorPrototype,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ "prototype",
+ },
+ }
+ runtime.global.RangeErrorPrototype.property["constructor"] =
+ _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: runtime.global.RangeError,
+ },
+ }
+ }
+ {
+ runtime.global.ReferenceErrorPrototype = &_object{
+ runtime: runtime,
+ class: "ReferenceError",
+ objectClass: _classObject,
+ prototype: runtime.global.ErrorPrototype,
+ extensible: true,
+ value: nil,
+ property: map[string]_property{
+ "name": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueString,
+ value: "ReferenceError",
+ },
+ },
+ },
+ propertyOrder: []string{
+ "name",
+ },
+ }
+ runtime.global.ReferenceError = &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ value: _nativeFunctionObject{
+ name: "ReferenceError",
+ call: builtinReferenceError,
+ construct: builtinNewReferenceError,
+ },
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ "prototype": _property{
+ mode: 0,
+ value: Value{
+ kind: valueObject,
+ value: runtime.global.ReferenceErrorPrototype,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ "prototype",
+ },
+ }
+ runtime.global.ReferenceErrorPrototype.property["constructor"] =
+ _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: runtime.global.ReferenceError,
+ },
+ }
+ }
+ {
+ runtime.global.SyntaxErrorPrototype = &_object{
+ runtime: runtime,
+ class: "SyntaxError",
+ objectClass: _classObject,
+ prototype: runtime.global.ErrorPrototype,
+ extensible: true,
+ value: nil,
+ property: map[string]_property{
+ "name": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueString,
+ value: "SyntaxError",
+ },
+ },
+ },
+ propertyOrder: []string{
+ "name",
+ },
+ }
+ runtime.global.SyntaxError = &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ value: _nativeFunctionObject{
+ name: "SyntaxError",
+ call: builtinSyntaxError,
+ construct: builtinNewSyntaxError,
+ },
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ "prototype": _property{
+ mode: 0,
+ value: Value{
+ kind: valueObject,
+ value: runtime.global.SyntaxErrorPrototype,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ "prototype",
+ },
+ }
+ runtime.global.SyntaxErrorPrototype.property["constructor"] =
+ _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: runtime.global.SyntaxError,
+ },
+ }
+ }
+ {
+ runtime.global.URIErrorPrototype = &_object{
+ runtime: runtime,
+ class: "URIError",
+ objectClass: _classObject,
+ prototype: runtime.global.ErrorPrototype,
+ extensible: true,
+ value: nil,
+ property: map[string]_property{
+ "name": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueString,
+ value: "URIError",
+ },
+ },
+ },
+ propertyOrder: []string{
+ "name",
+ },
+ }
+ runtime.global.URIError = &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ value: _nativeFunctionObject{
+ name: "URIError",
+ call: builtinURIError,
+ construct: builtinNewURIError,
+ },
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ "prototype": _property{
+ mode: 0,
+ value: Value{
+ kind: valueObject,
+ value: runtime.global.URIErrorPrototype,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ "prototype",
+ },
+ }
+ runtime.global.URIErrorPrototype.property["constructor"] =
+ _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: runtime.global.URIError,
+ },
+ }
+ }
+ {
+ parse_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 2,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "parse",
+ call: builtinJSON_parse,
+ },
+ }
+ stringify_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 3,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "stringify",
+ call: builtinJSON_stringify,
+ },
+ }
+ runtime.global.JSON = &_object{
+ runtime: runtime,
+ class: "JSON",
+ objectClass: _classObject,
+ prototype: runtime.global.ObjectPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "parse": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: parse_function,
+ },
+ },
+ "stringify": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: stringify_function,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "parse",
+ "stringify",
+ },
+ }
+ }
+ {
+ eval_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "eval",
+ call: builtinGlobal_eval,
+ },
+ }
+ parseInt_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 2,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "parseInt",
+ call: builtinGlobal_parseInt,
+ },
+ }
+ parseFloat_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "parseFloat",
+ call: builtinGlobal_parseFloat,
+ },
+ }
+ isNaN_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "isNaN",
+ call: builtinGlobal_isNaN,
+ },
+ }
+ isFinite_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "isFinite",
+ call: builtinGlobal_isFinite,
+ },
+ }
+ decodeURI_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "decodeURI",
+ call: builtinGlobal_decodeURI,
+ },
+ }
+ decodeURIComponent_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "decodeURIComponent",
+ call: builtinGlobal_decodeURIComponent,
+ },
+ }
+ encodeURI_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "encodeURI",
+ call: builtinGlobal_encodeURI,
+ },
+ }
+ encodeURIComponent_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "encodeURIComponent",
+ call: builtinGlobal_encodeURIComponent,
+ },
+ }
+ escape_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "escape",
+ call: builtinGlobal_escape,
+ },
+ }
+ unescape_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 1,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "unescape",
+ call: builtinGlobal_unescape,
+ },
+ }
+ runtime.globalObject.property = map[string]_property{
+ "eval": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: eval_function,
+ },
+ },
+ "parseInt": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: parseInt_function,
+ },
+ },
+ "parseFloat": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: parseFloat_function,
+ },
+ },
+ "isNaN": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: isNaN_function,
+ },
+ },
+ "isFinite": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: isFinite_function,
+ },
+ },
+ "decodeURI": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: decodeURI_function,
+ },
+ },
+ "decodeURIComponent": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: decodeURIComponent_function,
+ },
+ },
+ "encodeURI": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: encodeURI_function,
+ },
+ },
+ "encodeURIComponent": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: encodeURIComponent_function,
+ },
+ },
+ "escape": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: escape_function,
+ },
+ },
+ "unescape": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: unescape_function,
+ },
+ },
+ "Object": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: runtime.global.Object,
+ },
+ },
+ "Function": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: runtime.global.Function,
+ },
+ },
+ "Array": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: runtime.global.Array,
+ },
+ },
+ "String": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: runtime.global.String,
+ },
+ },
+ "Boolean": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: runtime.global.Boolean,
+ },
+ },
+ "Number": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: runtime.global.Number,
+ },
+ },
+ "Math": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: runtime.global.Math,
+ },
+ },
+ "Date": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: runtime.global.Date,
+ },
+ },
+ "RegExp": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: runtime.global.RegExp,
+ },
+ },
+ "Error": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: runtime.global.Error,
+ },
+ },
+ "EvalError": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: runtime.global.EvalError,
+ },
+ },
+ "TypeError": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: runtime.global.TypeError,
+ },
+ },
+ "RangeError": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: runtime.global.RangeError,
+ },
+ },
+ "ReferenceError": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: runtime.global.ReferenceError,
+ },
+ },
+ "SyntaxError": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: runtime.global.SyntaxError,
+ },
+ },
+ "URIError": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: runtime.global.URIError,
+ },
+ },
+ "JSON": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: runtime.global.JSON,
+ },
+ },
+ "undefined": _property{
+ mode: 0,
+ value: Value{
+ kind: valueUndefined,
+ },
+ },
+ "NaN": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: math.NaN(),
+ },
+ },
+ "Infinity": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: math.Inf(+1),
+ },
+ },
+ }
+ runtime.globalObject.propertyOrder = []string{
+ "eval",
+ "parseInt",
+ "parseFloat",
+ "isNaN",
+ "isFinite",
+ "decodeURI",
+ "decodeURIComponent",
+ "encodeURI",
+ "encodeURIComponent",
+ "escape",
+ "unescape",
+ "Object",
+ "Function",
+ "Array",
+ "String",
+ "Boolean",
+ "Number",
+ "Math",
+ "Date",
+ "RegExp",
+ "Error",
+ "EvalError",
+ "TypeError",
+ "RangeError",
+ "ReferenceError",
+ "SyntaxError",
+ "URIError",
+ "JSON",
+ "undefined",
+ "NaN",
+ "Infinity",
+ }
+ }
+}
+
+func newConsoleObject(runtime *_runtime) *_object {
+ {
+ log_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "log",
+ call: builtinConsole_log,
+ },
+ }
+ debug_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "debug",
+ call: builtinConsole_log,
+ },
+ }
+ info_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "info",
+ call: builtinConsole_log,
+ },
+ }
+ error_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "error",
+ call: builtinConsole_error,
+ },
+ }
+ warn_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "warn",
+ call: builtinConsole_error,
+ },
+ }
+ dir_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "dir",
+ call: builtinConsole_dir,
+ },
+ }
+ time_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "time",
+ call: builtinConsole_time,
+ },
+ }
+ timeEnd_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "timeEnd",
+ call: builtinConsole_timeEnd,
+ },
+ }
+ trace_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "trace",
+ call: builtinConsole_trace,
+ },
+ }
+ assert_function := &_object{
+ runtime: runtime,
+ class: "Function",
+ objectClass: _classObject,
+ prototype: runtime.global.FunctionPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "length": _property{
+ mode: 0,
+ value: Value{
+ kind: valueNumber,
+ value: 0,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "length",
+ },
+ value: _nativeFunctionObject{
+ name: "assert",
+ call: builtinConsole_assert,
+ },
+ }
+ return &_object{
+ runtime: runtime,
+ class: "Object",
+ objectClass: _classObject,
+ prototype: runtime.global.ObjectPrototype,
+ extensible: true,
+ property: map[string]_property{
+ "log": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: log_function,
+ },
+ },
+ "debug": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: debug_function,
+ },
+ },
+ "info": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: info_function,
+ },
+ },
+ "error": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: error_function,
+ },
+ },
+ "warn": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: warn_function,
+ },
+ },
+ "dir": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: dir_function,
+ },
+ },
+ "time": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: time_function,
+ },
+ },
+ "timeEnd": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: timeEnd_function,
+ },
+ },
+ "trace": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: trace_function,
+ },
+ },
+ "assert": _property{
+ mode: 0101,
+ value: Value{
+ kind: valueObject,
+ value: assert_function,
+ },
+ },
+ },
+ propertyOrder: []string{
+ "log",
+ "debug",
+ "info",
+ "error",
+ "warn",
+ "dir",
+ "time",
+ "timeEnd",
+ "trace",
+ "assert",
+ },
+ }
+ }
+}
+
+func toValue_int(value int) Value {
+ return Value{
+ kind: valueNumber,
+ value: value,
+ }
+}
+
+func toValue_int8(value int8) Value {
+ return Value{
+ kind: valueNumber,
+ value: value,
+ }
+}
+
+func toValue_int16(value int16) Value {
+ return Value{
+ kind: valueNumber,
+ value: value,
+ }
+}
+
+func toValue_int32(value int32) Value {
+ return Value{
+ kind: valueNumber,
+ value: value,
+ }
+}
+
+func toValue_int64(value int64) Value {
+ return Value{
+ kind: valueNumber,
+ value: value,
+ }
+}
+
+func toValue_uint(value uint) Value {
+ return Value{
+ kind: valueNumber,
+ value: value,
+ }
+}
+
+func toValue_uint8(value uint8) Value {
+ return Value{
+ kind: valueNumber,
+ value: value,
+ }
+}
+
+func toValue_uint16(value uint16) Value {
+ return Value{
+ kind: valueNumber,
+ value: value,
+ }
+}
+
+func toValue_uint32(value uint32) Value {
+ return Value{
+ kind: valueNumber,
+ value: value,
+ }
+}
+
+func toValue_uint64(value uint64) Value {
+ return Value{
+ kind: valueNumber,
+ value: value,
+ }
+}
+
+func toValue_float32(value float32) Value {
+ return Value{
+ kind: valueNumber,
+ value: value,
+ }
+}
+
+func toValue_float64(value float64) Value {
+ return Value{
+ kind: valueNumber,
+ value: value,
+ }
+}
+
+func toValue_string(value string) Value {
+ return Value{
+ kind: valueString,
+ value: value,
+ }
+}
+
+func toValue_string16(value []uint16) Value {
+ return Value{
+ kind: valueString,
+ value: value,
+ }
+}
+
+func toValue_bool(value bool) Value {
+ return Value{
+ kind: valueBoolean,
+ value: value,
+ }
+}
+
+func toValue_object(value *_object) Value {
+ return Value{
+ kind: valueObject,
+ value: value,
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/json_test.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/json_test.go
new file mode 100644
index 000000000..4dd2ed7bf
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/json_test.go
@@ -0,0 +1,183 @@
+package otto
+
+import (
+ "testing"
+)
+
+func BenchmarkJSON_parse(b *testing.B) {
+ vm := New()
+ for i := 0; i < b.N; i++ {
+ vm.Run(`JSON.parse("1")`)
+ vm.Run(`JSON.parse("[1,2,3]")`)
+ vm.Run(`JSON.parse('{"a":{"x":100,"y":110},"b":[10,20,30],"c":"zazazaza"}')`)
+ vm.Run(`JSON.parse("[1,2,3]", function(k, v) { return undefined })`)
+ }
+}
+
+func TestJSON_parse(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ JSON.parse("1");
+ `, 1)
+
+ test(`
+ JSON.parse("null");
+ `, "null") // TODO Can we make this nil?
+
+ test(`
+ var abc = JSON.parse('"a\uFFFFbc"');
+ [ abc[0], abc[2], abc[3], abc.length ];
+ `, "a,b,c,4")
+
+ test(`
+ JSON.parse("[1, 2, 3]");
+ `, "1,2,3")
+
+ test(`
+ JSON.parse('{ "abc": 1, "def":2 }').abc;
+ `, 1)
+
+ test(`
+ JSON.parse('{ "abc": { "x": 100, "y": 110 }, "def": [ 10, 20 ,30 ], "ghi": "zazazaza" }').def;
+ `, "10,20,30")
+
+ test(`raise:
+ JSON.parse("12\t\r\n 34");
+ `, "SyntaxError: invalid character '3' after top-level value")
+
+ test(`
+ JSON.parse("[1, 2, 3]", function() { return undefined });
+ `, "undefined")
+
+ test(`raise:
+ JSON.parse("");
+ `, "SyntaxError: unexpected end of JSON input")
+
+ test(`raise:
+ JSON.parse("[1, 2, 3");
+ `, "SyntaxError: unexpected end of JSON input")
+
+ test(`raise:
+ JSON.parse("[1, 2, ; abc=10");
+ `, "SyntaxError: invalid character ';' looking for beginning of value")
+
+ test(`raise:
+ JSON.parse("[1, 2, function(){}]");
+ `, "SyntaxError: invalid character 'u' in literal false (expecting 'a')")
+ })
+}
+
+func TestJSON_stringify(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ defer mockUTC()()
+
+ test(`
+ JSON.stringify(function(){});
+ `, "undefined")
+
+ test(`
+ JSON.stringify(new Boolean(false));
+ `, "false")
+
+ test(`
+ JSON.stringify({a1: {b1: [1,2,3,4], b2: {c1: 1, c2: 2}}, a2: 'a2'}, null, -5);
+ `, `{"a1":{"b1":[1,2,3,4],"b2":{"c1":1,"c2":2}},"a2":"a2"}`)
+
+ test(`
+ JSON.stringify(undefined);
+ `, "undefined")
+
+ test(`
+ JSON.stringify(1);
+ `, "1")
+
+ test(`
+ JSON.stringify("abc def");
+ `, "\"abc def\"")
+
+ test(`
+ JSON.stringify(3.14159);
+ `, "3.14159")
+
+ test(`
+ JSON.stringify([]);
+ `, "[]")
+
+ test(`
+ JSON.stringify([1, 2, 3]);
+ `, "[1,2,3]")
+
+ test(`
+ JSON.stringify([true, false, null]);
+ `, "[true,false,null]")
+
+ test(`
+ JSON.stringify({
+ abc: { x: 100, y: 110 },
+ def: [ 10, 20, 30 ],
+ ghi: "zazazaza"
+ });
+ `, `{"abc":{"x":100,"y":110},"def":[10,20,30],"ghi":"zazazaza"}`)
+
+ test(`
+ JSON.stringify([
+ 'e',
+ {pluribus: 'unum'}
+ ], null, '\t');
+ `, "[\n\t\"e\",\n\t{\n\t\t\"pluribus\": \"unum\"\n\t}\n]")
+
+ test(`
+ JSON.stringify(new Date(0));
+ `, `"1970-01-01T00:00:00.000Z"`)
+
+ test(`
+ JSON.stringify([ new Date(0) ], function(key, value){
+ return this[key] instanceof Date ? 'Date(' + this[key] + ')' : value
+ });
+ `, `["Date(Thu, 01 Jan 1970 00:00:00 UTC)"]`)
+
+ test(`
+ JSON.stringify({
+ abc: 1,
+ def: 2,
+ ghi: 3
+ }, ['abc','def']);
+ `, `{"abc":1,"def":2}`)
+
+ test(`raise:
+ var abc = {
+ def: null
+ };
+ abc.def = abc;
+ JSON.stringify(abc)
+ `, "TypeError: Converting circular structure to JSON")
+
+ test(`raise:
+ var abc= [ null ];
+ abc[0] = abc;
+ JSON.stringify(abc);
+ `, "TypeError: Converting circular structure to JSON")
+
+ test(`raise:
+ var abc = {
+ def: {}
+ };
+ abc.def.ghi = abc;
+ JSON.stringify(abc)
+ `, "TypeError: Converting circular structure to JSON")
+
+ test(`
+ var ghi = { "pi": 3.14159 };
+ var abc = {
+ def: {}
+ };
+ abc.ghi = ghi;
+ abc.def.ghi = ghi;
+ JSON.stringify(abc);
+ `, `{"def":{"ghi":{"pi":3.14159}},"ghi":{"pi":3.14159}}`)
+ })
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/math_test.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/math_test.go
new file mode 100644
index 000000000..499998b14
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/math_test.go
@@ -0,0 +1,303 @@
+package otto
+
+import (
+ "math"
+ "testing"
+)
+
+var _NaN = math.NaN()
+var _Infinity = math.Inf(1)
+
+func TestMath_toString(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`Math.toString()`, "[object Math]")
+ })
+}
+
+func TestMath_abs(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`Math.abs(NaN)`, _NaN)
+ test(`Math.abs(2)`, 2)
+ test(`Math.abs(-2)`, 2)
+ test(`Math.abs(-Infinity)`, _Infinity)
+
+ test(`Math.acos(0.5)`, 1.0471975511965976)
+
+ test(`Math.abs('-1')`, 1)
+ test(`Math.abs(-2)`, 2)
+ test(`Math.abs(null)`, 0)
+ test(`Math.abs("string")`, _NaN)
+ test(`Math.abs()`, _NaN)
+ })
+}
+
+func TestMath_acos(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`Math.acos(NaN)`, _NaN)
+ test(`Math.acos(2)`, _NaN)
+ test(`Math.acos(-2)`, _NaN)
+ test(`1/Math.acos(1)`, _Infinity)
+
+ test(`Math.acos(0.5)`, 1.0471975511965976)
+ })
+}
+
+func TestMath_asin(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`Math.asin(NaN)`, _NaN)
+ test(`Math.asin(2)`, _NaN)
+ test(`Math.asin(-2)`, _NaN)
+ test(`1/Math.asin(0)`, _Infinity)
+ test(`1/Math.asin(-0)`, -_Infinity)
+
+ test(`Math.asin(0.5)`, 0.5235987755982989)
+ })
+}
+
+func TestMath_atan(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`Math.atan(NaN)`, _NaN)
+ test(`1/Math.atan(0)`, _Infinity)
+ test(`1/Math.atan(-0)`, -_Infinity)
+ test(`Math.atan(Infinity)`, 1.5707963267948966)
+ test(`Math.atan(-Infinity)`, -1.5707963267948966)
+
+ // freebsd/386 1.03 => 0.4636476090008061
+ // darwin 1.03 => 0.46364760900080604
+ test(`Math.atan(0.5).toPrecision(10)`, "0.463647609")
+ })
+}
+
+func TestMath_atan2(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`Math.atan2()`, _NaN)
+ test(`Math.atan2(NaN)`, _NaN)
+ test(`Math.atan2(0, NaN)`, _NaN)
+
+ test(`Math.atan2(1, 0)`, 1.5707963267948966)
+ test(`Math.atan2(1, -0)`, 1.5707963267948966)
+
+ test(`1/Math.atan2(0, 1)`, _Infinity)
+ test(`1/Math.atan2(0, 0)`, _Infinity)
+ test(`Math.atan2(0, -0)`, 3.141592653589793)
+ test(`Math.atan2(0, -1)`, 3.141592653589793)
+
+ test(`1/Math.atan2(-0, 1)`, -_Infinity)
+ test(`1/Math.atan2(-0, 0)`, -_Infinity)
+ test(`Math.atan2(-0, -0)`, -3.141592653589793)
+ test(`Math.atan2(-0, -1)`, -3.141592653589793)
+
+ test(`Math.atan2(-1, 0)`, -1.5707963267948966)
+ test(`Math.atan2(-1, -0)`, -1.5707963267948966)
+
+ test(`1/Math.atan2(1, Infinity)`, _Infinity)
+ test(`Math.atan2(1, -Infinity)`, 3.141592653589793)
+ test(`1/Math.atan2(-1, Infinity)`, -_Infinity)
+ test(`Math.atan2(-1, -Infinity)`, -3.141592653589793)
+
+ test(`Math.atan2(Infinity, 1)`, 1.5707963267948966)
+ test(`Math.atan2(-Infinity, 1)`, -1.5707963267948966)
+
+ test(`Math.atan2(Infinity, Infinity)`, 0.7853981633974483)
+ test(`Math.atan2(Infinity, -Infinity)`, 2.356194490192345)
+ test(`Math.atan2(-Infinity, Infinity)`, -0.7853981633974483)
+ test(`Math.atan2(-Infinity, -Infinity)`, -2.356194490192345)
+ })
+}
+
+func TestMath_ceil(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`Math.ceil(NaN)`, _NaN)
+ test(`Math.ceil(+0)`, 0)
+ test(`1/Math.ceil(-0)`, -_Infinity)
+ test(`Math.ceil(Infinity)`, _Infinity)
+ test(`Math.ceil(-Infinity)`, -_Infinity)
+ test(`1/Math.ceil(-0.5)`, -_Infinity)
+
+ test(`Math.ceil(-11)`, -11)
+ test(`Math.ceil(-0.5)`, 0)
+ test(`Math.ceil(1.5)`, 2)
+ })
+}
+
+func TestMath_cos(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`Math.cos(NaN)`, _NaN)
+ test(`Math.cos(+0)`, 1)
+ test(`Math.cos(-0)`, 1)
+ test(`Math.cos(Infinity)`, _NaN)
+ test(`Math.cos(-Infinity)`, _NaN)
+
+ test(`Math.cos(0.5)`, 0.8775825618903728)
+ })
+}
+
+func TestMath_exp(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`Math.exp(NaN)`, _NaN)
+ test(`Math.exp(+0)`, 1)
+ test(`Math.exp(-0)`, 1)
+ test(`Math.exp(Infinity)`, _Infinity)
+ test(`Math.exp(-Infinity)`, 0)
+ })
+}
+
+func TestMath_floor(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`Math.floor(NaN)`, _NaN)
+ test(`Math.floor(+0)`, 0)
+ test(`1/Math.floor(-0)`, -_Infinity)
+ test(`Math.floor(Infinity)`, _Infinity)
+ test(`Math.floor(-Infinity)`, -_Infinity)
+
+ test(`Math.floor(-11)`, -11)
+ test(`Math.floor(-0.5)`, -1)
+ test(`Math.floor(1.5)`, 1)
+ })
+}
+
+func TestMath_log(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`Math.log(NaN)`, _NaN)
+ test(`Math.log(-1)`, _NaN)
+ test(`Math.log(+0)`, -_Infinity)
+ test(`Math.log(-0)`, -_Infinity)
+ test(`1/Math.log(1)`, _Infinity)
+ test(`Math.log(Infinity)`, _Infinity)
+
+ test(`Math.log(0.5)`, -0.6931471805599453)
+ })
+}
+
+func TestMath_max(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`Math.max(-11, -1, 0, 1, 2, 3, 11)`, 11)
+ })
+}
+
+func TestMath_min(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`Math.min(-11, -1, 0, 1, 2, 3, 11)`, -11)
+ })
+}
+
+func TestMath_pow(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`Math.pow(0, NaN)`, _NaN)
+ test(`Math.pow(0, 0)`, 1)
+ test(`Math.pow(NaN, 0)`, 1)
+ test(`Math.pow(0, -0)`, 1)
+ test(`Math.pow(NaN, -0)`, 1)
+ test(`Math.pow(NaN, 1)`, _NaN)
+ test(`Math.pow(2, Infinity)`, _Infinity)
+ test(`1/Math.pow(2, -Infinity)`, _Infinity)
+ test(`Math.pow(1, Infinity)`, _NaN)
+ test(`Math.pow(1, -Infinity)`, _NaN)
+ test(`1/Math.pow(0.1, Infinity)`, _Infinity)
+ test(`Math.pow(0.1, -Infinity)`, _Infinity)
+ test(`Math.pow(Infinity, 1)`, _Infinity)
+ test(`1/Math.pow(Infinity, -1)`, _Infinity)
+ test(`Math.pow(-Infinity, 1)`, -_Infinity)
+ test(`Math.pow(-Infinity, 2)`, _Infinity)
+ test(`1/Math.pow(-Infinity, -1)`, -_Infinity)
+ test(`1/Math.pow(-Infinity, -2)`, _Infinity)
+ test(`1/Math.pow(0, 1)`, _Infinity)
+ test(`Math.pow(0, -1)`, _Infinity)
+ test(`1/Math.pow(-0, 1)`, -_Infinity)
+ test(`1/Math.pow(-0, 2)`, _Infinity)
+ test(`Math.pow(-0, -1)`, -_Infinity)
+ test(`Math.pow(-0, -2)`, _Infinity)
+ test(`Math.pow(-1, 0.1)`, _NaN)
+
+ test(`
+ [ Math.pow(-1, +Infinity), Math.pow(1, Infinity) ];
+ `, "NaN,NaN")
+ })
+}
+
+func TestMath_round(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`Math.round(NaN)`, _NaN)
+ test(`1/Math.round(0)`, _Infinity)
+ test(`1/Math.round(-0)`, -_Infinity)
+ test(`Math.round(Infinity)`, _Infinity)
+ test(`Math.round(-Infinity)`, -_Infinity)
+ test(`1/Math.round(0.1)`, _Infinity)
+ test(`1/Math.round(-0.1)`, -_Infinity)
+
+ test(`Math.round(3.5)`, 4)
+ test(`Math.round(-3.5)`, -3)
+ })
+}
+
+func TestMath_sin(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`Math.sin(NaN)`, _NaN)
+ test(`1/Math.sin(+0)`, _Infinity)
+ test(`1/Math.sin(-0)`, -_Infinity)
+ test(`Math.sin(Infinity)`, _NaN)
+ test(`Math.sin(-Infinity)`, _NaN)
+
+ test(`Math.sin(0.5)`, 0.479425538604203)
+ })
+}
+
+func TestMath_sqrt(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`Math.sqrt(NaN)`, _NaN)
+ test(`Math.sqrt(-1)`, _NaN)
+ test(`1/Math.sqrt(+0)`, _Infinity)
+ test(`1/Math.sqrt(-0)`, -_Infinity)
+ test(`Math.sqrt(Infinity)`, _Infinity)
+
+ test(`Math.sqrt(2)`, 1.4142135623730951)
+ })
+}
+
+func TestMath_tan(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`Math.tan(NaN)`, _NaN)
+ test(`1/Math.tan(+0)`, _Infinity)
+ test(`1/Math.tan(-0)`, -_Infinity)
+ test(`Math.tan(Infinity)`, _NaN)
+ test(`Math.tan(-Infinity)`, _NaN)
+
+ test(`Math.tan(0.5)`, 0.5463024898437905)
+ })
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/number_test.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/number_test.go
new file mode 100644
index 000000000..8db01cfc7
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/number_test.go
@@ -0,0 +1,165 @@
+package otto
+
+import (
+ "testing"
+)
+
+func TestNumber(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ var abc = Object.getOwnPropertyDescriptor(Number, "prototype");
+ [ [ typeof Number.prototype ],
+ [ abc.writable, abc.enumerable, abc.configurable ] ];
+ `, "object,false,false,false")
+ })
+}
+
+func TestNumber_toString(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ new Number(451).toString();
+ `, "451")
+
+ test(`
+ new Number(451).toString(10);
+ `, "451")
+
+ test(`
+ new Number(451).toString(8);
+ `, "703")
+
+ test(`raise:
+ new Number(451).toString(1);
+ `, "RangeError: RangeError: toString() radix must be between 2 and 36")
+
+ test(`raise:
+ new Number(451).toString(Infinity);
+ `, "RangeError: RangeError: toString() radix must be between 2 and 36")
+
+ test(`
+ new Number(NaN).toString()
+ `, "NaN")
+
+ test(`
+ new Number(Infinity).toString()
+ `, "Infinity")
+
+ test(`
+ new Number(Infinity).toString(16)
+ `, "Infinity")
+
+ test(`
+ [
+ Number.prototype.toString(undefined),
+ new Number().toString(undefined),
+ new Number(0).toString(undefined),
+ new Number(-1).toString(undefined),
+ new Number(1).toString(undefined),
+ new Number(Number.NaN).toString(undefined),
+ new Number(Number.POSITIVE_INFINITY).toString(undefined),
+ new Number(Number.NEGATIVE_INFINITY).toString(undefined)
+ ]
+ `, "0,0,0,-1,1,NaN,Infinity,-Infinity")
+ })
+}
+
+func TestNumber_toFixed(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`new Number(451).toFixed(2)`, "451.00")
+ test(`12345.6789.toFixed()`, "12346")
+ test(`12345.6789.toFixed(1)`, "12345.7")
+ test(`12345.6789.toFixed(6)`, "12345.678900")
+ test(`(1.23e-20).toFixed(2)`, "0.00")
+ test(`2.34.toFixed(1)`, "2.3") // FIXME Wtf? "2.3"
+ test(`-2.34.toFixed(1)`, -2.3) // FIXME Wtf? -2.3
+ test(`(-2.34).toFixed(1)`, "-2.3")
+
+ test(`raise:
+ new Number("a").toFixed(Number.POSITIVE_INFINITY);
+ `, "RangeError: toFixed() precision must be between 0 and 20")
+
+ test(`
+ [
+ new Number(1e21).toFixed(),
+ new Number(1e21).toFixed(0),
+ new Number(1e21).toFixed(1),
+ new Number(1e21).toFixed(1.1),
+ new Number(1e21).toFixed(0.9),
+ new Number(1e21).toFixed("1"),
+ new Number(1e21).toFixed("1.1"),
+ new Number(1e21).toFixed("0.9"),
+ new Number(1e21).toFixed(Number.NaN),
+ new Number(1e21).toFixed("some string")
+ ];
+ `, "1e+21,1e+21,1e+21,1e+21,1e+21,1e+21,1e+21,1e+21,1e+21,1e+21")
+
+ test(`raise:
+ new Number(1e21).toFixed(Number.POSITIVE_INFINITY);
+ `, "RangeError: toFixed() precision must be between 0 and 20")
+ })
+}
+
+func TestNumber_toExponential(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`new Number(451).toExponential(2)`, "4.51e+02")
+ test(`77.1234.toExponential()`, "7.71234e+01")
+ test(`77.1234.toExponential(4)`, "7.7123e+01")
+ test(`77.1234.toExponential(2)`, "7.71e+01")
+ test(`77 .toExponential()`, "7.7e+01")
+ })
+}
+
+func TestNumber_toPrecision(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`new Number(451).toPrecision()`, "451")
+ test(`new Number(451).toPrecision(1)`, "5e+02")
+ test(`5.123456.toPrecision()`, "5.123456")
+ test(`5.123456.toPrecision(5)`, "5.1235")
+ test(`5.123456.toPrecision(2)`, "5.1")
+ test(`5.123456.toPrecision(1)`, "5")
+ })
+}
+
+func TestNumber_toLocaleString(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ [
+ new Number(451).toLocaleString(),
+ new Number(451).toLocaleString(10),
+ new Number(451).toLocaleString(8)
+ ];
+ `, "451,451,703")
+ })
+}
+
+func TestValue_number(t *testing.T) {
+ tt(t, func() {
+ nm := toValue(0.0).number()
+ is(nm.kind, numberInteger)
+
+ nm = toValue(3.14159).number()
+ is(nm.kind, numberFloat)
+ })
+}
+
+func Test_NaN(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ [ NaN === NaN, NaN == NaN ];
+ `, "false,false")
+ })
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/object.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/object.go
new file mode 100644
index 000000000..849812c91
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/object.go
@@ -0,0 +1,156 @@
+package otto
+
+type _object struct {
+ runtime *_runtime
+
+ class string
+ objectClass *_objectClass
+ value interface{}
+
+ prototype *_object
+ extensible bool
+
+ property map[string]_property
+ propertyOrder []string
+}
+
+func newObject(runtime *_runtime, class string) *_object {
+ self := &_object{
+ runtime: runtime,
+ class: class,
+ objectClass: _classObject,
+ property: make(map[string]_property),
+ extensible: true,
+ }
+ return self
+}
+
+// 8.12
+
+// 8.12.1
+func (self *_object) getOwnProperty(name string) *_property {
+ return self.objectClass.getOwnProperty(self, name)
+}
+
+// 8.12.2
+func (self *_object) getProperty(name string) *_property {
+ return self.objectClass.getProperty(self, name)
+}
+
+// 8.12.3
+func (self *_object) get(name string) Value {
+ return self.objectClass.get(self, name)
+}
+
+// 8.12.4
+func (self *_object) canPut(name string) bool {
+ return self.objectClass.canPut(self, name)
+}
+
+// 8.12.5
+func (self *_object) put(name string, value Value, throw bool) {
+ self.objectClass.put(self, name, value, throw)
+}
+
+// 8.12.6
+func (self *_object) hasProperty(name string) bool {
+ return self.objectClass.hasProperty(self, name)
+}
+
+func (self *_object) hasOwnProperty(name string) bool {
+ return self.objectClass.hasOwnProperty(self, name)
+}
+
+type _defaultValueHint int
+
+const (
+ defaultValueNoHint _defaultValueHint = iota
+ defaultValueHintString
+ defaultValueHintNumber
+)
+
+// 8.12.8
+func (self *_object) DefaultValue(hint _defaultValueHint) Value {
+ if hint == defaultValueNoHint {
+ if self.class == "Date" {
+ // Date exception
+ hint = defaultValueHintString
+ } else {
+ hint = defaultValueHintNumber
+ }
+ }
+ methodSequence := []string{"valueOf", "toString"}
+ if hint == defaultValueHintString {
+ methodSequence = []string{"toString", "valueOf"}
+ }
+ for _, methodName := range methodSequence {
+ method := self.get(methodName)
+ // FIXME This is redundant...
+ if method.isCallable() {
+ result := method._object().call(toValue_object(self), nil, false, nativeFrame)
+ if result.IsPrimitive() {
+ return result
+ }
+ }
+ }
+
+ panic(self.runtime.panicTypeError())
+}
+
+func (self *_object) String() string {
+ return self.DefaultValue(defaultValueHintString).string()
+}
+
+func (self *_object) defineProperty(name string, value Value, mode _propertyMode, throw bool) bool {
+ return self.defineOwnProperty(name, _property{value, mode}, throw)
+}
+
+// 8.12.9
+func (self *_object) defineOwnProperty(name string, descriptor _property, throw bool) bool {
+ return self.objectClass.defineOwnProperty(self, name, descriptor, throw)
+}
+
+func (self *_object) delete(name string, throw bool) bool {
+ return self.objectClass.delete(self, name, throw)
+}
+
+func (self *_object) enumerate(all bool, each func(string) bool) {
+ self.objectClass.enumerate(self, all, each)
+}
+
+func (self *_object) _exists(name string) bool {
+ _, exists := self.property[name]
+ return exists
+}
+
+func (self *_object) _read(name string) (_property, bool) {
+ property, exists := self.property[name]
+ return property, exists
+}
+
+func (self *_object) _write(name string, value interface{}, mode _propertyMode) {
+ if value == nil {
+ value = Value{}
+ }
+ _, exists := self.property[name]
+ self.property[name] = _property{value, mode}
+ if !exists {
+ self.propertyOrder = append(self.propertyOrder, name)
+ }
+}
+
+func (self *_object) _delete(name string) {
+ _, exists := self.property[name]
+ delete(self.property, name)
+ if exists {
+ for index, property := range self.propertyOrder {
+ if name == property {
+ if index == len(self.propertyOrder)-1 {
+ self.propertyOrder = self.propertyOrder[:index]
+ } else {
+ self.propertyOrder = append(self.propertyOrder[:index], self.propertyOrder[index+1:]...)
+ }
+ }
+ }
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/object_class.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/object_class.go
new file mode 100644
index 000000000..d18b9cede
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/object_class.go
@@ -0,0 +1,493 @@
+package otto
+
+import (
+ "encoding/json"
+)
+
+type _objectClass struct {
+ getOwnProperty func(*_object, string) *_property
+ getProperty func(*_object, string) *_property
+ get func(*_object, string) Value
+ canPut func(*_object, string) bool
+ put func(*_object, string, Value, bool)
+ hasProperty func(*_object, string) bool
+ hasOwnProperty func(*_object, string) bool
+ defineOwnProperty func(*_object, string, _property, bool) bool
+ delete func(*_object, string, bool) bool
+ enumerate func(*_object, bool, func(string) bool)
+ clone func(*_object, *_object, *_clone) *_object
+ marshalJSON func(*_object) json.Marshaler
+}
+
+func objectEnumerate(self *_object, all bool, each func(string) bool) {
+ for _, name := range self.propertyOrder {
+ if all || self.property[name].enumerable() {
+ if !each(name) {
+ return
+ }
+ }
+ }
+}
+
+var (
+ _classObject,
+ _classArray,
+ _classString,
+ _classArguments,
+ _classGoStruct,
+ _classGoMap,
+ _classGoArray,
+ _classGoSlice,
+ _ *_objectClass
+)
+
+func init() {
+ _classObject = &_objectClass{
+ objectGetOwnProperty,
+ objectGetProperty,
+ objectGet,
+ objectCanPut,
+ objectPut,
+ objectHasProperty,
+ objectHasOwnProperty,
+ objectDefineOwnProperty,
+ objectDelete,
+ objectEnumerate,
+ objectClone,
+ nil,
+ }
+
+ _classArray = &_objectClass{
+ objectGetOwnProperty,
+ objectGetProperty,
+ objectGet,
+ objectCanPut,
+ objectPut,
+ objectHasProperty,
+ objectHasOwnProperty,
+ arrayDefineOwnProperty,
+ objectDelete,
+ objectEnumerate,
+ objectClone,
+ nil,
+ }
+
+ _classString = &_objectClass{
+ stringGetOwnProperty,
+ objectGetProperty,
+ objectGet,
+ objectCanPut,
+ objectPut,
+ objectHasProperty,
+ objectHasOwnProperty,
+ objectDefineOwnProperty,
+ objectDelete,
+ stringEnumerate,
+ objectClone,
+ nil,
+ }
+
+ _classArguments = &_objectClass{
+ argumentsGetOwnProperty,
+ objectGetProperty,
+ argumentsGet,
+ objectCanPut,
+ objectPut,
+ objectHasProperty,
+ objectHasOwnProperty,
+ argumentsDefineOwnProperty,
+ argumentsDelete,
+ objectEnumerate,
+ objectClone,
+ nil,
+ }
+
+ _classGoStruct = &_objectClass{
+ goStructGetOwnProperty,
+ objectGetProperty,
+ objectGet,
+ goStructCanPut,
+ goStructPut,
+ objectHasProperty,
+ objectHasOwnProperty,
+ objectDefineOwnProperty,
+ objectDelete,
+ goStructEnumerate,
+ objectClone,
+ goStructMarshalJSON,
+ }
+
+ _classGoMap = &_objectClass{
+ goMapGetOwnProperty,
+ objectGetProperty,
+ objectGet,
+ objectCanPut,
+ objectPut,
+ objectHasProperty,
+ objectHasOwnProperty,
+ goMapDefineOwnProperty,
+ goMapDelete,
+ goMapEnumerate,
+ objectClone,
+ nil,
+ }
+
+ _classGoArray = &_objectClass{
+ goArrayGetOwnProperty,
+ objectGetProperty,
+ objectGet,
+ objectCanPut,
+ objectPut,
+ objectHasProperty,
+ objectHasOwnProperty,
+ goArrayDefineOwnProperty,
+ goArrayDelete,
+ goArrayEnumerate,
+ objectClone,
+ nil,
+ }
+
+ _classGoSlice = &_objectClass{
+ goSliceGetOwnProperty,
+ objectGetProperty,
+ objectGet,
+ objectCanPut,
+ objectPut,
+ objectHasProperty,
+ objectHasOwnProperty,
+ goSliceDefineOwnProperty,
+ goSliceDelete,
+ goSliceEnumerate,
+ objectClone,
+ nil,
+ }
+}
+
+// Allons-y
+
+// 8.12.1
+func objectGetOwnProperty(self *_object, name string) *_property {
+ // Return a _copy_ of the property
+ property, exists := self._read(name)
+ if !exists {
+ return nil
+ }
+ return &property
+}
+
+// 8.12.2
+func objectGetProperty(self *_object, name string) *_property {
+ property := self.getOwnProperty(name)
+ if property != nil {
+ return property
+ }
+ if self.prototype != nil {
+ return self.prototype.getProperty(name)
+ }
+ return nil
+}
+
+// 8.12.3
+func objectGet(self *_object, name string) Value {
+ property := self.getProperty(name)
+ if property != nil {
+ return property.get(self)
+ }
+ return Value{}
+}
+
+// 8.12.4
+func objectCanPut(self *_object, name string) bool {
+ canPut, _, _ := _objectCanPut(self, name)
+ return canPut
+}
+
+func _objectCanPut(self *_object, name string) (canPut bool, property *_property, setter *_object) {
+ property = self.getOwnProperty(name)
+ if property != nil {
+ switch propertyValue := property.value.(type) {
+ case Value:
+ canPut = property.writable()
+ return
+ case _propertyGetSet:
+ setter = propertyValue[1]
+ canPut = setter != nil
+ return
+ default:
+ panic(self.runtime.panicTypeError())
+ }
+ }
+
+ if self.prototype == nil {
+ return self.extensible, nil, nil
+ }
+
+ property = self.prototype.getProperty(name)
+ if property == nil {
+ return self.extensible, nil, nil
+ }
+
+ switch propertyValue := property.value.(type) {
+ case Value:
+ if !self.extensible {
+ return false, nil, nil
+ }
+ return property.writable(), nil, nil
+ case _propertyGetSet:
+ setter = propertyValue[1]
+ canPut = setter != nil
+ return
+ default:
+ panic(self.runtime.panicTypeError())
+ }
+}
+
+// 8.12.5
+func objectPut(self *_object, name string, value Value, throw bool) {
+
+ if true {
+ // Shortcut...
+ //
+ // So, right now, every class is using objectCanPut and every class
+ // is using objectPut.
+ //
+ // If that were to no longer be the case, we would have to have
+ // something to detect that here, so that we do not use an
+ // incompatible canPut routine
+ canPut, property, setter := _objectCanPut(self, name)
+ if !canPut {
+ self.runtime.typeErrorResult(throw)
+ } else if setter != nil {
+ setter.call(toValue(self), []Value{value}, false, nativeFrame)
+ } else if property != nil {
+ property.value = value
+ self.defineOwnProperty(name, *property, throw)
+ } else {
+ self.defineProperty(name, value, 0111, throw)
+ }
+ return
+ }
+
+ // The long way...
+ //
+ // Right now, code should never get here, see above
+ if !self.canPut(name) {
+ self.runtime.typeErrorResult(throw)
+ return
+ }
+
+ property := self.getOwnProperty(name)
+ if property == nil {
+ property = self.getProperty(name)
+ if property != nil {
+ if getSet, isAccessor := property.value.(_propertyGetSet); isAccessor {
+ getSet[1].call(toValue(self), []Value{value}, false, nativeFrame)
+ return
+ }
+ }
+ self.defineProperty(name, value, 0111, throw)
+ } else {
+ switch propertyValue := property.value.(type) {
+ case Value:
+ property.value = value
+ self.defineOwnProperty(name, *property, throw)
+ case _propertyGetSet:
+ if propertyValue[1] != nil {
+ propertyValue[1].call(toValue(self), []Value{value}, false, nativeFrame)
+ return
+ }
+ if throw {
+ panic(self.runtime.panicTypeError())
+ }
+ default:
+ panic(self.runtime.panicTypeError())
+ }
+ }
+}
+
+// 8.12.6
+func objectHasProperty(self *_object, name string) bool {
+ return self.getProperty(name) != nil
+}
+
+func objectHasOwnProperty(self *_object, name string) bool {
+ return self.getOwnProperty(name) != nil
+}
+
+// 8.12.9
+func objectDefineOwnProperty(self *_object, name string, descriptor _property, throw bool) bool {
+ property, exists := self._read(name)
+ {
+ if !exists {
+ if !self.extensible {
+ goto Reject
+ }
+ if newGetSet, isAccessor := descriptor.value.(_propertyGetSet); isAccessor {
+ if newGetSet[0] == &_nilGetSetObject {
+ newGetSet[0] = nil
+ }
+ if newGetSet[1] == &_nilGetSetObject {
+ newGetSet[1] = nil
+ }
+ descriptor.value = newGetSet
+ }
+ self._write(name, descriptor.value, descriptor.mode)
+ return true
+ }
+ if descriptor.isEmpty() {
+ return true
+ }
+
+ // TODO Per 8.12.9.6 - We should shortcut here (returning true) if
+ // the current and new (define) properties are the same
+
+ configurable := property.configurable()
+ if !configurable {
+ if descriptor.configurable() {
+ goto Reject
+ }
+ // Test that, if enumerable is set on the property descriptor, then it should
+ // be the same as the existing property
+ if descriptor.enumerateSet() && descriptor.enumerable() != property.enumerable() {
+ goto Reject
+ }
+ }
+ value, isDataDescriptor := property.value.(Value)
+ getSet, _ := property.value.(_propertyGetSet)
+ if descriptor.isGenericDescriptor() {
+ // GenericDescriptor
+ } else if isDataDescriptor != descriptor.isDataDescriptor() {
+ // DataDescriptor <=> AccessorDescriptor
+ if !configurable {
+ goto Reject
+ }
+ } else if isDataDescriptor && descriptor.isDataDescriptor() {
+ // DataDescriptor <=> DataDescriptor
+ if !configurable {
+ if !property.writable() && descriptor.writable() {
+ goto Reject
+ }
+ if !property.writable() {
+ if descriptor.value != nil && !sameValue(value, descriptor.value.(Value)) {
+ goto Reject
+ }
+ }
+ }
+ } else {
+ // AccessorDescriptor <=> AccessorDescriptor
+ newGetSet, _ := descriptor.value.(_propertyGetSet)
+ presentGet, presentSet := true, true
+ if newGetSet[0] == &_nilGetSetObject {
+ // Present, but nil
+ newGetSet[0] = nil
+ } else if newGetSet[0] == nil {
+ // Missing, not even nil
+ newGetSet[0] = getSet[0]
+ presentGet = false
+ }
+ if newGetSet[1] == &_nilGetSetObject {
+ // Present, but nil
+ newGetSet[1] = nil
+ } else if newGetSet[1] == nil {
+ // Missing, not even nil
+ newGetSet[1] = getSet[1]
+ presentSet = false
+ }
+ if !configurable {
+ if (presentGet && (getSet[0] != newGetSet[0])) || (presentSet && (getSet[1] != newGetSet[1])) {
+ goto Reject
+ }
+ }
+ descriptor.value = newGetSet
+ }
+ {
+ // This section will preserve attributes of
+ // the original property, if necessary
+ value1 := descriptor.value
+ if value1 == nil {
+ value1 = property.value
+ } else if newGetSet, isAccessor := descriptor.value.(_propertyGetSet); isAccessor {
+ if newGetSet[0] == &_nilGetSetObject {
+ newGetSet[0] = nil
+ }
+ if newGetSet[1] == &_nilGetSetObject {
+ newGetSet[1] = nil
+ }
+ value1 = newGetSet
+ }
+ mode1 := descriptor.mode
+ if mode1&0222 != 0 {
+ // TODO Factor this out into somewhere testable
+ // (Maybe put into switch ...)
+ mode0 := property.mode
+ if mode1&0200 != 0 {
+ if descriptor.isDataDescriptor() {
+ mode1 &= ^0200 // Turn off "writable" missing
+ mode1 |= (mode0 & 0100)
+ }
+ }
+ if mode1&020 != 0 {
+ mode1 |= (mode0 & 010)
+ }
+ if mode1&02 != 0 {
+ mode1 |= (mode0 & 01)
+ }
+ mode1 &= 0311 // 0311 to preserve the non-setting on "writable"
+ }
+ self._write(name, value1, mode1)
+ }
+ return true
+ }
+Reject:
+ if throw {
+ panic(self.runtime.panicTypeError())
+ }
+ return false
+}
+
+func objectDelete(self *_object, name string, throw bool) bool {
+ property_ := self.getOwnProperty(name)
+ if property_ == nil {
+ return true
+ }
+ if property_.configurable() {
+ self._delete(name)
+ return true
+ }
+ return self.runtime.typeErrorResult(throw)
+}
+
+func objectClone(in *_object, out *_object, clone *_clone) *_object {
+ *out = *in
+
+ out.runtime = clone.runtime
+ if out.prototype != nil {
+ out.prototype = clone.object(in.prototype)
+ }
+ out.property = make(map[string]_property, len(in.property))
+ out.propertyOrder = make([]string, len(in.propertyOrder))
+ copy(out.propertyOrder, in.propertyOrder)
+ for index, property := range in.property {
+ out.property[index] = clone.property(property)
+ }
+
+ switch value := in.value.(type) {
+ case _nativeFunctionObject:
+ out.value = value
+ case _bindFunctionObject:
+ out.value = _bindFunctionObject{
+ target: clone.object(value.target),
+ this: clone.value(value.this),
+ argumentList: clone.valueArray(value.argumentList),
+ }
+ case _nodeFunctionObject:
+ out.value = _nodeFunctionObject{
+ node: value.node,
+ stash: clone.stash(value.stash),
+ }
+ case _argumentsObject:
+ out.value = value.clone(clone)
+ }
+
+ return out
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/object_test.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/object_test.go
new file mode 100644
index 000000000..d1e90680b
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/object_test.go
@@ -0,0 +1,639 @@
+package otto
+
+import (
+ "testing"
+)
+
+func TestObject_(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ object := newObject(nil, "")
+ is(object != nil, true)
+
+ object.put("xyzzy", toValue("Nothing happens."), true)
+ is(object.get("xyzzy"), "Nothing happens.")
+
+ test(`
+ var abc = Object.getOwnPropertyDescriptor(Object, "prototype");
+ [ [ typeof Object.prototype, abc.writable, abc.enumerable, abc.configurable ],
+ ];
+ `, "object,false,false,false")
+ })
+}
+
+func TestStringObject(t *testing.T) {
+ tt(t, func() {
+ object := New().runtime.newStringObject(toValue("xyzzy"))
+ is(object.get("1"), "y")
+ is(object.get("10"), "undefined")
+ is(object.get("2"), "z")
+ })
+}
+
+func TestObject_getPrototypeOf(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ abc = {};
+ def = Object.getPrototypeOf(abc);
+ ghi = Object.getPrototypeOf(def);
+ [abc,def,ghi,ghi+""];
+ `, "[object Object],[object Object],,null")
+
+ test(`
+ abc = Object.getOwnPropertyDescriptor(Object, "getPrototypeOf");
+ [ abc.value === Object.getPrototypeOf, abc.writable, abc.enumerable, abc.configurable ];
+ `, "true,true,false,true")
+ })
+}
+
+func TestObject_new(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ [ new Object("abc"), new Object(2+2) ];
+ `, "abc,4")
+ })
+}
+
+func TestObject_create(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`raise: Object.create()`, "TypeError")
+
+ test(`
+ var abc = Object.create(null)
+ var def = Object.create({x: 10, y: 20})
+ var ghi = Object.create(Object.prototype)
+
+ var jkl = Object.create({x: 10, y: 20}, {
+ z: {
+ value: 30,
+ writable: true
+ },
+ // sum: {
+ // get: function() {
+ // return this.x + this.y + this.z
+ // }
+ // }
+ });
+ [ abc.prototype, def.x, def.y, ghi, jkl.x, jkl.y, jkl.z ]
+ `, ",10,20,[object Object],10,20,30")
+
+ test(`
+ var properties = {};
+ Object.defineProperty(properties, "abc", {
+ value: {},
+ enumerable: false
+ });
+ var mno = Object.create({}, properties);
+ mno.hasOwnProperty("abc");
+ `, false)
+ })
+}
+
+func TestObject_toLocaleString(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ ({}).toLocaleString();
+ `, "[object Object]")
+
+ test(`
+ object = {
+ toString: function() {
+ return "Nothing happens.";
+ }
+ };
+ object.toLocaleString();
+ `, "Nothing happens.")
+ })
+}
+
+func TestObject_isExtensible(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`raise:
+ Object.isExtensible();
+ `, "TypeError")
+
+ // FIXME terst, Why raise?
+ test(`raise:
+ Object.isExtensible({});
+ `, true)
+
+ test(`Object.isExtensible.length`, 1)
+ test(`Object.isExtensible.prototype`, "undefined")
+ })
+}
+
+func TestObject_preventExtensions(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`raise:
+ Object.preventExtensions()
+ `, "TypeError")
+
+ test(`raise:
+ var abc = { def: true };
+ var ghi = Object.preventExtensions(abc);
+ [ ghi.def === true, Object.isExtensible(abc), Object.isExtensible(ghi) ];
+ `, "true,false,false")
+
+ test(`
+ var abc = new String();
+ var def = Object.isExtensible(abc);
+ Object.preventExtensions(abc);
+ var ghi = false;
+ try {
+ Object.defineProperty(abc, "0", { value: "~" });
+ } catch (err) {
+ ghi = err instanceof TypeError;
+ }
+ [ def, ghi, abc.hasOwnProperty("0"), typeof abc[0] ];
+ `, "true,true,false,undefined")
+
+ test(`Object.preventExtensions.length`, 1)
+ test(`Object.preventExtensions.prototype`, "undefined")
+ })
+}
+
+func TestObject_isSealed(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`Object.isSealed.length`, 1)
+ test(`Object.isSealed.prototype`, "undefined")
+ })
+}
+
+func TestObject_seal(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`raise: Object.seal()`, "TypeError")
+
+ test(`
+ var abc = {a:1,b:1,c:3};
+ var sealed = Object.isSealed(abc);
+ Object.seal(abc);
+ [sealed, Object.isSealed(abc)];
+ `, "false,true")
+
+ test(`
+ var abc = {a:1,b:1,c:3};
+ var sealed = Object.isSealed(abc);
+ var caught = false;
+ Object.seal(abc);
+ abc.b = 5;
+ Object.defineProperty(abc, "a", {value:4});
+ try {
+ Object.defineProperty(abc, "a", {value:42,enumerable:false});
+ } catch (e) {
+ caught = e instanceof TypeError;
+ }
+ [sealed, Object.isSealed(abc), caught, abc.a, abc.b];
+ `, "false,true,true,4,5")
+
+ test(`Object.seal.length`, 1)
+ test(`Object.seal.prototype`, "undefined")
+ })
+}
+
+func TestObject_isFrozen(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`raise: Object.isFrozen()`, "TypeError")
+ test(`Object.isFrozen(Object.preventExtensions({a:1}))`, false)
+ test(`Object.isFrozen({})`, false)
+
+ test(`
+ var abc = {};
+ Object.defineProperty(abc, "def", {
+ value: "def",
+ writable: true,
+ configurable: false
+ });
+ Object.preventExtensions(abc);
+ !Object.isFrozen(abc);
+ `, true)
+
+ test(`Object.isFrozen.length`, 1)
+ test(`Object.isFrozen.prototype`, "undefined")
+ })
+}
+
+func TestObject_freeze(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`raise: Object.freeze()`, "TypeError")
+
+ test(`
+ var abc = {a:1,b:2,c:3};
+ var frozen = Object.isFrozen(abc);
+ Object.freeze(abc);
+ abc.b = 5;
+ [frozen, Object.isFrozen(abc), abc.b];
+ `, "false,true,2")
+
+ test(`
+ var abc = {a:1,b:2,c:3};
+ var frozen = Object.isFrozen(abc);
+ var caught = false;
+ Object.freeze(abc);
+ abc.b = 5;
+ try {
+ Object.defineProperty(abc, "a", {value:4});
+ } catch (e) {
+ caught = e instanceof TypeError;
+ }
+ [frozen, Object.isFrozen(abc), caught, abc.a, abc.b];
+ `, "false,true,true,1,2")
+
+ test(`Object.freeze.length`, 1)
+ test(`Object.freeze.prototype`, "undefined")
+ })
+}
+
+func TestObject_defineProperty(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ (function(abc, def, ghi){
+ Object.defineProperty(arguments, "0", {
+ enumerable: false
+ });
+ return true;
+ })(0, 1, 2);
+ `, true)
+
+ test(`
+ var abc = {};
+ abc.def = 3.14; // Default: writable: true, enumerable: true, configurable: true
+
+ Object.defineProperty(abc, "def", {
+ value: 42
+ });
+
+ var ghi = Object.getOwnPropertyDescriptor(abc, "def");
+ [ ghi.value, ghi.writable, ghi.enumerable, ghi.configurable ];
+ `, "42,true,true,true")
+
+ // Test that we handle the case of DefineOwnProperty
+ // where [[Writable]] is something but [[Value]] is not
+ test(`
+ var abc = [];
+ Object.defineProperty(abc, "0", { writable: false });
+ 0 in abc;
+ `, true)
+
+ // Test that we handle the case of DefineOwnProperty
+ // where [[Writable]] is something but [[Value]] is not
+ // (and the property originally had something for [[Value]]
+ test(`
+ abc = {
+ def: 42
+ };
+ Object.defineProperty(abc, "def", { writable: false });
+ abc.def;
+ `, 42)
+ })
+}
+
+func TestObject_keys(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`Object.keys({ abc:undefined, def:undefined })`, "abc,def")
+
+ test(`
+ function abc() {
+ this.abc = undefined;
+ this.def = undefined;
+ }
+ Object.keys(new abc())
+ `, "abc,def")
+
+ test(`
+ function def() {
+ this.ghi = undefined;
+ }
+ def.prototype = new abc();
+ Object.keys(new def());
+ `, "ghi")
+
+ test(`
+ var ghi = Object.create(
+ {
+ abc: undefined,
+ def: undefined
+ },
+ {
+ ghi: { value: undefined, enumerable: true },
+ jkl: { value: undefined, enumerable: false }
+ }
+ );
+ Object.keys(ghi);
+ `, "ghi")
+
+ test(`
+ (function(abc, def, ghi){
+ return Object.keys(arguments)
+ })(undefined, undefined);
+ `, "0,1")
+
+ test(`
+ (function(abc, def, ghi){
+ return Object.keys(arguments)
+ })(undefined, undefined, undefined, undefined);
+ `, "0,1,2,3")
+ })
+}
+
+func TestObject_getOwnPropertyNames(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`Object.getOwnPropertyNames({ abc:undefined, def:undefined })`, "abc,def")
+
+ test(`
+ var ghi = Object.create(
+ {
+ abc: undefined,
+ def: undefined
+ },
+ {
+ ghi: { value: undefined, enumerable: true },
+ jkl: { value: undefined, enumerable: false }
+ }
+ );
+ Object.getOwnPropertyNames(ghi)
+ `, "ghi,jkl")
+ })
+}
+
+func TestObjectGetterSetter(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`raise:
+ Object.create({}, {
+ abc: {
+ get: function(){
+ return "true";
+ },
+ writable: true
+ }
+ }).abc;
+ `, "TypeError")
+
+ test(`raise:
+ Object.create({}, {
+ abc: {
+ get: function(){
+ return "true";
+ },
+ writable: false
+ }
+ }).abc;
+ `, "TypeError")
+
+ test(`
+ Object.create({}, {
+ abc: {
+ get: function(){
+ return "true";
+ }
+ }
+ }).abc;
+ `, "true")
+
+ test(`
+ Object.create({xyz:true},{abc:{get:function(){return this.xyx}}}).abc;
+ Object.create({
+ xyz: true
+ }, {
+ abc: {
+ get: function(){
+ return this.xyz;
+ }
+ }
+ }).abc;
+ `, true)
+
+ test(`
+ var abc = false;
+ var def = Object.create({}, {
+ xyz: {
+ set: function(value) {
+ abc = value;
+ }
+ }
+ });
+ def.xyz = true;
+ [ abc ];
+ `, "true")
+
+ test(`
+ var abc = {};
+ Object.defineProperty(abc, "def", {
+ value: "xyzzy",
+ configurable: true
+ });
+ Object.preventExtensions(abc);
+ Object.defineProperty(abc, "def", {
+ get: function() {
+ return 5;
+ }
+ });
+ var def = Object.getOwnPropertyDescriptor(abc, "def");
+ [ abc.def, typeof def.get, typeof def.set, typeof def.value, def.configurable, def.enumerable, typeof def.writable ];
+ `, "5,function,undefined,undefined,true,false,undefined")
+
+ test(`
+ var abc = {};
+ Object.defineProperty(abc, "def", {
+ get: function() {
+ return 5;
+ }
+ configurable: true
+ });
+ Object.preventExtensions(abc);
+ Object.defineProperty(abc, "def", {
+ value: "xyzzy",
+ });
+ var def = Object.getOwnPropertyDescriptor(abc, "def");
+ [ abc.def, typeof def.get, typeof def.set, def.value, def.configurable, def.enumerable, def.writable ];
+ `, "xyzzy,undefined,undefined,xyzzy,true,false,false")
+
+ test(`
+ var abc = {};
+
+ function _get0() {
+ return 10;
+ }
+
+ function _set(value) {
+ abc.def = value;
+ }
+
+ Object.defineProperty(abc, "ghi", {
+ get: _get0,
+ set: _set,
+ configurable: true
+ });
+
+ function _get1() {
+ return 20;
+ }
+
+ Object.defineProperty(abc, "ghi", {
+ get: _get0
+ });
+
+ var descriptor = Object.getOwnPropertyDescriptor(abc, "ghi");
+ [ typeof descriptor.set ];
+ `, "function")
+
+ test(`raise:
+ var abc = [];
+ Object.defineProperty(abc, "length", {
+ get: function () {
+ return 2;
+ }
+ });
+ `, "TypeError")
+
+ test(`
+ var abc = {};
+
+ var getter = function() {
+ return 1;
+ }
+
+ Object.defineProperty(abc, "def", {
+ get: getter,
+ configurable: false
+ });
+
+ var jkl = undefined;
+ try {
+ Object.defineProperty(abc, "def", {
+ get: undefined
+ });
+ }
+ catch (err) {
+ jkl = err;
+ }
+ var ghi = Object.getOwnPropertyDescriptor(abc, "def");
+ [ jkl instanceof TypeError, ghi.get === getter, ghi.configurable, ghi.enumerable ];
+ `, "true,true,false,false")
+
+ test(`
+ var abc = {};
+
+ var getter = function() {
+ return 1;
+ };
+
+ Object.defineProperty(abc, "def", {
+ get: getter
+ });
+
+ Object.defineProperty(abc, "def", {
+ set: undefined
+ });
+
+ var ghi = Object.getOwnPropertyDescriptor(abc, "def");
+ [ ghi.get === getter, ghi.set === undefined, ghi.configurable, ghi.enumerable ];
+ `, "true,true,false,false")
+
+ test(`
+ var abc = {};
+
+ var getter = function() {
+ return 1;
+ };
+
+ Object.defineProperty(abc, "def", {
+ get: getter
+ });
+
+ var jkl = undefined;
+ try {
+ Object.defineProperty(abc, "def", {
+ set: function() {}
+ });
+ }
+ catch (err) {
+ jkl = err;
+ }
+
+ var ghi = Object.getOwnPropertyDescriptor(abc, "def");
+ [ jkl instanceof TypeError, ghi.get === getter, ghi.set, ghi.configurable, ghi.enumerable ];
+ `, "true,true,,false,false")
+
+ test(`
+ var abc = {};
+ var def = "xyzzy";
+
+ Object.defineProperty(abc, "ghi", {
+ get: undefined,
+ set: function(value) {
+ def = value;
+ },
+ enumerable: true,
+ configurable: true
+ });
+
+ var hasOwn = abc.hasOwnProperty("ghi");
+ var descriptor = Object.getOwnPropertyDescriptor(abc, "ghi");
+
+ [ hasOwn, typeof descriptor.get ];
+ `, "true,undefined")
+
+ test(`
+ var abc = "xyzzy";
+ Object.defineProperty(Array.prototype, "abc", {
+ get: function () {
+ return abc;
+ },
+ set: function (value) {
+ abc = value;
+ },
+ enumerable: true,
+ configurable: true
+ });
+ var def = [];
+ def.abc = 3.14159;
+ [ def.hasOwnProperty("abc"), def.abc, abc ];
+ `, "false,3.14159,3.14159")
+ })
+}
+
+func TestProperty(t *testing.T) {
+ tt(t, func() {
+ property := _property{}
+ property.writeOn()
+ is(property.writeSet(), true)
+
+ property.writeClear()
+ is(property.writeSet(), false)
+
+ property.writeOff()
+ is(property.writeSet(), true)
+
+ property.writeClear()
+ is(property.writeSet(), false)
+ })
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/otto.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/otto.go
new file mode 100644
index 000000000..9de3e08c5
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/otto.go
@@ -0,0 +1,578 @@
+/*
+Package otto is a JavaScript parser and interpreter written natively in Go.
+
+http://godoc.org/github.com/robertkrimen/otto
+
+ import (
+ "github.com/robertkrimen/otto"
+ )
+
+Run something in the VM
+
+ vm := otto.New()
+ vm.Run(`
+ abc = 2 + 2;
+ console.log("The value of abc is " + abc); // 4
+ `)
+
+Get a value out of the VM
+
+ value, err := vm.Get("abc")
+ value, _ := value.ToInteger()
+ }
+
+Set a number
+
+ vm.Set("def", 11)
+ vm.Run(`
+ console.log("The value of def is " + def);
+ // The value of def is 11
+ `)
+
+Set a string
+
+ vm.Set("xyzzy", "Nothing happens.")
+ vm.Run(`
+ console.log(xyzzy.length); // 16
+ `)
+
+Get the value of an expression
+
+ value, _ = vm.Run("xyzzy.length")
+ {
+ // value is an int64 with a value of 16
+ value, _ := value.ToInteger()
+ }
+
+An error happens
+
+ value, err = vm.Run("abcdefghijlmnopqrstuvwxyz.length")
+ if err != nil {
+ // err = ReferenceError: abcdefghijlmnopqrstuvwxyz is not defined
+ // If there is an error, then value.IsUndefined() is true
+ ...
+ }
+
+Set a Go function
+
+ vm.Set("sayHello", func(call otto.FunctionCall) otto.Value {
+ fmt.Printf("Hello, %s.\n", call.Argument(0).String())
+ return otto.Value{}
+ })
+
+Set a Go function that returns something useful
+
+ vm.Set("twoPlus", func(call otto.FunctionCall) otto.Value {
+ right, _ := call.Argument(0).ToInteger()
+ result, _ := vm.ToValue(2 + right)
+ return result
+ })
+
+Use the functions in JavaScript
+
+ result, _ = vm.Run(`
+ sayHello("Xyzzy"); // Hello, Xyzzy.
+ sayHello(); // Hello, undefined
+
+ result = twoPlus(2.0); // 4
+ `)
+
+Parser
+
+A separate parser is available in the parser package if you're just interested in building an AST.
+
+http://godoc.org/github.com/robertkrimen/otto/parser
+
+Parse and return an AST
+
+ filename := "" // A filename is optional
+ src := `
+ // Sample xyzzy example
+ (function(){
+ if (3.14159 > 0) {
+ console.log("Hello, World.");
+ return;
+ }
+
+ var xyzzy = NaN;
+ console.log("Nothing happens.");
+ return xyzzy;
+ })();
+ `
+
+ // Parse some JavaScript, yielding a *ast.Program and/or an ErrorList
+ program, err := parser.ParseFile(nil, filename, src, 0)
+
+otto
+
+You can run (Go) JavaScript from the commandline with: http://github.com/robertkrimen/otto/tree/master/otto
+
+ $ go get -v github.com/robertkrimen/otto/otto
+
+Run JavaScript by entering some source on stdin or by giving otto a filename:
+
+ $ otto example.js
+
+underscore
+
+Optionally include the JavaScript utility-belt library, underscore, with this import:
+
+ import (
+ "github.com/robertkrimen/otto"
+ _ "github.com/robertkrimen/otto/underscore"
+ )
+
+ // Now every otto runtime will come loaded with underscore
+
+For more information: http://github.com/robertkrimen/otto/tree/master/underscore
+
+Caveat Emptor
+
+The following are some limitations with otto:
+
+ * "use strict" will parse, but does nothing.
+ * The regular expression engine (re2/regexp) is not fully compatible with the ECMA5 specification.
+
+Regular Expression Incompatibility
+
+Go translates JavaScript-style regular expressions into something that is "regexp" compatible via `parser.TransformRegExp`.
+Unfortunately, RegExp requires backtracking for some patterns, and backtracking is not supported by the standard Go engine: https://code.google.com/p/re2/wiki/Syntax
+
+Therefore, the following syntax is incompatible:
+
+ (?=) // Lookahead (positive), currently a parsing error
+ (?!) // Lookahead (backhead), currently a parsing error
+ \1 // Backreference (\1, \2, \3, ...), currently a parsing error
+
+A brief discussion of these limitations: "Regexp (?!re)" https://groups.google.com/forum/?fromgroups=#%21topic/golang-nuts/7qgSDWPIh_E
+
+More information about re2: https://code.google.com/p/re2/
+
+In addition to the above, re2 (Go) has a different definition for \s: [\t\n\f\r ].
+The JavaScript definition, on the other hand, also includes \v, Unicode "Separator, Space", etc.
+
+Halting Problem
+
+If you want to stop long running executions (like third-party code), you can use the interrupt channel to do this:
+
+ package main
+
+ import (
+ "errors"
+ "fmt"
+ "os"
+ "time"
+
+ "github.com/robertkrimen/otto"
+ )
+
+ var halt = errors.New("Stahp")
+
+ func main() {
+ runUnsafe(`var abc = [];`)
+ runUnsafe(`
+ while (true) {
+ // Loop forever
+ }`)
+ }
+
+ func runUnsafe(unsafe string) {
+ start := time.Now()
+ defer func() {
+ duration := time.Since(start)
+ if caught := recover(); caught != nil {
+ if caught == halt {
+ fmt.Fprintf(os.Stderr, "Some code took to long! Stopping after: %v\n", duration)
+ return
+ }
+ panic(caught) // Something else happened, repanic!
+ }
+ fmt.Fprintf(os.Stderr, "Ran code successfully: %v\n", duration)
+ }()
+
+ vm := otto.New()
+ vm.Interrupt = make(chan func(), 1) // The buffer prevents blocking
+
+ go func() {
+ time.Sleep(2 * time.Second) // Stop after two seconds
+ vm.Interrupt <- func() {
+ panic(halt)
+ }
+ }()
+
+ vm.Run(unsafe) // Here be dragons (risky code)
+ }
+
+Where is setTimeout/setInterval?
+
+These timing functions are not actually part of the ECMA-262 specification. Typically, they belong to the `windows` object (in the browser).
+It would not be difficult to provide something like these via Go, but you probably want to wrap otto in an event loop in that case.
+
+For an example of how this could be done in Go with otto, see natto:
+
+http://github.com/robertkrimen/natto
+
+Here is some more discussion of the issue:
+
+* http://book.mixu.net/node/ch2.html
+
+* http://en.wikipedia.org/wiki/Reentrancy_%28computing%29
+
+* http://aaroncrane.co.uk/2009/02/perl_safe_signals/
+
+*/
+package otto
+
+import (
+ "fmt"
+ "strings"
+
+ "github.com/robertkrimen/otto/registry"
+)
+
+// Otto is the representation of the JavaScript runtime. Each instance of Otto has a self-contained namespace.
+type Otto struct {
+ // Interrupt is a channel for interrupting the runtime. You can use this to halt a long running execution, for example.
+ // See "Halting Problem" for more information.
+ Interrupt chan func()
+ runtime *_runtime
+}
+
+// New will allocate a new JavaScript runtime
+func New() *Otto {
+ self := &Otto{
+ runtime: newContext(),
+ }
+ self.runtime.otto = self
+ self.Set("console", self.runtime.newConsole())
+
+ registry.Apply(func(entry registry.Entry) {
+ self.Run(entry.Source())
+ })
+
+ return self
+}
+
+func (otto *Otto) clone() *Otto {
+ self := &Otto{
+ runtime: otto.runtime.clone(),
+ }
+ self.runtime.otto = self
+ return self
+}
+
+// Run will allocate a new JavaScript runtime, run the given source
+// on the allocated runtime, and return the runtime, resulting value, and
+// error (if any).
+//
+// src may be a string, a byte slice, a bytes.Buffer, or an io.Reader, but it MUST always be in UTF-8.
+//
+// src may also be a Script.
+//
+// src may also be a Program, but if the AST has been modified, then runtime behavior is undefined.
+//
+func Run(src interface{}) (*Otto, Value, error) {
+ otto := New()
+ value, err := otto.Run(src) // This already does safety checking
+ return otto, value, err
+}
+
+// Run will run the given source (parsing it first if necessary), returning the resulting value and error (if any)
+//
+// src may be a string, a byte slice, a bytes.Buffer, or an io.Reader, but it MUST always be in UTF-8.
+//
+// If the runtime is unable to parse source, then this function will return undefined and the parse error (nothing
+// will be evaluated in this case).
+//
+// src may also be a Script.
+//
+// src may also be a Program, but if the AST has been modified, then runtime behavior is undefined.
+//
+func (self Otto) Run(src interface{}) (Value, error) {
+ value, err := self.runtime.cmpl_run(src)
+ if !value.safe() {
+ value = Value{}
+ }
+ return value, err
+}
+
+// Get the value of the top-level binding of the given name.
+//
+// If there is an error (like the binding does not exist), then the value
+// will be undefined.
+func (self Otto) Get(name string) (Value, error) {
+ value := Value{}
+ err := catchPanic(func() {
+ value = self.getValue(name)
+ })
+ if !value.safe() {
+ value = Value{}
+ }
+ return value, err
+}
+
+func (self Otto) getValue(name string) Value {
+ return self.runtime.globalStash.getBinding(name, false)
+}
+
+// Set the top-level binding of the given name to the given value.
+//
+// Set will automatically apply ToValue to the given value in order
+// to convert it to a JavaScript value (type Value).
+//
+// If there is an error (like the binding is read-only, or the ToValue conversion
+// fails), then an error is returned.
+//
+// If the top-level binding does not exist, it will be created.
+func (self Otto) Set(name string, value interface{}) error {
+ {
+ value, err := self.ToValue(value)
+ if err != nil {
+ return err
+ }
+ err = catchPanic(func() {
+ self.setValue(name, value)
+ })
+ return err
+ }
+}
+
+func (self Otto) setValue(name string, value Value) {
+ self.runtime.globalStash.setValue(name, value, false)
+}
+
+// Call the given JavaScript with a given this and arguments.
+//
+// If this is nil, then some special handling takes place to determine the proper
+// this value, falling back to a "standard" invocation if necessary (where this is
+// undefined).
+//
+// If source begins with "new " (A lowercase new followed by a space), then
+// Call will invoke the function constructor rather than performing a function call.
+// In this case, the this argument has no effect.
+//
+// // value is a String object
+// value, _ := vm.Call("Object", nil, "Hello, World.")
+//
+// // Likewise...
+// value, _ := vm.Call("new Object", nil, "Hello, World.")
+//
+// // This will perform a concat on the given array and return the result
+// // value is [ 1, 2, 3, undefined, 4, 5, 6, 7, "abc" ]
+// value, _ := vm.Call(`[ 1, 2, 3, undefined, 4 ].concat`, nil, 5, 6, 7, "abc")
+//
+func (self Otto) Call(source string, this interface{}, argumentList ...interface{}) (Value, error) {
+
+ thisValue := Value{}
+
+ construct := false
+ if strings.HasPrefix(source, "new ") {
+ source = source[4:]
+ construct = true
+ }
+
+ // FIXME enterGlobalScope
+ self.runtime.enterGlobalScope()
+ defer func() {
+ self.runtime.leaveScope()
+ }()
+
+ if !construct && this == nil {
+ program, err := self.runtime.cmpl_parse("", source+"()")
+ if err == nil {
+ if node, ok := program.body[0].(*_nodeExpressionStatement); ok {
+ if node, ok := node.expression.(*_nodeCallExpression); ok {
+ var value Value
+ err := catchPanic(func() {
+ value = self.runtime.cmpl_evaluate_nodeCallExpression(node, argumentList)
+ })
+ if err != nil {
+ return Value{}, err
+ }
+ return value, nil
+ }
+ }
+ }
+ } else {
+ value, err := self.ToValue(this)
+ if err != nil {
+ return Value{}, err
+ }
+ thisValue = value
+ }
+
+ {
+ this := thisValue
+
+ fn, err := self.Run(source)
+ if err != nil {
+ return Value{}, err
+ }
+
+ if construct {
+ result, err := fn.constructSafe(self.runtime, this, argumentList...)
+ if err != nil {
+ return Value{}, err
+ }
+ return result, nil
+ }
+
+ result, err := fn.Call(this, argumentList...)
+ if err != nil {
+ return Value{}, err
+ }
+ return result, nil
+ }
+}
+
+// Object will run the given source and return the result as an object.
+//
+// For example, accessing an existing object:
+//
+// object, _ := vm.Object(`Number`)
+//
+// Or, creating a new object:
+//
+// object, _ := vm.Object(`({ xyzzy: "Nothing happens." })`)
+//
+// Or, creating and assigning an object:
+//
+// object, _ := vm.Object(`xyzzy = {}`)
+// object.Set("volume", 11)
+//
+// If there is an error (like the source does not result in an object), then
+// nil and an error is returned.
+func (self Otto) Object(source string) (*Object, error) {
+ value, err := self.runtime.cmpl_run(source)
+ if err != nil {
+ return nil, err
+ }
+ if value.IsObject() {
+ return value.Object(), nil
+ }
+ return nil, fmt.Errorf("value is not an object")
+}
+
+// ToValue will convert an interface{} value to a value digestible by otto/JavaScript.
+func (self Otto) ToValue(value interface{}) (Value, error) {
+ return self.runtime.safeToValue(value)
+}
+
+// Copy will create a copy/clone of the runtime.
+//
+// Copy is useful for saving some time when creating many similar runtimes.
+//
+// This method works by walking the original runtime and cloning each object, scope, stash,
+// etc. into a new runtime.
+//
+// Be on the lookout for memory leaks or inadvertent sharing of resources.
+func (in *Otto) Copy() *Otto {
+ out := &Otto{
+ runtime: in.runtime.clone(),
+ }
+ out.runtime.otto = out
+ return out
+}
+
+// Object{}
+
+// Object is the representation of a JavaScript object.
+type Object struct {
+ object *_object
+ value Value
+}
+
+func _newObject(object *_object, value Value) *Object {
+ // value MUST contain object!
+ return &Object{
+ object: object,
+ value: value,
+ }
+}
+
+// Call a method on the object.
+//
+// It is essentially equivalent to:
+//
+// var method, _ := object.Get(name)
+// method.Call(object, argumentList...)
+//
+// An undefined value and an error will result if:
+//
+// 1. There is an error during conversion of the argument list
+// 2. The property is not actually a function
+// 3. An (uncaught) exception is thrown
+//
+func (self Object) Call(name string, argumentList ...interface{}) (Value, error) {
+ // TODO: Insert an example using JavaScript below...
+ // e.g., Object("JSON").Call("stringify", ...)
+
+ function, err := self.Get(name)
+ if err != nil {
+ return Value{}, err
+ }
+ return function.Call(self.Value(), argumentList...)
+}
+
+// Value will return self as a value.
+func (self Object) Value() Value {
+ return self.value
+}
+
+// Get the value of the property with the given name.
+func (self Object) Get(name string) (Value, error) {
+ value := Value{}
+ err := catchPanic(func() {
+ value = self.object.get(name)
+ })
+ if !value.safe() {
+ value = Value{}
+ }
+ return value, err
+}
+
+// Set the property of the given name to the given value.
+//
+// An error will result if the setting the property triggers an exception (i.e. read-only),
+// or there is an error during conversion of the given value.
+func (self Object) Set(name string, value interface{}) error {
+ {
+ value, err := self.object.runtime.safeToValue(value)
+ if err != nil {
+ return err
+ }
+ err = catchPanic(func() {
+ self.object.put(name, value, true)
+ })
+ return err
+ }
+}
+
+// Get the keys for the object
+//
+// Equivalent to calling Object.keys on the object
+func (self Object) Keys() []string {
+ var keys []string
+ self.object.enumerate(false, func(name string) bool {
+ keys = append(keys, name)
+ return true
+ })
+ return keys
+}
+
+// Class will return the class string of the object.
+//
+// The return value will (generally) be one of:
+//
+// Object
+// Function
+// Array
+// String
+// Number
+// Boolean
+// Date
+// RegExp
+//
+func (self Object) Class() string {
+ return self.object.class
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/otto/Makefile b/Godeps/_workspace/src/github.com/robertkrimen/otto/otto/Makefile
new file mode 100644
index 000000000..bac5cd4a5
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/otto/Makefile
@@ -0,0 +1,5 @@
+.PHONY: build
+
+build:
+ go build -a
+ -gxc build-darwin-386 -a
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/otto/main.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/otto/main.go
new file mode 100644
index 000000000..f379e42a9
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/otto/main.go
@@ -0,0 +1,48 @@
+package main
+
+import (
+ "flag"
+ "fmt"
+ "io/ioutil"
+ "os"
+
+ "github.com/robertkrimen/otto"
+ "github.com/robertkrimen/otto/underscore"
+)
+
+var flag_underscore *bool = flag.Bool("underscore", true, "Load underscore into the runtime environment")
+
+func readSource(filename string) ([]byte, error) {
+ if filename == "" || filename == "-" {
+ return ioutil.ReadAll(os.Stdin)
+ }
+ return ioutil.ReadFile(filename)
+}
+
+func main() {
+ flag.Parse()
+
+ if !*flag_underscore {
+ underscore.Disable()
+ }
+
+ err := func() error {
+ src, err := readSource(flag.Arg(0))
+ if err != nil {
+ return err
+ }
+
+ vm := otto.New()
+ _, err = vm.Run(src)
+ return err
+ }()
+ if err != nil {
+ switch err := err.(type) {
+ case *otto.Error:
+ fmt.Print(err.String())
+ default:
+ fmt.Println(err)
+ }
+ os.Exit(64)
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/otto_.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/otto_.go
new file mode 100644
index 000000000..e053b54e2
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/otto_.go
@@ -0,0 +1,178 @@
+package otto
+
+import (
+ "fmt"
+ "regexp"
+ runtime_ "runtime"
+ "strconv"
+ "strings"
+)
+
+var isIdentifier_Regexp *regexp.Regexp = regexp.MustCompile(`^[a-zA-Z\$][a-zA-Z0-9\$]*$`)
+
+func isIdentifier(string_ string) bool {
+ return isIdentifier_Regexp.MatchString(string_)
+}
+
+func (self *_runtime) toValueArray(arguments ...interface{}) []Value {
+ length := len(arguments)
+ if length == 1 {
+ if valueArray, ok := arguments[0].([]Value); ok {
+ return valueArray
+ }
+ return []Value{toValue(arguments[0])}
+ }
+
+ valueArray := make([]Value, length)
+ for index, value := range arguments {
+ valueArray[index] = toValue(value)
+ }
+
+ return valueArray
+}
+
+func stringToArrayIndex(name string) int64 {
+ index, err := strconv.ParseInt(name, 10, 64)
+ if err != nil {
+ return -1
+ }
+ if index < 0 {
+ return -1
+ }
+ if index >= maxUint32 {
+ // The value 2^32 (or above) is not a valid index because
+ // you cannot store a uint32 length for an index of uint32
+ return -1
+ }
+ return index
+}
+
+func isUint32(value int64) bool {
+ return value >= 0 && value <= maxUint32
+}
+
+func arrayIndexToString(index int64) string {
+ return strconv.FormatInt(index, 10)
+}
+
+func valueOfArrayIndex(array []Value, index int) Value {
+ value, _ := getValueOfArrayIndex(array, index)
+ return value
+}
+
+func getValueOfArrayIndex(array []Value, index int) (Value, bool) {
+ if index >= 0 && index < len(array) {
+ value := array[index]
+ if !value.isEmpty() {
+ return value, true
+ }
+ }
+ return Value{}, false
+}
+
+// A range index can be anything from 0 up to length. It is NOT safe to use as an index
+// to an array, but is useful for slicing and in some ECMA algorithms.
+func valueToRangeIndex(indexValue Value, length int64, negativeIsZero bool) int64 {
+ index := indexValue.number().int64
+ if negativeIsZero {
+ if index < 0 {
+ index = 0
+ }
+ // minimum(index, length)
+ if index >= length {
+ index = length
+ }
+ return index
+ }
+
+ if index < 0 {
+ index += length
+ if index < 0 {
+ index = 0
+ }
+ } else {
+ if index > length {
+ index = length
+ }
+ }
+ return index
+}
+
+func rangeStartEnd(array []Value, size int64, negativeIsZero bool) (start, end int64) {
+ start = valueToRangeIndex(valueOfArrayIndex(array, 0), size, negativeIsZero)
+ if len(array) == 1 {
+ // If there is only the start argument, then end = size
+ end = size
+ return
+ }
+
+ // Assuming the argument is undefined...
+ end = size
+ endValue := valueOfArrayIndex(array, 1)
+ if !endValue.IsUndefined() {
+ // Which it is not, so get the value as an array index
+ end = valueToRangeIndex(endValue, size, negativeIsZero)
+ }
+ return
+}
+
+func rangeStartLength(source []Value, size int64) (start, length int64) {
+ start = valueToRangeIndex(valueOfArrayIndex(source, 0), size, false)
+
+ // Assume the second argument is missing or undefined
+ length = int64(size)
+ if len(source) == 1 {
+ // If there is only the start argument, then length = size
+ return
+ }
+
+ lengthValue := valueOfArrayIndex(source, 1)
+ if !lengthValue.IsUndefined() {
+ // Which it is not, so get the value as an array index
+ length = lengthValue.number().int64
+ }
+ return
+}
+
+func boolFields(input string) (result map[string]bool) {
+ result = map[string]bool{}
+ for _, word := range strings.Fields(input) {
+ result[word] = true
+ }
+ return result
+}
+
+func hereBeDragons(arguments ...interface{}) string {
+ pc, _, _, _ := runtime_.Caller(1)
+ name := runtime_.FuncForPC(pc).Name()
+ message := fmt.Sprintf("Here be dragons -- %s", name)
+ if len(arguments) > 0 {
+ message += ": "
+ argument0 := fmt.Sprintf("%s", arguments[0])
+ if len(arguments) == 1 {
+ message += argument0
+ } else {
+ message += fmt.Sprintf(argument0, arguments[1:]...)
+ }
+ } else {
+ message += "."
+ }
+ return message
+}
+
+func throwHereBeDragons(arguments ...interface{}) {
+ panic(hereBeDragons(arguments...))
+}
+
+func eachPair(list []interface{}, fn func(_0, _1 interface{})) {
+ for len(list) > 0 {
+ var _0, _1 interface{}
+ _0 = list[0]
+ list = list[1:] // Pop off first
+ if len(list) > 0 {
+ _1 = list[0]
+ list = list[1:] // Pop off second
+ }
+ fn(_0, _1)
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/otto_error_test.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/otto_error_test.go
new file mode 100644
index 000000000..5ce358819
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/otto_error_test.go
@@ -0,0 +1,48 @@
+package otto
+
+import (
+ "testing"
+)
+
+func TestOttoError(t *testing.T) {
+ tt(t, func() {
+ vm := New()
+
+ _, err := vm.Run(`throw "Xyzzy"`)
+ is(err, "Xyzzy")
+
+ _, err = vm.Run(`throw new TypeError()`)
+ is(err, "TypeError")
+
+ _, err = vm.Run(`throw new TypeError("Nothing happens.")`)
+ is(err, "TypeError: Nothing happens.")
+
+ _, err = ToValue([]byte{})
+ is(err, "TypeError: invalid value (slice): missing runtime: [] ([]uint8)")
+
+ _, err = vm.Run(`
+ (function(){
+ return abcdef.length
+ })()
+ `)
+ is(err, "ReferenceError: 'abcdef' is not defined")
+
+ _, err = vm.Run(`
+ function start() {
+ }
+
+ start()
+
+ xyzzy()
+ `)
+ is(err, "ReferenceError: 'xyzzy' is not defined")
+
+ _, err = vm.Run(`
+ // Just a comment
+
+ xyzzy
+ `)
+ is(err, "ReferenceError: 'xyzzy' is not defined")
+
+ })
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/otto_test.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/otto_test.go
new file mode 100644
index 000000000..2f1e1c35f
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/otto_test.go
@@ -0,0 +1,1379 @@
+package otto
+
+import (
+ "bytes"
+ "io"
+ "testing"
+
+ "github.com/robertkrimen/otto/parser"
+)
+
+func TestOtto(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test("xyzzy = 2", 2)
+
+ test("xyzzy + 2", 4)
+
+ test("xyzzy += 16", 18)
+
+ test("xyzzy", 18)
+
+ test(`
+ (function(){
+ return 1
+ })()
+ `, 1)
+
+ test(`
+ (function(){
+ return 1
+ }).call(this)
+ `, 1)
+
+ test(`
+ (function(){
+ var result
+ (function(){
+ result = -1
+ })()
+ return result
+ })()
+ `, -1)
+
+ test(`
+ var abc = 1
+ abc || (abc = -1)
+ abc
+ `, 1)
+
+ test(`
+ var abc = (function(){ 1 === 1 })();
+ abc;
+ `, "undefined")
+ })
+}
+
+func TestFunction__(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ function abc() {
+ return 1;
+ };
+ abc();
+ `, 1)
+ })
+}
+
+func TestIf(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ abc = undefined;
+ def = undefined;
+ if (true) abc = 1
+ else abc = 2;
+ if (false) {
+ def = 3;
+ }
+ else def = 4;
+
+ [ abc, def ];
+ `, "1,4")
+
+ test(`
+ if (1) {
+ abc = 1;
+ }
+ else {
+ abc = 0;
+ }
+ abc;
+ `, 1)
+
+ test(`
+ if (0) {
+ abc = 1;
+ }
+ else {
+ abc = 0;
+ }
+ abc;
+ `, 0)
+
+ test(`
+ abc = 0;
+ if (0) {
+ abc = 1;
+ }
+ abc;
+ `, 0)
+
+ test(`
+ abc = 0;
+ if (abc) {
+ abc = 1;
+ }
+ abc;
+ `, 0)
+ })
+}
+
+func TestSequence(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ 1, 2, 3;
+ `, 3)
+ })
+}
+
+func TestCall(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ Math.pow(3, 2);
+ `, 9)
+ })
+}
+
+func TestMember(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ abc = [ 0, 1, 2 ];
+ def = {
+ "abc": 0,
+ "def": 1,
+ "ghi": 2,
+ };
+ [ abc[2], def.abc, abc[1], def.def ];
+ `, "2,0,1,1")
+ })
+}
+
+func Test_this(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ typeof this;
+ `, "object")
+ })
+}
+
+func TestWhile(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ limit = 4
+ abc = 0
+ while (limit) {
+ abc = abc + 1
+ limit = limit - 1
+ }
+ abc;
+ `, 4)
+ })
+}
+
+func TestSwitch_break(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ var abc = true;
+ var ghi = "Xyzzy";
+ while (abc) {
+ switch ('def') {
+ case 'def':
+ break;
+ }
+ ghi = "Nothing happens.";
+ abc = false;
+ }
+ ghi;
+ `, "Nothing happens.")
+
+ test(`
+ var abc = true;
+ var ghi = "Xyzzy";
+ WHILE:
+ while (abc) {
+ switch ('def') {
+ case 'def':
+ break WHILE;
+ }
+ ghi = "Nothing happens."
+ abc = false
+ }
+ ghi;
+ `, "Xyzzy")
+
+ test(`
+ var ghi = "Xyzzy";
+ FOR:
+ for (;;) {
+ switch ('def') {
+ case 'def':
+ break FOR;
+ ghi = "";
+ }
+ ghi = "Nothing happens.";
+ }
+ ghi;
+ `, "Xyzzy")
+
+ test(`
+ var ghi = "Xyzzy";
+ FOR:
+ for (var jkl in {}) {
+ switch ('def') {
+ case 'def':
+ break FOR;
+ ghi = "Something happens.";
+ }
+ ghi = "Nothing happens.";
+ }
+ ghi;
+ `, "Xyzzy")
+
+ test(`
+ var ghi = "Xyzzy";
+ function jkl() {
+ switch ('def') {
+ case 'def':
+ break;
+ ghi = "";
+ }
+ ghi = "Nothing happens.";
+ }
+ while (abc) {
+ jkl();
+ abc = false;
+ ghi = "Something happens.";
+ }
+ ghi;
+ `, "Something happens.")
+ })
+}
+
+func TestTryFinally(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ var abc;
+ try {
+ abc = 1;
+ }
+ finally {
+ abc = 2;
+ }
+ abc;
+ `, 2)
+
+ test(`
+ var abc = false, def = 0;
+ do {
+ def += 1;
+ if (def > 100) {
+ break;
+ }
+ try {
+ continue;
+ }
+ finally {
+ abc = true;
+ }
+ }
+ while(!abc && def < 10)
+ def;
+ `, 1)
+
+ test(`
+ var abc = false, def = 0, ghi = 0;
+ do {
+ def += 1;
+ if (def > 100) {
+ break;
+ }
+ try {
+ throw 0;
+ }
+ catch (jkl) {
+ continue;
+ }
+ finally {
+ abc = true;
+ ghi = 11;
+ }
+ ghi -= 1;
+ }
+ while(!abc && def < 10)
+ ghi;
+ `, 11)
+
+ test(`
+ var abc = 0, def = 0;
+ do {
+ try {
+ abc += 1;
+ throw "ghi";
+ }
+ finally {
+ def = 1;
+ continue;
+ }
+ def -= 1;
+ }
+ while (abc < 2)
+ [ abc, def ];
+ `, "2,1")
+ })
+}
+
+func TestTryCatch(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ var abc = 1;
+ try {
+ throw 4;
+ abc = -1;
+ }
+ catch (xyzzy) {
+ abc += xyzzy + 1;
+ }
+ abc;
+ `, 6)
+
+ test(`
+ abc = 1;
+ var def;
+ try {
+ try {
+ throw 4;
+ abc = -1;
+ }
+ catch (xyzzy) {
+ abc += xyzzy + 1;
+ throw 64;
+ }
+ }
+ catch (xyzzy) {
+ def = xyzzy;
+ abc = -2;
+ }
+ [ def, abc ];
+ `, "64,-2")
+ })
+}
+
+func TestWith(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ var def;
+ with({ abc: 9 }) {
+ def = abc;
+ }
+ def;
+ `, 9)
+
+ test(`
+ var def;
+ with({ abc: function(){
+ return 11;
+ } }) {
+ def = abc();
+ }
+ def;
+ `, 11)
+ })
+}
+
+func TestSwitch(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ var abc = 0;
+ switch (0) {
+ default:
+ abc += 1;
+ case 1:
+ abc += 2;
+ case 2:
+ abc += 4;
+ case 3:
+ abc += 8;
+ }
+ abc;
+ `, 15)
+
+ test(`
+ abc = 0;
+ switch (3) {
+ default:
+ abc += 1;
+ case 1:
+ abc += 2;
+ case 2:
+ abc += 4;
+ case 3:
+ abc += 8;
+ }
+ abc;
+ `, 8)
+
+ test(`
+ abc = 0;
+ switch (60) {
+ case 1:
+ abc += 2;
+ case 2:
+ abc += 4;
+ case 3:
+ abc += 8;
+ }
+ abc;
+ `, 0)
+ })
+}
+
+func TestForIn(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ var abc;
+ for (property in { a: 1 }) {
+ abc = property;
+ }
+ abc;
+ `, "a")
+
+ test(`
+ var ghi;
+ for (property in new String("xyzzy")) {
+ ghi = property;
+ }
+ ghi;
+ `, "4")
+ })
+}
+
+func TestFor(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ var abc = 7;
+ for (i = 0; i < 3; i += 1) {
+ abc += 1;
+ }
+ abc;
+ `, 10)
+
+ test(`
+ abc = 7;
+ for (i = 0; i < 3; i += 1) {
+ abc += 1;
+ if (i == 1) {
+ break;
+ }
+ }
+ abc;
+ `, 9)
+
+ test(`
+ abc = 7;
+ for (i = 0; i < 3; i += 1) {
+ if (i == 2) {
+ continue;
+ }
+ abc += 1;
+ }
+ abc;
+ `, 9)
+
+ test(`
+ abc = 0;
+ for (;;) {
+ abc += 1;
+ if (abc == 3)
+ break;
+ }
+ abc;
+ `, 3)
+
+ test(`
+ for (abc = 0; ;) {
+ abc += 1;
+ if (abc == 3)
+ break;
+ }
+ abc;
+ `, 3)
+
+ test(`
+ for (abc = 0; ; abc += 1) {
+ abc += 1;
+ if (abc == 3)
+ break;
+ }
+ abc;
+ `, 3)
+ })
+}
+
+func TestLabelled(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ // TODO Add emergency break
+
+ test(`
+ xyzzy: for (var abc = 0; abc <= 0; abc++) {
+ for (var def = 0; def <= 1; def++) {
+ if (def === 0) {
+ continue xyzzy;
+ } else {
+ }
+ }
+ }
+ `)
+
+ test(`
+ abc = 0
+ def:
+ while (true) {
+ while (true) {
+ abc = abc + 1
+ if (abc > 11) {
+ break def;
+ }
+ }
+ }
+ abc;
+ `, 12)
+
+ test(`
+ abc = 0
+ def:
+ do {
+ do {
+ abc = abc + 1
+ if (abc > 11) {
+ break def;
+ }
+ } while (true)
+ } while (true)
+ abc;
+ `, 12)
+ })
+}
+
+func TestConditional(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ [ true ? false : true, true ? 1 : 0, false ? 3.14159 : "abc" ];
+ `, "false,1,abc")
+ })
+}
+
+func TestArrayLiteral(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ [ 1, , 3.14159 ];
+ `, "1,,3.14159")
+ })
+}
+
+func TestAssignment(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ var abc = 1;
+ abc;
+ `, 1)
+
+ test(`
+ abc += 2;
+ abc;
+ `, 3)
+ })
+}
+
+func TestBinaryOperation(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`0 == 1`, false)
+ test(`1 == "1"`, true)
+ test(`0 === 1`, false)
+ test(`1 === "1"`, false)
+ test(`"1" === "1"`, true)
+ })
+}
+
+func Test_typeof(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`typeof abc`, "undefined")
+ test(`typeof abc === 'undefined'`, true)
+ test(`typeof {}`, "object")
+ test(`typeof null`, "object")
+ })
+}
+
+func Test_PrimitiveValueObjectValue(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ Number11 := test(`new Number(11)`)
+ is(Number11.float64(), 11)
+ })
+}
+
+func Test_eval(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ // FIXME terst, Is this correct?
+ test(`
+ var abc = 1;
+ `, "undefined")
+
+ test(`
+ eval("abc += 1");
+ `, 2)
+
+ test(`
+ (function(){
+ var abc = 11;
+ eval("abc += 1");
+ return abc;
+ })();
+ `, 12)
+ test(`abc`, 2)
+
+ test(`
+ (function(){
+ try {
+ eval("var prop = \\u2029;");
+ return false;
+ } catch (abc) {
+ return [ abc instanceof SyntaxError, abc.toString() ];
+ }
+ })();
+ `, "true,SyntaxError: Unexpected token ILLEGAL")
+
+ test(`
+ function abc(){
+ this.THIS = eval("this");
+ }
+ var def = new abc();
+ def === def.THIS;
+ `, true)
+ })
+}
+
+func Test_evalDirectIndirect(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ // (function () {return this;}()).abc = "global";
+ test(`
+ var abc = "global";
+ (function(){
+ try {
+ var _eval = eval;
+ var abc = "function";
+ return [
+ _eval("\'global\' === abc"), // eval (Indirect)
+ eval("\'function\' === abc"), // eval (Direct)
+ ];
+ } finally {
+ delete this.abc;
+ }
+ })();
+ `, "true,true")
+ })
+}
+
+func TestError_URIError(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`new URIError() instanceof URIError`, true)
+
+ test(`
+ var abc
+ try {
+ decodeURI("http://example.com/ _^#%")
+ }
+ catch (def) {
+ abc = def instanceof URIError
+ }
+ abc
+ `, true)
+ })
+}
+
+func TestTo(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ {
+ value, _ := test(`"11"`).ToFloat()
+ is(value, float64(11))
+ }
+
+ {
+ value, _ := test(`"11"`).ToInteger()
+ is(value, int64(11))
+
+ value, _ = test(`1.1`).ToInteger()
+ is(value, int64(1))
+ }
+ })
+}
+
+func TestShouldError(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`raise:
+ xyzzy
+ throw new TypeError("Nothing happens.")
+ `, "ReferenceError: 'xyzzy' is not defined")
+ })
+}
+
+func TestAPI(t *testing.T) {
+ tt(t, func() {
+ test, vm := test()
+
+ test(`
+ String.prototype.xyzzy = function(){
+ return this.length + 11 + (arguments[0] || 0)
+ }
+ abc = new String("xyzzy")
+ def = "Nothing happens."
+ abc.xyzzy()
+ `, 16)
+ abc, _ := vm.Get("abc")
+ def, _ := vm.Get("def")
+ object := abc.Object()
+ result, _ := object.Call("xyzzy")
+ is(result, 16)
+ result, _ = object.Call("xyzzy", 1)
+ is(result, 17)
+ value, _ := object.Get("xyzzy")
+ result, _ = value.Call(def)
+ is(result, 27)
+ result, _ = value.Call(def, 3)
+ is(result, 30)
+ object = value.Object() // Object xyzzy
+ result, _ = object.Value().Call(def, 3)
+ is(result, 30)
+
+ test(`
+ abc = {
+ 'abc': 1,
+ 'def': false,
+ 3.14159: NaN,
+ };
+ abc['abc'];
+ `, 1)
+ abc, err := vm.Get("abc")
+ is(err, nil)
+ object = abc.Object() // Object abc
+ value, err = object.Get("abc")
+ is(err, nil)
+ is(value, 1)
+ is(object.Keys(), []string{"abc", "def", "3.14159"})
+
+ test(`
+ abc = [ 0, 1, 2, 3.14159, "abc", , ];
+ abc.def = true;
+ `)
+ abc, err = vm.Get("abc")
+ is(err, nil)
+ object = abc.Object() // Object abc
+ is(object.Keys(), []string{"0", "1", "2", "3", "4", "def"})
+ })
+}
+
+func TestUnicode(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`var abc = eval("\"a\uFFFFa\"");`, "undefined")
+
+ test(`abc.length`, 3)
+
+ test(`abc != "aa"`, true)
+
+ test("abc[1] === \"\uFFFF\"", true)
+ })
+}
+
+func TestDotMember(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ abc = {
+ ghi: 11,
+ }
+ abc.def = "Xyzzy"
+ abc.null = "Nothing happens."
+ `)
+ test(`abc.def`, "Xyzzy")
+ test(`abc.null`, "Nothing happens.")
+ test(`abc.ghi`, 11)
+
+ test(`
+ abc = {
+ null: 11,
+ }
+ `)
+ test(`abc.def`, "undefined")
+ test(`abc.null`, 11)
+ test(`abc.ghi`, "undefined")
+ })
+}
+
+func Test_stringToFloat(t *testing.T) {
+ tt(t, func() {
+
+ is(parseNumber("10e10000"), _Infinity)
+ is(parseNumber("10e10_."), _NaN)
+ })
+}
+
+func Test_delete(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ delete 42;
+ `, true)
+
+ test(`
+ var abc = delete $_undefined_$;
+ abc = abc && delete ($_undefined_$);
+ abc;
+ `, true)
+
+ // delete should not trigger get()
+ test(`
+ var abc = {
+ get def() {
+ throw "Test_delete: delete should not trigger get()"
+ }
+ };
+ delete abc.def
+ `, true)
+ })
+}
+
+func TestObject_defineOwnProperty(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ var object = {};
+
+ var descriptor = new Boolean(false);
+ descriptor.configurable = true;
+
+ Object.defineProperties(object, {
+ property: descriptor
+ });
+
+ var abc = object.hasOwnProperty("property");
+ delete object.property;
+ var def = object.hasOwnProperty("property");
+
+ [ abc, def ];
+ `, "true,false")
+
+ test(`
+ var object = [0, 1, 2];
+ Object.defineProperty(object, "0", {
+ value: 42,
+ writable: false,
+ enumerable: false,
+ configurable: false
+ });
+ var abc = Object.getOwnPropertyDescriptor(object, "0");
+ [ abc.value, abc.writable, abc.enumerable, abc.configurable ];
+ `, "42,false,false,false")
+
+ test(`
+ var abc = { "xyzzy": 42 };
+ var def = Object.defineProperties(abc, "");
+ abc === def;
+ `, true)
+ })
+}
+
+func Test_assignmentEvaluationOrder(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ var abc = 0;
+ ((abc = 1) & abc);
+ `, 1)
+
+ test(`
+ var abc = 0;
+ (abc & (abc = 1));
+ `, 0)
+ })
+}
+
+func TestOttoCall(t *testing.T) {
+ tt(t, func() {
+ vm := New()
+
+ _, err := vm.Run(`
+ var abc = {
+ ghi: 1,
+ def: function(def){
+ var ghi = 0;
+ if (this.ghi) {
+ ghi = this.ghi;
+ }
+ return "def: " + (def + 3.14159 + ghi);
+ }
+ };
+ `)
+ is(err, nil)
+
+ value, err := vm.Call(`abc.def`, nil, 2)
+ is(err, nil)
+ is(value, "def: 6.14159")
+
+ value, err = vm.Call(`abc.def`, "", 2)
+ is(err, nil)
+ is(value, "def: 5.14159")
+
+ // Do not attempt to do a ToValue on a this of nil
+ value, err = vm.Call(`jkl.def`, nil, 1, 2, 3)
+ is(err, "!=", nil)
+ is(value, "undefined")
+
+ value, err = vm.Call(`[ 1, 2, 3, undefined, 4 ].concat`, nil, 5, 6, 7, "abc")
+ is(err, nil)
+ is(value, "1,2,3,,4,5,6,7,abc")
+ })
+}
+
+func TestOttoCall_new(t *testing.T) {
+ tt(t, func() {
+ test, vm := test()
+
+ vm.Set("abc", func(call FunctionCall) Value {
+ value, err := call.Otto.Call(`new Object`, nil, "Nothing happens.")
+ is(err, nil)
+ return value
+ })
+ test(`
+ def = abc();
+ [ def, def instanceof String ];
+ `, "Nothing happens.,true")
+ })
+}
+
+func TestOttoCall_throw(t *testing.T) {
+ // FIXME? (Been broken for a while)
+ // Looks like this has been broken for a while... what
+ // behavior do we want here?
+
+ if true {
+ return
+ }
+
+ tt(t, func() {
+ test, vm := test()
+
+ vm.Set("abc", func(call FunctionCall) Value {
+ if false {
+ call.Otto.Call(`throw eval`, nil, "({ def: 3.14159 })")
+ }
+ call.Otto.Call(`throw Error`, nil, "abcdef")
+ return Value{}
+ })
+ // TODO try { abc(); } catch (err) { error = err }
+ // Possible unrelated error case:
+ // If error is not declared beforehand, is later referencing it a ReferenceError?
+ // Should the catch { } declare error in the outer scope?
+ test(`
+ var error;
+ try {
+ abc();
+ }
+ catch (err) {
+ error = err;
+ }
+ [ error instanceof Error, error.message, error.def ];
+ `, "true,abcdef,")
+
+ vm.Set("def", func(call FunctionCall) Value {
+ call.Otto.Call(`throw new Object`, nil, 3.14159)
+ return UndefinedValue()
+ })
+ test(`
+ try {
+ def();
+ }
+ catch (err) {
+ error = err;
+ }
+ [ error instanceof Error, error.message, error.def, typeof error, error, error instanceof Number ];
+ `, "false,,,object,3.14159,true")
+ })
+}
+
+func TestOttoCopy(t *testing.T) {
+ tt(t, func() {
+ vm0 := New()
+ vm0.Run(`
+ var abc = function() {
+ return "Xyzzy";
+ };
+
+ function def() {
+ return abc() + (0 + {});
+ }
+ `)
+
+ value, err := vm0.Run(`
+ def();
+ `)
+ is(err, nil)
+ is(value, "Xyzzy0[object Object]")
+
+ vm1 := vm0.Copy()
+ value, err = vm1.Run(`
+ def();
+ `)
+ is(err, nil)
+ is(value, "Xyzzy0[object Object]")
+
+ vm1.Run(`
+ abc = function() {
+ return 3.14159;
+ };
+ `)
+ value, err = vm1.Run(`
+ def();
+ `)
+ is(err, nil)
+ is(value, "3.141590[object Object]")
+
+ value, err = vm0.Run(`
+ def();
+ `)
+ is(err, nil)
+ is(value, "Xyzzy0[object Object]")
+
+ {
+ vm0 := New()
+ vm0.Run(`
+ var global = (function () {return this;}())
+ var abc = 0;
+ var vm = "vm0";
+
+ var def = (function(){
+ var jkl = 0;
+ var abc = function() {
+ global.abc += 1;
+ jkl += 1;
+ return 1;
+ };
+
+ return function() {
+ return [ vm, global.abc, jkl, abc() ];
+ };
+ })();
+ `)
+
+ value, err := vm0.Run(`
+ def();
+ `)
+ is(err, nil)
+ is(value, "vm0,0,0,1")
+
+ vm1 := vm0.Copy()
+ vm1.Set("vm", "vm1")
+ value, err = vm1.Run(`
+ def();
+ `)
+ is(err, nil)
+ is(value, "vm1,1,1,1")
+
+ value, err = vm0.Run(`
+ def();
+ `)
+ is(err, nil)
+ is(value, "vm0,1,1,1")
+
+ value, err = vm1.Run(`
+ def();
+ `)
+ is(err, nil)
+ is(value, "vm1,2,2,1")
+ }
+ })
+}
+
+func TestOttoCall_clone(t *testing.T) {
+ tt(t, func() {
+ vm := New().clone()
+ rt := vm.runtime
+
+ {
+ // FIXME terst, Check how this comparison is done
+ is(rt.global.Array.prototype, rt.global.FunctionPrototype)
+ is(rt.global.ArrayPrototype, "!=", nil)
+ is(rt.global.Array.runtime, rt)
+ is(rt.global.Array.prototype.runtime, rt)
+ is(rt.global.Array.get("prototype")._object().runtime, rt)
+ }
+
+ {
+ value, err := vm.Run(`[ 1, 2, 3 ].toString()`)
+ is(err, nil)
+ is(value, "1,2,3")
+ }
+
+ {
+ value, err := vm.Run(`[ 1, 2, 3 ]`)
+ is(err, nil)
+ is(value, "1,2,3")
+ object := value._object()
+ is(object, "!=", nil)
+ is(object.prototype, rt.global.ArrayPrototype)
+
+ value, err = vm.Run(`Array.prototype`)
+ is(err, nil)
+ object = value._object()
+ is(object.runtime, rt)
+ is(object, "!=", nil)
+ is(object, rt.global.ArrayPrototype)
+ }
+
+ {
+ otto1 := New()
+ _, err := otto1.Run(`
+ var abc = 1;
+ var def = 2;
+ `)
+ is(err, nil)
+
+ otto2 := otto1.clone()
+ value, err := otto2.Run(`abc += 1; abc;`)
+ is(err, nil)
+ is(value, 2)
+
+ value, err = otto1.Run(`abc += 4; abc;`)
+ is(err, nil)
+ is(value, 5)
+ }
+
+ {
+ vm1 := New()
+ _, err := vm1.Run(`
+ var abc = 1;
+ var def = function(value) {
+ abc += value;
+ return abc;
+ }
+ `)
+ is(err, nil)
+
+ vm2 := vm1.clone()
+ value, err := vm2.Run(`def(1)`)
+ is(err, nil)
+ is(value, 2)
+
+ value, err = vm1.Run(`def(4)`)
+ is(err, nil)
+ is(value, 5)
+ }
+
+ {
+ vm1 := New()
+ _, err := vm1.Run(`
+ var abc = {
+ ghi: 1,
+ jkl: function(value) {
+ this.ghi += value;
+ return this.ghi;
+ }
+ };
+ var def = {
+ abc: abc
+ };
+ `)
+ is(err, nil)
+
+ otto2 := vm1.clone()
+ value, err := otto2.Run(`def.abc.jkl(1)`)
+ is(err, nil)
+ is(value, 2)
+
+ value, err = vm1.Run(`def.abc.jkl(4)`)
+ is(err, nil)
+ is(value, 5)
+ }
+
+ {
+ vm1 := New()
+ _, err := vm1.Run(`
+ var abc = function() { return "abc"; };
+ var def = function() { return "def"; };
+ `)
+ is(err, nil)
+
+ vm2 := vm1.clone()
+ value, err := vm2.Run(`
+ [ abc.toString(), def.toString() ];
+ `)
+ is(value, `function() { return "abc"; },function() { return "def"; }`)
+
+ _, err = vm2.Run(`
+ var def = function() { return "ghi"; };
+ `)
+ is(err, nil)
+
+ value, err = vm1.Run(`
+ [ abc.toString(), def.toString() ];
+ `)
+ is(value, `function() { return "abc"; },function() { return "def"; }`)
+
+ value, err = vm2.Run(`
+ [ abc.toString(), def.toString() ];
+ `)
+ is(value, `function() { return "abc"; },function() { return "ghi"; }`)
+ }
+
+ })
+}
+
+func TestOttoRun(t *testing.T) {
+ tt(t, func() {
+ vm := New()
+
+ program, err := parser.ParseFile(nil, "", "", 0)
+ is(err, nil)
+ value, err := vm.Run(program)
+ is(err, nil)
+ is(value, UndefinedValue())
+
+ program, err = parser.ParseFile(nil, "", "2 + 2", 0)
+ is(err, nil)
+ value, err = vm.Run(program)
+ is(err, nil)
+ is(value, 4)
+ value, err = vm.Run(program)
+ is(err, nil)
+ is(value, 4)
+
+ program, err = parser.ParseFile(nil, "", "var abc; if (!abc) abc = 0; abc += 2; abc;", 0)
+ value, err = vm.Run(program)
+ is(err, nil)
+ is(value, 2)
+ value, err = vm.Run(program)
+ is(err, nil)
+ is(value, 4)
+ value, err = vm.Run(program)
+ is(err, nil)
+ is(value, 6)
+
+ {
+ src := []byte("var abc; if (!abc) abc = 0; abc += 2; abc;")
+ value, err = vm.Run(src)
+ is(err, nil)
+ is(value, 8)
+
+ value, err = vm.Run(bytes.NewBuffer(src))
+ is(err, nil)
+ is(value, 10)
+
+ value, err = vm.Run(io.Reader(bytes.NewBuffer(src)))
+ is(err, nil)
+ is(value, 12)
+ }
+
+ {
+ script, err := vm.Compile("", `var abc; if (!abc) abc = 0; abc += 2; abc;`)
+ is(err, nil)
+
+ value, err = vm.Run(script)
+ is(err, nil)
+ is(value, 14)
+
+ value, err = vm.Run(script)
+ is(err, nil)
+ is(value, 16)
+
+ is(script.String(), "// \nvar abc; if (!abc) abc = 0; abc += 2; abc;")
+ }
+ })
+}
+
+func Test_objectLength(t *testing.T) {
+ tt(t, func() {
+ _, vm := test()
+
+ value := vm.Set("abc", []string{"jkl", "mno"})
+ is(objectLength(value._object()), 2)
+
+ value, _ = vm.Run(`[1, 2, 3]`)
+ is(objectLength(value._object()), 3)
+
+ value, _ = vm.Run(`new String("abcdefghi")`)
+ is(objectLength(value._object()), 9)
+
+ value, _ = vm.Run(`"abcdefghi"`)
+ is(objectLength(value._object()), 0)
+ })
+}
+
+func BenchmarkNew(b *testing.B) {
+ for i := 0; i < b.N; i++ {
+ New()
+ }
+}
+
+func BenchmarkClone(b *testing.B) {
+ vm := New()
+ b.ResetTimer()
+ for i := 0; i < b.N; i++ {
+ vm.clone()
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/panic_test.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/panic_test.go
new file mode 100644
index 000000000..06f0a64fc
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/panic_test.go
@@ -0,0 +1,40 @@
+package otto
+
+import (
+ "testing"
+)
+
+func Test_panic(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ // Test that property.value is set to something if writable is set
+ // to something
+ test(`
+ var abc = [];
+ Object.defineProperty(abc, "0", { writable: false });
+ Object.defineProperty(abc, "0", { writable: false });
+ "0" in abc;
+ `, true)
+
+ test(`raise:
+ var abc = [];
+ Object.defineProperty(abc, "0", { writable: false });
+ Object.defineProperty(abc, "0", { value: false, writable: false });
+ `, "TypeError")
+
+ // Test that a regular expression can contain \c0410 (CYRILLIC CAPITAL LETTER A)
+ // without panicking
+ test(`
+ var abc = 0x0410;
+ var def = String.fromCharCode(abc);
+ new RegExp("\\c" + def).exec(def);
+ `, "null")
+
+ // Test transforming a transformable regular expression without a panic
+ test(`
+ new RegExp("\\u0000");
+ new RegExp("\\undefined").test("undefined");
+ `, true)
+ })
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/parser/Makefile b/Godeps/_workspace/src/github.com/robertkrimen/otto/parser/Makefile
new file mode 100644
index 000000000..766fd4d0b
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/parser/Makefile
@@ -0,0 +1,4 @@
+.PHONY: test
+
+test:
+ go test
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/parser/README.markdown b/Godeps/_workspace/src/github.com/robertkrimen/otto/parser/README.markdown
new file mode 100644
index 000000000..c3cae5b60
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/parser/README.markdown
@@ -0,0 +1,190 @@
+# parser
+--
+ import "github.com/robertkrimen/otto/parser"
+
+Package parser implements a parser for JavaScript.
+
+ import (
+ "github.com/robertkrimen/otto/parser"
+ )
+
+Parse and return an AST
+
+ filename := "" // A filename is optional
+ src := `
+ // Sample xyzzy example
+ (function(){
+ if (3.14159 > 0) {
+ console.log("Hello, World.");
+ return;
+ }
+
+ var xyzzy = NaN;
+ console.log("Nothing happens.");
+ return xyzzy;
+ })();
+ `
+
+ // Parse some JavaScript, yielding a *ast.Program and/or an ErrorList
+ program, err := parser.ParseFile(nil, filename, src, 0)
+
+
+### Warning
+
+The parser and AST interfaces are still works-in-progress (particularly where
+node types are concerned) and may change in the future.
+
+## Usage
+
+#### func ParseFile
+
+```go
+func ParseFile(fileSet *file.FileSet, filename string, src interface{}, mode Mode) (*ast.Program, error)
+```
+ParseFile parses the source code of a single JavaScript/ECMAScript source file
+and returns the corresponding ast.Program node.
+
+If fileSet == nil, ParseFile parses source without a FileSet. If fileSet != nil,
+ParseFile first adds filename and src to fileSet.
+
+The filename argument is optional and is used for labelling errors, etc.
+
+src may be a string, a byte slice, a bytes.Buffer, or an io.Reader, but it MUST
+always be in UTF-8.
+
+ // Parse some JavaScript, yielding a *ast.Program and/or an ErrorList
+ program, err := parser.ParseFile(nil, "", `if (abc > 1) {}`, 0)
+
+#### func ParseFunction
+
+```go
+func ParseFunction(parameterList, body string) (*ast.FunctionLiteral, error)
+```
+ParseFunction parses a given parameter list and body as a function and returns
+the corresponding ast.FunctionLiteral node.
+
+The parameter list, if any, should be a comma-separated list of identifiers.
+
+#### func ReadSource
+
+```go
+func ReadSource(filename string, src interface{}) ([]byte, error)
+```
+
+#### func TransformRegExp
+
+```go
+func TransformRegExp(pattern string) (string, error)
+```
+TransformRegExp transforms a JavaScript pattern into a Go "regexp" pattern.
+
+re2 (Go) cannot do backtracking, so the presence of a lookahead (?=) (?!) or
+backreference (\1, \2, ...) will cause an error.
+
+re2 (Go) has a different definition for \s: [\t\n\f\r ]. The JavaScript
+definition, on the other hand, also includes \v, Unicode "Separator, Space",
+etc.
+
+If the pattern is invalid (not valid even in JavaScript), then this function
+returns the empty string and an error.
+
+If the pattern is valid, but incompatible (contains a lookahead or
+backreference), then this function returns the transformation (a non-empty
+string) AND an error.
+
+#### type Error
+
+```go
+type Error struct {
+ Position file.Position
+ Message string
+}
+```
+
+An Error represents a parsing error. It includes the position where the error
+occurred and a message/description.
+
+#### func (Error) Error
+
+```go
+func (self Error) Error() string
+```
+
+#### type ErrorList
+
+```go
+type ErrorList []*Error
+```
+
+ErrorList is a list of *Errors.
+
+#### func (*ErrorList) Add
+
+```go
+func (self *ErrorList) Add(position file.Position, msg string)
+```
+Add adds an Error with given position and message to an ErrorList.
+
+#### func (ErrorList) Err
+
+```go
+func (self ErrorList) Err() error
+```
+Err returns an error equivalent to this ErrorList. If the list is empty, Err
+returns nil.
+
+#### func (ErrorList) Error
+
+```go
+func (self ErrorList) Error() string
+```
+Error implements the Error interface.
+
+#### func (ErrorList) Len
+
+```go
+func (self ErrorList) Len() int
+```
+
+#### func (ErrorList) Less
+
+```go
+func (self ErrorList) Less(i, j int) bool
+```
+
+#### func (*ErrorList) Reset
+
+```go
+func (self *ErrorList) Reset()
+```
+Reset resets an ErrorList to no errors.
+
+#### func (ErrorList) Sort
+
+```go
+func (self ErrorList) Sort()
+```
+
+#### func (ErrorList) Swap
+
+```go
+func (self ErrorList) Swap(i, j int)
+```
+
+#### type Mode
+
+```go
+type Mode uint
+```
+
+A Mode value is a set of flags (or 0). They control optional parser
+functionality.
+
+```go
+const (
+ IgnoreRegExpErrors Mode = 1 << iota // Ignore RegExp compatibility errors (allow backtracking)
+)
+```
+
+--
+**godocdown** http://github.com/robertkrimen/godocdown
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/parser/dbg.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/parser/dbg.go
new file mode 100644
index 000000000..3c5f2f698
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/parser/dbg.go
@@ -0,0 +1,9 @@
+// This file was AUTOMATICALLY GENERATED by dbg-import (smuggol) for github.com/robertkrimen/dbg
+
+package parser
+
+import (
+ Dbg "github.com/robertkrimen/otto/dbg"
+)
+
+var dbg, dbgf = Dbg.New()
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/parser/error.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/parser/error.go
new file mode 100644
index 000000000..e0f74a5cf
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/parser/error.go
@@ -0,0 +1,175 @@
+package parser
+
+import (
+ "fmt"
+ "sort"
+
+ "github.com/robertkrimen/otto/file"
+ "github.com/robertkrimen/otto/token"
+)
+
+const (
+ err_UnexpectedToken = "Unexpected token %v"
+ err_UnexpectedEndOfInput = "Unexpected end of input"
+ err_UnexpectedEscape = "Unexpected escape"
+)
+
+// UnexpectedNumber: 'Unexpected number',
+// UnexpectedString: 'Unexpected string',
+// UnexpectedIdentifier: 'Unexpected identifier',
+// UnexpectedReserved: 'Unexpected reserved word',
+// NewlineAfterThrow: 'Illegal newline after throw',
+// InvalidRegExp: 'Invalid regular expression',
+// UnterminatedRegExp: 'Invalid regular expression: missing /',
+// InvalidLHSInAssignment: 'Invalid left-hand side in assignment',
+// InvalidLHSInForIn: 'Invalid left-hand side in for-in',
+// MultipleDefaultsInSwitch: 'More than one default clause in switch statement',
+// NoCatchOrFinally: 'Missing catch or finally after try',
+// UnknownLabel: 'Undefined label \'%0\'',
+// Redeclaration: '%0 \'%1\' has already been declared',
+// IllegalContinue: 'Illegal continue statement',
+// IllegalBreak: 'Illegal break statement',
+// IllegalReturn: 'Illegal return statement',
+// StrictModeWith: 'Strict mode code may not include a with statement',
+// StrictCatchVariable: 'Catch variable may not be eval or arguments in strict mode',
+// StrictVarName: 'Variable name may not be eval or arguments in strict mode',
+// StrictParamName: 'Parameter name eval or arguments is not allowed in strict mode',
+// StrictParamDupe: 'Strict mode function may not have duplicate parameter names',
+// StrictFunctionName: 'Function name may not be eval or arguments in strict mode',
+// StrictOctalLiteral: 'Octal literals are not allowed in strict mode.',
+// StrictDelete: 'Delete of an unqualified identifier in strict mode.',
+// StrictDuplicateProperty: 'Duplicate data property in object literal not allowed in strict mode',
+// AccessorDataProperty: 'Object literal may not have data and accessor property with the same name',
+// AccessorGetSet: 'Object literal may not have multiple get/set accessors with the same name',
+// StrictLHSAssignment: 'Assignment to eval or arguments is not allowed in strict mode',
+// StrictLHSPostfix: 'Postfix increment/decrement may not have eval or arguments operand in strict mode',
+// StrictLHSPrefix: 'Prefix increment/decrement may not have eval or arguments operand in strict mode',
+// StrictReservedWord: 'Use of future reserved word in strict mode'
+
+// A SyntaxError is a description of an ECMAScript syntax error.
+
+// An Error represents a parsing error. It includes the position where the error occurred and a message/description.
+type Error struct {
+ Position file.Position
+ Message string
+}
+
+// FIXME Should this be "SyntaxError"?
+
+func (self Error) Error() string {
+ filename := self.Position.Filename
+ if filename == "" {
+ filename = "(anonymous)"
+ }
+ return fmt.Sprintf("%s: Line %d:%d %s",
+ filename,
+ self.Position.Line,
+ self.Position.Column,
+ self.Message,
+ )
+}
+
+func (self *_parser) error(place interface{}, msg string, msgValues ...interface{}) *Error {
+ idx := file.Idx(0)
+ switch place := place.(type) {
+ case int:
+ idx = self.idxOf(place)
+ case file.Idx:
+ if place == 0 {
+ idx = self.idxOf(self.chrOffset)
+ } else {
+ idx = place
+ }
+ default:
+ panic(fmt.Errorf("error(%T, ...)", place))
+ }
+
+ position := self.position(idx)
+ msg = fmt.Sprintf(msg, msgValues...)
+ self.errors.Add(position, msg)
+ return self.errors[len(self.errors)-1]
+}
+
+func (self *_parser) errorUnexpected(idx file.Idx, chr rune) error {
+ if chr == -1 {
+ return self.error(idx, err_UnexpectedEndOfInput)
+ }
+ return self.error(idx, err_UnexpectedToken, token.ILLEGAL)
+}
+
+func (self *_parser) errorUnexpectedToken(tkn token.Token) error {
+ switch tkn {
+ case token.EOF:
+ return self.error(file.Idx(0), err_UnexpectedEndOfInput)
+ }
+ value := tkn.String()
+ switch tkn {
+ case token.BOOLEAN, token.NULL:
+ value = self.literal
+ case token.IDENTIFIER:
+ return self.error(self.idx, "Unexpected identifier")
+ case token.KEYWORD:
+ // TODO Might be a future reserved word
+ return self.error(self.idx, "Unexpected reserved word")
+ case token.NUMBER:
+ return self.error(self.idx, "Unexpected number")
+ case token.STRING:
+ return self.error(self.idx, "Unexpected string")
+ }
+ return self.error(self.idx, err_UnexpectedToken, value)
+}
+
+// ErrorList is a list of *Errors.
+//
+type ErrorList []*Error
+
+// Add adds an Error with given position and message to an ErrorList.
+func (self *ErrorList) Add(position file.Position, msg string) {
+ *self = append(*self, &Error{position, msg})
+}
+
+// Reset resets an ErrorList to no errors.
+func (self *ErrorList) Reset() { *self = (*self)[0:0] }
+
+func (self ErrorList) Len() int { return len(self) }
+func (self ErrorList) Swap(i, j int) { self[i], self[j] = self[j], self[i] }
+func (self ErrorList) Less(i, j int) bool {
+ x := &self[i].Position
+ y := &self[j].Position
+ if x.Filename < y.Filename {
+ return true
+ }
+ if x.Filename == y.Filename {
+ if x.Line < y.Line {
+ return true
+ }
+ if x.Line == y.Line {
+ return x.Column < y.Column
+ }
+ }
+ return false
+}
+
+func (self ErrorList) Sort() {
+ sort.Sort(self)
+}
+
+// Error implements the Error interface.
+func (self ErrorList) Error() string {
+ switch len(self) {
+ case 0:
+ return "no errors"
+ case 1:
+ return self[0].Error()
+ }
+ return fmt.Sprintf("%s (and %d more errors)", self[0].Error(), len(self)-1)
+}
+
+// Err returns an error equivalent to this ErrorList.
+// If the list is empty, Err returns nil.
+func (self ErrorList) Err() error {
+ if len(self) == 0 {
+ return nil
+ }
+ return self
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/parser/expression.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/parser/expression.go
new file mode 100644
index 000000000..dc397b5cb
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/parser/expression.go
@@ -0,0 +1,815 @@
+package parser
+
+import (
+ "regexp"
+
+ "github.com/robertkrimen/otto/ast"
+ "github.com/robertkrimen/otto/file"
+ "github.com/robertkrimen/otto/token"
+)
+
+func (self *_parser) parseIdentifier() *ast.Identifier {
+ literal := self.literal
+ idx := self.idx
+ self.next()
+ return &ast.Identifier{
+ Name: literal,
+ Idx: idx,
+ }
+}
+
+func (self *_parser) parsePrimaryExpression() ast.Expression {
+ literal := self.literal
+ idx := self.idx
+ switch self.token {
+ case token.IDENTIFIER:
+ self.next()
+ if len(literal) > 1 {
+ tkn, strict := token.IsKeyword(literal)
+ if tkn == token.KEYWORD {
+ if !strict {
+ self.error(idx, "Unexpected reserved word")
+ }
+ }
+ }
+ return &ast.Identifier{
+ Name: literal,
+ Idx: idx,
+ }
+ case token.NULL:
+ self.next()
+ return &ast.NullLiteral{
+ Idx: idx,
+ Literal: literal,
+ }
+ case token.BOOLEAN:
+ self.next()
+ value := false
+ switch literal {
+ case "true":
+ value = true
+ case "false":
+ value = false
+ default:
+ self.error(idx, "Illegal boolean literal")
+ }
+ return &ast.BooleanLiteral{
+ Idx: idx,
+ Literal: literal,
+ Value: value,
+ }
+ case token.STRING:
+ self.next()
+ value, err := parseStringLiteral(literal[1 : len(literal)-1])
+ if err != nil {
+ self.error(idx, err.Error())
+ }
+ return &ast.StringLiteral{
+ Idx: idx,
+ Literal: literal,
+ Value: value,
+ }
+ case token.NUMBER:
+ self.next()
+ value, err := parseNumberLiteral(literal)
+ if err != nil {
+ self.error(idx, err.Error())
+ value = 0
+ }
+ return &ast.NumberLiteral{
+ Idx: idx,
+ Literal: literal,
+ Value: value,
+ }
+ case token.SLASH, token.QUOTIENT_ASSIGN:
+ return self.parseRegExpLiteral()
+ case token.LEFT_BRACE:
+ return self.parseObjectLiteral()
+ case token.LEFT_BRACKET:
+ return self.parseArrayLiteral()
+ case token.LEFT_PARENTHESIS:
+ self.expect(token.LEFT_PARENTHESIS)
+ expression := self.parseExpression()
+ self.expect(token.RIGHT_PARENTHESIS)
+ return expression
+ case token.THIS:
+ self.next()
+ return &ast.ThisExpression{
+ Idx: idx,
+ }
+ case token.FUNCTION:
+ return self.parseFunction(false)
+ }
+
+ self.errorUnexpectedToken(self.token)
+ self.nextStatement()
+ return &ast.BadExpression{From: idx, To: self.idx}
+}
+
+func (self *_parser) parseRegExpLiteral() *ast.RegExpLiteral {
+
+ offset := self.chrOffset - 1 // Opening slash already gotten
+ if self.token == token.QUOTIENT_ASSIGN {
+ offset -= 1 // =
+ }
+ idx := self.idxOf(offset)
+
+ pattern, err := self.scanString(offset)
+ endOffset := self.chrOffset
+
+ self.next()
+ if err == nil {
+ pattern = pattern[1 : len(pattern)-1]
+ }
+
+ flags := ""
+ if self.token == token.IDENTIFIER { // gim
+
+ flags = self.literal
+ self.next()
+ endOffset = self.chrOffset - 1
+ }
+
+ var value string
+ // TODO 15.10
+ {
+ // Test during parsing that this is a valid regular expression
+ // Sorry, (?=) and (?!) are invalid (for now)
+ pattern, err := TransformRegExp(pattern)
+ if err != nil {
+ if pattern == "" || self.mode&IgnoreRegExpErrors == 0 {
+ self.error(idx, "Invalid regular expression: %s", err.Error())
+ }
+ } else {
+ _, err = regexp.Compile(pattern)
+ if err != nil {
+ // We should not get here, ParseRegExp should catch any errors
+ self.error(idx, "Invalid regular expression: %s", err.Error()[22:]) // Skip redundant "parse regexp error"
+ } else {
+ value = pattern
+ }
+ }
+ }
+
+ literal := self.str[offset:endOffset]
+
+ return &ast.RegExpLiteral{
+ Idx: idx,
+ Literal: literal,
+ Pattern: pattern,
+ Flags: flags,
+ Value: value,
+ }
+}
+
+func (self *_parser) parseVariableDeclaration(declarationList *[]*ast.VariableExpression) ast.Expression {
+
+ if self.token != token.IDENTIFIER {
+ idx := self.expect(token.IDENTIFIER)
+ self.nextStatement()
+ return &ast.BadExpression{From: idx, To: self.idx}
+ }
+
+ literal := self.literal
+ idx := self.idx
+ self.next()
+ node := &ast.VariableExpression{
+ Name: literal,
+ Idx: idx,
+ }
+
+ if declarationList != nil {
+ *declarationList = append(*declarationList, node)
+ }
+
+ if self.token == token.ASSIGN {
+ self.next()
+ node.Initializer = self.parseAssignmentExpression()
+ }
+
+ return node
+}
+
+func (self *_parser) parseVariableDeclarationList(var_ file.Idx) []ast.Expression {
+
+ var declarationList []*ast.VariableExpression // Avoid bad expressions
+ var list []ast.Expression
+
+ for {
+ list = append(list, self.parseVariableDeclaration(&declarationList))
+ if self.token != token.COMMA {
+ break
+ }
+ self.next()
+ }
+
+ self.scope.declare(&ast.VariableDeclaration{
+ Var: var_,
+ List: declarationList,
+ })
+
+ return list
+}
+
+func (self *_parser) parseObjectPropertyKey() (string, string) {
+ idx, tkn, literal := self.idx, self.token, self.literal
+ value := ""
+ self.next()
+ switch tkn {
+ case token.IDENTIFIER:
+ value = literal
+ case token.NUMBER:
+ var err error
+ _, err = parseNumberLiteral(literal)
+ if err != nil {
+ self.error(idx, err.Error())
+ } else {
+ value = literal
+ }
+ case token.STRING:
+ var err error
+ value, err = parseStringLiteral(literal[1 : len(literal)-1])
+ if err != nil {
+ self.error(idx, err.Error())
+ }
+ default:
+ // null, false, class, etc.
+ if matchIdentifier.MatchString(literal) {
+ value = literal
+ }
+ }
+ return literal, value
+}
+
+func (self *_parser) parseObjectProperty() ast.Property {
+
+ literal, value := self.parseObjectPropertyKey()
+ if literal == "get" && self.token != token.COLON {
+ idx := self.idx
+ _, value := self.parseObjectPropertyKey()
+ parameterList := self.parseFunctionParameterList()
+
+ node := &ast.FunctionLiteral{
+ Function: idx,
+ ParameterList: parameterList,
+ }
+ self.parseFunctionBlock(node)
+ return ast.Property{
+ Key: value,
+ Kind: "get",
+ Value: node,
+ }
+ } else if literal == "set" && self.token != token.COLON {
+ idx := self.idx
+ _, value := self.parseObjectPropertyKey()
+ parameterList := self.parseFunctionParameterList()
+
+ node := &ast.FunctionLiteral{
+ Function: idx,
+ ParameterList: parameterList,
+ }
+ self.parseFunctionBlock(node)
+ return ast.Property{
+ Key: value,
+ Kind: "set",
+ Value: node,
+ }
+ }
+
+ self.expect(token.COLON)
+
+ return ast.Property{
+ Key: value,
+ Kind: "value",
+ Value: self.parseAssignmentExpression(),
+ }
+}
+
+func (self *_parser) parseObjectLiteral() ast.Expression {
+ var value []ast.Property
+ idx0 := self.expect(token.LEFT_BRACE)
+ for self.token != token.RIGHT_BRACE && self.token != token.EOF {
+ property := self.parseObjectProperty()
+ value = append(value, property)
+ if self.token == token.COMMA {
+ self.next()
+ continue
+ }
+ }
+ idx1 := self.expect(token.RIGHT_BRACE)
+
+ return &ast.ObjectLiteral{
+ LeftBrace: idx0,
+ RightBrace: idx1,
+ Value: value,
+ }
+}
+
+func (self *_parser) parseArrayLiteral() ast.Expression {
+
+ idx0 := self.expect(token.LEFT_BRACKET)
+ var value []ast.Expression
+ for self.token != token.RIGHT_BRACKET && self.token != token.EOF {
+ if self.token == token.COMMA {
+ self.next()
+ value = append(value, nil)
+ continue
+ }
+ value = append(value, self.parseAssignmentExpression())
+ if self.token != token.RIGHT_BRACKET {
+ self.expect(token.COMMA)
+ }
+ }
+ idx1 := self.expect(token.RIGHT_BRACKET)
+
+ return &ast.ArrayLiteral{
+ LeftBracket: idx0,
+ RightBracket: idx1,
+ Value: value,
+ }
+}
+
+func (self *_parser) parseArgumentList() (argumentList []ast.Expression, idx0, idx1 file.Idx) {
+ idx0 = self.expect(token.LEFT_PARENTHESIS)
+ if self.token != token.RIGHT_PARENTHESIS {
+ for {
+ argumentList = append(argumentList, self.parseAssignmentExpression())
+ if self.token != token.COMMA {
+ break
+ }
+ self.next()
+ }
+ }
+ idx1 = self.expect(token.RIGHT_PARENTHESIS)
+ return
+}
+
+func (self *_parser) parseCallExpression(left ast.Expression) ast.Expression {
+ argumentList, idx0, idx1 := self.parseArgumentList()
+ return &ast.CallExpression{
+ Callee: left,
+ LeftParenthesis: idx0,
+ ArgumentList: argumentList,
+ RightParenthesis: idx1,
+ }
+}
+
+func (self *_parser) parseDotMember(left ast.Expression) ast.Expression {
+ period := self.expect(token.PERIOD)
+
+ literal := self.literal
+ idx := self.idx
+
+ if !matchIdentifier.MatchString(literal) {
+ self.expect(token.IDENTIFIER)
+ self.nextStatement()
+ return &ast.BadExpression{From: period, To: self.idx}
+ }
+
+ self.next()
+
+ return &ast.DotExpression{
+ Left: left,
+ Identifier: ast.Identifier{
+ Idx: idx,
+ Name: literal,
+ },
+ }
+}
+
+func (self *_parser) parseBracketMember(left ast.Expression) ast.Expression {
+ idx0 := self.expect(token.LEFT_BRACKET)
+ member := self.parseExpression()
+ idx1 := self.expect(token.RIGHT_BRACKET)
+ return &ast.BracketExpression{
+ LeftBracket: idx0,
+ Left: left,
+ Member: member,
+ RightBracket: idx1,
+ }
+}
+
+func (self *_parser) parseNewExpression() ast.Expression {
+ idx := self.expect(token.NEW)
+ callee := self.parseLeftHandSideExpression()
+ node := &ast.NewExpression{
+ New: idx,
+ Callee: callee,
+ }
+ if self.token == token.LEFT_PARENTHESIS {
+ argumentList, idx0, idx1 := self.parseArgumentList()
+ node.ArgumentList = argumentList
+ node.LeftParenthesis = idx0
+ node.RightParenthesis = idx1
+ }
+ return node
+}
+
+func (self *_parser) parseLeftHandSideExpression() ast.Expression {
+
+ var left ast.Expression
+ if self.token == token.NEW {
+ left = self.parseNewExpression()
+ } else {
+ left = self.parsePrimaryExpression()
+ }
+
+ for {
+ if self.token == token.PERIOD {
+ left = self.parseDotMember(left)
+ } else if self.token == token.LEFT_BRACE {
+ left = self.parseBracketMember(left)
+ } else {
+ break
+ }
+ }
+
+ return left
+}
+
+func (self *_parser) parseLeftHandSideExpressionAllowCall() ast.Expression {
+
+ allowIn := self.scope.allowIn
+ self.scope.allowIn = true
+ defer func() {
+ self.scope.allowIn = allowIn
+ }()
+
+ var left ast.Expression
+ if self.token == token.NEW {
+ left = self.parseNewExpression()
+ } else {
+ left = self.parsePrimaryExpression()
+ }
+
+ for {
+ if self.token == token.PERIOD {
+ left = self.parseDotMember(left)
+ } else if self.token == token.LEFT_BRACKET {
+ left = self.parseBracketMember(left)
+ } else if self.token == token.LEFT_PARENTHESIS {
+ left = self.parseCallExpression(left)
+ } else {
+ break
+ }
+ }
+
+ return left
+}
+
+func (self *_parser) parsePostfixExpression() ast.Expression {
+ operand := self.parseLeftHandSideExpressionAllowCall()
+
+ switch self.token {
+ case token.INCREMENT, token.DECREMENT:
+ // Make sure there is no line terminator here
+ if self.implicitSemicolon {
+ break
+ }
+ tkn := self.token
+ idx := self.idx
+ self.next()
+ switch operand.(type) {
+ case *ast.Identifier, *ast.DotExpression, *ast.BracketExpression:
+ default:
+ self.error(idx, "Invalid left-hand side in assignment")
+ self.nextStatement()
+ return &ast.BadExpression{From: idx, To: self.idx}
+ }
+ return &ast.UnaryExpression{
+ Operator: tkn,
+ Idx: idx,
+ Operand: operand,
+ Postfix: true,
+ }
+ }
+
+ return operand
+}
+
+func (self *_parser) parseUnaryExpression() ast.Expression {
+
+ switch self.token {
+ case token.PLUS, token.MINUS, token.NOT, token.BITWISE_NOT:
+ fallthrough
+ case token.DELETE, token.VOID, token.TYPEOF:
+ tkn := self.token
+ idx := self.idx
+ self.next()
+ return &ast.UnaryExpression{
+ Operator: tkn,
+ Idx: idx,
+ Operand: self.parseUnaryExpression(),
+ }
+ case token.INCREMENT, token.DECREMENT:
+ tkn := self.token
+ idx := self.idx
+ self.next()
+ operand := self.parseUnaryExpression()
+ switch operand.(type) {
+ case *ast.Identifier, *ast.DotExpression, *ast.BracketExpression:
+ default:
+ self.error(idx, "Invalid left-hand side in assignment")
+ self.nextStatement()
+ return &ast.BadExpression{From: idx, To: self.idx}
+ }
+ return &ast.UnaryExpression{
+ Operator: tkn,
+ Idx: idx,
+ Operand: operand,
+ }
+ }
+
+ return self.parsePostfixExpression()
+}
+
+func (self *_parser) parseMultiplicativeExpression() ast.Expression {
+ next := self.parseUnaryExpression
+ left := next()
+
+ for self.token == token.MULTIPLY || self.token == token.SLASH ||
+ self.token == token.REMAINDER {
+ tkn := self.token
+ self.next()
+ left = &ast.BinaryExpression{
+ Operator: tkn,
+ Left: left,
+ Right: next(),
+ }
+ }
+
+ return left
+}
+
+func (self *_parser) parseAdditiveExpression() ast.Expression {
+ next := self.parseMultiplicativeExpression
+ left := next()
+
+ for self.token == token.PLUS || self.token == token.MINUS {
+ tkn := self.token
+ self.next()
+ left = &ast.BinaryExpression{
+ Operator: tkn,
+ Left: left,
+ Right: next(),
+ }
+ }
+
+ return left
+}
+
+func (self *_parser) parseShiftExpression() ast.Expression {
+ next := self.parseAdditiveExpression
+ left := next()
+
+ for self.token == token.SHIFT_LEFT || self.token == token.SHIFT_RIGHT ||
+ self.token == token.UNSIGNED_SHIFT_RIGHT {
+ tkn := self.token
+ self.next()
+ left = &ast.BinaryExpression{
+ Operator: tkn,
+ Left: left,
+ Right: next(),
+ }
+ }
+
+ return left
+}
+
+func (self *_parser) parseRelationalExpression() ast.Expression {
+ next := self.parseShiftExpression
+ left := next()
+
+ allowIn := self.scope.allowIn
+ self.scope.allowIn = true
+ defer func() {
+ self.scope.allowIn = allowIn
+ }()
+
+ switch self.token {
+ case token.LESS, token.LESS_OR_EQUAL, token.GREATER, token.GREATER_OR_EQUAL:
+ tkn := self.token
+ self.next()
+ return &ast.BinaryExpression{
+ Operator: tkn,
+ Left: left,
+ Right: self.parseRelationalExpression(),
+ Comparison: true,
+ }
+ case token.INSTANCEOF:
+ tkn := self.token
+ self.next()
+ return &ast.BinaryExpression{
+ Operator: tkn,
+ Left: left,
+ Right: self.parseRelationalExpression(),
+ }
+ case token.IN:
+ if !allowIn {
+ return left
+ }
+ tkn := self.token
+ self.next()
+ return &ast.BinaryExpression{
+ Operator: tkn,
+ Left: left,
+ Right: self.parseRelationalExpression(),
+ }
+ }
+
+ return left
+}
+
+func (self *_parser) parseEqualityExpression() ast.Expression {
+ next := self.parseRelationalExpression
+ left := next()
+
+ for self.token == token.EQUAL || self.token == token.NOT_EQUAL ||
+ self.token == token.STRICT_EQUAL || self.token == token.STRICT_NOT_EQUAL {
+ tkn := self.token
+ self.next()
+ left = &ast.BinaryExpression{
+ Operator: tkn,
+ Left: left,
+ Right: next(),
+ Comparison: true,
+ }
+ }
+
+ return left
+}
+
+func (self *_parser) parseBitwiseAndExpression() ast.Expression {
+ next := self.parseEqualityExpression
+ left := next()
+
+ for self.token == token.AND {
+ tkn := self.token
+ self.next()
+ left = &ast.BinaryExpression{
+ Operator: tkn,
+ Left: left,
+ Right: next(),
+ }
+ }
+
+ return left
+}
+
+func (self *_parser) parseBitwiseExclusiveOrExpression() ast.Expression {
+ next := self.parseBitwiseAndExpression
+ left := next()
+
+ for self.token == token.EXCLUSIVE_OR {
+ tkn := self.token
+ self.next()
+ left = &ast.BinaryExpression{
+ Operator: tkn,
+ Left: left,
+ Right: next(),
+ }
+ }
+
+ return left
+}
+
+func (self *_parser) parseBitwiseOrExpression() ast.Expression {
+ next := self.parseBitwiseExclusiveOrExpression
+ left := next()
+
+ for self.token == token.OR {
+ tkn := self.token
+ self.next()
+ left = &ast.BinaryExpression{
+ Operator: tkn,
+ Left: left,
+ Right: next(),
+ }
+ }
+
+ return left
+}
+
+func (self *_parser) parseLogicalAndExpression() ast.Expression {
+ next := self.parseBitwiseOrExpression
+ left := next()
+
+ for self.token == token.LOGICAL_AND {
+ tkn := self.token
+ self.next()
+ left = &ast.BinaryExpression{
+ Operator: tkn,
+ Left: left,
+ Right: next(),
+ }
+ }
+
+ return left
+}
+
+func (self *_parser) parseLogicalOrExpression() ast.Expression {
+ next := self.parseLogicalAndExpression
+ left := next()
+
+ for self.token == token.LOGICAL_OR {
+ tkn := self.token
+ self.next()
+ left = &ast.BinaryExpression{
+ Operator: tkn,
+ Left: left,
+ Right: next(),
+ }
+ }
+
+ return left
+}
+
+func (self *_parser) parseConditionlExpression() ast.Expression {
+ left := self.parseLogicalOrExpression()
+
+ if self.token == token.QUESTION_MARK {
+ self.next()
+ consequent := self.parseAssignmentExpression()
+ self.expect(token.COLON)
+ return &ast.ConditionalExpression{
+ Test: left,
+ Consequent: consequent,
+ Alternate: self.parseAssignmentExpression(),
+ }
+ }
+
+ return left
+}
+
+func (self *_parser) parseAssignmentExpression() ast.Expression {
+ left := self.parseConditionlExpression()
+ var operator token.Token
+ switch self.token {
+ case token.ASSIGN:
+ operator = self.token
+ case token.ADD_ASSIGN:
+ operator = token.PLUS
+ case token.SUBTRACT_ASSIGN:
+ operator = token.MINUS
+ case token.MULTIPLY_ASSIGN:
+ operator = token.MULTIPLY
+ case token.QUOTIENT_ASSIGN:
+ operator = token.SLASH
+ case token.REMAINDER_ASSIGN:
+ operator = token.REMAINDER
+ case token.AND_ASSIGN:
+ operator = token.AND
+ case token.AND_NOT_ASSIGN:
+ operator = token.AND_NOT
+ case token.OR_ASSIGN:
+ operator = token.OR
+ case token.EXCLUSIVE_OR_ASSIGN:
+ operator = token.EXCLUSIVE_OR
+ case token.SHIFT_LEFT_ASSIGN:
+ operator = token.SHIFT_LEFT
+ case token.SHIFT_RIGHT_ASSIGN:
+ operator = token.SHIFT_RIGHT
+ case token.UNSIGNED_SHIFT_RIGHT_ASSIGN:
+ operator = token.UNSIGNED_SHIFT_RIGHT
+ }
+
+ if operator != 0 {
+ idx := self.idx
+ self.next()
+ switch left.(type) {
+ case *ast.Identifier, *ast.DotExpression, *ast.BracketExpression:
+ default:
+ self.error(left.Idx0(), "Invalid left-hand side in assignment")
+ self.nextStatement()
+ return &ast.BadExpression{From: idx, To: self.idx}
+ }
+ return &ast.AssignExpression{
+ Left: left,
+ Operator: operator,
+ Right: self.parseAssignmentExpression(),
+ }
+ }
+
+ return left
+}
+
+func (self *_parser) parseExpression() ast.Expression {
+ next := self.parseAssignmentExpression
+ left := next()
+
+ if self.token == token.COMMA {
+ sequence := []ast.Expression{left}
+ for {
+ if self.token != token.COMMA {
+ break
+ }
+ self.next()
+ sequence = append(sequence, next())
+ }
+ return &ast.SequenceExpression{
+ Sequence: sequence,
+ }
+ }
+
+ return left
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/parser/lexer.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/parser/lexer.go
new file mode 100644
index 000000000..bc3e74f77
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/parser/lexer.go
@@ -0,0 +1,819 @@
+package parser
+
+import (
+ "bytes"
+ "errors"
+ "fmt"
+ "regexp"
+ "strconv"
+ "strings"
+ "unicode"
+ "unicode/utf8"
+
+ "github.com/robertkrimen/otto/file"
+ "github.com/robertkrimen/otto/token"
+)
+
+type _chr struct {
+ value rune
+ width int
+}
+
+var matchIdentifier = regexp.MustCompile(`^[$_\p{L}][$_\p{L}\d}]*$`)
+
+func isDecimalDigit(chr rune) bool {
+ return '0' <= chr && chr <= '9'
+}
+
+func digitValue(chr rune) int {
+ switch {
+ case '0' <= chr && chr <= '9':
+ return int(chr - '0')
+ case 'a' <= chr && chr <= 'f':
+ return int(chr - 'a' + 10)
+ case 'A' <= chr && chr <= 'F':
+ return int(chr - 'A' + 10)
+ }
+ return 16 // Larger than any legal digit value
+}
+
+func isDigit(chr rune, base int) bool {
+ return digitValue(chr) < base
+}
+
+func isIdentifierStart(chr rune) bool {
+ return chr == '$' || chr == '_' || chr == '\\' ||
+ 'a' <= chr && chr <= 'z' || 'A' <= chr && chr <= 'Z' ||
+ chr >= utf8.RuneSelf && unicode.IsLetter(chr)
+}
+
+func isIdentifierPart(chr rune) bool {
+ return chr == '$' || chr == '_' || chr == '\\' ||
+ 'a' <= chr && chr <= 'z' || 'A' <= chr && chr <= 'Z' ||
+ '0' <= chr && chr <= '9' ||
+ chr >= utf8.RuneSelf && (unicode.IsLetter(chr) || unicode.IsDigit(chr))
+}
+
+func (self *_parser) scanIdentifier() (string, error) {
+ offset := self.chrOffset
+ parse := false
+ for isIdentifierPart(self.chr) {
+ if self.chr == '\\' {
+ distance := self.chrOffset - offset
+ self.read()
+ if self.chr != 'u' {
+ return "", fmt.Errorf("Invalid identifier escape character: %c (%s)", self.chr, string(self.chr))
+ }
+ parse = true
+ var value rune
+ for j := 0; j < 4; j++ {
+ self.read()
+ decimal, ok := hex2decimal(byte(self.chr))
+ if !ok {
+ return "", fmt.Errorf("Invalid identifier escape character: %c (%s)", self.chr, string(self.chr))
+ }
+ value = value<<4 | decimal
+ }
+ if value == '\\' {
+ return "", fmt.Errorf("Invalid identifier escape value: %c (%s)", value, string(value))
+ } else if distance == 0 {
+ if !isIdentifierStart(value) {
+ return "", fmt.Errorf("Invalid identifier escape value: %c (%s)", value, string(value))
+ }
+ } else if distance > 0 {
+ if !isIdentifierPart(value) {
+ return "", fmt.Errorf("Invalid identifier escape value: %c (%s)", value, string(value))
+ }
+ }
+ }
+ self.read()
+ }
+ literal := string(self.str[offset:self.chrOffset])
+ if parse {
+ return parseStringLiteral(literal)
+ }
+ return literal, nil
+}
+
+// 7.2
+func isLineWhiteSpace(chr rune) bool {
+ switch chr {
+ case '\u0009', '\u000b', '\u000c', '\u0020', '\u00a0', '\ufeff':
+ return true
+ case '\u000a', '\u000d', '\u2028', '\u2029':
+ return false
+ case '\u0085':
+ return false
+ }
+ return unicode.IsSpace(chr)
+}
+
+// 7.3
+func isLineTerminator(chr rune) bool {
+ switch chr {
+ case '\u000a', '\u000d', '\u2028', '\u2029':
+ return true
+ }
+ return false
+}
+
+func (self *_parser) scan() (tkn token.Token, literal string, idx file.Idx) {
+
+ self.implicitSemicolon = false
+
+ for {
+ self.skipWhiteSpace()
+
+ idx = self.idxOf(self.chrOffset)
+ insertSemicolon := false
+
+ switch chr := self.chr; {
+ case isIdentifierStart(chr):
+ var err error
+ literal, err = self.scanIdentifier()
+ if err != nil {
+ tkn = token.ILLEGAL
+ break
+ }
+ if len(literal) > 1 {
+ // Keywords are longer than 1 character, avoid lookup otherwise
+ var strict bool
+ tkn, strict = token.IsKeyword(literal)
+
+ switch tkn {
+
+ case 0: // Not a keyword
+ if literal == "true" || literal == "false" {
+ self.insertSemicolon = true
+ tkn = token.BOOLEAN
+ return
+ } else if literal == "null" {
+ self.insertSemicolon = true
+ tkn = token.NULL
+ return
+ }
+
+ case token.KEYWORD:
+ tkn = token.KEYWORD
+ if strict {
+ // TODO If strict and in strict mode, then this is not a break
+ break
+ }
+ return
+
+ case
+ token.THIS,
+ token.BREAK,
+ token.THROW, // A newline after a throw is not allowed, but we need to detect it
+ token.RETURN,
+ token.CONTINUE,
+ token.DEBUGGER:
+ self.insertSemicolon = true
+ return
+
+ default:
+ return
+
+ }
+ }
+ self.insertSemicolon = true
+ tkn = token.IDENTIFIER
+ return
+ case '0' <= chr && chr <= '9':
+ self.insertSemicolon = true
+ tkn, literal = self.scanNumericLiteral(false)
+ return
+ default:
+ self.read()
+ switch chr {
+ case -1:
+ if self.insertSemicolon {
+ self.insertSemicolon = false
+ self.implicitSemicolon = true
+ }
+ tkn = token.EOF
+ case '\r', '\n', '\u2028', '\u2029':
+ self.insertSemicolon = false
+ self.implicitSemicolon = true
+ continue
+ case ':':
+ tkn = token.COLON
+ case '.':
+ if digitValue(self.chr) < 10 {
+ insertSemicolon = true
+ tkn, literal = self.scanNumericLiteral(true)
+ } else {
+ tkn = token.PERIOD
+ }
+ case ',':
+ tkn = token.COMMA
+ case ';':
+ tkn = token.SEMICOLON
+ case '(':
+ tkn = token.LEFT_PARENTHESIS
+ case ')':
+ tkn = token.RIGHT_PARENTHESIS
+ insertSemicolon = true
+ case '[':
+ tkn = token.LEFT_BRACKET
+ case ']':
+ tkn = token.RIGHT_BRACKET
+ insertSemicolon = true
+ case '{':
+ tkn = token.LEFT_BRACE
+ case '}':
+ tkn = token.RIGHT_BRACE
+ insertSemicolon = true
+ case '+':
+ tkn = self.switch3(token.PLUS, token.ADD_ASSIGN, '+', token.INCREMENT)
+ if tkn == token.INCREMENT {
+ insertSemicolon = true
+ }
+ case '-':
+ tkn = self.switch3(token.MINUS, token.SUBTRACT_ASSIGN, '-', token.DECREMENT)
+ if tkn == token.DECREMENT {
+ insertSemicolon = true
+ }
+ case '*':
+ tkn = self.switch2(token.MULTIPLY, token.MULTIPLY_ASSIGN)
+ case '/':
+ if self.chr == '/' {
+ self.skipSingleLineComment()
+ continue
+ } else if self.chr == '*' {
+ self.skipMultiLineComment()
+ continue
+ } else {
+ // Could be division, could be RegExp literal
+ tkn = self.switch2(token.SLASH, token.QUOTIENT_ASSIGN)
+ insertSemicolon = true
+ }
+ case '%':
+ tkn = self.switch2(token.REMAINDER, token.REMAINDER_ASSIGN)
+ case '^':
+ tkn = self.switch2(token.EXCLUSIVE_OR, token.EXCLUSIVE_OR_ASSIGN)
+ case '<':
+ tkn = self.switch4(token.LESS, token.LESS_OR_EQUAL, '<', token.SHIFT_LEFT, token.SHIFT_LEFT_ASSIGN)
+ case '>':
+ tkn = self.switch6(token.GREATER, token.GREATER_OR_EQUAL, '>', token.SHIFT_RIGHT, token.SHIFT_RIGHT_ASSIGN, '>', token.UNSIGNED_SHIFT_RIGHT, token.UNSIGNED_SHIFT_RIGHT_ASSIGN)
+ case '=':
+ tkn = self.switch2(token.ASSIGN, token.EQUAL)
+ if tkn == token.EQUAL && self.chr == '=' {
+ self.read()
+ tkn = token.STRICT_EQUAL
+ }
+ case '!':
+ tkn = self.switch2(token.NOT, token.NOT_EQUAL)
+ if tkn == token.NOT_EQUAL && self.chr == '=' {
+ self.read()
+ tkn = token.STRICT_NOT_EQUAL
+ }
+ case '&':
+ if self.chr == '^' {
+ self.read()
+ tkn = self.switch2(token.AND_NOT, token.AND_NOT_ASSIGN)
+ } else {
+ tkn = self.switch3(token.AND, token.AND_ASSIGN, '&', token.LOGICAL_AND)
+ }
+ case '|':
+ tkn = self.switch3(token.OR, token.OR_ASSIGN, '|', token.LOGICAL_OR)
+ case '~':
+ tkn = token.BITWISE_NOT
+ case '?':
+ tkn = token.QUESTION_MARK
+ case '"', '\'':
+ insertSemicolon = true
+ tkn = token.STRING
+ var err error
+ literal, err = self.scanString(self.chrOffset - 1)
+ if err != nil {
+ tkn = token.ILLEGAL
+ }
+ default:
+ self.errorUnexpected(idx, chr)
+ tkn = token.ILLEGAL
+ }
+ }
+ self.insertSemicolon = insertSemicolon
+ return
+ }
+}
+
+func (self *_parser) switch2(tkn0, tkn1 token.Token) token.Token {
+ if self.chr == '=' {
+ self.read()
+ return tkn1
+ }
+ return tkn0
+}
+
+func (self *_parser) switch3(tkn0, tkn1 token.Token, chr2 rune, tkn2 token.Token) token.Token {
+ if self.chr == '=' {
+ self.read()
+ return tkn1
+ }
+ if self.chr == chr2 {
+ self.read()
+ return tkn2
+ }
+ return tkn0
+}
+
+func (self *_parser) switch4(tkn0, tkn1 token.Token, chr2 rune, tkn2, tkn3 token.Token) token.Token {
+ if self.chr == '=' {
+ self.read()
+ return tkn1
+ }
+ if self.chr == chr2 {
+ self.read()
+ if self.chr == '=' {
+ self.read()
+ return tkn3
+ }
+ return tkn2
+ }
+ return tkn0
+}
+
+func (self *_parser) switch6(tkn0, tkn1 token.Token, chr2 rune, tkn2, tkn3 token.Token, chr3 rune, tkn4, tkn5 token.Token) token.Token {
+ if self.chr == '=' {
+ self.read()
+ return tkn1
+ }
+ if self.chr == chr2 {
+ self.read()
+ if self.chr == '=' {
+ self.read()
+ return tkn3
+ }
+ if self.chr == chr3 {
+ self.read()
+ if self.chr == '=' {
+ self.read()
+ return tkn5
+ }
+ return tkn4
+ }
+ return tkn2
+ }
+ return tkn0
+}
+
+func (self *_parser) chrAt(index int) _chr {
+ value, width := utf8.DecodeRuneInString(self.str[index:])
+ return _chr{
+ value: value,
+ width: width,
+ }
+}
+
+func (self *_parser) _peek() rune {
+ if self.offset+1 < self.length {
+ return rune(self.str[self.offset+1])
+ }
+ return -1
+}
+
+func (self *_parser) read() {
+ if self.offset < self.length {
+ self.chrOffset = self.offset
+ chr, width := rune(self.str[self.offset]), 1
+ if chr >= utf8.RuneSelf { // !ASCII
+ chr, width = utf8.DecodeRuneInString(self.str[self.offset:])
+ if chr == utf8.RuneError && width == 1 {
+ self.error(self.chrOffset, "Invalid UTF-8 character")
+ }
+ }
+ self.offset += width
+ self.chr = chr
+ } else {
+ self.chrOffset = self.length
+ self.chr = -1 // EOF
+ }
+}
+
+// This is here since the functions are so similar
+func (self *_RegExp_parser) read() {
+ if self.offset < self.length {
+ self.chrOffset = self.offset
+ chr, width := rune(self.str[self.offset]), 1
+ if chr >= utf8.RuneSelf { // !ASCII
+ chr, width = utf8.DecodeRuneInString(self.str[self.offset:])
+ if chr == utf8.RuneError && width == 1 {
+ self.error(self.chrOffset, "Invalid UTF-8 character")
+ }
+ }
+ self.offset += width
+ self.chr = chr
+ } else {
+ self.chrOffset = self.length
+ self.chr = -1 // EOF
+ }
+}
+
+func (self *_parser) skipSingleLineComment() {
+ for self.chr != -1 {
+ self.read()
+ if isLineTerminator(self.chr) {
+ return
+ }
+ }
+}
+
+func (self *_parser) skipMultiLineComment() {
+ self.read()
+ for self.chr >= 0 {
+ chr := self.chr
+ self.read()
+ if chr == '*' && self.chr == '/' {
+ self.read()
+ return
+ }
+ }
+
+ self.errorUnexpected(0, self.chr)
+}
+
+func (self *_parser) skipWhiteSpace() {
+ for {
+ switch self.chr {
+ case ' ', '\t', '\f', '\v', '\u00a0', '\ufeff':
+ self.read()
+ continue
+ case '\r':
+ if self._peek() == '\n' {
+ self.read()
+ }
+ fallthrough
+ case '\u2028', '\u2029', '\n':
+ if self.insertSemicolon {
+ return
+ }
+ self.read()
+ continue
+ }
+ if self.chr >= utf8.RuneSelf {
+ if unicode.IsSpace(self.chr) {
+ self.read()
+ continue
+ }
+ }
+ break
+ }
+}
+
+func (self *_parser) skipLineWhiteSpace() {
+ for isLineWhiteSpace(self.chr) {
+ self.read()
+ }
+}
+
+func (self *_parser) scanMantissa(base int) {
+ for digitValue(self.chr) < base {
+ self.read()
+ }
+}
+
+func (self *_parser) scanEscape(quote rune) {
+
+ var length, base uint32
+ switch self.chr {
+ //case '0', '1', '2', '3', '4', '5', '6', '7':
+ // Octal:
+ // length, base, limit = 3, 8, 255
+ case 'a', 'b', 'f', 'n', 'r', 't', 'v', '\\', '"', '\'', '0':
+ self.read()
+ return
+ case '\r', '\n', '\u2028', '\u2029':
+ self.scanNewline()
+ return
+ case 'x':
+ self.read()
+ length, base = 2, 16
+ case 'u':
+ self.read()
+ length, base = 4, 16
+ default:
+ self.read() // Always make progress
+ return
+ }
+
+ var value uint32
+ for ; length > 0 && self.chr != quote && self.chr >= 0; length-- {
+ digit := uint32(digitValue(self.chr))
+ if digit >= base {
+ break
+ }
+ value = value*base + digit
+ self.read()
+ }
+}
+
+func (self *_parser) scanString(offset int) (string, error) {
+ // " ' /
+ quote := rune(self.str[offset])
+
+ for self.chr != quote {
+ chr := self.chr
+ if chr == '\n' || chr == '\r' || chr == '\u2028' || chr == '\u2029' || chr < 0 {
+ goto newline
+ }
+ self.read()
+ if chr == '\\' {
+ if quote == '/' {
+ if self.chr == '\n' || self.chr == '\r' || self.chr == '\u2028' || self.chr == '\u2029' || self.chr < 0 {
+ goto newline
+ }
+ self.read()
+ } else {
+ self.scanEscape(quote)
+ }
+ } else if chr == '[' && quote == '/' {
+ // Allow a slash (/) in a bracket character class ([...])
+ // TODO Fix this, this is hacky...
+ quote = -1
+ } else if chr == ']' && quote == -1 {
+ quote = '/'
+ }
+ }
+
+ // " ' /
+ self.read()
+
+ return string(self.str[offset:self.chrOffset]), nil
+
+newline:
+ self.scanNewline()
+ err := "String not terminated"
+ if quote == '/' {
+ err = "Invalid regular expression: missing /"
+ self.error(self.idxOf(offset), err)
+ }
+ return "", errors.New(err)
+}
+
+func (self *_parser) scanNewline() {
+ if self.chr == '\r' {
+ self.read()
+ if self.chr != '\n' {
+ return
+ }
+ }
+ self.read()
+}
+
+func hex2decimal(chr byte) (value rune, ok bool) {
+ {
+ chr := rune(chr)
+ switch {
+ case '0' <= chr && chr <= '9':
+ return chr - '0', true
+ case 'a' <= chr && chr <= 'f':
+ return chr - 'a' + 10, true
+ case 'A' <= chr && chr <= 'F':
+ return chr - 'A' + 10, true
+ }
+ return
+ }
+}
+
+func parseNumberLiteral(literal string) (value interface{}, err error) {
+ // TODO Is Uint okay? What about -MAX_UINT
+ value, err = strconv.ParseInt(literal, 0, 64)
+ if err == nil {
+ return
+ }
+
+ parseIntErr := err // Save this first error, just in case
+
+ value, err = strconv.ParseFloat(literal, 64)
+ if err == nil {
+ return
+ } else if err.(*strconv.NumError).Err == strconv.ErrRange {
+ // Infinity, etc.
+ return value, nil
+ }
+
+ err = parseIntErr
+
+ if err.(*strconv.NumError).Err == strconv.ErrRange {
+ if len(literal) > 2 && literal[0] == '0' && (literal[1] == 'X' || literal[1] == 'x') {
+ // Could just be a very large number (e.g. 0x8000000000000000)
+ var value float64
+ literal = literal[2:]
+ for _, chr := range literal {
+ digit := digitValue(chr)
+ if digit >= 16 {
+ goto error
+ }
+ value = value*16 + float64(digit)
+ }
+ return value, nil
+ }
+ }
+
+error:
+ return nil, errors.New("Illegal numeric literal")
+}
+
+func parseStringLiteral(literal string) (string, error) {
+ // Best case scenario...
+ if literal == "" {
+ return "", nil
+ }
+
+ // Slightly less-best case scenario...
+ if !strings.ContainsRune(literal, '\\') {
+ return literal, nil
+ }
+
+ str := literal
+ buffer := bytes.NewBuffer(make([]byte, 0, 3*len(literal)/2))
+
+ for len(str) > 0 {
+ switch chr := str[0]; {
+ // We do not explicitly handle the case of the quote
+ // value, which can be: " ' /
+ // This assumes we're already passed a partially well-formed literal
+ case chr >= utf8.RuneSelf:
+ chr, size := utf8.DecodeRuneInString(str)
+ buffer.WriteRune(chr)
+ str = str[size:]
+ continue
+ case chr != '\\':
+ buffer.WriteByte(chr)
+ str = str[1:]
+ continue
+ }
+
+ if len(str) <= 1 {
+ panic("len(str) <= 1")
+ }
+ chr := str[1]
+ var value rune
+ if chr >= utf8.RuneSelf {
+ str = str[1:]
+ var size int
+ value, size = utf8.DecodeRuneInString(str)
+ str = str[size:] // \ + <character>
+ } else {
+ str = str[2:] // \<character>
+ switch chr {
+ case 'b':
+ value = '\b'
+ case 'f':
+ value = '\f'
+ case 'n':
+ value = '\n'
+ case 'r':
+ value = '\r'
+ case 't':
+ value = '\t'
+ case 'v':
+ value = '\v'
+ case 'x', 'u':
+ size := 0
+ switch chr {
+ case 'x':
+ size = 2
+ case 'u':
+ size = 4
+ }
+ if len(str) < size {
+ return "", fmt.Errorf("invalid escape: \\%s: len(%q) != %d", string(chr), str, size)
+ }
+ for j := 0; j < size; j++ {
+ decimal, ok := hex2decimal(str[j])
+ if !ok {
+ return "", fmt.Errorf("invalid escape: \\%s: %q", string(chr), str[:size])
+ }
+ value = value<<4 | decimal
+ }
+ str = str[size:]
+ if chr == 'x' {
+ break
+ }
+ if value > utf8.MaxRune {
+ panic("value > utf8.MaxRune")
+ }
+ case '0':
+ if len(str) == 0 || '0' > str[0] || str[0] > '7' {
+ value = 0
+ break
+ }
+ fallthrough
+ case '1', '2', '3', '4', '5', '6', '7':
+ // TODO strict
+ value = rune(chr) - '0'
+ j := 0
+ for ; j < 2; j++ {
+ if len(str) < j+1 {
+ break
+ }
+ chr := str[j]
+ if '0' > chr || chr > '7' {
+ break
+ }
+ decimal := rune(str[j]) - '0'
+ value = (value << 3) | decimal
+ }
+ str = str[j:]
+ case '\\':
+ value = '\\'
+ case '\'', '"':
+ value = rune(chr)
+ case '\r':
+ if len(str) > 0 {
+ if str[0] == '\n' {
+ str = str[1:]
+ }
+ }
+ fallthrough
+ case '\n':
+ continue
+ default:
+ value = rune(chr)
+ }
+ }
+ buffer.WriteRune(value)
+ }
+
+ return buffer.String(), nil
+}
+
+func (self *_parser) scanNumericLiteral(decimalPoint bool) (token.Token, string) {
+
+ offset := self.chrOffset
+ tkn := token.NUMBER
+
+ if decimalPoint {
+ offset--
+ self.scanMantissa(10)
+ goto exponent
+ }
+
+ if self.chr == '0' {
+ offset := self.chrOffset
+ self.read()
+ if self.chr == 'x' || self.chr == 'X' {
+ // Hexadecimal
+ self.read()
+ if isDigit(self.chr, 16) {
+ self.read()
+ } else {
+ return token.ILLEGAL, self.str[offset:self.chrOffset]
+ }
+ self.scanMantissa(16)
+
+ if self.chrOffset-offset <= 2 {
+ // Only "0x" or "0X"
+ self.error(0, "Illegal hexadecimal number")
+ }
+
+ goto hexadecimal
+ } else if self.chr == '.' {
+ // Float
+ goto float
+ } else {
+ // Octal, Float
+ if self.chr == 'e' || self.chr == 'E' {
+ goto exponent
+ }
+ self.scanMantissa(8)
+ if self.chr == '8' || self.chr == '9' {
+ return token.ILLEGAL, self.str[offset:self.chrOffset]
+ }
+ goto octal
+ }
+ }
+
+ self.scanMantissa(10)
+
+float:
+ if self.chr == '.' {
+ self.read()
+ self.scanMantissa(10)
+ }
+
+exponent:
+ if self.chr == 'e' || self.chr == 'E' {
+ self.read()
+ if self.chr == '-' || self.chr == '+' {
+ self.read()
+ }
+ if isDecimalDigit(self.chr) {
+ self.read()
+ self.scanMantissa(10)
+ } else {
+ return token.ILLEGAL, self.str[offset:self.chrOffset]
+ }
+ }
+
+hexadecimal:
+octal:
+ if isIdentifierStart(self.chr) || isDecimalDigit(self.chr) {
+ return token.ILLEGAL, self.str[offset:self.chrOffset]
+ }
+
+ return tkn, self.str[offset:self.chrOffset]
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/parser/lexer_test.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/parser/lexer_test.go
new file mode 100644
index 000000000..37eb7a464
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/parser/lexer_test.go
@@ -0,0 +1,380 @@
+package parser
+
+import (
+ "../terst"
+ "testing"
+
+ "github.com/robertkrimen/otto/file"
+ "github.com/robertkrimen/otto/token"
+)
+
+var tt = terst.Terst
+var is = terst.Is
+
+func TestLexer(t *testing.T) {
+ tt(t, func() {
+ setup := func(src string) *_parser {
+ parser := newParser("", src)
+ return parser
+ }
+
+ test := func(src string, test ...interface{}) {
+ parser := setup(src)
+ for len(test) > 0 {
+ tkn, literal, idx := parser.scan()
+ if len(test) > 0 {
+ is(tkn, test[0].(token.Token))
+ test = test[1:]
+ }
+ if len(test) > 0 {
+ is(literal, test[0].(string))
+ test = test[1:]
+ }
+ if len(test) > 0 {
+ // FIXME terst, Fix this so that cast to file.Idx is not necessary?
+ is(idx, file.Idx(test[0].(int)))
+ test = test[1:]
+ }
+ }
+ }
+
+ test("",
+ token.EOF, "", 1,
+ )
+
+ test("1",
+ token.NUMBER, "1", 1,
+ token.EOF, "", 2,
+ )
+
+ test(".0",
+ token.NUMBER, ".0", 1,
+ token.EOF, "", 3,
+ )
+
+ test("abc",
+ token.IDENTIFIER, "abc", 1,
+ token.EOF, "", 4,
+ )
+
+ test("abc(1)",
+ token.IDENTIFIER, "abc", 1,
+ token.LEFT_PARENTHESIS, "", 4,
+ token.NUMBER, "1", 5,
+ token.RIGHT_PARENTHESIS, "", 6,
+ token.EOF, "", 7,
+ )
+
+ test(".",
+ token.PERIOD, "", 1,
+ token.EOF, "", 2,
+ )
+
+ test("===.",
+ token.STRICT_EQUAL, "", 1,
+ token.PERIOD, "", 4,
+ token.EOF, "", 5,
+ )
+
+ test(">>>=.0",
+ token.UNSIGNED_SHIFT_RIGHT_ASSIGN, "", 1,
+ token.NUMBER, ".0", 5,
+ token.EOF, "", 7,
+ )
+
+ test(">>>=0.0.",
+ token.UNSIGNED_SHIFT_RIGHT_ASSIGN, "", 1,
+ token.NUMBER, "0.0", 5,
+ token.PERIOD, "", 8,
+ token.EOF, "", 9,
+ )
+
+ test("\"abc\"",
+ token.STRING, "\"abc\"", 1,
+ token.EOF, "", 6,
+ )
+
+ test("abc = //",
+ token.IDENTIFIER, "abc", 1,
+ token.ASSIGN, "", 5,
+ token.EOF, "", 9,
+ )
+
+ test("abc = 1 / 2",
+ token.IDENTIFIER, "abc", 1,
+ token.ASSIGN, "", 5,
+ token.NUMBER, "1", 7,
+ token.SLASH, "", 9,
+ token.NUMBER, "2", 11,
+ token.EOF, "", 12,
+ )
+
+ test("xyzzy = 'Nothing happens.'",
+ token.IDENTIFIER, "xyzzy", 1,
+ token.ASSIGN, "", 7,
+ token.STRING, "'Nothing happens.'", 9,
+ token.EOF, "", 27,
+ )
+
+ test("abc = !false",
+ token.IDENTIFIER, "abc", 1,
+ token.ASSIGN, "", 5,
+ token.NOT, "", 7,
+ token.BOOLEAN, "false", 8,
+ token.EOF, "", 13,
+ )
+
+ test("abc = !!true",
+ token.IDENTIFIER, "abc", 1,
+ token.ASSIGN, "", 5,
+ token.NOT, "", 7,
+ token.NOT, "", 8,
+ token.BOOLEAN, "true", 9,
+ token.EOF, "", 13,
+ )
+
+ test("abc *= 1",
+ token.IDENTIFIER, "abc", 1,
+ token.MULTIPLY_ASSIGN, "", 5,
+ token.NUMBER, "1", 8,
+ token.EOF, "", 9,
+ )
+
+ test("if 1 else",
+ token.IF, "if", 1,
+ token.NUMBER, "1", 4,
+ token.ELSE, "else", 6,
+ token.EOF, "", 10,
+ )
+
+ test("null",
+ token.NULL, "null", 1,
+ token.EOF, "", 5,
+ )
+
+ test(`"\u007a\x79\u000a\x78"`,
+ token.STRING, "\"\\u007a\\x79\\u000a\\x78\"", 1,
+ token.EOF, "", 23,
+ )
+
+ test(`"[First line \
+Second line \
+ Third line\
+. ]"
+ `,
+ token.STRING, "\"[First line \\\nSecond line \\\n Third line\\\n. ]\"", 1,
+ token.EOF, "", 53,
+ )
+
+ test("/",
+ token.SLASH, "", 1,
+ token.EOF, "", 2,
+ )
+
+ test("var abc = \"abc\uFFFFabc\"",
+ token.VAR, "var", 1,
+ token.IDENTIFIER, "abc", 5,
+ token.ASSIGN, "", 9,
+ token.STRING, "\"abc\uFFFFabc\"", 11,
+ token.EOF, "", 22,
+ )
+
+ test(`'\t' === '\r'`,
+ token.STRING, "'\\t'", 1,
+ token.STRICT_EQUAL, "", 6,
+ token.STRING, "'\\r'", 10,
+ token.EOF, "", 14,
+ )
+
+ test(`var \u0024 = 1`,
+ token.VAR, "var", 1,
+ token.IDENTIFIER, "$", 5,
+ token.ASSIGN, "", 12,
+ token.NUMBER, "1", 14,
+ token.EOF, "", 15,
+ )
+
+ test("10e10000",
+ token.NUMBER, "10e10000", 1,
+ token.EOF, "", 9,
+ )
+
+ test(`var if var class`,
+ token.VAR, "var", 1,
+ token.IF, "if", 5,
+ token.VAR, "var", 8,
+ token.KEYWORD, "class", 12,
+ token.EOF, "", 17,
+ )
+
+ test(`-0`,
+ token.MINUS, "", 1,
+ token.NUMBER, "0", 2,
+ token.EOF, "", 3,
+ )
+
+ test(`.01`,
+ token.NUMBER, ".01", 1,
+ token.EOF, "", 4,
+ )
+
+ test(`.01e+2`,
+ token.NUMBER, ".01e+2", 1,
+ token.EOF, "", 7,
+ )
+
+ test(";",
+ token.SEMICOLON, "", 1,
+ token.EOF, "", 2,
+ )
+
+ test(";;",
+ token.SEMICOLON, "", 1,
+ token.SEMICOLON, "", 2,
+ token.EOF, "", 3,
+ )
+
+ test("//",
+ token.EOF, "", 3,
+ )
+
+ test(";;//",
+ token.SEMICOLON, "", 1,
+ token.SEMICOLON, "", 2,
+ token.EOF, "", 5,
+ )
+
+ test("1",
+ token.NUMBER, "1", 1,
+ )
+
+ test("12 123",
+ token.NUMBER, "12", 1,
+ token.NUMBER, "123", 4,
+ )
+
+ test("1.2 12.3",
+ token.NUMBER, "1.2", 1,
+ token.NUMBER, "12.3", 5,
+ )
+
+ test("/ /=",
+ token.SLASH, "", 1,
+ token.QUOTIENT_ASSIGN, "", 3,
+ )
+
+ test(`"abc"`,
+ token.STRING, `"abc"`, 1,
+ )
+
+ test(`'abc'`,
+ token.STRING, `'abc'`, 1,
+ )
+
+ test("++",
+ token.INCREMENT, "", 1,
+ )
+
+ test(">",
+ token.GREATER, "", 1,
+ )
+
+ test(">=",
+ token.GREATER_OR_EQUAL, "", 1,
+ )
+
+ test(">>",
+ token.SHIFT_RIGHT, "", 1,
+ )
+
+ test(">>=",
+ token.SHIFT_RIGHT_ASSIGN, "", 1,
+ )
+
+ test(">>>",
+ token.UNSIGNED_SHIFT_RIGHT, "", 1,
+ )
+
+ test(">>>=",
+ token.UNSIGNED_SHIFT_RIGHT_ASSIGN, "", 1,
+ )
+
+ test("1 \"abc\"",
+ token.NUMBER, "1", 1,
+ token.STRING, "\"abc\"", 3,
+ )
+
+ test(",",
+ token.COMMA, "", 1,
+ )
+
+ test("1, \"abc\"",
+ token.NUMBER, "1", 1,
+ token.COMMA, "", 2,
+ token.STRING, "\"abc\"", 4,
+ )
+
+ test("new abc(1, 3.14159);",
+ token.NEW, "new", 1,
+ token.IDENTIFIER, "abc", 5,
+ token.LEFT_PARENTHESIS, "", 8,
+ token.NUMBER, "1", 9,
+ token.COMMA, "", 10,
+ token.NUMBER, "3.14159", 12,
+ token.RIGHT_PARENTHESIS, "", 19,
+ token.SEMICOLON, "", 20,
+ )
+
+ test("1 == \"1\"",
+ token.NUMBER, "1", 1,
+ token.EQUAL, "", 3,
+ token.STRING, "\"1\"", 6,
+ )
+
+ test("1\n[]\n",
+ token.NUMBER, "1", 1,
+ token.LEFT_BRACKET, "", 3,
+ token.RIGHT_BRACKET, "", 4,
+ )
+
+ test("1\ufeff[]\ufeff",
+ token.NUMBER, "1", 1,
+ token.LEFT_BRACKET, "", 5,
+ token.RIGHT_BRACKET, "", 6,
+ )
+
+ // ILLEGAL
+
+ test(`3ea`,
+ token.ILLEGAL, "3e", 1,
+ token.IDENTIFIER, "a", 3,
+ token.EOF, "", 4,
+ )
+
+ test(`3in`,
+ token.ILLEGAL, "3", 1,
+ token.IN, "in", 2,
+ token.EOF, "", 4,
+ )
+
+ test("\"Hello\nWorld\"",
+ token.ILLEGAL, "", 1,
+ token.IDENTIFIER, "World", 8,
+ token.ILLEGAL, "", 13,
+ token.EOF, "", 14,
+ )
+
+ test("\u203f = 10",
+ token.ILLEGAL, "", 1,
+ token.ASSIGN, "", 5,
+ token.NUMBER, "10", 7,
+ token.EOF, "", 9,
+ )
+
+ test(`"\x0G"`,
+ token.STRING, "\"\\x0G\"", 1,
+ token.EOF, "", 7,
+ )
+
+ })
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/parser/marshal_test.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/parser/marshal_test.go
new file mode 100644
index 000000000..f54cd2d4f
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/parser/marshal_test.go
@@ -0,0 +1,930 @@
+package parser
+
+import (
+ "bytes"
+ "encoding/json"
+ "fmt"
+ "os"
+ "reflect"
+ "strings"
+ "testing"
+
+ "github.com/robertkrimen/otto/ast"
+)
+
+func marshal(name string, children ...interface{}) interface{} {
+ if len(children) == 1 {
+ if name == "" {
+ return testMarshalNode(children[0])
+ }
+ return map[string]interface{}{
+ name: children[0],
+ }
+ }
+ map_ := map[string]interface{}{}
+ length := len(children) / 2
+ for i := 0; i < length; i++ {
+ name := children[i*2].(string)
+ value := children[i*2+1]
+ map_[name] = value
+ }
+ if name == "" {
+ return map_
+ }
+ return map[string]interface{}{
+ name: map_,
+ }
+}
+
+func testMarshalNode(node interface{}) interface{} {
+ switch node := node.(type) {
+
+ // Expression
+
+ case *ast.ArrayLiteral:
+ return marshal("Array", testMarshalNode(node.Value))
+
+ case *ast.AssignExpression:
+ return marshal("Assign",
+ "Left", testMarshalNode(node.Left),
+ "Right", testMarshalNode(node.Right),
+ )
+
+ case *ast.BinaryExpression:
+ return marshal("BinaryExpression",
+ "Operator", node.Operator.String(),
+ "Left", testMarshalNode(node.Left),
+ "Right", testMarshalNode(node.Right),
+ )
+
+ case *ast.BooleanLiteral:
+ return marshal("Literal", node.Value)
+
+ case *ast.CallExpression:
+ return marshal("Call",
+ "Callee", testMarshalNode(node.Callee),
+ "ArgumentList", testMarshalNode(node.ArgumentList),
+ )
+
+ case *ast.ConditionalExpression:
+ return marshal("Conditional",
+ "Test", testMarshalNode(node.Test),
+ "Consequent", testMarshalNode(node.Consequent),
+ "Alternate", testMarshalNode(node.Alternate),
+ )
+
+ case *ast.DotExpression:
+ return marshal("Dot",
+ "Left", testMarshalNode(node.Left),
+ "Member", node.Identifier.Name,
+ )
+
+ case *ast.NewExpression:
+ return marshal("New",
+ "Callee", testMarshalNode(node.Callee),
+ "ArgumentList", testMarshalNode(node.ArgumentList),
+ )
+
+ case *ast.NullLiteral:
+ return marshal("Literal", nil)
+
+ case *ast.NumberLiteral:
+ return marshal("Literal", node.Value)
+
+ case *ast.ObjectLiteral:
+ return marshal("Object", testMarshalNode(node.Value))
+
+ case *ast.RegExpLiteral:
+ return marshal("Literal", node.Literal)
+
+ case *ast.StringLiteral:
+ return marshal("Literal", node.Literal)
+
+ case *ast.VariableExpression:
+ return []interface{}{node.Name, testMarshalNode(node.Initializer)}
+
+ // Statement
+
+ case *ast.Program:
+ return testMarshalNode(node.Body)
+
+ case *ast.BlockStatement:
+ return marshal("BlockStatement", testMarshalNode(node.List))
+
+ case *ast.EmptyStatement:
+ return "EmptyStatement"
+
+ case *ast.ExpressionStatement:
+ return testMarshalNode(node.Expression)
+
+ case *ast.ForInStatement:
+ return marshal("ForIn",
+ "Into", marshal("", node.Into),
+ "Source", marshal("", node.Source),
+ "Body", marshal("", node.Body),
+ )
+
+ case *ast.FunctionLiteral:
+ return marshal("Function", testMarshalNode(node.Body))
+
+ case *ast.Identifier:
+ return marshal("Identifier", node.Name)
+
+ case *ast.IfStatement:
+ if_ := marshal("",
+ "Test", testMarshalNode(node.Test),
+ "Consequent", testMarshalNode(node.Consequent),
+ ).(map[string]interface{})
+ if node.Alternate != nil {
+ if_["Alternate"] = testMarshalNode(node.Alternate)
+ }
+ return marshal("If", if_)
+
+ case *ast.LabelledStatement:
+ return marshal("Label",
+ "Name", node.Label.Name,
+ "Statement", testMarshalNode(node.Statement),
+ )
+ case ast.Property:
+ return marshal("",
+ "Key", node.Key,
+ "Value", testMarshalNode(node.Value),
+ )
+
+ case *ast.ReturnStatement:
+ return marshal("Return", testMarshalNode(node.Argument))
+
+ case *ast.SequenceExpression:
+ return marshal("Sequence", testMarshalNode(node.Sequence))
+
+ case *ast.ThrowStatement:
+ return marshal("Throw", testMarshalNode(node.Argument))
+
+ case *ast.VariableStatement:
+ return marshal("Var", testMarshalNode(node.List))
+
+ }
+
+ {
+ value := reflect.ValueOf(node)
+ if value.Kind() == reflect.Slice {
+ tmp0 := []interface{}{}
+ for index := 0; index < value.Len(); index++ {
+ tmp0 = append(tmp0, testMarshalNode(value.Index(index).Interface()))
+ }
+ return tmp0
+ }
+ }
+
+ if node != nil {
+ fmt.Fprintf(os.Stderr, "testMarshalNode(%T)\n", node)
+ }
+
+ return nil
+}
+
+func testMarshal(node interface{}) string {
+ value, err := json.Marshal(testMarshalNode(node))
+ if err != nil {
+ panic(err)
+ }
+ return string(value)
+}
+
+func TestParserAST(t *testing.T) {
+ tt(t, func() {
+
+ test := func(inputOutput string) {
+ match := matchBeforeAfterSeparator.FindStringIndex(inputOutput)
+ input := strings.TrimSpace(inputOutput[0:match[0]])
+ wantOutput := strings.TrimSpace(inputOutput[match[1]:])
+ _, program, err := testParse(input)
+ is(err, nil)
+ haveOutput := testMarshal(program)
+ tmp0, tmp1 := bytes.Buffer{}, bytes.Buffer{}
+ json.Indent(&tmp0, []byte(haveOutput), "\t\t", " ")
+ json.Indent(&tmp1, []byte(wantOutput), "\t\t", " ")
+ is("\n\t\t"+tmp0.String(), "\n\t\t"+tmp1.String())
+ }
+
+ test(`
+ ---
+[]
+ `)
+
+ test(`
+ ;
+ ---
+[
+ "EmptyStatement"
+]
+ `)
+
+ test(`
+ ;;;
+ ---
+[
+ "EmptyStatement",
+ "EmptyStatement",
+ "EmptyStatement"
+]
+ `)
+
+ test(`
+ 1; true; abc; "abc"; null;
+ ---
+[
+ {
+ "Literal": 1
+ },
+ {
+ "Literal": true
+ },
+ {
+ "Identifier": "abc"
+ },
+ {
+ "Literal": "\"abc\""
+ },
+ {
+ "Literal": null
+ }
+]
+ `)
+
+ test(`
+ { 1; null; 3.14159; ; }
+ ---
+[
+ {
+ "BlockStatement": [
+ {
+ "Literal": 1
+ },
+ {
+ "Literal": null
+ },
+ {
+ "Literal": 3.14159
+ },
+ "EmptyStatement"
+ ]
+ }
+]
+ `)
+
+ test(`
+ new abc();
+ ---
+[
+ {
+ "New": {
+ "ArgumentList": [],
+ "Callee": {
+ "Identifier": "abc"
+ }
+ }
+ }
+]
+ `)
+
+ test(`
+ new abc(1, 3.14159)
+ ---
+[
+ {
+ "New": {
+ "ArgumentList": [
+ {
+ "Literal": 1
+ },
+ {
+ "Literal": 3.14159
+ }
+ ],
+ "Callee": {
+ "Identifier": "abc"
+ }
+ }
+ }
+]
+ `)
+
+ test(`
+ true ? false : true
+ ---
+[
+ {
+ "Conditional": {
+ "Alternate": {
+ "Literal": true
+ },
+ "Consequent": {
+ "Literal": false
+ },
+ "Test": {
+ "Literal": true
+ }
+ }
+ }
+]
+ `)
+
+ test(`
+ true || false
+ ---
+[
+ {
+ "BinaryExpression": {
+ "Left": {
+ "Literal": true
+ },
+ "Operator": "||",
+ "Right": {
+ "Literal": false
+ }
+ }
+ }
+]
+ `)
+
+ test(`
+ 0 + { abc: true }
+ ---
+[
+ {
+ "BinaryExpression": {
+ "Left": {
+ "Literal": 0
+ },
+ "Operator": "+",
+ "Right": {
+ "Object": [
+ {
+ "Key": "abc",
+ "Value": {
+ "Literal": true
+ }
+ }
+ ]
+ }
+ }
+ }
+]
+ `)
+
+ test(`
+ 1 == "1"
+ ---
+[
+ {
+ "BinaryExpression": {
+ "Left": {
+ "Literal": 1
+ },
+ "Operator": "==",
+ "Right": {
+ "Literal": "\"1\""
+ }
+ }
+ }
+]
+ `)
+
+ test(`
+ abc(1)
+ ---
+[
+ {
+ "Call": {
+ "ArgumentList": [
+ {
+ "Literal": 1
+ }
+ ],
+ "Callee": {
+ "Identifier": "abc"
+ }
+ }
+ }
+]
+ `)
+
+ test(`
+ Math.pow(3, 2)
+ ---
+[
+ {
+ "Call": {
+ "ArgumentList": [
+ {
+ "Literal": 3
+ },
+ {
+ "Literal": 2
+ }
+ ],
+ "Callee": {
+ "Dot": {
+ "Left": {
+ "Identifier": "Math"
+ },
+ "Member": "pow"
+ }
+ }
+ }
+ }
+]
+ `)
+
+ test(`
+ 1, 2, 3
+ ---
+[
+ {
+ "Sequence": [
+ {
+ "Literal": 1
+ },
+ {
+ "Literal": 2
+ },
+ {
+ "Literal": 3
+ }
+ ]
+ }
+]
+ `)
+
+ test(`
+ / abc / gim;
+ ---
+[
+ {
+ "Literal": "/ abc / gim"
+ }
+]
+ `)
+
+ test(`
+ if (0)
+ 1;
+ ---
+[
+ {
+ "If": {
+ "Consequent": {
+ "Literal": 1
+ },
+ "Test": {
+ "Literal": 0
+ }
+ }
+ }
+]
+ `)
+
+ test(`
+ 0+function(){
+ return;
+ }
+ ---
+[
+ {
+ "BinaryExpression": {
+ "Left": {
+ "Literal": 0
+ },
+ "Operator": "+",
+ "Right": {
+ "Function": {
+ "BlockStatement": [
+ {
+ "Return": null
+ }
+ ]
+ }
+ }
+ }
+ }
+]
+ `)
+
+ test(`
+ xyzzy // Ignore it
+ // Ignore this
+ // And this
+ /* And all..
+
+
+
+ ... of this!
+ */
+ "Nothing happens."
+ // And finally this
+ ---
+[
+ {
+ "Identifier": "xyzzy"
+ },
+ {
+ "Literal": "\"Nothing happens.\""
+ }
+]
+ `)
+
+ test(`
+ ((x & (x = 1)) !== 0)
+ ---
+[
+ {
+ "BinaryExpression": {
+ "Left": {
+ "BinaryExpression": {
+ "Left": {
+ "Identifier": "x"
+ },
+ "Operator": "\u0026",
+ "Right": {
+ "Assign": {
+ "Left": {
+ "Identifier": "x"
+ },
+ "Right": {
+ "Literal": 1
+ }
+ }
+ }
+ }
+ },
+ "Operator": "!==",
+ "Right": {
+ "Literal": 0
+ }
+ }
+ }
+]
+ `)
+
+ test(`
+ { abc: 'def' }
+ ---
+[
+ {
+ "BlockStatement": [
+ {
+ "Label": {
+ "Name": "abc",
+ "Statement": {
+ "Literal": "'def'"
+ }
+ }
+ }
+ ]
+ }
+]
+ `)
+
+ test(`
+ // This is not an object, this is a string literal with a label!
+ ({ abc: 'def' })
+ ---
+[
+ {
+ "Object": [
+ {
+ "Key": "abc",
+ "Value": {
+ "Literal": "'def'"
+ }
+ }
+ ]
+ }
+]
+ `)
+
+ test(`
+ [,]
+ ---
+[
+ {
+ "Array": [
+ null
+ ]
+ }
+]
+ `)
+
+ test(`
+ [,,]
+ ---
+[
+ {
+ "Array": [
+ null,
+ null
+ ]
+ }
+]
+ `)
+
+ test(`
+ ({ get abc() {} })
+ ---
+[
+ {
+ "Object": [
+ {
+ "Key": "abc",
+ "Value": {
+ "Function": {
+ "BlockStatement": []
+ }
+ }
+ }
+ ]
+ }
+]
+ `)
+
+ test(`
+ /abc/.source
+ ---
+[
+ {
+ "Dot": {
+ "Left": {
+ "Literal": "/abc/"
+ },
+ "Member": "source"
+ }
+ }
+]
+ `)
+
+ test(`
+ xyzzy
+
+ throw new TypeError("Nothing happens.")
+ ---
+[
+ {
+ "Identifier": "xyzzy"
+ },
+ {
+ "Throw": {
+ "New": {
+ "ArgumentList": [
+ {
+ "Literal": "\"Nothing happens.\""
+ }
+ ],
+ "Callee": {
+ "Identifier": "TypeError"
+ }
+ }
+ }
+ }
+]
+ `)
+
+ // When run, this will call a type error to be thrown
+ // This is essentially the same as:
+ //
+ // var abc = 1(function(){})()
+ //
+ test(`
+ var abc = 1
+ (function(){
+ })()
+ ---
+[
+ {
+ "Var": [
+ [
+ "abc",
+ {
+ "Call": {
+ "ArgumentList": [],
+ "Callee": {
+ "Call": {
+ "ArgumentList": [
+ {
+ "Function": {
+ "BlockStatement": []
+ }
+ }
+ ],
+ "Callee": {
+ "Literal": 1
+ }
+ }
+ }
+ }
+ }
+ ]
+ ]
+ }
+]
+ `)
+
+ test(`
+ "use strict"
+ ---
+[
+ {
+ "Literal": "\"use strict\""
+ }
+]
+ `)
+
+ test(`
+ "use strict"
+ abc = 1 + 2 + 11
+ ---
+[
+ {
+ "Literal": "\"use strict\""
+ },
+ {
+ "Assign": {
+ "Left": {
+ "Identifier": "abc"
+ },
+ "Right": {
+ "BinaryExpression": {
+ "Left": {
+ "BinaryExpression": {
+ "Left": {
+ "Literal": 1
+ },
+ "Operator": "+",
+ "Right": {
+ "Literal": 2
+ }
+ }
+ },
+ "Operator": "+",
+ "Right": {
+ "Literal": 11
+ }
+ }
+ }
+ }
+ }
+]
+ `)
+
+ test(`
+ abc = function() { 'use strict' }
+ ---
+[
+ {
+ "Assign": {
+ "Left": {
+ "Identifier": "abc"
+ },
+ "Right": {
+ "Function": {
+ "BlockStatement": [
+ {
+ "Literal": "'use strict'"
+ }
+ ]
+ }
+ }
+ }
+ }
+]
+ `)
+
+ test(`
+ for (var abc in def) {
+ }
+ ---
+[
+ {
+ "ForIn": {
+ "Body": {
+ "BlockStatement": []
+ },
+ "Into": [
+ "abc",
+ null
+ ],
+ "Source": {
+ "Identifier": "def"
+ }
+ }
+ }
+]
+ `)
+
+ test(`
+ abc = {
+ '"': "'",
+ "'": '"',
+ }
+ ---
+[
+ {
+ "Assign": {
+ "Left": {
+ "Identifier": "abc"
+ },
+ "Right": {
+ "Object": [
+ {
+ "Key": "\"",
+ "Value": {
+ "Literal": "\"'\""
+ }
+ },
+ {
+ "Key": "'",
+ "Value": {
+ "Literal": "'\"'"
+ }
+ }
+ ]
+ }
+ }
+ }
+]
+ `)
+
+ return
+
+ test(`
+ if (!abc && abc.jkl(def) && abc[0] === +abc[0] && abc.length < ghi) {
+ }
+ ---
+[
+ {
+ "If": {
+ "Consequent": {
+ "BlockStatement": []
+ },
+ "Test": {
+ "BinaryExpression": {
+ "Left": {
+ "BinaryExpression": {
+ "Left": {
+ "BinaryExpression": {
+ "Left": null,
+ "Operator": "\u0026\u0026",
+ "Right": {
+ "Call": {
+ "ArgumentList": [
+ {
+ "Identifier": "def"
+ }
+ ],
+ "Callee": {
+ "Dot": {
+ "Left": {
+ "Identifier": "abc"
+ },
+ "Member": "jkl"
+ }
+ }
+ }
+ }
+ }
+ },
+ "Operator": "\u0026\u0026",
+ "Right": {
+ "BinaryExpression": {
+ "Left": null,
+ "Operator": "===",
+ "Right": null
+ }
+ }
+ }
+ },
+ "Operator": "\u0026\u0026",
+ "Right": {
+ "BinaryExpression": {
+ "Left": {
+ "Dot": {
+ "Left": {
+ "Identifier": "abc"
+ },
+ "Member": "length"
+ }
+ },
+ "Operator": "\u003c",
+ "Right": {
+ "Identifier": "ghi"
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+]
+ `)
+ })
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/parser/parser.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/parser/parser.go
new file mode 100644
index 000000000..1536344d7
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/parser/parser.go
@@ -0,0 +1,273 @@
+/*
+Package parser implements a parser for JavaScript.
+
+ import (
+ "github.com/robertkrimen/otto/parser"
+ )
+
+Parse and return an AST
+
+ filename := "" // A filename is optional
+ src := `
+ // Sample xyzzy example
+ (function(){
+ if (3.14159 > 0) {
+ console.log("Hello, World.");
+ return;
+ }
+
+ var xyzzy = NaN;
+ console.log("Nothing happens.");
+ return xyzzy;
+ })();
+ `
+
+ // Parse some JavaScript, yielding a *ast.Program and/or an ErrorList
+ program, err := parser.ParseFile(nil, filename, src, 0)
+
+Warning
+
+The parser and AST interfaces are still works-in-progress (particularly where
+node types are concerned) and may change in the future.
+
+*/
+package parser
+
+import (
+ "bytes"
+ "errors"
+ "io"
+ "io/ioutil"
+
+ "github.com/robertkrimen/otto/ast"
+ "github.com/robertkrimen/otto/file"
+ "github.com/robertkrimen/otto/token"
+)
+
+// A Mode value is a set of flags (or 0). They control optional parser functionality.
+type Mode uint
+
+const (
+ IgnoreRegExpErrors Mode = 1 << iota // Ignore RegExp compatibility errors (allow backtracking)
+)
+
+type _parser struct {
+ filename string
+ str string
+ length int
+ base int
+
+ chr rune // The current character
+ chrOffset int // The offset of current character
+ offset int // The offset after current character (may be greater than 1)
+
+ idx file.Idx // The index of token
+ token token.Token // The token
+ literal string // The literal of the token, if any
+
+ scope *_scope
+ insertSemicolon bool // If we see a newline, then insert an implicit semicolon
+ implicitSemicolon bool // An implicit semicolon exists
+
+ errors ErrorList
+
+ recover struct {
+ // Scratch when trying to seek to the next statement, etc.
+ idx file.Idx
+ count int
+ }
+
+ mode Mode
+
+ file *file.File
+}
+
+func _newParser(filename, src string, base int) *_parser {
+ return &_parser{
+ chr: ' ', // This is set so we can start scanning by skipping whitespace
+ str: src,
+ length: len(src),
+ base: base,
+ file: file.NewFile(filename, src, base),
+ }
+}
+
+func newParser(filename, src string) *_parser {
+ return _newParser(filename, src, 1)
+}
+
+func ReadSource(filename string, src interface{}) ([]byte, error) {
+ if src != nil {
+ switch src := src.(type) {
+ case string:
+ return []byte(src), nil
+ case []byte:
+ return src, nil
+ case *bytes.Buffer:
+ if src != nil {
+ return src.Bytes(), nil
+ }
+ case io.Reader:
+ var bfr bytes.Buffer
+ if _, err := io.Copy(&bfr, src); err != nil {
+ return nil, err
+ }
+ return bfr.Bytes(), nil
+ }
+ return nil, errors.New("invalid source")
+ }
+ return ioutil.ReadFile(filename)
+}
+
+// ParseFile parses the source code of a single JavaScript/ECMAScript source file and returns
+// the corresponding ast.Program node.
+//
+// If fileSet == nil, ParseFile parses source without a FileSet.
+// If fileSet != nil, ParseFile first adds filename and src to fileSet.
+//
+// The filename argument is optional and is used for labelling errors, etc.
+//
+// src may be a string, a byte slice, a bytes.Buffer, or an io.Reader, but it MUST always be in UTF-8.
+//
+// // Parse some JavaScript, yielding a *ast.Program and/or an ErrorList
+// program, err := parser.ParseFile(nil, "", `if (abc > 1) {}`, 0)
+//
+func ParseFile(fileSet *file.FileSet, filename string, src interface{}, mode Mode) (*ast.Program, error) {
+ str, err := ReadSource(filename, src)
+ if err != nil {
+ return nil, err
+ }
+ {
+ str := string(str)
+
+ base := 1
+ if fileSet != nil {
+ base = fileSet.AddFile(filename, str)
+ }
+
+ parser := _newParser(filename, str, base)
+ parser.mode = mode
+ return parser.parse()
+ }
+}
+
+// ParseFunction parses a given parameter list and body as a function and returns the
+// corresponding ast.FunctionLiteral node.
+//
+// The parameter list, if any, should be a comma-separated list of identifiers.
+//
+func ParseFunction(parameterList, body string) (*ast.FunctionLiteral, error) {
+
+ src := "(function(" + parameterList + ") {\n" + body + "\n})"
+
+ parser := _newParser("", src, 1)
+ program, err := parser.parse()
+ if err != nil {
+ return nil, err
+ }
+
+ return program.Body[0].(*ast.ExpressionStatement).Expression.(*ast.FunctionLiteral), nil
+}
+
+func (self *_parser) slice(idx0, idx1 file.Idx) string {
+ from := int(idx0) - self.base
+ to := int(idx1) - self.base
+ if from >= 0 && to <= len(self.str) {
+ return self.str[from:to]
+ }
+
+ return ""
+}
+
+func (self *_parser) parse() (*ast.Program, error) {
+ self.next()
+ program := self.parseProgram()
+ if false {
+ self.errors.Sort()
+ }
+ return program, self.errors.Err()
+}
+
+func (self *_parser) next() {
+ self.token, self.literal, self.idx = self.scan()
+}
+
+func (self *_parser) optionalSemicolon() {
+ if self.token == token.SEMICOLON {
+ self.next()
+ return
+ }
+
+ if self.implicitSemicolon {
+ self.implicitSemicolon = false
+ return
+ }
+
+ if self.token != token.EOF && self.token != token.RIGHT_BRACE {
+ self.expect(token.SEMICOLON)
+ }
+}
+
+func (self *_parser) semicolon() {
+ if self.token != token.RIGHT_PARENTHESIS && self.token != token.RIGHT_BRACE {
+ if self.implicitSemicolon {
+ self.implicitSemicolon = false
+ return
+ }
+
+ self.expect(token.SEMICOLON)
+ }
+}
+
+func (self *_parser) idxOf(offset int) file.Idx {
+ return file.Idx(self.base + offset)
+}
+
+func (self *_parser) expect(value token.Token) file.Idx {
+ idx := self.idx
+ if self.token != value {
+ self.errorUnexpectedToken(self.token)
+ }
+ self.next()
+ return idx
+}
+
+func lineCount(str string) (int, int) {
+ line, last := 0, -1
+ pair := false
+ for index, chr := range str {
+ switch chr {
+ case '\r':
+ line += 1
+ last = index
+ pair = true
+ continue
+ case '\n':
+ if !pair {
+ line += 1
+ }
+ last = index
+ case '\u2028', '\u2029':
+ line += 1
+ last = index + 2
+ }
+ pair = false
+ }
+ return line, last
+}
+
+func (self *_parser) position(idx file.Idx) file.Position {
+ position := file.Position{}
+ offset := int(idx) - self.base
+ str := self.str[:offset]
+ position.Filename = self.filename
+ line, last := lineCount(str)
+ position.Line = 1 + line
+ if last >= 0 {
+ position.Column = offset - last
+ } else {
+ position.Column = 1 + len(str)
+ }
+
+ return position
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/parser/parser_test.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/parser/parser_test.go
new file mode 100644
index 000000000..8f9457745
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/parser/parser_test.go
@@ -0,0 +1,1004 @@
+package parser
+
+import (
+ "errors"
+ "regexp"
+ "strings"
+ "testing"
+
+ "github.com/robertkrimen/otto/ast"
+ "github.com/robertkrimen/otto/file"
+)
+
+func firstErr(err error) error {
+ switch err := err.(type) {
+ case ErrorList:
+ return err[0]
+ }
+ return err
+}
+
+var matchBeforeAfterSeparator = regexp.MustCompile(`(?m)^[ \t]*---$`)
+
+func testParse(src string) (parser *_parser, program *ast.Program, err error) {
+ defer func() {
+ if tmp := recover(); tmp != nil {
+ switch tmp := tmp.(type) {
+ case string:
+ if strings.HasPrefix(tmp, "SyntaxError:") {
+ parser = nil
+ program = nil
+ err = errors.New(tmp)
+ return
+ }
+ }
+ panic(tmp)
+ }
+ }()
+ parser = newParser("", src)
+ program, err = parser.parse()
+ return
+}
+
+func TestParseFile(t *testing.T) {
+ tt(t, func() {
+ _, err := ParseFile(nil, "", `/abc/`, 0)
+ is(err, nil)
+
+ _, err = ParseFile(nil, "", `/(?!def)abc/`, IgnoreRegExpErrors)
+ is(err, nil)
+
+ _, err = ParseFile(nil, "", `/(?!def)abc/`, 0)
+ is(err, "(anonymous): Line 1:1 Invalid regular expression: re2: Invalid (?!) <lookahead>")
+
+ _, err = ParseFile(nil, "", `/(?!def)abc/; return`, IgnoreRegExpErrors)
+ is(err, "(anonymous): Line 1:15 Illegal return statement")
+ })
+}
+
+func TestParseFunction(t *testing.T) {
+ tt(t, func() {
+ test := func(prm, bdy string, expect interface{}) *ast.FunctionLiteral {
+ function, err := ParseFunction(prm, bdy)
+ is(firstErr(err), expect)
+ return function
+ }
+
+ test("a, b,c,d", "", nil)
+
+ test("a, b;,c,d", "", "(anonymous): Line 1:15 Unexpected token ;")
+
+ test("this", "", "(anonymous): Line 1:11 Unexpected token this")
+
+ test("a, b, c, null", "", "(anonymous): Line 1:20 Unexpected token null")
+
+ test("a, b,c,d", "return;", nil)
+
+ test("a, b,c,d", "break;", "(anonymous): Line 2:1 Illegal break statement")
+
+ test("a, b,c,d", "{}", nil)
+ })
+}
+
+func TestParserErr(t *testing.T) {
+ tt(t, func() {
+ test := func(input string, expect interface{}) (*ast.Program, *_parser) {
+ parser := newParser("", input)
+ program, err := parser.parse()
+ is(firstErr(err), expect)
+ return program, parser
+ }
+
+ program, parser := test("", nil)
+
+ program, parser = test(`
+ var abc;
+ break; do {
+ } while(true);
+ `, "(anonymous): Line 3:9 Illegal break statement")
+ {
+ stmt := program.Body[1].(*ast.BadStatement)
+ is(parser.position(stmt.From).Column, 9)
+ is(parser.position(stmt.To).Column, 16)
+ is(parser.slice(stmt.From, stmt.To), "break; ")
+ }
+
+ test("{", "(anonymous): Line 1:2 Unexpected end of input")
+
+ test("}", "(anonymous): Line 1:1 Unexpected token }")
+
+ test("3ea", "(anonymous): Line 1:1 Unexpected token ILLEGAL")
+
+ test("3in", "(anonymous): Line 1:1 Unexpected token ILLEGAL")
+
+ test("3in []", "(anonymous): Line 1:1 Unexpected token ILLEGAL")
+
+ test("3e", "(anonymous): Line 1:1 Unexpected token ILLEGAL")
+
+ test("3e+", "(anonymous): Line 1:1 Unexpected token ILLEGAL")
+
+ test("3e-", "(anonymous): Line 1:1 Unexpected token ILLEGAL")
+
+ test("3x", "(anonymous): Line 1:1 Unexpected token ILLEGAL")
+
+ test("3x0", "(anonymous): Line 1:1 Unexpected token ILLEGAL")
+
+ test("0x", "(anonymous): Line 1:1 Unexpected token ILLEGAL")
+
+ test("09", "(anonymous): Line 1:1 Unexpected token ILLEGAL")
+
+ test("018", "(anonymous): Line 1:1 Unexpected token ILLEGAL")
+
+ test("01.0", "(anonymous): Line 1:3 Unexpected number")
+
+ test("01a", "(anonymous): Line 1:1 Unexpected token ILLEGAL")
+
+ test("0x3in[]", "(anonymous): Line 1:1 Unexpected token ILLEGAL")
+
+ test("\"Hello\nWorld\"", "(anonymous): Line 1:1 Unexpected token ILLEGAL")
+
+ test("\u203f = 10", "(anonymous): Line 1:1 Unexpected token ILLEGAL")
+
+ test("x\\", "(anonymous): Line 1:1 Unexpected token ILLEGAL")
+
+ test("x\\\\", "(anonymous): Line 1:1 Unexpected token ILLEGAL")
+
+ test("x\\u005c", "(anonymous): Line 1:1 Unexpected token ILLEGAL")
+
+ test("x\\u002a", "(anonymous): Line 1:1 Unexpected token ILLEGAL")
+
+ test("x\\\\u002a", "(anonymous): Line 1:1 Unexpected token ILLEGAL")
+
+ test("/\n", "(anonymous): Line 1:1 Invalid regular expression: missing /")
+
+ test("var x = /(s/g", "(anonymous): Line 1:9 Invalid regular expression: Unterminated group")
+
+ test("0 = 1", "(anonymous): Line 1:1 Invalid left-hand side in assignment")
+
+ test("func() = 1", "(anonymous): Line 1:1 Invalid left-hand side in assignment")
+
+ test("(1 + 1) = 2", "(anonymous): Line 1:2 Invalid left-hand side in assignment")
+
+ test("1++", "(anonymous): Line 1:2 Invalid left-hand side in assignment")
+
+ test("1--", "(anonymous): Line 1:2 Invalid left-hand side in assignment")
+
+ test("--1", "(anonymous): Line 1:1 Invalid left-hand side in assignment")
+
+ test("for((1 + 1) in abc) def();", "(anonymous): Line 1:1 Invalid left-hand side in for-in")
+
+ test("[", "(anonymous): Line 1:2 Unexpected end of input")
+
+ test("[,", "(anonymous): Line 1:3 Unexpected end of input")
+
+ test("1 + {", "(anonymous): Line 1:6 Unexpected end of input")
+
+ test("1 + { abc:abc", "(anonymous): Line 1:14 Unexpected end of input")
+
+ test("1 + { abc:abc,", "(anonymous): Line 1:15 Unexpected end of input")
+
+ test("var abc = /\n/", "(anonymous): Line 1:11 Invalid regular expression: missing /")
+
+ test("var abc = \"\n", "(anonymous): Line 1:11 Unexpected token ILLEGAL")
+
+ test("var if = 0", "(anonymous): Line 1:5 Unexpected token if")
+
+ test("abc + 0 = 1", "(anonymous): Line 1:1 Invalid left-hand side in assignment")
+
+ test("+abc = 1", "(anonymous): Line 1:1 Invalid left-hand side in assignment")
+
+ test("1 + (", "(anonymous): Line 1:6 Unexpected end of input")
+
+ test("\n\n\n{", "(anonymous): Line 4:2 Unexpected end of input")
+
+ test("\n/* Some multiline\ncomment */\n)", "(anonymous): Line 4:1 Unexpected token )")
+
+ // TODO
+ //{ set 1 }
+ //{ get 2 }
+ //({ set: s(if) { } })
+ //({ set s(.) { } })
+ //({ set: s() { } })
+ //({ set: s(a, b) { } })
+ //({ get: g(d) { } })
+ //({ get i() { }, i: 42 })
+ //({ i: 42, get i() { } })
+ //({ set i(x) { }, i: 42 })
+ //({ i: 42, set i(x) { } })
+ //({ get i() { }, get i() { } })
+ //({ set i(x) { }, set i(x) { } })
+
+ test("function abc(if) {}", "(anonymous): Line 1:14 Unexpected token if")
+
+ test("function abc(true) {}", "(anonymous): Line 1:14 Unexpected token true")
+
+ test("function abc(false) {}", "(anonymous): Line 1:14 Unexpected token false")
+
+ test("function abc(null) {}", "(anonymous): Line 1:14 Unexpected token null")
+
+ test("function null() {}", "(anonymous): Line 1:10 Unexpected token null")
+
+ test("function true() {}", "(anonymous): Line 1:10 Unexpected token true")
+
+ test("function false() {}", "(anonymous): Line 1:10 Unexpected token false")
+
+ test("function if() {}", "(anonymous): Line 1:10 Unexpected token if")
+
+ test("a b;", "(anonymous): Line 1:3 Unexpected identifier")
+
+ test("if.a", "(anonymous): Line 1:3 Unexpected token .")
+
+ test("a if", "(anonymous): Line 1:3 Unexpected token if")
+
+ test("a class", "(anonymous): Line 1:3 Unexpected reserved word")
+
+ test("break\n", "(anonymous): Line 1:1 Illegal break statement")
+
+ test("break 1;", "(anonymous): Line 1:7 Unexpected number")
+
+ test("for (;;) { break 1; }", "(anonymous): Line 1:18 Unexpected number")
+
+ test("continue\n", "(anonymous): Line 1:1 Illegal continue statement")
+
+ test("continue 1;", "(anonymous): Line 1:10 Unexpected number")
+
+ test("for (;;) { continue 1; }", "(anonymous): Line 1:21 Unexpected number")
+
+ test("throw", "(anonymous): Line 1:1 Unexpected end of input")
+
+ test("throw;", "(anonymous): Line 1:6 Unexpected token ;")
+
+ test("throw \n", "(anonymous): Line 1:1 Unexpected end of input")
+
+ test("for (var abc, def in {});", "(anonymous): Line 1:19 Unexpected token in")
+
+ test("for ((abc in {});;);", nil)
+
+ test("for ((abc in {}));", "(anonymous): Line 1:17 Unexpected token )")
+
+ test("for (+abc in {});", "(anonymous): Line 1:1 Invalid left-hand side in for-in")
+
+ test("if (false)", "(anonymous): Line 1:11 Unexpected end of input")
+
+ test("if (false) abc(); else", "(anonymous): Line 1:23 Unexpected end of input")
+
+ test("do", "(anonymous): Line 1:3 Unexpected end of input")
+
+ test("while (false)", "(anonymous): Line 1:14 Unexpected end of input")
+
+ test("for (;;)", "(anonymous): Line 1:9 Unexpected end of input")
+
+ test("with (abc)", "(anonymous): Line 1:11 Unexpected end of input")
+
+ test("try {}", "(anonymous): Line 1:1 Missing catch or finally after try")
+
+ test("try {} catch {}", "(anonymous): Line 1:14 Unexpected token {")
+
+ test("try {} catch () {}", "(anonymous): Line 1:15 Unexpected token )")
+
+ test("\u203f = 1", "(anonymous): Line 1:1 Unexpected token ILLEGAL")
+
+ // TODO
+ // const x = 12, y;
+ // const x, y = 12;
+ // const x;
+ // if(true) let a = 1;
+ // if(true) const a = 1;
+
+ test(`new abc()."def"`, "(anonymous): Line 1:11 Unexpected string")
+
+ test("/*", "(anonymous): Line 1:3 Unexpected end of input")
+
+ test("/**", "(anonymous): Line 1:4 Unexpected end of input")
+
+ test("/*\n\n\n", "(anonymous): Line 4:1 Unexpected end of input")
+
+ test("/*\n\n\n*", "(anonymous): Line 4:2 Unexpected end of input")
+
+ test("/*abc", "(anonymous): Line 1:6 Unexpected end of input")
+
+ test("/*abc *", "(anonymous): Line 1:9 Unexpected end of input")
+
+ test("\n]", "(anonymous): Line 2:1 Unexpected token ]")
+
+ test("\r\n]", "(anonymous): Line 2:1 Unexpected token ]")
+
+ test("\n\r]", "(anonymous): Line 3:1 Unexpected token ]")
+
+ test("//\r\n]", "(anonymous): Line 2:1 Unexpected token ]")
+
+ test("//\n\r]", "(anonymous): Line 3:1 Unexpected token ]")
+
+ test("/abc\\\n/", "(anonymous): Line 1:1 Invalid regular expression: missing /")
+
+ test("//\r \n]", "(anonymous): Line 3:1 Unexpected token ]")
+
+ test("/*\r\n*/]", "(anonymous): Line 2:3 Unexpected token ]")
+
+ test("/*\r \n*/]", "(anonymous): Line 3:3 Unexpected token ]")
+
+ test("\\\\", "(anonymous): Line 1:1 Unexpected token ILLEGAL")
+
+ test("\\u005c", "(anonymous): Line 1:1 Unexpected token ILLEGAL")
+
+ test("\\abc", "(anonymous): Line 1:1 Unexpected token ILLEGAL")
+
+ test("\\u0000", "(anonymous): Line 1:1 Unexpected token ILLEGAL")
+
+ test("\\u200c = []", "(anonymous): Line 1:1 Unexpected token ILLEGAL")
+
+ test("\\u200D = []", "(anonymous): Line 1:1 Unexpected token ILLEGAL")
+
+ test(`"\`, "(anonymous): Line 1:1 Unexpected token ILLEGAL")
+
+ test(`"\u`, "(anonymous): Line 1:1 Unexpected token ILLEGAL")
+
+ test("return", "(anonymous): Line 1:1 Illegal return statement")
+
+ test("continue", "(anonymous): Line 1:1 Illegal continue statement")
+
+ test("break", "(anonymous): Line 1:1 Illegal break statement")
+
+ test("switch (abc) { default: continue; }", "(anonymous): Line 1:25 Illegal continue statement")
+
+ test("do { abc } *", "(anonymous): Line 1:12 Unexpected token *")
+
+ test("while (true) { break abc; }", "(anonymous): Line 1:16 Undefined label 'abc'")
+
+ test("while (true) { continue abc; }", "(anonymous): Line 1:16 Undefined label 'abc'")
+
+ test("abc: while (true) { (function(){ break abc; }); }", "(anonymous): Line 1:34 Undefined label 'abc'")
+
+ test("abc: while (true) { (function(){ abc: break abc; }); }", nil)
+
+ test("abc: while (true) { (function(){ continue abc; }); }", "(anonymous): Line 1:34 Undefined label 'abc'")
+
+ test(`abc: if (0) break abc; else {}`, nil)
+
+ test(`abc: if (0) { break abc; } else {}`, nil)
+
+ test(`abc: if (0) { break abc } else {}`, nil)
+
+ test("abc: while (true) { abc: while (true) {} }", "(anonymous): Line 1:21 Label 'abc' already exists")
+
+ if false {
+ // TODO When strict mode is implemented
+ test("(function () { 'use strict'; delete abc; }())", "")
+ }
+
+ test("_: _: while (true) {]", "(anonymous): Line 1:4 Label '_' already exists")
+
+ test("_:\n_:\nwhile (true) {]", "(anonymous): Line 2:1 Label '_' already exists")
+
+ test("_:\n _:\nwhile (true) {]", "(anonymous): Line 2:4 Label '_' already exists")
+
+ test("/Xyzzy(?!Nothing happens)/",
+ "(anonymous): Line 1:1 Invalid regular expression: re2: Invalid (?!) <lookahead>")
+
+ test("function(){}", "(anonymous): Line 1:9 Unexpected token (")
+
+ test("\n/*/", "(anonymous): Line 2:4 Unexpected end of input")
+
+ test("/*/.source", "(anonymous): Line 1:11 Unexpected end of input")
+
+ test("/\\1/.source", "(anonymous): Line 1:1 Invalid regular expression: re2: Invalid \\1 <backreference>")
+
+ test("var class", "(anonymous): Line 1:5 Unexpected reserved word")
+
+ test("var if", "(anonymous): Line 1:5 Unexpected token if")
+
+ test("object Object", "(anonymous): Line 1:8 Unexpected identifier")
+
+ test("[object Object]", "(anonymous): Line 1:9 Unexpected identifier")
+
+ test("\\u0xyz", "(anonymous): Line 1:1 Unexpected token ILLEGAL")
+
+ test(`for (var abc, def in {}) {}`, "(anonymous): Line 1:19 Unexpected token in")
+
+ test(`for (abc, def in {}) {}`, "(anonymous): Line 1:1 Invalid left-hand side in for-in")
+
+ test(`for (var abc=def, ghi=("abc" in {}); true;) {}`, nil)
+
+ {
+ // Semicolon insertion
+
+ test("this\nif (1);", nil)
+
+ test("while (1) { break\nif (1); }", nil)
+
+ test("throw\nif (1);", "(anonymous): Line 1:1 Illegal newline after throw")
+
+ test("(function(){ return\nif (1); })", nil)
+
+ test("while (1) { continue\nif (1); }", nil)
+
+ test("debugger\nif (1);", nil)
+ }
+
+ { // Reserved words
+
+ test("class", "(anonymous): Line 1:1 Unexpected reserved word")
+ test("abc.class = 1", nil)
+ test("var class;", "(anonymous): Line 1:5 Unexpected reserved word")
+
+ test("const", "(anonymous): Line 1:1 Unexpected reserved word")
+ test("abc.const = 1", nil)
+ test("var const;", "(anonymous): Line 1:5 Unexpected reserved word")
+
+ test("enum", "(anonymous): Line 1:1 Unexpected reserved word")
+ test("abc.enum = 1", nil)
+ test("var enum;", "(anonymous): Line 1:5 Unexpected reserved word")
+
+ test("export", "(anonymous): Line 1:1 Unexpected reserved word")
+ test("abc.export = 1", nil)
+ test("var export;", "(anonymous): Line 1:5 Unexpected reserved word")
+
+ test("extends", "(anonymous): Line 1:1 Unexpected reserved word")
+ test("abc.extends = 1", nil)
+ test("var extends;", "(anonymous): Line 1:5 Unexpected reserved word")
+
+ test("import", "(anonymous): Line 1:1 Unexpected reserved word")
+ test("abc.import = 1", nil)
+ test("var import;", "(anonymous): Line 1:5 Unexpected reserved word")
+
+ test("super", "(anonymous): Line 1:1 Unexpected reserved word")
+ test("abc.super = 1", nil)
+ test("var super;", "(anonymous): Line 1:5 Unexpected reserved word")
+ }
+
+ { // Reserved words (strict)
+
+ test(`implements`, nil)
+ test(`abc.implements = 1`, nil)
+ test(`var implements;`, nil)
+
+ test(`interface`, nil)
+ test(`abc.interface = 1`, nil)
+ test(`var interface;`, nil)
+
+ test(`let`, nil)
+ test(`abc.let = 1`, nil)
+ test(`var let;`, nil)
+
+ test(`package`, nil)
+ test(`abc.package = 1`, nil)
+ test(`var package;`, nil)
+
+ test(`private`, nil)
+ test(`abc.private = 1`, nil)
+ test(`var private;`, nil)
+
+ test(`protected`, nil)
+ test(`abc.protected = 1`, nil)
+ test(`var protected;`, nil)
+
+ test(`public`, nil)
+ test(`abc.public = 1`, nil)
+ test(`var public;`, nil)
+
+ test(`static`, nil)
+ test(`abc.static = 1`, nil)
+ test(`var static;`, nil)
+
+ test(`yield`, nil)
+ test(`abc.yield = 1`, nil)
+ test(`var yield;`, nil)
+ }
+ })
+}
+
+func TestParser(t *testing.T) {
+ tt(t, func() {
+ test := func(source string, chk interface{}) *ast.Program {
+ _, program, err := testParse(source)
+ is(firstErr(err), chk)
+ return program
+ }
+
+ test(`
+ abc
+ --
+ []
+ `, "(anonymous): Line 3:13 Invalid left-hand side in assignment")
+
+ test(`
+ abc--
+ []
+ `, nil)
+
+ test("1\n[]\n", "(anonymous): Line 2:2 Unexpected token ]")
+
+ test(`
+ function abc() {
+ }
+ abc()
+ `, nil)
+
+ program := test("", nil)
+
+ test("//", nil)
+
+ test("/* */", nil)
+
+ test("/** **/", nil)
+
+ test("/*****/", nil)
+
+ test("/*", "(anonymous): Line 1:3 Unexpected end of input")
+
+ test("#", "(anonymous): Line 1:1 Unexpected token ILLEGAL")
+
+ test("/**/#", "(anonymous): Line 1:5 Unexpected token ILLEGAL")
+
+ test("new +", "(anonymous): Line 1:5 Unexpected token +")
+
+ program = test(";", nil)
+ is(len(program.Body), 1)
+ is(program.Body[0].(*ast.EmptyStatement).Semicolon, file.Idx(1))
+
+ program = test(";;", nil)
+ is(len(program.Body), 2)
+ is(program.Body[0].(*ast.EmptyStatement).Semicolon, file.Idx(1))
+ is(program.Body[1].(*ast.EmptyStatement).Semicolon, file.Idx(2))
+
+ program = test("1.2", nil)
+ is(len(program.Body), 1)
+ is(program.Body[0].(*ast.ExpressionStatement).Expression.(*ast.NumberLiteral).Literal, "1.2")
+
+ program = test("/* */1.2", nil)
+ is(len(program.Body), 1)
+ is(program.Body[0].(*ast.ExpressionStatement).Expression.(*ast.NumberLiteral).Literal, "1.2")
+
+ program = test("\n", nil)
+ is(len(program.Body), 0)
+
+ test(`
+ if (0) {
+ abc = 0
+ }
+ else abc = 0
+ `, nil)
+
+ test("if (0) abc = 0 else abc = 0", "(anonymous): Line 1:16 Unexpected token else")
+
+ test(`
+ if (0) {
+ abc = 0
+ } else abc = 0
+ `, nil)
+
+ test(`
+ if (0) {
+ abc = 1
+ } else {
+ }
+ `, nil)
+
+ test(`
+ do {
+ } while (true)
+ `, nil)
+
+ test(`
+ try {
+ } finally {
+ }
+ `, nil)
+
+ test(`
+ try {
+ } catch (abc) {
+ } finally {
+ }
+ `, nil)
+
+ test(`
+ try {
+ }
+ catch (abc) {
+ }
+ finally {
+ }
+ `, nil)
+
+ test(`try {} catch (abc) {} finally {}`, nil)
+
+ test(`
+ do {
+ do {
+ } while (0)
+ } while (0)
+ `, nil)
+
+ test(`
+ (function(){
+ try {
+ if (
+ 1
+ ) {
+ return 1
+ }
+ return 0
+ } finally {
+ }
+ })()
+ `, nil)
+
+ test("abc = ''\ndef", nil)
+
+ test("abc = 1\ndef", nil)
+
+ test("abc = Math\ndef", nil)
+
+ test(`"\'"`, nil)
+
+ test(`
+ abc = function(){
+ }
+ abc = 0
+ `, nil)
+
+ test("abc.null = 0", nil)
+
+ test("0x41", nil)
+
+ test(`"\d"`, nil)
+
+ test(`(function(){return this})`, nil)
+
+ test(`
+ Object.defineProperty(Array.prototype, "0", {
+ value: 100,
+ writable: false,
+ configurable: true
+ });
+ abc = [101];
+ abc.hasOwnProperty("0") && abc[0] === 101;
+ `, nil)
+
+ test(`new abc()`, nil)
+ test(`new {}`, nil)
+
+ test(`
+ limit = 4
+ result = 0
+ while (limit) {
+ limit = limit - 1
+ if (limit) {
+ }
+ else {
+ break
+ }
+ result = result + 1
+ }
+ `, nil)
+
+ test(`
+ while (0) {
+ if (0) {
+ continue
+ }
+ }
+ `, nil)
+
+ test("var \u0061\u0062\u0063 = 0", nil)
+
+ // 7_3_1
+ test("var test7_3_1\nabc = 66;", nil)
+ test("var test7_3_1\u2028abc = 66;", nil)
+
+ // 7_3_3
+ test("//\u2028 =;", "(anonymous): Line 2:2 Unexpected token =")
+
+ // 7_3_10
+ test("var abc = \u2029;", "(anonymous): Line 2:1 Unexpected token ;")
+ test("var abc = \\u2029;", "(anonymous): Line 1:11 Unexpected token ILLEGAL")
+ test("var \\u0061\\u0062\\u0063 = 0;", nil)
+
+ test("'", "(anonymous): Line 1:1 Unexpected token ILLEGAL")
+
+ test("'\nstr\ning\n'", "(anonymous): Line 1:1 Unexpected token ILLEGAL")
+
+ // S7.6_A4.3_T1
+ test(`var $\u0030 = 0;`, nil)
+
+ // S7.6.1.1_A1.1
+ test(`switch = 1`, "(anonymous): Line 1:8 Unexpected token =")
+
+ // S7.8.3_A2.1_T1
+ test(`.0 === 0.0`, nil)
+
+ // 7.8.5-1
+ test("var regExp = /\\\rn/;", "(anonymous): Line 1:14 Invalid regular expression: missing /")
+
+ // S7.8.5_A1.1_T2
+ test("var regExp = /=/;", nil)
+
+ // S7.8.5_A1.2_T1
+ test("/*/", "(anonymous): Line 1:4 Unexpected end of input")
+
+ // Sbp_7.9_A9_T3
+ test(`
+ do {
+ ;
+ } while (false) true
+ `, nil)
+
+ // S7.9_A10_T10
+ test(`
+ {a:1
+ } 3
+ `, nil)
+
+ test(`
+ abc
+ ++def
+ `, nil)
+
+ // S7.9_A5.2_T1
+ test(`
+ for(false;false
+ ) {
+ break;
+ }
+ `, "(anonymous): Line 3:13 Unexpected token )")
+
+ // S7.9_A9_T8
+ test(`
+ do {};
+ while (false)
+ `, "(anonymous): Line 2:18 Unexpected token ;")
+
+ // S8.4_A5
+ test(`
+ "x\0y"
+ `, nil)
+
+ // S9.3.1_A6_T1
+ test(`
+ 10e10000
+ `, nil)
+
+ // 10.4.2-1-5
+ test(`
+ "abc\
+ def"
+ `, nil)
+
+ test("'\\\n'", nil)
+
+ test("'\\\r\n'", nil)
+
+ //// 11.13.1-1-1
+ test("42 = 42;", "(anonymous): Line 1:1 Invalid left-hand side in assignment")
+
+ // S11.13.2_A4.2_T1.3
+ test(`
+ abc /= "1"
+ `, nil)
+
+ // 12.1-1
+ test(`
+ try{};catch(){}
+ `, "(anonymous): Line 2:13 Missing catch or finally after try")
+
+ // 12.1-3
+ test(`
+ try{};finally{}
+ `, "(anonymous): Line 2:13 Missing catch or finally after try")
+
+ // S12.6.3_A11.1_T3
+ test(`
+ while (true) {
+ break abc;
+ }
+ `, "(anonymous): Line 3:17 Undefined label 'abc'")
+
+ // S15.3_A2_T1
+ test(`var x / = 1;`, "(anonymous): Line 1:7 Unexpected token /")
+
+ test(`
+ function abc() {
+ if (0)
+ return;
+ else {
+ }
+ }
+ `, nil)
+
+ test("//\u2028 var =;", "(anonymous): Line 2:6 Unexpected token =")
+
+ test(`
+ throw
+ {}
+ `, "(anonymous): Line 2:13 Illegal newline after throw")
+
+ // S7.6.1.1_A1.11
+ test(`
+ function = 1
+ `, "(anonymous): Line 2:22 Unexpected token =")
+
+ // S7.8.3_A1.2_T1
+ test(`0e1`, nil)
+
+ test("abc = 1; abc\n++", "(anonymous): Line 2:3 Unexpected end of input")
+
+ // ---
+
+ test("({ get abc() {} })", nil)
+
+ test(`for (abc.def in {}) {}`, nil)
+
+ test(`while (true) { break }`, nil)
+
+ test(`while (true) { continue }`, nil)
+
+ test(`abc=/^(?:(\w+:)\/{2}(\w+(?:\.\w+)*\/?)|(.{0,2}\/{1}))?([/.]*?(?:[^?]+)?\/)?((?:[^/?]+)\.(\w+))(?:\?(\S+)?)?$/,def=/^(?:(\w+:)\/{2})|(.{0,2}\/{1})?([/.]*?(?:[^?]+)?\/?)?$/`, nil)
+
+ test(`(function() { try {} catch (err) {} finally {} return })`, nil)
+
+ test(`0xde0b6b3a7640080.toFixed(0)`, nil)
+
+ test(`/[^-._0-9A-Za-z\xb7\xc0-\xd6\xd8-\xf6\xf8-\u037d\u37f-\u1fff\u200c-\u200d\u203f\u2040\u2070-\u218f]/`, nil)
+
+ test(`/[\u0000-\u0008\u000B-\u000C\u000E-\u001F\uD800-\uDFFF\uFFFE-\uFFFF]/`, nil)
+
+ test("var abc = 1;\ufeff", nil)
+
+ test("\ufeff/* var abc = 1; */", nil)
+
+ test(`if (-0x8000000000000000<=abc&&abc<=0x8000000000000000) {}`, nil)
+
+ test(`(function(){debugger;return this;})`, nil)
+
+ test(`
+
+ `, nil)
+
+ test(`
+ var abc = ""
+ debugger
+ `, nil)
+
+ test(`
+ var abc = /\[\]$/
+ debugger
+ `, nil)
+
+ test(`
+ var abc = 1 /
+ 2
+ debugger
+ `, nil)
+ })
+}
+
+func Test_parseStringLiteral(t *testing.T) {
+ tt(t, func() {
+ test := func(have, want string) {
+ have, err := parseStringLiteral(have)
+ is(err, nil)
+ is(have, want)
+ }
+
+ test("", "")
+
+ test("1(\\\\d+)", "1(\\d+)")
+
+ test("\\u2029", "\u2029")
+
+ test("abc\\uFFFFabc", "abc\uFFFFabc")
+
+ test("[First line \\\nSecond line \\\n Third line\\\n. ]",
+ "[First line Second line Third line. ]")
+
+ test("\\u007a\\x79\\u000a\\x78", "zy\nx")
+
+ // S7.8.4_A4.2_T3
+ test("\\a", "a")
+ test("\u0410", "\u0410")
+
+ // S7.8.4_A5.1_T1
+ test("\\0", "\u0000")
+
+ // S8.4_A5
+ test("\u0000", "\u0000")
+
+ // 15.5.4.20
+ test("'abc'\\\n'def'", "'abc''def'")
+
+ // 15.5.4.20-4-1
+ test("'abc'\\\r\n'def'", "'abc''def'")
+
+ // Octal
+ test("\\0", "\000")
+ test("\\00", "\000")
+ test("\\000", "\000")
+ test("\\09", "\0009")
+ test("\\009", "\0009")
+ test("\\0009", "\0009")
+ test("\\1", "\001")
+ test("\\01", "\001")
+ test("\\001", "\001")
+ test("\\0011", "\0011")
+ test("\\1abc", "\001abc")
+
+ test("\\\u4e16", "\u4e16")
+
+ // err
+ test = func(have, want string) {
+ have, err := parseStringLiteral(have)
+ is(err.Error(), want)
+ is(have, "")
+ }
+
+ test(`\u`, `invalid escape: \u: len("") != 4`)
+ test(`\u0`, `invalid escape: \u: len("0") != 4`)
+ test(`\u00`, `invalid escape: \u: len("00") != 4`)
+ test(`\u000`, `invalid escape: \u: len("000") != 4`)
+
+ test(`\x`, `invalid escape: \x: len("") != 2`)
+ test(`\x0`, `invalid escape: \x: len("0") != 2`)
+ test(`\x0`, `invalid escape: \x: len("0") != 2`)
+ })
+}
+
+func Test_parseNumberLiteral(t *testing.T) {
+ tt(t, func() {
+ test := func(input string, expect interface{}) {
+ result, err := parseNumberLiteral(input)
+ is(err, nil)
+ is(result, expect)
+ }
+
+ test("0", 0)
+
+ test("0x8000000000000000", float64(9.223372036854776e+18))
+ })
+}
+
+func TestPosition(t *testing.T) {
+ tt(t, func() {
+ parser := newParser("", "// Lorem ipsum")
+
+ // Out of range, idx0 (error condition)
+ is(parser.slice(0, 1), "")
+ is(parser.slice(0, 10), "")
+
+ // Out of range, idx1 (error condition)
+ is(parser.slice(1, 128), "")
+
+ is(parser.str[0:0], "")
+ is(parser.slice(1, 1), "")
+
+ is(parser.str[0:1], "/")
+ is(parser.slice(1, 2), "/")
+
+ is(parser.str[0:14], "// Lorem ipsum")
+ is(parser.slice(1, 15), "// Lorem ipsum")
+
+ parser = newParser("", "(function(){ return 0; })")
+ program, err := parser.parse()
+ is(err, nil)
+
+ var node ast.Node
+ node = program.Body[0].(*ast.ExpressionStatement).Expression.(*ast.FunctionLiteral)
+ is(node.Idx0(), file.Idx(2))
+ is(node.Idx1(), file.Idx(25))
+ is(parser.slice(node.Idx0(), node.Idx1()), "function(){ return 0; }")
+ is(parser.slice(node.Idx0(), node.Idx1()+1), "function(){ return 0; })")
+ is(parser.slice(node.Idx0(), node.Idx1()+2), "")
+ is(node.(*ast.FunctionLiteral).Source, "function(){ return 0; }")
+
+ node = program
+ is(node.Idx0(), file.Idx(2))
+ is(node.Idx1(), file.Idx(25))
+ is(parser.slice(node.Idx0(), node.Idx1()), "function(){ return 0; }")
+
+ parser = newParser("", "(function(){ return abc; })")
+ program, err = parser.parse()
+ is(err, nil)
+ node = program.Body[0].(*ast.ExpressionStatement).Expression.(*ast.FunctionLiteral)
+ is(node.(*ast.FunctionLiteral).Source, "function(){ return abc; }")
+ })
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/parser/regexp.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/parser/regexp.go
new file mode 100644
index 000000000..f614dae74
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/parser/regexp.go
@@ -0,0 +1,358 @@
+package parser
+
+import (
+ "bytes"
+ "fmt"
+ "strconv"
+)
+
+type _RegExp_parser struct {
+ str string
+ length int
+
+ chr rune // The current character
+ chrOffset int // The offset of current character
+ offset int // The offset after current character (may be greater than 1)
+
+ errors []error
+ invalid bool // The input is an invalid JavaScript RegExp
+
+ goRegexp *bytes.Buffer
+}
+
+// TransformRegExp transforms a JavaScript pattern into a Go "regexp" pattern.
+//
+// re2 (Go) cannot do backtracking, so the presence of a lookahead (?=) (?!) or
+// backreference (\1, \2, ...) will cause an error.
+//
+// re2 (Go) has a different definition for \s: [\t\n\f\r ].
+// The JavaScript definition, on the other hand, also includes \v, Unicode "Separator, Space", etc.
+//
+// If the pattern is invalid (not valid even in JavaScript), then this function
+// returns the empty string and an error.
+//
+// If the pattern is valid, but incompatible (contains a lookahead or backreference),
+// then this function returns the transformation (a non-empty string) AND an error.
+func TransformRegExp(pattern string) (string, error) {
+
+ if pattern == "" {
+ return "", nil
+ }
+
+ // TODO If without \, if without (?=, (?!, then another shortcut
+
+ parser := _RegExp_parser{
+ str: pattern,
+ length: len(pattern),
+ goRegexp: bytes.NewBuffer(make([]byte, 0, 3*len(pattern)/2)),
+ }
+ parser.read() // Pull in the first character
+ parser.scan()
+ var err error
+ if len(parser.errors) > 0 {
+ err = parser.errors[0]
+ }
+ if parser.invalid {
+ return "", err
+ }
+
+ // Might not be re2 compatible, but is still a valid JavaScript RegExp
+ return parser.goRegexp.String(), err
+}
+
+func (self *_RegExp_parser) scan() {
+ for self.chr != -1 {
+ switch self.chr {
+ case '\\':
+ self.read()
+ self.scanEscape(false)
+ case '(':
+ self.pass()
+ self.scanGroup()
+ case '[':
+ self.pass()
+ self.scanBracket()
+ case ')':
+ self.error(-1, "Unmatched ')'")
+ self.invalid = true
+ self.pass()
+ default:
+ self.pass()
+ }
+ }
+}
+
+// (...)
+func (self *_RegExp_parser) scanGroup() {
+ str := self.str[self.chrOffset:]
+ if len(str) > 1 { // A possibility of (?= or (?!
+ if str[0] == '?' {
+ if str[1] == '=' || str[1] == '!' {
+ self.error(-1, "re2: Invalid (%s) <lookahead>", self.str[self.chrOffset:self.chrOffset+2])
+ }
+ }
+ }
+ for self.chr != -1 && self.chr != ')' {
+ switch self.chr {
+ case '\\':
+ self.read()
+ self.scanEscape(false)
+ case '(':
+ self.pass()
+ self.scanGroup()
+ case '[':
+ self.pass()
+ self.scanBracket()
+ default:
+ self.pass()
+ continue
+ }
+ }
+ if self.chr != ')' {
+ self.error(-1, "Unterminated group")
+ self.invalid = true
+ return
+ }
+ self.pass()
+}
+
+// [...]
+func (self *_RegExp_parser) scanBracket() {
+ for self.chr != -1 {
+ if self.chr == ']' {
+ break
+ } else if self.chr == '\\' {
+ self.read()
+ self.scanEscape(true)
+ continue
+ }
+ self.pass()
+ }
+ if self.chr != ']' {
+ self.error(-1, "Unterminated character class")
+ self.invalid = true
+ return
+ }
+ self.pass()
+}
+
+// \...
+func (self *_RegExp_parser) scanEscape(inClass bool) {
+ offset := self.chrOffset
+
+ var length, base uint32
+ switch self.chr {
+
+ case '0', '1', '2', '3', '4', '5', '6', '7':
+ var value int64
+ size := 0
+ for {
+ digit := int64(digitValue(self.chr))
+ if digit >= 8 {
+ // Not a valid digit
+ break
+ }
+ value = value*8 + digit
+ self.read()
+ size += 1
+ }
+ if size == 1 { // The number of characters read
+ _, err := self.goRegexp.Write([]byte{'\\', byte(value) + '0'})
+ if err != nil {
+ self.errors = append(self.errors, err)
+ }
+ if value != 0 {
+ // An invalid backreference
+ self.error(-1, "re2: Invalid \\%d <backreference>", value)
+ }
+ return
+ }
+ tmp := []byte{'\\', 'x', '0', 0}
+ if value >= 16 {
+ tmp = tmp[0:2]
+ } else {
+ tmp = tmp[0:3]
+ }
+ tmp = strconv.AppendInt(tmp, value, 16)
+ _, err := self.goRegexp.Write(tmp)
+ if err != nil {
+ self.errors = append(self.errors, err)
+ }
+ return
+
+ case '8', '9':
+ size := 0
+ for {
+ digit := digitValue(self.chr)
+ if digit >= 10 {
+ // Not a valid digit
+ break
+ }
+ self.read()
+ size += 1
+ }
+ err := self.goRegexp.WriteByte('\\')
+ if err != nil {
+ self.errors = append(self.errors, err)
+ }
+ _, err = self.goRegexp.WriteString(self.str[offset:self.chrOffset])
+ if err != nil {
+ self.errors = append(self.errors, err)
+ }
+ self.error(-1, "re2: Invalid \\%s <backreference>", self.str[offset:self.chrOffset])
+ return
+
+ case 'x':
+ self.read()
+ length, base = 2, 16
+
+ case 'u':
+ self.read()
+ length, base = 4, 16
+
+ case 'b':
+ if inClass {
+ _, err := self.goRegexp.Write([]byte{'\\', 'x', '0', '8'})
+ if err != nil {
+ self.errors = append(self.errors, err)
+ }
+ self.read()
+ return
+ }
+ fallthrough
+
+ case 'B':
+ fallthrough
+
+ case 'd', 'D', 's', 'S', 'w', 'W':
+ // This is slightly broken, because ECMAScript
+ // includes \v in \s, \S, while re2 does not
+ fallthrough
+
+ case '\\':
+ fallthrough
+
+ case 'f', 'n', 'r', 't', 'v':
+ err := self.goRegexp.WriteByte('\\')
+ if err != nil {
+ self.errors = append(self.errors, err)
+ }
+ self.pass()
+ return
+
+ case 'c':
+ self.read()
+ var value int64
+ if 'a' <= self.chr && self.chr <= 'z' {
+ value = int64(self.chr) - 'a' + 1
+ } else if 'A' <= self.chr && self.chr <= 'Z' {
+ value = int64(self.chr) - 'A' + 1
+ } else {
+ err := self.goRegexp.WriteByte('c')
+ if err != nil {
+ self.errors = append(self.errors, err)
+ }
+ return
+ }
+ tmp := []byte{'\\', 'x', '0', 0}
+ if value >= 16 {
+ tmp = tmp[0:2]
+ } else {
+ tmp = tmp[0:3]
+ }
+ tmp = strconv.AppendInt(tmp, value, 16)
+ _, err := self.goRegexp.Write(tmp)
+ if err != nil {
+ self.errors = append(self.errors, err)
+ }
+ self.read()
+ return
+
+ default:
+ // $ is an identifier character, so we have to have
+ // a special case for it here
+ if self.chr == '$' || !isIdentifierPart(self.chr) {
+ // A non-identifier character needs escaping
+ err := self.goRegexp.WriteByte('\\')
+ if err != nil {
+ self.errors = append(self.errors, err)
+ }
+ } else {
+ // Unescape the character for re2
+ }
+ self.pass()
+ return
+ }
+
+ // Otherwise, we're a \u.... or \x...
+ valueOffset := self.chrOffset
+
+ var value uint32
+ {
+ length := length
+ for ; length > 0; length-- {
+ digit := uint32(digitValue(self.chr))
+ if digit >= base {
+ // Not a valid digit
+ goto skip
+ }
+ value = value*base + digit
+ self.read()
+ }
+ }
+
+ if length == 4 {
+ _, err := self.goRegexp.Write([]byte{
+ '\\',
+ 'x',
+ '{',
+ self.str[valueOffset+0],
+ self.str[valueOffset+1],
+ self.str[valueOffset+2],
+ self.str[valueOffset+3],
+ '}',
+ })
+ if err != nil {
+ self.errors = append(self.errors, err)
+ }
+ } else if length == 2 {
+ _, err := self.goRegexp.Write([]byte{
+ '\\',
+ 'x',
+ self.str[valueOffset+0],
+ self.str[valueOffset+1],
+ })
+ if err != nil {
+ self.errors = append(self.errors, err)
+ }
+ } else {
+ // Should never, ever get here...
+ self.error(-1, "re2: Illegal branch in scanEscape")
+ goto skip
+ }
+
+ return
+
+skip:
+ _, err := self.goRegexp.WriteString(self.str[offset:self.chrOffset])
+ if err != nil {
+ self.errors = append(self.errors, err)
+ }
+}
+
+func (self *_RegExp_parser) pass() {
+ if self.chr != -1 {
+ _, err := self.goRegexp.WriteRune(self.chr)
+ if err != nil {
+ self.errors = append(self.errors, err)
+ }
+ }
+ self.read()
+}
+
+// TODO Better error reporting, use the offset, etc.
+func (self *_RegExp_parser) error(offset int, msg string, msgValues ...interface{}) error {
+ err := fmt.Errorf(msg, msgValues...)
+ self.errors = append(self.errors, err)
+ return err
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/parser/regexp_test.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/parser/regexp_test.go
new file mode 100644
index 000000000..3222db1a7
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/parser/regexp_test.go
@@ -0,0 +1,149 @@
+package parser
+
+import (
+ "regexp"
+ "testing"
+)
+
+func TestRegExp(t *testing.T) {
+ tt(t, func() {
+ {
+ // err
+ test := func(input string, expect interface{}) {
+ _, err := TransformRegExp(input)
+ is(err, expect)
+ }
+
+ test("[", "Unterminated character class")
+
+ test("(", "Unterminated group")
+
+ test("(?=)", "re2: Invalid (?=) <lookahead>")
+
+ test("(?=)", "re2: Invalid (?=) <lookahead>")
+
+ test("(?!)", "re2: Invalid (?!) <lookahead>")
+
+ // An error anyway
+ test("(?=", "re2: Invalid (?=) <lookahead>")
+
+ test("\\1", "re2: Invalid \\1 <backreference>")
+
+ test("\\90", "re2: Invalid \\90 <backreference>")
+
+ test("\\9123456789", "re2: Invalid \\9123456789 <backreference>")
+
+ test("\\(?=)", "Unmatched ')'")
+
+ test(")", "Unmatched ')'")
+ }
+
+ {
+ // err
+ test := func(input, expect string, expectErr interface{}) {
+ output, err := TransformRegExp(input)
+ is(output, expect)
+ is(err, expectErr)
+ }
+
+ test("(?!)", "(?!)", "re2: Invalid (?!) <lookahead>")
+
+ test(")", "", "Unmatched ')'")
+
+ test("(?!))", "", "re2: Invalid (?!) <lookahead>")
+
+ test("\\0", "\\0", nil)
+
+ test("\\1", "\\1", "re2: Invalid \\1 <backreference>")
+
+ test("\\9123456789", "\\9123456789", "re2: Invalid \\9123456789 <backreference>")
+ }
+
+ {
+ // err
+ test := func(input string, expect string) {
+ result, err := TransformRegExp(input)
+ is(err, nil)
+ if is(result, expect) {
+ _, err := regexp.Compile(result)
+ if !is(err, nil) {
+ t.Log(result)
+ }
+ }
+ }
+
+ test("", "")
+
+ test("abc", "abc")
+
+ test(`\abc`, `abc`)
+
+ test(`\a\b\c`, `a\bc`)
+
+ test(`\x`, `x`)
+
+ test(`\c`, `c`)
+
+ test(`\cA`, `\x01`)
+
+ test(`\cz`, `\x1a`)
+
+ test(`\ca`, `\x01`)
+
+ test(`\cj`, `\x0a`)
+
+ test(`\ck`, `\x0b`)
+
+ test(`\+`, `\+`)
+
+ test(`[\b]`, `[\x08]`)
+
+ test(`\u0z01\x\undefined`, `u0z01xundefined`)
+
+ test(`\\|'|\r|\n|\t|\u2028|\u2029`, `\\|'|\r|\n|\t|\x{2028}|\x{2029}`)
+
+ test("]", "]")
+
+ test("}", "}")
+
+ test("%", "%")
+
+ test("(%)", "(%)")
+
+ test("(?:[%\\s])", "(?:[%\\s])")
+
+ test("[[]", "[[]")
+
+ test("\\101", "\\x41")
+
+ test("\\51", "\\x29")
+
+ test("\\051", "\\x29")
+
+ test("\\175", "\\x7d")
+
+ test("\\04", "\\x04")
+
+ test(`<%([\s\S]+?)%>`, `<%([\s\S]+?)%>`)
+
+ test(`(.)^`, "(.)^")
+
+ test(`<%-([\s\S]+?)%>|<%=([\s\S]+?)%>|<%([\s\S]+?)%>|$`, `<%-([\s\S]+?)%>|<%=([\s\S]+?)%>|<%([\s\S]+?)%>|$`)
+
+ test(`\$`, `\$`)
+
+ test(`[G-b]`, `[G-b]`)
+
+ test(`[G-b\0]`, `[G-b\0]`)
+ }
+ })
+}
+
+func TestTransformRegExp(t *testing.T) {
+ tt(t, func() {
+ pattern, err := TransformRegExp(`\s+abc\s+`)
+ is(err, nil)
+ is(pattern, `\s+abc\s+`)
+ is(regexp.MustCompile(pattern).MatchString("\t abc def"), true)
+ })
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/parser/scope.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/parser/scope.go
new file mode 100644
index 000000000..e1dbdda13
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/parser/scope.go
@@ -0,0 +1,44 @@
+package parser
+
+import (
+ "github.com/robertkrimen/otto/ast"
+)
+
+type _scope struct {
+ outer *_scope
+ allowIn bool
+ inIteration bool
+ inSwitch bool
+ inFunction bool
+ declarationList []ast.Declaration
+
+ labels []string
+}
+
+func (self *_parser) openScope() {
+ self.scope = &_scope{
+ outer: self.scope,
+ allowIn: true,
+ }
+}
+
+func (self *_parser) closeScope() {
+ self.scope = self.scope.outer
+}
+
+func (self *_scope) declare(declaration ast.Declaration) {
+ self.declarationList = append(self.declarationList, declaration)
+}
+
+func (self *_scope) hasLabel(name string) bool {
+ for _, label := range self.labels {
+ if label == name {
+ return true
+ }
+ }
+ if self.outer != nil && !self.inFunction {
+ // Crossing a function boundary to look for a label is verboten
+ return self.outer.hasLabel(name)
+ }
+ return false
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/parser/statement.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/parser/statement.go
new file mode 100644
index 000000000..2059d3856
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/parser/statement.go
@@ -0,0 +1,663 @@
+package parser
+
+import (
+ "github.com/robertkrimen/otto/ast"
+ "github.com/robertkrimen/otto/token"
+)
+
+func (self *_parser) parseBlockStatement() *ast.BlockStatement {
+ node := &ast.BlockStatement{}
+ node.LeftBrace = self.expect(token.LEFT_BRACE)
+ node.List = self.parseStatementList()
+ node.RightBrace = self.expect(token.RIGHT_BRACE)
+
+ return node
+}
+
+func (self *_parser) parseEmptyStatement() ast.Statement {
+ idx := self.expect(token.SEMICOLON)
+ return &ast.EmptyStatement{Semicolon: idx}
+}
+
+func (self *_parser) parseStatementList() (list []ast.Statement) {
+ for self.token != token.RIGHT_BRACE && self.token != token.EOF {
+ list = append(list, self.parseStatement())
+ }
+
+ return
+}
+
+func (self *_parser) parseStatement() ast.Statement {
+
+ if self.token == token.EOF {
+ self.errorUnexpectedToken(self.token)
+ return &ast.BadStatement{From: self.idx, To: self.idx + 1}
+ }
+
+ switch self.token {
+ case token.SEMICOLON:
+ return self.parseEmptyStatement()
+ case token.LEFT_BRACE:
+ return self.parseBlockStatement()
+ case token.IF:
+ return self.parseIfStatement()
+ case token.DO:
+ return self.parseDoWhileStatement()
+ case token.WHILE:
+ return self.parseWhileStatement()
+ case token.FOR:
+ return self.parseForOrForInStatement()
+ case token.BREAK:
+ return self.parseBreakStatement()
+ case token.CONTINUE:
+ return self.parseContinueStatement()
+ case token.DEBUGGER:
+ return self.parseDebuggerStatement()
+ case token.WITH:
+ return self.parseWithStatement()
+ case token.VAR:
+ return self.parseVariableStatement()
+ case token.FUNCTION:
+ self.parseFunction(true)
+ // FIXME
+ return &ast.EmptyStatement{}
+ case token.SWITCH:
+ return self.parseSwitchStatement()
+ case token.RETURN:
+ return self.parseReturnStatement()
+ case token.THROW:
+ return self.parseThrowStatement()
+ case token.TRY:
+ return self.parseTryStatement()
+ }
+
+ expression := self.parseExpression()
+
+ if identifier, isIdentifier := expression.(*ast.Identifier); isIdentifier && self.token == token.COLON {
+ // LabelledStatement
+ colon := self.idx
+ self.next() // :
+ label := identifier.Name
+ for _, value := range self.scope.labels {
+ if label == value {
+ self.error(identifier.Idx0(), "Label '%s' already exists", label)
+ }
+ }
+ self.scope.labels = append(self.scope.labels, label) // Push the label
+ statement := self.parseStatement()
+ self.scope.labels = self.scope.labels[:len(self.scope.labels)-1] // Pop the label
+ return &ast.LabelledStatement{
+ Label: identifier,
+ Colon: colon,
+ Statement: statement,
+ }
+ }
+
+ self.optionalSemicolon()
+
+ return &ast.ExpressionStatement{
+ Expression: expression,
+ }
+}
+
+func (self *_parser) parseTryStatement() ast.Statement {
+
+ node := &ast.TryStatement{
+ Try: self.expect(token.TRY),
+ Body: self.parseBlockStatement(),
+ }
+
+ if self.token == token.CATCH {
+ catch := self.idx
+ self.next()
+ self.expect(token.LEFT_PARENTHESIS)
+ if self.token != token.IDENTIFIER {
+ self.expect(token.IDENTIFIER)
+ self.nextStatement()
+ return &ast.BadStatement{From: catch, To: self.idx}
+ } else {
+ identifier := self.parseIdentifier()
+ self.expect(token.RIGHT_PARENTHESIS)
+ node.Catch = &ast.CatchStatement{
+ Catch: catch,
+ Parameter: identifier,
+ Body: self.parseBlockStatement(),
+ }
+ }
+ }
+
+ if self.token == token.FINALLY {
+ self.next()
+ node.Finally = self.parseBlockStatement()
+ }
+
+ if node.Catch == nil && node.Finally == nil {
+ self.error(node.Try, "Missing catch or finally after try")
+ return &ast.BadStatement{From: node.Try, To: node.Body.Idx1()}
+ }
+
+ return node
+}
+
+func (self *_parser) parseFunctionParameterList() *ast.ParameterList {
+ opening := self.expect(token.LEFT_PARENTHESIS)
+ var list []*ast.Identifier
+ for self.token != token.RIGHT_PARENTHESIS && self.token != token.EOF {
+ if self.token != token.IDENTIFIER {
+ self.expect(token.IDENTIFIER)
+ } else {
+ list = append(list, self.parseIdentifier())
+ }
+ if self.token != token.RIGHT_PARENTHESIS {
+ self.expect(token.COMMA)
+ }
+ }
+ closing := self.expect(token.RIGHT_PARENTHESIS)
+
+ return &ast.ParameterList{
+ Opening: opening,
+ List: list,
+ Closing: closing,
+ }
+}
+
+func (self *_parser) parseParameterList() (list []string) {
+ for self.token != token.EOF {
+ if self.token != token.IDENTIFIER {
+ self.expect(token.IDENTIFIER)
+ }
+ list = append(list, self.literal)
+ self.next()
+ if self.token != token.EOF {
+ self.expect(token.COMMA)
+ }
+ }
+ return
+}
+
+func (self *_parser) parseFunction(declaration bool) *ast.FunctionLiteral {
+
+ node := &ast.FunctionLiteral{
+ Function: self.expect(token.FUNCTION),
+ }
+
+ var name *ast.Identifier
+ if self.token == token.IDENTIFIER {
+ name = self.parseIdentifier()
+ if declaration {
+ self.scope.declare(&ast.FunctionDeclaration{
+ Function: node,
+ })
+ }
+ } else if declaration {
+ // Use expect error handling
+ self.expect(token.IDENTIFIER)
+ }
+ node.Name = name
+ node.ParameterList = self.parseFunctionParameterList()
+ self.parseFunctionBlock(node)
+ node.Source = self.slice(node.Idx0(), node.Idx1())
+
+ return node
+}
+
+func (self *_parser) parseFunctionBlock(node *ast.FunctionLiteral) {
+ {
+ self.openScope()
+ inFunction := self.scope.inFunction
+ self.scope.inFunction = true
+ defer func() {
+ self.scope.inFunction = inFunction
+ self.closeScope()
+ }()
+ node.Body = self.parseBlockStatement()
+ node.DeclarationList = self.scope.declarationList
+ }
+}
+
+func (self *_parser) parseDebuggerStatement() ast.Statement {
+ idx := self.expect(token.DEBUGGER)
+
+ node := &ast.DebuggerStatement{
+ Debugger: idx,
+ }
+
+ self.semicolon()
+
+ return node
+}
+
+func (self *_parser) parseReturnStatement() ast.Statement {
+ idx := self.expect(token.RETURN)
+
+ if !self.scope.inFunction {
+ self.error(idx, "Illegal return statement")
+ self.nextStatement()
+ return &ast.BadStatement{From: idx, To: self.idx}
+ }
+
+ node := &ast.ReturnStatement{
+ Return: idx,
+ }
+
+ if !self.implicitSemicolon && self.token != token.SEMICOLON && self.token != token.RIGHT_BRACE && self.token != token.EOF {
+ node.Argument = self.parseExpression()
+ }
+
+ self.semicolon()
+
+ return node
+}
+
+func (self *_parser) parseThrowStatement() ast.Statement {
+ idx := self.expect(token.THROW)
+
+ if self.implicitSemicolon {
+ if self.chr == -1 { // Hackish
+ self.error(idx, "Unexpected end of input")
+ } else {
+ self.error(idx, "Illegal newline after throw")
+ }
+ self.nextStatement()
+ return &ast.BadStatement{From: idx, To: self.idx}
+ }
+
+ node := &ast.ThrowStatement{
+ Argument: self.parseExpression(),
+ }
+
+ self.semicolon()
+
+ return node
+}
+
+func (self *_parser) parseSwitchStatement() ast.Statement {
+ self.expect(token.SWITCH)
+ self.expect(token.LEFT_PARENTHESIS)
+ node := &ast.SwitchStatement{
+ Discriminant: self.parseExpression(),
+ Default: -1,
+ }
+ self.expect(token.RIGHT_PARENTHESIS)
+
+ self.expect(token.LEFT_BRACE)
+
+ inSwitch := self.scope.inSwitch
+ self.scope.inSwitch = true
+ defer func() {
+ self.scope.inSwitch = inSwitch
+ }()
+
+ for index := 0; self.token != token.EOF; index++ {
+ if self.token == token.RIGHT_BRACE {
+ self.next()
+ break
+ }
+
+ clause := self.parseCaseStatement()
+ if clause.Test == nil {
+ if node.Default != -1 {
+ self.error(clause.Case, "Already saw a default in switch")
+ }
+ node.Default = index
+ }
+ node.Body = append(node.Body, clause)
+ }
+
+ return node
+}
+
+func (self *_parser) parseWithStatement() ast.Statement {
+ self.expect(token.WITH)
+ self.expect(token.LEFT_PARENTHESIS)
+ node := &ast.WithStatement{
+ Object: self.parseExpression(),
+ }
+ self.expect(token.RIGHT_PARENTHESIS)
+
+ node.Body = self.parseStatement()
+
+ return node
+}
+
+func (self *_parser) parseCaseStatement() *ast.CaseStatement {
+
+ node := &ast.CaseStatement{
+ Case: self.idx,
+ }
+ if self.token == token.DEFAULT {
+ self.next()
+ } else {
+ self.expect(token.CASE)
+ node.Test = self.parseExpression()
+ }
+ self.expect(token.COLON)
+
+ for {
+ if self.token == token.EOF ||
+ self.token == token.RIGHT_BRACE ||
+ self.token == token.CASE ||
+ self.token == token.DEFAULT {
+ break
+ }
+ node.Consequent = append(node.Consequent, self.parseStatement())
+
+ }
+
+ return node
+}
+
+func (self *_parser) parseIterationStatement() ast.Statement {
+ inIteration := self.scope.inIteration
+ self.scope.inIteration = true
+ defer func() {
+ self.scope.inIteration = inIteration
+ }()
+ return self.parseStatement()
+}
+
+func (self *_parser) parseForIn(into ast.Expression) *ast.ForInStatement {
+
+ // Already have consumed "<into> in"
+
+ source := self.parseExpression()
+ self.expect(token.RIGHT_PARENTHESIS)
+
+ return &ast.ForInStatement{
+ Into: into,
+ Source: source,
+ Body: self.parseIterationStatement(),
+ }
+}
+
+func (self *_parser) parseFor(initializer ast.Expression) *ast.ForStatement {
+
+ // Already have consumed "<initializer> ;"
+
+ var test, update ast.Expression
+
+ if self.token != token.SEMICOLON {
+ test = self.parseExpression()
+ }
+ self.expect(token.SEMICOLON)
+
+ if self.token != token.RIGHT_PARENTHESIS {
+ update = self.parseExpression()
+ }
+ self.expect(token.RIGHT_PARENTHESIS)
+
+ return &ast.ForStatement{
+ Initializer: initializer,
+ Test: test,
+ Update: update,
+ Body: self.parseIterationStatement(),
+ }
+}
+
+func (self *_parser) parseForOrForInStatement() ast.Statement {
+ idx := self.expect(token.FOR)
+ self.expect(token.LEFT_PARENTHESIS)
+
+ var left []ast.Expression
+
+ forIn := false
+ if self.token != token.SEMICOLON {
+
+ allowIn := self.scope.allowIn
+ self.scope.allowIn = false
+ if self.token == token.VAR {
+ var_ := self.idx
+ self.next()
+ list := self.parseVariableDeclarationList(var_)
+ if len(list) == 1 && self.token == token.IN {
+ self.next() // in
+ forIn = true
+ left = []ast.Expression{list[0]} // There is only one declaration
+ } else {
+ left = list
+ }
+ } else {
+ left = append(left, self.parseExpression())
+ if self.token == token.IN {
+ self.next()
+ forIn = true
+ }
+ }
+ self.scope.allowIn = allowIn
+ }
+
+ if forIn {
+ switch left[0].(type) {
+ case *ast.Identifier, *ast.DotExpression, *ast.BracketExpression, *ast.VariableExpression:
+ // These are all acceptable
+ default:
+ self.error(idx, "Invalid left-hand side in for-in")
+ self.nextStatement()
+ return &ast.BadStatement{From: idx, To: self.idx}
+ }
+ return self.parseForIn(left[0])
+ }
+
+ self.expect(token.SEMICOLON)
+ return self.parseFor(&ast.SequenceExpression{Sequence: left})
+}
+
+func (self *_parser) parseVariableStatement() *ast.VariableStatement {
+
+ idx := self.expect(token.VAR)
+
+ list := self.parseVariableDeclarationList(idx)
+ self.semicolon()
+
+ return &ast.VariableStatement{
+ Var: idx,
+ List: list,
+ }
+}
+
+func (self *_parser) parseDoWhileStatement() ast.Statement {
+ inIteration := self.scope.inIteration
+ self.scope.inIteration = true
+ defer func() {
+ self.scope.inIteration = inIteration
+ }()
+
+ self.expect(token.DO)
+ node := &ast.DoWhileStatement{}
+ if self.token == token.LEFT_BRACE {
+ node.Body = self.parseBlockStatement()
+ } else {
+ node.Body = self.parseStatement()
+ }
+
+ self.expect(token.WHILE)
+ self.expect(token.LEFT_PARENTHESIS)
+ node.Test = self.parseExpression()
+ self.expect(token.RIGHT_PARENTHESIS)
+
+ return node
+}
+
+func (self *_parser) parseWhileStatement() ast.Statement {
+ self.expect(token.WHILE)
+ self.expect(token.LEFT_PARENTHESIS)
+ node := &ast.WhileStatement{
+ Test: self.parseExpression(),
+ }
+ self.expect(token.RIGHT_PARENTHESIS)
+ node.Body = self.parseIterationStatement()
+
+ return node
+}
+
+func (self *_parser) parseIfStatement() ast.Statement {
+ self.expect(token.IF)
+ self.expect(token.LEFT_PARENTHESIS)
+ node := &ast.IfStatement{
+ Test: self.parseExpression(),
+ }
+ self.expect(token.RIGHT_PARENTHESIS)
+
+ if self.token == token.LEFT_BRACE {
+ node.Consequent = self.parseBlockStatement()
+ } else {
+ node.Consequent = self.parseStatement()
+ }
+
+ if self.token == token.ELSE {
+ self.next()
+ node.Alternate = self.parseStatement()
+ }
+
+ return node
+}
+
+func (self *_parser) parseSourceElement() ast.Statement {
+ return self.parseStatement()
+}
+
+func (self *_parser) parseSourceElements() []ast.Statement {
+ body := []ast.Statement(nil)
+
+ for {
+ if self.token != token.STRING {
+ break
+ }
+
+ body = append(body, self.parseSourceElement())
+ }
+
+ for self.token != token.EOF {
+ body = append(body, self.parseSourceElement())
+ }
+
+ return body
+}
+
+func (self *_parser) parseProgram() *ast.Program {
+ self.openScope()
+ defer self.closeScope()
+ return &ast.Program{
+ Body: self.parseSourceElements(),
+ DeclarationList: self.scope.declarationList,
+ File: self.file,
+ }
+}
+
+func (self *_parser) parseBreakStatement() ast.Statement {
+ idx := self.expect(token.BREAK)
+ semicolon := self.implicitSemicolon
+ if self.token == token.SEMICOLON {
+ semicolon = true
+ self.next()
+ }
+
+ if semicolon || self.token == token.RIGHT_BRACE {
+ self.implicitSemicolon = false
+ if !self.scope.inIteration && !self.scope.inSwitch {
+ goto illegal
+ }
+ return &ast.BranchStatement{
+ Idx: idx,
+ Token: token.BREAK,
+ }
+ }
+
+ if self.token == token.IDENTIFIER {
+ identifier := self.parseIdentifier()
+ if !self.scope.hasLabel(identifier.Name) {
+ self.error(idx, "Undefined label '%s'", identifier.Name)
+ return &ast.BadStatement{From: idx, To: identifier.Idx1()}
+ }
+ self.semicolon()
+ return &ast.BranchStatement{
+ Idx: idx,
+ Token: token.BREAK,
+ Label: identifier,
+ }
+ }
+
+ self.expect(token.IDENTIFIER)
+
+illegal:
+ self.error(idx, "Illegal break statement")
+ self.nextStatement()
+ return &ast.BadStatement{From: idx, To: self.idx}
+}
+
+func (self *_parser) parseContinueStatement() ast.Statement {
+ idx := self.expect(token.CONTINUE)
+ semicolon := self.implicitSemicolon
+ if self.token == token.SEMICOLON {
+ semicolon = true
+ self.next()
+ }
+
+ if semicolon || self.token == token.RIGHT_BRACE {
+ self.implicitSemicolon = false
+ if !self.scope.inIteration {
+ goto illegal
+ }
+ return &ast.BranchStatement{
+ Idx: idx,
+ Token: token.CONTINUE,
+ }
+ }
+
+ if self.token == token.IDENTIFIER {
+ identifier := self.parseIdentifier()
+ if !self.scope.hasLabel(identifier.Name) {
+ self.error(idx, "Undefined label '%s'", identifier.Name)
+ return &ast.BadStatement{From: idx, To: identifier.Idx1()}
+ }
+ if !self.scope.inIteration {
+ goto illegal
+ }
+ self.semicolon()
+ return &ast.BranchStatement{
+ Idx: idx,
+ Token: token.CONTINUE,
+ Label: identifier,
+ }
+ }
+
+ self.expect(token.IDENTIFIER)
+
+illegal:
+ self.error(idx, "Illegal continue statement")
+ self.nextStatement()
+ return &ast.BadStatement{From: idx, To: self.idx}
+}
+
+// Find the next statement after an error (recover)
+func (self *_parser) nextStatement() {
+ for {
+ switch self.token {
+ case token.BREAK, token.CONTINUE,
+ token.FOR, token.IF, token.RETURN, token.SWITCH,
+ token.VAR, token.DO, token.TRY, token.WITH,
+ token.WHILE, token.THROW, token.CATCH, token.FINALLY:
+ // Return only if parser made some progress since last
+ // sync or if it has not reached 10 next calls without
+ // progress. Otherwise consume at least one token to
+ // avoid an endless parser loop
+ if self.idx == self.recover.idx && self.recover.count < 10 {
+ self.recover.count++
+ return
+ }
+ if self.idx > self.recover.idx {
+ self.recover.idx = self.idx
+ self.recover.count = 0
+ return
+ }
+ // Reaching here indicates a parser bug, likely an
+ // incorrect token list in this function, but it only
+ // leads to skipping of possibly correct code if a
+ // previous error is present, and thus is preferred
+ // over a non-terminating parse.
+ case token.EOF:
+ return
+ }
+ self.next()
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/parser_test.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/parser_test.go
new file mode 100644
index 000000000..7db43d239
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/parser_test.go
@@ -0,0 +1,42 @@
+package otto
+
+import (
+ "testing"
+)
+
+func TestPersistence(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ function abc() { return 1; }
+ abc.toString();
+ `, "function abc() { return 1; }")
+
+ test(`
+ function def() { return 3.14159; }
+ [ abc.toString(), def.toString() ];
+ `, "function abc() { return 1; },function def() { return 3.14159; }")
+
+ test(`
+ eval("function ghi() { return 'ghi' }");
+ [ abc.toString(), def.toString(), ghi.toString() ];
+ `, "function abc() { return 1; },function def() { return 3.14159; },function ghi() { return 'ghi' }")
+
+ test(`
+ [ abc.toString(), def.toString(), ghi.toString() ];
+ `, "function abc() { return 1; },function def() { return 3.14159; },function ghi() { return 'ghi' }")
+
+ test(`/*
+
+
+
+
+
+
+
+
+
+ */`, UndefinedValue())
+ })
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/property.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/property.go
new file mode 100644
index 000000000..5445eccde
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/property.go
@@ -0,0 +1,220 @@
+package otto
+
+// property
+
+type _propertyMode int
+
+const (
+ modeWriteMask _propertyMode = 0700
+ modeEnumerateMask = 0070
+ modeConfigureMask = 0007
+ modeOnMask = 0111
+ modeOffMask = 0000
+ modeSetMask = 0222 // If value is 2, then mode is neither "On" nor "Off"
+)
+
+type _propertyGetSet [2]*_object
+
+var _nilGetSetObject _object = _object{}
+
+type _property struct {
+ value interface{}
+ mode _propertyMode
+}
+
+func (self _property) writable() bool {
+ return self.mode&modeWriteMask == modeWriteMask&modeOnMask
+}
+
+func (self *_property) writeOn() {
+ self.mode = (self.mode & ^modeWriteMask) | (modeWriteMask & modeOnMask)
+}
+
+func (self *_property) writeOff() {
+ self.mode &= ^modeWriteMask
+}
+
+func (self *_property) writeClear() {
+ self.mode = (self.mode & ^modeWriteMask) | (modeWriteMask & modeSetMask)
+}
+
+func (self _property) writeSet() bool {
+ return 0 == self.mode&modeWriteMask&modeSetMask
+}
+
+func (self _property) enumerable() bool {
+ return self.mode&modeEnumerateMask == modeEnumerateMask&modeOnMask
+}
+
+func (self *_property) enumerateOn() {
+ self.mode = (self.mode & ^modeEnumerateMask) | (modeEnumerateMask & modeOnMask)
+}
+
+func (self *_property) enumerateOff() {
+ self.mode &= ^modeEnumerateMask
+}
+
+func (self _property) enumerateSet() bool {
+ return 0 == self.mode&modeEnumerateMask&modeSetMask
+}
+
+func (self _property) configurable() bool {
+ return self.mode&modeConfigureMask == modeConfigureMask&modeOnMask
+}
+
+func (self *_property) configureOn() {
+ self.mode = (self.mode & ^modeConfigureMask) | (modeConfigureMask & modeOnMask)
+}
+
+func (self *_property) configureOff() {
+ self.mode &= ^modeConfigureMask
+}
+
+func (self _property) configureSet() bool {
+ return 0 == self.mode&modeConfigureMask&modeSetMask
+}
+
+func (self _property) copy() *_property {
+ property := self
+ return &property
+}
+
+func (self _property) get(this *_object) Value {
+ switch value := self.value.(type) {
+ case Value:
+ return value
+ case _propertyGetSet:
+ if value[0] != nil {
+ return value[0].call(toValue(this), nil, false, nativeFrame)
+ }
+ }
+ return Value{}
+}
+
+func (self _property) isAccessorDescriptor() bool {
+ setGet, test := self.value.(_propertyGetSet)
+ return test && (setGet[0] != nil || setGet[1] != nil)
+}
+
+func (self _property) isDataDescriptor() bool {
+ if self.writeSet() { // Either "On" or "Off"
+ return true
+ }
+ value, valid := self.value.(Value)
+ return valid && !value.isEmpty()
+}
+
+func (self _property) isGenericDescriptor() bool {
+ return !(self.isDataDescriptor() || self.isAccessorDescriptor())
+}
+
+func (self _property) isEmpty() bool {
+ return self.mode == 0222 && self.isGenericDescriptor()
+}
+
+// _enumerableValue, _enumerableTrue, _enumerableFalse?
+// .enumerableValue() .enumerableExists()
+
+func toPropertyDescriptor(rt *_runtime, value Value) (descriptor _property) {
+ objectDescriptor := value._object()
+ if objectDescriptor == nil {
+ panic(rt.panicTypeError())
+ }
+
+ {
+ descriptor.mode = modeSetMask // Initially nothing is set
+ if objectDescriptor.hasProperty("enumerable") {
+ if objectDescriptor.get("enumerable").bool() {
+ descriptor.enumerateOn()
+ } else {
+ descriptor.enumerateOff()
+ }
+ }
+
+ if objectDescriptor.hasProperty("configurable") {
+ if objectDescriptor.get("configurable").bool() {
+ descriptor.configureOn()
+ } else {
+ descriptor.configureOff()
+ }
+ }
+
+ if objectDescriptor.hasProperty("writable") {
+ if objectDescriptor.get("writable").bool() {
+ descriptor.writeOn()
+ } else {
+ descriptor.writeOff()
+ }
+ }
+ }
+
+ var getter, setter *_object
+ getterSetter := false
+
+ if objectDescriptor.hasProperty("get") {
+ value := objectDescriptor.get("get")
+ if value.IsDefined() {
+ if !value.isCallable() {
+ panic(rt.panicTypeError())
+ }
+ getter = value._object()
+ getterSetter = true
+ } else {
+ getter = &_nilGetSetObject
+ getterSetter = true
+ }
+ }
+
+ if objectDescriptor.hasProperty("set") {
+ value := objectDescriptor.get("set")
+ if value.IsDefined() {
+ if !value.isCallable() {
+ panic(rt.panicTypeError())
+ }
+ setter = value._object()
+ getterSetter = true
+ } else {
+ setter = &_nilGetSetObject
+ getterSetter = true
+ }
+ }
+
+ if getterSetter {
+ if descriptor.writeSet() {
+ panic(rt.panicTypeError())
+ }
+ descriptor.value = _propertyGetSet{getter, setter}
+ }
+
+ if objectDescriptor.hasProperty("value") {
+ if getterSetter {
+ panic(rt.panicTypeError())
+ }
+ descriptor.value = objectDescriptor.get("value")
+ }
+
+ return
+}
+
+func (self *_runtime) fromPropertyDescriptor(descriptor _property) *_object {
+ object := self.newObject()
+ if descriptor.isDataDescriptor() {
+ object.defineProperty("value", descriptor.value.(Value), 0111, false)
+ object.defineProperty("writable", toValue_bool(descriptor.writable()), 0111, false)
+ } else if descriptor.isAccessorDescriptor() {
+ getSet := descriptor.value.(_propertyGetSet)
+ get := Value{}
+ if getSet[0] != nil {
+ get = toValue_object(getSet[0])
+ }
+ set := Value{}
+ if getSet[1] != nil {
+ set = toValue_object(getSet[1])
+ }
+ object.defineProperty("get", get, 0111, false)
+ object.defineProperty("set", set, 0111, false)
+ }
+ object.defineProperty("enumerable", toValue_bool(descriptor.enumerable()), 0111, false)
+ object.defineProperty("configurable", toValue_bool(descriptor.configurable()), 0111, false)
+ return object
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/reflect_test.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/reflect_test.go
new file mode 100644
index 000000000..e4e83adeb
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/reflect_test.go
@@ -0,0 +1,483 @@
+package otto
+
+import (
+ "math"
+ "reflect"
+ "testing"
+)
+
+type _abcStruct struct {
+ Abc bool
+ Def int
+ Ghi string
+ Jkl interface{}
+ Mno _mnoStruct
+ Pqr map[string]int8
+}
+
+func (abc _abcStruct) String() string {
+ return abc.Ghi
+}
+
+func (abc *_abcStruct) FuncPointer() string {
+ return "abc"
+}
+
+func (abc _abcStruct) Func() {
+ return
+}
+
+func (abc _abcStruct) FuncReturn1() string {
+ return "abc"
+}
+
+func (abc _abcStruct) FuncReturn2() (string, error) {
+ return "def", nil
+}
+
+func (abc _abcStruct) Func1Return1(a string) string {
+ return a
+}
+
+func (abc _abcStruct) Func2Return1(x, y string) string {
+ return x + y
+}
+
+func (abc _abcStruct) FuncEllipsis(xyz ...string) int {
+ return len(xyz)
+}
+
+func (abc _abcStruct) FuncReturnStruct() _mnoStruct {
+ return _mnoStruct{}
+}
+
+type _mnoStruct struct {
+ Ghi string
+}
+
+func (mno _mnoStruct) Func() string {
+ return "mno"
+}
+
+func TestReflect(t *testing.T) {
+ if true {
+ return
+ }
+ tt(t, func() {
+ // Testing dbgf
+ // These should panic
+ toValue("Xyzzy").toReflectValue(reflect.Ptr)
+ stringToReflectValue("Xyzzy", reflect.Ptr)
+ })
+}
+
+func Test_reflectStruct(t *testing.T) {
+ tt(t, func() {
+ test, vm := test()
+
+ // _abcStruct
+ {
+ abc := &_abcStruct{}
+ vm.Set("abc", abc)
+
+ test(`
+ [ abc.Abc, abc.Ghi ];
+ `, "false,")
+
+ abc.Abc = true
+ abc.Ghi = "Nothing happens."
+
+ test(`
+ [ abc.Abc, abc.Ghi ];
+ `, "true,Nothing happens.")
+
+ *abc = _abcStruct{}
+
+ test(`
+ [ abc.Abc, abc.Ghi ];
+ `, "false,")
+
+ abc.Abc = true
+ abc.Ghi = "Xyzzy"
+ vm.Set("abc", abc)
+
+ test(`
+ [ abc.Abc, abc.Ghi ];
+ `, "true,Xyzzy")
+
+ is(abc.Abc, true)
+ test(`
+ abc.Abc = false;
+ abc.Def = 451;
+ abc.Ghi = "Nothing happens.";
+ abc.abc = "Something happens.";
+ [ abc.Def, abc.abc ];
+ `, "451,Something happens.")
+ is(abc.Abc, false)
+ is(abc.Def, 451)
+ is(abc.Ghi, "Nothing happens.")
+
+ test(`
+ delete abc.Def;
+ delete abc.abc;
+ [ abc.Def, abc.abc ];
+ `, "451,")
+ is(abc.Def, 451)
+
+ test(`
+ abc.FuncPointer();
+ `, "abc")
+
+ test(`
+ abc.Func();
+ `, "undefined")
+
+ test(`
+ abc.FuncReturn1();
+ `, "abc")
+
+ test(`
+ abc.Func1Return1("abc");
+ `, "abc")
+
+ test(`
+ abc.Func2Return1("abc", "def");
+ `, "abcdef")
+
+ test(`
+ abc.FuncEllipsis("abc", "def", "ghi");
+ `, 3)
+
+ test(`raise:
+ abc.FuncReturn2();
+ `, "TypeError")
+
+ test(`
+ abc.FuncReturnStruct();
+ `, "[object Object]")
+
+ test(`
+ abc.FuncReturnStruct().Func();
+ `, "mno")
+ }
+ })
+}
+
+func Test_reflectMap(t *testing.T) {
+ tt(t, func() {
+ test, vm := test()
+
+ // map[string]string
+ {
+ abc := map[string]string{
+ "Xyzzy": "Nothing happens.",
+ "def": "1",
+ }
+ vm.Set("abc", abc)
+
+ test(`
+ abc.xyz = "pqr";
+ [ abc.Xyzzy, abc.def, abc.ghi ];
+ `, "Nothing happens.,1,")
+
+ is(abc["xyz"], "pqr")
+ }
+
+ // map[string]float64
+ {
+ abc := map[string]float64{
+ "Xyzzy": math.Pi,
+ "def": 1,
+ }
+ vm.Set("abc", abc)
+
+ test(`
+ abc.xyz = "pqr";
+ abc.jkl = 10;
+ [ abc.Xyzzy, abc.def, abc.ghi ];
+ `, "3.141592653589793,1,")
+
+ is(abc["xyz"], math.NaN())
+ is(abc["jkl"], float64(10))
+ }
+
+ // map[string]int32
+ {
+ abc := map[string]int32{
+ "Xyzzy": 3,
+ "def": 1,
+ }
+ vm.Set("abc", abc)
+
+ test(`
+ abc.xyz = "pqr";
+ abc.jkl = 10;
+ [ abc.Xyzzy, abc.def, abc.ghi ];
+ `, "3,1,")
+
+ is(abc["xyz"], 0)
+ is(abc["jkl"], int32(10))
+
+ test(`
+ delete abc["Xyzzy"];
+ `)
+
+ _, exists := abc["Xyzzy"]
+ is(exists, false)
+ is(abc["Xyzzy"], 0)
+ }
+
+ // map[int32]string
+ {
+ abc := map[int32]string{
+ 0: "abc",
+ 1: "def",
+ }
+ vm.Set("abc", abc)
+
+ test(`
+ abc[2] = "pqr";
+ //abc.jkl = 10;
+ abc[3] = 10;
+ [ abc[0], abc[1], abc[2], abc[3] ]
+ `, "abc,def,pqr,10")
+
+ is(abc[2], "pqr")
+ is(abc[3], "10")
+
+ test(`
+ delete abc[2];
+ `)
+
+ _, exists := abc[2]
+ is(exists, false)
+ }
+
+ })
+}
+
+func Test_reflectSlice(t *testing.T) {
+ tt(t, func() {
+ test, vm := test()
+
+ // []bool
+ {
+ abc := []bool{
+ false,
+ true,
+ true,
+ false,
+ }
+ vm.Set("abc", abc)
+
+ test(`
+ abc;
+ `, "false,true,true,false")
+
+ test(`
+ abc[0] = true;
+ abc[abc.length-1] = true;
+ delete abc[2];
+ abc;
+ `, "true,true,false,true")
+
+ is(abc, []bool{true, true, false, true})
+ is(abc[len(abc)-1], true)
+ }
+
+ // []int32
+ {
+ abc := make([]int32, 4)
+ vm.Set("abc", abc)
+
+ test(`
+ abc;
+ `, "0,0,0,0")
+
+ test(`
+ abc[0] = 4.2;
+ abc[1] = "42";
+ abc[2] = 3.14;
+ abc;
+ `, "4,42,3,0")
+
+ is(abc, []int32{4, 42, 3, 0})
+
+ test(`
+ delete abc[1];
+ delete abc[2];
+ `)
+ is(abc[1], 0)
+ is(abc[2], 0)
+ }
+ })
+}
+
+func Test_reflectArray(t *testing.T) {
+ tt(t, func() {
+ test, vm := test()
+
+ // []bool
+ {
+ abc := [4]bool{
+ false,
+ true,
+ true,
+ false,
+ }
+ vm.Set("abc", abc)
+
+ test(`
+ abc;
+ `, "false,true,true,false")
+ // Unaddressable array
+
+ test(`
+ abc[0] = true;
+ abc[abc.length-1] = true;
+ abc;
+ `, "false,true,true,false")
+ // Again, unaddressable array
+
+ is(abc, [4]bool{false, true, true, false})
+ is(abc[len(abc)-1], false)
+ // ...
+ }
+
+ // []int32
+ {
+ abc := make([]int32, 4)
+ vm.Set("abc", abc)
+
+ test(`
+ abc;
+ `, "0,0,0,0")
+
+ test(`
+ abc[0] = 4.2;
+ abc[1] = "42";
+ abc[2] = 3.14;
+ abc;
+ `, "4,42,3,0")
+
+ is(abc, []int32{4, 42, 3, 0})
+ }
+
+ // []bool
+ {
+ abc := [4]bool{
+ false,
+ true,
+ true,
+ false,
+ }
+ vm.Set("abc", &abc)
+
+ test(`
+ abc;
+ `, "false,true,true,false")
+
+ test(`
+ abc[0] = true;
+ abc[abc.length-1] = true;
+ delete abc[2];
+ abc;
+ `, "true,true,false,true")
+
+ is(abc, [4]bool{true, true, false, true})
+ is(abc[len(abc)-1], true)
+ }
+
+ })
+}
+
+func Test_reflectArray_concat(t *testing.T) {
+ tt(t, func() {
+ test, vm := test()
+
+ vm.Set("ghi", []string{"jkl", "mno"})
+ vm.Set("pqr", []interface{}{"jkl", 42, 3.14159, true})
+ test(`
+ var def = {
+ "abc": ["abc"],
+ "xyz": ["xyz"]
+ };
+ xyz = pqr.concat(ghi, def.abc, def, def.xyz);
+ [ xyz, xyz.length ];
+ `, "jkl,42,3.14159,true,jkl,mno,abc,[object Object],xyz,9")
+ })
+}
+
+func Test_reflectMapInterface(t *testing.T) {
+ tt(t, func() {
+ test, vm := test()
+
+ {
+ abc := map[string]interface{}{
+ "Xyzzy": "Nothing happens.",
+ "def": "1",
+ "jkl": "jkl",
+ }
+ vm.Set("abc", abc)
+ vm.Set("mno", &_abcStruct{})
+
+ test(`
+ abc.xyz = "pqr";
+ abc.ghi = {};
+ abc.jkl = 3.14159;
+ abc.mno = mno;
+ mno.Abc = true;
+ mno.Ghi = "Something happens.";
+ [ abc.Xyzzy, abc.def, abc.ghi, abc.mno ];
+ `, "Nothing happens.,1,[object Object],[object Object]")
+
+ is(abc["xyz"], "pqr")
+ is(abc["ghi"], "[object Object]")
+ is(abc["jkl"], float64(3.14159))
+ mno, valid := abc["mno"].(*_abcStruct)
+ is(valid, true)
+ is(mno.Abc, true)
+ is(mno.Ghi, "Something happens.")
+ }
+ })
+}
+
+func TestPassthrough(t *testing.T) {
+ tt(t, func() {
+ test, vm := test()
+
+ {
+ abc := &_abcStruct{
+ Mno: _mnoStruct{
+ Ghi: "<Mno.Ghi>",
+ },
+ }
+ vm.Set("abc", abc)
+
+ test(`
+ abc.Mno.Ghi;
+ `, "<Mno.Ghi>")
+
+ vm.Set("pqr", map[string]int8{
+ "xyzzy": 0,
+ "Nothing happens.": 1,
+ })
+
+ test(`
+ abc.Ghi = "abc";
+ abc.Pqr = pqr;
+ abc.Pqr["Nothing happens."];
+ `, 1)
+
+ mno := _mnoStruct{
+ Ghi: "<mno.Ghi>",
+ }
+ vm.Set("mno", mno)
+
+ test(`
+ abc.Mno = mno;
+ abc.Mno.Ghi;
+ `, "<mno.Ghi>")
+ }
+ })
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/regexp_test.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/regexp_test.go
new file mode 100644
index 000000000..8e65ee46a
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/regexp_test.go
@@ -0,0 +1,290 @@
+package otto
+
+import (
+ "fmt"
+ "testing"
+)
+
+func TestRegExp(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ [
+ /abc/.toString(),
+ /abc/gim.toString(),
+ ""+/abc/gi.toString(),
+ new RegExp("1(\\d+)").toString(),
+ ];
+ `, "/abc/,/abc/gim,/abc/gi,/1(\\d+)/")
+
+ test(`
+ [
+ new RegExp("abc").exec("123abc456"),
+ null === new RegExp("xyzzy").exec("123abc456"),
+ new RegExp("1(\\d+)").exec("123abc456"),
+ new RegExp("xyzzy").test("123abc456"),
+ new RegExp("1(\\d+)").test("123abc456"),
+ new RegExp("abc").exec("123abc456"),
+ ];
+ `, "abc,true,123,23,false,true,abc")
+
+ test(`new RegExp("abc").toString()`, "/abc/")
+ test(`new RegExp("abc", "g").toString()`, "/abc/g")
+ test(`new RegExp("abc", "mig").toString()`, "/abc/gim")
+
+ result := test(`/(a)?/.exec('b')`, ",")
+ is(result._object().get("0"), "")
+ is(result._object().get("1"), "undefined")
+ is(result._object().get("length"), 2)
+
+ result = test(`/(a)?(b)?/.exec('b')`, "b,,b")
+ is(result._object().get("0"), "b")
+ is(result._object().get("1"), "undefined")
+ is(result._object().get("2"), "b")
+ is(result._object().get("length"), 3)
+
+ test(`/\u0041/.source`, "\\u0041")
+ test(`/\a/.source`, "\\a")
+ test(`/\;/.source`, "\\;")
+
+ test(`/a\a/.source`, "a\\a")
+ test(`/,\;/.source`, ",\\;")
+ test(`/ \ /.source`, " \\ ")
+
+ // Start sanity check...
+ test("eval(\"/abc/\").source", "abc")
+ test("eval(\"/\u0023/\").source", "#")
+ test("eval(\"/\u0058/\").source", "X")
+ test("eval(\"/\\\u0023/\").source == \"\\\u0023\"", true)
+ test("'0x' + '0058'", "0x0058")
+ test("'\\\\' + '0x' + '0058'", "\\0x0058")
+ // ...stop sanity check
+
+ test(`abc = '\\' + String.fromCharCode('0x' + '0058'); eval('/' + abc + '/').source`, "\\X")
+ test(`abc = '\\' + String.fromCharCode('0x0058'); eval('/' + abc + '/').source == "\\\u0058"`, true)
+ test(`abc = '\\' + String.fromCharCode('0x0023'); eval('/' + abc + '/').source == "\\\u0023"`, true)
+ test(`abc = '\\' + String.fromCharCode('0x0078'); eval('/' + abc + '/').source == "\\\u0078"`, true)
+
+ test(`
+ var abc = Object.getOwnPropertyDescriptor(RegExp, "prototype");
+ [ [ typeof RegExp.prototype ],
+ [ abc.writable, abc.enumerable, abc.configurable ] ];
+ `, "object,false,false,false")
+ })
+}
+
+func TestRegExp_global(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ var abc = /(?:ab|cd)\d?/g;
+ var found = [];
+ do {
+ match = abc.exec("ab cd2 ab34 cd");
+ if (match !== null) {
+ found.push(match[0]);
+ } else {
+ break;
+ }
+ } while (true);
+ found;
+ `, "ab,cd2,ab3,cd")
+ })
+}
+
+func TestRegExp_exec(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ abc = /./g;
+ def = '123456';
+ ghi = 0;
+ while (ghi < 100 && abc.exec(def) !== null) {
+ ghi += 1;
+ }
+ [ ghi, def.length, ghi == def.length ];
+ `, "6,6,true")
+
+ test(`
+ abc = /[abc](\d)?/g;
+ def = 'a0 b c1 d3';
+ ghi = 0;
+ lastIndex = 0;
+ while (ghi < 100 && abc.exec(def) !== null) {
+ lastIndex = abc.lastIndex;
+ ghi += 1;
+
+ }
+ [ ghi, lastIndex ];
+ `, "3,7")
+
+ test(`
+ var abc = /[abc](\d)?/.exec("a0 b c1 d3");
+ [ abc.length, abc.input, abc.index, abc ];
+ `, "2,a0 b c1 d3,0,a0,0")
+
+ test(`raise:
+ var exec = RegExp.prototype.exec;
+ exec("Xyzzy");
+ `, "TypeError: Calling RegExp.exec on a non-RegExp object")
+
+ test(`
+ var abc = /\w{3}\d?/.exec("CE\uFFFFL\uFFDDbox127");
+ [ abc.input.length, abc.length, abc.input, abc.index, abc ];
+ `, "11,1,CE\uFFFFL\uFFDDbox127,5,box1")
+
+ test(`RegExp.prototype.exec.length`, 1)
+ test(`RegExp.prototype.exec.prototype`, "undefined")
+ })
+}
+
+func TestRegExp_test(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`RegExp.prototype.test.length`, 1)
+ test(`RegExp.prototype.test.prototype`, "undefined")
+ })
+}
+
+func TestRegExp_toString(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`RegExp.prototype.toString.length`, 0)
+ test(`RegExp.prototype.toString.prototype`, "undefined")
+ })
+}
+
+func TestRegExp_zaacbbbcac(t *testing.T) {
+ if true {
+ return
+ }
+
+ tt(t, func() {
+ test, _ := test()
+
+ // FIXME? TODO /(z)((a+)?(b+)?(c))*/.exec("zaacbbbcac")
+ test(`
+ var abc = /(z)((a+)?(b+)?(c))*/.exec("zaacbbbcac");
+ [ abc.length, abc.index, abc ];
+ `, "6,0,zaacbbbcac,z,ac,a,,c")
+ })
+}
+
+func TestRegExpCopying(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ abc = /xyzzy/i;
+ def = RegExp(abc);
+ abc.indicator = 1;
+ [ abc.indicator, def.indicator ];
+ `, "1,1")
+
+ test(`raise:
+ RegExp(new RegExp("\\d"), "1");
+ `, "TypeError: Cannot supply flags when constructing one RegExp from another")
+ })
+}
+
+func TestRegExp_multiline(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ var abc = /s$/m.exec("pairs\nmakes\tdouble");
+ [ abc.length, abc.index, abc ];
+ `, "1,4,s")
+ })
+}
+
+func TestRegExp_source(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ [ /xyzzy/i.source, /./i.source ];
+ `, "xyzzy,.")
+
+ test(`
+ var abc = /./i;
+ var def = new RegExp(abc);
+ [ abc.source, def.source, abc.source === def.source ];
+ `, ".,.,true")
+
+ test(`
+ var abc = /./i;
+ var def = abc.hasOwnProperty("source");
+ var ghi = abc.source;
+ abc.source = "xyzzy";
+ [ def, abc.source ];
+ `, "true,.")
+ })
+}
+
+func TestRegExp_newRegExp(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ Math.toString();
+ var abc = new RegExp(Math,eval("\"g\""));
+ [ abc, abc.global ];
+ `, "/[object Math]/g,true")
+ })
+}
+
+func TestRegExp_flags(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ var abc = /./i;
+ var def = new RegExp(abc);
+ [ abc.multiline == def.multiline, abc.global == def.global, abc.ignoreCase == def.ignoreCase ];
+ `, "true,true,true")
+ })
+}
+
+func TestRegExp_controlCharacter(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ for code := 0x41; code < 0x5a; code++ {
+ string_ := string(code - 64)
+ test(fmt.Sprintf(`
+ var code = 0x%x;
+ var string = String.fromCharCode(code %% 32);
+ var result = (new RegExp("\\c" + String.fromCharCode(code))).exec(string);
+ [ code, string, result ];
+ `, code), fmt.Sprintf("%d,%s,%s", code, string_, string_))
+ }
+ })
+}
+
+func TestRegExp_notNotEmptyCharacterClass(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ var abc = /[\s\S]a/m.exec("a\naba");
+ [ abc.length, abc.input, abc ];
+ `, "1,a\naba,\na")
+ })
+}
+
+func TestRegExp_compile(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ var abc = /[\s\S]a/;
+ abc.compile('^\w+');
+ `, "undefined")
+ })
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/registry/README.markdown b/Godeps/_workspace/src/github.com/robertkrimen/otto/registry/README.markdown
new file mode 100644
index 000000000..ba2d38909
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/registry/README.markdown
@@ -0,0 +1,51 @@
+# registry
+--
+ import "github.com/robertkrimen/otto/registry"
+
+Package registry is an expirmental package to facillitate altering the otto
+runtime via import.
+
+This interface can change at any time.
+
+## Usage
+
+#### func Apply
+
+```go
+func Apply(callback func(Entry))
+```
+
+#### type Entry
+
+```go
+type Entry struct {
+}
+```
+
+
+#### func Register
+
+```go
+func Register(source func() string) *Entry
+```
+
+#### func (*Entry) Disable
+
+```go
+func (self *Entry) Disable()
+```
+
+#### func (*Entry) Enable
+
+```go
+func (self *Entry) Enable()
+```
+
+#### func (Entry) Source
+
+```go
+func (self Entry) Source() string
+```
+
+--
+**godocdown** http://github.com/robertkrimen/godocdown
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/registry/registry.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/registry/registry.go
new file mode 100644
index 000000000..966638ac4
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/registry/registry.go
@@ -0,0 +1,47 @@
+/*
+Package registry is an expirmental package to facillitate altering the otto runtime via import.
+
+This interface can change at any time.
+*/
+package registry
+
+var registry []*Entry = make([]*Entry, 0)
+
+type Entry struct {
+ active bool
+ source func() string
+}
+
+func newEntry(source func() string) *Entry {
+ return &Entry{
+ active: true,
+ source: source,
+ }
+}
+
+func (self *Entry) Enable() {
+ self.active = true
+}
+
+func (self *Entry) Disable() {
+ self.active = false
+}
+
+func (self Entry) Source() string {
+ return self.source()
+}
+
+func Apply(callback func(Entry)) {
+ for _, entry := range registry {
+ if !entry.active {
+ continue
+ }
+ callback(*entry)
+ }
+}
+
+func Register(source func() string) *Entry {
+ entry := newEntry(source)
+ registry = append(registry, entry)
+ return entry
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/result.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/result.go
new file mode 100644
index 000000000..63642e7d0
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/result.go
@@ -0,0 +1,30 @@
+package otto
+
+import ()
+
+type _resultKind int
+
+const (
+ resultNormal _resultKind = iota
+ resultReturn
+ resultBreak
+ resultContinue
+)
+
+type _result struct {
+ kind _resultKind
+ value Value
+ target string
+}
+
+func newReturnResult(value Value) _result {
+ return _result{resultReturn, value, ""}
+}
+
+func newContinueResult(target string) _result {
+ return _result{resultContinue, emptyValue, target}
+}
+
+func newBreakResult(target string) _result {
+ return _result{resultBreak, emptyValue, target}
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/runtime.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/runtime.go
new file mode 100644
index 000000000..1ac1b435e
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/runtime.go
@@ -0,0 +1,331 @@
+package otto
+
+import (
+ "errors"
+ "reflect"
+ "sync"
+
+ "github.com/robertkrimen/otto/ast"
+ "github.com/robertkrimen/otto/parser"
+)
+
+type _global struct {
+ Object *_object // Object( ... ), new Object( ... ) - 1 (length)
+ Function *_object // Function( ... ), new Function( ... ) - 1
+ Array *_object // Array( ... ), new Array( ... ) - 1
+ String *_object // String( ... ), new String( ... ) - 1
+ Boolean *_object // Boolean( ... ), new Boolean( ... ) - 1
+ Number *_object // Number( ... ), new Number( ... ) - 1
+ Math *_object
+ Date *_object // Date( ... ), new Date( ... ) - 7
+ RegExp *_object // RegExp( ... ), new RegExp( ... ) - 2
+ Error *_object // Error( ... ), new Error( ... ) - 1
+ EvalError *_object
+ TypeError *_object
+ RangeError *_object
+ ReferenceError *_object
+ SyntaxError *_object
+ URIError *_object
+ JSON *_object
+
+ ObjectPrototype *_object // Object.prototype
+ FunctionPrototype *_object // Function.prototype
+ ArrayPrototype *_object // Array.prototype
+ StringPrototype *_object // String.prototype
+ BooleanPrototype *_object // Boolean.prototype
+ NumberPrototype *_object // Number.prototype
+ DatePrototype *_object // Date.prototype
+ RegExpPrototype *_object // RegExp.prototype
+ ErrorPrototype *_object // Error.prototype
+ EvalErrorPrototype *_object
+ TypeErrorPrototype *_object
+ RangeErrorPrototype *_object
+ ReferenceErrorPrototype *_object
+ SyntaxErrorPrototype *_object
+ URIErrorPrototype *_object
+}
+
+type _runtime struct {
+ global _global
+ globalObject *_object
+ globalStash *_objectStash
+ scope *_scope
+ otto *Otto
+ eval *_object // The builtin eval, for determine indirect versus direct invocation
+
+ labels []string // FIXME
+ lck sync.Mutex
+}
+
+func (self *_runtime) enterScope(scope *_scope) {
+ scope.outer = self.scope
+ self.scope = scope
+}
+
+func (self *_runtime) leaveScope() {
+ self.scope = self.scope.outer
+}
+
+// FIXME This is used in two places (cloning)
+func (self *_runtime) enterGlobalScope() {
+ self.enterScope(newScope(self.globalStash, self.globalStash, self.globalObject))
+}
+
+func (self *_runtime) enterFunctionScope(outer _stash, this Value) *_fnStash {
+ if outer == nil {
+ outer = self.globalStash
+ }
+ stash := self.newFunctionStash(outer)
+ var thisObject *_object
+ switch this.kind {
+ case valueUndefined, valueNull:
+ thisObject = self.globalObject
+ default:
+ thisObject = self.toObject(this)
+ }
+ self.enterScope(newScope(stash, stash, thisObject))
+ return stash
+}
+
+func (self *_runtime) putValue(reference _reference, value Value) {
+ name := reference.putValue(value)
+ if name != "" {
+ // Why? -- If reference.base == nil
+ // strict = false
+ self.globalObject.defineProperty(name, value, 0111, false)
+ }
+}
+
+func (self *_runtime) tryCatchEvaluate(inner func() Value) (tryValue Value, exception bool) {
+ // resultValue = The value of the block (e.g. the last statement)
+ // throw = Something was thrown
+ // throwValue = The value of what was thrown
+ // other = Something that changes flow (return, break, continue) that is not a throw
+ // Otherwise, some sort of unknown panic happened, we'll just propagate it
+ defer func() {
+ if caught := recover(); caught != nil {
+ if exception, ok := caught.(*_exception); ok {
+ caught = exception.eject()
+ }
+ switch caught := caught.(type) {
+ case _error:
+ exception = true
+ tryValue = toValue_object(self.newError(caught.name, caught.messageValue()))
+ case Value:
+ exception = true
+ tryValue = caught
+ default:
+ panic(caught)
+ }
+ }
+ }()
+
+ tryValue = inner()
+ return
+}
+
+// toObject
+
+func (self *_runtime) toObject(value Value) *_object {
+ switch value.kind {
+ case valueEmpty, valueUndefined, valueNull:
+ panic(self.panicTypeError())
+ case valueBoolean:
+ return self.newBoolean(value)
+ case valueString:
+ return self.newString(value)
+ case valueNumber:
+ return self.newNumber(value)
+ case valueObject:
+ return value._object()
+ }
+ panic(self.panicTypeError())
+}
+
+func (self *_runtime) objectCoerce(value Value) (*_object, error) {
+ switch value.kind {
+ case valueUndefined:
+ return nil, errors.New("undefined")
+ case valueNull:
+ return nil, errors.New("null")
+ case valueBoolean:
+ return self.newBoolean(value), nil
+ case valueString:
+ return self.newString(value), nil
+ case valueNumber:
+ return self.newNumber(value), nil
+ case valueObject:
+ return value._object(), nil
+ }
+ panic(self.panicTypeError())
+}
+
+func checkObjectCoercible(rt *_runtime, value Value) {
+ isObject, mustCoerce := testObjectCoercible(value)
+ if !isObject && !mustCoerce {
+ panic(rt.panicTypeError())
+ }
+}
+
+// testObjectCoercible
+
+func testObjectCoercible(value Value) (isObject bool, mustCoerce bool) {
+ switch value.kind {
+ case valueReference, valueEmpty, valueNull, valueUndefined:
+ return false, false
+ case valueNumber, valueString, valueBoolean:
+ isObject = false
+ mustCoerce = true
+ case valueObject:
+ isObject = true
+ mustCoerce = false
+ }
+ return
+}
+
+func (self *_runtime) safeToValue(value interface{}) (Value, error) {
+ result := Value{}
+ err := catchPanic(func() {
+ result = self.toValue(value)
+ })
+ return result, err
+}
+
+func (self *_runtime) toValue(value interface{}) Value {
+ switch value := value.(type) {
+ case Value:
+ return value
+ case func(FunctionCall) Value:
+ return toValue_object(self.newNativeFunction("", value))
+ case _nativeFunction:
+ return toValue_object(self.newNativeFunction("", value))
+ case Object, *Object, _object, *_object:
+ // Nothing happens.
+ // FIXME We should really figure out what can come here.
+ // This catch-all is ugly.
+ default:
+ {
+ value := reflect.ValueOf(value)
+ switch value.Kind() {
+ case reflect.Ptr:
+ switch reflect.Indirect(value).Kind() {
+ case reflect.Struct:
+ return toValue_object(self.newGoStructObject(value))
+ case reflect.Array:
+ return toValue_object(self.newGoArray(value))
+ }
+ case reflect.Func:
+ // TODO Maybe cache this?
+ return toValue_object(self.newNativeFunction("", func(call FunctionCall) Value {
+ in := make([]reflect.Value, len(call.ArgumentList))
+ for i, value := range call.ArgumentList {
+ in[i] = reflect.ValueOf(value.export())
+ }
+
+ out := value.Call(in)
+ if len(out) == 1 {
+ return self.toValue(out[0].Interface())
+ } else if len(out) == 0 {
+ return Value{}
+ }
+
+ panic(call.runtime.panicTypeError())
+ }))
+ case reflect.Struct:
+ return toValue_object(self.newGoStructObject(value))
+ case reflect.Map:
+ return toValue_object(self.newGoMapObject(value))
+ case reflect.Slice:
+ return toValue_object(self.newGoSlice(value))
+ case reflect.Array:
+ return toValue_object(self.newGoArray(value))
+ }
+ }
+ }
+ return toValue(value)
+}
+
+func (runtime *_runtime) newGoSlice(value reflect.Value) *_object {
+ self := runtime.newGoSliceObject(value)
+ self.prototype = runtime.global.ArrayPrototype
+ return self
+}
+
+func (runtime *_runtime) newGoArray(value reflect.Value) *_object {
+ self := runtime.newGoArrayObject(value)
+ self.prototype = runtime.global.ArrayPrototype
+ return self
+}
+
+func (runtime *_runtime) parse(filename string, src interface{}) (*ast.Program, error) {
+ return parser.ParseFile(nil, filename, src, 0)
+}
+
+func (runtime *_runtime) cmpl_parse(filename string, src interface{}) (*_nodeProgram, error) {
+ program, err := parser.ParseFile(nil, filename, src, 0)
+ if err != nil {
+ return nil, err
+ }
+ return cmpl_parse(program), nil
+}
+
+func (self *_runtime) parseSource(src interface{}) (*_nodeProgram, *ast.Program, error) {
+ switch src := src.(type) {
+ case *ast.Program:
+ return nil, src, nil
+ case *Script:
+ return src.program, nil, nil
+ }
+ program, err := self.parse("", src)
+ return nil, program, err
+}
+
+func (self *_runtime) cmpl_run(src interface{}) (Value, error) {
+ result := Value{}
+ cmpl_program, program, err := self.parseSource(src)
+ if err != nil {
+ return result, err
+ }
+ if cmpl_program == nil {
+ cmpl_program = cmpl_parse(program)
+ }
+ err = catchPanic(func() {
+ result = self.cmpl_evaluate_nodeProgram(cmpl_program, false)
+ })
+ switch result.kind {
+ case valueEmpty:
+ result = Value{}
+ case valueReference:
+ result = result.resolve()
+ }
+ return result, err
+}
+
+func (self *_runtime) parseThrow(err error) {
+ if err == nil {
+ return
+ }
+ switch err := err.(type) {
+ case parser.ErrorList:
+ {
+ err := err[0]
+ if err.Message == "Invalid left-hand side in assignment" {
+ panic(self.panicReferenceError(err.Message))
+ }
+ panic(self.panicSyntaxError(err.Message))
+ }
+ }
+ panic(self.panicSyntaxError(err.Error()))
+}
+
+func (self *_runtime) parseOrThrow(source string) *ast.Program {
+ program, err := self.parse("", source)
+ self.parseThrow(err) // Will panic/throw appropriately
+ return program
+}
+
+func (self *_runtime) cmpl_parseOrThrow(source string) *_nodeProgram {
+ program, err := self.cmpl_parse("", source)
+ self.parseThrow(err) // Will panic/throw appropriately
+ return program
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/runtime_test.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/runtime_test.go
new file mode 100644
index 000000000..2510a0b3f
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/runtime_test.go
@@ -0,0 +1,778 @@
+package otto
+
+import (
+ "math"
+ "testing"
+)
+
+// FIXME terst, Review tests
+
+func TestOperator(t *testing.T) {
+ tt(t, func() {
+ test, vm := test()
+
+ test("xyzzy = 1")
+ test("xyzzy", 1)
+
+ if true {
+ vm.Set("twoPlusTwo", func(FunctionCall) Value {
+ return toValue(5)
+ })
+ test("twoPlusTwo( 1 )", 5)
+
+ test("1 + twoPlusTwo( 1 )", 6)
+
+ test("-1 + twoPlusTwo( 1 )", 4)
+ }
+
+ test("result = 4")
+ test("result", 4)
+
+ test("result += 1")
+ test("result", 5)
+
+ test("result *= 2")
+ test("result", 10)
+
+ test("result /= 2")
+ test("result", 5)
+
+ test("result = 112.51 % 3.1")
+ test("result", 0.9100000000000019)
+
+ test("result = 'Xyzzy'")
+ test("result", "Xyzzy")
+
+ test("result = 'Xyz' + 'zy'")
+ test("result", "Xyzzy")
+
+ test("result = \"Xyzzy\"")
+ test("result", "Xyzzy")
+
+ test("result = 1; result = result")
+ test("result", 1)
+
+ test(`
+ var result64
+ =
+ 64
+ , result10 =
+ 10
+ `)
+ test("result64", 64)
+ test("result10", 10)
+
+ test(`
+ result = 1;
+ result += 1;
+ `)
+ test("result", 2)
+ })
+}
+
+func TestFunction_(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ result = 2
+ xyzzy = function() {
+ result += 1
+ }
+ xyzzy()
+ result;
+ `, 3)
+
+ test(`
+ xyzzy = function() {
+ return 1
+ }
+ result = xyzzy()
+ `, 1)
+
+ test(`
+ xyzzy = function() {}
+ result = xyzzy()
+ `, "undefined")
+
+ test(`
+ xyzzy = function() {
+ return 64
+ return 1
+ }
+ result = xyzzy()
+ `, 64)
+
+ test(`
+ result = 4
+ xyzzy = function() {
+ result = 2
+ }
+ xyzzy();
+ result;
+ `, 2)
+
+ test(`
+ result = 4
+ xyzzy = function() {
+ var result
+ result = 2
+ }
+ xyzzy();
+ result;
+ `, 4)
+
+ test(`
+ xyzzy = function() {
+ var result = 4
+ return result
+ }
+ result = xyzzy()
+ `, 4)
+
+ test(`
+ xyzzy = function() {
+ function test() {
+ var result = 1
+ return result
+ }
+ return test() + 1
+ }
+ result = xyzzy() + 1
+ `, 3)
+
+ test(`
+ xyzzy = function() {
+ function test() {
+ var result = 1
+ return result
+ }
+ _xyzzy = 2
+ var result = _xyzzy + test() + 1
+ return result
+ }
+ result = xyzzy() + 1;
+ [ result, _xyzzy ];
+ `, "5,2")
+
+ test(`
+ xyzzy = function(apple) {
+ return 1
+ }
+ result = xyzzy(1)
+ `, 1)
+
+ test(`
+ xyzzy = function(apple) {
+ return apple + 1
+ }
+ result = xyzzy(2)
+ `, 3)
+
+ test(`
+ {
+ result = 1
+ result += 1;
+ }
+ `, 2)
+
+ test(`
+ var global = 1
+ outer = function() {
+ var global = 2
+ var inner = function(){
+ return global
+ }
+ return inner()
+ }
+ result = outer()
+ `, 2)
+
+ test(`
+ var apple = 1
+ var banana = function() {
+ return apple
+ }
+ var cherry = function() {
+ var apple = 2
+ return banana()
+ }
+ result = cherry()
+ `, 1)
+
+ test(`
+ function xyz() {
+ };
+ delete xyz;
+ `, false)
+
+ test(`
+ var abc = function __factorial(def){
+ if (def === 1) {
+ return def;
+ } else {
+ return __factorial(def-1)*def;
+ }
+ };
+ abc(3);
+ `, 6)
+ })
+}
+
+func TestDoWhile(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ limit = 4;
+ result = 0;
+ do {
+ result = result + 1;
+ limit = limit - 1;
+ } while (limit);
+ result;
+ `, 4)
+
+ test(`
+ result = eval("do {abc=1; break; abc=2;} while (0);");
+ [ result, abc ];
+ `, "1,1")
+ })
+}
+
+func TestContinueBreak(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ limit = 4
+ result = 0
+ while (limit) {
+ limit = limit - 1
+ if (limit) {
+ }
+ else {
+ break
+ }
+ result = result + 1
+ }
+ [ result, limit ];
+ `, "3,0")
+
+ test(`
+ limit = 4
+ result = 0
+ while (limit) {
+ limit = limit - 1
+ if (limit) {
+ continue
+ }
+ else {
+ break
+ }
+ result = result + 1
+ }
+ result;
+ `, 0)
+
+ test(`
+ limit = 4
+ result = 0
+ do {
+ limit = limit - 1
+ if (limit) {
+ continue
+ }
+ else {
+ break
+ }
+ result = result + 1
+ } while (limit)
+ result;
+ `, 0)
+ })
+}
+
+func TestTryCatchError(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ var abc
+ try {
+ 1()
+ }
+ catch (def) {
+ abc = def
+ }
+ abc;
+ `, "TypeError: 1 is not a function")
+
+ })
+}
+
+func TestPositiveNegativeZero(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`1/0`, _Infinity)
+ test(`1/-0`, -_Infinity)
+ test(`
+ abc = -0
+ 1/abc
+ `, -_Infinity)
+ })
+}
+
+func TestComparison(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ undefined = 1; undefined;
+ `, "undefined")
+
+ test("undefined == undefined", true)
+
+ test("undefined != undefined", false)
+
+ test("null == null", true)
+
+ test("null != null", false)
+
+ test("0 == 1", false)
+
+ is(negativeZero(), -0)
+ is(positiveZero(), 0)
+ is(math.Signbit(negativeZero()), true)
+ is(positiveZero() == negativeZero(), true)
+
+ test("1 == 1", true)
+
+ test("'Hello, World.' == 'Goodbye, World.'", false)
+
+ test("'Hello, World.' == true", false)
+
+ test("'Hello, World.' == false", false)
+
+ test("'Hello, World.' == 1", false)
+
+ test("1 == 'Hello, World.'", false)
+
+ is(parseNumber("-1"), -1)
+
+ test("0+Object", "0function Object() { [native code] }")
+ })
+}
+
+func TestComparisonRelational(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test("0 < 0", false)
+
+ test("0 > 0", false)
+
+ test("0 <= 0", true)
+
+ test("0 >= 0", true)
+
+ test("' 0' >= 0", true)
+
+ test("'_ 0' >= 0", false)
+ })
+}
+
+func TestArguments(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ xyzzy = function() {
+ return arguments[0]
+ }
+ result = xyzzy("xyzzy");
+ `, "xyzzy")
+
+ test(`
+ xyzzy = function() {
+ arguments[0] = "abcdef"
+ return arguments[0]
+ }
+ result = xyzzy("xyzzy");
+ `, "abcdef")
+
+ test(`
+ xyzzy = function(apple) {
+ apple = "abcdef"
+ return arguments[0]
+ }
+ result = xyzzy("xyzzy");
+ `, "abcdef")
+
+ test(`
+ (function(){
+ return arguments
+ })()
+ `, "[object Arguments]")
+
+ test(`
+ (function(){
+ return arguments.length
+ })()
+ `, 0)
+
+ test(`
+ (function(){
+ return arguments.length
+ })(1, 2, 4, 8, 10)
+ `, 5)
+ })
+}
+
+func TestObjectLiteral(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ ({});
+ `, "[object Object]")
+
+ test(`
+ var abc = {
+ xyzzy: "Nothing happens.",
+ get 1e2() {
+ return 3.14159;
+ },
+ get null() {
+ return true;
+ },
+ get "[\n]"() {
+ return "<>";
+ }
+ };
+ [ abc["1e2"], abc.null, abc["[\n]"] ];
+ `, "3.14159,true,<>")
+
+ test(`
+ var abc = {
+ xyzzy: "Nothing happens.",
+ set 1e2() {
+ this[3.14159] = 100;
+ return Math.random();
+ },
+ set null(def) {
+ this.def = def;
+ return Math.random();
+ },
+ };
+ [ abc["1e2"] = Infinity, abc[3.14159], abc.null = "xyz", abc.def ];
+ `, "Infinity,100,xyz,xyz")
+ })
+}
+
+func TestUnaryPrefix(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ var result = 0;
+ [++result, result];
+ `, "1,1")
+
+ test(`
+ result = 0;
+ [--result, result];
+ `, "-1,-1")
+
+ test(`
+ var object = { valueOf: function() { return 1; } };
+ result = ++object;
+ [ result, typeof result ];
+ `, "2,number")
+
+ test(`
+ var object = { valueOf: function() { return 1; } };
+ result = --object;
+ [ result, typeof result ];
+ `, "0,number")
+ })
+}
+
+func TestUnaryPostfix(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ var result = 0;
+ result++;
+ [ result++, result ];
+ `, "1,2")
+
+ test(`
+ result = 0;
+ result--;
+ [ result--, result ];
+ `, "-1,-2")
+
+ test(`
+ var object = { valueOf: function() { return 1; } };
+ result = object++;
+ [ result, typeof result ];
+ `, "1,number")
+
+ test(`
+ var object = { valueOf: function() { return 1; } };
+ result = object--
+ [ result, typeof result ];
+ `, "1,number")
+ })
+}
+
+func TestBinaryLogicalOperation(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ abc = true
+ def = false
+ ghi = false
+ jkl = false
+ result = abc && def || ghi && jkl
+ `, false)
+
+ test(`
+ abc = true
+ def = true
+ ghi = false
+ jkl = false
+ result = abc && def || ghi && jkl
+ `, true)
+
+ })
+}
+
+func TestBinaryBitwiseOperation(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ abc = 1 & 2;
+ def = 1 & 3;
+ ghi = 1 | 3;
+ jkl = 1 ^ 2;
+ mno = 1 ^ 3;
+ [ abc, def, ghi, jkl, mno ];
+ `, "0,1,3,3,2")
+ })
+}
+
+func TestBinaryShiftOperation(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ high = (1 << 30) - 1 + (1 << 30)
+ low = -high - 1
+ abc = 23 << 1
+ def = -105 >> 1
+ ghi = 23 << 2
+ jkl = 1 >>> 31
+ mno = 1 << 64
+ pqr = 1 >> 2
+ stu = -2 >> 4
+ vwx = low >> 1
+ yz = low >>> 1
+ `)
+ test("abc", 46)
+ test("def", -53)
+ test("ghi", 92)
+ test("jkl", 0)
+ test("mno", 1)
+ test("pqr", 0)
+ test("stu", -1)
+ test("vwx", -1073741824)
+ test("yz", 1073741824)
+ })
+}
+
+func TestParenthesizing(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ abc = 1 + 2 * 3
+ def = (1 + 2) * 3
+ ghi = !(false || true)
+ jkl = !false || true
+ `)
+ test("abc", 7)
+ test("def", 9)
+ test("ghi", false)
+ test("jkl", true)
+ })
+}
+
+func Test_instanceof(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ abc = {} instanceof Object;
+ `, true)
+
+ test(`
+ abc = "abc" instanceof Object;
+ `, false)
+
+ test(`raise:
+ abc = {} instanceof "abc";
+ `, "TypeError: Expecting a function in instanceof check, but got: abc")
+
+ test(`raise:
+ "xyzzy" instanceof Math;
+ `, "TypeError")
+ })
+}
+
+func TestIn(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ abc = "prototype" in Object;
+ def = "xyzzy" in Object;
+ [ abc, def ];
+ `, "true,false")
+ })
+}
+
+func Test_new(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ abc = new Boolean;
+ def = new Boolean(1);
+ [ abc, def ];
+ `, "false,true")
+ })
+}
+
+func TestNewFunction(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ new Function("return 11")()
+ `, 11)
+
+ test(`
+ abc = 10
+ new Function("abc += 1")()
+ abc
+ `, 11)
+
+ test(`
+ new Function("a", "b", "c", "return b + 2")(10, 11, 12)
+ `, 13)
+
+ test(`raise:
+ new 1
+ `, "TypeError: 1 is not a function")
+
+ // TODO Better error reporting: new this
+ test(`raise:
+ new this
+ `, "TypeError: [object environment] is not a function")
+
+ test(`raise:
+ new {}
+ `, "TypeError: [object Object] is not a function")
+ })
+}
+
+func TestNewPrototype(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ abc = { 'xyzzy': 'Nothing happens.' }
+ function Xyzzy(){}
+ Xyzzy.prototype = abc;
+ (new Xyzzy()).xyzzy
+ `, "Nothing happens.")
+ })
+}
+
+func TestBlock(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ var abc=0;
+ var ghi;
+ def: {
+ do {
+ abc++;
+ if (!(abc < 10)) {
+ break def;
+ ghi = "ghi";
+ }
+ } while (true);
+ }
+ [ abc,ghi ];
+ `, "10,")
+ })
+}
+
+func Test_toString(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ [undefined+""]
+ `, "undefined")
+ })
+}
+
+func TestEvaluationOrder(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ var abc = 0;
+ abc < (abc = 1) === true;
+ `, true)
+ })
+}
+
+func TestClone(t *testing.T) {
+ tt(t, func() {
+ vm1 := New()
+ vm1.Run(`
+ var abc = 1;
+ `)
+
+ vm2 := vm1.clone()
+ vm1.Run(`
+ abc += 2;
+ `)
+ vm2.Run(`
+ abc += 4;
+ `)
+
+ is(vm1.getValue("abc"), 3)
+ is(vm2.getValue("abc"), 5)
+ })
+}
+
+func Test_debugger(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ debugger;
+ `, "undefined")
+ })
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/scope.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/scope.go
new file mode 100644
index 000000000..b80808434
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/scope.go
@@ -0,0 +1,34 @@
+package otto
+
+// _scope:
+// entryFile
+// entryIdx
+// top?
+// outer => nil
+
+// _stash:
+// lexical
+// variable
+//
+// _thisStash (ObjectEnvironment)
+// _fnStash
+// _dclStash
+
+// An ECMA-262 ExecutionContext
+type _scope struct {
+ lexical _stash
+ variable _stash
+ this *_object
+ eval bool // Replace this with kind?
+ outer *_scope
+
+ frame _frame
+}
+
+func newScope(lexical _stash, variable _stash, this *_object) *_scope {
+ return &_scope{
+ lexical: lexical,
+ variable: variable,
+ this: this,
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/script.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/script.go
new file mode 100644
index 000000000..ed8aebbf4
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/script.go
@@ -0,0 +1,122 @@
+package otto
+
+import (
+ "bytes"
+ "encoding/gob"
+ "errors"
+
+ "github.com/robertkrimen/otto/parser"
+)
+
+var ErrVersion = errors.New("version mismatch")
+
+var scriptVersion = "2014-04-13/1"
+
+// Script is a handle for some (reusable) JavaScript.
+// Passing a Script value to a run method will evaluate the JavaScript.
+//
+type Script struct {
+ version string
+ program *_nodeProgram
+ filename string
+ src string
+}
+
+// Compile will parse the given source and return a Script value or nil and
+// an error if there was a problem during compilation.
+//
+// script, err := vm.Compile("", `var abc; if (!abc) abc = 0; abc += 2; abc;`)
+// vm.Run(script)
+//
+func (self *Otto) Compile(filename string, src interface{}) (*Script, error) {
+ {
+ src, err := parser.ReadSource(filename, src)
+ if err != nil {
+ return nil, err
+ }
+
+ program, err := self.runtime.parse(filename, src)
+ if err != nil {
+ return nil, err
+ }
+
+ cmpl_program := cmpl_parse(program)
+
+ script := &Script{
+ version: scriptVersion,
+ program: cmpl_program,
+ filename: filename,
+ src: string(src),
+ }
+
+ return script, nil
+ }
+}
+
+func (self *Script) String() string {
+ return "// " + self.filename + "\n" + self.src
+}
+
+// MarshalBinary will marshal a script into a binary form. A marshalled script
+// that is later unmarshalled can be executed on the same version of the otto runtime.
+//
+// The binary format can change at any time and should be considered unspecified and opaque.
+//
+func (self *Script) marshalBinary() ([]byte, error) {
+ var bfr bytes.Buffer
+ encoder := gob.NewEncoder(&bfr)
+ err := encoder.Encode(self.version)
+ if err != nil {
+ return nil, err
+ }
+ err = encoder.Encode(self.program)
+ if err != nil {
+ return nil, err
+ }
+ err = encoder.Encode(self.filename)
+ if err != nil {
+ return nil, err
+ }
+ err = encoder.Encode(self.src)
+ if err != nil {
+ return nil, err
+ }
+ return bfr.Bytes(), nil
+}
+
+// UnmarshalBinary will vivify a marshalled script into something usable. If the script was
+// originally marshalled on a different version of the otto runtime, then this method
+// will return an error.
+//
+// The binary format can change at any time and should be considered unspecified and opaque.
+//
+func (self *Script) unmarshalBinary(data []byte) error {
+ decoder := gob.NewDecoder(bytes.NewReader(data))
+ err := decoder.Decode(&self.version)
+ if err != nil {
+ goto error
+ }
+ if self.version != scriptVersion {
+ err = ErrVersion
+ goto error
+ }
+ err = decoder.Decode(&self.program)
+ if err != nil {
+ goto error
+ }
+ err = decoder.Decode(&self.filename)
+ if err != nil {
+ goto error
+ }
+ err = decoder.Decode(&self.src)
+ if err != nil {
+ goto error
+ }
+ return nil
+error:
+ self.version = ""
+ self.program = nil
+ self.filename = ""
+ self.src = ""
+ return err
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/script_test.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/script_test.go
new file mode 100644
index 000000000..4c35c646e
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/script_test.go
@@ -0,0 +1,78 @@
+package otto
+
+import (
+ "testing"
+)
+
+func TestScript(t *testing.T) {
+ tt(t, func() {
+ vm := New()
+
+ script, err := vm.Compile("xyzzy", `var abc; if (!abc) abc = 0; abc += 2; abc;`)
+ is(err, nil)
+
+ str := script.String()
+ is(str, "// xyzzy\nvar abc; if (!abc) abc = 0; abc += 2; abc;")
+
+ value, err := vm.Run(script)
+ is(err, nil)
+ is(value, 2)
+
+ if true {
+ return
+ }
+
+ tmp, err := script.marshalBinary()
+ is(err, nil)
+ is(len(tmp), 1228)
+
+ {
+ script := &Script{}
+ err = script.unmarshalBinary(tmp)
+ is(err, nil)
+
+ is(script.String(), str)
+
+ value, err = vm.Run(script)
+ is(err, nil)
+ is(value, 4)
+
+ tmp, err = script.marshalBinary()
+ is(err, nil)
+ is(len(tmp), 1228)
+ }
+
+ {
+ script := &Script{}
+ err = script.unmarshalBinary(tmp)
+ is(err, nil)
+
+ is(script.String(), str)
+
+ value, err := vm.Run(script)
+ is(err, nil)
+ is(value, 6)
+
+ tmp, err = script.marshalBinary()
+ is(err, nil)
+ is(len(tmp), 1228)
+ }
+
+ {
+ version := scriptVersion
+ scriptVersion = "bogus"
+
+ script := &Script{}
+ err = script.unmarshalBinary(tmp)
+ is(err, "version mismatch")
+
+ is(script.String(), "// \n")
+ is(script.version, "")
+ is(script.program == nil, true)
+ is(script.filename, "")
+ is(script.src, "")
+
+ scriptVersion = version
+ }
+ })
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/stash.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/stash.go
new file mode 100644
index 000000000..578708d3f
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/stash.go
@@ -0,0 +1,275 @@
+package otto
+
+import (
+ "fmt"
+)
+
+// ======
+// _stash
+// ======
+
+type _stash interface {
+ hasBinding(string) bool //
+ createBinding(string, bool, Value) // CreateMutableBinding
+ setBinding(string, Value, bool) // SetMutableBinding
+ getBinding(string, bool) Value // GetBindingValue
+ deleteBinding(string) bool //
+ setValue(string, Value, bool) // createBinding + setBinding
+
+ outer() _stash
+ runtime() *_runtime
+
+ newReference(string, bool, _at) _reference
+
+ clone(clone *_clone) _stash
+}
+
+// ==========
+// _objectStash
+// ==========
+
+type _objectStash struct {
+ _runtime *_runtime
+ _outer _stash
+ object *_object
+}
+
+func (self *_objectStash) runtime() *_runtime {
+ return self._runtime
+}
+
+func (runtime *_runtime) newObjectStash(object *_object, outer _stash) *_objectStash {
+ if object == nil {
+ object = runtime.newBaseObject()
+ object.class = "environment"
+ }
+ return &_objectStash{
+ _runtime: runtime,
+ _outer: outer,
+ object: object,
+ }
+}
+
+func (in *_objectStash) clone(clone *_clone) _stash {
+ out, exists := clone.objectStash(in)
+ if exists {
+ return out
+ }
+ *out = _objectStash{
+ clone.runtime,
+ clone.stash(in._outer),
+ clone.object(in.object),
+ }
+ return out
+}
+
+func (self *_objectStash) hasBinding(name string) bool {
+ return self.object.hasProperty(name)
+}
+
+func (self *_objectStash) createBinding(name string, deletable bool, value Value) {
+ if self.object.hasProperty(name) {
+ panic(hereBeDragons())
+ }
+ mode := _propertyMode(0111)
+ if !deletable {
+ mode = _propertyMode(0110)
+ }
+ // TODO False?
+ self.object.defineProperty(name, value, mode, false)
+}
+
+func (self *_objectStash) setBinding(name string, value Value, strict bool) {
+ self.object.put(name, value, strict)
+}
+
+func (self *_objectStash) setValue(name string, value Value, throw bool) {
+ if !self.hasBinding(name) {
+ self.createBinding(name, true, value) // Configurable by default
+ } else {
+ self.setBinding(name, value, throw)
+ }
+}
+
+func (self *_objectStash) getBinding(name string, throw bool) Value {
+ if self.object.hasProperty(name) {
+ return self.object.get(name)
+ }
+ if throw { // strict?
+ panic(self._runtime.panicReferenceError("Not Defined", name))
+ }
+ return Value{}
+}
+
+func (self *_objectStash) deleteBinding(name string) bool {
+ return self.object.delete(name, false)
+}
+
+func (self *_objectStash) outer() _stash {
+ return self._outer
+}
+
+func (self *_objectStash) newReference(name string, strict bool, at _at) _reference {
+ return newPropertyReference(self._runtime, self.object, name, strict, at)
+}
+
+// =========
+// _dclStash
+// =========
+
+type _dclStash struct {
+ _runtime *_runtime
+ _outer _stash
+ property map[string]_dclProperty
+}
+
+type _dclProperty struct {
+ value Value
+ mutable bool
+ deletable bool
+ readable bool
+}
+
+func (runtime *_runtime) newDeclarationStash(outer _stash) *_dclStash {
+ return &_dclStash{
+ _runtime: runtime,
+ _outer: outer,
+ property: map[string]_dclProperty{},
+ }
+}
+
+func (in *_dclStash) clone(clone *_clone) _stash {
+ out, exists := clone.dclStash(in)
+ if exists {
+ return out
+ }
+ property := make(map[string]_dclProperty, len(in.property))
+ for index, value := range in.property {
+ property[index] = clone.dclProperty(value)
+ }
+ *out = _dclStash{
+ clone.runtime,
+ clone.stash(in._outer),
+ property,
+ }
+ return out
+}
+
+func (self *_dclStash) hasBinding(name string) bool {
+ _, exists := self.property[name]
+ return exists
+}
+
+func (self *_dclStash) runtime() *_runtime {
+ return self._runtime
+}
+
+func (self *_dclStash) createBinding(name string, deletable bool, value Value) {
+ _, exists := self.property[name]
+ if exists {
+ panic(fmt.Errorf("createBinding: %s: already exists", name))
+ }
+ self.property[name] = _dclProperty{
+ value: value,
+ mutable: true,
+ deletable: deletable,
+ readable: false,
+ }
+}
+
+func (self *_dclStash) setBinding(name string, value Value, strict bool) {
+ property, exists := self.property[name]
+ if !exists {
+ panic(fmt.Errorf("setBinding: %s: missing", name))
+ }
+ if property.mutable {
+ property.value = value
+ self.property[name] = property
+ } else {
+ self._runtime.typeErrorResult(strict)
+ }
+}
+
+func (self *_dclStash) setValue(name string, value Value, throw bool) {
+ if !self.hasBinding(name) {
+ self.createBinding(name, false, value) // NOT deletable by default
+ } else {
+ self.setBinding(name, value, throw)
+ }
+}
+
+// FIXME This is called a __lot__
+func (self *_dclStash) getBinding(name string, throw bool) Value {
+ property, exists := self.property[name]
+ if !exists {
+ panic(fmt.Errorf("getBinding: %s: missing", name))
+ }
+ if !property.mutable && !property.readable {
+ if throw { // strict?
+ panic(self._runtime.panicTypeError())
+ }
+ return Value{}
+ }
+ return property.value
+}
+
+func (self *_dclStash) deleteBinding(name string) bool {
+ property, exists := self.property[name]
+ if !exists {
+ return true
+ }
+ if !property.deletable {
+ return false
+ }
+ delete(self.property, name)
+ return true
+}
+
+func (self *_dclStash) outer() _stash {
+ return self._outer
+}
+
+func (self *_dclStash) newReference(name string, strict bool, _ _at) _reference {
+ return &_stashReference{
+ name: name,
+ base: self,
+ }
+}
+
+// ========
+// _fnStash
+// ========
+
+type _fnStash struct {
+ _dclStash
+ arguments *_object
+ indexOfArgumentName map[string]string
+}
+
+func (runtime *_runtime) newFunctionStash(outer _stash) *_fnStash {
+ return &_fnStash{
+ _dclStash: _dclStash{
+ _runtime: runtime,
+ _outer: outer,
+ property: map[string]_dclProperty{},
+ },
+ }
+}
+
+func (in *_fnStash) clone(clone *_clone) _stash {
+ out, exists := clone.fnStash(in)
+ if exists {
+ return out
+ }
+ dclStash := in._dclStash.clone(clone).(*_dclStash)
+ index := make(map[string]string, len(in.indexOfArgumentName))
+ for name, value := range in.indexOfArgumentName {
+ index[name] = value
+ }
+ *out = _fnStash{
+ _dclStash: *dclStash,
+ arguments: clone.object(in.arguments),
+ indexOfArgumentName: index,
+ }
+ return out
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/string_test.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/string_test.go
new file mode 100644
index 000000000..b7b06324b
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/string_test.go
@@ -0,0 +1,365 @@
+package otto
+
+import (
+ "testing"
+)
+
+func TestString(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ abc = (new String("xyzzy")).length;
+ def = new String().length;
+ ghi = new String("Nothing happens.").length;
+ `)
+ test("abc", 5)
+ test("def", 0)
+ test("ghi", 16)
+ test(`"".length`, 0)
+ test(`"a\uFFFFbc".length`, 4)
+ test(`String(+0)`, "0")
+ test(`String(-0)`, "0")
+ test(`""+-0`, "0")
+ test(`
+ var abc = Object.getOwnPropertyDescriptor(String, "prototype");
+ [ [ typeof String.prototype ],
+ [ abc.writable, abc.enumerable, abc.configurable ] ];
+ `, "object,false,false,false")
+ })
+}
+
+func TestString_charAt(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ abc = "xyzzy".charAt(0)
+ def = "xyzzy".charAt(11)
+ `)
+ test("abc", "x")
+ test("def", "")
+ })
+}
+
+func TestString_charCodeAt(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`
+ abc = "xyzzy".charCodeAt(0)
+ def = "xyzzy".charCodeAt(11)
+ `)
+ test("abc", 120)
+ test("def", _NaN)
+ })
+}
+
+func TestString_fromCharCode(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`String.fromCharCode()`, []uint16{})
+ test(`String.fromCharCode(88, 121, 122, 122, 121)`, []uint16{88, 121, 122, 122, 121}) // FIXME terst, Double-check these...
+ test(`String.fromCharCode("88", 121, 122, 122.05, 121)`, []uint16{88, 121, 122, 122, 121})
+ test(`String.fromCharCode("88", 121, 122, NaN, 121)`, []uint16{88, 121, 122, 0, 121})
+ test(`String.fromCharCode("0x21")`, []uint16{33})
+ test(`String.fromCharCode(-1).charCodeAt(0)`, 65535)
+ test(`String.fromCharCode(65535).charCodeAt(0)`, 65535)
+ test(`String.fromCharCode(65534).charCodeAt(0)`, 65534)
+ test(`String.fromCharCode(4294967295).charCodeAt(0)`, 65535)
+ test(`String.fromCharCode(4294967294).charCodeAt(0)`, 65534)
+ test(`String.fromCharCode(0x0024) === "$"`, true)
+ })
+}
+
+func TestString_concat(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`"".concat()`, "")
+ test(`"".concat("abc", "def")`, "abcdef")
+ test(`"".concat("abc", undefined, "def")`, "abcundefineddef")
+ })
+}
+
+func TestString_indexOf(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`"".indexOf("")`, 0)
+ test(`"".indexOf("", 11)`, 0)
+ test(`"abc".indexOf("")`, 0)
+ test(`"abc".indexOf("", 11)`, 3)
+ test(`"abc".indexOf("a")`, 0)
+ test(`"abc".indexOf("bc")`, 1)
+ test(`"abc".indexOf("bc", 11)`, -1)
+ test(`"$$abcdabcd".indexOf("ab", function(){return -Infinity;}())`, 2)
+ test(`"$$abcdabcd".indexOf("ab", function(){return NaN;}())`, 2)
+
+ test(`
+ var abc = {toString:function(){return "\u0041B";}}
+ var def = {valueOf:function(){return true;}}
+ var ghi = "ABB\u0041BABAB";
+ var jkl;
+ with(ghi) {
+ jkl = indexOf(abc, def);
+ }
+ jkl;
+ `, 3)
+ })
+}
+
+func TestString_lastIndexOf(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`"".lastIndexOf("")`, 0)
+ test(`"".lastIndexOf("", 11)`, 0)
+ test(`"abc".lastIndexOf("")`, 3)
+ test(`"abc".lastIndexOf("", 11)`, 3)
+ test(`"abc".lastIndexOf("a")`, 0)
+ test(`"abc".lastIndexOf("bc")`, 1)
+ test(`"abc".lastIndexOf("bc", 11)`, 1)
+ test(`"abc".lastIndexOf("bc", 0)`, -1)
+ test(`"abc".lastIndexOf("abcabcabc", 2)`, -1)
+ test(`"abc".lastIndexOf("abc", 0)`, 0)
+ test(`"abc".lastIndexOf("abc", 1)`, 0)
+ test(`"abc".lastIndexOf("abc", 2)`, 0)
+ test(`"abc".lastIndexOf("abc", 3)`, 0)
+
+ test(`
+ abc = new Object(true);
+ abc.lastIndexOf = String.prototype.lastIndexOf;
+ abc.lastIndexOf(true, false);
+ `, 0)
+ })
+}
+
+func TestString_match(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`"abc____abc_abc___".match(/__abc/)`, "__abc")
+ test(`"abc___abc_abc__abc__abc".match(/abc/g)`, "abc,abc,abc,abc,abc")
+ test(`"abc____abc_abc___".match(/__abc/g)`, "__abc")
+ test(`
+ abc = /abc/g
+ "abc___abc_abc__abc__abc".match(abc)
+ `, "abc,abc,abc,abc,abc")
+ test(`abc.lastIndex`, 23)
+ })
+}
+
+func TestString_replace(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`"abc_abc".replace(/abc/, "$&123")`, "abc123_abc")
+ test(`"abc_abc".replace(/abc/g, "$&123")`, "abc123_abc123")
+ test(`"abc_abc_".replace(/abc/g, "$&123")`, "abc123_abc123_")
+ test(`"_abc_abc_".replace(/abc/g, "$&123")`, "_abc123_abc123_")
+ test(`"abc".replace(/abc/, "$&123")`, "abc123")
+ test(`"abc_".replace(/abc/, "$&123")`, "abc123_")
+ test("\"^abc$\".replace(/abc/, \"$`def\")", "^^def$")
+ test("\"^abc$\".replace(/abc/, \"def$`\")", "^def^$")
+ test(`"_abc_abd_".replace(/ab(c|d)/g, "$1")`, "_c_d_")
+ test(`
+ "_abc_abd_".replace(/ab(c|d)/g, function(){
+ })
+ `, "_undefined_undefined_")
+
+ test(`"b".replace(/(a)?(b)?/, "_$1_")`, "__")
+ test(`
+ "b".replace(/(a)?(b)?/, function(a, b, c, d, e, f){
+ return [a, b, c, d, e, f]
+ })
+ `, "b,,b,0,b,")
+
+ test(`
+ var abc = 'She sells seashells by the seashore.';
+ var def = /sh/;
+ [ abc.replace(def, "$'" + 'sch') ];
+ `, "She sells seaells by the seashore.schells by the seashore.")
+ })
+}
+
+func TestString_search(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`"abc".search(/abc/)`, 0)
+ test(`"abc".search(/def/)`, -1)
+ test(`"abc".search(/c$/)`, 2)
+ test(`"abc".search(/$/)`, 3)
+ })
+}
+
+func TestString_split(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`"abc".split("", 1)`, "a")
+ test(`"abc".split("", 2)`, "a,b")
+ test(`"abc".split("", 3)`, "a,b,c")
+ test(`"abc".split("", 4)`, "a,b,c")
+ test(`"abc".split("", 11)`, "a,b,c")
+ test(`"abc".split("", 0)`, "")
+ test(`"abc".split("")`, "a,b,c")
+
+ test(`"abc".split(undefined)`, "abc")
+
+ test(`"__1__3_1__2__".split("_")`, ",,1,,3,1,,2,,")
+
+ test(`"__1__3_1__2__".split(/_/)`, ",,1,,3,1,,2,,")
+
+ test(`"ab".split(/a*/)`, ",b")
+
+ test(`_ = "A<B>bold</B>and<CODE>coded</CODE>".split(/<(\/)?([^<>]+)>/)`, "A,,B,bold,/,B,and,,CODE,coded,/,CODE,")
+ test(`_.length`, 13)
+ test(`_[1] === undefined`, true)
+ test(`_[12] === ""`, true)
+
+ test(`
+ var abc = new String("one-1 two-2 three-3");
+ var def = abc.split(new RegExp);
+
+ [ def.constructor === Array, abc.length, def.length, def.join('') ];
+ `, "true,19,19,one-1 two-2 three-3")
+ })
+}
+
+func TestString_slice(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`"abc".slice()`, "abc")
+ test(`"abc".slice(0)`, "abc")
+ test(`"abc".slice(0,11)`, "abc")
+ test(`"abc".slice(0,-1)`, "ab")
+ test(`"abc".slice(-1,11)`, "c")
+ test(`abc = "abc"; abc.slice(abc.length+1, 0)`, "")
+ })
+}
+
+func TestString_substring(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`"abc".substring()`, "abc")
+ test(`"abc".substring(0)`, "abc")
+ test(`"abc".substring(0,11)`, "abc")
+ test(`"abc".substring(11,0)`, "abc")
+ test(`"abc".substring(0,-1)`, "")
+ test(`"abc".substring(-1,11)`, "abc")
+ test(`"abc".substring(11,1)`, "bc")
+ test(`"abc".substring(1)`, "bc")
+ test(`"abc".substring(Infinity, Infinity)`, "")
+ })
+}
+
+func TestString_toCase(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`"abc".toLowerCase()`, "abc")
+ test(`"ABC".toLowerCase()`, "abc")
+ test(`"abc".toLocaleLowerCase()`, "abc")
+ test(`"ABC".toLocaleLowerCase()`, "abc")
+ test(`"abc".toUpperCase()`, "ABC")
+ test(`"ABC".toUpperCase()`, "ABC")
+ test(`"abc".toLocaleUpperCase()`, "ABC")
+ test(`"ABC".toLocaleUpperCase()`, "ABC")
+ })
+}
+
+func Test_floatToString(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`String(-1234567890)`, "-1234567890")
+ test(`-+String(-(-1234567890))`, -1234567890)
+ test(`String(-1e128)`, "-1e+128")
+ test(`String(0.12345)`, "0.12345")
+ test(`String(-0.00000012345)`, "-1.2345e-7")
+ test(`String(0.0000012345)`, "0.0000012345")
+ test(`String(1000000000000000000000)`, "1e+21")
+ test(`String(1e21)`, "1e+21")
+ test(`String(1E21)`, "1e+21")
+ test(`String(-1000000000000000000000)`, "-1e+21")
+ test(`String(-1e21)`, "-1e+21")
+ test(`String(-1E21)`, "-1e+21")
+ test(`String(0.0000001)`, "1e-7")
+ test(`String(1e-7)`, "1e-7")
+ test(`String(1E-7)`, "1e-7")
+ test(`String(-0.0000001)`, "-1e-7")
+ test(`String(-1e-7)`, "-1e-7")
+ test(`String(-1E-7)`, "-1e-7")
+ })
+}
+
+func TestString_indexing(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ // Actually a test of stringToArrayIndex, under the hood.
+ test(`
+ abc = new String("abc");
+ index = Math.pow(2, 32);
+ [ abc.length, abc[index], abc[index+1], abc[index+2], abc[index+3] ];
+ `, "3,,,,")
+ })
+}
+
+func TestString_trim(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`' \n abc \t \n'.trim();`, "abc")
+ test(`" abc\u000B".trim()`, "abc")
+ test(`"abc ".trim()`, "abc")
+ test(`
+ var a = "\u180Eabc \u000B "
+ var b = a.trim()
+ a.length + b.length
+ `, 10)
+ })
+}
+
+func TestString_trimLeft(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`" abc\u000B".trimLeft()`, "abc\u000B")
+ test(`"abc ".trimLeft()`, "abc ")
+ test(`
+ var a = "\u180Eabc \u000B "
+ var b = a.trimLeft()
+ a.length + b.length
+ `, 13)
+ })
+}
+
+func TestString_trimRight(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`" abc\u000B".trimRight()`, " abc")
+ test(`" abc ".trimRight()`, " abc")
+ test(`
+ var a = "\u180Eabc \u000B "
+ var b = a.trimRight()
+ a.length + b.length
+ `, 11)
+ })
+}
+
+func TestString_localeCompare(t *testing.T) {
+ tt(t, func() {
+ test, _ := test()
+
+ test(`'a'.localeCompare('c');`, -1)
+ test(`'c'.localeCompare('a');`, 1)
+ test(`'a'.localeCompare('a');`, 0)
+ })
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/terst/terst.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/terst/terst.go
new file mode 100644
index 000000000..a25ca8b9c
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/terst/terst.go
@@ -0,0 +1,669 @@
+// This file was AUTOMATICALLY GENERATED by terst-import (smuggol) from github.com/robertkrimen/terst
+
+/*
+Package terst is a terse (terst = test + terse), easy-to-use testing library for Go.
+
+terst is compatible with (and works via) the standard testing package: http://golang.org/pkg/testing
+
+ var is = terst.Is
+
+ func Test(t *testing.T) {
+ terst.Terst(t, func() {
+ is("abc", "abc")
+
+ is(1, ">", 0)
+
+ var abc []int
+ is(abc, nil)
+ }
+ }
+
+Do not import terst directly, instead use `terst-import` to copy it into your testing environment:
+
+https://github.com/robertkrimen/terst/tree/master/terst-import
+
+ $ go get github.com/robertkrimen/terst/terst-import
+
+ $ terst-import
+
+*/
+package terst
+
+import (
+ "bytes"
+ "errors"
+ "fmt"
+ "math/big"
+ "reflect"
+ "regexp"
+ "runtime"
+ "strings"
+ "sync"
+ "testing"
+ "time"
+)
+
+// Is compares two values (got & expect) and returns true if the comparison is true,
+// false otherwise. In addition, if the comparison is false, Is will report the error
+// in a manner similar to testing.T.Error(...). Is also takes an optional argument,
+// a comparator, that changes how the comparison is made. The following
+// comparators are available:
+//
+// == # got == expect (default)
+// != # got != expect
+//
+// > # got > expect (float32, uint, uint16, int, int64, ...)
+// >= # got >= expect
+// < # got < expect
+// <= # got <= expect
+//
+// =~ # regexp.MustCompile(expect).Match{String}(got)
+// !~ # !regexp.MustCompile(expect).Match{String}(got)
+//
+// Basic usage with the default comparator (==):
+//
+// Is(<got>, <expect>)
+//
+// Specifying a different comparator:
+//
+// Is(<got>, <comparator>, <expect>)
+//
+// A simple comparison:
+//
+// Is(2 + 2, 4)
+//
+// A bit trickier:
+//
+// Is(1, ">", 0)
+// Is(2 + 2, "!=", 5)
+// Is("Nothing happens.", "=~", `ing(\s+)happens\.$`)
+//
+// Is should only be called under a Terst(t, ...) call. For a standalone version,
+// use IsErr. If no scope is found and the comparison is false, then Is will panic the error.
+//
+func Is(arguments ...interface{}) bool {
+ err := IsErr(arguments...)
+ if err != nil {
+ call := Caller()
+ if call == nil {
+ panic(err)
+ }
+ call.Error(err)
+ return false
+ }
+ return true
+}
+
+type (
+ // ErrFail indicates a comparison failure (e.g. 0 > 1).
+ ErrFail error
+
+ // ErrInvalid indicates an invalid comparison (e.g. bool == string).
+ ErrInvalid error
+)
+
+var errInvalid = errors.New("invalid")
+
+var registry = struct {
+ table map[uintptr]*_scope
+ lock sync.RWMutex
+}{
+ table: map[uintptr]*_scope{},
+}
+
+func registerScope(pc uintptr, scope *_scope) {
+ registry.lock.Lock()
+ defer registry.lock.Unlock()
+ registry.table[pc] = scope
+}
+
+func scope() *_scope {
+ scope, _ := findScope()
+ return scope
+}
+
+func floatCompare(a float64, b float64) int {
+ if a > b {
+ return 1
+ } else if a < b {
+ return -1
+ }
+ // NaN == NaN
+ return 0
+}
+
+func bigIntCompare(a *big.Int, b *big.Int) int {
+ return a.Cmp(b)
+}
+
+func bigInt(value int64) *big.Int {
+ return big.NewInt(value)
+}
+
+func bigUint(value uint64) *big.Int {
+ return big.NewInt(0).SetUint64(value)
+}
+
+type _toString interface {
+ String() string
+}
+
+func toString(value interface{}) (string, error) {
+ switch value := value.(type) {
+ case string:
+ return value, nil
+ case _toString:
+ return value.String(), nil
+ case error:
+ return value.Error(), nil
+ }
+ return "", errInvalid
+}
+
+func matchString(got string, expect *regexp.Regexp) (int, error) {
+ if expect.MatchString(got) {
+ return 0, nil
+ }
+ return -1, nil
+}
+
+func match(got []byte, expect *regexp.Regexp) (int, error) {
+ if expect.Match(got) {
+ return 0, nil
+ }
+ return -1, nil
+}
+
+func compareMatch(got, expect interface{}) (int, error) {
+ switch got := got.(type) {
+ case []byte:
+ switch expect := expect.(type) {
+ case string:
+ matcher, err := regexp.Compile(expect)
+ if err != nil {
+ return 0, err
+ }
+ return match(got, matcher)
+ case *regexp.Regexp:
+ return match(got, expect)
+ }
+ default:
+ if got, err := toString(got); err == nil {
+ switch expect := expect.(type) {
+ case string:
+ matcher, err := regexp.Compile(expect)
+ if err != nil {
+ return 0, err
+ }
+ return matchString(got, matcher)
+ case *regexp.Regexp:
+ return matchString(got, expect)
+ }
+ } else {
+ return 0, err
+ }
+ }
+ return 0, errInvalid
+}
+
+func floatPromote(value reflect.Value) (float64, error) {
+ kind := value.Kind()
+ if reflect.Int <= kind && kind <= reflect.Int64 {
+ return float64(value.Int()), nil
+ }
+ if reflect.Uint <= kind && kind <= reflect.Uint64 {
+ return float64(value.Uint()), nil
+ }
+ if reflect.Float32 <= kind && kind <= reflect.Float64 {
+ return value.Float(), nil
+ }
+ return 0, errInvalid
+}
+
+func bigIntPromote(value reflect.Value) (*big.Int, error) {
+ kind := value.Kind()
+ if reflect.Int <= kind && kind <= reflect.Int64 {
+ return bigInt(value.Int()), nil
+ }
+ if reflect.Uint <= kind && kind <= reflect.Uint64 {
+ return bigUint(value.Uint()), nil
+ }
+ return nil, errInvalid
+}
+
+func compareOther(got, expect interface{}) (int, error) {
+ {
+ switch expect.(type) {
+ case float32, float64:
+ return compareNumber(got, expect)
+ case uint, uint8, uint16, uint32, uint64:
+ return compareNumber(got, expect)
+ case int, int8, int16, int32, int64:
+ return compareNumber(got, expect)
+ case string:
+ var err error
+ got, err = toString(got)
+ if err != nil {
+ return 0, err
+ }
+ case nil:
+ got := reflect.ValueOf(got)
+ switch got.Kind() {
+ case reflect.Chan, reflect.Func, reflect.Map, reflect.Ptr, reflect.Slice, reflect.Interface:
+ if got.IsNil() {
+ return 0, nil
+ }
+ return -1, nil
+ case reflect.Invalid: // reflect.Invalid: var abc interface{} = nil
+ return 0, nil
+ }
+ return 0, errInvalid
+ }
+ }
+
+ if reflect.ValueOf(got).Type() != reflect.ValueOf(expect).Type() {
+ return 0, errInvalid
+ }
+
+ if reflect.DeepEqual(got, expect) {
+ return 0, nil
+ }
+ return -1, nil
+}
+
+func compareNumber(got, expect interface{}) (int, error) {
+ {
+ got := reflect.ValueOf(got)
+ k0 := got.Kind()
+ expect := reflect.ValueOf(expect)
+ k1 := expect.Kind()
+ if reflect.Float32 <= k0 && k0 <= reflect.Float64 ||
+ reflect.Float32 <= k1 && k1 <= reflect.Float64 {
+ got, err := floatPromote(got)
+ if err != nil {
+ return 0, err
+ }
+ expect, err := floatPromote(expect)
+ if err != nil {
+ return 0, err
+ }
+ return floatCompare(got, expect), nil
+ } else {
+ got, err := bigIntPromote(got)
+ if err != nil {
+ return 0, err
+ }
+ expect, err := bigIntPromote(expect)
+ if err != nil {
+ return 0, err
+ }
+ return got.Cmp(expect), nil
+ }
+ }
+
+ return 0, errInvalid
+}
+
+// IsErr compares two values (got & expect) and returns nil if the comparison is true, an ErrFail if
+// the comparison is false, or an ErrInvalid if the comparison is invalid. IsErr also
+// takes an optional argument, a comparator, that changes how the comparison is made.
+//
+// Is & IsErr are similar but different:
+//
+// Is(...) // Should only be called within a Terst(...) call
+// IsErr(...) // A standalone comparator, the same as Is, just without the automatic reporting
+//
+func IsErr(arguments ...interface{}) error {
+ var got, expect interface{}
+ comparator := "=="
+ switch len(arguments) {
+ case 0, 1:
+ return fmt.Errorf("invalid number of arguments to IsErr: %d", len(arguments))
+ case 2:
+ got, expect = arguments[0], arguments[1]
+ default:
+ if value, ok := arguments[1].(string); ok {
+ comparator = value
+ } else {
+ return fmt.Errorf("invalid comparator: %v", arguments[1])
+ }
+ got, expect = arguments[0], arguments[2]
+ }
+
+ var result int
+ var err error
+
+ switch comparator {
+ case "<", "<=", ">", ">=":
+ result, err = compareNumber(got, expect)
+ case "=~", "!~":
+ result, err = compareMatch(got, expect)
+ case "==", "!=":
+ result, err = compareOther(got, expect)
+ default:
+ return fmt.Errorf("invalid comparator: %s", comparator)
+ }
+
+ if err == errInvalid {
+ return ErrInvalid(fmt.Errorf(
+ "\nINVALID (%s):\n got: %v (%T)\n expected: %v (%T)",
+ comparator,
+ got, got,
+ expect, expect,
+ ))
+ } else if err != nil {
+ return err
+ }
+
+ equality, pass := false, false
+
+ switch comparator {
+ case "==", "=~":
+ equality = true
+ pass = result == 0
+ case "!=", "!~":
+ equality = true
+ pass = result != 0
+ case "<":
+ pass = result < 0
+ case "<=":
+ pass = result <= 0
+ case ">":
+ pass = result > 0
+ case ">=":
+ pass = result >= 0
+ }
+
+ if !pass {
+ if equality {
+ if comparator[1] == '~' {
+ if value, ok := got.([]byte); ok {
+ return ErrFail(fmt.Errorf(
+ "\nFAIL (%s)\n got: %s %v%s\nexpected: %v%s",
+ comparator,
+ value, got, typeKindString(got),
+ expect, typeKindString(expect),
+ ))
+ }
+ }
+ return ErrFail(fmt.Errorf(
+ "\nFAIL (%s)\n got: %v%s\nexpected: %v%s",
+ comparator,
+ got, typeKindString(got),
+ expect, typeKindString(expect),
+ ))
+ }
+ return ErrFail(fmt.Errorf(
+ "\nFAIL (%s)\n got: %v%s\nexpected: %s %v%s",
+ comparator,
+ got, typeKindString(got),
+ comparator, expect, typeKindString(expect),
+ ))
+ }
+
+ return nil
+}
+
+func typeKindString(value interface{}) string {
+ reflectValue := reflect.ValueOf(value)
+ kind := reflectValue.Kind().String()
+ result := fmt.Sprintf("%T", value)
+ if kind == result {
+ if kind == "string" {
+ return ""
+ }
+ return fmt.Sprintf(" (%T)", value)
+ }
+ return fmt.Sprintf(" (%T=%s)", value, kind)
+}
+
+func (scope *_scope) reset() {
+ scope.name = ""
+ scope.output = scope.output[:]
+ scope.start = time.Time{}
+ scope.duration = 0
+}
+
+// Terst creates a testing scope, where Is can be called and errors will be reported
+// according to the top-level location of the comparison, and not where the Is call
+// actually takes place. For example:
+//
+// func test(value int) {
+// Is(value, 5) // <--- This failure is reported below.
+// }
+//
+// Terst(t, func(){
+//
+// Is(2, ">", 3) // <--- An error is reported here.
+//
+// test(5) // <--- An error is reported here.
+//
+// })
+//
+func Terst(t *testing.T, arguments ...func()) {
+ scope := &_scope{
+ t: t,
+ }
+
+ pc, _, _, ok := runtime.Caller(1) // TODO Associate with the Test... func
+ if !ok {
+ panic("Here be dragons.")
+ }
+
+ _, scope.testFunc = findTestFunc()
+
+ registerScope(pc, scope)
+
+ for _, fn := range arguments {
+ func() {
+ scope.reset()
+ name := scope.testFunc.Name()
+ index := strings.LastIndex(scope.testFunc.Name(), ".")
+ if index >= 0 {
+ name = name[index+1:] + "(Terst)"
+ } else {
+ name = "(Terst)"
+ }
+ name = "(Terst)"
+ scope.name = name
+ scope.start = time.Now()
+ defer func() {
+ scope.duration = time.Now().Sub(scope.start)
+ if err := recover(); err != nil {
+ scope.t.Fail()
+ scope.report()
+ panic(err)
+ }
+ scope.report()
+ }()
+ fn()
+ }()
+ }
+}
+
+// From "testing"
+func (scope *_scope) report() {
+ format := "~~~ %s: (Terst)\n%s"
+ if scope.t.Failed() {
+ fmt.Printf(format, "FAIL", scope.output)
+ } else if testing.Verbose() && len(scope.output) > 0 {
+ fmt.Printf(format, "PASS", scope.output)
+ }
+}
+
+func (scope *_scope) log(call _entry, str string) {
+ scope.mu.Lock()
+ defer scope.mu.Unlock()
+ scope.output = append(scope.output, decorate(call, str)...)
+}
+
+// decorate prefixes the string with the file and line of the call site
+// and inserts the final newline if needed and indentation tabs for formascing.
+func decorate(call _entry, s string) string {
+
+ file, line := call.File, call.Line
+ if call.PC > 0 {
+ // Truncate file name at last file name separator.
+ if index := strings.LastIndex(file, "/"); index >= 0 {
+ file = file[index+1:]
+ } else if index = strings.LastIndex(file, "\\"); index >= 0 {
+ file = file[index+1:]
+ }
+ } else {
+ file = "???"
+ line = 1
+ }
+ buf := new(bytes.Buffer)
+ // Every line is indented at least one tab.
+ buf.WriteByte('\t')
+ fmt.Fprintf(buf, "%s:%d: ", file, line)
+ lines := strings.Split(s, "\n")
+ if l := len(lines); l > 1 && lines[l-1] == "" {
+ lines = lines[:l-1]
+ }
+ for i, line := range lines {
+ if i > 0 {
+ // Second and subsequent lines are indented an extra tab.
+ buf.WriteString("\n\t\t")
+ }
+ buf.WriteString(line)
+ }
+ buf.WriteByte('\n')
+ return buf.String()
+}
+
+func findScope() (*_scope, _entry) {
+ registry.lock.RLock()
+ defer registry.lock.RUnlock()
+ table := registry.table
+ depth := 2 // Starting depth
+ call := _entry{}
+ for {
+ pc, _, _, ok := runtime.Caller(depth)
+ if !ok {
+ break
+ }
+ if scope, exists := table[pc]; exists {
+ pc, file, line, _ := runtime.Caller(depth - 3) // Terst(...) + func(){}() + fn() => ???()
+ call.PC = pc
+ call.File = file
+ call.Line = line
+ return scope, call
+ }
+ depth++
+ }
+ return nil, _entry{}
+}
+
+// Call is a reference to a line immediately under a Terst testing scope.
+type Call struct {
+ scope *_scope
+ entry _entry
+}
+
+// Caller will search the stack, looking for a Terst testing scope. If a scope
+// is found, then Caller returns a Call for logging errors, accessing testing.T, etc.
+// If no scope is found, Caller returns nil.
+func Caller() *Call {
+ scope, entry := findScope()
+ if scope == nil {
+ return nil
+ }
+ return &Call{
+ scope: scope,
+ entry: entry,
+ }
+}
+
+// TestFunc returns the *runtime.Func entry for the top-level Test...(t testing.T)
+// function.
+func (cl *Call) TestFunc() *runtime.Func {
+ return cl.scope.testFunc
+}
+
+// T returns the original testing.T passed to Terst(...)
+func (cl *Call) T() *testing.T {
+ return cl.scope.t
+}
+
+// Log is the terst version of `testing.T.Log`
+func (cl *Call) Log(arguments ...interface{}) {
+ cl.scope.log(cl.entry, fmt.Sprintln(arguments...))
+}
+
+// Logf is the terst version of `testing.T.Logf`
+func (cl *Call) Logf(format string, arguments ...interface{}) {
+ cl.scope.log(cl.entry, fmt.Sprintf(format, arguments...))
+}
+
+// Error is the terst version of `testing.T.Error`
+func (cl *Call) Error(arguments ...interface{}) {
+ cl.scope.log(cl.entry, fmt.Sprintln(arguments...))
+ cl.scope.t.Fail()
+}
+
+// Errorf is the terst version of `testing.T.Errorf`
+func (cl *Call) Errorf(format string, arguments ...interface{}) {
+ cl.scope.log(cl.entry, fmt.Sprintf(format, arguments...))
+ cl.scope.t.Fail()
+}
+
+// Skip is the terst version of `testing.T.Skip`
+func (cl *Call) Skip(arguments ...interface{}) {
+ cl.scope.log(cl.entry, fmt.Sprintln(arguments...))
+ cl.scope.t.SkipNow()
+}
+
+// Skipf is the terst version of `testing.T.Skipf`
+func (cl *Call) Skipf(format string, arguments ...interface{}) {
+ cl.scope.log(cl.entry, fmt.Sprintf(format, arguments...))
+ cl.scope.t.SkipNow()
+}
+
+type _scope struct {
+ t *testing.T
+ testFunc *runtime.Func
+ name string
+ mu sync.RWMutex
+ output []byte
+ start time.Time
+ duration time.Duration
+}
+
+type _entry struct {
+ PC uintptr
+ File string
+ Line int
+ Func *runtime.Func
+}
+
+func _findFunc(match string) (_entry, *runtime.Func) {
+ depth := 2 // Starting depth
+ for {
+ pc, file, line, ok := runtime.Caller(depth)
+ if !ok {
+ break
+ }
+ fn := runtime.FuncForPC(pc)
+ name := fn.Name()
+ if index := strings.LastIndex(name, match); index >= 0 {
+ // Assume we have an instance of TestXyzzy in a _test file
+ return _entry{
+ PC: pc,
+ File: file,
+ Line: line,
+ Func: fn,
+ }, fn
+ }
+ depth++
+ }
+ return _entry{}, nil
+}
+
+func findTestFunc() (_entry, *runtime.Func) {
+ return _findFunc(".Test")
+}
+
+func findTerstFunc() (_entry, *runtime.Func) {
+ return _findFunc(".Terst")
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/test/Makefile b/Godeps/_workspace/src/github.com/robertkrimen/otto/test/Makefile
new file mode 100644
index 000000000..ac76fdeac
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/test/Makefile
@@ -0,0 +1,26 @@
+.PHONY: test fetch clean build err report
+
+TESTER := tester
+
+test: $(TESTER)
+ for test in test-*.js; do ./$^ -test=true $$test 1>/dev/null || exit 1; done
+ @echo PASS
+
+report: $(TESTER)
+ ./$^ -report | grep -v "MT READY"
+
+fetch: $(TESTER)
+ ./$^ fetch
+
+build:
+ go build -a -o $(TESTER)
+
+$(TESTER): tester.go
+ $(MAKE) build
+
+clean:
+ rm -f test-*.js
+ rm -f $(TESTER)
+
+err: $(TESTER)
+ for test in test-*.js; do ./$^ $$test; done 2>$@
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/test/tester.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/test/tester.go
new file mode 100644
index 000000000..ea694fd8d
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/test/tester.go
@@ -0,0 +1,196 @@
+package main
+
+import (
+ "encoding/json"
+ "flag"
+ "fmt"
+ "io/ioutil"
+ "net/http"
+ "os"
+ "regexp"
+ "strings"
+ "sync"
+ "text/tabwriter"
+
+ "github.com/robertkrimen/otto"
+ "github.com/robertkrimen/otto/parser"
+)
+
+var flag_test *bool = flag.Bool("test", false, "")
+var flag_report *bool = flag.Bool("report", false, "")
+
+var match_ReferenceError_not_defined = regexp.MustCompile(`^ReferenceError: \S+ is not defined$`)
+var match_lookahead = regexp.MustCompile(`Invalid regular expression: re2: Invalid \(\?[=!]\) <lookahead>`)
+var match_backreference = regexp.MustCompile(`Invalid regular expression: re2: Invalid \\\d <backreference>`)
+var match_TypeError_undefined = regexp.MustCompile(`^TypeError: Cannot access member '[^']+' of undefined$`)
+
+var target = map[string]string{
+ "test-angular-bindonce.js": "fail", // (anonymous): Line 1:944 Unexpected token ( (and 40 more errors)
+ "test-jsforce.js": "fail", // (anonymous): Line 9:28329 RuneError (and 5 more errors)
+ "test-chaplin.js": "parse", // Error: Chaplin requires Common.js or AMD modules
+ "test-dropbox.js.js": "parse", // Error: dropbox.js loaded in an unsupported JavaScript environment.
+ "test-epitome.js": "parse", // TypeError: undefined is not a function
+ "test-portal.js": "parse", // TypeError
+ "test-reactive-coffee.js": "parse", // Dependencies are not met for reactive: _ and $ not found
+ "test-scriptaculous.js": "parse", // script.aculo.us requires the Prototype JavaScript framework >= 1.6.0.3
+ "test-waypoints.js": "parse", // TypeError: undefined is not a function
+ "test-webuploader.js": "parse", // Error: `jQuery` is undefined
+ "test-xuijs.js": "parse", // TypeError: undefined is not a function
+}
+
+// http://cdnjs.com/
+// http://api.cdnjs.com/libraries
+
+func fetch(name, location string) error {
+ response, err := http.Get(location)
+ if err != nil {
+ return err
+ }
+ defer response.Body.Close()
+ body, err := ioutil.ReadAll(response.Body)
+ if err != nil {
+ return err
+ }
+
+ if !strings.HasSuffix(location, ".js") {
+ return nil
+ }
+
+ filename := "test-" + name + ".js"
+ fmt.Println(filename, len(body))
+ return ioutil.WriteFile(filename, body, 0644)
+}
+
+func test(filename string) error {
+ script, err := ioutil.ReadFile(filename)
+ if err != nil {
+ return err
+ }
+
+ if !*flag_report {
+ fmt.Fprintln(os.Stdout, filename, len(script))
+ }
+
+ parse := false
+ option := target[filename]
+
+ if option != "parse" {
+ vm := otto.New()
+ _, err = vm.Run(string(script))
+ if err != nil {
+ value := err.Error()
+ switch {
+ case match_ReferenceError_not_defined.MatchString(value):
+ case match_TypeError_undefined.MatchString(value):
+ case match_lookahead.MatchString(value):
+ case match_backreference.MatchString(value):
+ default:
+ return err
+ }
+ parse = true
+ }
+ }
+
+ if parse {
+ _, err = parser.ParseFile(nil, filename, string(script), parser.IgnoreRegExpErrors)
+ if err != nil {
+ return err
+ }
+ target[filename] = "parse"
+ }
+
+ return nil
+}
+
+func main() {
+ flag.Parse()
+
+ filename := ""
+
+ err := func() error {
+
+ if flag.Arg(0) == "fetch" {
+ response, err := http.Get("http://api.cdnjs.com/libraries")
+ if err != nil {
+ return err
+ }
+ defer response.Body.Close()
+ body, err := ioutil.ReadAll(response.Body)
+ if err != nil {
+ return err
+ }
+
+ var tmp map[string]interface{}
+
+ err = json.Unmarshal(body, &tmp)
+ if err != nil {
+ return err
+ }
+
+ var wg sync.WaitGroup
+
+ for _, value := range tmp["results"].([]interface{}) {
+ wg.Add(1)
+ library := value.(map[string]interface{})
+ go func() {
+ defer wg.Done()
+ fetch(library["name"].(string), library["latest"].(string))
+ }()
+ }
+
+ wg.Wait()
+
+ return nil
+ }
+
+ if *flag_report {
+ files, err := ioutil.ReadDir(".")
+ if err != nil {
+ return err
+ }
+ writer := tabwriter.NewWriter(os.Stdout, 0, 8, 0, '\t', 0)
+ fmt.Fprintln(writer, "", "\t| Status")
+ fmt.Fprintln(writer, "---", "\t| ---")
+ for _, file := range files {
+ filename := file.Name()
+ if !strings.HasPrefix(filename, "test-") {
+ continue
+ }
+ err := test(filename)
+ option := target[filename]
+ name := strings.TrimPrefix(strings.TrimSuffix(filename, ".js"), "test-")
+ if err == nil {
+ switch option {
+ case "":
+ fmt.Fprintln(writer, name, "\t| pass")
+ case "parse":
+ fmt.Fprintln(writer, name, "\t| pass (parse)")
+ case "re2":
+ continue
+ fmt.Fprintln(writer, name, "\t| unknown (re2)")
+ }
+ } else {
+ fmt.Fprintln(writer, name, "\t| fail")
+ }
+ }
+ writer.Flush()
+ return nil
+ }
+
+ filename = flag.Arg(0)
+ return test(filename)
+
+ }()
+ if err != nil {
+ if filename != "" {
+ if *flag_test && target[filename] == "fail" {
+ goto exit
+ }
+ fmt.Fprintf(os.Stderr, "%s: %s\n", filename, err.Error())
+ } else {
+ fmt.Fprintln(os.Stderr, err)
+ }
+ os.Exit(64)
+ }
+exit:
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/testing_test.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/testing_test.go
new file mode 100644
index 000000000..bf820bc0c
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/testing_test.go
@@ -0,0 +1,135 @@
+package otto
+
+import (
+ "./terst"
+ "errors"
+ "strings"
+ "testing"
+ "time"
+)
+
+func tt(t *testing.T, arguments ...func()) {
+ halt := errors.New("A test was taking too long")
+ timer := time.AfterFunc(2*time.Second, func() {
+ panic(halt)
+ })
+ defer func() {
+ timer.Stop()
+ }()
+ terst.Terst(t, arguments...)
+}
+
+func is(arguments ...interface{}) bool {
+ var got, expect interface{}
+
+ switch len(arguments) {
+ case 0, 1:
+ return terst.Is(arguments...)
+ case 2:
+ got, expect = arguments[0], arguments[1]
+ default:
+ got, expect = arguments[0], arguments[2]
+ }
+
+ switch value := got.(type) {
+ case Value:
+ if value.value != nil {
+ got = value.value
+ }
+ case *Error:
+ if value != nil {
+ got = value.Error()
+ }
+ if expect == nil {
+ // FIXME This is weird
+ expect = ""
+ }
+ }
+
+ if len(arguments) == 2 {
+ arguments[0] = got
+ arguments[1] = expect
+ } else {
+ arguments[0] = got
+ arguments[2] = expect
+ }
+
+ return terst.Is(arguments...)
+}
+
+func test(arguments ...interface{}) (func(string, ...interface{}) Value, *_tester) {
+ tester := newTester()
+ if len(arguments) > 0 {
+ tester.test(arguments[0].(string))
+ }
+ return tester.test, tester
+}
+
+type _tester struct {
+ vm *Otto
+}
+
+func newTester() *_tester {
+ return &_tester{
+ vm: New(),
+ }
+}
+
+func (self *_tester) Get(name string) (Value, error) {
+ return self.vm.Get(name)
+}
+
+func (self *_tester) Set(name string, value interface{}) Value {
+ err := self.vm.Set(name, value)
+ is(err, nil)
+ if err != nil {
+ terst.Caller().T().FailNow()
+ }
+ return self.vm.getValue(name)
+}
+
+func (self *_tester) Run(src interface{}) (Value, error) {
+ return self.vm.Run(src)
+}
+
+func (self *_tester) test(name string, expect ...interface{}) Value {
+ vm := self.vm
+ raise := false
+ defer func() {
+ if caught := recover(); caught != nil {
+ if exception, ok := caught.(*_exception); ok {
+ caught = exception.eject()
+ }
+ if raise {
+ if len(expect) > 0 {
+ is(caught, expect[0])
+ }
+ } else {
+ dbg("Panic, caught:", caught)
+ panic(caught)
+ }
+ }
+ }()
+ var value Value
+ var err error
+ if isIdentifier(name) {
+ value = vm.getValue(name)
+ } else {
+ source := name
+ index := strings.Index(source, "raise:")
+ if index == 0 {
+ raise = true
+ source = source[6:]
+ source = strings.TrimLeft(source, " ")
+ }
+ value, err = vm.runtime.cmpl_run(source)
+ if err != nil {
+ panic(err)
+ }
+ }
+ value = value.resolve()
+ if len(expect) > 0 {
+ is(value, expect[0])
+ }
+ return value
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/token/Makefile b/Godeps/_workspace/src/github.com/robertkrimen/otto/token/Makefile
new file mode 100644
index 000000000..1e85c7348
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/token/Makefile
@@ -0,0 +1,2 @@
+token_const.go: tokenfmt
+ ./$^ | gofmt > $@
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/token/README.markdown b/Godeps/_workspace/src/github.com/robertkrimen/otto/token/README.markdown
new file mode 100644
index 000000000..ff3b16104
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/token/README.markdown
@@ -0,0 +1,171 @@
+# token
+--
+ import "github.com/robertkrimen/otto/token"
+
+Package token defines constants representing the lexical tokens of JavaScript
+(ECMA5).
+
+## Usage
+
+```go
+const (
+ ILLEGAL
+ EOF
+ COMMENT
+ KEYWORD
+
+ STRING
+ BOOLEAN
+ NULL
+ NUMBER
+ IDENTIFIER
+
+ PLUS // +
+ MINUS // -
+ MULTIPLY // *
+ SLASH // /
+ REMAINDER // %
+
+ AND // &
+ OR // |
+ EXCLUSIVE_OR // ^
+ SHIFT_LEFT // <<
+ SHIFT_RIGHT // >>
+ UNSIGNED_SHIFT_RIGHT // >>>
+ AND_NOT // &^
+
+ ADD_ASSIGN // +=
+ SUBTRACT_ASSIGN // -=
+ MULTIPLY_ASSIGN // *=
+ QUOTIENT_ASSIGN // /=
+ REMAINDER_ASSIGN // %=
+
+ AND_ASSIGN // &=
+ OR_ASSIGN // |=
+ EXCLUSIVE_OR_ASSIGN // ^=
+ SHIFT_LEFT_ASSIGN // <<=
+ SHIFT_RIGHT_ASSIGN // >>=
+ UNSIGNED_SHIFT_RIGHT_ASSIGN // >>>=
+ AND_NOT_ASSIGN // &^=
+
+ LOGICAL_AND // &&
+ LOGICAL_OR // ||
+ INCREMENT // ++
+ DECREMENT // --
+
+ EQUAL // ==
+ STRICT_EQUAL // ===
+ LESS // <
+ GREATER // >
+ ASSIGN // =
+ NOT // !
+
+ BITWISE_NOT // ~
+
+ NOT_EQUAL // !=
+ STRICT_NOT_EQUAL // !==
+ LESS_OR_EQUAL // <=
+ GREATER_OR_EQUAL // >=
+
+ LEFT_PARENTHESIS // (
+ LEFT_BRACKET // [
+ LEFT_BRACE // {
+ COMMA // ,
+ PERIOD // .
+
+ RIGHT_PARENTHESIS // )
+ RIGHT_BRACKET // ]
+ RIGHT_BRACE // }
+ SEMICOLON // ;
+ COLON // :
+ QUESTION_MARK // ?
+
+ IF
+ IN
+ DO
+
+ VAR
+ FOR
+ NEW
+ TRY
+
+ THIS
+ ELSE
+ CASE
+ VOID
+ WITH
+
+ WHILE
+ BREAK
+ CATCH
+ THROW
+
+ RETURN
+ TYPEOF
+ DELETE
+ SWITCH
+
+ DEFAULT
+ FINALLY
+
+ FUNCTION
+ CONTINUE
+ DEBUGGER
+
+ INSTANCEOF
+)
+```
+
+#### type Token
+
+```go
+type Token int
+```
+
+Token is the set of lexical tokens in JavaScript (ECMA5).
+
+#### func IsKeyword
+
+```go
+func IsKeyword(literal string) (Token, bool)
+```
+IsKeyword returns the keyword token if literal is a keyword, a KEYWORD token if
+the literal is a future keyword (const, let, class, super, ...), or 0 if the
+literal is not a keyword.
+
+If the literal is a keyword, IsKeyword returns a second value indicating if the
+literal is considered a future keyword in strict-mode only.
+
+7.6.1.2 Future Reserved Words:
+
+ const
+ class
+ enum
+ export
+ extends
+ import
+ super
+
+7.6.1.2 Future Reserved Words (strict):
+
+ implements
+ interface
+ let
+ package
+ private
+ protected
+ public
+ static
+
+#### func (Token) String
+
+```go
+func (tkn Token) String() string
+```
+String returns the string corresponding to the token. For operators, delimiters,
+and keywords the string is the actual token string (e.g., for the token PLUS,
+the String() is "+"). For all other tokens the string corresponds to the token
+name (e.g. for the token IDENTIFIER, the string is "IDENTIFIER").
+
+--
+**godocdown** http://github.com/robertkrimen/godocdown
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/token/token.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/token/token.go
new file mode 100644
index 000000000..0e941ac96
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/token/token.go
@@ -0,0 +1,116 @@
+// Package token defines constants representing the lexical tokens of JavaScript (ECMA5).
+package token
+
+import (
+ "strconv"
+)
+
+// Token is the set of lexical tokens in JavaScript (ECMA5).
+type Token int
+
+// String returns the string corresponding to the token.
+// For operators, delimiters, and keywords the string is the actual
+// token string (e.g., for the token PLUS, the String() is
+// "+"). For all other tokens the string corresponds to the token
+// name (e.g. for the token IDENTIFIER, the string is "IDENTIFIER").
+//
+func (tkn Token) String() string {
+ if 0 == tkn {
+ return "UNKNOWN"
+ }
+ if tkn < Token(len(token2string)) {
+ return token2string[tkn]
+ }
+ return "token(" + strconv.Itoa(int(tkn)) + ")"
+}
+
+// This is not used for anything
+func (tkn Token) precedence(in bool) int {
+
+ switch tkn {
+ case LOGICAL_OR:
+ return 1
+
+ case LOGICAL_AND:
+ return 2
+
+ case OR, OR_ASSIGN:
+ return 3
+
+ case EXCLUSIVE_OR:
+ return 4
+
+ case AND, AND_ASSIGN, AND_NOT, AND_NOT_ASSIGN:
+ return 5
+
+ case EQUAL,
+ NOT_EQUAL,
+ STRICT_EQUAL,
+ STRICT_NOT_EQUAL:
+ return 6
+
+ case LESS, GREATER, LESS_OR_EQUAL, GREATER_OR_EQUAL, INSTANCEOF:
+ return 7
+
+ case IN:
+ if in {
+ return 7
+ }
+ return 0
+
+ case SHIFT_LEFT, SHIFT_RIGHT, UNSIGNED_SHIFT_RIGHT:
+ fallthrough
+ case SHIFT_LEFT_ASSIGN, SHIFT_RIGHT_ASSIGN, UNSIGNED_SHIFT_RIGHT_ASSIGN:
+ return 8
+
+ case PLUS, MINUS, ADD_ASSIGN, SUBTRACT_ASSIGN:
+ return 9
+
+ case MULTIPLY, SLASH, REMAINDER, MULTIPLY_ASSIGN, QUOTIENT_ASSIGN, REMAINDER_ASSIGN:
+ return 11
+ }
+ return 0
+}
+
+type _keyword struct {
+ token Token
+ futureKeyword bool
+ strict bool
+}
+
+// IsKeyword returns the keyword token if literal is a keyword, a KEYWORD token
+// if the literal is a future keyword (const, let, class, super, ...), or 0 if the literal is not a keyword.
+//
+// If the literal is a keyword, IsKeyword returns a second value indicating if the literal
+// is considered a future keyword in strict-mode only.
+//
+// 7.6.1.2 Future Reserved Words:
+//
+// const
+// class
+// enum
+// export
+// extends
+// import
+// super
+//
+// 7.6.1.2 Future Reserved Words (strict):
+//
+// implements
+// interface
+// let
+// package
+// private
+// protected
+// public
+// static
+//
+func IsKeyword(literal string) (Token, bool) {
+ if keyword, exists := keywordTable[literal]; exists {
+ if keyword.futureKeyword {
+ return KEYWORD, keyword.strict
+ }
+ return keyword.token, false
+ }
+ return 0, false
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/token/token_const.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/token/token_const.go
new file mode 100644
index 000000000..b1d83c6de
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/token/token_const.go
@@ -0,0 +1,349 @@
+package token
+
+const (
+ _ Token = iota
+
+ ILLEGAL
+ EOF
+ COMMENT
+ KEYWORD
+
+ STRING
+ BOOLEAN
+ NULL
+ NUMBER
+ IDENTIFIER
+
+ PLUS // +
+ MINUS // -
+ MULTIPLY // *
+ SLASH // /
+ REMAINDER // %
+
+ AND // &
+ OR // |
+ EXCLUSIVE_OR // ^
+ SHIFT_LEFT // <<
+ SHIFT_RIGHT // >>
+ UNSIGNED_SHIFT_RIGHT // >>>
+ AND_NOT // &^
+
+ ADD_ASSIGN // +=
+ SUBTRACT_ASSIGN // -=
+ MULTIPLY_ASSIGN // *=
+ QUOTIENT_ASSIGN // /=
+ REMAINDER_ASSIGN // %=
+
+ AND_ASSIGN // &=
+ OR_ASSIGN // |=
+ EXCLUSIVE_OR_ASSIGN // ^=
+ SHIFT_LEFT_ASSIGN // <<=
+ SHIFT_RIGHT_ASSIGN // >>=
+ UNSIGNED_SHIFT_RIGHT_ASSIGN // >>>=
+ AND_NOT_ASSIGN // &^=
+
+ LOGICAL_AND // &&
+ LOGICAL_OR // ||
+ INCREMENT // ++
+ DECREMENT // --
+
+ EQUAL // ==
+ STRICT_EQUAL // ===
+ LESS // <
+ GREATER // >
+ ASSIGN // =
+ NOT // !
+
+ BITWISE_NOT // ~
+
+ NOT_EQUAL // !=
+ STRICT_NOT_EQUAL // !==
+ LESS_OR_EQUAL // <=
+ GREATER_OR_EQUAL // >=
+
+ LEFT_PARENTHESIS // (
+ LEFT_BRACKET // [
+ LEFT_BRACE // {
+ COMMA // ,
+ PERIOD // .
+
+ RIGHT_PARENTHESIS // )
+ RIGHT_BRACKET // ]
+ RIGHT_BRACE // }
+ SEMICOLON // ;
+ COLON // :
+ QUESTION_MARK // ?
+
+ firstKeyword
+ IF
+ IN
+ DO
+
+ VAR
+ FOR
+ NEW
+ TRY
+
+ THIS
+ ELSE
+ CASE
+ VOID
+ WITH
+
+ WHILE
+ BREAK
+ CATCH
+ THROW
+
+ RETURN
+ TYPEOF
+ DELETE
+ SWITCH
+
+ DEFAULT
+ FINALLY
+
+ FUNCTION
+ CONTINUE
+ DEBUGGER
+
+ INSTANCEOF
+ lastKeyword
+)
+
+var token2string = [...]string{
+ ILLEGAL: "ILLEGAL",
+ EOF: "EOF",
+ COMMENT: "COMMENT",
+ KEYWORD: "KEYWORD",
+ STRING: "STRING",
+ BOOLEAN: "BOOLEAN",
+ NULL: "NULL",
+ NUMBER: "NUMBER",
+ IDENTIFIER: "IDENTIFIER",
+ PLUS: "+",
+ MINUS: "-",
+ MULTIPLY: "*",
+ SLASH: "/",
+ REMAINDER: "%",
+ AND: "&",
+ OR: "|",
+ EXCLUSIVE_OR: "^",
+ SHIFT_LEFT: "<<",
+ SHIFT_RIGHT: ">>",
+ UNSIGNED_SHIFT_RIGHT: ">>>",
+ AND_NOT: "&^",
+ ADD_ASSIGN: "+=",
+ SUBTRACT_ASSIGN: "-=",
+ MULTIPLY_ASSIGN: "*=",
+ QUOTIENT_ASSIGN: "/=",
+ REMAINDER_ASSIGN: "%=",
+ AND_ASSIGN: "&=",
+ OR_ASSIGN: "|=",
+ EXCLUSIVE_OR_ASSIGN: "^=",
+ SHIFT_LEFT_ASSIGN: "<<=",
+ SHIFT_RIGHT_ASSIGN: ">>=",
+ UNSIGNED_SHIFT_RIGHT_ASSIGN: ">>>=",
+ AND_NOT_ASSIGN: "&^=",
+ LOGICAL_AND: "&&",
+ LOGICAL_OR: "||",
+ INCREMENT: "++",
+ DECREMENT: "--",
+ EQUAL: "==",
+ STRICT_EQUAL: "===",
+ LESS: "<",
+ GREATER: ">",
+ ASSIGN: "=",
+ NOT: "!",
+ BITWISE_NOT: "~",
+ NOT_EQUAL: "!=",
+ STRICT_NOT_EQUAL: "!==",
+ LESS_OR_EQUAL: "<=",
+ GREATER_OR_EQUAL: ">=",
+ LEFT_PARENTHESIS: "(",
+ LEFT_BRACKET: "[",
+ LEFT_BRACE: "{",
+ COMMA: ",",
+ PERIOD: ".",
+ RIGHT_PARENTHESIS: ")",
+ RIGHT_BRACKET: "]",
+ RIGHT_BRACE: "}",
+ SEMICOLON: ";",
+ COLON: ":",
+ QUESTION_MARK: "?",
+ IF: "if",
+ IN: "in",
+ DO: "do",
+ VAR: "var",
+ FOR: "for",
+ NEW: "new",
+ TRY: "try",
+ THIS: "this",
+ ELSE: "else",
+ CASE: "case",
+ VOID: "void",
+ WITH: "with",
+ WHILE: "while",
+ BREAK: "break",
+ CATCH: "catch",
+ THROW: "throw",
+ RETURN: "return",
+ TYPEOF: "typeof",
+ DELETE: "delete",
+ SWITCH: "switch",
+ DEFAULT: "default",
+ FINALLY: "finally",
+ FUNCTION: "function",
+ CONTINUE: "continue",
+ DEBUGGER: "debugger",
+ INSTANCEOF: "instanceof",
+}
+
+var keywordTable = map[string]_keyword{
+ "if": _keyword{
+ token: IF,
+ },
+ "in": _keyword{
+ token: IN,
+ },
+ "do": _keyword{
+ token: DO,
+ },
+ "var": _keyword{
+ token: VAR,
+ },
+ "for": _keyword{
+ token: FOR,
+ },
+ "new": _keyword{
+ token: NEW,
+ },
+ "try": _keyword{
+ token: TRY,
+ },
+ "this": _keyword{
+ token: THIS,
+ },
+ "else": _keyword{
+ token: ELSE,
+ },
+ "case": _keyword{
+ token: CASE,
+ },
+ "void": _keyword{
+ token: VOID,
+ },
+ "with": _keyword{
+ token: WITH,
+ },
+ "while": _keyword{
+ token: WHILE,
+ },
+ "break": _keyword{
+ token: BREAK,
+ },
+ "catch": _keyword{
+ token: CATCH,
+ },
+ "throw": _keyword{
+ token: THROW,
+ },
+ "return": _keyword{
+ token: RETURN,
+ },
+ "typeof": _keyword{
+ token: TYPEOF,
+ },
+ "delete": _keyword{
+ token: DELETE,
+ },
+ "switch": _keyword{
+ token: SWITCH,
+ },
+ "default": _keyword{
+ token: DEFAULT,
+ },
+ "finally": _keyword{
+ token: FINALLY,
+ },
+ "function": _keyword{
+ token: FUNCTION,
+ },
+ "continue": _keyword{
+ token: CONTINUE,
+ },
+ "debugger": _keyword{
+ token: DEBUGGER,
+ },
+ "instanceof": _keyword{
+ token: INSTANCEOF,
+ },
+ "const": _keyword{
+ token: KEYWORD,
+ futureKeyword: true,
+ },
+ "class": _keyword{
+ token: KEYWORD,
+ futureKeyword: true,
+ },
+ "enum": _keyword{
+ token: KEYWORD,
+ futureKeyword: true,
+ },
+ "export": _keyword{
+ token: KEYWORD,
+ futureKeyword: true,
+ },
+ "extends": _keyword{
+ token: KEYWORD,
+ futureKeyword: true,
+ },
+ "import": _keyword{
+ token: KEYWORD,
+ futureKeyword: true,
+ },
+ "super": _keyword{
+ token: KEYWORD,
+ futureKeyword: true,
+ },
+ "implements": _keyword{
+ token: KEYWORD,
+ futureKeyword: true,
+ strict: true,
+ },
+ "interface": _keyword{
+ token: KEYWORD,
+ futureKeyword: true,
+ strict: true,
+ },
+ "let": _keyword{
+ token: KEYWORD,
+ futureKeyword: true,
+ strict: true,
+ },
+ "package": _keyword{
+ token: KEYWORD,
+ futureKeyword: true,
+ strict: true,
+ },
+ "private": _keyword{
+ token: KEYWORD,
+ futureKeyword: true,
+ strict: true,
+ },
+ "protected": _keyword{
+ token: KEYWORD,
+ futureKeyword: true,
+ strict: true,
+ },
+ "public": _keyword{
+ token: KEYWORD,
+ futureKeyword: true,
+ strict: true,
+ },
+ "static": _keyword{
+ token: KEYWORD,
+ futureKeyword: true,
+ strict: true,
+ },
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/token/tokenfmt b/Godeps/_workspace/src/github.com/robertkrimen/otto/token/tokenfmt
new file mode 100644
index 000000000..63dd5d9e6
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/token/tokenfmt
@@ -0,0 +1,222 @@
+#!/usr/bin/env perl
+
+use strict;
+use warnings;
+
+my (%token, @order, @keywords);
+
+{
+ my $keywords;
+ my @const;
+ push @const, <<_END_;
+package token
+
+const(
+ _ Token = iota
+_END_
+
+ for (split m/\n/, <<_END_) {
+ILLEGAL
+EOF
+COMMENT
+KEYWORD
+
+STRING
+BOOLEAN
+NULL
+NUMBER
+IDENTIFIER
+
+PLUS +
+MINUS -
+MULTIPLY *
+SLASH /
+REMAINDER %
+
+AND &
+OR |
+EXCLUSIVE_OR ^
+SHIFT_LEFT <<
+SHIFT_RIGHT >>
+UNSIGNED_SHIFT_RIGHT >>>
+AND_NOT &^
+
+ADD_ASSIGN +=
+SUBTRACT_ASSIGN -=
+MULTIPLY_ASSIGN *=
+QUOTIENT_ASSIGN /=
+REMAINDER_ASSIGN %=
+
+AND_ASSIGN &=
+OR_ASSIGN |=
+EXCLUSIVE_OR_ASSIGN ^=
+SHIFT_LEFT_ASSIGN <<=
+SHIFT_RIGHT_ASSIGN >>=
+UNSIGNED_SHIFT_RIGHT_ASSIGN >>>=
+AND_NOT_ASSIGN &^=
+
+LOGICAL_AND &&
+LOGICAL_OR ||
+INCREMENT ++
+DECREMENT --
+
+EQUAL ==
+STRICT_EQUAL ===
+LESS <
+GREATER >
+ASSIGN =
+NOT !
+
+BITWISE_NOT ~
+
+NOT_EQUAL !=
+STRICT_NOT_EQUAL !==
+LESS_OR_EQUAL <=
+GREATER_OR_EQUAL <=
+
+LEFT_PARENTHESIS (
+LEFT_BRACKET [
+LEFT_BRACE {
+COMMA ,
+PERIOD .
+
+RIGHT_PARENTHESIS )
+RIGHT_BRACKET ]
+RIGHT_BRACE }
+SEMICOLON ;
+COLON :
+QUESTION_MARK ?
+
+firstKeyword
+IF
+IN
+DO
+
+VAR
+FOR
+NEW
+TRY
+
+THIS
+ELSE
+CASE
+VOID
+WITH
+
+WHILE
+BREAK
+CATCH
+THROW
+
+RETURN
+TYPEOF
+DELETE
+SWITCH
+
+DEFAULT
+FINALLY
+
+FUNCTION
+CONTINUE
+DEBUGGER
+
+INSTANCEOF
+lastKeyword
+_END_
+ chomp;
+
+ next if m/^\s*#/;
+
+ my ($name, $symbol) = m/(\w+)\s*(\S+)?/;
+
+ if (defined $symbol) {
+ push @order, $name;
+ push @const, "$name // $symbol";
+ $token{$name} = $symbol;
+ } elsif (defined $name) {
+ $keywords ||= $name eq 'firstKeyword';
+
+ push @const, $name;
+ #$const[-1] .= " Token = iota" if 2 == @const;
+ if ($name =~ m/^([A-Z]+)/) {
+ push @keywords, $name if $keywords;
+ push @order, $name;
+ if ($token{SEMICOLON}) {
+ $token{$name} = lc $1;
+ } else {
+ $token{$name} = $name;
+ }
+ }
+ } else {
+ push @const, "";
+ }
+
+ }
+ push @const, ")";
+ print join "\n", @const, "";
+}
+
+{
+ print <<_END_;
+
+var token2string = [...]string{
+_END_
+ for my $name (@order) {
+ print "$name: \"$token{$name}\",\n";
+ }
+ print <<_END_;
+}
+_END_
+
+ print <<_END_;
+
+var keywordTable = map[string]_keyword{
+_END_
+ for my $name (@keywords) {
+ print <<_END_
+ "@{[ lc $name ]}": _keyword{
+ token: $name,
+ },
+_END_
+ }
+
+ for my $name (qw/
+ const
+ class
+ enum
+ export
+ extends
+ import
+ super
+ /) {
+ print <<_END_
+ "$name": _keyword{
+ token: KEYWORD,
+ futureKeyword: true,
+ },
+_END_
+ }
+
+ for my $name (qw/
+ implements
+ interface
+ let
+ package
+ private
+ protected
+ public
+ static
+ /) {
+ print <<_END_
+ "$name": _keyword{
+ token: KEYWORD,
+ futureKeyword: true,
+ strict: true,
+ },
+_END_
+ }
+
+ print <<_END_;
+}
+_END_
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/type_arguments.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/type_arguments.go
new file mode 100644
index 000000000..841d75855
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/type_arguments.go
@@ -0,0 +1,106 @@
+package otto
+
+import (
+ "strconv"
+)
+
+func (runtime *_runtime) newArgumentsObject(indexOfParameterName []string, stash _stash, length int) *_object {
+ self := runtime.newClassObject("Arguments")
+
+ for index, _ := range indexOfParameterName {
+ name := strconv.FormatInt(int64(index), 10)
+ objectDefineOwnProperty(self, name, _property{Value{}, 0111}, false)
+ }
+
+ self.objectClass = _classArguments
+ self.value = _argumentsObject{
+ indexOfParameterName: indexOfParameterName,
+ stash: stash,
+ }
+
+ self.prototype = runtime.global.ObjectPrototype
+
+ self.defineProperty("length", toValue_int(length), 0101, false)
+
+ return self
+}
+
+type _argumentsObject struct {
+ indexOfParameterName []string
+ // function(abc, def, ghi)
+ // indexOfParameterName[0] = "abc"
+ // indexOfParameterName[1] = "def"
+ // indexOfParameterName[2] = "ghi"
+ // ...
+ stash _stash
+}
+
+func (in _argumentsObject) clone(clone *_clone) _argumentsObject {
+ indexOfParameterName := make([]string, len(in.indexOfParameterName))
+ copy(indexOfParameterName, in.indexOfParameterName)
+ return _argumentsObject{
+ indexOfParameterName,
+ clone.stash(in.stash),
+ }
+}
+
+func (self _argumentsObject) get(name string) (Value, bool) {
+ index := stringToArrayIndex(name)
+ if index >= 0 && index < int64(len(self.indexOfParameterName)) {
+ name := self.indexOfParameterName[index]
+ if name == "" {
+ return Value{}, false
+ }
+ return self.stash.getBinding(name, false), true
+ }
+ return Value{}, false
+}
+
+func (self _argumentsObject) put(name string, value Value) {
+ index := stringToArrayIndex(name)
+ name = self.indexOfParameterName[index]
+ self.stash.setBinding(name, value, false)
+}
+
+func (self _argumentsObject) delete(name string) {
+ index := stringToArrayIndex(name)
+ self.indexOfParameterName[index] = ""
+}
+
+func argumentsGet(self *_object, name string) Value {
+ if value, exists := self.value.(_argumentsObject).get(name); exists {
+ return value
+ }
+ return objectGet(self, name)
+}
+
+func argumentsGetOwnProperty(self *_object, name string) *_property {
+ property := objectGetOwnProperty(self, name)
+ if value, exists := self.value.(_argumentsObject).get(name); exists {
+ property.value = value
+ }
+ return property
+}
+
+func argumentsDefineOwnProperty(self *_object, name string, descriptor _property, throw bool) bool {
+ if _, exists := self.value.(_argumentsObject).get(name); exists {
+ if !objectDefineOwnProperty(self, name, descriptor, false) {
+ return self.runtime.typeErrorResult(throw)
+ }
+ if value, valid := descriptor.value.(Value); valid {
+ self.value.(_argumentsObject).put(name, value)
+ }
+ return true
+ }
+ return objectDefineOwnProperty(self, name, descriptor, throw)
+}
+
+func argumentsDelete(self *_object, name string, throw bool) bool {
+ if !objectDelete(self, name, throw) {
+ return false
+ }
+ if _, exists := self.value.(_argumentsObject).get(name); exists {
+ self.value.(_argumentsObject).delete(name)
+ }
+ return true
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/type_array.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/type_array.go
new file mode 100644
index 000000000..236376a8e
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/type_array.go
@@ -0,0 +1,109 @@
+package otto
+
+import (
+ "strconv"
+)
+
+func (runtime *_runtime) newArrayObject(length uint32) *_object {
+ self := runtime.newObject()
+ self.class = "Array"
+ self.defineProperty("length", toValue_uint32(length), 0100, false)
+ self.objectClass = _classArray
+ return self
+}
+
+func isArray(object *_object) bool {
+ return object != nil && (object.class == "Array" || object.class == "GoArray")
+}
+
+func objectLength(object *_object) uint32 {
+ if object == nil {
+ return 0
+ }
+ switch object.class {
+ case "Array":
+ return object.get("length").value.(uint32)
+ case "String":
+ return uint32(object.get("length").value.(int))
+ case "GoArray":
+ return uint32(object.get("length").value.(int))
+ }
+ return 0
+}
+
+func arrayUint32(rt *_runtime, value Value) uint32 {
+ nm := value.number()
+ if nm.kind != numberInteger || !isUint32(nm.int64) {
+ // FIXME
+ panic(rt.panicRangeError())
+ }
+ return uint32(nm.int64)
+}
+
+func arrayDefineOwnProperty(self *_object, name string, descriptor _property, throw bool) bool {
+ lengthProperty := self.getOwnProperty("length")
+ lengthValue, valid := lengthProperty.value.(Value)
+ if !valid {
+ panic("Array.length != Value{}")
+ }
+ length := lengthValue.value.(uint32)
+ if name == "length" {
+ if descriptor.value == nil {
+ return objectDefineOwnProperty(self, name, descriptor, throw)
+ }
+ newLengthValue, isValue := descriptor.value.(Value)
+ if !isValue {
+ panic(self.runtime.panicTypeError())
+ }
+ newLength := arrayUint32(self.runtime, newLengthValue)
+ descriptor.value = toValue_uint32(newLength)
+ if newLength > length {
+ return objectDefineOwnProperty(self, name, descriptor, throw)
+ }
+ if !lengthProperty.writable() {
+ goto Reject
+ }
+ newWritable := true
+ if descriptor.mode&0700 == 0 {
+ // If writable is off
+ newWritable = false
+ descriptor.mode |= 0100
+ }
+ if !objectDefineOwnProperty(self, name, descriptor, throw) {
+ return false
+ }
+ for newLength < length {
+ length -= 1
+ if !self.delete(strconv.FormatInt(int64(length), 10), false) {
+ descriptor.value = toValue_uint32(length + 1)
+ if !newWritable {
+ descriptor.mode &= 0077
+ }
+ objectDefineOwnProperty(self, name, descriptor, false)
+ goto Reject
+ }
+ }
+ if !newWritable {
+ descriptor.mode &= 0077
+ objectDefineOwnProperty(self, name, descriptor, false)
+ }
+ } else if index := stringToArrayIndex(name); index >= 0 {
+ if index >= int64(length) && !lengthProperty.writable() {
+ goto Reject
+ }
+ if !objectDefineOwnProperty(self, strconv.FormatInt(index, 10), descriptor, false) {
+ goto Reject
+ }
+ if index >= int64(length) {
+ lengthProperty.value = toValue_uint32(uint32(index + 1))
+ objectDefineOwnProperty(self, "length", *lengthProperty, false)
+ return true
+ }
+ }
+ return objectDefineOwnProperty(self, name, descriptor, throw)
+Reject:
+ if throw {
+ panic(self.runtime.panicTypeError())
+ }
+ return false
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/type_boolean.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/type_boolean.go
new file mode 100644
index 000000000..afc45c69b
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/type_boolean.go
@@ -0,0 +1,13 @@
+package otto
+
+import (
+ "strconv"
+)
+
+func (runtime *_runtime) newBooleanObject(value Value) *_object {
+ return runtime.newPrimitiveObject("Boolean", toValue_bool(value.bool()))
+}
+
+func booleanToString(value bool) string {
+ return strconv.FormatBool(value)
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/type_date.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/type_date.go
new file mode 100644
index 000000000..7079e649c
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/type_date.go
@@ -0,0 +1,299 @@
+package otto
+
+import (
+ "fmt"
+ "math"
+ "regexp"
+ Time "time"
+)
+
+type _dateObject struct {
+ time Time.Time // Time from the "time" package, a cached version of time
+ epoch int64
+ value Value
+ isNaN bool
+}
+
+var (
+ invalidDateObject = _dateObject{
+ time: Time.Time{},
+ epoch: -1,
+ value: NaNValue(),
+ isNaN: true,
+ }
+)
+
+type _ecmaTime struct {
+ year int
+ month int
+ day int
+ hour int
+ minute int
+ second int
+ millisecond int
+ location *Time.Location // Basically, either local or UTC
+}
+
+func ecmaTime(goTime Time.Time) _ecmaTime {
+ return _ecmaTime{
+ goTime.Year(),
+ dateFromGoMonth(goTime.Month()),
+ goTime.Day(),
+ goTime.Hour(),
+ goTime.Minute(),
+ goTime.Second(),
+ goTime.Nanosecond() / (100 * 100 * 100),
+ goTime.Location(),
+ }
+}
+
+func (self *_ecmaTime) goTime() Time.Time {
+ return Time.Date(
+ self.year,
+ dateToGoMonth(self.month),
+ self.day,
+ self.hour,
+ self.minute,
+ self.second,
+ self.millisecond*(100*100*100),
+ self.location,
+ )
+}
+
+func (self *_dateObject) Time() Time.Time {
+ return self.time
+}
+
+func (self *_dateObject) Epoch() int64 {
+ return self.epoch
+}
+
+func (self *_dateObject) Value() Value {
+ return self.value
+}
+
+// FIXME A date should only be in the range of -100,000,000 to +100,000,000 (1970): 15.9.1.1
+func (self *_dateObject) SetNaN() {
+ self.time = Time.Time{}
+ self.epoch = -1
+ self.value = NaNValue()
+ self.isNaN = true
+}
+
+func (self *_dateObject) SetTime(time Time.Time) {
+ self.Set(timeToEpoch(time))
+}
+
+func epoch2dateObject(epoch float64) _dateObject {
+ date := _dateObject{}
+ date.Set(epoch)
+ return date
+}
+
+func (self *_dateObject) Set(epoch float64) {
+ // epoch
+ self.epoch = epochToInteger(epoch)
+
+ // time
+ time, err := epochToTime(epoch)
+ self.time = time // Is either a valid time, or the zero-value for time.Time
+
+ // value & isNaN
+ if err != nil {
+ self.isNaN = true
+ self.epoch = -1
+ self.value = NaNValue()
+ } else {
+ self.value = toValue_int64(self.epoch)
+ }
+}
+
+func epochToInteger(value float64) int64 {
+ if value > 0 {
+ return int64(math.Floor(value))
+ }
+ return int64(math.Ceil(value))
+}
+
+func epochToTime(value float64) (time Time.Time, err error) {
+ epochWithMilli := value
+ if math.IsNaN(epochWithMilli) || math.IsInf(epochWithMilli, 0) {
+ err = fmt.Errorf("Invalid time %v", value)
+ return
+ }
+
+ epoch := int64(epochWithMilli / 1000)
+ milli := int64(epochWithMilli) % 1000
+
+ time = Time.Unix(int64(epoch), milli*1000000).UTC()
+ return
+}
+
+func timeToEpoch(time Time.Time) float64 {
+ return float64(time.UnixNano() / (1000 * 1000))
+}
+
+func (runtime *_runtime) newDateObject(epoch float64) *_object {
+ self := runtime.newObject()
+ self.class = "Date"
+
+ // FIXME This is ugly...
+ date := _dateObject{}
+ date.Set(epoch)
+ self.value = date
+ return self
+}
+
+func (self *_object) dateValue() _dateObject {
+ value, _ := self.value.(_dateObject)
+ return value
+}
+
+func dateObjectOf(rt *_runtime, _dateObject *_object) _dateObject {
+ if _dateObject == nil || _dateObject.class != "Date" {
+ panic(rt.panicTypeError())
+ }
+ return _dateObject.dateValue()
+}
+
+// JavaScript is 0-based, Go is 1-based (15.9.1.4)
+func dateToGoMonth(month int) Time.Month {
+ return Time.Month(month + 1)
+}
+
+func dateFromGoMonth(month Time.Month) int {
+ return int(month) - 1
+}
+
+// Both JavaScript & Go are 0-based (Sunday == 0)
+func dateToGoDay(day int) Time.Weekday {
+ return Time.Weekday(day)
+}
+
+func dateFromGoDay(day Time.Weekday) int {
+ return int(day)
+}
+
+func newDateTime(argumentList []Value, location *Time.Location) (epoch float64) {
+
+ pick := func(index int, default_ float64) (float64, bool) {
+ if index >= len(argumentList) {
+ return default_, false
+ }
+ value := argumentList[index].float64()
+ if math.IsNaN(value) || math.IsInf(value, 0) {
+ return 0, true
+ }
+ return value, false
+ }
+
+ if len(argumentList) >= 2 { // 2-argument, 3-argument, ...
+ var year, month, day, hour, minute, second, millisecond float64
+ var invalid bool
+ if year, invalid = pick(0, 1900.0); invalid {
+ goto INVALID
+ }
+ if month, invalid = pick(1, 0.0); invalid {
+ goto INVALID
+ }
+ if day, invalid = pick(2, 1.0); invalid {
+ goto INVALID
+ }
+ if hour, invalid = pick(3, 0.0); invalid {
+ goto INVALID
+ }
+ if minute, invalid = pick(4, 0.0); invalid {
+ goto INVALID
+ }
+ if second, invalid = pick(5, 0.0); invalid {
+ goto INVALID
+ }
+ if millisecond, invalid = pick(6, 0.0); invalid {
+ goto INVALID
+ }
+
+ if year >= 0 && year <= 99 {
+ year += 1900
+ }
+
+ time := Time.Date(int(year), dateToGoMonth(int(month)), int(day), int(hour), int(minute), int(second), int(millisecond)*1000*1000, location)
+ return timeToEpoch(time)
+
+ } else if len(argumentList) == 0 { // 0-argument
+ time := Time.Now().UTC()
+ return timeToEpoch(time)
+ } else { // 1-argument
+ value := valueOfArrayIndex(argumentList, 0)
+ value = toPrimitive(value)
+ if value.IsString() {
+ return dateParse(value.string())
+ }
+
+ return value.float64()
+ }
+
+INVALID:
+ epoch = math.NaN()
+ return
+}
+
+var (
+ dateLayoutList = []string{
+ "2006",
+ "2006-01",
+ "2006-01-02",
+
+ "2006T15:04",
+ "2006-01T15:04",
+ "2006-01-02T15:04",
+
+ "2006T15:04:05",
+ "2006-01T15:04:05",
+ "2006-01-02T15:04:05",
+
+ "2006T15:04:05.000",
+ "2006-01T15:04:05.000",
+ "2006-01-02T15:04:05.000",
+
+ "2006T15:04-0700",
+ "2006-01T15:04-0700",
+ "2006-01-02T15:04-0700",
+
+ "2006T15:04:05-0700",
+ "2006-01T15:04:05-0700",
+ "2006-01-02T15:04:05-0700",
+
+ "2006T15:04:05.000-0700",
+ "2006-01T15:04:05.000-0700",
+ "2006-01-02T15:04:05.000-0700",
+
+ Time.RFC1123,
+ }
+ matchDateTimeZone = regexp.MustCompile(`^(.*)(?:(Z)|([\+\-]\d{2}):(\d{2}))$`)
+)
+
+func dateParse(date string) (epoch float64) {
+ // YYYY-MM-DDTHH:mm:ss.sssZ
+ var time Time.Time
+ var err error
+ {
+ date := date
+ if match := matchDateTimeZone.FindStringSubmatch(date); match != nil {
+ if match[2] == "Z" {
+ date = match[1] + "+0000"
+ } else {
+ date = match[1] + match[3] + match[4]
+ }
+ }
+ for _, layout := range dateLayoutList {
+ time, err = Time.Parse(layout, date)
+ if err == nil {
+ break
+ }
+ }
+ }
+ if err != nil {
+ return math.NaN()
+ }
+ return float64(time.UnixNano()) / (1000 * 1000) // UnixMilli()
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/type_error.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/type_error.go
new file mode 100644
index 000000000..c469f5fcb
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/type_error.go
@@ -0,0 +1,13 @@
+package otto
+
+func (rt *_runtime) newErrorObject(name string, message Value) *_object {
+ self := rt.newClassObject("Error")
+ if message.IsDefined() {
+ msg := message.string()
+ self.defineProperty("message", toValue_string(msg), 0111, false)
+ self.value = newError(rt, name, msg)
+ } else {
+ self.value = newError(rt, name)
+ }
+ return self
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/type_function.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/type_function.go
new file mode 100644
index 000000000..a5eb7554a
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/type_function.go
@@ -0,0 +1,262 @@
+package otto
+
+// _constructFunction
+type _constructFunction func(*_object, []Value) Value
+
+// 13.2.2 [[Construct]]
+func defaultConstruct(fn *_object, argumentList []Value) Value {
+ object := fn.runtime.newObject()
+ object.class = "Object"
+
+ prototype := fn.get("prototype")
+ if prototype.kind != valueObject {
+ prototype = toValue_object(fn.runtime.global.ObjectPrototype)
+ }
+ object.prototype = prototype._object()
+
+ this := toValue_object(object)
+ value := fn.call(this, argumentList, false, nativeFrame)
+ if value.kind == valueObject {
+ return value
+ }
+ return this
+}
+
+// _nativeFunction
+type _nativeFunction func(FunctionCall) Value
+
+// ===================== //
+// _nativeFunctionObject //
+// ===================== //
+
+type _nativeFunctionObject struct {
+ name string
+ call _nativeFunction // [[Call]]
+ construct _constructFunction // [[Construct]]
+}
+
+func (runtime *_runtime) newNativeFunctionObject(name string, native _nativeFunction, length int) *_object {
+ self := runtime.newClassObject("Function")
+ self.value = _nativeFunctionObject{
+ call: native,
+ construct: defaultConstruct,
+ }
+ self.defineProperty("length", toValue_int(length), 0000, false)
+ return self
+}
+
+// =================== //
+// _bindFunctionObject //
+// =================== //
+
+type _bindFunctionObject struct {
+ target *_object
+ this Value
+ argumentList []Value
+}
+
+func (runtime *_runtime) newBoundFunctionObject(target *_object, this Value, argumentList []Value) *_object {
+ self := runtime.newClassObject("Function")
+ self.value = _bindFunctionObject{
+ target: target,
+ this: this,
+ argumentList: argumentList,
+ }
+ length := int(toInt32(target.get("length")))
+ length -= len(argumentList)
+ if length < 0 {
+ length = 0
+ }
+ self.defineProperty("length", toValue_int(length), 0000, false)
+ self.defineProperty("caller", Value{}, 0000, false) // TODO Should throw a TypeError
+ self.defineProperty("arguments", Value{}, 0000, false) // TODO Should throw a TypeError
+ return self
+}
+
+// [[Construct]]
+func (fn _bindFunctionObject) construct(argumentList []Value) Value {
+ object := fn.target
+ switch value := object.value.(type) {
+ case _nativeFunctionObject:
+ return value.construct(object, fn.argumentList)
+ case _nodeFunctionObject:
+ argumentList = append(fn.argumentList, argumentList...)
+ return object.construct(argumentList)
+ }
+ panic(fn.target.runtime.panicTypeError())
+}
+
+// =================== //
+// _nodeFunctionObject //
+// =================== //
+
+type _nodeFunctionObject struct {
+ node *_nodeFunctionLiteral
+ stash _stash
+}
+
+func (runtime *_runtime) newNodeFunctionObject(node *_nodeFunctionLiteral, stash _stash) *_object {
+ self := runtime.newClassObject("Function")
+ self.value = _nodeFunctionObject{
+ node: node,
+ stash: stash,
+ }
+ self.defineProperty("length", toValue_int(len(node.parameterList)), 0000, false)
+ return self
+}
+
+// ======= //
+// _object //
+// ======= //
+
+func (self *_object) isCall() bool {
+ switch fn := self.value.(type) {
+ case _nativeFunctionObject:
+ return fn.call != nil
+ case _bindFunctionObject:
+ return true
+ case _nodeFunctionObject:
+ return true
+ }
+ return false
+}
+
+func (self *_object) call(this Value, argumentList []Value, eval bool, frame _frame) Value {
+ switch fn := self.value.(type) {
+
+ case _nativeFunctionObject:
+ // TODO Enter a scope, name from the native object...
+ // Since eval is a native function, we only have to check for it here
+ if eval {
+ eval = self == self.runtime.eval // If eval is true, then it IS a direct eval
+ }
+ return fn.call(FunctionCall{
+ runtime: self.runtime,
+ eval: eval,
+
+ This: this,
+ ArgumentList: argumentList,
+ Otto: self.runtime.otto,
+ })
+
+ case _bindFunctionObject:
+ // TODO Passthrough site, do not enter a scope
+ argumentList = append(fn.argumentList, argumentList...)
+ return fn.target.call(fn.this, argumentList, false, frame)
+
+ case _nodeFunctionObject:
+ rt := self.runtime
+ stash := rt.enterFunctionScope(fn.stash, this)
+ defer func() {
+ rt.leaveScope()
+ }()
+ rt.scope.frame = frame
+ callValue := rt.cmpl_call_nodeFunction(self, stash, fn.node, this, argumentList)
+ if value, valid := callValue.value.(_result); valid {
+ return value.value
+ }
+ return callValue
+ }
+
+ panic(self.runtime.panicTypeError("%v is not a function", toValue_object(self)))
+}
+
+func (self *_object) construct(argumentList []Value) Value {
+ switch fn := self.value.(type) {
+
+ case _nativeFunctionObject:
+ if fn.call == nil {
+ panic(self.runtime.panicTypeError("%v is not a function", toValue_object(self)))
+ }
+ if fn.construct == nil {
+ panic(self.runtime.panicTypeError("%v is not a constructor", toValue_object(self)))
+ }
+ return fn.construct(self, argumentList)
+
+ case _bindFunctionObject:
+ return fn.construct(argumentList)
+
+ case _nodeFunctionObject:
+ return defaultConstruct(self, argumentList)
+ }
+
+ panic(self.runtime.panicTypeError("%v is not a function", toValue_object(self)))
+}
+
+// 15.3.5.3
+func (self *_object) hasInstance(of Value) bool {
+ if !self.isCall() {
+ // We should not have a hasInstance method
+ panic(self.runtime.panicTypeError())
+ }
+ if !of.IsObject() {
+ return false
+ }
+ prototype := self.get("prototype")
+ if !prototype.IsObject() {
+ panic(self.runtime.panicTypeError())
+ }
+ prototypeObject := prototype._object()
+
+ value := of._object().prototype
+ for value != nil {
+ if value == prototypeObject {
+ return true
+ }
+ value = value.prototype
+ }
+ return false
+}
+
+// ============ //
+// FunctionCall //
+// ============ //
+
+// FunctionCall is an encapsulation of a JavaScript function call.
+type FunctionCall struct {
+ runtime *_runtime
+ _thisObject *_object
+ eval bool // This call is a direct call to eval
+
+ This Value
+ ArgumentList []Value
+ Otto *Otto
+}
+
+// Argument will return the value of the argument at the given index.
+//
+// If no such argument exists, undefined is returned.
+func (self FunctionCall) Argument(index int) Value {
+ return valueOfArrayIndex(self.ArgumentList, index)
+}
+
+func (self FunctionCall) getArgument(index int) (Value, bool) {
+ return getValueOfArrayIndex(self.ArgumentList, index)
+}
+
+func (self FunctionCall) slice(index int) []Value {
+ if index < len(self.ArgumentList) {
+ return self.ArgumentList[index:]
+ }
+ return []Value{}
+}
+
+func (self *FunctionCall) thisObject() *_object {
+ if self._thisObject == nil {
+ this := self.This.resolve() // FIXME Is this right?
+ self._thisObject = self.runtime.toObject(this)
+ }
+ return self._thisObject
+}
+
+func (self *FunctionCall) thisClassObject(class string) *_object {
+ thisObject := self.thisObject()
+ if thisObject.class != class {
+ panic(self.runtime.panicTypeError())
+ }
+ return self._thisObject
+}
+
+func (self FunctionCall) toObject(value Value) *_object {
+ return self.runtime.toObject(value)
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/type_go_array.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/type_go_array.go
new file mode 100644
index 000000000..13a0b10f2
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/type_go_array.go
@@ -0,0 +1,134 @@
+package otto
+
+import (
+ "reflect"
+ "strconv"
+)
+
+func (runtime *_runtime) newGoArrayObject(value reflect.Value) *_object {
+ self := runtime.newObject()
+ self.class = "GoArray"
+ self.objectClass = _classGoArray
+ self.value = _newGoArrayObject(value)
+ return self
+}
+
+type _goArrayObject struct {
+ value reflect.Value
+ writable bool
+ propertyMode _propertyMode
+}
+
+func _newGoArrayObject(value reflect.Value) *_goArrayObject {
+ writable := value.Kind() == reflect.Ptr // The Array is addressable (like a Slice)
+ mode := _propertyMode(0010)
+ if writable {
+ mode = 0110
+ }
+ self := &_goArrayObject{
+ value: value,
+ writable: writable,
+ propertyMode: mode,
+ }
+ return self
+}
+
+func (self _goArrayObject) getValue(index int64) (reflect.Value, bool) {
+ value := reflect.Indirect(self.value)
+ if index < int64(value.Len()) {
+ return value.Index(int(index)), true
+ }
+ return reflect.Value{}, false
+}
+
+func (self _goArrayObject) setValue(index int64, value Value) bool {
+ indexValue, exists := self.getValue(index)
+ if !exists {
+ return false
+ }
+ reflectValue, err := value.toReflectValue(reflect.Indirect(self.value).Type().Elem().Kind())
+ if err != nil {
+ panic(err)
+ }
+ indexValue.Set(reflectValue)
+ return true
+}
+
+func goArrayGetOwnProperty(self *_object, name string) *_property {
+ // length
+ if name == "length" {
+ return &_property{
+ value: toValue(reflect.Indirect(self.value.(*_goArrayObject).value).Len()),
+ mode: 0,
+ }
+ }
+
+ // .0, .1, .2, ...
+ index := stringToArrayIndex(name)
+ if index >= 0 {
+ object := self.value.(*_goArrayObject)
+ value := Value{}
+ reflectValue, exists := object.getValue(index)
+ if exists {
+ value = self.runtime.toValue(reflectValue.Interface())
+ }
+ return &_property{
+ value: value,
+ mode: object.propertyMode,
+ }
+ }
+
+ return objectGetOwnProperty(self, name)
+}
+
+func goArrayEnumerate(self *_object, all bool, each func(string) bool) {
+ object := self.value.(*_goArrayObject)
+ // .0, .1, .2, ...
+
+ for index, length := 0, object.value.Len(); index < length; index++ {
+ name := strconv.FormatInt(int64(index), 10)
+ if !each(name) {
+ return
+ }
+ }
+
+ objectEnumerate(self, all, each)
+}
+
+func goArrayDefineOwnProperty(self *_object, name string, descriptor _property, throw bool) bool {
+ if name == "length" {
+ return self.runtime.typeErrorResult(throw)
+ } else if index := stringToArrayIndex(name); index >= 0 {
+ object := self.value.(*_goArrayObject)
+ if object.writable {
+ if self.value.(*_goArrayObject).setValue(index, descriptor.value.(Value)) {
+ return true
+ }
+ }
+ return self.runtime.typeErrorResult(throw)
+ }
+ return objectDefineOwnProperty(self, name, descriptor, throw)
+}
+
+func goArrayDelete(self *_object, name string, throw bool) bool {
+ // length
+ if name == "length" {
+ return self.runtime.typeErrorResult(throw)
+ }
+
+ // .0, .1, .2, ...
+ index := stringToArrayIndex(name)
+ if index >= 0 {
+ object := self.value.(*_goArrayObject)
+ if object.writable {
+ indexValue, exists := object.getValue(index)
+ if exists {
+ indexValue.Set(reflect.Zero(reflect.Indirect(object.value).Type().Elem()))
+ return true
+ }
+ }
+ return self.runtime.typeErrorResult(throw)
+ }
+
+ return self.delete(name, throw)
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/type_go_map.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/type_go_map.go
new file mode 100644
index 000000000..542a2c29d
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/type_go_map.go
@@ -0,0 +1,87 @@
+package otto
+
+import (
+ "reflect"
+)
+
+func (runtime *_runtime) newGoMapObject(value reflect.Value) *_object {
+ self := runtime.newObject()
+ self.class = "Object" // TODO Should this be something else?
+ self.objectClass = _classGoMap
+ self.value = _newGoMapObject(value)
+ return self
+}
+
+type _goMapObject struct {
+ value reflect.Value
+ keyKind reflect.Kind
+ valueKind reflect.Kind
+}
+
+func _newGoMapObject(value reflect.Value) *_goMapObject {
+ if value.Kind() != reflect.Map {
+ dbgf("%/panic//%@: %v != reflect.Map", value.Kind())
+ }
+ self := &_goMapObject{
+ value: value,
+ keyKind: value.Type().Key().Kind(),
+ valueKind: value.Type().Elem().Kind(),
+ }
+ return self
+}
+
+func (self _goMapObject) toKey(name string) reflect.Value {
+ reflectValue, err := stringToReflectValue(name, self.keyKind)
+ if err != nil {
+ panic(err)
+ }
+ return reflectValue
+}
+
+func (self _goMapObject) toValue(value Value) reflect.Value {
+ reflectValue, err := value.toReflectValue(self.valueKind)
+ if err != nil {
+ panic(err)
+ }
+ return reflectValue
+}
+
+func goMapGetOwnProperty(self *_object, name string) *_property {
+ object := self.value.(*_goMapObject)
+ value := object.value.MapIndex(object.toKey(name))
+ if value.IsValid() {
+ return &_property{self.runtime.toValue(value.Interface()), 0111}
+ }
+
+ return nil
+}
+
+func goMapEnumerate(self *_object, all bool, each func(string) bool) {
+ object := self.value.(*_goMapObject)
+ keys := object.value.MapKeys()
+ for _, key := range keys {
+ if !each(key.String()) {
+ return
+ }
+ }
+}
+
+func goMapDefineOwnProperty(self *_object, name string, descriptor _property, throw bool) bool {
+ object := self.value.(*_goMapObject)
+ // TODO ...or 0222
+ if descriptor.mode != 0111 {
+ return self.runtime.typeErrorResult(throw)
+ }
+ if !descriptor.isDataDescriptor() {
+ return self.runtime.typeErrorResult(throw)
+ }
+ object.value.SetMapIndex(object.toKey(name), object.toValue(descriptor.value.(Value)))
+ return true
+}
+
+func goMapDelete(self *_object, name string, throw bool) bool {
+ object := self.value.(*_goMapObject)
+ object.value.SetMapIndex(object.toKey(name), reflect.Value{})
+ // FIXME
+ return true
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/type_go_slice.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/type_go_slice.go
new file mode 100644
index 000000000..7143531a8
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/type_go_slice.go
@@ -0,0 +1,118 @@
+package otto
+
+import (
+ "reflect"
+ "strconv"
+)
+
+func (runtime *_runtime) newGoSliceObject(value reflect.Value) *_object {
+ self := runtime.newObject()
+ self.class = "GoArray" // TODO GoSlice?
+ self.objectClass = _classGoSlice
+ self.value = _newGoSliceObject(value)
+ return self
+}
+
+type _goSliceObject struct {
+ value reflect.Value
+}
+
+func _newGoSliceObject(value reflect.Value) *_goSliceObject {
+ self := &_goSliceObject{
+ value: value,
+ }
+ return self
+}
+
+func (self _goSliceObject) getValue(index int64) (reflect.Value, bool) {
+ if index < int64(self.value.Len()) {
+ return self.value.Index(int(index)), true
+ }
+ return reflect.Value{}, false
+}
+
+func (self _goSliceObject) setValue(index int64, value Value) bool {
+ indexValue, exists := self.getValue(index)
+ if !exists {
+ return false
+ }
+ reflectValue, err := value.toReflectValue(self.value.Type().Elem().Kind())
+ if err != nil {
+ panic(err)
+ }
+ indexValue.Set(reflectValue)
+ return true
+}
+
+func goSliceGetOwnProperty(self *_object, name string) *_property {
+ // length
+ if name == "length" {
+ return &_property{
+ value: toValue(self.value.(*_goSliceObject).value.Len()),
+ mode: 0,
+ }
+ }
+
+ // .0, .1, .2, ...
+ index := stringToArrayIndex(name)
+ if index >= 0 {
+ value := Value{}
+ reflectValue, exists := self.value.(*_goSliceObject).getValue(index)
+ if exists {
+ value = self.runtime.toValue(reflectValue.Interface())
+ }
+ return &_property{
+ value: value,
+ mode: 0110,
+ }
+ }
+
+ return objectGetOwnProperty(self, name)
+}
+
+func goSliceEnumerate(self *_object, all bool, each func(string) bool) {
+ object := self.value.(*_goSliceObject)
+ // .0, .1, .2, ...
+
+ for index, length := 0, object.value.Len(); index < length; index++ {
+ name := strconv.FormatInt(int64(index), 10)
+ if !each(name) {
+ return
+ }
+ }
+
+ objectEnumerate(self, all, each)
+}
+
+func goSliceDefineOwnProperty(self *_object, name string, descriptor _property, throw bool) bool {
+ if name == "length" {
+ return self.runtime.typeErrorResult(throw)
+ } else if index := stringToArrayIndex(name); index >= 0 {
+ if self.value.(*_goSliceObject).setValue(index, descriptor.value.(Value)) {
+ return true
+ }
+ return self.runtime.typeErrorResult(throw)
+ }
+ return objectDefineOwnProperty(self, name, descriptor, throw)
+}
+
+func goSliceDelete(self *_object, name string, throw bool) bool {
+ // length
+ if name == "length" {
+ return self.runtime.typeErrorResult(throw)
+ }
+
+ // .0, .1, .2, ...
+ index := stringToArrayIndex(name)
+ if index >= 0 {
+ object := self.value.(*_goSliceObject)
+ indexValue, exists := object.getValue(index)
+ if exists {
+ indexValue.Set(reflect.Zero(object.value.Type().Elem()))
+ return true
+ }
+ return self.runtime.typeErrorResult(throw)
+ }
+
+ return self.delete(name, throw)
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/type_go_struct.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/type_go_struct.go
new file mode 100644
index 000000000..608ac6660
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/type_go_struct.go
@@ -0,0 +1,146 @@
+package otto
+
+import (
+ "encoding/json"
+ "reflect"
+)
+
+// FIXME Make a note about not being able to modify a struct unless it was
+// passed as a pointer-to: &struct{ ... }
+// This seems to be a limitation of the reflect package.
+// This goes for the other Go constructs too.
+// I guess we could get around it by either:
+// 1. Creating a new struct every time
+// 2. Creating an addressable? struct in the constructor
+
+func (runtime *_runtime) newGoStructObject(value reflect.Value) *_object {
+ self := runtime.newObject()
+ self.class = "Object" // TODO Should this be something else?
+ self.objectClass = _classGoStruct
+ self.value = _newGoStructObject(value)
+ return self
+}
+
+type _goStructObject struct {
+ value reflect.Value
+}
+
+func _newGoStructObject(value reflect.Value) *_goStructObject {
+ if reflect.Indirect(value).Kind() != reflect.Struct {
+ dbgf("%/panic//%@: %v != reflect.Struct", value.Kind())
+ }
+ self := &_goStructObject{
+ value: value,
+ }
+ return self
+}
+
+func (self _goStructObject) getValue(name string) reflect.Value {
+ if validGoStructName(name) {
+ // Do not reveal hidden or unexported fields
+ if field := reflect.Indirect(self.value).FieldByName(name); (field != reflect.Value{}) {
+ return field
+ }
+
+ if method := self.value.MethodByName(name); (method != reflect.Value{}) {
+ return method
+ }
+ }
+
+ return reflect.Value{}
+}
+
+func (self _goStructObject) field(name string) (reflect.StructField, bool) {
+ return reflect.Indirect(self.value).Type().FieldByName(name)
+}
+
+func (self _goStructObject) method(name string) (reflect.Method, bool) {
+ return reflect.Indirect(self.value).Type().MethodByName(name)
+}
+
+func (self _goStructObject) setValue(name string, value Value) bool {
+ field, exists := self.field(name)
+ if !exists {
+ return false
+ }
+ fieldValue := self.getValue(name)
+ reflectValue, err := value.toReflectValue(field.Type.Kind())
+ if err != nil {
+ panic(err)
+ }
+ fieldValue.Set(reflectValue)
+
+ return true
+}
+
+func goStructGetOwnProperty(self *_object, name string) *_property {
+ object := self.value.(*_goStructObject)
+ value := object.getValue(name)
+ if value.IsValid() {
+ return &_property{self.runtime.toValue(value.Interface()), 0110}
+ }
+
+ return objectGetOwnProperty(self, name)
+}
+
+func validGoStructName(name string) bool {
+ if name == "" {
+ return false
+ }
+ return 'A' <= name[0] && name[0] <= 'Z' // TODO What about Unicode?
+}
+
+func goStructEnumerate(self *_object, all bool, each func(string) bool) {
+ object := self.value.(*_goStructObject)
+
+ // Enumerate fields
+ for index := 0; index < reflect.Indirect(object.value).NumField(); index++ {
+ name := reflect.Indirect(object.value).Type().Field(index).Name
+ if validGoStructName(name) {
+ if !each(name) {
+ return
+ }
+ }
+ }
+
+ // Enumerate methods
+ for index := 0; index < object.value.NumMethod(); index++ {
+ name := object.value.Type().Method(index).Name
+ if validGoStructName(name) {
+ if !each(name) {
+ return
+ }
+ }
+ }
+
+ objectEnumerate(self, all, each)
+}
+
+func goStructCanPut(self *_object, name string) bool {
+ object := self.value.(*_goStructObject)
+ value := object.getValue(name)
+ if value.IsValid() {
+ return true
+ }
+
+ return objectCanPut(self, name)
+}
+
+func goStructPut(self *_object, name string, value Value, throw bool) {
+ object := self.value.(*_goStructObject)
+ if object.setValue(name, value) {
+ return
+ }
+
+ objectPut(self, name, value, throw)
+}
+
+func goStructMarshalJSON(self *_object) json.Marshaler {
+ object := self.value.(*_goStructObject)
+ goValue := reflect.Indirect(object.value).Interface()
+ switch marshaler := goValue.(type) {
+ case json.Marshaler:
+ return marshaler
+ }
+ return nil
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/type_number.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/type_number.go
new file mode 100644
index 000000000..28de4444c
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/type_number.go
@@ -0,0 +1,5 @@
+package otto
+
+func (runtime *_runtime) newNumberObject(value Value) *_object {
+ return runtime.newPrimitiveObject("Number", value.numberValue())
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/type_reference.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/type_reference.go
new file mode 100644
index 000000000..fd770c6f4
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/type_reference.go
@@ -0,0 +1,103 @@
+package otto
+
+type _reference interface {
+ invalid() bool // IsUnresolvableReference
+ getValue() Value // getValue
+ putValue(Value) string // PutValue
+ delete() bool
+}
+
+// PropertyReference
+
+type _propertyReference struct {
+ name string
+ strict bool
+ base *_object
+ runtime *_runtime
+ at _at
+}
+
+func newPropertyReference(rt *_runtime, base *_object, name string, strict bool, at _at) *_propertyReference {
+ return &_propertyReference{
+ runtime: rt,
+ name: name,
+ strict: strict,
+ base: base,
+ at: at,
+ }
+}
+
+func (self *_propertyReference) invalid() bool {
+ return self.base == nil
+}
+
+func (self *_propertyReference) getValue() Value {
+ if self.base == nil {
+ panic(self.runtime.panicReferenceError("'%s' is not defined", self.name, self.at))
+ }
+ return self.base.get(self.name)
+}
+
+func (self *_propertyReference) putValue(value Value) string {
+ if self.base == nil {
+ return self.name
+ }
+ self.base.put(self.name, value, self.strict)
+ return ""
+}
+
+func (self *_propertyReference) delete() bool {
+ if self.base == nil {
+ // TODO Throw an error if strict
+ return true
+ }
+ return self.base.delete(self.name, self.strict)
+}
+
+// ArgumentReference
+
+func newArgumentReference(runtime *_runtime, base *_object, name string, strict bool, at _at) *_propertyReference {
+ if base == nil {
+ panic(hereBeDragons())
+ }
+ return newPropertyReference(runtime, base, name, strict, at)
+}
+
+type _stashReference struct {
+ name string
+ strict bool
+ base _stash
+}
+
+func (self *_stashReference) invalid() bool {
+ return false // The base (an environment) will never be nil
+}
+
+func (self *_stashReference) getValue() Value {
+ return self.base.getBinding(self.name, self.strict)
+}
+
+func (self *_stashReference) putValue(value Value) string {
+ self.base.setValue(self.name, value, self.strict)
+ return ""
+}
+
+func (self *_stashReference) delete() bool {
+ if self.base == nil {
+ // This should never be reached, but just in case
+ return false
+ }
+ return self.base.deleteBinding(self.name)
+}
+
+// getIdentifierReference
+
+func getIdentifierReference(runtime *_runtime, stash _stash, name string, strict bool, at _at) _reference {
+ if stash == nil {
+ return newPropertyReference(runtime, nil, name, strict, at)
+ }
+ if stash.hasBinding(name) {
+ return stash.newReference(name, strict, at)
+ }
+ return getIdentifierReference(runtime, stash.outer(), name, strict, at)
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/type_regexp.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/type_regexp.go
new file mode 100644
index 000000000..57fe31640
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/type_regexp.go
@@ -0,0 +1,146 @@
+package otto
+
+import (
+ "fmt"
+ "regexp"
+ "unicode/utf8"
+
+ "github.com/robertkrimen/otto/parser"
+)
+
+type _regExpObject struct {
+ regularExpression *regexp.Regexp
+ global bool
+ ignoreCase bool
+ multiline bool
+ source string
+ flags string
+}
+
+func (runtime *_runtime) newRegExpObject(pattern string, flags string) *_object {
+ self := runtime.newObject()
+ self.class = "RegExp"
+
+ global := false
+ ignoreCase := false
+ multiline := false
+ re2flags := ""
+
+ // TODO Maybe clean up the panicking here... TypeError, SyntaxError, ?
+
+ for _, chr := range flags {
+ switch chr {
+ case 'g':
+ if global {
+ panic(runtime.panicSyntaxError("newRegExpObject: %s %s", pattern, flags))
+ }
+ global = true
+ case 'm':
+ if multiline {
+ panic(runtime.panicSyntaxError("newRegExpObject: %s %s", pattern, flags))
+ }
+ multiline = true
+ re2flags += "m"
+ case 'i':
+ if ignoreCase {
+ panic(runtime.panicSyntaxError("newRegExpObject: %s %s", pattern, flags))
+ }
+ ignoreCase = true
+ re2flags += "i"
+ }
+ }
+
+ re2pattern, err := parser.TransformRegExp(pattern)
+ if err != nil {
+ panic(runtime.panicTypeError("Invalid regular expression: %s", err.Error()))
+ }
+ if len(re2flags) > 0 {
+ re2pattern = fmt.Sprintf("(?%s:%s)", re2flags, re2pattern)
+ }
+
+ regularExpression, err := regexp.Compile(re2pattern)
+ if err != nil {
+ panic(runtime.panicSyntaxError("Invalid regular expression: %s", err.Error()[22:]))
+ }
+
+ self.value = _regExpObject{
+ regularExpression: regularExpression,
+ global: global,
+ ignoreCase: ignoreCase,
+ multiline: multiline,
+ source: pattern,
+ flags: flags,
+ }
+ self.defineProperty("global", toValue_bool(global), 0, false)
+ self.defineProperty("ignoreCase", toValue_bool(ignoreCase), 0, false)
+ self.defineProperty("multiline", toValue_bool(multiline), 0, false)
+ self.defineProperty("lastIndex", toValue_int(0), 0100, false)
+ self.defineProperty("source", toValue_string(pattern), 0, false)
+ return self
+}
+
+func (self *_object) regExpValue() _regExpObject {
+ value, _ := self.value.(_regExpObject)
+ return value
+}
+
+func execRegExp(this *_object, target string) (match bool, result []int) {
+ if this.class != "RegExp" {
+ panic(this.runtime.panicTypeError("Calling RegExp.exec on a non-RegExp object"))
+ }
+ lastIndex := this.get("lastIndex").number().int64
+ index := lastIndex
+ global := this.get("global").bool()
+ if !global {
+ index = 0
+ }
+ if 0 > index || index > int64(len(target)) {
+ } else {
+ result = this.regExpValue().regularExpression.FindStringSubmatchIndex(target[index:])
+ }
+ if result == nil {
+ //this.defineProperty("lastIndex", toValue_(0), 0111, true)
+ this.put("lastIndex", toValue_int(0), true)
+ return // !match
+ }
+ match = true
+ startIndex := index
+ endIndex := int(lastIndex) + result[1]
+ // We do this shift here because the .FindStringSubmatchIndex above
+ // was done on a local subordinate slice of the string, not the whole string
+ for index, _ := range result {
+ result[index] += int(startIndex)
+ }
+ if global {
+ //this.defineProperty("lastIndex", toValue_(endIndex), 0111, true)
+ this.put("lastIndex", toValue_int(endIndex), true)
+ }
+ return // match
+}
+
+func execResultToArray(runtime *_runtime, target string, result []int) *_object {
+ captureCount := len(result) / 2
+ valueArray := make([]Value, captureCount)
+ for index := 0; index < captureCount; index++ {
+ offset := 2 * index
+ if result[offset] != -1 {
+ valueArray[index] = toValue_string(target[result[offset]:result[offset+1]])
+ } else {
+ valueArray[index] = Value{}
+ }
+ }
+ matchIndex := result[0]
+ if matchIndex != 0 {
+ matchIndex = 0
+ // Find the rune index in the string, not the byte index
+ for index := 0; index < result[0]; {
+ _, size := utf8.DecodeRuneInString(target[index:])
+ matchIndex += 1
+ index += size
+ }
+ }
+ match := runtime.newArrayOf(valueArray)
+ match.defineProperty("input", toValue_string(target), 0111, false)
+ match.defineProperty("index", toValue_int(matchIndex), 0111, false)
+ return match
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/type_string.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/type_string.go
new file mode 100644
index 000000000..ef3afa42b
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/type_string.go
@@ -0,0 +1,112 @@
+package otto
+
+import (
+ "strconv"
+ "unicode/utf8"
+)
+
+type _stringObject interface {
+ Length() int
+ At(int) rune
+ String() string
+}
+
+type _stringASCII string
+
+func (str _stringASCII) Length() int {
+ return len(str)
+}
+
+func (str _stringASCII) At(at int) rune {
+ return rune(str[at])
+}
+
+func (str _stringASCII) String() string {
+ return string(str)
+}
+
+type _stringWide struct {
+ string string
+ length int
+ runes []rune
+}
+
+func (str _stringWide) Length() int {
+ return str.length
+}
+
+func (str _stringWide) At(at int) rune {
+ if str.runes == nil {
+ str.runes = []rune(str.string)
+ }
+ return str.runes[at]
+}
+
+func (str _stringWide) String() string {
+ return str.string
+}
+
+func _newStringObject(str string) _stringObject {
+ for i := 0; i < len(str); i++ {
+ if str[i] >= utf8.RuneSelf {
+ goto wide
+ }
+ }
+
+ return _stringASCII(str)
+
+wide:
+ return &_stringWide{
+ string: str,
+ length: utf8.RuneCountInString(str),
+ }
+}
+
+func stringAt(str _stringObject, index int) rune {
+ if 0 <= index && index < str.Length() {
+ return str.At(index)
+ }
+ return utf8.RuneError
+}
+
+func (runtime *_runtime) newStringObject(value Value) *_object {
+ str := _newStringObject(value.string())
+
+ self := runtime.newClassObject("String")
+ self.defineProperty("length", toValue_int(str.Length()), 0, false)
+ self.objectClass = _classString
+ self.value = str
+ return self
+}
+
+func (self *_object) stringValue() _stringObject {
+ if str, ok := self.value.(_stringObject); ok {
+ return str
+ }
+ return nil
+}
+
+func stringEnumerate(self *_object, all bool, each func(string) bool) {
+ if str := self.stringValue(); str != nil {
+ length := str.Length()
+ for index := 0; index < length; index++ {
+ if !each(strconv.FormatInt(int64(index), 10)) {
+ return
+ }
+ }
+ }
+ objectEnumerate(self, all, each)
+}
+
+func stringGetOwnProperty(self *_object, name string) *_property {
+ if property := objectGetOwnProperty(self, name); property != nil {
+ return property
+ }
+ // TODO Test a string of length >= +int32 + 1?
+ if index := stringToArrayIndex(name); index >= 0 {
+ if chr := stringAt(self.stringValue(), int(index)); chr != utf8.RuneError {
+ return &_property{toValue_string(string(chr)), 0}
+ }
+ }
+ return nil
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/underscore/Makefile b/Godeps/_workspace/src/github.com/robertkrimen/otto/underscore/Makefile
new file mode 100644
index 000000000..fc872917f
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/underscore/Makefile
@@ -0,0 +1,11 @@
+.PHONY: source
+
+source: source.go
+
+underscore.js:
+ curl -kL http://underscorejs.org/underscore.js > $@
+
+source.go: underscore.js
+ go-bindata -f underscore -p underscore -u true < $< 2>/dev/null | grep -v '^//' | gofmt > $@
+ head -4 $< >> $@
+ mv $< ..
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/underscore/README.markdown b/Godeps/_workspace/src/github.com/robertkrimen/otto/underscore/README.markdown
new file mode 100644
index 000000000..bce37b695
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/underscore/README.markdown
@@ -0,0 +1,53 @@
+# underscore
+--
+ import "github.com/robertkrimen/otto/underscore"
+
+Package underscore contains the source for the JavaScript utility-belt library.
+
+ import (
+ _ "github.com/robertkrimen/otto/underscore"
+ )
+ // Every Otto runtime will now include underscore
+
+http://underscorejs.org
+
+https://github.com/documentcloud/underscore
+
+By importing this package, you'll automatically load underscore every time you
+create a new Otto runtime.
+
+To prevent this behavior, you can do the following:
+
+ import (
+ "github.com/robertkrimen/otto/underscore"
+ )
+
+ func init() {
+ underscore.Disable()
+ }
+
+## Usage
+
+#### func Disable
+
+```go
+func Disable()
+```
+Disable underscore runtime inclusion.
+
+#### func Enable
+
+```go
+func Enable()
+```
+Enable underscore runtime inclusion.
+
+#### func Source
+
+```go
+func Source() string
+```
+Source returns the underscore source.
+
+--
+**godocdown** http://github.com/robertkrimen/godocdown
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/underscore/source.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/underscore/source.go
new file mode 100644
index 000000000..65754ab71
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/underscore/source.go
@@ -0,0 +1,3462 @@
+package underscore
+
+func underscore() []byte {
+ return []byte{
+ 0x2f, 0x2f, 0x20, 0x20, 0x20, 0x20, 0x20, 0x55, 0x6e, 0x64, 0x65, 0x72,
+ 0x73, 0x63, 0x6f, 0x72, 0x65, 0x2e, 0x6a, 0x73, 0x20, 0x31, 0x2e, 0x34,
+ 0x2e, 0x34, 0x0a, 0x2f, 0x2f, 0x20, 0x20, 0x20, 0x20, 0x20, 0x68, 0x74,
+ 0x74, 0x70, 0x3a, 0x2f, 0x2f, 0x75, 0x6e, 0x64, 0x65, 0x72, 0x73, 0x63,
+ 0x6f, 0x72, 0x65, 0x6a, 0x73, 0x2e, 0x6f, 0x72, 0x67, 0x0a, 0x2f, 0x2f,
+ 0x20, 0x20, 0x20, 0x20, 0x20, 0x28, 0x63, 0x29, 0x20, 0x32, 0x30, 0x30,
+ 0x39, 0x2d, 0x32, 0x30, 0x31, 0x33, 0x20, 0x4a, 0x65, 0x72, 0x65, 0x6d,
+ 0x79, 0x20, 0x41, 0x73, 0x68, 0x6b, 0x65, 0x6e, 0x61, 0x73, 0x2c, 0x20,
+ 0x44, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x43, 0x6c, 0x6f, 0x75,
+ 0x64, 0x20, 0x49, 0x6e, 0x63, 0x2e, 0x0a, 0x2f, 0x2f, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x55, 0x6e, 0x64, 0x65, 0x72, 0x73, 0x63, 0x6f, 0x72, 0x65,
+ 0x20, 0x6d, 0x61, 0x79, 0x20, 0x62, 0x65, 0x20, 0x66, 0x72, 0x65, 0x65,
+ 0x6c, 0x79, 0x20, 0x64, 0x69, 0x73, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74,
+ 0x65, 0x64, 0x20, 0x75, 0x6e, 0x64, 0x65, 0x72, 0x20, 0x74, 0x68, 0x65,
+ 0x20, 0x4d, 0x49, 0x54, 0x20, 0x6c, 0x69, 0x63, 0x65, 0x6e, 0x73, 0x65,
+ 0x2e, 0x0a, 0x0a, 0x28, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e,
+ 0x28, 0x29, 0x20, 0x7b, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x42,
+ 0x61, 0x73, 0x65, 0x6c, 0x69, 0x6e, 0x65, 0x20, 0x73, 0x65, 0x74, 0x75,
+ 0x70, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x2d, 0x2d, 0x2d, 0x2d, 0x2d,
+ 0x2d, 0x2d, 0x2d, 0x2d, 0x2d, 0x2d, 0x2d, 0x2d, 0x2d, 0x0a, 0x0a, 0x20,
+ 0x20, 0x2f, 0x2f, 0x20, 0x45, 0x73, 0x74, 0x61, 0x62, 0x6c, 0x69, 0x73,
+ 0x68, 0x20, 0x74, 0x68, 0x65, 0x20, 0x72, 0x6f, 0x6f, 0x74, 0x20, 0x6f,
+ 0x62, 0x6a, 0x65, 0x63, 0x74, 0x2c, 0x20, 0x60, 0x77, 0x69, 0x6e, 0x64,
+ 0x6f, 0x77, 0x60, 0x20, 0x69, 0x6e, 0x20, 0x74, 0x68, 0x65, 0x20, 0x62,
+ 0x72, 0x6f, 0x77, 0x73, 0x65, 0x72, 0x2c, 0x20, 0x6f, 0x72, 0x20, 0x60,
+ 0x67, 0x6c, 0x6f, 0x62, 0x61, 0x6c, 0x60, 0x20, 0x6f, 0x6e, 0x20, 0x74,
+ 0x68, 0x65, 0x20, 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, 0x2e, 0x0a, 0x20,
+ 0x20, 0x76, 0x61, 0x72, 0x20, 0x72, 0x6f, 0x6f, 0x74, 0x20, 0x3d, 0x20,
+ 0x74, 0x68, 0x69, 0x73, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20,
+ 0x53, 0x61, 0x76, 0x65, 0x20, 0x74, 0x68, 0x65, 0x20, 0x70, 0x72, 0x65,
+ 0x76, 0x69, 0x6f, 0x75, 0x73, 0x20, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x20,
+ 0x6f, 0x66, 0x20, 0x74, 0x68, 0x65, 0x20, 0x60, 0x5f, 0x60, 0x20, 0x76,
+ 0x61, 0x72, 0x69, 0x61, 0x62, 0x6c, 0x65, 0x2e, 0x0a, 0x20, 0x20, 0x76,
+ 0x61, 0x72, 0x20, 0x70, 0x72, 0x65, 0x76, 0x69, 0x6f, 0x75, 0x73, 0x55,
+ 0x6e, 0x64, 0x65, 0x72, 0x73, 0x63, 0x6f, 0x72, 0x65, 0x20, 0x3d, 0x20,
+ 0x72, 0x6f, 0x6f, 0x74, 0x2e, 0x5f, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f,
+ 0x2f, 0x20, 0x45, 0x73, 0x74, 0x61, 0x62, 0x6c, 0x69, 0x73, 0x68, 0x20,
+ 0x74, 0x68, 0x65, 0x20, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, 0x74,
+ 0x68, 0x61, 0x74, 0x20, 0x67, 0x65, 0x74, 0x73, 0x20, 0x72, 0x65, 0x74,
+ 0x75, 0x72, 0x6e, 0x65, 0x64, 0x20, 0x74, 0x6f, 0x20, 0x62, 0x72, 0x65,
+ 0x61, 0x6b, 0x20, 0x6f, 0x75, 0x74, 0x20, 0x6f, 0x66, 0x20, 0x61, 0x20,
+ 0x6c, 0x6f, 0x6f, 0x70, 0x20, 0x69, 0x74, 0x65, 0x72, 0x61, 0x74, 0x69,
+ 0x6f, 0x6e, 0x2e, 0x0a, 0x20, 0x20, 0x76, 0x61, 0x72, 0x20, 0x62, 0x72,
+ 0x65, 0x61, 0x6b, 0x65, 0x72, 0x20, 0x3d, 0x20, 0x7b, 0x7d, 0x3b, 0x0a,
+ 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x53, 0x61, 0x76, 0x65, 0x20, 0x62,
+ 0x79, 0x74, 0x65, 0x73, 0x20, 0x69, 0x6e, 0x20, 0x74, 0x68, 0x65, 0x20,
+ 0x6d, 0x69, 0x6e, 0x69, 0x66, 0x69, 0x65, 0x64, 0x20, 0x28, 0x62, 0x75,
+ 0x74, 0x20, 0x6e, 0x6f, 0x74, 0x20, 0x67, 0x7a, 0x69, 0x70, 0x70, 0x65,
+ 0x64, 0x29, 0x20, 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x3a, 0x0a,
+ 0x20, 0x20, 0x76, 0x61, 0x72, 0x20, 0x41, 0x72, 0x72, 0x61, 0x79, 0x50,
+ 0x72, 0x6f, 0x74, 0x6f, 0x20, 0x3d, 0x20, 0x41, 0x72, 0x72, 0x61, 0x79,
+ 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x74, 0x79, 0x70, 0x65, 0x2c, 0x20,
+ 0x4f, 0x62, 0x6a, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x20, 0x3d, 0x20, 0x4f,
+ 0x62, 0x6a, 0x65, 0x63, 0x74, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x74,
+ 0x79, 0x70, 0x65, 0x2c, 0x20, 0x46, 0x75, 0x6e, 0x63, 0x50, 0x72, 0x6f,
+ 0x74, 0x6f, 0x20, 0x3d, 0x20, 0x46, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f,
+ 0x6e, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x74, 0x79, 0x70, 0x65, 0x3b,
+ 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x43, 0x72, 0x65, 0x61, 0x74,
+ 0x65, 0x20, 0x71, 0x75, 0x69, 0x63, 0x6b, 0x20, 0x72, 0x65, 0x66, 0x65,
+ 0x72, 0x65, 0x6e, 0x63, 0x65, 0x20, 0x76, 0x61, 0x72, 0x69, 0x61, 0x62,
+ 0x6c, 0x65, 0x73, 0x20, 0x66, 0x6f, 0x72, 0x20, 0x73, 0x70, 0x65, 0x65,
+ 0x64, 0x20, 0x61, 0x63, 0x63, 0x65, 0x73, 0x73, 0x20, 0x74, 0x6f, 0x20,
+ 0x63, 0x6f, 0x72, 0x65, 0x20, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x74, 0x79,
+ 0x70, 0x65, 0x73, 0x2e, 0x0a, 0x20, 0x20, 0x76, 0x61, 0x72, 0x20, 0x70,
+ 0x75, 0x73, 0x68, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x20, 0x20, 0x3d, 0x20, 0x41, 0x72, 0x72, 0x61, 0x79, 0x50,
+ 0x72, 0x6f, 0x74, 0x6f, 0x2e, 0x70, 0x75, 0x73, 0x68, 0x2c, 0x0a, 0x20,
+ 0x20, 0x20, 0x20, 0x20, 0x20, 0x73, 0x6c, 0x69, 0x63, 0x65, 0x20, 0x20,
+ 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x3d, 0x20,
+ 0x41, 0x72, 0x72, 0x61, 0x79, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x2e, 0x73,
+ 0x6c, 0x69, 0x63, 0x65, 0x2c, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x63, 0x6f, 0x6e, 0x63, 0x61, 0x74, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x20, 0x20, 0x20, 0x3d, 0x20, 0x41, 0x72, 0x72, 0x61, 0x79,
+ 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x2e, 0x63, 0x6f, 0x6e, 0x63, 0x61, 0x74,
+ 0x2c, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x74, 0x6f, 0x53, 0x74,
+ 0x72, 0x69, 0x6e, 0x67, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x3d, 0x20, 0x4f, 0x62, 0x6a, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x2e,
+ 0x74, 0x6f, 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x2c, 0x0a, 0x20, 0x20,
+ 0x20, 0x20, 0x20, 0x20, 0x68, 0x61, 0x73, 0x4f, 0x77, 0x6e, 0x50, 0x72,
+ 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x20, 0x20, 0x3d, 0x20, 0x4f,
+ 0x62, 0x6a, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x2e, 0x68, 0x61, 0x73, 0x4f,
+ 0x77, 0x6e, 0x50, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x3b, 0x0a,
+ 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x41, 0x6c, 0x6c, 0x20, 0x2a, 0x2a,
+ 0x45, 0x43, 0x4d, 0x41, 0x53, 0x63, 0x72, 0x69, 0x70, 0x74, 0x20, 0x35,
+ 0x2a, 0x2a, 0x20, 0x6e, 0x61, 0x74, 0x69, 0x76, 0x65, 0x20, 0x66, 0x75,
+ 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x20, 0x69, 0x6d, 0x70, 0x6c, 0x65,
+ 0x6d, 0x65, 0x6e, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x20, 0x74,
+ 0x68, 0x61, 0x74, 0x20, 0x77, 0x65, 0x20, 0x68, 0x6f, 0x70, 0x65, 0x20,
+ 0x74, 0x6f, 0x20, 0x75, 0x73, 0x65, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20,
+ 0x61, 0x72, 0x65, 0x20, 0x64, 0x65, 0x63, 0x6c, 0x61, 0x72, 0x65, 0x64,
+ 0x20, 0x68, 0x65, 0x72, 0x65, 0x2e, 0x0a, 0x20, 0x20, 0x76, 0x61, 0x72,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x6e, 0x61, 0x74, 0x69, 0x76, 0x65, 0x46,
+ 0x6f, 0x72, 0x45, 0x61, 0x63, 0x68, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x3d, 0x20, 0x41, 0x72, 0x72, 0x61, 0x79, 0x50, 0x72, 0x6f, 0x74, 0x6f,
+ 0x2e, 0x66, 0x6f, 0x72, 0x45, 0x61, 0x63, 0x68, 0x2c, 0x0a, 0x20, 0x20,
+ 0x20, 0x20, 0x6e, 0x61, 0x74, 0x69, 0x76, 0x65, 0x4d, 0x61, 0x70, 0x20,
+ 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x3d, 0x20, 0x41,
+ 0x72, 0x72, 0x61, 0x79, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x2e, 0x6d, 0x61,
+ 0x70, 0x2c, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x6e, 0x61, 0x74, 0x69, 0x76,
+ 0x65, 0x52, 0x65, 0x64, 0x75, 0x63, 0x65, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x3d, 0x20, 0x41, 0x72, 0x72, 0x61, 0x79, 0x50, 0x72, 0x6f,
+ 0x74, 0x6f, 0x2e, 0x72, 0x65, 0x64, 0x75, 0x63, 0x65, 0x2c, 0x0a, 0x20,
+ 0x20, 0x20, 0x20, 0x6e, 0x61, 0x74, 0x69, 0x76, 0x65, 0x52, 0x65, 0x64,
+ 0x75, 0x63, 0x65, 0x52, 0x69, 0x67, 0x68, 0x74, 0x20, 0x20, 0x3d, 0x20,
+ 0x41, 0x72, 0x72, 0x61, 0x79, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x2e, 0x72,
+ 0x65, 0x64, 0x75, 0x63, 0x65, 0x52, 0x69, 0x67, 0x68, 0x74, 0x2c, 0x0a,
+ 0x20, 0x20, 0x20, 0x20, 0x6e, 0x61, 0x74, 0x69, 0x76, 0x65, 0x46, 0x69,
+ 0x6c, 0x74, 0x65, 0x72, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x3d,
+ 0x20, 0x41, 0x72, 0x72, 0x61, 0x79, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x2e,
+ 0x66, 0x69, 0x6c, 0x74, 0x65, 0x72, 0x2c, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x6e, 0x61, 0x74, 0x69, 0x76, 0x65, 0x45, 0x76, 0x65, 0x72, 0x79, 0x20,
+ 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x3d, 0x20, 0x41, 0x72, 0x72,
+ 0x61, 0x79, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x2e, 0x65, 0x76, 0x65, 0x72,
+ 0x79, 0x2c, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x6e, 0x61, 0x74, 0x69, 0x76,
+ 0x65, 0x53, 0x6f, 0x6d, 0x65, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x3d, 0x20, 0x41, 0x72, 0x72, 0x61, 0x79, 0x50, 0x72, 0x6f,
+ 0x74, 0x6f, 0x2e, 0x73, 0x6f, 0x6d, 0x65, 0x2c, 0x0a, 0x20, 0x20, 0x20,
+ 0x20, 0x6e, 0x61, 0x74, 0x69, 0x76, 0x65, 0x49, 0x6e, 0x64, 0x65, 0x78,
+ 0x4f, 0x66, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x3d, 0x20, 0x41, 0x72,
+ 0x72, 0x61, 0x79, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x2e, 0x69, 0x6e, 0x64,
+ 0x65, 0x78, 0x4f, 0x66, 0x2c, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x6e, 0x61,
+ 0x74, 0x69, 0x76, 0x65, 0x4c, 0x61, 0x73, 0x74, 0x49, 0x6e, 0x64, 0x65,
+ 0x78, 0x4f, 0x66, 0x20, 0x20, 0x3d, 0x20, 0x41, 0x72, 0x72, 0x61, 0x79,
+ 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x2e, 0x6c, 0x61, 0x73, 0x74, 0x49, 0x6e,
+ 0x64, 0x65, 0x78, 0x4f, 0x66, 0x2c, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x6e,
+ 0x61, 0x74, 0x69, 0x76, 0x65, 0x49, 0x73, 0x41, 0x72, 0x72, 0x61, 0x79,
+ 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x3d, 0x20, 0x41, 0x72, 0x72, 0x61,
+ 0x79, 0x2e, 0x69, 0x73, 0x41, 0x72, 0x72, 0x61, 0x79, 0x2c, 0x0a, 0x20,
+ 0x20, 0x20, 0x20, 0x6e, 0x61, 0x74, 0x69, 0x76, 0x65, 0x4b, 0x65, 0x79,
+ 0x73, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x3d, 0x20,
+ 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x2e, 0x6b, 0x65, 0x79, 0x73, 0x2c,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x6e, 0x61, 0x74, 0x69, 0x76, 0x65, 0x42,
+ 0x69, 0x6e, 0x64, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x3d, 0x20, 0x46, 0x75, 0x6e, 0x63, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x2e,
+ 0x62, 0x69, 0x6e, 0x64, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20,
+ 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x20, 0x61, 0x20, 0x73, 0x61, 0x66,
+ 0x65, 0x20, 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x20,
+ 0x74, 0x6f, 0x20, 0x74, 0x68, 0x65, 0x20, 0x55, 0x6e, 0x64, 0x65, 0x72,
+ 0x73, 0x63, 0x6f, 0x72, 0x65, 0x20, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74,
+ 0x20, 0x66, 0x6f, 0x72, 0x20, 0x75, 0x73, 0x65, 0x20, 0x62, 0x65, 0x6c,
+ 0x6f, 0x77, 0x2e, 0x0a, 0x20, 0x20, 0x76, 0x61, 0x72, 0x20, 0x5f, 0x20,
+ 0x3d, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x6f,
+ 0x62, 0x6a, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66,
+ 0x20, 0x28, 0x6f, 0x62, 0x6a, 0x20, 0x69, 0x6e, 0x73, 0x74, 0x61, 0x6e,
+ 0x63, 0x65, 0x6f, 0x66, 0x20, 0x5f, 0x29, 0x20, 0x72, 0x65, 0x74, 0x75,
+ 0x72, 0x6e, 0x20, 0x6f, 0x62, 0x6a, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x69, 0x66, 0x20, 0x28, 0x21, 0x28, 0x74, 0x68, 0x69, 0x73, 0x20, 0x69,
+ 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x6f, 0x66, 0x20, 0x5f, 0x29,
+ 0x29, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x6e, 0x65, 0x77,
+ 0x20, 0x5f, 0x28, 0x6f, 0x62, 0x6a, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20,
+ 0x20, 0x74, 0x68, 0x69, 0x73, 0x2e, 0x5f, 0x77, 0x72, 0x61, 0x70, 0x70,
+ 0x65, 0x64, 0x20, 0x3d, 0x20, 0x6f, 0x62, 0x6a, 0x3b, 0x0a, 0x20, 0x20,
+ 0x7d, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x45, 0x78, 0x70,
+ 0x6f, 0x72, 0x74, 0x20, 0x74, 0x68, 0x65, 0x20, 0x55, 0x6e, 0x64, 0x65,
+ 0x72, 0x73, 0x63, 0x6f, 0x72, 0x65, 0x20, 0x6f, 0x62, 0x6a, 0x65, 0x63,
+ 0x74, 0x20, 0x66, 0x6f, 0x72, 0x20, 0x2a, 0x2a, 0x4e, 0x6f, 0x64, 0x65,
+ 0x2e, 0x6a, 0x73, 0x2a, 0x2a, 0x2c, 0x20, 0x77, 0x69, 0x74, 0x68, 0x0a,
+ 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x62, 0x61, 0x63, 0x6b, 0x77, 0x61, 0x72,
+ 0x64, 0x73, 0x2d, 0x63, 0x6f, 0x6d, 0x70, 0x61, 0x74, 0x69, 0x62, 0x69,
+ 0x6c, 0x69, 0x74, 0x79, 0x20, 0x66, 0x6f, 0x72, 0x20, 0x74, 0x68, 0x65,
+ 0x20, 0x6f, 0x6c, 0x64, 0x20, 0x60, 0x72, 0x65, 0x71, 0x75, 0x69, 0x72,
+ 0x65, 0x28, 0x29, 0x60, 0x20, 0x41, 0x50, 0x49, 0x2e, 0x20, 0x49, 0x66,
+ 0x20, 0x77, 0x65, 0x27, 0x72, 0x65, 0x20, 0x69, 0x6e, 0x0a, 0x20, 0x20,
+ 0x2f, 0x2f, 0x20, 0x74, 0x68, 0x65, 0x20, 0x62, 0x72, 0x6f, 0x77, 0x73,
+ 0x65, 0x72, 0x2c, 0x20, 0x61, 0x64, 0x64, 0x20, 0x60, 0x5f, 0x60, 0x20,
+ 0x61, 0x73, 0x20, 0x61, 0x20, 0x67, 0x6c, 0x6f, 0x62, 0x61, 0x6c, 0x20,
+ 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, 0x76, 0x69, 0x61, 0x20, 0x61,
+ 0x20, 0x73, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x20, 0x69, 0x64, 0x65, 0x6e,
+ 0x74, 0x69, 0x66, 0x69, 0x65, 0x72, 0x2c, 0x0a, 0x20, 0x20, 0x2f, 0x2f,
+ 0x20, 0x66, 0x6f, 0x72, 0x20, 0x43, 0x6c, 0x6f, 0x73, 0x75, 0x72, 0x65,
+ 0x20, 0x43, 0x6f, 0x6d, 0x70, 0x69, 0x6c, 0x65, 0x72, 0x20, 0x22, 0x61,
+ 0x64, 0x76, 0x61, 0x6e, 0x63, 0x65, 0x64, 0x22, 0x20, 0x6d, 0x6f, 0x64,
+ 0x65, 0x2e, 0x0a, 0x20, 0x20, 0x69, 0x66, 0x20, 0x28, 0x74, 0x79, 0x70,
+ 0x65, 0x6f, 0x66, 0x20, 0x65, 0x78, 0x70, 0x6f, 0x72, 0x74, 0x73, 0x20,
+ 0x21, 0x3d, 0x3d, 0x20, 0x27, 0x75, 0x6e, 0x64, 0x65, 0x66, 0x69, 0x6e,
+ 0x65, 0x64, 0x27, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x69,
+ 0x66, 0x20, 0x28, 0x74, 0x79, 0x70, 0x65, 0x6f, 0x66, 0x20, 0x6d, 0x6f,
+ 0x64, 0x75, 0x6c, 0x65, 0x20, 0x21, 0x3d, 0x3d, 0x20, 0x27, 0x75, 0x6e,
+ 0x64, 0x65, 0x66, 0x69, 0x6e, 0x65, 0x64, 0x27, 0x20, 0x26, 0x26, 0x20,
+ 0x6d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x2e, 0x65, 0x78, 0x70, 0x6f, 0x72,
+ 0x74, 0x73, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x65, 0x78, 0x70, 0x6f, 0x72, 0x74, 0x73, 0x20, 0x3d, 0x20, 0x6d, 0x6f,
+ 0x64, 0x75, 0x6c, 0x65, 0x2e, 0x65, 0x78, 0x70, 0x6f, 0x72, 0x74, 0x73,
+ 0x20, 0x3d, 0x20, 0x5f, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x0a,
+ 0x20, 0x20, 0x20, 0x20, 0x65, 0x78, 0x70, 0x6f, 0x72, 0x74, 0x73, 0x2e,
+ 0x5f, 0x20, 0x3d, 0x20, 0x5f, 0x3b, 0x0a, 0x20, 0x20, 0x7d, 0x20, 0x65,
+ 0x6c, 0x73, 0x65, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x72, 0x6f,
+ 0x6f, 0x74, 0x2e, 0x5f, 0x20, 0x3d, 0x20, 0x5f, 0x3b, 0x0a, 0x20, 0x20,
+ 0x7d, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x43, 0x75, 0x72, 0x72,
+ 0x65, 0x6e, 0x74, 0x20, 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x2e,
+ 0x0a, 0x20, 0x20, 0x5f, 0x2e, 0x56, 0x45, 0x52, 0x53, 0x49, 0x4f, 0x4e,
+ 0x20, 0x3d, 0x20, 0x27, 0x31, 0x2e, 0x34, 0x2e, 0x34, 0x27, 0x3b, 0x0a,
+ 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x43, 0x6f, 0x6c, 0x6c, 0x65, 0x63,
+ 0x74, 0x69, 0x6f, 0x6e, 0x20, 0x46, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f,
+ 0x6e, 0x73, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x2d, 0x2d, 0x2d, 0x2d,
+ 0x2d, 0x2d, 0x2d, 0x2d, 0x2d, 0x2d, 0x2d, 0x2d, 0x2d, 0x2d, 0x2d, 0x2d,
+ 0x2d, 0x2d, 0x2d, 0x2d, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x54,
+ 0x68, 0x65, 0x20, 0x63, 0x6f, 0x72, 0x6e, 0x65, 0x72, 0x73, 0x74, 0x6f,
+ 0x6e, 0x65, 0x2c, 0x20, 0x61, 0x6e, 0x20, 0x60, 0x65, 0x61, 0x63, 0x68,
+ 0x60, 0x20, 0x69, 0x6d, 0x70, 0x6c, 0x65, 0x6d, 0x65, 0x6e, 0x74, 0x61,
+ 0x74, 0x69, 0x6f, 0x6e, 0x2c, 0x20, 0x61, 0x6b, 0x61, 0x20, 0x60, 0x66,
+ 0x6f, 0x72, 0x45, 0x61, 0x63, 0x68, 0x60, 0x2e, 0x0a, 0x20, 0x20, 0x2f,
+ 0x2f, 0x20, 0x48, 0x61, 0x6e, 0x64, 0x6c, 0x65, 0x73, 0x20, 0x6f, 0x62,
+ 0x6a, 0x65, 0x63, 0x74, 0x73, 0x20, 0x77, 0x69, 0x74, 0x68, 0x20, 0x74,
+ 0x68, 0x65, 0x20, 0x62, 0x75, 0x69, 0x6c, 0x74, 0x2d, 0x69, 0x6e, 0x20,
+ 0x60, 0x66, 0x6f, 0x72, 0x45, 0x61, 0x63, 0x68, 0x60, 0x2c, 0x20, 0x61,
+ 0x72, 0x72, 0x61, 0x79, 0x73, 0x2c, 0x20, 0x61, 0x6e, 0x64, 0x20, 0x72,
+ 0x61, 0x77, 0x20, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x73, 0x2e, 0x0a,
+ 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x44, 0x65, 0x6c, 0x65, 0x67, 0x61, 0x74,
+ 0x65, 0x73, 0x20, 0x74, 0x6f, 0x20, 0x2a, 0x2a, 0x45, 0x43, 0x4d, 0x41,
+ 0x53, 0x63, 0x72, 0x69, 0x70, 0x74, 0x20, 0x35, 0x2a, 0x2a, 0x27, 0x73,
+ 0x20, 0x6e, 0x61, 0x74, 0x69, 0x76, 0x65, 0x20, 0x60, 0x66, 0x6f, 0x72,
+ 0x45, 0x61, 0x63, 0x68, 0x60, 0x20, 0x69, 0x66, 0x20, 0x61, 0x76, 0x61,
+ 0x69, 0x6c, 0x61, 0x62, 0x6c, 0x65, 0x2e, 0x0a, 0x20, 0x20, 0x76, 0x61,
+ 0x72, 0x20, 0x65, 0x61, 0x63, 0x68, 0x20, 0x3d, 0x20, 0x5f, 0x2e, 0x65,
+ 0x61, 0x63, 0x68, 0x20, 0x3d, 0x20, 0x5f, 0x2e, 0x66, 0x6f, 0x72, 0x45,
+ 0x61, 0x63, 0x68, 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69,
+ 0x6f, 0x6e, 0x28, 0x6f, 0x62, 0x6a, 0x2c, 0x20, 0x69, 0x74, 0x65, 0x72,
+ 0x61, 0x74, 0x6f, 0x72, 0x2c, 0x20, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x78,
+ 0x74, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20,
+ 0x28, 0x6f, 0x62, 0x6a, 0x20, 0x3d, 0x3d, 0x20, 0x6e, 0x75, 0x6c, 0x6c,
+ 0x29, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x3b, 0x0a, 0x20, 0x20,
+ 0x20, 0x20, 0x69, 0x66, 0x20, 0x28, 0x6e, 0x61, 0x74, 0x69, 0x76, 0x65,
+ 0x46, 0x6f, 0x72, 0x45, 0x61, 0x63, 0x68, 0x20, 0x26, 0x26, 0x20, 0x6f,
+ 0x62, 0x6a, 0x2e, 0x66, 0x6f, 0x72, 0x45, 0x61, 0x63, 0x68, 0x20, 0x3d,
+ 0x3d, 0x3d, 0x20, 0x6e, 0x61, 0x74, 0x69, 0x76, 0x65, 0x46, 0x6f, 0x72,
+ 0x45, 0x61, 0x63, 0x68, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x6f, 0x62, 0x6a, 0x2e, 0x66, 0x6f, 0x72, 0x45, 0x61, 0x63,
+ 0x68, 0x28, 0x69, 0x74, 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x2c, 0x20,
+ 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x29, 0x3b, 0x0a, 0x20, 0x20,
+ 0x20, 0x20, 0x7d, 0x20, 0x65, 0x6c, 0x73, 0x65, 0x20, 0x69, 0x66, 0x20,
+ 0x28, 0x6f, 0x62, 0x6a, 0x2e, 0x6c, 0x65, 0x6e, 0x67, 0x74, 0x68, 0x20,
+ 0x3d, 0x3d, 0x3d, 0x20, 0x2b, 0x6f, 0x62, 0x6a, 0x2e, 0x6c, 0x65, 0x6e,
+ 0x67, 0x74, 0x68, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x66, 0x6f, 0x72, 0x20, 0x28, 0x76, 0x61, 0x72, 0x20, 0x69, 0x20,
+ 0x3d, 0x20, 0x30, 0x2c, 0x20, 0x6c, 0x20, 0x3d, 0x20, 0x6f, 0x62, 0x6a,
+ 0x2e, 0x6c, 0x65, 0x6e, 0x67, 0x74, 0x68, 0x3b, 0x20, 0x69, 0x20, 0x3c,
+ 0x20, 0x6c, 0x3b, 0x20, 0x69, 0x2b, 0x2b, 0x29, 0x20, 0x7b, 0x0a, 0x20,
+ 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20, 0x28, 0x69,
+ 0x74, 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x2e, 0x63, 0x61, 0x6c, 0x6c,
+ 0x28, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x2c, 0x20, 0x6f, 0x62,
+ 0x6a, 0x5b, 0x69, 0x5d, 0x2c, 0x20, 0x69, 0x2c, 0x20, 0x6f, 0x62, 0x6a,
+ 0x29, 0x20, 0x3d, 0x3d, 0x3d, 0x20, 0x62, 0x72, 0x65, 0x61, 0x6b, 0x65,
+ 0x72, 0x29, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x3b, 0x0a, 0x20,
+ 0x20, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x7d,
+ 0x20, 0x65, 0x6c, 0x73, 0x65, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x66, 0x6f, 0x72, 0x20, 0x28, 0x76, 0x61, 0x72, 0x20, 0x6b,
+ 0x65, 0x79, 0x20, 0x69, 0x6e, 0x20, 0x6f, 0x62, 0x6a, 0x29, 0x20, 0x7b,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20,
+ 0x28, 0x5f, 0x2e, 0x68, 0x61, 0x73, 0x28, 0x6f, 0x62, 0x6a, 0x2c, 0x20,
+ 0x6b, 0x65, 0x79, 0x29, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20, 0x28, 0x69, 0x74,
+ 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x2e, 0x63, 0x61, 0x6c, 0x6c, 0x28,
+ 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x2c, 0x20, 0x6f, 0x62, 0x6a,
+ 0x5b, 0x6b, 0x65, 0x79, 0x5d, 0x2c, 0x20, 0x6b, 0x65, 0x79, 0x2c, 0x20,
+ 0x6f, 0x62, 0x6a, 0x29, 0x20, 0x3d, 0x3d, 0x3d, 0x20, 0x62, 0x72, 0x65,
+ 0x61, 0x6b, 0x65, 0x72, 0x29, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e,
+ 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x0a,
+ 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x7d, 0x0a, 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f,
+ 0x20, 0x52, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x74, 0x68, 0x65, 0x20,
+ 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x73, 0x20, 0x6f, 0x66, 0x20, 0x61,
+ 0x70, 0x70, 0x6c, 0x79, 0x69, 0x6e, 0x67, 0x20, 0x74, 0x68, 0x65, 0x20,
+ 0x69, 0x74, 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x20, 0x74, 0x6f, 0x20,
+ 0x65, 0x61, 0x63, 0x68, 0x20, 0x65, 0x6c, 0x65, 0x6d, 0x65, 0x6e, 0x74,
+ 0x2e, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x44, 0x65, 0x6c, 0x65, 0x67,
+ 0x61, 0x74, 0x65, 0x73, 0x20, 0x74, 0x6f, 0x20, 0x2a, 0x2a, 0x45, 0x43,
+ 0x4d, 0x41, 0x53, 0x63, 0x72, 0x69, 0x70, 0x74, 0x20, 0x35, 0x2a, 0x2a,
+ 0x27, 0x73, 0x20, 0x6e, 0x61, 0x74, 0x69, 0x76, 0x65, 0x20, 0x60, 0x6d,
+ 0x61, 0x70, 0x60, 0x20, 0x69, 0x66, 0x20, 0x61, 0x76, 0x61, 0x69, 0x6c,
+ 0x61, 0x62, 0x6c, 0x65, 0x2e, 0x0a, 0x20, 0x20, 0x5f, 0x2e, 0x6d, 0x61,
+ 0x70, 0x20, 0x3d, 0x20, 0x5f, 0x2e, 0x63, 0x6f, 0x6c, 0x6c, 0x65, 0x63,
+ 0x74, 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e,
+ 0x28, 0x6f, 0x62, 0x6a, 0x2c, 0x20, 0x69, 0x74, 0x65, 0x72, 0x61, 0x74,
+ 0x6f, 0x72, 0x2c, 0x20, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x29,
+ 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x76, 0x61, 0x72, 0x20, 0x72,
+ 0x65, 0x73, 0x75, 0x6c, 0x74, 0x73, 0x20, 0x3d, 0x20, 0x5b, 0x5d, 0x3b,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20, 0x28, 0x6f, 0x62, 0x6a,
+ 0x20, 0x3d, 0x3d, 0x20, 0x6e, 0x75, 0x6c, 0x6c, 0x29, 0x20, 0x72, 0x65,
+ 0x74, 0x75, 0x72, 0x6e, 0x20, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x73,
+ 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20, 0x28, 0x6e, 0x61,
+ 0x74, 0x69, 0x76, 0x65, 0x4d, 0x61, 0x70, 0x20, 0x26, 0x26, 0x20, 0x6f,
+ 0x62, 0x6a, 0x2e, 0x6d, 0x61, 0x70, 0x20, 0x3d, 0x3d, 0x3d, 0x20, 0x6e,
+ 0x61, 0x74, 0x69, 0x76, 0x65, 0x4d, 0x61, 0x70, 0x29, 0x20, 0x72, 0x65,
+ 0x74, 0x75, 0x72, 0x6e, 0x20, 0x6f, 0x62, 0x6a, 0x2e, 0x6d, 0x61, 0x70,
+ 0x28, 0x69, 0x74, 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x2c, 0x20, 0x63,
+ 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20,
+ 0x20, 0x65, 0x61, 0x63, 0x68, 0x28, 0x6f, 0x62, 0x6a, 0x2c, 0x20, 0x66,
+ 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x76, 0x61, 0x6c, 0x75,
+ 0x65, 0x2c, 0x20, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x2c, 0x20, 0x6c, 0x69,
+ 0x73, 0x74, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x73, 0x5b, 0x72, 0x65, 0x73, 0x75,
+ 0x6c, 0x74, 0x73, 0x2e, 0x6c, 0x65, 0x6e, 0x67, 0x74, 0x68, 0x5d, 0x20,
+ 0x3d, 0x20, 0x69, 0x74, 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x2e, 0x63,
+ 0x61, 0x6c, 0x6c, 0x28, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x2c,
+ 0x20, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x2c, 0x20, 0x69, 0x6e, 0x64, 0x65,
+ 0x78, 0x2c, 0x20, 0x6c, 0x69, 0x73, 0x74, 0x29, 0x3b, 0x0a, 0x20, 0x20,
+ 0x20, 0x20, 0x7d, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65,
+ 0x74, 0x75, 0x72, 0x6e, 0x20, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x73,
+ 0x3b, 0x0a, 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x76, 0x61,
+ 0x72, 0x20, 0x72, 0x65, 0x64, 0x75, 0x63, 0x65, 0x45, 0x72, 0x72, 0x6f,
+ 0x72, 0x20, 0x3d, 0x20, 0x27, 0x52, 0x65, 0x64, 0x75, 0x63, 0x65, 0x20,
+ 0x6f, 0x66, 0x20, 0x65, 0x6d, 0x70, 0x74, 0x79, 0x20, 0x61, 0x72, 0x72,
+ 0x61, 0x79, 0x20, 0x77, 0x69, 0x74, 0x68, 0x20, 0x6e, 0x6f, 0x20, 0x69,
+ 0x6e, 0x69, 0x74, 0x69, 0x61, 0x6c, 0x20, 0x76, 0x61, 0x6c, 0x75, 0x65,
+ 0x27, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x2a, 0x2a, 0x52,
+ 0x65, 0x64, 0x75, 0x63, 0x65, 0x2a, 0x2a, 0x20, 0x62, 0x75, 0x69, 0x6c,
+ 0x64, 0x73, 0x20, 0x75, 0x70, 0x20, 0x61, 0x20, 0x73, 0x69, 0x6e, 0x67,
+ 0x6c, 0x65, 0x20, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x20, 0x66, 0x72,
+ 0x6f, 0x6d, 0x20, 0x61, 0x20, 0x6c, 0x69, 0x73, 0x74, 0x20, 0x6f, 0x66,
+ 0x20, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x73, 0x2c, 0x20, 0x61, 0x6b, 0x61,
+ 0x20, 0x60, 0x69, 0x6e, 0x6a, 0x65, 0x63, 0x74, 0x60, 0x2c, 0x0a, 0x20,
+ 0x20, 0x2f, 0x2f, 0x20, 0x6f, 0x72, 0x20, 0x60, 0x66, 0x6f, 0x6c, 0x64,
+ 0x6c, 0x60, 0x2e, 0x20, 0x44, 0x65, 0x6c, 0x65, 0x67, 0x61, 0x74, 0x65,
+ 0x73, 0x20, 0x74, 0x6f, 0x20, 0x2a, 0x2a, 0x45, 0x43, 0x4d, 0x41, 0x53,
+ 0x63, 0x72, 0x69, 0x70, 0x74, 0x20, 0x35, 0x2a, 0x2a, 0x27, 0x73, 0x20,
+ 0x6e, 0x61, 0x74, 0x69, 0x76, 0x65, 0x20, 0x60, 0x72, 0x65, 0x64, 0x75,
+ 0x63, 0x65, 0x60, 0x20, 0x69, 0x66, 0x20, 0x61, 0x76, 0x61, 0x69, 0x6c,
+ 0x61, 0x62, 0x6c, 0x65, 0x2e, 0x0a, 0x20, 0x20, 0x5f, 0x2e, 0x72, 0x65,
+ 0x64, 0x75, 0x63, 0x65, 0x20, 0x3d, 0x20, 0x5f, 0x2e, 0x66, 0x6f, 0x6c,
+ 0x64, 0x6c, 0x20, 0x3d, 0x20, 0x5f, 0x2e, 0x69, 0x6e, 0x6a, 0x65, 0x63,
+ 0x74, 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e,
+ 0x28, 0x6f, 0x62, 0x6a, 0x2c, 0x20, 0x69, 0x74, 0x65, 0x72, 0x61, 0x74,
+ 0x6f, 0x72, 0x2c, 0x20, 0x6d, 0x65, 0x6d, 0x6f, 0x2c, 0x20, 0x63, 0x6f,
+ 0x6e, 0x74, 0x65, 0x78, 0x74, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20,
+ 0x20, 0x76, 0x61, 0x72, 0x20, 0x69, 0x6e, 0x69, 0x74, 0x69, 0x61, 0x6c,
+ 0x20, 0x3d, 0x20, 0x61, 0x72, 0x67, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x73,
+ 0x2e, 0x6c, 0x65, 0x6e, 0x67, 0x74, 0x68, 0x20, 0x3e, 0x20, 0x32, 0x3b,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20, 0x28, 0x6f, 0x62, 0x6a,
+ 0x20, 0x3d, 0x3d, 0x20, 0x6e, 0x75, 0x6c, 0x6c, 0x29, 0x20, 0x6f, 0x62,
+ 0x6a, 0x20, 0x3d, 0x20, 0x5b, 0x5d, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x69, 0x66, 0x20, 0x28, 0x6e, 0x61, 0x74, 0x69, 0x76, 0x65, 0x52, 0x65,
+ 0x64, 0x75, 0x63, 0x65, 0x20, 0x26, 0x26, 0x20, 0x6f, 0x62, 0x6a, 0x2e,
+ 0x72, 0x65, 0x64, 0x75, 0x63, 0x65, 0x20, 0x3d, 0x3d, 0x3d, 0x20, 0x6e,
+ 0x61, 0x74, 0x69, 0x76, 0x65, 0x52, 0x65, 0x64, 0x75, 0x63, 0x65, 0x29,
+ 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20,
+ 0x28, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x29, 0x20, 0x69, 0x74,
+ 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x20, 0x3d, 0x20, 0x5f, 0x2e, 0x62,
+ 0x69, 0x6e, 0x64, 0x28, 0x69, 0x74, 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72,
+ 0x2c, 0x20, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x29, 0x3b, 0x0a,
+ 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e,
+ 0x20, 0x69, 0x6e, 0x69, 0x74, 0x69, 0x61, 0x6c, 0x20, 0x3f, 0x20, 0x6f,
+ 0x62, 0x6a, 0x2e, 0x72, 0x65, 0x64, 0x75, 0x63, 0x65, 0x28, 0x69, 0x74,
+ 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x2c, 0x20, 0x6d, 0x65, 0x6d, 0x6f,
+ 0x29, 0x20, 0x3a, 0x20, 0x6f, 0x62, 0x6a, 0x2e, 0x72, 0x65, 0x64, 0x75,
+ 0x63, 0x65, 0x28, 0x69, 0x74, 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x29,
+ 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x65, 0x61, 0x63, 0x68, 0x28, 0x6f, 0x62, 0x6a, 0x2c, 0x20, 0x66, 0x75,
+ 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x76, 0x61, 0x6c, 0x75, 0x65,
+ 0x2c, 0x20, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x2c, 0x20, 0x6c, 0x69, 0x73,
+ 0x74, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x69,
+ 0x66, 0x20, 0x28, 0x21, 0x69, 0x6e, 0x69, 0x74, 0x69, 0x61, 0x6c, 0x29,
+ 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x6d,
+ 0x65, 0x6d, 0x6f, 0x20, 0x3d, 0x20, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3b,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x69, 0x6e, 0x69,
+ 0x74, 0x69, 0x61, 0x6c, 0x20, 0x3d, 0x20, 0x74, 0x72, 0x75, 0x65, 0x3b,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x20, 0x65, 0x6c, 0x73,
+ 0x65, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x6d, 0x65, 0x6d, 0x6f, 0x20, 0x3d, 0x20, 0x69, 0x74, 0x65, 0x72, 0x61,
+ 0x74, 0x6f, 0x72, 0x2e, 0x63, 0x61, 0x6c, 0x6c, 0x28, 0x63, 0x6f, 0x6e,
+ 0x74, 0x65, 0x78, 0x74, 0x2c, 0x20, 0x6d, 0x65, 0x6d, 0x6f, 0x2c, 0x20,
+ 0x76, 0x61, 0x6c, 0x75, 0x65, 0x2c, 0x20, 0x69, 0x6e, 0x64, 0x65, 0x78,
+ 0x2c, 0x20, 0x6c, 0x69, 0x73, 0x74, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x20, 0x7d, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x29, 0x3b,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20, 0x28, 0x21, 0x69, 0x6e,
+ 0x69, 0x74, 0x69, 0x61, 0x6c, 0x29, 0x20, 0x74, 0x68, 0x72, 0x6f, 0x77,
+ 0x20, 0x6e, 0x65, 0x77, 0x20, 0x54, 0x79, 0x70, 0x65, 0x45, 0x72, 0x72,
+ 0x6f, 0x72, 0x28, 0x72, 0x65, 0x64, 0x75, 0x63, 0x65, 0x45, 0x72, 0x72,
+ 0x6f, 0x72, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74,
+ 0x75, 0x72, 0x6e, 0x20, 0x6d, 0x65, 0x6d, 0x6f, 0x3b, 0x0a, 0x20, 0x20,
+ 0x7d, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x54, 0x68, 0x65,
+ 0x20, 0x72, 0x69, 0x67, 0x68, 0x74, 0x2d, 0x61, 0x73, 0x73, 0x6f, 0x63,
+ 0x69, 0x61, 0x74, 0x69, 0x76, 0x65, 0x20, 0x76, 0x65, 0x72, 0x73, 0x69,
+ 0x6f, 0x6e, 0x20, 0x6f, 0x66, 0x20, 0x72, 0x65, 0x64, 0x75, 0x63, 0x65,
+ 0x2c, 0x20, 0x61, 0x6c, 0x73, 0x6f, 0x20, 0x6b, 0x6e, 0x6f, 0x77, 0x6e,
+ 0x20, 0x61, 0x73, 0x20, 0x60, 0x66, 0x6f, 0x6c, 0x64, 0x72, 0x60, 0x2e,
+ 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x44, 0x65, 0x6c, 0x65, 0x67, 0x61,
+ 0x74, 0x65, 0x73, 0x20, 0x74, 0x6f, 0x20, 0x2a, 0x2a, 0x45, 0x43, 0x4d,
+ 0x41, 0x53, 0x63, 0x72, 0x69, 0x70, 0x74, 0x20, 0x35, 0x2a, 0x2a, 0x27,
+ 0x73, 0x20, 0x6e, 0x61, 0x74, 0x69, 0x76, 0x65, 0x20, 0x60, 0x72, 0x65,
+ 0x64, 0x75, 0x63, 0x65, 0x52, 0x69, 0x67, 0x68, 0x74, 0x60, 0x20, 0x69,
+ 0x66, 0x20, 0x61, 0x76, 0x61, 0x69, 0x6c, 0x61, 0x62, 0x6c, 0x65, 0x2e,
+ 0x0a, 0x20, 0x20, 0x5f, 0x2e, 0x72, 0x65, 0x64, 0x75, 0x63, 0x65, 0x52,
+ 0x69, 0x67, 0x68, 0x74, 0x20, 0x3d, 0x20, 0x5f, 0x2e, 0x66, 0x6f, 0x6c,
+ 0x64, 0x72, 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f,
+ 0x6e, 0x28, 0x6f, 0x62, 0x6a, 0x2c, 0x20, 0x69, 0x74, 0x65, 0x72, 0x61,
+ 0x74, 0x6f, 0x72, 0x2c, 0x20, 0x6d, 0x65, 0x6d, 0x6f, 0x2c, 0x20, 0x63,
+ 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20,
+ 0x20, 0x20, 0x76, 0x61, 0x72, 0x20, 0x69, 0x6e, 0x69, 0x74, 0x69, 0x61,
+ 0x6c, 0x20, 0x3d, 0x20, 0x61, 0x72, 0x67, 0x75, 0x6d, 0x65, 0x6e, 0x74,
+ 0x73, 0x2e, 0x6c, 0x65, 0x6e, 0x67, 0x74, 0x68, 0x20, 0x3e, 0x20, 0x32,
+ 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20, 0x28, 0x6f, 0x62,
+ 0x6a, 0x20, 0x3d, 0x3d, 0x20, 0x6e, 0x75, 0x6c, 0x6c, 0x29, 0x20, 0x6f,
+ 0x62, 0x6a, 0x20, 0x3d, 0x20, 0x5b, 0x5d, 0x3b, 0x0a, 0x20, 0x20, 0x20,
+ 0x20, 0x69, 0x66, 0x20, 0x28, 0x6e, 0x61, 0x74, 0x69, 0x76, 0x65, 0x52,
+ 0x65, 0x64, 0x75, 0x63, 0x65, 0x52, 0x69, 0x67, 0x68, 0x74, 0x20, 0x26,
+ 0x26, 0x20, 0x6f, 0x62, 0x6a, 0x2e, 0x72, 0x65, 0x64, 0x75, 0x63, 0x65,
+ 0x52, 0x69, 0x67, 0x68, 0x74, 0x20, 0x3d, 0x3d, 0x3d, 0x20, 0x6e, 0x61,
+ 0x74, 0x69, 0x76, 0x65, 0x52, 0x65, 0x64, 0x75, 0x63, 0x65, 0x52, 0x69,
+ 0x67, 0x68, 0x74, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x69, 0x66, 0x20, 0x28, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74,
+ 0x29, 0x20, 0x69, 0x74, 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x20, 0x3d,
+ 0x20, 0x5f, 0x2e, 0x62, 0x69, 0x6e, 0x64, 0x28, 0x69, 0x74, 0x65, 0x72,
+ 0x61, 0x74, 0x6f, 0x72, 0x2c, 0x20, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x78,
+ 0x74, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65,
+ 0x74, 0x75, 0x72, 0x6e, 0x20, 0x69, 0x6e, 0x69, 0x74, 0x69, 0x61, 0x6c,
+ 0x20, 0x3f, 0x20, 0x6f, 0x62, 0x6a, 0x2e, 0x72, 0x65, 0x64, 0x75, 0x63,
+ 0x65, 0x52, 0x69, 0x67, 0x68, 0x74, 0x28, 0x69, 0x74, 0x65, 0x72, 0x61,
+ 0x74, 0x6f, 0x72, 0x2c, 0x20, 0x6d, 0x65, 0x6d, 0x6f, 0x29, 0x20, 0x3a,
+ 0x20, 0x6f, 0x62, 0x6a, 0x2e, 0x72, 0x65, 0x64, 0x75, 0x63, 0x65, 0x52,
+ 0x69, 0x67, 0x68, 0x74, 0x28, 0x69, 0x74, 0x65, 0x72, 0x61, 0x74, 0x6f,
+ 0x72, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x0a, 0x20, 0x20,
+ 0x20, 0x20, 0x76, 0x61, 0x72, 0x20, 0x6c, 0x65, 0x6e, 0x67, 0x74, 0x68,
+ 0x20, 0x3d, 0x20, 0x6f, 0x62, 0x6a, 0x2e, 0x6c, 0x65, 0x6e, 0x67, 0x74,
+ 0x68, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20, 0x28, 0x6c,
+ 0x65, 0x6e, 0x67, 0x74, 0x68, 0x20, 0x21, 0x3d, 0x3d, 0x20, 0x2b, 0x6c,
+ 0x65, 0x6e, 0x67, 0x74, 0x68, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x20, 0x76, 0x61, 0x72, 0x20, 0x6b, 0x65, 0x79, 0x73, 0x20,
+ 0x3d, 0x20, 0x5f, 0x2e, 0x6b, 0x65, 0x79, 0x73, 0x28, 0x6f, 0x62, 0x6a,
+ 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x6c, 0x65, 0x6e,
+ 0x67, 0x74, 0x68, 0x20, 0x3d, 0x20, 0x6b, 0x65, 0x79, 0x73, 0x2e, 0x6c,
+ 0x65, 0x6e, 0x67, 0x74, 0x68, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x7d,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x65, 0x61, 0x63, 0x68, 0x28, 0x6f, 0x62,
+ 0x6a, 0x2c, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28,
+ 0x76, 0x61, 0x6c, 0x75, 0x65, 0x2c, 0x20, 0x69, 0x6e, 0x64, 0x65, 0x78,
+ 0x2c, 0x20, 0x6c, 0x69, 0x73, 0x74, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20,
+ 0x20, 0x20, 0x20, 0x20, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x20, 0x3d, 0x20,
+ 0x6b, 0x65, 0x79, 0x73, 0x20, 0x3f, 0x20, 0x6b, 0x65, 0x79, 0x73, 0x5b,
+ 0x2d, 0x2d, 0x6c, 0x65, 0x6e, 0x67, 0x74, 0x68, 0x5d, 0x20, 0x3a, 0x20,
+ 0x2d, 0x2d, 0x6c, 0x65, 0x6e, 0x67, 0x74, 0x68, 0x3b, 0x0a, 0x20, 0x20,
+ 0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20, 0x28, 0x21, 0x69, 0x6e, 0x69,
+ 0x74, 0x69, 0x61, 0x6c, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x20, 0x20, 0x6d, 0x65, 0x6d, 0x6f, 0x20, 0x3d, 0x20, 0x6f,
+ 0x62, 0x6a, 0x5b, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x5d, 0x3b, 0x0a, 0x20,
+ 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x69, 0x6e, 0x69, 0x74, 0x69,
+ 0x61, 0x6c, 0x20, 0x3d, 0x20, 0x74, 0x72, 0x75, 0x65, 0x3b, 0x0a, 0x20,
+ 0x20, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x20, 0x65, 0x6c, 0x73, 0x65, 0x20,
+ 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x6d, 0x65,
+ 0x6d, 0x6f, 0x20, 0x3d, 0x20, 0x69, 0x74, 0x65, 0x72, 0x61, 0x74, 0x6f,
+ 0x72, 0x2e, 0x63, 0x61, 0x6c, 0x6c, 0x28, 0x63, 0x6f, 0x6e, 0x74, 0x65,
+ 0x78, 0x74, 0x2c, 0x20, 0x6d, 0x65, 0x6d, 0x6f, 0x2c, 0x20, 0x6f, 0x62,
+ 0x6a, 0x5b, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x5d, 0x2c, 0x20, 0x69, 0x6e,
+ 0x64, 0x65, 0x78, 0x2c, 0x20, 0x6c, 0x69, 0x73, 0x74, 0x29, 0x3b, 0x0a,
+ 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x7d, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20, 0x28,
+ 0x21, 0x69, 0x6e, 0x69, 0x74, 0x69, 0x61, 0x6c, 0x29, 0x20, 0x74, 0x68,
+ 0x72, 0x6f, 0x77, 0x20, 0x6e, 0x65, 0x77, 0x20, 0x54, 0x79, 0x70, 0x65,
+ 0x45, 0x72, 0x72, 0x6f, 0x72, 0x28, 0x72, 0x65, 0x64, 0x75, 0x63, 0x65,
+ 0x45, 0x72, 0x72, 0x6f, 0x72, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x6d, 0x65, 0x6d, 0x6f, 0x3b,
+ 0x0a, 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20,
+ 0x52, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x74, 0x68, 0x65, 0x20, 0x66,
+ 0x69, 0x72, 0x73, 0x74, 0x20, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x20, 0x77,
+ 0x68, 0x69, 0x63, 0x68, 0x20, 0x70, 0x61, 0x73, 0x73, 0x65, 0x73, 0x20,
+ 0x61, 0x20, 0x74, 0x72, 0x75, 0x74, 0x68, 0x20, 0x74, 0x65, 0x73, 0x74,
+ 0x2e, 0x20, 0x41, 0x6c, 0x69, 0x61, 0x73, 0x65, 0x64, 0x20, 0x61, 0x73,
+ 0x20, 0x60, 0x64, 0x65, 0x74, 0x65, 0x63, 0x74, 0x60, 0x2e, 0x0a, 0x20,
+ 0x20, 0x5f, 0x2e, 0x66, 0x69, 0x6e, 0x64, 0x20, 0x3d, 0x20, 0x5f, 0x2e,
+ 0x64, 0x65, 0x74, 0x65, 0x63, 0x74, 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e,
+ 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x6f, 0x62, 0x6a, 0x2c, 0x20, 0x69,
+ 0x74, 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x2c, 0x20, 0x63, 0x6f, 0x6e,
+ 0x74, 0x65, 0x78, 0x74, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x76, 0x61, 0x72, 0x20, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x3b, 0x0a,
+ 0x20, 0x20, 0x20, 0x20, 0x61, 0x6e, 0x79, 0x28, 0x6f, 0x62, 0x6a, 0x2c,
+ 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x76, 0x61,
+ 0x6c, 0x75, 0x65, 0x2c, 0x20, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x2c, 0x20,
+ 0x6c, 0x69, 0x73, 0x74, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x69, 0x66, 0x20, 0x28, 0x69, 0x74, 0x65, 0x72, 0x61, 0x74,
+ 0x6f, 0x72, 0x2e, 0x63, 0x61, 0x6c, 0x6c, 0x28, 0x63, 0x6f, 0x6e, 0x74,
+ 0x65, 0x78, 0x74, 0x2c, 0x20, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x2c, 0x20,
+ 0x69, 0x6e, 0x64, 0x65, 0x78, 0x2c, 0x20, 0x6c, 0x69, 0x73, 0x74, 0x29,
+ 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x20, 0x3d, 0x20, 0x76, 0x61, 0x6c,
+ 0x75, 0x65, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x74, 0x72, 0x75, 0x65, 0x3b,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x0a, 0x20, 0x20, 0x20,
+ 0x20, 0x7d, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74,
+ 0x75, 0x72, 0x6e, 0x20, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x3b, 0x0a,
+ 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x52,
+ 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x61, 0x6c, 0x6c, 0x20, 0x74, 0x68,
+ 0x65, 0x20, 0x65, 0x6c, 0x65, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x20, 0x74,
+ 0x68, 0x61, 0x74, 0x20, 0x70, 0x61, 0x73, 0x73, 0x20, 0x61, 0x20, 0x74,
+ 0x72, 0x75, 0x74, 0x68, 0x20, 0x74, 0x65, 0x73, 0x74, 0x2e, 0x0a, 0x20,
+ 0x20, 0x2f, 0x2f, 0x20, 0x44, 0x65, 0x6c, 0x65, 0x67, 0x61, 0x74, 0x65,
+ 0x73, 0x20, 0x74, 0x6f, 0x20, 0x2a, 0x2a, 0x45, 0x43, 0x4d, 0x41, 0x53,
+ 0x63, 0x72, 0x69, 0x70, 0x74, 0x20, 0x35, 0x2a, 0x2a, 0x27, 0x73, 0x20,
+ 0x6e, 0x61, 0x74, 0x69, 0x76, 0x65, 0x20, 0x60, 0x66, 0x69, 0x6c, 0x74,
+ 0x65, 0x72, 0x60, 0x20, 0x69, 0x66, 0x20, 0x61, 0x76, 0x61, 0x69, 0x6c,
+ 0x61, 0x62, 0x6c, 0x65, 0x2e, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x41,
+ 0x6c, 0x69, 0x61, 0x73, 0x65, 0x64, 0x20, 0x61, 0x73, 0x20, 0x60, 0x73,
+ 0x65, 0x6c, 0x65, 0x63, 0x74, 0x60, 0x2e, 0x0a, 0x20, 0x20, 0x5f, 0x2e,
+ 0x66, 0x69, 0x6c, 0x74, 0x65, 0x72, 0x20, 0x3d, 0x20, 0x5f, 0x2e, 0x73,
+ 0x65, 0x6c, 0x65, 0x63, 0x74, 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e, 0x63,
+ 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x6f, 0x62, 0x6a, 0x2c, 0x20, 0x69, 0x74,
+ 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x2c, 0x20, 0x63, 0x6f, 0x6e, 0x74,
+ 0x65, 0x78, 0x74, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x76,
+ 0x61, 0x72, 0x20, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x73, 0x20, 0x3d,
+ 0x20, 0x5b, 0x5d, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20,
+ 0x28, 0x6f, 0x62, 0x6a, 0x20, 0x3d, 0x3d, 0x20, 0x6e, 0x75, 0x6c, 0x6c,
+ 0x29, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x72, 0x65, 0x73,
+ 0x75, 0x6c, 0x74, 0x73, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66,
+ 0x20, 0x28, 0x6e, 0x61, 0x74, 0x69, 0x76, 0x65, 0x46, 0x69, 0x6c, 0x74,
+ 0x65, 0x72, 0x20, 0x26, 0x26, 0x20, 0x6f, 0x62, 0x6a, 0x2e, 0x66, 0x69,
+ 0x6c, 0x74, 0x65, 0x72, 0x20, 0x3d, 0x3d, 0x3d, 0x20, 0x6e, 0x61, 0x74,
+ 0x69, 0x76, 0x65, 0x46, 0x69, 0x6c, 0x74, 0x65, 0x72, 0x29, 0x20, 0x72,
+ 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x6f, 0x62, 0x6a, 0x2e, 0x66, 0x69,
+ 0x6c, 0x74, 0x65, 0x72, 0x28, 0x69, 0x74, 0x65, 0x72, 0x61, 0x74, 0x6f,
+ 0x72, 0x2c, 0x20, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x29, 0x3b,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x65, 0x61, 0x63, 0x68, 0x28, 0x6f, 0x62,
+ 0x6a, 0x2c, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28,
+ 0x76, 0x61, 0x6c, 0x75, 0x65, 0x2c, 0x20, 0x69, 0x6e, 0x64, 0x65, 0x78,
+ 0x2c, 0x20, 0x6c, 0x69, 0x73, 0x74, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20,
+ 0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20, 0x28, 0x69, 0x74, 0x65, 0x72,
+ 0x61, 0x74, 0x6f, 0x72, 0x2e, 0x63, 0x61, 0x6c, 0x6c, 0x28, 0x63, 0x6f,
+ 0x6e, 0x74, 0x65, 0x78, 0x74, 0x2c, 0x20, 0x76, 0x61, 0x6c, 0x75, 0x65,
+ 0x2c, 0x20, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x2c, 0x20, 0x6c, 0x69, 0x73,
+ 0x74, 0x29, 0x29, 0x20, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x73, 0x5b,
+ 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x73, 0x2e, 0x6c, 0x65, 0x6e, 0x67,
+ 0x74, 0x68, 0x5d, 0x20, 0x3d, 0x20, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3b,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20,
+ 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x72, 0x65, 0x73, 0x75,
+ 0x6c, 0x74, 0x73, 0x3b, 0x0a, 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x0a, 0x20,
+ 0x20, 0x2f, 0x2f, 0x20, 0x52, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x61,
+ 0x6c, 0x6c, 0x20, 0x74, 0x68, 0x65, 0x20, 0x65, 0x6c, 0x65, 0x6d, 0x65,
+ 0x6e, 0x74, 0x73, 0x20, 0x66, 0x6f, 0x72, 0x20, 0x77, 0x68, 0x69, 0x63,
+ 0x68, 0x20, 0x61, 0x20, 0x74, 0x72, 0x75, 0x74, 0x68, 0x20, 0x74, 0x65,
+ 0x73, 0x74, 0x20, 0x66, 0x61, 0x69, 0x6c, 0x73, 0x2e, 0x0a, 0x20, 0x20,
+ 0x5f, 0x2e, 0x72, 0x65, 0x6a, 0x65, 0x63, 0x74, 0x20, 0x3d, 0x20, 0x66,
+ 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x6f, 0x62, 0x6a, 0x2c,
+ 0x20, 0x69, 0x74, 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x2c, 0x20, 0x63,
+ 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20,
+ 0x20, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x5f, 0x2e, 0x66,
+ 0x69, 0x6c, 0x74, 0x65, 0x72, 0x28, 0x6f, 0x62, 0x6a, 0x2c, 0x20, 0x66,
+ 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x76, 0x61, 0x6c, 0x75,
+ 0x65, 0x2c, 0x20, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x2c, 0x20, 0x6c, 0x69,
+ 0x73, 0x74, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x21, 0x69, 0x74, 0x65, 0x72,
+ 0x61, 0x74, 0x6f, 0x72, 0x2e, 0x63, 0x61, 0x6c, 0x6c, 0x28, 0x63, 0x6f,
+ 0x6e, 0x74, 0x65, 0x78, 0x74, 0x2c, 0x20, 0x76, 0x61, 0x6c, 0x75, 0x65,
+ 0x2c, 0x20, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x2c, 0x20, 0x6c, 0x69, 0x73,
+ 0x74, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x2c, 0x20, 0x63,
+ 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x7d,
+ 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x44, 0x65, 0x74, 0x65,
+ 0x72, 0x6d, 0x69, 0x6e, 0x65, 0x20, 0x77, 0x68, 0x65, 0x74, 0x68, 0x65,
+ 0x72, 0x20, 0x61, 0x6c, 0x6c, 0x20, 0x6f, 0x66, 0x20, 0x74, 0x68, 0x65,
+ 0x20, 0x65, 0x6c, 0x65, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x20, 0x6d, 0x61,
+ 0x74, 0x63, 0x68, 0x20, 0x61, 0x20, 0x74, 0x72, 0x75, 0x74, 0x68, 0x20,
+ 0x74, 0x65, 0x73, 0x74, 0x2e, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x44,
+ 0x65, 0x6c, 0x65, 0x67, 0x61, 0x74, 0x65, 0x73, 0x20, 0x74, 0x6f, 0x20,
+ 0x2a, 0x2a, 0x45, 0x43, 0x4d, 0x41, 0x53, 0x63, 0x72, 0x69, 0x70, 0x74,
+ 0x20, 0x35, 0x2a, 0x2a, 0x27, 0x73, 0x20, 0x6e, 0x61, 0x74, 0x69, 0x76,
+ 0x65, 0x20, 0x60, 0x65, 0x76, 0x65, 0x72, 0x79, 0x60, 0x20, 0x69, 0x66,
+ 0x20, 0x61, 0x76, 0x61, 0x69, 0x6c, 0x61, 0x62, 0x6c, 0x65, 0x2e, 0x0a,
+ 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x41, 0x6c, 0x69, 0x61, 0x73, 0x65, 0x64,
+ 0x20, 0x61, 0x73, 0x20, 0x60, 0x61, 0x6c, 0x6c, 0x60, 0x2e, 0x0a, 0x20,
+ 0x20, 0x5f, 0x2e, 0x65, 0x76, 0x65, 0x72, 0x79, 0x20, 0x3d, 0x20, 0x5f,
+ 0x2e, 0x61, 0x6c, 0x6c, 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74,
+ 0x69, 0x6f, 0x6e, 0x28, 0x6f, 0x62, 0x6a, 0x2c, 0x20, 0x69, 0x74, 0x65,
+ 0x72, 0x61, 0x74, 0x6f, 0x72, 0x2c, 0x20, 0x63, 0x6f, 0x6e, 0x74, 0x65,
+ 0x78, 0x74, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x69, 0x74,
+ 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x20, 0x7c, 0x7c, 0x20, 0x28, 0x69,
+ 0x74, 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x20, 0x3d, 0x20, 0x5f, 0x2e,
+ 0x69, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x74, 0x79, 0x29, 0x3b, 0x0a, 0x20,
+ 0x20, 0x20, 0x20, 0x76, 0x61, 0x72, 0x20, 0x72, 0x65, 0x73, 0x75, 0x6c,
+ 0x74, 0x20, 0x3d, 0x20, 0x74, 0x72, 0x75, 0x65, 0x3b, 0x0a, 0x20, 0x20,
+ 0x20, 0x20, 0x69, 0x66, 0x20, 0x28, 0x6f, 0x62, 0x6a, 0x20, 0x3d, 0x3d,
+ 0x20, 0x6e, 0x75, 0x6c, 0x6c, 0x29, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72,
+ 0x6e, 0x20, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x3b, 0x0a, 0x20, 0x20,
+ 0x20, 0x20, 0x69, 0x66, 0x20, 0x28, 0x6e, 0x61, 0x74, 0x69, 0x76, 0x65,
+ 0x45, 0x76, 0x65, 0x72, 0x79, 0x20, 0x26, 0x26, 0x20, 0x6f, 0x62, 0x6a,
+ 0x2e, 0x65, 0x76, 0x65, 0x72, 0x79, 0x20, 0x3d, 0x3d, 0x3d, 0x20, 0x6e,
+ 0x61, 0x74, 0x69, 0x76, 0x65, 0x45, 0x76, 0x65, 0x72, 0x79, 0x29, 0x20,
+ 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x6f, 0x62, 0x6a, 0x2e, 0x65,
+ 0x76, 0x65, 0x72, 0x79, 0x28, 0x69, 0x74, 0x65, 0x72, 0x61, 0x74, 0x6f,
+ 0x72, 0x2c, 0x20, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x29, 0x3b,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x65, 0x61, 0x63, 0x68, 0x28, 0x6f, 0x62,
+ 0x6a, 0x2c, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28,
+ 0x76, 0x61, 0x6c, 0x75, 0x65, 0x2c, 0x20, 0x69, 0x6e, 0x64, 0x65, 0x78,
+ 0x2c, 0x20, 0x6c, 0x69, 0x73, 0x74, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20,
+ 0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20, 0x28, 0x21, 0x28, 0x72, 0x65,
+ 0x73, 0x75, 0x6c, 0x74, 0x20, 0x3d, 0x20, 0x72, 0x65, 0x73, 0x75, 0x6c,
+ 0x74, 0x20, 0x26, 0x26, 0x20, 0x69, 0x74, 0x65, 0x72, 0x61, 0x74, 0x6f,
+ 0x72, 0x2e, 0x63, 0x61, 0x6c, 0x6c, 0x28, 0x63, 0x6f, 0x6e, 0x74, 0x65,
+ 0x78, 0x74, 0x2c, 0x20, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x2c, 0x20, 0x69,
+ 0x6e, 0x64, 0x65, 0x78, 0x2c, 0x20, 0x6c, 0x69, 0x73, 0x74, 0x29, 0x29,
+ 0x29, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x62, 0x72, 0x65,
+ 0x61, 0x6b, 0x65, 0x72, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x29,
+ 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e,
+ 0x20, 0x21, 0x21, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x3b, 0x0a, 0x20,
+ 0x20, 0x7d, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x44, 0x65,
+ 0x74, 0x65, 0x72, 0x6d, 0x69, 0x6e, 0x65, 0x20, 0x69, 0x66, 0x20, 0x61,
+ 0x74, 0x20, 0x6c, 0x65, 0x61, 0x73, 0x74, 0x20, 0x6f, 0x6e, 0x65, 0x20,
+ 0x65, 0x6c, 0x65, 0x6d, 0x65, 0x6e, 0x74, 0x20, 0x69, 0x6e, 0x20, 0x74,
+ 0x68, 0x65, 0x20, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, 0x6d, 0x61,
+ 0x74, 0x63, 0x68, 0x65, 0x73, 0x20, 0x61, 0x20, 0x74, 0x72, 0x75, 0x74,
+ 0x68, 0x20, 0x74, 0x65, 0x73, 0x74, 0x2e, 0x0a, 0x20, 0x20, 0x2f, 0x2f,
+ 0x20, 0x44, 0x65, 0x6c, 0x65, 0x67, 0x61, 0x74, 0x65, 0x73, 0x20, 0x74,
+ 0x6f, 0x20, 0x2a, 0x2a, 0x45, 0x43, 0x4d, 0x41, 0x53, 0x63, 0x72, 0x69,
+ 0x70, 0x74, 0x20, 0x35, 0x2a, 0x2a, 0x27, 0x73, 0x20, 0x6e, 0x61, 0x74,
+ 0x69, 0x76, 0x65, 0x20, 0x60, 0x73, 0x6f, 0x6d, 0x65, 0x60, 0x20, 0x69,
+ 0x66, 0x20, 0x61, 0x76, 0x61, 0x69, 0x6c, 0x61, 0x62, 0x6c, 0x65, 0x2e,
+ 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x41, 0x6c, 0x69, 0x61, 0x73, 0x65,
+ 0x64, 0x20, 0x61, 0x73, 0x20, 0x60, 0x61, 0x6e, 0x79, 0x60, 0x2e, 0x0a,
+ 0x20, 0x20, 0x76, 0x61, 0x72, 0x20, 0x61, 0x6e, 0x79, 0x20, 0x3d, 0x20,
+ 0x5f, 0x2e, 0x73, 0x6f, 0x6d, 0x65, 0x20, 0x3d, 0x20, 0x5f, 0x2e, 0x61,
+ 0x6e, 0x79, 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f,
+ 0x6e, 0x28, 0x6f, 0x62, 0x6a, 0x2c, 0x20, 0x69, 0x74, 0x65, 0x72, 0x61,
+ 0x74, 0x6f, 0x72, 0x2c, 0x20, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74,
+ 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x69, 0x74, 0x65, 0x72,
+ 0x61, 0x74, 0x6f, 0x72, 0x20, 0x7c, 0x7c, 0x20, 0x28, 0x69, 0x74, 0x65,
+ 0x72, 0x61, 0x74, 0x6f, 0x72, 0x20, 0x3d, 0x20, 0x5f, 0x2e, 0x69, 0x64,
+ 0x65, 0x6e, 0x74, 0x69, 0x74, 0x79, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20,
+ 0x20, 0x76, 0x61, 0x72, 0x20, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x20,
+ 0x3d, 0x20, 0x66, 0x61, 0x6c, 0x73, 0x65, 0x3b, 0x0a, 0x20, 0x20, 0x20,
+ 0x20, 0x69, 0x66, 0x20, 0x28, 0x6f, 0x62, 0x6a, 0x20, 0x3d, 0x3d, 0x20,
+ 0x6e, 0x75, 0x6c, 0x6c, 0x29, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e,
+ 0x20, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x3b, 0x0a, 0x20, 0x20, 0x20,
+ 0x20, 0x69, 0x66, 0x20, 0x28, 0x6e, 0x61, 0x74, 0x69, 0x76, 0x65, 0x53,
+ 0x6f, 0x6d, 0x65, 0x20, 0x26, 0x26, 0x20, 0x6f, 0x62, 0x6a, 0x2e, 0x73,
+ 0x6f, 0x6d, 0x65, 0x20, 0x3d, 0x3d, 0x3d, 0x20, 0x6e, 0x61, 0x74, 0x69,
+ 0x76, 0x65, 0x53, 0x6f, 0x6d, 0x65, 0x29, 0x20, 0x72, 0x65, 0x74, 0x75,
+ 0x72, 0x6e, 0x20, 0x6f, 0x62, 0x6a, 0x2e, 0x73, 0x6f, 0x6d, 0x65, 0x28,
+ 0x69, 0x74, 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x2c, 0x20, 0x63, 0x6f,
+ 0x6e, 0x74, 0x65, 0x78, 0x74, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x65, 0x61, 0x63, 0x68, 0x28, 0x6f, 0x62, 0x6a, 0x2c, 0x20, 0x66, 0x75,
+ 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x76, 0x61, 0x6c, 0x75, 0x65,
+ 0x2c, 0x20, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x2c, 0x20, 0x6c, 0x69, 0x73,
+ 0x74, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x69,
+ 0x66, 0x20, 0x28, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x20, 0x7c, 0x7c,
+ 0x20, 0x28, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x20, 0x3d, 0x20, 0x69,
+ 0x74, 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x2e, 0x63, 0x61, 0x6c, 0x6c,
+ 0x28, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x2c, 0x20, 0x76, 0x61,
+ 0x6c, 0x75, 0x65, 0x2c, 0x20, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x2c, 0x20,
+ 0x6c, 0x69, 0x73, 0x74, 0x29, 0x29, 0x29, 0x20, 0x72, 0x65, 0x74, 0x75,
+ 0x72, 0x6e, 0x20, 0x62, 0x72, 0x65, 0x61, 0x6b, 0x65, 0x72, 0x3b, 0x0a,
+ 0x20, 0x20, 0x20, 0x20, 0x7d, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x21, 0x21, 0x72, 0x65, 0x73,
+ 0x75, 0x6c, 0x74, 0x3b, 0x0a, 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x0a, 0x20,
+ 0x20, 0x2f, 0x2f, 0x20, 0x44, 0x65, 0x74, 0x65, 0x72, 0x6d, 0x69, 0x6e,
+ 0x65, 0x20, 0x69, 0x66, 0x20, 0x74, 0x68, 0x65, 0x20, 0x61, 0x72, 0x72,
+ 0x61, 0x79, 0x20, 0x6f, 0x72, 0x20, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74,
+ 0x20, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x73, 0x20, 0x61, 0x20,
+ 0x67, 0x69, 0x76, 0x65, 0x6e, 0x20, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x20,
+ 0x28, 0x75, 0x73, 0x69, 0x6e, 0x67, 0x20, 0x60, 0x3d, 0x3d, 0x3d, 0x60,
+ 0x29, 0x2e, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x41, 0x6c, 0x69, 0x61,
+ 0x73, 0x65, 0x64, 0x20, 0x61, 0x73, 0x20, 0x60, 0x69, 0x6e, 0x63, 0x6c,
+ 0x75, 0x64, 0x65, 0x60, 0x2e, 0x0a, 0x20, 0x20, 0x5f, 0x2e, 0x63, 0x6f,
+ 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x73, 0x20, 0x3d, 0x20, 0x5f, 0x2e, 0x69,
+ 0x6e, 0x63, 0x6c, 0x75, 0x64, 0x65, 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e,
+ 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x6f, 0x62, 0x6a, 0x2c, 0x20, 0x74,
+ 0x61, 0x72, 0x67, 0x65, 0x74, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20,
+ 0x20, 0x69, 0x66, 0x20, 0x28, 0x6f, 0x62, 0x6a, 0x20, 0x3d, 0x3d, 0x20,
+ 0x6e, 0x75, 0x6c, 0x6c, 0x29, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e,
+ 0x20, 0x66, 0x61, 0x6c, 0x73, 0x65, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x69, 0x66, 0x20, 0x28, 0x6e, 0x61, 0x74, 0x69, 0x76, 0x65, 0x49, 0x6e,
+ 0x64, 0x65, 0x78, 0x4f, 0x66, 0x20, 0x26, 0x26, 0x20, 0x6f, 0x62, 0x6a,
+ 0x2e, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x4f, 0x66, 0x20, 0x3d, 0x3d, 0x3d,
+ 0x20, 0x6e, 0x61, 0x74, 0x69, 0x76, 0x65, 0x49, 0x6e, 0x64, 0x65, 0x78,
+ 0x4f, 0x66, 0x29, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x6f,
+ 0x62, 0x6a, 0x2e, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x4f, 0x66, 0x28, 0x74,
+ 0x61, 0x72, 0x67, 0x65, 0x74, 0x29, 0x20, 0x21, 0x3d, 0x20, 0x2d, 0x31,
+ 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e,
+ 0x20, 0x61, 0x6e, 0x79, 0x28, 0x6f, 0x62, 0x6a, 0x2c, 0x20, 0x66, 0x75,
+ 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x76, 0x61, 0x6c, 0x75, 0x65,
+ 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65,
+ 0x74, 0x75, 0x72, 0x6e, 0x20, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x20, 0x3d,
+ 0x3d, 0x3d, 0x20, 0x74, 0x61, 0x72, 0x67, 0x65, 0x74, 0x3b, 0x0a, 0x20,
+ 0x20, 0x20, 0x20, 0x7d, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x7d, 0x3b, 0x0a,
+ 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x49, 0x6e, 0x76, 0x6f, 0x6b, 0x65,
+ 0x20, 0x61, 0x20, 0x6d, 0x65, 0x74, 0x68, 0x6f, 0x64, 0x20, 0x28, 0x77,
+ 0x69, 0x74, 0x68, 0x20, 0x61, 0x72, 0x67, 0x75, 0x6d, 0x65, 0x6e, 0x74,
+ 0x73, 0x29, 0x20, 0x6f, 0x6e, 0x20, 0x65, 0x76, 0x65, 0x72, 0x79, 0x20,
+ 0x69, 0x74, 0x65, 0x6d, 0x20, 0x69, 0x6e, 0x20, 0x61, 0x20, 0x63, 0x6f,
+ 0x6c, 0x6c, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x0a, 0x20, 0x20,
+ 0x5f, 0x2e, 0x69, 0x6e, 0x76, 0x6f, 0x6b, 0x65, 0x20, 0x3d, 0x20, 0x66,
+ 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x6f, 0x62, 0x6a, 0x2c,
+ 0x20, 0x6d, 0x65, 0x74, 0x68, 0x6f, 0x64, 0x29, 0x20, 0x7b, 0x0a, 0x20,
+ 0x20, 0x20, 0x20, 0x76, 0x61, 0x72, 0x20, 0x61, 0x72, 0x67, 0x73, 0x20,
+ 0x3d, 0x20, 0x73, 0x6c, 0x69, 0x63, 0x65, 0x2e, 0x63, 0x61, 0x6c, 0x6c,
+ 0x28, 0x61, 0x72, 0x67, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x2c, 0x20,
+ 0x32, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x76, 0x61, 0x72, 0x20,
+ 0x69, 0x73, 0x46, 0x75, 0x6e, 0x63, 0x20, 0x3d, 0x20, 0x5f, 0x2e, 0x69,
+ 0x73, 0x46, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x6d, 0x65,
+ 0x74, 0x68, 0x6f, 0x64, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x72,
+ 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x5f, 0x2e, 0x6d, 0x61, 0x70, 0x28,
+ 0x6f, 0x62, 0x6a, 0x2c, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f,
+ 0x6e, 0x28, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x29, 0x20, 0x7b, 0x0a, 0x20,
+ 0x20, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20,
+ 0x28, 0x69, 0x73, 0x46, 0x75, 0x6e, 0x63, 0x20, 0x3f, 0x20, 0x6d, 0x65,
+ 0x74, 0x68, 0x6f, 0x64, 0x20, 0x3a, 0x20, 0x76, 0x61, 0x6c, 0x75, 0x65,
+ 0x5b, 0x6d, 0x65, 0x74, 0x68, 0x6f, 0x64, 0x5d, 0x29, 0x2e, 0x61, 0x70,
+ 0x70, 0x6c, 0x79, 0x28, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x2c, 0x20, 0x61,
+ 0x72, 0x67, 0x73, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x29,
+ 0x3b, 0x0a, 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f,
+ 0x20, 0x43, 0x6f, 0x6e, 0x76, 0x65, 0x6e, 0x69, 0x65, 0x6e, 0x63, 0x65,
+ 0x20, 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x20, 0x6f, 0x66, 0x20,
+ 0x61, 0x20, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x20, 0x75, 0x73, 0x65,
+ 0x20, 0x63, 0x61, 0x73, 0x65, 0x20, 0x6f, 0x66, 0x20, 0x60, 0x6d, 0x61,
+ 0x70, 0x60, 0x3a, 0x20, 0x66, 0x65, 0x74, 0x63, 0x68, 0x69, 0x6e, 0x67,
+ 0x20, 0x61, 0x20, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x79, 0x2e,
+ 0x0a, 0x20, 0x20, 0x5f, 0x2e, 0x70, 0x6c, 0x75, 0x63, 0x6b, 0x20, 0x3d,
+ 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x6f, 0x62,
+ 0x6a, 0x2c, 0x20, 0x6b, 0x65, 0x79, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20,
+ 0x20, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x5f, 0x2e, 0x6d,
+ 0x61, 0x70, 0x28, 0x6f, 0x62, 0x6a, 0x2c, 0x20, 0x66, 0x75, 0x6e, 0x63,
+ 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x29, 0x7b,
+ 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x76, 0x61, 0x6c, 0x75,
+ 0x65, 0x5b, 0x6b, 0x65, 0x79, 0x5d, 0x3b, 0x20, 0x7d, 0x29, 0x3b, 0x0a,
+ 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x43,
+ 0x6f, 0x6e, 0x76, 0x65, 0x6e, 0x69, 0x65, 0x6e, 0x63, 0x65, 0x20, 0x76,
+ 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x20, 0x6f, 0x66, 0x20, 0x61, 0x20,
+ 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x20, 0x75, 0x73, 0x65, 0x20, 0x63,
+ 0x61, 0x73, 0x65, 0x20, 0x6f, 0x66, 0x20, 0x60, 0x66, 0x69, 0x6c, 0x74,
+ 0x65, 0x72, 0x60, 0x3a, 0x20, 0x73, 0x65, 0x6c, 0x65, 0x63, 0x74, 0x69,
+ 0x6e, 0x67, 0x20, 0x6f, 0x6e, 0x6c, 0x79, 0x20, 0x6f, 0x62, 0x6a, 0x65,
+ 0x63, 0x74, 0x73, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x63, 0x6f, 0x6e,
+ 0x74, 0x61, 0x69, 0x6e, 0x69, 0x6e, 0x67, 0x20, 0x73, 0x70, 0x65, 0x63,
+ 0x69, 0x66, 0x69, 0x63, 0x20, 0x60, 0x6b, 0x65, 0x79, 0x3a, 0x76, 0x61,
+ 0x6c, 0x75, 0x65, 0x60, 0x20, 0x70, 0x61, 0x69, 0x72, 0x73, 0x2e, 0x0a,
+ 0x20, 0x20, 0x5f, 0x2e, 0x77, 0x68, 0x65, 0x72, 0x65, 0x20, 0x3d, 0x20,
+ 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x6f, 0x62, 0x6a,
+ 0x2c, 0x20, 0x61, 0x74, 0x74, 0x72, 0x73, 0x2c, 0x20, 0x66, 0x69, 0x72,
+ 0x73, 0x74, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66,
+ 0x20, 0x28, 0x5f, 0x2e, 0x69, 0x73, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x28,
+ 0x61, 0x74, 0x74, 0x72, 0x73, 0x29, 0x29, 0x20, 0x72, 0x65, 0x74, 0x75,
+ 0x72, 0x6e, 0x20, 0x66, 0x69, 0x72, 0x73, 0x74, 0x20, 0x3f, 0x20, 0x6e,
+ 0x75, 0x6c, 0x6c, 0x20, 0x3a, 0x20, 0x5b, 0x5d, 0x3b, 0x0a, 0x20, 0x20,
+ 0x20, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x5f, 0x5b, 0x66,
+ 0x69, 0x72, 0x73, 0x74, 0x20, 0x3f, 0x20, 0x27, 0x66, 0x69, 0x6e, 0x64,
+ 0x27, 0x20, 0x3a, 0x20, 0x27, 0x66, 0x69, 0x6c, 0x74, 0x65, 0x72, 0x27,
+ 0x5d, 0x28, 0x6f, 0x62, 0x6a, 0x2c, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74,
+ 0x69, 0x6f, 0x6e, 0x28, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x29, 0x20, 0x7b,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x66, 0x6f, 0x72, 0x20, 0x28,
+ 0x76, 0x61, 0x72, 0x20, 0x6b, 0x65, 0x79, 0x20, 0x69, 0x6e, 0x20, 0x61,
+ 0x74, 0x74, 0x72, 0x73, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20, 0x28, 0x61, 0x74, 0x74, 0x72,
+ 0x73, 0x5b, 0x6b, 0x65, 0x79, 0x5d, 0x20, 0x21, 0x3d, 0x3d, 0x20, 0x76,
+ 0x61, 0x6c, 0x75, 0x65, 0x5b, 0x6b, 0x65, 0x79, 0x5d, 0x29, 0x20, 0x72,
+ 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x66, 0x61, 0x6c, 0x73, 0x65, 0x3b,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x0a, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x74, 0x72,
+ 0x75, 0x65, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x29, 0x3b, 0x0a,
+ 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x43,
+ 0x6f, 0x6e, 0x76, 0x65, 0x6e, 0x69, 0x65, 0x6e, 0x63, 0x65, 0x20, 0x76,
+ 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x20, 0x6f, 0x66, 0x20, 0x61, 0x20,
+ 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x20, 0x75, 0x73, 0x65, 0x20, 0x63,
+ 0x61, 0x73, 0x65, 0x20, 0x6f, 0x66, 0x20, 0x60, 0x66, 0x69, 0x6e, 0x64,
+ 0x60, 0x3a, 0x20, 0x67, 0x65, 0x74, 0x74, 0x69, 0x6e, 0x67, 0x20, 0x74,
+ 0x68, 0x65, 0x20, 0x66, 0x69, 0x72, 0x73, 0x74, 0x20, 0x6f, 0x62, 0x6a,
+ 0x65, 0x63, 0x74, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x63, 0x6f, 0x6e,
+ 0x74, 0x61, 0x69, 0x6e, 0x69, 0x6e, 0x67, 0x20, 0x73, 0x70, 0x65, 0x63,
+ 0x69, 0x66, 0x69, 0x63, 0x20, 0x60, 0x6b, 0x65, 0x79, 0x3a, 0x76, 0x61,
+ 0x6c, 0x75, 0x65, 0x60, 0x20, 0x70, 0x61, 0x69, 0x72, 0x73, 0x2e, 0x0a,
+ 0x20, 0x20, 0x5f, 0x2e, 0x66, 0x69, 0x6e, 0x64, 0x57, 0x68, 0x65, 0x72,
+ 0x65, 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e,
+ 0x28, 0x6f, 0x62, 0x6a, 0x2c, 0x20, 0x61, 0x74, 0x74, 0x72, 0x73, 0x29,
+ 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72,
+ 0x6e, 0x20, 0x5f, 0x2e, 0x77, 0x68, 0x65, 0x72, 0x65, 0x28, 0x6f, 0x62,
+ 0x6a, 0x2c, 0x20, 0x61, 0x74, 0x74, 0x72, 0x73, 0x2c, 0x20, 0x74, 0x72,
+ 0x75, 0x65, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x0a, 0x20,
+ 0x20, 0x2f, 0x2f, 0x20, 0x52, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x74,
+ 0x68, 0x65, 0x20, 0x6d, 0x61, 0x78, 0x69, 0x6d, 0x75, 0x6d, 0x20, 0x65,
+ 0x6c, 0x65, 0x6d, 0x65, 0x6e, 0x74, 0x20, 0x6f, 0x72, 0x20, 0x28, 0x65,
+ 0x6c, 0x65, 0x6d, 0x65, 0x6e, 0x74, 0x2d, 0x62, 0x61, 0x73, 0x65, 0x64,
+ 0x20, 0x63, 0x6f, 0x6d, 0x70, 0x75, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e,
+ 0x29, 0x2e, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x43, 0x61, 0x6e, 0x27,
+ 0x74, 0x20, 0x6f, 0x70, 0x74, 0x69, 0x6d, 0x69, 0x7a, 0x65, 0x20, 0x61,
+ 0x72, 0x72, 0x61, 0x79, 0x73, 0x20, 0x6f, 0x66, 0x20, 0x69, 0x6e, 0x74,
+ 0x65, 0x67, 0x65, 0x72, 0x73, 0x20, 0x6c, 0x6f, 0x6e, 0x67, 0x65, 0x72,
+ 0x20, 0x74, 0x68, 0x61, 0x6e, 0x20, 0x36, 0x35, 0x2c, 0x35, 0x33, 0x35,
+ 0x20, 0x65, 0x6c, 0x65, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x2e, 0x0a, 0x20,
+ 0x20, 0x2f, 0x2f, 0x20, 0x53, 0x65, 0x65, 0x3a, 0x20, 0x68, 0x74, 0x74,
+ 0x70, 0x73, 0x3a, 0x2f, 0x2f, 0x62, 0x75, 0x67, 0x73, 0x2e, 0x77, 0x65,
+ 0x62, 0x6b, 0x69, 0x74, 0x2e, 0x6f, 0x72, 0x67, 0x2f, 0x73, 0x68, 0x6f,
+ 0x77, 0x5f, 0x62, 0x75, 0x67, 0x2e, 0x63, 0x67, 0x69, 0x3f, 0x69, 0x64,
+ 0x3d, 0x38, 0x30, 0x37, 0x39, 0x37, 0x0a, 0x20, 0x20, 0x5f, 0x2e, 0x6d,
+ 0x61, 0x78, 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f,
+ 0x6e, 0x28, 0x6f, 0x62, 0x6a, 0x2c, 0x20, 0x69, 0x74, 0x65, 0x72, 0x61,
+ 0x74, 0x6f, 0x72, 0x2c, 0x20, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74,
+ 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20, 0x28,
+ 0x21, 0x69, 0x74, 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x20, 0x26, 0x26,
+ 0x20, 0x5f, 0x2e, 0x69, 0x73, 0x41, 0x72, 0x72, 0x61, 0x79, 0x28, 0x6f,
+ 0x62, 0x6a, 0x29, 0x20, 0x26, 0x26, 0x20, 0x6f, 0x62, 0x6a, 0x5b, 0x30,
+ 0x5d, 0x20, 0x3d, 0x3d, 0x3d, 0x20, 0x2b, 0x6f, 0x62, 0x6a, 0x5b, 0x30,
+ 0x5d, 0x20, 0x26, 0x26, 0x20, 0x6f, 0x62, 0x6a, 0x2e, 0x6c, 0x65, 0x6e,
+ 0x67, 0x74, 0x68, 0x20, 0x3c, 0x20, 0x36, 0x35, 0x35, 0x33, 0x35, 0x29,
+ 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74,
+ 0x75, 0x72, 0x6e, 0x20, 0x4d, 0x61, 0x74, 0x68, 0x2e, 0x6d, 0x61, 0x78,
+ 0x2e, 0x61, 0x70, 0x70, 0x6c, 0x79, 0x28, 0x4d, 0x61, 0x74, 0x68, 0x2c,
+ 0x20, 0x6f, 0x62, 0x6a, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x7d,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20, 0x28, 0x21, 0x69, 0x74,
+ 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x20, 0x26, 0x26, 0x20, 0x5f, 0x2e,
+ 0x69, 0x73, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x28, 0x6f, 0x62, 0x6a, 0x29,
+ 0x29, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x2d, 0x49, 0x6e,
+ 0x66, 0x69, 0x6e, 0x69, 0x74, 0x79, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x76, 0x61, 0x72, 0x20, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x20, 0x3d,
+ 0x20, 0x7b, 0x63, 0x6f, 0x6d, 0x70, 0x75, 0x74, 0x65, 0x64, 0x20, 0x3a,
+ 0x20, 0x2d, 0x49, 0x6e, 0x66, 0x69, 0x6e, 0x69, 0x74, 0x79, 0x2c, 0x20,
+ 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x20, 0x2d, 0x49, 0x6e, 0x66, 0x69,
+ 0x6e, 0x69, 0x74, 0x79, 0x7d, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x65,
+ 0x61, 0x63, 0x68, 0x28, 0x6f, 0x62, 0x6a, 0x2c, 0x20, 0x66, 0x75, 0x6e,
+ 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x2c,
+ 0x20, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x2c, 0x20, 0x6c, 0x69, 0x73, 0x74,
+ 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x76, 0x61,
+ 0x72, 0x20, 0x63, 0x6f, 0x6d, 0x70, 0x75, 0x74, 0x65, 0x64, 0x20, 0x3d,
+ 0x20, 0x69, 0x74, 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x20, 0x3f, 0x20,
+ 0x69, 0x74, 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x2e, 0x63, 0x61, 0x6c,
+ 0x6c, 0x28, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x2c, 0x20, 0x76,
+ 0x61, 0x6c, 0x75, 0x65, 0x2c, 0x20, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x2c,
+ 0x20, 0x6c, 0x69, 0x73, 0x74, 0x29, 0x20, 0x3a, 0x20, 0x76, 0x61, 0x6c,
+ 0x75, 0x65, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x63, 0x6f,
+ 0x6d, 0x70, 0x75, 0x74, 0x65, 0x64, 0x20, 0x3e, 0x3d, 0x20, 0x72, 0x65,
+ 0x73, 0x75, 0x6c, 0x74, 0x2e, 0x63, 0x6f, 0x6d, 0x70, 0x75, 0x74, 0x65,
+ 0x64, 0x20, 0x26, 0x26, 0x20, 0x28, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74,
+ 0x20, 0x3d, 0x20, 0x7b, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x20, 0x3a, 0x20,
+ 0x76, 0x61, 0x6c, 0x75, 0x65, 0x2c, 0x20, 0x63, 0x6f, 0x6d, 0x70, 0x75,
+ 0x74, 0x65, 0x64, 0x20, 0x3a, 0x20, 0x63, 0x6f, 0x6d, 0x70, 0x75, 0x74,
+ 0x65, 0x64, 0x7d, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x29,
+ 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e,
+ 0x20, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x2e, 0x76, 0x61, 0x6c, 0x75,
+ 0x65, 0x3b, 0x0a, 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f,
+ 0x2f, 0x20, 0x52, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x74, 0x68, 0x65,
+ 0x20, 0x6d, 0x69, 0x6e, 0x69, 0x6d, 0x75, 0x6d, 0x20, 0x65, 0x6c, 0x65,
+ 0x6d, 0x65, 0x6e, 0x74, 0x20, 0x28, 0x6f, 0x72, 0x20, 0x65, 0x6c, 0x65,
+ 0x6d, 0x65, 0x6e, 0x74, 0x2d, 0x62, 0x61, 0x73, 0x65, 0x64, 0x20, 0x63,
+ 0x6f, 0x6d, 0x70, 0x75, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x29, 0x2e,
+ 0x0a, 0x20, 0x20, 0x5f, 0x2e, 0x6d, 0x69, 0x6e, 0x20, 0x3d, 0x20, 0x66,
+ 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x6f, 0x62, 0x6a, 0x2c,
+ 0x20, 0x69, 0x74, 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x2c, 0x20, 0x63,
+ 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20,
+ 0x20, 0x20, 0x69, 0x66, 0x20, 0x28, 0x21, 0x69, 0x74, 0x65, 0x72, 0x61,
+ 0x74, 0x6f, 0x72, 0x20, 0x26, 0x26, 0x20, 0x5f, 0x2e, 0x69, 0x73, 0x41,
+ 0x72, 0x72, 0x61, 0x79, 0x28, 0x6f, 0x62, 0x6a, 0x29, 0x20, 0x26, 0x26,
+ 0x20, 0x6f, 0x62, 0x6a, 0x5b, 0x30, 0x5d, 0x20, 0x3d, 0x3d, 0x3d, 0x20,
+ 0x2b, 0x6f, 0x62, 0x6a, 0x5b, 0x30, 0x5d, 0x20, 0x26, 0x26, 0x20, 0x6f,
+ 0x62, 0x6a, 0x2e, 0x6c, 0x65, 0x6e, 0x67, 0x74, 0x68, 0x20, 0x3c, 0x20,
+ 0x36, 0x35, 0x35, 0x33, 0x35, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x4d, 0x61,
+ 0x74, 0x68, 0x2e, 0x6d, 0x69, 0x6e, 0x2e, 0x61, 0x70, 0x70, 0x6c, 0x79,
+ 0x28, 0x4d, 0x61, 0x74, 0x68, 0x2c, 0x20, 0x6f, 0x62, 0x6a, 0x29, 0x3b,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x69,
+ 0x66, 0x20, 0x28, 0x21, 0x69, 0x74, 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72,
+ 0x20, 0x26, 0x26, 0x20, 0x5f, 0x2e, 0x69, 0x73, 0x45, 0x6d, 0x70, 0x74,
+ 0x79, 0x28, 0x6f, 0x62, 0x6a, 0x29, 0x29, 0x20, 0x72, 0x65, 0x74, 0x75,
+ 0x72, 0x6e, 0x20, 0x49, 0x6e, 0x66, 0x69, 0x6e, 0x69, 0x74, 0x79, 0x3b,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x76, 0x61, 0x72, 0x20, 0x72, 0x65, 0x73,
+ 0x75, 0x6c, 0x74, 0x20, 0x3d, 0x20, 0x7b, 0x63, 0x6f, 0x6d, 0x70, 0x75,
+ 0x74, 0x65, 0x64, 0x20, 0x3a, 0x20, 0x49, 0x6e, 0x66, 0x69, 0x6e, 0x69,
+ 0x74, 0x79, 0x2c, 0x20, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x20, 0x49,
+ 0x6e, 0x66, 0x69, 0x6e, 0x69, 0x74, 0x79, 0x7d, 0x3b, 0x0a, 0x20, 0x20,
+ 0x20, 0x20, 0x65, 0x61, 0x63, 0x68, 0x28, 0x6f, 0x62, 0x6a, 0x2c, 0x20,
+ 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x76, 0x61, 0x6c,
+ 0x75, 0x65, 0x2c, 0x20, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x2c, 0x20, 0x6c,
+ 0x69, 0x73, 0x74, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x76, 0x61, 0x72, 0x20, 0x63, 0x6f, 0x6d, 0x70, 0x75, 0x74, 0x65,
+ 0x64, 0x20, 0x3d, 0x20, 0x69, 0x74, 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72,
+ 0x20, 0x3f, 0x20, 0x69, 0x74, 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x2e,
+ 0x63, 0x61, 0x6c, 0x6c, 0x28, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74,
+ 0x2c, 0x20, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x2c, 0x20, 0x69, 0x6e, 0x64,
+ 0x65, 0x78, 0x2c, 0x20, 0x6c, 0x69, 0x73, 0x74, 0x29, 0x20, 0x3a, 0x20,
+ 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x63, 0x6f, 0x6d, 0x70, 0x75, 0x74, 0x65, 0x64, 0x20, 0x3c, 0x20,
+ 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x2e, 0x63, 0x6f, 0x6d, 0x70, 0x75,
+ 0x74, 0x65, 0x64, 0x20, 0x26, 0x26, 0x20, 0x28, 0x72, 0x65, 0x73, 0x75,
+ 0x6c, 0x74, 0x20, 0x3d, 0x20, 0x7b, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x20,
+ 0x3a, 0x20, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x2c, 0x20, 0x63, 0x6f, 0x6d,
+ 0x70, 0x75, 0x74, 0x65, 0x64, 0x20, 0x3a, 0x20, 0x63, 0x6f, 0x6d, 0x70,
+ 0x75, 0x74, 0x65, 0x64, 0x7d, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x7d, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74, 0x75,
+ 0x72, 0x6e, 0x20, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x2e, 0x76, 0x61,
+ 0x6c, 0x75, 0x65, 0x3b, 0x0a, 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x0a, 0x20,
+ 0x20, 0x2f, 0x2f, 0x20, 0x53, 0x68, 0x75, 0x66, 0x66, 0x6c, 0x65, 0x20,
+ 0x61, 0x6e, 0x20, 0x61, 0x72, 0x72, 0x61, 0x79, 0x2e, 0x0a, 0x20, 0x20,
+ 0x5f, 0x2e, 0x73, 0x68, 0x75, 0x66, 0x66, 0x6c, 0x65, 0x20, 0x3d, 0x20,
+ 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x6f, 0x62, 0x6a,
+ 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x76, 0x61, 0x72, 0x20,
+ 0x72, 0x61, 0x6e, 0x64, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x76, 0x61,
+ 0x72, 0x20, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x20, 0x3d, 0x20, 0x30, 0x3b,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x76, 0x61, 0x72, 0x20, 0x73, 0x68, 0x75,
+ 0x66, 0x66, 0x6c, 0x65, 0x64, 0x20, 0x3d, 0x20, 0x5b, 0x5d, 0x3b, 0x0a,
+ 0x20, 0x20, 0x20, 0x20, 0x65, 0x61, 0x63, 0x68, 0x28, 0x6f, 0x62, 0x6a,
+ 0x2c, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x76,
+ 0x61, 0x6c, 0x75, 0x65, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x72, 0x61, 0x6e, 0x64, 0x20, 0x3d, 0x20, 0x5f, 0x2e, 0x72,
+ 0x61, 0x6e, 0x64, 0x6f, 0x6d, 0x28, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x2b,
+ 0x2b, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x73, 0x68,
+ 0x75, 0x66, 0x66, 0x6c, 0x65, 0x64, 0x5b, 0x69, 0x6e, 0x64, 0x65, 0x78,
+ 0x20, 0x2d, 0x20, 0x31, 0x5d, 0x20, 0x3d, 0x20, 0x73, 0x68, 0x75, 0x66,
+ 0x66, 0x6c, 0x65, 0x64, 0x5b, 0x72, 0x61, 0x6e, 0x64, 0x5d, 0x3b, 0x0a,
+ 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x73, 0x68, 0x75, 0x66, 0x66, 0x6c,
+ 0x65, 0x64, 0x5b, 0x72, 0x61, 0x6e, 0x64, 0x5d, 0x20, 0x3d, 0x20, 0x76,
+ 0x61, 0x6c, 0x75, 0x65, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x29,
+ 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e,
+ 0x20, 0x73, 0x68, 0x75, 0x66, 0x66, 0x6c, 0x65, 0x64, 0x3b, 0x0a, 0x20,
+ 0x20, 0x7d, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x41, 0x6e,
+ 0x20, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x6e, 0x61, 0x6c, 0x20, 0x66, 0x75,
+ 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x20, 0x74, 0x6f, 0x20, 0x67, 0x65,
+ 0x6e, 0x65, 0x72, 0x61, 0x74, 0x65, 0x20, 0x6c, 0x6f, 0x6f, 0x6b, 0x75,
+ 0x70, 0x20, 0x69, 0x74, 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x73, 0x2e,
+ 0x0a, 0x20, 0x20, 0x76, 0x61, 0x72, 0x20, 0x6c, 0x6f, 0x6f, 0x6b, 0x75,
+ 0x70, 0x49, 0x74, 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x20, 0x3d, 0x20,
+ 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x76, 0x61, 0x6c,
+ 0x75, 0x65, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65,
+ 0x74, 0x75, 0x72, 0x6e, 0x20, 0x5f, 0x2e, 0x69, 0x73, 0x46, 0x75, 0x6e,
+ 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x29,
+ 0x20, 0x3f, 0x20, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x20, 0x3a, 0x20, 0x66,
+ 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x6f, 0x62, 0x6a, 0x29,
+ 0x7b, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x6f, 0x62, 0x6a,
+ 0x5b, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x5d, 0x3b, 0x20, 0x7d, 0x3b, 0x0a,
+ 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x53,
+ 0x6f, 0x72, 0x74, 0x20, 0x74, 0x68, 0x65, 0x20, 0x6f, 0x62, 0x6a, 0x65,
+ 0x63, 0x74, 0x27, 0x73, 0x20, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x73, 0x20,
+ 0x62, 0x79, 0x20, 0x61, 0x20, 0x63, 0x72, 0x69, 0x74, 0x65, 0x72, 0x69,
+ 0x6f, 0x6e, 0x20, 0x70, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x65, 0x64, 0x20,
+ 0x62, 0x79, 0x20, 0x61, 0x6e, 0x20, 0x69, 0x74, 0x65, 0x72, 0x61, 0x74,
+ 0x6f, 0x72, 0x2e, 0x0a, 0x20, 0x20, 0x5f, 0x2e, 0x73, 0x6f, 0x72, 0x74,
+ 0x42, 0x79, 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f,
+ 0x6e, 0x28, 0x6f, 0x62, 0x6a, 0x2c, 0x20, 0x76, 0x61, 0x6c, 0x75, 0x65,
+ 0x2c, 0x20, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x29, 0x20, 0x7b,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x76, 0x61, 0x72, 0x20, 0x69, 0x74, 0x65,
+ 0x72, 0x61, 0x74, 0x6f, 0x72, 0x20, 0x3d, 0x20, 0x6c, 0x6f, 0x6f, 0x6b,
+ 0x75, 0x70, 0x49, 0x74, 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x28, 0x76,
+ 0x61, 0x6c, 0x75, 0x65, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x72,
+ 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x5f, 0x2e, 0x70, 0x6c, 0x75, 0x63,
+ 0x6b, 0x28, 0x5f, 0x2e, 0x6d, 0x61, 0x70, 0x28, 0x6f, 0x62, 0x6a, 0x2c,
+ 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x76, 0x61,
+ 0x6c, 0x75, 0x65, 0x2c, 0x20, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x2c, 0x20,
+ 0x6c, 0x69, 0x73, 0x74, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x7b, 0x0a, 0x20,
+ 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x76, 0x61, 0x6c, 0x75, 0x65,
+ 0x20, 0x3a, 0x20, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x2c, 0x0a, 0x20, 0x20,
+ 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x20,
+ 0x3a, 0x20, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x2c, 0x0a, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x20, 0x20, 0x20, 0x63, 0x72, 0x69, 0x74, 0x65, 0x72, 0x69,
+ 0x61, 0x20, 0x3a, 0x20, 0x69, 0x74, 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72,
+ 0x2e, 0x63, 0x61, 0x6c, 0x6c, 0x28, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x78,
+ 0x74, 0x2c, 0x20, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x2c, 0x20, 0x69, 0x6e,
+ 0x64, 0x65, 0x78, 0x2c, 0x20, 0x6c, 0x69, 0x73, 0x74, 0x29, 0x0a, 0x20,
+ 0x20, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x7d, 0x29, 0x2e, 0x73, 0x6f, 0x72, 0x74, 0x28, 0x66, 0x75, 0x6e, 0x63,
+ 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x6c, 0x65, 0x66, 0x74, 0x2c, 0x20, 0x72,
+ 0x69, 0x67, 0x68, 0x74, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x76, 0x61, 0x72, 0x20, 0x61, 0x20, 0x3d, 0x20, 0x6c, 0x65,
+ 0x66, 0x74, 0x2e, 0x63, 0x72, 0x69, 0x74, 0x65, 0x72, 0x69, 0x61, 0x3b,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x76, 0x61, 0x72, 0x20, 0x62,
+ 0x20, 0x3d, 0x20, 0x72, 0x69, 0x67, 0x68, 0x74, 0x2e, 0x63, 0x72, 0x69,
+ 0x74, 0x65, 0x72, 0x69, 0x61, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x69, 0x66, 0x20, 0x28, 0x61, 0x20, 0x21, 0x3d, 0x3d, 0x20, 0x62,
+ 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x69, 0x66, 0x20, 0x28, 0x61, 0x20, 0x3e, 0x20, 0x62, 0x20, 0x7c, 0x7c,
+ 0x20, 0x61, 0x20, 0x3d, 0x3d, 0x3d, 0x20, 0x76, 0x6f, 0x69, 0x64, 0x20,
+ 0x30, 0x29, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x31, 0x3b,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20,
+ 0x28, 0x61, 0x20, 0x3c, 0x20, 0x62, 0x20, 0x7c, 0x7c, 0x20, 0x62, 0x20,
+ 0x3d, 0x3d, 0x3d, 0x20, 0x76, 0x6f, 0x69, 0x64, 0x20, 0x30, 0x29, 0x20,
+ 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x2d, 0x31, 0x3b, 0x0a, 0x20,
+ 0x20, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x6c, 0x65, 0x66, 0x74,
+ 0x2e, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x20, 0x3c, 0x20, 0x72, 0x69, 0x67,
+ 0x68, 0x74, 0x2e, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x20, 0x3f, 0x20, 0x2d,
+ 0x31, 0x20, 0x3a, 0x20, 0x31, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x7d,
+ 0x29, 0x2c, 0x20, 0x27, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x27, 0x29, 0x3b,
+ 0x0a, 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20,
+ 0x41, 0x6e, 0x20, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x6e, 0x61, 0x6c, 0x20,
+ 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x20, 0x75, 0x73, 0x65,
+ 0x64, 0x20, 0x66, 0x6f, 0x72, 0x20, 0x61, 0x67, 0x67, 0x72, 0x65, 0x67,
+ 0x61, 0x74, 0x65, 0x20, 0x22, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x20, 0x62,
+ 0x79, 0x22, 0x20, 0x6f, 0x70, 0x65, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e,
+ 0x73, 0x2e, 0x0a, 0x20, 0x20, 0x76, 0x61, 0x72, 0x20, 0x67, 0x72, 0x6f,
+ 0x75, 0x70, 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f,
+ 0x6e, 0x28, 0x6f, 0x62, 0x6a, 0x2c, 0x20, 0x76, 0x61, 0x6c, 0x75, 0x65,
+ 0x2c, 0x20, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x2c, 0x20, 0x62,
+ 0x65, 0x68, 0x61, 0x76, 0x69, 0x6f, 0x72, 0x29, 0x20, 0x7b, 0x0a, 0x20,
+ 0x20, 0x20, 0x20, 0x76, 0x61, 0x72, 0x20, 0x72, 0x65, 0x73, 0x75, 0x6c,
+ 0x74, 0x20, 0x3d, 0x20, 0x7b, 0x7d, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x76, 0x61, 0x72, 0x20, 0x69, 0x74, 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72,
+ 0x20, 0x3d, 0x20, 0x6c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x49, 0x74, 0x65,
+ 0x72, 0x61, 0x74, 0x6f, 0x72, 0x28, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x20,
+ 0x7c, 0x7c, 0x20, 0x5f, 0x2e, 0x69, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x74,
+ 0x79, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x65, 0x61, 0x63, 0x68,
+ 0x28, 0x6f, 0x62, 0x6a, 0x2c, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69,
+ 0x6f, 0x6e, 0x28, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x2c, 0x20, 0x69, 0x6e,
+ 0x64, 0x65, 0x78, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x76, 0x61, 0x72, 0x20, 0x6b, 0x65, 0x79, 0x20, 0x3d, 0x20, 0x69,
+ 0x74, 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x2e, 0x63, 0x61, 0x6c, 0x6c,
+ 0x28, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x2c, 0x20, 0x76, 0x61,
+ 0x6c, 0x75, 0x65, 0x2c, 0x20, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x2c, 0x20,
+ 0x6f, 0x62, 0x6a, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x62, 0x65, 0x68, 0x61, 0x76, 0x69, 0x6f, 0x72, 0x28, 0x72, 0x65, 0x73,
+ 0x75, 0x6c, 0x74, 0x2c, 0x20, 0x6b, 0x65, 0x79, 0x2c, 0x20, 0x76, 0x61,
+ 0x6c, 0x75, 0x65, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x29,
+ 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e,
+ 0x20, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x3b, 0x0a, 0x20, 0x20, 0x7d,
+ 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x47, 0x72, 0x6f, 0x75,
+ 0x70, 0x73, 0x20, 0x74, 0x68, 0x65, 0x20, 0x6f, 0x62, 0x6a, 0x65, 0x63,
+ 0x74, 0x27, 0x73, 0x20, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x73, 0x20, 0x62,
+ 0x79, 0x20, 0x61, 0x20, 0x63, 0x72, 0x69, 0x74, 0x65, 0x72, 0x69, 0x6f,
+ 0x6e, 0x2e, 0x20, 0x50, 0x61, 0x73, 0x73, 0x20, 0x65, 0x69, 0x74, 0x68,
+ 0x65, 0x72, 0x20, 0x61, 0x20, 0x73, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x20,
+ 0x61, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x0a, 0x20, 0x20,
+ 0x2f, 0x2f, 0x20, 0x74, 0x6f, 0x20, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x20,
+ 0x62, 0x79, 0x2c, 0x20, 0x6f, 0x72, 0x20, 0x61, 0x20, 0x66, 0x75, 0x6e,
+ 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x20, 0x74, 0x68, 0x61, 0x74, 0x20, 0x72,
+ 0x65, 0x74, 0x75, 0x72, 0x6e, 0x73, 0x20, 0x74, 0x68, 0x65, 0x20, 0x63,
+ 0x72, 0x69, 0x74, 0x65, 0x72, 0x69, 0x6f, 0x6e, 0x2e, 0x0a, 0x20, 0x20,
+ 0x5f, 0x2e, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x42, 0x79, 0x20, 0x3d, 0x20,
+ 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x6f, 0x62, 0x6a,
+ 0x2c, 0x20, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x2c, 0x20, 0x63, 0x6f, 0x6e,
+ 0x74, 0x65, 0x78, 0x74, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x67, 0x72, 0x6f, 0x75, 0x70,
+ 0x28, 0x6f, 0x62, 0x6a, 0x2c, 0x20, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x2c,
+ 0x20, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x2c, 0x20, 0x66, 0x75,
+ 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x72, 0x65, 0x73, 0x75, 0x6c,
+ 0x74, 0x2c, 0x20, 0x6b, 0x65, 0x79, 0x2c, 0x20, 0x76, 0x61, 0x6c, 0x75,
+ 0x65, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x28,
+ 0x5f, 0x2e, 0x68, 0x61, 0x73, 0x28, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74,
+ 0x2c, 0x20, 0x6b, 0x65, 0x79, 0x29, 0x20, 0x3f, 0x20, 0x72, 0x65, 0x73,
+ 0x75, 0x6c, 0x74, 0x5b, 0x6b, 0x65, 0x79, 0x5d, 0x20, 0x3a, 0x20, 0x28,
+ 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x5b, 0x6b, 0x65, 0x79, 0x5d, 0x20,
+ 0x3d, 0x20, 0x5b, 0x5d, 0x29, 0x29, 0x2e, 0x70, 0x75, 0x73, 0x68, 0x28,
+ 0x76, 0x61, 0x6c, 0x75, 0x65, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x7d, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x0a, 0x20, 0x20,
+ 0x2f, 0x2f, 0x20, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x73, 0x20, 0x69, 0x6e,
+ 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x73, 0x20, 0x6f, 0x66, 0x20, 0x61,
+ 0x6e, 0x20, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, 0x74, 0x68, 0x61,
+ 0x74, 0x20, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x20, 0x62, 0x79, 0x20, 0x61,
+ 0x20, 0x63, 0x65, 0x72, 0x74, 0x61, 0x69, 0x6e, 0x20, 0x63, 0x72, 0x69,
+ 0x74, 0x65, 0x72, 0x69, 0x6f, 0x6e, 0x2e, 0x20, 0x50, 0x61, 0x73, 0x73,
+ 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x65, 0x69, 0x74, 0x68, 0x65, 0x72,
+ 0x20, 0x61, 0x20, 0x73, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x20, 0x61, 0x74,
+ 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x20, 0x74, 0x6f, 0x20, 0x63,
+ 0x6f, 0x75, 0x6e, 0x74, 0x20, 0x62, 0x79, 0x2c, 0x20, 0x6f, 0x72, 0x20,
+ 0x61, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x20, 0x74,
+ 0x68, 0x61, 0x74, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x73, 0x20,
+ 0x74, 0x68, 0x65, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x63, 0x72, 0x69,
+ 0x74, 0x65, 0x72, 0x69, 0x6f, 0x6e, 0x2e, 0x0a, 0x20, 0x20, 0x5f, 0x2e,
+ 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x42, 0x79, 0x20, 0x3d, 0x20, 0x66, 0x75,
+ 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x6f, 0x62, 0x6a, 0x2c, 0x20,
+ 0x76, 0x61, 0x6c, 0x75, 0x65, 0x2c, 0x20, 0x63, 0x6f, 0x6e, 0x74, 0x65,
+ 0x78, 0x74, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65,
+ 0x74, 0x75, 0x72, 0x6e, 0x20, 0x67, 0x72, 0x6f, 0x75, 0x70, 0x28, 0x6f,
+ 0x62, 0x6a, 0x2c, 0x20, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x2c, 0x20, 0x63,
+ 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x2c, 0x20, 0x66, 0x75, 0x6e, 0x63,
+ 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x2c,
+ 0x20, 0x6b, 0x65, 0x79, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x69, 0x66, 0x20, 0x28, 0x21, 0x5f, 0x2e, 0x68, 0x61, 0x73,
+ 0x28, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x2c, 0x20, 0x6b, 0x65, 0x79,
+ 0x29, 0x29, 0x20, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x5b, 0x6b, 0x65,
+ 0x79, 0x5d, 0x20, 0x3d, 0x20, 0x30, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x5b, 0x6b, 0x65, 0x79,
+ 0x5d, 0x2b, 0x2b, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x29, 0x3b,
+ 0x0a, 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20,
+ 0x55, 0x73, 0x65, 0x20, 0x61, 0x20, 0x63, 0x6f, 0x6d, 0x70, 0x61, 0x72,
+ 0x61, 0x74, 0x6f, 0x72, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f,
+ 0x6e, 0x20, 0x74, 0x6f, 0x20, 0x66, 0x69, 0x67, 0x75, 0x72, 0x65, 0x20,
+ 0x6f, 0x75, 0x74, 0x20, 0x74, 0x68, 0x65, 0x20, 0x73, 0x6d, 0x61, 0x6c,
+ 0x6c, 0x65, 0x73, 0x74, 0x20, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x20, 0x61,
+ 0x74, 0x20, 0x77, 0x68, 0x69, 0x63, 0x68, 0x0a, 0x20, 0x20, 0x2f, 0x2f,
+ 0x20, 0x61, 0x6e, 0x20, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, 0x73,
+ 0x68, 0x6f, 0x75, 0x6c, 0x64, 0x20, 0x62, 0x65, 0x20, 0x69, 0x6e, 0x73,
+ 0x65, 0x72, 0x74, 0x65, 0x64, 0x20, 0x73, 0x6f, 0x20, 0x61, 0x73, 0x20,
+ 0x74, 0x6f, 0x20, 0x6d, 0x61, 0x69, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x20,
+ 0x6f, 0x72, 0x64, 0x65, 0x72, 0x2e, 0x20, 0x55, 0x73, 0x65, 0x73, 0x20,
+ 0x62, 0x69, 0x6e, 0x61, 0x72, 0x79, 0x20, 0x73, 0x65, 0x61, 0x72, 0x63,
+ 0x68, 0x2e, 0x0a, 0x20, 0x20, 0x5f, 0x2e, 0x73, 0x6f, 0x72, 0x74, 0x65,
+ 0x64, 0x49, 0x6e, 0x64, 0x65, 0x78, 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e,
+ 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x61, 0x72, 0x72, 0x61, 0x79, 0x2c,
+ 0x20, 0x6f, 0x62, 0x6a, 0x2c, 0x20, 0x69, 0x74, 0x65, 0x72, 0x61, 0x74,
+ 0x6f, 0x72, 0x2c, 0x20, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x29,
+ 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x69, 0x74, 0x65, 0x72, 0x61,
+ 0x74, 0x6f, 0x72, 0x20, 0x3d, 0x20, 0x69, 0x74, 0x65, 0x72, 0x61, 0x74,
+ 0x6f, 0x72, 0x20, 0x3d, 0x3d, 0x20, 0x6e, 0x75, 0x6c, 0x6c, 0x20, 0x3f,
+ 0x20, 0x5f, 0x2e, 0x69, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x74, 0x79, 0x20,
+ 0x3a, 0x20, 0x6c, 0x6f, 0x6f, 0x6b, 0x75, 0x70, 0x49, 0x74, 0x65, 0x72,
+ 0x61, 0x74, 0x6f, 0x72, 0x28, 0x69, 0x74, 0x65, 0x72, 0x61, 0x74, 0x6f,
+ 0x72, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x76, 0x61, 0x72, 0x20,
+ 0x76, 0x61, 0x6c, 0x75, 0x65, 0x20, 0x3d, 0x20, 0x69, 0x74, 0x65, 0x72,
+ 0x61, 0x74, 0x6f, 0x72, 0x2e, 0x63, 0x61, 0x6c, 0x6c, 0x28, 0x63, 0x6f,
+ 0x6e, 0x74, 0x65, 0x78, 0x74, 0x2c, 0x20, 0x6f, 0x62, 0x6a, 0x29, 0x3b,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x76, 0x61, 0x72, 0x20, 0x6c, 0x6f, 0x77,
+ 0x20, 0x3d, 0x20, 0x30, 0x2c, 0x20, 0x68, 0x69, 0x67, 0x68, 0x20, 0x3d,
+ 0x20, 0x61, 0x72, 0x72, 0x61, 0x79, 0x2e, 0x6c, 0x65, 0x6e, 0x67, 0x74,
+ 0x68, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x77, 0x68, 0x69, 0x6c, 0x65,
+ 0x20, 0x28, 0x6c, 0x6f, 0x77, 0x20, 0x3c, 0x20, 0x68, 0x69, 0x67, 0x68,
+ 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x76, 0x61,
+ 0x72, 0x20, 0x6d, 0x69, 0x64, 0x20, 0x3d, 0x20, 0x28, 0x6c, 0x6f, 0x77,
+ 0x20, 0x2b, 0x20, 0x68, 0x69, 0x67, 0x68, 0x29, 0x20, 0x3e, 0x3e, 0x3e,
+ 0x20, 0x31, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x69, 0x74,
+ 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x2e, 0x63, 0x61, 0x6c, 0x6c, 0x28,
+ 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x2c, 0x20, 0x61, 0x72, 0x72,
+ 0x61, 0x79, 0x5b, 0x6d, 0x69, 0x64, 0x5d, 0x29, 0x20, 0x3c, 0x20, 0x76,
+ 0x61, 0x6c, 0x75, 0x65, 0x20, 0x3f, 0x20, 0x6c, 0x6f, 0x77, 0x20, 0x3d,
+ 0x20, 0x6d, 0x69, 0x64, 0x20, 0x2b, 0x20, 0x31, 0x20, 0x3a, 0x20, 0x68,
+ 0x69, 0x67, 0x68, 0x20, 0x3d, 0x20, 0x6d, 0x69, 0x64, 0x3b, 0x0a, 0x20,
+ 0x20, 0x20, 0x20, 0x7d, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74,
+ 0x75, 0x72, 0x6e, 0x20, 0x6c, 0x6f, 0x77, 0x3b, 0x0a, 0x20, 0x20, 0x7d,
+ 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x53, 0x61, 0x66, 0x65,
+ 0x6c, 0x79, 0x20, 0x63, 0x6f, 0x6e, 0x76, 0x65, 0x72, 0x74, 0x20, 0x61,
+ 0x6e, 0x79, 0x74, 0x68, 0x69, 0x6e, 0x67, 0x20, 0x69, 0x74, 0x65, 0x72,
+ 0x61, 0x62, 0x6c, 0x65, 0x20, 0x69, 0x6e, 0x74, 0x6f, 0x20, 0x61, 0x20,
+ 0x72, 0x65, 0x61, 0x6c, 0x2c, 0x20, 0x6c, 0x69, 0x76, 0x65, 0x20, 0x61,
+ 0x72, 0x72, 0x61, 0x79, 0x2e, 0x0a, 0x20, 0x20, 0x5f, 0x2e, 0x74, 0x6f,
+ 0x41, 0x72, 0x72, 0x61, 0x79, 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e, 0x63,
+ 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x6f, 0x62, 0x6a, 0x29, 0x20, 0x7b, 0x0a,
+ 0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20, 0x28, 0x21, 0x6f, 0x62, 0x6a,
+ 0x29, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x5b, 0x5d, 0x3b,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20, 0x28, 0x5f, 0x2e, 0x69,
+ 0x73, 0x41, 0x72, 0x72, 0x61, 0x79, 0x28, 0x6f, 0x62, 0x6a, 0x29, 0x29,
+ 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x73, 0x6c, 0x69, 0x63,
+ 0x65, 0x2e, 0x63, 0x61, 0x6c, 0x6c, 0x28, 0x6f, 0x62, 0x6a, 0x29, 0x3b,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20, 0x28, 0x6f, 0x62, 0x6a,
+ 0x2e, 0x6c, 0x65, 0x6e, 0x67, 0x74, 0x68, 0x20, 0x3d, 0x3d, 0x3d, 0x20,
+ 0x2b, 0x6f, 0x62, 0x6a, 0x2e, 0x6c, 0x65, 0x6e, 0x67, 0x74, 0x68, 0x29,
+ 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x5f, 0x2e, 0x6d, 0x61,
+ 0x70, 0x28, 0x6f, 0x62, 0x6a, 0x2c, 0x20, 0x5f, 0x2e, 0x69, 0x64, 0x65,
+ 0x6e, 0x74, 0x69, 0x74, 0x79, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x5f, 0x2e, 0x76, 0x61, 0x6c,
+ 0x75, 0x65, 0x73, 0x28, 0x6f, 0x62, 0x6a, 0x29, 0x3b, 0x0a, 0x20, 0x20,
+ 0x7d, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x52, 0x65, 0x74,
+ 0x75, 0x72, 0x6e, 0x20, 0x74, 0x68, 0x65, 0x20, 0x6e, 0x75, 0x6d, 0x62,
+ 0x65, 0x72, 0x20, 0x6f, 0x66, 0x20, 0x65, 0x6c, 0x65, 0x6d, 0x65, 0x6e,
+ 0x74, 0x73, 0x20, 0x69, 0x6e, 0x20, 0x61, 0x6e, 0x20, 0x6f, 0x62, 0x6a,
+ 0x65, 0x63, 0x74, 0x2e, 0x0a, 0x20, 0x20, 0x5f, 0x2e, 0x73, 0x69, 0x7a,
+ 0x65, 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e,
+ 0x28, 0x6f, 0x62, 0x6a, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x69, 0x66, 0x20, 0x28, 0x6f, 0x62, 0x6a, 0x20, 0x3d, 0x3d, 0x20, 0x6e,
+ 0x75, 0x6c, 0x6c, 0x29, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20,
+ 0x30, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72,
+ 0x6e, 0x20, 0x28, 0x6f, 0x62, 0x6a, 0x2e, 0x6c, 0x65, 0x6e, 0x67, 0x74,
+ 0x68, 0x20, 0x3d, 0x3d, 0x3d, 0x20, 0x2b, 0x6f, 0x62, 0x6a, 0x2e, 0x6c,
+ 0x65, 0x6e, 0x67, 0x74, 0x68, 0x29, 0x20, 0x3f, 0x20, 0x6f, 0x62, 0x6a,
+ 0x2e, 0x6c, 0x65, 0x6e, 0x67, 0x74, 0x68, 0x20, 0x3a, 0x20, 0x5f, 0x2e,
+ 0x6b, 0x65, 0x79, 0x73, 0x28, 0x6f, 0x62, 0x6a, 0x29, 0x2e, 0x6c, 0x65,
+ 0x6e, 0x67, 0x74, 0x68, 0x3b, 0x0a, 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x0a,
+ 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x41, 0x72, 0x72, 0x61, 0x79, 0x20, 0x46,
+ 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x0a, 0x20, 0x20, 0x2f,
+ 0x2f, 0x20, 0x2d, 0x2d, 0x2d, 0x2d, 0x2d, 0x2d, 0x2d, 0x2d, 0x2d, 0x2d,
+ 0x2d, 0x2d, 0x2d, 0x2d, 0x2d, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20,
+ 0x47, 0x65, 0x74, 0x20, 0x74, 0x68, 0x65, 0x20, 0x66, 0x69, 0x72, 0x73,
+ 0x74, 0x20, 0x65, 0x6c, 0x65, 0x6d, 0x65, 0x6e, 0x74, 0x20, 0x6f, 0x66,
+ 0x20, 0x61, 0x6e, 0x20, 0x61, 0x72, 0x72, 0x61, 0x79, 0x2e, 0x20, 0x50,
+ 0x61, 0x73, 0x73, 0x69, 0x6e, 0x67, 0x20, 0x2a, 0x2a, 0x6e, 0x2a, 0x2a,
+ 0x20, 0x77, 0x69, 0x6c, 0x6c, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e,
+ 0x20, 0x74, 0x68, 0x65, 0x20, 0x66, 0x69, 0x72, 0x73, 0x74, 0x20, 0x4e,
+ 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x73,
+ 0x20, 0x69, 0x6e, 0x20, 0x74, 0x68, 0x65, 0x20, 0x61, 0x72, 0x72, 0x61,
+ 0x79, 0x2e, 0x20, 0x41, 0x6c, 0x69, 0x61, 0x73, 0x65, 0x64, 0x20, 0x61,
+ 0x73, 0x20, 0x60, 0x68, 0x65, 0x61, 0x64, 0x60, 0x20, 0x61, 0x6e, 0x64,
+ 0x20, 0x60, 0x74, 0x61, 0x6b, 0x65, 0x60, 0x2e, 0x20, 0x54, 0x68, 0x65,
+ 0x20, 0x2a, 0x2a, 0x67, 0x75, 0x61, 0x72, 0x64, 0x2a, 0x2a, 0x20, 0x63,
+ 0x68, 0x65, 0x63, 0x6b, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x61, 0x6c,
+ 0x6c, 0x6f, 0x77, 0x73, 0x20, 0x69, 0x74, 0x20, 0x74, 0x6f, 0x20, 0x77,
+ 0x6f, 0x72, 0x6b, 0x20, 0x77, 0x69, 0x74, 0x68, 0x20, 0x60, 0x5f, 0x2e,
+ 0x6d, 0x61, 0x70, 0x60, 0x2e, 0x0a, 0x20, 0x20, 0x5f, 0x2e, 0x66, 0x69,
+ 0x72, 0x73, 0x74, 0x20, 0x3d, 0x20, 0x5f, 0x2e, 0x68, 0x65, 0x61, 0x64,
+ 0x20, 0x3d, 0x20, 0x5f, 0x2e, 0x74, 0x61, 0x6b, 0x65, 0x20, 0x3d, 0x20,
+ 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x61, 0x72, 0x72,
+ 0x61, 0x79, 0x2c, 0x20, 0x6e, 0x2c, 0x20, 0x67, 0x75, 0x61, 0x72, 0x64,
+ 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20, 0x28,
+ 0x61, 0x72, 0x72, 0x61, 0x79, 0x20, 0x3d, 0x3d, 0x20, 0x6e, 0x75, 0x6c,
+ 0x6c, 0x29, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x76, 0x6f,
+ 0x69, 0x64, 0x20, 0x30, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65,
+ 0x74, 0x75, 0x72, 0x6e, 0x20, 0x28, 0x6e, 0x20, 0x21, 0x3d, 0x20, 0x6e,
+ 0x75, 0x6c, 0x6c, 0x29, 0x20, 0x26, 0x26, 0x20, 0x21, 0x67, 0x75, 0x61,
+ 0x72, 0x64, 0x20, 0x3f, 0x20, 0x73, 0x6c, 0x69, 0x63, 0x65, 0x2e, 0x63,
+ 0x61, 0x6c, 0x6c, 0x28, 0x61, 0x72, 0x72, 0x61, 0x79, 0x2c, 0x20, 0x30,
+ 0x2c, 0x20, 0x6e, 0x29, 0x20, 0x3a, 0x20, 0x61, 0x72, 0x72, 0x61, 0x79,
+ 0x5b, 0x30, 0x5d, 0x3b, 0x0a, 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x0a, 0x20,
+ 0x20, 0x2f, 0x2f, 0x20, 0x52, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x73, 0x20,
+ 0x65, 0x76, 0x65, 0x72, 0x79, 0x74, 0x68, 0x69, 0x6e, 0x67, 0x20, 0x62,
+ 0x75, 0x74, 0x20, 0x74, 0x68, 0x65, 0x20, 0x6c, 0x61, 0x73, 0x74, 0x20,
+ 0x65, 0x6e, 0x74, 0x72, 0x79, 0x20, 0x6f, 0x66, 0x20, 0x74, 0x68, 0x65,
+ 0x20, 0x61, 0x72, 0x72, 0x61, 0x79, 0x2e, 0x20, 0x45, 0x73, 0x70, 0x65,
+ 0x63, 0x69, 0x61, 0x6c, 0x6c, 0x79, 0x20, 0x75, 0x73, 0x65, 0x66, 0x75,
+ 0x6c, 0x20, 0x6f, 0x6e, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x74, 0x68,
+ 0x65, 0x20, 0x61, 0x72, 0x67, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x20,
+ 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x2e, 0x20, 0x50, 0x61, 0x73, 0x73,
+ 0x69, 0x6e, 0x67, 0x20, 0x2a, 0x2a, 0x6e, 0x2a, 0x2a, 0x20, 0x77, 0x69,
+ 0x6c, 0x6c, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x61, 0x6c,
+ 0x6c, 0x20, 0x74, 0x68, 0x65, 0x20, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x73,
+ 0x20, 0x69, 0x6e, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x74, 0x68, 0x65,
+ 0x20, 0x61, 0x72, 0x72, 0x61, 0x79, 0x2c, 0x20, 0x65, 0x78, 0x63, 0x6c,
+ 0x75, 0x64, 0x69, 0x6e, 0x67, 0x20, 0x74, 0x68, 0x65, 0x20, 0x6c, 0x61,
+ 0x73, 0x74, 0x20, 0x4e, 0x2e, 0x20, 0x54, 0x68, 0x65, 0x20, 0x2a, 0x2a,
+ 0x67, 0x75, 0x61, 0x72, 0x64, 0x2a, 0x2a, 0x20, 0x63, 0x68, 0x65, 0x63,
+ 0x6b, 0x20, 0x61, 0x6c, 0x6c, 0x6f, 0x77, 0x73, 0x20, 0x69, 0x74, 0x20,
+ 0x74, 0x6f, 0x20, 0x77, 0x6f, 0x72, 0x6b, 0x20, 0x77, 0x69, 0x74, 0x68,
+ 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x60, 0x5f, 0x2e, 0x6d, 0x61, 0x70,
+ 0x60, 0x2e, 0x0a, 0x20, 0x20, 0x5f, 0x2e, 0x69, 0x6e, 0x69, 0x74, 0x69,
+ 0x61, 0x6c, 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f,
+ 0x6e, 0x28, 0x61, 0x72, 0x72, 0x61, 0x79, 0x2c, 0x20, 0x6e, 0x2c, 0x20,
+ 0x67, 0x75, 0x61, 0x72, 0x64, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20,
+ 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x73, 0x6c, 0x69, 0x63,
+ 0x65, 0x2e, 0x63, 0x61, 0x6c, 0x6c, 0x28, 0x61, 0x72, 0x72, 0x61, 0x79,
+ 0x2c, 0x20, 0x30, 0x2c, 0x20, 0x61, 0x72, 0x72, 0x61, 0x79, 0x2e, 0x6c,
+ 0x65, 0x6e, 0x67, 0x74, 0x68, 0x20, 0x2d, 0x20, 0x28, 0x28, 0x6e, 0x20,
+ 0x3d, 0x3d, 0x20, 0x6e, 0x75, 0x6c, 0x6c, 0x29, 0x20, 0x7c, 0x7c, 0x20,
+ 0x67, 0x75, 0x61, 0x72, 0x64, 0x20, 0x3f, 0x20, 0x31, 0x20, 0x3a, 0x20,
+ 0x6e, 0x29, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x0a, 0x20,
+ 0x20, 0x2f, 0x2f, 0x20, 0x47, 0x65, 0x74, 0x20, 0x74, 0x68, 0x65, 0x20,
+ 0x6c, 0x61, 0x73, 0x74, 0x20, 0x65, 0x6c, 0x65, 0x6d, 0x65, 0x6e, 0x74,
+ 0x20, 0x6f, 0x66, 0x20, 0x61, 0x6e, 0x20, 0x61, 0x72, 0x72, 0x61, 0x79,
+ 0x2e, 0x20, 0x50, 0x61, 0x73, 0x73, 0x69, 0x6e, 0x67, 0x20, 0x2a, 0x2a,
+ 0x6e, 0x2a, 0x2a, 0x20, 0x77, 0x69, 0x6c, 0x6c, 0x20, 0x72, 0x65, 0x74,
+ 0x75, 0x72, 0x6e, 0x20, 0x74, 0x68, 0x65, 0x20, 0x6c, 0x61, 0x73, 0x74,
+ 0x20, 0x4e, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x76, 0x61, 0x6c, 0x75,
+ 0x65, 0x73, 0x20, 0x69, 0x6e, 0x20, 0x74, 0x68, 0x65, 0x20, 0x61, 0x72,
+ 0x72, 0x61, 0x79, 0x2e, 0x20, 0x54, 0x68, 0x65, 0x20, 0x2a, 0x2a, 0x67,
+ 0x75, 0x61, 0x72, 0x64, 0x2a, 0x2a, 0x20, 0x63, 0x68, 0x65, 0x63, 0x6b,
+ 0x20, 0x61, 0x6c, 0x6c, 0x6f, 0x77, 0x73, 0x20, 0x69, 0x74, 0x20, 0x74,
+ 0x6f, 0x20, 0x77, 0x6f, 0x72, 0x6b, 0x20, 0x77, 0x69, 0x74, 0x68, 0x20,
+ 0x60, 0x5f, 0x2e, 0x6d, 0x61, 0x70, 0x60, 0x2e, 0x0a, 0x20, 0x20, 0x5f,
+ 0x2e, 0x6c, 0x61, 0x73, 0x74, 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e, 0x63,
+ 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x61, 0x72, 0x72, 0x61, 0x79, 0x2c, 0x20,
+ 0x6e, 0x2c, 0x20, 0x67, 0x75, 0x61, 0x72, 0x64, 0x29, 0x20, 0x7b, 0x0a,
+ 0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20, 0x28, 0x61, 0x72, 0x72, 0x61,
+ 0x79, 0x20, 0x3d, 0x3d, 0x20, 0x6e, 0x75, 0x6c, 0x6c, 0x29, 0x20, 0x72,
+ 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x76, 0x6f, 0x69, 0x64, 0x20, 0x30,
+ 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20, 0x28, 0x28, 0x6e,
+ 0x20, 0x21, 0x3d, 0x20, 0x6e, 0x75, 0x6c, 0x6c, 0x29, 0x20, 0x26, 0x26,
+ 0x20, 0x21, 0x67, 0x75, 0x61, 0x72, 0x64, 0x29, 0x20, 0x7b, 0x0a, 0x20,
+ 0x20, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20,
+ 0x73, 0x6c, 0x69, 0x63, 0x65, 0x2e, 0x63, 0x61, 0x6c, 0x6c, 0x28, 0x61,
+ 0x72, 0x72, 0x61, 0x79, 0x2c, 0x20, 0x4d, 0x61, 0x74, 0x68, 0x2e, 0x6d,
+ 0x61, 0x78, 0x28, 0x61, 0x72, 0x72, 0x61, 0x79, 0x2e, 0x6c, 0x65, 0x6e,
+ 0x67, 0x74, 0x68, 0x20, 0x2d, 0x20, 0x6e, 0x2c, 0x20, 0x30, 0x29, 0x29,
+ 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x20, 0x65, 0x6c, 0x73, 0x65,
+ 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74,
+ 0x75, 0x72, 0x6e, 0x20, 0x61, 0x72, 0x72, 0x61, 0x79, 0x5b, 0x61, 0x72,
+ 0x72, 0x61, 0x79, 0x2e, 0x6c, 0x65, 0x6e, 0x67, 0x74, 0x68, 0x20, 0x2d,
+ 0x20, 0x31, 0x5d, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x0a, 0x20,
+ 0x20, 0x7d, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x52, 0x65,
+ 0x74, 0x75, 0x72, 0x6e, 0x73, 0x20, 0x65, 0x76, 0x65, 0x72, 0x79, 0x74,
+ 0x68, 0x69, 0x6e, 0x67, 0x20, 0x62, 0x75, 0x74, 0x20, 0x74, 0x68, 0x65,
+ 0x20, 0x66, 0x69, 0x72, 0x73, 0x74, 0x20, 0x65, 0x6e, 0x74, 0x72, 0x79,
+ 0x20, 0x6f, 0x66, 0x20, 0x74, 0x68, 0x65, 0x20, 0x61, 0x72, 0x72, 0x61,
+ 0x79, 0x2e, 0x20, 0x41, 0x6c, 0x69, 0x61, 0x73, 0x65, 0x64, 0x20, 0x61,
+ 0x73, 0x20, 0x60, 0x74, 0x61, 0x69, 0x6c, 0x60, 0x20, 0x61, 0x6e, 0x64,
+ 0x20, 0x60, 0x64, 0x72, 0x6f, 0x70, 0x60, 0x2e, 0x0a, 0x20, 0x20, 0x2f,
+ 0x2f, 0x20, 0x45, 0x73, 0x70, 0x65, 0x63, 0x69, 0x61, 0x6c, 0x6c, 0x79,
+ 0x20, 0x75, 0x73, 0x65, 0x66, 0x75, 0x6c, 0x20, 0x6f, 0x6e, 0x20, 0x74,
+ 0x68, 0x65, 0x20, 0x61, 0x72, 0x67, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x73,
+ 0x20, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x2e, 0x20, 0x50, 0x61, 0x73,
+ 0x73, 0x69, 0x6e, 0x67, 0x20, 0x61, 0x6e, 0x20, 0x2a, 0x2a, 0x6e, 0x2a,
+ 0x2a, 0x20, 0x77, 0x69, 0x6c, 0x6c, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72,
+ 0x6e, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x74, 0x68, 0x65, 0x20, 0x72,
+ 0x65, 0x73, 0x74, 0x20, 0x4e, 0x20, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x73,
+ 0x20, 0x69, 0x6e, 0x20, 0x74, 0x68, 0x65, 0x20, 0x61, 0x72, 0x72, 0x61,
+ 0x79, 0x2e, 0x20, 0x54, 0x68, 0x65, 0x20, 0x2a, 0x2a, 0x67, 0x75, 0x61,
+ 0x72, 0x64, 0x2a, 0x2a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x63, 0x68,
+ 0x65, 0x63, 0x6b, 0x20, 0x61, 0x6c, 0x6c, 0x6f, 0x77, 0x73, 0x20, 0x69,
+ 0x74, 0x20, 0x74, 0x6f, 0x20, 0x77, 0x6f, 0x72, 0x6b, 0x20, 0x77, 0x69,
+ 0x74, 0x68, 0x20, 0x60, 0x5f, 0x2e, 0x6d, 0x61, 0x70, 0x60, 0x2e, 0x0a,
+ 0x20, 0x20, 0x5f, 0x2e, 0x72, 0x65, 0x73, 0x74, 0x20, 0x3d, 0x20, 0x5f,
+ 0x2e, 0x74, 0x61, 0x69, 0x6c, 0x20, 0x3d, 0x20, 0x5f, 0x2e, 0x64, 0x72,
+ 0x6f, 0x70, 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f,
+ 0x6e, 0x28, 0x61, 0x72, 0x72, 0x61, 0x79, 0x2c, 0x20, 0x6e, 0x2c, 0x20,
+ 0x67, 0x75, 0x61, 0x72, 0x64, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20,
+ 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x73, 0x6c, 0x69, 0x63,
+ 0x65, 0x2e, 0x63, 0x61, 0x6c, 0x6c, 0x28, 0x61, 0x72, 0x72, 0x61, 0x79,
+ 0x2c, 0x20, 0x28, 0x6e, 0x20, 0x3d, 0x3d, 0x20, 0x6e, 0x75, 0x6c, 0x6c,
+ 0x29, 0x20, 0x7c, 0x7c, 0x20, 0x67, 0x75, 0x61, 0x72, 0x64, 0x20, 0x3f,
+ 0x20, 0x31, 0x20, 0x3a, 0x20, 0x6e, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x7d,
+ 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x54, 0x72, 0x69, 0x6d,
+ 0x20, 0x6f, 0x75, 0x74, 0x20, 0x61, 0x6c, 0x6c, 0x20, 0x66, 0x61, 0x6c,
+ 0x73, 0x79, 0x20, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x73, 0x20, 0x66, 0x72,
+ 0x6f, 0x6d, 0x20, 0x61, 0x6e, 0x20, 0x61, 0x72, 0x72, 0x61, 0x79, 0x2e,
+ 0x0a, 0x20, 0x20, 0x5f, 0x2e, 0x63, 0x6f, 0x6d, 0x70, 0x61, 0x63, 0x74,
+ 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28,
+ 0x61, 0x72, 0x72, 0x61, 0x79, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20,
+ 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x5f, 0x2e, 0x66, 0x69,
+ 0x6c, 0x74, 0x65, 0x72, 0x28, 0x61, 0x72, 0x72, 0x61, 0x79, 0x2c, 0x20,
+ 0x5f, 0x2e, 0x69, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x74, 0x79, 0x29, 0x3b,
+ 0x0a, 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20,
+ 0x49, 0x6e, 0x74, 0x65, 0x72, 0x6e, 0x61, 0x6c, 0x20, 0x69, 0x6d, 0x70,
+ 0x6c, 0x65, 0x6d, 0x65, 0x6e, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x20,
+ 0x6f, 0x66, 0x20, 0x61, 0x20, 0x72, 0x65, 0x63, 0x75, 0x72, 0x73, 0x69,
+ 0x76, 0x65, 0x20, 0x60, 0x66, 0x6c, 0x61, 0x74, 0x74, 0x65, 0x6e, 0x60,
+ 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x0a, 0x20,
+ 0x20, 0x76, 0x61, 0x72, 0x20, 0x66, 0x6c, 0x61, 0x74, 0x74, 0x65, 0x6e,
+ 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28,
+ 0x69, 0x6e, 0x70, 0x75, 0x74, 0x2c, 0x20, 0x73, 0x68, 0x61, 0x6c, 0x6c,
+ 0x6f, 0x77, 0x2c, 0x20, 0x6f, 0x75, 0x74, 0x70, 0x75, 0x74, 0x29, 0x20,
+ 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x65, 0x61, 0x63, 0x68, 0x28, 0x69,
+ 0x6e, 0x70, 0x75, 0x74, 0x2c, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69,
+ 0x6f, 0x6e, 0x28, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x29, 0x20, 0x7b, 0x0a,
+ 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20, 0x28, 0x5f, 0x2e,
+ 0x69, 0x73, 0x41, 0x72, 0x72, 0x61, 0x79, 0x28, 0x76, 0x61, 0x6c, 0x75,
+ 0x65, 0x29, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x73, 0x68, 0x61, 0x6c, 0x6c, 0x6f, 0x77, 0x20, 0x3f, 0x20,
+ 0x70, 0x75, 0x73, 0x68, 0x2e, 0x61, 0x70, 0x70, 0x6c, 0x79, 0x28, 0x6f,
+ 0x75, 0x74, 0x70, 0x75, 0x74, 0x2c, 0x20, 0x76, 0x61, 0x6c, 0x75, 0x65,
+ 0x29, 0x20, 0x3a, 0x20, 0x66, 0x6c, 0x61, 0x74, 0x74, 0x65, 0x6e, 0x28,
+ 0x76, 0x61, 0x6c, 0x75, 0x65, 0x2c, 0x20, 0x73, 0x68, 0x61, 0x6c, 0x6c,
+ 0x6f, 0x77, 0x2c, 0x20, 0x6f, 0x75, 0x74, 0x70, 0x75, 0x74, 0x29, 0x3b,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x20, 0x65, 0x6c, 0x73,
+ 0x65, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x6f, 0x75, 0x74, 0x70, 0x75, 0x74, 0x2e, 0x70, 0x75, 0x73, 0x68, 0x28,
+ 0x76, 0x61, 0x6c, 0x75, 0x65, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x7d, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x29, 0x3b, 0x0a,
+ 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x6f,
+ 0x75, 0x74, 0x70, 0x75, 0x74, 0x3b, 0x0a, 0x20, 0x20, 0x7d, 0x3b, 0x0a,
+ 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x52, 0x65, 0x74, 0x75, 0x72, 0x6e,
+ 0x20, 0x61, 0x20, 0x63, 0x6f, 0x6d, 0x70, 0x6c, 0x65, 0x74, 0x65, 0x6c,
+ 0x79, 0x20, 0x66, 0x6c, 0x61, 0x74, 0x74, 0x65, 0x6e, 0x65, 0x64, 0x20,
+ 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x20, 0x6f, 0x66, 0x20, 0x61,
+ 0x6e, 0x20, 0x61, 0x72, 0x72, 0x61, 0x79, 0x2e, 0x0a, 0x20, 0x20, 0x5f,
+ 0x2e, 0x66, 0x6c, 0x61, 0x74, 0x74, 0x65, 0x6e, 0x20, 0x3d, 0x20, 0x66,
+ 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x61, 0x72, 0x72, 0x61,
+ 0x79, 0x2c, 0x20, 0x73, 0x68, 0x61, 0x6c, 0x6c, 0x6f, 0x77, 0x29, 0x20,
+ 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e,
+ 0x20, 0x66, 0x6c, 0x61, 0x74, 0x74, 0x65, 0x6e, 0x28, 0x61, 0x72, 0x72,
+ 0x61, 0x79, 0x2c, 0x20, 0x73, 0x68, 0x61, 0x6c, 0x6c, 0x6f, 0x77, 0x2c,
+ 0x20, 0x5b, 0x5d, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x0a,
+ 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x52, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20,
+ 0x61, 0x20, 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x20, 0x6f, 0x66,
+ 0x20, 0x74, 0x68, 0x65, 0x20, 0x61, 0x72, 0x72, 0x61, 0x79, 0x20, 0x74,
+ 0x68, 0x61, 0x74, 0x20, 0x64, 0x6f, 0x65, 0x73, 0x20, 0x6e, 0x6f, 0x74,
+ 0x20, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x20, 0x74, 0x68, 0x65,
+ 0x20, 0x73, 0x70, 0x65, 0x63, 0x69, 0x66, 0x69, 0x65, 0x64, 0x20, 0x76,
+ 0x61, 0x6c, 0x75, 0x65, 0x28, 0x73, 0x29, 0x2e, 0x0a, 0x20, 0x20, 0x5f,
+ 0x2e, 0x77, 0x69, 0x74, 0x68, 0x6f, 0x75, 0x74, 0x20, 0x3d, 0x20, 0x66,
+ 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x61, 0x72, 0x72, 0x61,
+ 0x79, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74,
+ 0x75, 0x72, 0x6e, 0x20, 0x5f, 0x2e, 0x64, 0x69, 0x66, 0x66, 0x65, 0x72,
+ 0x65, 0x6e, 0x63, 0x65, 0x28, 0x61, 0x72, 0x72, 0x61, 0x79, 0x2c, 0x20,
+ 0x73, 0x6c, 0x69, 0x63, 0x65, 0x2e, 0x63, 0x61, 0x6c, 0x6c, 0x28, 0x61,
+ 0x72, 0x67, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x2c, 0x20, 0x31, 0x29,
+ 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f,
+ 0x2f, 0x20, 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x65, 0x20, 0x61, 0x20,
+ 0x64, 0x75, 0x70, 0x6c, 0x69, 0x63, 0x61, 0x74, 0x65, 0x2d, 0x66, 0x72,
+ 0x65, 0x65, 0x20, 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x20, 0x6f,
+ 0x66, 0x20, 0x74, 0x68, 0x65, 0x20, 0x61, 0x72, 0x72, 0x61, 0x79, 0x2e,
+ 0x20, 0x49, 0x66, 0x20, 0x74, 0x68, 0x65, 0x20, 0x61, 0x72, 0x72, 0x61,
+ 0x79, 0x20, 0x68, 0x61, 0x73, 0x20, 0x61, 0x6c, 0x72, 0x65, 0x61, 0x64,
+ 0x79, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x62, 0x65, 0x65, 0x6e, 0x20,
+ 0x73, 0x6f, 0x72, 0x74, 0x65, 0x64, 0x2c, 0x20, 0x79, 0x6f, 0x75, 0x20,
+ 0x68, 0x61, 0x76, 0x65, 0x20, 0x74, 0x68, 0x65, 0x20, 0x6f, 0x70, 0x74,
+ 0x69, 0x6f, 0x6e, 0x20, 0x6f, 0x66, 0x20, 0x75, 0x73, 0x69, 0x6e, 0x67,
+ 0x20, 0x61, 0x20, 0x66, 0x61, 0x73, 0x74, 0x65, 0x72, 0x20, 0x61, 0x6c,
+ 0x67, 0x6f, 0x72, 0x69, 0x74, 0x68, 0x6d, 0x2e, 0x0a, 0x20, 0x20, 0x2f,
+ 0x2f, 0x20, 0x41, 0x6c, 0x69, 0x61, 0x73, 0x65, 0x64, 0x20, 0x61, 0x73,
+ 0x20, 0x60, 0x75, 0x6e, 0x69, 0x71, 0x75, 0x65, 0x60, 0x2e, 0x0a, 0x20,
+ 0x20, 0x5f, 0x2e, 0x75, 0x6e, 0x69, 0x71, 0x20, 0x3d, 0x20, 0x5f, 0x2e,
+ 0x75, 0x6e, 0x69, 0x71, 0x75, 0x65, 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e,
+ 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x61, 0x72, 0x72, 0x61, 0x79, 0x2c,
+ 0x20, 0x69, 0x73, 0x53, 0x6f, 0x72, 0x74, 0x65, 0x64, 0x2c, 0x20, 0x69,
+ 0x74, 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x2c, 0x20, 0x63, 0x6f, 0x6e,
+ 0x74, 0x65, 0x78, 0x74, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x69, 0x66, 0x20, 0x28, 0x5f, 0x2e, 0x69, 0x73, 0x46, 0x75, 0x6e, 0x63,
+ 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x69, 0x73, 0x53, 0x6f, 0x72, 0x74, 0x65,
+ 0x64, 0x29, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x20, 0x3d, 0x20, 0x69, 0x74,
+ 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x69, 0x74, 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x20, 0x3d,
+ 0x20, 0x69, 0x73, 0x53, 0x6f, 0x72, 0x74, 0x65, 0x64, 0x3b, 0x0a, 0x20,
+ 0x20, 0x20, 0x20, 0x20, 0x20, 0x69, 0x73, 0x53, 0x6f, 0x72, 0x74, 0x65,
+ 0x64, 0x20, 0x3d, 0x20, 0x66, 0x61, 0x6c, 0x73, 0x65, 0x3b, 0x0a, 0x20,
+ 0x20, 0x20, 0x20, 0x7d, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x76, 0x61, 0x72,
+ 0x20, 0x69, 0x6e, 0x69, 0x74, 0x69, 0x61, 0x6c, 0x20, 0x3d, 0x20, 0x69,
+ 0x74, 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x20, 0x3f, 0x20, 0x5f, 0x2e,
+ 0x6d, 0x61, 0x70, 0x28, 0x61, 0x72, 0x72, 0x61, 0x79, 0x2c, 0x20, 0x69,
+ 0x74, 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x2c, 0x20, 0x63, 0x6f, 0x6e,
+ 0x74, 0x65, 0x78, 0x74, 0x29, 0x20, 0x3a, 0x20, 0x61, 0x72, 0x72, 0x61,
+ 0x79, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x76, 0x61, 0x72, 0x20, 0x72,
+ 0x65, 0x73, 0x75, 0x6c, 0x74, 0x73, 0x20, 0x3d, 0x20, 0x5b, 0x5d, 0x3b,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x76, 0x61, 0x72, 0x20, 0x73, 0x65, 0x65,
+ 0x6e, 0x20, 0x3d, 0x20, 0x5b, 0x5d, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x65, 0x61, 0x63, 0x68, 0x28, 0x69, 0x6e, 0x69, 0x74, 0x69, 0x61, 0x6c,
+ 0x2c, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x76,
+ 0x61, 0x6c, 0x75, 0x65, 0x2c, 0x20, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x29,
+ 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20,
+ 0x28, 0x69, 0x73, 0x53, 0x6f, 0x72, 0x74, 0x65, 0x64, 0x20, 0x3f, 0x20,
+ 0x28, 0x21, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x20, 0x7c, 0x7c, 0x20, 0x73,
+ 0x65, 0x65, 0x6e, 0x5b, 0x73, 0x65, 0x65, 0x6e, 0x2e, 0x6c, 0x65, 0x6e,
+ 0x67, 0x74, 0x68, 0x20, 0x2d, 0x20, 0x31, 0x5d, 0x20, 0x21, 0x3d, 0x3d,
+ 0x20, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x29, 0x20, 0x3a, 0x20, 0x21, 0x5f,
+ 0x2e, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x73, 0x28, 0x73, 0x65,
+ 0x65, 0x6e, 0x2c, 0x20, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x29, 0x29, 0x20,
+ 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x73, 0x65,
+ 0x65, 0x6e, 0x2e, 0x70, 0x75, 0x73, 0x68, 0x28, 0x76, 0x61, 0x6c, 0x75,
+ 0x65, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x73, 0x2e, 0x70, 0x75, 0x73, 0x68,
+ 0x28, 0x61, 0x72, 0x72, 0x61, 0x79, 0x5b, 0x69, 0x6e, 0x64, 0x65, 0x78,
+ 0x5d, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x0a,
+ 0x20, 0x20, 0x20, 0x20, 0x7d, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x72, 0x65, 0x73, 0x75, 0x6c,
+ 0x74, 0x73, 0x3b, 0x0a, 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x0a, 0x20, 0x20,
+ 0x2f, 0x2f, 0x20, 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63, 0x65, 0x20, 0x61,
+ 0x6e, 0x20, 0x61, 0x72, 0x72, 0x61, 0x79, 0x20, 0x74, 0x68, 0x61, 0x74,
+ 0x20, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x73, 0x20, 0x74, 0x68,
+ 0x65, 0x20, 0x75, 0x6e, 0x69, 0x6f, 0x6e, 0x3a, 0x20, 0x65, 0x61, 0x63,
+ 0x68, 0x20, 0x64, 0x69, 0x73, 0x74, 0x69, 0x6e, 0x63, 0x74, 0x20, 0x65,
+ 0x6c, 0x65, 0x6d, 0x65, 0x6e, 0x74, 0x20, 0x66, 0x72, 0x6f, 0x6d, 0x20,
+ 0x61, 0x6c, 0x6c, 0x20, 0x6f, 0x66, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20,
+ 0x74, 0x68, 0x65, 0x20, 0x70, 0x61, 0x73, 0x73, 0x65, 0x64, 0x2d, 0x69,
+ 0x6e, 0x20, 0x61, 0x72, 0x72, 0x61, 0x79, 0x73, 0x2e, 0x0a, 0x20, 0x20,
+ 0x5f, 0x2e, 0x75, 0x6e, 0x69, 0x6f, 0x6e, 0x20, 0x3d, 0x20, 0x66, 0x75,
+ 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x29, 0x20, 0x7b, 0x0a, 0x20,
+ 0x20, 0x20, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x5f, 0x2e,
+ 0x75, 0x6e, 0x69, 0x71, 0x28, 0x63, 0x6f, 0x6e, 0x63, 0x61, 0x74, 0x2e,
+ 0x61, 0x70, 0x70, 0x6c, 0x79, 0x28, 0x41, 0x72, 0x72, 0x61, 0x79, 0x50,
+ 0x72, 0x6f, 0x74, 0x6f, 0x2c, 0x20, 0x61, 0x72, 0x67, 0x75, 0x6d, 0x65,
+ 0x6e, 0x74, 0x73, 0x29, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x7d, 0x3b, 0x0a,
+ 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x50, 0x72, 0x6f, 0x64, 0x75, 0x63,
+ 0x65, 0x20, 0x61, 0x6e, 0x20, 0x61, 0x72, 0x72, 0x61, 0x79, 0x20, 0x74,
+ 0x68, 0x61, 0x74, 0x20, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x73,
+ 0x20, 0x65, 0x76, 0x65, 0x72, 0x79, 0x20, 0x69, 0x74, 0x65, 0x6d, 0x20,
+ 0x73, 0x68, 0x61, 0x72, 0x65, 0x64, 0x20, 0x62, 0x65, 0x74, 0x77, 0x65,
+ 0x65, 0x6e, 0x20, 0x61, 0x6c, 0x6c, 0x20, 0x74, 0x68, 0x65, 0x0a, 0x20,
+ 0x20, 0x2f, 0x2f, 0x20, 0x70, 0x61, 0x73, 0x73, 0x65, 0x64, 0x2d, 0x69,
+ 0x6e, 0x20, 0x61, 0x72, 0x72, 0x61, 0x79, 0x73, 0x2e, 0x0a, 0x20, 0x20,
+ 0x5f, 0x2e, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x73, 0x65, 0x63, 0x74, 0x69,
+ 0x6f, 0x6e, 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f,
+ 0x6e, 0x28, 0x61, 0x72, 0x72, 0x61, 0x79, 0x29, 0x20, 0x7b, 0x0a, 0x20,
+ 0x20, 0x20, 0x20, 0x76, 0x61, 0x72, 0x20, 0x72, 0x65, 0x73, 0x74, 0x20,
+ 0x3d, 0x20, 0x73, 0x6c, 0x69, 0x63, 0x65, 0x2e, 0x63, 0x61, 0x6c, 0x6c,
+ 0x28, 0x61, 0x72, 0x67, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x2c, 0x20,
+ 0x31, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74, 0x75,
+ 0x72, 0x6e, 0x20, 0x5f, 0x2e, 0x66, 0x69, 0x6c, 0x74, 0x65, 0x72, 0x28,
+ 0x5f, 0x2e, 0x75, 0x6e, 0x69, 0x71, 0x28, 0x61, 0x72, 0x72, 0x61, 0x79,
+ 0x29, 0x2c, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28,
+ 0x69, 0x74, 0x65, 0x6d, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x5f, 0x2e, 0x65,
+ 0x76, 0x65, 0x72, 0x79, 0x28, 0x72, 0x65, 0x73, 0x74, 0x2c, 0x20, 0x66,
+ 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x6f, 0x74, 0x68, 0x65,
+ 0x72, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x5f, 0x2e, 0x69, 0x6e,
+ 0x64, 0x65, 0x78, 0x4f, 0x66, 0x28, 0x6f, 0x74, 0x68, 0x65, 0x72, 0x2c,
+ 0x20, 0x69, 0x74, 0x65, 0x6d, 0x29, 0x20, 0x3e, 0x3d, 0x20, 0x30, 0x3b,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x29, 0x3b, 0x0a, 0x20,
+ 0x20, 0x20, 0x20, 0x7d, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x7d, 0x3b, 0x0a,
+ 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x54, 0x61, 0x6b, 0x65, 0x20, 0x74,
+ 0x68, 0x65, 0x20, 0x64, 0x69, 0x66, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63,
+ 0x65, 0x20, 0x62, 0x65, 0x74, 0x77, 0x65, 0x65, 0x6e, 0x20, 0x6f, 0x6e,
+ 0x65, 0x20, 0x61, 0x72, 0x72, 0x61, 0x79, 0x20, 0x61, 0x6e, 0x64, 0x20,
+ 0x61, 0x20, 0x6e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x20, 0x6f, 0x66, 0x20,
+ 0x6f, 0x74, 0x68, 0x65, 0x72, 0x20, 0x61, 0x72, 0x72, 0x61, 0x79, 0x73,
+ 0x2e, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x4f, 0x6e, 0x6c, 0x79, 0x20,
+ 0x74, 0x68, 0x65, 0x20, 0x65, 0x6c, 0x65, 0x6d, 0x65, 0x6e, 0x74, 0x73,
+ 0x20, 0x70, 0x72, 0x65, 0x73, 0x65, 0x6e, 0x74, 0x20, 0x69, 0x6e, 0x20,
+ 0x6a, 0x75, 0x73, 0x74, 0x20, 0x74, 0x68, 0x65, 0x20, 0x66, 0x69, 0x72,
+ 0x73, 0x74, 0x20, 0x61, 0x72, 0x72, 0x61, 0x79, 0x20, 0x77, 0x69, 0x6c,
+ 0x6c, 0x20, 0x72, 0x65, 0x6d, 0x61, 0x69, 0x6e, 0x2e, 0x0a, 0x20, 0x20,
+ 0x5f, 0x2e, 0x64, 0x69, 0x66, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65,
+ 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28,
+ 0x61, 0x72, 0x72, 0x61, 0x79, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20,
+ 0x20, 0x76, 0x61, 0x72, 0x20, 0x72, 0x65, 0x73, 0x74, 0x20, 0x3d, 0x20,
+ 0x63, 0x6f, 0x6e, 0x63, 0x61, 0x74, 0x2e, 0x61, 0x70, 0x70, 0x6c, 0x79,
+ 0x28, 0x41, 0x72, 0x72, 0x61, 0x79, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x2c,
+ 0x20, 0x73, 0x6c, 0x69, 0x63, 0x65, 0x2e, 0x63, 0x61, 0x6c, 0x6c, 0x28,
+ 0x61, 0x72, 0x67, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x2c, 0x20, 0x31,
+ 0x29, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74, 0x75,
+ 0x72, 0x6e, 0x20, 0x5f, 0x2e, 0x66, 0x69, 0x6c, 0x74, 0x65, 0x72, 0x28,
+ 0x61, 0x72, 0x72, 0x61, 0x79, 0x2c, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74,
+ 0x69, 0x6f, 0x6e, 0x28, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x29, 0x7b, 0x20,
+ 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x21, 0x5f, 0x2e, 0x63, 0x6f,
+ 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x73, 0x28, 0x72, 0x65, 0x73, 0x74, 0x2c,
+ 0x20, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x29, 0x3b, 0x20, 0x7d, 0x29, 0x3b,
+ 0x0a, 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20,
+ 0x5a, 0x69, 0x70, 0x20, 0x74, 0x6f, 0x67, 0x65, 0x74, 0x68, 0x65, 0x72,
+ 0x20, 0x6d, 0x75, 0x6c, 0x74, 0x69, 0x70, 0x6c, 0x65, 0x20, 0x6c, 0x69,
+ 0x73, 0x74, 0x73, 0x20, 0x69, 0x6e, 0x74, 0x6f, 0x20, 0x61, 0x20, 0x73,
+ 0x69, 0x6e, 0x67, 0x6c, 0x65, 0x20, 0x61, 0x72, 0x72, 0x61, 0x79, 0x20,
+ 0x2d, 0x2d, 0x20, 0x65, 0x6c, 0x65, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x20,
+ 0x74, 0x68, 0x61, 0x74, 0x20, 0x73, 0x68, 0x61, 0x72, 0x65, 0x0a, 0x20,
+ 0x20, 0x2f, 0x2f, 0x20, 0x61, 0x6e, 0x20, 0x69, 0x6e, 0x64, 0x65, 0x78,
+ 0x20, 0x67, 0x6f, 0x20, 0x74, 0x6f, 0x67, 0x65, 0x74, 0x68, 0x65, 0x72,
+ 0x2e, 0x0a, 0x20, 0x20, 0x5f, 0x2e, 0x7a, 0x69, 0x70, 0x20, 0x3d, 0x20,
+ 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x29, 0x20, 0x7b,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x76, 0x61, 0x72, 0x20, 0x61, 0x72, 0x67,
+ 0x73, 0x20, 0x3d, 0x20, 0x73, 0x6c, 0x69, 0x63, 0x65, 0x2e, 0x63, 0x61,
+ 0x6c, 0x6c, 0x28, 0x61, 0x72, 0x67, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x73,
+ 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x76, 0x61, 0x72, 0x20, 0x6c,
+ 0x65, 0x6e, 0x67, 0x74, 0x68, 0x20, 0x3d, 0x20, 0x5f, 0x2e, 0x6d, 0x61,
+ 0x78, 0x28, 0x5f, 0x2e, 0x70, 0x6c, 0x75, 0x63, 0x6b, 0x28, 0x61, 0x72,
+ 0x67, 0x73, 0x2c, 0x20, 0x27, 0x6c, 0x65, 0x6e, 0x67, 0x74, 0x68, 0x27,
+ 0x29, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x76, 0x61, 0x72, 0x20,
+ 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x73, 0x20, 0x3d, 0x20, 0x6e, 0x65,
+ 0x77, 0x20, 0x41, 0x72, 0x72, 0x61, 0x79, 0x28, 0x6c, 0x65, 0x6e, 0x67,
+ 0x74, 0x68, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x66, 0x6f, 0x72,
+ 0x20, 0x28, 0x76, 0x61, 0x72, 0x20, 0x69, 0x20, 0x3d, 0x20, 0x30, 0x3b,
+ 0x20, 0x69, 0x20, 0x3c, 0x20, 0x6c, 0x65, 0x6e, 0x67, 0x74, 0x68, 0x3b,
+ 0x20, 0x69, 0x2b, 0x2b, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x73, 0x5b, 0x69, 0x5d,
+ 0x20, 0x3d, 0x20, 0x5f, 0x2e, 0x70, 0x6c, 0x75, 0x63, 0x6b, 0x28, 0x61,
+ 0x72, 0x67, 0x73, 0x2c, 0x20, 0x22, 0x22, 0x20, 0x2b, 0x20, 0x69, 0x29,
+ 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x72, 0x65, 0x73, 0x75, 0x6c,
+ 0x74, 0x73, 0x3b, 0x0a, 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x0a, 0x20, 0x20,
+ 0x2f, 0x2f, 0x20, 0x43, 0x6f, 0x6e, 0x76, 0x65, 0x72, 0x74, 0x73, 0x20,
+ 0x6c, 0x69, 0x73, 0x74, 0x73, 0x20, 0x69, 0x6e, 0x74, 0x6f, 0x20, 0x6f,
+ 0x62, 0x6a, 0x65, 0x63, 0x74, 0x73, 0x2e, 0x20, 0x50, 0x61, 0x73, 0x73,
+ 0x20, 0x65, 0x69, 0x74, 0x68, 0x65, 0x72, 0x20, 0x61, 0x20, 0x73, 0x69,
+ 0x6e, 0x67, 0x6c, 0x65, 0x20, 0x61, 0x72, 0x72, 0x61, 0x79, 0x20, 0x6f,
+ 0x66, 0x20, 0x60, 0x5b, 0x6b, 0x65, 0x79, 0x2c, 0x20, 0x76, 0x61, 0x6c,
+ 0x75, 0x65, 0x5d, 0x60, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x70, 0x61,
+ 0x69, 0x72, 0x73, 0x2c, 0x20, 0x6f, 0x72, 0x20, 0x74, 0x77, 0x6f, 0x20,
+ 0x70, 0x61, 0x72, 0x61, 0x6c, 0x6c, 0x65, 0x6c, 0x20, 0x61, 0x72, 0x72,
+ 0x61, 0x79, 0x73, 0x20, 0x6f, 0x66, 0x20, 0x74, 0x68, 0x65, 0x20, 0x73,
+ 0x61, 0x6d, 0x65, 0x20, 0x6c, 0x65, 0x6e, 0x67, 0x74, 0x68, 0x20, 0x2d,
+ 0x2d, 0x20, 0x6f, 0x6e, 0x65, 0x20, 0x6f, 0x66, 0x20, 0x6b, 0x65, 0x79,
+ 0x73, 0x2c, 0x20, 0x61, 0x6e, 0x64, 0x20, 0x6f, 0x6e, 0x65, 0x20, 0x6f,
+ 0x66, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x74, 0x68, 0x65, 0x20, 0x63,
+ 0x6f, 0x72, 0x72, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x64, 0x69, 0x6e, 0x67,
+ 0x20, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x73, 0x2e, 0x0a, 0x20, 0x20, 0x5f,
+ 0x2e, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, 0x3d, 0x20, 0x66, 0x75,
+ 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x6c, 0x69, 0x73, 0x74, 0x2c,
+ 0x20, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x73, 0x29, 0x20, 0x7b, 0x0a, 0x20,
+ 0x20, 0x20, 0x20, 0x69, 0x66, 0x20, 0x28, 0x6c, 0x69, 0x73, 0x74, 0x20,
+ 0x3d, 0x3d, 0x20, 0x6e, 0x75, 0x6c, 0x6c, 0x29, 0x20, 0x72, 0x65, 0x74,
+ 0x75, 0x72, 0x6e, 0x20, 0x7b, 0x7d, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x76, 0x61, 0x72, 0x20, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x20, 0x3d,
+ 0x20, 0x7b, 0x7d, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x66, 0x6f, 0x72,
+ 0x20, 0x28, 0x76, 0x61, 0x72, 0x20, 0x69, 0x20, 0x3d, 0x20, 0x30, 0x2c,
+ 0x20, 0x6c, 0x20, 0x3d, 0x20, 0x6c, 0x69, 0x73, 0x74, 0x2e, 0x6c, 0x65,
+ 0x6e, 0x67, 0x74, 0x68, 0x3b, 0x20, 0x69, 0x20, 0x3c, 0x20, 0x6c, 0x3b,
+ 0x20, 0x69, 0x2b, 0x2b, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x69, 0x66, 0x20, 0x28, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x73,
+ 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x5b, 0x6c, 0x69, 0x73, 0x74, 0x5b,
+ 0x69, 0x5d, 0x5d, 0x20, 0x3d, 0x20, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x73,
+ 0x5b, 0x69, 0x5d, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7d,
+ 0x20, 0x65, 0x6c, 0x73, 0x65, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x5b, 0x6c,
+ 0x69, 0x73, 0x74, 0x5b, 0x69, 0x5d, 0x5b, 0x30, 0x5d, 0x5d, 0x20, 0x3d,
+ 0x20, 0x6c, 0x69, 0x73, 0x74, 0x5b, 0x69, 0x5d, 0x5b, 0x31, 0x5d, 0x3b,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x0a, 0x20, 0x20, 0x20,
+ 0x20, 0x7d, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72,
+ 0x6e, 0x20, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x3b, 0x0a, 0x20, 0x20,
+ 0x7d, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x49, 0x66, 0x20,
+ 0x74, 0x68, 0x65, 0x20, 0x62, 0x72, 0x6f, 0x77, 0x73, 0x65, 0x72, 0x20,
+ 0x64, 0x6f, 0x65, 0x73, 0x6e, 0x27, 0x74, 0x20, 0x73, 0x75, 0x70, 0x70,
+ 0x6c, 0x79, 0x20, 0x75, 0x73, 0x20, 0x77, 0x69, 0x74, 0x68, 0x20, 0x69,
+ 0x6e, 0x64, 0x65, 0x78, 0x4f, 0x66, 0x20, 0x28, 0x49, 0x27, 0x6d, 0x20,
+ 0x6c, 0x6f, 0x6f, 0x6b, 0x69, 0x6e, 0x67, 0x20, 0x61, 0x74, 0x20, 0x79,
+ 0x6f, 0x75, 0x2c, 0x20, 0x2a, 0x2a, 0x4d, 0x53, 0x49, 0x45, 0x2a, 0x2a,
+ 0x29, 0x2c, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x77, 0x65, 0x20, 0x6e,
+ 0x65, 0x65, 0x64, 0x20, 0x74, 0x68, 0x69, 0x73, 0x20, 0x66, 0x75, 0x6e,
+ 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x20, 0x52, 0x65, 0x74, 0x75, 0x72,
+ 0x6e, 0x20, 0x74, 0x68, 0x65, 0x20, 0x70, 0x6f, 0x73, 0x69, 0x74, 0x69,
+ 0x6f, 0x6e, 0x20, 0x6f, 0x66, 0x20, 0x74, 0x68, 0x65, 0x20, 0x66, 0x69,
+ 0x72, 0x73, 0x74, 0x20, 0x6f, 0x63, 0x63, 0x75, 0x72, 0x72, 0x65, 0x6e,
+ 0x63, 0x65, 0x20, 0x6f, 0x66, 0x20, 0x61, 0x6e, 0x0a, 0x20, 0x20, 0x2f,
+ 0x2f, 0x20, 0x69, 0x74, 0x65, 0x6d, 0x20, 0x69, 0x6e, 0x20, 0x61, 0x6e,
+ 0x20, 0x61, 0x72, 0x72, 0x61, 0x79, 0x2c, 0x20, 0x6f, 0x72, 0x20, 0x2d,
+ 0x31, 0x20, 0x69, 0x66, 0x20, 0x74, 0x68, 0x65, 0x20, 0x69, 0x74, 0x65,
+ 0x6d, 0x20, 0x69, 0x73, 0x20, 0x6e, 0x6f, 0x74, 0x20, 0x69, 0x6e, 0x63,
+ 0x6c, 0x75, 0x64, 0x65, 0x64, 0x20, 0x69, 0x6e, 0x20, 0x74, 0x68, 0x65,
+ 0x20, 0x61, 0x72, 0x72, 0x61, 0x79, 0x2e, 0x0a, 0x20, 0x20, 0x2f, 0x2f,
+ 0x20, 0x44, 0x65, 0x6c, 0x65, 0x67, 0x61, 0x74, 0x65, 0x73, 0x20, 0x74,
+ 0x6f, 0x20, 0x2a, 0x2a, 0x45, 0x43, 0x4d, 0x41, 0x53, 0x63, 0x72, 0x69,
+ 0x70, 0x74, 0x20, 0x35, 0x2a, 0x2a, 0x27, 0x73, 0x20, 0x6e, 0x61, 0x74,
+ 0x69, 0x76, 0x65, 0x20, 0x60, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x4f, 0x66,
+ 0x60, 0x20, 0x69, 0x66, 0x20, 0x61, 0x76, 0x61, 0x69, 0x6c, 0x61, 0x62,
+ 0x6c, 0x65, 0x2e, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x49, 0x66, 0x20,
+ 0x74, 0x68, 0x65, 0x20, 0x61, 0x72, 0x72, 0x61, 0x79, 0x20, 0x69, 0x73,
+ 0x20, 0x6c, 0x61, 0x72, 0x67, 0x65, 0x20, 0x61, 0x6e, 0x64, 0x20, 0x61,
+ 0x6c, 0x72, 0x65, 0x61, 0x64, 0x79, 0x20, 0x69, 0x6e, 0x20, 0x73, 0x6f,
+ 0x72, 0x74, 0x20, 0x6f, 0x72, 0x64, 0x65, 0x72, 0x2c, 0x20, 0x70, 0x61,
+ 0x73, 0x73, 0x20, 0x60, 0x74, 0x72, 0x75, 0x65, 0x60, 0x0a, 0x20, 0x20,
+ 0x2f, 0x2f, 0x20, 0x66, 0x6f, 0x72, 0x20, 0x2a, 0x2a, 0x69, 0x73, 0x53,
+ 0x6f, 0x72, 0x74, 0x65, 0x64, 0x2a, 0x2a, 0x20, 0x74, 0x6f, 0x20, 0x75,
+ 0x73, 0x65, 0x20, 0x62, 0x69, 0x6e, 0x61, 0x72, 0x79, 0x20, 0x73, 0x65,
+ 0x61, 0x72, 0x63, 0x68, 0x2e, 0x0a, 0x20, 0x20, 0x5f, 0x2e, 0x69, 0x6e,
+ 0x64, 0x65, 0x78, 0x4f, 0x66, 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e, 0x63,
+ 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x61, 0x72, 0x72, 0x61, 0x79, 0x2c, 0x20,
+ 0x69, 0x74, 0x65, 0x6d, 0x2c, 0x20, 0x69, 0x73, 0x53, 0x6f, 0x72, 0x74,
+ 0x65, 0x64, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66,
+ 0x20, 0x28, 0x61, 0x72, 0x72, 0x61, 0x79, 0x20, 0x3d, 0x3d, 0x20, 0x6e,
+ 0x75, 0x6c, 0x6c, 0x29, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20,
+ 0x2d, 0x31, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x76, 0x61, 0x72, 0x20,
+ 0x69, 0x20, 0x3d, 0x20, 0x30, 0x2c, 0x20, 0x6c, 0x20, 0x3d, 0x20, 0x61,
+ 0x72, 0x72, 0x61, 0x79, 0x2e, 0x6c, 0x65, 0x6e, 0x67, 0x74, 0x68, 0x3b,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20, 0x28, 0x69, 0x73, 0x53,
+ 0x6f, 0x72, 0x74, 0x65, 0x64, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x20, 0x69, 0x66, 0x20, 0x28, 0x74, 0x79, 0x70, 0x65, 0x6f,
+ 0x66, 0x20, 0x69, 0x73, 0x53, 0x6f, 0x72, 0x74, 0x65, 0x64, 0x20, 0x3d,
+ 0x3d, 0x20, 0x27, 0x6e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x27, 0x29, 0x20,
+ 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x69, 0x20,
+ 0x3d, 0x20, 0x28, 0x69, 0x73, 0x53, 0x6f, 0x72, 0x74, 0x65, 0x64, 0x20,
+ 0x3c, 0x20, 0x30, 0x20, 0x3f, 0x20, 0x4d, 0x61, 0x74, 0x68, 0x2e, 0x6d,
+ 0x61, 0x78, 0x28, 0x30, 0x2c, 0x20, 0x6c, 0x20, 0x2b, 0x20, 0x69, 0x73,
+ 0x53, 0x6f, 0x72, 0x74, 0x65, 0x64, 0x29, 0x20, 0x3a, 0x20, 0x69, 0x73,
+ 0x53, 0x6f, 0x72, 0x74, 0x65, 0x64, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x20, 0x7d, 0x20, 0x65, 0x6c, 0x73, 0x65, 0x20, 0x7b, 0x0a,
+ 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x69, 0x20, 0x3d, 0x20,
+ 0x5f, 0x2e, 0x73, 0x6f, 0x72, 0x74, 0x65, 0x64, 0x49, 0x6e, 0x64, 0x65,
+ 0x78, 0x28, 0x61, 0x72, 0x72, 0x61, 0x79, 0x2c, 0x20, 0x69, 0x74, 0x65,
+ 0x6d, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x61, 0x72, 0x72, 0x61, 0x79,
+ 0x5b, 0x69, 0x5d, 0x20, 0x3d, 0x3d, 0x3d, 0x20, 0x69, 0x74, 0x65, 0x6d,
+ 0x20, 0x3f, 0x20, 0x69, 0x20, 0x3a, 0x20, 0x2d, 0x31, 0x3b, 0x0a, 0x20,
+ 0x20, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x7d,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20, 0x28, 0x6e, 0x61, 0x74,
+ 0x69, 0x76, 0x65, 0x49, 0x6e, 0x64, 0x65, 0x78, 0x4f, 0x66, 0x20, 0x26,
+ 0x26, 0x20, 0x61, 0x72, 0x72, 0x61, 0x79, 0x2e, 0x69, 0x6e, 0x64, 0x65,
+ 0x78, 0x4f, 0x66, 0x20, 0x3d, 0x3d, 0x3d, 0x20, 0x6e, 0x61, 0x74, 0x69,
+ 0x76, 0x65, 0x49, 0x6e, 0x64, 0x65, 0x78, 0x4f, 0x66, 0x29, 0x20, 0x72,
+ 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x61, 0x72, 0x72, 0x61, 0x79, 0x2e,
+ 0x69, 0x6e, 0x64, 0x65, 0x78, 0x4f, 0x66, 0x28, 0x69, 0x74, 0x65, 0x6d,
+ 0x2c, 0x20, 0x69, 0x73, 0x53, 0x6f, 0x72, 0x74, 0x65, 0x64, 0x29, 0x3b,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x66, 0x6f, 0x72, 0x20, 0x28, 0x3b, 0x20,
+ 0x69, 0x20, 0x3c, 0x20, 0x6c, 0x3b, 0x20, 0x69, 0x2b, 0x2b, 0x29, 0x20,
+ 0x69, 0x66, 0x20, 0x28, 0x61, 0x72, 0x72, 0x61, 0x79, 0x5b, 0x69, 0x5d,
+ 0x20, 0x3d, 0x3d, 0x3d, 0x20, 0x69, 0x74, 0x65, 0x6d, 0x29, 0x20, 0x72,
+ 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x69, 0x3b, 0x0a, 0x20, 0x20, 0x20,
+ 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x2d, 0x31, 0x3b, 0x0a,
+ 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x44,
+ 0x65, 0x6c, 0x65, 0x67, 0x61, 0x74, 0x65, 0x73, 0x20, 0x74, 0x6f, 0x20,
+ 0x2a, 0x2a, 0x45, 0x43, 0x4d, 0x41, 0x53, 0x63, 0x72, 0x69, 0x70, 0x74,
+ 0x20, 0x35, 0x2a, 0x2a, 0x27, 0x73, 0x20, 0x6e, 0x61, 0x74, 0x69, 0x76,
+ 0x65, 0x20, 0x60, 0x6c, 0x61, 0x73, 0x74, 0x49, 0x6e, 0x64, 0x65, 0x78,
+ 0x4f, 0x66, 0x60, 0x20, 0x69, 0x66, 0x20, 0x61, 0x76, 0x61, 0x69, 0x6c,
+ 0x61, 0x62, 0x6c, 0x65, 0x2e, 0x0a, 0x20, 0x20, 0x5f, 0x2e, 0x6c, 0x61,
+ 0x73, 0x74, 0x49, 0x6e, 0x64, 0x65, 0x78, 0x4f, 0x66, 0x20, 0x3d, 0x20,
+ 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x61, 0x72, 0x72,
+ 0x61, 0x79, 0x2c, 0x20, 0x69, 0x74, 0x65, 0x6d, 0x2c, 0x20, 0x66, 0x72,
+ 0x6f, 0x6d, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66,
+ 0x20, 0x28, 0x61, 0x72, 0x72, 0x61, 0x79, 0x20, 0x3d, 0x3d, 0x20, 0x6e,
+ 0x75, 0x6c, 0x6c, 0x29, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20,
+ 0x2d, 0x31, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x76, 0x61, 0x72, 0x20,
+ 0x68, 0x61, 0x73, 0x49, 0x6e, 0x64, 0x65, 0x78, 0x20, 0x3d, 0x20, 0x66,
+ 0x72, 0x6f, 0x6d, 0x20, 0x21, 0x3d, 0x20, 0x6e, 0x75, 0x6c, 0x6c, 0x3b,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20, 0x28, 0x6e, 0x61, 0x74,
+ 0x69, 0x76, 0x65, 0x4c, 0x61, 0x73, 0x74, 0x49, 0x6e, 0x64, 0x65, 0x78,
+ 0x4f, 0x66, 0x20, 0x26, 0x26, 0x20, 0x61, 0x72, 0x72, 0x61, 0x79, 0x2e,
+ 0x6c, 0x61, 0x73, 0x74, 0x49, 0x6e, 0x64, 0x65, 0x78, 0x4f, 0x66, 0x20,
+ 0x3d, 0x3d, 0x3d, 0x20, 0x6e, 0x61, 0x74, 0x69, 0x76, 0x65, 0x4c, 0x61,
+ 0x73, 0x74, 0x49, 0x6e, 0x64, 0x65, 0x78, 0x4f, 0x66, 0x29, 0x20, 0x7b,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72,
+ 0x6e, 0x20, 0x68, 0x61, 0x73, 0x49, 0x6e, 0x64, 0x65, 0x78, 0x20, 0x3f,
+ 0x20, 0x61, 0x72, 0x72, 0x61, 0x79, 0x2e, 0x6c, 0x61, 0x73, 0x74, 0x49,
+ 0x6e, 0x64, 0x65, 0x78, 0x4f, 0x66, 0x28, 0x69, 0x74, 0x65, 0x6d, 0x2c,
+ 0x20, 0x66, 0x72, 0x6f, 0x6d, 0x29, 0x20, 0x3a, 0x20, 0x61, 0x72, 0x72,
+ 0x61, 0x79, 0x2e, 0x6c, 0x61, 0x73, 0x74, 0x49, 0x6e, 0x64, 0x65, 0x78,
+ 0x4f, 0x66, 0x28, 0x69, 0x74, 0x65, 0x6d, 0x29, 0x3b, 0x0a, 0x20, 0x20,
+ 0x20, 0x20, 0x7d, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x76, 0x61, 0x72, 0x20,
+ 0x69, 0x20, 0x3d, 0x20, 0x28, 0x68, 0x61, 0x73, 0x49, 0x6e, 0x64, 0x65,
+ 0x78, 0x20, 0x3f, 0x20, 0x66, 0x72, 0x6f, 0x6d, 0x20, 0x3a, 0x20, 0x61,
+ 0x72, 0x72, 0x61, 0x79, 0x2e, 0x6c, 0x65, 0x6e, 0x67, 0x74, 0x68, 0x29,
+ 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x77, 0x68, 0x69, 0x6c, 0x65, 0x20,
+ 0x28, 0x69, 0x2d, 0x2d, 0x29, 0x20, 0x69, 0x66, 0x20, 0x28, 0x61, 0x72,
+ 0x72, 0x61, 0x79, 0x5b, 0x69, 0x5d, 0x20, 0x3d, 0x3d, 0x3d, 0x20, 0x69,
+ 0x74, 0x65, 0x6d, 0x29, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20,
+ 0x69, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72,
+ 0x6e, 0x20, 0x2d, 0x31, 0x3b, 0x0a, 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x0a,
+ 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x47, 0x65, 0x6e, 0x65, 0x72, 0x61, 0x74,
+ 0x65, 0x20, 0x61, 0x6e, 0x20, 0x69, 0x6e, 0x74, 0x65, 0x67, 0x65, 0x72,
+ 0x20, 0x41, 0x72, 0x72, 0x61, 0x79, 0x20, 0x63, 0x6f, 0x6e, 0x74, 0x61,
+ 0x69, 0x6e, 0x69, 0x6e, 0x67, 0x20, 0x61, 0x6e, 0x20, 0x61, 0x72, 0x69,
+ 0x74, 0x68, 0x6d, 0x65, 0x74, 0x69, 0x63, 0x20, 0x70, 0x72, 0x6f, 0x67,
+ 0x72, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x2e, 0x20, 0x41, 0x20, 0x70,
+ 0x6f, 0x72, 0x74, 0x20, 0x6f, 0x66, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20,
+ 0x74, 0x68, 0x65, 0x20, 0x6e, 0x61, 0x74, 0x69, 0x76, 0x65, 0x20, 0x50,
+ 0x79, 0x74, 0x68, 0x6f, 0x6e, 0x20, 0x60, 0x72, 0x61, 0x6e, 0x67, 0x65,
+ 0x28, 0x29, 0x60, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e,
+ 0x2e, 0x20, 0x53, 0x65, 0x65, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x5b,
+ 0x74, 0x68, 0x65, 0x20, 0x50, 0x79, 0x74, 0x68, 0x6f, 0x6e, 0x20, 0x64,
+ 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e,
+ 0x5d, 0x28, 0x68, 0x74, 0x74, 0x70, 0x3a, 0x2f, 0x2f, 0x64, 0x6f, 0x63,
+ 0x73, 0x2e, 0x70, 0x79, 0x74, 0x68, 0x6f, 0x6e, 0x2e, 0x6f, 0x72, 0x67,
+ 0x2f, 0x6c, 0x69, 0x62, 0x72, 0x61, 0x72, 0x79, 0x2f, 0x66, 0x75, 0x6e,
+ 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x2e, 0x68, 0x74, 0x6d, 0x6c, 0x23,
+ 0x72, 0x61, 0x6e, 0x67, 0x65, 0x29, 0x2e, 0x0a, 0x20, 0x20, 0x5f, 0x2e,
+ 0x72, 0x61, 0x6e, 0x67, 0x65, 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e, 0x63,
+ 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x73, 0x74, 0x61, 0x72, 0x74, 0x2c, 0x20,
+ 0x73, 0x74, 0x6f, 0x70, 0x2c, 0x20, 0x73, 0x74, 0x65, 0x70, 0x29, 0x20,
+ 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20, 0x28, 0x61, 0x72,
+ 0x67, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x2e, 0x6c, 0x65, 0x6e, 0x67,
+ 0x74, 0x68, 0x20, 0x3c, 0x3d, 0x20, 0x31, 0x29, 0x20, 0x7b, 0x0a, 0x20,
+ 0x20, 0x20, 0x20, 0x20, 0x20, 0x73, 0x74, 0x6f, 0x70, 0x20, 0x3d, 0x20,
+ 0x73, 0x74, 0x61, 0x72, 0x74, 0x20, 0x7c, 0x7c, 0x20, 0x30, 0x3b, 0x0a,
+ 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x73, 0x74, 0x61, 0x72, 0x74, 0x20,
+ 0x3d, 0x20, 0x30, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x0a, 0x20,
+ 0x20, 0x20, 0x20, 0x73, 0x74, 0x65, 0x70, 0x20, 0x3d, 0x20, 0x61, 0x72,
+ 0x67, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x5b, 0x32, 0x5d, 0x20, 0x7c,
+ 0x7c, 0x20, 0x31, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x76, 0x61,
+ 0x72, 0x20, 0x6c, 0x65, 0x6e, 0x20, 0x3d, 0x20, 0x4d, 0x61, 0x74, 0x68,
+ 0x2e, 0x6d, 0x61, 0x78, 0x28, 0x4d, 0x61, 0x74, 0x68, 0x2e, 0x63, 0x65,
+ 0x69, 0x6c, 0x28, 0x28, 0x73, 0x74, 0x6f, 0x70, 0x20, 0x2d, 0x20, 0x73,
+ 0x74, 0x61, 0x72, 0x74, 0x29, 0x20, 0x2f, 0x20, 0x73, 0x74, 0x65, 0x70,
+ 0x29, 0x2c, 0x20, 0x30, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x76,
+ 0x61, 0x72, 0x20, 0x69, 0x64, 0x78, 0x20, 0x3d, 0x20, 0x30, 0x3b, 0x0a,
+ 0x20, 0x20, 0x20, 0x20, 0x76, 0x61, 0x72, 0x20, 0x72, 0x61, 0x6e, 0x67,
+ 0x65, 0x20, 0x3d, 0x20, 0x6e, 0x65, 0x77, 0x20, 0x41, 0x72, 0x72, 0x61,
+ 0x79, 0x28, 0x6c, 0x65, 0x6e, 0x29, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x20,
+ 0x20, 0x77, 0x68, 0x69, 0x6c, 0x65, 0x28, 0x69, 0x64, 0x78, 0x20, 0x3c,
+ 0x20, 0x6c, 0x65, 0x6e, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x72, 0x61, 0x6e, 0x67, 0x65, 0x5b, 0x69, 0x64, 0x78, 0x2b,
+ 0x2b, 0x5d, 0x20, 0x3d, 0x20, 0x73, 0x74, 0x61, 0x72, 0x74, 0x3b, 0x0a,
+ 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x73, 0x74, 0x61, 0x72, 0x74, 0x20,
+ 0x2b, 0x3d, 0x20, 0x73, 0x74, 0x65, 0x70, 0x3b, 0x0a, 0x20, 0x20, 0x20,
+ 0x20, 0x7d, 0x0a, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74, 0x75,
+ 0x72, 0x6e, 0x20, 0x72, 0x61, 0x6e, 0x67, 0x65, 0x3b, 0x0a, 0x20, 0x20,
+ 0x7d, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x46, 0x75, 0x6e,
+ 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x20, 0x28, 0x61, 0x68, 0x65, 0x6d, 0x29,
+ 0x20, 0x46, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x0a, 0x20,
+ 0x20, 0x2f, 0x2f, 0x20, 0x2d, 0x2d, 0x2d, 0x2d, 0x2d, 0x2d, 0x2d, 0x2d,
+ 0x2d, 0x2d, 0x2d, 0x2d, 0x2d, 0x2d, 0x2d, 0x2d, 0x2d, 0x2d, 0x0a, 0x0a,
+ 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x20,
+ 0x61, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x20, 0x62,
+ 0x6f, 0x75, 0x6e, 0x64, 0x20, 0x74, 0x6f, 0x20, 0x61, 0x20, 0x67, 0x69,
+ 0x76, 0x65, 0x6e, 0x20, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, 0x28,
+ 0x61, 0x73, 0x73, 0x69, 0x67, 0x6e, 0x69, 0x6e, 0x67, 0x20, 0x60, 0x74,
+ 0x68, 0x69, 0x73, 0x60, 0x2c, 0x20, 0x61, 0x6e, 0x64, 0x20, 0x61, 0x72,
+ 0x67, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x2c, 0x0a, 0x20, 0x20, 0x2f,
+ 0x2f, 0x20, 0x6f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x61, 0x6c, 0x6c, 0x79,
+ 0x29, 0x2e, 0x20, 0x44, 0x65, 0x6c, 0x65, 0x67, 0x61, 0x74, 0x65, 0x73,
+ 0x20, 0x74, 0x6f, 0x20, 0x2a, 0x2a, 0x45, 0x43, 0x4d, 0x41, 0x53, 0x63,
+ 0x72, 0x69, 0x70, 0x74, 0x20, 0x35, 0x2a, 0x2a, 0x27, 0x73, 0x20, 0x6e,
+ 0x61, 0x74, 0x69, 0x76, 0x65, 0x20, 0x60, 0x46, 0x75, 0x6e, 0x63, 0x74,
+ 0x69, 0x6f, 0x6e, 0x2e, 0x62, 0x69, 0x6e, 0x64, 0x60, 0x20, 0x69, 0x66,
+ 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x61, 0x76, 0x61, 0x69, 0x6c, 0x61,
+ 0x62, 0x6c, 0x65, 0x2e, 0x0a, 0x20, 0x20, 0x5f, 0x2e, 0x62, 0x69, 0x6e,
+ 0x64, 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e,
+ 0x28, 0x66, 0x75, 0x6e, 0x63, 0x2c, 0x20, 0x63, 0x6f, 0x6e, 0x74, 0x65,
+ 0x78, 0x74, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66,
+ 0x20, 0x28, 0x66, 0x75, 0x6e, 0x63, 0x2e, 0x62, 0x69, 0x6e, 0x64, 0x20,
+ 0x3d, 0x3d, 0x3d, 0x20, 0x6e, 0x61, 0x74, 0x69, 0x76, 0x65, 0x42, 0x69,
+ 0x6e, 0x64, 0x20, 0x26, 0x26, 0x20, 0x6e, 0x61, 0x74, 0x69, 0x76, 0x65,
+ 0x42, 0x69, 0x6e, 0x64, 0x29, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e,
+ 0x20, 0x6e, 0x61, 0x74, 0x69, 0x76, 0x65, 0x42, 0x69, 0x6e, 0x64, 0x2e,
+ 0x61, 0x70, 0x70, 0x6c, 0x79, 0x28, 0x66, 0x75, 0x6e, 0x63, 0x2c, 0x20,
+ 0x73, 0x6c, 0x69, 0x63, 0x65, 0x2e, 0x63, 0x61, 0x6c, 0x6c, 0x28, 0x61,
+ 0x72, 0x67, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x2c, 0x20, 0x31, 0x29,
+ 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x76, 0x61, 0x72, 0x20, 0x61,
+ 0x72, 0x67, 0x73, 0x20, 0x3d, 0x20, 0x73, 0x6c, 0x69, 0x63, 0x65, 0x2e,
+ 0x63, 0x61, 0x6c, 0x6c, 0x28, 0x61, 0x72, 0x67, 0x75, 0x6d, 0x65, 0x6e,
+ 0x74, 0x73, 0x2c, 0x20, 0x32, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74,
+ 0x69, 0x6f, 0x6e, 0x28, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x66, 0x75, 0x6e,
+ 0x63, 0x2e, 0x61, 0x70, 0x70, 0x6c, 0x79, 0x28, 0x63, 0x6f, 0x6e, 0x74,
+ 0x65, 0x78, 0x74, 0x2c, 0x20, 0x61, 0x72, 0x67, 0x73, 0x2e, 0x63, 0x6f,
+ 0x6e, 0x63, 0x61, 0x74, 0x28, 0x73, 0x6c, 0x69, 0x63, 0x65, 0x2e, 0x63,
+ 0x61, 0x6c, 0x6c, 0x28, 0x61, 0x72, 0x67, 0x75, 0x6d, 0x65, 0x6e, 0x74,
+ 0x73, 0x29, 0x29, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x3b,
+ 0x0a, 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20,
+ 0x50, 0x61, 0x72, 0x74, 0x69, 0x61, 0x6c, 0x6c, 0x79, 0x20, 0x61, 0x70,
+ 0x70, 0x6c, 0x79, 0x20, 0x61, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69,
+ 0x6f, 0x6e, 0x20, 0x62, 0x79, 0x20, 0x63, 0x72, 0x65, 0x61, 0x74, 0x69,
+ 0x6e, 0x67, 0x20, 0x61, 0x20, 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e,
+ 0x20, 0x74, 0x68, 0x61, 0x74, 0x20, 0x68, 0x61, 0x73, 0x20, 0x68, 0x61,
+ 0x64, 0x20, 0x73, 0x6f, 0x6d, 0x65, 0x20, 0x6f, 0x66, 0x20, 0x69, 0x74,
+ 0x73, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x61, 0x72, 0x67, 0x75, 0x6d,
+ 0x65, 0x6e, 0x74, 0x73, 0x20, 0x70, 0x72, 0x65, 0x2d, 0x66, 0x69, 0x6c,
+ 0x6c, 0x65, 0x64, 0x2c, 0x20, 0x77, 0x69, 0x74, 0x68, 0x6f, 0x75, 0x74,
+ 0x20, 0x63, 0x68, 0x61, 0x6e, 0x67, 0x69, 0x6e, 0x67, 0x20, 0x69, 0x74,
+ 0x73, 0x20, 0x64, 0x79, 0x6e, 0x61, 0x6d, 0x69, 0x63, 0x20, 0x60, 0x74,
+ 0x68, 0x69, 0x73, 0x60, 0x20, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74,
+ 0x2e, 0x0a, 0x20, 0x20, 0x5f, 0x2e, 0x70, 0x61, 0x72, 0x74, 0x69, 0x61,
+ 0x6c, 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e,
+ 0x28, 0x66, 0x75, 0x6e, 0x63, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20,
+ 0x20, 0x76, 0x61, 0x72, 0x20, 0x61, 0x72, 0x67, 0x73, 0x20, 0x3d, 0x20,
+ 0x73, 0x6c, 0x69, 0x63, 0x65, 0x2e, 0x63, 0x61, 0x6c, 0x6c, 0x28, 0x61,
+ 0x72, 0x67, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x2c, 0x20, 0x31, 0x29,
+ 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e,
+ 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x29, 0x20,
+ 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74, 0x75,
+ 0x72, 0x6e, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x2e, 0x61, 0x70, 0x70, 0x6c,
+ 0x79, 0x28, 0x74, 0x68, 0x69, 0x73, 0x2c, 0x20, 0x61, 0x72, 0x67, 0x73,
+ 0x2e, 0x63, 0x6f, 0x6e, 0x63, 0x61, 0x74, 0x28, 0x73, 0x6c, 0x69, 0x63,
+ 0x65, 0x2e, 0x63, 0x61, 0x6c, 0x6c, 0x28, 0x61, 0x72, 0x67, 0x75, 0x6d,
+ 0x65, 0x6e, 0x74, 0x73, 0x29, 0x29, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20,
+ 0x20, 0x7d, 0x3b, 0x0a, 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x0a, 0x20, 0x20,
+ 0x2f, 0x2f, 0x20, 0x42, 0x69, 0x6e, 0x64, 0x20, 0x61, 0x6c, 0x6c, 0x20,
+ 0x6f, 0x66, 0x20, 0x61, 0x6e, 0x20, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74,
+ 0x27, 0x73, 0x20, 0x6d, 0x65, 0x74, 0x68, 0x6f, 0x64, 0x73, 0x20, 0x74,
+ 0x6f, 0x20, 0x74, 0x68, 0x61, 0x74, 0x20, 0x6f, 0x62, 0x6a, 0x65, 0x63,
+ 0x74, 0x2e, 0x20, 0x55, 0x73, 0x65, 0x66, 0x75, 0x6c, 0x20, 0x66, 0x6f,
+ 0x72, 0x20, 0x65, 0x6e, 0x73, 0x75, 0x72, 0x69, 0x6e, 0x67, 0x20, 0x74,
+ 0x68, 0x61, 0x74, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x61, 0x6c, 0x6c,
+ 0x20, 0x63, 0x61, 0x6c, 0x6c, 0x62, 0x61, 0x63, 0x6b, 0x73, 0x20, 0x64,
+ 0x65, 0x66, 0x69, 0x6e, 0x65, 0x64, 0x20, 0x6f, 0x6e, 0x20, 0x61, 0x6e,
+ 0x20, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, 0x62, 0x65, 0x6c, 0x6f,
+ 0x6e, 0x67, 0x20, 0x74, 0x6f, 0x20, 0x69, 0x74, 0x2e, 0x0a, 0x20, 0x20,
+ 0x5f, 0x2e, 0x62, 0x69, 0x6e, 0x64, 0x41, 0x6c, 0x6c, 0x20, 0x3d, 0x20,
+ 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x6f, 0x62, 0x6a,
+ 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x76, 0x61, 0x72, 0x20,
+ 0x66, 0x75, 0x6e, 0x63, 0x73, 0x20, 0x3d, 0x20, 0x73, 0x6c, 0x69, 0x63,
+ 0x65, 0x2e, 0x63, 0x61, 0x6c, 0x6c, 0x28, 0x61, 0x72, 0x67, 0x75, 0x6d,
+ 0x65, 0x6e, 0x74, 0x73, 0x2c, 0x20, 0x31, 0x29, 0x3b, 0x0a, 0x20, 0x20,
+ 0x20, 0x20, 0x69, 0x66, 0x20, 0x28, 0x66, 0x75, 0x6e, 0x63, 0x73, 0x2e,
+ 0x6c, 0x65, 0x6e, 0x67, 0x74, 0x68, 0x20, 0x3d, 0x3d, 0x3d, 0x20, 0x30,
+ 0x29, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x73, 0x20, 0x3d, 0x20, 0x5f, 0x2e,
+ 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x28, 0x6f, 0x62,
+ 0x6a, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x65, 0x61, 0x63, 0x68,
+ 0x28, 0x66, 0x75, 0x6e, 0x63, 0x73, 0x2c, 0x20, 0x66, 0x75, 0x6e, 0x63,
+ 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x66, 0x29, 0x20, 0x7b, 0x20, 0x6f, 0x62,
+ 0x6a, 0x5b, 0x66, 0x5d, 0x20, 0x3d, 0x20, 0x5f, 0x2e, 0x62, 0x69, 0x6e,
+ 0x64, 0x28, 0x6f, 0x62, 0x6a, 0x5b, 0x66, 0x5d, 0x2c, 0x20, 0x6f, 0x62,
+ 0x6a, 0x29, 0x3b, 0x20, 0x7d, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x6f, 0x62, 0x6a, 0x3b, 0x0a,
+ 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x4d,
+ 0x65, 0x6d, 0x6f, 0x69, 0x7a, 0x65, 0x20, 0x61, 0x6e, 0x20, 0x65, 0x78,
+ 0x70, 0x65, 0x6e, 0x73, 0x69, 0x76, 0x65, 0x20, 0x66, 0x75, 0x6e, 0x63,
+ 0x74, 0x69, 0x6f, 0x6e, 0x20, 0x62, 0x79, 0x20, 0x73, 0x74, 0x6f, 0x72,
+ 0x69, 0x6e, 0x67, 0x20, 0x69, 0x74, 0x73, 0x20, 0x72, 0x65, 0x73, 0x75,
+ 0x6c, 0x74, 0x73, 0x2e, 0x0a, 0x20, 0x20, 0x5f, 0x2e, 0x6d, 0x65, 0x6d,
+ 0x6f, 0x69, 0x7a, 0x65, 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74,
+ 0x69, 0x6f, 0x6e, 0x28, 0x66, 0x75, 0x6e, 0x63, 0x2c, 0x20, 0x68, 0x61,
+ 0x73, 0x68, 0x65, 0x72, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x76, 0x61, 0x72, 0x20, 0x6d, 0x65, 0x6d, 0x6f, 0x20, 0x3d, 0x20, 0x7b,
+ 0x7d, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x68, 0x61, 0x73, 0x68, 0x65,
+ 0x72, 0x20, 0x7c, 0x7c, 0x20, 0x28, 0x68, 0x61, 0x73, 0x68, 0x65, 0x72,
+ 0x20, 0x3d, 0x20, 0x5f, 0x2e, 0x69, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x74,
+ 0x79, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74, 0x75,
+ 0x72, 0x6e, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28,
+ 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x76, 0x61,
+ 0x72, 0x20, 0x6b, 0x65, 0x79, 0x20, 0x3d, 0x20, 0x68, 0x61, 0x73, 0x68,
+ 0x65, 0x72, 0x2e, 0x61, 0x70, 0x70, 0x6c, 0x79, 0x28, 0x74, 0x68, 0x69,
+ 0x73, 0x2c, 0x20, 0x61, 0x72, 0x67, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x73,
+ 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74,
+ 0x75, 0x72, 0x6e, 0x20, 0x5f, 0x2e, 0x68, 0x61, 0x73, 0x28, 0x6d, 0x65,
+ 0x6d, 0x6f, 0x2c, 0x20, 0x6b, 0x65, 0x79, 0x29, 0x20, 0x3f, 0x20, 0x6d,
+ 0x65, 0x6d, 0x6f, 0x5b, 0x6b, 0x65, 0x79, 0x5d, 0x20, 0x3a, 0x20, 0x28,
+ 0x6d, 0x65, 0x6d, 0x6f, 0x5b, 0x6b, 0x65, 0x79, 0x5d, 0x20, 0x3d, 0x20,
+ 0x66, 0x75, 0x6e, 0x63, 0x2e, 0x61, 0x70, 0x70, 0x6c, 0x79, 0x28, 0x74,
+ 0x68, 0x69, 0x73, 0x2c, 0x20, 0x61, 0x72, 0x67, 0x75, 0x6d, 0x65, 0x6e,
+ 0x74, 0x73, 0x29, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x3b,
+ 0x0a, 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20,
+ 0x44, 0x65, 0x6c, 0x61, 0x79, 0x73, 0x20, 0x61, 0x20, 0x66, 0x75, 0x6e,
+ 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x20, 0x66, 0x6f, 0x72, 0x20, 0x74, 0x68,
+ 0x65, 0x20, 0x67, 0x69, 0x76, 0x65, 0x6e, 0x20, 0x6e, 0x75, 0x6d, 0x62,
+ 0x65, 0x72, 0x20, 0x6f, 0x66, 0x20, 0x6d, 0x69, 0x6c, 0x6c, 0x69, 0x73,
+ 0x65, 0x63, 0x6f, 0x6e, 0x64, 0x73, 0x2c, 0x20, 0x61, 0x6e, 0x64, 0x20,
+ 0x74, 0x68, 0x65, 0x6e, 0x20, 0x63, 0x61, 0x6c, 0x6c, 0x73, 0x0a, 0x20,
+ 0x20, 0x2f, 0x2f, 0x20, 0x69, 0x74, 0x20, 0x77, 0x69, 0x74, 0x68, 0x20,
+ 0x74, 0x68, 0x65, 0x20, 0x61, 0x72, 0x67, 0x75, 0x6d, 0x65, 0x6e, 0x74,
+ 0x73, 0x20, 0x73, 0x75, 0x70, 0x70, 0x6c, 0x69, 0x65, 0x64, 0x2e, 0x0a,
+ 0x20, 0x20, 0x5f, 0x2e, 0x64, 0x65, 0x6c, 0x61, 0x79, 0x20, 0x3d, 0x20,
+ 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x66, 0x75, 0x6e,
+ 0x63, 0x2c, 0x20, 0x77, 0x61, 0x69, 0x74, 0x29, 0x20, 0x7b, 0x0a, 0x20,
+ 0x20, 0x20, 0x20, 0x76, 0x61, 0x72, 0x20, 0x61, 0x72, 0x67, 0x73, 0x20,
+ 0x3d, 0x20, 0x73, 0x6c, 0x69, 0x63, 0x65, 0x2e, 0x63, 0x61, 0x6c, 0x6c,
+ 0x28, 0x61, 0x72, 0x67, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x2c, 0x20,
+ 0x32, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74, 0x75,
+ 0x72, 0x6e, 0x20, 0x73, 0x65, 0x74, 0x54, 0x69, 0x6d, 0x65, 0x6f, 0x75,
+ 0x74, 0x28, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x29,
+ 0x7b, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x66, 0x75, 0x6e,
+ 0x63, 0x2e, 0x61, 0x70, 0x70, 0x6c, 0x79, 0x28, 0x6e, 0x75, 0x6c, 0x6c,
+ 0x2c, 0x20, 0x61, 0x72, 0x67, 0x73, 0x29, 0x3b, 0x20, 0x7d, 0x2c, 0x20,
+ 0x77, 0x61, 0x69, 0x74, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x7d, 0x3b, 0x0a,
+ 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x44, 0x65, 0x66, 0x65, 0x72, 0x73,
+ 0x20, 0x61, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x2c,
+ 0x20, 0x73, 0x63, 0x68, 0x65, 0x64, 0x75, 0x6c, 0x69, 0x6e, 0x67, 0x20,
+ 0x69, 0x74, 0x20, 0x74, 0x6f, 0x20, 0x72, 0x75, 0x6e, 0x20, 0x61, 0x66,
+ 0x74, 0x65, 0x72, 0x20, 0x74, 0x68, 0x65, 0x20, 0x63, 0x75, 0x72, 0x72,
+ 0x65, 0x6e, 0x74, 0x20, 0x63, 0x61, 0x6c, 0x6c, 0x20, 0x73, 0x74, 0x61,
+ 0x63, 0x6b, 0x20, 0x68, 0x61, 0x73, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20,
+ 0x63, 0x6c, 0x65, 0x61, 0x72, 0x65, 0x64, 0x2e, 0x0a, 0x20, 0x20, 0x5f,
+ 0x2e, 0x64, 0x65, 0x66, 0x65, 0x72, 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e,
+ 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x66, 0x75, 0x6e, 0x63, 0x29, 0x20,
+ 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e,
+ 0x20, 0x5f, 0x2e, 0x64, 0x65, 0x6c, 0x61, 0x79, 0x2e, 0x61, 0x70, 0x70,
+ 0x6c, 0x79, 0x28, 0x5f, 0x2c, 0x20, 0x5b, 0x66, 0x75, 0x6e, 0x63, 0x2c,
+ 0x20, 0x31, 0x5d, 0x2e, 0x63, 0x6f, 0x6e, 0x63, 0x61, 0x74, 0x28, 0x73,
+ 0x6c, 0x69, 0x63, 0x65, 0x2e, 0x63, 0x61, 0x6c, 0x6c, 0x28, 0x61, 0x72,
+ 0x67, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x2c, 0x20, 0x31, 0x29, 0x29,
+ 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f,
+ 0x2f, 0x20, 0x52, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x73, 0x20, 0x61, 0x20,
+ 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x2c, 0x20, 0x74, 0x68,
+ 0x61, 0x74, 0x2c, 0x20, 0x77, 0x68, 0x65, 0x6e, 0x20, 0x69, 0x6e, 0x76,
+ 0x6f, 0x6b, 0x65, 0x64, 0x2c, 0x20, 0x77, 0x69, 0x6c, 0x6c, 0x20, 0x6f,
+ 0x6e, 0x6c, 0x79, 0x20, 0x62, 0x65, 0x20, 0x74, 0x72, 0x69, 0x67, 0x67,
+ 0x65, 0x72, 0x65, 0x64, 0x20, 0x61, 0x74, 0x20, 0x6d, 0x6f, 0x73, 0x74,
+ 0x20, 0x6f, 0x6e, 0x63, 0x65, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x64,
+ 0x75, 0x72, 0x69, 0x6e, 0x67, 0x20, 0x61, 0x20, 0x67, 0x69, 0x76, 0x65,
+ 0x6e, 0x20, 0x77, 0x69, 0x6e, 0x64, 0x6f, 0x77, 0x20, 0x6f, 0x66, 0x20,
+ 0x74, 0x69, 0x6d, 0x65, 0x2e, 0x0a, 0x20, 0x20, 0x5f, 0x2e, 0x74, 0x68,
+ 0x72, 0x6f, 0x74, 0x74, 0x6c, 0x65, 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e,
+ 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x66, 0x75, 0x6e, 0x63, 0x2c, 0x20,
+ 0x77, 0x61, 0x69, 0x74, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x76, 0x61, 0x72, 0x20, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x2c,
+ 0x20, 0x61, 0x72, 0x67, 0x73, 0x2c, 0x20, 0x74, 0x69, 0x6d, 0x65, 0x6f,
+ 0x75, 0x74, 0x2c, 0x20, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x3b, 0x0a,
+ 0x20, 0x20, 0x20, 0x20, 0x76, 0x61, 0x72, 0x20, 0x70, 0x72, 0x65, 0x76,
+ 0x69, 0x6f, 0x75, 0x73, 0x20, 0x3d, 0x20, 0x30, 0x3b, 0x0a, 0x20, 0x20,
+ 0x20, 0x20, 0x76, 0x61, 0x72, 0x20, 0x6c, 0x61, 0x74, 0x65, 0x72, 0x20,
+ 0x3d, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x29,
+ 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x70, 0x72, 0x65,
+ 0x76, 0x69, 0x6f, 0x75, 0x73, 0x20, 0x3d, 0x20, 0x6e, 0x65, 0x77, 0x20,
+ 0x44, 0x61, 0x74, 0x65, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x74, 0x69, 0x6d, 0x65, 0x6f, 0x75, 0x74, 0x20, 0x3d, 0x20, 0x6e, 0x75,
+ 0x6c, 0x6c, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65,
+ 0x73, 0x75, 0x6c, 0x74, 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x2e,
+ 0x61, 0x70, 0x70, 0x6c, 0x79, 0x28, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x78,
+ 0x74, 0x2c, 0x20, 0x61, 0x72, 0x67, 0x73, 0x29, 0x3b, 0x0a, 0x20, 0x20,
+ 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74,
+ 0x75, 0x72, 0x6e, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e,
+ 0x28, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x76,
+ 0x61, 0x72, 0x20, 0x6e, 0x6f, 0x77, 0x20, 0x3d, 0x20, 0x6e, 0x65, 0x77,
+ 0x20, 0x44, 0x61, 0x74, 0x65, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x76, 0x61, 0x72, 0x20, 0x72, 0x65, 0x6d, 0x61, 0x69, 0x6e, 0x69,
+ 0x6e, 0x67, 0x20, 0x3d, 0x20, 0x77, 0x61, 0x69, 0x74, 0x20, 0x2d, 0x20,
+ 0x28, 0x6e, 0x6f, 0x77, 0x20, 0x2d, 0x20, 0x70, 0x72, 0x65, 0x76, 0x69,
+ 0x6f, 0x75, 0x73, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x20, 0x3d, 0x20, 0x74, 0x68,
+ 0x69, 0x73, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x61, 0x72,
+ 0x67, 0x73, 0x20, 0x3d, 0x20, 0x61, 0x72, 0x67, 0x75, 0x6d, 0x65, 0x6e,
+ 0x74, 0x73, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66,
+ 0x20, 0x28, 0x72, 0x65, 0x6d, 0x61, 0x69, 0x6e, 0x69, 0x6e, 0x67, 0x20,
+ 0x3c, 0x3d, 0x20, 0x30, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x20, 0x20, 0x63, 0x6c, 0x65, 0x61, 0x72, 0x54, 0x69, 0x6d,
+ 0x65, 0x6f, 0x75, 0x74, 0x28, 0x74, 0x69, 0x6d, 0x65, 0x6f, 0x75, 0x74,
+ 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x74,
+ 0x69, 0x6d, 0x65, 0x6f, 0x75, 0x74, 0x20, 0x3d, 0x20, 0x6e, 0x75, 0x6c,
+ 0x6c, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x70,
+ 0x72, 0x65, 0x76, 0x69, 0x6f, 0x75, 0x73, 0x20, 0x3d, 0x20, 0x6e, 0x6f,
+ 0x77, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x72,
+ 0x65, 0x73, 0x75, 0x6c, 0x74, 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e, 0x63,
+ 0x2e, 0x61, 0x70, 0x70, 0x6c, 0x79, 0x28, 0x63, 0x6f, 0x6e, 0x74, 0x65,
+ 0x78, 0x74, 0x2c, 0x20, 0x61, 0x72, 0x67, 0x73, 0x29, 0x3b, 0x0a, 0x20,
+ 0x20, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x20, 0x65, 0x6c, 0x73, 0x65, 0x20,
+ 0x69, 0x66, 0x20, 0x28, 0x21, 0x74, 0x69, 0x6d, 0x65, 0x6f, 0x75, 0x74,
+ 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x74, 0x69, 0x6d, 0x65, 0x6f, 0x75, 0x74, 0x20, 0x3d, 0x20, 0x73, 0x65,
+ 0x74, 0x54, 0x69, 0x6d, 0x65, 0x6f, 0x75, 0x74, 0x28, 0x6c, 0x61, 0x74,
+ 0x65, 0x72, 0x2c, 0x20, 0x72, 0x65, 0x6d, 0x61, 0x69, 0x6e, 0x69, 0x6e,
+ 0x67, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x0a,
+ 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e,
+ 0x20, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x3b, 0x0a, 0x20, 0x20, 0x20,
+ 0x20, 0x7d, 0x3b, 0x0a, 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x0a, 0x20, 0x20,
+ 0x2f, 0x2f, 0x20, 0x52, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x73, 0x20, 0x61,
+ 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x2c, 0x20, 0x74,
+ 0x68, 0x61, 0x74, 0x2c, 0x20, 0x61, 0x73, 0x20, 0x6c, 0x6f, 0x6e, 0x67,
+ 0x20, 0x61, 0x73, 0x20, 0x69, 0x74, 0x20, 0x63, 0x6f, 0x6e, 0x74, 0x69,
+ 0x6e, 0x75, 0x65, 0x73, 0x20, 0x74, 0x6f, 0x20, 0x62, 0x65, 0x20, 0x69,
+ 0x6e, 0x76, 0x6f, 0x6b, 0x65, 0x64, 0x2c, 0x20, 0x77, 0x69, 0x6c, 0x6c,
+ 0x20, 0x6e, 0x6f, 0x74, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x62, 0x65,
+ 0x20, 0x74, 0x72, 0x69, 0x67, 0x67, 0x65, 0x72, 0x65, 0x64, 0x2e, 0x20,
+ 0x54, 0x68, 0x65, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e,
+ 0x20, 0x77, 0x69, 0x6c, 0x6c, 0x20, 0x62, 0x65, 0x20, 0x63, 0x61, 0x6c,
+ 0x6c, 0x65, 0x64, 0x20, 0x61, 0x66, 0x74, 0x65, 0x72, 0x20, 0x69, 0x74,
+ 0x20, 0x73, 0x74, 0x6f, 0x70, 0x73, 0x20, 0x62, 0x65, 0x69, 0x6e, 0x67,
+ 0x20, 0x63, 0x61, 0x6c, 0x6c, 0x65, 0x64, 0x20, 0x66, 0x6f, 0x72, 0x0a,
+ 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x4e, 0x20, 0x6d, 0x69, 0x6c, 0x6c, 0x69,
+ 0x73, 0x65, 0x63, 0x6f, 0x6e, 0x64, 0x73, 0x2e, 0x20, 0x49, 0x66, 0x20,
+ 0x60, 0x69, 0x6d, 0x6d, 0x65, 0x64, 0x69, 0x61, 0x74, 0x65, 0x60, 0x20,
+ 0x69, 0x73, 0x20, 0x70, 0x61, 0x73, 0x73, 0x65, 0x64, 0x2c, 0x20, 0x74,
+ 0x72, 0x69, 0x67, 0x67, 0x65, 0x72, 0x20, 0x74, 0x68, 0x65, 0x20, 0x66,
+ 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x20, 0x6f, 0x6e, 0x20, 0x74,
+ 0x68, 0x65, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x6c, 0x65, 0x61, 0x64,
+ 0x69, 0x6e, 0x67, 0x20, 0x65, 0x64, 0x67, 0x65, 0x2c, 0x20, 0x69, 0x6e,
+ 0x73, 0x74, 0x65, 0x61, 0x64, 0x20, 0x6f, 0x66, 0x20, 0x74, 0x68, 0x65,
+ 0x20, 0x74, 0x72, 0x61, 0x69, 0x6c, 0x69, 0x6e, 0x67, 0x2e, 0x0a, 0x20,
+ 0x20, 0x5f, 0x2e, 0x64, 0x65, 0x62, 0x6f, 0x75, 0x6e, 0x63, 0x65, 0x20,
+ 0x3d, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x66,
+ 0x75, 0x6e, 0x63, 0x2c, 0x20, 0x77, 0x61, 0x69, 0x74, 0x2c, 0x20, 0x69,
+ 0x6d, 0x6d, 0x65, 0x64, 0x69, 0x61, 0x74, 0x65, 0x29, 0x20, 0x7b, 0x0a,
+ 0x20, 0x20, 0x20, 0x20, 0x76, 0x61, 0x72, 0x20, 0x74, 0x69, 0x6d, 0x65,
+ 0x6f, 0x75, 0x74, 0x2c, 0x20, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x3b,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20,
+ 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x29, 0x20, 0x7b,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x76, 0x61, 0x72, 0x20, 0x63,
+ 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x20, 0x3d, 0x20, 0x74, 0x68, 0x69,
+ 0x73, 0x2c, 0x20, 0x61, 0x72, 0x67, 0x73, 0x20, 0x3d, 0x20, 0x61, 0x72,
+ 0x67, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x3b, 0x0a, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x20, 0x76, 0x61, 0x72, 0x20, 0x6c, 0x61, 0x74, 0x65, 0x72,
+ 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28,
+ 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x74, 0x69, 0x6d, 0x65, 0x6f, 0x75, 0x74, 0x20, 0x3d, 0x20, 0x6e, 0x75,
+ 0x6c, 0x6c, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x69, 0x66, 0x20, 0x28, 0x21, 0x69, 0x6d, 0x6d, 0x65, 0x64, 0x69, 0x61,
+ 0x74, 0x65, 0x29, 0x20, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x20, 0x3d,
+ 0x20, 0x66, 0x75, 0x6e, 0x63, 0x2e, 0x61, 0x70, 0x70, 0x6c, 0x79, 0x28,
+ 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x2c, 0x20, 0x61, 0x72, 0x67,
+ 0x73, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x3b,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x76, 0x61, 0x72, 0x20, 0x63,
+ 0x61, 0x6c, 0x6c, 0x4e, 0x6f, 0x77, 0x20, 0x3d, 0x20, 0x69, 0x6d, 0x6d,
+ 0x65, 0x64, 0x69, 0x61, 0x74, 0x65, 0x20, 0x26, 0x26, 0x20, 0x21, 0x74,
+ 0x69, 0x6d, 0x65, 0x6f, 0x75, 0x74, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x63, 0x6c, 0x65, 0x61, 0x72, 0x54, 0x69, 0x6d, 0x65, 0x6f,
+ 0x75, 0x74, 0x28, 0x74, 0x69, 0x6d, 0x65, 0x6f, 0x75, 0x74, 0x29, 0x3b,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x74, 0x69, 0x6d, 0x65, 0x6f,
+ 0x75, 0x74, 0x20, 0x3d, 0x20, 0x73, 0x65, 0x74, 0x54, 0x69, 0x6d, 0x65,
+ 0x6f, 0x75, 0x74, 0x28, 0x6c, 0x61, 0x74, 0x65, 0x72, 0x2c, 0x20, 0x77,
+ 0x61, 0x69, 0x74, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x69, 0x66, 0x20, 0x28, 0x63, 0x61, 0x6c, 0x6c, 0x4e, 0x6f, 0x77, 0x29,
+ 0x20, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x20, 0x3d, 0x20, 0x66, 0x75,
+ 0x6e, 0x63, 0x2e, 0x61, 0x70, 0x70, 0x6c, 0x79, 0x28, 0x63, 0x6f, 0x6e,
+ 0x74, 0x65, 0x78, 0x74, 0x2c, 0x20, 0x61, 0x72, 0x67, 0x73, 0x29, 0x3b,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72,
+ 0x6e, 0x20, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x3b, 0x0a, 0x20, 0x20,
+ 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x0a, 0x20,
+ 0x20, 0x2f, 0x2f, 0x20, 0x52, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x73, 0x20,
+ 0x61, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x20, 0x74,
+ 0x68, 0x61, 0x74, 0x20, 0x77, 0x69, 0x6c, 0x6c, 0x20, 0x62, 0x65, 0x20,
+ 0x65, 0x78, 0x65, 0x63, 0x75, 0x74, 0x65, 0x64, 0x20, 0x61, 0x74, 0x20,
+ 0x6d, 0x6f, 0x73, 0x74, 0x20, 0x6f, 0x6e, 0x65, 0x20, 0x74, 0x69, 0x6d,
+ 0x65, 0x2c, 0x20, 0x6e, 0x6f, 0x20, 0x6d, 0x61, 0x74, 0x74, 0x65, 0x72,
+ 0x20, 0x68, 0x6f, 0x77, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x6f, 0x66,
+ 0x74, 0x65, 0x6e, 0x20, 0x79, 0x6f, 0x75, 0x20, 0x63, 0x61, 0x6c, 0x6c,
+ 0x20, 0x69, 0x74, 0x2e, 0x20, 0x55, 0x73, 0x65, 0x66, 0x75, 0x6c, 0x20,
+ 0x66, 0x6f, 0x72, 0x20, 0x6c, 0x61, 0x7a, 0x79, 0x20, 0x69, 0x6e, 0x69,
+ 0x74, 0x69, 0x61, 0x6c, 0x69, 0x7a, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x2e,
+ 0x0a, 0x20, 0x20, 0x5f, 0x2e, 0x6f, 0x6e, 0x63, 0x65, 0x20, 0x3d, 0x20,
+ 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x66, 0x75, 0x6e,
+ 0x63, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x76, 0x61, 0x72,
+ 0x20, 0x72, 0x61, 0x6e, 0x20, 0x3d, 0x20, 0x66, 0x61, 0x6c, 0x73, 0x65,
+ 0x2c, 0x20, 0x6d, 0x65, 0x6d, 0x6f, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74,
+ 0x69, 0x6f, 0x6e, 0x28, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x69, 0x66, 0x20, 0x28, 0x72, 0x61, 0x6e, 0x29, 0x20, 0x72,
+ 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x6d, 0x65, 0x6d, 0x6f, 0x3b, 0x0a,
+ 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x72, 0x61, 0x6e, 0x20, 0x3d, 0x20,
+ 0x74, 0x72, 0x75, 0x65, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x6d, 0x65, 0x6d, 0x6f, 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x2e,
+ 0x61, 0x70, 0x70, 0x6c, 0x79, 0x28, 0x74, 0x68, 0x69, 0x73, 0x2c, 0x20,
+ 0x61, 0x72, 0x67, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x29, 0x3b, 0x0a,
+ 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x20, 0x3d,
+ 0x20, 0x6e, 0x75, 0x6c, 0x6c, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x6d, 0x65, 0x6d, 0x6f,
+ 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x20, 0x20, 0x7d,
+ 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x52, 0x65, 0x74, 0x75,
+ 0x72, 0x6e, 0x73, 0x20, 0x74, 0x68, 0x65, 0x20, 0x66, 0x69, 0x72, 0x73,
+ 0x74, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x20, 0x70,
+ 0x61, 0x73, 0x73, 0x65, 0x64, 0x20, 0x61, 0x73, 0x20, 0x61, 0x6e, 0x20,
+ 0x61, 0x72, 0x67, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x20, 0x74, 0x6f, 0x20,
+ 0x74, 0x68, 0x65, 0x20, 0x73, 0x65, 0x63, 0x6f, 0x6e, 0x64, 0x2c, 0x0a,
+ 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x61, 0x6c, 0x6c, 0x6f, 0x77, 0x69, 0x6e,
+ 0x67, 0x20, 0x79, 0x6f, 0x75, 0x20, 0x74, 0x6f, 0x20, 0x61, 0x64, 0x6a,
+ 0x75, 0x73, 0x74, 0x20, 0x61, 0x72, 0x67, 0x75, 0x6d, 0x65, 0x6e, 0x74,
+ 0x73, 0x2c, 0x20, 0x72, 0x75, 0x6e, 0x20, 0x63, 0x6f, 0x64, 0x65, 0x20,
+ 0x62, 0x65, 0x66, 0x6f, 0x72, 0x65, 0x20, 0x61, 0x6e, 0x64, 0x20, 0x61,
+ 0x66, 0x74, 0x65, 0x72, 0x2c, 0x20, 0x61, 0x6e, 0x64, 0x0a, 0x20, 0x20,
+ 0x2f, 0x2f, 0x20, 0x63, 0x6f, 0x6e, 0x64, 0x69, 0x74, 0x69, 0x6f, 0x6e,
+ 0x61, 0x6c, 0x6c, 0x79, 0x20, 0x65, 0x78, 0x65, 0x63, 0x75, 0x74, 0x65,
+ 0x20, 0x74, 0x68, 0x65, 0x20, 0x6f, 0x72, 0x69, 0x67, 0x69, 0x6e, 0x61,
+ 0x6c, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x0a,
+ 0x20, 0x20, 0x5f, 0x2e, 0x77, 0x72, 0x61, 0x70, 0x20, 0x3d, 0x20, 0x66,
+ 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x66, 0x75, 0x6e, 0x63,
+ 0x2c, 0x20, 0x77, 0x72, 0x61, 0x70, 0x70, 0x65, 0x72, 0x29, 0x20, 0x7b,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20,
+ 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x29, 0x20, 0x7b,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x76, 0x61, 0x72, 0x20, 0x61,
+ 0x72, 0x67, 0x73, 0x20, 0x3d, 0x20, 0x5b, 0x66, 0x75, 0x6e, 0x63, 0x5d,
+ 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x70, 0x75, 0x73, 0x68,
+ 0x2e, 0x61, 0x70, 0x70, 0x6c, 0x79, 0x28, 0x61, 0x72, 0x67, 0x73, 0x2c,
+ 0x20, 0x61, 0x72, 0x67, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x29, 0x3b,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72,
+ 0x6e, 0x20, 0x77, 0x72, 0x61, 0x70, 0x70, 0x65, 0x72, 0x2e, 0x61, 0x70,
+ 0x70, 0x6c, 0x79, 0x28, 0x74, 0x68, 0x69, 0x73, 0x2c, 0x20, 0x61, 0x72,
+ 0x67, 0x73, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x3b, 0x0a,
+ 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x52,
+ 0x65, 0x74, 0x75, 0x72, 0x6e, 0x73, 0x20, 0x61, 0x20, 0x66, 0x75, 0x6e,
+ 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x20, 0x74, 0x68, 0x61, 0x74, 0x20, 0x69,
+ 0x73, 0x20, 0x74, 0x68, 0x65, 0x20, 0x63, 0x6f, 0x6d, 0x70, 0x6f, 0x73,
+ 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x20, 0x6f, 0x66, 0x20, 0x61, 0x20, 0x6c,
+ 0x69, 0x73, 0x74, 0x20, 0x6f, 0x66, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74,
+ 0x69, 0x6f, 0x6e, 0x73, 0x2c, 0x20, 0x65, 0x61, 0x63, 0x68, 0x0a, 0x20,
+ 0x20, 0x2f, 0x2f, 0x20, 0x63, 0x6f, 0x6e, 0x73, 0x75, 0x6d, 0x69, 0x6e,
+ 0x67, 0x20, 0x74, 0x68, 0x65, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e,
+ 0x20, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x20, 0x6f, 0x66, 0x20, 0x74, 0x68,
+ 0x65, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x20, 0x74,
+ 0x68, 0x61, 0x74, 0x20, 0x66, 0x6f, 0x6c, 0x6c, 0x6f, 0x77, 0x73, 0x2e,
+ 0x0a, 0x20, 0x20, 0x5f, 0x2e, 0x63, 0x6f, 0x6d, 0x70, 0x6f, 0x73, 0x65,
+ 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28,
+ 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x76, 0x61, 0x72, 0x20,
+ 0x66, 0x75, 0x6e, 0x63, 0x73, 0x20, 0x3d, 0x20, 0x61, 0x72, 0x67, 0x75,
+ 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x72,
+ 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69,
+ 0x6f, 0x6e, 0x28, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x76, 0x61, 0x72, 0x20, 0x61, 0x72, 0x67, 0x73, 0x20, 0x3d, 0x20,
+ 0x61, 0x72, 0x67, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x3b, 0x0a, 0x20,
+ 0x20, 0x20, 0x20, 0x20, 0x20, 0x66, 0x6f, 0x72, 0x20, 0x28, 0x76, 0x61,
+ 0x72, 0x20, 0x69, 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x73, 0x2e,
+ 0x6c, 0x65, 0x6e, 0x67, 0x74, 0x68, 0x20, 0x2d, 0x20, 0x31, 0x3b, 0x20,
+ 0x69, 0x20, 0x3e, 0x3d, 0x20, 0x30, 0x3b, 0x20, 0x69, 0x2d, 0x2d, 0x29,
+ 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x61,
+ 0x72, 0x67, 0x73, 0x20, 0x3d, 0x20, 0x5b, 0x66, 0x75, 0x6e, 0x63, 0x73,
+ 0x5b, 0x69, 0x5d, 0x2e, 0x61, 0x70, 0x70, 0x6c, 0x79, 0x28, 0x74, 0x68,
+ 0x69, 0x73, 0x2c, 0x20, 0x61, 0x72, 0x67, 0x73, 0x29, 0x5d, 0x3b, 0x0a,
+ 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x61, 0x72, 0x67,
+ 0x73, 0x5b, 0x30, 0x5d, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x3b,
+ 0x0a, 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20,
+ 0x52, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x73, 0x20, 0x61, 0x20, 0x66, 0x75,
+ 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x20, 0x74, 0x68, 0x61, 0x74, 0x20,
+ 0x77, 0x69, 0x6c, 0x6c, 0x20, 0x6f, 0x6e, 0x6c, 0x79, 0x20, 0x62, 0x65,
+ 0x20, 0x65, 0x78, 0x65, 0x63, 0x75, 0x74, 0x65, 0x64, 0x20, 0x61, 0x66,
+ 0x74, 0x65, 0x72, 0x20, 0x62, 0x65, 0x69, 0x6e, 0x67, 0x20, 0x63, 0x61,
+ 0x6c, 0x6c, 0x65, 0x64, 0x20, 0x4e, 0x20, 0x74, 0x69, 0x6d, 0x65, 0x73,
+ 0x2e, 0x0a, 0x20, 0x20, 0x5f, 0x2e, 0x61, 0x66, 0x74, 0x65, 0x72, 0x20,
+ 0x3d, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x74,
+ 0x69, 0x6d, 0x65, 0x73, 0x2c, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x29, 0x20,
+ 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20, 0x28, 0x74, 0x69,
+ 0x6d, 0x65, 0x73, 0x20, 0x3c, 0x3d, 0x20, 0x30, 0x29, 0x20, 0x72, 0x65,
+ 0x74, 0x75, 0x72, 0x6e, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x28, 0x29, 0x3b,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20,
+ 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x29, 0x20, 0x7b,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20, 0x28, 0x2d,
+ 0x2d, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x20, 0x3c, 0x20, 0x31, 0x29, 0x20,
+ 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65,
+ 0x74, 0x75, 0x72, 0x6e, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x2e, 0x61, 0x70,
+ 0x70, 0x6c, 0x79, 0x28, 0x74, 0x68, 0x69, 0x73, 0x2c, 0x20, 0x61, 0x72,
+ 0x67, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x29, 0x3b, 0x0a, 0x20, 0x20,
+ 0x20, 0x20, 0x20, 0x20, 0x7d, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x3b,
+ 0x0a, 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20,
+ 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, 0x46, 0x75, 0x6e, 0x63, 0x74,
+ 0x69, 0x6f, 0x6e, 0x73, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x2d, 0x2d,
+ 0x2d, 0x2d, 0x2d, 0x2d, 0x2d, 0x2d, 0x2d, 0x2d, 0x2d, 0x2d, 0x2d, 0x2d,
+ 0x2d, 0x2d, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x52, 0x65, 0x74,
+ 0x72, 0x69, 0x65, 0x76, 0x65, 0x20, 0x74, 0x68, 0x65, 0x20, 0x6e, 0x61,
+ 0x6d, 0x65, 0x73, 0x20, 0x6f, 0x66, 0x20, 0x61, 0x6e, 0x20, 0x6f, 0x62,
+ 0x6a, 0x65, 0x63, 0x74, 0x27, 0x73, 0x20, 0x70, 0x72, 0x6f, 0x70, 0x65,
+ 0x72, 0x74, 0x69, 0x65, 0x73, 0x2e, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20,
+ 0x44, 0x65, 0x6c, 0x65, 0x67, 0x61, 0x74, 0x65, 0x73, 0x20, 0x74, 0x6f,
+ 0x20, 0x2a, 0x2a, 0x45, 0x43, 0x4d, 0x41, 0x53, 0x63, 0x72, 0x69, 0x70,
+ 0x74, 0x20, 0x35, 0x2a, 0x2a, 0x27, 0x73, 0x20, 0x6e, 0x61, 0x74, 0x69,
+ 0x76, 0x65, 0x20, 0x60, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x2e, 0x6b,
+ 0x65, 0x79, 0x73, 0x60, 0x0a, 0x20, 0x20, 0x5f, 0x2e, 0x6b, 0x65, 0x79,
+ 0x73, 0x20, 0x3d, 0x20, 0x6e, 0x61, 0x74, 0x69, 0x76, 0x65, 0x4b, 0x65,
+ 0x79, 0x73, 0x20, 0x7c, 0x7c, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69,
+ 0x6f, 0x6e, 0x28, 0x6f, 0x62, 0x6a, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20,
+ 0x20, 0x20, 0x69, 0x66, 0x20, 0x28, 0x6f, 0x62, 0x6a, 0x20, 0x21, 0x3d,
+ 0x3d, 0x20, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x28, 0x6f, 0x62, 0x6a,
+ 0x29, 0x29, 0x20, 0x74, 0x68, 0x72, 0x6f, 0x77, 0x20, 0x6e, 0x65, 0x77,
+ 0x20, 0x54, 0x79, 0x70, 0x65, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x28, 0x27,
+ 0x49, 0x6e, 0x76, 0x61, 0x6c, 0x69, 0x64, 0x20, 0x6f, 0x62, 0x6a, 0x65,
+ 0x63, 0x74, 0x27, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x76, 0x61,
+ 0x72, 0x20, 0x6b, 0x65, 0x79, 0x73, 0x20, 0x3d, 0x20, 0x5b, 0x5d, 0x3b,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x66, 0x6f, 0x72, 0x20, 0x28, 0x76, 0x61,
+ 0x72, 0x20, 0x6b, 0x65, 0x79, 0x20, 0x69, 0x6e, 0x20, 0x6f, 0x62, 0x6a,
+ 0x29, 0x20, 0x69, 0x66, 0x20, 0x28, 0x5f, 0x2e, 0x68, 0x61, 0x73, 0x28,
+ 0x6f, 0x62, 0x6a, 0x2c, 0x20, 0x6b, 0x65, 0x79, 0x29, 0x29, 0x20, 0x6b,
+ 0x65, 0x79, 0x73, 0x5b, 0x6b, 0x65, 0x79, 0x73, 0x2e, 0x6c, 0x65, 0x6e,
+ 0x67, 0x74, 0x68, 0x5d, 0x20, 0x3d, 0x20, 0x6b, 0x65, 0x79, 0x3b, 0x0a,
+ 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x6b,
+ 0x65, 0x79, 0x73, 0x3b, 0x0a, 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x0a, 0x20,
+ 0x20, 0x2f, 0x2f, 0x20, 0x52, 0x65, 0x74, 0x72, 0x69, 0x65, 0x76, 0x65,
+ 0x20, 0x74, 0x68, 0x65, 0x20, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x73, 0x20,
+ 0x6f, 0x66, 0x20, 0x61, 0x6e, 0x20, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74,
+ 0x27, 0x73, 0x20, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x69, 0x65,
+ 0x73, 0x2e, 0x0a, 0x20, 0x20, 0x5f, 0x2e, 0x76, 0x61, 0x6c, 0x75, 0x65,
+ 0x73, 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e,
+ 0x28, 0x6f, 0x62, 0x6a, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x76, 0x61, 0x72, 0x20, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x73, 0x20, 0x3d,
+ 0x20, 0x5b, 0x5d, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x66, 0x6f, 0x72,
+ 0x20, 0x28, 0x76, 0x61, 0x72, 0x20, 0x6b, 0x65, 0x79, 0x20, 0x69, 0x6e,
+ 0x20, 0x6f, 0x62, 0x6a, 0x29, 0x20, 0x69, 0x66, 0x20, 0x28, 0x5f, 0x2e,
+ 0x68, 0x61, 0x73, 0x28, 0x6f, 0x62, 0x6a, 0x2c, 0x20, 0x6b, 0x65, 0x79,
+ 0x29, 0x29, 0x20, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x73, 0x2e, 0x70, 0x75,
+ 0x73, 0x68, 0x28, 0x6f, 0x62, 0x6a, 0x5b, 0x6b, 0x65, 0x79, 0x5d, 0x29,
+ 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e,
+ 0x20, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x73, 0x3b, 0x0a, 0x20, 0x20, 0x7d,
+ 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x43, 0x6f, 0x6e, 0x76,
+ 0x65, 0x72, 0x74, 0x20, 0x61, 0x6e, 0x20, 0x6f, 0x62, 0x6a, 0x65, 0x63,
+ 0x74, 0x20, 0x69, 0x6e, 0x74, 0x6f, 0x20, 0x61, 0x20, 0x6c, 0x69, 0x73,
+ 0x74, 0x20, 0x6f, 0x66, 0x20, 0x60, 0x5b, 0x6b, 0x65, 0x79, 0x2c, 0x20,
+ 0x76, 0x61, 0x6c, 0x75, 0x65, 0x5d, 0x60, 0x20, 0x70, 0x61, 0x69, 0x72,
+ 0x73, 0x2e, 0x0a, 0x20, 0x20, 0x5f, 0x2e, 0x70, 0x61, 0x69, 0x72, 0x73,
+ 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28,
+ 0x6f, 0x62, 0x6a, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x76,
+ 0x61, 0x72, 0x20, 0x70, 0x61, 0x69, 0x72, 0x73, 0x20, 0x3d, 0x20, 0x5b,
+ 0x5d, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x66, 0x6f, 0x72, 0x20, 0x28,
+ 0x76, 0x61, 0x72, 0x20, 0x6b, 0x65, 0x79, 0x20, 0x69, 0x6e, 0x20, 0x6f,
+ 0x62, 0x6a, 0x29, 0x20, 0x69, 0x66, 0x20, 0x28, 0x5f, 0x2e, 0x68, 0x61,
+ 0x73, 0x28, 0x6f, 0x62, 0x6a, 0x2c, 0x20, 0x6b, 0x65, 0x79, 0x29, 0x29,
+ 0x20, 0x70, 0x61, 0x69, 0x72, 0x73, 0x2e, 0x70, 0x75, 0x73, 0x68, 0x28,
+ 0x5b, 0x6b, 0x65, 0x79, 0x2c, 0x20, 0x6f, 0x62, 0x6a, 0x5b, 0x6b, 0x65,
+ 0x79, 0x5d, 0x5d, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65,
+ 0x74, 0x75, 0x72, 0x6e, 0x20, 0x70, 0x61, 0x69, 0x72, 0x73, 0x3b, 0x0a,
+ 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x49,
+ 0x6e, 0x76, 0x65, 0x72, 0x74, 0x20, 0x74, 0x68, 0x65, 0x20, 0x6b, 0x65,
+ 0x79, 0x73, 0x20, 0x61, 0x6e, 0x64, 0x20, 0x76, 0x61, 0x6c, 0x75, 0x65,
+ 0x73, 0x20, 0x6f, 0x66, 0x20, 0x61, 0x6e, 0x20, 0x6f, 0x62, 0x6a, 0x65,
+ 0x63, 0x74, 0x2e, 0x20, 0x54, 0x68, 0x65, 0x20, 0x76, 0x61, 0x6c, 0x75,
+ 0x65, 0x73, 0x20, 0x6d, 0x75, 0x73, 0x74, 0x20, 0x62, 0x65, 0x20, 0x73,
+ 0x65, 0x72, 0x69, 0x61, 0x6c, 0x69, 0x7a, 0x61, 0x62, 0x6c, 0x65, 0x2e,
+ 0x0a, 0x20, 0x20, 0x5f, 0x2e, 0x69, 0x6e, 0x76, 0x65, 0x72, 0x74, 0x20,
+ 0x3d, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x6f,
+ 0x62, 0x6a, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x76, 0x61,
+ 0x72, 0x20, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x20, 0x3d, 0x20, 0x7b,
+ 0x7d, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x66, 0x6f, 0x72, 0x20, 0x28,
+ 0x76, 0x61, 0x72, 0x20, 0x6b, 0x65, 0x79, 0x20, 0x69, 0x6e, 0x20, 0x6f,
+ 0x62, 0x6a, 0x29, 0x20, 0x69, 0x66, 0x20, 0x28, 0x5f, 0x2e, 0x68, 0x61,
+ 0x73, 0x28, 0x6f, 0x62, 0x6a, 0x2c, 0x20, 0x6b, 0x65, 0x79, 0x29, 0x29,
+ 0x20, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x5b, 0x6f, 0x62, 0x6a, 0x5b,
+ 0x6b, 0x65, 0x79, 0x5d, 0x5d, 0x20, 0x3d, 0x20, 0x6b, 0x65, 0x79, 0x3b,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20,
+ 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x3b, 0x0a, 0x20, 0x20, 0x7d, 0x3b,
+ 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x52, 0x65, 0x74, 0x75, 0x72,
+ 0x6e, 0x20, 0x61, 0x20, 0x73, 0x6f, 0x72, 0x74, 0x65, 0x64, 0x20, 0x6c,
+ 0x69, 0x73, 0x74, 0x20, 0x6f, 0x66, 0x20, 0x74, 0x68, 0x65, 0x20, 0x66,
+ 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x20, 0x6e, 0x61, 0x6d, 0x65,
+ 0x73, 0x20, 0x61, 0x76, 0x61, 0x69, 0x6c, 0x61, 0x62, 0x6c, 0x65, 0x20,
+ 0x6f, 0x6e, 0x20, 0x74, 0x68, 0x65, 0x20, 0x6f, 0x62, 0x6a, 0x65, 0x63,
+ 0x74, 0x2e, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x41, 0x6c, 0x69, 0x61,
+ 0x73, 0x65, 0x64, 0x20, 0x61, 0x73, 0x20, 0x60, 0x6d, 0x65, 0x74, 0x68,
+ 0x6f, 0x64, 0x73, 0x60, 0x0a, 0x20, 0x20, 0x5f, 0x2e, 0x66, 0x75, 0x6e,
+ 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x20, 0x3d, 0x20, 0x5f, 0x2e, 0x6d,
+ 0x65, 0x74, 0x68, 0x6f, 0x64, 0x73, 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e,
+ 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x6f, 0x62, 0x6a, 0x29, 0x20, 0x7b,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x76, 0x61, 0x72, 0x20, 0x6e, 0x61, 0x6d,
+ 0x65, 0x73, 0x20, 0x3d, 0x20, 0x5b, 0x5d, 0x3b, 0x0a, 0x20, 0x20, 0x20,
+ 0x20, 0x66, 0x6f, 0x72, 0x20, 0x28, 0x76, 0x61, 0x72, 0x20, 0x6b, 0x65,
+ 0x79, 0x20, 0x69, 0x6e, 0x20, 0x6f, 0x62, 0x6a, 0x29, 0x20, 0x7b, 0x0a,
+ 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20, 0x28, 0x5f, 0x2e,
+ 0x69, 0x73, 0x46, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x6f,
+ 0x62, 0x6a, 0x5b, 0x6b, 0x65, 0x79, 0x5d, 0x29, 0x29, 0x20, 0x6e, 0x61,
+ 0x6d, 0x65, 0x73, 0x2e, 0x70, 0x75, 0x73, 0x68, 0x28, 0x6b, 0x65, 0x79,
+ 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x0a, 0x20, 0x20, 0x20,
+ 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x6e, 0x61, 0x6d, 0x65,
+ 0x73, 0x2e, 0x73, 0x6f, 0x72, 0x74, 0x28, 0x29, 0x3b, 0x0a, 0x20, 0x20,
+ 0x7d, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x45, 0x78, 0x74,
+ 0x65, 0x6e, 0x64, 0x20, 0x61, 0x20, 0x67, 0x69, 0x76, 0x65, 0x6e, 0x20,
+ 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, 0x77, 0x69, 0x74, 0x68, 0x20,
+ 0x61, 0x6c, 0x6c, 0x20, 0x74, 0x68, 0x65, 0x20, 0x70, 0x72, 0x6f, 0x70,
+ 0x65, 0x72, 0x74, 0x69, 0x65, 0x73, 0x20, 0x69, 0x6e, 0x20, 0x70, 0x61,
+ 0x73, 0x73, 0x65, 0x64, 0x2d, 0x69, 0x6e, 0x20, 0x6f, 0x62, 0x6a, 0x65,
+ 0x63, 0x74, 0x28, 0x73, 0x29, 0x2e, 0x0a, 0x20, 0x20, 0x5f, 0x2e, 0x65,
+ 0x78, 0x74, 0x65, 0x6e, 0x64, 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e, 0x63,
+ 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x6f, 0x62, 0x6a, 0x29, 0x20, 0x7b, 0x0a,
+ 0x20, 0x20, 0x20, 0x20, 0x65, 0x61, 0x63, 0x68, 0x28, 0x73, 0x6c, 0x69,
+ 0x63, 0x65, 0x2e, 0x63, 0x61, 0x6c, 0x6c, 0x28, 0x61, 0x72, 0x67, 0x75,
+ 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x2c, 0x20, 0x31, 0x29, 0x2c, 0x20, 0x66,
+ 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x73, 0x6f, 0x75, 0x72,
+ 0x63, 0x65, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x69, 0x66, 0x20, 0x28, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x29, 0x20,
+ 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x66, 0x6f,
+ 0x72, 0x20, 0x28, 0x76, 0x61, 0x72, 0x20, 0x70, 0x72, 0x6f, 0x70, 0x20,
+ 0x69, 0x6e, 0x20, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x29, 0x20, 0x7b,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x6f,
+ 0x62, 0x6a, 0x5b, 0x70, 0x72, 0x6f, 0x70, 0x5d, 0x20, 0x3d, 0x20, 0x73,
+ 0x6f, 0x75, 0x72, 0x63, 0x65, 0x5b, 0x70, 0x72, 0x6f, 0x70, 0x5d, 0x3b,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x0a, 0x20,
+ 0x20, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x7d,
+ 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72,
+ 0x6e, 0x20, 0x6f, 0x62, 0x6a, 0x3b, 0x0a, 0x20, 0x20, 0x7d, 0x3b, 0x0a,
+ 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x52, 0x65, 0x74, 0x75, 0x72, 0x6e,
+ 0x20, 0x61, 0x20, 0x63, 0x6f, 0x70, 0x79, 0x20, 0x6f, 0x66, 0x20, 0x74,
+ 0x68, 0x65, 0x20, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, 0x6f, 0x6e,
+ 0x6c, 0x79, 0x20, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x69, 0x6e,
+ 0x67, 0x20, 0x74, 0x68, 0x65, 0x20, 0x77, 0x68, 0x69, 0x74, 0x65, 0x6c,
+ 0x69, 0x73, 0x74, 0x65, 0x64, 0x20, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72,
+ 0x74, 0x69, 0x65, 0x73, 0x2e, 0x0a, 0x20, 0x20, 0x5f, 0x2e, 0x70, 0x69,
+ 0x63, 0x6b, 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f,
+ 0x6e, 0x28, 0x6f, 0x62, 0x6a, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20,
+ 0x20, 0x76, 0x61, 0x72, 0x20, 0x63, 0x6f, 0x70, 0x79, 0x20, 0x3d, 0x20,
+ 0x7b, 0x7d, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x76, 0x61, 0x72, 0x20,
+ 0x6b, 0x65, 0x79, 0x73, 0x20, 0x3d, 0x20, 0x63, 0x6f, 0x6e, 0x63, 0x61,
+ 0x74, 0x2e, 0x61, 0x70, 0x70, 0x6c, 0x79, 0x28, 0x41, 0x72, 0x72, 0x61,
+ 0x79, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x2c, 0x20, 0x73, 0x6c, 0x69, 0x63,
+ 0x65, 0x2e, 0x63, 0x61, 0x6c, 0x6c, 0x28, 0x61, 0x72, 0x67, 0x75, 0x6d,
+ 0x65, 0x6e, 0x74, 0x73, 0x2c, 0x20, 0x31, 0x29, 0x29, 0x3b, 0x0a, 0x20,
+ 0x20, 0x20, 0x20, 0x65, 0x61, 0x63, 0x68, 0x28, 0x6b, 0x65, 0x79, 0x73,
+ 0x2c, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x6b,
+ 0x65, 0x79, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x69, 0x66, 0x20, 0x28, 0x6b, 0x65, 0x79, 0x20, 0x69, 0x6e, 0x20, 0x6f,
+ 0x62, 0x6a, 0x29, 0x20, 0x63, 0x6f, 0x70, 0x79, 0x5b, 0x6b, 0x65, 0x79,
+ 0x5d, 0x20, 0x3d, 0x20, 0x6f, 0x62, 0x6a, 0x5b, 0x6b, 0x65, 0x79, 0x5d,
+ 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x29, 0x3b, 0x0a, 0x20, 0x20,
+ 0x20, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x63, 0x6f, 0x70,
+ 0x79, 0x3b, 0x0a, 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x20,
+ 0x2f, 0x2f, 0x20, 0x52, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x61, 0x20,
+ 0x63, 0x6f, 0x70, 0x79, 0x20, 0x6f, 0x66, 0x20, 0x74, 0x68, 0x65, 0x20,
+ 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, 0x77, 0x69, 0x74, 0x68, 0x6f,
+ 0x75, 0x74, 0x20, 0x74, 0x68, 0x65, 0x20, 0x62, 0x6c, 0x61, 0x63, 0x6b,
+ 0x6c, 0x69, 0x73, 0x74, 0x65, 0x64, 0x20, 0x70, 0x72, 0x6f, 0x70, 0x65,
+ 0x72, 0x74, 0x69, 0x65, 0x73, 0x2e, 0x0a, 0x20, 0x20, 0x5f, 0x2e, 0x6f,
+ 0x6d, 0x69, 0x74, 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69,
+ 0x6f, 0x6e, 0x28, 0x6f, 0x62, 0x6a, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20,
+ 0x20, 0x20, 0x76, 0x61, 0x72, 0x20, 0x63, 0x6f, 0x70, 0x79, 0x20, 0x3d,
+ 0x20, 0x7b, 0x7d, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x76, 0x61, 0x72,
+ 0x20, 0x6b, 0x65, 0x79, 0x73, 0x20, 0x3d, 0x20, 0x63, 0x6f, 0x6e, 0x63,
+ 0x61, 0x74, 0x2e, 0x61, 0x70, 0x70, 0x6c, 0x79, 0x28, 0x41, 0x72, 0x72,
+ 0x61, 0x79, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x2c, 0x20, 0x73, 0x6c, 0x69,
+ 0x63, 0x65, 0x2e, 0x63, 0x61, 0x6c, 0x6c, 0x28, 0x61, 0x72, 0x67, 0x75,
+ 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x2c, 0x20, 0x31, 0x29, 0x29, 0x3b, 0x0a,
+ 0x20, 0x20, 0x20, 0x20, 0x66, 0x6f, 0x72, 0x20, 0x28, 0x76, 0x61, 0x72,
+ 0x20, 0x6b, 0x65, 0x79, 0x20, 0x69, 0x6e, 0x20, 0x6f, 0x62, 0x6a, 0x29,
+ 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20,
+ 0x28, 0x21, 0x5f, 0x2e, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x73,
+ 0x28, 0x6b, 0x65, 0x79, 0x73, 0x2c, 0x20, 0x6b, 0x65, 0x79, 0x29, 0x29,
+ 0x20, 0x63, 0x6f, 0x70, 0x79, 0x5b, 0x6b, 0x65, 0x79, 0x5d, 0x20, 0x3d,
+ 0x20, 0x6f, 0x62, 0x6a, 0x5b, 0x6b, 0x65, 0x79, 0x5d, 0x3b, 0x0a, 0x20,
+ 0x20, 0x20, 0x20, 0x7d, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74,
+ 0x75, 0x72, 0x6e, 0x20, 0x63, 0x6f, 0x70, 0x79, 0x3b, 0x0a, 0x20, 0x20,
+ 0x7d, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x46, 0x69, 0x6c,
+ 0x6c, 0x20, 0x69, 0x6e, 0x20, 0x61, 0x20, 0x67, 0x69, 0x76, 0x65, 0x6e,
+ 0x20, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, 0x77, 0x69, 0x74, 0x68,
+ 0x20, 0x64, 0x65, 0x66, 0x61, 0x75, 0x6c, 0x74, 0x20, 0x70, 0x72, 0x6f,
+ 0x70, 0x65, 0x72, 0x74, 0x69, 0x65, 0x73, 0x2e, 0x0a, 0x20, 0x20, 0x5f,
+ 0x2e, 0x64, 0x65, 0x66, 0x61, 0x75, 0x6c, 0x74, 0x73, 0x20, 0x3d, 0x20,
+ 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x6f, 0x62, 0x6a,
+ 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x65, 0x61, 0x63, 0x68,
+ 0x28, 0x73, 0x6c, 0x69, 0x63, 0x65, 0x2e, 0x63, 0x61, 0x6c, 0x6c, 0x28,
+ 0x61, 0x72, 0x67, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x2c, 0x20, 0x31,
+ 0x29, 0x2c, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28,
+ 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20,
+ 0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20, 0x28, 0x73, 0x6f, 0x75, 0x72,
+ 0x63, 0x65, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x66, 0x6f, 0x72, 0x20, 0x28, 0x76, 0x61, 0x72, 0x20, 0x70,
+ 0x72, 0x6f, 0x70, 0x20, 0x69, 0x6e, 0x20, 0x73, 0x6f, 0x75, 0x72, 0x63,
+ 0x65, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x20, 0x69, 0x66, 0x20, 0x28, 0x6f, 0x62, 0x6a, 0x5b, 0x70,
+ 0x72, 0x6f, 0x70, 0x5d, 0x20, 0x3d, 0x3d, 0x20, 0x6e, 0x75, 0x6c, 0x6c,
+ 0x29, 0x20, 0x6f, 0x62, 0x6a, 0x5b, 0x70, 0x72, 0x6f, 0x70, 0x5d, 0x20,
+ 0x3d, 0x20, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x5b, 0x70, 0x72, 0x6f,
+ 0x70, 0x5d, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x7d, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x0a, 0x20, 0x20,
+ 0x20, 0x20, 0x7d, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65,
+ 0x74, 0x75, 0x72, 0x6e, 0x20, 0x6f, 0x62, 0x6a, 0x3b, 0x0a, 0x20, 0x20,
+ 0x7d, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x43, 0x72, 0x65,
+ 0x61, 0x74, 0x65, 0x20, 0x61, 0x20, 0x28, 0x73, 0x68, 0x61, 0x6c, 0x6c,
+ 0x6f, 0x77, 0x2d, 0x63, 0x6c, 0x6f, 0x6e, 0x65, 0x64, 0x29, 0x20, 0x64,
+ 0x75, 0x70, 0x6c, 0x69, 0x63, 0x61, 0x74, 0x65, 0x20, 0x6f, 0x66, 0x20,
+ 0x61, 0x6e, 0x20, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x2e, 0x0a, 0x20,
+ 0x20, 0x5f, 0x2e, 0x63, 0x6c, 0x6f, 0x6e, 0x65, 0x20, 0x3d, 0x20, 0x66,
+ 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x6f, 0x62, 0x6a, 0x29,
+ 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20, 0x28, 0x21,
+ 0x5f, 0x2e, 0x69, 0x73, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x28, 0x6f,
+ 0x62, 0x6a, 0x29, 0x29, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20,
+ 0x6f, 0x62, 0x6a, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74,
+ 0x75, 0x72, 0x6e, 0x20, 0x5f, 0x2e, 0x69, 0x73, 0x41, 0x72, 0x72, 0x61,
+ 0x79, 0x28, 0x6f, 0x62, 0x6a, 0x29, 0x20, 0x3f, 0x20, 0x6f, 0x62, 0x6a,
+ 0x2e, 0x73, 0x6c, 0x69, 0x63, 0x65, 0x28, 0x29, 0x20, 0x3a, 0x20, 0x5f,
+ 0x2e, 0x65, 0x78, 0x74, 0x65, 0x6e, 0x64, 0x28, 0x7b, 0x7d, 0x2c, 0x20,
+ 0x6f, 0x62, 0x6a, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x0a,
+ 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x49, 0x6e, 0x76, 0x6f, 0x6b, 0x65, 0x73,
+ 0x20, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x63, 0x65, 0x70, 0x74, 0x6f, 0x72,
+ 0x20, 0x77, 0x69, 0x74, 0x68, 0x20, 0x74, 0x68, 0x65, 0x20, 0x6f, 0x62,
+ 0x6a, 0x2c, 0x20, 0x61, 0x6e, 0x64, 0x20, 0x74, 0x68, 0x65, 0x6e, 0x20,
+ 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x73, 0x20, 0x6f, 0x62, 0x6a, 0x2e,
+ 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x54, 0x68, 0x65, 0x20, 0x70, 0x72,
+ 0x69, 0x6d, 0x61, 0x72, 0x79, 0x20, 0x70, 0x75, 0x72, 0x70, 0x6f, 0x73,
+ 0x65, 0x20, 0x6f, 0x66, 0x20, 0x74, 0x68, 0x69, 0x73, 0x20, 0x6d, 0x65,
+ 0x74, 0x68, 0x6f, 0x64, 0x20, 0x69, 0x73, 0x20, 0x74, 0x6f, 0x20, 0x22,
+ 0x74, 0x61, 0x70, 0x20, 0x69, 0x6e, 0x74, 0x6f, 0x22, 0x20, 0x61, 0x20,
+ 0x6d, 0x65, 0x74, 0x68, 0x6f, 0x64, 0x20, 0x63, 0x68, 0x61, 0x69, 0x6e,
+ 0x2c, 0x20, 0x69, 0x6e, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x6f, 0x72,
+ 0x64, 0x65, 0x72, 0x20, 0x74, 0x6f, 0x20, 0x70, 0x65, 0x72, 0x66, 0x6f,
+ 0x72, 0x6d, 0x20, 0x6f, 0x70, 0x65, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e,
+ 0x73, 0x20, 0x6f, 0x6e, 0x20, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x6d, 0x65,
+ 0x64, 0x69, 0x61, 0x74, 0x65, 0x20, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74,
+ 0x73, 0x20, 0x77, 0x69, 0x74, 0x68, 0x69, 0x6e, 0x20, 0x74, 0x68, 0x65,
+ 0x20, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x2e, 0x0a, 0x20, 0x20, 0x5f, 0x2e,
+ 0x74, 0x61, 0x70, 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69,
+ 0x6f, 0x6e, 0x28, 0x6f, 0x62, 0x6a, 0x2c, 0x20, 0x69, 0x6e, 0x74, 0x65,
+ 0x72, 0x63, 0x65, 0x70, 0x74, 0x6f, 0x72, 0x29, 0x20, 0x7b, 0x0a, 0x20,
+ 0x20, 0x20, 0x20, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x63, 0x65, 0x70, 0x74,
+ 0x6f, 0x72, 0x28, 0x6f, 0x62, 0x6a, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20,
+ 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x6f, 0x62, 0x6a, 0x3b,
+ 0x0a, 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20,
+ 0x49, 0x6e, 0x74, 0x65, 0x72, 0x6e, 0x61, 0x6c, 0x20, 0x72, 0x65, 0x63,
+ 0x75, 0x72, 0x73, 0x69, 0x76, 0x65, 0x20, 0x63, 0x6f, 0x6d, 0x70, 0x61,
+ 0x72, 0x69, 0x73, 0x6f, 0x6e, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69,
+ 0x6f, 0x6e, 0x20, 0x66, 0x6f, 0x72, 0x20, 0x60, 0x69, 0x73, 0x45, 0x71,
+ 0x75, 0x61, 0x6c, 0x60, 0x2e, 0x0a, 0x20, 0x20, 0x76, 0x61, 0x72, 0x20,
+ 0x65, 0x71, 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f,
+ 0x6e, 0x28, 0x61, 0x2c, 0x20, 0x62, 0x2c, 0x20, 0x61, 0x53, 0x74, 0x61,
+ 0x63, 0x6b, 0x2c, 0x20, 0x62, 0x53, 0x74, 0x61, 0x63, 0x6b, 0x29, 0x20,
+ 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x49, 0x64, 0x65,
+ 0x6e, 0x74, 0x69, 0x63, 0x61, 0x6c, 0x20, 0x6f, 0x62, 0x6a, 0x65, 0x63,
+ 0x74, 0x73, 0x20, 0x61, 0x72, 0x65, 0x20, 0x65, 0x71, 0x75, 0x61, 0x6c,
+ 0x2e, 0x20, 0x60, 0x30, 0x20, 0x3d, 0x3d, 0x3d, 0x20, 0x2d, 0x30, 0x60,
+ 0x2c, 0x20, 0x62, 0x75, 0x74, 0x20, 0x74, 0x68, 0x65, 0x79, 0x20, 0x61,
+ 0x72, 0x65, 0x6e, 0x27, 0x74, 0x20, 0x69, 0x64, 0x65, 0x6e, 0x74, 0x69,
+ 0x63, 0x61, 0x6c, 0x2e, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x2f, 0x2f, 0x20,
+ 0x53, 0x65, 0x65, 0x20, 0x74, 0x68, 0x65, 0x20, 0x48, 0x61, 0x72, 0x6d,
+ 0x6f, 0x6e, 0x79, 0x20, 0x60, 0x65, 0x67, 0x61, 0x6c, 0x60, 0x20, 0x70,
+ 0x72, 0x6f, 0x70, 0x6f, 0x73, 0x61, 0x6c, 0x3a, 0x20, 0x68, 0x74, 0x74,
+ 0x70, 0x3a, 0x2f, 0x2f, 0x77, 0x69, 0x6b, 0x69, 0x2e, 0x65, 0x63, 0x6d,
+ 0x61, 0x73, 0x63, 0x72, 0x69, 0x70, 0x74, 0x2e, 0x6f, 0x72, 0x67, 0x2f,
+ 0x64, 0x6f, 0x6b, 0x75, 0x2e, 0x70, 0x68, 0x70, 0x3f, 0x69, 0x64, 0x3d,
+ 0x68, 0x61, 0x72, 0x6d, 0x6f, 0x6e, 0x79, 0x3a, 0x65, 0x67, 0x61, 0x6c,
+ 0x2e, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20, 0x28, 0x61, 0x20,
+ 0x3d, 0x3d, 0x3d, 0x20, 0x62, 0x29, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72,
+ 0x6e, 0x20, 0x61, 0x20, 0x21, 0x3d, 0x3d, 0x20, 0x30, 0x20, 0x7c, 0x7c,
+ 0x20, 0x31, 0x20, 0x2f, 0x20, 0x61, 0x20, 0x3d, 0x3d, 0x20, 0x31, 0x20,
+ 0x2f, 0x20, 0x62, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x2f, 0x2f, 0x20,
+ 0x41, 0x20, 0x73, 0x74, 0x72, 0x69, 0x63, 0x74, 0x20, 0x63, 0x6f, 0x6d,
+ 0x70, 0x61, 0x72, 0x69, 0x73, 0x6f, 0x6e, 0x20, 0x69, 0x73, 0x20, 0x6e,
+ 0x65, 0x63, 0x65, 0x73, 0x73, 0x61, 0x72, 0x79, 0x20, 0x62, 0x65, 0x63,
+ 0x61, 0x75, 0x73, 0x65, 0x20, 0x60, 0x6e, 0x75, 0x6c, 0x6c, 0x20, 0x3d,
+ 0x3d, 0x20, 0x75, 0x6e, 0x64, 0x65, 0x66, 0x69, 0x6e, 0x65, 0x64, 0x60,
+ 0x2e, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20, 0x28, 0x61, 0x20,
+ 0x3d, 0x3d, 0x20, 0x6e, 0x75, 0x6c, 0x6c, 0x20, 0x7c, 0x7c, 0x20, 0x62,
+ 0x20, 0x3d, 0x3d, 0x20, 0x6e, 0x75, 0x6c, 0x6c, 0x29, 0x20, 0x72, 0x65,
+ 0x74, 0x75, 0x72, 0x6e, 0x20, 0x61, 0x20, 0x3d, 0x3d, 0x3d, 0x20, 0x62,
+ 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x55, 0x6e, 0x77,
+ 0x72, 0x61, 0x70, 0x20, 0x61, 0x6e, 0x79, 0x20, 0x77, 0x72, 0x61, 0x70,
+ 0x70, 0x65, 0x64, 0x20, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x73, 0x2e,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20, 0x28, 0x61, 0x20, 0x69,
+ 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x6f, 0x66, 0x20, 0x5f, 0x29,
+ 0x20, 0x61, 0x20, 0x3d, 0x20, 0x61, 0x2e, 0x5f, 0x77, 0x72, 0x61, 0x70,
+ 0x70, 0x65, 0x64, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20,
+ 0x28, 0x62, 0x20, 0x69, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x6f,
+ 0x66, 0x20, 0x5f, 0x29, 0x20, 0x62, 0x20, 0x3d, 0x20, 0x62, 0x2e, 0x5f,
+ 0x77, 0x72, 0x61, 0x70, 0x70, 0x65, 0x64, 0x3b, 0x0a, 0x20, 0x20, 0x20,
+ 0x20, 0x2f, 0x2f, 0x20, 0x43, 0x6f, 0x6d, 0x70, 0x61, 0x72, 0x65, 0x20,
+ 0x60, 0x5b, 0x5b, 0x43, 0x6c, 0x61, 0x73, 0x73, 0x5d, 0x5d, 0x60, 0x20,
+ 0x6e, 0x61, 0x6d, 0x65, 0x73, 0x2e, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x76,
+ 0x61, 0x72, 0x20, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x4e, 0x61, 0x6d, 0x65,
+ 0x20, 0x3d, 0x20, 0x74, 0x6f, 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x2e,
+ 0x63, 0x61, 0x6c, 0x6c, 0x28, 0x61, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20,
+ 0x20, 0x69, 0x66, 0x20, 0x28, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x4e, 0x61,
+ 0x6d, 0x65, 0x20, 0x21, 0x3d, 0x20, 0x74, 0x6f, 0x53, 0x74, 0x72, 0x69,
+ 0x6e, 0x67, 0x2e, 0x63, 0x61, 0x6c, 0x6c, 0x28, 0x62, 0x29, 0x29, 0x20,
+ 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x66, 0x61, 0x6c, 0x73, 0x65,
+ 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x73, 0x77, 0x69, 0x74, 0x63, 0x68,
+ 0x20, 0x28, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x4e, 0x61, 0x6d, 0x65, 0x29,
+ 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x2f, 0x2f, 0x20,
+ 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x73, 0x2c, 0x20, 0x6e, 0x75, 0x6d,
+ 0x62, 0x65, 0x72, 0x73, 0x2c, 0x20, 0x64, 0x61, 0x74, 0x65, 0x73, 0x2c,
+ 0x20, 0x61, 0x6e, 0x64, 0x20, 0x62, 0x6f, 0x6f, 0x6c, 0x65, 0x61, 0x6e,
+ 0x73, 0x20, 0x61, 0x72, 0x65, 0x20, 0x63, 0x6f, 0x6d, 0x70, 0x61, 0x72,
+ 0x65, 0x64, 0x20, 0x62, 0x79, 0x20, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x2e,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x63, 0x61, 0x73, 0x65, 0x20,
+ 0x27, 0x5b, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, 0x53, 0x74, 0x72,
+ 0x69, 0x6e, 0x67, 0x5d, 0x27, 0x3a, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x50, 0x72, 0x69, 0x6d, 0x69, 0x74,
+ 0x69, 0x76, 0x65, 0x73, 0x20, 0x61, 0x6e, 0x64, 0x20, 0x74, 0x68, 0x65,
+ 0x69, 0x72, 0x20, 0x63, 0x6f, 0x72, 0x72, 0x65, 0x73, 0x70, 0x6f, 0x6e,
+ 0x64, 0x69, 0x6e, 0x67, 0x20, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20,
+ 0x77, 0x72, 0x61, 0x70, 0x70, 0x65, 0x72, 0x73, 0x20, 0x61, 0x72, 0x65,
+ 0x20, 0x65, 0x71, 0x75, 0x69, 0x76, 0x61, 0x6c, 0x65, 0x6e, 0x74, 0x3b,
+ 0x20, 0x74, 0x68, 0x75, 0x73, 0x2c, 0x20, 0x60, 0x22, 0x35, 0x22, 0x60,
+ 0x20, 0x69, 0x73, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x2f, 0x2f, 0x20, 0x65, 0x71, 0x75, 0x69, 0x76, 0x61, 0x6c, 0x65, 0x6e,
+ 0x74, 0x20, 0x74, 0x6f, 0x20, 0x60, 0x6e, 0x65, 0x77, 0x20, 0x53, 0x74,
+ 0x72, 0x69, 0x6e, 0x67, 0x28, 0x22, 0x35, 0x22, 0x29, 0x60, 0x2e, 0x0a,
+ 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74, 0x75,
+ 0x72, 0x6e, 0x20, 0x61, 0x20, 0x3d, 0x3d, 0x20, 0x53, 0x74, 0x72, 0x69,
+ 0x6e, 0x67, 0x28, 0x62, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x63, 0x61, 0x73, 0x65, 0x20, 0x27, 0x5b, 0x6f, 0x62, 0x6a, 0x65,
+ 0x63, 0x74, 0x20, 0x4e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x5d, 0x27, 0x3a,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x2f, 0x2f, 0x20,
+ 0x60, 0x4e, 0x61, 0x4e, 0x60, 0x73, 0x20, 0x61, 0x72, 0x65, 0x20, 0x65,
+ 0x71, 0x75, 0x69, 0x76, 0x61, 0x6c, 0x65, 0x6e, 0x74, 0x2c, 0x20, 0x62,
+ 0x75, 0x74, 0x20, 0x6e, 0x6f, 0x6e, 0x2d, 0x72, 0x65, 0x66, 0x6c, 0x65,
+ 0x78, 0x69, 0x76, 0x65, 0x2e, 0x20, 0x41, 0x6e, 0x20, 0x60, 0x65, 0x67,
+ 0x61, 0x6c, 0x60, 0x20, 0x63, 0x6f, 0x6d, 0x70, 0x61, 0x72, 0x69, 0x73,
+ 0x6f, 0x6e, 0x20, 0x69, 0x73, 0x20, 0x70, 0x65, 0x72, 0x66, 0x6f, 0x72,
+ 0x6d, 0x65, 0x64, 0x20, 0x66, 0x6f, 0x72, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x6f, 0x74, 0x68, 0x65, 0x72,
+ 0x20, 0x6e, 0x75, 0x6d, 0x65, 0x72, 0x69, 0x63, 0x20, 0x76, 0x61, 0x6c,
+ 0x75, 0x65, 0x73, 0x2e, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x61, 0x20, 0x21, 0x3d,
+ 0x20, 0x2b, 0x61, 0x20, 0x3f, 0x20, 0x62, 0x20, 0x21, 0x3d, 0x20, 0x2b,
+ 0x62, 0x20, 0x3a, 0x20, 0x28, 0x61, 0x20, 0x3d, 0x3d, 0x20, 0x30, 0x20,
+ 0x3f, 0x20, 0x31, 0x20, 0x2f, 0x20, 0x61, 0x20, 0x3d, 0x3d, 0x20, 0x31,
+ 0x20, 0x2f, 0x20, 0x62, 0x20, 0x3a, 0x20, 0x61, 0x20, 0x3d, 0x3d, 0x20,
+ 0x2b, 0x62, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x63,
+ 0x61, 0x73, 0x65, 0x20, 0x27, 0x5b, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74,
+ 0x20, 0x44, 0x61, 0x74, 0x65, 0x5d, 0x27, 0x3a, 0x0a, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x20, 0x63, 0x61, 0x73, 0x65, 0x20, 0x27, 0x5b, 0x6f, 0x62,
+ 0x6a, 0x65, 0x63, 0x74, 0x20, 0x42, 0x6f, 0x6f, 0x6c, 0x65, 0x61, 0x6e,
+ 0x5d, 0x27, 0x3a, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x2f, 0x2f, 0x20, 0x43, 0x6f, 0x65, 0x72, 0x63, 0x65, 0x20, 0x64, 0x61,
+ 0x74, 0x65, 0x73, 0x20, 0x61, 0x6e, 0x64, 0x20, 0x62, 0x6f, 0x6f, 0x6c,
+ 0x65, 0x61, 0x6e, 0x73, 0x20, 0x74, 0x6f, 0x20, 0x6e, 0x75, 0x6d, 0x65,
+ 0x72, 0x69, 0x63, 0x20, 0x70, 0x72, 0x69, 0x6d, 0x69, 0x74, 0x69, 0x76,
+ 0x65, 0x20, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x73, 0x2e, 0x20, 0x44, 0x61,
+ 0x74, 0x65, 0x73, 0x20, 0x61, 0x72, 0x65, 0x20, 0x63, 0x6f, 0x6d, 0x70,
+ 0x61, 0x72, 0x65, 0x64, 0x20, 0x62, 0x79, 0x20, 0x74, 0x68, 0x65, 0x69,
+ 0x72, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x2f, 0x2f,
+ 0x20, 0x6d, 0x69, 0x6c, 0x6c, 0x69, 0x73, 0x65, 0x63, 0x6f, 0x6e, 0x64,
+ 0x20, 0x72, 0x65, 0x70, 0x72, 0x65, 0x73, 0x65, 0x6e, 0x74, 0x61, 0x74,
+ 0x69, 0x6f, 0x6e, 0x73, 0x2e, 0x20, 0x4e, 0x6f, 0x74, 0x65, 0x20, 0x74,
+ 0x68, 0x61, 0x74, 0x20, 0x69, 0x6e, 0x76, 0x61, 0x6c, 0x69, 0x64, 0x20,
+ 0x64, 0x61, 0x74, 0x65, 0x73, 0x20, 0x77, 0x69, 0x74, 0x68, 0x20, 0x6d,
+ 0x69, 0x6c, 0x6c, 0x69, 0x73, 0x65, 0x63, 0x6f, 0x6e, 0x64, 0x20, 0x72,
+ 0x65, 0x70, 0x72, 0x65, 0x73, 0x65, 0x6e, 0x74, 0x61, 0x74, 0x69, 0x6f,
+ 0x6e, 0x73, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x2f,
+ 0x2f, 0x20, 0x6f, 0x66, 0x20, 0x60, 0x4e, 0x61, 0x4e, 0x60, 0x20, 0x61,
+ 0x72, 0x65, 0x20, 0x6e, 0x6f, 0x74, 0x20, 0x65, 0x71, 0x75, 0x69, 0x76,
+ 0x61, 0x6c, 0x65, 0x6e, 0x74, 0x2e, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x2b, 0x61,
+ 0x20, 0x3d, 0x3d, 0x20, 0x2b, 0x62, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x52, 0x65, 0x67, 0x45, 0x78, 0x70, 0x73,
+ 0x20, 0x61, 0x72, 0x65, 0x20, 0x63, 0x6f, 0x6d, 0x70, 0x61, 0x72, 0x65,
+ 0x64, 0x20, 0x62, 0x79, 0x20, 0x74, 0x68, 0x65, 0x69, 0x72, 0x20, 0x73,
+ 0x6f, 0x75, 0x72, 0x63, 0x65, 0x20, 0x70, 0x61, 0x74, 0x74, 0x65, 0x72,
+ 0x6e, 0x73, 0x20, 0x61, 0x6e, 0x64, 0x20, 0x66, 0x6c, 0x61, 0x67, 0x73,
+ 0x2e, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x63, 0x61, 0x73, 0x65,
+ 0x20, 0x27, 0x5b, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, 0x52, 0x65,
+ 0x67, 0x45, 0x78, 0x70, 0x5d, 0x27, 0x3a, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x61,
+ 0x2e, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x20, 0x3d, 0x3d, 0x20, 0x62,
+ 0x2e, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x20, 0x26, 0x26, 0x0a, 0x20,
+ 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x61, 0x2e, 0x67, 0x6c, 0x6f, 0x62, 0x61, 0x6c, 0x20, 0x3d,
+ 0x3d, 0x20, 0x62, 0x2e, 0x67, 0x6c, 0x6f, 0x62, 0x61, 0x6c, 0x20, 0x26,
+ 0x26, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x20, 0x20, 0x20, 0x61, 0x2e, 0x6d, 0x75, 0x6c, 0x74, 0x69,
+ 0x6c, 0x69, 0x6e, 0x65, 0x20, 0x3d, 0x3d, 0x20, 0x62, 0x2e, 0x6d, 0x75,
+ 0x6c, 0x74, 0x69, 0x6c, 0x69, 0x6e, 0x65, 0x20, 0x26, 0x26, 0x0a, 0x20,
+ 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x61, 0x2e, 0x69, 0x67, 0x6e, 0x6f, 0x72, 0x65, 0x43, 0x61,
+ 0x73, 0x65, 0x20, 0x3d, 0x3d, 0x20, 0x62, 0x2e, 0x69, 0x67, 0x6e, 0x6f,
+ 0x72, 0x65, 0x43, 0x61, 0x73, 0x65, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x7d, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20, 0x28, 0x74, 0x79,
+ 0x70, 0x65, 0x6f, 0x66, 0x20, 0x61, 0x20, 0x21, 0x3d, 0x20, 0x27, 0x6f,
+ 0x62, 0x6a, 0x65, 0x63, 0x74, 0x27, 0x20, 0x7c, 0x7c, 0x20, 0x74, 0x79,
+ 0x70, 0x65, 0x6f, 0x66, 0x20, 0x62, 0x20, 0x21, 0x3d, 0x20, 0x27, 0x6f,
+ 0x62, 0x6a, 0x65, 0x63, 0x74, 0x27, 0x29, 0x20, 0x72, 0x65, 0x74, 0x75,
+ 0x72, 0x6e, 0x20, 0x66, 0x61, 0x6c, 0x73, 0x65, 0x3b, 0x0a, 0x20, 0x20,
+ 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x41, 0x73, 0x73, 0x75, 0x6d, 0x65, 0x20,
+ 0x65, 0x71, 0x75, 0x61, 0x6c, 0x69, 0x74, 0x79, 0x20, 0x66, 0x6f, 0x72,
+ 0x20, 0x63, 0x79, 0x63, 0x6c, 0x69, 0x63, 0x20, 0x73, 0x74, 0x72, 0x75,
+ 0x63, 0x74, 0x75, 0x72, 0x65, 0x73, 0x2e, 0x20, 0x54, 0x68, 0x65, 0x20,
+ 0x61, 0x6c, 0x67, 0x6f, 0x72, 0x69, 0x74, 0x68, 0x6d, 0x20, 0x66, 0x6f,
+ 0x72, 0x20, 0x64, 0x65, 0x74, 0x65, 0x63, 0x74, 0x69, 0x6e, 0x67, 0x20,
+ 0x63, 0x79, 0x63, 0x6c, 0x69, 0x63, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x2f,
+ 0x2f, 0x20, 0x73, 0x74, 0x72, 0x75, 0x63, 0x74, 0x75, 0x72, 0x65, 0x73,
+ 0x20, 0x69, 0x73, 0x20, 0x61, 0x64, 0x61, 0x70, 0x74, 0x65, 0x64, 0x20,
+ 0x66, 0x72, 0x6f, 0x6d, 0x20, 0x45, 0x53, 0x20, 0x35, 0x2e, 0x31, 0x20,
+ 0x73, 0x65, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x20, 0x31, 0x35, 0x2e, 0x31,
+ 0x32, 0x2e, 0x33, 0x2c, 0x20, 0x61, 0x62, 0x73, 0x74, 0x72, 0x61, 0x63,
+ 0x74, 0x20, 0x6f, 0x70, 0x65, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x20,
+ 0x60, 0x4a, 0x4f, 0x60, 0x2e, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x76, 0x61,
+ 0x72, 0x20, 0x6c, 0x65, 0x6e, 0x67, 0x74, 0x68, 0x20, 0x3d, 0x20, 0x61,
+ 0x53, 0x74, 0x61, 0x63, 0x6b, 0x2e, 0x6c, 0x65, 0x6e, 0x67, 0x74, 0x68,
+ 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x77, 0x68, 0x69, 0x6c, 0x65, 0x20,
+ 0x28, 0x6c, 0x65, 0x6e, 0x67, 0x74, 0x68, 0x2d, 0x2d, 0x29, 0x20, 0x7b,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x4c, 0x69,
+ 0x6e, 0x65, 0x61, 0x72, 0x20, 0x73, 0x65, 0x61, 0x72, 0x63, 0x68, 0x2e,
+ 0x20, 0x50, 0x65, 0x72, 0x66, 0x6f, 0x72, 0x6d, 0x61, 0x6e, 0x63, 0x65,
+ 0x20, 0x69, 0x73, 0x20, 0x69, 0x6e, 0x76, 0x65, 0x72, 0x73, 0x65, 0x6c,
+ 0x79, 0x20, 0x70, 0x72, 0x6f, 0x70, 0x6f, 0x72, 0x74, 0x69, 0x6f, 0x6e,
+ 0x61, 0x6c, 0x20, 0x74, 0x6f, 0x20, 0x74, 0x68, 0x65, 0x20, 0x6e, 0x75,
+ 0x6d, 0x62, 0x65, 0x72, 0x20, 0x6f, 0x66, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x75, 0x6e, 0x69, 0x71, 0x75, 0x65, 0x20,
+ 0x6e, 0x65, 0x73, 0x74, 0x65, 0x64, 0x20, 0x73, 0x74, 0x72, 0x75, 0x63,
+ 0x74, 0x75, 0x72, 0x65, 0x73, 0x2e, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x69, 0x66, 0x20, 0x28, 0x61, 0x53, 0x74, 0x61, 0x63, 0x6b, 0x5b,
+ 0x6c, 0x65, 0x6e, 0x67, 0x74, 0x68, 0x5d, 0x20, 0x3d, 0x3d, 0x20, 0x61,
+ 0x29, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x62, 0x53, 0x74,
+ 0x61, 0x63, 0x6b, 0x5b, 0x6c, 0x65, 0x6e, 0x67, 0x74, 0x68, 0x5d, 0x20,
+ 0x3d, 0x3d, 0x20, 0x62, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x0a,
+ 0x20, 0x20, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x41, 0x64, 0x64, 0x20, 0x74,
+ 0x68, 0x65, 0x20, 0x66, 0x69, 0x72, 0x73, 0x74, 0x20, 0x6f, 0x62, 0x6a,
+ 0x65, 0x63, 0x74, 0x20, 0x74, 0x6f, 0x20, 0x74, 0x68, 0x65, 0x20, 0x73,
+ 0x74, 0x61, 0x63, 0x6b, 0x20, 0x6f, 0x66, 0x20, 0x74, 0x72, 0x61, 0x76,
+ 0x65, 0x72, 0x73, 0x65, 0x64, 0x20, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74,
+ 0x73, 0x2e, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x61, 0x53, 0x74, 0x61, 0x63,
+ 0x6b, 0x2e, 0x70, 0x75, 0x73, 0x68, 0x28, 0x61, 0x29, 0x3b, 0x0a, 0x20,
+ 0x20, 0x20, 0x20, 0x62, 0x53, 0x74, 0x61, 0x63, 0x6b, 0x2e, 0x70, 0x75,
+ 0x73, 0x68, 0x28, 0x62, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x76,
+ 0x61, 0x72, 0x20, 0x73, 0x69, 0x7a, 0x65, 0x20, 0x3d, 0x20, 0x30, 0x2c,
+ 0x20, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x20, 0x3d, 0x20, 0x74, 0x72,
+ 0x75, 0x65, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x52,
+ 0x65, 0x63, 0x75, 0x72, 0x73, 0x69, 0x76, 0x65, 0x6c, 0x79, 0x20, 0x63,
+ 0x6f, 0x6d, 0x70, 0x61, 0x72, 0x65, 0x20, 0x6f, 0x62, 0x6a, 0x65, 0x63,
+ 0x74, 0x73, 0x20, 0x61, 0x6e, 0x64, 0x20, 0x61, 0x72, 0x72, 0x61, 0x79,
+ 0x73, 0x2e, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20, 0x28, 0x63,
+ 0x6c, 0x61, 0x73, 0x73, 0x4e, 0x61, 0x6d, 0x65, 0x20, 0x3d, 0x3d, 0x20,
+ 0x27, 0x5b, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, 0x41, 0x72, 0x72,
+ 0x61, 0x79, 0x5d, 0x27, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x43, 0x6f, 0x6d, 0x70, 0x61, 0x72, 0x65,
+ 0x20, 0x61, 0x72, 0x72, 0x61, 0x79, 0x20, 0x6c, 0x65, 0x6e, 0x67, 0x74,
+ 0x68, 0x73, 0x20, 0x74, 0x6f, 0x20, 0x64, 0x65, 0x74, 0x65, 0x72, 0x6d,
+ 0x69, 0x6e, 0x65, 0x20, 0x69, 0x66, 0x20, 0x61, 0x20, 0x64, 0x65, 0x65,
+ 0x70, 0x20, 0x63, 0x6f, 0x6d, 0x70, 0x61, 0x72, 0x69, 0x73, 0x6f, 0x6e,
+ 0x20, 0x69, 0x73, 0x20, 0x6e, 0x65, 0x63, 0x65, 0x73, 0x73, 0x61, 0x72,
+ 0x79, 0x2e, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x73, 0x69, 0x7a,
+ 0x65, 0x20, 0x3d, 0x20, 0x61, 0x2e, 0x6c, 0x65, 0x6e, 0x67, 0x74, 0x68,
+ 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x73, 0x75,
+ 0x6c, 0x74, 0x20, 0x3d, 0x20, 0x73, 0x69, 0x7a, 0x65, 0x20, 0x3d, 0x3d,
+ 0x20, 0x62, 0x2e, 0x6c, 0x65, 0x6e, 0x67, 0x74, 0x68, 0x3b, 0x0a, 0x20,
+ 0x20, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20, 0x28, 0x72, 0x65, 0x73,
+ 0x75, 0x6c, 0x74, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x44, 0x65, 0x65, 0x70, 0x20, 0x63,
+ 0x6f, 0x6d, 0x70, 0x61, 0x72, 0x65, 0x20, 0x74, 0x68, 0x65, 0x20, 0x63,
+ 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x73, 0x2c, 0x20, 0x69, 0x67, 0x6e,
+ 0x6f, 0x72, 0x69, 0x6e, 0x67, 0x20, 0x6e, 0x6f, 0x6e, 0x2d, 0x6e, 0x75,
+ 0x6d, 0x65, 0x72, 0x69, 0x63, 0x20, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72,
+ 0x74, 0x69, 0x65, 0x73, 0x2e, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x77, 0x68, 0x69, 0x6c, 0x65, 0x20, 0x28, 0x73, 0x69, 0x7a,
+ 0x65, 0x2d, 0x2d, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20, 0x28, 0x21, 0x28, 0x72,
+ 0x65, 0x73, 0x75, 0x6c, 0x74, 0x20, 0x3d, 0x20, 0x65, 0x71, 0x28, 0x61,
+ 0x5b, 0x73, 0x69, 0x7a, 0x65, 0x5d, 0x2c, 0x20, 0x62, 0x5b, 0x73, 0x69,
+ 0x7a, 0x65, 0x5d, 0x2c, 0x20, 0x61, 0x53, 0x74, 0x61, 0x63, 0x6b, 0x2c,
+ 0x20, 0x62, 0x53, 0x74, 0x61, 0x63, 0x6b, 0x29, 0x29, 0x29, 0x20, 0x62,
+ 0x72, 0x65, 0x61, 0x6b, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x7d, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x0a,
+ 0x20, 0x20, 0x20, 0x20, 0x7d, 0x20, 0x65, 0x6c, 0x73, 0x65, 0x20, 0x7b,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x4f, 0x62,
+ 0x6a, 0x65, 0x63, 0x74, 0x73, 0x20, 0x77, 0x69, 0x74, 0x68, 0x20, 0x64,
+ 0x69, 0x66, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x74, 0x20, 0x63, 0x6f, 0x6e,
+ 0x73, 0x74, 0x72, 0x75, 0x63, 0x74, 0x6f, 0x72, 0x73, 0x20, 0x61, 0x72,
+ 0x65, 0x20, 0x6e, 0x6f, 0x74, 0x20, 0x65, 0x71, 0x75, 0x69, 0x76, 0x61,
+ 0x6c, 0x65, 0x6e, 0x74, 0x2c, 0x20, 0x62, 0x75, 0x74, 0x20, 0x60, 0x4f,
+ 0x62, 0x6a, 0x65, 0x63, 0x74, 0x60, 0x73, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x66, 0x72, 0x6f, 0x6d, 0x20, 0x64, 0x69,
+ 0x66, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x74, 0x20, 0x66, 0x72, 0x61, 0x6d,
+ 0x65, 0x73, 0x20, 0x61, 0x72, 0x65, 0x2e, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x76, 0x61, 0x72, 0x20, 0x61, 0x43, 0x74, 0x6f, 0x72, 0x20,
+ 0x3d, 0x20, 0x61, 0x2e, 0x63, 0x6f, 0x6e, 0x73, 0x74, 0x72, 0x75, 0x63,
+ 0x74, 0x6f, 0x72, 0x2c, 0x20, 0x62, 0x43, 0x74, 0x6f, 0x72, 0x20, 0x3d,
+ 0x20, 0x62, 0x2e, 0x63, 0x6f, 0x6e, 0x73, 0x74, 0x72, 0x75, 0x63, 0x74,
+ 0x6f, 0x72, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66,
+ 0x20, 0x28, 0x61, 0x43, 0x74, 0x6f, 0x72, 0x20, 0x21, 0x3d, 0x3d, 0x20,
+ 0x62, 0x43, 0x74, 0x6f, 0x72, 0x20, 0x26, 0x26, 0x20, 0x21, 0x28, 0x5f,
+ 0x2e, 0x69, 0x73, 0x46, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28,
+ 0x61, 0x43, 0x74, 0x6f, 0x72, 0x29, 0x20, 0x26, 0x26, 0x20, 0x28, 0x61,
+ 0x43, 0x74, 0x6f, 0x72, 0x20, 0x69, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63,
+ 0x65, 0x6f, 0x66, 0x20, 0x61, 0x43, 0x74, 0x6f, 0x72, 0x29, 0x20, 0x26,
+ 0x26, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x5f, 0x2e, 0x69,
+ 0x73, 0x46, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x62, 0x43,
+ 0x74, 0x6f, 0x72, 0x29, 0x20, 0x26, 0x26, 0x20, 0x28, 0x62, 0x43, 0x74,
+ 0x6f, 0x72, 0x20, 0x69, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x6f,
+ 0x66, 0x20, 0x62, 0x43, 0x74, 0x6f, 0x72, 0x29, 0x29, 0x29, 0x20, 0x7b,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74,
+ 0x75, 0x72, 0x6e, 0x20, 0x66, 0x61, 0x6c, 0x73, 0x65, 0x3b, 0x0a, 0x20,
+ 0x20, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x2f, 0x2f, 0x20, 0x44, 0x65, 0x65, 0x70, 0x20, 0x63, 0x6f, 0x6d,
+ 0x70, 0x61, 0x72, 0x65, 0x20, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x73,
+ 0x2e, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x66, 0x6f, 0x72, 0x20,
+ 0x28, 0x76, 0x61, 0x72, 0x20, 0x6b, 0x65, 0x79, 0x20, 0x69, 0x6e, 0x20,
+ 0x61, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x69, 0x66, 0x20, 0x28, 0x5f, 0x2e, 0x68, 0x61, 0x73, 0x28, 0x61,
+ 0x2c, 0x20, 0x6b, 0x65, 0x79, 0x29, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20,
+ 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x43,
+ 0x6f, 0x75, 0x6e, 0x74, 0x20, 0x74, 0x68, 0x65, 0x20, 0x65, 0x78, 0x70,
+ 0x65, 0x63, 0x74, 0x65, 0x64, 0x20, 0x6e, 0x75, 0x6d, 0x62, 0x65, 0x72,
+ 0x20, 0x6f, 0x66, 0x20, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x69,
+ 0x65, 0x73, 0x2e, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x73, 0x69, 0x7a, 0x65, 0x2b, 0x2b, 0x3b, 0x0a, 0x20, 0x20,
+ 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x44,
+ 0x65, 0x65, 0x70, 0x20, 0x63, 0x6f, 0x6d, 0x70, 0x61, 0x72, 0x65, 0x20,
+ 0x65, 0x61, 0x63, 0x68, 0x20, 0x6d, 0x65, 0x6d, 0x62, 0x65, 0x72, 0x2e,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x69,
+ 0x66, 0x20, 0x28, 0x21, 0x28, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x20,
+ 0x3d, 0x20, 0x5f, 0x2e, 0x68, 0x61, 0x73, 0x28, 0x62, 0x2c, 0x20, 0x6b,
+ 0x65, 0x79, 0x29, 0x20, 0x26, 0x26, 0x20, 0x65, 0x71, 0x28, 0x61, 0x5b,
+ 0x6b, 0x65, 0x79, 0x5d, 0x2c, 0x20, 0x62, 0x5b, 0x6b, 0x65, 0x79, 0x5d,
+ 0x2c, 0x20, 0x61, 0x53, 0x74, 0x61, 0x63, 0x6b, 0x2c, 0x20, 0x62, 0x53,
+ 0x74, 0x61, 0x63, 0x6b, 0x29, 0x29, 0x29, 0x20, 0x62, 0x72, 0x65, 0x61,
+ 0x6b, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7d,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x0a, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x45, 0x6e, 0x73, 0x75, 0x72, 0x65,
+ 0x20, 0x74, 0x68, 0x61, 0x74, 0x20, 0x62, 0x6f, 0x74, 0x68, 0x20, 0x6f,
+ 0x62, 0x6a, 0x65, 0x63, 0x74, 0x73, 0x20, 0x63, 0x6f, 0x6e, 0x74, 0x61,
+ 0x69, 0x6e, 0x20, 0x74, 0x68, 0x65, 0x20, 0x73, 0x61, 0x6d, 0x65, 0x20,
+ 0x6e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x20, 0x6f, 0x66, 0x20, 0x70, 0x72,
+ 0x6f, 0x70, 0x65, 0x72, 0x74, 0x69, 0x65, 0x73, 0x2e, 0x0a, 0x20, 0x20,
+ 0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20, 0x28, 0x72, 0x65, 0x73, 0x75,
+ 0x6c, 0x74, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x66, 0x6f, 0x72, 0x20, 0x28, 0x6b, 0x65, 0x79, 0x20, 0x69,
+ 0x6e, 0x20, 0x62, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20, 0x28, 0x5f, 0x2e, 0x68,
+ 0x61, 0x73, 0x28, 0x62, 0x2c, 0x20, 0x6b, 0x65, 0x79, 0x29, 0x20, 0x26,
+ 0x26, 0x20, 0x21, 0x28, 0x73, 0x69, 0x7a, 0x65, 0x2d, 0x2d, 0x29, 0x29,
+ 0x20, 0x62, 0x72, 0x65, 0x61, 0x6b, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x20, 0x20, 0x7d, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x20, 0x3d, 0x20, 0x21,
+ 0x73, 0x69, 0x7a, 0x65, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x7d, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x2f, 0x2f, 0x20, 0x52, 0x65, 0x6d, 0x6f, 0x76, 0x65, 0x20, 0x74, 0x68,
+ 0x65, 0x20, 0x66, 0x69, 0x72, 0x73, 0x74, 0x20, 0x6f, 0x62, 0x6a, 0x65,
+ 0x63, 0x74, 0x20, 0x66, 0x72, 0x6f, 0x6d, 0x20, 0x74, 0x68, 0x65, 0x20,
+ 0x73, 0x74, 0x61, 0x63, 0x6b, 0x20, 0x6f, 0x66, 0x20, 0x74, 0x72, 0x61,
+ 0x76, 0x65, 0x72, 0x73, 0x65, 0x64, 0x20, 0x6f, 0x62, 0x6a, 0x65, 0x63,
+ 0x74, 0x73, 0x2e, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x61, 0x53, 0x74, 0x61,
+ 0x63, 0x6b, 0x2e, 0x70, 0x6f, 0x70, 0x28, 0x29, 0x3b, 0x0a, 0x20, 0x20,
+ 0x20, 0x20, 0x62, 0x53, 0x74, 0x61, 0x63, 0x6b, 0x2e, 0x70, 0x6f, 0x70,
+ 0x28, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74, 0x75,
+ 0x72, 0x6e, 0x20, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x3b, 0x0a, 0x20,
+ 0x20, 0x7d, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x50, 0x65,
+ 0x72, 0x66, 0x6f, 0x72, 0x6d, 0x20, 0x61, 0x20, 0x64, 0x65, 0x65, 0x70,
+ 0x20, 0x63, 0x6f, 0x6d, 0x70, 0x61, 0x72, 0x69, 0x73, 0x6f, 0x6e, 0x20,
+ 0x74, 0x6f, 0x20, 0x63, 0x68, 0x65, 0x63, 0x6b, 0x20, 0x69, 0x66, 0x20,
+ 0x74, 0x77, 0x6f, 0x20, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x73, 0x20,
+ 0x61, 0x72, 0x65, 0x20, 0x65, 0x71, 0x75, 0x61, 0x6c, 0x2e, 0x0a, 0x20,
+ 0x20, 0x5f, 0x2e, 0x69, 0x73, 0x45, 0x71, 0x75, 0x61, 0x6c, 0x20, 0x3d,
+ 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x61, 0x2c,
+ 0x20, 0x62, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65,
+ 0x74, 0x75, 0x72, 0x6e, 0x20, 0x65, 0x71, 0x28, 0x61, 0x2c, 0x20, 0x62,
+ 0x2c, 0x20, 0x5b, 0x5d, 0x2c, 0x20, 0x5b, 0x5d, 0x29, 0x3b, 0x0a, 0x20,
+ 0x20, 0x7d, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x49, 0x73,
+ 0x20, 0x61, 0x20, 0x67, 0x69, 0x76, 0x65, 0x6e, 0x20, 0x61, 0x72, 0x72,
+ 0x61, 0x79, 0x2c, 0x20, 0x73, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x2c, 0x20,
+ 0x6f, 0x72, 0x20, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, 0x65, 0x6d,
+ 0x70, 0x74, 0x79, 0x3f, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x41, 0x6e,
+ 0x20, 0x22, 0x65, 0x6d, 0x70, 0x74, 0x79, 0x22, 0x20, 0x6f, 0x62, 0x6a,
+ 0x65, 0x63, 0x74, 0x20, 0x68, 0x61, 0x73, 0x20, 0x6e, 0x6f, 0x20, 0x65,
+ 0x6e, 0x75, 0x6d, 0x65, 0x72, 0x61, 0x62, 0x6c, 0x65, 0x20, 0x6f, 0x77,
+ 0x6e, 0x2d, 0x70, 0x72, 0x6f, 0x70, 0x65, 0x72, 0x74, 0x69, 0x65, 0x73,
+ 0x2e, 0x0a, 0x20, 0x20, 0x5f, 0x2e, 0x69, 0x73, 0x45, 0x6d, 0x70, 0x74,
+ 0x79, 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e,
+ 0x28, 0x6f, 0x62, 0x6a, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x69, 0x66, 0x20, 0x28, 0x6f, 0x62, 0x6a, 0x20, 0x3d, 0x3d, 0x20, 0x6e,
+ 0x75, 0x6c, 0x6c, 0x29, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20,
+ 0x74, 0x72, 0x75, 0x65, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66,
+ 0x20, 0x28, 0x5f, 0x2e, 0x69, 0x73, 0x41, 0x72, 0x72, 0x61, 0x79, 0x28,
+ 0x6f, 0x62, 0x6a, 0x29, 0x20, 0x7c, 0x7c, 0x20, 0x5f, 0x2e, 0x69, 0x73,
+ 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x28, 0x6f, 0x62, 0x6a, 0x29, 0x29,
+ 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x6f, 0x62, 0x6a, 0x2e,
+ 0x6c, 0x65, 0x6e, 0x67, 0x74, 0x68, 0x20, 0x3d, 0x3d, 0x3d, 0x20, 0x30,
+ 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x66, 0x6f, 0x72, 0x20, 0x28, 0x76,
+ 0x61, 0x72, 0x20, 0x6b, 0x65, 0x79, 0x20, 0x69, 0x6e, 0x20, 0x6f, 0x62,
+ 0x6a, 0x29, 0x20, 0x69, 0x66, 0x20, 0x28, 0x5f, 0x2e, 0x68, 0x61, 0x73,
+ 0x28, 0x6f, 0x62, 0x6a, 0x2c, 0x20, 0x6b, 0x65, 0x79, 0x29, 0x29, 0x20,
+ 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x66, 0x61, 0x6c, 0x73, 0x65,
+ 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e,
+ 0x20, 0x74, 0x72, 0x75, 0x65, 0x3b, 0x0a, 0x20, 0x20, 0x7d, 0x3b, 0x0a,
+ 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x49, 0x73, 0x20, 0x61, 0x20, 0x67,
+ 0x69, 0x76, 0x65, 0x6e, 0x20, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x20, 0x61,
+ 0x20, 0x44, 0x4f, 0x4d, 0x20, 0x65, 0x6c, 0x65, 0x6d, 0x65, 0x6e, 0x74,
+ 0x3f, 0x0a, 0x20, 0x20, 0x5f, 0x2e, 0x69, 0x73, 0x45, 0x6c, 0x65, 0x6d,
+ 0x65, 0x6e, 0x74, 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69,
+ 0x6f, 0x6e, 0x28, 0x6f, 0x62, 0x6a, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20,
+ 0x20, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x21, 0x21, 0x28,
+ 0x6f, 0x62, 0x6a, 0x20, 0x26, 0x26, 0x20, 0x6f, 0x62, 0x6a, 0x2e, 0x6e,
+ 0x6f, 0x64, 0x65, 0x54, 0x79, 0x70, 0x65, 0x20, 0x3d, 0x3d, 0x3d, 0x20,
+ 0x31, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x0a, 0x20, 0x20,
+ 0x2f, 0x2f, 0x20, 0x49, 0x73, 0x20, 0x61, 0x20, 0x67, 0x69, 0x76, 0x65,
+ 0x6e, 0x20, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x20, 0x61, 0x6e, 0x20, 0x61,
+ 0x72, 0x72, 0x61, 0x79, 0x3f, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x44,
+ 0x65, 0x6c, 0x65, 0x67, 0x61, 0x74, 0x65, 0x73, 0x20, 0x74, 0x6f, 0x20,
+ 0x45, 0x43, 0x4d, 0x41, 0x35, 0x27, 0x73, 0x20, 0x6e, 0x61, 0x74, 0x69,
+ 0x76, 0x65, 0x20, 0x41, 0x72, 0x72, 0x61, 0x79, 0x2e, 0x69, 0x73, 0x41,
+ 0x72, 0x72, 0x61, 0x79, 0x0a, 0x20, 0x20, 0x5f, 0x2e, 0x69, 0x73, 0x41,
+ 0x72, 0x72, 0x61, 0x79, 0x20, 0x3d, 0x20, 0x6e, 0x61, 0x74, 0x69, 0x76,
+ 0x65, 0x49, 0x73, 0x41, 0x72, 0x72, 0x61, 0x79, 0x20, 0x7c, 0x7c, 0x20,
+ 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x6f, 0x62, 0x6a,
+ 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74, 0x75,
+ 0x72, 0x6e, 0x20, 0x74, 0x6f, 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x2e,
+ 0x63, 0x61, 0x6c, 0x6c, 0x28, 0x6f, 0x62, 0x6a, 0x29, 0x20, 0x3d, 0x3d,
+ 0x20, 0x27, 0x5b, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, 0x41, 0x72,
+ 0x72, 0x61, 0x79, 0x5d, 0x27, 0x3b, 0x0a, 0x20, 0x20, 0x7d, 0x3b, 0x0a,
+ 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x49, 0x73, 0x20, 0x61, 0x20, 0x67,
+ 0x69, 0x76, 0x65, 0x6e, 0x20, 0x76, 0x61, 0x72, 0x69, 0x61, 0x62, 0x6c,
+ 0x65, 0x20, 0x61, 0x6e, 0x20, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x3f,
+ 0x0a, 0x20, 0x20, 0x5f, 0x2e, 0x69, 0x73, 0x4f, 0x62, 0x6a, 0x65, 0x63,
+ 0x74, 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e,
+ 0x28, 0x6f, 0x62, 0x6a, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x6f, 0x62, 0x6a, 0x20, 0x3d,
+ 0x3d, 0x3d, 0x20, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x28, 0x6f, 0x62,
+ 0x6a, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x0a, 0x20, 0x20,
+ 0x2f, 0x2f, 0x20, 0x41, 0x64, 0x64, 0x20, 0x73, 0x6f, 0x6d, 0x65, 0x20,
+ 0x69, 0x73, 0x54, 0x79, 0x70, 0x65, 0x20, 0x6d, 0x65, 0x74, 0x68, 0x6f,
+ 0x64, 0x73, 0x3a, 0x20, 0x69, 0x73, 0x41, 0x72, 0x67, 0x75, 0x6d, 0x65,
+ 0x6e, 0x74, 0x73, 0x2c, 0x20, 0x69, 0x73, 0x46, 0x75, 0x6e, 0x63, 0x74,
+ 0x69, 0x6f, 0x6e, 0x2c, 0x20, 0x69, 0x73, 0x53, 0x74, 0x72, 0x69, 0x6e,
+ 0x67, 0x2c, 0x20, 0x69, 0x73, 0x4e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x2c,
+ 0x20, 0x69, 0x73, 0x44, 0x61, 0x74, 0x65, 0x2c, 0x20, 0x69, 0x73, 0x52,
+ 0x65, 0x67, 0x45, 0x78, 0x70, 0x2e, 0x0a, 0x20, 0x20, 0x65, 0x61, 0x63,
+ 0x68, 0x28, 0x5b, 0x27, 0x41, 0x72, 0x67, 0x75, 0x6d, 0x65, 0x6e, 0x74,
+ 0x73, 0x27, 0x2c, 0x20, 0x27, 0x46, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f,
+ 0x6e, 0x27, 0x2c, 0x20, 0x27, 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x27,
+ 0x2c, 0x20, 0x27, 0x4e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x27, 0x2c, 0x20,
+ 0x27, 0x44, 0x61, 0x74, 0x65, 0x27, 0x2c, 0x20, 0x27, 0x52, 0x65, 0x67,
+ 0x45, 0x78, 0x70, 0x27, 0x5d, 0x2c, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74,
+ 0x69, 0x6f, 0x6e, 0x28, 0x6e, 0x61, 0x6d, 0x65, 0x29, 0x20, 0x7b, 0x0a,
+ 0x20, 0x20, 0x20, 0x20, 0x5f, 0x5b, 0x27, 0x69, 0x73, 0x27, 0x20, 0x2b,
+ 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x5d, 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e,
+ 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x6f, 0x62, 0x6a, 0x29, 0x20, 0x7b,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72,
+ 0x6e, 0x20, 0x74, 0x6f, 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x2e, 0x63,
+ 0x61, 0x6c, 0x6c, 0x28, 0x6f, 0x62, 0x6a, 0x29, 0x20, 0x3d, 0x3d, 0x20,
+ 0x27, 0x5b, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, 0x27, 0x20, 0x2b,
+ 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x20, 0x2b, 0x20, 0x27, 0x5d, 0x27, 0x3b,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x20, 0x20, 0x7d, 0x29,
+ 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x44, 0x65, 0x66, 0x69,
+ 0x6e, 0x65, 0x20, 0x61, 0x20, 0x66, 0x61, 0x6c, 0x6c, 0x62, 0x61, 0x63,
+ 0x6b, 0x20, 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x20, 0x6f, 0x66,
+ 0x20, 0x74, 0x68, 0x65, 0x20, 0x6d, 0x65, 0x74, 0x68, 0x6f, 0x64, 0x20,
+ 0x69, 0x6e, 0x20, 0x62, 0x72, 0x6f, 0x77, 0x73, 0x65, 0x72, 0x73, 0x20,
+ 0x28, 0x61, 0x68, 0x65, 0x6d, 0x2c, 0x20, 0x49, 0x45, 0x29, 0x2c, 0x20,
+ 0x77, 0x68, 0x65, 0x72, 0x65, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x74,
+ 0x68, 0x65, 0x72, 0x65, 0x20, 0x69, 0x73, 0x6e, 0x27, 0x74, 0x20, 0x61,
+ 0x6e, 0x79, 0x20, 0x69, 0x6e, 0x73, 0x70, 0x65, 0x63, 0x74, 0x61, 0x62,
+ 0x6c, 0x65, 0x20, 0x22, 0x41, 0x72, 0x67, 0x75, 0x6d, 0x65, 0x6e, 0x74,
+ 0x73, 0x22, 0x20, 0x74, 0x79, 0x70, 0x65, 0x2e, 0x0a, 0x20, 0x20, 0x69,
+ 0x66, 0x20, 0x28, 0x21, 0x5f, 0x2e, 0x69, 0x73, 0x41, 0x72, 0x67, 0x75,
+ 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x28, 0x61, 0x72, 0x67, 0x75, 0x6d, 0x65,
+ 0x6e, 0x74, 0x73, 0x29, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x5f, 0x2e, 0x69, 0x73, 0x41, 0x72, 0x67, 0x75, 0x6d, 0x65, 0x6e, 0x74,
+ 0x73, 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e,
+ 0x28, 0x6f, 0x62, 0x6a, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x21, 0x21, 0x28,
+ 0x6f, 0x62, 0x6a, 0x20, 0x26, 0x26, 0x20, 0x5f, 0x2e, 0x68, 0x61, 0x73,
+ 0x28, 0x6f, 0x62, 0x6a, 0x2c, 0x20, 0x27, 0x63, 0x61, 0x6c, 0x6c, 0x65,
+ 0x65, 0x27, 0x29, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x3b,
+ 0x0a, 0x20, 0x20, 0x7d, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x4f,
+ 0x70, 0x74, 0x69, 0x6d, 0x69, 0x7a, 0x65, 0x20, 0x60, 0x69, 0x73, 0x46,
+ 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x60, 0x20, 0x69, 0x66, 0x20,
+ 0x61, 0x70, 0x70, 0x72, 0x6f, 0x70, 0x72, 0x69, 0x61, 0x74, 0x65, 0x2e,
+ 0x0a, 0x20, 0x20, 0x69, 0x66, 0x20, 0x28, 0x74, 0x79, 0x70, 0x65, 0x6f,
+ 0x66, 0x20, 0x28, 0x2f, 0x2e, 0x2f, 0x29, 0x20, 0x21, 0x3d, 0x3d, 0x20,
+ 0x27, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x27, 0x29, 0x20,
+ 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x5f, 0x2e, 0x69, 0x73, 0x46, 0x75,
+ 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e,
+ 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x6f, 0x62, 0x6a, 0x29, 0x20, 0x7b,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72,
+ 0x6e, 0x20, 0x74, 0x79, 0x70, 0x65, 0x6f, 0x66, 0x20, 0x6f, 0x62, 0x6a,
+ 0x20, 0x3d, 0x3d, 0x3d, 0x20, 0x27, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69,
+ 0x6f, 0x6e, 0x27, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x3b, 0x0a,
+ 0x20, 0x20, 0x7d, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x49, 0x73,
+ 0x20, 0x61, 0x20, 0x67, 0x69, 0x76, 0x65, 0x6e, 0x20, 0x6f, 0x62, 0x6a,
+ 0x65, 0x63, 0x74, 0x20, 0x61, 0x20, 0x66, 0x69, 0x6e, 0x69, 0x74, 0x65,
+ 0x20, 0x6e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x3f, 0x0a, 0x20, 0x20, 0x5f,
+ 0x2e, 0x69, 0x73, 0x46, 0x69, 0x6e, 0x69, 0x74, 0x65, 0x20, 0x3d, 0x20,
+ 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x6f, 0x62, 0x6a,
+ 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74, 0x75,
+ 0x72, 0x6e, 0x20, 0x69, 0x73, 0x46, 0x69, 0x6e, 0x69, 0x74, 0x65, 0x28,
+ 0x6f, 0x62, 0x6a, 0x29, 0x20, 0x26, 0x26, 0x20, 0x21, 0x69, 0x73, 0x4e,
+ 0x61, 0x4e, 0x28, 0x70, 0x61, 0x72, 0x73, 0x65, 0x46, 0x6c, 0x6f, 0x61,
+ 0x74, 0x28, 0x6f, 0x62, 0x6a, 0x29, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x7d,
+ 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x49, 0x73, 0x20, 0x74,
+ 0x68, 0x65, 0x20, 0x67, 0x69, 0x76, 0x65, 0x6e, 0x20, 0x76, 0x61, 0x6c,
+ 0x75, 0x65, 0x20, 0x60, 0x4e, 0x61, 0x4e, 0x60, 0x3f, 0x20, 0x28, 0x4e,
+ 0x61, 0x4e, 0x20, 0x69, 0x73, 0x20, 0x74, 0x68, 0x65, 0x20, 0x6f, 0x6e,
+ 0x6c, 0x79, 0x20, 0x6e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x20, 0x77, 0x68,
+ 0x69, 0x63, 0x68, 0x20, 0x64, 0x6f, 0x65, 0x73, 0x20, 0x6e, 0x6f, 0x74,
+ 0x20, 0x65, 0x71, 0x75, 0x61, 0x6c, 0x20, 0x69, 0x74, 0x73, 0x65, 0x6c,
+ 0x66, 0x29, 0x2e, 0x0a, 0x20, 0x20, 0x5f, 0x2e, 0x69, 0x73, 0x4e, 0x61,
+ 0x4e, 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e,
+ 0x28, 0x6f, 0x62, 0x6a, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x5f, 0x2e, 0x69, 0x73, 0x4e,
+ 0x75, 0x6d, 0x62, 0x65, 0x72, 0x28, 0x6f, 0x62, 0x6a, 0x29, 0x20, 0x26,
+ 0x26, 0x20, 0x6f, 0x62, 0x6a, 0x20, 0x21, 0x3d, 0x20, 0x2b, 0x6f, 0x62,
+ 0x6a, 0x3b, 0x0a, 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f,
+ 0x2f, 0x20, 0x49, 0x73, 0x20, 0x61, 0x20, 0x67, 0x69, 0x76, 0x65, 0x6e,
+ 0x20, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x20, 0x61, 0x20, 0x62, 0x6f, 0x6f,
+ 0x6c, 0x65, 0x61, 0x6e, 0x3f, 0x0a, 0x20, 0x20, 0x5f, 0x2e, 0x69, 0x73,
+ 0x42, 0x6f, 0x6f, 0x6c, 0x65, 0x61, 0x6e, 0x20, 0x3d, 0x20, 0x66, 0x75,
+ 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x6f, 0x62, 0x6a, 0x29, 0x20,
+ 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e,
+ 0x20, 0x6f, 0x62, 0x6a, 0x20, 0x3d, 0x3d, 0x3d, 0x20, 0x74, 0x72, 0x75,
+ 0x65, 0x20, 0x7c, 0x7c, 0x20, 0x6f, 0x62, 0x6a, 0x20, 0x3d, 0x3d, 0x3d,
+ 0x20, 0x66, 0x61, 0x6c, 0x73, 0x65, 0x20, 0x7c, 0x7c, 0x20, 0x74, 0x6f,
+ 0x53, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x2e, 0x63, 0x61, 0x6c, 0x6c, 0x28,
+ 0x6f, 0x62, 0x6a, 0x29, 0x20, 0x3d, 0x3d, 0x20, 0x27, 0x5b, 0x6f, 0x62,
+ 0x6a, 0x65, 0x63, 0x74, 0x20, 0x42, 0x6f, 0x6f, 0x6c, 0x65, 0x61, 0x6e,
+ 0x5d, 0x27, 0x3b, 0x0a, 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x0a, 0x20, 0x20,
+ 0x2f, 0x2f, 0x20, 0x49, 0x73, 0x20, 0x61, 0x20, 0x67, 0x69, 0x76, 0x65,
+ 0x6e, 0x20, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x20, 0x65, 0x71, 0x75, 0x61,
+ 0x6c, 0x20, 0x74, 0x6f, 0x20, 0x6e, 0x75, 0x6c, 0x6c, 0x3f, 0x0a, 0x20,
+ 0x20, 0x5f, 0x2e, 0x69, 0x73, 0x4e, 0x75, 0x6c, 0x6c, 0x20, 0x3d, 0x20,
+ 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x6f, 0x62, 0x6a,
+ 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74, 0x75,
+ 0x72, 0x6e, 0x20, 0x6f, 0x62, 0x6a, 0x20, 0x3d, 0x3d, 0x3d, 0x20, 0x6e,
+ 0x75, 0x6c, 0x6c, 0x3b, 0x0a, 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x0a, 0x20,
+ 0x20, 0x2f, 0x2f, 0x20, 0x49, 0x73, 0x20, 0x61, 0x20, 0x67, 0x69, 0x76,
+ 0x65, 0x6e, 0x20, 0x76, 0x61, 0x72, 0x69, 0x61, 0x62, 0x6c, 0x65, 0x20,
+ 0x75, 0x6e, 0x64, 0x65, 0x66, 0x69, 0x6e, 0x65, 0x64, 0x3f, 0x0a, 0x20,
+ 0x20, 0x5f, 0x2e, 0x69, 0x73, 0x55, 0x6e, 0x64, 0x65, 0x66, 0x69, 0x6e,
+ 0x65, 0x64, 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f,
+ 0x6e, 0x28, 0x6f, 0x62, 0x6a, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20,
+ 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x6f, 0x62, 0x6a, 0x20,
+ 0x3d, 0x3d, 0x3d, 0x20, 0x76, 0x6f, 0x69, 0x64, 0x20, 0x30, 0x3b, 0x0a,
+ 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x53,
+ 0x68, 0x6f, 0x72, 0x74, 0x63, 0x75, 0x74, 0x20, 0x66, 0x75, 0x6e, 0x63,
+ 0x74, 0x69, 0x6f, 0x6e, 0x20, 0x66, 0x6f, 0x72, 0x20, 0x63, 0x68, 0x65,
+ 0x63, 0x6b, 0x69, 0x6e, 0x67, 0x20, 0x69, 0x66, 0x20, 0x61, 0x6e, 0x20,
+ 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20, 0x68, 0x61, 0x73, 0x20, 0x61,
+ 0x20, 0x67, 0x69, 0x76, 0x65, 0x6e, 0x20, 0x70, 0x72, 0x6f, 0x70, 0x65,
+ 0x72, 0x74, 0x79, 0x20, 0x64, 0x69, 0x72, 0x65, 0x63, 0x74, 0x6c, 0x79,
+ 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x6f, 0x6e, 0x20, 0x69, 0x74, 0x73,
+ 0x65, 0x6c, 0x66, 0x20, 0x28, 0x69, 0x6e, 0x20, 0x6f, 0x74, 0x68, 0x65,
+ 0x72, 0x20, 0x77, 0x6f, 0x72, 0x64, 0x73, 0x2c, 0x20, 0x6e, 0x6f, 0x74,
+ 0x20, 0x6f, 0x6e, 0x20, 0x61, 0x20, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x74,
+ 0x79, 0x70, 0x65, 0x29, 0x2e, 0x0a, 0x20, 0x20, 0x5f, 0x2e, 0x68, 0x61,
+ 0x73, 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e,
+ 0x28, 0x6f, 0x62, 0x6a, 0x2c, 0x20, 0x6b, 0x65, 0x79, 0x29, 0x20, 0x7b,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20,
+ 0x68, 0x61, 0x73, 0x4f, 0x77, 0x6e, 0x50, 0x72, 0x6f, 0x70, 0x65, 0x72,
+ 0x74, 0x79, 0x2e, 0x63, 0x61, 0x6c, 0x6c, 0x28, 0x6f, 0x62, 0x6a, 0x2c,
+ 0x20, 0x6b, 0x65, 0x79, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x7d, 0x3b, 0x0a,
+ 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x55, 0x74, 0x69, 0x6c, 0x69, 0x74,
+ 0x79, 0x20, 0x46, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x0a,
+ 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x2d, 0x2d, 0x2d, 0x2d, 0x2d, 0x2d, 0x2d,
+ 0x2d, 0x2d, 0x2d, 0x2d, 0x2d, 0x2d, 0x2d, 0x2d, 0x2d, 0x2d, 0x0a, 0x0a,
+ 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x52, 0x75, 0x6e, 0x20, 0x55, 0x6e, 0x64,
+ 0x65, 0x72, 0x73, 0x63, 0x6f, 0x72, 0x65, 0x2e, 0x6a, 0x73, 0x20, 0x69,
+ 0x6e, 0x20, 0x2a, 0x6e, 0x6f, 0x43, 0x6f, 0x6e, 0x66, 0x6c, 0x69, 0x63,
+ 0x74, 0x2a, 0x20, 0x6d, 0x6f, 0x64, 0x65, 0x2c, 0x20, 0x72, 0x65, 0x74,
+ 0x75, 0x72, 0x6e, 0x69, 0x6e, 0x67, 0x20, 0x74, 0x68, 0x65, 0x20, 0x60,
+ 0x5f, 0x60, 0x20, 0x76, 0x61, 0x72, 0x69, 0x61, 0x62, 0x6c, 0x65, 0x20,
+ 0x74, 0x6f, 0x20, 0x69, 0x74, 0x73, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20,
+ 0x70, 0x72, 0x65, 0x76, 0x69, 0x6f, 0x75, 0x73, 0x20, 0x6f, 0x77, 0x6e,
+ 0x65, 0x72, 0x2e, 0x20, 0x52, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x73, 0x20,
+ 0x61, 0x20, 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x20,
+ 0x74, 0x6f, 0x20, 0x74, 0x68, 0x65, 0x20, 0x55, 0x6e, 0x64, 0x65, 0x72,
+ 0x73, 0x63, 0x6f, 0x72, 0x65, 0x20, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74,
+ 0x2e, 0x0a, 0x20, 0x20, 0x5f, 0x2e, 0x6e, 0x6f, 0x43, 0x6f, 0x6e, 0x66,
+ 0x6c, 0x69, 0x63, 0x74, 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74,
+ 0x69, 0x6f, 0x6e, 0x28, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x72, 0x6f, 0x6f, 0x74, 0x2e, 0x5f, 0x20, 0x3d, 0x20, 0x70, 0x72, 0x65,
+ 0x76, 0x69, 0x6f, 0x75, 0x73, 0x55, 0x6e, 0x64, 0x65, 0x72, 0x73, 0x63,
+ 0x6f, 0x72, 0x65, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74,
+ 0x75, 0x72, 0x6e, 0x20, 0x74, 0x68, 0x69, 0x73, 0x3b, 0x0a, 0x20, 0x20,
+ 0x7d, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x4b, 0x65, 0x65,
+ 0x70, 0x20, 0x74, 0x68, 0x65, 0x20, 0x69, 0x64, 0x65, 0x6e, 0x74, 0x69,
+ 0x74, 0x79, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x20,
+ 0x61, 0x72, 0x6f, 0x75, 0x6e, 0x64, 0x20, 0x66, 0x6f, 0x72, 0x20, 0x64,
+ 0x65, 0x66, 0x61, 0x75, 0x6c, 0x74, 0x20, 0x69, 0x74, 0x65, 0x72, 0x61,
+ 0x74, 0x6f, 0x72, 0x73, 0x2e, 0x0a, 0x20, 0x20, 0x5f, 0x2e, 0x69, 0x64,
+ 0x65, 0x6e, 0x74, 0x69, 0x74, 0x79, 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e,
+ 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x29,
+ 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72,
+ 0x6e, 0x20, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3b, 0x0a, 0x20, 0x20, 0x7d,
+ 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x52, 0x75, 0x6e, 0x20,
+ 0x61, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x20, 0x2a,
+ 0x2a, 0x6e, 0x2a, 0x2a, 0x20, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x2e, 0x0a,
+ 0x20, 0x20, 0x5f, 0x2e, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x20, 0x3d, 0x20,
+ 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x6e, 0x2c, 0x20,
+ 0x69, 0x74, 0x65, 0x72, 0x61, 0x74, 0x6f, 0x72, 0x2c, 0x20, 0x63, 0x6f,
+ 0x6e, 0x74, 0x65, 0x78, 0x74, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20,
+ 0x20, 0x76, 0x61, 0x72, 0x20, 0x61, 0x63, 0x63, 0x75, 0x6d, 0x20, 0x3d,
+ 0x20, 0x41, 0x72, 0x72, 0x61, 0x79, 0x28, 0x6e, 0x29, 0x3b, 0x0a, 0x20,
+ 0x20, 0x20, 0x20, 0x66, 0x6f, 0x72, 0x20, 0x28, 0x76, 0x61, 0x72, 0x20,
+ 0x69, 0x20, 0x3d, 0x20, 0x30, 0x3b, 0x20, 0x69, 0x20, 0x3c, 0x20, 0x6e,
+ 0x3b, 0x20, 0x69, 0x2b, 0x2b, 0x29, 0x20, 0x61, 0x63, 0x63, 0x75, 0x6d,
+ 0x5b, 0x69, 0x5d, 0x20, 0x3d, 0x20, 0x69, 0x74, 0x65, 0x72, 0x61, 0x74,
+ 0x6f, 0x72, 0x2e, 0x63, 0x61, 0x6c, 0x6c, 0x28, 0x63, 0x6f, 0x6e, 0x74,
+ 0x65, 0x78, 0x74, 0x2c, 0x20, 0x69, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20,
+ 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x61, 0x63, 0x63, 0x75,
+ 0x6d, 0x3b, 0x0a, 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f,
+ 0x2f, 0x20, 0x52, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x61, 0x20, 0x72,
+ 0x61, 0x6e, 0x64, 0x6f, 0x6d, 0x20, 0x69, 0x6e, 0x74, 0x65, 0x67, 0x65,
+ 0x72, 0x20, 0x62, 0x65, 0x74, 0x77, 0x65, 0x65, 0x6e, 0x20, 0x6d, 0x69,
+ 0x6e, 0x20, 0x61, 0x6e, 0x64, 0x20, 0x6d, 0x61, 0x78, 0x20, 0x28, 0x69,
+ 0x6e, 0x63, 0x6c, 0x75, 0x73, 0x69, 0x76, 0x65, 0x29, 0x2e, 0x0a, 0x20,
+ 0x20, 0x5f, 0x2e, 0x72, 0x61, 0x6e, 0x64, 0x6f, 0x6d, 0x20, 0x3d, 0x20,
+ 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x6d, 0x69, 0x6e,
+ 0x2c, 0x20, 0x6d, 0x61, 0x78, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20,
+ 0x20, 0x69, 0x66, 0x20, 0x28, 0x6d, 0x61, 0x78, 0x20, 0x3d, 0x3d, 0x20,
+ 0x6e, 0x75, 0x6c, 0x6c, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x6d, 0x61, 0x78, 0x20, 0x3d, 0x20, 0x6d, 0x69, 0x6e, 0x3b,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x6d, 0x69, 0x6e, 0x20, 0x3d,
+ 0x20, 0x30, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x0a, 0x20, 0x20,
+ 0x20, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x6d, 0x69, 0x6e,
+ 0x20, 0x2b, 0x20, 0x4d, 0x61, 0x74, 0x68, 0x2e, 0x66, 0x6c, 0x6f, 0x6f,
+ 0x72, 0x28, 0x4d, 0x61, 0x74, 0x68, 0x2e, 0x72, 0x61, 0x6e, 0x64, 0x6f,
+ 0x6d, 0x28, 0x29, 0x20, 0x2a, 0x20, 0x28, 0x6d, 0x61, 0x78, 0x20, 0x2d,
+ 0x20, 0x6d, 0x69, 0x6e, 0x20, 0x2b, 0x20, 0x31, 0x29, 0x29, 0x3b, 0x0a,
+ 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x4c,
+ 0x69, 0x73, 0x74, 0x20, 0x6f, 0x66, 0x20, 0x48, 0x54, 0x4d, 0x4c, 0x20,
+ 0x65, 0x6e, 0x74, 0x69, 0x74, 0x69, 0x65, 0x73, 0x20, 0x66, 0x6f, 0x72,
+ 0x20, 0x65, 0x73, 0x63, 0x61, 0x70, 0x69, 0x6e, 0x67, 0x2e, 0x0a, 0x20,
+ 0x20, 0x76, 0x61, 0x72, 0x20, 0x65, 0x6e, 0x74, 0x69, 0x74, 0x79, 0x4d,
+ 0x61, 0x70, 0x20, 0x3d, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x65,
+ 0x73, 0x63, 0x61, 0x70, 0x65, 0x3a, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x20, 0x27, 0x26, 0x27, 0x3a, 0x20, 0x27, 0x26, 0x61, 0x6d,
+ 0x70, 0x3b, 0x27, 0x2c, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x27,
+ 0x3c, 0x27, 0x3a, 0x20, 0x27, 0x26, 0x6c, 0x74, 0x3b, 0x27, 0x2c, 0x0a,
+ 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x27, 0x3e, 0x27, 0x3a, 0x20, 0x27,
+ 0x26, 0x67, 0x74, 0x3b, 0x27, 0x2c, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x27, 0x22, 0x27, 0x3a, 0x20, 0x27, 0x26, 0x71, 0x75, 0x6f, 0x74,
+ 0x3b, 0x27, 0x2c, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x22, 0x27,
+ 0x22, 0x3a, 0x20, 0x27, 0x26, 0x23, 0x78, 0x32, 0x37, 0x3b, 0x27, 0x2c,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x27, 0x2f, 0x27, 0x3a, 0x20,
+ 0x27, 0x26, 0x23, 0x78, 0x32, 0x46, 0x3b, 0x27, 0x0a, 0x20, 0x20, 0x20,
+ 0x20, 0x7d, 0x0a, 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x20, 0x20, 0x65, 0x6e,
+ 0x74, 0x69, 0x74, 0x79, 0x4d, 0x61, 0x70, 0x2e, 0x75, 0x6e, 0x65, 0x73,
+ 0x63, 0x61, 0x70, 0x65, 0x20, 0x3d, 0x20, 0x5f, 0x2e, 0x69, 0x6e, 0x76,
+ 0x65, 0x72, 0x74, 0x28, 0x65, 0x6e, 0x74, 0x69, 0x74, 0x79, 0x4d, 0x61,
+ 0x70, 0x2e, 0x65, 0x73, 0x63, 0x61, 0x70, 0x65, 0x29, 0x3b, 0x0a, 0x0a,
+ 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x52, 0x65, 0x67, 0x65, 0x78, 0x65, 0x73,
+ 0x20, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x69, 0x6e, 0x67, 0x20,
+ 0x74, 0x68, 0x65, 0x20, 0x6b, 0x65, 0x79, 0x73, 0x20, 0x61, 0x6e, 0x64,
+ 0x20, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x73, 0x20, 0x6c, 0x69, 0x73, 0x74,
+ 0x65, 0x64, 0x20, 0x69, 0x6d, 0x6d, 0x65, 0x64, 0x69, 0x61, 0x74, 0x65,
+ 0x6c, 0x79, 0x20, 0x61, 0x62, 0x6f, 0x76, 0x65, 0x2e, 0x0a, 0x20, 0x20,
+ 0x76, 0x61, 0x72, 0x20, 0x65, 0x6e, 0x74, 0x69, 0x74, 0x79, 0x52, 0x65,
+ 0x67, 0x65, 0x78, 0x65, 0x73, 0x20, 0x3d, 0x20, 0x7b, 0x0a, 0x20, 0x20,
+ 0x20, 0x20, 0x65, 0x73, 0x63, 0x61, 0x70, 0x65, 0x3a, 0x20, 0x20, 0x20,
+ 0x6e, 0x65, 0x77, 0x20, 0x52, 0x65, 0x67, 0x45, 0x78, 0x70, 0x28, 0x27,
+ 0x5b, 0x27, 0x20, 0x2b, 0x20, 0x5f, 0x2e, 0x6b, 0x65, 0x79, 0x73, 0x28,
+ 0x65, 0x6e, 0x74, 0x69, 0x74, 0x79, 0x4d, 0x61, 0x70, 0x2e, 0x65, 0x73,
+ 0x63, 0x61, 0x70, 0x65, 0x29, 0x2e, 0x6a, 0x6f, 0x69, 0x6e, 0x28, 0x27,
+ 0x27, 0x29, 0x20, 0x2b, 0x20, 0x27, 0x5d, 0x27, 0x2c, 0x20, 0x27, 0x67,
+ 0x27, 0x29, 0x2c, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x75, 0x6e, 0x65, 0x73,
+ 0x63, 0x61, 0x70, 0x65, 0x3a, 0x20, 0x6e, 0x65, 0x77, 0x20, 0x52, 0x65,
+ 0x67, 0x45, 0x78, 0x70, 0x28, 0x27, 0x28, 0x27, 0x20, 0x2b, 0x20, 0x5f,
+ 0x2e, 0x6b, 0x65, 0x79, 0x73, 0x28, 0x65, 0x6e, 0x74, 0x69, 0x74, 0x79,
+ 0x4d, 0x61, 0x70, 0x2e, 0x75, 0x6e, 0x65, 0x73, 0x63, 0x61, 0x70, 0x65,
+ 0x29, 0x2e, 0x6a, 0x6f, 0x69, 0x6e, 0x28, 0x27, 0x7c, 0x27, 0x29, 0x20,
+ 0x2b, 0x20, 0x27, 0x29, 0x27, 0x2c, 0x20, 0x27, 0x67, 0x27, 0x29, 0x0a,
+ 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x46,
+ 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x20, 0x66, 0x6f, 0x72,
+ 0x20, 0x65, 0x73, 0x63, 0x61, 0x70, 0x69, 0x6e, 0x67, 0x20, 0x61, 0x6e,
+ 0x64, 0x20, 0x75, 0x6e, 0x65, 0x73, 0x63, 0x61, 0x70, 0x69, 0x6e, 0x67,
+ 0x20, 0x73, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x73, 0x20, 0x74, 0x6f, 0x2f,
+ 0x66, 0x72, 0x6f, 0x6d, 0x20, 0x48, 0x54, 0x4d, 0x4c, 0x20, 0x69, 0x6e,
+ 0x74, 0x65, 0x72, 0x70, 0x6f, 0x6c, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x2e,
+ 0x0a, 0x20, 0x20, 0x5f, 0x2e, 0x65, 0x61, 0x63, 0x68, 0x28, 0x5b, 0x27,
+ 0x65, 0x73, 0x63, 0x61, 0x70, 0x65, 0x27, 0x2c, 0x20, 0x27, 0x75, 0x6e,
+ 0x65, 0x73, 0x63, 0x61, 0x70, 0x65, 0x27, 0x5d, 0x2c, 0x20, 0x66, 0x75,
+ 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x6d, 0x65, 0x74, 0x68, 0x6f,
+ 0x64, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x5f, 0x5b, 0x6d,
+ 0x65, 0x74, 0x68, 0x6f, 0x64, 0x5d, 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e,
+ 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x73, 0x74, 0x72, 0x69, 0x6e, 0x67,
+ 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66,
+ 0x20, 0x28, 0x73, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x20, 0x3d, 0x3d, 0x20,
+ 0x6e, 0x75, 0x6c, 0x6c, 0x29, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e,
+ 0x20, 0x27, 0x27, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x72,
+ 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x28, 0x27, 0x27, 0x20, 0x2b, 0x20,
+ 0x73, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x29, 0x2e, 0x72, 0x65, 0x70, 0x6c,
+ 0x61, 0x63, 0x65, 0x28, 0x65, 0x6e, 0x74, 0x69, 0x74, 0x79, 0x52, 0x65,
+ 0x67, 0x65, 0x78, 0x65, 0x73, 0x5b, 0x6d, 0x65, 0x74, 0x68, 0x6f, 0x64,
+ 0x5d, 0x2c, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28,
+ 0x6d, 0x61, 0x74, 0x63, 0x68, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20,
+ 0x65, 0x6e, 0x74, 0x69, 0x74, 0x79, 0x4d, 0x61, 0x70, 0x5b, 0x6d, 0x65,
+ 0x74, 0x68, 0x6f, 0x64, 0x5d, 0x5b, 0x6d, 0x61, 0x74, 0x63, 0x68, 0x5d,
+ 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x29, 0x3b, 0x0a,
+ 0x20, 0x20, 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x20, 0x20, 0x7d, 0x29, 0x3b,
+ 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x49, 0x66, 0x20, 0x74, 0x68,
+ 0x65, 0x20, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x20, 0x6f, 0x66, 0x20, 0x74,
+ 0x68, 0x65, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x64, 0x20, 0x70, 0x72, 0x6f,
+ 0x70, 0x65, 0x72, 0x74, 0x79, 0x20, 0x69, 0x73, 0x20, 0x61, 0x20, 0x66,
+ 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x20, 0x74, 0x68, 0x65, 0x6e,
+ 0x20, 0x69, 0x6e, 0x76, 0x6f, 0x6b, 0x65, 0x20, 0x69, 0x74, 0x3b, 0x0a,
+ 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x6f, 0x74, 0x68, 0x65, 0x72, 0x77, 0x69,
+ 0x73, 0x65, 0x2c, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x69,
+ 0x74, 0x2e, 0x0a, 0x20, 0x20, 0x5f, 0x2e, 0x72, 0x65, 0x73, 0x75, 0x6c,
+ 0x74, 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e,
+ 0x28, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x2c, 0x20, 0x70, 0x72, 0x6f,
+ 0x70, 0x65, 0x72, 0x74, 0x79, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20,
+ 0x20, 0x69, 0x66, 0x20, 0x28, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x20,
+ 0x3d, 0x3d, 0x20, 0x6e, 0x75, 0x6c, 0x6c, 0x29, 0x20, 0x72, 0x65, 0x74,
+ 0x75, 0x72, 0x6e, 0x20, 0x6e, 0x75, 0x6c, 0x6c, 0x3b, 0x0a, 0x20, 0x20,
+ 0x20, 0x20, 0x76, 0x61, 0x72, 0x20, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x20,
+ 0x3d, 0x20, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x5b, 0x70, 0x72, 0x6f,
+ 0x70, 0x65, 0x72, 0x74, 0x79, 0x5d, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x5f, 0x2e, 0x69, 0x73, 0x46,
+ 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x76, 0x61, 0x6c, 0x75,
+ 0x65, 0x29, 0x20, 0x3f, 0x20, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x2e, 0x63,
+ 0x61, 0x6c, 0x6c, 0x28, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x29, 0x20,
+ 0x3a, 0x20, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3b, 0x0a, 0x20, 0x20, 0x7d,
+ 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x41, 0x64, 0x64, 0x20,
+ 0x79, 0x6f, 0x75, 0x72, 0x20, 0x6f, 0x77, 0x6e, 0x20, 0x63, 0x75, 0x73,
+ 0x74, 0x6f, 0x6d, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e,
+ 0x73, 0x20, 0x74, 0x6f, 0x20, 0x74, 0x68, 0x65, 0x20, 0x55, 0x6e, 0x64,
+ 0x65, 0x72, 0x73, 0x63, 0x6f, 0x72, 0x65, 0x20, 0x6f, 0x62, 0x6a, 0x65,
+ 0x63, 0x74, 0x2e, 0x0a, 0x20, 0x20, 0x5f, 0x2e, 0x6d, 0x69, 0x78, 0x69,
+ 0x6e, 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e,
+ 0x28, 0x6f, 0x62, 0x6a, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x65, 0x61, 0x63, 0x68, 0x28, 0x5f, 0x2e, 0x66, 0x75, 0x6e, 0x63, 0x74,
+ 0x69, 0x6f, 0x6e, 0x73, 0x28, 0x6f, 0x62, 0x6a, 0x29, 0x2c, 0x20, 0x66,
+ 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x6e, 0x61, 0x6d, 0x65,
+ 0x29, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x76, 0x61, 0x72,
+ 0x20, 0x66, 0x75, 0x6e, 0x63, 0x20, 0x3d, 0x20, 0x5f, 0x5b, 0x6e, 0x61,
+ 0x6d, 0x65, 0x5d, 0x20, 0x3d, 0x20, 0x6f, 0x62, 0x6a, 0x5b, 0x6e, 0x61,
+ 0x6d, 0x65, 0x5d, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x5f,
+ 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x74, 0x79, 0x70, 0x65, 0x5b, 0x6e,
+ 0x61, 0x6d, 0x65, 0x5d, 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74,
+ 0x69, 0x6f, 0x6e, 0x28, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x20, 0x20, 0x76, 0x61, 0x72, 0x20, 0x61, 0x72, 0x67, 0x73,
+ 0x20, 0x3d, 0x20, 0x5b, 0x74, 0x68, 0x69, 0x73, 0x2e, 0x5f, 0x77, 0x72,
+ 0x61, 0x70, 0x70, 0x65, 0x64, 0x5d, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x20, 0x20, 0x70, 0x75, 0x73, 0x68, 0x2e, 0x61, 0x70, 0x70,
+ 0x6c, 0x79, 0x28, 0x61, 0x72, 0x67, 0x73, 0x2c, 0x20, 0x61, 0x72, 0x67,
+ 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20,
+ 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x2e, 0x63, 0x61, 0x6c, 0x6c, 0x28,
+ 0x74, 0x68, 0x69, 0x73, 0x2c, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x2e, 0x61,
+ 0x70, 0x70, 0x6c, 0x79, 0x28, 0x5f, 0x2c, 0x20, 0x61, 0x72, 0x67, 0x73,
+ 0x29, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x3b,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x7d,
+ 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x47, 0x65, 0x6e, 0x65,
+ 0x72, 0x61, 0x74, 0x65, 0x20, 0x61, 0x20, 0x75, 0x6e, 0x69, 0x71, 0x75,
+ 0x65, 0x20, 0x69, 0x6e, 0x74, 0x65, 0x67, 0x65, 0x72, 0x20, 0x69, 0x64,
+ 0x20, 0x28, 0x75, 0x6e, 0x69, 0x71, 0x75, 0x65, 0x20, 0x77, 0x69, 0x74,
+ 0x68, 0x69, 0x6e, 0x20, 0x74, 0x68, 0x65, 0x20, 0x65, 0x6e, 0x74, 0x69,
+ 0x72, 0x65, 0x20, 0x63, 0x6c, 0x69, 0x65, 0x6e, 0x74, 0x20, 0x73, 0x65,
+ 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x29, 0x2e, 0x0a, 0x20, 0x20, 0x2f, 0x2f,
+ 0x20, 0x55, 0x73, 0x65, 0x66, 0x75, 0x6c, 0x20, 0x66, 0x6f, 0x72, 0x20,
+ 0x74, 0x65, 0x6d, 0x70, 0x6f, 0x72, 0x61, 0x72, 0x79, 0x20, 0x44, 0x4f,
+ 0x4d, 0x20, 0x69, 0x64, 0x73, 0x2e, 0x0a, 0x20, 0x20, 0x76, 0x61, 0x72,
+ 0x20, 0x69, 0x64, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x65, 0x72, 0x20, 0x3d,
+ 0x20, 0x30, 0x3b, 0x0a, 0x20, 0x20, 0x5f, 0x2e, 0x75, 0x6e, 0x69, 0x71,
+ 0x75, 0x65, 0x49, 0x64, 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74,
+ 0x69, 0x6f, 0x6e, 0x28, 0x70, 0x72, 0x65, 0x66, 0x69, 0x78, 0x29, 0x20,
+ 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x76, 0x61, 0x72, 0x20, 0x69, 0x64,
+ 0x20, 0x3d, 0x20, 0x2b, 0x2b, 0x69, 0x64, 0x43, 0x6f, 0x75, 0x6e, 0x74,
+ 0x65, 0x72, 0x20, 0x2b, 0x20, 0x27, 0x27, 0x3b, 0x0a, 0x20, 0x20, 0x20,
+ 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x70, 0x72, 0x65, 0x66,
+ 0x69, 0x78, 0x20, 0x3f, 0x20, 0x70, 0x72, 0x65, 0x66, 0x69, 0x78, 0x20,
+ 0x2b, 0x20, 0x69, 0x64, 0x20, 0x3a, 0x20, 0x69, 0x64, 0x3b, 0x0a, 0x20,
+ 0x20, 0x7d, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x42, 0x79,
+ 0x20, 0x64, 0x65, 0x66, 0x61, 0x75, 0x6c, 0x74, 0x2c, 0x20, 0x55, 0x6e,
+ 0x64, 0x65, 0x72, 0x73, 0x63, 0x6f, 0x72, 0x65, 0x20, 0x75, 0x73, 0x65,
+ 0x73, 0x20, 0x45, 0x52, 0x42, 0x2d, 0x73, 0x74, 0x79, 0x6c, 0x65, 0x20,
+ 0x74, 0x65, 0x6d, 0x70, 0x6c, 0x61, 0x74, 0x65, 0x20, 0x64, 0x65, 0x6c,
+ 0x69, 0x6d, 0x69, 0x74, 0x65, 0x72, 0x73, 0x2c, 0x20, 0x63, 0x68, 0x61,
+ 0x6e, 0x67, 0x65, 0x20, 0x74, 0x68, 0x65, 0x0a, 0x20, 0x20, 0x2f, 0x2f,
+ 0x20, 0x66, 0x6f, 0x6c, 0x6c, 0x6f, 0x77, 0x69, 0x6e, 0x67, 0x20, 0x74,
+ 0x65, 0x6d, 0x70, 0x6c, 0x61, 0x74, 0x65, 0x20, 0x73, 0x65, 0x74, 0x74,
+ 0x69, 0x6e, 0x67, 0x73, 0x20, 0x74, 0x6f, 0x20, 0x75, 0x73, 0x65, 0x20,
+ 0x61, 0x6c, 0x74, 0x65, 0x72, 0x6e, 0x61, 0x74, 0x69, 0x76, 0x65, 0x20,
+ 0x64, 0x65, 0x6c, 0x69, 0x6d, 0x69, 0x74, 0x65, 0x72, 0x73, 0x2e, 0x0a,
+ 0x20, 0x20, 0x5f, 0x2e, 0x74, 0x65, 0x6d, 0x70, 0x6c, 0x61, 0x74, 0x65,
+ 0x53, 0x65, 0x74, 0x74, 0x69, 0x6e, 0x67, 0x73, 0x20, 0x3d, 0x20, 0x7b,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x65, 0x76, 0x61, 0x6c, 0x75, 0x61, 0x74,
+ 0x65, 0x20, 0x20, 0x20, 0x20, 0x3a, 0x20, 0x2f, 0x3c, 0x25, 0x28, 0x5b,
+ 0x5c, 0x73, 0x5c, 0x53, 0x5d, 0x2b, 0x3f, 0x29, 0x25, 0x3e, 0x2f, 0x67,
+ 0x2c, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x70,
+ 0x6f, 0x6c, 0x61, 0x74, 0x65, 0x20, 0x3a, 0x20, 0x2f, 0x3c, 0x25, 0x3d,
+ 0x28, 0x5b, 0x5c, 0x73, 0x5c, 0x53, 0x5d, 0x2b, 0x3f, 0x29, 0x25, 0x3e,
+ 0x2f, 0x67, 0x2c, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x65, 0x73, 0x63, 0x61,
+ 0x70, 0x65, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x3a, 0x20, 0x2f, 0x3c,
+ 0x25, 0x2d, 0x28, 0x5b, 0x5c, 0x73, 0x5c, 0x53, 0x5d, 0x2b, 0x3f, 0x29,
+ 0x25, 0x3e, 0x2f, 0x67, 0x0a, 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x0a, 0x20,
+ 0x20, 0x2f, 0x2f, 0x20, 0x57, 0x68, 0x65, 0x6e, 0x20, 0x63, 0x75, 0x73,
+ 0x74, 0x6f, 0x6d, 0x69, 0x7a, 0x69, 0x6e, 0x67, 0x20, 0x60, 0x74, 0x65,
+ 0x6d, 0x70, 0x6c, 0x61, 0x74, 0x65, 0x53, 0x65, 0x74, 0x74, 0x69, 0x6e,
+ 0x67, 0x73, 0x60, 0x2c, 0x20, 0x69, 0x66, 0x20, 0x79, 0x6f, 0x75, 0x20,
+ 0x64, 0x6f, 0x6e, 0x27, 0x74, 0x20, 0x77, 0x61, 0x6e, 0x74, 0x20, 0x74,
+ 0x6f, 0x20, 0x64, 0x65, 0x66, 0x69, 0x6e, 0x65, 0x20, 0x61, 0x6e, 0x0a,
+ 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x70, 0x6f,
+ 0x6c, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x2c, 0x20, 0x65, 0x76, 0x61, 0x6c,
+ 0x75, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x20, 0x6f, 0x72, 0x20, 0x65, 0x73,
+ 0x63, 0x61, 0x70, 0x69, 0x6e, 0x67, 0x20, 0x72, 0x65, 0x67, 0x65, 0x78,
+ 0x2c, 0x20, 0x77, 0x65, 0x20, 0x6e, 0x65, 0x65, 0x64, 0x20, 0x6f, 0x6e,
+ 0x65, 0x20, 0x74, 0x68, 0x61, 0x74, 0x20, 0x69, 0x73, 0x0a, 0x20, 0x20,
+ 0x2f, 0x2f, 0x20, 0x67, 0x75, 0x61, 0x72, 0x61, 0x6e, 0x74, 0x65, 0x65,
+ 0x64, 0x20, 0x6e, 0x6f, 0x74, 0x20, 0x74, 0x6f, 0x20, 0x6d, 0x61, 0x74,
+ 0x63, 0x68, 0x2e, 0x0a, 0x20, 0x20, 0x76, 0x61, 0x72, 0x20, 0x6e, 0x6f,
+ 0x4d, 0x61, 0x74, 0x63, 0x68, 0x20, 0x3d, 0x20, 0x2f, 0x28, 0x2e, 0x29,
+ 0x5e, 0x2f, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x43, 0x65,
+ 0x72, 0x74, 0x61, 0x69, 0x6e, 0x20, 0x63, 0x68, 0x61, 0x72, 0x61, 0x63,
+ 0x74, 0x65, 0x72, 0x73, 0x20, 0x6e, 0x65, 0x65, 0x64, 0x20, 0x74, 0x6f,
+ 0x20, 0x62, 0x65, 0x20, 0x65, 0x73, 0x63, 0x61, 0x70, 0x65, 0x64, 0x20,
+ 0x73, 0x6f, 0x20, 0x74, 0x68, 0x61, 0x74, 0x20, 0x74, 0x68, 0x65, 0x79,
+ 0x20, 0x63, 0x61, 0x6e, 0x20, 0x62, 0x65, 0x20, 0x70, 0x75, 0x74, 0x20,
+ 0x69, 0x6e, 0x74, 0x6f, 0x20, 0x61, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20,
+ 0x73, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x20, 0x6c, 0x69, 0x74, 0x65, 0x72,
+ 0x61, 0x6c, 0x2e, 0x0a, 0x20, 0x20, 0x76, 0x61, 0x72, 0x20, 0x65, 0x73,
+ 0x63, 0x61, 0x70, 0x65, 0x73, 0x20, 0x3d, 0x20, 0x7b, 0x0a, 0x20, 0x20,
+ 0x20, 0x20, 0x22, 0x27, 0x22, 0x3a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x22, 0x27, 0x22, 0x2c, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x27, 0x5c, 0x5c,
+ 0x27, 0x3a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x27, 0x5c, 0x5c, 0x27, 0x2c,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x27, 0x5c, 0x72, 0x27, 0x3a, 0x20, 0x20,
+ 0x20, 0x20, 0x20, 0x27, 0x72, 0x27, 0x2c, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x27, 0x5c, 0x6e, 0x27, 0x3a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x27, 0x6e,
+ 0x27, 0x2c, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x27, 0x5c, 0x74, 0x27, 0x3a,
+ 0x20, 0x20, 0x20, 0x20, 0x20, 0x27, 0x74, 0x27, 0x2c, 0x0a, 0x20, 0x20,
+ 0x20, 0x20, 0x27, 0x5c, 0x75, 0x32, 0x30, 0x32, 0x38, 0x27, 0x3a, 0x20,
+ 0x27, 0x75, 0x32, 0x30, 0x32, 0x38, 0x27, 0x2c, 0x0a, 0x20, 0x20, 0x20,
+ 0x20, 0x27, 0x5c, 0x75, 0x32, 0x30, 0x32, 0x39, 0x27, 0x3a, 0x20, 0x27,
+ 0x75, 0x32, 0x30, 0x32, 0x39, 0x27, 0x0a, 0x20, 0x20, 0x7d, 0x3b, 0x0a,
+ 0x0a, 0x20, 0x20, 0x76, 0x61, 0x72, 0x20, 0x65, 0x73, 0x63, 0x61, 0x70,
+ 0x65, 0x72, 0x20, 0x3d, 0x20, 0x2f, 0x5c, 0x5c, 0x7c, 0x27, 0x7c, 0x5c,
+ 0x72, 0x7c, 0x5c, 0x6e, 0x7c, 0x5c, 0x74, 0x7c, 0x5c, 0x75, 0x32, 0x30,
+ 0x32, 0x38, 0x7c, 0x5c, 0x75, 0x32, 0x30, 0x32, 0x39, 0x2f, 0x67, 0x3b,
+ 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x4a, 0x61, 0x76, 0x61, 0x53,
+ 0x63, 0x72, 0x69, 0x70, 0x74, 0x20, 0x6d, 0x69, 0x63, 0x72, 0x6f, 0x2d,
+ 0x74, 0x65, 0x6d, 0x70, 0x6c, 0x61, 0x74, 0x69, 0x6e, 0x67, 0x2c, 0x20,
+ 0x73, 0x69, 0x6d, 0x69, 0x6c, 0x61, 0x72, 0x20, 0x74, 0x6f, 0x20, 0x4a,
+ 0x6f, 0x68, 0x6e, 0x20, 0x52, 0x65, 0x73, 0x69, 0x67, 0x27, 0x73, 0x20,
+ 0x69, 0x6d, 0x70, 0x6c, 0x65, 0x6d, 0x65, 0x6e, 0x74, 0x61, 0x74, 0x69,
+ 0x6f, 0x6e, 0x2e, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x55, 0x6e, 0x64,
+ 0x65, 0x72, 0x73, 0x63, 0x6f, 0x72, 0x65, 0x20, 0x74, 0x65, 0x6d, 0x70,
+ 0x6c, 0x61, 0x74, 0x69, 0x6e, 0x67, 0x20, 0x68, 0x61, 0x6e, 0x64, 0x6c,
+ 0x65, 0x73, 0x20, 0x61, 0x72, 0x62, 0x69, 0x74, 0x72, 0x61, 0x72, 0x79,
+ 0x20, 0x64, 0x65, 0x6c, 0x69, 0x6d, 0x69, 0x74, 0x65, 0x72, 0x73, 0x2c,
+ 0x20, 0x70, 0x72, 0x65, 0x73, 0x65, 0x72, 0x76, 0x65, 0x73, 0x20, 0x77,
+ 0x68, 0x69, 0x74, 0x65, 0x73, 0x70, 0x61, 0x63, 0x65, 0x2c, 0x0a, 0x20,
+ 0x20, 0x2f, 0x2f, 0x20, 0x61, 0x6e, 0x64, 0x20, 0x63, 0x6f, 0x72, 0x72,
+ 0x65, 0x63, 0x74, 0x6c, 0x79, 0x20, 0x65, 0x73, 0x63, 0x61, 0x70, 0x65,
+ 0x73, 0x20, 0x71, 0x75, 0x6f, 0x74, 0x65, 0x73, 0x20, 0x77, 0x69, 0x74,
+ 0x68, 0x69, 0x6e, 0x20, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x70, 0x6f, 0x6c,
+ 0x61, 0x74, 0x65, 0x64, 0x20, 0x63, 0x6f, 0x64, 0x65, 0x2e, 0x0a, 0x20,
+ 0x20, 0x5f, 0x2e, 0x74, 0x65, 0x6d, 0x70, 0x6c, 0x61, 0x74, 0x65, 0x20,
+ 0x3d, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x74,
+ 0x65, 0x78, 0x74, 0x2c, 0x20, 0x64, 0x61, 0x74, 0x61, 0x2c, 0x20, 0x73,
+ 0x65, 0x74, 0x74, 0x69, 0x6e, 0x67, 0x73, 0x29, 0x20, 0x7b, 0x0a, 0x20,
+ 0x20, 0x20, 0x20, 0x76, 0x61, 0x72, 0x20, 0x72, 0x65, 0x6e, 0x64, 0x65,
+ 0x72, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x73, 0x65, 0x74, 0x74, 0x69,
+ 0x6e, 0x67, 0x73, 0x20, 0x3d, 0x20, 0x5f, 0x2e, 0x64, 0x65, 0x66, 0x61,
+ 0x75, 0x6c, 0x74, 0x73, 0x28, 0x7b, 0x7d, 0x2c, 0x20, 0x73, 0x65, 0x74,
+ 0x74, 0x69, 0x6e, 0x67, 0x73, 0x2c, 0x20, 0x5f, 0x2e, 0x74, 0x65, 0x6d,
+ 0x70, 0x6c, 0x61, 0x74, 0x65, 0x53, 0x65, 0x74, 0x74, 0x69, 0x6e, 0x67,
+ 0x73, 0x29, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x2f, 0x2f, 0x20,
+ 0x43, 0x6f, 0x6d, 0x62, 0x69, 0x6e, 0x65, 0x20, 0x64, 0x65, 0x6c, 0x69,
+ 0x6d, 0x69, 0x74, 0x65, 0x72, 0x73, 0x20, 0x69, 0x6e, 0x74, 0x6f, 0x20,
+ 0x6f, 0x6e, 0x65, 0x20, 0x72, 0x65, 0x67, 0x75, 0x6c, 0x61, 0x72, 0x20,
+ 0x65, 0x78, 0x70, 0x72, 0x65, 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x20, 0x76,
+ 0x69, 0x61, 0x20, 0x61, 0x6c, 0x74, 0x65, 0x72, 0x6e, 0x61, 0x74, 0x69,
+ 0x6f, 0x6e, 0x2e, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x76, 0x61, 0x72, 0x20,
+ 0x6d, 0x61, 0x74, 0x63, 0x68, 0x65, 0x72, 0x20, 0x3d, 0x20, 0x6e, 0x65,
+ 0x77, 0x20, 0x52, 0x65, 0x67, 0x45, 0x78, 0x70, 0x28, 0x5b, 0x0a, 0x20,
+ 0x20, 0x20, 0x20, 0x20, 0x20, 0x28, 0x73, 0x65, 0x74, 0x74, 0x69, 0x6e,
+ 0x67, 0x73, 0x2e, 0x65, 0x73, 0x63, 0x61, 0x70, 0x65, 0x20, 0x7c, 0x7c,
+ 0x20, 0x6e, 0x6f, 0x4d, 0x61, 0x74, 0x63, 0x68, 0x29, 0x2e, 0x73, 0x6f,
+ 0x75, 0x72, 0x63, 0x65, 0x2c, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x28, 0x73, 0x65, 0x74, 0x74, 0x69, 0x6e, 0x67, 0x73, 0x2e, 0x69, 0x6e,
+ 0x74, 0x65, 0x72, 0x70, 0x6f, 0x6c, 0x61, 0x74, 0x65, 0x20, 0x7c, 0x7c,
+ 0x20, 0x6e, 0x6f, 0x4d, 0x61, 0x74, 0x63, 0x68, 0x29, 0x2e, 0x73, 0x6f,
+ 0x75, 0x72, 0x63, 0x65, 0x2c, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x28, 0x73, 0x65, 0x74, 0x74, 0x69, 0x6e, 0x67, 0x73, 0x2e, 0x65, 0x76,
+ 0x61, 0x6c, 0x75, 0x61, 0x74, 0x65, 0x20, 0x7c, 0x7c, 0x20, 0x6e, 0x6f,
+ 0x4d, 0x61, 0x74, 0x63, 0x68, 0x29, 0x2e, 0x73, 0x6f, 0x75, 0x72, 0x63,
+ 0x65, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x5d, 0x2e, 0x6a, 0x6f, 0x69, 0x6e,
+ 0x28, 0x27, 0x7c, 0x27, 0x29, 0x20, 0x2b, 0x20, 0x27, 0x7c, 0x24, 0x27,
+ 0x2c, 0x20, 0x27, 0x67, 0x27, 0x29, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x20,
+ 0x20, 0x2f, 0x2f, 0x20, 0x43, 0x6f, 0x6d, 0x70, 0x69, 0x6c, 0x65, 0x20,
+ 0x74, 0x68, 0x65, 0x20, 0x74, 0x65, 0x6d, 0x70, 0x6c, 0x61, 0x74, 0x65,
+ 0x20, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x2c, 0x20, 0x65, 0x73, 0x63,
+ 0x61, 0x70, 0x69, 0x6e, 0x67, 0x20, 0x73, 0x74, 0x72, 0x69, 0x6e, 0x67,
+ 0x20, 0x6c, 0x69, 0x74, 0x65, 0x72, 0x61, 0x6c, 0x73, 0x20, 0x61, 0x70,
+ 0x70, 0x72, 0x6f, 0x70, 0x72, 0x69, 0x61, 0x74, 0x65, 0x6c, 0x79, 0x2e,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x76, 0x61, 0x72, 0x20, 0x69, 0x6e, 0x64,
+ 0x65, 0x78, 0x20, 0x3d, 0x20, 0x30, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x76, 0x61, 0x72, 0x20, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x20, 0x3d,
+ 0x20, 0x22, 0x5f, 0x5f, 0x70, 0x2b, 0x3d, 0x27, 0x22, 0x3b, 0x0a, 0x20,
+ 0x20, 0x20, 0x20, 0x74, 0x65, 0x78, 0x74, 0x2e, 0x72, 0x65, 0x70, 0x6c,
+ 0x61, 0x63, 0x65, 0x28, 0x6d, 0x61, 0x74, 0x63, 0x68, 0x65, 0x72, 0x2c,
+ 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x6d, 0x61,
+ 0x74, 0x63, 0x68, 0x2c, 0x20, 0x65, 0x73, 0x63, 0x61, 0x70, 0x65, 0x2c,
+ 0x20, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x70, 0x6f, 0x6c, 0x61, 0x74, 0x65,
+ 0x2c, 0x20, 0x65, 0x76, 0x61, 0x6c, 0x75, 0x61, 0x74, 0x65, 0x2c, 0x20,
+ 0x6f, 0x66, 0x66, 0x73, 0x65, 0x74, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20,
+ 0x20, 0x20, 0x20, 0x20, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x20, 0x2b,
+ 0x3d, 0x20, 0x74, 0x65, 0x78, 0x74, 0x2e, 0x73, 0x6c, 0x69, 0x63, 0x65,
+ 0x28, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x2c, 0x20, 0x6f, 0x66, 0x66, 0x73,
+ 0x65, 0x74, 0x29, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x2e, 0x72, 0x65, 0x70, 0x6c, 0x61, 0x63, 0x65, 0x28, 0x65, 0x73, 0x63,
+ 0x61, 0x70, 0x65, 0x72, 0x2c, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69,
+ 0x6f, 0x6e, 0x28, 0x6d, 0x61, 0x74, 0x63, 0x68, 0x29, 0x20, 0x7b, 0x20,
+ 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x27, 0x5c, 0x5c, 0x27, 0x20,
+ 0x2b, 0x20, 0x65, 0x73, 0x63, 0x61, 0x70, 0x65, 0x73, 0x5b, 0x6d, 0x61,
+ 0x74, 0x63, 0x68, 0x5d, 0x3b, 0x20, 0x7d, 0x29, 0x3b, 0x0a, 0x0a, 0x20,
+ 0x20, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20, 0x28, 0x65, 0x73, 0x63,
+ 0x61, 0x70, 0x65, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x20, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x20, 0x2b, 0x3d,
+ 0x20, 0x22, 0x27, 0x2b, 0x5c, 0x6e, 0x28, 0x28, 0x5f, 0x5f, 0x74, 0x3d,
+ 0x28, 0x22, 0x20, 0x2b, 0x20, 0x65, 0x73, 0x63, 0x61, 0x70, 0x65, 0x20,
+ 0x2b, 0x20, 0x22, 0x29, 0x29, 0x3d, 0x3d, 0x6e, 0x75, 0x6c, 0x6c, 0x3f,
+ 0x27, 0x27, 0x3a, 0x5f, 0x2e, 0x65, 0x73, 0x63, 0x61, 0x70, 0x65, 0x28,
+ 0x5f, 0x5f, 0x74, 0x29, 0x29, 0x2b, 0x5c, 0x6e, 0x27, 0x22, 0x3b, 0x0a,
+ 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x69, 0x66, 0x20, 0x28, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x70,
+ 0x6f, 0x6c, 0x61, 0x74, 0x65, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x20, 0x20, 0x20, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x20,
+ 0x2b, 0x3d, 0x20, 0x22, 0x27, 0x2b, 0x5c, 0x6e, 0x28, 0x28, 0x5f, 0x5f,
+ 0x74, 0x3d, 0x28, 0x22, 0x20, 0x2b, 0x20, 0x69, 0x6e, 0x74, 0x65, 0x72,
+ 0x70, 0x6f, 0x6c, 0x61, 0x74, 0x65, 0x20, 0x2b, 0x20, 0x22, 0x29, 0x29,
+ 0x3d, 0x3d, 0x6e, 0x75, 0x6c, 0x6c, 0x3f, 0x27, 0x27, 0x3a, 0x5f, 0x5f,
+ 0x74, 0x29, 0x2b, 0x5c, 0x6e, 0x27, 0x22, 0x3b, 0x0a, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x20, 0x7d, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x69,
+ 0x66, 0x20, 0x28, 0x65, 0x76, 0x61, 0x6c, 0x75, 0x61, 0x74, 0x65, 0x29,
+ 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x73,
+ 0x6f, 0x75, 0x72, 0x63, 0x65, 0x20, 0x2b, 0x3d, 0x20, 0x22, 0x27, 0x3b,
+ 0x5c, 0x6e, 0x22, 0x20, 0x2b, 0x20, 0x65, 0x76, 0x61, 0x6c, 0x75, 0x61,
+ 0x74, 0x65, 0x20, 0x2b, 0x20, 0x22, 0x5c, 0x6e, 0x5f, 0x5f, 0x70, 0x2b,
+ 0x3d, 0x27, 0x22, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x7d,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x69, 0x6e, 0x64, 0x65, 0x78,
+ 0x20, 0x3d, 0x20, 0x6f, 0x66, 0x66, 0x73, 0x65, 0x74, 0x20, 0x2b, 0x20,
+ 0x6d, 0x61, 0x74, 0x63, 0x68, 0x2e, 0x6c, 0x65, 0x6e, 0x67, 0x74, 0x68,
+ 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74, 0x75,
+ 0x72, 0x6e, 0x20, 0x6d, 0x61, 0x74, 0x63, 0x68, 0x3b, 0x0a, 0x20, 0x20,
+ 0x20, 0x20, 0x7d, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x73, 0x6f,
+ 0x75, 0x72, 0x63, 0x65, 0x20, 0x2b, 0x3d, 0x20, 0x22, 0x27, 0x3b, 0x5c,
+ 0x6e, 0x22, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x2f, 0x2f, 0x20,
+ 0x49, 0x66, 0x20, 0x61, 0x20, 0x76, 0x61, 0x72, 0x69, 0x61, 0x62, 0x6c,
+ 0x65, 0x20, 0x69, 0x73, 0x20, 0x6e, 0x6f, 0x74, 0x20, 0x73, 0x70, 0x65,
+ 0x63, 0x69, 0x66, 0x69, 0x65, 0x64, 0x2c, 0x20, 0x70, 0x6c, 0x61, 0x63,
+ 0x65, 0x20, 0x64, 0x61, 0x74, 0x61, 0x20, 0x76, 0x61, 0x6c, 0x75, 0x65,
+ 0x73, 0x20, 0x69, 0x6e, 0x20, 0x6c, 0x6f, 0x63, 0x61, 0x6c, 0x20, 0x73,
+ 0x63, 0x6f, 0x70, 0x65, 0x2e, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66,
+ 0x20, 0x28, 0x21, 0x73, 0x65, 0x74, 0x74, 0x69, 0x6e, 0x67, 0x73, 0x2e,
+ 0x76, 0x61, 0x72, 0x69, 0x61, 0x62, 0x6c, 0x65, 0x29, 0x20, 0x73, 0x6f,
+ 0x75, 0x72, 0x63, 0x65, 0x20, 0x3d, 0x20, 0x27, 0x77, 0x69, 0x74, 0x68,
+ 0x28, 0x6f, 0x62, 0x6a, 0x7c, 0x7c, 0x7b, 0x7d, 0x29, 0x7b, 0x5c, 0x6e,
+ 0x27, 0x20, 0x2b, 0x20, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x20, 0x2b,
+ 0x20, 0x27, 0x7d, 0x5c, 0x6e, 0x27, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x20,
+ 0x20, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x20, 0x3d, 0x20, 0x22, 0x76,
+ 0x61, 0x72, 0x20, 0x5f, 0x5f, 0x74, 0x2c, 0x5f, 0x5f, 0x70, 0x3d, 0x27,
+ 0x27, 0x2c, 0x5f, 0x5f, 0x6a, 0x3d, 0x41, 0x72, 0x72, 0x61, 0x79, 0x2e,
+ 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x74, 0x79, 0x70, 0x65, 0x2e, 0x6a, 0x6f,
+ 0x69, 0x6e, 0x2c, 0x22, 0x20, 0x2b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x22, 0x70, 0x72, 0x69, 0x6e, 0x74, 0x3d, 0x66, 0x75, 0x6e, 0x63,
+ 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x29, 0x7b, 0x5f, 0x5f, 0x70, 0x2b, 0x3d,
+ 0x5f, 0x5f, 0x6a, 0x2e, 0x63, 0x61, 0x6c, 0x6c, 0x28, 0x61, 0x72, 0x67,
+ 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x2c, 0x27, 0x27, 0x29, 0x3b, 0x7d,
+ 0x3b, 0x5c, 0x6e, 0x22, 0x20, 0x2b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x20, 0x2b, 0x20, 0x22, 0x72,
+ 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x5f, 0x5f, 0x70, 0x3b, 0x5c, 0x6e,
+ 0x22, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x74, 0x72, 0x79, 0x20,
+ 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x6e, 0x64,
+ 0x65, 0x72, 0x20, 0x3d, 0x20, 0x6e, 0x65, 0x77, 0x20, 0x46, 0x75, 0x6e,
+ 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x73, 0x65, 0x74, 0x74, 0x69, 0x6e,
+ 0x67, 0x73, 0x2e, 0x76, 0x61, 0x72, 0x69, 0x61, 0x62, 0x6c, 0x65, 0x20,
+ 0x7c, 0x7c, 0x20, 0x27, 0x6f, 0x62, 0x6a, 0x27, 0x2c, 0x20, 0x27, 0x5f,
+ 0x27, 0x2c, 0x20, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x29, 0x3b, 0x0a,
+ 0x20, 0x20, 0x20, 0x20, 0x7d, 0x20, 0x63, 0x61, 0x74, 0x63, 0x68, 0x20,
+ 0x28, 0x65, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x65, 0x2e, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x20, 0x3d, 0x20, 0x73,
+ 0x6f, 0x75, 0x72, 0x63, 0x65, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x74, 0x68, 0x72, 0x6f, 0x77, 0x20, 0x65, 0x3b, 0x0a, 0x20, 0x20,
+ 0x20, 0x20, 0x7d, 0x0a, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20,
+ 0x28, 0x64, 0x61, 0x74, 0x61, 0x29, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72,
+ 0x6e, 0x20, 0x72, 0x65, 0x6e, 0x64, 0x65, 0x72, 0x28, 0x64, 0x61, 0x74,
+ 0x61, 0x2c, 0x20, 0x5f, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x76,
+ 0x61, 0x72, 0x20, 0x74, 0x65, 0x6d, 0x70, 0x6c, 0x61, 0x74, 0x65, 0x20,
+ 0x3d, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x64,
+ 0x61, 0x74, 0x61, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x72, 0x65, 0x6e, 0x64,
+ 0x65, 0x72, 0x2e, 0x63, 0x61, 0x6c, 0x6c, 0x28, 0x74, 0x68, 0x69, 0x73,
+ 0x2c, 0x20, 0x64, 0x61, 0x74, 0x61, 0x2c, 0x20, 0x5f, 0x29, 0x3b, 0x0a,
+ 0x20, 0x20, 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x2f, 0x2f, 0x20, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x20, 0x74,
+ 0x68, 0x65, 0x20, 0x63, 0x6f, 0x6d, 0x70, 0x69, 0x6c, 0x65, 0x64, 0x20,
+ 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x20, 0x73, 0x6f, 0x75,
+ 0x72, 0x63, 0x65, 0x20, 0x61, 0x73, 0x20, 0x61, 0x20, 0x63, 0x6f, 0x6e,
+ 0x76, 0x65, 0x6e, 0x69, 0x65, 0x6e, 0x63, 0x65, 0x20, 0x66, 0x6f, 0x72,
+ 0x20, 0x70, 0x72, 0x65, 0x63, 0x6f, 0x6d, 0x70, 0x69, 0x6c, 0x61, 0x74,
+ 0x69, 0x6f, 0x6e, 0x2e, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x74, 0x65, 0x6d,
+ 0x70, 0x6c, 0x61, 0x74, 0x65, 0x2e, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65,
+ 0x20, 0x3d, 0x20, 0x27, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e,
+ 0x28, 0x27, 0x20, 0x2b, 0x20, 0x28, 0x73, 0x65, 0x74, 0x74, 0x69, 0x6e,
+ 0x67, 0x73, 0x2e, 0x76, 0x61, 0x72, 0x69, 0x61, 0x62, 0x6c, 0x65, 0x20,
+ 0x7c, 0x7c, 0x20, 0x27, 0x6f, 0x62, 0x6a, 0x27, 0x29, 0x20, 0x2b, 0x20,
+ 0x27, 0x29, 0x7b, 0x5c, 0x6e, 0x27, 0x20, 0x2b, 0x20, 0x73, 0x6f, 0x75,
+ 0x72, 0x63, 0x65, 0x20, 0x2b, 0x20, 0x27, 0x7d, 0x27, 0x3b, 0x0a, 0x0a,
+ 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x74,
+ 0x65, 0x6d, 0x70, 0x6c, 0x61, 0x74, 0x65, 0x3b, 0x0a, 0x20, 0x20, 0x7d,
+ 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x41, 0x64, 0x64, 0x20,
+ 0x61, 0x20, 0x22, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x22, 0x20, 0x66, 0x75,
+ 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x2c, 0x20, 0x77, 0x68, 0x69, 0x63,
+ 0x68, 0x20, 0x77, 0x69, 0x6c, 0x6c, 0x20, 0x64, 0x65, 0x6c, 0x65, 0x67,
+ 0x61, 0x74, 0x65, 0x20, 0x74, 0x6f, 0x20, 0x74, 0x68, 0x65, 0x20, 0x77,
+ 0x72, 0x61, 0x70, 0x70, 0x65, 0x72, 0x2e, 0x0a, 0x20, 0x20, 0x5f, 0x2e,
+ 0x63, 0x68, 0x61, 0x69, 0x6e, 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e, 0x63,
+ 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x6f, 0x62, 0x6a, 0x29, 0x20, 0x7b, 0x0a,
+ 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x5f,
+ 0x28, 0x6f, 0x62, 0x6a, 0x29, 0x2e, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x28,
+ 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f,
+ 0x2f, 0x20, 0x4f, 0x4f, 0x50, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x2d,
+ 0x2d, 0x2d, 0x2d, 0x2d, 0x2d, 0x2d, 0x2d, 0x2d, 0x2d, 0x2d, 0x2d, 0x2d,
+ 0x2d, 0x2d, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x49, 0x66, 0x20, 0x55,
+ 0x6e, 0x64, 0x65, 0x72, 0x73, 0x63, 0x6f, 0x72, 0x65, 0x20, 0x69, 0x73,
+ 0x20, 0x63, 0x61, 0x6c, 0x6c, 0x65, 0x64, 0x20, 0x61, 0x73, 0x20, 0x61,
+ 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x2c, 0x20, 0x69,
+ 0x74, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x73, 0x20, 0x61, 0x20,
+ 0x77, 0x72, 0x61, 0x70, 0x70, 0x65, 0x64, 0x20, 0x6f, 0x62, 0x6a, 0x65,
+ 0x63, 0x74, 0x20, 0x74, 0x68, 0x61, 0x74, 0x0a, 0x20, 0x20, 0x2f, 0x2f,
+ 0x20, 0x63, 0x61, 0x6e, 0x20, 0x62, 0x65, 0x20, 0x75, 0x73, 0x65, 0x64,
+ 0x20, 0x4f, 0x4f, 0x2d, 0x73, 0x74, 0x79, 0x6c, 0x65, 0x2e, 0x20, 0x54,
+ 0x68, 0x69, 0x73, 0x20, 0x77, 0x72, 0x61, 0x70, 0x70, 0x65, 0x72, 0x20,
+ 0x68, 0x6f, 0x6c, 0x64, 0x73, 0x20, 0x61, 0x6c, 0x74, 0x65, 0x72, 0x65,
+ 0x64, 0x20, 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x73, 0x20, 0x6f,
+ 0x66, 0x20, 0x61, 0x6c, 0x6c, 0x20, 0x74, 0x68, 0x65, 0x0a, 0x20, 0x20,
+ 0x2f, 0x2f, 0x20, 0x75, 0x6e, 0x64, 0x65, 0x72, 0x73, 0x63, 0x6f, 0x72,
+ 0x65, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x2e,
+ 0x20, 0x57, 0x72, 0x61, 0x70, 0x70, 0x65, 0x64, 0x20, 0x6f, 0x62, 0x6a,
+ 0x65, 0x63, 0x74, 0x73, 0x20, 0x6d, 0x61, 0x79, 0x20, 0x62, 0x65, 0x20,
+ 0x63, 0x68, 0x61, 0x69, 0x6e, 0x65, 0x64, 0x2e, 0x0a, 0x0a, 0x20, 0x20,
+ 0x2f, 0x2f, 0x20, 0x48, 0x65, 0x6c, 0x70, 0x65, 0x72, 0x20, 0x66, 0x75,
+ 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x20, 0x74, 0x6f, 0x20, 0x63, 0x6f,
+ 0x6e, 0x74, 0x69, 0x6e, 0x75, 0x65, 0x20, 0x63, 0x68, 0x61, 0x69, 0x6e,
+ 0x69, 0x6e, 0x67, 0x20, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x6d, 0x65, 0x64,
+ 0x69, 0x61, 0x74, 0x65, 0x20, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x73,
+ 0x2e, 0x0a, 0x20, 0x20, 0x76, 0x61, 0x72, 0x20, 0x72, 0x65, 0x73, 0x75,
+ 0x6c, 0x74, 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f,
+ 0x6e, 0x28, 0x6f, 0x62, 0x6a, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20,
+ 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x74, 0x68, 0x69, 0x73,
+ 0x2e, 0x5f, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x20, 0x3f, 0x20, 0x5f, 0x28,
+ 0x6f, 0x62, 0x6a, 0x29, 0x2e, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x28, 0x29,
+ 0x20, 0x3a, 0x20, 0x6f, 0x62, 0x6a, 0x3b, 0x0a, 0x20, 0x20, 0x7d, 0x3b,
+ 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x41, 0x64, 0x64, 0x20, 0x61,
+ 0x6c, 0x6c, 0x20, 0x6f, 0x66, 0x20, 0x74, 0x68, 0x65, 0x20, 0x55, 0x6e,
+ 0x64, 0x65, 0x72, 0x73, 0x63, 0x6f, 0x72, 0x65, 0x20, 0x66, 0x75, 0x6e,
+ 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x20, 0x74, 0x6f, 0x20, 0x74, 0x68,
+ 0x65, 0x20, 0x77, 0x72, 0x61, 0x70, 0x70, 0x65, 0x72, 0x20, 0x6f, 0x62,
+ 0x6a, 0x65, 0x63, 0x74, 0x2e, 0x0a, 0x20, 0x20, 0x5f, 0x2e, 0x6d, 0x69,
+ 0x78, 0x69, 0x6e, 0x28, 0x5f, 0x29, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f,
+ 0x2f, 0x20, 0x41, 0x64, 0x64, 0x20, 0x61, 0x6c, 0x6c, 0x20, 0x6d, 0x75,
+ 0x74, 0x61, 0x74, 0x6f, 0x72, 0x20, 0x41, 0x72, 0x72, 0x61, 0x79, 0x20,
+ 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x20, 0x74, 0x6f,
+ 0x20, 0x74, 0x68, 0x65, 0x20, 0x77, 0x72, 0x61, 0x70, 0x70, 0x65, 0x72,
+ 0x2e, 0x0a, 0x20, 0x20, 0x65, 0x61, 0x63, 0x68, 0x28, 0x5b, 0x27, 0x70,
+ 0x6f, 0x70, 0x27, 0x2c, 0x20, 0x27, 0x70, 0x75, 0x73, 0x68, 0x27, 0x2c,
+ 0x20, 0x27, 0x72, 0x65, 0x76, 0x65, 0x72, 0x73, 0x65, 0x27, 0x2c, 0x20,
+ 0x27, 0x73, 0x68, 0x69, 0x66, 0x74, 0x27, 0x2c, 0x20, 0x27, 0x73, 0x6f,
+ 0x72, 0x74, 0x27, 0x2c, 0x20, 0x27, 0x73, 0x70, 0x6c, 0x69, 0x63, 0x65,
+ 0x27, 0x2c, 0x20, 0x27, 0x75, 0x6e, 0x73, 0x68, 0x69, 0x66, 0x74, 0x27,
+ 0x5d, 0x2c, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28,
+ 0x6e, 0x61, 0x6d, 0x65, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x76, 0x61, 0x72, 0x20, 0x6d, 0x65, 0x74, 0x68, 0x6f, 0x64, 0x20, 0x3d,
+ 0x20, 0x41, 0x72, 0x72, 0x61, 0x79, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x5b,
+ 0x6e, 0x61, 0x6d, 0x65, 0x5d, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x5f,
+ 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x74, 0x79, 0x70, 0x65, 0x5b, 0x6e,
+ 0x61, 0x6d, 0x65, 0x5d, 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74,
+ 0x69, 0x6f, 0x6e, 0x28, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x76, 0x61, 0x72, 0x20, 0x6f, 0x62, 0x6a, 0x20, 0x3d, 0x20,
+ 0x74, 0x68, 0x69, 0x73, 0x2e, 0x5f, 0x77, 0x72, 0x61, 0x70, 0x70, 0x65,
+ 0x64, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x6d, 0x65, 0x74,
+ 0x68, 0x6f, 0x64, 0x2e, 0x61, 0x70, 0x70, 0x6c, 0x79, 0x28, 0x6f, 0x62,
+ 0x6a, 0x2c, 0x20, 0x61, 0x72, 0x67, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x73,
+ 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20,
+ 0x28, 0x28, 0x6e, 0x61, 0x6d, 0x65, 0x20, 0x3d, 0x3d, 0x20, 0x27, 0x73,
+ 0x68, 0x69, 0x66, 0x74, 0x27, 0x20, 0x7c, 0x7c, 0x20, 0x6e, 0x61, 0x6d,
+ 0x65, 0x20, 0x3d, 0x3d, 0x20, 0x27, 0x73, 0x70, 0x6c, 0x69, 0x63, 0x65,
+ 0x27, 0x29, 0x20, 0x26, 0x26, 0x20, 0x6f, 0x62, 0x6a, 0x2e, 0x6c, 0x65,
+ 0x6e, 0x67, 0x74, 0x68, 0x20, 0x3d, 0x3d, 0x3d, 0x20, 0x30, 0x29, 0x20,
+ 0x64, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x20, 0x6f, 0x62, 0x6a, 0x5b, 0x30,
+ 0x5d, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74,
+ 0x75, 0x72, 0x6e, 0x20, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x2e, 0x63,
+ 0x61, 0x6c, 0x6c, 0x28, 0x74, 0x68, 0x69, 0x73, 0x2c, 0x20, 0x6f, 0x62,
+ 0x6a, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x3b, 0x0a, 0x20,
+ 0x20, 0x7d, 0x29, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x41,
+ 0x64, 0x64, 0x20, 0x61, 0x6c, 0x6c, 0x20, 0x61, 0x63, 0x63, 0x65, 0x73,
+ 0x73, 0x6f, 0x72, 0x20, 0x41, 0x72, 0x72, 0x61, 0x79, 0x20, 0x66, 0x75,
+ 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x20, 0x74, 0x6f, 0x20, 0x74,
+ 0x68, 0x65, 0x20, 0x77, 0x72, 0x61, 0x70, 0x70, 0x65, 0x72, 0x2e, 0x0a,
+ 0x20, 0x20, 0x65, 0x61, 0x63, 0x68, 0x28, 0x5b, 0x27, 0x63, 0x6f, 0x6e,
+ 0x63, 0x61, 0x74, 0x27, 0x2c, 0x20, 0x27, 0x6a, 0x6f, 0x69, 0x6e, 0x27,
+ 0x2c, 0x20, 0x27, 0x73, 0x6c, 0x69, 0x63, 0x65, 0x27, 0x5d, 0x2c, 0x20,
+ 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x6e, 0x61, 0x6d,
+ 0x65, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x76, 0x61, 0x72,
+ 0x20, 0x6d, 0x65, 0x74, 0x68, 0x6f, 0x64, 0x20, 0x3d, 0x20, 0x41, 0x72,
+ 0x72, 0x61, 0x79, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x5b, 0x6e, 0x61, 0x6d,
+ 0x65, 0x5d, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x5f, 0x2e, 0x70, 0x72,
+ 0x6f, 0x74, 0x6f, 0x74, 0x79, 0x70, 0x65, 0x5b, 0x6e, 0x61, 0x6d, 0x65,
+ 0x5d, 0x20, 0x3d, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e,
+ 0x28, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x72,
+ 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74,
+ 0x2e, 0x63, 0x61, 0x6c, 0x6c, 0x28, 0x74, 0x68, 0x69, 0x73, 0x2c, 0x20,
+ 0x6d, 0x65, 0x74, 0x68, 0x6f, 0x64, 0x2e, 0x61, 0x70, 0x70, 0x6c, 0x79,
+ 0x28, 0x74, 0x68, 0x69, 0x73, 0x2e, 0x5f, 0x77, 0x72, 0x61, 0x70, 0x70,
+ 0x65, 0x64, 0x2c, 0x20, 0x61, 0x72, 0x67, 0x75, 0x6d, 0x65, 0x6e, 0x74,
+ 0x73, 0x29, 0x29, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x3b, 0x0a,
+ 0x20, 0x20, 0x7d, 0x29, 0x3b, 0x0a, 0x0a, 0x20, 0x20, 0x5f, 0x2e, 0x65,
+ 0x78, 0x74, 0x65, 0x6e, 0x64, 0x28, 0x5f, 0x2e, 0x70, 0x72, 0x6f, 0x74,
+ 0x6f, 0x74, 0x79, 0x70, 0x65, 0x2c, 0x20, 0x7b, 0x0a, 0x0a, 0x20, 0x20,
+ 0x20, 0x20, 0x2f, 0x2f, 0x20, 0x53, 0x74, 0x61, 0x72, 0x74, 0x20, 0x63,
+ 0x68, 0x61, 0x69, 0x6e, 0x69, 0x6e, 0x67, 0x20, 0x61, 0x20, 0x77, 0x72,
+ 0x61, 0x70, 0x70, 0x65, 0x64, 0x20, 0x55, 0x6e, 0x64, 0x65, 0x72, 0x73,
+ 0x63, 0x6f, 0x72, 0x65, 0x20, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x2e,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x3a, 0x20,
+ 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x29, 0x20, 0x7b,
+ 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x74, 0x68, 0x69, 0x73, 0x2e,
+ 0x5f, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x20, 0x3d, 0x20, 0x74, 0x72, 0x75,
+ 0x65, 0x3b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74,
+ 0x75, 0x72, 0x6e, 0x20, 0x74, 0x68, 0x69, 0x73, 0x3b, 0x0a, 0x20, 0x20,
+ 0x20, 0x20, 0x7d, 0x2c, 0x0a, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x2f, 0x2f,
+ 0x20, 0x45, 0x78, 0x74, 0x72, 0x61, 0x63, 0x74, 0x73, 0x20, 0x74, 0x68,
+ 0x65, 0x20, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x20, 0x66, 0x72, 0x6f,
+ 0x6d, 0x20, 0x61, 0x20, 0x77, 0x72, 0x61, 0x70, 0x70, 0x65, 0x64, 0x20,
+ 0x61, 0x6e, 0x64, 0x20, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x65, 0x64, 0x20,
+ 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x2e, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74,
+ 0x69, 0x6f, 0x6e, 0x28, 0x29, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20,
+ 0x20, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x74, 0x68, 0x69,
+ 0x73, 0x2e, 0x5f, 0x77, 0x72, 0x61, 0x70, 0x70, 0x65, 0x64, 0x3b, 0x0a,
+ 0x20, 0x20, 0x20, 0x20, 0x7d, 0x0a, 0x0a, 0x20, 0x20, 0x7d, 0x29, 0x3b,
+ 0x0a, 0x0a, 0x7d, 0x29, 0x2e, 0x63, 0x61, 0x6c, 0x6c, 0x28, 0x74, 0x68,
+ 0x69, 0x73, 0x29, 0x3b, 0x0a,
+ }
+}
+// Underscore.js 1.4.4
+// http://underscorejs.org
+// (c) 2009-2013 Jeremy Ashkenas, DocumentCloud Inc.
+// Underscore may be freely distributed under the MIT license.
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/underscore/testify b/Godeps/_workspace/src/github.com/robertkrimen/otto/underscore/testify
new file mode 100644
index 000000000..7f6e0f7c1
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/underscore/testify
@@ -0,0 +1,84 @@
+#!/usr/bin/env perl
+
+use strict;
+use warnings;
+
+my $underscore_test = shift @ARGV || "";
+if (!-d $underscore_test) {
+ print <<_END_;
+Usage:
+
+ testify ./underscore/test
+
+ # Should look something like:
+ arrays.js
+ chaining.js
+ collections.js
+ functions.js
+ index.html
+ objects.js
+ speed.js
+ utility.js
+ vendor
+
+_END_
+ if ($underscore_test) {
+ die "!: Not a directory: $underscore_test\n"
+ }
+ exit;
+}
+
+chdir $underscore_test or die "!: $!";
+
+my @js = <*.js>;
+
+for my $file (@js) {
+ open my $fh, '<', $file or die "!: $!";
+ my $tests = join "", <$fh>;
+ my @tests = $tests =~ m/
+ ^(\s{2}test\(.*?
+ ^\s{2}}\);)$
+ /mgxs;
+ close $fh;
+ next unless @tests;
+ print "$file: ", scalar(@tests), "\n";
+ my $underscore_name = "underscore_$file";
+ $underscore_name =~ s/.js$//;
+ my $go_file = "${underscore_name}_test.go";
+ $go_file =~ s/.js$/.go/;
+ open $fh, '>', $go_file or die "!: $!";
+
+ $fh->print(<<_END_);
+package otto
+
+import (
+ "testing"
+)
+
+_END_
+
+ my $count = 0;
+ for my $test (@tests) {
+ $test =~ s/`([^`]+)`/<$1>/g;
+ my ($name) = $test =~ m/^\s*test\(['"]([^'"]+)['"]/;
+ $fh->print(<<_END_);
+// $name
+func Test_${underscore_name}_$count(t *testing.T) {
+ tt(t, func(){
+ test := underscoreTest()
+
+ test(`
+$test
+ `)
+ })
+}
+
+_END_
+ $count++;
+ }
+}
+
+# test('#779 - delimeters are applied to unescaped text.', 1, function() {
+# var template = _.template('<<\nx\n>>', null, {evaluate: /<<(.*?)>>/g});
+# strictEqual(template(), '<<\nx\n>>');
+# });
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/underscore/underscore.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/underscore/underscore.go
new file mode 100644
index 000000000..714b8f3cf
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/underscore/underscore.go
@@ -0,0 +1,49 @@
+/*
+Package underscore contains the source for the JavaScript utility-belt library.
+
+ import (
+ _ "github.com/robertkrimen/otto/underscore"
+ )
+ // Every Otto runtime will now include underscore
+
+http://underscorejs.org
+
+https://github.com/documentcloud/underscore
+
+By importing this package, you'll automatically load underscore every time you create a new Otto runtime.
+
+To prevent this behavior, you can do the following:
+
+ import (
+ "github.com/robertkrimen/otto/underscore"
+ )
+
+ func init() {
+ underscore.Disable()
+ }
+
+*/
+package underscore
+
+import (
+ "github.com/robertkrimen/otto/registry"
+)
+
+var entry *registry.Entry = registry.Register(func() string {
+ return Source()
+})
+
+// Enable underscore runtime inclusion.
+func Enable() {
+ entry.Enable()
+}
+
+// Disable underscore runtime inclusion.
+func Disable() {
+ entry.Disable()
+}
+
+// Source returns the underscore source.
+func Source() string {
+ return string(underscore())
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/underscore_arrays_test.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/underscore_arrays_test.go
new file mode 100644
index 000000000..9d6297820
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/underscore_arrays_test.go
@@ -0,0 +1,344 @@
+package otto
+
+import (
+ "testing"
+)
+
+// first
+func Test_underscore_arrays_0(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("first", function() {
+ equal(_.first([1,2,3]), 1, 'can pull out the first element of an array');
+ equal(_([1, 2, 3]).first(), 1, 'can perform OO-style "first()"');
+ equal(_.first([1,2,3], 0).join(', '), "", 'can pass an index to first');
+ equal(_.first([1,2,3], 2).join(', '), '1, 2', 'can pass an index to first');
+ equal(_.first([1,2,3], 5).join(', '), '1, 2, 3', 'can pass an index to first');
+ var result = (function(){ return _.first(arguments); })(4, 3, 2, 1);
+ equal(result, 4, 'works on an arguments object.');
+ result = _.map([[1,2,3],[1,2,3]], _.first);
+ equal(result.join(','), '1,1', 'works well with _.map');
+ result = (function() { return _.take([1,2,3], 2); })();
+ equal(result.join(','), '1,2', 'aliased as take');
+
+ equal(_.first(null), undefined, 'handles nulls');
+ });
+ `)
+ })
+}
+
+// rest
+func Test_underscore_arrays_1(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("rest", function() {
+ var numbers = [1, 2, 3, 4];
+ equal(_.rest(numbers).join(", "), "2, 3, 4", 'working rest()');
+ equal(_.rest(numbers, 0).join(", "), "1, 2, 3, 4", 'working rest(0)');
+ equal(_.rest(numbers, 2).join(', '), '3, 4', 'rest can take an index');
+ var result = (function(){ return _(arguments).tail(); })(1, 2, 3, 4);
+ equal(result.join(', '), '2, 3, 4', 'aliased as tail and works on arguments object');
+ result = _.map([[1,2,3],[1,2,3]], _.rest);
+ equal(_.flatten(result).join(','), '2,3,2,3', 'works well with _.map');
+ result = (function(){ return _(arguments).drop(); })(1, 2, 3, 4);
+ equal(result.join(', '), '2, 3, 4', 'aliased as drop and works on arguments object');
+ });
+ `)
+ })
+}
+
+// initial
+func Test_underscore_arrays_2(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("initial", function() {
+ equal(_.initial([1,2,3,4,5]).join(", "), "1, 2, 3, 4", 'working initial()');
+ equal(_.initial([1,2,3,4],2).join(", "), "1, 2", 'initial can take an index');
+ var result = (function(){ return _(arguments).initial(); })(1, 2, 3, 4);
+ equal(result.join(", "), "1, 2, 3", 'initial works on arguments object');
+ result = _.map([[1,2,3],[1,2,3]], _.initial);
+ equal(_.flatten(result).join(','), '1,2,1,2', 'initial works with _.map');
+ });
+ `)
+ })
+}
+
+// last
+func Test_underscore_arrays_3(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("last", function() {
+ equal(_.last([1,2,3]), 3, 'can pull out the last element of an array');
+ equal(_.last([1,2,3], 0).join(', '), "", 'can pass an index to last');
+ equal(_.last([1,2,3], 2).join(', '), '2, 3', 'can pass an index to last');
+ equal(_.last([1,2,3], 5).join(', '), '1, 2, 3', 'can pass an index to last');
+ var result = (function(){ return _(arguments).last(); })(1, 2, 3, 4);
+ equal(result, 4, 'works on an arguments object');
+ result = _.map([[1,2,3],[1,2,3]], _.last);
+ equal(result.join(','), '3,3', 'works well with _.map');
+
+ equal(_.last(null), undefined, 'handles nulls');
+ });
+ `)
+ })
+}
+
+// compact
+func Test_underscore_arrays_4(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("compact", function() {
+ equal(_.compact([0, 1, false, 2, false, 3]).length, 3, 'can trim out all falsy values');
+ var result = (function(){ return _.compact(arguments).length; })(0, 1, false, 2, false, 3);
+ equal(result, 3, 'works on an arguments object');
+ });
+ `)
+ })
+}
+
+// flatten
+func Test_underscore_arrays_5(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("flatten", function() {
+ var list = [1, [2], [3, [[[4]]]]];
+ deepEqual(_.flatten(list), [1,2,3,4], 'can flatten nested arrays');
+ deepEqual(_.flatten(list, true), [1,2,3,[[[4]]]], 'can shallowly flatten nested arrays');
+ var result = (function(){ return _.flatten(arguments); })(1, [2], [3, [[[4]]]]);
+ deepEqual(result, [1,2,3,4], 'works on an arguments object');
+ });
+ `)
+ })
+}
+
+// without
+func Test_underscore_arrays_6(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("without", function() {
+ var list = [1, 2, 1, 0, 3, 1, 4];
+ equal(_.without(list, 0, 1).join(', '), '2, 3, 4', 'can remove all instances of an object');
+ var result = (function(){ return _.without(arguments, 0, 1); })(1, 2, 1, 0, 3, 1, 4);
+ equal(result.join(', '), '2, 3, 4', 'works on an arguments object');
+
+ var list = [{one : 1}, {two : 2}];
+ ok(_.without(list, {one : 1}).length == 2, 'uses real object identity for comparisons.');
+ ok(_.without(list, list[0]).length == 1, 'ditto.');
+ });
+ `)
+ })
+}
+
+// uniq
+func Test_underscore_arrays_7(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("uniq", function() {
+ var list = [1, 2, 1, 3, 1, 4];
+ equal(_.uniq(list).join(', '), '1, 2, 3, 4', 'can find the unique values of an unsorted array');
+
+ var list = [1, 1, 1, 2, 2, 3];
+ equal(_.uniq(list, true).join(', '), '1, 2, 3', 'can find the unique values of a sorted array faster');
+
+ var list = [{name:'moe'}, {name:'curly'}, {name:'larry'}, {name:'curly'}];
+ var iterator = function(value) { return value.name; };
+ equal(_.map(_.uniq(list, false, iterator), iterator).join(', '), 'moe, curly, larry', 'can find the unique values of an array using a custom iterator');
+
+ equal(_.map(_.uniq(list, iterator), iterator).join(', '), 'moe, curly, larry', 'can find the unique values of an array using a custom iterator without specifying whether array is sorted');
+
+ var iterator = function(value) { return value +1; };
+ var list = [1, 2, 2, 3, 4, 4];
+ equal(_.uniq(list, true, iterator).join(', '), '1, 2, 3, 4', 'iterator works with sorted array');
+
+ var result = (function(){ return _.uniq(arguments); })(1, 2, 1, 3, 1, 4);
+ equal(result.join(', '), '1, 2, 3, 4', 'works on an arguments object');
+ });
+ `)
+ })
+}
+
+// intersection
+func Test_underscore_arrays_8(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("intersection", function() {
+ var stooges = ['moe', 'curly', 'larry'], leaders = ['moe', 'groucho'];
+ equal(_.intersection(stooges, leaders).join(''), 'moe', 'can take the set intersection of two arrays');
+ equal(_(stooges).intersection(leaders).join(''), 'moe', 'can perform an OO-style intersection');
+ var result = (function(){ return _.intersection(arguments, leaders); })('moe', 'curly', 'larry');
+ equal(result.join(''), 'moe', 'works on an arguments object');
+ });
+ `)
+ })
+}
+
+// union
+func Test_underscore_arrays_9(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("union", function() {
+ var result = _.union([1, 2, 3], [2, 30, 1], [1, 40]);
+ equal(result.join(' '), '1 2 3 30 40', 'takes the union of a list of arrays');
+
+ var result = _.union([1, 2, 3], [2, 30, 1], [1, 40, [1]]);
+ equal(result.join(' '), '1 2 3 30 40 1', 'takes the union of a list of nested arrays');
+ });
+ `)
+ })
+}
+
+// difference
+func Test_underscore_arrays_10(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("difference", function() {
+ var result = _.difference([1, 2, 3], [2, 30, 40]);
+ equal(result.join(' '), '1 3', 'takes the difference of two arrays');
+
+ var result = _.difference([1, 2, 3, 4], [2, 30, 40], [1, 11, 111]);
+ equal(result.join(' '), '3 4', 'takes the difference of three arrays');
+ });
+ `)
+ })
+}
+
+// zip
+func Test_underscore_arrays_11(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test('zip', function() {
+ var names = ['moe', 'larry', 'curly'], ages = [30, 40, 50], leaders = [true];
+ var stooges = _.zip(names, ages, leaders);
+ equal(String(stooges), 'moe,30,true,larry,40,,curly,50,', 'zipped together arrays of different lengths');
+ });
+ `)
+ })
+}
+
+// object
+func Test_underscore_arrays_12(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test('object', function() {
+ var result = _.object(['moe', 'larry', 'curly'], [30, 40, 50]);
+ var shouldBe = {moe: 30, larry: 40, curly: 50};
+ ok(_.isEqual(result, shouldBe), 'two arrays zipped together into an object');
+
+ result = _.object([['one', 1], ['two', 2], ['three', 3]]);
+ shouldBe = {one: 1, two: 2, three: 3};
+ ok(_.isEqual(result, shouldBe), 'an array of pairs zipped together into an object');
+
+ var stooges = {moe: 30, larry: 40, curly: 50};
+ ok(_.isEqual(_.object(_.pairs(stooges)), stooges), 'an object converted to pairs and back to an object');
+
+ ok(_.isEqual(_.object(null), {}), 'handles nulls');
+ });
+ `)
+ })
+}
+
+// indexOf
+func Test_underscore_arrays_13(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("indexOf", function() {
+ var numbers = [1, 2, 3];
+ numbers.indexOf = null;
+ equal(_.indexOf(numbers, 2), 1, 'can compute indexOf, even without the native function');
+ var result = (function(){ return _.indexOf(arguments, 2); })(1, 2, 3);
+ equal(result, 1, 'works on an arguments object');
+ equal(_.indexOf(null, 2), -1, 'handles nulls properly');
+
+ var numbers = [10, 20, 30, 40, 50], num = 35;
+ var index = _.indexOf(numbers, num, true);
+ equal(index, -1, '35 is not in the list');
+
+ numbers = [10, 20, 30, 40, 50]; num = 40;
+ index = _.indexOf(numbers, num, true);
+ equal(index, 3, '40 is in the list');
+
+ numbers = [1, 40, 40, 40, 40, 40, 40, 40, 50, 60, 70]; num = 40;
+ index = _.indexOf(numbers, num, true);
+ equal(index, 1, '40 is in the list');
+
+ numbers = [1, 2, 3, 1, 2, 3, 1, 2, 3];
+ index = _.indexOf(numbers, 2, 5);
+ equal(index, 7, 'supports the fromIndex argument');
+ });
+ `)
+ })
+}
+
+// lastIndexOf
+func Test_underscore_arrays_14(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("lastIndexOf", function() {
+ var numbers = [1, 0, 1];
+ equal(_.lastIndexOf(numbers, 1), 2);
+
+ numbers = [1, 0, 1, 0, 0, 1, 0, 0, 0];
+ numbers.lastIndexOf = null;
+ equal(_.lastIndexOf(numbers, 1), 5, 'can compute lastIndexOf, even without the native function');
+ equal(_.lastIndexOf(numbers, 0), 8, 'lastIndexOf the other element');
+ var result = (function(){ return _.lastIndexOf(arguments, 1); })(1, 0, 1, 0, 0, 1, 0, 0, 0);
+ equal(result, 5, 'works on an arguments object');
+ equal(_.indexOf(null, 2), -1, 'handles nulls properly');
+
+ numbers = [1, 2, 3, 1, 2, 3, 1, 2, 3];
+ var index = _.lastIndexOf(numbers, 2, 2);
+ equal(index, 1, 'supports the fromIndex argument');
+ });
+ `)
+ })
+}
+
+// range
+func Test_underscore_arrays_15(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("range", function() {
+ equal(_.range(0).join(''), '', 'range with 0 as a first argument generates an empty array');
+ equal(_.range(4).join(' '), '0 1 2 3', 'range with a single positive argument generates an array of elements 0,1,2,...,n-1');
+ equal(_.range(5, 8).join(' '), '5 6 7', 'range with two arguments a &amp; b, a&lt;b generates an array of elements a,a+1,a+2,...,b-2,b-1');
+ equal(_.range(8, 5).join(''), '', 'range with two arguments a &amp; b, b&lt;a generates an empty array');
+ equal(_.range(3, 10, 3).join(' '), '3 6 9', 'range with three arguments a &amp; b &amp; c, c &lt; b-a, a &lt; b generates an array of elements a,a+c,a+2c,...,b - (multiplier of a) &lt; c');
+ equal(_.range(3, 10, 15).join(''), '3', 'range with three arguments a &amp; b &amp; c, c &gt; b-a, a &lt; b generates an array with a single element, equal to a');
+ equal(_.range(12, 7, -2).join(' '), '12 10 8', 'range with three arguments a &amp; b &amp; c, a &gt; b, c &lt; 0 generates an array of elements a,a-c,a-2c and ends with the number not less than b');
+ equal(_.range(0, -10, -1).join(' '), '0 -1 -2 -3 -4 -5 -6 -7 -8 -9', 'final example in the Python docs');
+ });
+ `)
+ })
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/underscore_chaining_test.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/underscore_chaining_test.go
new file mode 100644
index 000000000..accf04fdc
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/underscore_chaining_test.go
@@ -0,0 +1,95 @@
+package otto
+
+import (
+ "testing"
+)
+
+// map/flatten/reduce
+func Test_underscore_chaining_0(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("map/flatten/reduce", function() {
+ var lyrics = [
+ "I'm a lumberjack and I'm okay",
+ "I sleep all night and I work all day",
+ "He's a lumberjack and he's okay",
+ "He sleeps all night and he works all day"
+ ];
+ var counts = _(lyrics).chain()
+ .map(function(line) { return line.split(''); })
+ .flatten()
+ .reduce(function(hash, l) {
+ hash[l] = hash[l] || 0;
+ hash[l]++;
+ return hash;
+ }, {}).value();
+ ok(counts['a'] == 16 && counts['e'] == 10, 'counted all the letters in the song');
+ });
+ `)
+ })
+}
+
+// select/reject/sortBy
+func Test_underscore_chaining_1(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("select/reject/sortBy", function() {
+ var numbers = [1,2,3,4,5,6,7,8,9,10];
+ numbers = _(numbers).chain().select(function(n) {
+ return n % 2 == 0;
+ }).reject(function(n) {
+ return n % 4 == 0;
+ }).sortBy(function(n) {
+ return -n;
+ }).value();
+ equal(numbers.join(', '), "10, 6, 2", "filtered and reversed the numbers");
+ });
+ `)
+ })
+}
+
+// select/reject/sortBy in functional style
+func Test_underscore_chaining_2(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("select/reject/sortBy in functional style", function() {
+ var numbers = [1,2,3,4,5,6,7,8,9,10];
+ numbers = _.chain(numbers).select(function(n) {
+ return n % 2 == 0;
+ }).reject(function(n) {
+ return n % 4 == 0;
+ }).sortBy(function(n) {
+ return -n;
+ }).value();
+ equal(numbers.join(', '), "10, 6, 2", "filtered and reversed the numbers");
+ });
+ `)
+ })
+}
+
+// reverse/concat/unshift/pop/map
+func Test_underscore_chaining_3(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("reverse/concat/unshift/pop/map", function() {
+ var numbers = [1,2,3,4,5];
+ numbers = _(numbers).chain()
+ .reverse()
+ .concat([5, 5, 5])
+ .unshift(17)
+ .pop()
+ .map(function(n){ return n * 2; })
+ .value();
+ equal(numbers.join(', '), "34, 10, 8, 6, 4, 2, 10, 10", 'can chain together array functions.');
+ });
+ `)
+ })
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/underscore_collections_test.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/underscore_collections_test.go
new file mode 100644
index 000000000..9afc2a2b2
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/underscore_collections_test.go
@@ -0,0 +1,698 @@
+package otto
+
+import (
+ "testing"
+)
+
+// each
+func Test_underscore_collections_0(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("each", function() {
+ _.each([1, 2, 3], function(num, i) {
+ equal(num, i + 1, 'each iterators provide value and iteration count');
+ });
+
+ var answers = [];
+ _.each([1, 2, 3], function(num){ answers.push(num * this.multiplier);}, {multiplier : 5});
+ equal(answers.join(', '), '5, 10, 15', 'context object property accessed');
+
+ answers = [];
+ _.forEach([1, 2, 3], function(num){ answers.push(num); });
+ equal(answers.join(', '), '1, 2, 3', 'aliased as "forEach"');
+
+ answers = [];
+ var obj = {one : 1, two : 2, three : 3};
+ obj.constructor.prototype.four = 4;
+ _.each(obj, function(value, key){ answers.push(key); });
+ equal(answers.join(", "), 'one, two, three', 'iterating over objects works, and ignores the object prototype.');
+ delete obj.constructor.prototype.four;
+
+ var answer = null;
+ _.each([1, 2, 3], function(num, index, arr){ if (_.include(arr, num)) answer = true; });
+ ok(answer, 'can reference the original collection from inside the iterator');
+
+ answers = 0;
+ _.each(null, function(){ ++answers; });
+ equal(answers, 0, 'handles a null properly');
+ });
+ `)
+ })
+}
+
+// map
+func Test_underscore_collections_1(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test('map', function() {
+ var doubled = _.map([1, 2, 3], function(num){ return num * 2; });
+ equal(doubled.join(', '), '2, 4, 6', 'doubled numbers');
+
+ doubled = _.collect([1, 2, 3], function(num){ return num * 2; });
+ equal(doubled.join(', '), '2, 4, 6', 'aliased as "collect"');
+
+ var tripled = _.map([1, 2, 3], function(num){ return num * this.multiplier; }, {multiplier : 3});
+ equal(tripled.join(', '), '3, 6, 9', 'tripled numbers with context');
+
+ var doubled = _([1, 2, 3]).map(function(num){ return num * 2; });
+ equal(doubled.join(', '), '2, 4, 6', 'OO-style doubled numbers');
+
+ // TEST: ReferenceError: document is not defined
+ return;
+
+ if (document.querySelectorAll) {
+ var ids = _.map(document.querySelectorAll('#map-test *'), function(n){ return n.id; });
+ deepEqual(ids, ['id1', 'id2'], 'Can use collection methods on NodeLists.');
+ }
+
+ var ids = _.map($('#map-test').children(), function(n){ return n.id; });
+ deepEqual(ids, ['id1', 'id2'], 'Can use collection methods on jQuery Array-likes.');
+
+ var ids = _.map(document.images, function(n){ return n.id; });
+ ok(ids[0] == 'chart_image', 'can use collection methods on HTMLCollections');
+
+ var ifnull = _.map(null, function(){});
+ ok(_.isArray(ifnull) && ifnull.length === 0, 'handles a null properly');
+ });
+ `)
+ })
+}
+
+// reduce
+func Test_underscore_collections_2(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test('reduce', function() {
+ var sum = _.reduce([1, 2, 3], function(sum, num){ return sum + num; }, 0);
+ equal(sum, 6, 'can sum up an array');
+
+ var context = {multiplier : 3};
+ sum = _.reduce([1, 2, 3], function(sum, num){ return sum + num * this.multiplier; }, 0, context);
+ equal(sum, 18, 'can reduce with a context object');
+
+ sum = _.inject([1, 2, 3], function(sum, num){ return sum + num; }, 0);
+ equal(sum, 6, 'aliased as "inject"');
+
+ sum = _([1, 2, 3]).reduce(function(sum, num){ return sum + num; }, 0);
+ equal(sum, 6, 'OO-style reduce');
+
+ var sum = _.reduce([1, 2, 3], function(sum, num){ return sum + num; });
+ equal(sum, 6, 'default initial value');
+
+ var ifnull;
+ try {
+ _.reduce(null, function(){});
+ } catch (ex) {
+ ifnull = ex;
+ }
+ ok(ifnull instanceof TypeError, 'handles a null (without inital value) properly');
+
+ ok(_.reduce(null, function(){}, 138) === 138, 'handles a null (with initial value) properly');
+ equal(_.reduce([], function(){}, undefined), undefined, 'undefined can be passed as a special case');
+ raises(function() { _.reduce([], function(){}); }, TypeError, 'throws an error for empty arrays with no initial value');
+ });
+ `)
+ })
+}
+
+// reduceRight
+func Test_underscore_collections_3(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test('reduceRight', function() {
+ var list = _.reduceRight(["foo", "bar", "baz"], function(memo, str){ return memo + str; }, '');
+ equal(list, 'bazbarfoo', 'can perform right folds');
+
+ var list = _.foldr(["foo", "bar", "baz"], function(memo, str){ return memo + str; }, '');
+ equal(list, 'bazbarfoo', 'aliased as "foldr"');
+
+ var list = _.foldr(["foo", "bar", "baz"], function(memo, str){ return memo + str; });
+ equal(list, 'bazbarfoo', 'default initial value');
+
+ var ifnull;
+ try {
+ _.reduceRight(null, function(){});
+ } catch (ex) {
+ ifnull = ex;
+ }
+ ok(ifnull instanceof TypeError, 'handles a null (without inital value) properly');
+
+ var sum = _.reduceRight({a: 1, b: 2, c: 3}, function(sum, num){ return sum + num; });
+ equal(sum, 6, 'default initial value on object');
+
+ ok(_.reduceRight(null, function(){}, 138) === 138, 'handles a null (with initial value) properly');
+
+ equal(_.reduceRight([], function(){}, undefined), undefined, 'undefined can be passed as a special case');
+ raises(function() { _.reduceRight([], function(){}); }, TypeError, 'throws an error for empty arrays with no initial value');
+
+ // Assert that the correct arguments are being passed.
+
+ var args,
+ memo = {},
+ object = {a: 1, b: 2},
+ lastKey = _.keys(object).pop();
+
+ var expected = lastKey == 'a'
+ ? [memo, 1, 'a', object]
+ : [memo, 2, 'b', object];
+
+ _.reduceRight(object, function() {
+ args || (args = _.toArray(arguments));
+ }, memo);
+
+ deepEqual(args, expected);
+
+ // And again, with numeric keys.
+
+ object = {'2': 'a', '1': 'b'};
+ lastKey = _.keys(object).pop();
+ args = null;
+
+ expected = lastKey == '2'
+ ? [memo, 'a', '2', object]
+ : [memo, 'b', '1', object];
+
+ _.reduceRight(object, function() {
+ args || (args = _.toArray(arguments));
+ }, memo);
+
+ deepEqual(args, expected);
+ });
+ `)
+ })
+}
+
+// find
+func Test_underscore_collections_4(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test('find', function() {
+ var array = [1, 2, 3, 4];
+ strictEqual(_.find(array, function(n) { return n > 2; }), 3, 'should return first found <value>');
+ strictEqual(_.find(array, function() { return false; }), void 0, 'should return <undefined> if <value> is not found');
+ });
+ `)
+ })
+}
+
+// detect
+func Test_underscore_collections_5(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test('detect', function() {
+ var result = _.detect([1, 2, 3], function(num){ return num * 2 == 4; });
+ equal(result, 2, 'found the first "2" and broke the loop');
+ });
+ `)
+ })
+}
+
+// select
+func Test_underscore_collections_6(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test('select', function() {
+ var evens = _.select([1, 2, 3, 4, 5, 6], function(num){ return num % 2 == 0; });
+ equal(evens.join(', '), '2, 4, 6', 'selected each even number');
+
+ evens = _.filter([1, 2, 3, 4, 5, 6], function(num){ return num % 2 == 0; });
+ equal(evens.join(', '), '2, 4, 6', 'aliased as "filter"');
+ });
+ `)
+ })
+}
+
+// reject
+func Test_underscore_collections_7(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test('reject', function() {
+ var odds = _.reject([1, 2, 3, 4, 5, 6], function(num){ return num % 2 == 0; });
+ equal(odds.join(', '), '1, 3, 5', 'rejected each even number');
+
+ var context = "obj";
+
+ var evens = _.reject([1, 2, 3, 4, 5, 6], function(num){
+ equal(context, "obj");
+ return num % 2 != 0;
+ }, context);
+ equal(evens.join(', '), '2, 4, 6', 'rejected each odd number');
+ });
+ `)
+ })
+}
+
+// all
+func Test_underscore_collections_8(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test('all', function() {
+ ok(_.all([], _.identity), 'the empty set');
+ ok(_.all([true, true, true], _.identity), 'all true values');
+ ok(!_.all([true, false, true], _.identity), 'one false value');
+ ok(_.all([0, 10, 28], function(num){ return num % 2 == 0; }), 'even numbers');
+ ok(!_.all([0, 11, 28], function(num){ return num % 2 == 0; }), 'an odd number');
+ ok(_.all([1], _.identity) === true, 'cast to boolean - true');
+ ok(_.all([0], _.identity) === false, 'cast to boolean - false');
+ ok(_.every([true, true, true], _.identity), 'aliased as "every"');
+ ok(!_.all([undefined, undefined, undefined], _.identity), 'works with arrays of undefined');
+ });
+ `)
+ })
+}
+
+// any
+func Test_underscore_collections_9(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test('any', function() {
+ var nativeSome = Array.prototype.some;
+ Array.prototype.some = null;
+ ok(!_.any([]), 'the empty set');
+ ok(!_.any([false, false, false]), 'all false values');
+ ok(_.any([false, false, true]), 'one true value');
+ ok(_.any([null, 0, 'yes', false]), 'a string');
+ ok(!_.any([null, 0, '', false]), 'falsy values');
+ ok(!_.any([1, 11, 29], function(num){ return num % 2 == 0; }), 'all odd numbers');
+ ok(_.any([1, 10, 29], function(num){ return num % 2 == 0; }), 'an even number');
+ ok(_.any([1], _.identity) === true, 'cast to boolean - true');
+ ok(_.any([0], _.identity) === false, 'cast to boolean - false');
+ ok(_.some([false, false, true]), 'aliased as "some"');
+ Array.prototype.some = nativeSome;
+ });
+ `)
+ })
+}
+
+// include
+func Test_underscore_collections_10(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test('include', function() {
+ ok(_.include([1,2,3], 2), 'two is in the array');
+ ok(!_.include([1,3,9], 2), 'two is not in the array');
+ ok(_.contains({moe:1, larry:3, curly:9}, 3) === true, '_.include on objects checks their values');
+ ok(_([1,2,3]).include(2), 'OO-style include');
+ });
+ `)
+ })
+}
+
+// invoke
+func Test_underscore_collections_11(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test('invoke', function() {
+ var list = [[5, 1, 7], [3, 2, 1]];
+ var result = _.invoke(list, 'sort');
+ equal(result[0].join(', '), '1, 5, 7', 'first array sorted');
+ equal(result[1].join(', '), '1, 2, 3', 'second array sorted');
+ });
+ `)
+ })
+}
+
+// invoke w/ function reference
+func Test_underscore_collections_12(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test('invoke w/ function reference', function() {
+ var list = [[5, 1, 7], [3, 2, 1]];
+ var result = _.invoke(list, Array.prototype.sort);
+ equal(result[0].join(', '), '1, 5, 7', 'first array sorted');
+ equal(result[1].join(', '), '1, 2, 3', 'second array sorted');
+ });
+ `)
+ })
+}
+
+// invoke when strings have a call method
+func Test_underscore_collections_13(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test('invoke when strings have a call method', function() {
+ String.prototype.call = function() {
+ return 42;
+ };
+ var list = [[5, 1, 7], [3, 2, 1]];
+ var s = "foo";
+ equal(s.call(), 42, "call function exists");
+ var result = _.invoke(list, 'sort');
+ equal(result[0].join(', '), '1, 5, 7', 'first array sorted');
+ equal(result[1].join(', '), '1, 2, 3', 'second array sorted');
+ delete String.prototype.call;
+ equal(s.call, undefined, "call function removed");
+ });
+ `)
+ })
+}
+
+// pluck
+func Test_underscore_collections_14(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test('pluck', function() {
+ var people = [{name : 'moe', age : 30}, {name : 'curly', age : 50}];
+ equal(_.pluck(people, 'name').join(', '), 'moe, curly', 'pulls names out of objects');
+ });
+ `)
+ })
+}
+
+// where
+func Test_underscore_collections_15(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test('where', function() {
+ var list = [{a: 1, b: 2}, {a: 2, b: 2}, {a: 1, b: 3}, {a: 1, b: 4}];
+ var result = _.where(list, {a: 1});
+ equal(result.length, 3);
+ equal(result[result.length - 1].b, 4);
+ result = _.where(list, {b: 2});
+ equal(result.length, 2);
+ equal(result[0].a, 1);
+ });
+ `)
+ })
+}
+
+// findWhere
+func Test_underscore_collections_16(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test('findWhere', function() {
+ var list = [{a: 1, b: 2}, {a: 2, b: 2}, {a: 1, b: 3}, {a: 1, b: 4}, {a: 2, b: 4}];
+ var result = _.findWhere(list, {a: 1});
+ deepEqual(result, {a: 1, b: 2});
+ result = _.findWhere(list, {b: 4});
+ deepEqual(result, {a: 1, b: 4});
+ });
+ `)
+ })
+}
+
+// max
+func Test_underscore_collections_17(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test('max', function() {
+ equal(3, _.max([1, 2, 3]), 'can perform a regular Math.max');
+
+ var neg = _.max([1, 2, 3], function(num){ return -num; });
+ equal(neg, 1, 'can perform a computation-based max');
+
+ equal(-Infinity, _.max({}), 'Maximum value of an empty object');
+ equal(-Infinity, _.max([]), 'Maximum value of an empty array');
+ equal(_.max({'a': 'a'}), -Infinity, 'Maximum value of a non-numeric collection');
+
+ // TEST: Takes too long
+ return;
+
+ equal(299999, _.max(_.range(1,300000)), "Maximum value of a too-big array");
+ });
+ `)
+ })
+}
+
+// min
+func Test_underscore_collections_18(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test('min', function() {
+ equal(1, _.min([1, 2, 3]), 'can perform a regular Math.min');
+
+ var neg = _.min([1, 2, 3], function(num){ return -num; });
+ equal(neg, 3, 'can perform a computation-based min');
+
+ equal(Infinity, _.min({}), 'Minimum value of an empty object');
+ equal(Infinity, _.min([]), 'Minimum value of an empty array');
+ equal(_.min({'a': 'a'}), Infinity, 'Minimum value of a non-numeric collection');
+
+ var now = new Date(9999999999);
+ var then = new Date(0);
+ equal(_.min([now, then]), then);
+
+ // TEST: Takes too long
+ return;
+
+ equal(1, _.min(_.range(1,300000)), "Minimum value of a too-big array");
+ });
+ `)
+ })
+}
+
+// sortBy
+func Test_underscore_collections_19(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test('sortBy', function() {
+ var people = [{name : 'curly', age : 50}, {name : 'moe', age : 30}];
+ people = _.sortBy(people, function(person){ return person.age; });
+ equal(_.pluck(people, 'name').join(', '), 'moe, curly', 'stooges sorted by age');
+
+ var list = [undefined, 4, 1, undefined, 3, 2];
+ equal(_.sortBy(list, _.identity).join(','), '1,2,3,4,,', 'sortBy with undefined values');
+
+ var list = ["one", "two", "three", "four", "five"];
+ var sorted = _.sortBy(list, 'length');
+ equal(sorted.join(' '), 'one two four five three', 'sorted by length');
+
+ function Pair(x, y) {
+ this.x = x;
+ this.y = y;
+ }
+
+ var collection = [
+ new Pair(1, 1), new Pair(1, 2),
+ new Pair(1, 3), new Pair(1, 4),
+ new Pair(1, 5), new Pair(1, 6),
+ new Pair(2, 1), new Pair(2, 2),
+ new Pair(2, 3), new Pair(2, 4),
+ new Pair(2, 5), new Pair(2, 6),
+ new Pair(undefined, 1), new Pair(undefined, 2),
+ new Pair(undefined, 3), new Pair(undefined, 4),
+ new Pair(undefined, 5), new Pair(undefined, 6)
+ ];
+
+ var actual = _.sortBy(collection, function(pair) {
+ return pair.x;
+ });
+
+ deepEqual(actual, collection, 'sortBy should be stable');
+ });
+ `)
+ })
+}
+
+// groupBy
+func Test_underscore_collections_20(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test('groupBy', function() {
+ var parity = _.groupBy([1, 2, 3, 4, 5, 6], function(num){ return num % 2; });
+ ok('0' in parity && '1' in parity, 'created a group for each value');
+ equal(parity[0].join(', '), '2, 4, 6', 'put each even number in the right group');
+
+ var list = ["one", "two", "three", "four", "five", "six", "seven", "eight", "nine", "ten"];
+ var grouped = _.groupBy(list, 'length');
+ equal(grouped['3'].join(' '), 'one two six ten');
+ equal(grouped['4'].join(' '), 'four five nine');
+ equal(grouped['5'].join(' '), 'three seven eight');
+
+ var context = {};
+ _.groupBy([{}], function(){ ok(this === context); }, context);
+
+ grouped = _.groupBy([4.2, 6.1, 6.4], function(num) {
+ return Math.floor(num) > 4 ? 'hasOwnProperty' : 'constructor';
+ });
+ equal(grouped.constructor.length, 1);
+ equal(grouped.hasOwnProperty.length, 2);
+
+ var array = [{}];
+ _.groupBy(array, function(value, index, obj){ ok(obj === array); });
+
+ var array = [1, 2, 1, 2, 3];
+ var grouped = _.groupBy(array);
+ equal(grouped['1'].length, 2);
+ equal(grouped['3'].length, 1);
+ });
+ `)
+ })
+}
+
+// countBy
+func Test_underscore_collections_21(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test('countBy', function() {
+ var parity = _.countBy([1, 2, 3, 4, 5], function(num){ return num % 2 == 0; });
+ equal(parity['true'], 2);
+ equal(parity['false'], 3);
+
+ var list = ["one", "two", "three", "four", "five", "six", "seven", "eight", "nine", "ten"];
+ var grouped = _.countBy(list, 'length');
+ equal(grouped['3'], 4);
+ equal(grouped['4'], 3);
+ equal(grouped['5'], 3);
+
+ var context = {};
+ _.countBy([{}], function(){ ok(this === context); }, context);
+
+ grouped = _.countBy([4.2, 6.1, 6.4], function(num) {
+ return Math.floor(num) > 4 ? 'hasOwnProperty' : 'constructor';
+ });
+ equal(grouped.constructor, 1);
+ equal(grouped.hasOwnProperty, 2);
+
+ var array = [{}];
+ _.countBy(array, function(value, index, obj){ ok(obj === array); });
+
+ var array = [1, 2, 1, 2, 3];
+ var grouped = _.countBy(array);
+ equal(grouped['1'], 2);
+ equal(grouped['3'], 1);
+ });
+ `)
+ })
+}
+
+// sortedIndex
+func Test_underscore_collections_22(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test('sortedIndex', function() {
+ var numbers = [10, 20, 30, 40, 50], num = 35;
+ var indexForNum = _.sortedIndex(numbers, num);
+ equal(indexForNum, 3, '35 should be inserted at index 3');
+
+ var indexFor30 = _.sortedIndex(numbers, 30);
+ equal(indexFor30, 2, '30 should be inserted at index 2');
+
+ var objects = [{x: 10}, {x: 20}, {x: 30}, {x: 40}];
+ var iterator = function(obj){ return obj.x; };
+ strictEqual(_.sortedIndex(objects, {x: 25}, iterator), 2);
+ strictEqual(_.sortedIndex(objects, {x: 35}, 'x'), 3);
+
+ var context = {1: 2, 2: 3, 3: 4};
+ iterator = function(obj){ return this[obj]; };
+ strictEqual(_.sortedIndex([1, 3], 2, iterator, context), 1);
+ });
+ `)
+ })
+}
+
+// shuffle
+func Test_underscore_collections_23(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test('shuffle', function() {
+ var numbers = _.range(10);
+ var shuffled = _.shuffle(numbers).sort();
+ notStrictEqual(numbers, shuffled, 'original object is unmodified');
+ equal(shuffled.join(','), numbers.join(','), 'contains the same members before and after shuffle');
+ });
+ `)
+ })
+}
+
+// toArray
+func Test_underscore_collections_24(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test('toArray', function() {
+ ok(!_.isArray(arguments), 'arguments object is not an array');
+ ok(_.isArray(_.toArray(arguments)), 'arguments object converted into array');
+ var a = [1,2,3];
+ ok(_.toArray(a) !== a, 'array is cloned');
+ equal(_.toArray(a).join(', '), '1, 2, 3', 'cloned array contains same elements');
+
+ var numbers = _.toArray({one : 1, two : 2, three : 3});
+ equal(numbers.join(', '), '1, 2, 3', 'object flattened into array');
+
+ // TEST: ReferenceError: document is not defined
+ return;
+
+ // test in IE < 9
+ try {
+ var actual = _.toArray(document.childNodes);
+ } catch(ex) { }
+
+ ok(_.isArray(actual), 'should not throw converting a node list');
+ });
+ `)
+ })
+}
+
+// size
+func Test_underscore_collections_25(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test('size', function() {
+ equal(_.size({one : 1, two : 2, three : 3}), 3, 'can compute the size of an object');
+ equal(_.size([1, 2, 3]), 3, 'can compute the size of an array');
+
+ var func = function() {
+ return _.size(arguments);
+ };
+
+ equal(func(1, 2, 3, 4), 4, 'can test the size of the arguments object');
+
+ equal(_.size('hello'), 5, 'can compute the size of a string');
+
+ equal(_.size(null), 0, 'handles nulls');
+ });
+ `)
+ })
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/underscore_functions_test.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/underscore_functions_test.go
new file mode 100644
index 000000000..be59e16b3
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/underscore_functions_test.go
@@ -0,0 +1,208 @@
+package otto
+
+import (
+ "testing"
+)
+
+// bind
+func Test_underscore_functions_0(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("bind", function() {
+ var context = {name : 'moe'};
+ var func = function(arg) { return "name: " + (this.name || arg); };
+ var bound = _.bind(func, context);
+ equal(bound(), 'name: moe', 'can bind a function to a context');
+
+ bound = _(func).bind(context);
+ equal(bound(), 'name: moe', 'can do OO-style binding');
+
+ bound = _.bind(func, null, 'curly');
+ equal(bound(), 'name: curly', 'can bind without specifying a context');
+
+ func = function(salutation, name) { return salutation + ': ' + name; };
+ func = _.bind(func, this, 'hello');
+ equal(func('moe'), 'hello: moe', 'the function was partially applied in advance');
+
+ func = _.bind(func, this, 'curly');
+ equal(func(), 'hello: curly', 'the function was completely applied in advance');
+
+ func = function(salutation, firstname, lastname) { return salutation + ': ' + firstname + ' ' + lastname; };
+ func = _.bind(func, this, 'hello', 'moe', 'curly');
+ equal(func(), 'hello: moe curly', 'the function was partially applied in advance and can accept multiple arguments');
+
+ func = function(context, message) { equal(this, context, message); };
+ _.bind(func, 0, 0, 'can bind a function to <0>')();
+ _.bind(func, '', '', 'can bind a function to an empty string')();
+ _.bind(func, false, false, 'can bind a function to <false>')();
+
+ // These tests are only meaningful when using a browser without a native bind function
+ // To test this with a modern browser, set underscore's nativeBind to undefined
+ var F = function () { return this; };
+ var Boundf = _.bind(F, {hello: "moe curly"});
+ equal(Boundf().hello, "moe curly", "When called without the new operator, it's OK to be bound to the context");
+ });
+ `)
+ })
+}
+
+// partial
+func Test_underscore_functions_1(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("partial", function() {
+ var obj = {name: 'moe'};
+ var func = function() { return this.name + ' ' + _.toArray(arguments).join(' '); };
+
+ obj.func = _.partial(func, 'a', 'b');
+ equal(obj.func('c', 'd'), 'moe a b c d', 'can partially apply');
+ });
+ `)
+ })
+}
+
+// bindAll
+func Test_underscore_functions_2(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("bindAll", function() {
+ var curly = {name : 'curly'}, moe = {
+ name : 'moe',
+ getName : function() { return 'name: ' + this.name; },
+ sayHi : function() { return 'hi: ' + this.name; }
+ };
+ curly.getName = moe.getName;
+ _.bindAll(moe, 'getName', 'sayHi');
+ curly.sayHi = moe.sayHi;
+ equal(curly.getName(), 'name: curly', 'unbound function is bound to current object');
+ equal(curly.sayHi(), 'hi: moe', 'bound function is still bound to original object');
+
+ curly = {name : 'curly'};
+ moe = {
+ name : 'moe',
+ getName : function() { return 'name: ' + this.name; },
+ sayHi : function() { return 'hi: ' + this.name; }
+ };
+ _.bindAll(moe);
+ curly.sayHi = moe.sayHi;
+ equal(curly.sayHi(), 'hi: moe', 'calling bindAll with no arguments binds all functions to the object');
+ });
+ `)
+ })
+}
+
+// memoize
+func Test_underscore_functions_3(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("memoize", function() {
+ var fib = function(n) {
+ return n < 2 ? n : fib(n - 1) + fib(n - 2);
+ };
+ var fastFib = _.memoize(fib);
+ equal(fib(10), 55, 'a memoized version of fibonacci produces identical results');
+ equal(fastFib(10), 55, 'a memoized version of fibonacci produces identical results');
+
+ var o = function(str) {
+ return str;
+ };
+ var fastO = _.memoize(o);
+ equal(o('toString'), 'toString', 'checks hasOwnProperty');
+ equal(fastO('toString'), 'toString', 'checks hasOwnProperty');
+ });
+ `)
+ })
+}
+
+// once
+func Test_underscore_functions_4(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("once", function() {
+ var num = 0;
+ var increment = _.once(function(){ num++; });
+ increment();
+ increment();
+ equal(num, 1);
+ });
+ `)
+ })
+}
+
+// wrap
+func Test_underscore_functions_5(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("wrap", function() {
+ var greet = function(name){ return "hi: " + name; };
+ var backwards = _.wrap(greet, function(func, name){ return func(name) + ' ' + name.split('').reverse().join(''); });
+ equal(backwards('moe'), 'hi: moe eom', 'wrapped the saluation function');
+
+ var inner = function(){ return "Hello "; };
+ var obj = {name : "Moe"};
+ obj.hi = _.wrap(inner, function(fn){ return fn() + this.name; });
+ equal(obj.hi(), "Hello Moe");
+
+ var noop = function(){};
+ var wrapped = _.wrap(noop, function(fn){ return Array.prototype.slice.call(arguments, 0); });
+ var ret = wrapped(['whats', 'your'], 'vector', 'victor');
+ deepEqual(ret, [noop, ['whats', 'your'], 'vector', 'victor']);
+ });
+ `)
+ })
+}
+
+// compose
+func Test_underscore_functions_6(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("compose", function() {
+ var greet = function(name){ return "hi: " + name; };
+ var exclaim = function(sentence){ return sentence + '!'; };
+ var composed = _.compose(exclaim, greet);
+ equal(composed('moe'), 'hi: moe!', 'can compose a function that takes another');
+
+ composed = _.compose(greet, exclaim);
+ equal(composed('moe'), 'hi: moe!', 'in this case, the functions are also commutative');
+ });
+ `)
+ })
+}
+
+// after
+func Test_underscore_functions_7(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("after", function() {
+ var testAfter = function(afterAmount, timesCalled) {
+ var afterCalled = 0;
+ var after = _.after(afterAmount, function() {
+ afterCalled++;
+ });
+ while (timesCalled--) after();
+ return afterCalled;
+ };
+
+ equal(testAfter(5, 5), 1, "after(N) should fire after being called N times");
+ equal(testAfter(5, 4), 0, "after(N) should not fire unless called N times");
+ equal(testAfter(0, 0), 1, "after(0) should fire immediately");
+ });
+ `)
+ })
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/underscore_objects_test.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/underscore_objects_test.go
new file mode 100644
index 000000000..1973af8dd
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/underscore_objects_test.go
@@ -0,0 +1,826 @@
+package otto
+
+import (
+ "testing"
+)
+
+// keys
+func Test_underscore_objects_0(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("keys", function() {
+ equal(_.keys({one : 1, two : 2}).join(', '), 'one, two', 'can extract the keys from an object');
+ // the test above is not safe because it relies on for-in enumeration order
+ var a = []; a[1] = 0;
+ equal(_.keys(a).join(', '), '1', 'is not fooled by sparse arrays; see issue #95');
+ raises(function() { _.keys(null); }, TypeError, 'throws an error for <null> values');
+ raises(function() { _.keys(void 0); }, TypeError, 'throws an error for <undefined> values');
+ raises(function() { _.keys(1); }, TypeError, 'throws an error for number primitives');
+ raises(function() { _.keys('a'); }, TypeError, 'throws an error for string primitives');
+ raises(function() { _.keys(true); }, TypeError, 'throws an error for boolean primitives');
+ });
+ `)
+ })
+}
+
+// values
+func Test_underscore_objects_1(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("values", function() {
+ equal(_.values({one: 1, two: 2}).join(', '), '1, 2', 'can extract the values from an object');
+ equal(_.values({one: 1, two: 2, length: 3}).join(', '), '1, 2, 3', '... even when one of them is "length"');
+ });
+ `)
+ })
+}
+
+// pairs
+func Test_underscore_objects_2(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("pairs", function() {
+ deepEqual(_.pairs({one: 1, two: 2}), [['one', 1], ['two', 2]], 'can convert an object into pairs');
+ deepEqual(_.pairs({one: 1, two: 2, length: 3}), [['one', 1], ['two', 2], ['length', 3]], '... even when one of them is "length"');
+ });
+ `)
+ })
+}
+
+// invert
+func Test_underscore_objects_3(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("invert", function() {
+ var obj = {first: 'Moe', second: 'Larry', third: 'Curly'};
+ equal(_.keys(_.invert(obj)).join(' '), 'Moe Larry Curly', 'can invert an object');
+ ok(_.isEqual(_.invert(_.invert(obj)), obj), 'two inverts gets you back where you started');
+
+ var obj = {length: 3};
+ ok(_.invert(obj)['3'] == 'length', 'can invert an object with "length"')
+ });
+ `)
+ })
+}
+
+// functions
+func Test_underscore_objects_4(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("functions", function() {
+ var obj = {a : 'dash', b : _.map, c : (/yo/), d : _.reduce};
+ ok(_.isEqual(['b', 'd'], _.functions(obj)), 'can grab the function names of any passed-in object');
+
+ var Animal = function(){};
+ Animal.prototype.run = function(){};
+ equal(_.functions(new Animal).join(''), 'run', 'also looks up functions on the prototype');
+ });
+ `)
+ })
+}
+
+// extend
+func Test_underscore_objects_5(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("extend", function() {
+ var result;
+ equal(_.extend({}, {a:'b'}).a, 'b', 'can extend an object with the attributes of another');
+ equal(_.extend({a:'x'}, {a:'b'}).a, 'b', 'properties in source override destination');
+ equal(_.extend({x:'x'}, {a:'b'}).x, 'x', 'properties not in source dont get overriden');
+ result = _.extend({x:'x'}, {a:'a'}, {b:'b'});
+ ok(_.isEqual(result, {x:'x', a:'a', b:'b'}), 'can extend from multiple source objects');
+ result = _.extend({x:'x'}, {a:'a', x:2}, {a:'b'});
+ ok(_.isEqual(result, {x:2, a:'b'}), 'extending from multiple source objects last property trumps');
+ result = _.extend({}, {a: void 0, b: null});
+ equal(_.keys(result).join(''), 'ab', 'extend does not copy undefined values');
+
+ try {
+ result = {};
+ _.extend(result, null, undefined, {a:1});
+ } catch(ex) {}
+
+ equal(result.a, 1, 'should not error on <null> or <undefined> sources');
+ });
+ `)
+ })
+}
+
+// pick
+func Test_underscore_objects_6(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("pick", function() {
+ var result;
+ result = _.pick({a:1, b:2, c:3}, 'a', 'c');
+ ok(_.isEqual(result, {a:1, c:3}), 'can restrict properties to those named');
+ result = _.pick({a:1, b:2, c:3}, ['b', 'c']);
+ ok(_.isEqual(result, {b:2, c:3}), 'can restrict properties to those named in an array');
+ result = _.pick({a:1, b:2, c:3}, ['a'], 'b');
+ ok(_.isEqual(result, {a:1, b:2}), 'can restrict properties to those named in mixed args');
+
+ var Obj = function(){};
+ Obj.prototype = {a: 1, b: 2, c: 3};
+ ok(_.isEqual(_.pick(new Obj, 'a', 'c'), {a:1, c: 3}), 'include prototype props');
+ });
+ `)
+ })
+}
+
+// omit
+func Test_underscore_objects_7(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("omit", function() {
+ var result;
+ result = _.omit({a:1, b:2, c:3}, 'b');
+ ok(_.isEqual(result, {a:1, c:3}), 'can omit a single named property');
+ result = _.omit({a:1, b:2, c:3}, 'a', 'c');
+ ok(_.isEqual(result, {b:2}), 'can omit several named properties');
+ result = _.omit({a:1, b:2, c:3}, ['b', 'c']);
+ ok(_.isEqual(result, {a:1}), 'can omit properties named in an array');
+
+ var Obj = function(){};
+ Obj.prototype = {a: 1, b: 2, c: 3};
+ ok(_.isEqual(_.omit(new Obj, 'b'), {a:1, c: 3}), 'include prototype props');
+ });
+ `)
+ })
+}
+
+// defaults
+func Test_underscore_objects_8(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("defaults", function() {
+ var result;
+ var options = {zero: 0, one: 1, empty: "", nan: NaN, string: "string"};
+
+ _.defaults(options, {zero: 1, one: 10, twenty: 20});
+ equal(options.zero, 0, 'value exists');
+ equal(options.one, 1, 'value exists');
+ equal(options.twenty, 20, 'default applied');
+
+ _.defaults(options, {empty: "full"}, {nan: "nan"}, {word: "word"}, {word: "dog"});
+ equal(options.empty, "", 'value exists');
+ ok(_.isNaN(options.nan), "NaN isn't overridden");
+ equal(options.word, "word", 'new value is added, first one wins');
+
+ try {
+ options = {};
+ _.defaults(options, null, undefined, {a:1});
+ } catch(ex) {}
+
+ equal(options.a, 1, 'should not error on <null> or <undefined> sources');
+ });
+ `)
+ })
+}
+
+// clone
+func Test_underscore_objects_9(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("clone", function() {
+ var moe = {name : 'moe', lucky : [13, 27, 34]};
+ var clone = _.clone(moe);
+ equal(clone.name, 'moe', 'the clone as the attributes of the original');
+
+ clone.name = 'curly';
+ ok(clone.name == 'curly' && moe.name == 'moe', 'clones can change shallow attributes without affecting the original');
+
+ clone.lucky.push(101);
+ equal(_.last(moe.lucky), 101, 'changes to deep attributes are shared with the original');
+
+ equal(_.clone(undefined), void 0, 'non objects should not be changed by clone');
+ equal(_.clone(1), 1, 'non objects should not be changed by clone');
+ equal(_.clone(null), null, 'non objects should not be changed by clone');
+ });
+ `)
+ })
+}
+
+// isEqual
+func Test_underscore_objects_10(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("isEqual", function() {
+ function First() {
+ this.value = 1;
+ }
+ First.prototype.value = 1;
+ function Second() {
+ this.value = 1;
+ }
+ Second.prototype.value = 2;
+
+ // Basic equality and identity comparisons.
+ ok(_.isEqual(null, null), "<null> is equal to <null>");
+ ok(_.isEqual(), "<undefined> is equal to <undefined>");
+
+ ok(!_.isEqual(0, -0), "<0> is not equal to <-0>");
+ ok(!_.isEqual(-0, 0), "Commutative equality is implemented for <0> and <-0>");
+ ok(!_.isEqual(null, undefined), "<null> is not equal to <undefined>");
+ ok(!_.isEqual(undefined, null), "Commutative equality is implemented for <null> and <undefined>");
+
+ // String object and primitive comparisons.
+ ok(_.isEqual("Curly", "Curly"), "Identical string primitives are equal");
+ ok(_.isEqual(new String("Curly"), new String("Curly")), "String objects with identical primitive values are equal");
+ ok(_.isEqual(new String("Curly"), "Curly"), "String primitives and their corresponding object wrappers are equal");
+ ok(_.isEqual("Curly", new String("Curly")), "Commutative equality is implemented for string objects and primitives");
+
+ ok(!_.isEqual("Curly", "Larry"), "String primitives with different values are not equal");
+ ok(!_.isEqual(new String("Curly"), new String("Larry")), "String objects with different primitive values are not equal");
+ ok(!_.isEqual(new String("Curly"), {toString: function(){ return "Curly"; }}), "String objects and objects with a custom <toString> method are not equal");
+
+ // Number object and primitive comparisons.
+ ok(_.isEqual(75, 75), "Identical number primitives are equal");
+ ok(_.isEqual(new Number(75), new Number(75)), "Number objects with identical primitive values are equal");
+ ok(_.isEqual(75, new Number(75)), "Number primitives and their corresponding object wrappers are equal");
+ ok(_.isEqual(new Number(75), 75), "Commutative equality is implemented for number objects and primitives");
+ ok(!_.isEqual(new Number(0), -0), "<new Number(0)> and <-0> are not equal");
+ ok(!_.isEqual(0, new Number(-0)), "Commutative equality is implemented for <new Number(0)> and <-0>");
+
+ ok(!_.isEqual(new Number(75), new Number(63)), "Number objects with different primitive values are not equal");
+ ok(!_.isEqual(new Number(63), {valueOf: function(){ return 63; }}), "Number objects and objects with a <valueOf> method are not equal");
+
+ // Comparisons involving <NaN>.
+ ok(_.isEqual(NaN, NaN), "<NaN> is equal to <NaN>");
+ ok(!_.isEqual(61, NaN), "A number primitive is not equal to <NaN>");
+ ok(!_.isEqual(new Number(79), NaN), "A number object is not equal to <NaN>");
+ ok(!_.isEqual(Infinity, NaN), "<Infinity> is not equal to <NaN>");
+
+ // Boolean object and primitive comparisons.
+ ok(_.isEqual(true, true), "Identical boolean primitives are equal");
+ ok(_.isEqual(new Boolean, new Boolean), "Boolean objects with identical primitive values are equal");
+ ok(_.isEqual(true, new Boolean(true)), "Boolean primitives and their corresponding object wrappers are equal");
+ ok(_.isEqual(new Boolean(true), true), "Commutative equality is implemented for booleans");
+ ok(!_.isEqual(new Boolean(true), new Boolean), "Boolean objects with different primitive values are not equal");
+
+ // Common type coercions.
+ ok(!_.isEqual(true, new Boolean(false)), "Boolean objects are not equal to the boolean primitive <true>");
+ ok(!_.isEqual("75", 75), "String and number primitives with like values are not equal");
+ ok(!_.isEqual(new Number(63), new String(63)), "String and number objects with like values are not equal");
+ ok(!_.isEqual(75, "75"), "Commutative equality is implemented for like string and number values");
+ ok(!_.isEqual(0, ""), "Number and string primitives with like values are not equal");
+ ok(!_.isEqual(1, true), "Number and boolean primitives with like values are not equal");
+ ok(!_.isEqual(new Boolean(false), new Number(0)), "Boolean and number objects with like values are not equal");
+ ok(!_.isEqual(false, new String("")), "Boolean primitives and string objects with like values are not equal");
+ ok(!_.isEqual(12564504e5, new Date(2009, 9, 25)), "Dates and their corresponding numeric primitive values are not equal");
+
+ // Dates.
+ ok(_.isEqual(new Date(2009, 9, 25), new Date(2009, 9, 25)), "Date objects referencing identical times are equal");
+ ok(!_.isEqual(new Date(2009, 9, 25), new Date(2009, 11, 13)), "Date objects referencing different times are not equal");
+ ok(!_.isEqual(new Date(2009, 11, 13), {
+ getTime: function(){
+ return 12606876e5;
+ }
+ }), "Date objects and objects with a <getTime> method are not equal");
+ ok(!_.isEqual(new Date("Curly"), new Date("Curly")), "Invalid dates are not equal");
+
+ // Functions.
+ ok(!_.isEqual(First, Second), "Different functions with identical bodies and source code representations are not equal");
+
+ // RegExps.
+ ok(_.isEqual(/(?:)/gim, /(?:)/gim), "RegExps with equivalent patterns and flags are equal");
+ ok(!_.isEqual(/(?:)/g, /(?:)/gi), "RegExps with equivalent patterns and different flags are not equal");
+ ok(!_.isEqual(/Moe/gim, /Curly/gim), "RegExps with different patterns and equivalent flags are not equal");
+ ok(!_.isEqual(/(?:)/gi, /(?:)/g), "Commutative equality is implemented for RegExps");
+ ok(!_.isEqual(/Curly/g, {source: "Larry", global: true, ignoreCase: false, multiline: false}), "RegExps and RegExp-like objects are not equal");
+
+ // Empty arrays, array-like objects, and object literals.
+ ok(_.isEqual({}, {}), "Empty object literals are equal");
+ ok(_.isEqual([], []), "Empty array literals are equal");
+ ok(_.isEqual([{}], [{}]), "Empty nested arrays and objects are equal");
+ ok(!_.isEqual({length: 0}, []), "Array-like objects and arrays are not equal.");
+ ok(!_.isEqual([], {length: 0}), "Commutative equality is implemented for array-like objects");
+
+ ok(!_.isEqual({}, []), "Object literals and array literals are not equal");
+ ok(!_.isEqual([], {}), "Commutative equality is implemented for objects and arrays");
+
+ // Arrays with primitive and object values.
+ ok(_.isEqual([1, "Larry", true], [1, "Larry", true]), "Arrays containing identical primitives are equal");
+ ok(_.isEqual([(/Moe/g), new Date(2009, 9, 25)], [(/Moe/g), new Date(2009, 9, 25)]), "Arrays containing equivalent elements are equal");
+
+ // Multi-dimensional arrays.
+ var a = [new Number(47), false, "Larry", /Moe/, new Date(2009, 11, 13), ['running', 'biking', new String('programming')], {a: 47}];
+ var b = [new Number(47), false, "Larry", /Moe/, new Date(2009, 11, 13), ['running', 'biking', new String('programming')], {a: 47}];
+ ok(_.isEqual(a, b), "Arrays containing nested arrays and objects are recursively compared");
+
+ // Overwrite the methods defined in ES 5.1 section 15.4.4.
+ a.forEach = a.map = a.filter = a.every = a.indexOf = a.lastIndexOf = a.some = a.reduce = a.reduceRight = null;
+ b.join = b.pop = b.reverse = b.shift = b.slice = b.splice = b.concat = b.sort = b.unshift = null;
+
+ // Array elements and properties.
+ ok(_.isEqual(a, b), "Arrays containing equivalent elements and different non-numeric properties are equal");
+ a.push("White Rocks");
+ ok(!_.isEqual(a, b), "Arrays of different lengths are not equal");
+ a.push("East Boulder");
+ b.push("Gunbarrel Ranch", "Teller Farm");
+ ok(!_.isEqual(a, b), "Arrays of identical lengths containing different elements are not equal");
+
+ // Sparse arrays.
+ ok(_.isEqual(Array(3), Array(3)), "Sparse arrays of identical lengths are equal");
+ ok(!_.isEqual(Array(3), Array(6)), "Sparse arrays of different lengths are not equal when both are empty");
+
+ // Simple objects.
+ ok(_.isEqual({a: "Curly", b: 1, c: true}, {a: "Curly", b: 1, c: true}), "Objects containing identical primitives are equal");
+ ok(_.isEqual({a: /Curly/g, b: new Date(2009, 11, 13)}, {a: /Curly/g, b: new Date(2009, 11, 13)}), "Objects containing equivalent members are equal");
+ ok(!_.isEqual({a: 63, b: 75}, {a: 61, b: 55}), "Objects of identical sizes with different values are not equal");
+ ok(!_.isEqual({a: 63, b: 75}, {a: 61, c: 55}), "Objects of identical sizes with different property names are not equal");
+ ok(!_.isEqual({a: 1, b: 2}, {a: 1}), "Objects of different sizes are not equal");
+ ok(!_.isEqual({a: 1}, {a: 1, b: 2}), "Commutative equality is implemented for objects");
+ ok(!_.isEqual({x: 1, y: undefined}, {x: 1, z: 2}), "Objects with identical keys and different values are not equivalent");
+
+ // <A> contains nested objects and arrays.
+ a = {
+ name: new String("Moe Howard"),
+ age: new Number(77),
+ stooge: true,
+ hobbies: ["acting"],
+ film: {
+ name: "Sing a Song of Six Pants",
+ release: new Date(1947, 9, 30),
+ stars: [new String("Larry Fine"), "Shemp Howard"],
+ minutes: new Number(16),
+ seconds: 54
+ }
+ };
+
+ // <B> contains equivalent nested objects and arrays.
+ b = {
+ name: new String("Moe Howard"),
+ age: new Number(77),
+ stooge: true,
+ hobbies: ["acting"],
+ film: {
+ name: "Sing a Song of Six Pants",
+ release: new Date(1947, 9, 30),
+ stars: [new String("Larry Fine"), "Shemp Howard"],
+ minutes: new Number(16),
+ seconds: 54
+ }
+ };
+ ok(_.isEqual(a, b), "Objects with nested equivalent members are recursively compared");
+
+ // Instances.
+ ok(_.isEqual(new First, new First), "Object instances are equal");
+ ok(!_.isEqual(new First, new Second), "Objects with different constructors and identical own properties are not equal");
+ ok(!_.isEqual({value: 1}, new First), "Object instances and objects sharing equivalent properties are not equal");
+ ok(!_.isEqual({value: 2}, new Second), "The prototype chain of objects should not be examined");
+
+ // Circular Arrays.
+ (a = []).push(a);
+ (b = []).push(b);
+ ok(_.isEqual(a, b), "Arrays containing circular references are equal");
+ a.push(new String("Larry"));
+ b.push(new String("Larry"));
+ ok(_.isEqual(a, b), "Arrays containing circular references and equivalent properties are equal");
+ a.push("Shemp");
+ b.push("Curly");
+ ok(!_.isEqual(a, b), "Arrays containing circular references and different properties are not equal");
+
+ // More circular arrays #767.
+ a = ["everything is checked but", "this", "is not"];
+ a[1] = a;
+ b = ["everything is checked but", ["this", "array"], "is not"];
+ ok(!_.isEqual(a, b), "Comparison of circular references with non-circular references are not equal");
+
+ // Circular Objects.
+ a = {abc: null};
+ b = {abc: null};
+ a.abc = a;
+ b.abc = b;
+ ok(_.isEqual(a, b), "Objects containing circular references are equal");
+ a.def = 75;
+ b.def = 75;
+ ok(_.isEqual(a, b), "Objects containing circular references and equivalent properties are equal");
+ a.def = new Number(75);
+ b.def = new Number(63);
+ ok(!_.isEqual(a, b), "Objects containing circular references and different properties are not equal");
+
+ // More circular objects #767.
+ a = {everything: "is checked", but: "this", is: "not"};
+ a.but = a;
+ b = {everything: "is checked", but: {that:"object"}, is: "not"};
+ ok(!_.isEqual(a, b), "Comparison of circular references with non-circular object references are not equal");
+
+ // Cyclic Structures.
+ a = [{abc: null}];
+ b = [{abc: null}];
+ (a[0].abc = a).push(a);
+ (b[0].abc = b).push(b);
+ ok(_.isEqual(a, b), "Cyclic structures are equal");
+ a[0].def = "Larry";
+ b[0].def = "Larry";
+ ok(_.isEqual(a, b), "Cyclic structures containing equivalent properties are equal");
+ a[0].def = new String("Larry");
+ b[0].def = new String("Curly");
+ ok(!_.isEqual(a, b), "Cyclic structures containing different properties are not equal");
+
+ // Complex Circular References.
+ a = {foo: {b: {foo: {c: {foo: null}}}}};
+ b = {foo: {b: {foo: {c: {foo: null}}}}};
+ a.foo.b.foo.c.foo = a;
+ b.foo.b.foo.c.foo = b;
+ ok(_.isEqual(a, b), "Cyclic structures with nested and identically-named properties are equal");
+
+ // Chaining.
+ ok(!_.isEqual(_({x: 1, y: undefined}).chain(), _({x: 1, z: 2}).chain()), 'Chained objects containing different values are not equal');
+
+ a = _({x: 1, y: 2}).chain();
+ b = _({x: 1, y: 2}).chain();
+ equal(_.isEqual(a.isEqual(b), _(true)), true, '<isEqual> can be chained');
+
+ // TEST: ???
+ return;
+
+ // Objects from another frame.
+ ok(_.isEqual({}, iObject));
+ });
+ `)
+ })
+}
+
+// isEmpty
+func Test_underscore_objects_11(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("isEmpty", function() {
+ ok(!_([1]).isEmpty(), '[1] is not empty');
+ ok(_.isEmpty([]), '[] is empty');
+ ok(!_.isEmpty({one : 1}), '{one : 1} is not empty');
+ ok(_.isEmpty({}), '{} is empty');
+ ok(_.isEmpty(new RegExp('')), 'objects with prototype properties are empty');
+ ok(_.isEmpty(null), 'null is empty');
+ ok(_.isEmpty(), 'undefined is empty');
+ ok(_.isEmpty(''), 'the empty string is empty');
+ ok(!_.isEmpty('moe'), 'but other strings are not');
+
+ var obj = {one : 1};
+ delete obj.one;
+ ok(_.isEmpty(obj), 'deleting all the keys from an object empties it');
+ });
+ `)
+ })
+}
+
+// isElement
+func Test_underscore_objects_12(t *testing.T) {
+ // TEST: ReferenceError: $ is not defined
+ if true {
+ return
+ }
+
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("isElement", function() {
+ ok(!_.isElement('div'), 'strings are not dom elements');
+ ok(_.isElement($('html')[0]), 'the html tag is a DOM element');
+ ok(_.isElement(iElement), 'even from another frame');
+ });
+ `)
+ })
+}
+
+// isArguments
+func Test_underscore_objects_13(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("isArguments", function() {
+ var args = (function(){ return arguments; })(1, 2, 3);
+ ok(!_.isArguments('string'), 'a string is not an arguments object');
+ ok(!_.isArguments(_.isArguments), 'a function is not an arguments object');
+ ok(_.isArguments(args), 'but the arguments object is an arguments object');
+ ok(!_.isArguments(_.toArray(args)), 'but not when it\'s converted into an array');
+ ok(!_.isArguments([1,2,3]), 'and not vanilla arrays.');
+
+ // TEST: ReferenceError: iArguments is not defined
+ return;
+ ok(_.isArguments(iArguments), 'even from another frame');
+ });
+ `)
+ })
+}
+
+// isObject
+func Test_underscore_objects_14(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("isObject", function() {
+ ok(_.isObject(arguments), 'the arguments object is object');
+ ok(_.isObject([1, 2, 3]), 'and arrays');
+ // TEST: ReferenceError: $ is not defined
+ return;
+ ok(_.isObject($('html')[0]), 'and DOM element');
+ ok(_.isObject(iElement), 'even from another frame');
+ ok(_.isObject(function () {}), 'and functions');
+ ok(_.isObject(iFunction), 'even from another frame');
+ ok(!_.isObject(null), 'but not null');
+ ok(!_.isObject(undefined), 'and not undefined');
+ ok(!_.isObject('string'), 'and not string');
+ ok(!_.isObject(12), 'and not number');
+ ok(!_.isObject(true), 'and not boolean');
+ ok(_.isObject(new String('string')), 'but new String()');
+ });
+ `)
+ })
+}
+
+// isArray
+func Test_underscore_objects_15(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("isArray", function() {
+ ok(!_.isArray(arguments), 'the arguments object is not an array');
+ ok(_.isArray([1, 2, 3]), 'but arrays are');
+ // TEST: ???
+ return;
+ ok(_.isArray(iArray), 'even from another frame');
+ });
+ `)
+ })
+}
+
+// isString
+func Test_underscore_objects_16(t *testing.T) {
+ // TEST: ReferenceError: document is not defined
+ if true {
+ return
+ }
+
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("isString", function() {
+ ok(!_.isString(document.body), 'the document body is not a string');
+ ok(_.isString([1, 2, 3].join(', ')), 'but strings are');
+ // TEST: ???
+ return;
+ ok(_.isString(iString), 'even from another frame');
+ });
+ `)
+ })
+}
+
+// isNumber
+func Test_underscore_objects_17(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("isNumber", function() {
+ ok(!_.isNumber('string'), 'a string is not a number');
+ ok(!_.isNumber(arguments), 'the arguments object is not a number');
+ ok(!_.isNumber(undefined), 'undefined is not a number');
+ ok(_.isNumber(3 * 4 - 7 / 10), 'but numbers are');
+ ok(_.isNumber(NaN), 'NaN *is* a number');
+ ok(_.isNumber(Infinity), 'Infinity is a number');
+ // TEST: ???
+ return;
+ ok(_.isNumber(iNumber), 'even from another frame');
+ ok(!_.isNumber('1'), 'numeric strings are not numbers');
+ });
+ `)
+ })
+}
+
+// isBoolean
+func Test_underscore_objects_18(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("isBoolean", function() {
+ ok(!_.isBoolean(2), 'a number is not a boolean');
+ ok(!_.isBoolean("string"), 'a string is not a boolean');
+ ok(!_.isBoolean("false"), 'the string "false" is not a boolean');
+ ok(!_.isBoolean("true"), 'the string "true" is not a boolean');
+ ok(!_.isBoolean(arguments), 'the arguments object is not a boolean');
+ ok(!_.isBoolean(undefined), 'undefined is not a boolean');
+ ok(!_.isBoolean(NaN), 'NaN is not a boolean');
+ ok(!_.isBoolean(null), 'null is not a boolean');
+ ok(_.isBoolean(true), 'but true is');
+ ok(_.isBoolean(false), 'and so is false');
+ // TEST: ???
+ return;
+ ok(_.isBoolean(iBoolean), 'even from another frame');
+ });
+ `)
+ })
+}
+
+// isFunction
+func Test_underscore_objects_19(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("isFunction", function() {
+ ok(!_.isFunction([1, 2, 3]), 'arrays are not functions');
+ ok(!_.isFunction('moe'), 'strings are not functions');
+ ok(_.isFunction(_.isFunction), 'but functions are');
+ // TEST: ???
+ return;
+ ok(_.isFunction(iFunction), 'even from another frame');
+ });
+ `)
+ })
+}
+
+// isDate
+func Test_underscore_objects_20(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("isDate", function() {
+ ok(!_.isDate(100), 'numbers are not dates');
+ ok(!_.isDate({}), 'objects are not dates');
+ ok(_.isDate(new Date()), 'but dates are');
+ // TEST: ???
+ return;
+ ok(_.isDate(iDate), 'even from another frame');
+ });
+ `)
+ })
+}
+
+// isRegExp
+func Test_underscore_objects_21(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("isRegExp", function() {
+ ok(!_.isRegExp(_.identity), 'functions are not RegExps');
+ ok(_.isRegExp(/identity/), 'but RegExps are');
+ // TEST: ???
+ return;
+ ok(_.isRegExp(iRegExp), 'even from another frame');
+ });
+ `)
+ })
+}
+
+// isFinite
+func Test_underscore_objects_22(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("isFinite", function() {
+ ok(!_.isFinite(undefined), 'undefined is not Finite');
+ ok(!_.isFinite(null), 'null is not Finite');
+ ok(!_.isFinite(NaN), 'NaN is not Finite');
+ ok(!_.isFinite(Infinity), 'Infinity is not Finite');
+ ok(!_.isFinite(-Infinity), '-Infinity is not Finite');
+ ok(_.isFinite('12'), 'Numeric strings are numbers');
+ ok(!_.isFinite('1a'), 'Non numeric strings are not numbers');
+ ok(!_.isFinite(''), 'Empty strings are not numbers');
+ var obj = new Number(5);
+ ok(_.isFinite(obj), 'Number instances can be finite');
+ ok(_.isFinite(0), '0 is Finite');
+ ok(_.isFinite(123), 'Ints are Finite');
+ ok(_.isFinite(-12.44), 'Floats are Finite');
+ });
+ `)
+ })
+}
+
+// isNaN
+func Test_underscore_objects_23(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("isNaN", function() {
+ ok(!_.isNaN(undefined), 'undefined is not NaN');
+ ok(!_.isNaN(null), 'null is not NaN');
+ ok(!_.isNaN(0), '0 is not NaN');
+ ok(_.isNaN(NaN), 'but NaN is');
+ // TEST: ???
+ return;
+ ok(_.isNaN(iNaN), 'even from another frame');
+ ok(_.isNaN(new Number(NaN)), 'wrapped NaN is still NaN');
+ });
+ `)
+ })
+}
+
+// isNull
+func Test_underscore_objects_24(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("isNull", function() {
+ ok(!_.isNull(undefined), 'undefined is not null');
+ ok(!_.isNull(NaN), 'NaN is not null');
+ ok(_.isNull(null), 'but null is');
+ // TEST: ???
+ return;
+ ok(_.isNull(iNull), 'even from another frame');
+ });
+ `)
+ })
+}
+
+// isUndefined
+func Test_underscore_objects_25(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("isUndefined", function() {
+ ok(!_.isUndefined(1), 'numbers are defined');
+ ok(!_.isUndefined(null), 'null is defined');
+ ok(!_.isUndefined(false), 'false is defined');
+ ok(!_.isUndefined(NaN), 'NaN is defined');
+ ok(_.isUndefined(), 'nothing is undefined');
+ ok(_.isUndefined(undefined), 'undefined is undefined');
+ // TEST: ???
+ return;
+ ok(_.isUndefined(iUndefined), 'even from another frame');
+ });
+ `)
+ })
+}
+
+// tap
+func Test_underscore_objects_26(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("tap", function() {
+ var intercepted = null;
+ var interceptor = function(obj) { intercepted = obj; };
+ var returned = _.tap(1, interceptor);
+ equal(intercepted, 1, "passes tapped object to interceptor");
+ equal(returned, 1, "returns tapped object");
+
+ returned = _([1,2,3]).chain().
+ map(function(n){ return n * 2; }).
+ max().
+ tap(interceptor).
+ value();
+ ok(returned == 6 && intercepted == 6, 'can use tapped objects in a chain');
+ });
+ `)
+ })
+}
+
+// has
+func Test_underscore_objects_27(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("has", function () {
+ var obj = {foo: "bar", func: function () {} };
+ ok (_.has(obj, "foo"), "has() checks that the object has a property.");
+ ok (_.has(obj, "baz") == false, "has() returns false if the object doesn't have the property.");
+ ok (_.has(obj, "func"), "has() works for functions too.");
+ obj.hasOwnProperty = null;
+ ok (_.has(obj, "foo"), "has() works even when the hasOwnProperty method is deleted.");
+ var child = {};
+ child.prototype = obj;
+ ok (_.has(child, "foo") == false, "has() does not check the prototype chain for a property.")
+ });
+ `)
+ })
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/underscore_test.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/underscore_test.go
new file mode 100644
index 000000000..d8bf2da18
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/underscore_test.go
@@ -0,0 +1,165 @@
+package otto
+
+import (
+ "./terst"
+ "testing"
+
+ "github.com/robertkrimen/otto/underscore"
+)
+
+func init() {
+ underscore.Disable()
+}
+
+// A persistent handle for the underscore tester
+// We do not run underscore tests in parallel, so it is okay to stash globally
+// (Maybe use sync.Pool in the future...)
+var tester_ *_tester
+
+// A tester for underscore: test_ => test(underscore) :)
+func test_(arguments ...interface{}) (func(string, ...interface{}) Value, *_tester) {
+ tester := tester_
+ if tester == nil {
+ tester = newTester()
+ tester.underscore() // Load underscore and testing shim, etc.
+ tester_ = tester
+ }
+
+ return tester.test, tester
+}
+
+func (self *_tester) underscore() {
+ vm := self.vm
+ _, err := vm.Run(underscore.Source())
+ if err != nil {
+ panic(err)
+ }
+
+ vm.Set("assert", func(call FunctionCall) Value {
+ if !call.Argument(0).bool() {
+ message := "Assertion failed"
+ if len(call.ArgumentList) > 1 {
+ message = call.ArgumentList[1].string()
+ }
+ t := terst.Caller().T()
+ is(message, nil)
+ t.Fail()
+ return falseValue
+ }
+ return trueValue
+ })
+
+ vm.Run(`
+ var templateSettings;
+
+ function _setup() {
+ templateSettings = _.clone(_.templateSettings);
+ }
+
+ function _teardown() {
+ _.templateSettings = templateSettings;
+ }
+
+ function module() {
+ /* Nothing happens. */
+ }
+
+ function equals(a, b, emit) {
+ assert(a == b, emit + ", <" + a + "> != <" + b + ">");
+ }
+ var equal = equals;
+
+ function notStrictEqual(a, b, emit) {
+ assert(a !== b, emit);
+ }
+
+ function strictEqual(a, b, emit) {
+ assert(a === b, emit);
+ }
+
+ function ok(a, emit) {
+ assert(a, emit);
+ }
+
+ function raises(fn, want, emit) {
+ var have, _ok = false;
+ if (typeof want === "string") {
+ emit = want;
+ want = null;
+ }
+
+ try {
+ fn();
+ } catch(tmp) {
+ have = tmp;
+ }
+
+ if (have) {
+ if (!want) {
+ _ok = true;
+ }
+ else if (want instanceof RegExp) {
+ _ok = want.test(have);
+ }
+ else if (have instanceof want) {
+ _ok = true
+ }
+ else if (want.call({}, have) === true) {
+ _ok = true;
+ }
+ }
+
+ ok(_ok, emit);
+ }
+
+ function test(name){
+ _setup()
+ try {
+ templateSettings = _.clone(_.templateSettings);
+ if (arguments.length == 3) {
+ count = 0
+ for (count = 0; count < arguments[1]; count++) {
+ arguments[2]()
+ }
+ } else {
+ // For now.
+ arguments[1]()
+ }
+ }
+ finally {
+ _teardown()
+ }
+ }
+
+ function deepEqual(a, b, emit) {
+ // Also, for now.
+ assert(_.isEqual(a, b), emit)
+ }
+ `)
+}
+
+func Test_underscore(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ _.map([1, 2, 3], function(value){
+ return value + 1
+ })
+ `, "2,3,4")
+
+ test(`
+ abc = _.find([1, 2, 3, -1], function(value) { return value == -1 })
+ `, -1)
+
+ test(`_.isEqual(1, 1)`, true)
+ test(`_.isEqual([], [])`, true)
+ test(`_.isEqual(['b', 'd'], ['b', 'd'])`, true)
+ test(`_.isEqual(['b', 'd', 'c'], ['b', 'd', 'e'])`, false)
+ test(`_.isFunction(function(){})`, true)
+ test(`_.template('<p>\u2028<%= "\\u2028\\u2029" %>\u2029</p>')()`, "<p>\u2028\u2028\u2029\u2029</p>")
+ })
+}
+
+// TODO Test: typeof An argument reference
+// TODO Test: abc = {}; abc == Object(abc)
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/underscore_utility_test.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/underscore_utility_test.go
new file mode 100644
index 000000000..ebabb083b
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/underscore_utility_test.go
@@ -0,0 +1,419 @@
+package otto
+
+import (
+ "testing"
+)
+
+// #750 - Return _ instance.
+func Test_underscore_utility_0(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("#750 - Return _ instance.", 2, function() {
+ var instance = _([]);
+ ok(_(instance) === instance);
+ ok(new _(instance) === instance);
+ });
+ `)
+ })
+}
+
+// identity
+func Test_underscore_utility_1(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("identity", function() {
+ var moe = {name : 'moe'};
+ equal(_.identity(moe), moe, 'moe is the same as his identity');
+ });
+ `)
+ })
+}
+
+// random
+func Test_underscore_utility_2(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("random", function() {
+ var array = _.range(1000);
+ var min = Math.pow(2, 31);
+ var max = Math.pow(2, 62);
+
+ ok(_.every(array, function() {
+ return _.random(min, max) >= min;
+ }), "should produce a random number greater than or equal to the minimum number");
+
+ ok(_.some(array, function() {
+ return _.random(Number.MAX_VALUE) > 0;
+ }), "should produce a random number when passed <Number.MAX_VALUE>");
+ });
+ `)
+ })
+}
+
+// uniqueId
+func Test_underscore_utility_3(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("uniqueId", function() {
+ var ids = [], i = 0;
+ while(i++ < 100) ids.push(_.uniqueId());
+ equal(_.uniq(ids).length, ids.length, 'can generate a globally-unique stream of ids');
+ });
+ `)
+ })
+}
+
+// times
+func Test_underscore_utility_4(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("times", function() {
+ var vals = [];
+ _.times(3, function (i) { vals.push(i); });
+ ok(_.isEqual(vals, [0,1,2]), "is 0 indexed");
+ //
+ vals = [];
+ _(3).times(function(i) { vals.push(i); });
+ ok(_.isEqual(vals, [0,1,2]), "works as a wrapper");
+ // collects return values
+ ok(_.isEqual([0, 1, 2], _.times(3, function(i) { return i; })), "collects return values");
+ });
+ `)
+ })
+}
+
+// mixin
+func Test_underscore_utility_5(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("mixin", function() {
+ _.mixin({
+ myReverse: function(string) {
+ return string.split('').reverse().join('');
+ }
+ });
+ equal(_.myReverse('panacea'), 'aecanap', 'mixed in a function to _');
+ equal(_('champ').myReverse(), 'pmahc', 'mixed in a function to the OOP wrapper');
+ });
+ `)
+ })
+}
+
+// _.escape
+func Test_underscore_utility_6(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("_.escape", function() {
+ equal(_.escape("Curly & Moe"), "Curly &amp; Moe");
+ equal(_.escape("Curly &amp; Moe"), "Curly &amp;amp; Moe");
+ equal(_.escape(null), '');
+ });
+ `)
+ })
+}
+
+// _.unescape
+func Test_underscore_utility_7(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("_.unescape", function() {
+ var string = "Curly & Moe";
+ equal(_.unescape("Curly &amp; Moe"), string);
+ equal(_.unescape("Curly &amp;amp; Moe"), "Curly &amp; Moe");
+ equal(_.unescape(null), '');
+ equal(_.unescape(_.escape(string)), string);
+ });
+ `)
+ })
+}
+
+// template
+func Test_underscore_utility_8(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test("template", function() {
+ var basicTemplate = _.template("<%= thing %> is gettin' on my noives!");
+ var result = basicTemplate({thing : 'This'});
+ equal(result, "This is gettin' on my noives!", 'can do basic attribute interpolation');
+
+ var sansSemicolonTemplate = _.template("A <% this %> B");
+ equal(sansSemicolonTemplate(), "A B");
+
+ var backslashTemplate = _.template("<%= thing %> is \\ridanculous");
+ equal(backslashTemplate({thing: 'This'}), "This is \\ridanculous");
+
+ var escapeTemplate = _.template('<%= a ? "checked=\\"checked\\"" : "" %>');
+ equal(escapeTemplate({a: true}), 'checked="checked"', 'can handle slash escapes in interpolations.');
+
+ var fancyTemplate = _.template("<ul><% \
+ for (var key in people) { \
+ %><li><%= people[key] %></li><% } %></ul>");
+ result = fancyTemplate({people : {moe : "Moe", larry : "Larry", curly : "Curly"}});
+ equal(result, "<ul><li>Moe</li><li>Larry</li><li>Curly</li></ul>", 'can run arbitrary javascript in templates');
+
+ var escapedCharsInJavascriptTemplate = _.template("<ul><% _.each(numbers.split('\\n'), function(item) { %><li><%= item %></li><% }) %></ul>");
+ result = escapedCharsInJavascriptTemplate({numbers: "one\ntwo\nthree\nfour"});
+ equal(result, "<ul><li>one</li><li>two</li><li>three</li><li>four</li></ul>", 'Can use escaped characters (e.g. \\n) in Javascript');
+
+ var namespaceCollisionTemplate = _.template("<%= pageCount %> <%= thumbnails[pageCount] %> <% _.each(thumbnails, function(p) { %><div class=\"thumbnail\" rel=\"<%= p %>\"></div><% }); %>");
+ result = namespaceCollisionTemplate({
+ pageCount: 3,
+ thumbnails: {
+ 1: "p1-thumbnail.gif",
+ 2: "p2-thumbnail.gif",
+ 3: "p3-thumbnail.gif"
+ }
+ });
+ equal(result, "3 p3-thumbnail.gif <div class=\"thumbnail\" rel=\"p1-thumbnail.gif\"></div><div class=\"thumbnail\" rel=\"p2-thumbnail.gif\"></div><div class=\"thumbnail\" rel=\"p3-thumbnail.gif\"></div>");
+
+ var noInterpolateTemplate = _.template("<div><p>Just some text. Hey, I know this is silly but it aids consistency.</p></div>");
+ result = noInterpolateTemplate();
+ equal(result, "<div><p>Just some text. Hey, I know this is silly but it aids consistency.</p></div>");
+
+ var quoteTemplate = _.template("It's its, not it's");
+ equal(quoteTemplate({}), "It's its, not it's");
+
+ var quoteInStatementAndBody = _.template("<%\
+ if(foo == 'bar'){ \
+ %>Statement quotes and 'quotes'.<% } %>");
+ equal(quoteInStatementAndBody({foo: "bar"}), "Statement quotes and 'quotes'.");
+
+ var withNewlinesAndTabs = _.template('This\n\t\tis: <%= x %>.\n\tok.\nend.');
+ equal(withNewlinesAndTabs({x: 'that'}), 'This\n\t\tis: that.\n\tok.\nend.');
+
+ var template = _.template("<i><%- value %></i>");
+ var result = template({value: "<script>"});
+ equal(result, '<i>&lt;script&gt;</i>');
+
+ var stooge = {
+ name: "Moe",
+ template: _.template("I'm <%= this.name %>")
+ };
+ equal(stooge.template(), "I'm Moe");
+
+ // TEST: ReferenceError: $ is not defined
+ if (false) {
+ if (!$.browser.msie) {
+ var fromHTML = _.template($('#template').html());
+ equal(fromHTML({data : 12345}).replace(/\s/g, ''), '<li>24690</li>');
+ }
+ }
+
+ _.templateSettings = {
+ evaluate : /\{\{([\s\S]+?)\}\}/g,
+ interpolate : /\{\{=([\s\S]+?)\}\}/g
+ };
+
+ var custom = _.template("<ul>{{ for (var key in people) { }}<li>{{= people[key] }}</li>{{ } }}</ul>");
+ result = custom({people : {moe : "Moe", larry : "Larry", curly : "Curly"}});
+ equal(result, "<ul><li>Moe</li><li>Larry</li><li>Curly</li></ul>", 'can run arbitrary javascript in templates');
+
+ var customQuote = _.template("It's its, not it's");
+ equal(customQuote({}), "It's its, not it's");
+
+ var quoteInStatementAndBody = _.template("{{ if(foo == 'bar'){ }}Statement quotes and 'quotes'.{{ } }}");
+ equal(quoteInStatementAndBody({foo: "bar"}), "Statement quotes and 'quotes'.");
+
+ _.templateSettings = {
+ evaluate : /<\?([\s\S]+?)\?>/g,
+ interpolate : /<\?=([\s\S]+?)\?>/g
+ };
+
+ var customWithSpecialChars = _.template("<ul><? for (var key in people) { ?><li><?= people[key] ?></li><? } ?></ul>");
+ result = customWithSpecialChars({people : {moe : "Moe", larry : "Larry", curly : "Curly"}});
+ equal(result, "<ul><li>Moe</li><li>Larry</li><li>Curly</li></ul>", 'can run arbitrary javascript in templates');
+
+ var customWithSpecialCharsQuote = _.template("It's its, not it's");
+ equal(customWithSpecialCharsQuote({}), "It's its, not it's");
+
+ var quoteInStatementAndBody = _.template("<? if(foo == 'bar'){ ?>Statement quotes and 'quotes'.<? } ?>");
+ equal(quoteInStatementAndBody({foo: "bar"}), "Statement quotes and 'quotes'.");
+
+ _.templateSettings = {
+ interpolate : /\{\{(.+?)\}\}/g
+ };
+
+ var mustache = _.template("Hello {{planet}}!");
+ equal(mustache({planet : "World"}), "Hello World!", "can mimic mustache.js");
+
+ var templateWithNull = _.template("a null undefined {{planet}}");
+ equal(templateWithNull({planet : "world"}), "a null undefined world", "can handle missing escape and evaluate settings");
+ });
+ `)
+ })
+}
+
+// _.template provides the generated function source, when a SyntaxError occurs
+func Test_underscore_utility_9(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test('_.template provides the generated function source, when a SyntaxError occurs', function() {
+ try {
+ _.template('<b><%= if x %></b>');
+ } catch (ex) {
+ var source = ex.source;
+ }
+ ok(/__p/.test(source));
+ });
+ `)
+ })
+}
+
+// _.template handles \\u2028 & \\u2029
+func Test_underscore_utility_10(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test('_.template handles \\u2028 & \\u2029', function() {
+ var tmpl = _.template('<p>\u2028<%= "\\u2028\\u2029" %>\u2029</p>');
+ strictEqual(tmpl(), '<p>\u2028\u2028\u2029\u2029</p>');
+ });
+ `)
+ })
+}
+
+// result calls functions and returns primitives
+func Test_underscore_utility_11(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test('result calls functions and returns primitives', function() {
+ var obj = {w: '', x: 'x', y: function(){ return this.x; }};
+ strictEqual(_.result(obj, 'w'), '');
+ strictEqual(_.result(obj, 'x'), 'x');
+ strictEqual(_.result(obj, 'y'), 'x');
+ strictEqual(_.result(obj, 'z'), undefined);
+ strictEqual(_.result(null, 'x'), null);
+ });
+ `)
+ })
+}
+
+// _.templateSettings.variable
+func Test_underscore_utility_12(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test('_.templateSettings.variable', function() {
+ var s = '<%=data.x%>';
+ var data = {x: 'x'};
+ strictEqual(_.template(s, data, {variable: 'data'}), 'x');
+ _.templateSettings.variable = 'data';
+ strictEqual(_.template(s)(data), 'x');
+ });
+ `)
+ })
+}
+
+// #547 - _.templateSettings is unchanged by custom settings.
+func Test_underscore_utility_13(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test('#547 - _.templateSettings is unchanged by custom settings.', function() {
+ ok(!_.templateSettings.variable);
+ _.template('', {}, {variable: 'x'});
+ ok(!_.templateSettings.variable);
+ });
+ `)
+ })
+}
+
+// #556 - undefined template variables.
+func Test_underscore_utility_14(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test('#556 - undefined template variables.', function() {
+ var template = _.template('<%=x%>');
+ strictEqual(template({x: null}), '');
+ strictEqual(template({x: undefined}), '');
+
+ var templateEscaped = _.template('<%-x%>');
+ strictEqual(templateEscaped({x: null}), '');
+ strictEqual(templateEscaped({x: undefined}), '');
+
+ var templateWithProperty = _.template('<%=x.foo%>');
+ strictEqual(templateWithProperty({x: {} }), '');
+ strictEqual(templateWithProperty({x: {} }), '');
+
+ var templateWithPropertyEscaped = _.template('<%-x.foo%>');
+ strictEqual(templateWithPropertyEscaped({x: {} }), '');
+ strictEqual(templateWithPropertyEscaped({x: {} }), '');
+ });
+ `)
+ })
+}
+
+// interpolate evaluates code only once.
+func Test_underscore_utility_15(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test('interpolate evaluates code only once.', 2, function() {
+ var count = 0;
+ var template = _.template('<%= f() %>');
+ template({f: function(){ ok(!(count++)); }});
+
+ var countEscaped = 0;
+ var templateEscaped = _.template('<%- f() %>');
+ templateEscaped({f: function(){ ok(!(countEscaped++)); }});
+ });
+ `)
+ })
+}
+
+// #746 - _.template settings are not modified.
+func Test_underscore_utility_16(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test('#746 - _.template settings are not modified.', 1, function() {
+ var settings = {};
+ _.template('', null, settings);
+ deepEqual(settings, {});
+ });
+ `)
+ })
+}
+
+// #779 - delimeters are applied to unescaped text.
+func Test_underscore_utility_17(t *testing.T) {
+ tt(t, func() {
+ test, _ := test_()
+
+ test(`
+ test('#779 - delimeters are applied to unescaped text.', 1, function() {
+ var template = _.template('<<\nx\n>>', null, {evaluate: /<<(.*?)>>/g});
+ strictEqual(template(), '<<\nx\n>>');
+ });
+ `)
+ })
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/value.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/value.go
new file mode 100644
index 000000000..05d61dd62
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/value.go
@@ -0,0 +1,989 @@
+package otto
+
+import (
+ "fmt"
+ "math"
+ "reflect"
+ "strconv"
+ "unicode/utf16"
+)
+
+type _valueKind int
+
+const (
+ valueUndefined _valueKind = iota
+ valueNull
+ valueNumber
+ valueString
+ valueBoolean
+ valueObject
+
+ // These are invalid outside of the runtime
+ valueEmpty
+ valueResult
+ valueReference
+)
+
+// Value is the representation of a JavaScript value.
+type Value struct {
+ kind _valueKind
+ value interface{}
+}
+
+func (vl Value) safe() bool {
+ return vl.kind < valueEmpty
+}
+
+var (
+ emptyValue = Value{kind: valueEmpty}
+ nullValue = Value{kind: valueNull}
+ falseValue = Value{kind: valueBoolean, value: false}
+ trueValue = Value{kind: valueBoolean, value: true}
+)
+
+// ToValue will convert an interface{} value to a value digestible by otto/JavaScript
+//
+// This function will not work for advanced types (struct, map, slice/array, etc.) and
+// you should use Otto.ToValue instead.
+func ToValue(value interface{}) (Value, error) {
+ result := Value{}
+ err := catchPanic(func() {
+ result = toValue(value)
+ })
+ return result, err
+}
+
+func (value Value) isEmpty() bool {
+ return value.kind == valueEmpty
+}
+
+// Undefined
+
+// UndefinedValue will return a Value representing undefined.
+func UndefinedValue() Value {
+ return Value{}
+}
+
+// IsDefined will return false if the value is undefined, and true otherwise.
+func (value Value) IsDefined() bool {
+ return value.kind != valueUndefined
+}
+
+// IsUndefined will return true if the value is undefined, and false otherwise.
+func (value Value) IsUndefined() bool {
+ return value.kind == valueUndefined
+}
+
+// NullValue will return a Value representing null.
+func NullValue() Value {
+ return Value{kind: valueNull}
+}
+
+// IsNull will return true if the value is null, and false otherwise.
+func (value Value) IsNull() bool {
+ return value.kind == valueNull
+}
+
+// ---
+
+func (value Value) isCallable() bool {
+ switch value := value.value.(type) {
+ case *_object:
+ return value.isCall()
+ }
+ return false
+}
+
+// Call the value as a function with the given this value and argument list and
+// return the result of invocation. It is essentially equivalent to:
+//
+// value.apply(thisValue, argumentList)
+//
+// An undefined value and an error will result if:
+//
+// 1. There is an error during conversion of the argument list
+// 2. The value is not actually a function
+// 3. An (uncaught) exception is thrown
+//
+func (value Value) Call(this Value, argumentList ...interface{}) (Value, error) {
+ result := Value{}
+ err := catchPanic(func() {
+ // FIXME
+ result = value.call(nil, this, argumentList...)
+ })
+ if !value.safe() {
+ value = Value{}
+ }
+ return result, err
+}
+
+func (value Value) call(rt *_runtime, this Value, argumentList ...interface{}) Value {
+ switch function := value.value.(type) {
+ case *_object:
+ return function.call(this, function.runtime.toValueArray(argumentList...), false, nativeFrame)
+ }
+ if rt == nil {
+ panic("FIXME TypeError")
+ }
+ panic(rt.panicTypeError())
+}
+
+func (value Value) constructSafe(rt *_runtime, this Value, argumentList ...interface{}) (Value, error) {
+ result := Value{}
+ err := catchPanic(func() {
+ result = value.construct(rt, this, argumentList...)
+ })
+ return result, err
+}
+
+func (value Value) construct(rt *_runtime, this Value, argumentList ...interface{}) Value {
+ switch fn := value.value.(type) {
+ case *_object:
+ return fn.construct(fn.runtime.toValueArray(argumentList...))
+ }
+ if rt == nil {
+ panic("FIXME TypeError")
+ }
+ panic(rt.panicTypeError())
+}
+
+// IsPrimitive will return true if value is a primitive (any kind of primitive).
+func (value Value) IsPrimitive() bool {
+ return !value.IsObject()
+}
+
+// IsBoolean will return true if value is a boolean (primitive).
+func (value Value) IsBoolean() bool {
+ return value.kind == valueBoolean
+}
+
+// IsNumber will return true if value is a number (primitive).
+func (value Value) IsNumber() bool {
+ return value.kind == valueNumber
+}
+
+// IsNaN will return true if value is NaN (or would convert to NaN).
+func (value Value) IsNaN() bool {
+ switch value := value.value.(type) {
+ case float64:
+ return math.IsNaN(value)
+ case float32:
+ return math.IsNaN(float64(value))
+ case int, int8, int32, int64:
+ return false
+ case uint, uint8, uint32, uint64:
+ return false
+ }
+
+ return math.IsNaN(value.float64())
+}
+
+// IsString will return true if value is a string (primitive).
+func (value Value) IsString() bool {
+ return value.kind == valueString
+}
+
+// IsObject will return true if value is an object.
+func (value Value) IsObject() bool {
+ return value.kind == valueObject
+}
+
+// IsFunction will return true if value is a function.
+func (value Value) IsFunction() bool {
+ if value.kind != valueObject {
+ return false
+ }
+ return value.value.(*_object).class == "Function"
+}
+
+// Class will return the class string of the value or the empty string if value is not an object.
+//
+// The return value will (generally) be one of:
+//
+// Object
+// Function
+// Array
+// String
+// Number
+// Boolean
+// Date
+// RegExp
+//
+func (value Value) Class() string {
+ if value.kind != valueObject {
+ return ""
+ }
+ return value.value.(*_object).class
+}
+
+func (value Value) isArray() bool {
+ if value.kind != valueObject {
+ return false
+ }
+ return isArray(value.value.(*_object))
+}
+
+func (value Value) isStringObject() bool {
+ if value.kind != valueObject {
+ return false
+ }
+ return value.value.(*_object).class == "String"
+}
+
+func (value Value) isBooleanObject() bool {
+ if value.kind != valueObject {
+ return false
+ }
+ return value.value.(*_object).class == "Boolean"
+}
+
+func (value Value) isNumberObject() bool {
+ if value.kind != valueObject {
+ return false
+ }
+ return value.value.(*_object).class == "Number"
+}
+
+func (value Value) isDate() bool {
+ if value.kind != valueObject {
+ return false
+ }
+ return value.value.(*_object).class == "Date"
+}
+
+func (value Value) isRegExp() bool {
+ if value.kind != valueObject {
+ return false
+ }
+ return value.value.(*_object).class == "RegExp"
+}
+
+func (value Value) isError() bool {
+ if value.kind != valueObject {
+ return false
+ }
+ return value.value.(*_object).class == "Error"
+}
+
+// ---
+
+func toValue_reflectValuePanic(value interface{}, kind reflect.Kind) {
+ // FIXME?
+ switch kind {
+ case reflect.Struct:
+ panic(newError(nil, "TypeError", "invalid value (struct): missing runtime: %v (%T)", value, value))
+ case reflect.Map:
+ panic(newError(nil, "TypeError", "invalid value (map): missing runtime: %v (%T)", value, value))
+ case reflect.Slice:
+ panic(newError(nil, "TypeError", "invalid value (slice): missing runtime: %v (%T)", value, value))
+ }
+}
+
+func toValue(value interface{}) Value {
+ switch value := value.(type) {
+ case Value:
+ return value
+ case bool:
+ return Value{valueBoolean, value}
+ case int:
+ return Value{valueNumber, value}
+ case int8:
+ return Value{valueNumber, value}
+ case int16:
+ return Value{valueNumber, value}
+ case int32:
+ return Value{valueNumber, value}
+ case int64:
+ return Value{valueNumber, value}
+ case uint:
+ return Value{valueNumber, value}
+ case uint8:
+ return Value{valueNumber, value}
+ case uint16:
+ return Value{valueNumber, value}
+ case uint32:
+ return Value{valueNumber, value}
+ case uint64:
+ return Value{valueNumber, value}
+ case float32:
+ return Value{valueNumber, float64(value)}
+ case float64:
+ return Value{valueNumber, value}
+ case []uint16:
+ return Value{valueString, value}
+ case string:
+ return Value{valueString, value}
+ // A rune is actually an int32, which is handled above
+ case *_object:
+ return Value{valueObject, value}
+ case *Object:
+ return Value{valueObject, value.object}
+ case Object:
+ return Value{valueObject, value.object}
+ case _reference: // reference is an interface (already a pointer)
+ return Value{valueReference, value}
+ case _result:
+ return Value{valueResult, value}
+ case nil:
+ // TODO Ugh.
+ return Value{}
+ case reflect.Value:
+ for value.Kind() == reflect.Ptr {
+ // We were given a pointer, so we'll drill down until we get a non-pointer
+ //
+ // These semantics might change if we want to start supporting pointers to values transparently
+ // (It would be best not to depend on this behavior)
+ // FIXME: UNDEFINED
+ if value.IsNil() {
+ return Value{}
+ }
+ value = value.Elem()
+ }
+ switch value.Kind() {
+ case reflect.Bool:
+ return Value{valueBoolean, bool(value.Bool())}
+ case reflect.Int:
+ return Value{valueNumber, int(value.Int())}
+ case reflect.Int8:
+ return Value{valueNumber, int8(value.Int())}
+ case reflect.Int16:
+ return Value{valueNumber, int16(value.Int())}
+ case reflect.Int32:
+ return Value{valueNumber, int32(value.Int())}
+ case reflect.Int64:
+ return Value{valueNumber, int64(value.Int())}
+ case reflect.Uint:
+ return Value{valueNumber, uint(value.Uint())}
+ case reflect.Uint8:
+ return Value{valueNumber, uint8(value.Uint())}
+ case reflect.Uint16:
+ return Value{valueNumber, uint16(value.Uint())}
+ case reflect.Uint32:
+ return Value{valueNumber, uint32(value.Uint())}
+ case reflect.Uint64:
+ return Value{valueNumber, uint64(value.Uint())}
+ case reflect.Float32:
+ return Value{valueNumber, float32(value.Float())}
+ case reflect.Float64:
+ return Value{valueNumber, float64(value.Float())}
+ case reflect.String:
+ return Value{valueString, string(value.String())}
+ default:
+ toValue_reflectValuePanic(value.Interface(), value.Kind())
+ }
+ default:
+ return toValue(reflect.ValueOf(value))
+ }
+ // FIXME?
+ panic(newError(nil, "TypeError", "invalid value: %v (%T)", value, value))
+}
+
+// String will return the value as a string.
+//
+// This method will make return the empty string if there is an error.
+func (value Value) String() string {
+ result := ""
+ catchPanic(func() {
+ result = value.string()
+ })
+ return result
+}
+
+// ToBoolean will convert the value to a boolean (bool).
+//
+// ToValue(0).ToBoolean() => false
+// ToValue("").ToBoolean() => false
+// ToValue(true).ToBoolean() => true
+// ToValue(1).ToBoolean() => true
+// ToValue("Nothing happens").ToBoolean() => true
+//
+// If there is an error during the conversion process (like an uncaught exception), then the result will be false and an error.
+func (value Value) ToBoolean() (bool, error) {
+ result := false
+ err := catchPanic(func() {
+ result = value.bool()
+ })
+ return result, err
+}
+
+func (value Value) numberValue() Value {
+ if value.kind == valueNumber {
+ return value
+ }
+ return Value{valueNumber, value.float64()}
+}
+
+// ToFloat will convert the value to a number (float64).
+//
+// ToValue(0).ToFloat() => 0.
+// ToValue(1.1).ToFloat() => 1.1
+// ToValue("11").ToFloat() => 11.
+//
+// If there is an error during the conversion process (like an uncaught exception), then the result will be 0 and an error.
+func (value Value) ToFloat() (float64, error) {
+ result := float64(0)
+ err := catchPanic(func() {
+ result = value.float64()
+ })
+ return result, err
+}
+
+// ToInteger will convert the value to a number (int64).
+//
+// ToValue(0).ToInteger() => 0
+// ToValue(1.1).ToInteger() => 1
+// ToValue("11").ToInteger() => 11
+//
+// If there is an error during the conversion process (like an uncaught exception), then the result will be 0 and an error.
+func (value Value) ToInteger() (int64, error) {
+ result := int64(0)
+ err := catchPanic(func() {
+ result = value.number().int64
+ })
+ return result, err
+}
+
+// ToString will convert the value to a string (string).
+//
+// ToValue(0).ToString() => "0"
+// ToValue(false).ToString() => "false"
+// ToValue(1.1).ToString() => "1.1"
+// ToValue("11").ToString() => "11"
+// ToValue('Nothing happens.').ToString() => "Nothing happens."
+//
+// If there is an error during the conversion process (like an uncaught exception), then the result will be the empty string ("") and an error.
+func (value Value) ToString() (string, error) {
+ result := ""
+ err := catchPanic(func() {
+ result = value.string()
+ })
+ return result, err
+}
+
+func (value Value) _object() *_object {
+ switch value := value.value.(type) {
+ case *_object:
+ return value
+ }
+ return nil
+}
+
+// Object will return the object of the value, or nil if value is not an object.
+//
+// This method will not do any implicit conversion. For example, calling this method on a string primitive value will not return a String object.
+func (value Value) Object() *Object {
+ switch object := value.value.(type) {
+ case *_object:
+ return _newObject(object, value)
+ }
+ return nil
+}
+
+func (value Value) reference() _reference {
+ switch value := value.value.(type) {
+ case _reference:
+ return value
+ }
+ return nil
+}
+
+func (value Value) resolve() Value {
+ switch value := value.value.(type) {
+ case _reference:
+ return value.getValue()
+ }
+ return value
+}
+
+var (
+ __NaN__ float64 = math.NaN()
+ __PositiveInfinity__ float64 = math.Inf(+1)
+ __NegativeInfinity__ float64 = math.Inf(-1)
+ __PositiveZero__ float64 = 0
+ __NegativeZero__ float64 = math.Float64frombits(0 | (1 << 63))
+)
+
+func positiveInfinity() float64 {
+ return __PositiveInfinity__
+}
+
+func negativeInfinity() float64 {
+ return __NegativeInfinity__
+}
+
+func positiveZero() float64 {
+ return __PositiveZero__
+}
+
+func negativeZero() float64 {
+ return __NegativeZero__
+}
+
+// NaNValue will return a value representing NaN.
+//
+// It is equivalent to:
+//
+// ToValue(math.NaN())
+//
+func NaNValue() Value {
+ return Value{valueNumber, __NaN__}
+}
+
+func positiveInfinityValue() Value {
+ return Value{valueNumber, __PositiveInfinity__}
+}
+
+func negativeInfinityValue() Value {
+ return Value{valueNumber, __NegativeInfinity__}
+}
+
+func positiveZeroValue() Value {
+ return Value{valueNumber, __PositiveZero__}
+}
+
+func negativeZeroValue() Value {
+ return Value{valueNumber, __NegativeZero__}
+}
+
+// TrueValue will return a value representing true.
+//
+// It is equivalent to:
+//
+// ToValue(true)
+//
+func TrueValue() Value {
+ return Value{valueBoolean, true}
+}
+
+// FalseValue will return a value representing false.
+//
+// It is equivalent to:
+//
+// ToValue(false)
+//
+func FalseValue() Value {
+ return Value{valueBoolean, false}
+}
+
+func sameValue(x Value, y Value) bool {
+ if x.kind != y.kind {
+ return false
+ }
+ result := false
+ switch x.kind {
+ case valueUndefined, valueNull:
+ result = true
+ case valueNumber:
+ x := x.float64()
+ y := y.float64()
+ if math.IsNaN(x) && math.IsNaN(y) {
+ result = true
+ } else {
+ result = x == y
+ if result && x == 0 {
+ // Since +0 != -0
+ result = math.Signbit(x) == math.Signbit(y)
+ }
+ }
+ case valueString:
+ result = x.string() == y.string()
+ case valueBoolean:
+ result = x.bool() == y.bool()
+ case valueObject:
+ result = x._object() == y._object()
+ default:
+ panic(hereBeDragons())
+ }
+
+ return result
+}
+
+func strictEqualityComparison(x Value, y Value) bool {
+ if x.kind != y.kind {
+ return false
+ }
+ result := false
+ switch x.kind {
+ case valueUndefined, valueNull:
+ result = true
+ case valueNumber:
+ x := x.float64()
+ y := y.float64()
+ if math.IsNaN(x) && math.IsNaN(y) {
+ result = false
+ } else {
+ result = x == y
+ }
+ case valueString:
+ result = x.string() == y.string()
+ case valueBoolean:
+ result = x.bool() == y.bool()
+ case valueObject:
+ result = x._object() == y._object()
+ default:
+ panic(hereBeDragons())
+ }
+
+ return result
+}
+
+// Export will attempt to convert the value to a Go representation
+// and return it via an interface{} kind.
+//
+// Export returns an error, but it will always be nil. It is present
+// for backwards compatibility.
+//
+// If a reasonable conversion is not possible, then the original
+// value is returned.
+//
+// undefined -> nil (FIXME?: Should be Value{})
+// null -> nil
+// boolean -> bool
+// number -> A number type (int, float32, uint64, ...)
+// string -> string
+// Array -> []interface{}
+// Object -> map[string]interface{}
+//
+func (self Value) Export() (interface{}, error) {
+ return self.export(), nil
+}
+
+func (self Value) export() interface{} {
+
+ switch self.kind {
+ case valueUndefined:
+ return nil
+ case valueNull:
+ return nil
+ case valueNumber, valueBoolean:
+ return self.value
+ case valueString:
+ switch value := self.value.(type) {
+ case string:
+ return value
+ case []uint16:
+ return string(utf16.Decode(value))
+ }
+ case valueObject:
+ object := self._object()
+ switch value := object.value.(type) {
+ case *_goStructObject:
+ return value.value.Interface()
+ case *_goMapObject:
+ return value.value.Interface()
+ case *_goArrayObject:
+ return value.value.Interface()
+ case *_goSliceObject:
+ return value.value.Interface()
+ }
+ if object.class == "Array" {
+ result := make([]interface{}, 0)
+ lengthValue := object.get("length")
+ length := lengthValue.value.(uint32)
+ for index := uint32(0); index < length; index += 1 {
+ name := strconv.FormatInt(int64(index), 10)
+ if !object.hasProperty(name) {
+ continue
+ }
+ value := object.get(name)
+ result = append(result, value.export())
+ }
+ return result
+ } else {
+ result := make(map[string]interface{})
+ // TODO Should we export everything? Or just what is enumerable?
+ object.enumerate(false, func(name string) bool {
+ value := object.get(name)
+ if value.IsDefined() {
+ result[name] = value.export()
+ }
+ return true
+ })
+ return result
+ }
+ }
+
+ if self.safe() {
+ return self
+ }
+
+ return Value{}
+}
+
+func (self Value) evaluateBreakContinue(labels []string) _resultKind {
+ result := self.value.(_result)
+ if result.kind == resultBreak || result.kind == resultContinue {
+ for _, label := range labels {
+ if label == result.target {
+ return result.kind
+ }
+ }
+ }
+ return resultReturn
+}
+
+func (self Value) evaluateBreak(labels []string) _resultKind {
+ result := self.value.(_result)
+ if result.kind == resultBreak {
+ for _, label := range labels {
+ if label == result.target {
+ return result.kind
+ }
+ }
+ }
+ return resultReturn
+}
+
+func (self Value) exportNative() interface{} {
+
+ switch self.kind {
+ case valueUndefined:
+ return self
+ case valueNull:
+ return nil
+ case valueNumber, valueBoolean:
+ return self.value
+ case valueString:
+ switch value := self.value.(type) {
+ case string:
+ return value
+ case []uint16:
+ return string(utf16.Decode(value))
+ }
+ case valueObject:
+ object := self._object()
+ switch value := object.value.(type) {
+ case *_goStructObject:
+ return value.value.Interface()
+ case *_goMapObject:
+ return value.value.Interface()
+ case *_goArrayObject:
+ return value.value.Interface()
+ case *_goSliceObject:
+ return value.value.Interface()
+ }
+ }
+
+ return self
+}
+
+// Make a best effort to return a reflect.Value corresponding to reflect.Kind, but
+// fallback to just returning the Go value we have handy.
+func (value Value) toReflectValue(kind reflect.Kind) (reflect.Value, error) {
+ switch kind {
+ case reflect.Bool: // Bool
+ return reflect.ValueOf(value.bool()), nil
+ case reflect.Int: // Int
+ // We convert to float64 here because converting to int64 will not tell us
+ // if a value is outside the range of int64
+ tmp := toIntegerFloat(value)
+ if tmp < float_minInt || tmp > float_maxInt {
+ return reflect.Value{}, fmt.Errorf("RangeError: %f (%v) to int", tmp, value)
+ } else {
+ return reflect.ValueOf(int(tmp)), nil
+ }
+ case reflect.Int8: // Int8
+ tmp := value.number().int64
+ if tmp < int64_minInt8 || tmp > int64_maxInt8 {
+ return reflect.Value{}, fmt.Errorf("RangeError: %d (%v) to int8", tmp, value)
+ } else {
+ return reflect.ValueOf(int8(tmp)), nil
+ }
+ case reflect.Int16: // Int16
+ tmp := value.number().int64
+ if tmp < int64_minInt16 || tmp > int64_maxInt16 {
+ return reflect.Value{}, fmt.Errorf("RangeError: %d (%v) to int16", tmp, value)
+ } else {
+ return reflect.ValueOf(int16(tmp)), nil
+ }
+ case reflect.Int32: // Int32
+ tmp := value.number().int64
+ if tmp < int64_minInt32 || tmp > int64_maxInt32 {
+ return reflect.Value{}, fmt.Errorf("RangeError: %d (%v) to int32", tmp, value)
+ } else {
+ return reflect.ValueOf(int32(tmp)), nil
+ }
+ case reflect.Int64: // Int64
+ // We convert to float64 here because converting to int64 will not tell us
+ // if a value is outside the range of int64
+ tmp := toIntegerFloat(value)
+ if tmp < float_minInt64 || tmp > float_maxInt64 {
+ return reflect.Value{}, fmt.Errorf("RangeError: %f (%v) to int", tmp, value)
+ } else {
+ return reflect.ValueOf(int64(tmp)), nil
+ }
+ case reflect.Uint: // Uint
+ // We convert to float64 here because converting to int64 will not tell us
+ // if a value is outside the range of uint
+ tmp := toIntegerFloat(value)
+ if tmp < 0 || tmp > float_maxUint {
+ return reflect.Value{}, fmt.Errorf("RangeError: %f (%v) to uint", tmp, value)
+ } else {
+ return reflect.ValueOf(uint(tmp)), nil
+ }
+ case reflect.Uint8: // Uint8
+ tmp := value.number().int64
+ if tmp < 0 || tmp > int64_maxUint8 {
+ return reflect.Value{}, fmt.Errorf("RangeError: %d (%v) to uint8", tmp, value)
+ } else {
+ return reflect.ValueOf(uint8(tmp)), nil
+ }
+ case reflect.Uint16: // Uint16
+ tmp := value.number().int64
+ if tmp < 0 || tmp > int64_maxUint16 {
+ return reflect.Value{}, fmt.Errorf("RangeError: %d (%v) to uint16", tmp, value)
+ } else {
+ return reflect.ValueOf(uint16(tmp)), nil
+ }
+ case reflect.Uint32: // Uint32
+ tmp := value.number().int64
+ if tmp < 0 || tmp > int64_maxUint32 {
+ return reflect.Value{}, fmt.Errorf("RangeError: %d (%v) to uint32", tmp, value)
+ } else {
+ return reflect.ValueOf(uint32(tmp)), nil
+ }
+ case reflect.Uint64: // Uint64
+ // We convert to float64 here because converting to int64 will not tell us
+ // if a value is outside the range of uint64
+ tmp := toIntegerFloat(value)
+ if tmp < 0 || tmp > float_maxUint64 {
+ return reflect.Value{}, fmt.Errorf("RangeError: %f (%v) to uint64", tmp, value)
+ } else {
+ return reflect.ValueOf(uint64(tmp)), nil
+ }
+ case reflect.Float32: // Float32
+ tmp := value.float64()
+ tmp1 := tmp
+ if 0 > tmp1 {
+ tmp1 = -tmp1
+ }
+ if tmp1 < math.SmallestNonzeroFloat32 || tmp1 > math.MaxFloat32 {
+ return reflect.Value{}, fmt.Errorf("RangeError: %f (%v) to float32", tmp, value)
+ } else {
+ return reflect.ValueOf(float32(tmp)), nil
+ }
+ case reflect.Float64: // Float64
+ value := value.float64()
+ return reflect.ValueOf(float64(value)), nil
+ case reflect.String: // String
+ return reflect.ValueOf(value.string()), nil
+ case reflect.Invalid: // Invalid
+ case reflect.Complex64: // FIXME? Complex64
+ case reflect.Complex128: // FIXME? Complex128
+ case reflect.Chan: // FIXME? Chan
+ case reflect.Func: // FIXME? Func
+ case reflect.Ptr: // FIXME? Ptr
+ case reflect.UnsafePointer: // FIXME? UnsafePointer
+ default:
+ switch value.kind {
+ case valueObject:
+ object := value._object()
+ switch vl := object.value.(type) {
+ case *_goStructObject: // Struct
+ return reflect.ValueOf(vl.value.Interface()), nil
+ case *_goMapObject: // Map
+ return reflect.ValueOf(vl.value.Interface()), nil
+ case *_goArrayObject: // Array
+ return reflect.ValueOf(vl.value.Interface()), nil
+ case *_goSliceObject: // Slice
+ return reflect.ValueOf(vl.value.Interface()), nil
+ }
+ return reflect.ValueOf(value.exportNative()), nil
+ case valueEmpty, valueResult, valueReference:
+ // These are invalid, and should panic
+ default:
+ return reflect.ValueOf(value.value), nil
+ }
+ }
+
+ // FIXME Should this end up as a TypeError?
+ panic(fmt.Errorf("invalid conversion of %v (%v) to reflect.Kind: %v", value.kind, value, kind))
+}
+
+func stringToReflectValue(value string, kind reflect.Kind) (reflect.Value, error) {
+ switch kind {
+ case reflect.Bool:
+ value, err := strconv.ParseBool(value)
+ if err != nil {
+ return reflect.Value{}, err
+ }
+ return reflect.ValueOf(value), nil
+ case reflect.Int:
+ value, err := strconv.ParseInt(value, 0, 0)
+ if err != nil {
+ return reflect.Value{}, err
+ }
+ return reflect.ValueOf(int(value)), nil
+ case reflect.Int8:
+ value, err := strconv.ParseInt(value, 0, 8)
+ if err != nil {
+ return reflect.Value{}, err
+ }
+ return reflect.ValueOf(int8(value)), nil
+ case reflect.Int16:
+ value, err := strconv.ParseInt(value, 0, 16)
+ if err != nil {
+ return reflect.Value{}, err
+ }
+ return reflect.ValueOf(int16(value)), nil
+ case reflect.Int32:
+ value, err := strconv.ParseInt(value, 0, 32)
+ if err != nil {
+ return reflect.Value{}, err
+ }
+ return reflect.ValueOf(int32(value)), nil
+ case reflect.Int64:
+ value, err := strconv.ParseInt(value, 0, 64)
+ if err != nil {
+ return reflect.Value{}, err
+ }
+ return reflect.ValueOf(int64(value)), nil
+ case reflect.Uint:
+ value, err := strconv.ParseUint(value, 0, 0)
+ if err != nil {
+ return reflect.Value{}, err
+ }
+ return reflect.ValueOf(uint(value)), nil
+ case reflect.Uint8:
+ value, err := strconv.ParseUint(value, 0, 8)
+ if err != nil {
+ return reflect.Value{}, err
+ }
+ return reflect.ValueOf(uint8(value)), nil
+ case reflect.Uint16:
+ value, err := strconv.ParseUint(value, 0, 16)
+ if err != nil {
+ return reflect.Value{}, err
+ }
+ return reflect.ValueOf(uint16(value)), nil
+ case reflect.Uint32:
+ value, err := strconv.ParseUint(value, 0, 32)
+ if err != nil {
+ return reflect.Value{}, err
+ }
+ return reflect.ValueOf(uint32(value)), nil
+ case reflect.Uint64:
+ value, err := strconv.ParseUint(value, 0, 64)
+ if err != nil {
+ return reflect.Value{}, err
+ }
+ return reflect.ValueOf(uint64(value)), nil
+ case reflect.Float32:
+ value, err := strconv.ParseFloat(value, 32)
+ if err != nil {
+ return reflect.Value{}, err
+ }
+ return reflect.ValueOf(float32(value)), nil
+ case reflect.Float64:
+ value, err := strconv.ParseFloat(value, 64)
+ if err != nil {
+ return reflect.Value{}, err
+ }
+ return reflect.ValueOf(float64(value)), nil
+ case reflect.String:
+ return reflect.ValueOf(value), nil
+ }
+
+ // FIXME This should end up as a TypeError?
+ panic(fmt.Errorf("invalid conversion of %q to reflect.Kind: %v", value, kind))
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/value_boolean.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/value_boolean.go
new file mode 100644
index 000000000..3040f4163
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/value_boolean.go
@@ -0,0 +1,40 @@
+package otto
+
+import (
+ "fmt"
+ "math"
+ "reflect"
+)
+
+func (value Value) bool() bool {
+ if value.kind == valueBoolean {
+ return value.value.(bool)
+ }
+ if value.IsUndefined() {
+ return false
+ }
+ if value.IsNull() {
+ return false
+ }
+ switch value := value.value.(type) {
+ case bool:
+ return value
+ case int, int8, int16, int32, int64:
+ return 0 != reflect.ValueOf(value).Int()
+ case uint, uint8, uint16, uint32, uint64:
+ return 0 != reflect.ValueOf(value).Uint()
+ case float32:
+ return 0 != value
+ case float64:
+ if math.IsNaN(value) || value == 0 {
+ return false
+ }
+ return true
+ case string:
+ return 0 != len(value)
+ }
+ if value.IsObject() {
+ return true
+ }
+ panic(fmt.Errorf("toBoolean(%T)", value.value))
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/value_number.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/value_number.go
new file mode 100644
index 000000000..54996c729
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/value_number.go
@@ -0,0 +1,324 @@
+package otto
+
+import (
+ "fmt"
+ "math"
+ "regexp"
+ "strconv"
+ "strings"
+)
+
+var stringToNumberParseInteger = regexp.MustCompile(`^(?:0[xX])`)
+
+func parseNumber(value string) float64 {
+ value = strings.TrimSpace(value)
+
+ if value == "" {
+ return 0
+ }
+
+ parseFloat := false
+ if strings.IndexRune(value, '.') != -1 {
+ parseFloat = true
+ } else if stringToNumberParseInteger.MatchString(value) {
+ parseFloat = false
+ } else {
+ parseFloat = true
+ }
+
+ if parseFloat {
+ number, err := strconv.ParseFloat(value, 64)
+ if err != nil && err.(*strconv.NumError).Err != strconv.ErrRange {
+ return math.NaN()
+ }
+ return number
+ }
+
+ number, err := strconv.ParseInt(value, 0, 64)
+ if err != nil {
+ return math.NaN()
+ }
+ return float64(number)
+}
+
+func (value Value) float64() float64 {
+ switch value.kind {
+ case valueUndefined:
+ return math.NaN()
+ case valueNull:
+ return 0
+ }
+ switch value := value.value.(type) {
+ case bool:
+ if value {
+ return 1
+ }
+ return 0
+ case int:
+ return float64(value)
+ case int8:
+ return float64(value)
+ case int16:
+ return float64(value)
+ case int32:
+ return float64(value)
+ case int64:
+ return float64(value)
+ case uint:
+ return float64(value)
+ case uint8:
+ return float64(value)
+ case uint16:
+ return float64(value)
+ case uint32:
+ return float64(value)
+ case uint64:
+ return float64(value)
+ case float64:
+ return value
+ case string:
+ return parseNumber(value)
+ case *_object:
+ return value.DefaultValue(defaultValueHintNumber).float64()
+ }
+ panic(fmt.Errorf("toFloat(%T)", value.value))
+}
+
+const (
+ float_2_64 float64 = 18446744073709551616.0
+ float_2_63 float64 = 9223372036854775808.0
+ float_2_32 float64 = 4294967296.0
+ float_2_31 float64 = 2147483648.0
+ float_2_16 float64 = 65536.0
+ integer_2_32 int64 = 4294967296
+ integer_2_31 int64 = 2146483648
+ sqrt1_2 float64 = math.Sqrt2 / 2
+)
+
+const (
+ maxInt8 = math.MaxInt8
+ minInt8 = math.MinInt8
+ maxInt16 = math.MaxInt16
+ minInt16 = math.MinInt16
+ maxInt32 = math.MaxInt32
+ minInt32 = math.MinInt32
+ maxInt64 = math.MaxInt64
+ minInt64 = math.MinInt64
+ maxUint8 = math.MaxUint8
+ maxUint16 = math.MaxUint16
+ maxUint32 = math.MaxUint32
+ maxUint64 = math.MaxUint64
+ maxUint = ^uint(0)
+ minUint = 0
+ maxInt = int(^uint(0) >> 1)
+ minInt = -maxInt - 1
+
+ // int64
+ int64_maxInt int64 = int64(maxInt)
+ int64_minInt int64 = int64(minInt)
+ int64_maxInt8 int64 = math.MaxInt8
+ int64_minInt8 int64 = math.MinInt8
+ int64_maxInt16 int64 = math.MaxInt16
+ int64_minInt16 int64 = math.MinInt16
+ int64_maxInt32 int64 = math.MaxInt32
+ int64_minInt32 int64 = math.MinInt32
+ int64_maxUint8 int64 = math.MaxUint8
+ int64_maxUint16 int64 = math.MaxUint16
+ int64_maxUint32 int64 = math.MaxUint32
+
+ // float64
+ float_maxInt float64 = float64(int(^uint(0) >> 1))
+ float_minInt float64 = float64(int(-maxInt - 1))
+ float_minUint float64 = float64(0)
+ float_maxUint float64 = float64(uint(^uint(0)))
+ float_minUint64 float64 = float64(0)
+ float_maxUint64 float64 = math.MaxUint64
+ float_maxInt64 float64 = math.MaxInt64
+ float_minInt64 float64 = math.MinInt64
+)
+
+func toIntegerFloat(value Value) float64 {
+ float := value.float64()
+ if math.IsInf(float, 0) {
+ } else if math.IsNaN(float) {
+ float = 0
+ } else if float > 0 {
+ float = math.Floor(float)
+ } else {
+ float = math.Ceil(float)
+ }
+ return float
+}
+
+type _numberKind int
+
+const (
+ numberInteger _numberKind = iota // 3.0 => 3.0
+ numberFloat // 3.14159 => 3.0, 1+2**63 > 2**63-1
+ numberInfinity // Infinity => 2**63-1
+ numberNaN // NaN => 0
+)
+
+type _number struct {
+ kind _numberKind
+ int64 int64
+ float64 float64
+}
+
+// FIXME
+// http://www.goinggo.net/2013/08/gustavos-ieee-754-brain-teaser.html
+// http://bazaar.launchpad.net/~niemeyer/strepr/trunk/view/6/strepr.go#L160
+func (vl Value) number() (number _number) {
+ switch vl := vl.value.(type) {
+ case int8:
+ number.int64 = int64(vl)
+ return
+ case int16:
+ number.int64 = int64(vl)
+ return
+ case uint8:
+ number.int64 = int64(vl)
+ return
+ case uint16:
+ number.int64 = int64(vl)
+ return
+ case uint32:
+ number.int64 = int64(vl)
+ return
+ case int:
+ number.int64 = int64(vl)
+ return
+ case int64:
+ number.int64 = vl
+ return
+ }
+
+ float := vl.float64()
+ if float == 0 {
+ return
+ }
+
+ number.kind = numberFloat
+ number.float64 = float
+
+ if math.IsNaN(float) {
+ number.kind = numberNaN
+ return
+ }
+
+ if math.IsInf(float, 0) {
+ number.kind = numberInfinity
+ }
+
+ if float >= float_maxInt64 {
+ number.int64 = math.MaxInt64
+ return
+ }
+
+ if float <= float_minInt64 {
+ number.int64 = math.MinInt64
+ return
+ }
+
+ integer := float64(0)
+ if float > 0 {
+ integer = math.Floor(float)
+ } else {
+ integer = math.Ceil(float)
+ }
+
+ if float == integer {
+ number.kind = numberInteger
+ }
+ number.int64 = int64(float)
+ return
+}
+
+// ECMA 262: 9.5
+func toInt32(value Value) int32 {
+ {
+ switch value := value.value.(type) {
+ case int8:
+ return int32(value)
+ case int16:
+ return int32(value)
+ case int32:
+ return value
+ }
+ }
+ floatValue := value.float64()
+ if math.IsNaN(floatValue) || math.IsInf(floatValue, 0) {
+ return 0
+ }
+ if floatValue == 0 { // This will work for +0 & -0
+ return 0
+ }
+ remainder := math.Mod(floatValue, float_2_32)
+ if remainder > 0 {
+ remainder = math.Floor(remainder)
+ } else {
+ remainder = math.Ceil(remainder) + float_2_32
+ }
+ if remainder > float_2_31 {
+ return int32(remainder - float_2_32)
+ }
+ return int32(remainder)
+}
+
+func toUint32(value Value) uint32 {
+ {
+ switch value := value.value.(type) {
+ case int8:
+ return uint32(value)
+ case int16:
+ return uint32(value)
+ case uint8:
+ return uint32(value)
+ case uint16:
+ return uint32(value)
+ case uint32:
+ return value
+ }
+ }
+ floatValue := value.float64()
+ if math.IsNaN(floatValue) || math.IsInf(floatValue, 0) {
+ return 0
+ }
+ if floatValue == 0 {
+ return 0
+ }
+ remainder := math.Mod(floatValue, float_2_32)
+ if remainder > 0 {
+ remainder = math.Floor(remainder)
+ } else {
+ remainder = math.Ceil(remainder) + float_2_32
+ }
+ return uint32(remainder)
+}
+
+func toUint16(value Value) uint16 {
+ {
+ switch value := value.value.(type) {
+ case int8:
+ return uint16(value)
+ case uint8:
+ return uint16(value)
+ case uint16:
+ return value
+ }
+ }
+ floatValue := value.float64()
+ if math.IsNaN(floatValue) || math.IsInf(floatValue, 0) {
+ return 0
+ }
+ if floatValue == 0 {
+ return 0
+ }
+ remainder := math.Mod(floatValue, float_2_16)
+ if remainder > 0 {
+ remainder = math.Floor(remainder)
+ } else {
+ remainder = math.Ceil(remainder) + float_2_16
+ }
+ return uint16(remainder)
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/value_primitive.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/value_primitive.go
new file mode 100644
index 000000000..11ed329d1
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/value_primitive.go
@@ -0,0 +1,23 @@
+package otto
+
+func toStringPrimitive(value Value) Value {
+ return _toPrimitive(value, defaultValueHintString)
+}
+
+func toNumberPrimitive(value Value) Value {
+ return _toPrimitive(value, defaultValueHintNumber)
+}
+
+func toPrimitive(value Value) Value {
+ return _toPrimitive(value, defaultValueNoHint)
+}
+
+func _toPrimitive(value Value, hint _defaultValueHint) Value {
+ switch value.kind {
+ case valueNull, valueUndefined, valueNumber, valueString, valueBoolean:
+ return value
+ case valueObject:
+ return value._object().DefaultValue(hint)
+ }
+ panic(hereBeDragons(value.kind, value))
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/value_string.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/value_string.go
new file mode 100644
index 000000000..0fbfd6b25
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/value_string.go
@@ -0,0 +1,103 @@
+package otto
+
+import (
+ "fmt"
+ "math"
+ "regexp"
+ "strconv"
+ "unicode/utf16"
+)
+
+var matchLeading0Exponent = regexp.MustCompile(`([eE][\+\-])0+([1-9])`) // 1e-07 => 1e-7
+
+// FIXME
+// https://code.google.com/p/v8/source/browse/branches/bleeding_edge/src/conversions.cc?spec=svn18082&r=18082
+func floatToString(value float64, bitsize int) string {
+ // TODO Fit to ECMA-262 9.8.1 specification
+ if math.IsNaN(value) {
+ return "NaN"
+ } else if math.IsInf(value, 0) {
+ if math.Signbit(value) {
+ return "-Infinity"
+ }
+ return "Infinity"
+ }
+ exponent := math.Log10(math.Abs(value))
+ if exponent >= 21 || exponent < -6 {
+ return matchLeading0Exponent.ReplaceAllString(strconv.FormatFloat(value, 'g', -1, bitsize), "$1$2")
+ }
+ return strconv.FormatFloat(value, 'f', -1, bitsize)
+}
+
+func numberToStringRadix(value Value, radix int) string {
+ float := value.float64()
+ if math.IsNaN(float) {
+ return "NaN"
+ } else if math.IsInf(float, 1) {
+ return "Infinity"
+ } else if math.IsInf(float, -1) {
+ return "-Infinity"
+ }
+ // FIXME This is very broken
+ // Need to do proper radix conversion for floats, ...
+ // This truncates large floats (so bad).
+ return strconv.FormatInt(int64(float), radix)
+}
+
+func (value Value) string() string {
+ if value.kind == valueString {
+ switch value := value.value.(type) {
+ case string:
+ return value
+ case []uint16:
+ return string(utf16.Decode(value))
+ }
+ }
+ if value.IsUndefined() {
+ return "undefined"
+ }
+ if value.IsNull() {
+ return "null"
+ }
+ switch value := value.value.(type) {
+ case bool:
+ return strconv.FormatBool(value)
+ case int:
+ return strconv.FormatInt(int64(value), 10)
+ case int8:
+ return strconv.FormatInt(int64(value), 10)
+ case int16:
+ return strconv.FormatInt(int64(value), 10)
+ case int32:
+ return strconv.FormatInt(int64(value), 10)
+ case int64:
+ return strconv.FormatInt(value, 10)
+ case uint:
+ return strconv.FormatUint(uint64(value), 10)
+ case uint8:
+ return strconv.FormatUint(uint64(value), 10)
+ case uint16:
+ return strconv.FormatUint(uint64(value), 10)
+ case uint32:
+ return strconv.FormatUint(uint64(value), 10)
+ case uint64:
+ return strconv.FormatUint(value, 10)
+ case float32:
+ if value == 0 {
+ return "0" // Take care not to return -0
+ }
+ return floatToString(float64(value), 32)
+ case float64:
+ if value == 0 {
+ return "0" // Take care not to return -0
+ }
+ return floatToString(value, 64)
+ case []uint16:
+ return string(utf16.Decode(value))
+ case string:
+ return value
+ case *_object:
+ return value.DefaultValue(defaultValueHintString).string()
+ }
+ panic(fmt.Errorf("%v.string( %T)", value.value, value.value))
+}
diff --git a/Godeps/_workspace/src/github.com/robertkrimen/otto/value_test.go b/Godeps/_workspace/src/github.com/robertkrimen/otto/value_test.go
new file mode 100644
index 000000000..4a9bd546f
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/robertkrimen/otto/value_test.go
@@ -0,0 +1,281 @@
+package otto
+
+import (
+ "encoding/json"
+ "math"
+ "testing"
+)
+
+func TestValue(t *testing.T) {
+ tt(t, func() {
+ value := UndefinedValue()
+ is(value.IsUndefined(), true)
+ is(value, UndefinedValue())
+ is(value, "undefined")
+
+ is(toValue(false), false)
+ is(toValue(1), 1)
+ is(toValue(1).float64(), float64(1))
+ })
+}
+
+func TestObject(t *testing.T) {
+ tt(t, func() {
+ is(emptyValue.isEmpty(), true)
+ //is(newObject().Value(), "[object]")
+ //is(newBooleanObject(false).Value(), "false")
+ //is(newFunctionObject(nil).Value(), "[function]")
+ //is(newNumberObject(1).Value(), "1")
+ //is(newStringObject("Hello, World.").Value(), "Hello, World.")
+ })
+}
+
+type intAlias int
+
+func TestToValue(t *testing.T) {
+ tt(t, func() {
+ _, tester := test()
+ vm := tester.vm
+
+ value, _ := vm.ToValue(nil)
+ is(value, "undefined")
+
+ value, _ = vm.ToValue((*byte)(nil))
+ is(value, "undefined")
+
+ value, _ = vm.ToValue(intAlias(5))
+ is(value, 5)
+
+ {
+ tmp := new(int)
+
+ value, _ = vm.ToValue(&tmp)
+ is(value, 0)
+
+ *tmp = 1
+
+ value, _ = vm.ToValue(&tmp)
+ is(value, 1)
+
+ tmp = nil
+
+ value, _ = vm.ToValue(&tmp)
+ is(value, "undefined")
+ }
+
+ {
+ tmp0 := new(int)
+ tmp1 := &tmp0
+ tmp2 := &tmp1
+
+ value, _ = vm.ToValue(&tmp2)
+ is(value, 0)
+
+ *tmp0 = 1
+
+ value, _ = vm.ToValue(&tmp2)
+ is(value, 1)
+
+ tmp0 = nil
+
+ value, _ = vm.ToValue(&tmp2)
+ is(value, "undefined")
+ }
+ })
+}
+
+func TestToBoolean(t *testing.T) {
+ tt(t, func() {
+ is := func(left interface{}, right bool) {
+ is(toValue(left).bool(), right)
+ }
+
+ is("", false)
+ is("xyzzy", true)
+ is(1, true)
+ is(0, false)
+ //is(toValue(newObject()), true)
+ is(UndefinedValue(), false)
+ is(NullValue(), false)
+ })
+}
+
+func TestToFloat(t *testing.T) {
+ tt(t, func() {
+ {
+ is := func(left interface{}, right float64) {
+ is(toValue(left).float64(), right)
+ }
+ is("", 0)
+ is("xyzzy", math.NaN())
+ is("2", 2)
+ is(1, 1)
+ is(0, 0)
+ is(NullValue(), 0)
+ //is(newObjectValue(), math.NaN())
+ }
+ is(math.IsNaN(UndefinedValue().float64()), true)
+ })
+}
+
+func TestToString(t *testing.T) {
+ tt(t, func() {
+ is("undefined", UndefinedValue().string())
+ is("null", NullValue().string())
+ is("true", toValue(true).string())
+ is("false", toValue(false).string())
+
+ is(UndefinedValue(), "undefined")
+ is(NullValue(), "null")
+ is(toValue(true), true)
+ is(toValue(false), false)
+ })
+}
+
+func Test_toInt32(t *testing.T) {
+ tt(t, func() {
+ test := []interface{}{
+ 0, int32(0),
+ 1, int32(1),
+ -2147483649.0, int32(2147483647),
+ -4294967297.0, int32(-1),
+ -4294967296.0, int32(0),
+ -4294967295.0, int32(1),
+ math.Inf(+1), int32(0),
+ math.Inf(-1), int32(0),
+ }
+ for index := 0; index < len(test)/2; index++ {
+ // FIXME terst, Make strict again?
+ is(
+ toInt32(toValue(test[index*2])),
+ test[index*2+1].(int32),
+ )
+ }
+ })
+}
+
+func Test_toUint32(t *testing.T) {
+ tt(t, func() {
+ test := []interface{}{
+ 0, uint32(0),
+ 1, uint32(1),
+ -2147483649.0, uint32(2147483647),
+ -4294967297.0, uint32(4294967295),
+ -4294967296.0, uint32(0),
+ -4294967295.0, uint32(1),
+ math.Inf(+1), uint32(0),
+ math.Inf(-1), uint32(0),
+ }
+ for index := 0; index < len(test)/2; index++ {
+ // FIXME terst, Make strict again?
+ is(
+ toUint32(toValue(test[index*2])),
+ test[index*2+1].(uint32),
+ )
+ }
+ })
+}
+
+func Test_toUint16(t *testing.T) {
+ tt(t, func() {
+ test := []interface{}{
+ 0, uint16(0),
+ 1, uint16(1),
+ -2147483649.0, uint16(65535),
+ -4294967297.0, uint16(65535),
+ -4294967296.0, uint16(0),
+ -4294967295.0, uint16(1),
+ math.Inf(+1), uint16(0),
+ math.Inf(-1), uint16(0),
+ }
+ for index := 0; index < len(test)/2; index++ {
+ // FIXME terst, Make strict again?
+ is(
+ toUint16(toValue(test[index*2])),
+ test[index*2+1].(uint16),
+ )
+ }
+ })
+}
+
+func Test_sameValue(t *testing.T) {
+ tt(t, func() {
+ is(sameValue(positiveZeroValue(), negativeZeroValue()), false)
+ is(sameValue(positiveZeroValue(), toValue(0)), true)
+ is(sameValue(NaNValue(), NaNValue()), true)
+ is(sameValue(NaNValue(), toValue("Nothing happens.")), false)
+ })
+}
+
+func TestExport(t *testing.T) {
+ tt(t, func() {
+ test, vm := test()
+
+ is(test(`null;`).export(), nil)
+ is(test(`undefined;`).export(), nil)
+ is(test(`true;`).export(), true)
+ is(test(`false;`).export(), false)
+ is(test(`0;`).export(), 0)
+ is(test(`3.1459`).export(), 3.1459)
+ is(test(`"Nothing happens";`).export(), "Nothing happens")
+ is(test(`String.fromCharCode(97,98,99,100,101,102)`).export(), "abcdef")
+ {
+ value := test(`({ abc: 1, def: true, ghi: undefined });`).export().(map[string]interface{})
+ is(value["abc"], 1)
+ is(value["def"], true)
+ _, exists := value["ghi"]
+ is(exists, false)
+ }
+ {
+ value := test(`[ "abc", 1, "def", true, undefined, null ];`).export().([]interface{})
+ is(value[0], "abc")
+ is(value[1], 1)
+ is(value[2], "def")
+ is(value[3], true)
+ is(value[4], nil)
+ is(value[5], nil)
+ is(value[5], interface{}(nil))
+ }
+
+ roundtrip := []interface{}{
+ true,
+ false,
+ 0,
+ 3.1459,
+ []interface{}{true, false, 0, 3.1459, "abc"},
+ map[string]interface{}{
+ "Boolean": true,
+ "Number": 3.1459,
+ "String": "abc",
+ "Array": []interface{}{false, 0, "", nil},
+ "Object": map[string]interface{}{
+ "Boolean": false,
+ "Number": 0,
+ "String": "def",
+ },
+ },
+ }
+
+ for _, value := range roundtrip {
+ input, err := json.Marshal(value)
+ is(err, nil)
+
+ output, err := json.Marshal(test("(" + string(input) + ");").export())
+ is(err, nil)
+
+ is(string(input), string(output))
+ }
+
+ {
+ abc := struct {
+ def int
+ ghi interface{}
+ xyz float32
+ }{}
+ abc.def = 3
+ abc.xyz = 3.1459
+ vm.Set("abc", abc)
+ is(test(`abc;`).export(), abc)
+ }
+ })
+}
diff --git a/Godeps/_workspace/src/github.com/rs/cors/.travis.yml b/Godeps/_workspace/src/github.com/rs/cors/.travis.yml
new file mode 100644
index 000000000..bbb5185a2
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/rs/cors/.travis.yml
@@ -0,0 +1,4 @@
+language: go
+go:
+- 1.3
+- 1.4
diff --git a/Godeps/_workspace/src/github.com/rs/cors/LICENSE b/Godeps/_workspace/src/github.com/rs/cors/LICENSE
new file mode 100644
index 000000000..d8e2df5a4
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/rs/cors/LICENSE
@@ -0,0 +1,19 @@
+Copyright (c) 2014 Olivier Poitrey <rs@dailymotion.com>
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is furnished
+to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in all
+copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+THE SOFTWARE.
diff --git a/Godeps/_workspace/src/github.com/rs/cors/README.md b/Godeps/_workspace/src/github.com/rs/cors/README.md
new file mode 100644
index 000000000..6f70c30ac
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/rs/cors/README.md
@@ -0,0 +1,84 @@
+# Go CORS handler [![godoc](http://img.shields.io/badge/godoc-reference-blue.svg?style=flat)](https://godoc.org/github.com/rs/cors) [![license](http://img.shields.io/badge/license-MIT-red.svg?style=flat)](https://raw.githubusercontent.com/rs/cors/master/LICENSE) [![build](https://img.shields.io/travis/rs/cors.svg?style=flat)](https://travis-ci.org/rs/cors)
+
+CORS is a `net/http` handler implementing [Cross Origin Resource Sharing W3 specification](http://www.w3.org/TR/cors/) in Golang.
+
+## Getting Started
+
+After installing Go and setting up your [GOPATH](http://golang.org/doc/code.html#GOPATH), create your first `.go` file. We'll call it `server.go`.
+
+```go
+package main
+
+import (
+ "net/http"
+
+ "github.com/rs/cors"
+)
+
+func main() {
+ h := http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) {
+ w.Header().Set("Content-Type", "application/json")
+ w.Write([]byte("{\"hello\": \"world\"}"))
+ })
+
+ // cors.Default() setup the middleware with default options being
+ // all origins accepted with simple methods (GET, POST). See
+ // documentation below for more options.
+ handler = cors.Default().Handler(h)
+ http.ListenAndServe(":8080", handler)
+}
+```
+
+Install `cors`:
+
+ go get github.com/rs/cors
+
+Then run your server:
+
+ go run server.go
+
+The server now runs on `localhost:8080`:
+
+ $ curl -D - -H 'Origin: http://foo.com' http://localhost:8080/
+ HTTP/1.1 200 OK
+ Access-Control-Allow-Origin: foo.com
+ Content-Type: application/json
+ Date: Sat, 25 Oct 2014 03:43:57 GMT
+ Content-Length: 18
+
+ {"hello": "world"}
+
+### More Examples
+
+* `net/http`: [examples/nethttp/server.go](https://github.com/rs/cors/blob/master/examples/nethttp/server.go)
+* [Goji](https://goji.io): [examples/goji/server.go](https://github.com/rs/cors/blob/master/examples/goji/server.go)
+* [Martini](http://martini.codegangsta.io): [examples/martini/server.go](https://github.com/rs/cors/blob/master/examples/martini/server.go)
+* [Negroni](https://github.com/codegangsta/negroni): [examples/negroni/server.go](https://github.com/rs/cors/blob/master/examples/negroni/server.go)
+* [Alice](https://github.com/justinas/alice): [examples/alice/server.go](https://github.com/rs/cors/blob/master/examples/alice/server.go)
+
+## Parameters
+
+Parameters are passed to the middleware thru the `cors.New` method as follow:
+
+```go
+c := cors.New(cors.Options{
+ AllowedOrigins: []string{"http://foo.com"},
+ AllowCredentials: true,
+})
+
+// Insert the middleware
+handler = c.Handler(handler)
+```
+
+* **AllowedOrigins** `[]string`: A list of origins a cross-domain request can be executed from. If the special `*` value is present in the list, all origins will be allowed. The default value is `*`.
+* **AllowedMethods** `[]string`: A list of methods the client is allowed to use with cross-domain requests.
+* **AllowedHeaders** `[]string`: A list of non simple headers the client is allowed to use with cross-domain requests. Default value is simple methods (`GET` and `POST`)
+* **ExposedHeaders** `[]string`: Indicates which headers are safe to expose to the API of a CORS API specification
+* **AllowCredentials** `bool`: Indicates whether the request can include user credentials like cookies, HTTP authentication or client side SSL certificates. The default is `false`.
+* **MaxAge** `int`: Indicates how long (in seconds) the results of a preflight request can be cached. The default is `0` which stands for no max age.
+
+See [API documentation](http://godoc.org/github.com/rs/cors) for more info.
+
+## Licenses
+
+All source code is licensed under the [MIT License](https://raw.github.com/rs/cors/master/LICENSE).
diff --git a/Godeps/_workspace/src/github.com/rs/cors/bench_test.go b/Godeps/_workspace/src/github.com/rs/cors/bench_test.go
new file mode 100644
index 000000000..454375d2c
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/rs/cors/bench_test.go
@@ -0,0 +1,37 @@
+package cors
+
+import (
+ "net/http"
+ "net/http/httptest"
+ "testing"
+)
+
+func BenchmarkWithout(b *testing.B) {
+ res := httptest.NewRecorder()
+ req, _ := http.NewRequest("GET", "http://example.com/foo", nil)
+
+ for i := 0; i < b.N; i++ {
+ testHandler.ServeHTTP(res, req)
+ }
+}
+
+func BenchmarkDefault(b *testing.B) {
+ res := httptest.NewRecorder()
+ req, _ := http.NewRequest("GET", "http://example.com/foo", nil)
+ handler := Default()
+
+ for i := 0; i < b.N; i++ {
+ handler.Handler(testHandler).ServeHTTP(res, req)
+ }
+}
+
+func BenchmarkPreflight(b *testing.B) {
+ res := httptest.NewRecorder()
+ req, _ := http.NewRequest("OPTIONS", "http://example.com/foo", nil)
+ req.Header.Add("Access-Control-Request-Method", "GET")
+ handler := Default()
+
+ for i := 0; i < b.N; i++ {
+ handler.Handler(testHandler).ServeHTTP(res, req)
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/rs/cors/cors.go b/Godeps/_workspace/src/github.com/rs/cors/cors.go
new file mode 100644
index 000000000..276bc40bb
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/rs/cors/cors.go
@@ -0,0 +1,308 @@
+/*
+Package cors is net/http handler to handle CORS related requests
+as defined by http://www.w3.org/TR/cors/
+
+You can configure it by passing an option struct to cors.New:
+
+ c := cors.New(cors.Options{
+ AllowedOrigins: []string{"foo.com"},
+ AllowedMethods: []string{"GET", "POST", "DELETE"},
+ AllowCredentials: true,
+ })
+
+Then insert the handler in the chain:
+
+ handler = c.Handler(handler)
+
+See Options documentation for more options.
+
+The resulting handler is a standard net/http handler.
+*/
+package cors
+
+import (
+ "log"
+ "net/http"
+ "os"
+ "strconv"
+ "strings"
+)
+
+// Options is a configuration container to setup the CORS middleware.
+type Options struct {
+ // AllowedOrigins is a list of origins a cross-domain request can be executed from.
+ // If the special "*" value is present in the list, all origins will be allowed.
+ // Default value is ["*"]
+ AllowedOrigins []string
+ // AllowedMethods is a list of methods the client is allowed to use with
+ // cross-domain requests. Default value is simple methods (GET and POST)
+ AllowedMethods []string
+ // AllowedHeaders is list of non simple headers the client is allowed to use with
+ // cross-domain requests.
+ // If the special "*" value is present in the list, all headers will be allowed.
+ // Default value is [] but "Origin" is always appended to the list.
+ AllowedHeaders []string
+ // ExposedHeaders indicates which headers are safe to expose to the API of a CORS
+ // API specification
+ ExposedHeaders []string
+ // AllowCredentials indicates whether the request can include user credentials like
+ // cookies, HTTP authentication or client side SSL certificates.
+ AllowCredentials bool
+ // MaxAge indicates how long (in seconds) the results of a preflight request
+ // can be cached
+ MaxAge int
+ // Debugging flag adds additional output to debug server side CORS issues
+ Debug bool
+ // log object to use when debugging
+ log *log.Logger
+}
+
+type Cors struct {
+ // The CORS Options
+ options Options
+}
+
+// New creates a new Cors handler with the provided options.
+func New(options Options) *Cors {
+ // Normalize options
+ // Note: for origins and methods matching, the spec requires a case-sensitive matching.
+ // As it may error prone, we chose to ignore the spec here.
+ normOptions := Options{
+ AllowedOrigins: convert(options.AllowedOrigins, strings.ToLower),
+ AllowedMethods: convert(options.AllowedMethods, strings.ToUpper),
+ // Origin is always appended as some browsers will always request
+ // for this header at preflight
+ AllowedHeaders: convert(append(options.AllowedHeaders, "Origin"), http.CanonicalHeaderKey),
+ ExposedHeaders: convert(options.ExposedHeaders, http.CanonicalHeaderKey),
+ AllowCredentials: options.AllowCredentials,
+ MaxAge: options.MaxAge,
+ Debug: options.Debug,
+ log: log.New(os.Stdout, "[cors] ", log.LstdFlags),
+ }
+ if len(normOptions.AllowedOrigins) == 0 {
+ // Default is all origins
+ normOptions.AllowedOrigins = []string{"*"}
+ }
+ if len(normOptions.AllowedHeaders) == 1 {
+ // Add some sensible defaults
+ normOptions.AllowedHeaders = []string{"Origin", "Accept", "Content-Type"}
+ }
+ if len(normOptions.AllowedMethods) == 0 {
+ // Default is simple methods
+ normOptions.AllowedMethods = []string{"GET", "POST"}
+ }
+
+ if normOptions.Debug {
+ normOptions.log.Printf("Options: %v", normOptions)
+ }
+ return &Cors{
+ options: normOptions,
+ }
+}
+
+// Default creates a new Cors handler with default options
+func Default() *Cors {
+ return New(Options{})
+}
+
+// Handler apply the CORS specification on the request, and add relevant CORS headers
+// as necessary.
+func (cors *Cors) Handler(h http.Handler) http.Handler {
+ return http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) {
+ if r.Method == "OPTIONS" {
+ cors.logf("Handler: Preflight request")
+ cors.handlePreflight(w, r)
+ // Preflight requests are standalone and should stop the chain as some other
+ // middleware may not handle OPTIONS requests correctly. One typical example
+ // is authentication middleware ; OPTIONS requests won't carry authentication
+ // headers (see #1)
+ } else {
+ cors.logf("Handler: Actual request")
+ cors.handleActualRequest(w, r)
+ h.ServeHTTP(w, r)
+ }
+ })
+}
+
+// Martini compatible handler
+func (cors *Cors) HandlerFunc(w http.ResponseWriter, r *http.Request) {
+ if r.Method == "OPTIONS" {
+ cors.logf("HandlerFunc: Preflight request")
+ cors.handlePreflight(w, r)
+ } else {
+ cors.logf("HandlerFunc: Actual request")
+ cors.handleActualRequest(w, r)
+ }
+}
+
+// Negroni compatible interface
+func (cors *Cors) ServeHTTP(w http.ResponseWriter, r *http.Request, next http.HandlerFunc) {
+ if r.Method == "OPTIONS" {
+ cors.logf("ServeHTTP: Preflight request")
+ cors.handlePreflight(w, r)
+ // Preflight requests are standalone and should stop the chain as some other
+ // middleware may not handle OPTIONS requests correctly. One typical example
+ // is authentication middleware ; OPTIONS requests won't carry authentication
+ // headers (see #1)
+ } else {
+ cors.logf("ServeHTTP: Actual request")
+ cors.handleActualRequest(w, r)
+ next(w, r)
+ }
+}
+
+// handlePreflight handles pre-flight CORS requests
+func (cors *Cors) handlePreflight(w http.ResponseWriter, r *http.Request) {
+ options := cors.options
+ headers := w.Header()
+ origin := r.Header.Get("Origin")
+
+ if r.Method != "OPTIONS" {
+ cors.logf(" Preflight aborted: %s!=OPTIONS", r.Method)
+ return
+ }
+ if origin == "" {
+ cors.logf(" Preflight aborted: empty origin")
+ return
+ }
+ if !cors.isOriginAllowed(origin) {
+ cors.logf(" Preflight aborted: origin '%s' not allowed", origin)
+ return
+ }
+
+ reqMethod := r.Header.Get("Access-Control-Request-Method")
+ if !cors.isMethodAllowed(reqMethod) {
+ cors.logf(" Preflight aborted: method '%s' not allowed", reqMethod)
+ return
+ }
+ reqHeaders := parseHeaderList(r.Header.Get("Access-Control-Request-Headers"))
+ if !cors.areHeadersAllowed(reqHeaders) {
+ cors.logf(" Preflight aborted: headers '%v' not allowed", reqHeaders)
+ return
+ }
+ headers.Set("Access-Control-Allow-Origin", origin)
+ headers.Add("Vary", "Origin")
+ // Spec says: Since the list of methods can be unbounded, simply returning the method indicated
+ // by Access-Control-Request-Method (if supported) can be enough
+ headers.Set("Access-Control-Allow-Methods", strings.ToUpper(reqMethod))
+ if len(reqHeaders) > 0 {
+
+ // Spec says: Since the list of headers can be unbounded, simply returning supported headers
+ // from Access-Control-Request-Headers can be enough
+ headers.Set("Access-Control-Allow-Headers", strings.Join(reqHeaders, ", "))
+ }
+ if options.AllowCredentials {
+ headers.Set("Access-Control-Allow-Credentials", "true")
+ }
+ if options.MaxAge > 0 {
+ headers.Set("Access-Control-Max-Age", strconv.Itoa(options.MaxAge))
+ }
+ cors.logf(" Preflight response headers: %v", headers)
+}
+
+// handleActualRequest handles simple cross-origin requests, actual request or redirects
+func (cors *Cors) handleActualRequest(w http.ResponseWriter, r *http.Request) {
+ options := cors.options
+ headers := w.Header()
+ origin := r.Header.Get("Origin")
+
+ if r.Method == "OPTIONS" {
+ cors.logf(" Actual request no headers added: method == %s", r.Method)
+ return
+ }
+ if origin == "" {
+ cors.logf(" Actual request no headers added: missing origin")
+ return
+ }
+ if !cors.isOriginAllowed(origin) {
+ cors.logf(" Actual request no headers added: origin '%s' not allowed", origin)
+ return
+ }
+
+ // Note that spec does define a way to specifically disallow a simple method like GET or
+ // POST. Access-Control-Allow-Methods is only used for pre-flight requests and the
+ // spec doesn't instruct to check the allowed methods for simple cross-origin requests.
+ // We think it's a nice feature to be able to have control on those methods though.
+ if !cors.isMethodAllowed(r.Method) {
+ if cors.options.Debug {
+ cors.logf(" Actual request no headers added: method '%s' not allowed",
+ r.Method)
+ }
+
+ return
+ }
+ headers.Set("Access-Control-Allow-Origin", origin)
+ headers.Add("Vary", "Origin")
+ if len(options.ExposedHeaders) > 0 {
+ headers.Set("Access-Control-Expose-Headers", strings.Join(options.ExposedHeaders, ", "))
+ }
+ if options.AllowCredentials {
+ headers.Set("Access-Control-Allow-Credentials", "true")
+ }
+ cors.logf(" Actual response added headers: %v", headers)
+}
+
+// convenience method. checks if debugging is turned on before printing
+func (cors *Cors) logf(format string, a ...interface{}) {
+ if cors.options.Debug {
+ cors.options.log.Printf(format, a...)
+ }
+}
+
+// isOriginAllowed checks if a given origin is allowed to perform cross-domain requests
+// on the endpoint
+func (cors *Cors) isOriginAllowed(origin string) bool {
+ allowedOrigins := cors.options.AllowedOrigins
+ origin = strings.ToLower(origin)
+ for _, allowedOrigin := range allowedOrigins {
+ switch allowedOrigin {
+ case "*":
+ return true
+ case origin:
+ return true
+ }
+ }
+ return false
+}
+
+// isMethodAllowed checks if a given method can be used as part of a cross-domain request
+// on the endpoing
+func (cors *Cors) isMethodAllowed(method string) bool {
+ allowedMethods := cors.options.AllowedMethods
+ if len(allowedMethods) == 0 {
+ // If no method allowed, always return false, even for preflight request
+ return false
+ }
+ method = strings.ToUpper(method)
+ if method == "OPTIONS" {
+ // Always allow preflight requests
+ return true
+ }
+ for _, allowedMethod := range allowedMethods {
+ if allowedMethod == method {
+ return true
+ }
+ }
+ return false
+}
+
+// areHeadersAllowed checks if a given list of headers are allowed to used within
+// a cross-domain request.
+func (cors *Cors) areHeadersAllowed(requestedHeaders []string) bool {
+ if len(requestedHeaders) == 0 {
+ return true
+ }
+ for _, header := range requestedHeaders {
+ found := false
+ for _, allowedHeader := range cors.options.AllowedHeaders {
+ if allowedHeader == "*" || allowedHeader == header {
+ found = true
+ break
+ }
+ }
+ if !found {
+ return false
+ }
+ }
+ return true
+}
diff --git a/Godeps/_workspace/src/github.com/rs/cors/cors_test.go b/Godeps/_workspace/src/github.com/rs/cors/cors_test.go
new file mode 100644
index 000000000..f215018c9
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/rs/cors/cors_test.go
@@ -0,0 +1,288 @@
+package cors
+
+import (
+ "net/http"
+ "net/http/httptest"
+ "testing"
+)
+
+var testHandler = http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) {
+ w.Write([]byte("bar"))
+})
+
+func assertHeaders(t *testing.T, resHeaders http.Header, reqHeaders map[string]string) {
+ for name, value := range reqHeaders {
+ if resHeaders.Get(name) != value {
+ t.Errorf("Invalid header `%s', wanted `%s', got `%s'", name, value, resHeaders.Get(name))
+ }
+ }
+}
+
+func TestNoConfig(t *testing.T) {
+ s := New(Options{
+ // Intentionally left blank.
+ })
+
+ res := httptest.NewRecorder()
+ req, _ := http.NewRequest("GET", "http://example.com/foo", nil)
+
+ s.Handler(testHandler).ServeHTTP(res, req)
+
+ assertHeaders(t, res.Header(), map[string]string{
+ "Access-Control-Allow-Origin": "",
+ "Access-Control-Allow-Methods": "",
+ "Access-Control-Allow-Headers": "",
+ "Access-Control-Allow-Credentials": "",
+ "Access-Control-Max-Age": "",
+ "Access-Control-Expose-Headers": "",
+ })
+}
+
+func TestWildcardOrigin(t *testing.T) {
+ s := New(Options{
+ AllowedOrigins: []string{"*"},
+ })
+
+ res := httptest.NewRecorder()
+ req, _ := http.NewRequest("GET", "http://example.com/foo", nil)
+ req.Header.Add("Origin", "http://foobar.com")
+
+ s.Handler(testHandler).ServeHTTP(res, req)
+
+ assertHeaders(t, res.Header(), map[string]string{
+ "Access-Control-Allow-Origin": "http://foobar.com",
+ "Access-Control-Allow-Methods": "",
+ "Access-Control-Allow-Headers": "",
+ "Access-Control-Allow-Credentials": "",
+ "Access-Control-Max-Age": "",
+ "Access-Control-Expose-Headers": "",
+ })
+}
+
+func TestAllowedOrigin(t *testing.T) {
+ s := New(Options{
+ AllowedOrigins: []string{"http://foobar.com"},
+ })
+
+ res := httptest.NewRecorder()
+ req, _ := http.NewRequest("GET", "http://example.com/foo", nil)
+ req.Header.Add("Origin", "http://foobar.com")
+
+ s.Handler(testHandler).ServeHTTP(res, req)
+
+ assertHeaders(t, res.Header(), map[string]string{
+ "Access-Control-Allow-Origin": "http://foobar.com",
+ "Access-Control-Allow-Methods": "",
+ "Access-Control-Allow-Headers": "",
+ "Access-Control-Allow-Credentials": "",
+ "Access-Control-Max-Age": "",
+ "Access-Control-Expose-Headers": "",
+ })
+}
+
+func TestDisallowedOrigin(t *testing.T) {
+ s := New(Options{
+ AllowedOrigins: []string{"http://foobar.com"},
+ })
+
+ res := httptest.NewRecorder()
+ req, _ := http.NewRequest("GET", "http://example.com/foo", nil)
+ req.Header.Add("Origin", "http://barbaz.com")
+
+ s.Handler(testHandler).ServeHTTP(res, req)
+
+ assertHeaders(t, res.Header(), map[string]string{
+ "Access-Control-Allow-Origin": "",
+ "Access-Control-Allow-Methods": "",
+ "Access-Control-Allow-Headers": "",
+ "Access-Control-Allow-Credentials": "",
+ "Access-Control-Max-Age": "",
+ "Access-Control-Expose-Headers": "",
+ })
+}
+
+func TestAllowedMethod(t *testing.T) {
+ s := New(Options{
+ AllowedOrigins: []string{"http://foobar.com"},
+ AllowedMethods: []string{"PUT", "DELETE"},
+ })
+
+ res := httptest.NewRecorder()
+ req, _ := http.NewRequest("OPTIONS", "http://example.com/foo", nil)
+ req.Header.Add("Origin", "http://foobar.com")
+ req.Header.Add("Access-Control-Request-Method", "PUT")
+
+ s.Handler(testHandler).ServeHTTP(res, req)
+
+ assertHeaders(t, res.Header(), map[string]string{
+ "Access-Control-Allow-Origin": "http://foobar.com",
+ "Access-Control-Allow-Methods": "PUT",
+ "Access-Control-Allow-Headers": "",
+ "Access-Control-Allow-Credentials": "",
+ "Access-Control-Max-Age": "",
+ "Access-Control-Expose-Headers": "",
+ })
+}
+
+func TestDisallowedMethod(t *testing.T) {
+ s := New(Options{
+ AllowedOrigins: []string{"http://foobar.com"},
+ AllowedMethods: []string{"PUT", "DELETE"},
+ })
+
+ res := httptest.NewRecorder()
+ req, _ := http.NewRequest("OPTIONS", "http://example.com/foo", nil)
+ req.Header.Add("Origin", "http://foobar.com")
+ req.Header.Add("Access-Control-Request-Method", "PATCH")
+
+ s.Handler(testHandler).ServeHTTP(res, req)
+
+ assertHeaders(t, res.Header(), map[string]string{
+ "Access-Control-Allow-Origin": "",
+ "Access-Control-Allow-Methods": "",
+ "Access-Control-Allow-Headers": "",
+ "Access-Control-Allow-Credentials": "",
+ "Access-Control-Max-Age": "",
+ "Access-Control-Expose-Headers": "",
+ })
+}
+
+func TestAllowedHeader(t *testing.T) {
+ s := New(Options{
+ AllowedOrigins: []string{"http://foobar.com"},
+ AllowedHeaders: []string{"X-Header-1", "x-header-2"},
+ })
+
+ res := httptest.NewRecorder()
+ req, _ := http.NewRequest("OPTIONS", "http://example.com/foo", nil)
+ req.Header.Add("Origin", "http://foobar.com")
+ req.Header.Add("Access-Control-Request-Method", "GET")
+ req.Header.Add("Access-Control-Request-Headers", "X-Header-2, X-HEADER-1")
+
+ s.Handler(testHandler).ServeHTTP(res, req)
+
+ assertHeaders(t, res.Header(), map[string]string{
+ "Access-Control-Allow-Origin": "http://foobar.com",
+ "Access-Control-Allow-Methods": "GET",
+ "Access-Control-Allow-Headers": "X-Header-2, X-Header-1",
+ "Access-Control-Allow-Credentials": "",
+ "Access-Control-Max-Age": "",
+ "Access-Control-Expose-Headers": "",
+ })
+}
+
+func TestAllowedWildcardHeader(t *testing.T) {
+ s := New(Options{
+ AllowedOrigins: []string{"http://foobar.com"},
+ AllowedHeaders: []string{"*"},
+ })
+
+ res := httptest.NewRecorder()
+ req, _ := http.NewRequest("OPTIONS", "http://example.com/foo", nil)
+ req.Header.Add("Origin", "http://foobar.com")
+ req.Header.Add("Access-Control-Request-Method", "GET")
+ req.Header.Add("Access-Control-Request-Headers", "X-Header-2, X-HEADER-1")
+
+ s.Handler(testHandler).ServeHTTP(res, req)
+
+ assertHeaders(t, res.Header(), map[string]string{
+ "Access-Control-Allow-Origin": "http://foobar.com",
+ "Access-Control-Allow-Methods": "GET",
+ "Access-Control-Allow-Headers": "X-Header-2, X-Header-1",
+ "Access-Control-Allow-Credentials": "",
+ "Access-Control-Max-Age": "",
+ "Access-Control-Expose-Headers": "",
+ })
+}
+
+func TestDisallowedHeader(t *testing.T) {
+ s := New(Options{
+ AllowedOrigins: []string{"http://foobar.com"},
+ AllowedHeaders: []string{"X-Header-1", "x-header-2"},
+ })
+
+ res := httptest.NewRecorder()
+ req, _ := http.NewRequest("OPTIONS", "http://example.com/foo", nil)
+ req.Header.Add("Origin", "http://foobar.com")
+ req.Header.Add("Access-Control-Request-Method", "GET")
+ req.Header.Add("Access-Control-Request-Headers", "X-Header-3, X-Header-1")
+
+ s.Handler(testHandler).ServeHTTP(res, req)
+
+ assertHeaders(t, res.Header(), map[string]string{
+ "Access-Control-Allow-Origin": "",
+ "Access-Control-Allow-Methods": "",
+ "Access-Control-Allow-Headers": "",
+ "Access-Control-Allow-Credentials": "",
+ "Access-Control-Max-Age": "",
+ "Access-Control-Expose-Headers": "",
+ })
+}
+
+func TestOriginHeader(t *testing.T) {
+ s := New(Options{
+ AllowedOrigins: []string{"http://foobar.com"},
+ })
+
+ res := httptest.NewRecorder()
+ req, _ := http.NewRequest("OPTIONS", "http://example.com/foo", nil)
+ req.Header.Add("Origin", "http://foobar.com")
+ req.Header.Add("Access-Control-Request-Method", "GET")
+ req.Header.Add("Access-Control-Request-Headers", "origin")
+
+ s.Handler(testHandler).ServeHTTP(res, req)
+
+ assertHeaders(t, res.Header(), map[string]string{
+ "Access-Control-Allow-Origin": "http://foobar.com",
+ "Access-Control-Allow-Methods": "GET",
+ "Access-Control-Allow-Headers": "Origin",
+ "Access-Control-Allow-Credentials": "",
+ "Access-Control-Max-Age": "",
+ "Access-Control-Expose-Headers": "",
+ })
+}
+
+func TestExposedHeader(t *testing.T) {
+ s := New(Options{
+ AllowedOrigins: []string{"http://foobar.com"},
+ ExposedHeaders: []string{"X-Header-1", "x-header-2"},
+ })
+
+ res := httptest.NewRecorder()
+ req, _ := http.NewRequest("GET", "http://example.com/foo", nil)
+ req.Header.Add("Origin", "http://foobar.com")
+
+ s.Handler(testHandler).ServeHTTP(res, req)
+
+ assertHeaders(t, res.Header(), map[string]string{
+ "Access-Control-Allow-Origin": "http://foobar.com",
+ "Access-Control-Allow-Methods": "",
+ "Access-Control-Allow-Headers": "",
+ "Access-Control-Allow-Credentials": "",
+ "Access-Control-Max-Age": "",
+ "Access-Control-Expose-Headers": "X-Header-1, X-Header-2",
+ })
+}
+
+func TestAllowedCredentials(t *testing.T) {
+ s := New(Options{
+ AllowedOrigins: []string{"http://foobar.com"},
+ AllowCredentials: true,
+ })
+
+ res := httptest.NewRecorder()
+ req, _ := http.NewRequest("OPTIONS", "http://example.com/foo", nil)
+ req.Header.Add("Origin", "http://foobar.com")
+ req.Header.Add("Access-Control-Request-Method", "GET")
+
+ s.Handler(testHandler).ServeHTTP(res, req)
+
+ assertHeaders(t, res.Header(), map[string]string{
+ "Access-Control-Allow-Origin": "http://foobar.com",
+ "Access-Control-Allow-Methods": "GET",
+ "Access-Control-Allow-Headers": "",
+ "Access-Control-Allow-Credentials": "true",
+ "Access-Control-Max-Age": "",
+ "Access-Control-Expose-Headers": "",
+ })
+}
diff --git a/Godeps/_workspace/src/github.com/rs/cors/examples/alice/server.go b/Godeps/_workspace/src/github.com/rs/cors/examples/alice/server.go
new file mode 100644
index 000000000..0a3e15cb8
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/rs/cors/examples/alice/server.go
@@ -0,0 +1,24 @@
+package main
+
+import (
+ "net/http"
+
+ "github.com/justinas/alice"
+ "github.com/rs/cors"
+)
+
+func main() {
+ c := cors.New(cors.Options{
+ AllowedOrigins: []string{"http://foo.com"},
+ })
+
+ mux := http.NewServeMux()
+
+ mux.HandleFunc("/", func(w http.ResponseWriter, r *http.Request) {
+ w.Header().Set("Content-Type", "application/json")
+ w.Write([]byte("{\"hello\": \"world\"}"))
+ })
+
+ chain := alice.New(c.Handler).Then(mux)
+ http.ListenAndServe(":8080", chain)
+}
diff --git a/Godeps/_workspace/src/github.com/rs/cors/examples/default/server.go b/Godeps/_workspace/src/github.com/rs/cors/examples/default/server.go
new file mode 100644
index 000000000..851ac41d0
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/rs/cors/examples/default/server.go
@@ -0,0 +1,18 @@
+package main
+
+import (
+ "net/http"
+
+ "github.com/rs/cors"
+)
+
+func main() {
+ h := http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) {
+ w.Header().Set("Content-Type", "application/json")
+ w.Write([]byte("{\"hello\": \"world\"}"))
+ })
+
+ // Use default options
+ handler := cors.Default().Handler(h)
+ http.ListenAndServe(":8080", handler)
+}
diff --git a/Godeps/_workspace/src/github.com/rs/cors/examples/goji/server.go b/Godeps/_workspace/src/github.com/rs/cors/examples/goji/server.go
new file mode 100644
index 000000000..1fb4073aa
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/rs/cors/examples/goji/server.go
@@ -0,0 +1,22 @@
+package main
+
+import (
+ "net/http"
+
+ "github.com/rs/cors"
+ "github.com/zenazn/goji"
+)
+
+func main() {
+ c := cors.New(cors.Options{
+ AllowedOrigins: []string{"http://foo.com"},
+ })
+ goji.Use(c.Handler)
+
+ goji.Get("/", func(w http.ResponseWriter, r *http.Request) {
+ w.Header().Set("Content-Type", "application/json")
+ w.Write([]byte("{\"hello\": \"world\"}"))
+ })
+
+ goji.Serve()
+}
diff --git a/Godeps/_workspace/src/github.com/rs/cors/examples/martini/server.go b/Godeps/_workspace/src/github.com/rs/cors/examples/martini/server.go
new file mode 100644
index 000000000..081af32f9
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/rs/cors/examples/martini/server.go
@@ -0,0 +1,23 @@
+package main
+
+import (
+ "github.com/go-martini/martini"
+ "github.com/martini-contrib/render"
+ "github.com/rs/cors"
+)
+
+func main() {
+ c := cors.New(cors.Options{
+ AllowedOrigins: []string{"http://foo.com"},
+ })
+
+ m := martini.Classic()
+ m.Use(render.Renderer())
+ m.Use(c.HandlerFunc)
+
+ m.Get("/", func(r render.Render) {
+ r.JSON(200, map[string]interface{}{"hello": "world"})
+ })
+
+ m.Run()
+}
diff --git a/Godeps/_workspace/src/github.com/rs/cors/examples/negroni/server.go b/Godeps/_workspace/src/github.com/rs/cors/examples/negroni/server.go
new file mode 100644
index 000000000..3cb33bff6
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/rs/cors/examples/negroni/server.go
@@ -0,0 +1,26 @@
+package main
+
+import (
+ "net/http"
+
+ "github.com/codegangsta/negroni"
+ "github.com/rs/cors"
+)
+
+func main() {
+ c := cors.New(cors.Options{
+ AllowedOrigins: []string{"http://foo.com"},
+ })
+
+ mux := http.NewServeMux()
+
+ mux.HandleFunc("/", func(w http.ResponseWriter, r *http.Request) {
+ w.Header().Set("Content-Type", "application/json")
+ w.Write([]byte("{\"hello\": \"world\"}"))
+ })
+
+ n := negroni.Classic()
+ n.Use(c)
+ n.UseHandler(mux)
+ n.Run(":3000")
+}
diff --git a/Godeps/_workspace/src/github.com/rs/cors/examples/nethttp/server.go b/Godeps/_workspace/src/github.com/rs/cors/examples/nethttp/server.go
new file mode 100644
index 000000000..eaa775e44
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/rs/cors/examples/nethttp/server.go
@@ -0,0 +1,20 @@
+package main
+
+import (
+ "net/http"
+
+ "github.com/rs/cors"
+)
+
+func main() {
+ c := cors.New(cors.Options{
+ AllowedOrigins: []string{"http://foo.com"},
+ })
+
+ handler := http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) {
+ w.Header().Set("Content-Type", "application/json")
+ w.Write([]byte("{\"hello\": \"world\"}"))
+ })
+
+ http.ListenAndServe(":8080", c.Handler(handler))
+}
diff --git a/Godeps/_workspace/src/github.com/rs/cors/examples/openbar/server.go b/Godeps/_workspace/src/github.com/rs/cors/examples/openbar/server.go
new file mode 100644
index 000000000..094042300
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/rs/cors/examples/openbar/server.go
@@ -0,0 +1,22 @@
+package main
+
+import (
+ "net/http"
+
+ "github.com/rs/cors"
+)
+
+func main() {
+ c := cors.New(cors.Options{
+ AllowedOrigins: []string{"*"},
+ AllowedMethods: []string{"GET", "POST", "PUT", "DELETE"},
+ AllowCredentials: true,
+ })
+
+ h := http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) {
+ w.Header().Set("Content-Type", "application/json")
+ w.Write([]byte("{\"hello\": \"world\"}"))
+ })
+
+ http.ListenAndServe(":8080", c.Handler(h))
+}
diff --git a/Godeps/_workspace/src/github.com/rs/cors/utils.go b/Godeps/_workspace/src/github.com/rs/cors/utils.go
new file mode 100644
index 000000000..429ab1114
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/rs/cors/utils.go
@@ -0,0 +1,27 @@
+package cors
+
+import (
+ "net/http"
+ "strings"
+)
+
+type converter func(string) string
+
+// convert converts a list of string using the passed converter function
+func convert(s []string, c converter) []string {
+ out := []string{}
+ for _, i := range s {
+ out = append(out, c(i))
+ }
+ return out
+}
+
+func parseHeaderList(headerList string) (headers []string) {
+ for _, header := range strings.Split(headerList, ",") {
+ header = http.CanonicalHeaderKey(strings.TrimSpace(header))
+ if header != "" {
+ headers = append(headers, header)
+ }
+ }
+ return headers
+}
diff --git a/Godeps/_workspace/src/github.com/rs/cors/utils_test.go b/Godeps/_workspace/src/github.com/rs/cors/utils_test.go
new file mode 100644
index 000000000..3fc77fc1e
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/rs/cors/utils_test.go
@@ -0,0 +1,28 @@
+package cors
+
+import (
+ "strings"
+ "testing"
+)
+
+func TestConvert(t *testing.T) {
+ s := convert([]string{"A", "b", "C"}, strings.ToLower)
+ e := []string{"a", "b", "c"}
+ if s[0] != e[0] || s[1] != e[1] || s[2] != e[2] {
+ t.Errorf("%v != %v", s, e)
+ }
+}
+
+func TestParseHeaderList(t *testing.T) {
+ h := parseHeaderList("header, second-header, THIRD-HEADER")
+ e := []string{"Header", "Second-Header", "Third-Header"}
+ if h[0] != e[0] || h[1] != e[1] || h[2] != e[2] {
+ t.Errorf("%v != %v", h, e)
+ }
+}
+
+func TestParseHeaderListEmpty(t *testing.T) {
+ if len(parseHeaderList("")) != 0 {
+ t.Error("should be empty sclice")
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/batch.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/batch.go
new file mode 100644
index 000000000..0d7911eca
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/batch.go
@@ -0,0 +1,216 @@
+// Copyright (c) 2012, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package leveldb
+
+import (
+ "encoding/binary"
+ "errors"
+
+ "github.com/syndtr/goleveldb/leveldb/memdb"
+)
+
+var (
+ errBatchTooShort = errors.New("leveldb: batch is too short")
+ errBatchBadRecord = errors.New("leveldb: bad record in batch")
+)
+
+const kBatchHdrLen = 8 + 4
+
+type batchReplay interface {
+ put(key, value []byte, seq uint64)
+ delete(key []byte, seq uint64)
+}
+
+// Batch is a write batch.
+type Batch struct {
+ buf []byte
+ rLen, bLen int
+ seq uint64
+ sync bool
+}
+
+func (b *Batch) grow(n int) {
+ off := len(b.buf)
+ if off == 0 {
+ // include headers
+ off = kBatchHdrLen
+ n += off
+ }
+ if cap(b.buf)-off >= n {
+ return
+ }
+ buf := make([]byte, 2*cap(b.buf)+n)
+ copy(buf, b.buf)
+ b.buf = buf[:off]
+}
+
+func (b *Batch) appendRec(t vType, key, value []byte) {
+ n := 1 + binary.MaxVarintLen32 + len(key)
+ if t == tVal {
+ n += binary.MaxVarintLen32 + len(value)
+ }
+ b.grow(n)
+ off := len(b.buf)
+ buf := b.buf[:off+n]
+ buf[off] = byte(t)
+ off += 1
+ off += binary.PutUvarint(buf[off:], uint64(len(key)))
+ copy(buf[off:], key)
+ off += len(key)
+ if t == tVal {
+ off += binary.PutUvarint(buf[off:], uint64(len(value)))
+ copy(buf[off:], value)
+ off += len(value)
+ }
+ b.buf = buf[:off]
+ b.rLen++
+ // Include 8-byte ikey header
+ b.bLen += len(key) + len(value) + 8
+}
+
+// Put appends 'put operation' of the given key/value pair to the batch.
+// It is safe to modify the contents of the argument after Put returns.
+func (b *Batch) Put(key, value []byte) {
+ b.appendRec(tVal, key, value)
+}
+
+// Delete appends 'delete operation' of the given key to the batch.
+// It is safe to modify the contents of the argument after Delete returns.
+func (b *Batch) Delete(key []byte) {
+ b.appendRec(tDel, key, nil)
+}
+
+// Reset resets the batch.
+func (b *Batch) Reset() {
+ b.buf = nil
+ b.seq = 0
+ b.rLen = 0
+ b.bLen = 0
+ b.sync = false
+}
+
+func (b *Batch) init(sync bool) {
+ b.sync = sync
+}
+
+func (b *Batch) put(key, value []byte, seq uint64) {
+ if b.rLen == 0 {
+ b.seq = seq
+ }
+ b.Put(key, value)
+}
+
+func (b *Batch) delete(key []byte, seq uint64) {
+ if b.rLen == 0 {
+ b.seq = seq
+ }
+ b.Delete(key)
+}
+
+func (b *Batch) append(p *Batch) {
+ if p.rLen > 0 {
+ b.grow(len(p.buf) - kBatchHdrLen)
+ b.buf = append(b.buf, p.buf[kBatchHdrLen:]...)
+ b.rLen += p.rLen
+ }
+ if p.sync {
+ b.sync = true
+ }
+}
+
+func (b *Batch) len() int {
+ return b.rLen
+}
+
+func (b *Batch) size() int {
+ return b.bLen
+}
+
+func (b *Batch) encode() []byte {
+ b.grow(0)
+ binary.LittleEndian.PutUint64(b.buf, b.seq)
+ binary.LittleEndian.PutUint32(b.buf[8:], uint32(b.rLen))
+
+ return b.buf
+}
+
+func (b *Batch) decode(buf []byte) error {
+ if len(buf) < kBatchHdrLen {
+ return errBatchTooShort
+ }
+
+ b.seq = binary.LittleEndian.Uint64(buf)
+ b.rLen = int(binary.LittleEndian.Uint32(buf[8:]))
+ // No need to be precise at this point, it won't be used anyway
+ b.bLen = len(buf) - kBatchHdrLen
+ b.buf = buf
+
+ return nil
+}
+
+func (b *Batch) decodeRec(f func(i int, t vType, key, value []byte)) error {
+ off := kBatchHdrLen
+ for i := 0; i < b.rLen; i++ {
+ if off >= len(b.buf) {
+ return errors.New("leveldb: invalid batch record length")
+ }
+
+ t := vType(b.buf[off])
+ if t > tVal {
+ return errors.New("leveldb: invalid batch record type in batch")
+ }
+ off += 1
+
+ x, n := binary.Uvarint(b.buf[off:])
+ off += n
+ if n <= 0 || off+int(x) > len(b.buf) {
+ return errBatchBadRecord
+ }
+ key := b.buf[off : off+int(x)]
+ off += int(x)
+
+ var value []byte
+ if t == tVal {
+ x, n := binary.Uvarint(b.buf[off:])
+ off += n
+ if n <= 0 || off+int(x) > len(b.buf) {
+ return errBatchBadRecord
+ }
+ value = b.buf[off : off+int(x)]
+ off += int(x)
+ }
+
+ f(i, t, key, value)
+ }
+
+ return nil
+}
+
+func (b *Batch) replay(to batchReplay) error {
+ return b.decodeRec(func(i int, t vType, key, value []byte) {
+ switch t {
+ case tVal:
+ to.put(key, value, b.seq+uint64(i))
+ case tDel:
+ to.delete(key, b.seq+uint64(i))
+ }
+ })
+}
+
+func (b *Batch) memReplay(to *memdb.DB) error {
+ return b.decodeRec(func(i int, t vType, key, value []byte) {
+ ikey := newIKey(key, b.seq+uint64(i), t)
+ to.Put(ikey, value)
+ })
+}
+
+func (b *Batch) revertMemReplay(to *memdb.DB) error {
+ return b.decodeRec(func(i int, t vType, key, value []byte) {
+ ikey := newIKey(key, b.seq+uint64(i), t)
+ to.Delete(ikey)
+ })
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/batch_test.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/batch_test.go
new file mode 100644
index 000000000..19b749b8f
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/batch_test.go
@@ -0,0 +1,120 @@
+// Copyright (c) 2012, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package leveldb
+
+import (
+ "bytes"
+ "testing"
+
+ "github.com/syndtr/goleveldb/leveldb/comparer"
+ "github.com/syndtr/goleveldb/leveldb/memdb"
+)
+
+type tbRec struct {
+ t vType
+ key, value []byte
+}
+
+type testBatch struct {
+ rec []*tbRec
+}
+
+func (p *testBatch) put(key, value []byte, seq uint64) {
+ p.rec = append(p.rec, &tbRec{tVal, key, value})
+}
+
+func (p *testBatch) delete(key []byte, seq uint64) {
+ p.rec = append(p.rec, &tbRec{tDel, key, nil})
+}
+
+func compareBatch(t *testing.T, b1, b2 *Batch) {
+ if b1.seq != b2.seq {
+ t.Errorf("invalid seq number want %d, got %d", b1.seq, b2.seq)
+ }
+ if b1.len() != b2.len() {
+ t.Fatalf("invalid record length want %d, got %d", b1.len(), b2.len())
+ }
+ p1, p2 := new(testBatch), new(testBatch)
+ err := b1.replay(p1)
+ if err != nil {
+ t.Fatal("error when replaying batch 1: ", err)
+ }
+ err = b2.replay(p2)
+ if err != nil {
+ t.Fatal("error when replaying batch 2: ", err)
+ }
+ for i := range p1.rec {
+ r1, r2 := p1.rec[i], p2.rec[i]
+ if r1.t != r2.t {
+ t.Errorf("invalid type on record '%d' want %d, got %d", i, r1.t, r2.t)
+ }
+ if !bytes.Equal(r1.key, r2.key) {
+ t.Errorf("invalid key on record '%d' want %s, got %s", i, string(r1.key), string(r2.key))
+ }
+ if r1.t == tVal {
+ if !bytes.Equal(r1.value, r2.value) {
+ t.Errorf("invalid value on record '%d' want %s, got %s", i, string(r1.value), string(r2.value))
+ }
+ }
+ }
+}
+
+func TestBatch_EncodeDecode(t *testing.T) {
+ b1 := new(Batch)
+ b1.seq = 10009
+ b1.Put([]byte("key1"), []byte("value1"))
+ b1.Put([]byte("key2"), []byte("value2"))
+ b1.Delete([]byte("key1"))
+ b1.Put([]byte("k"), []byte(""))
+ b1.Put([]byte("zzzzzzzzzzz"), []byte("zzzzzzzzzzzzzzzzzzzzzzzz"))
+ b1.Delete([]byte("key10000"))
+ b1.Delete([]byte("k"))
+ buf := b1.encode()
+ b2 := new(Batch)
+ err := b2.decode(buf)
+ if err != nil {
+ t.Error("error when decoding batch: ", err)
+ }
+ compareBatch(t, b1, b2)
+}
+
+func TestBatch_Append(t *testing.T) {
+ b1 := new(Batch)
+ b1.seq = 10009
+ b1.Put([]byte("key1"), []byte("value1"))
+ b1.Put([]byte("key2"), []byte("value2"))
+ b1.Delete([]byte("key1"))
+ b1.Put([]byte("foo"), []byte("foovalue"))
+ b1.Put([]byte("bar"), []byte("barvalue"))
+ b2a := new(Batch)
+ b2a.seq = 10009
+ b2a.Put([]byte("key1"), []byte("value1"))
+ b2a.Put([]byte("key2"), []byte("value2"))
+ b2a.Delete([]byte("key1"))
+ b2b := new(Batch)
+ b2b.Put([]byte("foo"), []byte("foovalue"))
+ b2b.Put([]byte("bar"), []byte("barvalue"))
+ b2a.append(b2b)
+ compareBatch(t, b1, b2a)
+}
+
+func TestBatch_Size(t *testing.T) {
+ b := new(Batch)
+ for i := 0; i < 2; i++ {
+ b.Put([]byte("key1"), []byte("value1"))
+ b.Put([]byte("key2"), []byte("value2"))
+ b.Delete([]byte("key1"))
+ b.Put([]byte("foo"), []byte("foovalue"))
+ b.Put([]byte("bar"), []byte("barvalue"))
+ mem := memdb.New(&iComparer{comparer.DefaultComparer}, 0)
+ b.memReplay(mem)
+ if b.size() != mem.Size() {
+ t.Errorf("invalid batch size calculation, want=%d got=%d", mem.Size(), b.size())
+ }
+ b.Reset()
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/bench_test.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/bench_test.go
new file mode 100644
index 000000000..ea6801a89
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/bench_test.go
@@ -0,0 +1,461 @@
+// Copyright (c) 2012, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package leveldb
+
+import (
+ "bytes"
+ "fmt"
+ "math/rand"
+ "os"
+ "path/filepath"
+ "runtime"
+ "testing"
+
+ "github.com/syndtr/goleveldb/leveldb/iterator"
+ "github.com/syndtr/goleveldb/leveldb/opt"
+ "github.com/syndtr/goleveldb/leveldb/storage"
+)
+
+func randomString(r *rand.Rand, n int) []byte {
+ b := new(bytes.Buffer)
+ for i := 0; i < n; i++ {
+ b.WriteByte(' ' + byte(r.Intn(95)))
+ }
+ return b.Bytes()
+}
+
+func compressibleStr(r *rand.Rand, frac float32, n int) []byte {
+ nn := int(float32(n) * frac)
+ rb := randomString(r, nn)
+ b := make([]byte, 0, n+nn)
+ for len(b) < n {
+ b = append(b, rb...)
+ }
+ return b[:n]
+}
+
+type valueGen struct {
+ src []byte
+ pos int
+}
+
+func newValueGen(frac float32) *valueGen {
+ v := new(valueGen)
+ r := rand.New(rand.NewSource(301))
+ v.src = make([]byte, 0, 1048576+100)
+ for len(v.src) < 1048576 {
+ v.src = append(v.src, compressibleStr(r, frac, 100)...)
+ }
+ return v
+}
+
+func (v *valueGen) get(n int) []byte {
+ if v.pos+n > len(v.src) {
+ v.pos = 0
+ }
+ v.pos += n
+ return v.src[v.pos-n : v.pos]
+}
+
+var benchDB = filepath.Join(os.TempDir(), fmt.Sprintf("goleveldbbench-%d", os.Getuid()))
+
+type dbBench struct {
+ b *testing.B
+ stor storage.Storage
+ db *DB
+
+ o *opt.Options
+ ro *opt.ReadOptions
+ wo *opt.WriteOptions
+
+ keys, values [][]byte
+}
+
+func openDBBench(b *testing.B, noCompress bool) *dbBench {
+ _, err := os.Stat(benchDB)
+ if err == nil {
+ err = os.RemoveAll(benchDB)
+ if err != nil {
+ b.Fatal("cannot remove old db: ", err)
+ }
+ }
+
+ p := &dbBench{
+ b: b,
+ o: &opt.Options{},
+ ro: &opt.ReadOptions{},
+ wo: &opt.WriteOptions{},
+ }
+ p.stor, err = storage.OpenFile(benchDB)
+ if err != nil {
+ b.Fatal("cannot open stor: ", err)
+ }
+ if noCompress {
+ p.o.Compression = opt.NoCompression
+ }
+
+ p.db, err = Open(p.stor, p.o)
+ if err != nil {
+ b.Fatal("cannot open db: ", err)
+ }
+
+ runtime.GOMAXPROCS(runtime.NumCPU())
+ return p
+}
+
+func (p *dbBench) reopen() {
+ p.db.Close()
+ var err error
+ p.db, err = Open(p.stor, p.o)
+ if err != nil {
+ p.b.Fatal("Reopen: got error: ", err)
+ }
+}
+
+func (p *dbBench) populate(n int) {
+ p.keys, p.values = make([][]byte, n), make([][]byte, n)
+ v := newValueGen(0.5)
+ for i := range p.keys {
+ p.keys[i], p.values[i] = []byte(fmt.Sprintf("%016d", i)), v.get(100)
+ }
+}
+
+func (p *dbBench) randomize() {
+ m := len(p.keys)
+ times := m * 2
+ r1, r2 := rand.New(rand.NewSource(0xdeadbeef)), rand.New(rand.NewSource(0xbeefface))
+ for n := 0; n < times; n++ {
+ i, j := r1.Int()%m, r2.Int()%m
+ if i == j {
+ continue
+ }
+ p.keys[i], p.keys[j] = p.keys[j], p.keys[i]
+ p.values[i], p.values[j] = p.values[j], p.values[i]
+ }
+}
+
+func (p *dbBench) writes(perBatch int) {
+ b := p.b
+ db := p.db
+
+ n := len(p.keys)
+ m := n / perBatch
+ if n%perBatch > 0 {
+ m++
+ }
+ batches := make([]Batch, m)
+ j := 0
+ for i := range batches {
+ first := true
+ for ; j < n && ((j+1)%perBatch != 0 || first); j++ {
+ first = false
+ batches[i].Put(p.keys[j], p.values[j])
+ }
+ }
+ runtime.GC()
+
+ b.ResetTimer()
+ b.StartTimer()
+ for i := range batches {
+ err := db.Write(&(batches[i]), p.wo)
+ if err != nil {
+ b.Fatal("write failed: ", err)
+ }
+ }
+ b.StopTimer()
+ b.SetBytes(116)
+}
+
+func (p *dbBench) drop() {
+ p.keys, p.values = nil, nil
+ runtime.GC()
+}
+
+func (p *dbBench) puts() {
+ b := p.b
+ db := p.db
+
+ b.ResetTimer()
+ b.StartTimer()
+ for i := range p.keys {
+ err := db.Put(p.keys[i], p.values[i], p.wo)
+ if err != nil {
+ b.Fatal("put failed: ", err)
+ }
+ }
+ b.StopTimer()
+ b.SetBytes(116)
+}
+
+func (p *dbBench) fill() {
+ b := p.b
+ db := p.db
+
+ perBatch := 10000
+ batch := new(Batch)
+ for i, n := 0, len(p.keys); i < n; {
+ first := true
+ for ; i < n && ((i+1)%perBatch != 0 || first); i++ {
+ first = false
+ batch.Put(p.keys[i], p.values[i])
+ }
+ err := db.Write(batch, p.wo)
+ if err != nil {
+ b.Fatal("write failed: ", err)
+ }
+ batch.Reset()
+ }
+}
+
+func (p *dbBench) gets() {
+ b := p.b
+ db := p.db
+
+ b.ResetTimer()
+ for i := range p.keys {
+ _, err := db.Get(p.keys[i], p.ro)
+ if err != nil {
+ b.Error("got error: ", err)
+ }
+ }
+ b.StopTimer()
+}
+
+func (p *dbBench) seeks() {
+ b := p.b
+
+ iter := p.newIter()
+ defer iter.Release()
+ b.ResetTimer()
+ for i := range p.keys {
+ if !iter.Seek(p.keys[i]) {
+ b.Error("value not found for: ", string(p.keys[i]))
+ }
+ }
+ b.StopTimer()
+}
+
+func (p *dbBench) newIter() iterator.Iterator {
+ iter := p.db.NewIterator(nil, p.ro)
+ err := iter.Error()
+ if err != nil {
+ p.b.Fatal("cannot create iterator: ", err)
+ }
+ return iter
+}
+
+func (p *dbBench) close() {
+ p.db.Close()
+ p.stor.Close()
+ os.RemoveAll(benchDB)
+ p.db = nil
+ p.keys = nil
+ p.values = nil
+ runtime.GC()
+ runtime.GOMAXPROCS(1)
+}
+
+func BenchmarkDBWrite(b *testing.B) {
+ p := openDBBench(b, false)
+ p.populate(b.N)
+ p.writes(1)
+ p.close()
+}
+
+func BenchmarkDBWriteBatch(b *testing.B) {
+ p := openDBBench(b, false)
+ p.populate(b.N)
+ p.writes(1000)
+ p.close()
+}
+
+func BenchmarkDBWriteUncompressed(b *testing.B) {
+ p := openDBBench(b, true)
+ p.populate(b.N)
+ p.writes(1)
+ p.close()
+}
+
+func BenchmarkDBWriteBatchUncompressed(b *testing.B) {
+ p := openDBBench(b, true)
+ p.populate(b.N)
+ p.writes(1000)
+ p.close()
+}
+
+func BenchmarkDBWriteRandom(b *testing.B) {
+ p := openDBBench(b, false)
+ p.populate(b.N)
+ p.randomize()
+ p.writes(1)
+ p.close()
+}
+
+func BenchmarkDBWriteRandomSync(b *testing.B) {
+ p := openDBBench(b, false)
+ p.wo.Sync = true
+ p.populate(b.N)
+ p.writes(1)
+ p.close()
+}
+
+func BenchmarkDBOverwrite(b *testing.B) {
+ p := openDBBench(b, false)
+ p.populate(b.N)
+ p.writes(1)
+ p.writes(1)
+ p.close()
+}
+
+func BenchmarkDBOverwriteRandom(b *testing.B) {
+ p := openDBBench(b, false)
+ p.populate(b.N)
+ p.writes(1)
+ p.randomize()
+ p.writes(1)
+ p.close()
+}
+
+func BenchmarkDBPut(b *testing.B) {
+ p := openDBBench(b, false)
+ p.populate(b.N)
+ p.puts()
+ p.close()
+}
+
+func BenchmarkDBRead(b *testing.B) {
+ p := openDBBench(b, false)
+ p.populate(b.N)
+ p.fill()
+ p.drop()
+
+ iter := p.newIter()
+ b.ResetTimer()
+ for iter.Next() {
+ }
+ iter.Release()
+ b.StopTimer()
+ b.SetBytes(116)
+ p.close()
+}
+
+func BenchmarkDBReadGC(b *testing.B) {
+ p := openDBBench(b, false)
+ p.populate(b.N)
+ p.fill()
+
+ iter := p.newIter()
+ b.ResetTimer()
+ for iter.Next() {
+ }
+ iter.Release()
+ b.StopTimer()
+ b.SetBytes(116)
+ p.close()
+}
+
+func BenchmarkDBReadUncompressed(b *testing.B) {
+ p := openDBBench(b, true)
+ p.populate(b.N)
+ p.fill()
+ p.drop()
+
+ iter := p.newIter()
+ b.ResetTimer()
+ for iter.Next() {
+ }
+ iter.Release()
+ b.StopTimer()
+ b.SetBytes(116)
+ p.close()
+}
+
+func BenchmarkDBReadTable(b *testing.B) {
+ p := openDBBench(b, false)
+ p.populate(b.N)
+ p.fill()
+ p.reopen()
+ p.drop()
+
+ iter := p.newIter()
+ b.ResetTimer()
+ for iter.Next() {
+ }
+ iter.Release()
+ b.StopTimer()
+ b.SetBytes(116)
+ p.close()
+}
+
+func BenchmarkDBReadReverse(b *testing.B) {
+ p := openDBBench(b, false)
+ p.populate(b.N)
+ p.fill()
+ p.drop()
+
+ iter := p.newIter()
+ b.ResetTimer()
+ iter.Last()
+ for iter.Prev() {
+ }
+ iter.Release()
+ b.StopTimer()
+ b.SetBytes(116)
+ p.close()
+}
+
+func BenchmarkDBReadReverseTable(b *testing.B) {
+ p := openDBBench(b, false)
+ p.populate(b.N)
+ p.fill()
+ p.reopen()
+ p.drop()
+
+ iter := p.newIter()
+ b.ResetTimer()
+ iter.Last()
+ for iter.Prev() {
+ }
+ iter.Release()
+ b.StopTimer()
+ b.SetBytes(116)
+ p.close()
+}
+
+func BenchmarkDBSeek(b *testing.B) {
+ p := openDBBench(b, false)
+ p.populate(b.N)
+ p.fill()
+ p.seeks()
+ p.close()
+}
+
+func BenchmarkDBSeekRandom(b *testing.B) {
+ p := openDBBench(b, false)
+ p.populate(b.N)
+ p.fill()
+ p.randomize()
+ p.seeks()
+ p.close()
+}
+
+func BenchmarkDBGet(b *testing.B) {
+ p := openDBBench(b, false)
+ p.populate(b.N)
+ p.fill()
+ p.gets()
+ p.close()
+}
+
+func BenchmarkDBGetRandom(b *testing.B) {
+ p := openDBBench(b, false)
+ p.populate(b.N)
+ p.fill()
+ p.randomize()
+ p.gets()
+ p.close()
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/cache/cache.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/cache/cache.go
new file mode 100644
index 000000000..9b6a74977
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/cache/cache.go
@@ -0,0 +1,125 @@
+// Copyright (c) 2012, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Package cache provides interface and implementation of a cache algorithms.
+package cache
+
+import (
+ "sync/atomic"
+)
+
+// SetFunc used by Namespace.Get method to create a cache object. SetFunc
+// may return ok false, in that case the cache object will not be created.
+type SetFunc func() (ok bool, value interface{}, charge int, fin SetFin)
+
+// SetFin will be called when corresponding cache object are released.
+type SetFin func()
+
+// DelFin will be called when corresponding cache object are released.
+// DelFin will be called after SetFin. The exist is true if the corresponding
+// cache object is actually exist in the cache tree.
+type DelFin func(exist bool)
+
+// PurgeFin will be called when corresponding cache object are released.
+// PurgeFin will be called after SetFin. If PurgeFin present DelFin will
+// not be executed but passed to the PurgeFin, it is up to the caller
+// to call it or not.
+type PurgeFin func(ns, key uint64, delfin DelFin)
+
+// Cache is a cache tree.
+type Cache interface {
+ // SetCapacity sets cache capacity.
+ SetCapacity(capacity int)
+
+ // GetNamespace gets or creates a cache namespace for the given id.
+ GetNamespace(id uint64) Namespace
+
+ // Purge purges all cache namespaces, read Namespace.Purge method documentation.
+ Purge(fin PurgeFin)
+
+ // Zap zaps all cache namespaces, read Namespace.Zap method documentation.
+ Zap(closed bool)
+}
+
+// Namespace is a cache namespace.
+type Namespace interface {
+ // Get gets cache object for the given key. The given SetFunc (if not nil) will
+ // be called if the given key does not exist.
+ // If the given key does not exist, SetFunc is nil or SetFunc return ok false, Get
+ // will return ok false.
+ Get(key uint64, setf SetFunc) (obj Object, ok bool)
+
+ // Get deletes cache object for the given key. If exist the cache object will
+ // be deleted later when all of its handles have been released (i.e. no one use
+ // it anymore) and the given DelFin (if not nil) will finally be executed. If
+ // such cache object does not exist the given DelFin will be executed anyway.
+ //
+ // Delete returns true if such cache object exist.
+ Delete(key uint64, fin DelFin) bool
+
+ // Purge deletes all cache objects, read Delete method documentation.
+ Purge(fin PurgeFin)
+
+ // Zap detaches the namespace from the cache tree and delete all its cache
+ // objects. The cache objects deletion and finalizers execution are happen
+ // immediately, even if its existing handles haven't yet been released.
+ // A zapped namespace can't never be filled again.
+ // If closed is false then the Get function will always call the given SetFunc
+ // if it is not nil, but resultant of the SetFunc will not be cached.
+ Zap(closed bool)
+}
+
+// Object is a cache object.
+type Object interface {
+ // Release releases the cache object. Other methods should not be called
+ // after the cache object has been released.
+ Release()
+
+ // Value returns value of the cache object.
+ Value() interface{}
+}
+
+// Namespace state.
+type nsState int
+
+const (
+ nsEffective nsState = iota
+ nsZapped
+ nsClosed
+)
+
+// Node state.
+type nodeState int
+
+const (
+ nodeEffective nodeState = iota
+ nodeEvicted
+ nodeRemoved
+)
+
+// Fake object.
+type fakeObject struct {
+ value interface{}
+ fin func()
+ once uint32
+}
+
+func (o *fakeObject) Value() interface{} {
+ if atomic.LoadUint32(&o.once) == 0 {
+ return o.value
+ }
+ return nil
+}
+
+func (o *fakeObject) Release() {
+ if !atomic.CompareAndSwapUint32(&o.once, 0, 1) {
+ return
+ }
+ if o.fin != nil {
+ o.fin()
+ o.fin = nil
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/cache/cache_test.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/cache/cache_test.go
new file mode 100644
index 000000000..07a9939b2
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/cache/cache_test.go
@@ -0,0 +1,236 @@
+// Copyright (c) 2012, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package cache
+
+import (
+ "math/rand"
+ "testing"
+)
+
+func set(ns Namespace, key uint64, value interface{}, charge int, fin func()) Object {
+ obj, _ := ns.Get(key, func() (bool, interface{}, int, SetFin) {
+ return true, value, charge, fin
+ })
+ return obj
+}
+
+func TestCache_HitMiss(t *testing.T) {
+ cases := []struct {
+ key uint64
+ value string
+ }{
+ {1, "vvvvvvvvv"},
+ {100, "v1"},
+ {0, "v2"},
+ {12346, "v3"},
+ {777, "v4"},
+ {999, "v5"},
+ {7654, "v6"},
+ {2, "v7"},
+ {3, "v8"},
+ {9, "v9"},
+ }
+
+ setfin := 0
+ c := NewLRUCache(1000)
+ ns := c.GetNamespace(0)
+ for i, x := range cases {
+ set(ns, x.key, x.value, len(x.value), func() {
+ setfin++
+ }).Release()
+ for j, y := range cases {
+ r, ok := ns.Get(y.key, nil)
+ if j <= i {
+ // should hit
+ if !ok {
+ t.Errorf("case '%d' iteration '%d' is miss", i, j)
+ } else if r.Value().(string) != y.value {
+ t.Errorf("case '%d' iteration '%d' has invalid value got '%s', want '%s'", i, j, r.Value().(string), y.value)
+ }
+ } else {
+ // should miss
+ if ok {
+ t.Errorf("case '%d' iteration '%d' is hit , value '%s'", i, j, r.Value().(string))
+ }
+ }
+ if ok {
+ r.Release()
+ }
+ }
+ }
+
+ for i, x := range cases {
+ finalizerOk := false
+ ns.Delete(x.key, func(exist bool) {
+ finalizerOk = true
+ })
+
+ if !finalizerOk {
+ t.Errorf("case %d delete finalizer not executed", i)
+ }
+
+ for j, y := range cases {
+ r, ok := ns.Get(y.key, nil)
+ if j > i {
+ // should hit
+ if !ok {
+ t.Errorf("case '%d' iteration '%d' is miss", i, j)
+ } else if r.Value().(string) != y.value {
+ t.Errorf("case '%d' iteration '%d' has invalid value got '%s', want '%s'", i, j, r.Value().(string), y.value)
+ }
+ } else {
+ // should miss
+ if ok {
+ t.Errorf("case '%d' iteration '%d' is hit, value '%s'", i, j, r.Value().(string))
+ }
+ }
+ if ok {
+ r.Release()
+ }
+ }
+ }
+
+ if setfin != len(cases) {
+ t.Errorf("some set finalizer may not be executed, want=%d got=%d", len(cases), setfin)
+ }
+}
+
+func TestLRUCache_Eviction(t *testing.T) {
+ c := NewLRUCache(12)
+ ns := c.GetNamespace(0)
+ o1 := set(ns, 1, 1, 1, nil)
+ set(ns, 2, 2, 1, nil).Release()
+ set(ns, 3, 3, 1, nil).Release()
+ set(ns, 4, 4, 1, nil).Release()
+ set(ns, 5, 5, 1, nil).Release()
+ if r, ok := ns.Get(2, nil); ok { // 1,3,4,5,2
+ r.Release()
+ }
+ set(ns, 9, 9, 10, nil).Release() // 5,2,9
+
+ for _, x := range []uint64{9, 2, 5, 1} {
+ r, ok := ns.Get(x, nil)
+ if !ok {
+ t.Errorf("miss for key '%d'", x)
+ } else {
+ if r.Value().(int) != int(x) {
+ t.Errorf("invalid value for key '%d' want '%d', got '%d'", x, x, r.Value().(int))
+ }
+ r.Release()
+ }
+ }
+ o1.Release()
+ for _, x := range []uint64{1, 2, 5} {
+ r, ok := ns.Get(x, nil)
+ if !ok {
+ t.Errorf("miss for key '%d'", x)
+ } else {
+ if r.Value().(int) != int(x) {
+ t.Errorf("invalid value for key '%d' want '%d', got '%d'", x, x, r.Value().(int))
+ }
+ r.Release()
+ }
+ }
+ for _, x := range []uint64{3, 4, 9} {
+ r, ok := ns.Get(x, nil)
+ if ok {
+ t.Errorf("hit for key '%d'", x)
+ if r.Value().(int) != int(x) {
+ t.Errorf("invalid value for key '%d' want '%d', got '%d'", x, x, r.Value().(int))
+ }
+ r.Release()
+ }
+ }
+}
+
+func TestLRUCache_SetGet(t *testing.T) {
+ c := NewLRUCache(13)
+ ns := c.GetNamespace(0)
+ for i := 0; i < 200; i++ {
+ n := uint64(rand.Intn(99999) % 20)
+ set(ns, n, n, 1, nil).Release()
+ if p, ok := ns.Get(n, nil); ok {
+ if p.Value() == nil {
+ t.Errorf("key '%d' contains nil value", n)
+ } else {
+ got := p.Value().(uint64)
+ if got != n {
+ t.Errorf("invalid value for key '%d' want '%d', got '%d'", n, n, got)
+ }
+ }
+ p.Release()
+ } else {
+ t.Errorf("key '%d' doesn't exist", n)
+ }
+ }
+}
+
+func TestLRUCache_Purge(t *testing.T) {
+ c := NewLRUCache(3)
+ ns1 := c.GetNamespace(0)
+ o1 := set(ns1, 1, 1, 1, nil)
+ o2 := set(ns1, 2, 2, 1, nil)
+ ns1.Purge(nil)
+ set(ns1, 3, 3, 1, nil).Release()
+ for _, x := range []uint64{1, 2, 3} {
+ r, ok := ns1.Get(x, nil)
+ if !ok {
+ t.Errorf("miss for key '%d'", x)
+ } else {
+ if r.Value().(int) != int(x) {
+ t.Errorf("invalid value for key '%d' want '%d', got '%d'", x, x, r.Value().(int))
+ }
+ r.Release()
+ }
+ }
+ o1.Release()
+ o2.Release()
+ for _, x := range []uint64{1, 2} {
+ r, ok := ns1.Get(x, nil)
+ if ok {
+ t.Errorf("hit for key '%d'", x)
+ if r.Value().(int) != int(x) {
+ t.Errorf("invalid value for key '%d' want '%d', got '%d'", x, x, r.Value().(int))
+ }
+ r.Release()
+ }
+ }
+}
+
+func BenchmarkLRUCache_SetRelease(b *testing.B) {
+ capacity := b.N / 100
+ if capacity <= 0 {
+ capacity = 10
+ }
+ c := NewLRUCache(capacity)
+ ns := c.GetNamespace(0)
+ b.ResetTimer()
+ for i := uint64(0); i < uint64(b.N); i++ {
+ set(ns, i, nil, 1, nil).Release()
+ }
+}
+
+func BenchmarkLRUCache_SetReleaseTwice(b *testing.B) {
+ capacity := b.N / 100
+ if capacity <= 0 {
+ capacity = 10
+ }
+ c := NewLRUCache(capacity)
+ ns := c.GetNamespace(0)
+ b.ResetTimer()
+
+ na := b.N / 2
+ nb := b.N - na
+
+ for i := uint64(0); i < uint64(na); i++ {
+ set(ns, i, nil, 1, nil).Release()
+ }
+
+ for i := uint64(0); i < uint64(nb); i++ {
+ set(ns, i, nil, 1, nil).Release()
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/cache/empty_cache.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/cache/empty_cache.go
new file mode 100644
index 000000000..1fbf81459
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/cache/empty_cache.go
@@ -0,0 +1,246 @@
+// Copyright (c) 2013, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package cache
+
+import (
+ "sync"
+ "sync/atomic"
+)
+
+type emptyCache struct {
+ sync.Mutex
+ table map[uint64]*emptyNS
+}
+
+// NewEmptyCache creates a new initialized empty cache.
+func NewEmptyCache() Cache {
+ return &emptyCache{
+ table: make(map[uint64]*emptyNS),
+ }
+}
+
+func (c *emptyCache) GetNamespace(id uint64) Namespace {
+ c.Lock()
+ defer c.Unlock()
+
+ if ns, ok := c.table[id]; ok {
+ return ns
+ }
+
+ ns := &emptyNS{
+ cache: c,
+ id: id,
+ table: make(map[uint64]*emptyNode),
+ }
+ c.table[id] = ns
+ return ns
+}
+
+func (c *emptyCache) Purge(fin PurgeFin) {
+ c.Lock()
+ for _, ns := range c.table {
+ ns.purgeNB(fin)
+ }
+ c.Unlock()
+}
+
+func (c *emptyCache) Zap(closed bool) {
+ c.Lock()
+ for _, ns := range c.table {
+ ns.zapNB(closed)
+ }
+ c.table = make(map[uint64]*emptyNS)
+ c.Unlock()
+}
+
+func (*emptyCache) SetCapacity(capacity int) {}
+
+type emptyNS struct {
+ cache *emptyCache
+ id uint64
+ table map[uint64]*emptyNode
+ state nsState
+}
+
+func (ns *emptyNS) Get(key uint64, setf SetFunc) (o Object, ok bool) {
+ ns.cache.Lock()
+
+ switch ns.state {
+ case nsZapped:
+ ns.cache.Unlock()
+ if setf == nil {
+ return
+ }
+
+ var value interface{}
+ var fin func()
+ ok, value, _, fin = setf()
+ if ok {
+ o = &fakeObject{
+ value: value,
+ fin: fin,
+ }
+ }
+ return
+ case nsClosed:
+ ns.cache.Unlock()
+ return
+ }
+
+ n, ok := ns.table[key]
+ if ok {
+ n.ref++
+ } else {
+ if setf == nil {
+ ns.cache.Unlock()
+ return
+ }
+
+ var value interface{}
+ var fin func()
+ ok, value, _, fin = setf()
+ if !ok {
+ ns.cache.Unlock()
+ return
+ }
+
+ n = &emptyNode{
+ ns: ns,
+ key: key,
+ value: value,
+ setfin: fin,
+ ref: 1,
+ }
+ ns.table[key] = n
+ }
+
+ ns.cache.Unlock()
+ o = &emptyObject{node: n}
+ return
+}
+
+func (ns *emptyNS) Delete(key uint64, fin DelFin) bool {
+ ns.cache.Lock()
+
+ if ns.state != nsEffective {
+ ns.cache.Unlock()
+ if fin != nil {
+ fin(false)
+ }
+ return false
+ }
+
+ n, ok := ns.table[key]
+ if !ok {
+ ns.cache.Unlock()
+ if fin != nil {
+ fin(false)
+ }
+ return false
+ }
+ n.delfin = fin
+ ns.cache.Unlock()
+ return true
+}
+
+func (ns *emptyNS) purgeNB(fin PurgeFin) {
+ if ns.state != nsEffective {
+ return
+ }
+ for _, n := range ns.table {
+ n.purgefin = fin
+ }
+}
+
+func (ns *emptyNS) Purge(fin PurgeFin) {
+ ns.cache.Lock()
+ ns.purgeNB(fin)
+ ns.cache.Unlock()
+}
+
+func (ns *emptyNS) zapNB(closed bool) {
+ if ns.state != nsEffective {
+ return
+ }
+ for _, n := range ns.table {
+ n.execFin()
+ }
+ if closed {
+ ns.state = nsClosed
+ } else {
+ ns.state = nsZapped
+ }
+ ns.table = nil
+}
+
+func (ns *emptyNS) Zap(closed bool) {
+ ns.cache.Lock()
+ ns.zapNB(closed)
+ delete(ns.cache.table, ns.id)
+ ns.cache.Unlock()
+}
+
+type emptyNode struct {
+ ns *emptyNS
+ key uint64
+ value interface{}
+ ref int
+ setfin SetFin
+ delfin DelFin
+ purgefin PurgeFin
+}
+
+func (n *emptyNode) execFin() {
+ if n.setfin != nil {
+ n.setfin()
+ n.setfin = nil
+ }
+ if n.purgefin != nil {
+ n.purgefin(n.ns.id, n.key, n.delfin)
+ n.delfin = nil
+ n.purgefin = nil
+ } else if n.delfin != nil {
+ n.delfin(true)
+ n.delfin = nil
+ }
+}
+
+func (n *emptyNode) evict() {
+ n.ns.cache.Lock()
+ n.ref--
+ if n.ref == 0 {
+ if n.ns.state == nsEffective {
+ // Remove elem.
+ delete(n.ns.table, n.key)
+ // Execute finalizer.
+ n.execFin()
+ }
+ } else if n.ref < 0 {
+ panic("leveldb/cache: emptyNode: negative node reference")
+ }
+ n.ns.cache.Unlock()
+}
+
+type emptyObject struct {
+ node *emptyNode
+ once uint32
+}
+
+func (o *emptyObject) Value() interface{} {
+ if atomic.LoadUint32(&o.once) == 0 {
+ return o.node.value
+ }
+ return nil
+}
+
+func (o *emptyObject) Release() {
+ if !atomic.CompareAndSwapUint32(&o.once, 0, 1) {
+ return
+ }
+ o.node.evict()
+ o.node = nil
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/cache/lru_cache.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/cache/lru_cache.go
new file mode 100644
index 000000000..3c98e076b
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/cache/lru_cache.go
@@ -0,0 +1,354 @@
+// Copyright (c) 2012, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package cache
+
+import (
+ "sync"
+ "sync/atomic"
+)
+
+// lruCache represent a LRU cache state.
+type lruCache struct {
+ sync.Mutex
+
+ recent lruNode
+ table map[uint64]*lruNs
+ capacity int
+ size int
+}
+
+// NewLRUCache creates a new initialized LRU cache with the given capacity.
+func NewLRUCache(capacity int) Cache {
+ c := &lruCache{
+ table: make(map[uint64]*lruNs),
+ capacity: capacity,
+ }
+ c.recent.rNext = &c.recent
+ c.recent.rPrev = &c.recent
+ return c
+}
+
+// SetCapacity set cache capacity.
+func (c *lruCache) SetCapacity(capacity int) {
+ c.Lock()
+ c.capacity = capacity
+ c.evict()
+ c.Unlock()
+}
+
+// GetNamespace return namespace object for given id.
+func (c *lruCache) GetNamespace(id uint64) Namespace {
+ c.Lock()
+ defer c.Unlock()
+
+ if p, ok := c.table[id]; ok {
+ return p
+ }
+
+ p := &lruNs{
+ lru: c,
+ id: id,
+ table: make(map[uint64]*lruNode),
+ }
+ c.table[id] = p
+ return p
+}
+
+// Purge purge entire cache.
+func (c *lruCache) Purge(fin PurgeFin) {
+ c.Lock()
+ for _, ns := range c.table {
+ ns.purgeNB(fin)
+ }
+ c.Unlock()
+}
+
+func (c *lruCache) Zap(closed bool) {
+ c.Lock()
+ for _, ns := range c.table {
+ ns.zapNB(closed)
+ }
+ c.table = make(map[uint64]*lruNs)
+ c.Unlock()
+}
+
+func (c *lruCache) evict() {
+ top := &c.recent
+ for n := c.recent.rPrev; c.size > c.capacity && n != top; {
+ n.state = nodeEvicted
+ n.rRemove()
+ n.evictNB()
+ c.size -= n.charge
+ n = c.recent.rPrev
+ }
+}
+
+type lruNs struct {
+ lru *lruCache
+ id uint64
+ table map[uint64]*lruNode
+ state nsState
+}
+
+func (ns *lruNs) Get(key uint64, setf SetFunc) (o Object, ok bool) {
+ lru := ns.lru
+ lru.Lock()
+
+ switch ns.state {
+ case nsZapped:
+ lru.Unlock()
+ if setf == nil {
+ return
+ }
+
+ var value interface{}
+ var fin func()
+ ok, value, _, fin = setf()
+ if ok {
+ o = &fakeObject{
+ value: value,
+ fin: fin,
+ }
+ }
+ return
+ case nsClosed:
+ lru.Unlock()
+ return
+ }
+
+ n, ok := ns.table[key]
+ if ok {
+ switch n.state {
+ case nodeEvicted:
+ // Insert to recent list.
+ n.state = nodeEffective
+ n.ref++
+ lru.size += n.charge
+ lru.evict()
+ fallthrough
+ case nodeEffective:
+ // Bump to front
+ n.rRemove()
+ n.rInsert(&lru.recent)
+ }
+ n.ref++
+ } else {
+ if setf == nil {
+ lru.Unlock()
+ return
+ }
+
+ var value interface{}
+ var charge int
+ var fin func()
+ ok, value, charge, fin = setf()
+ if !ok {
+ lru.Unlock()
+ return
+ }
+
+ n = &lruNode{
+ ns: ns,
+ key: key,
+ value: value,
+ charge: charge,
+ setfin: fin,
+ ref: 2,
+ }
+ ns.table[key] = n
+ n.rInsert(&lru.recent)
+
+ lru.size += charge
+ lru.evict()
+ }
+
+ lru.Unlock()
+ o = &lruObject{node: n}
+ return
+}
+
+func (ns *lruNs) Delete(key uint64, fin DelFin) bool {
+ lru := ns.lru
+ lru.Lock()
+
+ if ns.state != nsEffective {
+ lru.Unlock()
+ if fin != nil {
+ fin(false)
+ }
+ return false
+ }
+
+ n, ok := ns.table[key]
+ if !ok {
+ lru.Unlock()
+ if fin != nil {
+ fin(false)
+ }
+ return false
+ }
+
+ n.delfin = fin
+ switch n.state {
+ case nodeRemoved:
+ lru.Unlock()
+ return false
+ case nodeEffective:
+ lru.size -= n.charge
+ n.rRemove()
+ n.evictNB()
+ }
+ n.state = nodeRemoved
+
+ lru.Unlock()
+ return true
+}
+
+func (ns *lruNs) purgeNB(fin PurgeFin) {
+ lru := ns.lru
+ if ns.state != nsEffective {
+ return
+ }
+
+ for _, n := range ns.table {
+ n.purgefin = fin
+ if n.state == nodeEffective {
+ lru.size -= n.charge
+ n.rRemove()
+ n.evictNB()
+ }
+ n.state = nodeRemoved
+ }
+}
+
+func (ns *lruNs) Purge(fin PurgeFin) {
+ ns.lru.Lock()
+ ns.purgeNB(fin)
+ ns.lru.Unlock()
+}
+
+func (ns *lruNs) zapNB(closed bool) {
+ lru := ns.lru
+ if ns.state != nsEffective {
+ return
+ }
+
+ if closed {
+ ns.state = nsClosed
+ } else {
+ ns.state = nsZapped
+ }
+ for _, n := range ns.table {
+ if n.state == nodeEffective {
+ lru.size -= n.charge
+ n.rRemove()
+ }
+ n.state = nodeRemoved
+ n.execFin()
+ }
+ ns.table = nil
+}
+
+func (ns *lruNs) Zap(closed bool) {
+ ns.lru.Lock()
+ ns.zapNB(closed)
+ delete(ns.lru.table, ns.id)
+ ns.lru.Unlock()
+}
+
+type lruNode struct {
+ ns *lruNs
+
+ rNext, rPrev *lruNode
+
+ key uint64
+ value interface{}
+ charge int
+ ref int
+ state nodeState
+ setfin SetFin
+ delfin DelFin
+ purgefin PurgeFin
+}
+
+func (n *lruNode) rInsert(at *lruNode) {
+ x := at.rNext
+ at.rNext = n
+ n.rPrev = at
+ n.rNext = x
+ x.rPrev = n
+}
+
+func (n *lruNode) rRemove() bool {
+ // only remove if not already removed
+ if n.rPrev == nil {
+ return false
+ }
+
+ n.rPrev.rNext = n.rNext
+ n.rNext.rPrev = n.rPrev
+ n.rPrev = nil
+ n.rNext = nil
+
+ return true
+}
+
+func (n *lruNode) execFin() {
+ if n.setfin != nil {
+ n.setfin()
+ n.setfin = nil
+ }
+ if n.purgefin != nil {
+ n.purgefin(n.ns.id, n.key, n.delfin)
+ n.delfin = nil
+ n.purgefin = nil
+ } else if n.delfin != nil {
+ n.delfin(true)
+ n.delfin = nil
+ }
+}
+
+func (n *lruNode) evictNB() {
+ n.ref--
+ if n.ref == 0 {
+ if n.ns.state == nsEffective {
+ // remove elem
+ delete(n.ns.table, n.key)
+ // execute finalizer
+ n.execFin()
+ }
+ } else if n.ref < 0 {
+ panic("leveldb/cache: lruCache: negative node reference")
+ }
+}
+
+func (n *lruNode) evict() {
+ n.ns.lru.Lock()
+ n.evictNB()
+ n.ns.lru.Unlock()
+}
+
+type lruObject struct {
+ node *lruNode
+ once uint32
+}
+
+func (o *lruObject) Value() interface{} {
+ if atomic.LoadUint32(&o.once) == 0 {
+ return o.node.value
+ }
+ return nil
+}
+
+func (o *lruObject) Release() {
+ if !atomic.CompareAndSwapUint32(&o.once, 0, 1) {
+ return
+ }
+
+ o.node.evict()
+ o.node = nil
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/comparer.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/comparer.go
new file mode 100644
index 000000000..d33d5e9c7
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/comparer.go
@@ -0,0 +1,75 @@
+// Copyright (c) 2012, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package leveldb
+
+import "github.com/syndtr/goleveldb/leveldb/comparer"
+
+type iComparer struct {
+ ucmp comparer.Comparer
+}
+
+func (icmp *iComparer) uName() string {
+ return icmp.ucmp.Name()
+}
+
+func (icmp *iComparer) uCompare(a, b []byte) int {
+ return icmp.ucmp.Compare(a, b)
+}
+
+func (icmp *iComparer) uSeparator(dst, a, b []byte) []byte {
+ return icmp.ucmp.Separator(dst, a, b)
+}
+
+func (icmp *iComparer) uSuccessor(dst, b []byte) []byte {
+ return icmp.ucmp.Successor(dst, b)
+}
+
+func (icmp *iComparer) Name() string {
+ return icmp.uName()
+}
+
+func (icmp *iComparer) Compare(a, b []byte) int {
+ x := icmp.ucmp.Compare(iKey(a).ukey(), iKey(b).ukey())
+ if x == 0 {
+ if m, n := iKey(a).num(), iKey(b).num(); m > n {
+ x = -1
+ } else if m < n {
+ x = 1
+ }
+ }
+ return x
+}
+
+func (icmp *iComparer) Separator(dst, a, b []byte) []byte {
+ ua, ub := iKey(a).ukey(), iKey(b).ukey()
+ dst = icmp.ucmp.Separator(dst, ua, ub)
+ if dst == nil {
+ return nil
+ }
+ if len(dst) < len(ua) && icmp.uCompare(ua, dst) < 0 {
+ dst = append(dst, kMaxNumBytes...)
+ } else {
+ // Did not close possibilities that n maybe longer than len(ub).
+ dst = append(dst, a[len(a)-8:]...)
+ }
+ return dst
+}
+
+func (icmp *iComparer) Successor(dst, b []byte) []byte {
+ ub := iKey(b).ukey()
+ dst = icmp.ucmp.Successor(dst, ub)
+ if dst == nil {
+ return nil
+ }
+ if len(dst) < len(ub) && icmp.uCompare(ub, dst) < 0 {
+ dst = append(dst, kMaxNumBytes...)
+ } else {
+ // Did not close possibilities that n maybe longer than len(ub).
+ dst = append(dst, b[len(b)-8:]...)
+ }
+ return dst
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/comparer/bytes_comparer.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/comparer/bytes_comparer.go
new file mode 100644
index 000000000..14dddf88d
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/comparer/bytes_comparer.go
@@ -0,0 +1,51 @@
+// Copyright (c) 2012, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package comparer
+
+import "bytes"
+
+type bytesComparer struct{}
+
+func (bytesComparer) Compare(a, b []byte) int {
+ return bytes.Compare(a, b)
+}
+
+func (bytesComparer) Name() string {
+ return "leveldb.BytewiseComparator"
+}
+
+func (bytesComparer) Separator(dst, a, b []byte) []byte {
+ i, n := 0, len(a)
+ if n > len(b) {
+ n = len(b)
+ }
+ for ; i < n && a[i] == b[i]; i++ {
+ }
+ if i >= n {
+ // Do not shorten if one string is a prefix of the other
+ } else if c := a[i]; c < 0xff && c+1 < b[i] {
+ dst = append(dst, a[:i+1]...)
+ dst[i]++
+ return dst
+ }
+ return nil
+}
+
+func (bytesComparer) Successor(dst, b []byte) []byte {
+ for i, c := range b {
+ if c != 0xff {
+ dst = append(dst, b[:i+1]...)
+ dst[i]++
+ return dst
+ }
+ }
+ return nil
+}
+
+// DefaultComparer are default implementation of the Comparer interface.
+// It uses the natural ordering, consistent with bytes.Compare.
+var DefaultComparer = bytesComparer{}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/comparer/comparer.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/comparer/comparer.go
new file mode 100644
index 000000000..14a28f16f
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/comparer/comparer.go
@@ -0,0 +1,57 @@
+// Copyright (c) 2012, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Package comparer provides interface and implementation for ordering
+// sets of data.
+package comparer
+
+// BasicComparer is the interface that wraps the basic Compare method.
+type BasicComparer interface {
+ // Compare returns -1, 0, or +1 depending on whether a is 'less than',
+ // 'equal to' or 'greater than' b. The two arguments can only be 'equal'
+ // if their contents are exactly equal. Furthermore, the empty slice
+ // must be 'less than' any non-empty slice.
+ Compare(a, b []byte) int
+}
+
+// Comparer defines a total ordering over the space of []byte keys: a 'less
+// than' relationship.
+type Comparer interface {
+ BasicComparer
+
+ // Name returns name of the comparer.
+ //
+ // The Level-DB on-disk format stores the comparer name, and opening a
+ // database with a different comparer from the one it was created with
+ // will result in an error.
+ //
+ // An implementation to a new name whenever the comparer implementation
+ // changes in a way that will cause the relative ordering of any two keys
+ // to change.
+ //
+ // Names starting with "leveldb." are reserved and should not be used
+ // by any users of this package.
+ Name() string
+
+ // Bellow are advanced functions used used to reduce the space requirements
+ // for internal data structures such as index blocks.
+
+ // Separator appends a sequence of bytes x to dst such that a <= x && x < b,
+ // where 'less than' is consistent with Compare. An implementation should
+ // return nil if x equal to a.
+ //
+ // Either contents of a or b should not by any means modified. Doing so
+ // may cause corruption on the internal state.
+ Separator(dst, a, b []byte) []byte
+
+ // Successor appends a sequence of bytes x to dst such that x >= b, where
+ // 'less than' is consistent with Compare. An implementation should return
+ // nil if x equal to b.
+ //
+ // Contents of b should not by any means modified. Doing so may cause
+ // corruption on the internal state.
+ Successor(dst, b []byte) []byte
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/config.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/config.go
new file mode 100644
index 000000000..511058897
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/config.go
@@ -0,0 +1,40 @@
+// Copyright (c) 2012, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package leveldb
+
+const (
+ kNumLevels = 7
+
+ // Level-0 compaction is started when we hit this many files.
+ kL0_CompactionTrigger float64 = 4
+
+ // Soft limit on number of level-0 files. We slow down writes at this point.
+ kL0_SlowdownWritesTrigger = 8
+
+ // Maximum number of level-0 files. We stop writes at this point.
+ kL0_StopWritesTrigger = 12
+
+ // Maximum level to which a new compacted memdb is pushed if it
+ // does not create overlap. We try to push to level 2 to avoid the
+ // relatively expensive level 0=>1 compactions and to avoid some
+ // expensive manifest file operations. We do not push all the way to
+ // the largest level since that can generate a lot of wasted disk
+ // space if the same key space is being repeatedly overwritten.
+ kMaxMemCompactLevel = 2
+
+ // Maximum size of a table.
+ kMaxTableSize = 2 * 1048576
+
+ // Maximum bytes of overlaps in grandparent (i.e., level+2) before we
+ // stop building a single file in a level->level+1 compaction.
+ kMaxGrandParentOverlapBytes = 10 * kMaxTableSize
+
+ // Maximum number of bytes in all compacted files. We avoid expanding
+ // the lower level file set of a compaction if it would make the
+ // total compaction cover more than this many bytes.
+ kExpCompactionMaxBytes = 25 * kMaxTableSize
+)
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/corrupt_test.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/corrupt_test.go
new file mode 100644
index 000000000..a036e0893
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/corrupt_test.go
@@ -0,0 +1,472 @@
+// Copyright (c) 2013, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package leveldb
+
+import (
+ "bytes"
+ "fmt"
+ "io"
+ "math/rand"
+ "testing"
+
+ "github.com/syndtr/goleveldb/leveldb/cache"
+ "github.com/syndtr/goleveldb/leveldb/opt"
+ "github.com/syndtr/goleveldb/leveldb/storage"
+)
+
+const ctValSize = 1000
+
+type dbCorruptHarness struct {
+ dbHarness
+}
+
+func newDbCorruptHarnessWopt(t *testing.T, o *opt.Options) *dbCorruptHarness {
+ h := new(dbCorruptHarness)
+ h.init(t, o)
+ return h
+}
+
+func newDbCorruptHarness(t *testing.T) *dbCorruptHarness {
+ return newDbCorruptHarnessWopt(t, &opt.Options{
+ BlockCache: cache.NewLRUCache(100),
+ Strict: opt.StrictJournalChecksum,
+ })
+}
+
+func (h *dbCorruptHarness) recover() {
+ p := &h.dbHarness
+ t := p.t
+
+ var err error
+ p.db, err = Recover(h.stor, h.o)
+ if err != nil {
+ t.Fatal("Repair: got error: ", err)
+ }
+}
+
+func (h *dbCorruptHarness) build(n int) {
+ p := &h.dbHarness
+ t := p.t
+ db := p.db
+
+ batch := new(Batch)
+ for i := 0; i < n; i++ {
+ batch.Reset()
+ batch.Put(tkey(i), tval(i, ctValSize))
+ err := db.Write(batch, p.wo)
+ if err != nil {
+ t.Fatal("write error: ", err)
+ }
+ }
+}
+
+func (h *dbCorruptHarness) buildShuffled(n int, rnd *rand.Rand) {
+ p := &h.dbHarness
+ t := p.t
+ db := p.db
+
+ batch := new(Batch)
+ for i := range rnd.Perm(n) {
+ batch.Reset()
+ batch.Put(tkey(i), tval(i, ctValSize))
+ err := db.Write(batch, p.wo)
+ if err != nil {
+ t.Fatal("write error: ", err)
+ }
+ }
+}
+
+func (h *dbCorruptHarness) deleteRand(n, max int, rnd *rand.Rand) {
+ p := &h.dbHarness
+ t := p.t
+ db := p.db
+
+ batch := new(Batch)
+ for i := 0; i < n; i++ {
+ batch.Reset()
+ batch.Delete(tkey(rnd.Intn(max)))
+ err := db.Write(batch, p.wo)
+ if err != nil {
+ t.Fatal("write error: ", err)
+ }
+ }
+}
+
+func (h *dbCorruptHarness) corrupt(ft storage.FileType, offset, n int) {
+ p := &h.dbHarness
+ t := p.t
+
+ var file storage.File
+ ff, _ := p.stor.GetFiles(ft)
+ for _, f := range ff {
+ if file == nil || f.Num() > file.Num() {
+ file = f
+ }
+ }
+ if file == nil {
+ t.Fatalf("no such file with type %q", ft)
+ }
+
+ r, err := file.Open()
+ if err != nil {
+ t.Fatal("cannot open file: ", err)
+ }
+ x, err := r.Seek(0, 2)
+ if err != nil {
+ t.Fatal("cannot query file size: ", err)
+ }
+ m := int(x)
+ if _, err := r.Seek(0, 0); err != nil {
+ t.Fatal(err)
+ }
+
+ if offset < 0 {
+ if -offset > m {
+ offset = 0
+ } else {
+ offset = m + offset
+ }
+ }
+ if offset > m {
+ offset = m
+ }
+ if offset+n > m {
+ n = m - offset
+ }
+
+ buf := make([]byte, m)
+ _, err = io.ReadFull(r, buf)
+ if err != nil {
+ t.Fatal("cannot read file: ", err)
+ }
+ r.Close()
+
+ for i := 0; i < n; i++ {
+ buf[offset+i] ^= 0x80
+ }
+
+ err = file.Remove()
+ if err != nil {
+ t.Fatal("cannot remove old file: ", err)
+ }
+ w, err := file.Create()
+ if err != nil {
+ t.Fatal("cannot create new file: ", err)
+ }
+ _, err = w.Write(buf)
+ if err != nil {
+ t.Fatal("cannot write new file: ", err)
+ }
+ w.Close()
+}
+
+func (h *dbCorruptHarness) removeAll(ft storage.FileType) {
+ ff, err := h.stor.GetFiles(ft)
+ if err != nil {
+ h.t.Fatal("get files: ", err)
+ }
+ for _, f := range ff {
+ if err := f.Remove(); err != nil {
+ h.t.Error("remove file: ", err)
+ }
+ }
+}
+
+func (h *dbCorruptHarness) removeOne(ft storage.FileType) {
+ ff, err := h.stor.GetFiles(ft)
+ if err != nil {
+ h.t.Fatal("get files: ", err)
+ }
+ f := ff[rand.Intn(len(ff))]
+ h.t.Logf("removing file @%d", f.Num())
+ if err := f.Remove(); err != nil {
+ h.t.Error("remove file: ", err)
+ }
+}
+
+func (h *dbCorruptHarness) check(min, max int) {
+ p := &h.dbHarness
+ t := p.t
+ db := p.db
+
+ var n, badk, badv, missed, good int
+ iter := db.NewIterator(nil, p.ro)
+ for iter.Next() {
+ k := 0
+ fmt.Sscanf(string(iter.Key()), "%d", &k)
+ if k < n {
+ badk++
+ continue
+ }
+ missed += k - n
+ n = k + 1
+ if !bytes.Equal(iter.Value(), tval(k, ctValSize)) {
+ badv++
+ } else {
+ good++
+ }
+ }
+ err := iter.Error()
+ iter.Release()
+ t.Logf("want=%d..%d got=%d badkeys=%d badvalues=%d missed=%d, err=%v",
+ min, max, good, badk, badv, missed, err)
+ if good < min || good > max {
+ t.Errorf("good entries number not in range")
+ }
+}
+
+func TestCorruptDB_Journal(t *testing.T) {
+ h := newDbCorruptHarness(t)
+
+ h.build(100)
+ h.check(100, 100)
+ h.closeDB()
+ h.corrupt(storage.TypeJournal, 19, 1)
+ h.corrupt(storage.TypeJournal, 32*1024+1000, 1)
+
+ h.openDB()
+ h.check(36, 36)
+
+ h.close()
+}
+
+func TestCorruptDB_Table(t *testing.T) {
+ h := newDbCorruptHarness(t)
+
+ h.build(100)
+ h.compactMem()
+ h.compactRangeAt(0, "", "")
+ h.compactRangeAt(1, "", "")
+ h.closeDB()
+ h.corrupt(storage.TypeTable, 100, 1)
+
+ h.openDB()
+ h.check(99, 99)
+
+ h.close()
+}
+
+func TestCorruptDB_TableIndex(t *testing.T) {
+ h := newDbCorruptHarness(t)
+
+ h.build(10000)
+ h.compactMem()
+ h.closeDB()
+ h.corrupt(storage.TypeTable, -2000, 500)
+
+ h.openDB()
+ h.check(5000, 9999)
+
+ h.close()
+}
+
+func TestCorruptDB_MissingManifest(t *testing.T) {
+ rnd := rand.New(rand.NewSource(0x0badda7a))
+ h := newDbCorruptHarnessWopt(t, &opt.Options{
+ BlockCache: cache.NewLRUCache(100),
+ Strict: opt.StrictJournalChecksum,
+ WriteBuffer: 1000 * 60,
+ })
+
+ h.build(1000)
+ h.compactMem()
+ h.buildShuffled(1000, rnd)
+ h.compactMem()
+ h.deleteRand(500, 1000, rnd)
+ h.compactMem()
+ h.buildShuffled(1000, rnd)
+ h.compactMem()
+ h.deleteRand(500, 1000, rnd)
+ h.compactMem()
+ h.buildShuffled(1000, rnd)
+ h.compactMem()
+ h.closeDB()
+
+ h.stor.SetIgnoreOpenErr(storage.TypeManifest)
+ h.removeAll(storage.TypeManifest)
+ h.openAssert(false)
+ h.stor.SetIgnoreOpenErr(0)
+
+ h.recover()
+ h.check(1000, 1000)
+ h.build(1000)
+ h.compactMem()
+ h.compactRange("", "")
+ h.closeDB()
+
+ h.recover()
+ h.check(1000, 1000)
+
+ h.close()
+}
+
+func TestCorruptDB_SequenceNumberRecovery(t *testing.T) {
+ h := newDbCorruptHarness(t)
+
+ h.put("foo", "v1")
+ h.put("foo", "v2")
+ h.put("foo", "v3")
+ h.put("foo", "v4")
+ h.put("foo", "v5")
+ h.closeDB()
+
+ h.recover()
+ h.getVal("foo", "v5")
+ h.put("foo", "v6")
+ h.getVal("foo", "v6")
+
+ h.reopenDB()
+ h.getVal("foo", "v6")
+
+ h.close()
+}
+
+func TestCorruptDB_SequenceNumberRecoveryTable(t *testing.T) {
+ h := newDbCorruptHarness(t)
+
+ h.put("foo", "v1")
+ h.put("foo", "v2")
+ h.put("foo", "v3")
+ h.compactMem()
+ h.put("foo", "v4")
+ h.put("foo", "v5")
+ h.compactMem()
+ h.closeDB()
+
+ h.recover()
+ h.getVal("foo", "v5")
+ h.put("foo", "v6")
+ h.getVal("foo", "v6")
+
+ h.reopenDB()
+ h.getVal("foo", "v6")
+
+ h.close()
+}
+
+func TestCorruptDB_CorruptedManifest(t *testing.T) {
+ h := newDbCorruptHarness(t)
+
+ h.put("foo", "hello")
+ h.compactMem()
+ h.compactRange("", "")
+ h.closeDB()
+ h.corrupt(storage.TypeManifest, 0, 1000)
+ h.openAssert(false)
+
+ h.recover()
+ h.getVal("foo", "hello")
+
+ h.close()
+}
+
+func TestCorruptDB_CompactionInputError(t *testing.T) {
+ h := newDbCorruptHarness(t)
+
+ h.build(10)
+ h.compactMem()
+ h.closeDB()
+ h.corrupt(storage.TypeTable, 100, 1)
+
+ h.openDB()
+ h.check(9, 9)
+
+ h.build(10000)
+ h.check(10000, 10000)
+
+ h.close()
+}
+
+func TestCorruptDB_UnrelatedKeys(t *testing.T) {
+ h := newDbCorruptHarness(t)
+
+ h.build(10)
+ h.compactMem()
+ h.closeDB()
+ h.corrupt(storage.TypeTable, 100, 1)
+
+ h.openDB()
+ h.put(string(tkey(1000)), string(tval(1000, ctValSize)))
+ h.getVal(string(tkey(1000)), string(tval(1000, ctValSize)))
+ h.compactMem()
+ h.getVal(string(tkey(1000)), string(tval(1000, ctValSize)))
+
+ h.close()
+}
+
+func TestCorruptDB_Level0NewerFileHasOlderSeqnum(t *testing.T) {
+ h := newDbCorruptHarness(t)
+
+ h.put("a", "v1")
+ h.put("b", "v1")
+ h.compactMem()
+ h.put("a", "v2")
+ h.put("b", "v2")
+ h.compactMem()
+ h.put("a", "v3")
+ h.put("b", "v3")
+ h.compactMem()
+ h.put("c", "v0")
+ h.put("d", "v0")
+ h.compactMem()
+ h.compactRangeAt(1, "", "")
+ h.closeDB()
+
+ h.recover()
+ h.getVal("a", "v3")
+ h.getVal("b", "v3")
+ h.getVal("c", "v0")
+ h.getVal("d", "v0")
+
+ h.close()
+}
+
+func TestCorruptDB_RecoverInvalidSeq_Issue53(t *testing.T) {
+ h := newDbCorruptHarness(t)
+
+ h.put("a", "v1")
+ h.put("b", "v1")
+ h.compactMem()
+ h.put("a", "v2")
+ h.put("b", "v2")
+ h.compactMem()
+ h.put("a", "v3")
+ h.put("b", "v3")
+ h.compactMem()
+ h.put("c", "v0")
+ h.put("d", "v0")
+ h.compactMem()
+ h.compactRangeAt(0, "", "")
+ h.closeDB()
+
+ h.recover()
+ h.getVal("a", "v3")
+ h.getVal("b", "v3")
+ h.getVal("c", "v0")
+ h.getVal("d", "v0")
+
+ h.close()
+}
+
+func TestCorruptDB_MissingTableFiles(t *testing.T) {
+ h := newDbCorruptHarness(t)
+
+ h.put("a", "v1")
+ h.put("b", "v1")
+ h.compactMem()
+ h.put("c", "v2")
+ h.put("d", "v2")
+ h.compactMem()
+ h.put("e", "v3")
+ h.put("f", "v3")
+ h.closeDB()
+
+ h.removeOne(storage.TypeTable)
+ h.openAssert(false)
+
+ h.close()
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/db.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/db.go
new file mode 100644
index 000000000..8e975dc63
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/db.go
@@ -0,0 +1,755 @@
+// Copyright (c) 2012, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package leveldb
+
+import (
+ "errors"
+ "fmt"
+ "io"
+ "os"
+ "runtime"
+ "strings"
+ "sync"
+ "time"
+
+ "github.com/syndtr/goleveldb/leveldb/iterator"
+ "github.com/syndtr/goleveldb/leveldb/journal"
+ "github.com/syndtr/goleveldb/leveldb/memdb"
+ "github.com/syndtr/goleveldb/leveldb/opt"
+ "github.com/syndtr/goleveldb/leveldb/storage"
+ "github.com/syndtr/goleveldb/leveldb/table"
+ "github.com/syndtr/goleveldb/leveldb/util"
+)
+
+// DB is a LevelDB database.
+type DB struct {
+ // Need 64-bit alignment.
+ seq uint64
+
+ s *session
+
+ // MemDB
+ memMu sync.RWMutex
+ mem *memdb.DB
+ frozenMem *memdb.DB
+ journal *journal.Writer
+ journalWriter storage.Writer
+ journalFile storage.File
+ frozenJournalFile storage.File
+ frozenSeq uint64
+
+ // Snapshot
+ snapsMu sync.Mutex
+ snapsRoot snapshotElement
+
+ // Write
+ writeC chan *Batch
+ writeMergedC chan bool
+ writeLockC chan struct{}
+ writeAckC chan error
+ journalC chan *Batch
+ journalAckC chan error
+
+ // Compaction
+ tcompCmdC chan cCmd
+ tcompPauseC chan chan<- struct{}
+ tcompTriggerC chan struct{}
+ mcompCmdC chan cCmd
+ mcompTriggerC chan struct{}
+ compErrC chan error
+ compErrSetC chan error
+ compStats [kNumLevels]cStats
+
+ // Close
+ closeW sync.WaitGroup
+ closeC chan struct{}
+ closed uint32
+ closer io.Closer
+}
+
+func openDB(s *session) (*DB, error) {
+ s.log("db@open opening")
+ start := time.Now()
+ db := &DB{
+ s: s,
+ // Initial sequence
+ seq: s.stSeq,
+ // Write
+ writeC: make(chan *Batch),
+ writeMergedC: make(chan bool),
+ writeLockC: make(chan struct{}, 1),
+ writeAckC: make(chan error),
+ journalC: make(chan *Batch),
+ journalAckC: make(chan error),
+ // Compaction
+ tcompCmdC: make(chan cCmd),
+ tcompPauseC: make(chan chan<- struct{}),
+ tcompTriggerC: make(chan struct{}, 1),
+ mcompCmdC: make(chan cCmd),
+ mcompTriggerC: make(chan struct{}, 1),
+ compErrC: make(chan error),
+ compErrSetC: make(chan error),
+ // Close
+ closeC: make(chan struct{}),
+ }
+ db.initSnapshot()
+
+ if err := db.recoverJournal(); err != nil {
+ return nil, err
+ }
+
+ // Remove any obsolete files.
+ if err := db.checkAndCleanFiles(); err != nil {
+ // Close journal.
+ if db.journal != nil {
+ db.journal.Close()
+ db.journalWriter.Close()
+ }
+ return nil, err
+ }
+
+ // Don't include compaction error goroutine into wait group.
+ go db.compactionError()
+
+ db.closeW.Add(3)
+ go db.tCompaction()
+ go db.mCompaction()
+ go db.jWriter()
+
+ s.logf("db@open done T·%v", time.Since(start))
+
+ runtime.SetFinalizer(db, (*DB).Close)
+ return db, nil
+}
+
+// Open opens or creates a DB for the given storage.
+// The DB will be created if not exist, unless ErrorIfMissing is true.
+// Also, if ErrorIfExist is true and the DB exist Open will returns
+// os.ErrExist error.
+//
+// Open will return an error with type of ErrCorrupted if corruption
+// detected in the DB. Corrupted DB can be recovered with Recover
+// function.
+//
+// The DB must be closed after use, by calling Close method.
+func Open(p storage.Storage, o *opt.Options) (db *DB, err error) {
+ s, err := newSession(p, o)
+ if err != nil {
+ return
+ }
+ defer func() {
+ if err != nil {
+ s.close()
+ s.release()
+ }
+ }()
+
+ err = s.recover()
+ if err != nil {
+ if !os.IsNotExist(err) || s.o.GetErrorIfMissing() {
+ return
+ }
+ err = s.create()
+ if err != nil {
+ return
+ }
+ } else if s.o.GetErrorIfExist() {
+ err = os.ErrExist
+ return
+ }
+
+ return openDB(s)
+}
+
+// OpenFile opens or creates a DB for the given path.
+// The DB will be created if not exist, unless ErrorIfMissing is true.
+// Also, if ErrorIfExist is true and the DB exist OpenFile will returns
+// os.ErrExist error.
+//
+// OpenFile uses standard file-system backed storage implementation as
+// desribed in the leveldb/storage package.
+//
+// OpenFile will return an error with type of ErrCorrupted if corruption
+// detected in the DB. Corrupted DB can be recovered with Recover
+// function.
+//
+// The DB must be closed after use, by calling Close method.
+func OpenFile(path string, o *opt.Options) (db *DB, err error) {
+ stor, err := storage.OpenFile(path)
+ if err != nil {
+ return
+ }
+ db, err = Open(stor, o)
+ if err != nil {
+ stor.Close()
+ } else {
+ db.closer = stor
+ }
+ return
+}
+
+// Recover recovers and opens a DB with missing or corrupted manifest files
+// for the given storage. It will ignore any manifest files, valid or not.
+// The DB must already exist or it will returns an error.
+// Also, Recover will ignore ErrorIfMissing and ErrorIfExist options.
+//
+// The DB must be closed after use, by calling Close method.
+func Recover(p storage.Storage, o *opt.Options) (db *DB, err error) {
+ s, err := newSession(p, o)
+ if err != nil {
+ return
+ }
+ defer func() {
+ if err != nil {
+ s.close()
+ s.release()
+ }
+ }()
+
+ err = recoverTable(s, o)
+ if err != nil {
+ return
+ }
+ return openDB(s)
+}
+
+// RecoverFile recovers and opens a DB with missing or corrupted manifest files
+// for the given path. It will ignore any manifest files, valid or not.
+// The DB must already exist or it will returns an error.
+// Also, Recover will ignore ErrorIfMissing and ErrorIfExist options.
+//
+// RecoverFile uses standard file-system backed storage implementation as desribed
+// in the leveldb/storage package.
+//
+// The DB must be closed after use, by calling Close method.
+func RecoverFile(path string, o *opt.Options) (db *DB, err error) {
+ stor, err := storage.OpenFile(path)
+ if err != nil {
+ return
+ }
+ db, err = Recover(stor, o)
+ if err != nil {
+ stor.Close()
+ } else {
+ db.closer = stor
+ }
+ return
+}
+
+func recoverTable(s *session, o *opt.Options) error {
+ ff0, err := s.getFiles(storage.TypeTable)
+ if err != nil {
+ return err
+ }
+ ff1 := files(ff0)
+ ff1.sort()
+
+ var mSeq uint64
+ var good, corrupted int
+ rec := new(sessionRecord)
+ buildTable := func(iter iterator.Iterator) (tmp storage.File, size int64, err error) {
+ tmp = s.newTemp()
+ writer, err := tmp.Create()
+ if err != nil {
+ return
+ }
+ defer func() {
+ writer.Close()
+ if err != nil {
+ tmp.Remove()
+ tmp = nil
+ }
+ }()
+ tw := table.NewWriter(writer, o)
+ // Copy records.
+ for iter.Next() {
+ key := iter.Key()
+ if validIkey(key) {
+ err = tw.Append(key, iter.Value())
+ if err != nil {
+ return
+ }
+ }
+ }
+ err = iter.Error()
+ if err != nil {
+ return
+ }
+ err = tw.Close()
+ if err != nil {
+ return
+ }
+ err = writer.Sync()
+ if err != nil {
+ return
+ }
+ size = int64(tw.BytesLen())
+ return
+ }
+ recoverTable := func(file storage.File) error {
+ s.logf("table@recovery recovering @%d", file.Num())
+ reader, err := file.Open()
+ if err != nil {
+ return err
+ }
+ defer reader.Close()
+ // Get file size.
+ size, err := reader.Seek(0, 2)
+ if err != nil {
+ return err
+ }
+ var tSeq uint64
+ var tgood, tcorrupted, blockerr int
+ var min, max []byte
+ tr := table.NewReader(reader, size, nil, o)
+ iter := tr.NewIterator(nil, nil)
+ iter.(iterator.ErrorCallbackSetter).SetErrorCallback(func(err error) {
+ s.logf("table@recovery found error @%d %q", file.Num(), err)
+ blockerr++
+ })
+ // Scan the table.
+ for iter.Next() {
+ key := iter.Key()
+ _, seq, _, ok := parseIkey(key)
+ if !ok {
+ tcorrupted++
+ continue
+ }
+ tgood++
+ if seq > tSeq {
+ tSeq = seq
+ }
+ if min == nil {
+ min = append([]byte{}, key...)
+ }
+ max = append(max[:0], key...)
+ }
+ if err := iter.Error(); err != nil {
+ iter.Release()
+ return err
+ }
+ iter.Release()
+ if tgood > 0 {
+ if tcorrupted > 0 || blockerr > 0 {
+ // Rebuild the table.
+ s.logf("table@recovery rebuilding @%d", file.Num())
+ iter := tr.NewIterator(nil, nil)
+ tmp, newSize, err := buildTable(iter)
+ iter.Release()
+ if err != nil {
+ return err
+ }
+ reader.Close()
+ if err := file.Replace(tmp); err != nil {
+ return err
+ }
+ size = newSize
+ }
+ if tSeq > mSeq {
+ mSeq = tSeq
+ }
+ // Add table to level 0.
+ rec.addTable(0, file.Num(), uint64(size), min, max)
+ s.logf("table@recovery recovered @%d N·%d C·%d B·%d S·%d Q·%d", file.Num(), tgood, tcorrupted, blockerr, size, tSeq)
+ } else {
+ s.logf("table@recovery unrecoverable @%d C·%d B·%d S·%d", file.Num(), tcorrupted, blockerr, size)
+ }
+
+ good += tgood
+ corrupted += tcorrupted
+
+ return nil
+ }
+ // Recover all tables.
+ if len(ff1) > 0 {
+ s.logf("table@recovery F·%d", len(ff1))
+ s.markFileNum(ff1[len(ff1)-1].Num())
+ for _, file := range ff1 {
+ if err := recoverTable(file); err != nil {
+ return err
+ }
+ }
+ s.logf("table@recovery recovered F·%d N·%d C·%d Q·%d", len(ff1), good, corrupted, mSeq)
+ }
+ // Set sequence number.
+ rec.setSeq(mSeq + 1)
+ // Create new manifest.
+ if err := s.create(); err != nil {
+ return err
+ }
+ // Commit.
+ return s.commit(rec)
+}
+
+func (d *DB) recoverJournal() error {
+ s := d.s
+
+ ff0, err := s.getFiles(storage.TypeJournal)
+ if err != nil {
+ return err
+ }
+ ff1 := files(ff0)
+ ff1.sort()
+ ff2 := make([]storage.File, 0, len(ff1))
+ for _, file := range ff1 {
+ if file.Num() >= s.stJournalNum || file.Num() == s.stPrevJournalNum {
+ s.markFileNum(file.Num())
+ ff2 = append(ff2, file)
+ }
+ }
+
+ var jr *journal.Reader
+ var of storage.File
+ var mem *memdb.DB
+ batch := new(Batch)
+ cm := newCMem(s)
+ buf := new(util.Buffer)
+ // Options.
+ strict := s.o.GetStrict(opt.StrictJournal)
+ checksum := s.o.GetStrict(opt.StrictJournalChecksum)
+ writeBuffer := s.o.GetWriteBuffer()
+ recoverJournal := func(file storage.File) error {
+ s.logf("journal@recovery recovering @%d", file.Num())
+ reader, err := file.Open()
+ if err != nil {
+ return err
+ }
+ defer reader.Close()
+ if jr == nil {
+ jr = journal.NewReader(reader, dropper{s, file}, strict, checksum)
+ } else {
+ jr.Reset(reader, dropper{s, file}, strict, checksum)
+ }
+ if of != nil {
+ if mem.Len() > 0 {
+ if err := cm.flush(mem, 0); err != nil {
+ return err
+ }
+ }
+ if err := cm.commit(file.Num(), d.seq); err != nil {
+ return err
+ }
+ cm.reset()
+ of.Remove()
+ of = nil
+ }
+ // Reset memdb.
+ mem.Reset()
+ for {
+ r, err := jr.Next()
+ if err != nil {
+ if err == io.EOF {
+ break
+ }
+ return err
+ }
+ buf.Reset()
+ if _, err := buf.ReadFrom(r); err != nil {
+ if strict {
+ return err
+ }
+ continue
+ }
+ if err := batch.decode(buf.Bytes()); err != nil {
+ return err
+ }
+ if err := batch.memReplay(mem); err != nil {
+ return err
+ }
+ d.seq = batch.seq + uint64(batch.len())
+ if mem.Size() >= writeBuffer {
+ // Large enough, flush it.
+ if err := cm.flush(mem, 0); err != nil {
+ return err
+ }
+ // Reset memdb.
+ mem.Reset()
+ }
+ }
+ of = file
+ return nil
+ }
+ // Recover all journals.
+ if len(ff2) > 0 {
+ s.logf("journal@recovery F·%d", len(ff2))
+ mem = memdb.New(s.icmp, writeBuffer)
+ for _, file := range ff2 {
+ if err := recoverJournal(file); err != nil {
+ return err
+ }
+ }
+ // Flush the last journal.
+ if mem.Len() > 0 {
+ if err := cm.flush(mem, 0); err != nil {
+ return err
+ }
+ }
+ }
+ // Create a new journal.
+ if _, err := d.newMem(0); err != nil {
+ return err
+ }
+ // Commit.
+ if err := cm.commit(d.journalFile.Num(), d.seq); err != nil {
+ // Close journal.
+ if d.journal != nil {
+ d.journal.Close()
+ d.journalWriter.Close()
+ }
+ return err
+ }
+ // Remove the last journal.
+ if of != nil {
+ of.Remove()
+ }
+ return nil
+}
+
+func (d *DB) get(key []byte, seq uint64, ro *opt.ReadOptions) (value []byte, err error) {
+ s := d.s
+
+ ikey := newIKey(key, seq, tSeek)
+
+ em, fm := d.getMems()
+ for _, m := range [...]*memdb.DB{em, fm} {
+ if m == nil {
+ continue
+ }
+ mk, mv, me := m.Find(ikey)
+ if me == nil {
+ ukey, _, t, ok := parseIkey(mk)
+ if ok && s.icmp.uCompare(ukey, key) == 0 {
+ if t == tDel {
+ return nil, ErrNotFound
+ }
+ return mv, nil
+ }
+ } else if me != ErrNotFound {
+ return nil, me
+ }
+ }
+
+ v := s.version()
+ value, cSched, err := v.get(ikey, ro)
+ v.release()
+ if cSched {
+ // Trigger table compaction.
+ d.compTrigger(d.tcompTriggerC)
+ }
+ return
+}
+
+// Get gets the value for the given key. It returns ErrNotFound if the
+// DB does not contain the key.
+//
+// The caller should not modify the contents of the returned slice, but
+// it is safe to modify the contents of the argument after Get returns.
+func (d *DB) Get(key []byte, ro *opt.ReadOptions) (value []byte, err error) {
+ err = d.ok()
+ if err != nil {
+ return
+ }
+
+ return d.get(key, d.getSeq(), ro)
+}
+
+// NewIterator returns an iterator for the latest snapshot of the
+// uderlying DB.
+// The returned iterator is not goroutine-safe, but it is safe to use
+// multiple iterators concurrently, with each in a dedicated goroutine.
+// It is also safe to use an iterator concurrently with modifying its
+// underlying DB. The resultant key/value pairs are guaranteed to be
+// consistent.
+//
+// Slice allows slicing the iterator to only contains keys in the given
+// range. A nil Range.Start is treated as a key before all keys in the
+// DB. And a nil Range.Limit is treated as a key after all keys in
+// the DB.
+//
+// The iterator must be released after use, by calling Release method.
+//
+// Also read Iterator documentation of the leveldb/iterator package.
+func (d *DB) NewIterator(slice *util.Range, ro *opt.ReadOptions) iterator.Iterator {
+ if err := d.ok(); err != nil {
+ return iterator.NewEmptyIterator(err)
+ }
+
+ p := d.newSnapshot()
+ defer p.Release()
+ return p.NewIterator(slice, ro)
+}
+
+// GetSnapshot returns a latest snapshot of the underlying DB. A snapshot
+// is a frozen snapshot of a DB state at a particular point in time. The
+// content of snapshot are guaranteed to be consistent.
+//
+// The snapshot must be released after use, by calling Release method.
+func (d *DB) GetSnapshot() (*Snapshot, error) {
+ if err := d.ok(); err != nil {
+ return nil, err
+ }
+
+ return d.newSnapshot(), nil
+}
+
+// GetProperty returns value of the given property name.
+//
+// Property names:
+// leveldb.num-files-at-level{n}
+// Returns the number of filer at level 'n'.
+// leveldb.stats
+// Returns statistics of the underlying DB.
+// leveldb.sstables
+// Returns sstables list for each level.
+func (d *DB) GetProperty(name string) (value string, err error) {
+ err = d.ok()
+ if err != nil {
+ return
+ }
+
+ const prefix = "leveldb."
+ if !strings.HasPrefix(name, prefix) {
+ return "", errors.New("leveldb: GetProperty: unknown property: " + name)
+ }
+
+ p := name[len(prefix):]
+
+ s := d.s
+ v := s.version()
+ defer v.release()
+
+ switch {
+ case strings.HasPrefix(p, "num-files-at-level"):
+ var level uint
+ var rest string
+ n, _ := fmt.Scanf("%d%s", &level, &rest)
+ if n != 1 || level >= kNumLevels {
+ err = errors.New("leveldb: GetProperty: invalid property: " + name)
+ } else {
+ value = fmt.Sprint(v.tLen(int(level)))
+ }
+ case p == "stats":
+ value = "Compactions\n" +
+ " Level | Tables | Size(MB) | Time(sec) | Read(MB) | Write(MB)\n" +
+ "-------+------------+---------------+---------------+---------------+---------------\n"
+ for level, tt := range v.tables {
+ duration, read, write := d.compStats[level].get()
+ if len(tt) == 0 && duration == 0 {
+ continue
+ }
+ value += fmt.Sprintf(" %3d | %10d | %13.5f | %13.5f | %13.5f | %13.5f\n",
+ level, len(tt), float64(tt.size())/1048576.0, duration.Seconds(),
+ float64(read)/1048576.0, float64(write)/1048576.0)
+ }
+ case p == "sstables":
+ for level, tt := range v.tables {
+ value += fmt.Sprintf("--- level %d ---\n", level)
+ for _, t := range tt {
+ value += fmt.Sprintf("%d:%d[%q .. %q]\n", t.file.Num(), t.size, t.min, t.max)
+ }
+ }
+ default:
+ err = errors.New("leveldb: GetProperty: unknown property: " + name)
+ }
+
+ return
+}
+
+// SizeOf calculates approximate sizes of the given key ranges.
+// The length of the returned sizes are equal with the length of the given
+// ranges. The returned sizes measure storage space usage, so if the user
+// data compresses by a factor of ten, the returned sizes will be one-tenth
+// the size of the corresponding user data size.
+// The results may not include the sizes of recently written data.
+func (d *DB) SizeOf(ranges []util.Range) (Sizes, error) {
+ if err := d.ok(); err != nil {
+ return nil, err
+ }
+
+ v := d.s.version()
+ defer v.release()
+
+ sizes := make(Sizes, 0, len(ranges))
+ for _, r := range ranges {
+ min := newIKey(r.Start, kMaxSeq, tSeek)
+ max := newIKey(r.Limit, kMaxSeq, tSeek)
+ start, err := v.offsetOf(min)
+ if err != nil {
+ return nil, err
+ }
+ limit, err := v.offsetOf(max)
+ if err != nil {
+ return nil, err
+ }
+ var size uint64
+ if limit >= start {
+ size = limit - start
+ }
+ sizes = append(sizes, size)
+ }
+
+ return sizes, nil
+}
+
+// Close closes the DB. This will also releases any outstanding snapshot.
+//
+// It is not safe to close a DB until all outstanding iterators are released.
+// It is valid to call Close multiple times. Other methods should not be
+// called after the DB has been closed.
+func (d *DB) Close() error {
+ if !d.setClosed() {
+ return ErrClosed
+ }
+
+ s := d.s
+ start := time.Now()
+ s.log("db@close closing")
+
+ // Clear the finalizer.
+ runtime.SetFinalizer(d, nil)
+
+ // Get compaction error.
+ var err error
+ select {
+ case err = <-d.compErrC:
+ default:
+ }
+
+ close(d.closeC)
+
+ // Wait for the close WaitGroup.
+ d.closeW.Wait()
+
+ // Close journal.
+ if d.journal != nil {
+ d.journal.Close()
+ d.journalWriter.Close()
+ }
+
+ // Close session.
+ s.close()
+ s.logf("db@close done T·%v", time.Since(start))
+ s.release()
+
+ if d.closer != nil {
+ if err1 := d.closer.Close(); err == nil {
+ err = err1
+ }
+ }
+
+ d.s = nil
+ d.mem = nil
+ d.frozenMem = nil
+ d.journal = nil
+ d.journalWriter = nil
+ d.journalFile = nil
+ d.frozenJournalFile = nil
+ d.snapsRoot = snapshotElement{}
+ d.closer = nil
+
+ return err
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/db_compaction.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/db_compaction.go
new file mode 100644
index 000000000..c82bd9f28
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/db_compaction.go
@@ -0,0 +1,688 @@
+// Copyright (c) 2012, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package leveldb
+
+import (
+ "errors"
+ "sync"
+ "time"
+
+ "github.com/syndtr/goleveldb/leveldb/memdb"
+)
+
+var (
+ errCompactionTransactExiting = errors.New("leveldb: compaction transact exiting")
+)
+
+type cStats struct {
+ sync.Mutex
+ duration time.Duration
+ read uint64
+ write uint64
+}
+
+func (p *cStats) add(n *cStatsStaging) {
+ p.Lock()
+ p.duration += n.duration
+ p.read += n.read
+ p.write += n.write
+ p.Unlock()
+}
+
+func (p *cStats) get() (duration time.Duration, read, write uint64) {
+ p.Lock()
+ defer p.Unlock()
+ return p.duration, p.read, p.write
+}
+
+type cStatsStaging struct {
+ start time.Time
+ duration time.Duration
+ on bool
+ read uint64
+ write uint64
+}
+
+func (p *cStatsStaging) startTimer() {
+ if !p.on {
+ p.start = time.Now()
+ p.on = true
+ }
+}
+
+func (p *cStatsStaging) stopTimer() {
+ if p.on {
+ p.duration += time.Since(p.start)
+ p.on = false
+ }
+}
+
+type cMem struct {
+ s *session
+ level int
+ rec *sessionRecord
+}
+
+func newCMem(s *session) *cMem {
+ return &cMem{s: s, rec: new(sessionRecord)}
+}
+
+func (c *cMem) flush(mem *memdb.DB, level int) error {
+ s := c.s
+
+ // Write memdb to table
+ iter := mem.NewIterator(nil)
+ defer iter.Release()
+ t, n, err := s.tops.createFrom(iter)
+ if err != nil {
+ return err
+ }
+
+ if level < 0 {
+ level = s.version_NB().pickLevel(t.min.ukey(), t.max.ukey())
+ }
+ c.rec.addTableFile(level, t)
+
+ s.logf("mem@flush created L%d@%d N·%d S·%s %q:%q", level, t.file.Num(), n, shortenb(int(t.size)), t.min, t.max)
+
+ c.level = level
+ return nil
+}
+
+func (c *cMem) reset() {
+ c.rec = new(sessionRecord)
+}
+
+func (c *cMem) commit(journal, seq uint64) error {
+ c.rec.setJournalNum(journal)
+ c.rec.setSeq(seq)
+ // Commit changes
+ return c.s.commit(c.rec)
+}
+
+func (d *DB) compactionError() {
+ var err error
+noerr:
+ for {
+ select {
+ case _, _ = <-d.closeC:
+ return
+ case err = <-d.compErrSetC:
+ if err != nil {
+ goto haserr
+ }
+ }
+ }
+haserr:
+ for {
+ select {
+ case _, _ = <-d.closeC:
+ return
+ case err = <-d.compErrSetC:
+ if err == nil {
+ goto noerr
+ }
+ case d.compErrC <- err:
+ }
+ }
+}
+
+type compactionTransactCounter int
+
+func (cnt *compactionTransactCounter) incr() {
+ *cnt++
+}
+
+func (d *DB) compactionTransact(name string, exec func(cnt *compactionTransactCounter) error, rollback func() error) {
+ s := d.s
+ defer func() {
+ if x := recover(); x != nil {
+ if x == errCompactionTransactExiting && rollback != nil {
+ if err := rollback(); err != nil {
+ s.logf("%s rollback error %q", name, err)
+ }
+ }
+ panic(x)
+ }
+ }()
+ const (
+ backoffMin = 1 * time.Second
+ backoffMax = 8 * time.Second
+ backoffMul = 2 * time.Second
+ )
+ backoff := backoffMin
+ backoffT := time.NewTimer(backoff)
+ lastCnt := compactionTransactCounter(0)
+ for n := 0; ; n++ {
+ // Check wether the DB is closed.
+ if d.isClosed() {
+ s.logf("%s exiting", name)
+ d.compactionExitTransact()
+ } else if n > 0 {
+ s.logf("%s retrying N·%d", name, n)
+ }
+
+ // Execute.
+ cnt := compactionTransactCounter(0)
+ err := exec(&cnt)
+
+ // Set compaction error status.
+ select {
+ case d.compErrSetC <- err:
+ case _, _ = <-d.closeC:
+ s.logf("%s exiting", name)
+ d.compactionExitTransact()
+ }
+ if err == nil {
+ return
+ }
+ s.logf("%s error I·%d %q", name, cnt, err)
+
+ // Reset backoff duration if counter is advancing.
+ if cnt > lastCnt {
+ backoff = backoffMin
+ lastCnt = cnt
+ }
+
+ // Backoff.
+ backoffT.Reset(backoff)
+ if backoff < backoffMax {
+ backoff *= backoffMul
+ if backoff > backoffMax {
+ backoff = backoffMax
+ }
+ }
+ select {
+ case <-backoffT.C:
+ case _, _ = <-d.closeC:
+ s.logf("%s exiting", name)
+ d.compactionExitTransact()
+ }
+ }
+}
+
+func (d *DB) compactionExitTransact() {
+ panic(errCompactionTransactExiting)
+}
+
+func (d *DB) memCompaction() {
+ mem := d.getFrozenMem()
+ if mem == nil {
+ return
+ }
+
+ s := d.s
+ c := newCMem(s)
+ stats := new(cStatsStaging)
+
+ s.logf("mem@flush N·%d S·%s", mem.Len(), shortenb(mem.Size()))
+
+ // Don't compact empty memdb.
+ if mem.Len() == 0 {
+ s.logf("mem@flush skipping")
+ // drop frozen mem
+ d.dropFrozenMem()
+ return
+ }
+
+ // Pause table compaction.
+ ch := make(chan struct{})
+ select {
+ case d.tcompPauseC <- (chan<- struct{})(ch):
+ case _, _ = <-d.closeC:
+ return
+ }
+
+ d.compactionTransact("mem@flush", func(cnt *compactionTransactCounter) (err error) {
+ stats.startTimer()
+ defer stats.stopTimer()
+ return c.flush(mem, -1)
+ }, func() error {
+ for _, r := range c.rec.addedTables {
+ s.logf("mem@flush rollback @%d", r.num)
+ f := s.getTableFile(r.num)
+ if err := f.Remove(); err != nil {
+ return err
+ }
+ }
+ return nil
+ })
+
+ d.compactionTransact("mem@commit", func(cnt *compactionTransactCounter) (err error) {
+ stats.startTimer()
+ defer stats.stopTimer()
+ return c.commit(d.journalFile.Num(), d.frozenSeq)
+ }, nil)
+
+ s.logf("mem@flush commited F·%d T·%v", len(c.rec.addedTables), stats.duration)
+
+ for _, r := range c.rec.addedTables {
+ stats.write += r.size
+ }
+ d.compStats[c.level].add(stats)
+
+ // Drop frozen mem.
+ d.dropFrozenMem()
+
+ // Resume table compaction.
+ select {
+ case <-ch:
+ case _, _ = <-d.closeC:
+ return
+ }
+
+ // Trigger table compaction.
+ d.compTrigger(d.mcompTriggerC)
+}
+
+func (d *DB) tableCompaction(c *compaction, noTrivial bool) {
+ s := d.s
+
+ rec := new(sessionRecord)
+ rec.addCompactionPointer(c.level, c.max)
+
+ if !noTrivial && c.trivial() {
+ t := c.tables[0][0]
+ s.logf("table@move L%d@%d -> L%d", c.level, t.file.Num(), c.level+1)
+ rec.deleteTable(c.level, t.file.Num())
+ rec.addTableFile(c.level+1, t)
+ d.compactionTransact("table@move", func(cnt *compactionTransactCounter) (err error) {
+ return s.commit(rec)
+ }, nil)
+ return
+ }
+
+ var stats [2]cStatsStaging
+ for i, tt := range c.tables {
+ for _, t := range tt {
+ stats[i].read += t.size
+ // Insert deleted tables into record
+ rec.deleteTable(c.level+i, t.file.Num())
+ }
+ }
+ sourceSize := int(stats[0].read + stats[1].read)
+ minSeq := d.minSeq()
+ s.logf("table@compaction L%d·%d -> L%d·%d S·%s Q·%d", c.level, len(c.tables[0]), c.level+1, len(c.tables[1]), shortenb(sourceSize), minSeq)
+
+ var snapUkey []byte
+ var snapHasUkey bool
+ var snapSeq uint64
+ var snapIter int
+ var snapDropCnt int
+ var dropCnt int
+ d.compactionTransact("table@build", func(cnt *compactionTransactCounter) (err error) {
+ ukey := append([]byte{}, snapUkey...)
+ hasUkey := snapHasUkey
+ lseq := snapSeq
+ dropCnt = snapDropCnt
+ snapSched := snapIter == 0
+
+ var tw *tWriter
+ finish := func() error {
+ t, err := tw.finish()
+ if err != nil {
+ return err
+ }
+ rec.addTableFile(c.level+1, t)
+ stats[1].write += t.size
+ s.logf("table@build created L%d@%d N·%d S·%s %q:%q", c.level+1, t.file.Num(), tw.tw.EntriesLen(), shortenb(int(t.size)), t.min, t.max)
+ return nil
+ }
+
+ defer func() {
+ stats[1].stopTimer()
+ if tw != nil {
+ tw.drop()
+ tw = nil
+ }
+ }()
+
+ stats[1].startTimer()
+ iter := c.newIterator()
+ defer iter.Release()
+ for i := 0; iter.Next(); i++ {
+ // Incr transact counter.
+ cnt.incr()
+
+ // Skip until last state.
+ if i < snapIter {
+ continue
+ }
+
+ key := iKey(iter.Key())
+
+ if c.shouldStopBefore(key) && tw != nil {
+ err = finish()
+ if err != nil {
+ return
+ }
+ snapSched = true
+ tw = nil
+ }
+
+ // Scheduled for snapshot, snapshot will used to retry compaction
+ // if error occured.
+ if snapSched {
+ snapUkey = append(snapUkey[:0], ukey...)
+ snapHasUkey = hasUkey
+ snapSeq = lseq
+ snapIter = i
+ snapDropCnt = dropCnt
+ snapSched = false
+ }
+
+ if seq, t, ok := key.parseNum(); !ok {
+ // Don't drop error keys
+ ukey = ukey[:0]
+ hasUkey = false
+ lseq = kMaxSeq
+ } else {
+ if !hasUkey || s.icmp.uCompare(key.ukey(), ukey) != 0 {
+ // First occurrence of this user key
+ ukey = append(ukey[:0], key.ukey()...)
+ hasUkey = true
+ lseq = kMaxSeq
+ }
+
+ drop := false
+ if lseq <= minSeq {
+ // Dropped because newer entry for same user key exist
+ drop = true // (A)
+ } else if t == tDel && seq <= minSeq && c.isBaseLevelForKey(ukey) {
+ // For this user key:
+ // (1) there is no data in higher levels
+ // (2) data in lower levels will have larger seq numbers
+ // (3) data in layers that are being compacted here and have
+ // smaller seq numbers will be dropped in the next
+ // few iterations of this loop (by rule (A) above).
+ // Therefore this deletion marker is obsolete and can be dropped.
+ drop = true
+ }
+
+ lseq = seq
+ if drop {
+ dropCnt++
+ continue
+ }
+ }
+
+ // Create new table if not already
+ if tw == nil {
+ // Check for pause event.
+ select {
+ case ch := <-d.tcompPauseC:
+ d.pauseCompaction(ch)
+ case _, _ = <-d.closeC:
+ d.compactionExitTransact()
+ default:
+ }
+
+ // Create new table.
+ tw, err = s.tops.create()
+ if err != nil {
+ return
+ }
+ }
+
+ // Write key/value into table
+ err = tw.add(key, iter.Value())
+ if err != nil {
+ return
+ }
+
+ // Finish table if it is big enough
+ if tw.tw.BytesLen() >= kMaxTableSize {
+ err = finish()
+ if err != nil {
+ return
+ }
+ snapSched = true
+ tw = nil
+ }
+ }
+
+ err = iter.Error()
+ if err != nil {
+ return
+ }
+
+ // Finish last table
+ if tw != nil && !tw.empty() {
+ err = finish()
+ if err != nil {
+ return
+ }
+ tw = nil
+ }
+ return
+ }, func() error {
+ for _, r := range rec.addedTables {
+ s.logf("table@build rollback @%d", r.num)
+ f := s.getTableFile(r.num)
+ if err := f.Remove(); err != nil {
+ return err
+ }
+ }
+ return nil
+ })
+
+ // Commit changes
+ d.compactionTransact("table@commit", func(cnt *compactionTransactCounter) (err error) {
+ stats[1].startTimer()
+ defer stats[1].stopTimer()
+ return s.commit(rec)
+ }, nil)
+
+ resultSize := int(int(stats[1].write))
+ s.logf("table@compaction commited F%s S%s D·%d T·%v", sint(len(rec.addedTables)-len(rec.deletedTables)), sshortenb(resultSize-sourceSize), dropCnt, stats[1].duration)
+
+ // Save compaction stats
+ for i := range stats {
+ d.compStats[c.level+1].add(&stats[i])
+ }
+}
+
+func (d *DB) tableRangeCompaction(level int, min, max []byte) {
+ s := d.s
+ s.logf("table@compaction range L%d %q:%q", level, min, max)
+
+ if level >= 0 {
+ if c := s.getCompactionRange(level, min, max); c != nil {
+ d.tableCompaction(c, true)
+ }
+ } else {
+ v := s.version_NB()
+ m := 1
+ for i, t := range v.tables[1:] {
+ if t.isOverlaps(min, max, true, s.icmp) {
+ m = i + 1
+ }
+ }
+ for level := 0; level < m; level++ {
+ if c := s.getCompactionRange(level, min, max); c != nil {
+ d.tableCompaction(c, true)
+ }
+ }
+ }
+}
+
+func (d *DB) tableAutoCompaction() {
+ if c := d.s.pickCompaction(); c != nil {
+ d.tableCompaction(c, false)
+ }
+}
+
+func (d *DB) tableNeedCompaction() bool {
+ return d.s.version_NB().needCompaction()
+}
+
+func (d *DB) pauseCompaction(ch chan<- struct{}) {
+ select {
+ case ch <- struct{}{}:
+ case _, _ = <-d.closeC:
+ d.compactionExitTransact()
+ }
+}
+
+type cCmd interface {
+ ack(err error)
+}
+
+type cIdle struct {
+ ackC chan<- error
+}
+
+func (r cIdle) ack(err error) {
+ r.ackC <- err
+}
+
+type cRange struct {
+ level int
+ min, max []byte
+ ackC chan<- error
+}
+
+func (r cRange) ack(err error) {
+ defer func() {
+ recover()
+ }()
+ if r.ackC != nil {
+ r.ackC <- err
+ }
+}
+
+func (d *DB) compSendIdle(compC chan<- cCmd) error {
+ ch := make(chan error)
+ defer close(ch)
+ // Send cmd.
+ select {
+ case compC <- cIdle{ch}:
+ case err := <-d.compErrC:
+ return err
+ case _, _ = <-d.closeC:
+ return ErrClosed
+ }
+ // Wait cmd.
+ return <-ch
+}
+
+func (d *DB) compSendRange(compC chan<- cCmd, level int, min, max []byte) (err error) {
+ ch := make(chan error)
+ defer close(ch)
+ // Send cmd.
+ select {
+ case compC <- cRange{level, min, max, ch}:
+ case err := <-d.compErrC:
+ return err
+ case _, _ = <-d.closeC:
+ return ErrClosed
+ }
+ // Wait cmd.
+ select {
+ case err = <-d.compErrC:
+ case err = <-ch:
+ }
+ return err
+}
+
+func (d *DB) compTrigger(compTriggerC chan struct{}) {
+ select {
+ case compTriggerC <- struct{}{}:
+ default:
+ }
+}
+
+func (d *DB) mCompaction() {
+ var x cCmd
+
+ defer func() {
+ if x := recover(); x != nil {
+ if x != errCompactionTransactExiting {
+ panic(x)
+ }
+ }
+ if x != nil {
+ x.ack(ErrClosed)
+ }
+ d.closeW.Done()
+ }()
+
+ for {
+ select {
+ case _, _ = <-d.closeC:
+ return
+ case x = <-d.mcompCmdC:
+ d.memCompaction()
+ x.ack(nil)
+ x = nil
+ case <-d.mcompTriggerC:
+ d.memCompaction()
+ }
+ }
+}
+
+func (d *DB) tCompaction() {
+ var x cCmd
+ var ackQ []cCmd
+
+ defer func() {
+ if x := recover(); x != nil {
+ if x != errCompactionTransactExiting {
+ panic(x)
+ }
+ }
+ for i := range ackQ {
+ ackQ[i].ack(ErrClosed)
+ ackQ[i] = nil
+ }
+ if x != nil {
+ x.ack(ErrClosed)
+ }
+ d.closeW.Done()
+ }()
+
+ for {
+ if d.tableNeedCompaction() {
+ select {
+ case x = <-d.tcompCmdC:
+ case <-d.tcompTriggerC:
+ case _, _ = <-d.closeC:
+ return
+ case ch := <-d.tcompPauseC:
+ d.pauseCompaction(ch)
+ continue
+ default:
+ }
+ } else {
+ for i := range ackQ {
+ ackQ[i].ack(nil)
+ ackQ[i] = nil
+ }
+ ackQ = ackQ[:0]
+ select {
+ case x = <-d.tcompCmdC:
+ case <-d.tcompTriggerC:
+ case ch := <-d.tcompPauseC:
+ d.pauseCompaction(ch)
+ continue
+ case _, _ = <-d.closeC:
+ return
+ }
+ }
+ if x != nil {
+ switch cmd := x.(type) {
+ case cIdle:
+ ackQ = append(ackQ, x)
+ case cRange:
+ d.tableRangeCompaction(cmd.level, cmd.min, cmd.max)
+ x.ack(nil)
+ }
+ x = nil
+ }
+ d.tableAutoCompaction()
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/db_iter.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/db_iter.go
new file mode 100644
index 000000000..9973a8fef
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/db_iter.go
@@ -0,0 +1,310 @@
+// Copyright (c) 2012, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package leveldb
+
+import (
+ "errors"
+ "runtime"
+
+ "github.com/syndtr/goleveldb/leveldb/iterator"
+ "github.com/syndtr/goleveldb/leveldb/opt"
+ "github.com/syndtr/goleveldb/leveldb/util"
+)
+
+var (
+ errInvalidIkey = errors.New("leveldb: Iterator: invalid internal key")
+)
+
+func (db *DB) newRawIterator(slice *util.Range, ro *opt.ReadOptions) iterator.Iterator {
+ s := db.s
+
+ em, fm := db.getMems()
+ v := s.version()
+
+ ti := v.getIterators(slice, ro)
+ n := len(ti) + 2
+ i := make([]iterator.Iterator, 0, n)
+ i = append(i, em.NewIterator(slice))
+ if fm != nil {
+ i = append(i, fm.NewIterator(slice))
+ }
+ i = append(i, ti...)
+ strict := s.o.GetStrict(opt.StrictIterator) || ro.GetStrict(opt.StrictIterator)
+ mi := iterator.NewMergedIterator(i, s.icmp, strict)
+ mi.SetReleaser(&versionReleaser{v: v})
+ return mi
+}
+
+func (db *DB) newIterator(seq uint64, slice *util.Range, ro *opt.ReadOptions) *dbIter {
+ var slice_ *util.Range
+ if slice != nil {
+ slice_ = &util.Range{}
+ if slice.Start != nil {
+ slice_.Start = newIKey(slice.Start, kMaxSeq, tSeek)
+ }
+ if slice.Limit != nil {
+ slice_.Limit = newIKey(slice.Limit, kMaxSeq, tSeek)
+ }
+ }
+ rawIter := db.newRawIterator(slice_, ro)
+ iter := &dbIter{
+ icmp: db.s.icmp,
+ iter: rawIter,
+ seq: seq,
+ strict: db.s.o.GetStrict(opt.StrictIterator) || ro.GetStrict(opt.StrictIterator),
+ key: make([]byte, 0),
+ value: make([]byte, 0),
+ }
+ runtime.SetFinalizer(iter, (*dbIter).Release)
+ return iter
+}
+
+type dir int
+
+const (
+ dirReleased dir = iota - 1
+ dirSOI
+ dirEOI
+ dirBackward
+ dirForward
+)
+
+// dbIter represent an interator states over a database session.
+type dbIter struct {
+ icmp *iComparer
+ iter iterator.Iterator
+ seq uint64
+ strict bool
+
+ dir dir
+ key []byte
+ value []byte
+ err error
+ releaser util.Releaser
+}
+
+func (i *dbIter) setErr(err error) {
+ i.err = err
+ i.key = nil
+ i.value = nil
+}
+
+func (i *dbIter) iterErr() {
+ if err := i.iter.Error(); err != nil {
+ i.setErr(err)
+ }
+}
+
+func (i *dbIter) Valid() bool {
+ return i.err == nil && i.dir > dirEOI
+}
+
+func (i *dbIter) First() bool {
+ if i.err != nil {
+ return false
+ } else if i.dir == dirReleased {
+ i.err = ErrIterReleased
+ return false
+ }
+
+ if i.iter.First() {
+ i.dir = dirSOI
+ return i.next()
+ }
+ i.dir = dirEOI
+ i.iterErr()
+ return false
+}
+
+func (i *dbIter) Last() bool {
+ if i.err != nil {
+ return false
+ } else if i.dir == dirReleased {
+ i.err = ErrIterReleased
+ return false
+ }
+
+ if i.iter.Last() {
+ return i.prev()
+ }
+ i.dir = dirSOI
+ i.iterErr()
+ return false
+}
+
+func (i *dbIter) Seek(key []byte) bool {
+ if i.err != nil {
+ return false
+ } else if i.dir == dirReleased {
+ i.err = ErrIterReleased
+ return false
+ }
+
+ ikey := newIKey(key, i.seq, tSeek)
+ if i.iter.Seek(ikey) {
+ i.dir = dirSOI
+ return i.next()
+ }
+ i.dir = dirEOI
+ i.iterErr()
+ return false
+}
+
+func (i *dbIter) next() bool {
+ for {
+ ukey, seq, t, ok := parseIkey(i.iter.Key())
+ if ok {
+ if seq <= i.seq {
+ switch t {
+ case tDel:
+ // Skip deleted key.
+ i.key = append(i.key[:0], ukey...)
+ i.dir = dirForward
+ case tVal:
+ if i.dir == dirSOI || i.icmp.uCompare(ukey, i.key) > 0 {
+ i.key = append(i.key[:0], ukey...)
+ i.value = append(i.value[:0], i.iter.Value()...)
+ i.dir = dirForward
+ return true
+ }
+ }
+ }
+ } else if i.strict {
+ i.setErr(errInvalidIkey)
+ break
+ }
+ if !i.iter.Next() {
+ i.dir = dirEOI
+ i.iterErr()
+ break
+ }
+ }
+ return false
+}
+
+func (i *dbIter) Next() bool {
+ if i.dir == dirEOI || i.err != nil {
+ return false
+ } else if i.dir == dirReleased {
+ i.err = ErrIterReleased
+ return false
+ }
+
+ if !i.iter.Next() || (i.dir == dirBackward && !i.iter.Next()) {
+ i.dir = dirEOI
+ i.iterErr()
+ return false
+ }
+ return i.next()
+}
+
+func (i *dbIter) prev() bool {
+ i.dir = dirBackward
+ del := true
+ if i.iter.Valid() {
+ for {
+ ukey, seq, t, ok := parseIkey(i.iter.Key())
+ if ok {
+ if seq <= i.seq {
+ if !del && i.icmp.uCompare(ukey, i.key) < 0 {
+ return true
+ }
+ del = (t == tDel)
+ if !del {
+ i.key = append(i.key[:0], ukey...)
+ i.value = append(i.value[:0], i.iter.Value()...)
+ }
+ }
+ } else if i.strict {
+ i.setErr(errInvalidIkey)
+ return false
+ }
+ if !i.iter.Prev() {
+ break
+ }
+ }
+ }
+ if del {
+ i.dir = dirSOI
+ i.iterErr()
+ return false
+ }
+ return true
+}
+
+func (i *dbIter) Prev() bool {
+ if i.dir == dirSOI || i.err != nil {
+ return false
+ } else if i.dir == dirReleased {
+ i.err = ErrIterReleased
+ return false
+ }
+
+ switch i.dir {
+ case dirEOI:
+ return i.Last()
+ case dirForward:
+ for i.iter.Prev() {
+ ukey, _, _, ok := parseIkey(i.iter.Key())
+ if ok {
+ if i.icmp.uCompare(ukey, i.key) < 0 {
+ goto cont
+ }
+ } else if i.strict {
+ i.setErr(errInvalidIkey)
+ return false
+ }
+ }
+ i.dir = dirSOI
+ i.iterErr()
+ return false
+ }
+
+cont:
+ return i.prev()
+}
+
+func (i *dbIter) Key() []byte {
+ if i.err != nil || i.dir <= dirEOI {
+ return nil
+ }
+ return i.key
+}
+
+func (i *dbIter) Value() []byte {
+ if i.err != nil || i.dir <= dirEOI {
+ return nil
+ }
+ return i.value
+}
+
+func (i *dbIter) Release() {
+ if i.dir != dirReleased {
+ // Clear the finalizer.
+ runtime.SetFinalizer(i, nil)
+
+ if i.releaser != nil {
+ i.releaser.Release()
+ }
+
+ i.dir = dirReleased
+ i.key = nil
+ i.value = nil
+ i.iter.Release()
+ i.iter = nil
+ }
+}
+
+func (i *dbIter) SetReleaser(releaser util.Releaser) {
+ if i.dir != dirReleased {
+ i.releaser = releaser
+ }
+}
+
+func (i *dbIter) Error() error {
+ return i.err
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/db_snapshot.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/db_snapshot.go
new file mode 100644
index 000000000..225b7cd5e
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/db_snapshot.go
@@ -0,0 +1,165 @@
+// Copyright (c) 2012, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package leveldb
+
+import (
+ "runtime"
+ "sync"
+
+ "github.com/syndtr/goleveldb/leveldb/iterator"
+ "github.com/syndtr/goleveldb/leveldb/opt"
+ "github.com/syndtr/goleveldb/leveldb/util"
+)
+
+type snapshotElement struct {
+ seq uint64
+ ref int
+ // Next and previous pointers in the doubly-linked list of elements.
+ next, prev *snapshotElement
+}
+
+// Initialize the snapshot.
+func (db *DB) initSnapshot() {
+ db.snapsRoot.next = &db.snapsRoot
+ db.snapsRoot.prev = &db.snapsRoot
+}
+
+// Acquires a snapshot, based on latest sequence.
+func (db *DB) acquireSnapshot() *snapshotElement {
+ db.snapsMu.Lock()
+ seq := db.getSeq()
+ elem := db.snapsRoot.prev
+ if elem == &db.snapsRoot || elem.seq != seq {
+ at := db.snapsRoot.prev
+ next := at.next
+ elem = &snapshotElement{
+ seq: seq,
+ prev: at,
+ next: next,
+ }
+ at.next = elem
+ next.prev = elem
+ }
+ elem.ref++
+ db.snapsMu.Unlock()
+ return elem
+}
+
+// Releases given snapshot element.
+func (db *DB) releaseSnapshot(elem *snapshotElement) {
+ if !db.isClosed() {
+ db.snapsMu.Lock()
+ elem.ref--
+ if elem.ref == 0 {
+ elem.prev.next = elem.next
+ elem.next.prev = elem.prev
+ elem.next = nil
+ elem.prev = nil
+ } else if elem.ref < 0 {
+ panic("leveldb: Snapshot: negative element reference")
+ }
+ db.snapsMu.Unlock()
+ }
+}
+
+// Gets minimum sequence that not being snapshoted.
+func (db *DB) minSeq() uint64 {
+ db.snapsMu.Lock()
+ defer db.snapsMu.Unlock()
+ elem := db.snapsRoot.prev
+ if elem != &db.snapsRoot {
+ return elem.seq
+ }
+ return db.getSeq()
+}
+
+// Snapshot is a DB snapshot.
+type Snapshot struct {
+ db *DB
+ elem *snapshotElement
+ mu sync.Mutex
+ released bool
+}
+
+// Creates new snapshot object.
+func (db *DB) newSnapshot() *Snapshot {
+ p := &Snapshot{
+ db: db,
+ elem: db.acquireSnapshot(),
+ }
+ runtime.SetFinalizer(p, (*Snapshot).Release)
+ return p
+}
+
+// Get gets the value for the given key. It returns ErrNotFound if
+// the DB does not contain the key.
+//
+// The caller should not modify the contents of the returned slice, but
+// it is safe to modify the contents of the argument after Get returns.
+func (p *Snapshot) Get(key []byte, ro *opt.ReadOptions) (value []byte, err error) {
+ db := p.db
+ err = db.ok()
+ if err != nil {
+ return
+ }
+ p.mu.Lock()
+ defer p.mu.Unlock()
+ if p.released {
+ err = ErrSnapshotReleased
+ return
+ }
+ return db.get(key, p.elem.seq, ro)
+}
+
+// NewIterator returns an iterator for the snapshot of the uderlying DB.
+// The returned iterator is not goroutine-safe, but it is safe to use
+// multiple iterators concurrently, with each in a dedicated goroutine.
+// It is also safe to use an iterator concurrently with modifying its
+// underlying DB. The resultant key/value pairs are guaranteed to be
+// consistent.
+//
+// Slice allows slicing the iterator to only contains keys in the given
+// range. A nil Range.Start is treated as a key before all keys in the
+// DB. And a nil Range.Limit is treated as a key after all keys in
+// the DB.
+//
+// The iterator must be released after use, by calling Release method.
+// Releasing the snapshot doesn't mean releasing the iterator too, the
+// iterator would be still valid until released.
+//
+// Also read Iterator documentation of the leveldb/iterator package.
+func (p *Snapshot) NewIterator(slice *util.Range, ro *opt.ReadOptions) iterator.Iterator {
+ db := p.db
+ if err := db.ok(); err != nil {
+ return iterator.NewEmptyIterator(err)
+ }
+ p.mu.Lock()
+ defer p.mu.Unlock()
+ if p.released {
+ return iterator.NewEmptyIterator(ErrSnapshotReleased)
+ }
+ return db.newIterator(p.elem.seq, slice, ro)
+}
+
+// Release releases the snapshot. This will not release any returned
+// iterators, the iterators would still be valid until released or the
+// underlying DB is closed.
+//
+// Other methods should not be called after the snapshot has been released.
+func (p *Snapshot) Release() {
+ p.mu.Lock()
+ if !p.released {
+ // Clear the finalizer.
+ runtime.SetFinalizer(p, nil)
+
+ p.released = true
+ p.db.releaseSnapshot(p.elem)
+ p.db = nil
+ p.elem = nil
+ }
+ p.mu.Unlock()
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/db_state.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/db_state.go
new file mode 100644
index 000000000..a13706142
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/db_state.go
@@ -0,0 +1,114 @@
+// Copyright (c) 2013, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package leveldb
+
+import (
+ "sync/atomic"
+
+ "github.com/syndtr/goleveldb/leveldb/journal"
+ "github.com/syndtr/goleveldb/leveldb/memdb"
+)
+
+// Get latest sequence number.
+func (d *DB) getSeq() uint64 {
+ return atomic.LoadUint64(&d.seq)
+}
+
+// Atomically adds delta to seq.
+func (d *DB) addSeq(delta uint64) {
+ atomic.AddUint64(&d.seq, delta)
+}
+
+// Create new memdb and froze the old one; need external synchronization.
+// newMem only called synchronously by the writer.
+func (d *DB) newMem(n int) (mem *memdb.DB, err error) {
+ s := d.s
+
+ num := s.allocFileNum()
+ file := s.getJournalFile(num)
+ w, err := file.Create()
+ if err != nil {
+ s.reuseFileNum(num)
+ return
+ }
+ d.memMu.Lock()
+ if d.journal == nil {
+ d.journal = journal.NewWriter(w)
+ } else {
+ d.journal.Reset(w)
+ d.journalWriter.Close()
+ d.frozenJournalFile = d.journalFile
+ }
+ d.journalWriter = w
+ d.journalFile = file
+ d.frozenMem = d.mem
+ d.mem = memdb.New(s.icmp, maxInt(d.s.o.GetWriteBuffer(), n))
+ mem = d.mem
+ // The seq only incremented by the writer.
+ d.frozenSeq = d.seq
+ d.memMu.Unlock()
+ return
+}
+
+// Get all memdbs.
+func (d *DB) getMems() (e *memdb.DB, f *memdb.DB) {
+ d.memMu.RLock()
+ defer d.memMu.RUnlock()
+ return d.mem, d.frozenMem
+}
+
+// Get frozen memdb.
+func (d *DB) getEffectiveMem() *memdb.DB {
+ d.memMu.RLock()
+ defer d.memMu.RUnlock()
+ return d.mem
+}
+
+// Check whether we has frozen memdb.
+func (d *DB) hasFrozenMem() bool {
+ d.memMu.RLock()
+ defer d.memMu.RUnlock()
+ return d.frozenMem != nil
+}
+
+// Get frozen memdb.
+func (d *DB) getFrozenMem() *memdb.DB {
+ d.memMu.RLock()
+ defer d.memMu.RUnlock()
+ return d.frozenMem
+}
+
+// Drop frozen memdb; assume that frozen memdb isn't nil.
+func (d *DB) dropFrozenMem() {
+ d.memMu.Lock()
+ if err := d.frozenJournalFile.Remove(); err != nil {
+ d.s.logf("journal@remove removing @%d %q", d.frozenJournalFile.Num(), err)
+ } else {
+ d.s.logf("journal@remove removed @%d", d.frozenJournalFile.Num())
+ }
+ d.frozenJournalFile = nil
+ d.frozenMem = nil
+ d.memMu.Unlock()
+}
+
+// Set closed flag; return true if not already closed.
+func (d *DB) setClosed() bool {
+ return atomic.CompareAndSwapUint32(&d.closed, 0, 1)
+}
+
+// Check whether DB was closed.
+func (d *DB) isClosed() bool {
+ return atomic.LoadUint32(&d.closed) != 0
+}
+
+// Check read ok status.
+func (d *DB) ok() error {
+ if d.isClosed() {
+ return ErrClosed
+ }
+ return nil
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/db_test.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/db_test.go
new file mode 100644
index 000000000..5de7d9723
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/db_test.go
@@ -0,0 +1,1888 @@
+// Copyright (c) 2012, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package leveldb
+
+import (
+ "fmt"
+ "math/rand"
+ "os"
+ "path/filepath"
+ "runtime"
+ "strings"
+ "sync"
+ "sync/atomic"
+ "testing"
+ "time"
+ "unsafe"
+
+ "github.com/syndtr/goleveldb/leveldb/comparer"
+ "github.com/syndtr/goleveldb/leveldb/filter"
+ "github.com/syndtr/goleveldb/leveldb/iterator"
+ "github.com/syndtr/goleveldb/leveldb/opt"
+ "github.com/syndtr/goleveldb/leveldb/storage"
+ "github.com/syndtr/goleveldb/leveldb/util"
+)
+
+func tkey(i int) []byte {
+ return []byte(fmt.Sprintf("%016d", i))
+}
+
+func tval(seed, n int) []byte {
+ r := rand.New(rand.NewSource(int64(seed)))
+ return randomString(r, n)
+}
+
+type dbHarness struct {
+ t *testing.T
+
+ stor *testStorage
+ db *DB
+ o *opt.Options
+ ro *opt.ReadOptions
+ wo *opt.WriteOptions
+}
+
+func newDbHarnessWopt(t *testing.T, o *opt.Options) *dbHarness {
+ h := new(dbHarness)
+ h.init(t, o)
+ return h
+}
+
+func newDbHarness(t *testing.T) *dbHarness {
+ return newDbHarnessWopt(t, &opt.Options{})
+}
+
+func (h *dbHarness) init(t *testing.T, o *opt.Options) {
+ h.t = t
+ h.stor = newTestStorage(t)
+ h.o = o
+ h.ro = nil
+ h.wo = nil
+
+ if err := h.openDB0(); err != nil {
+ // So that it will come after fatal message.
+ defer h.stor.Close()
+ h.t.Fatal("Open (init): got error: ", err)
+ }
+}
+
+func (h *dbHarness) openDB0() (err error) {
+ h.t.Log("opening DB")
+ h.db, err = Open(h.stor, h.o)
+ return
+}
+
+func (h *dbHarness) openDB() {
+ if err := h.openDB0(); err != nil {
+ h.t.Fatal("Open: got error: ", err)
+ }
+}
+
+func (h *dbHarness) closeDB0() error {
+ h.t.Log("closing DB")
+ return h.db.Close()
+}
+
+func (h *dbHarness) closeDB() {
+ if err := h.closeDB0(); err != nil {
+ h.t.Error("Close: got error: ", err)
+ }
+ h.stor.CloseCheck()
+ runtime.GC()
+}
+
+func (h *dbHarness) reopenDB() {
+ h.closeDB()
+ h.openDB()
+}
+
+func (h *dbHarness) close() {
+ h.closeDB0()
+ h.db = nil
+ h.stor.Close()
+ h.stor = nil
+ runtime.GC()
+}
+
+func (h *dbHarness) openAssert(want bool) {
+ db, err := Open(h.stor, h.o)
+ if err != nil {
+ if want {
+ h.t.Error("Open: assert: got error: ", err)
+ } else {
+ h.t.Log("Open: assert: got error (expected): ", err)
+ }
+ } else {
+ if !want {
+ h.t.Error("Open: assert: expect error")
+ }
+ db.Close()
+ }
+}
+
+func (h *dbHarness) write(batch *Batch) {
+ if err := h.db.Write(batch, h.wo); err != nil {
+ h.t.Error("Write: got error: ", err)
+ }
+}
+
+func (h *dbHarness) put(key, value string) {
+ if err := h.db.Put([]byte(key), []byte(value), h.wo); err != nil {
+ h.t.Error("Put: got error: ", err)
+ }
+}
+
+func (h *dbHarness) putMulti(n int, low, hi string) {
+ for i := 0; i < n; i++ {
+ h.put(low, "begin")
+ h.put(hi, "end")
+ h.compactMem()
+ }
+}
+
+func (h *dbHarness) maxNextLevelOverlappingBytes(want uint64) {
+ t := h.t
+ db := h.db
+
+ var res uint64
+ v := db.s.version()
+ for i, tt := range v.tables[1 : len(v.tables)-1] {
+ level := i + 1
+ next := v.tables[level+1]
+ for _, t := range tt {
+ var r tFiles
+ min, max := t.min.ukey(), t.max.ukey()
+ next.getOverlaps(min, max, &r, true, db.s.icmp.ucmp)
+ sum := r.size()
+ if sum > res {
+ res = sum
+ }
+ }
+ }
+ v.release()
+
+ if res > want {
+ t.Errorf("next level overlapping bytes is more than %d, got=%d", want, res)
+ }
+}
+
+func (h *dbHarness) delete(key string) {
+ t := h.t
+ db := h.db
+
+ err := db.Delete([]byte(key), h.wo)
+ if err != nil {
+ t.Error("Delete: got error: ", err)
+ }
+}
+
+func (h *dbHarness) assertNumKeys(want int) {
+ iter := h.db.NewIterator(nil, h.ro)
+ defer iter.Release()
+ got := 0
+ for iter.Next() {
+ got++
+ }
+ if err := iter.Error(); err != nil {
+ h.t.Error("assertNumKeys: ", err)
+ }
+ if want != got {
+ h.t.Errorf("assertNumKeys: want=%d got=%d", want, got)
+ }
+}
+
+func (h *dbHarness) getr(db Reader, key string, expectFound bool) (found bool, v []byte) {
+ t := h.t
+ v, err := db.Get([]byte(key), h.ro)
+ switch err {
+ case ErrNotFound:
+ if expectFound {
+ t.Errorf("Get: key '%s' not found, want found", key)
+ }
+ case nil:
+ found = true
+ if !expectFound {
+ t.Errorf("Get: key '%s' found, want not found", key)
+ }
+ default:
+ t.Error("Get: got error: ", err)
+ }
+ return
+}
+
+func (h *dbHarness) get(key string, expectFound bool) (found bool, v []byte) {
+ return h.getr(h.db, key, expectFound)
+}
+
+func (h *dbHarness) getValr(db Reader, key, value string) {
+ t := h.t
+ found, r := h.getr(db, key, true)
+ if !found {
+ return
+ }
+ rval := string(r)
+ if rval != value {
+ t.Errorf("Get: invalid value, got '%s', want '%s'", rval, value)
+ }
+}
+
+func (h *dbHarness) getVal(key, value string) {
+ h.getValr(h.db, key, value)
+}
+
+func (h *dbHarness) allEntriesFor(key, want string) {
+ t := h.t
+ db := h.db
+ s := db.s
+
+ ikey := newIKey([]byte(key), kMaxSeq, tVal)
+ iter := db.newRawIterator(nil, nil)
+ if !iter.Seek(ikey) && iter.Error() != nil {
+ t.Error("AllEntries: error during seek, err: ", iter.Error())
+ return
+ }
+ res := "[ "
+ first := true
+ for iter.Valid() {
+ rkey := iKey(iter.Key())
+ if _, t, ok := rkey.parseNum(); ok {
+ if s.icmp.uCompare(ikey.ukey(), rkey.ukey()) != 0 {
+ break
+ }
+ if !first {
+ res += ", "
+ }
+ first = false
+ switch t {
+ case tVal:
+ res += string(iter.Value())
+ case tDel:
+ res += "DEL"
+ }
+ } else {
+ if !first {
+ res += ", "
+ }
+ first = false
+ res += "CORRUPTED"
+ }
+ iter.Next()
+ }
+ if !first {
+ res += " "
+ }
+ res += "]"
+ if res != want {
+ t.Errorf("AllEntries: assert failed for key %q, got=%q want=%q", key, res, want)
+ }
+}
+
+// Return a string that contains all key,value pairs in order,
+// formatted like "(k1->v1)(k2->v2)".
+func (h *dbHarness) getKeyVal(want string) {
+ t := h.t
+ db := h.db
+
+ s, err := db.GetSnapshot()
+ if err != nil {
+ t.Fatal("GetSnapshot: got error: ", err)
+ }
+ res := ""
+ iter := s.NewIterator(nil, nil)
+ for iter.Next() {
+ res += fmt.Sprintf("(%s->%s)", string(iter.Key()), string(iter.Value()))
+ }
+ iter.Release()
+
+ if res != want {
+ t.Errorf("GetKeyVal: invalid key/value pair, got=%q want=%q", res, want)
+ }
+ s.Release()
+}
+
+func (h *dbHarness) waitCompaction() {
+ t := h.t
+ db := h.db
+ if err := db.compSendIdle(db.tcompCmdC); err != nil {
+ t.Error("compaction error: ", err)
+ }
+}
+
+func (h *dbHarness) waitMemCompaction() {
+ t := h.t
+ db := h.db
+
+ if err := db.compSendIdle(db.mcompCmdC); err != nil {
+ t.Error("compaction error: ", err)
+ }
+}
+
+func (h *dbHarness) compactMem() {
+ t := h.t
+ db := h.db
+
+ db.writeLockC <- struct{}{}
+ defer func() {
+ <-db.writeLockC
+ }()
+
+ if _, err := db.rotateMem(0); err != nil {
+ t.Error("compaction error: ", err)
+ }
+ if err := db.compSendIdle(db.mcompCmdC); err != nil {
+ t.Error("compaction error: ", err)
+ }
+
+ if h.totalTables() == 0 {
+ t.Error("zero tables after mem compaction")
+ }
+}
+
+func (h *dbHarness) compactRangeAtErr(level int, min, max string, wanterr bool) {
+ t := h.t
+ db := h.db
+
+ var _min, _max []byte
+ if min != "" {
+ _min = []byte(min)
+ }
+ if max != "" {
+ _max = []byte(max)
+ }
+
+ if err := db.compSendRange(db.tcompCmdC, level, _min, _max); err != nil {
+ if wanterr {
+ t.Log("CompactRangeAt: got error (expected): ", err)
+ } else {
+ t.Error("CompactRangeAt: got error: ", err)
+ }
+ } else if wanterr {
+ t.Error("CompactRangeAt: expect error")
+ }
+}
+
+func (h *dbHarness) compactRangeAt(level int, min, max string) {
+ h.compactRangeAtErr(level, min, max, false)
+}
+
+func (h *dbHarness) compactRange(min, max string) {
+ t := h.t
+ db := h.db
+
+ var r util.Range
+ if min != "" {
+ r.Start = []byte(min)
+ }
+ if max != "" {
+ r.Limit = []byte(max)
+ }
+ if err := db.CompactRange(r); err != nil {
+ t.Error("CompactRange: got error: ", err)
+ }
+}
+
+func (h *dbHarness) sizeAssert(start, limit string, low, hi uint64) {
+ t := h.t
+ db := h.db
+
+ s, err := db.SizeOf([]util.Range{
+ {[]byte(start), []byte(limit)},
+ })
+ if err != nil {
+ t.Error("SizeOf: got error: ", err)
+ }
+ if s.Sum() < low || s.Sum() > hi {
+ t.Errorf("sizeof %q to %q not in range, want %d - %d, got %d",
+ shorten(start), shorten(limit), low, hi, s.Sum())
+ }
+}
+
+func (h *dbHarness) getSnapshot() (s *Snapshot) {
+ s, err := h.db.GetSnapshot()
+ if err != nil {
+ h.t.Fatal("GetSnapshot: got error: ", err)
+ }
+ return
+}
+func (h *dbHarness) tablesPerLevel(want string) {
+ res := ""
+ nz := 0
+ v := h.db.s.version()
+ for level, tt := range v.tables {
+ if level > 0 {
+ res += ","
+ }
+ res += fmt.Sprint(len(tt))
+ if len(tt) > 0 {
+ nz = len(res)
+ }
+ }
+ v.release()
+ res = res[:nz]
+ if res != want {
+ h.t.Errorf("invalid tables len, want=%s, got=%s", want, res)
+ }
+}
+
+func (h *dbHarness) totalTables() (n int) {
+ v := h.db.s.version()
+ for _, tt := range v.tables {
+ n += len(tt)
+ }
+ v.release()
+ return
+}
+
+type keyValue interface {
+ Key() []byte
+ Value() []byte
+}
+
+func testKeyVal(t *testing.T, kv keyValue, want string) {
+ res := string(kv.Key()) + "->" + string(kv.Value())
+ if res != want {
+ t.Errorf("invalid key/value, want=%q, got=%q", want, res)
+ }
+}
+
+func numKey(num int) string {
+ return fmt.Sprintf("key%06d", num)
+}
+
+var _bloom_filter = filter.NewBloomFilter(10)
+
+func truno(t *testing.T, o *opt.Options, f func(h *dbHarness)) {
+ for i := 0; i < 4; i++ {
+ func() {
+ switch i {
+ case 0:
+ case 1:
+ if o == nil {
+ o = &opt.Options{Filter: _bloom_filter}
+ } else {
+ old := o
+ o = &opt.Options{}
+ *o = *old
+ o.Filter = _bloom_filter
+ }
+ case 2:
+ if o == nil {
+ o = &opt.Options{Compression: opt.NoCompression}
+ } else {
+ old := o
+ o = &opt.Options{}
+ *o = *old
+ o.Compression = opt.NoCompression
+ }
+ }
+ h := newDbHarnessWopt(t, o)
+ defer h.close()
+ switch i {
+ case 3:
+ h.reopenDB()
+ }
+ f(h)
+ }()
+ }
+}
+
+func trun(t *testing.T, f func(h *dbHarness)) {
+ truno(t, nil, f)
+}
+
+func testAligned(t *testing.T, name string, offset uintptr) {
+ if offset%8 != 0 {
+ t.Errorf("field %s offset is not 64-bit aligned", name)
+ }
+}
+
+func Test_FieldsAligned(t *testing.T) {
+ p1 := new(DB)
+ testAligned(t, "DB.seq", unsafe.Offsetof(p1.seq))
+ p2 := new(session)
+ testAligned(t, "session.stFileNum", unsafe.Offsetof(p2.stFileNum))
+ testAligned(t, "session.stJournalNum", unsafe.Offsetof(p2.stJournalNum))
+ testAligned(t, "session.stPrevJournalNum", unsafe.Offsetof(p2.stPrevJournalNum))
+ testAligned(t, "session.stSeq", unsafe.Offsetof(p2.stSeq))
+}
+
+func TestDb_Locking(t *testing.T) {
+ h := newDbHarness(t)
+ defer h.stor.Close()
+ h.openAssert(false)
+ h.closeDB()
+ h.openAssert(true)
+}
+
+func TestDb_Empty(t *testing.T) {
+ trun(t, func(h *dbHarness) {
+ h.get("foo", false)
+
+ h.reopenDB()
+ h.get("foo", false)
+ })
+}
+
+func TestDb_ReadWrite(t *testing.T) {
+ trun(t, func(h *dbHarness) {
+ h.put("foo", "v1")
+ h.getVal("foo", "v1")
+ h.put("bar", "v2")
+ h.put("foo", "v3")
+ h.getVal("foo", "v3")
+ h.getVal("bar", "v2")
+
+ h.reopenDB()
+ h.getVal("foo", "v3")
+ h.getVal("bar", "v2")
+ })
+}
+
+func TestDb_PutDeleteGet(t *testing.T) {
+ trun(t, func(h *dbHarness) {
+ h.put("foo", "v1")
+ h.getVal("foo", "v1")
+ h.put("foo", "v2")
+ h.getVal("foo", "v2")
+ h.delete("foo")
+ h.get("foo", false)
+
+ h.reopenDB()
+ h.get("foo", false)
+ })
+}
+
+func TestDb_EmptyBatch(t *testing.T) {
+ h := newDbHarness(t)
+ defer h.close()
+
+ h.get("foo", false)
+ err := h.db.Write(new(Batch), h.wo)
+ if err != nil {
+ t.Error("writing empty batch yield error: ", err)
+ }
+ h.get("foo", false)
+}
+
+func TestDb_GetFromFrozen(t *testing.T) {
+ h := newDbHarnessWopt(t, &opt.Options{WriteBuffer: 100100})
+ defer h.close()
+
+ h.put("foo", "v1")
+ h.getVal("foo", "v1")
+
+ h.stor.DelaySync(storage.TypeTable) // Block sync calls
+ h.put("k1", strings.Repeat("x", 100000)) // Fill memtable
+ h.put("k2", strings.Repeat("y", 100000)) // Trigger compaction
+ for i := 0; h.db.getFrozenMem() == nil && i < 100; i++ {
+ time.Sleep(10 * time.Microsecond)
+ }
+ if h.db.getFrozenMem() == nil {
+ h.stor.ReleaseSync(storage.TypeTable)
+ t.Fatal("No frozen mem")
+ }
+ h.getVal("foo", "v1")
+ h.stor.ReleaseSync(storage.TypeTable) // Release sync calls
+
+ h.reopenDB()
+ h.getVal("foo", "v1")
+ h.get("k1", true)
+ h.get("k2", true)
+}
+
+func TestDb_GetFromTable(t *testing.T) {
+ trun(t, func(h *dbHarness) {
+ h.put("foo", "v1")
+ h.compactMem()
+ h.getVal("foo", "v1")
+ })
+}
+
+func TestDb_GetSnapshot(t *testing.T) {
+ trun(t, func(h *dbHarness) {
+ bar := strings.Repeat("b", 200)
+ h.put("foo", "v1")
+ h.put(bar, "v1")
+
+ snap, err := h.db.GetSnapshot()
+ if err != nil {
+ t.Fatal("GetSnapshot: got error: ", err)
+ }
+
+ h.put("foo", "v2")
+ h.put(bar, "v2")
+
+ h.getVal("foo", "v2")
+ h.getVal(bar, "v2")
+ h.getValr(snap, "foo", "v1")
+ h.getValr(snap, bar, "v1")
+
+ h.compactMem()
+
+ h.getVal("foo", "v2")
+ h.getVal(bar, "v2")
+ h.getValr(snap, "foo", "v1")
+ h.getValr(snap, bar, "v1")
+
+ snap.Release()
+
+ h.reopenDB()
+ h.getVal("foo", "v2")
+ h.getVal(bar, "v2")
+ })
+}
+
+func TestDb_GetLevel0Ordering(t *testing.T) {
+ trun(t, func(h *dbHarness) {
+ for i := 0; i < 4; i++ {
+ h.put("bar", fmt.Sprintf("b%d", i))
+ h.put("foo", fmt.Sprintf("v%d", i))
+ h.compactMem()
+ }
+ h.getVal("foo", "v3")
+ h.getVal("bar", "b3")
+
+ v := h.db.s.version()
+ t0len := v.tLen(0)
+ v.release()
+ if t0len < 2 {
+ t.Errorf("level-0 tables is less than 2, got %d", t0len)
+ }
+
+ h.reopenDB()
+ h.getVal("foo", "v3")
+ h.getVal("bar", "b3")
+ })
+}
+
+func TestDb_GetOrderedByLevels(t *testing.T) {
+ trun(t, func(h *dbHarness) {
+ h.put("foo", "v1")
+ h.compactMem()
+ h.compactRange("a", "z")
+ h.getVal("foo", "v1")
+ h.put("foo", "v2")
+ h.compactMem()
+ h.getVal("foo", "v2")
+ })
+}
+
+func TestDb_GetPicksCorrectFile(t *testing.T) {
+ trun(t, func(h *dbHarness) {
+ // Arrange to have multiple files in a non-level-0 level.
+ h.put("a", "va")
+ h.compactMem()
+ h.compactRange("a", "b")
+ h.put("x", "vx")
+ h.compactMem()
+ h.compactRange("x", "y")
+ h.put("f", "vf")
+ h.compactMem()
+ h.compactRange("f", "g")
+
+ h.getVal("a", "va")
+ h.getVal("f", "vf")
+ h.getVal("x", "vx")
+
+ h.compactRange("", "")
+ h.getVal("a", "va")
+ h.getVal("f", "vf")
+ h.getVal("x", "vx")
+ })
+}
+
+func TestDb_GetEncountersEmptyLevel(t *testing.T) {
+ trun(t, func(h *dbHarness) {
+ // Arrange for the following to happen:
+ // * sstable A in level 0
+ // * nothing in level 1
+ // * sstable B in level 2
+ // Then do enough Get() calls to arrange for an automatic compaction
+ // of sstable A. A bug would cause the compaction to be marked as
+ // occuring at level 1 (instead of the correct level 0).
+
+ // Step 1: First place sstables in levels 0 and 2
+ for i := 0; ; i++ {
+ if i >= 100 {
+ t.Fatal("could not fill levels-0 and level-2")
+ }
+ v := h.db.s.version()
+ if v.tLen(0) > 0 && v.tLen(2) > 0 {
+ v.release()
+ break
+ }
+ v.release()
+ h.put("a", "begin")
+ h.put("z", "end")
+ h.compactMem()
+
+ h.getVal("a", "begin")
+ h.getVal("z", "end")
+ }
+
+ // Step 2: clear level 1 if necessary.
+ h.compactRangeAt(1, "", "")
+ h.tablesPerLevel("1,0,1")
+
+ h.getVal("a", "begin")
+ h.getVal("z", "end")
+
+ // Step 3: read a bunch of times
+ for i := 0; i < 200; i++ {
+ h.get("missing", false)
+ }
+
+ // Step 4: Wait for compaction to finish
+ h.waitCompaction()
+
+ v := h.db.s.version()
+ if v.tLen(0) > 0 {
+ t.Errorf("level-0 tables more than 0, got %d", v.tLen(0))
+ }
+ v.release()
+
+ h.getVal("a", "begin")
+ h.getVal("z", "end")
+ })
+}
+
+func TestDb_IterMultiWithDelete(t *testing.T) {
+ trun(t, func(h *dbHarness) {
+ h.put("a", "va")
+ h.put("b", "vb")
+ h.put("c", "vc")
+ h.delete("b")
+ h.get("b", false)
+
+ iter := h.db.NewIterator(nil, nil)
+ iter.Seek([]byte("c"))
+ testKeyVal(t, iter, "c->vc")
+ iter.Prev()
+ testKeyVal(t, iter, "a->va")
+ iter.Release()
+
+ h.compactMem()
+
+ iter = h.db.NewIterator(nil, nil)
+ iter.Seek([]byte("c"))
+ testKeyVal(t, iter, "c->vc")
+ iter.Prev()
+ testKeyVal(t, iter, "a->va")
+ iter.Release()
+ })
+}
+
+func TestDb_IteratorPinsRef(t *testing.T) {
+ h := newDbHarness(t)
+ defer h.close()
+
+ h.put("foo", "hello")
+
+ // Get iterator that will yield the current contents of the DB.
+ iter := h.db.NewIterator(nil, nil)
+
+ // Write to force compactions
+ h.put("foo", "newvalue1")
+ for i := 0; i < 100; i++ {
+ h.put(numKey(i), strings.Repeat(fmt.Sprintf("v%09d", i), 100000/10))
+ }
+ h.put("foo", "newvalue2")
+
+ iter.First()
+ testKeyVal(t, iter, "foo->hello")
+ if iter.Next() {
+ t.Errorf("expect eof")
+ }
+ iter.Release()
+}
+
+func TestDb_Recover(t *testing.T) {
+ trun(t, func(h *dbHarness) {
+ h.put("foo", "v1")
+ h.put("baz", "v5")
+
+ h.reopenDB()
+ h.getVal("foo", "v1")
+
+ h.getVal("foo", "v1")
+ h.getVal("baz", "v5")
+ h.put("bar", "v2")
+ h.put("foo", "v3")
+
+ h.reopenDB()
+ h.getVal("foo", "v3")
+ h.put("foo", "v4")
+ h.getVal("foo", "v4")
+ h.getVal("bar", "v2")
+ h.getVal("baz", "v5")
+ })
+}
+
+func TestDb_RecoverWithEmptyJournal(t *testing.T) {
+ trun(t, func(h *dbHarness) {
+ h.put("foo", "v1")
+ h.put("foo", "v2")
+
+ h.reopenDB()
+ h.reopenDB()
+ h.put("foo", "v3")
+
+ h.reopenDB()
+ h.getVal("foo", "v3")
+ })
+}
+
+func TestDb_RecoverDuringMemtableCompaction(t *testing.T) {
+ truno(t, &opt.Options{WriteBuffer: 1000000}, func(h *dbHarness) {
+
+ h.stor.DelaySync(storage.TypeTable)
+ h.put("big1", strings.Repeat("x", 10000000))
+ h.put("big2", strings.Repeat("y", 1000))
+ h.put("bar", "v2")
+ h.stor.ReleaseSync(storage.TypeTable)
+
+ h.reopenDB()
+ h.getVal("bar", "v2")
+ h.getVal("big1", strings.Repeat("x", 10000000))
+ h.getVal("big2", strings.Repeat("y", 1000))
+ })
+}
+
+func TestDb_MinorCompactionsHappen(t *testing.T) {
+ h := newDbHarnessWopt(t, &opt.Options{WriteBuffer: 10000})
+ defer h.close()
+
+ n := 500
+
+ key := func(i int) string {
+ return fmt.Sprintf("key%06d", i)
+ }
+
+ for i := 0; i < n; i++ {
+ h.put(key(i), key(i)+strings.Repeat("v", 1000))
+ }
+
+ for i := 0; i < n; i++ {
+ h.getVal(key(i), key(i)+strings.Repeat("v", 1000))
+ }
+
+ h.reopenDB()
+ for i := 0; i < n; i++ {
+ h.getVal(key(i), key(i)+strings.Repeat("v", 1000))
+ }
+}
+
+func TestDb_RecoverWithLargeJournal(t *testing.T) {
+ h := newDbHarness(t)
+ defer h.close()
+
+ h.put("big1", strings.Repeat("1", 200000))
+ h.put("big2", strings.Repeat("2", 200000))
+ h.put("small3", strings.Repeat("3", 10))
+ h.put("small4", strings.Repeat("4", 10))
+ h.tablesPerLevel("")
+
+ // Make sure that if we re-open with a small write buffer size that
+ // we flush table files in the middle of a large journal file.
+ h.o.WriteBuffer = 100000
+ h.reopenDB()
+ h.getVal("big1", strings.Repeat("1", 200000))
+ h.getVal("big2", strings.Repeat("2", 200000))
+ h.getVal("small3", strings.Repeat("3", 10))
+ h.getVal("small4", strings.Repeat("4", 10))
+ v := h.db.s.version()
+ if v.tLen(0) <= 1 {
+ t.Errorf("tables-0 less than one")
+ }
+ v.release()
+}
+
+func TestDb_CompactionsGenerateMultipleFiles(t *testing.T) {
+ h := newDbHarnessWopt(t, &opt.Options{
+ WriteBuffer: 10000000,
+ Compression: opt.NoCompression,
+ })
+ defer h.close()
+
+ v := h.db.s.version()
+ if v.tLen(0) > 0 {
+ t.Errorf("level-0 tables more than 0, got %d", v.tLen(0))
+ }
+ v.release()
+
+ n := 80
+
+ // Write 8MB (80 values, each 100K)
+ for i := 0; i < n; i++ {
+ h.put(numKey(i), strings.Repeat(fmt.Sprintf("v%09d", i), 100000/10))
+ }
+
+ // Reopening moves updates to level-0
+ h.reopenDB()
+ h.compactRangeAt(0, "", "")
+
+ v = h.db.s.version()
+ if v.tLen(0) > 0 {
+ t.Errorf("level-0 tables more than 0, got %d", v.tLen(0))
+ }
+ if v.tLen(1) <= 1 {
+ t.Errorf("level-1 tables less than 1, got %d", v.tLen(1))
+ }
+ v.release()
+
+ for i := 0; i < n; i++ {
+ h.getVal(numKey(i), strings.Repeat(fmt.Sprintf("v%09d", i), 100000/10))
+ }
+}
+
+func TestDb_RepeatedWritesToSameKey(t *testing.T) {
+ h := newDbHarnessWopt(t, &opt.Options{WriteBuffer: 100000})
+ defer h.close()
+
+ maxTables := kNumLevels + kL0_StopWritesTrigger
+
+ value := strings.Repeat("v", 2*h.o.GetWriteBuffer())
+ for i := 0; i < 5*maxTables; i++ {
+ h.put("key", value)
+ n := h.totalTables()
+ if n > maxTables {
+ t.Errorf("total tables exceed %d, got=%d, iter=%d", maxTables, n, i)
+ }
+ }
+}
+
+func TestDb_RepeatedWritesToSameKeyAfterReopen(t *testing.T) {
+ h := newDbHarnessWopt(t, &opt.Options{WriteBuffer: 100000})
+ defer h.close()
+
+ h.reopenDB()
+
+ maxTables := kNumLevels + kL0_StopWritesTrigger
+
+ value := strings.Repeat("v", 2*h.o.GetWriteBuffer())
+ for i := 0; i < 5*maxTables; i++ {
+ h.put("key", value)
+ n := h.totalTables()
+ if n > maxTables {
+ t.Errorf("total tables exceed %d, got=%d, iter=%d", maxTables, n, i)
+ }
+ }
+}
+
+func TestDb_SparseMerge(t *testing.T) {
+ h := newDbHarnessWopt(t, &opt.Options{Compression: opt.NoCompression})
+ defer h.close()
+
+ h.putMulti(kNumLevels, "A", "Z")
+
+ // Suppose there is:
+ // small amount of data with prefix A
+ // large amount of data with prefix B
+ // small amount of data with prefix C
+ // and that recent updates have made small changes to all three prefixes.
+ // Check that we do not do a compaction that merges all of B in one shot.
+ h.put("A", "va")
+ value := strings.Repeat("x", 1000)
+ for i := 0; i < 100000; i++ {
+ h.put(fmt.Sprintf("B%010d", i), value)
+ }
+ h.put("C", "vc")
+ h.compactMem()
+ h.compactRangeAt(0, "", "")
+ h.waitCompaction()
+
+ // Make sparse update
+ h.put("A", "va2")
+ h.put("B100", "bvalue2")
+ h.put("C", "vc2")
+ h.compactMem()
+
+ h.maxNextLevelOverlappingBytes(20 * 1048576)
+ h.compactRangeAt(0, "", "")
+ h.waitCompaction()
+ h.maxNextLevelOverlappingBytes(20 * 1048576)
+ h.compactRangeAt(1, "", "")
+ h.waitCompaction()
+ h.maxNextLevelOverlappingBytes(20 * 1048576)
+}
+
+func TestDb_SizeOf(t *testing.T) {
+ h := newDbHarnessWopt(t, &opt.Options{
+ Compression: opt.NoCompression,
+ WriteBuffer: 10000000,
+ })
+ defer h.close()
+
+ h.sizeAssert("", "xyz", 0, 0)
+ h.reopenDB()
+ h.sizeAssert("", "xyz", 0, 0)
+
+ // Write 8MB (80 values, each 100K)
+ n := 80
+ s1 := 100000
+ s2 := 105000
+
+ for i := 0; i < n; i++ {
+ h.put(numKey(i), strings.Repeat(fmt.Sprintf("v%09d", i), s1/10))
+ }
+
+ // 0 because SizeOf() does not account for memtable space
+ h.sizeAssert("", numKey(50), 0, 0)
+
+ for r := 0; r < 3; r++ {
+ h.reopenDB()
+
+ for cs := 0; cs < n; cs += 10 {
+ for i := 0; i < n; i += 10 {
+ h.sizeAssert("", numKey(i), uint64(s1*i), uint64(s2*i))
+ h.sizeAssert("", numKey(i)+".suffix", uint64(s1*(i+1)), uint64(s2*(i+1)))
+ h.sizeAssert(numKey(i), numKey(i+10), uint64(s1*10), uint64(s2*10))
+ }
+
+ h.sizeAssert("", numKey(50), uint64(s1*50), uint64(s2*50))
+ h.sizeAssert("", numKey(50)+".suffix", uint64(s1*50), uint64(s2*50))
+
+ h.compactRangeAt(0, numKey(cs), numKey(cs+9))
+ }
+
+ v := h.db.s.version()
+ if v.tLen(0) != 0 {
+ t.Errorf("level-0 tables was not zero, got %d", v.tLen(0))
+ }
+ if v.tLen(1) == 0 {
+ t.Error("level-1 tables was zero")
+ }
+ v.release()
+ }
+}
+
+func TestDb_SizeOf_MixOfSmallAndLarge(t *testing.T) {
+ h := newDbHarnessWopt(t, &opt.Options{Compression: opt.NoCompression})
+ defer h.close()
+
+ sizes := []uint64{
+ 10000,
+ 10000,
+ 100000,
+ 10000,
+ 100000,
+ 10000,
+ 300000,
+ 10000,
+ }
+
+ for i, n := range sizes {
+ h.put(numKey(i), strings.Repeat(fmt.Sprintf("v%09d", i), int(n)/10))
+ }
+
+ for r := 0; r < 3; r++ {
+ h.reopenDB()
+
+ var x uint64
+ for i, n := range sizes {
+ y := x
+ if i > 0 {
+ y += 1000
+ }
+ h.sizeAssert("", numKey(i), x, y)
+ x += n
+ }
+
+ h.sizeAssert(numKey(3), numKey(5), 110000, 111000)
+
+ h.compactRangeAt(0, "", "")
+ }
+}
+
+func TestDb_Snapshot(t *testing.T) {
+ trun(t, func(h *dbHarness) {
+ h.put("foo", "v1")
+ s1 := h.getSnapshot()
+ h.put("foo", "v2")
+ s2 := h.getSnapshot()
+ h.put("foo", "v3")
+ s3 := h.getSnapshot()
+ h.put("foo", "v4")
+
+ h.getValr(s1, "foo", "v1")
+ h.getValr(s2, "foo", "v2")
+ h.getValr(s3, "foo", "v3")
+ h.getVal("foo", "v4")
+
+ s3.Release()
+ h.getValr(s1, "foo", "v1")
+ h.getValr(s2, "foo", "v2")
+ h.getVal("foo", "v4")
+
+ s1.Release()
+ h.getValr(s2, "foo", "v2")
+ h.getVal("foo", "v4")
+
+ s2.Release()
+ h.getVal("foo", "v4")
+ })
+}
+
+func TestDb_HiddenValuesAreRemoved(t *testing.T) {
+ trun(t, func(h *dbHarness) {
+ s := h.db.s
+
+ h.put("foo", "v1")
+ h.compactMem()
+ m := kMaxMemCompactLevel
+ v := s.version()
+ num := v.tLen(m)
+ v.release()
+ if num != 1 {
+ t.Errorf("invalid level-%d len, want=1 got=%d", m, num)
+ }
+
+ // Place a table at level last-1 to prevent merging with preceding mutation
+ h.put("a", "begin")
+ h.put("z", "end")
+ h.compactMem()
+ v = s.version()
+ if v.tLen(m) != 1 {
+ t.Errorf("invalid level-%d len, want=1 got=%d", m, v.tLen(m))
+ }
+ if v.tLen(m-1) != 1 {
+ t.Errorf("invalid level-%d len, want=1 got=%d", m-1, v.tLen(m-1))
+ }
+ v.release()
+
+ h.delete("foo")
+ h.put("foo", "v2")
+ h.allEntriesFor("foo", "[ v2, DEL, v1 ]")
+ h.compactMem()
+ h.allEntriesFor("foo", "[ v2, DEL, v1 ]")
+ h.compactRangeAt(m-2, "", "z")
+ // DEL eliminated, but v1 remains because we aren't compacting that level
+ // (DEL can be eliminated because v2 hides v1).
+ h.allEntriesFor("foo", "[ v2, v1 ]")
+ h.compactRangeAt(m-1, "", "")
+ // Merging last-1 w/ last, so we are the base level for "foo", so
+ // DEL is removed. (as is v1).
+ h.allEntriesFor("foo", "[ v2 ]")
+ })
+}
+
+func TestDb_DeletionMarkers2(t *testing.T) {
+ h := newDbHarness(t)
+ defer h.close()
+ s := h.db.s
+
+ h.put("foo", "v1")
+ h.compactMem()
+ m := kMaxMemCompactLevel
+ v := s.version()
+ num := v.tLen(m)
+ v.release()
+ if num != 1 {
+ t.Errorf("invalid level-%d len, want=1 got=%d", m, num)
+ }
+
+ // Place a table at level last-1 to prevent merging with preceding mutation
+ h.put("a", "begin")
+ h.put("z", "end")
+ h.compactMem()
+ v = s.version()
+ if v.tLen(m) != 1 {
+ t.Errorf("invalid level-%d len, want=1 got=%d", m, v.tLen(m))
+ }
+ if v.tLen(m-1) != 1 {
+ t.Errorf("invalid level-%d len, want=1 got=%d", m-1, v.tLen(m-1))
+ }
+ v.release()
+
+ h.delete("foo")
+ h.allEntriesFor("foo", "[ DEL, v1 ]")
+ h.compactMem() // Moves to level last-2
+ h.allEntriesFor("foo", "[ DEL, v1 ]")
+ h.compactRangeAt(m-2, "", "")
+ // DEL kept: "last" file overlaps
+ h.allEntriesFor("foo", "[ DEL, v1 ]")
+ h.compactRangeAt(m-1, "", "")
+ // Merging last-1 w/ last, so we are the base level for "foo", so
+ // DEL is removed. (as is v1).
+ h.allEntriesFor("foo", "[ ]")
+}
+
+func TestDb_CompactionTableOpenError(t *testing.T) {
+ h := newDbHarnessWopt(t, &opt.Options{MaxOpenFiles: 0})
+ defer h.close()
+
+ im := 10
+ jm := 10
+ for r := 0; r < 2; r++ {
+ for i := 0; i < im; i++ {
+ for j := 0; j < jm; j++ {
+ h.put(fmt.Sprintf("k%d,%d", i, j), fmt.Sprintf("v%d,%d", i, j))
+ }
+ h.compactMem()
+ }
+ }
+
+ if n := h.totalTables(); n != im*2 {
+ t.Errorf("total tables is %d, want %d", n, im)
+ }
+
+ h.stor.SetOpenErr(storage.TypeTable)
+ go h.db.CompactRange(util.Range{})
+ if err := h.db.compSendIdle(h.db.tcompCmdC); err != nil {
+ t.Log("compaction error: ", err)
+ }
+ h.closeDB0()
+ h.openDB()
+ h.stor.SetOpenErr(0)
+
+ for i := 0; i < im; i++ {
+ for j := 0; j < jm; j++ {
+ h.getVal(fmt.Sprintf("k%d,%d", i, j), fmt.Sprintf("v%d,%d", i, j))
+ }
+ }
+}
+
+func TestDb_OverlapInLevel0(t *testing.T) {
+ trun(t, func(h *dbHarness) {
+ if kMaxMemCompactLevel != 2 {
+ t.Fatal("fix test to reflect the config")
+ }
+
+ // Fill levels 1 and 2 to disable the pushing of new memtables to levels > 0.
+ h.put("100", "v100")
+ h.put("999", "v999")
+ h.compactMem()
+ h.delete("100")
+ h.delete("999")
+ h.compactMem()
+ h.tablesPerLevel("0,1,1")
+
+ // Make files spanning the following ranges in level-0:
+ // files[0] 200 .. 900
+ // files[1] 300 .. 500
+ // Note that files are sorted by min key.
+ h.put("300", "v300")
+ h.put("500", "v500")
+ h.compactMem()
+ h.put("200", "v200")
+ h.put("600", "v600")
+ h.put("900", "v900")
+ h.compactMem()
+ h.tablesPerLevel("2,1,1")
+
+ // Compact away the placeholder files we created initially
+ h.compactRangeAt(1, "", "")
+ h.compactRangeAt(2, "", "")
+ h.tablesPerLevel("2")
+
+ // Do a memtable compaction. Before bug-fix, the compaction would
+ // not detect the overlap with level-0 files and would incorrectly place
+ // the deletion in a deeper level.
+ h.delete("600")
+ h.compactMem()
+ h.tablesPerLevel("3")
+ h.get("600", false)
+ })
+}
+
+func TestDb_L0_CompactionBug_Issue44_a(t *testing.T) {
+ h := newDbHarness(t)
+ defer h.close()
+
+ h.reopenDB()
+ h.put("b", "v")
+ h.reopenDB()
+ h.delete("b")
+ h.delete("a")
+ h.reopenDB()
+ h.delete("a")
+ h.reopenDB()
+ h.put("a", "v")
+ h.reopenDB()
+ h.reopenDB()
+ h.getKeyVal("(a->v)")
+ h.waitCompaction()
+ h.getKeyVal("(a->v)")
+}
+
+func TestDb_L0_CompactionBug_Issue44_b(t *testing.T) {
+ h := newDbHarness(t)
+ defer h.close()
+
+ h.reopenDB()
+ h.put("", "")
+ h.reopenDB()
+ h.delete("e")
+ h.put("", "")
+ h.reopenDB()
+ h.put("c", "cv")
+ h.reopenDB()
+ h.put("", "")
+ h.reopenDB()
+ h.put("", "")
+ h.waitCompaction()
+ h.reopenDB()
+ h.put("d", "dv")
+ h.reopenDB()
+ h.put("", "")
+ h.reopenDB()
+ h.delete("d")
+ h.delete("b")
+ h.reopenDB()
+ h.getKeyVal("(->)(c->cv)")
+ h.waitCompaction()
+ h.getKeyVal("(->)(c->cv)")
+}
+
+func TestDb_SingleEntryMemCompaction(t *testing.T) {
+ trun(t, func(h *dbHarness) {
+ for i := 0; i < 10; i++ {
+ h.put("big", strings.Repeat("v", opt.DefaultWriteBuffer))
+ h.compactMem()
+ h.put("key", strings.Repeat("v", opt.DefaultBlockSize))
+ h.compactMem()
+ h.put("k", "v")
+ h.compactMem()
+ h.put("", "")
+ h.compactMem()
+ h.put("verybig", strings.Repeat("v", opt.DefaultWriteBuffer*2))
+ h.compactMem()
+ }
+ })
+}
+
+func TestDb_ManifestWriteError(t *testing.T) {
+ for i := 0; i < 2; i++ {
+ func() {
+ h := newDbHarness(t)
+ defer h.close()
+
+ h.put("foo", "bar")
+ h.getVal("foo", "bar")
+
+ // Mem compaction (will succeed)
+ h.compactMem()
+ h.getVal("foo", "bar")
+ v := h.db.s.version()
+ if n := v.tLen(kMaxMemCompactLevel); n != 1 {
+ t.Errorf("invalid total tables, want=1 got=%d", n)
+ }
+ v.release()
+
+ if i == 0 {
+ h.stor.SetWriteErr(storage.TypeManifest)
+ } else {
+ h.stor.SetSyncErr(storage.TypeManifest)
+ }
+
+ // Merging compaction (will fail)
+ h.compactRangeAtErr(kMaxMemCompactLevel, "", "", true)
+
+ h.db.Close()
+ h.stor.SetWriteErr(0)
+ h.stor.SetSyncErr(0)
+
+ // Should not lose data
+ h.openDB()
+ h.getVal("foo", "bar")
+ }()
+ }
+}
+
+func assertErr(t *testing.T, err error, wanterr bool) {
+ if err != nil {
+ if wanterr {
+ t.Log("AssertErr: got error (expected): ", err)
+ } else {
+ t.Error("AssertErr: got error: ", err)
+ }
+ } else if wanterr {
+ t.Error("AssertErr: expect error")
+ }
+}
+
+func TestDb_ClosedIsClosed(t *testing.T) {
+ h := newDbHarness(t)
+ db := h.db
+
+ var iter, iter2 iterator.Iterator
+ var snap *Snapshot
+ func() {
+ defer h.close()
+
+ h.put("k", "v")
+ h.getVal("k", "v")
+
+ iter = db.NewIterator(nil, h.ro)
+ iter.Seek([]byte("k"))
+ testKeyVal(t, iter, "k->v")
+
+ var err error
+ snap, err = db.GetSnapshot()
+ if err != nil {
+ t.Fatal("GetSnapshot: got error: ", err)
+ }
+
+ h.getValr(snap, "k", "v")
+
+ iter2 = snap.NewIterator(nil, h.ro)
+ iter2.Seek([]byte("k"))
+ testKeyVal(t, iter2, "k->v")
+
+ h.put("foo", "v2")
+ h.delete("foo")
+
+ // closing DB
+ iter.Release()
+ iter2.Release()
+ }()
+
+ assertErr(t, db.Put([]byte("x"), []byte("y"), h.wo), true)
+ _, err := db.Get([]byte("k"), h.ro)
+ assertErr(t, err, true)
+
+ if iter.Valid() {
+ t.Errorf("iter.Valid should false")
+ }
+ assertErr(t, iter.Error(), false)
+ testKeyVal(t, iter, "->")
+ if iter.Seek([]byte("k")) {
+ t.Errorf("iter.Seek should false")
+ }
+ assertErr(t, iter.Error(), true)
+
+ assertErr(t, iter2.Error(), false)
+
+ _, err = snap.Get([]byte("k"), h.ro)
+ assertErr(t, err, true)
+
+ _, err = db.GetSnapshot()
+ assertErr(t, err, true)
+
+ iter3 := db.NewIterator(nil, h.ro)
+ assertErr(t, iter3.Error(), true)
+
+ iter3 = snap.NewIterator(nil, h.ro)
+ assertErr(t, iter3.Error(), true)
+
+ assertErr(t, db.Delete([]byte("k"), h.wo), true)
+
+ _, err = db.GetProperty("leveldb.stats")
+ assertErr(t, err, true)
+
+ _, err = db.SizeOf([]util.Range{{[]byte("a"), []byte("z")}})
+ assertErr(t, err, true)
+
+ assertErr(t, db.CompactRange(util.Range{}), true)
+
+ assertErr(t, db.Close(), true)
+}
+
+type numberComparer struct{}
+
+func (numberComparer) num(x []byte) (n int) {
+ fmt.Sscan(string(x[1:len(x)-1]), &n)
+ return
+}
+
+func (numberComparer) Name() string {
+ return "test.NumberComparer"
+}
+
+func (p numberComparer) Compare(a, b []byte) int {
+ return p.num(a) - p.num(b)
+}
+
+func (numberComparer) Separator(dst, a, b []byte) []byte { return nil }
+func (numberComparer) Successor(dst, b []byte) []byte { return nil }
+
+func TestDb_CustomComparer(t *testing.T) {
+ h := newDbHarnessWopt(t, &opt.Options{
+ Comparer: numberComparer{},
+ WriteBuffer: 1000,
+ })
+ defer h.close()
+
+ h.put("[10]", "ten")
+ h.put("[0x14]", "twenty")
+ for i := 0; i < 2; i++ {
+ h.getVal("[10]", "ten")
+ h.getVal("[0xa]", "ten")
+ h.getVal("[20]", "twenty")
+ h.getVal("[0x14]", "twenty")
+ h.get("[15]", false)
+ h.get("[0xf]", false)
+ h.compactMem()
+ h.compactRange("[0]", "[9999]")
+ }
+
+ for n := 0; n < 2; n++ {
+ for i := 0; i < 100; i++ {
+ v := fmt.Sprintf("[%d]", i*10)
+ h.put(v, v)
+ }
+ h.compactMem()
+ h.compactRange("[0]", "[1000000]")
+ }
+}
+
+func TestDb_ManualCompaction(t *testing.T) {
+ h := newDbHarness(t)
+ defer h.close()
+
+ if kMaxMemCompactLevel != 2 {
+ t.Fatal("fix test to reflect the config")
+ }
+
+ h.putMulti(3, "p", "q")
+ h.tablesPerLevel("1,1,1")
+
+ // Compaction range falls before files
+ h.compactRange("", "c")
+ h.tablesPerLevel("1,1,1")
+
+ // Compaction range falls after files
+ h.compactRange("r", "z")
+ h.tablesPerLevel("1,1,1")
+
+ // Compaction range overlaps files
+ h.compactRange("p1", "p9")
+ h.tablesPerLevel("0,0,1")
+
+ // Populate a different range
+ h.putMulti(3, "c", "e")
+ h.tablesPerLevel("1,1,2")
+
+ // Compact just the new range
+ h.compactRange("b", "f")
+ h.tablesPerLevel("0,0,2")
+
+ // Compact all
+ h.putMulti(1, "a", "z")
+ h.tablesPerLevel("0,1,2")
+ h.compactRange("", "")
+ h.tablesPerLevel("0,0,1")
+}
+
+func TestDb_BloomFilter(t *testing.T) {
+ h := newDbHarnessWopt(t, &opt.Options{
+ BlockCache: opt.NoCache,
+ Filter: filter.NewBloomFilter(10),
+ })
+ defer h.close()
+
+ key := func(i int) string {
+ return fmt.Sprintf("key%06d", i)
+ }
+
+ n := 10000
+
+ // Populate multiple layers
+ for i := 0; i < n; i++ {
+ h.put(key(i), key(i))
+ }
+ h.compactMem()
+ h.compactRange("a", "z")
+ for i := 0; i < n; i += 100 {
+ h.put(key(i), key(i))
+ }
+ h.compactMem()
+
+ // Prevent auto compactions triggered by seeks
+ h.stor.DelaySync(storage.TypeTable)
+
+ // Lookup present keys. Should rarely read from small sstable.
+ h.stor.SetReadCounter(storage.TypeTable)
+ for i := 0; i < n; i++ {
+ h.getVal(key(i), key(i))
+ }
+ cnt := int(h.stor.ReadCounter())
+ t.Logf("lookup of %d present keys yield %d sstable I/O reads", n, cnt)
+
+ if min, max := n, n+2*n/100; cnt < min || cnt > max {
+ t.Errorf("num of sstable I/O reads of present keys not in range of %d - %d, got %d", min, max, cnt)
+ }
+
+ // Lookup missing keys. Should rarely read from either sstable.
+ h.stor.ResetReadCounter()
+ for i := 0; i < n; i++ {
+ h.get(key(i)+".missing", false)
+ }
+ cnt = int(h.stor.ReadCounter())
+ t.Logf("lookup of %d missing keys yield %d sstable I/O reads", n, cnt)
+ if max := 3 * n / 100; cnt > max {
+ t.Errorf("num of sstable I/O reads of missing keys was more than %d, got %d", max, cnt)
+ }
+
+ h.stor.ReleaseSync(storage.TypeTable)
+}
+
+func TestDb_Concurrent(t *testing.T) {
+ const n, secs, maxkey = 4, 2, 1000
+
+ runtime.GOMAXPROCS(n)
+ trun(t, func(h *dbHarness) {
+ var closeWg sync.WaitGroup
+ var stop uint32
+ var cnt [n]uint32
+
+ for i := 0; i < n; i++ {
+ closeWg.Add(1)
+ go func(i int) {
+ var put, get, found uint
+ defer func() {
+ t.Logf("goroutine %d stopped after %d ops, put=%d get=%d found=%d missing=%d",
+ i, cnt[i], put, get, found, get-found)
+ closeWg.Done()
+ }()
+
+ rnd := rand.New(rand.NewSource(int64(1000 + i)))
+ for atomic.LoadUint32(&stop) == 0 {
+ x := cnt[i]
+
+ k := rnd.Intn(maxkey)
+ kstr := fmt.Sprintf("%016d", k)
+
+ if (rnd.Int() % 2) > 0 {
+ put++
+ h.put(kstr, fmt.Sprintf("%d.%d.%-1000d", k, i, x))
+ } else {
+ get++
+ v, err := h.db.Get([]byte(kstr), h.ro)
+ if err == nil {
+ found++
+ rk, ri, rx := 0, -1, uint32(0)
+ fmt.Sscanf(string(v), "%d.%d.%d", &rk, &ri, &rx)
+ if rk != k {
+ t.Errorf("invalid key want=%d got=%d", k, rk)
+ }
+ if ri < 0 || ri >= n {
+ t.Error("invalid goroutine number: ", ri)
+ } else {
+ tx := atomic.LoadUint32(&(cnt[ri]))
+ if rx > tx {
+ t.Errorf("invalid seq number, %d > %d ", rx, tx)
+ }
+ }
+ } else if err != ErrNotFound {
+ t.Error("Get: got error: ", err)
+ return
+ }
+ }
+ atomic.AddUint32(&cnt[i], 1)
+ }
+ }(i)
+ }
+
+ time.Sleep(secs * time.Second)
+ atomic.StoreUint32(&stop, 1)
+ closeWg.Wait()
+ })
+
+ runtime.GOMAXPROCS(1)
+}
+
+func TestDb_Concurrent2(t *testing.T) {
+ const n, n2 = 4, 4000
+
+ runtime.GOMAXPROCS(n*2 + 2)
+ truno(t, &opt.Options{WriteBuffer: 30}, func(h *dbHarness) {
+ var closeWg sync.WaitGroup
+ var stop uint32
+
+ for i := 0; i < n; i++ {
+ closeWg.Add(1)
+ go func(i int) {
+ for k := 0; atomic.LoadUint32(&stop) == 0; k++ {
+ h.put(fmt.Sprintf("k%d", k), fmt.Sprintf("%d.%d.", k, i)+strings.Repeat("x", 10))
+ }
+ closeWg.Done()
+ }(i)
+ }
+
+ for i := 0; i < n; i++ {
+ closeWg.Add(1)
+ go func(i int) {
+ for k := 1000000; k < 0 || atomic.LoadUint32(&stop) == 0; k-- {
+ h.put(fmt.Sprintf("k%d", k), fmt.Sprintf("%d.%d.", k, i)+strings.Repeat("x", 10))
+ }
+ closeWg.Done()
+ }(i)
+ }
+
+ cmp := comparer.DefaultComparer
+ for i := 0; i < n2; i++ {
+ closeWg.Add(1)
+ go func(i int) {
+ it := h.db.NewIterator(nil, nil)
+ var pk []byte
+ for it.Next() {
+ kk := it.Key()
+ if cmp.Compare(kk, pk) <= 0 {
+ t.Errorf("iter %d: %q is successor of %q", i, pk, kk)
+ }
+ pk = append(pk[:0], kk...)
+ var k, vk, vi int
+ if n, err := fmt.Sscanf(string(it.Key()), "k%d", &k); err != nil {
+ t.Errorf("iter %d: Scanf error on key %q: %v", i, it.Key(), err)
+ } else if n < 1 {
+ t.Errorf("iter %d: Cannot parse key %q", i, it.Key())
+ }
+ if n, err := fmt.Sscanf(string(it.Value()), "%d.%d", &vk, &vi); err != nil {
+ t.Errorf("iter %d: Scanf error on value %q: %v", i, it.Value(), err)
+ } else if n < 2 {
+ t.Errorf("iter %d: Cannot parse value %q", i, it.Value())
+ }
+
+ if vk != k {
+ t.Errorf("iter %d: invalid value i=%d, want=%d got=%d", i, vi, k, vk)
+ }
+ }
+ if err := it.Error(); err != nil {
+ t.Errorf("iter %d: Got error: %v", i, err)
+ }
+ it.Release()
+ closeWg.Done()
+ }(i)
+ }
+
+ atomic.StoreUint32(&stop, 1)
+ closeWg.Wait()
+ })
+
+ runtime.GOMAXPROCS(1)
+}
+
+func TestDb_CreateReopenDbOnFile(t *testing.T) {
+ dbpath := filepath.Join(os.TempDir(), fmt.Sprintf("goleveldbtestCreateReopenDbOnFile-%d", os.Getuid()))
+ if err := os.RemoveAll(dbpath); err != nil {
+ t.Fatal("cannot remove old db: ", err)
+ }
+ defer os.RemoveAll(dbpath)
+
+ for i := 0; i < 3; i++ {
+ stor, err := storage.OpenFile(dbpath)
+ if err != nil {
+ t.Fatalf("(%d) cannot open storage: %s", i, err)
+ }
+ db, err := Open(stor, nil)
+ if err != nil {
+ t.Fatalf("(%d) cannot open db: %s", i, err)
+ }
+ if err := db.Put([]byte("foo"), []byte("bar"), nil); err != nil {
+ t.Fatalf("(%d) cannot write to db: %s", i, err)
+ }
+ if err := db.Close(); err != nil {
+ t.Fatalf("(%d) cannot close db: %s", i, err)
+ }
+ if err := stor.Close(); err != nil {
+ t.Fatalf("(%d) cannot close storage: %s", i, err)
+ }
+ }
+}
+
+func TestDb_CreateReopenDbOnFile2(t *testing.T) {
+ dbpath := filepath.Join(os.TempDir(), fmt.Sprintf("goleveldbtestCreateReopenDbOnFile2-%d", os.Getuid()))
+ if err := os.RemoveAll(dbpath); err != nil {
+ t.Fatal("cannot remove old db: ", err)
+ }
+ defer os.RemoveAll(dbpath)
+
+ for i := 0; i < 3; i++ {
+ db, err := OpenFile(dbpath, nil)
+ if err != nil {
+ t.Fatalf("(%d) cannot open db: %s", i, err)
+ }
+ if err := db.Put([]byte("foo"), []byte("bar"), nil); err != nil {
+ t.Fatalf("(%d) cannot write to db: %s", i, err)
+ }
+ if err := db.Close(); err != nil {
+ t.Fatalf("(%d) cannot close db: %s", i, err)
+ }
+ }
+}
+
+func TestDb_DeletionMarkersOnMemdb(t *testing.T) {
+ h := newDbHarness(t)
+ defer h.close()
+
+ h.put("foo", "v1")
+ h.compactMem()
+ h.delete("foo")
+ h.get("foo", false)
+ h.getKeyVal("")
+}
+
+func TestDb_LeveldbIssue178(t *testing.T) {
+ nKeys := (kMaxTableSize / 30) * 5
+ key1 := func(i int) string {
+ return fmt.Sprintf("my_key_%d", i)
+ }
+ key2 := func(i int) string {
+ return fmt.Sprintf("my_key_%d_xxx", i)
+ }
+
+ // Disable compression since it affects the creation of layers and the
+ // code below is trying to test against a very specific scenario.
+ h := newDbHarnessWopt(t, &opt.Options{Compression: opt.NoCompression})
+ defer h.close()
+
+ // Create first key range.
+ batch := new(Batch)
+ for i := 0; i < nKeys; i++ {
+ batch.Put([]byte(key1(i)), []byte("value for range 1 key"))
+ }
+ h.write(batch)
+
+ // Create second key range.
+ batch.Reset()
+ for i := 0; i < nKeys; i++ {
+ batch.Put([]byte(key2(i)), []byte("value for range 2 key"))
+ }
+ h.write(batch)
+
+ // Delete second key range.
+ batch.Reset()
+ for i := 0; i < nKeys; i++ {
+ batch.Delete([]byte(key2(i)))
+ }
+ h.write(batch)
+ h.waitMemCompaction()
+
+ // Run manual compaction.
+ h.compactRange(key1(0), key1(nKeys-1))
+
+ // Checking the keys.
+ h.assertNumKeys(nKeys)
+}
+
+func TestDb_LeveldbIssue200(t *testing.T) {
+ h := newDbHarness(t)
+ defer h.close()
+
+ h.put("1", "b")
+ h.put("2", "c")
+ h.put("3", "d")
+ h.put("4", "e")
+ h.put("5", "f")
+
+ iter := h.db.NewIterator(nil, h.ro)
+
+ // Add an element that should not be reflected in the iterator.
+ h.put("25", "cd")
+
+ iter.Seek([]byte("5"))
+ assertBytes(t, []byte("5"), iter.Key())
+ iter.Prev()
+ assertBytes(t, []byte("4"), iter.Key())
+ iter.Prev()
+ assertBytes(t, []byte("3"), iter.Key())
+ iter.Next()
+ assertBytes(t, []byte("4"), iter.Key())
+ iter.Next()
+ assertBytes(t, []byte("5"), iter.Key())
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/db_util.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/db_util.go
new file mode 100644
index 000000000..2db007e27
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/db_util.go
@@ -0,0 +1,95 @@
+// Copyright (c) 2012, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package leveldb
+
+import (
+ "errors"
+
+ "github.com/syndtr/goleveldb/leveldb/iterator"
+ "github.com/syndtr/goleveldb/leveldb/opt"
+ "github.com/syndtr/goleveldb/leveldb/storage"
+ "github.com/syndtr/goleveldb/leveldb/util"
+)
+
+// Reader is the interface that wraps basic Get and NewIterator methods.
+// This interface implemented by both DB and Snapshot.
+type Reader interface {
+ Get(key []byte, ro *opt.ReadOptions) (value []byte, err error)
+ NewIterator(slice *util.Range, ro *opt.ReadOptions) iterator.Iterator
+}
+
+type Sizes []uint64
+
+// Sum returns sum of the sizes.
+func (p Sizes) Sum() (n uint64) {
+ for _, s := range p {
+ n += s
+ }
+ return n
+}
+
+// Check and clean files.
+func (d *DB) checkAndCleanFiles() error {
+ s := d.s
+
+ v := s.version_NB()
+ tables := make(map[uint64]bool)
+ for _, tt := range v.tables {
+ for _, t := range tt {
+ tables[t.file.Num()] = false
+ }
+ }
+
+ ff, err := s.getFiles(storage.TypeAll)
+ if err != nil {
+ return err
+ }
+
+ var nTables int
+ var rem []storage.File
+ for _, f := range ff {
+ keep := true
+ switch f.Type() {
+ case storage.TypeManifest:
+ keep = f.Num() >= s.manifestFile.Num()
+ case storage.TypeJournal:
+ if d.frozenJournalFile != nil {
+ keep = f.Num() >= d.frozenJournalFile.Num()
+ } else {
+ keep = f.Num() >= d.journalFile.Num()
+ }
+ case storage.TypeTable:
+ _, keep = tables[f.Num()]
+ if keep {
+ tables[f.Num()] = true
+ nTables++
+ }
+ }
+
+ if !keep {
+ rem = append(rem, f)
+ }
+ }
+
+ if nTables != len(tables) {
+ for num, present := range tables {
+ if !present {
+ s.logf("db@janitor table missing @%d", num)
+ }
+ }
+ return ErrCorrupted{Type: MissingFiles, Err: errors.New("leveldb: table files missing")}
+ }
+
+ s.logf("db@janitor F·%d G·%d", len(ff), len(rem))
+ for _, f := range rem {
+ s.logf("db@janitor removing %s-%d", f.Type(), f.Num())
+ if err := f.Remove(); err != nil {
+ return err
+ }
+ }
+ return nil
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/db_write.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/db_write.go
new file mode 100644
index 000000000..4660e840c
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/db_write.go
@@ -0,0 +1,279 @@
+// Copyright (c) 2012, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package leveldb
+
+import (
+ "time"
+
+ "github.com/syndtr/goleveldb/leveldb/memdb"
+ "github.com/syndtr/goleveldb/leveldb/opt"
+ "github.com/syndtr/goleveldb/leveldb/util"
+)
+
+func (d *DB) writeJournal(b *Batch) error {
+ w, err := d.journal.Next()
+ if err != nil {
+ return err
+ }
+ if _, err := w.Write(b.encode()); err != nil {
+ return err
+ }
+ if err := d.journal.Flush(); err != nil {
+ return err
+ }
+ if b.sync {
+ return d.journalWriter.Sync()
+ }
+ return nil
+}
+
+func (d *DB) jWriter() {
+ defer d.closeW.Done()
+ for {
+ select {
+ case b := <-d.journalC:
+ if b != nil {
+ d.journalAckC <- d.writeJournal(b)
+ }
+ case _, _ = <-d.closeC:
+ return
+ }
+ }
+}
+
+func (d *DB) rotateMem(n int) (mem *memdb.DB, err error) {
+ // Wait for pending memdb compaction.
+ err = d.compSendIdle(d.mcompCmdC)
+ if err != nil {
+ return
+ }
+
+ // Create new memdb and journal.
+ mem, err = d.newMem(n)
+ if err != nil {
+ return
+ }
+
+ // Schedule memdb compaction.
+ d.compTrigger(d.mcompTriggerC)
+ return
+}
+
+func (d *DB) flush(n int) (mem *memdb.DB, nn int, err error) {
+ s := d.s
+
+ delayed := false
+ flush := func() bool {
+ v := s.version()
+ defer v.release()
+ mem = d.getEffectiveMem()
+ nn = mem.Free()
+ switch {
+ case v.tLen(0) >= kL0_SlowdownWritesTrigger && !delayed:
+ delayed = true
+ time.Sleep(time.Millisecond)
+ case nn >= n:
+ return false
+ case v.tLen(0) >= kL0_StopWritesTrigger:
+ delayed = true
+ err = d.compSendIdle(d.tcompCmdC)
+ if err != nil {
+ return false
+ }
+ default:
+ // Allow memdb to grow if it has no entry.
+ if mem.Len() == 0 {
+ nn = n
+ return false
+ }
+ mem, err = d.rotateMem(n)
+ nn = mem.Free()
+ return false
+ }
+ return true
+ }
+ start := time.Now()
+ for flush() {
+ }
+ if delayed {
+ s.logf("db@write delayed T·%v", time.Since(start))
+ }
+ return
+}
+
+// Write apply the given batch to the DB. The batch will be applied
+// sequentially.
+//
+// It is safe to modify the contents of the arguments after Write returns.
+func (d *DB) Write(b *Batch, wo *opt.WriteOptions) (err error) {
+ err = d.ok()
+ if err != nil || b == nil || b.len() == 0 {
+ return
+ }
+
+ b.init(wo.GetSync())
+
+ // The write happen synchronously.
+retry:
+ select {
+ case d.writeC <- b:
+ if <-d.writeMergedC {
+ return <-d.writeAckC
+ }
+ goto retry
+ case d.writeLockC <- struct{}{}:
+ case _, _ = <-d.closeC:
+ return ErrClosed
+ }
+
+ merged := 0
+ defer func() {
+ <-d.writeLockC
+ for i := 0; i < merged; i++ {
+ d.writeAckC <- err
+ }
+ }()
+
+ mem, memFree, err := d.flush(b.size())
+ if err != nil {
+ return
+ }
+
+ // Calculate maximum size of the batch.
+ m := 1 << 20
+ if x := b.size(); x <= 128<<10 {
+ m = x + (128 << 10)
+ }
+ m = minInt(m, memFree)
+
+ // Merge with other batch.
+drain:
+ for b.size() < m && !b.sync {
+ select {
+ case nb := <-d.writeC:
+ if b.size()+nb.size() <= m {
+ b.append(nb)
+ d.writeMergedC <- true
+ merged++
+ } else {
+ d.writeMergedC <- false
+ break drain
+ }
+ default:
+ break drain
+ }
+ }
+
+ // Set batch first seq number relative from last seq.
+ b.seq = d.seq + 1
+
+ // Write journal concurrently if it is large enough.
+ if b.size() >= (128 << 10) {
+ // Push the write batch to the journal writer
+ select {
+ case _, _ = <-d.closeC:
+ err = ErrClosed
+ return
+ case d.journalC <- b:
+ // Write into memdb
+ b.memReplay(mem)
+ }
+ // Wait for journal writer
+ select {
+ case _, _ = <-d.closeC:
+ err = ErrClosed
+ return
+ case err = <-d.journalAckC:
+ if err != nil {
+ // Revert memdb if error detected
+ b.revertMemReplay(mem)
+ return
+ }
+ }
+ } else {
+ err = d.writeJournal(b)
+ if err != nil {
+ return
+ }
+ b.memReplay(mem)
+ }
+
+ // Set last seq number.
+ d.addSeq(uint64(b.len()))
+
+ if b.size() >= memFree {
+ d.rotateMem(0)
+ }
+ return
+}
+
+// Put sets the value for the given key. It overwrites any previous value
+// for that key; a DB is not a multi-map.
+//
+// It is safe to modify the contents of the arguments after Put returns.
+func (d *DB) Put(key, value []byte, wo *opt.WriteOptions) error {
+ b := new(Batch)
+ b.Put(key, value)
+ return d.Write(b, wo)
+}
+
+// Delete deletes the value for the given key. It returns ErrNotFound if
+// the DB does not contain the key.
+//
+// It is safe to modify the contents of the arguments after Delete returns.
+func (d *DB) Delete(key []byte, wo *opt.WriteOptions) error {
+ b := new(Batch)
+ b.Delete(key)
+ return d.Write(b, wo)
+}
+
+func isMemOverlaps(icmp *iComparer, mem *memdb.DB, min, max []byte) bool {
+ iter := mem.NewIterator(nil)
+ defer iter.Release()
+ return (max == nil || (iter.First() && icmp.uCompare(max, iKey(iter.Key()).ukey()) >= 0)) &&
+ (min == nil || (iter.Last() && icmp.uCompare(min, iKey(iter.Key()).ukey()) <= 0))
+}
+
+// CompactRange compacts the underlying DB for the given key range.
+// In particular, deleted and overwritten versions are discarded,
+// and the data is rearranged to reduce the cost of operations
+// needed to access the data. This operation should typically only
+// be invoked by users who understand the underlying implementation.
+//
+// A nil Range.Start is treated as a key before all keys in the DB.
+// And a nil Range.Limit is treated as a key after all keys in the DB.
+// Therefore if both is nil then it will compact entire DB.
+func (d *DB) CompactRange(r util.Range) error {
+ if err := d.ok(); err != nil {
+ return err
+ }
+
+ select {
+ case d.writeLockC <- struct{}{}:
+ case _, _ = <-d.closeC:
+ return ErrClosed
+ }
+
+ // Check for overlaps in memdb.
+ mem := d.getEffectiveMem()
+ if isMemOverlaps(d.s.icmp, mem, r.Start, r.Limit) {
+ // Memdb compaction.
+ if _, err := d.rotateMem(0); err != nil {
+ <-d.writeLockC
+ return err
+ }
+ <-d.writeLockC
+ if err := d.compSendIdle(d.mcompCmdC); err != nil {
+ return err
+ }
+ } else {
+ <-d.writeLockC
+ }
+
+ // Table compaction.
+ return d.compSendRange(d.tcompCmdC, -1, r.Start, r.Limit)
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/doc.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/doc.go
new file mode 100644
index 000000000..ac9ea3d0c
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/doc.go
@@ -0,0 +1,80 @@
+// Copyright (c) 2012, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Package leveldb provides implementation of LevelDB key/value database.
+//
+// Create or open a database:
+//
+// db, err := leveldb.OpenFile("path/to/db", nil)
+// ...
+// defer db.Close()
+// ...
+//
+// Read or modify the database content:
+//
+// // Remember that the contents of the returned slice should not be modified.
+// data, err := db.Get([]byte("key"), nil)
+// ...
+// err = db.Put([]byte("key"), []byte("value"), nil)
+// ...
+// err = db.Delete([]byte("key"), nil)
+// ...
+//
+// Iterate over database content:
+//
+// iter := db.NewIterator(nil, nil)
+// for iter.Next() {
+// // Remember that the contents of the returned slice should not be modified, and
+// // only valid until the next call to Next.
+// key := iter.Key()
+// value := iter.Value()
+// ...
+// }
+// iter.Release()
+// err = iter.Error()
+// ...
+//
+// Seek-then-Iterate:
+//
+// iter := db.NewIterator(nil, nil)
+// for ok := iter.Seek(key); ok; ok = iter.Next() {
+// // Use key/value.
+// ...
+// }
+// iter.Release()
+// err = iter.Error()
+// ...
+//
+// Iterate over subset of database content:
+//
+// iter := db.NewIterator(&util.Range{Start: []byte("foo"), Limit: []byte("xoo")}, nil)
+// for iter.Next() {
+// // Use key/value.
+// ...
+// }
+// iter.Release()
+// err = iter.Error()
+// ...
+//
+// Batch writes:
+//
+// batch := new(leveldb.Batch)
+// batch.Put([]byte("foo"), []byte("value"))
+// batch.Put([]byte("bar"), []byte("another value"))
+// batch.Delete([]byte("baz"))
+// err = db.Write(batch, nil)
+// ...
+//
+// Use bloom filter:
+//
+// o := &opt.Options{
+// Filter: filter.NewBloomFilter(10),
+// }
+// db, err := leveldb.OpenFile("path/to/db", o)
+// ...
+// defer db.Close()
+// ...
+package leveldb
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/error.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/error.go
new file mode 100644
index 000000000..8066bd9a4
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/error.go
@@ -0,0 +1,38 @@
+// Copyright (c) 2014, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package leveldb
+
+import (
+ "errors"
+
+ "github.com/syndtr/goleveldb/leveldb/util"
+)
+
+var (
+ ErrNotFound = util.ErrNotFound
+ ErrSnapshotReleased = errors.New("leveldb: snapshot released")
+ ErrIterReleased = errors.New("leveldb: iterator released")
+ ErrClosed = errors.New("leveldb: closed")
+)
+
+type CorruptionType int
+
+const (
+ CorruptedManifest CorruptionType = iota
+ MissingFiles
+)
+
+// ErrCorrupted is the type that wraps errors that indicate corruption in
+// the database.
+type ErrCorrupted struct {
+ Type CorruptionType
+ Err error
+}
+
+func (e ErrCorrupted) Error() string {
+ return e.Err.Error()
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/external_test.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/external_test.go
new file mode 100644
index 000000000..d7dff04b6
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/external_test.go
@@ -0,0 +1,58 @@
+// Copyright (c) 2014, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package leveldb
+
+import (
+ . "github.com/onsi/ginkgo"
+ . "github.com/onsi/gomega"
+
+ "github.com/syndtr/goleveldb/leveldb/opt"
+ "github.com/syndtr/goleveldb/leveldb/testutil"
+)
+
+var _ = testutil.Defer(func() {
+ Describe("Leveldb external", func() {
+ o := &opt.Options{
+ BlockCache: opt.NoCache,
+ BlockRestartInterval: 5,
+ BlockSize: 50,
+ Compression: opt.NoCompression,
+ MaxOpenFiles: 0,
+ Strict: opt.StrictAll,
+ WriteBuffer: 1000,
+ }
+
+ Describe("write test", func() {
+ It("should do write correctly", func(done Done) {
+ db := newTestingDB(o, nil, nil)
+ t := testutil.DBTesting{
+ DB: db,
+ Deleted: testutil.KeyValue_Generate(nil, 500, 1, 50, 5, 5).Clone(),
+ }
+ testutil.DoDBTesting(&t)
+ db.TestClose()
+ done <- true
+ }, 9.0)
+ })
+
+ Describe("read test", func() {
+ testutil.AllKeyValueTesting(nil, func(kv testutil.KeyValue) testutil.DB {
+ // Building the DB.
+ db := newTestingDB(o, nil, nil)
+ kv.IterateShuffled(nil, func(i int, key, value []byte) {
+ err := db.TestPut(key, value)
+ Expect(err).NotTo(HaveOccurred())
+ })
+ testutil.Defer("teardown", func() {
+ db.TestClose()
+ })
+
+ return db
+ })
+ })
+ })
+})
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/filter.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/filter.go
new file mode 100644
index 000000000..37c1e146b
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/filter.go
@@ -0,0 +1,31 @@
+// Copyright (c) 2012, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package leveldb
+
+import (
+ "github.com/syndtr/goleveldb/leveldb/filter"
+)
+
+type iFilter struct {
+ filter.Filter
+}
+
+func (f iFilter) Contains(filter, key []byte) bool {
+ return f.Filter.Contains(filter, iKey(key).ukey())
+}
+
+func (f iFilter) NewGenerator() filter.FilterGenerator {
+ return iFilterGenerator{f.Filter.NewGenerator()}
+}
+
+type iFilterGenerator struct {
+ filter.FilterGenerator
+}
+
+func (g iFilterGenerator) Add(key []byte) {
+ g.FilterGenerator.Add(iKey(key).ukey())
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/filter/bloom.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/filter/bloom.go
new file mode 100644
index 000000000..bab0e9970
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/filter/bloom.go
@@ -0,0 +1,116 @@
+// Copyright (c) 2012, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package filter
+
+import (
+ "github.com/syndtr/goleveldb/leveldb/util"
+)
+
+func bloomHash(key []byte) uint32 {
+ return util.Hash(key, 0xbc9f1d34)
+}
+
+type bloomFilter int
+
+// The bloom filter serializes its parameters and is backward compatible
+// with respect to them. Therefor, its parameters are not added to its
+// name.
+func (bloomFilter) Name() string {
+ return "leveldb.BuiltinBloomFilter"
+}
+
+func (f bloomFilter) Contains(filter, key []byte) bool {
+ nBytes := len(filter) - 1
+ if nBytes < 1 {
+ return false
+ }
+ nBits := uint32(nBytes * 8)
+
+ // Use the encoded k so that we can read filters generated by
+ // bloom filters created using different parameters.
+ k := filter[nBytes]
+ if k > 30 {
+ // Reserved for potentially new encodings for short bloom filters.
+ // Consider it a match.
+ return true
+ }
+
+ kh := bloomHash(key)
+ delta := (kh >> 17) | (kh << 15) // Rotate right 17 bits
+ for j := uint8(0); j < k; j++ {
+ bitpos := kh % nBits
+ if (uint32(filter[bitpos/8]) & (1 << (bitpos % 8))) == 0 {
+ return false
+ }
+ kh += delta
+ }
+ return true
+}
+
+func (f bloomFilter) NewGenerator() FilterGenerator {
+ // Round down to reduce probing cost a little bit.
+ k := uint8(f * 69 / 100) // 0.69 =~ ln(2)
+ if k < 1 {
+ k = 1
+ } else if k > 30 {
+ k = 30
+ }
+ return &bloomFilterGenerator{
+ n: int(f),
+ k: k,
+ }
+}
+
+type bloomFilterGenerator struct {
+ n int
+ k uint8
+
+ keyHashes []uint32
+}
+
+func (g *bloomFilterGenerator) Add(key []byte) {
+ // Use double-hashing to generate a sequence of hash values.
+ // See analysis in [Kirsch,Mitzenmacher 2006].
+ g.keyHashes = append(g.keyHashes, bloomHash(key))
+}
+
+func (g *bloomFilterGenerator) Generate(b Buffer) {
+ // Compute bloom filter size (in both bits and bytes)
+ nBits := uint32(len(g.keyHashes) * g.n)
+ // For small n, we can see a very high false positive rate. Fix it
+ // by enforcing a minimum bloom filter length.
+ if nBits < 64 {
+ nBits = 64
+ }
+ nBytes := (nBits + 7) / 8
+ nBits = nBytes * 8
+
+ dest := b.Alloc(int(nBytes) + 1)
+ dest[nBytes] = g.k
+ for _, kh := range g.keyHashes {
+ delta := (kh >> 17) | (kh << 15) // Rotate right 17 bits
+ for j := uint8(0); j < g.k; j++ {
+ bitpos := kh % nBits
+ dest[bitpos/8] |= (1 << (bitpos % 8))
+ kh += delta
+ }
+ }
+
+ g.keyHashes = g.keyHashes[:0]
+}
+
+// NewBloomFilter creates a new initialized bloom filter for given
+// bitsPerKey.
+//
+// Since bitsPerKey is persisted individually for each bloom filter
+// serialization, bloom filters are backwards compatible with respect to
+// changing bitsPerKey. This means that no big performance penalty will
+// be experienced when changing the parameter. See documentation for
+// opt.Options.Filter for more information.
+func NewBloomFilter(bitsPerKey int) Filter {
+ return bloomFilter(bitsPerKey)
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/filter/bloom_test.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/filter/bloom_test.go
new file mode 100644
index 000000000..1fb56f071
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/filter/bloom_test.go
@@ -0,0 +1,142 @@
+// Copyright (c) 2012, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package filter
+
+import (
+ "encoding/binary"
+ "github.com/syndtr/goleveldb/leveldb/util"
+ "testing"
+)
+
+type harness struct {
+ t *testing.T
+
+ bloom Filter
+ generator FilterGenerator
+ filter []byte
+}
+
+func newHarness(t *testing.T) *harness {
+ bloom := NewBloomFilter(10)
+ return &harness{
+ t: t,
+ bloom: bloom,
+ generator: bloom.NewGenerator(),
+ }
+}
+
+func (h *harness) add(key []byte) {
+ h.generator.Add(key)
+}
+
+func (h *harness) addNum(key uint32) {
+ var b [4]byte
+ binary.LittleEndian.PutUint32(b[:], key)
+ h.add(b[:])
+}
+
+func (h *harness) build() {
+ b := &util.Buffer{}
+ h.generator.Generate(b)
+ h.filter = b.Bytes()
+}
+
+func (h *harness) reset() {
+ h.filter = nil
+}
+
+func (h *harness) filterLen() int {
+ return len(h.filter)
+}
+
+func (h *harness) assert(key []byte, want, silent bool) bool {
+ got := h.bloom.Contains(h.filter, key)
+ if !silent && got != want {
+ h.t.Errorf("assert on '%v' failed got '%v', want '%v'", key, got, want)
+ }
+ return got
+}
+
+func (h *harness) assertNum(key uint32, want, silent bool) bool {
+ var b [4]byte
+ binary.LittleEndian.PutUint32(b[:], key)
+ return h.assert(b[:], want, silent)
+}
+
+func TestBloomFilter_Empty(t *testing.T) {
+ h := newHarness(t)
+ h.build()
+ h.assert([]byte("hello"), false, false)
+ h.assert([]byte("world"), false, false)
+}
+
+func TestBloomFilter_Small(t *testing.T) {
+ h := newHarness(t)
+ h.add([]byte("hello"))
+ h.add([]byte("world"))
+ h.build()
+ h.assert([]byte("hello"), true, false)
+ h.assert([]byte("world"), true, false)
+ h.assert([]byte("x"), false, false)
+ h.assert([]byte("foo"), false, false)
+}
+
+func nextN(n int) int {
+ switch {
+ case n < 10:
+ n += 1
+ case n < 100:
+ n += 10
+ case n < 1000:
+ n += 100
+ default:
+ n += 1000
+ }
+ return n
+}
+
+func TestBloomFilter_VaryingLengths(t *testing.T) {
+ h := newHarness(t)
+ var mediocre, good int
+ for n := 1; n < 10000; n = nextN(n) {
+ h.reset()
+ for i := 0; i < n; i++ {
+ h.addNum(uint32(i))
+ }
+ h.build()
+
+ got := h.filterLen()
+ want := (n * 10 / 8) + 40
+ if got > want {
+ t.Errorf("filter len test failed, '%d' > '%d'", got, want)
+ }
+
+ for i := 0; i < n; i++ {
+ h.assertNum(uint32(i), true, false)
+ }
+
+ var rate float32
+ for i := 0; i < 10000; i++ {
+ if h.assertNum(uint32(i+1000000000), true, true) {
+ rate++
+ }
+ }
+ rate /= 10000
+ if rate > 0.02 {
+ t.Errorf("false positive rate is more than 2%%, got %v, at len %d", rate, n)
+ }
+ if rate > 0.0125 {
+ mediocre++
+ } else {
+ good++
+ }
+ }
+ t.Logf("false positive rate: %d good, %d mediocre", good, mediocre)
+ if mediocre > good/5 {
+ t.Error("mediocre false positive rate is more than expected")
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/filter/filter.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/filter/filter.go
new file mode 100644
index 000000000..7a925c5a8
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/filter/filter.go
@@ -0,0 +1,60 @@
+// Copyright (c) 2012, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Package filter provides interface and implementation of probabilistic
+// data structure.
+//
+// The filter is resposible for creating small filter from a set of keys.
+// These filter will then used to test whether a key is a member of the set.
+// In many cases, a filter can cut down the number of disk seeks from a
+// handful to a single disk seek per DB.Get call.
+package filter
+
+// Buffer is the interface that wraps basic Alloc, Write and WriteByte methods.
+type Buffer interface {
+ // Alloc allocs n bytes of slice from the buffer. This also advancing
+ // write offset.
+ Alloc(n int) []byte
+
+ // Write appends the contents of p to the buffer.
+ Write(p []byte) (n int, err error)
+
+ // WriteByte appends the byte c to the buffer.
+ WriteByte(c byte) error
+}
+
+// Filter is the filter.
+type Filter interface {
+ // Name returns the name of this policy.
+ //
+ // Note that if the filter encoding changes in an incompatible way,
+ // the name returned by this method must be changed. Otherwise, old
+ // incompatible filters may be passed to methods of this type.
+ Name() string
+
+ // NewGenerator creates a new filter generator.
+ NewGenerator() FilterGenerator
+
+ // Contains returns true if the filter contains the given key.
+ //
+ // The filter are filters generated by the filter generator.
+ Contains(filter, key []byte) bool
+}
+
+// FilterGenerator is the filter generator.
+type FilterGenerator interface {
+ // Add adds a key to the filter generator.
+ //
+ // The key may become invalid after call to this method end, therefor
+ // key must be copied if implementation require keeping key for later
+ // use. The key should not modified directly, doing so may cause
+ // undefined results.
+ Add(key []byte)
+
+ // Generate generates filters based on keys passed so far. After call
+ // to Generate the filter generator maybe resetted, depends on implementation.
+ Generate(b Buffer)
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/iterator/array_iter.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/iterator/array_iter.go
new file mode 100644
index 000000000..9b4b72741
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/iterator/array_iter.go
@@ -0,0 +1,158 @@
+// Copyright (c) 2014, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package iterator
+
+import (
+ "github.com/syndtr/goleveldb/leveldb/util"
+)
+
+// BasicArray is the interface that wraps basic Len and Search method.
+type BasicArray interface {
+ // Len returns length of the array.
+ Len() int
+
+ // Search finds smallest index that point to a key that is greater
+ // than or equal to the given key.
+ Search(key []byte) int
+}
+
+// Array is the interface that wraps BasicArray and basic Index method.
+type Array interface {
+ BasicArray
+
+ // Index returns key/value pair with index of i.
+ Index(i int) (key, value []byte)
+}
+
+// Array is the interface that wraps BasicArray and basic Get method.
+type ArrayIndexer interface {
+ BasicArray
+
+ // Get returns a new data iterator with index of i.
+ Get(i int) Iterator
+}
+
+type basicArrayIterator struct {
+ util.BasicReleaser
+ array BasicArray
+ pos int
+}
+
+func (i *basicArrayIterator) Valid() bool {
+ return i.pos >= 0 && i.pos < i.array.Len()
+}
+
+func (i *basicArrayIterator) First() bool {
+ if i.array.Len() == 0 {
+ i.pos = -1
+ return false
+ }
+ i.pos = 0
+ return true
+}
+
+func (i *basicArrayIterator) Last() bool {
+ n := i.array.Len()
+ if n == 0 {
+ i.pos = 0
+ return false
+ }
+ i.pos = n - 1
+ return true
+}
+
+func (i *basicArrayIterator) Seek(key []byte) bool {
+ n := i.array.Len()
+ if n == 0 {
+ i.pos = 0
+ return false
+ }
+ i.pos = i.array.Search(key)
+ if i.pos >= n {
+ return false
+ }
+ return true
+}
+
+func (i *basicArrayIterator) Next() bool {
+ i.pos++
+ if n := i.array.Len(); i.pos >= n {
+ i.pos = n
+ return false
+ }
+ return true
+}
+
+func (i *basicArrayIterator) Prev() bool {
+ i.pos--
+ if i.pos < 0 {
+ i.pos = -1
+ return false
+ }
+ return true
+}
+
+func (i *basicArrayIterator) Error() error { return nil }
+
+type arrayIterator struct {
+ basicArrayIterator
+ array Array
+ pos int
+ key, value []byte
+}
+
+func (i *arrayIterator) updateKV() {
+ if i.pos == i.basicArrayIterator.pos {
+ return
+ }
+ i.pos = i.basicArrayIterator.pos
+ if i.Valid() {
+ i.key, i.value = i.array.Index(i.pos)
+ } else {
+ i.key = nil
+ i.value = nil
+ }
+}
+
+func (i *arrayIterator) Key() []byte {
+ i.updateKV()
+ return i.key
+}
+
+func (i *arrayIterator) Value() []byte {
+ i.updateKV()
+ return i.value
+}
+
+type arrayIteratorIndexer struct {
+ basicArrayIterator
+ array ArrayIndexer
+}
+
+func (i *arrayIteratorIndexer) Get() Iterator {
+ if i.Valid() {
+ return i.array.Get(i.basicArrayIterator.pos)
+ }
+ return nil
+}
+
+// NewArrayIterator returns an iterator from the given array.
+func NewArrayIterator(array Array) Iterator {
+ return &arrayIterator{
+ basicArrayIterator: basicArrayIterator{array: array, pos: -1},
+ array: array,
+ pos: -1,
+ }
+}
+
+// NewArrayIndexer returns an index iterator from the given array.
+func NewArrayIndexer(array ArrayIndexer) IteratorIndexer {
+ return &arrayIteratorIndexer{
+ basicArrayIterator: basicArrayIterator{array: array, pos: -1},
+ array: array,
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/iterator/array_iter_test.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/iterator/array_iter_test.go
new file mode 100644
index 000000000..1ed6d07cb
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/iterator/array_iter_test.go
@@ -0,0 +1,30 @@
+// Copyright (c) 2014, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package iterator_test
+
+import (
+ . "github.com/onsi/ginkgo"
+
+ . "github.com/syndtr/goleveldb/leveldb/iterator"
+ "github.com/syndtr/goleveldb/leveldb/testutil"
+)
+
+var _ = testutil.Defer(func() {
+ Describe("Array iterator", func() {
+ It("Should iterates and seeks correctly", func() {
+ // Build key/value.
+ kv := testutil.KeyValue_Generate(nil, 70, 1, 5, 3, 3)
+
+ // Test the iterator.
+ t := testutil.IteratorTesting{
+ KeyValue: kv.Clone(),
+ Iter: NewArrayIterator(kv),
+ }
+ testutil.DoIteratorTesting(&t)
+ })
+ })
+})
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/iterator/indexed_iter.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/iterator/indexed_iter.go
new file mode 100644
index 000000000..1e99a2bf6
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/iterator/indexed_iter.go
@@ -0,0 +1,221 @@
+// Copyright (c) 2012, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package iterator
+
+import (
+ "github.com/syndtr/goleveldb/leveldb/util"
+)
+
+// IteratorIndexer is the interface that wraps CommonIterator and basic Get
+// method. IteratorIndexer provides index for indexed iterator.
+type IteratorIndexer interface {
+ CommonIterator
+
+ // Get returns a new data iterator for the current position, or nil if
+ // done.
+ Get() Iterator
+}
+
+type indexedIterator struct {
+ util.BasicReleaser
+ index IteratorIndexer
+ strict bool
+ strictGet bool
+
+ data Iterator
+ err error
+ errf func(err error)
+}
+
+func (i *indexedIterator) setData() {
+ if i.data != nil {
+ i.data.Release()
+ }
+ i.data = i.index.Get()
+ if i.strictGet {
+ if err := i.data.Error(); err != nil {
+ i.err = err
+ }
+ }
+}
+
+func (i *indexedIterator) clearData() {
+ if i.data != nil {
+ i.data.Release()
+ }
+ i.data = nil
+}
+
+func (i *indexedIterator) dataErr() bool {
+ if i.errf != nil {
+ if err := i.data.Error(); err != nil {
+ i.errf(err)
+ }
+ }
+ if i.strict {
+ if err := i.data.Error(); err != nil {
+ i.err = err
+ return true
+ }
+ }
+ return false
+}
+
+func (i *indexedIterator) Valid() bool {
+ return i.data != nil && i.data.Valid()
+}
+
+func (i *indexedIterator) First() bool {
+ if i.err != nil {
+ return false
+ }
+
+ if !i.index.First() {
+ i.clearData()
+ return false
+ }
+ i.setData()
+ return i.Next()
+}
+
+func (i *indexedIterator) Last() bool {
+ if i.err != nil {
+ return false
+ }
+
+ if !i.index.Last() {
+ i.clearData()
+ return false
+ }
+ i.setData()
+ if !i.data.Last() {
+ if i.dataErr() {
+ return false
+ }
+ i.clearData()
+ return i.Prev()
+ }
+ return true
+}
+
+func (i *indexedIterator) Seek(key []byte) bool {
+ if i.err != nil {
+ return false
+ }
+
+ if !i.index.Seek(key) {
+ i.clearData()
+ return false
+ }
+ i.setData()
+ if !i.data.Seek(key) {
+ if i.dataErr() {
+ return false
+ }
+ i.clearData()
+ return i.Next()
+ }
+ return true
+}
+
+func (i *indexedIterator) Next() bool {
+ if i.err != nil {
+ return false
+ }
+
+ switch {
+ case i.data != nil && !i.data.Next():
+ if i.dataErr() {
+ return false
+ }
+ i.clearData()
+ fallthrough
+ case i.data == nil:
+ if !i.index.Next() {
+ return false
+ }
+ i.setData()
+ return i.Next()
+ }
+ return true
+}
+
+func (i *indexedIterator) Prev() bool {
+ if i.err != nil {
+ return false
+ }
+
+ switch {
+ case i.data != nil && !i.data.Prev():
+ if i.dataErr() {
+ return false
+ }
+ i.clearData()
+ fallthrough
+ case i.data == nil:
+ if !i.index.Prev() {
+ return false
+ }
+ i.setData()
+ if !i.data.Last() {
+ if i.dataErr() {
+ return false
+ }
+ i.clearData()
+ return i.Prev()
+ }
+ }
+ return true
+}
+
+func (i *indexedIterator) Key() []byte {
+ if i.data == nil {
+ return nil
+ }
+ return i.data.Key()
+}
+
+func (i *indexedIterator) Value() []byte {
+ if i.data == nil {
+ return nil
+ }
+ return i.data.Value()
+}
+
+func (i *indexedIterator) Release() {
+ i.clearData()
+ i.index.Release()
+ i.BasicReleaser.Release()
+}
+
+func (i *indexedIterator) Error() error {
+ if i.err != nil {
+ return i.err
+ }
+ if err := i.index.Error(); err != nil {
+ return err
+ }
+ return nil
+}
+
+func (i *indexedIterator) SetErrorCallback(f func(err error)) {
+ i.errf = f
+}
+
+// NewIndexedIterator returns an indexed iterator. An index is iterator
+// that returns another iterator, a data iterator. A data iterator is the
+// iterator that contains actual key/value pairs.
+//
+// If strict is true then error yield by data iterator will halt the indexed
+// iterator, on contrary if strict is false then the indexed iterator will
+// ignore those error and move on to the next index. If strictGet is true and
+// index.Get() yield an 'error iterator' then the indexed iterator will be halted.
+// An 'error iterator' is iterator which its Error() method always return non-nil
+// even before any 'seeks method' is called.
+func NewIndexedIterator(index IteratorIndexer, strict, strictGet bool) Iterator {
+ return &indexedIterator{index: index, strict: strict, strictGet: strictGet}
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/iterator/indexed_iter_test.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/iterator/indexed_iter_test.go
new file mode 100644
index 000000000..6a89b3830
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/iterator/indexed_iter_test.go
@@ -0,0 +1,83 @@
+// Copyright (c) 2014, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package iterator_test
+
+import (
+ "sort"
+
+ . "github.com/onsi/ginkgo"
+
+ "github.com/syndtr/goleveldb/leveldb/comparer"
+ . "github.com/syndtr/goleveldb/leveldb/iterator"
+ "github.com/syndtr/goleveldb/leveldb/testutil"
+)
+
+type keyValue struct {
+ key []byte
+ testutil.KeyValue
+}
+
+type keyValueIndex []keyValue
+
+func (x keyValueIndex) Search(key []byte) int {
+ return sort.Search(x.Len(), func(i int) bool {
+ return comparer.DefaultComparer.Compare(x[i].key, key) >= 0
+ })
+}
+
+func (x keyValueIndex) Len() int { return len(x) }
+func (x keyValueIndex) Index(i int) (key, value []byte) { return x[i].key, nil }
+func (x keyValueIndex) Get(i int) Iterator { return NewArrayIterator(x[i]) }
+
+var _ = testutil.Defer(func() {
+ Describe("Indexed iterator", func() {
+ Test := func(n ...int) func() {
+ if len(n) == 0 {
+ rnd := testutil.NewRand()
+ n = make([]int, rnd.Intn(17)+3)
+ for i := range n {
+ n[i] = rnd.Intn(19) + 1
+ }
+ }
+
+ return func() {
+ It("Should iterates and seeks correctly", func(done Done) {
+ // Build key/value.
+ index := make(keyValueIndex, len(n))
+ sum := 0
+ for _, x := range n {
+ sum += x
+ }
+ kv := testutil.KeyValue_Generate(nil, sum, 1, 10, 4, 4)
+ for i, j := 0, 0; i < len(n); i++ {
+ for x := n[i]; x > 0; x-- {
+ key, value := kv.Index(j)
+ index[i].key = key
+ index[i].Put(key, value)
+ j++
+ }
+ }
+
+ // Test the iterator.
+ t := testutil.IteratorTesting{
+ KeyValue: kv.Clone(),
+ Iter: NewIndexedIterator(NewArrayIndexer(index), true, true),
+ }
+ testutil.DoIteratorTesting(&t)
+ done <- true
+ }, 1.5)
+ }
+ }
+
+ Describe("with 100 keys", Test(100))
+ Describe("with 50-50 keys", Test(50, 50))
+ Describe("with 50-1 keys", Test(50, 1))
+ Describe("with 50-1-50 keys", Test(50, 1, 50))
+ Describe("with 1-50 keys", Test(1, 50))
+ Describe("with random N-keys", Test())
+ })
+})
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/iterator/iter.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/iterator/iter.go
new file mode 100644
index 000000000..1b80184e8
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/iterator/iter.go
@@ -0,0 +1,142 @@
+// Copyright (c) 2012, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Package iterator provides interface and implementation to traverse over
+// contents of a database.
+package iterator
+
+import (
+ "errors"
+
+ "github.com/syndtr/goleveldb/leveldb/util"
+)
+
+// IteratorSeeker is the interface that wraps the 'seeks method'.
+type IteratorSeeker interface {
+ // First moves the iterator to the first key/value pair. If the iterator
+ // only contains one key/value pair then First and Last whould moves
+ // to the same key/value pair.
+ // It returns whether such pair exist.
+ First() bool
+
+ // Last moves the iterator to the last key/value pair. If the iterator
+ // only contains one key/value pair then First and Last whould moves
+ // to the same key/value pair.
+ // It returns whether such pair exist.
+ Last() bool
+
+ // Seek moves the iterator to the first key/value pair whose key is greater
+ // than or equal to the given key.
+ // It returns whether such pair exist.
+ //
+ // It is safe to modify the contents of the argument after Seek returns.
+ Seek(key []byte) bool
+
+ // Next moves the iterator to the next key/value pair.
+ // It returns whether the iterator is exhausted.
+ Next() bool
+
+ // Prev moves the iterator to the previous key/value pair.
+ // It returns whether the iterator is exhausted.
+ Prev() bool
+}
+
+// CommonIterator is the interface that wraps common interator methods.
+type CommonIterator interface {
+ IteratorSeeker
+
+ // util.Releaser is the interface that wraps basic Release method.
+ // When called Release will releases any resources associated with the
+ // iterator.
+ util.Releaser
+
+ // util.ReleaseSetter is the interface that wraps the basic SetReleaser
+ // method.
+ util.ReleaseSetter
+
+ // TODO: Remove this when ready.
+ Valid() bool
+
+ // Error returns any accumulated error. Exhausting all the key/value pairs
+ // is not considered to be an error.
+ Error() error
+}
+
+// Iterator iterates over a DB's key/value pairs in key order.
+//
+// When encouter an error any 'seeks method' will return false and will
+// yield no key/value pairs. The error can be queried by calling the Error
+// method. Calling Release is still necessary.
+//
+// An iterator must be released after use, but it is not necessary to read
+// an iterator until exhaustion.
+// Also, an iterator is not necessarily goroutine-safe, but it is safe to use
+// multiple iterators concurrently, with each in a dedicated goroutine.
+type Iterator interface {
+ CommonIterator
+
+ // Key returns the key of the current key/value pair, or nil if done.
+ // The caller should not modify the contents of the returned slice, and
+ // its contents may change on the next call to any 'seeks method'.
+ Key() []byte
+
+ // Value returns the key of the current key/value pair, or nil if done.
+ // The caller should not modify the contents of the returned slice, and
+ // its contents may change on the next call to any 'seeks method'.
+ Value() []byte
+}
+
+// ErrorCallbackSetter is the interface that wraps basic SetErrorCallback
+// method.
+//
+// ErrorCallbackSetter implemented by indexed and merged iterator.
+type ErrorCallbackSetter interface {
+ // SetErrorCallback allows set an error callback of the coresponding
+ // iterator. Use nil to clear the callback.
+ SetErrorCallback(f func(err error))
+}
+
+type emptyIterator struct {
+ releaser util.Releaser
+ released bool
+ err error
+}
+
+func (i *emptyIterator) rErr() {
+ if i.err == nil && i.released {
+ i.err = errors.New("leveldb/iterator: iterator released")
+ }
+}
+
+func (i *emptyIterator) Release() {
+ if i.releaser != nil {
+ i.releaser.Release()
+ i.releaser = nil
+ }
+ i.released = true
+}
+
+func (i *emptyIterator) SetReleaser(releaser util.Releaser) {
+ if !i.released {
+ i.releaser = releaser
+ }
+}
+
+func (*emptyIterator) Valid() bool { return false }
+func (i *emptyIterator) First() bool { i.rErr(); return false }
+func (i *emptyIterator) Last() bool { i.rErr(); return false }
+func (i *emptyIterator) Seek(key []byte) bool { i.rErr(); return false }
+func (i *emptyIterator) Next() bool { i.rErr(); return false }
+func (i *emptyIterator) Prev() bool { i.rErr(); return false }
+func (*emptyIterator) Key() []byte { return nil }
+func (*emptyIterator) Value() []byte { return nil }
+func (i *emptyIterator) Error() error { return i.err }
+
+// NewEmptyIterator creates an empty iterator. The err parameter can be
+// nil, but if not nil the given err will be returned by Error method.
+func NewEmptyIterator(err error) Iterator {
+ return &emptyIterator{err: err}
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/iterator/iter_suite_test.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/iterator/iter_suite_test.go
new file mode 100644
index 000000000..7ec2fc6f2
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/iterator/iter_suite_test.go
@@ -0,0 +1,17 @@
+package iterator_test
+
+import (
+ "testing"
+
+ . "github.com/onsi/ginkgo"
+ . "github.com/onsi/gomega"
+
+ "github.com/syndtr/goleveldb/leveldb/testutil"
+)
+
+func TestIterator(t *testing.T) {
+ testutil.RunDefer()
+
+ RegisterFailHandler(Fail)
+ RunSpecs(t, "Iterator Suite")
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/iterator/merged_iter.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/iterator/merged_iter.go
new file mode 100644
index 000000000..c8314c4e5
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/iterator/merged_iter.go
@@ -0,0 +1,307 @@
+// Copyright (c) 2012, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package iterator
+
+import (
+ "errors"
+
+ "github.com/syndtr/goleveldb/leveldb/comparer"
+ "github.com/syndtr/goleveldb/leveldb/util"
+)
+
+var (
+ ErrIterReleased = errors.New("leveldb/iterator: iterator released")
+)
+
+type dir int
+
+const (
+ dirReleased dir = iota - 1
+ dirSOI
+ dirEOI
+ dirBackward
+ dirForward
+)
+
+type mergedIterator struct {
+ cmp comparer.Comparer
+ iters []Iterator
+ strict bool
+
+ keys [][]byte
+ index int
+ dir dir
+ err error
+ errf func(err error)
+ releaser util.Releaser
+}
+
+func assertKey(key []byte) []byte {
+ if key == nil {
+ panic("leveldb/iterator: nil key")
+ }
+ return key
+}
+
+func (i *mergedIterator) iterErr(iter Iterator) bool {
+ if i.errf != nil {
+ if err := iter.Error(); err != nil {
+ i.errf(err)
+ }
+ }
+ if i.strict {
+ if err := iter.Error(); err != nil {
+ i.err = err
+ return true
+ }
+ }
+ return false
+}
+
+func (i *mergedIterator) Valid() bool {
+ return i.err == nil && i.dir > dirEOI
+}
+
+func (i *mergedIterator) First() bool {
+ if i.err != nil {
+ return false
+ } else if i.dir == dirReleased {
+ i.err = ErrIterReleased
+ return false
+ }
+
+ for x, iter := range i.iters {
+ switch {
+ case iter.First():
+ i.keys[x] = assertKey(iter.Key())
+ case i.iterErr(iter):
+ return false
+ default:
+ i.keys[x] = nil
+ }
+ }
+ i.dir = dirSOI
+ return i.next()
+}
+
+func (i *mergedIterator) Last() bool {
+ if i.err != nil {
+ return false
+ } else if i.dir == dirReleased {
+ i.err = ErrIterReleased
+ return false
+ }
+
+ for x, iter := range i.iters {
+ switch {
+ case iter.Last():
+ i.keys[x] = assertKey(iter.Key())
+ case i.iterErr(iter):
+ return false
+ default:
+ i.keys[x] = nil
+ }
+ }
+ i.dir = dirEOI
+ return i.prev()
+}
+
+func (i *mergedIterator) Seek(key []byte) bool {
+ if i.err != nil {
+ return false
+ } else if i.dir == dirReleased {
+ i.err = ErrIterReleased
+ return false
+ }
+
+ for x, iter := range i.iters {
+ switch {
+ case iter.Seek(key):
+ i.keys[x] = assertKey(iter.Key())
+ case i.iterErr(iter):
+ return false
+ default:
+ i.keys[x] = nil
+ }
+ }
+ i.dir = dirSOI
+ return i.next()
+}
+
+func (i *mergedIterator) next() bool {
+ var key []byte
+ if i.dir == dirForward {
+ key = i.keys[i.index]
+ }
+ for x, tkey := range i.keys {
+ if tkey != nil && (key == nil || i.cmp.Compare(tkey, key) < 0) {
+ key = tkey
+ i.index = x
+ }
+ }
+ if key == nil {
+ i.dir = dirEOI
+ return false
+ }
+ i.dir = dirForward
+ return true
+}
+
+func (i *mergedIterator) Next() bool {
+ if i.dir == dirEOI || i.err != nil {
+ return false
+ } else if i.dir == dirReleased {
+ i.err = ErrIterReleased
+ return false
+ }
+
+ switch i.dir {
+ case dirSOI:
+ return i.First()
+ case dirBackward:
+ key := append([]byte{}, i.keys[i.index]...)
+ if !i.Seek(key) {
+ return false
+ }
+ return i.Next()
+ }
+
+ x := i.index
+ iter := i.iters[x]
+ switch {
+ case iter.Next():
+ i.keys[x] = assertKey(iter.Key())
+ case i.iterErr(iter):
+ return false
+ default:
+ i.keys[x] = nil
+ }
+ return i.next()
+}
+
+func (i *mergedIterator) prev() bool {
+ var key []byte
+ if i.dir == dirBackward {
+ key = i.keys[i.index]
+ }
+ for x, tkey := range i.keys {
+ if tkey != nil && (key == nil || i.cmp.Compare(tkey, key) > 0) {
+ key = tkey
+ i.index = x
+ }
+ }
+ if key == nil {
+ i.dir = dirSOI
+ return false
+ }
+ i.dir = dirBackward
+ return true
+}
+
+func (i *mergedIterator) Prev() bool {
+ if i.dir == dirSOI || i.err != nil {
+ return false
+ } else if i.dir == dirReleased {
+ i.err = ErrIterReleased
+ return false
+ }
+
+ switch i.dir {
+ case dirEOI:
+ return i.Last()
+ case dirForward:
+ key := append([]byte{}, i.keys[i.index]...)
+ for x, iter := range i.iters {
+ if x == i.index {
+ continue
+ }
+ seek := iter.Seek(key)
+ switch {
+ case seek && iter.Prev(), !seek && iter.Last():
+ i.keys[x] = assertKey(iter.Key())
+ case i.iterErr(iter):
+ return false
+ default:
+ i.keys[x] = nil
+ }
+ }
+ }
+
+ x := i.index
+ iter := i.iters[x]
+ switch {
+ case iter.Prev():
+ i.keys[x] = assertKey(iter.Key())
+ case i.iterErr(iter):
+ return false
+ default:
+ i.keys[x] = nil
+ }
+ return i.prev()
+}
+
+func (i *mergedIterator) Key() []byte {
+ if i.err != nil || i.dir <= dirEOI {
+ return nil
+ }
+ return i.keys[i.index]
+}
+
+func (i *mergedIterator) Value() []byte {
+ if i.err != nil || i.dir <= dirEOI {
+ return nil
+ }
+ return i.iters[i.index].Value()
+}
+
+func (i *mergedIterator) Release() {
+ if i.dir != dirReleased {
+ i.dir = dirReleased
+ for _, iter := range i.iters {
+ iter.Release()
+ }
+ i.iters = nil
+ i.keys = nil
+ if i.releaser != nil {
+ i.releaser.Release()
+ i.releaser = nil
+ }
+ }
+}
+
+func (i *mergedIterator) SetReleaser(releaser util.Releaser) {
+ if i.dir != dirReleased {
+ i.releaser = releaser
+ }
+}
+
+func (i *mergedIterator) Error() error {
+ return i.err
+}
+
+func (i *mergedIterator) SetErrorCallback(f func(err error)) {
+ i.errf = f
+}
+
+// NewMergedIterator returns an iterator that merges its input. Walking the
+// resultant iterator will return all key/value pairs of all input iterators
+// in strictly increasing key order, as defined by cmp.
+// The input's key ranges may overlap, but there are assumed to be no duplicate
+// keys: if iters[i] contains a key k then iters[j] will not contain that key k.
+// None of the iters may be nil.
+//
+// If strict is true then error yield by any iterators will halt the merged
+// iterator, on contrary if strict is false then the merged iterator will
+// ignore those error and move on to the next iterator.
+func NewMergedIterator(iters []Iterator, cmp comparer.Comparer, strict bool) Iterator {
+ return &mergedIterator{
+ iters: iters,
+ cmp: cmp,
+ strict: strict,
+ keys: make([][]byte, len(iters)),
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/iterator/merged_iter_test.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/iterator/merged_iter_test.go
new file mode 100644
index 000000000..e523b63e4
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/iterator/merged_iter_test.go
@@ -0,0 +1,60 @@
+// Copyright (c) 2014, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package iterator_test
+
+import (
+ . "github.com/onsi/ginkgo"
+ . "github.com/onsi/gomega"
+
+ "github.com/syndtr/goleveldb/leveldb/comparer"
+ . "github.com/syndtr/goleveldb/leveldb/iterator"
+ "github.com/syndtr/goleveldb/leveldb/testutil"
+)
+
+var _ = testutil.Defer(func() {
+ Describe("Merged iterator", func() {
+ Test := func(filled int, empty int) func() {
+ return func() {
+ It("Should iterates and seeks correctly", func(done Done) {
+ rnd := testutil.NewRand()
+
+ // Build key/value.
+ filledKV := make([]testutil.KeyValue, filled)
+ kv := testutil.KeyValue_Generate(nil, 100, 1, 10, 4, 4)
+ kv.Iterate(func(i int, key, value []byte) {
+ filledKV[rnd.Intn(filled)].Put(key, value)
+ })
+
+ // Create itearators.
+ iters := make([]Iterator, filled+empty)
+ for i := range iters {
+ if empty == 0 || (rnd.Int()%2 == 0 && filled > 0) {
+ filled--
+ Expect(filledKV[filled].Len()).ShouldNot(BeZero())
+ iters[i] = NewArrayIterator(filledKV[filled])
+ } else {
+ empty--
+ iters[i] = NewEmptyIterator(nil)
+ }
+ }
+
+ // Test the iterator.
+ t := testutil.IteratorTesting{
+ KeyValue: kv.Clone(),
+ Iter: NewMergedIterator(iters, comparer.DefaultComparer, true),
+ }
+ testutil.DoIteratorTesting(&t)
+ done <- true
+ }, 1.5)
+ }
+ }
+
+ Describe("with three, all filled iterators", Test(3, 0))
+ Describe("with one filled, one empty iterators", Test(1, 1))
+ Describe("with one filled, two empty iterators", Test(1, 2))
+ })
+})
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/journal/journal.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/journal/journal.go
new file mode 100644
index 000000000..b522c76e6
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/journal/journal.go
@@ -0,0 +1,513 @@
+// Copyright 2011 The LevelDB-Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Taken from: https://code.google.com/p/leveldb-go/source/browse/leveldb/record/record.go?r=1d5ccbe03246da926391ee12d1c6caae054ff4b0
+// License, authors and contributors informations can be found at bellow URLs respectively:
+// https://code.google.com/p/leveldb-go/source/browse/LICENSE
+// https://code.google.com/p/leveldb-go/source/browse/AUTHORS
+// https://code.google.com/p/leveldb-go/source/browse/CONTRIBUTORS
+
+// Package journal reads and writes sequences of journals. Each journal is a stream
+// of bytes that completes before the next journal starts.
+//
+// When reading, call Next to obtain an io.Reader for the next journal. Next will
+// return io.EOF when there are no more journals. It is valid to call Next
+// without reading the current journal to exhaustion.
+//
+// When writing, call Next to obtain an io.Writer for the next journal. Calling
+// Next finishes the current journal. Call Close to finish the final journal.
+//
+// Optionally, call Flush to finish the current journal and flush the underlying
+// writer without starting a new journal. To start a new journal after flushing,
+// call Next.
+//
+// Neither Readers or Writers are safe to use concurrently.
+//
+// Example code:
+// func read(r io.Reader) ([]string, error) {
+// var ss []string
+// journals := journal.NewReader(r, nil, true, true)
+// for {
+// j, err := journals.Next()
+// if err == io.EOF {
+// break
+// }
+// if err != nil {
+// return nil, err
+// }
+// s, err := ioutil.ReadAll(j)
+// if err != nil {
+// return nil, err
+// }
+// ss = append(ss, string(s))
+// }
+// return ss, nil
+// }
+//
+// func write(w io.Writer, ss []string) error {
+// journals := journal.NewWriter(w)
+// for _, s := range ss {
+// j, err := journals.Next()
+// if err != nil {
+// return err
+// }
+// if _, err := j.Write([]byte(s)), err != nil {
+// return err
+// }
+// }
+// return journals.Close()
+// }
+//
+// The wire format is that the stream is divided into 32KiB blocks, and each
+// block contains a number of tightly packed chunks. Chunks cannot cross block
+// boundaries. The last block may be shorter than 32 KiB. Any unused bytes in a
+// block must be zero.
+//
+// A journal maps to one or more chunks. Each chunk has a 7 byte header (a 4
+// byte checksum, a 2 byte little-endian uint16 length, and a 1 byte chunk type)
+// followed by a payload. The checksum is over the chunk type and the payload.
+//
+// There are four chunk types: whether the chunk is the full journal, or the
+// first, middle or last chunk of a multi-chunk journal. A multi-chunk journal
+// has one first chunk, zero or more middle chunks, and one last chunk.
+//
+// The wire format allows for limited recovery in the face of data corruption:
+// on a format error (such as a checksum mismatch), the reader moves to the
+// next block and looks for the next full or first chunk.
+package journal
+
+import (
+ "encoding/binary"
+ "errors"
+ "fmt"
+ "io"
+
+ "github.com/syndtr/goleveldb/leveldb/util"
+)
+
+// These constants are part of the wire format and should not be changed.
+const (
+ fullChunkType = 1
+ firstChunkType = 2
+ middleChunkType = 3
+ lastChunkType = 4
+)
+
+const (
+ blockSize = 32 * 1024
+ headerSize = 7
+)
+
+type flusher interface {
+ Flush() error
+}
+
+// DroppedError is the error type that passed to Dropper.Drop method.
+type DroppedError struct {
+ Size int
+ Reason string
+}
+
+func (e DroppedError) Error() string {
+ return fmt.Sprintf("leveldb/journal: dropped %d bytes: %s", e.Size, e.Reason)
+}
+
+// Dropper is the interface that wrap simple Drop method. The Drop
+// method will be called when the journal reader dropping a chunk.
+type Dropper interface {
+ Drop(err error)
+}
+
+// Reader reads journals from an underlying io.Reader.
+type Reader struct {
+ // r is the underlying reader.
+ r io.Reader
+ // the dropper.
+ dropper Dropper
+ // strict flag.
+ strict bool
+ // checksum flag.
+ checksum bool
+ // seq is the sequence number of the current journal.
+ seq int
+ // buf[i:j] is the unread portion of the current chunk's payload.
+ // The low bound, i, excludes the chunk header.
+ i, j int
+ // n is the number of bytes of buf that are valid. Once reading has started,
+ // only the final block can have n < blockSize.
+ n int
+ // last is whether the current chunk is the last chunk of the journal.
+ last bool
+ // err is any accumulated error.
+ err error
+ // buf is the buffer.
+ buf [blockSize]byte
+}
+
+// NewReader returns a new reader. The dropper may be nil, and if
+// strict is true then corrupted or invalid chunk will halt the journal
+// reader entirely.
+func NewReader(r io.Reader, dropper Dropper, strict, checksum bool) *Reader {
+ return &Reader{
+ r: r,
+ dropper: dropper,
+ strict: strict,
+ checksum: checksum,
+ last: true,
+ }
+}
+
+// nextChunk sets r.buf[r.i:r.j] to hold the next chunk's payload, reading the
+// next block into the buffer if necessary.
+func (r *Reader) nextChunk(wantFirst, skip bool) error {
+ for {
+ if r.j+headerSize <= r.n {
+ checksum := binary.LittleEndian.Uint32(r.buf[r.j+0 : r.j+4])
+ length := binary.LittleEndian.Uint16(r.buf[r.j+4 : r.j+6])
+ chunkType := r.buf[r.j+6]
+
+ var err error
+ if checksum == 0 && length == 0 && chunkType == 0 {
+ // Drop entire block.
+ err = DroppedError{r.n - r.j, "zero header"}
+ r.i = r.n
+ r.j = r.n
+ } else {
+ m := r.n - r.j
+ r.i = r.j + headerSize
+ r.j = r.j + headerSize + int(length)
+ if r.j > r.n {
+ // Drop entire block.
+ err = DroppedError{m, "chunk length overflows block"}
+ r.i = r.n
+ r.j = r.n
+ } else if r.checksum && checksum != util.NewCRC(r.buf[r.i-1:r.j]).Value() {
+ // Drop entire block.
+ err = DroppedError{m, "checksum mismatch"}
+ r.i = r.n
+ r.j = r.n
+ }
+ }
+ if wantFirst && err == nil && chunkType != fullChunkType && chunkType != firstChunkType {
+ if skip {
+ // The chunk are intentionally skipped.
+ if chunkType == lastChunkType {
+ skip = false
+ }
+ continue
+ } else {
+ // Drop the chunk.
+ err = DroppedError{r.j - r.i + headerSize, "orphan chunk"}
+ }
+ }
+ if err == nil {
+ r.last = chunkType == fullChunkType || chunkType == lastChunkType
+ } else {
+ if r.dropper != nil {
+ r.dropper.Drop(err)
+ }
+ if r.strict {
+ r.err = err
+ }
+ }
+ return err
+ }
+ if r.n < blockSize && r.n > 0 {
+ // This is the last block.
+ if r.j != r.n {
+ r.err = io.ErrUnexpectedEOF
+ } else {
+ r.err = io.EOF
+ }
+ return r.err
+ }
+ n, err := io.ReadFull(r.r, r.buf[:])
+ if err != nil && err != io.ErrUnexpectedEOF {
+ r.err = err
+ return r.err
+ }
+ if n == 0 {
+ r.err = io.EOF
+ return r.err
+ }
+ r.i, r.j, r.n = 0, 0, n
+ }
+}
+
+// Next returns a reader for the next journal. It returns io.EOF if there are no
+// more journals. The reader returned becomes stale after the next Next call,
+// and should no longer be used.
+func (r *Reader) Next() (io.Reader, error) {
+ r.seq++
+ if r.err != nil {
+ return nil, r.err
+ }
+ skip := !r.last
+ for {
+ r.i = r.j
+ if r.nextChunk(true, skip) != nil {
+ // So that 'orphan chunk' drop will be reported.
+ skip = false
+ } else {
+ break
+ }
+ if r.err != nil {
+ return nil, r.err
+ }
+ }
+ return &singleReader{r, r.seq, nil}, nil
+}
+
+// Reset resets the journal reader, allows reuse of the journal reader.
+func (r *Reader) Reset(reader io.Reader, dropper Dropper, strict, checksum bool) error {
+ r.seq++
+ err := r.err
+ r.r = reader
+ r.dropper = dropper
+ r.strict = strict
+ r.checksum = checksum
+ r.i = 0
+ r.j = 0
+ r.n = 0
+ r.last = true
+ r.err = nil
+ return err
+}
+
+type singleReader struct {
+ r *Reader
+ seq int
+ err error
+}
+
+func (x *singleReader) Read(p []byte) (int, error) {
+ r := x.r
+ if r.seq != x.seq {
+ return 0, errors.New("leveldb/journal: stale reader")
+ }
+ if x.err != nil {
+ return 0, x.err
+ }
+ if r.err != nil {
+ return 0, r.err
+ }
+ for r.i == r.j {
+ if r.last {
+ return 0, io.EOF
+ }
+ if x.err = r.nextChunk(false, false); x.err != nil {
+ return 0, x.err
+ }
+ }
+ n := copy(p, r.buf[r.i:r.j])
+ r.i += n
+ return n, nil
+}
+
+func (x *singleReader) ReadByte() (byte, error) {
+ r := x.r
+ if r.seq != x.seq {
+ return 0, errors.New("leveldb/journal: stale reader")
+ }
+ if x.err != nil {
+ return 0, x.err
+ }
+ if r.err != nil {
+ return 0, r.err
+ }
+ for r.i == r.j {
+ if r.last {
+ return 0, io.EOF
+ }
+ if x.err = r.nextChunk(false, false); x.err != nil {
+ return 0, x.err
+ }
+ }
+ c := r.buf[r.i]
+ r.i++
+ return c, nil
+}
+
+// Writer writes journals to an underlying io.Writer.
+type Writer struct {
+ // w is the underlying writer.
+ w io.Writer
+ // seq is the sequence number of the current journal.
+ seq int
+ // f is w as a flusher.
+ f flusher
+ // buf[i:j] is the bytes that will become the current chunk.
+ // The low bound, i, includes the chunk header.
+ i, j int
+ // buf[:written] has already been written to w.
+ // written is zero unless Flush has been called.
+ written int
+ // first is whether the current chunk is the first chunk of the journal.
+ first bool
+ // pending is whether a chunk is buffered but not yet written.
+ pending bool
+ // err is any accumulated error.
+ err error
+ // buf is the buffer.
+ buf [blockSize]byte
+}
+
+// NewWriter returns a new Writer.
+func NewWriter(w io.Writer) *Writer {
+ f, _ := w.(flusher)
+ return &Writer{
+ w: w,
+ f: f,
+ }
+}
+
+// fillHeader fills in the header for the pending chunk.
+func (w *Writer) fillHeader(last bool) {
+ if w.i+headerSize > w.j || w.j > blockSize {
+ panic("leveldb/journal: bad writer state")
+ }
+ if last {
+ if w.first {
+ w.buf[w.i+6] = fullChunkType
+ } else {
+ w.buf[w.i+6] = lastChunkType
+ }
+ } else {
+ if w.first {
+ w.buf[w.i+6] = firstChunkType
+ } else {
+ w.buf[w.i+6] = middleChunkType
+ }
+ }
+ binary.LittleEndian.PutUint32(w.buf[w.i+0:w.i+4], util.NewCRC(w.buf[w.i+6:w.j]).Value())
+ binary.LittleEndian.PutUint16(w.buf[w.i+4:w.i+6], uint16(w.j-w.i-headerSize))
+}
+
+// writeBlock writes the buffered block to the underlying writer, and reserves
+// space for the next chunk's header.
+func (w *Writer) writeBlock() {
+ _, w.err = w.w.Write(w.buf[w.written:])
+ w.i = 0
+ w.j = headerSize
+ w.written = 0
+}
+
+// writePending finishes the current journal and writes the buffer to the
+// underlying writer.
+func (w *Writer) writePending() {
+ if w.err != nil {
+ return
+ }
+ if w.pending {
+ w.fillHeader(true)
+ w.pending = false
+ }
+ _, w.err = w.w.Write(w.buf[w.written:w.j])
+ w.written = w.j
+}
+
+// Close finishes the current journal and closes the writer.
+func (w *Writer) Close() error {
+ w.seq++
+ w.writePending()
+ if w.err != nil {
+ return w.err
+ }
+ w.err = errors.New("leveldb/journal: closed Writer")
+ return nil
+}
+
+// Flush finishes the current journal, writes to the underlying writer, and
+// flushes it if that writer implements interface{ Flush() error }.
+func (w *Writer) Flush() error {
+ w.seq++
+ w.writePending()
+ if w.err != nil {
+ return w.err
+ }
+ if w.f != nil {
+ w.err = w.f.Flush()
+ return w.err
+ }
+ return nil
+}
+
+// Reset resets the journal writer, allows reuse of the journal writer. Reset
+// will also closes the journal writer if not already.
+func (w *Writer) Reset(writer io.Writer) (err error) {
+ w.seq++
+ if w.err == nil {
+ w.writePending()
+ err = w.err
+ }
+ w.w = writer
+ w.f, _ = writer.(flusher)
+ w.i = 0
+ w.j = 0
+ w.written = 0
+ w.first = false
+ w.pending = false
+ w.err = nil
+ return
+}
+
+// Next returns a writer for the next journal. The writer returned becomes stale
+// after the next Close, Flush or Next call, and should no longer be used.
+func (w *Writer) Next() (io.Writer, error) {
+ w.seq++
+ if w.err != nil {
+ return nil, w.err
+ }
+ if w.pending {
+ w.fillHeader(true)
+ }
+ w.i = w.j
+ w.j = w.j + headerSize
+ // Check if there is room in the block for the header.
+ if w.j > blockSize {
+ // Fill in the rest of the block with zeroes.
+ for k := w.i; k < blockSize; k++ {
+ w.buf[k] = 0
+ }
+ w.writeBlock()
+ if w.err != nil {
+ return nil, w.err
+ }
+ }
+ w.first = true
+ w.pending = true
+ return singleWriter{w, w.seq}, nil
+}
+
+type singleWriter struct {
+ w *Writer
+ seq int
+}
+
+func (x singleWriter) Write(p []byte) (int, error) {
+ w := x.w
+ if w.seq != x.seq {
+ return 0, errors.New("leveldb/journal: stale writer")
+ }
+ if w.err != nil {
+ return 0, w.err
+ }
+ n0 := len(p)
+ for len(p) > 0 {
+ // Write a block, if it is full.
+ if w.j == blockSize {
+ w.fillHeader(false)
+ w.writeBlock()
+ if w.err != nil {
+ return 0, w.err
+ }
+ w.first = false
+ }
+ // Copy bytes into the buffer.
+ n := copy(w.buf[w.j:], p)
+ w.j += n
+ p = p[n:]
+ }
+ return n0, nil
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/journal/journal_test.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/journal/journal_test.go
new file mode 100644
index 000000000..5e1193ae2
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/journal/journal_test.go
@@ -0,0 +1,328 @@
+// Copyright 2011 The LevelDB-Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Taken from: https://code.google.com/p/leveldb-go/source/browse/leveldb/record/record_test.go?r=df1fa28f7f3be6c3935548169002309c12967135
+// License, authors and contributors informations can be found at bellow URLs respectively:
+// https://code.google.com/p/leveldb-go/source/browse/LICENSE
+// https://code.google.com/p/leveldb-go/source/browse/AUTHORS
+// https://code.google.com/p/leveldb-go/source/browse/CONTRIBUTORS
+
+package journal
+
+import (
+ "bytes"
+ "fmt"
+ "io"
+ "io/ioutil"
+ "math/rand"
+ "strings"
+ "testing"
+)
+
+type dropper struct {
+ t *testing.T
+}
+
+func (d dropper) Drop(err error) {
+ d.t.Log(err)
+}
+
+func short(s string) string {
+ if len(s) < 64 {
+ return s
+ }
+ return fmt.Sprintf("%s...(skipping %d bytes)...%s", s[:20], len(s)-40, s[len(s)-20:])
+}
+
+// big returns a string of length n, composed of repetitions of partial.
+func big(partial string, n int) string {
+ return strings.Repeat(partial, n/len(partial)+1)[:n]
+}
+
+func TestEmpty(t *testing.T) {
+ buf := new(bytes.Buffer)
+ r := NewReader(buf, dropper{t}, true, true)
+ if _, err := r.Next(); err != io.EOF {
+ t.Fatalf("got %v, want %v", err, io.EOF)
+ }
+}
+
+func testGenerator(t *testing.T, reset func(), gen func() (string, bool)) {
+ buf := new(bytes.Buffer)
+
+ reset()
+ w := NewWriter(buf)
+ for {
+ s, ok := gen()
+ if !ok {
+ break
+ }
+ ww, err := w.Next()
+ if err != nil {
+ t.Fatal(err)
+ }
+ if _, err := ww.Write([]byte(s)); err != nil {
+ t.Fatal(err)
+ }
+ }
+ if err := w.Close(); err != nil {
+ t.Fatal(err)
+ }
+
+ reset()
+ r := NewReader(buf, dropper{t}, true, true)
+ for {
+ s, ok := gen()
+ if !ok {
+ break
+ }
+ rr, err := r.Next()
+ if err != nil {
+ t.Fatal(err)
+ }
+ x, err := ioutil.ReadAll(rr)
+ if err != nil {
+ t.Fatal(err)
+ }
+ if string(x) != s {
+ t.Fatalf("got %q, want %q", short(string(x)), short(s))
+ }
+ }
+ if _, err := r.Next(); err != io.EOF {
+ t.Fatalf("got %v, want %v", err, io.EOF)
+ }
+}
+
+func testLiterals(t *testing.T, s []string) {
+ var i int
+ reset := func() {
+ i = 0
+ }
+ gen := func() (string, bool) {
+ if i == len(s) {
+ return "", false
+ }
+ i++
+ return s[i-1], true
+ }
+ testGenerator(t, reset, gen)
+}
+
+func TestMany(t *testing.T) {
+ const n = 1e5
+ var i int
+ reset := func() {
+ i = 0
+ }
+ gen := func() (string, bool) {
+ if i == n {
+ return "", false
+ }
+ i++
+ return fmt.Sprintf("%d.", i-1), true
+ }
+ testGenerator(t, reset, gen)
+}
+
+func TestRandom(t *testing.T) {
+ const n = 1e2
+ var (
+ i int
+ r *rand.Rand
+ )
+ reset := func() {
+ i, r = 0, rand.New(rand.NewSource(0))
+ }
+ gen := func() (string, bool) {
+ if i == n {
+ return "", false
+ }
+ i++
+ return strings.Repeat(string(uint8(i)), r.Intn(2*blockSize+16)), true
+ }
+ testGenerator(t, reset, gen)
+}
+
+func TestBasic(t *testing.T) {
+ testLiterals(t, []string{
+ strings.Repeat("a", 1000),
+ strings.Repeat("b", 97270),
+ strings.Repeat("c", 8000),
+ })
+}
+
+func TestBoundary(t *testing.T) {
+ for i := blockSize - 16; i < blockSize+16; i++ {
+ s0 := big("abcd", i)
+ for j := blockSize - 16; j < blockSize+16; j++ {
+ s1 := big("ABCDE", j)
+ testLiterals(t, []string{s0, s1})
+ testLiterals(t, []string{s0, "", s1})
+ testLiterals(t, []string{s0, "x", s1})
+ }
+ }
+}
+
+func TestFlush(t *testing.T) {
+ buf := new(bytes.Buffer)
+ w := NewWriter(buf)
+ // Write a couple of records. Everything should still be held
+ // in the record.Writer buffer, so that buf.Len should be 0.
+ w0, _ := w.Next()
+ w0.Write([]byte("0"))
+ w1, _ := w.Next()
+ w1.Write([]byte("11"))
+ if got, want := buf.Len(), 0; got != want {
+ t.Fatalf("buffer length #0: got %d want %d", got, want)
+ }
+ // Flush the record.Writer buffer, which should yield 17 bytes.
+ // 17 = 2*7 + 1 + 2, which is two headers and 1 + 2 payload bytes.
+ if err := w.Flush(); err != nil {
+ t.Fatal(err)
+ }
+ if got, want := buf.Len(), 17; got != want {
+ t.Fatalf("buffer length #1: got %d want %d", got, want)
+ }
+ // Do another write, one that isn't large enough to complete the block.
+ // The write should not have flowed through to buf.
+ w2, _ := w.Next()
+ w2.Write(bytes.Repeat([]byte("2"), 10000))
+ if got, want := buf.Len(), 17; got != want {
+ t.Fatalf("buffer length #2: got %d want %d", got, want)
+ }
+ // Flushing should get us up to 10024 bytes written.
+ // 10024 = 17 + 7 + 10000.
+ if err := w.Flush(); err != nil {
+ t.Fatal(err)
+ }
+ if got, want := buf.Len(), 10024; got != want {
+ t.Fatalf("buffer length #3: got %d want %d", got, want)
+ }
+ // Do a bigger write, one that completes the current block.
+ // We should now have 32768 bytes (a complete block), without
+ // an explicit flush.
+ w3, _ := w.Next()
+ w3.Write(bytes.Repeat([]byte("3"), 40000))
+ if got, want := buf.Len(), 32768; got != want {
+ t.Fatalf("buffer length #4: got %d want %d", got, want)
+ }
+ // Flushing should get us up to 50038 bytes written.
+ // 50038 = 10024 + 2*7 + 40000. There are two headers because
+ // the one record was split into two chunks.
+ if err := w.Flush(); err != nil {
+ t.Fatal(err)
+ }
+ if got, want := buf.Len(), 50038; got != want {
+ t.Fatalf("buffer length #5: got %d want %d", got, want)
+ }
+ // Check that reading those records give the right lengths.
+ r := NewReader(buf, dropper{t}, true, true)
+ wants := []int64{1, 2, 10000, 40000}
+ for i, want := range wants {
+ rr, _ := r.Next()
+ n, err := io.Copy(ioutil.Discard, rr)
+ if err != nil {
+ t.Fatalf("read #%d: %v", i, err)
+ }
+ if n != want {
+ t.Fatalf("read #%d: got %d bytes want %d", i, n, want)
+ }
+ }
+}
+
+func TestNonExhaustiveRead(t *testing.T) {
+ const n = 100
+ buf := new(bytes.Buffer)
+ p := make([]byte, 10)
+ rnd := rand.New(rand.NewSource(1))
+
+ w := NewWriter(buf)
+ for i := 0; i < n; i++ {
+ length := len(p) + rnd.Intn(3*blockSize)
+ s := string(uint8(i)) + "123456789abcdefgh"
+ ww, _ := w.Next()
+ ww.Write([]byte(big(s, length)))
+ }
+ if err := w.Close(); err != nil {
+ t.Fatal(err)
+ }
+
+ r := NewReader(buf, dropper{t}, true, true)
+ for i := 0; i < n; i++ {
+ rr, _ := r.Next()
+ _, err := io.ReadFull(rr, p)
+ if err != nil {
+ t.Fatal(err)
+ }
+ want := string(uint8(i)) + "123456789"
+ if got := string(p); got != want {
+ t.Fatalf("read #%d: got %q want %q", i, got, want)
+ }
+ }
+}
+
+func TestStaleReader(t *testing.T) {
+ buf := new(bytes.Buffer)
+
+ w := NewWriter(buf)
+ w0, err := w.Next()
+ if err != nil {
+ t.Fatal(err)
+ }
+ w0.Write([]byte("0"))
+ w1, err := w.Next()
+ if err != nil {
+ t.Fatal(err)
+ }
+ w1.Write([]byte("11"))
+ if err := w.Close(); err != nil {
+ t.Fatal(err)
+ }
+
+ r := NewReader(buf, dropper{t}, true, true)
+ r0, err := r.Next()
+ if err != nil {
+ t.Fatal(err)
+ }
+ r1, err := r.Next()
+ if err != nil {
+ t.Fatal(err)
+ }
+ p := make([]byte, 1)
+ if _, err := r0.Read(p); err == nil || !strings.Contains(err.Error(), "stale") {
+ t.Fatalf("stale read #0: unexpected error: %v", err)
+ }
+ if _, err := r1.Read(p); err != nil {
+ t.Fatalf("fresh read #1: got %v want nil error", err)
+ }
+ if p[0] != '1' {
+ t.Fatalf("fresh read #1: byte contents: got '%c' want '1'", p[0])
+ }
+}
+
+func TestStaleWriter(t *testing.T) {
+ buf := new(bytes.Buffer)
+
+ w := NewWriter(buf)
+ w0, err := w.Next()
+ if err != nil {
+ t.Fatal(err)
+ }
+ w1, err := w.Next()
+ if err != nil {
+ t.Fatal(err)
+ }
+ if _, err := w0.Write([]byte("0")); err == nil || !strings.Contains(err.Error(), "stale") {
+ t.Fatalf("stale write #0: unexpected error: %v", err)
+ }
+ if _, err := w1.Write([]byte("11")); err != nil {
+ t.Fatalf("fresh write #1: got %v want nil error", err)
+ }
+ if err := w.Flush(); err != nil {
+ t.Fatalf("flush: %v", err)
+ }
+ if _, err := w1.Write([]byte("0")); err == nil || !strings.Contains(err.Error(), "stale") {
+ t.Fatalf("stale write #1: unexpected error: %v", err)
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/key.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/key.go
new file mode 100644
index 000000000..b9acf932d
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/key.go
@@ -0,0 +1,139 @@
+// Copyright (c) 2012, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package leveldb
+
+import (
+ "encoding/binary"
+ "fmt"
+)
+
+type vType int
+
+func (t vType) String() string {
+ switch t {
+ case tDel:
+ return "d"
+ case tVal:
+ return "v"
+ }
+ return "x"
+}
+
+// Value types encoded as the last component of internal keys.
+// Don't modify; this value are saved to disk.
+const (
+ tDel vType = iota
+ tVal
+)
+
+// tSeek defines the vType that should be passed when constructing an
+// internal key for seeking to a particular sequence number (since we
+// sort sequence numbers in decreasing order and the value type is
+// embedded as the low 8 bits in the sequence number in internal keys,
+// we need to use the highest-numbered ValueType, not the lowest).
+const tSeek = tVal
+
+const (
+ // Maximum value possible for sequence number; the 8-bits are
+ // used by value type, so its can packed together in single
+ // 64-bit integer.
+ kMaxSeq uint64 = (uint64(1) << 56) - 1
+ // Maximum value possible for packed sequence number and type.
+ kMaxNum uint64 = (kMaxSeq << 8) | uint64(tSeek)
+)
+
+// Maximum number encoded in bytes.
+var kMaxNumBytes = make([]byte, 8)
+
+func init() {
+ binary.LittleEndian.PutUint64(kMaxNumBytes, kMaxNum)
+}
+
+type iKey []byte
+
+func newIKey(ukey []byte, seq uint64, t vType) iKey {
+ if seq > kMaxSeq || t > tVal {
+ panic("invalid seq number or value type")
+ }
+
+ b := make(iKey, len(ukey)+8)
+ copy(b, ukey)
+ binary.LittleEndian.PutUint64(b[len(ukey):], (seq<<8)|uint64(t))
+ return b
+}
+
+func parseIkey(p []byte) (ukey []byte, seq uint64, t vType, ok bool) {
+ if len(p) < 8 {
+ return
+ }
+ num := binary.LittleEndian.Uint64(p[len(p)-8:])
+ seq, t = uint64(num>>8), vType(num&0xff)
+ if t > tVal {
+ return
+ }
+ ukey = p[:len(p)-8]
+ ok = true
+ return
+}
+
+func validIkey(p []byte) bool {
+ _, _, _, ok := parseIkey(p)
+ return ok
+}
+
+func (p iKey) assert() {
+ if p == nil {
+ panic("nil iKey")
+ }
+ if len(p) < 8 {
+ panic(fmt.Sprintf("invalid iKey %q, len=%d", []byte(p), len(p)))
+ }
+}
+
+func (p iKey) ok() bool {
+ if len(p) < 8 {
+ return false
+ }
+ _, _, ok := p.parseNum()
+ return ok
+}
+
+func (p iKey) ukey() []byte {
+ p.assert()
+ return p[:len(p)-8]
+}
+
+func (p iKey) num() uint64 {
+ p.assert()
+ return binary.LittleEndian.Uint64(p[len(p)-8:])
+}
+
+func (p iKey) parseNum() (seq uint64, t vType, ok bool) {
+ if p == nil {
+ panic("nil iKey")
+ }
+ if len(p) < 8 {
+ return
+ }
+ num := p.num()
+ seq, t = uint64(num>>8), vType(num&0xff)
+ if t > tVal {
+ return 0, 0, false
+ }
+ ok = true
+ return
+}
+
+func (p iKey) String() string {
+ if len(p) == 0 {
+ return "<nil>"
+ }
+ if seq, t, ok := p.parseNum(); ok {
+ return fmt.Sprintf("%s,%s%d", shorten(string(p.ukey())), t, seq)
+ }
+ return "<invalid>"
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/key_test.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/key_test.go
new file mode 100644
index 000000000..e307cfc1d
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/key_test.go
@@ -0,0 +1,123 @@
+// Copyright (c) 2012, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package leveldb
+
+import (
+ "bytes"
+ "testing"
+
+ "github.com/syndtr/goleveldb/leveldb/comparer"
+)
+
+var defaultIComparer = &iComparer{comparer.DefaultComparer}
+
+func ikey(key string, seq uint64, t vType) iKey {
+ return newIKey([]byte(key), uint64(seq), t)
+}
+
+func shortSep(a, b []byte) []byte {
+ dst := make([]byte, len(a))
+ dst = defaultIComparer.Separator(dst[:0], a, b)
+ if dst == nil {
+ return a
+ }
+ return dst
+}
+
+func shortSuccessor(b []byte) []byte {
+ dst := make([]byte, len(b))
+ dst = defaultIComparer.Successor(dst[:0], b)
+ if dst == nil {
+ return b
+ }
+ return dst
+}
+
+func testSingleKey(t *testing.T, key string, seq uint64, vt vType) {
+ ik := ikey(key, seq, vt)
+
+ if !bytes.Equal(ik.ukey(), []byte(key)) {
+ t.Errorf("user key does not equal, got %v, want %v", string(ik.ukey()), key)
+ }
+
+ if rseq, rt, ok := ik.parseNum(); ok {
+ if rseq != seq {
+ t.Errorf("seq number does not equal, got %v, want %v", rseq, seq)
+ }
+
+ if rt != vt {
+ t.Errorf("type does not equal, got %v, want %v", rt, vt)
+ }
+ } else {
+ t.Error("cannot parse seq and type")
+ }
+}
+
+func TestIKey_EncodeDecode(t *testing.T) {
+ keys := []string{"", "k", "hello", "longggggggggggggggggggggg"}
+ seqs := []uint64{
+ 1, 2, 3,
+ (1 << 8) - 1, 1 << 8, (1 << 8) + 1,
+ (1 << 16) - 1, 1 << 16, (1 << 16) + 1,
+ (1 << 32) - 1, 1 << 32, (1 << 32) + 1,
+ }
+ for _, key := range keys {
+ for _, seq := range seqs {
+ testSingleKey(t, key, seq, tVal)
+ testSingleKey(t, "hello", 1, tDel)
+ }
+ }
+}
+
+func assertBytes(t *testing.T, want, got []byte) {
+ if !bytes.Equal(got, want) {
+ t.Errorf("assert failed, got %v, want %v", got, want)
+ }
+}
+
+func TestIKeyShortSeparator(t *testing.T) {
+ // When user keys are same
+ assertBytes(t, ikey("foo", 100, tVal),
+ shortSep(ikey("foo", 100, tVal),
+ ikey("foo", 99, tVal)))
+ assertBytes(t, ikey("foo", 100, tVal),
+ shortSep(ikey("foo", 100, tVal),
+ ikey("foo", 101, tVal)))
+ assertBytes(t, ikey("foo", 100, tVal),
+ shortSep(ikey("foo", 100, tVal),
+ ikey("foo", 100, tVal)))
+ assertBytes(t, ikey("foo", 100, tVal),
+ shortSep(ikey("foo", 100, tVal),
+ ikey("foo", 100, tDel)))
+
+ // When user keys are misordered
+ assertBytes(t, ikey("foo", 100, tVal),
+ shortSep(ikey("foo", 100, tVal),
+ ikey("bar", 99, tVal)))
+
+ // When user keys are different, but correctly ordered
+ assertBytes(t, ikey("g", uint64(kMaxSeq), tSeek),
+ shortSep(ikey("foo", 100, tVal),
+ ikey("hello", 200, tVal)))
+
+ // When start user key is prefix of limit user key
+ assertBytes(t, ikey("foo", 100, tVal),
+ shortSep(ikey("foo", 100, tVal),
+ ikey("foobar", 200, tVal)))
+
+ // When limit user key is prefix of start user key
+ assertBytes(t, ikey("foobar", 100, tVal),
+ shortSep(ikey("foobar", 100, tVal),
+ ikey("foo", 200, tVal)))
+}
+
+func TestIKeyShortestSuccessor(t *testing.T) {
+ assertBytes(t, ikey("g", uint64(kMaxSeq), tSeek),
+ shortSuccessor(ikey("foo", 100, tVal)))
+ assertBytes(t, ikey("\xff\xff", 100, tVal),
+ shortSuccessor(ikey("\xff\xff", 100, tVal)))
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/leveldb_suite_test.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/leveldb_suite_test.go
new file mode 100644
index 000000000..245b1fd4d
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/leveldb_suite_test.go
@@ -0,0 +1,20 @@
+package leveldb
+
+import (
+ "testing"
+
+ . "github.com/onsi/ginkgo"
+ . "github.com/onsi/gomega"
+
+ "github.com/syndtr/goleveldb/leveldb/testutil"
+)
+
+func TestLeveldb(t *testing.T) {
+ testutil.RunDefer()
+
+ RegisterFailHandler(Fail)
+ RunSpecs(t, "Leveldb Suite")
+
+ RegisterTestingT(t)
+ testutil.RunDefer("teardown")
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/memdb/bench_test.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/memdb/bench_test.go
new file mode 100644
index 000000000..b05084caa
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/memdb/bench_test.go
@@ -0,0 +1,75 @@
+// Copyright (c) 2012, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package memdb
+
+import (
+ "encoding/binary"
+ "math/rand"
+ "testing"
+
+ "github.com/syndtr/goleveldb/leveldb/comparer"
+)
+
+func BenchmarkPut(b *testing.B) {
+ buf := make([][4]byte, b.N)
+ for i := range buf {
+ binary.LittleEndian.PutUint32(buf[i][:], uint32(i))
+ }
+
+ b.ResetTimer()
+ p := New(comparer.DefaultComparer, 0)
+ for i := range buf {
+ p.Put(buf[i][:], nil)
+ }
+}
+
+func BenchmarkPutRandom(b *testing.B) {
+ buf := make([][4]byte, b.N)
+ for i := range buf {
+ binary.LittleEndian.PutUint32(buf[i][:], uint32(rand.Int()))
+ }
+
+ b.ResetTimer()
+ p := New(comparer.DefaultComparer, 0)
+ for i := range buf {
+ p.Put(buf[i][:], nil)
+ }
+}
+
+func BenchmarkGet(b *testing.B) {
+ buf := make([][4]byte, b.N)
+ for i := range buf {
+ binary.LittleEndian.PutUint32(buf[i][:], uint32(i))
+ }
+
+ p := New(comparer.DefaultComparer, 0)
+ for i := range buf {
+ p.Put(buf[i][:], nil)
+ }
+
+ b.ResetTimer()
+ for i := range buf {
+ p.Get(buf[i][:])
+ }
+}
+
+func BenchmarkGetRandom(b *testing.B) {
+ buf := make([][4]byte, b.N)
+ for i := range buf {
+ binary.LittleEndian.PutUint32(buf[i][:], uint32(i))
+ }
+
+ p := New(comparer.DefaultComparer, 0)
+ for i := range buf {
+ p.Put(buf[i][:], nil)
+ }
+
+ b.ResetTimer()
+ for i := 0; i < b.N; i++ {
+ p.Get(buf[rand.Int()%b.N][:])
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/memdb/memdb.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/memdb/memdb.go
new file mode 100644
index 000000000..7bcae992a
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/memdb/memdb.go
@@ -0,0 +1,450 @@
+// Copyright (c) 2012, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Package memdb provides in-memory key/value database implementation.
+package memdb
+
+import (
+ "math/rand"
+ "sync"
+
+ "github.com/syndtr/goleveldb/leveldb/comparer"
+ "github.com/syndtr/goleveldb/leveldb/iterator"
+ "github.com/syndtr/goleveldb/leveldb/util"
+)
+
+var (
+ ErrNotFound = util.ErrNotFound
+)
+
+const tMaxHeight = 12
+
+type dbIter struct {
+ util.BasicReleaser
+ p *DB
+ slice *util.Range
+ node int
+ forward bool
+ key, value []byte
+}
+
+func (i *dbIter) fill(checkStart, checkLimit bool) bool {
+ if i.node != 0 {
+ n := i.p.nodeData[i.node]
+ m := n + i.p.nodeData[i.node+nKey]
+ i.key = i.p.kvData[n:m]
+ if i.slice != nil {
+ switch {
+ case checkLimit && i.slice.Limit != nil && i.p.cmp.Compare(i.key, i.slice.Limit) >= 0:
+ fallthrough
+ case checkStart && i.slice.Start != nil && i.p.cmp.Compare(i.key, i.slice.Start) < 0:
+ i.node = 0
+ goto bail
+ }
+ }
+ i.value = i.p.kvData[m : m+i.p.nodeData[i.node+nVal]]
+ return true
+ }
+bail:
+ i.key = nil
+ i.value = nil
+ return false
+}
+
+func (i *dbIter) Valid() bool {
+ return i.node != 0
+}
+
+func (i *dbIter) First() bool {
+ i.forward = true
+ i.p.mu.RLock()
+ defer i.p.mu.RUnlock()
+ if i.slice != nil && i.slice.Start != nil {
+ i.node, _ = i.p.findGE(i.slice.Start, false)
+ } else {
+ i.node = i.p.nodeData[nNext]
+ }
+ return i.fill(false, true)
+}
+
+func (i *dbIter) Last() bool {
+ if i.p == nil {
+ return false
+ }
+ i.forward = false
+ i.p.mu.RLock()
+ defer i.p.mu.RUnlock()
+ if i.slice != nil && i.slice.Limit != nil {
+ i.node = i.p.findLT(i.slice.Limit)
+ } else {
+ i.node = i.p.findLast()
+ }
+ return i.fill(true, false)
+}
+
+func (i *dbIter) Seek(key []byte) bool {
+ if i.p == nil {
+ return false
+ }
+ i.forward = true
+ i.p.mu.RLock()
+ defer i.p.mu.RUnlock()
+ if i.slice != nil && i.slice.Start != nil && i.p.cmp.Compare(key, i.slice.Start) < 0 {
+ key = i.slice.Start
+ }
+ i.node, _ = i.p.findGE(key, false)
+ return i.fill(false, true)
+}
+
+func (i *dbIter) Next() bool {
+ if i.p == nil {
+ return false
+ }
+ if i.node == 0 {
+ if !i.forward {
+ return i.First()
+ }
+ return false
+ }
+ i.forward = true
+ i.p.mu.RLock()
+ defer i.p.mu.RUnlock()
+ i.node = i.p.nodeData[i.node+nNext]
+ return i.fill(false, true)
+}
+
+func (i *dbIter) Prev() bool {
+ if i.p == nil {
+ return false
+ }
+ if i.node == 0 {
+ if i.forward {
+ return i.Last()
+ }
+ return false
+ }
+ i.forward = false
+ i.p.mu.RLock()
+ defer i.p.mu.RUnlock()
+ i.node = i.p.findLT(i.key)
+ return i.fill(true, false)
+}
+
+func (i *dbIter) Key() []byte {
+ return i.key
+}
+
+func (i *dbIter) Value() []byte {
+ return i.value
+}
+
+func (i *dbIter) Error() error { return nil }
+
+func (i *dbIter) Release() {
+ if i.p != nil {
+ i.p = nil
+ i.node = 0
+ i.key = nil
+ i.value = nil
+ i.BasicReleaser.Release()
+ }
+}
+
+const (
+ nKV = iota
+ nKey
+ nVal
+ nHeight
+ nNext
+)
+
+// DB is an in-memory key/value database.
+type DB struct {
+ cmp comparer.BasicComparer
+ rnd *rand.Rand
+
+ mu sync.RWMutex
+ kvData []byte
+ // Node data:
+ // [0] : KV offset
+ // [1] : Key length
+ // [2] : Value length
+ // [3] : Height
+ // [3..height] : Next nodes
+ nodeData []int
+ prevNode [tMaxHeight]int
+ maxHeight int
+ n int
+ kvSize int
+}
+
+func (p *DB) randHeight() (h int) {
+ const branching = 4
+ h = 1
+ for h < tMaxHeight && p.rnd.Int()%branching == 0 {
+ h++
+ }
+ return
+}
+
+func (p *DB) findGE(key []byte, prev bool) (int, bool) {
+ node := 0
+ h := p.maxHeight - 1
+ for {
+ next := p.nodeData[node+nNext+h]
+ cmp := 1
+ if next != 0 {
+ o := p.nodeData[next]
+ cmp = p.cmp.Compare(p.kvData[o:o+p.nodeData[next+nKey]], key)
+ }
+ if cmp < 0 {
+ // Keep searching in this list
+ node = next
+ } else {
+ if prev {
+ p.prevNode[h] = node
+ } else if cmp == 0 {
+ return next, true
+ }
+ if h == 0 {
+ return next, cmp == 0
+ }
+ h--
+ }
+ }
+}
+
+func (p *DB) findLT(key []byte) int {
+ node := 0
+ h := p.maxHeight - 1
+ for {
+ next := p.nodeData[node+nNext+h]
+ o := p.nodeData[next]
+ if next == 0 || p.cmp.Compare(p.kvData[o:o+p.nodeData[next+nKey]], key) >= 0 {
+ if h == 0 {
+ break
+ }
+ h--
+ } else {
+ node = next
+ }
+ }
+ return node
+}
+
+func (p *DB) findLast() int {
+ node := 0
+ h := p.maxHeight - 1
+ for {
+ next := p.nodeData[node+nNext+h]
+ if next == 0 {
+ if h == 0 {
+ break
+ }
+ h--
+ } else {
+ node = next
+ }
+ }
+ return node
+}
+
+// Put sets the value for the given key. It overwrites any previous value
+// for that key; a DB is not a multi-map.
+//
+// It is safe to modify the contents of the arguments after Put returns.
+func (p *DB) Put(key []byte, value []byte) error {
+ p.mu.Lock()
+ defer p.mu.Unlock()
+
+ if node, exact := p.findGE(key, true); exact {
+ kvOffset := len(p.kvData)
+ p.kvData = append(p.kvData, key...)
+ p.kvData = append(p.kvData, value...)
+ p.nodeData[node] = kvOffset
+ m := p.nodeData[node+nVal]
+ p.nodeData[node+nVal] = len(value)
+ p.kvSize += len(value) - m
+ return nil
+ }
+
+ h := p.randHeight()
+ if h > p.maxHeight {
+ for i := p.maxHeight; i < h; i++ {
+ p.prevNode[i] = 0
+ }
+ p.maxHeight = h
+ }
+
+ kvOffset := len(p.kvData)
+ p.kvData = append(p.kvData, key...)
+ p.kvData = append(p.kvData, value...)
+ // Node
+ node := len(p.nodeData)
+ p.nodeData = append(p.nodeData, kvOffset, len(key), len(value), h)
+ for i, n := range p.prevNode[:h] {
+ m := n + 4 + i
+ p.nodeData = append(p.nodeData, p.nodeData[m])
+ p.nodeData[m] = node
+ }
+
+ p.kvSize += len(key) + len(value)
+ p.n++
+ return nil
+}
+
+// Delete deletes the value for the given key. It returns ErrNotFound if
+// the DB does not contain the key.
+//
+// It is safe to modify the contents of the arguments after Delete returns.
+func (p *DB) Delete(key []byte) error {
+ p.mu.Lock()
+ defer p.mu.Unlock()
+
+ node, exact := p.findGE(key, true)
+ if !exact {
+ return ErrNotFound
+ }
+
+ h := p.nodeData[node+nHeight]
+ for i, n := range p.prevNode[:h] {
+ m := n + 4 + i
+ p.nodeData[m] = p.nodeData[p.nodeData[m]+nNext+i]
+ }
+
+ p.kvSize -= p.nodeData[node+nKey] + p.nodeData[node+nVal]
+ p.n--
+ return nil
+}
+
+// Contains returns true if the given key are in the DB.
+//
+// It is safe to modify the contents of the arguments after Contains returns.
+func (p *DB) Contains(key []byte) bool {
+ p.mu.RLock()
+ _, exact := p.findGE(key, false)
+ p.mu.RUnlock()
+ return exact
+}
+
+// Get gets the value for the given key. It returns error.ErrNotFound if the
+// DB does not contain the key.
+//
+// The caller should not modify the contents of the returned slice, but
+// it is safe to modify the contents of the argument after Get returns.
+func (p *DB) Get(key []byte) (value []byte, err error) {
+ p.mu.RLock()
+ if node, exact := p.findGE(key, false); exact {
+ o := p.nodeData[node] + p.nodeData[node+nKey]
+ value = p.kvData[o : o+p.nodeData[node+nVal]]
+ } else {
+ err = ErrNotFound
+ }
+ p.mu.RUnlock()
+ return
+}
+
+// Find finds key/value pair whose key is greater than or equal to the
+// given key. It returns ErrNotFound if the table doesn't contain
+// such pair.
+//
+// The caller should not modify the contents of the returned slice, but
+// it is safe to modify the contents of the argument after Find returns.
+func (p *DB) Find(key []byte) (rkey, value []byte, err error) {
+ p.mu.RLock()
+ if node, _ := p.findGE(key, false); node != 0 {
+ n := p.nodeData[node]
+ m := n + p.nodeData[node+nKey]
+ rkey = p.kvData[n:m]
+ value = p.kvData[m : m+p.nodeData[node+nVal]]
+ } else {
+ err = ErrNotFound
+ }
+ p.mu.RUnlock()
+ return
+}
+
+// NewIterator returns an iterator of the DB.
+// The returned iterator is not goroutine-safe, but it is safe to use
+// multiple iterators concurrently, with each in a dedicated goroutine.
+// It is also safe to use an iterator concurrently with modifying its
+// underlying DB. However, the resultant key/value pairs are not guaranteed
+// to be a consistent snapshot of the DB at a particular point in time.
+//
+// Slice allows slicing the iterator to only contains keys in the given
+// range. A nil Range.Start is treated as a key before all keys in the
+// DB. And a nil Range.Limit is treated as a key after all keys in
+// the DB.
+//
+// The iterator must be released after use, by calling Release method.
+//
+// Also read Iterator documentation of the leveldb/iterator package.
+func (p *DB) NewIterator(slice *util.Range) iterator.Iterator {
+ return &dbIter{p: p, slice: slice}
+}
+
+// Capacity returns keys/values buffer capacity.
+func (p *DB) Capacity() int {
+ p.mu.RLock()
+ defer p.mu.RUnlock()
+ return cap(p.kvData)
+}
+
+// Size returns sum of keys and values length. Note that deleted
+// key/value will not be accouted for, but it will still consume
+// the buffer, since the buffer is append only.
+func (p *DB) Size() int {
+ p.mu.RLock()
+ defer p.mu.RUnlock()
+ return p.kvSize
+}
+
+// Free returns keys/values free buffer before need to grow.
+func (p *DB) Free() int {
+ p.mu.RLock()
+ defer p.mu.RUnlock()
+ return cap(p.kvData) - len(p.kvData)
+}
+
+// Len returns the number of entries in the DB.
+func (p *DB) Len() int {
+ p.mu.RLock()
+ defer p.mu.RUnlock()
+ return p.n
+}
+
+// Reset resets the DB to initial empty state. Allows reuse the buffer.
+func (p *DB) Reset() {
+ p.rnd = rand.New(rand.NewSource(0xdeadbeef))
+ p.maxHeight = 1
+ p.n = 0
+ p.kvSize = 0
+ p.kvData = p.kvData[:0]
+ p.nodeData = p.nodeData[:4+tMaxHeight]
+ p.nodeData[nKV] = 0
+ p.nodeData[nKey] = 0
+ p.nodeData[nVal] = 0
+ p.nodeData[nHeight] = tMaxHeight
+ for n := 0; n < tMaxHeight; n++ {
+ p.nodeData[4+n] = 0
+ p.prevNode[n] = 0
+ }
+}
+
+// New creates a new initalized in-memory key/value DB. The capacity
+// is the initial key/value buffer capacity. The capacity is advisory,
+// not enforced.
+func New(cmp comparer.BasicComparer, capacity int) *DB {
+ p := &DB{
+ cmp: cmp,
+ rnd: rand.New(rand.NewSource(0xdeadbeef)),
+ maxHeight: 1,
+ kvData: make([]byte, 0, capacity),
+ nodeData: make([]int, 4+tMaxHeight),
+ }
+ p.nodeData[nHeight] = tMaxHeight
+ return p
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/memdb/memdb_suite_test.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/memdb/memdb_suite_test.go
new file mode 100644
index 000000000..788539a87
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/memdb/memdb_suite_test.go
@@ -0,0 +1,17 @@
+package memdb
+
+import (
+ "testing"
+
+ . "github.com/onsi/ginkgo"
+ . "github.com/onsi/gomega"
+
+ "github.com/syndtr/goleveldb/leveldb/testutil"
+)
+
+func TestMemdb(t *testing.T) {
+ testutil.RunDefer()
+
+ RegisterFailHandler(Fail)
+ RunSpecs(t, "Memdb Suite")
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/memdb/memdb_test.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/memdb/memdb_test.go
new file mode 100644
index 000000000..f96a9d1ea
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/memdb/memdb_test.go
@@ -0,0 +1,135 @@
+// Copyright (c) 2014, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package memdb
+
+import (
+ . "github.com/onsi/ginkgo"
+ . "github.com/onsi/gomega"
+
+ "github.com/syndtr/goleveldb/leveldb/comparer"
+ "github.com/syndtr/goleveldb/leveldb/iterator"
+ "github.com/syndtr/goleveldb/leveldb/testutil"
+ "github.com/syndtr/goleveldb/leveldb/util"
+)
+
+func (p *DB) TestFindLT(key []byte) (rkey, value []byte, err error) {
+ p.mu.RLock()
+ if node := p.findLT(key); node != 0 {
+ n := p.nodeData[node]
+ m := n + p.nodeData[node+nKey]
+ rkey = p.kvData[n:m]
+ value = p.kvData[m : m+p.nodeData[node+nVal]]
+ } else {
+ err = ErrNotFound
+ }
+ p.mu.RUnlock()
+ return
+}
+
+func (p *DB) TestFindLast() (rkey, value []byte, err error) {
+ p.mu.RLock()
+ if node := p.findLast(); node != 0 {
+ n := p.nodeData[node]
+ m := n + p.nodeData[node+nKey]
+ rkey = p.kvData[n:m]
+ value = p.kvData[m : m+p.nodeData[node+nVal]]
+ } else {
+ err = ErrNotFound
+ }
+ p.mu.RUnlock()
+ return
+}
+
+func (p *DB) TestPut(key []byte, value []byte) error {
+ p.Put(key, value)
+ return nil
+}
+
+func (p *DB) TestDelete(key []byte) error {
+ p.Delete(key)
+ return nil
+}
+
+func (p *DB) TestFind(key []byte) (rkey, rvalue []byte, err error) {
+ return p.Find(key)
+}
+
+func (p *DB) TestGet(key []byte) (value []byte, err error) {
+ return p.Get(key)
+}
+
+func (p *DB) TestNewIterator(slice *util.Range) iterator.Iterator {
+ return p.NewIterator(slice)
+}
+
+var _ = testutil.Defer(func() {
+ Describe("Memdb", func() {
+ Describe("write test", func() {
+ It("should do write correctly", func() {
+ db := New(comparer.DefaultComparer, 0)
+ t := testutil.DBTesting{
+ DB: db,
+ Deleted: testutil.KeyValue_Generate(nil, 1000, 1, 30, 5, 5).Clone(),
+ PostFn: func(t *testutil.DBTesting) {
+ Expect(db.Len()).Should(Equal(t.Present.Len()))
+ Expect(db.Size()).Should(Equal(t.Present.Size()))
+ switch t.Act {
+ case testutil.DBPut, testutil.DBOverwrite:
+ Expect(db.Contains(t.ActKey)).Should(BeTrue())
+ default:
+ Expect(db.Contains(t.ActKey)).Should(BeFalse())
+ }
+ },
+ }
+ testutil.DoDBTesting(&t)
+ })
+ })
+
+ Describe("read test", func() {
+ testutil.AllKeyValueTesting(nil, func(kv testutil.KeyValue) testutil.DB {
+ // Building the DB.
+ db := New(comparer.DefaultComparer, 0)
+ kv.IterateShuffled(nil, func(i int, key, value []byte) {
+ db.Put(key, value)
+ })
+
+ if kv.Len() > 1 {
+ It("Should find correct keys with findLT", func() {
+ testutil.ShuffledIndex(nil, kv.Len()-1, 1, func(i int) {
+ key_, key, _ := kv.IndexInexact(i + 1)
+ expectedKey, expectedValue := kv.Index(i)
+
+ // Using key that exist.
+ rkey, rvalue, err := db.TestFindLT(key)
+ Expect(err).ShouldNot(HaveOccurred(), "Error for key %q -> %q", key, expectedKey)
+ Expect(rkey).Should(Equal(expectedKey), "Key")
+ Expect(rvalue).Should(Equal(expectedValue), "Value for key %q -> %q", key, expectedKey)
+
+ // Using key that doesn't exist.
+ rkey, rvalue, err = db.TestFindLT(key_)
+ Expect(err).ShouldNot(HaveOccurred(), "Error for key %q (%q) -> %q", key_, key, expectedKey)
+ Expect(rkey).Should(Equal(expectedKey))
+ Expect(rvalue).Should(Equal(expectedValue), "Value for key %q (%q) -> %q", key_, key, expectedKey)
+ })
+ })
+ }
+
+ if kv.Len() > 0 {
+ It("Should find last key with findLast", func() {
+ key, value := kv.Index(kv.Len() - 1)
+ rkey, rvalue, err := db.TestFindLast()
+ Expect(err).ShouldNot(HaveOccurred())
+ Expect(rkey).Should(Equal(key))
+ Expect(rvalue).Should(Equal(value))
+ })
+ }
+
+ return db
+ })
+ })
+ })
+})
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/opt/options.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/opt/options.go
new file mode 100644
index 000000000..b940ce427
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/opt/options.go
@@ -0,0 +1,318 @@
+// Copyright (c) 2012, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Package opt provides sets of options used by LevelDB.
+package opt
+
+import (
+ "github.com/syndtr/goleveldb/leveldb/cache"
+ "github.com/syndtr/goleveldb/leveldb/comparer"
+ "github.com/syndtr/goleveldb/leveldb/filter"
+)
+
+const (
+ KiB = 1024
+ MiB = KiB * 1024
+ GiB = MiB * 1024
+)
+
+const (
+ DefaultBlockCacheSize = 8 * MiB
+ DefaultBlockRestartInterval = 16
+ DefaultBlockSize = 4 * KiB
+ DefaultCompressionType = SnappyCompression
+ DefaultMaxOpenFiles = 1000
+ DefaultWriteBuffer = 4 * MiB
+)
+
+type noCache struct{}
+
+func (noCache) SetCapacity(capacity int) {}
+func (noCache) GetNamespace(id uint64) cache.Namespace { return nil }
+func (noCache) Purge(fin cache.PurgeFin) {}
+func (noCache) Zap(closed bool) {}
+
+var NoCache cache.Cache = noCache{}
+
+// Compression is the per-block compression algorithm to use.
+type Compression uint
+
+func (c Compression) String() string {
+ switch c {
+ case DefaultCompression:
+ return "default"
+ case NoCompression:
+ return "none"
+ case SnappyCompression:
+ return "snappy"
+ }
+ return "invalid"
+}
+
+const (
+ DefaultCompression Compression = iota
+ NoCompression
+ SnappyCompression
+ nCompression
+)
+
+// Strict is the DB strict level.
+type Strict uint
+
+const (
+ // If present then a corrupted or invalid chunk or block in manifest
+ // journal will cause an error istead of being dropped.
+ StrictManifest Strict = 1 << iota
+
+ // If present then a corrupted or invalid chunk or block in journal
+ // will cause an error istead of being dropped.
+ StrictJournal
+
+ // If present then journal chunk checksum will be verified.
+ StrictJournalChecksum
+
+ // If present then an invalid key/value pair will cause an error
+ // instead of being skipped.
+ StrictIterator
+
+ // If present then 'sorted table' block checksum will be verified.
+ StrictBlockChecksum
+
+ // StrictAll enables all strict flags.
+ StrictAll = StrictManifest | StrictJournal | StrictJournalChecksum | StrictIterator | StrictBlockChecksum
+
+ // DefaultStrict is the default strict flags. Specify any strict flags
+ // will override default strict flags as whole (i.e. not OR'ed).
+ DefaultStrict = StrictJournalChecksum | StrictBlockChecksum
+
+ // NoStrict disables all strict flags. Override default strict flags.
+ NoStrict = ^StrictAll
+)
+
+// Options holds the optional parameters for the DB at large.
+type Options struct {
+ // AltFilters defines one or more 'alternative filters'.
+ // 'alternative filters' will be used during reads if a filter block
+ // does not match with the 'effective filter'.
+ //
+ // The default value is nil
+ AltFilters []filter.Filter
+
+ // BlockCache provides per-block caching for LevelDB. Specify NoCache to
+ // disable block caching.
+ //
+ // By default LevelDB will create LRU-cache with capacity of 8MiB.
+ BlockCache cache.Cache
+
+ // BlockRestartInterval is the number of keys between restart points for
+ // delta encoding of keys.
+ //
+ // The default value is 16.
+ BlockRestartInterval int
+
+ // BlockSize is the minimum uncompressed size in bytes of each 'sorted table'
+ // block.
+ //
+ // The default value is 4KiB.
+ BlockSize int
+
+ // Comparer defines a total ordering over the space of []byte keys: a 'less
+ // than' relationship. The same comparison algorithm must be used for reads
+ // and writes over the lifetime of the DB.
+ //
+ // The default value uses the same ordering as bytes.Compare.
+ Comparer comparer.Comparer
+
+ // Compression defines the per-block compression to use.
+ //
+ // The default value (DefaultCompression) uses snappy compression.
+ Compression Compression
+
+ // ErrorIfExist defines whether an error should returned if the DB already
+ // exist.
+ //
+ // The default value is false.
+ ErrorIfExist bool
+
+ // ErrorIfMissing defines whether an error should returned if the DB is
+ // missing. If false then the database will be created if missing, otherwise
+ // an error will be returned.
+ //
+ // The default value is false.
+ ErrorIfMissing bool
+
+ // Filter defines an 'effective filter' to use. An 'effective filter'
+ // if defined will be used to generate per-table filter block.
+ // The filter name will be stored on disk.
+ // During reads LevelDB will try to find matching filter from
+ // 'effective filter' and 'alternative filters'.
+ //
+ // Filter can be changed after a DB has been created. It is recommended
+ // to put old filter to the 'alternative filters' to mitigate lack of
+ // filter during transition period.
+ //
+ // A filter is used to reduce disk reads when looking for a specific key.
+ //
+ // The default value is nil.
+ Filter filter.Filter
+
+ // MaxOpenFiles defines maximum number of open files to kept around
+ // (cached). This is not an hard limit, actual open files may exceed
+ // the defined value.
+ //
+ // The default value is 1000.
+ MaxOpenFiles int
+
+ // Strict defines the DB strict level.
+ Strict Strict
+
+ // WriteBuffer defines maximum size of a 'memdb' before flushed to
+ // 'sorted table'. 'memdb' is an in-memory DB backed by an on-disk
+ // unsorted journal.
+ //
+ // LevelDB may held up to two 'memdb' at the same time.
+ //
+ // The default value is 4MiB.
+ WriteBuffer int
+}
+
+func (o *Options) GetAltFilters() []filter.Filter {
+ if o == nil {
+ return nil
+ }
+ return o.AltFilters
+}
+
+func (o *Options) GetBlockCache() cache.Cache {
+ if o == nil {
+ return nil
+ }
+ return o.BlockCache
+}
+
+func (o *Options) GetBlockRestartInterval() int {
+ if o == nil || o.BlockRestartInterval <= 0 {
+ return DefaultBlockRestartInterval
+ }
+ return o.BlockRestartInterval
+}
+
+func (o *Options) GetBlockSize() int {
+ if o == nil || o.BlockSize <= 0 {
+ return DefaultBlockSize
+ }
+ return o.BlockSize
+}
+
+func (o *Options) GetComparer() comparer.Comparer {
+ if o == nil || o.Comparer == nil {
+ return comparer.DefaultComparer
+ }
+ return o.Comparer
+}
+
+func (o *Options) GetCompression() Compression {
+ if o == nil || o.Compression <= DefaultCompression || o.Compression >= nCompression {
+ return DefaultCompressionType
+ }
+ return o.Compression
+}
+
+func (o *Options) GetErrorIfExist() bool {
+ if o == nil {
+ return false
+ }
+ return o.ErrorIfExist
+}
+
+func (o *Options) GetErrorIfMissing() bool {
+ if o == nil {
+ return false
+ }
+ return o.ErrorIfMissing
+}
+
+func (o *Options) GetFilter() filter.Filter {
+ if o == nil {
+ return nil
+ }
+ return o.Filter
+}
+
+func (o *Options) GetMaxOpenFiles() int {
+ if o == nil || o.MaxOpenFiles <= 0 {
+ return DefaultMaxOpenFiles
+ }
+ return o.MaxOpenFiles
+}
+
+func (o *Options) GetStrict(strict Strict) bool {
+ if o == nil || o.Strict == 0 {
+ return DefaultStrict&strict != 0
+ }
+ return o.Strict&strict != 0
+}
+
+func (o *Options) GetWriteBuffer() int {
+ if o == nil || o.WriteBuffer <= 0 {
+ return DefaultWriteBuffer
+ }
+ return o.WriteBuffer
+}
+
+// ReadOptions holds the optional parameters for 'read operation'. The
+// 'read operation' includes Get, Find and NewIterator.
+type ReadOptions struct {
+ // DontFillCache defines whether block reads for this 'read operation'
+ // should be cached. If false then the block will be cached. This does
+ // not affects already cached block.
+ //
+ // The default value is false.
+ DontFillCache bool
+
+ // Strict overrides global DB strict level. Only StrictIterator and
+ // StrictBlockChecksum that does have effects here.
+ Strict Strict
+}
+
+func (ro *ReadOptions) GetDontFillCache() bool {
+ if ro == nil {
+ return false
+ }
+ return ro.DontFillCache
+}
+
+func (ro *ReadOptions) GetStrict(strict Strict) bool {
+ if ro == nil {
+ return false
+ }
+ return ro.Strict&strict != 0
+}
+
+// WriteOptions holds the optional parameters for 'write operation'. The
+// 'write operation' includes Write, Put and Delete.
+type WriteOptions struct {
+ // Sync is whether to sync underlying writes from the OS buffer cache
+ // through to actual disk, if applicable. Setting Sync can result in
+ // slower writes.
+ //
+ // If false, and the machine crashes, then some recent writes may be lost.
+ // Note that if it is just the process that crashes (and the machine does
+ // not) then no writes will be lost.
+ //
+ // In other words, Sync being false has the same semantics as a write
+ // system call. Sync being true means write followed by fsync.
+ //
+ // The default value is false.
+ Sync bool
+}
+
+func (wo *WriteOptions) GetSync() bool {
+ if wo == nil {
+ return false
+ }
+ return wo.Sync
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/options.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/options.go
new file mode 100644
index 000000000..fc6a96965
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/options.go
@@ -0,0 +1,41 @@
+// Copyright (c) 2012, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package leveldb
+
+import (
+ "github.com/syndtr/goleveldb/leveldb/cache"
+ "github.com/syndtr/goleveldb/leveldb/filter"
+ "github.com/syndtr/goleveldb/leveldb/opt"
+)
+
+func (s *session) setOptions(o *opt.Options) {
+ s.o = &opt.Options{}
+ if o != nil {
+ *s.o = *o
+ }
+ // Alternative filters.
+ if filters := o.GetAltFilters(); len(filters) > 0 {
+ s.o.AltFilters = make([]filter.Filter, len(filters))
+ for i, filter := range filters {
+ s.o.AltFilters[i] = &iFilter{filter}
+ }
+ }
+ // Block cache.
+ switch o.GetBlockCache() {
+ case nil:
+ s.o.BlockCache = cache.NewLRUCache(opt.DefaultBlockCacheSize)
+ case opt.NoCache:
+ s.o.BlockCache = nil
+ }
+ // Comparer.
+ s.icmp = &iComparer{o.GetComparer()}
+ s.o.Comparer = s.icmp
+ // Filter.
+ if filter := o.GetFilter(); filter != nil {
+ s.o.Filter = &iFilter{filter}
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/session.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/session.go
new file mode 100644
index 000000000..6b2a61683
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/session.go
@@ -0,0 +1,403 @@
+// Copyright (c) 2012, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package leveldb
+
+import (
+ "errors"
+ "io"
+ "os"
+ "sync"
+ "sync/atomic"
+
+ "github.com/syndtr/goleveldb/leveldb/iterator"
+ "github.com/syndtr/goleveldb/leveldb/journal"
+ "github.com/syndtr/goleveldb/leveldb/opt"
+ "github.com/syndtr/goleveldb/leveldb/storage"
+ "github.com/syndtr/goleveldb/leveldb/util"
+)
+
+// session represent a persistent database session.
+type session struct {
+ // Need 64-bit alignment.
+ stFileNum uint64 // current unused file number
+ stJournalNum uint64 // current journal file number; need external synchronization
+ stPrevJournalNum uint64 // prev journal file number; no longer used; for compatibility with older version of leveldb
+ stSeq uint64 // last mem compacted seq; need external synchronization
+ stTempFileNum uint64
+
+ stor storage.Storage
+ storLock util.Releaser
+ o *opt.Options
+ icmp *iComparer
+ tops *tOps
+
+ manifest *journal.Writer
+ manifestWriter storage.Writer
+ manifestFile storage.File
+
+ stCPtrs [kNumLevels]iKey // compact pointers; need external synchronization
+ stVersion *version // current version
+ vmu sync.Mutex
+}
+
+func newSession(stor storage.Storage, o *opt.Options) (s *session, err error) {
+ if stor == nil {
+ return nil, os.ErrInvalid
+ }
+ storLock, err := stor.Lock()
+ if err != nil {
+ return
+ }
+ s = &session{
+ stor: stor,
+ storLock: storLock,
+ }
+ s.setOptions(o)
+ s.tops = newTableOps(s, s.o.GetMaxOpenFiles())
+ s.setVersion(&version{s: s})
+ s.log("log@legend F·NumFile S·FileSize N·Entry C·BadEntry B·BadBlock D·DeletedEntry L·Level Q·SeqNum T·TimeElapsed")
+ return
+}
+
+// Close session.
+func (s *session) close() {
+ s.tops.close()
+ if bc := s.o.GetBlockCache(); bc != nil {
+ bc.Purge(nil)
+ }
+ if s.manifest != nil {
+ s.manifest.Close()
+ }
+ if s.manifestWriter != nil {
+ s.manifestWriter.Close()
+ }
+ s.manifest = nil
+ s.manifestWriter = nil
+ s.manifestFile = nil
+ s.stVersion = nil
+}
+
+func (s *session) release() {
+ s.storLock.Release()
+}
+
+// Create a new database session; need external synchronization.
+func (s *session) create() error {
+ // create manifest
+ return s.newManifest(nil, nil)
+}
+
+// Recover a database session; need external synchronization.
+func (s *session) recover() (err error) {
+ defer func() {
+ if os.IsNotExist(err) {
+ // Don't return os.ErrNotExist if the underlying storage contains
+ // other files that belong to LevelDB. So the DB won't get trashed.
+ if files, _ := s.stor.GetFiles(storage.TypeAll); len(files) > 0 {
+ err = ErrCorrupted{Type: CorruptedManifest, Err: errors.New("leveldb: manifest file missing")}
+ }
+ }
+ }()
+
+ file, err := s.stor.GetManifest()
+ if err != nil {
+ return
+ }
+
+ reader, err := file.Open()
+ if err != nil {
+ return
+ }
+ defer reader.Close()
+ strict := s.o.GetStrict(opt.StrictManifest)
+ jr := journal.NewReader(reader, dropper{s, file}, strict, true)
+
+ staging := s.version_NB().newStaging()
+ rec := &sessionRecord{}
+ for {
+ var r io.Reader
+ r, err = jr.Next()
+ if err != nil {
+ if err == io.EOF {
+ err = nil
+ break
+ }
+ return
+ }
+
+ err = rec.decode(r)
+ if err == nil {
+ // save compact pointers
+ for _, rp := range rec.compactionPointers {
+ s.stCPtrs[rp.level] = iKey(rp.key)
+ }
+ // commit record to version staging
+ staging.commit(rec)
+ } else if strict {
+ return ErrCorrupted{Type: CorruptedManifest, Err: err}
+ } else {
+ s.logf("manifest error: %v (skipped)", err)
+ }
+ rec.resetCompactionPointers()
+ rec.resetAddedTables()
+ rec.resetDeletedTables()
+ }
+
+ switch {
+ case !rec.has(recComparer):
+ return ErrCorrupted{Type: CorruptedManifest, Err: errors.New("leveldb: manifest missing comparer name")}
+ case rec.comparer != s.icmp.uName():
+ return ErrCorrupted{Type: CorruptedManifest, Err: errors.New("leveldb: comparer mismatch, " + "want '" + s.icmp.uName() + "', " + "got '" + rec.comparer + "'")}
+ case !rec.has(recNextNum):
+ return ErrCorrupted{Type: CorruptedManifest, Err: errors.New("leveldb: manifest missing next file number")}
+ case !rec.has(recJournalNum):
+ return ErrCorrupted{Type: CorruptedManifest, Err: errors.New("leveldb: manifest missing journal file number")}
+ case !rec.has(recSeq):
+ return ErrCorrupted{Type: CorruptedManifest, Err: errors.New("leveldb: manifest missing seq number")}
+ }
+
+ s.manifestFile = file
+ s.setVersion(staging.finish())
+ s.setFileNum(rec.nextNum)
+ s.recordCommited(rec)
+ return nil
+}
+
+// Commit session; need external synchronization.
+func (s *session) commit(r *sessionRecord) (err error) {
+ // spawn new version based on current version
+ nv := s.version_NB().spawn(r)
+
+ if s.manifest == nil {
+ // manifest journal writer not yet created, create one
+ err = s.newManifest(r, nv)
+ } else {
+ err = s.flushManifest(r)
+ }
+
+ // finally, apply new version if no error rise
+ if err == nil {
+ s.setVersion(nv)
+ }
+
+ return
+}
+
+// Pick a compaction based on current state; need external synchronization.
+func (s *session) pickCompaction() *compaction {
+ v := s.version_NB()
+
+ var level int
+ var t0 tFiles
+ if v.cScore >= 1 {
+ level = v.cLevel
+ cp := s.stCPtrs[level]
+ tt := v.tables[level]
+ for _, t := range tt {
+ if cp == nil || s.icmp.Compare(t.max, cp) > 0 {
+ t0 = append(t0, t)
+ break
+ }
+ }
+ if len(t0) == 0 {
+ t0 = append(t0, tt[0])
+ }
+ } else {
+ if p := atomic.LoadPointer(&v.cSeek); p != nil {
+ ts := (*tSet)(p)
+ level = ts.level
+ t0 = append(t0, ts.table)
+ } else {
+ return nil
+ }
+ }
+
+ c := &compaction{s: s, version: v, level: level}
+ if level == 0 {
+ min, max := t0.getRange(s.icmp)
+ t0 = nil
+ v.tables[0].getOverlaps(min.ukey(), max.ukey(), &t0, false, s.icmp.ucmp)
+ }
+
+ c.tables[0] = t0
+ c.expand()
+ return c
+}
+
+// Create compaction from given level and range; need external synchronization.
+func (s *session) getCompactionRange(level int, min, max []byte) *compaction {
+ v := s.version_NB()
+
+ var t0 tFiles
+ v.tables[level].getOverlaps(min, max, &t0, level != 0, s.icmp.ucmp)
+ if len(t0) == 0 {
+ return nil
+ }
+
+ // Avoid compacting too much in one shot in case the range is large.
+ // But we cannot do this for level-0 since level-0 files can overlap
+ // and we must not pick one file and drop another older file if the
+ // two files overlap.
+ if level > 0 {
+ limit := uint64(kMaxTableSize)
+ total := uint64(0)
+ for i, t := range t0 {
+ total += t.size
+ if total >= limit {
+ s.logf("table@compaction limiting F·%d -> F·%d", len(t0), i+1)
+ t0 = t0[:i+1]
+ break
+ }
+ }
+ }
+
+ c := &compaction{s: s, version: v, level: level}
+ c.tables[0] = t0
+ c.expand()
+ return c
+}
+
+// compaction represent a compaction state
+type compaction struct {
+ s *session
+ version *version
+
+ level int
+ tables [2]tFiles
+
+ gp tFiles
+ gpidx int
+ seenKey bool
+ overlappedBytes uint64
+ min, max iKey
+
+ tPtrs [kNumLevels]int
+}
+
+// Expand compacted tables; need external synchronization.
+func (c *compaction) expand() {
+ s := c.s
+ v := c.version
+
+ level := c.level
+ vt0, vt1 := v.tables[level], v.tables[level+1]
+
+ t0, t1 := c.tables[0], c.tables[1]
+ min, max := t0.getRange(s.icmp)
+ vt1.getOverlaps(min.ukey(), max.ukey(), &t1, true, s.icmp.ucmp)
+
+ // Get entire range covered by compaction
+ amin, amax := append(t0, t1...).getRange(s.icmp)
+
+ // See if we can grow the number of inputs in "level" without
+ // changing the number of "level+1" files we pick up.
+ if len(t1) > 0 {
+ var exp0 tFiles
+ vt0.getOverlaps(amin.ukey(), amax.ukey(), &exp0, level != 0, s.icmp.ucmp)
+ if len(exp0) > len(t0) && t1.size()+exp0.size() < kExpCompactionMaxBytes {
+ var exp1 tFiles
+ xmin, xmax := exp0.getRange(s.icmp)
+ vt1.getOverlaps(xmin.ukey(), xmax.ukey(), &exp1, true, s.icmp.ucmp)
+ if len(exp1) == len(t1) {
+ s.logf("table@compaction expanding L%d+L%d (F·%d S·%s)+(F·%d S·%s) -> (F·%d S·%s)+(F·%d S·%s)",
+ level, level+1, len(t0), shortenb(int(t0.size())), len(t1), shortenb(int(t1.size())),
+ len(exp0), shortenb(int(exp0.size())), len(exp1), shortenb(int(exp1.size())))
+ min, max = xmin, xmax
+ t0, t1 = exp0, exp1
+ amin, amax = append(t0, t1...).getRange(s.icmp)
+ }
+ }
+ }
+
+ // Compute the set of grandparent files that overlap this compaction
+ // (parent == level+1; grandparent == level+2)
+ if level+2 < kNumLevels {
+ v.tables[level+2].getOverlaps(amin.ukey(), amax.ukey(), &c.gp, true, s.icmp.ucmp)
+ }
+
+ c.tables[0], c.tables[1] = t0, t1
+ c.min, c.max = min, max
+}
+
+// Check whether compaction is trivial.
+func (c *compaction) trivial() bool {
+ return len(c.tables[0]) == 1 && len(c.tables[1]) == 0 && c.gp.size() <= kMaxGrandParentOverlapBytes
+}
+
+func (c *compaction) isBaseLevelForKey(key []byte) bool {
+ s := c.s
+ v := c.version
+
+ for level, tt := range v.tables[c.level+2:] {
+ for c.tPtrs[level] < len(tt) {
+ t := tt[c.tPtrs[level]]
+ if s.icmp.uCompare(key, t.max.ukey()) <= 0 {
+ // We've advanced far enough
+ if s.icmp.uCompare(key, t.min.ukey()) >= 0 {
+ // Key falls in this file's range, so definitely not base level
+ return false
+ }
+ break
+ }
+ c.tPtrs[level]++
+ }
+ }
+ return true
+}
+
+func (c *compaction) shouldStopBefore(key iKey) bool {
+ for ; c.gpidx < len(c.gp); c.gpidx++ {
+ gp := c.gp[c.gpidx]
+ if c.s.icmp.Compare(key, gp.max) <= 0 {
+ break
+ }
+ if c.seenKey {
+ c.overlappedBytes += gp.size
+ }
+ }
+ c.seenKey = true
+
+ if c.overlappedBytes > kMaxGrandParentOverlapBytes {
+ // Too much overlap for current output; start new output
+ c.overlappedBytes = 0
+ return true
+ }
+ return false
+}
+
+func (c *compaction) newIterator() iterator.Iterator {
+ s := c.s
+
+ level := c.level
+ icap := 2
+ if c.level == 0 {
+ icap = len(c.tables[0]) + 1
+ }
+ its := make([]iterator.Iterator, 0, icap)
+
+ ro := &opt.ReadOptions{
+ DontFillCache: true,
+ }
+ strict := s.o.GetStrict(opt.StrictIterator)
+
+ for i, tt := range c.tables {
+ if len(tt) == 0 {
+ continue
+ }
+
+ if level+i == 0 {
+ for _, t := range tt {
+ its = append(its, s.tops.newIterator(t, nil, ro))
+ }
+ } else {
+ it := iterator.NewIndexedIterator(tt.newIndexIterator(s.tops, s.icmp, nil, ro), strict, true)
+ its = append(its, it)
+ }
+ }
+
+ return iterator.NewMergedIterator(its, s.icmp, true)
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/session_record.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/session_record.go
new file mode 100644
index 000000000..c50fda737
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/session_record.go
@@ -0,0 +1,308 @@
+// Copyright (c) 2012, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package leveldb
+
+import (
+ "bufio"
+ "encoding/binary"
+ "errors"
+ "io"
+)
+
+var errCorruptManifest = errors.New("leveldb: corrupt manifest")
+
+type byteReader interface {
+ io.Reader
+ io.ByteReader
+}
+
+// These numbers are written to disk and should not be changed.
+const (
+ recComparer = 1
+ recJournalNum = 2
+ recNextNum = 3
+ recSeq = 4
+ recCompactionPointer = 5
+ recDeletedTable = 6
+ recNewTable = 7
+ // 8 was used for large value refs
+ recPrevJournalNum = 9
+)
+
+type cpRecord struct {
+ level int
+ key iKey
+}
+
+type ntRecord struct {
+ level int
+ num uint64
+ size uint64
+ min iKey
+ max iKey
+}
+
+func (r ntRecord) makeFile(s *session) *tFile {
+ return newTFile(s.getTableFile(r.num), r.size, r.min, r.max)
+}
+
+type dtRecord struct {
+ level int
+ num uint64
+}
+
+type sessionRecord struct {
+ hasRec int
+ comparer string
+ journalNum uint64
+ prevJournalNum uint64
+ nextNum uint64
+ seq uint64
+ compactionPointers []cpRecord
+ addedTables []ntRecord
+ deletedTables []dtRecord
+ scratch [binary.MaxVarintLen64]byte
+ err error
+}
+
+func (p *sessionRecord) has(rec int) bool {
+ return p.hasRec&(1<<uint(rec)) != 0
+}
+
+func (p *sessionRecord) setComparer(name string) {
+ p.hasRec |= 1 << recComparer
+ p.comparer = name
+}
+
+func (p *sessionRecord) setJournalNum(num uint64) {
+ p.hasRec |= 1 << recJournalNum
+ p.journalNum = num
+}
+
+func (p *sessionRecord) setPrevJournalNum(num uint64) {
+ p.hasRec |= 1 << recPrevJournalNum
+ p.prevJournalNum = num
+}
+
+func (p *sessionRecord) setNextNum(num uint64) {
+ p.hasRec |= 1 << recNextNum
+ p.nextNum = num
+}
+
+func (p *sessionRecord) setSeq(seq uint64) {
+ p.hasRec |= 1 << recSeq
+ p.seq = seq
+}
+
+func (p *sessionRecord) addCompactionPointer(level int, key iKey) {
+ p.hasRec |= 1 << recCompactionPointer
+ p.compactionPointers = append(p.compactionPointers, cpRecord{level, key})
+}
+
+func (p *sessionRecord) resetCompactionPointers() {
+ p.hasRec &= ^(1 << recCompactionPointer)
+ p.compactionPointers = p.compactionPointers[:0]
+}
+
+func (p *sessionRecord) addTable(level int, num, size uint64, min, max iKey) {
+ p.hasRec |= 1 << recNewTable
+ p.addedTables = append(p.addedTables, ntRecord{level, num, size, min, max})
+}
+
+func (p *sessionRecord) addTableFile(level int, t *tFile) {
+ p.addTable(level, t.file.Num(), t.size, t.min, t.max)
+}
+
+func (p *sessionRecord) resetAddedTables() {
+ p.hasRec &= ^(1 << recNewTable)
+ p.addedTables = p.addedTables[:0]
+}
+
+func (p *sessionRecord) deleteTable(level int, num uint64) {
+ p.hasRec |= 1 << recDeletedTable
+ p.deletedTables = append(p.deletedTables, dtRecord{level, num})
+}
+
+func (p *sessionRecord) resetDeletedTables() {
+ p.hasRec &= ^(1 << recDeletedTable)
+ p.deletedTables = p.deletedTables[:0]
+}
+
+func (p *sessionRecord) putUvarint(w io.Writer, x uint64) {
+ if p.err != nil {
+ return
+ }
+ n := binary.PutUvarint(p.scratch[:], x)
+ _, p.err = w.Write(p.scratch[:n])
+}
+
+func (p *sessionRecord) putBytes(w io.Writer, x []byte) {
+ if p.err != nil {
+ return
+ }
+ p.putUvarint(w, uint64(len(x)))
+ if p.err != nil {
+ return
+ }
+ _, p.err = w.Write(x)
+}
+
+func (p *sessionRecord) encode(w io.Writer) error {
+ p.err = nil
+ if p.has(recComparer) {
+ p.putUvarint(w, recComparer)
+ p.putBytes(w, []byte(p.comparer))
+ }
+ if p.has(recJournalNum) {
+ p.putUvarint(w, recJournalNum)
+ p.putUvarint(w, p.journalNum)
+ }
+ if p.has(recNextNum) {
+ p.putUvarint(w, recNextNum)
+ p.putUvarint(w, p.nextNum)
+ }
+ if p.has(recSeq) {
+ p.putUvarint(w, recSeq)
+ p.putUvarint(w, p.seq)
+ }
+ for _, cp := range p.compactionPointers {
+ p.putUvarint(w, recCompactionPointer)
+ p.putUvarint(w, uint64(cp.level))
+ p.putBytes(w, cp.key)
+ }
+ for _, t := range p.deletedTables {
+ p.putUvarint(w, recDeletedTable)
+ p.putUvarint(w, uint64(t.level))
+ p.putUvarint(w, t.num)
+ }
+ for _, t := range p.addedTables {
+ p.putUvarint(w, recNewTable)
+ p.putUvarint(w, uint64(t.level))
+ p.putUvarint(w, t.num)
+ p.putUvarint(w, t.size)
+ p.putBytes(w, t.min)
+ p.putBytes(w, t.max)
+ }
+ return p.err
+}
+
+func (p *sessionRecord) readUvarint(r io.ByteReader) uint64 {
+ if p.err != nil {
+ return 0
+ }
+ x, err := binary.ReadUvarint(r)
+ if err != nil {
+ if err == io.EOF {
+ p.err = errCorruptManifest
+ } else {
+ p.err = err
+ }
+ return 0
+ }
+ return x
+}
+
+func (p *sessionRecord) readBytes(r byteReader) []byte {
+ if p.err != nil {
+ return nil
+ }
+ n := p.readUvarint(r)
+ if p.err != nil {
+ return nil
+ }
+ x := make([]byte, n)
+ _, p.err = io.ReadFull(r, x)
+ if p.err != nil {
+ if p.err == io.EOF {
+ p.err = errCorruptManifest
+ }
+ return nil
+ }
+ return x
+}
+
+func (p *sessionRecord) readLevel(r io.ByteReader) int {
+ if p.err != nil {
+ return 0
+ }
+ x := p.readUvarint(r)
+ if p.err != nil {
+ return 0
+ }
+ if x >= kNumLevels {
+ p.err = errCorruptManifest
+ return 0
+ }
+ return int(x)
+}
+
+func (p *sessionRecord) decode(r io.Reader) error {
+ br, ok := r.(byteReader)
+ if !ok {
+ br = bufio.NewReader(r)
+ }
+ p.err = nil
+ for p.err == nil {
+ rec, err := binary.ReadUvarint(br)
+ if err != nil {
+ if err == io.EOF {
+ err = nil
+ }
+ return err
+ }
+ switch rec {
+ case recComparer:
+ x := p.readBytes(br)
+ if p.err == nil {
+ p.setComparer(string(x))
+ }
+ case recJournalNum:
+ x := p.readUvarint(br)
+ if p.err == nil {
+ p.setJournalNum(x)
+ }
+ case recPrevJournalNum:
+ x := p.readUvarint(br)
+ if p.err == nil {
+ p.setPrevJournalNum(x)
+ }
+ case recNextNum:
+ x := p.readUvarint(br)
+ if p.err == nil {
+ p.setNextNum(x)
+ }
+ case recSeq:
+ x := p.readUvarint(br)
+ if p.err == nil {
+ p.setSeq(x)
+ }
+ case recCompactionPointer:
+ level := p.readLevel(br)
+ key := p.readBytes(br)
+ if p.err == nil {
+ p.addCompactionPointer(level, iKey(key))
+ }
+ case recNewTable:
+ level := p.readLevel(br)
+ num := p.readUvarint(br)
+ size := p.readUvarint(br)
+ min := p.readBytes(br)
+ max := p.readBytes(br)
+ if p.err == nil {
+ p.addTable(level, num, size, min, max)
+ }
+ case recDeletedTable:
+ level := p.readLevel(br)
+ num := p.readUvarint(br)
+ if p.err == nil {
+ p.deleteTable(level, num)
+ }
+ }
+ }
+
+ return p.err
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/session_record_test.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/session_record_test.go
new file mode 100644
index 000000000..029fabfe6
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/session_record_test.go
@@ -0,0 +1,62 @@
+// Copyright (c) 2012, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package leveldb
+
+import (
+ "bytes"
+ "testing"
+)
+
+func decodeEncode(v *sessionRecord) (res bool, err error) {
+ b := new(bytes.Buffer)
+ err = v.encode(b)
+ if err != nil {
+ return
+ }
+ v2 := new(sessionRecord)
+ err = v.decode(b)
+ if err != nil {
+ return
+ }
+ b2 := new(bytes.Buffer)
+ err = v2.encode(b2)
+ if err != nil {
+ return
+ }
+ return bytes.Equal(b.Bytes(), b2.Bytes()), nil
+}
+
+func TestSessionRecord_EncodeDecode(t *testing.T) {
+ big := uint64(1) << 50
+ v := new(sessionRecord)
+ i := uint64(0)
+ test := func() {
+ res, err := decodeEncode(v)
+ if err != nil {
+ t.Fatalf("error when testing encode/decode sessionRecord: %v", err)
+ }
+ if !res {
+ t.Error("encode/decode test failed at iteration:", i)
+ }
+ }
+
+ for ; i < 4; i++ {
+ test()
+ v.addTable(3, big+300+i, big+400+i,
+ newIKey([]byte("foo"), big+500+1, tVal),
+ newIKey([]byte("zoo"), big+600+1, tDel))
+ v.deleteTable(4, big+700+i)
+ v.addCompactionPointer(int(i), newIKey([]byte("x"), big+900+1, tVal))
+ }
+
+ v.setComparer("foo")
+ v.setJournalNum(big + 100)
+ v.setPrevJournalNum(big + 99)
+ v.setNextNum(big + 200)
+ v.setSeq(big + 1000)
+ test()
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/session_util.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/session_util.go
new file mode 100644
index 000000000..bf412b030
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/session_util.go
@@ -0,0 +1,253 @@
+// Copyright (c) 2012, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package leveldb
+
+import (
+ "fmt"
+ "sync/atomic"
+
+ "github.com/syndtr/goleveldb/leveldb/journal"
+ "github.com/syndtr/goleveldb/leveldb/storage"
+)
+
+// logging
+
+type dropper struct {
+ s *session
+ file storage.File
+}
+
+func (d dropper) Drop(err error) {
+ if e, ok := err.(journal.DroppedError); ok {
+ d.s.logf("journal@drop %s-%d S·%s %q", d.file.Type(), d.file.Num(), shortenb(e.Size), e.Reason)
+ } else {
+ d.s.logf("journal@drop %s-%d %q", d.file.Type(), d.file.Num(), err)
+ }
+}
+
+func (s *session) log(v ...interface{}) {
+ s.stor.Log(fmt.Sprint(v...))
+}
+
+func (s *session) logf(format string, v ...interface{}) {
+ s.stor.Log(fmt.Sprintf(format, v...))
+}
+
+// file utils
+
+func (s *session) getJournalFile(num uint64) storage.File {
+ return s.stor.GetFile(num, storage.TypeJournal)
+}
+
+func (s *session) getTableFile(num uint64) storage.File {
+ return s.stor.GetFile(num, storage.TypeTable)
+}
+
+func (s *session) getFiles(t storage.FileType) ([]storage.File, error) {
+ return s.stor.GetFiles(t)
+}
+
+func (s *session) newTemp() storage.File {
+ num := atomic.AddUint64(&s.stTempFileNum, 1) - 1
+ return s.stor.GetFile(num, storage.TypeTemp)
+}
+
+// session state
+
+// Get current version.
+func (s *session) version() *version {
+ s.vmu.Lock()
+ defer s.vmu.Unlock()
+ s.stVersion.ref++
+ return s.stVersion
+}
+
+// Get current version; no barrier.
+func (s *session) version_NB() *version {
+ return s.stVersion
+}
+
+// Set current version to v.
+func (s *session) setVersion(v *version) {
+ s.vmu.Lock()
+ v.ref = 1
+ if old := s.stVersion; old != nil {
+ v.ref++
+ old.next = v
+ old.release_NB()
+ }
+ s.stVersion = v
+ s.vmu.Unlock()
+}
+
+// Get current unused file number.
+func (s *session) fileNum() uint64 {
+ return atomic.LoadUint64(&s.stFileNum)
+}
+
+// Get current unused file number to num.
+func (s *session) setFileNum(num uint64) {
+ atomic.StoreUint64(&s.stFileNum, num)
+}
+
+// Mark file number as used.
+func (s *session) markFileNum(num uint64) {
+ num += 1
+ for {
+ old, x := s.stFileNum, num
+ if old > x {
+ x = old
+ }
+ if atomic.CompareAndSwapUint64(&s.stFileNum, old, x) {
+ break
+ }
+ }
+}
+
+// Allocate a file number.
+func (s *session) allocFileNum() (num uint64) {
+ return atomic.AddUint64(&s.stFileNum, 1) - 1
+}
+
+// Reuse given file number.
+func (s *session) reuseFileNum(num uint64) {
+ for {
+ old, x := s.stFileNum, num
+ if old != x+1 {
+ x = old
+ }
+ if atomic.CompareAndSwapUint64(&s.stFileNum, old, x) {
+ break
+ }
+ }
+}
+
+// manifest related utils
+
+// Fill given session record obj with current states; need external
+// synchronization.
+func (s *session) fillRecord(r *sessionRecord, snapshot bool) {
+ r.setNextNum(s.fileNum())
+
+ if snapshot {
+ if !r.has(recJournalNum) {
+ r.setJournalNum(s.stJournalNum)
+ }
+
+ if !r.has(recSeq) {
+ r.setSeq(s.stSeq)
+ }
+
+ for level, ik := range s.stCPtrs {
+ if ik != nil {
+ r.addCompactionPointer(level, ik)
+ }
+ }
+
+ r.setComparer(s.icmp.uName())
+ }
+}
+
+// Mark if record has been commited, this will update session state;
+// need external synchronization.
+func (s *session) recordCommited(r *sessionRecord) {
+ if r.has(recJournalNum) {
+ s.stJournalNum = r.journalNum
+ }
+
+ if r.has(recPrevJournalNum) {
+ s.stPrevJournalNum = r.prevJournalNum
+ }
+
+ if r.has(recSeq) {
+ s.stSeq = r.seq
+ }
+
+ for _, p := range r.compactionPointers {
+ s.stCPtrs[p.level] = iKey(p.key)
+ }
+}
+
+// Create a new manifest file; need external synchronization.
+func (s *session) newManifest(rec *sessionRecord, v *version) (err error) {
+ num := s.allocFileNum()
+ file := s.stor.GetFile(num, storage.TypeManifest)
+ writer, err := file.Create()
+ if err != nil {
+ return
+ }
+ jw := journal.NewWriter(writer)
+
+ if v == nil {
+ v = s.version_NB()
+ }
+ if rec == nil {
+ rec = new(sessionRecord)
+ }
+ s.fillRecord(rec, true)
+ v.fillRecord(rec)
+
+ defer func() {
+ if err == nil {
+ s.recordCommited(rec)
+ if s.manifest != nil {
+ s.manifest.Close()
+ }
+ if s.manifestWriter != nil {
+ s.manifestWriter.Close()
+ }
+ if s.manifestFile != nil {
+ s.manifestFile.Remove()
+ }
+ s.manifestFile = file
+ s.manifestWriter = writer
+ s.manifest = jw
+ } else {
+ writer.Close()
+ file.Remove()
+ s.reuseFileNum(num)
+ }
+ }()
+
+ w, err := jw.Next()
+ if err != nil {
+ return
+ }
+ err = rec.encode(w)
+ if err != nil {
+ return
+ }
+ err = jw.Flush()
+ if err != nil {
+ return
+ }
+ err = s.stor.SetManifest(file)
+ return
+}
+
+// Flush record to disk.
+func (s *session) flushManifest(rec *sessionRecord) (err error) {
+ s.fillRecord(rec, false)
+ w, err := s.manifest.Next()
+ if err != nil {
+ return
+ }
+ err = rec.encode(w)
+ if err != nil {
+ return
+ }
+ err = s.manifest.Flush()
+ if err != nil {
+ return
+ }
+ err = s.manifestWriter.Sync()
+ if err != nil {
+ return
+ }
+ s.recordCommited(rec)
+ return
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/storage/file_storage.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/storage/file_storage.go
new file mode 100644
index 000000000..75439f6db
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/storage/file_storage.go
@@ -0,0 +1,534 @@
+// Copyright (c) 2012, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reservefs.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package storage
+
+import (
+ "errors"
+ "fmt"
+ "io/ioutil"
+ "os"
+ "path/filepath"
+ "runtime"
+ "strconv"
+ "strings"
+ "sync"
+ "time"
+
+ "github.com/syndtr/goleveldb/leveldb/util"
+)
+
+var errFileOpen = errors.New("leveldb/storage: file still open")
+
+type fileLock interface {
+ release() error
+}
+
+type fileStorageLock struct {
+ fs *fileStorage
+}
+
+func (lock *fileStorageLock) Release() {
+ fs := lock.fs
+ fs.mu.Lock()
+ defer fs.mu.Unlock()
+ if fs.slock == lock {
+ fs.slock = nil
+ }
+ return
+}
+
+// fileStorage is a file-system backed storage.
+type fileStorage struct {
+ path string
+
+ mu sync.Mutex
+ flock fileLock
+ slock *fileStorageLock
+ logw *os.File
+ buf []byte
+ // Opened file counter; if open < 0 means closed.
+ open int
+ day int
+}
+
+// OpenFile returns a new filesytem-backed storage implementation with the given
+// path. This also hold a file lock, so any subsequent attempt to open the same
+// path will fail.
+//
+// The storage must be closed after use, by calling Close method.
+func OpenFile(path string) (Storage, error) {
+ if err := os.MkdirAll(path, 0755); err != nil {
+ return nil, err
+ }
+
+ flock, err := newFileLock(filepath.Join(path, "LOCK"))
+ if err != nil {
+ return nil, err
+ }
+
+ defer func() {
+ if err != nil {
+ flock.release()
+ }
+ }()
+
+ rename(filepath.Join(path, "LOG"), filepath.Join(path, "LOG.old"))
+ logw, err := os.OpenFile(filepath.Join(path, "LOG"), os.O_WRONLY|os.O_CREATE, 0644)
+ if err != nil {
+ return nil, err
+ }
+
+ fs := &fileStorage{path: path, flock: flock, logw: logw}
+ runtime.SetFinalizer(fs, (*fileStorage).Close)
+ return fs, nil
+}
+
+func (fs *fileStorage) Lock() (util.Releaser, error) {
+ fs.mu.Lock()
+ defer fs.mu.Unlock()
+ if fs.open < 0 {
+ return nil, ErrClosed
+ }
+ if fs.slock != nil {
+ return nil, ErrLocked
+ }
+ fs.slock = &fileStorageLock{fs: fs}
+ return fs.slock, nil
+}
+
+func itoa(buf []byte, i int, wid int) []byte {
+ var u uint = uint(i)
+ if u == 0 && wid <= 1 {
+ return append(buf, '0')
+ }
+
+ // Assemble decimal in reverse order.
+ var b [32]byte
+ bp := len(b)
+ for ; u > 0 || wid > 0; u /= 10 {
+ bp--
+ wid--
+ b[bp] = byte(u%10) + '0'
+ }
+ return append(buf, b[bp:]...)
+}
+
+func (fs *fileStorage) printDay(t time.Time) {
+ if fs.day == t.Day() {
+ return
+ }
+ fs.day = t.Day()
+ fs.logw.Write([]byte("=============== " + t.Format("Jan 2, 2006 (MST)") + " ===============\n"))
+}
+
+func (fs *fileStorage) doLog(t time.Time, str string) {
+ fs.printDay(t)
+ hour, min, sec := t.Clock()
+ msec := t.Nanosecond() / 1e3
+ // time
+ fs.buf = itoa(fs.buf[:0], hour, 2)
+ fs.buf = append(fs.buf, ':')
+ fs.buf = itoa(fs.buf, min, 2)
+ fs.buf = append(fs.buf, ':')
+ fs.buf = itoa(fs.buf, sec, 2)
+ fs.buf = append(fs.buf, '.')
+ fs.buf = itoa(fs.buf, msec, 6)
+ fs.buf = append(fs.buf, ' ')
+ // write
+ fs.buf = append(fs.buf, []byte(str)...)
+ fs.buf = append(fs.buf, '\n')
+ fs.logw.Write(fs.buf)
+}
+
+func (fs *fileStorage) Log(str string) {
+ t := time.Now()
+ fs.mu.Lock()
+ defer fs.mu.Unlock()
+ if fs.open < 0 {
+ return
+ }
+ fs.doLog(t, str)
+}
+
+func (fs *fileStorage) log(str string) {
+ fs.doLog(time.Now(), str)
+}
+
+func (fs *fileStorage) GetFile(num uint64, t FileType) File {
+ return &file{fs: fs, num: num, t: t}
+}
+
+func (fs *fileStorage) GetFiles(t FileType) (ff []File, err error) {
+ fs.mu.Lock()
+ defer fs.mu.Unlock()
+ if fs.open < 0 {
+ return nil, ErrClosed
+ }
+ dir, err := os.Open(fs.path)
+ if err != nil {
+ return
+ }
+ fnn, err := dir.Readdirnames(0)
+ // Close the dir first before checking for Readdirnames error.
+ if err := dir.Close(); err != nil {
+ fs.log(fmt.Sprintf("close dir: %v", err))
+ }
+ if err != nil {
+ return
+ }
+ f := &file{fs: fs}
+ for _, fn := range fnn {
+ if f.parse(fn) && (f.t&t) != 0 {
+ ff = append(ff, f)
+ f = &file{fs: fs}
+ }
+ }
+ return
+}
+
+func (fs *fileStorage) GetManifest() (f File, err error) {
+ fs.mu.Lock()
+ defer fs.mu.Unlock()
+ if fs.open < 0 {
+ return nil, ErrClosed
+ }
+ dir, err := os.Open(fs.path)
+ if err != nil {
+ return
+ }
+ fnn, err := dir.Readdirnames(0)
+ // Close the dir first before checking for Readdirnames error.
+ if err := dir.Close(); err != nil {
+ fs.log(fmt.Sprintf("close dir: %v", err))
+ }
+ if err != nil {
+ return
+ }
+ // Find latest CURRENT file.
+ var rem []string
+ var pend bool
+ var cerr error
+ for _, fn := range fnn {
+ if strings.HasPrefix(fn, "CURRENT") {
+ pend1 := len(fn) > 7
+ // Make sure it is valid name for a CURRENT file, otherwise skip it.
+ if pend1 {
+ if fn[7] != '.' || len(fn) < 9 {
+ fs.log(fmt.Sprintf("skipping %s: invalid file name", fn))
+ continue
+ }
+ if _, e1 := strconv.ParseUint(fn[7:], 10, 0); e1 != nil {
+ fs.log(fmt.Sprintf("skipping %s: invalid file num: %v", fn, e1))
+ continue
+ }
+ }
+ path := filepath.Join(fs.path, fn)
+ r, e1 := os.OpenFile(path, os.O_RDONLY, 0)
+ if e1 != nil {
+ return nil, e1
+ }
+ b, e1 := ioutil.ReadAll(r)
+ if e1 != nil {
+ r.Close()
+ return nil, e1
+ }
+ f1 := &file{fs: fs}
+ if len(b) < 1 || b[len(b)-1] != '\n' || !f1.parse(string(b[:len(b)-1])) {
+ fs.log(fmt.Sprintf("skipping %s: corrupted or incomplete", fn))
+ if pend1 {
+ rem = append(rem, fn)
+ }
+ if !pend1 || cerr == nil {
+ cerr = fmt.Errorf("leveldb/storage: corrupted or incomplete %s file", fn)
+ }
+ } else if f != nil && f1.Num() < f.Num() {
+ fs.log(fmt.Sprintf("skipping %s: obsolete", fn))
+ if pend1 {
+ rem = append(rem, fn)
+ }
+ } else {
+ f = f1
+ pend = pend1
+ }
+ if err := r.Close(); err != nil {
+ fs.log(fmt.Sprintf("close %s: %v", fn, err))
+ }
+ }
+ }
+ // Don't remove any files if there is no valid CURRENT file.
+ if f == nil {
+ if cerr != nil {
+ err = cerr
+ } else {
+ err = os.ErrNotExist
+ }
+ return
+ }
+ // Rename pending CURRENT file to an effective CURRENT.
+ if pend {
+ path := fmt.Sprintf("%s.%d", filepath.Join(fs.path, "CURRENT"), f.Num())
+ if err := rename(path, filepath.Join(fs.path, "CURRENT")); err != nil {
+ fs.log(fmt.Sprintf("CURRENT.%d -> CURRENT: %v", f.Num(), err))
+ }
+ }
+ // Remove obsolete or incomplete pending CURRENT files.
+ for _, fn := range rem {
+ path := filepath.Join(fs.path, fn)
+ if err := os.Remove(path); err != nil {
+ fs.log(fmt.Sprintf("remove %s: %v", fn, err))
+ }
+ }
+ return
+}
+
+func (fs *fileStorage) SetManifest(f File) (err error) {
+ fs.mu.Lock()
+ defer fs.mu.Unlock()
+ if fs.open < 0 {
+ return ErrClosed
+ }
+ f2, ok := f.(*file)
+ if !ok || f2.t != TypeManifest {
+ return ErrInvalidFile
+ }
+ defer func() {
+ if err != nil {
+ fs.log(fmt.Sprintf("CURRENT: %v", err))
+ }
+ }()
+ path := fmt.Sprintf("%s.%d", filepath.Join(fs.path, "CURRENT"), f2.Num())
+ w, err := os.OpenFile(path, os.O_WRONLY|os.O_CREATE|os.O_TRUNC, 0644)
+ if err != nil {
+ return err
+ }
+ _, err = fmt.Fprintln(w, f2.name())
+ // Close the file first.
+ if err := w.Close(); err != nil {
+ fs.log(fmt.Sprintf("close CURRENT.%d: %v", f2.num, err))
+ }
+ if err != nil {
+ return err
+ }
+ return rename(path, filepath.Join(fs.path, "CURRENT"))
+}
+
+func (fs *fileStorage) Close() error {
+ fs.mu.Lock()
+ defer fs.mu.Unlock()
+ if fs.open < 0 {
+ return ErrClosed
+ }
+ // Clear the finalizer.
+ runtime.SetFinalizer(fs, nil)
+
+ if fs.open > 0 {
+ fs.log(fmt.Sprintf("refuse to close, %d files still open", fs.open))
+ return fmt.Errorf("leveldb/storage: cannot close, %d files still open", fs.open)
+ }
+ fs.open = -1
+ e1 := fs.logw.Close()
+ err := fs.flock.release()
+ if err == nil {
+ err = e1
+ }
+ return err
+}
+
+type fileWrap struct {
+ *os.File
+ f *file
+}
+
+func (fw fileWrap) Sync() error {
+ if err := fw.File.Sync(); err != nil {
+ return err
+ }
+ if fw.f.Type() == TypeManifest {
+ // Also sync parent directory if file type is manifest.
+ // See: https://code.google.com/p/leveldb/issues/detail?id=190.
+ if err := syncDir(fw.f.fs.path); err != nil {
+ return err
+ }
+ }
+ return nil
+}
+
+func (fw fileWrap) Close() error {
+ f := fw.f
+ f.fs.mu.Lock()
+ defer f.fs.mu.Unlock()
+ if !f.open {
+ return ErrClosed
+ }
+ f.open = false
+ f.fs.open--
+ err := fw.File.Close()
+ if err != nil {
+ f.fs.log(fmt.Sprintf("close %s.%d: %v", f.Type(), f.Num(), err))
+ }
+ return err
+}
+
+type file struct {
+ fs *fileStorage
+ num uint64
+ t FileType
+ open bool
+}
+
+func (f *file) Open() (Reader, error) {
+ f.fs.mu.Lock()
+ defer f.fs.mu.Unlock()
+ if f.fs.open < 0 {
+ return nil, ErrClosed
+ }
+ if f.open {
+ return nil, errFileOpen
+ }
+ of, err := os.OpenFile(f.path(), os.O_RDONLY, 0)
+ if err != nil {
+ if f.hasOldName() && os.IsNotExist(err) {
+ of, err = os.OpenFile(f.oldPath(), os.O_RDONLY, 0)
+ if err == nil {
+ goto ok
+ }
+ }
+ return nil, err
+ }
+ok:
+ f.open = true
+ f.fs.open++
+ return fileWrap{of, f}, nil
+}
+
+func (f *file) Create() (Writer, error) {
+ f.fs.mu.Lock()
+ defer f.fs.mu.Unlock()
+ if f.fs.open < 0 {
+ return nil, ErrClosed
+ }
+ if f.open {
+ return nil, errFileOpen
+ }
+ of, err := os.OpenFile(f.path(), os.O_WRONLY|os.O_CREATE|os.O_TRUNC, 0644)
+ if err != nil {
+ return nil, err
+ }
+ f.open = true
+ f.fs.open++
+ return fileWrap{of, f}, nil
+}
+
+func (f *file) Replace(newfile File) error {
+ f.fs.mu.Lock()
+ defer f.fs.mu.Unlock()
+ if f.fs.open < 0 {
+ return ErrClosed
+ }
+ newfile2, ok := newfile.(*file)
+ if !ok {
+ return ErrInvalidFile
+ }
+ if f.open || newfile2.open {
+ return errFileOpen
+ }
+ return rename(newfile2.path(), f.path())
+}
+
+func (f *file) Type() FileType {
+ return f.t
+}
+
+func (f *file) Num() uint64 {
+ return f.num
+}
+
+func (f *file) Remove() error {
+ f.fs.mu.Lock()
+ defer f.fs.mu.Unlock()
+ if f.fs.open < 0 {
+ return ErrClosed
+ }
+ if f.open {
+ return errFileOpen
+ }
+ err := os.Remove(f.path())
+ if err != nil {
+ f.fs.log(fmt.Sprintf("remove %s.%d: %v", f.Type(), f.Num(), err))
+ }
+ // Also try remove file with old name, just in case.
+ if f.hasOldName() {
+ if e1 := os.Remove(f.oldPath()); !os.IsNotExist(e1) {
+ f.fs.log(fmt.Sprintf("remove %s.%d: %v (old name)", f.Type(), f.Num(), err))
+ err = e1
+ }
+ }
+ return err
+}
+
+func (f *file) hasOldName() bool {
+ return f.t == TypeTable
+}
+
+func (f *file) oldName() string {
+ switch f.t {
+ case TypeTable:
+ return fmt.Sprintf("%06d.sst", f.num)
+ }
+ return f.name()
+}
+
+func (f *file) oldPath() string {
+ return filepath.Join(f.fs.path, f.oldName())
+}
+
+func (f *file) name() string {
+ switch f.t {
+ case TypeManifest:
+ return fmt.Sprintf("MANIFEST-%06d", f.num)
+ case TypeJournal:
+ return fmt.Sprintf("%06d.log", f.num)
+ case TypeTable:
+ return fmt.Sprintf("%06d.ldb", f.num)
+ case TypeTemp:
+ return fmt.Sprintf("%06d.tmp", f.num)
+ default:
+ panic("invalid file type")
+ }
+}
+
+func (f *file) path() string {
+ return filepath.Join(f.fs.path, f.name())
+}
+
+func (f *file) parse(name string) bool {
+ var num uint64
+ var tail string
+ _, err := fmt.Sscanf(name, "%d.%s", &num, &tail)
+ if err == nil {
+ switch tail {
+ case "log":
+ f.t = TypeJournal
+ case "ldb", "sst":
+ f.t = TypeTable
+ case "tmp":
+ f.t = TypeTemp
+ default:
+ return false
+ }
+ f.num = num
+ return true
+ }
+ n, _ := fmt.Sscanf(name, "MANIFEST-%d%s", &num, &tail)
+ if n == 1 {
+ f.t = TypeManifest
+ f.num = num
+ return true
+ }
+
+ return false
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/storage/file_storage_plan9.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/storage/file_storage_plan9.go
new file mode 100644
index 000000000..42940d769
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/storage/file_storage_plan9.go
@@ -0,0 +1,52 @@
+// Copyright (c) 2012, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package storage
+
+import (
+ "os"
+ "path/filepath"
+)
+
+type plan9FileLock struct {
+ f *os.File
+}
+
+func (fl *plan9FileLock) release() error {
+ return fl.f.Close()
+}
+
+func newFileLock(path string) (fl fileLock, err error) {
+ f, err := os.OpenFile(path, os.O_RDWR|os.O_CREATE, os.ModeExclusive|0644)
+ if err != nil {
+ return
+ }
+ fl = &plan9FileLock{f: f}
+ return
+}
+
+func rename(oldpath, newpath string) error {
+ if _, err := os.Stat(newpath); err == nil {
+ if err := os.Remove(newpath); err != nil {
+ return err
+ }
+ }
+
+ _, fname := filepath.Split(newpath)
+ return os.Rename(oldpath, fname)
+}
+
+func syncDir(name string) error {
+ f, err := os.Open(name)
+ if err != nil {
+ return err
+ }
+ defer f.Close()
+ if err := f.Sync(); err != nil {
+ return err
+ }
+ return nil
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/storage/file_storage_test.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/storage/file_storage_test.go
new file mode 100644
index 000000000..92abcbb7d
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/storage/file_storage_test.go
@@ -0,0 +1,142 @@
+// Copyright (c) 2012, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package storage
+
+import (
+ "fmt"
+ "os"
+ "path/filepath"
+ "testing"
+)
+
+var cases = []struct {
+ oldName []string
+ name string
+ ftype FileType
+ num uint64
+}{
+ {nil, "000100.log", TypeJournal, 100},
+ {nil, "000000.log", TypeJournal, 0},
+ {[]string{"000000.sst"}, "000000.ldb", TypeTable, 0},
+ {nil, "MANIFEST-000002", TypeManifest, 2},
+ {nil, "MANIFEST-000007", TypeManifest, 7},
+ {nil, "18446744073709551615.log", TypeJournal, 18446744073709551615},
+ {nil, "000100.tmp", TypeTemp, 100},
+}
+
+var invalidCases = []string{
+ "",
+ "foo",
+ "foo-dx-100.log",
+ ".log",
+ "",
+ "manifest",
+ "CURREN",
+ "CURRENTX",
+ "MANIFES",
+ "MANIFEST",
+ "MANIFEST-",
+ "XMANIFEST-3",
+ "MANIFEST-3x",
+ "LOC",
+ "LOCKx",
+ "LO",
+ "LOGx",
+ "18446744073709551616.log",
+ "184467440737095516150.log",
+ "100",
+ "100.",
+ "100.lop",
+}
+
+func TestFileStorage_CreateFileName(t *testing.T) {
+ for _, c := range cases {
+ f := &file{num: c.num, t: c.ftype}
+ if f.name() != c.name {
+ t.Errorf("invalid filename got '%s', want '%s'", f.name(), c.name)
+ }
+ }
+}
+
+func TestFileStorage_ParseFileName(t *testing.T) {
+ for _, c := range cases {
+ for _, name := range append([]string{c.name}, c.oldName...) {
+ f := new(file)
+ if !f.parse(name) {
+ t.Errorf("cannot parse filename '%s'", name)
+ continue
+ }
+ if f.Type() != c.ftype {
+ t.Errorf("filename '%s' invalid type got '%d', want '%d'", name, f.Type(), c.ftype)
+ }
+ if f.Num() != c.num {
+ t.Errorf("filename '%s' invalid number got '%d', want '%d'", name, f.Num(), c.num)
+ }
+ }
+ }
+}
+
+func TestFileStorage_InvalidFileName(t *testing.T) {
+ for _, name := range invalidCases {
+ f := new(file)
+ if f.parse(name) {
+ t.Errorf("filename '%s' should be invalid", name)
+ }
+ }
+}
+
+func TestFileStorage_Locking(t *testing.T) {
+ path := filepath.Join(os.TempDir(), fmt.Sprintf("goleveldbtestfd-%d", os.Getuid()))
+
+ _, err := os.Stat(path)
+ if err == nil {
+ err = os.RemoveAll(path)
+ if err != nil {
+ t.Fatal("RemoveAll: got error: ", err)
+ }
+ }
+
+ p1, err := OpenFile(path)
+ if err != nil {
+ t.Fatal("OpenFile(1): got error: ", err)
+ }
+
+ defer os.RemoveAll(path)
+
+ p2, err := OpenFile(path)
+ if err != nil {
+ t.Logf("OpenFile(2): got error: %s (expected)", err)
+ } else {
+ p2.Close()
+ p1.Close()
+ t.Fatal("OpenFile(2): expect error")
+ }
+
+ p1.Close()
+
+ p3, err := OpenFile(path)
+ if err != nil {
+ t.Fatal("OpenFile(3): got error: ", err)
+ }
+ defer p3.Close()
+
+ l, err := p3.Lock()
+ if err != nil {
+ t.Fatal("storage lock failed(1): ", err)
+ }
+ _, err = p3.Lock()
+ if err == nil {
+ t.Fatal("expect error for second storage lock attempt")
+ } else {
+ t.Logf("storage lock got error: %s (expected)", err)
+ }
+ l.Release()
+ _, err = p3.Lock()
+ if err != nil {
+ t.Fatal("storage lock failed(2): ", err)
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/storage/file_storage_unix.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/storage/file_storage_unix.go
new file mode 100644
index 000000000..73499afc8
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/storage/file_storage_unix.go
@@ -0,0 +1,63 @@
+// Copyright (c) 2012, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// +build darwin freebsd linux netbsd openbsd
+
+package storage
+
+import (
+ "os"
+ "syscall"
+)
+
+type unixFileLock struct {
+ f *os.File
+}
+
+func (fl *unixFileLock) release() error {
+ if err := setFileLock(fl.f, false); err != nil {
+ return err
+ }
+ return fl.f.Close()
+}
+
+func newFileLock(path string) (fl fileLock, err error) {
+ f, err := os.OpenFile(path, os.O_RDWR|os.O_CREATE, 0644)
+ if err != nil {
+ return
+ }
+ err = setFileLock(f, true)
+ if err != nil {
+ f.Close()
+ return
+ }
+ fl = &unixFileLock{f: f}
+ return
+}
+
+func setFileLock(f *os.File, lock bool) error {
+ how := syscall.LOCK_UN
+ if lock {
+ how = syscall.LOCK_EX
+ }
+ return syscall.Flock(int(f.Fd()), how|syscall.LOCK_NB)
+}
+
+func rename(oldpath, newpath string) error {
+ return os.Rename(oldpath, newpath)
+}
+
+func syncDir(name string) error {
+ f, err := os.Open(name)
+ if err != nil {
+ return err
+ }
+ defer f.Close()
+ if err := f.Sync(); err != nil {
+ return err
+ }
+ return nil
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/storage/file_storage_windows.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/storage/file_storage_windows.go
new file mode 100644
index 000000000..50c3c454e
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/storage/file_storage_windows.go
@@ -0,0 +1,69 @@
+// Copyright (c) 2013, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package storage
+
+import (
+ "syscall"
+ "unsafe"
+)
+
+var (
+ modkernel32 = syscall.NewLazyDLL("kernel32.dll")
+
+ procMoveFileExW = modkernel32.NewProc("MoveFileExW")
+)
+
+const (
+ _MOVEFILE_REPLACE_EXISTING = 1
+)
+
+type windowsFileLock struct {
+ fd syscall.Handle
+}
+
+func (fl *windowsFileLock) release() error {
+ return syscall.Close(fl.fd)
+}
+
+func newFileLock(path string) (fl fileLock, err error) {
+ pathp, err := syscall.UTF16PtrFromString(path)
+ if err != nil {
+ return
+ }
+ fd, err := syscall.CreateFile(pathp, syscall.GENERIC_READ|syscall.GENERIC_WRITE, 0, nil, syscall.CREATE_ALWAYS, syscall.FILE_ATTRIBUTE_NORMAL, 0)
+ if err != nil {
+ return
+ }
+ fl = &windowsFileLock{fd: fd}
+ return
+}
+
+func moveFileEx(from *uint16, to *uint16, flags uint32) error {
+ r1, _, e1 := syscall.Syscall(procMoveFileExW.Addr(), 3, uintptr(unsafe.Pointer(from)), uintptr(unsafe.Pointer(to)), uintptr(flags))
+ if r1 == 0 {
+ if e1 != 0 {
+ return error(e1)
+ } else {
+ return syscall.EINVAL
+ }
+ }
+ return nil
+}
+
+func rename(oldpath, newpath string) error {
+ from, err := syscall.UTF16PtrFromString(oldpath)
+ if err != nil {
+ return err
+ }
+ to, err := syscall.UTF16PtrFromString(newpath)
+ if err != nil {
+ return err
+ }
+ return moveFileEx(from, to, _MOVEFILE_REPLACE_EXISTING)
+}
+
+func syncDir(name string) error { return nil }
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/storage/mem_storage.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/storage/mem_storage.go
new file mode 100644
index 000000000..fc1c8165d
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/storage/mem_storage.go
@@ -0,0 +1,203 @@
+// Copyright (c) 2013, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package storage
+
+import (
+ "bytes"
+ "os"
+ "sync"
+
+ "github.com/syndtr/goleveldb/leveldb/util"
+)
+
+const typeShift = 3
+
+type memStorageLock struct {
+ ms *memStorage
+}
+
+func (lock *memStorageLock) Release() {
+ ms := lock.ms
+ ms.mu.Lock()
+ defer ms.mu.Unlock()
+ if ms.slock == lock {
+ ms.slock = nil
+ }
+ return
+}
+
+// memStorage is a memory-backed storage.
+type memStorage struct {
+ mu sync.Mutex
+ slock *memStorageLock
+ files map[uint64]*memFile
+ manifest *memFilePtr
+}
+
+// NewMemStorage returns a new memory-backed storage implementation.
+func NewMemStorage() Storage {
+ return &memStorage{
+ files: make(map[uint64]*memFile),
+ }
+}
+
+func (ms *memStorage) Lock() (util.Releaser, error) {
+ ms.mu.Lock()
+ defer ms.mu.Unlock()
+ if ms.slock != nil {
+ return nil, ErrLocked
+ }
+ ms.slock = &memStorageLock{ms: ms}
+ return ms.slock, nil
+}
+
+func (*memStorage) Log(str string) {}
+
+func (ms *memStorage) GetFile(num uint64, t FileType) File {
+ return &memFilePtr{ms: ms, num: num, t: t}
+}
+
+func (ms *memStorage) GetFiles(t FileType) ([]File, error) {
+ ms.mu.Lock()
+ var ff []File
+ for x, _ := range ms.files {
+ num, mt := x>>typeShift, FileType(x)&TypeAll
+ if mt&t == 0 {
+ continue
+ }
+ ff = append(ff, &memFilePtr{ms: ms, num: num, t: mt})
+ }
+ ms.mu.Unlock()
+ return ff, nil
+}
+
+func (ms *memStorage) GetManifest() (File, error) {
+ ms.mu.Lock()
+ defer ms.mu.Unlock()
+ if ms.manifest == nil {
+ return nil, os.ErrNotExist
+ }
+ return ms.manifest, nil
+}
+
+func (ms *memStorage) SetManifest(f File) error {
+ fm, ok := f.(*memFilePtr)
+ if !ok || fm.t != TypeManifest {
+ return ErrInvalidFile
+ }
+ ms.mu.Lock()
+ ms.manifest = fm
+ ms.mu.Unlock()
+ return nil
+}
+
+func (*memStorage) Close() error { return nil }
+
+type memReader struct {
+ *bytes.Reader
+ m *memFile
+}
+
+func (mr *memReader) Close() error {
+ return mr.m.Close()
+}
+
+type memFile struct {
+ bytes.Buffer
+ ms *memStorage
+ open bool
+}
+
+func (*memFile) Sync() error { return nil }
+func (m *memFile) Close() error {
+ m.ms.mu.Lock()
+ m.open = false
+ m.ms.mu.Unlock()
+ return nil
+}
+
+type memFilePtr struct {
+ ms *memStorage
+ num uint64
+ t FileType
+}
+
+func (p *memFilePtr) x() uint64 {
+ return p.Num()<<typeShift | uint64(p.Type())
+}
+
+func (p *memFilePtr) Open() (Reader, error) {
+ ms := p.ms
+ ms.mu.Lock()
+ defer ms.mu.Unlock()
+ if m, exist := ms.files[p.x()]; exist {
+ if m.open {
+ return nil, errFileOpen
+ }
+ m.open = true
+ return &memReader{Reader: bytes.NewReader(m.Bytes()), m: m}, nil
+ }
+ return nil, os.ErrNotExist
+}
+
+func (p *memFilePtr) Create() (Writer, error) {
+ ms := p.ms
+ ms.mu.Lock()
+ defer ms.mu.Unlock()
+ m, exist := ms.files[p.x()]
+ if exist {
+ if m.open {
+ return nil, errFileOpen
+ }
+ m.Reset()
+ } else {
+ m = &memFile{ms: ms}
+ ms.files[p.x()] = m
+ }
+ m.open = true
+ return m, nil
+}
+
+func (p *memFilePtr) Replace(newfile File) error {
+ p1, ok := newfile.(*memFilePtr)
+ if !ok {
+ return ErrInvalidFile
+ }
+ ms := p.ms
+ ms.mu.Lock()
+ defer ms.mu.Unlock()
+ m1, exist := ms.files[p1.x()]
+ if !exist {
+ return os.ErrNotExist
+ }
+ m0, exist := ms.files[p.x()]
+ if (exist && m0.open) || m1.open {
+ return errFileOpen
+ }
+ delete(ms.files, p1.x())
+ ms.files[p.x()] = m1
+ return nil
+}
+
+func (p *memFilePtr) Type() FileType {
+ return p.t
+}
+
+func (p *memFilePtr) Num() uint64 {
+ return p.num
+}
+
+func (p *memFilePtr) Remove() error {
+ ms := p.ms
+ ms.mu.Lock()
+ defer ms.mu.Unlock()
+ if _, exist := ms.files[p.x()]; exist {
+ delete(ms.files, p.x())
+ return nil
+ }
+ return os.ErrNotExist
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/storage/mem_storage_test.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/storage/mem_storage_test.go
new file mode 100644
index 000000000..23bb074b4
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/storage/mem_storage_test.go
@@ -0,0 +1,66 @@
+// Copyright (c) 2013, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package storage
+
+import (
+ "bytes"
+ "testing"
+)
+
+func TestMemStorage(t *testing.T) {
+ m := NewMemStorage()
+
+ l, err := m.Lock()
+ if err != nil {
+ t.Fatal("storage lock failed(1): ", err)
+ }
+ _, err = m.Lock()
+ if err == nil {
+ t.Fatal("expect error for second storage lock attempt")
+ } else {
+ t.Logf("storage lock got error: %s (expected)", err)
+ }
+ l.Release()
+ _, err = m.Lock()
+ if err != nil {
+ t.Fatal("storage lock failed(2): ", err)
+ }
+
+ f := m.GetFile(1, TypeTable)
+ if f.Num() != 1 && f.Type() != TypeTable {
+ t.Fatal("invalid file number and type")
+ }
+ w, _ := f.Create()
+ w.Write([]byte("abc"))
+ w.Close()
+ if ff, _ := m.GetFiles(TypeAll); len(ff) != 1 {
+ t.Fatal("invalid GetFiles len")
+ }
+ buf := new(bytes.Buffer)
+ r, err := f.Open()
+ if err != nil {
+ t.Fatal("Open: got error: ", err)
+ }
+ buf.ReadFrom(r)
+ r.Close()
+ if got := buf.String(); got != "abc" {
+ t.Fatalf("Read: invalid value, want=abc got=%s", got)
+ }
+ if _, err := f.Open(); err != nil {
+ t.Fatal("Open: got error: ", err)
+ }
+ if _, err := m.GetFile(1, TypeTable).Open(); err == nil {
+ t.Fatal("expecting error")
+ }
+ f.Remove()
+ if ff, _ := m.GetFiles(TypeAll); len(ff) != 0 {
+ t.Fatal("invalid GetFiles len", len(ff))
+ }
+ if _, err := f.Open(); err == nil {
+ t.Fatal("expecting error")
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/storage/storage.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/storage/storage.go
new file mode 100644
index 000000000..de5694888
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/storage/storage.go
@@ -0,0 +1,127 @@
+// Copyright (c) 2012, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Package storage provides storage abstraction for LevelDB.
+package storage
+
+import (
+ "errors"
+ "fmt"
+ "io"
+
+ "github.com/syndtr/goleveldb/leveldb/util"
+)
+
+type FileType uint32
+
+const (
+ TypeManifest FileType = 1 << iota
+ TypeJournal
+ TypeTable
+ TypeTemp
+
+ TypeAll = TypeManifest | TypeJournal | TypeTable | TypeTemp
+)
+
+func (t FileType) String() string {
+ switch t {
+ case TypeManifest:
+ return "manifest"
+ case TypeJournal:
+ return "journal"
+ case TypeTable:
+ return "table"
+ case TypeTemp:
+ return "temp"
+ }
+ return fmt.Sprintf("<unknown:%d>", t)
+}
+
+var (
+ ErrInvalidFile = errors.New("leveldb/storage: invalid file for argument")
+ ErrLocked = errors.New("leveldb/storage: already locked")
+ ErrClosed = errors.New("leveldb/storage: closed")
+)
+
+// Syncer is the interface that wraps basic Sync method.
+type Syncer interface {
+ // Sync commits the current contents of the file to stable storage.
+ Sync() error
+}
+
+// Reader is the interface that groups the basic Read, Seek, ReadAt and Close
+// methods.
+type Reader interface {
+ io.ReadSeeker
+ io.ReaderAt
+ io.Closer
+}
+
+// Writer is the interface that groups the basic Write, Sync and Close
+// methods.
+type Writer interface {
+ io.WriteCloser
+ Syncer
+}
+
+// File is the file.
+type File interface {
+ // Open opens the file for read. Returns os.ErrNotExist error
+ // if the file does not exist.
+ // Returns ErrClosed if the underlying storage is closed.
+ Open() (r Reader, err error)
+
+ // Create creates the file for writting. Truncate the file if
+ // already exist.
+ // Returns ErrClosed if the underlying storage is closed.
+ Create() (w Writer, err error)
+
+ // Replace replaces file with newfile.
+ // Returns ErrClosed if the underlying storage is closed.
+ Replace(newfile File) error
+
+ // Type returns the file type
+ Type() FileType
+
+ // Num returns the file number.
+ Num() uint64
+
+ // Remove removes the file.
+ // Returns ErrClosed if the underlying storage is closed.
+ Remove() error
+}
+
+// Storage is the storage.
+type Storage interface {
+ // Lock locks the storage. Any subsequent attempt to call Lock will fail
+ // until the last lock released.
+ // After use the caller should call the Release method.
+ Lock() (l util.Releaser, err error)
+
+ // Log logs a string. This is used for logging. An implementation
+ // may write to a file, stdout or simply do nothing.
+ Log(str string)
+
+ // GetFile returns a file for the given number and type. GetFile will never
+ // returns nil, even if the underlying storage is closed.
+ GetFile(num uint64, t FileType) File
+
+ // GetFiles returns a slice of files that match the given file types.
+ // The file types may be OR'ed together.
+ GetFiles(t FileType) ([]File, error)
+
+ // GetManifest returns a manifest file. Returns os.ErrNotExist if manifest
+ // file does not exist.
+ GetManifest() (File, error)
+
+ // SetManifest sets the given file as manifest file. The given file should
+ // be a manifest file type or error will be returned.
+ SetManifest(f File) error
+
+ // Close closes the storage. It is valid to call Close multiple times.
+ // Other methods should not be called after the storage has been closed.
+ Close() error
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/storage_test.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/storage_test.go
new file mode 100644
index 000000000..27e76d707
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/storage_test.go
@@ -0,0 +1,459 @@
+// Copyright (c) 2012, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENE file.
+
+package leveldb
+
+import (
+ "errors"
+ "fmt"
+ "io"
+ "io/ioutil"
+ "os"
+ "path/filepath"
+ "sync"
+ "testing"
+
+ "github.com/syndtr/goleveldb/leveldb/storage"
+ "github.com/syndtr/goleveldb/leveldb/util"
+)
+
+const typeShift = 4
+
+var (
+ tsErrInvalidFile = errors.New("leveldb.testStorage: invalid file for argument")
+ tsErrFileOpen = errors.New("leveldb.testStorage: file still open")
+)
+
+var (
+ tsFSEnv = os.Getenv("GOLEVELDB_USEFS")
+ tsKeepFS = tsFSEnv == "2"
+ tsFS = tsKeepFS || tsFSEnv == "" || tsFSEnv == "1"
+ tsMU = &sync.Mutex{}
+ tsNum = 0
+)
+
+type tsLock struct {
+ ts *testStorage
+ r util.Releaser
+}
+
+func (l tsLock) Release() {
+ l.r.Release()
+ l.ts.t.Log("I: storage lock released")
+}
+
+type tsReader struct {
+ tf tsFile
+ storage.Reader
+}
+
+func (tr tsReader) Read(b []byte) (n int, err error) {
+ ts := tr.tf.ts
+ ts.countRead(tr.tf.Type())
+ n, err = tr.Reader.Read(b)
+ if err != nil && err != io.EOF {
+ ts.t.Errorf("E: read error, num=%d type=%v n=%d: %v", tr.tf.Num(), tr.tf.Type(), n, err)
+ }
+ return
+}
+
+func (tr tsReader) ReadAt(b []byte, off int64) (n int, err error) {
+ ts := tr.tf.ts
+ ts.countRead(tr.tf.Type())
+ n, err = tr.Reader.ReadAt(b, off)
+ if err != nil && err != io.EOF {
+ ts.t.Errorf("E: readAt error, num=%d type=%v off=%d n=%d: %v", tr.tf.Num(), tr.tf.Type(), off, n, err)
+ }
+ return
+}
+
+func (tr tsReader) Close() (err error) {
+ err = tr.Reader.Close()
+ tr.tf.close("reader", err)
+ return
+}
+
+type tsWriter struct {
+ tf tsFile
+ storage.Writer
+}
+
+func (tw tsWriter) Write(b []byte) (n int, err error) {
+ ts := tw.tf.ts
+ ts.mu.Lock()
+ defer ts.mu.Unlock()
+ if ts.emuWriteErr&tw.tf.Type() != 0 {
+ return 0, errors.New("leveldb.testStorage: emulated write error")
+ }
+ n, err = tw.Writer.Write(b)
+ if err != nil {
+ ts.t.Errorf("E: write error, num=%d type=%v n=%d: %v", tw.tf.Num(), tw.tf.Type(), n, err)
+ }
+ return
+}
+
+func (tw tsWriter) Sync() (err error) {
+ ts := tw.tf.ts
+ ts.mu.Lock()
+ defer ts.mu.Unlock()
+ for ts.emuDelaySync&tw.tf.Type() != 0 {
+ ts.cond.Wait()
+ }
+ if ts.emuSyncErr&tw.tf.Type() != 0 {
+ return errors.New("leveldb.testStorage: emulated sync error")
+ }
+ err = tw.Writer.Sync()
+ if err != nil {
+ ts.t.Errorf("E: sync error, num=%d type=%v: %v", tw.tf.Num(), tw.tf.Type(), err)
+ }
+ return
+}
+
+func (tw tsWriter) Close() (err error) {
+ err = tw.Writer.Close()
+ tw.tf.close("reader", err)
+ return
+}
+
+type tsFile struct {
+ ts *testStorage
+ storage.File
+}
+
+func (tf tsFile) x() uint64 {
+ return tf.Num()<<typeShift | uint64(tf.Type())
+}
+
+func (tf tsFile) checkOpen(m string) error {
+ ts := tf.ts
+ if writer, ok := ts.opens[tf.x()]; ok {
+ if writer {
+ ts.t.Errorf("E: cannot %s file, num=%d type=%v: a writer still open", m, tf.Num(), tf.Type())
+ } else {
+ ts.t.Errorf("E: cannot %s file, num=%d type=%v: a reader still open", m, tf.Num(), tf.Type())
+ }
+ return tsErrFileOpen
+ }
+ return nil
+}
+
+func (tf tsFile) close(m string, err error) {
+ ts := tf.ts
+ ts.mu.Lock()
+ defer ts.mu.Unlock()
+ if _, ok := ts.opens[tf.x()]; !ok {
+ ts.t.Errorf("E: %s: redudant file closing, num=%d type=%v", m, tf.Num(), tf.Type())
+ } else if err == nil {
+ ts.t.Logf("I: %s: file closed, num=%d type=%v", m, tf.Num(), tf.Type())
+ }
+ delete(ts.opens, tf.x())
+ if err != nil {
+ ts.t.Errorf("E: %s: cannot close file, num=%d type=%v: %v", m, tf.Num(), tf.Type(), err)
+ }
+}
+
+func (tf tsFile) Open() (r storage.Reader, err error) {
+ ts := tf.ts
+ ts.mu.Lock()
+ defer ts.mu.Unlock()
+ err = tf.checkOpen("open")
+ if err != nil {
+ return
+ }
+ if ts.emuOpenErr&tf.Type() != 0 {
+ err = errors.New("leveldb.testStorage: emulated open error")
+ return
+ }
+ r, err = tf.File.Open()
+ if err != nil {
+ if ts.ignoreOpenErr&tf.Type() != 0 {
+ ts.t.Logf("I: cannot open file, num=%d type=%v: %v (ignored)", tf.Num(), tf.Type(), err)
+ } else {
+ ts.t.Errorf("E: cannot open file, num=%d type=%v: %v", tf.Num(), tf.Type(), err)
+ }
+ } else {
+ ts.t.Logf("I: file opened, num=%d type=%v", tf.Num(), tf.Type())
+ ts.opens[tf.x()] = false
+ r = tsReader{tf, r}
+ }
+ return
+}
+
+func (tf tsFile) Create() (w storage.Writer, err error) {
+ ts := tf.ts
+ ts.mu.Lock()
+ defer ts.mu.Unlock()
+ err = tf.checkOpen("create")
+ if err != nil {
+ return
+ }
+ if ts.emuCreateErr&tf.Type() != 0 {
+ err = errors.New("leveldb.testStorage: emulated create error")
+ return
+ }
+ w, err = tf.File.Create()
+ if err != nil {
+ ts.t.Errorf("E: cannot create file, num=%d type=%v: %v", tf.Num(), tf.Type(), err)
+ } else {
+ ts.t.Logf("I: file created, num=%d type=%v", tf.Num(), tf.Type())
+ ts.opens[tf.x()] = true
+ w = tsWriter{tf, w}
+ }
+ return
+}
+
+func (tf tsFile) Remove() (err error) {
+ ts := tf.ts
+ ts.mu.Lock()
+ defer ts.mu.Unlock()
+ err = tf.checkOpen("remove")
+ if err != nil {
+ return
+ }
+ err = tf.File.Remove()
+ if err != nil {
+ ts.t.Errorf("E: cannot remove file, num=%d type=%v: %v", tf.Num(), tf.Type(), err)
+ } else {
+ ts.t.Logf("I: file removed, num=%d type=%v", tf.Num(), tf.Type())
+ }
+ return
+}
+
+type testStorage struct {
+ t *testing.T
+ storage.Storage
+ closeFn func() error
+
+ mu sync.Mutex
+ cond sync.Cond
+ // Open files, true=writer, false=reader
+ opens map[uint64]bool
+ emuOpenErr storage.FileType
+ emuCreateErr storage.FileType
+ emuDelaySync storage.FileType
+ emuWriteErr storage.FileType
+ emuSyncErr storage.FileType
+ ignoreOpenErr storage.FileType
+ readCnt uint64
+ readCntEn storage.FileType
+}
+
+func (ts *testStorage) SetOpenErr(t storage.FileType) {
+ ts.mu.Lock()
+ ts.emuOpenErr = t
+ ts.mu.Unlock()
+}
+
+func (ts *testStorage) SetCreateErr(t storage.FileType) {
+ ts.mu.Lock()
+ ts.emuCreateErr = t
+ ts.mu.Unlock()
+}
+
+func (ts *testStorage) DelaySync(t storage.FileType) {
+ ts.mu.Lock()
+ ts.emuDelaySync |= t
+ ts.cond.Broadcast()
+ ts.mu.Unlock()
+}
+
+func (ts *testStorage) ReleaseSync(t storage.FileType) {
+ ts.mu.Lock()
+ ts.emuDelaySync &= ^t
+ ts.cond.Broadcast()
+ ts.mu.Unlock()
+}
+
+func (ts *testStorage) SetWriteErr(t storage.FileType) {
+ ts.mu.Lock()
+ ts.emuWriteErr = t
+ ts.mu.Unlock()
+}
+
+func (ts *testStorage) SetSyncErr(t storage.FileType) {
+ ts.mu.Lock()
+ ts.emuSyncErr = t
+ ts.mu.Unlock()
+}
+
+func (ts *testStorage) ReadCounter() uint64 {
+ ts.mu.Lock()
+ defer ts.mu.Unlock()
+ return ts.readCnt
+}
+
+func (ts *testStorage) ResetReadCounter() {
+ ts.mu.Lock()
+ ts.readCnt = 0
+ ts.mu.Unlock()
+}
+
+func (ts *testStorage) SetReadCounter(t storage.FileType) {
+ ts.mu.Lock()
+ ts.readCntEn = t
+ ts.mu.Unlock()
+}
+
+func (ts *testStorage) countRead(t storage.FileType) {
+ ts.mu.Lock()
+ if ts.readCntEn&t != 0 {
+ ts.readCnt++
+ }
+ ts.mu.Unlock()
+}
+
+func (ts *testStorage) SetIgnoreOpenErr(t storage.FileType) {
+ ts.ignoreOpenErr = t
+}
+
+func (ts *testStorage) Lock() (r util.Releaser, err error) {
+ r, err = ts.Storage.Lock()
+ if err != nil {
+ ts.t.Logf("W: storage locking failed: %v", err)
+ } else {
+ ts.t.Log("I: storage locked")
+ r = tsLock{ts, r}
+ }
+ return
+}
+
+func (ts *testStorage) Log(str string) {
+ ts.t.Log("L: " + str)
+ ts.Storage.Log(str)
+}
+
+func (ts *testStorage) GetFile(num uint64, t storage.FileType) storage.File {
+ return tsFile{ts, ts.Storage.GetFile(num, t)}
+}
+
+func (ts *testStorage) GetFiles(t storage.FileType) (ff []storage.File, err error) {
+ ff0, err := ts.Storage.GetFiles(t)
+ if err != nil {
+ ts.t.Errorf("E: get files failed: %v", err)
+ return
+ }
+ ff = make([]storage.File, len(ff0))
+ for i, f := range ff0 {
+ ff[i] = tsFile{ts, f}
+ }
+ ts.t.Logf("I: get files, type=0x%x count=%d", int(t), len(ff))
+ return
+}
+
+func (ts *testStorage) GetManifest() (f storage.File, err error) {
+ f0, err := ts.Storage.GetManifest()
+ if err != nil {
+ if !os.IsNotExist(err) {
+ ts.t.Errorf("E: get manifest failed: %v", err)
+ }
+ return
+ }
+ f = tsFile{ts, f0}
+ ts.t.Logf("I: get manifest, num=%d", f.Num())
+ return
+}
+
+func (ts *testStorage) SetManifest(f storage.File) error {
+ tf, ok := f.(tsFile)
+ if !ok {
+ ts.t.Error("E: set manifest failed: type assertion failed")
+ return tsErrInvalidFile
+ } else if tf.Type() != storage.TypeManifest {
+ ts.t.Errorf("E: set manifest failed: invalid file type: %s", tf.Type())
+ return tsErrInvalidFile
+ }
+ err := ts.Storage.SetManifest(tf.File)
+ if err != nil {
+ ts.t.Errorf("E: set manifest failed: %v", err)
+ } else {
+ ts.t.Logf("I: set manifest, num=%d", tf.Num())
+ }
+ return err
+}
+
+func (ts *testStorage) Close() error {
+ ts.CloseCheck()
+ err := ts.Storage.Close()
+ if err != nil {
+ ts.t.Errorf("E: closing storage failed: %v", err)
+ } else {
+ ts.t.Log("I: storage closed")
+ }
+ if ts.closeFn != nil {
+ if err := ts.closeFn(); err != nil {
+ ts.t.Errorf("E: close function: %v", err)
+ }
+ }
+ return err
+}
+
+func (ts *testStorage) CloseCheck() {
+ ts.mu.Lock()
+ if len(ts.opens) == 0 {
+ ts.t.Log("I: all files are closed")
+ } else {
+ ts.t.Errorf("E: %d files still open", len(ts.opens))
+ for x, writer := range ts.opens {
+ num, tt := x>>typeShift, storage.FileType(x)&storage.TypeAll
+ ts.t.Errorf("E: * num=%d type=%v writer=%v", num, tt, writer)
+ }
+ }
+ ts.mu.Unlock()
+}
+
+func newTestStorage(t *testing.T) *testStorage {
+ var stor storage.Storage
+ var closeFn func() error
+ if tsFS {
+ for {
+ tsMU.Lock()
+ num := tsNum
+ tsNum++
+ tsMU.Unlock()
+ path := filepath.Join(os.TempDir(), fmt.Sprintf("goleveldb-test%d0%d0%d", os.Getuid(), os.Getpid(), num))
+ if _, err := os.Stat(path); err != nil {
+ stor, err = storage.OpenFile(path)
+ if err != nil {
+ t.Fatalf("F: cannot create storage: %v", err)
+ }
+ t.Logf("I: storage created: %s", path)
+ closeFn = func() error {
+ for _, name := range []string{"LOG.old", "LOG"} {
+ f, err := os.Open(filepath.Join(path, name))
+ if err != nil {
+ continue
+ }
+ if log, err := ioutil.ReadAll(f); err != nil {
+ t.Logf("---------------------- %s ----------------------", name)
+ t.Logf("cannot read log: %v", err)
+ t.Logf("---------------------- %s ----------------------", name)
+ } else if len(log) > 0 {
+ t.Logf("---------------------- %s ----------------------\n%s", name, string(log))
+ t.Logf("---------------------- %s ----------------------", name)
+ }
+ f.Close()
+ }
+ if tsKeepFS {
+ return nil
+ }
+ return os.RemoveAll(path)
+ }
+
+ break
+ }
+ }
+ } else {
+ stor = storage.NewMemStorage()
+ }
+ ts := &testStorage{
+ t: t,
+ Storage: stor,
+ closeFn: closeFn,
+ opens: make(map[uint64]bool),
+ }
+ ts.cond.L = &ts.mu
+ return ts
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/table.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/table.go
new file mode 100644
index 000000000..fdd5d2bcf
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/table.go
@@ -0,0 +1,424 @@
+// Copyright (c) 2012, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package leveldb
+
+import (
+ "sort"
+ "sync/atomic"
+
+ "github.com/syndtr/goleveldb/leveldb/cache"
+ "github.com/syndtr/goleveldb/leveldb/comparer"
+ "github.com/syndtr/goleveldb/leveldb/iterator"
+ "github.com/syndtr/goleveldb/leveldb/opt"
+ "github.com/syndtr/goleveldb/leveldb/storage"
+ "github.com/syndtr/goleveldb/leveldb/table"
+ "github.com/syndtr/goleveldb/leveldb/util"
+)
+
+// table file
+type tFile struct {
+ file storage.File
+ seekLeft int32
+ size uint64
+ min, max iKey
+}
+
+// test if key is after t
+func (t *tFile) isAfter(key []byte, ucmp comparer.BasicComparer) bool {
+ return key != nil && ucmp.Compare(key, t.max.ukey()) > 0
+}
+
+// test if key is before t
+func (t *tFile) isBefore(key []byte, ucmp comparer.BasicComparer) bool {
+ return key != nil && ucmp.Compare(key, t.min.ukey()) < 0
+}
+
+func (t *tFile) incrSeek() int32 {
+ return atomic.AddInt32(&t.seekLeft, -1)
+}
+
+func newTFile(file storage.File, size uint64, min, max iKey) *tFile {
+ f := &tFile{
+ file: file,
+ size: size,
+ min: min,
+ max: max,
+ }
+
+ // We arrange to automatically compact this file after
+ // a certain number of seeks. Let's assume:
+ // (1) One seek costs 10ms
+ // (2) Writing or reading 1MB costs 10ms (100MB/s)
+ // (3) A compaction of 1MB does 25MB of IO:
+ // 1MB read from this level
+ // 10-12MB read from next level (boundaries may be misaligned)
+ // 10-12MB written to next level
+ // This implies that 25 seeks cost the same as the compaction
+ // of 1MB of data. I.e., one seek costs approximately the
+ // same as the compaction of 40KB of data. We are a little
+ // conservative and allow approximately one seek for every 16KB
+ // of data before triggering a compaction.
+ f.seekLeft = int32(size / 16384)
+ if f.seekLeft < 100 {
+ f.seekLeft = 100
+ }
+
+ return f
+}
+
+// table files
+type tFiles []*tFile
+
+func (tf tFiles) Len() int { return len(tf) }
+func (tf tFiles) Swap(i, j int) { tf[i], tf[j] = tf[j], tf[i] }
+
+func (tf tFiles) lessByKey(icmp *iComparer, i, j int) bool {
+ a, b := tf[i], tf[j]
+ n := icmp.Compare(a.min, b.min)
+ if n == 0 {
+ return a.file.Num() < b.file.Num()
+ }
+ return n < 0
+}
+
+func (tf tFiles) lessByNum(i, j int) bool {
+ return tf[i].file.Num() > tf[j].file.Num()
+}
+
+func (tf tFiles) sortByKey(icmp *iComparer) {
+ sort.Sort(&tFilesSortByKey{tFiles: tf, icmp: icmp})
+}
+
+func (tf tFiles) sortByNum() {
+ sort.Sort(&tFilesSortByNum{tFiles: tf})
+}
+
+func (tf tFiles) size() (sum uint64) {
+ for _, t := range tf {
+ sum += t.size
+ }
+ return sum
+}
+
+func (tf tFiles) searchMin(key iKey, icmp *iComparer) int {
+ return sort.Search(len(tf), func(i int) bool {
+ return icmp.Compare(tf[i].min, key) >= 0
+ })
+}
+
+func (tf tFiles) searchMax(key iKey, icmp *iComparer) int {
+ return sort.Search(len(tf), func(i int) bool {
+ return icmp.Compare(tf[i].max, key) >= 0
+ })
+}
+
+func (tf tFiles) isOverlaps(min, max []byte, disjSorted bool, icmp *iComparer) bool {
+ if !disjSorted {
+ // Need to check against all files
+ for _, t := range tf {
+ if !t.isAfter(min, icmp.ucmp) && !t.isBefore(max, icmp.ucmp) {
+ return true
+ }
+ }
+ return false
+ }
+
+ var idx int
+ if len(min) > 0 {
+ // Find the earliest possible internal key for min
+ idx = tf.searchMax(newIKey(min, kMaxSeq, tSeek), icmp)
+ }
+
+ if idx >= len(tf) {
+ // beginning of range is after all files, so no overlap
+ return false
+ }
+ return !tf[idx].isBefore(max, icmp.ucmp)
+}
+
+func (tf tFiles) getOverlaps(min, max []byte, r *tFiles, disjSorted bool, ucmp comparer.BasicComparer) {
+ for i := 0; i < len(tf); {
+ t := tf[i]
+ i++
+ if t.isAfter(min, ucmp) || t.isBefore(max, ucmp) {
+ continue
+ }
+
+ *r = append(*r, t)
+ if !disjSorted {
+ // Level-0 files may overlap each other. So check if the newly
+ // added file has expanded the range. If so, restart search.
+ if min != nil && ucmp.Compare(t.min.ukey(), min) < 0 {
+ min = t.min.ukey()
+ *r = nil
+ i = 0
+ } else if max != nil && ucmp.Compare(t.max.ukey(), max) > 0 {
+ max = t.max.ukey()
+ *r = nil
+ i = 0
+ }
+ }
+ }
+
+ return
+}
+
+func (tf tFiles) getRange(icmp *iComparer) (min, max iKey) {
+ for i, t := range tf {
+ if i == 0 {
+ min, max = t.min, t.max
+ continue
+ }
+ if icmp.Compare(t.min, min) < 0 {
+ min = t.min
+ }
+ if icmp.Compare(t.max, max) > 0 {
+ max = t.max
+ }
+ }
+
+ return
+}
+
+func (tf tFiles) newIndexIterator(tops *tOps, icmp *iComparer, slice *util.Range, ro *opt.ReadOptions) iterator.IteratorIndexer {
+ if slice != nil {
+ var start, limit int
+ if slice.Start != nil {
+ start = tf.searchMax(iKey(slice.Start), icmp)
+ }
+ if slice.Limit != nil {
+ limit = tf.searchMin(iKey(slice.Limit), icmp)
+ } else {
+ limit = tf.Len()
+ }
+ tf = tf[start:limit]
+ }
+ return iterator.NewArrayIndexer(&tFilesArrayIndexer{
+ tFiles: tf,
+ tops: tops,
+ icmp: icmp,
+ slice: slice,
+ ro: ro,
+ })
+}
+
+type tFilesArrayIndexer struct {
+ tFiles
+ tops *tOps
+ icmp *iComparer
+ slice *util.Range
+ ro *opt.ReadOptions
+}
+
+func (a *tFilesArrayIndexer) Search(key []byte) int {
+ return a.searchMax(iKey(key), a.icmp)
+}
+
+func (a *tFilesArrayIndexer) Get(i int) iterator.Iterator {
+ if i == 0 || i == a.Len()-1 {
+ return a.tops.newIterator(a.tFiles[i], a.slice, a.ro)
+ }
+ return a.tops.newIterator(a.tFiles[i], nil, a.ro)
+}
+
+type tFilesSortByKey struct {
+ tFiles
+ icmp *iComparer
+}
+
+func (x *tFilesSortByKey) Less(i, j int) bool {
+ return x.lessByKey(x.icmp, i, j)
+}
+
+type tFilesSortByNum struct {
+ tFiles
+}
+
+func (x *tFilesSortByNum) Less(i, j int) bool {
+ return x.lessByNum(i, j)
+}
+
+// table operations
+type tOps struct {
+ s *session
+ cache cache.Cache
+ cacheNS cache.Namespace
+}
+
+func newTableOps(s *session, cacheCap int) *tOps {
+ c := cache.NewLRUCache(cacheCap)
+ ns := c.GetNamespace(0)
+ return &tOps{s, c, ns}
+}
+
+func (t *tOps) create() (*tWriter, error) {
+ file := t.s.getTableFile(t.s.allocFileNum())
+ fw, err := file.Create()
+ if err != nil {
+ return nil, err
+ }
+ return &tWriter{
+ t: t,
+ file: file,
+ w: fw,
+ tw: table.NewWriter(fw, t.s.o),
+ }, nil
+}
+
+func (t *tOps) createFrom(src iterator.Iterator) (f *tFile, n int, err error) {
+ w, err := t.create()
+ if err != nil {
+ return f, n, err
+ }
+
+ defer func() {
+ if err != nil {
+ w.drop()
+ }
+ }()
+
+ for src.Next() {
+ err = w.add(src.Key(), src.Value())
+ if err != nil {
+ return
+ }
+ }
+ err = src.Error()
+ if err != nil {
+ return
+ }
+
+ n = w.tw.EntriesLen()
+ f, err = w.finish()
+ return
+}
+
+func (t *tOps) lookup(f *tFile) (c cache.Object, err error) {
+ num := f.file.Num()
+ c, ok := t.cacheNS.Get(num, func() (ok bool, value interface{}, charge int, fin cache.SetFin) {
+ var r storage.Reader
+ r, err = f.file.Open()
+ if err != nil {
+ return
+ }
+
+ o := t.s.o
+
+ var cacheNS cache.Namespace
+ if bc := o.GetBlockCache(); bc != nil {
+ cacheNS = bc.GetNamespace(num)
+ }
+
+ ok = true
+ value = table.NewReader(r, int64(f.size), cacheNS, o)
+ charge = 1
+ fin = func() {
+ r.Close()
+ }
+ return
+ })
+ if !ok && err == nil {
+ err = ErrClosed
+ }
+ return
+}
+
+func (t *tOps) get(f *tFile, key []byte, ro *opt.ReadOptions) (rkey, rvalue []byte, err error) {
+ c, err := t.lookup(f)
+ if err != nil {
+ return nil, nil, err
+ }
+ defer c.Release()
+ return c.Value().(*table.Reader).Find(key, ro)
+}
+
+func (t *tOps) offsetOf(f *tFile, key []byte) (offset uint64, err error) {
+ c, err := t.lookup(f)
+ if err != nil {
+ return
+ }
+ _offset, err := c.Value().(*table.Reader).OffsetOf(key)
+ offset = uint64(_offset)
+ c.Release()
+ return
+}
+
+func (t *tOps) newIterator(f *tFile, slice *util.Range, ro *opt.ReadOptions) iterator.Iterator {
+ c, err := t.lookup(f)
+ if err != nil {
+ return iterator.NewEmptyIterator(err)
+ }
+ iter := c.Value().(*table.Reader).NewIterator(slice, ro)
+ iter.SetReleaser(c)
+ return iter
+}
+
+func (t *tOps) remove(f *tFile) {
+ num := f.file.Num()
+ t.cacheNS.Delete(num, func(exist bool) {
+ if err := f.file.Remove(); err != nil {
+ t.s.logf("table@remove removing @%d %q", num, err)
+ } else {
+ t.s.logf("table@remove removed @%d", num)
+ }
+ if bc := t.s.o.GetBlockCache(); bc != nil {
+ bc.GetNamespace(num).Zap(false)
+ }
+ })
+}
+
+func (t *tOps) close() {
+ t.cache.Zap(true)
+}
+
+type tWriter struct {
+ t *tOps
+
+ file storage.File
+ w storage.Writer
+ tw *table.Writer
+
+ first, last []byte
+}
+
+func (w *tWriter) add(key, value []byte) error {
+ if w.first == nil {
+ w.first = append([]byte{}, key...)
+ }
+ w.last = append(w.last[:0], key...)
+ return w.tw.Append(key, value)
+}
+
+func (w *tWriter) empty() bool {
+ return w.first == nil
+}
+
+func (w *tWriter) finish() (f *tFile, err error) {
+ err = w.tw.Close()
+ if err != nil {
+ return
+ }
+ err = w.w.Sync()
+ if err != nil {
+ w.w.Close()
+ return
+ }
+ w.w.Close()
+ f = newTFile(w.file, uint64(w.tw.BytesLen()), iKey(w.first), iKey(w.last))
+ return
+}
+
+func (w *tWriter) drop() {
+ w.w.Close()
+ w.file.Remove()
+ w.t.s.reuseFileNum(w.file.Num())
+ w.w = nil
+ w.file = nil
+ w.tw = nil
+ w.first = nil
+ w.last = nil
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/table/block_test.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/table/block_test.go
new file mode 100644
index 000000000..ca598f4f5
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/table/block_test.go
@@ -0,0 +1,131 @@
+// Copyright (c) 2014, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package table
+
+import (
+ "encoding/binary"
+ "fmt"
+
+ . "github.com/onsi/ginkgo"
+ . "github.com/onsi/gomega"
+
+ "github.com/syndtr/goleveldb/leveldb/comparer"
+ "github.com/syndtr/goleveldb/leveldb/iterator"
+ "github.com/syndtr/goleveldb/leveldb/testutil"
+ "github.com/syndtr/goleveldb/leveldb/util"
+)
+
+func (b *block) TestNewIterator(slice *util.Range) iterator.Iterator {
+ return b.newIterator(slice, false, nil)
+}
+
+var _ = testutil.Defer(func() {
+ Describe("Block", func() {
+ Build := func(kv *testutil.KeyValue, restartInterval int) *block {
+ // Building the block.
+ bw := &blockWriter{
+ restartInterval: restartInterval,
+ scratch: make([]byte, 30),
+ }
+ kv.Iterate(func(i int, key, value []byte) {
+ bw.append(key, value)
+ })
+ bw.finish()
+
+ // Opening the block.
+ data := bw.buf.Bytes()
+ restartsLen := int(binary.LittleEndian.Uint32(data[len(data)-4:]))
+ return &block{
+ cmp: comparer.DefaultComparer,
+ data: data,
+ restartsLen: restartsLen,
+ restartsOffset: len(data) - (restartsLen+1)*4,
+ }
+ }
+
+ Describe("read test", func() {
+ for restartInterval := 1; restartInterval <= 5; restartInterval++ {
+ Describe(fmt.Sprintf("with restart interval of %d", restartInterval), func() {
+ kv := &testutil.KeyValue{}
+ Text := func() string {
+ return fmt.Sprintf("and %d keys", kv.Len())
+ }
+
+ Test := func() {
+ // Make block.
+ br := Build(kv, restartInterval)
+ // Do testing.
+ testutil.KeyValueTesting(nil, br, kv.Clone())
+ }
+
+ Describe(Text(), Test)
+
+ kv.PutString("", "empty")
+ Describe(Text(), Test)
+
+ kv.PutString("a1", "foo")
+ Describe(Text(), Test)
+
+ kv.PutString("a2", "v")
+ Describe(Text(), Test)
+
+ kv.PutString("a3qqwrkks", "hello")
+ Describe(Text(), Test)
+
+ kv.PutString("a4", "bar")
+ Describe(Text(), Test)
+
+ kv.PutString("a5111111", "v5")
+ kv.PutString("a6", "")
+ kv.PutString("a7", "v7")
+ kv.PutString("a8", "vvvvvvvvvvvvvvvvvvvvvv8")
+ kv.PutString("b", "v9")
+ kv.PutString("c9", "v9")
+ kv.PutString("c91", "v9")
+ kv.PutString("d0", "v9")
+ Describe(Text(), Test)
+ })
+ }
+ })
+
+ Describe("out-of-bound slice test", func() {
+ kv := &testutil.KeyValue{}
+ kv.PutString("k1", "v1")
+ kv.PutString("k2", "v2")
+ kv.PutString("k3abcdefgg", "v3")
+ kv.PutString("k4", "v4")
+ kv.PutString("k5", "v5")
+ for restartInterval := 1; restartInterval <= 5; restartInterval++ {
+ Describe(fmt.Sprintf("with restart interval of %d", restartInterval), func() {
+ // Make block.
+ br := Build(kv, restartInterval)
+
+ Test := func(r *util.Range) func(done Done) {
+ return func(done Done) {
+ iter := br.newIterator(r, false, nil)
+ Expect(iter.Error()).ShouldNot(HaveOccurred())
+
+ t := testutil.IteratorTesting{
+ KeyValue: kv.Clone(),
+ Iter: iter,
+ }
+
+ testutil.DoIteratorTesting(&t)
+ done <- true
+ }
+ }
+
+ It("Should do iterations and seeks correctly #0",
+ Test(&util.Range{Start: []byte("k0"), Limit: []byte("k6")}), 2.0)
+
+ It("Should do iterations and seeks correctly #1",
+ Test(&util.Range{Start: []byte(""), Limit: []byte("zzzzzzz")}), 2.0)
+ })
+ }
+ })
+ })
+})
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/table/reader.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/table/reader.go
new file mode 100644
index 000000000..8acb9f720
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/table/reader.go
@@ -0,0 +1,848 @@
+// Copyright (c) 2012, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package table
+
+import (
+ "encoding/binary"
+ "errors"
+ "fmt"
+ "io"
+ "sort"
+ "strings"
+
+ "code.google.com/p/snappy-go/snappy"
+
+ "github.com/syndtr/goleveldb/leveldb/cache"
+ "github.com/syndtr/goleveldb/leveldb/comparer"
+ "github.com/syndtr/goleveldb/leveldb/filter"
+ "github.com/syndtr/goleveldb/leveldb/iterator"
+ "github.com/syndtr/goleveldb/leveldb/opt"
+ "github.com/syndtr/goleveldb/leveldb/util"
+)
+
+var (
+ ErrNotFound = util.ErrNotFound
+ ErrIterReleased = errors.New("leveldb/table: iterator released")
+)
+
+func max(x, y int) int {
+ if x > y {
+ return x
+ }
+ return y
+}
+
+type block struct {
+ cmp comparer.BasicComparer
+ data []byte
+ restartsLen int
+ restartsOffset int
+ // Whether checksum is verified and valid.
+ checksum bool
+}
+
+func (b *block) seek(rstart, rlimit int, key []byte) (index, offset int, err error) {
+ n := b.restartsOffset
+ data := b.data
+ cmp := b.cmp
+
+ index = sort.Search(b.restartsLen-rstart-(b.restartsLen-rlimit), func(i int) bool {
+ offset := int(binary.LittleEndian.Uint32(data[n+4*(rstart+i):]))
+ offset += 1 // shared always zero, since this is a restart point
+ v1, n1 := binary.Uvarint(data[offset:]) // key length
+ _, n2 := binary.Uvarint(data[offset+n1:]) // value length
+ m := offset + n1 + n2
+ return cmp.Compare(data[m:m+int(v1)], key) > 0
+ }) + rstart - 1
+ if index < rstart {
+ // The smallest key is greater-than key sought.
+ index = rstart
+ }
+ offset = int(binary.LittleEndian.Uint32(data[n+4*index:]))
+ return
+}
+
+func (b *block) restartIndex(rstart, rlimit, offset int) int {
+ n := b.restartsOffset
+ data := b.data
+ return sort.Search(b.restartsLen-rstart-(b.restartsLen-rlimit), func(i int) bool {
+ return int(binary.LittleEndian.Uint32(data[n+4*(rstart+i):])) > offset
+ }) + rstart - 1
+}
+
+func (b *block) restartOffset(index int) int {
+ return int(binary.LittleEndian.Uint32(b.data[b.restartsOffset+4*index:]))
+}
+
+func (b *block) entry(offset int) (key, value []byte, nShared, n int, err error) {
+ if offset >= b.restartsOffset {
+ if offset != b.restartsOffset {
+ err = errors.New("leveldb/table: Reader: BlockEntry: invalid block (block entries offset not aligned)")
+ }
+ return
+ }
+ v0, n0 := binary.Uvarint(b.data[offset:]) // Shared prefix length
+ v1, n1 := binary.Uvarint(b.data[offset+n0:]) // Key length
+ v2, n2 := binary.Uvarint(b.data[offset+n0+n1:]) // Value length
+ m := n0 + n1 + n2
+ n = m + int(v1) + int(v2)
+ if n0 <= 0 || n1 <= 0 || n2 <= 0 || offset+n > b.restartsOffset {
+ err = errors.New("leveldb/table: Reader: invalid block (block entries corrupted)")
+ return
+ }
+ key = b.data[offset+m : offset+m+int(v1)]
+ value = b.data[offset+m+int(v1) : offset+n]
+ nShared = int(v0)
+ return
+}
+
+func (b *block) newIterator(slice *util.Range, inclLimit bool, cache util.Releaser) *blockIter {
+ bi := &blockIter{
+ block: b,
+ cache: cache,
+ // Valid key should never be nil.
+ key: make([]byte, 0),
+ dir: dirSOI,
+ riStart: 0,
+ riLimit: b.restartsLen,
+ offsetStart: 0,
+ offsetRealStart: 0,
+ offsetLimit: b.restartsOffset,
+ }
+ if slice != nil {
+ if slice.Start != nil {
+ if bi.Seek(slice.Start) {
+ bi.riStart = b.restartIndex(bi.restartIndex, b.restartsLen, bi.prevOffset)
+ bi.offsetStart = b.restartOffset(bi.riStart)
+ bi.offsetRealStart = bi.prevOffset
+ } else {
+ bi.riStart = b.restartsLen
+ bi.offsetStart = b.restartsOffset
+ bi.offsetRealStart = b.restartsOffset
+ }
+ }
+ if slice.Limit != nil {
+ if bi.Seek(slice.Limit) && (!inclLimit || bi.Next()) {
+ bi.offsetLimit = bi.prevOffset
+ bi.riLimit = bi.restartIndex + 1
+ }
+ }
+ bi.reset()
+ if bi.offsetStart > bi.offsetLimit {
+ bi.sErr(errors.New("leveldb/table: Reader: invalid slice range"))
+ }
+ }
+ return bi
+}
+
+type dir int
+
+const (
+ dirReleased dir = iota - 1
+ dirSOI
+ dirEOI
+ dirBackward
+ dirForward
+)
+
+type blockIter struct {
+ block *block
+ cache, releaser util.Releaser
+ key, value []byte
+ offset int
+ // Previous offset, only filled by Next.
+ prevOffset int
+ prevNode []int
+ prevKeys []byte
+ restartIndex int
+ // Iterator direction.
+ dir dir
+ // Restart index slice range.
+ riStart int
+ riLimit int
+ // Offset slice range.
+ offsetStart int
+ offsetRealStart int
+ offsetLimit int
+ // Error.
+ err error
+}
+
+func (i *blockIter) sErr(err error) {
+ i.err = err
+ i.key = nil
+ i.value = nil
+ i.prevNode = nil
+ i.prevKeys = nil
+}
+
+func (i *blockIter) reset() {
+ if i.dir == dirBackward {
+ i.prevNode = i.prevNode[:0]
+ i.prevKeys = i.prevKeys[:0]
+ }
+ i.restartIndex = i.riStart
+ i.offset = i.offsetStart
+ i.dir = dirSOI
+ i.key = i.key[:0]
+ i.value = nil
+}
+
+func (i *blockIter) isFirst() bool {
+ switch i.dir {
+ case dirForward:
+ return i.prevOffset == i.offsetRealStart
+ case dirBackward:
+ return len(i.prevNode) == 1 && i.restartIndex == i.riStart
+ }
+ return false
+}
+
+func (i *blockIter) isLast() bool {
+ switch i.dir {
+ case dirForward, dirBackward:
+ return i.offset == i.offsetLimit
+ }
+ return false
+}
+
+func (i *blockIter) First() bool {
+ if i.err != nil {
+ return false
+ } else if i.dir == dirReleased {
+ i.err = ErrIterReleased
+ return false
+ }
+
+ if i.dir == dirBackward {
+ i.prevNode = i.prevNode[:0]
+ i.prevKeys = i.prevKeys[:0]
+ }
+ i.dir = dirSOI
+ return i.Next()
+}
+
+func (i *blockIter) Last() bool {
+ if i.err != nil {
+ return false
+ } else if i.dir == dirReleased {
+ i.err = ErrIterReleased
+ return false
+ }
+
+ if i.dir == dirBackward {
+ i.prevNode = i.prevNode[:0]
+ i.prevKeys = i.prevKeys[:0]
+ }
+ i.dir = dirEOI
+ return i.Prev()
+}
+
+func (i *blockIter) Seek(key []byte) bool {
+ if i.err != nil {
+ return false
+ } else if i.dir == dirReleased {
+ i.err = ErrIterReleased
+ return false
+ }
+
+ ri, offset, err := i.block.seek(i.riStart, i.riLimit, key)
+ if err != nil {
+ i.sErr(err)
+ return false
+ }
+ i.restartIndex = ri
+ i.offset = max(i.offsetStart, offset)
+ if i.dir == dirSOI || i.dir == dirEOI {
+ i.dir = dirForward
+ }
+ for i.Next() {
+ if i.block.cmp.Compare(i.key, key) >= 0 {
+ return true
+ }
+ }
+ return false
+}
+
+func (i *blockIter) Next() bool {
+ if i.dir == dirEOI || i.err != nil {
+ return false
+ } else if i.dir == dirReleased {
+ i.err = ErrIterReleased
+ return false
+ }
+
+ if i.dir == dirSOI {
+ i.restartIndex = i.riStart
+ i.offset = i.offsetStart
+ } else if i.dir == dirBackward {
+ i.prevNode = i.prevNode[:0]
+ i.prevKeys = i.prevKeys[:0]
+ }
+ for i.offset < i.offsetRealStart {
+ key, value, nShared, n, err := i.block.entry(i.offset)
+ if err != nil {
+ i.sErr(err)
+ return false
+ }
+ if n == 0 {
+ i.dir = dirEOI
+ return false
+ }
+ i.key = append(i.key[:nShared], key...)
+ i.value = value
+ i.offset += n
+ }
+ if i.offset >= i.offsetLimit {
+ i.dir = dirEOI
+ if i.offset != i.offsetLimit {
+ i.sErr(errors.New("leveldb/table: Reader: Next: invalid block (block entries offset not aligned)"))
+ }
+ return false
+ }
+ key, value, nShared, n, err := i.block.entry(i.offset)
+ if err != nil {
+ i.sErr(err)
+ return false
+ }
+ if n == 0 {
+ i.dir = dirEOI
+ return false
+ }
+ i.key = append(i.key[:nShared], key...)
+ i.value = value
+ i.prevOffset = i.offset
+ i.offset += n
+ i.dir = dirForward
+ return true
+}
+
+func (i *blockIter) Prev() bool {
+ if i.dir == dirSOI || i.err != nil {
+ return false
+ } else if i.dir == dirReleased {
+ i.err = ErrIterReleased
+ return false
+ }
+
+ var ri int
+ if i.dir == dirForward {
+ // Change direction.
+ i.offset = i.prevOffset
+ if i.offset == i.offsetRealStart {
+ i.dir = dirSOI
+ return false
+ }
+ ri = i.block.restartIndex(i.restartIndex, i.riLimit, i.offset)
+ i.dir = dirBackward
+ } else if i.dir == dirEOI {
+ // At the end of iterator.
+ i.restartIndex = i.riLimit
+ i.offset = i.offsetLimit
+ if i.offset == i.offsetRealStart {
+ i.dir = dirSOI
+ return false
+ }
+ ri = i.riLimit - 1
+ i.dir = dirBackward
+ } else if len(i.prevNode) == 1 {
+ // This is the end of a restart range.
+ i.offset = i.prevNode[0]
+ i.prevNode = i.prevNode[:0]
+ if i.restartIndex == i.riStart {
+ i.dir = dirSOI
+ return false
+ }
+ i.restartIndex--
+ ri = i.restartIndex
+ } else {
+ // In the middle of restart range, get from cache.
+ n := len(i.prevNode) - 3
+ node := i.prevNode[n:]
+ i.prevNode = i.prevNode[:n]
+ // Get the key.
+ ko := node[0]
+ i.key = append(i.key[:0], i.prevKeys[ko:]...)
+ i.prevKeys = i.prevKeys[:ko]
+ // Get the value.
+ vo := node[1]
+ vl := vo + node[2]
+ i.value = i.block.data[vo:vl]
+ i.offset = vl
+ return true
+ }
+ // Build entries cache.
+ i.key = i.key[:0]
+ i.value = nil
+ offset := i.block.restartOffset(ri)
+ if offset == i.offset {
+ ri -= 1
+ if ri < 0 {
+ i.dir = dirSOI
+ return false
+ }
+ offset = i.block.restartOffset(ri)
+ }
+ i.prevNode = append(i.prevNode, offset)
+ for {
+ key, value, nShared, n, err := i.block.entry(offset)
+ if err != nil {
+ i.sErr(err)
+ return false
+ }
+ if offset >= i.offsetRealStart {
+ if i.value != nil {
+ // Appends 3 variables:
+ // 1. Previous keys offset
+ // 2. Value offset in the data block
+ // 3. Value length
+ i.prevNode = append(i.prevNode, len(i.prevKeys), offset-len(i.value), len(i.value))
+ i.prevKeys = append(i.prevKeys, i.key...)
+ }
+ i.value = value
+ }
+ i.key = append(i.key[:nShared], key...)
+ offset += n
+ // Stop if target offset reached.
+ if offset >= i.offset {
+ if offset != i.offset {
+ i.sErr(errors.New("leveldb/table: Reader: Prev: invalid block (block entries offset not aligned)"))
+ return false
+ }
+
+ break
+ }
+ }
+ i.restartIndex = ri
+ i.offset = offset
+ return true
+}
+
+func (i *blockIter) Key() []byte {
+ if i.err != nil || i.dir <= dirEOI {
+ return nil
+ }
+ return i.key
+}
+
+func (i *blockIter) Value() []byte {
+ if i.err != nil || i.dir <= dirEOI {
+ return nil
+ }
+ return i.value
+}
+
+func (i *blockIter) Release() {
+ i.prevNode = nil
+ i.prevKeys = nil
+ i.key = nil
+ i.value = nil
+ i.dir = dirReleased
+ if i.cache != nil {
+ i.cache.Release()
+ i.cache = nil
+ }
+ if i.releaser != nil {
+ i.releaser.Release()
+ i.releaser = nil
+ }
+}
+
+func (i *blockIter) SetReleaser(releaser util.Releaser) {
+ if i.dir > dirReleased {
+ i.releaser = releaser
+ }
+}
+
+func (i *blockIter) Valid() bool {
+ return i.err == nil && (i.dir == dirBackward || i.dir == dirForward)
+}
+
+func (i *blockIter) Error() error {
+ return i.err
+}
+
+type filterBlock struct {
+ filter filter.Filter
+ data []byte
+ oOffset int
+ baseLg uint
+ filtersNum int
+}
+
+func (b *filterBlock) contains(offset uint64, key []byte) bool {
+ i := int(offset >> b.baseLg)
+ if i < b.filtersNum {
+ o := b.data[b.oOffset+i*4:]
+ n := int(binary.LittleEndian.Uint32(o))
+ m := int(binary.LittleEndian.Uint32(o[4:]))
+ if n < m && m <= b.oOffset {
+ return b.filter.Contains(b.data[n:m], key)
+ } else if n == m {
+ return false
+ }
+ }
+ return true
+}
+
+type indexIter struct {
+ blockIter
+ tableReader *Reader
+ slice *util.Range
+ // Options
+ checksum bool
+ fillCache bool
+}
+
+func (i *indexIter) Get() iterator.Iterator {
+ value := i.Value()
+ if value == nil {
+ return nil
+ }
+ dataBH, n := decodeBlockHandle(value)
+ if n == 0 {
+ return iterator.NewEmptyIterator(errors.New("leveldb/table: Reader: invalid table (bad data block handle)"))
+ }
+ var slice *util.Range
+ if i.slice != nil && (i.blockIter.isFirst() || i.blockIter.isLast()) {
+ slice = i.slice
+ }
+ return i.tableReader.getDataIter(dataBH, slice, i.checksum, i.fillCache)
+}
+
+// Reader is a table reader.
+type Reader struct {
+ reader io.ReaderAt
+ cache cache.Namespace
+ err error
+ // Options
+ cmp comparer.Comparer
+ filter filter.Filter
+ checksum bool
+ strictIter bool
+
+ dataEnd int64
+ indexBlock *block
+ filterBlock *filterBlock
+}
+
+func verifyChecksum(data []byte) bool {
+ n := len(data) - 4
+ checksum0 := binary.LittleEndian.Uint32(data[n:])
+ checksum1 := util.NewCRC(data[:n]).Value()
+ return checksum0 == checksum1
+}
+
+func (r *Reader) readRawBlock(bh blockHandle, checksum bool) ([]byte, error) {
+ data := make([]byte, bh.length+blockTrailerLen)
+ if _, err := r.reader.ReadAt(data, int64(bh.offset)); err != nil && err != io.EOF {
+ return nil, err
+ }
+ if checksum || r.checksum {
+ if !verifyChecksum(data) {
+ return nil, errors.New("leveldb/table: Reader: invalid block (checksum mismatch)")
+ }
+ }
+ switch data[bh.length] {
+ case blockTypeNoCompression:
+ data = data[:bh.length]
+ case blockTypeSnappyCompression:
+ var err error
+ data, err = snappy.Decode(nil, data[:bh.length])
+ if err != nil {
+ return nil, err
+ }
+ default:
+ return nil, fmt.Errorf("leveldb/table: Reader: unknown block compression type: %d", data[bh.length])
+ }
+ return data, nil
+}
+
+func (r *Reader) readBlock(bh blockHandle, checksum bool) (*block, error) {
+ data, err := r.readRawBlock(bh, checksum)
+ if err != nil {
+ return nil, err
+ }
+ restartsLen := int(binary.LittleEndian.Uint32(data[len(data)-4:]))
+ b := &block{
+ cmp: r.cmp,
+ data: data,
+ restartsLen: restartsLen,
+ restartsOffset: len(data) - (restartsLen+1)*4,
+ checksum: checksum || r.checksum,
+ }
+ return b, nil
+}
+
+func (r *Reader) readFilterBlock(bh blockHandle, filter filter.Filter) (*filterBlock, error) {
+ data, err := r.readRawBlock(bh, true)
+ if err != nil {
+ return nil, err
+ }
+ n := len(data)
+ if n < 5 {
+ return nil, errors.New("leveldb/table: Reader: invalid filter block (too short)")
+ }
+ m := n - 5
+ oOffset := int(binary.LittleEndian.Uint32(data[m:]))
+ if oOffset > m {
+ return nil, errors.New("leveldb/table: Reader: invalid filter block (invalid offset)")
+ }
+ b := &filterBlock{
+ filter: filter,
+ data: data,
+ oOffset: oOffset,
+ baseLg: uint(data[n-1]),
+ filtersNum: (m - oOffset) / 4,
+ }
+ return b, nil
+}
+
+func (r *Reader) getDataIter(dataBH blockHandle, slice *util.Range, checksum, fillCache bool) iterator.Iterator {
+ if r.cache != nil {
+ // Get/set block cache.
+ var err error
+ cache, ok := r.cache.Get(dataBH.offset, func() (ok bool, value interface{}, charge int, fin cache.SetFin) {
+ if !fillCache {
+ return
+ }
+ var dataBlock *block
+ dataBlock, err = r.readBlock(dataBH, checksum)
+ if err == nil {
+ ok = true
+ value = dataBlock
+ charge = int(dataBH.length)
+ }
+ return
+ })
+ if err != nil {
+ return iterator.NewEmptyIterator(err)
+ }
+ if ok {
+ dataBlock := cache.Value().(*block)
+ if !dataBlock.checksum && (r.checksum || checksum) {
+ if !verifyChecksum(dataBlock.data) {
+ return iterator.NewEmptyIterator(errors.New("leveldb/table: Reader: invalid block (checksum mismatch)"))
+ }
+ dataBlock.checksum = true
+ }
+ iter := dataBlock.newIterator(slice, false, cache)
+ return iter
+ }
+ }
+ dataBlock, err := r.readBlock(dataBH, checksum)
+ if err != nil {
+ return iterator.NewEmptyIterator(err)
+ }
+ iter := dataBlock.newIterator(slice, false, nil)
+ return iter
+}
+
+// NewIterator creates an iterator from the table.
+//
+// Slice allows slicing the iterator to only contains keys in the given
+// range. A nil Range.Start is treated as a key before all keys in the
+// table. And a nil Range.Limit is treated as a key after all keys in
+// the table.
+//
+// The returned iterator is not goroutine-safe and should be released
+// when not used.
+//
+// Also read Iterator documentation of the leveldb/iterator package.
+
+func (r *Reader) NewIterator(slice *util.Range, ro *opt.ReadOptions) iterator.Iterator {
+ if r.err != nil {
+ return iterator.NewEmptyIterator(r.err)
+ }
+
+ index := &indexIter{
+ blockIter: *r.indexBlock.newIterator(slice, true, nil),
+ tableReader: r,
+ slice: slice,
+ checksum: ro.GetStrict(opt.StrictBlockChecksum),
+ fillCache: !ro.GetDontFillCache(),
+ }
+ return iterator.NewIndexedIterator(index, r.strictIter || ro.GetStrict(opt.StrictIterator), false)
+}
+
+// Find finds key/value pair whose key is greater than or equal to the
+// given key. It returns ErrNotFound if the table doesn't contain
+// such pair.
+//
+// The caller should not modify the contents of the returned slice, but
+// it is safe to modify the contents of the argument after Find returns.
+func (r *Reader) Find(key []byte, ro *opt.ReadOptions) (rkey, value []byte, err error) {
+ if r.err != nil {
+ err = r.err
+ return
+ }
+
+ index := r.indexBlock.newIterator(nil, true, nil)
+ defer index.Release()
+ if !index.Seek(key) {
+ err = index.Error()
+ if err == nil {
+ err = ErrNotFound
+ }
+ return
+ }
+ dataBH, n := decodeBlockHandle(index.Value())
+ if n == 0 {
+ err = errors.New("leveldb/table: Reader: invalid table (bad data block handle)")
+ return
+ }
+ if r.filterBlock != nil && !r.filterBlock.contains(dataBH.offset, key) {
+ err = ErrNotFound
+ return
+ }
+ data := r.getDataIter(dataBH, nil, ro.GetStrict(opt.StrictBlockChecksum), !ro.GetDontFillCache())
+ defer data.Release()
+ if !data.Seek(key) {
+ err = data.Error()
+ if err == nil {
+ err = ErrNotFound
+ }
+ return
+ }
+ rkey = data.Key()
+ value = data.Value()
+ return
+}
+
+// Get gets the value for the given key. It returns errors.ErrNotFound
+// if the table does not contain the key.
+//
+// The caller should not modify the contents of the returned slice, but
+// it is safe to modify the contents of the argument after Get returns.
+func (r *Reader) Get(key []byte, ro *opt.ReadOptions) (value []byte, err error) {
+ if r.err != nil {
+ err = r.err
+ return
+ }
+
+ rkey, value, err := r.Find(key, ro)
+ if err == nil && r.cmp.Compare(rkey, key) != 0 {
+ value = nil
+ err = ErrNotFound
+ }
+ return
+}
+
+// OffsetOf returns approximate offset for the given key.
+//
+// It is safe to modify the contents of the argument after Get returns.
+func (r *Reader) OffsetOf(key []byte) (offset int64, err error) {
+ if r.err != nil {
+ err = r.err
+ return
+ }
+
+ index := r.indexBlock.newIterator(nil, true, nil)
+ defer index.Release()
+ if index.Seek(key) {
+ dataBH, n := decodeBlockHandle(index.Value())
+ if n == 0 {
+ err = errors.New("leveldb/table: Reader: invalid table (bad data block handle)")
+ return
+ }
+ offset = int64(dataBH.offset)
+ return
+ }
+ err = index.Error()
+ if err == nil {
+ offset = r.dataEnd
+ }
+ return
+}
+
+// NewReader creates a new initialized table reader for the file.
+// The cache is optional and can be nil.
+func NewReader(f io.ReaderAt, size int64, cache cache.Namespace, o *opt.Options) *Reader {
+ r := &Reader{
+ reader: f,
+ cache: cache,
+ cmp: o.GetComparer(),
+ checksum: o.GetStrict(opt.StrictBlockChecksum),
+ strictIter: o.GetStrict(opt.StrictIterator),
+ }
+ if f == nil {
+ r.err = errors.New("leveldb/table: Reader: nil file")
+ return r
+ }
+ if size < footerLen {
+ r.err = errors.New("leveldb/table: Reader: invalid table (file size is too small)")
+ return r
+ }
+ var footer [footerLen]byte
+ if _, err := r.reader.ReadAt(footer[:], size-footerLen); err != nil && err != io.EOF {
+ r.err = fmt.Errorf("leveldb/table: Reader: invalid table (could not read footer): %v", err)
+ }
+ if string(footer[footerLen-len(magic):footerLen]) != magic {
+ r.err = errors.New("leveldb/table: Reader: invalid table (bad magic number)")
+ return r
+ }
+ // Decode the metaindex block handle.
+ metaBH, n := decodeBlockHandle(footer[:])
+ if n == 0 {
+ r.err = errors.New("leveldb/table: Reader: invalid table (bad metaindex block handle)")
+ return r
+ }
+ // Decode the index block handle.
+ indexBH, n := decodeBlockHandle(footer[n:])
+ if n == 0 {
+ r.err = errors.New("leveldb/table: Reader: invalid table (bad index block handle)")
+ return r
+ }
+ // Read index block.
+ r.indexBlock, r.err = r.readBlock(indexBH, true)
+ if r.err != nil {
+ return r
+ }
+ // Read metaindex block.
+ metaBlock, err := r.readBlock(metaBH, true)
+ if err != nil {
+ r.err = err
+ return r
+ }
+ // Set data end.
+ r.dataEnd = int64(metaBH.offset)
+ metaIter := metaBlock.newIterator(nil, false, nil)
+ for metaIter.Next() {
+ key := string(metaIter.Key())
+ if !strings.HasPrefix(key, "filter.") {
+ continue
+ }
+ fn := key[7:]
+ var filter filter.Filter
+ if f0 := o.GetFilter(); f0 != nil && f0.Name() == fn {
+ filter = f0
+ } else {
+ for _, f0 := range o.GetAltFilters() {
+ if f0.Name() == fn {
+ filter = f0
+ break
+ }
+ }
+ }
+ if filter != nil {
+ filterBH, n := decodeBlockHandle(metaIter.Value())
+ if n == 0 {
+ continue
+ }
+ // Update data end.
+ r.dataEnd = int64(filterBH.offset)
+ filterBlock, err := r.readFilterBlock(filterBH, filter)
+ if err != nil {
+ continue
+ }
+ r.filterBlock = filterBlock
+ break
+ }
+ }
+ metaIter.Release()
+ return r
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/table/table.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/table/table.go
new file mode 100644
index 000000000..c0ac70d9e
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/table/table.go
@@ -0,0 +1,177 @@
+// Copyright (c) 2012, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Package table allows read and write sorted key/value.
+package table
+
+import (
+ "encoding/binary"
+)
+
+/*
+Table:
+
+Table is consist of one or more data blocks, an optional filter block
+a metaindex block, an index block and a table footer. Metaindex block
+is a special block used to keep parameters of the table, such as filter
+block name and its block handle. Index block is a special block used to
+keep record of data blocks offset and length, index block use one as
+restart interval. The key used by index block are the last key of preceding
+block, shorter separator of adjacent blocks or shorter successor of the
+last key of the last block. Filter block is an optional block contains
+sequence of filter data generated by a filter generator.
+
+Table data structure:
+ + optional
+ /
+ +--------------+--------------+--------------+------+-------+-----------------+-------------+--------+
+ | data block 1 | ... | data block n | filter block | metaindex block | index block | footer |
+ +--------------+--------------+--------------+--------------+-----------------+-------------+--------+
+
+ Each block followed by a 5-bytes trailer contains compression type and checksum.
+
+Table block trailer:
+
+ +---------------------------+-------------------+
+ | compression type (1-byte) | checksum (4-byte) |
+ +---------------------------+-------------------+
+
+ The checksum is a CRC-32 computed using Castagnoli's polynomial. Compression
+ type also included in the checksum.
+
+Table footer:
+
+ +------------------- 40-bytes -------------------+
+ / \
+ +------------------------+--------------------+------+-----------------+
+ | metaindex block handle / index block handle / ---- | magic (8-bytes) |
+ +------------------------+--------------------+------+-----------------+
+
+ The magic are first 64-bit of SHA-1 sum of "http://code.google.com/p/leveldb/".
+
+NOTE: All fixed-length integer are little-endian.
+*/
+
+/*
+Block:
+
+Block is consist of one or more key/value entries and a block trailer.
+Block entry shares key prefix with its preceding key until a restart
+point reached. A block should contains at least one restart point.
+First restart point are always zero.
+
+Block data structure:
+
+ + restart point + restart point (depends on restart interval)
+ / /
+ +---------------+---------------+---------------+---------------+---------+
+ | block entry 1 | block entry 2 | ... | block entry n | trailer |
+ +---------------+---------------+---------------+---------------+---------+
+
+Key/value entry:
+
+ +---- key len ----+
+ / \
+ +-------+---------+-----------+---------+--------------------+--------------+----------------+
+ | shared (varint) | not shared (varint) | value len (varint) | key (varlen) | value (varlen) |
+ +-----------------+---------------------+--------------------+--------------+----------------+
+
+ Block entry shares key prefix with its preceding key:
+ Conditions:
+ restart_interval=2
+ entry one : key=deck,value=v1
+ entry two : key=dock,value=v2
+ entry three: key=duck,value=v3
+ The entries will be encoded as follow:
+
+ + restart point (offset=0) + restart point (offset=16)
+ / /
+ +-----+-----+-----+----------+--------+-----+-----+-----+---------+--------+-----+-----+-----+----------+--------+
+ | 0 | 4 | 2 | "deck" | "v1" | 1 | 3 | 2 | "ock" | "v2" | 0 | 4 | 2 | "duck" | "v3" |
+ +-----+-----+-----+----------+--------+-----+-----+-----+---------+--------+-----+-----+-----+----------+--------+
+ \ / \ / \ /
+ +----------- entry one -----------+ +----------- entry two ----------+ +---------- entry three ----------+
+
+ The block trailer will contains two restart points:
+
+ +------------+-----------+--------+
+ | 0 | 16 | 2 |
+ +------------+-----------+---+----+
+ \ / \
+ +-- restart points --+ + restart points length
+
+Block trailer:
+
+ +-- 4-bytes --+
+ / \
+ +-----------------+-----------------+-----------------+------------------------------+
+ | restart point 1 | .... | restart point n | restart points len (4-bytes) |
+ +-----------------+-----------------+-----------------+------------------------------+
+
+
+NOTE: All fixed-length integer are little-endian.
+*/
+
+/*
+Filter block:
+
+Filter block consist of one or more filter data and a filter block trailer.
+The trailer contains filter data offsets, a trailer offset and a 1-byte base Lg.
+
+Filter block data structure:
+
+ + offset 1 + offset 2 + offset n + trailer offset
+ / / / /
+ +---------------+---------------+---------------+---------+
+ | filter data 1 | ... | filter data n | trailer |
+ +---------------+---------------+---------------+---------+
+
+Filter block trailer:
+
+ +- 4-bytes -+
+ / \
+ +---------------+---------------+---------------+-------------------------+------------------+
+ | offset 1 | .... | offset n | filter offset (4-bytes) | base Lg (1-byte) |
+ +-------------- +---------------+---------------+-------------------------+------------------+
+
+
+NOTE: All fixed-length integer are little-endian.
+*/
+
+const (
+ blockTrailerLen = 5
+ footerLen = 48
+
+ magic = "\x57\xfb\x80\x8b\x24\x75\x47\xdb"
+
+ // The block type gives the per-block compression format.
+ // These constants are part of the file format and should not be changed.
+ blockTypeNoCompression = 0
+ blockTypeSnappyCompression = 1
+
+ // Generate new filter every 2KB of data
+ filterBaseLg = 11
+ filterBase = 1 << filterBaseLg
+)
+
+type blockHandle struct {
+ offset, length uint64
+}
+
+func decodeBlockHandle(src []byte) (blockHandle, int) {
+ offset, n := binary.Uvarint(src)
+ length, m := binary.Uvarint(src[n:])
+ if n == 0 || m == 0 {
+ return blockHandle{}, 0
+ }
+ return blockHandle{offset, length}, n + m
+}
+
+func encodeBlockHandle(dst []byte, b blockHandle) int {
+ n := binary.PutUvarint(dst, b.offset)
+ m := binary.PutUvarint(dst[n:], b.length)
+ return n + m
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/table/table_suite_test.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/table/table_suite_test.go
new file mode 100644
index 000000000..bc9eb83cc
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/table/table_suite_test.go
@@ -0,0 +1,17 @@
+package table
+
+import (
+ "testing"
+
+ . "github.com/onsi/ginkgo"
+ . "github.com/onsi/gomega"
+
+ "github.com/syndtr/goleveldb/leveldb/testutil"
+)
+
+func TestTable(t *testing.T) {
+ testutil.RunDefer()
+
+ RegisterFailHandler(Fail)
+ RunSpecs(t, "Table Suite")
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/table/table_test.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/table/table_test.go
new file mode 100644
index 000000000..d7d3b2a4b
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/table/table_test.go
@@ -0,0 +1,119 @@
+// Copyright (c) 2014, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package table
+
+import (
+ "bytes"
+
+ . "github.com/onsi/ginkgo"
+ . "github.com/onsi/gomega"
+
+ "github.com/syndtr/goleveldb/leveldb/iterator"
+ "github.com/syndtr/goleveldb/leveldb/opt"
+ "github.com/syndtr/goleveldb/leveldb/testutil"
+ "github.com/syndtr/goleveldb/leveldb/util"
+)
+
+type tableWrapper struct {
+ *Reader
+}
+
+func (t tableWrapper) TestFind(key []byte) (rkey, rvalue []byte, err error) {
+ return t.Reader.Find(key, nil)
+}
+
+func (t tableWrapper) TestGet(key []byte) (value []byte, err error) {
+ return t.Reader.Get(key, nil)
+}
+
+func (t tableWrapper) TestNewIterator(slice *util.Range) iterator.Iterator {
+ return t.Reader.NewIterator(slice, nil)
+}
+
+var _ = testutil.Defer(func() {
+ Describe("Table", func() {
+ Describe("approximate offset test", func() {
+ var (
+ buf = &bytes.Buffer{}
+ o = &opt.Options{
+ BlockSize: 1024,
+ Compression: opt.NoCompression,
+ }
+ )
+
+ // Building the table.
+ tw := NewWriter(buf, o)
+ tw.Append([]byte("k01"), []byte("hello"))
+ tw.Append([]byte("k02"), []byte("hello2"))
+ tw.Append([]byte("k03"), bytes.Repeat([]byte{'x'}, 10000))
+ tw.Append([]byte("k04"), bytes.Repeat([]byte{'x'}, 200000))
+ tw.Append([]byte("k05"), bytes.Repeat([]byte{'x'}, 300000))
+ tw.Append([]byte("k06"), []byte("hello3"))
+ tw.Append([]byte("k07"), bytes.Repeat([]byte{'x'}, 100000))
+ err := tw.Close()
+
+ It("Should be able to approximate offset of a key correctly", func() {
+ Expect(err).ShouldNot(HaveOccurred())
+
+ tr := NewReader(bytes.NewReader(buf.Bytes()), int64(buf.Len()), nil, o)
+ CheckOffset := func(key string, expect, threshold int) {
+ offset, err := tr.OffsetOf([]byte(key))
+ Expect(err).ShouldNot(HaveOccurred())
+ Expect(offset).Should(BeNumerically("~", expect, threshold), "Offset of key %q", key)
+ }
+
+ CheckOffset("k0", 0, 0)
+ CheckOffset("k01a", 0, 0)
+ CheckOffset("k02", 0, 0)
+ CheckOffset("k03", 0, 0)
+ CheckOffset("k04", 10000, 1000)
+ CheckOffset("k04a", 210000, 1000)
+ CheckOffset("k05", 210000, 1000)
+ CheckOffset("k06", 510000, 1000)
+ CheckOffset("k07", 510000, 1000)
+ CheckOffset("xyz", 610000, 2000)
+ })
+ })
+
+ Describe("read test", func() {
+ Build := func(kv testutil.KeyValue) testutil.DB {
+ o := &opt.Options{
+ BlockSize: 512,
+ BlockRestartInterval: 3,
+ }
+ buf := &bytes.Buffer{}
+
+ // Building the table.
+ tw := NewWriter(buf, o)
+ kv.Iterate(func(i int, key, value []byte) {
+ tw.Append(key, value)
+ })
+ tw.Close()
+
+ // Opening the table.
+ tr := NewReader(bytes.NewReader(buf.Bytes()), int64(buf.Len()), nil, o)
+ return tableWrapper{tr}
+ }
+ Test := func(kv *testutil.KeyValue, body func(r *Reader)) func() {
+ return func() {
+ db := Build(*kv)
+ if body != nil {
+ body(db.(tableWrapper).Reader)
+ }
+ testutil.KeyValueTesting(nil, db, *kv)
+ }
+ }
+
+ testutil.AllKeyValueTesting(nil, Build)
+ Describe("with one key per block", Test(testutil.KeyValue_Generate(nil, 9, 1, 10, 512, 512), func(r *Reader) {
+ It("should have correct blocks number", func() {
+ Expect(r.indexBlock.restartsLen).Should(Equal(9))
+ })
+ }))
+ })
+ })
+})
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/table/writer.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/table/writer.go
new file mode 100644
index 000000000..4e19e93a9
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/table/writer.go
@@ -0,0 +1,379 @@
+// Copyright (c) 2012, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package table
+
+import (
+ "encoding/binary"
+ "errors"
+ "fmt"
+ "io"
+
+ "code.google.com/p/snappy-go/snappy"
+
+ "github.com/syndtr/goleveldb/leveldb/comparer"
+ "github.com/syndtr/goleveldb/leveldb/filter"
+ "github.com/syndtr/goleveldb/leveldb/opt"
+ "github.com/syndtr/goleveldb/leveldb/util"
+)
+
+func sharedPrefixLen(a, b []byte) int {
+ i, n := 0, len(a)
+ if n > len(b) {
+ n = len(b)
+ }
+ for i < n && a[i] == b[i] {
+ i++
+ }
+ return i
+}
+
+type blockWriter struct {
+ restartInterval int
+ buf util.Buffer
+ nEntries int
+ prevKey []byte
+ restarts []uint32
+ scratch []byte
+}
+
+func (w *blockWriter) append(key, value []byte) {
+ nShared := 0
+ if w.nEntries%w.restartInterval == 0 {
+ w.restarts = append(w.restarts, uint32(w.buf.Len()))
+ } else {
+ nShared = sharedPrefixLen(w.prevKey, key)
+ }
+ n := binary.PutUvarint(w.scratch[0:], uint64(nShared))
+ n += binary.PutUvarint(w.scratch[n:], uint64(len(key)-nShared))
+ n += binary.PutUvarint(w.scratch[n:], uint64(len(value)))
+ w.buf.Write(w.scratch[:n])
+ w.buf.Write(key[nShared:])
+ w.buf.Write(value)
+ w.prevKey = append(w.prevKey[:0], key...)
+ w.nEntries++
+}
+
+func (w *blockWriter) finish() {
+ // Write restarts entry.
+ if w.nEntries == 0 {
+ // Must have at least one restart entry.
+ w.restarts = append(w.restarts, 0)
+ }
+ w.restarts = append(w.restarts, uint32(len(w.restarts)))
+ for _, x := range w.restarts {
+ buf4 := w.buf.Alloc(4)
+ binary.LittleEndian.PutUint32(buf4, x)
+ }
+}
+
+func (w *blockWriter) reset() {
+ w.buf.Reset()
+ w.nEntries = 0
+ w.restarts = w.restarts[:0]
+}
+
+func (w *blockWriter) bytesLen() int {
+ restartsLen := len(w.restarts)
+ if restartsLen == 0 {
+ restartsLen = 1
+ }
+ return w.buf.Len() + 4*restartsLen + 4
+}
+
+type filterWriter struct {
+ generator filter.FilterGenerator
+ buf util.Buffer
+ nKeys int
+ offsets []uint32
+}
+
+func (w *filterWriter) add(key []byte) {
+ if w.generator == nil {
+ return
+ }
+ w.generator.Add(key)
+ w.nKeys++
+}
+
+func (w *filterWriter) flush(offset uint64) {
+ if w.generator == nil {
+ return
+ }
+ for x := int(offset / filterBase); x > len(w.offsets); {
+ w.generate()
+ }
+}
+
+func (w *filterWriter) finish() {
+ if w.generator == nil {
+ return
+ }
+ // Generate last keys.
+
+ if w.nKeys > 0 {
+ w.generate()
+ }
+ w.offsets = append(w.offsets, uint32(w.buf.Len()))
+ for _, x := range w.offsets {
+ buf4 := w.buf.Alloc(4)
+ binary.LittleEndian.PutUint32(buf4, x)
+ }
+ w.buf.WriteByte(filterBaseLg)
+}
+
+func (w *filterWriter) generate() {
+ // Record offset.
+ w.offsets = append(w.offsets, uint32(w.buf.Len()))
+ // Generate filters.
+ if w.nKeys > 0 {
+ w.generator.Generate(&w.buf)
+ w.nKeys = 0
+ }
+}
+
+// Writer is a table writer.
+type Writer struct {
+ writer io.Writer
+ err error
+ // Options
+ cmp comparer.Comparer
+ filter filter.Filter
+ compression opt.Compression
+ blockSize int
+
+ dataBlock blockWriter
+ indexBlock blockWriter
+ filterBlock filterWriter
+ pendingBH blockHandle
+ offset uint64
+ nEntries int
+ // Scratch allocated enough for 5 uvarint. Block writer should not use
+ // first 20-bytes since it will be used to encode block handle, which
+ // then passed to the block writer itself.
+ scratch [50]byte
+ comparerScratch []byte
+ compressionScratch []byte
+}
+
+func (w *Writer) writeBlock(buf *util.Buffer, compression opt.Compression) (bh blockHandle, err error) {
+ // Compress the buffer if necessary.
+ var b []byte
+ if compression == opt.SnappyCompression {
+ // Allocate scratch enough for compression and block trailer.
+ if n := snappy.MaxEncodedLen(buf.Len()) + blockTrailerLen; len(w.compressionScratch) < n {
+ w.compressionScratch = make([]byte, n)
+ }
+ var compressed []byte
+ compressed, err = snappy.Encode(w.compressionScratch, buf.Bytes())
+ if err != nil {
+ return
+ }
+ n := len(compressed)
+ b = compressed[:n+blockTrailerLen]
+ b[n] = blockTypeSnappyCompression
+ } else {
+ tmp := buf.Alloc(blockTrailerLen)
+ tmp[0] = blockTypeNoCompression
+ b = buf.Bytes()
+ }
+
+ // Calculate the checksum.
+ n := len(b) - 4
+ checksum := util.NewCRC(b[:n]).Value()
+ binary.LittleEndian.PutUint32(b[n:], checksum)
+
+ // Write the buffer to the file.
+ _, err = w.writer.Write(b)
+ if err != nil {
+ return
+ }
+ bh = blockHandle{w.offset, uint64(len(b) - blockTrailerLen)}
+ w.offset += uint64(len(b))
+ return
+}
+
+func (w *Writer) flushPendingBH(key []byte) {
+ if w.pendingBH.length == 0 {
+ return
+ }
+ var separator []byte
+ if len(key) == 0 {
+ separator = w.cmp.Successor(w.comparerScratch[:0], w.dataBlock.prevKey)
+ } else {
+ separator = w.cmp.Separator(w.comparerScratch[:0], w.dataBlock.prevKey, key)
+ }
+ if separator == nil {
+ separator = w.dataBlock.prevKey
+ } else {
+ w.comparerScratch = separator
+ }
+ n := encodeBlockHandle(w.scratch[:20], w.pendingBH)
+ // Append the block handle to the index block.
+ w.indexBlock.append(separator, w.scratch[:n])
+ // Reset prev key of the data block.
+ w.dataBlock.prevKey = w.dataBlock.prevKey[:0]
+ // Clear pending block handle.
+ w.pendingBH = blockHandle{}
+}
+
+func (w *Writer) finishBlock() error {
+ w.dataBlock.finish()
+ bh, err := w.writeBlock(&w.dataBlock.buf, w.compression)
+ if err != nil {
+ return err
+ }
+ w.pendingBH = bh
+ // Reset the data block.
+ w.dataBlock.reset()
+ // Flush the filter block.
+ w.filterBlock.flush(w.offset)
+ return nil
+}
+
+// Append appends key/value pair to the table. The keys passed must
+// be in increasing order.
+//
+// It is safe to modify the contents of the arguments after Append returns.
+func (w *Writer) Append(key, value []byte) error {
+ if w.err != nil {
+ return w.err
+ }
+ if w.nEntries > 0 && w.cmp.Compare(w.dataBlock.prevKey, key) >= 0 {
+ w.err = fmt.Errorf("leveldb/table: Writer: keys are not in increasing order: %q, %q", w.dataBlock.prevKey, key)
+ return w.err
+ }
+
+ w.flushPendingBH(key)
+ // Append key/value pair to the data block.
+ w.dataBlock.append(key, value)
+ // Add key to the filter block.
+ w.filterBlock.add(key)
+
+ // Finish the data block if block size target reached.
+ if w.dataBlock.bytesLen() >= w.blockSize {
+ if err := w.finishBlock(); err != nil {
+ w.err = err
+ return w.err
+ }
+ }
+ w.nEntries++
+ return nil
+}
+
+// BlocksLen returns number of blocks written so far.
+func (w *Writer) BlocksLen() int {
+ n := w.indexBlock.nEntries
+ if w.pendingBH.length > 0 {
+ // Includes the pending block.
+ n++
+ }
+ return n
+}
+
+// EntriesLen returns number of entries added so far.
+func (w *Writer) EntriesLen() int {
+ return w.nEntries
+}
+
+// BytesLen returns number of bytes written so far.
+func (w *Writer) BytesLen() int {
+ return int(w.offset)
+}
+
+// Close will finalize the table. Calling Append is not possible
+// after Close, but calling BlocksLen, EntriesLen and BytesLen
+// is still possible.
+func (w *Writer) Close() error {
+ if w.err != nil {
+ return w.err
+ }
+
+ // Write the last data block. Or empty data block if there
+ // aren't any data blocks at all.
+ if w.dataBlock.nEntries > 0 || w.nEntries == 0 {
+ if err := w.finishBlock(); err != nil {
+ w.err = err
+ return w.err
+ }
+ }
+ w.flushPendingBH(nil)
+
+ // Write the filter block.
+ var filterBH blockHandle
+ w.filterBlock.finish()
+ if buf := &w.filterBlock.buf; buf.Len() > 0 {
+ filterBH, w.err = w.writeBlock(buf, opt.NoCompression)
+ if w.err != nil {
+ return w.err
+ }
+ }
+
+ // Write the metaindex block.
+ if filterBH.length > 0 {
+ key := []byte("filter." + w.filter.Name())
+ n := encodeBlockHandle(w.scratch[:20], filterBH)
+ w.dataBlock.append(key, w.scratch[:n])
+ }
+ w.dataBlock.finish()
+ metaindexBH, err := w.writeBlock(&w.dataBlock.buf, w.compression)
+ if err != nil {
+ w.err = err
+ return w.err
+ }
+
+ // Write the index block.
+ w.indexBlock.finish()
+ indexBH, err := w.writeBlock(&w.indexBlock.buf, w.compression)
+ if err != nil {
+ w.err = err
+ return w.err
+ }
+
+ // Write the table footer.
+ footer := w.scratch[:footerLen]
+ for i := range footer {
+ footer[i] = 0
+ }
+ n := encodeBlockHandle(footer, metaindexBH)
+ encodeBlockHandle(footer[n:], indexBH)
+ copy(footer[footerLen-len(magic):], magic)
+ if _, err := w.writer.Write(footer); err != nil {
+ w.err = err
+ return w.err
+ }
+ w.offset += footerLen
+
+ w.err = errors.New("leveldb/table: writer is closed")
+ return nil
+}
+
+// NewWriter creates a new initialized table writer for the file.
+//
+// Table writer is not goroutine-safe.
+func NewWriter(f io.Writer, o *opt.Options) *Writer {
+ w := &Writer{
+ writer: f,
+ cmp: o.GetComparer(),
+ filter: o.GetFilter(),
+ compression: o.GetCompression(),
+ blockSize: o.GetBlockSize(),
+ comparerScratch: make([]byte, 0),
+ }
+ // data block
+ w.dataBlock.restartInterval = o.GetBlockRestartInterval()
+ // The first 20-bytes are used for encoding block handle.
+ w.dataBlock.scratch = w.scratch[20:]
+ // index block
+ w.indexBlock.restartInterval = 1
+ w.indexBlock.scratch = w.scratch[20:]
+ // filter block
+ if w.filter != nil {
+ w.filterBlock.generator = w.filter.NewGenerator()
+ w.filterBlock.flush(0)
+ }
+ return w
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/testutil/db.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/testutil/db.go
new file mode 100644
index 000000000..4b87b5ef6
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/testutil/db.go
@@ -0,0 +1,216 @@
+// Copyright (c) 2014, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package testutil
+
+import (
+ "fmt"
+ "math/rand"
+
+ . "github.com/onsi/gomega"
+
+ "github.com/syndtr/goleveldb/leveldb/iterator"
+ "github.com/syndtr/goleveldb/leveldb/util"
+)
+
+type DB interface{}
+
+type Put interface {
+ TestPut(key []byte, value []byte) error
+}
+
+type Delete interface {
+ TestDelete(key []byte) error
+}
+
+type Find interface {
+ TestFind(key []byte) (rkey, rvalue []byte, err error)
+}
+
+type Get interface {
+ TestGet(key []byte) (value []byte, err error)
+}
+
+type NewIterator interface {
+ TestNewIterator(slice *util.Range) iterator.Iterator
+}
+
+type DBAct int
+
+func (a DBAct) String() string {
+ switch a {
+ case DBNone:
+ return "none"
+ case DBPut:
+ return "put"
+ case DBOverwrite:
+ return "overwrite"
+ case DBDelete:
+ return "delete"
+ case DBDeleteNA:
+ return "delete_na"
+ }
+ return "unknown"
+}
+
+const (
+ DBNone DBAct = iota
+ DBPut
+ DBOverwrite
+ DBDelete
+ DBDeleteNA
+)
+
+type DBTesting struct {
+ Rand *rand.Rand
+ DB interface {
+ Get
+ Put
+ Delete
+ }
+ PostFn func(t *DBTesting)
+ Deleted, Present KeyValue
+ Act, LastAct DBAct
+ ActKey, LastActKey []byte
+}
+
+func (t *DBTesting) post() {
+ if t.PostFn != nil {
+ t.PostFn(t)
+ }
+}
+
+func (t *DBTesting) setAct(act DBAct, key []byte) {
+ t.LastAct, t.Act = t.Act, act
+ t.LastActKey, t.ActKey = t.ActKey, key
+}
+
+func (t *DBTesting) text() string {
+ return fmt.Sprintf("last action was <%v> %q, <%v> %q", t.LastAct, t.LastActKey, t.Act, t.ActKey)
+}
+
+func (t *DBTesting) Text() string {
+ return "DBTesting " + t.text()
+}
+
+func (t *DBTesting) TestPresentKV(key, value []byte) {
+ rvalue, err := t.DB.TestGet(key)
+ Expect(err).ShouldNot(HaveOccurred(), "Get on key %q, %s", key, t.text())
+ Expect(rvalue).Should(Equal(value), "Value for key %q, %s", key, t.text())
+}
+
+func (t *DBTesting) TestAllPresent() {
+ t.Present.IterateShuffled(t.Rand, func(i int, key, value []byte) {
+ t.TestPresentKV(key, value)
+ })
+}
+
+func (t *DBTesting) TestDeletedKey(key []byte) {
+ _, err := t.DB.TestGet(key)
+ Expect(err).Should(Equal(util.ErrNotFound), "Get on deleted key %q, %s", key, t.text())
+}
+
+func (t *DBTesting) TestAllDeleted() {
+ t.Deleted.IterateShuffled(t.Rand, func(i int, key, value []byte) {
+ t.TestDeletedKey(key)
+ })
+}
+
+func (t *DBTesting) TestAll() {
+ dn := t.Deleted.Len()
+ pn := t.Present.Len()
+ ShuffledIndex(t.Rand, dn+pn, 1, func(i int) {
+ if i >= dn {
+ key, value := t.Present.Index(i - dn)
+ t.TestPresentKV(key, value)
+ } else {
+ t.TestDeletedKey(t.Deleted.KeyAt(i))
+ }
+ })
+}
+
+func (t *DBTesting) Put(key, value []byte) {
+ if new := t.Present.PutU(key, value); new {
+ t.setAct(DBPut, key)
+ } else {
+ t.setAct(DBOverwrite, key)
+ }
+ t.Deleted.Delete(key)
+ err := t.DB.TestPut(key, value)
+ Expect(err).ShouldNot(HaveOccurred(), t.Text())
+ t.TestPresentKV(key, value)
+ t.post()
+}
+
+func (t *DBTesting) PutRandom() bool {
+ if t.Deleted.Len() > 0 {
+ i := t.Rand.Intn(t.Deleted.Len())
+ key, value := t.Deleted.Index(i)
+ t.Put(key, value)
+ return true
+ }
+ return false
+}
+
+func (t *DBTesting) Delete(key []byte) {
+ if exist, value := t.Present.Delete(key); exist {
+ t.setAct(DBDelete, key)
+ t.Deleted.PutU(key, value)
+ } else {
+ t.setAct(DBDeleteNA, key)
+ }
+ err := t.DB.TestDelete(key)
+ Expect(err).ShouldNot(HaveOccurred(), t.Text())
+ t.TestDeletedKey(key)
+ t.post()
+}
+
+func (t *DBTesting) DeleteRandom() bool {
+ if t.Present.Len() > 0 {
+ i := t.Rand.Intn(t.Present.Len())
+ t.Delete(t.Present.KeyAt(i))
+ return true
+ }
+ return false
+}
+
+func (t *DBTesting) RandomAct(round int) {
+ for i := 0; i < round; i++ {
+ if t.Rand.Int()%2 == 0 {
+ t.PutRandom()
+ } else {
+ t.DeleteRandom()
+ }
+ }
+}
+
+func DoDBTesting(t *DBTesting) {
+ if t.Rand == nil {
+ t.Rand = NewRand()
+ }
+
+ t.DeleteRandom()
+ t.PutRandom()
+ t.DeleteRandom()
+ t.DeleteRandom()
+ for i := t.Deleted.Len() / 2; i >= 0; i-- {
+ t.PutRandom()
+ }
+ t.RandomAct((t.Deleted.Len() + t.Present.Len()) * 10)
+
+ // Additional iterator testing
+ if db, ok := t.DB.(NewIterator); ok {
+ iter := db.TestNewIterator(nil)
+ Expect(iter.Error()).NotTo(HaveOccurred())
+
+ it := IteratorTesting{
+ KeyValue: t.Present,
+ Iter: iter,
+ }
+
+ DoIteratorTesting(&it)
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/testutil/iter.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/testutil/iter.go
new file mode 100644
index 000000000..df6d9db6a
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/testutil/iter.go
@@ -0,0 +1,327 @@
+// Copyright (c) 2014, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package testutil
+
+import (
+ "fmt"
+ "math/rand"
+
+ . "github.com/onsi/gomega"
+
+ "github.com/syndtr/goleveldb/leveldb/iterator"
+)
+
+type IterAct int
+
+func (a IterAct) String() string {
+ switch a {
+ case IterNone:
+ return "none"
+ case IterFirst:
+ return "first"
+ case IterLast:
+ return "last"
+ case IterPrev:
+ return "prev"
+ case IterNext:
+ return "next"
+ case IterSeek:
+ return "seek"
+ case IterSOI:
+ return "soi"
+ case IterEOI:
+ return "eoi"
+ }
+ return "unknown"
+}
+
+const (
+ IterNone IterAct = iota
+ IterFirst
+ IterLast
+ IterPrev
+ IterNext
+ IterSeek
+ IterSOI
+ IterEOI
+)
+
+type IteratorTesting struct {
+ KeyValue
+ Iter iterator.Iterator
+ Rand *rand.Rand
+ PostFn func(t *IteratorTesting)
+ Pos int
+ Act, LastAct IterAct
+
+ once bool
+}
+
+func (t *IteratorTesting) init() {
+ if !t.once {
+ t.Pos = -1
+ t.once = true
+ }
+}
+
+func (t *IteratorTesting) post() {
+ if t.PostFn != nil {
+ t.PostFn(t)
+ }
+}
+
+func (t *IteratorTesting) setAct(act IterAct) {
+ t.LastAct, t.Act = t.Act, act
+}
+
+func (t *IteratorTesting) text() string {
+ return fmt.Sprintf("at pos %d and last action was <%v> -> <%v>", t.Pos, t.LastAct, t.Act)
+}
+
+func (t *IteratorTesting) Text() string {
+ return "IteratorTesting is " + t.text()
+}
+
+func (t *IteratorTesting) IsFirst() bool {
+ t.init()
+ return t.Len() > 0 && t.Pos == 0
+}
+
+func (t *IteratorTesting) IsLast() bool {
+ t.init()
+ return t.Len() > 0 && t.Pos == t.Len()-1
+}
+
+func (t *IteratorTesting) TestKV() {
+ t.init()
+ key, value := t.Index(t.Pos)
+ Expect(t.Iter.Key()).NotTo(BeNil())
+ Expect(t.Iter.Key()).Should(Equal(key), "Key is invalid, %s", t.text())
+ Expect(t.Iter.Value()).Should(Equal(value), "Value for key %q, %s", key, t.text())
+}
+
+func (t *IteratorTesting) First() {
+ t.init()
+ t.setAct(IterFirst)
+
+ ok := t.Iter.First()
+ Expect(t.Iter.Error()).ShouldNot(HaveOccurred())
+ if t.Len() > 0 {
+ t.Pos = 0
+ Expect(ok).Should(BeTrue(), t.Text())
+ t.TestKV()
+ } else {
+ t.Pos = -1
+ Expect(ok).ShouldNot(BeTrue(), t.Text())
+ }
+ t.post()
+}
+
+func (t *IteratorTesting) Last() {
+ t.init()
+ t.setAct(IterLast)
+
+ ok := t.Iter.Last()
+ Expect(t.Iter.Error()).ShouldNot(HaveOccurred())
+ if t.Len() > 0 {
+ t.Pos = t.Len() - 1
+ Expect(ok).Should(BeTrue(), t.Text())
+ t.TestKV()
+ } else {
+ t.Pos = 0
+ Expect(ok).ShouldNot(BeTrue(), t.Text())
+ }
+ t.post()
+}
+
+func (t *IteratorTesting) Next() {
+ t.init()
+ t.setAct(IterNext)
+
+ ok := t.Iter.Next()
+ Expect(t.Iter.Error()).ShouldNot(HaveOccurred())
+ if t.Pos < t.Len()-1 {
+ t.Pos++
+ Expect(ok).Should(BeTrue(), t.Text())
+ t.TestKV()
+ } else {
+ t.Pos = t.Len()
+ Expect(ok).ShouldNot(BeTrue(), t.Text())
+ }
+ t.post()
+}
+
+func (t *IteratorTesting) Prev() {
+ t.init()
+ t.setAct(IterPrev)
+
+ ok := t.Iter.Prev()
+ Expect(t.Iter.Error()).ShouldNot(HaveOccurred())
+ if t.Pos > 0 {
+ t.Pos--
+ Expect(ok).Should(BeTrue(), t.Text())
+ t.TestKV()
+ } else {
+ t.Pos = -1
+ Expect(ok).ShouldNot(BeTrue(), t.Text())
+ }
+ t.post()
+}
+
+func (t *IteratorTesting) Seek(i int) {
+ t.init()
+ t.setAct(IterSeek)
+
+ key, _ := t.Index(i)
+ oldKey, _ := t.IndexOrNil(t.Pos)
+
+ ok := t.Iter.Seek(key)
+ Expect(t.Iter.Error()).ShouldNot(HaveOccurred())
+ Expect(ok).Should(BeTrue(), fmt.Sprintf("Seek from key %q to %q, to pos %d, %s", oldKey, key, i, t.text()))
+
+ t.Pos = i
+ t.TestKV()
+ t.post()
+}
+
+func (t *IteratorTesting) SeekInexact(i int) {
+ t.init()
+ t.setAct(IterSeek)
+ var key0 []byte
+ key1, _ := t.Index(i)
+ if i > 0 {
+ key0, _ = t.Index(i - 1)
+ }
+ key := BytesSeparator(key0, key1)
+ oldKey, _ := t.IndexOrNil(t.Pos)
+
+ ok := t.Iter.Seek(key)
+ Expect(t.Iter.Error()).ShouldNot(HaveOccurred())
+ Expect(ok).Should(BeTrue(), fmt.Sprintf("Seek from key %q to %q (%q), to pos %d, %s", oldKey, key, key1, i, t.text()))
+
+ t.Pos = i
+ t.TestKV()
+ t.post()
+}
+
+func (t *IteratorTesting) SeekKey(key []byte) {
+ t.init()
+ t.setAct(IterSeek)
+ oldKey, _ := t.IndexOrNil(t.Pos)
+ i := t.Search(key)
+
+ ok := t.Iter.Seek(key)
+ Expect(t.Iter.Error()).ShouldNot(HaveOccurred())
+ if i < t.Len() {
+ key_, _ := t.Index(i)
+ Expect(ok).Should(BeTrue(), fmt.Sprintf("Seek from key %q to %q (%q), to pos %d, %s", oldKey, key, key_, i, t.text()))
+ t.Pos = i
+ t.TestKV()
+ } else {
+ Expect(ok).ShouldNot(BeTrue(), fmt.Sprintf("Seek from key %q to %q, %s", oldKey, key, t.text()))
+ }
+
+ t.Pos = i
+ t.post()
+}
+
+func (t *IteratorTesting) SOI() {
+ t.init()
+ t.setAct(IterSOI)
+ Expect(t.Pos).Should(BeNumerically("<=", 0), t.Text())
+ for i := 0; i < 3; i++ {
+ t.Prev()
+ }
+ t.post()
+}
+
+func (t *IteratorTesting) EOI() {
+ t.init()
+ t.setAct(IterEOI)
+ Expect(t.Pos).Should(BeNumerically(">=", t.Len()-1), t.Text())
+ for i := 0; i < 3; i++ {
+ t.Next()
+ }
+ t.post()
+}
+
+func (t *IteratorTesting) WalkPrev(fn func(t *IteratorTesting)) {
+ t.init()
+ for old := t.Pos; t.Pos > 0; old = t.Pos {
+ fn(t)
+ Expect(t.Pos).Should(BeNumerically("<", old), t.Text())
+ }
+}
+
+func (t *IteratorTesting) WalkNext(fn func(t *IteratorTesting)) {
+ t.init()
+ for old := t.Pos; t.Pos < t.Len()-1; old = t.Pos {
+ fn(t)
+ Expect(t.Pos).Should(BeNumerically(">", old), t.Text())
+ }
+}
+
+func (t *IteratorTesting) PrevAll() {
+ t.WalkPrev(func(t *IteratorTesting) {
+ t.Prev()
+ })
+}
+
+func (t *IteratorTesting) NextAll() {
+ t.WalkNext(func(t *IteratorTesting) {
+ t.Next()
+ })
+}
+
+func DoIteratorTesting(t *IteratorTesting) {
+ if t.Rand == nil {
+ t.Rand = NewRand()
+ }
+ t.SOI()
+ t.NextAll()
+ t.First()
+ t.SOI()
+ t.NextAll()
+ t.EOI()
+ t.PrevAll()
+ t.Last()
+ t.EOI()
+ t.PrevAll()
+ t.SOI()
+
+ t.NextAll()
+ t.PrevAll()
+ t.NextAll()
+ t.Last()
+ t.PrevAll()
+ t.First()
+ t.NextAll()
+ t.EOI()
+
+ ShuffledIndex(t.Rand, t.Len(), 1, func(i int) {
+ t.Seek(i)
+ })
+
+ ShuffledIndex(t.Rand, t.Len(), 1, func(i int) {
+ t.SeekInexact(i)
+ })
+
+ ShuffledIndex(t.Rand, t.Len(), 1, func(i int) {
+ t.Seek(i)
+ if i%2 != 0 {
+ t.PrevAll()
+ t.SOI()
+ } else {
+ t.NextAll()
+ t.EOI()
+ }
+ })
+
+ for _, key := range []string{"", "foo", "bar", "\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff"} {
+ t.SeekKey([]byte(key))
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/testutil/kv.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/testutil/kv.go
new file mode 100644
index 000000000..471d5708c
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/testutil/kv.go
@@ -0,0 +1,352 @@
+// Copyright (c) 2014, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package testutil
+
+import (
+ "fmt"
+ "math/rand"
+ "sort"
+ "strings"
+
+ "github.com/syndtr/goleveldb/leveldb/util"
+)
+
+type KeyValueEntry struct {
+ key, value []byte
+}
+
+type KeyValue struct {
+ entries []KeyValueEntry
+ nbytes int
+}
+
+func (kv *KeyValue) Put(key, value []byte) {
+ if n := len(kv.entries); n > 0 && cmp.Compare(kv.entries[n-1].key, key) >= 0 {
+ panic(fmt.Sprintf("Put: keys are not in increasing order: %q, %q", kv.entries[n-1].key, key))
+ }
+ kv.entries = append(kv.entries, KeyValueEntry{key, value})
+ kv.nbytes += len(key) + len(value)
+}
+
+func (kv *KeyValue) PutString(key, value string) {
+ kv.Put([]byte(key), []byte(value))
+}
+
+func (kv *KeyValue) PutU(key, value []byte) bool {
+ if i, exist := kv.Get(key); !exist {
+ if i < kv.Len() {
+ kv.entries = append(kv.entries[:i+1], kv.entries[i:]...)
+ kv.entries[i] = KeyValueEntry{key, value}
+ } else {
+ kv.entries = append(kv.entries, KeyValueEntry{key, value})
+ }
+ kv.nbytes += len(key) + len(value)
+ return true
+ } else {
+ kv.nbytes += len(value) - len(kv.ValueAt(i))
+ kv.entries[i].value = value
+ }
+ return false
+}
+
+func (kv *KeyValue) PutUString(key, value string) bool {
+ return kv.PutU([]byte(key), []byte(value))
+}
+
+func (kv *KeyValue) Delete(key []byte) (exist bool, value []byte) {
+ i, exist := kv.Get(key)
+ if exist {
+ value = kv.entries[i].value
+ kv.DeleteIndex(i)
+ }
+ return
+}
+
+func (kv *KeyValue) DeleteIndex(i int) bool {
+ if i < kv.Len() {
+ kv.nbytes -= len(kv.KeyAt(i)) + len(kv.ValueAt(i))
+ kv.entries = append(kv.entries[:i], kv.entries[i+1:]...)
+ return true
+ }
+ return false
+}
+
+func (kv KeyValue) Len() int {
+ return len(kv.entries)
+}
+
+func (kv *KeyValue) Size() int {
+ return kv.nbytes
+}
+
+func (kv KeyValue) KeyAt(i int) []byte {
+ return kv.entries[i].key
+}
+
+func (kv KeyValue) ValueAt(i int) []byte {
+ return kv.entries[i].value
+}
+
+func (kv KeyValue) Index(i int) (key, value []byte) {
+ if i < 0 || i >= len(kv.entries) {
+ panic(fmt.Sprintf("Index #%d: out of range", i))
+ }
+ return kv.entries[i].key, kv.entries[i].value
+}
+
+func (kv KeyValue) IndexInexact(i int) (key_, key, value []byte) {
+ key, value = kv.Index(i)
+ var key0 []byte
+ var key1 = kv.KeyAt(i)
+ if i > 0 {
+ key0 = kv.KeyAt(i - 1)
+ }
+ key_ = BytesSeparator(key0, key1)
+ return
+}
+
+func (kv KeyValue) IndexOrNil(i int) (key, value []byte) {
+ if i >= 0 && i < len(kv.entries) {
+ return kv.entries[i].key, kv.entries[i].value
+ }
+ return nil, nil
+}
+
+func (kv KeyValue) IndexString(i int) (key, value string) {
+ key_, _value := kv.Index(i)
+ return string(key_), string(_value)
+}
+
+func (kv KeyValue) Search(key []byte) int {
+ return sort.Search(kv.Len(), func(i int) bool {
+ return cmp.Compare(kv.KeyAt(i), key) >= 0
+ })
+}
+
+func (kv KeyValue) SearchString(key string) int {
+ return kv.Search([]byte(key))
+}
+
+func (kv KeyValue) Get(key []byte) (i int, exist bool) {
+ i = kv.Search(key)
+ if i < kv.Len() && cmp.Compare(kv.KeyAt(i), key) == 0 {
+ exist = true
+ }
+ return
+}
+
+func (kv KeyValue) GetString(key string) (i int, exist bool) {
+ return kv.Get([]byte(key))
+}
+
+func (kv KeyValue) Iterate(fn func(i int, key, value []byte)) {
+ for i, x := range kv.entries {
+ fn(i, x.key, x.value)
+ }
+}
+
+func (kv KeyValue) IterateString(fn func(i int, key, value string)) {
+ kv.Iterate(func(i int, key, value []byte) {
+ fn(i, string(key), string(value))
+ })
+}
+
+func (kv KeyValue) IterateShuffled(rnd *rand.Rand, fn func(i int, key, value []byte)) {
+ ShuffledIndex(rnd, kv.Len(), 1, func(i int) {
+ fn(i, kv.entries[i].key, kv.entries[i].value)
+ })
+}
+
+func (kv KeyValue) IterateShuffledString(rnd *rand.Rand, fn func(i int, key, value string)) {
+ kv.IterateShuffled(rnd, func(i int, key, value []byte) {
+ fn(i, string(key), string(value))
+ })
+}
+
+func (kv KeyValue) IterateInexact(fn func(i int, key_, key, value []byte)) {
+ for i := range kv.entries {
+ key_, key, value := kv.IndexInexact(i)
+ fn(i, key_, key, value)
+ }
+}
+
+func (kv KeyValue) IterateInexactString(fn func(i int, key_, key, value string)) {
+ kv.IterateInexact(func(i int, key_, key, value []byte) {
+ fn(i, string(key_), string(key), string(value))
+ })
+}
+
+func (kv KeyValue) Clone() KeyValue {
+ return KeyValue{append([]KeyValueEntry{}, kv.entries...), kv.nbytes}
+}
+
+func (kv KeyValue) Slice(start, limit int) KeyValue {
+ if start < 0 || limit > kv.Len() {
+ panic(fmt.Sprintf("Slice %d .. %d: out of range", start, limit))
+ } else if limit < start {
+ panic(fmt.Sprintf("Slice %d .. %d: invalid range", start, limit))
+ }
+ return KeyValue{append([]KeyValueEntry{}, kv.entries[start:limit]...), kv.nbytes}
+}
+
+func (kv KeyValue) SliceKey(start, limit []byte) KeyValue {
+ start_ := 0
+ limit_ := kv.Len()
+ if start != nil {
+ start_ = kv.Search(start)
+ }
+ if limit != nil {
+ limit_ = kv.Search(limit)
+ }
+ return kv.Slice(start_, limit_)
+}
+
+func (kv KeyValue) SliceKeyString(start, limit string) KeyValue {
+ return kv.SliceKey([]byte(start), []byte(limit))
+}
+
+func (kv KeyValue) SliceRange(r *util.Range) KeyValue {
+ if r != nil {
+ return kv.SliceKey(r.Start, r.Limit)
+ }
+ return kv.Clone()
+}
+
+func (kv KeyValue) Range(start, limit int) (r util.Range) {
+ if kv.Len() > 0 {
+ if start == kv.Len() {
+ r.Start = BytesAfter(kv.KeyAt(start - 1))
+ } else {
+ r.Start = kv.KeyAt(start)
+ }
+ }
+ if limit < kv.Len() {
+ r.Limit = kv.KeyAt(limit)
+ }
+ return
+}
+
+func KeyValue_EmptyKey() *KeyValue {
+ kv := &KeyValue{}
+ kv.PutString("", "v")
+ return kv
+}
+
+func KeyValue_EmptyValue() *KeyValue {
+ kv := &KeyValue{}
+ kv.PutString("abc", "")
+ kv.PutString("abcd", "")
+ return kv
+}
+
+func KeyValue_OneKeyValue() *KeyValue {
+ kv := &KeyValue{}
+ kv.PutString("abc", "v")
+ return kv
+}
+
+func KeyValue_BigValue() *KeyValue {
+ kv := &KeyValue{}
+ kv.PutString("big1", strings.Repeat("1", 200000))
+ return kv
+}
+
+func KeyValue_SpecialKey() *KeyValue {
+ kv := &KeyValue{}
+ kv.PutString("\xff\xff", "v3")
+ return kv
+}
+
+func KeyValue_MultipleKeyValue() *KeyValue {
+ kv := &KeyValue{}
+ kv.PutString("a", "v")
+ kv.PutString("aa", "v1")
+ kv.PutString("aaa", "v2")
+ kv.PutString("aaacccccccccc", "v2")
+ kv.PutString("aaaccccccccccd", "v3")
+ kv.PutString("aaaccccccccccf", "v4")
+ kv.PutString("aaaccccccccccfg", "v5")
+ kv.PutString("ab", "v6")
+ kv.PutString("abc", "v7")
+ kv.PutString("abcd", "v8")
+ kv.PutString("accccccccccccccc", "v9")
+ kv.PutString("b", "v10")
+ kv.PutString("bb", "v11")
+ kv.PutString("bc", "v12")
+ kv.PutString("c", "v13")
+ kv.PutString("c1", "v13")
+ kv.PutString("czzzzzzzzzzzzzz", "v14")
+ kv.PutString("fffffffffffffff", "v15")
+ kv.PutString("g11", "v15")
+ kv.PutString("g111", "v15")
+ kv.PutString("g111\xff", "v15")
+ kv.PutString("zz", "v16")
+ kv.PutString("zzzzzzz", "v16")
+ kv.PutString("zzzzzzzzzzzzzzzz", "v16")
+ return kv
+}
+
+var keymap = []byte("012345678ABCDEFGHIJKLMNOPQRSTUVWXYabcdefghijklmnopqrstuvwxy")
+
+func KeyValue_Generate(rnd *rand.Rand, n, minlen, maxlen, vminlen, vmaxlen int) *KeyValue {
+ if rnd == nil {
+ rnd = NewRand()
+ }
+ if maxlen < minlen {
+ panic("max len should >= min len")
+ }
+
+ rrand := func(min, max int) int {
+ if min == max {
+ return max
+ }
+ return rnd.Intn(max-min) + min
+ }
+
+ kv := &KeyValue{}
+ endC := byte(len(keymap) - 1)
+ gen := make([]byte, 0, maxlen)
+ for i := 0; i < n; i++ {
+ m := rrand(minlen, maxlen)
+ last := gen
+ retry:
+ gen = last[:m]
+ if k := len(last); m > k {
+ for j := k; j < m; j++ {
+ gen[j] = 0
+ }
+ } else {
+ for j := m - 1; j >= 0; j-- {
+ c := last[j]
+ if c == endC {
+ continue
+ }
+ gen[j] = c + 1
+ for j += 1; j < m; j++ {
+ gen[j] = 0
+ }
+ goto ok
+ }
+ if m < maxlen {
+ m++
+ goto retry
+ }
+ panic(fmt.Sprintf("only able to generate %d keys out of %d keys, try increasing max len", kv.Len(), n))
+ ok:
+ }
+ key := make([]byte, m)
+ for j := 0; j < m; j++ {
+ key[j] = keymap[gen[j]]
+ }
+ value := make([]byte, rrand(vminlen, vmaxlen))
+ for n := copy(value, []byte(fmt.Sprintf("v%d", i))); n < len(value); n++ {
+ value[n] = 'x'
+ }
+ kv.Put(key, value)
+ }
+ return kv
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/testutil/kvtest.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/testutil/kvtest.go
new file mode 100644
index 000000000..4fc75b6f2
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/testutil/kvtest.go
@@ -0,0 +1,136 @@
+// Copyright (c) 2014, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package testutil
+
+import (
+ "fmt"
+ "math/rand"
+
+ . "github.com/onsi/ginkgo"
+ . "github.com/onsi/gomega"
+
+ "github.com/syndtr/goleveldb/leveldb/util"
+)
+
+func KeyValueTesting(rnd *rand.Rand, p DB, kv KeyValue) {
+ if rnd == nil {
+ rnd = NewRand()
+ }
+
+ if db, ok := p.(Find); ok {
+ It("Should find all keys with Find", func() {
+ ShuffledIndex(nil, kv.Len(), 1, func(i int) {
+ key_, key, value := kv.IndexInexact(i)
+
+ // Using exact key.
+ rkey, rvalue, err := db.TestFind(key)
+ Expect(err).ShouldNot(HaveOccurred(), "Error for key %q", key)
+ Expect(rkey).Should(Equal(key), "Key")
+ Expect(rvalue).Should(Equal(value), "Value for key %q", key)
+
+ // Using inexact key.
+ rkey, rvalue, err = db.TestFind(key_)
+ Expect(err).ShouldNot(HaveOccurred(), "Error for key %q (%q)", key_, key)
+ Expect(rkey).Should(Equal(key))
+ Expect(rvalue).Should(Equal(value), "Value for key %q (%q)", key_, key)
+ })
+ })
+
+ It("Should return error if the key is not present", func() {
+ var key []byte
+ if kv.Len() > 0 {
+ key_, _ := kv.Index(kv.Len() - 1)
+ key = BytesAfter(key_)
+ }
+ rkey, _, err := db.TestFind(key)
+ Expect(err).Should(HaveOccurred(), "Find for key %q yield key %q", key, rkey)
+ Expect(err).Should(Equal(util.ErrNotFound))
+ })
+ }
+
+ if db, ok := p.(Get); ok {
+ It("Should only find exact key with Get", func() {
+ ShuffledIndex(nil, kv.Len(), 1, func(i int) {
+ key_, key, value := kv.IndexInexact(i)
+
+ // Using exact key.
+ rvalue, err := db.TestGet(key)
+ Expect(err).ShouldNot(HaveOccurred(), "Error for key %q", key)
+ Expect(rvalue).Should(Equal(value), "Value for key %q", key)
+
+ // Using inexact key.
+ if len(key_) > 0 {
+ _, err = db.TestGet(key_)
+ Expect(err).Should(HaveOccurred(), "Error for key %q", key_)
+ Expect(err).Should(Equal(util.ErrNotFound))
+ }
+ })
+ })
+ }
+
+ if db, ok := p.(NewIterator); ok {
+ TestIter := func(r *util.Range, _kv KeyValue) {
+ iter := db.TestNewIterator(r)
+ Expect(iter.Error()).ShouldNot(HaveOccurred())
+
+ t := IteratorTesting{
+ KeyValue: _kv,
+ Iter: iter,
+ }
+
+ DoIteratorTesting(&t)
+ }
+
+ It("Should iterates and seeks correctly", func(done Done) {
+ TestIter(nil, kv.Clone())
+ done <- true
+ }, 3.0)
+
+ RandomIndex(rnd, kv.Len(), kv.Len(), func(i int) {
+ type slice struct {
+ r *util.Range
+ start, limit int
+ }
+
+ key_, _, _ := kv.IndexInexact(i)
+ for _, x := range []slice{
+ {&util.Range{Start: key_, Limit: nil}, i, kv.Len()},
+ {&util.Range{Start: nil, Limit: key_}, 0, i},
+ } {
+ It(fmt.Sprintf("Should iterates and seeks correctly of a slice %d .. %d", x.start, x.limit), func(done Done) {
+ TestIter(x.r, kv.Slice(x.start, x.limit))
+ done <- true
+ }, 3.0)
+ }
+ })
+
+ RandomRange(rnd, kv.Len(), kv.Len(), func(start, limit int) {
+ It(fmt.Sprintf("Should iterates and seeks correctly of a slice %d .. %d", start, limit), func(done Done) {
+ r := kv.Range(start, limit)
+ TestIter(&r, kv.Slice(start, limit))
+ done <- true
+ }, 3.0)
+ })
+ }
+}
+
+func AllKeyValueTesting(rnd *rand.Rand, body func(kv KeyValue) DB) {
+ Test := func(kv *KeyValue) func() {
+ return func() {
+ db := body(*kv)
+ KeyValueTesting(rnd, db, *kv)
+ }
+ }
+
+ Describe("with no key/value (empty)", Test(&KeyValue{}))
+ Describe("with empty key", Test(KeyValue_EmptyKey()))
+ Describe("with empty value", Test(KeyValue_EmptyValue()))
+ Describe("with one key/value", Test(KeyValue_OneKeyValue()))
+ Describe("with big value", Test(KeyValue_BigValue()))
+ Describe("with special key", Test(KeyValue_SpecialKey()))
+ Describe("with multiple key/value", Test(KeyValue_MultipleKeyValue()))
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/testutil/storage.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/testutil/storage.go
new file mode 100644
index 000000000..0f8d77a73
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/testutil/storage.go
@@ -0,0 +1,585 @@
+// Copyright (c) 2014, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package testutil
+
+import (
+ "bytes"
+ "fmt"
+ "io"
+ "os"
+ "path/filepath"
+ "runtime"
+ "strings"
+ "sync"
+
+ . "github.com/onsi/gomega"
+
+ "github.com/syndtr/goleveldb/leveldb/storage"
+ "github.com/syndtr/goleveldb/leveldb/util"
+)
+
+var (
+ storageMu sync.Mutex
+ storageUseFS bool = true
+ storageKeepFS bool = false
+ storageNum int
+)
+
+type StorageMode int
+
+const (
+ ModeOpen StorageMode = 1 << iota
+ ModeCreate
+ ModeRemove
+ ModeRead
+ ModeWrite
+ ModeSync
+ ModeClose
+)
+
+const (
+ modeOpen = iota
+ modeCreate
+ modeRemove
+ modeRead
+ modeWrite
+ modeSync
+ modeClose
+
+ modeCount
+)
+
+const (
+ typeManifest = iota
+ typeJournal
+ typeTable
+ typeTemp
+
+ typeCount
+)
+
+const flattenCount = modeCount * typeCount
+
+func flattenType(m StorageMode, t storage.FileType) int {
+ var x int
+ switch m {
+ case ModeOpen:
+ x = modeOpen
+ case ModeCreate:
+ x = modeCreate
+ case ModeRemove:
+ x = modeRemove
+ case ModeRead:
+ x = modeRead
+ case ModeWrite:
+ x = modeWrite
+ case ModeSync:
+ x = modeSync
+ case ModeClose:
+ x = modeClose
+ default:
+ panic("invalid storage mode")
+ }
+ x *= typeCount
+ switch t {
+ case storage.TypeManifest:
+ return x + typeManifest
+ case storage.TypeJournal:
+ return x + typeJournal
+ case storage.TypeTable:
+ return x + typeTable
+ case storage.TypeTemp:
+ return x + typeTemp
+ default:
+ panic("invalid file type")
+ }
+}
+
+func listFlattenType(m StorageMode, t storage.FileType) []int {
+ ret := make([]int, 0, flattenCount)
+ add := func(x int) {
+ x *= typeCount
+ switch {
+ case t&storage.TypeManifest != 0:
+ ret = append(ret, x+typeManifest)
+ case t&storage.TypeJournal != 0:
+ ret = append(ret, x+typeJournal)
+ case t&storage.TypeTable != 0:
+ ret = append(ret, x+typeTable)
+ case t&storage.TypeTemp != 0:
+ ret = append(ret, x+typeTemp)
+ }
+ }
+ switch {
+ case m&ModeOpen != 0:
+ add(modeOpen)
+ case m&ModeCreate != 0:
+ add(modeCreate)
+ case m&ModeRemove != 0:
+ add(modeRemove)
+ case m&ModeRead != 0:
+ add(modeRead)
+ case m&ModeWrite != 0:
+ add(modeWrite)
+ case m&ModeSync != 0:
+ add(modeSync)
+ case m&ModeClose != 0:
+ add(modeClose)
+ }
+ return ret
+}
+
+func packFile(num uint64, t storage.FileType) uint64 {
+ if num>>(64-typeCount) != 0 {
+ panic("overflow")
+ }
+ return num<<typeCount | uint64(t)
+}
+
+func unpackFile(x uint64) (uint64, storage.FileType) {
+ return x >> typeCount, storage.FileType(x) & storage.TypeAll
+}
+
+type emulatedError struct {
+ err error
+}
+
+func (err emulatedError) Error() string {
+ return fmt.Sprintf("emulated storage error: %v", err.err)
+}
+
+type storageLock struct {
+ s *Storage
+ r util.Releaser
+}
+
+func (l storageLock) Release() {
+ l.r.Release()
+ l.s.logI("storage lock released")
+}
+
+type reader struct {
+ f *file
+ storage.Reader
+}
+
+func (r *reader) Read(p []byte) (n int, err error) {
+ err = r.f.s.emulateError(ModeRead, r.f.Type())
+ if err == nil {
+ r.f.s.stall(ModeRead, r.f.Type())
+ n, err = r.Reader.Read(p)
+ }
+ r.f.s.count(ModeRead, r.f.Type(), n)
+ if err != nil && err != io.EOF {
+ r.f.s.logI("read error, num=%d type=%v n=%d err=%v", r.f.Num(), r.f.Type(), n, err)
+ }
+ return
+}
+
+func (r *reader) ReadAt(p []byte, off int64) (n int, err error) {
+ err = r.f.s.emulateError(ModeRead, r.f.Type())
+ if err == nil {
+ r.f.s.stall(ModeRead, r.f.Type())
+ n, err = r.Reader.ReadAt(p, off)
+ }
+ r.f.s.count(ModeRead, r.f.Type(), n)
+ if err != nil && err != io.EOF {
+ r.f.s.logI("readAt error, num=%d type=%v offset=%d n=%d err=%v", r.f.Num(), r.f.Type(), off, n, err)
+ }
+ return
+}
+
+func (r *reader) Close() (err error) {
+ return r.f.doClose(r.Reader)
+}
+
+type writer struct {
+ f *file
+ storage.Writer
+}
+
+func (w *writer) Write(p []byte) (n int, err error) {
+ err = w.f.s.emulateError(ModeWrite, w.f.Type())
+ if err == nil {
+ w.f.s.stall(ModeWrite, w.f.Type())
+ n, err = w.Writer.Write(p)
+ }
+ w.f.s.count(ModeWrite, w.f.Type(), n)
+ if err != nil && err != io.EOF {
+ w.f.s.logI("write error, num=%d type=%v n=%d err=%v", w.f.Num(), w.f.Type(), n, err)
+ }
+ return
+}
+
+func (w *writer) Sync() (err error) {
+ err = w.f.s.emulateError(ModeSync, w.f.Type())
+ if err == nil {
+ w.f.s.stall(ModeSync, w.f.Type())
+ err = w.Writer.Sync()
+ }
+ w.f.s.count(ModeSync, w.f.Type(), 0)
+ if err != nil {
+ w.f.s.logI("sync error, num=%d type=%v err=%v", w.f.Num(), w.f.Type(), err)
+ }
+ return
+}
+
+func (w *writer) Close() (err error) {
+ return w.f.doClose(w.Writer)
+}
+
+type file struct {
+ s *Storage
+ storage.File
+}
+
+func (f *file) pack() uint64 {
+ return packFile(f.Num(), f.Type())
+}
+
+func (f *file) assertOpen() {
+ ExpectWithOffset(2, f.s.opens).NotTo(HaveKey(f.pack()), "File open, num=%d type=%v writer=%v", f.Num(), f.Type(), f.s.opens[f.pack()])
+}
+
+func (f *file) doClose(closer io.Closer) (err error) {
+ err = f.s.emulateError(ModeClose, f.Type())
+ if err == nil {
+ f.s.stall(ModeClose, f.Type())
+ }
+ f.s.mu.Lock()
+ defer f.s.mu.Unlock()
+ if err == nil {
+ ExpectWithOffset(2, f.s.opens).To(HaveKey(f.pack()), "File closed, num=%d type=%v", f.Num(), f.Type())
+ err = closer.Close()
+ }
+ f.s.countNB(ModeClose, f.Type(), 0)
+ writer := f.s.opens[f.pack()]
+ if err != nil {
+ f.s.logISkip(1, "file close failed, num=%d type=%v writer=%v err=%v", f.Num(), f.Type(), writer, err)
+ } else {
+ f.s.logISkip(1, "file closed, num=%d type=%v writer=%v", f.Num(), f.Type(), writer)
+ delete(f.s.opens, f.pack())
+ }
+ return
+}
+
+func (f *file) Open() (r storage.Reader, err error) {
+ err = f.s.emulateError(ModeOpen, f.Type())
+ if err == nil {
+ f.s.stall(ModeOpen, f.Type())
+ }
+ f.s.mu.Lock()
+ defer f.s.mu.Unlock()
+ if err == nil {
+ f.assertOpen()
+ f.s.countNB(ModeOpen, f.Type(), 0)
+ r, err = f.File.Open()
+ }
+ if err != nil {
+ f.s.logI("file open failed, num=%d type=%v err=%v", f.Num(), f.Type(), err)
+ } else {
+ f.s.logI("file opened, num=%d type=%v", f.Num(), f.Type())
+ f.s.opens[f.pack()] = false
+ r = &reader{f, r}
+ }
+ return
+}
+
+func (f *file) Create() (w storage.Writer, err error) {
+ err = f.s.emulateError(ModeCreate, f.Type())
+ if err == nil {
+ f.s.stall(ModeCreate, f.Type())
+ }
+ f.s.mu.Lock()
+ defer f.s.mu.Unlock()
+ if err == nil {
+ f.assertOpen()
+ f.s.countNB(ModeCreate, f.Type(), 0)
+ w, err = f.File.Create()
+ }
+ if err != nil {
+ f.s.logI("file create failed, num=%d type=%v err=%v", f.Num(), f.Type(), err)
+ } else {
+ f.s.logI("file created, num=%d type=%v", f.Num(), f.Type())
+ f.s.opens[f.pack()] = true
+ w = &writer{f, w}
+ }
+ return
+}
+
+func (f *file) Remove() (err error) {
+ err = f.s.emulateError(ModeRemove, f.Type())
+ if err == nil {
+ f.s.stall(ModeRemove, f.Type())
+ }
+ f.s.mu.Lock()
+ defer f.s.mu.Unlock()
+ if err == nil {
+ f.assertOpen()
+ f.s.countNB(ModeRemove, f.Type(), 0)
+ err = f.File.Remove()
+ }
+ if err != nil {
+ f.s.logI("file remove failed, num=%d type=%v err=%v", f.Num(), f.Type(), err)
+ } else {
+ f.s.logI("file removed, num=%d type=%v", f.Num(), f.Type())
+ }
+ return
+}
+
+type Storage struct {
+ storage.Storage
+ closeFn func() error
+
+ lmu sync.Mutex
+ lb bytes.Buffer
+
+ mu sync.Mutex
+ // Open files, true=writer, false=reader
+ opens map[uint64]bool
+ counters [flattenCount]int
+ bytesCounter [flattenCount]int64
+ emulatedError [flattenCount]error
+ stallCond sync.Cond
+ stalled [flattenCount]bool
+}
+
+func (s *Storage) log(skip int, str string) {
+ s.lmu.Lock()
+ defer s.lmu.Unlock()
+ _, file, line, ok := runtime.Caller(skip + 2)
+ if ok {
+ // Truncate file name at last file name separator.
+ if index := strings.LastIndex(file, "/"); index >= 0 {
+ file = file[index+1:]
+ } else if index = strings.LastIndex(file, "\\"); index >= 0 {
+ file = file[index+1:]
+ }
+ } else {
+ file = "???"
+ line = 1
+ }
+ fmt.Fprintf(&s.lb, "%s:%d: ", file, line)
+ lines := strings.Split(str, "\n")
+ if l := len(lines); l > 1 && lines[l-1] == "" {
+ lines = lines[:l-1]
+ }
+ for i, line := range lines {
+ if i > 0 {
+ s.lb.WriteString("\n\t")
+ }
+ s.lb.WriteString(line)
+ }
+ s.lb.WriteByte('\n')
+}
+
+func (s *Storage) logISkip(skip int, format string, args ...interface{}) {
+ pc, _, _, ok := runtime.Caller(skip + 1)
+ if ok {
+ if f := runtime.FuncForPC(pc); f != nil {
+ fname := f.Name()
+ if index := strings.LastIndex(fname, "."); index >= 0 {
+ fname = fname[index+1:]
+ }
+ format = fname + ": " + format
+ }
+ }
+ s.log(skip+1, fmt.Sprintf(format, args...))
+}
+
+func (s *Storage) logI(format string, args ...interface{}) {
+ s.logISkip(1, format, args...)
+}
+
+func (s *Storage) Log(str string) {
+ s.log(1, "Log: "+str)
+}
+
+func (s *Storage) Lock() (r util.Releaser, err error) {
+ r, err = s.Storage.Lock()
+ if err != nil {
+ s.logI("storage locking failed, err=%v", err)
+ } else {
+ s.logI("storage locked")
+ r = storageLock{s, r}
+ }
+ return
+}
+
+func (s *Storage) GetFile(num uint64, t storage.FileType) storage.File {
+ return &file{s, s.Storage.GetFile(num, t)}
+}
+
+func (s *Storage) GetFiles(t storage.FileType) (files []storage.File, err error) {
+ rfiles, err := s.Storage.GetFiles(t)
+ if err != nil {
+ s.logI("get files failed, err=%v", err)
+ return
+ }
+ files = make([]storage.File, len(rfiles))
+ for i, f := range rfiles {
+ files[i] = &file{s, f}
+ }
+ s.logI("get files, type=0x%x count=%d", int(t), len(files))
+ return
+}
+
+func (s *Storage) GetManifest() (f storage.File, err error) {
+ manifest, err := s.Storage.GetManifest()
+ if err != nil {
+ if !os.IsNotExist(err) {
+ s.logI("get manifest failed, err=%v", err)
+ }
+ return
+ }
+ s.logI("get manifest, num=%d", manifest.Num())
+ return &file{s, manifest}, nil
+}
+
+func (s *Storage) SetManifest(f storage.File) error {
+ f_, ok := f.(*file)
+ ExpectWithOffset(1, ok).To(BeTrue())
+ ExpectWithOffset(1, f_.Type()).To(Equal(storage.TypeManifest))
+ err := s.Storage.SetManifest(f_.File)
+ if err != nil {
+ s.logI("set manifest failed, err=%v", err)
+ } else {
+ s.logI("set manifest, num=%d", f_.Num())
+ }
+ return err
+}
+
+func (s *Storage) openFiles() string {
+ out := "Open files:"
+ for x, writer := range s.opens {
+ num, t := unpackFile(x)
+ out += fmt.Sprintf("\n · num=%d type=%v writer=%v", num, t, writer)
+ }
+ return out
+}
+
+func (s *Storage) Close() error {
+ s.mu.Lock()
+ defer s.mu.Unlock()
+ ExpectWithOffset(1, s.opens).To(BeEmpty(), s.openFiles())
+ err := s.Storage.Close()
+ if err != nil {
+ s.logI("storage closing failed, err=%v", err)
+ } else {
+ s.logI("storage closed")
+ }
+ if s.closeFn != nil {
+ if err1 := s.closeFn(); err1 != nil {
+ s.logI("close func error, err=%v", err1)
+ }
+ }
+ return err
+}
+
+func (s *Storage) countNB(m StorageMode, t storage.FileType, n int) {
+ s.counters[flattenType(m, t)]++
+ s.bytesCounter[flattenType(m, t)] += int64(n)
+}
+
+func (s *Storage) count(m StorageMode, t storage.FileType, n int) {
+ s.mu.Lock()
+ defer s.mu.Unlock()
+ s.countNB(m, t, n)
+}
+
+func (s *Storage) ResetCounter(m StorageMode, t storage.FileType) {
+ for _, x := range listFlattenType(m, t) {
+ s.counters[x] = 0
+ s.bytesCounter[x] = 0
+ }
+}
+
+func (s *Storage) Counter(m StorageMode, t storage.FileType) (count int, bytes int64) {
+ for _, x := range listFlattenType(m, t) {
+ count += s.counters[x]
+ bytes += s.bytesCounter[x]
+ }
+ return
+}
+
+func (s *Storage) emulateError(m StorageMode, t storage.FileType) error {
+ s.mu.Lock()
+ defer s.mu.Unlock()
+ err := s.emulatedError[flattenType(m, t)]
+ if err != nil {
+ return emulatedError{err}
+ }
+ return nil
+}
+
+func (s *Storage) EmulateError(m StorageMode, t storage.FileType, err error) {
+ s.mu.Lock()
+ defer s.mu.Unlock()
+ for _, x := range listFlattenType(m, t) {
+ s.emulatedError[x] = err
+ }
+}
+
+func (s *Storage) stall(m StorageMode, t storage.FileType) {
+ x := flattenType(m, t)
+ s.mu.Lock()
+ defer s.mu.Unlock()
+ for s.stalled[x] {
+ s.stallCond.Wait()
+ }
+}
+
+func (s *Storage) Stall(m StorageMode, t storage.FileType) {
+ s.mu.Lock()
+ defer s.mu.Unlock()
+ for _, x := range listFlattenType(m, t) {
+ s.stalled[x] = true
+ }
+}
+
+func (s *Storage) Release(m StorageMode, t storage.FileType) {
+ s.mu.Lock()
+ defer s.mu.Unlock()
+ for _, x := range listFlattenType(m, t) {
+ s.stalled[x] = false
+ }
+ s.stallCond.Broadcast()
+}
+
+func NewStorage() *Storage {
+ var stor storage.Storage
+ var closeFn func() error
+ if storageUseFS {
+ for {
+ storageMu.Lock()
+ num := storageNum
+ storageNum++
+ storageMu.Unlock()
+ path := filepath.Join(os.TempDir(), fmt.Sprintf("goleveldb-test%d0%d0%d", os.Getuid(), os.Getpid(), num))
+ if _, err := os.Stat(path); os.IsNotExist(err) {
+ stor, err = storage.OpenFile(path)
+ ExpectWithOffset(1, err).NotTo(HaveOccurred(), "creating storage at %s", path)
+ closeFn = func() error {
+ if storageKeepFS {
+ return nil
+ }
+ return os.RemoveAll(path)
+ }
+ break
+ }
+ }
+ } else {
+ stor = storage.NewMemStorage()
+ }
+ s := &Storage{
+ Storage: stor,
+ closeFn: closeFn,
+ opens: make(map[uint64]bool),
+ }
+ s.stallCond.L = &s.mu
+ return s
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/testutil/util.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/testutil/util.go
new file mode 100644
index 000000000..38fe25d52
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/testutil/util.go
@@ -0,0 +1,157 @@
+// Copyright (c) 2014, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package testutil
+
+import (
+ "bytes"
+ "flag"
+ "math/rand"
+ "reflect"
+ "sync"
+
+ "github.com/onsi/ginkgo/config"
+
+ "github.com/syndtr/goleveldb/leveldb/comparer"
+)
+
+var (
+ runfn = make(map[string][]func())
+ runmu sync.Mutex
+)
+
+func Defer(args ...interface{}) bool {
+ var (
+ group string
+ fn func()
+ )
+ for _, arg := range args {
+ v := reflect.ValueOf(arg)
+ switch v.Kind() {
+ case reflect.String:
+ group = v.String()
+ case reflect.Func:
+ r := reflect.ValueOf(&fn).Elem()
+ r.Set(v)
+ }
+ }
+ if fn != nil {
+ runmu.Lock()
+ runfn[group] = append(runfn[group], fn)
+ runmu.Unlock()
+ }
+ return true
+}
+
+func RunDefer(groups ...string) bool {
+ if len(groups) == 0 {
+ groups = append(groups, "")
+ }
+ runmu.Lock()
+ var runfn_ []func()
+ for _, group := range groups {
+ runfn_ = append(runfn_, runfn[group]...)
+ delete(runfn, group)
+ }
+ runmu.Unlock()
+ for _, fn := range runfn_ {
+ fn()
+ }
+ return runfn_ != nil
+}
+
+func RandomSeed() int64 {
+ if !flag.Parsed() {
+ panic("random seed not initialized")
+ }
+ return config.GinkgoConfig.RandomSeed
+}
+
+func NewRand() *rand.Rand {
+ return rand.New(rand.NewSource(RandomSeed()))
+}
+
+var cmp = comparer.DefaultComparer
+
+func BytesSeparator(a, b []byte) []byte {
+ if bytes.Equal(a, b) {
+ return b
+ }
+ i, n := 0, len(a)
+ if n > len(b) {
+ n = len(b)
+ }
+ for ; i < n && (a[i] == b[i]); i++ {
+ }
+ x := append([]byte{}, a[:i]...)
+ if i < n {
+ if c := a[i] + 1; c < b[i] {
+ return append(x, c)
+ }
+ x = append(x, a[i])
+ i++
+ }
+ for ; i < len(a); i++ {
+ if c := a[i]; c < 0xff {
+ return append(x, c+1)
+ } else {
+ x = append(x, c)
+ }
+ }
+ if len(b) > i && b[i] > 0 {
+ return append(x, b[i]-1)
+ }
+ return append(x, 'x')
+}
+
+func BytesAfter(b []byte) []byte {
+ var x []byte
+ for _, c := range b {
+ if c < 0xff {
+ return append(x, c+1)
+ } else {
+ x = append(x, c)
+ }
+ }
+ return append(x, 'x')
+}
+
+func RandomIndex(rnd *rand.Rand, n, round int, fn func(i int)) {
+ if rnd == nil {
+ rnd = NewRand()
+ }
+ for x := 0; x < round; x++ {
+ fn(rnd.Intn(n))
+ }
+ return
+}
+
+func ShuffledIndex(rnd *rand.Rand, n, round int, fn func(i int)) {
+ if rnd == nil {
+ rnd = NewRand()
+ }
+ for x := 0; x < round; x++ {
+ for _, i := range rnd.Perm(n) {
+ fn(i)
+ }
+ }
+ return
+}
+
+func RandomRange(rnd *rand.Rand, n, round int, fn func(start, limit int)) {
+ if rnd == nil {
+ rnd = NewRand()
+ }
+ for x := 0; x < round; x++ {
+ start := rnd.Intn(n)
+ length := 0
+ if j := n - start; j > 0 {
+ length = rnd.Intn(j)
+ }
+ fn(start, start+length)
+ }
+ return
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/testutil_test.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/testutil_test.go
new file mode 100644
index 000000000..c1402fda3
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/testutil_test.go
@@ -0,0 +1,58 @@
+// Copyright (c) 2014, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package leveldb
+
+import (
+ . "github.com/onsi/gomega"
+
+ "github.com/syndtr/goleveldb/leveldb/iterator"
+ "github.com/syndtr/goleveldb/leveldb/opt"
+ "github.com/syndtr/goleveldb/leveldb/testutil"
+ "github.com/syndtr/goleveldb/leveldb/util"
+)
+
+type testingDB struct {
+ *DB
+ ro *opt.ReadOptions
+ wo *opt.WriteOptions
+ stor *testutil.Storage
+}
+
+func (t *testingDB) TestPut(key []byte, value []byte) error {
+ return t.Put(key, value, t.wo)
+}
+
+func (t *testingDB) TestDelete(key []byte) error {
+ return t.Delete(key, t.wo)
+}
+
+func (t *testingDB) TestGet(key []byte) (value []byte, err error) {
+ return t.Get(key, t.ro)
+}
+
+func (t *testingDB) TestNewIterator(slice *util.Range) iterator.Iterator {
+ return t.NewIterator(slice, t.ro)
+}
+
+func (t *testingDB) TestClose() {
+ err := t.Close()
+ ExpectWithOffset(1, err).NotTo(HaveOccurred())
+ err = t.stor.Close()
+ ExpectWithOffset(1, err).NotTo(HaveOccurred())
+}
+
+func newTestingDB(o *opt.Options, ro *opt.ReadOptions, wo *opt.WriteOptions) *testingDB {
+ stor := testutil.NewStorage()
+ db, err := Open(stor, o)
+ Expect(err).NotTo(HaveOccurred())
+ return &testingDB{
+ DB: db,
+ ro: ro,
+ wo: wo,
+ stor: stor,
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/util.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/util.go
new file mode 100644
index 000000000..a43d2e460
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/util.go
@@ -0,0 +1,91 @@
+// Copyright (c) 2012, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package leveldb
+
+import (
+ "fmt"
+ "sort"
+
+ "github.com/syndtr/goleveldb/leveldb/storage"
+)
+
+func shorten(str string) string {
+ if len(str) <= 4 {
+ return str
+ }
+ return str[:1] + ".." + str[len(str)-1:]
+}
+
+var bunits = [...]string{"", "Ki", "Mi", "Gi"}
+
+func shortenb(bytes int) string {
+ i := 0
+ for ; bytes > 1024 && i < 4; i++ {
+ bytes /= 1024
+ }
+ return fmt.Sprintf("%d%sB", bytes, bunits[i])
+}
+
+func sshortenb(bytes int) string {
+ if bytes == 0 {
+ return "~"
+ }
+ sign := "+"
+ if bytes < 0 {
+ sign = "-"
+ bytes *= -1
+ }
+ i := 0
+ for ; bytes > 1024 && i < 4; i++ {
+ bytes /= 1024
+ }
+ return fmt.Sprintf("%s%d%sB", sign, bytes, bunits[i])
+}
+
+func sint(x int) string {
+ if x == 0 {
+ return "~"
+ }
+ sign := "+"
+ if x < 0 {
+ sign = "-"
+ x *= -1
+ }
+ return fmt.Sprintf("%s%d", sign, x)
+}
+
+func minInt(a, b int) int {
+ if a < b {
+ return a
+ }
+ return b
+}
+
+func maxInt(a, b int) int {
+ if a > b {
+ return a
+ }
+ return b
+}
+
+type files []storage.File
+
+func (p files) Len() int {
+ return len(p)
+}
+
+func (p files) Less(i, j int) bool {
+ return p[i].Num() < p[j].Num()
+}
+
+func (p files) Swap(i, j int) {
+ p[i], p[j] = p[j], p[i]
+}
+
+func (p files) sort() {
+ sort.Sort(p)
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/util/buffer.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/util/buffer.go
new file mode 100644
index 000000000..21de24255
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/util/buffer.go
@@ -0,0 +1,293 @@
+// Copyright 2009 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+package util
+
+// This a copy of Go std bytes.Buffer with some modification
+// and some features stripped.
+
+import (
+ "bytes"
+ "io"
+)
+
+// A Buffer is a variable-sized buffer of bytes with Read and Write methods.
+// The zero value for Buffer is an empty buffer ready to use.
+type Buffer struct {
+ buf []byte // contents are the bytes buf[off : len(buf)]
+ off int // read at &buf[off], write at &buf[len(buf)]
+ bootstrap [64]byte // memory to hold first slice; helps small buffers (Printf) avoid allocation.
+}
+
+// Bytes returns a slice of the contents of the unread portion of the buffer;
+// len(b.Bytes()) == b.Len(). If the caller changes the contents of the
+// returned slice, the contents of the buffer will change provided there
+// are no intervening method calls on the Buffer.
+func (b *Buffer) Bytes() []byte { return b.buf[b.off:] }
+
+// String returns the contents of the unread portion of the buffer
+// as a string. If the Buffer is a nil pointer, it returns "<nil>".
+func (b *Buffer) String() string {
+ if b == nil {
+ // Special case, useful in debugging.
+ return "<nil>"
+ }
+ return string(b.buf[b.off:])
+}
+
+// Len returns the number of bytes of the unread portion of the buffer;
+// b.Len() == len(b.Bytes()).
+func (b *Buffer) Len() int { return len(b.buf) - b.off }
+
+// Truncate discards all but the first n unread bytes from the buffer.
+// It panics if n is negative or greater than the length of the buffer.
+func (b *Buffer) Truncate(n int) {
+ switch {
+ case n < 0 || n > b.Len():
+ panic("leveldb/util.Buffer: truncation out of range")
+ case n == 0:
+ // Reuse buffer space.
+ b.off = 0
+ }
+ b.buf = b.buf[0 : b.off+n]
+}
+
+// Reset resets the buffer so it has no content.
+// b.Reset() is the same as b.Truncate(0).
+func (b *Buffer) Reset() { b.Truncate(0) }
+
+// grow grows the buffer to guarantee space for n more bytes.
+// It returns the index where bytes should be written.
+// If the buffer can't grow it will panic with bytes.ErrTooLarge.
+func (b *Buffer) grow(n int) int {
+ m := b.Len()
+ // If buffer is empty, reset to recover space.
+ if m == 0 && b.off != 0 {
+ b.Truncate(0)
+ }
+ if len(b.buf)+n > cap(b.buf) {
+ var buf []byte
+ if b.buf == nil && n <= len(b.bootstrap) {
+ buf = b.bootstrap[0:]
+ } else if m+n <= cap(b.buf)/2 {
+ // We can slide things down instead of allocating a new
+ // slice. We only need m+n <= cap(b.buf) to slide, but
+ // we instead let capacity get twice as large so we
+ // don't spend all our time copying.
+ copy(b.buf[:], b.buf[b.off:])
+ buf = b.buf[:m]
+ } else {
+ // not enough space anywhere
+ buf = makeSlice(2*cap(b.buf) + n)
+ copy(buf, b.buf[b.off:])
+ }
+ b.buf = buf
+ b.off = 0
+ }
+ b.buf = b.buf[0 : b.off+m+n]
+ return b.off + m
+}
+
+// Alloc allocs n bytes of slice from the buffer, growing the buffer as
+// needed. If n is negative, Alloc will panic.
+// If the buffer can't grow it will panic with bytes.ErrTooLarge.
+func (b *Buffer) Alloc(n int) []byte {
+ if n < 0 {
+ panic("leveldb/util.Buffer.Alloc: negative count")
+ }
+ m := b.grow(n)
+ return b.buf[m:]
+}
+
+// Grow grows the buffer's capacity, if necessary, to guarantee space for
+// another n bytes. After Grow(n), at least n bytes can be written to the
+// buffer without another allocation.
+// If n is negative, Grow will panic.
+// If the buffer can't grow it will panic with bytes.ErrTooLarge.
+func (b *Buffer) Grow(n int) {
+ if n < 0 {
+ panic("leveldb/util.Buffer.Grow: negative count")
+ }
+ m := b.grow(n)
+ b.buf = b.buf[0:m]
+}
+
+// Write appends the contents of p to the buffer, growing the buffer as
+// needed. The return value n is the length of p; err is always nil. If the
+// buffer becomes too large, Write will panic with bytes.ErrTooLarge.
+func (b *Buffer) Write(p []byte) (n int, err error) {
+ m := b.grow(len(p))
+ return copy(b.buf[m:], p), nil
+}
+
+// MinRead is the minimum slice size passed to a Read call by
+// Buffer.ReadFrom. As long as the Buffer has at least MinRead bytes beyond
+// what is required to hold the contents of r, ReadFrom will not grow the
+// underlying buffer.
+const MinRead = 512
+
+// ReadFrom reads data from r until EOF and appends it to the buffer, growing
+// the buffer as needed. The return value n is the number of bytes read. Any
+// error except io.EOF encountered during the read is also returned. If the
+// buffer becomes too large, ReadFrom will panic with bytes.ErrTooLarge.
+func (b *Buffer) ReadFrom(r io.Reader) (n int64, err error) {
+ // If buffer is empty, reset to recover space.
+ if b.off >= len(b.buf) {
+ b.Truncate(0)
+ }
+ for {
+ if free := cap(b.buf) - len(b.buf); free < MinRead {
+ // not enough space at end
+ newBuf := b.buf
+ if b.off+free < MinRead {
+ // not enough space using beginning of buffer;
+ // double buffer capacity
+ newBuf = makeSlice(2*cap(b.buf) + MinRead)
+ }
+ copy(newBuf, b.buf[b.off:])
+ b.buf = newBuf[:len(b.buf)-b.off]
+ b.off = 0
+ }
+ m, e := r.Read(b.buf[len(b.buf):cap(b.buf)])
+ b.buf = b.buf[0 : len(b.buf)+m]
+ n += int64(m)
+ if e == io.EOF {
+ break
+ }
+ if e != nil {
+ return n, e
+ }
+ }
+ return n, nil // err is EOF, so return nil explicitly
+}
+
+// makeSlice allocates a slice of size n. If the allocation fails, it panics
+// with bytes.ErrTooLarge.
+func makeSlice(n int) []byte {
+ // If the make fails, give a known error.
+ defer func() {
+ if recover() != nil {
+ panic(bytes.ErrTooLarge)
+ }
+ }()
+ return make([]byte, n)
+}
+
+// WriteTo writes data to w until the buffer is drained or an error occurs.
+// The return value n is the number of bytes written; it always fits into an
+// int, but it is int64 to match the io.WriterTo interface. Any error
+// encountered during the write is also returned.
+func (b *Buffer) WriteTo(w io.Writer) (n int64, err error) {
+ if b.off < len(b.buf) {
+ nBytes := b.Len()
+ m, e := w.Write(b.buf[b.off:])
+ if m > nBytes {
+ panic("leveldb/util.Buffer.WriteTo: invalid Write count")
+ }
+ b.off += m
+ n = int64(m)
+ if e != nil {
+ return n, e
+ }
+ // all bytes should have been written, by definition of
+ // Write method in io.Writer
+ if m != nBytes {
+ return n, io.ErrShortWrite
+ }
+ }
+ // Buffer is now empty; reset.
+ b.Truncate(0)
+ return
+}
+
+// WriteByte appends the byte c to the buffer, growing the buffer as needed.
+// The returned error is always nil, but is included to match bufio.Writer's
+// WriteByte. If the buffer becomes too large, WriteByte will panic with
+// bytes.ErrTooLarge.
+func (b *Buffer) WriteByte(c byte) error {
+ m := b.grow(1)
+ b.buf[m] = c
+ return nil
+}
+
+// Read reads the next len(p) bytes from the buffer or until the buffer
+// is drained. The return value n is the number of bytes read. If the
+// buffer has no data to return, err is io.EOF (unless len(p) is zero);
+// otherwise it is nil.
+func (b *Buffer) Read(p []byte) (n int, err error) {
+ if b.off >= len(b.buf) {
+ // Buffer is empty, reset to recover space.
+ b.Truncate(0)
+ if len(p) == 0 {
+ return
+ }
+ return 0, io.EOF
+ }
+ n = copy(p, b.buf[b.off:])
+ b.off += n
+ return
+}
+
+// Next returns a slice containing the next n bytes from the buffer,
+// advancing the buffer as if the bytes had been returned by Read.
+// If there are fewer than n bytes in the buffer, Next returns the entire buffer.
+// The slice is only valid until the next call to a read or write method.
+func (b *Buffer) Next(n int) []byte {
+ m := b.Len()
+ if n > m {
+ n = m
+ }
+ data := b.buf[b.off : b.off+n]
+ b.off += n
+ return data
+}
+
+// ReadByte reads and returns the next byte from the buffer.
+// If no byte is available, it returns error io.EOF.
+func (b *Buffer) ReadByte() (c byte, err error) {
+ if b.off >= len(b.buf) {
+ // Buffer is empty, reset to recover space.
+ b.Truncate(0)
+ return 0, io.EOF
+ }
+ c = b.buf[b.off]
+ b.off++
+ return c, nil
+}
+
+// ReadBytes reads until the first occurrence of delim in the input,
+// returning a slice containing the data up to and including the delimiter.
+// If ReadBytes encounters an error before finding a delimiter,
+// it returns the data read before the error and the error itself (often io.EOF).
+// ReadBytes returns err != nil if and only if the returned data does not end in
+// delim.
+func (b *Buffer) ReadBytes(delim byte) (line []byte, err error) {
+ slice, err := b.readSlice(delim)
+ // return a copy of slice. The buffer's backing array may
+ // be overwritten by later calls.
+ line = append(line, slice...)
+ return
+}
+
+// readSlice is like ReadBytes but returns a reference to internal buffer data.
+func (b *Buffer) readSlice(delim byte) (line []byte, err error) {
+ i := bytes.IndexByte(b.buf[b.off:], delim)
+ end := b.off + i + 1
+ if i < 0 {
+ end = len(b.buf)
+ err = io.EOF
+ }
+ line = b.buf[b.off:end]
+ b.off = end
+ return line, err
+}
+
+// NewBuffer creates and initializes a new Buffer using buf as its initial
+// contents. It is intended to prepare a Buffer to read existing data. It
+// can also be used to size the internal buffer for writing. To do that,
+// buf should have the desired capacity but a length of zero.
+//
+// In most cases, new(Buffer) (or just declaring a Buffer variable) is
+// sufficient to initialize a Buffer.
+func NewBuffer(buf []byte) *Buffer { return &Buffer{buf: buf} }
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/util/buffer_test.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/util/buffer_test.go
new file mode 100644
index 000000000..87d96739c
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/util/buffer_test.go
@@ -0,0 +1,369 @@
+// Copyright 2009 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+package util
+
+import (
+ "bytes"
+ "io"
+ "math/rand"
+ "runtime"
+ "testing"
+)
+
+const N = 10000 // make this bigger for a larger (and slower) test
+var data string // test data for write tests
+var testBytes []byte // test data; same as data but as a slice.
+
+func init() {
+ testBytes = make([]byte, N)
+ for i := 0; i < N; i++ {
+ testBytes[i] = 'a' + byte(i%26)
+ }
+ data = string(testBytes)
+}
+
+// Verify that contents of buf match the string s.
+func check(t *testing.T, testname string, buf *Buffer, s string) {
+ bytes := buf.Bytes()
+ str := buf.String()
+ if buf.Len() != len(bytes) {
+ t.Errorf("%s: buf.Len() == %d, len(buf.Bytes()) == %d", testname, buf.Len(), len(bytes))
+ }
+
+ if buf.Len() != len(str) {
+ t.Errorf("%s: buf.Len() == %d, len(buf.String()) == %d", testname, buf.Len(), len(str))
+ }
+
+ if buf.Len() != len(s) {
+ t.Errorf("%s: buf.Len() == %d, len(s) == %d", testname, buf.Len(), len(s))
+ }
+
+ if string(bytes) != s {
+ t.Errorf("%s: string(buf.Bytes()) == %q, s == %q", testname, string(bytes), s)
+ }
+}
+
+// Fill buf through n writes of byte slice fub.
+// The initial contents of buf corresponds to the string s;
+// the result is the final contents of buf returned as a string.
+func fillBytes(t *testing.T, testname string, buf *Buffer, s string, n int, fub []byte) string {
+ check(t, testname+" (fill 1)", buf, s)
+ for ; n > 0; n-- {
+ m, err := buf.Write(fub)
+ if m != len(fub) {
+ t.Errorf(testname+" (fill 2): m == %d, expected %d", m, len(fub))
+ }
+ if err != nil {
+ t.Errorf(testname+" (fill 3): err should always be nil, found err == %s", err)
+ }
+ s += string(fub)
+ check(t, testname+" (fill 4)", buf, s)
+ }
+ return s
+}
+
+func TestNewBuffer(t *testing.T) {
+ buf := NewBuffer(testBytes)
+ check(t, "NewBuffer", buf, data)
+}
+
+// Empty buf through repeated reads into fub.
+// The initial contents of buf corresponds to the string s.
+func empty(t *testing.T, testname string, buf *Buffer, s string, fub []byte) {
+ check(t, testname+" (empty 1)", buf, s)
+
+ for {
+ n, err := buf.Read(fub)
+ if n == 0 {
+ break
+ }
+ if err != nil {
+ t.Errorf(testname+" (empty 2): err should always be nil, found err == %s", err)
+ }
+ s = s[n:]
+ check(t, testname+" (empty 3)", buf, s)
+ }
+
+ check(t, testname+" (empty 4)", buf, "")
+}
+
+func TestBasicOperations(t *testing.T) {
+ var buf Buffer
+
+ for i := 0; i < 5; i++ {
+ check(t, "TestBasicOperations (1)", &buf, "")
+
+ buf.Reset()
+ check(t, "TestBasicOperations (2)", &buf, "")
+
+ buf.Truncate(0)
+ check(t, "TestBasicOperations (3)", &buf, "")
+
+ n, err := buf.Write([]byte(data[0:1]))
+ if n != 1 {
+ t.Errorf("wrote 1 byte, but n == %d", n)
+ }
+ if err != nil {
+ t.Errorf("err should always be nil, but err == %s", err)
+ }
+ check(t, "TestBasicOperations (4)", &buf, "a")
+
+ buf.WriteByte(data[1])
+ check(t, "TestBasicOperations (5)", &buf, "ab")
+
+ n, err = buf.Write([]byte(data[2:26]))
+ if n != 24 {
+ t.Errorf("wrote 25 bytes, but n == %d", n)
+ }
+ check(t, "TestBasicOperations (6)", &buf, string(data[0:26]))
+
+ buf.Truncate(26)
+ check(t, "TestBasicOperations (7)", &buf, string(data[0:26]))
+
+ buf.Truncate(20)
+ check(t, "TestBasicOperations (8)", &buf, string(data[0:20]))
+
+ empty(t, "TestBasicOperations (9)", &buf, string(data[0:20]), make([]byte, 5))
+ empty(t, "TestBasicOperations (10)", &buf, "", make([]byte, 100))
+
+ buf.WriteByte(data[1])
+ c, err := buf.ReadByte()
+ if err != nil {
+ t.Error("ReadByte unexpected eof")
+ }
+ if c != data[1] {
+ t.Errorf("ReadByte wrong value c=%v", c)
+ }
+ c, err = buf.ReadByte()
+ if err == nil {
+ t.Error("ReadByte unexpected not eof")
+ }
+ }
+}
+
+func TestLargeByteWrites(t *testing.T) {
+ var buf Buffer
+ limit := 30
+ if testing.Short() {
+ limit = 9
+ }
+ for i := 3; i < limit; i += 3 {
+ s := fillBytes(t, "TestLargeWrites (1)", &buf, "", 5, testBytes)
+ empty(t, "TestLargeByteWrites (2)", &buf, s, make([]byte, len(data)/i))
+ }
+ check(t, "TestLargeByteWrites (3)", &buf, "")
+}
+
+func TestLargeByteReads(t *testing.T) {
+ var buf Buffer
+ for i := 3; i < 30; i += 3 {
+ s := fillBytes(t, "TestLargeReads (1)", &buf, "", 5, testBytes[0:len(testBytes)/i])
+ empty(t, "TestLargeReads (2)", &buf, s, make([]byte, len(data)))
+ }
+ check(t, "TestLargeByteReads (3)", &buf, "")
+}
+
+func TestMixedReadsAndWrites(t *testing.T) {
+ var buf Buffer
+ s := ""
+ for i := 0; i < 50; i++ {
+ wlen := rand.Intn(len(data))
+ s = fillBytes(t, "TestMixedReadsAndWrites (1)", &buf, s, 1, testBytes[0:wlen])
+ rlen := rand.Intn(len(data))
+ fub := make([]byte, rlen)
+ n, _ := buf.Read(fub)
+ s = s[n:]
+ }
+ empty(t, "TestMixedReadsAndWrites (2)", &buf, s, make([]byte, buf.Len()))
+}
+
+func TestNil(t *testing.T) {
+ var b *Buffer
+ if b.String() != "<nil>" {
+ t.Errorf("expected <nil>; got %q", b.String())
+ }
+}
+
+func TestReadFrom(t *testing.T) {
+ var buf Buffer
+ for i := 3; i < 30; i += 3 {
+ s := fillBytes(t, "TestReadFrom (1)", &buf, "", 5, testBytes[0:len(testBytes)/i])
+ var b Buffer
+ b.ReadFrom(&buf)
+ empty(t, "TestReadFrom (2)", &b, s, make([]byte, len(data)))
+ }
+}
+
+func TestWriteTo(t *testing.T) {
+ var buf Buffer
+ for i := 3; i < 30; i += 3 {
+ s := fillBytes(t, "TestWriteTo (1)", &buf, "", 5, testBytes[0:len(testBytes)/i])
+ var b Buffer
+ buf.WriteTo(&b)
+ empty(t, "TestWriteTo (2)", &b, s, make([]byte, len(data)))
+ }
+}
+
+func TestNext(t *testing.T) {
+ b := []byte{0, 1, 2, 3, 4}
+ tmp := make([]byte, 5)
+ for i := 0; i <= 5; i++ {
+ for j := i; j <= 5; j++ {
+ for k := 0; k <= 6; k++ {
+ // 0 <= i <= j <= 5; 0 <= k <= 6
+ // Check that if we start with a buffer
+ // of length j at offset i and ask for
+ // Next(k), we get the right bytes.
+ buf := NewBuffer(b[0:j])
+ n, _ := buf.Read(tmp[0:i])
+ if n != i {
+ t.Fatalf("Read %d returned %d", i, n)
+ }
+ bb := buf.Next(k)
+ want := k
+ if want > j-i {
+ want = j - i
+ }
+ if len(bb) != want {
+ t.Fatalf("in %d,%d: len(Next(%d)) == %d", i, j, k, len(bb))
+ }
+ for l, v := range bb {
+ if v != byte(l+i) {
+ t.Fatalf("in %d,%d: Next(%d)[%d] = %d, want %d", i, j, k, l, v, l+i)
+ }
+ }
+ }
+ }
+ }
+}
+
+var readBytesTests = []struct {
+ buffer string
+ delim byte
+ expected []string
+ err error
+}{
+ {"", 0, []string{""}, io.EOF},
+ {"a\x00", 0, []string{"a\x00"}, nil},
+ {"abbbaaaba", 'b', []string{"ab", "b", "b", "aaab"}, nil},
+ {"hello\x01world", 1, []string{"hello\x01"}, nil},
+ {"foo\nbar", 0, []string{"foo\nbar"}, io.EOF},
+ {"alpha\nbeta\ngamma\n", '\n', []string{"alpha\n", "beta\n", "gamma\n"}, nil},
+ {"alpha\nbeta\ngamma", '\n', []string{"alpha\n", "beta\n", "gamma"}, io.EOF},
+}
+
+func TestReadBytes(t *testing.T) {
+ for _, test := range readBytesTests {
+ buf := NewBuffer([]byte(test.buffer))
+ var err error
+ for _, expected := range test.expected {
+ var bytes []byte
+ bytes, err = buf.ReadBytes(test.delim)
+ if string(bytes) != expected {
+ t.Errorf("expected %q, got %q", expected, bytes)
+ }
+ if err != nil {
+ break
+ }
+ }
+ if err != test.err {
+ t.Errorf("expected error %v, got %v", test.err, err)
+ }
+ }
+}
+
+func TestGrow(t *testing.T) {
+ x := []byte{'x'}
+ y := []byte{'y'}
+ tmp := make([]byte, 72)
+ for _, startLen := range []int{0, 100, 1000, 10000, 100000} {
+ xBytes := bytes.Repeat(x, startLen)
+ for _, growLen := range []int{0, 100, 1000, 10000, 100000} {
+ buf := NewBuffer(xBytes)
+ // If we read, this affects buf.off, which is good to test.
+ readBytes, _ := buf.Read(tmp)
+ buf.Grow(growLen)
+ yBytes := bytes.Repeat(y, growLen)
+ // Check no allocation occurs in write, as long as we're single-threaded.
+ var m1, m2 runtime.MemStats
+ runtime.ReadMemStats(&m1)
+ buf.Write(yBytes)
+ runtime.ReadMemStats(&m2)
+ if runtime.GOMAXPROCS(-1) == 1 && m1.Mallocs != m2.Mallocs {
+ t.Errorf("allocation occurred during write")
+ }
+ // Check that buffer has correct data.
+ if !bytes.Equal(buf.Bytes()[0:startLen-readBytes], xBytes[readBytes:]) {
+ t.Errorf("bad initial data at %d %d", startLen, growLen)
+ }
+ if !bytes.Equal(buf.Bytes()[startLen-readBytes:startLen-readBytes+growLen], yBytes) {
+ t.Errorf("bad written data at %d %d", startLen, growLen)
+ }
+ }
+ }
+}
+
+// Was a bug: used to give EOF reading empty slice at EOF.
+func TestReadEmptyAtEOF(t *testing.T) {
+ b := new(Buffer)
+ slice := make([]byte, 0)
+ n, err := b.Read(slice)
+ if err != nil {
+ t.Errorf("read error: %v", err)
+ }
+ if n != 0 {
+ t.Errorf("wrong count; got %d want 0", n)
+ }
+}
+
+// Tests that we occasionally compact. Issue 5154.
+func TestBufferGrowth(t *testing.T) {
+ var b Buffer
+ buf := make([]byte, 1024)
+ b.Write(buf[0:1])
+ var cap0 int
+ for i := 0; i < 5<<10; i++ {
+ b.Write(buf)
+ b.Read(buf)
+ if i == 0 {
+ cap0 = cap(b.buf)
+ }
+ }
+ cap1 := cap(b.buf)
+ // (*Buffer).grow allows for 2x capacity slop before sliding,
+ // so set our error threshold at 3x.
+ if cap1 > cap0*3 {
+ t.Errorf("buffer cap = %d; too big (grew from %d)", cap1, cap0)
+ }
+}
+
+// From Issue 5154.
+func BenchmarkBufferNotEmptyWriteRead(b *testing.B) {
+ buf := make([]byte, 1024)
+ for i := 0; i < b.N; i++ {
+ var b Buffer
+ b.Write(buf[0:1])
+ for i := 0; i < 5<<10; i++ {
+ b.Write(buf)
+ b.Read(buf)
+ }
+ }
+}
+
+// Check that we don't compact too often. From Issue 5154.
+func BenchmarkBufferFullSmallReads(b *testing.B) {
+ buf := make([]byte, 1024)
+ for i := 0; i < b.N; i++ {
+ var b Buffer
+ b.Write(buf)
+ for b.Len()+20 < cap(b.buf) {
+ b.Write(buf[:10])
+ }
+ for i := 0; i < 5<<10; i++ {
+ b.Read(buf[:1])
+ b.Write(buf[:1])
+ }
+ }
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/util/crc32.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/util/crc32.go
new file mode 100644
index 000000000..631c9d610
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/util/crc32.go
@@ -0,0 +1,30 @@
+// Copyright 2011 The LevelDB-Go Authors. All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package util
+
+import (
+ "hash/crc32"
+)
+
+var table = crc32.MakeTable(crc32.Castagnoli)
+
+// CRC is a CRC-32 checksum computed using Castagnoli's polynomial.
+type CRC uint32
+
+// NewCRC creates a new crc based on the given bytes.
+func NewCRC(b []byte) CRC {
+ return CRC(0).Update(b)
+}
+
+// Update updates the crc with the given bytes.
+func (c CRC) Update(b []byte) CRC {
+ return CRC(crc32.Update(uint32(c), table, b))
+}
+
+// Value returns a masked crc.
+func (c CRC) Value() uint32 {
+ return uint32(c>>15|c<<17) + 0xa282ead8
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/util/hash.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/util/hash.go
new file mode 100644
index 000000000..54903660f
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/util/hash.go
@@ -0,0 +1,48 @@
+// Copyright (c) 2012, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package util
+
+import (
+ "bytes"
+ "encoding/binary"
+)
+
+// Hash return hash of the given data.
+func Hash(data []byte, seed uint32) uint32 {
+ // Similar to murmur hash
+ var m uint32 = 0xc6a4a793
+ var r uint32 = 24
+ h := seed ^ (uint32(len(data)) * m)
+
+ buf := bytes.NewBuffer(data)
+ for buf.Len() >= 4 {
+ var w uint32
+ binary.Read(buf, binary.LittleEndian, &w)
+ h += w
+ h *= m
+ h ^= (h >> 16)
+ }
+
+ rest := buf.Bytes()
+ switch len(rest) {
+ default:
+ panic("not reached")
+ case 3:
+ h += uint32(rest[2]) << 16
+ fallthrough
+ case 2:
+ h += uint32(rest[1]) << 8
+ fallthrough
+ case 1:
+ h += uint32(rest[0])
+ h *= m
+ h ^= (h >> r)
+ case 0:
+ }
+
+ return h
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/util/range.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/util/range.go
new file mode 100644
index 000000000..da0583123
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/util/range.go
@@ -0,0 +1,16 @@
+// Copyright (c) 2014, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package util
+
+// Range is a key range.
+type Range struct {
+ // Start of the key range, include in the range.
+ Start []byte
+
+ // Limit of the key range, not include in the range.
+ Limit []byte
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/util/util.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/util/util.go
new file mode 100644
index 000000000..229c7d41f
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/util/util.go
@@ -0,0 +1,49 @@
+// Copyright (c) 2013, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// Package util provides utilities used throughout leveldb.
+package util
+
+import (
+ "errors"
+)
+
+var (
+ ErrNotFound = errors.New("leveldb: not found")
+)
+
+// Releaser is the interface that wraps the basic Release method.
+type Releaser interface {
+ // Release releases associated resources. Release should always success
+ // and can be called multipe times without causing error.
+ Release()
+}
+
+// ReleaseSetter is the interface that wraps the basic SetReleaser method.
+type ReleaseSetter interface {
+ // SetReleaser associates the given releaser to the resources. The
+ // releaser will be called once coresponding resources released.
+ // Calling SetReleaser with nil will clear the releaser.
+ SetReleaser(releaser Releaser)
+}
+
+// BasicReleaser provides basic implementation of Releaser and ReleaseSetter.
+type BasicReleaser struct {
+ releaser Releaser
+}
+
+// Release implements Releaser.Release.
+func (r *BasicReleaser) Release() {
+ if r.releaser != nil {
+ r.releaser.Release()
+ r.releaser = nil
+ }
+}
+
+// SetReleaser implements ReleaseSetter.SetReleaser.
+func (r *BasicReleaser) SetReleaser(releaser Releaser) {
+ r.releaser = releaser
+}
diff --git a/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/version.go b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/version.go
new file mode 100644
index 000000000..4c54d6480
--- /dev/null
+++ b/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/version.go
@@ -0,0 +1,428 @@
+// Copyright (c) 2012, Suryandaru Triandana <syndtr@gmail.com>
+// All rights reserved.
+//
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package leveldb
+
+import (
+ "errors"
+ "sync/atomic"
+ "unsafe"
+
+ "github.com/syndtr/goleveldb/leveldb/iterator"
+ "github.com/syndtr/goleveldb/leveldb/opt"
+ "github.com/syndtr/goleveldb/leveldb/util"
+)
+
+var levelMaxSize [kNumLevels]float64
+
+func init() {
+ // Precompute max size of each level
+ for level := range levelMaxSize {
+ res := float64(10 * 1048576)
+ for n := level; n > 1; n-- {
+ res *= 10
+ }
+ levelMaxSize[level] = res
+ }
+}
+
+type tSet struct {
+ level int
+ table *tFile
+}
+
+type version struct {
+ s *session
+
+ tables [kNumLevels]tFiles
+
+ // Level that should be compacted next and its compaction score.
+ // Score < 1 means compaction is not strictly needed. These fields
+ // are initialized by ComputeCompaction()
+ cLevel int
+ cScore float64
+
+ cSeek unsafe.Pointer
+
+ ref int
+ next *version
+}
+
+func (v *version) release_NB() {
+ v.ref--
+ if v.ref > 0 {
+ return
+ }
+ if v.ref < 0 {
+ panic("negative version ref")
+ }
+
+ s := v.s
+
+ tables := make(map[uint64]bool)
+ for _, tt := range v.next.tables {
+ for _, t := range tt {
+ num := t.file.Num()
+ tables[num] = true
+ }
+ }
+
+ for _, tt := range v.tables {
+ for _, t := range tt {
+ num := t.file.Num()
+ if _, ok := tables[num]; !ok {
+ s.tops.remove(t)
+ }
+ }
+ }
+
+ v.next.release_NB()
+ v.next = nil
+}
+
+func (v *version) release() {
+ v.s.vmu.Lock()
+ v.release_NB()
+ v.s.vmu.Unlock()
+}
+
+func (v *version) get(key iKey, ro *opt.ReadOptions) (value []byte, cstate bool, err error) {
+ s := v.s
+
+ ukey := key.ukey()
+
+ var tset *tSet
+ tseek := true
+
+ // We can search level-by-level since entries never hop across
+ // levels. Therefore we are guaranteed that if we find data
+ // in an smaller level, later levels are irrelevant.
+ for level, ts := range v.tables {
+ if len(ts) == 0 {
+ continue
+ }
+
+ if level == 0 {
+ // Level-0 files may overlap each other. Find all files that
+ // overlap user_key and process them in order from newest to
+ var tmp tFiles
+ for _, t := range ts {
+ if s.icmp.uCompare(ukey, t.min.ukey()) >= 0 &&
+ s.icmp.uCompare(ukey, t.max.ukey()) <= 0 {
+ tmp = append(tmp, t)
+ }
+ }
+
+ if len(tmp) == 0 {
+ continue
+ }
+
+ tmp.sortByNum()
+ ts = tmp
+ } else {
+ i := ts.searchMax(key, s.icmp)
+ if i >= len(ts) || s.icmp.uCompare(ukey, ts[i].min.ukey()) < 0 {
+ continue
+ }
+
+ ts = ts[i : i+1]
+ }
+
+ var l0found bool
+ var l0seq uint64
+ var l0type vType
+ var l0value []byte
+ for _, t := range ts {
+ if tseek {
+ if tset == nil {
+ tset = &tSet{level, t}
+ } else if tset.table.incrSeek() <= 0 {
+ cstate = atomic.CompareAndSwapPointer(&v.cSeek, nil, unsafe.Pointer(tset))
+ tseek = false
+ }
+ }
+
+ var _rkey, rval []byte
+ _rkey, rval, err = s.tops.get(t, key, ro)
+ if err == ErrNotFound {
+ continue
+ } else if err != nil {
+ return
+ }
+
+ rkey := iKey(_rkey)
+ if seq, t, ok := rkey.parseNum(); ok {
+ if s.icmp.uCompare(ukey, rkey.ukey()) == 0 {
+ if level == 0 {
+ if seq >= l0seq {
+ l0found = true
+ l0seq = seq
+ l0type = t
+ l0value = rval
+ }
+ } else {
+ switch t {
+ case tVal:
+ value = rval
+ case tDel:
+ err = ErrNotFound
+ default:
+ panic("invalid type")
+ }
+ return
+ }
+ }
+ } else {
+ err = errors.New("leveldb: internal key corrupted")
+ return
+ }
+ }
+ if level == 0 && l0found {
+ switch l0type {
+ case tVal:
+ value = l0value
+ case tDel:
+ err = ErrNotFound
+ default:
+ panic("invalid type")
+ }
+ return
+ }
+ }
+
+ err = ErrNotFound
+ return
+}
+
+func (v *version) getIterators(slice *util.Range, ro *opt.ReadOptions) (its []iterator.Iterator) {
+ s := v.s
+
+ // Merge all level zero files together since they may overlap
+ for _, t := range v.tables[0] {
+ it := s.tops.newIterator(t, slice, ro)
+ its = append(its, it)
+ }
+
+ strict := s.o.GetStrict(opt.StrictIterator) || ro.GetStrict(opt.StrictIterator)
+ for _, tt := range v.tables[1:] {
+ if len(tt) == 0 {
+ continue
+ }
+
+ it := iterator.NewIndexedIterator(tt.newIndexIterator(s.tops, s.icmp, slice, ro), strict, true)
+ its = append(its, it)
+ }
+
+ return
+}
+
+func (v *version) newStaging() *versionStaging {
+ return &versionStaging{base: v}
+}
+
+// Spawn a new version based on this version.
+func (v *version) spawn(r *sessionRecord) *version {
+ staging := v.newStaging()
+ staging.commit(r)
+ return staging.finish()
+}
+
+func (v *version) fillRecord(r *sessionRecord) {
+ for level, ts := range v.tables {
+ for _, t := range ts {
+ r.addTableFile(level, t)
+ }
+ }
+}
+
+func (v *version) tLen(level int) int {
+ return len(v.tables[level])
+}
+
+func (v *version) offsetOf(key iKey) (n uint64, err error) {
+ for level, tt := range v.tables {
+ for _, t := range tt {
+ if v.s.icmp.Compare(t.max, key) <= 0 {
+ // Entire file is before "key", so just add the file size
+ n += t.size
+ } else if v.s.icmp.Compare(t.min, key) > 0 {
+ // Entire file is after "key", so ignore
+ if level > 0 {
+ // Files other than level 0 are sorted by meta->min, so
+ // no further files in this level will contain data for
+ // "key".
+ break
+ }
+ } else {
+ // "key" falls in the range for this table. Add the
+ // approximate offset of "key" within the table.
+ var nn uint64
+ nn, err = v.s.tops.offsetOf(t, key)
+ if err != nil {
+ return 0, err
+ }
+ n += nn
+ }
+ }
+ }
+
+ return
+}
+
+func (v *version) pickLevel(min, max []byte) (level int) {
+ if !v.tables[0].isOverlaps(min, max, false, v.s.icmp) {
+ var r tFiles
+ for ; level < kMaxMemCompactLevel; level++ {
+ if v.tables[level+1].isOverlaps(min, max, true, v.s.icmp) {
+ break
+ }
+ v.tables[level+2].getOverlaps(min, max, &r, true, v.s.icmp.ucmp)
+ if r.size() > kMaxGrandParentOverlapBytes {
+ break
+ }
+ }
+ }
+
+ return
+}
+
+func (v *version) computeCompaction() {
+ // Precomputed best level for next compaction
+ var bestLevel int = -1
+ var bestScore float64 = -1
+
+ for level, ff := range v.tables {
+ var score float64
+ if level == 0 {
+ // We treat level-0 specially by bounding the number of files
+ // instead of number of bytes for two reasons:
+ //
+ // (1) With larger write-buffer sizes, it is nice not to do too
+ // many level-0 compactions.
+ //
+ // (2) The files in level-0 are merged on every read and
+ // therefore we wish to avoid too many files when the individual
+ // file size is small (perhaps because of a small write-buffer
+ // setting, or very high compression ratios, or lots of
+ // overwrites/deletions).
+ score = float64(len(ff)) / kL0_CompactionTrigger
+ } else {
+ score = float64(ff.size()) / levelMaxSize[level]
+ }
+
+ if score > bestScore {
+ bestLevel = level
+ bestScore = score
+ }
+ }
+
+ v.cLevel = bestLevel
+ v.cScore = bestScore
+}
+
+func (v *version) needCompaction() bool {
+ return v.cScore >= 1 || atomic.LoadPointer(&v.cSeek) != nil
+}
+
+type versionStaging struct {
+ base *version
+ tables [kNumLevels]struct {
+ added map[uint64]ntRecord
+ deleted map[uint64]struct{}
+ }
+}
+
+func (p *versionStaging) commit(r *sessionRecord) {
+ btt := p.base.tables
+
+ // deleted tables
+ for _, tr := range r.deletedTables {
+ tm := &(p.tables[tr.level])
+
+ bt := btt[tr.level]
+ if len(bt) > 0 {
+ if tm.deleted == nil {
+ tm.deleted = make(map[uint64]struct{})
+ }
+ tm.deleted[tr.num] = struct{}{}
+ }
+
+ if tm.added != nil {
+ delete(tm.added, tr.num)
+ }
+ }
+
+ // new tables
+ for _, tr := range r.addedTables {
+ tm := &(p.tables[tr.level])
+
+ if tm.added == nil {
+ tm.added = make(map[uint64]ntRecord)
+ }
+ tm.added[tr.num] = tr
+
+ if tm.deleted != nil {
+ delete(tm.deleted, tr.num)
+ }
+ }
+}
+
+func (p *versionStaging) finish() *version {
+ s := p.base.s
+ btt := p.base.tables
+
+ // build new version
+ nv := &version{s: s}
+ for level, tm := range p.tables {
+ bt := btt[level]
+
+ n := len(bt) + len(tm.added) - len(tm.deleted)
+ if n < 0 {
+ n = 0
+ }
+ nt := make(tFiles, 0, n)
+
+ // base tables
+ for _, t := range bt {
+ if _, ok := tm.deleted[t.file.Num()]; ok {
+ continue
+ }
+ if _, ok := tm.added[t.file.Num()]; ok {
+ continue
+ }
+ nt = append(nt, t)
+ }
+
+ // new tables
+ for _, tr := range tm.added {
+ nt = append(nt, tr.makeFile(s))
+ }
+
+ // sort tables
+ nt.sortByKey(s.icmp)
+ nv.tables[level] = nt
+ }
+
+ // compute compaction score for new version
+ nv.computeCompaction()
+
+ return nv
+}
+
+type versionReleaser struct {
+ v *version
+ once bool
+}
+
+func (vr *versionReleaser) Release() {
+ v := vr.v
+ v.s.vmu.Lock()
+ if !vr.once {
+ v.release_NB()
+ vr.once = true
+ }
+ v.s.vmu.Unlock()
+}
diff --git a/Godeps/_workspace/src/golang.org/x/crypto/pbkdf2/pbkdf2.go b/Godeps/_workspace/src/golang.org/x/crypto/pbkdf2/pbkdf2.go
new file mode 100644
index 000000000..c02b4d5a7
--- /dev/null
+++ b/Godeps/_workspace/src/golang.org/x/crypto/pbkdf2/pbkdf2.go
@@ -0,0 +1,77 @@
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+/*
+Package pbkdf2 implements the key derivation function PBKDF2 as defined in RFC
+2898 / PKCS #5 v2.0.
+
+A key derivation function is useful when encrypting data based on a password
+or any other not-fully-random data. It uses a pseudorandom function to derive
+a secure encryption key based on the password.
+
+While v2.0 of the standard defines only one pseudorandom function to use,
+HMAC-SHA1, the drafted v2.1 specification allows use of all five FIPS Approved
+Hash Functions SHA-1, SHA-224, SHA-256, SHA-384 and SHA-512 for HMAC. To
+choose, you can pass the `New` functions from the different SHA packages to
+pbkdf2.Key.
+*/
+package pbkdf2
+
+import (
+ "crypto/hmac"
+ "hash"
+)
+
+// Key derives a key from the password, salt and iteration count, returning a
+// []byte of length keylen that can be used as cryptographic key. The key is
+// derived based on the method described as PBKDF2 with the HMAC variant using
+// the supplied hash function.
+//
+// For example, to use a HMAC-SHA-1 based PBKDF2 key derivation function, you
+// can get a derived key for e.g. AES-256 (which needs a 32-byte key) by
+// doing:
+//
+// dk := pbkdf2.Key([]byte("some password"), salt, 4096, 32, sha1.New)
+//
+// Remember to get a good random salt. At least 8 bytes is recommended by the
+// RFC.
+//
+// Using a higher iteration count will increase the cost of an exhaustive
+// search but will also make derivation proportionally slower.
+func Key(password, salt []byte, iter, keyLen int, h func() hash.Hash) []byte {
+ prf := hmac.New(h, password)
+ hashLen := prf.Size()
+ numBlocks := (keyLen + hashLen - 1) / hashLen
+
+ var buf [4]byte
+ dk := make([]byte, 0, numBlocks*hashLen)
+ U := make([]byte, hashLen)
+ for block := 1; block <= numBlocks; block++ {
+ // N.B.: || means concatenation, ^ means XOR
+ // for each block T_i = U_1 ^ U_2 ^ ... ^ U_iter
+ // U_1 = PRF(password, salt || uint(i))
+ prf.Reset()
+ prf.Write(salt)
+ buf[0] = byte(block >> 24)
+ buf[1] = byte(block >> 16)
+ buf[2] = byte(block >> 8)
+ buf[3] = byte(block)
+ prf.Write(buf[:4])
+ dk = prf.Sum(dk)
+ T := dk[len(dk)-hashLen:]
+ copy(U, T)
+
+ // U_n = PRF(password, U_(n-1))
+ for n := 2; n <= iter; n++ {
+ prf.Reset()
+ prf.Write(U)
+ U = U[:0]
+ U = prf.Sum(U)
+ for x := range U {
+ T[x] ^= U[x]
+ }
+ }
+ }
+ return dk[:keyLen]
+}
diff --git a/Godeps/_workspace/src/golang.org/x/crypto/pbkdf2/pbkdf2_test.go b/Godeps/_workspace/src/golang.org/x/crypto/pbkdf2/pbkdf2_test.go
new file mode 100644
index 000000000..137924061
--- /dev/null
+++ b/Godeps/_workspace/src/golang.org/x/crypto/pbkdf2/pbkdf2_test.go
@@ -0,0 +1,157 @@
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+package pbkdf2
+
+import (
+ "bytes"
+ "crypto/sha1"
+ "crypto/sha256"
+ "hash"
+ "testing"
+)
+
+type testVector struct {
+ password string
+ salt string
+ iter int
+ output []byte
+}
+
+// Test vectors from RFC 6070, http://tools.ietf.org/html/rfc6070
+var sha1TestVectors = []testVector{
+ {
+ "password",
+ "salt",
+ 1,
+ []byte{
+ 0x0c, 0x60, 0xc8, 0x0f, 0x96, 0x1f, 0x0e, 0x71,
+ 0xf3, 0xa9, 0xb5, 0x24, 0xaf, 0x60, 0x12, 0x06,
+ 0x2f, 0xe0, 0x37, 0xa6,
+ },
+ },
+ {
+ "password",
+ "salt",
+ 2,
+ []byte{
+ 0xea, 0x6c, 0x01, 0x4d, 0xc7, 0x2d, 0x6f, 0x8c,
+ 0xcd, 0x1e, 0xd9, 0x2a, 0xce, 0x1d, 0x41, 0xf0,
+ 0xd8, 0xde, 0x89, 0x57,
+ },
+ },
+ {
+ "password",
+ "salt",
+ 4096,
+ []byte{
+ 0x4b, 0x00, 0x79, 0x01, 0xb7, 0x65, 0x48, 0x9a,
+ 0xbe, 0xad, 0x49, 0xd9, 0x26, 0xf7, 0x21, 0xd0,
+ 0x65, 0xa4, 0x29, 0xc1,
+ },
+ },
+ // // This one takes too long
+ // {
+ // "password",
+ // "salt",
+ // 16777216,
+ // []byte{
+ // 0xee, 0xfe, 0x3d, 0x61, 0xcd, 0x4d, 0xa4, 0xe4,
+ // 0xe9, 0x94, 0x5b, 0x3d, 0x6b, 0xa2, 0x15, 0x8c,
+ // 0x26, 0x34, 0xe9, 0x84,
+ // },
+ // },
+ {
+ "passwordPASSWORDpassword",
+ "saltSALTsaltSALTsaltSALTsaltSALTsalt",
+ 4096,
+ []byte{
+ 0x3d, 0x2e, 0xec, 0x4f, 0xe4, 0x1c, 0x84, 0x9b,
+ 0x80, 0xc8, 0xd8, 0x36, 0x62, 0xc0, 0xe4, 0x4a,
+ 0x8b, 0x29, 0x1a, 0x96, 0x4c, 0xf2, 0xf0, 0x70,
+ 0x38,
+ },
+ },
+ {
+ "pass\000word",
+ "sa\000lt",
+ 4096,
+ []byte{
+ 0x56, 0xfa, 0x6a, 0xa7, 0x55, 0x48, 0x09, 0x9d,
+ 0xcc, 0x37, 0xd7, 0xf0, 0x34, 0x25, 0xe0, 0xc3,
+ },
+ },
+}
+
+// Test vectors from
+// http://stackoverflow.com/questions/5130513/pbkdf2-hmac-sha2-test-vectors
+var sha256TestVectors = []testVector{
+ {
+ "password",
+ "salt",
+ 1,
+ []byte{
+ 0x12, 0x0f, 0xb6, 0xcf, 0xfc, 0xf8, 0xb3, 0x2c,
+ 0x43, 0xe7, 0x22, 0x52, 0x56, 0xc4, 0xf8, 0x37,
+ 0xa8, 0x65, 0x48, 0xc9,
+ },
+ },
+ {
+ "password",
+ "salt",
+ 2,
+ []byte{
+ 0xae, 0x4d, 0x0c, 0x95, 0xaf, 0x6b, 0x46, 0xd3,
+ 0x2d, 0x0a, 0xdf, 0xf9, 0x28, 0xf0, 0x6d, 0xd0,
+ 0x2a, 0x30, 0x3f, 0x8e,
+ },
+ },
+ {
+ "password",
+ "salt",
+ 4096,
+ []byte{
+ 0xc5, 0xe4, 0x78, 0xd5, 0x92, 0x88, 0xc8, 0x41,
+ 0xaa, 0x53, 0x0d, 0xb6, 0x84, 0x5c, 0x4c, 0x8d,
+ 0x96, 0x28, 0x93, 0xa0,
+ },
+ },
+ {
+ "passwordPASSWORDpassword",
+ "saltSALTsaltSALTsaltSALTsaltSALTsalt",
+ 4096,
+ []byte{
+ 0x34, 0x8c, 0x89, 0xdb, 0xcb, 0xd3, 0x2b, 0x2f,
+ 0x32, 0xd8, 0x14, 0xb8, 0x11, 0x6e, 0x84, 0xcf,
+ 0x2b, 0x17, 0x34, 0x7e, 0xbc, 0x18, 0x00, 0x18,
+ 0x1c,
+ },
+ },
+ {
+ "pass\000word",
+ "sa\000lt",
+ 4096,
+ []byte{
+ 0x89, 0xb6, 0x9d, 0x05, 0x16, 0xf8, 0x29, 0x89,
+ 0x3c, 0x69, 0x62, 0x26, 0x65, 0x0a, 0x86, 0x87,
+ },
+ },
+}
+
+func testHash(t *testing.T, h func() hash.Hash, hashName string, vectors []testVector) {
+ for i, v := range vectors {
+ o := Key([]byte(v.password), []byte(v.salt), v.iter, len(v.output), h)
+ if !bytes.Equal(o, v.output) {
+ t.Errorf("%s %d: expected %x, got %x", hashName, i, v.output, o)
+ }
+ }
+}
+
+func TestWithHMACSHA1(t *testing.T) {
+ testHash(t, sha1.New, "SHA1", sha1TestVectors)
+}
+
+func TestWithHMACSHA256(t *testing.T) {
+ testHash(t, sha256.New, "SHA256", sha256TestVectors)
+}
diff --git a/Godeps/_workspace/src/golang.org/x/crypto/ripemd160/ripemd160.go b/Godeps/_workspace/src/golang.org/x/crypto/ripemd160/ripemd160.go
new file mode 100644
index 000000000..da690f0b9
--- /dev/null
+++ b/Godeps/_workspace/src/golang.org/x/crypto/ripemd160/ripemd160.go
@@ -0,0 +1,120 @@
+// Copyright 2010 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Package ripemd160 implements the RIPEMD-160 hash algorithm.
+package ripemd160
+
+// RIPEMD-160 is designed by by Hans Dobbertin, Antoon Bosselaers, and Bart
+// Preneel with specifications available at:
+// http://homes.esat.kuleuven.be/~cosicart/pdf/AB-9601/AB-9601.pdf.
+
+import (
+ "crypto"
+ "hash"
+)
+
+func init() {
+ crypto.RegisterHash(crypto.RIPEMD160, New)
+}
+
+// The size of the checksum in bytes.
+const Size = 20
+
+// The block size of the hash algorithm in bytes.
+const BlockSize = 64
+
+const (
+ _s0 = 0x67452301
+ _s1 = 0xefcdab89
+ _s2 = 0x98badcfe
+ _s3 = 0x10325476
+ _s4 = 0xc3d2e1f0
+)
+
+// digest represents the partial evaluation of a checksum.
+type digest struct {
+ s [5]uint32 // running context
+ x [BlockSize]byte // temporary buffer
+ nx int // index into x
+ tc uint64 // total count of bytes processed
+}
+
+func (d *digest) Reset() {
+ d.s[0], d.s[1], d.s[2], d.s[3], d.s[4] = _s0, _s1, _s2, _s3, _s4
+ d.nx = 0
+ d.tc = 0
+}
+
+// New returns a new hash.Hash computing the checksum.
+func New() hash.Hash {
+ result := new(digest)
+ result.Reset()
+ return result
+}
+
+func (d *digest) Size() int { return Size }
+
+func (d *digest) BlockSize() int { return BlockSize }
+
+func (d *digest) Write(p []byte) (nn int, err error) {
+ nn = len(p)
+ d.tc += uint64(nn)
+ if d.nx > 0 {
+ n := len(p)
+ if n > BlockSize-d.nx {
+ n = BlockSize - d.nx
+ }
+ for i := 0; i < n; i++ {
+ d.x[d.nx+i] = p[i]
+ }
+ d.nx += n
+ if d.nx == BlockSize {
+ _Block(d, d.x[0:])
+ d.nx = 0
+ }
+ p = p[n:]
+ }
+ n := _Block(d, p)
+ p = p[n:]
+ if len(p) > 0 {
+ d.nx = copy(d.x[:], p)
+ }
+ return
+}
+
+func (d0 *digest) Sum(in []byte) []byte {
+ // Make a copy of d0 so that caller can keep writing and summing.
+ d := *d0
+
+ // Padding. Add a 1 bit and 0 bits until 56 bytes mod 64.
+ tc := d.tc
+ var tmp [64]byte
+ tmp[0] = 0x80
+ if tc%64 < 56 {
+ d.Write(tmp[0 : 56-tc%64])
+ } else {
+ d.Write(tmp[0 : 64+56-tc%64])
+ }
+
+ // Length in bits.
+ tc <<= 3
+ for i := uint(0); i < 8; i++ {
+ tmp[i] = byte(tc >> (8 * i))
+ }
+ d.Write(tmp[0:8])
+
+ if d.nx != 0 {
+ panic("d.nx != 0")
+ }
+
+ var digest [Size]byte
+ for i, s := range d.s {
+ digest[i*4] = byte(s)
+ digest[i*4+1] = byte(s >> 8)
+ digest[i*4+2] = byte(s >> 16)
+ digest[i*4+3] = byte(s >> 24)
+ }
+
+ return append(in, digest[:]...)
+}
diff --git a/Godeps/_workspace/src/golang.org/x/crypto/ripemd160/ripemd160_test.go b/Godeps/_workspace/src/golang.org/x/crypto/ripemd160/ripemd160_test.go
new file mode 100644
index 000000000..5df1b2593
--- /dev/null
+++ b/Godeps/_workspace/src/golang.org/x/crypto/ripemd160/ripemd160_test.go
@@ -0,0 +1,64 @@
+// Copyright 2010 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+package ripemd160
+
+// Test vectors are from:
+// http://homes.esat.kuleuven.be/~bosselae/ripemd160.html
+
+import (
+ "fmt"
+ "io"
+ "testing"
+)
+
+type mdTest struct {
+ out string
+ in string
+}
+
+var vectors = [...]mdTest{
+ {"9c1185a5c5e9fc54612808977ee8f548b2258d31", ""},
+ {"0bdc9d2d256b3ee9daae347be6f4dc835a467ffe", "a"},
+ {"8eb208f7e05d987a9b044a8e98c6b087f15a0bfc", "abc"},
+ {"5d0689ef49d2fae572b881b123a85ffa21595f36", "message digest"},
+ {"f71c27109c692c1b56bbdceb5b9d2865b3708dbc", "abcdefghijklmnopqrstuvwxyz"},
+ {"12a053384a9c0c88e405a06c27dcf49ada62eb2b", "abcdbcdecdefdefgefghfghighijhijkijkljklmklmnlmnomnopnopq"},
+ {"b0e20b6e3116640286ed3a87a5713079b21f5189", "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789"},
+ {"9b752e45573d4b39f4dbd3323cab82bf63326bfb", "12345678901234567890123456789012345678901234567890123456789012345678901234567890"},
+}
+
+func TestVectors(t *testing.T) {
+ for i := 0; i < len(vectors); i++ {
+ tv := vectors[i]
+ md := New()
+ for j := 0; j < 3; j++ {
+ if j < 2 {
+ io.WriteString(md, tv.in)
+ } else {
+ io.WriteString(md, tv.in[0:len(tv.in)/2])
+ md.Sum(nil)
+ io.WriteString(md, tv.in[len(tv.in)/2:])
+ }
+ s := fmt.Sprintf("%x", md.Sum(nil))
+ if s != tv.out {
+ t.Fatalf("RIPEMD-160[%d](%s) = %s, expected %s", j, tv.in, s, tv.out)
+ }
+ md.Reset()
+ }
+ }
+}
+
+func TestMillionA(t *testing.T) {
+ md := New()
+ for i := 0; i < 100000; i++ {
+ io.WriteString(md, "aaaaaaaaaa")
+ }
+ out := "52783243c1697bdbe16d37f97f68f08325dc1528"
+ s := fmt.Sprintf("%x", md.Sum(nil))
+ if s != out {
+ t.Fatalf("RIPEMD-160 (1 million 'a') = %s, expected %s", s, out)
+ }
+ md.Reset()
+}
diff --git a/Godeps/_workspace/src/golang.org/x/crypto/ripemd160/ripemd160block.go b/Godeps/_workspace/src/golang.org/x/crypto/ripemd160/ripemd160block.go
new file mode 100644
index 000000000..7bc8e6c48
--- /dev/null
+++ b/Godeps/_workspace/src/golang.org/x/crypto/ripemd160/ripemd160block.go
@@ -0,0 +1,161 @@
+// Copyright 2010 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// RIPEMD-160 block step.
+// In its own file so that a faster assembly or C version
+// can be substituted easily.
+
+package ripemd160
+
+// work buffer indices and roll amounts for one line
+var _n = [80]uint{
+ 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15,
+ 7, 4, 13, 1, 10, 6, 15, 3, 12, 0, 9, 5, 2, 14, 11, 8,
+ 3, 10, 14, 4, 9, 15, 8, 1, 2, 7, 0, 6, 13, 11, 5, 12,
+ 1, 9, 11, 10, 0, 8, 12, 4, 13, 3, 7, 15, 14, 5, 6, 2,
+ 4, 0, 5, 9, 7, 12, 2, 10, 14, 1, 3, 8, 11, 6, 15, 13,
+}
+
+var _r = [80]uint{
+ 11, 14, 15, 12, 5, 8, 7, 9, 11, 13, 14, 15, 6, 7, 9, 8,
+ 7, 6, 8, 13, 11, 9, 7, 15, 7, 12, 15, 9, 11, 7, 13, 12,
+ 11, 13, 6, 7, 14, 9, 13, 15, 14, 8, 13, 6, 5, 12, 7, 5,
+ 11, 12, 14, 15, 14, 15, 9, 8, 9, 14, 5, 6, 8, 6, 5, 12,
+ 9, 15, 5, 11, 6, 8, 13, 12, 5, 12, 13, 14, 11, 8, 5, 6,
+}
+
+// same for the other parallel one
+var n_ = [80]uint{
+ 5, 14, 7, 0, 9, 2, 11, 4, 13, 6, 15, 8, 1, 10, 3, 12,
+ 6, 11, 3, 7, 0, 13, 5, 10, 14, 15, 8, 12, 4, 9, 1, 2,
+ 15, 5, 1, 3, 7, 14, 6, 9, 11, 8, 12, 2, 10, 0, 4, 13,
+ 8, 6, 4, 1, 3, 11, 15, 0, 5, 12, 2, 13, 9, 7, 10, 14,
+ 12, 15, 10, 4, 1, 5, 8, 7, 6, 2, 13, 14, 0, 3, 9, 11,
+}
+
+var r_ = [80]uint{
+ 8, 9, 9, 11, 13, 15, 15, 5, 7, 7, 8, 11, 14, 14, 12, 6,
+ 9, 13, 15, 7, 12, 8, 9, 11, 7, 7, 12, 7, 6, 15, 13, 11,
+ 9, 7, 15, 11, 8, 6, 6, 14, 12, 13, 5, 14, 13, 13, 7, 5,
+ 15, 5, 8, 11, 14, 14, 6, 14, 6, 9, 12, 9, 12, 5, 15, 8,
+ 8, 5, 12, 9, 12, 5, 14, 6, 8, 13, 6, 5, 15, 13, 11, 11,
+}
+
+func _Block(md *digest, p []byte) int {
+ n := 0
+ var x [16]uint32
+ var alpha, beta uint32
+ for len(p) >= BlockSize {
+ a, b, c, d, e := md.s[0], md.s[1], md.s[2], md.s[3], md.s[4]
+ aa, bb, cc, dd, ee := a, b, c, d, e
+ j := 0
+ for i := 0; i < 16; i++ {
+ x[i] = uint32(p[j]) | uint32(p[j+1])<<8 | uint32(p[j+2])<<16 | uint32(p[j+3])<<24
+ j += 4
+ }
+
+ // round 1
+ i := 0
+ for i < 16 {
+ alpha = a + (b ^ c ^ d) + x[_n[i]]
+ s := _r[i]
+ alpha = (alpha<<s | alpha>>(32-s)) + e
+ beta = c<<10 | c>>22
+ a, b, c, d, e = e, alpha, b, beta, d
+
+ // parallel line
+ alpha = aa + (bb ^ (cc | ^dd)) + x[n_[i]] + 0x50a28be6
+ s = r_[i]
+ alpha = (alpha<<s | alpha>>(32-s)) + ee
+ beta = cc<<10 | cc>>22
+ aa, bb, cc, dd, ee = ee, alpha, bb, beta, dd
+
+ i++
+ }
+
+ // round 2
+ for i < 32 {
+ alpha = a + (b&c | ^b&d) + x[_n[i]] + 0x5a827999
+ s := _r[i]
+ alpha = (alpha<<s | alpha>>(32-s)) + e
+ beta = c<<10 | c>>22
+ a, b, c, d, e = e, alpha, b, beta, d
+
+ // parallel line
+ alpha = aa + (bb&dd | cc&^dd) + x[n_[i]] + 0x5c4dd124
+ s = r_[i]
+ alpha = (alpha<<s | alpha>>(32-s)) + ee
+ beta = cc<<10 | cc>>22
+ aa, bb, cc, dd, ee = ee, alpha, bb, beta, dd
+
+ i++
+ }
+
+ // round 3
+ for i < 48 {
+ alpha = a + (b | ^c ^ d) + x[_n[i]] + 0x6ed9eba1
+ s := _r[i]
+ alpha = (alpha<<s | alpha>>(32-s)) + e
+ beta = c<<10 | c>>22
+ a, b, c, d, e = e, alpha, b, beta, d
+
+ // parallel line
+ alpha = aa + (bb | ^cc ^ dd) + x[n_[i]] + 0x6d703ef3
+ s = r_[i]
+ alpha = (alpha<<s | alpha>>(32-s)) + ee
+ beta = cc<<10 | cc>>22
+ aa, bb, cc, dd, ee = ee, alpha, bb, beta, dd
+
+ i++
+ }
+
+ // round 4
+ for i < 64 {
+ alpha = a + (b&d | c&^d) + x[_n[i]] + 0x8f1bbcdc
+ s := _r[i]
+ alpha = (alpha<<s | alpha>>(32-s)) + e
+ beta = c<<10 | c>>22
+ a, b, c, d, e = e, alpha, b, beta, d
+
+ // parallel line
+ alpha = aa + (bb&cc | ^bb&dd) + x[n_[i]] + 0x7a6d76e9
+ s = r_[i]
+ alpha = (alpha<<s | alpha>>(32-s)) + ee
+ beta = cc<<10 | cc>>22
+ aa, bb, cc, dd, ee = ee, alpha, bb, beta, dd
+
+ i++
+ }
+
+ // round 5
+ for i < 80 {
+ alpha = a + (b ^ (c | ^d)) + x[_n[i]] + 0xa953fd4e
+ s := _r[i]
+ alpha = (alpha<<s | alpha>>(32-s)) + e
+ beta = c<<10 | c>>22
+ a, b, c, d, e = e, alpha, b, beta, d
+
+ // parallel line
+ alpha = aa + (bb ^ cc ^ dd) + x[n_[i]]
+ s = r_[i]
+ alpha = (alpha<<s | alpha>>(32-s)) + ee
+ beta = cc<<10 | cc>>22
+ aa, bb, cc, dd, ee = ee, alpha, bb, beta, dd
+
+ i++
+ }
+
+ // combine results
+ dd += c + md.s[1]
+ md.s[1] = md.s[2] + d + ee
+ md.s[2] = md.s[3] + e + aa
+ md.s[3] = md.s[4] + a + bb
+ md.s[4] = md.s[0] + b + cc
+ md.s[0] = dd
+
+ p = p[BlockSize:]
+ n += BlockSize
+ }
+ return n
+}
diff --git a/Godeps/_workspace/src/golang.org/x/crypto/scrypt/scrypt.go b/Godeps/_workspace/src/golang.org/x/crypto/scrypt/scrypt.go
new file mode 100644
index 000000000..30737b0a6
--- /dev/null
+++ b/Godeps/_workspace/src/golang.org/x/crypto/scrypt/scrypt.go
@@ -0,0 +1,243 @@
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Package scrypt implements the scrypt key derivation function as defined in
+// Colin Percival's paper "Stronger Key Derivation via Sequential Memory-Hard
+// Functions" (http://www.tarsnap.com/scrypt/scrypt.pdf).
+package scrypt
+
+import (
+ "crypto/sha256"
+ "errors"
+
+ "golang.org/x/crypto/pbkdf2"
+)
+
+const maxInt = int(^uint(0) >> 1)
+
+// blockCopy copies n numbers from src into dst.
+func blockCopy(dst, src []uint32, n int) {
+ copy(dst, src[:n])
+}
+
+// blockXOR XORs numbers from dst with n numbers from src.
+func blockXOR(dst, src []uint32, n int) {
+ for i, v := range src[:n] {
+ dst[i] ^= v
+ }
+}
+
+// salsaXOR applies Salsa20/8 to the XOR of 16 numbers from tmp and in,
+// and puts the result into both both tmp and out.
+func salsaXOR(tmp *[16]uint32, in, out []uint32) {
+ w0 := tmp[0] ^ in[0]
+ w1 := tmp[1] ^ in[1]
+ w2 := tmp[2] ^ in[2]
+ w3 := tmp[3] ^ in[3]
+ w4 := tmp[4] ^ in[4]
+ w5 := tmp[5] ^ in[5]
+ w6 := tmp[6] ^ in[6]
+ w7 := tmp[7] ^ in[7]
+ w8 := tmp[8] ^ in[8]
+ w9 := tmp[9] ^ in[9]
+ w10 := tmp[10] ^ in[10]
+ w11 := tmp[11] ^ in[11]
+ w12 := tmp[12] ^ in[12]
+ w13 := tmp[13] ^ in[13]
+ w14 := tmp[14] ^ in[14]
+ w15 := tmp[15] ^ in[15]
+
+ x0, x1, x2, x3, x4, x5, x6, x7, x8 := w0, w1, w2, w3, w4, w5, w6, w7, w8
+ x9, x10, x11, x12, x13, x14, x15 := w9, w10, w11, w12, w13, w14, w15
+
+ for i := 0; i < 8; i += 2 {
+ u := x0 + x12
+ x4 ^= u<<7 | u>>(32-7)
+ u = x4 + x0
+ x8 ^= u<<9 | u>>(32-9)
+ u = x8 + x4
+ x12 ^= u<<13 | u>>(32-13)
+ u = x12 + x8
+ x0 ^= u<<18 | u>>(32-18)
+
+ u = x5 + x1
+ x9 ^= u<<7 | u>>(32-7)
+ u = x9 + x5
+ x13 ^= u<<9 | u>>(32-9)
+ u = x13 + x9
+ x1 ^= u<<13 | u>>(32-13)
+ u = x1 + x13
+ x5 ^= u<<18 | u>>(32-18)
+
+ u = x10 + x6
+ x14 ^= u<<7 | u>>(32-7)
+ u = x14 + x10
+ x2 ^= u<<9 | u>>(32-9)
+ u = x2 + x14
+ x6 ^= u<<13 | u>>(32-13)
+ u = x6 + x2
+ x10 ^= u<<18 | u>>(32-18)
+
+ u = x15 + x11
+ x3 ^= u<<7 | u>>(32-7)
+ u = x3 + x15
+ x7 ^= u<<9 | u>>(32-9)
+ u = x7 + x3
+ x11 ^= u<<13 | u>>(32-13)
+ u = x11 + x7
+ x15 ^= u<<18 | u>>(32-18)
+
+ u = x0 + x3
+ x1 ^= u<<7 | u>>(32-7)
+ u = x1 + x0
+ x2 ^= u<<9 | u>>(32-9)
+ u = x2 + x1
+ x3 ^= u<<13 | u>>(32-13)
+ u = x3 + x2
+ x0 ^= u<<18 | u>>(32-18)
+
+ u = x5 + x4
+ x6 ^= u<<7 | u>>(32-7)
+ u = x6 + x5
+ x7 ^= u<<9 | u>>(32-9)
+ u = x7 + x6
+ x4 ^= u<<13 | u>>(32-13)
+ u = x4 + x7
+ x5 ^= u<<18 | u>>(32-18)
+
+ u = x10 + x9
+ x11 ^= u<<7 | u>>(32-7)
+ u = x11 + x10
+ x8 ^= u<<9 | u>>(32-9)
+ u = x8 + x11
+ x9 ^= u<<13 | u>>(32-13)
+ u = x9 + x8
+ x10 ^= u<<18 | u>>(32-18)
+
+ u = x15 + x14
+ x12 ^= u<<7 | u>>(32-7)
+ u = x12 + x15
+ x13 ^= u<<9 | u>>(32-9)
+ u = x13 + x12
+ x14 ^= u<<13 | u>>(32-13)
+ u = x14 + x13
+ x15 ^= u<<18 | u>>(32-18)
+ }
+ x0 += w0
+ x1 += w1
+ x2 += w2
+ x3 += w3
+ x4 += w4
+ x5 += w5
+ x6 += w6
+ x7 += w7
+ x8 += w8
+ x9 += w9
+ x10 += w10
+ x11 += w11
+ x12 += w12
+ x13 += w13
+ x14 += w14
+ x15 += w15
+
+ out[0], tmp[0] = x0, x0
+ out[1], tmp[1] = x1, x1
+ out[2], tmp[2] = x2, x2
+ out[3], tmp[3] = x3, x3
+ out[4], tmp[4] = x4, x4
+ out[5], tmp[5] = x5, x5
+ out[6], tmp[6] = x6, x6
+ out[7], tmp[7] = x7, x7
+ out[8], tmp[8] = x8, x8
+ out[9], tmp[9] = x9, x9
+ out[10], tmp[10] = x10, x10
+ out[11], tmp[11] = x11, x11
+ out[12], tmp[12] = x12, x12
+ out[13], tmp[13] = x13, x13
+ out[14], tmp[14] = x14, x14
+ out[15], tmp[15] = x15, x15
+}
+
+func blockMix(tmp *[16]uint32, in, out []uint32, r int) {
+ blockCopy(tmp[:], in[(2*r-1)*16:], 16)
+ for i := 0; i < 2*r; i += 2 {
+ salsaXOR(tmp, in[i*16:], out[i*8:])
+ salsaXOR(tmp, in[i*16+16:], out[i*8+r*16:])
+ }
+}
+
+func integer(b []uint32, r int) uint64 {
+ j := (2*r - 1) * 16
+ return uint64(b[j]) | uint64(b[j+1])<<32
+}
+
+func smix(b []byte, r, N int, v, xy []uint32) {
+ var tmp [16]uint32
+ x := xy
+ y := xy[32*r:]
+
+ j := 0
+ for i := 0; i < 32*r; i++ {
+ x[i] = uint32(b[j]) | uint32(b[j+1])<<8 | uint32(b[j+2])<<16 | uint32(b[j+3])<<24
+ j += 4
+ }
+ for i := 0; i < N; i += 2 {
+ blockCopy(v[i*(32*r):], x, 32*r)
+ blockMix(&tmp, x, y, r)
+
+ blockCopy(v[(i+1)*(32*r):], y, 32*r)
+ blockMix(&tmp, y, x, r)
+ }
+ for i := 0; i < N; i += 2 {
+ j := int(integer(x, r) & uint64(N-1))
+ blockXOR(x, v[j*(32*r):], 32*r)
+ blockMix(&tmp, x, y, r)
+
+ j = int(integer(y, r) & uint64(N-1))
+ blockXOR(y, v[j*(32*r):], 32*r)
+ blockMix(&tmp, y, x, r)
+ }
+ j = 0
+ for _, v := range x[:32*r] {
+ b[j+0] = byte(v >> 0)
+ b[j+1] = byte(v >> 8)
+ b[j+2] = byte(v >> 16)
+ b[j+3] = byte(v >> 24)
+ j += 4
+ }
+}
+
+// Key derives a key from the password, salt, and cost parameters, returning
+// a byte slice of length keyLen that can be used as cryptographic key.
+//
+// N is a CPU/memory cost parameter, which must be a power of two greater than 1.
+// r and p must satisfy r * p < 2³⁰. If the parameters do not satisfy the
+// limits, the function returns a nil byte slice and an error.
+//
+// For example, you can get a derived key for e.g. AES-256 (which needs a
+// 32-byte key) by doing:
+//
+// dk := scrypt.Key([]byte("some password"), salt, 16384, 8, 1, 32)
+//
+// The recommended parameters for interactive logins as of 2009 are N=16384,
+// r=8, p=1. They should be increased as memory latency and CPU parallelism
+// increases. Remember to get a good random salt.
+func Key(password, salt []byte, N, r, p, keyLen int) ([]byte, error) {
+ if N <= 1 || N&(N-1) != 0 {
+ return nil, errors.New("scrypt: N must be > 1 and a power of 2")
+ }
+ if uint64(r)*uint64(p) >= 1<<30 || r > maxInt/128/p || r > maxInt/256 || N > maxInt/128/r {
+ return nil, errors.New("scrypt: parameters are too large")
+ }
+
+ xy := make([]uint32, 64*r)
+ v := make([]uint32, 32*N*r)
+ b := pbkdf2.Key(password, salt, 1, p*128*r, sha256.New)
+
+ for i := 0; i < p; i++ {
+ smix(b[i*128*r:], r, N, v, xy)
+ }
+
+ return pbkdf2.Key(password, b, 1, keyLen, sha256.New), nil
+}
diff --git a/Godeps/_workspace/src/golang.org/x/crypto/scrypt/scrypt_test.go b/Godeps/_workspace/src/golang.org/x/crypto/scrypt/scrypt_test.go
new file mode 100644
index 000000000..e096c3a31
--- /dev/null
+++ b/Godeps/_workspace/src/golang.org/x/crypto/scrypt/scrypt_test.go
@@ -0,0 +1,160 @@
+// Copyright 2012 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+package scrypt
+
+import (
+ "bytes"
+ "testing"
+)
+
+type testVector struct {
+ password string
+ salt string
+ N, r, p int
+ output []byte
+}
+
+var good = []testVector{
+ {
+ "password",
+ "salt",
+ 2, 10, 10,
+ []byte{
+ 0x48, 0x2c, 0x85, 0x8e, 0x22, 0x90, 0x55, 0xe6, 0x2f,
+ 0x41, 0xe0, 0xec, 0x81, 0x9a, 0x5e, 0xe1, 0x8b, 0xdb,
+ 0x87, 0x25, 0x1a, 0x53, 0x4f, 0x75, 0xac, 0xd9, 0x5a,
+ 0xc5, 0xe5, 0xa, 0xa1, 0x5f,
+ },
+ },
+ {
+ "password",
+ "salt",
+ 16, 100, 100,
+ []byte{
+ 0x88, 0xbd, 0x5e, 0xdb, 0x52, 0xd1, 0xdd, 0x0, 0x18,
+ 0x87, 0x72, 0xad, 0x36, 0x17, 0x12, 0x90, 0x22, 0x4e,
+ 0x74, 0x82, 0x95, 0x25, 0xb1, 0x8d, 0x73, 0x23, 0xa5,
+ 0x7f, 0x91, 0x96, 0x3c, 0x37,
+ },
+ },
+ {
+ "this is a long \000 password",
+ "and this is a long \000 salt",
+ 16384, 8, 1,
+ []byte{
+ 0xc3, 0xf1, 0x82, 0xee, 0x2d, 0xec, 0x84, 0x6e, 0x70,
+ 0xa6, 0x94, 0x2f, 0xb5, 0x29, 0x98, 0x5a, 0x3a, 0x09,
+ 0x76, 0x5e, 0xf0, 0x4c, 0x61, 0x29, 0x23, 0xb1, 0x7f,
+ 0x18, 0x55, 0x5a, 0x37, 0x07, 0x6d, 0xeb, 0x2b, 0x98,
+ 0x30, 0xd6, 0x9d, 0xe5, 0x49, 0x26, 0x51, 0xe4, 0x50,
+ 0x6a, 0xe5, 0x77, 0x6d, 0x96, 0xd4, 0x0f, 0x67, 0xaa,
+ 0xee, 0x37, 0xe1, 0x77, 0x7b, 0x8a, 0xd5, 0xc3, 0x11,
+ 0x14, 0x32, 0xbb, 0x3b, 0x6f, 0x7e, 0x12, 0x64, 0x40,
+ 0x18, 0x79, 0xe6, 0x41, 0xae,
+ },
+ },
+ {
+ "p",
+ "s",
+ 2, 1, 1,
+ []byte{
+ 0x48, 0xb0, 0xd2, 0xa8, 0xa3, 0x27, 0x26, 0x11, 0x98,
+ 0x4c, 0x50, 0xeb, 0xd6, 0x30, 0xaf, 0x52,
+ },
+ },
+
+ {
+ "",
+ "",
+ 16, 1, 1,
+ []byte{
+ 0x77, 0xd6, 0x57, 0x62, 0x38, 0x65, 0x7b, 0x20, 0x3b,
+ 0x19, 0xca, 0x42, 0xc1, 0x8a, 0x04, 0x97, 0xf1, 0x6b,
+ 0x48, 0x44, 0xe3, 0x07, 0x4a, 0xe8, 0xdf, 0xdf, 0xfa,
+ 0x3f, 0xed, 0xe2, 0x14, 0x42, 0xfc, 0xd0, 0x06, 0x9d,
+ 0xed, 0x09, 0x48, 0xf8, 0x32, 0x6a, 0x75, 0x3a, 0x0f,
+ 0xc8, 0x1f, 0x17, 0xe8, 0xd3, 0xe0, 0xfb, 0x2e, 0x0d,
+ 0x36, 0x28, 0xcf, 0x35, 0xe2, 0x0c, 0x38, 0xd1, 0x89,
+ 0x06,
+ },
+ },
+ {
+ "password",
+ "NaCl",
+ 1024, 8, 16,
+ []byte{
+ 0xfd, 0xba, 0xbe, 0x1c, 0x9d, 0x34, 0x72, 0x00, 0x78,
+ 0x56, 0xe7, 0x19, 0x0d, 0x01, 0xe9, 0xfe, 0x7c, 0x6a,
+ 0xd7, 0xcb, 0xc8, 0x23, 0x78, 0x30, 0xe7, 0x73, 0x76,
+ 0x63, 0x4b, 0x37, 0x31, 0x62, 0x2e, 0xaf, 0x30, 0xd9,
+ 0x2e, 0x22, 0xa3, 0x88, 0x6f, 0xf1, 0x09, 0x27, 0x9d,
+ 0x98, 0x30, 0xda, 0xc7, 0x27, 0xaf, 0xb9, 0x4a, 0x83,
+ 0xee, 0x6d, 0x83, 0x60, 0xcb, 0xdf, 0xa2, 0xcc, 0x06,
+ 0x40,
+ },
+ },
+ {
+ "pleaseletmein", "SodiumChloride",
+ 16384, 8, 1,
+ []byte{
+ 0x70, 0x23, 0xbd, 0xcb, 0x3a, 0xfd, 0x73, 0x48, 0x46,
+ 0x1c, 0x06, 0xcd, 0x81, 0xfd, 0x38, 0xeb, 0xfd, 0xa8,
+ 0xfb, 0xba, 0x90, 0x4f, 0x8e, 0x3e, 0xa9, 0xb5, 0x43,
+ 0xf6, 0x54, 0x5d, 0xa1, 0xf2, 0xd5, 0x43, 0x29, 0x55,
+ 0x61, 0x3f, 0x0f, 0xcf, 0x62, 0xd4, 0x97, 0x05, 0x24,
+ 0x2a, 0x9a, 0xf9, 0xe6, 0x1e, 0x85, 0xdc, 0x0d, 0x65,
+ 0x1e, 0x40, 0xdf, 0xcf, 0x01, 0x7b, 0x45, 0x57, 0x58,
+ 0x87,
+ },
+ },
+ /*
+ // Disabled: needs 1 GiB RAM and takes too long for a simple test.
+ {
+ "pleaseletmein", "SodiumChloride",
+ 1048576, 8, 1,
+ []byte{
+ 0x21, 0x01, 0xcb, 0x9b, 0x6a, 0x51, 0x1a, 0xae, 0xad,
+ 0xdb, 0xbe, 0x09, 0xcf, 0x70, 0xf8, 0x81, 0xec, 0x56,
+ 0x8d, 0x57, 0x4a, 0x2f, 0xfd, 0x4d, 0xab, 0xe5, 0xee,
+ 0x98, 0x20, 0xad, 0xaa, 0x47, 0x8e, 0x56, 0xfd, 0x8f,
+ 0x4b, 0xa5, 0xd0, 0x9f, 0xfa, 0x1c, 0x6d, 0x92, 0x7c,
+ 0x40, 0xf4, 0xc3, 0x37, 0x30, 0x40, 0x49, 0xe8, 0xa9,
+ 0x52, 0xfb, 0xcb, 0xf4, 0x5c, 0x6f, 0xa7, 0x7a, 0x41,
+ 0xa4,
+ },
+ },
+ */
+}
+
+var bad = []testVector{
+ {"p", "s", 0, 1, 1, nil}, // N == 0
+ {"p", "s", 1, 1, 1, nil}, // N == 1
+ {"p", "s", 7, 8, 1, nil}, // N is not power of 2
+ {"p", "s", 16, maxInt / 2, maxInt / 2, nil}, // p * r too large
+}
+
+func TestKey(t *testing.T) {
+ for i, v := range good {
+ k, err := Key([]byte(v.password), []byte(v.salt), v.N, v.r, v.p, len(v.output))
+ if err != nil {
+ t.Errorf("%d: got unexpected error: %s", i, err)
+ }
+ if !bytes.Equal(k, v.output) {
+ t.Errorf("%d: expected %x, got %x", i, v.output, k)
+ }
+ }
+ for i, v := range bad {
+ _, err := Key([]byte(v.password), []byte(v.salt), v.N, v.r, v.p, 32)
+ if err == nil {
+ t.Errorf("%d: expected error, got nil", i)
+ }
+ }
+}
+
+func BenchmarkKey(b *testing.B) {
+ for i := 0; i < b.N; i++ {
+ Key([]byte("password"), []byte("salt"), 16384, 8, 1, 64)
+ }
+}
diff --git a/Godeps/_workspace/src/gopkg.in/check.v1/.gitignore b/Godeps/_workspace/src/gopkg.in/check.v1/.gitignore
new file mode 100644
index 000000000..191a5360b
--- /dev/null
+++ b/Godeps/_workspace/src/gopkg.in/check.v1/.gitignore
@@ -0,0 +1,4 @@
+_*
+*.swp
+*.[568]
+[568].out
diff --git a/Godeps/_workspace/src/gopkg.in/check.v1/LICENSE b/Godeps/_workspace/src/gopkg.in/check.v1/LICENSE
new file mode 100644
index 000000000..545cf2d33
--- /dev/null
+++ b/Godeps/_workspace/src/gopkg.in/check.v1/LICENSE
@@ -0,0 +1,25 @@
+Gocheck - A rich testing framework for Go
+
+Copyright (c) 2010-2013 Gustavo Niemeyer <gustavo@niemeyer.net>
+
+All rights reserved.
+
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions are met:
+
+1. Redistributions of source code must retain the above copyright notice, this
+ list of conditions and the following disclaimer.
+2. Redistributions in binary form must reproduce the above copyright notice,
+ this list of conditions and the following disclaimer in the documentation
+ and/or other materials provided with the distribution.
+
+THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
+ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
+ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
+ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
diff --git a/Godeps/_workspace/src/gopkg.in/check.v1/README.md b/Godeps/_workspace/src/gopkg.in/check.v1/README.md
new file mode 100644
index 000000000..0ca9e5726
--- /dev/null
+++ b/Godeps/_workspace/src/gopkg.in/check.v1/README.md
@@ -0,0 +1,20 @@
+Instructions
+============
+
+Install the package with:
+
+ go get gopkg.in/check.v1
+
+Import it with:
+
+ import "gopkg.in/check.v1"
+
+and use _check_ as the package name inside the code.
+
+For more details, visit the project page:
+
+* http://labix.org/gocheck
+
+and the API documentation:
+
+* https://gopkg.in/check.v1
diff --git a/Godeps/_workspace/src/gopkg.in/check.v1/TODO b/Godeps/_workspace/src/gopkg.in/check.v1/TODO
new file mode 100644
index 000000000..33498270e
--- /dev/null
+++ b/Godeps/_workspace/src/gopkg.in/check.v1/TODO
@@ -0,0 +1,2 @@
+- Assert(slice, Contains, item)
+- Parallel test support
diff --git a/Godeps/_workspace/src/gopkg.in/check.v1/benchmark.go b/Godeps/_workspace/src/gopkg.in/check.v1/benchmark.go
new file mode 100644
index 000000000..48cb8c811
--- /dev/null
+++ b/Godeps/_workspace/src/gopkg.in/check.v1/benchmark.go
@@ -0,0 +1,163 @@
+// Copyright 2009 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+package check
+
+import (
+ "fmt"
+ "runtime"
+ "time"
+)
+
+var memStats runtime.MemStats
+
+// testingB is a type passed to Benchmark functions to manage benchmark
+// timing and to specify the number of iterations to run.
+type timer struct {
+ start time.Time // Time test or benchmark started
+ duration time.Duration
+ N int
+ bytes int64
+ timerOn bool
+ benchTime time.Duration
+ // The initial states of memStats.Mallocs and memStats.TotalAlloc.
+ startAllocs uint64
+ startBytes uint64
+ // The net total of this test after being run.
+ netAllocs uint64
+ netBytes uint64
+}
+
+// StartTimer starts timing a test. This function is called automatically
+// before a benchmark starts, but it can also used to resume timing after
+// a call to StopTimer.
+func (c *C) StartTimer() {
+ if !c.timerOn {
+ c.start = time.Now()
+ c.timerOn = true
+
+ runtime.ReadMemStats(&memStats)
+ c.startAllocs = memStats.Mallocs
+ c.startBytes = memStats.TotalAlloc
+ }
+}
+
+// StopTimer stops timing a test. This can be used to pause the timer
+// while performing complex initialization that you don't
+// want to measure.
+func (c *C) StopTimer() {
+ if c.timerOn {
+ c.duration += time.Now().Sub(c.start)
+ c.timerOn = false
+ runtime.ReadMemStats(&memStats)
+ c.netAllocs += memStats.Mallocs - c.startAllocs
+ c.netBytes += memStats.TotalAlloc - c.startBytes
+ }
+}
+
+// ResetTimer sets the elapsed benchmark time to zero.
+// It does not affect whether the timer is running.
+func (c *C) ResetTimer() {
+ if c.timerOn {
+ c.start = time.Now()
+ runtime.ReadMemStats(&memStats)
+ c.startAllocs = memStats.Mallocs
+ c.startBytes = memStats.TotalAlloc
+ }
+ c.duration = 0
+ c.netAllocs = 0
+ c.netBytes = 0
+}
+
+// SetBytes informs the number of bytes that the benchmark processes
+// on each iteration. If this is called in a benchmark it will also
+// report MB/s.
+func (c *C) SetBytes(n int64) {
+ c.bytes = n
+}
+
+func (c *C) nsPerOp() int64 {
+ if c.N <= 0 {
+ return 0
+ }
+ return c.duration.Nanoseconds() / int64(c.N)
+}
+
+func (c *C) mbPerSec() float64 {
+ if c.bytes <= 0 || c.duration <= 0 || c.N <= 0 {
+ return 0
+ }
+ return (float64(c.bytes) * float64(c.N) / 1e6) / c.duration.Seconds()
+}
+
+func (c *C) timerString() string {
+ if c.N <= 0 {
+ return fmt.Sprintf("%3.3fs", float64(c.duration.Nanoseconds())/1e9)
+ }
+ mbs := c.mbPerSec()
+ mb := ""
+ if mbs != 0 {
+ mb = fmt.Sprintf("\t%7.2f MB/s", mbs)
+ }
+ nsop := c.nsPerOp()
+ ns := fmt.Sprintf("%10d ns/op", nsop)
+ if c.N > 0 && nsop < 100 {
+ // The format specifiers here make sure that
+ // the ones digits line up for all three possible formats.
+ if nsop < 10 {
+ ns = fmt.Sprintf("%13.2f ns/op", float64(c.duration.Nanoseconds())/float64(c.N))
+ } else {
+ ns = fmt.Sprintf("%12.1f ns/op", float64(c.duration.Nanoseconds())/float64(c.N))
+ }
+ }
+ memStats := ""
+ if c.benchMem {
+ allocedBytes := fmt.Sprintf("%8d B/op", int64(c.netBytes)/int64(c.N))
+ allocs := fmt.Sprintf("%8d allocs/op", int64(c.netAllocs)/int64(c.N))
+ memStats = fmt.Sprintf("\t%s\t%s", allocedBytes, allocs)
+ }
+ return fmt.Sprintf("%8d\t%s%s%s", c.N, ns, mb, memStats)
+}
+
+func min(x, y int) int {
+ if x > y {
+ return y
+ }
+ return x
+}
+
+func max(x, y int) int {
+ if x < y {
+ return y
+ }
+ return x
+}
+
+// roundDown10 rounds a number down to the nearest power of 10.
+func roundDown10(n int) int {
+ var tens = 0
+ // tens = floor(log_10(n))
+ for n > 10 {
+ n = n / 10
+ tens++
+ }
+ // result = 10^tens
+ result := 1
+ for i := 0; i < tens; i++ {
+ result *= 10
+ }
+ return result
+}
+
+// roundUp rounds x up to a number of the form [1eX, 2eX, 5eX].
+func roundUp(n int) int {
+ base := roundDown10(n)
+ if n < (2 * base) {
+ return 2 * base
+ }
+ if n < (5 * base) {
+ return 5 * base
+ }
+ return 10 * base
+}
diff --git a/Godeps/_workspace/src/gopkg.in/check.v1/benchmark_test.go b/Godeps/_workspace/src/gopkg.in/check.v1/benchmark_test.go
new file mode 100644
index 000000000..4dd827c16
--- /dev/null
+++ b/Godeps/_workspace/src/gopkg.in/check.v1/benchmark_test.go
@@ -0,0 +1,91 @@
+// These tests verify the test running logic.
+
+package check_test
+
+import (
+ "time"
+ . "gopkg.in/check.v1"
+)
+
+var benchmarkS = Suite(&BenchmarkS{})
+
+type BenchmarkS struct{}
+
+func (s *BenchmarkS) TestCountSuite(c *C) {
+ suitesRun += 1
+}
+
+func (s *BenchmarkS) TestBasicTestTiming(c *C) {
+ helper := FixtureHelper{sleepOn: "Test1", sleep: 1000000 * time.Nanosecond}
+ output := String{}
+ runConf := RunConf{Output: &output, Verbose: true}
+ Run(&helper, &runConf)
+
+ expected := "PASS: check_test\\.go:[0-9]+: FixtureHelper\\.Test1\t0\\.001s\n" +
+ "PASS: check_test\\.go:[0-9]+: FixtureHelper\\.Test2\t0\\.000s\n"
+ c.Assert(output.value, Matches, expected)
+}
+
+func (s *BenchmarkS) TestStreamTestTiming(c *C) {
+ helper := FixtureHelper{sleepOn: "SetUpSuite", sleep: 1000000 * time.Nanosecond}
+ output := String{}
+ runConf := RunConf{Output: &output, Stream: true}
+ Run(&helper, &runConf)
+
+ expected := "(?s).*\nPASS: check_test\\.go:[0-9]+: FixtureHelper\\.SetUpSuite\t *0\\.001s\n.*"
+ c.Assert(output.value, Matches, expected)
+}
+
+func (s *BenchmarkS) TestBenchmark(c *C) {
+ helper := FixtureHelper{sleep: 100000}
+ output := String{}
+ runConf := RunConf{
+ Output: &output,
+ Benchmark: true,
+ BenchmarkTime: 10000000,
+ Filter: "Benchmark1",
+ }
+ Run(&helper, &runConf)
+ c.Check(helper.calls[0], Equals, "SetUpSuite")
+ c.Check(helper.calls[1], Equals, "SetUpTest")
+ c.Check(helper.calls[2], Equals, "Benchmark1")
+ c.Check(helper.calls[3], Equals, "TearDownTest")
+ c.Check(helper.calls[4], Equals, "SetUpTest")
+ c.Check(helper.calls[5], Equals, "Benchmark1")
+ c.Check(helper.calls[6], Equals, "TearDownTest")
+ // ... and more.
+
+ expected := "PASS: check_test\\.go:[0-9]+: FixtureHelper\\.Benchmark1\t *100\t *[12][0-9]{5} ns/op\n"
+ c.Assert(output.value, Matches, expected)
+}
+
+func (s *BenchmarkS) TestBenchmarkBytes(c *C) {
+ helper := FixtureHelper{sleep: 100000}
+ output := String{}
+ runConf := RunConf{
+ Output: &output,
+ Benchmark: true,
+ BenchmarkTime: 10000000,
+ Filter: "Benchmark2",
+ }
+ Run(&helper, &runConf)
+
+ expected := "PASS: check_test\\.go:[0-9]+: FixtureHelper\\.Benchmark2\t *100\t *[12][0-9]{5} ns/op\t *[4-9]\\.[0-9]{2} MB/s\n"
+ c.Assert(output.value, Matches, expected)
+}
+
+func (s *BenchmarkS) TestBenchmarkMem(c *C) {
+ helper := FixtureHelper{sleep: 100000}
+ output := String{}
+ runConf := RunConf{
+ Output: &output,
+ Benchmark: true,
+ BenchmarkMem: true,
+ BenchmarkTime: 10000000,
+ Filter: "Benchmark3",
+ }
+ Run(&helper, &runConf)
+
+ expected := "PASS: check_test\\.go:[0-9]+: FixtureHelper\\.Benchmark3\t *100\t *[12][0-9]{5} ns/op\t *[0-9]+ B/op\t *[1-9] allocs/op\n"
+ c.Assert(output.value, Matches, expected)
+}
diff --git a/Godeps/_workspace/src/gopkg.in/check.v1/bootstrap_test.go b/Godeps/_workspace/src/gopkg.in/check.v1/bootstrap_test.go
new file mode 100644
index 000000000..e55f327c7
--- /dev/null
+++ b/Godeps/_workspace/src/gopkg.in/check.v1/bootstrap_test.go
@@ -0,0 +1,82 @@
+// These initial tests are for bootstrapping. They verify that we can
+// basically use the testing infrastructure itself to check if the test
+// system is working.
+//
+// These tests use will break down the test runner badly in case of
+// errors because if they simply fail, we can't be sure the developer
+// will ever see anything (because failing means the failing system
+// somehow isn't working! :-)
+//
+// Do not assume *any* internal functionality works as expected besides
+// what's actually tested here.
+
+package check_test
+
+import (
+ "fmt"
+ "gopkg.in/check.v1"
+ "strings"
+)
+
+type BootstrapS struct{}
+
+var boostrapS = check.Suite(&BootstrapS{})
+
+func (s *BootstrapS) TestCountSuite(c *check.C) {
+ suitesRun += 1
+}
+
+func (s *BootstrapS) TestFailedAndFail(c *check.C) {
+ if c.Failed() {
+ critical("c.Failed() must be false first!")
+ }
+ c.Fail()
+ if !c.Failed() {
+ critical("c.Fail() didn't put the test in a failed state!")
+ }
+ c.Succeed()
+}
+
+func (s *BootstrapS) TestFailedAndSucceed(c *check.C) {
+ c.Fail()
+ c.Succeed()
+ if c.Failed() {
+ critical("c.Succeed() didn't put the test back in a non-failed state")
+ }
+}
+
+func (s *BootstrapS) TestLogAndGetTestLog(c *check.C) {
+ c.Log("Hello there!")
+ log := c.GetTestLog()
+ if log != "Hello there!\n" {
+ critical(fmt.Sprintf("Log() or GetTestLog() is not working! Got: %#v", log))
+ }
+}
+
+func (s *BootstrapS) TestLogfAndGetTestLog(c *check.C) {
+ c.Logf("Hello %v", "there!")
+ log := c.GetTestLog()
+ if log != "Hello there!\n" {
+ critical(fmt.Sprintf("Logf() or GetTestLog() is not working! Got: %#v", log))
+ }
+}
+
+func (s *BootstrapS) TestRunShowsErrors(c *check.C) {
+ output := String{}
+ check.Run(&FailHelper{}, &check.RunConf{Output: &output})
+ if strings.Index(output.value, "Expected failure!") == -1 {
+ critical(fmt.Sprintf("RunWithWriter() output did not contain the "+
+ "expected failure! Got: %#v",
+ output.value))
+ }
+}
+
+func (s *BootstrapS) TestRunDoesntShowSuccesses(c *check.C) {
+ output := String{}
+ check.Run(&SuccessHelper{}, &check.RunConf{Output: &output})
+ if strings.Index(output.value, "Expected success!") != -1 {
+ critical(fmt.Sprintf("RunWithWriter() output contained a successful "+
+ "test! Got: %#v",
+ output.value))
+ }
+}
diff --git a/Godeps/_workspace/src/gopkg.in/check.v1/check.go b/Godeps/_workspace/src/gopkg.in/check.v1/check.go
new file mode 100644
index 000000000..ca8c0f92d
--- /dev/null
+++ b/Godeps/_workspace/src/gopkg.in/check.v1/check.go
@@ -0,0 +1,945 @@
+// Package check is a rich testing extension for Go's testing package.
+//
+// For details about the project, see:
+//
+// http://labix.org/gocheck
+//
+package check
+
+import (
+ "bytes"
+ "errors"
+ "fmt"
+ "io"
+ "math/rand"
+ "os"
+ "path"
+ "path/filepath"
+ "reflect"
+ "regexp"
+ "runtime"
+ "strconv"
+ "strings"
+ "sync"
+ "time"
+)
+
+// -----------------------------------------------------------------------
+// Internal type which deals with suite method calling.
+
+const (
+ fixtureKd = iota
+ testKd
+)
+
+type funcKind int
+
+const (
+ succeededSt = iota
+ failedSt
+ skippedSt
+ panickedSt
+ fixturePanickedSt
+ missedSt
+)
+
+type funcStatus int
+
+// A method value can't reach its own Method structure.
+type methodType struct {
+ reflect.Value
+ Info reflect.Method
+}
+
+func newMethod(receiver reflect.Value, i int) *methodType {
+ return &methodType{receiver.Method(i), receiver.Type().Method(i)}
+}
+
+func (method *methodType) PC() uintptr {
+ return method.Info.Func.Pointer()
+}
+
+func (method *methodType) suiteName() string {
+ t := method.Info.Type.In(0)
+ if t.Kind() == reflect.Ptr {
+ t = t.Elem()
+ }
+ return t.Name()
+}
+
+func (method *methodType) String() string {
+ return method.suiteName() + "." + method.Info.Name
+}
+
+func (method *methodType) matches(re *regexp.Regexp) bool {
+ return (re.MatchString(method.Info.Name) ||
+ re.MatchString(method.suiteName()) ||
+ re.MatchString(method.String()))
+}
+
+type C struct {
+ method *methodType
+ kind funcKind
+ testName string
+ status funcStatus
+ logb *logger
+ logw io.Writer
+ done chan *C
+ reason string
+ mustFail bool
+ tempDir *tempDir
+ benchMem bool
+ startTime time.Time
+ timer
+}
+
+func (c *C) stopNow() {
+ runtime.Goexit()
+}
+
+// logger is a concurrency safe byte.Buffer
+type logger struct {
+ sync.Mutex
+ writer bytes.Buffer
+}
+
+func (l *logger) Write(buf []byte) (int, error) {
+ l.Lock()
+ defer l.Unlock()
+ return l.writer.Write(buf)
+}
+
+func (l *logger) WriteTo(w io.Writer) (int64, error) {
+ l.Lock()
+ defer l.Unlock()
+ return l.writer.WriteTo(w)
+}
+
+func (l *logger) String() string {
+ l.Lock()
+ defer l.Unlock()
+ return l.writer.String()
+}
+
+// -----------------------------------------------------------------------
+// Handling of temporary files and directories.
+
+type tempDir struct {
+ sync.Mutex
+ path string
+ counter int
+}
+
+func (td *tempDir) newPath() string {
+ td.Lock()
+ defer td.Unlock()
+ if td.path == "" {
+ var err error
+ for i := 0; i != 100; i++ {
+ path := fmt.Sprintf("%s%ccheck-%d", os.TempDir(), os.PathSeparator, rand.Int())
+ if err = os.Mkdir(path, 0700); err == nil {
+ td.path = path
+ break
+ }
+ }
+ if td.path == "" {
+ panic("Couldn't create temporary directory: " + err.Error())
+ }
+ }
+ result := filepath.Join(td.path, strconv.Itoa(td.counter))
+ td.counter += 1
+ return result
+}
+
+func (td *tempDir) removeAll() {
+ td.Lock()
+ defer td.Unlock()
+ if td.path != "" {
+ err := os.RemoveAll(td.path)
+ if err != nil {
+ fmt.Fprintf(os.Stderr, "WARNING: Error cleaning up temporaries: "+err.Error())
+ }
+ }
+}
+
+// Create a new temporary directory which is automatically removed after
+// the suite finishes running.
+func (c *C) MkDir() string {
+ path := c.tempDir.newPath()
+ if err := os.Mkdir(path, 0700); err != nil {
+ panic(fmt.Sprintf("Couldn't create temporary directory %s: %s", path, err.Error()))
+ }
+ return path
+}
+
+// -----------------------------------------------------------------------
+// Low-level logging functions.
+
+func (c *C) log(args ...interface{}) {
+ c.writeLog([]byte(fmt.Sprint(args...) + "\n"))
+}
+
+func (c *C) logf(format string, args ...interface{}) {
+ c.writeLog([]byte(fmt.Sprintf(format+"\n", args...)))
+}
+
+func (c *C) logNewLine() {
+ c.writeLog([]byte{'\n'})
+}
+
+func (c *C) writeLog(buf []byte) {
+ c.logb.Write(buf)
+ if c.logw != nil {
+ c.logw.Write(buf)
+ }
+}
+
+func hasStringOrError(x interface{}) (ok bool) {
+ _, ok = x.(fmt.Stringer)
+ if ok {
+ return
+ }
+ _, ok = x.(error)
+ return
+}
+
+func (c *C) logValue(label string, value interface{}) {
+ if label == "" {
+ if hasStringOrError(value) {
+ c.logf("... %#v (%q)", value, value)
+ } else {
+ c.logf("... %#v", value)
+ }
+ } else if value == nil {
+ c.logf("... %s = nil", label)
+ } else {
+ if hasStringOrError(value) {
+ fv := fmt.Sprintf("%#v", value)
+ qv := fmt.Sprintf("%q", value)
+ if fv != qv {
+ c.logf("... %s %s = %s (%s)", label, reflect.TypeOf(value), fv, qv)
+ return
+ }
+ }
+ if s, ok := value.(string); ok && isMultiLine(s) {
+ c.logf(`... %s %s = "" +`, label, reflect.TypeOf(value))
+ c.logMultiLine(s)
+ } else {
+ c.logf("... %s %s = %#v", label, reflect.TypeOf(value), value)
+ }
+ }
+}
+
+func (c *C) logMultiLine(s string) {
+ b := make([]byte, 0, len(s)*2)
+ i := 0
+ n := len(s)
+ for i < n {
+ j := i + 1
+ for j < n && s[j-1] != '\n' {
+ j++
+ }
+ b = append(b, "... "...)
+ b = strconv.AppendQuote(b, s[i:j])
+ if j < n {
+ b = append(b, " +"...)
+ }
+ b = append(b, '\n')
+ i = j
+ }
+ c.writeLog(b)
+}
+
+func isMultiLine(s string) bool {
+ for i := 0; i+1 < len(s); i++ {
+ if s[i] == '\n' {
+ return true
+ }
+ }
+ return false
+}
+
+func (c *C) logString(issue string) {
+ c.log("... ", issue)
+}
+
+func (c *C) logCaller(skip int) {
+ // This is a bit heavier than it ought to be.
+ skip += 1 // Our own frame.
+ pc, callerFile, callerLine, ok := runtime.Caller(skip)
+ if !ok {
+ return
+ }
+ var testFile string
+ var testLine int
+ testFunc := runtime.FuncForPC(c.method.PC())
+ if runtime.FuncForPC(pc) != testFunc {
+ for {
+ skip += 1
+ if pc, file, line, ok := runtime.Caller(skip); ok {
+ // Note that the test line may be different on
+ // distinct calls for the same test. Showing
+ // the "internal" line is helpful when debugging.
+ if runtime.FuncForPC(pc) == testFunc {
+ testFile, testLine = file, line
+ break
+ }
+ } else {
+ break
+ }
+ }
+ }
+ if testFile != "" && (testFile != callerFile || testLine != callerLine) {
+ c.logCode(testFile, testLine)
+ }
+ c.logCode(callerFile, callerLine)
+}
+
+func (c *C) logCode(path string, line int) {
+ c.logf("%s:%d:", nicePath(path), line)
+ code, err := printLine(path, line)
+ if code == "" {
+ code = "..." // XXX Open the file and take the raw line.
+ if err != nil {
+ code += err.Error()
+ }
+ }
+ c.log(indent(code, " "))
+}
+
+var valueGo = filepath.Join("reflect", "value.go")
+var asmGo = filepath.Join("runtime", "asm_")
+
+func (c *C) logPanic(skip int, value interface{}) {
+ skip++ // Our own frame.
+ initialSkip := skip
+ for ; ; skip++ {
+ if pc, file, line, ok := runtime.Caller(skip); ok {
+ if skip == initialSkip {
+ c.logf("... Panic: %s (PC=0x%X)\n", value, pc)
+ }
+ name := niceFuncName(pc)
+ path := nicePath(file)
+ if strings.Contains(path, "/gopkg.in/check.v") {
+ continue
+ }
+ if name == "Value.call" && strings.HasSuffix(path, valueGo) {
+ continue
+ }
+ if name == "call16" && strings.Contains(path, asmGo) {
+ continue
+ }
+ c.logf("%s:%d\n in %s", nicePath(file), line, name)
+ } else {
+ break
+ }
+ }
+}
+
+func (c *C) logSoftPanic(issue string) {
+ c.log("... Panic: ", issue)
+}
+
+func (c *C) logArgPanic(method *methodType, expectedType string) {
+ c.logf("... Panic: %s argument should be %s",
+ niceFuncName(method.PC()), expectedType)
+}
+
+// -----------------------------------------------------------------------
+// Some simple formatting helpers.
+
+var initWD, initWDErr = os.Getwd()
+
+func init() {
+ if initWDErr == nil {
+ initWD = strings.Replace(initWD, "\\", "/", -1) + "/"
+ }
+}
+
+func nicePath(path string) string {
+ if initWDErr == nil {
+ if strings.HasPrefix(path, initWD) {
+ return path[len(initWD):]
+ }
+ }
+ return path
+}
+
+func niceFuncPath(pc uintptr) string {
+ function := runtime.FuncForPC(pc)
+ if function != nil {
+ filename, line := function.FileLine(pc)
+ return fmt.Sprintf("%s:%d", nicePath(filename), line)
+ }
+ return "<unknown path>"
+}
+
+func niceFuncName(pc uintptr) string {
+ function := runtime.FuncForPC(pc)
+ if function != nil {
+ name := path.Base(function.Name())
+ if i := strings.Index(name, "."); i > 0 {
+ name = name[i+1:]
+ }
+ if strings.HasPrefix(name, "(*") {
+ if i := strings.Index(name, ")"); i > 0 {
+ name = name[2:i] + name[i+1:]
+ }
+ }
+ if i := strings.LastIndex(name, ".*"); i != -1 {
+ name = name[:i] + "." + name[i+2:]
+ }
+ if i := strings.LastIndex(name, "·"); i != -1 {
+ name = name[:i] + "." + name[i+2:]
+ }
+ return name
+ }
+ return "<unknown function>"
+}
+
+// -----------------------------------------------------------------------
+// Result tracker to aggregate call results.
+
+type Result struct {
+ Succeeded int
+ Failed int
+ Skipped int
+ Panicked int
+ FixturePanicked int
+ ExpectedFailures int
+ Missed int // Not even tried to run, related to a panic in the fixture.
+ RunError error // Houston, we've got a problem.
+ WorkDir string // If KeepWorkDir is true
+}
+
+type resultTracker struct {
+ result Result
+ _lastWasProblem bool
+ _waiting int
+ _missed int
+ _expectChan chan *C
+ _doneChan chan *C
+ _stopChan chan bool
+}
+
+func newResultTracker() *resultTracker {
+ return &resultTracker{_expectChan: make(chan *C), // Synchronous
+ _doneChan: make(chan *C, 32), // Asynchronous
+ _stopChan: make(chan bool)} // Synchronous
+}
+
+func (tracker *resultTracker) start() {
+ go tracker._loopRoutine()
+}
+
+func (tracker *resultTracker) waitAndStop() {
+ <-tracker._stopChan
+}
+
+func (tracker *resultTracker) expectCall(c *C) {
+ tracker._expectChan <- c
+}
+
+func (tracker *resultTracker) callDone(c *C) {
+ tracker._doneChan <- c
+}
+
+func (tracker *resultTracker) _loopRoutine() {
+ for {
+ var c *C
+ if tracker._waiting > 0 {
+ // Calls still running. Can't stop.
+ select {
+ // XXX Reindent this (not now to make diff clear)
+ case c = <-tracker._expectChan:
+ tracker._waiting += 1
+ case c = <-tracker._doneChan:
+ tracker._waiting -= 1
+ switch c.status {
+ case succeededSt:
+ if c.kind == testKd {
+ if c.mustFail {
+ tracker.result.ExpectedFailures++
+ } else {
+ tracker.result.Succeeded++
+ }
+ }
+ case failedSt:
+ tracker.result.Failed++
+ case panickedSt:
+ if c.kind == fixtureKd {
+ tracker.result.FixturePanicked++
+ } else {
+ tracker.result.Panicked++
+ }
+ case fixturePanickedSt:
+ // Track it as missed, since the panic
+ // was on the fixture, not on the test.
+ tracker.result.Missed++
+ case missedSt:
+ tracker.result.Missed++
+ case skippedSt:
+ if c.kind == testKd {
+ tracker.result.Skipped++
+ }
+ }
+ }
+ } else {
+ // No calls. Can stop, but no done calls here.
+ select {
+ case tracker._stopChan <- true:
+ return
+ case c = <-tracker._expectChan:
+ tracker._waiting += 1
+ case c = <-tracker._doneChan:
+ panic("Tracker got an unexpected done call.")
+ }
+ }
+ }
+}
+
+// -----------------------------------------------------------------------
+// The underlying suite runner.
+
+type suiteRunner struct {
+ suite interface{}
+ setUpSuite, tearDownSuite *methodType
+ setUpTest, tearDownTest *methodType
+ tests []*methodType
+ tracker *resultTracker
+ tempDir *tempDir
+ keepDir bool
+ output *outputWriter
+ reportedProblemLast bool
+ benchTime time.Duration
+ benchMem bool
+}
+
+type RunConf struct {
+ Output io.Writer
+ Stream bool
+ Verbose bool
+ Filter string
+ Benchmark bool
+ BenchmarkTime time.Duration // Defaults to 1 second
+ BenchmarkMem bool
+ KeepWorkDir bool
+}
+
+// Create a new suiteRunner able to run all methods in the given suite.
+func newSuiteRunner(suite interface{}, runConf *RunConf) *suiteRunner {
+ var conf RunConf
+ if runConf != nil {
+ conf = *runConf
+ }
+ if conf.Output == nil {
+ conf.Output = os.Stdout
+ }
+ if conf.Benchmark {
+ conf.Verbose = true
+ }
+
+ suiteType := reflect.TypeOf(suite)
+ suiteNumMethods := suiteType.NumMethod()
+ suiteValue := reflect.ValueOf(suite)
+
+ runner := &suiteRunner{
+ suite: suite,
+ output: newOutputWriter(conf.Output, conf.Stream, conf.Verbose),
+ tracker: newResultTracker(),
+ benchTime: conf.BenchmarkTime,
+ benchMem: conf.BenchmarkMem,
+ tempDir: &tempDir{},
+ keepDir: conf.KeepWorkDir,
+ tests: make([]*methodType, 0, suiteNumMethods),
+ }
+ if runner.benchTime == 0 {
+ runner.benchTime = 1 * time.Second
+ }
+
+ var filterRegexp *regexp.Regexp
+ if conf.Filter != "" {
+ if regexp, err := regexp.Compile(conf.Filter); err != nil {
+ msg := "Bad filter expression: " + err.Error()
+ runner.tracker.result.RunError = errors.New(msg)
+ return runner
+ } else {
+ filterRegexp = regexp
+ }
+ }
+
+ for i := 0; i != suiteNumMethods; i++ {
+ method := newMethod(suiteValue, i)
+ switch method.Info.Name {
+ case "SetUpSuite":
+ runner.setUpSuite = method
+ case "TearDownSuite":
+ runner.tearDownSuite = method
+ case "SetUpTest":
+ runner.setUpTest = method
+ case "TearDownTest":
+ runner.tearDownTest = method
+ default:
+ prefix := "Test"
+ if conf.Benchmark {
+ prefix = "Benchmark"
+ }
+ if !strings.HasPrefix(method.Info.Name, prefix) {
+ continue
+ }
+ if filterRegexp == nil || method.matches(filterRegexp) {
+ runner.tests = append(runner.tests, method)
+ }
+ }
+ }
+ return runner
+}
+
+// Run all methods in the given suite.
+func (runner *suiteRunner) run() *Result {
+ if runner.tracker.result.RunError == nil && len(runner.tests) > 0 {
+ runner.tracker.start()
+ if runner.checkFixtureArgs() {
+ c := runner.runFixture(runner.setUpSuite, "", nil)
+ if c == nil || c.status == succeededSt {
+ for i := 0; i != len(runner.tests); i++ {
+ c := runner.runTest(runner.tests[i])
+ if c.status == fixturePanickedSt {
+ runner.skipTests(missedSt, runner.tests[i+1:])
+ break
+ }
+ }
+ } else if c != nil && c.status == skippedSt {
+ runner.skipTests(skippedSt, runner.tests)
+ } else {
+ runner.skipTests(missedSt, runner.tests)
+ }
+ runner.runFixture(runner.tearDownSuite, "", nil)
+ } else {
+ runner.skipTests(missedSt, runner.tests)
+ }
+ runner.tracker.waitAndStop()
+ if runner.keepDir {
+ runner.tracker.result.WorkDir = runner.tempDir.path
+ } else {
+ runner.tempDir.removeAll()
+ }
+ }
+ return &runner.tracker.result
+}
+
+// Create a call object with the given suite method, and fork a
+// goroutine with the provided dispatcher for running it.
+func (runner *suiteRunner) forkCall(method *methodType, kind funcKind, testName string, logb *logger, dispatcher func(c *C)) *C {
+ var logw io.Writer
+ if runner.output.Stream {
+ logw = runner.output
+ }
+ if logb == nil {
+ logb = new(logger)
+ }
+ c := &C{
+ method: method,
+ kind: kind,
+ testName: testName,
+ logb: logb,
+ logw: logw,
+ tempDir: runner.tempDir,
+ done: make(chan *C, 1),
+ timer: timer{benchTime: runner.benchTime},
+ startTime: time.Now(),
+ benchMem: runner.benchMem,
+ }
+ runner.tracker.expectCall(c)
+ go (func() {
+ runner.reportCallStarted(c)
+ defer runner.callDone(c)
+ dispatcher(c)
+ })()
+ return c
+}
+
+// Same as forkCall(), but wait for call to finish before returning.
+func (runner *suiteRunner) runFunc(method *methodType, kind funcKind, testName string, logb *logger, dispatcher func(c *C)) *C {
+ c := runner.forkCall(method, kind, testName, logb, dispatcher)
+ <-c.done
+ return c
+}
+
+// Handle a finished call. If there were any panics, update the call status
+// accordingly. Then, mark the call as done and report to the tracker.
+func (runner *suiteRunner) callDone(c *C) {
+ value := recover()
+ if value != nil {
+ switch v := value.(type) {
+ case *fixturePanic:
+ if v.status == skippedSt {
+ c.status = skippedSt
+ } else {
+ c.logSoftPanic("Fixture has panicked (see related PANIC)")
+ c.status = fixturePanickedSt
+ }
+ default:
+ c.logPanic(1, value)
+ c.status = panickedSt
+ }
+ }
+ if c.mustFail {
+ switch c.status {
+ case failedSt:
+ c.status = succeededSt
+ case succeededSt:
+ c.status = failedSt
+ c.logString("Error: Test succeeded, but was expected to fail")
+ c.logString("Reason: " + c.reason)
+ }
+ }
+
+ runner.reportCallDone(c)
+ c.done <- c
+}
+
+// Runs a fixture call synchronously. The fixture will still be run in a
+// goroutine like all suite methods, but this method will not return
+// while the fixture goroutine is not done, because the fixture must be
+// run in a desired order.
+func (runner *suiteRunner) runFixture(method *methodType, testName string, logb *logger) *C {
+ if method != nil {
+ c := runner.runFunc(method, fixtureKd, testName, logb, func(c *C) {
+ c.ResetTimer()
+ c.StartTimer()
+ defer c.StopTimer()
+ c.method.Call([]reflect.Value{reflect.ValueOf(c)})
+ })
+ return c
+ }
+ return nil
+}
+
+// Run the fixture method with runFixture(), but panic with a fixturePanic{}
+// in case the fixture method panics. This makes it easier to track the
+// fixture panic together with other call panics within forkTest().
+func (runner *suiteRunner) runFixtureWithPanic(method *methodType, testName string, logb *logger, skipped *bool) *C {
+ if skipped != nil && *skipped {
+ return nil
+ }
+ c := runner.runFixture(method, testName, logb)
+ if c != nil && c.status != succeededSt {
+ if skipped != nil {
+ *skipped = c.status == skippedSt
+ }
+ panic(&fixturePanic{c.status, method})
+ }
+ return c
+}
+
+type fixturePanic struct {
+ status funcStatus
+ method *methodType
+}
+
+// Run the suite test method, together with the test-specific fixture,
+// asynchronously.
+func (runner *suiteRunner) forkTest(method *methodType) *C {
+ testName := method.String()
+ return runner.forkCall(method, testKd, testName, nil, func(c *C) {
+ var skipped bool
+ defer runner.runFixtureWithPanic(runner.tearDownTest, testName, nil, &skipped)
+ defer c.StopTimer()
+ benchN := 1
+ for {
+ runner.runFixtureWithPanic(runner.setUpTest, testName, c.logb, &skipped)
+ mt := c.method.Type()
+ if mt.NumIn() != 1 || mt.In(0) != reflect.TypeOf(c) {
+ // Rather than a plain panic, provide a more helpful message when
+ // the argument type is incorrect.
+ c.status = panickedSt
+ c.logArgPanic(c.method, "*check.C")
+ return
+ }
+ if strings.HasPrefix(c.method.Info.Name, "Test") {
+ c.ResetTimer()
+ c.StartTimer()
+ c.method.Call([]reflect.Value{reflect.ValueOf(c)})
+ return
+ }
+ if !strings.HasPrefix(c.method.Info.Name, "Benchmark") {
+ panic("unexpected method prefix: " + c.method.Info.Name)
+ }
+
+ runtime.GC()
+ c.N = benchN
+ c.ResetTimer()
+ c.StartTimer()
+ c.method.Call([]reflect.Value{reflect.ValueOf(c)})
+ c.StopTimer()
+ if c.status != succeededSt || c.duration >= c.benchTime || benchN >= 1e9 {
+ return
+ }
+ perOpN := int(1e9)
+ if c.nsPerOp() != 0 {
+ perOpN = int(c.benchTime.Nanoseconds() / c.nsPerOp())
+ }
+
+ // Logic taken from the stock testing package:
+ // - Run more iterations than we think we'll need for a second (1.5x).
+ // - Don't grow too fast in case we had timing errors previously.
+ // - Be sure to run at least one more than last time.
+ benchN = max(min(perOpN+perOpN/2, 100*benchN), benchN+1)
+ benchN = roundUp(benchN)
+
+ skipped = true // Don't run the deferred one if this panics.
+ runner.runFixtureWithPanic(runner.tearDownTest, testName, nil, nil)
+ skipped = false
+ }
+ })
+}
+
+// Same as forkTest(), but wait for the test to finish before returning.
+func (runner *suiteRunner) runTest(method *methodType) *C {
+ c := runner.forkTest(method)
+ <-c.done
+ return c
+}
+
+// Helper to mark tests as skipped or missed. A bit heavy for what
+// it does, but it enables homogeneous handling of tracking, including
+// nice verbose output.
+func (runner *suiteRunner) skipTests(status funcStatus, methods []*methodType) {
+ for _, method := range methods {
+ runner.runFunc(method, testKd, "", nil, func(c *C) {
+ c.status = status
+ })
+ }
+}
+
+// Verify if the fixture arguments are *check.C. In case of errors,
+// log the error as a panic in the fixture method call, and return false.
+func (runner *suiteRunner) checkFixtureArgs() bool {
+ succeeded := true
+ argType := reflect.TypeOf(&C{})
+ for _, method := range []*methodType{runner.setUpSuite, runner.tearDownSuite, runner.setUpTest, runner.tearDownTest} {
+ if method != nil {
+ mt := method.Type()
+ if mt.NumIn() != 1 || mt.In(0) != argType {
+ succeeded = false
+ runner.runFunc(method, fixtureKd, "", nil, func(c *C) {
+ c.logArgPanic(method, "*check.C")
+ c.status = panickedSt
+ })
+ }
+ }
+ }
+ return succeeded
+}
+
+func (runner *suiteRunner) reportCallStarted(c *C) {
+ runner.output.WriteCallStarted("START", c)
+}
+
+func (runner *suiteRunner) reportCallDone(c *C) {
+ runner.tracker.callDone(c)
+ switch c.status {
+ case succeededSt:
+ if c.mustFail {
+ runner.output.WriteCallSuccess("FAIL EXPECTED", c)
+ } else {
+ runner.output.WriteCallSuccess("PASS", c)
+ }
+ case skippedSt:
+ runner.output.WriteCallSuccess("SKIP", c)
+ case failedSt:
+ runner.output.WriteCallProblem("FAIL", c)
+ case panickedSt:
+ runner.output.WriteCallProblem("PANIC", c)
+ case fixturePanickedSt:
+ // That's a testKd call reporting that its fixture
+ // has panicked. The fixture call which caused the
+ // panic itself was tracked above. We'll report to
+ // aid debugging.
+ runner.output.WriteCallProblem("PANIC", c)
+ case missedSt:
+ runner.output.WriteCallSuccess("MISS", c)
+ }
+}
+
+// -----------------------------------------------------------------------
+// Output writer manages atomic output writing according to settings.
+
+type outputWriter struct {
+ m sync.Mutex
+ writer io.Writer
+ wroteCallProblemLast bool
+ Stream bool
+ Verbose bool
+}
+
+func newOutputWriter(writer io.Writer, stream, verbose bool) *outputWriter {
+ return &outputWriter{writer: writer, Stream: stream, Verbose: verbose}
+}
+
+func (ow *outputWriter) Write(content []byte) (n int, err error) {
+ ow.m.Lock()
+ n, err = ow.writer.Write(content)
+ ow.m.Unlock()
+ return
+}
+
+func (ow *outputWriter) WriteCallStarted(label string, c *C) {
+ if ow.Stream {
+ header := renderCallHeader(label, c, "", "\n")
+ ow.m.Lock()
+ ow.writer.Write([]byte(header))
+ ow.m.Unlock()
+ }
+}
+
+func (ow *outputWriter) WriteCallProblem(label string, c *C) {
+ var prefix string
+ if !ow.Stream {
+ prefix = "\n-----------------------------------" +
+ "-----------------------------------\n"
+ }
+ header := renderCallHeader(label, c, prefix, "\n\n")
+ ow.m.Lock()
+ ow.wroteCallProblemLast = true
+ ow.writer.Write([]byte(header))
+ if !ow.Stream {
+ c.logb.WriteTo(ow.writer)
+ }
+ ow.m.Unlock()
+}
+
+func (ow *outputWriter) WriteCallSuccess(label string, c *C) {
+ if ow.Stream || (ow.Verbose && c.kind == testKd) {
+ // TODO Use a buffer here.
+ var suffix string
+ if c.reason != "" {
+ suffix = " (" + c.reason + ")"
+ }
+ if c.status == succeededSt {
+ suffix += "\t" + c.timerString()
+ }
+ suffix += "\n"
+ if ow.Stream {
+ suffix += "\n"
+ }
+ header := renderCallHeader(label, c, "", suffix)
+ ow.m.Lock()
+ // Resist temptation of using line as prefix above due to race.
+ if !ow.Stream && ow.wroteCallProblemLast {
+ header = "\n-----------------------------------" +
+ "-----------------------------------\n" +
+ header
+ }
+ ow.wroteCallProblemLast = false
+ ow.writer.Write([]byte(header))
+ ow.m.Unlock()
+ }
+}
+
+func renderCallHeader(label string, c *C, prefix, suffix string) string {
+ pc := c.method.PC()
+ return fmt.Sprintf("%s%s: %s: %s%s", prefix, label, niceFuncPath(pc),
+ niceFuncName(pc), suffix)
+}
diff --git a/Godeps/_workspace/src/gopkg.in/check.v1/check_test.go b/Godeps/_workspace/src/gopkg.in/check.v1/check_test.go
new file mode 100644
index 000000000..871b32527
--- /dev/null
+++ b/Godeps/_workspace/src/gopkg.in/check.v1/check_test.go
@@ -0,0 +1,207 @@
+// This file contains just a few generic helpers which are used by the
+// other test files.
+
+package check_test
+
+import (
+ "flag"
+ "fmt"
+ "os"
+ "regexp"
+ "runtime"
+ "testing"
+ "time"
+
+ "gopkg.in/check.v1"
+)
+
+// We count the number of suites run at least to get a vague hint that the
+// test suite is behaving as it should. Otherwise a bug introduced at the
+// very core of the system could go unperceived.
+const suitesRunExpected = 8
+
+var suitesRun int = 0
+
+func Test(t *testing.T) {
+ check.TestingT(t)
+ if suitesRun != suitesRunExpected && flag.Lookup("check.f").Value.String() == "" {
+ critical(fmt.Sprintf("Expected %d suites to run rather than %d",
+ suitesRunExpected, suitesRun))
+ }
+}
+
+// -----------------------------------------------------------------------
+// Helper functions.
+
+// Break down badly. This is used in test cases which can't yet assume
+// that the fundamental bits are working.
+func critical(error string) {
+ fmt.Fprintln(os.Stderr, "CRITICAL: "+error)
+ os.Exit(1)
+}
+
+// Return the file line where it's called.
+func getMyLine() int {
+ if _, _, line, ok := runtime.Caller(1); ok {
+ return line
+ }
+ return -1
+}
+
+// -----------------------------------------------------------------------
+// Helper type implementing a basic io.Writer for testing output.
+
+// Type implementing the io.Writer interface for analyzing output.
+type String struct {
+ value string
+}
+
+// The only function required by the io.Writer interface. Will append
+// written data to the String.value string.
+func (s *String) Write(p []byte) (n int, err error) {
+ s.value += string(p)
+ return len(p), nil
+}
+
+// Trivial wrapper to test errors happening on a different file
+// than the test itself.
+func checkEqualWrapper(c *check.C, obtained, expected interface{}) (result bool, line int) {
+ return c.Check(obtained, check.Equals, expected), getMyLine()
+}
+
+// -----------------------------------------------------------------------
+// Helper suite for testing basic fail behavior.
+
+type FailHelper struct {
+ testLine int
+}
+
+func (s *FailHelper) TestLogAndFail(c *check.C) {
+ s.testLine = getMyLine() - 1
+ c.Log("Expected failure!")
+ c.Fail()
+}
+
+// -----------------------------------------------------------------------
+// Helper suite for testing basic success behavior.
+
+type SuccessHelper struct{}
+
+func (s *SuccessHelper) TestLogAndSucceed(c *check.C) {
+ c.Log("Expected success!")
+}
+
+// -----------------------------------------------------------------------
+// Helper suite for testing ordering and behavior of fixture.
+
+type FixtureHelper struct {
+ calls []string
+ panicOn string
+ skip bool
+ skipOnN int
+ sleepOn string
+ sleep time.Duration
+ bytes int64
+}
+
+func (s *FixtureHelper) trace(name string, c *check.C) {
+ s.calls = append(s.calls, name)
+ if name == s.panicOn {
+ panic(name)
+ }
+ if s.sleep > 0 && s.sleepOn == name {
+ time.Sleep(s.sleep)
+ }
+ if s.skip && s.skipOnN == len(s.calls)-1 {
+ c.Skip("skipOnN == n")
+ }
+}
+
+func (s *FixtureHelper) SetUpSuite(c *check.C) {
+ s.trace("SetUpSuite", c)
+}
+
+func (s *FixtureHelper) TearDownSuite(c *check.C) {
+ s.trace("TearDownSuite", c)
+}
+
+func (s *FixtureHelper) SetUpTest(c *check.C) {
+ s.trace("SetUpTest", c)
+}
+
+func (s *FixtureHelper) TearDownTest(c *check.C) {
+ s.trace("TearDownTest", c)
+}
+
+func (s *FixtureHelper) Test1(c *check.C) {
+ s.trace("Test1", c)
+}
+
+func (s *FixtureHelper) Test2(c *check.C) {
+ s.trace("Test2", c)
+}
+
+func (s *FixtureHelper) Benchmark1(c *check.C) {
+ s.trace("Benchmark1", c)
+ for i := 0; i < c.N; i++ {
+ time.Sleep(s.sleep)
+ }
+}
+
+func (s *FixtureHelper) Benchmark2(c *check.C) {
+ s.trace("Benchmark2", c)
+ c.SetBytes(1024)
+ for i := 0; i < c.N; i++ {
+ time.Sleep(s.sleep)
+ }
+}
+
+func (s *FixtureHelper) Benchmark3(c *check.C) {
+ var x []int64
+ s.trace("Benchmark3", c)
+ for i := 0; i < c.N; i++ {
+ time.Sleep(s.sleep)
+ x = make([]int64, 5)
+ _ = x
+ }
+}
+
+// -----------------------------------------------------------------------
+// Helper which checks the state of the test and ensures that it matches
+// the given expectations. Depends on c.Errorf() working, so shouldn't
+// be used to test this one function.
+
+type expectedState struct {
+ name string
+ result interface{}
+ failed bool
+ log string
+}
+
+// Verify the state of the test. Note that since this also verifies if
+// the test is supposed to be in a failed state, no other checks should
+// be done in addition to what is being tested.
+func checkState(c *check.C, result interface{}, expected *expectedState) {
+ failed := c.Failed()
+ c.Succeed()
+ log := c.GetTestLog()
+ matched, matchError := regexp.MatchString("^"+expected.log+"$", log)
+ if matchError != nil {
+ c.Errorf("Error in matching expression used in testing %s",
+ expected.name)
+ } else if !matched {
+ c.Errorf("%s logged:\n----------\n%s----------\n\nExpected:\n----------\n%s\n----------",
+ expected.name, log, expected.log)
+ }
+ if result != expected.result {
+ c.Errorf("%s returned %#v rather than %#v",
+ expected.name, result, expected.result)
+ }
+ if failed != expected.failed {
+ if failed {
+ c.Errorf("%s has failed when it shouldn't", expected.name)
+ } else {
+ c.Errorf("%s has not failed when it should", expected.name)
+ }
+ }
+}
diff --git a/Godeps/_workspace/src/gopkg.in/check.v1/checkers.go b/Godeps/_workspace/src/gopkg.in/check.v1/checkers.go
new file mode 100644
index 000000000..bac338729
--- /dev/null
+++ b/Godeps/_workspace/src/gopkg.in/check.v1/checkers.go
@@ -0,0 +1,458 @@
+package check
+
+import (
+ "fmt"
+ "reflect"
+ "regexp"
+)
+
+// -----------------------------------------------------------------------
+// CommentInterface and Commentf helper, to attach extra information to checks.
+
+type comment struct {
+ format string
+ args []interface{}
+}
+
+// Commentf returns an infomational value to use with Assert or Check calls.
+// If the checker test fails, the provided arguments will be passed to
+// fmt.Sprintf, and will be presented next to the logged failure.
+//
+// For example:
+//
+// c.Assert(v, Equals, 42, Commentf("Iteration #%d failed.", i))
+//
+// Note that if the comment is constant, a better option is to
+// simply use a normal comment right above or next to the line, as
+// it will also get printed with any errors:
+//
+// c.Assert(l, Equals, 8192) // Ensure buffer size is correct (bug #123)
+//
+func Commentf(format string, args ...interface{}) CommentInterface {
+ return &comment{format, args}
+}
+
+// CommentInterface must be implemented by types that attach extra
+// information to failed checks. See the Commentf function for details.
+type CommentInterface interface {
+ CheckCommentString() string
+}
+
+func (c *comment) CheckCommentString() string {
+ return fmt.Sprintf(c.format, c.args...)
+}
+
+// -----------------------------------------------------------------------
+// The Checker interface.
+
+// The Checker interface must be provided by checkers used with
+// the Assert and Check verification methods.
+type Checker interface {
+ Info() *CheckerInfo
+ Check(params []interface{}, names []string) (result bool, error string)
+}
+
+// See the Checker interface.
+type CheckerInfo struct {
+ Name string
+ Params []string
+}
+
+func (info *CheckerInfo) Info() *CheckerInfo {
+ return info
+}
+
+// -----------------------------------------------------------------------
+// Not checker logic inverter.
+
+// The Not checker inverts the logic of the provided checker. The
+// resulting checker will succeed where the original one failed, and
+// vice-versa.
+//
+// For example:
+//
+// c.Assert(a, Not(Equals), b)
+//
+func Not(checker Checker) Checker {
+ return &notChecker{checker}
+}
+
+type notChecker struct {
+ sub Checker
+}
+
+func (checker *notChecker) Info() *CheckerInfo {
+ info := *checker.sub.Info()
+ info.Name = "Not(" + info.Name + ")"
+ return &info
+}
+
+func (checker *notChecker) Check(params []interface{}, names []string) (result bool, error string) {
+ result, error = checker.sub.Check(params, names)
+ result = !result
+ return
+}
+
+// -----------------------------------------------------------------------
+// IsNil checker.
+
+type isNilChecker struct {
+ *CheckerInfo
+}
+
+// The IsNil checker tests whether the obtained value is nil.
+//
+// For example:
+//
+// c.Assert(err, IsNil)
+//
+var IsNil Checker = &isNilChecker{
+ &CheckerInfo{Name: "IsNil", Params: []string{"value"}},
+}
+
+func (checker *isNilChecker) Check(params []interface{}, names []string) (result bool, error string) {
+ return isNil(params[0]), ""
+}
+
+func isNil(obtained interface{}) (result bool) {
+ if obtained == nil {
+ result = true
+ } else {
+ switch v := reflect.ValueOf(obtained); v.Kind() {
+ case reflect.Chan, reflect.Func, reflect.Interface, reflect.Map, reflect.Ptr, reflect.Slice:
+ return v.IsNil()
+ }
+ }
+ return
+}
+
+// -----------------------------------------------------------------------
+// NotNil checker. Alias for Not(IsNil), since it's so common.
+
+type notNilChecker struct {
+ *CheckerInfo
+}
+
+// The NotNil checker verifies that the obtained value is not nil.
+//
+// For example:
+//
+// c.Assert(iface, NotNil)
+//
+// This is an alias for Not(IsNil), made available since it's a
+// fairly common check.
+//
+var NotNil Checker = &notNilChecker{
+ &CheckerInfo{Name: "NotNil", Params: []string{"value"}},
+}
+
+func (checker *notNilChecker) Check(params []interface{}, names []string) (result bool, error string) {
+ return !isNil(params[0]), ""
+}
+
+// -----------------------------------------------------------------------
+// Equals checker.
+
+type equalsChecker struct {
+ *CheckerInfo
+}
+
+// The Equals checker verifies that the obtained value is equal to
+// the expected value, according to usual Go semantics for ==.
+//
+// For example:
+//
+// c.Assert(value, Equals, 42)
+//
+var Equals Checker = &equalsChecker{
+ &CheckerInfo{Name: "Equals", Params: []string{"obtained", "expected"}},
+}
+
+func (checker *equalsChecker) Check(params []interface{}, names []string) (result bool, error string) {
+ defer func() {
+ if v := recover(); v != nil {
+ result = false
+ error = fmt.Sprint(v)
+ }
+ }()
+ return params[0] == params[1], ""
+}
+
+// -----------------------------------------------------------------------
+// DeepEquals checker.
+
+type deepEqualsChecker struct {
+ *CheckerInfo
+}
+
+// The DeepEquals checker verifies that the obtained value is deep-equal to
+// the expected value. The check will work correctly even when facing
+// slices, interfaces, and values of different types (which always fail
+// the test).
+//
+// For example:
+//
+// c.Assert(value, DeepEquals, 42)
+// c.Assert(array, DeepEquals, []string{"hi", "there"})
+//
+var DeepEquals Checker = &deepEqualsChecker{
+ &CheckerInfo{Name: "DeepEquals", Params: []string{"obtained", "expected"}},
+}
+
+func (checker *deepEqualsChecker) Check(params []interface{}, names []string) (result bool, error string) {
+ return reflect.DeepEqual(params[0], params[1]), ""
+}
+
+// -----------------------------------------------------------------------
+// HasLen checker.
+
+type hasLenChecker struct {
+ *CheckerInfo
+}
+
+// The HasLen checker verifies that the obtained value has the
+// provided length. In many cases this is superior to using Equals
+// in conjuction with the len function because in case the check
+// fails the value itself will be printed, instead of its length,
+// providing more details for figuring the problem.
+//
+// For example:
+//
+// c.Assert(list, HasLen, 5)
+//
+var HasLen Checker = &hasLenChecker{
+ &CheckerInfo{Name: "HasLen", Params: []string{"obtained", "n"}},
+}
+
+func (checker *hasLenChecker) Check(params []interface{}, names []string) (result bool, error string) {
+ n, ok := params[1].(int)
+ if !ok {
+ return false, "n must be an int"
+ }
+ value := reflect.ValueOf(params[0])
+ switch value.Kind() {
+ case reflect.Map, reflect.Array, reflect.Slice, reflect.Chan, reflect.String:
+ default:
+ return false, "obtained value type has no length"
+ }
+ return value.Len() == n, ""
+}
+
+// -----------------------------------------------------------------------
+// ErrorMatches checker.
+
+type errorMatchesChecker struct {
+ *CheckerInfo
+}
+
+// The ErrorMatches checker verifies that the error value
+// is non nil and matches the regular expression provided.
+//
+// For example:
+//
+// c.Assert(err, ErrorMatches, "perm.*denied")
+//
+var ErrorMatches Checker = errorMatchesChecker{
+ &CheckerInfo{Name: "ErrorMatches", Params: []string{"value", "regex"}},
+}
+
+func (checker errorMatchesChecker) Check(params []interface{}, names []string) (result bool, errStr string) {
+ if params[0] == nil {
+ return false, "Error value is nil"
+ }
+ err, ok := params[0].(error)
+ if !ok {
+ return false, "Value is not an error"
+ }
+ params[0] = err.Error()
+ names[0] = "error"
+ return matches(params[0], params[1])
+}
+
+// -----------------------------------------------------------------------
+// Matches checker.
+
+type matchesChecker struct {
+ *CheckerInfo
+}
+
+// The Matches checker verifies that the string provided as the obtained
+// value (or the string resulting from obtained.String()) matches the
+// regular expression provided.
+//
+// For example:
+//
+// c.Assert(err, Matches, "perm.*denied")
+//
+var Matches Checker = &matchesChecker{
+ &CheckerInfo{Name: "Matches", Params: []string{"value", "regex"}},
+}
+
+func (checker *matchesChecker) Check(params []interface{}, names []string) (result bool, error string) {
+ return matches(params[0], params[1])
+}
+
+func matches(value, regex interface{}) (result bool, error string) {
+ reStr, ok := regex.(string)
+ if !ok {
+ return false, "Regex must be a string"
+ }
+ valueStr, valueIsStr := value.(string)
+ if !valueIsStr {
+ if valueWithStr, valueHasStr := value.(fmt.Stringer); valueHasStr {
+ valueStr, valueIsStr = valueWithStr.String(), true
+ }
+ }
+ if valueIsStr {
+ matches, err := regexp.MatchString("^"+reStr+"$", valueStr)
+ if err != nil {
+ return false, "Can't compile regex: " + err.Error()
+ }
+ return matches, ""
+ }
+ return false, "Obtained value is not a string and has no .String()"
+}
+
+// -----------------------------------------------------------------------
+// Panics checker.
+
+type panicsChecker struct {
+ *CheckerInfo
+}
+
+// The Panics checker verifies that calling the provided zero-argument
+// function will cause a panic which is deep-equal to the provided value.
+//
+// For example:
+//
+// c.Assert(func() { f(1, 2) }, Panics, &SomeErrorType{"BOOM"}).
+//
+//
+var Panics Checker = &panicsChecker{
+ &CheckerInfo{Name: "Panics", Params: []string{"function", "expected"}},
+}
+
+func (checker *panicsChecker) Check(params []interface{}, names []string) (result bool, error string) {
+ f := reflect.ValueOf(params[0])
+ if f.Kind() != reflect.Func || f.Type().NumIn() != 0 {
+ return false, "Function must take zero arguments"
+ }
+ defer func() {
+ // If the function has not panicked, then don't do the check.
+ if error != "" {
+ return
+ }
+ params[0] = recover()
+ names[0] = "panic"
+ result = reflect.DeepEqual(params[0], params[1])
+ }()
+ f.Call(nil)
+ return false, "Function has not panicked"
+}
+
+type panicMatchesChecker struct {
+ *CheckerInfo
+}
+
+// The PanicMatches checker verifies that calling the provided zero-argument
+// function will cause a panic with an error value matching
+// the regular expression provided.
+//
+// For example:
+//
+// c.Assert(func() { f(1, 2) }, PanicMatches, `open.*: no such file or directory`).
+//
+//
+var PanicMatches Checker = &panicMatchesChecker{
+ &CheckerInfo{Name: "PanicMatches", Params: []string{"function", "expected"}},
+}
+
+func (checker *panicMatchesChecker) Check(params []interface{}, names []string) (result bool, errmsg string) {
+ f := reflect.ValueOf(params[0])
+ if f.Kind() != reflect.Func || f.Type().NumIn() != 0 {
+ return false, "Function must take zero arguments"
+ }
+ defer func() {
+ // If the function has not panicked, then don't do the check.
+ if errmsg != "" {
+ return
+ }
+ obtained := recover()
+ names[0] = "panic"
+ if e, ok := obtained.(error); ok {
+ params[0] = e.Error()
+ } else if _, ok := obtained.(string); ok {
+ params[0] = obtained
+ } else {
+ errmsg = "Panic value is not a string or an error"
+ return
+ }
+ result, errmsg = matches(params[0], params[1])
+ }()
+ f.Call(nil)
+ return false, "Function has not panicked"
+}
+
+// -----------------------------------------------------------------------
+// FitsTypeOf checker.
+
+type fitsTypeChecker struct {
+ *CheckerInfo
+}
+
+// The FitsTypeOf checker verifies that the obtained value is
+// assignable to a variable with the same type as the provided
+// sample value.
+//
+// For example:
+//
+// c.Assert(value, FitsTypeOf, int64(0))
+// c.Assert(value, FitsTypeOf, os.Error(nil))
+//
+var FitsTypeOf Checker = &fitsTypeChecker{
+ &CheckerInfo{Name: "FitsTypeOf", Params: []string{"obtained", "sample"}},
+}
+
+func (checker *fitsTypeChecker) Check(params []interface{}, names []string) (result bool, error string) {
+ obtained := reflect.ValueOf(params[0])
+ sample := reflect.ValueOf(params[1])
+ if !obtained.IsValid() {
+ return false, ""
+ }
+ if !sample.IsValid() {
+ return false, "Invalid sample value"
+ }
+ return obtained.Type().AssignableTo(sample.Type()), ""
+}
+
+// -----------------------------------------------------------------------
+// Implements checker.
+
+type implementsChecker struct {
+ *CheckerInfo
+}
+
+// The Implements checker verifies that the obtained value
+// implements the interface specified via a pointer to an interface
+// variable.
+//
+// For example:
+//
+// var e os.Error
+// c.Assert(err, Implements, &e)
+//
+var Implements Checker = &implementsChecker{
+ &CheckerInfo{Name: "Implements", Params: []string{"obtained", "ifaceptr"}},
+}
+
+func (checker *implementsChecker) Check(params []interface{}, names []string) (result bool, error string) {
+ obtained := reflect.ValueOf(params[0])
+ ifaceptr := reflect.ValueOf(params[1])
+ if !obtained.IsValid() {
+ return false, ""
+ }
+ if !ifaceptr.IsValid() || ifaceptr.Kind() != reflect.Ptr || ifaceptr.Elem().Kind() != reflect.Interface {
+ return false, "ifaceptr should be a pointer to an interface variable"
+ }
+ return obtained.Type().Implements(ifaceptr.Elem().Type()), ""
+}
diff --git a/Godeps/_workspace/src/gopkg.in/check.v1/checkers_test.go b/Godeps/_workspace/src/gopkg.in/check.v1/checkers_test.go
new file mode 100644
index 000000000..5c6974746
--- /dev/null
+++ b/Godeps/_workspace/src/gopkg.in/check.v1/checkers_test.go
@@ -0,0 +1,272 @@
+package check_test
+
+import (
+ "errors"
+ "gopkg.in/check.v1"
+ "reflect"
+ "runtime"
+)
+
+type CheckersS struct{}
+
+var _ = check.Suite(&CheckersS{})
+
+func testInfo(c *check.C, checker check.Checker, name string, paramNames []string) {
+ info := checker.Info()
+ if info.Name != name {
+ c.Fatalf("Got name %s, expected %s", info.Name, name)
+ }
+ if !reflect.DeepEqual(info.Params, paramNames) {
+ c.Fatalf("Got param names %#v, expected %#v", info.Params, paramNames)
+ }
+}
+
+func testCheck(c *check.C, checker check.Checker, result bool, error string, params ...interface{}) ([]interface{}, []string) {
+ info := checker.Info()
+ if len(params) != len(info.Params) {
+ c.Fatalf("unexpected param count in test; expected %d got %d", len(info.Params), len(params))
+ }
+ names := append([]string{}, info.Params...)
+ result_, error_ := checker.Check(params, names)
+ if result_ != result || error_ != error {
+ c.Fatalf("%s.Check(%#v) returned (%#v, %#v) rather than (%#v, %#v)",
+ info.Name, params, result_, error_, result, error)
+ }
+ return params, names
+}
+
+func (s *CheckersS) TestComment(c *check.C) {
+ bug := check.Commentf("a %d bc", 42)
+ comment := bug.CheckCommentString()
+ if comment != "a 42 bc" {
+ c.Fatalf("Commentf returned %#v", comment)
+ }
+}
+
+func (s *CheckersS) TestIsNil(c *check.C) {
+ testInfo(c, check.IsNil, "IsNil", []string{"value"})
+
+ testCheck(c, check.IsNil, true, "", nil)
+ testCheck(c, check.IsNil, false, "", "a")
+
+ testCheck(c, check.IsNil, true, "", (chan int)(nil))
+ testCheck(c, check.IsNil, false, "", make(chan int))
+ testCheck(c, check.IsNil, true, "", (error)(nil))
+ testCheck(c, check.IsNil, false, "", errors.New(""))
+ testCheck(c, check.IsNil, true, "", ([]int)(nil))
+ testCheck(c, check.IsNil, false, "", make([]int, 1))
+ testCheck(c, check.IsNil, false, "", int(0))
+}
+
+func (s *CheckersS) TestNotNil(c *check.C) {
+ testInfo(c, check.NotNil, "NotNil", []string{"value"})
+
+ testCheck(c, check.NotNil, false, "", nil)
+ testCheck(c, check.NotNil, true, "", "a")
+
+ testCheck(c, check.NotNil, false, "", (chan int)(nil))
+ testCheck(c, check.NotNil, true, "", make(chan int))
+ testCheck(c, check.NotNil, false, "", (error)(nil))
+ testCheck(c, check.NotNil, true, "", errors.New(""))
+ testCheck(c, check.NotNil, false, "", ([]int)(nil))
+ testCheck(c, check.NotNil, true, "", make([]int, 1))
+}
+
+func (s *CheckersS) TestNot(c *check.C) {
+ testInfo(c, check.Not(check.IsNil), "Not(IsNil)", []string{"value"})
+
+ testCheck(c, check.Not(check.IsNil), false, "", nil)
+ testCheck(c, check.Not(check.IsNil), true, "", "a")
+}
+
+type simpleStruct struct {
+ i int
+}
+
+func (s *CheckersS) TestEquals(c *check.C) {
+ testInfo(c, check.Equals, "Equals", []string{"obtained", "expected"})
+
+ // The simplest.
+ testCheck(c, check.Equals, true, "", 42, 42)
+ testCheck(c, check.Equals, false, "", 42, 43)
+
+ // Different native types.
+ testCheck(c, check.Equals, false, "", int32(42), int64(42))
+
+ // With nil.
+ testCheck(c, check.Equals, false, "", 42, nil)
+
+ // Slices
+ testCheck(c, check.Equals, false, "runtime error: comparing uncomparable type []uint8", []byte{1, 2}, []byte{1, 2})
+
+ // Struct values
+ testCheck(c, check.Equals, true, "", simpleStruct{1}, simpleStruct{1})
+ testCheck(c, check.Equals, false, "", simpleStruct{1}, simpleStruct{2})
+
+ // Struct pointers
+ testCheck(c, check.Equals, false, "", &simpleStruct{1}, &simpleStruct{1})
+ testCheck(c, check.Equals, false, "", &simpleStruct{1}, &simpleStruct{2})
+}
+
+func (s *CheckersS) TestDeepEquals(c *check.C) {
+ testInfo(c, check.DeepEquals, "DeepEquals", []string{"obtained", "expected"})
+
+ // The simplest.
+ testCheck(c, check.DeepEquals, true, "", 42, 42)
+ testCheck(c, check.DeepEquals, false, "", 42, 43)
+
+ // Different native types.
+ testCheck(c, check.DeepEquals, false, "", int32(42), int64(42))
+
+ // With nil.
+ testCheck(c, check.DeepEquals, false, "", 42, nil)
+
+ // Slices
+ testCheck(c, check.DeepEquals, true, "", []byte{1, 2}, []byte{1, 2})
+ testCheck(c, check.DeepEquals, false, "", []byte{1, 2}, []byte{1, 3})
+
+ // Struct values
+ testCheck(c, check.DeepEquals, true, "", simpleStruct{1}, simpleStruct{1})
+ testCheck(c, check.DeepEquals, false, "", simpleStruct{1}, simpleStruct{2})
+
+ // Struct pointers
+ testCheck(c, check.DeepEquals, true, "", &simpleStruct{1}, &simpleStruct{1})
+ testCheck(c, check.DeepEquals, false, "", &simpleStruct{1}, &simpleStruct{2})
+}
+
+func (s *CheckersS) TestHasLen(c *check.C) {
+ testInfo(c, check.HasLen, "HasLen", []string{"obtained", "n"})
+
+ testCheck(c, check.HasLen, true, "", "abcd", 4)
+ testCheck(c, check.HasLen, true, "", []int{1, 2}, 2)
+ testCheck(c, check.HasLen, false, "", []int{1, 2}, 3)
+
+ testCheck(c, check.HasLen, false, "n must be an int", []int{1, 2}, "2")
+ testCheck(c, check.HasLen, false, "obtained value type has no length", nil, 2)
+}
+
+func (s *CheckersS) TestErrorMatches(c *check.C) {
+ testInfo(c, check.ErrorMatches, "ErrorMatches", []string{"value", "regex"})
+
+ testCheck(c, check.ErrorMatches, false, "Error value is nil", nil, "some error")
+ testCheck(c, check.ErrorMatches, false, "Value is not an error", 1, "some error")
+ testCheck(c, check.ErrorMatches, true, "", errors.New("some error"), "some error")
+ testCheck(c, check.ErrorMatches, true, "", errors.New("some error"), "so.*or")
+
+ // Verify params mutation
+ params, names := testCheck(c, check.ErrorMatches, false, "", errors.New("some error"), "other error")
+ c.Assert(params[0], check.Equals, "some error")
+ c.Assert(names[0], check.Equals, "error")
+}
+
+func (s *CheckersS) TestMatches(c *check.C) {
+ testInfo(c, check.Matches, "Matches", []string{"value", "regex"})
+
+ // Simple matching
+ testCheck(c, check.Matches, true, "", "abc", "abc")
+ testCheck(c, check.Matches, true, "", "abc", "a.c")
+
+ // Must match fully
+ testCheck(c, check.Matches, false, "", "abc", "ab")
+ testCheck(c, check.Matches, false, "", "abc", "bc")
+
+ // String()-enabled values accepted
+ testCheck(c, check.Matches, true, "", reflect.ValueOf("abc"), "a.c")
+ testCheck(c, check.Matches, false, "", reflect.ValueOf("abc"), "a.d")
+
+ // Some error conditions.
+ testCheck(c, check.Matches, false, "Obtained value is not a string and has no .String()", 1, "a.c")
+ testCheck(c, check.Matches, false, "Can't compile regex: error parsing regexp: missing closing ]: `[c$`", "abc", "a[c")
+}
+
+func (s *CheckersS) TestPanics(c *check.C) {
+ testInfo(c, check.Panics, "Panics", []string{"function", "expected"})
+
+ // Some errors.
+ testCheck(c, check.Panics, false, "Function has not panicked", func() bool { return false }, "BOOM")
+ testCheck(c, check.Panics, false, "Function must take zero arguments", 1, "BOOM")
+
+ // Plain strings.
+ testCheck(c, check.Panics, true, "", func() { panic("BOOM") }, "BOOM")
+ testCheck(c, check.Panics, false, "", func() { panic("KABOOM") }, "BOOM")
+ testCheck(c, check.Panics, true, "", func() bool { panic("BOOM") }, "BOOM")
+
+ // Error values.
+ testCheck(c, check.Panics, true, "", func() { panic(errors.New("BOOM")) }, errors.New("BOOM"))
+ testCheck(c, check.Panics, false, "", func() { panic(errors.New("KABOOM")) }, errors.New("BOOM"))
+
+ type deep struct{ i int }
+ // Deep value
+ testCheck(c, check.Panics, true, "", func() { panic(&deep{99}) }, &deep{99})
+
+ // Verify params/names mutation
+ params, names := testCheck(c, check.Panics, false, "", func() { panic(errors.New("KABOOM")) }, errors.New("BOOM"))
+ c.Assert(params[0], check.ErrorMatches, "KABOOM")
+ c.Assert(names[0], check.Equals, "panic")
+
+ // Verify a nil panic
+ testCheck(c, check.Panics, true, "", func() { panic(nil) }, nil)
+ testCheck(c, check.Panics, false, "", func() { panic(nil) }, "NOPE")
+}
+
+func (s *CheckersS) TestPanicMatches(c *check.C) {
+ testInfo(c, check.PanicMatches, "PanicMatches", []string{"function", "expected"})
+
+ // Error matching.
+ testCheck(c, check.PanicMatches, true, "", func() { panic(errors.New("BOOM")) }, "BO.M")
+ testCheck(c, check.PanicMatches, false, "", func() { panic(errors.New("KABOOM")) }, "BO.M")
+
+ // Some errors.
+ testCheck(c, check.PanicMatches, false, "Function has not panicked", func() bool { return false }, "BOOM")
+ testCheck(c, check.PanicMatches, false, "Function must take zero arguments", 1, "BOOM")
+
+ // Plain strings.
+ testCheck(c, check.PanicMatches, true, "", func() { panic("BOOM") }, "BO.M")
+ testCheck(c, check.PanicMatches, false, "", func() { panic("KABOOM") }, "BOOM")
+ testCheck(c, check.PanicMatches, true, "", func() bool { panic("BOOM") }, "BO.M")
+
+ // Verify params/names mutation
+ params, names := testCheck(c, check.PanicMatches, false, "", func() { panic(errors.New("KABOOM")) }, "BOOM")
+ c.Assert(params[0], check.Equals, "KABOOM")
+ c.Assert(names[0], check.Equals, "panic")
+
+ // Verify a nil panic
+ testCheck(c, check.PanicMatches, false, "Panic value is not a string or an error", func() { panic(nil) }, "")
+}
+
+func (s *CheckersS) TestFitsTypeOf(c *check.C) {
+ testInfo(c, check.FitsTypeOf, "FitsTypeOf", []string{"obtained", "sample"})
+
+ // Basic types
+ testCheck(c, check.FitsTypeOf, true, "", 1, 0)
+ testCheck(c, check.FitsTypeOf, false, "", 1, int64(0))
+
+ // Aliases
+ testCheck(c, check.FitsTypeOf, false, "", 1, errors.New(""))
+ testCheck(c, check.FitsTypeOf, false, "", "error", errors.New(""))
+ testCheck(c, check.FitsTypeOf, true, "", errors.New("error"), errors.New(""))
+
+ // Structures
+ testCheck(c, check.FitsTypeOf, false, "", 1, simpleStruct{})
+ testCheck(c, check.FitsTypeOf, false, "", simpleStruct{42}, &simpleStruct{})
+ testCheck(c, check.FitsTypeOf, true, "", simpleStruct{42}, simpleStruct{})
+ testCheck(c, check.FitsTypeOf, true, "", &simpleStruct{42}, &simpleStruct{})
+
+ // Some bad values
+ testCheck(c, check.FitsTypeOf, false, "Invalid sample value", 1, interface{}(nil))
+ testCheck(c, check.FitsTypeOf, false, "", interface{}(nil), 0)
+}
+
+func (s *CheckersS) TestImplements(c *check.C) {
+ testInfo(c, check.Implements, "Implements", []string{"obtained", "ifaceptr"})
+
+ var e error
+ var re runtime.Error
+ testCheck(c, check.Implements, true, "", errors.New(""), &e)
+ testCheck(c, check.Implements, false, "", errors.New(""), &re)
+
+ // Some bad values
+ testCheck(c, check.Implements, false, "ifaceptr should be a pointer to an interface variable", 0, errors.New(""))
+ testCheck(c, check.Implements, false, "ifaceptr should be a pointer to an interface variable", 0, interface{}(nil))
+ testCheck(c, check.Implements, false, "", interface{}(nil), &e)
+}
diff --git a/Godeps/_workspace/src/gopkg.in/check.v1/export_test.go b/Godeps/_workspace/src/gopkg.in/check.v1/export_test.go
new file mode 100644
index 000000000..0e6cfe0f2
--- /dev/null
+++ b/Godeps/_workspace/src/gopkg.in/check.v1/export_test.go
@@ -0,0 +1,9 @@
+package check
+
+func PrintLine(filename string, line int) (string, error) {
+ return printLine(filename, line)
+}
+
+func Indent(s, with string) string {
+ return indent(s, with)
+}
diff --git a/Godeps/_workspace/src/gopkg.in/check.v1/fixture_test.go b/Godeps/_workspace/src/gopkg.in/check.v1/fixture_test.go
new file mode 100644
index 000000000..2bff9e163
--- /dev/null
+++ b/Godeps/_workspace/src/gopkg.in/check.v1/fixture_test.go
@@ -0,0 +1,484 @@
+// Tests for the behavior of the test fixture system.
+
+package check_test
+
+import (
+ . "gopkg.in/check.v1"
+)
+
+// -----------------------------------------------------------------------
+// Fixture test suite.
+
+type FixtureS struct{}
+
+var fixtureS = Suite(&FixtureS{})
+
+func (s *FixtureS) TestCountSuite(c *C) {
+ suitesRun += 1
+}
+
+// -----------------------------------------------------------------------
+// Basic fixture ordering verification.
+
+func (s *FixtureS) TestOrder(c *C) {
+ helper := FixtureHelper{}
+ Run(&helper, nil)
+ c.Check(helper.calls[0], Equals, "SetUpSuite")
+ c.Check(helper.calls[1], Equals, "SetUpTest")
+ c.Check(helper.calls[2], Equals, "Test1")
+ c.Check(helper.calls[3], Equals, "TearDownTest")
+ c.Check(helper.calls[4], Equals, "SetUpTest")
+ c.Check(helper.calls[5], Equals, "Test2")
+ c.Check(helper.calls[6], Equals, "TearDownTest")
+ c.Check(helper.calls[7], Equals, "TearDownSuite")
+ c.Check(len(helper.calls), Equals, 8)
+}
+
+// -----------------------------------------------------------------------
+// Check the behavior when panics occur within tests and fixtures.
+
+func (s *FixtureS) TestPanicOnTest(c *C) {
+ helper := FixtureHelper{panicOn: "Test1"}
+ output := String{}
+ Run(&helper, &RunConf{Output: &output})
+ c.Check(helper.calls[0], Equals, "SetUpSuite")
+ c.Check(helper.calls[1], Equals, "SetUpTest")
+ c.Check(helper.calls[2], Equals, "Test1")
+ c.Check(helper.calls[3], Equals, "TearDownTest")
+ c.Check(helper.calls[4], Equals, "SetUpTest")
+ c.Check(helper.calls[5], Equals, "Test2")
+ c.Check(helper.calls[6], Equals, "TearDownTest")
+ c.Check(helper.calls[7], Equals, "TearDownSuite")
+ c.Check(len(helper.calls), Equals, 8)
+
+ expected := "^\n-+\n" +
+ "PANIC: check_test\\.go:[0-9]+: FixtureHelper.Test1\n\n" +
+ "\\.\\.\\. Panic: Test1 \\(PC=[xA-F0-9]+\\)\n\n" +
+ ".+:[0-9]+\n" +
+ " in (go)?panic\n" +
+ ".*check_test.go:[0-9]+\n" +
+ " in FixtureHelper.trace\n" +
+ ".*check_test.go:[0-9]+\n" +
+ " in FixtureHelper.Test1\n" +
+ "(.|\n)*$"
+
+ c.Check(output.value, Matches, expected)
+}
+
+func (s *FixtureS) TestPanicOnSetUpTest(c *C) {
+ helper := FixtureHelper{panicOn: "SetUpTest"}
+ output := String{}
+ Run(&helper, &RunConf{Output: &output})
+ c.Check(helper.calls[0], Equals, "SetUpSuite")
+ c.Check(helper.calls[1], Equals, "SetUpTest")
+ c.Check(helper.calls[2], Equals, "TearDownTest")
+ c.Check(helper.calls[3], Equals, "TearDownSuite")
+ c.Check(len(helper.calls), Equals, 4)
+
+ expected := "^\n-+\n" +
+ "PANIC: check_test\\.go:[0-9]+: " +
+ "FixtureHelper\\.SetUpTest\n\n" +
+ "\\.\\.\\. Panic: SetUpTest \\(PC=[xA-F0-9]+\\)\n\n" +
+ ".+:[0-9]+\n" +
+ " in (go)?panic\n" +
+ ".*check_test.go:[0-9]+\n" +
+ " in FixtureHelper.trace\n" +
+ ".*check_test.go:[0-9]+\n" +
+ " in FixtureHelper.SetUpTest\n" +
+ "(.|\n)*" +
+ "\n-+\n" +
+ "PANIC: check_test\\.go:[0-9]+: " +
+ "FixtureHelper\\.Test1\n\n" +
+ "\\.\\.\\. Panic: Fixture has panicked " +
+ "\\(see related PANIC\\)\n$"
+
+ c.Check(output.value, Matches, expected)
+}
+
+func (s *FixtureS) TestPanicOnTearDownTest(c *C) {
+ helper := FixtureHelper{panicOn: "TearDownTest"}
+ output := String{}
+ Run(&helper, &RunConf{Output: &output})
+ c.Check(helper.calls[0], Equals, "SetUpSuite")
+ c.Check(helper.calls[1], Equals, "SetUpTest")
+ c.Check(helper.calls[2], Equals, "Test1")
+ c.Check(helper.calls[3], Equals, "TearDownTest")
+ c.Check(helper.calls[4], Equals, "TearDownSuite")
+ c.Check(len(helper.calls), Equals, 5)
+
+ expected := "^\n-+\n" +
+ "PANIC: check_test\\.go:[0-9]+: " +
+ "FixtureHelper.TearDownTest\n\n" +
+ "\\.\\.\\. Panic: TearDownTest \\(PC=[xA-F0-9]+\\)\n\n" +
+ ".+:[0-9]+\n" +
+ " in (go)?panic\n" +
+ ".*check_test.go:[0-9]+\n" +
+ " in FixtureHelper.trace\n" +
+ ".*check_test.go:[0-9]+\n" +
+ " in FixtureHelper.TearDownTest\n" +
+ "(.|\n)*" +
+ "\n-+\n" +
+ "PANIC: check_test\\.go:[0-9]+: " +
+ "FixtureHelper\\.Test1\n\n" +
+ "\\.\\.\\. Panic: Fixture has panicked " +
+ "\\(see related PANIC\\)\n$"
+
+ c.Check(output.value, Matches, expected)
+}
+
+func (s *FixtureS) TestPanicOnSetUpSuite(c *C) {
+ helper := FixtureHelper{panicOn: "SetUpSuite"}
+ output := String{}
+ Run(&helper, &RunConf{Output: &output})
+ c.Check(helper.calls[0], Equals, "SetUpSuite")
+ c.Check(helper.calls[1], Equals, "TearDownSuite")
+ c.Check(len(helper.calls), Equals, 2)
+
+ expected := "^\n-+\n" +
+ "PANIC: check_test\\.go:[0-9]+: " +
+ "FixtureHelper.SetUpSuite\n\n" +
+ "\\.\\.\\. Panic: SetUpSuite \\(PC=[xA-F0-9]+\\)\n\n" +
+ ".+:[0-9]+\n" +
+ " in (go)?panic\n" +
+ ".*check_test.go:[0-9]+\n" +
+ " in FixtureHelper.trace\n" +
+ ".*check_test.go:[0-9]+\n" +
+ " in FixtureHelper.SetUpSuite\n" +
+ "(.|\n)*$"
+
+ c.Check(output.value, Matches, expected)
+}
+
+func (s *FixtureS) TestPanicOnTearDownSuite(c *C) {
+ helper := FixtureHelper{panicOn: "TearDownSuite"}
+ output := String{}
+ Run(&helper, &RunConf{Output: &output})
+ c.Check(helper.calls[0], Equals, "SetUpSuite")
+ c.Check(helper.calls[1], Equals, "SetUpTest")
+ c.Check(helper.calls[2], Equals, "Test1")
+ c.Check(helper.calls[3], Equals, "TearDownTest")
+ c.Check(helper.calls[4], Equals, "SetUpTest")
+ c.Check(helper.calls[5], Equals, "Test2")
+ c.Check(helper.calls[6], Equals, "TearDownTest")
+ c.Check(helper.calls[7], Equals, "TearDownSuite")
+ c.Check(len(helper.calls), Equals, 8)
+
+ expected := "^\n-+\n" +
+ "PANIC: check_test\\.go:[0-9]+: " +
+ "FixtureHelper.TearDownSuite\n\n" +
+ "\\.\\.\\. Panic: TearDownSuite \\(PC=[xA-F0-9]+\\)\n\n" +
+ ".+:[0-9]+\n" +
+ " in (go)?panic\n" +
+ ".*check_test.go:[0-9]+\n" +
+ " in FixtureHelper.trace\n" +
+ ".*check_test.go:[0-9]+\n" +
+ " in FixtureHelper.TearDownSuite\n" +
+ "(.|\n)*$"
+
+ c.Check(output.value, Matches, expected)
+}
+
+// -----------------------------------------------------------------------
+// A wrong argument on a test or fixture will produce a nice error.
+
+func (s *FixtureS) TestPanicOnWrongTestArg(c *C) {
+ helper := WrongTestArgHelper{}
+ output := String{}
+ Run(&helper, &RunConf{Output: &output})
+ c.Check(helper.calls[0], Equals, "SetUpSuite")
+ c.Check(helper.calls[1], Equals, "SetUpTest")
+ c.Check(helper.calls[2], Equals, "TearDownTest")
+ c.Check(helper.calls[3], Equals, "SetUpTest")
+ c.Check(helper.calls[4], Equals, "Test2")
+ c.Check(helper.calls[5], Equals, "TearDownTest")
+ c.Check(helper.calls[6], Equals, "TearDownSuite")
+ c.Check(len(helper.calls), Equals, 7)
+
+ expected := "^\n-+\n" +
+ "PANIC: fixture_test\\.go:[0-9]+: " +
+ "WrongTestArgHelper\\.Test1\n\n" +
+ "\\.\\.\\. Panic: WrongTestArgHelper\\.Test1 argument " +
+ "should be \\*check\\.C\n"
+
+ c.Check(output.value, Matches, expected)
+}
+
+func (s *FixtureS) TestPanicOnWrongSetUpTestArg(c *C) {
+ helper := WrongSetUpTestArgHelper{}
+ output := String{}
+ Run(&helper, &RunConf{Output: &output})
+ c.Check(len(helper.calls), Equals, 0)
+
+ expected :=
+ "^\n-+\n" +
+ "PANIC: fixture_test\\.go:[0-9]+: " +
+ "WrongSetUpTestArgHelper\\.SetUpTest\n\n" +
+ "\\.\\.\\. Panic: WrongSetUpTestArgHelper\\.SetUpTest argument " +
+ "should be \\*check\\.C\n"
+
+ c.Check(output.value, Matches, expected)
+}
+
+func (s *FixtureS) TestPanicOnWrongSetUpSuiteArg(c *C) {
+ helper := WrongSetUpSuiteArgHelper{}
+ output := String{}
+ Run(&helper, &RunConf{Output: &output})
+ c.Check(len(helper.calls), Equals, 0)
+
+ expected :=
+ "^\n-+\n" +
+ "PANIC: fixture_test\\.go:[0-9]+: " +
+ "WrongSetUpSuiteArgHelper\\.SetUpSuite\n\n" +
+ "\\.\\.\\. Panic: WrongSetUpSuiteArgHelper\\.SetUpSuite argument " +
+ "should be \\*check\\.C\n"
+
+ c.Check(output.value, Matches, expected)
+}
+
+// -----------------------------------------------------------------------
+// Nice errors also when tests or fixture have wrong arg count.
+
+func (s *FixtureS) TestPanicOnWrongTestArgCount(c *C) {
+ helper := WrongTestArgCountHelper{}
+ output := String{}
+ Run(&helper, &RunConf{Output: &output})
+ c.Check(helper.calls[0], Equals, "SetUpSuite")
+ c.Check(helper.calls[1], Equals, "SetUpTest")
+ c.Check(helper.calls[2], Equals, "TearDownTest")
+ c.Check(helper.calls[3], Equals, "SetUpTest")
+ c.Check(helper.calls[4], Equals, "Test2")
+ c.Check(helper.calls[5], Equals, "TearDownTest")
+ c.Check(helper.calls[6], Equals, "TearDownSuite")
+ c.Check(len(helper.calls), Equals, 7)
+
+ expected := "^\n-+\n" +
+ "PANIC: fixture_test\\.go:[0-9]+: " +
+ "WrongTestArgCountHelper\\.Test1\n\n" +
+ "\\.\\.\\. Panic: WrongTestArgCountHelper\\.Test1 argument " +
+ "should be \\*check\\.C\n"
+
+ c.Check(output.value, Matches, expected)
+}
+
+func (s *FixtureS) TestPanicOnWrongSetUpTestArgCount(c *C) {
+ helper := WrongSetUpTestArgCountHelper{}
+ output := String{}
+ Run(&helper, &RunConf{Output: &output})
+ c.Check(len(helper.calls), Equals, 0)
+
+ expected :=
+ "^\n-+\n" +
+ "PANIC: fixture_test\\.go:[0-9]+: " +
+ "WrongSetUpTestArgCountHelper\\.SetUpTest\n\n" +
+ "\\.\\.\\. Panic: WrongSetUpTestArgCountHelper\\.SetUpTest argument " +
+ "should be \\*check\\.C\n"
+
+ c.Check(output.value, Matches, expected)
+}
+
+func (s *FixtureS) TestPanicOnWrongSetUpSuiteArgCount(c *C) {
+ helper := WrongSetUpSuiteArgCountHelper{}
+ output := String{}
+ Run(&helper, &RunConf{Output: &output})
+ c.Check(len(helper.calls), Equals, 0)
+
+ expected :=
+ "^\n-+\n" +
+ "PANIC: fixture_test\\.go:[0-9]+: " +
+ "WrongSetUpSuiteArgCountHelper\\.SetUpSuite\n\n" +
+ "\\.\\.\\. Panic: WrongSetUpSuiteArgCountHelper" +
+ "\\.SetUpSuite argument should be \\*check\\.C\n"
+
+ c.Check(output.value, Matches, expected)
+}
+
+// -----------------------------------------------------------------------
+// Helper test suites with wrong function arguments.
+
+type WrongTestArgHelper struct {
+ FixtureHelper
+}
+
+func (s *WrongTestArgHelper) Test1(t int) {
+}
+
+type WrongSetUpTestArgHelper struct {
+ FixtureHelper
+}
+
+func (s *WrongSetUpTestArgHelper) SetUpTest(t int) {
+}
+
+type WrongSetUpSuiteArgHelper struct {
+ FixtureHelper
+}
+
+func (s *WrongSetUpSuiteArgHelper) SetUpSuite(t int) {
+}
+
+type WrongTestArgCountHelper struct {
+ FixtureHelper
+}
+
+func (s *WrongTestArgCountHelper) Test1(c *C, i int) {
+}
+
+type WrongSetUpTestArgCountHelper struct {
+ FixtureHelper
+}
+
+func (s *WrongSetUpTestArgCountHelper) SetUpTest(c *C, i int) {
+}
+
+type WrongSetUpSuiteArgCountHelper struct {
+ FixtureHelper
+}
+
+func (s *WrongSetUpSuiteArgCountHelper) SetUpSuite(c *C, i int) {
+}
+
+// -----------------------------------------------------------------------
+// Ensure fixture doesn't run without tests.
+
+type NoTestsHelper struct {
+ hasRun bool
+}
+
+func (s *NoTestsHelper) SetUpSuite(c *C) {
+ s.hasRun = true
+}
+
+func (s *NoTestsHelper) TearDownSuite(c *C) {
+ s.hasRun = true
+}
+
+func (s *FixtureS) TestFixtureDoesntRunWithoutTests(c *C) {
+ helper := NoTestsHelper{}
+ output := String{}
+ Run(&helper, &RunConf{Output: &output})
+ c.Check(helper.hasRun, Equals, false)
+}
+
+// -----------------------------------------------------------------------
+// Verify that checks and assertions work correctly inside the fixture.
+
+type FixtureCheckHelper struct {
+ fail string
+ completed bool
+}
+
+func (s *FixtureCheckHelper) SetUpSuite(c *C) {
+ switch s.fail {
+ case "SetUpSuiteAssert":
+ c.Assert(false, Equals, true)
+ case "SetUpSuiteCheck":
+ c.Check(false, Equals, true)
+ }
+ s.completed = true
+}
+
+func (s *FixtureCheckHelper) SetUpTest(c *C) {
+ switch s.fail {
+ case "SetUpTestAssert":
+ c.Assert(false, Equals, true)
+ case "SetUpTestCheck":
+ c.Check(false, Equals, true)
+ }
+ s.completed = true
+}
+
+func (s *FixtureCheckHelper) Test(c *C) {
+ // Do nothing.
+}
+
+func (s *FixtureS) TestSetUpSuiteCheck(c *C) {
+ helper := FixtureCheckHelper{fail: "SetUpSuiteCheck"}
+ output := String{}
+ Run(&helper, &RunConf{Output: &output})
+ c.Assert(output.value, Matches,
+ "\n---+\n"+
+ "FAIL: fixture_test\\.go:[0-9]+: "+
+ "FixtureCheckHelper\\.SetUpSuite\n\n"+
+ "fixture_test\\.go:[0-9]+:\n"+
+ " c\\.Check\\(false, Equals, true\\)\n"+
+ "\\.+ obtained bool = false\n"+
+ "\\.+ expected bool = true\n\n")
+ c.Assert(helper.completed, Equals, true)
+}
+
+func (s *FixtureS) TestSetUpSuiteAssert(c *C) {
+ helper := FixtureCheckHelper{fail: "SetUpSuiteAssert"}
+ output := String{}
+ Run(&helper, &RunConf{Output: &output})
+ c.Assert(output.value, Matches,
+ "\n---+\n"+
+ "FAIL: fixture_test\\.go:[0-9]+: "+
+ "FixtureCheckHelper\\.SetUpSuite\n\n"+
+ "fixture_test\\.go:[0-9]+:\n"+
+ " c\\.Assert\\(false, Equals, true\\)\n"+
+ "\\.+ obtained bool = false\n"+
+ "\\.+ expected bool = true\n\n")
+ c.Assert(helper.completed, Equals, false)
+}
+
+// -----------------------------------------------------------------------
+// Verify that logging within SetUpTest() persists within the test log itself.
+
+type FixtureLogHelper struct {
+ c *C
+}
+
+func (s *FixtureLogHelper) SetUpTest(c *C) {
+ s.c = c
+ c.Log("1")
+}
+
+func (s *FixtureLogHelper) Test(c *C) {
+ c.Log("2")
+ s.c.Log("3")
+ c.Log("4")
+ c.Fail()
+}
+
+func (s *FixtureLogHelper) TearDownTest(c *C) {
+ s.c.Log("5")
+}
+
+func (s *FixtureS) TestFixtureLogging(c *C) {
+ helper := FixtureLogHelper{}
+ output := String{}
+ Run(&helper, &RunConf{Output: &output})
+ c.Assert(output.value, Matches,
+ "\n---+\n"+
+ "FAIL: fixture_test\\.go:[0-9]+: "+
+ "FixtureLogHelper\\.Test\n\n"+
+ "1\n2\n3\n4\n5\n")
+}
+
+// -----------------------------------------------------------------------
+// Skip() within fixture methods.
+
+func (s *FixtureS) TestSkipSuite(c *C) {
+ helper := FixtureHelper{skip: true, skipOnN: 0}
+ output := String{}
+ result := Run(&helper, &RunConf{Output: &output})
+ c.Assert(output.value, Equals, "")
+ c.Assert(helper.calls[0], Equals, "SetUpSuite")
+ c.Assert(helper.calls[1], Equals, "TearDownSuite")
+ c.Assert(len(helper.calls), Equals, 2)
+ c.Assert(result.Skipped, Equals, 2)
+}
+
+func (s *FixtureS) TestSkipTest(c *C) {
+ helper := FixtureHelper{skip: true, skipOnN: 1}
+ output := String{}
+ result := Run(&helper, &RunConf{Output: &output})
+ c.Assert(helper.calls[0], Equals, "SetUpSuite")
+ c.Assert(helper.calls[1], Equals, "SetUpTest")
+ c.Assert(helper.calls[2], Equals, "SetUpTest")
+ c.Assert(helper.calls[3], Equals, "Test2")
+ c.Assert(helper.calls[4], Equals, "TearDownTest")
+ c.Assert(helper.calls[5], Equals, "TearDownSuite")
+ c.Assert(len(helper.calls), Equals, 6)
+ c.Assert(result.Skipped, Equals, 1)
+}
diff --git a/Godeps/_workspace/src/gopkg.in/check.v1/foundation_test.go b/Godeps/_workspace/src/gopkg.in/check.v1/foundation_test.go
new file mode 100644
index 000000000..8ecf7915f
--- /dev/null
+++ b/Godeps/_workspace/src/gopkg.in/check.v1/foundation_test.go
@@ -0,0 +1,335 @@
+// These tests check that the foundations of gocheck are working properly.
+// They already assume that fundamental failing is working already, though,
+// since this was tested in bootstrap_test.go. Even then, some care may
+// still have to be taken when using external functions, since they should
+// of course not rely on functionality tested here.
+
+package check_test
+
+import (
+ "fmt"
+ "gopkg.in/check.v1"
+ "log"
+ "os"
+ "regexp"
+ "strings"
+)
+
+// -----------------------------------------------------------------------
+// Foundation test suite.
+
+type FoundationS struct{}
+
+var foundationS = check.Suite(&FoundationS{})
+
+func (s *FoundationS) TestCountSuite(c *check.C) {
+ suitesRun += 1
+}
+
+func (s *FoundationS) TestErrorf(c *check.C) {
+ // Do not use checkState() here. It depends on Errorf() working.
+ expectedLog := fmt.Sprintf("foundation_test.go:%d:\n"+
+ " c.Errorf(\"Error %%v!\", \"message\")\n"+
+ "... Error: Error message!\n\n",
+ getMyLine()+1)
+ c.Errorf("Error %v!", "message")
+ failed := c.Failed()
+ c.Succeed()
+ if log := c.GetTestLog(); log != expectedLog {
+ c.Logf("Errorf() logged %#v rather than %#v", log, expectedLog)
+ c.Fail()
+ }
+ if !failed {
+ c.Logf("Errorf() didn't put the test in a failed state")
+ c.Fail()
+ }
+}
+
+func (s *FoundationS) TestError(c *check.C) {
+ expectedLog := fmt.Sprintf("foundation_test.go:%d:\n"+
+ " c\\.Error\\(\"Error \", \"message!\"\\)\n"+
+ "\\.\\.\\. Error: Error message!\n\n",
+ getMyLine()+1)
+ c.Error("Error ", "message!")
+ checkState(c, nil,
+ &expectedState{
+ name: "Error(`Error `, `message!`)",
+ failed: true,
+ log: expectedLog,
+ })
+}
+
+func (s *FoundationS) TestFailNow(c *check.C) {
+ defer (func() {
+ if !c.Failed() {
+ c.Error("FailNow() didn't fail the test")
+ } else {
+ c.Succeed()
+ if c.GetTestLog() != "" {
+ c.Error("Something got logged:\n" + c.GetTestLog())
+ }
+ }
+ })()
+
+ c.FailNow()
+ c.Log("FailNow() didn't stop the test")
+}
+
+func (s *FoundationS) TestSucceedNow(c *check.C) {
+ defer (func() {
+ if c.Failed() {
+ c.Error("SucceedNow() didn't succeed the test")
+ }
+ if c.GetTestLog() != "" {
+ c.Error("Something got logged:\n" + c.GetTestLog())
+ }
+ })()
+
+ c.Fail()
+ c.SucceedNow()
+ c.Log("SucceedNow() didn't stop the test")
+}
+
+func (s *FoundationS) TestFailureHeader(c *check.C) {
+ output := String{}
+ failHelper := FailHelper{}
+ check.Run(&failHelper, &check.RunConf{Output: &output})
+ header := fmt.Sprintf(""+
+ "\n-----------------------------------"+
+ "-----------------------------------\n"+
+ "FAIL: check_test.go:%d: FailHelper.TestLogAndFail\n",
+ failHelper.testLine)
+ if strings.Index(output.value, header) == -1 {
+ c.Errorf(""+
+ "Failure didn't print a proper header.\n"+
+ "... Got:\n%s... Expected something with:\n%s",
+ output.value, header)
+ }
+}
+
+func (s *FoundationS) TestFatal(c *check.C) {
+ var line int
+ defer (func() {
+ if !c.Failed() {
+ c.Error("Fatal() didn't fail the test")
+ } else {
+ c.Succeed()
+ expected := fmt.Sprintf("foundation_test.go:%d:\n"+
+ " c.Fatal(\"Die \", \"now!\")\n"+
+ "... Error: Die now!\n\n",
+ line)
+ if c.GetTestLog() != expected {
+ c.Error("Incorrect log:", c.GetTestLog())
+ }
+ }
+ })()
+
+ line = getMyLine() + 1
+ c.Fatal("Die ", "now!")
+ c.Log("Fatal() didn't stop the test")
+}
+
+func (s *FoundationS) TestFatalf(c *check.C) {
+ var line int
+ defer (func() {
+ if !c.Failed() {
+ c.Error("Fatalf() didn't fail the test")
+ } else {
+ c.Succeed()
+ expected := fmt.Sprintf("foundation_test.go:%d:\n"+
+ " c.Fatalf(\"Die %%s!\", \"now\")\n"+
+ "... Error: Die now!\n\n",
+ line)
+ if c.GetTestLog() != expected {
+ c.Error("Incorrect log:", c.GetTestLog())
+ }
+ }
+ })()
+
+ line = getMyLine() + 1
+ c.Fatalf("Die %s!", "now")
+ c.Log("Fatalf() didn't stop the test")
+}
+
+func (s *FoundationS) TestCallerLoggingInsideTest(c *check.C) {
+ log := fmt.Sprintf(""+
+ "foundation_test.go:%d:\n"+
+ " result := c.Check\\(10, check.Equals, 20\\)\n"+
+ "\\.\\.\\. obtained int = 10\n"+
+ "\\.\\.\\. expected int = 20\n\n",
+ getMyLine()+1)
+ result := c.Check(10, check.Equals, 20)
+ checkState(c, result,
+ &expectedState{
+ name: "Check(10, Equals, 20)",
+ result: false,
+ failed: true,
+ log: log,
+ })
+}
+
+func (s *FoundationS) TestCallerLoggingInDifferentFile(c *check.C) {
+ result, line := checkEqualWrapper(c, 10, 20)
+ testLine := getMyLine() - 1
+ log := fmt.Sprintf(""+
+ "foundation_test.go:%d:\n"+
+ " result, line := checkEqualWrapper\\(c, 10, 20\\)\n"+
+ "check_test.go:%d:\n"+
+ " return c.Check\\(obtained, check.Equals, expected\\), getMyLine\\(\\)\n"+
+ "\\.\\.\\. obtained int = 10\n"+
+ "\\.\\.\\. expected int = 20\n\n",
+ testLine, line)
+ checkState(c, result,
+ &expectedState{
+ name: "Check(10, Equals, 20)",
+ result: false,
+ failed: true,
+ log: log,
+ })
+}
+
+// -----------------------------------------------------------------------
+// ExpectFailure() inverts the logic of failure.
+
+type ExpectFailureSucceedHelper struct{}
+
+func (s *ExpectFailureSucceedHelper) TestSucceed(c *check.C) {
+ c.ExpectFailure("It booms!")
+ c.Error("Boom!")
+}
+
+type ExpectFailureFailHelper struct{}
+
+func (s *ExpectFailureFailHelper) TestFail(c *check.C) {
+ c.ExpectFailure("Bug #XYZ")
+}
+
+func (s *FoundationS) TestExpectFailureFail(c *check.C) {
+ helper := ExpectFailureFailHelper{}
+ output := String{}
+ result := check.Run(&helper, &check.RunConf{Output: &output})
+
+ expected := "" +
+ "^\n-+\n" +
+ "FAIL: foundation_test\\.go:[0-9]+:" +
+ " ExpectFailureFailHelper\\.TestFail\n\n" +
+ "\\.\\.\\. Error: Test succeeded, but was expected to fail\n" +
+ "\\.\\.\\. Reason: Bug #XYZ\n$"
+
+ matched, err := regexp.MatchString(expected, output.value)
+ if err != nil {
+ c.Error("Bad expression: ", expected)
+ } else if !matched {
+ c.Error("ExpectFailure() didn't log properly:\n", output.value)
+ }
+
+ c.Assert(result.ExpectedFailures, check.Equals, 0)
+}
+
+func (s *FoundationS) TestExpectFailureSucceed(c *check.C) {
+ helper := ExpectFailureSucceedHelper{}
+ output := String{}
+ result := check.Run(&helper, &check.RunConf{Output: &output})
+
+ c.Assert(output.value, check.Equals, "")
+ c.Assert(result.ExpectedFailures, check.Equals, 1)
+}
+
+func (s *FoundationS) TestExpectFailureSucceedVerbose(c *check.C) {
+ helper := ExpectFailureSucceedHelper{}
+ output := String{}
+ result := check.Run(&helper, &check.RunConf{Output: &output, Verbose: true})
+
+ expected := "" +
+ "FAIL EXPECTED: foundation_test\\.go:[0-9]+:" +
+ " ExpectFailureSucceedHelper\\.TestSucceed \\(It booms!\\)\t *[.0-9]+s\n"
+
+ matched, err := regexp.MatchString(expected, output.value)
+ if err != nil {
+ c.Error("Bad expression: ", expected)
+ } else if !matched {
+ c.Error("ExpectFailure() didn't log properly:\n", output.value)
+ }
+
+ c.Assert(result.ExpectedFailures, check.Equals, 1)
+}
+
+// -----------------------------------------------------------------------
+// Skip() allows stopping a test without positive/negative results.
+
+type SkipTestHelper struct{}
+
+func (s *SkipTestHelper) TestFail(c *check.C) {
+ c.Skip("Wrong platform or whatever")
+ c.Error("Boom!")
+}
+
+func (s *FoundationS) TestSkip(c *check.C) {
+ helper := SkipTestHelper{}
+ output := String{}
+ check.Run(&helper, &check.RunConf{Output: &output})
+
+ if output.value != "" {
+ c.Error("Skip() logged something:\n", output.value)
+ }
+}
+
+func (s *FoundationS) TestSkipVerbose(c *check.C) {
+ helper := SkipTestHelper{}
+ output := String{}
+ check.Run(&helper, &check.RunConf{Output: &output, Verbose: true})
+
+ expected := "SKIP: foundation_test\\.go:[0-9]+: SkipTestHelper\\.TestFail" +
+ " \\(Wrong platform or whatever\\)"
+ matched, err := regexp.MatchString(expected, output.value)
+ if err != nil {
+ c.Error("Bad expression: ", expected)
+ } else if !matched {
+ c.Error("Skip() didn't log properly:\n", output.value)
+ }
+}
+
+// -----------------------------------------------------------------------
+// Check minimum *log.Logger interface provided by *check.C.
+
+type minLogger interface {
+ Output(calldepth int, s string) error
+}
+
+func (s *BootstrapS) TestMinLogger(c *check.C) {
+ var logger minLogger
+ logger = log.New(os.Stderr, "", 0)
+ logger = c
+ logger.Output(0, "Hello there")
+ expected := `\[LOG\] [0-9]+:[0-9][0-9]\.[0-9][0-9][0-9] +Hello there\n`
+ output := c.GetTestLog()
+ c.Assert(output, check.Matches, expected)
+}
+
+// -----------------------------------------------------------------------
+// Ensure that suites with embedded types are working fine, including the
+// the workaround for issue 906.
+
+type EmbeddedInternalS struct {
+ called bool
+}
+
+type EmbeddedS struct {
+ EmbeddedInternalS
+}
+
+var embeddedS = check.Suite(&EmbeddedS{})
+
+func (s *EmbeddedS) TestCountSuite(c *check.C) {
+ suitesRun += 1
+}
+
+func (s *EmbeddedInternalS) TestMethod(c *check.C) {
+ c.Error("TestMethod() of the embedded type was called!?")
+}
+
+func (s *EmbeddedS) TestMethod(c *check.C) {
+ // http://code.google.com/p/go/issues/detail?id=906
+ c.Check(s.called, check.Equals, false) // Go issue 906 is affecting the runner?
+ s.called = true
+}
diff --git a/Godeps/_workspace/src/gopkg.in/check.v1/helpers.go b/Godeps/_workspace/src/gopkg.in/check.v1/helpers.go
new file mode 100644
index 000000000..4b6c26da4
--- /dev/null
+++ b/Godeps/_workspace/src/gopkg.in/check.v1/helpers.go
@@ -0,0 +1,231 @@
+package check
+
+import (
+ "fmt"
+ "strings"
+ "time"
+)
+
+// TestName returns the current test name in the form "SuiteName.TestName"
+func (c *C) TestName() string {
+ return c.testName
+}
+
+// -----------------------------------------------------------------------
+// Basic succeeding/failing logic.
+
+// Failed returns whether the currently running test has already failed.
+func (c *C) Failed() bool {
+ return c.status == failedSt
+}
+
+// Fail marks the currently running test as failed.
+//
+// Something ought to have been previously logged so the developer can tell
+// what went wrong. The higher level helper functions will fail the test
+// and do the logging properly.
+func (c *C) Fail() {
+ c.status = failedSt
+}
+
+// FailNow marks the currently running test as failed and stops running it.
+// Something ought to have been previously logged so the developer can tell
+// what went wrong. The higher level helper functions will fail the test
+// and do the logging properly.
+func (c *C) FailNow() {
+ c.Fail()
+ c.stopNow()
+}
+
+// Succeed marks the currently running test as succeeded, undoing any
+// previous failures.
+func (c *C) Succeed() {
+ c.status = succeededSt
+}
+
+// SucceedNow marks the currently running test as succeeded, undoing any
+// previous failures, and stops running the test.
+func (c *C) SucceedNow() {
+ c.Succeed()
+ c.stopNow()
+}
+
+// ExpectFailure informs that the running test is knowingly broken for
+// the provided reason. If the test does not fail, an error will be reported
+// to raise attention to this fact. This method is useful to temporarily
+// disable tests which cover well known problems until a better time to
+// fix the problem is found, without forgetting about the fact that a
+// failure still exists.
+func (c *C) ExpectFailure(reason string) {
+ if reason == "" {
+ panic("Missing reason why the test is expected to fail")
+ }
+ c.mustFail = true
+ c.reason = reason
+}
+
+// Skip skips the running test for the provided reason. If run from within
+// SetUpTest, the individual test being set up will be skipped, and if run
+// from within SetUpSuite, the whole suite is skipped.
+func (c *C) Skip(reason string) {
+ if reason == "" {
+ panic("Missing reason why the test is being skipped")
+ }
+ c.reason = reason
+ c.status = skippedSt
+ c.stopNow()
+}
+
+// -----------------------------------------------------------------------
+// Basic logging.
+
+// GetTestLog returns the current test error output.
+func (c *C) GetTestLog() string {
+ return c.logb.String()
+}
+
+// Log logs some information into the test error output.
+// The provided arguments are assembled together into a string with fmt.Sprint.
+func (c *C) Log(args ...interface{}) {
+ c.log(args...)
+}
+
+// Log logs some information into the test error output.
+// The provided arguments are assembled together into a string with fmt.Sprintf.
+func (c *C) Logf(format string, args ...interface{}) {
+ c.logf(format, args...)
+}
+
+// Output enables *C to be used as a logger in functions that require only
+// the minimum interface of *log.Logger.
+func (c *C) Output(calldepth int, s string) error {
+ d := time.Now().Sub(c.startTime)
+ msec := d / time.Millisecond
+ sec := d / time.Second
+ min := d / time.Minute
+
+ c.Logf("[LOG] %d:%02d.%03d %s", min, sec%60, msec%1000, s)
+ return nil
+}
+
+// Error logs an error into the test error output and marks the test as failed.
+// The provided arguments are assembled together into a string with fmt.Sprint.
+func (c *C) Error(args ...interface{}) {
+ c.logCaller(1)
+ c.logString(fmt.Sprint("Error: ", fmt.Sprint(args...)))
+ c.logNewLine()
+ c.Fail()
+}
+
+// Errorf logs an error into the test error output and marks the test as failed.
+// The provided arguments are assembled together into a string with fmt.Sprintf.
+func (c *C) Errorf(format string, args ...interface{}) {
+ c.logCaller(1)
+ c.logString(fmt.Sprintf("Error: "+format, args...))
+ c.logNewLine()
+ c.Fail()
+}
+
+// Fatal logs an error into the test error output, marks the test as failed, and
+// stops the test execution. The provided arguments are assembled together into
+// a string with fmt.Sprint.
+func (c *C) Fatal(args ...interface{}) {
+ c.logCaller(1)
+ c.logString(fmt.Sprint("Error: ", fmt.Sprint(args...)))
+ c.logNewLine()
+ c.FailNow()
+}
+
+// Fatlaf logs an error into the test error output, marks the test as failed, and
+// stops the test execution. The provided arguments are assembled together into
+// a string with fmt.Sprintf.
+func (c *C) Fatalf(format string, args ...interface{}) {
+ c.logCaller(1)
+ c.logString(fmt.Sprint("Error: ", fmt.Sprintf(format, args...)))
+ c.logNewLine()
+ c.FailNow()
+}
+
+// -----------------------------------------------------------------------
+// Generic checks and assertions based on checkers.
+
+// Check verifies if the first value matches the expected value according
+// to the provided checker. If they do not match, an error is logged, the
+// test is marked as failed, and the test execution continues.
+//
+// Some checkers may not need the expected argument (e.g. IsNil).
+//
+// Extra arguments provided to the function are logged next to the reported
+// problem when the matching fails.
+func (c *C) Check(obtained interface{}, checker Checker, args ...interface{}) bool {
+ return c.internalCheck("Check", obtained, checker, args...)
+}
+
+// Assert ensures that the first value matches the expected value according
+// to the provided checker. If they do not match, an error is logged, the
+// test is marked as failed, and the test execution stops.
+//
+// Some checkers may not need the expected argument (e.g. IsNil).
+//
+// Extra arguments provided to the function are logged next to the reported
+// problem when the matching fails.
+func (c *C) Assert(obtained interface{}, checker Checker, args ...interface{}) {
+ if !c.internalCheck("Assert", obtained, checker, args...) {
+ c.stopNow()
+ }
+}
+
+func (c *C) internalCheck(funcName string, obtained interface{}, checker Checker, args ...interface{}) bool {
+ if checker == nil {
+ c.logCaller(2)
+ c.logString(fmt.Sprintf("%s(obtained, nil!?, ...):", funcName))
+ c.logString("Oops.. you've provided a nil checker!")
+ c.logNewLine()
+ c.Fail()
+ return false
+ }
+
+ // If the last argument is a bug info, extract it out.
+ var comment CommentInterface
+ if len(args) > 0 {
+ if c, ok := args[len(args)-1].(CommentInterface); ok {
+ comment = c
+ args = args[:len(args)-1]
+ }
+ }
+
+ params := append([]interface{}{obtained}, args...)
+ info := checker.Info()
+
+ if len(params) != len(info.Params) {
+ names := append([]string{info.Params[0], info.Name}, info.Params[1:]...)
+ c.logCaller(2)
+ c.logString(fmt.Sprintf("%s(%s):", funcName, strings.Join(names, ", ")))
+ c.logString(fmt.Sprintf("Wrong number of parameters for %s: want %d, got %d", info.Name, len(names), len(params)+1))
+ c.logNewLine()
+ c.Fail()
+ return false
+ }
+
+ // Copy since it may be mutated by Check.
+ names := append([]string{}, info.Params...)
+
+ // Do the actual check.
+ result, error := checker.Check(params, names)
+ if !result || error != "" {
+ c.logCaller(2)
+ for i := 0; i != len(params); i++ {
+ c.logValue(names[i], params[i])
+ }
+ if comment != nil {
+ c.logString(comment.CheckCommentString())
+ }
+ if error != "" {
+ c.logString(error)
+ }
+ c.logNewLine()
+ c.Fail()
+ return false
+ }
+ return true
+}
diff --git a/Godeps/_workspace/src/gopkg.in/check.v1/helpers_test.go b/Godeps/_workspace/src/gopkg.in/check.v1/helpers_test.go
new file mode 100644
index 000000000..4baa656ba
--- /dev/null
+++ b/Godeps/_workspace/src/gopkg.in/check.v1/helpers_test.go
@@ -0,0 +1,519 @@
+// These tests verify the inner workings of the helper methods associated
+// with check.T.
+
+package check_test
+
+import (
+ "gopkg.in/check.v1"
+ "os"
+ "reflect"
+ "runtime"
+ "sync"
+)
+
+var helpersS = check.Suite(&HelpersS{})
+
+type HelpersS struct{}
+
+func (s *HelpersS) TestCountSuite(c *check.C) {
+ suitesRun += 1
+}
+
+// -----------------------------------------------------------------------
+// Fake checker and bug info to verify the behavior of Assert() and Check().
+
+type MyChecker struct {
+ info *check.CheckerInfo
+ params []interface{}
+ names []string
+ result bool
+ error string
+}
+
+func (checker *MyChecker) Info() *check.CheckerInfo {
+ if checker.info == nil {
+ return &check.CheckerInfo{Name: "MyChecker", Params: []string{"myobtained", "myexpected"}}
+ }
+ return checker.info
+}
+
+func (checker *MyChecker) Check(params []interface{}, names []string) (bool, string) {
+ rparams := checker.params
+ rnames := checker.names
+ checker.params = append([]interface{}{}, params...)
+ checker.names = append([]string{}, names...)
+ if rparams != nil {
+ copy(params, rparams)
+ }
+ if rnames != nil {
+ copy(names, rnames)
+ }
+ return checker.result, checker.error
+}
+
+type myCommentType string
+
+func (c myCommentType) CheckCommentString() string {
+ return string(c)
+}
+
+func myComment(s string) myCommentType {
+ return myCommentType(s)
+}
+
+// -----------------------------------------------------------------------
+// Ensure a real checker actually works fine.
+
+func (s *HelpersS) TestCheckerInterface(c *check.C) {
+ testHelperSuccess(c, "Check(1, Equals, 1)", true, func() interface{} {
+ return c.Check(1, check.Equals, 1)
+ })
+}
+
+// -----------------------------------------------------------------------
+// Tests for Check(), mostly the same as for Assert() following these.
+
+func (s *HelpersS) TestCheckSucceedWithExpected(c *check.C) {
+ checker := &MyChecker{result: true}
+ testHelperSuccess(c, "Check(1, checker, 2)", true, func() interface{} {
+ return c.Check(1, checker, 2)
+ })
+ if !reflect.DeepEqual(checker.params, []interface{}{1, 2}) {
+ c.Fatalf("Bad params for check: %#v", checker.params)
+ }
+}
+
+func (s *HelpersS) TestCheckSucceedWithoutExpected(c *check.C) {
+ checker := &MyChecker{result: true, info: &check.CheckerInfo{Params: []string{"myvalue"}}}
+ testHelperSuccess(c, "Check(1, checker)", true, func() interface{} {
+ return c.Check(1, checker)
+ })
+ if !reflect.DeepEqual(checker.params, []interface{}{1}) {
+ c.Fatalf("Bad params for check: %#v", checker.params)
+ }
+}
+
+func (s *HelpersS) TestCheckFailWithExpected(c *check.C) {
+ checker := &MyChecker{result: false}
+ log := "(?s)helpers_test\\.go:[0-9]+:.*\nhelpers_test\\.go:[0-9]+:\n" +
+ " return c\\.Check\\(1, checker, 2\\)\n" +
+ "\\.+ myobtained int = 1\n" +
+ "\\.+ myexpected int = 2\n\n"
+ testHelperFailure(c, "Check(1, checker, 2)", false, false, log,
+ func() interface{} {
+ return c.Check(1, checker, 2)
+ })
+}
+
+func (s *HelpersS) TestCheckFailWithExpectedAndComment(c *check.C) {
+ checker := &MyChecker{result: false}
+ log := "(?s)helpers_test\\.go:[0-9]+:.*\nhelpers_test\\.go:[0-9]+:\n" +
+ " return c\\.Check\\(1, checker, 2, myComment\\(\"Hello world!\"\\)\\)\n" +
+ "\\.+ myobtained int = 1\n" +
+ "\\.+ myexpected int = 2\n" +
+ "\\.+ Hello world!\n\n"
+ testHelperFailure(c, "Check(1, checker, 2, msg)", false, false, log,
+ func() interface{} {
+ return c.Check(1, checker, 2, myComment("Hello world!"))
+ })
+}
+
+func (s *HelpersS) TestCheckFailWithExpectedAndStaticComment(c *check.C) {
+ checker := &MyChecker{result: false}
+ log := "(?s)helpers_test\\.go:[0-9]+:.*\nhelpers_test\\.go:[0-9]+:\n" +
+ " // Nice leading comment\\.\n" +
+ " return c\\.Check\\(1, checker, 2\\) // Hello there\n" +
+ "\\.+ myobtained int = 1\n" +
+ "\\.+ myexpected int = 2\n\n"
+ testHelperFailure(c, "Check(1, checker, 2, msg)", false, false, log,
+ func() interface{} {
+ // Nice leading comment.
+ return c.Check(1, checker, 2) // Hello there
+ })
+}
+
+func (s *HelpersS) TestCheckFailWithoutExpected(c *check.C) {
+ checker := &MyChecker{result: false, info: &check.CheckerInfo{Params: []string{"myvalue"}}}
+ log := "(?s)helpers_test\\.go:[0-9]+:.*\nhelpers_test\\.go:[0-9]+:\n" +
+ " return c\\.Check\\(1, checker\\)\n" +
+ "\\.+ myvalue int = 1\n\n"
+ testHelperFailure(c, "Check(1, checker)", false, false, log,
+ func() interface{} {
+ return c.Check(1, checker)
+ })
+}
+
+func (s *HelpersS) TestCheckFailWithoutExpectedAndMessage(c *check.C) {
+ checker := &MyChecker{result: false, info: &check.CheckerInfo{Params: []string{"myvalue"}}}
+ log := "(?s)helpers_test\\.go:[0-9]+:.*\nhelpers_test\\.go:[0-9]+:\n" +
+ " return c\\.Check\\(1, checker, myComment\\(\"Hello world!\"\\)\\)\n" +
+ "\\.+ myvalue int = 1\n" +
+ "\\.+ Hello world!\n\n"
+ testHelperFailure(c, "Check(1, checker, msg)", false, false, log,
+ func() interface{} {
+ return c.Check(1, checker, myComment("Hello world!"))
+ })
+}
+
+func (s *HelpersS) TestCheckWithMissingExpected(c *check.C) {
+ checker := &MyChecker{result: true}
+ log := "(?s)helpers_test\\.go:[0-9]+:.*\nhelpers_test\\.go:[0-9]+:\n" +
+ " return c\\.Check\\(1, checker\\)\n" +
+ "\\.+ Check\\(myobtained, MyChecker, myexpected\\):\n" +
+ "\\.+ Wrong number of parameters for MyChecker: " +
+ "want 3, got 2\n\n"
+ testHelperFailure(c, "Check(1, checker, !?)", false, false, log,
+ func() interface{} {
+ return c.Check(1, checker)
+ })
+}
+
+func (s *HelpersS) TestCheckWithTooManyExpected(c *check.C) {
+ checker := &MyChecker{result: true}
+ log := "(?s)helpers_test\\.go:[0-9]+:.*\nhelpers_test\\.go:[0-9]+:\n" +
+ " return c\\.Check\\(1, checker, 2, 3\\)\n" +
+ "\\.+ Check\\(myobtained, MyChecker, myexpected\\):\n" +
+ "\\.+ Wrong number of parameters for MyChecker: " +
+ "want 3, got 4\n\n"
+ testHelperFailure(c, "Check(1, checker, 2, 3)", false, false, log,
+ func() interface{} {
+ return c.Check(1, checker, 2, 3)
+ })
+}
+
+func (s *HelpersS) TestCheckWithError(c *check.C) {
+ checker := &MyChecker{result: false, error: "Some not so cool data provided!"}
+ log := "(?s)helpers_test\\.go:[0-9]+:.*\nhelpers_test\\.go:[0-9]+:\n" +
+ " return c\\.Check\\(1, checker, 2\\)\n" +
+ "\\.+ myobtained int = 1\n" +
+ "\\.+ myexpected int = 2\n" +
+ "\\.+ Some not so cool data provided!\n\n"
+ testHelperFailure(c, "Check(1, checker, 2)", false, false, log,
+ func() interface{} {
+ return c.Check(1, checker, 2)
+ })
+}
+
+func (s *HelpersS) TestCheckWithNilChecker(c *check.C) {
+ log := "(?s)helpers_test\\.go:[0-9]+:.*\nhelpers_test\\.go:[0-9]+:\n" +
+ " return c\\.Check\\(1, nil\\)\n" +
+ "\\.+ Check\\(obtained, nil!\\?, \\.\\.\\.\\):\n" +
+ "\\.+ Oops\\.\\. you've provided a nil checker!\n\n"
+ testHelperFailure(c, "Check(obtained, nil)", false, false, log,
+ func() interface{} {
+ return c.Check(1, nil)
+ })
+}
+
+func (s *HelpersS) TestCheckWithParamsAndNamesMutation(c *check.C) {
+ checker := &MyChecker{result: false, params: []interface{}{3, 4}, names: []string{"newobtained", "newexpected"}}
+ log := "(?s)helpers_test\\.go:[0-9]+:.*\nhelpers_test\\.go:[0-9]+:\n" +
+ " return c\\.Check\\(1, checker, 2\\)\n" +
+ "\\.+ newobtained int = 3\n" +
+ "\\.+ newexpected int = 4\n\n"
+ testHelperFailure(c, "Check(1, checker, 2) with mutation", false, false, log,
+ func() interface{} {
+ return c.Check(1, checker, 2)
+ })
+}
+
+// -----------------------------------------------------------------------
+// Tests for Assert(), mostly the same as for Check() above.
+
+func (s *HelpersS) TestAssertSucceedWithExpected(c *check.C) {
+ checker := &MyChecker{result: true}
+ testHelperSuccess(c, "Assert(1, checker, 2)", nil, func() interface{} {
+ c.Assert(1, checker, 2)
+ return nil
+ })
+ if !reflect.DeepEqual(checker.params, []interface{}{1, 2}) {
+ c.Fatalf("Bad params for check: %#v", checker.params)
+ }
+}
+
+func (s *HelpersS) TestAssertSucceedWithoutExpected(c *check.C) {
+ checker := &MyChecker{result: true, info: &check.CheckerInfo{Params: []string{"myvalue"}}}
+ testHelperSuccess(c, "Assert(1, checker)", nil, func() interface{} {
+ c.Assert(1, checker)
+ return nil
+ })
+ if !reflect.DeepEqual(checker.params, []interface{}{1}) {
+ c.Fatalf("Bad params for check: %#v", checker.params)
+ }
+}
+
+func (s *HelpersS) TestAssertFailWithExpected(c *check.C) {
+ checker := &MyChecker{result: false}
+ log := "(?s)helpers_test\\.go:[0-9]+:.*\nhelpers_test\\.go:[0-9]+:\n" +
+ " c\\.Assert\\(1, checker, 2\\)\n" +
+ "\\.+ myobtained int = 1\n" +
+ "\\.+ myexpected int = 2\n\n"
+ testHelperFailure(c, "Assert(1, checker, 2)", nil, true, log,
+ func() interface{} {
+ c.Assert(1, checker, 2)
+ return nil
+ })
+}
+
+func (s *HelpersS) TestAssertFailWithExpectedAndMessage(c *check.C) {
+ checker := &MyChecker{result: false}
+ log := "(?s)helpers_test\\.go:[0-9]+:.*\nhelpers_test\\.go:[0-9]+:\n" +
+ " c\\.Assert\\(1, checker, 2, myComment\\(\"Hello world!\"\\)\\)\n" +
+ "\\.+ myobtained int = 1\n" +
+ "\\.+ myexpected int = 2\n" +
+ "\\.+ Hello world!\n\n"
+ testHelperFailure(c, "Assert(1, checker, 2, msg)", nil, true, log,
+ func() interface{} {
+ c.Assert(1, checker, 2, myComment("Hello world!"))
+ return nil
+ })
+}
+
+func (s *HelpersS) TestAssertFailWithoutExpected(c *check.C) {
+ checker := &MyChecker{result: false, info: &check.CheckerInfo{Params: []string{"myvalue"}}}
+ log := "(?s)helpers_test\\.go:[0-9]+:.*\nhelpers_test\\.go:[0-9]+:\n" +
+ " c\\.Assert\\(1, checker\\)\n" +
+ "\\.+ myvalue int = 1\n\n"
+ testHelperFailure(c, "Assert(1, checker)", nil, true, log,
+ func() interface{} {
+ c.Assert(1, checker)
+ return nil
+ })
+}
+
+func (s *HelpersS) TestAssertFailWithoutExpectedAndMessage(c *check.C) {
+ checker := &MyChecker{result: false, info: &check.CheckerInfo{Params: []string{"myvalue"}}}
+ log := "(?s)helpers_test\\.go:[0-9]+:.*\nhelpers_test\\.go:[0-9]+:\n" +
+ " c\\.Assert\\(1, checker, myComment\\(\"Hello world!\"\\)\\)\n" +
+ "\\.+ myvalue int = 1\n" +
+ "\\.+ Hello world!\n\n"
+ testHelperFailure(c, "Assert(1, checker, msg)", nil, true, log,
+ func() interface{} {
+ c.Assert(1, checker, myComment("Hello world!"))
+ return nil
+ })
+}
+
+func (s *HelpersS) TestAssertWithMissingExpected(c *check.C) {
+ checker := &MyChecker{result: true}
+ log := "(?s)helpers_test\\.go:[0-9]+:.*\nhelpers_test\\.go:[0-9]+:\n" +
+ " c\\.Assert\\(1, checker\\)\n" +
+ "\\.+ Assert\\(myobtained, MyChecker, myexpected\\):\n" +
+ "\\.+ Wrong number of parameters for MyChecker: " +
+ "want 3, got 2\n\n"
+ testHelperFailure(c, "Assert(1, checker, !?)", nil, true, log,
+ func() interface{} {
+ c.Assert(1, checker)
+ return nil
+ })
+}
+
+func (s *HelpersS) TestAssertWithError(c *check.C) {
+ checker := &MyChecker{result: false, error: "Some not so cool data provided!"}
+ log := "(?s)helpers_test\\.go:[0-9]+:.*\nhelpers_test\\.go:[0-9]+:\n" +
+ " c\\.Assert\\(1, checker, 2\\)\n" +
+ "\\.+ myobtained int = 1\n" +
+ "\\.+ myexpected int = 2\n" +
+ "\\.+ Some not so cool data provided!\n\n"
+ testHelperFailure(c, "Assert(1, checker, 2)", nil, true, log,
+ func() interface{} {
+ c.Assert(1, checker, 2)
+ return nil
+ })
+}
+
+func (s *HelpersS) TestAssertWithNilChecker(c *check.C) {
+ log := "(?s)helpers_test\\.go:[0-9]+:.*\nhelpers_test\\.go:[0-9]+:\n" +
+ " c\\.Assert\\(1, nil\\)\n" +
+ "\\.+ Assert\\(obtained, nil!\\?, \\.\\.\\.\\):\n" +
+ "\\.+ Oops\\.\\. you've provided a nil checker!\n\n"
+ testHelperFailure(c, "Assert(obtained, nil)", nil, true, log,
+ func() interface{} {
+ c.Assert(1, nil)
+ return nil
+ })
+}
+
+// -----------------------------------------------------------------------
+// Ensure that values logged work properly in some interesting cases.
+
+func (s *HelpersS) TestValueLoggingWithArrays(c *check.C) {
+ checker := &MyChecker{result: false}
+ log := "(?s)helpers_test.go:[0-9]+:.*\nhelpers_test.go:[0-9]+:\n" +
+ " return c\\.Check\\(\\[\\]byte{1, 2}, checker, \\[\\]byte{1, 3}\\)\n" +
+ "\\.+ myobtained \\[\\]uint8 = \\[\\]byte{0x1, 0x2}\n" +
+ "\\.+ myexpected \\[\\]uint8 = \\[\\]byte{0x1, 0x3}\n\n"
+ testHelperFailure(c, "Check([]byte{1}, chk, []byte{3})", false, false, log,
+ func() interface{} {
+ return c.Check([]byte{1, 2}, checker, []byte{1, 3})
+ })
+}
+
+func (s *HelpersS) TestValueLoggingWithMultiLine(c *check.C) {
+ checker := &MyChecker{result: false}
+ log := "(?s)helpers_test.go:[0-9]+:.*\nhelpers_test.go:[0-9]+:\n" +
+ " return c\\.Check\\(\"a\\\\nb\\\\n\", checker, \"a\\\\nb\\\\nc\"\\)\n" +
+ "\\.+ myobtained string = \"\" \\+\n" +
+ "\\.+ \"a\\\\n\" \\+\n" +
+ "\\.+ \"b\\\\n\"\n" +
+ "\\.+ myexpected string = \"\" \\+\n" +
+ "\\.+ \"a\\\\n\" \\+\n" +
+ "\\.+ \"b\\\\n\" \\+\n" +
+ "\\.+ \"c\"\n\n"
+ testHelperFailure(c, `Check("a\nb\n", chk, "a\nb\nc")`, false, false, log,
+ func() interface{} {
+ return c.Check("a\nb\n", checker, "a\nb\nc")
+ })
+}
+
+func (s *HelpersS) TestValueLoggingWithMultiLineException(c *check.C) {
+ // If the newline is at the end of the string, don't log as multi-line.
+ checker := &MyChecker{result: false}
+ log := "(?s)helpers_test.go:[0-9]+:.*\nhelpers_test.go:[0-9]+:\n" +
+ " return c\\.Check\\(\"a b\\\\n\", checker, \"a\\\\nb\"\\)\n" +
+ "\\.+ myobtained string = \"a b\\\\n\"\n" +
+ "\\.+ myexpected string = \"\" \\+\n" +
+ "\\.+ \"a\\\\n\" \\+\n" +
+ "\\.+ \"b\"\n\n"
+ testHelperFailure(c, `Check("a b\n", chk, "a\nb")`, false, false, log,
+ func() interface{} {
+ return c.Check("a b\n", checker, "a\nb")
+ })
+}
+
+// -----------------------------------------------------------------------
+// MakeDir() tests.
+
+type MkDirHelper struct {
+ path1 string
+ path2 string
+ isDir1 bool
+ isDir2 bool
+ isDir3 bool
+ isDir4 bool
+}
+
+func (s *MkDirHelper) SetUpSuite(c *check.C) {
+ s.path1 = c.MkDir()
+ s.isDir1 = isDir(s.path1)
+}
+
+func (s *MkDirHelper) Test(c *check.C) {
+ s.path2 = c.MkDir()
+ s.isDir2 = isDir(s.path2)
+}
+
+func (s *MkDirHelper) TearDownSuite(c *check.C) {
+ s.isDir3 = isDir(s.path1)
+ s.isDir4 = isDir(s.path2)
+}
+
+func (s *HelpersS) TestMkDir(c *check.C) {
+ helper := MkDirHelper{}
+ output := String{}
+ check.Run(&helper, &check.RunConf{Output: &output})
+ c.Assert(output.value, check.Equals, "")
+ c.Check(helper.isDir1, check.Equals, true)
+ c.Check(helper.isDir2, check.Equals, true)
+ c.Check(helper.isDir3, check.Equals, true)
+ c.Check(helper.isDir4, check.Equals, true)
+ c.Check(helper.path1, check.Not(check.Equals),
+ helper.path2)
+ c.Check(isDir(helper.path1), check.Equals, false)
+ c.Check(isDir(helper.path2), check.Equals, false)
+}
+
+func isDir(path string) bool {
+ if stat, err := os.Stat(path); err == nil {
+ return stat.IsDir()
+ }
+ return false
+}
+
+// Concurrent logging should not corrupt the underling buffer.
+// Use go test -race to detect the race in this test.
+func (s *HelpersS) TestConcurrentLogging(c *check.C) {
+ defer runtime.GOMAXPROCS(runtime.GOMAXPROCS(runtime.NumCPU()))
+ var start, stop sync.WaitGroup
+ start.Add(1)
+ for i, n := 0, runtime.NumCPU()*2; i < n; i++ {
+ stop.Add(1)
+ go func(i int) {
+ start.Wait()
+ for j := 0; j < 30; j++ {
+ c.Logf("Worker %d: line %d", i, j)
+ }
+ stop.Done()
+ }(i)
+ }
+ start.Done()
+ stop.Wait()
+}
+
+// -----------------------------------------------------------------------
+// Test the TestName function
+
+type TestNameHelper struct {
+ name1 string
+ name2 string
+ name3 string
+ name4 string
+ name5 string
+}
+
+func (s *TestNameHelper) SetUpSuite(c *check.C) { s.name1 = c.TestName() }
+func (s *TestNameHelper) SetUpTest(c *check.C) { s.name2 = c.TestName() }
+func (s *TestNameHelper) Test(c *check.C) { s.name3 = c.TestName() }
+func (s *TestNameHelper) TearDownTest(c *check.C) { s.name4 = c.TestName() }
+func (s *TestNameHelper) TearDownSuite(c *check.C) { s.name5 = c.TestName() }
+
+func (s *HelpersS) TestTestName(c *check.C) {
+ helper := TestNameHelper{}
+ output := String{}
+ check.Run(&helper, &check.RunConf{Output: &output})
+ c.Check(helper.name1, check.Equals, "")
+ c.Check(helper.name2, check.Equals, "TestNameHelper.Test")
+ c.Check(helper.name3, check.Equals, "TestNameHelper.Test")
+ c.Check(helper.name4, check.Equals, "TestNameHelper.Test")
+ c.Check(helper.name5, check.Equals, "")
+}
+
+// -----------------------------------------------------------------------
+// A couple of helper functions to test helper functions. :-)
+
+func testHelperSuccess(c *check.C, name string, expectedResult interface{}, closure func() interface{}) {
+ var result interface{}
+ defer (func() {
+ if err := recover(); err != nil {
+ panic(err)
+ }
+ checkState(c, result,
+ &expectedState{
+ name: name,
+ result: expectedResult,
+ failed: false,
+ log: "",
+ })
+ })()
+ result = closure()
+}
+
+func testHelperFailure(c *check.C, name string, expectedResult interface{}, shouldStop bool, log string, closure func() interface{}) {
+ var result interface{}
+ defer (func() {
+ if err := recover(); err != nil {
+ panic(err)
+ }
+ checkState(c, result,
+ &expectedState{
+ name: name,
+ result: expectedResult,
+ failed: true,
+ log: log,
+ })
+ })()
+ result = closure()
+ if shouldStop {
+ c.Logf("%s didn't stop when it should", name)
+ }
+}
diff --git a/Godeps/_workspace/src/gopkg.in/check.v1/printer.go b/Godeps/_workspace/src/gopkg.in/check.v1/printer.go
new file mode 100644
index 000000000..e0f7557b5
--- /dev/null
+++ b/Godeps/_workspace/src/gopkg.in/check.v1/printer.go
@@ -0,0 +1,168 @@
+package check
+
+import (
+ "bytes"
+ "go/ast"
+ "go/parser"
+ "go/printer"
+ "go/token"
+ "os"
+)
+
+func indent(s, with string) (r string) {
+ eol := true
+ for i := 0; i != len(s); i++ {
+ c := s[i]
+ switch {
+ case eol && c == '\n' || c == '\r':
+ case c == '\n' || c == '\r':
+ eol = true
+ case eol:
+ eol = false
+ s = s[:i] + with + s[i:]
+ i += len(with)
+ }
+ }
+ return s
+}
+
+func printLine(filename string, line int) (string, error) {
+ fset := token.NewFileSet()
+ file, err := os.Open(filename)
+ if err != nil {
+ return "", err
+ }
+ fnode, err := parser.ParseFile(fset, filename, file, parser.ParseComments)
+ if err != nil {
+ return "", err
+ }
+ config := &printer.Config{Mode: printer.UseSpaces, Tabwidth: 4}
+ lp := &linePrinter{fset: fset, fnode: fnode, line: line, config: config}
+ ast.Walk(lp, fnode)
+ result := lp.output.Bytes()
+ // Comments leave \n at the end.
+ n := len(result)
+ for n > 0 && result[n-1] == '\n' {
+ n--
+ }
+ return string(result[:n]), nil
+}
+
+type linePrinter struct {
+ config *printer.Config
+ fset *token.FileSet
+ fnode *ast.File
+ line int
+ output bytes.Buffer
+ stmt ast.Stmt
+}
+
+func (lp *linePrinter) emit() bool {
+ if lp.stmt != nil {
+ lp.trim(lp.stmt)
+ lp.printWithComments(lp.stmt)
+ lp.stmt = nil
+ return true
+ }
+ return false
+}
+
+func (lp *linePrinter) printWithComments(n ast.Node) {
+ nfirst := lp.fset.Position(n.Pos()).Line
+ nlast := lp.fset.Position(n.End()).Line
+ for _, g := range lp.fnode.Comments {
+ cfirst := lp.fset.Position(g.Pos()).Line
+ clast := lp.fset.Position(g.End()).Line
+ if clast == nfirst-1 && lp.fset.Position(n.Pos()).Column == lp.fset.Position(g.Pos()).Column {
+ for _, c := range g.List {
+ lp.output.WriteString(c.Text)
+ lp.output.WriteByte('\n')
+ }
+ }
+ if cfirst >= nfirst && cfirst <= nlast && n.End() <= g.List[0].Slash {
+ // The printer will not include the comment if it starts past
+ // the node itself. Trick it into printing by overlapping the
+ // slash with the end of the statement.
+ g.List[0].Slash = n.End() - 1
+ }
+ }
+ node := &printer.CommentedNode{n, lp.fnode.Comments}
+ lp.config.Fprint(&lp.output, lp.fset, node)
+}
+
+func (lp *linePrinter) Visit(n ast.Node) (w ast.Visitor) {
+ if n == nil {
+ if lp.output.Len() == 0 {
+ lp.emit()
+ }
+ return nil
+ }
+ first := lp.fset.Position(n.Pos()).Line
+ last := lp.fset.Position(n.End()).Line
+ if first <= lp.line && last >= lp.line {
+ // Print the innermost statement containing the line.
+ if stmt, ok := n.(ast.Stmt); ok {
+ if _, ok := n.(*ast.BlockStmt); !ok {
+ lp.stmt = stmt
+ }
+ }
+ if first == lp.line && lp.emit() {
+ return nil
+ }
+ return lp
+ }
+ return nil
+}
+
+func (lp *linePrinter) trim(n ast.Node) bool {
+ stmt, ok := n.(ast.Stmt)
+ if !ok {
+ return true
+ }
+ line := lp.fset.Position(n.Pos()).Line
+ if line != lp.line {
+ return false
+ }
+ switch stmt := stmt.(type) {
+ case *ast.IfStmt:
+ stmt.Body = lp.trimBlock(stmt.Body)
+ case *ast.SwitchStmt:
+ stmt.Body = lp.trimBlock(stmt.Body)
+ case *ast.TypeSwitchStmt:
+ stmt.Body = lp.trimBlock(stmt.Body)
+ case *ast.CaseClause:
+ stmt.Body = lp.trimList(stmt.Body)
+ case *ast.CommClause:
+ stmt.Body = lp.trimList(stmt.Body)
+ case *ast.BlockStmt:
+ stmt.List = lp.trimList(stmt.List)
+ }
+ return true
+}
+
+func (lp *linePrinter) trimBlock(stmt *ast.BlockStmt) *ast.BlockStmt {
+ if !lp.trim(stmt) {
+ return lp.emptyBlock(stmt)
+ }
+ stmt.Rbrace = stmt.Lbrace
+ return stmt
+}
+
+func (lp *linePrinter) trimList(stmts []ast.Stmt) []ast.Stmt {
+ for i := 0; i != len(stmts); i++ {
+ if !lp.trim(stmts[i]) {
+ stmts[i] = lp.emptyStmt(stmts[i])
+ break
+ }
+ }
+ return stmts
+}
+
+func (lp *linePrinter) emptyStmt(n ast.Node) *ast.ExprStmt {
+ return &ast.ExprStmt{&ast.Ellipsis{n.Pos(), nil}}
+}
+
+func (lp *linePrinter) emptyBlock(n ast.Node) *ast.BlockStmt {
+ p := n.Pos()
+ return &ast.BlockStmt{p, []ast.Stmt{lp.emptyStmt(n)}, p}
+}
diff --git a/Godeps/_workspace/src/gopkg.in/check.v1/printer_test.go b/Godeps/_workspace/src/gopkg.in/check.v1/printer_test.go
new file mode 100644
index 000000000..538b2d52e
--- /dev/null
+++ b/Godeps/_workspace/src/gopkg.in/check.v1/printer_test.go
@@ -0,0 +1,104 @@
+package check_test
+
+import (
+ . "gopkg.in/check.v1"
+)
+
+var _ = Suite(&PrinterS{})
+
+type PrinterS struct{}
+
+func (s *PrinterS) TestCountSuite(c *C) {
+ suitesRun += 1
+}
+
+var printTestFuncLine int
+
+func init() {
+ printTestFuncLine = getMyLine() + 3
+}
+
+func printTestFunc() {
+ println(1) // Comment1
+ if 2 == 2 { // Comment2
+ println(3) // Comment3
+ }
+ switch 5 {
+ case 6: println(6) // Comment6
+ println(7)
+ }
+ switch interface{}(9).(type) {// Comment9
+ case int: println(10)
+ println(11)
+ }
+ select {
+ case <-(chan bool)(nil): println(14)
+ println(15)
+ default: println(16)
+ println(17)
+ }
+ println(19,
+ 20)
+ _ = func() { println(21)
+ println(22)
+ }
+ println(24, func() {
+ println(25)
+ })
+ // Leading comment
+ // with multiple lines.
+ println(29) // Comment29
+}
+
+var printLineTests = []struct {
+ line int
+ output string
+}{
+ {1, "println(1) // Comment1"},
+ {2, "if 2 == 2 { // Comment2\n ...\n}"},
+ {3, "println(3) // Comment3"},
+ {5, "switch 5 {\n...\n}"},
+ {6, "case 6:\n println(6) // Comment6\n ..."},
+ {7, "println(7)"},
+ {9, "switch interface{}(9).(type) { // Comment9\n...\n}"},
+ {10, "case int:\n println(10)\n ..."},
+ {14, "case <-(chan bool)(nil):\n println(14)\n ..."},
+ {15, "println(15)"},
+ {16, "default:\n println(16)\n ..."},
+ {17, "println(17)"},
+ {19, "println(19,\n 20)"},
+ {20, "println(19,\n 20)"},
+ {21, "_ = func() {\n println(21)\n println(22)\n}"},
+ {22, "println(22)"},
+ {24, "println(24, func() {\n println(25)\n})"},
+ {25, "println(25)"},
+ {26, "println(24, func() {\n println(25)\n})"},
+ {29, "// Leading comment\n// with multiple lines.\nprintln(29) // Comment29"},
+}
+
+func (s *PrinterS) TestPrintLine(c *C) {
+ for _, test := range printLineTests {
+ output, err := PrintLine("printer_test.go", printTestFuncLine+test.line)
+ c.Assert(err, IsNil)
+ c.Assert(output, Equals, test.output)
+ }
+}
+
+var indentTests = []struct {
+ in, out string
+}{
+ {"", ""},
+ {"\n", "\n"},
+ {"a", ">>>a"},
+ {"a\n", ">>>a\n"},
+ {"a\nb", ">>>a\n>>>b"},
+ {" ", ">>> "},
+}
+
+func (s *PrinterS) TestIndent(c *C) {
+ for _, test := range indentTests {
+ out := Indent(test.in, ">>>")
+ c.Assert(out, Equals, test.out)
+ }
+
+}
diff --git a/Godeps/_workspace/src/gopkg.in/check.v1/run.go b/Godeps/_workspace/src/gopkg.in/check.v1/run.go
new file mode 100644
index 000000000..da8fd7987
--- /dev/null
+++ b/Godeps/_workspace/src/gopkg.in/check.v1/run.go
@@ -0,0 +1,175 @@
+package check
+
+import (
+ "bufio"
+ "flag"
+ "fmt"
+ "os"
+ "testing"
+ "time"
+)
+
+// -----------------------------------------------------------------------
+// Test suite registry.
+
+var allSuites []interface{}
+
+// Suite registers the given value as a test suite to be run. Any methods
+// starting with the Test prefix in the given value will be considered as
+// a test method.
+func Suite(suite interface{}) interface{} {
+ allSuites = append(allSuites, suite)
+ return suite
+}
+
+// -----------------------------------------------------------------------
+// Public running interface.
+
+var (
+ oldFilterFlag = flag.String("gocheck.f", "", "Regular expression selecting which tests and/or suites to run")
+ oldVerboseFlag = flag.Bool("gocheck.v", false, "Verbose mode")
+ oldStreamFlag = flag.Bool("gocheck.vv", false, "Super verbose mode (disables output caching)")
+ oldBenchFlag = flag.Bool("gocheck.b", false, "Run benchmarks")
+ oldBenchTime = flag.Duration("gocheck.btime", 1*time.Second, "approximate run time for each benchmark")
+ oldListFlag = flag.Bool("gocheck.list", false, "List the names of all tests that will be run")
+ oldWorkFlag = flag.Bool("gocheck.work", false, "Display and do not remove the test working directory")
+
+ newFilterFlag = flag.String("check.f", "", "Regular expression selecting which tests and/or suites to run")
+ newVerboseFlag = flag.Bool("check.v", false, "Verbose mode")
+ newStreamFlag = flag.Bool("check.vv", false, "Super verbose mode (disables output caching)")
+ newBenchFlag = flag.Bool("check.b", false, "Run benchmarks")
+ newBenchTime = flag.Duration("check.btime", 1*time.Second, "approximate run time for each benchmark")
+ newBenchMem = flag.Bool("check.bmem", false, "Report memory benchmarks")
+ newListFlag = flag.Bool("check.list", false, "List the names of all tests that will be run")
+ newWorkFlag = flag.Bool("check.work", false, "Display and do not remove the test working directory")
+)
+
+// TestingT runs all test suites registered with the Suite function,
+// printing results to stdout, and reporting any failures back to
+// the "testing" package.
+func TestingT(testingT *testing.T) {
+ benchTime := *newBenchTime
+ if benchTime == 1*time.Second {
+ benchTime = *oldBenchTime
+ }
+ conf := &RunConf{
+ Filter: *oldFilterFlag + *newFilterFlag,
+ Verbose: *oldVerboseFlag || *newVerboseFlag,
+ Stream: *oldStreamFlag || *newStreamFlag,
+ Benchmark: *oldBenchFlag || *newBenchFlag,
+ BenchmarkTime: benchTime,
+ BenchmarkMem: *newBenchMem,
+ KeepWorkDir: *oldWorkFlag || *newWorkFlag,
+ }
+ if *oldListFlag || *newListFlag {
+ w := bufio.NewWriter(os.Stdout)
+ for _, name := range ListAll(conf) {
+ fmt.Fprintln(w, name)
+ }
+ w.Flush()
+ return
+ }
+ result := RunAll(conf)
+ println(result.String())
+ if !result.Passed() {
+ testingT.Fail()
+ }
+}
+
+// RunAll runs all test suites registered with the Suite function, using the
+// provided run configuration.
+func RunAll(runConf *RunConf) *Result {
+ result := Result{}
+ for _, suite := range allSuites {
+ result.Add(Run(suite, runConf))
+ }
+ return &result
+}
+
+// Run runs the provided test suite using the provided run configuration.
+func Run(suite interface{}, runConf *RunConf) *Result {
+ runner := newSuiteRunner(suite, runConf)
+ return runner.run()
+}
+
+// ListAll returns the names of all the test functions registered with the
+// Suite function that will be run with the provided run configuration.
+func ListAll(runConf *RunConf) []string {
+ var names []string
+ for _, suite := range allSuites {
+ names = append(names, List(suite, runConf)...)
+ }
+ return names
+}
+
+// List returns the names of the test functions in the given
+// suite that will be run with the provided run configuration.
+func List(suite interface{}, runConf *RunConf) []string {
+ var names []string
+ runner := newSuiteRunner(suite, runConf)
+ for _, t := range runner.tests {
+ names = append(names, t.String())
+ }
+ return names
+}
+
+// -----------------------------------------------------------------------
+// Result methods.
+
+func (r *Result) Add(other *Result) {
+ r.Succeeded += other.Succeeded
+ r.Skipped += other.Skipped
+ r.Failed += other.Failed
+ r.Panicked += other.Panicked
+ r.FixturePanicked += other.FixturePanicked
+ r.ExpectedFailures += other.ExpectedFailures
+ r.Missed += other.Missed
+ if r.WorkDir != "" && other.WorkDir != "" {
+ r.WorkDir += ":" + other.WorkDir
+ } else if other.WorkDir != "" {
+ r.WorkDir = other.WorkDir
+ }
+}
+
+func (r *Result) Passed() bool {
+ return (r.Failed == 0 && r.Panicked == 0 &&
+ r.FixturePanicked == 0 && r.Missed == 0 &&
+ r.RunError == nil)
+}
+
+func (r *Result) String() string {
+ if r.RunError != nil {
+ return "ERROR: " + r.RunError.Error()
+ }
+
+ var value string
+ if r.Failed == 0 && r.Panicked == 0 && r.FixturePanicked == 0 &&
+ r.Missed == 0 {
+ value = "OK: "
+ } else {
+ value = "OOPS: "
+ }
+ value += fmt.Sprintf("%d passed", r.Succeeded)
+ if r.Skipped != 0 {
+ value += fmt.Sprintf(", %d skipped", r.Skipped)
+ }
+ if r.ExpectedFailures != 0 {
+ value += fmt.Sprintf(", %d expected failures", r.ExpectedFailures)
+ }
+ if r.Failed != 0 {
+ value += fmt.Sprintf(", %d FAILED", r.Failed)
+ }
+ if r.Panicked != 0 {
+ value += fmt.Sprintf(", %d PANICKED", r.Panicked)
+ }
+ if r.FixturePanicked != 0 {
+ value += fmt.Sprintf(", %d FIXTURE-PANICKED", r.FixturePanicked)
+ }
+ if r.Missed != 0 {
+ value += fmt.Sprintf(", %d MISSED", r.Missed)
+ }
+ if r.WorkDir != "" {
+ value += "\nWORK=" + r.WorkDir
+ }
+ return value
+}
diff --git a/Godeps/_workspace/src/gopkg.in/check.v1/run_test.go b/Godeps/_workspace/src/gopkg.in/check.v1/run_test.go
new file mode 100644
index 000000000..f41fffc3f
--- /dev/null
+++ b/Godeps/_workspace/src/gopkg.in/check.v1/run_test.go
@@ -0,0 +1,419 @@
+// These tests verify the test running logic.
+
+package check_test
+
+import (
+ "errors"
+ . "gopkg.in/check.v1"
+ "os"
+ "sync"
+)
+
+var runnerS = Suite(&RunS{})
+
+type RunS struct{}
+
+func (s *RunS) TestCountSuite(c *C) {
+ suitesRun += 1
+}
+
+// -----------------------------------------------------------------------
+// Tests ensuring result counting works properly.
+
+func (s *RunS) TestSuccess(c *C) {
+ output := String{}
+ result := Run(&SuccessHelper{}, &RunConf{Output: &output})
+ c.Check(result.Succeeded, Equals, 1)
+ c.Check(result.Failed, Equals, 0)
+ c.Check(result.Skipped, Equals, 0)
+ c.Check(result.Panicked, Equals, 0)
+ c.Check(result.FixturePanicked, Equals, 0)
+ c.Check(result.Missed, Equals, 0)
+ c.Check(result.RunError, IsNil)
+}
+
+func (s *RunS) TestFailure(c *C) {
+ output := String{}
+ result := Run(&FailHelper{}, &RunConf{Output: &output})
+ c.Check(result.Succeeded, Equals, 0)
+ c.Check(result.Failed, Equals, 1)
+ c.Check(result.Skipped, Equals, 0)
+ c.Check(result.Panicked, Equals, 0)
+ c.Check(result.FixturePanicked, Equals, 0)
+ c.Check(result.Missed, Equals, 0)
+ c.Check(result.RunError, IsNil)
+}
+
+func (s *RunS) TestFixture(c *C) {
+ output := String{}
+ result := Run(&FixtureHelper{}, &RunConf{Output: &output})
+ c.Check(result.Succeeded, Equals, 2)
+ c.Check(result.Failed, Equals, 0)
+ c.Check(result.Skipped, Equals, 0)
+ c.Check(result.Panicked, Equals, 0)
+ c.Check(result.FixturePanicked, Equals, 0)
+ c.Check(result.Missed, Equals, 0)
+ c.Check(result.RunError, IsNil)
+}
+
+func (s *RunS) TestPanicOnTest(c *C) {
+ output := String{}
+ helper := &FixtureHelper{panicOn: "Test1"}
+ result := Run(helper, &RunConf{Output: &output})
+ c.Check(result.Succeeded, Equals, 1)
+ c.Check(result.Failed, Equals, 0)
+ c.Check(result.Skipped, Equals, 0)
+ c.Check(result.Panicked, Equals, 1)
+ c.Check(result.FixturePanicked, Equals, 0)
+ c.Check(result.Missed, Equals, 0)
+ c.Check(result.RunError, IsNil)
+}
+
+func (s *RunS) TestPanicOnSetUpTest(c *C) {
+ output := String{}
+ helper := &FixtureHelper{panicOn: "SetUpTest"}
+ result := Run(helper, &RunConf{Output: &output})
+ c.Check(result.Succeeded, Equals, 0)
+ c.Check(result.Failed, Equals, 0)
+ c.Check(result.Skipped, Equals, 0)
+ c.Check(result.Panicked, Equals, 0)
+ c.Check(result.FixturePanicked, Equals, 1)
+ c.Check(result.Missed, Equals, 2)
+ c.Check(result.RunError, IsNil)
+}
+
+func (s *RunS) TestPanicOnSetUpSuite(c *C) {
+ output := String{}
+ helper := &FixtureHelper{panicOn: "SetUpSuite"}
+ result := Run(helper, &RunConf{Output: &output})
+ c.Check(result.Succeeded, Equals, 0)
+ c.Check(result.Failed, Equals, 0)
+ c.Check(result.Skipped, Equals, 0)
+ c.Check(result.Panicked, Equals, 0)
+ c.Check(result.FixturePanicked, Equals, 1)
+ c.Check(result.Missed, Equals, 2)
+ c.Check(result.RunError, IsNil)
+}
+
+// -----------------------------------------------------------------------
+// Check result aggregation.
+
+func (s *RunS) TestAdd(c *C) {
+ result := &Result{
+ Succeeded: 1,
+ Skipped: 2,
+ Failed: 3,
+ Panicked: 4,
+ FixturePanicked: 5,
+ Missed: 6,
+ ExpectedFailures: 7,
+ }
+ result.Add(&Result{
+ Succeeded: 10,
+ Skipped: 20,
+ Failed: 30,
+ Panicked: 40,
+ FixturePanicked: 50,
+ Missed: 60,
+ ExpectedFailures: 70,
+ })
+ c.Check(result.Succeeded, Equals, 11)
+ c.Check(result.Skipped, Equals, 22)
+ c.Check(result.Failed, Equals, 33)
+ c.Check(result.Panicked, Equals, 44)
+ c.Check(result.FixturePanicked, Equals, 55)
+ c.Check(result.Missed, Equals, 66)
+ c.Check(result.ExpectedFailures, Equals, 77)
+ c.Check(result.RunError, IsNil)
+}
+
+// -----------------------------------------------------------------------
+// Check the Passed() method.
+
+func (s *RunS) TestPassed(c *C) {
+ c.Assert((&Result{}).Passed(), Equals, true)
+ c.Assert((&Result{Succeeded: 1}).Passed(), Equals, true)
+ c.Assert((&Result{Skipped: 1}).Passed(), Equals, true)
+ c.Assert((&Result{Failed: 1}).Passed(), Equals, false)
+ c.Assert((&Result{Panicked: 1}).Passed(), Equals, false)
+ c.Assert((&Result{FixturePanicked: 1}).Passed(), Equals, false)
+ c.Assert((&Result{Missed: 1}).Passed(), Equals, false)
+ c.Assert((&Result{RunError: errors.New("!")}).Passed(), Equals, false)
+}
+
+// -----------------------------------------------------------------------
+// Check that result printing is working correctly.
+
+func (s *RunS) TestPrintSuccess(c *C) {
+ result := &Result{Succeeded: 5}
+ c.Check(result.String(), Equals, "OK: 5 passed")
+}
+
+func (s *RunS) TestPrintFailure(c *C) {
+ result := &Result{Failed: 5}
+ c.Check(result.String(), Equals, "OOPS: 0 passed, 5 FAILED")
+}
+
+func (s *RunS) TestPrintSkipped(c *C) {
+ result := &Result{Skipped: 5}
+ c.Check(result.String(), Equals, "OK: 0 passed, 5 skipped")
+}
+
+func (s *RunS) TestPrintExpectedFailures(c *C) {
+ result := &Result{ExpectedFailures: 5}
+ c.Check(result.String(), Equals, "OK: 0 passed, 5 expected failures")
+}
+
+func (s *RunS) TestPrintPanicked(c *C) {
+ result := &Result{Panicked: 5}
+ c.Check(result.String(), Equals, "OOPS: 0 passed, 5 PANICKED")
+}
+
+func (s *RunS) TestPrintFixturePanicked(c *C) {
+ result := &Result{FixturePanicked: 5}
+ c.Check(result.String(), Equals, "OOPS: 0 passed, 5 FIXTURE-PANICKED")
+}
+
+func (s *RunS) TestPrintMissed(c *C) {
+ result := &Result{Missed: 5}
+ c.Check(result.String(), Equals, "OOPS: 0 passed, 5 MISSED")
+}
+
+func (s *RunS) TestPrintAll(c *C) {
+ result := &Result{Succeeded: 1, Skipped: 2, ExpectedFailures: 3,
+ Panicked: 4, FixturePanicked: 5, Missed: 6}
+ c.Check(result.String(), Equals,
+ "OOPS: 1 passed, 2 skipped, 3 expected failures, 4 PANICKED, "+
+ "5 FIXTURE-PANICKED, 6 MISSED")
+}
+
+func (s *RunS) TestPrintRunError(c *C) {
+ result := &Result{Succeeded: 1, Failed: 1,
+ RunError: errors.New("Kaboom!")}
+ c.Check(result.String(), Equals, "ERROR: Kaboom!")
+}
+
+// -----------------------------------------------------------------------
+// Verify that the method pattern flag works correctly.
+
+func (s *RunS) TestFilterTestName(c *C) {
+ helper := FixtureHelper{}
+ output := String{}
+ runConf := RunConf{Output: &output, Filter: "Test[91]"}
+ Run(&helper, &runConf)
+ c.Check(helper.calls[0], Equals, "SetUpSuite")
+ c.Check(helper.calls[1], Equals, "SetUpTest")
+ c.Check(helper.calls[2], Equals, "Test1")
+ c.Check(helper.calls[3], Equals, "TearDownTest")
+ c.Check(helper.calls[4], Equals, "TearDownSuite")
+ c.Check(len(helper.calls), Equals, 5)
+}
+
+func (s *RunS) TestFilterTestNameWithAll(c *C) {
+ helper := FixtureHelper{}
+ output := String{}
+ runConf := RunConf{Output: &output, Filter: ".*"}
+ Run(&helper, &runConf)
+ c.Check(helper.calls[0], Equals, "SetUpSuite")
+ c.Check(helper.calls[1], Equals, "SetUpTest")
+ c.Check(helper.calls[2], Equals, "Test1")
+ c.Check(helper.calls[3], Equals, "TearDownTest")
+ c.Check(helper.calls[4], Equals, "SetUpTest")
+ c.Check(helper.calls[5], Equals, "Test2")
+ c.Check(helper.calls[6], Equals, "TearDownTest")
+ c.Check(helper.calls[7], Equals, "TearDownSuite")
+ c.Check(len(helper.calls), Equals, 8)
+}
+
+func (s *RunS) TestFilterSuiteName(c *C) {
+ helper := FixtureHelper{}
+ output := String{}
+ runConf := RunConf{Output: &output, Filter: "FixtureHelper"}
+ Run(&helper, &runConf)
+ c.Check(helper.calls[0], Equals, "SetUpSuite")
+ c.Check(helper.calls[1], Equals, "SetUpTest")
+ c.Check(helper.calls[2], Equals, "Test1")
+ c.Check(helper.calls[3], Equals, "TearDownTest")
+ c.Check(helper.calls[4], Equals, "SetUpTest")
+ c.Check(helper.calls[5], Equals, "Test2")
+ c.Check(helper.calls[6], Equals, "TearDownTest")
+ c.Check(helper.calls[7], Equals, "TearDownSuite")
+ c.Check(len(helper.calls), Equals, 8)
+}
+
+func (s *RunS) TestFilterSuiteNameAndTestName(c *C) {
+ helper := FixtureHelper{}
+ output := String{}
+ runConf := RunConf{Output: &output, Filter: "FixtureHelper\\.Test2"}
+ Run(&helper, &runConf)
+ c.Check(helper.calls[0], Equals, "SetUpSuite")
+ c.Check(helper.calls[1], Equals, "SetUpTest")
+ c.Check(helper.calls[2], Equals, "Test2")
+ c.Check(helper.calls[3], Equals, "TearDownTest")
+ c.Check(helper.calls[4], Equals, "TearDownSuite")
+ c.Check(len(helper.calls), Equals, 5)
+}
+
+func (s *RunS) TestFilterAllOut(c *C) {
+ helper := FixtureHelper{}
+ output := String{}
+ runConf := RunConf{Output: &output, Filter: "NotFound"}
+ Run(&helper, &runConf)
+ c.Check(len(helper.calls), Equals, 0)
+}
+
+func (s *RunS) TestRequirePartialMatch(c *C) {
+ helper := FixtureHelper{}
+ output := String{}
+ runConf := RunConf{Output: &output, Filter: "est"}
+ Run(&helper, &runConf)
+ c.Check(len(helper.calls), Equals, 8)
+}
+
+func (s *RunS) TestFilterError(c *C) {
+ helper := FixtureHelper{}
+ output := String{}
+ runConf := RunConf{Output: &output, Filter: "]["}
+ result := Run(&helper, &runConf)
+ c.Check(result.String(), Equals,
+ "ERROR: Bad filter expression: error parsing regexp: missing closing ]: `[`")
+ c.Check(len(helper.calls), Equals, 0)
+}
+
+// -----------------------------------------------------------------------
+// Verify that List works correctly.
+
+func (s *RunS) TestListFiltered(c *C) {
+ names := List(&FixtureHelper{}, &RunConf{Filter: "1"})
+ c.Assert(names, DeepEquals, []string{
+ "FixtureHelper.Test1",
+ })
+}
+
+func (s *RunS) TestList(c *C) {
+ names := List(&FixtureHelper{}, &RunConf{})
+ c.Assert(names, DeepEquals, []string{
+ "FixtureHelper.Test1",
+ "FixtureHelper.Test2",
+ })
+}
+
+// -----------------------------------------------------------------------
+// Verify that verbose mode prints tests which pass as well.
+
+func (s *RunS) TestVerboseMode(c *C) {
+ helper := FixtureHelper{}
+ output := String{}
+ runConf := RunConf{Output: &output, Verbose: true}
+ Run(&helper, &runConf)
+
+ expected := "PASS: check_test\\.go:[0-9]+: FixtureHelper\\.Test1\t *[.0-9]+s\n" +
+ "PASS: check_test\\.go:[0-9]+: FixtureHelper\\.Test2\t *[.0-9]+s\n"
+
+ c.Assert(output.value, Matches, expected)
+}
+
+func (s *RunS) TestVerboseModeWithFailBeforePass(c *C) {
+ helper := FixtureHelper{panicOn: "Test1"}
+ output := String{}
+ runConf := RunConf{Output: &output, Verbose: true}
+ Run(&helper, &runConf)
+
+ expected := "(?s).*PANIC.*\n-+\n" + // Should have an extra line.
+ "PASS: check_test\\.go:[0-9]+: FixtureHelper\\.Test2\t *[.0-9]+s\n"
+
+ c.Assert(output.value, Matches, expected)
+}
+
+// -----------------------------------------------------------------------
+// Verify the stream output mode. In this mode there's no output caching.
+
+type StreamHelper struct {
+ l2 sync.Mutex
+ l3 sync.Mutex
+}
+
+func (s *StreamHelper) SetUpSuite(c *C) {
+ c.Log("0")
+}
+
+func (s *StreamHelper) Test1(c *C) {
+ c.Log("1")
+ s.l2.Lock()
+ s.l3.Lock()
+ go func() {
+ s.l2.Lock() // Wait for "2".
+ c.Log("3")
+ s.l3.Unlock()
+ }()
+}
+
+func (s *StreamHelper) Test2(c *C) {
+ c.Log("2")
+ s.l2.Unlock()
+ s.l3.Lock() // Wait for "3".
+ c.Fail()
+ c.Log("4")
+}
+
+func (s *RunS) TestStreamMode(c *C) {
+ helper := &StreamHelper{}
+ output := String{}
+ runConf := RunConf{Output: &output, Stream: true}
+ Run(helper, &runConf)
+
+ expected := "START: run_test\\.go:[0-9]+: StreamHelper\\.SetUpSuite\n0\n" +
+ "PASS: run_test\\.go:[0-9]+: StreamHelper\\.SetUpSuite\t *[.0-9]+s\n\n" +
+ "START: run_test\\.go:[0-9]+: StreamHelper\\.Test1\n1\n" +
+ "PASS: run_test\\.go:[0-9]+: StreamHelper\\.Test1\t *[.0-9]+s\n\n" +
+ "START: run_test\\.go:[0-9]+: StreamHelper\\.Test2\n2\n3\n4\n" +
+ "FAIL: run_test\\.go:[0-9]+: StreamHelper\\.Test2\n\n"
+
+ c.Assert(output.value, Matches, expected)
+}
+
+type StreamMissHelper struct{}
+
+func (s *StreamMissHelper) SetUpSuite(c *C) {
+ c.Log("0")
+ c.Fail()
+}
+
+func (s *StreamMissHelper) Test1(c *C) {
+ c.Log("1")
+}
+
+func (s *RunS) TestStreamModeWithMiss(c *C) {
+ helper := &StreamMissHelper{}
+ output := String{}
+ runConf := RunConf{Output: &output, Stream: true}
+ Run(helper, &runConf)
+
+ expected := "START: run_test\\.go:[0-9]+: StreamMissHelper\\.SetUpSuite\n0\n" +
+ "FAIL: run_test\\.go:[0-9]+: StreamMissHelper\\.SetUpSuite\n\n" +
+ "START: run_test\\.go:[0-9]+: StreamMissHelper\\.Test1\n" +
+ "MISS: run_test\\.go:[0-9]+: StreamMissHelper\\.Test1\n\n"
+
+ c.Assert(output.value, Matches, expected)
+}
+
+// -----------------------------------------------------------------------
+// Verify that that the keep work dir request indeed does so.
+
+type WorkDirSuite struct {}
+
+func (s *WorkDirSuite) Test(c *C) {
+ c.MkDir()
+}
+
+func (s *RunS) TestKeepWorkDir(c *C) {
+ output := String{}
+ runConf := RunConf{Output: &output, Verbose: true, KeepWorkDir: true}
+ result := Run(&WorkDirSuite{}, &runConf)
+
+ c.Assert(result.String(), Matches, ".*\nWORK=" + result.WorkDir)
+
+ stat, err := os.Stat(result.WorkDir)
+ c.Assert(err, IsNil)
+ c.Assert(stat.IsDir(), Equals, true)
+}
diff --git a/Godeps/_workspace/src/gopkg.in/fatih/set.v0/.travis.yml b/Godeps/_workspace/src/gopkg.in/fatih/set.v0/.travis.yml
new file mode 100644
index 000000000..b05e4c53f
--- /dev/null
+++ b/Godeps/_workspace/src/gopkg.in/fatih/set.v0/.travis.yml
@@ -0,0 +1,3 @@
+language: go
+go: 1.2
+
diff --git a/Godeps/_workspace/src/gopkg.in/fatih/set.v0/LICENSE.md b/Godeps/_workspace/src/gopkg.in/fatih/set.v0/LICENSE.md
new file mode 100644
index 000000000..25fdaf639
--- /dev/null
+++ b/Godeps/_workspace/src/gopkg.in/fatih/set.v0/LICENSE.md
@@ -0,0 +1,20 @@
+The MIT License (MIT)
+
+Copyright (c) 2013 Fatih Arslan
+
+Permission is hereby granted, free of charge, to any person obtaining a copy of
+this software and associated documentation files (the "Software"), to deal in
+the Software without restriction, including without limitation the rights to
+use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
+the Software, and to permit persons to whom the Software is furnished to do so,
+subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in all
+copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
+FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
+COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
+IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
+CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
diff --git a/Godeps/_workspace/src/gopkg.in/fatih/set.v0/README.md b/Godeps/_workspace/src/gopkg.in/fatih/set.v0/README.md
new file mode 100644
index 000000000..23afdd98d
--- /dev/null
+++ b/Godeps/_workspace/src/gopkg.in/fatih/set.v0/README.md
@@ -0,0 +1,245 @@
+# Set [![GoDoc](http://img.shields.io/badge/go-documentation-blue.svg?style=flat-square)](https://godoc.org/gopkg.in/fatih/set.v0) [![Build Status](http://img.shields.io/travis/fatih/set.svg?style=flat-square)](https://travis-ci.org/fatih/set)
+
+Set is a basic and simple, hash-based, **Set** data structure implementation
+in Go (Golang).
+
+Set provides both threadsafe and non-threadsafe implementations of a generic
+set data structure. The thread safety encompasses all operations on one set.
+Operations on multiple sets are consistent in that the elements of each set
+used was valid at exactly one point in time between the start and the end of
+the operation. Because it's thread safe, you can use it concurrently with your
+goroutines.
+
+For usage see examples below or click on the godoc badge.
+
+## Install and Usage
+
+Install the package with:
+
+```bash
+go get gopkg.in/fatih/set.v0
+```
+
+Import it with:
+
+```go
+import "gopkg.in/fatih/set.v0"
+```
+
+and use `set` as the package name inside the code.
+
+## Examples
+
+#### Initialization of a new Set
+
+```go
+
+// create a set with zero items
+s := set.New()
+s := set.NewNonTS() // non thread-safe version
+
+// ... or with some initial values
+s := set.New("istanbul", "frankfurt", 30.123, "san francisco", 1234)
+s := set.NewNonTS("kenya", "ethiopia", "sumatra")
+
+```
+
+#### Basic Operations
+
+```go
+// add items
+s.Add("istanbul")
+s.Add("istanbul") // nothing happens if you add duplicate item
+
+// add multiple items
+s.Add("ankara", "san francisco", 3.14)
+
+// remove item
+s.Remove("frankfurt")
+s.Remove("frankfurt") // nothing happes if you remove a nonexisting item
+
+// remove multiple items
+s.Remove("barcelona", 3.14, "ankara")
+
+// removes an arbitary item and return it
+item := s.Pop()
+
+// create a new copy
+other := s.Copy()
+
+// remove all items
+s.Clear()
+
+// number of items in the set
+len := s.Size()
+
+// return a list of items
+items := s.List()
+
+// string representation of set
+fmt.Printf("set is %s", s.String())
+
+```
+
+#### Check Operations
+
+```go
+// check for set emptiness, returns true if set is empty
+s.IsEmpty()
+
+// check for a single item exist
+s.Has("istanbul")
+
+// ... or for multiple items. This will return true if all of the items exist.
+s.Has("istanbul", "san francisco", 3.14)
+
+// create two sets for the following checks...
+s := s.New("1", "2", "3", "4", "5")
+t := s.New("1", "2", "3")
+
+
+// check if they are the same
+if !s.IsEqual(t) {
+ fmt.Println("s is not equal to t")
+}
+
+// if s contains all elements of t
+if s.IsSubset(t) {
+ fmt.Println("t is a subset of s")
+}
+
+// ... or if s is a superset of t
+if t.IsSuperset(s) {
+ fmt.Println("s is a superset of t")
+}
+
+
+```
+
+#### Set Operations
+
+
+```go
+// let us initialize two sets with some values
+a := set.New("ankara", "berlin", "san francisco")
+b := set.New("frankfurt", "berlin")
+
+// creates a new set with the items in a and b combined.
+// [frankfurt, berlin, ankara, san francisco]
+c := set.Union(a, b)
+
+// contains items which is in both a and b
+// [berlin]
+c := set.Intersection(a, b)
+
+// contains items which are in a but not in b
+// [ankara, san francisco]
+c := set.Difference(a, b)
+
+// contains items which are in one of either, but not in both.
+// [frankfurt, ankara, san francisco]
+c := set.SymmetricDifference(a, b)
+
+```
+
+```go
+// like Union but saves the result back into a.
+a.Merge(b)
+
+// removes the set items which are in b from a and saves the result back into a.
+a.Separate(b)
+
+```
+
+#### Multiple Set Operations
+
+```go
+a := set.New("1", "3", "4", "5")
+b := set.New("2", "3", "4", "5")
+c := set.New("4", "5", "6", "7")
+
+// creates a new set with items in a, b and c
+// [1 2 3 4 5 6 7]
+u := set.Union(a, b, c)
+
+// creates a new set with items in a but not in b and c
+// [1]
+u := set.Difference(a, b, c)
+
+// creates a new set with items that are common to a, b and c
+// [5]
+u := set.Intersection(a, b, c)
+```
+
+#### Helper methods
+
+The Slice functions below are a convenient way to extract or convert your Set data
+into basic data types.
+
+
+```go
+// create a set of mixed types
+s := set.New("ankara", "5", "8", "san francisco", 13, 21)
+
+
+// convert s into a slice of strings (type is []string)
+// [ankara 5 8 san francisco]
+t := set.StringSlice(s)
+
+
+// u contains a slice of ints (type is []int)
+// [13, 21]
+u := set.IntSlice(s)
+
+```
+
+#### Concurrent safe usage
+
+Below is an example of a concurrent way that uses set. We call ten functions
+concurrently and wait until they are finished. It basically creates a new
+string for each goroutine and adds it to our set.
+
+```go
+package main
+
+import (
+ "fmt"
+ "github.com/fatih/set"
+ "strconv"
+ "sync"
+)
+
+func main() {
+ var wg sync.WaitGroup // this is just for waiting until all goroutines finish
+
+ // Initialize our thread safe Set
+ s := set.New()
+
+ // Add items concurrently (item1, item2, and so on)
+ for i := 0; i < 10; i++ {
+ wg.Add(1)
+ go func(i int) {
+ item := "item" + strconv.Itoa(i)
+ fmt.Println("adding", item)
+ s.Add(item)
+ wg.Done()
+ }(i)
+ }
+
+ // Wait until all concurrent calls finished and print our set
+ wg.Wait()
+ fmt.Println(s)
+}
+```
+
+## Credits
+
+ * [Fatih Arslan](https://github.com/fatih)
+ * [Arne Hormann](https://github.com/arnehormann)
+ * [Sam Boyer](https://github.com/sdboyer)
+ * [Ralph Loizzo](https://github.com/friartech)
+
+## License
+
+The MIT License (MIT) - see LICENSE.md for more details
+
diff --git a/Godeps/_workspace/src/gopkg.in/fatih/set.v0/set.go b/Godeps/_workspace/src/gopkg.in/fatih/set.v0/set.go
new file mode 100644
index 000000000..ac0240ce7
--- /dev/null
+++ b/Godeps/_workspace/src/gopkg.in/fatih/set.v0/set.go
@@ -0,0 +1,121 @@
+// Package set provides both threadsafe and non-threadsafe implementations of
+// a generic set data structure. In the threadsafe set, safety encompasses all
+// operations on one set. Operations on multiple sets are consistent in that
+// the elements of each set used was valid at exactly one point in time
+// between the start and the end of the operation.
+package set
+
+// Interface is describing a Set. Sets are an unordered, unique list of values.
+type Interface interface {
+ New(items ...interface{}) Interface
+ Add(items ...interface{})
+ Remove(items ...interface{})
+ Pop() interface{}
+ Has(items ...interface{}) bool
+ Size() int
+ Clear()
+ IsEmpty() bool
+ IsEqual(s Interface) bool
+ IsSubset(s Interface) bool
+ IsSuperset(s Interface) bool
+ Each(func(interface{}) bool)
+ String() string
+ List() []interface{}
+ Copy() Interface
+ Merge(s Interface)
+ Separate(s Interface)
+}
+
+// helpful to not write everywhere struct{}{}
+var keyExists = struct{}{}
+
+// Union is the merger of multiple sets. It returns a new set with all the
+// elements present in all the sets that are passed.
+//
+// The dynamic type of the returned set is determined by the first passed set's
+// implementation of the New() method.
+func Union(set1, set2 Interface, sets ...Interface) Interface {
+ u := set1.Copy()
+ set2.Each(func(item interface{}) bool {
+ u.Add(item)
+ return true
+ })
+ for _, set := range sets {
+ set.Each(func(item interface{}) bool {
+ u.Add(item)
+ return true
+ })
+ }
+
+ return u
+}
+
+// Difference returns a new set which contains items which are in in the first
+// set but not in the others. Unlike the Difference() method you can use this
+// function separately with multiple sets.
+func Difference(set1, set2 Interface, sets ...Interface) Interface {
+ s := set1.Copy()
+ s.Separate(set2)
+ for _, set := range sets {
+ s.Separate(set) // seperate is thread safe
+ }
+ return s
+}
+
+// Intersection returns a new set which contains items that only exist in all given sets.
+func Intersection(set1, set2 Interface, sets ...Interface) Interface {
+ all := Union(set1, set2, sets...)
+ result := Union(set1, set2, sets...)
+
+ all.Each(func(item interface{}) bool {
+ if !set1.Has(item) || !set2.Has(item) {
+ result.Remove(item)
+ }
+
+ for _, set := range sets {
+ if !set.Has(item) {
+ result.Remove(item)
+ }
+ }
+ return true
+ })
+ return result
+}
+
+// SymmetricDifference returns a new set which s is the difference of items which are in
+// one of either, but not in both.
+func SymmetricDifference(s Interface, t Interface) Interface {
+ u := Difference(s, t)
+ v := Difference(t, s)
+ return Union(u, v)
+}
+
+// StringSlice is a helper function that returns a slice of strings of s. If
+// the set contains mixed types of items only items of type string are returned.
+func StringSlice(s Interface) []string {
+ slice := make([]string, 0)
+ for _, item := range s.List() {
+ v, ok := item.(string)
+ if !ok {
+ continue
+ }
+
+ slice = append(slice, v)
+ }
+ return slice
+}
+
+// IntSlice is a helper function that returns a slice of ints of s. If
+// the set contains mixed types of items only items of type int are returned.
+func IntSlice(s Interface) []int {
+ slice := make([]int, 0)
+ for _, item := range s.List() {
+ v, ok := item.(int)
+ if !ok {
+ continue
+ }
+
+ slice = append(slice, v)
+ }
+ return slice
+}
diff --git a/Godeps/_workspace/src/gopkg.in/fatih/set.v0/set_nots.go b/Godeps/_workspace/src/gopkg.in/fatih/set.v0/set_nots.go
new file mode 100644
index 000000000..ec1ab2285
--- /dev/null
+++ b/Godeps/_workspace/src/gopkg.in/fatih/set.v0/set_nots.go
@@ -0,0 +1,195 @@
+package set
+
+import (
+ "fmt"
+ "strings"
+)
+
+// Provides a common set baseline for both threadsafe and non-ts Sets.
+type set struct {
+ m map[interface{}]struct{} // struct{} doesn't take up space
+}
+
+// SetNonTS defines a non-thread safe set data structure.
+type SetNonTS struct {
+ set
+}
+
+// NewNonTS creates and initialize a new non-threadsafe Set.
+// It accepts a variable number of arguments to populate the initial set.
+// If nothing is passed a SetNonTS with zero size is created.
+func NewNonTS(items ...interface{}) *SetNonTS {
+ s := &SetNonTS{}
+ s.m = make(map[interface{}]struct{})
+
+ // Ensure interface compliance
+ var _ Interface = s
+
+ s.Add(items...)
+ return s
+}
+
+// New creates and initalizes a new Set interface. It accepts a variable
+// number of arguments to populate the initial set. If nothing is passed a
+// zero size Set based on the struct is created.
+func (s *set) New(items ...interface{}) Interface {
+ return NewNonTS(items...)
+}
+
+// Add includes the specified items (one or more) to the set. The underlying
+// Set s is modified. If passed nothing it silently returns.
+func (s *set) Add(items ...interface{}) {
+ if len(items) == 0 {
+ return
+ }
+
+ for _, item := range items {
+ s.m[item] = keyExists
+ }
+}
+
+// Remove deletes the specified items from the set. The underlying Set s is
+// modified. If passed nothing it silently returns.
+func (s *set) Remove(items ...interface{}) {
+ if len(items) == 0 {
+ return
+ }
+
+ for _, item := range items {
+ delete(s.m, item)
+ }
+}
+
+// Pop deletes and return an item from the set. The underlying Set s is
+// modified. If set is empty, nil is returned.
+func (s *set) Pop() interface{} {
+ for item := range s.m {
+ delete(s.m, item)
+ return item
+ }
+ return nil
+}
+
+// Has looks for the existence of items passed. It returns false if nothing is
+// passed. For multiple items it returns true only if all of the items exist.
+func (s *set) Has(items ...interface{}) bool {
+ // assume checked for empty item, which not exist
+ if len(items) == 0 {
+ return false
+ }
+
+ has := true
+ for _, item := range items {
+ if _, has = s.m[item]; !has {
+ break
+ }
+ }
+ return has
+}
+
+// Size returns the number of items in a set.
+func (s *set) Size() int {
+ return len(s.m)
+}
+
+// Clear removes all items from the set.
+func (s *set) Clear() {
+ s.m = make(map[interface{}]struct{})
+}
+
+// IsEmpty reports whether the Set is empty.
+func (s *set) IsEmpty() bool {
+ return s.Size() == 0
+}
+
+// IsEqual test whether s and t are the same in size and have the same items.
+func (s *set) IsEqual(t Interface) bool {
+ // Force locking only if given set is threadsafe.
+ if conv, ok := t.(*Set); ok {
+ conv.l.RLock()
+ defer conv.l.RUnlock()
+ }
+
+ // return false if they are no the same size
+ if sameSize := len(s.m) == t.Size(); !sameSize {
+ return false
+ }
+
+ equal := true
+ t.Each(func(item interface{}) bool {
+ _, equal = s.m[item]
+ return equal // if false, Each() will end
+ })
+
+ return equal
+}
+
+// IsSubset tests whether t is a subset of s.
+func (s *set) IsSubset(t Interface) (subset bool) {
+ subset = true
+
+ t.Each(func(item interface{}) bool {
+ _, subset = s.m[item]
+ return subset
+ })
+
+ return
+}
+
+// IsSuperset tests whether t is a superset of s.
+func (s *set) IsSuperset(t Interface) bool {
+ return t.IsSubset(s)
+}
+
+// Each traverses the items in the Set, calling the provided function for each
+// set member. Traversal will continue until all items in the Set have been
+// visited, or if the closure returns false.
+func (s *set) Each(f func(item interface{}) bool) {
+ for item := range s.m {
+ if !f(item) {
+ break
+ }
+ }
+}
+
+// String returns a string representation of s
+func (s *set) String() string {
+ t := make([]string, 0, len(s.List()))
+ for _, item := range s.List() {
+ t = append(t, fmt.Sprintf("%v", item))
+ }
+
+ return fmt.Sprintf("[%s]", strings.Join(t, ", "))
+}
+
+// List returns a slice of all items. There is also StringSlice() and
+// IntSlice() methods for returning slices of type string or int.
+func (s *set) List() []interface{} {
+ list := make([]interface{}, 0, len(s.m))
+
+ for item := range s.m {
+ list = append(list, item)
+ }
+
+ return list
+}
+
+// Copy returns a new Set with a copy of s.
+func (s *set) Copy() Interface {
+ return NewNonTS(s.List()...)
+}
+
+// Merge is like Union, however it modifies the current set it's applied on
+// with the given t set.
+func (s *set) Merge(t Interface) {
+ t.Each(func(item interface{}) bool {
+ s.m[item] = keyExists
+ return true
+ })
+}
+
+// it's not the opposite of Merge.
+// Separate removes the set items containing in t from set s. Please aware that
+func (s *set) Separate(t Interface) {
+ s.Remove(t.List()...)
+}
diff --git a/Godeps/_workspace/src/gopkg.in/fatih/set.v0/set_nots_test.go b/Godeps/_workspace/src/gopkg.in/fatih/set.v0/set_nots_test.go
new file mode 100644
index 000000000..fd599699f
--- /dev/null
+++ b/Godeps/_workspace/src/gopkg.in/fatih/set.v0/set_nots_test.go
@@ -0,0 +1,282 @@
+package set
+
+import (
+ "reflect"
+ "strings"
+ "testing"
+)
+
+func TestSetNonTS_NewNonTS_parameters(t *testing.T) {
+ s := NewNonTS("string", "another_string", 1, 3.14)
+
+ if s.Size() != 4 {
+ t.Error("NewNonTS: calling with parameters should create a set with size of four")
+ }
+}
+
+func TestSetNonTS_Add(t *testing.T) {
+ s := NewNonTS()
+ s.Add(1)
+ s.Add(2)
+ s.Add(2) // duplicate
+ s.Add("fatih")
+ s.Add("zeynep")
+ s.Add("zeynep") // another duplicate
+
+ if s.Size() != 4 {
+ t.Error("Add: items are not unique. The set size should be four")
+ }
+
+ if !s.Has(1, 2, "fatih", "zeynep") {
+ t.Error("Add: added items are not availabile in the set.")
+ }
+}
+
+func TestSetNonTS_Add_multiple(t *testing.T) {
+ s := NewNonTS()
+ s.Add("ankara", "san francisco", 3.14)
+
+ if s.Size() != 3 {
+ t.Error("Add: items are not unique. The set size should be three")
+ }
+
+ if !s.Has("ankara", "san francisco", 3.14) {
+ t.Error("Add: added items are not availabile in the set.")
+ }
+}
+
+func TestSetNonTS_Remove(t *testing.T) {
+ s := NewNonTS()
+ s.Add(1)
+ s.Add(2)
+ s.Add("fatih")
+
+ s.Remove(1)
+ if s.Size() != 2 {
+ t.Error("Remove: set size should be two after removing")
+ }
+
+ s.Remove(1)
+ if s.Size() != 2 {
+ t.Error("Remove: set size should be not change after trying to remove a non-existing item")
+ }
+
+ s.Remove(2)
+ s.Remove("fatih")
+ if s.Size() != 0 {
+ t.Error("Remove: set size should be zero")
+ }
+
+ s.Remove("fatih") // try to remove something from a zero length set
+}
+
+func TestSetNonTS_Remove_multiple(t *testing.T) {
+ s := NewNonTS()
+ s.Add("ankara", "san francisco", 3.14, "istanbul")
+ s.Remove("ankara", "san francisco", 3.14)
+
+ if s.Size() != 1 {
+ t.Error("Remove: items are not unique. The set size should be four")
+ }
+
+ if !s.Has("istanbul") {
+ t.Error("Add: added items are not availabile in the set.")
+ }
+}
+
+func TestSetNonTS_Pop(t *testing.T) {
+ s := NewNonTS()
+ s.Add(1)
+ s.Add(2)
+ s.Add("fatih")
+
+ a := s.Pop()
+ if s.Size() != 2 {
+ t.Error("Pop: set size should be two after popping out")
+ }
+
+ if s.Has(a) {
+ t.Error("Pop: returned item should not exist")
+ }
+
+ s.Pop()
+ s.Pop()
+ b := s.Pop()
+ if b != nil {
+ t.Error("Pop: should return nil because set is empty")
+ }
+
+ s.Pop() // try to remove something from a zero length set
+}
+
+func TestSetNonTS_Has(t *testing.T) {
+ s := NewNonTS("1", "2", "3", "4")
+
+ if !s.Has("1") {
+ t.Error("Has: the item 1 exist, but 'Has' is returning false")
+ }
+
+ if !s.Has("1", "2", "3", "4") {
+ t.Error("Has: the items all exist, but 'Has' is returning false")
+ }
+}
+
+func TestSetNonTS_Clear(t *testing.T) {
+ s := NewNonTS()
+ s.Add(1)
+ s.Add("istanbul")
+ s.Add("san francisco")
+
+ s.Clear()
+ if s.Size() != 0 {
+ t.Error("Clear: set size should be zero")
+ }
+}
+
+func TestSetNonTS_IsEmpty(t *testing.T) {
+ s := NewNonTS()
+
+ empty := s.IsEmpty()
+ if !empty {
+ t.Error("IsEmpty: set is empty, it should be true")
+ }
+
+ s.Add(2)
+ s.Add(3)
+ notEmpty := s.IsEmpty()
+
+ if notEmpty {
+ t.Error("IsEmpty: set is filled, it should be false")
+ }
+}
+
+func TestSetNonTS_IsEqual(t *testing.T) {
+ s := NewNonTS("1", "2", "3")
+ u := NewNonTS("1", "2", "3")
+
+ ok := s.IsEqual(u)
+ if !ok {
+ t.Error("IsEqual: set s and t are equal. However it returns false")
+ }
+
+ // same size, different content
+ a := NewNonTS("1", "2", "3")
+ b := NewNonTS("4", "5", "6")
+
+ ok = a.IsEqual(b)
+ if ok {
+ t.Error("IsEqual: set a and b are now equal (1). However it returns true")
+ }
+
+ // different size, similar content
+ a = NewNonTS("1", "2", "3")
+ b = NewNonTS("1", "2", "3", "4")
+
+ ok = a.IsEqual(b)
+ if ok {
+ t.Error("IsEqual: set s and t are now equal (2). However it returns true")
+ }
+
+}
+
+func TestSetNonTS_IsSubset(t *testing.T) {
+ s := NewNonTS("1", "2", "3", "4")
+ u := NewNonTS("1", "2", "3")
+
+ ok := s.IsSubset(u)
+ if !ok {
+ t.Error("IsSubset: u is a subset of s. However it returns false")
+ }
+
+ ok = u.IsSubset(s)
+ if ok {
+ t.Error("IsSubset: s is not a subset of u. However it returns true")
+ }
+
+}
+
+func TestSetNonTS_IsSuperset(t *testing.T) {
+ s := NewNonTS("1", "2", "3", "4")
+ u := NewNonTS("1", "2", "3")
+
+ ok := u.IsSuperset(s)
+ if !ok {
+ t.Error("IsSuperset: s is a superset of u. However it returns false")
+ }
+
+ ok = s.IsSuperset(u)
+ if ok {
+ t.Error("IsSuperset: u is not a superset of u. However it returns true")
+ }
+
+}
+
+func TestSetNonTS_String(t *testing.T) {
+ s := NewNonTS()
+ if s.String() != "[]" {
+ t.Errorf("String: output is not what is excepted '%s'", s.String())
+ }
+
+ s.Add("1", "2", "3", "4")
+ if !strings.HasPrefix(s.String(), "[") {
+ t.Error("String: output should begin with a square bracket")
+ }
+
+ if !strings.HasSuffix(s.String(), "]") {
+ t.Error("String: output should end with a square bracket")
+ }
+
+}
+
+func TestSetNonTS_List(t *testing.T) {
+ s := NewNonTS("1", "2", "3", "4")
+
+ // this returns a slice of interface{}
+ if len(s.List()) != 4 {
+ t.Error("List: slice size should be four.")
+ }
+
+ for _, item := range s.List() {
+ r := reflect.TypeOf(item)
+ if r.Kind().String() != "string" {
+ t.Error("List: slice item should be a string")
+ }
+ }
+}
+
+func TestSetNonTS_Copy(t *testing.T) {
+ s := NewNonTS("1", "2", "3", "4")
+ r := s.Copy()
+
+ if !s.IsEqual(r) {
+ t.Error("Copy: set s and r are not equal")
+ }
+}
+
+func TestSetNonTS_Merge(t *testing.T) {
+ s := NewNonTS("1", "2", "3")
+ r := NewNonTS("3", "4", "5")
+ s.Merge(r)
+
+ if s.Size() != 5 {
+ t.Error("Merge: the set doesn't have all items in it.")
+ }
+
+ if !s.Has("1", "2", "3", "4", "5") {
+ t.Error("Merge: merged items are not availabile in the set.")
+ }
+}
+
+func TestSetNonTS_Separate(t *testing.T) {
+ s := NewNonTS("1", "2", "3")
+ r := NewNonTS("3", "5")
+ s.Separate(r)
+
+ if s.Size() != 2 {
+ t.Error("Separate: the set doesn't have all items in it.")
+ }
+
+ if !s.Has("1", "2") {
+ t.Error("Separate: items after separation are not availabile in the set.")
+ }
+}
diff --git a/Godeps/_workspace/src/gopkg.in/fatih/set.v0/set_test.go b/Godeps/_workspace/src/gopkg.in/fatih/set.v0/set_test.go
new file mode 100644
index 000000000..83dd5806d
--- /dev/null
+++ b/Godeps/_workspace/src/gopkg.in/fatih/set.v0/set_test.go
@@ -0,0 +1,188 @@
+package set
+
+import (
+ "reflect"
+ "testing"
+)
+
+func Test_Union(t *testing.T) {
+ s := New("1", "2", "3")
+ r := New("3", "4", "5")
+ x := NewNonTS("5", "6", "7")
+
+ u := Union(s, r, x)
+ if settype := reflect.TypeOf(u).String(); settype != "*set.Set" {
+ t.Error("Union should derive its set type from the first passed set, got", settype)
+ }
+ if u.Size() != 7 {
+ t.Error("Union: the merged set doesn't have all items in it.")
+ }
+
+ if !u.Has("1", "2", "3", "4", "5", "6", "7") {
+ t.Error("Union: merged items are not availabile in the set.")
+ }
+
+ z := Union(x, r)
+ if z.Size() != 5 {
+ t.Error("Union: Union of 2 sets doesn't have the proper number of items.")
+ }
+ if settype := reflect.TypeOf(z).String(); settype != "*set.SetNonTS" {
+ t.Error("Union should derive its set type from the first passed set, got", settype)
+ }
+
+}
+
+func Test_Difference(t *testing.T) {
+ s := New("1", "2", "3")
+ r := New("3", "4", "5")
+ x := New("5", "6", "7")
+ u := Difference(s, r, x)
+
+ if u.Size() != 2 {
+ t.Error("Difference: the set doesn't have all items in it.")
+ }
+
+ if !u.Has("1", "2") {
+ t.Error("Difference: items are not availabile in the set.")
+ }
+
+ y := Difference(r, r)
+ if y.Size() != 0 {
+ t.Error("Difference: size should be zero")
+ }
+
+}
+
+func Test_Intersection(t *testing.T) {
+ s1 := New("1", "3", "4", "5")
+ s2 := New("2", "3", "5", "6")
+ s3 := New("4", "5", "6", "7")
+ u := Intersection(s1, s2, s3)
+
+ if u.Size() != 1 {
+ t.Error("Intersection: the set doesn't have all items in it.")
+ }
+
+ if !u.Has("5") {
+ t.Error("Intersection: items after intersection are not availabile in the set.")
+ }
+}
+
+func Test_SymmetricDifference(t *testing.T) {
+ s := New("1", "2", "3")
+ r := New("3", "4", "5")
+ u := SymmetricDifference(s, r)
+
+ if u.Size() != 4 {
+ t.Error("SymmetricDifference: the set doesn't have all items in it.")
+ }
+
+ if !u.Has("1", "2", "4", "5") {
+ t.Error("SymmetricDifference: items are not availabile in the set.")
+ }
+}
+
+func Test_StringSlice(t *testing.T) {
+ s := New("san francisco", "istanbul", 3.14, 1321, "ankara")
+ u := StringSlice(s)
+
+ if len(u) != 3 {
+ t.Error("StringSlice: slice should only have three items")
+ }
+
+ for _, item := range u {
+ r := reflect.TypeOf(item)
+ if r.Kind().String() != "string" {
+ t.Error("StringSlice: slice item should be a string")
+ }
+ }
+}
+
+func Test_IntSlice(t *testing.T) {
+ s := New("san francisco", "istanbul", 3.14, 1321, "ankara", 8876)
+ u := IntSlice(s)
+
+ if len(u) != 2 {
+ t.Error("IntSlice: slice should only have two items")
+ }
+
+ for _, item := range u {
+ r := reflect.TypeOf(item)
+ if r.Kind().String() != "int" {
+ t.Error("Intslice: slice item should be a int")
+ }
+ }
+}
+
+func BenchmarkSetEquality(b *testing.B) {
+ s := New()
+ u := New()
+
+ for i := 0; i < b.N; i++ {
+ s.Add(i)
+ u.Add(i)
+ }
+
+ b.ResetTimer()
+
+ for i := 0; i < b.N; i++ {
+ s.IsEqual(u)
+ }
+}
+
+func BenchmarkSubset(b *testing.B) {
+ s := New()
+ u := New()
+
+ for i := 0; i < b.N; i++ {
+ s.Add(i)
+ u.Add(i)
+ }
+
+ b.ResetTimer()
+
+ for i := 0; i < b.N; i++ {
+ s.IsSubset(u)
+ }
+}
+
+func benchmarkIntersection(b *testing.B, numberOfItems int) {
+ s1 := New()
+ s2 := New()
+
+ for i := 0; i < numberOfItems/2; i++ {
+ s1.Add(i)
+ }
+ for i := 0; i < numberOfItems; i++ {
+ s2.Add(i)
+ }
+
+ b.ResetTimer()
+ for i := 0; i < b.N; i++ {
+ Intersection(s1, s2)
+ }
+}
+
+func BenchmarkIntersection10(b *testing.B) {
+ benchmarkIntersection(b, 10)
+}
+
+func BenchmarkIntersection100(b *testing.B) {
+ benchmarkIntersection(b, 100)
+}
+
+func BenchmarkIntersection1000(b *testing.B) {
+ benchmarkIntersection(b, 1000)
+}
+
+func BenchmarkIntersection10000(b *testing.B) {
+ benchmarkIntersection(b, 10000)
+}
+
+func BenchmarkIntersection100000(b *testing.B) {
+ benchmarkIntersection(b, 100000)
+}
+
+func BenchmarkIntersection1000000(b *testing.B) {
+ benchmarkIntersection(b, 1000000)
+}
diff --git a/Godeps/_workspace/src/gopkg.in/fatih/set.v0/set_ts.go b/Godeps/_workspace/src/gopkg.in/fatih/set.v0/set_ts.go
new file mode 100644
index 000000000..50f532565
--- /dev/null
+++ b/Godeps/_workspace/src/gopkg.in/fatih/set.v0/set_ts.go
@@ -0,0 +1,200 @@
+package set
+
+import (
+ "sync"
+)
+
+// Set defines a thread safe set data structure.
+type Set struct {
+ set
+ l sync.RWMutex // we name it because we don't want to expose it
+}
+
+// New creates and initialize a new Set. It's accept a variable number of
+// arguments to populate the initial set. If nothing passed a Set with zero
+// size is created.
+func New(items ...interface{}) *Set {
+ s := &Set{}
+ s.m = make(map[interface{}]struct{})
+
+ // Ensure interface compliance
+ var _ Interface = s
+
+ s.Add(items...)
+ return s
+}
+
+// New creates and initalizes a new Set interface. It accepts a variable
+// number of arguments to populate the initial set. If nothing is passed a
+// zero size Set based on the struct is created.
+func (s *Set) New(items ...interface{}) Interface {
+ return New(items...)
+}
+
+// Add includes the specified items (one or more) to the set. The underlying
+// Set s is modified. If passed nothing it silently returns.
+func (s *Set) Add(items ...interface{}) {
+ if len(items) == 0 {
+ return
+ }
+
+ s.l.Lock()
+ defer s.l.Unlock()
+
+ for _, item := range items {
+ s.m[item] = keyExists
+ }
+}
+
+// Remove deletes the specified items from the set. The underlying Set s is
+// modified. If passed nothing it silently returns.
+func (s *Set) Remove(items ...interface{}) {
+ if len(items) == 0 {
+ return
+ }
+
+ s.l.Lock()
+ defer s.l.Unlock()
+
+ for _, item := range items {
+ delete(s.m, item)
+ }
+}
+
+// Pop deletes and return an item from the set. The underlying Set s is
+// modified. If set is empty, nil is returned.
+func (s *Set) Pop() interface{} {
+ s.l.RLock()
+ for item := range s.m {
+ s.l.RUnlock()
+ s.l.Lock()
+ delete(s.m, item)
+ s.l.Unlock()
+ return item
+ }
+ s.l.RUnlock()
+ return nil
+}
+
+// Has looks for the existence of items passed. It returns false if nothing is
+// passed. For multiple items it returns true only if all of the items exist.
+func (s *Set) Has(items ...interface{}) bool {
+ // assume checked for empty item, which not exist
+ if len(items) == 0 {
+ return false
+ }
+
+ s.l.RLock()
+ defer s.l.RUnlock()
+
+ has := true
+ for _, item := range items {
+ if _, has = s.m[item]; !has {
+ break
+ }
+ }
+ return has
+}
+
+// Size returns the number of items in a set.
+func (s *Set) Size() int {
+ s.l.RLock()
+ defer s.l.RUnlock()
+
+ l := len(s.m)
+ return l
+}
+
+// Clear removes all items from the set.
+func (s *Set) Clear() {
+ s.l.Lock()
+ defer s.l.Unlock()
+
+ s.m = make(map[interface{}]struct{})
+}
+
+// IsEqual test whether s and t are the same in size and have the same items.
+func (s *Set) IsEqual(t Interface) bool {
+ s.l.RLock()
+ defer s.l.RUnlock()
+
+ // Force locking only if given set is threadsafe.
+ if conv, ok := t.(*Set); ok {
+ conv.l.RLock()
+ defer conv.l.RUnlock()
+ }
+
+ // return false if they are no the same size
+ if sameSize := len(s.m) == t.Size(); !sameSize {
+ return false
+ }
+
+ equal := true
+ t.Each(func(item interface{}) bool {
+ _, equal = s.m[item]
+ return equal // if false, Each() will end
+ })
+
+ return equal
+}
+
+// IsSubset tests whether t is a subset of s.
+func (s *Set) IsSubset(t Interface) (subset bool) {
+ s.l.RLock()
+ defer s.l.RUnlock()
+
+ subset = true
+
+ t.Each(func(item interface{}) bool {
+ _, subset = s.m[item]
+ return subset
+ })
+
+ return
+}
+
+// Each traverses the items in the Set, calling the provided function for each
+// set member. Traversal will continue until all items in the Set have been
+// visited, or if the closure returns false.
+func (s *Set) Each(f func(item interface{}) bool) {
+ s.l.RLock()
+ defer s.l.RUnlock()
+
+ for item := range s.m {
+ if !f(item) {
+ break
+ }
+ }
+}
+
+// List returns a slice of all items. There is also StringSlice() and
+// IntSlice() methods for returning slices of type string or int.
+func (s *Set) List() []interface{} {
+ s.l.RLock()
+ defer s.l.RUnlock()
+
+ list := make([]interface{}, 0, len(s.m))
+
+ for item := range s.m {
+ list = append(list, item)
+ }
+
+ return list
+}
+
+// Copy returns a new Set with a copy of s.
+func (s *Set) Copy() Interface {
+ return New(s.List()...)
+}
+
+// Merge is like Union, however it modifies the current set it's applied on
+// with the given t set.
+func (s *Set) Merge(t Interface) {
+ s.l.Lock()
+ defer s.l.Unlock()
+
+ t.Each(func(item interface{}) bool {
+ s.m[item] = keyExists
+ return true
+ })
+}
diff --git a/Godeps/_workspace/src/gopkg.in/fatih/set.v0/set_ts_test.go b/Godeps/_workspace/src/gopkg.in/fatih/set.v0/set_ts_test.go
new file mode 100644
index 000000000..8d2f509d0
--- /dev/null
+++ b/Godeps/_workspace/src/gopkg.in/fatih/set.v0/set_ts_test.go
@@ -0,0 +1,321 @@
+package set
+
+import (
+ "reflect"
+ "strconv"
+ "strings"
+ "testing"
+)
+
+func TestSet_New(t *testing.T) {
+ s := New()
+
+ if s.Size() != 0 {
+ t.Error("New: calling without any parameters should create a set with zero size")
+ }
+
+ u := s.New()
+ if u.Size() != 0 {
+ t.Error("New: creating a new set via s.New() should create a set with zero size")
+ }
+}
+
+func TestSet_New_parameters(t *testing.T) {
+ s := New("string", "another_string", 1, 3.14)
+
+ if s.Size() != 4 {
+ t.Error("New: calling with parameters should create a set with size of four")
+ }
+}
+
+func TestSet_Add(t *testing.T) {
+ s := New()
+ s.Add(1)
+ s.Add(2)
+ s.Add(2) // duplicate
+ s.Add("fatih")
+ s.Add("zeynep")
+ s.Add("zeynep") // another duplicate
+
+ if s.Size() != 4 {
+ t.Error("Add: items are not unique. The set size should be four")
+ }
+
+ if !s.Has(1, 2, "fatih", "zeynep") {
+ t.Error("Add: added items are not availabile in the set.")
+ }
+}
+
+func TestSet_Add_multiple(t *testing.T) {
+ s := New()
+ s.Add("ankara", "san francisco", 3.14)
+
+ if s.Size() != 3 {
+ t.Error("Add: items are not unique. The set size should be three")
+ }
+
+ if !s.Has("ankara", "san francisco", 3.14) {
+ t.Error("Add: added items are not availabile in the set.")
+ }
+}
+
+func TestSet_Remove(t *testing.T) {
+ s := New()
+ s.Add(1)
+ s.Add(2)
+ s.Add("fatih")
+
+ s.Remove(1)
+ if s.Size() != 2 {
+ t.Error("Remove: set size should be two after removing")
+ }
+
+ s.Remove(1)
+ if s.Size() != 2 {
+ t.Error("Remove: set size should be not change after trying to remove a non-existing item")
+ }
+
+ s.Remove(2)
+ s.Remove("fatih")
+ if s.Size() != 0 {
+ t.Error("Remove: set size should be zero")
+ }
+
+ s.Remove("fatih") // try to remove something from a zero length set
+}
+
+func TestSet_Remove_multiple(t *testing.T) {
+ s := New()
+ s.Add("ankara", "san francisco", 3.14, "istanbul")
+ s.Remove("ankara", "san francisco", 3.14)
+
+ if s.Size() != 1 {
+ t.Error("Remove: items are not unique. The set size should be four")
+ }
+
+ if !s.Has("istanbul") {
+ t.Error("Add: added items are not availabile in the set.")
+ }
+}
+
+func TestSet_Pop(t *testing.T) {
+ s := New()
+ s.Add(1)
+ s.Add(2)
+ s.Add("fatih")
+
+ a := s.Pop()
+ if s.Size() != 2 {
+ t.Error("Pop: set size should be two after popping out")
+ }
+
+ if s.Has(a) {
+ t.Error("Pop: returned item should not exist")
+ }
+
+ s.Pop()
+ s.Pop()
+ b := s.Pop()
+ if b != nil {
+ t.Error("Pop: should return nil because set is empty")
+ }
+
+ s.Pop() // try to remove something from a zero length set
+}
+
+func TestSet_Has(t *testing.T) {
+ s := New("1", "2", "3", "4")
+
+ if !s.Has("1") {
+ t.Error("Has: the item 1 exist, but 'Has' is returning false")
+ }
+
+ if !s.Has("1", "2", "3", "4") {
+ t.Error("Has: the items all exist, but 'Has' is returning false")
+ }
+}
+
+func TestSet_Clear(t *testing.T) {
+ s := New()
+ s.Add(1)
+ s.Add("istanbul")
+ s.Add("san francisco")
+
+ s.Clear()
+ if s.Size() != 0 {
+ t.Error("Clear: set size should be zero")
+ }
+}
+
+func TestSet_IsEmpty(t *testing.T) {
+ s := New()
+
+ empty := s.IsEmpty()
+ if !empty {
+ t.Error("IsEmpty: set is empty, it should be true")
+ }
+
+ s.Add(2)
+ s.Add(3)
+ notEmpty := s.IsEmpty()
+
+ if notEmpty {
+ t.Error("IsEmpty: set is filled, it should be false")
+ }
+}
+
+func TestSet_IsEqual(t *testing.T) {
+ s := New("1", "2", "3")
+ u := New("1", "2", "3")
+
+ ok := s.IsEqual(u)
+ if !ok {
+ t.Error("IsEqual: set s and t are equal. However it returns false")
+ }
+
+ // same size, different content
+ a := New("1", "2", "3")
+ b := New("4", "5", "6")
+
+ ok = a.IsEqual(b)
+ if ok {
+ t.Error("IsEqual: set a and b are now equal (1). However it returns true")
+ }
+
+ // different size, similar content
+ a = New("1", "2", "3")
+ b = New("1", "2", "3", "4")
+
+ ok = a.IsEqual(b)
+ if ok {
+ t.Error("IsEqual: set s and t are now equal (2). However it returns true")
+ }
+
+}
+
+func TestSet_IsSubset(t *testing.T) {
+ s := New("1", "2", "3", "4")
+ u := New("1", "2", "3")
+
+ ok := s.IsSubset(u)
+ if !ok {
+ t.Error("IsSubset: u is a subset of s. However it returns false")
+ }
+
+ ok = u.IsSubset(s)
+ if ok {
+ t.Error("IsSubset: s is not a subset of u. However it returns true")
+ }
+
+}
+
+func TestSet_IsSuperset(t *testing.T) {
+ s := New("1", "2", "3", "4")
+ u := New("1", "2", "3")
+
+ ok := u.IsSuperset(s)
+ if !ok {
+ t.Error("IsSuperset: s is a superset of u. However it returns false")
+ }
+
+ ok = s.IsSuperset(u)
+ if ok {
+ t.Error("IsSuperset: u is not a superset of u. However it returns true")
+ }
+
+}
+
+func TestSet_String(t *testing.T) {
+ s := New()
+ if s.String() != "[]" {
+ t.Errorf("String: output is not what is excepted '%s'", s.String())
+ }
+
+ s.Add("1", "2", "3", "4")
+ if !strings.HasPrefix(s.String(), "[") {
+ t.Error("String: output should begin with a square bracket")
+ }
+
+ if !strings.HasSuffix(s.String(), "]") {
+ t.Error("String: output should end with a square bracket")
+ }
+}
+
+func TestSet_List(t *testing.T) {
+ s := New("1", "2", "3", "4")
+
+ // this returns a slice of interface{}
+ if len(s.List()) != 4 {
+ t.Error("List: slice size should be four.")
+ }
+
+ for _, item := range s.List() {
+ r := reflect.TypeOf(item)
+ if r.Kind().String() != "string" {
+ t.Error("List: slice item should be a string")
+ }
+ }
+}
+
+func TestSet_Copy(t *testing.T) {
+ s := New("1", "2", "3", "4")
+ r := s.Copy()
+
+ if !s.IsEqual(r) {
+ t.Error("Copy: set s and r are not equal")
+ }
+}
+
+func TestSet_Merge(t *testing.T) {
+ s := New("1", "2", "3")
+ r := New("3", "4", "5")
+ s.Merge(r)
+
+ if s.Size() != 5 {
+ t.Error("Merge: the set doesn't have all items in it.")
+ }
+
+ if !s.Has("1", "2", "3", "4", "5") {
+ t.Error("Merge: merged items are not availabile in the set.")
+ }
+}
+
+func TestSet_Separate(t *testing.T) {
+ s := New("1", "2", "3")
+ r := New("3", "5")
+ s.Separate(r)
+
+ if s.Size() != 2 {
+ t.Error("Separate: the set doesn't have all items in it.")
+ }
+
+ if !s.Has("1", "2") {
+ t.Error("Separate: items after separation are not availabile in the set.")
+ }
+}
+
+func TestSet_RaceAdd(t *testing.T) {
+ // Create two sets. Add concurrently items to each of them. Remove from the
+ // other one.
+ // "go test -race" should detect this if the library is not thread-safe.
+ s := New()
+ u := New()
+
+ go func() {
+ for i := 0; i < 1000; i++ {
+ item := "item" + strconv.Itoa(i)
+ go func(i int) {
+ s.Add(item)
+ u.Add(item)
+ }(i)
+ }
+ }()
+
+ for i := 0; i < 1000; i++ {
+ item := "item" + strconv.Itoa(i)
+ go func(i int) {
+ s.Add(item)
+ u.Add(item)
+ }(i)
+ }
+}
diff --git a/Godeps/_workspace/src/gopkg.in/qml.v1/cdata/cdata.go b/Godeps/_workspace/src/gopkg.in/qml.v1/cdata/cdata.go
new file mode 100644
index 000000000..6f13b810f
--- /dev/null
+++ b/Godeps/_workspace/src/gopkg.in/qml.v1/cdata/cdata.go
@@ -0,0 +1,6 @@
+// Package cdata supports the implementation of the qml package.
+package cdata
+
+func Ref() uintptr
+
+func Addrs() (uintptr, uintptr)
diff --git a/Godeps/_workspace/src/gopkg.in/qml.v1/cdata/cdata12.c b/Godeps/_workspace/src/gopkg.in/qml.v1/cdata/cdata12.c
new file mode 100644
index 000000000..2e60abfa2
--- /dev/null
+++ b/Godeps/_workspace/src/gopkg.in/qml.v1/cdata/cdata12.c
@@ -0,0 +1,18 @@
+// +build !go1.4
+
+#include "runtime.h"
+
+void ·Ref(uintptr ref) {
+ ref = (uintptr)g->m;
+ FLUSH(&ref);
+}
+
+void runtime·main(void);
+void main·main(void);
+
+void ·Addrs(uintptr rmain, uintptr mmain) {
+ rmain = (uintptr)runtime·main;
+ mmain = (uintptr)main·main;
+ FLUSH(&rmain);
+ FLUSH(&mmain);
+}
diff --git a/Godeps/_workspace/src/gopkg.in/qml.v1/cdata/cdata14_386.s b/Godeps/_workspace/src/gopkg.in/qml.v1/cdata/cdata14_386.s
new file mode 100644
index 000000000..7dae9b961
--- /dev/null
+++ b/Godeps/_workspace/src/gopkg.in/qml.v1/cdata/cdata14_386.s
@@ -0,0 +1,17 @@
+// +build go1.4
+
+#include "textflag.h"
+
+TEXT ·Ref(SB),NOSPLIT,$4-4
+ CALL runtime·acquirem(SB)
+ MOVL 0(SP), AX
+ MOVL AX, ret+0(FP)
+ CALL runtime·releasem(SB)
+ RET
+
+TEXT ·Addrs(SB),NOSPLIT,$0-8
+ MOVL $runtime·main(SB), AX
+ MOVL AX, ret+0(FP)
+ MOVL $runtime·main_main(SB), AX
+ MOVL AX, ret+8(FP)
+ RET
diff --git a/Godeps/_workspace/src/gopkg.in/qml.v1/cdata/cdata14_amd64.s b/Godeps/_workspace/src/gopkg.in/qml.v1/cdata/cdata14_amd64.s
new file mode 100644
index 000000000..83cc22c9c
--- /dev/null
+++ b/Godeps/_workspace/src/gopkg.in/qml.v1/cdata/cdata14_amd64.s
@@ -0,0 +1,17 @@
+// +build go1.4
+
+#include "textflag.h"
+
+TEXT ·Ref(SB),NOSPLIT,$8-8
+ CALL runtime·acquirem(SB)
+ MOVQ 0(SP), AX
+ MOVQ AX, ret+0(FP)
+ CALL runtime·releasem(SB)
+ RET
+
+TEXT ·Addrs(SB),NOSPLIT,$0-16
+ MOVQ $runtime·main(SB), AX
+ MOVQ AX, ret+0(FP)
+ MOVQ $runtime·main_main(SB), AX
+ MOVQ AX, ret+8(FP)
+ RET
diff --git a/Godeps/_workspace/src/gopkg.in/qml.v1/cdata/cdata14_arm.s b/Godeps/_workspace/src/gopkg.in/qml.v1/cdata/cdata14_arm.s
new file mode 100644
index 000000000..c66bbafbf
--- /dev/null
+++ b/Godeps/_workspace/src/gopkg.in/qml.v1/cdata/cdata14_arm.s
@@ -0,0 +1,18 @@
+// +build go1.4
+
+#include "textflag.h"
+
+TEXT ·Ref(SB),NOSPLIT,$4-4
+ BL runtime·acquirem(SB)
+ MOVW 4(R13), R0
+ MOVW R0, ret+0(FP)
+ MOVW R0, 4(R13)
+ BL runtime·releasem(SB)
+ RET
+
+TEXT ·Addrs(SB),NOSPLIT,$0-8
+ MOVW $runtime·main(SB), R0
+ MOVW R0, ret+0(FP)
+ MOVW $runtime·main_main(SB), R0
+ MOVW R0, ret+4(FP)
+ RET
diff --git a/Godeps/_workspace/src/gopkg.in/qml.v1/cdata/cdata_test.go b/Godeps/_workspace/src/gopkg.in/qml.v1/cdata/cdata_test.go
new file mode 100644
index 000000000..e7c3f33c5
--- /dev/null
+++ b/Godeps/_workspace/src/gopkg.in/qml.v1/cdata/cdata_test.go
@@ -0,0 +1,42 @@
+package cdata
+
+import (
+ "runtime"
+ "sync"
+ "testing"
+)
+
+type refPair struct {
+ ref1, ref2 uintptr
+}
+
+func TestRef(t *testing.T) {
+ const N = 10
+ runtime.LockOSThread()
+ exit := sync.WaitGroup{}
+ exit.Add(1)
+ defer exit.Done()
+ wg := sync.WaitGroup{}
+ wg.Add(N)
+ ch := make(chan refPair)
+ for i := 0; i < N; i++ {
+ go func() {
+ runtime.LockOSThread()
+ wg.Done()
+ ch <- refPair{Ref(), Ref()}
+ exit.Wait()
+ }()
+ }
+ wg.Wait()
+ refs := make(map[uintptr]bool)
+ for i := 0; i < N; i++ {
+ pair := <-ch
+ if pair.ref1 != pair.ref2 {
+ t.Fatalf("found inconsistent ref: %d != %d", pair.ref1, pair.ref2)
+ }
+ if refs[pair.ref1] {
+ t.Fatalf("found duplicated ref: %d", pair.ref1)
+ }
+ refs[pair.ref1] = true
+ }
+}
diff --git a/Godeps/_workspace/src/gopkg.in/qml.v1/gl/glbase/glbase.go b/Godeps/_workspace/src/gopkg.in/qml.v1/gl/glbase/glbase.go
new file mode 100644
index 000000000..c483b15a2
--- /dev/null
+++ b/Godeps/_workspace/src/gopkg.in/qml.v1/gl/glbase/glbase.go
@@ -0,0 +1,33 @@
+package glbase
+
+// A Context represents an OpenGL context that may be rendered on by the
+// version-specific APIs under this package.
+type Context struct {
+ // This is just a marker at the moment, as the GL.API functions will
+ // initialize their GL context from the current context in the
+ // renderer thread. The design supports proper expansion and fixes for
+ // upstream changes that break that model, though.
+ private struct{}
+}
+
+// Contexter is implemented by values that have an assigned OpenGL context.
+type Contexter interface {
+ GLContext() *Context
+}
+
+type (
+ Bitfield uint32
+ Enum uint32
+ Sync uintptr
+ Clampf float32
+ Clampd float64
+
+ Uniform int32
+ Attrib int32
+ Texture uint32
+ Program uint32
+ Shader uint32
+ Buffer uint32
+ Framebuffer uint32
+ Renderbuffer uint32
+)
diff --git a/LICENSE b/LICENSE
new file mode 100644
index 000000000..30f629158
--- /dev/null
+++ b/LICENSE
@@ -0,0 +1,16 @@
+Copyright (c) 2013-2014, Jeffrey Wilcke. All rights reserved.
+
+This library is free software; you can redistribute it and/or
+modify it under the terms of the GNU Lesser General Public
+License as published by the Free Software Foundation; either
+version 2.1 of the License, or (at your option) any later version.
+
+This library is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+Lesser General Public License for more details.
+
+You should have received a copy of the GNU Lesser General Public
+License along with this library; if not, write to the Free Software
+Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+MA 02110-1301 USA
diff --git a/README.md b/README.md
index 0f7dbe5a6..dc965a15c 100644
--- a/README.md
+++ b/README.md
@@ -1,26 +1,100 @@
-tests
+## Ethereum Go
+
+Ethereum Go Client © 2014 Jeffrey Wilcke.
+
+ | Linux | OSX | Windows | Tests
+----------|---------|-----|---------|------
+develop | [![Build+Status](https://build.ethdev.com/buildstatusimage?builder=Linux%20Go%20develop%20branch)](https://build.ethdev.com/builders/Linux%20Go%20develop%20branch/builds/-1) | [![Build+Status](https://build.ethdev.com/buildstatusimage?builder=Linux%20Go%20develop%20branch)](https://build.ethdev.com/builders/OSX%20Go%20develop%20branch/builds/-1) | N/A | [![Buildr+Status](https://travis-ci.org/ethereum/go-ethereum.svg?branch=develop)](https://travis-ci.org/ethereum/go-ethereum) [![Coverage Status](https://coveralls.io/repos/ethereum/go-ethereum/badge.svg?branch=develop)](https://coveralls.io/r/ethereum/go-ethereum?branch=develop)
+master | [![Build+Status](https://build.ethdev.com/buildstatusimage?builder=Linux%20Go%20master%20branch)](https://build.ethdev.com/builders/Linux%20Go%20master%20branch/builds/-1) | [![Build+Status](https://build.ethdev.com/buildstatusimage?builder=OSX%20Go%20master%20branch)](https://build.ethdev.com/builders/OSX%20Go%20master%20branch/builds/-1) | N/A | [![Buildr+Status](https://travis-ci.org/ethereum/go-ethereum.svg?branch=master)](https://travis-ci.org/ethereum/go-ethereum) [![Coverage Status](https://coveralls.io/repos/ethereum/go-ethereum/badge.svg?branch=master)](https://coveralls.io/r/ethereum/go-ethereum?branch=master)
+
+[![Bugs](https://badge.waffle.io/ethereum/go-ethereum.png?label=bug&title=Bugs)](https://waffle.io/ethereum/go-ethereum)
+[![Stories in Ready](https://badge.waffle.io/ethereum/go-ethereum.png?label=ready&title=Ready)](https://waffle.io/ethereum/go-ethereum)
+[![Stories in Progress](https://badge.waffle.io/ethereum/go-ethereum.svg?label=in%20progress&title=In Progress)](http://waffle.io/ethereum/go-ethereum)
+[![Gitter](https://badges.gitter.im/Join%20Chat.svg)](https://gitter.im/ethereum/go-ethereum?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge)
+
+
+Build
=====
-Common tests for all clients to test against.
+Mist (GUI):
+
+`go get github.com/ethereum/go-ethereum/cmd/mist`
+
+Geth (CLI):
+
+`go get github.com/ethereum/go-ethereum/cmd/geth`
+
+As of POC-8, go-ethereum uses [Godep](https://github.com/tools/godep) to manage dependencies. Assuming you have [your environment all set up](https://github.com/ethereum/go-ethereum/wiki/Building-Ethereum), switch to the go-ethereum repository root folder, and build/install the executable you need:
+
+Mist (GUI):
+
+```
+godep go build -v ./cmd/mist
+```
+
+Geth (CLI):
+
+```
+godep go build -v ./cmd/geth
+```
+
+Instead of `build`, you can use `install` which will also install the resulting binary.
+
+For prerequisites and detailed build instructions please see the [Wiki](https://github.com/ethereum/go-ethereum/wiki/Building-Ethereum(Go))
+
+If you intend to develop on go-ethereum, check the [Developers' Guide](https://github.com/ethereum/go-ethereum/wiki/Developers'-Guide)
+
+Automated (dev) builds
+======================
+
+* [Docker](https://registry.hub.docker.com/u/ethereum/client-go/)
+* [OS X](http://build.ethdev.com/builds/OSX%20Go%20develop%20branch/Mist-OSX-latest.dmg)
+* Ubuntu
+ [trusty](https://build.ethdev.com/builds/Linux%20Go%20develop%20deb%20i386-trusty/latest/ethereum-cli_0.9.0%2B192SNAPSHOT20150314224122trusty-0ubuntu1_i386.deb) |
+ [utopic](https://build.ethdev.com/builds/Linux%20Go%20develop%20deb%20i386-utopic/latest/ethereum-cli_0.9.0%2B194SNAPSHOT20150314224124utopic-0ubuntu1_i386.deb)
+* [Windows] Coming soon&trade;
+
+Executables
+===========
+
+Go Ethereum comes with several wrappers/executables found in
+[the `cmd` directory](https://github.com/ethereum/go-ethereum/tree/develop/cmd):
-All files should be of the form:
+* `mist` Official Ethereum Browser (ethereum GUI client)
+* `geth` Ethereum CLI (ethereum command line interface client)
+* `bootnode` runs a bootstrap node for the Discovery Protocol
+* `ethtest` test tool which runs with the [tests](https://github.com/ethereum/testes) suite:
+ `cat file | ethtest`.
+* `evm` is a generic Ethereum Virtual Machine: `evm -code 60ff60ff -gas
+ 10000 -price 0 -dump`. See `-h` for a detailed description.
+* `disasm` disassembles EVM code: `echo "6001" | disasm`
+* `rlpdump` converts a rlp stream to `interface{}`.
+
+Command line options
+============================
+
+Both `mist` and `geth` can be configured via command line options, environment variables and config files.
+
+To get the options available:
```
-{
- "test1name":
- {
- "test1property1": ...,
- "test1property2": ...,
- ...
- },
- "test2name":
- {
- "test2property1": ...,
- "test2property2": ...,
- ...
- }
-}
+geth -help
```
-Arrays are allowed, but don't use them for sets of properties - only use them for data that is clearly a continuous contiguous sequence of values.
+For further details on options, see the [wiki](https://github.com/ethereum/go-ethereum/wiki/Command-Line-Options)
+
+Contribution
+============
+
+If you'd like to contribute to go-ethereum please fork, fix, commit and
+send a pull request. Commits who do not comply with the coding standards
+are ignored (use gofmt!). If you send pull requests make absolute sure that you
+commit on the `develop` branch and that you do not merge to master.
+Commits that are directly based on master are simply ignored.
+
+For dependency management, we use [godep](https://github.com/tools/godep). After installing with `go get github.com/tools/godep`, run `godep restore` to ensure that changes to other repositories do not break the build. To update a dependency version (for example, to include a new upstream fix), run `go get -u <foo/bar>` then `godep update <foo/...>`. To track a new dependency, add it to the project as normal than run `godep save ./...`. Changes to the [Godeps folder](https://github.com/ethereum/go-ethereum/tree/develop/Godeps): should be manually verified then commited.
+
+To make life easier try [git flow](http://nvie.com/posts/a-successful-git-branching-model/) it sets this all up and streamlines your work flow.
+
+See [Developers' Guide](https://github.com/ethereum/go-ethereum/wiki/Developers'-Guide)
diff --git a/_data/invalid1 b/_data/invalid1
new file mode 100755
index 000000000..9c24b13e8
--- /dev/null
+++ b/_data/invalid1
Binary files differ
diff --git a/_data/valid1 b/_data/valid1
new file mode 100755
index 000000000..809a55f1a
--- /dev/null
+++ b/_data/valid1
Binary files differ
diff --git a/_data/valid2 b/_data/valid2
new file mode 100755
index 000000000..3e9d2971a
--- /dev/null
+++ b/_data/valid2
Binary files differ
diff --git a/_data/valid3 b/_data/valid3
new file mode 100755
index 000000000..685bc9fd7
--- /dev/null
+++ b/_data/valid3
Binary files differ
diff --git a/_data/valid4 b/_data/valid4
new file mode 100755
index 000000000..fc016057f
--- /dev/null
+++ b/_data/valid4
Binary files differ
diff --git a/accounts/abi/abi.go b/accounts/abi/abi.go
new file mode 100644
index 000000000..067381a48
--- /dev/null
+++ b/accounts/abi/abi.go
@@ -0,0 +1,155 @@
+package abi
+
+import (
+ "encoding/json"
+ "fmt"
+ "io"
+ "strings"
+
+ "github.com/ethereum/go-ethereum/crypto"
+)
+
+// Callable method given a `Name` and whether the method is a constant.
+// If the method is `Const` no transaction needs to be created for this
+// particular Method call. It can easily be simulated using a local VM.
+// For example a `Balance()` method only needs to retrieve something
+// from the storage and therefor requires no Tx to be send to the
+// network. A method such as `Transact` does require a Tx and thus will
+// be flagged `true`.
+// Input specifies the required input parameters for this gives method.
+type Method struct {
+ Name string
+ Const bool
+ Input []Argument
+ Return Type // not yet implemented
+}
+
+// Returns the methods string signature according to the ABI spec.
+//
+// Example
+//
+// function foo(uint32 a, int b) = "foo(uint32,int256)"
+//
+// Please note that "int" is substitute for its canonical representation "int256"
+func (m Method) String() (out string) {
+ out += m.Name
+ types := make([]string, len(m.Input))
+ i := 0
+ for _, input := range m.Input {
+ types[i] = input.Type.String()
+ i++
+ }
+ out += "(" + strings.Join(types, ",") + ")"
+
+ return
+}
+
+func (m Method) Id() []byte {
+ return crypto.Sha3([]byte(m.String()))[:4]
+}
+
+// Argument holds the name of the argument and the corresponding type.
+// Types are used when packing and testing arguments.
+type Argument struct {
+ Name string
+ Type Type
+}
+
+func (a *Argument) UnmarshalJSON(data []byte) error {
+ var extarg struct {
+ Name string
+ Type string
+ }
+ err := json.Unmarshal(data, &extarg)
+ if err != nil {
+ return fmt.Errorf("argument json err: %v", err)
+ }
+
+ a.Type, err = NewType(extarg.Type)
+ if err != nil {
+ return err
+ }
+ a.Name = extarg.Name
+
+ return nil
+}
+
+// The ABI holds information about a contract's context and available
+// invokable methods. It will allow you to type check function calls and
+// packs data accordingly.
+type ABI struct {
+ Methods map[string]Method
+}
+
+// tests, tests whether the given input would result in a successful
+// call. Checks argument list count and matches input to `input`.
+func (abi ABI) pack(name string, args ...interface{}) ([]byte, error) {
+ method := abi.Methods[name]
+
+ var ret []byte
+ for i, a := range args {
+ input := method.Input[i]
+
+ packed, err := input.Type.pack(a)
+ if err != nil {
+ return nil, fmt.Errorf("`%s` %v", name, err)
+ }
+ ret = append(ret, packed...)
+
+ }
+
+ return ret, nil
+}
+
+// Pack the given method name to conform the ABI. Method call's data
+// will consist of method_id, args0, arg1, ... argN. Method id consists
+// of 4 bytes and arguments are all 32 bytes.
+// Method ids are created from the first 4 bytes of the hash of the
+// methods string signature. (signature = baz(uint32,string32))
+func (abi ABI) Pack(name string, args ...interface{}) ([]byte, error) {
+ method, exist := abi.Methods[name]
+ if !exist {
+ return nil, fmt.Errorf("method '%s' not found", name)
+ }
+
+ // start with argument count match
+ if len(args) != len(method.Input) {
+ return nil, fmt.Errorf("argument count mismatch: %d for %d", len(args), len(method.Input))
+ }
+
+ arguments, err := abi.pack(name, args...)
+ if err != nil {
+ return nil, err
+ }
+
+ // Set function id
+ packed := abi.Methods[name].Id()
+ packed = append(packed, arguments...)
+
+ return packed, nil
+}
+
+func (abi *ABI) UnmarshalJSON(data []byte) error {
+ var methods []Method
+ if err := json.Unmarshal(data, &methods); err != nil {
+ return err
+ }
+
+ abi.Methods = make(map[string]Method)
+ for _, method := range methods {
+ abi.Methods[method.Name] = method
+ }
+
+ return nil
+}
+
+func JSON(reader io.Reader) (ABI, error) {
+ dec := json.NewDecoder(reader)
+
+ var abi ABI
+ if err := dec.Decode(&abi); err != nil {
+ return ABI{}, err
+ }
+
+ return abi, nil
+}
diff --git a/accounts/abi/abi_test.go b/accounts/abi/abi_test.go
new file mode 100644
index 000000000..f47fa80f0
--- /dev/null
+++ b/accounts/abi/abi_test.go
@@ -0,0 +1,330 @@
+package abi
+
+import (
+ "bytes"
+ "math/big"
+ "reflect"
+ "strings"
+ "testing"
+
+ "github.com/ethereum/go-ethereum/crypto"
+)
+
+const jsondata = `
+[
+ { "name" : "balance", "const" : true },
+ { "name" : "send", "const" : false, "input" : [ { "name" : "amount", "type" : "uint256" } ] }
+]`
+
+const jsondata2 = `
+[
+ { "name" : "balance", "const" : true },
+ { "name" : "send", "const" : false, "input" : [ { "name" : "amount", "type" : "uint256" } ] },
+ { "name" : "test", "const" : false, "input" : [ { "name" : "number", "type" : "uint32" } ] },
+ { "name" : "string", "const" : false, "input" : [ { "name" : "input", "type" : "string" } ] },
+ { "name" : "bool", "const" : false, "input" : [ { "name" : "input", "type" : "bool" } ] },
+ { "name" : "address", "const" : false, "input" : [ { "name" : "input", "type" : "address" } ] },
+ { "name" : "string32", "const" : false, "input" : [ { "name" : "input", "type" : "string32" } ] },
+ { "name" : "uint64[2]", "const" : false, "input" : [ { "name" : "input", "type" : "uint64[2]" } ] },
+ { "name" : "uint64[]", "const" : false, "input" : [ { "name" : "input", "type" : "uint64[]" } ] },
+ { "name" : "foo", "const" : false, "input" : [ { "name" : "input", "type" : "uint32" } ] },
+ { "name" : "bar", "const" : false, "input" : [ { "name" : "input", "type" : "uint32" }, { "name" : "string", "type" : "uint16" } ] },
+ { "name" : "slice", "const" : false, "input" : [ { "name" : "input", "type" : "uint32[2]" } ] },
+ { "name" : "slice256", "const" : false, "input" : [ { "name" : "input", "type" : "uint256[2]" } ] }
+]`
+
+func TestType(t *testing.T) {
+ typ, err := NewType("uint32")
+ if err != nil {
+ t.Error(err)
+ }
+ if typ.Kind != reflect.Ptr {
+ t.Error("expected uint32 to have kind Ptr")
+ }
+
+ typ, err = NewType("uint32[]")
+ if err != nil {
+ t.Error(err)
+ }
+ if typ.Kind != reflect.Slice {
+ t.Error("expected uint32[] to have type slice")
+ }
+ if typ.Type != ubig_ts {
+ t.Error("expcted uith32[] to have type uint64")
+ }
+
+ typ, err = NewType("uint32[2]")
+ if err != nil {
+ t.Error(err)
+ }
+ if typ.Kind != reflect.Slice {
+ t.Error("expected uint32[2] to have kind slice")
+ }
+ if typ.Type != ubig_ts {
+ t.Error("expcted uith32[2] to have type uint64")
+ }
+ if typ.Size != 2 {
+ t.Error("expected uint32[2] to have a size of 2")
+ }
+}
+
+func TestReader(t *testing.T) {
+ Uint256, _ := NewType("uint256")
+ exp := ABI{
+ Methods: map[string]Method{
+ "balance": Method{
+ "balance", true, nil, Type{},
+ },
+ "send": Method{
+ "send", false, []Argument{
+ Argument{"amount", Uint256},
+ }, Type{},
+ },
+ },
+ }
+
+ abi, err := JSON(strings.NewReader(jsondata))
+ if err != nil {
+ t.Error(err)
+ }
+
+ // deep equal fails for some reason
+ t.Skip()
+ if !reflect.DeepEqual(abi, exp) {
+ t.Errorf("\nabi: %v\ndoes not match exp: %v", abi, exp)
+ }
+}
+
+func TestTestNumbers(t *testing.T) {
+ abi, err := JSON(strings.NewReader(jsondata2))
+ if err != nil {
+ t.Error(err)
+ t.FailNow()
+ }
+
+ if _, err := abi.Pack("balance"); err != nil {
+ t.Error(err)
+ }
+
+ if _, err := abi.Pack("balance", 1); err == nil {
+ t.Error("expected error for balance(1)")
+ }
+
+ if _, err := abi.Pack("doesntexist", nil); err == nil {
+ t.Errorf("doesntexist shouldn't exist")
+ }
+
+ if _, err := abi.Pack("doesntexist", 1); err == nil {
+ t.Errorf("doesntexist(1) shouldn't exist")
+ }
+
+ if _, err := abi.Pack("send", big.NewInt(1000)); err != nil {
+ t.Error(err)
+ }
+
+ i := new(int)
+ *i = 1000
+ if _, err := abi.Pack("send", i); err == nil {
+ t.Errorf("expected send( ptr ) to throw, requires *big.Int instead of *int")
+ }
+
+ if _, err := abi.Pack("send", 1000); err != nil {
+ t.Error("expected send(1000) to cast to big")
+ }
+
+ if _, err := abi.Pack("test", uint32(1000)); err != nil {
+ t.Error(err)
+ }
+}
+
+func TestTestString(t *testing.T) {
+ abi, err := JSON(strings.NewReader(jsondata2))
+ if err != nil {
+ t.Error(err)
+ t.FailNow()
+ }
+
+ if _, err := abi.Pack("string", "hello world"); err != nil {
+ t.Error(err)
+ }
+
+ str10 := string(make([]byte, 10))
+ if _, err := abi.Pack("string32", str10); err != nil {
+ t.Error(err)
+ }
+
+ str32 := string(make([]byte, 32))
+ if _, err := abi.Pack("string32", str32); err != nil {
+ t.Error(err)
+ }
+
+ str33 := string(make([]byte, 33))
+ if _, err := abi.Pack("string32", str33); err == nil {
+ t.Error("expected str33 to throw out of bound error")
+ }
+}
+
+func TestTestBool(t *testing.T) {
+ abi, err := JSON(strings.NewReader(jsondata2))
+ if err != nil {
+ t.Error(err)
+ t.FailNow()
+ }
+
+ if _, err := abi.Pack("bool", true); err != nil {
+ t.Error(err)
+ }
+}
+
+func TestTestSlice(t *testing.T) {
+ abi, err := JSON(strings.NewReader(jsondata2))
+ if err != nil {
+ t.Error(err)
+ t.FailNow()
+ }
+
+ addr := make([]byte, 20)
+ if _, err := abi.Pack("address", addr); err != nil {
+ t.Error(err)
+ }
+
+ addr = make([]byte, 21)
+ if _, err := abi.Pack("address", addr); err == nil {
+ t.Error("expected address of 21 width to throw")
+ }
+
+ slice := make([]byte, 2)
+ if _, err := abi.Pack("uint64[2]", slice); err != nil {
+ t.Error(err)
+ }
+
+ if _, err := abi.Pack("uint64[]", slice); err != nil {
+ t.Error(err)
+ }
+}
+
+func TestTestAddress(t *testing.T) {
+ abi, err := JSON(strings.NewReader(jsondata2))
+ if err != nil {
+ t.Error(err)
+ t.FailNow()
+ }
+
+ addr := make([]byte, 20)
+ if _, err := abi.Pack("address", addr); err != nil {
+ t.Error(err)
+ }
+}
+
+func TestMethodSignature(t *testing.T) {
+ String, _ := NewType("string")
+ String32, _ := NewType("string32")
+ m := Method{"foo", false, []Argument{Argument{"bar", String32}, Argument{"baz", String}}, Type{}}
+ exp := "foo(string32,string)"
+ if m.String() != exp {
+ t.Error("signature mismatch", exp, "!=", m.String())
+ }
+
+ idexp := crypto.Sha3([]byte(exp))[:4]
+ if !bytes.Equal(m.Id(), idexp) {
+ t.Errorf("expected ids to match %x != %x", m.Id(), idexp)
+ }
+
+ uintt, _ := NewType("uint")
+ m = Method{"foo", false, []Argument{Argument{"bar", uintt}}, Type{}}
+ exp = "foo(uint256)"
+ if m.String() != exp {
+ t.Error("signature mismatch", exp, "!=", m.String())
+ }
+}
+
+func TestPack(t *testing.T) {
+ abi, err := JSON(strings.NewReader(jsondata2))
+ if err != nil {
+ t.Error(err)
+ t.FailNow()
+ }
+
+ sig := crypto.Sha3([]byte("foo(uint32)"))[:4]
+ sig = append(sig, make([]byte, 32)...)
+ sig[35] = 10
+
+ packed, err := abi.Pack("foo", uint32(10))
+ if err != nil {
+ t.Error(err)
+ t.FailNow()
+ }
+
+ if !bytes.Equal(packed, sig) {
+ t.Errorf("expected %x got %x", sig, packed)
+ }
+}
+
+func TestMultiPack(t *testing.T) {
+ abi, err := JSON(strings.NewReader(jsondata2))
+ if err != nil {
+ t.Error(err)
+ t.FailNow()
+ }
+
+ sig := crypto.Sha3([]byte("bar(uint32,uint16)"))[:4]
+ sig = append(sig, make([]byte, 64)...)
+ sig[35] = 10
+ sig[67] = 11
+
+ packed, err := abi.Pack("bar", uint32(10), uint16(11))
+ if err != nil {
+ t.Error(err)
+ t.FailNow()
+ }
+
+ if !bytes.Equal(packed, sig) {
+ t.Errorf("expected %x got %x", sig, packed)
+ }
+}
+
+func TestPackSlice(t *testing.T) {
+ abi, err := JSON(strings.NewReader(jsondata2))
+ if err != nil {
+ t.Error(err)
+ t.FailNow()
+ }
+
+ sig := crypto.Sha3([]byte("slice(uint32[2])"))[:4]
+ sig = append(sig, make([]byte, 64)...)
+ sig[35] = 1
+ sig[67] = 2
+
+ packed, err := abi.Pack("slice", []uint32{1, 2})
+ if err != nil {
+ t.Error(err)
+ t.FailNow()
+ }
+
+ if !bytes.Equal(packed, sig) {
+ t.Errorf("expected %x got %x", sig, packed)
+ }
+}
+
+func TestPackSliceBig(t *testing.T) {
+ abi, err := JSON(strings.NewReader(jsondata2))
+ if err != nil {
+ t.Error(err)
+ t.FailNow()
+ }
+
+ sig := crypto.Sha3([]byte("slice256(uint256[2])"))[:4]
+ sig = append(sig, make([]byte, 64)...)
+ sig[35] = 1
+ sig[67] = 2
+
+ packed, err := abi.Pack("slice256", []*big.Int{big.NewInt(1), big.NewInt(2)})
+ if err != nil {
+ t.Error(err)
+ t.FailNow()
+ }
+
+ if !bytes.Equal(packed, sig) {
+ t.Errorf("expected %x got %x", sig, packed)
+ }
+}
diff --git a/accounts/abi/doc.go b/accounts/abi/doc.go
new file mode 100644
index 000000000..648c971e1
--- /dev/null
+++ b/accounts/abi/doc.go
@@ -0,0 +1,10 @@
+// Package abi implements the Ethereum ABI (Application Binary
+// Interface).
+//
+// The Ethereum ABI is strongly typed, known at compile time
+// and static. This ABI will handle basic type casting; unsigned
+// to signed and visa versa. It does not handle slice casting such
+// as unsigned slice to signed slice. Bit size type casting is also
+// handled. ints with a bit size of 32 will be properly cast to int256,
+// etc.
+package abi
diff --git a/accounts/abi/numbers.go b/accounts/abi/numbers.go
new file mode 100644
index 000000000..9205c005e
--- /dev/null
+++ b/accounts/abi/numbers.go
@@ -0,0 +1,106 @@
+package abi
+
+import (
+ "math/big"
+ "reflect"
+
+ "github.com/ethereum/go-ethereum/common"
+)
+
+var big_t = reflect.TypeOf(&big.Int{})
+var ubig_t = reflect.TypeOf(&big.Int{})
+var byte_t = reflect.TypeOf(byte(0))
+var byte_ts = reflect.TypeOf([]byte(nil))
+var uint_t = reflect.TypeOf(uint(0))
+var uint8_t = reflect.TypeOf(uint8(0))
+var uint16_t = reflect.TypeOf(uint16(0))
+var uint32_t = reflect.TypeOf(uint32(0))
+var uint64_t = reflect.TypeOf(uint64(0))
+var int_t = reflect.TypeOf(int(0))
+var int8_t = reflect.TypeOf(int8(0))
+var int16_t = reflect.TypeOf(int16(0))
+var int32_t = reflect.TypeOf(int32(0))
+var int64_t = reflect.TypeOf(int64(0))
+
+var uint_ts = reflect.TypeOf([]uint(nil))
+var uint8_ts = reflect.TypeOf([]uint8(nil))
+var uint16_ts = reflect.TypeOf([]uint16(nil))
+var uint32_ts = reflect.TypeOf([]uint32(nil))
+var uint64_ts = reflect.TypeOf([]uint64(nil))
+var ubig_ts = reflect.TypeOf([]*big.Int(nil))
+
+var int_ts = reflect.TypeOf([]int(nil))
+var int8_ts = reflect.TypeOf([]int8(nil))
+var int16_ts = reflect.TypeOf([]int16(nil))
+var int32_ts = reflect.TypeOf([]int32(nil))
+var int64_ts = reflect.TypeOf([]int64(nil))
+var big_ts = reflect.TypeOf([]*big.Int(nil))
+
+// U256 will ensure unsigned 256bit on big nums
+func U256(n *big.Int) []byte {
+ return common.LeftPadBytes(common.U256(n).Bytes(), 32)
+}
+
+func S256(n *big.Int) []byte {
+ sint := common.S256(n)
+ ret := common.LeftPadBytes(sint.Bytes(), 32)
+ if sint.Cmp(common.Big0) < 0 {
+ for i, b := range ret {
+ if b == 0 {
+ ret[i] = 1
+ continue
+ }
+ break
+ }
+ }
+
+ return ret
+}
+
+// S256 will ensure signed 256bit on big nums
+func U2U256(n uint64) []byte {
+ return U256(big.NewInt(int64(n)))
+}
+
+func S2S256(n int64) []byte {
+ return S256(big.NewInt(n))
+}
+
+// packNum packs the given number (using the reflect value) and will cast it to appropriate number representation
+func packNum(value reflect.Value, to byte) []byte {
+ switch kind := value.Kind(); kind {
+ case reflect.Uint, reflect.Uint8, reflect.Uint16, reflect.Uint32, reflect.Uint64:
+ if to == UintTy {
+ return U2U256(value.Uint())
+ } else {
+ return S2S256(int64(value.Uint()))
+ }
+ case reflect.Int, reflect.Int8, reflect.Int16, reflect.Int32, reflect.Int64:
+ if to == UintTy {
+ return U2U256(uint64(value.Int()))
+ } else {
+ return S2S256(value.Int())
+ }
+ case reflect.Ptr:
+ // This only takes care of packing and casting. No type checking is done here. It should be done prior to using this function.
+ if to == UintTy {
+ return U256(value.Interface().(*big.Int))
+ } else {
+ return S256(value.Interface().(*big.Int))
+ }
+
+ }
+
+ return nil
+}
+
+// checks whether the given reflect value is signed. This also works for slices with a number type
+func isSigned(v reflect.Value) bool {
+ switch v.Type() {
+ case ubig_ts, big_ts, big_t, ubig_t:
+ return true
+ case int_ts, int8_ts, int16_ts, int32_ts, int64_ts, int_t, int8_t, int16_t, int32_t, int64_t:
+ return true
+ }
+ return false
+}
diff --git a/accounts/abi/numbers_test.go b/accounts/abi/numbers_test.go
new file mode 100644
index 000000000..319d7fb51
--- /dev/null
+++ b/accounts/abi/numbers_test.go
@@ -0,0 +1,72 @@
+package abi
+
+import (
+ "bytes"
+ "math/big"
+ "reflect"
+ "testing"
+)
+
+func TestNumberTypes(t *testing.T) {
+ ubytes := make([]byte, 32)
+ ubytes[31] = 1
+ sbytesmin := []byte{1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1}
+
+ unsigned := U256(big.NewInt(1))
+ if !bytes.Equal(unsigned, ubytes) {
+ t.Error("expected %x got %x", ubytes, unsigned)
+ }
+
+ signed := S256(big.NewInt(1))
+ if !bytes.Equal(signed, ubytes) {
+ t.Error("expected %x got %x", ubytes, unsigned)
+ }
+
+ signed = S256(big.NewInt(-1))
+ if !bytes.Equal(signed, sbytesmin) {
+ t.Error("expected %x got %x", ubytes, unsigned)
+ }
+}
+
+func TestPackNumber(t *testing.T) {
+ ubytes := make([]byte, 32)
+ ubytes[31] = 1
+ sbytesmin := []byte{1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1}
+ maxunsigned := []byte{255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255}
+
+ packed := packNum(reflect.ValueOf(1), IntTy)
+ if !bytes.Equal(packed, ubytes) {
+ t.Errorf("expected %x got %x", ubytes, packed)
+ }
+ packed = packNum(reflect.ValueOf(-1), IntTy)
+ if !bytes.Equal(packed, sbytesmin) {
+ t.Errorf("expected %x got %x", ubytes, packed)
+ }
+ packed = packNum(reflect.ValueOf(1), UintTy)
+ if !bytes.Equal(packed, ubytes) {
+ t.Errorf("expected %x got %x", ubytes, packed)
+ }
+ packed = packNum(reflect.ValueOf(-1), UintTy)
+ if !bytes.Equal(packed, maxunsigned) {
+ t.Errorf("expected %x got %x", maxunsigned, packed)
+ }
+
+ packed = packNum(reflect.ValueOf("string"), UintTy)
+ if packed != nil {
+ t.Errorf("expected 'string' to pack to nil. got %x instead", packed)
+ }
+}
+
+func TestSigned(t *testing.T) {
+ if isSigned(reflect.ValueOf(uint(10))) {
+ t.Error()
+ }
+
+ if !isSigned(reflect.ValueOf(int(10))) {
+ t.Error()
+ }
+
+ if !isSigned(reflect.ValueOf(big.NewInt(10))) {
+ t.Error()
+ }
+}
diff --git a/accounts/abi/type.go b/accounts/abi/type.go
new file mode 100644
index 000000000..56520b672
--- /dev/null
+++ b/accounts/abi/type.go
@@ -0,0 +1,190 @@
+package abi
+
+import (
+ "fmt"
+ "reflect"
+ "regexp"
+ "strconv"
+
+ "github.com/ethereum/go-ethereum/common"
+)
+
+const (
+ IntTy byte = iota
+ UintTy
+ BoolTy
+ SliceTy
+ AddressTy
+ RealTy
+)
+
+// Type is the reflection of the supported argument type
+type Type struct {
+ Kind reflect.Kind
+ Type reflect.Type
+ Size int
+ T byte // Our own type checking
+ stringKind string // holds the unparsed string for deriving signatures
+}
+
+// New type returns a fully parsed Type given by the input string or an error if it can't be parsed.
+//
+// Strings can be in the format of:
+//
+// Input = Type [ "[" [ Number ] "]" ] Name .
+// Type = [ "u" ] "int" [ Number ] .
+//
+// Examples:
+//
+// string int uint real
+// string32 int8 uint8 uint[]
+// address int256 uint256 real[2]
+func NewType(t string) (typ Type, err error) {
+ // 1. full string 2. type 3. (opt.) is slice 4. (opt.) size
+ freg, err := regexp.Compile("([a-zA-Z0-9]+)(\\[([0-9]*)?\\])?")
+ if err != nil {
+ return Type{}, err
+ }
+ res := freg.FindAllStringSubmatch(t, -1)[0]
+ var (
+ isslice bool
+ size int
+ )
+ switch {
+ case res[3] != "":
+ // err is ignored. Already checked for number through the regexp
+ size, _ = strconv.Atoi(res[3])
+ isslice = true
+ case res[2] != "":
+ isslice = true
+ size = -1
+ case res[0] == "":
+ return Type{}, fmt.Errorf("type parse error for `%s`", t)
+ }
+
+ treg, err := regexp.Compile("([a-zA-Z]+)([0-9]*)?")
+ if err != nil {
+ return Type{}, err
+ }
+
+ parsedType := treg.FindAllStringSubmatch(res[1], -1)[0]
+ vsize, _ := strconv.Atoi(parsedType[2])
+ vtype := parsedType[1]
+ // substitute canonical representation
+ if vsize == 0 && (vtype == "int" || vtype == "uint") {
+ vsize = 256
+ t += "256"
+ }
+
+ if isslice {
+ typ.Kind = reflect.Slice
+ typ.Size = size
+ switch vtype {
+ case "int":
+ typ.Type = big_ts
+ case "uint":
+ typ.Type = ubig_ts
+ default:
+ return Type{}, fmt.Errorf("unsupported arg slice type: %s", t)
+ }
+ } else {
+ switch vtype {
+ case "int":
+ typ.Kind = reflect.Ptr
+ typ.Type = big_t
+ typ.Size = 256
+ typ.T = IntTy
+ case "uint":
+ typ.Kind = reflect.Ptr
+ typ.Type = ubig_t
+ typ.Size = 256
+ typ.T = UintTy
+ case "bool":
+ typ.Kind = reflect.Bool
+ case "real": // TODO
+ typ.Kind = reflect.Invalid
+ case "address":
+ typ.Kind = reflect.Slice
+ typ.Type = byte_ts
+ typ.Size = 20
+ typ.T = AddressTy
+ case "string":
+ typ.Kind = reflect.String
+ typ.Size = -1
+ if vsize > 0 {
+ typ.Size = 32
+ }
+ default:
+ return Type{}, fmt.Errorf("unsupported arg type: %s", t)
+ }
+ }
+ typ.stringKind = t
+
+ return
+}
+
+func (t Type) String() (out string) {
+ return t.stringKind
+}
+
+// Test the given input parameter `v` and checks if it matches certain
+// criteria
+// * Big integers are checks for ptr types and if the given value is
+// assignable
+// * Integer are checked for size
+// * Strings, addresses and bytes are checks for type and size
+func (t Type) pack(v interface{}) ([]byte, error) {
+ value := reflect.ValueOf(v)
+ switch kind := value.Kind(); kind {
+ case reflect.Uint, reflect.Uint8, reflect.Uint16, reflect.Uint32, reflect.Uint64:
+ if t.Type != ubig_t {
+ return nil, fmt.Errorf("type mismatch: %s for %T", t.Type, v)
+ }
+ return packNum(value, t.T), nil
+ case reflect.Int, reflect.Int8, reflect.Int16, reflect.Int32, reflect.Int64:
+ if t.Type != ubig_t {
+ return nil, fmt.Errorf("type mismatch: %s for %T", t.Type, v)
+ }
+ return packNum(value, t.T), nil
+ case reflect.Ptr:
+ // If the value is a ptr do a assign check (only used by
+ // big.Int for now)
+ if t.Type == ubig_t && value.Type() != ubig_t {
+ return nil, fmt.Errorf("type mismatch: %s for %T", t.Type, v)
+ }
+ return packNum(value, t.T), nil
+ case reflect.String:
+ if t.Size > -1 && value.Len() > t.Size {
+ return nil, fmt.Errorf("%v out of bound. %d for %d", value.Kind(), value.Len(), t.Size)
+ }
+ return []byte(common.LeftPadString(t.String(), 32)), nil
+ case reflect.Slice:
+ if t.Size > -1 && value.Len() > t.Size {
+ return nil, fmt.Errorf("%v out of bound. %d for %d", value.Kind(), value.Len(), t.Size)
+ }
+
+ // Address is a special slice. The slice acts as one rather than a list of elements.
+ if t.T == AddressTy {
+ return common.LeftPadBytes(v.([]byte), 32), nil
+ }
+
+ // Signed / Unsigned check
+ if (t.T != IntTy && isSigned(value)) || (t.T == UintTy && isSigned(value)) {
+ return nil, fmt.Errorf("slice of incompatible types.")
+ }
+
+ var packed []byte
+ for i := 0; i < value.Len(); i++ {
+ packed = append(packed, packNum(value.Index(i), t.T)...)
+ }
+ return packed, nil
+ case reflect.Bool:
+ if value.Bool() {
+ return common.LeftPadBytes(common.Big1.Bytes(), 32), nil
+ } else {
+ return common.LeftPadBytes(common.Big0.Bytes(), 32), nil
+ }
+ }
+
+ panic("unreached")
+}
diff --git a/accounts/account_manager.go b/accounts/account_manager.go
new file mode 100644
index 000000000..e9eb8f816
--- /dev/null
+++ b/accounts/account_manager.go
@@ -0,0 +1,237 @@
+/*
+ This file is part of go-ethereum
+
+ go-ethereum is free software: you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published by
+ the Free Software Foundation, either version 3 of the License, or
+ (at your option) any later version.
+
+ go-ethereum is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with go-ethereum. If not, see <http://www.gnu.org/licenses/>.
+*/
+/**
+ * @authors
+ * Gustav Simonsson <gustav.simonsson@gmail.com>
+ * @date 2015
+ *
+ */
+/*
+
+This abstracts part of a user's interaction with an account she controls.
+It's not an abstraction of core Ethereum accounts data type / logic -
+for that see the core processing code of blocks / txs.
+
+Currently this is pretty much a passthrough to the KeyStore2 interface,
+and accounts persistence is derived from stored keys' addresses
+
+*/
+package accounts
+
+import (
+ "bytes"
+ "crypto/ecdsa"
+ crand "crypto/rand"
+ "errors"
+ "os"
+ "sync"
+ "time"
+
+ "github.com/ethereum/go-ethereum/crypto"
+)
+
+var (
+ ErrLocked = errors.New("account is locked")
+ ErrNoKeys = errors.New("no keys in store")
+)
+
+type Account struct {
+ Address []byte
+}
+
+type Manager struct {
+ keyStore crypto.KeyStore2
+ unlocked map[string]*unlocked
+ mutex sync.RWMutex
+}
+
+type unlocked struct {
+ *crypto.Key
+ abort chan struct{}
+}
+
+func NewManager(keyStore crypto.KeyStore2) *Manager {
+ return &Manager{
+ keyStore: keyStore,
+ unlocked: make(map[string]*unlocked),
+ }
+}
+
+func (am *Manager) HasAccount(addr []byte) bool {
+ accounts, _ := am.Accounts()
+ for _, acct := range accounts {
+ if bytes.Compare(acct.Address, addr) == 0 {
+ return true
+ }
+ }
+ return false
+}
+
+func (am *Manager) Primary() (addr []byte, err error) {
+ addrs, err := am.keyStore.GetKeyAddresses()
+ if os.IsNotExist(err) {
+ return nil, ErrNoKeys
+ } else if err != nil {
+ return nil, err
+ }
+ if len(addrs) == 0 {
+ return nil, ErrNoKeys
+ }
+ return addrs[0], nil
+}
+
+func (am *Manager) DeleteAccount(address []byte, auth string) error {
+ return am.keyStore.DeleteKey(address, auth)
+}
+
+func (am *Manager) Sign(a Account, toSign []byte) (signature []byte, err error) {
+ am.mutex.RLock()
+ unlockedKey, found := am.unlocked[string(a.Address)]
+ am.mutex.RUnlock()
+ if !found {
+ return nil, ErrLocked
+ }
+ signature, err = crypto.Sign(toSign, unlockedKey.PrivateKey)
+ return signature, err
+}
+
+// TimedUnlock unlocks the account with the given address.
+// When timeout has passed, the account will be locked again.
+func (am *Manager) TimedUnlock(addr []byte, keyAuth string, timeout time.Duration) error {
+ key, err := am.keyStore.GetKey(addr, keyAuth)
+ if err != nil {
+ return err
+ }
+ u := am.addUnlocked(addr, key)
+ go am.dropLater(addr, u, timeout)
+ return nil
+}
+
+// Unlock unlocks the account with the given address. The account
+// stays unlocked until the program exits or until a TimedUnlock
+// timeout (started after the call to Unlock) expires.
+func (am *Manager) Unlock(addr []byte, keyAuth string) error {
+ key, err := am.keyStore.GetKey(addr, keyAuth)
+ if err != nil {
+ return err
+ }
+ am.addUnlocked(addr, key)
+ return nil
+}
+
+func (am *Manager) NewAccount(auth string) (Account, error) {
+ key, err := am.keyStore.GenerateNewKey(crand.Reader, auth)
+ if err != nil {
+ return Account{}, err
+ }
+ return Account{Address: key.Address}, nil
+}
+
+func (am *Manager) Accounts() ([]Account, error) {
+ addresses, err := am.keyStore.GetKeyAddresses()
+ if os.IsNotExist(err) {
+ return nil, ErrNoKeys
+ } else if err != nil {
+ return nil, err
+ }
+ accounts := make([]Account, len(addresses))
+ for i, addr := range addresses {
+ accounts[i] = Account{
+ Address: addr,
+ }
+ }
+ return accounts, err
+}
+
+func (am *Manager) addUnlocked(addr []byte, key *crypto.Key) *unlocked {
+ u := &unlocked{Key: key, abort: make(chan struct{})}
+ am.mutex.Lock()
+ prev, found := am.unlocked[string(addr)]
+ if found {
+ // terminate dropLater for this key to avoid unexpected drops.
+ close(prev.abort)
+ // the key is zeroed here instead of in dropLater because
+ // there might not actually be a dropLater running for this
+ // key, i.e. when Unlock was used.
+ zeroKey(prev.PrivateKey)
+ }
+ am.unlocked[string(addr)] = u
+ am.mutex.Unlock()
+ return u
+}
+
+func (am *Manager) dropLater(addr []byte, u *unlocked, timeout time.Duration) {
+ t := time.NewTimer(timeout)
+ defer t.Stop()
+ select {
+ case <-u.abort:
+ // just quit
+ case <-t.C:
+ am.mutex.Lock()
+ // only drop if it's still the same key instance that dropLater
+ // was launched with. we can check that using pointer equality
+ // because the map stores a new pointer every time the key is
+ // unlocked.
+ if am.unlocked[string(addr)] == u {
+ zeroKey(u.PrivateKey)
+ delete(am.unlocked, string(addr))
+ }
+ am.mutex.Unlock()
+ }
+}
+
+// zeroKey zeroes a private key in memory.
+func zeroKey(k *ecdsa.PrivateKey) {
+ b := k.D.Bits()
+ for i := range b {
+ b[i] = 0
+ }
+}
+
+// USE WITH CAUTION = this will save an unencrypted private key on disk
+// no cli or js interface
+func (am *Manager) Export(path string, addr []byte, keyAuth string) error {
+ key, err := am.keyStore.GetKey(addr, keyAuth)
+ if err != nil {
+ return err
+ }
+ return crypto.SaveECDSA(path, key.PrivateKey)
+}
+
+func (am *Manager) Import(path string, keyAuth string) (Account, error) {
+ privateKeyECDSA, err := crypto.LoadECDSA(path)
+ if err != nil {
+ return Account{}, err
+ }
+ key := crypto.NewKeyFromECDSA(privateKeyECDSA)
+ if err = am.keyStore.StoreKey(key, keyAuth); err != nil {
+ return Account{}, err
+ }
+ return Account{Address: key.Address}, nil
+}
+
+func (am *Manager) ImportPreSaleKey(keyJSON []byte, password string) (acc Account, err error) {
+ var key *crypto.Key
+ key, err = crypto.ImportPreSaleKey(am.keyStore, keyJSON, password)
+ if err != nil {
+ return
+ }
+ if err = am.keyStore.StoreKey(key, password); err != nil {
+ return
+ }
+ return Account{Address: key.Address}, nil
+}
diff --git a/accounts/accounts_test.go b/accounts/accounts_test.go
new file mode 100644
index 000000000..427114cbd
--- /dev/null
+++ b/accounts/accounts_test.go
@@ -0,0 +1,69 @@
+package accounts
+
+import (
+ "io/ioutil"
+ "os"
+ "testing"
+ "time"
+
+ "github.com/ethereum/go-ethereum/crypto"
+ "github.com/ethereum/go-ethereum/crypto/randentropy"
+)
+
+func TestSign(t *testing.T) {
+ dir, ks := tmpKeyStore(t, crypto.NewKeyStorePlain)
+ defer os.RemoveAll(dir)
+
+ am := NewManager(ks)
+ pass := "" // not used but required by API
+ a1, err := am.NewAccount(pass)
+ toSign := randentropy.GetEntropyCSPRNG(32)
+ am.Unlock(a1.Address, "")
+
+ _, err = am.Sign(a1, toSign)
+ if err != nil {
+ t.Fatal(err)
+ }
+}
+
+func TestTimedUnlock(t *testing.T) {
+ dir, ks := tmpKeyStore(t, crypto.NewKeyStorePassphrase)
+ defer os.RemoveAll(dir)
+
+ am := NewManager(ks)
+ pass := "foo"
+ a1, err := am.NewAccount(pass)
+ toSign := randentropy.GetEntropyCSPRNG(32)
+
+ // Signing without passphrase fails because account is locked
+ _, err = am.Sign(a1, toSign)
+ if err != ErrLocked {
+ t.Fatal("Signing should've failed with ErrLocked before unlocking, got ", err)
+ }
+
+ // Signing with passphrase works
+ if err = am.TimedUnlock(a1.Address, pass, 100*time.Millisecond); err != nil {
+ t.Fatal(err)
+ }
+
+ // Signing without passphrase works because account is temp unlocked
+ _, err = am.Sign(a1, toSign)
+ if err != nil {
+ t.Fatal("Signing shouldn't return an error after unlocking, got ", err)
+ }
+
+ // Signing fails again after automatic locking
+ time.Sleep(150 * time.Millisecond)
+ _, err = am.Sign(a1, toSign)
+ if err != ErrLocked {
+ t.Fatal("Signing should've failed with ErrLocked timeout expired, got ", err)
+ }
+}
+
+func tmpKeyStore(t *testing.T, new func(string) crypto.KeyStore2) (string, crypto.KeyStore2) {
+ d, err := ioutil.TempDir("", "eth-keystore-test")
+ if err != nil {
+ t.Fatal(err)
+ }
+ return d, new(d)
+}
diff --git a/blockpool/blockpool.go b/blockpool/blockpool.go
new file mode 100644
index 000000000..d9f8e3baa
--- /dev/null
+++ b/blockpool/blockpool.go
@@ -0,0 +1,874 @@
+package blockpool
+
+import (
+ "fmt"
+ "math/big"
+ "sync"
+ "time"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/core"
+ "github.com/ethereum/go-ethereum/core/types"
+ "github.com/ethereum/go-ethereum/errs"
+ "github.com/ethereum/go-ethereum/event"
+ ethlogger "github.com/ethereum/go-ethereum/logger"
+ "github.com/ethereum/go-ethereum/pow"
+)
+
+var plog = ethlogger.NewLogger("Blockpool")
+
+var (
+ // max number of block hashes sent in one request
+ blockHashesBatchSize = 256
+ // max number of blocks sent in one request
+ blockBatchSize = 64
+ // interval between two consecutive block checks (and requests)
+ blocksRequestInterval = 3 * time.Second
+ // level of redundancy in block requests sent
+ blocksRequestRepetition = 1
+ // interval between two consecutive block hash checks (and requests)
+ blockHashesRequestInterval = 3 * time.Second
+ // max number of idle iterations, ie., check through a section without new blocks coming in
+ blocksRequestMaxIdleRounds = 20
+ // timeout interval: max time allowed for peer without sending a block hash
+ blockHashesTimeout = 60 * time.Second
+ // timeout interval: max time allowed for peer without sending a block
+ blocksTimeout = 60 * time.Second
+ // timeout interval: max time allowed for best peer to remain idle (not send new block after sync complete)
+ idleBestPeerTimeout = 120 * time.Second
+ // duration of suspension after peer fatal error during which peer is not allowed to reconnect
+ peerSuspensionInterval = 300 * time.Second
+ // status is logged every statusUpdateInterval
+ statusUpdateInterval = 3 * time.Second
+)
+
+// blockpool config, values default to constants
+type Config struct {
+ BlockHashesBatchSize int
+ BlockBatchSize int
+ BlocksRequestRepetition int
+ BlocksRequestMaxIdleRounds int
+ BlockHashesRequestInterval time.Duration
+ BlocksRequestInterval time.Duration
+ BlockHashesTimeout time.Duration
+ BlocksTimeout time.Duration
+ IdleBestPeerTimeout time.Duration
+ PeerSuspensionInterval time.Duration
+ StatusUpdateInterval time.Duration
+}
+
+// blockpool errors
+const (
+ ErrInvalidBlock = iota
+ ErrInvalidPoW
+ ErrInsufficientChainInfo
+ ErrIdleTooLong
+ ErrIncorrectTD
+ ErrUnrequestedBlock
+)
+
+// error descriptions
+var errorToString = map[int]string{
+ ErrInvalidBlock: "Invalid block", // fatal
+ ErrInvalidPoW: "Invalid PoW", // fatal
+ ErrInsufficientChainInfo: "Insufficient chain info", // fatal
+ ErrIdleTooLong: "Idle too long", // fatal
+ ErrIncorrectTD: "Incorrect Total Difficulty", // fatal
+ ErrUnrequestedBlock: "Unrequested block",
+}
+
+// error severity
+func severity(code int) ethlogger.LogLevel {
+ switch code {
+ case ErrUnrequestedBlock:
+ return ethlogger.WarnLevel
+ default:
+ return ethlogger.ErrorLevel
+ }
+}
+
+// init initialises the Config, zero values fall back to constants
+func (self *Config) init() {
+ if self.BlockHashesBatchSize == 0 {
+ self.BlockHashesBatchSize = blockHashesBatchSize
+ }
+ if self.BlockBatchSize == 0 {
+ self.BlockBatchSize = blockBatchSize
+ }
+ if self.BlocksRequestRepetition == 0 {
+ self.BlocksRequestRepetition = blocksRequestRepetition
+ }
+ if self.BlocksRequestMaxIdleRounds == 0 {
+ self.BlocksRequestMaxIdleRounds = blocksRequestMaxIdleRounds
+ }
+ if self.BlockHashesRequestInterval == 0 {
+ self.BlockHashesRequestInterval = blockHashesRequestInterval
+ }
+ if self.BlocksRequestInterval == 0 {
+ self.BlocksRequestInterval = blocksRequestInterval
+ }
+ if self.BlockHashesTimeout == 0 {
+ self.BlockHashesTimeout = blockHashesTimeout
+ }
+ if self.BlocksTimeout == 0 {
+ self.BlocksTimeout = blocksTimeout
+ }
+ if self.IdleBestPeerTimeout == 0 {
+ self.IdleBestPeerTimeout = idleBestPeerTimeout
+ }
+ if self.PeerSuspensionInterval == 0 {
+ self.PeerSuspensionInterval = peerSuspensionInterval
+ }
+ if self.StatusUpdateInterval == 0 {
+ self.StatusUpdateInterval = statusUpdateInterval
+ }
+}
+
+// node is the basic unit of the internal model of block chain/tree in the blockpool
+type node struct {
+ lock sync.RWMutex
+ hash common.Hash
+ block *types.Block
+ hashBy string
+ blockBy string
+ td *big.Int
+}
+
+type index struct {
+ int
+}
+
+// entry is the struct kept and indexed in the pool
+type entry struct {
+ node *node
+ section *section
+ index *index
+}
+
+type BlockPool struct {
+ Config *Config
+
+ // the minimal interface with blockchain manager
+ hasBlock func(hash common.Hash) bool // query if block is known
+ insertChain func(types.Blocks) error // add section to blockchain
+ verifyPoW func(pow.Block) bool // soft PoW verification
+ chainEvents *event.TypeMux // ethereum eventer for chainEvents
+
+ tdSub event.Subscription // subscription to core.ChainHeadEvent
+ td *big.Int // our own total difficulty
+
+ pool map[common.Hash]*entry // the actual blockpool
+ peers *peers // peers manager in peers.go
+
+ status *status // info about blockpool (UI interface) in status.go
+
+ lock sync.RWMutex
+ chainLock sync.RWMutex
+ // alloc-easy pool of hash slices
+ hashSlicePool chan []common.Hash
+
+ // waitgroup is used in tests to wait for result-critical routines
+ // as well as in determining idle / syncing status
+ wg sync.WaitGroup //
+ quit chan bool // chan used for quitting parallel routines
+ running bool //
+}
+
+// public constructor
+// after blockpool returned, config can be set
+// BlockPool.Start will call Config.init to set missing values
+func New(
+ hasBlock func(hash common.Hash) bool,
+ insertChain func(types.Blocks) error,
+ verifyPoW func(pow.Block) bool,
+ chainEvents *event.TypeMux,
+ td *big.Int,
+) *BlockPool {
+
+ return &BlockPool{
+ Config: &Config{},
+ hasBlock: hasBlock,
+ insertChain: insertChain,
+ verifyPoW: verifyPoW,
+ chainEvents: chainEvents,
+ td: td,
+ }
+}
+
+// allows restart
+func (self *BlockPool) Start() {
+ self.lock.Lock()
+ defer self.lock.Unlock()
+
+ if self.running {
+ return
+ }
+
+ // set missing values
+ self.Config.init()
+
+ self.hashSlicePool = make(chan []common.Hash, 150)
+ self.status = newStatus()
+ self.quit = make(chan bool)
+ self.pool = make(map[common.Hash]*entry)
+ self.running = true
+
+ self.peers = &peers{
+ errors: &errs.Errors{
+ Package: "Blockpool",
+ Errors: errorToString,
+ Level: severity,
+ },
+ peers: make(map[string]*peer),
+ blacklist: make(map[string]time.Time),
+ status: self.status,
+ bp: self,
+ }
+
+ // subscribe and listen to core.ChainHeadEvent{} for uptodate TD
+ self.tdSub = self.chainEvents.Subscribe(core.ChainHeadEvent{})
+
+ // status update interval
+ timer := time.NewTicker(self.Config.StatusUpdateInterval)
+ go func() {
+ for {
+ select {
+ case <-self.quit:
+ return
+ case event := <-self.tdSub.Chan():
+ if ev, ok := event.(core.ChainHeadEvent); ok {
+ td := ev.Block.Td
+ var height *big.Int
+ if (ev.Block.HeaderHash == common.Hash{}) {
+ height = ev.Block.Header().Number
+ }
+ plog.DebugDetailf("ChainHeadEvent: height: %v, td: %v, hash: %s", height, td, hex(ev.Block.Hash()))
+ self.setTD(td)
+ self.peers.lock.Lock()
+
+ if best := self.peers.best; best != nil {
+ // only switch if we strictly go above otherwise we may stall if only
+ if td.Cmp(best.td) > 0 {
+ self.peers.best = nil
+ self.switchPeer(best, nil)
+ }
+ }
+ self.peers.lock.Unlock()
+ }
+ case <-timer.C:
+ plog.DebugDetailf("status:\n%v", self.Status())
+ }
+ }
+ }()
+ plog.Infoln("Started")
+}
+
+func (self *BlockPool) Stop() {
+ self.lock.Lock()
+ if !self.running {
+ self.lock.Unlock()
+ return
+ }
+ self.running = false
+
+ self.lock.Unlock()
+
+ plog.Infoln("Stopping...")
+
+ self.tdSub.Unsubscribe()
+ close(self.quit)
+
+ self.lock.Lock()
+ self.peers = nil
+ self.pool = nil
+ self.lock.Unlock()
+
+ plog.Infoln("Stopped")
+}
+
+// Wait blocks until active processes finish
+func (self *BlockPool) Wait(t time.Duration) {
+ self.lock.Lock()
+ if !self.running {
+ self.lock.Unlock()
+ return
+ }
+ self.lock.Unlock()
+
+ plog.Infoln("Waiting for processes to complete...")
+ w := make(chan bool)
+ go func() {
+ self.wg.Wait()
+ close(w)
+ }()
+
+ select {
+ case <-w:
+ plog.Infoln("Processes complete")
+ case <-time.After(t):
+ plog.Warnf("Timeout")
+ }
+}
+
+/*
+AddPeer is called by the eth protocol instance running on the peer after
+the status message has been received with total difficulty and current block hash
+
+Called a second time with the same peer id, it is used to update chain info for a peer.
+This is used when a new (mined) block message is received.
+
+RemovePeer needs to be called when the peer disconnects.
+
+Peer info is currently not persisted across disconnects (or sessions) except for suspension
+
+*/
+func (self *BlockPool) AddPeer(
+
+ td *big.Int, currentBlockHash common.Hash,
+ peerId string,
+ requestBlockHashes func(common.Hash) error,
+ requestBlocks func([]common.Hash) error,
+ peerError func(*errs.Error),
+
+) (best bool, suspended bool) {
+
+ return self.peers.addPeer(td, currentBlockHash, peerId, requestBlockHashes, requestBlocks, peerError)
+}
+
+// RemovePeer needs to be called when the peer disconnects
+func (self *BlockPool) RemovePeer(peerId string) {
+ self.peers.removePeer(peerId)
+}
+
+/*
+AddBlockHashes
+
+Entry point for eth protocol to add block hashes received via BlockHashesMsg
+
+Only hashes from the best peer are handled
+
+Initiates further hash requests until a known parent is reached (unless cancelled by a peerSwitch event, i.e., when a better peer becomes best peer)
+Launches all block request processes on each chain section
+
+The first argument is an iterator function. Using this block hashes are decoded from the rlp message payload on demand. As a result, AddBlockHashes needs to run synchronously for one peer since the message is discarded if the caller thread returns.
+*/
+func (self *BlockPool) AddBlockHashes(next func() (common.Hash, bool), peerId string) {
+
+ bestpeer, best := self.peers.getPeer(peerId)
+ if !best {
+ return
+ }
+ // bestpeer is still the best peer
+
+ self.wg.Add(1)
+ defer func() { self.wg.Done() }()
+
+ self.status.lock.Lock()
+ self.status.activePeers[bestpeer.id]++
+ self.status.lock.Unlock()
+
+ var n int
+ var hash common.Hash
+ var ok, headSection, peerswitch bool
+ var sec, child, parent *section
+ var entry *entry
+ var nodes []*node
+
+ hash, ok = next()
+ bestpeer.lock.Lock()
+
+ plog.Debugf("AddBlockHashes: peer <%s> starting from [%s] (peer head: %s)", peerId, hex(bestpeer.parentHash), hex(bestpeer.currentBlockHash))
+
+ // first check if we are building the head section of a peer's chain
+ if bestpeer.parentHash == hash {
+ if self.hasBlock(bestpeer.currentBlockHash) {
+ return
+ }
+ /*
+ When peer is promoted in switchPeer, a new header section process is launched.
+ Once the head section skeleton is actually created here, it is signaled to the process
+ so that it can quit.
+ In the special case that the node for parent of the head block is found in the blockpool
+ (with or without fetched block), a singleton section containing only the head block node is created.
+ */
+ headSection = true
+ if entry := self.get(bestpeer.currentBlockHash); entry == nil {
+ plog.DebugDetailf("AddBlockHashes: peer <%s> (head: %s) head section starting from [%s] ", peerId, hex(bestpeer.currentBlockHash), hex(bestpeer.parentHash))
+ // if head block is not yet in the pool, create entry and start node list for section
+ node := &node{
+ hash: bestpeer.currentBlockHash,
+ block: bestpeer.currentBlock,
+ hashBy: peerId,
+ blockBy: peerId,
+ td: bestpeer.td,
+ }
+ // nodes is a list of nodes in one section ordered top-bottom (old to young)
+ nodes = append(nodes, node)
+ n++
+ } else {
+ // otherwise set child section iff found node is the root of a section
+ // this is a possible scenario when a singleton head section was created
+ // on an earlier occasion when this peer or another with the same block was best peer
+ if entry.node == entry.section.bottom {
+ child = entry.section
+ plog.DebugDetailf("AddBlockHashes: peer <%s>: connects to child section root %s", peerId, hex(bestpeer.currentBlockHash))
+ }
+ }
+ } else {
+ // otherwise : we are not building the head section of the peer
+ plog.DebugDetailf("AddBlockHashes: peer <%s> (head: %s) section starting from [%s] ", peerId, hex(bestpeer.currentBlockHash), hex(hash))
+ }
+ // the switch channel signals peerswitch event
+ switchC := bestpeer.switchC
+ bestpeer.lock.Unlock()
+
+ // iterate over hashes coming from peer (first round we have hash set above)
+LOOP:
+ for ; ok; hash, ok = next() {
+
+ select {
+ case <-self.quit:
+ // global quit for blockpool
+ return
+
+ case <-switchC:
+ // if the peer is demoted, no more hashes read
+ plog.DebugDetailf("AddBlockHashes: demoted peer <%s> (head: %s)", peerId, hex(bestpeer.currentBlockHash), hex(hash))
+ peerswitch = true
+ break LOOP
+ default:
+ }
+
+ // if we reach the blockchain we stop reading further blockhashes
+ if self.hasBlock(hash) {
+ // check if known block connecting the downloaded chain to our blockchain
+ plog.DebugDetailf("AddBlockHashes: peer <%s> (head: %s) found block %s in the blockchain", peerId, hex(bestpeer.currentBlockHash), hex(hash))
+ if len(nodes) == 1 {
+ plog.DebugDetailf("AddBlockHashes: singleton section pushed to blockchain peer <%s> (head: %s) found block %s in the blockchain", peerId, hex(bestpeer.currentBlockHash), hex(hash))
+
+ // create new section if needed and push it to the blockchain
+ sec = self.newSection(nodes)
+ sec.addSectionToBlockChain(bestpeer)
+ } else {
+
+ /*
+ not added hash yet but according to peer child section built
+ earlier chain connects with blockchain
+ this maybe a potential vulnarability
+ the root block arrives (or already there but its parenthash was not pointing to known block in the blockchain)
+ we start inserting -> error -> remove the entire chain
+ instead of punishing this peer
+ solution: when switching peers always make sure best peers own head block
+ and td together with blockBy are recorded on the node
+ */
+ if len(nodes) == 0 && child != nil {
+ plog.DebugDetailf("AddBlockHashes: child section [%s] pushed to blockchain peer <%s> (head: %s) found block %s in the blockchain", sectionhex(child), peerId, hex(bestpeer.currentBlockHash), hex(hash))
+
+ child.addSectionToBlockChain(bestpeer)
+ }
+ }
+ break LOOP
+ }
+
+ // look up node in the pool
+ entry = self.get(hash)
+ if entry != nil {
+ // reached a known chain in the pool
+ if entry.node == entry.section.bottom && n == 1 {
+ /*
+ The first block hash received is an orphan node in the pool
+
+ This also supports clients that (despite the spec) include <from> hash in their
+ response to hashes request. Note that by providing <from> we can link sections
+ without having to wait for the root block of the child section to arrive, so it allows for superior performance.
+ */
+ plog.DebugDetailf("AddBlockHashes: peer <%s> (head: %s) found head block [%s] as root of connecting child section [%s] skipping", peerId, hex(bestpeer.currentBlockHash), hex(hash), sectionhex(entry.section))
+ // record the entry's chain section as child section
+ child = entry.section
+ continue LOOP
+ }
+ // otherwise record entry's chain section as parent connecting it to the pool
+ plog.DebugDetailf("AddBlockHashes: peer <%s> (head: %s) found block [%s] in section [%s]. Connected to pool.", peerId, hex(bestpeer.currentBlockHash), hex(hash), sectionhex(entry.section))
+ parent = entry.section
+ break LOOP
+ }
+
+ // finally if node for block hash does not exist, create it and append node to section nodes
+ node := &node{
+ hash: hash,
+ hashBy: peerId,
+ }
+ nodes = append(nodes, node)
+ } //for
+
+ /*
+ we got here if
+ - run out of hashes (parent = nil) sent by our best peer
+ - our peer is demoted (peerswitch = true)
+ - reached blockchain or blockpool
+ - quitting
+ */
+ self.chainLock.Lock()
+
+ plog.DebugDetailf("AddBlockHashes: peer <%s> (head: %s): %v nodes in new section", peerId, hex(bestpeer.currentBlockHash), len(nodes))
+ /*
+ Handle forks where connecting node is mid-section by splitting section at fork.
+ No splitting needed if connecting node is head of a section.
+ */
+ if parent != nil && entry != nil && entry.node != parent.top && len(nodes) > 0 {
+ plog.DebugDetailf("AddBlockHashes: peer <%s> (head: %s): fork after %s", peerId, hex(bestpeer.currentBlockHash), hex(hash))
+
+ self.splitSection(parent, entry)
+
+ self.status.lock.Lock()
+ self.status.values.Forks++
+ self.status.lock.Unlock()
+ }
+
+ // If new section is created, link it to parent/child sections.
+ sec = self.linkSections(nodes, parent, child)
+
+ if sec != nil {
+ self.status.lock.Lock()
+ self.status.values.BlockHashes += len(nodes)
+ self.status.lock.Unlock()
+ plog.DebugDetailf("AddBlockHashes: peer <%s> (head: %s): section [%s] created", peerId, hex(bestpeer.currentBlockHash), sectionhex(sec))
+ }
+
+ self.chainLock.Unlock()
+
+ /*
+ If a blockpool node is reached (parent section is not nil),
+ activate section (unless our peer is demoted by now).
+ This can be the bottom half of a newly split section in case of a fork.
+
+ bestPeer is nil if we got here after our peer got demoted while processing.
+ In this case no activation should happen
+ */
+ if parent != nil && !peerswitch {
+ self.activateChain(parent, bestpeer, nil)
+ plog.DebugDetailf("AddBlockHashes: peer <%s> (head: %s): parent section [%s]", peerId, hex(bestpeer.currentBlockHash), sectionhex(parent))
+ }
+
+ /*
+ If a new section was created, register section iff head section or no child known
+ Activate it with this peer.
+ */
+ if sec != nil {
+ // switch on section process (it is paused by switchC)
+ if !peerswitch {
+ if headSection || child == nil {
+ bestpeer.lock.Lock()
+ bestpeer.sections = append(bestpeer.sections, sec.top.hash)
+ bestpeer.lock.Unlock()
+ }
+ /*
+ Request another batch of older block hashes for parent section here.
+ But only once, repeating only when the section's root block arrives.
+ Otherwise no way to check if it arrived.
+ */
+ bestpeer.requestBlockHashes(sec.bottom.hash)
+ plog.DebugDetailf("AddBlockHashes: peer <%s> (head: %s): start requesting blocks for section [%s]", peerId, hex(bestpeer.currentBlockHash), sectionhex(sec))
+ sec.activate(bestpeer)
+ } else {
+ plog.DebugDetailf("AddBlockHashes: peer <%s> (head: %s) no longer best: delay requesting blocks for section [%s]", peerId, hex(bestpeer.currentBlockHash), sectionhex(sec))
+ sec.deactivate()
+ }
+ }
+
+ // If we are processing peer's head section, signal it to headSection process that it is created.
+
+ if headSection {
+ plog.DebugDetailf("AddBlockHashes: peer <%s> (head: %s) head section registered on head section process", peerId, hex(bestpeer.currentBlockHash))
+
+ var headSec *section
+ switch {
+ case sec != nil:
+ headSec = sec
+ case child != nil:
+ headSec = child
+ default:
+ headSec = parent
+ }
+ if !peerswitch {
+ plog.DebugDetailf("AddBlockHashes: peer <%s> (head: %s) head section [%s] created signalled to head section process", peerId, hex(bestpeer.currentBlockHash), sectionhex(headSec))
+ bestpeer.headSectionC <- headSec
+ }
+ }
+}
+
+/*
+ AddBlock is the entry point for the eth protocol to call when blockMsg is received.
+
+ It has a strict interpretation of the protocol in that if the block received has not been requested, it results in an error.
+
+ At the same time it is opportunistic in that if a requested block may be provided by any peer.
+
+ The received block is checked for PoW. Only the first PoW-valid block for a hash is considered legit.
+
+ If the block received is the head block of the current best peer, signal it to the head section process
+*/
+func (self *BlockPool) AddBlock(block *types.Block, peerId string) {
+ hash := block.Hash()
+
+ sender, _ := self.peers.getPeer(peerId)
+ if sender == nil {
+ return
+ }
+
+ self.status.lock.Lock()
+ self.status.activePeers[peerId]++
+ self.status.lock.Unlock()
+
+ entry := self.get(hash)
+
+ // a peer's current head block is appearing the first time
+ if hash == sender.currentBlockHash {
+ if sender.currentBlock == nil {
+ plog.Debugf("AddBlock: add head block %s for peer <%s> (head: %s)", hex(hash), peerId, hex(sender.currentBlockHash))
+ sender.setChainInfoFromBlock(block)
+
+ self.status.lock.Lock()
+ self.status.values.BlockHashes++
+ self.status.values.Blocks++
+ self.status.values.BlocksInPool++
+ self.status.lock.Unlock()
+ } else {
+ plog.DebugDetailf("AddBlock: head block %s for peer <%s> (head: %s) already known", hex(hash), peerId, hex(sender.currentBlockHash))
+ // signal to head section process
+ sender.currentBlockC <- block
+ }
+ } else {
+
+ plog.DebugDetailf("AddBlock: block %s received from peer <%s> (head: %s)", hex(hash), peerId, hex(sender.currentBlockHash))
+
+ sender.lock.Lock()
+ // update peer chain info if more recent than what we registered
+ if block.Td != nil && block.Td.Cmp(sender.td) > 0 {
+ sender.td = block.Td
+ sender.currentBlockHash = block.Hash()
+ sender.parentHash = block.ParentHash()
+ sender.currentBlock = block
+ sender.headSection = nil
+ }
+ sender.lock.Unlock()
+
+ if entry == nil {
+ plog.DebugDetailf("AddBlock: unrequested block %s received from peer <%s> (head: %s)", hex(hash), peerId, hex(sender.currentBlockHash))
+ sender.addError(ErrUnrequestedBlock, "%x", hash)
+
+ self.status.lock.Lock()
+ self.status.badPeers[peerId]++
+ self.status.lock.Unlock()
+ return
+ }
+ }
+ if entry == nil {
+ return
+ }
+
+ node := entry.node
+ node.lock.Lock()
+ defer node.lock.Unlock()
+
+ // check if block already received
+ if node.block != nil {
+ plog.DebugDetailf("AddBlock: block %s from peer <%s> (head: %s) already sent by <%s> ", hex(hash), peerId, hex(sender.currentBlockHash), node.blockBy)
+ return
+ }
+
+ // check if block is already inserted in the blockchain
+ if self.hasBlock(hash) {
+ plog.DebugDetailf("AddBlock: block %s from peer <%s> (head: %s) already in the blockchain", hex(hash), peerId, hex(sender.currentBlockHash))
+ return
+ }
+
+ // validate block for PoW
+ if !self.verifyPoW(block) {
+ plog.Warnf("AddBlock: invalid PoW on block %s from peer <%s> (head: %s)", hex(hash), peerId, hex(sender.currentBlockHash))
+ sender.addError(ErrInvalidPoW, "%x", hash)
+
+ self.status.lock.Lock()
+ self.status.badPeers[peerId]++
+ self.status.lock.Unlock()
+
+ return
+ }
+
+ node.block = block
+ node.blockBy = peerId
+ node.td = block.Td // optional field
+
+ self.status.lock.Lock()
+ self.status.values.Blocks++
+ self.status.values.BlocksInPool++
+ self.status.lock.Unlock()
+
+}
+
+/*
+ activateChain iterates down a chain section by section.
+ It activates the section process on incomplete sections with peer.
+ It relinks orphaned sections with their parent if root block (and its parent hash) is known.
+*/
+func (self *BlockPool) activateChain(sec *section, p *peer, connected map[common.Hash]*section) {
+
+ p.lock.RLock()
+ switchC := p.switchC
+ p.lock.RUnlock()
+
+ var i int
+
+LOOP:
+ for sec != nil {
+ parent := self.getParent(sec)
+ plog.DebugDetailf("activateChain: section [%s] activated by peer <%s>", sectionhex(sec), p.id)
+ sec.activate(p)
+ if i > 0 && connected != nil {
+ connected[sec.top.hash] = sec
+ }
+ /*
+ Need to relink both complete and incomplete sections
+ An incomplete section could have been blockHashesRequestsComplete before being delinked from its parent.
+ */
+ if parent == nil {
+ if sec.bottom.block != nil {
+ if entry := self.get(sec.bottom.block.ParentHash()); entry != nil {
+ parent = entry.section
+ plog.DebugDetailf("activateChain: [%s]-[%s] link", sectionhex(parent), sectionhex(sec))
+ link(parent, sec)
+ }
+ } else {
+ plog.DebugDetailf("activateChain: section [%s] activated by peer <%s> has missing root block", sectionhex(sec), p.id)
+ }
+ }
+ sec = parent
+
+ // stop if peer got demoted or global quit
+ select {
+ case <-switchC:
+ break LOOP
+ case <-self.quit:
+ break LOOP
+ default:
+ }
+ }
+}
+
+// check if block's actual TD (calculated after successful insertChain) is identical to TD advertised for peer's head block.
+func (self *BlockPool) checkTD(nodes ...*node) {
+ for _, n := range nodes {
+ if n.td != nil {
+ plog.DebugDetailf("peer td %v =?= block td %v", n.td, n.block.Td)
+ if n.td.Cmp(n.block.Td) != 0 {
+ self.peers.peerError(n.blockBy, ErrIncorrectTD, "on block %x", n.hash)
+ self.status.lock.Lock()
+ self.status.badPeers[n.blockBy]++
+ self.status.lock.Unlock()
+ }
+ }
+ }
+}
+
+// requestBlocks must run in separate go routine, otherwise
+// switchpeer -> activateChain -> activate deadlocks on section process select and peers.lock
+func (self *BlockPool) requestBlocks(attempts int, hashes []common.Hash) {
+ self.wg.Add(1)
+ go func() {
+ self.peers.requestBlocks(attempts, hashes)
+ self.wg.Done()
+ }()
+}
+
+// convenience methods to access adjacent sections
+func (self *BlockPool) getParent(sec *section) *section {
+ self.chainLock.RLock()
+ defer self.chainLock.RUnlock()
+ return sec.parent
+}
+
+func (self *BlockPool) getChild(sec *section) *section {
+ self.chainLock.RLock()
+ defer self.chainLock.RUnlock()
+ return sec.child
+}
+
+// accessor and setter for entries in the pool
+func (self *BlockPool) get(hash common.Hash) *entry {
+ self.lock.RLock()
+ defer self.lock.RUnlock()
+ return self.pool[hash]
+}
+
+func (self *BlockPool) set(hash common.Hash, e *entry) {
+ self.lock.Lock()
+ defer self.lock.Unlock()
+ self.pool[hash] = e
+}
+
+// accessor and setter for total difficulty
+func (self *BlockPool) getTD() *big.Int {
+ self.lock.RLock()
+ defer self.lock.RUnlock()
+ return self.td
+}
+
+func (self *BlockPool) setTD(td *big.Int) {
+ self.lock.Lock()
+ defer self.lock.Unlock()
+ self.td = td
+}
+
+func (self *BlockPool) remove(sec *section) {
+ // delete node entries from pool index under pool lock
+ self.lock.Lock()
+ defer self.lock.Unlock()
+
+ for _, node := range sec.nodes {
+ delete(self.pool, node.hash)
+ }
+ if sec.initialised && sec.poolRootIndex != 0 {
+ self.status.lock.Lock()
+ self.status.values.BlocksInPool -= len(sec.nodes) - sec.missing
+ self.status.lock.Unlock()
+ }
+}
+
+// get/put for optimised allocation similar to sync.Pool
+func (self *BlockPool) getHashSlice() (s []common.Hash) {
+ select {
+ case s = <-self.hashSlicePool:
+ default:
+ s = make([]common.Hash, self.Config.BlockBatchSize)
+ }
+ return
+}
+
+func (self *BlockPool) putHashSlice(s []common.Hash) {
+ if len(s) == self.Config.BlockBatchSize {
+ select {
+ case self.hashSlicePool <- s:
+ default:
+ }
+ }
+}
+
+// pretty prints hash (byte array) with first 4 bytes in hex
+func hex(hash common.Hash) (name string) {
+ if (hash == common.Hash{}) {
+ name = ""
+ } else {
+ name = fmt.Sprintf("%x", hash[:4])
+ }
+ return
+}
+
+// pretty prints a section using first 4 bytes in hex of bottom and top blockhash of the section
+func sectionhex(section *section) (name string) {
+ if section == nil {
+ name = ""
+ } else {
+ name = fmt.Sprintf("%x-%x", section.bottom.hash[:4], section.top.hash[:4])
+ }
+ return
+}
diff --git a/blockpool/blockpool_test.go b/blockpool/blockpool_test.go
new file mode 100644
index 000000000..9bcd72f04
--- /dev/null
+++ b/blockpool/blockpool_test.go
@@ -0,0 +1,449 @@
+package blockpool
+
+import (
+ "testing"
+ "time"
+
+ "github.com/ethereum/go-ethereum/blockpool/test"
+)
+
+// using the mock framework in blockpool_util_test
+// we test various scenarios here
+
+func TestPeerWithKnownBlock(t *testing.T) {
+ test.LogInit()
+ _, blockPool, blockPoolTester := newTestBlockPool(t)
+ blockPoolTester.refBlockChain[0] = nil
+ blockPoolTester.blockChain[0] = nil
+ blockPool.Start()
+
+ peer0 := blockPoolTester.newPeer("0", 1, 0)
+ peer0.AddPeer()
+
+ blockPool.Wait(waitTimeout)
+ blockPool.Stop()
+ // no request on known block
+ peer0.checkBlockHashesRequests()
+}
+
+func TestPeerWithKnownParentBlock(t *testing.T) {
+ test.LogInit()
+ _, blockPool, blockPoolTester := newTestBlockPool(t)
+ blockPoolTester.initRefBlockChain(1)
+ blockPoolTester.blockChain[0] = nil
+ blockPool.Start()
+
+ peer0 := blockPoolTester.newPeer("0", 1, 1)
+ peer0.AddPeer()
+ peer0.serveBlocks(0, 1)
+
+ blockPool.Wait(waitTimeout)
+ blockPool.Stop()
+ peer0.checkBlocksRequests([]int{1})
+ peer0.checkBlockHashesRequests()
+ blockPoolTester.refBlockChain[1] = []int{}
+ blockPoolTester.checkBlockChain(blockPoolTester.refBlockChain)
+}
+
+func TestSimpleChain(t *testing.T) {
+ test.LogInit()
+ _, blockPool, blockPoolTester := newTestBlockPool(t)
+ blockPoolTester.blockChain[0] = nil
+ blockPoolTester.initRefBlockChain(2)
+
+ blockPool.Start()
+
+ peer1 := blockPoolTester.newPeer("peer1", 2, 2)
+ peer1.AddPeer()
+ peer1.serveBlocks(1, 2)
+ go peer1.serveBlockHashes(2, 1, 0)
+ peer1.serveBlocks(0, 1)
+
+ blockPool.Wait(waitTimeout)
+ blockPool.Stop()
+ blockPoolTester.refBlockChain[2] = []int{}
+ blockPoolTester.checkBlockChain(blockPoolTester.refBlockChain)
+}
+
+func TestChainConnectingWithParentHash(t *testing.T) {
+ test.LogInit()
+ _, blockPool, blockPoolTester := newTestBlockPool(t)
+ blockPoolTester.blockChain[0] = nil
+ blockPoolTester.initRefBlockChain(3)
+
+ blockPool.Start()
+
+ peer1 := blockPoolTester.newPeer("peer1", 3, 3)
+ peer1.AddPeer()
+ go peer1.serveBlocks(2, 3)
+ go peer1.serveBlockHashes(3, 2, 1)
+ peer1.serveBlocks(0, 1, 2)
+
+ blockPool.Wait(waitTimeout)
+ blockPool.Stop()
+ blockPoolTester.refBlockChain[3] = []int{}
+ blockPoolTester.checkBlockChain(blockPoolTester.refBlockChain)
+}
+
+func TestMultiSectionChain(t *testing.T) {
+ test.LogInit()
+ _, blockPool, blockPoolTester := newTestBlockPool(t)
+ blockPoolTester.blockChain[0] = nil
+ blockPoolTester.initRefBlockChain(5)
+
+ blockPool.Start()
+
+ peer1 := blockPoolTester.newPeer("peer1", 5, 5)
+
+ peer1.AddPeer()
+ go peer1.serveBlocks(4, 5)
+ go peer1.serveBlockHashes(5, 4, 3)
+ go peer1.serveBlocks(2, 3, 4)
+ go peer1.serveBlockHashes(3, 2, 1, 0)
+ peer1.serveBlocks(0, 1, 2)
+
+ blockPool.Wait(waitTimeout)
+ blockPool.Stop()
+ blockPoolTester.refBlockChain[5] = []int{}
+ blockPoolTester.checkBlockChain(blockPoolTester.refBlockChain)
+}
+
+func TestNewBlocksOnPartialChain(t *testing.T) {
+ test.LogInit()
+ _, blockPool, blockPoolTester := newTestBlockPool(t)
+ blockPoolTester.blockChain[0] = nil
+ blockPoolTester.initRefBlockChain(7)
+ blockPool.Start()
+
+ peer1 := blockPoolTester.newPeer("peer1", 5, 5)
+ blockPoolTester.tds = make(map[int]int)
+ blockPoolTester.tds[5] = 5
+
+ peer1.AddPeer()
+ go peer1.serveBlocks(4, 5) // partially complete section
+ go peer1.serveBlockHashes(5, 4, 3)
+ peer1.serveBlocks(3, 4) // partially complete section
+
+ // peer1 found new blocks
+ peer1.td = 7
+ peer1.currentBlock = 7
+ peer1.AddPeer()
+ peer1.sendBlocks(6, 7)
+ go peer1.serveBlockHashes(7, 6, 5)
+ go peer1.serveBlocks(2, 3)
+ go peer1.serveBlocks(5, 6)
+ go peer1.serveBlockHashes(3, 2, 1) // tests that hash request from known chain root is remembered
+ peer1.serveBlocks(0, 1, 2)
+
+ blockPool.Wait(waitTimeout)
+ blockPool.Stop()
+ blockPoolTester.refBlockChain[7] = []int{}
+ blockPoolTester.checkBlockChain(blockPoolTester.refBlockChain)
+}
+
+func TestPeerSwitchUp(t *testing.T) {
+ test.LogInit()
+ _, blockPool, blockPoolTester := newTestBlockPool(t)
+ blockPoolTester.blockChain[0] = nil
+ blockPoolTester.initRefBlockChain(7)
+
+ blockPool.Start()
+
+ peer1 := blockPoolTester.newPeer("peer1", 6, 6)
+ peer2 := blockPoolTester.newPeer("peer2", 7, 7)
+
+ peer1.AddPeer()
+ go peer1.serveBlocks(5, 6)
+ go peer1.serveBlockHashes(6, 5, 4, 3) //
+ peer1.serveBlocks(2, 3) // section partially complete, block 3 will be preserved after peer demoted
+ peer2.AddPeer() // peer2 is promoted as best peer, peer1 is demoted
+ go peer2.serveBlocks(6, 7) //
+ go peer2.serveBlocks(4, 5) // tests that block request for earlier section is remembered
+ go peer1.serveBlocks(3, 4) // tests that connecting section by demoted peer is remembered and blocks are accepted from demoted peer
+ go peer2.serveBlockHashes(3, 2, 1, 0) // tests that known chain section is activated, hash requests from 3 is remembered
+ peer2.serveBlocks(0, 1, 2) // final blocks linking to blockchain sent
+
+ blockPool.Wait(waitTimeout)
+ blockPool.Stop()
+ blockPoolTester.refBlockChain[7] = []int{}
+ blockPoolTester.checkBlockChain(blockPoolTester.refBlockChain)
+}
+
+func TestPeerSwitchDownOverlapSectionWithoutRootBlock(t *testing.T) {
+ test.LogInit()
+ _, blockPool, blockPoolTester := newTestBlockPool(t)
+ blockPoolTester.blockChain[0] = nil
+ blockPoolTester.initRefBlockChain(6)
+ blockPool.Start()
+
+ peer1 := blockPoolTester.newPeer("peer1", 4, 4)
+ peer2 := blockPoolTester.newPeer("peer2", 6, 6)
+
+ peer2.AddPeer()
+ peer2.serveBlocks(5, 6) // partially complete, section will be preserved
+ peer2.serveBlockHashes(6, 5, 4) // no go: make sure skeleton is created
+ peer1.AddPeer() // inferior peer1 is promoted as best peer
+ blockPool.RemovePeer("peer2") // peer2 disconnects
+ go peer1.serveBlockHashes(4, 3, 2, 1, 0) //
+ go peer1.serveBlocks(3, 4) //
+ go peer1.serveBlocks(4, 5) // tests that section set by demoted peer is remembered and blocks are accepted from new peer if they have it even if peers original TD is lower
+ peer1.serveBlocks(0, 1, 2, 3)
+
+ blockPool.Wait(waitTimeout)
+ blockPool.Stop()
+ blockPoolTester.refBlockChain[6] = []int{} // tests that idle sections are not inserted in blockchain
+ blockPoolTester.checkBlockChain(blockPoolTester.refBlockChain)
+}
+
+func TestPeerSwitchDownOverlapSectionWithRootBlock(t *testing.T) {
+ test.LogInit()
+ _, blockPool, blockPoolTester := newTestBlockPool(t)
+ blockPoolTester.blockChain[0] = nil
+ blockPoolTester.initRefBlockChain(6)
+ blockPool.Start()
+
+ peer1 := blockPoolTester.newPeer("peer1", 4, 4)
+ peer2 := blockPoolTester.newPeer("peer2", 6, 6)
+
+ peer2.AddPeer()
+ peer2.serveBlocks(5, 6) // partially complete, section will be preserved
+ go peer2.serveBlockHashes(6, 5, 4) //
+ peer2.serveBlocks(3, 4) // !incomplete section
+ time.Sleep(100 * time.Millisecond) // make sure block 4 added
+ peer1.AddPeer() // inferior peer1 is promoted as best peer
+ blockPool.RemovePeer("peer2") // peer2 disconnects
+ go peer1.serveBlockHashes(4, 3, 2, 1, 0) // tests that hash request are directly connecting if the head block exists
+ go peer1.serveBlocks(4, 5) // tests that section set by demoted peer is remembered and blocks are accepted from new peer if they have it even if peers original TD is lower
+ peer1.serveBlocks(0, 1, 2, 3)
+
+ blockPool.Wait(waitTimeout)
+ blockPool.Stop()
+ blockPoolTester.refBlockChain[6] = []int{} // tests that idle sections are not inserted in blockchain
+ blockPoolTester.checkBlockChain(blockPoolTester.refBlockChain)
+}
+
+func TestPeerSwitchDownDisjointSection(t *testing.T) {
+ test.LogInit()
+ _, blockPool, blockPoolTester := newTestBlockPool(t)
+ blockPoolTester.blockChain[0] = nil
+ blockPoolTester.initRefBlockChain(3)
+ blockPool.Start()
+
+ peer1 := blockPoolTester.newPeer("peer1", 3, 3)
+ peer2 := blockPoolTester.newPeer("peer2", 6, 6)
+
+ peer2.AddPeer()
+ peer2.serveBlocks(5, 6) // partially complete, section will be preserved
+ go peer2.serveBlockHashes(6, 5, 4) //
+ peer2.serveBlocks(3, 4, 5) //
+ time.Sleep(100 * time.Millisecond) // make sure blocks are received
+ peer1.AddPeer() // inferior peer1 is promoted as best peer
+ blockPool.RemovePeer("peer2") // peer2 disconnects
+ go peer1.serveBlocks(2, 3) //
+ go peer1.serveBlockHashes(3, 2, 1) //
+ peer1.serveBlocks(0, 1, 2) //
+
+ blockPool.Wait(waitTimeout)
+ blockPool.Stop()
+ blockPoolTester.refBlockChain[3] = []int{} // tests that idle sections are not inserted in blockchain
+ blockPoolTester.checkBlockChain(blockPoolTester.refBlockChain)
+}
+
+func TestPeerSwitchBack(t *testing.T) {
+ test.LogInit()
+ _, blockPool, blockPoolTester := newTestBlockPool(t)
+ blockPoolTester.blockChain[0] = nil
+ blockPoolTester.initRefBlockChain(8)
+
+ blockPool.Start()
+
+ peer1 := blockPoolTester.newPeer("peer1", 11, 11)
+ peer2 := blockPoolTester.newPeer("peer2", 8, 8)
+
+ peer2.AddPeer()
+ go peer2.serveBlocks(7, 8)
+ go peer2.serveBlockHashes(8, 7, 6)
+ go peer2.serveBlockHashes(6, 5, 4)
+ peer2.serveBlocks(4, 5) // section partially complete
+ peer1.AddPeer() // peer1 is promoted as best peer
+ go peer1.serveBlocks(10, 11) //
+ peer1.serveBlockHashes(11, 10) // only gives useless results
+ blockPool.RemovePeer("peer1") // peer1 disconnects
+ go peer2.serveBlockHashes(4, 3, 2, 1, 0) // tests that asking for hashes from 4 is remembered
+ go peer2.serveBlocks(3, 4, 5, 6, 7, 8) // tests that section 4, 5, 6 and 7, 8 are remembered for missing blocks
+ peer2.serveBlocks(0, 1, 2, 3)
+
+ blockPool.Wait(waitTimeout)
+ blockPool.Stop()
+ blockPoolTester.refBlockChain[8] = []int{}
+ blockPoolTester.checkBlockChain(blockPoolTester.refBlockChain)
+}
+
+func TestForkSimple(t *testing.T) {
+ test.LogInit()
+ _, blockPool, blockPoolTester := newTestBlockPool(t)
+ blockPoolTester.blockChain[0] = nil
+ blockPoolTester.initRefBlockChain(9)
+ blockPoolTester.refBlockChain[3] = []int{4, 7}
+ delete(blockPoolTester.refBlockChain, 6)
+
+ blockPool.Start()
+ blockPoolTester.tds = make(map[int]int)
+ blockPoolTester.tds[6] = 10
+ peer1 := blockPoolTester.newPeer("peer1", 9, 9)
+ peer2 := blockPoolTester.newPeer("peer2", 10, 6)
+
+ peer1.AddPeer()
+ go peer1.serveBlocks(8, 9)
+ go peer1.serveBlockHashes(9, 8, 7, 3, 2)
+ peer1.serveBlocks(1, 2, 3, 7, 8)
+ peer2.AddPeer() // peer2 is promoted as best peer
+ go peer2.serveBlocks(5, 6) //
+ go peer2.serveBlockHashes(6, 5, 4, 3, 2) // fork on 3 -> 4 (earlier child: 7)
+ go peer2.serveBlocks(1, 2, 3, 4, 5)
+ go peer2.serveBlockHashes(2, 1, 0)
+ peer2.serveBlocks(0, 1, 2)
+
+ blockPool.Wait(waitTimeout)
+ blockPool.Stop()
+ blockPoolTester.refBlockChain[6] = []int{}
+ blockPoolTester.refBlockChain[3] = []int{4}
+ delete(blockPoolTester.refBlockChain, 7)
+ delete(blockPoolTester.refBlockChain, 8)
+ delete(blockPoolTester.refBlockChain, 9)
+ blockPoolTester.checkBlockChain(blockPoolTester.refBlockChain)
+
+}
+
+func TestForkSwitchBackByNewBlocks(t *testing.T) {
+ test.LogInit()
+ _, blockPool, blockPoolTester := newTestBlockPool(t)
+ blockPoolTester.blockChain[0] = nil
+ blockPoolTester.initRefBlockChain(11)
+ blockPoolTester.refBlockChain[3] = []int{4, 7}
+ delete(blockPoolTester.refBlockChain, 6)
+
+ blockPool.Start()
+ blockPoolTester.tds = make(map[int]int)
+ blockPoolTester.tds[6] = 10
+ peer1 := blockPoolTester.newPeer("peer1", 9, 9)
+ peer2 := blockPoolTester.newPeer("peer2", 10, 6)
+
+ peer1.AddPeer()
+ go peer1.serveBlocks(8, 9) //
+ go peer1.serveBlockHashes(9, 8, 7, 3, 2) //
+ peer1.serveBlocks(7, 8) // partial section
+ // time.Sleep(1 * time.Second)
+ peer2.AddPeer() //
+ go peer2.serveBlocks(5, 6) //
+ go peer2.serveBlockHashes(6, 5, 4, 3, 2) // peer2 forks on block 3
+ peer2.serveBlocks(1, 2, 3, 4, 5) //
+
+ // peer1 finds new blocks
+ peer1.td = 11
+ peer1.currentBlock = 11
+ peer1.AddPeer()
+ go peer1.serveBlocks(10, 11)
+ go peer1.serveBlockHashes(11, 10, 9)
+ go peer1.serveBlocks(9, 10)
+ // time.Sleep(1 * time.Second)
+ go peer1.serveBlocks(3, 7) // tests that block requests on earlier fork are remembered
+ go peer1.serveBlockHashes(2, 1) // tests that hash request from root of connecting chain section (added by demoted peer) is remembered
+ peer1.serveBlocks(0, 1)
+
+ blockPool.Wait(waitTimeout)
+ blockPool.Stop()
+ blockPoolTester.refBlockChain[11] = []int{}
+ blockPoolTester.refBlockChain[3] = []int{7}
+ delete(blockPoolTester.refBlockChain, 6)
+ delete(blockPoolTester.refBlockChain, 5)
+ delete(blockPoolTester.refBlockChain, 4)
+ blockPoolTester.checkBlockChain(blockPoolTester.refBlockChain)
+
+}
+
+func TestForkSwitchBackByPeerSwitchBack(t *testing.T) {
+ test.LogInit()
+ _, blockPool, blockPoolTester := newTestBlockPool(t)
+ blockPoolTester.blockChain[0] = nil
+ blockPoolTester.initRefBlockChain(9)
+ blockPoolTester.refBlockChain[3] = []int{4, 7}
+ delete(blockPoolTester.refBlockChain, 6)
+
+ blockPool.Start()
+
+ blockPoolTester.tds = make(map[int]int)
+ blockPoolTester.tds[6] = 10
+
+ blockPoolTester.tds = make(map[int]int)
+ blockPoolTester.tds[6] = 10
+
+ peer1 := blockPoolTester.newPeer("peer1", 9, 9)
+ peer2 := blockPoolTester.newPeer("peer2", 10, 6)
+
+ peer1.AddPeer()
+ go peer1.serveBlocks(8, 9)
+ go peer1.serveBlockHashes(9, 8, 7, 3, 2)
+ peer1.serveBlocks(7, 8)
+ peer2.AddPeer()
+ go peer2.serveBlocks(5, 6) //
+ go peer2.serveBlockHashes(6, 5, 4, 3, 2) // peer2 forks on block 3
+ peer2.serveBlocks(2, 3, 4, 5) //
+ blockPool.RemovePeer("peer2") // peer2 disconnects, peer1 is promoted again as best peer
+ go peer1.serveBlocks(1, 2) //
+ go peer1.serveBlockHashes(2, 1, 0) //
+ go peer1.serveBlocks(3, 7) // tests that block requests on earlier fork are remembered and orphan section relinks to existing parent block
+ peer1.serveBlocks(0, 1)
+
+ blockPool.Wait(waitTimeout)
+ blockPool.Stop()
+ blockPoolTester.refBlockChain[9] = []int{}
+ blockPoolTester.refBlockChain[3] = []int{7}
+ delete(blockPoolTester.refBlockChain, 6)
+ delete(blockPoolTester.refBlockChain, 5)
+ delete(blockPoolTester.refBlockChain, 4)
+ blockPoolTester.checkBlockChain(blockPoolTester.refBlockChain)
+
+}
+
+func TestForkCompleteSectionSwitchBackByPeerSwitchBack(t *testing.T) {
+ test.LogInit()
+ _, blockPool, blockPoolTester := newTestBlockPool(t)
+ blockPoolTester.blockChain[0] = nil
+ blockPoolTester.initRefBlockChain(9)
+ blockPoolTester.refBlockChain[3] = []int{4, 7}
+ delete(blockPoolTester.refBlockChain, 6)
+
+ blockPool.Start()
+
+ blockPoolTester.tds = make(map[int]int)
+ blockPoolTester.tds[6] = 10
+
+ peer1 := blockPoolTester.newPeer("peer1", 9, 9)
+ peer2 := blockPoolTester.newPeer("peer2", 10, 6)
+
+ peer1.AddPeer()
+ go peer1.serveBlocks(8, 9)
+ go peer1.serveBlockHashes(9, 8, 7)
+ peer1.serveBlocks(3, 7, 8) // make sure this section is complete
+ time.Sleep(1 * time.Second) //
+ go peer1.serveBlockHashes(7, 3, 2) // block 3/7 is section boundary
+ peer1.serveBlocks(2, 3) // partially complete sections block 2 missing
+ peer2.AddPeer() //
+ go peer2.serveBlocks(5, 6) //
+ go peer2.serveBlockHashes(6, 5, 4, 3, 2) // peer2 forks on block 3
+ peer2.serveBlocks(2, 3, 4, 5) // block 2 still missing.
+ blockPool.RemovePeer("peer2") // peer2 disconnects, peer1 is promoted again as best peer
+ go peer1.serveBlockHashes(2, 1, 0) //
+ peer1.serveBlocks(0, 1, 2)
+
+ blockPool.Wait(waitTimeout)
+ blockPool.Stop()
+ blockPoolTester.refBlockChain[9] = []int{}
+ blockPoolTester.refBlockChain[3] = []int{7}
+ delete(blockPoolTester.refBlockChain, 6)
+ delete(blockPoolTester.refBlockChain, 5)
+ delete(blockPoolTester.refBlockChain, 4)
+ blockPoolTester.checkBlockChain(blockPoolTester.refBlockChain)
+
+}
diff --git a/blockpool/blockpool_util_test.go b/blockpool/blockpool_util_test.go
new file mode 100644
index 000000000..be14fbae8
--- /dev/null
+++ b/blockpool/blockpool_util_test.go
@@ -0,0 +1,373 @@
+package blockpool
+
+import (
+ "fmt"
+ "math/big"
+ "sync"
+ "testing"
+ "time"
+
+ "github.com/ethereum/go-ethereum/blockpool/test"
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/core/types"
+ "github.com/ethereum/go-ethereum/errs"
+ "github.com/ethereum/go-ethereum/event"
+ "github.com/ethereum/go-ethereum/pow"
+)
+
+var (
+ waitTimeout = 60 * time.Second
+ testBlockHashesRequestInterval = 10 * time.Millisecond
+ testBlocksRequestInterval = 10 * time.Millisecond
+ requestWatchInterval = 10 * time.Millisecond
+)
+
+// test blockChain is an integer trie
+type blockChain map[int][]int
+
+// blockPoolTester provides the interface between tests and a blockPool
+//
+// refBlockChain is used to guide which blocks will be accepted as valid
+// blockChain gives the current state of the blockchain and
+// accumulates inserts so that we can check the resulting chain
+type blockPoolTester struct {
+ hashPool *test.TestHashPool
+ lock sync.RWMutex
+ reqlock sync.RWMutex
+ blocksRequestsMap map[int]bool
+ refBlockChain blockChain
+ blockChain blockChain
+ blockPool *BlockPool
+ t *testing.T
+ chainEvents *event.TypeMux
+ tds map[int]int
+}
+
+func newTestBlockPool(t *testing.T) (hashPool *test.TestHashPool, blockPool *BlockPool, b *blockPoolTester) {
+ hashPool = test.NewHashPool()
+ b = &blockPoolTester{
+ t: t,
+ hashPool: hashPool,
+ blockChain: make(blockChain),
+ refBlockChain: make(blockChain),
+ blocksRequestsMap: make(map[int]bool),
+ chainEvents: &event.TypeMux{},
+ }
+ b.blockPool = New(b.hasBlock, b.insertChain, b.verifyPoW, b.chainEvents, common.Big0)
+ blockPool = b.blockPool
+ blockPool.Config.BlockHashesRequestInterval = testBlockHashesRequestInterval
+ blockPool.Config.BlocksRequestInterval = testBlocksRequestInterval
+ return
+}
+
+func (self *blockPoolTester) Errorf(format string, params ...interface{}) {
+ // fmt.Printf(format+"\n", params...)
+ self.t.Errorf(format, params...)
+}
+
+// blockPoolTester implements the 3 callbacks needed by the blockPool:
+// hasBlock, insetChain, verifyPoW as well as provides the eventer
+// to subscribe to head insertions
+func (self *blockPoolTester) hasBlock(block common.Hash) (ok bool) {
+ self.lock.RLock()
+ defer self.lock.RUnlock()
+ indexes := self.hashPool.HashesToIndexes([]common.Hash{block})
+ i := indexes[0]
+ _, ok = self.blockChain[i]
+ // fmt.Printf("has block %v (%x...): %v\n", i, block[0:4], ok)
+ return
+}
+
+// mock insertChain relies on refBlockChain to determine block validity
+func (self *blockPoolTester) insertChain(blocks types.Blocks) error {
+ self.lock.Lock()
+ defer self.lock.Unlock()
+ var parent, child int
+ var children, refChildren []int
+ var ok bool
+ for _, block := range blocks {
+ child = self.hashPool.HashesToIndexes([]common.Hash{block.Hash()})[0]
+ var td int
+ if self.tds != nil {
+ td, ok = self.tds[child]
+ }
+ if !ok {
+ td = child
+ }
+ block.Td = big.NewInt(int64(td))
+ _, ok = self.blockChain[child]
+ if ok {
+ // fmt.Printf("block %v already in blockchain\n", child)
+ continue // already in chain
+ }
+ parent = self.hashPool.HashesToIndexes([]common.Hash{block.ParentHeaderHash})[0]
+ children, ok = self.blockChain[parent]
+ if !ok {
+ return fmt.Errorf("parent %v not in blockchain ", parent)
+ }
+ ok = false
+ var found bool
+ refChildren, found = self.refBlockChain[parent]
+ if found {
+ for _, c := range refChildren {
+ if c == child {
+ ok = true
+ }
+ }
+ if !ok {
+ return fmt.Errorf("invalid block %v", child)
+ }
+ } else {
+ ok = true
+ }
+ if ok {
+ // accept any blocks if parent not in refBlockChain
+ self.blockChain[parent] = append(children, child)
+ self.blockChain[child] = nil
+ }
+ }
+ return nil
+}
+
+// mock soft block validation always succeeds
+func (self *blockPoolTester) verifyPoW(pblock pow.Block) bool {
+ return true
+}
+
+// test helper that compares the resulting blockChain to the desired blockChain
+func (self *blockPoolTester) checkBlockChain(blockChain map[int][]int) {
+ self.lock.RLock()
+ defer self.lock.RUnlock()
+ // for k, v := range self.blockChain {
+ // fmt.Printf("got: %v -> %v\n", k, v)
+ // }
+ // for k, v := range blockChain {
+ // fmt.Printf("expected: %v -> %v\n", k, v)
+ // }
+ if len(blockChain) != len(self.blockChain) {
+ self.Errorf("blockchain incorrect (zlength differ)")
+ }
+ for k, v := range blockChain {
+ vv, ok := self.blockChain[k]
+ if !ok || !test.ArrayEq(v, vv) {
+ self.Errorf("blockchain incorrect on %v -> %v (!= %v)", k, vv, v)
+ }
+ }
+}
+
+// peerTester provides the peer callbacks for the blockPool
+// it registers actual callbacks so that the result can be compared to desired behaviour
+// provides helper functions to mock the protocol calls to the blockPool
+type peerTester struct {
+ // containers to record request and error callbacks
+ blockHashesRequests []int
+ blocksRequests [][]int
+ blocksRequestsMap map[int]bool
+ peerErrors []int
+
+ blockPool *BlockPool
+ hashPool *test.TestHashPool
+ lock sync.RWMutex
+ bt *blockPoolTester
+ id string
+ td int
+ currentBlock int
+ t *testing.T
+}
+
+// peerTester constructor takes hashPool and blockPool from the blockPoolTester
+func (self *blockPoolTester) newPeer(id string, td int, cb int) *peerTester {
+ return &peerTester{
+ id: id,
+ td: td,
+ currentBlock: cb,
+ hashPool: self.hashPool,
+ blockPool: self.blockPool,
+ t: self.t,
+ bt: self,
+ blocksRequestsMap: self.blocksRequestsMap,
+ }
+}
+
+func (self *peerTester) Errorf(format string, params ...interface{}) {
+ // fmt.Printf(format+"\n", params...)
+ self.t.Errorf(format, params...)
+}
+
+// helper to compare actual and expected block requests
+func (self *peerTester) checkBlocksRequests(blocksRequests ...[]int) {
+ if len(blocksRequests) > len(self.blocksRequests) {
+ self.Errorf("blocks requests incorrect (length differ)\ngot %v\nexpected %v", self.blocksRequests, blocksRequests)
+ } else {
+ for i, rr := range blocksRequests {
+ r := self.blocksRequests[i]
+ if !test.ArrayEq(r, rr) {
+ self.Errorf("blocks requests incorrect\ngot %v\nexpected %v", self.blocksRequests, blocksRequests)
+ }
+ }
+ }
+}
+
+// helper to compare actual and expected block hash requests
+func (self *peerTester) checkBlockHashesRequests(blocksHashesRequests ...int) {
+ rr := blocksHashesRequests
+ self.lock.RLock()
+ r := self.blockHashesRequests
+ self.lock.RUnlock()
+ if len(r) != len(rr) {
+ self.Errorf("block hashes requests incorrect (length differ)\ngot %v\nexpected %v", r, rr)
+ } else {
+ if !test.ArrayEq(r, rr) {
+ self.Errorf("block hashes requests incorrect\ngot %v\nexpected %v", r, rr)
+ }
+ }
+}
+
+// waiter function used by peer.serveBlocks
+// blocking until requests appear
+// this mocks proper wire protocol behaviour
+// since block requests are sent to any random peers
+// block request map is shared between peers
+// times out after waitTimeout
+func (self *peerTester) waitBlocksRequests(blocksRequest ...int) {
+ timeout := time.After(waitTimeout)
+ rr := blocksRequest
+ for {
+ self.lock.RLock()
+ r := self.blocksRequestsMap
+ // fmt.Printf("[%s] blocks request check %v (%v)\n", self.id, rr, r)
+ i := 0
+ for i = 0; i < len(rr); i++ {
+ _, ok := r[rr[i]]
+ if !ok {
+ break
+ }
+ }
+ self.lock.RUnlock()
+
+ if i == len(rr) {
+ return
+ }
+ time.Sleep(requestWatchInterval)
+ select {
+ case <-timeout:
+ default:
+ }
+ }
+}
+
+// waiter function used by peer.serveBlockHashes
+// blocking until requests appear
+// this mocks proper wire protocol behaviour
+// times out after a period
+func (self *peerTester) waitBlockHashesRequests(blocksHashesRequest int) {
+ timeout := time.After(waitTimeout)
+ rr := blocksHashesRequest
+ for i := 0; ; {
+ self.lock.RLock()
+ r := self.blockHashesRequests
+ self.lock.RUnlock()
+ // fmt.Printf("[%s] block hash request check %v (%v)\n", self.id, rr, r)
+ for ; i < len(r); i++ {
+ if rr == r[i] {
+ return
+ }
+ }
+ time.Sleep(requestWatchInterval)
+ select {
+ case <-timeout:
+ default:
+ }
+ }
+}
+
+// mocks a simple blockchain 0 (genesis) ... n (head)
+func (self *blockPoolTester) initRefBlockChain(n int) {
+ for i := 0; i < n; i++ {
+ self.refBlockChain[i] = []int{i + 1}
+ }
+}
+
+// peerTester functions that mimic protocol calls to the blockpool
+// registers the peer with the blockPool
+func (self *peerTester) AddPeer() (best bool) {
+ hash := self.hashPool.IndexesToHashes([]int{self.currentBlock})[0]
+ best, _ = self.blockPool.AddPeer(big.NewInt(int64(self.td)), hash, self.id, self.requestBlockHashes, self.requestBlocks, self.peerError)
+ return
+}
+
+// peer sends blockhashes if and when gets a request
+func (self *peerTester) serveBlockHashes(indexes ...int) {
+ // fmt.Printf("ready to serve block hashes %v\n", indexes)
+
+ self.waitBlockHashesRequests(indexes[0])
+ self.sendBlockHashes(indexes...)
+}
+
+// peer sends blockhashes not waiting for request
+func (self *peerTester) sendBlockHashes(indexes ...int) {
+ // fmt.Printf("adding block hashes %v\n", indexes)
+ hashes := self.hashPool.IndexesToHashes(indexes)
+ i := 1
+ next := func() (hash common.Hash, ok bool) {
+ if i < len(hashes) {
+ hash = hashes[i]
+ ok = true
+ i++
+ }
+ return
+ }
+ self.blockPool.AddBlockHashes(next, self.id)
+}
+
+// peer sends blocks if and when there is a request
+// (in the shared request store, not necessarily to a specific peer)
+func (self *peerTester) serveBlocks(indexes ...int) {
+ // fmt.Printf("ready to serve blocks %v\n", indexes[1:])
+ self.waitBlocksRequests(indexes[1:]...)
+ self.sendBlocks(indexes...)
+}
+
+// peer sends blocks not waiting for request
+func (self *peerTester) sendBlocks(indexes ...int) {
+ // fmt.Printf("adding blocks %v \n", indexes)
+ hashes := self.hashPool.IndexesToHashes(indexes)
+ for i := 1; i < len(hashes); i++ {
+ // fmt.Printf("adding block %v %x\n", indexes[i], hashes[i][:4])
+ self.blockPool.AddBlock(&types.Block{HeaderHash: hashes[i], ParentHeaderHash: hashes[i-1]}, self.id)
+ }
+}
+
+// the 3 mock peer callbacks
+
+// records block hashes requests by the blockPool
+// -1 is special: not found (a hash never seen)
+func (self *peerTester) requestBlockHashes(hash common.Hash) error {
+ indexes := self.hashPool.HashesToIndexes([]common.Hash{hash})
+ // fmt.Printf("[%s] block hash request %v %x\n", self.id, indexes[0], hash[:4])
+ self.lock.Lock()
+ defer self.lock.Unlock()
+ self.blockHashesRequests = append(self.blockHashesRequests, indexes[0])
+ return nil
+}
+
+// records block requests by the blockPool
+func (self *peerTester) requestBlocks(hashes []common.Hash) error {
+ indexes := self.hashPool.HashesToIndexes(hashes)
+ // fmt.Printf("blocks request %v %x...\n", indexes, hashes[0][:4])
+ self.bt.reqlock.Lock()
+ defer self.bt.reqlock.Unlock()
+ self.blocksRequests = append(self.blocksRequests, indexes)
+ for _, i := range indexes {
+ self.blocksRequestsMap[i] = true
+ }
+ return nil
+}
+
+// records the error codes of all the peerErrors found the blockPool
+func (self *peerTester) peerError(err *errs.Error) {
+ self.peerErrors = append(self.peerErrors, err.Code)
+ if err.Fatal() {
+ self.blockPool.RemovePeer(self.id)
+ }
+}
diff --git a/blockpool/config_test.go b/blockpool/config_test.go
new file mode 100644
index 000000000..e1ce31f27
--- /dev/null
+++ b/blockpool/config_test.go
@@ -0,0 +1,47 @@
+package blockpool
+
+import (
+ "testing"
+ "time"
+
+ "github.com/ethereum/go-ethereum/blockpool/test"
+ "github.com/ethereum/go-ethereum/event"
+)
+
+func TestBlockPoolConfig(t *testing.T) {
+ test.LogInit()
+ blockPool := &BlockPool{Config: &Config{}, chainEvents: &event.TypeMux{}}
+ blockPool.Start()
+ c := blockPool.Config
+ test.CheckInt("BlockHashesBatchSize", c.BlockHashesBatchSize, blockHashesBatchSize, t)
+ test.CheckInt("BlockBatchSize", c.BlockBatchSize, blockBatchSize, t)
+ test.CheckInt("BlocksRequestRepetition", c.BlocksRequestRepetition, blocksRequestRepetition, t)
+ test.CheckInt("BlocksRequestMaxIdleRounds", c.BlocksRequestMaxIdleRounds, blocksRequestMaxIdleRounds, t)
+ test.CheckDuration("BlockHashesRequestInterval", c.BlockHashesRequestInterval, blockHashesRequestInterval, t)
+ test.CheckDuration("BlocksRequestInterval", c.BlocksRequestInterval, blocksRequestInterval, t)
+ test.CheckDuration("BlockHashesTimeout", c.BlockHashesTimeout, blockHashesTimeout, t)
+ test.CheckDuration("BlocksTimeout", c.BlocksTimeout, blocksTimeout, t)
+ test.CheckDuration("IdleBestPeerTimeout", c.IdleBestPeerTimeout, idleBestPeerTimeout, t)
+ test.CheckDuration("PeerSuspensionInterval", c.PeerSuspensionInterval, peerSuspensionInterval, t)
+ test.CheckDuration("StatusUpdateInterval", c.StatusUpdateInterval, statusUpdateInterval, t)
+}
+
+func TestBlockPoolOverrideConfig(t *testing.T) {
+ test.LogInit()
+ blockPool := &BlockPool{Config: &Config{}, chainEvents: &event.TypeMux{}}
+ c := &Config{128, 32, 1, 0, 300 * time.Millisecond, 100 * time.Millisecond, 90 * time.Second, 0, 30 * time.Second, 30 * time.Second, 4 * time.Second}
+
+ blockPool.Config = c
+ blockPool.Start()
+ test.CheckInt("BlockHashesBatchSize", c.BlockHashesBatchSize, 128, t)
+ test.CheckInt("BlockBatchSize", c.BlockBatchSize, 32, t)
+ test.CheckInt("BlocksRequestRepetition", c.BlocksRequestRepetition, blocksRequestRepetition, t)
+ test.CheckInt("BlocksRequestMaxIdleRounds", c.BlocksRequestMaxIdleRounds, blocksRequestMaxIdleRounds, t)
+ test.CheckDuration("BlockHashesRequestInterval", c.BlockHashesRequestInterval, 300*time.Millisecond, t)
+ test.CheckDuration("BlocksRequestInterval", c.BlocksRequestInterval, 100*time.Millisecond, t)
+ test.CheckDuration("BlockHashesTimeout", c.BlockHashesTimeout, 90*time.Second, t)
+ test.CheckDuration("BlocksTimeout", c.BlocksTimeout, blocksTimeout, t)
+ test.CheckDuration("IdleBestPeerTimeout", c.IdleBestPeerTimeout, 30*time.Second, t)
+ test.CheckDuration("PeerSuspensionInterval", c.PeerSuspensionInterval, 30*time.Second, t)
+ test.CheckDuration("StatusUpdateInterval", c.StatusUpdateInterval, 4*time.Second, t)
+}
diff --git a/blockpool/errors_test.go b/blockpool/errors_test.go
new file mode 100644
index 000000000..350d6daef
--- /dev/null
+++ b/blockpool/errors_test.go
@@ -0,0 +1,181 @@
+package blockpool
+
+import (
+ "testing"
+ "time"
+
+ "github.com/ethereum/go-ethereum/blockpool/test"
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/core/types"
+ "github.com/ethereum/go-ethereum/pow"
+)
+
+func TestInvalidBlock(t *testing.T) {
+ test.LogInit()
+ _, blockPool, blockPoolTester := newTestBlockPool(t)
+ blockPoolTester.blockChain[0] = nil
+ blockPoolTester.initRefBlockChain(2)
+ blockPoolTester.refBlockChain[2] = []int{}
+
+ blockPool.Start()
+
+ peer1 := blockPoolTester.newPeer("peer1", 1, 3)
+ peer1.AddPeer()
+ go peer1.serveBlocks(2, 3)
+ go peer1.serveBlockHashes(3, 2, 1, 0)
+ peer1.serveBlocks(0, 1, 2)
+
+ blockPool.Wait(waitTimeout)
+ blockPool.Stop()
+ blockPoolTester.refBlockChain[2] = []int{}
+ blockPoolTester.checkBlockChain(blockPoolTester.refBlockChain)
+ if len(peer1.peerErrors) == 1 {
+ if peer1.peerErrors[0] != ErrInvalidBlock {
+ t.Errorf("wrong error, got %v, expected %v", peer1.peerErrors[0], ErrInvalidBlock)
+ }
+ } else {
+ t.Errorf("expected %v error, got %v", ErrInvalidBlock, peer1.peerErrors)
+ }
+}
+
+func TestVerifyPoW(t *testing.T) {
+ test.LogInit()
+ _, blockPool, blockPoolTester := newTestBlockPool(t)
+ blockPoolTester.blockChain[0] = nil
+ blockPoolTester.initRefBlockChain(3)
+ first := false
+ blockPoolTester.blockPool.verifyPoW = func(b pow.Block) bool {
+ bb, _ := b.(*types.Block)
+ indexes := blockPoolTester.hashPool.HashesToIndexes([]common.Hash{bb.Hash()})
+ if indexes[0] == 2 && !first {
+ first = true
+ return false
+ } else {
+ return true
+ }
+
+ }
+
+ blockPool.Start()
+
+ peer1 := blockPoolTester.newPeer("peer1", 1, 3)
+ peer2 := blockPoolTester.newPeer("peer2", 1, 3)
+ peer1.AddPeer()
+ peer2.AddPeer()
+ go peer1.serveBlocks(2, 3)
+ go peer1.serveBlockHashes(3, 2, 1, 0)
+ peer1.serveBlocks(0, 1, 2, 3)
+ blockPoolTester.blockPool.verifyPoW = func(b pow.Block) bool {
+ return true
+ }
+ peer2.serveBlocks(1, 2)
+
+ blockPool.Wait(waitTimeout)
+ blockPool.Stop()
+ blockPoolTester.refBlockChain[3] = []int{}
+ blockPoolTester.checkBlockChain(blockPoolTester.refBlockChain)
+ if len(peer1.peerErrors) == 1 {
+ if peer1.peerErrors[0] != ErrInvalidPoW {
+ t.Errorf("wrong error, expected %v, got %v", ErrInvalidPoW, peer1.peerErrors[0])
+ }
+ } else {
+ t.Errorf("expected %v error, got %v", ErrInvalidPoW, peer1.peerErrors)
+ }
+}
+
+func TestUnrequestedBlock(t *testing.T) {
+ test.LogInit()
+ _, blockPool, blockPoolTester := newTestBlockPool(t)
+ blockPoolTester.blockChain[0] = nil
+ blockPool.Start()
+
+ peer1 := blockPoolTester.newPeer("peer1", 1, 3)
+ peer1.AddPeer()
+ peer1.sendBlocks(1, 2)
+
+ blockPool.Stop()
+ if len(peer1.peerErrors) == 1 {
+ if peer1.peerErrors[0] != ErrUnrequestedBlock {
+ t.Errorf("wrong error, got %v, expected %v", peer1.peerErrors[0], ErrUnrequestedBlock)
+ }
+ } else {
+ t.Errorf("expected %v error, got %v", ErrUnrequestedBlock, peer1.peerErrors)
+ }
+}
+
+func TestErrInsufficientChainInfo(t *testing.T) {
+ test.LogInit()
+ _, blockPool, blockPoolTester := newTestBlockPool(t)
+ blockPool.Config.BlockHashesTimeout = 100 * time.Millisecond
+ blockPool.Start()
+
+ peer1 := blockPoolTester.newPeer("peer1", 1, 3)
+ peer1.AddPeer()
+
+ blockPool.Wait(waitTimeout)
+ blockPool.Stop()
+ if len(peer1.peerErrors) == 1 {
+ if peer1.peerErrors[0] != ErrInsufficientChainInfo {
+ t.Errorf("wrong error, got %v, expected %v", peer1.peerErrors[0], ErrInsufficientChainInfo)
+ }
+ } else {
+ t.Errorf("expected %v error, got %v", ErrInsufficientChainInfo, peer1.peerErrors)
+ }
+}
+
+func TestIncorrectTD(t *testing.T) {
+ test.LogInit()
+ _, blockPool, blockPoolTester := newTestBlockPool(t)
+ blockPoolTester.blockChain[0] = nil
+ blockPoolTester.initRefBlockChain(3)
+
+ blockPool.Start()
+
+ peer1 := blockPoolTester.newPeer("peer1", 1, 3)
+ peer1.AddPeer()
+ go peer1.serveBlocks(2, 3)
+ go peer1.serveBlockHashes(3, 2, 1, 0)
+ peer1.serveBlocks(0, 1, 2)
+
+ blockPool.Wait(waitTimeout)
+ blockPool.Stop()
+ blockPoolTester.refBlockChain[3] = []int{}
+ blockPoolTester.checkBlockChain(blockPoolTester.refBlockChain)
+ if len(peer1.peerErrors) == 1 {
+ if peer1.peerErrors[0] != ErrIncorrectTD {
+ t.Errorf("wrong error, got %v, expected %v", peer1.peerErrors[0], ErrIncorrectTD)
+ }
+ } else {
+ t.Errorf("expected %v error, got %v", ErrIncorrectTD, peer1.peerErrors)
+ }
+}
+
+func TestPeerSuspension(t *testing.T) {
+ test.LogInit()
+ _, blockPool, blockPoolTester := newTestBlockPool(t)
+ blockPool.Config.PeerSuspensionInterval = 100 * time.Millisecond
+
+ blockPool.Start()
+
+ peer1 := blockPoolTester.newPeer("peer1", 1, 3)
+ peer1.AddPeer()
+ blockPool.peers.peerError("peer1", 0, "")
+ bestpeer, _ := blockPool.peers.getPeer("peer1")
+ if bestpeer != nil {
+ t.Errorf("peer1 not removed on error")
+ }
+ peer1.AddPeer()
+ bestpeer, _ = blockPool.peers.getPeer("peer1")
+ if bestpeer != nil {
+ t.Errorf("peer1 not removed on reconnect")
+ }
+ time.Sleep(100 * time.Millisecond)
+ peer1.AddPeer()
+ bestpeer, _ = blockPool.peers.getPeer("peer1")
+ if bestpeer == nil {
+ t.Errorf("peer1 not connected after PeerSuspensionInterval")
+ }
+ // blockPool.Wait(waitTimeout)
+ blockPool.Stop()
+
+}
diff --git a/blockpool/peers.go b/blockpool/peers.go
new file mode 100644
index 000000000..615058e26
--- /dev/null
+++ b/blockpool/peers.go
@@ -0,0 +1,600 @@
+package blockpool
+
+import (
+ "math/big"
+ "math/rand"
+ "sort"
+ "sync"
+ "time"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/core/types"
+ "github.com/ethereum/go-ethereum/errs"
+)
+
+// the blockpool's model of a peer
+type peer struct {
+ lock sync.RWMutex
+
+ // last known blockchain status
+ td *big.Int
+ currentBlockHash common.Hash
+ currentBlock *types.Block
+ parentHash common.Hash
+ headSection *section
+
+ id string
+
+ // peer callbacks
+ requestBlockHashes func(common.Hash) error
+ requestBlocks func([]common.Hash) error
+ peerError func(*errs.Error)
+ errors *errs.Errors
+
+ sections []common.Hash
+
+ // channels to push new head block and head section for peer a
+ currentBlockC chan *types.Block
+ headSectionC chan *section
+
+ // channels to signal peer switch and peer quit to section processes
+ idleC chan bool
+ switchC chan bool
+
+ bp *BlockPool
+
+ // timers for head section process
+ blockHashesRequestTimer <-chan time.Time
+ blocksRequestTimer <-chan time.Time
+ headInfoTimer <-chan time.Time
+ bestIdleTimer <-chan time.Time
+
+ addToBlacklist func(id string)
+
+ idle bool
+}
+
+// peers is the component keeping a record of peers in a hashmap
+//
+type peers struct {
+ lock sync.RWMutex
+
+ bp *BlockPool
+ errors *errs.Errors
+ peers map[string]*peer
+ best *peer
+ status *status
+ blacklist map[string]time.Time
+}
+
+// peer constructor
+func (self *peers) newPeer(
+ td *big.Int,
+ currentBlockHash common.Hash,
+ id string,
+ requestBlockHashes func(common.Hash) error,
+ requestBlocks func([]common.Hash) error,
+ peerError func(*errs.Error),
+) (p *peer) {
+
+ p = &peer{
+ errors: self.errors,
+ td: td,
+ currentBlockHash: currentBlockHash,
+ id: id,
+ requestBlockHashes: requestBlockHashes,
+ requestBlocks: requestBlocks,
+ peerError: peerError,
+ currentBlockC: make(chan *types.Block),
+ headSectionC: make(chan *section),
+ bp: self.bp,
+ idle: true,
+ addToBlacklist: self.addToBlacklist,
+ }
+ // at creation the peer is recorded in the peer pool
+ self.peers[id] = p
+ return
+}
+
+// dispatches an error to a peer if still connected, adds it to the blacklist
+func (self *peers) peerError(id string, code int, format string, params ...interface{}) {
+ self.lock.RLock()
+ peer, ok := self.peers[id]
+ self.lock.RUnlock()
+ if ok {
+ peer.addError(code, format, params)
+ }
+ self.addToBlacklist(id)
+}
+
+// record time of offence in blacklist to implement suspension for PeerSuspensionInterval
+func (self *peers) addToBlacklist(id string) {
+ self.lock.Lock()
+ defer self.lock.Unlock()
+ self.blacklist[id] = time.Now()
+}
+
+// suspended checks if peer is still suspended
+func (self *peers) suspended(id string) (s bool) {
+ self.lock.Lock()
+ defer self.lock.Unlock()
+ if suspendedAt, ok := self.blacklist[id]; ok {
+ if s = suspendedAt.Add(self.bp.Config.PeerSuspensionInterval).After(time.Now()); !s {
+ // no longer suspended, delete entry
+ delete(self.blacklist, id)
+ }
+ }
+ return
+}
+
+func (self *peer) addError(code int, format string, params ...interface{}) {
+ err := self.errors.New(code, format, params...)
+ self.peerError(err)
+ self.addToBlacklist(self.id)
+}
+
+func (self *peer) setChainInfo(td *big.Int, c common.Hash) {
+ self.lock.Lock()
+ defer self.lock.Unlock()
+
+ self.td = td
+ self.currentBlockHash = c
+
+ self.currentBlock = nil
+ self.parentHash = common.Hash{}
+ self.headSection = nil
+}
+
+func (self *peer) setChainInfoFromBlock(block *types.Block) {
+ self.lock.Lock()
+ defer self.lock.Unlock()
+ // use the optional TD to update peer td, this helps second best peer selection
+ // in case best peer is lost
+ if block.Td != nil && block.Td.Cmp(self.td) > 0 {
+ plog.DebugDetailf("setChainInfoFromBlock: update <%s> - head: %v->%v - TD: %v->%v", self.id, hex(self.currentBlockHash), hex(block.Hash()), self.td, block.Td)
+ self.td = block.Td
+ self.currentBlockHash = block.Hash()
+ self.parentHash = block.ParentHash()
+ self.currentBlock = block
+ self.headSection = nil
+ }
+ self.bp.wg.Add(1)
+ go func() {
+ self.currentBlockC <- block
+ self.bp.wg.Done()
+ }()
+}
+
+// distribute block request among known peers
+func (self *peers) requestBlocks(attempts int, hashes []common.Hash) {
+ self.lock.RLock()
+ defer self.lock.RUnlock()
+ peerCount := len(self.peers)
+ // on first attempt use the best peer
+ if attempts == 0 {
+ plog.DebugDetailf("request %v missing blocks from best peer <%s>", len(hashes), self.best.id)
+ self.best.requestBlocks(hashes)
+ return
+ }
+ repetitions := self.bp.Config.BlocksRequestRepetition
+ if repetitions > peerCount {
+ repetitions = peerCount
+ }
+ i := 0
+ indexes := rand.Perm(peerCount)[0:repetitions]
+ sort.Ints(indexes)
+
+ plog.DebugDetailf("request %v missing blocks from %v/%v peers", len(hashes), repetitions, peerCount)
+ for _, peer := range self.peers {
+ if i == indexes[0] {
+ plog.DebugDetailf("request length: %v", len(hashes))
+ plog.DebugDetailf("request %v missing blocks [%x/%x] from peer <%s>", len(hashes), hashes[0][:4], hashes[len(hashes)-1][:4], peer.id)
+ peer.requestBlocks(hashes)
+ indexes = indexes[1:]
+ if len(indexes) == 0 {
+ break
+ }
+ }
+ i++
+ }
+ self.bp.putHashSlice(hashes)
+}
+
+// addPeer implements the logic for blockpool.AddPeer
+// returns 2 bool values
+// 1. true iff peer is promoted as best peer in the pool
+// 2. true iff peer is still suspended
+func (self *peers) addPeer(
+ td *big.Int,
+ currentBlockHash common.Hash,
+ id string,
+ requestBlockHashes func(common.Hash) error,
+ requestBlocks func([]common.Hash) error,
+ peerError func(*errs.Error),
+) (best bool, suspended bool) {
+
+ var previousBlockHash common.Hash
+ if self.suspended(id) {
+ suspended = true
+ return
+ }
+ self.lock.Lock()
+ p, found := self.peers[id]
+ if found {
+ // when called on an already connected peer, it means a newBlockMsg is received
+ // peer head info is updated
+ if p.currentBlockHash != currentBlockHash {
+ previousBlockHash = p.currentBlockHash
+ plog.Debugf("addPeer: Update peer <%s> with td %v and current block %s (was %v)", id, td, hex(currentBlockHash), hex(previousBlockHash))
+ p.setChainInfo(td, currentBlockHash)
+
+ self.status.lock.Lock()
+ self.status.values.NewBlocks++
+ self.status.lock.Unlock()
+ }
+ } else {
+ p = self.newPeer(td, currentBlockHash, id, requestBlockHashes, requestBlocks, peerError)
+
+ self.status.lock.Lock()
+
+ self.status.peers[id]++
+ self.status.values.NewBlocks++
+ self.status.lock.Unlock()
+
+ plog.Debugf("addPeer: add new peer <%v> with td %v and current block %s", id, td, hex(currentBlockHash))
+ }
+ self.lock.Unlock()
+
+ // check if peer's current head block is known
+ if self.bp.hasBlock(currentBlockHash) {
+ // peer not ahead
+ plog.Debugf("addPeer: peer <%v> with td %v and current block %s is behind", id, td, hex(currentBlockHash))
+ return false, false
+ }
+
+ if self.best == p {
+ // new block update for active current best peer -> request hashes
+ plog.Debugf("addPeer: <%s> already the best peer. Request new head section info from %s", id, hex(currentBlockHash))
+
+ if (previousBlockHash != common.Hash{}) {
+ plog.DebugDetailf("addPeer: <%s> head changed: %s -> %s ", id, hex(previousBlockHash), hex(currentBlockHash))
+ p.headSectionC <- nil
+ if entry := self.bp.get(previousBlockHash); entry != nil {
+ plog.DebugDetailf("addPeer: <%s> previous head : %v found in pool, activate", id, hex(previousBlockHash))
+ self.bp.activateChain(entry.section, p, nil)
+ p.sections = append(p.sections, previousBlockHash)
+ }
+ }
+ best = true
+ } else {
+ // baseline is our own TD
+ currentTD := self.bp.getTD()
+ if self.best != nil {
+ currentTD = self.best.td
+ }
+ if td.Cmp(currentTD) > 0 {
+ self.status.lock.Lock()
+ self.status.bestPeers[p.id]++
+ self.status.lock.Unlock()
+ plog.Debugf("addPeer: peer <%v> (td: %v > current td %v) promoted best peer", id, td, currentTD)
+ self.bp.switchPeer(self.best, p)
+ self.best = p
+ best = true
+ }
+ }
+ return
+}
+
+// removePeer is called (via RemovePeer) by the eth protocol when the peer disconnects
+func (self *peers) removePeer(id string) {
+ self.lock.Lock()
+ defer self.lock.Unlock()
+
+ p, found := self.peers[id]
+ if !found {
+ return
+ }
+
+ delete(self.peers, id)
+ plog.Debugf("addPeer: remove peer <%v> (td: %v)", id, p.td)
+
+ // if current best peer is removed, need to find a better one
+ if self.best == p {
+ var newp *peer
+ // only peers that are ahead of us are considered
+ max := self.bp.getTD()
+ // peer with the highest self-acclaimed TD is chosen
+ for _, pp := range self.peers {
+ if pp.td.Cmp(max) > 0 {
+ max = pp.td
+ newp = pp
+ }
+ }
+ if newp != nil {
+ self.status.lock.Lock()
+ self.status.bestPeers[p.id]++
+ self.status.lock.Unlock()
+ plog.Debugf("addPeer: peer <%v> (td: %v) promoted best peer", newp.id, newp.td)
+ } else {
+ plog.Warnln("addPeer: no suitable peers found")
+ }
+ self.best = newp
+ self.bp.switchPeer(p, newp)
+ }
+}
+
+// switchPeer launches section processes
+func (self *BlockPool) switchPeer(oldp, newp *peer) {
+
+ // first quit AddBlockHashes, requestHeadSection and activateChain
+ // by closing the old peer's switchC channel
+ if oldp != nil {
+ plog.DebugDetailf("<%s> quit peer processes", oldp.id)
+ close(oldp.switchC)
+ }
+ if newp != nil {
+ newp.idleC = make(chan bool)
+ newp.switchC = make(chan bool)
+ // if new best peer has no head section yet, create it and run it
+ // otherwise head section is an element of peer.sections
+ if newp.headSection == nil {
+ plog.DebugDetailf("[%s] head section for [%s] not created, requesting info", newp.id, hex(newp.currentBlockHash))
+
+ if newp.idle {
+ self.wg.Add(1)
+ newp.idle = false
+ self.syncing()
+ }
+
+ go func() {
+ newp.run()
+ if !newp.idle {
+ self.wg.Done()
+ newp.idle = true
+ }
+ }()
+
+ }
+
+ var connected = make(map[common.Hash]*section)
+ var sections []common.Hash
+ for _, hash := range newp.sections {
+ plog.DebugDetailf("activate chain starting from section [%s]", hex(hash))
+ // if section not connected (ie, top of a contiguous sequence of sections)
+ if connected[hash] == nil {
+ // if not deleted, then reread from pool (it can be orphaned top half of a split section)
+ if entry := self.get(hash); entry != nil {
+ self.activateChain(entry.section, newp, connected)
+ connected[hash] = entry.section
+ sections = append(sections, hash)
+ }
+ }
+ }
+ plog.DebugDetailf("<%s> section processes (%v non-contiguous sequences, was %v before)", newp.id, len(sections), len(newp.sections))
+ // need to lock now that newp is exposed to section processes
+ newp.lock.Lock()
+ newp.sections = sections
+ newp.lock.Unlock()
+ }
+ // finally deactivate section process for sections where newp didnt activate
+ // newp activating section process changes the quit channel for this reason
+ if oldp != nil {
+ plog.DebugDetailf("<%s> quit section processes", oldp.id)
+ close(oldp.idleC)
+ }
+}
+
+// getPeer looks up peer by id, returns peer and a bool value
+// that is true iff peer is current best peer
+func (self *peers) getPeer(id string) (p *peer, best bool) {
+ self.lock.RLock()
+ defer self.lock.RUnlock()
+ if self.best != nil && self.best.id == id {
+ return self.best, true
+ }
+ p = self.peers[id]
+ return
+}
+
+// head section process
+
+func (self *peer) handleSection(sec *section) {
+ self.lock.Lock()
+ defer self.lock.Unlock()
+ plog.DebugDetailf("HeadSection: <%s> (head: %s) head section received [%s]-[%s]", self.id, hex(self.currentBlockHash), sectionhex(self.headSection), sectionhex(sec))
+
+ self.headSection = sec
+ self.blockHashesRequestTimer = nil
+
+ if sec == nil {
+ if self.idle {
+ self.idle = false
+ self.bp.wg.Add(1)
+ self.bp.syncing()
+ }
+
+ self.headInfoTimer = time.After(self.bp.Config.BlockHashesTimeout)
+ self.bestIdleTimer = nil
+
+ plog.DebugDetailf("HeadSection: <%s> head block hash changed (mined block received). New head %s", self.id, hex(self.currentBlockHash))
+ } else {
+ if !self.idle {
+ self.idle = true
+ self.bp.wg.Done()
+ }
+
+ self.headInfoTimer = nil
+ self.bestIdleTimer = time.After(self.bp.Config.IdleBestPeerTimeout)
+ plog.DebugDetailf("HeadSection: <%s> (head: %s) head section [%s] created. Idle...", self.id, hex(self.currentBlockHash), sectionhex(sec))
+ }
+}
+
+func (self *peer) getCurrentBlock(currentBlock *types.Block) {
+ // called by update or after AddBlock signals that head block of current peer is received
+ if currentBlock == nil {
+ if entry := self.bp.get(self.currentBlockHash); entry != nil {
+ entry.node.lock.Lock()
+ currentBlock = entry.node.block
+ entry.node.lock.Unlock()
+ }
+ if currentBlock != nil {
+ plog.DebugDetailf("HeadSection: <%s> head block %s found in blockpool", self.id, hex(self.currentBlockHash))
+ } else {
+ plog.DebugDetailf("HeadSection: <%s> head block %s not found... requesting it", self.id, hex(self.currentBlockHash))
+ self.requestBlocks([]common.Hash{self.currentBlockHash})
+ self.blocksRequestTimer = time.After(self.bp.Config.BlocksRequestInterval)
+ return
+ }
+ } else {
+ plog.DebugDetailf("HeadSection: <%s> head block %s received (parent: %s)", self.id, hex(self.currentBlockHash), hex(currentBlock.ParentHash()))
+ }
+
+ self.lock.Lock()
+ defer self.lock.Unlock()
+ self.currentBlock = currentBlock
+ self.parentHash = currentBlock.ParentHash()
+ plog.DebugDetailf("HeadSection: <%s> head block %s found (parent: %s)... requesting hashes", self.id, hex(self.currentBlockHash), hex(self.parentHash))
+ self.blockHashesRequestTimer = time.After(0)
+ self.blocksRequestTimer = nil
+}
+
+func (self *peer) getBlockHashes() bool {
+ //if connecting parent is found
+ if self.bp.hasBlock(self.parentHash) {
+ plog.DebugDetailf("HeadSection: <%s> parent block %s found in blockchain", self.id, hex(self.parentHash))
+ err := self.bp.insertChain(types.Blocks([]*types.Block{self.currentBlock}))
+
+ self.bp.status.lock.Lock()
+ self.bp.status.values.BlocksInChain++
+ self.bp.status.values.BlocksInPool--
+ if err != nil {
+ self.addError(ErrInvalidBlock, "%v", err)
+ self.bp.status.badPeers[self.id]++
+ } else {
+ // XXX added currentBlock check (?)
+ if self.currentBlock != nil && self.currentBlock.Td != nil {
+ if self.td.Cmp(self.currentBlock.Td) != 0 {
+ self.addError(ErrIncorrectTD, "on block %x", self.currentBlockHash)
+ self.bp.status.badPeers[self.id]++
+ }
+ }
+ headKey := self.parentHash
+ height := self.bp.status.chain[headKey] + 1
+ self.bp.status.chain[self.currentBlockHash] = height
+ if height > self.bp.status.values.LongestChain {
+ self.bp.status.values.LongestChain = height
+ }
+ delete(self.bp.status.chain, headKey)
+ }
+ self.bp.status.lock.Unlock()
+ } else {
+ if parent := self.bp.get(self.parentHash); parent != nil {
+ if self.bp.get(self.currentBlockHash) == nil {
+ plog.DebugDetailf("HeadSection: <%s> connecting parent %s found in pool... creating singleton section", self.id, hex(self.parentHash))
+ n := &node{
+ hash: self.currentBlockHash,
+ block: self.currentBlock,
+ hashBy: self.id,
+ blockBy: self.id,
+ td: self.td,
+ }
+ self.bp.newSection([]*node{n}).activate(self)
+ } else {
+ plog.DebugDetailf("HeadSection: <%s> connecting parent %s found in pool...head section [%s] exists...not requesting hashes", self.id, hex(self.parentHash), sectionhex(parent.section))
+ self.bp.activateChain(parent.section, self, nil)
+ }
+ } else {
+ plog.DebugDetailf("HeadSection: <%s> section [%s] requestBlockHashes", self.id, sectionhex(self.headSection))
+ self.requestBlockHashes(self.currentBlockHash)
+ self.blockHashesRequestTimer = time.After(self.bp.Config.BlockHashesRequestInterval)
+ return false
+ }
+ }
+ self.blockHashesRequestTimer = nil
+ if !self.idle {
+ self.idle = true
+ self.headInfoTimer = nil
+ self.bestIdleTimer = time.After(self.bp.Config.IdleBestPeerTimeout)
+ self.bp.wg.Done()
+ }
+ return true
+}
+
+// main loop for head section process
+func (self *peer) run() {
+
+ self.lock.RLock()
+ switchC := self.switchC
+ self.lock.RUnlock()
+
+ self.blockHashesRequestTimer = nil
+
+ self.blocksRequestTimer = time.After(0)
+ self.headInfoTimer = time.After(self.bp.Config.BlockHashesTimeout)
+ self.bestIdleTimer = nil
+
+ var ping = time.NewTicker(5 * time.Second)
+
+LOOP:
+ for {
+ select {
+ // to minitor section process behaviour
+ case <-ping.C:
+ plog.Debugf("HeadSection: <%s> section with head %s, idle: %v", self.id, hex(self.currentBlockHash), self.idle)
+
+ // signal from AddBlockHashes that head section for current best peer is created
+ // if sec == nil, it signals that chain info has updated (new block message)
+ case sec := <-self.headSectionC:
+ self.handleSection(sec)
+
+ // periodic check for block hashes or parent block/section
+ case <-self.blockHashesRequestTimer:
+ self.getBlockHashes()
+
+ // signal from AddBlock that head block of current best peer has been received
+ case currentBlock := <-self.currentBlockC:
+ self.getCurrentBlock(currentBlock)
+
+ // keep requesting until found or timed out
+ case <-self.blocksRequestTimer:
+ self.getCurrentBlock(nil)
+
+ // quitting on timeout
+ case <-self.headInfoTimer:
+ self.peerError(self.bp.peers.errors.New(ErrInsufficientChainInfo, "timed out without providing block hashes or head block (td: %v, head: %s)", self.td, hex(self.currentBlockHash)))
+
+ self.bp.status.lock.Lock()
+ self.bp.status.badPeers[self.id]++
+ self.bp.status.lock.Unlock()
+ // there is no persistence here, so GC will just take care of cleaning up
+ break LOOP
+
+ // signal for peer switch, quit
+ case <-switchC:
+ var complete = "incomplete "
+ if self.idle {
+ complete = "complete"
+ }
+ plog.Debugf("HeadSection: <%s> section with head %s %s... quit request loop due to peer switch", self.id, hex(self.currentBlockHash), complete)
+ break LOOP
+
+ // global quit for blockpool
+ case <-self.bp.quit:
+ break LOOP
+
+ // best
+ case <-self.bestIdleTimer:
+ self.peerError(self.bp.peers.errors.New(ErrIdleTooLong, "timed out without providing new blocks (td: %v, head: %s)...quitting", self.td, hex(self.currentBlockHash)))
+
+ self.bp.status.lock.Lock()
+ self.bp.status.badPeers[self.id]++
+ self.bp.status.lock.Unlock()
+ plog.Debugf("HeadSection: <%s> (headsection [%s]) quit channel closed : timed out without providing new blocks...quitting", self.id, sectionhex(self.headSection))
+ break LOOP
+ }
+ }
+ if !self.idle {
+ self.idle = true
+ self.bp.wg.Done()
+ }
+}
diff --git a/blockpool/peers_test.go b/blockpool/peers_test.go
new file mode 100644
index 000000000..62e059337
--- /dev/null
+++ b/blockpool/peers_test.go
@@ -0,0 +1,189 @@
+package blockpool
+
+import (
+ "math/big"
+ "testing"
+ "time"
+
+ "github.com/ethereum/go-ethereum/blockpool/test"
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/core"
+ "github.com/ethereum/go-ethereum/core/types"
+)
+
+// the actual tests
+func TestAddPeer(t *testing.T) {
+ test.LogInit()
+ hashPool, blockPool, blockPoolTester := newTestBlockPool(t)
+ peer0 := blockPoolTester.newPeer("peer0", 1, 1)
+ peer1 := blockPoolTester.newPeer("peer1", 2, 2)
+ peer2 := blockPoolTester.newPeer("peer2", 3, 3)
+ var bestpeer *peer
+
+ blockPool.Start()
+
+ // pool
+ best := peer0.AddPeer()
+ if !best {
+ t.Errorf("peer0 (TD=1) not accepted as best")
+ }
+ if blockPool.peers.best.id != "peer0" {
+ t.Errorf("peer0 (TD=1) not set as best")
+ }
+
+ best = peer2.AddPeer()
+ if !best {
+ t.Errorf("peer2 (TD=3) not accepted as best")
+ }
+ if blockPool.peers.best.id != "peer2" {
+ t.Errorf("peer2 (TD=3) not set as best")
+ }
+ peer2.waitBlocksRequests(3)
+
+ best = peer1.AddPeer()
+ if best {
+ t.Errorf("peer1 (TD=2) accepted as best")
+ }
+ if blockPool.peers.best.id != "peer2" {
+ t.Errorf("peer2 (TD=3) not set any more as best")
+ }
+ if blockPool.peers.best.td.Cmp(big.NewInt(int64(3))) != 0 {
+ t.Errorf("peer1 TD not set")
+ }
+
+ peer2.td = 4
+ peer2.currentBlock = 4
+ best = peer2.AddPeer()
+ if !best {
+ t.Errorf("peer2 (TD=4) not accepted as best")
+ }
+ if blockPool.peers.best.id != "peer2" {
+ t.Errorf("peer2 (TD=4) not set as best")
+ }
+ if blockPool.peers.best.td.Cmp(big.NewInt(int64(4))) != 0 {
+ t.Errorf("peer2 TD not updated")
+ }
+ peer2.waitBlocksRequests(4)
+
+ peer1.td = 3
+ peer1.currentBlock = 3
+ best = peer1.AddPeer()
+ if best {
+ t.Errorf("peer1 (TD=3) should not be set as best")
+ }
+ if blockPool.peers.best.id == "peer1" {
+ t.Errorf("peer1 (TD=3) should not be set as best")
+ }
+ bestpeer, best = blockPool.peers.getPeer("peer1")
+ if bestpeer.td.Cmp(big.NewInt(int64(3))) != 0 {
+ t.Errorf("peer1 TD should be updated")
+ }
+
+ blockPool.RemovePeer("peer2")
+ bestpeer, best = blockPool.peers.getPeer("peer2")
+ if bestpeer != nil {
+ t.Errorf("peer2 not removed")
+ }
+
+ if blockPool.peers.best.id != "peer1" {
+ t.Errorf("existing peer1 (TD=3) should be set as best peer")
+ }
+ peer1.waitBlocksRequests(3)
+
+ blockPool.RemovePeer("peer1")
+ bestpeer, best = blockPool.peers.getPeer("peer1")
+ if bestpeer != nil {
+ t.Errorf("peer1 not removed")
+ }
+
+ if blockPool.peers.best.id != "peer0" {
+ t.Errorf("existing peer0 (TD=1) should be set as best peer")
+ }
+ peer0.waitBlocksRequests(1)
+
+ blockPool.RemovePeer("peer0")
+ bestpeer, best = blockPool.peers.getPeer("peer0")
+ if bestpeer != nil {
+ t.Errorf("peer1 not removed")
+ }
+
+ // adding back earlier peer ok
+ peer0.currentBlock = 3
+ best = peer0.AddPeer()
+ if !best {
+ t.Errorf("peer0 (TD=1) should be set as best")
+ }
+
+ if blockPool.peers.best.id != "peer0" {
+ t.Errorf("peer0 (TD=1) should be set as best")
+ }
+ peer0.waitBlocksRequests(3)
+
+ hash := hashPool.IndexesToHashes([]int{0})[0]
+ newblock := &types.Block{Td: common.Big3, HeaderHash: hash}
+ blockPool.chainEvents.Post(core.ChainHeadEvent{newblock})
+ time.Sleep(100 * time.Millisecond)
+ if blockPool.peers.best != nil {
+ t.Errorf("no peer should be ahead of self")
+ }
+ best = peer1.AddPeer()
+ if blockPool.peers.best != nil {
+ t.Errorf("still no peer should be ahead of self")
+ }
+
+ best = peer2.AddPeer()
+ if !best {
+ t.Errorf("peer2 (TD=4) not accepted as best")
+ }
+
+ blockPool.RemovePeer("peer2")
+ if blockPool.peers.best != nil {
+ t.Errorf("no peer should be ahead of self")
+ }
+
+ blockPool.Stop()
+}
+
+func TestPeerPromotionByOptionalTdOnBlock(t *testing.T) {
+ test.LogInit()
+ _, blockPool, blockPoolTester := newTestBlockPool(t)
+ blockPoolTester.blockChain[0] = nil
+ blockPoolTester.initRefBlockChain(4)
+ peer0 := blockPoolTester.newPeer("peer0", 2, 2)
+ peer1 := blockPoolTester.newPeer("peer1", 1, 1)
+ peer2 := blockPoolTester.newPeer("peer2", 4, 4)
+
+ blockPool.Start()
+ blockPoolTester.tds = make(map[int]int)
+ blockPoolTester.tds[3] = 3
+
+ // pool
+ peer0.AddPeer()
+ peer0.serveBlocks(1, 2)
+ best := peer1.AddPeer()
+ // this tests that peer1 is not promoted over peer0 yet
+ if best {
+ t.Errorf("peer1 (TD=1) should not be set as best")
+ }
+ best = peer2.AddPeer()
+ peer2.serveBlocks(3, 4)
+ peer2.serveBlockHashes(4, 3, 2, 1)
+ hashes := blockPoolTester.hashPool.IndexesToHashes([]int{2, 3})
+ peer1.waitBlocksRequests(3)
+ blockPool.AddBlock(&types.Block{
+ HeaderHash: common.Hash(hashes[1]),
+ ParentHeaderHash: common.Hash(hashes[0]),
+ Td: common.Big3,
+ }, "peer1")
+
+ blockPool.RemovePeer("peer2")
+ if blockPool.peers.best.id != "peer1" {
+ t.Errorf("peer1 (TD=3) should be set as best")
+ }
+ peer1.serveBlocks(0, 1, 2)
+
+ blockPool.Wait(waitTimeout)
+ blockPool.Stop()
+ blockPoolTester.refBlockChain[4] = []int{}
+ blockPoolTester.checkBlockChain(blockPoolTester.refBlockChain)
+}
diff --git a/blockpool/section.go b/blockpool/section.go
new file mode 100644
index 000000000..14e91cf33
--- /dev/null
+++ b/blockpool/section.go
@@ -0,0 +1,678 @@
+package blockpool
+
+import (
+ "sync"
+ "time"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/core/types"
+)
+
+/*
+ section is the worker on each chain section in the block pool
+ - remove the section if there are blocks missing after an absolute time
+ - remove the section if there are maxIdleRounds of idle rounds of block requests with no response
+ - periodically polls the chain section for missing blocks which are then requested from peers
+ - registers the process controller on the peer so that if the peer is promoted as best peer the second time (after a disconnect of a better one), all active processes are switched back on unless they removed (inserted in blockchain, invalid or expired)
+ - when turned off (if peer disconnects and new peer connects with alternative chain), no blockrequests are made but absolute expiry timer is ticking
+ - when turned back on it recursively calls itself on the root of the next chain section
+*/
+type section struct {
+ lock sync.RWMutex
+
+ parent *section // connecting section back in time towards blockchain
+ child *section // connecting section forward in time
+
+ top *node // the topmost node = head node = youngest node within the chain section
+ bottom *node // the bottom node = root node = oldest node within the chain section
+ nodes []*node
+
+ peer *peer
+ parentHash common.Hash
+
+ blockHashes []common.Hash
+
+ poolRootIndex int
+
+ bp *BlockPool
+
+ controlC chan *peer // to (de)register the current best peer
+ poolRootC chan *peer // indicate connectedness to blockchain (well, known blocks)
+ offC chan bool // closed if process terminated
+ suicideC chan bool // initiate suicide on the section
+ quitInitC chan bool // to signal end of initialisation
+ forkC chan chan bool // freeze section process while splitting
+ switchC chan bool // switching
+ idleC chan bool // channel to indicate thai food
+ processC chan *node //
+ missingC chan *node //
+
+ blocksRequestTimer <-chan time.Time
+ blockHashesRequestTimer <-chan time.Time
+ suicideTimer <-chan time.Time
+
+ blocksRequests int
+ blockHashesRequests int
+
+ blocksRequestsComplete bool
+ blockHashesRequestsComplete bool
+ ready bool
+ same bool
+ initialised bool
+ active bool
+
+ step int
+ idle int
+ missing int
+ lastMissing int
+ depth int
+ invalid bool
+ poolRoot bool
+}
+
+//
+func (self *BlockPool) newSection(nodes []*node) *section {
+ sec := &section{
+ bottom: nodes[len(nodes)-1],
+ top: nodes[0],
+ nodes: nodes,
+ poolRootIndex: len(nodes),
+ bp: self,
+ controlC: make(chan *peer),
+ poolRootC: make(chan *peer),
+ offC: make(chan bool),
+ }
+
+ for i, n := range nodes {
+ entry := &entry{node: n, section: sec, index: &index{i}}
+ self.set(n.hash, entry)
+ }
+
+ plog.DebugDetailf("[%s] setup section process", sectionhex(sec))
+
+ go sec.run()
+ return sec
+}
+
+func (self *section) addSectionToBlockChain(p *peer) {
+ self.bp.wg.Add(1)
+ go func() {
+
+ self.lock.Lock()
+ defer self.lock.Unlock()
+ defer func() {
+ self.bp.wg.Done()
+ }()
+
+ var nodes []*node
+ var n *node
+ var keys []common.Hash
+ var blocks []*types.Block
+ for self.poolRootIndex > 0 {
+ n = self.nodes[self.poolRootIndex-1]
+ n.lock.RLock()
+ block := n.block
+ n.lock.RUnlock()
+ if block == nil {
+ break
+ }
+ self.poolRootIndex--
+ keys = append(keys, n.hash)
+ blocks = append(blocks, block)
+ nodes = append(nodes, n)
+ }
+
+ if len(blocks) == 0 {
+ return
+ }
+
+ self.bp.lock.Lock()
+ for _, key := range keys {
+ delete(self.bp.pool, key)
+ }
+ self.bp.lock.Unlock()
+
+ plog.Infof("[%s] insert %v blocks [%v/%v] into blockchain", sectionhex(self), len(blocks), hex(blocks[0].Hash()), hex(blocks[len(blocks)-1].Hash()))
+ err := self.bp.insertChain(blocks)
+ if err != nil {
+ self.invalid = true
+ self.bp.peers.peerError(n.blockBy, ErrInvalidBlock, "%v", err)
+ plog.Warnf("invalid block %x", n.hash)
+ plog.Warnf("penalise peers %v (hash), %v (block)", n.hashBy, n.blockBy)
+
+ // or invalid block and the entire chain needs to be removed
+ self.removeChain()
+ } else {
+ // check tds
+ self.bp.wg.Add(1)
+ go func() {
+ plog.DebugDetailf("checking td")
+ self.bp.checkTD(nodes...)
+ self.bp.wg.Done()
+ }()
+ // if all blocks inserted in this section
+ // then need to try to insert blocks in child section
+ if self.poolRootIndex == 0 {
+ // if there is a child section, then recursively call itself:
+ // also if section process is not terminated,
+ // then signal blockchain connectivity with poolRootC
+ if child := self.bp.getChild(self); child != nil {
+ select {
+ case <-child.offC:
+ plog.DebugDetailf("[%s] add complete child section [%s] to the blockchain", sectionhex(self), sectionhex(child))
+ case child.poolRootC <- p:
+ plog.DebugDetailf("[%s] add incomplete child section [%s] to the blockchain", sectionhex(self), sectionhex(child))
+ }
+ child.addSectionToBlockChain(p)
+ } else {
+ plog.DebugDetailf("[%s] no child section in pool", sectionhex(self))
+ }
+ plog.DebugDetailf("[%s] section completely inserted to blockchain - remove", sectionhex(self))
+ // complete sections are removed. if called from within section process,
+ // this must run in its own go routine to avoid deadlock
+ self.remove()
+ }
+ }
+
+ self.bp.status.lock.Lock()
+ if err == nil {
+ headKey := blocks[0].ParentHash()
+ height := self.bp.status.chain[headKey] + len(blocks)
+ self.bp.status.chain[blocks[len(blocks)-1].Hash()] = height
+ if height > self.bp.status.values.LongestChain {
+ self.bp.status.values.LongestChain = height
+ }
+ delete(self.bp.status.chain, headKey)
+ }
+ self.bp.status.values.BlocksInChain += len(blocks)
+ self.bp.status.values.BlocksInPool -= len(blocks)
+ if err != nil {
+ self.bp.status.badPeers[n.blockBy]++
+ }
+ self.bp.status.lock.Unlock()
+
+ }()
+
+}
+
+func (self *section) run() {
+
+ // absolute time after which sub-chain is killed if not complete (some blocks are missing)
+ self.suicideC = make(chan bool)
+ self.forkC = make(chan chan bool)
+ self.suicideTimer = time.After(self.bp.Config.BlocksTimeout)
+
+ // node channels for the section
+ // container for missing block hashes
+ var checking bool
+ var ping = time.NewTicker(5 * time.Second)
+
+LOOP:
+ for !self.blockHashesRequestsComplete || !self.blocksRequestsComplete {
+
+ select {
+ case <-ping.C:
+ var name = "no peer"
+ if self.peer != nil {
+ name = self.peer.id
+ }
+ plog.DebugDetailf("[%s] peer <%s> active: %v", sectionhex(self), name, self.active)
+
+ // global quit from blockpool
+ case <-self.bp.quit:
+ break LOOP
+
+ // pause for peer switching
+ case <-self.switchC:
+ self.switchC = nil
+
+ case p := <-self.poolRootC:
+ // signal on pool root channel indicates that the blockpool is
+ // connected to the blockchain, insert the longest chain of blocks
+ // ignored in idle mode to avoid inserting chain sections of non-live peers
+ self.poolRoot = true
+ // switch off hash requests in case they were on
+ self.blockHashesRequestTimer = nil
+ self.blockHashesRequestsComplete = true
+ self.switchOn(p)
+
+ // peer quit or demoted, put section in idle mode
+ case <-self.idleC:
+ // peer quit or demoted, put section in idle mode
+ plog.Debugf("[%s] peer <%s> quit or demoted", sectionhex(self), self.peer.id)
+ self.switchOff()
+ self.idleC = nil
+
+ // timebomb - if section is not complete in time, nuke the entire chain
+ case <-self.suicideTimer:
+ self.removeChain()
+ plog.Debugf("[%s] timeout. (%v total attempts): missing %v/%v/%v...suicide", sectionhex(self), self.blocksRequests, self.missing, self.lastMissing, self.depth)
+ self.suicideTimer = nil
+ break LOOP
+
+ // closing suicideC triggers section suicide: removes section nodes from pool and terminates section process
+ case <-self.suicideC:
+ plog.DebugDetailf("[%s] quit", sectionhex(self))
+ break LOOP
+
+ // alarm for checking blocks in the section
+ case <-self.blocksRequestTimer:
+ plog.DebugDetailf("[%s] alarm: block request time", sectionhex(self))
+ self.processC = self.missingC
+
+ // alarm for checking parent of the section or sending out hash requests
+ case <-self.blockHashesRequestTimer:
+ plog.DebugDetailf("[%s] alarm: hash request time", sectionhex(self))
+ self.blockHashesRequest()
+
+ // activate this section process with a peer
+ case p := <-self.controlC:
+ if p == nil {
+ self.switchOff()
+ } else {
+ self.switchOn(p)
+ }
+ self.bp.wg.Done()
+ // blocks the process until section is split at the fork
+ case waiter := <-self.forkC:
+ <-waiter
+ self.initialised = false
+ self.quitInitC = nil
+
+ //
+ case n, ok := <-self.processC:
+ // channel closed, first iteration finished
+ if !ok && !self.initialised {
+ plog.DebugDetailf("[%s] section initalised: missing %v/%v/%v", sectionhex(self), self.missing, self.lastMissing, self.depth)
+ self.initialised = true
+ self.processC = nil
+ // self.processC = make(chan *node, self.missing)
+ self.checkRound()
+ checking = false
+ break
+ }
+ // plog.DebugDetailf("[%s] section proc step %v: missing %v/%v/%v", sectionhex(self), self.step, self.missing, self.lastMissing, self.depth)
+ if !checking {
+ self.step = 0
+ self.missing = 0
+ checking = true
+ }
+ self.step++
+
+ n.lock.RLock()
+ block := n.block
+ n.lock.RUnlock()
+
+ // if node has no block, request it (buffer it for batch request)
+ // feed it to missingC channel for the next round
+ if block == nil {
+ pos := self.missing % self.bp.Config.BlockBatchSize
+ if pos == 0 {
+ if self.missing != 0 {
+ self.bp.requestBlocks(self.blocksRequests, self.blockHashes[:])
+ }
+ self.blockHashes = self.bp.getHashSlice()
+ }
+ self.blockHashes[pos] = n.hash
+ self.missing++
+ self.missingC <- n
+ } else {
+ // checking for parent block
+ if self.poolRoot {
+ // if node has got block (received via async AddBlock call from protocol)
+ if self.step == self.lastMissing {
+ // current root of the pool
+ plog.DebugDetailf("[%s] received block for current pool root %s", sectionhex(self), hex(n.hash))
+ self.addSectionToBlockChain(self.peer)
+ }
+ } else {
+ if (self.parentHash == common.Hash{}) && n == self.bottom {
+ self.parentHash = block.ParentHash()
+ plog.DebugDetailf("[%s] got parent head block hash %s...checking", sectionhex(self), hex(self.parentHash))
+ self.blockHashesRequest()
+ }
+ }
+ }
+ if self.initialised && self.step == self.lastMissing {
+ plog.DebugDetailf("[%s] check if new blocks arrived (attempt %v): missing %v/%v/%v", sectionhex(self), self.blocksRequests, self.missing, self.lastMissing, self.depth)
+ self.checkRound()
+ checking = false
+ }
+ } // select
+ } // for
+
+ close(self.offC)
+ if self.peer != nil {
+ self.active = false
+ self.bp.wg.Done()
+ }
+
+ plog.DebugDetailf("[%s] section process terminated: %v blocks retrieved (%v attempts), hash requests complete on root (%v attempts).", sectionhex(self), self.depth, self.blocksRequests, self.blockHashesRequests)
+
+}
+
+func (self *section) switchOn(newpeer *peer) {
+
+ oldpeer := self.peer
+ // reset switchC/switchC to current best peer
+ self.idleC = newpeer.idleC
+ self.switchC = newpeer.switchC
+ self.peer = newpeer
+
+ if oldpeer != newpeer {
+ oldp := "no peer"
+ newp := "no peer"
+ if oldpeer != nil {
+ oldp = oldpeer.id
+ }
+ if newpeer != nil {
+ newp = newpeer.id
+ }
+
+ plog.DebugDetailf("[%s] active mode <%s> -> <%s>", sectionhex(self), oldp, newp)
+ }
+
+ // activate section with current peer
+ if oldpeer == nil {
+ self.bp.wg.Add(1)
+ self.active = true
+
+ if !self.blockHashesRequestsComplete {
+ self.blockHashesRequestTimer = time.After(0)
+ }
+ if !self.blocksRequestsComplete {
+ if !self.initialised {
+ if self.quitInitC != nil {
+ <-self.quitInitC
+ }
+ self.missingC = make(chan *node, self.bp.Config.BlockHashesBatchSize)
+ self.processC = make(chan *node, self.bp.Config.BlockHashesBatchSize)
+ self.quitInitC = make(chan bool)
+
+ self.step = 0
+ self.missing = 0
+ self.depth = len(self.nodes)
+ self.lastMissing = self.depth
+
+ self.feedNodes()
+ } else {
+ self.blocksRequestTimer = time.After(0)
+ }
+ }
+ }
+}
+
+// put the section to idle mode
+func (self *section) switchOff() {
+ // active -> idle
+ if self.peer != nil {
+ oldp := "no peer"
+ oldpeer := self.peer
+ if oldpeer != nil {
+ oldp = oldpeer.id
+ }
+ plog.DebugDetailf("[%s] idle mode peer <%s> -> <> (%v total attempts): missing %v/%v/%v", sectionhex(self), oldp, self.blocksRequests, self.missing, self.lastMissing, self.depth)
+
+ self.active = false
+ self.peer = nil
+ // turn off timers
+ self.blocksRequestTimer = nil
+ self.blockHashesRequestTimer = nil
+
+ if self.quitInitC != nil {
+ <-self.quitInitC
+ self.quitInitC = nil
+ }
+ self.processC = nil
+ self.bp.wg.Done()
+ }
+}
+
+// iterates through nodes of a section to feed processC
+// used to initialise chain section
+func (self *section) feedNodes() {
+ // if not run at least once fully, launch iterator
+ self.bp.wg.Add(1)
+ go func() {
+ self.lock.Lock()
+ defer self.lock.Unlock()
+ defer func() {
+ self.bp.wg.Done()
+ }()
+ var n *node
+ INIT:
+ for _, n = range self.nodes {
+ select {
+ case self.processC <- n:
+ case <-self.bp.quit:
+ break INIT
+ }
+ }
+ close(self.processC)
+ close(self.quitInitC)
+ }()
+}
+
+func (self *section) blockHashesRequest() {
+
+ if self.switchC != nil {
+ self.bp.chainLock.Lock()
+ parentSection := self.parent
+
+ if parentSection == nil {
+
+ // only link to new parent if not switching peers
+ // this protects against synchronisation issue where during switching
+ // a demoted peer's fork will be chosen over the best peer's chain
+ // because relinking the correct chain (activateChain) is overwritten here in
+ // demoted peer's section process just before the section is put to idle mode
+ if (self.parentHash != common.Hash{}) {
+ if parent := self.bp.get(self.parentHash); parent != nil {
+ parentSection = parent.section
+ plog.DebugDetailf("[%s] blockHashesRequest: parent section [%s] linked\n", sectionhex(self), sectionhex(parentSection))
+ link(parentSection, self)
+ } else {
+ if self.bp.hasBlock(self.parentHash) {
+ self.poolRoot = true
+ plog.DebugDetailf("[%s] blockHashesRequest: parentHash known ... inserting section in blockchain", sectionhex(self))
+ self.addSectionToBlockChain(self.peer)
+ self.blockHashesRequestTimer = nil
+ self.blockHashesRequestsComplete = true
+ }
+ }
+ }
+ }
+ self.bp.chainLock.Unlock()
+
+ if !self.poolRoot {
+ if parentSection != nil {
+ // activate parent section with this peer
+ // but only if not during switch mode
+ plog.DebugDetailf("[%s] parent section [%s] activated\n", sectionhex(self), sectionhex(parentSection))
+ self.bp.activateChain(parentSection, self.peer, nil)
+ // if not root of chain, switch off
+ plog.DebugDetailf("[%s] parent found, hash requests deactivated (after %v total attempts)\n", sectionhex(self), self.blockHashesRequests)
+ self.blockHashesRequestTimer = nil
+ self.blockHashesRequestsComplete = true
+ } else {
+ self.blockHashesRequests++
+ plog.DebugDetailf("[%s] hash request on root (%v total attempts)\n", sectionhex(self), self.blockHashesRequests)
+ self.peer.requestBlockHashes(self.bottom.hash)
+ self.blockHashesRequestTimer = time.After(self.bp.Config.BlockHashesRequestInterval)
+ }
+ }
+ }
+}
+
+// checks number of missing blocks after each round of request and acts accordingly
+func (self *section) checkRound() {
+ if self.missing == 0 {
+ // no missing blocks
+ plog.DebugDetailf("[%s] section checked: got all blocks. process complete (%v total blocksRequests): missing %v/%v/%v", sectionhex(self), self.blocksRequests, self.missing, self.lastMissing, self.depth)
+ self.blocksRequestsComplete = true
+ self.blocksRequestTimer = nil
+ } else {
+ // some missing blocks
+ plog.DebugDetailf("[%s] section checked: missing %v/%v/%v", sectionhex(self), self.missing, self.lastMissing, self.depth)
+ self.blocksRequests++
+ pos := self.missing % self.bp.Config.BlockBatchSize
+ if pos == 0 {
+ pos = self.bp.Config.BlockBatchSize
+ }
+ self.bp.requestBlocks(self.blocksRequests, self.blockHashes[:pos])
+
+ // handle idle rounds
+ if self.missing == self.lastMissing {
+ // idle round
+ if self.same {
+ // more than once
+ self.idle++
+ // too many idle rounds
+ if self.idle >= self.bp.Config.BlocksRequestMaxIdleRounds {
+ plog.DebugDetailf("[%s] block requests had %v idle rounds (%v total attempts): missing %v/%v/%v\ngiving up...", sectionhex(self), self.idle, self.blocksRequests, self.missing, self.lastMissing, self.depth)
+ self.removeChain()
+ }
+ } else {
+ self.idle = 0
+ }
+ self.same = true
+ } else {
+ self.same = false
+ }
+ self.lastMissing = self.missing
+ // put processC offline
+ self.processC = nil
+ self.blocksRequestTimer = time.After(self.bp.Config.BlocksRequestInterval)
+ }
+}
+
+/*
+ link connects two sections via parent/child fields
+ creating a doubly linked list
+ caller must hold BlockPool chainLock
+*/
+func link(parent *section, child *section) {
+ if parent != nil {
+ exChild := parent.child
+ parent.child = child
+ if exChild != nil && exChild != child {
+ if child != nil {
+ // if child is nil it is not a real fork
+ plog.DebugDetailf("[%s] chain fork [%s] -> [%s]", sectionhex(parent), sectionhex(exChild), sectionhex(child))
+ }
+ exChild.parent = nil
+ }
+ }
+ if child != nil {
+ exParent := child.parent
+ if exParent != nil && exParent != parent {
+ if parent != nil {
+ // if parent is nil it is not a real fork, but suicide delinking section
+ plog.DebugDetailf("[%s] chain reverse fork [%s] -> [%s]", sectionhex(child), sectionhex(exParent), sectionhex(parent))
+ }
+ exParent.child = nil
+ }
+ child.parent = parent
+ }
+}
+
+/*
+ handle forks where connecting node is mid-section
+ by splitting section at fork
+ no splitting needed if connecting node is head of a section
+ caller must hold chain lock
+*/
+func (self *BlockPool) splitSection(parent *section, entry *entry) {
+ plog.DebugDetailf("[%s] split section at fork", sectionhex(parent))
+ parent.deactivate()
+ waiter := make(chan bool)
+ parent.wait(waiter)
+ chain := parent.nodes
+ parent.nodes = chain[entry.index.int:]
+ parent.top = parent.nodes[0]
+ parent.poolRootIndex -= entry.index.int
+ orphan := self.newSection(chain[0:entry.index.int])
+ link(orphan, parent.child)
+ close(waiter)
+ orphan.deactivate()
+}
+
+func (self *section) wait(waiter chan bool) {
+ self.forkC <- waiter
+}
+
+func (self *BlockPool) linkSections(nodes []*node, parent, child *section) (sec *section) {
+ // if new section is created, link it to parent/child sections
+ // and launch section process fetching block and further hashes
+ if len(nodes) > 0 {
+ sec = self.newSection(nodes)
+ plog.Debugf("[%s]->[%s](%v)->[%s] new chain section", sectionhex(parent), sectionhex(sec), len(nodes), sectionhex(child))
+ link(parent, sec)
+ link(sec, child)
+ } else {
+ if parent != nil && child != nil {
+ // now this can only happen if we allow response to hash request to include <from> hash
+ // in this case we just link parent and child (without needing root block of child section)
+ plog.Debugf("[%s]->[%s] connecting known sections", sectionhex(parent), sectionhex(child))
+ link(parent, child)
+ }
+ }
+ return
+}
+
+func (self *section) activate(p *peer) {
+ self.bp.wg.Add(1)
+ select {
+ case <-self.offC:
+ plog.DebugDetailf("[%s] completed section process. cannot activate for peer <%s>", sectionhex(self), p.id)
+ self.bp.wg.Done()
+ case self.controlC <- p:
+ plog.DebugDetailf("[%s] activate section process for peer <%s>", sectionhex(self), p.id)
+ }
+}
+
+func (self *section) deactivate() {
+ self.bp.wg.Add(1)
+ self.controlC <- nil
+}
+
+// removes this section exacly
+func (self *section) remove() {
+ select {
+ case <-self.offC:
+ close(self.suicideC)
+ plog.DebugDetailf("[%s] remove: suicide", sectionhex(self))
+ case <-self.suicideC:
+ plog.DebugDetailf("[%s] remove: suicided already", sectionhex(self))
+ default:
+ plog.DebugDetailf("[%s] remove: suicide", sectionhex(self))
+ close(self.suicideC)
+ }
+ self.unlink()
+ self.bp.remove(self)
+ plog.DebugDetailf("[%s] removed section.", sectionhex(self))
+
+}
+
+// remove a section and all its descendents from the pool
+func (self *section) removeChain() {
+ // need to get the child before removeSection delinks the section
+ self.bp.chainLock.RLock()
+ child := self.child
+ self.bp.chainLock.RUnlock()
+
+ plog.DebugDetailf("[%s] remove chain", sectionhex(self))
+ self.remove()
+ if child != nil {
+ child.removeChain()
+ }
+}
+
+// unlink a section from its parent/child
+func (self *section) unlink() {
+ // first delink from child and parent under chainlock
+ self.bp.chainLock.Lock()
+ link(nil, self)
+ link(self, nil)
+ self.bp.chainLock.Unlock()
+}
diff --git a/blockpool/status.go b/blockpool/status.go
new file mode 100644
index 000000000..02e358510
--- /dev/null
+++ b/blockpool/status.go
@@ -0,0 +1,111 @@
+package blockpool
+
+import (
+ "fmt"
+ "sync"
+
+ "github.com/ethereum/go-ethereum/common"
+)
+
+type statusValues struct {
+ BlockHashes int // number of hashes fetched this session
+ BlockHashesInPool int // number of hashes currently in the pool
+ Blocks int // number of blocks fetched this session
+ BlocksInPool int // number of blocks currently in the pool
+ BlocksInChain int // number of blocks inserted/connected to the blockchain this session
+ NewBlocks int // number of new blocks (received with new blocks msg) this session
+ Forks int // number of chain forks in the blockchain (poolchain) this session
+ LongestChain int // the longest chain inserted since the start of session (aka session blockchain height)
+ BestPeer []byte //Pubkey
+ Syncing bool // requesting, updating etc
+ Peers int // cumulative number of all different registered peers since the start of this session
+ ActivePeers int // cumulative number of all different peers that contributed a hash or block since the start of this session
+ LivePeers int // number of live peers registered with the block pool (supposed to be redundant but good sanity check
+ BestPeers int // cumulative number of all peers that at some point were promoted as best peer (peer with highest TD status) this session
+ BadPeers int // cumulative number of all peers that violated the protocol (invalid block or pow, unrequested hash or block, etc)
+}
+
+type status struct {
+ lock sync.Mutex
+ values statusValues
+ chain map[common.Hash]int
+ peers map[string]int
+ bestPeers map[string]int
+ badPeers map[string]int
+ activePeers map[string]int
+}
+
+func newStatus() *status {
+ return &status{
+ chain: make(map[common.Hash]int),
+ peers: make(map[string]int),
+ bestPeers: make(map[string]int),
+ badPeers: make(map[string]int),
+ activePeers: make(map[string]int),
+ }
+}
+
+type Status struct {
+ statusValues
+}
+
+// blockpool status for reporting
+func (self *BlockPool) Status() *Status {
+ self.status.lock.Lock()
+ defer self.status.lock.Unlock()
+ self.status.values.ActivePeers = len(self.status.activePeers)
+ self.status.values.BestPeers = len(self.status.bestPeers)
+ self.status.values.BadPeers = len(self.status.badPeers)
+ self.status.values.LivePeers = len(self.peers.peers)
+ self.status.values.Peers = len(self.status.peers)
+ self.status.values.BlockHashesInPool = len(self.pool)
+ return &Status{self.status.values}
+}
+
+func (self *Status) String() string {
+ return fmt.Sprintf(`
+ Syncing: %v
+ BlockHashes: %v
+ BlockHashesInPool: %v
+ Blocks: %v
+ BlocksInPool: %v
+ BlocksInChain: %v
+ NewBlocks: %v
+ Forks: %v
+ LongestChain: %v
+ Peers: %v
+ LivePeers: %v
+ ActivePeers: %v
+ BestPeers: %v
+ BadPeers: %v
+`,
+ self.Syncing,
+ self.BlockHashes,
+ self.BlockHashesInPool,
+ self.Blocks,
+ self.BlocksInPool,
+ self.BlocksInChain,
+ self.NewBlocks,
+ self.Forks,
+ self.LongestChain,
+ self.Peers,
+ self.LivePeers,
+ self.ActivePeers,
+ self.BestPeers,
+ self.BadPeers,
+ )
+}
+
+func (self *BlockPool) syncing() {
+ self.status.lock.Lock()
+ defer self.status.lock.Unlock()
+ if !self.status.values.Syncing {
+ self.status.values.Syncing = true
+ go func() {
+ self.wg.Wait()
+ self.status.lock.Lock()
+ self.status.values.Syncing = false
+ self.status.lock.Unlock()
+ }()
+ }
+}
diff --git a/blockpool/status_test.go b/blockpool/status_test.go
new file mode 100644
index 000000000..a87b99d7c
--- /dev/null
+++ b/blockpool/status_test.go
@@ -0,0 +1,251 @@
+package blockpool
+
+import (
+ "fmt"
+ "testing"
+ "time"
+
+ "github.com/ethereum/go-ethereum/blockpool/test"
+)
+
+var statusFields = []string{
+ "BlockHashes",
+ "BlockHashesInPool",
+ "Blocks",
+ "BlocksInPool",
+ "BlocksInChain",
+ "NewBlocks",
+ "Forks",
+ "LongestChain",
+ "Peers",
+ "LivePeers",
+ "ActivePeers",
+ "BestPeers",
+ "BadPeers",
+}
+
+func getStatusValues(s *Status) []int {
+ return []int{
+ s.BlockHashes,
+ s.BlockHashesInPool,
+ s.Blocks,
+ s.BlocksInPool,
+ s.BlocksInChain,
+ s.NewBlocks,
+ s.Forks,
+ s.LongestChain,
+ s.Peers,
+ s.LivePeers,
+ s.ActivePeers,
+ s.BestPeers,
+ s.BadPeers,
+ }
+}
+
+func checkStatus(t *testing.T, bp *BlockPool, syncing bool, expected []int) (err error) {
+ s := bp.Status()
+ if s.Syncing != syncing {
+ err = fmt.Errorf("status for Syncing incorrect. expected %v, got %v", syncing, s.Syncing)
+ return
+ }
+ got := getStatusValues(s)
+ for i, v := range expected {
+ err = test.CheckInt(statusFields[i], got[i], v, t)
+ // fmt.Printf("%v: %v (%v)\n", statusFields[i], got[i], v)
+ if err != nil {
+ return
+ }
+ }
+ return
+}
+
+func TestBlockPoolStatus(t *testing.T) {
+ test.LogInit()
+ var err error
+ n := 3
+ for n > 0 {
+ n--
+ err = testBlockPoolStatus(t)
+ if err != nil {
+ t.Log(err)
+ continue
+ } else {
+ return
+ }
+ }
+ if err != nil {
+ t.Errorf("no pass out of 3: %v", err)
+ }
+}
+
+func testBlockPoolStatus(t *testing.T) (err error) {
+
+ _, blockPool, blockPoolTester := newTestBlockPool(t)
+ blockPoolTester.blockChain[0] = nil
+ blockPoolTester.initRefBlockChain(12)
+ blockPoolTester.refBlockChain[3] = []int{4, 7}
+ delete(blockPoolTester.refBlockChain, 6)
+
+ blockPool.Start()
+ defer blockPool.Stop()
+ blockPoolTester.tds = make(map[int]int)
+ blockPoolTester.tds[9] = 1
+ blockPoolTester.tds[11] = 3
+ blockPoolTester.tds[6] = 2
+
+ peer1 := blockPoolTester.newPeer("peer1", 1, 9)
+ peer2 := blockPoolTester.newPeer("peer2", 2, 6)
+ peer3 := blockPoolTester.newPeer("peer3", 3, 11)
+ peer4 := blockPoolTester.newPeer("peer4", 1, 9)
+ peer2.blocksRequestsMap = peer1.blocksRequestsMap
+
+ var expected []int
+ expected = []int{0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}
+ err = checkStatus(nil, blockPool, false, expected)
+ if err != nil {
+ return
+ }
+
+ peer1.AddPeer()
+ expected = []int{0, 0, 0, 0, 0, 1, 0, 0, 1, 1, 0, 1, 0}
+ err = checkStatus(nil, blockPool, true, expected)
+ if err != nil {
+ return
+ }
+
+ peer1.serveBlocks(8, 9)
+ expected = []int{1, 0, 1, 1, 0, 1, 0, 0, 1, 1, 1, 1, 0}
+ err = checkStatus(nil, blockPool, true, expected)
+ if err != nil {
+ return
+ }
+
+ peer1.serveBlockHashes(9, 8, 7, 3, 2)
+ expected = []int{6, 5, 1, 1, 0, 1, 0, 0, 1, 1, 1, 1, 0}
+ err = checkStatus(nil, blockPool, true, expected)
+ if err != nil {
+ return
+ }
+
+ peer1.serveBlocks(3, 7, 8)
+ expected = []int{6, 5, 3, 3, 0, 1, 0, 0, 1, 1, 1, 1, 0}
+ err = checkStatus(nil, blockPool, true, expected)
+ if err != nil {
+ return
+ }
+
+ peer1.serveBlocks(2, 3)
+ expected = []int{6, 5, 4, 4, 0, 1, 0, 0, 1, 1, 1, 1, 0}
+ err = checkStatus(nil, blockPool, true, expected)
+ if err != nil {
+ return
+ }
+
+ peer4.AddPeer()
+ expected = []int{6, 5, 4, 4, 0, 2, 0, 0, 2, 2, 1, 1, 0}
+ err = checkStatus(nil, blockPool, true, expected)
+ if err != nil {
+ return
+ }
+
+ peer4.sendBlockHashes(12, 11)
+ expected = []int{6, 5, 4, 4, 0, 2, 0, 0, 2, 2, 1, 1, 0}
+ err = checkStatus(nil, blockPool, true, expected)
+ if err != nil {
+ return
+ }
+
+ peer2.AddPeer()
+ expected = []int{6, 5, 4, 4, 0, 3, 0, 0, 3, 3, 1, 2, 0}
+ err = checkStatus(nil, blockPool, true, expected)
+ if err != nil {
+ return
+ }
+
+ peer2.serveBlocks(5, 6)
+ peer2.serveBlockHashes(6, 5, 4, 3, 2)
+ expected = []int{10, 8, 5, 5, 0, 3, 1, 0, 3, 3, 2, 2, 0}
+ err = checkStatus(nil, blockPool, true, expected)
+ if err != nil {
+ return
+ }
+
+ peer2.serveBlocks(2, 3, 4)
+ expected = []int{10, 8, 6, 6, 0, 3, 1, 0, 3, 3, 2, 2, 0}
+ err = checkStatus(nil, blockPool, true, expected)
+ if err != nil {
+ return
+ }
+
+ blockPool.RemovePeer("peer2")
+ expected = []int{10, 8, 6, 6, 0, 3, 1, 0, 3, 2, 2, 2, 0}
+ err = checkStatus(nil, blockPool, true, expected)
+ if err != nil {
+ return
+ }
+
+ peer1.serveBlockHashes(2, 1, 0)
+ expected = []int{11, 9, 6, 6, 0, 3, 1, 0, 3, 2, 2, 2, 0}
+ err = checkStatus(nil, blockPool, true, expected)
+ if err != nil {
+ return
+ }
+
+ peer1.serveBlocks(1, 2)
+ expected = []int{11, 9, 7, 7, 0, 3, 1, 0, 3, 2, 2, 2, 0}
+ err = checkStatus(nil, blockPool, true, expected)
+ if err != nil {
+ return
+ }
+
+ peer1.serveBlocks(4, 5)
+ expected = []int{11, 9, 8, 8, 0, 3, 1, 0, 3, 2, 2, 2, 0}
+ err = checkStatus(nil, blockPool, true, expected)
+ if err != nil {
+ return
+ }
+
+ peer3.AddPeer()
+ expected = []int{11, 9, 8, 8, 0, 4, 1, 0, 4, 3, 2, 3, 0}
+ err = checkStatus(nil, blockPool, true, expected)
+ if err != nil {
+ return
+ }
+
+ peer3.serveBlocks(10, 11)
+ expected = []int{12, 9, 9, 9, 0, 4, 1, 0, 4, 3, 3, 3, 0}
+ err = checkStatus(nil, blockPool, true, expected)
+ if err != nil {
+ return
+ }
+
+ peer3.serveBlockHashes(11, 10, 9)
+ expected = []int{14, 11, 9, 9, 0, 4, 1, 0, 4, 3, 3, 3, 0}
+ err = checkStatus(nil, blockPool, true, expected)
+ if err != nil {
+ return
+ }
+
+ peer4.sendBlocks(11, 12)
+ expected = []int{14, 11, 9, 9, 0, 4, 1, 0, 4, 3, 4, 3, 1}
+ err = checkStatus(nil, blockPool, true, expected)
+ if err != nil {
+ return
+ }
+ peer3.serveBlocks(9, 10)
+ expected = []int{14, 11, 10, 10, 0, 4, 1, 0, 4, 3, 4, 3, 1}
+ err = checkStatus(nil, blockPool, true, expected)
+ if err != nil {
+ return
+ }
+
+ peer3.serveBlocks(0, 1)
+ blockPool.Wait(waitTimeout)
+ time.Sleep(200 * time.Millisecond)
+ expected = []int{14, 3, 11, 3, 8, 4, 1, 8, 4, 3, 4, 3, 1}
+ err = checkStatus(nil, blockPool, false, expected)
+ if err != nil {
+ return
+ }
+ return nil
+}
diff --git a/blockpool/test/hash_pool.go b/blockpool/test/hash_pool.go
new file mode 100644
index 000000000..df3c750f9
--- /dev/null
+++ b/blockpool/test/hash_pool.go
@@ -0,0 +1,55 @@
+package test
+
+import (
+ "sync"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/crypto"
+)
+
+// hashPool is a test helper, that allows random hashes to be referred to by integers
+type TestHashPool struct {
+ intToHash
+ hashToInt
+ lock sync.Mutex
+}
+
+func NewHashPool() *TestHashPool {
+ return &TestHashPool{intToHash: make(intToHash), hashToInt: make(hashToInt)}
+}
+
+type intToHash map[int]common.Hash
+
+type hashToInt map[common.Hash]int
+
+func newHash(i int) common.Hash {
+ return common.BytesToHash(crypto.Sha3([]byte(string(i))))
+}
+
+func (self *TestHashPool) IndexesToHashes(indexes []int) (hashes []common.Hash) {
+ self.lock.Lock()
+ defer self.lock.Unlock()
+ for _, i := range indexes {
+ hash, found := self.intToHash[i]
+ if !found {
+ hash = newHash(i)
+ self.intToHash[i] = hash
+ self.hashToInt[hash] = i
+ }
+ hashes = append(hashes, hash)
+ }
+ return
+}
+
+func (self *TestHashPool) HashesToIndexes(hashes []common.Hash) (indexes []int) {
+ self.lock.Lock()
+ defer self.lock.Unlock()
+ for _, hash := range hashes {
+ i, found := self.hashToInt[hash]
+ if !found {
+ i = -1
+ }
+ indexes = append(indexes, i)
+ }
+ return
+}
diff --git a/blockpool/test/logger.go b/blockpool/test/logger.go
new file mode 100644
index 000000000..2828ffc83
--- /dev/null
+++ b/blockpool/test/logger.go
@@ -0,0 +1,74 @@
+package test
+
+import (
+ "log"
+ "os"
+ "sync"
+ "testing"
+
+ "github.com/ethereum/go-ethereum/logger"
+)
+
+// logging in tests
+
+var once sync.Once
+
+/* usage:
+func TestFunc(t *testing.T) {
+ test.LogInit()
+ // test
+}
+*/
+func LogInit() {
+ once.Do(func() {
+ logger.NewStdLogSystem(os.Stdout, log.LstdFlags, logger.LogLevel(logger.DebugDetailLevel))
+ })
+}
+
+type testLogger struct{ t *testing.T }
+
+/* usage:
+func TestFunc(t *testing.T) {
+ defer test.Testlog.Detach()
+ // test
+}
+*/
+func Testlog(t *testing.T) testLogger {
+ logger.Reset()
+ l := testLogger{t}
+ logger.AddLogSystem(l)
+ return l
+}
+
+func (l testLogger) LogPrint(msg logger.LogMsg) {
+ l.t.Log(msg.String())
+}
+
+func (testLogger) Detach() {
+ logger.Flush()
+ logger.Reset()
+}
+
+type benchLogger struct{ b *testing.B }
+
+/* usage:
+func BenchmarkFunc(b *testing.B) {
+ defer test.Benchlog.Detach()
+ // test
+}
+*/
+func Benchlog(b *testing.B) benchLogger {
+ logger.Reset()
+ l := benchLogger{b}
+ logger.AddLogSystem(l)
+ return l
+}
+
+func (l benchLogger) LogPrint(msg logger.LogMsg) {
+ l.b.Log(msg.String())
+}
+
+func (benchLogger) Detach() {
+ logger.Flush()
+ logger.Reset()
+}
diff --git a/blockpool/test/util.go b/blockpool/test/util.go
new file mode 100644
index 000000000..930601278
--- /dev/null
+++ b/blockpool/test/util.go
@@ -0,0 +1,41 @@
+package test
+
+import (
+ "fmt"
+ "testing"
+ "time"
+)
+
+// miscellaneous test helpers
+
+func CheckInt(name string, got int, expected int, t *testing.T) (err error) {
+ if got != expected {
+ err = fmt.Errorf("status for %v incorrect. expected %v, got %v", name, expected, got)
+ if t != nil {
+ t.Error(err)
+ }
+ }
+ return
+}
+
+func CheckDuration(name string, got time.Duration, expected time.Duration, t *testing.T) (err error) {
+ if got != expected {
+ err = fmt.Errorf("status for %v incorrect. expected %v, got %v", name, expected, got)
+ if t != nil {
+ t.Error(err)
+ }
+ }
+ return
+}
+
+func ArrayEq(a, b []int) bool {
+ if len(a) != len(b) {
+ return false
+ }
+ for i := range a {
+ if a[i] != b[i] {
+ return false
+ }
+ }
+ return true
+}
diff --git a/cmd/LICENSE b/cmd/LICENSE
new file mode 100644
index 000000000..78efdaabe
--- /dev/null
+++ b/cmd/LICENSE
@@ -0,0 +1,16 @@
+Copyright (c) 2013-2014, Jeffrey Wilcke. All rights reserved.
+
+This library is free software; you can redistribute it and/or
+modify it under the terms of the GNU General Public
+License as published by the Free Software Foundation; either
+version 2.1 of the License, or (at your option) any later version.
+
+This library is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with this library; if not, write to the Free Software
+Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+MA 02110-1301 USA
diff --git a/cmd/bootnode/main.go b/cmd/bootnode/main.go
new file mode 100644
index 000000000..dda9f34d4
--- /dev/null
+++ b/cmd/bootnode/main.go
@@ -0,0 +1,93 @@
+/*
+ This file is part of go-ethereum
+
+ go-ethereum is free software: you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation, either version 3 of the License, or
+ (at your option) any later version.
+
+ go-ethereum is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with go-ethereum. If not, see <http://www.gnu.org/licenses/>.
+*/
+
+// Command bootnode runs a bootstrap node for the Discovery Protocol.
+package main
+
+import (
+ "crypto/ecdsa"
+ "encoding/hex"
+ "flag"
+ "fmt"
+ "io/ioutil"
+ "log"
+ "os"
+
+ "github.com/ethereum/go-ethereum/crypto"
+ "github.com/ethereum/go-ethereum/logger"
+ "github.com/ethereum/go-ethereum/p2p/discover"
+ "github.com/ethereum/go-ethereum/p2p/nat"
+)
+
+func main() {
+ var (
+ listenAddr = flag.String("addr", ":30301", "listen address")
+ genKey = flag.String("genkey", "", "generate a node key and quit")
+ nodeKeyFile = flag.String("nodekey", "", "private key filename")
+ nodeKeyHex = flag.String("nodekeyhex", "", "private key as hex (for testing)")
+ natdesc = flag.String("nat", "none", "port mapping mechanism (any|none|upnp|pmp|extip:<IP>)")
+
+ nodeKey *ecdsa.PrivateKey
+ err error
+ )
+ flag.Parse()
+ logger.AddLogSystem(logger.NewStdLogSystem(os.Stdout, log.LstdFlags, logger.DebugLevel))
+
+ if *genKey != "" {
+ writeKey(*genKey)
+ os.Exit(0)
+ }
+
+ natm, err := nat.Parse(*natdesc)
+ if err != nil {
+ log.Fatalf("-nat: %v", err)
+ }
+ switch {
+ case *nodeKeyFile == "" && *nodeKeyHex == "":
+ log.Fatal("Use -nodekey or -nodekeyhex to specify a private key")
+ case *nodeKeyFile != "" && *nodeKeyHex != "":
+ log.Fatal("Options -nodekey and -nodekeyhex are mutually exclusive")
+ case *nodeKeyFile != "":
+ if nodeKey, err = crypto.LoadECDSA(*nodeKeyFile); err != nil {
+ log.Fatalf("-nodekey: %v", err)
+ }
+ case *nodeKeyHex != "":
+ if nodeKey, err = crypto.HexToECDSA(*nodeKeyHex); err != nil {
+ log.Fatalf("-nodekeyhex: %v", err)
+ }
+ }
+
+ if _, err := discover.ListenUDP(nodeKey, *listenAddr, natm); err != nil {
+ log.Fatal(err)
+ }
+ select {}
+}
+
+func writeKey(target string) {
+ key, err := crypto.GenerateKey()
+ if err != nil {
+ log.Fatal("could not generate key: %v", err)
+ }
+ b := crypto.FromECDSA(key)
+ if target == "-" {
+ fmt.Println(hex.EncodeToString(b))
+ } else {
+ if err := ioutil.WriteFile(target, b, 0600); err != nil {
+ log.Fatal("write error: ", err)
+ }
+ }
+}
diff --git a/cmd/disasm/main.go b/cmd/disasm/main.go
new file mode 100644
index 000000000..5b658046f
--- /dev/null
+++ b/cmd/disasm/main.go
@@ -0,0 +1,34 @@
+package main
+
+import (
+ "fmt"
+ "io/ioutil"
+ "os"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/core/vm"
+)
+
+func main() {
+ code, err := ioutil.ReadAll(os.Stdin)
+ if err != nil {
+ fmt.Println(err)
+ os.Exit(1)
+ }
+ code = common.Hex2Bytes(string(code[:len(code)-1]))
+ fmt.Printf("%x\n", code)
+
+ for pc := uint64(0); pc < uint64(len(code)); pc++ {
+ op := vm.OpCode(code[pc])
+ fmt.Printf("%-5d %v", pc, op)
+
+ switch op {
+ case vm.PUSH1, vm.PUSH2, vm.PUSH3, vm.PUSH4, vm.PUSH5, vm.PUSH6, vm.PUSH7, vm.PUSH8, vm.PUSH9, vm.PUSH10, vm.PUSH11, vm.PUSH12, vm.PUSH13, vm.PUSH14, vm.PUSH15, vm.PUSH16, vm.PUSH17, vm.PUSH18, vm.PUSH19, vm.PUSH20, vm.PUSH21, vm.PUSH22, vm.PUSH23, vm.PUSH24, vm.PUSH25, vm.PUSH26, vm.PUSH27, vm.PUSH28, vm.PUSH29, vm.PUSH30, vm.PUSH31, vm.PUSH32:
+ a := uint64(op) - uint64(vm.PUSH1) + 1
+ fmt.Printf(" => %x", code[pc+1:pc+1+a])
+
+ pc += a
+ }
+ fmt.Println()
+ }
+}
diff --git a/cmd/ethtest/.bowerrc b/cmd/ethtest/.bowerrc
new file mode 100644
index 000000000..c3a8813e8
--- /dev/null
+++ b/cmd/ethtest/.bowerrc
@@ -0,0 +1,5 @@
+{
+ "directory": "example/js/",
+ "cwd": "./",
+ "analytics": false
+} \ No newline at end of file
diff --git a/cmd/ethtest/.editorconfig b/cmd/ethtest/.editorconfig
new file mode 100644
index 000000000..60a2751d3
--- /dev/null
+++ b/cmd/ethtest/.editorconfig
@@ -0,0 +1,12 @@
+root = true
+
+[*]
+indent_style = space
+indent_size = 4
+end_of_line = lf
+charset = utf-8
+trim_trailing_whitespace = true
+insert_final_newline = true
+
+[*.md]
+trim_trailing_whitespace = false \ No newline at end of file
diff --git a/cmd/ethtest/.gitignore b/cmd/ethtest/.gitignore
new file mode 100644
index 000000000..399b6dc88
--- /dev/null
+++ b/cmd/ethtest/.gitignore
@@ -0,0 +1,18 @@
+# See http://help.github.com/ignore-files/ for more about ignoring files.
+#
+# If you find yourself ignoring temporary files generated by your text editor
+# or operating system, you probably want to add a global ignore instead:
+# git config --global core.excludesfile ~/.gitignore_global
+
+*.swp
+/tmp
+*/**/*un~
+*un~
+.DS_Store
+*/**/.DS_Store
+ethereum/ethereum
+ethereal/ethereal
+example/js
+node_modules
+bower_components
+npm-debug.log
diff --git a/cmd/ethtest/.jshintrc b/cmd/ethtest/.jshintrc
new file mode 100644
index 000000000..c0ec5f89d
--- /dev/null
+++ b/cmd/ethtest/.jshintrc
@@ -0,0 +1,50 @@
+{
+ "predef": [
+ "console",
+ "require",
+ "equal",
+ "test",
+ "testBoth",
+ "testWithDefault",
+ "raises",
+ "deepEqual",
+ "start",
+ "stop",
+ "ok",
+ "strictEqual",
+ "module",
+ "expect",
+ "reject",
+ "impl"
+ ],
+
+ "esnext": true,
+ "proto": true,
+ "node" : true,
+ "browser" : true,
+ "browserify" : true,
+
+ "boss" : true,
+ "curly": false,
+ "debug": true,
+ "devel": true,
+ "eqeqeq": true,
+ "evil": true,
+ "forin": false,
+ "immed": false,
+ "laxbreak": false,
+ "newcap": true,
+ "noarg": true,
+ "noempty": false,
+ "nonew": false,
+ "nomen": false,
+ "onevar": false,
+ "plusplus": false,
+ "regexp": false,
+ "undef": true,
+ "sub": true,
+ "strict": false,
+ "white": false,
+ "shadow": true,
+ "eqnull": true
+} \ No newline at end of file
diff --git a/cmd/ethtest/.npmignore b/cmd/ethtest/.npmignore
new file mode 100644
index 000000000..5bbffe4fd
--- /dev/null
+++ b/cmd/ethtest/.npmignore
@@ -0,0 +1,9 @@
+example/js
+node_modules
+test
+.gitignore
+.editorconfig
+.travis.yml
+.npmignore
+component.json
+testling.html \ No newline at end of file
diff --git a/cmd/ethtest/.travis.yml b/cmd/ethtest/.travis.yml
new file mode 100644
index 000000000..fafacbd5a
--- /dev/null
+++ b/cmd/ethtest/.travis.yml
@@ -0,0 +1,11 @@
+language: node_js
+node_js:
+ - "0.11"
+ - "0.10"
+before_script:
+ - npm install
+ - npm install jshint
+script:
+ - "jshint *.js lib"
+after_script:
+ - npm run-script gulp
diff --git a/cmd/ethtest/main.go b/cmd/ethtest/main.go
new file mode 100644
index 000000000..952ba1bd6
--- /dev/null
+++ b/cmd/ethtest/main.go
@@ -0,0 +1,229 @@
+/*
+ This file is part of go-ethereum
+
+ go-ethereum is free software: you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation, either version 3 of the License, or
+ (at your option) any later version.
+
+ go-ethereum is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with go-ethereum. If not, see <http://www.gnu.org/licenses/>.
+*/
+/**
+ * @authors:
+ * Jeffrey Wilcke <i@jev.io>
+ */
+
+package main
+
+import (
+ "bytes"
+ "encoding/json"
+ "io"
+ "io/ioutil"
+ "log"
+ "math/big"
+ "os"
+ "strconv"
+ "strings"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/core/state"
+ "github.com/ethereum/go-ethereum/core/types"
+ "github.com/ethereum/go-ethereum/core/vm"
+ "github.com/ethereum/go-ethereum/ethdb"
+ "github.com/ethereum/go-ethereum/logger"
+ "github.com/ethereum/go-ethereum/tests/helper"
+)
+
+type Log struct {
+ AddressF string `json:"address"`
+ DataF string `json:"data"`
+ TopicsF []string `json:"topics"`
+ BloomF string `json:"bloom"`
+}
+
+func (self Log) Address() []byte { return common.Hex2Bytes(self.AddressF) }
+func (self Log) Data() []byte { return common.Hex2Bytes(self.DataF) }
+func (self Log) RlpData() interface{} { return nil }
+func (self Log) Topics() [][]byte {
+ t := make([][]byte, len(self.TopicsF))
+ for i, topic := range self.TopicsF {
+ t[i] = common.Hex2Bytes(topic)
+ }
+ return t
+}
+
+type Account struct {
+ Balance string
+ Code string
+ Nonce string
+ Storage map[string]string
+}
+
+func StateObjectFromAccount(db common.Database, addr string, account Account) *state.StateObject {
+ obj := state.NewStateObject(common.HexToAddress(addr), db)
+ obj.SetBalance(common.Big(account.Balance))
+
+ if common.IsHex(account.Code) {
+ account.Code = account.Code[2:]
+ }
+ obj.SetCode(common.Hex2Bytes(account.Code))
+ obj.SetNonce(common.Big(account.Nonce).Uint64())
+
+ return obj
+}
+
+type VmTest struct {
+ Callcreates interface{}
+ Env Env
+ Exec map[string]string
+ Transaction map[string]string
+ Logs []Log
+ Gas string
+ Out string
+ Post map[string]Account
+ Pre map[string]Account
+ PostStateRoot string
+}
+
+type Env struct {
+ CurrentCoinbase string
+ CurrentDifficulty string
+ CurrentGasLimit string
+ CurrentNumber string
+ CurrentTimestamp interface{}
+ PreviousHash string
+}
+
+func RunVmTest(r io.Reader) (failed int) {
+ tests := make(map[string]VmTest)
+
+ data, _ := ioutil.ReadAll(r)
+ err := json.Unmarshal(data, &tests)
+ if err != nil {
+ log.Fatalln(err)
+ }
+
+ for name, test := range tests {
+ db, _ := ethdb.NewMemDatabase()
+ statedb := state.New(common.Hash{}, db)
+ for addr, account := range test.Pre {
+ obj := StateObjectFromAccount(db, addr, account)
+ statedb.SetStateObject(obj)
+ }
+
+ env := make(map[string]string)
+ env["currentCoinbase"] = test.Env.CurrentCoinbase
+ env["currentDifficulty"] = test.Env.CurrentDifficulty
+ env["currentGasLimit"] = test.Env.CurrentGasLimit
+ env["currentNumber"] = test.Env.CurrentNumber
+ env["previousHash"] = test.Env.PreviousHash
+ if n, ok := test.Env.CurrentTimestamp.(float64); ok {
+ env["currentTimestamp"] = strconv.Itoa(int(n))
+ } else {
+ env["currentTimestamp"] = test.Env.CurrentTimestamp.(string)
+ }
+
+ ret, logs, _, _ := helper.RunState(statedb, env, test.Transaction)
+ statedb.Sync()
+
+ rexp := helper.FromHex(test.Out)
+ if bytes.Compare(rexp, ret) != 0 {
+ helper.Log.Infof("%s's return failed. Expected %x, got %x\n", name, rexp, ret)
+ failed = 1
+ }
+
+ for addr, account := range test.Post {
+ obj := statedb.GetStateObject(common.HexToAddress(addr))
+ if obj == nil {
+ continue
+ }
+
+ if len(test.Exec) == 0 {
+ if obj.Balance().Cmp(common.Big(account.Balance)) != 0 {
+ helper.Log.Infof("%s's : (%x) balance failed. Expected %v, got %v => %v\n", name, obj.Address().Bytes()[:4], account.Balance, obj.Balance(), new(big.Int).Sub(common.Big(account.Balance), obj.Balance()))
+ failed = 1
+ }
+ }
+
+ for addr, value := range account.Storage {
+ v := obj.GetState(common.HexToHash(addr)).Bytes()
+ vexp := helper.FromHex(value)
+
+ if bytes.Compare(v, vexp) != 0 {
+ helper.Log.Infof("%s's : (%x: %s) storage failed. Expected %x, got %x (%v %v)\n", name, obj.Address().Bytes()[0:4], addr, vexp, v, common.BigD(vexp), common.BigD(v))
+ failed = 1
+ }
+ }
+ }
+
+ statedb.Sync()
+ //if !bytes.Equal(common.Hex2Bytes(test.PostStateRoot), statedb.Root()) {
+ if common.HexToHash(test.PostStateRoot) != statedb.Root() {
+ helper.Log.Infof("%s's : Post state root failed. Expected %s, got %x", name, test.PostStateRoot, statedb.Root())
+ failed = 1
+ }
+
+ if len(test.Logs) > 0 {
+ if len(test.Logs) != len(logs) {
+ helper.Log.Infof("log length failed. Expected %d, got %d", len(test.Logs), len(logs))
+ failed = 1
+ } else {
+ for i, log := range test.Logs {
+ if common.HexToAddress(log.AddressF) != logs[i].Address() {
+ helper.Log.Infof("'%s' log address failed. Expected %v got %x", name, log.AddressF, logs[i].Address())
+ failed = 1
+ }
+
+ if !bytes.Equal(logs[i].Data(), helper.FromHex(log.DataF)) {
+ helper.Log.Infof("'%s' log data failed. Expected %v got %x", name, log.DataF, logs[i].Data())
+ failed = 1
+ }
+
+ if len(log.TopicsF) != len(logs[i].Topics()) {
+ helper.Log.Infof("'%s' log topics length failed. Expected %d got %d", name, len(log.TopicsF), logs[i].Topics())
+ failed = 1
+ } else {
+ for j, topic := range log.TopicsF {
+ if common.HexToHash(topic) != logs[i].Topics()[j] {
+ helper.Log.Infof("'%s' log topic[%d] failed. Expected %v got %x", name, j, topic, logs[i].Topics()[j])
+ failed = 1
+ }
+ }
+ }
+ genBloom := common.LeftPadBytes(types.LogsBloom(state.Logs{logs[i]}).Bytes(), 256)
+
+ if !bytes.Equal(genBloom, common.Hex2Bytes(log.BloomF)) {
+ helper.Log.Infof("'%s' bloom failed.", name)
+ failed = 1
+ }
+ }
+ }
+ }
+
+ if failed == 1 {
+ helper.Log.Infoln(string(statedb.Dump()))
+ }
+
+ logger.Flush()
+ }
+
+ return
+}
+
+func main() {
+ helper.Logger.SetLogLevel(5)
+ vm.Debug = true
+
+ if len(os.Args) > 1 {
+ os.Exit(RunVmTest(strings.NewReader(os.Args[1])))
+ } else {
+ os.Exit(RunVmTest(os.Stdin))
+ }
+}
diff --git a/cmd/evm/code.txt b/cmd/evm/code.txt
new file mode 100644
index 000000000..a964ad9d2
--- /dev/null
+++ b/cmd/evm/code.txt
@@ -0,0 +1 @@
+60006102ff5360003560001a60008114156103395760013560405260216040516020025990590160009052606052604051602002816060513760405160200281019050506002604051121561005957604051602002606051f35b604051602002599059016000905260a052600060c052604051602002599059016000905260e0526000610100526001610120525b604051610120511215610109576060515161012051602002606051015112156100d8576101205160200260605101516101005160200260e051015260016101005101610100526100f9565b61012051602002606051015160c05160200260a0510152600160c0510160c0525b600161012051016101205261008d565b60216020599059016000905260c051808252806020028301925050602082015990590160009052600081538151600182015260218101825160200260a0518260005b8381101561016657808301518186015260208101905061014b565b50505050825160200281019050604059905901600090526102405281610240515283602061024051015261024051905090509050905060c05160200280599059016000905281816020850151855160003060195a03f1508090509050905060a05260216020599059016000905261010051808252806020028301925050602082015990590160009052600081538151600182015260218101825160200260e0518260005b8381101561022557808301518186015260208101905061020a565b50505050825160200281019050604059905901600090526102c052816102c051528360206102c05101526102c05190509050905090506101005160200280599059016000905281816020850151855160003060195a03f1508090509050905060e05260405160200259905901600090526102e0526000610120525b610100516101205112156102d7576101205160200260e0510151610120516020026102e051015260016101205101610120526102a0565b60605151610100516020026102e05101526000610120525b60c05161012051121561032d576101205160200260a05101516101205160016101005101016020026102e051015260016101205101610120526102ef565b6040516020026102e051f35b50
diff --git a/cmd/evm/input.txt b/cmd/evm/input.txt
new file mode 100644
index 000000000..1b6857ab9
--- /dev/null
+++ b/cmd/evm/input.txt
@@ -0,0 +1 @@
+0000000000000000000000000000000000000000000000000000000000000000c80000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000003000000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000050000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000000700000000000000000000000000000000000000000000000000000000000000080000000000000000000000000000000000000000000000000000000000000009000000000000000000000000000000000000000000000000000000000000000a000000000000000000000000000000000000000000000000000000000000000b000000000000000000000000000000000000000000000000000000000000000c000000000000000000000000000000000000000000000000000000000000000d000000000000000000000000000000000000000000000000000000000000000e000000000000000000000000000000000000000000000000000000000000000f0000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000001100000000000000000000000000000000000000000000000000000000000000120000000000000000000000000000000000000000000000000000000000000013000000000000000000000000000000000000000000000000000000000000001400000000000000000000000000000000000000000000000000000000000000150000000000000000000000000000000000000000000000000000000000000016000000000000000000000000000000000000000000000000000000000000001700000000000000000000000000000000000000000000000000000000000000180000000000000000000000000000000000000000000000000000000000000019000000000000000000000000000000000000000000000000000000000000001a000000000000000000000000000000000000000000000000000000000000001b000000000000000000000000000000000000000000000000000000000000001c000000000000000000000000000000000000000000000000000000000000001d000000000000000000000000000000000000000000000000000000000000001e000000000000000000000000000000000000000000000000000000000000001f0000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000002100000000000000000000000000000000000000000000000000000000000000220000000000000000000000000000000000000000000000000000000000000023000000000000000000000000000000000000000000000000000000000000002400000000000000000000000000000000000000000000000000000000000000250000000000000000000000000000000000000000000000000000000000000026000000000000000000000000000000000000000000000000000000000000002700000000000000000000000000000000000000000000000000000000000000280000000000000000000000000000000000000000000000000000000000000029000000000000000000000000000000000000000000000000000000000000002a000000000000000000000000000000000000000000000000000000000000002b000000000000000000000000000000000000000000000000000000000000002c000000000000000000000000000000000000000000000000000000000000002d000000000000000000000000000000000000000000000000000000000000002e000000000000000000000000000000000000000000000000000000000000002f0000000000000000000000000000000000000000000000000000000000000030000000000000000000000000000000000000000000000000000000000000003100000000000000000000000000000000000000000000000000000000000000320000000000000000000000000000000000000000000000000000000000000033000000000000000000000000000000000000000000000000000000000000003400000000000000000000000000000000000000000000000000000000000000350000000000000000000000000000000000000000000000000000000000000036000000000000000000000000000000000000000000000000000000000000003700000000000000000000000000000000000000000000000000000000000000380000000000000000000000000000000000000000000000000000000000000039000000000000000000000000000000000000000000000000000000000000003a000000000000000000000000000000000000000000000000000000000000003b000000000000000000000000000000000000000000000000000000000000003c000000000000000000000000000000000000000000000000000000000000003d000000000000000000000000000000000000000000000000000000000000003e000000000000000000000000000000000000000000000000000000000000003f0000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000004100000000000000000000000000000000000000000000000000000000000000420000000000000000000000000000000000000000000000000000000000000043000000000000000000000000000000000000000000000000000000000000004400000000000000000000000000000000000000000000000000000000000000450000000000000000000000000000000000000000000000000000000000000046000000000000000000000000000000000000000000000000000000000000004700000000000000000000000000000000000000000000000000000000000000480000000000000000000000000000000000000000000000000000000000000049000000000000000000000000000000000000000000000000000000000000004a000000000000000000000000000000000000000000000000000000000000004b000000000000000000000000000000000000000000000000000000000000004c000000000000000000000000000000000000000000000000000000000000004d000000000000000000000000000000000000000000000000000000000000004e000000000000000000000000000000000000000000000000000000000000004f0000000000000000000000000000000000000000000000000000000000000050000000000000000000000000000000000000000000000000000000000000005100000000000000000000000000000000000000000000000000000000000000520000000000000000000000000000000000000000000000000000000000000053000000000000000000000000000000000000000000000000000000000000005400000000000000000000000000000000000000000000000000000000000000550000000000000000000000000000000000000000000000000000000000000056000000000000000000000000000000000000000000000000000000000000005700000000000000000000000000000000000000000000000000000000000000580000000000000000000000000000000000000000000000000000000000000059000000000000000000000000000000000000000000000000000000000000005a000000000000000000000000000000000000000000000000000000000000005b000000000000000000000000000000000000000000000000000000000000005c000000000000000000000000000000000000000000000000000000000000005d000000000000000000000000000000000000000000000000000000000000005e000000000000000000000000000000000000000000000000000000000000005f0000000000000000000000000000000000000000000000000000000000000060000000000000000000000000000000000000000000000000000000000000006100000000000000000000000000000000000000000000000000000000000000620000000000000000000000000000000000000000000000000000000000000063000000000000000000000000000000000000000000000000000000000000006400000000000000000000000000000000000000000000000000000000000000650000000000000000000000000000000000000000000000000000000000000066000000000000000000000000000000000000000000000000000000000000006700000000000000000000000000000000000000000000000000000000000000680000000000000000000000000000000000000000000000000000000000000069000000000000000000000000000000000000000000000000000000000000006a000000000000000000000000000000000000000000000000000000000000006b000000000000000000000000000000000000000000000000000000000000006c000000000000000000000000000000000000000000000000000000000000006d000000000000000000000000000000000000000000000000000000000000006e000000000000000000000000000000000000000000000000000000000000006f0000000000000000000000000000000000000000000000000000000000000070000000000000000000000000000000000000000000000000000000000000007100000000000000000000000000000000000000000000000000000000000000720000000000000000000000000000000000000000000000000000000000000073000000000000000000000000000000000000000000000000000000000000007400000000000000000000000000000000000000000000000000000000000000750000000000000000000000000000000000000000000000000000000000000076000000000000000000000000000000000000000000000000000000000000007700000000000000000000000000000000000000000000000000000000000000780000000000000000000000000000000000000000000000000000000000000079000000000000000000000000000000000000000000000000000000000000007a000000000000000000000000000000000000000000000000000000000000007b000000000000000000000000000000000000000000000000000000000000007c000000000000000000000000000000000000000000000000000000000000007d000000000000000000000000000000000000000000000000000000000000007e000000000000000000000000000000000000000000000000000000000000007f0000000000000000000000000000000000000000000000000000000000000080000000000000000000000000000000000000000000000000000000000000008100000000000000000000000000000000000000000000000000000000000000820000000000000000000000000000000000000000000000000000000000000083000000000000000000000000000000000000000000000000000000000000008400000000000000000000000000000000000000000000000000000000000000850000000000000000000000000000000000000000000000000000000000000086000000000000000000000000000000000000000000000000000000000000008700000000000000000000000000000000000000000000000000000000000000880000000000000000000000000000000000000000000000000000000000000089000000000000000000000000000000000000000000000000000000000000008a000000000000000000000000000000000000000000000000000000000000008b000000000000000000000000000000000000000000000000000000000000008c000000000000000000000000000000000000000000000000000000000000008d000000000000000000000000000000000000000000000000000000000000008e000000000000000000000000000000000000000000000000000000000000008f0000000000000000000000000000000000000000000000000000000000000090000000000000000000000000000000000000000000000000000000000000009100000000000000000000000000000000000000000000000000000000000000920000000000000000000000000000000000000000000000000000000000000093000000000000000000000000000000000000000000000000000000000000009400000000000000000000000000000000000000000000000000000000000000950000000000000000000000000000000000000000000000000000000000000096000000000000000000000000000000000000000000000000000000000000009700000000000000000000000000000000000000000000000000000000000000980000000000000000000000000000000000000000000000000000000000000099000000000000000000000000000000000000000000000000000000000000009a000000000000000000000000000000000000000000000000000000000000009b000000000000000000000000000000000000000000000000000000000000009c000000000000000000000000000000000000000000000000000000000000009d000000000000000000000000000000000000000000000000000000000000009e000000000000000000000000000000000000000000000000000000000000009f00000000000000000000000000000000000000000000000000000000000000a000000000000000000000000000000000000000000000000000000000000000a100000000000000000000000000000000000000000000000000000000000000a200000000000000000000000000000000000000000000000000000000000000a300000000000000000000000000000000000000000000000000000000000000a400000000000000000000000000000000000000000000000000000000000000a500000000000000000000000000000000000000000000000000000000000000a600000000000000000000000000000000000000000000000000000000000000a700000000000000000000000000000000000000000000000000000000000000a800000000000000000000000000000000000000000000000000000000000000a900000000000000000000000000000000000000000000000000000000000000aa00000000000000000000000000000000000000000000000000000000000000ab00000000000000000000000000000000000000000000000000000000000000ac00000000000000000000000000000000000000000000000000000000000000ad00000000000000000000000000000000000000000000000000000000000000ae00000000000000000000000000000000000000000000000000000000000000af00000000000000000000000000000000000000000000000000000000000000b000000000000000000000000000000000000000000000000000000000000000b100000000000000000000000000000000000000000000000000000000000000b200000000000000000000000000000000000000000000000000000000000000b300000000000000000000000000000000000000000000000000000000000000b400000000000000000000000000000000000000000000000000000000000000b500000000000000000000000000000000000000000000000000000000000000b600000000000000000000000000000000000000000000000000000000000000b700000000000000000000000000000000000000000000000000000000000000b800000000000000000000000000000000000000000000000000000000000000b900000000000000000000000000000000000000000000000000000000000000ba00000000000000000000000000000000000000000000000000000000000000bb00000000000000000000000000000000000000000000000000000000000000bc00000000000000000000000000000000000000000000000000000000000000bd00000000000000000000000000000000000000000000000000000000000000be00000000000000000000000000000000000000000000000000000000000000bf00000000000000000000000000000000000000000000000000000000000000c000000000000000000000000000000000000000000000000000000000000000c100000000000000000000000000000000000000000000000000000000000000c200000000000000000000000000000000000000000000000000000000000000c300000000000000000000000000000000000000000000000000000000000000c400000000000000000000000000000000000000000000000000000000000000c500000000000000000000000000000000000000000000000000000000000000c600000000000000000000000000000000000000000000000000000000000000c7
diff --git a/cmd/evm/main.go b/cmd/evm/main.go
new file mode 100644
index 000000000..5eb753fa8
--- /dev/null
+++ b/cmd/evm/main.go
@@ -0,0 +1,163 @@
+/*
+ This file is part of go-ethereum
+
+ go-ethereum is free software: you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation, either version 3 of the License, or
+ (at your option) any later version.
+
+ go-ethereum is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with go-ethereum. If not, see <http://www.gnu.org/licenses/>.
+*/
+/**
+ * @authors
+ * Jeffrey Wilcke <i@jev.io>
+ */
+
+package main
+
+import (
+ "flag"
+ "fmt"
+ "log"
+ "math/big"
+ "os"
+ "runtime"
+ "time"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/core"
+ "github.com/ethereum/go-ethereum/core/state"
+ "github.com/ethereum/go-ethereum/core/types"
+ "github.com/ethereum/go-ethereum/core/vm"
+ "github.com/ethereum/go-ethereum/ethdb"
+ "github.com/ethereum/go-ethereum/logger"
+)
+
+var (
+ code = flag.String("code", "", "evm code")
+ loglevel = flag.Int("log", 4, "log level")
+ gas = flag.String("gas", "1000000000", "gas amount")
+ price = flag.String("price", "0", "gas price")
+ value = flag.String("value", "0", "tx value")
+ dump = flag.Bool("dump", false, "dump state after run")
+ data = flag.String("data", "", "data")
+)
+
+func perr(v ...interface{}) {
+ fmt.Println(v...)
+ //os.Exit(1)
+}
+
+func main() {
+ flag.Parse()
+
+ logger.AddLogSystem(logger.NewStdLogSystem(os.Stdout, log.LstdFlags, logger.LogLevel(*loglevel)))
+
+ db, _ := ethdb.NewMemDatabase()
+ statedb := state.New(common.Hash{}, db)
+ sender := statedb.CreateAccount(common.StringToAddress("sender"))
+ receiver := statedb.CreateAccount(common.StringToAddress("receiver"))
+ receiver.SetCode(common.Hex2Bytes(*code))
+
+ vmenv := NewEnv(statedb, common.StringToAddress("evmuser"), common.Big(*value))
+
+ tstart := time.Now()
+
+ ret, e := vmenv.Call(sender, receiver.Address(), common.Hex2Bytes(*data), common.Big(*gas), common.Big(*price), common.Big(*value))
+
+ logger.Flush()
+ if e != nil {
+ perr(e)
+ }
+
+ if *dump {
+ fmt.Println(string(statedb.Dump()))
+ }
+
+ var mem runtime.MemStats
+ runtime.ReadMemStats(&mem)
+ fmt.Printf("vm took %v\n", time.Since(tstart))
+ fmt.Printf(`alloc: %d
+tot alloc: %d
+no. malloc: %d
+heap alloc: %d
+heap objs: %d
+num gc: %d
+`, mem.Alloc, mem.TotalAlloc, mem.Mallocs, mem.HeapAlloc, mem.HeapObjects, mem.NumGC)
+
+ fmt.Printf("%x\n", ret)
+}
+
+type VMEnv struct {
+ state *state.StateDB
+ block *types.Block
+
+ transactor *common.Address
+ value *big.Int
+
+ depth int
+ Gas *big.Int
+ time int64
+}
+
+func NewEnv(state *state.StateDB, transactor common.Address, value *big.Int) *VMEnv {
+ return &VMEnv{
+ state: state,
+ transactor: &transactor,
+ value: value,
+ time: time.Now().Unix(),
+ }
+}
+
+func (self *VMEnv) State() *state.StateDB { return self.state }
+func (self *VMEnv) Origin() common.Address { return *self.transactor }
+func (self *VMEnv) BlockNumber() *big.Int { return common.Big0 }
+func (self *VMEnv) Coinbase() common.Address { return *self.transactor }
+func (self *VMEnv) Time() int64 { return self.time }
+func (self *VMEnv) Difficulty() *big.Int { return common.Big1 }
+func (self *VMEnv) BlockHash() []byte { return make([]byte, 32) }
+func (self *VMEnv) Value() *big.Int { return self.value }
+func (self *VMEnv) GasLimit() *big.Int { return big.NewInt(1000000000) }
+func (self *VMEnv) VmType() vm.Type { return vm.StdVmTy }
+func (self *VMEnv) Depth() int { return 0 }
+func (self *VMEnv) SetDepth(i int) { self.depth = i }
+func (self *VMEnv) GetHash(n uint64) common.Hash {
+ if self.block.Number().Cmp(big.NewInt(int64(n))) == 0 {
+ return self.block.Hash()
+ }
+ return common.Hash{}
+}
+func (self *VMEnv) AddLog(log state.Log) {
+ self.state.AddLog(log)
+}
+func (self *VMEnv) Transfer(from, to vm.Account, amount *big.Int) error {
+ return vm.Transfer(from, to, amount)
+}
+
+func (self *VMEnv) vm(addr *common.Address, data []byte, gas, price, value *big.Int) *core.Execution {
+ return core.NewExecution(self, addr, data, gas, price, value)
+}
+
+func (self *VMEnv) Call(caller vm.ContextRef, addr common.Address, data []byte, gas, price, value *big.Int) ([]byte, error) {
+ exe := self.vm(&addr, data, gas, price, value)
+ ret, err := exe.Call(addr, caller)
+ self.Gas = exe.Gas
+
+ return ret, err
+}
+func (self *VMEnv) CallCode(caller vm.ContextRef, addr common.Address, data []byte, gas, price, value *big.Int) ([]byte, error) {
+ a := caller.Address()
+ exe := self.vm(&a, data, gas, price, value)
+ return exe.Call(addr, caller)
+}
+
+func (self *VMEnv) Create(caller vm.ContextRef, data []byte, gas, price, value *big.Int) ([]byte, error, vm.ContextRef) {
+ exe := self.vm(nil, data, gas, price, value)
+ return exe.Create(caller)
+}
diff --git a/cmd/geth/admin.go b/cmd/geth/admin.go
new file mode 100644
index 000000000..b217e88b5
--- /dev/null
+++ b/cmd/geth/admin.go
@@ -0,0 +1,261 @@
+package main
+
+import (
+ "fmt"
+ "os"
+ "time"
+
+ "github.com/ethereum/go-ethereum/cmd/utils"
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/core/state"
+ "github.com/ethereum/go-ethereum/core/types"
+ "github.com/ethereum/go-ethereum/rlp"
+ "github.com/ethereum/go-ethereum/rpc"
+ "github.com/ethereum/go-ethereum/xeth"
+ "github.com/robertkrimen/otto"
+)
+
+/*
+node admin bindings
+*/
+
+func (js *jsre) adminBindings() {
+ js.re.Set("admin", struct{}{})
+ t, _ := js.re.Get("admin")
+ admin := t.Object()
+ admin.Set("suggestPeer", js.suggestPeer)
+ admin.Set("startRPC", js.startRPC)
+ admin.Set("startMining", js.startMining)
+ admin.Set("stopMining", js.stopMining)
+ admin.Set("nodeInfo", js.nodeInfo)
+ admin.Set("peers", js.peers)
+ admin.Set("newAccount", js.newAccount)
+ admin.Set("unlock", js.unlock)
+ admin.Set("import", js.importChain)
+ admin.Set("export", js.exportChain)
+ admin.Set("dumpBlock", js.dumpBlock)
+}
+
+func (js *jsre) startMining(call otto.FunctionCall) otto.Value {
+ _, err := call.Argument(0).ToInteger()
+ if err != nil {
+ fmt.Println(err)
+ return otto.FalseValue()
+ }
+ // threads now ignored
+ err = js.ethereum.StartMining()
+ if err != nil {
+ fmt.Println(err)
+ return otto.FalseValue()
+ }
+ return otto.TrueValue()
+}
+
+func (js *jsre) stopMining(call otto.FunctionCall) otto.Value {
+ js.ethereum.StopMining()
+ return otto.TrueValue()
+}
+
+func (js *jsre) startRPC(call otto.FunctionCall) otto.Value {
+ addr, err := call.Argument(0).ToString()
+ if err != nil {
+ fmt.Println(err)
+ return otto.FalseValue()
+ }
+ port, err := call.Argument(1).ToInteger()
+ if err != nil {
+ fmt.Println(err)
+ return otto.FalseValue()
+ }
+
+ config := rpc.RpcConfig{
+ ListenAddress: addr,
+ ListenPort: uint(port),
+ // CorsDomain: ctx.GlobalString(RPCCORSDomainFlag.Name),
+ }
+
+ xeth := xeth.New(js.ethereum, nil)
+ err = rpc.Start(xeth, config)
+
+ if err != nil {
+ fmt.Printf(err.Error())
+ return otto.FalseValue()
+ }
+
+ return otto.TrueValue()
+}
+
+func (js *jsre) suggestPeer(call otto.FunctionCall) otto.Value {
+ nodeURL, err := call.Argument(0).ToString()
+ if err != nil {
+ fmt.Println(err)
+ return otto.FalseValue()
+ }
+ err = js.ethereum.SuggestPeer(nodeURL)
+ if err != nil {
+ fmt.Println(err)
+ return otto.FalseValue()
+ }
+ return otto.TrueValue()
+}
+
+func (js *jsre) unlock(call otto.FunctionCall) otto.Value {
+ addr, err := call.Argument(0).ToString()
+ if err != nil {
+ fmt.Println(err)
+ return otto.FalseValue()
+ }
+ seconds, err := call.Argument(2).ToInteger()
+ if err != nil {
+ fmt.Println(err)
+ return otto.FalseValue()
+ }
+ arg := call.Argument(1)
+ var passphrase string
+ if arg.IsUndefined() {
+ fmt.Println("Please enter a passphrase now.")
+ passphrase, err = readPassword("Passphrase: ", true)
+ if err != nil {
+ utils.Fatalf("%v", err)
+ }
+ } else {
+ passphrase, err = arg.ToString()
+ if err != nil {
+ fmt.Println(err)
+ return otto.FalseValue()
+ }
+ }
+ am := js.ethereum.AccountManager()
+ // err := am.Unlock(common.FromHex(split[0]), split[1])
+ // if err != nil {
+ // utils.Fatalf("Unlock account failed '%v'", err)
+ // }
+ err = am.TimedUnlock(common.FromHex(addr), passphrase, time.Duration(seconds)*time.Second)
+ if err != nil {
+ fmt.Printf("Unlock account failed '%v'\n", err)
+ return otto.FalseValue()
+ }
+ return otto.TrueValue()
+}
+
+func (js *jsre) newAccount(call otto.FunctionCall) otto.Value {
+ arg := call.Argument(0)
+ var passphrase string
+ if arg.IsUndefined() {
+ fmt.Println("The new account will be encrypted with a passphrase.")
+ fmt.Println("Please enter a passphrase now.")
+ auth, err := readPassword("Passphrase: ", true)
+ if err != nil {
+ utils.Fatalf("%v", err)
+ }
+ confirm, err := readPassword("Repeat Passphrase: ", false)
+ if err != nil {
+ utils.Fatalf("%v", err)
+ }
+ if auth != confirm {
+ utils.Fatalf("Passphrases did not match.")
+ }
+ passphrase = auth
+ } else {
+ var err error
+ passphrase, err = arg.ToString()
+ if err != nil {
+ fmt.Println(err)
+ return otto.FalseValue()
+ }
+ }
+ acct, err := js.ethereum.AccountManager().NewAccount(passphrase)
+ if err != nil {
+ fmt.Printf("Could not create the account: %v", err)
+ return otto.UndefinedValue()
+ }
+ return js.re.ToVal(common.Bytes2Hex(acct.Address))
+}
+
+func (js *jsre) nodeInfo(call otto.FunctionCall) otto.Value {
+ return js.re.ToVal(js.ethereum.NodeInfo())
+}
+
+func (js *jsre) peers(call otto.FunctionCall) otto.Value {
+ return js.re.ToVal(js.ethereum.PeersInfo())
+}
+
+func (js *jsre) importChain(call otto.FunctionCall) otto.Value {
+ if len(call.ArgumentList) == 0 {
+ fmt.Println("err: require file name")
+ return otto.FalseValue()
+ }
+
+ fn, err := call.Argument(0).ToString()
+ if err != nil {
+ fmt.Println(err)
+ return otto.FalseValue()
+ }
+
+ var fh *os.File
+ fh, err = os.OpenFile(fn, os.O_RDONLY, os.ModePerm)
+ if err != nil {
+ fmt.Println(err)
+ return otto.FalseValue()
+ }
+ defer fh.Close()
+
+ var blocks types.Blocks
+ if err = rlp.Decode(fh, &blocks); err != nil {
+ fmt.Println(err)
+ return otto.FalseValue()
+ }
+
+ js.ethereum.ChainManager().Reset()
+ if err = js.ethereum.ChainManager().InsertChain(blocks); err != nil {
+ fmt.Println(err)
+ return otto.FalseValue()
+ }
+
+ return otto.TrueValue()
+}
+
+func (js *jsre) exportChain(call otto.FunctionCall) otto.Value {
+ if len(call.ArgumentList) == 0 {
+ fmt.Println("err: require file name")
+ return otto.FalseValue()
+ }
+
+ fn, err := call.Argument(0).ToString()
+ if err != nil {
+ fmt.Println(err)
+ return otto.FalseValue()
+ }
+ if err := utils.ExportChain(js.ethereum.ChainManager(), fn); err != nil {
+ fmt.Println(err)
+ return otto.FalseValue()
+ }
+ return otto.TrueValue()
+}
+
+func (js *jsre) dumpBlock(call otto.FunctionCall) otto.Value {
+ var block *types.Block
+ if len(call.ArgumentList) > 0 {
+ if call.Argument(0).IsNumber() {
+ num, _ := call.Argument(0).ToInteger()
+ block = js.ethereum.ChainManager().GetBlockByNumber(uint64(num))
+ } else if call.Argument(0).IsString() {
+ hash, _ := call.Argument(0).ToString()
+ block = js.ethereum.ChainManager().GetBlock(common.HexToHash(hash))
+ } else {
+ fmt.Println("invalid argument for dump. Either hex string or number")
+ }
+
+ } else {
+ block = js.ethereum.ChainManager().CurrentBlock()
+ }
+ if block == nil {
+ fmt.Println("block not found")
+ return otto.UndefinedValue()
+ }
+
+ statedb := state.New(block.Root(), js.ethereum.StateDb())
+ dump := statedb.RawDump()
+ return js.re.ToVal(dump)
+
+}
diff --git a/cmd/geth/blocktest.go b/cmd/geth/blocktest.go
new file mode 100644
index 000000000..f0b6bb1a2
--- /dev/null
+++ b/cmd/geth/blocktest.go
@@ -0,0 +1,80 @@
+package main
+
+import (
+ "fmt"
+
+ "github.com/codegangsta/cli"
+ "github.com/ethereum/go-ethereum/cmd/utils"
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/eth"
+ "github.com/ethereum/go-ethereum/ethdb"
+ "github.com/ethereum/go-ethereum/tests"
+)
+
+var blocktestCmd = cli.Command{
+ Action: runblocktest,
+ Name: "blocktest",
+ Usage: `loads a block test file`,
+ Description: `
+The first argument should be a block test file.
+The second argument is the name of a block test from the file.
+
+The block test will be loaded into an in-memory database.
+If loading succeeds, the RPC server is started. Clients will
+be able to interact with the chain defined by the test.
+`,
+}
+
+func runblocktest(ctx *cli.Context) {
+ if len(ctx.Args()) != 3 {
+ utils.Fatalf("Usage: ethereum blocktest <path-to-test-file> <test-name> {rpc, norpc}")
+ }
+ file, testname, startrpc := ctx.Args()[0], ctx.Args()[1], ctx.Args()[2]
+
+ bt, err := tests.LoadBlockTests(file)
+ if err != nil {
+ utils.Fatalf("%v", err)
+ }
+ test, ok := bt[testname]
+ if !ok {
+ utils.Fatalf("Test file does not contain test named %q", testname)
+ }
+
+ cfg := utils.MakeEthConfig(ClientIdentifier, Version, ctx)
+ cfg.NewDB = func(path string) (common.Database, error) { return ethdb.NewMemDatabase() }
+ cfg.MaxPeers = 0 // disable network
+ ethereum, err := eth.New(cfg)
+ if err != nil {
+ utils.Fatalf("%v", err)
+ }
+
+ // import the genesis block
+ ethereum.ResetWithGenesisBlock(test.Genesis)
+
+ // import pre accounts
+ statedb, err := test.InsertPreState(ethereum.StateDb())
+ if err != nil {
+ utils.Fatalf("could not insert genesis accounts: %v", err)
+ }
+
+ // insert the test blocks, which will execute all transactions
+ chain := ethereum.ChainManager()
+ if err := chain.InsertChain(test.Blocks); err != nil {
+ utils.Fatalf("Block Test load error: %v %T", err, err)
+ } else {
+ fmt.Println("Block Test chain loaded")
+ }
+
+ if err := test.ValidatePostState(statedb); err != nil {
+ utils.Fatalf("post state validation failed: %v", err)
+ }
+ fmt.Println("Block Test post state validated, starting ethereum.")
+
+ if startrpc == "rpc" {
+ startEth(ctx, ethereum)
+ utils.StartRPC(ethereum, ctx)
+ ethereum.WaitForShutdown()
+ } else {
+ startEth(ctx, ethereum)
+ }
+}
diff --git a/cmd/geth/js.go b/cmd/geth/js.go
new file mode 100644
index 000000000..59a8469fa
--- /dev/null
+++ b/cmd/geth/js.go
@@ -0,0 +1,245 @@
+// Copyright (c) 2013-2014, Jeffrey Wilcke. All rights reserved.
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License, or (at your option) any later version.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// General Public License for more details.
+//
+// You should have received a copy of the GNU General Public License
+// along with this library; if not, write to the Free Software
+// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+// MA 02110-1301 USA
+
+package main
+
+import (
+ "bufio"
+ "fmt"
+ "os"
+ "path"
+ "strings"
+
+ "github.com/ethereum/go-ethereum/cmd/utils"
+ "github.com/ethereum/go-ethereum/core/types"
+ "github.com/ethereum/go-ethereum/eth"
+ re "github.com/ethereum/go-ethereum/jsre"
+ "github.com/ethereum/go-ethereum/rpc"
+ "github.com/ethereum/go-ethereum/xeth"
+ "github.com/peterh/liner"
+ "github.com/robertkrimen/otto"
+)
+
+type prompter interface {
+ AppendHistory(string)
+ Prompt(p string) (string, error)
+ PasswordPrompt(p string) (string, error)
+}
+
+type dumbterm struct{ r *bufio.Reader }
+
+func (r dumbterm) Prompt(p string) (string, error) {
+ fmt.Print(p)
+ return r.r.ReadString('\n')
+}
+
+func (r dumbterm) PasswordPrompt(p string) (string, error) {
+ fmt.Println("!! Unsupported terminal, password will echo.")
+ fmt.Print(p)
+ input, err := bufio.NewReader(os.Stdin).ReadString('\n')
+ fmt.Println()
+ return input, err
+}
+
+func (r dumbterm) AppendHistory(string) {}
+
+type jsre struct {
+ re *re.JSRE
+ ethereum *eth.Ethereum
+ xeth *xeth.XEth
+ ps1 string
+ atexit func()
+
+ prompter
+}
+
+func newJSRE(ethereum *eth.Ethereum, libPath string, interactive bool) *jsre {
+ js := &jsre{ethereum: ethereum, ps1: "> "}
+ js.xeth = xeth.New(ethereum, js)
+ js.re = re.New(libPath)
+ js.apiBindings()
+ js.adminBindings()
+
+ if !liner.TerminalSupported() || !interactive {
+ js.prompter = dumbterm{bufio.NewReader(os.Stdin)}
+ } else {
+ lr := liner.NewLiner()
+ js.withHistory(func(hist *os.File) { lr.ReadHistory(hist) })
+ lr.SetCtrlCAborts(true)
+ js.prompter = lr
+ js.atexit = func() {
+ js.withHistory(func(hist *os.File) { hist.Truncate(0); lr.WriteHistory(hist) })
+ lr.Close()
+ }
+ }
+ return js
+}
+
+func (js *jsre) apiBindings() {
+
+ ethApi := rpc.NewEthereumApi(js.xeth)
+ //js.re.Bind("jeth", rpc.NewJeth(ethApi, js.re.ToVal))
+
+ jeth := rpc.NewJeth(ethApi, js.re.ToVal, js.re)
+ //js.re.Bind("jeth", jeth)
+ js.re.Set("jeth", struct{}{})
+ t, _ := js.re.Get("jeth")
+ jethObj := t.Object()
+ jethObj.Set("send", jeth.Send)
+
+ err := js.re.Compile("bignumber.js", re.BigNumber_JS)
+ if err != nil {
+ utils.Fatalf("Error loading bignumber.js: %v", err)
+ }
+
+ // we need to declare a dummy setTimeout. Otto does not support it
+ _, err = js.re.Eval("setTimeout = function(cb, delay) {};")
+ if err != nil {
+ utils.Fatalf("Error defining setTimeout: %v", err)
+ }
+
+ err = js.re.Compile("ethereum.js", re.Ethereum_JS)
+ if err != nil {
+ utils.Fatalf("Error loading ethereum.js: %v", err)
+ }
+
+ _, err = js.re.Eval("var web3 = require('ethereum.js');")
+ if err != nil {
+ utils.Fatalf("Error requiring web3: %v", err)
+ }
+
+ _, err = js.re.Eval("web3.setProvider(jeth)")
+ if err != nil {
+ utils.Fatalf("Error setting web3 provider: %v", err)
+ }
+ _, err = js.re.Eval(`
+var eth = web3.eth;
+var shh = web3.shh;
+var db = web3.db;
+var net = web3.net;
+ `)
+ if err != nil {
+ utils.Fatalf("Error setting namespaces: %v", err)
+ }
+
+}
+
+func (self *jsre) ConfirmTransaction(tx *types.Transaction) bool {
+ p := fmt.Sprintf("Confirm Transaction %v\n[y/n] ", tx)
+ answer, _ := self.Prompt(p)
+ return strings.HasPrefix(strings.Trim(answer, " "), "y")
+}
+
+func (self *jsre) UnlockAccount(addr []byte) bool {
+ fmt.Printf("Please unlock account %x.\n", addr)
+ pass, err := self.PasswordPrompt("Passphrase: ")
+ if err != nil {
+ return false
+ }
+ // TODO: allow retry
+ if err := self.ethereum.AccountManager().Unlock(addr, pass); err != nil {
+ return false
+ } else {
+ fmt.Println("Account is now unlocked for this session.")
+ return true
+ }
+}
+
+func (self *jsre) exec(filename string) error {
+ if err := self.re.Exec(filename); err != nil {
+ return fmt.Errorf("Javascript Error: %v", err)
+ }
+ return nil
+}
+
+func (self *jsre) interactive() {
+ for {
+ input, err := self.Prompt(self.ps1)
+ if err != nil {
+ break
+ }
+ if input == "" {
+ continue
+ }
+ str += input + "\n"
+ self.setIndent()
+ if indentCount <= 0 {
+ if input == "exit" {
+ break
+ }
+ hist := str[:len(str)-1]
+ self.AppendHistory(hist)
+ self.parseInput(str)
+ str = ""
+ }
+ }
+ if self.atexit != nil {
+ self.atexit()
+ }
+}
+
+func (self *jsre) withHistory(op func(*os.File)) {
+ hist, err := os.OpenFile(path.Join(self.ethereum.DataDir, "history"), os.O_RDWR|os.O_CREATE, os.ModePerm)
+ if err != nil {
+ fmt.Printf("unable to open history file: %v\n", err)
+ return
+ }
+ op(hist)
+ hist.Close()
+}
+
+func (self *jsre) parseInput(code string) {
+ defer func() {
+ if r := recover(); r != nil {
+ fmt.Println("[native] error", r)
+ }
+ }()
+ value, err := self.re.Run(code)
+ if err != nil {
+ if ottoErr, ok := err.(*otto.Error); ok {
+ fmt.Println(ottoErr.String())
+ } else {
+ fmt.Println(err)
+ }
+ return
+ }
+ self.printValue(value)
+}
+
+var indentCount = 0
+var str = ""
+
+func (self *jsre) setIndent() {
+ open := strings.Count(str, "{")
+ open += strings.Count(str, "(")
+ closed := strings.Count(str, "}")
+ closed += strings.Count(str, ")")
+ indentCount = open - closed
+ if indentCount <= 0 {
+ self.ps1 = "> "
+ } else {
+ self.ps1 = strings.Join(make([]string, indentCount*2), "..")
+ self.ps1 += " "
+ }
+}
+
+func (self *jsre) printValue(v interface{}) {
+ val, err := self.re.PrettyPrint(v)
+ if err == nil {
+ fmt.Printf("%v", val)
+ }
+}
diff --git a/cmd/geth/js_test.go b/cmd/geth/js_test.go
new file mode 100644
index 000000000..5b962f621
--- /dev/null
+++ b/cmd/geth/js_test.go
@@ -0,0 +1,262 @@
+package main
+
+import (
+ "fmt"
+ "io/ioutil"
+ "os"
+ "path"
+ "testing"
+
+ "github.com/robertkrimen/otto"
+
+ "github.com/ethereum/go-ethereum/accounts"
+ "github.com/ethereum/go-ethereum/crypto"
+ "github.com/ethereum/go-ethereum/eth"
+)
+
+var port = 30300
+
+func testJEthRE(t *testing.T) (repl *jsre, ethereum *eth.Ethereum, err error) {
+ os.RemoveAll("/tmp/eth/")
+ err = os.MkdirAll("/tmp/eth/keys/e273f01c99144c438695e10f24926dc1f9fbf62d/", os.ModePerm)
+ if err != nil {
+ t.Errorf("%v", err)
+ return
+ }
+ err = os.MkdirAll("/tmp/eth/data", os.ModePerm)
+ if err != nil {
+ t.Errorf("%v", err)
+ return
+ }
+ // FIXME: this does not work ATM
+ ks := crypto.NewKeyStorePlain("/tmp/eth/keys")
+ ioutil.WriteFile("/tmp/eth/keys/e273f01c99144c438695e10f24926dc1f9fbf62d/e273f01c99144c438695e10f24926dc1f9fbf62d",
+ []byte(`{"Id":"RhRXD+fNRKS4jx+7ZfEsNA==","Address":"4nPwHJkUTEOGleEPJJJtwfn79i0=","PrivateKey":"h4ACVpe74uIvi5Cg/2tX/Yrm2xdr3J7QoMbMtNX2CNc="}`), os.ModePerm)
+
+ port++
+ ethereum, err = eth.New(&eth.Config{
+ DataDir: "/tmp/eth",
+ AccountManager: accounts.NewManager(ks),
+ Port: fmt.Sprintf("%d", port),
+ MaxPeers: 10,
+ Name: "test",
+ })
+
+ if err != nil {
+ t.Errorf("%v", err)
+ return
+ }
+ assetPath := path.Join(os.Getenv("GOPATH"), "src", "github.com", "ethereum", "go-ethereum", "cmd", "mist", "assets", "ext")
+ repl = newJSRE(ethereum, assetPath, false)
+ return
+}
+
+func TestNodeInfo(t *testing.T) {
+ repl, ethereum, err := testJEthRE(t)
+ if err != nil {
+ t.Errorf("error creating jsre, got %v", err)
+ return
+ }
+ err = ethereum.Start()
+ if err != nil {
+ t.Errorf("error starting ethereum: %v", err)
+ return
+ }
+ defer ethereum.Stop()
+
+ val, err := repl.re.Run("admin.nodeInfo()")
+ if err != nil {
+ t.Errorf("expected no error, got %v", err)
+ }
+ exp, err := val.Export()
+ if err != nil {
+ t.Errorf("expected no error, got %v", err)
+ }
+ nodeInfo, ok := exp.(*eth.NodeInfo)
+ if !ok {
+ t.Errorf("expected nodeInfo, got %v", err)
+ }
+ exp = "test"
+ got := nodeInfo.Name
+ if exp != got {
+ t.Errorf("expected %v, got %v", exp, got)
+ }
+ exp = 30301
+ port := nodeInfo.DiscPort
+ if exp != port {
+ t.Errorf("expected %v, got %v", exp, port)
+ }
+ exp = 30301
+ port = nodeInfo.TCPPort
+ if exp != port {
+ t.Errorf("expected %v, got %v", exp, port)
+ }
+}
+
+func TestAccounts(t *testing.T) {
+ repl, ethereum, err := testJEthRE(t)
+ if err != nil {
+ t.Errorf("error creating jsre, got %v", err)
+ return
+ }
+ err = ethereum.Start()
+ if err != nil {
+ t.Errorf("error starting ethereum: %v", err)
+ return
+ }
+ defer ethereum.Stop()
+
+ val, err := repl.re.Run("eth.coinbase")
+ if err != nil {
+ t.Errorf("expected no error, got %v", err)
+ }
+
+ pp, err := repl.re.PrettyPrint(val)
+ if err != nil {
+ t.Errorf("%v", err)
+ }
+
+ if !val.IsString() {
+ t.Errorf("incorrect type, expected string, got %v: %v", val, pp)
+ }
+ strVal, _ := val.ToString()
+ expected := "0xe273f01c99144c438695e10f24926dc1f9fbf62d"
+ if strVal != expected {
+ t.Errorf("incorrect result, expected %s, got %v", expected, strVal)
+ }
+
+ val, err = repl.re.Run(`admin.newAccount("password")`)
+ if err != nil {
+ t.Errorf("expected no error, got %v", err)
+ }
+ addr, err := val.ToString()
+ if err != nil {
+ t.Errorf("expected string, got %v", err)
+ }
+
+ val, err = repl.re.Run("eth.accounts")
+ if err != nil {
+ t.Errorf("expected no error, got %v", err)
+ }
+ exp, err := val.Export()
+ if err != nil {
+ t.Errorf("expected no error, got %v", err)
+ }
+ interfaceAddr, ok := exp.([]interface{})
+ if !ok {
+ t.Errorf("expected []string, got %T", exp)
+ }
+
+ addrs := make([]string, len(interfaceAddr))
+ for i, addr := range interfaceAddr {
+ var ok bool
+ if addrs[i], ok = addr.(string); !ok {
+ t.Errorf("expected addrs[%d] to be string. Got %T instead", i, addr)
+ }
+ }
+
+ if len(addrs) != 2 || (addr != addrs[0][2:] && addr != addrs[1][2:]) {
+ t.Errorf("expected addrs == [<default>, <new>], got %v (%v)", addrs, addr)
+ }
+
+}
+
+func TestBlockChain(t *testing.T) {
+ repl, ethereum, err := testJEthRE(t)
+ if err != nil {
+ t.Errorf("error creating jsre, got %v", err)
+ return
+ }
+ err = ethereum.Start()
+ if err != nil {
+ t.Errorf("error starting ethereum: %v", err)
+ return
+ }
+ defer ethereum.Stop()
+
+ // should get current block
+ val0, err := repl.re.Run("admin.dumpBlock()")
+ if err != nil {
+ t.Errorf("expected no error, got %v", err)
+ }
+
+ fn := "/tmp/eth/data/blockchain.0"
+ _, err = repl.re.Run("admin.export(\"" + fn + "\")")
+ if err != nil {
+ t.Errorf("expected no error, got %v", err)
+ }
+ if _, err = os.Stat(fn); err != nil {
+ t.Errorf("expected no error on file, got %v", err)
+ }
+
+ _, err = repl.re.Run("admin.import(\"" + fn + "\")")
+ if err != nil {
+ t.Errorf("expected no error, got %v", err)
+ }
+
+ var val1 otto.Value
+
+ // should get current block
+ val1, err = repl.re.Run("admin.dumpBlock()")
+ if err != nil {
+ t.Errorf("expected no error, got %v", err)
+ }
+
+ // FIXME: neither != , nor reflect.DeepEqual works, doing string comparison
+ v0 := fmt.Sprintf("%v", val0)
+ v1 := fmt.Sprintf("%v", val1)
+ if v0 != v1 {
+ t.Errorf("expected same head after export-import, got %v (!=%v)", v1, v0)
+ }
+}
+
+func TestMining(t *testing.T) {
+ repl, ethereum, err := testJEthRE(t)
+ if err != nil {
+ t.Errorf("error creating jsre, got %v", err)
+ return
+ }
+ err = ethereum.Start()
+ if err != nil {
+ t.Errorf("error starting ethereum: %v", err)
+ return
+ }
+ defer ethereum.Stop()
+
+ val, err := repl.re.Run("eth.mining")
+ if err != nil {
+ t.Errorf("expected no error, got %v", err)
+ }
+ var mining bool
+ mining, err = val.ToBoolean()
+ if err != nil {
+ t.Errorf("expected boolean, got %v", err)
+ }
+ if mining {
+ t.Errorf("expected false (not mining), got true")
+ }
+
+}
+
+func TestRPC(t *testing.T) {
+ repl, ethereum, err := testJEthRE(t)
+ if err != nil {
+ t.Errorf("error creating jsre, got %v", err)
+ return
+ }
+ err = ethereum.Start()
+ if err != nil {
+ t.Errorf("error starting ethereum: %v", err)
+ return
+ }
+ defer ethereum.Stop()
+
+ val, err := repl.re.Run(`admin.startRPC("127.0.0.1", 5004)`)
+ if err != nil {
+ t.Errorf("expected no error, got %v", err)
+ }
+ success, _ := val.ToBoolean()
+ if !success {
+ t.Errorf("expected true (started), got false")
+ }
+}
diff --git a/cmd/geth/main.go b/cmd/geth/main.go
new file mode 100644
index 000000000..62e30ac9a
--- /dev/null
+++ b/cmd/geth/main.go
@@ -0,0 +1,517 @@
+/*
+ This file is part of go-ethereum
+
+ go-ethereum is free software: you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation, either version 3 of the License, or
+ (at your option) any later version.
+
+ go-ethereum is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with go-ethereum. If not, see <http://www.gnu.org/licenses/>.
+*/
+/**
+ * @authors
+ * Jeffrey Wilcke <i@jev.io>
+ */
+package main
+
+import (
+ "bufio"
+ "fmt"
+ "io/ioutil"
+ "os"
+ "runtime"
+ "strconv"
+ "time"
+
+ "github.com/codegangsta/cli"
+ "github.com/ethereum/ethash"
+ "github.com/ethereum/go-ethereum/accounts"
+ "github.com/ethereum/go-ethereum/cmd/utils"
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/core/state"
+ "github.com/ethereum/go-ethereum/core/types"
+ "github.com/ethereum/go-ethereum/eth"
+ "github.com/ethereum/go-ethereum/logger"
+ "github.com/peterh/liner"
+)
+
+const (
+ ClientIdentifier = "Geth"
+ Version = "0.9.4"
+)
+
+var (
+ clilogger = logger.NewLogger("CLI")
+ app = utils.NewApp(Version, "the go-ethereum command line interface")
+)
+
+func init() {
+ app.Action = run
+ app.HideVersion = true // we have a command to print the version
+ app.Commands = []cli.Command{
+ blocktestCmd,
+ {
+ Action: makedag,
+ Name: "makedag",
+ Usage: "generate ethash dag (for testing)",
+ Description: `
+The makedag command generates an ethash DAG in /tmp/dag.
+
+This command exists to support the system testing project.
+Regular users do not need to execute it.
+`,
+ },
+ {
+ Action: version,
+ Name: "version",
+ Usage: "print ethereum version numbers",
+ Description: `
+The output of this command is supposed to be machine-readable.
+`,
+ },
+
+ {
+ Name: "wallet",
+ Usage: "ethereum presale wallet",
+ Subcommands: []cli.Command{
+ {
+ Action: importWallet,
+ Name: "import",
+ Usage: "import ethereum presale wallet",
+ },
+ },
+ },
+ {
+ Action: accountList,
+ Name: "account",
+ Usage: "manage accounts",
+ Description: `
+
+Manage accounts lets you create new accounts, list all existing accounts,
+import a private key into a new account.
+
+It supports interactive mode, when you are prompted for password as well as
+non-interactive mode where passwords are supplied via a given password file.
+Non-interactive mode is only meant for scripted use on test networks or known
+safe environments.
+
+Make sure you remember the password you gave when creating a new account (with
+either new or import). Without it you are not able to unlock your account.
+
+Note that exporting your key in unencrypted format is NOT supported.
+
+Keys are stored under <DATADIR>/keys.
+It is safe to transfer the entire directory or the individual keys therein
+between ethereum nodes.
+Make sure you backup your keys regularly.
+
+And finally. DO NOT FORGET YOUR PASSWORD.
+`,
+ Subcommands: []cli.Command{
+ {
+ Action: accountList,
+ Name: "list",
+ Usage: "print account addresses",
+ },
+ {
+ Action: accountCreate,
+ Name: "new",
+ Usage: "create a new account",
+ Description: `
+
+ ethereum account new
+
+Creates a new account. Prints the address.
+
+The account is saved in encrypted format, you are prompted for a passphrase.
+
+You must remember this passphrase to unlock your account in the future.
+
+For non-interactive use the passphrase can be specified with the --password flag:
+
+ ethereum --password <passwordfile> account new
+
+Note, this is meant to be used for testing only, it is a bad idea to save your
+password to file or expose in any other way.
+ `,
+ },
+ {
+ Action: accountImport,
+ Name: "import",
+ Usage: "import a private key into a new account",
+ Description: `
+
+ ethereum account import <keyfile>
+
+Imports an unencrypted private key from <keyfile> and creates a new account.
+Prints the address.
+
+The keyfile is assumed to contain an unencrypted private key in canonical EC
+raw bytes format.
+
+The account is saved in encrypted format, you are prompted for a passphrase.
+
+You must remember this passphrase to unlock your account in the future.
+
+For non-interactive use the passphrase can be specified with the -password flag:
+
+ ethereum --password <passwordfile> account import <keyfile>
+
+Note:
+As you can directly copy your encrypted accounts to another ethereum instance,
+this import mechanism is not needed when you transfer an account between
+nodes.
+ `,
+ },
+ },
+ },
+ {
+ Action: dump,
+ Name: "dump",
+ Usage: `dump a specific block from storage`,
+ Description: `
+The arguments are interpreted as block numbers or hashes.
+Use "ethereum dump 0" to dump the genesis block.
+`,
+ },
+ {
+ Action: console,
+ Name: "console",
+ Usage: `Geth Console: interactive JavaScript environment`,
+ Description: `
+The Geth console is an interactive shell for the JavaScript runtime environment
+which exposes a node admin interface as well as the DAPP JavaScript API.
+See https://github.com/ethereum/go-ethereum/wiki/Frontier-Console
+`,
+ },
+ {
+ Action: execJSFiles,
+ Name: "js",
+ Usage: `executes the given JavaScript files in the Geth JavaScript VM`,
+ Description: `
+The JavaScript VM exposes a node admin interface as well as the DAPP
+JavaScript API. See https://github.com/ethereum/go-ethereum/wiki/Javascipt-Console
+`,
+ },
+ {
+ Action: importchain,
+ Name: "import",
+ Usage: `import a blockchain file`,
+ },
+ {
+ Action: exportchain,
+ Name: "export",
+ Usage: `export blockchain into file`,
+ },
+ }
+ app.Flags = []cli.Flag{
+ utils.UnlockedAccountFlag,
+ utils.PasswordFileFlag,
+ utils.BootnodesFlag,
+ utils.DataDirFlag,
+ utils.JSpathFlag,
+ utils.ListenPortFlag,
+ utils.LogFileFlag,
+ utils.LogJSONFlag,
+ utils.LogLevelFlag,
+ utils.MaxPeersFlag,
+ utils.EtherbaseFlag,
+ utils.MinerThreadsFlag,
+ utils.MiningEnabledFlag,
+ utils.NATFlag,
+ utils.NodeKeyFileFlag,
+ utils.NodeKeyHexFlag,
+ utils.RPCEnabledFlag,
+ utils.RPCListenAddrFlag,
+ utils.RPCPortFlag,
+ utils.VMDebugFlag,
+ utils.ProtocolVersionFlag,
+ utils.NetworkIdFlag,
+ utils.RPCCORSDomainFlag,
+ }
+
+ // missing:
+ // flag.StringVar(&ConfigFile, "conf", defaultConfigFile, "config file")
+ // flag.BoolVar(&DiffTool, "difftool", false, "creates output for diff'ing. Sets LogLevel=0")
+ // flag.StringVar(&DiffType, "diff", "all", "sets the level of diff output [vm, all]. Has no effect if difftool=false")
+
+ // potential subcommands:
+ // flag.StringVar(&SecretFile, "import", "", "imports the file given (hex or mnemonic formats)")
+ // flag.StringVar(&ExportDir, "export", "", "exports the session keyring to files in the directory given")
+ // flag.BoolVar(&GenAddr, "genaddr", false, "create a new priv/pub key")
+}
+
+func main() {
+ runtime.GOMAXPROCS(runtime.NumCPU())
+ defer logger.Flush()
+ if err := app.Run(os.Args); err != nil {
+ fmt.Fprintln(os.Stderr, err)
+ os.Exit(1)
+ }
+}
+
+func run(ctx *cli.Context) {
+ fmt.Printf("Welcome to the FRONTIER\n")
+ utils.HandleInterrupt()
+ cfg := utils.MakeEthConfig(ClientIdentifier, Version, ctx)
+ ethereum, err := eth.New(cfg)
+ if err != nil {
+ utils.Fatalf("%v", err)
+ }
+
+ startEth(ctx, ethereum)
+ // this blocks the thread
+ ethereum.WaitForShutdown()
+}
+
+func console(ctx *cli.Context) {
+ cfg := utils.MakeEthConfig(ClientIdentifier, Version, ctx)
+ ethereum, err := eth.New(cfg)
+ if err != nil {
+ utils.Fatalf("%v", err)
+ }
+
+ startEth(ctx, ethereum)
+ repl := newJSRE(ethereum, ctx.String(utils.JSpathFlag.Name), true)
+ repl.interactive()
+
+ ethereum.Stop()
+ ethereum.WaitForShutdown()
+}
+
+func execJSFiles(ctx *cli.Context) {
+ cfg := utils.MakeEthConfig(ClientIdentifier, Version, ctx)
+ ethereum, err := eth.New(cfg)
+ if err != nil {
+ utils.Fatalf("%v", err)
+ }
+
+ startEth(ctx, ethereum)
+ repl := newJSRE(ethereum, ctx.String(utils.JSpathFlag.Name), false)
+ for _, file := range ctx.Args() {
+ repl.exec(file)
+ }
+
+ ethereum.Stop()
+ ethereum.WaitForShutdown()
+}
+
+func unlockAccount(ctx *cli.Context, am *accounts.Manager, account string) (passphrase string) {
+ var err error
+ // Load startup keys. XXX we are going to need a different format
+ // Attempt to unlock the account
+ passphrase = getPassPhrase(ctx, "", false)
+ accbytes := common.FromHex(account)
+ if len(accbytes) == 0 {
+ utils.Fatalf("Invalid account address '%s'", account)
+ }
+ err = am.Unlock(accbytes, passphrase)
+ if err != nil {
+ utils.Fatalf("Unlock account failed '%v'", err)
+ }
+ return
+}
+
+func startEth(ctx *cli.Context, eth *eth.Ethereum) {
+ utils.StartEthereum(eth)
+ am := eth.AccountManager()
+
+ account := ctx.GlobalString(utils.UnlockedAccountFlag.Name)
+ if len(account) > 0 {
+ if account == "primary" {
+ accbytes, err := am.Primary()
+ if err != nil {
+ utils.Fatalf("no primary account: %v", err)
+ }
+ account = common.ToHex(accbytes)
+ }
+ unlockAccount(ctx, am, account)
+ }
+ // Start auxiliary services if enabled.
+ if ctx.GlobalBool(utils.RPCEnabledFlag.Name) {
+ utils.StartRPC(eth, ctx)
+ }
+ if ctx.GlobalBool(utils.MiningEnabledFlag.Name) {
+ eth.StartMining()
+ }
+}
+
+func accountList(ctx *cli.Context) {
+ am := utils.GetAccountManager(ctx)
+ accts, err := am.Accounts()
+ if err != nil {
+ utils.Fatalf("Could not list accounts: %v", err)
+ }
+ for _, acct := range accts {
+ fmt.Printf("Address: %x\n", acct)
+ }
+}
+
+func getPassPhrase(ctx *cli.Context, desc string, confirmation bool) (passphrase string) {
+ passfile := ctx.GlobalString(utils.PasswordFileFlag.Name)
+ if len(passfile) == 0 {
+ fmt.Println(desc)
+ auth, err := readPassword("Passphrase: ", true)
+ if err != nil {
+ utils.Fatalf("%v", err)
+ }
+ if confirmation {
+ confirm, err := readPassword("Repeat Passphrase: ", false)
+ if err != nil {
+ utils.Fatalf("%v", err)
+ }
+ if auth != confirm {
+ utils.Fatalf("Passphrases did not match.")
+ }
+ }
+ passphrase = auth
+
+ } else {
+ passbytes, err := ioutil.ReadFile(passfile)
+ if err != nil {
+ utils.Fatalf("Unable to read password file '%s': %v", passfile, err)
+ }
+ passphrase = string(passbytes)
+ }
+ return
+}
+
+func accountCreate(ctx *cli.Context) {
+ am := utils.GetAccountManager(ctx)
+ passphrase := getPassPhrase(ctx, "Your new account is locked with a password. Please give a password. Do not forget this password.", true)
+ acct, err := am.NewAccount(passphrase)
+ if err != nil {
+ utils.Fatalf("Could not create the account: %v", err)
+ }
+ fmt.Printf("Address: %x\n", acct)
+}
+
+func importWallet(ctx *cli.Context) {
+ keyfile := ctx.Args().First()
+ if len(keyfile) == 0 {
+ utils.Fatalf("keyfile must be given as argument")
+ }
+ keyJson, err := ioutil.ReadFile(keyfile)
+ if err != nil {
+ utils.Fatalf("Could not read wallet file: %v", err)
+ }
+
+ am := utils.GetAccountManager(ctx)
+ passphrase := getPassPhrase(ctx, "", false)
+
+ acct, err := am.ImportPreSaleKey(keyJson, passphrase)
+ if err != nil {
+ utils.Fatalf("Could not create the account: %v", err)
+ }
+ fmt.Printf("Address: %x\n", acct)
+}
+
+func accountImport(ctx *cli.Context) {
+ keyfile := ctx.Args().First()
+ if len(keyfile) == 0 {
+ utils.Fatalf("keyfile must be given as argument")
+ }
+ am := utils.GetAccountManager(ctx)
+ passphrase := getPassPhrase(ctx, "Your new account is locked with a password. Please give a password. Do not forget this password.", true)
+ acct, err := am.Import(keyfile, passphrase)
+ if err != nil {
+ utils.Fatalf("Could not create the account: %v", err)
+ }
+ fmt.Printf("Address: %x\n", acct)
+}
+
+func importchain(ctx *cli.Context) {
+ if len(ctx.Args()) != 1 {
+ utils.Fatalf("This command requires an argument.")
+ }
+ chainmgr, _, _ := utils.GetChain(ctx)
+ start := time.Now()
+ err := utils.ImportChain(chainmgr, ctx.Args().First())
+ if err != nil {
+ utils.Fatalf("Import error: %v\n", err)
+ }
+ fmt.Printf("Import done in %v", time.Since(start))
+ return
+}
+
+func exportchain(ctx *cli.Context) {
+ if len(ctx.Args()) != 1 {
+ utils.Fatalf("This command requires an argument.")
+ }
+ chainmgr, _, _ := utils.GetChain(ctx)
+ start := time.Now()
+ err := utils.ExportChain(chainmgr, ctx.Args().First())
+ if err != nil {
+ utils.Fatalf("Export error: %v\n", err)
+ }
+ fmt.Printf("Export done in %v", time.Since(start))
+ return
+}
+
+func dump(ctx *cli.Context) {
+ chainmgr, _, stateDb := utils.GetChain(ctx)
+ for _, arg := range ctx.Args() {
+ var block *types.Block
+ if hashish(arg) {
+ block = chainmgr.GetBlock(common.HexToHash(arg))
+ } else {
+ num, _ := strconv.Atoi(arg)
+ block = chainmgr.GetBlockByNumber(uint64(num))
+ }
+ if block == nil {
+ fmt.Println("{}")
+ utils.Fatalf("block not found")
+ } else {
+ statedb := state.New(block.Root(), stateDb)
+ fmt.Printf("%s\n", statedb.Dump())
+ }
+ }
+}
+
+func makedag(ctx *cli.Context) {
+ chain, _, _ := utils.GetChain(ctx)
+ pow := ethash.New(chain)
+ fmt.Println("making cache")
+ pow.UpdateCache(true)
+ fmt.Println("making DAG")
+ pow.UpdateDAG()
+}
+
+func version(c *cli.Context) {
+ fmt.Printf(`%v
+Version: %v
+Protocol Version: %d
+Network Id: %d
+GO: %s
+OS: %s
+GOPATH=%s
+GOROOT=%s
+`, ClientIdentifier, Version, c.GlobalInt(utils.ProtocolVersionFlag.Name), c.GlobalInt(utils.NetworkIdFlag.Name), runtime.Version(), runtime.GOOS, os.Getenv("GOPATH"), runtime.GOROOT())
+}
+
+// hashish returns true for strings that look like hashes.
+func hashish(x string) bool {
+ _, err := strconv.Atoi(x)
+ return err != nil
+}
+
+func readPassword(prompt string, warnTerm bool) (string, error) {
+ if liner.TerminalSupported() {
+ lr := liner.NewLiner()
+ defer lr.Close()
+ return lr.PasswordPrompt(prompt)
+ }
+ if warnTerm {
+ fmt.Println("!! Unsupported terminal, password will be echoed.")
+ }
+ fmt.Print(prompt)
+ input, err := bufio.NewReader(os.Stdin).ReadString('\n')
+ fmt.Println()
+ return input, err
+}
diff --git a/cmd/mist/assets/back.png b/cmd/mist/assets/back.png
new file mode 100644
index 000000000..38fc84d6e
--- /dev/null
+++ b/cmd/mist/assets/back.png
Binary files differ
diff --git a/cmd/mist/assets/backButton.png b/cmd/mist/assets/backButton.png
new file mode 100644
index 000000000..eef997434
--- /dev/null
+++ b/cmd/mist/assets/backButton.png
Binary files differ
diff --git a/cmd/mist/assets/backButton@2x.png b/cmd/mist/assets/backButton@2x.png
new file mode 100644
index 000000000..b72fd73f4
--- /dev/null
+++ b/cmd/mist/assets/backButton@2x.png
Binary files differ
diff --git a/cmd/mist/assets/backButtonDisabled.png b/cmd/mist/assets/backButtonDisabled.png
new file mode 100644
index 000000000..428747870
--- /dev/null
+++ b/cmd/mist/assets/backButtonDisabled.png
Binary files differ
diff --git a/cmd/mist/assets/backButtonDisabled@2x.png b/cmd/mist/assets/backButtonDisabled@2x.png
new file mode 100644
index 000000000..0eaa6daa5
--- /dev/null
+++ b/cmd/mist/assets/backButtonDisabled@2x.png
Binary files differ
diff --git a/cmd/mist/assets/backButtonHover.png b/cmd/mist/assets/backButtonHover.png
new file mode 100644
index 000000000..8c5226f5a
--- /dev/null
+++ b/cmd/mist/assets/backButtonHover.png
Binary files differ
diff --git a/cmd/mist/assets/backButtonHover@2x.png b/cmd/mist/assets/backButtonHover@2x.png
new file mode 100644
index 000000000..406601ebc
--- /dev/null
+++ b/cmd/mist/assets/backButtonHover@2x.png
Binary files differ
diff --git a/cmd/mist/assets/browser.png b/cmd/mist/assets/browser.png
new file mode 100644
index 000000000..074c9ae3c
--- /dev/null
+++ b/cmd/mist/assets/browser.png
Binary files differ
diff --git a/cmd/mist/assets/browser@2x.png b/cmd/mist/assets/browser@2x.png
new file mode 100644
index 000000000..8ca417608
--- /dev/null
+++ b/cmd/mist/assets/browser@2x.png
Binary files differ
diff --git a/cmd/mist/assets/bug.png b/cmd/mist/assets/bug.png
new file mode 100644
index 000000000..f5e85dc99
--- /dev/null
+++ b/cmd/mist/assets/bug.png
Binary files differ
diff --git a/cmd/mist/assets/close.png b/cmd/mist/assets/close.png
new file mode 100644
index 000000000..88df442c5
--- /dev/null
+++ b/cmd/mist/assets/close.png
Binary files differ
diff --git a/cmd/mist/assets/debugger/debugger.qml b/cmd/mist/assets/debugger/debugger.qml
new file mode 100644
index 000000000..5566e8fca
--- /dev/null
+++ b/cmd/mist/assets/debugger/debugger.qml
@@ -0,0 +1,436 @@
+import QtQuick 2.0
+import QtQuick.Controls 1.0;
+import QtQuick.Layouts 1.0;
+import QtQuick.Dialogs 1.0;
+import QtQuick.Window 2.1;
+import QtQuick.Controls.Styles 1.1
+import Ethereum 1.0
+
+ApplicationWindow {
+ id: win
+ visible: false
+ title: "IceCREAM"
+ minimumWidth: 1280
+ minimumHeight: 700
+ width: 1290
+ height: 750
+
+ property alias codeText: codeEditor.text
+ property alias dataText: rawDataField.text
+
+ onClosing: {
+ //dbg.Stop()
+ }
+
+ menuBar: MenuBar {
+ Menu {
+ title: "Edit"
+ MenuItem {
+ text: "Focus code"
+ shortcut: "Ctrl+1"
+ onTriggered: {
+ codeEditor.focus = true
+ }
+ }
+ MenuItem {
+ text: "Focus data"
+ shortcut: "Ctrl+2"
+ onTriggered: {
+ rawDataField.focus = true
+ }
+ }
+
+ MenuItem {
+ text: "Command"
+ shortcut: "Ctrl+l"
+ onTriggered: {
+ dbgCommand.focus = true
+ }
+ }
+ }
+
+ Menu {
+ title: "Debugger"
+ MenuItem {
+ text: "Run"
+ shortcut: "Ctrl+r"
+ onTriggered: debugCurrent()
+ }
+
+ MenuItem {
+ text: "Stop"
+ onTriggered: dbp.stop()
+ }
+
+ MenuSeparator {}
+
+ MenuItem {
+ text: "Next"
+ shortcut: "Ctrl+n"
+ onTriggered: dbg.next()
+ }
+
+ MenuItem {
+ text: "Continue"
+ shortcut: "Ctrl+g"
+ onTriggered: dbg.continue()
+ }
+ }
+ }
+
+
+ SplitView {
+ anchors.fill: parent
+ property var asmModel: ListModel {
+ id: asmModel
+ }
+
+ TableView {
+ id: asmTableView
+ width: 200
+ headerVisible: false
+ TableViewColumn{ role: "value" ; title: "" ; width: asmTableView.width - 2 }
+ model: asmModel
+ /*
+ alternatingRowColors: false
+ itemDelegate: Item {
+ Rectangle {
+ anchors.fill: parent
+ color: "#DDD"
+ Text {
+ anchors {
+ left: parent.left
+ right: parent.right
+ leftMargin: 10
+ verticalCenter: parent.verticalCenter
+ }
+ color: "#333"
+ elide: styleData.elideMode
+ text: styleData.value
+ font.pixelSize: 11
+ MouseArea {
+ acceptedButtons: Qt.LeftButton
+ anchors.fill: parent
+ onClicked: {
+ mouse.accepted = true
+ }
+ }
+ }
+ }
+ }
+ */
+ }
+
+ Rectangle {
+ color: "#00000000"
+ anchors.left: asmTableView.right
+ anchors.right: parent.right
+ SplitView {
+ orientation: Qt.Vertical
+ anchors.fill: parent
+
+ Rectangle {
+ color: "#00000000"
+ height: 330
+ anchors.left: parent.left
+ anchors.right: parent.right
+
+ TextArea {
+ id: codeEditor
+ anchors.top: parent.top
+ anchors.bottom: parent.bottom
+ anchors.left: parent.left
+ anchors.right: settings.left
+ focus: true
+
+ /*
+ Timer {
+ id: compileTimer
+ interval: 500 ; running: true ; repeat: true
+ onTriggered: {
+ dbg.autoComp(codeEditor.text)
+ }
+ }
+ */
+ }
+
+ Column {
+ id: settings
+ spacing: 5
+ width: 300
+ height: parent.height
+ anchors.right: parent.right
+ anchors.top: parent.top
+ anchors.bottom: parent.bottom
+
+ Label {
+ text: "Arbitrary data"
+ }
+ TextArea {
+ id: rawDataField
+ anchors.left: parent.left
+ anchors.right: parent.right
+ height: 150
+ }
+
+ Label {
+ text: "Amount"
+ }
+ TextField {
+ id: txValue
+ width: 200
+ placeholderText: "Amount"
+ validator: RegExpValidator { regExp: /\d*/ }
+ }
+ Label {
+ text: "Amount of gas"
+ }
+ TextField {
+ id: txGas
+ width: 200
+ validator: RegExpValidator { regExp: /\d*/ }
+ text: "10000"
+ placeholderText: "Gas"
+ }
+ Label {
+ text: "Gas price"
+ }
+ TextField {
+ id: txGasPrice
+ width: 200
+ placeholderText: "Gas price"
+ text: "1000000000000"
+ validator: RegExpValidator { regExp: /\d*/ }
+ }
+ }
+ }
+
+ SplitView {
+ orientation: Qt.Vertical
+ id: inspectorPane
+ height: 500
+
+ SplitView {
+ orientation: Qt.Horizontal
+ height: 150
+
+ TableView {
+ id: stackTableView
+ property var stackModel: ListModel {
+ id: stackModel
+ }
+ height: parent.height
+ width: 300
+ TableViewColumn{ role: "value" ; title: "Local VM stack" ; width: stackTableView.width - 2 }
+ model: stackModel
+ }
+
+ TableView {
+ id: memoryTableView
+ property var memModel: ListModel {
+ id: memModel
+ }
+ height: parent.height
+ width: parent.width - stackTableView.width
+ TableViewColumn{ id:mnumColmn ; role: "num" ; title: "#" ; width: 50 }
+ TableViewColumn{ role: "value" ; title: "Memory" ; width: 650 }
+ model: memModel
+ }
+ }
+
+ Rectangle {
+ height: 100
+ width: parent.width
+ TableView {
+ id: storageTableView
+ property var memModel: ListModel {
+ id: storageModel
+ }
+ height: parent.height
+ width: parent.width
+ TableViewColumn{ id: key ; role: "key" ; title: "#" ; width: storageTableView.width / 2 - 1}
+ TableViewColumn{ role: "value" ; title: "Storage" ; width: storageTableView.width / 2 - 1}
+ model: storageModel
+ }
+ }
+
+ Rectangle {
+ height: 200
+ width: parent.width * 0.66
+ TableView {
+ id: logTableView
+ property var logModel: ListModel {
+ id: logModel
+ }
+ height: parent.height
+ width: parent.width
+ TableViewColumn{ id: message ; role: "message" ; title: "log" ; width: logTableView.width - 2 }
+ model: logModel
+ }
+ }
+
+ }
+ }
+ }
+ }
+
+ function exec() {
+ dbg.execCommand(dbgCommand.text);
+ dbgCommand.text = "";
+ }
+ statusBar: StatusBar {
+ height: 30
+
+
+ TextField {
+ id: dbgCommand
+ y: 1
+ x: asmTableView.width
+ width: 500
+ placeholderText: "Debugger (type 'help')"
+ Keys.onReturnPressed: {
+ exec()
+ }
+ }
+
+ RowLayout {
+ anchors.left: dbgCommand.right
+ anchors.leftMargin: 10
+ spacing: 5
+ y: parent.height / 2 - this.height / 2
+
+ Text {
+ objectName: "stackFrame"
+ font.pixelSize: 10
+ text: "<b>stack ptr</b>: 0"
+ }
+
+ Text {
+ objectName: "stackSize"
+ font.pixelSize: 10
+ text: "<b>stack size</b>: 0"
+ }
+
+ Text {
+ objectName: "memSize"
+ font.pixelSize: 10
+ text: "<b>mem size</b>: 0"
+ }
+ }
+ }
+
+ toolBar: ToolBar {
+ height: 30
+ RowLayout {
+ spacing: 10
+
+ Button {
+ property var enabled: true
+ id: debugStart
+ onClicked: {
+ debugCurrent()
+ }
+ text: "Debug"
+ }
+
+ Button {
+ property var enabled: true
+ id: debugNextButton
+ onClicked: {
+ dbg.next()
+ }
+ text: "Next"
+ }
+
+ Button {
+ id: debugContinueButton
+ onClicked: {
+ dbg.continue()
+ }
+ text: "Continue"
+ }
+ }
+
+
+ ComboBox {
+ visible: false
+ id: snippets
+ anchors.right: parent.right
+ model: ListModel {
+ ListElement { text: "Snippets" ; value: "" }
+ ListElement { text: "Call Contract" ; value: "var[2] in = { \"arg1\", 0xdeadbeef };\nvar ret;\n\nvar success = call(0x0c542ddea93dae0c2fcb2cf175f03ad80d6be9a0, 0, 7000, in, ret)\n\nreturn ret" }
+ }
+ onCurrentIndexChanged: {
+ if(currentIndex != 0) {
+ var code = snippets.model.get(currentIndex).value;
+ codeEditor.insert(codeEditor.cursorPosition, code)
+ }
+ }
+ }
+
+ }
+
+ function debugCurrent() {
+ dbg.debug(txValue.text, txGas.text, txGasPrice.text, codeEditor.text, rawDataField.text)
+ }
+
+ function setAsm(asm) {
+ asmModel.append({asm: asm})
+ }
+
+ function clearAsm() {
+ asmModel.clear()
+ }
+
+ function setInstruction(num) {
+ asmTableView.selection.clear()
+ asmTableView.selection.select(num)
+ asmTableView.positionViewAtRow(num, ListView.Center)
+ }
+
+ function setMem(mem) {
+ memModel.append({num: mem.num, value: mem.value})
+ }
+ function clearMem(){
+ memModel.clear()
+ }
+
+ function setStack(stack) {
+ stackModel.append({value: stack})
+ }
+ function addDebugMessage(message){
+ debuggerLog.append({value: message})
+ }
+
+ function clearStack() {
+ stackModel.clear()
+ }
+
+ function clearStorage() {
+ storageModel.clear()
+ }
+
+ function setStorage(storage) {
+ storageModel.append({key: storage.key, value: storage.value})
+ }
+
+ function setLog(msg) {
+ // Remove first item once we've reached max log items
+ if(logModel.count > 250) {
+ logModel.remove(0)
+ }
+
+ if(msg.len != 0) {
+ if(logTableView.flickableItem.atYEnd) {
+ logModel.append({message: msg})
+ logTableView.positionViewAtRow(logTableView.rowCount - 1, ListView.Contain)
+ } else {
+ logModel.append({message: msg})
+ }
+ }
+ }
+
+ function clearLog() {
+ logModel.clear()
+ }
+}
diff --git a/cmd/mist/assets/examples/abi.html b/cmd/mist/assets/examples/abi.html
new file mode 100644
index 000000000..8170e88b0
--- /dev/null
+++ b/cmd/mist/assets/examples/abi.html
@@ -0,0 +1,55 @@
+<!doctype>
+<html>
+<head>
+<title>Hello world</title>
+<script src="../ext/bignumber.min.js"></script>
+<script src="../ext/ethereum.js/dist/ethereum.js"></script>
+<script>
+ var web3 = require('web3');
+ web3.setProvider(new web3.providers.HttpSyncProvider('http://localhost:8080'));
+ var eth = web3.eth;
+ var desc = [{
+ "name": "multiply(uint256)",
+ "inputs": [{
+ "name": "a",
+ "type": "uint256"
+ }],
+ "outputs": [{
+ "name": "d",
+ "type": "uint256"
+ }]
+ }];
+ var address = web3.eth.transact({
+ data: "0x603880600c6000396000f3006001600060e060020a600035048063c6888fa114601857005b6021600435602b565b8060005260206000f35b600081600702905091905056",
+ gasPrice: "1000000000000000",
+ gas: "10000",
+ });
+ var contract = web3.eth.contract(address, desc);
+
+ function calculate() {
+ var param = parseInt(document.getElementById('value').value);
+
+ var res = contract.call().multiply(param);
+ document.getElementById('result').innerText = res.toString(10);
+ }
+</script>
+</head>
+<body>
+<h3>Contract content</h3>
+<textarea style="height:100px; width: 300px;" disabled="disabled">
+contract test {
+ function multiply(uint a) returns(uint d) {
+ return a * 7;
+ }
+}
+</textarea>
+<code><pre>
+603880600c6000396000f3006001600060e060020a600035048063c6888fa1140
+05b6021600435602b565b8060005260206000f35b600081600702905091905056</pre></code>
+
+<hr>
+<div>7 x <input type="number" id="value" onkeyup='calculate()'></input> =
+<span id="result"></spa>
+
+</body>
+</html>
diff --git a/cmd/mist/assets/examples/balance.html b/cmd/mist/assets/examples/balance.html
new file mode 100644
index 000000000..bc483a879
--- /dev/null
+++ b/cmd/mist/assets/examples/balance.html
@@ -0,0 +1,40 @@
+<!doctype>
+<html>
+
+<head>
+<script src="../ext/bignumber.min.js"></script>
+<script src="../ext/ethereum.js/dist/ethereum.js"></script>
+<script type="text/javascript">
+
+ var web3 = require('web3');
+ web3.setProvider(new web3.providers.HttpSyncProvider('http://localhost:8080'));
+
+ function watchBalance() {
+ var coinbase = web3.eth.coinbase;
+ var originalBalance = 0;
+
+ var balance = web3.eth.balanceAt(coinbase);
+ var originalBalance = web3.toDecimal(balance);
+ document.getElementById('original').innerText = 'original balance: ' + originalBalance + ' watching...';
+
+ web3.eth.watch({altered: coinbase}).changed(function() {
+ balance = web3.eth.balanceAt(coinbase)
+ var currentBalance = web3.toDecimal(balance);
+ document.getElementById("current").innerText = 'current: ' + currentBalance;
+ document.getElementById("diff").innerText = 'diff: ' + (currentBalance - originalBalance);
+ });
+ }
+
+</script>
+</head>
+<body>
+ <h1>coinbase balance</h1>
+ <button type="button" onClick="watchBalance();">watch balance</button>
+ <div></div>
+ <div id="original"></div>
+ <div id="current"></div>
+ <div id="diff"></div>
+</body>
+</html>
+
+
diff --git a/cmd/mist/assets/examples/bomb.html b/cmd/mist/assets/examples/bomb.html
new file mode 100644
index 000000000..62540f9bb
--- /dev/null
+++ b/cmd/mist/assets/examples/bomb.html
@@ -0,0 +1,22 @@
+<html>
+<head>
+<script src="../ext/bignumber.min.js"></script>
+<script src="../ext/ethereum.js/dist/ethereum.js"></script>
+
+<script>
+var web3 = require('web3');
+web3.setProvider(new web3.providers.HttpSyncProvider('http://localhost:8545'));
+var eth = web3.eth;
+
+function bomb() {
+ for (var i = 0; i < 200; i++) {
+ eth.transact({})
+ }
+}
+</script>
+</head>
+
+<body>
+<button onclick="bomb();">BOOM!</button>
+</body>
+</html>
diff --git a/cmd/mist/assets/examples/coin.html b/cmd/mist/assets/examples/coin.html
new file mode 100644
index 000000000..b265f777d
--- /dev/null
+++ b/cmd/mist/assets/examples/coin.html
@@ -0,0 +1,148 @@
+<!doctype>
+<html>
+<title>JevCoin</title>
+<head>
+<script type="text/javascript" src="../ext/bignumber.min.js"></script>
+<script type="text/javascript" src="../ext/ethereum.js/dist/ethereum-light.min.js"></script>
+</head>
+<body>
+
+<h1>JevCoin <code id="contract_addr"></code></h1>
+<div>
+ <strong>Balance</strong>
+ <span id="balance"></strong>
+</div>
+
+<div>
+ <span>Address:</span>
+ <input type="text" id="address" style="width:200px">
+ <span>Amount:</span>
+ <input type="text" id="amount" style="width:200px">
+ <button onclick="transact()">Send</button>
+ <span id="message"></span>
+</div>
+
+<hr>
+
+<table width="100%" id="table">
+ <tr><td style="width:40%;">Address</td><td>Balance</td></tr>
+ <tbody id="table_body"></tbody>
+</table>
+
+</body>
+
+<script type="text/javascript">
+ var web3 = require('ethereum.js');
+ var eth = web3.eth;
+
+ web3.setProvider(new web3.providers.HttpProvider('http://localhost:8545'));
+ var desc = [{
+ "name": "balance(address)",
+ "type": "function",
+ "inputs": [{
+ "name": "who",
+ "type": "address"
+ }],
+ "constant": true,
+ "outputs": [{
+ "name": "value",
+ "type": "uint256"
+ }]
+ }, {
+ "name": "send(address,uint256)",
+ "type": "function",
+ "inputs": [{
+ "name": "to",
+ "type": "address"
+ }, {
+ "name": "value",
+ "type": "uint256"
+ }],
+ "outputs": []
+ }, {
+ "name":"Changed",
+ "type":"event",
+ "inputs": [
+ {"name":"from","type":"address","indexed":true},
+ {"name":"amount","type":"uint256","indexed":true},
+ ],
+ }];
+
+ var address = localStorage.getItem("address");
+ // deploy if not exist
+ if(address === null) {
+ var code = "0x60056013565b61014f8061003a6000396000f35b620f42406000600033600160a060020a0316815260200190815260200160002081905550560060e060020a600035048063d0679d3414610020578063e3d670d71461003457005b61002e600435602435610049565b60006000f35b61003f600435610129565b8060005260206000f35b806000600033600160a060020a03168152602001908152602001600020541061007157610076565b610125565b806000600033600160a060020a03168152602001908152602001600020908154039081905550806000600084600160a060020a031681526020019081526020016000209081540190819055508033600160a060020a03167fb52dda022b6c1a1f40905a85f257f689aa5d69d850e49cf939d688fbe5af594660006000a38082600160a060020a03167fb52dda022b6c1a1f40905a85f257f689aa5d69d850e49cf939d688fbe5af594660006000a35b5050565b60006000600083600160a060020a0316815260200190815260200160002054905091905056";
+ address = web3.eth.sendTransaction({from: eth.coinbase, data: code, gas: "1000000"});
+ localStorage.setItem("address", address);
+ }
+ document.querySelector("#contract_addr").innerHTML = address;
+
+ var Contract = web3.eth.contract(desc);
+ contract = new Contract(address);
+ contract.Changed({from: eth.accounts[0]}).watch(function() {
+ refresh();
+ });
+
+ function refresh() {
+ document.querySelector("#balance").innerHTML = contract.call({from:eth.coinbase}).balance(eth.coinbase);
+
+ var table = document.querySelector("#table_body");
+ table.innerHTML = ""; // clear
+ }
+
+ function transact() {
+ var to = document.querySelector("#address");
+ if( to.value.length == 0 ) {
+ to = "0x4205b06c2cfa0e30359edcab94543266cb6fa1d3";
+ } else {
+ if (to.value.substr(0,2) != "0x")
+ to.value = "0x"+to.value;
+ }
+
+ var value = document.querySelector("#amount");
+ var amount = parseInt( value.value );
+ console.log("transact: ", to.value, " => ", amount)
+
+ contract.sendTransaction({from: eth.accounts[0]}).send( to.value, amount );
+
+ to.value = "";
+ value.value = "";
+
+ var message = document.querySelector("#message")
+ message.innerHTML = "Submitted";
+ setTimeout(function() {
+ message.innerHTML = "";
+ }, 1000);
+ }
+
+ refresh();
+</script>
+</html>
+
+<!--
+contract JevCoin {
+ function JevCoin()
+ {
+ balances[msg.sender] = 1000000;
+ }
+
+ event Changed(address indexed from, uint indexed amount);
+ function send(address to, uint value)
+ {
+ if( balances[msg.sender] < value ) return;
+
+ balances[msg.sender] -= value;
+ balances[to] += value;
+
+ Changed(msg.sender, value);
+ Changed(to, value);
+ }
+
+ function balance(address who) constant returns(uint t)
+ {
+ t = balances[who];
+ }
+
+ mapping(address => uint256) balances;
+ }
+-!>
diff --git a/cmd/mist/assets/examples/coin.js b/cmd/mist/assets/examples/coin.js
new file mode 100644
index 000000000..77daac846
--- /dev/null
+++ b/cmd/mist/assets/examples/coin.js
@@ -0,0 +1,65 @@
+var walletABI = [
+ {
+ "name":"confirm",
+ "type":"function",
+ "constant":false,
+ "inputs":[
+ {"name":"_h","type":"hash256"}
+ ],
+ "outputs":[]
+ },{
+ "name":"execute",
+ "constant":false,
+ "type":"function",
+ "inputs":[
+ {"name":"_to","type":"address"},
+ {"name":"_value","type":"uint256"},
+ {"name":"_data","type":"bytes"}
+ ],
+ "outputs":[
+ {"name":"_r","type":"hash256"}
+ ]
+ },{
+ "name":"kill",
+ "type":"function",
+ "constant":false,
+ "inputs":[
+ {"name":"_to","type":"address"}
+ ],
+ "outputs":[]
+ },{
+ "name":"changeOwner",
+ "type":"function",
+ "constant":false,
+ "inputs":[
+ {"name":"_from","type":"address"},
+ {"name":"_to","type":"address"}
+ ],
+ "outputs":[]
+ },{
+ "name":"CashIn",
+ "type":"event",
+ "inputs":[
+ {"indexed":false,"name":"value","type":"uint256"}
+ ]
+ },{
+ "name":"SingleTransact",
+ "type":"event",
+ "inputs":[
+ {"indexed":true,"name":"out","type":"string32"},
+ {"indexed":false,"name":"owner","type":"address"},
+ {"indexed":false,"name":"value","type":"uint256"},
+ {"indexed":false,"name":"to","type":"address"}
+ ]
+ },{
+ "name":"MultiTransact",
+ "type":"event",
+ "inputs":[
+ {"indexed":true,"name":"out","type":"string32"},
+ {"indexed":false,"name":"owner","type":"address"},
+ {"indexed":false,"name":"operation","type":"hash256"},
+ {"indexed":false,"name":"value","type":"uint256"},
+ {"indexed":false,"name":"to","type":"address"}
+ ]
+ }
+];
diff --git a/cmd/mist/assets/examples/info.html b/cmd/mist/assets/examples/info.html
new file mode 100644
index 000000000..3b958a494
--- /dev/null
+++ b/cmd/mist/assets/examples/info.html
@@ -0,0 +1,84 @@
+
+<!doctype>
+<html>
+<head>
+<meta name="badge" content="10">
+<script type="text/javascript" src="../ext/bignumber.min.js"></script>
+<script type="text/javascript" src="../ext/ethereum.js/dist/ethereum.js"></script>
+</head>
+<body>
+ <h1>Info</h1>
+
+ <table width="100%">
+ <tr>
+ <td>Block number</td>
+ <td id="number"></td>
+ </tr>
+
+ <tr>
+ <td>Peer count</td>
+ <td id="peer_count"></td>
+ </tr>
+
+ <tr>
+ <td>Default block</td>
+ <td id="default_block"></td>
+ </tr>
+
+ <tr>
+ <td>Accounts</td>
+ <td id="accounts"></td>
+ </tr>
+
+ <tr>
+ <td>Balance</td>
+ <td id="balance"></td>
+
+ <tr>
+ <td>Gas price</td>
+ <td id="gas_price"></td>
+ </tr>
+
+ <tr>
+ <td>Mining</td>
+ <td id="mining"></td>
+ </tr>
+
+ <tr>
+ <td>Listening</td>
+ <td id="listening"></td>
+ </tr>
+
+ <tr>
+ <td>Coinbase</td>
+ <td id="coinbase"></td>
+ </tr>
+ </table>
+</body>
+
+<script type="text/javascript">
+ var web3 = require('web3');
+ var eth = web3.eth;
+
+ web3.setProvider(new web3.providers.HttpSyncProvider('http://localhost:8545'));
+
+ eth.defaultBlock = -2
+
+ document.querySelector("#number").innerHTML = eth.number;
+ document.querySelector("#coinbase").innerHTML = eth.coinbase
+ document.querySelector("#peer_count").innerHTML = eth.peerCount;
+ document.querySelector("#default_block").innerHTML = eth.defaultBlock;
+ document.querySelector("#accounts").innerHTML = eth.accounts;
+ document.querySelector("#balance").innerHTML = web3.toEth(eth.balanceAt(eth.accounts[0]));
+ document.querySelector("#gas_price").innerHTML = eth.gasPrice;
+ document.querySelector("#mining").innerHTML = eth.mining;
+ document.querySelector("#listening").innerHTML = eth.listening;
+ eth.watch('chain').changed(function() {
+ document.querySelector("#number").innerHTML = eth.number;
+ });
+
+
+</script>
+
+</html>
+
diff --git a/cmd/mist/assets/examples/whisper.html b/cmd/mist/assets/examples/whisper.html
new file mode 100644
index 000000000..ad568f783
--- /dev/null
+++ b/cmd/mist/assets/examples/whisper.html
@@ -0,0 +1,70 @@
+<!doctype>
+<html>
+<title>Whisper test</title>
+<head>
+<script type="text/javascript" src="../ext/bignumber.min.js"></script>
+<script type="text/javascript" src="../ext/ethereum.js/dist/ethereum.js"></script>
+</head>
+<body>
+
+<h1>Whisper test</h1>
+
+<button onclick="test()">Send</button>
+<button onclick="test2()">Private send</button>
+
+<table width="100%" id="table">
+ <tr>
+ <td>Count</td>
+ <td id="count"></td>
+ </tr>
+
+ <tr>
+ <td>ID</td>
+ <td id="id"></td>
+ </tr>
+
+ <tr>
+ <td>Has identity</td>
+ <td id="known"></td>
+ </tr>
+</table>
+</body>
+
+<script type="text/javascript">
+ var web3 = require('web3');
+ web3.setProvider(new web3.providers.HttpSyncProvider('http://localhost:8080'));
+
+ var shh = web3.shh;
+
+ var id = shh.newIdentity();
+ document.querySelector("#id").innerHTML = id;
+ document.querySelector("#known").innerHTML = shh.haveIdentity(id);
+
+ var watch = shh.watch({topics: ["test"]})
+ watch.arrived(function(message) {
+ document.querySelector("#table").innerHTML += "<tr><td colspan='2'>"+JSON.stringify(message)+"</td></tr>";
+ });
+
+ var selfWatch = shh.watch({to: id, topics: ["test"]})
+ selfWatch.arrived(function(message) {
+ document.querySelector("#table").innerHTML += "<tr><td>To me</td><td>"+JSON.stringify(message)+"</td></tr>";
+ });
+
+ function test() {
+ shh.post({topics: ["test"], payload: web3.fromAscii("test it")});
+ count();
+ }
+
+ function test2() {
+ shh.post({to: id, topics: ["test"], payload: web3.fromAscii("Private")});
+ count();
+ }
+
+ function count() {
+ document.querySelector("#count").innerHTML = watch.messages().length;
+ }
+</script>
+
+</html>
+
+
diff --git a/cmd/mist/assets/ext/.bowerrc b/cmd/mist/assets/ext/.bowerrc
new file mode 100644
index 000000000..c3a8813e8
--- /dev/null
+++ b/cmd/mist/assets/ext/.bowerrc
@@ -0,0 +1,5 @@
+{
+ "directory": "example/js/",
+ "cwd": "./",
+ "analytics": false
+} \ No newline at end of file
diff --git a/cmd/mist/assets/ext/.editorconfig b/cmd/mist/assets/ext/.editorconfig
new file mode 100644
index 000000000..60a2751d3
--- /dev/null
+++ b/cmd/mist/assets/ext/.editorconfig
@@ -0,0 +1,12 @@
+root = true
+
+[*]
+indent_style = space
+indent_size = 4
+end_of_line = lf
+charset = utf-8
+trim_trailing_whitespace = true
+insert_final_newline = true
+
+[*.md]
+trim_trailing_whitespace = false \ No newline at end of file
diff --git a/cmd/mist/assets/ext/.gitignore b/cmd/mist/assets/ext/.gitignore
new file mode 100644
index 000000000..399b6dc88
--- /dev/null
+++ b/cmd/mist/assets/ext/.gitignore
@@ -0,0 +1,18 @@
+# See http://help.github.com/ignore-files/ for more about ignoring files.
+#
+# If you find yourself ignoring temporary files generated by your text editor
+# or operating system, you probably want to add a global ignore instead:
+# git config --global core.excludesfile ~/.gitignore_global
+
+*.swp
+/tmp
+*/**/*un~
+*un~
+.DS_Store
+*/**/.DS_Store
+ethereum/ethereum
+ethereal/ethereal
+example/js
+node_modules
+bower_components
+npm-debug.log
diff --git a/cmd/mist/assets/ext/.jshintrc b/cmd/mist/assets/ext/.jshintrc
new file mode 100644
index 000000000..c0ec5f89d
--- /dev/null
+++ b/cmd/mist/assets/ext/.jshintrc
@@ -0,0 +1,50 @@
+{
+ "predef": [
+ "console",
+ "require",
+ "equal",
+ "test",
+ "testBoth",
+ "testWithDefault",
+ "raises",
+ "deepEqual",
+ "start",
+ "stop",
+ "ok",
+ "strictEqual",
+ "module",
+ "expect",
+ "reject",
+ "impl"
+ ],
+
+ "esnext": true,
+ "proto": true,
+ "node" : true,
+ "browser" : true,
+ "browserify" : true,
+
+ "boss" : true,
+ "curly": false,
+ "debug": true,
+ "devel": true,
+ "eqeqeq": true,
+ "evil": true,
+ "forin": false,
+ "immed": false,
+ "laxbreak": false,
+ "newcap": true,
+ "noarg": true,
+ "noempty": false,
+ "nonew": false,
+ "nomen": false,
+ "onevar": false,
+ "plusplus": false,
+ "regexp": false,
+ "undef": true,
+ "sub": true,
+ "strict": false,
+ "white": false,
+ "shadow": true,
+ "eqnull": true
+} \ No newline at end of file
diff --git a/cmd/mist/assets/ext/.npmignore b/cmd/mist/assets/ext/.npmignore
new file mode 100644
index 000000000..5bbffe4fd
--- /dev/null
+++ b/cmd/mist/assets/ext/.npmignore
@@ -0,0 +1,9 @@
+example/js
+node_modules
+test
+.gitignore
+.editorconfig
+.travis.yml
+.npmignore
+component.json
+testling.html \ No newline at end of file
diff --git a/cmd/mist/assets/ext/.travis.yml b/cmd/mist/assets/ext/.travis.yml
new file mode 100644
index 000000000..83b21d840
--- /dev/null
+++ b/cmd/mist/assets/ext/.travis.yml
@@ -0,0 +1,13 @@
+language: node_js
+node_js:
+ - "0.11"
+ - "0.10"
+before_script:
+ - npm install
+ - npm install jshint
+script:
+ - "jshint *.js lib"
+after_script:
+ - npm run-script build
+ - npm test
+
diff --git a/cmd/mist/assets/ext/bignumber.min.js b/cmd/mist/assets/ext/bignumber.min.js
new file mode 100644
index 000000000..7b63a8a02
--- /dev/null
+++ b/cmd/mist/assets/ext/bignumber.min.js
@@ -0,0 +1,4 @@
+/* bignumber.js v2.0.3 https://github.com/MikeMcl/bignumber.js/LICENCE */
+/* modified by zelig to fix https://github.com/robertkrimen/otto#regular-expression-incompatibility */
+!function(e){"use strict";function n(e){function a(e,n){var t,r,i,o,u,s,f=this;if(!(f instanceof a))return j&&L(26,"constructor call without new",e),new a(e,n);if(null!=n&&H(n,2,64,M,"base")){if(n=0|n,s=e+"",10==n)return f=new a(e instanceof a?e:s),U(f,P+f.e+1,k);if((o="number"==typeof e)&&0*e!=0||!new RegExp("^-?"+(t="["+O.slice(0,n)+"]+")+"(?:\\."+t+")?$",37>n?"i":"").test(s))return g(f,s,o,n);o?(f.s=0>1/e?(s=s.slice(1),-1):1,j&&s.replace(/^0\.0*|\./,"").length>15&&L(M,b,e),o=!1):f.s=45===s.charCodeAt(0)?(s=s.slice(1),-1):1,s=D(s,10,n,f.s)}else{if(e instanceof a)return f.s=e.s,f.e=e.e,f.c=(e=e.c)?e.slice():e,void(M=0);if((o="number"==typeof e)&&0*e==0){if(f.s=0>1/e?(e=-e,-1):1,e===~~e){for(r=0,i=e;i>=10;i/=10,r++);return f.e=r,f.c=[e],void(M=0)}s=e+""}else{if(!p.test(s=e+""))return g(f,s,o);f.s=45===s.charCodeAt(0)?(s=s.slice(1),-1):1}}for((r=s.indexOf("."))>-1&&(s=s.replace(".","")),(i=s.search(/e/i))>0?(0>r&&(r=i),r+=+s.slice(i+1),s=s.substring(0,i)):0>r&&(r=s.length),i=0;48===s.charCodeAt(i);i++);for(u=s.length;48===s.charCodeAt(--u););if(s=s.slice(i,u+1))if(u=s.length,o&&j&&u>15&&L(M,b,f.s*e),r=r-i-1,r>z)f.c=f.e=null;else if(G>r)f.c=[f.e=0];else{if(f.e=r,f.c=[],i=(r+1)%y,0>r&&(i+=y),u>i){for(i&&f.c.push(+s.slice(0,i)),u-=y;u>i;)f.c.push(+s.slice(i,i+=y));s=s.slice(i),i=y-s.length}else i-=u;for(;i--;s+="0");f.c.push(+s)}else f.c=[f.e=0];M=0}function D(e,n,t,i){var o,u,f,c,h,g,p,d=e.indexOf("."),m=P,w=k;for(37>t&&(e=e.toLowerCase()),d>=0&&(f=J,J=0,e=e.replace(".",""),p=new a(t),h=p.pow(e.length-d),J=f,p.c=s(l(r(h.c),h.e),10,n),p.e=p.c.length),g=s(e,t,n),u=f=g.length;0==g[--f];g.pop());if(!g[0])return"0";if(0>d?--u:(h.c=g,h.e=u,h.s=i,h=C(h,p,m,w,n),g=h.c,c=h.r,u=h.e),o=u+m+1,d=g[o],f=n/2,c=c||0>o||null!=g[o+1],c=4>w?(null!=d||c)&&(0==w||w==(h.s<0?3:2)):d>f||d==f&&(4==w||c||6==w&&1&g[o-1]||w==(h.s<0?8:7)),1>o||!g[0])e=c?l("1",-m):"0";else{if(g.length=o,c)for(--n;++g[--o]>n;)g[o]=0,o||(++u,g.unshift(1));for(f=g.length;!g[--f];);for(d=0,e="";f>=d;e+=O.charAt(g[d++]));e=l(e,u)}return e}function _(e,n,t,i){var o,u,s,c,h;if(t=null!=t&&H(t,0,8,i,v)?0|t:k,!e.c)return e.toString();if(o=e.c[0],s=e.e,null==n)h=r(e.c),h=19==i||24==i&&B>=s?f(h,s):l(h,s);else if(e=U(new a(e),n,t),u=e.e,h=r(e.c),c=h.length,19==i||24==i&&(u>=n||B>=u)){for(;n>c;h+="0",c++);h=f(h,u)}else if(n-=s,h=l(h,u),u+1>c){if(--n>0)for(h+=".";n--;h+="0");}else if(n+=u-c,n>0)for(u+1==c&&(h+=".");n--;h+="0");return e.s<0&&o?"-"+h:h}function x(e,n){var t,r,i=0;for(u(e[0])&&(e=e[0]),t=new a(e[0]);++i<e.length;){if(r=new a(e[i]),!r.s){t=r;break}n.call(t,r)&&(t=r)}return t}function F(e,n,t,r,i){return(n>e||e>t||e!=c(e))&&L(r,(i||"decimal places")+(n>e||e>t?" out of range":" not an integer"),e),!0}function I(e,n,t){for(var r=1,i=n.length;!n[--i];n.pop());for(i=n[0];i>=10;i/=10,r++);return(t=r+t*y-1)>z?e.c=e.e=null:G>t?e.c=[e.e=0]:(e.e=t,e.c=n),e}function L(e,n,t){var r=new Error(["new BigNumber","cmp","config","div","divToInt","eq","gt","gte","lt","lte","minus","mod","plus","precision","random","round","shift","times","toDigits","toExponential","toFixed","toFormat","toFraction","pow","toPrecision","toString","BigNumber"][e]+"() "+n+": "+t);throw r.name="BigNumber Error",M=0,r}function U(e,n,t,r){var i,o,u,s,f,l,c,a=e.c,h=R;if(a){e:{for(i=1,s=a[0];s>=10;s/=10,i++);if(o=n-i,0>o)o+=y,u=n,f=a[l=0],c=f/h[i-u-1]%10|0;else if(l=d((o+1)/y),l>=a.length){if(!r)break e;for(;a.length<=l;a.push(0));f=c=0,i=1,o%=y,u=o-y+1}else{for(f=s=a[l],i=1;s>=10;s/=10,i++);o%=y,u=o-y+i,c=0>u?0:f/h[i-u-1]%10|0}if(r=r||0>n||null!=a[l+1]||(0>u?f:f%h[i-u-1]),r=4>t?(c||r)&&(0==t||t==(e.s<0?3:2)):c>5||5==c&&(4==t||r||6==t&&(o>0?u>0?f/h[i-u]:0:a[l-1])%10&1||t==(e.s<0?8:7)),1>n||!a[0])return a.length=0,r?(n-=e.e+1,a[0]=h[n%y],e.e=-n||0):a[0]=e.e=0,e;if(0==o?(a.length=l,s=1,l--):(a.length=l+1,s=h[y-o],a[l]=u>0?m(f/h[i-u]%h[u])*s:0),r)for(;;){if(0==l){for(o=1,u=a[0];u>=10;u/=10,o++);for(u=a[0]+=s,s=1;u>=10;u/=10,s++);o!=s&&(e.e++,a[0]==N&&(a[0]=1));break}if(a[l]+=s,a[l]!=N)break;a[l--]=0,s=1}for(o=a.length;0===a[--o];a.pop());}e.e>z?e.c=e.e=null:e.e<G&&(e.c=[e.e=0])}return e}var C,M=0,T=a.prototype,q=new a(1),P=20,k=4,B=-7,$=21,G=-1e7,z=1e7,j=!0,H=F,V=!1,W=1,J=100,X={decimalSeparator:".",groupSeparator:",",groupSize:3,secondaryGroupSize:0,fractionGroupSeparator:" ",fractionGroupSize:0};return a.another=n,a.ROUND_UP=0,a.ROUND_DOWN=1,a.ROUND_CEIL=2,a.ROUND_FLOOR=3,a.ROUND_HALF_UP=4,a.ROUND_HALF_DOWN=5,a.ROUND_HALF_EVEN=6,a.ROUND_HALF_CEIL=7,a.ROUND_HALF_FLOOR=8,a.EUCLID=9,a.config=function(){var e,n,t=0,r={},i=arguments,s=i[0],f=s&&"object"==typeof s?function(){return s.hasOwnProperty(n)?null!=(e=s[n]):void 0}:function(){return i.length>t?null!=(e=i[t++]):void 0};return f(n="DECIMAL_PLACES")&&H(e,0,E,2,n)&&(P=0|e),r[n]=P,f(n="ROUNDING_MODE")&&H(e,0,8,2,n)&&(k=0|e),r[n]=k,f(n="EXPONENTIAL_AT")&&(u(e)?H(e[0],-E,0,2,n)&&H(e[1],0,E,2,n)&&(B=0|e[0],$=0|e[1]):H(e,-E,E,2,n)&&(B=-($=0|(0>e?-e:e)))),r[n]=[B,$],f(n="RANGE")&&(u(e)?H(e[0],-E,-1,2,n)&&H(e[1],1,E,2,n)&&(G=0|e[0],z=0|e[1]):H(e,-E,E,2,n)&&(0|e?G=-(z=0|(0>e?-e:e)):j&&L(2,n+" cannot be zero",e))),r[n]=[G,z],f(n="ERRORS")&&(e===!!e||1===e||0===e?(M=0,H=(j=!!e)?F:o):j&&L(2,n+w,e)),r[n]=j,f(n="CRYPTO")&&(e===!!e||1===e||0===e?(V=!(!e||!h||"object"!=typeof h),e&&!V&&j&&L(2,"crypto unavailable",h)):j&&L(2,n+w,e)),r[n]=V,f(n="MODULO_MODE")&&H(e,0,9,2,n)&&(W=0|e),r[n]=W,f(n="POW_PRECISION")&&H(e,0,E,2,n)&&(J=0|e),r[n]=J,f(n="FORMAT")&&("object"==typeof e?X=e:j&&L(2,n+" not an object",e)),r[n]=X,r},a.max=function(){return x(arguments,T.lt)},a.min=function(){return x(arguments,T.gt)},a.random=function(){var e=9007199254740992,n=Math.random()*e&2097151?function(){return m(Math.random()*e)}:function(){return 8388608*(1073741824*Math.random()|0)+(8388608*Math.random()|0)};return function(e){var t,r,i,o,u,s=0,f=[],l=new a(q);if(e=null!=e&&H(e,0,E,14)?0|e:P,o=d(e/y),V)if(h&&h.getRandomValues){for(t=h.getRandomValues(new Uint32Array(o*=2));o>s;)u=131072*t[s]+(t[s+1]>>>11),u>=9e15?(r=h.getRandomValues(new Uint32Array(2)),t[s]=r[0],t[s+1]=r[1]):(f.push(u%1e14),s+=2);s=o/2}else if(h&&h.randomBytes){for(t=h.randomBytes(o*=7);o>s;)u=281474976710656*(31&t[s])+1099511627776*t[s+1]+4294967296*t[s+2]+16777216*t[s+3]+(t[s+4]<<16)+(t[s+5]<<8)+t[s+6],u>=9e15?h.randomBytes(7).copy(t,s):(f.push(u%1e14),s+=7);s=o/7}else j&&L(14,"crypto unavailable",h);if(!s)for(;o>s;)u=n(),9e15>u&&(f[s++]=u%1e14);for(o=f[--s],e%=y,o&&e&&(u=R[y-e],f[s]=m(o/u)*u);0===f[s];f.pop(),s--);if(0>s)f=[i=0];else{for(i=-1;0===f[0];f.shift(),i-=y);for(s=1,u=f[0];u>=10;u/=10,s++);y>s&&(i-=y-s)}return l.e=i,l.c=f,l}}(),C=function(){function e(e,n,t){var r,i,o,u,s=0,f=e.length,l=n%A,c=n/A|0;for(e=e.slice();f--;)o=e[f]%A,u=e[f]/A|0,r=c*o+u*l,i=l*o+r%A*A+s,s=(i/t|0)+(r/A|0)+c*u,e[f]=i%t;return s&&e.unshift(s),e}function n(e,n,t,r){var i,o;if(t!=r)o=t>r?1:-1;else for(i=o=0;t>i;i++)if(e[i]!=n[i]){o=e[i]>n[i]?1:-1;break}return o}function r(e,n,t,r){for(var i=0;t--;)e[t]-=i,i=e[t]<n[t]?1:0,e[t]=i*r+e[t]-n[t];for(;!e[0]&&e.length>1;e.shift());}return function(i,o,u,s,f){var l,c,h,g,p,d,w,v,b,O,S,R,A,E,D,_,x,F=i.s==o.s?1:-1,I=i.c,L=o.c;if(!(I&&I[0]&&L&&L[0]))return new a(i.s&&o.s&&(I?!L||I[0]!=L[0]:L)?I&&0==I[0]||!L?0*F:F/0:0/0);for(v=new a(F),b=v.c=[],c=i.e-o.e,F=u+c+1,f||(f=N,c=t(i.e/y)-t(o.e/y),F=F/y|0),h=0;L[h]==(I[h]||0);h++);if(L[h]>(I[h]||0)&&c--,0>F)b.push(1),g=!0;else{for(E=I.length,_=L.length,h=0,F+=2,p=m(f/(L[0]+1)),p>1&&(L=e(L,p,f),I=e(I,p,f),_=L.length,E=I.length),A=_,O=I.slice(0,_),S=O.length;_>S;O[S++]=0);x=L.slice(),x.unshift(0),D=L[0],L[1]>=f/2&&D++;do p=0,l=n(L,O,_,S),0>l?(R=O[0],_!=S&&(R=R*f+(O[1]||0)),p=m(R/D),p>1?(p>=f&&(p=f-1),d=e(L,p,f),w=d.length,S=O.length,l=n(d,O,w,S),1==l&&(p--,r(d,w>_?x:L,w,f))):(0==p&&(l=p=1),d=L.slice()),w=d.length,S>w&&d.unshift(0),r(O,d,S,f),-1==l&&(S=O.length,l=n(L,O,_,S),1>l&&(p++,r(O,S>_?x:L,S,f))),S=O.length):0===l&&(p++,O=[0]),b[h++]=p,l&&O[0]?O[S++]=I[A]||0:(O=[I[A]],S=1);while((A++<E||null!=O[0])&&F--);g=null!=O[0],b[0]||b.shift()}if(f==N){for(h=1,F=b[0];F>=10;F/=10,h++);U(v,u+(v.e=h+c*y-1)+1,s,g)}else v.e=c,v.r=+g;return v}}(),g=function(){var e=/^(-?)0([xbo])(\w[\w.]*$)/i,n=/^([^.]+)\.$/,t=/^\.([^.]+)$/,r=/^-?(Infinity|NaN)$/,i=/^\s*\+([\w.])|^\s+|\s+$/g;return function(o,u,s,f){var l,c=s?u:u.replace(i,"$1");if(r.test(c))o.s=isNaN(c)?null:0>c?-1:1;else{if(!s&&(c=c.replace(e,function(e,n,t){return l="x"==(t=t.toLowerCase())?16:"b"==t?2:8,f&&f!=l?e:n}),f&&(l=f,c=c.replace(n,"$1").replace(t,"0.$1")),u!=c))return new a(c,l);j&&L(M,"not a"+(f?" base "+f:"")+" number",u),o.s=null}o.c=o.e=null,M=0}}(),T.absoluteValue=T.abs=function(){var e=new a(this);return e.s<0&&(e.s=1),e},T.ceil=function(){return U(new a(this),this.e+1,2)},T.comparedTo=T.cmp=function(e,n){return M=1,i(this,new a(e,n))},T.decimalPlaces=T.dp=function(){var e,n,r=this.c;if(!r)return null;if(e=((n=r.length-1)-t(this.e/y))*y,n=r[n])for(;n%10==0;n/=10,e--);return 0>e&&(e=0),e},T.dividedBy=T.div=function(e,n){return M=3,C(this,new a(e,n),P,k)},T.dividedToIntegerBy=T.divToInt=function(e,n){return M=4,C(this,new a(e,n),0,1)},T.equals=T.eq=function(e,n){return M=5,0===i(this,new a(e,n))},T.floor=function(){return U(new a(this),this.e+1,3)},T.greaterThan=T.gt=function(e,n){return M=6,i(this,new a(e,n))>0},T.greaterThanOrEqualTo=T.gte=function(e,n){return M=7,1===(n=i(this,new a(e,n)))||0===n},T.isFinite=function(){return!!this.c},T.isInteger=T.isInt=function(){return!!this.c&&t(this.e/y)>this.c.length-2},T.isNaN=function(){return!this.s},T.isNegative=T.isNeg=function(){return this.s<0},T.isZero=function(){return!!this.c&&0==this.c[0]},T.lessThan=T.lt=function(e,n){return M=8,i(this,new a(e,n))<0},T.lessThanOrEqualTo=T.lte=function(e,n){return M=9,-1===(n=i(this,new a(e,n)))||0===n},T.minus=T.sub=function(e,n){var r,i,o,u,s=this,f=s.s;if(M=10,e=new a(e,n),n=e.s,!f||!n)return new a(0/0);if(f!=n)return e.s=-n,s.plus(e);var l=s.e/y,c=e.e/y,h=s.c,g=e.c;if(!l||!c){if(!h||!g)return h?(e.s=-n,e):new a(g?s:0/0);if(!h[0]||!g[0])return g[0]?(e.s=-n,e):new a(h[0]?s:3==k?-0:0)}if(l=t(l),c=t(c),h=h.slice(),f=l-c){for((u=0>f)?(f=-f,o=h):(c=l,o=g),o.reverse(),n=f;n--;o.push(0));o.reverse()}else for(i=(u=(f=h.length)<(n=g.length))?f:n,f=n=0;i>n;n++)if(h[n]!=g[n]){u=h[n]<g[n];break}if(u&&(o=h,h=g,g=o,e.s=-e.s),n=(i=g.length)-(r=h.length),n>0)for(;n--;h[r++]=0);for(n=N-1;i>f;){if(h[--i]<g[i]){for(r=i;r&&!h[--r];h[r]=n);--h[r],h[i]+=N}h[i]-=g[i]}for(;0==h[0];h.shift(),--c);return h[0]?I(e,h,c):(e.s=3==k?-1:1,e.c=[e.e=0],e)},T.modulo=T.mod=function(e,n){var t,r,i=this;return M=11,e=new a(e,n),!i.c||!e.s||e.c&&!e.c[0]?new a(0/0):!e.c||i.c&&!i.c[0]?new a(i):(9==W?(r=e.s,e.s=1,t=C(i,e,0,3),e.s=r,t.s*=r):t=C(i,e,0,W),i.minus(t.times(e)))},T.negated=T.neg=function(){var e=new a(this);return e.s=-e.s||null,e},T.plus=T.add=function(e,n){var r,i=this,o=i.s;if(M=12,e=new a(e,n),n=e.s,!o||!n)return new a(0/0);if(o!=n)return e.s=-n,i.minus(e);var u=i.e/y,s=e.e/y,f=i.c,l=e.c;if(!u||!s){if(!f||!l)return new a(o/0);if(!f[0]||!l[0])return l[0]?e:new a(f[0]?i:0*o)}if(u=t(u),s=t(s),f=f.slice(),o=u-s){for(o>0?(s=u,r=l):(o=-o,r=f),r.reverse();o--;r.push(0));r.reverse()}for(o=f.length,n=l.length,0>o-n&&(r=l,l=f,f=r,n=o),o=0;n;)o=(f[--n]=f[n]+l[n]+o)/N|0,f[n]%=N;return o&&(f.unshift(o),++s),I(e,f,s)},T.precision=T.sd=function(e){var n,t,r=this,i=r.c;if(null!=e&&e!==!!e&&1!==e&&0!==e&&(j&&L(13,"argument"+w,e),e!=!!e&&(e=null)),!i)return null;if(t=i.length-1,n=t*y+1,t=i[t]){for(;t%10==0;t/=10,n--);for(t=i[0];t>=10;t/=10,n++);}return e&&r.e+1>n&&(n=r.e+1),n},T.round=function(e,n){var t=new a(this);return(null==e||H(e,0,E,15))&&U(t,~~e+this.e+1,null!=n&&H(n,0,8,15,v)?0|n:k),t},T.shift=function(e){var n=this;return H(e,-S,S,16,"argument")?n.times("1e"+c(e)):new a(n.c&&n.c[0]&&(-S>e||e>S)?n.s*(0>e?0:1/0):n)},T.squareRoot=T.sqrt=function(){var e,n,i,o,u,s=this,f=s.c,l=s.s,c=s.e,h=P+4,g=new a("0.5");if(1!==l||!f||!f[0])return new a(!l||0>l&&(!f||f[0])?0/0:f?s:1/0);if(l=Math.sqrt(+s),0==l||l==1/0?(n=r(f),(n.length+c)%2==0&&(n+="0"),l=Math.sqrt(n),c=t((c+1)/2)-(0>c||c%2),l==1/0?n="1e"+c:(n=l.toExponential(),n=n.slice(0,n.indexOf("e")+1)+c),i=new a(n)):i=new a(l+""),i.c[0])for(c=i.e,l=c+h,3>l&&(l=0);;)if(u=i,i=g.times(u.plus(C(s,u,h,1))),r(u.c).slice(0,l)===(n=r(i.c)).slice(0,l)){if(i.e<c&&--l,n=n.slice(l-3,l+1),"9999"!=n&&(o||"4999"!=n)){(!+n||!+n.slice(1)&&"5"==n.charAt(0))&&(U(i,i.e+P+2,1),e=!i.times(i).eq(s));break}if(!o&&(U(u,u.e+P+2,0),u.times(u).eq(s))){i=u;break}h+=4,l+=4,o=1}return U(i,i.e+P+1,k,e)},T.times=T.mul=function(e,n){var r,i,o,u,s,f,l,c,h,g,p,d,m,w,v,b=this,O=b.c,S=(M=17,e=new a(e,n)).c;if(!(O&&S&&O[0]&&S[0]))return!b.s||!e.s||O&&!O[0]&&!S||S&&!S[0]&&!O?e.c=e.e=e.s=null:(e.s*=b.s,O&&S?(e.c=[0],e.e=0):e.c=e.e=null),e;for(i=t(b.e/y)+t(e.e/y),e.s*=b.s,l=O.length,g=S.length,g>l&&(m=O,O=S,S=m,o=l,l=g,g=o),o=l+g,m=[];o--;m.push(0));for(w=N,v=A,o=g;--o>=0;){for(r=0,p=S[o]%v,d=S[o]/v|0,s=l,u=o+s;u>o;)c=O[--s]%v,h=O[s]/v|0,f=d*c+h*p,c=p*c+f%v*v+m[u]+r,r=(c/w|0)+(f/v|0)+d*h,m[u--]=c%w;m[u]=r}return r?++i:m.shift(),I(e,m,i)},T.toDigits=function(e,n){var t=new a(this);return e=null!=e&&H(e,1,E,18,"precision")?0|e:null,n=null!=n&&H(n,0,8,18,v)?0|n:k,e?U(t,e,n):t},T.toExponential=function(e,n){return _(this,null!=e&&H(e,0,E,19)?~~e+1:null,n,19)},T.toFixed=function(e,n){return _(this,null!=e&&H(e,0,E,20)?~~e+this.e+1:null,n,20)},T.toFormat=function(e,n){var t=_(this,null!=e&&H(e,0,E,21)?~~e+this.e+1:null,n,21);if(this.c){var r,i=t.split("."),o=+X.groupSize,u=+X.secondaryGroupSize,s=X.groupSeparator,f=i[0],l=i[1],c=this.s<0,a=c?f.slice(1):f,h=a.length;if(u&&(r=o,o=u,u=r,h-=r),o>0&&h>0){for(r=h%o||o,f=a.substr(0,r);h>r;r+=o)f+=s+a.substr(r,o);u>0&&(f+=s+a.slice(r)),c&&(f="-"+f)}t=l?f+X.decimalSeparator+((u=+X.fractionGroupSize)?l.replace(new RegExp("\\d{"+u+"}\\B","g"),"$&"+X.fractionGroupSeparator):l):f}return t},T.toFraction=function(e){var n,t,i,o,u,s,f,l,c,h=j,g=this,p=g.c,d=new a(q),m=t=new a(q),w=f=new a(q);if(null!=e&&(j=!1,s=new a(e),j=h,(!(h=s.isInt())||s.lt(q))&&(j&&L(22,"max denominator "+(h?"out of range":"not an integer"),e),e=!h&&s.c&&U(s,s.e+1,1).gte(q)?s:null)),!p)return g.toString();for(c=r(p),o=d.e=c.length-g.e-1,d.c[0]=R[(u=o%y)<0?y+u:u],e=!e||s.cmp(d)>0?o>0?d:m:s,u=z,z=1/0,s=new a(c),f.c[0]=0;l=C(s,d,0,1),i=t.plus(l.times(w)),1!=i.cmp(e);)t=w,w=i,m=f.plus(l.times(i=m)),f=i,d=s.minus(l.times(i=d)),s=i;return i=C(e.minus(t),w,0,1),f=f.plus(i.times(m)),t=t.plus(i.times(w)),f.s=m.s=g.s,o*=2,n=C(m,w,o,k).minus(g).abs().cmp(C(f,t,o,k).minus(g).abs())<1?[m.toString(),w.toString()]:[f.toString(),t.toString()],z=u,n},T.toNumber=function(){var e=this;return+e||(e.s?0*e.s:0/0)},T.toPower=T.pow=function(e){var n,t,r=m(0>e?-e:+e),i=this;if(!H(e,-S,S,23,"exponent")&&(!isFinite(e)||r>S&&(e/=0)||parseFloat(e)!=e&&!(e=0/0)))return new a(Math.pow(+i,e));for(n=J?d(J/y+2):0,t=new a(q);;){if(r%2){if(t=t.times(i),!t.c)break;n&&t.c.length>n&&(t.c.length=n)}if(r=m(r/2),!r)break;i=i.times(i),n&&i.c&&i.c.length>n&&(i.c.length=n)}return 0>e&&(t=q.div(t)),n?U(t,J,k):t},T.toPrecision=function(e,n){return _(this,null!=e&&H(e,1,E,24,"precision")?0|e:null,n,24)},T.toString=function(e){var n,t=this,i=t.s,o=t.e;return null===o?i?(n="Infinity",0>i&&(n="-"+n)):n="NaN":(n=r(t.c),n=null!=e&&H(e,2,64,25,"base")?D(l(n,o),0|e,10,i):B>=o||o>=$?f(n,o):l(n,o),0>i&&t.c[0]&&(n="-"+n)),n},T.truncated=T.trunc=function(){return U(new a(this),this.e+1,1)},T.valueOf=T.toJSON=function(){return this.toString()},null!=e&&a.config(e),a}function t(e){var n=0|e;return e>0||e===n?n:n-1}function r(e){for(var n,t,r=1,i=e.length,o=e[0]+"";i>r;){for(n=e[r++]+"",t=y-n.length;t--;n="0"+n);o+=n}for(i=o.length;48===o.charCodeAt(--i););return o.slice(0,i+1||1)}function i(e,n){var t,r,i=e.c,o=n.c,u=e.s,s=n.s,f=e.e,l=n.e;if(!u||!s)return null;if(t=i&&!i[0],r=o&&!o[0],t||r)return t?r?0:-s:u;if(u!=s)return u;if(t=0>u,r=f==l,!i||!o)return r?0:!i^t?1:-1;if(!r)return f>l^t?1:-1;for(s=(f=i.length)<(l=o.length)?f:l,u=0;s>u;u++)if(i[u]!=o[u])return i[u]>o[u]^t?1:-1;return f==l?0:f>l^t?1:-1}function o(e,n,t){return(e=c(e))>=n&&t>=e}function u(e){return"[object Array]"==Object.prototype.toString.call(e)}function s(e,n,t){for(var r,i,o=[0],u=0,s=e.length;s>u;){for(i=o.length;i--;o[i]*=n);for(o[r=0]+=O.indexOf(e.charAt(u++));r<o.length;r++)o[r]>t-1&&(null==o[r+1]&&(o[r+1]=0),o[r+1]+=o[r]/t|0,o[r]%=t)}return o.reverse()}function f(e,n){return(e.length>1?e.charAt(0)+"."+e.slice(1):e)+(0>n?"e":"e+")+n}function l(e,n){var t,r;if(0>n){for(r="0.";++n;r+="0");e=r+e}else if(t=e.length,++n>t){for(r="0",n-=t;--n;r+="0");e+=r}else t>n&&(e=e.slice(0,n)+"."+e.slice(n));return e}function c(e){return e=parseFloat(e),0>e?d(e):m(e)}var a,h,g,p=/^-?(\d+(\.\d*)?|\.\d+)(e[+-]?\d+)?$/i,d=Math.ceil,m=Math.floor,w=" not a boolean or binary digit",v="rounding mode",b="number type has more than 15 significant digits",O="0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ$_",N=1e14,y=14,S=9007199254740991,R=[1,10,100,1e3,1e4,1e5,1e6,1e7,1e8,1e9,1e10,1e11,1e12,1e13],A=1e7,E=1e9;if(a=n(),"function"==typeof define&&define.amd)define(function(){return a});else if("undefined"!=typeof module&&module.exports){if(module.exports=a,!h)try{h=require("crypto")}catch(D){}}else e.BigNumber=a}(this);
+//# sourceMappingURL=doc/bignumber.js.map \ No newline at end of file
diff --git a/cmd/mist/assets/ext/ethereum.js b/cmd/mist/assets/ext/ethereum.js
new file mode 160000
+Subproject 31e046dbecea51d3b99b21f3e7e60ddfb6c3930
diff --git a/cmd/mist/assets/ext/filter.js b/cmd/mist/assets/ext/filter.js
new file mode 100644
index 000000000..f8529c54b
--- /dev/null
+++ b/cmd/mist/assets/ext/filter.js
@@ -0,0 +1,66 @@
+// Copyright (c) 2013-2014, Jeffrey Wilcke. All rights reserved.
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License, or (at your option) any later version.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// General Public License for more details.
+//
+// You should have received a copy of the GNU General Public License
+// along with this library; if not, write to the Free Software
+// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+// MA 02110-1301 USA
+
+var ethx = {
+ prototype: Object,
+
+ watch: function(options) {
+ return new Filter(options);
+ },
+
+ note: function() {
+ var args = Array.prototype.slice.call(arguments, 0);
+ var o = []
+ for(var i = 0; i < args.length; i++) {
+ o.push(args[i].toString())
+ }
+
+ eth.notef(o);
+ },
+};
+
+var Filter = function(options) {
+ this.callbacks = [];
+ this.options = options;
+
+ if(options === "chain") {
+ this.id = eth.newFilterString(options);
+ } else if(typeof options === "object") {
+ this.id = eth.newFilter(options);
+ }
+};
+
+Filter.prototype.changed = function(callback) {
+ this.callbacks.push(callback);
+
+ var self = this;
+ messages.connect(function(messages, id) {
+ if(id == self.id) {
+ for(var i = 0; i < self.callbacks.length; i++) {
+ self.callbacks[i].call(self, messages);
+ }
+ }
+ });
+};
+
+Filter.prototype.uninstall = function() {
+ eth.uninstallFilter(this.id)
+}
+
+Filter.prototype.messages = function() {
+ return eth.messages(this.id)
+}
diff --git a/cmd/mist/assets/ext/http.js b/cmd/mist/assets/ext/http.js
new file mode 100644
index 000000000..81908266f
--- /dev/null
+++ b/cmd/mist/assets/ext/http.js
@@ -0,0 +1,30 @@
+// Copyright (c) 2013-2014, Jeffrey Wilcke. All rights reserved.
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License, or (at your option) any later version.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// General Public License for more details.
+//
+// You should have received a copy of the GNU General Public License
+// along with this library; if not, write to the Free Software
+// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+// MA 02110-1301 USA
+
+// this function is included locally, but you can also include separately via a header definition
+function request(url, callback) {
+ var xhr = new XMLHttpRequest();
+ xhr.onreadystatechange = (function(req) {
+ return function() {
+ if(req.readyState === 4) {
+ callback(req);
+ }
+ }
+ })(xhr);
+ xhr.open('GET', url, true);
+ xhr.send('');
+}
diff --git a/cmd/mist/assets/ext/mist.js b/cmd/mist/assets/ext/mist.js
new file mode 100644
index 000000000..849e0804e
--- /dev/null
+++ b/cmd/mist/assets/ext/mist.js
@@ -0,0 +1,36 @@
+// Copyright (c) 2015, ETHDEV. All rights reserved.
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License, or (at your option) any later version.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// General Public License for more details.
+//
+// You should have received a copy of the GNU General Public License
+// along with this library; if not, write to the Free Software
+// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+// MA 02110-1301 USA
+
+// this function is included locally, but you can also include separately via a header definition
+
+
+document.onkeydown = function(evt) {
+ // This functions keeps track of keyboard inputs in order to allow copy, paste and other features
+
+ evt = evt || window.event;
+ if (evt.ctrlKey && evt.keyCode == 67) {
+ window.document.execCommand("copy");
+ } else if (evt.ctrlKey && evt.keyCode == 88) {
+ window.document.execCommand("cut");
+ } else if (evt.ctrlKey && evt.keyCode == 86) {
+ window.document.execCommand("paste");
+ } else if (evt.ctrlKey && evt.keyCode == 90) {
+ window.document.execCommand("undo");
+ } else if (evt.ctrlKey && evt.shiftKey && evt.keyCode == 90) {
+ window.document.execCommand("redo");
+ }
+}; \ No newline at end of file
diff --git a/cmd/mist/assets/facet.png b/cmd/mist/assets/facet.png
new file mode 100644
index 000000000..49a266e96
--- /dev/null
+++ b/cmd/mist/assets/facet.png
Binary files differ
diff --git a/cmd/mist/assets/heart.png b/cmd/mist/assets/heart.png
new file mode 100644
index 000000000..3c874ab7f
--- /dev/null
+++ b/cmd/mist/assets/heart.png
Binary files differ
diff --git a/cmd/mist/assets/html/home.html b/cmd/mist/assets/html/home.html
new file mode 100644
index 000000000..dc96cc754
--- /dev/null
+++ b/cmd/mist/assets/html/home.html
@@ -0,0 +1,83 @@
+<!doctype>
+<html>
+<head>
+<title>Ethereum</title>
+<script type="text/javascript" src="../ext/bignumber.min.js"></script>
+<script type="text/javascript" src="../ext/ethereum.js/dist/ethereum.js"></script>
+<style type="text/css">
+ body {
+ font-family: Helvetica;
+ }
+ div.logo {
+ width: 192px;
+ margin: 40px auto;
+ }
+</style>
+</head>
+<body>
+ <div class="logo"><img src="logo.png"></img></div>
+ <h1>Info</h1>
+
+ <table width="100%">
+ <tr>
+ <td>Block number</td>
+ <td id="number"></td>
+ </tr>
+
+ <tr>
+ <td>Peer count</td>
+ <td id="peer_count"></td>
+ </tr>
+
+ <tr>
+ <td>Accounts</td>
+ <td id="accounts"></td>
+ </tr>
+
+ <tr>
+ <td>Gas price</td>
+ <td id="gas_price"></td>
+ </tr>
+
+ <tr>
+ <td>Mining</td>
+ <td id="mining"></td>
+ </tr>
+
+ <tr>
+ <td>Listening</td>
+ <td id="listening"></td>
+ </tr>
+
+ <tr>
+ <td>Coinbase</td>
+ <td id="coinbase"></td>
+ </tr>
+ </table>
+</body>
+
+<script type="text/javascript">
+ var web3 = require('web3');
+ var eth = web3.eth;
+
+ web3.setProvider(new web3.providers.HttpSyncProvider('http://localhost:8545'));
+
+ document.querySelector("#number").innerHTML = eth.number;
+ document.querySelector("#coinbase").innerHTML = eth.coinbase
+ document.querySelector("#peer_count").innerHTML = eth.peerCount;
+ document.querySelector("#accounts").innerHTML = eth.accounts;
+ document.querySelector("#gas_price").innerHTML = eth.gasPrice;
+ document.querySelector("#mining").innerHTML = eth.mining;
+ document.querySelector("#listening").innerHTML = eth.listening;
+
+ eth.watch('pending').changed(function() {
+ console.log("pending changed");
+ });
+ eth.watch('chain').changed(function() {
+ document.querySelector("#number").innerHTML = eth.number;
+ });
+
+</script>
+
+</html>
+
diff --git a/cmd/mist/assets/html/logo.png b/cmd/mist/assets/html/logo.png
new file mode 100644
index 000000000..28dc9f509
--- /dev/null
+++ b/cmd/mist/assets/html/logo.png
Binary files differ
diff --git a/cmd/mist/assets/icecream.png b/cmd/mist/assets/icecream.png
new file mode 100644
index 000000000..2438ca845
--- /dev/null
+++ b/cmd/mist/assets/icecream.png
Binary files differ
diff --git a/cmd/mist/assets/mining-icon.png b/cmd/mist/assets/mining-icon.png
new file mode 100644
index 000000000..db611e5c0
--- /dev/null
+++ b/cmd/mist/assets/mining-icon.png
Binary files differ
diff --git a/cmd/mist/assets/mining-icon@2x.png b/cmd/mist/assets/mining-icon@2x.png
new file mode 100644
index 000000000..16466d338
--- /dev/null
+++ b/cmd/mist/assets/mining-icon@2x.png
Binary files differ
diff --git a/cmd/mist/assets/muted/codemirror.css b/cmd/mist/assets/muted/codemirror.css
new file mode 100644
index 000000000..098a317a2
--- /dev/null
+++ b/cmd/mist/assets/muted/codemirror.css
@@ -0,0 +1,272 @@
+/* BASICS */
+
+.CodeMirror {
+ /* Set height, width, borders, and global font properties here */
+ font-family: monospace;
+ height: 300px;
+}
+.CodeMirror-scroll {
+ /* Set scrolling behaviour here */
+ overflow: auto;
+}
+
+/* PADDING */
+
+.CodeMirror-lines {
+ padding: 4px 0; /* Vertical padding around content */
+}
+.CodeMirror pre {
+ padding: 0 4px; /* Horizontal padding of content */
+}
+
+.CodeMirror-scrollbar-filler, .CodeMirror-gutter-filler {
+ background-color: white; /* The little square between H and V scrollbars */
+}
+
+/* GUTTER */
+
+.CodeMirror-gutters {
+ border-right: 1px solid #ddd;
+ background-color: #f7f7f7;
+ white-space: nowrap;
+}
+.CodeMirror-linenumbers {}
+.CodeMirror-linenumber {
+ padding: 0 3px 0 5px;
+ min-width: 20px;
+ text-align: right;
+ color: #999;
+ -moz-box-sizing: content-box;
+ box-sizing: content-box;
+}
+
+/* CURSOR */
+
+.CodeMirror div.CodeMirror-cursor {
+ border-left: 1px solid black;
+}
+/* Shown when moving in bi-directional text */
+.CodeMirror div.CodeMirror-secondarycursor {
+ border-left: 1px solid silver;
+}
+.CodeMirror.cm-keymap-fat-cursor div.CodeMirror-cursor {
+ width: auto;
+ border: 0;
+ background: #7e7;
+}
+/* Can style cursor different in overwrite (non-insert) mode */
+div.CodeMirror-overwrite div.CodeMirror-cursor {}
+
+.cm-tab { display: inline-block; }
+
+.CodeMirror-ruler {
+ border-left: 1px solid #ccc;
+ position: absolute;
+}
+
+/* DEFAULT THEME */
+
+.cm-s-default .cm-keyword {color: #708;}
+.cm-s-default .cm-atom {color: #219;}
+.cm-s-default .cm-number {color: #164;}
+.cm-s-default .cm-def {color: #00f;}
+.cm-s-default .cm-variable,
+.cm-s-default .cm-punctuation,
+.cm-s-default .cm-property,
+.cm-s-default .cm-operator {}
+.cm-s-default .cm-variable-2 {color: #05a;}
+.cm-s-default .cm-variable-3 {color: #085;}
+.cm-s-default .cm-comment {color: #a50;}
+.cm-s-default .cm-string {color: #a11;}
+.cm-s-default .cm-string-2 {color: #f50;}
+.cm-s-default .cm-meta {color: #555;}
+.cm-s-default .cm-qualifier {color: #555;}
+.cm-s-default .cm-builtin {color: #30a;}
+.cm-s-default .cm-bracket {color: #997;}
+.cm-s-default .cm-tag {color: #170;}
+.cm-s-default .cm-attribute {color: #00c;}
+.cm-s-default .cm-header {color: blue;}
+.cm-s-default .cm-quote {color: #090;}
+.cm-s-default .cm-hr {color: #999;}
+.cm-s-default .cm-link {color: #00c;}
+
+.cm-negative {color: #d44;}
+.cm-positive {color: #292;}
+.cm-header, .cm-strong {font-weight: bold;}
+.cm-em {font-style: italic;}
+.cm-link {text-decoration: underline;}
+
+.cm-s-default .cm-error {color: #f00;}
+.cm-invalidchar {color: #f00;}
+
+div.CodeMirror span.CodeMirror-matchingbracket {color: #0f0;}
+div.CodeMirror span.CodeMirror-nonmatchingbracket {color: #f22;}
+.CodeMirror-activeline-background {background: #e8f2ff;}
+
+/* STOP */
+
+/* The rest of this file contains styles related to the mechanics of
+ the editor. You probably shouldn't touch them. */
+
+.CodeMirror {
+ line-height: 1;
+ position: relative;
+ overflow: hidden;
+ background: white;
+ color: black;
+}
+
+.CodeMirror-scroll {
+ /* 30px is the magic margin used to hide the element's real scrollbars */
+ /* See overflow: hidden in .CodeMirror */
+ margin-bottom: -30px; margin-right: -30px;
+ padding-bottom: 30px;
+ height: 100%;
+ outline: none; /* Prevent dragging from highlighting the element */
+ position: relative;
+ -moz-box-sizing: content-box;
+ box-sizing: content-box;
+}
+.CodeMirror-sizer {
+ position: relative;
+ border-right: 30px solid transparent;
+ -moz-box-sizing: content-box;
+ box-sizing: content-box;
+}
+
+/* The fake, visible scrollbars. Used to force redraw during scrolling
+ before actuall scrolling happens, thus preventing shaking and
+ flickering artifacts. */
+.CodeMirror-vscrollbar, .CodeMirror-hscrollbar, .CodeMirror-scrollbar-filler, .CodeMirror-gutter-filler {
+ position: absolute;
+ z-index: 6;
+ display: none;
+}
+.CodeMirror-vscrollbar {
+ right: 0; top: 0;
+ overflow-x: hidden;
+ overflow-y: scroll;
+}
+.CodeMirror-hscrollbar {
+ bottom: 0; left: 0;
+ overflow-y: hidden;
+ overflow-x: scroll;
+}
+.CodeMirror-scrollbar-filler {
+ right: 0; bottom: 0;
+}
+.CodeMirror-gutter-filler {
+ left: 0; bottom: 0;
+}
+
+.CodeMirror-gutters {
+ position: absolute; left: 0; top: 0;
+ padding-bottom: 30px;
+ z-index: 3;
+}
+.CodeMirror-gutter {
+ white-space: normal;
+ height: 100%;
+ -moz-box-sizing: content-box;
+ box-sizing: content-box;
+ padding-bottom: 30px;
+ margin-bottom: -32px;
+ display: inline-block;
+ /* Hack to make IE7 behave */
+ *zoom:1;
+ *display:inline;
+}
+.CodeMirror-gutter-elt {
+ position: absolute;
+ cursor: default;
+ z-index: 4;
+}
+
+.CodeMirror-lines {
+ cursor: text;
+}
+.CodeMirror pre {
+ /* Reset some styles that the rest of the page might have set */
+ -moz-border-radius: 0; -webkit-border-radius: 0; border-radius: 0;
+ border-width: 0;
+ background: transparent;
+ font-family: inherit;
+ font-size: inherit;
+ margin: 0;
+ white-space: pre;
+ word-wrap: normal;
+ line-height: inherit;
+ color: inherit;
+ z-index: 2;
+ position: relative;
+ overflow: visible;
+}
+.CodeMirror-wrap pre {
+ word-wrap: break-word;
+ white-space: pre-wrap;
+ word-break: normal;
+}
+
+.CodeMirror-linebackground {
+ position: absolute;
+ left: 0; right: 0; top: 0; bottom: 0;
+ z-index: 0;
+}
+
+.CodeMirror-linewidget {
+ position: relative;
+ z-index: 2;
+ overflow: auto;
+}
+
+.CodeMirror-widget {}
+
+.CodeMirror-wrap .CodeMirror-scroll {
+ overflow-x: hidden;
+}
+
+.CodeMirror-measure {
+ position: absolute;
+ width: 100%;
+ height: 0;
+ overflow: hidden;
+ visibility: hidden;
+}
+.CodeMirror-measure pre { position: static; }
+
+.CodeMirror div.CodeMirror-cursor {
+ position: absolute;
+ border-right: none;
+ width: 0;
+}
+
+div.CodeMirror-cursors {
+ visibility: hidden;
+ position: relative;
+ z-index: 1;
+}
+.CodeMirror-focused div.CodeMirror-cursors {
+ visibility: visible;
+}
+
+.CodeMirror-selected { background: #d9d9d9; }
+.CodeMirror-focused .CodeMirror-selected { background: #d7d4f0; }
+.CodeMirror-crosshair { cursor: crosshair; }
+
+.cm-searching {
+ background: #ffa;
+ background: rgba(255, 255, 0, .4);
+}
+
+/* IE7 hack to prevent it from returning funny offsetTops on the spans */
+.CodeMirror span { *vertical-align: text-bottom; }
+
+/* Used to force a border model for a node */
+.cm-force-border { padding-right: .1px; }
+
+@media print {
+ /* Hide the cursor when printing */
+ .CodeMirror div.CodeMirror-cursors {
+ visibility: hidden;
+ }
+}
diff --git a/cmd/mist/assets/muted/debugger.html b/cmd/mist/assets/muted/debugger.html
new file mode 100644
index 000000000..b7552f030
--- /dev/null
+++ b/cmd/mist/assets/muted/debugger.html
@@ -0,0 +1,53 @@
+<!doctype>
+<html>
+<head>
+<style type="text/css">
+ html, body {
+ margin: 0; padding: 0;
+ min-height: 100%;
+ }
+
+ #debugger {
+ height: 100%;
+ font-family: "Monaco"
+ }
+ #debugger .line {
+ overflow: none;
+ }
+ #debugger .col1, #debugger .col2 {
+ float: left;
+ padding: 3px;
+ }
+ #debugger .col1 {
+ width: 10px;
+ padding-left: 10px
+ -webkit-touch-callout: none;
+ -webkit-user-select: none;
+ -khtml-user-select: none;
+ -moz-user-select: none;
+ -ms-user-select: none;
+ user-select: none;
+ }
+ #debugger .col2 {
+ width: 90%;
+ }
+ .prompt {
+ color: "#5089D4";
+ }
+</style>
+
+</head>
+
+<body>
+<div id="debugger">
+ <div class="line">
+ <div class="col1 prompt">
+ &gt;
+ </div>
+ <div class="col2" contenteditable>
+ </div>
+ </div>
+</div>
+
+</body>
+</html>
diff --git a/cmd/mist/assets/muted/eclipse.css b/cmd/mist/assets/muted/eclipse.css
new file mode 100644
index 000000000..317218e3d
--- /dev/null
+++ b/cmd/mist/assets/muted/eclipse.css
@@ -0,0 +1,23 @@
+.cm-s-eclipse span.cm-meta {color: #FF1717;}
+.cm-s-eclipse span.cm-keyword { line-height: 1em; font-weight: bold; color: #7F0055; }
+.cm-s-eclipse span.cm-atom {color: #219;}
+.cm-s-eclipse span.cm-number {color: #164;}
+.cm-s-eclipse span.cm-def {color: #00f;}
+.cm-s-eclipse span.cm-variable {color: black;}
+.cm-s-eclipse span.cm-variable-2 {color: #0000C0;}
+.cm-s-eclipse span.cm-variable-3 {color: #0000C0;}
+.cm-s-eclipse span.cm-property {color: black;}
+.cm-s-eclipse span.cm-operator {color: black;}
+.cm-s-eclipse span.cm-comment {color: #3F7F5F;}
+.cm-s-eclipse span.cm-string {color: #2A00FF;}
+.cm-s-eclipse span.cm-string-2 {color: #f50;}
+.cm-s-eclipse span.cm-qualifier {color: #555;}
+.cm-s-eclipse span.cm-builtin {color: #30a;}
+.cm-s-eclipse span.cm-bracket {color: #cc7;}
+.cm-s-eclipse span.cm-tag {color: #170;}
+.cm-s-eclipse span.cm-attribute {color: #00c;}
+.cm-s-eclipse span.cm-link {color: #219;}
+.cm-s-eclipse span.cm-error {color: #f00;}
+
+.cm-s-eclipse .CodeMirror-activeline-background {background: #e8f2ff !important;}
+.cm-s-eclipse .CodeMirror-matchingbracket {outline:1px solid grey; color:black !important;}
diff --git a/cmd/mist/assets/muted/index.html b/cmd/mist/assets/muted/index.html
new file mode 100644
index 000000000..14949b5ac
--- /dev/null
+++ b/cmd/mist/assets/muted/index.html
@@ -0,0 +1,80 @@
+<!doctype>
+<html>
+<head>
+<title>Mutan Editor</title>
+<link rel="stylesheet" href="codemirror.css">
+<link rel="stylesheet" href="eclipse.css">
+<script src="lib/codemirror.js"></script>
+<script src="lib/matchbrackets.js"></script>
+<script src="lib/go.js"></script>
+<script src="muted.js"></script>
+
+<style type="text/css">
+ html, body {
+ margin: 0; padding: 0;
+ min-height: 100%;
+ }
+
+ #debugger {
+ height: 30%;
+ font-family: "Monaco";
+ border-top: 5px solid grey;
+ }
+ #debugger .line {
+ overflow: none;
+ }
+ #debugger .col1, #debugger .col2 {
+ float: left;
+ padding: 3px;
+ }
+ #debugger .col1 {
+ width: 10px;
+ padding-left: 10px
+ -webkit-touch-callout: none;
+ -webkit-user-select: none;
+ -khtml-user-select: none;
+ -moz-user-select: none;
+ -ms-user-select: none;
+ user-select: none;
+ }
+ #debugger .col2 {
+ width: 90%;
+ }
+ .prompt {
+ color: "#5089D4";
+ }
+
+ .CodeMirror {
+ height: 70%;
+ font-size: 14pt;
+ }
+</style>
+</head>
+
+<body>
+<textarea id="editor"></textarea>
+
+<div id="debugger">
+ <div class="line">
+ <div class="col1 prompt">
+ &gt;
+ </div>
+ <div class="col2" contenteditable>
+ </div>
+ </div>
+</div>
+
+<script>
+ var textArea = document.querySelector("#editor")
+ var editor = CodeMirror.fromTextArea(textArea, {
+ theme: "eclipse",
+ mode: "text/html",
+ lineNumbers: true,
+ mode: "text/x-go",
+ indentUnit: 8,
+ tabSize: 8,
+ indentWithTabs: true,
+ });
+</script>
+</body>
+</html>
diff --git a/cmd/mist/assets/muted/lib/codemirror.js b/cmd/mist/assets/muted/lib/codemirror.js
new file mode 100644
index 000000000..0ab217711
--- /dev/null
+++ b/cmd/mist/assets/muted/lib/codemirror.js
@@ -0,0 +1,7526 @@
+// This is CodeMirror (http://codemirror.net), a code editor
+// implemented in JavaScript on top of the browser's DOM.
+//
+// You can find some technical background for some of the code below
+// at http://marijnhaverbeke.nl/blog/#cm-internals .
+
+(function(mod) {
+ if (typeof exports == "object" && typeof module == "object") // CommonJS
+ module.exports = mod();
+ else if (typeof define == "function" && define.amd) // AMD
+ return define([], mod);
+ else // Plain browser env
+ this.CodeMirror = mod();
+})(function() {
+ "use strict";
+
+ // BROWSER SNIFFING
+
+ // Kludges for bugs and behavior differences that can't be feature
+ // detected are enabled based on userAgent etc sniffing.
+
+ var gecko = /gecko\/\d/i.test(navigator.userAgent);
+ // ie_uptoN means Internet Explorer version N or lower
+ var ie_upto10 = /MSIE \d/.test(navigator.userAgent);
+ var ie_upto7 = ie_upto10 && (document.documentMode == null || document.documentMode < 8);
+ var ie_upto8 = ie_upto10 && (document.documentMode == null || document.documentMode < 9);
+ var ie_upto9 = ie_upto10 && (document.documentMode == null || document.documentMode < 10);
+ var ie_11up = /Trident\/([7-9]|\d{2,})\./.test(navigator.userAgent);
+ var ie = ie_upto10 || ie_11up;
+ var webkit = /WebKit\//.test(navigator.userAgent);
+ var qtwebkit = webkit && /Qt\/\d+\.\d+/.test(navigator.userAgent);
+ var chrome = /Chrome\//.test(navigator.userAgent);
+ var presto = /Opera\//.test(navigator.userAgent);
+ var safari = /Apple Computer/.test(navigator.vendor);
+ var khtml = /KHTML\//.test(navigator.userAgent);
+ var mac_geMountainLion = /Mac OS X 1\d\D([8-9]|\d\d)\D/.test(navigator.userAgent);
+ var phantom = /PhantomJS/.test(navigator.userAgent);
+
+ var ios = /AppleWebKit/.test(navigator.userAgent) && /Mobile\/\w+/.test(navigator.userAgent);
+ // This is woefully incomplete. Suggestions for alternative methods welcome.
+ var mobile = ios || /Android|webOS|BlackBerry|Opera Mini|Opera Mobi|IEMobile/i.test(navigator.userAgent);
+ var mac = ios || /Mac/.test(navigator.platform);
+ var windows = /win/i.test(navigator.platform);
+
+ var presto_version = presto && navigator.userAgent.match(/Version\/(\d*\.\d*)/);
+ if (presto_version) presto_version = Number(presto_version[1]);
+ if (presto_version && presto_version >= 15) { presto = false; webkit = true; }
+ // Some browsers use the wrong event properties to signal cmd/ctrl on OS X
+ var flipCtrlCmd = mac && (qtwebkit || presto && (presto_version == null || presto_version < 12.11));
+ var captureRightClick = gecko || (ie && !ie_upto8);
+
+ // Optimize some code when these features are not used.
+ var sawReadOnlySpans = false, sawCollapsedSpans = false;
+
+ // EDITOR CONSTRUCTOR
+
+ // A CodeMirror instance represents an editor. This is the object
+ // that user code is usually dealing with.
+
+ function CodeMirror(place, options) {
+ if (!(this instanceof CodeMirror)) return new CodeMirror(place, options);
+
+ this.options = options = options || {};
+ // Determine effective options based on given values and defaults.
+ copyObj(defaults, options, false);
+ setGuttersForLineNumbers(options);
+
+ var doc = options.value;
+ if (typeof doc == "string") doc = new Doc(doc, options.mode);
+ this.doc = doc;
+
+ var display = this.display = new Display(place, doc);
+ display.wrapper.CodeMirror = this;
+ updateGutters(this);
+ themeChanged(this);
+ if (options.lineWrapping)
+ this.display.wrapper.className += " CodeMirror-wrap";
+ if (options.autofocus && !mobile) focusInput(this);
+
+ this.state = {
+ keyMaps: [], // stores maps added by addKeyMap
+ overlays: [], // highlighting overlays, as added by addOverlay
+ modeGen: 0, // bumped when mode/overlay changes, used to invalidate highlighting info
+ overwrite: false, focused: false,
+ suppressEdits: false, // used to disable editing during key handlers when in readOnly mode
+ pasteIncoming: false, cutIncoming: false, // help recognize paste/cut edits in readInput
+ draggingText: false,
+ highlight: new Delayed() // stores highlight worker timeout
+ };
+
+ // Override magic textarea content restore that IE sometimes does
+ // on our hidden textarea on reload
+ if (ie_upto10) setTimeout(bind(resetInput, this, true), 20);
+
+ registerEventHandlers(this);
+
+ var cm = this;
+ runInOp(this, function() {
+ cm.curOp.forceUpdate = true;
+ attachDoc(cm, doc);
+
+ if ((options.autofocus && !mobile) || activeElt() == display.input)
+ setTimeout(bind(onFocus, cm), 20);
+ else
+ onBlur(cm);
+
+ for (var opt in optionHandlers) if (optionHandlers.hasOwnProperty(opt))
+ optionHandlers[opt](cm, options[opt], Init);
+ for (var i = 0; i < initHooks.length; ++i) initHooks[i](cm);
+ });
+ }
+
+ // DISPLAY CONSTRUCTOR
+
+ // The display handles the DOM integration, both for input reading
+ // and content drawing. It holds references to DOM nodes and
+ // display-related state.
+
+ function Display(place, doc) {
+ var d = this;
+
+ // The semihidden textarea that is focused when the editor is
+ // focused, and receives input.
+ var input = d.input = elt("textarea", null, null, "position: absolute; padding: 0; width: 1px; height: 1em; outline: none");
+ // The textarea is kept positioned near the cursor to prevent the
+ // fact that it'll be scrolled into view on input from scrolling
+ // our fake cursor out of view. On webkit, when wrap=off, paste is
+ // very slow. So make the area wide instead.
+ if (webkit) input.style.width = "1000px";
+ else input.setAttribute("wrap", "off");
+ // If border: 0; -- iOS fails to open keyboard (issue #1287)
+ if (ios) input.style.border = "1px solid black";
+ input.setAttribute("autocorrect", "off"); input.setAttribute("autocapitalize", "off"); input.setAttribute("spellcheck", "false");
+
+ // Wraps and hides input textarea
+ d.inputDiv = elt("div", [input], null, "overflow: hidden; position: relative; width: 3px; height: 0px;");
+ // The fake scrollbar elements.
+ d.scrollbarH = elt("div", [elt("div", null, null, "height: 100%; min-height: 1px")], "CodeMirror-hscrollbar");
+ d.scrollbarV = elt("div", [elt("div", null, null, "min-width: 1px")], "CodeMirror-vscrollbar");
+ // Covers bottom-right square when both scrollbars are present.
+ d.scrollbarFiller = elt("div", null, "CodeMirror-scrollbar-filler");
+ // Covers bottom of gutter when coverGutterNextToScrollbar is on
+ // and h scrollbar is present.
+ d.gutterFiller = elt("div", null, "CodeMirror-gutter-filler");
+ // Will contain the actual code, positioned to cover the viewport.
+ d.lineDiv = elt("div", null, "CodeMirror-code");
+ // Elements are added to these to represent selection and cursors.
+ d.selectionDiv = elt("div", null, null, "position: relative; z-index: 1");
+ d.cursorDiv = elt("div", null, "CodeMirror-cursors");
+ // A visibility: hidden element used to find the size of things.
+ d.measure = elt("div", null, "CodeMirror-measure");
+ // When lines outside of the viewport are measured, they are drawn in this.
+ d.lineMeasure = elt("div", null, "CodeMirror-measure");
+ // Wraps everything that needs to exist inside the vertically-padded coordinate system
+ d.lineSpace = elt("div", [d.measure, d.lineMeasure, d.selectionDiv, d.cursorDiv, d.lineDiv],
+ null, "position: relative; outline: none");
+ // Moved around its parent to cover visible view.
+ d.mover = elt("div", [elt("div", [d.lineSpace], "CodeMirror-lines")], null, "position: relative");
+ // Set to the height of the document, allowing scrolling.
+ d.sizer = elt("div", [d.mover], "CodeMirror-sizer");
+ // Behavior of elts with overflow: auto and padding is
+ // inconsistent across browsers. This is used to ensure the
+ // scrollable area is big enough.
+ d.heightForcer = elt("div", null, null, "position: absolute; height: " + scrollerCutOff + "px; width: 1px;");
+ // Will contain the gutters, if any.
+ d.gutters = elt("div", null, "CodeMirror-gutters");
+ d.lineGutter = null;
+ // Actual scrollable element.
+ d.scroller = elt("div", [d.sizer, d.heightForcer, d.gutters], "CodeMirror-scroll");
+ d.scroller.setAttribute("tabIndex", "-1");
+ // The element in which the editor lives.
+ d.wrapper = elt("div", [d.inputDiv, d.scrollbarH, d.scrollbarV,
+ d.scrollbarFiller, d.gutterFiller, d.scroller], "CodeMirror");
+
+ // Work around IE7 z-index bug (not perfect, hence IE7 not really being supported)
+ if (ie_upto7) { d.gutters.style.zIndex = -1; d.scroller.style.paddingRight = 0; }
+ // Needed to hide big blue blinking cursor on Mobile Safari
+ if (ios) input.style.width = "0px";
+ if (!webkit) d.scroller.draggable = true;
+ // Needed to handle Tab key in KHTML
+ if (khtml) { d.inputDiv.style.height = "1px"; d.inputDiv.style.position = "absolute"; }
+ // Need to set a minimum width to see the scrollbar on IE7 (but must not set it on IE8).
+ if (ie_upto7) d.scrollbarH.style.minHeight = d.scrollbarV.style.minWidth = "18px";
+
+ if (place.appendChild) place.appendChild(d.wrapper);
+ else place(d.wrapper);
+
+ // Current rendered range (may be bigger than the view window).
+ d.viewFrom = d.viewTo = doc.first;
+ // Information about the rendered lines.
+ d.view = [];
+ // Holds info about a single rendered line when it was rendered
+ // for measurement, while not in view.
+ d.externalMeasured = null;
+ // Empty space (in pixels) above the view
+ d.viewOffset = 0;
+ d.lastSizeC = 0;
+ d.updateLineNumbers = null;
+
+ // Used to only resize the line number gutter when necessary (when
+ // the amount of lines crosses a boundary that makes its width change)
+ d.lineNumWidth = d.lineNumInnerWidth = d.lineNumChars = null;
+ // See readInput and resetInput
+ d.prevInput = "";
+ // Set to true when a non-horizontal-scrolling line widget is
+ // added. As an optimization, line widget aligning is skipped when
+ // this is false.
+ d.alignWidgets = false;
+ // Flag that indicates whether we expect input to appear real soon
+ // now (after some event like 'keypress' or 'input') and are
+ // polling intensively.
+ d.pollingFast = false;
+ // Self-resetting timeout for the poller
+ d.poll = new Delayed();
+
+ d.cachedCharWidth = d.cachedTextHeight = d.cachedPaddingH = null;
+
+ // Tracks when resetInput has punted to just putting a short
+ // string into the textarea instead of the full selection.
+ d.inaccurateSelection = false;
+
+ // Tracks the maximum line length so that the horizontal scrollbar
+ // can be kept static when scrolling.
+ d.maxLine = null;
+ d.maxLineLength = 0;
+ d.maxLineChanged = false;
+
+ // Used for measuring wheel scrolling granularity
+ d.wheelDX = d.wheelDY = d.wheelStartX = d.wheelStartY = null;
+
+ // True when shift is held down.
+ d.shift = false;
+ }
+
+ // STATE UPDATES
+
+ // Used to get the editor into a consistent state again when options change.
+
+ function loadMode(cm) {
+ cm.doc.mode = CodeMirror.getMode(cm.options, cm.doc.modeOption);
+ resetModeState(cm);
+ }
+
+ function resetModeState(cm) {
+ cm.doc.iter(function(line) {
+ if (line.stateAfter) line.stateAfter = null;
+ if (line.styles) line.styles = null;
+ });
+ cm.doc.frontier = cm.doc.first;
+ startWorker(cm, 100);
+ cm.state.modeGen++;
+ if (cm.curOp) regChange(cm);
+ }
+
+ function wrappingChanged(cm) {
+ if (cm.options.lineWrapping) {
+ addClass(cm.display.wrapper, "CodeMirror-wrap");
+ cm.display.sizer.style.minWidth = "";
+ } else {
+ rmClass(cm.display.wrapper, "CodeMirror-wrap");
+ findMaxLine(cm);
+ }
+ estimateLineHeights(cm);
+ regChange(cm);
+ clearCaches(cm);
+ setTimeout(function(){updateScrollbars(cm);}, 100);
+ }
+
+ // Returns a function that estimates the height of a line, to use as
+ // first approximation until the line becomes visible (and is thus
+ // properly measurable).
+ function estimateHeight(cm) {
+ var th = textHeight(cm.display), wrapping = cm.options.lineWrapping;
+ var perLine = wrapping && Math.max(5, cm.display.scroller.clientWidth / charWidth(cm.display) - 3);
+ return function(line) {
+ if (lineIsHidden(cm.doc, line)) return 0;
+
+ var widgetsHeight = 0;
+ if (line.widgets) for (var i = 0; i < line.widgets.length; i++) {
+ if (line.widgets[i].height) widgetsHeight += line.widgets[i].height;
+ }
+
+ if (wrapping)
+ return widgetsHeight + (Math.ceil(line.text.length / perLine) || 1) * th;
+ else
+ return widgetsHeight + th;
+ };
+ }
+
+ function estimateLineHeights(cm) {
+ var doc = cm.doc, est = estimateHeight(cm);
+ doc.iter(function(line) {
+ var estHeight = est(line);
+ if (estHeight != line.height) updateLineHeight(line, estHeight);
+ });
+ }
+
+ function keyMapChanged(cm) {
+ var map = keyMap[cm.options.keyMap], style = map.style;
+ cm.display.wrapper.className = cm.display.wrapper.className.replace(/\s*cm-keymap-\S+/g, "") +
+ (style ? " cm-keymap-" + style : "");
+ }
+
+ function themeChanged(cm) {
+ cm.display.wrapper.className = cm.display.wrapper.className.replace(/\s*cm-s-\S+/g, "") +
+ cm.options.theme.replace(/(^|\s)\s*/g, " cm-s-");
+ clearCaches(cm);
+ }
+
+ function guttersChanged(cm) {
+ updateGutters(cm);
+ regChange(cm);
+ setTimeout(function(){alignHorizontally(cm);}, 20);
+ }
+
+ // Rebuild the gutter elements, ensure the margin to the left of the
+ // code matches their width.
+ function updateGutters(cm) {
+ var gutters = cm.display.gutters, specs = cm.options.gutters;
+ removeChildren(gutters);
+ for (var i = 0; i < specs.length; ++i) {
+ var gutterClass = specs[i];
+ var gElt = gutters.appendChild(elt("div", null, "CodeMirror-gutter " + gutterClass));
+ if (gutterClass == "CodeMirror-linenumbers") {
+ cm.display.lineGutter = gElt;
+ gElt.style.width = (cm.display.lineNumWidth || 1) + "px";
+ }
+ }
+ gutters.style.display = i ? "" : "none";
+ updateGutterSpace(cm);
+ }
+
+ function updateGutterSpace(cm) {
+ var width = cm.display.gutters.offsetWidth;
+ cm.display.sizer.style.marginLeft = width + "px";
+ cm.display.scrollbarH.style.left = cm.options.fixedGutter ? width + "px" : 0;
+ }
+
+ // Compute the character length of a line, taking into account
+ // collapsed ranges (see markText) that might hide parts, and join
+ // other lines onto it.
+ function lineLength(line) {
+ if (line.height == 0) return 0;
+ var len = line.text.length, merged, cur = line;
+ while (merged = collapsedSpanAtStart(cur)) {
+ var found = merged.find(0, true);
+ cur = found.from.line;
+ len += found.from.ch - found.to.ch;
+ }
+ cur = line;
+ while (merged = collapsedSpanAtEnd(cur)) {
+ var found = merged.find(0, true);
+ len -= cur.text.length - found.from.ch;
+ cur = found.to.line;
+ len += cur.text.length - found.to.ch;
+ }
+ return len;
+ }
+
+ // Find the longest line in the document.
+ function findMaxLine(cm) {
+ var d = cm.display, doc = cm.doc;
+ d.maxLine = getLine(doc, doc.first);
+ d.maxLineLength = lineLength(d.maxLine);
+ d.maxLineChanged = true;
+ doc.iter(function(line) {
+ var len = lineLength(line);
+ if (len > d.maxLineLength) {
+ d.maxLineLength = len;
+ d.maxLine = line;
+ }
+ });
+ }
+
+ // Make sure the gutters options contains the element
+ // "CodeMirror-linenumbers" when the lineNumbers option is true.
+ function setGuttersForLineNumbers(options) {
+ var found = indexOf(options.gutters, "CodeMirror-linenumbers");
+ if (found == -1 && options.lineNumbers) {
+ options.gutters = options.gutters.concat(["CodeMirror-linenumbers"]);
+ } else if (found > -1 && !options.lineNumbers) {
+ options.gutters = options.gutters.slice(0);
+ options.gutters.splice(found, 1);
+ }
+ }
+
+ // SCROLLBARS
+
+ // Prepare DOM reads needed to update the scrollbars. Done in one
+ // shot to minimize update/measure roundtrips.
+ function measureForScrollbars(cm) {
+ var scroll = cm.display.scroller;
+ return {
+ clientHeight: scroll.clientHeight,
+ barHeight: cm.display.scrollbarV.clientHeight,
+ scrollWidth: scroll.scrollWidth, clientWidth: scroll.clientWidth,
+ barWidth: cm.display.scrollbarH.clientWidth,
+ docHeight: Math.round(cm.doc.height + paddingVert(cm.display))
+ };
+ }
+
+ // Re-synchronize the fake scrollbars with the actual size of the
+ // content.
+ function updateScrollbars(cm, measure) {
+ if (!measure) measure = measureForScrollbars(cm);
+ var d = cm.display;
+ var scrollHeight = measure.docHeight + scrollerCutOff;
+ var needsH = measure.scrollWidth > measure.clientWidth;
+ var needsV = scrollHeight > measure.clientHeight;
+ if (needsV) {
+ d.scrollbarV.style.display = "block";
+ d.scrollbarV.style.bottom = needsH ? scrollbarWidth(d.measure) + "px" : "0";
+ // A bug in IE8 can cause this value to be negative, so guard it.
+ d.scrollbarV.firstChild.style.height =
+ Math.max(0, scrollHeight - measure.clientHeight + (measure.barHeight || d.scrollbarV.clientHeight)) + "px";
+ } else {
+ d.scrollbarV.style.display = "";
+ d.scrollbarV.firstChild.style.height = "0";
+ }
+ if (needsH) {
+ d.scrollbarH.style.display = "block";
+ d.scrollbarH.style.right = needsV ? scrollbarWidth(d.measure) + "px" : "0";
+ d.scrollbarH.firstChild.style.width =
+ (measure.scrollWidth - measure.clientWidth + (measure.barWidth || d.scrollbarH.clientWidth)) + "px";
+ } else {
+ d.scrollbarH.style.display = "";
+ d.scrollbarH.firstChild.style.width = "0";
+ }
+ if (needsH && needsV) {
+ d.scrollbarFiller.style.display = "block";
+ d.scrollbarFiller.style.height = d.scrollbarFiller.style.width = scrollbarWidth(d.measure) + "px";
+ } else d.scrollbarFiller.style.display = "";
+ if (needsH && cm.options.coverGutterNextToScrollbar && cm.options.fixedGutter) {
+ d.gutterFiller.style.display = "block";
+ d.gutterFiller.style.height = scrollbarWidth(d.measure) + "px";
+ d.gutterFiller.style.width = d.gutters.offsetWidth + "px";
+ } else d.gutterFiller.style.display = "";
+
+ if (!cm.state.checkedOverlayScrollbar && measure.clientHeight > 0) {
+ if (scrollbarWidth(d.measure) === 0) {
+ var w = mac && !mac_geMountainLion ? "12px" : "18px";
+ d.scrollbarV.style.minWidth = d.scrollbarH.style.minHeight = w;
+ var barMouseDown = function(e) {
+ if (e_target(e) != d.scrollbarV && e_target(e) != d.scrollbarH)
+ operation(cm, onMouseDown)(e);
+ };
+ on(d.scrollbarV, "mousedown", barMouseDown);
+ on(d.scrollbarH, "mousedown", barMouseDown);
+ }
+ cm.state.checkedOverlayScrollbar = true;
+ }
+ }
+
+ // Compute the lines that are visible in a given viewport (defaults
+ // the the current scroll position). viewPort may contain top,
+ // height, and ensure (see op.scrollToPos) properties.
+ function visibleLines(display, doc, viewPort) {
+ var top = viewPort && viewPort.top != null ? viewPort.top : display.scroller.scrollTop;
+ top = Math.floor(top - paddingTop(display));
+ var bottom = viewPort && viewPort.bottom != null ? viewPort.bottom : top + display.wrapper.clientHeight;
+
+ var from = lineAtHeight(doc, top), to = lineAtHeight(doc, bottom);
+ // Ensure is a {from: {line, ch}, to: {line, ch}} object, and
+ // forces those lines into the viewport (if possible).
+ if (viewPort && viewPort.ensure) {
+ var ensureFrom = viewPort.ensure.from.line, ensureTo = viewPort.ensure.to.line;
+ if (ensureFrom < from)
+ return {from: ensureFrom,
+ to: lineAtHeight(doc, heightAtLine(getLine(doc, ensureFrom)) + display.wrapper.clientHeight)};
+ if (Math.min(ensureTo, doc.lastLine()) >= to)
+ return {from: lineAtHeight(doc, heightAtLine(getLine(doc, ensureTo)) - display.wrapper.clientHeight),
+ to: ensureTo};
+ }
+ return {from: from, to: to};
+ }
+
+ // LINE NUMBERS
+
+ // Re-align line numbers and gutter marks to compensate for
+ // horizontal scrolling.
+ function alignHorizontally(cm) {
+ var display = cm.display, view = display.view;
+ if (!display.alignWidgets && (!display.gutters.firstChild || !cm.options.fixedGutter)) return;
+ var comp = compensateForHScroll(display) - display.scroller.scrollLeft + cm.doc.scrollLeft;
+ var gutterW = display.gutters.offsetWidth, left = comp + "px";
+ for (var i = 0; i < view.length; i++) if (!view[i].hidden) {
+ if (cm.options.fixedGutter && view[i].gutter)
+ view[i].gutter.style.left = left;
+ var align = view[i].alignable;
+ if (align) for (var j = 0; j < align.length; j++)
+ align[j].style.left = left;
+ }
+ if (cm.options.fixedGutter)
+ display.gutters.style.left = (comp + gutterW) + "px";
+ }
+
+ // Used to ensure that the line number gutter is still the right
+ // size for the current document size. Returns true when an update
+ // is needed.
+ function maybeUpdateLineNumberWidth(cm) {
+ if (!cm.options.lineNumbers) return false;
+ var doc = cm.doc, last = lineNumberFor(cm.options, doc.first + doc.size - 1), display = cm.display;
+ if (last.length != display.lineNumChars) {
+ var test = display.measure.appendChild(elt("div", [elt("div", last)],
+ "CodeMirror-linenumber CodeMirror-gutter-elt"));
+ var innerW = test.firstChild.offsetWidth, padding = test.offsetWidth - innerW;
+ display.lineGutter.style.width = "";
+ display.lineNumInnerWidth = Math.max(innerW, display.lineGutter.offsetWidth - padding);
+ display.lineNumWidth = display.lineNumInnerWidth + padding;
+ display.lineNumChars = display.lineNumInnerWidth ? last.length : -1;
+ display.lineGutter.style.width = display.lineNumWidth + "px";
+ updateGutterSpace(cm);
+ return true;
+ }
+ return false;
+ }
+
+ function lineNumberFor(options, i) {
+ return String(options.lineNumberFormatter(i + options.firstLineNumber));
+ }
+
+ // Computes display.scroller.scrollLeft + display.gutters.offsetWidth,
+ // but using getBoundingClientRect to get a sub-pixel-accurate
+ // result.
+ function compensateForHScroll(display) {
+ return display.scroller.getBoundingClientRect().left - display.sizer.getBoundingClientRect().left;
+ }
+
+ // DISPLAY DRAWING
+
+ // Updates the display, selection, and scrollbars, using the
+ // information in display.view to find out which nodes are no longer
+ // up-to-date. Tries to bail out early when no changes are needed,
+ // unless forced is true.
+ // Returns true if an actual update happened, false otherwise.
+ function updateDisplay(cm, viewPort, forced) {
+ var oldFrom = cm.display.viewFrom, oldTo = cm.display.viewTo, updated;
+ var visible = visibleLines(cm.display, cm.doc, viewPort);
+ for (var first = true;; first = false) {
+ var oldWidth = cm.display.scroller.clientWidth;
+ if (!updateDisplayInner(cm, visible, forced)) break;
+ updated = true;
+
+ // If the max line changed since it was last measured, measure it,
+ // and ensure the document's width matches it.
+ if (cm.display.maxLineChanged && !cm.options.lineWrapping)
+ adjustContentWidth(cm);
+
+ var barMeasure = measureForScrollbars(cm);
+ updateSelection(cm);
+ setDocumentHeight(cm, barMeasure);
+ updateScrollbars(cm, barMeasure);
+ if (webkit && cm.options.lineWrapping)
+ checkForWebkitWidthBug(cm, barMeasure); // (Issue #2420)
+ if (first && cm.options.lineWrapping && oldWidth != cm.display.scroller.clientWidth) {
+ forced = true;
+ continue;
+ }
+ forced = false;
+
+ // Clip forced viewport to actual scrollable area.
+ if (viewPort && viewPort.top != null)
+ viewPort = {top: Math.min(barMeasure.docHeight - scrollerCutOff - barMeasure.clientHeight, viewPort.top)};
+ // Updated line heights might result in the drawn area not
+ // actually covering the viewport. Keep looping until it does.
+ visible = visibleLines(cm.display, cm.doc, viewPort);
+ if (visible.from >= cm.display.viewFrom && visible.to <= cm.display.viewTo)
+ break;
+ }
+
+ cm.display.updateLineNumbers = null;
+ if (updated) {
+ signalLater(cm, "update", cm);
+ if (cm.display.viewFrom != oldFrom || cm.display.viewTo != oldTo)
+ signalLater(cm, "viewportChange", cm, cm.display.viewFrom, cm.display.viewTo);
+ }
+ return updated;
+ }
+
+ // Does the actual updating of the line display. Bails out
+ // (returning false) when there is nothing to be done and forced is
+ // false.
+ function updateDisplayInner(cm, visible, forced) {
+ var display = cm.display, doc = cm.doc;
+ if (!display.wrapper.offsetWidth) {
+ resetView(cm);
+ return;
+ }
+
+ // Bail out if the visible area is already rendered and nothing changed.
+ if (!forced && visible.from >= display.viewFrom && visible.to <= display.viewTo &&
+ countDirtyView(cm) == 0)
+ return;
+
+ if (maybeUpdateLineNumberWidth(cm))
+ resetView(cm);
+ var dims = getDimensions(cm);
+
+ // Compute a suitable new viewport (from & to)
+ var end = doc.first + doc.size;
+ var from = Math.max(visible.from - cm.options.viewportMargin, doc.first);
+ var to = Math.min(end, visible.to + cm.options.viewportMargin);
+ if (display.viewFrom < from && from - display.viewFrom < 20) from = Math.max(doc.first, display.viewFrom);
+ if (display.viewTo > to && display.viewTo - to < 20) to = Math.min(end, display.viewTo);
+ if (sawCollapsedSpans) {
+ from = visualLineNo(cm.doc, from);
+ to = visualLineEndNo(cm.doc, to);
+ }
+
+ var different = from != display.viewFrom || to != display.viewTo ||
+ display.lastSizeC != display.wrapper.clientHeight;
+ adjustView(cm, from, to);
+
+ display.viewOffset = heightAtLine(getLine(cm.doc, display.viewFrom));
+ // Position the mover div to align with the current scroll position
+ cm.display.mover.style.top = display.viewOffset + "px";
+
+ var toUpdate = countDirtyView(cm);
+ if (!different && toUpdate == 0 && !forced) return;
+
+ // For big changes, we hide the enclosing element during the
+ // update, since that speeds up the operations on most browsers.
+ var focused = activeElt();
+ if (toUpdate > 4) display.lineDiv.style.display = "none";
+ patchDisplay(cm, display.updateLineNumbers, dims);
+ if (toUpdate > 4) display.lineDiv.style.display = "";
+ // There might have been a widget with a focused element that got
+ // hidden or updated, if so re-focus it.
+ if (focused && activeElt() != focused && focused.offsetHeight) focused.focus();
+
+ // Prevent selection and cursors from interfering with the scroll
+ // width.
+ removeChildren(display.cursorDiv);
+ removeChildren(display.selectionDiv);
+
+ if (different) {
+ display.lastSizeC = display.wrapper.clientHeight;
+ startWorker(cm, 400);
+ }
+
+ updateHeightsInViewport(cm);
+
+ return true;
+ }
+
+ function adjustContentWidth(cm) {
+ var display = cm.display;
+ var width = measureChar(cm, display.maxLine, display.maxLine.text.length).left;
+ display.maxLineChanged = false;
+ var minWidth = Math.max(0, width + 3);
+ var maxScrollLeft = Math.max(0, display.sizer.offsetLeft + minWidth + scrollerCutOff - display.scroller.clientWidth);
+ display.sizer.style.minWidth = minWidth + "px";
+ if (maxScrollLeft < cm.doc.scrollLeft)
+ setScrollLeft(cm, Math.min(display.scroller.scrollLeft, maxScrollLeft), true);
+ }
+
+ function setDocumentHeight(cm, measure) {
+ cm.display.sizer.style.minHeight = cm.display.heightForcer.style.top = measure.docHeight + "px";
+ cm.display.gutters.style.height = Math.max(measure.docHeight, measure.clientHeight - scrollerCutOff) + "px";
+ }
+
+
+ function checkForWebkitWidthBug(cm, measure) {
+ // Work around Webkit bug where it sometimes reserves space for a
+ // non-existing phantom scrollbar in the scroller (Issue #2420)
+ if (cm.display.sizer.offsetWidth + cm.display.gutters.offsetWidth < cm.display.scroller.clientWidth - 1) {
+ cm.display.sizer.style.minHeight = cm.display.heightForcer.style.top = "0px";
+ cm.display.gutters.style.height = measure.docHeight + "px";
+ }
+ }
+
+ // Read the actual heights of the rendered lines, and update their
+ // stored heights to match.
+ function updateHeightsInViewport(cm) {
+ var display = cm.display;
+ var prevBottom = display.lineDiv.offsetTop;
+ for (var i = 0; i < display.view.length; i++) {
+ var cur = display.view[i], height;
+ if (cur.hidden) continue;
+ if (ie_upto7) {
+ var bot = cur.node.offsetTop + cur.node.offsetHeight;
+ height = bot - prevBottom;
+ prevBottom = bot;
+ } else {
+ var box = cur.node.getBoundingClientRect();
+ height = box.bottom - box.top;
+ }
+ var diff = cur.line.height - height;
+ if (height < 2) height = textHeight(display);
+ if (diff > .001 || diff < -.001) {
+ updateLineHeight(cur.line, height);
+ updateWidgetHeight(cur.line);
+ if (cur.rest) for (var j = 0; j < cur.rest.length; j++)
+ updateWidgetHeight(cur.rest[j]);
+ }
+ }
+ }
+
+ // Read and store the height of line widgets associated with the
+ // given line.
+ function updateWidgetHeight(line) {
+ if (line.widgets) for (var i = 0; i < line.widgets.length; ++i)
+ line.widgets[i].height = line.widgets[i].node.offsetHeight;
+ }
+
+ // Do a bulk-read of the DOM positions and sizes needed to draw the
+ // view, so that we don't interleave reading and writing to the DOM.
+ function getDimensions(cm) {
+ var d = cm.display, left = {}, width = {};
+ for (var n = d.gutters.firstChild, i = 0; n; n = n.nextSibling, ++i) {
+ left[cm.options.gutters[i]] = n.offsetLeft;
+ width[cm.options.gutters[i]] = n.offsetWidth;
+ }
+ return {fixedPos: compensateForHScroll(d),
+ gutterTotalWidth: d.gutters.offsetWidth,
+ gutterLeft: left,
+ gutterWidth: width,
+ wrapperWidth: d.wrapper.clientWidth};
+ }
+
+ // Sync the actual display DOM structure with display.view, removing
+ // nodes for lines that are no longer in view, and creating the ones
+ // that are not there yet, and updating the ones that are out of
+ // date.
+ function patchDisplay(cm, updateNumbersFrom, dims) {
+ var display = cm.display, lineNumbers = cm.options.lineNumbers;
+ var container = display.lineDiv, cur = container.firstChild;
+
+ function rm(node) {
+ var next = node.nextSibling;
+ // Works around a throw-scroll bug in OS X Webkit
+ if (webkit && mac && cm.display.currentWheelTarget == node)
+ node.style.display = "none";
+ else
+ node.parentNode.removeChild(node);
+ return next;
+ }
+
+ var view = display.view, lineN = display.viewFrom;
+ // Loop over the elements in the view, syncing cur (the DOM nodes
+ // in display.lineDiv) with the view as we go.
+ for (var i = 0; i < view.length; i++) {
+ var lineView = view[i];
+ if (lineView.hidden) {
+ } else if (!lineView.node) { // Not drawn yet
+ var node = buildLineElement(cm, lineView, lineN, dims);
+ container.insertBefore(node, cur);
+ } else { // Already drawn
+ while (cur != lineView.node) cur = rm(cur);
+ var updateNumber = lineNumbers && updateNumbersFrom != null &&
+ updateNumbersFrom <= lineN && lineView.lineNumber;
+ if (lineView.changes) {
+ if (indexOf(lineView.changes, "gutter") > -1) updateNumber = false;
+ updateLineForChanges(cm, lineView, lineN, dims);
+ }
+ if (updateNumber) {
+ removeChildren(lineView.lineNumber);
+ lineView.lineNumber.appendChild(document.createTextNode(lineNumberFor(cm.options, lineN)));
+ }
+ cur = lineView.node.nextSibling;
+ }
+ lineN += lineView.size;
+ }
+ while (cur) cur = rm(cur);
+ }
+
+ // When an aspect of a line changes, a string is added to
+ // lineView.changes. This updates the relevant part of the line's
+ // DOM structure.
+ function updateLineForChanges(cm, lineView, lineN, dims) {
+ for (var j = 0; j < lineView.changes.length; j++) {
+ var type = lineView.changes[j];
+ if (type == "text") updateLineText(cm, lineView);
+ else if (type == "gutter") updateLineGutter(cm, lineView, lineN, dims);
+ else if (type == "class") updateLineClasses(lineView);
+ else if (type == "widget") updateLineWidgets(lineView, dims);
+ }
+ lineView.changes = null;
+ }
+
+ // Lines with gutter elements, widgets or a background class need to
+ // be wrapped, and have the extra elements added to the wrapper div
+ function ensureLineWrapped(lineView) {
+ if (lineView.node == lineView.text) {
+ lineView.node = elt("div", null, null, "position: relative");
+ if (lineView.text.parentNode)
+ lineView.text.parentNode.replaceChild(lineView.node, lineView.text);
+ lineView.node.appendChild(lineView.text);
+ if (ie_upto7) lineView.node.style.zIndex = 2;
+ }
+ return lineView.node;
+ }
+
+ function updateLineBackground(lineView) {
+ var cls = lineView.bgClass ? lineView.bgClass + " " + (lineView.line.bgClass || "") : lineView.line.bgClass;
+ if (cls) cls += " CodeMirror-linebackground";
+ if (lineView.background) {
+ if (cls) lineView.background.className = cls;
+ else { lineView.background.parentNode.removeChild(lineView.background); lineView.background = null; }
+ } else if (cls) {
+ var wrap = ensureLineWrapped(lineView);
+ lineView.background = wrap.insertBefore(elt("div", null, cls), wrap.firstChild);
+ }
+ }
+
+ // Wrapper around buildLineContent which will reuse the structure
+ // in display.externalMeasured when possible.
+ function getLineContent(cm, lineView) {
+ var ext = cm.display.externalMeasured;
+ if (ext && ext.line == lineView.line) {
+ cm.display.externalMeasured = null;
+ lineView.measure = ext.measure;
+ return ext.built;
+ }
+ return buildLineContent(cm, lineView);
+ }
+
+ // Redraw the line's text. Interacts with the background and text
+ // classes because the mode may output tokens that influence these
+ // classes.
+ function updateLineText(cm, lineView) {
+ var cls = lineView.text.className;
+ var built = getLineContent(cm, lineView);
+ if (lineView.text == lineView.node) lineView.node = built.pre;
+ lineView.text.parentNode.replaceChild(built.pre, lineView.text);
+ lineView.text = built.pre;
+ if (built.bgClass != lineView.bgClass || built.textClass != lineView.textClass) {
+ lineView.bgClass = built.bgClass;
+ lineView.textClass = built.textClass;
+ updateLineClasses(lineView);
+ } else if (cls) {
+ lineView.text.className = cls;
+ }
+ }
+
+ function updateLineClasses(lineView) {
+ updateLineBackground(lineView);
+ if (lineView.line.wrapClass)
+ ensureLineWrapped(lineView).className = lineView.line.wrapClass;
+ else if (lineView.node != lineView.text)
+ lineView.node.className = "";
+ var textClass = lineView.textClass ? lineView.textClass + " " + (lineView.line.textClass || "") : lineView.line.textClass;
+ lineView.text.className = textClass || "";
+ }
+
+ function updateLineGutter(cm, lineView, lineN, dims) {
+ if (lineView.gutter) {
+ lineView.node.removeChild(lineView.gutter);
+ lineView.gutter = null;
+ }
+ var markers = lineView.line.gutterMarkers;
+ if (cm.options.lineNumbers || markers) {
+ var wrap = ensureLineWrapped(lineView);
+ var gutterWrap = lineView.gutter =
+ wrap.insertBefore(elt("div", null, "CodeMirror-gutter-wrapper", "position: absolute; left: " +
+ (cm.options.fixedGutter ? dims.fixedPos : -dims.gutterTotalWidth) + "px"),
+ lineView.text);
+ if (cm.options.lineNumbers && (!markers || !markers["CodeMirror-linenumbers"]))
+ lineView.lineNumber = gutterWrap.appendChild(
+ elt("div", lineNumberFor(cm.options, lineN),
+ "CodeMirror-linenumber CodeMirror-gutter-elt",
+ "left: " + dims.gutterLeft["CodeMirror-linenumbers"] + "px; width: "
+ + cm.display.lineNumInnerWidth + "px"));
+ if (markers) for (var k = 0; k < cm.options.gutters.length; ++k) {
+ var id = cm.options.gutters[k], found = markers.hasOwnProperty(id) && markers[id];
+ if (found)
+ gutterWrap.appendChild(elt("div", [found], "CodeMirror-gutter-elt", "left: " +
+ dims.gutterLeft[id] + "px; width: " + dims.gutterWidth[id] + "px"));
+ }
+ }
+ }
+
+ function updateLineWidgets(lineView, dims) {
+ if (lineView.alignable) lineView.alignable = null;
+ for (var node = lineView.node.firstChild, next; node; node = next) {
+ var next = node.nextSibling;
+ if (node.className == "CodeMirror-linewidget")
+ lineView.node.removeChild(node);
+ }
+ insertLineWidgets(lineView, dims);
+ }
+
+ // Build a line's DOM representation from scratch
+ function buildLineElement(cm, lineView, lineN, dims) {
+ var built = getLineContent(cm, lineView);
+ lineView.text = lineView.node = built.pre;
+ if (built.bgClass) lineView.bgClass = built.bgClass;
+ if (built.textClass) lineView.textClass = built.textClass;
+
+ updateLineClasses(lineView);
+ updateLineGutter(cm, lineView, lineN, dims);
+ insertLineWidgets(lineView, dims);
+ return lineView.node;
+ }
+
+ // A lineView may contain multiple logical lines (when merged by
+ // collapsed spans). The widgets for all of them need to be drawn.
+ function insertLineWidgets(lineView, dims) {
+ insertLineWidgetsFor(lineView.line, lineView, dims, true);
+ if (lineView.rest) for (var i = 0; i < lineView.rest.length; i++)
+ insertLineWidgetsFor(lineView.rest[i], lineView, dims, false);
+ }
+
+ function insertLineWidgetsFor(line, lineView, dims, allowAbove) {
+ if (!line.widgets) return;
+ var wrap = ensureLineWrapped(lineView);
+ for (var i = 0, ws = line.widgets; i < ws.length; ++i) {
+ var widget = ws[i], node = elt("div", [widget.node], "CodeMirror-linewidget");
+ if (!widget.handleMouseEvents) node.ignoreEvents = true;
+ positionLineWidget(widget, node, lineView, dims);
+ if (allowAbove && widget.above)
+ wrap.insertBefore(node, lineView.gutter || lineView.text);
+ else
+ wrap.appendChild(node);
+ signalLater(widget, "redraw");
+ }
+ }
+
+ function positionLineWidget(widget, node, lineView, dims) {
+ if (widget.noHScroll) {
+ (lineView.alignable || (lineView.alignable = [])).push(node);
+ var width = dims.wrapperWidth;
+ node.style.left = dims.fixedPos + "px";
+ if (!widget.coverGutter) {
+ width -= dims.gutterTotalWidth;
+ node.style.paddingLeft = dims.gutterTotalWidth + "px";
+ }
+ node.style.width = width + "px";
+ }
+ if (widget.coverGutter) {
+ node.style.zIndex = 5;
+ node.style.position = "relative";
+ if (!widget.noHScroll) node.style.marginLeft = -dims.gutterTotalWidth + "px";
+ }
+ }
+
+ // POSITION OBJECT
+
+ // A Pos instance represents a position within the text.
+ var Pos = CodeMirror.Pos = function(line, ch) {
+ if (!(this instanceof Pos)) return new Pos(line, ch);
+ this.line = line; this.ch = ch;
+ };
+
+ // Compare two positions, return 0 if they are the same, a negative
+ // number when a is less, and a positive number otherwise.
+ var cmp = CodeMirror.cmpPos = function(a, b) { return a.line - b.line || a.ch - b.ch; };
+
+ function copyPos(x) {return Pos(x.line, x.ch);}
+ function maxPos(a, b) { return cmp(a, b) < 0 ? b : a; }
+ function minPos(a, b) { return cmp(a, b) < 0 ? a : b; }
+
+ // SELECTION / CURSOR
+
+ // Selection objects are immutable. A new one is created every time
+ // the selection changes. A selection is one or more non-overlapping
+ // (and non-touching) ranges, sorted, and an integer that indicates
+ // which one is the primary selection (the one that's scrolled into
+ // view, that getCursor returns, etc).
+ function Selection(ranges, primIndex) {
+ this.ranges = ranges;
+ this.primIndex = primIndex;
+ }
+
+ Selection.prototype = {
+ primary: function() { return this.ranges[this.primIndex]; },
+ equals: function(other) {
+ if (other == this) return true;
+ if (other.primIndex != this.primIndex || other.ranges.length != this.ranges.length) return false;
+ for (var i = 0; i < this.ranges.length; i++) {
+ var here = this.ranges[i], there = other.ranges[i];
+ if (cmp(here.anchor, there.anchor) != 0 || cmp(here.head, there.head) != 0) return false;
+ }
+ return true;
+ },
+ deepCopy: function() {
+ for (var out = [], i = 0; i < this.ranges.length; i++)
+ out[i] = new Range(copyPos(this.ranges[i].anchor), copyPos(this.ranges[i].head));
+ return new Selection(out, this.primIndex);
+ },
+ somethingSelected: function() {
+ for (var i = 0; i < this.ranges.length; i++)
+ if (!this.ranges[i].empty()) return true;
+ return false;
+ },
+ contains: function(pos, end) {
+ if (!end) end = pos;
+ for (var i = 0; i < this.ranges.length; i++) {
+ var range = this.ranges[i];
+ if (cmp(end, range.from()) >= 0 && cmp(pos, range.to()) <= 0)
+ return i;
+ }
+ return -1;
+ }
+ };
+
+ function Range(anchor, head) {
+ this.anchor = anchor; this.head = head;
+ }
+
+ Range.prototype = {
+ from: function() { return minPos(this.anchor, this.head); },
+ to: function() { return maxPos(this.anchor, this.head); },
+ empty: function() {
+ return this.head.line == this.anchor.line && this.head.ch == this.anchor.ch;
+ }
+ };
+
+ // Take an unsorted, potentially overlapping set of ranges, and
+ // build a selection out of it. 'Consumes' ranges array (modifying
+ // it).
+ function normalizeSelection(ranges, primIndex) {
+ var prim = ranges[primIndex];
+ ranges.sort(function(a, b) { return cmp(a.from(), b.from()); });
+ primIndex = indexOf(ranges, prim);
+ for (var i = 1; i < ranges.length; i++) {
+ var cur = ranges[i], prev = ranges[i - 1];
+ if (cmp(prev.to(), cur.from()) >= 0) {
+ var from = minPos(prev.from(), cur.from()), to = maxPos(prev.to(), cur.to());
+ var inv = prev.empty() ? cur.from() == cur.head : prev.from() == prev.head;
+ if (i <= primIndex) --primIndex;
+ ranges.splice(--i, 2, new Range(inv ? to : from, inv ? from : to));
+ }
+ }
+ return new Selection(ranges, primIndex);
+ }
+
+ function simpleSelection(anchor, head) {
+ return new Selection([new Range(anchor, head || anchor)], 0);
+ }
+
+ // Most of the external API clips given positions to make sure they
+ // actually exist within the document.
+ function clipLine(doc, n) {return Math.max(doc.first, Math.min(n, doc.first + doc.size - 1));}
+ function clipPos(doc, pos) {
+ if (pos.line < doc.first) return Pos(doc.first, 0);
+ var last = doc.first + doc.size - 1;
+ if (pos.line > last) return Pos(last, getLine(doc, last).text.length);
+ return clipToLen(pos, getLine(doc, pos.line).text.length);
+ }
+ function clipToLen(pos, linelen) {
+ var ch = pos.ch;
+ if (ch == null || ch > linelen) return Pos(pos.line, linelen);
+ else if (ch < 0) return Pos(pos.line, 0);
+ else return pos;
+ }
+ function isLine(doc, l) {return l >= doc.first && l < doc.first + doc.size;}
+ function clipPosArray(doc, array) {
+ for (var out = [], i = 0; i < array.length; i++) out[i] = clipPos(doc, array[i]);
+ return out;
+ }
+
+ // SELECTION UPDATES
+
+ // The 'scroll' parameter given to many of these indicated whether
+ // the new cursor position should be scrolled into view after
+ // modifying the selection.
+
+ // If shift is held or the extend flag is set, extends a range to
+ // include a given position (and optionally a second position).
+ // Otherwise, simply returns the range between the given positions.
+ // Used for cursor motion and such.
+ function extendRange(doc, range, head, other) {
+ if (doc.cm && doc.cm.display.shift || doc.extend) {
+ var anchor = range.anchor;
+ if (other) {
+ var posBefore = cmp(head, anchor) < 0;
+ if (posBefore != (cmp(other, anchor) < 0)) {
+ anchor = head;
+ head = other;
+ } else if (posBefore != (cmp(head, other) < 0)) {
+ head = other;
+ }
+ }
+ return new Range(anchor, head);
+ } else {
+ return new Range(other || head, head);
+ }
+ }
+
+ // Extend the primary selection range, discard the rest.
+ function extendSelection(doc, head, other, options) {
+ setSelection(doc, new Selection([extendRange(doc, doc.sel.primary(), head, other)], 0), options);
+ }
+
+ // Extend all selections (pos is an array of selections with length
+ // equal the number of selections)
+ function extendSelections(doc, heads, options) {
+ for (var out = [], i = 0; i < doc.sel.ranges.length; i++)
+ out[i] = extendRange(doc, doc.sel.ranges[i], heads[i], null);
+ var newSel = normalizeSelection(out, doc.sel.primIndex);
+ setSelection(doc, newSel, options);
+ }
+
+ // Updates a single range in the selection.
+ function replaceOneSelection(doc, i, range, options) {
+ var ranges = doc.sel.ranges.slice(0);
+ ranges[i] = range;
+ setSelection(doc, normalizeSelection(ranges, doc.sel.primIndex), options);
+ }
+
+ // Reset the selection to a single range.
+ function setSimpleSelection(doc, anchor, head, options) {
+ setSelection(doc, simpleSelection(anchor, head), options);
+ }
+
+ // Give beforeSelectionChange handlers a change to influence a
+ // selection update.
+ function filterSelectionChange(doc, sel) {
+ var obj = {
+ ranges: sel.ranges,
+ update: function(ranges) {
+ this.ranges = [];
+ for (var i = 0; i < ranges.length; i++)
+ this.ranges[i] = new Range(clipPos(doc, ranges[i].anchor),
+ clipPos(doc, ranges[i].head));
+ }
+ };
+ signal(doc, "beforeSelectionChange", doc, obj);
+ if (doc.cm) signal(doc.cm, "beforeSelectionChange", doc.cm, obj);
+ if (obj.ranges != sel.ranges) return normalizeSelection(obj.ranges, obj.ranges.length - 1);
+ else return sel;
+ }
+
+ function setSelectionReplaceHistory(doc, sel, options) {
+ var done = doc.history.done, last = lst(done);
+ if (last && last.ranges) {
+ done[done.length - 1] = sel;
+ setSelectionNoUndo(doc, sel, options);
+ } else {
+ setSelection(doc, sel, options);
+ }
+ }
+
+ // Set a new selection.
+ function setSelection(doc, sel, options) {
+ setSelectionNoUndo(doc, sel, options);
+ addSelectionToHistory(doc, doc.sel, doc.cm ? doc.cm.curOp.id : NaN, options);
+ }
+
+ function setSelectionNoUndo(doc, sel, options) {
+ if (hasHandler(doc, "beforeSelectionChange") || doc.cm && hasHandler(doc.cm, "beforeSelectionChange"))
+ sel = filterSelectionChange(doc, sel);
+
+ var bias = cmp(sel.primary().head, doc.sel.primary().head) < 0 ? -1 : 1;
+ setSelectionInner(doc, skipAtomicInSelection(doc, sel, bias, true));
+
+ if (!(options && options.scroll === false) && doc.cm)
+ ensureCursorVisible(doc.cm);
+ }
+
+ function setSelectionInner(doc, sel) {
+ if (sel.equals(doc.sel)) return;
+
+ doc.sel = sel;
+
+ if (doc.cm) {
+ doc.cm.curOp.updateInput = doc.cm.curOp.selectionChanged = true;
+ signalCursorActivity(doc.cm);
+ }
+ signalLater(doc, "cursorActivity", doc);
+ }
+
+ // Verify that the selection does not partially select any atomic
+ // marked ranges.
+ function reCheckSelection(doc) {
+ setSelectionInner(doc, skipAtomicInSelection(doc, doc.sel, null, false), sel_dontScroll);
+ }
+
+ // Return a selection that does not partially select any atomic
+ // ranges.
+ function skipAtomicInSelection(doc, sel, bias, mayClear) {
+ var out;
+ for (var i = 0; i < sel.ranges.length; i++) {
+ var range = sel.ranges[i];
+ var newAnchor = skipAtomic(doc, range.anchor, bias, mayClear);
+ var newHead = skipAtomic(doc, range.head, bias, mayClear);
+ if (out || newAnchor != range.anchor || newHead != range.head) {
+ if (!out) out = sel.ranges.slice(0, i);
+ out[i] = new Range(newAnchor, newHead);
+ }
+ }
+ return out ? normalizeSelection(out, sel.primIndex) : sel;
+ }
+
+ // Ensure a given position is not inside an atomic range.
+ function skipAtomic(doc, pos, bias, mayClear) {
+ var flipped = false, curPos = pos;
+ var dir = bias || 1;
+ doc.cantEdit = false;
+ search: for (;;) {
+ var line = getLine(doc, curPos.line);
+ if (line.markedSpans) {
+ for (var i = 0; i < line.markedSpans.length; ++i) {
+ var sp = line.markedSpans[i], m = sp.marker;
+ if ((sp.from == null || (m.inclusiveLeft ? sp.from <= curPos.ch : sp.from < curPos.ch)) &&
+ (sp.to == null || (m.inclusiveRight ? sp.to >= curPos.ch : sp.to > curPos.ch))) {
+ if (mayClear) {
+ signal(m, "beforeCursorEnter");
+ if (m.explicitlyCleared) {
+ if (!line.markedSpans) break;
+ else {--i; continue;}
+ }
+ }
+ if (!m.atomic) continue;
+ var newPos = m.find(dir < 0 ? -1 : 1);
+ if (cmp(newPos, curPos) == 0) {
+ newPos.ch += dir;
+ if (newPos.ch < 0) {
+ if (newPos.line > doc.first) newPos = clipPos(doc, Pos(newPos.line - 1));
+ else newPos = null;
+ } else if (newPos.ch > line.text.length) {
+ if (newPos.line < doc.first + doc.size - 1) newPos = Pos(newPos.line + 1, 0);
+ else newPos = null;
+ }
+ if (!newPos) {
+ if (flipped) {
+ // Driven in a corner -- no valid cursor position found at all
+ // -- try again *with* clearing, if we didn't already
+ if (!mayClear) return skipAtomic(doc, pos, bias, true);
+ // Otherwise, turn off editing until further notice, and return the start of the doc
+ doc.cantEdit = true;
+ return Pos(doc.first, 0);
+ }
+ flipped = true; newPos = pos; dir = -dir;
+ }
+ }
+ curPos = newPos;
+ continue search;
+ }
+ }
+ }
+ return curPos;
+ }
+ }
+
+ // SELECTION DRAWING
+
+ // Redraw the selection and/or cursor
+ function updateSelection(cm) {
+ var display = cm.display, doc = cm.doc;
+ var curFragment = document.createDocumentFragment();
+ var selFragment = document.createDocumentFragment();
+
+ for (var i = 0; i < doc.sel.ranges.length; i++) {
+ var range = doc.sel.ranges[i];
+ var collapsed = range.empty();
+ if (collapsed || cm.options.showCursorWhenSelecting)
+ drawSelectionCursor(cm, range, curFragment);
+ if (!collapsed)
+ drawSelectionRange(cm, range, selFragment);
+ }
+
+ // Move the hidden textarea near the cursor to prevent scrolling artifacts
+ if (cm.options.moveInputWithCursor) {
+ var headPos = cursorCoords(cm, doc.sel.primary().head, "div");
+ var wrapOff = display.wrapper.getBoundingClientRect(), lineOff = display.lineDiv.getBoundingClientRect();
+ var top = Math.max(0, Math.min(display.wrapper.clientHeight - 10,
+ headPos.top + lineOff.top - wrapOff.top));
+ var left = Math.max(0, Math.min(display.wrapper.clientWidth - 10,
+ headPos.left + lineOff.left - wrapOff.left));
+ display.inputDiv.style.top = top + "px";
+ display.inputDiv.style.left = left + "px";
+ }
+
+ removeChildrenAndAdd(display.cursorDiv, curFragment);
+ removeChildrenAndAdd(display.selectionDiv, selFragment);
+ }
+
+ // Draws a cursor for the given range
+ function drawSelectionCursor(cm, range, output) {
+ var pos = cursorCoords(cm, range.head, "div");
+
+ var cursor = output.appendChild(elt("div", "\u00a0", "CodeMirror-cursor"));
+ cursor.style.left = pos.left + "px";
+ cursor.style.top = pos.top + "px";
+ cursor.style.height = Math.max(0, pos.bottom - pos.top) * cm.options.cursorHeight + "px";
+
+ if (pos.other) {
+ // Secondary cursor, shown when on a 'jump' in bi-directional text
+ var otherCursor = output.appendChild(elt("div", "\u00a0", "CodeMirror-cursor CodeMirror-secondarycursor"));
+ otherCursor.style.display = "";
+ otherCursor.style.left = pos.other.left + "px";
+ otherCursor.style.top = pos.other.top + "px";
+ otherCursor.style.height = (pos.other.bottom - pos.other.top) * .85 + "px";
+ }
+ }
+
+ // Draws the given range as a highlighted selection
+ function drawSelectionRange(cm, range, output) {
+ var display = cm.display, doc = cm.doc;
+ var fragment = document.createDocumentFragment();
+ var padding = paddingH(cm.display), leftSide = padding.left, rightSide = display.lineSpace.offsetWidth - padding.right;
+
+ function add(left, top, width, bottom) {
+ if (top < 0) top = 0;
+ top = Math.round(top);
+ bottom = Math.round(bottom);
+ fragment.appendChild(elt("div", null, "CodeMirror-selected", "position: absolute; left: " + left +
+ "px; top: " + top + "px; width: " + (width == null ? rightSide - left : width) +
+ "px; height: " + (bottom - top) + "px"));
+ }
+
+ function drawForLine(line, fromArg, toArg) {
+ var lineObj = getLine(doc, line);
+ var lineLen = lineObj.text.length;
+ var start, end;
+ function coords(ch, bias) {
+ return charCoords(cm, Pos(line, ch), "div", lineObj, bias);
+ }
+
+ iterateBidiSections(getOrder(lineObj), fromArg || 0, toArg == null ? lineLen : toArg, function(from, to, dir) {
+ var leftPos = coords(from, "left"), rightPos, left, right;
+ if (from == to) {
+ rightPos = leftPos;
+ left = right = leftPos.left;
+ } else {
+ rightPos = coords(to - 1, "right");
+ if (dir == "rtl") { var tmp = leftPos; leftPos = rightPos; rightPos = tmp; }
+ left = leftPos.left;
+ right = rightPos.right;
+ }
+ if (fromArg == null && from == 0) left = leftSide;
+ if (rightPos.top - leftPos.top > 3) { // Different lines, draw top part
+ add(left, leftPos.top, null, leftPos.bottom);
+ left = leftSide;
+ if (leftPos.bottom < rightPos.top) add(left, leftPos.bottom, null, rightPos.top);
+ }
+ if (toArg == null && to == lineLen) right = rightSide;
+ if (!start || leftPos.top < start.top || leftPos.top == start.top && leftPos.left < start.left)
+ start = leftPos;
+ if (!end || rightPos.bottom > end.bottom || rightPos.bottom == end.bottom && rightPos.right > end.right)
+ end = rightPos;
+ if (left < leftSide + 1) left = leftSide;
+ add(left, rightPos.top, right - left, rightPos.bottom);
+ });
+ return {start: start, end: end};
+ }
+
+ var sFrom = range.from(), sTo = range.to();
+ if (sFrom.line == sTo.line) {
+ drawForLine(sFrom.line, sFrom.ch, sTo.ch);
+ } else {
+ var fromLine = getLine(doc, sFrom.line), toLine = getLine(doc, sTo.line);
+ var singleVLine = visualLine(fromLine) == visualLine(toLine);
+ var leftEnd = drawForLine(sFrom.line, sFrom.ch, singleVLine ? fromLine.text.length + 1 : null).end;
+ var rightStart = drawForLine(sTo.line, singleVLine ? 0 : null, sTo.ch).start;
+ if (singleVLine) {
+ if (leftEnd.top < rightStart.top - 2) {
+ add(leftEnd.right, leftEnd.top, null, leftEnd.bottom);
+ add(leftSide, rightStart.top, rightStart.left, rightStart.bottom);
+ } else {
+ add(leftEnd.right, leftEnd.top, rightStart.left - leftEnd.right, leftEnd.bottom);
+ }
+ }
+ if (leftEnd.bottom < rightStart.top)
+ add(leftSide, leftEnd.bottom, null, rightStart.top);
+ }
+
+ output.appendChild(fragment);
+ }
+
+ // Cursor-blinking
+ function restartBlink(cm) {
+ if (!cm.state.focused) return;
+ var display = cm.display;
+ clearInterval(display.blinker);
+ var on = true;
+ display.cursorDiv.style.visibility = "";
+ if (cm.options.cursorBlinkRate > 0)
+ display.blinker = setInterval(function() {
+ display.cursorDiv.style.visibility = (on = !on) ? "" : "hidden";
+ }, cm.options.cursorBlinkRate);
+ }
+
+ // HIGHLIGHT WORKER
+
+ function startWorker(cm, time) {
+ if (cm.doc.mode.startState && cm.doc.frontier < cm.display.viewTo)
+ cm.state.highlight.set(time, bind(highlightWorker, cm));
+ }
+
+ function highlightWorker(cm) {
+ var doc = cm.doc;
+ if (doc.frontier < doc.first) doc.frontier = doc.first;
+ if (doc.frontier >= cm.display.viewTo) return;
+ var end = +new Date + cm.options.workTime;
+ var state = copyState(doc.mode, getStateBefore(cm, doc.frontier));
+
+ runInOp(cm, function() {
+ doc.iter(doc.frontier, Math.min(doc.first + doc.size, cm.display.viewTo + 500), function(line) {
+ if (doc.frontier >= cm.display.viewFrom) { // Visible
+ var oldStyles = line.styles;
+ var highlighted = highlightLine(cm, line, state, true);
+ line.styles = highlighted.styles;
+ if (highlighted.classes) line.styleClasses = highlighted.classes;
+ else if (line.styleClasses) line.styleClasses = null;
+ var ischange = !oldStyles || oldStyles.length != line.styles.length;
+ for (var i = 0; !ischange && i < oldStyles.length; ++i) ischange = oldStyles[i] != line.styles[i];
+ if (ischange) regLineChange(cm, doc.frontier, "text");
+ line.stateAfter = copyState(doc.mode, state);
+ } else {
+ processLine(cm, line.text, state);
+ line.stateAfter = doc.frontier % 5 == 0 ? copyState(doc.mode, state) : null;
+ }
+ ++doc.frontier;
+ if (+new Date > end) {
+ startWorker(cm, cm.options.workDelay);
+ return true;
+ }
+ });
+ });
+ }
+
+ // Finds the line to start with when starting a parse. Tries to
+ // find a line with a stateAfter, so that it can start with a
+ // valid state. If that fails, it returns the line with the
+ // smallest indentation, which tends to need the least context to
+ // parse correctly.
+ function findStartLine(cm, n, precise) {
+ var minindent, minline, doc = cm.doc;
+ var lim = precise ? -1 : n - (cm.doc.mode.innerMode ? 1000 : 100);
+ for (var search = n; search > lim; --search) {
+ if (search <= doc.first) return doc.first;
+ var line = getLine(doc, search - 1);
+ if (line.stateAfter && (!precise || search <= doc.frontier)) return search;
+ var indented = countColumn(line.text, null, cm.options.tabSize);
+ if (minline == null || minindent > indented) {
+ minline = search - 1;
+ minindent = indented;
+ }
+ }
+ return minline;
+ }
+
+ function getStateBefore(cm, n, precise) {
+ var doc = cm.doc, display = cm.display;
+ if (!doc.mode.startState) return true;
+ var pos = findStartLine(cm, n, precise), state = pos > doc.first && getLine(doc, pos-1).stateAfter;
+ if (!state) state = startState(doc.mode);
+ else state = copyState(doc.mode, state);
+ doc.iter(pos, n, function(line) {
+ processLine(cm, line.text, state);
+ var save = pos == n - 1 || pos % 5 == 0 || pos >= display.viewFrom && pos < display.viewTo;
+ line.stateAfter = save ? copyState(doc.mode, state) : null;
+ ++pos;
+ });
+ if (precise) doc.frontier = pos;
+ return state;
+ }
+
+ // POSITION MEASUREMENT
+
+ function paddingTop(display) {return display.lineSpace.offsetTop;}
+ function paddingVert(display) {return display.mover.offsetHeight - display.lineSpace.offsetHeight;}
+ function paddingH(display) {
+ if (display.cachedPaddingH) return display.cachedPaddingH;
+ var e = removeChildrenAndAdd(display.measure, elt("pre", "x"));
+ var style = window.getComputedStyle ? window.getComputedStyle(e) : e.currentStyle;
+ var data = {left: parseInt(style.paddingLeft), right: parseInt(style.paddingRight)};
+ if (!isNaN(data.left) && !isNaN(data.right)) display.cachedPaddingH = data;
+ return data;
+ }
+
+ // Ensure the lineView.wrapping.heights array is populated. This is
+ // an array of bottom offsets for the lines that make up a drawn
+ // line. When lineWrapping is on, there might be more than one
+ // height.
+ function ensureLineHeights(cm, lineView, rect) {
+ var wrapping = cm.options.lineWrapping;
+ var curWidth = wrapping && cm.display.scroller.clientWidth;
+ if (!lineView.measure.heights || wrapping && lineView.measure.width != curWidth) {
+ var heights = lineView.measure.heights = [];
+ if (wrapping) {
+ lineView.measure.width = curWidth;
+ var rects = lineView.text.firstChild.getClientRects();
+ for (var i = 0; i < rects.length - 1; i++) {
+ var cur = rects[i], next = rects[i + 1];
+ if (Math.abs(cur.bottom - next.bottom) > 2)
+ heights.push((cur.bottom + next.top) / 2 - rect.top);
+ }
+ }
+ heights.push(rect.bottom - rect.top);
+ }
+ }
+
+ // Find a line map (mapping character offsets to text nodes) and a
+ // measurement cache for the given line number. (A line view might
+ // contain multiple lines when collapsed ranges are present.)
+ function mapFromLineView(lineView, line, lineN) {
+ if (lineView.line == line)
+ return {map: lineView.measure.map, cache: lineView.measure.cache};
+ for (var i = 0; i < lineView.rest.length; i++)
+ if (lineView.rest[i] == line)
+ return {map: lineView.measure.maps[i], cache: lineView.measure.caches[i]};
+ for (var i = 0; i < lineView.rest.length; i++)
+ if (lineNo(lineView.rest[i]) > lineN)
+ return {map: lineView.measure.maps[i], cache: lineView.measure.caches[i], before: true};
+ }
+
+ // Render a line into the hidden node display.externalMeasured. Used
+ // when measurement is needed for a line that's not in the viewport.
+ function updateExternalMeasurement(cm, line) {
+ line = visualLine(line);
+ var lineN = lineNo(line);
+ var view = cm.display.externalMeasured = new LineView(cm.doc, line, lineN);
+ view.lineN = lineN;
+ var built = view.built = buildLineContent(cm, view);
+ view.text = built.pre;
+ removeChildrenAndAdd(cm.display.lineMeasure, built.pre);
+ return view;
+ }
+
+ // Get a {top, bottom, left, right} box (in line-local coordinates)
+ // for a given character.
+ function measureChar(cm, line, ch, bias) {
+ return measureCharPrepared(cm, prepareMeasureForLine(cm, line), ch, bias);
+ }
+
+ // Find a line view that corresponds to the given line number.
+ function findViewForLine(cm, lineN) {
+ if (lineN >= cm.display.viewFrom && lineN < cm.display.viewTo)
+ return cm.display.view[findViewIndex(cm, lineN)];
+ var ext = cm.display.externalMeasured;
+ if (ext && lineN >= ext.lineN && lineN < ext.lineN + ext.size)
+ return ext;
+ }
+
+ // Measurement can be split in two steps, the set-up work that
+ // applies to the whole line, and the measurement of the actual
+ // character. Functions like coordsChar, that need to do a lot of
+ // measurements in a row, can thus ensure that the set-up work is
+ // only done once.
+ function prepareMeasureForLine(cm, line) {
+ var lineN = lineNo(line);
+ var view = findViewForLine(cm, lineN);
+ if (view && !view.text)
+ view = null;
+ else if (view && view.changes)
+ updateLineForChanges(cm, view, lineN, getDimensions(cm));
+ if (!view)
+ view = updateExternalMeasurement(cm, line);
+
+ var info = mapFromLineView(view, line, lineN);
+ return {
+ line: line, view: view, rect: null,
+ map: info.map, cache: info.cache, before: info.before,
+ hasHeights: false
+ };
+ }
+
+ // Given a prepared measurement object, measures the position of an
+ // actual character (or fetches it from the cache).
+ function measureCharPrepared(cm, prepared, ch, bias) {
+ if (prepared.before) ch = -1;
+ var key = ch + (bias || ""), found;
+ if (prepared.cache.hasOwnProperty(key)) {
+ found = prepared.cache[key];
+ } else {
+ if (!prepared.rect)
+ prepared.rect = prepared.view.text.getBoundingClientRect();
+ if (!prepared.hasHeights) {
+ ensureLineHeights(cm, prepared.view, prepared.rect);
+ prepared.hasHeights = true;
+ }
+ found = measureCharInner(cm, prepared, ch, bias);
+ if (!found.bogus) prepared.cache[key] = found;
+ }
+ return {left: found.left, right: found.right, top: found.top, bottom: found.bottom};
+ }
+
+ var nullRect = {left: 0, right: 0, top: 0, bottom: 0};
+
+ function measureCharInner(cm, prepared, ch, bias) {
+ var map = prepared.map;
+
+ var node, start, end, collapse;
+ // First, search the line map for the text node corresponding to,
+ // or closest to, the target character.
+ for (var i = 0; i < map.length; i += 3) {
+ var mStart = map[i], mEnd = map[i + 1];
+ if (ch < mStart) {
+ start = 0; end = 1;
+ collapse = "left";
+ } else if (ch < mEnd) {
+ start = ch - mStart;
+ end = start + 1;
+ } else if (i == map.length - 3 || ch == mEnd && map[i + 3] > ch) {
+ end = mEnd - mStart;
+ start = end - 1;
+ if (ch >= mEnd) collapse = "right";
+ }
+ if (start != null) {
+ node = map[i + 2];
+ if (mStart == mEnd && bias == (node.insertLeft ? "left" : "right"))
+ collapse = bias;
+ if (bias == "left" && start == 0)
+ while (i && map[i - 2] == map[i - 3] && map[i - 1].insertLeft) {
+ node = map[(i -= 3) + 2];
+ collapse = "left";
+ }
+ if (bias == "right" && start == mEnd - mStart)
+ while (i < map.length - 3 && map[i + 3] == map[i + 4] && !map[i + 5].insertLeft) {
+ node = map[(i += 3) + 2];
+ collapse = "right";
+ }
+ break;
+ }
+ }
+
+ var rect;
+ if (node.nodeType == 3) { // If it is a text node, use a range to retrieve the coordinates.
+ while (start && isExtendingChar(prepared.line.text.charAt(mStart + start))) --start;
+ while (mStart + end < mEnd && isExtendingChar(prepared.line.text.charAt(mStart + end))) ++end;
+ if (ie_upto8 && start == 0 && end == mEnd - mStart) {
+ rect = node.parentNode.getBoundingClientRect();
+ } else if (ie && cm.options.lineWrapping) {
+ var rects = range(node, start, end).getClientRects();
+ if (rects.length)
+ rect = rects[bias == "right" ? rects.length - 1 : 0];
+ else
+ rect = nullRect;
+ } else {
+ rect = range(node, start, end).getBoundingClientRect();
+ }
+ } else { // If it is a widget, simply get the box for the whole widget.
+ if (start > 0) collapse = bias = "right";
+ var rects;
+ if (cm.options.lineWrapping && (rects = node.getClientRects()).length > 1)
+ rect = rects[bias == "right" ? rects.length - 1 : 0];
+ else
+ rect = node.getBoundingClientRect();
+ }
+ if (ie_upto8 && !start && (!rect || !rect.left && !rect.right)) {
+ var rSpan = node.parentNode.getClientRects()[0];
+ if (rSpan)
+ rect = {left: rSpan.left, right: rSpan.left + charWidth(cm.display), top: rSpan.top, bottom: rSpan.bottom};
+ else
+ rect = nullRect;
+ }
+
+ var top, bot = (rect.bottom + rect.top) / 2 - prepared.rect.top;
+ var heights = prepared.view.measure.heights;
+ for (var i = 0; i < heights.length - 1; i++)
+ if (bot < heights[i]) break;
+ top = i ? heights[i - 1] : 0; bot = heights[i];
+ var result = {left: (collapse == "right" ? rect.right : rect.left) - prepared.rect.left,
+ right: (collapse == "left" ? rect.left : rect.right) - prepared.rect.left,
+ top: top, bottom: bot};
+ if (!rect.left && !rect.right) result.bogus = true;
+ return result;
+ }
+
+ function clearLineMeasurementCacheFor(lineView) {
+ if (lineView.measure) {
+ lineView.measure.cache = {};
+ lineView.measure.heights = null;
+ if (lineView.rest) for (var i = 0; i < lineView.rest.length; i++)
+ lineView.measure.caches[i] = {};
+ }
+ }
+
+ function clearLineMeasurementCache(cm) {
+ cm.display.externalMeasure = null;
+ removeChildren(cm.display.lineMeasure);
+ for (var i = 0; i < cm.display.view.length; i++)
+ clearLineMeasurementCacheFor(cm.display.view[i]);
+ }
+
+ function clearCaches(cm) {
+ clearLineMeasurementCache(cm);
+ cm.display.cachedCharWidth = cm.display.cachedTextHeight = cm.display.cachedPaddingH = null;
+ if (!cm.options.lineWrapping) cm.display.maxLineChanged = true;
+ cm.display.lineNumChars = null;
+ }
+
+ function pageScrollX() { return window.pageXOffset || (document.documentElement || document.body).scrollLeft; }
+ function pageScrollY() { return window.pageYOffset || (document.documentElement || document.body).scrollTop; }
+
+ // Converts a {top, bottom, left, right} box from line-local
+ // coordinates into another coordinate system. Context may be one of
+ // "line", "div" (display.lineDiv), "local"/null (editor), or "page".
+ function intoCoordSystem(cm, lineObj, rect, context) {
+ if (lineObj.widgets) for (var i = 0; i < lineObj.widgets.length; ++i) if (lineObj.widgets[i].above) {
+ var size = widgetHeight(lineObj.widgets[i]);
+ rect.top += size; rect.bottom += size;
+ }
+ if (context == "line") return rect;
+ if (!context) context = "local";
+ var yOff = heightAtLine(lineObj);
+ if (context == "local") yOff += paddingTop(cm.display);
+ else yOff -= cm.display.viewOffset;
+ if (context == "page" || context == "window") {
+ var lOff = cm.display.lineSpace.getBoundingClientRect();
+ yOff += lOff.top + (context == "window" ? 0 : pageScrollY());
+ var xOff = lOff.left + (context == "window" ? 0 : pageScrollX());
+ rect.left += xOff; rect.right += xOff;
+ }
+ rect.top += yOff; rect.bottom += yOff;
+ return rect;
+ }
+
+ // Coverts a box from "div" coords to another coordinate system.
+ // Context may be "window", "page", "div", or "local"/null.
+ function fromCoordSystem(cm, coords, context) {
+ if (context == "div") return coords;
+ var left = coords.left, top = coords.top;
+ // First move into "page" coordinate system
+ if (context == "page") {
+ left -= pageScrollX();
+ top -= pageScrollY();
+ } else if (context == "local" || !context) {
+ var localBox = cm.display.sizer.getBoundingClientRect();
+ left += localBox.left;
+ top += localBox.top;
+ }
+
+ var lineSpaceBox = cm.display.lineSpace.getBoundingClientRect();
+ return {left: left - lineSpaceBox.left, top: top - lineSpaceBox.top};
+ }
+
+ function charCoords(cm, pos, context, lineObj, bias) {
+ if (!lineObj) lineObj = getLine(cm.doc, pos.line);
+ return intoCoordSystem(cm, lineObj, measureChar(cm, lineObj, pos.ch, bias), context);
+ }
+
+ // Returns a box for a given cursor position, which may have an
+ // 'other' property containing the position of the secondary cursor
+ // on a bidi boundary.
+ function cursorCoords(cm, pos, context, lineObj, preparedMeasure) {
+ lineObj = lineObj || getLine(cm.doc, pos.line);
+ if (!preparedMeasure) preparedMeasure = prepareMeasureForLine(cm, lineObj);
+ function get(ch, right) {
+ var m = measureCharPrepared(cm, preparedMeasure, ch, right ? "right" : "left");
+ if (right) m.left = m.right; else m.right = m.left;
+ return intoCoordSystem(cm, lineObj, m, context);
+ }
+ function getBidi(ch, partPos) {
+ var part = order[partPos], right = part.level % 2;
+ if (ch == bidiLeft(part) && partPos && part.level < order[partPos - 1].level) {
+ part = order[--partPos];
+ ch = bidiRight(part) - (part.level % 2 ? 0 : 1);
+ right = true;
+ } else if (ch == bidiRight(part) && partPos < order.length - 1 && part.level < order[partPos + 1].level) {
+ part = order[++partPos];
+ ch = bidiLeft(part) - part.level % 2;
+ right = false;
+ }
+ if (right && ch == part.to && ch > part.from) return get(ch - 1);
+ return get(ch, right);
+ }
+ var order = getOrder(lineObj), ch = pos.ch;
+ if (!order) return get(ch);
+ var partPos = getBidiPartAt(order, ch);
+ var val = getBidi(ch, partPos);
+ if (bidiOther != null) val.other = getBidi(ch, bidiOther);
+ return val;
+ }
+
+ // Used to cheaply estimate the coordinates for a position. Used for
+ // intermediate scroll updates.
+ function estimateCoords(cm, pos) {
+ var left = 0, pos = clipPos(cm.doc, pos);
+ if (!cm.options.lineWrapping) left = charWidth(cm.display) * pos.ch;
+ var lineObj = getLine(cm.doc, pos.line);
+ var top = heightAtLine(lineObj) + paddingTop(cm.display);
+ return {left: left, right: left, top: top, bottom: top + lineObj.height};
+ }
+
+ // Positions returned by coordsChar contain some extra information.
+ // xRel is the relative x position of the input coordinates compared
+ // to the found position (so xRel > 0 means the coordinates are to
+ // the right of the character position, for example). When outside
+ // is true, that means the coordinates lie outside the line's
+ // vertical range.
+ function PosWithInfo(line, ch, outside, xRel) {
+ var pos = Pos(line, ch);
+ pos.xRel = xRel;
+ if (outside) pos.outside = true;
+ return pos;
+ }
+
+ // Compute the character position closest to the given coordinates.
+ // Input must be lineSpace-local ("div" coordinate system).
+ function coordsChar(cm, x, y) {
+ var doc = cm.doc;
+ y += cm.display.viewOffset;
+ if (y < 0) return PosWithInfo(doc.first, 0, true, -1);
+ var lineN = lineAtHeight(doc, y), last = doc.first + doc.size - 1;
+ if (lineN > last)
+ return PosWithInfo(doc.first + doc.size - 1, getLine(doc, last).text.length, true, 1);
+ if (x < 0) x = 0;
+
+ var lineObj = getLine(doc, lineN);
+ for (;;) {
+ var found = coordsCharInner(cm, lineObj, lineN, x, y);
+ var merged = collapsedSpanAtEnd(lineObj);
+ var mergedPos = merged && merged.find(0, true);
+ if (merged && (found.ch > mergedPos.from.ch || found.ch == mergedPos.from.ch && found.xRel > 0))
+ lineN = lineNo(lineObj = mergedPos.to.line);
+ else
+ return found;
+ }
+ }
+
+ function coordsCharInner(cm, lineObj, lineNo, x, y) {
+ var innerOff = y - heightAtLine(lineObj);
+ var wrongLine = false, adjust = 2 * cm.display.wrapper.clientWidth;
+ var preparedMeasure = prepareMeasureForLine(cm, lineObj);
+
+ function getX(ch) {
+ var sp = cursorCoords(cm, Pos(lineNo, ch), "line", lineObj, preparedMeasure);
+ wrongLine = true;
+ if (innerOff > sp.bottom) return sp.left - adjust;
+ else if (innerOff < sp.top) return sp.left + adjust;
+ else wrongLine = false;
+ return sp.left;
+ }
+
+ var bidi = getOrder(lineObj), dist = lineObj.text.length;
+ var from = lineLeft(lineObj), to = lineRight(lineObj);
+ var fromX = getX(from), fromOutside = wrongLine, toX = getX(to), toOutside = wrongLine;
+
+ if (x > toX) return PosWithInfo(lineNo, to, toOutside, 1);
+ // Do a binary search between these bounds.
+ for (;;) {
+ if (bidi ? to == from || to == moveVisually(lineObj, from, 1) : to - from <= 1) {
+ var ch = x < fromX || x - fromX <= toX - x ? from : to;
+ var xDiff = x - (ch == from ? fromX : toX);
+ while (isExtendingChar(lineObj.text.charAt(ch))) ++ch;
+ var pos = PosWithInfo(lineNo, ch, ch == from ? fromOutside : toOutside,
+ xDiff < -1 ? -1 : xDiff > 1 ? 1 : 0);
+ return pos;
+ }
+ var step = Math.ceil(dist / 2), middle = from + step;
+ if (bidi) {
+ middle = from;
+ for (var i = 0; i < step; ++i) middle = moveVisually(lineObj, middle, 1);
+ }
+ var middleX = getX(middle);
+ if (middleX > x) {to = middle; toX = middleX; if (toOutside = wrongLine) toX += 1000; dist = step;}
+ else {from = middle; fromX = middleX; fromOutside = wrongLine; dist -= step;}
+ }
+ }
+
+ var measureText;
+ // Compute the default text height.
+ function textHeight(display) {
+ if (display.cachedTextHeight != null) return display.cachedTextHeight;
+ if (measureText == null) {
+ measureText = elt("pre");
+ // Measure a bunch of lines, for browsers that compute
+ // fractional heights.
+ for (var i = 0; i < 49; ++i) {
+ measureText.appendChild(document.createTextNode("x"));
+ measureText.appendChild(elt("br"));
+ }
+ measureText.appendChild(document.createTextNode("x"));
+ }
+ removeChildrenAndAdd(display.measure, measureText);
+ var height = measureText.offsetHeight / 50;
+ if (height > 3) display.cachedTextHeight = height;
+ removeChildren(display.measure);
+ return height || 1;
+ }
+
+ // Compute the default character width.
+ function charWidth(display) {
+ if (display.cachedCharWidth != null) return display.cachedCharWidth;
+ var anchor = elt("span", "xxxxxxxxxx");
+ var pre = elt("pre", [anchor]);
+ removeChildrenAndAdd(display.measure, pre);
+ var rect = anchor.getBoundingClientRect(), width = (rect.right - rect.left) / 10;
+ if (width > 2) display.cachedCharWidth = width;
+ return width || 10;
+ }
+
+ // OPERATIONS
+
+ // Operations are used to wrap a series of changes to the editor
+ // state in such a way that each change won't have to update the
+ // cursor and display (which would be awkward, slow, and
+ // error-prone). Instead, display updates are batched and then all
+ // combined and executed at once.
+
+ var nextOpId = 0;
+ // Start a new operation.
+ function startOperation(cm) {
+ cm.curOp = {
+ viewChanged: false, // Flag that indicates that lines might need to be redrawn
+ startHeight: cm.doc.height, // Used to detect need to update scrollbar
+ forceUpdate: false, // Used to force a redraw
+ updateInput: null, // Whether to reset the input textarea
+ typing: false, // Whether this reset should be careful to leave existing text (for compositing)
+ changeObjs: null, // Accumulated changes, for firing change events
+ cursorActivityHandlers: null, // Set of handlers to fire cursorActivity on
+ selectionChanged: false, // Whether the selection needs to be redrawn
+ updateMaxLine: false, // Set when the widest line needs to be determined anew
+ scrollLeft: null, scrollTop: null, // Intermediate scroll position, not pushed to DOM yet
+ scrollToPos: null, // Used to scroll to a specific position
+ id: ++nextOpId // Unique ID
+ };
+ if (!delayedCallbackDepth++) delayedCallbacks = [];
+ }
+
+ // Finish an operation, updating the display and signalling delayed events
+ function endOperation(cm) {
+ var op = cm.curOp, doc = cm.doc, display = cm.display;
+ cm.curOp = null;
+
+ if (op.updateMaxLine) findMaxLine(cm);
+
+ // If it looks like an update might be needed, call updateDisplay
+ if (op.viewChanged || op.forceUpdate || op.scrollTop != null ||
+ op.scrollToPos && (op.scrollToPos.from.line < display.viewFrom ||
+ op.scrollToPos.to.line >= display.viewTo) ||
+ display.maxLineChanged && cm.options.lineWrapping) {
+ var updated = updateDisplay(cm, {top: op.scrollTop, ensure: op.scrollToPos}, op.forceUpdate);
+ if (cm.display.scroller.offsetHeight) cm.doc.scrollTop = cm.display.scroller.scrollTop;
+ }
+ // If no update was run, but the selection changed, redraw that.
+ if (!updated && op.selectionChanged) updateSelection(cm);
+ if (!updated && op.startHeight != cm.doc.height) updateScrollbars(cm);
+
+ // Propagate the scroll position to the actual DOM scroller
+ if (op.scrollTop != null && display.scroller.scrollTop != op.scrollTop) {
+ var top = Math.max(0, Math.min(display.scroller.scrollHeight - display.scroller.clientHeight, op.scrollTop));
+ display.scroller.scrollTop = display.scrollbarV.scrollTop = doc.scrollTop = top;
+ }
+ if (op.scrollLeft != null && display.scroller.scrollLeft != op.scrollLeft) {
+ var left = Math.max(0, Math.min(display.scroller.scrollWidth - display.scroller.clientWidth, op.scrollLeft));
+ display.scroller.scrollLeft = display.scrollbarH.scrollLeft = doc.scrollLeft = left;
+ alignHorizontally(cm);
+ }
+ // If we need to scroll a specific position into view, do so.
+ if (op.scrollToPos) {
+ var coords = scrollPosIntoView(cm, clipPos(cm.doc, op.scrollToPos.from),
+ clipPos(cm.doc, op.scrollToPos.to), op.scrollToPos.margin);
+ if (op.scrollToPos.isCursor && cm.state.focused) maybeScrollWindow(cm, coords);
+ }
+
+ if (op.selectionChanged) restartBlink(cm);
+
+ if (cm.state.focused && op.updateInput)
+ resetInput(cm, op.typing);
+
+ // Fire events for markers that are hidden/unidden by editing or
+ // undoing
+ var hidden = op.maybeHiddenMarkers, unhidden = op.maybeUnhiddenMarkers;
+ if (hidden) for (var i = 0; i < hidden.length; ++i)
+ if (!hidden[i].lines.length) signal(hidden[i], "hide");
+ if (unhidden) for (var i = 0; i < unhidden.length; ++i)
+ if (unhidden[i].lines.length) signal(unhidden[i], "unhide");
+
+ var delayed;
+ if (!--delayedCallbackDepth) {
+ delayed = delayedCallbacks;
+ delayedCallbacks = null;
+ }
+ // Fire change events, and delayed event handlers
+ if (op.changeObjs)
+ signal(cm, "changes", cm, op.changeObjs);
+ if (delayed) for (var i = 0; i < delayed.length; ++i) delayed[i]();
+ if (op.cursorActivityHandlers)
+ for (var i = 0; i < op.cursorActivityHandlers.length; i++)
+ op.cursorActivityHandlers[i](cm);
+ }
+
+ // Run the given function in an operation
+ function runInOp(cm, f) {
+ if (cm.curOp) return f();
+ startOperation(cm);
+ try { return f(); }
+ finally { endOperation(cm); }
+ }
+ // Wraps a function in an operation. Returns the wrapped function.
+ function operation(cm, f) {
+ return function() {
+ if (cm.curOp) return f.apply(cm, arguments);
+ startOperation(cm);
+ try { return f.apply(cm, arguments); }
+ finally { endOperation(cm); }
+ };
+ }
+ // Used to add methods to editor and doc instances, wrapping them in
+ // operations.
+ function methodOp(f) {
+ return function() {
+ if (this.curOp) return f.apply(this, arguments);
+ startOperation(this);
+ try { return f.apply(this, arguments); }
+ finally { endOperation(this); }
+ };
+ }
+ function docMethodOp(f) {
+ return function() {
+ var cm = this.cm;
+ if (!cm || cm.curOp) return f.apply(this, arguments);
+ startOperation(cm);
+ try { return f.apply(this, arguments); }
+ finally { endOperation(cm); }
+ };
+ }
+
+ // VIEW TRACKING
+
+ // These objects are used to represent the visible (currently drawn)
+ // part of the document. A LineView may correspond to multiple
+ // logical lines, if those are connected by collapsed ranges.
+ function LineView(doc, line, lineN) {
+ // The starting line
+ this.line = line;
+ // Continuing lines, if any
+ this.rest = visualLineContinued(line);
+ // Number of logical lines in this visual line
+ this.size = this.rest ? lineNo(lst(this.rest)) - lineN + 1 : 1;
+ this.node = this.text = null;
+ this.hidden = lineIsHidden(doc, line);
+ }
+
+ // Create a range of LineView objects for the given lines.
+ function buildViewArray(cm, from, to) {
+ var array = [], nextPos;
+ for (var pos = from; pos < to; pos = nextPos) {
+ var view = new LineView(cm.doc, getLine(cm.doc, pos), pos);
+ nextPos = pos + view.size;
+ array.push(view);
+ }
+ return array;
+ }
+
+ // Updates the display.view data structure for a given change to the
+ // document. From and to are in pre-change coordinates. Lendiff is
+ // the amount of lines added or subtracted by the change. This is
+ // used for changes that span multiple lines, or change the way
+ // lines are divided into visual lines. regLineChange (below)
+ // registers single-line changes.
+ function regChange(cm, from, to, lendiff) {
+ if (from == null) from = cm.doc.first;
+ if (to == null) to = cm.doc.first + cm.doc.size;
+ if (!lendiff) lendiff = 0;
+
+ var display = cm.display;
+ if (lendiff && to < display.viewTo &&
+ (display.updateLineNumbers == null || display.updateLineNumbers > from))
+ display.updateLineNumbers = from;
+
+ cm.curOp.viewChanged = true;
+
+ if (from >= display.viewTo) { // Change after
+ if (sawCollapsedSpans && visualLineNo(cm.doc, from) < display.viewTo)
+ resetView(cm);
+ } else if (to <= display.viewFrom) { // Change before
+ if (sawCollapsedSpans && visualLineEndNo(cm.doc, to + lendiff) > display.viewFrom) {
+ resetView(cm);
+ } else {
+ display.viewFrom += lendiff;
+ display.viewTo += lendiff;
+ }
+ } else if (from <= display.viewFrom && to >= display.viewTo) { // Full overlap
+ resetView(cm);
+ } else if (from <= display.viewFrom) { // Top overlap
+ var cut = viewCuttingPoint(cm, to, to + lendiff, 1);
+ if (cut) {
+ display.view = display.view.slice(cut.index);
+ display.viewFrom = cut.lineN;
+ display.viewTo += lendiff;
+ } else {
+ resetView(cm);
+ }
+ } else if (to >= display.viewTo) { // Bottom overlap
+ var cut = viewCuttingPoint(cm, from, from, -1);
+ if (cut) {
+ display.view = display.view.slice(0, cut.index);
+ display.viewTo = cut.lineN;
+ } else {
+ resetView(cm);
+ }
+ } else { // Gap in the middle
+ var cutTop = viewCuttingPoint(cm, from, from, -1);
+ var cutBot = viewCuttingPoint(cm, to, to + lendiff, 1);
+ if (cutTop && cutBot) {
+ display.view = display.view.slice(0, cutTop.index)
+ .concat(buildViewArray(cm, cutTop.lineN, cutBot.lineN))
+ .concat(display.view.slice(cutBot.index));
+ display.viewTo += lendiff;
+ } else {
+ resetView(cm);
+ }
+ }
+
+ var ext = display.externalMeasured;
+ if (ext) {
+ if (to < ext.lineN)
+ ext.lineN += lendiff;
+ else if (from < ext.lineN + ext.size)
+ display.externalMeasured = null;
+ }
+ }
+
+ // Register a change to a single line. Type must be one of "text",
+ // "gutter", "class", "widget"
+ function regLineChange(cm, line, type) {
+ cm.curOp.viewChanged = true;
+ var display = cm.display, ext = cm.display.externalMeasured;
+ if (ext && line >= ext.lineN && line < ext.lineN + ext.size)
+ display.externalMeasured = null;
+
+ if (line < display.viewFrom || line >= display.viewTo) return;
+ var lineView = display.view[findViewIndex(cm, line)];
+ if (lineView.node == null) return;
+ var arr = lineView.changes || (lineView.changes = []);
+ if (indexOf(arr, type) == -1) arr.push(type);
+ }
+
+ // Clear the view.
+ function resetView(cm) {
+ cm.display.viewFrom = cm.display.viewTo = cm.doc.first;
+ cm.display.view = [];
+ cm.display.viewOffset = 0;
+ }
+
+ // Find the view element corresponding to a given line. Return null
+ // when the line isn't visible.
+ function findViewIndex(cm, n) {
+ if (n >= cm.display.viewTo) return null;
+ n -= cm.display.viewFrom;
+ if (n < 0) return null;
+ var view = cm.display.view;
+ for (var i = 0; i < view.length; i++) {
+ n -= view[i].size;
+ if (n < 0) return i;
+ }
+ }
+
+ function viewCuttingPoint(cm, oldN, newN, dir) {
+ var index = findViewIndex(cm, oldN), diff, view = cm.display.view;
+ if (!sawCollapsedSpans) return {index: index, lineN: newN};
+ for (var i = 0, n = cm.display.viewFrom; i < index; i++)
+ n += view[i].size;
+ if (n != oldN) {
+ if (dir > 0) {
+ if (index == view.length - 1) return null;
+ diff = (n + view[index].size) - oldN;
+ index++;
+ } else {
+ diff = n - oldN;
+ }
+ oldN += diff; newN += diff;
+ }
+ while (visualLineNo(cm.doc, newN) != newN) {
+ if (index == (dir < 0 ? 0 : view.length - 1)) return null;
+ newN += dir * view[index - (dir < 0 ? 1 : 0)].size;
+ index += dir;
+ }
+ return {index: index, lineN: newN};
+ }
+
+ // Force the view to cover a given range, adding empty view element
+ // or clipping off existing ones as needed.
+ function adjustView(cm, from, to) {
+ var display = cm.display, view = display.view;
+ if (view.length == 0 || from >= display.viewTo || to <= display.viewFrom) {
+ display.view = buildViewArray(cm, from, to);
+ display.viewFrom = from;
+ } else {
+ if (display.viewFrom > from)
+ display.view = buildViewArray(cm, from, display.viewFrom).concat(display.view);
+ else if (display.viewFrom < from)
+ display.view = display.view.slice(findViewIndex(cm, from));
+ display.viewFrom = from;
+ if (display.viewTo < to)
+ display.view = display.view.concat(buildViewArray(cm, display.viewTo, to));
+ else if (display.viewTo > to)
+ display.view = display.view.slice(0, findViewIndex(cm, to));
+ }
+ display.viewTo = to;
+ }
+
+ // Count the number of lines in the view whose DOM representation is
+ // out of date (or nonexistent).
+ function countDirtyView(cm) {
+ var view = cm.display.view, dirty = 0;
+ for (var i = 0; i < view.length; i++) {
+ var lineView = view[i];
+ if (!lineView.hidden && (!lineView.node || lineView.changes)) ++dirty;
+ }
+ return dirty;
+ }
+
+ // INPUT HANDLING
+
+ // Poll for input changes, using the normal rate of polling. This
+ // runs as long as the editor is focused.
+ function slowPoll(cm) {
+ if (cm.display.pollingFast) return;
+ cm.display.poll.set(cm.options.pollInterval, function() {
+ readInput(cm);
+ if (cm.state.focused) slowPoll(cm);
+ });
+ }
+
+ // When an event has just come in that is likely to add or change
+ // something in the input textarea, we poll faster, to ensure that
+ // the change appears on the screen quickly.
+ function fastPoll(cm) {
+ var missed = false;
+ cm.display.pollingFast = true;
+ function p() {
+ var changed = readInput(cm);
+ if (!changed && !missed) {missed = true; cm.display.poll.set(60, p);}
+ else {cm.display.pollingFast = false; slowPoll(cm);}
+ }
+ cm.display.poll.set(20, p);
+ }
+
+ // Read input from the textarea, and update the document to match.
+ // When something is selected, it is present in the textarea, and
+ // selected (unless it is huge, in which case a placeholder is
+ // used). When nothing is selected, the cursor sits after previously
+ // seen text (can be empty), which is stored in prevInput (we must
+ // not reset the textarea when typing, because that breaks IME).
+ function readInput(cm) {
+ var input = cm.display.input, prevInput = cm.display.prevInput, doc = cm.doc;
+ // Since this is called a *lot*, try to bail out as cheaply as
+ // possible when it is clear that nothing happened. hasSelection
+ // will be the case when there is a lot of text in the textarea,
+ // in which case reading its value would be expensive.
+ if (!cm.state.focused || (hasSelection(input) && !prevInput) || isReadOnly(cm) || cm.options.disableInput)
+ return false;
+ // See paste handler for more on the fakedLastChar kludge
+ if (cm.state.pasteIncoming && cm.state.fakedLastChar) {
+ input.value = input.value.substring(0, input.value.length - 1);
+ cm.state.fakedLastChar = false;
+ }
+ var text = input.value;
+ // If nothing changed, bail.
+ if (text == prevInput && !cm.somethingSelected()) return false;
+ // Work around nonsensical selection resetting in IE9/10
+ if (ie && !ie_upto8 && cm.display.inputHasSelection === text) {
+ resetInput(cm);
+ return false;
+ }
+
+ var withOp = !cm.curOp;
+ if (withOp) startOperation(cm);
+ cm.display.shift = false;
+
+ // Find the part of the input that is actually new
+ var same = 0, l = Math.min(prevInput.length, text.length);
+ while (same < l && prevInput.charCodeAt(same) == text.charCodeAt(same)) ++same;
+ var inserted = text.slice(same), textLines = splitLines(inserted);
+
+ // When pasing N lines into N selections, insert one line per selection
+ var multiPaste = cm.state.pasteIncoming && textLines.length > 1 && doc.sel.ranges.length == textLines.length;
+
+ // Normal behavior is to insert the new text into every selection
+ for (var i = doc.sel.ranges.length - 1; i >= 0; i--) {
+ var range = doc.sel.ranges[i];
+ var from = range.from(), to = range.to();
+ // Handle deletion
+ if (same < prevInput.length)
+ from = Pos(from.line, from.ch - (prevInput.length - same));
+ // Handle overwrite
+ else if (cm.state.overwrite && range.empty() && !cm.state.pasteIncoming)
+ to = Pos(to.line, Math.min(getLine(doc, to.line).text.length, to.ch + lst(textLines).length));
+ var updateInput = cm.curOp.updateInput;
+ var changeEvent = {from: from, to: to, text: multiPaste ? [textLines[i]] : textLines,
+ origin: cm.state.pasteIncoming ? "paste" : cm.state.cutIncoming ? "cut" : "+input"};
+ makeChange(cm.doc, changeEvent);
+ signalLater(cm, "inputRead", cm, changeEvent);
+ // When an 'electric' character is inserted, immediately trigger a reindent
+ if (inserted && !cm.state.pasteIncoming && cm.options.electricChars &&
+ cm.options.smartIndent && range.head.ch < 100 &&
+ (!i || doc.sel.ranges[i - 1].head.line != range.head.line)) {
+ var mode = cm.getModeAt(range.head);
+ if (mode.electricChars) {
+ for (var j = 0; j < mode.electricChars.length; j++)
+ if (inserted.indexOf(mode.electricChars.charAt(j)) > -1) {
+ indentLine(cm, range.head.line, "smart");
+ break;
+ }
+ } else if (mode.electricInput) {
+ var end = changeEnd(changeEvent);
+ if (mode.electricInput.test(getLine(doc, end.line).text.slice(0, end.ch)))
+ indentLine(cm, range.head.line, "smart");
+ }
+ }
+ }
+ ensureCursorVisible(cm);
+ cm.curOp.updateInput = updateInput;
+ cm.curOp.typing = true;
+
+ // Don't leave long text in the textarea, since it makes further polling slow
+ if (text.length > 1000 || text.indexOf("\n") > -1) input.value = cm.display.prevInput = "";
+ else cm.display.prevInput = text;
+ if (withOp) endOperation(cm);
+ cm.state.pasteIncoming = cm.state.cutIncoming = false;
+ return true;
+ }
+
+ // Reset the input to correspond to the selection (or to be empty,
+ // when not typing and nothing is selected)
+ function resetInput(cm, typing) {
+ var minimal, selected, doc = cm.doc;
+ if (cm.somethingSelected()) {
+ cm.display.prevInput = "";
+ var range = doc.sel.primary();
+ minimal = hasCopyEvent &&
+ (range.to().line - range.from().line > 100 || (selected = cm.getSelection()).length > 1000);
+ var content = minimal ? "-" : selected || cm.getSelection();
+ cm.display.input.value = content;
+ if (cm.state.focused) selectInput(cm.display.input);
+ if (ie && !ie_upto8) cm.display.inputHasSelection = content;
+ } else if (!typing) {
+ cm.display.prevInput = cm.display.input.value = "";
+ if (ie && !ie_upto8) cm.display.inputHasSelection = null;
+ }
+ cm.display.inaccurateSelection = minimal;
+ }
+
+ function focusInput(cm) {
+ if (cm.options.readOnly != "nocursor" && (!mobile || activeElt() != cm.display.input))
+ cm.display.input.focus();
+ }
+
+ function ensureFocus(cm) {
+ if (!cm.state.focused) { focusInput(cm); onFocus(cm); }
+ }
+
+ function isReadOnly(cm) {
+ return cm.options.readOnly || cm.doc.cantEdit;
+ }
+
+ // EVENT HANDLERS
+
+ // Attach the necessary event handlers when initializing the editor
+ function registerEventHandlers(cm) {
+ var d = cm.display;
+ on(d.scroller, "mousedown", operation(cm, onMouseDown));
+ // Older IE's will not fire a second mousedown for a double click
+ if (ie_upto10)
+ on(d.scroller, "dblclick", operation(cm, function(e) {
+ if (signalDOMEvent(cm, e)) return;
+ var pos = posFromMouse(cm, e);
+ if (!pos || clickInGutter(cm, e) || eventInWidget(cm.display, e)) return;
+ e_preventDefault(e);
+ var word = findWordAt(cm.doc, pos);
+ extendSelection(cm.doc, word.anchor, word.head);
+ }));
+ else
+ on(d.scroller, "dblclick", function(e) { signalDOMEvent(cm, e) || e_preventDefault(e); });
+ // Prevent normal selection in the editor (we handle our own)
+ on(d.lineSpace, "selectstart", function(e) {
+ if (!eventInWidget(d, e)) e_preventDefault(e);
+ });
+ // Some browsers fire contextmenu *after* opening the menu, at
+ // which point we can't mess with it anymore. Context menu is
+ // handled in onMouseDown for these browsers.
+ if (!captureRightClick) on(d.scroller, "contextmenu", function(e) {onContextMenu(cm, e);});
+
+ // Sync scrolling between fake scrollbars and real scrollable
+ // area, ensure viewport is updated when scrolling.
+ on(d.scroller, "scroll", function() {
+ if (d.scroller.clientHeight) {
+ setScrollTop(cm, d.scroller.scrollTop);
+ setScrollLeft(cm, d.scroller.scrollLeft, true);
+ signal(cm, "scroll", cm);
+ }
+ });
+ on(d.scrollbarV, "scroll", function() {
+ if (d.scroller.clientHeight) setScrollTop(cm, d.scrollbarV.scrollTop);
+ });
+ on(d.scrollbarH, "scroll", function() {
+ if (d.scroller.clientHeight) setScrollLeft(cm, d.scrollbarH.scrollLeft);
+ });
+
+ // Listen to wheel events in order to try and update the viewport on time.
+ on(d.scroller, "mousewheel", function(e){onScrollWheel(cm, e);});
+ on(d.scroller, "DOMMouseScroll", function(e){onScrollWheel(cm, e);});
+
+ // Prevent clicks in the scrollbars from killing focus
+ function reFocus() { if (cm.state.focused) setTimeout(bind(focusInput, cm), 0); }
+ on(d.scrollbarH, "mousedown", reFocus);
+ on(d.scrollbarV, "mousedown", reFocus);
+ // Prevent wrapper from ever scrolling
+ on(d.wrapper, "scroll", function() { d.wrapper.scrollTop = d.wrapper.scrollLeft = 0; });
+
+ // When the window resizes, we need to refresh active editors.
+ var resizeTimer;
+ function onResize() {
+ if (resizeTimer == null) resizeTimer = setTimeout(function() {
+ resizeTimer = null;
+ // Might be a text scaling operation, clear size caches.
+ d.cachedCharWidth = d.cachedTextHeight = d.cachedPaddingH = knownScrollbarWidth = null;
+ cm.setSize();
+ }, 100);
+ }
+ on(window, "resize", onResize);
+ // The above handler holds on to the editor and its data
+ // structures. Here we poll to unregister it when the editor is no
+ // longer in the document, so that it can be garbage-collected.
+ function unregister() {
+ if (contains(document.body, d.wrapper)) setTimeout(unregister, 5000);
+ else off(window, "resize", onResize);
+ }
+ setTimeout(unregister, 5000);
+
+ on(d.input, "keyup", operation(cm, onKeyUp));
+ on(d.input, "input", function() {
+ if (ie && !ie_upto8 && cm.display.inputHasSelection) cm.display.inputHasSelection = null;
+ fastPoll(cm);
+ });
+ on(d.input, "keydown", operation(cm, onKeyDown));
+ on(d.input, "keypress", operation(cm, onKeyPress));
+ on(d.input, "focus", bind(onFocus, cm));
+ on(d.input, "blur", bind(onBlur, cm));
+
+ function drag_(e) {
+ if (!signalDOMEvent(cm, e)) e_stop(e);
+ }
+ if (cm.options.dragDrop) {
+ on(d.scroller, "dragstart", function(e){onDragStart(cm, e);});
+ on(d.scroller, "dragenter", drag_);
+ on(d.scroller, "dragover", drag_);
+ on(d.scroller, "drop", operation(cm, onDrop));
+ }
+ on(d.scroller, "paste", function(e) {
+ if (eventInWidget(d, e)) return;
+ cm.state.pasteIncoming = true;
+ focusInput(cm);
+ fastPoll(cm);
+ });
+ on(d.input, "paste", function() {
+ // Workaround for webkit bug https://bugs.webkit.org/show_bug.cgi?id=90206
+ // Add a char to the end of textarea before paste occur so that
+ // selection doesn't span to the end of textarea.
+ if (webkit && !cm.state.fakedLastChar && !(new Date - cm.state.lastMiddleDown < 200)) {
+ var start = d.input.selectionStart, end = d.input.selectionEnd;
+ d.input.value += "$";
+ d.input.selectionStart = start;
+ d.input.selectionEnd = end;
+ cm.state.fakedLastChar = true;
+ }
+ cm.state.pasteIncoming = true;
+ fastPoll(cm);
+ });
+
+ function prepareCopyCut(e) {
+ if (cm.somethingSelected()) {
+ if (d.inaccurateSelection) {
+ d.prevInput = "";
+ d.inaccurateSelection = false;
+ d.input.value = cm.getSelection();
+ selectInput(d.input);
+ }
+ } else {
+ var text = "", ranges = [];
+ for (var i = 0; i < cm.doc.sel.ranges.length; i++) {
+ var line = cm.doc.sel.ranges[i].head.line;
+ var lineRange = {anchor: Pos(line, 0), head: Pos(line + 1, 0)};
+ ranges.push(lineRange);
+ text += cm.getRange(lineRange.anchor, lineRange.head);
+ }
+ if (e.type == "cut") {
+ cm.setSelections(ranges, null, sel_dontScroll);
+ } else {
+ d.prevInput = "";
+ d.input.value = text;
+ selectInput(d.input);
+ }
+ }
+ if (e.type == "cut") cm.state.cutIncoming = true;
+ }
+ on(d.input, "cut", prepareCopyCut);
+ on(d.input, "copy", prepareCopyCut);
+
+ // Needed to handle Tab key in KHTML
+ if (khtml) on(d.sizer, "mouseup", function() {
+ if (activeElt() == d.input) d.input.blur();
+ focusInput(cm);
+ });
+ }
+
+ // MOUSE EVENTS
+
+ // Return true when the given mouse event happened in a widget
+ function eventInWidget(display, e) {
+ for (var n = e_target(e); n != display.wrapper; n = n.parentNode) {
+ if (!n || n.ignoreEvents || n.parentNode == display.sizer && n != display.mover) return true;
+ }
+ }
+
+ // Given a mouse event, find the corresponding position. If liberal
+ // is false, it checks whether a gutter or scrollbar was clicked,
+ // and returns null if it was. forRect is used by rectangular
+ // selections, and tries to estimate a character position even for
+ // coordinates beyond the right of the text.
+ function posFromMouse(cm, e, liberal, forRect) {
+ var display = cm.display;
+ if (!liberal) {
+ var target = e_target(e);
+ if (target == display.scrollbarH || target == display.scrollbarV ||
+ target == display.scrollbarFiller || target == display.gutterFiller) return null;
+ }
+ var x, y, space = display.lineSpace.getBoundingClientRect();
+ // Fails unpredictably on IE[67] when mouse is dragged around quickly.
+ try { x = e.clientX - space.left; y = e.clientY - space.top; }
+ catch (e) { return null; }
+ var coords = coordsChar(cm, x, y), line;
+ if (forRect && coords.xRel == 1 && (line = getLine(cm.doc, coords.line).text).length == coords.ch) {
+ var colDiff = countColumn(line, line.length, cm.options.tabSize) - line.length;
+ coords = Pos(coords.line, Math.max(0, Math.round((x - paddingH(cm.display).left) / charWidth(cm.display)) - colDiff));
+ }
+ return coords;
+ }
+
+ // A mouse down can be a single click, double click, triple click,
+ // start of selection drag, start of text drag, new cursor
+ // (ctrl-click), rectangle drag (alt-drag), or xwin
+ // middle-click-paste. Or it might be a click on something we should
+ // not interfere with, such as a scrollbar or widget.
+ function onMouseDown(e) {
+ if (signalDOMEvent(this, e)) return;
+ var cm = this, display = cm.display;
+ display.shift = e.shiftKey;
+
+ if (eventInWidget(display, e)) {
+ if (!webkit) {
+ // Briefly turn off draggability, to allow widgets to do
+ // normal dragging things.
+ display.scroller.draggable = false;
+ setTimeout(function(){display.scroller.draggable = true;}, 100);
+ }
+ return;
+ }
+ if (clickInGutter(cm, e)) return;
+ var start = posFromMouse(cm, e);
+ window.focus();
+
+ switch (e_button(e)) {
+ case 1:
+ if (start)
+ leftButtonDown(cm, e, start);
+ else if (e_target(e) == display.scroller)
+ e_preventDefault(e);
+ break;
+ case 2:
+ if (webkit) cm.state.lastMiddleDown = +new Date;
+ if (start) extendSelection(cm.doc, start);
+ setTimeout(bind(focusInput, cm), 20);
+ e_preventDefault(e);
+ break;
+ case 3:
+ if (captureRightClick) onContextMenu(cm, e);
+ break;
+ }
+ }
+
+ var lastClick, lastDoubleClick;
+ function leftButtonDown(cm, e, start) {
+ setTimeout(bind(ensureFocus, cm), 0);
+
+ var now = +new Date, type;
+ if (lastDoubleClick && lastDoubleClick.time > now - 400 && cmp(lastDoubleClick.pos, start) == 0) {
+ type = "triple";
+ } else if (lastClick && lastClick.time > now - 400 && cmp(lastClick.pos, start) == 0) {
+ type = "double";
+ lastDoubleClick = {time: now, pos: start};
+ } else {
+ type = "single";
+ lastClick = {time: now, pos: start};
+ }
+
+ var sel = cm.doc.sel, addNew = mac ? e.metaKey : e.ctrlKey;
+ if (cm.options.dragDrop && dragAndDrop && !addNew && !isReadOnly(cm) &&
+ type == "single" && sel.contains(start) > -1 && sel.somethingSelected())
+ leftButtonStartDrag(cm, e, start);
+ else
+ leftButtonSelect(cm, e, start, type, addNew);
+ }
+
+ // Start a text drag. When it ends, see if any dragging actually
+ // happen, and treat as a click if it didn't.
+ function leftButtonStartDrag(cm, e, start) {
+ var display = cm.display;
+ var dragEnd = operation(cm, function(e2) {
+ if (webkit) display.scroller.draggable = false;
+ cm.state.draggingText = false;
+ off(document, "mouseup", dragEnd);
+ off(display.scroller, "drop", dragEnd);
+ if (Math.abs(e.clientX - e2.clientX) + Math.abs(e.clientY - e2.clientY) < 10) {
+ e_preventDefault(e2);
+ extendSelection(cm.doc, start);
+ focusInput(cm);
+ // Work around unexplainable focus problem in IE9 (#2127)
+ if (ie_upto10 && !ie_upto8)
+ setTimeout(function() {document.body.focus(); focusInput(cm);}, 20);
+ }
+ });
+ // Let the drag handler handle this.
+ if (webkit) display.scroller.draggable = true;
+ cm.state.draggingText = dragEnd;
+ // IE's approach to draggable
+ if (display.scroller.dragDrop) display.scroller.dragDrop();
+ on(document, "mouseup", dragEnd);
+ on(display.scroller, "drop", dragEnd);
+ }
+
+ // Normal selection, as opposed to text dragging.
+ function leftButtonSelect(cm, e, start, type, addNew) {
+ var display = cm.display, doc = cm.doc;
+ e_preventDefault(e);
+
+ var ourRange, ourIndex, startSel = doc.sel;
+ if (addNew && !e.shiftKey) {
+ ourIndex = doc.sel.contains(start);
+ if (ourIndex > -1)
+ ourRange = doc.sel.ranges[ourIndex];
+ else
+ ourRange = new Range(start, start);
+ } else {
+ ourRange = doc.sel.primary();
+ }
+
+ if (e.altKey) {
+ type = "rect";
+ if (!addNew) ourRange = new Range(start, start);
+ start = posFromMouse(cm, e, true, true);
+ ourIndex = -1;
+ } else if (type == "double") {
+ var word = findWordAt(doc, start);
+ if (cm.display.shift || doc.extend)
+ ourRange = extendRange(doc, ourRange, word.anchor, word.head);
+ else
+ ourRange = word;
+ } else if (type == "triple") {
+ var line = new Range(Pos(start.line, 0), clipPos(doc, Pos(start.line + 1, 0)));
+ if (cm.display.shift || doc.extend)
+ ourRange = extendRange(doc, ourRange, line.anchor, line.head);
+ else
+ ourRange = line;
+ } else {
+ ourRange = extendRange(doc, ourRange, start);
+ }
+
+ if (!addNew) {
+ ourIndex = 0;
+ setSelection(doc, new Selection([ourRange], 0), sel_mouse);
+ startSel = doc.sel;
+ } else if (ourIndex > -1) {
+ replaceOneSelection(doc, ourIndex, ourRange, sel_mouse);
+ } else {
+ ourIndex = doc.sel.ranges.length;
+ setSelection(doc, normalizeSelection(doc.sel.ranges.concat([ourRange]), ourIndex),
+ {scroll: false, origin: "*mouse"});
+ }
+
+ var lastPos = start;
+ function extendTo(pos) {
+ if (cmp(lastPos, pos) == 0) return;
+ lastPos = pos;
+
+ if (type == "rect") {
+ var ranges = [], tabSize = cm.options.tabSize;
+ var startCol = countColumn(getLine(doc, start.line).text, start.ch, tabSize);
+ var posCol = countColumn(getLine(doc, pos.line).text, pos.ch, tabSize);
+ var left = Math.min(startCol, posCol), right = Math.max(startCol, posCol);
+ for (var line = Math.min(start.line, pos.line), end = Math.min(cm.lastLine(), Math.max(start.line, pos.line));
+ line <= end; line++) {
+ var text = getLine(doc, line).text, leftPos = findColumn(text, left, tabSize);
+ if (left == right)
+ ranges.push(new Range(Pos(line, leftPos), Pos(line, leftPos)));
+ else if (text.length > leftPos)
+ ranges.push(new Range(Pos(line, leftPos), Pos(line, findColumn(text, right, tabSize))));
+ }
+ if (!ranges.length) ranges.push(new Range(start, start));
+ setSelection(doc, normalizeSelection(startSel.ranges.slice(0, ourIndex).concat(ranges), ourIndex), sel_mouse);
+ } else {
+ var oldRange = ourRange;
+ var anchor = oldRange.anchor, head = pos;
+ if (type != "single") {
+ if (type == "double")
+ var range = findWordAt(doc, pos);
+ else
+ var range = new Range(Pos(pos.line, 0), clipPos(doc, Pos(pos.line + 1, 0)));
+ if (cmp(range.anchor, anchor) > 0) {
+ head = range.head;
+ anchor = minPos(oldRange.from(), range.anchor);
+ } else {
+ head = range.anchor;
+ anchor = maxPos(oldRange.to(), range.head);
+ }
+ }
+ var ranges = startSel.ranges.slice(0);
+ ranges[ourIndex] = new Range(clipPos(doc, anchor), head);
+ setSelection(doc, normalizeSelection(ranges, ourIndex), sel_mouse);
+ }
+ }
+
+ var editorSize = display.wrapper.getBoundingClientRect();
+ // Used to ensure timeout re-tries don't fire when another extend
+ // happened in the meantime (clearTimeout isn't reliable -- at
+ // least on Chrome, the timeouts still happen even when cleared,
+ // if the clear happens after their scheduled firing time).
+ var counter = 0;
+
+ function extend(e) {
+ var curCount = ++counter;
+ var cur = posFromMouse(cm, e, true, type == "rect");
+ if (!cur) return;
+ if (cmp(cur, lastPos) != 0) {
+ ensureFocus(cm);
+ extendTo(cur);
+ var visible = visibleLines(display, doc);
+ if (cur.line >= visible.to || cur.line < visible.from)
+ setTimeout(operation(cm, function(){if (counter == curCount) extend(e);}), 150);
+ } else {
+ var outside = e.clientY < editorSize.top ? -20 : e.clientY > editorSize.bottom ? 20 : 0;
+ if (outside) setTimeout(operation(cm, function() {
+ if (counter != curCount) return;
+ display.scroller.scrollTop += outside;
+ extend(e);
+ }), 50);
+ }
+ }
+
+ function done(e) {
+ counter = Infinity;
+ e_preventDefault(e);
+ focusInput(cm);
+ off(document, "mousemove", move);
+ off(document, "mouseup", up);
+ doc.history.lastSelOrigin = null;
+ }
+
+ var move = operation(cm, function(e) {
+ if ((ie && !ie_upto9) ? !e.buttons : !e_button(e)) done(e);
+ else extend(e);
+ });
+ var up = operation(cm, done);
+ on(document, "mousemove", move);
+ on(document, "mouseup", up);
+ }
+
+ // Determines whether an event happened in the gutter, and fires the
+ // handlers for the corresponding event.
+ function gutterEvent(cm, e, type, prevent, signalfn) {
+ try { var mX = e.clientX, mY = e.clientY; }
+ catch(e) { return false; }
+ if (mX >= Math.floor(cm.display.gutters.getBoundingClientRect().right)) return false;
+ if (prevent) e_preventDefault(e);
+
+ var display = cm.display;
+ var lineBox = display.lineDiv.getBoundingClientRect();
+
+ if (mY > lineBox.bottom || !hasHandler(cm, type)) return e_defaultPrevented(e);
+ mY -= lineBox.top - display.viewOffset;
+
+ for (var i = 0; i < cm.options.gutters.length; ++i) {
+ var g = display.gutters.childNodes[i];
+ if (g && g.getBoundingClientRect().right >= mX) {
+ var line = lineAtHeight(cm.doc, mY);
+ var gutter = cm.options.gutters[i];
+ signalfn(cm, type, cm, line, gutter, e);
+ return e_defaultPrevented(e);
+ }
+ }
+ }
+
+ function clickInGutter(cm, e) {
+ return gutterEvent(cm, e, "gutterClick", true, signalLater);
+ }
+
+ // Kludge to work around strange IE behavior where it'll sometimes
+ // re-fire a series of drag-related events right after the drop (#1551)
+ var lastDrop = 0;
+
+ function onDrop(e) {
+ var cm = this;
+ if (signalDOMEvent(cm, e) || eventInWidget(cm.display, e))
+ return;
+ e_preventDefault(e);
+ if (ie) lastDrop = +new Date;
+ var pos = posFromMouse(cm, e, true), files = e.dataTransfer.files;
+ if (!pos || isReadOnly(cm)) return;
+ // Might be a file drop, in which case we simply extract the text
+ // and insert it.
+ if (files && files.length && window.FileReader && window.File) {
+ var n = files.length, text = Array(n), read = 0;
+ var loadFile = function(file, i) {
+ var reader = new FileReader;
+ reader.onload = operation(cm, function() {
+ text[i] = reader.result;
+ if (++read == n) {
+ pos = clipPos(cm.doc, pos);
+ var change = {from: pos, to: pos, text: splitLines(text.join("\n")), origin: "paste"};
+ makeChange(cm.doc, change);
+ setSelectionReplaceHistory(cm.doc, simpleSelection(pos, changeEnd(change)));
+ }
+ });
+ reader.readAsText(file);
+ };
+ for (var i = 0; i < n; ++i) loadFile(files[i], i);
+ } else { // Normal drop
+ // Don't do a replace if the drop happened inside of the selected text.
+ if (cm.state.draggingText && cm.doc.sel.contains(pos) > -1) {
+ cm.state.draggingText(e);
+ // Ensure the editor is re-focused
+ setTimeout(bind(focusInput, cm), 20);
+ return;
+ }
+ try {
+ var text = e.dataTransfer.getData("Text");
+ if (text) {
+ var selected = cm.state.draggingText && cm.listSelections();
+ setSelectionNoUndo(cm.doc, simpleSelection(pos, pos));
+ if (selected) for (var i = 0; i < selected.length; ++i)
+ replaceRange(cm.doc, "", selected[i].anchor, selected[i].head, "drag");
+ cm.replaceSelection(text, "around", "paste");
+ focusInput(cm);
+ }
+ }
+ catch(e){}
+ }
+ }
+
+ function onDragStart(cm, e) {
+ if (ie && (!cm.state.draggingText || +new Date - lastDrop < 100)) { e_stop(e); return; }
+ if (signalDOMEvent(cm, e) || eventInWidget(cm.display, e)) return;
+
+ e.dataTransfer.setData("Text", cm.getSelection());
+
+ // Use dummy image instead of default browsers image.
+ // Recent Safari (~6.0.2) have a tendency to segfault when this happens, so we don't do it there.
+ if (e.dataTransfer.setDragImage && !safari) {
+ var img = elt("img", null, null, "position: fixed; left: 0; top: 0;");
+ img.src = "data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw==";
+ if (presto) {
+ img.width = img.height = 1;
+ cm.display.wrapper.appendChild(img);
+ // Force a relayout, or Opera won't use our image for some obscure reason
+ img._top = img.offsetTop;
+ }
+ e.dataTransfer.setDragImage(img, 0, 0);
+ if (presto) img.parentNode.removeChild(img);
+ }
+ }
+
+ // SCROLL EVENTS
+
+ // Sync the scrollable area and scrollbars, ensure the viewport
+ // covers the visible area.
+ function setScrollTop(cm, val) {
+ if (Math.abs(cm.doc.scrollTop - val) < 2) return;
+ cm.doc.scrollTop = val;
+ if (!gecko) updateDisplay(cm, {top: val});
+ if (cm.display.scroller.scrollTop != val) cm.display.scroller.scrollTop = val;
+ if (cm.display.scrollbarV.scrollTop != val) cm.display.scrollbarV.scrollTop = val;
+ if (gecko) updateDisplay(cm);
+ startWorker(cm, 100);
+ }
+ // Sync scroller and scrollbar, ensure the gutter elements are
+ // aligned.
+ function setScrollLeft(cm, val, isScroller) {
+ if (isScroller ? val == cm.doc.scrollLeft : Math.abs(cm.doc.scrollLeft - val) < 2) return;
+ val = Math.min(val, cm.display.scroller.scrollWidth - cm.display.scroller.clientWidth);
+ cm.doc.scrollLeft = val;
+ alignHorizontally(cm);
+ if (cm.display.scroller.scrollLeft != val) cm.display.scroller.scrollLeft = val;
+ if (cm.display.scrollbarH.scrollLeft != val) cm.display.scrollbarH.scrollLeft = val;
+ }
+
+ // Since the delta values reported on mouse wheel events are
+ // unstandardized between browsers and even browser versions, and
+ // generally horribly unpredictable, this code starts by measuring
+ // the scroll effect that the first few mouse wheel events have,
+ // and, from that, detects the way it can convert deltas to pixel
+ // offsets afterwards.
+ //
+ // The reason we want to know the amount a wheel event will scroll
+ // is that it gives us a chance to update the display before the
+ // actual scrolling happens, reducing flickering.
+
+ var wheelSamples = 0, wheelPixelsPerUnit = null;
+ // Fill in a browser-detected starting value on browsers where we
+ // know one. These don't have to be accurate -- the result of them
+ // being wrong would just be a slight flicker on the first wheel
+ // scroll (if it is large enough).
+ if (ie) wheelPixelsPerUnit = -.53;
+ else if (gecko) wheelPixelsPerUnit = 15;
+ else if (chrome) wheelPixelsPerUnit = -.7;
+ else if (safari) wheelPixelsPerUnit = -1/3;
+
+ function onScrollWheel(cm, e) {
+ var dx = e.wheelDeltaX, dy = e.wheelDeltaY;
+ if (dx == null && e.detail && e.axis == e.HORIZONTAL_AXIS) dx = e.detail;
+ if (dy == null && e.detail && e.axis == e.VERTICAL_AXIS) dy = e.detail;
+ else if (dy == null) dy = e.wheelDelta;
+
+ var display = cm.display, scroll = display.scroller;
+ // Quit if there's nothing to scroll here
+ if (!(dx && scroll.scrollWidth > scroll.clientWidth ||
+ dy && scroll.scrollHeight > scroll.clientHeight)) return;
+
+ // Webkit browsers on OS X abort momentum scrolls when the target
+ // of the scroll event is removed from the scrollable element.
+ // This hack (see related code in patchDisplay) makes sure the
+ // element is kept around.
+ if (dy && mac && webkit) {
+ outer: for (var cur = e.target, view = display.view; cur != scroll; cur = cur.parentNode) {
+ for (var i = 0; i < view.length; i++) {
+ if (view[i].node == cur) {
+ cm.display.currentWheelTarget = cur;
+ break outer;
+ }
+ }
+ }
+ }
+
+ // On some browsers, horizontal scrolling will cause redraws to
+ // happen before the gutter has been realigned, causing it to
+ // wriggle around in a most unseemly way. When we have an
+ // estimated pixels/delta value, we just handle horizontal
+ // scrolling entirely here. It'll be slightly off from native, but
+ // better than glitching out.
+ if (dx && !gecko && !presto && wheelPixelsPerUnit != null) {
+ if (dy)
+ setScrollTop(cm, Math.max(0, Math.min(scroll.scrollTop + dy * wheelPixelsPerUnit, scroll.scrollHeight - scroll.clientHeight)));
+ setScrollLeft(cm, Math.max(0, Math.min(scroll.scrollLeft + dx * wheelPixelsPerUnit, scroll.scrollWidth - scroll.clientWidth)));
+ e_preventDefault(e);
+ display.wheelStartX = null; // Abort measurement, if in progress
+ return;
+ }
+
+ // 'Project' the visible viewport to cover the area that is being
+ // scrolled into view (if we know enough to estimate it).
+ if (dy && wheelPixelsPerUnit != null) {
+ var pixels = dy * wheelPixelsPerUnit;
+ var top = cm.doc.scrollTop, bot = top + display.wrapper.clientHeight;
+ if (pixels < 0) top = Math.max(0, top + pixels - 50);
+ else bot = Math.min(cm.doc.height, bot + pixels + 50);
+ updateDisplay(cm, {top: top, bottom: bot});
+ }
+
+ if (wheelSamples < 20) {
+ if (display.wheelStartX == null) {
+ display.wheelStartX = scroll.scrollLeft; display.wheelStartY = scroll.scrollTop;
+ display.wheelDX = dx; display.wheelDY = dy;
+ setTimeout(function() {
+ if (display.wheelStartX == null) return;
+ var movedX = scroll.scrollLeft - display.wheelStartX;
+ var movedY = scroll.scrollTop - display.wheelStartY;
+ var sample = (movedY && display.wheelDY && movedY / display.wheelDY) ||
+ (movedX && display.wheelDX && movedX / display.wheelDX);
+ display.wheelStartX = display.wheelStartY = null;
+ if (!sample) return;
+ wheelPixelsPerUnit = (wheelPixelsPerUnit * wheelSamples + sample) / (wheelSamples + 1);
+ ++wheelSamples;
+ }, 200);
+ } else {
+ display.wheelDX += dx; display.wheelDY += dy;
+ }
+ }
+ }
+
+ // KEY EVENTS
+
+ // Run a handler that was bound to a key.
+ function doHandleBinding(cm, bound, dropShift) {
+ if (typeof bound == "string") {
+ bound = commands[bound];
+ if (!bound) return false;
+ }
+ // Ensure previous input has been read, so that the handler sees a
+ // consistent view of the document
+ if (cm.display.pollingFast && readInput(cm)) cm.display.pollingFast = false;
+ var prevShift = cm.display.shift, done = false;
+ try {
+ if (isReadOnly(cm)) cm.state.suppressEdits = true;
+ if (dropShift) cm.display.shift = false;
+ done = bound(cm) != Pass;
+ } finally {
+ cm.display.shift = prevShift;
+ cm.state.suppressEdits = false;
+ }
+ return done;
+ }
+
+ // Collect the currently active keymaps.
+ function allKeyMaps(cm) {
+ var maps = cm.state.keyMaps.slice(0);
+ if (cm.options.extraKeys) maps.push(cm.options.extraKeys);
+ maps.push(cm.options.keyMap);
+ return maps;
+ }
+
+ var maybeTransition;
+ // Handle a key from the keydown event.
+ function handleKeyBinding(cm, e) {
+ // Handle automatic keymap transitions
+ var startMap = getKeyMap(cm.options.keyMap), next = startMap.auto;
+ clearTimeout(maybeTransition);
+ if (next && !isModifierKey(e)) maybeTransition = setTimeout(function() {
+ if (getKeyMap(cm.options.keyMap) == startMap) {
+ cm.options.keyMap = (next.call ? next.call(null, cm) : next);
+ keyMapChanged(cm);
+ }
+ }, 50);
+
+ var name = keyName(e, true), handled = false;
+ if (!name) return false;
+ var keymaps = allKeyMaps(cm);
+
+ if (e.shiftKey) {
+ // First try to resolve full name (including 'Shift-'). Failing
+ // that, see if there is a cursor-motion command (starting with
+ // 'go') bound to the keyname without 'Shift-'.
+ handled = lookupKey("Shift-" + name, keymaps, function(b) {return doHandleBinding(cm, b, true);})
+ || lookupKey(name, keymaps, function(b) {
+ if (typeof b == "string" ? /^go[A-Z]/.test(b) : b.motion)
+ return doHandleBinding(cm, b);
+ });
+ } else {
+ handled = lookupKey(name, keymaps, function(b) { return doHandleBinding(cm, b); });
+ }
+
+ if (handled) {
+ e_preventDefault(e);
+ restartBlink(cm);
+ signalLater(cm, "keyHandled", cm, name, e);
+ }
+ return handled;
+ }
+
+ // Handle a key from the keypress event
+ function handleCharBinding(cm, e, ch) {
+ var handled = lookupKey("'" + ch + "'", allKeyMaps(cm),
+ function(b) { return doHandleBinding(cm, b, true); });
+ if (handled) {
+ e_preventDefault(e);
+ restartBlink(cm);
+ signalLater(cm, "keyHandled", cm, "'" + ch + "'", e);
+ }
+ return handled;
+ }
+
+ var lastStoppedKey = null;
+ function onKeyDown(e) {
+ var cm = this;
+ ensureFocus(cm);
+ if (signalDOMEvent(cm, e)) return;
+ // IE does strange things with escape.
+ if (ie_upto10 && e.keyCode == 27) e.returnValue = false;
+ var code = e.keyCode;
+ cm.display.shift = code == 16 || e.shiftKey;
+ var handled = handleKeyBinding(cm, e);
+ if (presto) {
+ lastStoppedKey = handled ? code : null;
+ // Opera has no cut event... we try to at least catch the key combo
+ if (!handled && code == 88 && !hasCopyEvent && (mac ? e.metaKey : e.ctrlKey))
+ cm.replaceSelection("", null, "cut");
+ }
+
+ // Turn mouse into crosshair when Alt is held on Mac.
+ if (code == 18 && !/\bCodeMirror-crosshair\b/.test(cm.display.lineDiv.className))
+ showCrossHair(cm);
+ }
+
+ function showCrossHair(cm) {
+ var lineDiv = cm.display.lineDiv;
+ addClass(lineDiv, "CodeMirror-crosshair");
+
+ function up(e) {
+ if (e.keyCode == 18 || !e.altKey) {
+ rmClass(lineDiv, "CodeMirror-crosshair");
+ off(document, "keyup", up);
+ off(document, "mouseover", up);
+ }
+ }
+ on(document, "keyup", up);
+ on(document, "mouseover", up);
+ }
+
+ function onKeyUp(e) {
+ if (signalDOMEvent(this, e)) return;
+ if (e.keyCode == 16) this.doc.sel.shift = false;
+ }
+
+ function onKeyPress(e) {
+ var cm = this;
+ if (signalDOMEvent(cm, e)) return;
+ var keyCode = e.keyCode, charCode = e.charCode;
+ if (presto && keyCode == lastStoppedKey) {lastStoppedKey = null; e_preventDefault(e); return;}
+ if (((presto && (!e.which || e.which < 10)) || khtml) && handleKeyBinding(cm, e)) return;
+ var ch = String.fromCharCode(charCode == null ? keyCode : charCode);
+ if (handleCharBinding(cm, e, ch)) return;
+ if (ie && !ie_upto8) cm.display.inputHasSelection = null;
+ fastPoll(cm);
+ }
+
+ // FOCUS/BLUR EVENTS
+
+ function onFocus(cm) {
+ if (cm.options.readOnly == "nocursor") return;
+ if (!cm.state.focused) {
+ signal(cm, "focus", cm);
+ cm.state.focused = true;
+ addClass(cm.display.wrapper, "CodeMirror-focused");
+ // The prevInput test prevents this from firing when a context
+ // menu is closed (since the resetInput would kill the
+ // select-all detection hack)
+ if (!cm.curOp && cm.display.selForContextMenu == cm.doc.sel) {
+ resetInput(cm);
+ if (webkit) setTimeout(bind(resetInput, cm, true), 0); // Issue #1730
+ }
+ }
+ slowPoll(cm);
+ restartBlink(cm);
+ }
+ function onBlur(cm) {
+ if (cm.state.focused) {
+ signal(cm, "blur", cm);
+ cm.state.focused = false;
+ rmClass(cm.display.wrapper, "CodeMirror-focused");
+ }
+ clearInterval(cm.display.blinker);
+ setTimeout(function() {if (!cm.state.focused) cm.display.shift = false;}, 150);
+ }
+
+ // CONTEXT MENU HANDLING
+
+ var detectingSelectAll;
+ // To make the context menu work, we need to briefly unhide the
+ // textarea (making it as unobtrusive as possible) to let the
+ // right-click take effect on it.
+ function onContextMenu(cm, e) {
+ if (signalDOMEvent(cm, e, "contextmenu")) return;
+ var display = cm.display;
+ if (eventInWidget(display, e) || contextMenuInGutter(cm, e)) return;
+
+ var pos = posFromMouse(cm, e), scrollPos = display.scroller.scrollTop;
+ if (!pos || presto) return; // Opera is difficult.
+
+ // Reset the current text selection only if the click is done outside of the selection
+ // and 'resetSelectionOnContextMenu' option is true.
+ var reset = cm.options.resetSelectionOnContextMenu;
+ if (reset && cm.doc.sel.contains(pos) == -1)
+ operation(cm, setSelection)(cm.doc, simpleSelection(pos), sel_dontScroll);
+
+ var oldCSS = display.input.style.cssText;
+ display.inputDiv.style.position = "absolute";
+ display.input.style.cssText = "position: fixed; width: 30px; height: 30px; top: " + (e.clientY - 5) +
+ "px; left: " + (e.clientX - 5) + "px; z-index: 1000; background: " +
+ (ie ? "rgba(255, 255, 255, .05)" : "transparent") +
+ "; outline: none; border-width: 0; outline: none; overflow: hidden; opacity: .05; filter: alpha(opacity=5);";
+ focusInput(cm);
+ resetInput(cm);
+ // Adds "Select all" to context menu in FF
+ if (!cm.somethingSelected()) display.input.value = display.prevInput = " ";
+ display.selForContextMenu = cm.doc.sel;
+
+ // Select-all will be greyed out if there's nothing to select, so
+ // this adds a zero-width space so that we can later check whether
+ // it got selected.
+ function prepareSelectAllHack() {
+ if (display.input.selectionStart != null) {
+ var selected = cm.somethingSelected();
+ var extval = display.input.value = "\u200b" + (selected ? display.input.value : "");
+ display.prevInput = selected ? "" : "\u200b";
+ display.input.selectionStart = 1; display.input.selectionEnd = extval.length;
+ }
+ }
+ function rehide() {
+ display.inputDiv.style.position = "relative";
+ display.input.style.cssText = oldCSS;
+ if (ie_upto8) display.scrollbarV.scrollTop = display.scroller.scrollTop = scrollPos;
+ slowPoll(cm);
+
+ // Try to detect the user choosing select-all
+ if (display.input.selectionStart != null) {
+ if (!ie || ie_upto8) prepareSelectAllHack();
+ clearTimeout(detectingSelectAll);
+ var i = 0, poll = function() {
+ if (display.selForContextMenu == cm.doc.sel && display.input.selectionStart == 0)
+ operation(cm, commands.selectAll)(cm);
+ else if (i++ < 10) detectingSelectAll = setTimeout(poll, 500);
+ else resetInput(cm);
+ };
+ detectingSelectAll = setTimeout(poll, 200);
+ }
+ }
+
+ if (ie && !ie_upto8) prepareSelectAllHack();
+ if (captureRightClick) {
+ e_stop(e);
+ var mouseup = function() {
+ off(window, "mouseup", mouseup);
+ setTimeout(rehide, 20);
+ };
+ on(window, "mouseup", mouseup);
+ } else {
+ setTimeout(rehide, 50);
+ }
+ }
+
+ function contextMenuInGutter(cm, e) {
+ if (!hasHandler(cm, "gutterContextMenu")) return false;
+ return gutterEvent(cm, e, "gutterContextMenu", false, signal);
+ }
+
+ // UPDATING
+
+ // Compute the position of the end of a change (its 'to' property
+ // refers to the pre-change end).
+ var changeEnd = CodeMirror.changeEnd = function(change) {
+ if (!change.text) return change.to;
+ return Pos(change.from.line + change.text.length - 1,
+ lst(change.text).length + (change.text.length == 1 ? change.from.ch : 0));
+ };
+
+ // Adjust a position to refer to the post-change position of the
+ // same text, or the end of the change if the change covers it.
+ function adjustForChange(pos, change) {
+ if (cmp(pos, change.from) < 0) return pos;
+ if (cmp(pos, change.to) <= 0) return changeEnd(change);
+
+ var line = pos.line + change.text.length - (change.to.line - change.from.line) - 1, ch = pos.ch;
+ if (pos.line == change.to.line) ch += changeEnd(change).ch - change.to.ch;
+ return Pos(line, ch);
+ }
+
+ function computeSelAfterChange(doc, change) {
+ var out = [];
+ for (var i = 0; i < doc.sel.ranges.length; i++) {
+ var range = doc.sel.ranges[i];
+ out.push(new Range(adjustForChange(range.anchor, change),
+ adjustForChange(range.head, change)));
+ }
+ return normalizeSelection(out, doc.sel.primIndex);
+ }
+
+ function offsetPos(pos, old, nw) {
+ if (pos.line == old.line)
+ return Pos(nw.line, pos.ch - old.ch + nw.ch);
+ else
+ return Pos(nw.line + (pos.line - old.line), pos.ch);
+ }
+
+ // Used by replaceSelections to allow moving the selection to the
+ // start or around the replaced test. Hint may be "start" or "around".
+ function computeReplacedSel(doc, changes, hint) {
+ var out = [];
+ var oldPrev = Pos(doc.first, 0), newPrev = oldPrev;
+ for (var i = 0; i < changes.length; i++) {
+ var change = changes[i];
+ var from = offsetPos(change.from, oldPrev, newPrev);
+ var to = offsetPos(changeEnd(change), oldPrev, newPrev);
+ oldPrev = change.to;
+ newPrev = to;
+ if (hint == "around") {
+ var range = doc.sel.ranges[i], inv = cmp(range.head, range.anchor) < 0;
+ out[i] = new Range(inv ? to : from, inv ? from : to);
+ } else {
+ out[i] = new Range(from, from);
+ }
+ }
+ return new Selection(out, doc.sel.primIndex);
+ }
+
+ // Allow "beforeChange" event handlers to influence a change
+ function filterChange(doc, change, update) {
+ var obj = {
+ canceled: false,
+ from: change.from,
+ to: change.to,
+ text: change.text,
+ origin: change.origin,
+ cancel: function() { this.canceled = true; }
+ };
+ if (update) obj.update = function(from, to, text, origin) {
+ if (from) this.from = clipPos(doc, from);
+ if (to) this.to = clipPos(doc, to);
+ if (text) this.text = text;
+ if (origin !== undefined) this.origin = origin;
+ };
+ signal(doc, "beforeChange", doc, obj);
+ if (doc.cm) signal(doc.cm, "beforeChange", doc.cm, obj);
+
+ if (obj.canceled) return null;
+ return {from: obj.from, to: obj.to, text: obj.text, origin: obj.origin};
+ }
+
+ // Apply a change to a document, and add it to the document's
+ // history, and propagating it to all linked documents.
+ function makeChange(doc, change, ignoreReadOnly) {
+ if (doc.cm) {
+ if (!doc.cm.curOp) return operation(doc.cm, makeChange)(doc, change, ignoreReadOnly);
+ if (doc.cm.state.suppressEdits) return;
+ }
+
+ if (hasHandler(doc, "beforeChange") || doc.cm && hasHandler(doc.cm, "beforeChange")) {
+ change = filterChange(doc, change, true);
+ if (!change) return;
+ }
+
+ // Possibly split or suppress the update based on the presence
+ // of read-only spans in its range.
+ var split = sawReadOnlySpans && !ignoreReadOnly && removeReadOnlyRanges(doc, change.from, change.to);
+ if (split) {
+ for (var i = split.length - 1; i >= 0; --i)
+ makeChangeInner(doc, {from: split[i].from, to: split[i].to, text: i ? [""] : change.text});
+ } else {
+ makeChangeInner(doc, change);
+ }
+ }
+
+ function makeChangeInner(doc, change) {
+ if (change.text.length == 1 && change.text[0] == "" && cmp(change.from, change.to) == 0) return;
+ var selAfter = computeSelAfterChange(doc, change);
+ addChangeToHistory(doc, change, selAfter, doc.cm ? doc.cm.curOp.id : NaN);
+
+ makeChangeSingleDoc(doc, change, selAfter, stretchSpansOverChange(doc, change));
+ var rebased = [];
+
+ linkedDocs(doc, function(doc, sharedHist) {
+ if (!sharedHist && indexOf(rebased, doc.history) == -1) {
+ rebaseHist(doc.history, change);
+ rebased.push(doc.history);
+ }
+ makeChangeSingleDoc(doc, change, null, stretchSpansOverChange(doc, change));
+ });
+ }
+
+ // Revert a change stored in a document's history.
+ function makeChangeFromHistory(doc, type, allowSelectionOnly) {
+ if (doc.cm && doc.cm.state.suppressEdits) return;
+
+ var hist = doc.history, event, selAfter = doc.sel;
+ var source = type == "undo" ? hist.done : hist.undone, dest = type == "undo" ? hist.undone : hist.done;
+
+ // Verify that there is a useable event (so that ctrl-z won't
+ // needlessly clear selection events)
+ for (var i = 0; i < source.length; i++) {
+ event = source[i];
+ if (allowSelectionOnly ? event.ranges && !event.equals(doc.sel) : !event.ranges)
+ break;
+ }
+ if (i == source.length) return;
+ hist.lastOrigin = hist.lastSelOrigin = null;
+
+ for (;;) {
+ event = source.pop();
+ if (event.ranges) {
+ pushSelectionToHistory(event, dest);
+ if (allowSelectionOnly && !event.equals(doc.sel)) {
+ setSelection(doc, event, {clearRedo: false});
+ return;
+ }
+ selAfter = event;
+ }
+ else break;
+ }
+
+ // Build up a reverse change object to add to the opposite history
+ // stack (redo when undoing, and vice versa).
+ var antiChanges = [];
+ pushSelectionToHistory(selAfter, dest);
+ dest.push({changes: antiChanges, generation: hist.generation});
+ hist.generation = event.generation || ++hist.maxGeneration;
+
+ var filter = hasHandler(doc, "beforeChange") || doc.cm && hasHandler(doc.cm, "beforeChange");
+
+ for (var i = event.changes.length - 1; i >= 0; --i) {
+ var change = event.changes[i];
+ change.origin = type;
+ if (filter && !filterChange(doc, change, false)) {
+ source.length = 0;
+ return;
+ }
+
+ antiChanges.push(historyChangeFromChange(doc, change));
+
+ var after = i ? computeSelAfterChange(doc, change, null) : lst(source);
+ makeChangeSingleDoc(doc, change, after, mergeOldSpans(doc, change));
+ if (doc.cm) ensureCursorVisible(doc.cm);
+ var rebased = [];
+
+ // Propagate to the linked documents
+ linkedDocs(doc, function(doc, sharedHist) {
+ if (!sharedHist && indexOf(rebased, doc.history) == -1) {
+ rebaseHist(doc.history, change);
+ rebased.push(doc.history);
+ }
+ makeChangeSingleDoc(doc, change, null, mergeOldSpans(doc, change));
+ });
+ }
+ }
+
+ // Sub-views need their line numbers shifted when text is added
+ // above or below them in the parent document.
+ function shiftDoc(doc, distance) {
+ doc.first += distance;
+ doc.sel = new Selection(map(doc.sel.ranges, function(range) {
+ return new Range(Pos(range.anchor.line + distance, range.anchor.ch),
+ Pos(range.head.line + distance, range.head.ch));
+ }), doc.sel.primIndex);
+ if (doc.cm) regChange(doc.cm, doc.first, doc.first - distance, distance);
+ }
+
+ // More lower-level change function, handling only a single document
+ // (not linked ones).
+ function makeChangeSingleDoc(doc, change, selAfter, spans) {
+ if (doc.cm && !doc.cm.curOp)
+ return operation(doc.cm, makeChangeSingleDoc)(doc, change, selAfter, spans);
+
+ if (change.to.line < doc.first) {
+ shiftDoc(doc, change.text.length - 1 - (change.to.line - change.from.line));
+ return;
+ }
+ if (change.from.line > doc.lastLine()) return;
+
+ // Clip the change to the size of this doc
+ if (change.from.line < doc.first) {
+ var shift = change.text.length - 1 - (doc.first - change.from.line);
+ shiftDoc(doc, shift);
+ change = {from: Pos(doc.first, 0), to: Pos(change.to.line + shift, change.to.ch),
+ text: [lst(change.text)], origin: change.origin};
+ }
+ var last = doc.lastLine();
+ if (change.to.line > last) {
+ change = {from: change.from, to: Pos(last, getLine(doc, last).text.length),
+ text: [change.text[0]], origin: change.origin};
+ }
+
+ change.removed = getBetween(doc, change.from, change.to);
+
+ if (!selAfter) selAfter = computeSelAfterChange(doc, change, null);
+ if (doc.cm) makeChangeSingleDocInEditor(doc.cm, change, spans);
+ else updateDoc(doc, change, spans);
+ setSelectionNoUndo(doc, selAfter, sel_dontScroll);
+ }
+
+ // Handle the interaction of a change to a document with the editor
+ // that this document is part of.
+ function makeChangeSingleDocInEditor(cm, change, spans) {
+ var doc = cm.doc, display = cm.display, from = change.from, to = change.to;
+
+ var recomputeMaxLength = false, checkWidthStart = from.line;
+ if (!cm.options.lineWrapping) {
+ checkWidthStart = lineNo(visualLine(getLine(doc, from.line)));
+ doc.iter(checkWidthStart, to.line + 1, function(line) {
+ if (line == display.maxLine) {
+ recomputeMaxLength = true;
+ return true;
+ }
+ });
+ }
+
+ if (doc.sel.contains(change.from, change.to) > -1)
+ signalCursorActivity(cm);
+
+ updateDoc(doc, change, spans, estimateHeight(cm));
+
+ if (!cm.options.lineWrapping) {
+ doc.iter(checkWidthStart, from.line + change.text.length, function(line) {
+ var len = lineLength(line);
+ if (len > display.maxLineLength) {
+ display.maxLine = line;
+ display.maxLineLength = len;
+ display.maxLineChanged = true;
+ recomputeMaxLength = false;
+ }
+ });
+ if (recomputeMaxLength) cm.curOp.updateMaxLine = true;
+ }
+
+ // Adjust frontier, schedule worker
+ doc.frontier = Math.min(doc.frontier, from.line);
+ startWorker(cm, 400);
+
+ var lendiff = change.text.length - (to.line - from.line) - 1;
+ // Remember that these lines changed, for updating the display
+ if (from.line == to.line && change.text.length == 1 && !isWholeLineUpdate(cm.doc, change))
+ regLineChange(cm, from.line, "text");
+ else
+ regChange(cm, from.line, to.line + 1, lendiff);
+
+ var changesHandler = hasHandler(cm, "changes"), changeHandler = hasHandler(cm, "change");
+ if (changeHandler || changesHandler) {
+ var obj = {
+ from: from, to: to,
+ text: change.text,
+ removed: change.removed,
+ origin: change.origin
+ };
+ if (changeHandler) signalLater(cm, "change", cm, obj);
+ if (changesHandler) (cm.curOp.changeObjs || (cm.curOp.changeObjs = [])).push(obj);
+ }
+ }
+
+ function replaceRange(doc, code, from, to, origin) {
+ if (!to) to = from;
+ if (cmp(to, from) < 0) { var tmp = to; to = from; from = tmp; }
+ if (typeof code == "string") code = splitLines(code);
+ makeChange(doc, {from: from, to: to, text: code, origin: origin});
+ }
+
+ // SCROLLING THINGS INTO VIEW
+
+ // If an editor sits on the top or bottom of the window, partially
+ // scrolled out of view, this ensures that the cursor is visible.
+ function maybeScrollWindow(cm, coords) {
+ var display = cm.display, box = display.sizer.getBoundingClientRect(), doScroll = null;
+ if (coords.top + box.top < 0) doScroll = true;
+ else if (coords.bottom + box.top > (window.innerHeight || document.documentElement.clientHeight)) doScroll = false;
+ if (doScroll != null && !phantom) {
+ var scrollNode = elt("div", "\u200b", null, "position: absolute; top: " +
+ (coords.top - display.viewOffset - paddingTop(cm.display)) + "px; height: " +
+ (coords.bottom - coords.top + scrollerCutOff) + "px; left: " +
+ coords.left + "px; width: 2px;");
+ cm.display.lineSpace.appendChild(scrollNode);
+ scrollNode.scrollIntoView(doScroll);
+ cm.display.lineSpace.removeChild(scrollNode);
+ }
+ }
+
+ // Scroll a given position into view (immediately), verifying that
+ // it actually became visible (as line heights are accurately
+ // measured, the position of something may 'drift' during drawing).
+ function scrollPosIntoView(cm, pos, end, margin) {
+ if (margin == null) margin = 0;
+ for (;;) {
+ var changed = false, coords = cursorCoords(cm, pos);
+ var endCoords = !end || end == pos ? coords : cursorCoords(cm, end);
+ var scrollPos = calculateScrollPos(cm, Math.min(coords.left, endCoords.left),
+ Math.min(coords.top, endCoords.top) - margin,
+ Math.max(coords.left, endCoords.left),
+ Math.max(coords.bottom, endCoords.bottom) + margin);
+ var startTop = cm.doc.scrollTop, startLeft = cm.doc.scrollLeft;
+ if (scrollPos.scrollTop != null) {
+ setScrollTop(cm, scrollPos.scrollTop);
+ if (Math.abs(cm.doc.scrollTop - startTop) > 1) changed = true;
+ }
+ if (scrollPos.scrollLeft != null) {
+ setScrollLeft(cm, scrollPos.scrollLeft);
+ if (Math.abs(cm.doc.scrollLeft - startLeft) > 1) changed = true;
+ }
+ if (!changed) return coords;
+ }
+ }
+
+ // Scroll a given set of coordinates into view (immediately).
+ function scrollIntoView(cm, x1, y1, x2, y2) {
+ var scrollPos = calculateScrollPos(cm, x1, y1, x2, y2);
+ if (scrollPos.scrollTop != null) setScrollTop(cm, scrollPos.scrollTop);
+ if (scrollPos.scrollLeft != null) setScrollLeft(cm, scrollPos.scrollLeft);
+ }
+
+ // Calculate a new scroll position needed to scroll the given
+ // rectangle into view. Returns an object with scrollTop and
+ // scrollLeft properties. When these are undefined, the
+ // vertical/horizontal position does not need to be adjusted.
+ function calculateScrollPos(cm, x1, y1, x2, y2) {
+ var display = cm.display, snapMargin = textHeight(cm.display);
+ if (y1 < 0) y1 = 0;
+ var screentop = cm.curOp && cm.curOp.scrollTop != null ? cm.curOp.scrollTop : display.scroller.scrollTop;
+ var screen = display.scroller.clientHeight - scrollerCutOff, result = {};
+ var docBottom = cm.doc.height + paddingVert(display);
+ var atTop = y1 < snapMargin, atBottom = y2 > docBottom - snapMargin;
+ if (y1 < screentop) {
+ result.scrollTop = atTop ? 0 : y1;
+ } else if (y2 > screentop + screen) {
+ var newTop = Math.min(y1, (atBottom ? docBottom : y2) - screen);
+ if (newTop != screentop) result.scrollTop = newTop;
+ }
+
+ var screenleft = cm.curOp && cm.curOp.scrollLeft != null ? cm.curOp.scrollLeft : display.scroller.scrollLeft;
+ var screenw = display.scroller.clientWidth - scrollerCutOff;
+ x1 += display.gutters.offsetWidth; x2 += display.gutters.offsetWidth;
+ var gutterw = display.gutters.offsetWidth;
+ var atLeft = x1 < gutterw + 10;
+ if (x1 < screenleft + gutterw || atLeft) {
+ if (atLeft) x1 = 0;
+ result.scrollLeft = Math.max(0, x1 - 10 - gutterw);
+ } else if (x2 > screenw + screenleft - 3) {
+ result.scrollLeft = x2 + 10 - screenw;
+ }
+ return result;
+ }
+
+ // Store a relative adjustment to the scroll position in the current
+ // operation (to be applied when the operation finishes).
+ function addToScrollPos(cm, left, top) {
+ if (left != null || top != null) resolveScrollToPos(cm);
+ if (left != null)
+ cm.curOp.scrollLeft = (cm.curOp.scrollLeft == null ? cm.doc.scrollLeft : cm.curOp.scrollLeft) + left;
+ if (top != null)
+ cm.curOp.scrollTop = (cm.curOp.scrollTop == null ? cm.doc.scrollTop : cm.curOp.scrollTop) + top;
+ }
+
+ // Make sure that at the end of the operation the current cursor is
+ // shown.
+ function ensureCursorVisible(cm) {
+ resolveScrollToPos(cm);
+ var cur = cm.getCursor(), from = cur, to = cur;
+ if (!cm.options.lineWrapping) {
+ from = cur.ch ? Pos(cur.line, cur.ch - 1) : cur;
+ to = Pos(cur.line, cur.ch + 1);
+ }
+ cm.curOp.scrollToPos = {from: from, to: to, margin: cm.options.cursorScrollMargin, isCursor: true};
+ }
+
+ // When an operation has its scrollToPos property set, and another
+ // scroll action is applied before the end of the operation, this
+ // 'simulates' scrolling that position into view in a cheap way, so
+ // that the effect of intermediate scroll commands is not ignored.
+ function resolveScrollToPos(cm) {
+ var range = cm.curOp.scrollToPos;
+ if (range) {
+ cm.curOp.scrollToPos = null;
+ var from = estimateCoords(cm, range.from), to = estimateCoords(cm, range.to);
+ var sPos = calculateScrollPos(cm, Math.min(from.left, to.left),
+ Math.min(from.top, to.top) - range.margin,
+ Math.max(from.right, to.right),
+ Math.max(from.bottom, to.bottom) + range.margin);
+ cm.scrollTo(sPos.scrollLeft, sPos.scrollTop);
+ }
+ }
+
+ // API UTILITIES
+
+ // Indent the given line. The how parameter can be "smart",
+ // "add"/null, "subtract", or "prev". When aggressive is false
+ // (typically set to true for forced single-line indents), empty
+ // lines are not indented, and places where the mode returns Pass
+ // are left alone.
+ function indentLine(cm, n, how, aggressive) {
+ var doc = cm.doc, state;
+ if (how == null) how = "add";
+ if (how == "smart") {
+ // Fall back to "prev" when the mode doesn't have an indentation
+ // method.
+ if (!cm.doc.mode.indent) how = "prev";
+ else state = getStateBefore(cm, n);
+ }
+
+ var tabSize = cm.options.tabSize;
+ var line = getLine(doc, n), curSpace = countColumn(line.text, null, tabSize);
+ if (line.stateAfter) line.stateAfter = null;
+ var curSpaceString = line.text.match(/^\s*/)[0], indentation;
+ if (!aggressive && !/\S/.test(line.text)) {
+ indentation = 0;
+ how = "not";
+ } else if (how == "smart") {
+ indentation = cm.doc.mode.indent(state, line.text.slice(curSpaceString.length), line.text);
+ if (indentation == Pass) {
+ if (!aggressive) return;
+ how = "prev";
+ }
+ }
+ if (how == "prev") {
+ if (n > doc.first) indentation = countColumn(getLine(doc, n-1).text, null, tabSize);
+ else indentation = 0;
+ } else if (how == "add") {
+ indentation = curSpace + cm.options.indentUnit;
+ } else if (how == "subtract") {
+ indentation = curSpace - cm.options.indentUnit;
+ } else if (typeof how == "number") {
+ indentation = curSpace + how;
+ }
+ indentation = Math.max(0, indentation);
+
+ var indentString = "", pos = 0;
+ if (cm.options.indentWithTabs)
+ for (var i = Math.floor(indentation / tabSize); i; --i) {pos += tabSize; indentString += "\t";}
+ if (pos < indentation) indentString += spaceStr(indentation - pos);
+
+ if (indentString != curSpaceString) {
+ replaceRange(cm.doc, indentString, Pos(n, 0), Pos(n, curSpaceString.length), "+input");
+ } else {
+ // Ensure that, if the cursor was in the whitespace at the start
+ // of the line, it is moved to the end of that space.
+ for (var i = 0; i < doc.sel.ranges.length; i++) {
+ var range = doc.sel.ranges[i];
+ if (range.head.line == n && range.head.ch < curSpaceString.length) {
+ var pos = Pos(n, curSpaceString.length);
+ replaceOneSelection(doc, i, new Range(pos, pos));
+ break;
+ }
+ }
+ }
+ line.stateAfter = null;
+ }
+
+ // Utility for applying a change to a line by handle or number,
+ // returning the number and optionally registering the line as
+ // changed.
+ function changeLine(cm, handle, changeType, op) {
+ var no = handle, line = handle, doc = cm.doc;
+ if (typeof handle == "number") line = getLine(doc, clipLine(doc, handle));
+ else no = lineNo(handle);
+ if (no == null) return null;
+ if (op(line, no)) regLineChange(cm, no, changeType);
+ return line;
+ }
+
+ // Helper for deleting text near the selection(s), used to implement
+ // backspace, delete, and similar functionality.
+ function deleteNearSelection(cm, compute) {
+ var ranges = cm.doc.sel.ranges, kill = [];
+ // Build up a set of ranges to kill first, merging overlapping
+ // ranges.
+ for (var i = 0; i < ranges.length; i++) {
+ var toKill = compute(ranges[i]);
+ while (kill.length && cmp(toKill.from, lst(kill).to) <= 0) {
+ var replaced = kill.pop();
+ if (cmp(replaced.from, toKill.from) < 0) {
+ toKill.from = replaced.from;
+ break;
+ }
+ }
+ kill.push(toKill);
+ }
+ // Next, remove those actual ranges.
+ runInOp(cm, function() {
+ for (var i = kill.length - 1; i >= 0; i--)
+ replaceRange(cm.doc, "", kill[i].from, kill[i].to, "+delete");
+ ensureCursorVisible(cm);
+ });
+ }
+
+ // Used for horizontal relative motion. Dir is -1 or 1 (left or
+ // right), unit can be "char", "column" (like char, but doesn't
+ // cross line boundaries), "word" (across next word), or "group" (to
+ // the start of next group of word or non-word-non-whitespace
+ // chars). The visually param controls whether, in right-to-left
+ // text, direction 1 means to move towards the next index in the
+ // string, or towards the character to the right of the current
+ // position. The resulting position will have a hitSide=true
+ // property if it reached the end of the document.
+ function findPosH(doc, pos, dir, unit, visually) {
+ var line = pos.line, ch = pos.ch, origDir = dir;
+ var lineObj = getLine(doc, line);
+ var possible = true;
+ function findNextLine() {
+ var l = line + dir;
+ if (l < doc.first || l >= doc.first + doc.size) return (possible = false);
+ line = l;
+ return lineObj = getLine(doc, l);
+ }
+ function moveOnce(boundToLine) {
+ var next = (visually ? moveVisually : moveLogically)(lineObj, ch, dir, true);
+ if (next == null) {
+ if (!boundToLine && findNextLine()) {
+ if (visually) ch = (dir < 0 ? lineRight : lineLeft)(lineObj);
+ else ch = dir < 0 ? lineObj.text.length : 0;
+ } else return (possible = false);
+ } else ch = next;
+ return true;
+ }
+
+ if (unit == "char") moveOnce();
+ else if (unit == "column") moveOnce(true);
+ else if (unit == "word" || unit == "group") {
+ var sawType = null, group = unit == "group";
+ for (var first = true;; first = false) {
+ if (dir < 0 && !moveOnce(!first)) break;
+ var cur = lineObj.text.charAt(ch) || "\n";
+ var type = isWordChar(cur) ? "w"
+ : group && cur == "\n" ? "n"
+ : !group || /\s/.test(cur) ? null
+ : "p";
+ if (group && !first && !type) type = "s";
+ if (sawType && sawType != type) {
+ if (dir < 0) {dir = 1; moveOnce();}
+ break;
+ }
+
+ if (type) sawType = type;
+ if (dir > 0 && !moveOnce(!first)) break;
+ }
+ }
+ var result = skipAtomic(doc, Pos(line, ch), origDir, true);
+ if (!possible) result.hitSide = true;
+ return result;
+ }
+
+ // For relative vertical movement. Dir may be -1 or 1. Unit can be
+ // "page" or "line". The resulting position will have a hitSide=true
+ // property if it reached the end of the document.
+ function findPosV(cm, pos, dir, unit) {
+ var doc = cm.doc, x = pos.left, y;
+ if (unit == "page") {
+ var pageSize = Math.min(cm.display.wrapper.clientHeight, window.innerHeight || document.documentElement.clientHeight);
+ y = pos.top + dir * (pageSize - (dir < 0 ? 1.5 : .5) * textHeight(cm.display));
+ } else if (unit == "line") {
+ y = dir > 0 ? pos.bottom + 3 : pos.top - 3;
+ }
+ for (;;) {
+ var target = coordsChar(cm, x, y);
+ if (!target.outside) break;
+ if (dir < 0 ? y <= 0 : y >= doc.height) { target.hitSide = true; break; }
+ y += dir * 5;
+ }
+ return target;
+ }
+
+ // Find the word at the given position (as returned by coordsChar).
+ function findWordAt(doc, pos) {
+ var line = getLine(doc, pos.line).text;
+ var start = pos.ch, end = pos.ch;
+ if (line) {
+ if ((pos.xRel < 0 || end == line.length) && start) --start; else ++end;
+ var startChar = line.charAt(start);
+ var check = isWordChar(startChar) ? isWordChar
+ : /\s/.test(startChar) ? function(ch) {return /\s/.test(ch);}
+ : function(ch) {return !/\s/.test(ch) && !isWordChar(ch);};
+ while (start > 0 && check(line.charAt(start - 1))) --start;
+ while (end < line.length && check(line.charAt(end))) ++end;
+ }
+ return new Range(Pos(pos.line, start), Pos(pos.line, end));
+ }
+
+ // EDITOR METHODS
+
+ // The publicly visible API. Note that methodOp(f) means
+ // 'wrap f in an operation, performed on its `this` parameter'.
+
+ // This is not the complete set of editor methods. Most of the
+ // methods defined on the Doc type are also injected into
+ // CodeMirror.prototype, for backwards compatibility and
+ // convenience.
+
+ CodeMirror.prototype = {
+ constructor: CodeMirror,
+ focus: function(){window.focus(); focusInput(this); fastPoll(this);},
+
+ setOption: function(option, value) {
+ var options = this.options, old = options[option];
+ if (options[option] == value && option != "mode") return;
+ options[option] = value;
+ if (optionHandlers.hasOwnProperty(option))
+ operation(this, optionHandlers[option])(this, value, old);
+ },
+
+ getOption: function(option) {return this.options[option];},
+ getDoc: function() {return this.doc;},
+
+ addKeyMap: function(map, bottom) {
+ this.state.keyMaps[bottom ? "push" : "unshift"](map);
+ },
+ removeKeyMap: function(map) {
+ var maps = this.state.keyMaps;
+ for (var i = 0; i < maps.length; ++i)
+ if (maps[i] == map || (typeof maps[i] != "string" && maps[i].name == map)) {
+ maps.splice(i, 1);
+ return true;
+ }
+ },
+
+ addOverlay: methodOp(function(spec, options) {
+ var mode = spec.token ? spec : CodeMirror.getMode(this.options, spec);
+ if (mode.startState) throw new Error("Overlays may not be stateful.");
+ this.state.overlays.push({mode: mode, modeSpec: spec, opaque: options && options.opaque});
+ this.state.modeGen++;
+ regChange(this);
+ }),
+ removeOverlay: methodOp(function(spec) {
+ var overlays = this.state.overlays;
+ for (var i = 0; i < overlays.length; ++i) {
+ var cur = overlays[i].modeSpec;
+ if (cur == spec || typeof spec == "string" && cur.name == spec) {
+ overlays.splice(i, 1);
+ this.state.modeGen++;
+ regChange(this);
+ return;
+ }
+ }
+ }),
+
+ indentLine: methodOp(function(n, dir, aggressive) {
+ if (typeof dir != "string" && typeof dir != "number") {
+ if (dir == null) dir = this.options.smartIndent ? "smart" : "prev";
+ else dir = dir ? "add" : "subtract";
+ }
+ if (isLine(this.doc, n)) indentLine(this, n, dir, aggressive);
+ }),
+ indentSelection: methodOp(function(how) {
+ var ranges = this.doc.sel.ranges, end = -1;
+ for (var i = 0; i < ranges.length; i++) {
+ var range = ranges[i];
+ if (!range.empty()) {
+ var start = Math.max(end, range.from().line);
+ var to = range.to();
+ end = Math.min(this.lastLine(), to.line - (to.ch ? 0 : 1)) + 1;
+ for (var j = start; j < end; ++j)
+ indentLine(this, j, how);
+ } else if (range.head.line > end) {
+ indentLine(this, range.head.line, how, true);
+ end = range.head.line;
+ if (i == this.doc.sel.primIndex) ensureCursorVisible(this);
+ }
+ }
+ }),
+
+ // Fetch the parser token for a given character. Useful for hacks
+ // that want to inspect the mode state (say, for completion).
+ getTokenAt: function(pos, precise) {
+ var doc = this.doc;
+ pos = clipPos(doc, pos);
+ var state = getStateBefore(this, pos.line, precise), mode = this.doc.mode;
+ var line = getLine(doc, pos.line);
+ var stream = new StringStream(line.text, this.options.tabSize);
+ while (stream.pos < pos.ch && !stream.eol()) {
+ stream.start = stream.pos;
+ var style = readToken(mode, stream, state);
+ }
+ return {start: stream.start,
+ end: stream.pos,
+ string: stream.current(),
+ type: style || null,
+ state: state};
+ },
+
+ getTokenTypeAt: function(pos) {
+ pos = clipPos(this.doc, pos);
+ var styles = getLineStyles(this, getLine(this.doc, pos.line));
+ var before = 0, after = (styles.length - 1) / 2, ch = pos.ch;
+ var type;
+ if (ch == 0) type = styles[2];
+ else for (;;) {
+ var mid = (before + after) >> 1;
+ if ((mid ? styles[mid * 2 - 1] : 0) >= ch) after = mid;
+ else if (styles[mid * 2 + 1] < ch) before = mid + 1;
+ else { type = styles[mid * 2 + 2]; break; }
+ }
+ var cut = type ? type.indexOf("cm-overlay ") : -1;
+ return cut < 0 ? type : cut == 0 ? null : type.slice(0, cut - 1);
+ },
+
+ getModeAt: function(pos) {
+ var mode = this.doc.mode;
+ if (!mode.innerMode) return mode;
+ return CodeMirror.innerMode(mode, this.getTokenAt(pos).state).mode;
+ },
+
+ getHelper: function(pos, type) {
+ return this.getHelpers(pos, type)[0];
+ },
+
+ getHelpers: function(pos, type) {
+ var found = [];
+ if (!helpers.hasOwnProperty(type)) return helpers;
+ var help = helpers[type], mode = this.getModeAt(pos);
+ if (typeof mode[type] == "string") {
+ if (help[mode[type]]) found.push(help[mode[type]]);
+ } else if (mode[type]) {
+ for (var i = 0; i < mode[type].length; i++) {
+ var val = help[mode[type][i]];
+ if (val) found.push(val);
+ }
+ } else if (mode.helperType && help[mode.helperType]) {
+ found.push(help[mode.helperType]);
+ } else if (help[mode.name]) {
+ found.push(help[mode.name]);
+ }
+ for (var i = 0; i < help._global.length; i++) {
+ var cur = help._global[i];
+ if (cur.pred(mode, this) && indexOf(found, cur.val) == -1)
+ found.push(cur.val);
+ }
+ return found;
+ },
+
+ getStateAfter: function(line, precise) {
+ var doc = this.doc;
+ line = clipLine(doc, line == null ? doc.first + doc.size - 1: line);
+ return getStateBefore(this, line + 1, precise);
+ },
+
+ cursorCoords: function(start, mode) {
+ var pos, range = this.doc.sel.primary();
+ if (start == null) pos = range.head;
+ else if (typeof start == "object") pos = clipPos(this.doc, start);
+ else pos = start ? range.from() : range.to();
+ return cursorCoords(this, pos, mode || "page");
+ },
+
+ charCoords: function(pos, mode) {
+ return charCoords(this, clipPos(this.doc, pos), mode || "page");
+ },
+
+ coordsChar: function(coords, mode) {
+ coords = fromCoordSystem(this, coords, mode || "page");
+ return coordsChar(this, coords.left, coords.top);
+ },
+
+ lineAtHeight: function(height, mode) {
+ height = fromCoordSystem(this, {top: height, left: 0}, mode || "page").top;
+ return lineAtHeight(this.doc, height + this.display.viewOffset);
+ },
+ heightAtLine: function(line, mode) {
+ var end = false, last = this.doc.first + this.doc.size - 1;
+ if (line < this.doc.first) line = this.doc.first;
+ else if (line > last) { line = last; end = true; }
+ var lineObj = getLine(this.doc, line);
+ return intoCoordSystem(this, lineObj, {top: 0, left: 0}, mode || "page").top +
+ (end ? this.doc.height - heightAtLine(lineObj) : 0);
+ },
+
+ defaultTextHeight: function() { return textHeight(this.display); },
+ defaultCharWidth: function() { return charWidth(this.display); },
+
+ setGutterMarker: methodOp(function(line, gutterID, value) {
+ return changeLine(this, line, "gutter", function(line) {
+ var markers = line.gutterMarkers || (line.gutterMarkers = {});
+ markers[gutterID] = value;
+ if (!value && isEmpty(markers)) line.gutterMarkers = null;
+ return true;
+ });
+ }),
+
+ clearGutter: methodOp(function(gutterID) {
+ var cm = this, doc = cm.doc, i = doc.first;
+ doc.iter(function(line) {
+ if (line.gutterMarkers && line.gutterMarkers[gutterID]) {
+ line.gutterMarkers[gutterID] = null;
+ regLineChange(cm, i, "gutter");
+ if (isEmpty(line.gutterMarkers)) line.gutterMarkers = null;
+ }
+ ++i;
+ });
+ }),
+
+ addLineClass: methodOp(function(handle, where, cls) {
+ return changeLine(this, handle, "class", function(line) {
+ var prop = where == "text" ? "textClass" : where == "background" ? "bgClass" : "wrapClass";
+ if (!line[prop]) line[prop] = cls;
+ else if (new RegExp("(?:^|\\s)" + cls + "(?:$|\\s)").test(line[prop])) return false;
+ else line[prop] += " " + cls;
+ return true;
+ });
+ }),
+
+ removeLineClass: methodOp(function(handle, where, cls) {
+ return changeLine(this, handle, "class", function(line) {
+ var prop = where == "text" ? "textClass" : where == "background" ? "bgClass" : "wrapClass";
+ var cur = line[prop];
+ if (!cur) return false;
+ else if (cls == null) line[prop] = null;
+ else {
+ var found = cur.match(new RegExp("(?:^|\\s+)" + cls + "(?:$|\\s+)"));
+ if (!found) return false;
+ var end = found.index + found[0].length;
+ line[prop] = cur.slice(0, found.index) + (!found.index || end == cur.length ? "" : " ") + cur.slice(end) || null;
+ }
+ return true;
+ });
+ }),
+
+ addLineWidget: methodOp(function(handle, node, options) {
+ return addLineWidget(this, handle, node, options);
+ }),
+
+ removeLineWidget: function(widget) { widget.clear(); },
+
+ lineInfo: function(line) {
+ if (typeof line == "number") {
+ if (!isLine(this.doc, line)) return null;
+ var n = line;
+ line = getLine(this.doc, line);
+ if (!line) return null;
+ } else {
+ var n = lineNo(line);
+ if (n == null) return null;
+ }
+ return {line: n, handle: line, text: line.text, gutterMarkers: line.gutterMarkers,
+ textClass: line.textClass, bgClass: line.bgClass, wrapClass: line.wrapClass,
+ widgets: line.widgets};
+ },
+
+ getViewport: function() { return {from: this.display.viewFrom, to: this.display.viewTo};},
+
+ addWidget: function(pos, node, scroll, vert, horiz) {
+ var display = this.display;
+ pos = cursorCoords(this, clipPos(this.doc, pos));
+ var top = pos.bottom, left = pos.left;
+ node.style.position = "absolute";
+ display.sizer.appendChild(node);
+ if (vert == "over") {
+ top = pos.top;
+ } else if (vert == "above" || vert == "near") {
+ var vspace = Math.max(display.wrapper.clientHeight, this.doc.height),
+ hspace = Math.max(display.sizer.clientWidth, display.lineSpace.clientWidth);
+ // Default to positioning above (if specified and possible); otherwise default to positioning below
+ if ((vert == 'above' || pos.bottom + node.offsetHeight > vspace) && pos.top > node.offsetHeight)
+ top = pos.top - node.offsetHeight;
+ else if (pos.bottom + node.offsetHeight <= vspace)
+ top = pos.bottom;
+ if (left + node.offsetWidth > hspace)
+ left = hspace - node.offsetWidth;
+ }
+ node.style.top = top + "px";
+ node.style.left = node.style.right = "";
+ if (horiz == "right") {
+ left = display.sizer.clientWidth - node.offsetWidth;
+ node.style.right = "0px";
+ } else {
+ if (horiz == "left") left = 0;
+ else if (horiz == "middle") left = (display.sizer.clientWidth - node.offsetWidth) / 2;
+ node.style.left = left + "px";
+ }
+ if (scroll)
+ scrollIntoView(this, left, top, left + node.offsetWidth, top + node.offsetHeight);
+ },
+
+ triggerOnKeyDown: methodOp(onKeyDown),
+ triggerOnKeyPress: methodOp(onKeyPress),
+ triggerOnKeyUp: methodOp(onKeyUp),
+
+ execCommand: function(cmd) {
+ if (commands.hasOwnProperty(cmd))
+ return commands[cmd](this);
+ },
+
+ findPosH: function(from, amount, unit, visually) {
+ var dir = 1;
+ if (amount < 0) { dir = -1; amount = -amount; }
+ for (var i = 0, cur = clipPos(this.doc, from); i < amount; ++i) {
+ cur = findPosH(this.doc, cur, dir, unit, visually);
+ if (cur.hitSide) break;
+ }
+ return cur;
+ },
+
+ moveH: methodOp(function(dir, unit) {
+ var cm = this;
+ cm.extendSelectionsBy(function(range) {
+ if (cm.display.shift || cm.doc.extend || range.empty())
+ return findPosH(cm.doc, range.head, dir, unit, cm.options.rtlMoveVisually);
+ else
+ return dir < 0 ? range.from() : range.to();
+ }, sel_move);
+ }),
+
+ deleteH: methodOp(function(dir, unit) {
+ var sel = this.doc.sel, doc = this.doc;
+ if (sel.somethingSelected())
+ doc.replaceSelection("", null, "+delete");
+ else
+ deleteNearSelection(this, function(range) {
+ var other = findPosH(doc, range.head, dir, unit, false);
+ return dir < 0 ? {from: other, to: range.head} : {from: range.head, to: other};
+ });
+ }),
+
+ findPosV: function(from, amount, unit, goalColumn) {
+ var dir = 1, x = goalColumn;
+ if (amount < 0) { dir = -1; amount = -amount; }
+ for (var i = 0, cur = clipPos(this.doc, from); i < amount; ++i) {
+ var coords = cursorCoords(this, cur, "div");
+ if (x == null) x = coords.left;
+ else coords.left = x;
+ cur = findPosV(this, coords, dir, unit);
+ if (cur.hitSide) break;
+ }
+ return cur;
+ },
+
+ moveV: methodOp(function(dir, unit) {
+ var cm = this, doc = this.doc, goals = [];
+ var collapse = !cm.display.shift && !doc.extend && doc.sel.somethingSelected();
+ doc.extendSelectionsBy(function(range) {
+ if (collapse)
+ return dir < 0 ? range.from() : range.to();
+ var headPos = cursorCoords(cm, range.head, "div");
+ if (range.goalColumn != null) headPos.left = range.goalColumn;
+ goals.push(headPos.left);
+ var pos = findPosV(cm, headPos, dir, unit);
+ if (unit == "page" && range == doc.sel.primary())
+ addToScrollPos(cm, null, charCoords(cm, pos, "div").top - headPos.top);
+ return pos;
+ }, sel_move);
+ if (goals.length) for (var i = 0; i < doc.sel.ranges.length; i++)
+ doc.sel.ranges[i].goalColumn = goals[i];
+ }),
+
+ toggleOverwrite: function(value) {
+ if (value != null && value == this.state.overwrite) return;
+ if (this.state.overwrite = !this.state.overwrite)
+ addClass(this.display.cursorDiv, "CodeMirror-overwrite");
+ else
+ rmClass(this.display.cursorDiv, "CodeMirror-overwrite");
+
+ signal(this, "overwriteToggle", this, this.state.overwrite);
+ },
+ hasFocus: function() { return activeElt() == this.display.input; },
+
+ scrollTo: methodOp(function(x, y) {
+ if (x != null || y != null) resolveScrollToPos(this);
+ if (x != null) this.curOp.scrollLeft = x;
+ if (y != null) this.curOp.scrollTop = y;
+ }),
+ getScrollInfo: function() {
+ var scroller = this.display.scroller, co = scrollerCutOff;
+ return {left: scroller.scrollLeft, top: scroller.scrollTop,
+ height: scroller.scrollHeight - co, width: scroller.scrollWidth - co,
+ clientHeight: scroller.clientHeight - co, clientWidth: scroller.clientWidth - co};
+ },
+
+ scrollIntoView: methodOp(function(range, margin) {
+ if (range == null) {
+ range = {from: this.doc.sel.primary().head, to: null};
+ if (margin == null) margin = this.options.cursorScrollMargin;
+ } else if (typeof range == "number") {
+ range = {from: Pos(range, 0), to: null};
+ } else if (range.from == null) {
+ range = {from: range, to: null};
+ }
+ if (!range.to) range.to = range.from;
+ range.margin = margin || 0;
+
+ if (range.from.line != null) {
+ resolveScrollToPos(this);
+ this.curOp.scrollToPos = range;
+ } else {
+ var sPos = calculateScrollPos(this, Math.min(range.from.left, range.to.left),
+ Math.min(range.from.top, range.to.top) - range.margin,
+ Math.max(range.from.right, range.to.right),
+ Math.max(range.from.bottom, range.to.bottom) + range.margin);
+ this.scrollTo(sPos.scrollLeft, sPos.scrollTop);
+ }
+ }),
+
+ setSize: methodOp(function(width, height) {
+ function interpret(val) {
+ return typeof val == "number" || /^\d+$/.test(String(val)) ? val + "px" : val;
+ }
+ if (width != null) this.display.wrapper.style.width = interpret(width);
+ if (height != null) this.display.wrapper.style.height = interpret(height);
+ if (this.options.lineWrapping) clearLineMeasurementCache(this);
+ this.curOp.forceUpdate = true;
+ signal(this, "refresh", this);
+ }),
+
+ operation: function(f){return runInOp(this, f);},
+
+ refresh: methodOp(function() {
+ var oldHeight = this.display.cachedTextHeight;
+ regChange(this);
+ this.curOp.forceUpdate = true;
+ clearCaches(this);
+ this.scrollTo(this.doc.scrollLeft, this.doc.scrollTop);
+ updateGutterSpace(this);
+ if (oldHeight == null || Math.abs(oldHeight - textHeight(this.display)) > .5)
+ estimateLineHeights(this);
+ signal(this, "refresh", this);
+ }),
+
+ swapDoc: methodOp(function(doc) {
+ var old = this.doc;
+ old.cm = null;
+ attachDoc(this, doc);
+ clearCaches(this);
+ resetInput(this);
+ this.scrollTo(doc.scrollLeft, doc.scrollTop);
+ signalLater(this, "swapDoc", this, old);
+ return old;
+ }),
+
+ getInputField: function(){return this.display.input;},
+ getWrapperElement: function(){return this.display.wrapper;},
+ getScrollerElement: function(){return this.display.scroller;},
+ getGutterElement: function(){return this.display.gutters;}
+ };
+ eventMixin(CodeMirror);
+
+ // OPTION DEFAULTS
+
+ // The default configuration options.
+ var defaults = CodeMirror.defaults = {};
+ // Functions to run when options are changed.
+ var optionHandlers = CodeMirror.optionHandlers = {};
+
+ function option(name, deflt, handle, notOnInit) {
+ CodeMirror.defaults[name] = deflt;
+ if (handle) optionHandlers[name] =
+ notOnInit ? function(cm, val, old) {if (old != Init) handle(cm, val, old);} : handle;
+ }
+
+ // Passed to option handlers when there is no old value.
+ var Init = CodeMirror.Init = {toString: function(){return "CodeMirror.Init";}};
+
+ // These two are, on init, called from the constructor because they
+ // have to be initialized before the editor can start at all.
+ option("value", "", function(cm, val) {
+ cm.setValue(val);
+ }, true);
+ option("mode", null, function(cm, val) {
+ cm.doc.modeOption = val;
+ loadMode(cm);
+ }, true);
+
+ option("indentUnit", 2, loadMode, true);
+ option("indentWithTabs", false);
+ option("smartIndent", true);
+ option("tabSize", 4, function(cm) {
+ resetModeState(cm);
+ clearCaches(cm);
+ regChange(cm);
+ }, true);
+ option("specialChars", /[\t\u0000-\u0019\u00ad\u200b\u2028\u2029\ufeff]/g, function(cm, val) {
+ cm.options.specialChars = new RegExp(val.source + (val.test("\t") ? "" : "|\t"), "g");
+ cm.refresh();
+ }, true);
+ option("specialCharPlaceholder", defaultSpecialCharPlaceholder, function(cm) {cm.refresh();}, true);
+ option("electricChars", true);
+ option("rtlMoveVisually", !windows);
+ option("wholeLineUpdateBefore", true);
+
+ option("theme", "default", function(cm) {
+ themeChanged(cm);
+ guttersChanged(cm);
+ }, true);
+ option("keyMap", "default", keyMapChanged);
+ option("extraKeys", null);
+
+ option("lineWrapping", false, wrappingChanged, true);
+ option("gutters", [], function(cm) {
+ setGuttersForLineNumbers(cm.options);
+ guttersChanged(cm);
+ }, true);
+ option("fixedGutter", true, function(cm, val) {
+ cm.display.gutters.style.left = val ? compensateForHScroll(cm.display) + "px" : "0";
+ cm.refresh();
+ }, true);
+ option("coverGutterNextToScrollbar", false, updateScrollbars, true);
+ option("lineNumbers", false, function(cm) {
+ setGuttersForLineNumbers(cm.options);
+ guttersChanged(cm);
+ }, true);
+ option("firstLineNumber", 1, guttersChanged, true);
+ option("lineNumberFormatter", function(integer) {return integer;}, guttersChanged, true);
+ option("showCursorWhenSelecting", false, updateSelection, true);
+
+ option("resetSelectionOnContextMenu", true);
+
+ option("readOnly", false, function(cm, val) {
+ if (val == "nocursor") {
+ onBlur(cm);
+ cm.display.input.blur();
+ cm.display.disabled = true;
+ } else {
+ cm.display.disabled = false;
+ if (!val) resetInput(cm);
+ }
+ });
+ option("disableInput", false, function(cm, val) {if (!val) resetInput(cm);}, true);
+ option("dragDrop", true);
+
+ option("cursorBlinkRate", 530);
+ option("cursorScrollMargin", 0);
+ option("cursorHeight", 1);
+ option("workTime", 100);
+ option("workDelay", 100);
+ option("flattenSpans", true, resetModeState, true);
+ option("addModeClass", false, resetModeState, true);
+ option("pollInterval", 100);
+ option("undoDepth", 200, function(cm, val){cm.doc.history.undoDepth = val;});
+ option("historyEventDelay", 1250);
+ option("viewportMargin", 10, function(cm){cm.refresh();}, true);
+ option("maxHighlightLength", 10000, resetModeState, true);
+ option("moveInputWithCursor", true, function(cm, val) {
+ if (!val) cm.display.inputDiv.style.top = cm.display.inputDiv.style.left = 0;
+ });
+
+ option("tabindex", null, function(cm, val) {
+ cm.display.input.tabIndex = val || "";
+ });
+ option("autofocus", null);
+
+ // MODE DEFINITION AND QUERYING
+
+ // Known modes, by name and by MIME
+ var modes = CodeMirror.modes = {}, mimeModes = CodeMirror.mimeModes = {};
+
+ // Extra arguments are stored as the mode's dependencies, which is
+ // used by (legacy) mechanisms like loadmode.js to automatically
+ // load a mode. (Preferred mechanism is the require/define calls.)
+ CodeMirror.defineMode = function(name, mode) {
+ if (!CodeMirror.defaults.mode && name != "null") CodeMirror.defaults.mode = name;
+ if (arguments.length > 2) {
+ mode.dependencies = [];
+ for (var i = 2; i < arguments.length; ++i) mode.dependencies.push(arguments[i]);
+ }
+ modes[name] = mode;
+ };
+
+ CodeMirror.defineMIME = function(mime, spec) {
+ mimeModes[mime] = spec;
+ };
+
+ // Given a MIME type, a {name, ...options} config object, or a name
+ // string, return a mode config object.
+ CodeMirror.resolveMode = function(spec) {
+ if (typeof spec == "string" && mimeModes.hasOwnProperty(spec)) {
+ spec = mimeModes[spec];
+ } else if (spec && typeof spec.name == "string" && mimeModes.hasOwnProperty(spec.name)) {
+ var found = mimeModes[spec.name];
+ if (typeof found == "string") found = {name: found};
+ spec = createObj(found, spec);
+ spec.name = found.name;
+ } else if (typeof spec == "string" && /^[\w\-]+\/[\w\-]+\+xml$/.test(spec)) {
+ return CodeMirror.resolveMode("application/xml");
+ }
+ if (typeof spec == "string") return {name: spec};
+ else return spec || {name: "null"};
+ };
+
+ // Given a mode spec (anything that resolveMode accepts), find and
+ // initialize an actual mode object.
+ CodeMirror.getMode = function(options, spec) {
+ var spec = CodeMirror.resolveMode(spec);
+ var mfactory = modes[spec.name];
+ if (!mfactory) return CodeMirror.getMode(options, "text/plain");
+ var modeObj = mfactory(options, spec);
+ if (modeExtensions.hasOwnProperty(spec.name)) {
+ var exts = modeExtensions[spec.name];
+ for (var prop in exts) {
+ if (!exts.hasOwnProperty(prop)) continue;
+ if (modeObj.hasOwnProperty(prop)) modeObj["_" + prop] = modeObj[prop];
+ modeObj[prop] = exts[prop];
+ }
+ }
+ modeObj.name = spec.name;
+ if (spec.helperType) modeObj.helperType = spec.helperType;
+ if (spec.modeProps) for (var prop in spec.modeProps)
+ modeObj[prop] = spec.modeProps[prop];
+
+ return modeObj;
+ };
+
+ // Minimal default mode.
+ CodeMirror.defineMode("null", function() {
+ return {token: function(stream) {stream.skipToEnd();}};
+ });
+ CodeMirror.defineMIME("text/plain", "null");
+
+ // This can be used to attach properties to mode objects from
+ // outside the actual mode definition.
+ var modeExtensions = CodeMirror.modeExtensions = {};
+ CodeMirror.extendMode = function(mode, properties) {
+ var exts = modeExtensions.hasOwnProperty(mode) ? modeExtensions[mode] : (modeExtensions[mode] = {});
+ copyObj(properties, exts);
+ };
+
+ // EXTENSIONS
+
+ CodeMirror.defineExtension = function(name, func) {
+ CodeMirror.prototype[name] = func;
+ };
+ CodeMirror.defineDocExtension = function(name, func) {
+ Doc.prototype[name] = func;
+ };
+ CodeMirror.defineOption = option;
+
+ var initHooks = [];
+ CodeMirror.defineInitHook = function(f) {initHooks.push(f);};
+
+ var helpers = CodeMirror.helpers = {};
+ CodeMirror.registerHelper = function(type, name, value) {
+ if (!helpers.hasOwnProperty(type)) helpers[type] = CodeMirror[type] = {_global: []};
+ helpers[type][name] = value;
+ };
+ CodeMirror.registerGlobalHelper = function(type, name, predicate, value) {
+ CodeMirror.registerHelper(type, name, value);
+ helpers[type]._global.push({pred: predicate, val: value});
+ };
+
+ // MODE STATE HANDLING
+
+ // Utility functions for working with state. Exported because nested
+ // modes need to do this for their inner modes.
+
+ var copyState = CodeMirror.copyState = function(mode, state) {
+ if (state === true) return state;
+ if (mode.copyState) return mode.copyState(state);
+ var nstate = {};
+ for (var n in state) {
+ var val = state[n];
+ if (val instanceof Array) val = val.concat([]);
+ nstate[n] = val;
+ }
+ return nstate;
+ };
+
+ var startState = CodeMirror.startState = function(mode, a1, a2) {
+ return mode.startState ? mode.startState(a1, a2) : true;
+ };
+
+ // Given a mode and a state (for that mode), find the inner mode and
+ // state at the position that the state refers to.
+ CodeMirror.innerMode = function(mode, state) {
+ while (mode.innerMode) {
+ var info = mode.innerMode(state);
+ if (!info || info.mode == mode) break;
+ state = info.state;
+ mode = info.mode;
+ }
+ return info || {mode: mode, state: state};
+ };
+
+ // STANDARD COMMANDS
+
+ // Commands are parameter-less actions that can be performed on an
+ // editor, mostly used for keybindings.
+ var commands = CodeMirror.commands = {
+ selectAll: function(cm) {cm.setSelection(Pos(cm.firstLine(), 0), Pos(cm.lastLine()), sel_dontScroll);},
+ singleSelection: function(cm) {
+ cm.setSelection(cm.getCursor("anchor"), cm.getCursor("head"), sel_dontScroll);
+ },
+ killLine: function(cm) {
+ deleteNearSelection(cm, function(range) {
+ if (range.empty()) {
+ var len = getLine(cm.doc, range.head.line).text.length;
+ if (range.head.ch == len && range.head.line < cm.lastLine())
+ return {from: range.head, to: Pos(range.head.line + 1, 0)};
+ else
+ return {from: range.head, to: Pos(range.head.line, len)};
+ } else {
+ return {from: range.from(), to: range.to()};
+ }
+ });
+ },
+ deleteLine: function(cm) {
+ deleteNearSelection(cm, function(range) {
+ return {from: Pos(range.from().line, 0),
+ to: clipPos(cm.doc, Pos(range.to().line + 1, 0))};
+ });
+ },
+ delLineLeft: function(cm) {
+ deleteNearSelection(cm, function(range) {
+ return {from: Pos(range.from().line, 0), to: range.from()};
+ });
+ },
+ undo: function(cm) {cm.undo();},
+ redo: function(cm) {cm.redo();},
+ undoSelection: function(cm) {cm.undoSelection();},
+ redoSelection: function(cm) {cm.redoSelection();},
+ goDocStart: function(cm) {cm.extendSelection(Pos(cm.firstLine(), 0));},
+ goDocEnd: function(cm) {cm.extendSelection(Pos(cm.lastLine()));},
+ goLineStart: function(cm) {
+ cm.extendSelectionsBy(function(range) { return lineStart(cm, range.head.line); }, sel_move);
+ },
+ goLineStartSmart: function(cm) {
+ cm.extendSelectionsBy(function(range) {
+ var start = lineStart(cm, range.head.line);
+ var line = cm.getLineHandle(start.line);
+ var order = getOrder(line);
+ if (!order || order[0].level == 0) {
+ var firstNonWS = Math.max(0, line.text.search(/\S/));
+ var inWS = range.head.line == start.line && range.head.ch <= firstNonWS && range.head.ch;
+ return Pos(start.line, inWS ? 0 : firstNonWS);
+ }
+ return start;
+ }, sel_move);
+ },
+ goLineEnd: function(cm) {
+ cm.extendSelectionsBy(function(range) { return lineEnd(cm, range.head.line); }, sel_move);
+ },
+ goLineRight: function(cm) {
+ cm.extendSelectionsBy(function(range) {
+ var top = cm.charCoords(range.head, "div").top + 5;
+ return cm.coordsChar({left: cm.display.lineDiv.offsetWidth + 100, top: top}, "div");
+ }, sel_move);
+ },
+ goLineLeft: function(cm) {
+ cm.extendSelectionsBy(function(range) {
+ var top = cm.charCoords(range.head, "div").top + 5;
+ return cm.coordsChar({left: 0, top: top}, "div");
+ }, sel_move);
+ },
+ goLineUp: function(cm) {cm.moveV(-1, "line");},
+ goLineDown: function(cm) {cm.moveV(1, "line");},
+ goPageUp: function(cm) {cm.moveV(-1, "page");},
+ goPageDown: function(cm) {cm.moveV(1, "page");},
+ goCharLeft: function(cm) {cm.moveH(-1, "char");},
+ goCharRight: function(cm) {cm.moveH(1, "char");},
+ goColumnLeft: function(cm) {cm.moveH(-1, "column");},
+ goColumnRight: function(cm) {cm.moveH(1, "column");},
+ goWordLeft: function(cm) {cm.moveH(-1, "word");},
+ goGroupRight: function(cm) {cm.moveH(1, "group");},
+ goGroupLeft: function(cm) {cm.moveH(-1, "group");},
+ goWordRight: function(cm) {cm.moveH(1, "word");},
+ delCharBefore: function(cm) {cm.deleteH(-1, "char");},
+ delCharAfter: function(cm) {cm.deleteH(1, "char");},
+ delWordBefore: function(cm) {cm.deleteH(-1, "word");},
+ delWordAfter: function(cm) {cm.deleteH(1, "word");},
+ delGroupBefore: function(cm) {cm.deleteH(-1, "group");},
+ delGroupAfter: function(cm) {cm.deleteH(1, "group");},
+ indentAuto: function(cm) {cm.indentSelection("smart");},
+ indentMore: function(cm) {cm.indentSelection("add");},
+ indentLess: function(cm) {cm.indentSelection("subtract");},
+ insertTab: function(cm) {cm.replaceSelection("\t");},
+ insertSoftTab: function(cm) {
+ var spaces = [], ranges = cm.listSelections(), tabSize = cm.options.tabSize;
+ for (var i = 0; i < ranges.length; i++) {
+ var pos = ranges[i].from();
+ var col = countColumn(cm.getLine(pos.line), pos.ch, tabSize);
+ spaces.push(new Array(tabSize - col % tabSize + 1).join(" "));
+ }
+ cm.replaceSelections(spaces);
+ },
+ defaultTab: function(cm) {
+ if (cm.somethingSelected()) cm.indentSelection("add");
+ else cm.execCommand("insertTab");
+ },
+ transposeChars: function(cm) {
+ runInOp(cm, function() {
+ var ranges = cm.listSelections();
+ for (var i = 0; i < ranges.length; i++) {
+ var cur = ranges[i].head, line = getLine(cm.doc, cur.line).text;
+ if (cur.ch > 0 && cur.ch < line.length - 1)
+ cm.replaceRange(line.charAt(cur.ch) + line.charAt(cur.ch - 1),
+ Pos(cur.line, cur.ch - 1), Pos(cur.line, cur.ch + 1));
+ }
+ });
+ },
+ newlineAndIndent: function(cm) {
+ runInOp(cm, function() {
+ var len = cm.listSelections().length;
+ for (var i = 0; i < len; i++) {
+ var range = cm.listSelections()[i];
+ cm.replaceRange("\n", range.anchor, range.head, "+input");
+ cm.indentLine(range.from().line + 1, null, true);
+ ensureCursorVisible(cm);
+ }
+ });
+ },
+ toggleOverwrite: function(cm) {cm.toggleOverwrite();}
+ };
+
+ // STANDARD KEYMAPS
+
+ var keyMap = CodeMirror.keyMap = {};
+ keyMap.basic = {
+ "Left": "goCharLeft", "Right": "goCharRight", "Up": "goLineUp", "Down": "goLineDown",
+ "End": "goLineEnd", "Home": "goLineStartSmart", "PageUp": "goPageUp", "PageDown": "goPageDown",
+ "Delete": "delCharAfter", "Backspace": "delCharBefore", "Shift-Backspace": "delCharBefore",
+ "Tab": "defaultTab", "Shift-Tab": "indentAuto",
+ "Enter": "newlineAndIndent", "Insert": "toggleOverwrite",
+ "Esc": "singleSelection"
+ };
+ // Note that the save and find-related commands aren't defined by
+ // default. User code or addons can define them. Unknown commands
+ // are simply ignored.
+ keyMap.pcDefault = {
+ "Ctrl-A": "selectAll", "Ctrl-D": "deleteLine", "Ctrl-Z": "undo", "Shift-Ctrl-Z": "redo", "Ctrl-Y": "redo",
+ "Ctrl-Home": "goDocStart", "Ctrl-Up": "goDocStart", "Ctrl-End": "goDocEnd", "Ctrl-Down": "goDocEnd",
+ "Ctrl-Left": "goGroupLeft", "Ctrl-Right": "goGroupRight", "Alt-Left": "goLineStart", "Alt-Right": "goLineEnd",
+ "Ctrl-Backspace": "delGroupBefore", "Ctrl-Delete": "delGroupAfter", "Ctrl-S": "save", "Ctrl-F": "find",
+ "Ctrl-G": "findNext", "Shift-Ctrl-G": "findPrev", "Shift-Ctrl-F": "replace", "Shift-Ctrl-R": "replaceAll",
+ "Ctrl-[": "indentLess", "Ctrl-]": "indentMore",
+ "Ctrl-U": "undoSelection", "Shift-Ctrl-U": "redoSelection", "Alt-U": "redoSelection",
+ fallthrough: "basic"
+ };
+ keyMap.macDefault = {
+ "Cmd-A": "selectAll", "Cmd-D": "deleteLine", "Cmd-Z": "undo", "Shift-Cmd-Z": "redo", "Cmd-Y": "redo",
+ "Cmd-Up": "goDocStart", "Cmd-End": "goDocEnd", "Cmd-Down": "goDocEnd", "Alt-Left": "goGroupLeft",
+ "Alt-Right": "goGroupRight", "Cmd-Left": "goLineStart", "Cmd-Right": "goLineEnd", "Alt-Backspace": "delGroupBefore",
+ "Ctrl-Alt-Backspace": "delGroupAfter", "Alt-Delete": "delGroupAfter", "Cmd-S": "save", "Cmd-F": "find",
+ "Cmd-G": "findNext", "Shift-Cmd-G": "findPrev", "Cmd-Alt-F": "replace", "Shift-Cmd-Alt-F": "replaceAll",
+ "Cmd-[": "indentLess", "Cmd-]": "indentMore", "Cmd-Backspace": "delLineLeft",
+ "Cmd-U": "undoSelection", "Shift-Cmd-U": "redoSelection",
+ fallthrough: ["basic", "emacsy"]
+ };
+ // Very basic readline/emacs-style bindings, which are standard on Mac.
+ keyMap.emacsy = {
+ "Ctrl-F": "goCharRight", "Ctrl-B": "goCharLeft", "Ctrl-P": "goLineUp", "Ctrl-N": "goLineDown",
+ "Alt-F": "goWordRight", "Alt-B": "goWordLeft", "Ctrl-A": "goLineStart", "Ctrl-E": "goLineEnd",
+ "Ctrl-V": "goPageDown", "Shift-Ctrl-V": "goPageUp", "Ctrl-D": "delCharAfter", "Ctrl-H": "delCharBefore",
+ "Alt-D": "delWordAfter", "Alt-Backspace": "delWordBefore", "Ctrl-K": "killLine", "Ctrl-T": "transposeChars"
+ };
+ keyMap["default"] = mac ? keyMap.macDefault : keyMap.pcDefault;
+
+ // KEYMAP DISPATCH
+
+ function getKeyMap(val) {
+ if (typeof val == "string") return keyMap[val];
+ else return val;
+ }
+
+ // Given an array of keymaps and a key name, call handle on any
+ // bindings found, until that returns a truthy value, at which point
+ // we consider the key handled. Implements things like binding a key
+ // to false stopping further handling and keymap fallthrough.
+ var lookupKey = CodeMirror.lookupKey = function(name, maps, handle) {
+ function lookup(map) {
+ map = getKeyMap(map);
+ var found = map[name];
+ if (found === false) return "stop";
+ if (found != null && handle(found)) return true;
+ if (map.nofallthrough) return "stop";
+
+ var fallthrough = map.fallthrough;
+ if (fallthrough == null) return false;
+ if (Object.prototype.toString.call(fallthrough) != "[object Array]")
+ return lookup(fallthrough);
+ for (var i = 0; i < fallthrough.length; ++i) {
+ var done = lookup(fallthrough[i]);
+ if (done) return done;
+ }
+ return false;
+ }
+
+ for (var i = 0; i < maps.length; ++i) {
+ var done = lookup(maps[i]);
+ if (done) return done != "stop";
+ }
+ };
+
+ // Modifier key presses don't count as 'real' key presses for the
+ // purpose of keymap fallthrough.
+ var isModifierKey = CodeMirror.isModifierKey = function(event) {
+ var name = keyNames[event.keyCode];
+ return name == "Ctrl" || name == "Alt" || name == "Shift" || name == "Mod";
+ };
+
+ // Look up the name of a key as indicated by an event object.
+ var keyName = CodeMirror.keyName = function(event, noShift) {
+ if (presto && event.keyCode == 34 && event["char"]) return false;
+ var name = keyNames[event.keyCode];
+ if (name == null || event.altGraphKey) return false;
+ if (event.altKey) name = "Alt-" + name;
+ if (flipCtrlCmd ? event.metaKey : event.ctrlKey) name = "Ctrl-" + name;
+ if (flipCtrlCmd ? event.ctrlKey : event.metaKey) name = "Cmd-" + name;
+ if (!noShift && event.shiftKey) name = "Shift-" + name;
+ return name;
+ };
+
+ // FROMTEXTAREA
+
+ CodeMirror.fromTextArea = function(textarea, options) {
+ if (!options) options = {};
+ options.value = textarea.value;
+ if (!options.tabindex && textarea.tabindex)
+ options.tabindex = textarea.tabindex;
+ if (!options.placeholder && textarea.placeholder)
+ options.placeholder = textarea.placeholder;
+ // Set autofocus to true if this textarea is focused, or if it has
+ // autofocus and no other element is focused.
+ if (options.autofocus == null) {
+ var hasFocus = activeElt();
+ options.autofocus = hasFocus == textarea ||
+ textarea.getAttribute("autofocus") != null && hasFocus == document.body;
+ }
+
+ function save() {textarea.value = cm.getValue();}
+ if (textarea.form) {
+ on(textarea.form, "submit", save);
+ // Deplorable hack to make the submit method do the right thing.
+ if (!options.leaveSubmitMethodAlone) {
+ var form = textarea.form, realSubmit = form.submit;
+ try {
+ var wrappedSubmit = form.submit = function() {
+ save();
+ form.submit = realSubmit;
+ form.submit();
+ form.submit = wrappedSubmit;
+ };
+ } catch(e) {}
+ }
+ }
+
+ textarea.style.display = "none";
+ var cm = CodeMirror(function(node) {
+ textarea.parentNode.insertBefore(node, textarea.nextSibling);
+ }, options);
+ cm.save = save;
+ cm.getTextArea = function() { return textarea; };
+ cm.toTextArea = function() {
+ save();
+ textarea.parentNode.removeChild(cm.getWrapperElement());
+ textarea.style.display = "";
+ if (textarea.form) {
+ off(textarea.form, "submit", save);
+ if (typeof textarea.form.submit == "function")
+ textarea.form.submit = realSubmit;
+ }
+ };
+ return cm;
+ };
+
+ // STRING STREAM
+
+ // Fed to the mode parsers, provides helper functions to make
+ // parsers more succinct.
+
+ var StringStream = CodeMirror.StringStream = function(string, tabSize) {
+ this.pos = this.start = 0;
+ this.string = string;
+ this.tabSize = tabSize || 8;
+ this.lastColumnPos = this.lastColumnValue = 0;
+ this.lineStart = 0;
+ };
+
+ StringStream.prototype = {
+ eol: function() {return this.pos >= this.string.length;},
+ sol: function() {return this.pos == this.lineStart;},
+ peek: function() {return this.string.charAt(this.pos) || undefined;},
+ next: function() {
+ if (this.pos < this.string.length)
+ return this.string.charAt(this.pos++);
+ },
+ eat: function(match) {
+ var ch = this.string.charAt(this.pos);
+ if (typeof match == "string") var ok = ch == match;
+ else var ok = ch && (match.test ? match.test(ch) : match(ch));
+ if (ok) {++this.pos; return ch;}
+ },
+ eatWhile: function(match) {
+ var start = this.pos;
+ while (this.eat(match)){}
+ return this.pos > start;
+ },
+ eatSpace: function() {
+ var start = this.pos;
+ while (/[\s\u00a0]/.test(this.string.charAt(this.pos))) ++this.pos;
+ return this.pos > start;
+ },
+ skipToEnd: function() {this.pos = this.string.length;},
+ skipTo: function(ch) {
+ var found = this.string.indexOf(ch, this.pos);
+ if (found > -1) {this.pos = found; return true;}
+ },
+ backUp: function(n) {this.pos -= n;},
+ column: function() {
+ if (this.lastColumnPos < this.start) {
+ this.lastColumnValue = countColumn(this.string, this.start, this.tabSize, this.lastColumnPos, this.lastColumnValue);
+ this.lastColumnPos = this.start;
+ }
+ return this.lastColumnValue - (this.lineStart ? countColumn(this.string, this.lineStart, this.tabSize) : 0);
+ },
+ indentation: function() {
+ return countColumn(this.string, null, this.tabSize) -
+ (this.lineStart ? countColumn(this.string, this.lineStart, this.tabSize) : 0);
+ },
+ match: function(pattern, consume, caseInsensitive) {
+ if (typeof pattern == "string") {
+ var cased = function(str) {return caseInsensitive ? str.toLowerCase() : str;};
+ var substr = this.string.substr(this.pos, pattern.length);
+ if (cased(substr) == cased(pattern)) {
+ if (consume !== false) this.pos += pattern.length;
+ return true;
+ }
+ } else {
+ var match = this.string.slice(this.pos).match(pattern);
+ if (match && match.index > 0) return null;
+ if (match && consume !== false) this.pos += match[0].length;
+ return match;
+ }
+ },
+ current: function(){return this.string.slice(this.start, this.pos);},
+ hideFirstChars: function(n, inner) {
+ this.lineStart += n;
+ try { return inner(); }
+ finally { this.lineStart -= n; }
+ }
+ };
+
+ // TEXTMARKERS
+
+ // Created with markText and setBookmark methods. A TextMarker is a
+ // handle that can be used to clear or find a marked position in the
+ // document. Line objects hold arrays (markedSpans) containing
+ // {from, to, marker} object pointing to such marker objects, and
+ // indicating that such a marker is present on that line. Multiple
+ // lines may point to the same marker when it spans across lines.
+ // The spans will have null for their from/to properties when the
+ // marker continues beyond the start/end of the line. Markers have
+ // links back to the lines they currently touch.
+
+ var TextMarker = CodeMirror.TextMarker = function(doc, type) {
+ this.lines = [];
+ this.type = type;
+ this.doc = doc;
+ };
+ eventMixin(TextMarker);
+
+ // Clear the marker.
+ TextMarker.prototype.clear = function() {
+ if (this.explicitlyCleared) return;
+ var cm = this.doc.cm, withOp = cm && !cm.curOp;
+ if (withOp) startOperation(cm);
+ if (hasHandler(this, "clear")) {
+ var found = this.find();
+ if (found) signalLater(this, "clear", found.from, found.to);
+ }
+ var min = null, max = null;
+ for (var i = 0; i < this.lines.length; ++i) {
+ var line = this.lines[i];
+ var span = getMarkedSpanFor(line.markedSpans, this);
+ if (cm && !this.collapsed) regLineChange(cm, lineNo(line), "text");
+ else if (cm) {
+ if (span.to != null) max = lineNo(line);
+ if (span.from != null) min = lineNo(line);
+ }
+ line.markedSpans = removeMarkedSpan(line.markedSpans, span);
+ if (span.from == null && this.collapsed && !lineIsHidden(this.doc, line) && cm)
+ updateLineHeight(line, textHeight(cm.display));
+ }
+ if (cm && this.collapsed && !cm.options.lineWrapping) for (var i = 0; i < this.lines.length; ++i) {
+ var visual = visualLine(this.lines[i]), len = lineLength(visual);
+ if (len > cm.display.maxLineLength) {
+ cm.display.maxLine = visual;
+ cm.display.maxLineLength = len;
+ cm.display.maxLineChanged = true;
+ }
+ }
+
+ if (min != null && cm && this.collapsed) regChange(cm, min, max + 1);
+ this.lines.length = 0;
+ this.explicitlyCleared = true;
+ if (this.atomic && this.doc.cantEdit) {
+ this.doc.cantEdit = false;
+ if (cm) reCheckSelection(cm.doc);
+ }
+ if (cm) signalLater(cm, "markerCleared", cm, this);
+ if (withOp) endOperation(cm);
+ if (this.parent) this.parent.clear();
+ };
+
+ // Find the position of the marker in the document. Returns a {from,
+ // to} object by default. Side can be passed to get a specific side
+ // -- 0 (both), -1 (left), or 1 (right). When lineObj is true, the
+ // Pos objects returned contain a line object, rather than a line
+ // number (used to prevent looking up the same line twice).
+ TextMarker.prototype.find = function(side, lineObj) {
+ if (side == null && this.type == "bookmark") side = 1;
+ var from, to;
+ for (var i = 0; i < this.lines.length; ++i) {
+ var line = this.lines[i];
+ var span = getMarkedSpanFor(line.markedSpans, this);
+ if (span.from != null) {
+ from = Pos(lineObj ? line : lineNo(line), span.from);
+ if (side == -1) return from;
+ }
+ if (span.to != null) {
+ to = Pos(lineObj ? line : lineNo(line), span.to);
+ if (side == 1) return to;
+ }
+ }
+ return from && {from: from, to: to};
+ };
+
+ // Signals that the marker's widget changed, and surrounding layout
+ // should be recomputed.
+ TextMarker.prototype.changed = function() {
+ var pos = this.find(-1, true), widget = this, cm = this.doc.cm;
+ if (!pos || !cm) return;
+ runInOp(cm, function() {
+ var line = pos.line, lineN = lineNo(pos.line);
+ var view = findViewForLine(cm, lineN);
+ if (view) {
+ clearLineMeasurementCacheFor(view);
+ cm.curOp.selectionChanged = cm.curOp.forceUpdate = true;
+ }
+ cm.curOp.updateMaxLine = true;
+ if (!lineIsHidden(widget.doc, line) && widget.height != null) {
+ var oldHeight = widget.height;
+ widget.height = null;
+ var dHeight = widgetHeight(widget) - oldHeight;
+ if (dHeight)
+ updateLineHeight(line, line.height + dHeight);
+ }
+ });
+ };
+
+ TextMarker.prototype.attachLine = function(line) {
+ if (!this.lines.length && this.doc.cm) {
+ var op = this.doc.cm.curOp;
+ if (!op.maybeHiddenMarkers || indexOf(op.maybeHiddenMarkers, this) == -1)
+ (op.maybeUnhiddenMarkers || (op.maybeUnhiddenMarkers = [])).push(this);
+ }
+ this.lines.push(line);
+ };
+ TextMarker.prototype.detachLine = function(line) {
+ this.lines.splice(indexOf(this.lines, line), 1);
+ if (!this.lines.length && this.doc.cm) {
+ var op = this.doc.cm.curOp;
+ (op.maybeHiddenMarkers || (op.maybeHiddenMarkers = [])).push(this);
+ }
+ };
+
+ // Collapsed markers have unique ids, in order to be able to order
+ // them, which is needed for uniquely determining an outer marker
+ // when they overlap (they may nest, but not partially overlap).
+ var nextMarkerId = 0;
+
+ // Create a marker, wire it up to the right lines, and
+ function markText(doc, from, to, options, type) {
+ // Shared markers (across linked documents) are handled separately
+ // (markTextShared will call out to this again, once per
+ // document).
+ if (options && options.shared) return markTextShared(doc, from, to, options, type);
+ // Ensure we are in an operation.
+ if (doc.cm && !doc.cm.curOp) return operation(doc.cm, markText)(doc, from, to, options, type);
+
+ var marker = new TextMarker(doc, type), diff = cmp(from, to);
+ if (options) copyObj(options, marker, false);
+ // Don't connect empty markers unless clearWhenEmpty is false
+ if (diff > 0 || diff == 0 && marker.clearWhenEmpty !== false)
+ return marker;
+ if (marker.replacedWith) {
+ // Showing up as a widget implies collapsed (widget replaces text)
+ marker.collapsed = true;
+ marker.widgetNode = elt("span", [marker.replacedWith], "CodeMirror-widget");
+ if (!options.handleMouseEvents) marker.widgetNode.ignoreEvents = true;
+ if (options.insertLeft) marker.widgetNode.insertLeft = true;
+ }
+ if (marker.collapsed) {
+ if (conflictingCollapsedRange(doc, from.line, from, to, marker) ||
+ from.line != to.line && conflictingCollapsedRange(doc, to.line, from, to, marker))
+ throw new Error("Inserting collapsed marker partially overlapping an existing one");
+ sawCollapsedSpans = true;
+ }
+
+ if (marker.addToHistory)
+ addChangeToHistory(doc, {from: from, to: to, origin: "markText"}, doc.sel, NaN);
+
+ var curLine = from.line, cm = doc.cm, updateMaxLine;
+ doc.iter(curLine, to.line + 1, function(line) {
+ if (cm && marker.collapsed && !cm.options.lineWrapping && visualLine(line) == cm.display.maxLine)
+ updateMaxLine = true;
+ if (marker.collapsed && curLine != from.line) updateLineHeight(line, 0);
+ addMarkedSpan(line, new MarkedSpan(marker,
+ curLine == from.line ? from.ch : null,
+ curLine == to.line ? to.ch : null));
+ ++curLine;
+ });
+ // lineIsHidden depends on the presence of the spans, so needs a second pass
+ if (marker.collapsed) doc.iter(from.line, to.line + 1, function(line) {
+ if (lineIsHidden(doc, line)) updateLineHeight(line, 0);
+ });
+
+ if (marker.clearOnEnter) on(marker, "beforeCursorEnter", function() { marker.clear(); });
+
+ if (marker.readOnly) {
+ sawReadOnlySpans = true;
+ if (doc.history.done.length || doc.history.undone.length)
+ doc.clearHistory();
+ }
+ if (marker.collapsed) {
+ marker.id = ++nextMarkerId;
+ marker.atomic = true;
+ }
+ if (cm) {
+ // Sync editor state
+ if (updateMaxLine) cm.curOp.updateMaxLine = true;
+ if (marker.collapsed)
+ regChange(cm, from.line, to.line + 1);
+ else if (marker.className || marker.title || marker.startStyle || marker.endStyle)
+ for (var i = from.line; i <= to.line; i++) regLineChange(cm, i, "text");
+ if (marker.atomic) reCheckSelection(cm.doc);
+ signalLater(cm, "markerAdded", cm, marker);
+ }
+ return marker;
+ }
+
+ // SHARED TEXTMARKERS
+
+ // A shared marker spans multiple linked documents. It is
+ // implemented as a meta-marker-object controlling multiple normal
+ // markers.
+ var SharedTextMarker = CodeMirror.SharedTextMarker = function(markers, primary) {
+ this.markers = markers;
+ this.primary = primary;
+ for (var i = 0; i < markers.length; ++i)
+ markers[i].parent = this;
+ };
+ eventMixin(SharedTextMarker);
+
+ SharedTextMarker.prototype.clear = function() {
+ if (this.explicitlyCleared) return;
+ this.explicitlyCleared = true;
+ for (var i = 0; i < this.markers.length; ++i)
+ this.markers[i].clear();
+ signalLater(this, "clear");
+ };
+ SharedTextMarker.prototype.find = function(side, lineObj) {
+ return this.primary.find(side, lineObj);
+ };
+
+ function markTextShared(doc, from, to, options, type) {
+ options = copyObj(options);
+ options.shared = false;
+ var markers = [markText(doc, from, to, options, type)], primary = markers[0];
+ var widget = options.widgetNode;
+ linkedDocs(doc, function(doc) {
+ if (widget) options.widgetNode = widget.cloneNode(true);
+ markers.push(markText(doc, clipPos(doc, from), clipPos(doc, to), options, type));
+ for (var i = 0; i < doc.linked.length; ++i)
+ if (doc.linked[i].isParent) return;
+ primary = lst(markers);
+ });
+ return new SharedTextMarker(markers, primary);
+ }
+
+ function findSharedMarkers(doc) {
+ return doc.findMarks(Pos(doc.first, 0), doc.clipPos(Pos(doc.lastLine())),
+ function(m) { return m.parent; });
+ }
+
+ function copySharedMarkers(doc, markers) {
+ for (var i = 0; i < markers.length; i++) {
+ var marker = markers[i], pos = marker.find();
+ var mFrom = doc.clipPos(pos.from), mTo = doc.clipPos(pos.to);
+ if (cmp(mFrom, mTo)) {
+ var subMark = markText(doc, mFrom, mTo, marker.primary, marker.primary.type);
+ marker.markers.push(subMark);
+ subMark.parent = marker;
+ }
+ }
+ }
+
+ function detachSharedMarkers(markers) {
+ for (var i = 0; i < markers.length; i++) {
+ var marker = markers[i], linked = [marker.primary.doc];;
+ linkedDocs(marker.primary.doc, function(d) { linked.push(d); });
+ for (var j = 0; j < marker.markers.length; j++) {
+ var subMarker = marker.markers[j];
+ if (indexOf(linked, subMarker.doc) == -1) {
+ subMarker.parent = null;
+ marker.markers.splice(j--, 1);
+ }
+ }
+ }
+ }
+
+ // TEXTMARKER SPANS
+
+ function MarkedSpan(marker, from, to) {
+ this.marker = marker;
+ this.from = from; this.to = to;
+ }
+
+ // Search an array of spans for a span matching the given marker.
+ function getMarkedSpanFor(spans, marker) {
+ if (spans) for (var i = 0; i < spans.length; ++i) {
+ var span = spans[i];
+ if (span.marker == marker) return span;
+ }
+ }
+ // Remove a span from an array, returning undefined if no spans are
+ // left (we don't store arrays for lines without spans).
+ function removeMarkedSpan(spans, span) {
+ for (var r, i = 0; i < spans.length; ++i)
+ if (spans[i] != span) (r || (r = [])).push(spans[i]);
+ return r;
+ }
+ // Add a span to a line.
+ function addMarkedSpan(line, span) {
+ line.markedSpans = line.markedSpans ? line.markedSpans.concat([span]) : [span];
+ span.marker.attachLine(line);
+ }
+
+ // Used for the algorithm that adjusts markers for a change in the
+ // document. These functions cut an array of spans at a given
+ // character position, returning an array of remaining chunks (or
+ // undefined if nothing remains).
+ function markedSpansBefore(old, startCh, isInsert) {
+ if (old) for (var i = 0, nw; i < old.length; ++i) {
+ var span = old[i], marker = span.marker;
+ var startsBefore = span.from == null || (marker.inclusiveLeft ? span.from <= startCh : span.from < startCh);
+ if (startsBefore || span.from == startCh && marker.type == "bookmark" && (!isInsert || !span.marker.insertLeft)) {
+ var endsAfter = span.to == null || (marker.inclusiveRight ? span.to >= startCh : span.to > startCh);
+ (nw || (nw = [])).push(new MarkedSpan(marker, span.from, endsAfter ? null : span.to));
+ }
+ }
+ return nw;
+ }
+ function markedSpansAfter(old, endCh, isInsert) {
+ if (old) for (var i = 0, nw; i < old.length; ++i) {
+ var span = old[i], marker = span.marker;
+ var endsAfter = span.to == null || (marker.inclusiveRight ? span.to >= endCh : span.to > endCh);
+ if (endsAfter || span.from == endCh && marker.type == "bookmark" && (!isInsert || span.marker.insertLeft)) {
+ var startsBefore = span.from == null || (marker.inclusiveLeft ? span.from <= endCh : span.from < endCh);
+ (nw || (nw = [])).push(new MarkedSpan(marker, startsBefore ? null : span.from - endCh,
+ span.to == null ? null : span.to - endCh));
+ }
+ }
+ return nw;
+ }
+
+ // Given a change object, compute the new set of marker spans that
+ // cover the line in which the change took place. Removes spans
+ // entirely within the change, reconnects spans belonging to the
+ // same marker that appear on both sides of the change, and cuts off
+ // spans partially within the change. Returns an array of span
+ // arrays with one element for each line in (after) the change.
+ function stretchSpansOverChange(doc, change) {
+ var oldFirst = isLine(doc, change.from.line) && getLine(doc, change.from.line).markedSpans;
+ var oldLast = isLine(doc, change.to.line) && getLine(doc, change.to.line).markedSpans;
+ if (!oldFirst && !oldLast) return null;
+
+ var startCh = change.from.ch, endCh = change.to.ch, isInsert = cmp(change.from, change.to) == 0;
+ // Get the spans that 'stick out' on both sides
+ var first = markedSpansBefore(oldFirst, startCh, isInsert);
+ var last = markedSpansAfter(oldLast, endCh, isInsert);
+
+ // Next, merge those two ends
+ var sameLine = change.text.length == 1, offset = lst(change.text).length + (sameLine ? startCh : 0);
+ if (first) {
+ // Fix up .to properties of first
+ for (var i = 0; i < first.length; ++i) {
+ var span = first[i];
+ if (span.to == null) {
+ var found = getMarkedSpanFor(last, span.marker);
+ if (!found) span.to = startCh;
+ else if (sameLine) span.to = found.to == null ? null : found.to + offset;
+ }
+ }
+ }
+ if (last) {
+ // Fix up .from in last (or move them into first in case of sameLine)
+ for (var i = 0; i < last.length; ++i) {
+ var span = last[i];
+ if (span.to != null) span.to += offset;
+ if (span.from == null) {
+ var found = getMarkedSpanFor(first, span.marker);
+ if (!found) {
+ span.from = offset;
+ if (sameLine) (first || (first = [])).push(span);
+ }
+ } else {
+ span.from += offset;
+ if (sameLine) (first || (first = [])).push(span);
+ }
+ }
+ }
+ // Make sure we didn't create any zero-length spans
+ if (first) first = clearEmptySpans(first);
+ if (last && last != first) last = clearEmptySpans(last);
+
+ var newMarkers = [first];
+ if (!sameLine) {
+ // Fill gap with whole-line-spans
+ var gap = change.text.length - 2, gapMarkers;
+ if (gap > 0 && first)
+ for (var i = 0; i < first.length; ++i)
+ if (first[i].to == null)
+ (gapMarkers || (gapMarkers = [])).push(new MarkedSpan(first[i].marker, null, null));
+ for (var i = 0; i < gap; ++i)
+ newMarkers.push(gapMarkers);
+ newMarkers.push(last);
+ }
+ return newMarkers;
+ }
+
+ // Remove spans that are empty and don't have a clearWhenEmpty
+ // option of false.
+ function clearEmptySpans(spans) {
+ for (var i = 0; i < spans.length; ++i) {
+ var span = spans[i];
+ if (span.from != null && span.from == span.to && span.marker.clearWhenEmpty !== false)
+ spans.splice(i--, 1);
+ }
+ if (!spans.length) return null;
+ return spans;
+ }
+
+ // Used for un/re-doing changes from the history. Combines the
+ // result of computing the existing spans with the set of spans that
+ // existed in the history (so that deleting around a span and then
+ // undoing brings back the span).
+ function mergeOldSpans(doc, change) {
+ var old = getOldSpans(doc, change);
+ var stretched = stretchSpansOverChange(doc, change);
+ if (!old) return stretched;
+ if (!stretched) return old;
+
+ for (var i = 0; i < old.length; ++i) {
+ var oldCur = old[i], stretchCur = stretched[i];
+ if (oldCur && stretchCur) {
+ spans: for (var j = 0; j < stretchCur.length; ++j) {
+ var span = stretchCur[j];
+ for (var k = 0; k < oldCur.length; ++k)
+ if (oldCur[k].marker == span.marker) continue spans;
+ oldCur.push(span);
+ }
+ } else if (stretchCur) {
+ old[i] = stretchCur;
+ }
+ }
+ return old;
+ }
+
+ // Used to 'clip' out readOnly ranges when making a change.
+ function removeReadOnlyRanges(doc, from, to) {
+ var markers = null;
+ doc.iter(from.line, to.line + 1, function(line) {
+ if (line.markedSpans) for (var i = 0; i < line.markedSpans.length; ++i) {
+ var mark = line.markedSpans[i].marker;
+ if (mark.readOnly && (!markers || indexOf(markers, mark) == -1))
+ (markers || (markers = [])).push(mark);
+ }
+ });
+ if (!markers) return null;
+ var parts = [{from: from, to: to}];
+ for (var i = 0; i < markers.length; ++i) {
+ var mk = markers[i], m = mk.find(0);
+ for (var j = 0; j < parts.length; ++j) {
+ var p = parts[j];
+ if (cmp(p.to, m.from) < 0 || cmp(p.from, m.to) > 0) continue;
+ var newParts = [j, 1], dfrom = cmp(p.from, m.from), dto = cmp(p.to, m.to);
+ if (dfrom < 0 || !mk.inclusiveLeft && !dfrom)
+ newParts.push({from: p.from, to: m.from});
+ if (dto > 0 || !mk.inclusiveRight && !dto)
+ newParts.push({from: m.to, to: p.to});
+ parts.splice.apply(parts, newParts);
+ j += newParts.length - 1;
+ }
+ }
+ return parts;
+ }
+
+ // Connect or disconnect spans from a line.
+ function detachMarkedSpans(line) {
+ var spans = line.markedSpans;
+ if (!spans) return;
+ for (var i = 0; i < spans.length; ++i)
+ spans[i].marker.detachLine(line);
+ line.markedSpans = null;
+ }
+ function attachMarkedSpans(line, spans) {
+ if (!spans) return;
+ for (var i = 0; i < spans.length; ++i)
+ spans[i].marker.attachLine(line);
+ line.markedSpans = spans;
+ }
+
+ // Helpers used when computing which overlapping collapsed span
+ // counts as the larger one.
+ function extraLeft(marker) { return marker.inclusiveLeft ? -1 : 0; }
+ function extraRight(marker) { return marker.inclusiveRight ? 1 : 0; }
+
+ // Returns a number indicating which of two overlapping collapsed
+ // spans is larger (and thus includes the other). Falls back to
+ // comparing ids when the spans cover exactly the same range.
+ function compareCollapsedMarkers(a, b) {
+ var lenDiff = a.lines.length - b.lines.length;
+ if (lenDiff != 0) return lenDiff;
+ var aPos = a.find(), bPos = b.find();
+ var fromCmp = cmp(aPos.from, bPos.from) || extraLeft(a) - extraLeft(b);
+ if (fromCmp) return -fromCmp;
+ var toCmp = cmp(aPos.to, bPos.to) || extraRight(a) - extraRight(b);
+ if (toCmp) return toCmp;
+ return b.id - a.id;
+ }
+
+ // Find out whether a line ends or starts in a collapsed span. If
+ // so, return the marker for that span.
+ function collapsedSpanAtSide(line, start) {
+ var sps = sawCollapsedSpans && line.markedSpans, found;
+ if (sps) for (var sp, i = 0; i < sps.length; ++i) {
+ sp = sps[i];
+ if (sp.marker.collapsed && (start ? sp.from : sp.to) == null &&
+ (!found || compareCollapsedMarkers(found, sp.marker) < 0))
+ found = sp.marker;
+ }
+ return found;
+ }
+ function collapsedSpanAtStart(line) { return collapsedSpanAtSide(line, true); }
+ function collapsedSpanAtEnd(line) { return collapsedSpanAtSide(line, false); }
+
+ // Test whether there exists a collapsed span that partially
+ // overlaps (covers the start or end, but not both) of a new span.
+ // Such overlap is not allowed.
+ function conflictingCollapsedRange(doc, lineNo, from, to, marker) {
+ var line = getLine(doc, lineNo);
+ var sps = sawCollapsedSpans && line.markedSpans;
+ if (sps) for (var i = 0; i < sps.length; ++i) {
+ var sp = sps[i];
+ if (!sp.marker.collapsed) continue;
+ var found = sp.marker.find(0);
+ var fromCmp = cmp(found.from, from) || extraLeft(sp.marker) - extraLeft(marker);
+ var toCmp = cmp(found.to, to) || extraRight(sp.marker) - extraRight(marker);
+ if (fromCmp >= 0 && toCmp <= 0 || fromCmp <= 0 && toCmp >= 0) continue;
+ if (fromCmp <= 0 && (cmp(found.to, from) || extraRight(sp.marker) - extraLeft(marker)) > 0 ||
+ fromCmp >= 0 && (cmp(found.from, to) || extraLeft(sp.marker) - extraRight(marker)) < 0)
+ return true;
+ }
+ }
+
+ // A visual line is a line as drawn on the screen. Folding, for
+ // example, can cause multiple logical lines to appear on the same
+ // visual line. This finds the start of the visual line that the
+ // given line is part of (usually that is the line itself).
+ function visualLine(line) {
+ var merged;
+ while (merged = collapsedSpanAtStart(line))
+ line = merged.find(-1, true).line;
+ return line;
+ }
+
+ // Returns an array of logical lines that continue the visual line
+ // started by the argument, or undefined if there are no such lines.
+ function visualLineContinued(line) {
+ var merged, lines;
+ while (merged = collapsedSpanAtEnd(line)) {
+ line = merged.find(1, true).line;
+ (lines || (lines = [])).push(line);
+ }
+ return lines;
+ }
+
+ // Get the line number of the start of the visual line that the
+ // given line number is part of.
+ function visualLineNo(doc, lineN) {
+ var line = getLine(doc, lineN), vis = visualLine(line);
+ if (line == vis) return lineN;
+ return lineNo(vis);
+ }
+ // Get the line number of the start of the next visual line after
+ // the given line.
+ function visualLineEndNo(doc, lineN) {
+ if (lineN > doc.lastLine()) return lineN;
+ var line = getLine(doc, lineN), merged;
+ if (!lineIsHidden(doc, line)) return lineN;
+ while (merged = collapsedSpanAtEnd(line))
+ line = merged.find(1, true).line;
+ return lineNo(line) + 1;
+ }
+
+ // Compute whether a line is hidden. Lines count as hidden when they
+ // are part of a visual line that starts with another line, or when
+ // they are entirely covered by collapsed, non-widget span.
+ function lineIsHidden(doc, line) {
+ var sps = sawCollapsedSpans && line.markedSpans;
+ if (sps) for (var sp, i = 0; i < sps.length; ++i) {
+ sp = sps[i];
+ if (!sp.marker.collapsed) continue;
+ if (sp.from == null) return true;
+ if (sp.marker.widgetNode) continue;
+ if (sp.from == 0 && sp.marker.inclusiveLeft && lineIsHiddenInner(doc, line, sp))
+ return true;
+ }
+ }
+ function lineIsHiddenInner(doc, line, span) {
+ if (span.to == null) {
+ var end = span.marker.find(1, true);
+ return lineIsHiddenInner(doc, end.line, getMarkedSpanFor(end.line.markedSpans, span.marker));
+ }
+ if (span.marker.inclusiveRight && span.to == line.text.length)
+ return true;
+ for (var sp, i = 0; i < line.markedSpans.length; ++i) {
+ sp = line.markedSpans[i];
+ if (sp.marker.collapsed && !sp.marker.widgetNode && sp.from == span.to &&
+ (sp.to == null || sp.to != span.from) &&
+ (sp.marker.inclusiveLeft || span.marker.inclusiveRight) &&
+ lineIsHiddenInner(doc, line, sp)) return true;
+ }
+ }
+
+ // LINE WIDGETS
+
+ // Line widgets are block elements displayed above or below a line.
+
+ var LineWidget = CodeMirror.LineWidget = function(cm, node, options) {
+ if (options) for (var opt in options) if (options.hasOwnProperty(opt))
+ this[opt] = options[opt];
+ this.cm = cm;
+ this.node = node;
+ };
+ eventMixin(LineWidget);
+
+ function adjustScrollWhenAboveVisible(cm, line, diff) {
+ if (heightAtLine(line) < ((cm.curOp && cm.curOp.scrollTop) || cm.doc.scrollTop))
+ addToScrollPos(cm, null, diff);
+ }
+
+ LineWidget.prototype.clear = function() {
+ var cm = this.cm, ws = this.line.widgets, line = this.line, no = lineNo(line);
+ if (no == null || !ws) return;
+ for (var i = 0; i < ws.length; ++i) if (ws[i] == this) ws.splice(i--, 1);
+ if (!ws.length) line.widgets = null;
+ var height = widgetHeight(this);
+ runInOp(cm, function() {
+ adjustScrollWhenAboveVisible(cm, line, -height);
+ regLineChange(cm, no, "widget");
+ updateLineHeight(line, Math.max(0, line.height - height));
+ });
+ };
+ LineWidget.prototype.changed = function() {
+ var oldH = this.height, cm = this.cm, line = this.line;
+ this.height = null;
+ var diff = widgetHeight(this) - oldH;
+ if (!diff) return;
+ runInOp(cm, function() {
+ cm.curOp.forceUpdate = true;
+ adjustScrollWhenAboveVisible(cm, line, diff);
+ updateLineHeight(line, line.height + diff);
+ });
+ };
+
+ function widgetHeight(widget) {
+ if (widget.height != null) return widget.height;
+ if (!contains(document.body, widget.node))
+ removeChildrenAndAdd(widget.cm.display.measure, elt("div", [widget.node], null, "position: relative"));
+ return widget.height = widget.node.offsetHeight;
+ }
+
+ function addLineWidget(cm, handle, node, options) {
+ var widget = new LineWidget(cm, node, options);
+ if (widget.noHScroll) cm.display.alignWidgets = true;
+ changeLine(cm, handle, "widget", function(line) {
+ var widgets = line.widgets || (line.widgets = []);
+ if (widget.insertAt == null) widgets.push(widget);
+ else widgets.splice(Math.min(widgets.length - 1, Math.max(0, widget.insertAt)), 0, widget);
+ widget.line = line;
+ if (!lineIsHidden(cm.doc, line)) {
+ var aboveVisible = heightAtLine(line) < cm.doc.scrollTop;
+ updateLineHeight(line, line.height + widgetHeight(widget));
+ if (aboveVisible) addToScrollPos(cm, null, widget.height);
+ cm.curOp.forceUpdate = true;
+ }
+ return true;
+ });
+ return widget;
+ }
+
+ // LINE DATA STRUCTURE
+
+ // Line objects. These hold state related to a line, including
+ // highlighting info (the styles array).
+ var Line = CodeMirror.Line = function(text, markedSpans, estimateHeight) {
+ this.text = text;
+ attachMarkedSpans(this, markedSpans);
+ this.height = estimateHeight ? estimateHeight(this) : 1;
+ };
+ eventMixin(Line);
+ Line.prototype.lineNo = function() { return lineNo(this); };
+
+ // Change the content (text, markers) of a line. Automatically
+ // invalidates cached information and tries to re-estimate the
+ // line's height.
+ function updateLine(line, text, markedSpans, estimateHeight) {
+ line.text = text;
+ if (line.stateAfter) line.stateAfter = null;
+ if (line.styles) line.styles = null;
+ if (line.order != null) line.order = null;
+ detachMarkedSpans(line);
+ attachMarkedSpans(line, markedSpans);
+ var estHeight = estimateHeight ? estimateHeight(line) : 1;
+ if (estHeight != line.height) updateLineHeight(line, estHeight);
+ }
+
+ // Detach a line from the document tree and its markers.
+ function cleanUpLine(line) {
+ line.parent = null;
+ detachMarkedSpans(line);
+ }
+
+ function extractLineClasses(type, output) {
+ if (type) for (;;) {
+ var lineClass = type.match(/(?:^|\s+)line-(background-)?(\S+)/);
+ if (!lineClass) break;
+ type = type.slice(0, lineClass.index) + type.slice(lineClass.index + lineClass[0].length);
+ var prop = lineClass[1] ? "bgClass" : "textClass";
+ if (output[prop] == null)
+ output[prop] = lineClass[2];
+ else if (!(new RegExp("(?:^|\s)" + lineClass[2] + "(?:$|\s)")).test(output[prop]))
+ output[prop] += " " + lineClass[2];
+ }
+ return type;
+ }
+
+ function callBlankLine(mode, state) {
+ if (mode.blankLine) return mode.blankLine(state);
+ if (!mode.innerMode) return;
+ var inner = CodeMirror.innerMode(mode, state);
+ if (inner.mode.blankLine) return inner.mode.blankLine(inner.state);
+ }
+
+ function readToken(mode, stream, state) {
+ var style = mode.token(stream, state);
+ if (stream.pos <= stream.start)
+ throw new Error("Mode " + mode.name + " failed to advance stream.");
+ return style;
+ }
+
+ // Run the given mode's parser over a line, calling f for each token.
+ function runMode(cm, text, mode, state, f, lineClasses, forceToEnd) {
+ var flattenSpans = mode.flattenSpans;
+ if (flattenSpans == null) flattenSpans = cm.options.flattenSpans;
+ var curStart = 0, curStyle = null;
+ var stream = new StringStream(text, cm.options.tabSize), style;
+ if (text == "") extractLineClasses(callBlankLine(mode, state), lineClasses);
+ while (!stream.eol()) {
+ if (stream.pos > cm.options.maxHighlightLength) {
+ flattenSpans = false;
+ if (forceToEnd) processLine(cm, text, state, stream.pos);
+ stream.pos = text.length;
+ style = null;
+ } else {
+ style = extractLineClasses(readToken(mode, stream, state), lineClasses);
+ }
+ if (cm.options.addModeClass) {
+ var mName = CodeMirror.innerMode(mode, state).mode.name;
+ if (mName) style = "m-" + (style ? mName + " " + style : mName);
+ }
+ if (!flattenSpans || curStyle != style) {
+ if (curStart < stream.start) f(stream.start, curStyle);
+ curStart = stream.start; curStyle = style;
+ }
+ stream.start = stream.pos;
+ }
+ while (curStart < stream.pos) {
+ // Webkit seems to refuse to render text nodes longer than 57444 characters
+ var pos = Math.min(stream.pos, curStart + 50000);
+ f(pos, curStyle);
+ curStart = pos;
+ }
+ }
+
+ // Compute a style array (an array starting with a mode generation
+ // -- for invalidation -- followed by pairs of end positions and
+ // style strings), which is used to highlight the tokens on the
+ // line.
+ function highlightLine(cm, line, state, forceToEnd) {
+ // A styles array always starts with a number identifying the
+ // mode/overlays that it is based on (for easy invalidation).
+ var st = [cm.state.modeGen], lineClasses = {};
+ // Compute the base array of styles
+ runMode(cm, line.text, cm.doc.mode, state, function(end, style) {
+ st.push(end, style);
+ }, lineClasses, forceToEnd);
+
+ // Run overlays, adjust style array.
+ for (var o = 0; o < cm.state.overlays.length; ++o) {
+ var overlay = cm.state.overlays[o], i = 1, at = 0;
+ runMode(cm, line.text, overlay.mode, true, function(end, style) {
+ var start = i;
+ // Ensure there's a token end at the current position, and that i points at it
+ while (at < end) {
+ var i_end = st[i];
+ if (i_end > end)
+ st.splice(i, 1, end, st[i+1], i_end);
+ i += 2;
+ at = Math.min(end, i_end);
+ }
+ if (!style) return;
+ if (overlay.opaque) {
+ st.splice(start, i - start, end, "cm-overlay " + style);
+ i = start + 2;
+ } else {
+ for (; start < i; start += 2) {
+ var cur = st[start+1];
+ st[start+1] = (cur ? cur + " " : "") + "cm-overlay " + style;
+ }
+ }
+ }, lineClasses);
+ }
+
+ return {styles: st, classes: lineClasses.bgClass || lineClasses.textClass ? lineClasses : null};
+ }
+
+ function getLineStyles(cm, line) {
+ if (!line.styles || line.styles[0] != cm.state.modeGen) {
+ var result = highlightLine(cm, line, line.stateAfter = getStateBefore(cm, lineNo(line)));
+ line.styles = result.styles;
+ if (result.classes) line.styleClasses = result.classes;
+ else if (line.styleClasses) line.styleClasses = null;
+ }
+ return line.styles;
+ }
+
+ // Lightweight form of highlight -- proceed over this line and
+ // update state, but don't save a style array. Used for lines that
+ // aren't currently visible.
+ function processLine(cm, text, state, startAt) {
+ var mode = cm.doc.mode;
+ var stream = new StringStream(text, cm.options.tabSize);
+ stream.start = stream.pos = startAt || 0;
+ if (text == "") callBlankLine(mode, state);
+ while (!stream.eol() && stream.pos <= cm.options.maxHighlightLength) {
+ readToken(mode, stream, state);
+ stream.start = stream.pos;
+ }
+ }
+
+ // Convert a style as returned by a mode (either null, or a string
+ // containing one or more styles) to a CSS style. This is cached,
+ // and also looks for line-wide styles.
+ var styleToClassCache = {}, styleToClassCacheWithMode = {};
+ function interpretTokenStyle(style, options) {
+ if (!style || /^\s*$/.test(style)) return null;
+ var cache = options.addModeClass ? styleToClassCacheWithMode : styleToClassCache;
+ return cache[style] ||
+ (cache[style] = style.replace(/\S+/g, "cm-$&"));
+ }
+
+ // Render the DOM representation of the text of a line. Also builds
+ // up a 'line map', which points at the DOM nodes that represent
+ // specific stretches of text, and is used by the measuring code.
+ // The returned object contains the DOM node, this map, and
+ // information about line-wide styles that were set by the mode.
+ function buildLineContent(cm, lineView) {
+ // The padding-right forces the element to have a 'border', which
+ // is needed on Webkit to be able to get line-level bounding
+ // rectangles for it (in measureChar).
+ var content = elt("span", null, null, webkit ? "padding-right: .1px" : null);
+ var builder = {pre: elt("pre", [content]), content: content, col: 0, pos: 0, cm: cm};
+ lineView.measure = {};
+
+ // Iterate over the logical lines that make up this visual line.
+ for (var i = 0; i <= (lineView.rest ? lineView.rest.length : 0); i++) {
+ var line = i ? lineView.rest[i - 1] : lineView.line, order;
+ builder.pos = 0;
+ builder.addToken = buildToken;
+ // Optionally wire in some hacks into the token-rendering
+ // algorithm, to deal with browser quirks.
+ if ((ie || webkit) && cm.getOption("lineWrapping"))
+ builder.addToken = buildTokenSplitSpaces(builder.addToken);
+ if (hasBadBidiRects(cm.display.measure) && (order = getOrder(line)))
+ builder.addToken = buildTokenBadBidi(builder.addToken, order);
+ builder.map = [];
+ insertLineContent(line, builder, getLineStyles(cm, line));
+ if (line.styleClasses) {
+ if (line.styleClasses.bgClass)
+ builder.bgClass = joinClasses(line.styleClasses.bgClass, builder.bgClass || "");
+ if (line.styleClasses.textClass)
+ builder.textClass = joinClasses(line.styleClasses.textClass, builder.textClass || "");
+ }
+
+ // Ensure at least a single node is present, for measuring.
+ if (builder.map.length == 0)
+ builder.map.push(0, 0, builder.content.appendChild(zeroWidthElement(cm.display.measure)));
+
+ // Store the map and a cache object for the current logical line
+ if (i == 0) {
+ lineView.measure.map = builder.map;
+ lineView.measure.cache = {};
+ } else {
+ (lineView.measure.maps || (lineView.measure.maps = [])).push(builder.map);
+ (lineView.measure.caches || (lineView.measure.caches = [])).push({});
+ }
+ }
+
+ signal(cm, "renderLine", cm, lineView.line, builder.pre);
+ return builder;
+ }
+
+ function defaultSpecialCharPlaceholder(ch) {
+ var token = elt("span", "\u2022", "cm-invalidchar");
+ token.title = "\\u" + ch.charCodeAt(0).toString(16);
+ return token;
+ }
+
+ // Build up the DOM representation for a single token, and add it to
+ // the line map. Takes care to render special characters separately.
+ function buildToken(builder, text, style, startStyle, endStyle, title) {
+ if (!text) return;
+ var special = builder.cm.options.specialChars, mustWrap = false;
+ if (!special.test(text)) {
+ builder.col += text.length;
+ var content = document.createTextNode(text);
+ builder.map.push(builder.pos, builder.pos + text.length, content);
+ if (ie_upto8) mustWrap = true;
+ builder.pos += text.length;
+ } else {
+ var content = document.createDocumentFragment(), pos = 0;
+ while (true) {
+ special.lastIndex = pos;
+ var m = special.exec(text);
+ var skipped = m ? m.index - pos : text.length - pos;
+ if (skipped) {
+ var txt = document.createTextNode(text.slice(pos, pos + skipped));
+ if (ie_upto8) content.appendChild(elt("span", [txt]));
+ else content.appendChild(txt);
+ builder.map.push(builder.pos, builder.pos + skipped, txt);
+ builder.col += skipped;
+ builder.pos += skipped;
+ }
+ if (!m) break;
+ pos += skipped + 1;
+ if (m[0] == "\t") {
+ var tabSize = builder.cm.options.tabSize, tabWidth = tabSize - builder.col % tabSize;
+ var txt = content.appendChild(elt("span", spaceStr(tabWidth), "cm-tab"));
+ builder.col += tabWidth;
+ } else {
+ var txt = builder.cm.options.specialCharPlaceholder(m[0]);
+ if (ie_upto8) content.appendChild(elt("span", [txt]));
+ else content.appendChild(txt);
+ builder.col += 1;
+ }
+ builder.map.push(builder.pos, builder.pos + 1, txt);
+ builder.pos++;
+ }
+ }
+ if (style || startStyle || endStyle || mustWrap) {
+ var fullStyle = style || "";
+ if (startStyle) fullStyle += startStyle;
+ if (endStyle) fullStyle += endStyle;
+ var token = elt("span", [content], fullStyle);
+ if (title) token.title = title;
+ return builder.content.appendChild(token);
+ }
+ builder.content.appendChild(content);
+ }
+
+ function buildTokenSplitSpaces(inner) {
+ function split(old) {
+ var out = " ";
+ for (var i = 0; i < old.length - 2; ++i) out += i % 2 ? " " : "\u00a0";
+ out += " ";
+ return out;
+ }
+ return function(builder, text, style, startStyle, endStyle, title) {
+ inner(builder, text.replace(/ {3,}/g, split), style, startStyle, endStyle, title);
+ };
+ }
+
+ // Work around nonsense dimensions being reported for stretches of
+ // right-to-left text.
+ function buildTokenBadBidi(inner, order) {
+ return function(builder, text, style, startStyle, endStyle, title) {
+ style = style ? style + " cm-force-border" : "cm-force-border";
+ var start = builder.pos, end = start + text.length;
+ for (;;) {
+ // Find the part that overlaps with the start of this text
+ for (var i = 0; i < order.length; i++) {
+ var part = order[i];
+ if (part.to > start && part.from <= start) break;
+ }
+ if (part.to >= end) return inner(builder, text, style, startStyle, endStyle, title);
+ inner(builder, text.slice(0, part.to - start), style, startStyle, null, title);
+ startStyle = null;
+ text = text.slice(part.to - start);
+ start = part.to;
+ }
+ };
+ }
+
+ function buildCollapsedSpan(builder, size, marker, ignoreWidget) {
+ var widget = !ignoreWidget && marker.widgetNode;
+ if (widget) {
+ builder.map.push(builder.pos, builder.pos + size, widget);
+ builder.content.appendChild(widget);
+ }
+ builder.pos += size;
+ }
+
+ // Outputs a number of spans to make up a line, taking highlighting
+ // and marked text into account.
+ function insertLineContent(line, builder, styles) {
+ var spans = line.markedSpans, allText = line.text, at = 0;
+ if (!spans) {
+ for (var i = 1; i < styles.length; i+=2)
+ builder.addToken(builder, allText.slice(at, at = styles[i]), interpretTokenStyle(styles[i+1], builder.cm.options));
+ return;
+ }
+
+ var len = allText.length, pos = 0, i = 1, text = "", style;
+ var nextChange = 0, spanStyle, spanEndStyle, spanStartStyle, title, collapsed;
+ for (;;) {
+ if (nextChange == pos) { // Update current marker set
+ spanStyle = spanEndStyle = spanStartStyle = title = "";
+ collapsed = null; nextChange = Infinity;
+ var foundBookmarks = [];
+ for (var j = 0; j < spans.length; ++j) {
+ var sp = spans[j], m = sp.marker;
+ if (sp.from <= pos && (sp.to == null || sp.to > pos)) {
+ if (sp.to != null && nextChange > sp.to) { nextChange = sp.to; spanEndStyle = ""; }
+ if (m.className) spanStyle += " " + m.className;
+ if (m.startStyle && sp.from == pos) spanStartStyle += " " + m.startStyle;
+ if (m.endStyle && sp.to == nextChange) spanEndStyle += " " + m.endStyle;
+ if (m.title && !title) title = m.title;
+ if (m.collapsed && (!collapsed || compareCollapsedMarkers(collapsed.marker, m) < 0))
+ collapsed = sp;
+ } else if (sp.from > pos && nextChange > sp.from) {
+ nextChange = sp.from;
+ }
+ if (m.type == "bookmark" && sp.from == pos && m.widgetNode) foundBookmarks.push(m);
+ }
+ if (collapsed && (collapsed.from || 0) == pos) {
+ buildCollapsedSpan(builder, (collapsed.to == null ? len + 1 : collapsed.to) - pos,
+ collapsed.marker, collapsed.from == null);
+ if (collapsed.to == null) return;
+ }
+ if (!collapsed && foundBookmarks.length) for (var j = 0; j < foundBookmarks.length; ++j)
+ buildCollapsedSpan(builder, 0, foundBookmarks[j]);
+ }
+ if (pos >= len) break;
+
+ var upto = Math.min(len, nextChange);
+ while (true) {
+ if (text) {
+ var end = pos + text.length;
+ if (!collapsed) {
+ var tokenText = end > upto ? text.slice(0, upto - pos) : text;
+ builder.addToken(builder, tokenText, style ? style + spanStyle : spanStyle,
+ spanStartStyle, pos + tokenText.length == nextChange ? spanEndStyle : "", title);
+ }
+ if (end >= upto) {text = text.slice(upto - pos); pos = upto; break;}
+ pos = end;
+ spanStartStyle = "";
+ }
+ text = allText.slice(at, at = styles[i++]);
+ style = interpretTokenStyle(styles[i++], builder.cm.options);
+ }
+ }
+ }
+
+ // DOCUMENT DATA STRUCTURE
+
+ // By default, updates that start and end at the beginning of a line
+ // are treated specially, in order to make the association of line
+ // widgets and marker elements with the text behave more intuitive.
+ function isWholeLineUpdate(doc, change) {
+ return change.from.ch == 0 && change.to.ch == 0 && lst(change.text) == "" &&
+ (!doc.cm || doc.cm.options.wholeLineUpdateBefore);
+ }
+
+ // Perform a change on the document data structure.
+ function updateDoc(doc, change, markedSpans, estimateHeight) {
+ function spansFor(n) {return markedSpans ? markedSpans[n] : null;}
+ function update(line, text, spans) {
+ updateLine(line, text, spans, estimateHeight);
+ signalLater(line, "change", line, change);
+ }
+
+ var from = change.from, to = change.to, text = change.text;
+ var firstLine = getLine(doc, from.line), lastLine = getLine(doc, to.line);
+ var lastText = lst(text), lastSpans = spansFor(text.length - 1), nlines = to.line - from.line;
+
+ // Adjust the line structure
+ if (isWholeLineUpdate(doc, change)) {
+ // This is a whole-line replace. Treated specially to make
+ // sure line objects move the way they are supposed to.
+ for (var i = 0, added = []; i < text.length - 1; ++i)
+ added.push(new Line(text[i], spansFor(i), estimateHeight));
+ update(lastLine, lastLine.text, lastSpans);
+ if (nlines) doc.remove(from.line, nlines);
+ if (added.length) doc.insert(from.line, added);
+ } else if (firstLine == lastLine) {
+ if (text.length == 1) {
+ update(firstLine, firstLine.text.slice(0, from.ch) + lastText + firstLine.text.slice(to.ch), lastSpans);
+ } else {
+ for (var added = [], i = 1; i < text.length - 1; ++i)
+ added.push(new Line(text[i], spansFor(i), estimateHeight));
+ added.push(new Line(lastText + firstLine.text.slice(to.ch), lastSpans, estimateHeight));
+ update(firstLine, firstLine.text.slice(0, from.ch) + text[0], spansFor(0));
+ doc.insert(from.line + 1, added);
+ }
+ } else if (text.length == 1) {
+ update(firstLine, firstLine.text.slice(0, from.ch) + text[0] + lastLine.text.slice(to.ch), spansFor(0));
+ doc.remove(from.line + 1, nlines);
+ } else {
+ update(firstLine, firstLine.text.slice(0, from.ch) + text[0], spansFor(0));
+ update(lastLine, lastText + lastLine.text.slice(to.ch), lastSpans);
+ for (var i = 1, added = []; i < text.length - 1; ++i)
+ added.push(new Line(text[i], spansFor(i), estimateHeight));
+ if (nlines > 1) doc.remove(from.line + 1, nlines - 1);
+ doc.insert(from.line + 1, added);
+ }
+
+ signalLater(doc, "change", doc, change);
+ }
+
+ // The document is represented as a BTree consisting of leaves, with
+ // chunk of lines in them, and branches, with up to ten leaves or
+ // other branch nodes below them. The top node is always a branch
+ // node, and is the document object itself (meaning it has
+ // additional methods and properties).
+ //
+ // All nodes have parent links. The tree is used both to go from
+ // line numbers to line objects, and to go from objects to numbers.
+ // It also indexes by height, and is used to convert between height
+ // and line object, and to find the total height of the document.
+ //
+ // See also http://marijnhaverbeke.nl/blog/codemirror-line-tree.html
+
+ function LeafChunk(lines) {
+ this.lines = lines;
+ this.parent = null;
+ for (var i = 0, height = 0; i < lines.length; ++i) {
+ lines[i].parent = this;
+ height += lines[i].height;
+ }
+ this.height = height;
+ }
+
+ LeafChunk.prototype = {
+ chunkSize: function() { return this.lines.length; },
+ // Remove the n lines at offset 'at'.
+ removeInner: function(at, n) {
+ for (var i = at, e = at + n; i < e; ++i) {
+ var line = this.lines[i];
+ this.height -= line.height;
+ cleanUpLine(line);
+ signalLater(line, "delete");
+ }
+ this.lines.splice(at, n);
+ },
+ // Helper used to collapse a small branch into a single leaf.
+ collapse: function(lines) {
+ lines.push.apply(lines, this.lines);
+ },
+ // Insert the given array of lines at offset 'at', count them as
+ // having the given height.
+ insertInner: function(at, lines, height) {
+ this.height += height;
+ this.lines = this.lines.slice(0, at).concat(lines).concat(this.lines.slice(at));
+ for (var i = 0; i < lines.length; ++i) lines[i].parent = this;
+ },
+ // Used to iterate over a part of the tree.
+ iterN: function(at, n, op) {
+ for (var e = at + n; at < e; ++at)
+ if (op(this.lines[at])) return true;
+ }
+ };
+
+ function BranchChunk(children) {
+ this.children = children;
+ var size = 0, height = 0;
+ for (var i = 0; i < children.length; ++i) {
+ var ch = children[i];
+ size += ch.chunkSize(); height += ch.height;
+ ch.parent = this;
+ }
+ this.size = size;
+ this.height = height;
+ this.parent = null;
+ }
+
+ BranchChunk.prototype = {
+ chunkSize: function() { return this.size; },
+ removeInner: function(at, n) {
+ this.size -= n;
+ for (var i = 0; i < this.children.length; ++i) {
+ var child = this.children[i], sz = child.chunkSize();
+ if (at < sz) {
+ var rm = Math.min(n, sz - at), oldHeight = child.height;
+ child.removeInner(at, rm);
+ this.height -= oldHeight - child.height;
+ if (sz == rm) { this.children.splice(i--, 1); child.parent = null; }
+ if ((n -= rm) == 0) break;
+ at = 0;
+ } else at -= sz;
+ }
+ // If the result is smaller than 25 lines, ensure that it is a
+ // single leaf node.
+ if (this.size - n < 25 &&
+ (this.children.length > 1 || !(this.children[0] instanceof LeafChunk))) {
+ var lines = [];
+ this.collapse(lines);
+ this.children = [new LeafChunk(lines)];
+ this.children[0].parent = this;
+ }
+ },
+ collapse: function(lines) {
+ for (var i = 0; i < this.children.length; ++i) this.children[i].collapse(lines);
+ },
+ insertInner: function(at, lines, height) {
+ this.size += lines.length;
+ this.height += height;
+ for (var i = 0; i < this.children.length; ++i) {
+ var child = this.children[i], sz = child.chunkSize();
+ if (at <= sz) {
+ child.insertInner(at, lines, height);
+ if (child.lines && child.lines.length > 50) {
+ while (child.lines.length > 50) {
+ var spilled = child.lines.splice(child.lines.length - 25, 25);
+ var newleaf = new LeafChunk(spilled);
+ child.height -= newleaf.height;
+ this.children.splice(i + 1, 0, newleaf);
+ newleaf.parent = this;
+ }
+ this.maybeSpill();
+ }
+ break;
+ }
+ at -= sz;
+ }
+ },
+ // When a node has grown, check whether it should be split.
+ maybeSpill: function() {
+ if (this.children.length <= 10) return;
+ var me = this;
+ do {
+ var spilled = me.children.splice(me.children.length - 5, 5);
+ var sibling = new BranchChunk(spilled);
+ if (!me.parent) { // Become the parent node
+ var copy = new BranchChunk(me.children);
+ copy.parent = me;
+ me.children = [copy, sibling];
+ me = copy;
+ } else {
+ me.size -= sibling.size;
+ me.height -= sibling.height;
+ var myIndex = indexOf(me.parent.children, me);
+ me.parent.children.splice(myIndex + 1, 0, sibling);
+ }
+ sibling.parent = me.parent;
+ } while (me.children.length > 10);
+ me.parent.maybeSpill();
+ },
+ iterN: function(at, n, op) {
+ for (var i = 0; i < this.children.length; ++i) {
+ var child = this.children[i], sz = child.chunkSize();
+ if (at < sz) {
+ var used = Math.min(n, sz - at);
+ if (child.iterN(at, used, op)) return true;
+ if ((n -= used) == 0) break;
+ at = 0;
+ } else at -= sz;
+ }
+ }
+ };
+
+ var nextDocId = 0;
+ var Doc = CodeMirror.Doc = function(text, mode, firstLine) {
+ if (!(this instanceof Doc)) return new Doc(text, mode, firstLine);
+ if (firstLine == null) firstLine = 0;
+
+ BranchChunk.call(this, [new LeafChunk([new Line("", null)])]);
+ this.first = firstLine;
+ this.scrollTop = this.scrollLeft = 0;
+ this.cantEdit = false;
+ this.cleanGeneration = 1;
+ this.frontier = firstLine;
+ var start = Pos(firstLine, 0);
+ this.sel = simpleSelection(start);
+ this.history = new History(null);
+ this.id = ++nextDocId;
+ this.modeOption = mode;
+
+ if (typeof text == "string") text = splitLines(text);
+ updateDoc(this, {from: start, to: start, text: text});
+ setSelection(this, simpleSelection(start), sel_dontScroll);
+ };
+
+ Doc.prototype = createObj(BranchChunk.prototype, {
+ constructor: Doc,
+ // Iterate over the document. Supports two forms -- with only one
+ // argument, it calls that for each line in the document. With
+ // three, it iterates over the range given by the first two (with
+ // the second being non-inclusive).
+ iter: function(from, to, op) {
+ if (op) this.iterN(from - this.first, to - from, op);
+ else this.iterN(this.first, this.first + this.size, from);
+ },
+
+ // Non-public interface for adding and removing lines.
+ insert: function(at, lines) {
+ var height = 0;
+ for (var i = 0; i < lines.length; ++i) height += lines[i].height;
+ this.insertInner(at - this.first, lines, height);
+ },
+ remove: function(at, n) { this.removeInner(at - this.first, n); },
+
+ // From here, the methods are part of the public interface. Most
+ // are also available from CodeMirror (editor) instances.
+
+ getValue: function(lineSep) {
+ var lines = getLines(this, this.first, this.first + this.size);
+ if (lineSep === false) return lines;
+ return lines.join(lineSep || "\n");
+ },
+ setValue: docMethodOp(function(code) {
+ var top = Pos(this.first, 0), last = this.first + this.size - 1;
+ makeChange(this, {from: top, to: Pos(last, getLine(this, last).text.length),
+ text: splitLines(code), origin: "setValue"}, true);
+ setSelection(this, simpleSelection(top));
+ }),
+ replaceRange: function(code, from, to, origin) {
+ from = clipPos(this, from);
+ to = to ? clipPos(this, to) : from;
+ replaceRange(this, code, from, to, origin);
+ },
+ getRange: function(from, to, lineSep) {
+ var lines = getBetween(this, clipPos(this, from), clipPos(this, to));
+ if (lineSep === false) return lines;
+ return lines.join(lineSep || "\n");
+ },
+
+ getLine: function(line) {var l = this.getLineHandle(line); return l && l.text;},
+
+ getLineHandle: function(line) {if (isLine(this, line)) return getLine(this, line);},
+ getLineNumber: function(line) {return lineNo(line);},
+
+ getLineHandleVisualStart: function(line) {
+ if (typeof line == "number") line = getLine(this, line);
+ return visualLine(line);
+ },
+
+ lineCount: function() {return this.size;},
+ firstLine: function() {return this.first;},
+ lastLine: function() {return this.first + this.size - 1;},
+
+ clipPos: function(pos) {return clipPos(this, pos);},
+
+ getCursor: function(start) {
+ var range = this.sel.primary(), pos;
+ if (start == null || start == "head") pos = range.head;
+ else if (start == "anchor") pos = range.anchor;
+ else if (start == "end" || start == "to" || start === false) pos = range.to();
+ else pos = range.from();
+ return pos;
+ },
+ listSelections: function() { return this.sel.ranges; },
+ somethingSelected: function() {return this.sel.somethingSelected();},
+
+ setCursor: docMethodOp(function(line, ch, options) {
+ setSimpleSelection(this, clipPos(this, typeof line == "number" ? Pos(line, ch || 0) : line), null, options);
+ }),
+ setSelection: docMethodOp(function(anchor, head, options) {
+ setSimpleSelection(this, clipPos(this, anchor), clipPos(this, head || anchor), options);
+ }),
+ extendSelection: docMethodOp(function(head, other, options) {
+ extendSelection(this, clipPos(this, head), other && clipPos(this, other), options);
+ }),
+ extendSelections: docMethodOp(function(heads, options) {
+ extendSelections(this, clipPosArray(this, heads, options));
+ }),
+ extendSelectionsBy: docMethodOp(function(f, options) {
+ extendSelections(this, map(this.sel.ranges, f), options);
+ }),
+ setSelections: docMethodOp(function(ranges, primary, options) {
+ if (!ranges.length) return;
+ for (var i = 0, out = []; i < ranges.length; i++)
+ out[i] = new Range(clipPos(this, ranges[i].anchor),
+ clipPos(this, ranges[i].head));
+ if (primary == null) primary = Math.min(ranges.length - 1, this.sel.primIndex);
+ setSelection(this, normalizeSelection(out, primary), options);
+ }),
+ addSelection: docMethodOp(function(anchor, head, options) {
+ var ranges = this.sel.ranges.slice(0);
+ ranges.push(new Range(clipPos(this, anchor), clipPos(this, head || anchor)));
+ setSelection(this, normalizeSelection(ranges, ranges.length - 1), options);
+ }),
+
+ getSelection: function(lineSep) {
+ var ranges = this.sel.ranges, lines;
+ for (var i = 0; i < ranges.length; i++) {
+ var sel = getBetween(this, ranges[i].from(), ranges[i].to());
+ lines = lines ? lines.concat(sel) : sel;
+ }
+ if (lineSep === false) return lines;
+ else return lines.join(lineSep || "\n");
+ },
+ getSelections: function(lineSep) {
+ var parts = [], ranges = this.sel.ranges;
+ for (var i = 0; i < ranges.length; i++) {
+ var sel = getBetween(this, ranges[i].from(), ranges[i].to());
+ if (lineSep !== false) sel = sel.join(lineSep || "\n");
+ parts[i] = sel;
+ }
+ return parts;
+ },
+ replaceSelection: function(code, collapse, origin) {
+ var dup = [];
+ for (var i = 0; i < this.sel.ranges.length; i++)
+ dup[i] = code;
+ this.replaceSelections(dup, collapse, origin || "+input");
+ },
+ replaceSelections: docMethodOp(function(code, collapse, origin) {
+ var changes = [], sel = this.sel;
+ for (var i = 0; i < sel.ranges.length; i++) {
+ var range = sel.ranges[i];
+ changes[i] = {from: range.from(), to: range.to(), text: splitLines(code[i]), origin: origin};
+ }
+ var newSel = collapse && collapse != "end" && computeReplacedSel(this, changes, collapse);
+ for (var i = changes.length - 1; i >= 0; i--)
+ makeChange(this, changes[i]);
+ if (newSel) setSelectionReplaceHistory(this, newSel);
+ else if (this.cm) ensureCursorVisible(this.cm);
+ }),
+ undo: docMethodOp(function() {makeChangeFromHistory(this, "undo");}),
+ redo: docMethodOp(function() {makeChangeFromHistory(this, "redo");}),
+ undoSelection: docMethodOp(function() {makeChangeFromHistory(this, "undo", true);}),
+ redoSelection: docMethodOp(function() {makeChangeFromHistory(this, "redo", true);}),
+
+ setExtending: function(val) {this.extend = val;},
+ getExtending: function() {return this.extend;},
+
+ historySize: function() {
+ var hist = this.history, done = 0, undone = 0;
+ for (var i = 0; i < hist.done.length; i++) if (!hist.done[i].ranges) ++done;
+ for (var i = 0; i < hist.undone.length; i++) if (!hist.undone[i].ranges) ++undone;
+ return {undo: done, redo: undone};
+ },
+ clearHistory: function() {this.history = new History(this.history.maxGeneration);},
+
+ markClean: function() {
+ this.cleanGeneration = this.changeGeneration(true);
+ },
+ changeGeneration: function(forceSplit) {
+ if (forceSplit)
+ this.history.lastOp = this.history.lastOrigin = null;
+ return this.history.generation;
+ },
+ isClean: function (gen) {
+ return this.history.generation == (gen || this.cleanGeneration);
+ },
+
+ getHistory: function() {
+ return {done: copyHistoryArray(this.history.done),
+ undone: copyHistoryArray(this.history.undone)};
+ },
+ setHistory: function(histData) {
+ var hist = this.history = new History(this.history.maxGeneration);
+ hist.done = copyHistoryArray(histData.done.slice(0), null, true);
+ hist.undone = copyHistoryArray(histData.undone.slice(0), null, true);
+ },
+
+ markText: function(from, to, options) {
+ return markText(this, clipPos(this, from), clipPos(this, to), options, "range");
+ },
+ setBookmark: function(pos, options) {
+ var realOpts = {replacedWith: options && (options.nodeType == null ? options.widget : options),
+ insertLeft: options && options.insertLeft,
+ clearWhenEmpty: false, shared: options && options.shared};
+ pos = clipPos(this, pos);
+ return markText(this, pos, pos, realOpts, "bookmark");
+ },
+ findMarksAt: function(pos) {
+ pos = clipPos(this, pos);
+ var markers = [], spans = getLine(this, pos.line).markedSpans;
+ if (spans) for (var i = 0; i < spans.length; ++i) {
+ var span = spans[i];
+ if ((span.from == null || span.from <= pos.ch) &&
+ (span.to == null || span.to >= pos.ch))
+ markers.push(span.marker.parent || span.marker);
+ }
+ return markers;
+ },
+ findMarks: function(from, to, filter) {
+ from = clipPos(this, from); to = clipPos(this, to);
+ var found = [], lineNo = from.line;
+ this.iter(from.line, to.line + 1, function(line) {
+ var spans = line.markedSpans;
+ if (spans) for (var i = 0; i < spans.length; i++) {
+ var span = spans[i];
+ if (!(lineNo == from.line && from.ch > span.to ||
+ span.from == null && lineNo != from.line||
+ lineNo == to.line && span.from > to.ch) &&
+ (!filter || filter(span.marker)))
+ found.push(span.marker.parent || span.marker);
+ }
+ ++lineNo;
+ });
+ return found;
+ },
+ getAllMarks: function() {
+ var markers = [];
+ this.iter(function(line) {
+ var sps = line.markedSpans;
+ if (sps) for (var i = 0; i < sps.length; ++i)
+ if (sps[i].from != null) markers.push(sps[i].marker);
+ });
+ return markers;
+ },
+
+ posFromIndex: function(off) {
+ var ch, lineNo = this.first;
+ this.iter(function(line) {
+ var sz = line.text.length + 1;
+ if (sz > off) { ch = off; return true; }
+ off -= sz;
+ ++lineNo;
+ });
+ return clipPos(this, Pos(lineNo, ch));
+ },
+ indexFromPos: function (coords) {
+ coords = clipPos(this, coords);
+ var index = coords.ch;
+ if (coords.line < this.first || coords.ch < 0) return 0;
+ this.iter(this.first, coords.line, function (line) {
+ index += line.text.length + 1;
+ });
+ return index;
+ },
+
+ copy: function(copyHistory) {
+ var doc = new Doc(getLines(this, this.first, this.first + this.size), this.modeOption, this.first);
+ doc.scrollTop = this.scrollTop; doc.scrollLeft = this.scrollLeft;
+ doc.sel = this.sel;
+ doc.extend = false;
+ if (copyHistory) {
+ doc.history.undoDepth = this.history.undoDepth;
+ doc.setHistory(this.getHistory());
+ }
+ return doc;
+ },
+
+ linkedDoc: function(options) {
+ if (!options) options = {};
+ var from = this.first, to = this.first + this.size;
+ if (options.from != null && options.from > from) from = options.from;
+ if (options.to != null && options.to < to) to = options.to;
+ var copy = new Doc(getLines(this, from, to), options.mode || this.modeOption, from);
+ if (options.sharedHist) copy.history = this.history;
+ (this.linked || (this.linked = [])).push({doc: copy, sharedHist: options.sharedHist});
+ copy.linked = [{doc: this, isParent: true, sharedHist: options.sharedHist}];
+ copySharedMarkers(copy, findSharedMarkers(this));
+ return copy;
+ },
+ unlinkDoc: function(other) {
+ if (other instanceof CodeMirror) other = other.doc;
+ if (this.linked) for (var i = 0; i < this.linked.length; ++i) {
+ var link = this.linked[i];
+ if (link.doc != other) continue;
+ this.linked.splice(i, 1);
+ other.unlinkDoc(this);
+ detachSharedMarkers(findSharedMarkers(this));
+ break;
+ }
+ // If the histories were shared, split them again
+ if (other.history == this.history) {
+ var splitIds = [other.id];
+ linkedDocs(other, function(doc) {splitIds.push(doc.id);}, true);
+ other.history = new History(null);
+ other.history.done = copyHistoryArray(this.history.done, splitIds);
+ other.history.undone = copyHistoryArray(this.history.undone, splitIds);
+ }
+ },
+ iterLinkedDocs: function(f) {linkedDocs(this, f);},
+
+ getMode: function() {return this.mode;},
+ getEditor: function() {return this.cm;}
+ });
+
+ // Public alias.
+ Doc.prototype.eachLine = Doc.prototype.iter;
+
+ // Set up methods on CodeMirror's prototype to redirect to the editor's document.
+ var dontDelegate = "iter insert remove copy getEditor".split(" ");
+ for (var prop in Doc.prototype) if (Doc.prototype.hasOwnProperty(prop) && indexOf(dontDelegate, prop) < 0)
+ CodeMirror.prototype[prop] = (function(method) {
+ return function() {return method.apply(this.doc, arguments);};
+ })(Doc.prototype[prop]);
+
+ eventMixin(Doc);
+
+ // Call f for all linked documents.
+ function linkedDocs(doc, f, sharedHistOnly) {
+ function propagate(doc, skip, sharedHist) {
+ if (doc.linked) for (var i = 0; i < doc.linked.length; ++i) {
+ var rel = doc.linked[i];
+ if (rel.doc == skip) continue;
+ var shared = sharedHist && rel.sharedHist;
+ if (sharedHistOnly && !shared) continue;
+ f(rel.doc, shared);
+ propagate(rel.doc, doc, shared);
+ }
+ }
+ propagate(doc, null, true);
+ }
+
+ // Attach a document to an editor.
+ function attachDoc(cm, doc) {
+ if (doc.cm) throw new Error("This document is already in use.");
+ cm.doc = doc;
+ doc.cm = cm;
+ estimateLineHeights(cm);
+ loadMode(cm);
+ if (!cm.options.lineWrapping) findMaxLine(cm);
+ cm.options.mode = doc.modeOption;
+ regChange(cm);
+ }
+
+ // LINE UTILITIES
+
+ // Find the line object corresponding to the given line number.
+ function getLine(doc, n) {
+ n -= doc.first;
+ if (n < 0 || n >= doc.size) throw new Error("There is no line " + (n + doc.first) + " in the document.");
+ for (var chunk = doc; !chunk.lines;) {
+ for (var i = 0;; ++i) {
+ var child = chunk.children[i], sz = child.chunkSize();
+ if (n < sz) { chunk = child; break; }
+ n -= sz;
+ }
+ }
+ return chunk.lines[n];
+ }
+
+ // Get the part of a document between two positions, as an array of
+ // strings.
+ function getBetween(doc, start, end) {
+ var out = [], n = start.line;
+ doc.iter(start.line, end.line + 1, function(line) {
+ var text = line.text;
+ if (n == end.line) text = text.slice(0, end.ch);
+ if (n == start.line) text = text.slice(start.ch);
+ out.push(text);
+ ++n;
+ });
+ return out;
+ }
+ // Get the lines between from and to, as array of strings.
+ function getLines(doc, from, to) {
+ var out = [];
+ doc.iter(from, to, function(line) { out.push(line.text); });
+ return out;
+ }
+
+ // Update the height of a line, propagating the height change
+ // upwards to parent nodes.
+ function updateLineHeight(line, height) {
+ var diff = height - line.height;
+ if (diff) for (var n = line; n; n = n.parent) n.height += diff;
+ }
+
+ // Given a line object, find its line number by walking up through
+ // its parent links.
+ function lineNo(line) {
+ if (line.parent == null) return null;
+ var cur = line.parent, no = indexOf(cur.lines, line);
+ for (var chunk = cur.parent; chunk; cur = chunk, chunk = chunk.parent) {
+ for (var i = 0;; ++i) {
+ if (chunk.children[i] == cur) break;
+ no += chunk.children[i].chunkSize();
+ }
+ }
+ return no + cur.first;
+ }
+
+ // Find the line at the given vertical position, using the height
+ // information in the document tree.
+ function lineAtHeight(chunk, h) {
+ var n = chunk.first;
+ outer: do {
+ for (var i = 0; i < chunk.children.length; ++i) {
+ var child = chunk.children[i], ch = child.height;
+ if (h < ch) { chunk = child; continue outer; }
+ h -= ch;
+ n += child.chunkSize();
+ }
+ return n;
+ } while (!chunk.lines);
+ for (var i = 0; i < chunk.lines.length; ++i) {
+ var line = chunk.lines[i], lh = line.height;
+ if (h < lh) break;
+ h -= lh;
+ }
+ return n + i;
+ }
+
+
+ // Find the height above the given line.
+ function heightAtLine(lineObj) {
+ lineObj = visualLine(lineObj);
+
+ var h = 0, chunk = lineObj.parent;
+ for (var i = 0; i < chunk.lines.length; ++i) {
+ var line = chunk.lines[i];
+ if (line == lineObj) break;
+ else h += line.height;
+ }
+ for (var p = chunk.parent; p; chunk = p, p = chunk.parent) {
+ for (var i = 0; i < p.children.length; ++i) {
+ var cur = p.children[i];
+ if (cur == chunk) break;
+ else h += cur.height;
+ }
+ }
+ return h;
+ }
+
+ // Get the bidi ordering for the given line (and cache it). Returns
+ // false for lines that are fully left-to-right, and an array of
+ // BidiSpan objects otherwise.
+ function getOrder(line) {
+ var order = line.order;
+ if (order == null) order = line.order = bidiOrdering(line.text);
+ return order;
+ }
+
+ // HISTORY
+
+ function History(startGen) {
+ // Arrays of change events and selections. Doing something adds an
+ // event to done and clears undo. Undoing moves events from done
+ // to undone, redoing moves them in the other direction.
+ this.done = []; this.undone = [];
+ this.undoDepth = Infinity;
+ // Used to track when changes can be merged into a single undo
+ // event
+ this.lastModTime = this.lastSelTime = 0;
+ this.lastOp = null;
+ this.lastOrigin = this.lastSelOrigin = null;
+ // Used by the isClean() method
+ this.generation = this.maxGeneration = startGen || 1;
+ }
+
+ // Create a history change event from an updateDoc-style change
+ // object.
+ function historyChangeFromChange(doc, change) {
+ var histChange = {from: copyPos(change.from), to: changeEnd(change), text: getBetween(doc, change.from, change.to)};
+ attachLocalSpans(doc, histChange, change.from.line, change.to.line + 1);
+ linkedDocs(doc, function(doc) {attachLocalSpans(doc, histChange, change.from.line, change.to.line + 1);}, true);
+ return histChange;
+ }
+
+ // Pop all selection events off the end of a history array. Stop at
+ // a change event.
+ function clearSelectionEvents(array) {
+ while (array.length) {
+ var last = lst(array);
+ if (last.ranges) array.pop();
+ else break;
+ }
+ }
+
+ // Find the top change event in the history. Pop off selection
+ // events that are in the way.
+ function lastChangeEvent(hist, force) {
+ if (force) {
+ clearSelectionEvents(hist.done);
+ return lst(hist.done);
+ } else if (hist.done.length && !lst(hist.done).ranges) {
+ return lst(hist.done);
+ } else if (hist.done.length > 1 && !hist.done[hist.done.length - 2].ranges) {
+ hist.done.pop();
+ return lst(hist.done);
+ }
+ }
+
+ // Register a change in the history. Merges changes that are within
+ // a single operation, ore are close together with an origin that
+ // allows merging (starting with "+") into a single event.
+ function addChangeToHistory(doc, change, selAfter, opId) {
+ var hist = doc.history;
+ hist.undone.length = 0;
+ var time = +new Date, cur;
+
+ if ((hist.lastOp == opId ||
+ hist.lastOrigin == change.origin && change.origin &&
+ ((change.origin.charAt(0) == "+" && doc.cm && hist.lastModTime > time - doc.cm.options.historyEventDelay) ||
+ change.origin.charAt(0) == "*")) &&
+ (cur = lastChangeEvent(hist, hist.lastOp == opId))) {
+ // Merge this change into the last event
+ var last = lst(cur.changes);
+ if (cmp(change.from, change.to) == 0 && cmp(change.from, last.to) == 0) {
+ // Optimized case for simple insertion -- don't want to add
+ // new changesets for every character typed
+ last.to = changeEnd(change);
+ } else {
+ // Add new sub-event
+ cur.changes.push(historyChangeFromChange(doc, change));
+ }
+ } else {
+ // Can not be merged, start a new event.
+ var before = lst(hist.done);
+ if (!before || !before.ranges)
+ pushSelectionToHistory(doc.sel, hist.done);
+ cur = {changes: [historyChangeFromChange(doc, change)],
+ generation: hist.generation};
+ hist.done.push(cur);
+ while (hist.done.length > hist.undoDepth) {
+ hist.done.shift();
+ if (!hist.done[0].ranges) hist.done.shift();
+ }
+ }
+ hist.done.push(selAfter);
+ hist.generation = ++hist.maxGeneration;
+ hist.lastModTime = hist.lastSelTime = time;
+ hist.lastOp = opId;
+ hist.lastOrigin = hist.lastSelOrigin = change.origin;
+
+ if (!last) signal(doc, "historyAdded");
+ }
+
+ function selectionEventCanBeMerged(doc, origin, prev, sel) {
+ var ch = origin.charAt(0);
+ return ch == "*" ||
+ ch == "+" &&
+ prev.ranges.length == sel.ranges.length &&
+ prev.somethingSelected() == sel.somethingSelected() &&
+ new Date - doc.history.lastSelTime <= (doc.cm ? doc.cm.options.historyEventDelay : 500);
+ }
+
+ // Called whenever the selection changes, sets the new selection as
+ // the pending selection in the history, and pushes the old pending
+ // selection into the 'done' array when it was significantly
+ // different (in number of selected ranges, emptiness, or time).
+ function addSelectionToHistory(doc, sel, opId, options) {
+ var hist = doc.history, origin = options && options.origin;
+
+ // A new event is started when the previous origin does not match
+ // the current, or the origins don't allow matching. Origins
+ // starting with * are always merged, those starting with + are
+ // merged when similar and close together in time.
+ if (opId == hist.lastOp ||
+ (origin && hist.lastSelOrigin == origin &&
+ (hist.lastModTime == hist.lastSelTime && hist.lastOrigin == origin ||
+ selectionEventCanBeMerged(doc, origin, lst(hist.done), sel))))
+ hist.done[hist.done.length - 1] = sel;
+ else
+ pushSelectionToHistory(sel, hist.done);
+
+ hist.lastSelTime = +new Date;
+ hist.lastSelOrigin = origin;
+ hist.lastOp = opId;
+ if (options && options.clearRedo !== false)
+ clearSelectionEvents(hist.undone);
+ }
+
+ function pushSelectionToHistory(sel, dest) {
+ var top = lst(dest);
+ if (!(top && top.ranges && top.equals(sel)))
+ dest.push(sel);
+ }
+
+ // Used to store marked span information in the history.
+ function attachLocalSpans(doc, change, from, to) {
+ var existing = change["spans_" + doc.id], n = 0;
+ doc.iter(Math.max(doc.first, from), Math.min(doc.first + doc.size, to), function(line) {
+ if (line.markedSpans)
+ (existing || (existing = change["spans_" + doc.id] = {}))[n] = line.markedSpans;
+ ++n;
+ });
+ }
+
+ // When un/re-doing restores text containing marked spans, those
+ // that have been explicitly cleared should not be restored.
+ function removeClearedSpans(spans) {
+ if (!spans) return null;
+ for (var i = 0, out; i < spans.length; ++i) {
+ if (spans[i].marker.explicitlyCleared) { if (!out) out = spans.slice(0, i); }
+ else if (out) out.push(spans[i]);
+ }
+ return !out ? spans : out.length ? out : null;
+ }
+
+ // Retrieve and filter the old marked spans stored in a change event.
+ function getOldSpans(doc, change) {
+ var found = change["spans_" + doc.id];
+ if (!found) return null;
+ for (var i = 0, nw = []; i < change.text.length; ++i)
+ nw.push(removeClearedSpans(found[i]));
+ return nw;
+ }
+
+ // Used both to provide a JSON-safe object in .getHistory, and, when
+ // detaching a document, to split the history in two
+ function copyHistoryArray(events, newGroup, instantiateSel) {
+ for (var i = 0, copy = []; i < events.length; ++i) {
+ var event = events[i];
+ if (event.ranges) {
+ copy.push(instantiateSel ? Selection.prototype.deepCopy.call(event) : event);
+ continue;
+ }
+ var changes = event.changes, newChanges = [];
+ copy.push({changes: newChanges});
+ for (var j = 0; j < changes.length; ++j) {
+ var change = changes[j], m;
+ newChanges.push({from: change.from, to: change.to, text: change.text});
+ if (newGroup) for (var prop in change) if (m = prop.match(/^spans_(\d+)$/)) {
+ if (indexOf(newGroup, Number(m[1])) > -1) {
+ lst(newChanges)[prop] = change[prop];
+ delete change[prop];
+ }
+ }
+ }
+ }
+ return copy;
+ }
+
+ // Rebasing/resetting history to deal with externally-sourced changes
+
+ function rebaseHistSelSingle(pos, from, to, diff) {
+ if (to < pos.line) {
+ pos.line += diff;
+ } else if (from < pos.line) {
+ pos.line = from;
+ pos.ch = 0;
+ }
+ }
+
+ // Tries to rebase an array of history events given a change in the
+ // document. If the change touches the same lines as the event, the
+ // event, and everything 'behind' it, is discarded. If the change is
+ // before the event, the event's positions are updated. Uses a
+ // copy-on-write scheme for the positions, to avoid having to
+ // reallocate them all on every rebase, but also avoid problems with
+ // shared position objects being unsafely updated.
+ function rebaseHistArray(array, from, to, diff) {
+ for (var i = 0; i < array.length; ++i) {
+ var sub = array[i], ok = true;
+ if (sub.ranges) {
+ if (!sub.copied) { sub = array[i] = sub.deepCopy(); sub.copied = true; }
+ for (var j = 0; j < sub.ranges.length; j++) {
+ rebaseHistSelSingle(sub.ranges[j].anchor, from, to, diff);
+ rebaseHistSelSingle(sub.ranges[j].head, from, to, diff);
+ }
+ continue;
+ }
+ for (var j = 0; j < sub.changes.length; ++j) {
+ var cur = sub.changes[j];
+ if (to < cur.from.line) {
+ cur.from = Pos(cur.from.line + diff, cur.from.ch);
+ cur.to = Pos(cur.to.line + diff, cur.to.ch);
+ } else if (from <= cur.to.line) {
+ ok = false;
+ break;
+ }
+ }
+ if (!ok) {
+ array.splice(0, i + 1);
+ i = 0;
+ }
+ }
+ }
+
+ function rebaseHist(hist, change) {
+ var from = change.from.line, to = change.to.line, diff = change.text.length - (to - from) - 1;
+ rebaseHistArray(hist.done, from, to, diff);
+ rebaseHistArray(hist.undone, from, to, diff);
+ }
+
+ // EVENT UTILITIES
+
+ // Due to the fact that we still support jurassic IE versions, some
+ // compatibility wrappers are needed.
+
+ var e_preventDefault = CodeMirror.e_preventDefault = function(e) {
+ if (e.preventDefault) e.preventDefault();
+ else e.returnValue = false;
+ };
+ var e_stopPropagation = CodeMirror.e_stopPropagation = function(e) {
+ if (e.stopPropagation) e.stopPropagation();
+ else e.cancelBubble = true;
+ };
+ function e_defaultPrevented(e) {
+ return e.defaultPrevented != null ? e.defaultPrevented : e.returnValue == false;
+ }
+ var e_stop = CodeMirror.e_stop = function(e) {e_preventDefault(e); e_stopPropagation(e);};
+
+ function e_target(e) {return e.target || e.srcElement;}
+ function e_button(e) {
+ var b = e.which;
+ if (b == null) {
+ if (e.button & 1) b = 1;
+ else if (e.button & 2) b = 3;
+ else if (e.button & 4) b = 2;
+ }
+ if (mac && e.ctrlKey && b == 1) b = 3;
+ return b;
+ }
+
+ // EVENT HANDLING
+
+ // Lightweight event framework. on/off also work on DOM nodes,
+ // registering native DOM handlers.
+
+ var on = CodeMirror.on = function(emitter, type, f) {
+ if (emitter.addEventListener)
+ emitter.addEventListener(type, f, false);
+ else if (emitter.attachEvent)
+ emitter.attachEvent("on" + type, f);
+ else {
+ var map = emitter._handlers || (emitter._handlers = {});
+ var arr = map[type] || (map[type] = []);
+ arr.push(f);
+ }
+ };
+
+ var off = CodeMirror.off = function(emitter, type, f) {
+ if (emitter.removeEventListener)
+ emitter.removeEventListener(type, f, false);
+ else if (emitter.detachEvent)
+ emitter.detachEvent("on" + type, f);
+ else {
+ var arr = emitter._handlers && emitter._handlers[type];
+ if (!arr) return;
+ for (var i = 0; i < arr.length; ++i)
+ if (arr[i] == f) { arr.splice(i, 1); break; }
+ }
+ };
+
+ var signal = CodeMirror.signal = function(emitter, type /*, values...*/) {
+ var arr = emitter._handlers && emitter._handlers[type];
+ if (!arr) return;
+ var args = Array.prototype.slice.call(arguments, 2);
+ for (var i = 0; i < arr.length; ++i) arr[i].apply(null, args);
+ };
+
+ // Often, we want to signal events at a point where we are in the
+ // middle of some work, but don't want the handler to start calling
+ // other methods on the editor, which might be in an inconsistent
+ // state or simply not expect any other events to happen.
+ // signalLater looks whether there are any handlers, and schedules
+ // them to be executed when the last operation ends, or, if no
+ // operation is active, when a timeout fires.
+ var delayedCallbacks, delayedCallbackDepth = 0;
+ function signalLater(emitter, type /*, values...*/) {
+ var arr = emitter._handlers && emitter._handlers[type];
+ if (!arr) return;
+ var args = Array.prototype.slice.call(arguments, 2);
+ if (!delayedCallbacks) {
+ ++delayedCallbackDepth;
+ delayedCallbacks = [];
+ setTimeout(fireDelayed, 0);
+ }
+ function bnd(f) {return function(){f.apply(null, args);};};
+ for (var i = 0; i < arr.length; ++i)
+ delayedCallbacks.push(bnd(arr[i]));
+ }
+
+ function fireDelayed() {
+ --delayedCallbackDepth;
+ var delayed = delayedCallbacks;
+ delayedCallbacks = null;
+ for (var i = 0; i < delayed.length; ++i) delayed[i]();
+ }
+
+ // The DOM events that CodeMirror handles can be overridden by
+ // registering a (non-DOM) handler on the editor for the event name,
+ // and preventDefault-ing the event in that handler.
+ function signalDOMEvent(cm, e, override) {
+ signal(cm, override || e.type, cm, e);
+ return e_defaultPrevented(e) || e.codemirrorIgnore;
+ }
+
+ function signalCursorActivity(cm) {
+ var arr = cm._handlers && cm._handlers.cursorActivity;
+ if (!arr) return;
+ var set = cm.curOp.cursorActivityHandlers || (cm.curOp.cursorActivityHandlers = []);
+ for (var i = 0; i < arr.length; ++i) if (indexOf(set, arr[i]) == -1)
+ set.push(arr[i]);
+ }
+
+ function hasHandler(emitter, type) {
+ var arr = emitter._handlers && emitter._handlers[type];
+ return arr && arr.length > 0;
+ }
+
+ // Add on and off methods to a constructor's prototype, to make
+ // registering events on such objects more convenient.
+ function eventMixin(ctor) {
+ ctor.prototype.on = function(type, f) {on(this, type, f);};
+ ctor.prototype.off = function(type, f) {off(this, type, f);};
+ }
+
+ // MISC UTILITIES
+
+ // Number of pixels added to scroller and sizer to hide scrollbar
+ var scrollerCutOff = 30;
+
+ // Returned or thrown by various protocols to signal 'I'm not
+ // handling this'.
+ var Pass = CodeMirror.Pass = {toString: function(){return "CodeMirror.Pass";}};
+
+ // Reused option objects for setSelection & friends
+ var sel_dontScroll = {scroll: false}, sel_mouse = {origin: "*mouse"}, sel_move = {origin: "+move"};
+
+ function Delayed() {this.id = null;}
+ Delayed.prototype.set = function(ms, f) {
+ clearTimeout(this.id);
+ this.id = setTimeout(f, ms);
+ };
+
+ // Counts the column offset in a string, taking tabs into account.
+ // Used mostly to find indentation.
+ var countColumn = CodeMirror.countColumn = function(string, end, tabSize, startIndex, startValue) {
+ if (end == null) {
+ end = string.search(/[^\s\u00a0]/);
+ if (end == -1) end = string.length;
+ }
+ for (var i = startIndex || 0, n = startValue || 0;;) {
+ var nextTab = string.indexOf("\t", i);
+ if (nextTab < 0 || nextTab >= end)
+ return n + (end - i);
+ n += nextTab - i;
+ n += tabSize - (n % tabSize);
+ i = nextTab + 1;
+ }
+ };
+
+ // The inverse of countColumn -- find the offset that corresponds to
+ // a particular column.
+ function findColumn(string, goal, tabSize) {
+ for (var pos = 0, col = 0;;) {
+ var nextTab = string.indexOf("\t", pos);
+ if (nextTab == -1) nextTab = string.length;
+ var skipped = nextTab - pos;
+ if (nextTab == string.length || col + skipped >= goal)
+ return pos + Math.min(skipped, goal - col);
+ col += nextTab - pos;
+ col += tabSize - (col % tabSize);
+ pos = nextTab + 1;
+ if (col >= goal) return pos;
+ }
+ }
+
+ var spaceStrs = [""];
+ function spaceStr(n) {
+ while (spaceStrs.length <= n)
+ spaceStrs.push(lst(spaceStrs) + " ");
+ return spaceStrs[n];
+ }
+
+ function lst(arr) { return arr[arr.length-1]; }
+
+ var selectInput = function(node) { node.select(); };
+ if (ios) // Mobile Safari apparently has a bug where select() is broken.
+ selectInput = function(node) { node.selectionStart = 0; node.selectionEnd = node.value.length; };
+ else if (ie) // Suppress mysterious IE10 errors
+ selectInput = function(node) { try { node.select(); } catch(_e) {} };
+
+ function indexOf(array, elt) {
+ for (var i = 0; i < array.length; ++i)
+ if (array[i] == elt) return i;
+ return -1;
+ }
+ if ([].indexOf) indexOf = function(array, elt) { return array.indexOf(elt); };
+ function map(array, f) {
+ var out = [];
+ for (var i = 0; i < array.length; i++) out[i] = f(array[i], i);
+ return out;
+ }
+ if ([].map) map = function(array, f) { return array.map(f); };
+
+ function createObj(base, props) {
+ var inst;
+ if (Object.create) {
+ inst = Object.create(base);
+ } else {
+ var ctor = function() {};
+ ctor.prototype = base;
+ inst = new ctor();
+ }
+ if (props) copyObj(props, inst);
+ return inst;
+ };
+
+ function copyObj(obj, target, overwrite) {
+ if (!target) target = {};
+ for (var prop in obj)
+ if (obj.hasOwnProperty(prop) && (overwrite !== false || !target.hasOwnProperty(prop)))
+ target[prop] = obj[prop];
+ return target;
+ }
+
+ function bind(f) {
+ var args = Array.prototype.slice.call(arguments, 1);
+ return function(){return f.apply(null, args);};
+ }
+
+ var nonASCIISingleCaseWordChar = /[\u00df\u3040-\u309f\u30a0-\u30ff\u3400-\u4db5\u4e00-\u9fcc\uac00-\ud7af]/;
+ var isWordChar = CodeMirror.isWordChar = function(ch) {
+ return /\w/.test(ch) || ch > "\x80" &&
+ (ch.toUpperCase() != ch.toLowerCase() || nonASCIISingleCaseWordChar.test(ch));
+ };
+
+ function isEmpty(obj) {
+ for (var n in obj) if (obj.hasOwnProperty(n) && obj[n]) return false;
+ return true;
+ }
+
+ // Extending unicode characters. A series of a non-extending char +
+ // any number of extending chars is treated as a single unit as far
+ // as editing and measuring is concerned. This is not fully correct,
+ // since some scripts/fonts/browsers also treat other configurations
+ // of code points as a group.
+ var extendingChars = /[\u0300-\u036f\u0483-\u0489\u0591-\u05bd\u05bf\u05c1\u05c2\u05c4\u05c5\u05c7\u0610-\u061a\u064b-\u065e\u0670\u06d6-\u06dc\u06de-\u06e4\u06e7\u06e8\u06ea-\u06ed\u0711\u0730-\u074a\u07a6-\u07b0\u07eb-\u07f3\u0816-\u0819\u081b-\u0823\u0825-\u0827\u0829-\u082d\u0900-\u0902\u093c\u0941-\u0948\u094d\u0951-\u0955\u0962\u0963\u0981\u09bc\u09be\u09c1-\u09c4\u09cd\u09d7\u09e2\u09e3\u0a01\u0a02\u0a3c\u0a41\u0a42\u0a47\u0a48\u0a4b-\u0a4d\u0a51\u0a70\u0a71\u0a75\u0a81\u0a82\u0abc\u0ac1-\u0ac5\u0ac7\u0ac8\u0acd\u0ae2\u0ae3\u0b01\u0b3c\u0b3e\u0b3f\u0b41-\u0b44\u0b4d\u0b56\u0b57\u0b62\u0b63\u0b82\u0bbe\u0bc0\u0bcd\u0bd7\u0c3e-\u0c40\u0c46-\u0c48\u0c4a-\u0c4d\u0c55\u0c56\u0c62\u0c63\u0cbc\u0cbf\u0cc2\u0cc6\u0ccc\u0ccd\u0cd5\u0cd6\u0ce2\u0ce3\u0d3e\u0d41-\u0d44\u0d4d\u0d57\u0d62\u0d63\u0dca\u0dcf\u0dd2-\u0dd4\u0dd6\u0ddf\u0e31\u0e34-\u0e3a\u0e47-\u0e4e\u0eb1\u0eb4-\u0eb9\u0ebb\u0ebc\u0ec8-\u0ecd\u0f18\u0f19\u0f35\u0f37\u0f39\u0f71-\u0f7e\u0f80-\u0f84\u0f86\u0f87\u0f90-\u0f97\u0f99-\u0fbc\u0fc6\u102d-\u1030\u1032-\u1037\u1039\u103a\u103d\u103e\u1058\u1059\u105e-\u1060\u1071-\u1074\u1082\u1085\u1086\u108d\u109d\u135f\u1712-\u1714\u1732-\u1734\u1752\u1753\u1772\u1773\u17b7-\u17bd\u17c6\u17c9-\u17d3\u17dd\u180b-\u180d\u18a9\u1920-\u1922\u1927\u1928\u1932\u1939-\u193b\u1a17\u1a18\u1a56\u1a58-\u1a5e\u1a60\u1a62\u1a65-\u1a6c\u1a73-\u1a7c\u1a7f\u1b00-\u1b03\u1b34\u1b36-\u1b3a\u1b3c\u1b42\u1b6b-\u1b73\u1b80\u1b81\u1ba2-\u1ba5\u1ba8\u1ba9\u1c2c-\u1c33\u1c36\u1c37\u1cd0-\u1cd2\u1cd4-\u1ce0\u1ce2-\u1ce8\u1ced\u1dc0-\u1de6\u1dfd-\u1dff\u200c\u200d\u20d0-\u20f0\u2cef-\u2cf1\u2de0-\u2dff\u302a-\u302f\u3099\u309a\ua66f-\ua672\ua67c\ua67d\ua6f0\ua6f1\ua802\ua806\ua80b\ua825\ua826\ua8c4\ua8e0-\ua8f1\ua926-\ua92d\ua947-\ua951\ua980-\ua982\ua9b3\ua9b6-\ua9b9\ua9bc\uaa29-\uaa2e\uaa31\uaa32\uaa35\uaa36\uaa43\uaa4c\uaab0\uaab2-\uaab4\uaab7\uaab8\uaabe\uaabf\uaac1\uabe5\uabe8\uabed\udc00-\udfff\ufb1e\ufe00-\ufe0f\ufe20-\ufe26\uff9e\uff9f]/;
+ function isExtendingChar(ch) { return ch.charCodeAt(0) >= 768 && extendingChars.test(ch); }
+
+ // DOM UTILITIES
+
+ function elt(tag, content, className, style) {
+ var e = document.createElement(tag);
+ if (className) e.className = className;
+ if (style) e.style.cssText = style;
+ if (typeof content == "string") e.appendChild(document.createTextNode(content));
+ else if (content) for (var i = 0; i < content.length; ++i) e.appendChild(content[i]);
+ return e;
+ }
+
+ var range;
+ if (document.createRange) range = function(node, start, end) {
+ var r = document.createRange();
+ r.setEnd(node, end);
+ r.setStart(node, start);
+ return r;
+ };
+ else range = function(node, start, end) {
+ var r = document.body.createTextRange();
+ r.moveToElementText(node.parentNode);
+ r.collapse(true);
+ r.moveEnd("character", end);
+ r.moveStart("character", start);
+ return r;
+ };
+
+ function removeChildren(e) {
+ for (var count = e.childNodes.length; count > 0; --count)
+ e.removeChild(e.firstChild);
+ return e;
+ }
+
+ function removeChildrenAndAdd(parent, e) {
+ return removeChildren(parent).appendChild(e);
+ }
+
+ function contains(parent, child) {
+ if (parent.contains)
+ return parent.contains(child);
+ while (child = child.parentNode)
+ if (child == parent) return true;
+ }
+
+ function activeElt() { return document.activeElement; }
+ // Older versions of IE throws unspecified error when touching
+ // document.activeElement in some cases (during loading, in iframe)
+ if (ie_upto10) activeElt = function() {
+ try { return document.activeElement; }
+ catch(e) { return document.body; }
+ };
+
+ function classTest(cls) { return new RegExp("\\b" + cls + "\\b\\s*"); }
+ function rmClass(node, cls) {
+ var test = classTest(cls);
+ if (test.test(node.className)) node.className = node.className.replace(test, "");
+ }
+ function addClass(node, cls) {
+ if (!classTest(cls).test(node.className)) node.className += " " + cls;
+ }
+ function joinClasses(a, b) {
+ var as = a.split(" ");
+ for (var i = 0; i < as.length; i++)
+ if (as[i] && !classTest(as[i]).test(b)) b += " " + as[i];
+ return b;
+ }
+
+ // FEATURE DETECTION
+
+ // Detect drag-and-drop
+ var dragAndDrop = function() {
+ // There is *some* kind of drag-and-drop support in IE6-8, but I
+ // couldn't get it to work yet.
+ if (ie_upto8) return false;
+ var div = elt('div');
+ return "draggable" in div || "dragDrop" in div;
+ }();
+
+ var knownScrollbarWidth;
+ function scrollbarWidth(measure) {
+ if (knownScrollbarWidth != null) return knownScrollbarWidth;
+ var test = elt("div", null, null, "width: 50px; height: 50px; overflow-x: scroll");
+ removeChildrenAndAdd(measure, test);
+ if (test.offsetWidth)
+ knownScrollbarWidth = test.offsetHeight - test.clientHeight;
+ return knownScrollbarWidth || 0;
+ }
+
+ var zwspSupported;
+ function zeroWidthElement(measure) {
+ if (zwspSupported == null) {
+ var test = elt("span", "\u200b");
+ removeChildrenAndAdd(measure, elt("span", [test, document.createTextNode("x")]));
+ if (measure.firstChild.offsetHeight != 0)
+ zwspSupported = test.offsetWidth <= 1 && test.offsetHeight > 2 && !ie_upto7;
+ }
+ if (zwspSupported) return elt("span", "\u200b");
+ else return elt("span", "\u00a0", null, "display: inline-block; width: 1px; margin-right: -1px");
+ }
+
+ // Feature-detect IE's crummy client rect reporting for bidi text
+ var badBidiRects;
+ function hasBadBidiRects(measure) {
+ if (badBidiRects != null) return badBidiRects;
+ var txt = removeChildrenAndAdd(measure, document.createTextNode("A\u062eA"));
+ var r0 = range(txt, 0, 1).getBoundingClientRect();
+ if (r0.left == r0.right) return false;
+ var r1 = range(txt, 1, 2).getBoundingClientRect();
+ return badBidiRects = (r1.right - r0.right < 3);
+ }
+
+ // See if "".split is the broken IE version, if so, provide an
+ // alternative way to split lines.
+ var splitLines = CodeMirror.splitLines = "\n\nb".split(/\n/).length != 3 ? function(string) {
+ var pos = 0, result = [], l = string.length;
+ while (pos <= l) {
+ var nl = string.indexOf("\n", pos);
+ if (nl == -1) nl = string.length;
+ var line = string.slice(pos, string.charAt(nl - 1) == "\r" ? nl - 1 : nl);
+ var rt = line.indexOf("\r");
+ if (rt != -1) {
+ result.push(line.slice(0, rt));
+ pos += rt + 1;
+ } else {
+ result.push(line);
+ pos = nl + 1;
+ }
+ }
+ return result;
+ } : function(string){return string.split(/\r\n?|\n/);};
+
+ var hasSelection = window.getSelection ? function(te) {
+ try { return te.selectionStart != te.selectionEnd; }
+ catch(e) { return false; }
+ } : function(te) {
+ try {var range = te.ownerDocument.selection.createRange();}
+ catch(e) {}
+ if (!range || range.parentElement() != te) return false;
+ return range.compareEndPoints("StartToEnd", range) != 0;
+ };
+
+ var hasCopyEvent = (function() {
+ var e = elt("div");
+ if ("oncopy" in e) return true;
+ e.setAttribute("oncopy", "return;");
+ return typeof e.oncopy == "function";
+ })();
+
+ // KEY NAMES
+
+ var keyNames = {3: "Enter", 8: "Backspace", 9: "Tab", 13: "Enter", 16: "Shift", 17: "Ctrl", 18: "Alt",
+ 19: "Pause", 20: "CapsLock", 27: "Esc", 32: "Space", 33: "PageUp", 34: "PageDown", 35: "End",
+ 36: "Home", 37: "Left", 38: "Up", 39: "Right", 40: "Down", 44: "PrintScrn", 45: "Insert",
+ 46: "Delete", 59: ";", 61: "=", 91: "Mod", 92: "Mod", 93: "Mod", 107: "=", 109: "-", 127: "Delete",
+ 173: "-", 186: ";", 187: "=", 188: ",", 189: "-", 190: ".", 191: "/", 192: "`", 219: "[", 220: "\\",
+ 221: "]", 222: "'", 63232: "Up", 63233: "Down", 63234: "Left", 63235: "Right", 63272: "Delete",
+ 63273: "Home", 63275: "End", 63276: "PageUp", 63277: "PageDown", 63302: "Insert"};
+ CodeMirror.keyNames = keyNames;
+ (function() {
+ // Number keys
+ for (var i = 0; i < 10; i++) keyNames[i + 48] = keyNames[i + 96] = String(i);
+ // Alphabetic keys
+ for (var i = 65; i <= 90; i++) keyNames[i] = String.fromCharCode(i);
+ // Function keys
+ for (var i = 1; i <= 12; i++) keyNames[i + 111] = keyNames[i + 63235] = "F" + i;
+ })();
+
+ // BIDI HELPERS
+
+ function iterateBidiSections(order, from, to, f) {
+ if (!order) return f(from, to, "ltr");
+ var found = false;
+ for (var i = 0; i < order.length; ++i) {
+ var part = order[i];
+ if (part.from < to && part.to > from || from == to && part.to == from) {
+ f(Math.max(part.from, from), Math.min(part.to, to), part.level == 1 ? "rtl" : "ltr");
+ found = true;
+ }
+ }
+ if (!found) f(from, to, "ltr");
+ }
+
+ function bidiLeft(part) { return part.level % 2 ? part.to : part.from; }
+ function bidiRight(part) { return part.level % 2 ? part.from : part.to; }
+
+ function lineLeft(line) { var order = getOrder(line); return order ? bidiLeft(order[0]) : 0; }
+ function lineRight(line) {
+ var order = getOrder(line);
+ if (!order) return line.text.length;
+ return bidiRight(lst(order));
+ }
+
+ function lineStart(cm, lineN) {
+ var line = getLine(cm.doc, lineN);
+ var visual = visualLine(line);
+ if (visual != line) lineN = lineNo(visual);
+ var order = getOrder(visual);
+ var ch = !order ? 0 : order[0].level % 2 ? lineRight(visual) : lineLeft(visual);
+ return Pos(lineN, ch);
+ }
+ function lineEnd(cm, lineN) {
+ var merged, line = getLine(cm.doc, lineN);
+ while (merged = collapsedSpanAtEnd(line)) {
+ line = merged.find(1, true).line;
+ lineN = null;
+ }
+ var order = getOrder(line);
+ var ch = !order ? line.text.length : order[0].level % 2 ? lineLeft(line) : lineRight(line);
+ return Pos(lineN == null ? lineNo(line) : lineN, ch);
+ }
+
+ function compareBidiLevel(order, a, b) {
+ var linedir = order[0].level;
+ if (a == linedir) return true;
+ if (b == linedir) return false;
+ return a < b;
+ }
+ var bidiOther;
+ function getBidiPartAt(order, pos) {
+ bidiOther = null;
+ for (var i = 0, found; i < order.length; ++i) {
+ var cur = order[i];
+ if (cur.from < pos && cur.to > pos) return i;
+ if ((cur.from == pos || cur.to == pos)) {
+ if (found == null) {
+ found = i;
+ } else if (compareBidiLevel(order, cur.level, order[found].level)) {
+ if (cur.from != cur.to) bidiOther = found;
+ return i;
+ } else {
+ if (cur.from != cur.to) bidiOther = i;
+ return found;
+ }
+ }
+ }
+ return found;
+ }
+
+ function moveInLine(line, pos, dir, byUnit) {
+ if (!byUnit) return pos + dir;
+ do pos += dir;
+ while (pos > 0 && isExtendingChar(line.text.charAt(pos)));
+ return pos;
+ }
+
+ // This is needed in order to move 'visually' through bi-directional
+ // text -- i.e., pressing left should make the cursor go left, even
+ // when in RTL text. The tricky part is the 'jumps', where RTL and
+ // LTR text touch each other. This often requires the cursor offset
+ // to move more than one unit, in order to visually move one unit.
+ function moveVisually(line, start, dir, byUnit) {
+ var bidi = getOrder(line);
+ if (!bidi) return moveLogically(line, start, dir, byUnit);
+ var pos = getBidiPartAt(bidi, start), part = bidi[pos];
+ var target = moveInLine(line, start, part.level % 2 ? -dir : dir, byUnit);
+
+ for (;;) {
+ if (target > part.from && target < part.to) return target;
+ if (target == part.from || target == part.to) {
+ if (getBidiPartAt(bidi, target) == pos) return target;
+ part = bidi[pos += dir];
+ return (dir > 0) == part.level % 2 ? part.to : part.from;
+ } else {
+ part = bidi[pos += dir];
+ if (!part) return null;
+ if ((dir > 0) == part.level % 2)
+ target = moveInLine(line, part.to, -1, byUnit);
+ else
+ target = moveInLine(line, part.from, 1, byUnit);
+ }
+ }
+ }
+
+ function moveLogically(line, start, dir, byUnit) {
+ var target = start + dir;
+ if (byUnit) while (target > 0 && isExtendingChar(line.text.charAt(target))) target += dir;
+ return target < 0 || target > line.text.length ? null : target;
+ }
+
+ // Bidirectional ordering algorithm
+ // See http://unicode.org/reports/tr9/tr9-13.html for the algorithm
+ // that this (partially) implements.
+
+ // One-char codes used for character types:
+ // L (L): Left-to-Right
+ // R (R): Right-to-Left
+ // r (AL): Right-to-Left Arabic
+ // 1 (EN): European Number
+ // + (ES): European Number Separator
+ // % (ET): European Number Terminator
+ // n (AN): Arabic Number
+ // , (CS): Common Number Separator
+ // m (NSM): Non-Spacing Mark
+ // b (BN): Boundary Neutral
+ // s (B): Paragraph Separator
+ // t (S): Segment Separator
+ // w (WS): Whitespace
+ // N (ON): Other Neutrals
+
+ // Returns null if characters are ordered as they appear
+ // (left-to-right), or an array of sections ({from, to, level}
+ // objects) in the order in which they occur visually.
+ var bidiOrdering = (function() {
+ // Character types for codepoints 0 to 0xff
+ var lowTypes = "bbbbbbbbbtstwsbbbbbbbbbbbbbbssstwNN%%%NNNNNN,N,N1111111111NNNNNNNLLLLLLLLLLLLLLLLLLLLLLLLLLNNNNNNLLLLLLLLLLLLLLLLLLLLLLLLLLNNNNbbbbbbsbbbbbbbbbbbbbbbbbbbbbbbbbb,N%%%%NNNNLNNNNN%%11NLNNN1LNNNNNLLLLLLLLLLLLLLLLLLLLLLLNLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLN";
+ // Character types for codepoints 0x600 to 0x6ff
+ var arabicTypes = "rrrrrrrrrrrr,rNNmmmmmmrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrmmmmmmmmmmmmmmrrrrrrrnnnnnnnnnn%nnrrrmrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrmmmmmmmmmmmmmmmmmmmNmmmm";
+ function charType(code) {
+ if (code <= 0xf7) return lowTypes.charAt(code);
+ else if (0x590 <= code && code <= 0x5f4) return "R";
+ else if (0x600 <= code && code <= 0x6ed) return arabicTypes.charAt(code - 0x600);
+ else if (0x6ee <= code && code <= 0x8ac) return "r";
+ else if (0x2000 <= code && code <= 0x200b) return "w";
+ else if (code == 0x200c) return "b";
+ else return "L";
+ }
+
+ var bidiRE = /[\u0590-\u05f4\u0600-\u06ff\u0700-\u08ac]/;
+ var isNeutral = /[stwN]/, isStrong = /[LRr]/, countsAsLeft = /[Lb1n]/, countsAsNum = /[1n]/;
+ // Browsers seem to always treat the boundaries of block elements as being L.
+ var outerType = "L";
+
+ function BidiSpan(level, from, to) {
+ this.level = level;
+ this.from = from; this.to = to;
+ }
+
+ return function(str) {
+ if (!bidiRE.test(str)) return false;
+ var len = str.length, types = [];
+ for (var i = 0, type; i < len; ++i)
+ types.push(type = charType(str.charCodeAt(i)));
+
+ // W1. Examine each non-spacing mark (NSM) in the level run, and
+ // change the type of the NSM to the type of the previous
+ // character. If the NSM is at the start of the level run, it will
+ // get the type of sor.
+ for (var i = 0, prev = outerType; i < len; ++i) {
+ var type = types[i];
+ if (type == "m") types[i] = prev;
+ else prev = type;
+ }
+
+ // W2. Search backwards from each instance of a European number
+ // until the first strong type (R, L, AL, or sor) is found. If an
+ // AL is found, change the type of the European number to Arabic
+ // number.
+ // W3. Change all ALs to R.
+ for (var i = 0, cur = outerType; i < len; ++i) {
+ var type = types[i];
+ if (type == "1" && cur == "r") types[i] = "n";
+ else if (isStrong.test(type)) { cur = type; if (type == "r") types[i] = "R"; }
+ }
+
+ // W4. A single European separator between two European numbers
+ // changes to a European number. A single common separator between
+ // two numbers of the same type changes to that type.
+ for (var i = 1, prev = types[0]; i < len - 1; ++i) {
+ var type = types[i];
+ if (type == "+" && prev == "1" && types[i+1] == "1") types[i] = "1";
+ else if (type == "," && prev == types[i+1] &&
+ (prev == "1" || prev == "n")) types[i] = prev;
+ prev = type;
+ }
+
+ // W5. A sequence of European terminators adjacent to European
+ // numbers changes to all European numbers.
+ // W6. Otherwise, separators and terminators change to Other
+ // Neutral.
+ for (var i = 0; i < len; ++i) {
+ var type = types[i];
+ if (type == ",") types[i] = "N";
+ else if (type == "%") {
+ for (var end = i + 1; end < len && types[end] == "%"; ++end) {}
+ var replace = (i && types[i-1] == "!") || (end < len && types[end] == "1") ? "1" : "N";
+ for (var j = i; j < end; ++j) types[j] = replace;
+ i = end - 1;
+ }
+ }
+
+ // W7. Search backwards from each instance of a European number
+ // until the first strong type (R, L, or sor) is found. If an L is
+ // found, then change the type of the European number to L.
+ for (var i = 0, cur = outerType; i < len; ++i) {
+ var type = types[i];
+ if (cur == "L" && type == "1") types[i] = "L";
+ else if (isStrong.test(type)) cur = type;
+ }
+
+ // N1. A sequence of neutrals takes the direction of the
+ // surrounding strong text if the text on both sides has the same
+ // direction. European and Arabic numbers act as if they were R in
+ // terms of their influence on neutrals. Start-of-level-run (sor)
+ // and end-of-level-run (eor) are used at level run boundaries.
+ // N2. Any remaining neutrals take the embedding direction.
+ for (var i = 0; i < len; ++i) {
+ if (isNeutral.test(types[i])) {
+ for (var end = i + 1; end < len && isNeutral.test(types[end]); ++end) {}
+ var before = (i ? types[i-1] : outerType) == "L";
+ var after = (end < len ? types[end] : outerType) == "L";
+ var replace = before || after ? "L" : "R";
+ for (var j = i; j < end; ++j) types[j] = replace;
+ i = end - 1;
+ }
+ }
+
+ // Here we depart from the documented algorithm, in order to avoid
+ // building up an actual levels array. Since there are only three
+ // levels (0, 1, 2) in an implementation that doesn't take
+ // explicit embedding into account, we can build up the order on
+ // the fly, without following the level-based algorithm.
+ var order = [], m;
+ for (var i = 0; i < len;) {
+ if (countsAsLeft.test(types[i])) {
+ var start = i;
+ for (++i; i < len && countsAsLeft.test(types[i]); ++i) {}
+ order.push(new BidiSpan(0, start, i));
+ } else {
+ var pos = i, at = order.length;
+ for (++i; i < len && types[i] != "L"; ++i) {}
+ for (var j = pos; j < i;) {
+ if (countsAsNum.test(types[j])) {
+ if (pos < j) order.splice(at, 0, new BidiSpan(1, pos, j));
+ var nstart = j;
+ for (++j; j < i && countsAsNum.test(types[j]); ++j) {}
+ order.splice(at, 0, new BidiSpan(2, nstart, j));
+ pos = j;
+ } else ++j;
+ }
+ if (pos < i) order.splice(at, 0, new BidiSpan(1, pos, i));
+ }
+ }
+ if (order[0].level == 1 && (m = str.match(/^\s+/))) {
+ order[0].from = m[0].length;
+ order.unshift(new BidiSpan(0, 0, m[0].length));
+ }
+ if (lst(order).level == 1 && (m = str.match(/\s+$/))) {
+ lst(order).to -= m[0].length;
+ order.push(new BidiSpan(0, len - m[0].length, len));
+ }
+ if (order[0].level != lst(order).level)
+ order.push(new BidiSpan(order[0].level, len, len));
+
+ return order;
+ };
+ })();
+
+ // THE END
+
+ CodeMirror.version = "4.1.0";
+
+ return CodeMirror;
+});
diff --git a/cmd/mist/assets/muted/lib/go.js b/cmd/mist/assets/muted/lib/go.js
new file mode 100644
index 000000000..9f1c1c4ab
--- /dev/null
+++ b/cmd/mist/assets/muted/lib/go.js
@@ -0,0 +1,182 @@
+(function(mod) {
+ if (typeof exports == "object" && typeof module == "object") // CommonJS
+ mod(require("../../lib/codemirror"));
+ else if (typeof define == "function" && define.amd) // AMD
+ define(["../../lib/codemirror"], mod);
+ else // Plain browser env
+ mod(CodeMirror);
+})(function(CodeMirror) {
+"use strict";
+
+CodeMirror.defineMode("go", function(config) {
+ var indentUnit = config.indentUnit;
+
+ var keywords = {
+ "break":true, "case":true, "chan":true, "const":true, "continue":true,
+ "default":true, "defer":true, "else":true, "fallthrough":true, "for":true,
+ "func":true, "go":true, "goto":true, "if":true, "import":true,
+ "interface":true, "map":true, "package":true, "range":true, "return":true,
+ "select":true, "struct":true, "switch":true, "type":true, "var":true,
+ "bool":true, "byte":true, "complex64":true, "complex128":true,
+ "float32":true, "float64":true, "int8":true, "int16":true, "int32":true,
+ "int64":true, "string":true, "uint8":true, "uint16":true, "uint32":true,
+ "uint64":true, "int":true, "uint":true, "uintptr":true, "big": true,
+ "main": true, "init": true, "this":true
+ };
+
+ var atoms = {
+ "true":true, "false":true, "iota":true, "nil":true, "append":true,
+ "cap":true, "close":true, "complex":true, "copy":true, "imag":true,
+ "len":true, "make":true, "new":true, "panic":true, "print":true,
+ "println":true, "real":true, "recover":true,
+ };
+
+ var isOperatorChar = /[+\-*&^%:=<>!|\/]/;
+
+ var curPunc;
+
+ function tokenBase(stream, state) {
+ var ch = stream.next();
+ if (ch == '"' || ch == "'" || ch == "`") {
+ state.tokenize = tokenString(ch);
+ return state.tokenize(stream, state);
+ }
+ if (/[\d\.]/.test(ch)) {
+ if (ch == ".") {
+ stream.match(/^[0-9]+([eE][\-+]?[0-9]+)?/);
+ } else if (ch == "0") {
+ stream.match(/^[xX][0-9a-fA-F]+/) || stream.match(/^0[0-7]+/);
+ } else {
+ stream.match(/^[0-9]*\.?[0-9]*([eE][\-+]?[0-9]+)?/);
+ }
+ return "number";
+ }
+ if (/[\[\]{}\(\),;\:\.]/.test(ch)) {
+ curPunc = ch;
+ return null;
+ }
+ if (ch == "/") {
+ if (stream.eat("*")) {
+ state.tokenize = tokenComment;
+ return tokenComment(stream, state);
+ }
+ if (stream.eat("/")) {
+ stream.skipToEnd();
+ return "comment";
+ }
+ }
+ if (isOperatorChar.test(ch)) {
+ stream.eatWhile(isOperatorChar);
+ return "operator";
+ }
+ stream.eatWhile(/[\w\$_]/);
+ var cur = stream.current();
+ if (keywords.propertyIsEnumerable(cur)) {
+ if (cur == "case" || cur == "default") curPunc = "case";
+ return "keyword";
+ }
+ if (atoms.propertyIsEnumerable(cur)) return "atom";
+ return "variable";
+ }
+
+ function tokenString(quote) {
+ return function(stream, state) {
+ var escaped = false, next, end = false;
+ while ((next = stream.next()) != null) {
+ if (next == quote && !escaped) {end = true; break;}
+ escaped = !escaped && next == "\\";
+ }
+ if (end || !(escaped || quote == "`"))
+ state.tokenize = tokenBase;
+ return "string";
+ };
+ }
+
+ function tokenComment(stream, state) {
+ var maybeEnd = false, ch;
+ while (ch = stream.next()) {
+ if (ch == "/" && maybeEnd) {
+ state.tokenize = tokenBase;
+ break;
+ }
+ maybeEnd = (ch == "*");
+ }
+ return "comment";
+ }
+
+ function Context(indented, column, type, align, prev) {
+ this.indented = indented;
+ this.column = column;
+ this.type = type;
+ this.align = align;
+ this.prev = prev;
+ }
+ function pushContext(state, col, type) {
+ return state.context = new Context(state.indented, col, type, null, state.context);
+ }
+ function popContext(state) {
+ var t = state.context.type;
+ if (t == ")" || t == "]" || t == "}")
+ state.indented = state.context.indented;
+ return state.context = state.context.prev;
+ }
+
+ // Interface
+
+ return {
+ startState: function(basecolumn) {
+ return {
+ tokenize: null,
+ context: new Context((basecolumn || 0) - indentUnit, 0, "top", false),
+ indented: 0,
+ startOfLine: true
+ };
+ },
+
+ token: function(stream, state) {
+ var ctx = state.context;
+ if (stream.sol()) {
+ if (ctx.align == null) ctx.align = false;
+ state.indented = stream.indentation();
+ state.startOfLine = true;
+ if (ctx.type == "case") ctx.type = "}";
+ }
+ if (stream.eatSpace()) return null;
+ curPunc = null;
+ var style = (state.tokenize || tokenBase)(stream, state);
+ if (style == "comment") return style;
+ if (ctx.align == null) ctx.align = true;
+
+ if (curPunc == "{") pushContext(state, stream.column(), "}");
+ else if (curPunc == "[") pushContext(state, stream.column(), "]");
+ else if (curPunc == "(") pushContext(state, stream.column(), ")");
+ else if (curPunc == "case") ctx.type = "case";
+ else if (curPunc == "}" && ctx.type == "}") ctx = popContext(state);
+ else if (curPunc == ctx.type) popContext(state);
+ state.startOfLine = false;
+ return style;
+ },
+
+ indent: function(state, textAfter) {
+ if (state.tokenize != tokenBase && state.tokenize != null) return 0;
+ var ctx = state.context, firstChar = textAfter && textAfter.charAt(0);
+ if (ctx.type == "case" && /^(?:case|default)\b/.test(textAfter)) {
+ state.context.type = "}";
+ return ctx.indented;
+ }
+ var closing = firstChar == ctx.type;
+ if (ctx.align) return ctx.column + (closing ? 0 : 1);
+ else return ctx.indented + (closing ? 0 : indentUnit);
+ },
+
+ electricChars: "{}):",
+ fold: "brace",
+ blockCommentStart: "/*",
+ blockCommentEnd: "*/",
+ lineComment: "//"
+ };
+});
+
+CodeMirror.defineMIME("text/x-go", "go");
+
+});
diff --git a/cmd/mist/assets/muted/lib/matchbrackets.js b/cmd/mist/assets/muted/lib/matchbrackets.js
new file mode 100644
index 000000000..dcdde81df
--- /dev/null
+++ b/cmd/mist/assets/muted/lib/matchbrackets.js
@@ -0,0 +1,117 @@
+(function(mod) {
+ if (typeof exports == "object" && typeof module == "object") // CommonJS
+ mod(require("../../lib/codemirror"));
+ else if (typeof define == "function" && define.amd) // AMD
+ define(["../../lib/codemirror"], mod);
+ else // Plain browser env
+ mod(CodeMirror);
+})(function(CodeMirror) {
+ var ie_lt8 = /MSIE \d/.test(navigator.userAgent) &&
+ (document.documentMode == null || document.documentMode < 8);
+
+ var Pos = CodeMirror.Pos;
+
+ var matching = {"(": ")>", ")": "(<", "[": "]>", "]": "[<", "{": "}>", "}": "{<"};
+
+ function findMatchingBracket(cm, where, strict, config) {
+ var line = cm.getLineHandle(where.line), pos = where.ch - 1;
+ var match = (pos >= 0 && matching[line.text.charAt(pos)]) || matching[line.text.charAt(++pos)];
+ if (!match) return null;
+ var dir = match.charAt(1) == ">" ? 1 : -1;
+ if (strict && (dir > 0) != (pos == where.ch)) return null;
+ var style = cm.getTokenTypeAt(Pos(where.line, pos + 1));
+
+ var found = scanForBracket(cm, Pos(where.line, pos + (dir > 0 ? 1 : 0)), dir, style || null, config);
+ if (found == null) return null;
+ return {from: Pos(where.line, pos), to: found && found.pos,
+ match: found && found.ch == match.charAt(0), forward: dir > 0};
+ }
+
+ // bracketRegex is used to specify which type of bracket to scan
+ // should be a regexp, e.g. /[[\]]/
+ //
+ // Note: If "where" is on an open bracket, then this bracket is ignored.
+ //
+ // Returns false when no bracket was found, null when it reached
+ // maxScanLines and gave up
+ function scanForBracket(cm, where, dir, style, config) {
+ var maxScanLen = (config && config.maxScanLineLength) || 10000;
+ var maxScanLines = (config && config.maxScanLines) || 1000;
+
+ var stack = [];
+ var re = config && config.bracketRegex ? config.bracketRegex : /[(){}[\]]/;
+ var lineEnd = dir > 0 ? Math.min(where.line + maxScanLines, cm.lastLine() + 1)
+ : Math.max(cm.firstLine() - 1, where.line - maxScanLines);
+ for (var lineNo = where.line; lineNo != lineEnd; lineNo += dir) {
+ var line = cm.getLine(lineNo);
+ if (!line) continue;
+ var pos = dir > 0 ? 0 : line.length - 1, end = dir > 0 ? line.length : -1;
+ if (line.length > maxScanLen) continue;
+ if (lineNo == where.line) pos = where.ch - (dir < 0 ? 1 : 0);
+ for (; pos != end; pos += dir) {
+ var ch = line.charAt(pos);
+ if (re.test(ch) && (style === undefined || cm.getTokenTypeAt(Pos(lineNo, pos + 1)) == style)) {
+ var match = matching[ch];
+ if ((match.charAt(1) == ">") == (dir > 0)) stack.push(ch);
+ else if (!stack.length) return {pos: Pos(lineNo, pos), ch: ch};
+ else stack.pop();
+ }
+ }
+ }
+ return lineNo - dir == (dir > 0 ? cm.lastLine() : cm.firstLine()) ? false : null;
+ }
+
+ function matchBrackets(cm, autoclear, config) {
+ // Disable brace matching in long lines, since it'll cause hugely slow updates
+ var maxHighlightLen = cm.state.matchBrackets.maxHighlightLineLength || 1000;
+ var marks = [], ranges = cm.listSelections();
+ for (var i = 0; i < ranges.length; i++) {
+ var match = ranges[i].empty() && findMatchingBracket(cm, ranges[i].head, false, config);
+ if (match && cm.getLine(match.from.line).length <= maxHighlightLen) {
+ var style = match.match ? "CodeMirror-matchingbracket" : "CodeMirror-nonmatchingbracket";
+ marks.push(cm.markText(match.from, Pos(match.from.line, match.from.ch + 1), {className: style}));
+ if (match.to && cm.getLine(match.to.line).length <= maxHighlightLen)
+ marks.push(cm.markText(match.to, Pos(match.to.line, match.to.ch + 1), {className: style}));
+ }
+ }
+
+ if (marks.length) {
+ // Kludge to work around the IE bug from issue #1193, where text
+ // input stops going to the textare whever this fires.
+ if (ie_lt8 && cm.state.focused) cm.display.input.focus();
+
+ var clear = function() {
+ cm.operation(function() {
+ for (var i = 0; i < marks.length; i++) marks[i].clear();
+ });
+ };
+ if (autoclear) setTimeout(clear, 800);
+ else return clear;
+ }
+ }
+
+ var currentlyHighlighted = null;
+ function doMatchBrackets(cm) {
+ cm.operation(function() {
+ if (currentlyHighlighted) {currentlyHighlighted(); currentlyHighlighted = null;}
+ currentlyHighlighted = matchBrackets(cm, false, cm.state.matchBrackets);
+ });
+ }
+
+ CodeMirror.defineOption("matchBrackets", false, function(cm, val, old) {
+ if (old && old != CodeMirror.Init)
+ cm.off("cursorActivity", doMatchBrackets);
+ if (val) {
+ cm.state.matchBrackets = typeof val == "object" ? val : {};
+ cm.on("cursorActivity", doMatchBrackets);
+ }
+ });
+
+ CodeMirror.defineExtension("matchBrackets", function() {matchBrackets(this, true);});
+ CodeMirror.defineExtension("findMatchingBracket", function(pos, strict, config){
+ return findMatchingBracket(this, pos, strict, config);
+ });
+ CodeMirror.defineExtension("scanForBracket", function(pos, dir, style, config){
+ return scanForBracket(this, pos, dir, style, config);
+ });
+});
diff --git a/cmd/mist/assets/muted/muted.js b/cmd/mist/assets/muted/muted.js
new file mode 100644
index 000000000..467411577
--- /dev/null
+++ b/cmd/mist/assets/muted/muted.js
@@ -0,0 +1,78 @@
+// Copyright (c) 2013-2014, Jeffrey Wilcke. All rights reserved.
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License, or (at your option) any later version.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// General Public License for more details.
+//
+// You should have received a copy of the GNU General Public License
+// along with this library; if not, write to the Free Software
+// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+// MA 02110-1301 USA
+
+// Helper function for generating pseudo callbacks and sending data to the QML part of the application
+function postData(data, cb) {
+ data._seed = Math.floor(Math.random() * 1000000)
+ if(cb) {
+ Muted._callbacks[data._seed] = cb;
+ }
+
+ if(data.args === undefined) {
+ data.args = [];
+ }
+
+ navigator.qt.postMessage(JSON.stringify(data));
+}
+
+window.Muted = {
+ prototype: Object(),
+}
+
+window.Muted._callbacks = {}
+window.Muted._onCallbacks = {}
+
+function debug(/**/) {
+ console.log("hello world")
+
+ var args = arguments;
+ var msg = ""
+ for(var i = 0; i < args.length; i++){
+ if(typeof args[i] == "object") {
+ msg += " " + JSON.stringify(args[i])
+ } else {
+ msg += args[i]
+ }
+ }
+
+ document.querySelector("#debugger").innerHTML += "<div class='line'><div class='col1'></div><div class='col2'>"+msg+"</div></div>";
+}
+console.log = function() {
+ var args = []
+ for(var i = 0; i < arguments.length; i++) {
+ args.push(arguments[i]);
+ }
+ postData({call:"log", args:args})
+}
+
+navigator.qt.onmessage = function(ev) {
+ var data = JSON.parse(ev.data)
+
+ if(data._event !== undefined) {
+ Muted.trigger(data._event, data.data);
+ } else {
+ if(data._seed) {
+ var cb = Muted._callbacks[data._seed];
+ if(cb) {
+ // Call the callback
+ cb(data.data);
+ // Remove the "trigger" callback
+ delete Muted._callbacks[ev._seed];
+ }
+ }
+ }
+}
diff --git a/cmd/mist/assets/net.png b/cmd/mist/assets/net.png
new file mode 100644
index 000000000..65a20ea00
--- /dev/null
+++ b/cmd/mist/assets/net.png
Binary files differ
diff --git a/cmd/mist/assets/network.png b/cmd/mist/assets/network.png
new file mode 100644
index 000000000..0a9ffe2ec
--- /dev/null
+++ b/cmd/mist/assets/network.png
Binary files differ
diff --git a/cmd/mist/assets/new.png b/cmd/mist/assets/new.png
new file mode 100644
index 000000000..e80096748
--- /dev/null
+++ b/cmd/mist/assets/new.png
Binary files differ
diff --git a/cmd/mist/assets/pick.png b/cmd/mist/assets/pick.png
new file mode 100644
index 000000000..2f5a261c2
--- /dev/null
+++ b/cmd/mist/assets/pick.png
Binary files differ
diff --git a/cmd/mist/assets/qml/QmlApp.qml b/cmd/mist/assets/qml/QmlApp.qml
new file mode 100644
index 000000000..f5c503f4c
--- /dev/null
+++ b/cmd/mist/assets/qml/QmlApp.qml
@@ -0,0 +1,22 @@
+import QtQuick 2.0
+import QtQuick.Controls 1.0;
+import QtQuick.Layouts 1.0;
+import Ethereum 1.0
+
+ApplicationWindow {
+ minimumWidth: 500
+ maximumWidth: 500
+ maximumHeight: 400
+ minimumHeight: 400
+
+ function onNewBlockCb(block) {
+ console.log("Please overwrite onNewBlock(block):", block)
+ }
+ function onObjectChangeCb(stateObject) {
+ console.log("Please overwrite onObjectChangeCb(object)", stateObject)
+ }
+ function onStorageChangeCb(storageObject) {
+ var ev = ["storage", storageObject.stateAddress, storageObject.address].join(":");
+ console.log("Please overwrite onStorageChangeCb(object)", ev)
+ }
+}
diff --git a/cmd/mist/assets/qml/depricated_browser.qml b/cmd/mist/assets/qml/depricated_browser.qml
new file mode 100644
index 000000000..7fb1f2068
--- /dev/null
+++ b/cmd/mist/assets/qml/depricated_browser.qml
@@ -0,0 +1,486 @@
+import QtQuick 2.1
+import QtWebKit 3.0
+import QtWebKit.experimental 1.0
+import QtQuick.Controls 1.0;
+import QtQuick.Controls.Styles 1.0
+import QtQuick.Layouts 1.0;
+import QtQuick.Window 2.1;
+import Ethereum 1.0
+
+Rectangle {
+ id: window
+ anchors.fill: parent
+ color: "#00000000"
+
+ property var title: "DApps"
+ property var iconSource: "../browser.png"
+ property var menuItem
+ property var hideUrl: true
+
+ property alias url: webview.url
+ property alias windowTitle: webview.title
+ property alias webView: webview
+
+ property var cleanPath: false
+ property var open: function(url) {
+ if(!window.cleanPath) {
+ var uri = url;
+ if(!/.*\:\/\/.*/.test(uri)) {
+ uri = "http://" + uri;
+ }
+
+ var reg = /(^https?\:\/\/(?:www\.)?)([a-zA-Z0-9_\-]*\.eth)(.*)/
+
+ if(reg.test(uri)) {
+ uri.replace(reg, function(match, pre, domain, path) {
+ uri = pre;
+
+ var lookup = eth.lookupDomain(domain.substring(0, domain.length - 4));
+ var ip = [];
+ for(var i = 0, l = lookup.length; i < l; i++) {
+ ip.push(lookup.charCodeAt(i))
+ }
+
+ if(ip.length != 0) {
+ uri += lookup;
+ } else {
+ uri += domain;
+ }
+
+ uri += path;
+ });
+ }
+
+ window.cleanPath = true;
+
+ webview.url = uri;
+
+ //uriNav.text = uri.text.replace(/(^https?\:\/\/(?:www\.)?)([a-zA-Z0-9_\-]*\.\w{2,3})(.*)/, "$1$2<span style='color:#CCC'>$3</span>");
+ uriNav.text = uri;
+ } else {
+ // Prevent inf loop.
+ window.cleanPath = false;
+ }
+ }
+
+ Component.onCompleted: {
+ webview.url = "http://etherian.io"
+ }
+
+ function messages(messages, id) {
+ // Bit of a cheat to get proper JSON
+ var m = JSON.parse(JSON.parse(JSON.stringify(messages)))
+ webview.postEvent("eth_changed", id, m);
+ }
+
+ function onShhMessage(message, id) {
+ webview.postEvent("shh_changed", id, message)
+ }
+
+ Item {
+ objectName: "root"
+ id: root
+ anchors.fill: parent
+ state: "inspectorShown"
+
+ RowLayout {
+ id: navBar
+ height: 40
+ anchors {
+ left: parent.left
+ right: parent.right
+ leftMargin: 7
+ }
+
+ Button {
+ id: back
+ onClicked: {
+ webview.goBack()
+ }
+ style: ButtonStyle {
+ background: Image {
+ source: "../back.png"
+ width: 30
+ height: 30
+ }
+ }
+ }
+
+ TextField {
+ anchors {
+ left: back.right
+ right: toggleInspector.left
+ leftMargin: 10
+ rightMargin: 10
+ }
+ text: webview.url;
+ id: uriNav
+ y: parent.height / 2 - this.height / 2
+
+ Keys.onReturnPressed: {
+ webview.url = this.text;
+ }
+ }
+
+ Button {
+ id: toggleInspector
+ anchors {
+ right: parent.right
+ }
+ iconSource: "../bug.png"
+ onClicked: {
+ if(inspector.visible == true){
+ inspector.visible = false
+ }else{
+ inspector.visible = true
+ inspector.url = webview.experimental.remoteInspectorUrl
+ }
+ }
+ }
+ }
+
+ // Border
+ Rectangle {
+ id: divider
+ anchors {
+ left: parent.left
+ right: parent.right
+ top: navBar.bottom
+ }
+ z: -1
+ height: 1
+ color: "#CCCCCC"
+ }
+
+ ScrollView {
+ anchors {
+ left: parent.left
+ right: parent.right
+ bottom: parent.bottom
+ top: divider.bottom
+ }
+ WebView {
+ objectName: "webView"
+ id: webview
+ anchors.fill: parent
+
+ function sendMessage(data) {
+ webview.experimental.postMessage(JSON.stringify(data))
+ }
+
+ experimental.preferences.javascriptEnabled: true
+ experimental.preferences.webAudioEnabled: true
+ experimental.preferences.pluginsEnabled: true
+ experimental.preferences.navigatorQtObjectEnabled: true
+ experimental.preferences.developerExtrasEnabled: true
+ experimental.preferences.webGLEnabled: true
+ experimental.preferences.notificationsEnabled: true
+ experimental.preferences.localStorageEnabled: true
+ experimental.userAgent:"Mozilla/5.0 (Windows NT 6.2; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Mist/0.1 Safari/537.36"
+
+ experimental.itemSelector: MouseArea {
+ // To avoid conflicting with ListView.model when inside Initiator context.
+ property QtObject selectorModel: model
+ anchors.fill: parent
+ onClicked: selectorModel.reject()
+
+ Menu {
+ visible: true
+ id: itemSelector
+
+ Instantiator {
+ model: selectorModel.items
+ delegate: MenuItem {
+ text: model.text
+ onTriggered: {
+ selectorModel.accept(index)
+ }
+ }
+ onObjectAdded: itemSelector.insertItem(index, object)
+ onObjectRemoved: itemSelector.removeItem(object)
+ }
+ }
+
+ Component.onCompleted: {
+ itemSelector.popup()
+ }
+ }
+ experimental.userScripts: ["../ext/q.js", "../ext/ethereum.js/dist/ethereum.min.js", "../ext/setup.js"]
+ experimental.onMessageReceived: {
+ //console.log("[onMessageReceived]: ", message.data)
+ var data = JSON.parse(message.data)
+
+ try {
+ switch(data.call) {
+ case "eth_compile":
+ postData(data._id, eth.compile(data.args[0]))
+ break
+
+ case "eth_coinbase":
+ postData(data._id, eth.coinBase())
+
+ case "eth_account":
+ postData(data._id, eth.key().address);
+
+ case "eth_istening":
+ postData(data._id, eth.isListening())
+
+ break
+
+ case "eth_mining":
+ postData(data._id, eth.isMining())
+
+ break
+
+ case "eth_peerCount":
+ postData(data._id, eth.peerCount())
+
+ break
+
+ case "eth_countAt":
+ require(1)
+ postData(data._id, eth.txCountAt(data.args[0]))
+
+ break
+
+ case "eth_codeAt":
+ require(1)
+ var code = eth.codeAt(data.args[0])
+ postData(data._id, code);
+
+ break
+
+ case "eth_blockByNumber":
+ require(1)
+ var block = eth.blockByNumber(data.args[0])
+ postData(data._id, block)
+ break
+
+ case "eth_blockByHash":
+ require(1)
+ var block = eth.blockByHash(data.args[0])
+ postData(data._id, block)
+ break
+
+ require(2)
+ var block = eth.blockByHash(data.args[0])
+ postData(data._id, block.transactions[data.args[1]])
+ break
+
+ case "eth_transactionByHash":
+ case "eth_transactionByNumber":
+ require(2)
+
+ var block;
+ if (data.call === "transactionByHash")
+ block = eth.blockByHash(data.args[0])
+ else
+ block = eth.blockByNumber(data.args[0])
+
+ var tx = block.transactions.get(data.args[1])
+
+ postData(data._id, tx)
+ break
+
+ case "eth_uncleByHash":
+ case "eth_uncleByNumber":
+ require(2)
+
+ var block;
+ if (data.call === "uncleByHash")
+ block = eth.blockByHash(data.args[0])
+ else
+ block = eth.blockByNumber(data.args[0])
+
+ var uncle = block.uncles.get(data.args[1])
+
+ postData(data._id, uncle)
+
+ break
+
+ case "transact":
+ require(5)
+
+ var tx = eth.transact(data.args)
+ postData(data._id, tx)
+
+ break
+
+ case "eth_stateAt":
+ require(2);
+
+ var storage = eth.storageAt(data.args[0], data.args[1]);
+ postData(data._id, storage)
+
+ break
+
+ case "eth_call":
+ require(1);
+ var ret = eth.call(data.args)
+ postData(data._id, ret)
+ break
+
+ case "eth_balanceAt":
+ require(1);
+
+ postData(data._id, eth.balanceAt(data.args[0]));
+ break
+
+ case "eth_watch":
+ require(2)
+ eth.watch(data.args[0], data.args[1])
+
+ case "eth_disconnect":
+ require(1)
+ postData(data._id, null)
+ break;
+
+ case "eth_newFilterString":
+ require(1)
+ var id = eth.newFilterString(data.args[0], window)
+ postData(data._id, id);
+ break;
+
+ case "eth_newFilter":
+ require(1)
+ var id = eth.newFilter(data.args[0], window)
+
+ postData(data._id, id);
+ break;
+
+ case "eth_filterLogs":
+ require(1);
+
+ var messages = eth.messages(data.args[0]);
+ var m = JSON.parse(JSON.parse(JSON.stringify(messages)))
+ postData(data._id, m);
+
+ break;
+
+ case "eth_deleteFilter":
+ require(1);
+ eth.uninstallFilter(data.args[0])
+ break;
+
+
+ case "shh_newFilter":
+ require(1);
+ var id = shh.watch(data.args[0], window);
+ postData(data._id, id);
+ break;
+
+ case "shh_newIdentity":
+ var id = shh.newIdentity()
+ postData(data._id, id)
+
+ break
+
+ case "shh_post":
+ require(1);
+
+ var params = data.args[0];
+ var fields = ["payload", "to", "from"];
+ for(var i = 0; i < fields.length; i++) {
+ params[fields[i]] = params[fields[i]] || "";
+ }
+ if(typeof params.payload !== "object") { params.payload = [params.payload]; } //params.payload = params.payload.join(""); }
+ params.topics = params.topics || [];
+ params.priority = params.priority || 1000;
+ params.ttl = params.ttl || 100;
+
+ shh.post(params.payload, params.to, params.from, params.topics, params.priority, params.ttl);
+
+ break;
+
+ case "shh_getMessages":
+ require(1);
+
+ var m = shh.messages(data.args[0]);
+ var messages = JSON.parse(JSON.parse(JSON.stringify(m)));
+ postData(data._id, messages);
+
+ break;
+
+ case "ssh_newGroup":
+ postData(data._id, "");
+ break;
+ }
+ } catch(e) {
+ console.log(data.call + ": " + e)
+
+ postData(data._id, null);
+ }
+ }
+
+ function post(seed, data) {
+ postData(data._id, data)
+ }
+ function require(args, num) {
+ if(args.length < num) {
+ throw("required argument count of "+num+" got "+args.length);
+ }
+ }
+ function postData(seed, data) {
+ webview.experimental.postMessage(JSON.stringify({data: data, _id: seed}))
+ }
+ function postEvent(event, id, data) {
+ webview.experimental.postMessage(JSON.stringify({data: data, _id: id, _event: event}))
+ }
+ function onWatchedCb(data, id) {
+ var messages = JSON.parse(data)
+ postEvent("watched:"+id, messages)
+ }
+ function onNewBlockCb(block) {
+ postEvent("block:new", block)
+ }
+ function onObjectChangeCb(stateObject) {
+ postEvent("object:"+stateObject.address(), stateObject)
+ }
+ function onStorageChangeCb(storageObject) {
+ var ev = ["storage", storageObject.stateAddress, storageObject.address].join(":");
+ postEvent(ev, [storageObject.address, storageObject.value])
+ }
+ }
+ }
+
+ Rectangle {
+ id: sizeGrip
+ color: "gray"
+ visible: false
+ height: 10
+ anchors {
+ left: root.left
+ right: root.right
+ }
+ y: Math.round(root.height * 2 / 3)
+
+ MouseArea {
+ anchors.fill: parent
+ drag.target: sizeGrip
+ drag.minimumY: 0
+ drag.maximumY: root.height
+ drag.axis: Drag.YAxis
+ }
+ }
+
+ WebView {
+ id: inspector
+ visible: false
+ anchors {
+ left: root.left
+ right: root.right
+ top: sizeGrip.bottom
+ bottom: root.bottom
+ }
+ }
+
+ states: [
+ State {
+ name: "inspectorShown"
+ PropertyChanges {
+ target: inspector
+ }
+ }
+ ]
+ }
+}
diff --git a/cmd/mist/assets/qml/first_run.qml b/cmd/mist/assets/qml/first_run.qml
new file mode 100644
index 000000000..0b1dac4c6
--- /dev/null
+++ b/cmd/mist/assets/qml/first_run.qml
@@ -0,0 +1,155 @@
+import QtQuick 2.0
+import Ethereum 1.0
+
+// Which ones do we actually need?
+import QtQuick.Controls 1.0;
+import QtQuick.Layouts 1.0;
+import QtQuick.Dialogs 1.0;
+import QtQuick.Window 2.1;
+import QtQuick.Controls.Styles 1.1
+import QtQuick.Dialogs 1.1
+
+ApplicationWindow {
+ id: wizardRoot
+ width: 500
+ height: 400
+ title: "Ethereal first run setup"
+
+ Column {
+ spacing: 5
+ anchors.leftMargin: 10
+ anchors.left: parent.left
+
+ Text {
+ visible: true
+ text: "<h2>Ethereal setup</h2>"
+ }
+
+ Column {
+ id: restoreColumn
+ spacing: 5
+ Text {
+ visible: true
+ font.pointSize: 14
+ text: "Restore your Ethereum account"
+ id: restoreLabel
+ }
+
+ TextField {
+ id: txPrivKey
+ width: 480
+ placeholderText: "Private key or mnemonic words"
+ focus: true
+ onTextChanged: {
+ if(this.text.length == 64){
+ detailLabel.text = "Private (hex) key detected."
+ actionButton.enabled = true
+ }
+ else if(this.text.split(" ").length == 24){
+ detailLabel.text = "Mnemonic key detected."
+ actionButton.enabled = true
+ }else{
+ detailLabel.text = ""
+ actionButton.enabled = false
+ }
+ }
+ }
+ Row {
+ spacing: 10
+ Button {
+ id: actionButton
+ text: "Restore"
+ enabled: false
+ onClicked: {
+ var success = lib.importAndSetPrivKey(txPrivKey.text)
+ if(success){
+ importedDetails.visible = true
+ restoreColumn.visible = false
+ newKey.visible = false
+ wizardRoot.height = 120
+ }
+ }
+ }
+ Text {
+ id: detailLabel
+ font.pointSize: 12
+ anchors.topMargin: 10
+ }
+ }
+ }
+ Column {
+ id: importedDetails
+ visible: false
+ Text {
+ text: "<b>Your account has been imported. Please close the application and restart it again to let the changes take effect.</b>"
+ wrapMode: Text.WordWrap
+ width: 460
+ }
+ }
+ Column {
+ spacing: 5
+ id: newDetailsColumn
+ visible: false
+ Text {
+ font.pointSize: 14
+ text: "Your account details"
+ }
+ Label {
+ text: "Address"
+ }
+ TextField {
+ id: addressInput
+ readOnly:true
+ width: 480
+ }
+ Label {
+ text: "Private key"
+ }
+ TextField {
+ id: privkeyInput
+ readOnly:true
+ width: 480
+ }
+ Label {
+ text: "Mnemonic words"
+ }
+ TextField {
+ id: mnemonicInput
+ readOnly:true
+ width: 480
+ }
+ Label {
+ text: "<b>A new account has been created. Please take the time to write down the <i>24 words</i>. You can use those to restore your account at a later date.</b>"
+ wrapMode: Text.WordWrap
+ width: 480
+ }
+ Label {
+ text: "Please restart the application once you have completed the steps above."
+ wrapMode: Text.WordWrap
+ width: 480
+ }
+ }
+
+ }
+ Button {
+ anchors.right: parent.right
+ anchors.bottom: parent.bottom
+ anchors.rightMargin: 10
+ anchors.bottomMargin: 10
+ id: newKey
+ text: "I don't have an account yet"
+ onClicked: {
+ var res = lib.createAndSetPrivKey()
+ mnemonicInput.text = res[0]
+ addressInput.text = res[1]
+ privkeyInput.text = res[2]
+
+ // Hide restore
+ restoreColumn.visible = false
+
+ // Show new details
+ newDetailsColumn.visible = true
+ newKey.visible = false
+ }
+ }
+}
diff --git a/cmd/mist/assets/qml/fonts/Simple-Line-Icons.ttf b/cmd/mist/assets/qml/fonts/Simple-Line-Icons.ttf
new file mode 100755
index 000000000..2194f1f87
--- /dev/null
+++ b/cmd/mist/assets/qml/fonts/Simple-Line-Icons.ttf
Binary files differ
diff --git a/cmd/mist/assets/qml/fonts/SourceSansPro-Black.ttf b/cmd/mist/assets/qml/fonts/SourceSansPro-Black.ttf
new file mode 100644
index 000000000..be1a3108e
--- /dev/null
+++ b/cmd/mist/assets/qml/fonts/SourceSansPro-Black.ttf
Binary files differ
diff --git a/cmd/mist/assets/qml/fonts/SourceSansPro-BlackIt.ttf b/cmd/mist/assets/qml/fonts/SourceSansPro-BlackIt.ttf
new file mode 100644
index 000000000..ac5c4ef7c
--- /dev/null
+++ b/cmd/mist/assets/qml/fonts/SourceSansPro-BlackIt.ttf
Binary files differ
diff --git a/cmd/mist/assets/qml/fonts/SourceSansPro-Bold.ttf b/cmd/mist/assets/qml/fonts/SourceSansPro-Bold.ttf
new file mode 100644
index 000000000..f47161c6b
--- /dev/null
+++ b/cmd/mist/assets/qml/fonts/SourceSansPro-Bold.ttf
Binary files differ
diff --git a/cmd/mist/assets/qml/fonts/SourceSansPro-BoldIt.ttf b/cmd/mist/assets/qml/fonts/SourceSansPro-BoldIt.ttf
new file mode 100644
index 000000000..6b3db698b
--- /dev/null
+++ b/cmd/mist/assets/qml/fonts/SourceSansPro-BoldIt.ttf
Binary files differ
diff --git a/cmd/mist/assets/qml/fonts/SourceSansPro-ExtraLight.ttf b/cmd/mist/assets/qml/fonts/SourceSansPro-ExtraLight.ttf
new file mode 100644
index 000000000..0a3e51fdb
--- /dev/null
+++ b/cmd/mist/assets/qml/fonts/SourceSansPro-ExtraLight.ttf
Binary files differ
diff --git a/cmd/mist/assets/qml/fonts/SourceSansPro-ExtraLightIt.ttf b/cmd/mist/assets/qml/fonts/SourceSansPro-ExtraLightIt.ttf
new file mode 100644
index 000000000..a0eb86aca
--- /dev/null
+++ b/cmd/mist/assets/qml/fonts/SourceSansPro-ExtraLightIt.ttf
Binary files differ
diff --git a/cmd/mist/assets/qml/fonts/SourceSansPro-It.ttf b/cmd/mist/assets/qml/fonts/SourceSansPro-It.ttf
new file mode 100644
index 000000000..fcc95fc7c
--- /dev/null
+++ b/cmd/mist/assets/qml/fonts/SourceSansPro-It.ttf
Binary files differ
diff --git a/cmd/mist/assets/qml/fonts/SourceSansPro-Light.ttf b/cmd/mist/assets/qml/fonts/SourceSansPro-Light.ttf
new file mode 100644
index 000000000..9cae13c97
--- /dev/null
+++ b/cmd/mist/assets/qml/fonts/SourceSansPro-Light.ttf
Binary files differ
diff --git a/cmd/mist/assets/qml/fonts/SourceSansPro-LightIt.ttf b/cmd/mist/assets/qml/fonts/SourceSansPro-LightIt.ttf
new file mode 100644
index 000000000..2ed784284
--- /dev/null
+++ b/cmd/mist/assets/qml/fonts/SourceSansPro-LightIt.ttf
Binary files differ
diff --git a/cmd/mist/assets/qml/fonts/SourceSansPro-Regular.ttf b/cmd/mist/assets/qml/fonts/SourceSansPro-Regular.ttf
new file mode 100644
index 000000000..8e8255e17
--- /dev/null
+++ b/cmd/mist/assets/qml/fonts/SourceSansPro-Regular.ttf
Binary files differ
diff --git a/cmd/mist/assets/qml/fonts/SourceSansPro-Semibold.ttf b/cmd/mist/assets/qml/fonts/SourceSansPro-Semibold.ttf
new file mode 100644
index 000000000..121ee9bbf
--- /dev/null
+++ b/cmd/mist/assets/qml/fonts/SourceSansPro-Semibold.ttf
Binary files differ
diff --git a/cmd/mist/assets/qml/fonts/SourceSansPro-SemiboldIt.ttf b/cmd/mist/assets/qml/fonts/SourceSansPro-SemiboldIt.ttf
new file mode 100644
index 000000000..6ceaa885f
--- /dev/null
+++ b/cmd/mist/assets/qml/fonts/SourceSansPro-SemiboldIt.ttf
Binary files differ
diff --git a/cmd/mist/assets/qml/fonts/SourceSerifPro-Bold.ttf b/cmd/mist/assets/qml/fonts/SourceSerifPro-Bold.ttf
new file mode 100644
index 000000000..ac7837fd9
--- /dev/null
+++ b/cmd/mist/assets/qml/fonts/SourceSerifPro-Bold.ttf
Binary files differ
diff --git a/cmd/mist/assets/qml/fonts/SourceSerifPro-Regular.ttf b/cmd/mist/assets/qml/fonts/SourceSerifPro-Regular.ttf
new file mode 100644
index 000000000..7201a8890
--- /dev/null
+++ b/cmd/mist/assets/qml/fonts/SourceSerifPro-Regular.ttf
Binary files differ
diff --git a/cmd/mist/assets/qml/fonts/SourceSerifPro-Semibold.ttf b/cmd/mist/assets/qml/fonts/SourceSerifPro-Semibold.ttf
new file mode 100644
index 000000000..db2fc804b
--- /dev/null
+++ b/cmd/mist/assets/qml/fonts/SourceSerifPro-Semibold.ttf
Binary files differ
diff --git a/cmd/mist/assets/qml/main.qml b/cmd/mist/assets/qml/main.qml
new file mode 100644
index 000000000..bf83dc3b2
--- /dev/null
+++ b/cmd/mist/assets/qml/main.qml
@@ -0,0 +1,1030 @@
+import QtQuick 2.0
+import QtQuick.Controls 1.0;
+import QtQuick.Layouts 1.0;
+import QtQuick.Dialogs 1.0;
+import QtQuick.Window 2.1;
+import QtQuick.Controls.Styles 1.1
+import Ethereum 1.0
+
+import "../ext/filter.js" as Eth
+import "../ext/http.js" as Http
+
+
+ApplicationWindow {
+ id: root
+
+ //flags: Qt.FramelessWindowHint
+ // Use this to make the window frameless. But then you'll need to do move and resize by hand
+
+ property var ethx : Eth.ethx
+ property var catalog;
+
+ width: 1200
+ height: 820
+ minimumHeight: 600
+ minimumWidth: 800
+
+ title: "Mist"
+
+ TextField {
+ id: copyElementHax
+ visible: false
+ }
+
+ function copyToClipboard(text) {
+ copyElementHax.text = text
+ copyElementHax.selectAll()
+ copyElementHax.copy()
+ }
+
+ // Takes care of loading all default plugins
+ Component.onCompleted: {
+
+ catalog = addPlugin("./views/catalog.qml", {noAdd: true, close: false, section: "begin", active: true});
+
+ var walletWeb = addPlugin("./views/browser.qml", {noAdd: true, close: false, section: "ethereum", active: false});
+ walletWeb.view.url = "http://ethereum-dapp-wallet.meteor.com/";
+ walletWeb.menuItem.title = "Wallet";
+
+ addPlugin("./views/miner.qml", {noAdd: true, close: false, section: "legacy", active: false});
+ addPlugin("./views/network.qml", {noAdd: true, close: false, section: "ethereum", active: false});
+
+ /* var whisperTab = addPlugin("./views/browser.qml", {noAdd: true, close: true, section: "ethereum", active: false});
+ whisperTab.view.url = "http://ethereum-dapp-whisper-client.meteor.com/";
+ whisperTab.menuItem.title = "Whisper Chat";
+*/
+ addPlugin("./views/wallet.qml", {noAdd: true, close: false, section: "legacy"});
+ addPlugin("./views/transaction.qml", {noAdd: true, close: false, section: "legacy"});
+ addPlugin("./views/whisper.qml", {noAdd: true, close: false, section: "legacy"});
+ addPlugin("./views/chain.qml", {noAdd: true, close: false, section: "legacy"});
+ addPlugin("./views/pending_tx.qml", {noAdd: true, close: false, section: "legacy"});
+ addPlugin("./views/info.qml", {noAdd: true, close: false, section: "legacy"});
+
+ mainSplit.setView(catalog.view, catalog.menuItem);
+
+ //newBrowserTab("http://ethereum-dapp-catalog.meteor.com");
+
+ // Command setup
+ gui.sendCommand(0)
+ }
+
+ function activeView(view, menuItem) {
+ mainSplit.setView(view, menuItem)
+ /*if (view.hideUrl) {
+ urlPane.visible = false;
+ mainView.anchors.top = rootView.top
+ } else {
+ urlPane.visible = true;
+ mainView.anchors.top = divider.bottom
+ }*/
+
+ }
+
+ function addViews(view, path, options) {
+ var views = mainSplit.addComponent(view, options)
+ views.menuItem.path = path
+
+ mainSplit.views.push(views);
+
+ if(!options.noAdd) {
+ gui.addPlugin(path)
+ }
+
+ return views
+ }
+
+ function addPlugin(path, options) {
+ try {
+ if(typeof(path) === "string" && /^https?/.test(path)) {
+ console.log('load http')
+ Http.request(path, function(o) {
+ if(o.status === 200) {
+ var view = Qt.createQmlObject(o.responseText, mainView, path)
+ addViews(view, path, options)
+ }
+ })
+
+ return
+ }
+
+ var component = Qt.createComponent(path);
+ if(component.status != Component.Ready) {
+ if(component.status == Component.Error) {
+ ethx.note("error: ", component.errorString());
+ }
+
+ return
+ }
+
+ var view = mainView.createView(component, options)
+ var views = addViews(view, path, options)
+
+ return views
+ } catch(e) {
+ console.log(e)
+ }
+ }
+
+ function newBrowserTab(url) {
+
+ var urlMatches = url.toString().match(/^[a-z]*\:\/\/([^\/?#]+)(?:[\/?#]|$)/i);
+ var requestedDomain = urlMatches && urlMatches[1];
+
+ var domainAlreadyOpen = false;
+
+ for(var i = 0; i < mainSplit.views.length; i++) {
+ if (mainSplit.views[i].view.url) {
+ var matches = mainSplit.views[i].view.url.toString().match(/^[a-z]*\:\/\/(?:www\.)?([^\/?#]+)(?:[\/?#]|$)/i);
+ var existingDomain = matches && matches[1];
+ if (requestedDomain == existingDomain) {
+ domainAlreadyOpen = true;
+
+ if (mainSplit.views[i].view.url != url){
+ mainSplit.views[i].view.url = url;
+ }
+
+ activeView(mainSplit.views[i].view, mainSplit.views[i].menuItem);
+ }
+ }
+ }
+
+ if (!domainAlreadyOpen) {
+ var window = addPlugin("./views/browser.qml", {noAdd: true, close: true, section: "apps", active: true});
+ window.view.url = url;
+ window.menuItem.title = "Mist";
+ activeView(window.view, window.menuItem);
+ }
+ }
+
+
+ menuBar: MenuBar {
+ Menu {
+ title: "File"
+ MenuItem {
+ text: "New tab"
+ shortcut: "Ctrl+t"
+ onTriggered: {
+ activeView(catalog.view, catalog.menuItem);
+ }
+ }
+
+ MenuSeparator {}
+
+ MenuItem {
+ text: "Import key"
+ shortcut: "Ctrl+i"
+ onTriggered: {
+ generalFileDialog.show(true, function(path) {
+ gui.importKey(path)
+ })
+ }
+ }
+
+ MenuItem {
+ text: "Export keys"
+ shortcut: "Ctrl+e"
+ onTriggered: {
+ generalFileDialog.show(false, function(path) {
+ })
+ }
+ }
+
+ MenuItem {
+ text: "Generate key"
+ shortcut: "Ctrl+k"
+ onTriggered: gui.generateKey()
+ }
+ }
+
+ Menu {
+ title: "Developer"
+ MenuItem {
+ text: "Import Tx"
+ onTriggered: {
+ txImportDialog.visible = true
+ }
+ }
+
+ MenuItem {
+ text: "Dump state"
+ onTriggered: {
+ generalFileDialog.show(false, function(path) {
+ // Empty hash for latest
+ gui.dumpState("", path)
+ })
+ }
+ }
+
+ MenuSeparator {}
+ }
+
+ Menu {
+ title: "Network"
+ MenuItem {
+ text: "Add Peer"
+ shortcut: "Ctrl+p"
+ onTriggered: {
+ addPeerWin.visible = true
+ }
+ }
+ MenuItem {
+ text: "Show Peers"
+ shortcut: "Ctrl+e"
+ onTriggered: {
+ peerWindow.visible = true
+ }
+ }
+ }
+
+ Menu {
+ title: "Help"
+ MenuItem {
+ text: "About"
+ onTriggered: {
+ aboutWin.visible = true
+ }
+ }
+ }
+
+ }
+
+ property var blockModel: ListModel {
+ id: blockModel
+ }
+
+ SplitView {
+ property var views: [];
+
+ id: mainSplit
+ anchors.fill: parent
+ //resizing: false // this is NOT where we remove that damning resizing handle..
+ handleDelegate: Item {
+ //This handle is a way to remove the line between the split views
+ Rectangle {
+ anchors.fill: parent
+ }
+ }
+
+ function setView(view, menu) {
+ for(var i = 0; i < views.length; i++) {
+ views[i].view.visible = false
+ views[i].menuItem.setSelection(false)
+ }
+ view.visible = true
+ menu.setSelection(true)
+ }
+
+ function addComponent(view, options) {
+ view.visible = false
+ view.anchors.fill = mainView
+
+ var menuItem = menu.createMenuItem(view, options);
+ if( view.hasOwnProperty("menuItem") ) {
+ view.menuItem = menuItem;
+ }
+
+ if( view.hasOwnProperty("onReady") ) {
+ view.onReady.call(view)
+ }
+
+ if( options.active ) {
+ setView(view, menuItem)
+ }
+
+
+ return {view: view, menuItem: menuItem}
+ }
+
+ /*********************
+ * Main menu.
+ ********************/
+ Rectangle {
+ id: menu
+ Layout.minimumWidth: 192
+ Layout.maximumWidth: 192
+
+ FontLoader {
+ id: sourceSansPro
+ source: "fonts/SourceSansPro-Regular.ttf"
+ }
+ FontLoader {
+ source: "fonts/SourceSansPro-Semibold.ttf"
+ }
+ FontLoader {
+ source: "fonts/SourceSansPro-Bold.ttf"
+ }
+ FontLoader {
+ source: "fonts/SourceSansPro-Black.ttf"
+ }
+ FontLoader {
+ source: "fonts/SourceSansPro-Light.ttf"
+ }
+ FontLoader {
+ source: "fonts/SourceSansPro-ExtraLight.ttf"
+ }
+ FontLoader {
+ id: simpleLineIcons
+ source: "fonts/Simple-Line-Icons.ttf"
+ }
+
+ Rectangle {
+ color: "steelblue"
+ anchors.fill: parent
+
+ MouseArea {
+ anchors.fill: parent
+ property real lastMouseX: 0
+ property real lastMouseY: 0
+ onPressed: {
+ lastMouseX = mouseX
+ lastMouseY = mouseY
+ }
+ onPositionChanged: {
+ root.x += (mouseX - lastMouseX)
+ root.y += (mouseY - lastMouseY)
+ }
+ /*onDoubleClicked: {
+ //!maximized ? view.set_max() : view.set_normal()}
+ visibility = "Minimized"
+ }*/
+ }
+ }
+
+
+
+ anchors.top: parent.top
+ Rectangle {
+ width: parent.height
+ height: parent.width
+ anchors.centerIn: parent
+ rotation: 90
+
+ gradient: Gradient {
+ GradientStop { position: 0.0; color: "#E2DEDE" }
+ GradientStop { position: 0.1; color: "#EBE8E8" }
+ GradientStop { position: 1.0; color: "#EBE8E8" }
+ }
+ }
+
+ Component {
+ id: menuItemTemplate
+ Rectangle {
+ id: menuItem
+ property var view;
+ property var path;
+ property var closable;
+ property var badgeContent;
+
+ property alias title: label.text
+ property alias icon: icon.source
+ property alias secondaryTitle: secondary.text
+ property alias badgeNumber: badgeNumberLabel.text
+ property alias badgeIcon: badgeIconLabel.text
+
+ function setSelection(on) {
+ sel.visible = on
+
+ if (this.closable == true) {
+ closeIcon.visible = on
+ }
+ }
+
+ function setAsBigButton(on) {
+ newAppButton.visible = on
+ label.visible = !on
+ buttonLabel.visible = on
+ }
+
+ width: 192
+ height: 55
+ color: "#00000000"
+
+ anchors {
+ left: parent.left
+ leftMargin: 4
+ }
+
+ Rectangle {
+ // New App Button
+ id: newAppButton
+ visible: false
+ anchors.fill: parent
+ anchors.rightMargin: 8
+ border.width: 0
+ radius: 5
+ height: 55
+ width: 180
+ color: "#F3F1F3"
+ }
+
+ Rectangle {
+ id: sel
+ visible: false
+ anchors.fill: parent
+ color: "#00000000"
+ Rectangle {
+ id: r
+ anchors.fill: parent
+ border.width: 0
+ radius: 5
+ color: "#FAFAFA"
+ }
+ Rectangle {
+ anchors {
+ top: r.top
+ bottom: r.bottom
+ right: r.right
+ }
+ width: 10
+ color: "#FAFAFA"
+ border.width:0
+
+ Rectangle {
+ // Small line on top of selection. What's this for?
+ anchors {
+ left: parent.left
+ right: parent.right
+ top: parent.top
+ }
+ height: 1
+ color: "#FAFAFA"
+ }
+
+ Rectangle {
+ // Small line on bottom of selection. What's this for again?
+ anchors {
+ left: parent.left
+ right: parent.right
+ bottom: parent.bottom
+ }
+ height: 1
+ color: "#FAFAFA"
+ }
+ }
+ }
+
+ MouseArea {
+ anchors.fill: parent
+ hoverEnabled: true
+ onClicked: {
+ activeView(view, menuItem);
+ }
+ onEntered: {
+ if (parent.closable == true) {
+ closeIcon.visible = sel.visible
+ }
+ }
+ onExited: {
+ closeIcon.visible = false
+ }
+ }
+
+ Image {
+ id: icon
+ height: 28
+ width: 28
+ anchors {
+ left: parent.left
+ verticalCenter: parent.verticalCenter
+ leftMargin: 6
+ }
+ }
+
+ Text {
+ id: buttonLabel
+ visible: false
+ text: "GO TO NEW APP"
+ font.family: sourceSansPro.name
+ font.weight: Font.DemiBold
+ anchors.horizontalCenter: parent.horizontalCenter
+ anchors.verticalCenter: parent.verticalCenter
+ color: "#AAA0A0"
+ }
+
+ Text {
+ id: label
+ font.family: sourceSansPro.name
+ font.weight: Font.DemiBold
+ elide: Text.ElideRight
+ x:250
+ color: "#665F5F"
+ font.pixelSize: 14
+ anchors {
+ left: icon.right
+ right: parent.right
+ verticalCenter: parent.verticalCenter
+ leftMargin: 6
+ rightMargin: 8
+ verticalCenterOffset: (secondaryTitle == "") ? 0 : -10;
+ }
+
+
+
+
+ }
+
+ Text {
+ id: secondary
+ //only shows secondary title if there's no badge
+ visible: (badgeContent == "icon" || badgeContent == "number" )? false : true
+ font.family: sourceSansPro.name
+ font.weight: Font.Light
+ anchors {
+ left: icon.right
+ leftMargin: 6
+ top: label.bottom
+ }
+ color: "#6691C2"
+ font.pixelSize: 12
+ }
+
+ Rectangle {
+ id: closeIcon
+ visible: false
+ width: 10
+ height: 10
+ color: "#FAFAFA"
+ anchors {
+ fill: icon
+ }
+
+ MouseArea {
+ anchors.fill: parent
+ onClicked: {
+ menuItem.closeApp()
+ }
+ }
+
+ Text {
+
+ font.family: simpleLineIcons.name
+ anchors {
+ centerIn: parent
+ }
+ color: "#665F5F"
+ font.pixelSize: 20
+ text: "\ue082"
+ }
+ }
+
+ Rectangle {
+ id: badge
+ visible: (badgeContent == "icon" || badgeContent == "number" )? true : false
+ width: 32
+ color: "#05000000"
+ anchors {
+ right: parent.right;
+ top: parent.top;
+ bottom: parent.bottom;
+ rightMargin: 4;
+ }
+
+ Text {
+ id: badgeIconLabel
+ visible: (badgeContent == "icon") ? true : false;
+ font.family: simpleLineIcons.name
+ anchors {
+ centerIn: parent
+ }
+ horizontalAlignment: Text.AlignCenter
+ color: "#AAA0A0"
+ font.pixelSize: 20
+ text: badgeIcon
+ }
+
+ Text {
+ id: badgeNumberLabel
+ visible: (badgeContent == "number") ? true : false;
+ anchors {
+ centerIn: parent
+ }
+ horizontalAlignment: Text.AlignCenter
+ font.family: sourceSansPro.name
+ font.weight: Font.Light
+ color: "#AAA0A0"
+ font.pixelSize: 18
+ text: badgeNumber
+ }
+ }
+
+
+
+ function closeApp() {
+ if(!this.closable) { return; }
+
+ if(this.view.hasOwnProperty("onDestroy")) {
+ this.view.onDestroy.call(this.view)
+ }
+
+ this.view.destroy()
+ this.destroy()
+ for (var i = 0; i < mainSplit.views.length; i++) {
+ var view = mainSplit.views[i];
+ if (view.menuItem === this) {
+ mainSplit.views.splice(i, 1);
+ break;
+ }
+ }
+ gui.removePlugin(this.path)
+ activeView(mainSplit.views[0].view, mainSplit.views[0].menuItem);
+ }
+ }
+ }
+
+ function createMenuItem(view, options) {
+ if(options === undefined) {
+ options = {};
+ }
+
+ var section;
+ switch(options.section) {
+ case "begin":
+ section = menuBegin
+ break;
+ case "ethereum":
+ section = menuDefault;
+ break;
+ case "legacy":
+ section = menuLegacy;
+ break;
+ default:
+ section = menuApps;
+ break;
+ }
+
+ var comp = menuItemTemplate.createObject(section)
+ comp.view = view
+ comp.title = view.title
+
+ if(view.hasOwnProperty("iconSource")) {
+ comp.icon = view.iconSource;
+ }
+ comp.closable = options.close;
+
+ if (options.section === "begin") {
+ comp.setAsBigButton(true)
+ }
+
+ return comp
+ }
+
+ ColumnLayout {
+ id: menuColumn
+ y: 10
+ width: parent.width
+ anchors.left: parent.left
+ anchors.right: parent.right
+ spacing: 3
+
+
+
+ ColumnLayout {
+ id: menuBegin
+ spacing: 3
+ anchors {
+ left: parent.left
+ right: parent.right
+ }
+ }
+
+ Rectangle {
+ height: 19
+ color: "transparent"
+ Text {
+ text: "ETHEREUM"
+ font.family: sourceSansPro.name
+ font.weight: Font.Regular
+ // anchors.top: 20
+ // anchors.left: 16
+ anchors {
+ leftMargin: 12
+ topMargin: 4
+ fill: parent
+ }
+ // anchors.leftMargin: 16
+ // anchors.topMargin: 16
+ // anchors.verticalCenterOffset: 50
+ color: "#AAA0A0"
+ }
+ }
+
+
+ ColumnLayout {
+ id: menuDefault
+ spacing: 3
+ anchors {
+ left: parent.left
+ right: parent.right
+ }
+ }
+
+ Rectangle {
+ height: 19
+ color: "#00ff00"
+ visible: (menuApps.children.length > 0)
+
+ Text {
+ text: "APPS"
+ font.family: sourceSansPro.name
+ font.weight: Font.Regular
+ anchors.fill: parent
+ anchors.leftMargin: 16
+ color: "#AAA0A0"
+ }
+ }
+
+ ColumnLayout {
+ id: menuApps
+ spacing: 3
+
+
+ anchors {
+ left: parent.left
+ right: parent.right
+ }
+ }
+
+ ColumnLayout {
+ id: menuLegacy
+ visible: true
+ spacing: 3
+ anchors {
+ left: parent.left
+ right: parent.right
+ }
+ }
+ }
+ }
+
+ /*********************
+ * Main view
+ ********************/
+ Rectangle {
+ id: rootView
+ anchors.right: parent.right
+ anchors.left: menu.right
+ anchors.bottom: parent.bottom
+ anchors.top: parent.top
+ color: "#00000000"
+
+ /*Rectangle {
+ id: urlPane
+ height: 40
+ color: "#00000000"
+ anchors {
+ left: parent.left
+ right: parent.right
+ leftMargin: 5
+ rightMargin: 5
+ top: parent.top
+ topMargin: 5
+ }
+ TextField {
+ id: url
+ objectName: "url"
+ placeholderText: "DApp URL"
+ anchors {
+ left: parent.left
+ right: parent.right
+ top: parent.top
+ topMargin: 5
+ rightMargin: 5
+ leftMargin: 5
+ }
+
+ Keys.onReturnPressed: {
+ if(/^https?/.test(this.text)) {
+ newBrowserTab(this.text);
+ } else {
+ addPlugin(this.text, {close: true, section: "apps"})
+ }
+ }
+ }
+
+ }
+
+ // Border
+ Rectangle {
+ id: divider
+ anchors {
+ left: parent.left
+ right: parent.right
+ top: urlPane.bottom
+ }
+ z: -1
+ height: 1
+ color: "#CCCCCC"
+ }*/
+
+ Rectangle {
+ id: mainView
+ color: "#00000000"
+ anchors.right: parent.right
+ anchors.left: parent.left
+ anchors.bottom: parent.bottom
+ anchors.top: parent.top
+
+ function createView(component) {
+ var view = component.createObject(mainView)
+
+ return view;
+ }
+ }
+ }
+ }
+
+
+ /******************
+ * Dialogs
+ *****************/
+ FileDialog {
+ id: generalFileDialog
+ property var callback;
+ onAccepted: {
+ var path = this.fileUrl.toString();
+ callback.call(this, path);
+ }
+
+ function show(selectExisting, callback) {
+ generalFileDialog.callback = callback;
+ generalFileDialog.selectExisting = selectExisting;
+
+ this.open();
+ }
+ }
+
+
+ /******************
+ * Wallet functions
+ *****************/
+ function importApp(path) {
+ var ext = path.split('.').pop()
+ if(ext == "html" || ext == "htm") {
+ eth.openHtml(path)
+ }else if(ext == "qml"){
+ addPlugin(path, {close: true, section: "apps"})
+ }
+ }
+
+ function setWalletValue(value) {
+ //walletValueLabel.text = value
+ }
+
+ function loadPlugin(name) {
+ console.log("Loading plugin" + name)
+ var view = mainView.addPlugin(name)
+ }
+
+ function clearPeers() { peerModel.clear() }
+ function addPeer(peer) { peerModel.append(peer) }
+
+ function setPeerCounters(text) {
+ //peerCounterLabel.text = text
+ }
+
+ function timeAgo(unixTs){
+ var lapsed = (Date.now() - new Date(unixTs*1000)) / 1000
+ return (lapsed + " seconds ago")
+ }
+
+ function convertToPretty(unixTs){
+ var a = new Date(unixTs*1000);
+ var months = ['Jan','Feb','Mar','Apr','May','Jun','Jul','Aug','Sep','Oct','Nov','Dec'];
+ var year = a.getFullYear();
+ var month = months[a.getMonth()];
+ var date = a.getDate();
+ var hour = a.getHours();
+ var min = a.getMinutes();
+ var sec = a.getSeconds();
+ var time = date+' '+month+' '+year+' '+hour+':'+min+':'+sec ;
+ return time;
+ }
+
+ /**********************
+ * Windows
+ *********************/
+ Window {
+ id: peerWindow
+ //flags: Qt.CustomizeWindowHint | Qt.Tool | Qt.WindowCloseButtonHint
+ height: 200
+ width: 700
+ Rectangle {
+ anchors.fill: parent
+ property var peerModel: ListModel {
+ id: peerModel
+ }
+ TableView {
+ anchors.fill: parent
+ id: peerTable
+ model: peerModel
+ TableViewColumn{width: 180; role: "addr" ; title: "Remote Address" }
+ TableViewColumn{width: 280; role: "nodeID" ; title: "Node ID" }
+ TableViewColumn{width: 100; role: "name" ; title: "Name" }
+ TableViewColumn{width: 40; role: "caps" ; title: "Capabilities" }
+ }
+ }
+ }
+
+ Window {
+ id: aboutWin
+ visible: false
+ title: "About"
+ minimumWidth: 350
+ maximumWidth: 350
+ maximumHeight: 280
+ minimumHeight: 280
+
+ Image {
+ id: aboutIcon
+ height: 150
+ width: 150
+ fillMode: Image.PreserveAspectFit
+ smooth: true
+ source: "../facet.png"
+ x: 10
+ y: 30
+ }
+
+ Text {
+ anchors.left: aboutIcon.right
+ anchors.leftMargin: 10
+ anchors.top: parent.top
+ anchors.topMargin: 30
+ font.pointSize: 12
+ text: "<h2>Mist (0.9.0)</h2><br><h3>Development</h3>Jeffrey Wilcke<br>Viktor Trón<br>Felix Lange<br>Taylor Gerring<br>Daniel Nagy<br>Gustav Simonsson<br><h3>UX/UI</h3>Alex van de Sande<br>Fabian Vogelsteller"
+ }
+ }
+
+ Window {
+ id: txImportDialog
+ minimumWidth: 270
+ maximumWidth: 270
+ maximumHeight: 50
+ minimumHeight: 50
+ TextField {
+ id: txImportField
+ width: 170
+ anchors.verticalCenter: parent.verticalCenter
+ anchors.left: parent.left
+ anchors.leftMargin: 10
+ onAccepted: {
+ }
+ }
+ Button {
+ anchors.left: txImportField.right
+ anchors.verticalCenter: parent.verticalCenter
+ anchors.leftMargin: 5
+ text: "Import"
+ onClicked: {
+ eth.importTx(txImportField.text)
+ txImportField.visible = false
+ }
+ }
+ Component.onCompleted: {
+ addrField.focus = true
+ }
+ }
+
+ Window {
+ id: addPeerWin
+ visible: false
+ minimumWidth: 400
+ maximumWidth: 400
+ maximumHeight: 50
+ minimumHeight: 50
+ title: "Connect to peer"
+
+ TextField {
+ id: addrField
+ anchors.verticalCenter: parent.verticalCenter
+ anchors.left: parent.left
+ anchors.right: addPeerButton.left
+ anchors.leftMargin: 10
+ anchors.rightMargin: 10
+ placeholderText: "enode://<hex node id>:<IP address>:<port>"
+ onAccepted: {
+ if(addrField.text.length != 0) {
+ eth.connectToPeer(addrField.text)
+ addPeerWin.visible = false
+ }
+ }
+ }
+
+ Button {
+ id: addPeerButton
+ anchors.right: parent.right
+ anchors.verticalCenter: parent.verticalCenter
+ anchors.rightMargin: 10
+ text: "Connect"
+ onClicked: {
+ if(addrField.text.length != 0) {
+ eth.connectToPeer(addrField.text)
+ addPeerWin.visible = false
+ }
+ }
+ }
+ Component.onCompleted: {
+ addrField.focus = true
+ }
+ }
+ }
diff --git a/cmd/mist/assets/qml/muted.qml b/cmd/mist/assets/qml/muted.qml
new file mode 100644
index 000000000..fac8267c4
--- /dev/null
+++ b/cmd/mist/assets/qml/muted.qml
@@ -0,0 +1,74 @@
+import QtQuick 2.0
+import QtWebKit 3.0
+import QtWebKit.experimental 1.0
+import QtQuick.Controls 1.0;
+import QtQuick.Layouts 1.0;
+import QtQuick.Window 2.1;
+import Ethereum 1.0
+
+ApplicationWindow {
+ id: window
+ title: "muted"
+ width: 900
+ height: 600
+ minimumHeight: 300
+
+ property alias url: webView.url
+ property alias webView: webView
+
+
+ Item {
+ id: root
+ anchors.fill: parent
+ WebView {
+ objectName: "webView"
+ id: webView
+ anchors {
+ top: root.top
+ right: root.right
+ left: root.left
+ bottom: root.bottom
+ //bottom: sizeGrip.top
+ }
+
+ experimental.preferences.javascriptEnabled: true
+ experimental.preferences.navigatorQtObjectEnabled: true
+ experimental.onMessageReceived: {
+ var data = JSON.parse(message.data)
+
+ switch(data.call) {
+ case "log":
+ console.log.apply(this, data.args)
+ break;
+ }
+ }
+ function postData(seed, data) {
+ webview.experimental.postMessage(JSON.stringify({data: data, _seed: seed}))
+ }
+ function postEvent(event, data) {
+ webview.experimental.postMessage(JSON.stringify({data: data, _event: event}))
+ }
+ }
+
+ /*
+ Rectangle {
+ id: sizeGrip
+ color: "gray"
+ height: 5
+ anchors {
+ left: root.left
+ right: root.right
+ }
+ y: Math.round(root.height * 2 / 3)
+
+ MouseArea {
+ anchors.fill: parent
+ drag.target: sizeGrip
+ drag.minimumY: 0
+ drag.maximumY: root.height - sizeGrip.height
+ drag.axis: Drag.YAxis
+ }
+ }
+ */
+ }
+}
diff --git a/cmd/mist/assets/qml/test_app.qml b/cmd/mist/assets/qml/test_app.qml
new file mode 100644
index 000000000..c69587839
--- /dev/null
+++ b/cmd/mist/assets/qml/test_app.qml
@@ -0,0 +1,70 @@
+import QtQuick 2.0
+import QtQuick.Controls 1.0;
+import QtQuick.Layouts 1.0;
+import Ethereum 1.0
+
+QmlApp {
+ minimumWidth: 350
+ maximumWidth: 350
+ maximumHeight: 80
+ minimumHeight: 80
+
+ title: "Generic Coin"
+
+ property string contractAddr: "f299f6c74515620e4c4cd8fe3d205b5c4f2e25c8"
+ property string addr: "2ef47100e0787b915105fd5e3f4ff6752079d5cb"
+
+ Component.onCompleted: {
+ eth.watch(contractAddr, addr)
+ eth.watch(addr, contractAddr)
+ setAmount()
+ }
+
+ function onStorageChangeCb(storageObject) {
+ setAmount()
+ }
+
+ function setAmount(){
+ var state = eth.getStateObject(contractAddr)
+ var storage = state.getStorage(addr)
+ amountLabel.text = storage
+ }
+ Column {
+ spacing: 5
+ Row {
+ spacing: 20
+ Label {
+ id: genLabel
+ text: "Generic coin balance:"
+ }
+ Label {
+ id: amountLabel
+ }
+ }
+ Row {
+ spacing: 20
+ TextField {
+ id: address
+ placeholderText: "Address"
+ }
+ TextField {
+ id: amount
+ placeholderText: "Amount"
+ }
+ }
+ Button {
+ text: "Send coins"
+ onClicked: {
+ var privKey = eth.getKey().privateKey
+ if(privKey){
+ var result = eth.transact(privKey, contractAddr, 0,"100000","250", "0x" + address.text + "\n" + amount.text)
+ resultTx.text = result.hash
+ }
+ }
+ }
+ Label {
+ id: resultTx
+ }
+ }
+
+}
diff --git a/cmd/mist/assets/qml/transactions.qml b/cmd/mist/assets/qml/transactions.qml
new file mode 100644
index 000000000..e9a035a85
--- /dev/null
+++ b/cmd/mist/assets/qml/transactions.qml
@@ -0,0 +1,9 @@
+import QtQuick 2.0
+import QtQuick.Controls 1.0;
+import QtQuick.Layouts 1.0;
+
+Rectangle {
+ id: transactionView
+ visible: false
+ Text { text: "TX VIEW" }
+}
diff --git a/cmd/mist/assets/qml/views/browser.qml b/cmd/mist/assets/qml/views/browser.qml
new file mode 100644
index 000000000..edecc8696
--- /dev/null
+++ b/cmd/mist/assets/qml/views/browser.qml
@@ -0,0 +1,506 @@
+import QtQuick 2.0
+import QtQuick.Controls 1.0;
+import QtQuick.Controls.Styles 1.0
+import QtQuick.Layouts 1.0;
+import QtWebEngine 1.0
+import QtWebEngine.experimental 1.0
+import QtQuick.Window 2.0;
+
+Rectangle {
+ id: window
+ anchors.fill: parent
+ color: "#00000000"
+
+ property var title: ""
+ property var iconSource: "../browser.png"
+ property var menuItem
+ property var hideUrl: true
+
+ property alias url: webview.url
+ property alias windowTitle: webview.title
+ property alias webView: webview
+
+ property var cleanPath: false
+ property var open: function(url) {
+ if(!window.cleanPath) {
+ var uri = url;
+ if(!/.*\:\/\/.*/.test(uri)) {
+ uri = "http://" + uri;
+ }
+
+ var reg = /(^https?\:\/\/(?:www\.)?)([a-zA-Z0-9_\-]*\.eth)(.*)/
+
+ if(reg.test(uri)) {
+ uri.replace(reg, function(match, pre, domain, path) {
+ uri = pre;
+
+ var lookup = eth.lookupDomain(domain.substring(0, domain.length - 4));
+ var ip = [];
+ for(var i = 0, l = lookup.length; i < l; i++) {
+ ip.push(lookup.charCodeAt(i))
+ }
+
+ if(ip.length != 0) {
+ uri += lookup;
+ } else {
+ uri += domain;
+ }
+
+ uri += path;
+ });
+ }
+
+ window.cleanPath = true;
+
+ webview.url = uri;
+
+ //uriNav.text = uri.text.replace(/(^https?\:\/\/(?:www\.)?)([a-zA-Z0-9_\-]*\.\w{2,3})(.*)/, "$1$2<span style='color:#CCC'>$3</span>");
+ uriNav.text = uri;
+
+ } else {
+ // Prevent inf loop.
+ window.cleanPath = false;
+ }
+ }
+
+ function showFullUrlBar(on){
+ if (uriNav.focus == false ) {
+ if (on == false) {
+ clickAnywhereOnApp.visible = false
+ navBar.state = "titleVisible"
+ } else {
+ clickAnywhereOnApp.visible = true
+ navBar.state = "fullUrlVisible"
+ }
+ }
+
+ }
+
+ Component.onCompleted: {
+ }
+
+ Item {
+ objectName: "root"
+ id: root
+ anchors {
+ fill: parent
+ }
+
+ state: "inspectorShown"
+
+ MouseArea {
+ id: clickAnywhereOnApp
+ z:15
+ // Using a secondary screen to catch on mouse exits for the area, because
+ // there are many hover actions conflicting
+
+ anchors {
+ top: parent.top
+ topMargin: 50
+ right: parent.right
+ bottom: parent.bottom
+ left: parent.left
+ }
+ hoverEnabled: true
+
+ onEntered: {
+ showFullUrlBar(false);
+ }
+
+ onClicked: {
+ uriNav.focus = false
+ showFullUrlBar(false);
+ }
+
+ // Rectangle {
+ // anchors.fill: parent
+ // color: "#88888888"
+ // }
+ }
+
+ RowLayout {
+ id: navBar
+ height: 74
+ z: 20
+ anchors {
+ left: parent.left
+ right: parent.right
+ }
+
+ Button {
+ id: back
+ z: 30
+ onClicked: {
+ webview.goBack()
+ }
+
+ anchors {
+ left: parent.left
+ leftMargin: 6
+ }
+
+ style: ButtonStyle {
+ background: Image {
+ source: (webview.canGoBack) ?
+ (control.hovered ? "../../backButtonHover.png" : "../../backButton.png") :
+ "../../backButtonDisabled.png"
+ width: 20
+ height: 30
+ }
+ }
+ }
+
+ Rectangle {
+ id: appInfoPane
+ height: 28
+ color: "#FFFFFF"
+ radius: 6
+ z:2
+ MouseArea {
+ anchors.fill: parent
+ z: 10
+ hoverEnabled: true
+
+ onEntered: {
+ showFullUrlBar(true);
+ }
+ /*onExited: {
+ showFullUrlBar(false);
+ }*/
+
+ }
+
+ anchors {
+ left: back.right
+ right: parent.right
+ leftMargin: 10
+ rightMargin: 10
+ }
+
+ Text {
+ id: appTitle
+ text: "LOADING"
+ font.bold: true
+ font.capitalization: Font.AllUppercase
+ horizontalAlignment: Text.AlignRight
+ verticalAlignment: Text.AlignVCenter
+ elide: Text.ElideRight
+
+ anchors {
+ left: parent.left
+ right: parent.horizontalCenter
+ top: parent.top
+ bottom: parent.bottom
+ leftMargin: 32
+ }
+ color: "#928484"
+ }
+
+ Text {
+ id: appDomain
+ text: "loading domain"
+ font.bold: false
+ horizontalAlignment: Text.AlignLeft
+ verticalAlignment: Text.AlignVCenter
+ elide: Text.ElideLeft
+
+ anchors {
+ left: parent.horizontalCenter
+ right: parent.right
+ top: parent.top
+ bottom: parent.bottom
+ leftMargin: 32
+
+ }
+ color: "#C0AFAF"
+ }
+
+
+ TextField {
+ id: uriNav
+ opacity: 0.0
+
+ anchors {
+ left: parent.left
+ right: parent.right
+ leftMargin: 16
+ }
+
+ horizontalAlignment: Text.AlignHCenter
+
+ style: TextFieldStyle {
+ textColor: "#928484"
+ background: Rectangle {
+ border.width: 0
+ color: "transparent"
+ }
+ }
+ text: webview.url;
+ y: parent.height / 2 - this.height / 2
+ z: 20
+ activeFocusOnPress: true
+ Keys.onReturnPressed: {
+ // if there's no http, add it.
+ var url = this.text,
+ matches = url.match(/^([a-z]*\:\/\/)?([^\/.]+)(:?\/)(.*|$)/i),
+ requestedProtocol = (matches && matches[1] != "undefined")? "" : "http://";
+
+ webview.url = requestedProtocol + url;
+ }
+ }
+
+
+ }
+
+ Rectangle {
+ id: appInfoPaneShadow
+ width: 10
+ height: 30
+ color: "#BDB6B6"
+ radius: 6
+ z:1
+
+ anchors {
+ left: back.right
+ right: parent.right
+ leftMargin:10
+ rightMargin:10
+ top: parent.top
+ topMargin: 23
+ }
+ }
+
+ Rectangle {
+ id: navBarBackground
+ anchors.fill: parent
+ z:-1
+ gradient: Gradient {
+ GradientStop { position: 0.0; color: "#F6F1F2" }
+ GradientStop { position: 1.0; color: "#DED5D5" }
+ }
+ }
+
+ states: [
+ State {
+ name: "fullUrlVisible"
+ PropertyChanges {
+ target: appTitle
+ anchors.rightMargin: -50
+ opacity: 0.0
+ }
+ PropertyChanges {
+ target: appDomain
+ anchors.leftMargin: -50
+ opacity: 0.0
+ }
+ PropertyChanges {
+ target: uriNav
+ anchors.leftMargin: 0
+ opacity: 1.0
+ }
+ },
+ State {
+ name: "titleVisible"
+
+ PropertyChanges {
+ target: appTitle
+ anchors.rightMargin: 10
+ opacity: 1.0
+ }
+ PropertyChanges {
+ target: appDomain
+ anchors.leftMargin: 10
+ opacity: 1.0
+ }
+ PropertyChanges {
+ target: uriNav
+ anchors.leftMargin: -50
+ opacity: 0.0
+ }
+ }
+
+ ]
+
+ transitions: [
+ // This adds a transition that defaults to applying to all state changes
+
+ Transition {
+
+ // This applies a default NumberAnimation to any changes a state change makes to x or y properties
+ NumberAnimation {
+ properties: "anchors.leftMargin, anchors.rightMargin, opacity"
+ easing.type: Easing.InOutQuad //Easing.InOutBack
+ duration: 300
+ }
+ }
+ ]
+
+ }
+
+ WebEngineView {
+ objectName: "webView"
+ id: webview
+ experimental.settings.javascriptCanAccessClipboard: true
+ //experimental.settings.localContentCanAccessRemoteUrls: true
+ anchors {
+ left: parent.left
+ right: parent.right
+ bottom: parent.bottom
+ top: navBar.bottom
+ }
+ z: 10
+
+ Timer {
+ interval: 2000; running: true; repeat: true
+ onTriggered: {
+ webview.runJavaScript("try{document.querySelector('meta[name=ethereum-dapp-info]').getAttribute('content')}catch(e){}", function(extraInfo) {
+ if (extraInfo) {
+ menuItem.secondaryTitle = extraInfo;
+ }
+ });
+ webview.runJavaScript("try{document.querySelector('meta[name=ethereum-dapp-badge]').getAttribute('content')}catch(e){}", function(badge) {
+ if (badge) {
+ if (Number(badge)>0 && Number(badge)<999) {
+ menuItem.badgeNumber = Number(badge);
+ menuItem.badgeContent = "number"
+ } else if (badge == "warning") {
+ menuItem.badgeIcon = "\ue00e"
+ menuItem.badgeContent = "icon"
+
+ } else if (badge == "ghost") {
+ menuItem.badgeIcon = "\ue01a"
+ menuItem.badgeContent = "icon"
+
+ } else if (badge == "question") {
+ menuItem.badgeIcon = "\ue05d"
+ menuItem.badgeContent = "icon"
+
+ } else if (badge == "info") {
+ menuItem.badgeIcon = "\ue08b"
+ menuItem.badgeContent = "icon"
+
+ } else if (badge == "check") {
+ menuItem.badgeIcon = "\ue080"
+ menuItem.badgeContent = "icon"
+
+ } else if (badge == "gear") {
+ menuItem.badgeIcon = "\ue09a"
+ menuItem.badgeContent = "icon"
+
+ } else {
+ menuItem.badgeContent = ""
+ }
+ } else {
+ menuItem.badgeContent = ""
+ }
+ });
+ }
+ }
+
+ onLoadingChanged: {
+ if (loadRequest.status == WebEngineView.LoadSucceededStatus) {
+
+ webview.runJavaScript("document.title", function(pageTitle) {
+ menuItem.title = pageTitle;
+ });
+
+ webView.runJavaScript("try{document.querySelector(\"link[rel='icon']\").getAttribute(\"href\")}catch(e){}", function(sideIcon){
+ if(sideIcon){
+ menuItem.icon = webview.url + sideIcon;
+ };
+ });
+
+ webView.runJavaScript("try{document.querySelector(\"meta[name='ethereum-dapp-url-bar-style']\").getAttribute(\"content\")}catch(e){}", function(topBarStyle){
+ if (!topBarStyle) {
+ showFullUrlBar(true);
+ navBarBackground.visible = true;
+ back.visible = true;
+ appInfoPane.anchors.leftMargin = 0;
+ appInfoPaneShadow.anchors.leftMargin = 0;
+ webview.anchors.topMargin = 0;
+ return;
+ }
+
+ if (topBarStyle=="transparent") {
+ // Adjust for a transparent sidebar Dapp
+ navBarBackground.visible = false;
+ back.visible = false;
+ appInfoPane.anchors.leftMargin = -16;
+ appInfoPaneShadow.anchors.leftMargin = -16;
+ webview.anchors.topMargin = -74;
+ webview.runJavaScript("document.querySelector('body').classList.add('ethereum-dapp-url-bar-style-transparent')")
+
+ } else {
+ navBarBackground.visible = true;
+ back.visible = true;
+ appInfoPane.anchors.leftMargin = 0;
+ appInfoPaneShadow.anchors.leftMargin = 0;
+ webview.anchors.topMargin = 0;
+ };
+ });
+
+
+ webview.runJavaScript(eth.readFile("bignumber.min.js"));
+ webview.runJavaScript(eth.readFile("ethereum.js/dist/ethereum.js"));
+ webview.runJavaScript(eth.readFile("mist.js"));
+
+ var cleanTitle = webview.url.toString()
+ var matches = cleanTitle.match(/^[a-z]*\:\/\/([^\/?#]+)(?:[\/?#]|$)/i);
+ var domain = matches && matches[1];
+
+
+ if (domain)
+ appDomain.text = domain //webview.url.replace("a", "z")
+ if (webview.title)
+ appTitle.text = webview.title
+
+ showFullUrlBar(false);
+ }
+ }
+ onJavaScriptConsoleMessage: {
+ console.log(sourceID + ":" + lineNumber + ":" + JSON.stringify(message));
+ }
+ }
+
+ Rectangle {
+ id: sizeGrip
+ color: "gray"
+ visible: false
+ height: 10
+ anchors {
+ left: root.left
+ right: root.right
+ }
+ y: Math.round(root.height * 2 / 3)
+
+ MouseArea {
+ anchors.fill: parent
+ drag.target: sizeGrip
+ drag.minimumY: 0
+ drag.maximumY: root.height
+ drag.axis: Drag.YAxis
+ }
+ }
+
+ WebEngineView {
+ id: inspector
+ visible: false
+ anchors {
+ left: root.left
+ right: root.right
+ top: sizeGrip.bottom
+ bottom: root.bottom
+ }
+
+ }
+
+ states: [
+ State {
+ name: "inspectorShown"
+ PropertyChanges {
+ target: inspector
+ }
+ }
+ ]
+ }
+}
diff --git a/cmd/mist/assets/qml/views/catalog.qml b/cmd/mist/assets/qml/views/catalog.qml
new file mode 100644
index 000000000..29e133074
--- /dev/null
+++ b/cmd/mist/assets/qml/views/catalog.qml
@@ -0,0 +1,144 @@
+import QtQuick 2.0
+import QtQuick.Controls 1.0;
+import QtQuick.Controls.Styles 1.0
+import QtQuick.Layouts 1.0;
+import QtWebEngine 1.0
+import QtWebEngine.experimental 1.0
+import QtQuick.Window 2.0;
+
+
+Rectangle {
+ id: window
+ anchors.fill: parent
+ color: "#00000000"
+
+ property var title: "Catalog"
+ property var iconSource: ""
+ property var menuItem
+ property var hideUrl: true
+
+ property alias url: webview.url
+ property alias windowTitle: webview.title
+ property alias webView: webview
+
+ property var cleanPath: false
+ property var open: function(url) {
+ if(!window.cleanPath) {
+ var uri = url;
+ if(!/.*\:\/\/.*/.test(uri)) {
+ uri = "http://" + uri;
+ }
+
+ var reg = /(^https?\:\/\/(?:www\.)?)([a-zA-Z0-9_\-]*\.eth)(.*)/
+
+ if(reg.test(uri)) {
+ uri.replace(reg, function(match, pre, domain, path) {
+ uri = pre;
+
+ var lookup = eth.lookupDomain(domain.substring(0, domain.length - 4));
+ var ip = [];
+ for(var i = 0, l = lookup.length; i < l; i++) {
+ ip.push(lookup.charCodeAt(i))
+ }
+
+ if(ip.length != 0) {
+ uri += lookup;
+ } else {
+ uri += domain;
+ }
+
+ uri += path;
+ });
+ }
+
+ window.cleanPath = true;
+
+ webview.url = uri;
+
+ //uriNav.text = uri.text.replace(/(^https?\:\/\/(?:www\.)?)([a-zA-Z0-9_\-]*\.\w{2,3})(.*)/, "$1$2<span style='color:#CCC'>$3</span>");
+ uriNav.text = uri;
+
+ } else {
+ // Prevent inf loop.
+ window.cleanPath = false;
+ }
+ }
+
+ Item {
+ objectName: "root"
+ id: root
+ anchors.fill: parent
+ state: "inspectorShown"
+
+ WebEngineView {
+ objectName: "webView"
+ id: webview
+ anchors.fill: parent
+
+ property var protocol: "http://"
+ //property var domain: "localhost:3000"
+ property var domain: "ethereum-dapp-catalog.meteor.com"
+ url: protocol + domain
+
+ experimental.settings.javascriptCanAccessClipboard: true
+
+
+ onJavaScriptConsoleMessage: {
+ console.log(sourceID + ":" + lineNumber + ":" + JSON.stringify(message));
+ }
+
+ onNavigationRequested: {
+ // this checks if the domain of the requested link is the same as the catalog's
+ // If it is, it opens on the same window, if it's not it opens a new tab
+
+ var cleanTitle = request.url.toString()
+ var matches = cleanTitle.match(/^[a-z]*\:\/\/([^\/?#]+)(?:[\/?#]|$)/i);
+ var requestedDomain = matches && matches[1];
+
+
+ if(request.navigationType==0){
+
+ if (requestedDomain === this.domain){
+ request.action = WebEngineView.AcceptRequest;
+ } else {
+ request.action = WebEngineView.IgnoreRequest;
+ newBrowserTab(request.url);
+ }
+
+ }
+ }
+ onLoadingChanged: {
+ if (loadRequest.status == WebEngineView.LoadSucceededStatus) {
+ webview.runJavaScript(eth.readFile("mist.js"));
+ }
+ }
+ }
+
+
+
+
+
+
+ WebEngineView {
+ id: inspector
+ visible: false
+ z:10
+ anchors {
+ left: root.left
+ right: root.right
+ top: root.top
+ bottom: root.bottom
+ }
+
+ }
+
+ states: [
+ State {
+ name: "inspectorShown"
+ PropertyChanges {
+ target: inspector
+ }
+ }
+ ]
+ }
+}
diff --git a/cmd/mist/assets/qml/views/chain.qml b/cmd/mist/assets/qml/views/chain.qml
new file mode 100644
index 000000000..9892beddf
--- /dev/null
+++ b/cmd/mist/assets/qml/views/chain.qml
@@ -0,0 +1,244 @@
+import QtQuick 2.0
+import QtQuick.Controls 1.0;
+import QtQuick.Layouts 1.0;
+import QtQuick.Dialogs 1.0;
+import QtQuick.Window 2.1;
+import QtQuick.Controls.Styles 1.1
+import Ethereum 1.0
+
+Rectangle {
+ id: root
+ property var title: "Block Chain"
+ property var menuItem
+
+ objectName: "chainView"
+ visible: false
+ anchors.fill: parent
+
+ TableView {
+ id: blockTable
+ width: parent.width
+ anchors.top: parent.top
+ anchors.bottom: parent.bottom
+ TableViewColumn{ role: "number" ; title: "#" ; width: 100 }
+ TableViewColumn{ role: "hash" ; title: "Hash" ; width: 560 }
+ TableViewColumn{ role: "txAmount" ; title: "Tx amount" ; width: 100 }
+
+ model: blockModel
+
+ itemDelegate: Item {
+ Text {
+ anchors {
+ left: parent.left
+ right: parent.right
+ leftMargin: 10
+ verticalCenter: parent.verticalCenter
+ }
+ color: styleData.textColor
+ elide: styleData.elideMode
+ text: styleData.value
+ font.pixelSize: 11
+ MouseArea {
+ acceptedButtons: Qt.LeftButton | Qt.RightButton
+ propagateComposedEvents: true
+ anchors.fill: parent
+ onClicked: {
+ blockTable.selection.clear()
+ blockTable.selection.select(styleData.row)
+
+ if(mouse.button == Qt.RightButton) {
+ contextMenu.row = styleData.row;
+ contextMenu.popup()
+ }
+ }
+
+ onDoubleClicked: {
+ popup.visible = true
+ popup.setDetails(blockModel.get(styleData.row))
+ }
+ }
+ }
+
+ }
+
+ Menu {
+ id: contextMenu
+ property var row
+ MenuItem {
+ text: "Details"
+ onTriggered: {
+ popup.visible = true
+ popup.setDetails(blockModel.get(contextMenu.row))
+ }
+ }
+
+ MenuSeparator{}
+
+ MenuItem {
+ text: "Copy"
+ onTriggered: {
+ copyToClipboard(blockModel.get(contextMenu.row).hash)
+ }
+ }
+
+ MenuItem {
+ text: "Dump State"
+ onTriggered: {
+ generalFileDialog.show(false, function(path) {
+ var hash = blockModel.get(contextMenu.row).hash;
+
+ gui.dumpState(hash, path);
+ });
+ }
+ }
+ }
+ }
+
+
+
+ function addBlock(block, initial) {
+ if(initial == undefined){
+ initial = false
+ }
+
+ var amount = block.transactions.length;
+ var txs = [];
+ for(var i = 0; i < block.transactions.length; i++) {
+ var tx = JSON.parse(block.transactions.getAsJson(i));
+ txs.push(tx);
+ }
+
+ if(initial){
+ blockModel.append({raw: block.raw, bloom: block.bloom, size: block.size, number: block.number, name: block.name, gasLimit: block.gasLimit, gasUsed: block.gasUsed, coinbase: block.coinbase, hash: block.hash, txs: txs, txAmount: amount, time: block.time, prettyTime: convertToPretty(block.time)})
+ } else {
+ blockModel.insert(0, {raw: block.raw, bloom: block.bloom, size: block.size, number: block.number, name: block.name, gasLimit: block.gasLimit, gasUsed: block.gasUsed, coinbase: block.coinbase, hash: block.hash, txs: txs, txAmount: amount, time: block.time, prettyTime: convertToPretty(block.time)})
+ }
+ }
+
+ Window {
+ id: popup
+ visible: false
+ //flags: Qt.CustomizeWindowHint | Qt.Tool | Qt.WindowCloseButtonHint
+ property var block
+ width: root.width
+ height: 300
+ Component{
+ id: blockDetailsDelegate
+ Rectangle {
+ color: "#252525"
+ width: popup.width
+ height: 150
+ Column {
+ anchors.leftMargin: 10
+ anchors.topMargin: 5
+ anchors.top: parent.top
+ anchors.left: parent.left
+ Text { text: '<h3>Block details</h3>'; color: "#F2F2F2"}
+ Text { text: '<b>Block number:</b> ' + number + " (Size: " + size + ")"; color: "#F2F2F2"}
+ Text { text: '<b>Hash:</b> ' + hash; color: "#F2F2F2"}
+ Text { text: '<b>Bloom:</b> ' + bloom; color: "#F2F2F2"}
+ Text { text: '<b>Coinbase:</b> &lt;' + name + '&gt; ' + coinbase; color: "#F2F2F2"}
+ Text { text: '<b>Block found at:</b> ' + prettyTime; color: "#F2F2F2"}
+ Text { text: '<b>Gas used:</b> ' + gasUsed + " / " + gasLimit; color: "#F2F2F2"}
+ }
+ }
+ }
+ ListView {
+ model: singleBlock
+ delegate: blockDetailsDelegate
+ anchors.top: parent.top
+ height: 100
+ anchors.leftMargin: 20
+ id: listViewThing
+ Layout.maximumHeight: 40
+ }
+ TableView {
+ id: txView
+ anchors.top: listViewThing.bottom
+ anchors.topMargin: 50
+ width: parent.width
+
+ TableViewColumn{width: 90; role: "value" ; title: "Value" }
+ TableViewColumn{width: 200; role: "hash" ; title: "Hash" }
+ TableViewColumn{width: 200; role: "sender" ; title: "Sender" }
+ TableViewColumn{width: 200;role: "address" ; title: "Receiver" }
+ TableViewColumn{width: 60; role: "gas" ; title: "Gas" }
+ TableViewColumn{width: 60; role: "gasPrice" ; title: "Gas Price" }
+ TableViewColumn{width: 60; role: "isContract" ; title: "Contract" }
+
+ model: transactionModel
+ onClicked: {
+ var tx = transactionModel.get(row)
+ if(tx.data) {
+ popup.showContractData(tx)
+ }else{
+ popup.height = 440
+ }
+ }
+ }
+
+ function showContractData(tx) {
+ if(tx.createsContract) {
+ contractData.text = tx.data
+ contractLabel.text = "<h4> Transaction created contract " + tx.address + "</h4>"
+ }else{
+ contractLabel.text = "<h4> Transaction ran contract " + tx.address + "</h4>"
+ contractData.text = tx.rawData
+ }
+ popup.height = 540
+ }
+
+ Rectangle {
+ id: txDetails
+ width: popup.width
+ height: 300
+ anchors.left: listViewThing.left
+ anchors.top: txView.bottom
+ Label {
+ text: "<h4>Contract data</h4>"
+ anchors.top: parent.top
+ anchors.left: parent.left
+ id: contractLabel
+ anchors.leftMargin: 10
+ }
+ TextArea {
+ id: contractData
+ text: "Contract"
+ anchors.top: contractLabel.bottom
+ anchors.left: parent.left
+ anchors.right: parent.right
+ wrapMode: Text.Wrap
+ height: 80
+ }
+ TextArea {
+ id: dumpData
+ anchors.top: contractData.bottom
+ anchors.left: parent.left
+ anchors.right: parent.right
+ anchors.bottom: parent.bottom
+ height: 300
+ }
+ }
+ property var transactionModel: ListModel {
+ id: transactionModel
+ }
+ property var singleBlock: ListModel {
+ id: singleBlock
+ }
+ function setDetails(bl){
+ singleBlock.set(0, bl)
+ popup.height = 300
+ transactionModel.clear()
+ if(bl.txs !== undefined){
+ for(var i = 0; i < bl.txs.count; i++) {
+ transactionModel.insert(0, bl.txs.get(i))
+ }
+ if(bl.txs.count > 0 && bl.txs.get(0).data){
+ popup.showContractData(bl.txs.get(0))
+ }
+ }
+ txView.forceActiveFocus()
+ dumpData.text = bl.raw;
+ }
+ }
+}
diff --git a/cmd/mist/assets/qml/views/history.qml b/cmd/mist/assets/qml/views/history.qml
new file mode 100644
index 000000000..c72f8f3ae
--- /dev/null
+++ b/cmd/mist/assets/qml/views/history.qml
@@ -0,0 +1,51 @@
+import QtQuick 2.0
+import QtQuick.Controls 1.0;
+import QtQuick.Layouts 1.0;
+import QtQuick.Dialogs 1.0;
+import QtQuick.Window 2.1;
+import QtQuick.Controls.Styles 1.1
+import Ethereum 1.0
+
+Rectangle {
+ property var title: "Transactions"
+ property var menuItem
+
+
+ id: historyView
+ visible: false
+ anchors.fill: parent
+ objectName: "transactionView"
+
+ property var txModel: ListModel {
+ id: txModel
+ }
+ TableView {
+ id: txTableView
+ anchors.fill: parent
+ TableViewColumn{ role: "inout" ; title: "" ; width: 40 }
+ TableViewColumn{ role: "value" ; title: "Value" ; width: 100 }
+ TableViewColumn{ role: "address" ; title: "Address" ; width: 430 }
+ TableViewColumn{ role: "contract" ; title: "Contract" ; width: 100 }
+
+ model: txModel
+ }
+
+ function addTx(tx, inout) {
+ var isContract
+ if (tx.contract == true){
+ isContract = "Yes"
+ }else{
+ isContract = "No"
+ }
+
+
+ var address;
+ if(inout == "recv") {
+ address = tx.sender;
+ } else {
+ address = tx.address;
+ }
+
+ txModel.insert(0, {inout: inout, hash: tx.hash, address: address, value: tx.value, contract: isContract})
+ }
+}
diff --git a/cmd/mist/assets/qml/views/info.qml b/cmd/mist/assets/qml/views/info.qml
new file mode 100644
index 000000000..0187bba6d
--- /dev/null
+++ b/cmd/mist/assets/qml/views/info.qml
@@ -0,0 +1,143 @@
+import QtQuick 2.0
+import QtQuick.Controls 1.0;
+import QtQuick.Layouts 1.0;
+import QtQuick.Dialogs 1.0;
+import QtQuick.Window 2.1;
+import QtQuick.Controls.Styles 1.1
+import Ethereum 1.0
+
+Rectangle {
+ property var title: "Debug Info"
+ property var menuItem
+
+ objectName: "infoView"
+ visible: false
+ anchors.fill: parent
+
+ color: "#00000000"
+
+ Column {
+ id: info
+ spacing: 3
+ anchors.fill: parent
+ anchors.topMargin: 5
+ anchors.leftMargin: 5
+
+ Label {
+ id: addressLabel
+ text: "Address"
+ }
+ TextField {
+ text: eth.coinbase()
+ width: 500
+ }
+
+ TextArea {
+ objectName: "statsPane"
+ width: parent.width
+ height: 200
+ selectByMouse: true
+ readOnly: true
+ font.family: "Courier"
+ }
+ }
+
+ RowLayout {
+ id: logLayout
+ width: parent.width
+ height: 200
+ anchors.bottom: parent.bottom
+
+ TableView {
+ id: addressView
+ width: parent.width
+ height: 200
+ anchors {
+ left: parent.left
+ bottom: parent.bottom
+ top: parent.top
+ }
+ TableViewColumn{ role: "name"; title: "name" }
+ TableViewColumn{ role: "address"; title: "address"; width: 300}
+
+ property var addressModel: ListModel {
+ id: addressModel
+ }
+
+ model: addressModel
+ itemDelegate: Item {
+ Text {
+ anchors {
+ left: parent.left
+ right: parent.right
+ leftMargin: 10
+ verticalCenter: parent.verticalCenter
+ }
+ color: styleData.textColor
+ elide: styleData.elideMode
+ text: styleData.value
+ font.pixelSize: 11
+ MouseArea {
+ acceptedButtons: Qt.LeftButton | Qt.RightButton
+ propagateComposedEvents: true
+ anchors.fill: parent
+ onClicked: {
+ addressView.selection.clear()
+ addressView.selection.select(styleData.row)
+
+ if(mouse.button == Qt.RightButton) {
+ contextMenu.row = styleData.row;
+ contextMenu.popup()
+ }
+ }
+ }
+ }
+ }
+
+ Menu {
+ id: contextMenu
+ property var row;
+
+ MenuItem {
+ text: "Copy"
+ onTriggered: {
+ copyToClipboard(addressModel.get(this.row).address)
+ }
+ }
+ }
+ }
+ }
+
+ property var logModel: ListModel {
+ id: logModel
+ }
+
+ function addDebugMessage(message){
+ debuggerLog.append({value: message})
+ }
+
+ function addAddress(address) {
+ addressModel.append({name: address.name, address: address.address})
+ }
+
+ function clearAddress() {
+ addressModel.clear()
+ }
+
+ function addLog(str) {
+ // Remove first item once we've reached max log items
+ if(logModel.count > 250) {
+ logModel.remove(0)
+ }
+
+ if(str.len != 0) {
+ if(logView.flickableItem.atYEnd) {
+ logModel.append({description: str})
+ logView.positionViewAtRow(logView.rowCount - 1, ListView.Contain)
+ } else {
+ logModel.append({description: str})
+ }
+ }
+
+ }
+}
diff --git a/cmd/mist/assets/qml/views/jeffcoin/jeff.png b/cmd/mist/assets/qml/views/jeffcoin/jeff.png
new file mode 100644
index 000000000..2b9c6651a
--- /dev/null
+++ b/cmd/mist/assets/qml/views/jeffcoin/jeff.png
Binary files differ
diff --git a/cmd/mist/assets/qml/views/jeffcoin/jeffcoin.qml b/cmd/mist/assets/qml/views/jeffcoin/jeffcoin.qml
new file mode 100644
index 000000000..23502d334
--- /dev/null
+++ b/cmd/mist/assets/qml/views/jeffcoin/jeffcoin.qml
@@ -0,0 +1,190 @@
+import QtQuick 2.0
+import QtQuick.Controls 1.0;
+import QtQuick.Layouts 1.0;
+import QtQuick.Dialogs 1.0;
+import QtQuick.Window 2.1;
+import QtQuick.Controls.Styles 1.1
+
+Rectangle {
+ id: root
+ property var title: "JeffCoin"
+ property var iconSource: "./views/jeffcoin/jeff.png"
+ property var menuItem
+ property var filter
+ property var address: "fc0a9436890478bb9b1c6ed7455c2535366f4a99"
+
+ function insertTx(message, blockNumber) {
+ if(!message) return;
+
+ var from = message.from
+ var to = message.input.substr(24, 40)
+ var value = eth.fromNumber(message.input.substr(64, 64))
+
+ var me = eth.key().address;
+ if((to == me|| from == me) && message.input.length == 128) {
+ var to = eth.lookupName(to)
+ var from = eth.lookupName(from)
+ txModel.insert(0, {confirmations: blockNumber - message.number, from: from, to: to, value: value})
+ }
+ }
+
+ function setBalance() {
+ var jeffCoinAmount = eth.fromNumber(eth.storageAt(address, eth.key().address)) + " JΞF"
+ menuItem.secondaryTitle = jeffCoinAmount
+
+ balance.text = "<b>Balance</b>: " + jeffCoinAmount;
+ }
+
+ function onReady() {
+ setBalance()
+
+ filter = new ethx.watch({latest: -1, to: address})
+ filter.changed(function(messages) {
+ setBalance()
+
+ var blockNumber = eth.block(-1).number;
+ for(var i = 0; i < messages.length; i++) {
+ insertTx(messages.get(i), blockNumber);
+ }
+ });
+
+ var blockNumber = eth.block(-1).number;
+ var msgs = filter.messages()
+ for(var i = msgs.length-1; i >= 0; i--) {
+ var message = JSON.parse(msgs.getAsJson(i))
+
+ insertTx(message, blockNumber)
+ }
+
+ var chainChanged = ethx.watch("chain")
+ chainChanged.changed(function() {
+ for(var i = 0; i < txModel.count; i++) {
+ var entry = txModel.get(i);
+ entry.confirmations++;
+ }
+ });
+ }
+
+ function onDestroy() {
+ filter.uninstall()
+ }
+
+ ColumnLayout {
+ spacing: 10
+ y: 40
+ anchors.fill: parent
+
+ Text {
+ id: balance
+ text: "<b>Balance</b>: " + eth.fromNumber(eth.storageAt(address, eth.key().address)) + " JΞF"
+ font.pixelSize: 24
+ anchors {
+ horizontalCenter: parent.horizontalCenter
+ top: parent.top
+ topMargin: 20
+ }
+ }
+
+ Rectangle {
+ id: newTxPane
+ color: "#ececec"
+ border.color: "#cccccc"
+ border.width: 1
+ anchors {
+ top: balance.bottom
+ topMargin: 10
+ left: parent.left
+ leftMargin: 5
+ right: parent.right
+ rightMargin: 5
+ }
+ height: 100
+
+ RowLayout {
+ id: amountFields
+ spacing: 10
+ anchors {
+ top: parent.top
+ topMargin: 20
+ left: parent.left
+ leftMargin: 20
+ }
+
+ Text {
+ text: "JΞF "
+ }
+
+ // There's something off with the row layout where textfields won't listen to the width setting
+ Rectangle {
+ width: 50
+ height: 20
+ TextField {
+ id: txValue
+ width: parent.width
+ placeholderText: "0.00"
+ }
+ }
+ }
+
+ RowLayout {
+ id: toFields
+ spacing: 10
+ anchors {
+ top: amountFields.bottom
+ topMargin: 5
+ left: parent.left
+ leftMargin: 20
+ }
+
+ Text {
+ text: "To"
+ }
+
+ Rectangle {
+ width: 200
+ height: 20
+ TextField {
+ id: txTo
+ width: parent.width
+ placeholderText: "Address or name"
+ }
+ }
+
+ Button {
+ text: "Send"
+ onClicked: {
+ var lookup = eth.lookupAddress(address)
+ if(lookup.length == 0)
+ lookup = address
+
+ eth.transact({from: eth.key().privateKey, to:lookup, gas: "9000", gasPrice: "10000000000000", data: ["0x"+txTo.text, txValue.text]})
+ }
+ }
+ }
+ }
+
+ Rectangle {
+ anchors {
+ left: parent.left
+ right: parent.right
+ top: newTxPane.bottom
+ topMargin: 10
+ bottom: parent.bottom
+ }
+ TableView {
+ id: txTableView
+ anchors.fill : parent
+ TableViewColumn{ role: "value" ; title: "Amount" ; width: 100 }
+ TableViewColumn{ role: "from" ; title: "From" ; width: 280 }
+ TableViewColumn{ role: "to" ; title: "To" ; width: 280 }
+ TableViewColumn{ role: "confirmations" ; title: "Confirmations" ; width: 100 }
+
+ model: ListModel {
+ id: txModel
+ Component.onCompleted: {
+ }
+ }
+ }
+ }
+ }
+}
diff --git a/cmd/mist/assets/qml/views/miner.qml b/cmd/mist/assets/qml/views/miner.qml
new file mode 100644
index 000000000..ff2bf85ca
--- /dev/null
+++ b/cmd/mist/assets/qml/views/miner.qml
@@ -0,0 +1,283 @@
+import QtQuick 2.0
+import QtQuick.Controls 1.0;
+import QtQuick.Layouts 1.0;
+import QtQuick.Dialogs 1.0;
+import QtQuick.Window 2.1;
+import QtQuick.Controls.Styles 1.1
+import Ethereum 1.0
+
+Rectangle {
+ id: root
+ property var title: "Miner"
+ property var iconSource: "../mining-icon.png"
+ property var menuItem
+
+ color: "#00000000"
+
+ Label {
+ visible: false
+ id: lastBlockLabel
+ objectName: "lastBlockLabel"
+ text: "---"
+ onTextChanged: {
+ //menuItem.secondaryTitle = text
+ }
+ }
+
+ ColumnLayout {
+ spacing: 10
+ anchors.fill: parent
+
+ Rectangle {
+ id: mainPane
+ color: "#00000000"
+ anchors {
+ top: parent.top
+ bottom: localTxPane.top
+ left: parent.left
+ right: parent.right
+ }
+
+ Rectangle {
+ id: menu
+ height: 25
+ anchors {
+ left: parent.left
+ }
+
+ RowLayout {
+ id: tools
+ anchors {
+ left: parent.left
+ right: parent.right
+ }
+
+ Button {
+ text: "Start"
+ onClicked: {
+ // eth.setGasPrice(minGasPrice.text || "10000000000000");
+ // eth.setExtra(blockExtra.text)
+ if (eth.toggleMining()) {
+ this.text = "Stop";
+ } else {
+ this.text = "Start";
+ }
+ }
+ }
+
+ // Rectangle {
+ // id: minGasPriceRect
+ // anchors.top: parent.top
+ // anchors.topMargin: 2
+ // width: 200
+ // TextField {
+ // id: minGasPrice
+ // placeholderText: "Min Gas: 10000000000000"
+ // width: 200
+ // validator: RegExpValidator { regExp: /\d*/ }
+ // }
+ // }
+
+ // Rectangle {
+ // width: 300
+ // anchors {
+ // left: minGasPriceRect.right
+ // leftMargin: 5
+ // top: parent.top
+ // topMargin: 2
+ // }
+
+ // TextField {
+ // id: blockExtra
+ // placeholderText: "Extra"
+ // width: parent.width
+ // maximumLength: 1024
+ // }
+ // }
+ }
+ }
+
+ Column {
+ anchors {
+ left: parent.left
+ right: parent.right
+ top: menu.bottom
+ topMargin: 5
+ }
+
+ Text {
+ text: "<b>Merged mining options</b>"
+ }
+
+ TableView {
+ id: mergedMiningTable
+ height: 300
+ anchors {
+ left: parent.left
+ right: parent.right
+ }
+ Component {
+ id: checkBoxDelegate
+
+ Item {
+ id: test
+ CheckBox {
+ anchors.fill: parent
+ checked: styleData.value
+
+ onClicked: {
+ var model = mergedMiningModel.get(styleData.row)
+
+ if (this.checked) {
+ model.id = txModel.createLocalTx(model.address, "0", "5000", "0", "")
+ } else {
+ txModel.removeWithId(model.id);
+ model.id = 0;
+ }
+ }
+ }
+ }
+ }
+ TableViewColumn{ role: "checked" ; title: "" ; width: 40 ; delegate: checkBoxDelegate }
+ TableViewColumn{ role: "name" ; title: "Name" ; width: 480 }
+ model: ListModel {
+ objectName: "mergedMiningModel"
+ id: mergedMiningModel
+ function addMergedMiningOption(model) {
+ this.append(model);
+ }
+ }
+ Component.onCompleted: {
+ /*
+ // XXX Temp. replace with above eventually
+ var tmpItems = ["JEVCoin", "Some coin", "Other coin", "Etc coin"];
+ var address = "e6716f9544a56c530d868e4bfbacb172315bdead";
+ for (var i = 0; i < tmpItems.length; i++) {
+ mergedMiningModel.append({checked: false, name: tmpItems[i], address: address, id: 0, itemId: i});
+ }
+ */
+ }
+ }
+ }
+ }
+
+ Rectangle {
+ id: localTxPane
+ color: "#ececec"
+ border.color: "#cccccc"
+ border.width: 1
+ anchors {
+ left: parent.left
+ right: parent.right
+ bottom: parent.bottom
+ }
+ height: 300
+
+ ColumnLayout {
+ spacing: 10
+ anchors.fill: parent
+ RowLayout {
+ id: newLocalTx
+ anchors {
+ left: parent.left
+ leftMargin: 5
+ top: parent.top
+ topMargin: 5
+ bottomMargin: 5
+ }
+
+ Text {
+ text: "Local tx"
+ }
+
+ Rectangle {
+ width: 250
+ color: "#00000000"
+ anchors.top: parent.top
+ anchors.topMargin: 2
+
+ TextField {
+ id: to
+ placeholderText: "To"
+ width: 250
+ validator: RegExpValidator { regExp: /[abcdefABCDEF1234567890]*/ }
+ }
+ }
+ TextField {
+ property var defaultGas: "5000"
+ id: gas
+ placeholderText: "Gas"
+ text: defaultGas
+ validator: RegExpValidator { regExp: /\d*/ }
+ }
+ TextField {
+ id: gasPrice
+ placeholderText: "Price"
+ validator: RegExpValidator { regExp: /\d*/ }
+ }
+ TextField {
+ id: value
+ placeholderText: "Amount"
+ text: "0"
+ validator: RegExpValidator { regExp: /\d*/ }
+ }
+ TextField {
+ id: data
+ placeholderText: "Data"
+ validator: RegExpValidator { regExp: /[abcdefABCDEF1234567890]*/ }
+ }
+ Button {
+ text: "Create"
+ onClicked: {
+ if (to.text.length == 40 && gasPrice.text.length != 0 && value.text.length != 0 && gas.text.length != 0) {
+ txModel.createLocalTx(to.text, gasPrice.text, gas.text, value.text, data.text);
+
+ to.text = ""; gasPrice.text = "";
+ gas.text = gas.defaultGas;
+ value.text = "0"
+ }
+ }
+ }
+ }
+
+ TableView {
+ id: txTableView
+ anchors {
+ top: newLocalTx.bottom
+ topMargin: 5
+ left: parent.left
+ right: parent.right
+ bottom: parent.bottom
+ }
+ TableViewColumn{ role: "to" ; title: "To" ; width: 480 }
+ TableViewColumn{ role: "gas" ; title: "Gas" ; width: 100 }
+ TableViewColumn{ role: "gasPrice" ; title: "Gas Price" ; width: 100 }
+ TableViewColumn{ role: "value" ; title: "Amount" ; width: 100 }
+ TableViewColumn{ role: "data" ; title: "Data" ; width: 100 }
+
+ model: ListModel {
+ id: txModel
+ Component.onCompleted: {
+ }
+ function removeWithId(id) {
+ for (var i = 0; i < this.count; i++) {
+ if (txModel.get(i).id == id) {
+ this.remove(i);
+ eth.removeLocalTransaction(id)
+ break;
+ }
+ }
+ }
+
+ function createLocalTx(to, gasPrice, gas, value, data) {
+ var id = eth.addLocalTransaction(to, data, gas, gasPrice, value)
+ txModel.insert(0, {to: to, gas: gas, gasPrice: gasPrice, value: value, data: data, id: id});
+
+ return id
+ }
+ }
+ }
+ }
+ }
+ }
+}
diff --git a/cmd/mist/assets/qml/views/network-health/205f39107b64acf34cb35d7edb57f47893187a12.js b/cmd/mist/assets/qml/views/network-health/205f39107b64acf34cb35d7edb57f47893187a12.js
new file mode 100644
index 000000000..a1f645ca5
--- /dev/null
+++ b/cmd/mist/assets/qml/views/network-health/205f39107b64acf34cb35d7edb57f47893187a12.js
@@ -0,0 +1,176 @@
+!function(){var n,t;(function(){t={}}).call(this),function(){(function(){var n=this,r=n._,e={},u=Array.prototype,i=Object.prototype,a=Function.prototype,o=u.push,c=u.slice,l=u.concat,f=i.toString,s=i.hasOwnProperty,p=u.forEach,v=u.map,h=u.reduce,d=u.reduceRight,g=u.filter,m=u.every,y=u.some,b=u.indexOf,_=u.lastIndexOf,w=Array.isArray,x=Object.keys,j=a.bind,A=function(n){return n instanceof A?n:this instanceof A?void(this._wrapped=n):new A(n)};"undefined"!=typeof t?("undefined"!=typeof module&&module.exports&&(t=module.exports=A),t._=A):n._=A,A.VERSION="1.5.2";var k=function(n){return"[object Arguments]"===f.call(n)};k(arguments)||(k=function(n){return!(!n||!s.call(n,"callee")||"function"!=typeof n.callee)});var O=function(n){return n.length===+n.length&&(k(n)||n.constructor!==Object)},E=A.each=A.forEach=function(n,t,r){if(null!=n)if(p&&n.forEach===p)n.forEach(t,r);else if(O(n)){for(var u=0,i=n.length;i>u;u++)if(t.call(r,n[u],u,n)===e)return}else for(var a=A.keys(n),u=0,i=a.length;i>u;u++)if(t.call(r,n[a[u]],a[u],n)===e)return};A.map=A.collect=function(n,t,r){var e=[];return null==n?e:v&&n.map===v?n.map(t,r):(E(n,function(n,u,i){e.push(t.call(r,n,u,i))}),e)};var F="Reduce of empty array with no initial value";A.reduce=A.foldl=A.inject=function(n,t,r,e){var u=arguments.length>2;if(null==n&&(n=[]),h&&n.reduce===h)return e&&(t=A.bind(t,e)),u?n.reduce(t,r):n.reduce(t);if(E(n,function(n,i,a){u?r=t.call(e,r,n,i,a):(r=n,u=!0)}),!u)throw new TypeError(F);return r},A.reduceRight=A.foldr=function(n,t,r,e){var u=arguments.length>2;if(null==n&&(n=[]),d&&n.reduceRight===d)return e&&(t=A.bind(t,e)),u?n.reduceRight(t,r):n.reduceRight(t);var i=n.length;if(!O(n)){var a=A.keys(n);i=a.length}if(E(n,function(o,c,l){c=a?a[--i]:--i,u?r=t.call(e,r,n[c],c,l):(r=n[c],u=!0)}),!u)throw new TypeError(F);return r},A.find=A.detect=function(n,t,r){var e;return M(n,function(n,u,i){return t.call(r,n,u,i)?(e=n,!0):void 0}),e},A.filter=A.select=function(n,t,r){var e=[];return null==n?e:g&&n.filter===g?n.filter(t,r):(E(n,function(n,u,i){t.call(r,n,u,i)&&e.push(n)}),e)},A.reject=function(n,t,r){return A.filter(n,function(n,e,u){return!t.call(r,n,e,u)},r)},A.every=A.all=function(n,t,r){t||(t=A.identity);var u=!0;return null==n?u:m&&n.every===m?n.every(t,r):(E(n,function(n,i,a){return(u=u&&t.call(r,n,i,a))?void 0:e}),!!u)};var M=A.some=A.any=function(n,t,r){t||(t=A.identity);var u=!1;return null==n?u:y&&n.some===y?n.some(t,r):(E(n,function(n,i,a){return u||(u=t.call(r,n,i,a))?e:void 0}),!!u)};A.contains=A.include=function(n,t){return null==n?!1:b&&n.indexOf===b?-1!=n.indexOf(t):M(n,function(n){return n===t})},A.invoke=function(n,t){var r=c.call(arguments,2),e=A.isFunction(t);return A.map(n,function(n){return(e?t:n[t]).apply(n,r)})},A.pluck=function(n,t){return A.map(n,function(n){return n[t]})},A.where=function(n,t,r){return A.isEmpty(t)?r?void 0:[]:A[r?"find":"filter"](n,function(n){for(var r in t)if(t[r]!==n[r])return!1;return!0})},A.findWhere=function(n,t){return A.where(n,t,!0)},A.max=function(n,t,r){if(!t&&A.isArray(n)&&n[0]===+n[0]&&n.length<65535)return Math.max.apply(Math,n);if(!t&&A.isEmpty(n))return-1/0;var e={computed:-1/0,value:-1/0};return E(n,function(n,u,i){var a=t?t.call(r,n,u,i):n;a>e.computed&&(e={value:n,computed:a})}),e.value},A.min=function(n,t,r){if(!t&&A.isArray(n)&&n[0]===+n[0]&&n.length<65535)return Math.min.apply(Math,n);if(!t&&A.isEmpty(n))return 1/0;var e={computed:1/0,value:1/0};return E(n,function(n,u,i){var a=t?t.call(r,n,u,i):n;a<e.computed&&(e={value:n,computed:a})}),e.value},A.shuffle=function(n){var t,r=0,e=[];return E(n,function(n){t=A.random(r++),e[r-1]=e[t],e[t]=n}),e},A.sample=function(n,t,r){return arguments.length<2||r?n[A.random(n.length-1)]:A.shuffle(n).slice(0,Math.max(0,t))};var R=function(n){return A.isFunction(n)?n:function(t){return t[n]}};A.sortBy=function(n,t,r){var e=R(t);return A.pluck(A.map(n,function(n,t,u){return{value:n,index:t,criteria:e.call(r,n,t,u)}}).sort(function(n,t){var r=n.criteria,e=t.criteria;if(r!==e){if(r>e||void 0===r)return 1;if(e>r||void 0===e)return-1}return n.index-t.index}),"value")};var S=function(n){return function(t,r,e){var u={},i=null==r?A.identity:R(r);return E(t,function(r,a){var o=i.call(e,r,a,t);n(u,o,r)}),u}};A.groupBy=S(function(n,t,r){(A.has(n,t)?n[t]:n[t]=[]).push(r)}),A.indexBy=S(function(n,t,r){n[t]=r}),A.countBy=S(function(n,t){A.has(n,t)?n[t]++:n[t]=1}),A.sortedIndex=function(n,t,r,e){r=null==r?A.identity:R(r);for(var u=r.call(e,t),i=0,a=n.length;a>i;){var o=i+a>>>1;r.call(e,n[o])<u?i=o+1:a=o}return i},A.toArray=function(n){return n?A.isArray(n)?c.call(n):O(n)?A.map(n,A.identity):A.values(n):[]},A.size=function(n){return null==n?0:O(n)?n.length:A.keys(n).length},A.first=A.head=A.take=function(n,t,r){return null==n?void 0:null==t||r?n[0]:c.call(n,0,t)},A.initial=function(n,t,r){return c.call(n,0,n.length-(null==t||r?1:t))},A.last=function(n,t,r){return null==n?void 0:null==t||r?n[n.length-1]:c.call(n,Math.max(n.length-t,0))},A.rest=A.tail=A.drop=function(n,t,r){return c.call(n,null==t||r?1:t)},A.compact=function(n){return A.filter(n,A.identity)};var I=function(n,t,r){return t&&A.every(n,A.isArray)?l.apply(r,n):(E(n,function(n){A.isArray(n)||A.isArguments(n)?t?o.apply(r,n):I(n,t,r):r.push(n)}),r)};A.flatten=function(n,t){return I(n,t,[])},A.without=function(n){return A.difference(n,c.call(arguments,1))},A.uniq=A.unique=function(n,t,r,e){A.isFunction(t)&&(e=r,r=t,t=!1);var u=r?A.map(n,r,e):n,i=[],a=[];return E(u,function(r,e){(t?e&&a[a.length-1]===r:A.contains(a,r))||(a.push(r),i.push(n[e]))}),i},A.union=function(){return A.uniq(A.flatten(arguments,!0))},A.intersection=function(n){var t=c.call(arguments,1);return A.filter(A.uniq(n),function(n){return A.every(t,function(t){return A.indexOf(t,n)>=0})})},A.difference=function(n){var t=l.apply(u,c.call(arguments,1));return A.filter(n,function(n){return!A.contains(t,n)})},A.zip=function(){for(var n=A.max(A.pluck(arguments,"length").concat(0)),t=new Array(n),r=0;n>r;r++)t[r]=A.pluck(arguments,""+r);return t},A.object=function(n,t){if(null==n)return{};for(var r={},e=0,u=n.length;u>e;e++)t?r[n[e]]=t[e]:r[n[e][0]]=n[e][1];return r},A.indexOf=function(n,t,r){if(null==n)return-1;var e=0,u=n.length;if(r){if("number"!=typeof r)return e=A.sortedIndex(n,t),n[e]===t?e:-1;e=0>r?Math.max(0,u+r):r}if(b&&n.indexOf===b)return n.indexOf(t,r);for(;u>e;e++)if(n[e]===t)return e;return-1},A.lastIndexOf=function(n,t,r){if(null==n)return-1;var e=null!=r;if(_&&n.lastIndexOf===_)return e?n.lastIndexOf(t,r):n.lastIndexOf(t);for(var u=e?r:n.length;u--;)if(n[u]===t)return u;return-1},A.range=function(n,t,r){arguments.length<=1&&(t=n||0,n=0),r=arguments[2]||1;for(var e=Math.max(Math.ceil((t-n)/r),0),u=0,i=new Array(e);e>u;)i[u++]=n,n+=r;return i};var T=function(){};A.bind=function(n,t){var r,e;if(j&&n.bind===j)return j.apply(n,c.call(arguments,1));if(!A.isFunction(n))throw new TypeError;return r=c.call(arguments,2),e=function(){if(!(this instanceof e))return n.apply(t,r.concat(c.call(arguments)));T.prototype=n.prototype;var u=new T;T.prototype=null;var i=n.apply(u,r.concat(c.call(arguments)));return Object(i)===i?i:u}},A.partial=function(n){var t=c.call(arguments,1);return function(){return n.apply(this,t.concat(c.call(arguments)))}},A.bindAll=function(n){var t=c.call(arguments,1);if(0===t.length)throw new Error("bindAll must be passed function names");return E(t,function(t){n[t]=A.bind(n[t],n)}),n},A.memoize=function(n,t){var r={};return t||(t=A.identity),function(){var e=t.apply(this,arguments);return A.has(r,e)?r[e]:r[e]=n.apply(this,arguments)}},A.delay=function(n,t){var r=c.call(arguments,2);return setTimeout(function(){return n.apply(null,r)},t)},A.defer=function(n){return A.delay.apply(A,[n,1].concat(c.call(arguments,1)))},A.throttle=function(n,t,r){var e,u,i,a=null,o=0;r||(r={});var c=function(){o=r.leading===!1?0:new Date,a=null,i=n.apply(e,u)};return function(){var l=new Date;o||r.leading!==!1||(o=l);var f=t-(l-o);return e=this,u=arguments,0>=f?(clearTimeout(a),a=null,o=l,i=n.apply(e,u)):a||r.trailing===!1||(a=setTimeout(c,f)),i}},A.debounce=function(n,t,r){var e,u,i,a,o;return function(){i=this,u=arguments,a=new Date;var c=function(){var l=new Date-a;t>l?e=setTimeout(c,t-l):(e=null,r||(o=n.apply(i,u)))},l=r&&!e;return e||(e=setTimeout(c,t)),l&&(o=n.apply(i,u)),o}},A.once=function(n){var t=!1,r;return function(){return t?r:(t=!0,r=n.apply(this,arguments),n=null,r)}},A.wrap=function(n,t){return function(){var r=[n];return o.apply(r,arguments),t.apply(this,r)}},A.compose=function(){var n=arguments;return function(){for(var t=arguments,r=n.length-1;r>=0;r--)t=[n[r].apply(this,t)];return t[0]}},A.after=function(n,t){return function(){return--n<1?t.apply(this,arguments):void 0}},A.keys=x||function(n){if(n!==Object(n))throw new TypeError("Invalid object");var t=[];for(var r in n)A.has(n,r)&&t.push(r);return t},A.values=function(n){for(var t=A.keys(n),r=t.length,e=new Array(r),u=0;r>u;u++)e[u]=n[t[u]];return e},A.pairs=function(n){for(var t=A.keys(n),r=t.length,e=new Array(r),u=0;r>u;u++)e[u]=[t[u],n[t[u]]];return e},A.invert=function(n){for(var t={},r=A.keys(n),e=0,u=r.length;u>e;e++)t[n[r[e]]]=r[e];return t},A.functions=A.methods=function(n){var t=[];for(var r in n)A.isFunction(n[r])&&t.push(r);return t.sort()},A.extend=function(n){return E(c.call(arguments,1),function(t){if(t)for(var r in t)n[r]=t[r]}),n},A.pick=function(n){var t={},r=l.apply(u,c.call(arguments,1));return E(r,function(r){r in n&&(t[r]=n[r])}),t},A.omit=function(n){var t={},r=l.apply(u,c.call(arguments,1));for(var e in n)A.contains(r,e)||(t[e]=n[e]);return t},A.defaults=function(n){return E(c.call(arguments,1),function(t){if(t)for(var r in t)void 0===n[r]&&(n[r]=t[r])}),n},A.clone=function(n){return A.isObject(n)?A.isArray(n)?n.slice():A.extend({},n):n},A.tap=function(n,t){return t(n),n};var N=function(n,t,r,e){if(n===t)return 0!==n||1/n==1/t;if(null==n||null==t)return n===t;n instanceof A&&(n=n._wrapped),t instanceof A&&(t=t._wrapped);var u=f.call(n);if(u!=f.call(t))return!1;switch(u){case"[object String]":return n==String(t);case"[object Number]":return n!=+n?t!=+t:0==n?1/n==1/t:n==+t;case"[object Date]":case"[object Boolean]":return+n==+t;case"[object RegExp]":return n.source==t.source&&n.global==t.global&&n.multiline==t.multiline&&n.ignoreCase==t.ignoreCase}if("object"!=typeof n||"object"!=typeof t)return!1;for(var i=r.length;i--;)if(r[i]==n)return e[i]==t;var a=n.constructor,o=t.constructor;if(a!==o&&!(A.isFunction(a)&&a instanceof a&&A.isFunction(o)&&o instanceof o))return!1;r.push(n),e.push(t);var c=0,l=!0;if("[object Array]"==u){if(c=n.length,l=c==t.length)for(;c--&&(l=N(n[c],t[c],r,e)););}else{for(var s in n)if(A.has(n,s)&&(c++,!(l=A.has(t,s)&&N(n[s],t[s],r,e))))break;if(l){for(s in t)if(A.has(t,s)&&!c--)break;l=!c}}return r.pop(),e.pop(),l};A.isEqual=function(n,t){return N(n,t,[],[])},A.isEmpty=function(n){if(null==n)return!0;if(A.isArray(n)||A.isString(n))return 0===n.length;for(var t in n)if(A.has(n,t))return!1;return!0},A.isElement=function(n){return!(!n||1!==n.nodeType)},A.isArray=w||function(n){return"[object Array]"==f.call(n)},A.isObject=function(n){return n===Object(n)},E(["Arguments","Function","String","Number","Date","RegExp"],function(n){A["is"+n]=function(t){return f.call(t)=="[object "+n+"]"}}),A.isArguments(arguments)||(A.isArguments=function(n){return!(!n||!A.has(n,"callee"))}),"function"!=typeof/./&&(A.isFunction=function(n){return"function"==typeof n}),A.isFinite=function(n){return isFinite(n)&&!isNaN(parseFloat(n))},A.isNaN=function(n){return A.isNumber(n)&&n!=+n},A.isBoolean=function(n){return n===!0||n===!1||"[object Boolean]"==f.call(n)},A.isNull=function(n){return null===n},A.isUndefined=function(n){return void 0===n},A.has=function(n,t){return s.call(n,t)},A.noConflict=function(){return n._=r,this},A.identity=function(n){return n},A.times=function(n,t,r){for(var e=Array(Math.max(0,n)),u=0;n>u;u++)e[u]=t.call(r,u);return e},A.random=function(n,t){return null==t&&(t=n,n=0),n+Math.floor(Math.random()*(t-n+1))};var q={escape:{"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#x27;"}};q.unescape=A.invert(q.escape);var B={escape:new RegExp("["+A.keys(q.escape).join("")+"]","g"),unescape:new RegExp("("+A.keys(q.unescape).join("|")+")","g")};A.each(["escape","unescape"],function(n){A[n]=function(t){return null==t?"":(""+t).replace(B[n],function(t){return q[n][t]})}}),A.result=function(n,t){if(null==n)return void 0;var r=n[t];return A.isFunction(r)?r.call(n):r},A.mixin=function(n){E(A.functions(n),function(t){var r=A[t]=n[t];A.prototype[t]=function(){var n=[this._wrapped];return o.apply(n,arguments),U.call(this,r.apply(A,n))}})};var D=0;A.uniqueId=function(n){var t=++D+"";return n?n+t:t},A.templateSettings={evaluate:/<%([\s\S]+?)%>/g,interpolate:/<%=([\s\S]+?)%>/g,escape:/<%-([\s\S]+?)%>/g};var P=/(.)^/,z={"'":"'","\\":"\\","\r":"r","\n":"n"," ":"t","\u2028":"u2028","\u2029":"u2029"},C=/\\|'|\r|\n|\t|\u2028|\u2029/g;A.template=function(n,t,r){var e;r=A.defaults({},r,A.templateSettings);var u=new RegExp([(r.escape||P).source,(r.interpolate||P).source,(r.evaluate||P).source].join("|")+"|$","g"),i=0,a="__p+='";n.replace(u,function(t,r,e,u,o){return a+=n.slice(i,o).replace(C,function(n){return"\\"+z[n]}),r&&(a+="'+\n((__t=("+r+"))==null?'':_.escape(__t))+\n'"),e&&(a+="'+\n((__t=("+e+"))==null?'':__t)+\n'"),u&&(a+="';\n"+u+"\n__p+='"),i=o+t.length,t}),a+="';\n",r.variable||(a="with(obj||{}){\n"+a+"}\n"),a="var __t,__p='',__j=Array.prototype.join,print=function(){__p+=__j.call(arguments,'');};\n"+a+"return __p;\n";try{e=new Function(r.variable||"obj","_",a)}catch(o){throw o.source=a,o}if(t)return e(t,A);var c=function(n){return e.call(this,n,A)};return c.source="function("+(r.variable||"obj")+"){\n"+a+"}",c},A.chain=function(n){return A(n).chain()};var U=function(n){return this._chain?A(n).chain():n};A.mixin(A),E(["pop","push","reverse","shift","sort","splice","unshift"],function(n){var t=u[n];A.prototype[n]=function(){var r=this._wrapped;return t.apply(r,arguments),"shift"!=n&&"splice"!=n||0!==r.length||delete r[0],U.call(this,r)}}),E(["concat","join","slice"],function(n){var t=u[n];A.prototype[n]=function(){return U.call(this,t.apply(this._wrapped,arguments))}}),A.extend(A.prototype,{chain:function(){return this._chain=!0,this},value:function(){return this._wrapped}})}).call(this)}.call(this),function(){n=t._}.call(this),"undefined"==typeof Package&&(Package={}),Package.underscore={_:n}}();
+
+!function(){var t=Package.underscore._,e;(function(){e={isClient:!0,isServer:!1},"object"==typeof __meteor_runtime_config__&&__meteor_runtime_config__.PUBLIC_SETTINGS&&(e.settings={"public":__meteor_runtime_config__.PUBLIC_SETTINGS})}).call(this),function(){function n(t){return t?e._debug("Exception in callback of async function",t.stack?t.stack:t):void 0}if(e.isServer)var r=Npm.require("fibers/future");"object"==typeof __meteor_runtime_config__&&__meteor_runtime_config__.meteorRelease&&(e.release=__meteor_runtime_config__.meteorRelease),t.extend(e,{_get:function(t){for(var e=1;e<arguments.length;e++){if(!(arguments[e]in t))return void 0;t=t[arguments[e]]}return t},_ensure:function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];n in t||(t[n]={}),t=t[n]}return t},_delete:function(t){for(var e=[t],n=!0,r=1;r<arguments.length-1;r++){var o=arguments[r];if(!(o in t)){n=!1;break}if(t=t[o],"object"!=typeof t)break;e.push(t)}for(var r=e.length-1;r>=0;r--){var o=arguments[r+1];if(n)n=!1;else for(var i in e[r][o])return;delete e[r][o]}},wrapAsync:function(o,i){return function(){for(var a=i||this,u=t.toArray(arguments),s,c=u.length-1;c>=0;--c){var l=u[c],f=typeof l;if("undefined"!==f){"function"===f&&(s=l);break}}if(!s){if(e.isClient)s=n;else{var _=new r;s=_.resolver()}++c}u[c]=e.bindEnvironment(s);var p=o.apply(a,u);return _?_.wait():p}},_inherits:function(e,n){for(var r in n)t.has(n,r)&&(e[r]=n[r]);var o=function(){this.constructor=e};return o.prototype=n.prototype,e.prototype=new o,e.__super__=n.prototype,e}});var o=!1;e._wrapAsync=function(t,n){return o||(e._debug("Meteor._wrapAsync has been renamed to Meteor.wrapAsync"),o=!0),e.wrapAsync.apply(e,arguments)}}.call(this),function(){"use strict";function t(){if(o.setImmediate){var t=function(t){o.setImmediate(t)};return t.implementation="setImmediate",t}return null}function n(){function t(t,e){return"string"==typeof t&&t.substring(0,e.length)===e}function e(e){if(e.source===o&&t(e.data,u)){var n=e.data.substring(u.length);try{a[n]&&a[n]()}finally{delete a[n]}}}if(!o.postMessage||o.importScripts)return null;var n=!0,r=o.onmessage;if(o.onmessage=function(){n=!1},o.postMessage("","*"),o.onmessage=r,!n)return null;var i=0,a={},u="Meteor._setImmediate."+Math.random()+".";o.addEventListener?o.addEventListener("message",e,!1):o.attachEvent("onmessage",e);var s=function(t){++i,a[i]=t,o.postMessage(u+i,"*")};return s.implementation="postMessage",s}function r(){var t=function(t){o.setTimeout(t,0)};return t.implementation="setTimeout",t}var o=this;e._setImmediate=t()||n()||r()}.call(this),function(){var n=function(t){if(Package.ddp){var e=Package.ddp.DDP._CurrentInvocation;if(e.get()&&e.get().isSimulation)throw new Error("Can't set timers inside simulations");return function(){e.withValue(null,t)}}return t},r=function(t,r){return e.bindEnvironment(n(r),t)};t.extend(e,{setTimeout:function(t,e){return setTimeout(r("setTimeout callback",t),e)},setInterval:function(t,e){return setInterval(r("setInterval callback",t),e)},clearInterval:function(t){return clearInterval(t)},clearTimeout:function(t){return clearTimeout(t)},defer:function(t){e._setImmediate(r("defer callback",t))}})}.call(this),function(){e.makeErrorType=function(t,n){var r=function(){var e=this;if(Error.captureStackTrace)Error.captureStackTrace(e,r);else{var o=new Error;o.__proto__=r.prototype,o instanceof r&&(e=o)}return n.apply(e,arguments),e.errorType=t,e};return e._inherits(r,Error),r},e.Error=e.makeErrorType("Meteor.Error",function(t,e,n){var r=this;r.error=t,r.reason=e,r.details=n,r.message=r.reason?r.reason+" ["+r.error+"]":"["+r.error+"]"}),e.Error.prototype.clone=function(){var t=this;return new e.Error(t.error,t.reason,t.details)}}.call(this),function(){e._noYieldsAllowed=function(t){return t()},e._SynchronousQueue=function(){var t=this;t._tasks=[],t._running=!1,t._runTimeout=null},t.extend(e._SynchronousQueue.prototype,{runTask:function(n){var r=this;if(!r.safeToRunTask())throw new Error("Could not synchronously run a task from a running task");r._tasks.push(n);var o=r._tasks;r._tasks=[],r._running=!0,r._runTimeout&&(clearTimeout(r._runTimeout),r._runTimeout=null);try{for(;!t.isEmpty(o);){var i=o.shift();try{i()}catch(a){if(t.isEmpty(o))throw a;e._debug("Exception in queued task: "+a.stack)}}}finally{r._running=!1}},queueTask:function(e){var n=this;n._tasks.push(e),n._runTimeout||(n._runTimeout=setTimeout(t.bind(n.flush,n),0))},flush:function(){var t=this;t.runTask(function(){})},drain:function(){var e=this;if(e.safeToRunTask())for(;!t.isEmpty(e._tasks);)e.flush()},safeToRunTask:function(){var t=this;return!t._running}})}.call(this),function(){var t=[],n=!e.isCordova&&("loaded"===document.readyState||"complete"==document.readyState),r=1,o=function(){if(r--,!(r>0)){n=!0;var o=function(){if(e.isCordova&&(!cordova.plugins||!cordova.plugins.CordovaUpdate))return void e.setTimeout(o,20);for(;t.length;)t.shift()()};o()}};document.addEventListener?(document.addEventListener("DOMContentLoaded",o,!1),e.isCordova&&(r++,document.addEventListener("deviceready",o,!1)),window.addEventListener("load",o,!1)):(document.attachEvent("onreadystatechange",function(){"complete"===document.readyState&&o()}),window.attachEvent("load",o)),e.startup=function(r){var o=!document.addEventListener&&document.documentElement.doScroll;if(o&&window===top){try{o("left")}catch(i){return void setTimeout(function(){e.startup(r)},50)}r()}else n?r():t.push(r)}}.call(this),function(){var t=0;e._debug=function(){if(t)return void t--;if("undefined"!=typeof console&&"undefined"!=typeof console.log)if(0==arguments.length)console.log("");else if("function"==typeof console.log.apply){for(var e=!0,n=0;n<arguments.length;n++)"string"!=typeof arguments[n]&&(e=!1);e?console.log.apply(console,[Array.prototype.join.call(arguments," ")]):console.log.apply(console,arguments)}else if("function"==typeof Function.prototype.bind){var r=Function.prototype.bind.call(console.log,console);r.apply(console,arguments)}else Function.prototype.call.call(console.log,console,Array.prototype.slice.call(arguments))},e._suppress_log=function(e){t+=e}}.call(this),function(){var n=0,r=[];e.EnvironmentVariable=function(){this.slot=n++},t.extend(e.EnvironmentVariable.prototype,{get:function(){return r[this.slot]},getOrNullIfOutsideFiber:function(){return this.get()},withValue:function(t,e){var n=r[this.slot];try{r[this.slot]=t;var o=e()}finally{r[this.slot]=n}return o}}),e.bindEnvironment=function(n,o,i){var a=t.clone(r);if(!o||"string"==typeof o){var u=o||"callback of async function";o=function(t){e._debug("Exception in "+u+":",t&&t.stack||t)}}return function(){var e=r;try{r=a;var u=n.apply(i,t.toArray(arguments))}catch(s){o(s)}finally{r=e}return u}},e._nodeCodeMustBeInFiber=function(){}}.call(this),function(){e.absoluteUrl=function(n,r){r||"object"!=typeof n||(r=n,n=void 0),r=t.extend({},e.absoluteUrl.defaultOptions,r||{});var o=r.rootUrl;if(!o)throw new Error("Must pass options.rootUrl or set ROOT_URL in the server environment");return/^http[s]?:\/\//i.test(o)||(o="http://"+o),/\/$/.test(o)||(o+="/"),n&&(o+=n),r.secure&&/^http:/.test(o)&&!/http:\/\/localhost[:\/]/.test(o)&&!/http:\/\/127\.0\.0\.1[:\/]/.test(o)&&(o=o.replace(/^http:/,"https:")),r.replaceLocalhost&&(o=o.replace(/^http:\/\/localhost([:\/].*)/,"http://127.0.0.1$1")),o},e.absoluteUrl.defaultOptions={},"object"==typeof __meteor_runtime_config__&&__meteor_runtime_config__.ROOT_URL&&(e.absoluteUrl.defaultOptions.rootUrl=__meteor_runtime_config__.ROOT_URL),e._relativeToSiteRootUrl=function(t){return"object"==typeof __meteor_runtime_config__&&"/"===t.substr(0,1)&&(t=(__meteor_runtime_config__.ROOT_URL_PATH_PREFIX||"")+t),t}}.call(this),"undefined"==typeof Package&&(Package={}),Package.meteor={Meteor:e}}();
+
+!function(){var Meteor=Package.meteor.Meteor,JSON;(function(){window.JSON&&(JSON=window.JSON)}).call(this),function(){"object"!=typeof JSON&&(JSON={}),function(){"use strict";function f(t){return 10>t?"0"+t:t}function quote(t){return escapable.lastIndex=0,escapable.test(t)?'"'+t.replace(escapable,function(t){var e=meta[t];return"string"==typeof e?e:"\\u"+("0000"+t.charCodeAt(0).toString(16)).slice(-4)})+'"':'"'+t+'"'}function str(t,e){var n,r,o,f,u=gap,i,a=e[t];switch(a&&"object"==typeof a&&"function"==typeof a.toJSON&&(a=a.toJSON(t)),"function"==typeof rep&&(a=rep.call(e,t,a)),typeof a){case"string":return quote(a);case"number":return isFinite(a)?String(a):"null";case"boolean":case"null":return String(a);case"object":if(!a)return"null";if(gap+=indent,i=[],"[object Array]"===Object.prototype.toString.apply(a)){for(f=a.length,n=0;f>n;n+=1)i[n]=str(n,a)||"null";return o=0===i.length?"[]":gap?"[\n"+gap+i.join(",\n"+gap)+"\n"+u+"]":"["+i.join(",")+"]",gap=u,o}if(rep&&"object"==typeof rep)for(f=rep.length,n=0;f>n;n+=1)"string"==typeof rep[n]&&(r=rep[n],o=str(r,a),o&&i.push(quote(r)+(gap?": ":":")+o));else for(r in a)Object.prototype.hasOwnProperty.call(a,r)&&(o=str(r,a),o&&i.push(quote(r)+(gap?": ":":")+o));return o=0===i.length?"{}":gap?"{\n"+gap+i.join(",\n"+gap)+"\n"+u+"}":"{"+i.join(",")+"}",gap=u,o}}"function"!=typeof Date.prototype.toJSON&&(Date.prototype.toJSON=function(t){return isFinite(this.valueOf())?this.getUTCFullYear()+"-"+f(this.getUTCMonth()+1)+"-"+f(this.getUTCDate())+"T"+f(this.getUTCHours())+":"+f(this.getUTCMinutes())+":"+f(this.getUTCSeconds())+"Z":null},String.prototype.toJSON=Number.prototype.toJSON=Boolean.prototype.toJSON=function(t){return this.valueOf()});var cx=/[\u0000\u00ad\u0600-\u0604\u070f\u17b4\u17b5\u200c-\u200f\u2028-\u202f\u2060-\u206f\ufeff\ufff0-\uffff]/g,escapable=/[\\\"\x00-\x1f\x7f-\x9f\u00ad\u0600-\u0604\u070f\u17b4\u17b5\u200c-\u200f\u2028-\u202f\u2060-\u206f\ufeff\ufff0-\uffff]/g,gap,indent,meta={"\b":"\\b"," ":"\\t","\n":"\\n","\f":"\\f","\r":"\\r",'"':'\\"',"\\":"\\\\"},rep;"function"!=typeof JSON.stringify&&(JSON.stringify=function(t,e,n){var r;if(gap="",indent="","number"==typeof n)for(r=0;n>r;r+=1)indent+=" ";else"string"==typeof n&&(indent=n);if(rep=e,e&&"function"!=typeof e&&("object"!=typeof e||"number"!=typeof e.length))throw new Error("JSON.stringify");return str("",{"":t})}),"function"!=typeof JSON.parse&&(JSON.parse=function(text,reviver){function walk(t,e){var n,r,o=t[e];if(o&&"object"==typeof o)for(n in o)Object.prototype.hasOwnProperty.call(o,n)&&(r=walk(o,n),void 0!==r?o[n]=r:delete o[n]);return reviver.call(t,e,o)}var j;if(text=String(text),cx.lastIndex=0,cx.test(text)&&(text=text.replace(cx,function(t){return"\\u"+("0000"+t.charCodeAt(0).toString(16)).slice(-4)})),/^[\],:{}\s]*$/.test(text.replace(/\\(?:["\\\/bfnrt]|u[0-9a-fA-F]{4})/g,"@").replace(/"[^"\\\n\r]*"|true|false|null|-?\d+(?:\.\d*)?(?:[eE][+\-]?\d+)?/g,"]").replace(/(?:^|:|,)(?:\s*\[)+/g,"")))return j=eval("("+text+")"),"function"==typeof reviver?walk({"":j},""):j;throw new SyntaxError("JSON.parse")})}()}.call(this),"undefined"==typeof Package&&(Package={}),Package.json={JSON:JSON}}();
+
+!function(){var n=Package.meteor.Meteor,r;(function(){for(var n="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",e={},a=0;a<n.length;a++)e[n.charAt(a)]=a;r={},r.encode=function(n){if("string"==typeof n){var e=n;n=r.newBinary(e.length);for(var a=0;a<e.length;a++){var l=e.charCodeAt(a);if(l>255)throw new Error("Not ascii. Base64.encode can only take ascii strings.");n[a]=l}}for(var u=[],i=null,o=null,c=null,s=null,a=0;a<n.length;a++)switch(a%3){case 0:i=n[a]>>2&63,o=(3&n[a])<<4;break;case 1:o|=n[a]>>4&15,c=(15&n[a])<<2;break;case 2:c|=n[a]>>6&3,s=63&n[a],u.push(t(i)),u.push(t(o)),u.push(t(c)),u.push(t(s)),i=null,o=null,c=null,s=null}return null!=i&&(u.push(t(i)),u.push(t(o)),u.push(null==c?"=":t(c)),null==s&&u.push("=")),u.join("")};var t=function(r){return n.charAt(r)},l=function(n){return"="===n?-1:e[n]};r.newBinary=function(n){if("undefined"==typeof Uint8Array||"undefined"==typeof ArrayBuffer){for(var r=[],e=0;n>e;e++)r.push(0);return r.$Uint8ArrayPolyfill=!0,r}return new Uint8Array(new ArrayBuffer(n))},r.decode=function(n){var e=Math.floor(3*n.length/4);"="==n.charAt(n.length-1)&&(e--,"="==n.charAt(n.length-2)&&e--);for(var a=r.newBinary(e),t=null,u=null,i=null,o=0,c=0;c<n.length;c++){var s=n.charAt(c),f=l(s);switch(c%4){case 0:if(0>f)throw new Error("invalid base64 string");t=f<<2;break;case 1:if(0>f)throw new Error("invalid base64 string");t|=f>>4,a[o++]=t,u=(15&f)<<4;break;case 2:f>=0&&(u|=f>>2,a[o++]=u,i=(3&f)<<6);break;case 3:f>=0&&(a[o++]=i|f)}}return a}}).call(this),"undefined"==typeof Package&&(Package={}),Package.base64={Base64:r}}();
+
+!function(){var n=Package.meteor.Meteor,e=Package.json.JSON,t=Package.underscore._,r=Package.base64.Base64,u,a;(function(){u={},a={};var i={};u.addType=function(n,e){if(t.has(i,n))throw new Error("Type "+n+" already present");i[n]=e};var o=function(n){return t.isNaN(n)||1/0===n||n===-1/0},f=[{matchJSONValue:function(n){return t.has(n,"$date")&&1===t.size(n)},matchObject:function(n){return n instanceof Date},toJSONValue:function(n){return{$date:n.getTime()}},fromJSONValue:function(n){return new Date(n.$date)}},{matchJSONValue:function(n){return t.has(n,"$InfNaN")&&1===t.size(n)},matchObject:o,toJSONValue:function(n){var e;return e=t.isNaN(n)?0:1/0===n?1:-1,{$InfNaN:e}},fromJSONValue:function(n){return n.$InfNaN/0}},{matchJSONValue:function(n){return t.has(n,"$binary")&&1===t.size(n)},matchObject:function(n){return"undefined"!=typeof Uint8Array&&n instanceof Uint8Array||n&&t.has(n,"$Uint8ArrayPolyfill")},toJSONValue:function(n){return{$binary:r.encode(n)}},fromJSONValue:function(n){return r.decode(n.$binary)}},{matchJSONValue:function(n){return t.has(n,"$escape")&&1===t.size(n)},matchObject:function(n){return t.isEmpty(n)||t.size(n)>2?!1:t.any(f,function(e){return e.matchJSONValue(n)})},toJSONValue:function(n){var e={};return t.each(n,function(n,t){e[t]=u.toJSONValue(n)}),{$escape:e}},fromJSONValue:function(n){var e={};return t.each(n.$escape,function(n,t){e[t]=u.fromJSONValue(n)}),e}},{matchJSONValue:function(n){return t.has(n,"$type")&&t.has(n,"$value")&&2===t.size(n)},matchObject:function(n){return u._isCustomType(n)},toJSONValue:function(e){var t=n._noYieldsAllowed(function(){return e.toJSONValue()});return{$type:e.typeName(),$value:t}},fromJSONValue:function(e){var r=e.$type;if(!t.has(i,r))throw new Error("Custom EJSON type "+r+" is not defined");var u=i[r];return n._noYieldsAllowed(function(){return u(e.$value)})}}];u._isCustomType=function(n){return n&&"function"==typeof n.toJSONValue&&"function"==typeof n.typeName&&t.has(i,n.typeName())};var c=u._adjustTypesToJSONValue=function(n){if(null===n)return null;var e=l(n);return void 0!==e?e:"object"!=typeof n?n:(t.each(n,function(e,t){if("object"==typeof e||void 0===e||o(e)){var r=l(e);return r?void(n[t]=r):void c(e)}}),n)},l=function(n){for(var e=0;e<f.length;e++){var t=f[e];if(t.matchObject(n))return t.toJSONValue(n)}return void 0};u.toJSONValue=function(n){var e=l(n);return void 0!==e?e:("object"==typeof n&&(n=u.clone(n),c(n)),n)};var s=u._adjustTypesFromJSONValue=function(n){if(null===n)return null;var e=y(n);return e!==n?e:"object"!=typeof n?n:(t.each(n,function(e,t){if("object"==typeof e){var r=y(e);if(e!==r)return void(n[t]=r);s(e)}}),n)},y=function(n){if("object"==typeof n&&null!==n&&t.size(n)<=2&&t.all(n,function(n,e){return"string"==typeof e&&"$"===e.substr(0,1)}))for(var e=0;e<f.length;e++){var r=f[e];if(r.matchJSONValue(n))return r.fromJSONValue(n)}return n};u.fromJSONValue=function(n){var e=y(n);return e===n&&"object"==typeof n?(n=u.clone(n),s(n),n):e},u.stringify=function(n,t){var r=u.toJSONValue(n);return t&&(t.canonical||t.indent)?u._canonicalStringify(r,t):e.stringify(r)},u.parse=function(n){if("string"!=typeof n)throw new Error("EJSON.parse argument should be a string");return u.fromJSONValue(e.parse(n))},u.isBinary=function(n){return!!("undefined"!=typeof Uint8Array&&n instanceof Uint8Array||n&&n.$Uint8ArrayPolyfill)},u.equals=function(n,e,r){var a,i=!(!r||!r.keyOrderSensitive);if(n===e)return!0;if(t.isNaN(n)&&t.isNaN(e))return!0;if(!n||!e)return!1;if("object"!=typeof n||"object"!=typeof e)return!1;if(n instanceof Date&&e instanceof Date)return n.valueOf()===e.valueOf();if(u.isBinary(n)&&u.isBinary(e)){if(n.length!==e.length)return!1;for(a=0;a<n.length;a++)if(n[a]!==e[a])return!1;return!0}if("function"==typeof n.equals)return n.equals(e,r);if("function"==typeof e.equals)return e.equals(n,r);if(n instanceof Array){if(!(e instanceof Array))return!1;if(n.length!==e.length)return!1;for(a=0;a<n.length;a++)if(!u.equals(n[a],e[a],r))return!1;return!0}switch(u._isCustomType(n)+u._isCustomType(e)){case 1:return!1;case 2:return u.equals(u.toJSONValue(n),u.toJSONValue(e))}var o;if(i){var f=[];return t.each(e,function(n,e){f.push(e)}),a=0,o=t.all(n,function(n,t){return a>=f.length?!1:t!==f[a]?!1:u.equals(n,e[f[a]],r)?(a++,!0):!1}),o&&a===f.length}return a=0,o=t.all(n,function(n,i){return t.has(e,i)&&u.equals(n,e[i],r)?(a++,!0):!1}),o&&t.size(e)===a},u.clone=function(n){var e;if("object"!=typeof n)return n;if(null===n)return null;if(n instanceof Date)return new Date(n.getTime());if(n instanceof RegExp)return n;if(u.isBinary(n)){e=u.newBinary(n.length);for(var r=0;r<n.length;r++)e[r]=n[r];return e}if(t.isArray(n)||t.isArguments(n)){for(e=[],r=0;r<n.length;r++)e[r]=u.clone(n[r]);return e}return"function"==typeof n.clone?n.clone():u._isCustomType(n)?u.fromJSONValue(u.clone(u.toJSONValue(n)),!0):(e={},t.each(n,function(n,t){e[t]=u.clone(n)}),e)},u.newBinary=r.newBinary}).call(this),function(){function n(n){return e.stringify(n)}var r=function(e,u,a,i,o){var f,c,l,s,y=i,h,N=u[e];switch(typeof N){case"string":return n(N);case"number":return isFinite(N)?String(N):"null";case"boolean":return String(N);case"object":if(!N)return"null";if(y=i+a,h=[],t.isArray(N)||t.isArguments(N)){for(s=N.length,f=0;s>f;f+=1)h[f]=r(f,N,a,y,o)||"null";return l=0===h.length?"[]":y?"[\n"+y+h.join(",\n"+y)+"\n"+i+"]":"["+h.join(",")+"]"}var p=t.keys(N);return o&&(p=p.sort()),t.each(p,function(e){l=r(e,N,a,y,o),l&&h.push(n(e)+(y?": ":":")+l)}),l=0===h.length?"{}":y?"{\n"+y+h.join(",\n"+y)+"\n"+i+"}":"{"+h.join(",")+"}"}};u._canonicalStringify=function(n,e){if(e=t.extend({indent:"",canonical:!1},e),e.indent===!0)e.indent=" ";else if("number"==typeof e.indent){for(var u="",a=0;a<e.indent;a++)u+=" ";e.indent=u}return r("",{"":n},e.indent,"",e.canonical)}}.call(this),"undefined"==typeof Package&&(Package={}),Package.ejson={EJSON:u,EJSONTest:a}}();
+
+!function(){var e=Package.meteor.Meteor,t=Package.underscore._,r=Package.ejson.EJSON,n;(function(){n=function(){return n.info.apply(this,arguments)};var i=0,o=[],a=0;n._intercept=function(e){i+=e},n._suppress=function(e){a+=e},n._intercepted=function(){var e=o;return o=[],i=0,e},n.outputFormat="json";var s={debug:"green",warn:"magenta",error:"red"},l="blue",c=["time","timeInexact","level","file","line","program","originApp","satellite","stderr"],u=c.concat(["app","message"]),g=function(t){var r=n.format(t),i=t.level;"undefined"!=typeof console&&console[i]?console[i](r):e._debug(r)};n._getCallerDetails=function(){var e=function(){var e=new Error,t=e.stack;return t},t=e();if(!t)return{};for(var r=t.split("\n"),n,i=1;i<r.length;++i){if(n=r[i],n.match(/^\s*at eval \(eval/))return{file:"eval"};if(!n.match(/packages\/(?:local-test:)?logging(?:\/|\.js)/))break}var o={},a=/(?:[@(]| at )([^(]+?):([0-9:]+)(?:\)|$)/.exec(n);return a?(o.line=a[2].split(":")[0],o.file=a[1].split("/").slice(-1)[0].split("?")[0],o):o},t.each(["debug","info","warn","error"],function(s){n[s]=function(l){if(a)return void a--;var u=!1;i&&(i--,u=!0);var f=!t.isObject(l)||t.isRegExp(l)||t.isDate(l)?{message:new String(l).toString()}:l;if(t.each(c,function(e){if(f[e])throw new Error("Can't set '"+e+"' in log message")}),t.has(f,"message")&&!t.isString(f.message))throw new Error("The 'message' field in log objects must be a string");if(f.omitCallerDetails||(f=t.extend(n._getCallerDetails(),f)),f.time=new Date,f.level=s,"debug"!==s)if(u)o.push(r.stringify(f));else if(e.isServer)if("colored-text"===n.outputFormat)console.log(n.format(f,{color:!0}));else{if("json"!==n.outputFormat)throw new Error("Unknown logging output format: "+n.outputFormat);console.log(r.stringify(f))}else g(f)}}),n.parse=function(e){var t=null;if(e&&"{"===e.charAt(0))try{t=r.parse(e)}catch(n){}return t&&t.time&&t.time instanceof Date?t:null},n.format=function(n,i){n=r.clone(n),i=i||{};var o=n.time;if(!(o instanceof Date))throw new Error("'time' must be a Date object");var a=n.timeInexact,c=n.level||"info",g=n.file,f=n.line,m=n.app||"",p=n.originApp,v=n.message||"",h=n.program||"",d=n.satellite,w=n.stderr||"";t.each(u,function(e){delete n[e]}),t.isEmpty(n)||(v&&(v+=" "),v+=r.stringify(n));var b=function(e){return 10>e?"0"+e:e.toString()},D=function(e){return 100>e?"0"+b(e):e.toString()},j=o.getFullYear().toString()+b(o.getMonth()+1)+b(o.getDate()),S=b(o.getHours())+":"+b(o.getMinutes())+":"+b(o.getSeconds())+"."+D(o.getMilliseconds()),k="("+-((new Date).getTimezoneOffset()/60)+")",E="";m&&(E+=m),p&&p!==m&&(E+=" via "+p),E&&(E="["+E+"] ");var x=[];h&&x.push(h),g&&x.push(g),f&&x.push(f);var y=t.isEmpty(x)?"":"("+x.join(":")+") ";d&&(y+=["[",d,"]"].join(""));var _=w?"(STDERR) ":"",C=[c.charAt(0).toUpperCase(),j,"-",S,k,a?"? ":" ",E,y,_].join(""),F=function(t,r){return i.color&&e.isServer&&r?Npm.require("cli-color")[r](t):t};return F(C,i.metaColor||l)+F(v,s[c])},n.objFromText=function(e,r){var n={message:e,level:"info",time:new Date,timeInexact:!0};return t.extend(n,r)}}).call(this),"undefined"==typeof Package&&(Package={}),Package.logging={Log:n}}();
+
+!function(){var a=Package.meteor.Meteor,e=Package.underscore._,t=Package.logging.Log,o=Package.json.JSON,n;(function(){n={};var t="Meteor_Reload",r={},i,l=null;try{l=window.sessionStorage,l?(l.setItem("__dummy__","1"),l.removeItem("__dummy__")):l=null}catch(g){l=null}n._getData=function(){return l&&l.getItem(t)},l&&(i=n._getData(),l.removeItem(t)),i||(i="{}");var c={};try{c=o.parse(i),"object"!=typeof c&&(a._debug("Got bad data on reload. Ignoring."),c={})}catch(d){a._debug("Got invalid JSON on reload. Ignoring.")}c.reload&&"object"==typeof c.data&&(r=c.data);var u=[];n._onMigrate=function(a,e){e||(e=a,a=void 0),u.push({name:a,callback:e})},n._migrationData=function(a){return r[a]};var s=function(a,t){a=a||function(){},t=t||{};for(var o={},n=e.clone(u),r=!0;n.length;){var i=n.shift(),l=i.callback(a,t);l[0]||(r=!1),l.length>1&&i.name&&(o[i.name]=l[1])}return r||t.immediateMigration?o:null};n._migrate=function(e,n){var r=s(e,n);if(null===r)return!1;try{var i=o.stringify({data:r,reload:!0})}catch(g){throw a._debug("Couldn't serialize data for migration",r),g}if(l)try{l.setItem(t,i)}catch(g){a._debug("Couldn't save data for migration to sessionStorage",g)}else a._debug("Browser does not support sessionStorage. Not saving migration state.");return!0},n._withFreshProvidersForTest=function(a){var t=e.clone(u);u=[];try{a()}finally{u=t}};var f=!1;n._reload=function(a){if(a=a||{},!f){f=!0;var t=function(){e.defer(function(){n._migrate(t,a)&&window.location.reload()})};t()}}}).call(this),function(){a._reload={onMigrate:n._onMigrate,migrationData:n._migrationData,reload:n._reload}}.call(this),"undefined"==typeof Package&&(Package={}),Package.reload={Reload:n}}();
+
+!function(){var t=Package.meteor.Meteor,n,e;(function(){n={},n.active=!1,n.currentComputation=null;var e=function(t){n.currentComputation=t,n.active=!!t},o=function(){return"undefined"!=typeof t?t._debug:"undefined"!=typeof console&&console.log?function(){console.log.apply(console,arguments)}:function(){}},r=function(t,n){if(p)throw n;var e;if(n.stack&&n.message){var r=n.stack.indexOf(n.message);e=r>=0&&10>=r?n.stack:n.message+("\n"===n.stack.charAt(0)?"":"\n")+n.stack}else e=n.stack||n.message;o()("Exception from Tracker "+t+" function:",e)},a=function(n){return"undefined"==typeof t||t.isClient?n:function(){var e=arguments;t._noYieldsAllowed(function(){n.apply(null,e)})}},i=1,u=[],c=!1,s=!1,f=!1,p=!1,d=[],l=function(){c||(setTimeout(n.flush,0),c=!0)},v=!1;n.Computation=function(t,n){if(!v)throw new Error("Tracker.Computation constructor is private; use Tracker.autorun");v=!1;var e=this;e.stopped=!1,e.invalidated=!1,e.firstRun=!0,e._id=i++,e._onInvalidateCallbacks=[],e._parent=n,e._func=t,e._recomputing=!1;var o=!0;try{e._compute(),o=!1}finally{e.firstRun=!1,o&&e.stop()}},n.Computation.prototype.onInvalidate=function(t){var e=this;if("function"!=typeof t)throw new Error("onInvalidate requires a function");e.invalidated?n.nonreactive(function(){a(t)(e)}):e._onInvalidateCallbacks.push(t)},n.Computation.prototype.invalidate=function(){var t=this;if(!t.invalidated){t._recomputing||t.stopped||(l(),u.push(this)),t.invalidated=!0;for(var e=0,o;o=t._onInvalidateCallbacks[e];e++)n.nonreactive(function(){a(o)(t)});t._onInvalidateCallbacks=[]}},n.Computation.prototype.stop=function(){this.stopped||(this.stopped=!0,this.invalidate())},n.Computation.prototype._compute=function(){var t=this;t.invalidated=!1;var o=n.currentComputation;e(t);var r=f;f=!0;try{a(t._func)(t)}finally{e(o),f=r}},n.Computation.prototype._recompute=function(){var t=this;t._recomputing=!0;try{for(;t.invalidated&&!t.stopped;)try{t._compute()}catch(n){r("recompute",n)}}finally{t._recomputing=!1}},n.Dependency=function(){this._dependentsById={}},n.Dependency.prototype.depend=function(t){if(!t){if(!n.active)return!1;t=n.currentComputation}var e=this,o=t._id;return o in e._dependentsById?!1:(e._dependentsById[o]=t,t.onInvalidate(function(){delete e._dependentsById[o]}),!0)},n.Dependency.prototype.changed=function(){var t=this;for(var n in t._dependentsById)t._dependentsById[n].invalidate()},n.Dependency.prototype.hasDependents=function(){var t=this;for(var n in t._dependentsById)return!0;return!1},n.flush=function(t){if(s)throw new Error("Can't call Tracker.flush while flushing");if(f)throw new Error("Can't flush inside Tracker.autorun");s=!0,c=!0,p=!(!t||!t._throwFirstError);var e=!1;try{for(;u.length||d.length;){for(;u.length;){var o=u.shift();o._recompute()}if(d.length){var a=d.shift();try{a()}catch(i){r("afterFlush",i)}}}e=!0}finally{e||(s=!1,n.flush({_throwFirstError:!1})),c=!1,s=!1}},n.autorun=function(t){if("function"!=typeof t)throw new Error("Tracker.autorun requires a function argument");v=!0;var e=new n.Computation(t,n.currentComputation);return n.active&&n.onInvalidate(function(){e.stop()}),e},n.nonreactive=function(t){var o=n.currentComputation;e(null);try{return t()}finally{e(o)}},n.onInvalidate=function(t){if(!n.active)throw new Error("Tracker.onInvalidate requires a currentComputation");n.currentComputation.onInvalidate(t)},n.afterFlush=function(t){d.push(t),l()}}).call(this),function(){t.flush=n.flush,t.autorun=n.autorun,t.autosubscribe=n.autorun,n.depend=function(t){return t.depend()},e=n}.call(this),"undefined"==typeof Package&&(Package={}),Package.tracker={Tracker:n,Deps:e}}();
+
+!function(){var e=Package.meteor.Meteor,n=Package.underscore._,t;(function(){if(e.isServer)var n=Npm.require("crypto");var r=function(){function e(){var e=4022871197,n=function(n){n=n.toString();for(var t=0;t<n.length;t++){e+=n.charCodeAt(t);var r=.02519603282416938*e;e=r>>>0,r-=e,r*=e,e=r>>>0,r-=e,e+=4294967296*r}return 2.3283064365386963e-10*(e>>>0)};return n.version="Mash 0.9",n}return function(n){var t=0,r=0,o=0,i=1;0==n.length&&(n=[+new Date]);var a=e();t=a(" "),r=a(" "),o=a(" ");for(var u=0;u<n.length;u++)t-=a(n[u]),0>t&&(t+=1),r-=a(n[u]),0>r&&(r+=1),o-=a(n[u]),0>o&&(o+=1);a=null;var d=function(){var e=2091639*t+2.3283064365386963e-10*i;return t=r,r=o,o=e-(i=0|e)};return d.uint32=function(){return 4294967296*d()},d.fract53=function(){return d()+1.1102230246251565e-16*(2097152*d()|0)},d.version="Alea 0.9",d.args=n,d}(Array.prototype.slice.call(arguments))},o="23456789ABCDEFGHJKLMNPQRSTWXYZabcdefghijkmnopqrstuvwxyz",i="abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789-_",a=function(e){var n=this;void 0!==e&&(n.alea=r.apply(null,e))};a.prototype.fraction=function(){var e=this;if(e.alea)return e.alea();if(n){var t=parseInt(e.hexString(8),16);return 2.3283064365386963e-10*t}if("undefined"!=typeof window&&window.crypto&&window.crypto.getRandomValues){var r=new Uint32Array(1);return window.crypto.getRandomValues(r),2.3283064365386963e-10*r[0]}throw new Error("No random generator available")},a.prototype.hexString=function(e){var t=this;if(n&&!t.alea){var r=Math.ceil(e/2),o;try{o=n.randomBytes(r)}catch(i){o=n.pseudoRandomBytes(r)}var a=o.toString("hex");return a.substring(0,e)}for(var u=[],d=0;e>d;++d)u.push(t.choice("0123456789abcdef"));return u.join("")},a.prototype._randomString=function(e,n){for(var t=this,r=[],o=0;e>o;o++)r[o]=t.choice(n);return r.join("")},a.prototype.id=function(e){var n=this;return void 0===e&&(e=17),n._randomString(e,o)},a.prototype.secret=function(e){var n=this;return void 0===e&&(e=43),n._randomString(e,i)},a.prototype.choice=function(e){var n=Math.floor(this.fraction()*e.length);return"string"==typeof e?e.substr(n,1):e[n]};var u="undefined"!=typeof window&&window.innerHeight||"undefined"!=typeof document&&document.documentElement&&document.documentElement.clientHeight||"undefined"!=typeof document&&document.body&&document.body.clientHeight||1,d="undefined"!=typeof window&&window.innerWidth||"undefined"!=typeof document&&document.documentElement&&document.documentElement.clientWidth||"undefined"!=typeof document&&document.body&&document.body.clientWidth||1,c="undefined"!=typeof navigator&&navigator.userAgent||"";t=n||"undefined"!=typeof window&&window.crypto&&window.crypto.getRandomValues?new a:new a([new Date,u,d,c,Math.random()]),t.createWithSeeds=function(){if(0===arguments.length)throw new Error("No seeds were provided");return new a(arguments)}}).call(this),function(){e.uuid=function(){for(var e="0123456789abcdef",n=[],r=0;36>r;r++)n[r]=t.choice(e);n[14]="4",n[19]=e.substr(3&parseInt(n[19],16)|8,1),n[8]=n[13]=n[18]=n[23]="-";var o=n.join("");return o}}.call(this),"undefined"==typeof Package&&(Package={}),Package.random={Random:t}}();
+
+!function(){var e=Package.meteor.Meteor,t=Package.underscore._,r=Package.random.Random,i;(function(){i=function(e){var r=this;t.extend(r,t.defaults(t.clone(e||{}),{baseTimeout:1e3,exponent:2.2,maxTimeout:3e5,minTimeout:10,minCount:2,fuzz:.5})),r.retryTimer=null},t.extend(i.prototype,{clear:function(){var e=this;e.retryTimer&&clearTimeout(e.retryTimer),e.retryTimer=null},_timeout:function(e){var t=this;if(e<t.minCount)return t.minTimeout;var i=Math.min(t.maxTimeout,t.baseTimeout*Math.pow(t.exponent,e));return i*=r.fraction()*t.fuzz+(1-t.fuzz/2)},retryLater:function(t,r){var i=this,n=i._timeout(t);return i.retryTimer&&clearTimeout(i.retryTimer),i.retryTimer=e.setTimeout(r,n),n}})}).call(this),"undefined"==typeof Package&&(Package={}),Package.retry={Retry:i}}();
+
+!function(){var e=Package.meteor.Meteor,t=Package.underscore._,r=Package.ejson.EJSON,n,i;(function(){var o=new e.EnvironmentVariable;n=function(e,t){var r=o.getOrNullIfOutsideFiber();r&&r.checking(e);try{l(e,t)}catch(n){throw n instanceof i.Error&&n.path&&(n.message+=" in field "+n.path),n}},i={Optional:function(e){return new a(e)},OneOf:function(){return new c(t.toArray(arguments))},Any:["__any__"],Where:function(e){return new f(e)},ObjectIncluding:function(e){return new s(e)},ObjectWithValues:function(e){return new h(e)},Integer:["__integer__"],Error:e.makeErrorType("Match.Error",function(t){this.message="Match error: "+t,this.path="",this.sanitizedError=new e.Error(400,"Match failed")}),test:function(e,t){try{return l(e,t),!0}catch(r){if(r instanceof i.Error)return!1;throw r}},_failIfArgumentsAreNotAllChecked:function(e,t,r,n){var i=new p(r,n),a=o.withValue(i,function(){return e.apply(t,r)});return i.throwUnlessAllArgumentsHaveBeenChecked(),a}};var a=function(e){this.pattern=e},c=function(e){if(t.isEmpty(e))throw new Error("Must provide at least one choice to Match.OneOf");this.choices=e},f=function(e){this.condition=e},s=function(e){this.pattern=e},h=function(e){this.pattern=e},u=[[String,"string"],[Number,"number"],[Boolean,"boolean"],[void 0,"undefined"]],l=function(e,n){if(n!==i.Any){for(var o=0;o<u.length;++o)if(n===u[o][0]){if(typeof e===u[o][1])return;throw new i.Error("Expected "+u[o][1]+", got "+typeof e)}if(null===n){if(null===e)return;throw new i.Error("Expected null, got "+r.stringify(e))}if("string"==typeof n||"number"==typeof n){if(e===n)return;throw new i.Error("Expected "+n+", got "+r.stringify(e))}if(n===i.Integer){if("number"==typeof e&&(0|e)===e)return;throw new i.Error("Expected Integer, got "+(e instanceof Object?r.stringify(e):e))}if(n===Object&&(n=i.ObjectIncluding({})),n instanceof Array){if(1!==n.length)throw Error("Bad pattern: arrays must have one type element"+r.stringify(n));if(!t.isArray(e)&&!t.isArguments(e))throw new i.Error("Expected array, got "+r.stringify(e));return void t.each(e,function(e,t){try{l(e,n[0])}catch(r){throw r instanceof i.Error&&(r.path=w(t,r.path)),r}})}if(n instanceof f){if(n.condition(e))return;throw new i.Error("Failed Match.Where validation")}if(n instanceof a&&(n=i.OneOf(void 0,n.pattern)),n instanceof c){for(var o=0;o<n.choices.length;++o)try{return void l(e,n.choices[o])}catch(p){if(!(p instanceof i.Error))throw p}throw new i.Error("Failed Match.OneOf or Match.Optional validation")}if(n instanceof Function){if(e instanceof n)return;throw new i.Error("Expected "+(n.name||"particular constructor"))}var g=!1,d;if(n instanceof s&&(g=!0,n=n.pattern),n instanceof h&&(g=!0,d=[n.pattern],n={}),"object"!=typeof n)throw Error("Bad pattern: unknown pattern type");if("object"!=typeof e)throw new i.Error("Expected object, got "+typeof e);if(null===e)throw new i.Error("Expected object, got null");if(e.constructor!==Object)throw new i.Error("Expected plain object");var y={},E={};t.each(n,function(e,t){e instanceof a?E[t]=e.pattern:y[t]=e}),t.each(e,function(e,r){try{if(t.has(y,r))l(e,y[r]),delete y[r];else if(t.has(E,r))l(e,E[r]);else{if(!g)throw new i.Error("Unknown key");d&&l(e,d[0])}}catch(n){throw n instanceof i.Error&&(n.path=w(r,n.path)),n}}),t.each(y,function(e,t){throw new i.Error("Missing key '"+t+"'")})}},p=function(e,r){var n=this;n.args=t.clone(e),n.args.reverse(),n.description=r};t.extend(p.prototype,{checking:function(e){var r=this;r._checkingOneValue(e)||(t.isArray(e)||t.isArguments(e))&&t.each(e,t.bind(r._checkingOneValue,r))},_checkingOneValue:function(e){for(var r=this,n=0;n<r.args.length;++n)if(e===r.args[n]||t.isNaN(e)&&t.isNaN(r.args[n]))return r.args.splice(n,1),!0;return!1},throwUnlessAllArgumentsHaveBeenChecked:function(){var e=this;if(!t.isEmpty(e.args))throw new Error("Did not check() all arguments during "+e.description)}});var g=["do","if","in","for","let","new","try","var","case","else","enum","eval","false","null","this","true","void","with","break","catch","class","const","super","throw","while","yield","delete","export","import","public","return","static","switch","typeof","default","extends","finally","package","private","continue","debugger","function","arguments","interface","protected","implements","instanceof"],w=function(e,r){return"number"==typeof e||e.match(/^[0-9]+$/)?e="["+e+"]":(!e.match(/^[a-z_$][0-9a-z_$]*$/i)||t.contains(g,e))&&(e=JSON.stringify([e])),r&&"["!==r[0]?e+"."+r:e+r}}).call(this),"undefined"==typeof Package&&(Package={}),Package.check={check:n,Match:i}}();
+
+!function(){var i=Package.meteor.Meteor,t=Package.underscore._,a=Package.json.JSON,n=Package.ejson.EJSON,e;(function(){e=function(i,t){var n=this;n._map={},n._idStringify=i||a.stringify,n._idParse=t||a.parse},t.extend(e.prototype,{get:function(i){var t=this,a=t._idStringify(i);return t._map[a]},set:function(i,t){var a=this,n=a._idStringify(i);a._map[n]=t},remove:function(i){var t=this,a=t._idStringify(i);delete t._map[a]},has:function(i){var a=this,n=a._idStringify(i);return t.has(a._map,n)},empty:function(){var i=this;return t.isEmpty(i._map)},clear:function(){var i=this;i._map={}},forEach:function(i){for(var a=this,n=t.keys(a._map),e=0;e<n.length;e++){var r=i.call(null,a._map[n[e]],a._idParse(n[e]));if(r===!1)return}},size:function(){var i=this;return t.size(i._map)},setDefault:function(i,a){var n=this,e=n._idStringify(i);return t.has(n._map,e)?n._map[e]:(n._map[e]=a,a)},clone:function(){var i=this,t=new e(i._idStringify,i._idParse);return i.forEach(function(i,a){t.set(a,n.clone(i))}),t}})}).call(this),"undefined"==typeof Package&&(Package={}),Package["id-map"]={IdMap:e}}();
+
+!function(){var t=Package.meteor.Meteor,e=Package.underscore._,r;(function(){var t=function(t,e,r,n){return{key:t,value:e,next:r,prev:n}};r=function(){var t=this;t._dict={},t._first=null,t._last=null,t._size=0;var r=e.toArray(arguments);t._stringify=function(t){return t},"function"==typeof r[0]&&(t._stringify=r.shift()),e.each(r,function(e){t.putBefore(e[0],e[1],null)})},e.extend(r.prototype,{_k:function(t){return" "+this._stringify(t)},empty:function(){var t=this;return!t._first},size:function(){var t=this;return t._size},_linkEltIn:function(t){var e=this;t.next?(t.prev=t.next.prev,t.next.prev=t,t.prev&&(t.prev.next=t)):(t.prev=e._last,e._last&&(e._last.next=t),e._last=t),(null===e._first||e._first===t.next)&&(e._first=t)},_linkEltOut:function(t){var e=this;t.next&&(t.next.prev=t.prev),t.prev&&(t.prev.next=t.next),t===e._last&&(e._last=t.prev),t===e._first&&(e._first=t.next)},putBefore:function(e,r,n){var i=this;if(i._dict[i._k(e)])throw new Error("Item "+e+" already present in OrderedDict");var o=n?t(e,r,i._dict[i._k(n)]):t(e,r,null);if(void 0===o.next)throw new Error("could not find item to put this one before");i._linkEltIn(o),i._dict[i._k(e)]=o,i._size++},append:function(t,e){var r=this;r.putBefore(t,e,null)},remove:function(t){var e=this,r=e._dict[e._k(t)];if(void 0===r)throw new Error("Item "+t+" not present in OrderedDict");return e._linkEltOut(r),e._size--,delete e._dict[e._k(t)],r.value},get:function(t){var e=this;return e.has(t)?e._dict[e._k(t)].value:void 0},has:function(t){var r=this;return e.has(r._dict,r._k(t))},forEach:function(t){for(var e=this,n=0,i=e._first;null!==i;){var o=t(i.value,i.key,n);if(o===r.BREAK)return;i=i.next,n++}},first:function(){var t=this;return t.empty()?void 0:t._first.key},firstValue:function(){var t=this;return t.empty()?void 0:t._first.value},last:function(){var t=this;return t.empty()?void 0:t._last.key},lastValue:function(){var t=this;return t.empty()?void 0:t._last.value},prev:function(t){var e=this;if(e.has(t)){var r=e._dict[e._k(t)];if(r.prev)return r.prev.key}return null},next:function(t){var e=this;if(e.has(t)){var r=e._dict[e._k(t)];if(r.next)return r.next.key}return null},moveBefore:function(t,e){var r=this,n=r._dict[r._k(t)],i=e?r._dict[r._k(e)]:null;if(void 0===n)throw new Error("Item to move is not present");if(void 0===i)throw new Error("Could not find element to move this one before");i!==n.next&&(r._linkEltOut(n),n.next=i,r._linkEltIn(n))},indexOf:function(t){var e=this,n=null;return e.forEach(function(i,o,u){return e._k(o)===e._k(t)?(n=u,r.BREAK):void 0}),n},_checkRep:function(){var t=this;e.each(t._dict,function(t,e){if(e.next===e)throw new Error("Next is a loop");if(e.prev===e)throw new Error("Prev is a loop")})}}),r.BREAK={"break":!0}}).call(this),"undefined"==typeof Package&&(Package={}),Package["ordered-dict"]={OrderedDict:r}}();
+
+!function(){var t=Package.meteor.Meteor,n,o;(function(){o={exports:{}}}).call(this),function(){!function(){function t(t){for(var n=[],o=[],a=0;a<t[0].length;a++)n.push(t[0][a][1]),o.push(t[0][a][0]);return n=n.sort(function(t,n){return t-n}),o=o.sort(function(t,n){return t-n}),[[n[0],o[0]],[n[n.length-1],o[o.length-1]]]}function n(t,n,o){for(var a=[[0,0]],r=0;r<o.length;r++){for(var e=0;e<o[r].length;e++)a.push(o[r][e]);a.push([0,0])}for(var i=!1,r=0,e=a.length-1;r<a.length;e=r++)a[r][0]>n!=a[e][0]>n&&t<(a[e][1]-a[r][1])*(n-a[r][0])/(a[e][0]-a[r][0])+a[r][1]&&(i=!i);return i}var a={};"undefined"!=typeof o&&o.exports&&(o.exports=a),a.lineStringsIntersect=function(t,n){for(var o=[],a=0;a<=t.coordinates.length-2;++a)for(var r=0;r<=n.coordinates.length-2;++r){var e={x:t.coordinates[a][1],y:t.coordinates[a][0]},i={x:t.coordinates[a+1][1],y:t.coordinates[a+1][0]},s={x:n.coordinates[r][1],y:n.coordinates[r][0]},c={x:n.coordinates[r+1][1],y:n.coordinates[r+1][0]},u=(c.x-s.x)*(e.y-s.y)-(c.y-s.y)*(e.x-s.x),h=(i.x-e.x)*(e.y-s.y)-(i.y-e.y)*(e.x-s.x),d=(c.y-s.y)*(i.x-e.x)-(c.x-s.x)*(i.y-e.y);if(0!=d){var l=u/d,y=h/d;l>=0&&1>=l&&y>=0&&1>=y&&o.push({type:"Point",coordinates:[e.x+l*(i.x-e.x),e.y+l*(i.y-e.y)]})}}return 0==o.length&&(o=!1),o},a.pointInBoundingBox=function(t,n){return!(t.coordinates[1]<n[0][0]||t.coordinates[1]>n[1][0]||t.coordinates[0]<n[0][1]||t.coordinates[0]>n[1][1])},a.pointInPolygon=function(o,r){for(var e="Polygon"==r.type?[r.coordinates]:r.coordinates,i=!1,s=0;s<e.length;s++)a.pointInBoundingBox(o,t(e[s]))&&(i=!0);if(!i)return!1;for(var c=!1,s=0;s<e.length;s++)n(o.coordinates[1],o.coordinates[0],e[s])&&(c=!0);return c},a.numberToRadius=function(t){return t*Math.PI/180},a.numberToDegree=function(t){return 180*t/Math.PI},a.drawCircle=function(t,n,o){for(var r=[n.coordinates[1],n.coordinates[0]],e=t/1e3/6371,i=[a.numberToRadius(r[0]),a.numberToRadius(r[1])],o=o||15,s=[[r[0],r[1]]],c=0;o>c;c++){var u=2*Math.PI*c/o,h=Math.asin(Math.sin(i[0])*Math.cos(e)+Math.cos(i[0])*Math.sin(e)*Math.cos(u)),d=i[1]+Math.atan2(Math.sin(u)*Math.sin(e)*Math.cos(i[0]),Math.cos(e)-Math.sin(i[0])*Math.sin(h));s[c]=[],s[c][1]=a.numberToDegree(h),s[c][0]=a.numberToDegree(d)}return{type:"Polygon",coordinates:[s]}},a.rectangleCentroid=function(t){var n=t.coordinates[0],o=n[0][0],a=n[0][1],r=n[2][0],e=n[2][1],i=r-o,s=e-a;return{type:"Point",coordinates:[o+i/2,a+s/2]}},a.pointDistance=function(t,n){var o=t.coordinates[0],r=t.coordinates[1],e=n.coordinates[0],i=n.coordinates[1],s=a.numberToRadius(i-r),c=a.numberToRadius(e-o),u=Math.pow(Math.sin(s/2),2)+Math.cos(a.numberToRadius(r))*Math.cos(a.numberToRadius(i))*Math.pow(Math.sin(c/2),2),h=2*Math.atan2(Math.sqrt(u),Math.sqrt(1-u));return 6371*h*1e3},a.geometryWithinRadius=function(t,n,o){if("Point"==t.type)return a.pointDistance(t,n)<=o;if("LineString"==t.type||"Polygon"==t.type){var r={},e;e="Polygon"==t.type?t.coordinates[0]:t.coordinates;for(var i in e)if(r.coordinates=e[i],a.pointDistance(r,n)>o)return!1}return!0},a.area=function(t){for(var n=0,o=t.coordinates[0],a=o.length-1,r,e,i=0;i<o.length;a=i++){var r={x:o[i][1],y:o[i][0]},e={x:o[a][1],y:o[a][0]};n+=r.x*e.y,n-=r.y*e.x}return n/=2},a.centroid=function(t){for(var n,o=0,r=0,e=t.coordinates[0],i=e.length-1,s,c,u=0;u<e.length;i=u++){var s={x:e[u][1],y:e[u][0]},c={x:e[i][1],y:e[i][0]};n=s.x*c.y-c.x*s.y,o+=(s.x+c.x)*n,r+=(s.y+c.y)*n}return n=6*a.area(t),{type:"Point",coordinates:[r/n,o/n]}},a.simplify=function(t,n){n=n||20,t=t.map(function(t){return{lng:t.coordinates[0],lat:t.coordinates[1]}});var o,a,r,e,i,s,c,u,h,d,l,y,M,f,g,x,p,v,P,b=Math.PI/180*.5,m=new Array,T=new Array,I=new Array;if(t.length<3)return t;for(o=t.length,d=360*n/(2*Math.PI*6378137),d*=d,r=0,T[0]=0,I[0]=o-1,a=1;a>0;)if(e=T[a-1],i=I[a-1],a--,i-e>1){for(l=t[i].lng()-t[e].lng(),y=t[i].lat()-t[e].lat(),Math.abs(l)>180&&(l=360-Math.abs(l)),l*=Math.cos(b*(t[i].lat()+t[e].lat())),M=l*l+y*y,s=e+1,c=e,h=-1;i>s;s++)f=t[s].lng()-t[e].lng(),g=t[s].lat()-t[e].lat(),Math.abs(f)>180&&(f=360-Math.abs(f)),f*=Math.cos(b*(t[s].lat()+t[e].lat())),x=f*f+g*g,p=t[s].lng()-t[i].lng(),v=t[s].lat()-t[i].lat(),Math.abs(p)>180&&(p=360-Math.abs(p)),p*=Math.cos(b*(t[s].lat()+t[i].lat())),P=p*p+v*v,u=x>=M+P?P:P>=M+x?x:(f*y-g*l)*(f*y-g*l)/M,u>h&&(c=s,h=u);d>h?(m[r]=e,r++):(a++,T[a-1]=c,I[a-1]=i,a++,T[a-1]=e,I[a-1]=c)}else m[r]=e,r++;m[r]=o-1,r++;for(var R=new Array,s=0;r>s;s++)R.push(t[m[s]]);return R.map(function(t){return{type:"Point",coordinates:[t.lng,t.lat]}})},a.destinationPoint=function(t,n,o){o/=6371,n=a.numberToRadius(n);var r=a.numberToRadius(t.coordinates[0]),e=a.numberToRadius(t.coordinates[1]),i=Math.asin(Math.sin(r)*Math.cos(o)+Math.cos(r)*Math.sin(o)*Math.cos(n)),s=e+Math.atan2(Math.sin(n)*Math.sin(o)*Math.cos(r),Math.cos(o)-Math.sin(r)*Math.sin(i));return s=(s+3*Math.PI)%(2*Math.PI)-Math.PI,{type:"Point",coordinates:[a.numberToDegree(i),a.numberToDegree(s)]}}}()}.call(this),function(){n=o.exports}.call(this),"undefined"==typeof Package&&(Package={}),Package["geojson-utils"]={GeoJSON:n}}();
+
+!function(){var e=Package.meteor.Meteor,r=Package.underscore._,t=Package.json.JSON,n=Package.ejson.EJSON,o=Package["id-map"].IdMap,i=Package["ordered-dict"].OrderedDict,a=Package.tracker.Tracker,s=Package.tracker.Deps,c=Package.random.Random,u=Package["geojson-utils"].GeoJSON,d,f,l,h,p,v,_,m,y,g,w,b,$,I,E,O;(function(){d=function(r){var t=this;t.name=r,t._docs=new d._IdMap,t._observeQueue=new e._SynchronousQueue,t.next_qid=1,t.queries={},t._savedOriginals=null,t.paused=!1},f={},l={},d._applyChanges=function(e,t){r.each(t,function(r,t){void 0===r?delete e[t]:e[t]=r})},h=function(e){var r=new Error(e);return r.name="MinimongoError",r},d.prototype.find=function(e,r){return 0===arguments.length&&(e={}),new d.Cursor(this,e,r)},d.Cursor=function(e,r,t){var n=this;t||(t={}),n.collection=e,n.sorter=null,d._selectorIsId(r)?(n._selectorId=r,n.matcher=new f.Matcher(r,n)):(n._selectorId=void 0,n.matcher=new f.Matcher(r,n),(n.matcher.hasGeoQuery()||t.sort)&&(n.sorter=new f.Sorter(t.sort||[],{matcher:n.matcher}))),n.skip=t.skip,n.limit=t.limit,n.fields=t.fields,n.fields&&(n.projectionFn=d._compileProjection(n.fields)),n._transform=d.wrapTransform(t.transform),"undefined"!=typeof a&&(n.reactive=void 0===t.reactive?!0:t.reactive)},d.Cursor.prototype.rewind=function(){},d.prototype.findOne=function(e,r){return 0===arguments.length&&(e={}),r=r||{},r.limit=1,this.find(e,r).fetch()[0]},d.Cursor.prototype.forEach=function(e,t){var o=this,i=o._getRawObjects({ordered:!0});o.reactive&&o._depend({addedBefore:!0,removed:!0,changed:!0,movedBefore:!0}),r.each(i,function(r,i){r=o.projectionFn?o.projectionFn(r):n.clone(r),o._transform&&(r=o._transform(r)),e.call(t,r,i,o)})},d.Cursor.prototype.getTransform=function(){return this._transform},d.Cursor.prototype.map=function(e,r){var t=this,n=[];return t.forEach(function(o,i){n.push(e.call(r,o,i,t))}),n},d.Cursor.prototype.fetch=function(){var e=this,r=[];return e.forEach(function(e){r.push(e)}),r},d.Cursor.prototype.count=function(){var e=this;return e.reactive&&e._depend({added:!0,removed:!0},!0),e._getRawObjects({ordered:!0}).length},d.Cursor.prototype._publishCursor=function(e){var r=this;if(!r.collection.name)throw new Error("Can't publish a cursor from a collection without a name.");var t=r.collection.name;return Mongo.Collection._publishCursor(r,e,t)},d.Cursor.prototype._getCollectionName=function(){var e=this;return e.collection.name},d._observeChangesCallbacksAreOrdered=function(e){if(e.added&&e.addedBefore)throw new Error("Please specify only one of added() and addedBefore()");return!(!e.addedBefore&&!e.movedBefore)},d._observeCallbacksAreOrdered=function(e){if(e.addedAt&&e.added)throw new Error("Please specify only one of added() and addedAt()");if(e.changedAt&&e.changed)throw new Error("Please specify only one of changed() and changedAt()");if(e.removed&&e.removedAt)throw new Error("Please specify only one of removed() and removedAt()");return!!(e.addedAt||e.movedTo||e.changedAt||e.removedAt)},d.ObserveHandle=function(){},r.extend(d.Cursor.prototype,{observe:function(e){var r=this;return d._observeFromObserveChanges(r,e)},observeChanges:function(e){var t=this,o=d._observeChangesCallbacksAreOrdered(e);if(!e._allow_unordered&&!o&&(t.skip||t.limit))throw new Error("must use ordered observe (ie, 'addedBefore' instead of 'added') with skip or limit");if(t.fields&&(0===t.fields._id||t.fields._id===!1))throw Error("You may not observe a cursor with {fields: {_id: 0}}");var i={matcher:t.matcher,sorter:o&&t.sorter,distances:t.matcher.hasGeoQuery()&&o&&new d._IdMap,resultsSnapshot:null,ordered:o,cursor:t,projectionFn:t.projectionFn},s;t.reactive&&(s=t.collection.next_qid++,t.collection.queries[s]=i),i.results=t._getRawObjects({ordered:o,distances:i.distances}),t.collection.paused&&(i.resultsSnapshot=o?[]:new d._IdMap);var c=function(e,n,o){return e?function(){var i=this,a=arguments;t.collection.paused||void 0!==n&&t.projectionFn&&(a[n]=t.projectionFn(a[n]),o&&r.isEmpty(a[n]))||t.collection._observeQueue.queueTask(function(){e.apply(i,a)})}:function(){}};if(i.added=c(e.added,1),i.changed=c(e.changed,1,!0),i.removed=c(e.removed),o&&(i.addedBefore=c(e.addedBefore,1),i.movedBefore=c(e.movedBefore)),!e._suppress_initial&&!t.collection.paused){var u=o?r.bind(r.each,null,i.results):r.bind(i.results.forEach,i.results);u(function(e){var r=n.clone(e);delete r._id,o&&i.addedBefore(e._id,r,null),i.added(e._id,r)})}var f=new d.ObserveHandle;return r.extend(f,{collection:t.collection,stop:function(){t.reactive&&delete t.collection.queries[s]}}),t.reactive&&a.active&&a.onInvalidate(function(){f.stop()}),t.collection._observeQueue.drain(),f}}),d.Cursor.prototype._getRawObjects=function(e){var r=this;e=e||{};var t=e.ordered?[]:new d._IdMap;if(void 0!==r._selectorId){if(r.skip)return t;var n=r.collection._docs.get(r._selectorId);return n&&(e.ordered?t.push(n):t.set(r._selectorId,n)),t}var o;if(r.matcher.hasGeoQuery()&&e.ordered&&(e.distances?(o=e.distances,o.clear()):o=new d._IdMap),r.collection._docs.forEach(function(n,i){var a=r.matcher.documentMatches(n);return a.result&&(e.ordered?(t.push(n),o&&void 0!==a.distance&&o.set(i,a.distance)):t.set(i,n)),!r.limit||r.skip||r.sorter||t.length!==r.limit?!0:!1}),!e.ordered)return t;if(r.sorter){var i=r.sorter.getComparator({distances:o});t.sort(i)}var a=r.skip||0,s=r.limit?r.limit+a:t.length;return t.slice(a,s)},d.Cursor.prototype._depend=function(e,t){var n=this;if(a.active){var o=new a.Dependency;o.depend();var i=r.bind(o.changed,o),s={_suppress_initial:!0,_allow_unordered:t};r.each(["added","changed","removed","addedBefore","movedBefore"],function(r){e[r]&&(s[r]=i)}),n.observeChanges(s)}},d.prototype.insert=function(t,o){var i=this;t=n.clone(t),r.has(t,"_id")||(t._id=d._useOID?new d._ObjectID:c.id());var a=t._id;if(i._docs.has(a))throw h("Duplicate _id '"+a+"'");i._saveOriginal(a,void 0),i._docs.set(a,t);var s=[];for(var u in i.queries){var f=i.queries[u],l=f.matcher.documentMatches(t);l.result&&(f.distances&&void 0!==l.distance&&f.distances.set(a,l.distance),f.cursor.skip||f.cursor.limit?s.push(u):d._insertInResults(f,t))}return r.each(s,function(e){i.queries[e]&&d._recomputeResults(i.queries[e])}),i._observeQueue.drain(),o&&e.defer(function(){o(null,a)}),a},d.prototype._eachPossiblyMatchingDoc=function(e,r){var t=this,n=d._idsMatchedBySelector(e);if(n)for(var o=0;o<n.length;++o){var i=n[o],a=t._docs.get(i);if(a){var s=r(a,i);if(s===!1)break}}else t._docs.forEach(r)},d.prototype.remove=function(t,o){var i=this;if(i.paused&&!i._savedOriginals&&n.equals(t,{})){var a=i._docs.size();return i._docs.clear(),r.each(i.queries,function(e){e.ordered?e.results=[]:e.results.clear()}),o&&e.defer(function(){o(null,a)}),a}var s=new f.Matcher(t,i),c=[];i._eachPossiblyMatchingDoc(t,function(e,r){s.documentMatches(e).result&&c.push(r)});for(var u=[],l=[],h=0;h<c.length;h++){var p=c[h],v=i._docs.get(p);r.each(i.queries,function(e,r){e.matcher.documentMatches(v).result&&(e.cursor.skip||e.cursor.limit?u.push(r):l.push({qid:r,doc:v}))}),i._saveOriginal(p,v),i._docs.remove(p)}return r.each(l,function(e){var r=i.queries[e.qid];r&&(r.distances&&r.distances.remove(e.doc._id),d._removeFromResults(r,e.doc))}),r.each(u,function(e){var r=i.queries[e];r&&d._recomputeResults(r)}),i._observeQueue.drain(),a=c.length,o&&e.defer(function(){o(null,a)}),a},d.prototype.update=function(t,o,i,a){var s=this;!a&&i instanceof Function&&(a=i,i=null),i||(i={});var c=new f.Matcher(t,s),u={};r.each(s.queries,function(e,r){!e.cursor.skip&&!e.cursor.limit||e.paused||(u[r]=n.clone(e.results))});var l={},h=0;s._eachPossiblyMatchingDoc(t,function(e,r){var t=c.documentMatches(e);return t.result&&(s._saveOriginal(r,e),s._modifyAndNotify(e,o,l,t.arrayIndices),++h,!i.multi)?!1:!0}),r.each(l,function(e,r){var t=s.queries[r];t&&d._recomputeResults(t,u[r])}),s._observeQueue.drain();var p;if(0===h&&i.upsert){var v=d._removeDollarOperators(t);d._modify(v,o,{isInsert:!0}),!v._id&&i.insertedId&&(v._id=i.insertedId),p=s.insert(v),h=1}var _;return i._returnObject?(_={numberAffected:h},void 0!==p&&(_.insertedId=p)):_=h,a&&e.defer(function(){a(null,_)}),_},d.prototype.upsert=function(e,t,n,o){var i=this;return o||"function"!=typeof n||(o=n,n={}),i.update(e,t,r.extend({},n,{upsert:!0,_returnObject:!0}),o)},d.prototype._modifyAndNotify=function(e,r,t,o){var i=this,a={};for(var s in i.queries){var c=i.queries[s];a[s]=c.ordered?c.matcher.documentMatches(e).result:c.results.has(e._id)}var u=n.clone(e);d._modify(e,r,{arrayIndices:o});for(s in i.queries){c=i.queries[s];var f=a[s],l=c.matcher.documentMatches(e),h=l.result;h&&c.distances&&void 0!==l.distance&&c.distances.set(e._id,l.distance),c.cursor.skip||c.cursor.limit?(f||h)&&(t[s]=!0):f&&!h?d._removeFromResults(c,e):!f&&h?d._insertInResults(c,e):f&&h&&d._updateInResults(c,e,u)}},d._insertInResults=function(e,r){var t=n.clone(r);if(delete t._id,e.ordered){if(e.sorter){var o=d._insertInSortedList(e.sorter.getComparator({distances:e.distances}),e.results,r),i=e.results[o+1];i=i?i._id:null,e.addedBefore(r._id,t,i)}else e.addedBefore(r._id,t,null),e.results.push(r);e.added(r._id,t)}else e.added(r._id,t),e.results.set(r._id,r)},d._removeFromResults=function(e,r){if(e.ordered){var t=d._findInOrderedResults(e,r);e.removed(r._id),e.results.splice(t,1)}else{var n=r._id;e.removed(r._id),e.results.remove(n)}},d._updateInResults=function(e,t,o){if(!n.equals(t._id,o._id))throw new Error("Can't change a doc's _id while updating");var i=d._makeChangedFields(t,o);if(!e.ordered)return void(r.isEmpty(i)||(e.changed(t._id,i),e.results.set(t._id,t)));var a=d._findInOrderedResults(e,t);if(r.isEmpty(i)||e.changed(t._id,i),e.sorter){e.results.splice(a,1);var s=d._insertInSortedList(e.sorter.getComparator({distances:e.distances}),e.results,t);if(a!==s){var c=e.results[s+1];c=c?c._id:null,e.movedBefore&&e.movedBefore(t._id,c)}}},d._recomputeResults=function(e,r){r||(r=e.results),e.distances&&e.distances.clear(),e.results=e.cursor._getRawObjects({ordered:e.ordered,distances:e.distances}),e.paused||d._diffQueryChanges(e.ordered,r,e.results,e)},d._findInOrderedResults=function(e,r){if(!e.ordered)throw new Error("Can't call _findInOrderedResults on unordered query");for(var t=0;t<e.results.length;t++)if(e.results[t]===r)return t;throw Error("object missing from query")},d._binarySearch=function(e,r,t){for(var n=0,o=r.length;o>0;){var i=Math.floor(o/2);e(t,r[n+i])>=0?(n+=i+1,o-=i+1):o=i}return n},d._insertInSortedList=function(e,r,t){if(0===r.length)return r.push(t),0;var n=d._binarySearch(e,r,t);return r.splice(n,0,t),n},d.prototype.saveOriginals=function(){var e=this;if(e._savedOriginals)throw new Error("Called saveOriginals twice without retrieveOriginals");e._savedOriginals=new d._IdMap},d.prototype.retrieveOriginals=function(){var e=this;if(!e._savedOriginals)throw new Error("Called retrieveOriginals without saveOriginals");var r=e._savedOriginals;return e._savedOriginals=null,r},d.prototype._saveOriginal=function(e,r){var t=this;t._savedOriginals&&(t._savedOriginals.has(e)||t._savedOriginals.set(e,n.clone(r)))},d.prototype.pauseObservers=function(){if(!this.paused){this.paused=!0;for(var e in this.queries){var r=this.queries[e];r.resultsSnapshot=n.clone(r.results)}}},d.prototype.resumeObservers=function(){var e=this;if(this.paused){this.paused=!1;for(var r in this.queries){var t=e.queries[r];d._diffQueryChanges(t.ordered,t.resultsSnapshot,t.results,t),t.resultsSnapshot=null}e._observeQueue.drain()}},d._idStringify=function(e){if(e instanceof d._ObjectID)return e.valueOf();if("string"==typeof e)return""===e?e:"-"===e.substr(0,1)||"~"===e.substr(0,1)||d._looksLikeObjectID(e)||"{"===e.substr(0,1)?"-"+e:e;if(void 0===e)return"-";if("object"==typeof e&&null!==e)throw new Error("Meteor does not currently support objects other than ObjectID as ids");return"~"+t.stringify(e)},d._idParse=function(e){return""===e?e:"-"===e?void 0:"-"===e.substr(0,1)?e.substr(1):"~"===e.substr(0,1)?t.parse(e.substr(1)):d._looksLikeObjectID(e)?new d._ObjectID(e):e},d._makeChangedFields=function(e,r){var t={};return d._diffObjects(r,e,{leftOnly:function(e,r){t[e]=void 0},rightOnly:function(e,r){t[e]=r},both:function(e,r,o){n.equals(r,o)||(t[e]=o)}}),t}}).call(this),function(){d.wrapTransform=function(e){return e?function(t){if(!r.has(t,"_id"))throw new Error("can only transform documents with _id");var o=t._id,i=a.nonreactive(function(){return e(t)});if(!v(i))throw new Error("transform must return object");if(r.has(i,"_id")){if(!n.equals(i._id,o))throw new Error("transformed document can't have different _id")}else i._id=o;return i}:null}}.call(this),function(){p=function(e){return r.isArray(e)&&!n.isBinary(e)},v=d._isPlainObject=function(e){return e&&3===d._f._type(e)},_=function(e){return p(e)||v(e)},m=function(e,n){if(!v(e))return!1;var o=void 0;return r.each(e,function(r,i){var a="$"===i.substr(0,1);if(void 0===o)o=a;else if(o!==a){if(!n)throw new Error("Inconsistent operator: "+t.stringify(e));o=!1}}),!!o},y=function(e){return/^[0-9]+$/.test(e)}}.call(this),function(){f.Matcher=function(e){var r=this;r._paths={},r._hasGeoQuery=!1,r._hasWhere=!1,r._isSimple=!0,r._matchingDocument=void 0,r._selector=null,r._docMatcher=r._compileSelector(e)},r.extend(f.Matcher.prototype,{documentMatches:function(e){if(!e||"object"!=typeof e)throw Error("documentMatches needs a document");return this._docMatcher(e)},hasGeoQuery:function(){return this._hasGeoQuery},hasWhere:function(){return this._hasWhere},isSimple:function(){return this._isSimple},_compileSelector:function(r){var t=this;if(r instanceof Function)return t._isSimple=!1,t._selector=r,t._recordPathUsed(""),function(e){return{result:!!r.call(e)}};if(d._selectorIsId(r))return t._selector={_id:r},t._recordPathUsed("_id"),function(e){return{result:n.equals(e._id,r)}};if(!r||"_id"in r&&!r._id)return t._isSimple=!1,k;if("boolean"==typeof r||p(r)||n.isBinary(r))throw new Error("Invalid selector: "+r);return t._selector=n.clone(r),e(r,t,{isRoot:!0})},_recordPathUsed:function(e){this._paths[e]=!0},_getPaths:function(){return r.keys(this._paths)}});var e=function(e,n,o){o=o||{};var i=[];return r.each(e,function(e,a){if("$"===a.substr(0,1)){if(!r.has(s,a))throw new Error("Unrecognized logical operator: "+a);n._isSimple=!1,i.push(s[a](e,n,o.inElemMatch))}else{o.inElemMatch||n._recordPathUsed(a);var c=$(a),u=t(e,n,o.isRoot);i.push(function(e){var r=c(e);return u(r)})}}),A(i)},t=function(e,r,t){return e instanceof RegExp?(r._isSimple=!1,o(g(e))):m(e)?i(e,r,t):o(w(e))},o=function(e,t){return t=t||{},function(n){var o=n;t.dontExpandLeafArrays||(o=I(n,t.dontIncludeLeafArrays));var i={};return i.result=r.any(o,function(r){var t=e(r.value);return"number"==typeof t&&(r.arrayIndices||(r.arrayIndices=[t]),t=!0),t&&r.arrayIndices&&(i.arrayIndices=r.arrayIndices),t}),i}};g=function(e){return function(t){return t instanceof RegExp?r.isEqual(t,e):"string"!=typeof t?!1:(e.lastIndex=0,e.test(t))}},w=function(e){if(m(e))throw Error("Can't create equalityValueSelector for operator object");return null==e?function(e){return null==e}:function(r){return d._f._equal(e,r)}};var i=function(e,t,n){var i=[];return r.each(e,function(a,s){var c=r.contains(["$lt","$lte","$gt","$gte"],s)&&r.isNumber(a),u="$ne"===s&&!r.isObject(a),d=r.contains(["$in","$nin"],s)&&r.isArray(a)&&!r.any(a,r.isObject);if("$eq"===s||c||d||u||(t._isSimple=!1),r.has(h,s))i.push(h[s](a,e,t,n));else{if(!r.has(b,s))throw new Error("Unrecognized operator: "+s);var f=b[s];i.push(o(f.compileElementSelector(a,e,t),f))}}),M(i)},a=function(t,n,o){if(!p(t)||r.isEmpty(t))throw Error("$and/$or/$nor must be nonempty array");return r.map(t,function(r){if(!v(r))throw Error("$or/$and/$nor entries need to be full objects");return e(r,n,{inElemMatch:o})})},s={$and:function(e,r,t){var n=a(e,r,t);return A(n)},$or:function(e,t,n){var o=a(e,t,n);return 1===o.length?o[0]:function(e){var t=r.any(o,function(r){return r(e).result});return{result:t}}},$nor:function(e,t,n){var o=a(e,t,n);return function(e){var t=r.all(o,function(r){return!r(e).result});return{result:t}}},$where:function(e,r){return r._recordPathUsed(""),r._hasWhere=!0,e instanceof Function||(e=Function("obj","return "+e)),function(r){return{result:e.call(r,r)}}},$comment:function(){return function(){return{result:!0}}}},c=function(e){return function(r){var t=e(r);return{result:!t.result}}},h={$not:function(e,r,n){return c(t(e,n))},$ne:function(e){return c(o(w(e)))},$nin:function(e){return c(o(b.$in.compileElementSelector(e)))},$exists:function(e){var r=o(function(e){return void 0!==e});return e?r:c(r)},$options:function(e,t){if(!r.has(t,"$regex"))throw Error("$options needs a $regex");return j},$maxDistance:function(e,r){if(!r.$near)throw Error("$maxDistance needs a $near");return j},$all:function(e,n,o){if(!p(e))throw Error("$all requires array");if(r.isEmpty(e))return k;var i=[];return r.each(e,function(e){if(m(e))throw Error("no $ expressions in $all");i.push(t(e,o))}),M(i)},$near:function(e,t,n,o){if(!o)throw Error("$near can't be inside another $ operator");n._hasGeoQuery=!0;var i,a,s;if(v(e)&&r.has(e,"$geometry"))i=e.$maxDistance,a=e.$geometry,s=function(e){return e&&e.type?"Point"===e.type?u.pointDistance(a,e):u.geometryWithinRadius(e,a,i)?0:i+1:null};else{if(i=t.$maxDistance,!p(e)&&!v(e))throw Error("$near argument must be coordinate pair or GeoJSON");a=O(e),s=function(e){return p(e)||v(e)?E(a,e):null}}return function(e){e=I(e);var t={result:!1};return r.each(e,function(e){var r=s(e.value);null===r||r>i||void 0!==t.distance&&t.distance<=r||(t.result=!0,t.distance=r,e.arrayIndices?t.arrayIndices=e.arrayIndices:delete t.arrayIndices)}),t}}},E=function(e,t){e=O(e),t=O(t);var n=e[0]-t[0],o=e[1]-t[1];return r.isNaN(n)||r.isNaN(o)?null:Math.sqrt(n*n+o*o)},O=function(e){return r.map(e,r.identity)},C=function(e){return{compileElementSelector:function(r){if(p(r))return function(){return!1};void 0===r&&(r=null);var t=d._f._type(r);return function(n){return void 0===n&&(n=null),d._f._type(n)!==t?!1:e(d._f._cmp(n,r))}}}};b={$lt:C(function(e){return 0>e}),$gt:C(function(e){return e>0}),$lte:C(function(e){return 0>=e}),$gte:C(function(e){return e>=0}),$mod:{compileElementSelector:function(e){if(!p(e)||2!==e.length||"number"!=typeof e[0]||"number"!=typeof e[1])throw Error("argument to $mod must be an array of two numbers");var r=e[0],t=e[1];return function(e){return"number"==typeof e&&e%r===t}}},$in:{compileElementSelector:function(e){if(!p(e))throw Error("$in needs an array");var t=[];return r.each(e,function(e){if(e instanceof RegExp)t.push(g(e));else{if(m(e))throw Error("cannot nest $ under $in");t.push(w(e))}}),function(e){return void 0===e&&(e=null),r.any(t,function(r){return r(e)})}}},$size:{dontExpandLeafArrays:!0,compileElementSelector:function(e){if("string"==typeof e)e=0;else if("number"!=typeof e)throw Error("$size needs a number");return function(r){return p(r)&&r.length===e}}},$type:{dontIncludeLeafArrays:!0,compileElementSelector:function(e){if("number"!=typeof e)throw Error("$type needs a number");return function(r){return void 0!==r&&d._f._type(r)===e}}},$regex:{compileElementSelector:function(e,r){if(!("string"==typeof e||e instanceof RegExp))throw Error("$regex has to be a string or RegExp");var t;if(void 0!==r.$options){if(/[^gim]/.test(r.$options))throw new Error("Only the i, m, and g regexp options are supported");var n=e instanceof RegExp?e.source:e;t=new RegExp(n,r.$options)}else t=e instanceof RegExp?e:new RegExp(e);return g(t)}},$elemMatch:{dontExpandLeafArrays:!0,compileElementSelector:function(r,n,o){if(!v(r))throw Error("$elemMatch need an object");var i,a;return m(r,!0)?(i=t(r,o),a=!1):(i=e(r,o,{inElemMatch:!0}),a=!0),function(e){if(!p(e))return!1;for(var r=0;r<e.length;++r){var t=e[r],n;if(a){if(!v(t)&&!p(t))return!1;n=t}else n=[{value:t,dontIterate:!0}];if(i(n).result)return r}return!1}}}},$=function(e,t){t=t||{};var n=e.split("."),o=n.length?n[0]:"",i=y(o),a=n.length>=2&&y(n[1]),s;n.length>1&&(s=$(n.slice(1).join(".")));var c=function(e){return e.dontIterate||delete e.dontIterate,e.arrayIndices&&!e.arrayIndices.length&&delete e.arrayIndices,e};return function(e,n){if(n||(n=[]),p(e)){if(!(i&&o<e.length))return[];n=n.concat(+o,"x")}var u=e[o];if(!s)return[c({value:u,dontIterate:p(e)&&p(u),arrayIndices:n})];if(!_(u))return p(e)?[]:[c({value:void 0,arrayIndices:n})];var d=[],f=function(e){Array.prototype.push.apply(d,e)};return f(s(u,n)),!p(u)||a&&t.forSort||r.each(u,function(e,r){v(e)&&f(s(e,n.concat(r)))}),d}},l.makeLookupFunction=$,I=function(e,t){var n=[];return r.each(e,function(e){var o=p(e.value);t&&o&&!e.dontIterate||n.push({value:e.value,arrayIndices:e.arrayIndices}),o&&!e.dontIterate&&r.each(e.value,function(r,t){n.push({value:r,arrayIndices:(e.arrayIndices||[]).concat(t)})})}),n};var k=function(e){return{result:!1}},j=function(e){return{result:!0}},S=function(e){return 0===e.length?j:1===e.length?e[0]:function(t){var n={};return n.result=r.all(e,function(e){var r=e(t);return r.result&&void 0!==r.distance&&void 0===n.distance&&(n.distance=r.distance),r.result&&r.arrayIndices&&(n.arrayIndices=r.arrayIndices),r.result}),n.result||(delete n.distance,delete n.arrayIndices),n}},A=S,M=S;d._f={_type:function(e){return"number"==typeof e?1:"string"==typeof e?2:"boolean"==typeof e?8:p(e)?4:null===e?10:e instanceof RegExp?11:"function"==typeof e?13:e instanceof Date?9:n.isBinary(e)?5:e instanceof d._ObjectID?7:3},_equal:function(e,r){return n.equals(e,r,{keyOrderSensitive:!0})},_typeorder:function(e){return[-1,1,2,3,4,5,-1,6,7,8,0,9,-1,100,2,100,1,8,1][e]},_cmp:function(e,r){if(void 0===e)return void 0===r?0:-1;if(void 0===r)return 1;var t=d._f._type(e),n=d._f._type(r),o=d._f._typeorder(t),i=d._f._typeorder(n);if(o!==i)return i>o?-1:1;if(t!==n)throw Error("Missing type coercion logic in _cmp");if(7===t&&(t=n=2,e=e.toHexString(),r=r.toHexString()),9===t&&(t=n=1,e=e.getTime(),r=r.getTime()),1===t)return e-r;if(2===n)return r>e?-1:e===r?0:1;if(3===t){var a=function(e){var r=[];for(var t in e)r.push(t),r.push(e[t]);return r};return d._f._cmp(a(e),a(r))}if(4===t)for(var s=0;;s++){if(s===e.length)return s===r.length?0:-1;if(s===r.length)return 1;var c=d._f._cmp(e[s],r[s]);if(0!==c)return c}if(5===t){if(e.length!==r.length)return e.length-r.length;for(s=0;s<e.length;s++){if(e[s]<r[s])return-1;if(e[s]>r[s])return 1}return 0}if(8===t)return e?r?0:1:r?-1:0;if(10===t)return 0;if(11===t)throw Error("Sorting not supported on regular expression");if(13===t)throw Error("Sorting not supported on Javascript code");throw Error("Unknown type to sort")}},d._removeDollarOperators=function(e){var r={};for(var t in e)"$"!==t.substr(0,1)&&(r[t]=e[t]);return r}}.call(this),function(){f.Sorter=function(n,o){var i=this;o=o||{},i._sortSpecParts=[];var a=function(e,r){if(!e)throw Error("sort keys must be non-empty");if("$"===e.charAt(0))throw Error("unsupported sort key: "+e);i._sortSpecParts.push({path:e,lookup:$(e,{forSort:!0}),ascending:r})};if(n instanceof Array)for(var s=0;s<n.length;s++)"string"==typeof n[s]?a(n[s],!0):a(n[s][0],"desc"!==n[s][1]);else{if("object"!=typeof n)throw Error("Bad sort specification: "+t.stringify(n));r.each(n,function(e,r){a(r,e>=0)})}if(i.affectedByModifier){var c={};r.each(i._sortSpecParts,function(e){c[e.path]=1}),i._selectorForAffectedByModifier=new f.Matcher(c)}i._keyComparator=e(r.map(i._sortSpecParts,function(e,r){return i._keyFieldComparator(r)})),i._keyFilter=null,o.matcher&&i._useWithMatcher(o.matcher)},r.extend(f.Sorter.prototype,{getComparator:function(r){var t=this;if(!r||!r.distances)return t._getBaseComparator();var n=r.distances;return e([t._getBaseComparator(),function(e,r){if(!n.has(e._id))throw Error("Missing distance for "+e._id);if(!n.has(r._id))throw Error("Missing distance for "+r._id);return n.get(e._id)-n.get(r._id)}])},_getPaths:function(){var e=this;return r.pluck(e._sortSpecParts,"path")},_getMinKeyFromDoc:function(e){var r=this,t=null;if(r._generateKeysFromDoc(e,function(e){return r._keyCompatibleWithSelector(e)?null===t?void(t=e):void(r._compareKeys(e,t)<0&&(t=e)):void 0}),null===t)throw Error("sort selector found no keys in doc?");return t},_keyCompatibleWithSelector:function(e){var r=this;return!r._keyFilter||r._keyFilter(e)},_generateKeysFromDoc:function(e,t){var n=this;if(0===n._sortSpecParts.length)throw new Error("can't generate keys without a spec");var o=[],i=function(e){return e.join(",")+","},a=null;if(r.each(n._sortSpecParts,function(t,n){var s=I(t.lookup(e),!0);s.length||(s=[{value:null}]);var c=!1;if(o[n]={},r.each(s,function(e){if(!e.arrayIndices){if(s.length>1)throw Error("multiple branches but no array used?");return void(o[n][""]=e.value)}c=!0;var t=i(e.arrayIndices);if(r.has(o[n],t))throw Error("duplicate path: "+t);if(o[n][t]=e.value,a&&!r.has(a,t))throw Error("cannot index parallel arrays")}),a){if(!r.has(o[n],"")&&r.size(a)!==r.size(o[n]))throw Error("cannot index parallel arrays!")}else c&&(a={},r.each(o[n],function(e,r){a[r]=!0}))}),!a){var s=r.map(o,function(e){if(!r.has(e,""))throw Error("no value in sole key case?");return e[""]});return void t(s)}r.each(a,function(e,n){var i=r.map(o,function(e){if(r.has(e,""))return e[""];if(!r.has(e,n))throw Error("missing path?");return e[n]});t(i)})},_compareKeys:function(e,r){var t=this;if(e.length!==t._sortSpecParts.length||r.length!==t._sortSpecParts.length)throw Error("Key has wrong length");return t._keyComparator(e,r)},_keyFieldComparator:function(e){var r=this,t=!r._sortSpecParts[e].ascending;return function(r,n){var o=d._f._cmp(r[e],n[e]);return t&&(o=-o),o}},_getBaseComparator:function(){var e=this;return e._sortSpecParts.length?function(r,t){var n=e._getMinKeyFromDoc(r),o=e._getMinKeyFromDoc(t);return e._compareKeys(n,o)}:function(e,r){return 0}},_useWithMatcher:function(e){var t=this;if(t._keyFilter)throw Error("called _useWithMatcher twice?");if(!r.isEmpty(t._sortSpecParts)){var n=e._selector;if(!(n instanceof Function)){var o={};r.each(t._sortSpecParts,function(e,r){o[e.path]=[]}),r.each(n,function(e,t){var n=o[t];if(n){if(e instanceof RegExp){if(e.ignoreCase||e.multiline)return;return void n.push(g(e))}return m(e)?void r.each(e,function(t,o){r.contains(["$lt","$lte","$gt","$gte"],o)&&n.push(b[o].compileElementSelector(t)),"$regex"!==o||e.$options||n.push(b.$regex.compileElementSelector(t,e))}):void n.push(w(e))}}),r.isEmpty(o[t._sortSpecParts[0].path])||(t._keyFilter=function(e){return r.all(t._sortSpecParts,function(t,n){return r.all(o[t.path],function(r){return r(e[n])})})})}}}});var e=function(e){return function(r,t){for(var n=0;n<e.length;++n){var o=e[n](r,t);if(0!==o)return o}return 0}}}.call(this),function(){d._compileProjection=function(e){d._checkSupportedProjection(e);var t=r.isUndefined(e._id)?!0:e._id,o=E(e),i=function(e,t){if(r.isArray(e))return r.map(e,function(e){return i(e,t)});var a=o.including?{}:n.clone(e);return r.each(t,function(t,s){r.has(e,s)&&(r.isObject(t)?r.isObject(e[s])&&(a[s]=i(e[s],t)):o.including?a[s]=n.clone(e[s]):delete a[s])}),a};return function(e){var n=i(e,o.tree);return t&&r.has(e,"_id")&&(n._id=e._id),!t&&r.has(n,"_id")&&delete n._id,n}},E=function(e){var t=r.keys(e).sort();t.length>0&&(1!==t.length||"_id"!==t[0])&&(t=r.reject(t,function(e){return"_id"===e}));var n=null;r.each(t,function(r){var t=!!e[r];if(null===n&&(n=t),n!==t)throw h("You cannot currently mix including and excluding fields.")});var o=O(t,function(e){return n},function(e,r,t){var n=t,o=r;throw h("both "+n+" and "+o+" found in fields option, using both of them may trigger unexpected behavior. Did you mean to use only one of them?")});return{tree:o,including:n}},O=function(e,t,n,o){return o=o||{},r.each(e,function(e){var i=o,a=e.split("."),s=r.all(a.slice(0,-1),function(t,o){if(r.has(i,t)){if(!r.isObject(i[t])&&(i[t]=n(i[t],a.slice(0,o+1).join("."),e),!r.isObject(i[t])))return!1}else i[t]={};return i=i[t],!0});if(s){var c=r.last(a);i[c]=r.has(i,c)?n(i[c],e,e):t(e)}}),o},d._checkSupportedProjection=function(e){if(!r.isObject(e)||r.isArray(e))throw h("fields option must be an object");r.each(e,function(e,t){if(r.contains(t.split("."),"$"))throw h("Minimongo doesn't support $ operator in projections yet.");if(-1===r.indexOf([1,0,!0,!1],e))throw h("Projection values should be one of 1, 0, true, or false")})}}.call(this),function(){d._modify=function(t,a,s){if(s=s||{},!v(a))throw h("Modifier must be an object");var c=m(a),u;if(c)u=n.clone(t),r.each(a,function(t,n){var a=i[n];if(s.isInsert&&"$setOnInsert"===n&&(a=i.$set),!a)throw h("Invalid modifier specified "+n);r.each(t,function(t,i){if(i.length&&"."===i[i.length-1])throw h("Invalid mod field name, may not end in a period");if("_id"===i)throw h("Mod on _id not allowed");var c=i.split("."),d=r.has(o,n),f="$rename"===n,l=e(u,c,{noCreate:o[n],forbidArray:"$rename"===n,arrayIndices:s.arrayIndices}),p=c.pop();a(l,p,t,i,u)})});else{if(a._id&&!n.equals(t._id,a._id))throw h("Cannot change the _id of a document");for(var d in a)if(/\./.test(d))throw h("When replacing document, field name may not contain '.'");u=a}r.each(r.keys(t),function(e){("_id"!==e||s.isInsert)&&delete t[e]}),r.each(u,function(e,r){t[r]=e})};var e=function(e,r,n){n=n||{};for(var o=!1,i=0;i<r.length;i++){var a=i===r.length-1,s=r[i],c=_(e);if(!c){if(n.noCreate)return void 0;var u=h("cannot use the part '"+s+"' to traverse "+e);throw u.setPropertyError=!0,u}if(e instanceof Array){if(n.forbidArray)return null;if("$"===s){if(o)throw h("Too many positional (i.e. '$') elements");if(!n.arrayIndices||!n.arrayIndices.length)throw h("The positional operator did not find the match needed from the query");s=n.arrayIndices[0],o=!0}else{if(!y(s)){if(n.noCreate)return void 0;throw h("can't append to array using string field name ["+s+"]")}s=parseInt(s)}if(a&&(r[i]=s),n.noCreate&&s>=e.length)return void 0;for(;e.length<s;)e.push(null);if(!a)if(e.length===s)e.push({});else if("object"!=typeof e[s])throw h("can't modify field '"+r[i+1]+"' of list value "+t.stringify(e[s]))}else{if(s.length&&"$"===s.substr(0,1))throw h("can't set field named "+s);if(!(s in e)){if(n.noCreate)return void 0;a||(e[s]={})}}if(a)return e;e=e[s]}},o={$unset:!0,$pop:!0,$rename:!0,$pull:!0,$pullAll:!0},i={$inc:function(e,r,t){if("number"!=typeof t)throw h("Modifier $inc allowed for numbers only");if(r in e){if("number"!=typeof e[r])throw h("Cannot apply $inc modifier to non-number");e[r]+=t}else e[r]=t},$set:function(e,t,o){if(!r.isObject(e)){var i=h("Cannot set property on non-object field");throw i.setPropertyError=!0,i}if(null===e){var i=h("Cannot set property on null");throw i.setPropertyError=!0,i}e[t]=n.clone(o)},$setOnInsert:function(e,r,t){},$unset:function(e,r,t){void 0!==e&&(e instanceof Array?r in e&&(e[r]=null):delete e[r])},$push:function(e,r,t){if(void 0===e[r]&&(e[r]=[]),!(e[r]instanceof Array))throw h("Cannot apply $push modifier to non-array");if(!t||!t.$each)return void e[r].push(n.clone(t));var o=t.$each;if(!(o instanceof Array))throw h("$each must be an array");var i=void 0;if("$slice"in t){if("number"!=typeof t.$slice)throw h("$slice must be a numeric value");if(t.$slice>0)throw h("$slice in $push must be zero or negative");i=t.$slice}var a=void 0;if(t.$sort){if(void 0===i)throw h("$sort requires $slice to be present");a=new f.Sorter(t.$sort).getComparator();for(var s=0;s<o.length;s++)if(3!==d._f._type(o[s]))throw h("$push like modifiers using $sort require all elements to be objects")}for(var c=0;c<o.length;c++)e[r].push(n.clone(o[c]));a&&e[r].sort(a),void 0!==i&&(e[r]=0===i?[]:e[r].slice(i))},$pushAll:function(e,r,t){if(!("object"==typeof t&&t instanceof Array))throw h("Modifier $pushAll/pullAll allowed for arrays only");var n=e[r];if(void 0===n)e[r]=t;else{if(!(n instanceof Array))throw h("Cannot apply $pushAll modifier to non-array");for(var o=0;o<t.length;o++)n.push(t[o])}},$addToSet:function(e,t,o){var i=!1;if("object"==typeof o)for(var a in o){"$each"===a&&(i=!0);break}var s=i?o.$each:[o],c=e[t];if(void 0===c)e[t]=s;else{if(!(c instanceof Array))throw h("Cannot apply $addToSet modifier to non-array");r.each(s,function(e){for(var r=0;r<c.length;r++)if(d._f._equal(e,c[r]))return;
+c.push(n.clone(e))})}},$pop:function(e,r,t){if(void 0!==e){var n=e[r];if(void 0!==n){if(!(n instanceof Array))throw h("Cannot apply $pop modifier to non-array");"number"==typeof t&&0>t?n.splice(0,1):n.pop()}}},$pull:function(e,r,t){if(void 0!==e){var n=e[r];if(void 0!==n){if(!(n instanceof Array))throw h("Cannot apply $pull/pullAll modifier to non-array");var o=[];if("object"!=typeof t||t instanceof Array)for(var i=0;i<n.length;i++)d._f._equal(n[i],t)||o.push(n[i]);else for(var a=new f.Matcher(t),i=0;i<n.length;i++)a.documentMatches(n[i]).result||o.push(n[i]);e[r]=o}}},$pullAll:function(e,r,t){if(!("object"==typeof t&&t instanceof Array))throw h("Modifier $pushAll/pullAll allowed for arrays only");if(void 0!==e){var n=e[r];if(void 0!==n){if(!(n instanceof Array))throw h("Cannot apply $pull/pullAll modifier to non-array");for(var o=[],i=0;i<n.length;i++){for(var a=!1,s=0;s<t.length;s++)if(d._f._equal(n[i],t[s])){a=!0;break}a||o.push(n[i])}e[r]=o}}},$rename:function(r,t,n,o,i){if(o===n)throw h("$rename source must differ from target");if(null===r)throw h("$rename source field invalid");if("string"!=typeof n)throw h("$rename target must be a string");if(void 0!==r){var a=r[t];delete r[t];var s=n.split("."),c=e(i,s,{forbidArray:!0});if(null===c)throw h("$rename target field invalid");var u=s.pop();c[u]=a}},$bit:function(e,r,t){throw h("$bit is not supported")}}}.call(this),function(){d._diffQueryChanges=function(e,r,t,n){e?d._diffQueryOrderedChanges(r,t,n):d._diffQueryUnorderedChanges(r,t,n)},d._diffQueryUnorderedChanges=function(e,r,t){if(t.movedBefore)throw new Error("_diffQueryUnordered called with a movedBefore observer!");r.forEach(function(r,o){var i=e.get(o);if(i)t.changed&&!n.equals(i,r)&&t.changed(o,d._makeChangedFields(r,i));else if(t.added){var a=n.clone(r);delete a._id,t.added(r._id,a)}}),t.removed&&e.forEach(function(e,n){r.has(n)||t.removed(n)})},d._diffQueryOrderedChanges=function(t,o,i){var a={};r.each(o,function(r){a[r._id]&&e._debug("Duplicate _id in new_results"),a[r._id]=!0});var s={};r.each(t,function(r,t){r._id in s&&e._debug("Duplicate _id in old_results"),s[r._id]=t});for(var c=[],u=0,f=o.length,l=new Array(f),h=new Array(f),p=function(e){return s[o[e]._id]},v=0;f>v;v++)if(void 0!==s[o[v]._id]){for(var _=u;_>0&&!(p(l[_-1])<p(v));)_--;h[v]=0===_?-1:l[_-1],l[_]=v,_+1>u&&(u=_+1)}for(var m=0===u?-1:l[u-1];m>=0;)c.push(m),m=h[m];c.reverse(),c.push(o.length),r.each(t,function(e){a[e._id]||i.removed&&i.removed(e._id)});var y=0;r.each(c,function(e){for(var a=o[e]?o[e]._id:null,c,u,f,l=y;e>l;l++)u=o[l],r.has(s,u._id)?(c=t[s[u._id]],f=d._makeChangedFields(u,c),r.isEmpty(f)||i.changed&&i.changed(u._id,f),i.movedBefore&&i.movedBefore(u._id,a)):(f=n.clone(u),delete f._id,i.addedBefore&&i.addedBefore(u._id,f,a),i.added&&i.added(u._id,f));a&&(u=o[e],c=t[s[u._id]],f=d._makeChangedFields(u,c),r.isEmpty(f)||i.changed&&i.changed(u._id,f)),y=e+1})},d._diffObjects=function(e,t,n){r.each(e,function(e,o){r.has(t,o)?n.both&&n.both(o,e,t[o]):n.leftOnly&&n.leftOnly(o,e)}),n.rightOnly&&r.each(t,function(t,o){r.has(e,o)||n.rightOnly(o,t)})}}.call(this),function(){d._IdMap=function(){var e=this;o.call(e,d._idStringify,d._idParse)},e._inherits(d._IdMap,o)}.call(this),function(){d._CachingChangeObserver=function(e){var t=this;e=e||{};var o=e.callbacks&&d._observeChangesCallbacksAreOrdered(e.callbacks);if(r.has(e,"ordered")){if(t.ordered=e.ordered,e.callbacks&&e.ordered!==o)throw Error("ordered option doesn't match callbacks")}else{if(!e.callbacks)throw Error("must provide ordered or callbacks");t.ordered=o}var a=e.callbacks||{};t.ordered?(t.docs=new i(d._idStringify),t.applyChange={addedBefore:function(e,r,o){var i=n.clone(r);i._id=e,a.addedBefore&&a.addedBefore.call(t,e,r,o),a.added&&a.added.call(t,e,r),t.docs.putBefore(e,i,o||null)},movedBefore:function(e,r){var n=t.docs.get(e);a.movedBefore&&a.movedBefore.call(t,e,r),t.docs.moveBefore(e,r||null)}}):(t.docs=new d._IdMap,t.applyChange={added:function(e,r){var o=n.clone(r);a.added&&a.added.call(t,e,r),o._id=e,t.docs.set(e,o)}}),t.applyChange.changed=function(e,r){var o=t.docs.get(e);if(!o)throw new Error("Unknown id for changed: "+e);a.changed&&a.changed.call(t,e,n.clone(r)),d._applyChanges(o,r)},t.applyChange.removed=function(e){a.removed&&a.removed.call(t,e),t.docs.remove(e)}},d._observeFromObserveChanges=function(e,t){var o=e.getTransform()||function(e){return e},i=!!t._suppress_initial,a;if(d._observeCallbacksAreOrdered(t)){var s=!t._no_indices;a={addedBefore:function(e,n,a){var c=this;if(!i&&(t.addedAt||t.added)){var u=o(r.extend(n,{_id:e}));if(t.addedAt){var d=s?a?c.docs.indexOf(a):c.docs.size():-1;t.addedAt(u,d,a)}else t.added(u)}},changed:function(e,r){var i=this;if(t.changedAt||t.changed){var a=n.clone(i.docs.get(e));if(!a)throw new Error("Unknown id for changed: "+e);var c=o(n.clone(a));if(d._applyChanges(a,r),a=o(a),t.changedAt){var u=s?i.docs.indexOf(e):-1;t.changedAt(a,c,u)}else t.changed(a,c)}},movedBefore:function(e,r){var i=this;if(t.movedTo){var a=s?i.docs.indexOf(e):-1,c=s?r?i.docs.indexOf(r):i.docs.size():-1;c>a&&--c,t.movedTo(o(n.clone(i.docs.get(e))),a,c,r||null)}},removed:function(e){var r=this;if(t.removedAt||t.removed){var n=o(r.docs.get(e));if(t.removedAt){var i=s?r.docs.indexOf(e):-1;t.removedAt(n,i)}else t.removed(n)}}}}else a={added:function(e,n){if(!i&&t.added){var a=r.extend(n,{_id:e});t.added(o(a))}},changed:function(e,r){var i=this;if(t.changed){var a=i.docs.get(e),s=n.clone(a);d._applyChanges(s,r),t.changed(o(s),o(n.clone(a)))}},removed:function(e){var r=this;t.removed&&t.removed(o(r.docs.get(e)))}};var c=new d._CachingChangeObserver({callbacks:a}),u=e.observeChanges(c.applyChange);return i=!1,u}}.call(this),function(){d._looksLikeObjectID=function(e){return 24===e.length&&e.match(/^[0-9a-f]*$/)},d._ObjectID=function(e){var r=this;if(e){if(e=e.toLowerCase(),!d._looksLikeObjectID(e))throw new Error("Invalid hexadecimal string for creating an ObjectID");r._str=e}else r._str=c.hexString(24)},d._ObjectID.prototype.toString=function(){var e=this;return'ObjectID("'+e._str+'")'},d._ObjectID.prototype.equals=function(e){var r=this;return e instanceof d._ObjectID&&r.valueOf()===e.valueOf()},d._ObjectID.prototype.clone=function(){var e=this;return new d._ObjectID(e._str)},d._ObjectID.prototype.typeName=function(){return"oid"},d._ObjectID.prototype.getTimestamp=function(){var e=this;return parseInt(e._str.substr(0,8),16)},d._ObjectID.prototype.valueOf=d._ObjectID.prototype.toJSONValue=d._ObjectID.prototype.toHexString=function(){return this._str},d._selectorIsId=function(e){return"string"==typeof e||"number"==typeof e||e instanceof d._ObjectID},d._selectorIsIdPerhapsAsObject=function(e){return d._selectorIsId(e)||e&&"object"==typeof e&&e._id&&d._selectorIsId(e._id)&&1===r.size(e)},d._idsMatchedBySelector=function(e){if(d._selectorIsId(e))return[e];if(!e)return null;if(r.has(e,"_id"))return d._selectorIsId(e._id)?[e._id]:e._id&&e._id.$in&&r.isArray(e._id.$in)&&!r.isEmpty(e._id.$in)&&r.all(e._id.$in,d._selectorIsId)?e._id.$in:null;if(e.$and&&r.isArray(e.$and))for(var t=0;t<e.$and.length;++t){var n=d._idsMatchedBySelector(e.$and[t]);if(n)return n}return null},n.addType("oid",function(e){return new d._ObjectID(e)})}.call(this),"undefined"==typeof Package&&(Package={}),Package.minimongo={LocalCollection:d,Minimongo:f,MinimongoTest:l}}();
+
+!function(){var e=Package.meteor.Meteor,t=Package.check.check,n=Package.check.Match,r=Package.random.Random,o=Package.ejson.EJSON,i=Package.json.JSON,a=Package.underscore._,s=Package.tracker.Tracker,u=Package.tracker.Deps,c=Package.logging.Log,l=Package.retry.Retry,d=Package.minimongo.LocalCollection,f=Package.minimongo.Minimongo,_,p,h,v,m,g,b,y,w,k,S,C,T;(function(){_={},p={}}).call(this),function(){h=function(){var e=document,t=window,n={},r=function(){};r.prototype.addEventListener=function(e,t){this._listeners||(this._listeners={}),e in this._listeners||(this._listeners[e]=[]);var r=this._listeners[e];-1===n.arrIndexOf(r,t)&&r.push(t)},r.prototype.removeEventListener=function(e,t){if(this._listeners&&e in this._listeners){var r=this._listeners[e],o=n.arrIndexOf(r,t);return-1!==o?void(r.length>1?this._listeners[e]=r.slice(0,o).concat(r.slice(o+1)):delete this._listeners[e]):void 0}},r.prototype.dispatchEvent=function(e){var t=e.type,n=Array.prototype.slice.call(arguments,0);if(this["on"+t]&&this["on"+t].apply(this,n),this._listeners&&t in this._listeners)for(var r=0;r<this._listeners[t].length;r++)this._listeners[t][r].apply(this,n)};var o=function(e,t){if(this.type=e,"undefined"!=typeof t)for(var n in t)t.hasOwnProperty(n)&&(this[n]=t[n])};o.prototype.toString=function(){var e=[];for(var t in this)if(this.hasOwnProperty(t)){var n=this[t];"function"==typeof n&&(n="[function]"),e.push(t+"="+n)}return"SimpleEvent("+e.join(", ")+")"};var a=function(e){var t=this;t._events=e||[],t._listeners={}};a.prototype.emit=function(e){var t=this;if(t._verifyType(e),!t._nuked){var n=Array.prototype.slice.call(arguments,1);if(t["on"+e]&&t["on"+e].apply(t,n),e in t._listeners)for(var r=0;r<t._listeners[e].length;r++)t._listeners[e][r].apply(t,n)}},a.prototype.on=function(e,t){var n=this;n._verifyType(e),n._nuked||(e in n._listeners||(n._listeners[e]=[]),n._listeners[e].push(t))},a.prototype._verifyType=function(e){var t=this;-1===n.arrIndexOf(t._events,e)&&n.log("Event "+i.stringify(e)+" not listed "+i.stringify(t._events)+" in "+t)},a.prototype.nuke=function(){var e=this;e._nuked=!0;for(var t=0;t<e._events.length;t++)delete e[e._events[t]];e._listeners={}};var s="abcdefghijklmnopqrstuvwxyz0123456789_";n.random_string=function(e,t){t=t||s.length;var n,r=[];for(n=0;e>n;n++)r.push(s.substr(Math.floor(Math.random()*t),1));return r.join("")},n.random_number=function(e){return Math.floor(Math.random()*e)},n.random_number_string=function(e){var t=(""+(e-1)).length,r=Array(t+1).join("0");return(r+n.random_number(e)).slice(-t)},n.getOrigin=function(e){e+="/";var t=e.split("/").slice(0,3);return t.join("/")},n.isSameOriginUrl=function(e,n){return n||(n=t.location.href),e.split("/").slice(0,3).join("/")===n.split("/").slice(0,3).join("/")},n.isSameOriginScheme=function(e,n){return n||(n=t.location.href),e.split(":")[0]===n.split(":")[0]},n.getParentDomain=function(e){if(/^[0-9.]*$/.test(e))return e;if(/^\[/.test(e))return e;if(!/[.]/.test(e))return e;var t=e.split(".").slice(1);return t.join(".")},n.objectExtend=function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n]);return e};var u="_jp";n.polluteGlobalNamespace=function(){u in t||(t[u]={})},n.closeFrame=function(e,t){return"c"+i.stringify([e,t])},n.userSetCode=function(e){return 1e3===e||e>=3e3&&4999>=e},n.countRTO=function(e){var t;return t=e>100?3*e:e+200},n.log=function(){t.console&&console.log&&console.log.apply&&console.log.apply(console,arguments)},n.bind=function(e,t){return e.bind?e.bind(t):function(){return e.apply(t,arguments)}},n.flatUrl=function(e){return-1===e.indexOf("?")&&-1===e.indexOf("#")},n.amendUrl=function(t,r){var o;if(void 0===r)o=e.location;else{var i=/^([a-z0-9.+-]+:)/i.exec(r);if(i){var a=i[0].toLowerCase(),s=r.substring(a.length),u=/[a-z0-9\.-]+(:[0-9]+)?/.exec(s);if(u)var c=u[0]}if(!a||!c)throw new Error("relativeTo must be an absolute url");o={protocol:a,host:c}}if(!t)throw new Error("Wrong url for SockJS");if(!n.flatUrl(t))throw new Error("Only basic urls are supported in SockJS");0===t.indexOf("//")&&(t=o.protocol+t),0===t.indexOf("/")&&(t=o.protocol+"//"+o.host+t),t=t.replace(/[/]+$/,"");var l=t.split("/");return("http:"===l[0]&&/:80$/.test(l[2])||"https:"===l[0]&&/:443$/.test(l[2]))&&(l[2]=l[2].replace(/:(80|443)$/,"")),t=l.join("/")},n.arrIndexOf=function(e,t){for(var n=0;n<e.length;n++)if(e[n]===t)return n;return-1},n.arrSkip=function(e,t){var r=n.arrIndexOf(e,t);if(-1===r)return e.slice();var o=e.slice(0,r);return o.concat(e.slice(r+1))},n.isArray=Array.isArray||function(e){return{}.toString.call(e).indexOf("Array")>=0},n.delay=function(e,t){return"function"==typeof e&&(t=e,e=0),setTimeout(t,e)};var c=/[\\\"\x00-\x1f\x7f-\x9f\u00ad\u0600-\u0604\u070f\u17b4\u17b5\u200c-\u200f\u2028-\u202f\u2060-\u206f\ufeff\ufff0-\uffff]/g,l={"\x00":"\\u0000","":"\\u0001","":"\\u0002","":"\\u0003","":"\\u0004","":"\\u0005","":"\\u0006","":"\\u0007","\b":"\\b"," ":"\\t","\n":"\\n"," ":"\\u000b","\f":"\\f","\r":"\\r","":"\\u000e","":"\\u000f","":"\\u0010","":"\\u0011","":"\\u0012","":"\\u0013","":"\\u0014","":"\\u0015","":"\\u0016","":"\\u0017","":"\\u0018","":"\\u0019","":"\\u001a","":"\\u001b","":"\\u001c","":"\\u001d","":"\\u001e","":"\\u001f",'"':'\\"',"\\":"\\\\","":"\\u007f","€":"\\u0080","":"\\u0081","‚":"\\u0082","ƒ":"\\u0083","„":"\\u0084","…":"\\u0085","†":"\\u0086","‡":"\\u0087","ˆ":"\\u0088","‰":"\\u0089","Š":"\\u008a","‹":"\\u008b","Œ":"\\u008c","":"\\u008d","Ž":"\\u008e","":"\\u008f","":"\\u0090","‘":"\\u0091","’":"\\u0092","“":"\\u0093","”":"\\u0094","•":"\\u0095","–":"\\u0096","—":"\\u0097","˜":"\\u0098","™":"\\u0099","š":"\\u009a","›":"\\u009b","œ":"\\u009c","":"\\u009d","ž":"\\u009e","Ÿ":"\\u009f","­":"\\u00ad","؀":"\\u0600","؁":"\\u0601","؂":"\\u0602","؃":"\\u0603","؄":"\\u0604","܏":"\\u070f","឴":"\\u17b4","឵":"\\u17b5","‌":"\\u200c","‍":"\\u200d","‎":"\\u200e","‏":"\\u200f","\u2028":"\\u2028","\u2029":"\\u2029","‪":"\\u202a","‫":"\\u202b","‬":"\\u202c","‭":"\\u202d","‮":"\\u202e"," ":"\\u202f","⁠":"\\u2060","⁡":"\\u2061","⁢":"\\u2062","⁣":"\\u2063","⁤":"\\u2064","⁥":"\\u2065","⁦":"\\u2066","⁧":"\\u2067","⁨":"\\u2068","⁩":"\\u2069","":"\\u206a","":"\\u206b","":"\\u206c","":"\\u206d","":"\\u206e","":"\\u206f","":"\\ufeff","￰":"\\ufff0","￱":"\\ufff1","￲":"\\ufff2","￳":"\\ufff3","￴":"\\ufff4","￵":"\\ufff5","￶":"\\ufff6","￷":"\\ufff7","￸":"\\ufff8","":"\\ufff9","":"\\ufffa","":"\\ufffb","":"\\ufffc","�":"\\ufffd","￾":"\\ufffe","￿":"\\uffff"},d=/[\x00-\x1f\ud800-\udfff\ufffe\uffff\u0300-\u0333\u033d-\u0346\u034a-\u034c\u0350-\u0352\u0357-\u0358\u035c-\u0362\u0374\u037e\u0387\u0591-\u05af\u05c4\u0610-\u0617\u0653-\u0654\u0657-\u065b\u065d-\u065e\u06df-\u06e2\u06eb-\u06ec\u0730\u0732-\u0733\u0735-\u0736\u073a\u073d\u073f-\u0741\u0743\u0745\u0747\u07eb-\u07f1\u0951\u0958-\u095f\u09dc-\u09dd\u09df\u0a33\u0a36\u0a59-\u0a5b\u0a5e\u0b5c-\u0b5d\u0e38-\u0e39\u0f43\u0f4d\u0f52\u0f57\u0f5c\u0f69\u0f72-\u0f76\u0f78\u0f80-\u0f83\u0f93\u0f9d\u0fa2\u0fa7\u0fac\u0fb9\u1939-\u193a\u1a17\u1b6b\u1cda-\u1cdb\u1dc0-\u1dcf\u1dfc\u1dfe\u1f71\u1f73\u1f75\u1f77\u1f79\u1f7b\u1f7d\u1fbb\u1fbe\u1fc9\u1fcb\u1fd3\u1fdb\u1fe3\u1feb\u1fee-\u1fef\u1ff9\u1ffb\u1ffd\u2000-\u2001\u20d0-\u20d1\u20d4-\u20d7\u20e7-\u20e9\u2126\u212a-\u212b\u2329-\u232a\u2adc\u302b-\u302c\uaab2-\uaab3\uf900-\ufa0d\ufa10\ufa12\ufa15-\ufa1e\ufa20\ufa22\ufa25-\ufa26\ufa2a-\ufa2d\ufa30-\ufa6d\ufa70-\ufad9\ufb1d\ufb1f\ufb2a-\ufb36\ufb38-\ufb3c\ufb3e\ufb40-\ufb41\ufb43-\ufb44\ufb46-\ufb4e\ufff0-\uffff]/g,f,_=i&&i.stringify||function(e){return c.lastIndex=0,c.test(e)&&(e=e.replace(c,function(e){return l[e]})),'"'+e+'"'},p=function(e){var t,n={},r=[];for(t=0;65536>t;t++)r.push(String.fromCharCode(t));return e.lastIndex=0,r.join("").replace(e,function(e){return n[e]="\\u"+("0000"+e.charCodeAt(0).toString(16)).slice(-4),""}),e.lastIndex=0,n};n.quote=function(e){var t=_(e);return d.lastIndex=0,d.test(t)?(f||(f=p(d)),t.replace(d,function(e){return f[e]})):t};var h=["websocket","xdr-streaming","xhr-streaming","iframe-eventsource","iframe-htmlfile","xdr-polling","xhr-polling","iframe-xhr-polling","jsonp-polling"];n.probeProtocols=function(){for(var e={},t=0;t<h.length;t++){var n=h[t];e[n]=T[n]&&T[n].enabled()}return e},n.detectProtocols=function(e,t,n){var r={},o=[];t||(t=h);for(var i=0;i<t.length;i++){var a=t[i];r[a]=e[a]}var s=function(e){var t=e.shift();r[t]?o.push(t):e.length>0&&s(e)};return n.websocket!==!1&&s(["websocket"]),r["xhr-streaming"]&&!n.null_origin?o.push("xhr-streaming"):!r["xdr-streaming"]||n.cookie_needed||n.null_origin?s(["iframe-eventsource","iframe-htmlfile"]):o.push("xdr-streaming"),r["xhr-polling"]&&!n.null_origin?o.push("xhr-polling"):!r["xdr-polling"]||n.cookie_needed||n.null_origin?s(["iframe-xhr-polling","jsonp-polling"]):o.push("xdr-polling"),o};var v="_sockjs_global";n.createHook=function(){var e="a"+n.random_string(8);if(!(v in t)){var r={};t[v]=function(e){return e in r||(r[e]={id:e,del:function(){delete r[e]}}),r[e]}}return t[v](e)},n.attachMessage=function(e){n.attachEvent("message",e)},n.attachEvent=function(n,r){"undefined"!=typeof t.addEventListener?t.addEventListener(n,r,!1):(e.attachEvent("on"+n,r),t.attachEvent("on"+n,r))},n.detachMessage=function(e){n.detachEvent("message",e)},n.detachEvent=function(n,r){"undefined"!=typeof t.addEventListener?t.removeEventListener(n,r,!1):(e.detachEvent("on"+n,r),t.detachEvent("on"+n,r))};var m={},g=!1,b=function(){for(var e in m)m[e](),delete m[e]},y=function(){g||(g=!0,b())};n.attachEvent("unload",y),n.unload_add=function(e){var t=n.random_string(8);return m[t]=e,g&&n.delay(b),t},n.unload_del=function(e){e in m&&delete m[e]},n.createIframe=function(t,r){var o=e.createElement("iframe"),i,a,s=function(){clearTimeout(i);try{o.onload=null}catch(e){}o.onerror=null},u=function(){o&&(s(),setTimeout(function(){o&&o.parentNode.removeChild(o),o=null},0),n.unload_del(a))},c=function(e){o&&(u(),r(e))},l=function(e,t){try{o&&o.contentWindow&&o.contentWindow.postMessage(e,t)}catch(n){}};return o.src=t,o.style.display="none",o.style.position="absolute",o.onerror=function(){c("onerror")},o.onload=function(){clearTimeout(i),i=setTimeout(function(){c("onload timeout")},2e3)},e.body.appendChild(o),i=setTimeout(function(){c("timeout")},15e3),a=n.unload_add(u),{post:l,cleanup:u,loaded:s}},n.createHtmlfile=function(e,r){var o=new ActiveXObject("htmlfile"),i,a,s,c=function(){clearTimeout(i)},l=function(){o&&(c(),n.unload_del(a),s.parentNode.removeChild(s),s=o=null,CollectGarbage())},d=function(e){o&&(l(),r(e))},f=function(e,t){try{s&&s.contentWindow&&s.contentWindow.postMessage(e,t)}catch(n){}};o.open(),o.write('<html><script>document.domain="'+document.domain+'";</script></html>'),o.close(),o.parentWindow[u]=t[u];var _=o.createElement("div");return o.body.appendChild(_),s=o.createElement("iframe"),_.appendChild(s),s.src=e,i=setTimeout(function(){d("timeout")},15e3),a=n.unload_add(l),{post:f,cleanup:l,loaded:c}};var w=function(){};w.prototype=new a(["chunk","finish"]),w.prototype._start=function(e,r,o,i){var a=this;try{a.xhr=new XMLHttpRequest}catch(s){}if(!a.xhr)try{a.xhr=new t.ActiveXObject("Microsoft.XMLHTTP")}catch(s){}(t.ActiveXObject||t.XDomainRequest)&&(r+=(-1===r.indexOf("?")?"?":"&")+"t="+ +new Date),a.unload_ref=n.unload_add(function(){a._cleanup(!0)});try{a.xhr.open(e,r,!0)}catch(u){return a.emit("finish",0,""),void a._cleanup()}if(i&&i.no_credentials||(a.xhr.withCredentials="true"),i&&i.headers)for(var c in i.headers)a.xhr.setRequestHeader(c,i.headers[c]);a.xhr.onreadystatechange=function(){if(a.xhr){var e=a.xhr;switch(e.readyState){case 3:try{var t=e.status,n=e.responseText}catch(e){}1223===t&&(t=204),n&&n.length>0&&a.emit("chunk",t,n);break;case 4:var t=e.status;1223===t&&(t=204),a.emit("finish",t,e.responseText),a._cleanup(!1)}}},a.xhr.send(o)},w.prototype._cleanup=function(e){var t=this;if(t.xhr){if(n.unload_del(t.unload_ref),t.xhr.onreadystatechange=function(){},e)try{t.xhr.abort()}catch(r){}t.unload_ref=t.xhr=null}},w.prototype.close=function(){var e=this;e.nuke(),e._cleanup(!0)};var k=n.XHRCorsObject=function(){var e=this,t=arguments;n.delay(function(){e._start.apply(e,t)})};k.prototype=new w;var S=n.XHRLocalObject=function(e,t,r){var o=this;n.delay(function(){o._start(e,t,r,{no_credentials:!0})})};S.prototype=new w;var C=n.XDRObject=function(e,t,r){var o=this;n.delay(function(){o._start(e,t,r)})};C.prototype=new a(["chunk","finish"]),C.prototype._start=function(e,t,r){var o=this,i=new XDomainRequest;t+=(-1===t.indexOf("?")?"?":"&")+"t="+ +new Date;var a=i.ontimeout=i.onerror=function(){o.emit("finish",0,""),o._cleanup(!1)};i.onprogress=function(){o.emit("chunk",200,i.responseText)},i.onload=function(){o.emit("finish",200,i.responseText),o._cleanup(!1)},o.xdr=i,o.unload_ref=n.unload_add(function(){o._cleanup(!0)});try{o.xdr.open(e,t),o.xdr.send(r)}catch(s){a()}},C.prototype._cleanup=function(e){var t=this;if(t.xdr){if(n.unload_del(t.unload_ref),t.xdr.ontimeout=t.xdr.onerror=t.xdr.onprogress=t.xdr.onload=null,e)try{t.xdr.abort()}catch(r){}t.unload_ref=t.xdr=null}},C.prototype.close=function(){var e=this;e.nuke(),e._cleanup(!0)},n.isXHRCorsCapable=function(){return t.XMLHttpRequest&&"withCredentials"in new XMLHttpRequest?1:t.XDomainRequest&&e.domain?2:B.enabled()?3:4};var T=function(e,t,r){if(!(this instanceof T))return new T(e,t,r);var o=this,i;o._options={devel:!1,debug:!1,protocols_whitelist:[],info:void 0,rtt:void 0},r&&n.objectExtend(o._options,r),o._base_url=n.amendUrl(e),o._server=o._options.server||n.random_number_string(1e3),o._options.protocols_whitelist&&o._options.protocols_whitelist.length?i=o._options.protocols_whitelist:(i="string"==typeof t&&t.length>0?[t]:n.isArray(t)?t:null,i&&o._debug('Deprecated API: Use "protocols_whitelist" option instead of supplying protocol list as a second parameter to SockJS constructor.')),o._protocols=[],o.protocol=null,o.readyState=T.CONNECTING,o._ir=q(o._base_url),o._ir.onfinish=function(e,t){o._ir=null,e?(o._options.info&&(e=n.objectExtend(e,o._options.info)),o._options.rtt&&(t=o._options.rtt),o._applyInfo(e,t,i),o._didClose()):o._didClose(1002,"Can't connect to server",!0)}};T.prototype=new r,T.version="0.3.4",T.CONNECTING=0,T.OPEN=1,T.CLOSING=2,T.CLOSED=3,T.prototype._debug=function(){this._options.debug&&n.log.apply(n,arguments)},T.prototype._dispatchOpen=function(){var e=this;e.readyState===T.CONNECTING?(e._transport_tref&&(clearTimeout(e._transport_tref),e._transport_tref=null),e.readyState=T.OPEN,e.dispatchEvent(new o("open"))):e._didClose(1006,"Server lost session")},T.prototype._dispatchMessage=function(e){var t=this;t.readyState===T.OPEN&&t.dispatchEvent(new o("message",{data:e}))},T.prototype._dispatchHeartbeat=function(e){var t=this;t.readyState===T.OPEN&&t.dispatchEvent(new o("heartbeat",{}))},T.prototype._didClose=function(e,t,r){var i=this;if(i.readyState!==T.CONNECTING&&i.readyState!==T.OPEN&&i.readyState!==T.CLOSING)throw new Error("INVALID_STATE_ERR");i._ir&&(i._ir.nuke(),i._ir=null),i._transport&&(i._transport.doCleanup(),i._transport=null);var a=new o("close",{code:e,reason:t,wasClean:n.userSetCode(e)});if(!n.userSetCode(e)&&i.readyState===T.CONNECTING&&!r){if(i._try_next_protocol(a))return;a=new o("close",{code:2e3,reason:"All transports failed",wasClean:!1,last_event:a})}i.readyState=T.CLOSED,n.delay(function(){i.dispatchEvent(a)})},T.prototype._didMessage=function(e){var t=this,n=e.slice(0,1);switch(n){case"o":t._dispatchOpen();break;case"a":for(var r=i.parse(e.slice(1)||"[]"),o=0;o<r.length;o++)t._dispatchMessage(r[o]);break;case"m":var r=i.parse(e.slice(1)||"null");t._dispatchMessage(r);break;case"c":var r=i.parse(e.slice(1)||"[]");t._didClose(r[0],r[1]);break;case"h":t._dispatchHeartbeat()}},T.prototype._try_next_protocol=function(t){var r=this;for(r.protocol&&(r._debug("Closed transport:",r.protocol,""+t),r.protocol=null),r._transport_tref&&(clearTimeout(r._transport_tref),r._transport_tref=null);;){var o=r.protocol=r._protocols.shift();if(!o)return!1;if(T[o]&&T[o].need_body===!0&&(!e.body||"undefined"!=typeof e.readyState&&"complete"!==e.readyState))return r._protocols.unshift(o),r.protocol="waiting-for-load",n.attachEvent("load",function(){r._try_next_protocol()}),!0;if(T[o]&&T[o].enabled(r._options)){var i=T[o].roundTrips||1,a=(r._options.rto||0)*i||5e3;r._transport_tref=n.delay(a,function(){r.readyState===T.CONNECTING&&r._didClose(2007,"Transport timeouted")});var s=n.random_string(8),u=r._base_url+"/"+r._server+"/"+s;return r._debug("Opening transport:",o," url:"+u," RTO:"+r._options.rto),r._transport=new T[o](r,u,r._base_url),!0}r._debug("Skipping transport:",o)}},T.prototype.close=function(e,t){var r=this;if(e&&!n.userSetCode(e))throw new Error("INVALID_ACCESS_ERR");return r.readyState!==T.CONNECTING&&r.readyState!==T.OPEN?!1:(r.readyState=T.CLOSING,r._didClose(e||1e3,t||"Normal closure"),!0)},T.prototype.send=function(e){var t=this;if(t.readyState===T.CONNECTING)throw new Error("INVALID_STATE_ERR");return t.readyState===T.OPEN&&t._transport.doSend(n.quote(""+e)),!0},T.prototype._applyInfo=function(t,r,o){var i=this;i._options.info=t,i._options.rtt=r,i._options.rto=n.countRTO(r),i._options.info.null_origin=!e.domain,t.base_url&&(i._base_url=n.amendUrl(t.base_url,i._base_url));var a=n.probeProtocols();i._protocols=n.detectProtocols(a,o,t),n.isSameOriginScheme(i._base_url)||2!==n.isXHRCorsCapable()||(i._protocols=["jsonp-polling"])};var E=T.websocket=function(e,r){var o=this,i=r+"/websocket";i="https"===i.slice(0,5)?"wss"+i.slice(5):"ws"+i.slice(4),o.ri=e,o.url=i;var a=t.WebSocket||t.MozWebSocket;o.ws=new a(o.url),o.ws.onmessage=function(e){o.ri._didMessage(e.data)},o.unload_ref=n.unload_add(function(){o.ws.close()}),o.ws.onclose=function(){o.ri._didMessage(n.closeFrame(1006,"WebSocket connection broken"))}};E.prototype.doSend=function(e){this.ws.send("["+e+"]")},E.prototype.doCleanup=function(){var e=this,t=e.ws;t&&(t.onmessage=t.onclose=null,t.close(),n.unload_del(e.unload_ref),e.unload_ref=e.ri=e.ws=null)},E.enabled=function(){return!(!t.WebSocket&&!t.MozWebSocket)},E.roundTrips=2;var O=function(){};O.prototype.send_constructor=function(e){var t=this;t.send_buffer=[],t.sender=e},O.prototype.doSend=function(e){var t=this;t.send_buffer.push(e),t.send_stop||t.send_schedule()},O.prototype.send_schedule_wait=function(){var e=this,t;e.send_stop=function(){e.send_stop=null,clearTimeout(t)},t=n.delay(25,function(){e.send_stop=null,e.send_schedule()})},O.prototype.send_schedule=function(){var e=this;if(e.send_buffer.length>0){var t="["+e.send_buffer.join(",")+"]";e.send_stop=e.sender(e.trans_url,t,function(t,n){e.send_stop=null,t===!1?e.ri._didClose(1006,"Sending error "+n):e.send_schedule_wait()}),e.send_buffer=[]}},O.prototype.send_destructor=function(){var e=this;e._send_stop&&e._send_stop(),e._send_stop=null};var x=function(t,r,o){var i=this;if(!("_send_form"in i)){var a=i._send_form=e.createElement("form"),s=i._send_area=e.createElement("textarea");s.name="d",a.style.display="none",a.style.position="absolute",a.method="POST",a.enctype="application/x-www-form-urlencoded",a.acceptCharset="UTF-8",a.appendChild(s),e.body.appendChild(a)}var a=i._send_form,s=i._send_area,u="a"+n.random_string(8);a.target=u,a.action=t+"/jsonp_send?i="+u;var c;try{c=e.createElement('<iframe name="'+u+'">')}catch(l){c=e.createElement("iframe"),c.name=u}c.id=u,a.appendChild(c),c.style.display="none";try{s.value=r}catch(d){n.log("Your browser is seriously broken. Go home! "+d.message)}a.submit();var f=function(e){c.onerror&&(c.onreadystatechange=c.onerror=c.onload=null,n.delay(500,function(){c.parentNode.removeChild(c),c=null}),s.value="",o(!0))};return c.onerror=c.onload=f,c.onreadystatechange=function(e){"complete"==c.readyState&&f()},f},I=function(e){return function(t,n,r){var o=new e("POST",t+"/xhr_send",n);return o.onfinish=function(e,t){r(200===e||204===e,"http status "+e)},function(e){r(!1,e)}}},M=function(t,r){var o,i=e.createElement("script"),a,s=function(e){a&&(a.parentNode.removeChild(a),a=null),i&&(clearTimeout(o),i.parentNode.removeChild(i),i.onreadystatechange=i.onerror=i.onload=i.onclick=null,i=null,r(e),r=null)},u=!1,c=null;if(i.id="a"+n.random_string(8),i.src=t,i.type="text/javascript",i.charset="UTF-8",i.onerror=function(e){c||(c=setTimeout(function(){u||s(n.closeFrame(1006,"JSONP script loaded abnormally (onerror)"))},1e3))},i.onload=function(e){s(n.closeFrame(1006,"JSONP script loaded abnormally (onload)"))},i.onreadystatechange=function(e){if(/loaded|closed/.test(i.readyState)){if(i&&i.htmlFor&&i.onclick){u=!0;try{i.onclick()}catch(t){}}i&&s(n.closeFrame(1006,"JSONP script loaded abnormally (onreadystatechange)"))}},"undefined"==typeof i.async&&e.attachEvent)if(/opera/i.test(navigator.userAgent))a=e.createElement("script"),a.text="try{var a = document.getElementById('"+i.id+"'); if(a)a.onerror();}catch(x){};",i.async=a.async=!1;else{try{i.htmlFor=i.id,i.event="onclick"}catch(l){}i.async=!0}"undefined"!=typeof i.async&&(i.async=!0),o=setTimeout(function(){s(n.closeFrame(1006,"JSONP script loaded abnormally (timeout)"))},35e3);var d=e.getElementsByTagName("head")[0];return d.insertBefore(i,d.firstChild),a&&d.insertBefore(a,d.firstChild),s},D=T["jsonp-polling"]=function(e,t){n.polluteGlobalNamespace();var r=this;r.ri=e,r.trans_url=t,r.send_constructor(x),r._schedule_recv()};D.prototype=new O,D.prototype._schedule_recv=function(){var e=this,t=function(t){e._recv_stop=null,t&&(e._is_closing||e.ri._didMessage(t)),e._is_closing||e._schedule_recv()};e._recv_stop=R(e.trans_url+"/jsonp",M,t)},D.enabled=function(){return!0},D.need_body=!0,D.prototype.doCleanup=function(){var e=this;e._is_closing=!0,e._recv_stop&&e._recv_stop(),e.ri=e._recv_stop=null,e.send_destructor()};var R=function(e,r,o){var i="a"+n.random_string(6),a=e+"?c="+escape(u+"."+i),s=0,c=function(e){switch(s){case 0:delete t[u][i],o(e);break;case 1:o(e),s=2;break;case 2:delete t[u][i]}},l=r(a,c);t[u][i]=l;var d=function(){t[u][i]&&(s=1,t[u][i](n.closeFrame(1e3,"JSONP user aborted read")))};return d},P=function(){};P.prototype=new O,P.prototype.run=function(e,t,n,r,o){var i=this;i.ri=e,i.trans_url=t,i.send_constructor(I(o)),i.poll=new Z(e,r,t+n,o)},P.prototype.doCleanup=function(){var e=this;e.poll&&(e.poll.abort(),e.poll=null)};var N=T["xhr-streaming"]=function(e,t){this.run(e,t,"/xhr_streaming",ot,n.XHRCorsObject)};N.prototype=new P,N.enabled=function(){return t.XMLHttpRequest&&"withCredentials"in new XMLHttpRequest&&!/opera/i.test(navigator.userAgent)},N.roundTrips=2,N.need_body=!0;var j=T["xdr-streaming"]=function(e,t){this.run(e,t,"/xhr_streaming",ot,n.XDRObject)};j.prototype=new P,j.enabled=function(){return!!t.XDomainRequest},j.roundTrips=2;var U=T["xhr-polling"]=function(e,t){this.run(e,t,"/xhr",ot,n.XHRCorsObject)};U.prototype=new P,U.enabled=N.enabled,U.roundTrips=2;var A=T["xdr-polling"]=function(e,t){this.run(e,t,"/xhr",ot,n.XDRObject)};A.prototype=new P,A.enabled=j.enabled,A.roundTrips=2;var B=function(){};B.prototype.i_constructor=function(e,t,r){var o=this;o.ri=e,o.origin=n.getOrigin(r),o.base_url=r,o.trans_url=t;var i=r+"/iframe.html";o.ri._options.devel&&(i+="?t="+ +new Date),o.window_id=n.random_string(8),i+="#"+o.window_id,o.iframeObj=n.createIframe(i,function(e){o.ri._didClose(1006,"Unable to load an iframe ("+e+")")}),o.onmessage_cb=n.bind(o.onmessage,o),n.attachMessage(o.onmessage_cb)},B.prototype.doCleanup=function(){var e=this;if(e.iframeObj){n.detachMessage(e.onmessage_cb);try{e.iframeObj.iframe.contentWindow&&e.postMessage("c")}catch(t){}e.iframeObj.cleanup(),e.iframeObj=null,e.onmessage_cb=e.iframeObj=null}},B.prototype.onmessage=function(e){var t=this;if(e.origin===t.origin){var n=e.data.slice(0,8),r=e.data.slice(8,9),o=e.data.slice(9);if(n===t.window_id)switch(r){case"s":t.iframeObj.loaded(),t.postMessage("s",i.stringify([T.version,t.protocol,t.trans_url,t.base_url]));break;case"t":t.ri._didMessage(o)}}},B.prototype.postMessage=function(e,t){var n=this;n.iframeObj.post(n.window_id+e+(t||""),n.origin)},B.prototype.doSend=function(e){this.postMessage("m",e)},B.enabled=function(){var e=navigator&&navigator.userAgent&&-1!==navigator.userAgent.indexOf("Konqueror");return("function"==typeof t.postMessage||"object"==typeof t.postMessage)&&!e};var H,L=function(e,r){parent!==t?parent.postMessage(H+e+(r||""),"*"):n.log("Can't postMessage, no parent window.",e,r)},F=function(){};F.prototype._didClose=function(e,t){L("t",n.closeFrame(e,t))},F.prototype._didMessage=function(e){L("t",e)},F.prototype._doSend=function(e){this._transport.doSend(e)},F.prototype._doCleanup=function(){this._transport.doCleanup()},n.parent_origin=void 0,T.bootstrap_iframe=function(){var r;H=e.location.hash.slice(1);var o=function(e){if(e.source===parent&&("undefined"==typeof n.parent_origin&&(n.parent_origin=e.origin),e.origin===n.parent_origin)){var o=e.data.slice(0,8),a=e.data.slice(8,9),s=e.data.slice(9);if(o===H)switch(a){case"s":var u=i.parse(s),c=u[0],l=u[1],d=u[2],f=u[3];if(c!==T.version&&n.log('Incompatibile SockJS! Main site uses: "'+c+'", the iframe: "'+T.version+'".'),!n.flatUrl(d)||!n.flatUrl(f))return void n.log("Only basic urls are supported in SockJS");if(!n.isSameOriginUrl(d)||!n.isSameOriginUrl(f))return void n.log("Can't connect to different domain from within an iframe. ("+i.stringify([t.location.href,d,f])+")");r=new F,r._transport=new F[l](r,d,f);break;case"m":r._doSend(s);break;case"c":r&&r._doCleanup(),r=null}}};n.attachMessage(o),L("s")};var X=function(e,t){var r=this;n.delay(function(){r.doXhr(e,t)})};X.prototype=new a(["finish"]),X.prototype.doXhr=function(e,t){var r=this,o=(new Date).getTime(),a=new t("GET",e+"/info?cb="+n.random_string(10)),s=n.delay(8e3,function(){a.ontimeout()});a.onfinish=function(e,t){if(clearTimeout(s),s=null,200===e){var n=(new Date).getTime()-o,a=i.parse(t);"object"!=typeof a&&(a={}),r.emit("finish",a,n)}else r.emit("finish")},a.ontimeout=function(){a.close(),r.emit("finish")}};var V=function(t){var r=this,o=function(){var e=new B;e.protocol="w-iframe-info-receiver";var n=function(t){if("string"==typeof t&&"m"===t.substr(0,1)){var n=i.parse(t.substr(1)),o=n[0],a=n[1];r.emit("finish",o,a)}else r.emit("finish");e.doCleanup(),e=null},o={_options:{},_didClose:n,_didMessage:n};e.i_constructor(o,t,t)};e.body?o():n.attachEvent("load",o)};V.prototype=new a(["finish"]);var W=function(){var e=this;n.delay(function(){e.emit("finish",{},2e3)})};W.prototype=new a(["finish"]);var q=function(e){if(n.isSameOriginUrl(e))return new X(e,n.XHRLocalObject);switch(n.isXHRCorsCapable()){case 1:return new X(e,n.XHRLocalObject);case 2:return n.isSameOriginScheme(e)?new X(e,n.XDRObject):new W;case 3:return new V(e);default:return new W}},G=F["w-iframe-info-receiver"]=function(e,t,r){var o=new X(r,n.XHRLocalObject);o.onfinish=function(t,n){e._didMessage("m"+i.stringify([t,n])),e._didClose()}};G.prototype.doCleanup=function(){};var J=T["iframe-eventsource"]=function(){var e=this;e.protocol="w-iframe-eventsource",e.i_constructor.apply(e,arguments)};J.prototype=new B,J.enabled=function(){return"EventSource"in t&&B.enabled()},J.need_body=!0,J.roundTrips=3;var Q=F["w-iframe-eventsource"]=function(e,t){this.run(e,t,"/eventsource",et,n.XHRLocalObject)};Q.prototype=new P;var z=T["iframe-xhr-polling"]=function(){var e=this;e.protocol="w-iframe-xhr-polling",e.i_constructor.apply(e,arguments)};z.prototype=new B,z.enabled=function(){return t.XMLHttpRequest&&B.enabled()},z.need_body=!0,z.roundTrips=3;var $=F["w-iframe-xhr-polling"]=function(e,t){this.run(e,t,"/xhr",ot,n.XHRLocalObject)};$.prototype=new P;var Y=T["iframe-htmlfile"]=function(){var e=this;e.protocol="w-iframe-htmlfile",e.i_constructor.apply(e,arguments)};Y.prototype=new B,Y.enabled=function(){return B.enabled()},Y.need_body=!0,Y.roundTrips=3;var K=F["w-iframe-htmlfile"]=function(e,t){this.run(e,t,"/htmlfile",rt,n.XHRLocalObject)};K.prototype=new P;var Z=function(e,t,n,r){var o=this;o.ri=e,o.Receiver=t,o.recv_url=n,o.AjaxObject=r,o._scheduleRecv()};Z.prototype._scheduleRecv=function(){var e=this,t=e.poll=new e.Receiver(e.recv_url,e.AjaxObject),n=0;t.onmessage=function(t){n+=1,e.ri._didMessage(t.data)},t.onclose=function(n){e.poll=t=t.onmessage=t.onclose=null,e.poll_is_closing||("permanent"===n.reason?e.ri._didClose(1006,"Polling error ("+n.reason+")"):e._scheduleRecv())}},Z.prototype.abort=function(){var e=this;e.poll_is_closing=!0,e.poll&&e.poll.abort()};var et=function(e){var t=this,r=new EventSource(e);r.onmessage=function(e){t.dispatchEvent(new o("message",{data:unescape(e.data)}))},t.es_close=r.onerror=function(e,i){var a=i?"user":2!==r.readyState?"network":"permanent";t.es_close=r.onmessage=r.onerror=null,r.close(),r=null,n.delay(200,function(){t.dispatchEvent(new o("close",{reason:a}))})}};et.prototype=new r,et.prototype.abort=function(){var e=this;e.es_close&&e.es_close({},!0)};var tt,nt=function(){if(void 0===tt)if("ActiveXObject"in t)try{tt=!!new ActiveXObject("htmlfile")}catch(e){}else tt=!1;return tt},rt=function(e){var r=this;n.polluteGlobalNamespace(),r.id="a"+n.random_string(6,26),e+=(-1===e.indexOf("?")?"?":"&")+"c="+escape(u+"."+r.id);var i=nt()?n.createHtmlfile:n.createIframe,a;t[u][r.id]={start:function(){a.loaded()},message:function(e){r.dispatchEvent(new o("message",{data:e}))},stop:function(){r.iframe_close({},"network")}},r.iframe_close=function(e,n){a.cleanup(),r.iframe_close=a=null,delete t[u][r.id],r.dispatchEvent(new o("close",{reason:n}))},a=i(e,function(e){r.iframe_close({},"permanent")})};rt.prototype=new r,rt.prototype.abort=function(){var e=this;e.iframe_close&&e.iframe_close({},"user")};var ot=function(e,t){var n=this,r=0;n.xo=new t("POST",e,null),n.xo.onchunk=function(e,t){if(200===e)for(;;){var i=t.slice(r),a=i.indexOf("\n");if(-1===a)break;r+=a+1;var s=i.slice(0,a);n.dispatchEvent(new o("message",{data:s}))}},n.xo.onfinish=function(e,t){n.xo.onchunk(e,t),n.xo=null;var r=200===e?"network":"permanent";n.dispatchEvent(new o("close",{reason:r}))}};return ot.prototype=new r,ot.prototype.abort=function(){var e=this;e.xo&&(e.xo.close(),e.dispatchEvent(new o("close",{reason:"user"})),e.xo=null)},T.getUtils=function(){return n},T.getIframeTransport=function(){return B},T}(),"_sockjs_onload"in window&&setTimeout(_sockjs_onload,1),"function"==typeof define&&define.amd&&define("sockjs",[],function(){return h})}.call(this),function(){p.ClientStream=function(e,t){var n=this;n.options=a.extend({retry:!0},t),n._initCommon(n.options),n.HEARTBEAT_TIMEOUT=1e5,n.rawUrl=e,n.socket=null,n.heartbeatTimer=null,"undefined"!=typeof window&&window.addEventListener&&window.addEventListener("online",a.bind(n._online,n),!1),n._launchConnection()},a.extend(p.ClientStream.prototype,{send:function(e){var t=this;t.currentStatus.connected&&t.socket.send(e)},_changeUrl:function(e){var t=this;t.rawUrl=e},_connected:function(){var e=this;e.connectionTimer&&(clearTimeout(e.connectionTimer),e.connectionTimer=null),e.currentStatus.connected||(e.currentStatus.status="connected",e.currentStatus.connected=!0,e.currentStatus.retryCount=0,e.statusChanged(),a.each(e.eventCallbacks.reset,function(e){e()}))},_cleanup:function(e){var t=this;t._clearConnectionAndHeartbeatTimers(),t.socket&&(t.socket.onmessage=t.socket.onclose=t.socket.onerror=t.socket.onheartbeat=function(){},t.socket.close(),t.socket=null),a.each(t.eventCallbacks.disconnect,function(t){t(e)})},_clearConnectionAndHeartbeatTimers:function(){var e=this;e.connectionTimer&&(clearTimeout(e.connectionTimer),e.connectionTimer=null),e.heartbeatTimer&&(clearTimeout(e.heartbeatTimer),e.heartbeatTimer=null)},_heartbeat_timeout:function(){var t=this;e._debug("Connection timeout. No sockjs heartbeat received."),t._lostConnection(new _.ConnectionError("Heartbeat timed out"))},_heartbeat_received:function(){var e=this;e._forcedToDisconnect||(e.heartbeatTimer&&clearTimeout(e.heartbeatTimer),e.heartbeatTimer=setTimeout(a.bind(e._heartbeat_timeout,e),e.HEARTBEAT_TIMEOUT))},_sockjsProtocolsWhitelist:function(){var e=["xdr-polling","xhr-polling","iframe-xhr-polling","jsonp-polling"],t=navigator&&/iPhone|iPad|iPod/.test(navigator.userAgent)&&/OS 4_|OS 5_/.test(navigator.userAgent);
+return t||(e=["websocket"].concat(e)),e},_launchConnection:function(){var t=this;t._cleanup();var n=a.extend({protocols_whitelist:t._sockjsProtocolsWhitelist()},t.options._sockjsOptions);t.socket=new h(v(t.rawUrl),void 0,n),t.socket.onopen=function(e){t._connected()},t.socket.onmessage=function(e){t._heartbeat_received(),t.currentStatus.connected&&a.each(t.eventCallbacks.message,function(t){t(e.data)})},t.socket.onclose=function(){t._lostConnection()},t.socket.onerror=function(){e._debug("stream error",a.toArray(arguments),(new Date).toDateString())},t.socket.onheartbeat=function(){t._heartbeat_received()},t.connectionTimer&&clearTimeout(t.connectionTimer),t.connectionTimer=setTimeout(function(){t._lostConnection(new _.ConnectionError("DDP connection timed out"))},t.CONNECT_TIMEOUT)}})}.call(this),function(){var t=function(e,t){return e.length>=t.length&&e.substring(0,t.length)===t},n=function(e,t){return e.length>=t.length&&e.substring(e.length-t.length)===t},o=function(o,i,a){i||(i="http");var s=o.match(/^ddp(i?)\+sockjs:\/\//),u=o.match(/^http(s?):\/\//),c;if(s){var l=o.substr(s[0].length);c="i"===s[1]?i:i+"s";var d=l.indexOf("/"),f=-1===d?l:l.substr(0,d),_=-1===d?"":l.substr(d);return f=f.replace(/\*/g,function(){return Math.floor(10*r.fraction())}),c+"://"+f+_}if(u){c=u[1]?i+"s":i;var p=o.substr(u[0].length);o=c+"://"+p}return-1!==o.indexOf("://")||t(o,"/")||(o=i+"://"+o),o=e._relativeToSiteRootUrl(o),n(o,"/")?o+a:o+"/"+a};v=function(e){return o(e,"http","sockjs")},m=function(e){var t=o(e,"ws","websocket");return t},p.toSockjsUrl=v,a.extend(p.ClientStream.prototype,{on:function(e,t){var n=this;if("message"!==e&&"reset"!==e&&"disconnect"!==e)throw new Error("unknown event type: "+e);n.eventCallbacks[e]||(n.eventCallbacks[e]=[]),n.eventCallbacks[e].push(t)},_initCommon:function(e){var t=this;e=e||{},t.CONNECT_TIMEOUT=e.connectTimeoutMs||1e4,t.eventCallbacks={},t._forcedToDisconnect=!1,t.currentStatus={status:"connecting",connected:!1,retryCount:0},t.statusListeners="undefined"!=typeof s&&new s.Dependency,t.statusChanged=function(){t.statusListeners&&t.statusListeners.changed()},t._retry=new l,t.connectionTimer=null},reconnect:function(e){var t=this;return e=e||{},e.url&&t._changeUrl(e.url),e._sockjsOptions&&(t.options._sockjsOptions=e._sockjsOptions),t.currentStatus.connected?void((e._force||e.url)&&t._lostConnection(new _.ForcedReconnectError)):("connecting"===t.currentStatus.status&&t._lostConnection(),t._retry.clear(),t.currentStatus.retryCount-=1,void t._retryNow())},disconnect:function(e){var t=this;e=e||{},t._forcedToDisconnect||(e._permanent&&(t._forcedToDisconnect=!0),t._cleanup(),t._retry.clear(),t.currentStatus={status:e._permanent?"failed":"offline",connected:!1,retryCount:0},e._permanent&&e._error&&(t.currentStatus.reason=e._error),t.statusChanged())},_lostConnection:function(e){var t=this;t._cleanup(e),t._retryLater(e)},_online:function(){"offline"!=this.currentStatus.status&&this.reconnect()},_retryLater:function(e){var t=this,n=0;t.options.retry||e&&"DDP.ForcedReconnectError"===e.errorType?(n=t._retry.retryLater(t.currentStatus.retryCount,a.bind(t._retryNow,t)),t.currentStatus.status="waiting",t.currentStatus.retryTime=(new Date).getTime()+n):(t.currentStatus.status="failed",delete t.currentStatus.retryTime),t.currentStatus.connected=!1,t.statusChanged()},_retryNow:function(){var e=this;e._forcedToDisconnect||(e.currentStatus.retryCount+=1,e.currentStatus.status="connecting",e.currentStatus.connected=!1,delete e.currentStatus.retryTime,e.statusChanged(),e._launchConnection())},status:function(){var e=this;return e.statusListeners&&e.statusListeners.depend(),e.currentStatus}}),_.ConnectionError=e.makeErrorType("DDP.ConnectionError",function(e){var t=this;t.message=e}),_.ForcedReconnectError=e.makeErrorType("DDP.ForcedReconnectError",function(){})}.call(this),function(){g=function(e){var t=this;t.heartbeatInterval=e.heartbeatInterval,t.heartbeatTimeout=e.heartbeatTimeout,t._sendPing=e.sendPing,t._onTimeout=e.onTimeout,t._heartbeatIntervalHandle=null,t._heartbeatTimeoutHandle=null},a.extend(g.prototype,{stop:function(){var e=this;e._clearHeartbeatIntervalTimer(),e._clearHeartbeatTimeoutTimer()},start:function(){var e=this;e.stop(),e._startHeartbeatIntervalTimer()},_startHeartbeatIntervalTimer:function(){var t=this;t._heartbeatIntervalHandle=e.setTimeout(a.bind(t._heartbeatIntervalFired,t),t.heartbeatInterval)},_startHeartbeatTimeoutTimer:function(){var t=this;t._heartbeatTimeoutHandle=e.setTimeout(a.bind(t._heartbeatTimeoutFired,t),t.heartbeatTimeout)},_clearHeartbeatIntervalTimer:function(){var t=this;t._heartbeatIntervalHandle&&(e.clearTimeout(t._heartbeatIntervalHandle),t._heartbeatIntervalHandle=null)},_clearHeartbeatTimeoutTimer:function(){var t=this;t._heartbeatTimeoutHandle&&(e.clearTimeout(t._heartbeatTimeoutHandle),t._heartbeatTimeoutHandle=null)},_heartbeatIntervalFired:function(){var e=this;e._heartbeatIntervalHandle=null,e._sendPing(),e._startHeartbeatTimeoutTimer()},_heartbeatTimeoutFired:function(){var e=this;e._heartbeatTimeoutHandle=null,e._onTimeout()},pingReceived:function(){var e=this;e._heartbeatIntervalHandle&&(e._clearHeartbeatIntervalTimer(),e._startHeartbeatIntervalTimer())},pongReceived:function(){var e=this;e._heartbeatTimeoutHandle&&(e._clearHeartbeatTimeoutTimer(),e._startHeartbeatIntervalTimer())}})}.call(this),function(){b=["1","pre2","pre1"],p.SUPPORTED_DDP_VERSIONS=b,y=function(e){var t=this;this.isSimulation=e.isSimulation,this._unblock=e.unblock||function(){},this._calledUnblock=!1,this.userId=e.userId,this._setUserId=e.setUserId||function(){},this.connection=e.connection,this.randomSeed=e.randomSeed,this.randomStream=null},a.extend(y.prototype,{unblock:function(){var e=this;e._calledUnblock=!0,e._unblock()},setUserId:function(e){var t=this;if(t._calledUnblock)throw new Error("Can't call setUserId in a method after calling unblock");t.userId=e,t._setUserId(e)}}),w=function(t){try{var n=i.parse(t)}catch(r){return e._debug("Discarding message with invalid JSON",t),null}return null===n||"object"!=typeof n?(e._debug("Discarding non-object DDP message",t),null):(a.has(n,"cleared")&&(a.has(n,"fields")||(n.fields={}),a.each(n.cleared,function(e){n.fields[e]=void 0}),delete n.cleared),a.each(["fields","params","result"],function(e){a.has(n,e)&&(n[e]=o._adjustTypesFromJSONValue(n[e]))}),n)},k=function(e){var t=o.clone(e);if(a.has(e,"fields")){var n=[];a.each(e.fields,function(e,r){void 0===e&&(n.push(r),delete t.fields[r])}),a.isEmpty(n)||(t.cleared=n),a.isEmpty(t.fields)&&delete t.fields}if(a.each(["fields","params","result"],function(e){a.has(t,e)&&(t[e]=o._adjustTypesToJSONValue(t[e]))}),e.id&&"string"!=typeof e.id)throw new Error("Message id is not a string");return i.stringify(t)},_._CurrentInvocation=new e.EnvironmentVariable}.call(this),function(){function e(){return r.hexString(20)}S=function(t){var n=this;this.seed=[].concat(t.seed||e()),this.sequences={}},S.get=function(e,t){if(t||(t="default"),!e)return r;var n=e.randomStream;return n||(e.randomStream=n=new S({seed:e.randomSeed})),n._sequence(t)},_.randomStream=function(e){var t=_._CurrentInvocation.get();return S.get(t,e)},C=function(e,t){var n=S.get(e,"/rpc/"+t);return n.hexString(20)},a.extend(S.prototype,{_sequence:function(e){var t=this,n=t.sequences[e]||null;if(null===n){for(var o=t.seed.concat(e),i=0;i<o.length;i++)a.isFunction(o[i])&&(o[i]=o[i]());t.sequences[e]=n=r.createWithSeeds.apply(null,o)}return n}})}.call(this),function(){if(e.isServer)var t=Npm.require("path"),n=Npm.require("fibers"),u=Npm.require(t.join("fibers","future"));var c=function(t,n){var r=this;n=a.extend({onConnected:function(){},onDDPVersionNegotiationFailure:function(t){e._debug(t)},heartbeatInterval:35e3,heartbeatTimeout:15e3,reloadWithOutstanding:!1,supportedDDPVersions:b,retry:!0,respondToPings:!0},n),r.onReconnect=null,r._stream="object"==typeof t?t:new p.ClientStream(t,{retry:n.retry,headers:n.headers,_sockjsOptions:n._sockjsOptions,_dontPrintErrors:n._dontPrintErrors,connectTimeoutMs:n.connectTimeoutMs}),r._lastSessionId=null,r._versionSuggestion=null,r._version=null,r._stores={},r._methodHandlers={},r._nextMethodId=1,r._supportedDDPVersions=n.supportedDDPVersions,r._heartbeatInterval=n.heartbeatInterval,r._heartbeatTimeout=n.heartbeatTimeout,r._methodInvokers={},r._outstandingMethodBlocks=[],r._documentsWrittenByStub={},r._serverDocuments={},r._afterUpdateCallbacks=[],r._messagesBufferedUntilQuiescence=[],r._methodsBlockingQuiescence={},r._subsBeingRevived={},r._resetStores=!1,r._updatesForUnknownStores={},r._retryMigrate=null,r._subscriptions={},r._userId=null,r._userIdDeps=new s.Dependency,e.isClient&&Package.reload&&!n.reloadWithOutstanding&&Package.reload.Reload._onMigrate(function(e){if(r._readyToMigrate())return[!0];if(r._retryMigrate)throw new Error("Two migrations in progress?");return r._retryMigrate=e,!1});var o=function(t){try{var o=w(t)}catch(i){return void e._debug("Exception while parsing DDP",i)}if(null===o||!o.msg)return void(o&&o.server_id||e._debug("discarding invalid livedata message",o));if("connected"===o.msg)r._version=r._versionSuggestion,r._livedata_connected(o),n.onConnected();else if("failed"==o.msg)if(a.contains(r._supportedDDPVersions,o.version))r._versionSuggestion=o.version,r._stream.reconnect({_force:!0});else{var s="DDP version negotiation failed; server requested version "+o.version;r._stream.disconnect({_permanent:!0,_error:s}),n.onDDPVersionNegotiationFailure(s)}else"ping"===o.msg?(n.respondToPings&&r._send({msg:"pong",id:o.id}),r._heartbeat&&r._heartbeat.pingReceived()):"pong"===o.msg?r._heartbeat&&r._heartbeat.pongReceived():a.include(["added","changed","removed","ready","updated"],o.msg)?r._livedata_data(o):"nosub"===o.msg?r._livedata_nosub(o):"result"===o.msg?r._livedata_result(o):"error"===o.msg?r._livedata_error(o):e._debug("discarding unknown livedata message type",o)},i=function(){var e={msg:"connect"};r._lastSessionId&&(e.session=r._lastSessionId),e.version=r._versionSuggestion||r._supportedDDPVersions[0],r._versionSuggestion=e.version,e.support=r._supportedDDPVersions,r._send(e),!a.isEmpty(r._outstandingMethodBlocks)&&a.isEmpty(r._outstandingMethodBlocks[0].methods)&&r._outstandingMethodBlocks.shift(),a.each(r._methodInvokers,function(e){e.sentMessage=!1}),r.onReconnect?r._callOnReconnectAndSendAppropriateOutstandingMethods():r._sendOutstandingMethods(),a.each(r._subscriptions,function(e,t){r._send({msg:"sub",id:t,name:e.name,params:e.params})})},u=function(){r._heartbeat&&(r._heartbeat.stop(),r._heartbeat=null)};e.isServer?(r._stream.on("message",e.bindEnvironment(o,e._debug)),r._stream.on("reset",e.bindEnvironment(i,e._debug)),r._stream.on("disconnect",e.bindEnvironment(u,e._debug))):(r._stream.on("message",o),r._stream.on("reset",i),r._stream.on("disconnect",u))},l=function(e){var t=this;t.methodId=e.methodId,t.sentMessage=!1,t._callback=e.callback,t._connection=e.connection,t._message=e.message,t._onResultReceived=e.onResultReceived||function(){},t._wait=e.wait,t._methodResult=null,t._dataVisible=!1,t._connection._methodInvokers[t.methodId]=t};a.extend(l.prototype,{sendMessage:function(){var e=this;if(e.gotResult())throw new Error("sendingMethod is called on method with result");e._dataVisible=!1,e.sentMessage=!0,e._wait&&(e._connection._methodsBlockingQuiescence[e.methodId]=!0),e._connection._send(e._message)},_maybeInvokeCallback:function(){var e=this;e._methodResult&&e._dataVisible&&(e._callback(e._methodResult[0],e._methodResult[1]),delete e._connection._methodInvokers[e.methodId],e._connection._outstandingMethodFinished())},receiveResult:function(e,t){var n=this;if(n.gotResult())throw new Error("Methods should only receive results once");n._methodResult=[e,t],n._onResultReceived(e,t),n._maybeInvokeCallback()},dataVisible:function(){var e=this;e._dataVisible=!0,e._maybeInvokeCallback()},gotResult:function(){var e=this;return!!e._methodResult}}),a.extend(c.prototype,{registerStore:function(e,t){var n=this;if(e in n._stores)return!1;var r={};a.each(["update","beginUpdate","endUpdate","saveOriginals","retrieveOriginals"],function(e){r[e]=function(){return t[e]?t[e].apply(t,arguments):void 0}}),n._stores[e]=r;var o=n._updatesForUnknownStores[e];return o&&(r.beginUpdate(o.length,!1),a.each(o,function(e){r.update(e)}),r.endUpdate(),delete n._updatesForUnknownStores[e]),!0},subscribe:function(e){var t=this,n=Array.prototype.slice.call(arguments,1),i={};if(n.length){var u=n[n.length-1];"function"==typeof u?i.onReady=n.pop():!u||"function"!=typeof u.onReady&&"function"!=typeof u.onError||(i=n.pop())}var c=a.find(t._subscriptions,function(t){return t.inactive&&t.name===e&&o.equals(t.params,n)}),l;c?(l=c.id,c.inactive=!1,i.onReady&&(c.ready||(c.readyCallback=i.onReady)),i.onError&&(c.errorCallback=i.onError)):(l=r.id(),t._subscriptions[l]={id:l,name:e,params:o.clone(n),inactive:!1,ready:!1,readyDeps:new s.Dependency,readyCallback:i.onReady,errorCallback:i.onError,connection:t,remove:function(){delete this.connection._subscriptions[this.id],this.ready&&this.readyDeps.changed()},stop:function(){this.connection._send({msg:"unsub",id:l}),this.remove()}},t._send({msg:"sub",id:l,name:e,params:n}));var d={stop:function(){a.has(t._subscriptions,l)&&t._subscriptions[l].stop()},ready:function(){if(!a.has(t._subscriptions,l))return!1;var e=t._subscriptions[l];return e.readyDeps.depend(),e.ready}};return s.active&&s.onInvalidate(function(e){a.has(t._subscriptions,l)&&(t._subscriptions[l].inactive=!0),s.afterFlush(function(){a.has(t._subscriptions,l)&&t._subscriptions[l].inactive&&d.stop()})}),d},_subscribeAndWait:function(e,t,n){var r=this,o=new u,i=!1,a;return t=t||[],t.push({onReady:function(){i=!0,o["return"]()},onError:function(e){i?n&&n.onLateError&&n.onLateError(e):o["throw"](e)}}),a=r.subscribe.apply(r,[e].concat(t)),o.wait(),a},methods:function(e){var t=this;a.each(e,function(e,n){if(t._methodHandlers[n])throw new Error("A method named '"+n+"' is already defined");t._methodHandlers[n]=e})},call:function(e){var t=Array.prototype.slice.call(arguments,1);if(t.length&&"function"==typeof t[t.length-1])var n=t.pop();return this.apply(e,t,n)},apply:function(t,n,r,i){var s=this;i||"function"!=typeof r||(i=r,r={}),r=r||{},i&&(i=e.bindEnvironment(i,"delivering result of invoking '"+t+"'")),n=o.clone(n);var c=function(){var e;return function(){return void 0===e&&(e=""+s._nextMethodId++),e}}(),d=_._CurrentInvocation.get(),f=d&&d.isSimulation,p=null,h=function(){return null===p&&(p=C(d,t)),p},v=s._methodHandlers[t];if(v){var m=function(e){s.setUserId(e)},g=new y({isSimulation:!0,userId:s.userId(),setUserId:m,randomSeed:function(){return h()}});f||s._saveOriginals();try{var b=_._CurrentInvocation.withValue(g,function(){return e.isServer?e._noYieldsAllowed(function(){return v.apply(g,o.clone(n))}):v.apply(g,o.clone(n))})}catch(w){var k=w}f||s._retrieveAndStoreOriginals(c())}if(f){if(i)return void i(k,b);if(k)throw k;return b}if(k&&!k.expected&&e._debug("Exception while simulating the effect of invoking '"+t+"'",k,k.stack),!i)if(e.isClient)i=function(n){n&&e._debug("Error invoking Method '"+t+"':",n.message)};else{var S=new u;i=S.resolver()}var T={msg:"method",method:t,params:n,id:c()};null!==p&&(T.randomSeed=p);var E=new l({methodId:c(),callback:i,connection:s,onResultReceived:r.onResultReceived,wait:!!r.wait,message:T});return r.wait?s._outstandingMethodBlocks.push({wait:!0,methods:[E]}):((a.isEmpty(s._outstandingMethodBlocks)||a.last(s._outstandingMethodBlocks).wait)&&s._outstandingMethodBlocks.push({wait:!1,methods:[]}),a.last(s._outstandingMethodBlocks).methods.push(E)),1===s._outstandingMethodBlocks.length&&E.sendMessage(),S?S.wait():r.returnStubValue?b:void 0},_saveOriginals:function(){var e=this;a.each(e._stores,function(e){e.saveOriginals()})},_retrieveAndStoreOriginals:function(e){var t=this;if(t._documentsWrittenByStub[e])throw new Error("Duplicate methodId in _retrieveAndStoreOriginals");var n=[];a.each(t._stores,function(r,o){var i=r.retrieveOriginals();i&&i.forEach(function(r,i){n.push({collection:o,id:i}),a.has(t._serverDocuments,o)||(t._serverDocuments[o]=new d._IdMap);var s=t._serverDocuments[o].setDefault(i,{});s.writtenByStubs?s.writtenByStubs[e]=!0:(s.document=r,s.flushCallbacks=[],s.writtenByStubs={},s.writtenByStubs[e]=!0)})}),a.isEmpty(n)||(t._documentsWrittenByStub[e]=n)},_unsubscribeAll:function(){var e=this;a.each(a.clone(e._subscriptions),function(t,n){"meteor_autoupdate_clientVersions"!==t.name&&e._subscriptions[n].stop()})},_send:function(e){var t=this;t._stream.send(k(e))},_lostConnection:function(e){var t=this;t._stream._lostConnection(e)},status:function(){var e=this;return e._stream.status.apply(e._stream,arguments)},reconnect:function(){var e=this;return e._stream.reconnect.apply(e._stream,arguments)},disconnect:function(){var e=this;return e._stream.disconnect.apply(e._stream,arguments)},close:function(){var e=this;return e._stream.disconnect({_permanent:!0})},userId:function(){var e=this;return e._userIdDeps&&e._userIdDeps.depend(),e._userId},setUserId:function(e){var t=this;t._userId!==e&&(t._userId=e,t._userIdDeps&&t._userIdDeps.changed())},_waitingForQuiescence:function(){var e=this;return!a.isEmpty(e._subsBeingRevived)||!a.isEmpty(e._methodsBlockingQuiescence)},_anyMethodsAreOutstanding:function(){var e=this;return a.any(a.pluck(e._methodInvokers,"sentMessage"))},_livedata_connected:function(e){var t=this;if("pre1"!==t._version&&0!==t._heartbeatInterval&&(t._heartbeat=new g({heartbeatInterval:t._heartbeatInterval,heartbeatTimeout:t._heartbeatTimeout,onTimeout:function(){t._lostConnection(new _.ConnectionError("DDP heartbeat timed out"))},sendPing:function(){t._send({msg:"ping"})}}),t._heartbeat.start()),t._lastSessionId&&(t._resetStores=!0),"string"==typeof e.session){var n=t._lastSessionId===e.session;t._lastSessionId=e.session}n||(t._updatesForUnknownStores={},t._resetStores&&(t._documentsWrittenByStub={},t._serverDocuments={}),t._afterUpdateCallbacks=[],t._subsBeingRevived={},a.each(t._subscriptions,function(e,n){e.ready&&(t._subsBeingRevived[n]=!0)}),t._methodsBlockingQuiescence={},t._resetStores&&a.each(t._methodInvokers,function(e){e.gotResult()?t._afterUpdateCallbacks.push(a.bind(e.dataVisible,e)):e.sentMessage&&(t._methodsBlockingQuiescence[e.methodId]=!0)}),t._messagesBufferedUntilQuiescence=[],t._waitingForQuiescence()||(t._resetStores&&(a.each(t._stores,function(e){e.beginUpdate(0,!0),e.endUpdate()}),t._resetStores=!1),t._runAfterUpdateCallbacks()))},_processOneDataMessage:function(e,t){var n=this;n["_process_"+e.msg](e,t)},_livedata_data:function(e){var t=this,n={};if(t._waitingForQuiescence()){if(t._messagesBufferedUntilQuiescence.push(e),"nosub"===e.msg&&delete t._subsBeingRevived[e.id],a.each(e.subs||[],function(e){delete t._subsBeingRevived[e]}),a.each(e.methods||[],function(e){delete t._methodsBlockingQuiescence[e]}),t._waitingForQuiescence())return;a.each(t._messagesBufferedUntilQuiescence,function(e){t._processOneDataMessage(e,n)}),t._messagesBufferedUntilQuiescence=[]}else t._processOneDataMessage(e,n);(t._resetStores||!a.isEmpty(n))&&(a.each(t._stores,function(e,r){e.beginUpdate(a.has(n,r)?n[r].length:0,t._resetStores)}),t._resetStores=!1,a.each(n,function(e,n){var r=t._stores[n];r?a.each(e,function(e){r.update(e)}):(a.has(t._updatesForUnknownStores,n)||(t._updatesForUnknownStores[n]=[]),Array.prototype.push.apply(t._updatesForUnknownStores[n],e))}),a.each(t._stores,function(e){e.endUpdate()})),t._runAfterUpdateCallbacks()},_runAfterUpdateCallbacks:function(){var e=this,t=e._afterUpdateCallbacks;e._afterUpdateCallbacks=[],a.each(t,function(e){e()})},_pushUpdate:function(e,t,n){var r=this;a.has(e,t)||(e[t]=[]),e[t].push(n)},_getServerDoc:function(e,t){var n=this;if(!a.has(n._serverDocuments,e))return null;var r=n._serverDocuments[e];return r.get(t)||null},_process_added:function(e,t){var n=this,r=d._idParse(e.id),o=n._getServerDoc(e.collection,r);if(o){if(void 0!==o.document)throw new Error("Server sent add for existing id: "+e.id);o.document=e.fields||{},o.document._id=r}else n._pushUpdate(t,e.collection,e)},_process_changed:function(e,t){var n=this,r=n._getServerDoc(e.collection,d._idParse(e.id));if(r){if(void 0===r.document)throw new Error("Server sent changed for nonexisting id: "+e.id);d._applyChanges(r.document,e.fields)}else n._pushUpdate(t,e.collection,e)},_process_removed:function(e,t){var n=this,r=n._getServerDoc(e.collection,d._idParse(e.id));if(r){if(void 0===r.document)throw new Error("Server sent removed for nonexisting id:"+e.id);r.document=void 0}else n._pushUpdate(t,e.collection,{msg:"removed",collection:e.collection,id:e.id})},_process_updated:function(e,t){var n=this;a.each(e.methods,function(e){a.each(n._documentsWrittenByStub[e],function(r){var o=n._getServerDoc(r.collection,r.id);if(!o)throw new Error("Lost serverDoc for "+i.stringify(r));if(!o.writtenByStubs[e])throw new Error("Doc "+i.stringify(r)+" not written by method "+e);delete o.writtenByStubs[e],a.isEmpty(o.writtenByStubs)&&(n._pushUpdate(t,r.collection,{msg:"replace",id:d._idStringify(r.id),replace:o.document}),a.each(o.flushCallbacks,function(e){e()}),n._serverDocuments[r.collection].remove(r.id))}),delete n._documentsWrittenByStub[e];var r=n._methodInvokers[e];if(!r)throw new Error("No callback invoker for method "+e);n._runWhenAllServerDocsAreFlushed(a.bind(r.dataVisible,r))})},_process_ready:function(e,t){var n=this;a.each(e.subs,function(e){n._runWhenAllServerDocsAreFlushed(function(){var t=n._subscriptions[e];t&&(t.ready||(t.readyCallback&&t.readyCallback(),t.ready=!0,t.readyDeps.changed()))})})},_runWhenAllServerDocsAreFlushed:function(e){var t=this,n=function(){t._afterUpdateCallbacks.push(e)},r=0,o=function(){--r,0===r&&n()};a.each(t._serverDocuments,function(e){e.forEach(function(e){var n=a.any(e.writtenByStubs,function(e,n){var r=t._methodInvokers[n];return r&&r.sentMessage});n&&(++r,e.flushCallbacks.push(o))})}),0===r&&n()},_livedata_nosub:function(t){var n=this;if(n._livedata_data(t),a.has(n._subscriptions,t.id)){var r=n._subscriptions[t.id].errorCallback;n._subscriptions[t.id].remove(),r&&t.error&&r(new e.Error(t.error.error,t.error.reason,t.error.details))}},_process_nosub:function(){},_livedata_result:function(t){var n=this;if(a.isEmpty(n._outstandingMethodBlocks))return void e._debug("Received method result but no methods outstanding");for(var r=n._outstandingMethodBlocks[0].methods,o,i=0;i<r.length&&(o=r[i],o.methodId!==t.id);i++);return o?(r.splice(i,1),void(a.has(t,"error")?o.receiveResult(new e.Error(t.error.error,t.error.reason,t.error.details)):o.receiveResult(void 0,t.result))):void e._debug("Can't match method response to original method call",t)},_outstandingMethodFinished:function(){var e=this;if(!e._anyMethodsAreOutstanding()){if(!a.isEmpty(e._outstandingMethodBlocks)){var t=e._outstandingMethodBlocks.shift();if(!a.isEmpty(t.methods))throw new Error("No methods outstanding but nonempty block: "+i.stringify(t));a.isEmpty(e._outstandingMethodBlocks)||e._sendOutstandingMethods()}e._maybeMigrate()}},_sendOutstandingMethods:function(){var e=this;a.isEmpty(e._outstandingMethodBlocks)||a.each(e._outstandingMethodBlocks[0].methods,function(e){e.sendMessage()})},_livedata_error:function(t){e._debug("Received error from server: ",t.reason),t.offendingMessage&&e._debug("For: ",t.offendingMessage)},_callOnReconnectAndSendAppropriateOutstandingMethods:function(){var e=this,t=e._outstandingMethodBlocks;if(e._outstandingMethodBlocks=[],e.onReconnect(),!a.isEmpty(t)){if(a.isEmpty(e._outstandingMethodBlocks))return e._outstandingMethodBlocks=t,void e._sendOutstandingMethods();a.last(e._outstandingMethodBlocks).wait||t[0].wait||(a.each(t[0].methods,function(t){a.last(e._outstandingMethodBlocks).methods.push(t),1===e._outstandingMethodBlocks.length&&t.sendMessage()}),t.shift()),a.each(t,function(t){e._outstandingMethodBlocks.push(t)})}},_readyToMigrate:function(){var e=this;return a.isEmpty(e._methodInvokers)},_maybeMigrate:function(){var e=this;e._retryMigrate&&e._readyToMigrate()&&(e._retryMigrate(),e._retryMigrate=null)}}),p.Connection=c,_.connect=function(e,t){var n=new c(e,t);return T.push(n),n},T=[],_._allSubscriptionsReady=function(){return a.all(T,function(e){return a.all(e._subscriptions,function(e){return e.ready})})}}.call(this),function(){if(e.refresh=function(e){},e.isClient){var t="/";"undefined"!=typeof __meteor_runtime_config__&&__meteor_runtime_config__.DDP_DEFAULT_CONNECTION_URL&&(t=__meteor_runtime_config__.DDP_DEFAULT_CONNECTION_URL);var n=new l,r=function(t){if(e._debug(t),Package.reload){var r=Package.reload.Reload._migrationData("livedata")||{},o=r.DDPVersionNegotiationFailures||0;++o,Package.reload.Reload._onMigrate("livedata",function(){return[!0,{DDPVersionNegotiationFailures:o}]}),n.retryLater(o,function(){Package.reload.Reload._reload()})}};e.connection=_.connect(t,{onDDPVersionNegotiationFailure:r}),a.each(["subscribe","methods","call","apply","status","reconnect","disconnect"],function(t){e[t]=a.bind(e.connection[t],e.connection)})}else e.connection=null;e.default_connection=e.connection,e.connect=_.connect}.call(this),"undefined"==typeof Package&&(Package={}),Package.ddp={DDP:_,LivedataTest:p}}();
+
+!function(){var e=Package.meteor.Meteor,a=Package.logging.Log,g=Package.underscore._,o=Package.ddp.DDP,c=Package.ejson.EJSON,P;"undefined"==typeof Package&&(Package={}),Package["follower-livedata"]={Follower:P}}();
+
+!function(){var a=Package.meteor.Meteor,e=Package.logging.Log,o=Package.underscore._,g=Package.ddp.DDP,c=Package.ejson.EJSON,n=Package["follower-livedata"].Follower;"undefined"==typeof Package&&(Package={}),Package["application-configuration"]={}}();
+
+!function(){var e=Package.meteor.Meteor,n=Package.random.Random,o=Package.ejson.EJSON,t=Package.json.JSON,r=Package.underscore._,i=Package.minimongo.LocalCollection,c=Package.minimongo.Minimongo,l=Package.logging.Log,a=Package.ddp.DDP,s=Package.tracker.Tracker,d=Package.tracker.Deps,u=Package.check.check,f=Package.check.Match,_,p;(function(){p=function(){var e=this;e.noConnCollections={}};var e=function(e,n){return e in n||(n[e]=new i(e)),n[e]};r.extend(p.prototype,{open:function(n,o){var t=this;return n?o?(o._mongo_livedata_collections||(o._mongo_livedata_collections={}),e(n,o._mongo_livedata_collections)):e(n,t.noConnCollections):new i}}),p=new p}).call(this),function(){_={},_.Collection=function(o,t){var c=this;if(!(c instanceof _.Collection))throw new Error('use "new" to construct a Mongo.Collection');if(o||null===o||(e._debug("Warning: creating anonymous collection. It will not be saved or synchronized over the network. (Pass null for the collection name to turn off this warning.)"),o=null),null!==o&&"string"!=typeof o)throw new Error("First argument to new Mongo.Collection must be a string or null");switch(t&&t.methods&&(t={connection:t}),t&&t.manager&&!t.connection&&(t.connection=t.manager),t=r.extend({connection:void 0,idGeneration:"STRING",transform:null,_driver:void 0,_preventAutopublish:!1},t),t.idGeneration){case"MONGO":c._makeNewID=function(){var e=o?a.randomStream("/collection/"+o):n;return new _.ObjectID(e.hexString(24))};break;case"STRING":default:c._makeNewID=function(){var e=o?a.randomStream("/collection/"+o):n;return e.id()}}if(c._transform=i.wrapTransform(t.transform),c._connection=o&&null!==t.connection?t.connection?t.connection:e.isClient?e.connection:e.server:null,t._driver||(t._driver=o&&c._connection===e.server&&"undefined"!=typeof MongoInternals&&MongoInternals.defaultRemoteCollectionDriver?MongoInternals.defaultRemoteCollectionDriver():p),c._collection=t._driver.open(o,c._connection),c._name=o,c._connection&&c._connection.registerStore){var l=c._connection.registerStore(o,{beginUpdate:function(e,n){(e>1||n)&&c._collection.pauseObservers(),n&&c._collection.remove({})},update:function(e){var n=i._idParse(e.id),o=c._collection.findOne(n);if("replace"===e.msg){var t=e.replace;return void(t?o?c._collection.update(n,t):c._collection.insert(t):o&&c._collection.remove(n))}if("added"===e.msg){if(o)throw new Error("Expected not to find a document already present for an add");c._collection.insert(r.extend({_id:n},e.fields))}else if("removed"===e.msg){if(!o)throw new Error("Expected to find a document already present for removed");c._collection.remove(n)}else{if("changed"!==e.msg)throw new Error("I don't know how to deal with this message");if(!o)throw new Error("Expected to find a document to change");if(!r.isEmpty(e.fields)){var l={};r.each(e.fields,function(e,n){void 0===e?(l.$unset||(l.$unset={}),l.$unset[n]=1):(l.$set||(l.$set={}),l.$set[n]=e)}),c._collection.update(n,l)}}},endUpdate:function(){c._collection.resumeObservers()},saveOriginals:function(){c._collection.saveOriginals()},retrieveOriginals:function(){return c._collection.retrieveOriginals()}});if(!l)throw new Error("There is already a collection named '"+o+"'")}c._defineMutationMethods(),Package.autopublish&&!t._preventAutopublish&&c._connection&&c._connection.publish&&c._connection.publish(null,function(){return c.find()},{is_auto:!0})},r.extend(_.Collection.prototype,{_getFindSelector:function(e){return 0==e.length?{}:e[0]},_getFindOptions:function(e){var n=this;return e.length<2?{transform:n._transform}:(u(e[1],f.Optional(f.ObjectIncluding({fields:f.Optional(f.OneOf(Object,void 0)),sort:f.Optional(f.OneOf(Object,Array,void 0)),limit:f.Optional(f.OneOf(Number,void 0)),skip:f.Optional(f.OneOf(Number,void 0))}))),r.extend({transform:n._transform},e[1]))},find:function(){var e=this,n=r.toArray(arguments);return e._collection.find(e._getFindSelector(n),e._getFindOptions(n))},findOne:function(){var e=this,n=r.toArray(arguments);return e._collection.findOne(e._getFindSelector(n),e._getFindOptions(n))}}),_.Collection._publishCursor=function(e,n,o){var t=e.observeChanges({added:function(e,t){n.added(o,e,t)},changed:function(e,t){n.changed(o,e,t)},removed:function(e){n.removed(o,e)}});n.onStop(function(){t.stop()})},_.Collection._rewriteSelector=function(e){if(i._selectorIsId(e)&&(e={_id:e}),!e||"_id"in e&&!e._id)return{_id:n.id()};var o={};return r.each(e,function(e,n){e instanceof RegExp?o[n]=t(e):e&&e.$regex instanceof RegExp?(o[n]=t(e.$regex),void 0!==e.$options&&(o[n].$options=e.$options)):o[n]=r.contains(["$or","$and","$nor"],n)?r.map(e,function(e){return _.Collection._rewriteSelector(e)}):e}),o};var t=function(e){u(e,RegExp);var n={$regex:e.source},o="";return e.ignoreCase&&(o+="i"),e.multiline&&(o+="m"),o&&(n.$options=o),n},c=function(n,o){if(!i._selectorIsIdPerhapsAsObject(n))throw new e.Error(403,"Not permitted. Untrusted code may only "+o+" documents by ID.")};r.each(["insert","update","remove"],function(n){_.Collection.prototype[n]=function(){var o=this,t=r.toArray(arguments),i,l,s;if(t.length&&(void 0===t[t.length-1]||t[t.length-1]instanceof Function)&&(i=t.pop()),"insert"===n){if(!t.length)throw new Error("insert requires an argument");if(t[0]=r.extend({},t[0]),"_id"in t[0]){if(l=t[0]._id,!l||!("string"==typeof l||l instanceof _.ObjectID))throw new Error("Meteor requires document _id fields to be non-empty strings or ObjectIDs")}else{var d=!0;if(o._connection&&o._connection!==e.server){var u=a._CurrentInvocation.get();u||(d=!1)}d&&(l=t[0]._id=o._makeNewID())}}else if(t[0]=_.Collection._rewriteSelector(t[0]),"update"===n){var f=t[2]=r.clone(t[2])||{};if(f&&"function"!=typeof f&&f.upsert)if(f.insertedId){if(!("string"==typeof f.insertedId||f.insertedId instanceof _.ObjectID))throw new Error("insertedId must be string or ObjectID")}else f.insertedId=o._makeNewID()}var p=function(e){return"insert"===n?(!l&&e&&(l=e),l):e},h;if(i&&(h=function(e,n){i(e,!e&&p(n))}),o._connection&&o._connection!==e.server){var u=a._CurrentInvocation.get(),v=u&&u.isSimulation;!e.isClient||h||v||(h=function(o){o&&e._debug(n+" failed: "+(o.reason||o.stack))}),v||"insert"===n||c(t[0],n),s=p(o._connection.apply(o._prefix+n,t,{returnStubValue:!0},h))}else{t.push(h);try{var m=o._collection[n].apply(o._collection,t);s=p(m)}catch(g){if(i)return i(g),null;throw g}}return s}}),_.Collection.prototype.upsert=function(e,n,o,t){var i=this;return t||"function"!=typeof o||(t=o,o={}),i.update(e,n,r.extend({},o,{_returnObject:!0,upsert:!0}),t)},_.Collection.prototype._ensureIndex=function(e,n){var o=this;if(!o._collection._ensureIndex)throw new Error("Can only call _ensureIndex on server collections");o._collection._ensureIndex(e,n)},_.Collection.prototype._dropIndex=function(e){var n=this;if(!n._collection._dropIndex)throw new Error("Can only call _dropIndex on server collections");n._collection._dropIndex(e)},_.Collection.prototype._dropCollection=function(){var e=this;if(!e._collection.dropCollection)throw new Error("Can only call _dropCollection on server collections");e._collection.dropCollection()},_.Collection.prototype._createCappedCollection=function(e,n){var o=this;if(!o._collection._createCappedCollection)throw new Error("Can only call _createCappedCollection on server collections");o._collection._createCappedCollection(e,n)},_.ObjectID=i._ObjectID,_.Cursor=i.Cursor,_.Collection.Cursor=_.Cursor,_.Collection.ObjectID=_.ObjectID,function(){var e=function(e,n){var o=["insert","update","remove","fetch","transform"];r.each(r.keys(n),function(n){if(!r.contains(o,n))throw new Error(e+": Invalid key: "+n)});var t=this;if(t._restricted=!0,r.each(["insert","update","remove"],function(o){if(n[o]){if(!(n[o]instanceof Function))throw new Error(e+": Value for `"+o+"` must be a function");n[o].transform=void 0===n.transform?t._transform:i.wrapTransform(n.transform),t._validators[o][e].push(n[o])}}),n.update||n.remove||n.fetch){if(n.fetch&&!(n.fetch instanceof Array))throw new Error(e+": Value for `fetch` must be an array");t._updateFetch(n.fetch)}};_.Collection.prototype.allow=function(n){e.call(this,"allow",n)},_.Collection.prototype.deny=function(n){e.call(this,"deny",n)}}(),_.Collection.prototype._defineMutationMethods=function(){var n=this;if(n._restricted=!1,n._insecure=void 0,n._validators={insert:{allow:[],deny:[]},update:{allow:[],deny:[]},remove:{allow:[],deny:[]},upsert:{allow:[],deny:[]},fetch:[],fetchAllFields:!1},n._name&&(n._prefix="/"+n._name+"/",n._connection)){var o={};r.each(["insert","update","remove"],function(t){o[n._prefix+t]=function(){u(arguments,[f.Any]);var o=r.toArray(arguments);try{var i=null;if("insert"!==t||r.has(o[0],"_id")||(i=n._makeNewID()),this.isSimulation)return null!==i&&(o[0]._id=i),n._collection[t].apply(n._collection,o);if("insert"!==t&&c(o[0],t),n._restricted){if(0===n._validators[t].allow.length)throw new e.Error(403,"Access denied. No allow validators set on restricted collection for method '"+t+"'.");var l="_validated"+t.charAt(0).toUpperCase()+t.slice(1);return o.unshift(this.userId),"insert"===t&&o.push(i),n[l].apply(n,o)}if(n._isInsecure())return null!==i&&(o[0]._id=i),n._collection[t].apply(n._collection,o);throw new e.Error(403,"Access denied")}catch(a){throw"MongoError"===a.name||"MinimongoError"===a.name?new e.Error(409,a.toString()):a}}}),(e.isClient||n._connection===e.server)&&n._connection.methods(o)}},_.Collection.prototype._updateFetch=function(e){var n=this;n._validators.fetchAllFields||(e?n._validators.fetch=r.union(n._validators.fetch,e):(n._validators.fetchAllFields=!0,n._validators.fetch=null))},_.Collection.prototype._isInsecure=function(){var e=this;return void 0===e._insecure?!!Package.insecure:e._insecure};var l=function(e,n,t){var r=n;return e.transform&&(r=o.clone(n),null!==t&&(r._id=t),r=e.transform(r)),r};_.Collection.prototype._validatedInsert=function(n,o,t){var i=this;if(r.any(i._validators.insert.deny,function(e){return e(n,l(e,o,t))}))throw new e.Error(403,"Access denied");if(r.all(i._validators.insert.allow,function(e){return!e(n,l(e,o,t))}))throw new e.Error(403,"Access denied");null!==t&&(o._id=t),i._collection.insert.call(i._collection,o)};var s=function(e,n){return e.transform?e.transform(n):n};_.Collection.prototype._validatedUpdate=function(n,o,t,c){var l=this;if(u(t,Object),c=r.clone(c)||{},!i._selectorIsIdPerhapsAsObject(o))throw new Error("validated update should be of a single ID");if(c.upsert)throw new e.Error(403,"Access denied. Upserts not allowed in a restricted collection.");var a="Access denied. In a restricted collection you can only update documents, not replace them. Use a Mongo update operator, such as '$set'.",f=[];if(r.isEmpty(t))throw new e.Error(403,a);r.each(t,function(n,o){if("$"!==o.charAt(0))throw new e.Error(403,a);if(!r.has(d,o))throw new e.Error(403,"Access denied. Operator "+o+" not allowed in a restricted collection.");r.each(r.keys(n),function(e){-1!==e.indexOf(".")&&(e=e.substring(0,e.indexOf("."))),r.contains(f,e)||f.push(e)})});var _={transform:null};l._validators.fetchAllFields||(_.fields={},r.each(l._validators.fetch,function(e){_.fields[e]=1}));var p=l._collection.findOne(o,_);if(!p)return 0;var h;if(r.any(l._validators.update.deny,function(e){return h||(h=s(e,p)),e(n,h,f,t)}))throw new e.Error(403,"Access denied");if(r.all(l._validators.update.allow,function(e){return h||(h=s(e,p)),!e(n,h,f,t)}))throw new e.Error(403,"Access denied");return c._forbidReplace=!0,l._collection.update.call(l._collection,o,t,c)};var d={$inc:1,$set:1,$unset:1,$addToSet:1,$pop:1,$pullAll:1,$pull:1,$pushAll:1,$push:1,$bit:1};_.Collection.prototype._validatedRemove=function(n,o){var t=this,i={transform:null};t._validators.fetchAllFields||(i.fields={},r.each(t._validators.fetch,function(e){i.fields[e]=1}));var c=t._collection.findOne(o,i);if(!c)return 0;if(r.any(t._validators.remove.deny,function(e){return e(n,s(e,c))}))throw new e.Error(403,"Access denied");if(r.all(t._validators.remove.allow,function(e){return!e(n,s(e,c))}))throw new e.Error(403,"Access denied");return t._collection.remove.call(t._collection,o)},e.Collection=_.Collection}.call(this),"undefined"==typeof Package&&(Package={}),Package.mongo={Mongo:_}}();
+
+!function(){var e=Package.meteor.Meteor,t=Package.tracker.Tracker,n=Package.tracker.Deps,a=Package.retry.Retry,r=Package.ddp.DDP,o=Package.mongo.Mongo,i=Package.underscore._,s,c;(function(){var t=__meteor_runtime_config__.autoupdateVersion||"unknown",n=__meteor_runtime_config__.autoupdateVersionRefreshable||"unknown";c=new o.Collection("meteor_autoupdate_clientVersions"),s={},s.newClientAvailable=function(){return!!c.findOne({_id:"version",version:{$ne:t}})||!!c.findOne({_id:"version-refreshable",version:{$ne:n}})};var r=!1,u=new a({minCount:0,baseTimeout:3e4}),l=0;s._retrySubscription=function(){e.subscribe("meteor_autoupdate_clientVersions",{onError:function(t){e._debug("autoupdate subscription failed:",t),l++,u.retryLater(l,function(){s._retrySubscription()})},onReady:function(){if(Package.reload)var a=function(a){var s=this;if("version-refreshable"===a._id&&a.version!==n){n=a.version;var c=a.assets&&a.assets.allCss||[],u=[];i.each(document.getElementsByTagName("link"),function(e){"__meteor-css__"===e.className&&u.push(e)});var l=function(t,n){var a=i.once(n);if(t.onload=function(){r=!0,a()},!r)var o=e.setInterval(function(){t.sheet&&(a(),e.clearInterval(o))},50)},d=i.after(c.length,function(){i.each(u,function(e){e.parentNode.removeChild(e)})}),_=function(t){document.getElementsByTagName("head").item(0).appendChild(t),l(t,function(){e.setTimeout(d,200)})};0!==c.length?i.each(c,function(t){var n=document.createElement("link");n.setAttribute("rel","stylesheet"),n.setAttribute("type","text/css"),n.setAttribute("class","__meteor-css__"),n.setAttribute("href",e._relativeToSiteRootUrl(t.url)),_(n)}):d()}else"version"===a._id&&a.version!==t&&(o&&o.stop(),Package.reload.Reload._reload())},o=c.find().observe({added:a,changed:a})}})},s._retrySubscription()}).call(this),"undefined"==typeof Package&&(Package={}),Package.autoupdate={Autoupdate:s}}();
+
+!function(){var a=Package.meteor.Meteor,e=Package.reload.Reload,o=Package.autoupdate.Autoupdate;"undefined"==typeof Package&&(Package={}),Package["meteor-platform"]={}}();
+
+!function(){var t=Package.meteor.Meteor,e,n;(function(){n={exports:{}}}).call(this),function(){function t(n,i){"use strict";function o(t,e){return function(){return t.apply(e,arguments)}}var r;if(i=i||{},this.trackingClick=!1,this.trackingClickStart=0,this.targetElement=null,this.touchStartX=0,this.touchStartY=0,this.lastTouchIdentifier=0,this.touchBoundary=i.touchBoundary||10,this.layer=n,this.tapDelay=i.tapDelay||200,!t.notNeeded(n)){for(var c=["onMouse","onClick","onTouchStart","onTouchMove","onTouchEnd","onTouchCancel"],s=this,a=0,u=c.length;u>a;a++)s[c[a]]=o(s[c[a]],s);e&&(n.addEventListener("mouseover",this.onMouse,!0),n.addEventListener("mousedown",this.onMouse,!0),n.addEventListener("mouseup",this.onMouse,!0)),n.addEventListener("click",this.onClick,!0),n.addEventListener("touchstart",this.onTouchStart,!1),n.addEventListener("touchmove",this.onTouchMove,!1),n.addEventListener("touchend",this.onTouchEnd,!1),n.addEventListener("touchcancel",this.onTouchCancel,!1),Event.prototype.stopImmediatePropagation||(n.removeEventListener=function(t,e,i){var o=Node.prototype.removeEventListener;"click"===t?o.call(n,t,e.hijacked||e,i):o.call(n,t,e,i)},n.addEventListener=function(t,e,i){var o=Node.prototype.addEventListener;"click"===t?o.call(n,t,e.hijacked||(e.hijacked=function(t){t.propagationStopped||e(t)}),i):o.call(n,t,e,i)}),"function"==typeof n.onclick&&(r=n.onclick,n.addEventListener("click",function(t){r(t)},!1),n.onclick=null)}}var e=navigator.userAgent.indexOf("Android")>0,i=/iP(ad|hone|od)/.test(navigator.userAgent),o=i&&/OS 4_\d(_\d)?/.test(navigator.userAgent),r=i&&/OS ([6-9]|\d{2})_\d/.test(navigator.userAgent),c=navigator.userAgent.indexOf("BB10")>0;t.prototype.needsClick=function(t){"use strict";switch(t.nodeName.toLowerCase()){case"button":case"select":case"textarea":if(t.disabled)return!0;break;case"input":if(i&&"file"===t.type||t.disabled)return!0;break;case"label":case"video":return!0}return/\bneedsclick\b/.test(t.className)},t.prototype.needsFocus=function(t){"use strict";switch(t.nodeName.toLowerCase()){case"textarea":return!0;case"select":return!e;case"input":switch(t.type){case"button":case"checkbox":case"file":case"image":case"radio":case"submit":return!1}return!t.disabled&&!t.readOnly;default:return/\bneedsfocus\b/.test(t.className)}},t.prototype.sendClick=function(t,e){"use strict";var n,i;document.activeElement&&document.activeElement!==t&&document.activeElement.blur(),i=e.changedTouches[0],n=document.createEvent("MouseEvents"),n.initMouseEvent(this.determineEventType(t),!0,!0,window,1,i.screenX,i.screenY,i.clientX,i.clientY,!1,!1,!1,!1,0,null),n.forwardedTouchEvent=!0,t.dispatchEvent(n)},t.prototype.determineEventType=function(t){"use strict";return e&&"select"===t.tagName.toLowerCase()?"mousedown":"click"},t.prototype.focus=function(t){"use strict";var e;i&&t.setSelectionRange&&0!==t.type.indexOf("date")&&"time"!==t.type?(e=t.value.length,t.setSelectionRange(e,e)):t.focus()},t.prototype.updateScrollParent=function(t){"use strict";var e,n;if(e=t.fastClickScrollParent,!e||!e.contains(t)){n=t;do{if(n.scrollHeight>n.offsetHeight){e=n,t.fastClickScrollParent=n;break}n=n.parentElement}while(n)}e&&(e.fastClickLastScrollTop=e.scrollTop)},t.prototype.getTargetElementFromEventTarget=function(t){"use strict";return t.nodeType===Node.TEXT_NODE?t.parentNode:t},t.prototype.onTouchStart=function(t){"use strict";var e,n,r;if(t.targetTouches.length>1)return!0;if(e=this.getTargetElementFromEventTarget(t.target),n=t.targetTouches[0],i){if(r=window.getSelection(),r.rangeCount&&!r.isCollapsed)return!0;if(!o){if(n.identifier&&n.identifier===this.lastTouchIdentifier)return t.preventDefault(),!1;this.lastTouchIdentifier=n.identifier,this.updateScrollParent(e)}}return this.trackingClick=!0,this.trackingClickStart=t.timeStamp,this.targetElement=e,this.touchStartX=n.pageX,this.touchStartY=n.pageY,t.timeStamp-this.lastClickTime<this.tapDelay&&t.preventDefault(),!0},t.prototype.touchHasMoved=function(t){"use strict";var e=t.changedTouches[0],n=this.touchBoundary;return Math.abs(e.pageX-this.touchStartX)>n||Math.abs(e.pageY-this.touchStartY)>n?!0:!1},t.prototype.onTouchMove=function(t){"use strict";return this.trackingClick?((this.targetElement!==this.getTargetElementFromEventTarget(t.target)||this.touchHasMoved(t))&&(this.trackingClick=!1,this.targetElement=null),!0):!0},t.prototype.findControl=function(t){"use strict";return void 0!==t.control?t.control:t.htmlFor?document.getElementById(t.htmlFor):t.querySelector("button, input:not([type=hidden]), keygen, meter, output, progress, select, textarea")},t.prototype.onTouchEnd=function(t){"use strict";var n,c,s,a,u,l=this.targetElement;if(!this.trackingClick)return!0;if(t.timeStamp-this.lastClickTime<this.tapDelay)return this.cancelNextClick=!0,!0;if(this.cancelNextClick=!1,this.lastClickTime=t.timeStamp,c=this.trackingClickStart,this.trackingClick=!1,this.trackingClickStart=0,r&&(u=t.changedTouches[0],l=document.elementFromPoint(u.pageX-window.pageXOffset,u.pageY-window.pageYOffset)||l,l.fastClickScrollParent=this.targetElement.fastClickScrollParent),s=l.tagName.toLowerCase(),"label"===s){if(n=this.findControl(l)){if(this.focus(l),e)return!1;l=n}}else if(this.needsFocus(l))return t.timeStamp-c>100||i&&window.top!==window&&"input"===s?(this.targetElement=null,!1):(this.focus(l),this.sendClick(l,t),i&&"select"===s||(this.targetElement=null,t.preventDefault()),!1);return i&&!o&&(a=l.fastClickScrollParent,a&&a.fastClickLastScrollTop!==a.scrollTop)?!0:(this.needsClick(l)||(t.preventDefault(),this.sendClick(l,t)),!1)},t.prototype.onTouchCancel=function(){"use strict";this.trackingClick=!1,this.targetElement=null},t.prototype.onMouse=function(t){"use strict";return this.targetElement?t.forwardedTouchEvent?!0:t.cancelable&&(!this.needsClick(this.targetElement)||this.cancelNextClick)?(t.stopImmediatePropagation?t.stopImmediatePropagation():t.propagationStopped=!0,t.stopPropagation(),t.preventDefault(),!1):!0:!0},t.prototype.onClick=function(t){"use strict";var e;return this.trackingClick?(this.targetElement=null,this.trackingClick=!1,!0):"submit"===t.target.type&&0===t.detail?!0:(e=this.onMouse(t),e||(this.targetElement=null),e)},t.prototype.destroy=function(){"use strict";var t=this.layer;e&&(t.removeEventListener("mouseover",this.onMouse,!0),t.removeEventListener("mousedown",this.onMouse,!0),t.removeEventListener("mouseup",this.onMouse,!0)),t.removeEventListener("click",this.onClick,!0),t.removeEventListener("touchstart",this.onTouchStart,!1),t.removeEventListener("touchmove",this.onTouchMove,!1),t.removeEventListener("touchend",this.onTouchEnd,!1),t.removeEventListener("touchcancel",this.onTouchCancel,!1)},t.notNeeded=function(t){"use strict";var n,i,o;if("undefined"==typeof window.ontouchstart)return!0;if(i=+(/Chrome\/([0-9]+)/.exec(navigator.userAgent)||[,0])[1]){if(!e)return!0;if(n=document.querySelector("meta[name=viewport]")){if(-1!==n.content.indexOf("user-scalable=no"))return!0;if(i>31&&document.documentElement.scrollWidth<=window.outerWidth)return!0}}if(c&&(o=navigator.userAgent.match(/Version\/([0-9]*)\.([0-9]*)/),o[1]>=10&&o[2]>=3&&(n=document.querySelector("meta[name=viewport]")))){if(-1!==n.content.indexOf("user-scalable=no"))return!0;if(document.documentElement.scrollWidth<=window.outerWidth)return!0}return"none"===t.style.msTouchAction?!0:!1},t.attach=function(e,n){"use strict";return new t(e,n)},"function"==typeof define&&"object"==typeof define.amd&&define.amd?define(function(){"use strict";return t}):"undefined"!=typeof n&&n.exports?(n.exports=t.attach,n.exports.FastClick=t):window.FastClick=t}.call(this),function(){e=n.exports.FastClick,t.startup(function(){e.attach(document.body)})}.call(this),"undefined"==typeof Package&&(Package={}),Package.fastclick={FastClick:e}}();
+
+!function(){var e=Package.meteor.Meteor;"undefined"==typeof Package&&(Package={}),Package.less={}}();
+
+!function(){var e=Package.meteor.Meteor,n;(function(){n={},function(e){function n(e,n){var o={};if(t(e)&&e.length>0)for(var r=n?c:i,a=e.split(/;\s/g),u,f,s,g=0,p=a.length;p>g;g++){if(s=a[g].match(/([^=]+)=/i),s instanceof Array)try{u=c(s[1]),f=r(a[g].substring(s[1].length+1))}catch(m){}else u=c(a[g]),f="";u&&(o[u]=f)}return o}function t(e){return"string"==typeof e}function o(e){return t(e)&&""!==e}function r(e){if(!o(e))throw new TypeError("Cookie name must be a non-empty string")}function i(e){return e}var a=e,c=decodeURIComponent,u=encodeURIComponent;a.get=function(e,t){r(e),t="function"==typeof t?{converter:t}:t||{};var o=n(document.cookie,!t.raw);return(t.converter||i)(o[e])},a.set=function(e,n,t){r(e),t=t||{};var i=t.expires,a=t.domain,c=t.path;t.raw||(n=u(String(n)));var f=e+"="+n,s=i;return"number"==typeof s&&(s=new Date,s.setDate(s.getDate()+i)),s instanceof Date&&(f+="; expires="+s.toUTCString()),o(a)&&(f+="; domain="+a),o(c)&&(f+="; path="+c),t.secure&&(f+="; secure"),document.cookie=f,f},a.remove=function(e,n){return n=n||{},n.expires=new Date(0),this.set(e,"",n)}}(n)}).call(this),"undefined"==typeof Package&&(Package={}),Package["chuangbo:cookie"]={Cookie:n}}();
+
+!function(){var e=Package.meteor.Meteor,t=Package.underscore._,a;(function(){(function(e){function t(e,t,a){switch(arguments.length){case 2:return null!=e?e:t;case 3:return null!=e?e:null!=t?t:a;default:throw new Error("Implement me")}}function a(e,t){return wt.call(e,t)}function n(){return{empty:!1,unusedTokens:[],unusedInput:[],overflow:-2,charsLeftOver:0,nullInput:!1,invalidMonth:null,invalidFormat:!1,userInvalidated:!1,iso:!1}}function _(e){ft.suppressDeprecationWarnings===!1&&"undefined"!=typeof console&&console.warn&&console.warn("Deprecation warning: "+e)}function s(e,t){var a=!0;return m(function(){return a&&(_(e),a=!1),t.apply(this,arguments)},t)}function r(e,t){ha[e]||(_(t),ha[e]=!0)}function d(e,t){return function(a){return L(e.call(this,a),t)}}function i(e,t){return function(a){return this.localeData().ordinal(e.call(this,a),t)}}function o(){}function u(e,t){t!==!1&&x(e),M(this,e),this._d=new Date(+e._d)}function l(e){var t=g(e),a=t.year||0,n=t.quarter||0,_=t.month||0,s=t.week||0,r=t.day||0,d=t.hour||0,i=t.minute||0,o=t.second||0,u=t.millisecond||0;this._milliseconds=+u+1e3*o+6e4*i+36e5*d,this._days=+r+7*s,this._months=+_+3*n+12*a,this._data={},this._locale=ft.localeData(),this._bubble()}function m(e,t){for(var n in t)a(t,n)&&(e[n]=t[n]);return a(t,"toString")&&(e.toString=t.toString),a(t,"valueOf")&&(e.valueOf=t.valueOf),e}function M(e,t){var a,n,_;if("undefined"!=typeof t._isAMomentObject&&(e._isAMomentObject=t._isAMomentObject),"undefined"!=typeof t._i&&(e._i=t._i),"undefined"!=typeof t._f&&(e._f=t._f),"undefined"!=typeof t._l&&(e._l=t._l),"undefined"!=typeof t._strict&&(e._strict=t._strict),"undefined"!=typeof t._tzm&&(e._tzm=t._tzm),"undefined"!=typeof t._isUTC&&(e._isUTC=t._isUTC),"undefined"!=typeof t._offset&&(e._offset=t._offset),"undefined"!=typeof t._pf&&(e._pf=t._pf),"undefined"!=typeof t._locale&&(e._locale=t._locale),Ft.length>0)for(a in Ft)n=Ft[a],_=t[n],"undefined"!=typeof _&&(e[n]=_);return e}function c(e){return 0>e?Math.ceil(e):Math.floor(e)}function L(e,t,a){for(var n=""+Math.abs(e),_=e>=0;n.length<t;)n="0"+n;return(_?a?"+":"":"-")+n}function h(e,t){var a={milliseconds:0,months:0};return a.months=t.month()-e.month()+12*(t.year()-e.year()),e.clone().add(a.months,"M").isAfter(t)&&--a.months,a.milliseconds=+t-+e.clone().add(a.months,"M"),a}function Y(e,t){var a;return t=A(t,e),e.isBefore(t)?a=h(e,t):(a=h(t,e),a.milliseconds=-a.milliseconds,a.months=-a.months),a}function y(e,t){return function(a,n){var _,s;return null===n||isNaN(+n)||(r(t,"moment()."+t+"(period, number) is deprecated. Please use moment()."+t+"(number, period)."),s=a,a=n,n=s),a="string"==typeof a?+a:a,_=ft.duration(a,n),f(this,_,e),this}}function f(e,t,a,n){var _=t._milliseconds,s=t._days,r=t._months;n=null==n?!0:n,_&&e._d.setTime(+e._d+_*a),s&&Mt(e,"Date",mt(e,"Date")+s*a),r&&lt(e,mt(e,"Month")+r*a),n&&ft.updateOffset(e,s||r)}function p(e){return"[object Array]"===Object.prototype.toString.call(e)}function D(e){return"[object Date]"===Object.prototype.toString.call(e)||e instanceof Date}function k(e,t,a){var n,_=Math.min(e.length,t.length),s=Math.abs(e.length-t.length),r=0;for(n=0;_>n;n++)(a&&e[n]!==t[n]||!a&&v(e[n])!==v(t[n]))&&r++;return r+s}function T(e){if(e){var t=e.toLowerCase().replace(/(.)s$/,"$1");e=oa[e]||ua[t]||t}return e}function g(e){var t,n,_={};for(n in e)a(e,n)&&(t=T(n),t&&(_[t]=e[n]));return _}function w(t){var a,n;if(0===t.indexOf("week"))a=7,n="day";else{if(0!==t.indexOf("month"))return;a=12,n="month"}ft[t]=function(_,s){var r,d,i=ft._locale[t],o=[];if("number"==typeof _&&(s=_,_=e),d=function(e){var t=ft().utc().set(n,e);return i.call(ft._locale,t,_||"")},null!=s)return d(s);for(r=0;a>r;r++)o.push(d(r));return o}}function v(e){var t=+e,a=0;return 0!==t&&isFinite(t)&&(a=t>=0?Math.floor(t):Math.ceil(t)),a}function b(e,t){return new Date(Date.UTC(e,t+1,0)).getUTCDate()}function S(e,t,a){return dt(ft([e,11,31+t-a]),t,a).week}function j(e){return W(e)?366:365}function W(e){return e%4===0&&e%100!==0||e%400===0}function x(e){var t;e._a&&-2===e._pf.overflow&&(t=e._a[bt]<0||e._a[bt]>11?bt:e._a[St]<1||e._a[St]>b(e._a[vt],e._a[bt])?St:e._a[jt]<0||e._a[jt]>23?jt:e._a[Wt]<0||e._a[Wt]>59?Wt:e._a[xt]<0||e._a[xt]>59?xt:e._a[zt]<0||e._a[zt]>999?zt:-1,e._pf._overflowDayOfYear&&(vt>t||t>St)&&(t=St),e._pf.overflow=t)}function z(e){return null==e._isValid&&(e._isValid=!isNaN(e._d.getTime())&&e._pf.overflow<0&&!e._pf.empty&&!e._pf.invalidMonth&&!e._pf.nullInput&&!e._pf.invalidFormat&&!e._pf.userInvalidated,e._strict&&(e._isValid=e._isValid&&0===e._pf.charsLeftOver&&0===e._pf.unusedTokens.length)),e._isValid}function H(e){return e?e.toLowerCase().replace("_","-"):e}function F(e){for(var t,a,n,_,s=0;s<e.length;){for(_=H(e[s]).split("-"),t=_.length,a=H(e[s+1]),a=a?a.split("-"):null;t>0;){if(n=E(_.slice(0,t).join("-")))return n;if(a&&a.length>=t&&k(_,a,!0)>=t-1)break;t--}s++}return null}function E(e){var t=null;if(!Ht[e]&&Et)try{t=ft.locale(),require("./locale/"+e),ft.locale(t)}catch(a){}return Ht[e]}function A(e,t){return t._isUTC?ft(e).zone(t._offset||0):ft(e).local()}function O(e){return e.match(/\[[\s\S]/)?e.replace(/^\[|\]$/g,""):e.replace(/\\/g,"")}function J(e){var t,a,n=e.match(Gt);for(t=0,a=n.length;a>t;t++)n[t]=La[n[t]]?La[n[t]]:O(n[t]);return function(_){var s="";for(t=0;a>t;t++)s+=n[t]instanceof Function?n[t].call(_,e):n[t];return s}}function G(e,t){return e.isValid()?(t=P(t,e.localeData()),la[t]||(la[t]=J(t)),la[t](e)):e.localeData().invalidDate()}function P(e,t){function a(e){return t.longDateFormat(e)||e}var n=5;for(Pt.lastIndex=0;n>=0&&Pt.test(e);)e=e.replace(Pt,a),Pt.lastIndex=0,n-=1;return e}function C(e,t){var a,n=t._strict;switch(e){case"Q":return Bt;case"DDDD":return Qt;case"YYYY":case"GGGG":case"gggg":return n?ea:Ut;case"Y":case"G":case"g":return aa;case"YYYYYY":case"YYYYY":case"GGGGG":case"ggggg":return n?ta:Nt;case"S":if(n)return Bt;case"SS":if(n)return Xt;case"SSS":if(n)return Qt;case"DDD":return It;case"MMM":case"MMMM":case"dd":case"ddd":case"dddd":return qt;case"a":case"A":return t._locale._meridiemParse;case"X":return $t;case"Z":case"ZZ":return Zt;case"T":return Kt;case"SSSS":return Vt;case"MM":case"DD":case"YY":case"GG":case"gg":case"HH":case"hh":case"mm":case"ss":case"ww":case"WW":return n?Xt:Ct;case"M":case"D":case"d":case"H":case"h":case"m":case"s":case"w":case"W":case"e":case"E":return Ct;case"Do":return Rt;default:return a=new RegExp(R($(e.replace("\\","")),"i"))}}function I(e){e=e||"";var t=e.match(Zt)||[],a=t[t.length-1]||[],n=(a+"").match(da)||["-",0,0],_=+(60*n[1])+v(n[2]);return"+"===n[0]?-_:_}function U(e,t,a){var n,_=a._a;switch(e){case"Q":null!=t&&(_[bt]=3*(v(t)-1));break;case"M":case"MM":null!=t&&(_[bt]=v(t)-1);break;case"MMM":case"MMMM":n=a._locale.monthsParse(t),null!=n?_[bt]=n:a._pf.invalidMonth=t;break;case"D":case"DD":null!=t&&(_[St]=v(t));break;case"Do":null!=t&&(_[St]=v(parseInt(t,10)));break;case"DDD":case"DDDD":null!=t&&(a._dayOfYear=v(t));break;case"YY":_[vt]=ft.parseTwoDigitYear(t);break;case"YYYY":case"YYYYY":case"YYYYYY":_[vt]=v(t);break;case"a":case"A":a._isPm=a._locale.isPM(t);break;case"H":case"HH":case"h":case"hh":_[jt]=v(t);break;case"m":case"mm":_[Wt]=v(t);break;case"s":case"ss":_[xt]=v(t);break;case"S":case"SS":case"SSS":case"SSSS":_[zt]=v(1e3*("0."+t));break;case"X":a._d=new Date(1e3*parseFloat(t));break;case"Z":case"ZZ":a._useUTC=!0,a._tzm=I(t);break;case"dd":case"ddd":case"dddd":n=a._locale.weekdaysParse(t),null!=n?(a._w=a._w||{},a._w.d=n):a._pf.invalidWeekday=t;break;case"w":case"ww":case"W":case"WW":case"d":case"e":case"E":e=e.substr(0,1);case"gggg":case"GGGG":case"GGGGG":e=e.substr(0,2),t&&(a._w=a._w||{},a._w[e]=v(t));break;case"gg":case"GG":a._w=a._w||{},a._w[e]=ft.parseTwoDigitYear(t)}}function N(e){var a,n,_,s,r,d,i;a=e._w,null!=a.GG||null!=a.W||null!=a.E?(r=1,d=4,n=t(a.GG,e._a[vt],dt(ft(),1,4).year),_=t(a.W,1),s=t(a.E,1)):(r=e._locale._week.dow,d=e._locale._week.doy,n=t(a.gg,e._a[vt],dt(ft(),r,d).year),_=t(a.w,1),null!=a.d?(s=a.d,r>s&&++_):s=null!=a.e?a.e+r:r),i=it(n,_,s,d,r),e._a[vt]=i.year,e._dayOfYear=i.dayOfYear}function V(e){var a,n,_,s,r=[];if(!e._d){for(_=Z(e),e._w&&null==e._a[St]&&null==e._a[bt]&&N(e),e._dayOfYear&&(s=t(e._a[vt],_[vt]),e._dayOfYear>j(s)&&(e._pf._overflowDayOfYear=!0),n=nt(s,0,e._dayOfYear),e._a[bt]=n.getUTCMonth(),e._a[St]=n.getUTCDate()),a=0;3>a&&null==e._a[a];++a)e._a[a]=r[a]=_[a];for(;7>a;a++)e._a[a]=r[a]=null==e._a[a]?2===a?1:0:e._a[a];e._d=(e._useUTC?nt:at).apply(null,r),null!=e._tzm&&e._d.setUTCMinutes(e._d.getUTCMinutes()+e._tzm)}}function q(e){var t;e._d||(t=g(e._i),e._a=[t.year,t.month,t.day,t.hour,t.minute,t.second,t.millisecond],V(e))}function Z(e){var t=new Date;return e._useUTC?[t.getUTCFullYear(),t.getUTCMonth(),t.getUTCDate()]:[t.getFullYear(),t.getMonth(),t.getDate()]}function K(e){if(e._f===ft.ISO_8601)return void X(e);e._a=[],e._pf.empty=!0;var t,a,n,_,s,r=""+e._i,d=r.length,i=0;for(n=P(e._f,e._locale).match(Gt)||[],t=0;t<n.length;t++)_=n[t],a=(r.match(C(_,e))||[])[0],a&&(s=r.substr(0,r.indexOf(a)),s.length>0&&e._pf.unusedInput.push(s),r=r.slice(r.indexOf(a)+a.length),i+=a.length),La[_]?(a?e._pf.empty=!1:e._pf.unusedTokens.push(_),U(_,a,e)):e._strict&&!a&&e._pf.unusedTokens.push(_);e._pf.charsLeftOver=d-i,r.length>0&&e._pf.unusedInput.push(r),e._isPm&&e._a[jt]<12&&(e._a[jt]+=12),e._isPm===!1&&12===e._a[jt]&&(e._a[jt]=0),V(e),x(e)}function $(e){return e.replace(/\\(\[)|\\(\])|\[([^\]\[]*)\]|\\(.)/g,function(e,t,a,n,_){return t||a||n||_})}function R(e){return e.replace(/[-\/\\^$*+?.()|[\]{}]/g,"\\$&")}function B(e){var t,a,_,s,r;if(0===e._f.length)return e._pf.invalidFormat=!0,void(e._d=new Date(0/0));for(s=0;s<e._f.length;s++)r=0,t=M({},e),null!=e._useUTC&&(t._useUTC=e._useUTC),t._pf=n(),t._f=e._f[s],K(t),z(t)&&(r+=t._pf.charsLeftOver,r+=10*t._pf.unusedTokens.length,t._pf.score=r,(null==_||_>r)&&(_=r,a=t));m(e,a||t)}function X(e){var t,a,n=e._i,_=na.exec(n);if(_){for(e._pf.iso=!0,t=0,a=sa.length;a>t;t++)if(sa[t][1].exec(n)){e._f=sa[t][0]+(_[6]||" ");break}for(t=0,a=ra.length;a>t;t++)if(ra[t][1].exec(n)){e._f+=ra[t][0];break}n.match(Zt)&&(e._f+="Z"),K(e)}else e._isValid=!1}function Q(e){X(e),e._isValid===!1&&(delete e._isValid,ft.createFromInputFallback(e))}function et(e,t){var a,n=[];for(a=0;a<e.length;++a)n.push(t(e[a],a));return n}function tt(t){var a,n=t._i;n===e?t._d=new Date:D(n)?t._d=new Date(+n):null!==(a=At.exec(n))?t._d=new Date(+a[1]):"string"==typeof n?Q(t):p(n)?(t._a=et(n.slice(0),function(e){return parseInt(e,10)}),V(t)):"object"==typeof n?q(t):"number"==typeof n?t._d=new Date(n):ft.createFromInputFallback(t)}function at(e,t,a,n,_,s,r){var d=new Date(e,t,a,n,_,s,r);return 1970>e&&d.setFullYear(e),d}function nt(e){var t=new Date(Date.UTC.apply(null,arguments));return 1970>e&&t.setUTCFullYear(e),t}function _t(e,t){if("string"==typeof e)if(isNaN(e)){if(e=t.weekdaysParse(e),"number"!=typeof e)return null}else e=parseInt(e,10);return e}function st(e,t,a,n,_){return _.relativeTime(t||1,!!a,e,n)}function rt(e,t,a){var n=ft.duration(e).abs(),_=gt(n.as("s")),s=gt(n.as("m")),r=gt(n.as("h")),d=gt(n.as("d")),i=gt(n.as("M")),o=gt(n.as("y")),u=_<ma.s&&["s",_]||1===s&&["m"]||s<ma.m&&["mm",s]||1===r&&["h"]||r<ma.h&&["hh",r]||1===d&&["d"]||d<ma.d&&["dd",d]||1===i&&["M"]||i<ma.M&&["MM",i]||1===o&&["y"]||["yy",o];return u[2]=t,u[3]=+e>0,u[4]=a,st.apply({},u)}function dt(e,t,a){var n,_=a-t,s=a-e.day();return s>_&&(s-=7),_-7>s&&(s+=7),n=ft(e).add(s,"d"),{week:Math.ceil(n.dayOfYear()/7),year:n.year()}}function it(e,t,a,n,_){var s,r,d=nt(e,0,1).getUTCDay();return d=0===d?7:d,a=null!=a?a:_,s=_-d+(d>n?7:0)-(_>d?7:0),r=7*(t-1)+(a-_)+s+1,{year:r>0?e:e-1,dayOfYear:r>0?r:j(e-1)+r}}function ot(t){var a=t._i,n=t._f;return t._locale=t._locale||ft.localeData(t._l),null===a||n===e&&""===a?ft.invalid({nullInput:!0}):("string"==typeof a&&(t._i=a=t._locale.preparse(a)),ft.isMoment(a)?new u(a,!0):(n?p(n)?B(t):K(t):tt(t),new u(t)))}function ut(e,t){var a,n;if(1===t.length&&p(t[0])&&(t=t[0]),!t.length)return ft();for(a=t[0],n=1;n<t.length;++n)t[n][e](a)&&(a=t[n]);return a}function lt(e,t){var a;return"string"==typeof t&&(t=e.localeData().monthsParse(t),"number"!=typeof t)?e:(a=Math.min(e.date(),b(e.year(),t)),e._d["set"+(e._isUTC?"UTC":"")+"Month"](t,a),e)}function mt(e,t){return e._d["get"+(e._isUTC?"UTC":"")+t]()}function Mt(e,t,a){return"Month"===t?lt(e,a):e._d["set"+(e._isUTC?"UTC":"")+t](a)}function ct(e,t){return function(a){return null!=a?(Mt(this,e,a),ft.updateOffset(this,t),this):mt(this,e)}}function Lt(e){return 400*e/146097}function ht(e){return 146097*e/400}function Yt(e){ft.duration.fn[e]=function(){return this._data[e]}}function yt(e){"undefined"==typeof ender&&(pt=Tt.moment,Tt.moment=e?s("Accessing Moment through the global scope is deprecated, and will be removed in an upcoming release.",ft):ft)}for(var ft,pt,Dt,kt="2.8.3",Tt="undefined"!=typeof global?global:this,gt=Math.round,wt=Object.prototype.hasOwnProperty,vt=0,bt=1,St=2,jt=3,Wt=4,xt=5,zt=6,Ht={},Ft=[],Et="undefined"!=typeof module&&module.exports,At=/^\/?Date\((\-?\d+)/i,Ot=/(\-)?(?:(\d*)\.)?(\d+)\:(\d+)(?:\:(\d+)\.?(\d{3})?)?/,Jt=/^(-)?P(?:(?:([0-9,.]*)Y)?(?:([0-9,.]*)M)?(?:([0-9,.]*)D)?(?:T(?:([0-9,.]*)H)?(?:([0-9,.]*)M)?(?:([0-9,.]*)S)?)?|([0-9,.]*)W)$/,Gt=/(\[[^\[]*\])|(\\)?(Mo|MM?M?M?|Do|DDDo|DD?D?D?|ddd?d?|do?|w[o|w]?|W[o|W]?|Q|YYYYYY|YYYYY|YYYY|YY|gg(ggg?)?|GG(GGG?)?|e|E|a|A|hh?|HH?|mm?|ss?|S{1,4}|X|zz?|ZZ?|.)/g,Pt=/(\[[^\[]*\])|(\\)?(LT|LL?L?L?|l{1,4})/g,Ct=/\d\d?/,It=/\d{1,3}/,Ut=/\d{1,4}/,Nt=/[+\-]?\d{1,6}/,Vt=/\d+/,qt=/[0-9]*['a-z\u00A0-\u05FF\u0700-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]+|[\u0600-\u06FF\/]+(\s*?[\u0600-\u06FF]+){1,2}/i,Zt=/Z|[\+\-]\d\d:?\d\d/gi,Kt=/T/i,$t=/[\+\-]?\d+(\.\d{1,3})?/,Rt=/\d{1,2}/,Bt=/\d/,Xt=/\d\d/,Qt=/\d{3}/,ea=/\d{4}/,ta=/[+-]?\d{6}/,aa=/[+-]?\d+/,na=/^\s*(?:[+-]\d{6}|\d{4})-(?:(\d\d-\d\d)|(W\d\d$)|(W\d\d-\d)|(\d\d\d))((T| )(\d\d(:\d\d(:\d\d(\.\d+)?)?)?)?([\+\-]\d\d(?::?\d\d)?|\s*Z)?)?$/,_a="YYYY-MM-DDTHH:mm:ssZ",sa=[["YYYYYY-MM-DD",/[+-]\d{6}-\d{2}-\d{2}/],["YYYY-MM-DD",/\d{4}-\d{2}-\d{2}/],["GGGG-[W]WW-E",/\d{4}-W\d{2}-\d/],["GGGG-[W]WW",/\d{4}-W\d{2}/],["YYYY-DDD",/\d{4}-\d{3}/]],ra=[["HH:mm:ss.SSSS",/(T| )\d\d:\d\d:\d\d\.\d+/],["HH:mm:ss",/(T| )\d\d:\d\d:\d\d/],["HH:mm",/(T| )\d\d:\d\d/],["HH",/(T| )\d\d/]],da=/([\+\-]|\d\d)/gi,ia=("Date|Hours|Minutes|Seconds|Milliseconds".split("|"),{Milliseconds:1,Seconds:1e3,Minutes:6e4,Hours:36e5,Days:864e5,Months:2592e6,Years:31536e6}),oa={ms:"millisecond",s:"second",m:"minute",h:"hour",d:"day",D:"date",w:"week",W:"isoWeek",M:"month",Q:"quarter",y:"year",DDD:"dayOfYear",e:"weekday",E:"isoWeekday",gg:"weekYear",GG:"isoWeekYear"},ua={dayofyear:"dayOfYear",isoweekday:"isoWeekday",isoweek:"isoWeek",weekyear:"weekYear",isoweekyear:"isoWeekYear"},la={},ma={s:45,m:45,h:22,d:26,M:11},Ma="DDD w W M D d".split(" "),ca="M D H h m s w W".split(" "),La={M:function(){return this.month()+1},MMM:function(e){return this.localeData().monthsShort(this,e)},MMMM:function(e){return this.localeData().months(this,e)},D:function(){return this.date()},DDD:function(){return this.dayOfYear()},d:function(){return this.day()},dd:function(e){return this.localeData().weekdaysMin(this,e)},ddd:function(e){return this.localeData().weekdaysShort(this,e)},dddd:function(e){return this.localeData().weekdays(this,e)},w:function(){return this.week()},W:function(){return this.isoWeek()},YY:function(){return L(this.year()%100,2)},YYYY:function(){return L(this.year(),4)},YYYYY:function(){return L(this.year(),5)},YYYYYY:function(){var e=this.year(),t=e>=0?"+":"-";return t+L(Math.abs(e),6)},gg:function(){return L(this.weekYear()%100,2)},gggg:function(){return L(this.weekYear(),4)},ggggg:function(){return L(this.weekYear(),5)},GG:function(){return L(this.isoWeekYear()%100,2)},GGGG:function(){return L(this.isoWeekYear(),4)},GGGGG:function(){return L(this.isoWeekYear(),5)},e:function(){return this.weekday()},E:function(){return this.isoWeekday()},a:function(){return this.localeData().meridiem(this.hours(),this.minutes(),!0)},A:function(){return this.localeData().meridiem(this.hours(),this.minutes(),!1)},H:function(){return this.hours()},h:function(){return this.hours()%12||12},m:function(){return this.minutes()},s:function(){return this.seconds()},S:function(){return v(this.milliseconds()/100)},SS:function(){return L(v(this.milliseconds()/10),2)},SSS:function(){return L(this.milliseconds(),3)},SSSS:function(){return L(this.milliseconds(),3)},Z:function(){var e=-this.zone(),t="+";return 0>e&&(e=-e,t="-"),t+L(v(e/60),2)+":"+L(v(e)%60,2)},ZZ:function(){var e=-this.zone(),t="+";return 0>e&&(e=-e,t="-"),t+L(v(e/60),2)+L(v(e)%60,2)},z:function(){return this.zoneAbbr()},zz:function(){return this.zoneName()},X:function(){return this.unix()},Q:function(){return this.quarter()}},ha={},Ya=["months","monthsShort","weekdays","weekdaysShort","weekdaysMin"];Ma.length;)Dt=Ma.pop(),La[Dt+"o"]=i(La[Dt],Dt);for(;ca.length;)Dt=ca.pop(),La[Dt+Dt]=d(La[Dt],2);La.DDDD=d(La.DDD,3),m(o.prototype,{set:function(e){var t,a;for(a in e)t=e[a],"function"==typeof t?this[a]=t:this["_"+a]=t},_months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),months:function(e){return this._months[e.month()]},_monthsShort:"Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_"),monthsShort:function(e){return this._monthsShort[e.month()]},monthsParse:function(e){var t,a,n;for(this._monthsParse||(this._monthsParse=[]),t=0;12>t;t++)if(this._monthsParse[t]||(a=ft.utc([2e3,t]),n="^"+this.months(a,"")+"|^"+this.monthsShort(a,""),this._monthsParse[t]=new RegExp(n.replace(".",""),"i")),this._monthsParse[t].test(e))return t},_weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),weekdays:function(e){return this._weekdays[e.day()]},_weekdaysShort:"Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),weekdaysShort:function(e){return this._weekdaysShort[e.day()]},_weekdaysMin:"Su_Mo_Tu_We_Th_Fr_Sa".split("_"),weekdaysMin:function(e){return this._weekdaysMin[e.day()]},weekdaysParse:function(e){var t,a,n;for(this._weekdaysParse||(this._weekdaysParse=[]),t=0;7>t;t++)if(this._weekdaysParse[t]||(a=ft([2e3,1]).day(t),n="^"+this.weekdays(a,"")+"|^"+this.weekdaysShort(a,"")+"|^"+this.weekdaysMin(a,""),this._weekdaysParse[t]=new RegExp(n.replace(".",""),"i")),this._weekdaysParse[t].test(e))return t},_longDateFormat:{LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY LT",LLLL:"dddd, MMMM D, YYYY LT"},longDateFormat:function(e){var t=this._longDateFormat[e];return!t&&this._longDateFormat[e.toUpperCase()]&&(t=this._longDateFormat[e.toUpperCase()].replace(/MMMM|MM|DD|dddd/g,function(e){return e.slice(1)}),this._longDateFormat[e]=t),t},isPM:function(e){return"p"===(e+"").toLowerCase().charAt(0)},_meridiemParse:/[ap]\.?m?\.?/i,meridiem:function(e,t,a){return e>11?a?"pm":"PM":a?"am":"AM"},_calendar:{sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"},calendar:function(e,t){var a=this._calendar[e];return"function"==typeof a?a.apply(t):a},_relativeTime:{future:"in %s",past:"%s ago",s:"a few seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",M:"a month",MM:"%d months",y:"a year",yy:"%d years"},relativeTime:function(e,t,a,n){var _=this._relativeTime[a];return"function"==typeof _?_(e,t,a,n):_.replace(/%d/i,e)},pastFuture:function(e,t){var a=this._relativeTime[e>0?"future":"past"];return"function"==typeof a?a(t):a.replace(/%s/i,t)},ordinal:function(e){return this._ordinal.replace("%d",e)},_ordinal:"%d",preparse:function(e){return e},postformat:function(e){return e},week:function(e){return dt(e,this._week.dow,this._week.doy).week},_week:{dow:0,doy:6},_invalidDate:"Invalid date",invalidDate:function(){return this._invalidDate}}),ft=function(t,a,_,s){var r;return"boolean"==typeof _&&(s=_,_=e),r={},r._isAMomentObject=!0,r._i=t,r._f=a,r._l=_,r._strict=s,r._isUTC=!1,r._pf=n(),ot(r)},ft.suppressDeprecationWarnings=!1,ft.createFromInputFallback=s("moment construction falls back to js Date. This is discouraged and will be removed in upcoming major release. Please refer to https://github.com/moment/moment/issues/1407 for more info.",function(e){e._d=new Date(e._i)}),ft.min=function(){var e=[].slice.call(arguments,0);return ut("isBefore",e)},ft.max=function(){var e=[].slice.call(arguments,0);return ut("isAfter",e)},ft.utc=function(t,a,_,s){var r;return"boolean"==typeof _&&(s=_,_=e),r={},r._isAMomentObject=!0,r._useUTC=!0,r._isUTC=!0,r._l=_,r._i=t,r._f=a,r._strict=s,r._pf=n(),ot(r).utc()},ft.unix=function(e){return ft(1e3*e)},ft.duration=function(e,t){var n,_,s,r,d=e,i=null;return ft.isDuration(e)?d={ms:e._milliseconds,d:e._days,M:e._months}:"number"==typeof e?(d={},t?d[t]=e:d.milliseconds=e):(i=Ot.exec(e))?(n="-"===i[1]?-1:1,d={y:0,d:v(i[St])*n,h:v(i[jt])*n,m:v(i[Wt])*n,s:v(i[xt])*n,ms:v(i[zt])*n}):(i=Jt.exec(e))?(n="-"===i[1]?-1:1,s=function(e){var t=e&&parseFloat(e.replace(",","."));return(isNaN(t)?0:t)*n},d={y:s(i[2]),M:s(i[3]),d:s(i[4]),h:s(i[5]),m:s(i[6]),s:s(i[7]),w:s(i[8])}):"object"==typeof d&&("from"in d||"to"in d)&&(r=Y(ft(d.from),ft(d.to)),d={},d.ms=r.milliseconds,d.M=r.months),_=new l(d),ft.isDuration(e)&&a(e,"_locale")&&(_._locale=e._locale),_},ft.version=kt,ft.defaultFormat=_a,ft.ISO_8601=function(){},ft.momentProperties=Ft,ft.updateOffset=function(){},ft.relativeTimeThreshold=function(t,a){return ma[t]===e?!1:a===e?ma[t]:(ma[t]=a,!0)},ft.lang=s("moment.lang is deprecated. Use moment.locale instead.",function(e,t){return ft.locale(e,t)}),ft.locale=function(e,t){var a;return e&&(a="undefined"!=typeof t?ft.defineLocale(e,t):ft.localeData(e),a&&(ft.duration._locale=ft._locale=a)),ft._locale._abbr},ft.defineLocale=function(e,t){return null!==t?(t.abbr=e,Ht[e]||(Ht[e]=new o),Ht[e].set(t),ft.locale(e),Ht[e]):(delete Ht[e],null)},ft.langData=s("moment.langData is deprecated. Use moment.localeData instead.",function(e){return ft.localeData(e)}),ft.localeData=function(e){var t;if(e&&e._locale&&e._locale._abbr&&(e=e._locale._abbr),!e)return ft._locale;if(!p(e)){if(t=E(e))return t;e=[e]}return F(e)},ft.isMoment=function(e){return e instanceof u||null!=e&&a(e,"_isAMomentObject")},ft.isDuration=function(e){return e instanceof l};for(Dt=Ya.length-1;Dt>=0;--Dt)w(Ya[Dt]);ft.normalizeUnits=function(e){return T(e)},ft.invalid=function(e){var t=ft.utc(0/0);return null!=e?m(t._pf,e):t._pf.userInvalidated=!0,t},ft.parseZone=function(){return ft.apply(null,arguments).parseZone()},ft.parseTwoDigitYear=function(e){return v(e)+(v(e)>68?1900:2e3)},m(ft.fn=u.prototype,{clone:function(){return ft(this)},valueOf:function(){return+this._d+6e4*(this._offset||0)},unix:function(){return Math.floor(+this/1e3)},toString:function(){return this.clone().locale("en").format("ddd MMM DD YYYY HH:mm:ss [GMT]ZZ")},toDate:function(){return this._offset?new Date(+this):this._d},toISOString:function(){var e=ft(this).utc();return 0<e.year()&&e.year()<=9999?G(e,"YYYY-MM-DD[T]HH:mm:ss.SSS[Z]"):G(e,"YYYYYY-MM-DD[T]HH:mm:ss.SSS[Z]")},toArray:function(){var e=this;return[e.year(),e.month(),e.date(),e.hours(),e.minutes(),e.seconds(),e.milliseconds()]},isValid:function(){return z(this)},isDSTShifted:function(){return this._a?this.isValid()&&k(this._a,(this._isUTC?ft.utc(this._a):ft(this._a)).toArray())>0:!1},parsingFlags:function(){return m({},this._pf)},invalidAt:function(){return this._pf.overflow},utc:function(e){return this.zone(0,e)},local:function(e){return this._isUTC&&(this.zone(0,e),this._isUTC=!1,e&&this.add(this._dateTzOffset(),"m")),this},format:function(e){var t=G(this,e||ft.defaultFormat);return this.localeData().postformat(t)},add:y(1,"add"),subtract:y(-1,"subtract"),diff:function(e,t,a){var n,_,s,r=A(e,this),d=6e4*(this.zone()-r.zone());return t=T(t),"year"===t||"month"===t?(n=432e5*(this.daysInMonth()+r.daysInMonth()),_=12*(this.year()-r.year())+(this.month()-r.month()),s=this-ft(this).startOf("month")-(r-ft(r).startOf("month")),s-=6e4*(this.zone()-ft(this).startOf("month").zone()-(r.zone()-ft(r).startOf("month").zone())),_+=s/n,"year"===t&&(_/=12)):(n=this-r,_="second"===t?n/1e3:"minute"===t?n/6e4:"hour"===t?n/36e5:"day"===t?(n-d)/864e5:"week"===t?(n-d)/6048e5:n),a?_:c(_)},from:function(e,t){return ft.duration({to:this,from:e}).locale(this.locale()).humanize(!t)},fromNow:function(e){return this.from(ft(),e)},calendar:function(e){var t=e||ft(),a=A(t,this).startOf("day"),n=this.diff(a,"days",!0),_=-6>n?"sameElse":-1>n?"lastWeek":0>n?"lastDay":1>n?"sameDay":2>n?"nextDay":7>n?"nextWeek":"sameElse";return this.format(this.localeData().calendar(_,this))},isLeapYear:function(){return W(this.year())},isDST:function(){return this.zone()<this.clone().month(0).zone()||this.zone()<this.clone().month(5).zone()},day:function(e){var t=this._isUTC?this._d.getUTCDay():this._d.getDay();return null!=e?(e=_t(e,this.localeData()),this.add(e-t,"d")):t},month:ct("Month",!0),startOf:function(e){switch(e=T(e)){case"year":this.month(0);case"quarter":case"month":this.date(1);case"week":case"isoWeek":case"day":this.hours(0);case"hour":this.minutes(0);case"minute":this.seconds(0);case"second":this.milliseconds(0)}return"week"===e?this.weekday(0):"isoWeek"===e&&this.isoWeekday(1),"quarter"===e&&this.month(3*Math.floor(this.month()/3)),this},endOf:function(e){return e=T(e),this.startOf(e).add(1,"isoWeek"===e?"week":e).subtract(1,"ms")},isAfter:function(e,t){return t=T("undefined"!=typeof t?t:"millisecond"),"millisecond"===t?(e=ft.isMoment(e)?e:ft(e),+this>+e):+this.clone().startOf(t)>+ft(e).startOf(t)},isBefore:function(e,t){return t=T("undefined"!=typeof t?t:"millisecond"),"millisecond"===t?(e=ft.isMoment(e)?e:ft(e),+e>+this):+this.clone().startOf(t)<+ft(e).startOf(t)},isSame:function(e,t){return t=T(t||"millisecond"),"millisecond"===t?(e=ft.isMoment(e)?e:ft(e),+this===+e):+this.clone().startOf(t)===+A(e,this).startOf(t)},min:s("moment().min is deprecated, use moment.min instead. https://github.com/moment/moment/issues/1548",function(e){return e=ft.apply(null,arguments),this>e?this:e}),max:s("moment().max is deprecated, use moment.max instead. https://github.com/moment/moment/issues/1548",function(e){return e=ft.apply(null,arguments),e>this?this:e}),zone:function(e,t){var a,n=this._offset||0;return null==e?this._isUTC?n:this._dateTzOffset():("string"==typeof e&&(e=I(e)),Math.abs(e)<16&&(e=60*e),!this._isUTC&&t&&(a=this._dateTzOffset()),this._offset=e,this._isUTC=!0,null!=a&&this.subtract(a,"m"),n!==e&&(!t||this._changeInProgress?f(this,ft.duration(n-e,"m"),1,!1):this._changeInProgress||(this._changeInProgress=!0,ft.updateOffset(this,!0),this._changeInProgress=null)),this)},zoneAbbr:function(){return this._isUTC?"UTC":""},zoneName:function(){return this._isUTC?"Coordinated Universal Time":""},parseZone:function(){return this._tzm?this.zone(this._tzm):"string"==typeof this._i&&this.zone(this._i),this},hasAlignedHourOffset:function(e){return e=e?ft(e).zone():0,(this.zone()-e)%60===0},daysInMonth:function(){return b(this.year(),this.month())},dayOfYear:function(e){var t=gt((ft(this).startOf("day")-ft(this).startOf("year"))/864e5)+1;return null==e?t:this.add(e-t,"d")},quarter:function(e){return null==e?Math.ceil((this.month()+1)/3):this.month(3*(e-1)+this.month()%3)},weekYear:function(e){var t=dt(this,this.localeData()._week.dow,this.localeData()._week.doy).year;return null==e?t:this.add(e-t,"y")},isoWeekYear:function(e){var t=dt(this,1,4).year;return null==e?t:this.add(e-t,"y")},week:function(e){var t=this.localeData().week(this);return null==e?t:this.add(7*(e-t),"d")},isoWeek:function(e){var t=dt(this,1,4).week;return null==e?t:this.add(7*(e-t),"d")},weekday:function(e){var t=(this.day()+7-this.localeData()._week.dow)%7;return null==e?t:this.add(e-t,"d")},isoWeekday:function(e){return null==e?this.day()||7:this.day(this.day()%7?e:e-7)},isoWeeksInYear:function(){return S(this.year(),1,4)},weeksInYear:function(){var e=this.localeData()._week;return S(this.year(),e.dow,e.doy)},get:function(e){return e=T(e),this[e]()},set:function(e,t){return e=T(e),"function"==typeof this[e]&&this[e](t),this},locale:function(t){var a;return t===e?this._locale._abbr:(a=ft.localeData(t),null!=a&&(this._locale=a),this)},lang:s("moment().lang() is deprecated. Use moment().localeData() instead.",function(t){return t===e?this.localeData():this.locale(t)}),localeData:function(){return this._locale},_dateTzOffset:function(){return 15*Math.round(this._d.getTimezoneOffset()/15)}}),ft.fn.millisecond=ft.fn.milliseconds=ct("Milliseconds",!1),ft.fn.second=ft.fn.seconds=ct("Seconds",!1),ft.fn.minute=ft.fn.minutes=ct("Minutes",!1),ft.fn.hour=ft.fn.hours=ct("Hours",!0),ft.fn.date=ct("Date",!0),ft.fn.dates=s("dates accessor is deprecated. Use date instead.",ct("Date",!0)),ft.fn.year=ct("FullYear",!0),ft.fn.years=s("years accessor is deprecated. Use year instead.",ct("FullYear",!0)),ft.fn.days=ft.fn.day,ft.fn.months=ft.fn.month,ft.fn.weeks=ft.fn.week,ft.fn.isoWeeks=ft.fn.isoWeek,ft.fn.quarters=ft.fn.quarter,ft.fn.toJSON=ft.fn.toISOString,m(ft.duration.fn=l.prototype,{_bubble:function(){var e,t,a,n=this._milliseconds,_=this._days,s=this._months,r=this._data,d=0;r.milliseconds=n%1e3,e=c(n/1e3),r.seconds=e%60,t=c(e/60),r.minutes=t%60,a=c(t/60),r.hours=a%24,_+=c(a/24),d=c(Lt(_)),_-=c(ht(d)),s+=c(_/30),_%=30,d+=c(s/12),s%=12,r.days=_,r.months=s,r.years=d},abs:function(){return this._milliseconds=Math.abs(this._milliseconds),this._days=Math.abs(this._days),this._months=Math.abs(this._months),this._data.milliseconds=Math.abs(this._data.milliseconds),this._data.seconds=Math.abs(this._data.seconds),this._data.minutes=Math.abs(this._data.minutes),this._data.hours=Math.abs(this._data.hours),this._data.months=Math.abs(this._data.months),this._data.years=Math.abs(this._data.years),this},weeks:function(){return c(this.days()/7)},valueOf:function(){return this._milliseconds+864e5*this._days+this._months%12*2592e6+31536e6*v(this._months/12)},humanize:function(e){var t=rt(this,!e,this.localeData());return e&&(t=this.localeData().pastFuture(+this,t)),this.localeData().postformat(t)},add:function(e,t){var a=ft.duration(e,t);return this._milliseconds+=a._milliseconds,this._days+=a._days,this._months+=a._months,this._bubble(),this},subtract:function(e,t){var a=ft.duration(e,t);return this._milliseconds-=a._milliseconds,this._days-=a._days,this._months-=a._months,this._bubble(),this},get:function(e){return e=T(e),this[e.toLowerCase()+"s"]()},as:function(e){var t,a;if(e=T(e),"month"===e||"year"===e)return t=this._days+this._milliseconds/864e5,a=this._months+12*Lt(t),"month"===e?a:a/12;switch(t=this._days+ht(this._months/12),e){case"week":return t/7+this._milliseconds/6048e5;case"day":return t+this._milliseconds/864e5;case"hour":return 24*t+this._milliseconds/36e5;case"minute":return 24*t*60+this._milliseconds/6e4;case"second":return 24*t*60*60+this._milliseconds/1e3;case"millisecond":return Math.floor(24*t*60*60*1e3)+this._milliseconds;default:throw new Error("Unknown unit "+e)}},lang:ft.fn.lang,locale:ft.fn.locale,toIsoString:s("toIsoString() is deprecated. Please use toISOString() instead (notice the capitals)",function(){return this.toISOString()}),toISOString:function(){var e=Math.abs(this.years()),t=Math.abs(this.months()),a=Math.abs(this.days()),n=Math.abs(this.hours()),_=Math.abs(this.minutes()),s=Math.abs(this.seconds()+this.milliseconds()/1e3);return this.asSeconds()?(this.asSeconds()<0?"-":"")+"P"+(e?e+"Y":"")+(t?t+"M":"")+(a?a+"D":"")+(n||_||s?"T":"")+(n?n+"H":"")+(_?_+"M":"")+(s?s+"S":""):"P0D"},localeData:function(){return this._locale}}),ft.duration.fn.toString=ft.duration.fn.toISOString;for(Dt in ia)a(ia,Dt)&&Yt(Dt.toLowerCase());ft.duration.fn.asMilliseconds=function(){return this.as("ms")},ft.duration.fn.asSeconds=function(){return this.as("s")},ft.duration.fn.asMinutes=function(){return this.as("m")},ft.duration.fn.asHours=function(){return this.as("h")},ft.duration.fn.asDays=function(){return this.as("d")},ft.duration.fn.asWeeks=function(){return this.as("weeks")},ft.duration.fn.asMonths=function(){return this.as("M")},ft.duration.fn.asYears=function(){return this.as("y")},ft.locale("en",{ordinal:function(e){var t=e%10,a=1===v(e%100/10)?"th":1===t?"st":2===t?"nd":3===t?"rd":"th";
+return e+a}}),function(e){e(ft)}(function(e){return e.defineLocale("af",{months:"Januarie_Februarie_Maart_April_Mei_Junie_Julie_Augustus_September_Oktober_November_Desember".split("_"),monthsShort:"Jan_Feb_Mar_Apr_Mei_Jun_Jul_Aug_Sep_Okt_Nov_Des".split("_"),weekdays:"Sondag_Maandag_Dinsdag_Woensdag_Donderdag_Vrydag_Saterdag".split("_"),weekdaysShort:"Son_Maa_Din_Woe_Don_Vry_Sat".split("_"),weekdaysMin:"So_Ma_Di_Wo_Do_Vr_Sa".split("_"),meridiem:function(e,t,a){return 12>e?a?"vm":"VM":a?"nm":"NM"},longDateFormat:{LT:"HH:mm",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY LT",LLLL:"dddd, D MMMM YYYY LT"},calendar:{sameDay:"[Vandag om] LT",nextDay:"[Môre om] LT",nextWeek:"dddd [om] LT",lastDay:"[Gister om] LT",lastWeek:"[Laas] dddd [om] LT",sameElse:"L"},relativeTime:{future:"oor %s",past:"%s gelede",s:"'n paar sekondes",m:"'n minuut",mm:"%d minute",h:"'n uur",hh:"%d ure",d:"'n dag",dd:"%d dae",M:"'n maand",MM:"%d maande",y:"'n jaar",yy:"%d jaar"},ordinal:function(e){return e+(1===e||8===e||e>=20?"ste":"de")},week:{dow:1,doy:4}})}),function(e){e(ft)}(function(e){return e.defineLocale("ar-ma",{months:"يناير_فبراير_مارس_أبريل_ماي_يونيو_يوليوز_غشت_شتنبر_أكتوبر_نونبر_دجنبر".split("_"),monthsShort:"يناير_فبراير_مارس_أبريل_ماي_يونيو_يوليوز_غشت_شتنبر_أكتوبر_نونبر_دجنبر".split("_"),weekdays:"الأحد_الإتنين_الثلاثاء_الأربعاء_الخميس_الجمعة_السبت".split("_"),weekdaysShort:"احد_اتنين_ثلاثاء_اربعاء_خميس_جمعة_سبت".split("_"),weekdaysMin:"ح_ن_ث_ر_خ_ج_س".split("_"),longDateFormat:{LT:"HH:mm",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY LT",LLLL:"dddd D MMMM YYYY LT"},calendar:{sameDay:"[اليوم على الساعة] LT",nextDay:"[غدا على الساعة] LT",nextWeek:"dddd [على الساعة] LT",lastDay:"[أمس على الساعة] LT",lastWeek:"dddd [على الساعة] LT",sameElse:"L"},relativeTime:{future:"في %s",past:"منذ %s",s:"ثوان",m:"دقيقة",mm:"%d دقائق",h:"ساعة",hh:"%d ساعات",d:"يوم",dd:"%d أيام",M:"شهر",MM:"%d أشهر",y:"سنة",yy:"%d سنوات"},week:{dow:6,doy:12}})}),function(e){e(ft)}(function(e){var t={1:"١",2:"٢",3:"٣",4:"٤",5:"٥",6:"٦",7:"٧",8:"٨",9:"٩",0:"٠"},a={"١":"1","٢":"2","٣":"3","٤":"4","٥":"5","٦":"6","٧":"7","٨":"8","٩":"9","٠":"0"};return e.defineLocale("ar-sa",{months:"يناير_فبراير_مارس_أبريل_مايو_يونيو_يوليو_أغسطس_سبتمبر_أكتوبر_نوفمبر_ديسمبر".split("_"),monthsShort:"يناير_فبراير_مارس_أبريل_مايو_يونيو_يوليو_أغسطس_سبتمبر_أكتوبر_نوفمبر_ديسمبر".split("_"),weekdays:"الأحد_الإثنين_الثلاثاء_الأربعاء_الخميس_الجمعة_السبت".split("_"),weekdaysShort:"أحد_إثنين_ثلاثاء_أربعاء_خميس_جمعة_سبت".split("_"),weekdaysMin:"ح_ن_ث_ر_خ_ج_س".split("_"),longDateFormat:{LT:"HH:mm",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY LT",LLLL:"dddd D MMMM YYYY LT"},meridiem:function(e){return 12>e?"ص":"م"},calendar:{sameDay:"[اليوم على الساعة] LT",nextDay:"[غدا على الساعة] LT",nextWeek:"dddd [على الساعة] LT",lastDay:"[أمس على الساعة] LT",lastWeek:"dddd [على الساعة] LT",sameElse:"L"},relativeTime:{future:"في %s",past:"منذ %s",s:"ثوان",m:"دقيقة",mm:"%d دقائق",h:"ساعة",hh:"%d ساعات",d:"يوم",dd:"%d أيام",M:"شهر",MM:"%d أشهر",y:"سنة",yy:"%d سنوات"},preparse:function(e){return e.replace(/[۰-۹]/g,function(e){return a[e]}).replace(/،/g,",")},postformat:function(e){return e.replace(/\d/g,function(e){return t[e]}).replace(/,/g,"،")},week:{dow:6,doy:12}})}),function(e){e(ft)}(function(e){var t={1:"١",2:"٢",3:"٣",4:"٤",5:"٥",6:"٦",7:"٧",8:"٨",9:"٩",0:"٠"},a={"١":"1","٢":"2","٣":"3","٤":"4","٥":"5","٦":"6","٧":"7","٨":"8","٩":"9","٠":"0"},n=function(e){return 0===e?0:1===e?1:2===e?2:e%100>=3&&10>=e%100?3:e%100>=11?4:5},_={s:["أقل من ثانية","ثانية واحدة",["ثانيتان","ثانيتين"],"%d ثوان","%d ثانية","%d ثانية"],m:["أقل من دقيقة","دقيقة واحدة",["دقيقتان","دقيقتين"],"%d دقائق","%d دقيقة","%d دقيقة"],h:["أقل من ساعة","ساعة واحدة",["ساعتان","ساعتين"],"%d ساعات","%d ساعة","%d ساعة"],d:["أقل من يوم","يوم واحد",["يومان","يومين"],"%d أيام","%d يومًا","%d يوم"],M:["أقل من شهر","شهر واحد",["شهران","شهرين"],"%d أشهر","%d شهرا","%d شهر"],y:["أقل من عام","عام واحد",["عامان","عامين"],"%d أعوام","%d عامًا","%d عام"]},s=function(e){return function(t,a){var s=n(t),r=_[e][n(t)];return 2===s&&(r=r[a?0:1]),r.replace(/%d/i,t)}},r=["كانون الثاني يناير","شباط فبراير","آذار مارس","نيسان أبريل","أيار مايو","حزيران يونيو","تموز يوليو","آب أغسطس","أيلول سبتمبر","تشرين الأول أكتوبر","تشرين الثاني نوفمبر","كانون الأول ديسمبر"];return e.defineLocale("ar",{months:r,monthsShort:r,weekdays:"الأحد_الإثنين_الثلاثاء_الأربعاء_الخميس_الجمعة_السبت".split("_"),weekdaysShort:"أحد_إثنين_ثلاثاء_أربعاء_خميس_جمعة_سبت".split("_"),weekdaysMin:"ح_ن_ث_ر_خ_ج_س".split("_"),longDateFormat:{LT:"HH:mm",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY LT",LLLL:"dddd D MMMM YYYY LT"},meridiem:function(e){return 12>e?"ص":"م"},calendar:{sameDay:"[اليوم عند الساعة] LT",nextDay:"[غدًا عند الساعة] LT",nextWeek:"dddd [عند الساعة] LT",lastDay:"[أمس عند الساعة] LT",lastWeek:"dddd [عند الساعة] LT",sameElse:"L"},relativeTime:{future:"بعد %s",past:"منذ %s",s:s("s"),m:s("m"),mm:s("m"),h:s("h"),hh:s("h"),d:s("d"),dd:s("d"),M:s("M"),MM:s("M"),y:s("y"),yy:s("y")},preparse:function(e){return e.replace(/[۰-۹]/g,function(e){return a[e]}).replace(/،/g,",")},postformat:function(e){return e.replace(/\d/g,function(e){return t[e]}).replace(/,/g,"،")},week:{dow:6,doy:12}})}),function(e){e(ft)}(function(e){var t={1:"-inci",5:"-inci",8:"-inci",70:"-inci",80:"-inci",2:"-nci",7:"-nci",20:"-nci",50:"-nci",3:"-üncü",4:"-üncü",100:"-üncü",6:"-ncı",9:"-uncu",10:"-uncu",30:"-uncu",60:"-ıncı",90:"-ıncı"};return e.defineLocale("az",{months:"yanvar_fevral_mart_aprel_may_iyun_iyul_avqust_sentyabr_oktyabr_noyabr_dekabr".split("_"),monthsShort:"yan_fev_mar_apr_may_iyn_iyl_avq_sen_okt_noy_dek".split("_"),weekdays:"Bazar_Bazar ertəsi_Çərşənbə axşamı_Çərşənbə_Cümə axşamı_Cümə_Şənbə".split("_"),weekdaysShort:"Baz_BzE_ÇAx_Çər_CAx_Cüm_Şən".split("_"),weekdaysMin:"Bz_BE_ÇA_Çə_CA_Cü_Şə".split("_"),longDateFormat:{LT:"HH:mm",L:"DD.MM.YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY LT",LLLL:"dddd, D MMMM YYYY LT"},calendar:{sameDay:"[bugün saat] LT",nextDay:"[sabah saat] LT",nextWeek:"[gələn həftə] dddd [saat] LT",lastDay:"[dünən] LT",lastWeek:"[keçən həftə] dddd [saat] LT",sameElse:"L"},relativeTime:{future:"%s sonra",past:"%s əvvəl",s:"birneçə saniyyə",m:"bir dəqiqə",mm:"%d dəqiqə",h:"bir saat",hh:"%d saat",d:"bir gün",dd:"%d gün",M:"bir ay",MM:"%d ay",y:"bir il",yy:"%d il"},meridiem:function(e){return 4>e?"gecə":12>e?"səhər":17>e?"gündüz":"axşam"},ordinal:function(e){if(0===e)return e+"-ıncı";var a=e%10,n=e%100-a,_=e>=100?100:null;return e+(t[a]||t[n]||t[_])},week:{dow:1,doy:7}})}),function(e){e(ft)}(function(e){function t(e,t){var a=e.split("_");return t%10===1&&t%100!==11?a[0]:t%10>=2&&4>=t%10&&(10>t%100||t%100>=20)?a[1]:a[2]}function a(e,a,n){var _={mm:a?"хвіліна_хвіліны_хвілін":"хвіліну_хвіліны_хвілін",hh:a?"гадзіна_гадзіны_гадзін":"гадзіну_гадзіны_гадзін",dd:"дзень_дні_дзён",MM:"месяц_месяцы_месяцаў",yy:"год_гады_гадоў"};return"m"===n?a?"хвіліна":"хвіліну":"h"===n?a?"гадзіна":"гадзіну":e+" "+t(_[n],+e)}function n(e,t){var a={nominative:"студзень_люты_сакавік_красавік_травень_чэрвень_ліпень_жнівень_верасень_кастрычнік_лістапад_снежань".split("_"),accusative:"студзеня_лютага_сакавіка_красавіка_траўня_чэрвеня_ліпеня_жніўня_верасня_кастрычніка_лістапада_снежня".split("_")},n=/D[oD]?(\[[^\[\]]*\]|\s+)+MMMM?/.test(t)?"accusative":"nominative";return a[n][e.month()]}function _(e,t){var a={nominative:"нядзеля_панядзелак_аўторак_серада_чацвер_пятніца_субота".split("_"),accusative:"нядзелю_панядзелак_аўторак_сераду_чацвер_пятніцу_суботу".split("_")},n=/\[ ?[Вв] ?(?:мінулую|наступную)? ?\] ?dddd/.test(t)?"accusative":"nominative";return a[n][e.day()]}return e.defineLocale("be",{months:n,monthsShort:"студ_лют_сак_крас_трав_чэрв_ліп_жнів_вер_каст_ліст_снеж".split("_"),weekdays:_,weekdaysShort:"нд_пн_ат_ср_чц_пт_сб".split("_"),weekdaysMin:"нд_пн_ат_ср_чц_пт_сб".split("_"),longDateFormat:{LT:"HH:mm",L:"DD.MM.YYYY",LL:"D MMMM YYYY г.",LLL:"D MMMM YYYY г., LT",LLLL:"dddd, D MMMM YYYY г., LT"},calendar:{sameDay:"[Сёння ў] LT",nextDay:"[Заўтра ў] LT",lastDay:"[Учора ў] LT",nextWeek:function(){return"[У] dddd [ў] LT"},lastWeek:function(){switch(this.day()){case 0:case 3:case 5:case 6:return"[У мінулую] dddd [ў] LT";case 1:case 2:case 4:return"[У мінулы] dddd [ў] LT"}},sameElse:"L"},relativeTime:{future:"праз %s",past:"%s таму",s:"некалькі секунд",m:a,mm:a,h:a,hh:a,d:"дзень",dd:a,M:"месяц",MM:a,y:"год",yy:a},meridiem:function(e){return 4>e?"ночы":12>e?"раніцы":17>e?"дня":"вечара"},ordinal:function(e,t){switch(t){case"M":case"d":case"DDD":case"w":case"W":return e%10!==2&&e%10!==3||e%100===12||e%100===13?e+"-ы":e+"-і";case"D":return e+"-га";default:return e}},week:{dow:1,doy:7}})}),function(e){e(ft)}(function(e){return e.defineLocale("bg",{months:"януари_февруари_март_април_май_юни_юли_август_септември_октомври_ноември_декември".split("_"),monthsShort:"янр_фев_мар_апр_май_юни_юли_авг_сеп_окт_ное_дек".split("_"),weekdays:"неделя_понеделник_вторник_сряда_четвъртък_петък_събота".split("_"),weekdaysShort:"нед_пон_вто_сря_чет_пет_съб".split("_"),weekdaysMin:"нд_пн_вт_ср_чт_пт_сб".split("_"),longDateFormat:{LT:"H:mm",L:"D.MM.YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY LT",LLLL:"dddd, D MMMM YYYY LT"},calendar:{sameDay:"[Днес в] LT",nextDay:"[Утре в] LT",nextWeek:"dddd [в] LT",lastDay:"[Вчера в] LT",lastWeek:function(){switch(this.day()){case 0:case 3:case 6:return"[В изминалата] dddd [в] LT";case 1:case 2:case 4:case 5:return"[В изминалия] dddd [в] LT"}},sameElse:"L"},relativeTime:{future:"след %s",past:"преди %s",s:"няколко секунди",m:"минута",mm:"%d минути",h:"час",hh:"%d часа",d:"ден",dd:"%d дни",M:"месец",MM:"%d месеца",y:"година",yy:"%d години"},ordinal:function(e){var t=e%10,a=e%100;return 0===e?e+"-ев":0===a?e+"-ен":a>10&&20>a?e+"-ти":1===t?e+"-ви":2===t?e+"-ри":7===t||8===t?e+"-ми":e+"-ти"},week:{dow:1,doy:7}})}),function(e){e(ft)}(function(e){var t={1:"১",2:"২",3:"৩",4:"৪",5:"৫",6:"৬",7:"৭",8:"৮",9:"৯",0:"০"},a={"১":"1","২":"2","৩":"3","৪":"4","৫":"5","৬":"6","৭":"7","৮":"8","৯":"9","০":"0"};return e.defineLocale("bn",{months:"জানুয়ারী_ফেবুয়ারী_মার্চ_এপ্রিল_মে_জুন_জুলাই_অগাস্ট_সেপ্টেম্বর_অক্টোবর_নভেম্বর_ডিসেম্বর".split("_"),monthsShort:"জানু_ফেব_মার্চ_এপর_মে_জুন_জুল_অগ_সেপ্ট_অক্টো_নভ_ডিসেম্".split("_"),weekdays:"রবিবার_সোমবার_মঙ্গলবার_বুধবার_বৃহস্পত্তিবার_শুক্রুবার_শনিবার".split("_"),weekdaysShort:"রবি_সোম_মঙ্গল_বুধ_বৃহস্পত্তি_শুক্রু_শনি".split("_"),weekdaysMin:"রব_সম_মঙ্গ_বু_ব্রিহ_শু_শনি".split("_"),longDateFormat:{LT:"A h:mm সময়",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY, LT",LLLL:"dddd, D MMMM YYYY, LT"},calendar:{sameDay:"[আজ] LT",nextDay:"[আগামীকাল] LT",nextWeek:"dddd, LT",lastDay:"[গতকাল] LT",lastWeek:"[গত] dddd, LT",sameElse:"L"},relativeTime:{future:"%s পরে",past:"%s আগে",s:"কএক সেকেন্ড",m:"এক মিনিট",mm:"%d মিনিট",h:"এক ঘন্টা",hh:"%d ঘন্টা",d:"এক দিন",dd:"%d দিন",M:"এক মাস",MM:"%d মাস",y:"এক বছর",yy:"%d বছর"},preparse:function(e){return e.replace(/[১২৩৪৫৬৭৮৯০]/g,function(e){return a[e]})},postformat:function(e){return e.replace(/\d/g,function(e){return t[e]})},meridiem:function(e){return 4>e?"রাত":10>e?"শকাল":17>e?"দুপুর":20>e?"বিকেল":"রাত"},week:{dow:0,doy:6}})}),function(e){e(ft)}(function(e){var t={1:"༡",2:"༢",3:"༣",4:"༤",5:"༥",6:"༦",7:"༧",8:"༨",9:"༩",0:"༠"},a={"༡":"1","༢":"2","༣":"3","༤":"4","༥":"5","༦":"6","༧":"7","༨":"8","༩":"9","༠":"0"};return e.defineLocale("bo",{months:"ཟླ་བ་དང་པོ_ཟླ་བ་གཉིས་པ_ཟླ་བ་གསུམ་པ_ཟླ་བ་བཞི་པ_ཟླ་བ་ལྔ་པ_ཟླ་བ་དྲུག་པ_ཟླ་བ་བདུན་པ_ཟླ་བ་བརྒྱད་པ_ཟླ་བ་དགུ་པ_ཟླ་བ་བཅུ་པ_ཟླ་བ་བཅུ་གཅིག་པ_ཟླ་བ་བཅུ་གཉིས་པ".split("_"),monthsShort:"ཟླ་བ་དང་པོ_ཟླ་བ་གཉིས་པ_ཟླ་བ་གསུམ་པ_ཟླ་བ་བཞི་པ_ཟླ་བ་ལྔ་པ_ཟླ་བ་དྲུག་པ_ཟླ་བ་བདུན་པ_ཟླ་བ་བརྒྱད་པ_ཟླ་བ་དགུ་པ_ཟླ་བ་བཅུ་པ_ཟླ་བ་བཅུ་གཅིག་པ_ཟླ་བ་བཅུ་གཉིས་པ".split("_"),weekdays:"གཟའ་ཉི་མ་_གཟའ་ཟླ་བ་_གཟའ་མིག་དམར་_གཟའ་ལྷག་པ་_གཟའ་ཕུར་བུ_གཟའ་པ་སངས་_གཟའ་སྤེན་པ་".split("_"),weekdaysShort:"ཉི་མ་_ཟླ་བ་_མིག་དམར་_ལྷག་པ་_ཕུར་བུ_པ་སངས་_སྤེན་པ་".split("_"),weekdaysMin:"ཉི་མ་_ཟླ་བ་_མིག་དམར་_ལྷག་པ་_ཕུར་བུ_པ་སངས་_སྤེན་པ་".split("_"),longDateFormat:{LT:"A h:mm",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY, LT",LLLL:"dddd, D MMMM YYYY, LT"},calendar:{sameDay:"[དི་རིང] LT",nextDay:"[སང་ཉིན] LT",nextWeek:"[བདུན་ཕྲག་རྗེས་མ], LT",lastDay:"[ཁ་སང] LT",lastWeek:"[བདུན་ཕྲག་མཐའ་མ] dddd, LT",sameElse:"L"},relativeTime:{future:"%s ལ་",past:"%s སྔན་ལ",s:"ལམ་སང",m:"སྐར་མ་གཅིག",mm:"%d སྐར་མ",h:"ཆུ་ཚོད་གཅིག",hh:"%d ཆུ་ཚོད",d:"ཉིན་གཅིག",dd:"%d ཉིན་",M:"ཟླ་བ་གཅིག",MM:"%d ཟླ་བ",y:"ལོ་གཅིག",yy:"%d ལོ"},preparse:function(e){return e.replace(/[༡༢༣༤༥༦༧༨༩༠]/g,function(e){return a[e]})},postformat:function(e){return e.replace(/\d/g,function(e){return t[e]})},meridiem:function(e){return 4>e?"མཚན་མོ":10>e?"ཞོགས་ཀས":17>e?"ཉིན་གུང":20>e?"དགོང་དག":"མཚན་མོ"},week:{dow:0,doy:6}})}),function(e){e(ft)}(function(t){function a(e,t,a){var n={mm:"munutenn",MM:"miz",dd:"devezh"};return e+" "+s(n[a],e)}function n(e){switch(_(e)){case 1:case 3:case 4:case 5:case 9:return e+" bloaz";default:return e+" vloaz"}}function _(e){return e>9?_(e%10):e}function s(e,t){return 2===t?r(e):e}function r(t){var a={m:"v",b:"v",d:"z"};return a[t.charAt(0)]===e?t:a[t.charAt(0)]+t.substring(1)}return t.defineLocale("br",{months:"Genver_C'hwevrer_Meurzh_Ebrel_Mae_Mezheven_Gouere_Eost_Gwengolo_Here_Du_Kerzu".split("_"),monthsShort:"Gen_C'hwe_Meu_Ebr_Mae_Eve_Gou_Eos_Gwe_Her_Du_Ker".split("_"),weekdays:"Sul_Lun_Meurzh_Merc'her_Yaou_Gwener_Sadorn".split("_"),weekdaysShort:"Sul_Lun_Meu_Mer_Yao_Gwe_Sad".split("_"),weekdaysMin:"Su_Lu_Me_Mer_Ya_Gw_Sa".split("_"),longDateFormat:{LT:"h[e]mm A",L:"DD/MM/YYYY",LL:"D [a viz] MMMM YYYY",LLL:"D [a viz] MMMM YYYY LT",LLLL:"dddd, D [a viz] MMMM YYYY LT"},calendar:{sameDay:"[Hiziv da] LT",nextDay:"[Warc'hoazh da] LT",nextWeek:"dddd [da] LT",lastDay:"[Dec'h da] LT",lastWeek:"dddd [paset da] LT",sameElse:"L"},relativeTime:{future:"a-benn %s",past:"%s 'zo",s:"un nebeud segondennoù",m:"ur vunutenn",mm:a,h:"un eur",hh:"%d eur",d:"un devezh",dd:a,M:"ur miz",MM:a,y:"ur bloaz",yy:n},ordinal:function(e){var t=1===e?"añ":"vet";return e+t},week:{dow:1,doy:4}})}),function(e){e(ft)}(function(e){function t(e,t,a){var n=e+" ";switch(a){case"m":return t?"jedna minuta":"jedne minute";case"mm":return n+=1===e?"minuta":2===e||3===e||4===e?"minute":"minuta";case"h":return t?"jedan sat":"jednog sata";case"hh":return n+=1===e?"sat":2===e||3===e||4===e?"sata":"sati";case"dd":return n+=1===e?"dan":"dana";case"MM":return n+=1===e?"mjesec":2===e||3===e||4===e?"mjeseca":"mjeseci";case"yy":return n+=1===e?"godina":2===e||3===e||4===e?"godine":"godina"}}return e.defineLocale("bs",{months:"januar_februar_mart_april_maj_juni_juli_avgust_septembar_oktobar_novembar_decembar".split("_"),monthsShort:"jan._feb._mar._apr._maj._jun._jul._avg._sep._okt._nov._dec.".split("_"),weekdays:"nedjelja_ponedjeljak_utorak_srijeda_četvrtak_petak_subota".split("_"),weekdaysShort:"ned._pon._uto._sri._čet._pet._sub.".split("_"),weekdaysMin:"ne_po_ut_sr_če_pe_su".split("_"),longDateFormat:{LT:"H:mm",L:"DD. MM. YYYY",LL:"D. MMMM YYYY",LLL:"D. MMMM YYYY LT",LLLL:"dddd, D. MMMM YYYY LT"},calendar:{sameDay:"[danas u] LT",nextDay:"[sutra u] LT",nextWeek:function(){switch(this.day()){case 0:return"[u] [nedjelju] [u] LT";case 3:return"[u] [srijedu] [u] LT";case 6:return"[u] [subotu] [u] LT";case 1:case 2:case 4:case 5:return"[u] dddd [u] LT"}},lastDay:"[jučer u] LT",lastWeek:function(){switch(this.day()){case 0:case 3:return"[prošlu] dddd [u] LT";case 6:return"[prošle] [subote] [u] LT";case 1:case 2:case 4:case 5:return"[prošli] dddd [u] LT"}},sameElse:"L"},relativeTime:{future:"za %s",past:"prije %s",s:"par sekundi",m:t,mm:t,h:t,hh:t,d:"dan",dd:t,M:"mjesec",MM:t,y:"godinu",yy:t},ordinal:"%d.",week:{dow:1,doy:7}})}),function(e){e(ft)}(function(e){return e.defineLocale("ca",{months:"gener_febrer_març_abril_maig_juny_juliol_agost_setembre_octubre_novembre_desembre".split("_"),monthsShort:"gen._febr._mar._abr._mai._jun._jul._ag._set._oct._nov._des.".split("_"),weekdays:"diumenge_dilluns_dimarts_dimecres_dijous_divendres_dissabte".split("_"),weekdaysShort:"dg._dl._dt._dc._dj._dv._ds.".split("_"),weekdaysMin:"Dg_Dl_Dt_Dc_Dj_Dv_Ds".split("_"),longDateFormat:{LT:"H:mm",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY LT",LLLL:"dddd D MMMM YYYY LT"},calendar:{sameDay:function(){return"[avui a "+(1!==this.hours()?"les":"la")+"] LT"},nextDay:function(){return"[demà a "+(1!==this.hours()?"les":"la")+"] LT"},nextWeek:function(){return"dddd [a "+(1!==this.hours()?"les":"la")+"] LT"},lastDay:function(){return"[ahir a "+(1!==this.hours()?"les":"la")+"] LT"},lastWeek:function(){return"[el] dddd [passat a "+(1!==this.hours()?"les":"la")+"] LT"},sameElse:"L"},relativeTime:{future:"en %s",past:"fa %s",s:"uns segons",m:"un minut",mm:"%d minuts",h:"una hora",hh:"%d hores",d:"un dia",dd:"%d dies",M:"un mes",MM:"%d mesos",y:"un any",yy:"%d anys"},ordinal:"%dº",week:{dow:1,doy:4}})}),function(e){e(ft)}(function(e){function t(e){return e>1&&5>e&&1!==~~(e/10)}function a(e,a,n,_){var s=e+" ";switch(n){case"s":return a||_?"pár sekund":"pár sekundami";case"m":return a?"minuta":_?"minutu":"minutou";case"mm":return a||_?s+(t(e)?"minuty":"minut"):s+"minutami";break;case"h":return a?"hodina":_?"hodinu":"hodinou";case"hh":return a||_?s+(t(e)?"hodiny":"hodin"):s+"hodinami";break;case"d":return a||_?"den":"dnem";case"dd":return a||_?s+(t(e)?"dny":"dní"):s+"dny";break;case"M":return a||_?"měsíc":"měsícem";case"MM":return a||_?s+(t(e)?"měsíce":"měsíců"):s+"měsíci";break;case"y":return a||_?"rok":"rokem";case"yy":return a||_?s+(t(e)?"roky":"let"):s+"lety"}}var n="leden_únor_březen_duben_květen_červen_červenec_srpen_září_říjen_listopad_prosinec".split("_"),_="led_úno_bře_dub_kvě_čvn_čvc_srp_zář_říj_lis_pro".split("_");return e.defineLocale("cs",{months:n,monthsShort:_,monthsParse:function(e,t){var a,n=[];for(a=0;12>a;a++)n[a]=new RegExp("^"+e[a]+"$|^"+t[a]+"$","i");return n}(n,_),weekdays:"neděle_pondělí_úterý_středa_čtvrtek_pátek_sobota".split("_"),weekdaysShort:"ne_po_út_st_čt_pá_so".split("_"),weekdaysMin:"ne_po_út_st_čt_pá_so".split("_"),longDateFormat:{LT:"H:mm",L:"DD. MM. YYYY",LL:"D. MMMM YYYY",LLL:"D. MMMM YYYY LT",LLLL:"dddd D. MMMM YYYY LT"},calendar:{sameDay:"[dnes v] LT",nextDay:"[zítra v] LT",nextWeek:function(){switch(this.day()){case 0:return"[v neděli v] LT";case 1:case 2:return"[v] dddd [v] LT";case 3:return"[ve středu v] LT";case 4:return"[ve čtvrtek v] LT";case 5:return"[v pátek v] LT";case 6:return"[v sobotu v] LT"}},lastDay:"[včera v] LT",lastWeek:function(){switch(this.day()){case 0:return"[minulou neděli v] LT";case 1:case 2:return"[minulé] dddd [v] LT";case 3:return"[minulou středu v] LT";case 4:case 5:return"[minulý] dddd [v] LT";case 6:return"[minulou sobotu v] LT"}},sameElse:"L"},relativeTime:{future:"za %s",past:"před %s",s:a,m:a,mm:a,h:a,hh:a,d:a,dd:a,M:a,MM:a,y:a,yy:a},ordinal:"%d.",week:{dow:1,doy:4}})}),function(e){e(ft)}(function(e){return e.defineLocale("cv",{months:"кăрлач_нарăс_пуш_ака_май_çĕртме_утă_çурла_авăн_юпа_чӳк_раштав".split("_"),monthsShort:"кăр_нар_пуш_ака_май_çĕр_утă_çур_ав_юпа_чӳк_раш".split("_"),weekdays:"вырсарникун_тунтикун_ытларикун_юнкун_кĕçнерникун_эрнекун_шăматкун".split("_"),weekdaysShort:"выр_тун_ытл_юн_кĕç_эрн_шăм".split("_"),weekdaysMin:"вр_тн_ыт_юн_кç_эр_шм".split("_"),longDateFormat:{LT:"HH:mm",L:"DD-MM-YYYY",LL:"YYYY [çулхи] MMMM [уйăхĕн] D[-мĕшĕ]",LLL:"YYYY [çулхи] MMMM [уйăхĕн] D[-мĕшĕ], LT",LLLL:"dddd, YYYY [çулхи] MMMM [уйăхĕн] D[-мĕшĕ], LT"},calendar:{sameDay:"[Паян] LT [сехетре]",nextDay:"[Ыран] LT [сехетре]",lastDay:"[Ĕнер] LT [сехетре]",nextWeek:"[Çитес] dddd LT [сехетре]",lastWeek:"[Иртнĕ] dddd LT [сехетре]",sameElse:"L"},relativeTime:{future:function(e){var t=/сехет$/i.exec(e)?"рен":/çул$/i.exec(e)?"тан":"ран";return e+t},past:"%s каялла",s:"пĕр-ик çеккунт",m:"пĕр минут",mm:"%d минут",h:"пĕр сехет",hh:"%d сехет",d:"пĕр кун",dd:"%d кун",M:"пĕр уйăх",MM:"%d уйăх",y:"пĕр çул",yy:"%d çул"},ordinal:"%d-мĕш",week:{dow:1,doy:7}})}),function(e){e(ft)}(function(e){return e.defineLocale("cy",{months:"Ionawr_Chwefror_Mawrth_Ebrill_Mai_Mehefin_Gorffennaf_Awst_Medi_Hydref_Tachwedd_Rhagfyr".split("_"),monthsShort:"Ion_Chwe_Maw_Ebr_Mai_Meh_Gor_Aws_Med_Hyd_Tach_Rhag".split("_"),weekdays:"Dydd Sul_Dydd Llun_Dydd Mawrth_Dydd Mercher_Dydd Iau_Dydd Gwener_Dydd Sadwrn".split("_"),weekdaysShort:"Sul_Llun_Maw_Mer_Iau_Gwe_Sad".split("_"),weekdaysMin:"Su_Ll_Ma_Me_Ia_Gw_Sa".split("_"),longDateFormat:{LT:"HH:mm",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY LT",LLLL:"dddd, D MMMM YYYY LT"},calendar:{sameDay:"[Heddiw am] LT",nextDay:"[Yfory am] LT",nextWeek:"dddd [am] LT",lastDay:"[Ddoe am] LT",lastWeek:"dddd [diwethaf am] LT",sameElse:"L"},relativeTime:{future:"mewn %s",past:"%s yn ôl",s:"ychydig eiliadau",m:"munud",mm:"%d munud",h:"awr",hh:"%d awr",d:"diwrnod",dd:"%d diwrnod",M:"mis",MM:"%d mis",y:"blwyddyn",yy:"%d flynedd"},ordinal:function(e){var t=e,a="",n=["","af","il","ydd","ydd","ed","ed","ed","fed","fed","fed","eg","fed","eg","eg","fed","eg","eg","fed","eg","fed"];return t>20?a=40===t||50===t||60===t||80===t||100===t?"fed":"ain":t>0&&(a=n[t]),e+a},week:{dow:1,doy:4}})}),function(e){e(ft)}(function(e){return e.defineLocale("da",{months:"januar_februar_marts_april_maj_juni_juli_august_september_oktober_november_december".split("_"),monthsShort:"jan_feb_mar_apr_maj_jun_jul_aug_sep_okt_nov_dec".split("_"),weekdays:"søndag_mandag_tirsdag_onsdag_torsdag_fredag_lørdag".split("_"),weekdaysShort:"søn_man_tir_ons_tor_fre_lør".split("_"),weekdaysMin:"sø_ma_ti_on_to_fr_lø".split("_"),longDateFormat:{LT:"HH:mm",L:"DD/MM/YYYY",LL:"D. MMMM YYYY",LLL:"D. MMMM YYYY LT",LLLL:"dddd [d.] D. MMMM YYYY LT"},calendar:{sameDay:"[I dag kl.] LT",nextDay:"[I morgen kl.] LT",nextWeek:"dddd [kl.] LT",lastDay:"[I går kl.] LT",lastWeek:"[sidste] dddd [kl] LT",sameElse:"L"},relativeTime:{future:"om %s",past:"%s siden",s:"få sekunder",m:"et minut",mm:"%d minutter",h:"en time",hh:"%d timer",d:"en dag",dd:"%d dage",M:"en måned",MM:"%d måneder",y:"et år",yy:"%d år"},ordinal:"%d.",week:{dow:1,doy:4}})}),function(e){e(ft)}(function(e){function t(e,t,a){var n={m:["eine Minute","einer Minute"],h:["eine Stunde","einer Stunde"],d:["ein Tag","einem Tag"],dd:[e+" Tage",e+" Tagen"],M:["ein Monat","einem Monat"],MM:[e+" Monate",e+" Monaten"],y:["ein Jahr","einem Jahr"],yy:[e+" Jahre",e+" Jahren"]};return t?n[a][0]:n[a][1]}return e.defineLocale("de-at",{months:"Jänner_Februar_März_April_Mai_Juni_Juli_August_September_Oktober_November_Dezember".split("_"),monthsShort:"Jän._Febr._Mrz._Apr._Mai_Jun._Jul._Aug._Sept._Okt._Nov._Dez.".split("_"),weekdays:"Sonntag_Montag_Dienstag_Mittwoch_Donnerstag_Freitag_Samstag".split("_"),weekdaysShort:"So._Mo._Di._Mi._Do._Fr._Sa.".split("_"),weekdaysMin:"So_Mo_Di_Mi_Do_Fr_Sa".split("_"),longDateFormat:{LT:"HH:mm [Uhr]",L:"DD.MM.YYYY",LL:"D. MMMM YYYY",LLL:"D. MMMM YYYY LT",LLLL:"dddd, D. MMMM YYYY LT"},calendar:{sameDay:"[Heute um] LT",sameElse:"L",nextDay:"[Morgen um] LT",nextWeek:"dddd [um] LT",lastDay:"[Gestern um] LT",lastWeek:"[letzten] dddd [um] LT"},relativeTime:{future:"in %s",past:"vor %s",s:"ein paar Sekunden",m:t,mm:"%d Minuten",h:t,hh:"%d Stunden",d:t,dd:t,M:t,MM:t,y:t,yy:t},ordinal:"%d.",week:{dow:1,doy:4}})}),function(e){e(ft)}(function(e){function t(e,t,a){var n={m:["eine Minute","einer Minute"],h:["eine Stunde","einer Stunde"],d:["ein Tag","einem Tag"],dd:[e+" Tage",e+" Tagen"],M:["ein Monat","einem Monat"],MM:[e+" Monate",e+" Monaten"],y:["ein Jahr","einem Jahr"],yy:[e+" Jahre",e+" Jahren"]};return t?n[a][0]:n[a][1]}return e.defineLocale("de",{months:"Januar_Februar_März_April_Mai_Juni_Juli_August_September_Oktober_November_Dezember".split("_"),monthsShort:"Jan._Febr._Mrz._Apr._Mai_Jun._Jul._Aug._Sept._Okt._Nov._Dez.".split("_"),weekdays:"Sonntag_Montag_Dienstag_Mittwoch_Donnerstag_Freitag_Samstag".split("_"),weekdaysShort:"So._Mo._Di._Mi._Do._Fr._Sa.".split("_"),weekdaysMin:"So_Mo_Di_Mi_Do_Fr_Sa".split("_"),longDateFormat:{LT:"HH:mm [Uhr]",L:"DD.MM.YYYY",LL:"D. MMMM YYYY",LLL:"D. MMMM YYYY LT",LLLL:"dddd, D. MMMM YYYY LT"},calendar:{sameDay:"[Heute um] LT",sameElse:"L",nextDay:"[Morgen um] LT",nextWeek:"dddd [um] LT",lastDay:"[Gestern um] LT",lastWeek:"[letzten] dddd [um] LT"},relativeTime:{future:"in %s",past:"vor %s",s:"ein paar Sekunden",m:t,mm:"%d Minuten",h:t,hh:"%d Stunden",d:t,dd:t,M:t,MM:t,y:t,yy:t},ordinal:"%d.",week:{dow:1,doy:4}})}),function(e){e(ft)}(function(e){return e.defineLocale("el",{monthsNominativeEl:"Ιανουάριος_Φεβρουάριος_Μάρτιος_Απρίλιος_Μάιος_Ιούνιος_Ιούλιος_Αύγουστος_Σεπτέμβριος_Οκτώβριος_Νοέμβριος_Δεκέμβριος".split("_"),monthsGenitiveEl:"Ιανουαρίου_Φεβρουαρίου_Μαρτίου_Απριλίου_Μαΐου_Ιουνίου_Ιουλίου_Αυγούστου_Σεπτεμβρίου_Οκτωβρίου_Νοεμβρίου_Δεκεμβρίου".split("_"),months:function(e,t){return/D/.test(t.substring(0,t.indexOf("MMMM")))?this._monthsGenitiveEl[e.month()]:this._monthsNominativeEl[e.month()]},monthsShort:"Ιαν_Φεβ_Μαρ_Απρ_Μαϊ_Ιουν_Ιουλ_Αυγ_Σεπ_Οκτ_Νοε_Δεκ".split("_"),weekdays:"Κυριακή_Δευτέρα_Τρίτη_Τετάρτη_Πέμπτη_Παρασκευή_Σάββατο".split("_"),weekdaysShort:"Κυρ_Δευ_Τρι_Τετ_Πεμ_Παρ_Σαβ".split("_"),weekdaysMin:"Κυ_Δε_Τρ_Τε_Πε_Πα_Σα".split("_"),meridiem:function(e,t,a){return e>11?a?"μμ":"ΜΜ":a?"πμ":"ΠΜ"},isPM:function(e){return"μ"===(e+"").toLowerCase()[0]},meridiemParse:/[ΠΜ]\.?Μ?\.?/i,longDateFormat:{LT:"h:mm A",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY LT",LLLL:"dddd, D MMMM YYYY LT"},calendarEl:{sameDay:"[Σήμερα {}] LT",nextDay:"[Αύριο {}] LT",nextWeek:"dddd [{}] LT",lastDay:"[Χθες {}] LT",lastWeek:function(){switch(this.day()){case 6:return"[το προηγούμενο] dddd [{}] LT";default:return"[την προηγούμενη] dddd [{}] LT"}},sameElse:"L"},calendar:function(e,t){var a=this._calendarEl[e],n=t&&t.hours();return"function"==typeof a&&(a=a.apply(t)),a.replace("{}",n%12===1?"στη":"στις")},relativeTime:{future:"σε %s",past:"%s πριν",s:"δευτερόλεπτα",m:"ένα λεπτό",mm:"%d λεπτά",h:"μία ώρα",hh:"%d ώρες",d:"μία μέρα",dd:"%d μέρες",M:"ένας μήνας",MM:"%d μήνες",y:"ένας χρόνος",yy:"%d χρόνια"},ordinal:function(e){return e+"η"},week:{dow:1,doy:4}})}),function(e){e(ft)}(function(e){return e.defineLocale("en-au",{months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),monthsShort:"Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_"),weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),weekdaysShort:"Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),weekdaysMin:"Su_Mo_Tu_We_Th_Fr_Sa".split("_"),longDateFormat:{LT:"h:mm A",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY LT",LLLL:"dddd, D MMMM YYYY LT"},calendar:{sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"},relativeTime:{future:"in %s",past:"%s ago",s:"a few seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",M:"a month",MM:"%d months",y:"a year",yy:"%d years"},ordinal:function(e){var t=e%10,a=1===~~(e%100/10)?"th":1===t?"st":2===t?"nd":3===t?"rd":"th";return e+a},week:{dow:1,doy:4}})}),function(e){e(ft)}(function(e){return e.defineLocale("en-ca",{months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),monthsShort:"Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_"),weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),weekdaysShort:"Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),weekdaysMin:"Su_Mo_Tu_We_Th_Fr_Sa".split("_"),longDateFormat:{LT:"h:mm A",L:"YYYY-MM-DD",LL:"D MMMM, YYYY",LLL:"D MMMM, YYYY LT",LLLL:"dddd, D MMMM, YYYY LT"},calendar:{sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"},relativeTime:{future:"in %s",past:"%s ago",s:"a few seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",M:"a month",MM:"%d months",y:"a year",yy:"%d years"},ordinal:function(e){var t=e%10,a=1===~~(e%100/10)?"th":1===t?"st":2===t?"nd":3===t?"rd":"th";return e+a}})}),function(e){e(ft)}(function(e){return e.defineLocale("en-gb",{months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),monthsShort:"Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_"),weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),weekdaysShort:"Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),weekdaysMin:"Su_Mo_Tu_We_Th_Fr_Sa".split("_"),longDateFormat:{LT:"HH:mm",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY LT",LLLL:"dddd, D MMMM YYYY LT"},calendar:{sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"},relativeTime:{future:"in %s",past:"%s ago",s:"a few seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",M:"a month",MM:"%d months",y:"a year",yy:"%d years"},ordinal:function(e){var t=e%10,a=1===~~(e%100/10)?"th":1===t?"st":2===t?"nd":3===t?"rd":"th";return e+a},week:{dow:1,doy:4}})}),function(e){e(ft)}(function(e){return e.defineLocale("eo",{months:"januaro_februaro_marto_aprilo_majo_junio_julio_aŭgusto_septembro_oktobro_novembro_decembro".split("_"),monthsShort:"jan_feb_mar_apr_maj_jun_jul_aŭg_sep_okt_nov_dec".split("_"),weekdays:"Dimanĉo_Lundo_Mardo_Merkredo_Ĵaŭdo_Vendredo_Sabato".split("_"),weekdaysShort:"Dim_Lun_Mard_Merk_Ĵaŭ_Ven_Sab".split("_"),weekdaysMin:"Di_Lu_Ma_Me_Ĵa_Ve_Sa".split("_"),longDateFormat:{LT:"HH:mm",L:"YYYY-MM-DD",LL:"D[-an de] MMMM, YYYY",LLL:"D[-an de] MMMM, YYYY LT",LLLL:"dddd, [la] D[-an de] MMMM, YYYY LT"},meridiem:function(e,t,a){return e>11?a?"p.t.m.":"P.T.M.":a?"a.t.m.":"A.T.M."},calendar:{sameDay:"[Hodiaŭ je] LT",nextDay:"[Morgaŭ je] LT",nextWeek:"dddd [je] LT",lastDay:"[Hieraŭ je] LT",lastWeek:"[pasinta] dddd [je] LT",sameElse:"L"},relativeTime:{future:"je %s",past:"antaŭ %s",s:"sekundoj",m:"minuto",mm:"%d minutoj",h:"horo",hh:"%d horoj",d:"tago",dd:"%d tagoj",M:"monato",MM:"%d monatoj",y:"jaro",yy:"%d jaroj"},ordinal:"%da",week:{dow:1,doy:7}})}),function(e){e(ft)}(function(e){var t="ene._feb._mar._abr._may._jun._jul._ago._sep._oct._nov._dic.".split("_"),a="ene_feb_mar_abr_may_jun_jul_ago_sep_oct_nov_dic".split("_");return e.defineLocale("es",{months:"enero_febrero_marzo_abril_mayo_junio_julio_agosto_septiembre_octubre_noviembre_diciembre".split("_"),monthsShort:function(e,n){return/-MMM-/.test(n)?a[e.month()]:t[e.month()]},weekdays:"domingo_lunes_martes_miércoles_jueves_viernes_sábado".split("_"),weekdaysShort:"dom._lun._mar._mié._jue._vie._sáb.".split("_"),weekdaysMin:"Do_Lu_Ma_Mi_Ju_Vi_Sá".split("_"),longDateFormat:{LT:"H:mm",L:"DD/MM/YYYY",LL:"D [de] MMMM [de] YYYY",LLL:"D [de] MMMM [de] YYYY LT",LLLL:"dddd, D [de] MMMM [de] YYYY LT"},calendar:{sameDay:function(){return"[hoy a la"+(1!==this.hours()?"s":"")+"] LT"},nextDay:function(){return"[mañana a la"+(1!==this.hours()?"s":"")+"] LT"},nextWeek:function(){return"dddd [a la"+(1!==this.hours()?"s":"")+"] LT"},lastDay:function(){return"[ayer a la"+(1!==this.hours()?"s":"")+"] LT"},lastWeek:function(){return"[el] dddd [pasado a la"+(1!==this.hours()?"s":"")+"] LT"},sameElse:"L"},relativeTime:{future:"en %s",past:"hace %s",s:"unos segundos",m:"un minuto",mm:"%d minutos",h:"una hora",hh:"%d horas",d:"un día",dd:"%d días",M:"un mes",MM:"%d meses",y:"un año",yy:"%d años"},ordinal:"%dº",week:{dow:1,doy:4}})}),function(e){e(ft)}(function(e){function t(e,t,a,n){var _={s:["mõne sekundi","mõni sekund","paar sekundit"],m:["ühe minuti","üks minut"],mm:[e+" minuti",e+" minutit"],h:["ühe tunni","tund aega","üks tund"],hh:[e+" tunni",e+" tundi"],d:["ühe päeva","üks päev"],M:["kuu aja","kuu aega","üks kuu"],MM:[e+" kuu",e+" kuud"],y:["ühe aasta","aasta","üks aasta"],yy:[e+" aasta",e+" aastat"]};return t?_[a][2]?_[a][2]:_[a][1]:n?_[a][0]:_[a][1]}return e.defineLocale("et",{months:"jaanuar_veebruar_märts_aprill_mai_juuni_juuli_august_september_oktoober_november_detsember".split("_"),monthsShort:"jaan_veebr_märts_apr_mai_juuni_juuli_aug_sept_okt_nov_dets".split("_"),weekdays:"pühapäev_esmaspäev_teisipäev_kolmapäev_neljapäev_reede_laupäev".split("_"),weekdaysShort:"P_E_T_K_N_R_L".split("_"),weekdaysMin:"P_E_T_K_N_R_L".split("_"),longDateFormat:{LT:"H:mm",L:"DD.MM.YYYY",LL:"D. MMMM YYYY",LLL:"D. MMMM YYYY LT",LLLL:"dddd, D. MMMM YYYY LT"},calendar:{sameDay:"[Täna,] LT",nextDay:"[Homme,] LT",nextWeek:"[Järgmine] dddd LT",lastDay:"[Eile,] LT",lastWeek:"[Eelmine] dddd LT",sameElse:"L"},relativeTime:{future:"%s pärast",past:"%s tagasi",s:t,m:t,mm:t,h:t,hh:t,d:t,dd:"%d päeva",M:t,MM:t,y:t,yy:t},ordinal:"%d.",week:{dow:1,doy:4}})
+}),function(e){e(ft)}(function(e){return e.defineLocale("eu",{months:"urtarrila_otsaila_martxoa_apirila_maiatza_ekaina_uztaila_abuztua_iraila_urria_azaroa_abendua".split("_"),monthsShort:"urt._ots._mar._api._mai._eka._uzt._abu._ira._urr._aza._abe.".split("_"),weekdays:"igandea_astelehena_asteartea_asteazkena_osteguna_ostirala_larunbata".split("_"),weekdaysShort:"ig._al._ar._az._og._ol._lr.".split("_"),weekdaysMin:"ig_al_ar_az_og_ol_lr".split("_"),longDateFormat:{LT:"HH:mm",L:"YYYY-MM-DD",LL:"YYYY[ko] MMMM[ren] D[a]",LLL:"YYYY[ko] MMMM[ren] D[a] LT",LLLL:"dddd, YYYY[ko] MMMM[ren] D[a] LT",l:"YYYY-M-D",ll:"YYYY[ko] MMM D[a]",lll:"YYYY[ko] MMM D[a] LT",llll:"ddd, YYYY[ko] MMM D[a] LT"},calendar:{sameDay:"[gaur] LT[etan]",nextDay:"[bihar] LT[etan]",nextWeek:"dddd LT[etan]",lastDay:"[atzo] LT[etan]",lastWeek:"[aurreko] dddd LT[etan]",sameElse:"L"},relativeTime:{future:"%s barru",past:"duela %s",s:"segundo batzuk",m:"minutu bat",mm:"%d minutu",h:"ordu bat",hh:"%d ordu",d:"egun bat",dd:"%d egun",M:"hilabete bat",MM:"%d hilabete",y:"urte bat",yy:"%d urte"},ordinal:"%d.",week:{dow:1,doy:7}})}),function(e){e(ft)}(function(e){var t={1:"۱",2:"۲",3:"۳",4:"۴",5:"۵",6:"۶",7:"۷",8:"۸",9:"۹",0:"۰"},a={"۱":"1","۲":"2","۳":"3","۴":"4","۵":"5","۶":"6","۷":"7","۸":"8","۹":"9","۰":"0"};return e.defineLocale("fa",{months:"ژانویه_فوریه_مارس_آوریل_مه_ژوئن_ژوئیه_اوت_سپتامبر_اکتبر_نوامبر_دسامبر".split("_"),monthsShort:"ژانویه_فوریه_مارس_آوریل_مه_ژوئن_ژوئیه_اوت_سپتامبر_اکتبر_نوامبر_دسامبر".split("_"),weekdays:"یک‌شنبه_دوشنبه_سه‌شنبه_چهارشنبه_پنج‌شنبه_جمعه_شنبه".split("_"),weekdaysShort:"یک‌شنبه_دوشنبه_سه‌شنبه_چهارشنبه_پنج‌شنبه_جمعه_شنبه".split("_"),weekdaysMin:"ی_د_س_چ_پ_ج_ش".split("_"),longDateFormat:{LT:"HH:mm",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY LT",LLLL:"dddd, D MMMM YYYY LT"},meridiem:function(e){return 12>e?"قبل از ظهر":"بعد از ظهر"},calendar:{sameDay:"[امروز ساعت] LT",nextDay:"[فردا ساعت] LT",nextWeek:"dddd [ساعت] LT",lastDay:"[دیروز ساعت] LT",lastWeek:"dddd [پیش] [ساعت] LT",sameElse:"L"},relativeTime:{future:"در %s",past:"%s پیش",s:"چندین ثانیه",m:"یک دقیقه",mm:"%d دقیقه",h:"یک ساعت",hh:"%d ساعت",d:"یک روز",dd:"%d روز",M:"یک ماه",MM:"%d ماه",y:"یک سال",yy:"%d سال"},preparse:function(e){return e.replace(/[۰-۹]/g,function(e){return a[e]}).replace(/،/g,",")},postformat:function(e){return e.replace(/\d/g,function(e){return t[e]}).replace(/,/g,"،")},ordinal:"%dم",week:{dow:6,doy:12}})}),function(e){e(ft)}(function(e){function t(e,t,n,_){var s="";switch(n){case"s":return _?"muutaman sekunnin":"muutama sekunti";case"m":return _?"minuutin":"minuutti";case"mm":s=_?"minuutin":"minuuttia";break;case"h":return _?"tunnin":"tunti";case"hh":s=_?"tunnin":"tuntia";break;case"d":return _?"päivän":"päivä";case"dd":s=_?"päivän":"päivää";break;case"M":return _?"kuukauden":"kuukausi";case"MM":s=_?"kuukauden":"kuukautta";break;case"y":return _?"vuoden":"vuosi";case"yy":s=_?"vuoden":"vuotta"}return s=a(e,_)+" "+s}function a(e,t){return 10>e?t?_[e]:n[e]:e}var n="nolla yksi kaksi kolme neljä viisi kuusi seitsemän kahdeksan yhdeksän".split(" "),_=["nolla","yhden","kahden","kolmen","neljän","viiden","kuuden",n[7],n[8],n[9]];return e.defineLocale("fi",{months:"tammikuu_helmikuu_maaliskuu_huhtikuu_toukokuu_kesäkuu_heinäkuu_elokuu_syyskuu_lokakuu_marraskuu_joulukuu".split("_"),monthsShort:"tammi_helmi_maalis_huhti_touko_kesä_heinä_elo_syys_loka_marras_joulu".split("_"),weekdays:"sunnuntai_maanantai_tiistai_keskiviikko_torstai_perjantai_lauantai".split("_"),weekdaysShort:"su_ma_ti_ke_to_pe_la".split("_"),weekdaysMin:"su_ma_ti_ke_to_pe_la".split("_"),longDateFormat:{LT:"HH.mm",L:"DD.MM.YYYY",LL:"Do MMMM[ta] YYYY",LLL:"Do MMMM[ta] YYYY, [klo] LT",LLLL:"dddd, Do MMMM[ta] YYYY, [klo] LT",l:"D.M.YYYY",ll:"Do MMM YYYY",lll:"Do MMM YYYY, [klo] LT",llll:"ddd, Do MMM YYYY, [klo] LT"},calendar:{sameDay:"[tänään] [klo] LT",nextDay:"[huomenna] [klo] LT",nextWeek:"dddd [klo] LT",lastDay:"[eilen] [klo] LT",lastWeek:"[viime] dddd[na] [klo] LT",sameElse:"L"},relativeTime:{future:"%s päästä",past:"%s sitten",s:t,m:t,mm:t,h:t,hh:t,d:t,dd:t,M:t,MM:t,y:t,yy:t},ordinal:"%d.",week:{dow:1,doy:4}})}),function(e){e(ft)}(function(e){return e.defineLocale("fo",{months:"januar_februar_mars_apríl_mai_juni_juli_august_september_oktober_november_desember".split("_"),monthsShort:"jan_feb_mar_apr_mai_jun_jul_aug_sep_okt_nov_des".split("_"),weekdays:"sunnudagur_mánadagur_týsdagur_mikudagur_hósdagur_fríggjadagur_leygardagur".split("_"),weekdaysShort:"sun_mán_týs_mik_hós_frí_ley".split("_"),weekdaysMin:"su_má_tý_mi_hó_fr_le".split("_"),longDateFormat:{LT:"HH:mm",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY LT",LLLL:"dddd D. MMMM, YYYY LT"},calendar:{sameDay:"[Í dag kl.] LT",nextDay:"[Í morgin kl.] LT",nextWeek:"dddd [kl.] LT",lastDay:"[Í gjár kl.] LT",lastWeek:"[síðstu] dddd [kl] LT",sameElse:"L"},relativeTime:{future:"um %s",past:"%s síðani",s:"fá sekund",m:"ein minutt",mm:"%d minuttir",h:"ein tími",hh:"%d tímar",d:"ein dagur",dd:"%d dagar",M:"ein mánaði",MM:"%d mánaðir",y:"eitt ár",yy:"%d ár"},ordinal:"%d.",week:{dow:1,doy:4}})}),function(e){e(ft)}(function(e){return e.defineLocale("fr-ca",{months:"janvier_février_mars_avril_mai_juin_juillet_août_septembre_octobre_novembre_décembre".split("_"),monthsShort:"janv._févr._mars_avr._mai_juin_juil._août_sept._oct._nov._déc.".split("_"),weekdays:"dimanche_lundi_mardi_mercredi_jeudi_vendredi_samedi".split("_"),weekdaysShort:"dim._lun._mar._mer._jeu._ven._sam.".split("_"),weekdaysMin:"Di_Lu_Ma_Me_Je_Ve_Sa".split("_"),longDateFormat:{LT:"HH:mm",L:"YYYY-MM-DD",LL:"D MMMM YYYY",LLL:"D MMMM YYYY LT",LLLL:"dddd D MMMM YYYY LT"},calendar:{sameDay:"[Aujourd'hui à] LT",nextDay:"[Demain à] LT",nextWeek:"dddd [à] LT",lastDay:"[Hier à] LT",lastWeek:"dddd [dernier à] LT",sameElse:"L"},relativeTime:{future:"dans %s",past:"il y a %s",s:"quelques secondes",m:"une minute",mm:"%d minutes",h:"une heure",hh:"%d heures",d:"un jour",dd:"%d jours",M:"un mois",MM:"%d mois",y:"un an",yy:"%d ans"},ordinal:function(e){return e+(1===e?"er":"")}})}),function(e){e(ft)}(function(e){return e.defineLocale("fr",{months:"janvier_février_mars_avril_mai_juin_juillet_août_septembre_octobre_novembre_décembre".split("_"),monthsShort:"janv._févr._mars_avr._mai_juin_juil._août_sept._oct._nov._déc.".split("_"),weekdays:"dimanche_lundi_mardi_mercredi_jeudi_vendredi_samedi".split("_"),weekdaysShort:"dim._lun._mar._mer._jeu._ven._sam.".split("_"),weekdaysMin:"Di_Lu_Ma_Me_Je_Ve_Sa".split("_"),longDateFormat:{LT:"HH:mm",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY LT",LLLL:"dddd D MMMM YYYY LT"},calendar:{sameDay:"[Aujourd'hui à] LT",nextDay:"[Demain à] LT",nextWeek:"dddd [à] LT",lastDay:"[Hier à] LT",lastWeek:"dddd [dernier à] LT",sameElse:"L"},relativeTime:{future:"dans %s",past:"il y a %s",s:"quelques secondes",m:"une minute",mm:"%d minutes",h:"une heure",hh:"%d heures",d:"un jour",dd:"%d jours",M:"un mois",MM:"%d mois",y:"un an",yy:"%d ans"},ordinal:function(e){return e+(1===e?"er":"")},week:{dow:1,doy:4}})}),function(e){e(ft)}(function(e){return e.defineLocale("gl",{months:"Xaneiro_Febreiro_Marzo_Abril_Maio_Xuño_Xullo_Agosto_Setembro_Outubro_Novembro_Decembro".split("_"),monthsShort:"Xan._Feb._Mar._Abr._Mai._Xuñ._Xul._Ago._Set._Out._Nov._Dec.".split("_"),weekdays:"Domingo_Luns_Martes_Mércores_Xoves_Venres_Sábado".split("_"),weekdaysShort:"Dom._Lun._Mar._Mér._Xov._Ven._Sáb.".split("_"),weekdaysMin:"Do_Lu_Ma_Mé_Xo_Ve_Sá".split("_"),longDateFormat:{LT:"H:mm",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY LT",LLLL:"dddd D MMMM YYYY LT"},calendar:{sameDay:function(){return"[hoxe "+(1!==this.hours()?"ás":"á")+"] LT"},nextDay:function(){return"[mañá "+(1!==this.hours()?"ás":"á")+"] LT"},nextWeek:function(){return"dddd ["+(1!==this.hours()?"ás":"a")+"] LT"},lastDay:function(){return"[onte "+(1!==this.hours()?"á":"a")+"] LT"},lastWeek:function(){return"[o] dddd [pasado "+(1!==this.hours()?"ás":"a")+"] LT"},sameElse:"L"},relativeTime:{future:function(e){return"uns segundos"===e?"nuns segundos":"en "+e},past:"hai %s",s:"uns segundos",m:"un minuto",mm:"%d minutos",h:"unha hora",hh:"%d horas",d:"un día",dd:"%d días",M:"un mes",MM:"%d meses",y:"un ano",yy:"%d anos"},ordinal:"%dº",week:{dow:1,doy:7}})}),function(e){e(ft)}(function(e){return e.defineLocale("he",{months:"ינואר_פברואר_מרץ_אפריל_מאי_יוני_יולי_אוגוסט_ספטמבר_אוקטובר_נובמבר_דצמבר".split("_"),monthsShort:"ינו׳_פבר׳_מרץ_אפר׳_מאי_יוני_יולי_אוג׳_ספט׳_אוק׳_נוב׳_דצמ׳".split("_"),weekdays:"ראשון_שני_שלישי_רביעי_חמישי_שישי_שבת".split("_"),weekdaysShort:"א׳_ב׳_ג׳_ד׳_ה׳_ו׳_ש׳".split("_"),weekdaysMin:"א_ב_ג_ד_ה_ו_ש".split("_"),longDateFormat:{LT:"HH:mm",L:"DD/MM/YYYY",LL:"D [ב]MMMM YYYY",LLL:"D [ב]MMMM YYYY LT",LLLL:"dddd, D [ב]MMMM YYYY LT",l:"D/M/YYYY",ll:"D MMM YYYY",lll:"D MMM YYYY LT",llll:"ddd, D MMM YYYY LT"},calendar:{sameDay:"[היום ב־]LT",nextDay:"[מחר ב־]LT",nextWeek:"dddd [בשעה] LT",lastDay:"[אתמול ב־]LT",lastWeek:"[ביום] dddd [האחרון בשעה] LT",sameElse:"L"},relativeTime:{future:"בעוד %s",past:"לפני %s",s:"מספר שניות",m:"דקה",mm:"%d דקות",h:"שעה",hh:function(e){return 2===e?"שעתיים":e+" שעות"},d:"יום",dd:function(e){return 2===e?"יומיים":e+" ימים"},M:"חודש",MM:function(e){return 2===e?"חודשיים":e+" חודשים"},y:"שנה",yy:function(e){return 2===e?"שנתיים":e+" שנים"}}})}),function(e){e(ft)}(function(e){var t={1:"१",2:"२",3:"३",4:"४",5:"५",6:"६",7:"७",8:"८",9:"९",0:"०"},a={"१":"1","२":"2","३":"3","४":"4","५":"5","६":"6","७":"7","८":"8","९":"9","०":"0"};return e.defineLocale("hi",{months:"जनवरी_फ़रवरी_मार्च_अप्रैल_मई_जून_जुलाई_अगस्त_सितम्बर_अक्टूबर_नवम्बर_दिसम्बर".split("_"),monthsShort:"जन._फ़र._मार्च_अप्रै._मई_जून_जुल._अग._सित._अक्टू._नव._दिस.".split("_"),weekdays:"रविवार_सोमवार_मंगलवार_बुधवार_गुरूवार_शुक्रवार_शनिवार".split("_"),weekdaysShort:"रवि_सोम_मंगल_बुध_गुरू_शुक्र_शनि".split("_"),weekdaysMin:"र_सो_मं_बु_गु_शु_श".split("_"),longDateFormat:{LT:"A h:mm बजे",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY, LT",LLLL:"dddd, D MMMM YYYY, LT"},calendar:{sameDay:"[आज] LT",nextDay:"[कल] LT",nextWeek:"dddd, LT",lastDay:"[कल] LT",lastWeek:"[पिछले] dddd, LT",sameElse:"L"},relativeTime:{future:"%s में",past:"%s पहले",s:"कुछ ही क्षण",m:"एक मिनट",mm:"%d मिनट",h:"एक घंटा",hh:"%d घंटे",d:"एक दिन",dd:"%d दिन",M:"एक महीने",MM:"%d महीने",y:"एक वर्ष",yy:"%d वर्ष"},preparse:function(e){return e.replace(/[१२३४५६७८९०]/g,function(e){return a[e]})},postformat:function(e){return e.replace(/\d/g,function(e){return t[e]})},meridiem:function(e){return 4>e?"रात":10>e?"सुबह":17>e?"दोपहर":20>e?"शाम":"रात"},week:{dow:0,doy:6}})}),function(e){e(ft)}(function(e){function t(e,t,a){var n=e+" ";switch(a){case"m":return t?"jedna minuta":"jedne minute";case"mm":return n+=1===e?"minuta":2===e||3===e||4===e?"minute":"minuta";case"h":return t?"jedan sat":"jednog sata";case"hh":return n+=1===e?"sat":2===e||3===e||4===e?"sata":"sati";case"dd":return n+=1===e?"dan":"dana";case"MM":return n+=1===e?"mjesec":2===e||3===e||4===e?"mjeseca":"mjeseci";case"yy":return n+=1===e?"godina":2===e||3===e||4===e?"godine":"godina"}}return e.defineLocale("hr",{months:"sječanj_veljača_ožujak_travanj_svibanj_lipanj_srpanj_kolovoz_rujan_listopad_studeni_prosinac".split("_"),monthsShort:"sje._vel._ožu._tra._svi._lip._srp._kol._ruj._lis._stu._pro.".split("_"),weekdays:"nedjelja_ponedjeljak_utorak_srijeda_četvrtak_petak_subota".split("_"),weekdaysShort:"ned._pon._uto._sri._čet._pet._sub.".split("_"),weekdaysMin:"ne_po_ut_sr_če_pe_su".split("_"),longDateFormat:{LT:"H:mm",L:"DD. MM. YYYY",LL:"D. MMMM YYYY",LLL:"D. MMMM YYYY LT",LLLL:"dddd, D. MMMM YYYY LT"},calendar:{sameDay:"[danas u] LT",nextDay:"[sutra u] LT",nextWeek:function(){switch(this.day()){case 0:return"[u] [nedjelju] [u] LT";case 3:return"[u] [srijedu] [u] LT";case 6:return"[u] [subotu] [u] LT";case 1:case 2:case 4:case 5:return"[u] dddd [u] LT"}},lastDay:"[jučer u] LT",lastWeek:function(){switch(this.day()){case 0:case 3:return"[prošlu] dddd [u] LT";case 6:return"[prošle] [subote] [u] LT";case 1:case 2:case 4:case 5:return"[prošli] dddd [u] LT"}},sameElse:"L"},relativeTime:{future:"za %s",past:"prije %s",s:"par sekundi",m:t,mm:t,h:t,hh:t,d:"dan",dd:t,M:"mjesec",MM:t,y:"godinu",yy:t},ordinal:"%d.",week:{dow:1,doy:7}})}),function(e){e(ft)}(function(e){function t(e,t,a,n){var _=e;switch(a){case"s":return n||t?"néhány másodperc":"néhány másodperce";case"m":return"egy"+(n||t?" perc":" perce");case"mm":return _+(n||t?" perc":" perce");case"h":return"egy"+(n||t?" óra":" órája");case"hh":return _+(n||t?" óra":" órája");case"d":return"egy"+(n||t?" nap":" napja");case"dd":return _+(n||t?" nap":" napja");case"M":return"egy"+(n||t?" hónap":" hónapja");case"MM":return _+(n||t?" hónap":" hónapja");case"y":return"egy"+(n||t?" év":" éve");case"yy":return _+(n||t?" év":" éve")}return""}function a(e){return(e?"":"[múlt] ")+"["+n[this.day()]+"] LT[-kor]"}var n="vasárnap hétfőn kedden szerdán csütörtökön pénteken szombaton".split(" ");return e.defineLocale("hu",{months:"január_február_március_április_május_június_július_augusztus_szeptember_október_november_december".split("_"),monthsShort:"jan_feb_márc_ápr_máj_jún_júl_aug_szept_okt_nov_dec".split("_"),weekdays:"vasárnap_hétfő_kedd_szerda_csütörtök_péntek_szombat".split("_"),weekdaysShort:"vas_hét_kedd_sze_csüt_pén_szo".split("_"),weekdaysMin:"v_h_k_sze_cs_p_szo".split("_"),longDateFormat:{LT:"H:mm",L:"YYYY.MM.DD.",LL:"YYYY. MMMM D.",LLL:"YYYY. MMMM D., LT",LLLL:"YYYY. MMMM D., dddd LT"},meridiem:function(e,t,a){return 12>e?a===!0?"de":"DE":a===!0?"du":"DU"},calendar:{sameDay:"[ma] LT[-kor]",nextDay:"[holnap] LT[-kor]",nextWeek:function(){return a.call(this,!0)},lastDay:"[tegnap] LT[-kor]",lastWeek:function(){return a.call(this,!1)},sameElse:"L"},relativeTime:{future:"%s múlva",past:"%s",s:t,m:t,mm:t,h:t,hh:t,d:t,dd:t,M:t,MM:t,y:t,yy:t},ordinal:"%d.",week:{dow:1,doy:7}})}),function(e){e(ft)}(function(e){function t(e,t){var a={nominative:"հունվար_փետրվար_մարտ_ապրիլ_մայիս_հունիս_հուլիս_օգոստոս_սեպտեմբեր_հոկտեմբեր_նոյեմբեր_դեկտեմբեր".split("_"),accusative:"հունվարի_փետրվարի_մարտի_ապրիլի_մայիսի_հունիսի_հուլիսի_օգոստոսի_սեպտեմբերի_հոկտեմբերի_նոյեմբերի_դեկտեմբերի".split("_")},n=/D[oD]?(\[[^\[\]]*\]|\s+)+MMMM?/.test(t)?"accusative":"nominative";return a[n][e.month()]}function a(e){var t="հնվ_փտր_մրտ_ապր_մյս_հնս_հլս_օգս_սպտ_հկտ_նմբ_դկտ".split("_");return t[e.month()]}function n(e){var t="կիրակի_երկուշաբթի_երեքշաբթի_չորեքշաբթի_հինգշաբթի_ուրբաթ_շաբաթ".split("_");return t[e.day()]}return e.defineLocale("hy-am",{months:t,monthsShort:a,weekdays:n,weekdaysShort:"կրկ_երկ_երք_չրք_հնգ_ուրբ_շբթ".split("_"),weekdaysMin:"կրկ_երկ_երք_չրք_հնգ_ուրբ_շբթ".split("_"),longDateFormat:{LT:"HH:mm",L:"DD.MM.YYYY",LL:"D MMMM YYYY թ.",LLL:"D MMMM YYYY թ., LT",LLLL:"dddd, D MMMM YYYY թ., LT"},calendar:{sameDay:"[այսօր] LT",nextDay:"[վաղը] LT",lastDay:"[երեկ] LT",nextWeek:function(){return"dddd [օրը ժամը] LT"},lastWeek:function(){return"[անցած] dddd [օրը ժամը] LT"},sameElse:"L"},relativeTime:{future:"%s հետո",past:"%s առաջ",s:"մի քանի վայրկյան",m:"րոպե",mm:"%d րոպե",h:"ժամ",hh:"%d ժամ",d:"օր",dd:"%d օր",M:"ամիս",MM:"%d ամիս",y:"տարի",yy:"%d տարի"},meridiem:function(e){return 4>e?"գիշերվա":12>e?"առավոտվա":17>e?"ցերեկվա":"երեկոյան"},ordinal:function(e,t){switch(t){case"DDD":case"w":case"W":case"DDDo":return 1===e?e+"-ին":e+"-րդ";default:return e}},week:{dow:1,doy:7}})}),function(e){e(ft)}(function(e){return e.defineLocale("id",{months:"Januari_Februari_Maret_April_Mei_Juni_Juli_Agustus_September_Oktober_November_Desember".split("_"),monthsShort:"Jan_Feb_Mar_Apr_Mei_Jun_Jul_Ags_Sep_Okt_Nov_Des".split("_"),weekdays:"Minggu_Senin_Selasa_Rabu_Kamis_Jumat_Sabtu".split("_"),weekdaysShort:"Min_Sen_Sel_Rab_Kam_Jum_Sab".split("_"),weekdaysMin:"Mg_Sn_Sl_Rb_Km_Jm_Sb".split("_"),longDateFormat:{LT:"HH.mm",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY [pukul] LT",LLLL:"dddd, D MMMM YYYY [pukul] LT"},meridiem:function(e){return 11>e?"pagi":15>e?"siang":19>e?"sore":"malam"},calendar:{sameDay:"[Hari ini pukul] LT",nextDay:"[Besok pukul] LT",nextWeek:"dddd [pukul] LT",lastDay:"[Kemarin pukul] LT",lastWeek:"dddd [lalu pukul] LT",sameElse:"L"},relativeTime:{future:"dalam %s",past:"%s yang lalu",s:"beberapa detik",m:"semenit",mm:"%d menit",h:"sejam",hh:"%d jam",d:"sehari",dd:"%d hari",M:"sebulan",MM:"%d bulan",y:"setahun",yy:"%d tahun"},week:{dow:1,doy:7}})}),function(e){e(ft)}(function(e){function t(e){return e%100===11?!0:e%10===1?!1:!0}function a(e,a,n,_){var s=e+" ";switch(n){case"s":return a||_?"nokkrar sekúndur":"nokkrum sekúndum";case"m":return a?"mínúta":"mínútu";case"mm":return t(e)?s+(a||_?"mínútur":"mínútum"):a?s+"mínúta":s+"mínútu";case"hh":return t(e)?s+(a||_?"klukkustundir":"klukkustundum"):s+"klukkustund";case"d":return a?"dagur":_?"dag":"degi";case"dd":return t(e)?a?s+"dagar":s+(_?"daga":"dögum"):a?s+"dagur":s+(_?"dag":"degi");case"M":return a?"mánuður":_?"mánuð":"mánuði";case"MM":return t(e)?a?s+"mánuðir":s+(_?"mánuði":"mánuðum"):a?s+"mánuður":s+(_?"mánuð":"mánuði");case"y":return a||_?"ár":"ári";case"yy":return t(e)?s+(a||_?"ár":"árum"):s+(a||_?"ár":"ári")}}return e.defineLocale("is",{months:"janúar_febrúar_mars_apríl_maí_júní_júlí_ágúst_september_október_nóvember_desember".split("_"),monthsShort:"jan_feb_mar_apr_maí_jún_júl_ágú_sep_okt_nóv_des".split("_"),weekdays:"sunnudagur_mánudagur_þriðjudagur_miðvikudagur_fimmtudagur_föstudagur_laugardagur".split("_"),weekdaysShort:"sun_mán_þri_mið_fim_fös_lau".split("_"),weekdaysMin:"Su_Má_Þr_Mi_Fi_Fö_La".split("_"),longDateFormat:{LT:"H:mm",L:"DD/MM/YYYY",LL:"D. MMMM YYYY",LLL:"D. MMMM YYYY [kl.] LT",LLLL:"dddd, D. MMMM YYYY [kl.] LT"},calendar:{sameDay:"[í dag kl.] LT",nextDay:"[á morgun kl.] LT",nextWeek:"dddd [kl.] LT",lastDay:"[í gær kl.] LT",lastWeek:"[síðasta] dddd [kl.] LT",sameElse:"L"},relativeTime:{future:"eftir %s",past:"fyrir %s síðan",s:a,m:a,mm:a,h:"klukkustund",hh:a,d:a,dd:a,M:a,MM:a,y:a,yy:a},ordinal:"%d.",week:{dow:1,doy:4}})}),function(e){e(ft)}(function(e){return e.defineLocale("it",{months:"gennaio_febbraio_marzo_aprile_maggio_giugno_luglio_agosto_settembre_ottobre_novembre_dicembre".split("_"),monthsShort:"gen_feb_mar_apr_mag_giu_lug_ago_set_ott_nov_dic".split("_"),weekdays:"Domenica_Lunedì_Martedì_Mercoledì_Giovedì_Venerdì_Sabato".split("_"),weekdaysShort:"Dom_Lun_Mar_Mer_Gio_Ven_Sab".split("_"),weekdaysMin:"D_L_Ma_Me_G_V_S".split("_"),longDateFormat:{LT:"HH:mm",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY LT",LLLL:"dddd, D MMMM YYYY LT"},calendar:{sameDay:"[Oggi alle] LT",nextDay:"[Domani alle] LT",nextWeek:"dddd [alle] LT",lastDay:"[Ieri alle] LT",lastWeek:"[lo scorso] dddd [alle] LT",sameElse:"L"},relativeTime:{future:function(e){return(/^[0-9].+$/.test(e)?"tra":"in")+" "+e},past:"%s fa",s:"alcuni secondi",m:"un minuto",mm:"%d minuti",h:"un'ora",hh:"%d ore",d:"un giorno",dd:"%d giorni",M:"un mese",MM:"%d mesi",y:"un anno",yy:"%d anni"},ordinal:"%dº",week:{dow:1,doy:4}})}),function(e){e(ft)}(function(e){return e.defineLocale("ja",{months:"1月_2月_3月_4月_5月_6月_7月_8月_9月_10月_11月_12月".split("_"),monthsShort:"1月_2月_3月_4月_5月_6月_7月_8月_9月_10月_11月_12月".split("_"),weekdays:"日曜日_月曜日_火曜日_水曜日_木曜日_金曜日_土曜日".split("_"),weekdaysShort:"日_月_火_水_木_金_土".split("_"),weekdaysMin:"日_月_火_水_木_金_土".split("_"),longDateFormat:{LT:"Ah時m分",L:"YYYY/MM/DD",LL:"YYYY年M月D日",LLL:"YYYY年M月D日LT",LLLL:"YYYY年M月D日LT dddd"},meridiem:function(e){return 12>e?"午前":"午後"},calendar:{sameDay:"[今日] LT",nextDay:"[明日] LT",nextWeek:"[来週]dddd LT",lastDay:"[昨日] LT",lastWeek:"[前週]dddd LT",sameElse:"L"},relativeTime:{future:"%s後",past:"%s前",s:"数秒",m:"1分",mm:"%d分",h:"1時間",hh:"%d時間",d:"1日",dd:"%d日",M:"1ヶ月",MM:"%dヶ月",y:"1年",yy:"%d年"}})}),function(e){e(ft)}(function(e){function t(e,t){var a={nominative:"იანვარი_თებერვალი_მარტი_აპრილი_მაისი_ივნისი_ივლისი_აგვისტო_სექტემბერი_ოქტომბერი_ნოემბერი_დეკემბერი".split("_"),accusative:"იანვარს_თებერვალს_მარტს_აპრილის_მაისს_ივნისს_ივლისს_აგვისტს_სექტემბერს_ოქტომბერს_ნოემბერს_დეკემბერს".split("_")},n=/D[oD] *MMMM?/.test(t)?"accusative":"nominative";return a[n][e.month()]}function a(e,t){var a={nominative:"კვირა_ორშაბათი_სამშაბათი_ოთხშაბათი_ხუთშაბათი_პარასკევი_შაბათი".split("_"),accusative:"კვირას_ორშაბათს_სამშაბათს_ოთხშაბათს_ხუთშაბათს_პარასკევს_შაბათს".split("_")},n=/(წინა|შემდეგ)/.test(t)?"accusative":"nominative";return a[n][e.day()]}return e.defineLocale("ka",{months:t,monthsShort:"იან_თებ_მარ_აპრ_მაი_ივნ_ივლ_აგვ_სექ_ოქტ_ნოე_დეკ".split("_"),weekdays:a,weekdaysShort:"კვი_ორშ_სამ_ოთხ_ხუთ_პარ_შაბ".split("_"),weekdaysMin:"კვ_ორ_სა_ოთ_ხუ_პა_შა".split("_"),longDateFormat:{LT:"h:mm A",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY LT",LLLL:"dddd, D MMMM YYYY LT"},calendar:{sameDay:"[დღეს] LT[-ზე]",nextDay:"[ხვალ] LT[-ზე]",lastDay:"[გუშინ] LT[-ზე]",nextWeek:"[შემდეგ] dddd LT[-ზე]",lastWeek:"[წინა] dddd LT-ზე",sameElse:"L"},relativeTime:{future:function(e){return/(წამი|წუთი|საათი|წელი)/.test(e)?e.replace(/ი$/,"ში"):e+"ში"},past:function(e){return/(წამი|წუთი|საათი|დღე|თვე)/.test(e)?e.replace(/(ი|ე)$/,"ის წინ"):/წელი/.test(e)?e.replace(/წელი$/,"წლის წინ"):void 0},s:"რამდენიმე წამი",m:"წუთი",mm:"%d წუთი",h:"საათი",hh:"%d საათი",d:"დღე",dd:"%d დღე",M:"თვე",MM:"%d თვე",y:"წელი",yy:"%d წელი"},ordinal:function(e){return 0===e?e:1===e?e+"-ლი":20>e||100>=e&&e%20===0||e%100===0?"მე-"+e:e+"-ე"},week:{dow:1,doy:7}})}),function(e){e(ft)}(function(e){return e.defineLocale("km",{months:"មករា_កុម្ភៈ_មិនា_មេសា_ឧសភា_មិថុនា_កក្កដា_សីហា_កញ្ញា_តុលា_វិច្ឆិកា_ធ្នូ".split("_"),monthsShort:"មករា_កុម្ភៈ_មិនា_មេសា_ឧសភា_មិថុនា_កក្កដា_សីហា_កញ្ញា_តុលា_វិច្ឆិកា_ធ្នូ".split("_"),weekdays:"អាទិត្យ_ច័ន្ទ_អង្គារ_ពុធ_ព្រហស្បតិ៍_សុក្រ_សៅរ៍".split("_"),weekdaysShort:"អាទិត្យ_ច័ន្ទ_អង្គារ_ពុធ_ព្រហស្បតិ៍_សុក្រ_សៅរ៍".split("_"),weekdaysMin:"អាទិត្យ_ច័ន្ទ_អង្គារ_ពុធ_ព្រហស្បតិ៍_សុក្រ_សៅរ៍".split("_"),longDateFormat:{LT:"HH:mm",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY LT",LLLL:"dddd, D MMMM YYYY LT"},calendar:{sameDay:"[ថ្ងៃនៈ ម៉ោង] LT",nextDay:"[ស្អែក ម៉ោង] LT",nextWeek:"dddd [ម៉ោង] LT",lastDay:"[ម្សិលមិញ ម៉ោង] LT",lastWeek:"dddd [សប្តាហ៍មុន] [ម៉ោង] LT",sameElse:"L"},relativeTime:{future:"%sទៀត",past:"%sមុន",s:"ប៉ុន្មានវិនាទី",m:"មួយនាទី",mm:"%d នាទី",h:"មួយម៉ោង",hh:"%d ម៉ោង",d:"មួយថ្ងៃ",dd:"%d ថ្ងៃ",M:"មួយខែ",MM:"%d ខែ",y:"មួយឆ្នាំ",yy:"%d ឆ្នាំ"},week:{dow:1,doy:4}})}),function(e){e(ft)}(function(e){return e.defineLocale("ko",{months:"1월_2월_3월_4월_5월_6월_7월_8월_9월_10월_11월_12월".split("_"),monthsShort:"1월_2월_3월_4월_5월_6월_7월_8월_9월_10월_11월_12월".split("_"),weekdays:"일요일_월요일_화요일_수요일_목요일_금요일_토요일".split("_"),weekdaysShort:"일_월_화_수_목_금_토".split("_"),weekdaysMin:"일_월_화_수_목_금_토".split("_"),longDateFormat:{LT:"A h시 m분",L:"YYYY.MM.DD",LL:"YYYY년 MMMM D일",LLL:"YYYY년 MMMM D일 LT",LLLL:"YYYY년 MMMM D일 dddd LT"},meridiem:function(e){return 12>e?"오전":"오후"},calendar:{sameDay:"오늘 LT",nextDay:"내일 LT",nextWeek:"dddd LT",lastDay:"어제 LT",lastWeek:"지난주 dddd LT",sameElse:"L"},relativeTime:{future:"%s 후",past:"%s 전",s:"몇초",ss:"%d초",m:"일분",mm:"%d분",h:"한시간",hh:"%d시간",d:"하루",dd:"%d일",M:"한달",MM:"%d달",y:"일년",yy:"%d년"},ordinal:"%d일",meridiemParse:/(오전|오후)/,isPM:function(e){return"오후"===e}})}),function(e){e(ft)}(function(e){function t(e,t,a){var n={m:["eng Minutt","enger Minutt"],h:["eng Stonn","enger Stonn"],d:["een Dag","engem Dag"],M:["ee Mount","engem Mount"],y:["ee Joer","engem Joer"]};return t?n[a][0]:n[a][1]}function a(e){var t=e.substr(0,e.indexOf(" "));return _(t)?"a "+e:"an "+e}function n(e){var t=e.substr(0,e.indexOf(" "));return _(t)?"viru "+e:"virun "+e}function _(e){if(e=parseInt(e,10),isNaN(e))return!1;if(0>e)return!0;if(10>e)return e>=4&&7>=e?!0:!1;if(100>e){var t=e%10,a=e/10;return _(0===t?a:t)}if(1e4>e){for(;e>=10;)e/=10;return _(e)}return e/=1e3,_(e)}return e.defineLocale("lb",{months:"Januar_Februar_Mäerz_Abrëll_Mee_Juni_Juli_August_September_Oktober_November_Dezember".split("_"),monthsShort:"Jan._Febr._Mrz._Abr._Mee_Jun._Jul._Aug._Sept._Okt._Nov._Dez.".split("_"),weekdays:"Sonndeg_Méindeg_Dënschdeg_Mëttwoch_Donneschdeg_Freideg_Samschdeg".split("_"),weekdaysShort:"So._Mé._Dë._Më._Do._Fr._Sa.".split("_"),weekdaysMin:"So_Mé_Dë_Më_Do_Fr_Sa".split("_"),longDateFormat:{LT:"H:mm [Auer]",L:"DD.MM.YYYY",LL:"D. MMMM YYYY",LLL:"D. MMMM YYYY LT",LLLL:"dddd, D. MMMM YYYY LT"},calendar:{sameDay:"[Haut um] LT",sameElse:"L",nextDay:"[Muer um] LT",nextWeek:"dddd [um] LT",lastDay:"[Gëschter um] LT",lastWeek:function(){switch(this.day()){case 2:case 4:return"[Leschten] dddd [um] LT";default:return"[Leschte] dddd [um] LT"}}},relativeTime:{future:a,past:n,s:"e puer Sekonnen",m:t,mm:"%d Minutten",h:t,hh:"%d Stonnen",d:t,dd:"%d Deeg",M:t,MM:"%d Méint",y:t,yy:"%d Joer"},ordinal:"%d.",week:{dow:1,doy:4}})}),function(e){e(ft)}(function(e){function t(e,t,a,n){return t?"kelios sekundės":n?"kelių sekundžių":"kelias sekundes"}function a(e,t,a,n){return t?_(a)[0]:n?_(a)[1]:_(a)[2]}function n(e){return e%10===0||e>10&&20>e}function _(e){return d[e].split("_")}function s(e,t,s,r){var d=e+" ";return 1===e?d+a(e,t,s[0],r):t?d+(n(e)?_(s)[1]:_(s)[0]):r?d+_(s)[1]:d+(n(e)?_(s)[1]:_(s)[2])}function r(e,t){var a=-1===t.indexOf("dddd HH:mm"),n=i[e.day()];return a?n:n.substring(0,n.length-2)+"į"}var d={m:"minutė_minutės_minutę",mm:"minutės_minučių_minutes",h:"valanda_valandos_valandą",hh:"valandos_valandų_valandas",d:"diena_dienos_dieną",dd:"dienos_dienų_dienas",M:"mėnuo_mėnesio_mėnesį",MM:"mėnesiai_mėnesių_mėnesius",y:"metai_metų_metus",yy:"metai_metų_metus"},i="sekmadienis_pirmadienis_antradienis_trečiadienis_ketvirtadienis_penktadienis_šeštadienis".split("_");return e.defineLocale("lt",{months:"sausio_vasario_kovo_balandžio_gegužės_birželio_liepos_rugpjūčio_rugsėjo_spalio_lapkričio_gruodžio".split("_"),monthsShort:"sau_vas_kov_bal_geg_bir_lie_rgp_rgs_spa_lap_grd".split("_"),weekdays:r,weekdaysShort:"Sek_Pir_Ant_Tre_Ket_Pen_Šeš".split("_"),weekdaysMin:"S_P_A_T_K_Pn_Š".split("_"),longDateFormat:{LT:"HH:mm",L:"YYYY-MM-DD",LL:"YYYY [m.] MMMM D [d.]",LLL:"YYYY [m.] MMMM D [d.], LT [val.]",LLLL:"YYYY [m.] MMMM D [d.], dddd, LT [val.]",l:"YYYY-MM-DD",ll:"YYYY [m.] MMMM D [d.]",lll:"YYYY [m.] MMMM D [d.], LT [val.]",llll:"YYYY [m.] MMMM D [d.], ddd, LT [val.]"},calendar:{sameDay:"[Šiandien] LT",nextDay:"[Rytoj] LT",nextWeek:"dddd LT",lastDay:"[Vakar] LT",lastWeek:"[Praėjusį] dddd LT",sameElse:"L"},relativeTime:{future:"po %s",past:"prieš %s",s:t,m:a,mm:s,h:a,hh:s,d:a,dd:s,M:a,MM:s,y:a,yy:s},ordinal:function(e){return e+"-oji"},week:{dow:1,doy:4}})}),function(e){e(ft)}(function(e){function t(e,t,a){var n=e.split("_");return a?t%10===1&&11!==t?n[2]:n[3]:t%10===1&&11!==t?n[0]:n[1]}function a(e,a,_){return e+" "+t(n[_],e,a)}var n={mm:"minūti_minūtes_minūte_minūtes",hh:"stundu_stundas_stunda_stundas",dd:"dienu_dienas_diena_dienas",MM:"mēnesi_mēnešus_mēnesis_mēneši",yy:"gadu_gadus_gads_gadi"};return e.defineLocale("lv",{months:"janvāris_februāris_marts_aprīlis_maijs_jūnijs_jūlijs_augusts_septembris_oktobris_novembris_decembris".split("_"),monthsShort:"jan_feb_mar_apr_mai_jūn_jūl_aug_sep_okt_nov_dec".split("_"),weekdays:"svētdiena_pirmdiena_otrdiena_trešdiena_ceturtdiena_piektdiena_sestdiena".split("_"),weekdaysShort:"Sv_P_O_T_C_Pk_S".split("_"),weekdaysMin:"Sv_P_O_T_C_Pk_S".split("_"),longDateFormat:{LT:"HH:mm",L:"DD.MM.YYYY",LL:"YYYY. [gada] D. MMMM",LLL:"YYYY. [gada] D. MMMM, LT",LLLL:"YYYY. [gada] D. MMMM, dddd, LT"},calendar:{sameDay:"[Šodien pulksten] LT",nextDay:"[Rīt pulksten] LT",nextWeek:"dddd [pulksten] LT",lastDay:"[Vakar pulksten] LT",lastWeek:"[Pagājušā] dddd [pulksten] LT",sameElse:"L"},relativeTime:{future:"%s vēlāk",past:"%s agrāk",s:"dažas sekundes",m:"minūti",mm:a,h:"stundu",hh:a,d:"dienu",dd:a,M:"mēnesi",MM:a,y:"gadu",yy:a},ordinal:"%d.",week:{dow:1,doy:4}})}),function(e){e(ft)}(function(e){return e.defineLocale("mk",{months:"јануари_февруари_март_април_мај_јуни_јули_август_септември_октомври_ноември_декември".split("_"),monthsShort:"јан_фев_мар_апр_мај_јун_јул_авг_сеп_окт_ное_дек".split("_"),weekdays:"недела_понеделник_вторник_среда_четврток_петок_сабота".split("_"),weekdaysShort:"нед_пон_вто_сре_чет_пет_саб".split("_"),weekdaysMin:"нe_пo_вт_ср_че_пе_сa".split("_"),longDateFormat:{LT:"H:mm",L:"D.MM.YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY LT",LLLL:"dddd, D MMMM YYYY LT"},calendar:{sameDay:"[Денес во] LT",nextDay:"[Утре во] LT",nextWeek:"dddd [во] LT",lastDay:"[Вчера во] LT",lastWeek:function(){switch(this.day()){case 0:case 3:case 6:return"[Во изминатата] dddd [во] LT";case 1:case 2:case 4:case 5:return"[Во изминатиот] dddd [во] LT"}},sameElse:"L"},relativeTime:{future:"после %s",past:"пред %s",s:"неколку секунди",m:"минута",mm:"%d минути",h:"час",hh:"%d часа",d:"ден",dd:"%d дена",M:"месец",MM:"%d месеци",y:"година",yy:"%d години"},ordinal:function(e){var t=e%10,a=e%100;return 0===e?e+"-ев":0===a?e+"-ен":a>10&&20>a?e+"-ти":1===t?e+"-ви":2===t?e+"-ри":7===t||8===t?e+"-ми":e+"-ти"},week:{dow:1,doy:7}})}),function(e){e(ft)}(function(e){return e.defineLocale("ml",{months:"ജനുവരി_ഫെബ്രുവരി_മാർച്ച്_ഏപ്രിൽ_മേയ്_ജൂൺ_ജൂലൈ_ഓഗസ്റ്റ്_സെപ്റ്റംബർ_ഒക്ടോബർ_നവംബർ_ഡിസംബർ".split("_"),monthsShort:"ജനു._ഫെബ്രു._മാർ._ഏപ്രി._മേയ്_ജൂൺ_ജൂലൈ._ഓഗ._സെപ്റ്റ._ഒക്ടോ._നവം._ഡിസം.".split("_"),weekdays:"ഞായറാഴ്ച_തിങ്കളാഴ്ച_ചൊവ്വാഴ്ച_ബുധനാഴ്ച_വ്യാഴാഴ്ച_വെള്ളിയാഴ്ച_ശനിയാഴ്ച".split("_"),weekdaysShort:"ഞായർ_തിങ്കൾ_ചൊവ്വ_ബുധൻ_വ്യാഴം_വെള്ളി_ശനി".split("_"),weekdaysMin:"ഞാ_തി_ചൊ_ബു_വ്യാ_വെ_ശ".split("_"),longDateFormat:{LT:"A h:mm -നു",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY, LT",LLLL:"dddd, D MMMM YYYY, LT"},calendar:{sameDay:"[ഇന്ന്] LT",nextDay:"[നാളെ] LT",nextWeek:"dddd, LT",lastDay:"[ഇന്നലെ] LT",lastWeek:"[കഴിഞ്ഞ] dddd, LT",sameElse:"L"},relativeTime:{future:"%s കഴിഞ്ഞ്",past:"%s മുൻപ്",s:"അൽപ നിമിഷങ്ങൾ",m:"ഒരു മിനിറ്റ്",mm:"%d മിനിറ്റ്",h:"ഒരു മണിക്കൂർ",hh:"%d മണിക്കൂർ",d:"ഒരു ദിവസം",dd:"%d ദിവസം",M:"ഒരു മാസം",MM:"%d മാസം",y:"ഒരു വർഷം",yy:"%d വർഷം"},meridiem:function(e){return 4>e?"രാത്രി":12>e?"രാവിലെ":17>e?"ഉച്ച കഴിഞ്ഞ്":20>e?"വൈകുന്നേരം":"രാത്രി"}})}),function(e){e(ft)}(function(e){var t={1:"१",2:"२",3:"३",4:"४",5:"५",6:"६",7:"७",8:"८",9:"९",0:"०"},a={"१":"1","२":"2","३":"3","४":"4","५":"5","६":"6","७":"7","८":"8","९":"9","०":"0"};return e.defineLocale("mr",{months:"जानेवारी_फेब्रुवारी_मार्च_एप्रिल_मे_जून_जुलै_ऑगस्ट_सप्टेंबर_ऑक्टोबर_नोव्हेंबर_डिसेंबर".split("_"),monthsShort:"जाने._फेब्रु._मार्च._एप्रि._मे._जून._जुलै._ऑग._सप्टें._ऑक्टो._नोव्हें._डिसें.".split("_"),weekdays:"रविवार_सोमवार_मंगळवार_बुधवार_गुरूवार_शुक्रवार_शनिवार".split("_"),weekdaysShort:"रवि_सोम_मंगळ_बुध_गुरू_शुक्र_शनि".split("_"),weekdaysMin:"र_सो_मं_बु_गु_शु_श".split("_"),longDateFormat:{LT:"A h:mm वाजता",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY, LT",LLLL:"dddd, D MMMM YYYY, LT"},calendar:{sameDay:"[आज] LT",nextDay:"[उद्या] LT",nextWeek:"dddd, LT",lastDay:"[काल] LT",lastWeek:"[मागील] dddd, LT",sameElse:"L"},relativeTime:{future:"%s नंतर",past:"%s पूर्वी",s:"सेकंद",m:"एक मिनिट",mm:"%d मिनिटे",h:"एक तास",hh:"%d तास",d:"एक दिवस",dd:"%d दिवस",M:"एक महिना",MM:"%d महिने",y:"एक वर्ष",yy:"%d वर्षे"},preparse:function(e){return e.replace(/[१२३४५६७८९०]/g,function(e){return a[e]})},postformat:function(e){return e.replace(/\d/g,function(e){return t[e]})},meridiem:function(e){return 4>e?"रात्री":10>e?"सकाळी":17>e?"दुपारी":20>e?"सायंकाळी":"रात्री"},week:{dow:0,doy:6}})}),function(e){e(ft)}(function(e){return e.defineLocale("ms-my",{months:"Januari_Februari_Mac_April_Mei_Jun_Julai_Ogos_September_Oktober_November_Disember".split("_"),monthsShort:"Jan_Feb_Mac_Apr_Mei_Jun_Jul_Ogs_Sep_Okt_Nov_Dis".split("_"),weekdays:"Ahad_Isnin_Selasa_Rabu_Khamis_Jumaat_Sabtu".split("_"),weekdaysShort:"Ahd_Isn_Sel_Rab_Kha_Jum_Sab".split("_"),weekdaysMin:"Ah_Is_Sl_Rb_Km_Jm_Sb".split("_"),longDateFormat:{LT:"HH.mm",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY [pukul] LT",LLLL:"dddd, D MMMM YYYY [pukul] LT"},meridiem:function(e){return 11>e?"pagi":15>e?"tengahari":19>e?"petang":"malam"},calendar:{sameDay:"[Hari ini pukul] LT",nextDay:"[Esok pukul] LT",nextWeek:"dddd [pukul] LT",lastDay:"[Kelmarin pukul] LT",lastWeek:"dddd [lepas pukul] LT",sameElse:"L"},relativeTime:{future:"dalam %s",past:"%s yang lepas",s:"beberapa saat",m:"seminit",mm:"%d minit",h:"sejam",hh:"%d jam",d:"sehari",dd:"%d hari",M:"sebulan",MM:"%d bulan",y:"setahun",yy:"%d tahun"},week:{dow:1,doy:7}})}),function(e){e(ft)}(function(e){var t={1:"၁",2:"၂",3:"၃",4:"၄",5:"၅",6:"၆",7:"၇",8:"၈",9:"၉",0:"၀"},a={"၁":"1","၂":"2","၃":"3","၄":"4","၅":"5","၆":"6","၇":"7","၈":"8","၉":"9","၀":"0"};
+return e.defineLocale("my",{months:"ဇန်နဝါရီ_ဖေဖော်ဝါရီ_မတ်_ဧပြီ_မေ_ဇွန်_ဇူလိုင်_သြဂုတ်_စက်တင်ဘာ_အောက်တိုဘာ_နိုဝင်ဘာ_ဒီဇင်ဘာ".split("_"),monthsShort:"ဇန်_ဖေ_မတ်_ပြီ_မေ_ဇွန်_လိုင်_သြ_စက်_အောက်_နို_ဒီ".split("_"),weekdays:"တနင်္ဂနွေ_တနင်္လာ_အင်္ဂါ_ဗုဒ္ဓဟူး_ကြာသပတေး_သောကြာ_စနေ".split("_"),weekdaysShort:"နွေ_လာ_င်္ဂါ_ဟူး_ကြာ_သော_နေ".split("_"),weekdaysMin:"နွေ_လာ_င်္ဂါ_ဟူး_ကြာ_သော_နေ".split("_"),longDateFormat:{LT:"HH:mm",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY LT",LLLL:"dddd D MMMM YYYY LT"},calendar:{sameDay:"[ယနေ.] LT [မှာ]",nextDay:"[မနက်ဖြန်] LT [မှာ]",nextWeek:"dddd LT [မှာ]",lastDay:"[မနေ.က] LT [မှာ]",lastWeek:"[ပြီးခဲ့သော] dddd LT [မှာ]",sameElse:"L"},relativeTime:{future:"လာမည့် %s မှာ",past:"လွန်ခဲ့သော %s က",s:"စက္ကန်.အနည်းငယ်",m:"တစ်မိနစ်",mm:"%d မိနစ်",h:"တစ်နာရီ",hh:"%d နာရီ",d:"တစ်ရက်",dd:"%d ရက်",M:"တစ်လ",MM:"%d လ",y:"တစ်နှစ်",yy:"%d နှစ်"},preparse:function(e){return e.replace(/[၁၂၃၄၅၆၇၈၉၀]/g,function(e){return a[e]})},postformat:function(e){return e.replace(/\d/g,function(e){return t[e]})},week:{dow:1,doy:4}})}),function(e){e(ft)}(function(e){return e.defineLocale("nb",{months:"januar_februar_mars_april_mai_juni_juli_august_september_oktober_november_desember".split("_"),monthsShort:"jan_feb_mar_apr_mai_jun_jul_aug_sep_okt_nov_des".split("_"),weekdays:"søndag_mandag_tirsdag_onsdag_torsdag_fredag_lørdag".split("_"),weekdaysShort:"søn_man_tirs_ons_tors_fre_lør".split("_"),weekdaysMin:"sø_ma_ti_on_to_fr_lø".split("_"),longDateFormat:{LT:"H.mm",L:"DD.MM.YYYY",LL:"D. MMMM YYYY",LLL:"D. MMMM YYYY [kl.] LT",LLLL:"dddd D. MMMM YYYY [kl.] LT"},calendar:{sameDay:"[i dag kl.] LT",nextDay:"[i morgen kl.] LT",nextWeek:"dddd [kl.] LT",lastDay:"[i går kl.] LT",lastWeek:"[forrige] dddd [kl.] LT",sameElse:"L"},relativeTime:{future:"om %s",past:"for %s siden",s:"noen sekunder",m:"ett minutt",mm:"%d minutter",h:"en time",hh:"%d timer",d:"en dag",dd:"%d dager",M:"en måned",MM:"%d måneder",y:"ett år",yy:"%d år"},ordinal:"%d.",week:{dow:1,doy:4}})}),function(e){e(ft)}(function(e){var t={1:"१",2:"२",3:"३",4:"४",5:"५",6:"६",7:"७",8:"८",9:"९",0:"०"},a={"१":"1","२":"2","३":"3","४":"4","५":"5","६":"6","७":"7","८":"8","९":"9","०":"0"};return e.defineLocale("ne",{months:"जनवरी_फेब्रुवरी_मार्च_अप्रिल_मई_जुन_जुलाई_अगष्ट_सेप्टेम्बर_अक्टोबर_नोभेम्बर_डिसेम्बर".split("_"),monthsShort:"जन._फेब्रु._मार्च_अप्रि._मई_जुन_जुलाई._अग._सेप्ट._अक्टो._नोभे._डिसे.".split("_"),weekdays:"आइतबार_सोमबार_मङ्गलबार_बुधबार_बिहिबार_शुक्रबार_शनिबार".split("_"),weekdaysShort:"आइत._सोम._मङ्गल._बुध._बिहि._शुक्र._शनि.".split("_"),weekdaysMin:"आइ._सो._मङ्_बु._बि._शु._श.".split("_"),longDateFormat:{LT:"Aको h:mm बजे",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY, LT",LLLL:"dddd, D MMMM YYYY, LT"},preparse:function(e){return e.replace(/[१२३४५६७८९०]/g,function(e){return a[e]})},postformat:function(e){return e.replace(/\d/g,function(e){return t[e]})},meridiem:function(e){return 3>e?"राती":10>e?"बिहान":15>e?"दिउँसो":18>e?"बेलुका":20>e?"साँझ":"राती"},calendar:{sameDay:"[आज] LT",nextDay:"[भोली] LT",nextWeek:"[आउँदो] dddd[,] LT",lastDay:"[हिजो] LT",lastWeek:"[गएको] dddd[,] LT",sameElse:"L"},relativeTime:{future:"%sमा",past:"%s अगाडी",s:"केही समय",m:"एक मिनेट",mm:"%d मिनेट",h:"एक घण्टा",hh:"%d घण्टा",d:"एक दिन",dd:"%d दिन",M:"एक महिना",MM:"%d महिना",y:"एक बर्ष",yy:"%d बर्ष"},week:{dow:1,doy:7}})}),function(e){e(ft)}(function(e){var t="jan._feb._mrt._apr._mei_jun._jul._aug._sep._okt._nov._dec.".split("_"),a="jan_feb_mrt_apr_mei_jun_jul_aug_sep_okt_nov_dec".split("_");return e.defineLocale("nl",{months:"januari_februari_maart_april_mei_juni_juli_augustus_september_oktober_november_december".split("_"),monthsShort:function(e,n){return/-MMM-/.test(n)?a[e.month()]:t[e.month()]},weekdays:"zondag_maandag_dinsdag_woensdag_donderdag_vrijdag_zaterdag".split("_"),weekdaysShort:"zo._ma._di._wo._do._vr._za.".split("_"),weekdaysMin:"Zo_Ma_Di_Wo_Do_Vr_Za".split("_"),longDateFormat:{LT:"HH:mm",L:"DD-MM-YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY LT",LLLL:"dddd D MMMM YYYY LT"},calendar:{sameDay:"[vandaag om] LT",nextDay:"[morgen om] LT",nextWeek:"dddd [om] LT",lastDay:"[gisteren om] LT",lastWeek:"[afgelopen] dddd [om] LT",sameElse:"L"},relativeTime:{future:"over %s",past:"%s geleden",s:"een paar seconden",m:"één minuut",mm:"%d minuten",h:"één uur",hh:"%d uur",d:"één dag",dd:"%d dagen",M:"één maand",MM:"%d maanden",y:"één jaar",yy:"%d jaar"},ordinal:function(e){return e+(1===e||8===e||e>=20?"ste":"de")},week:{dow:1,doy:4}})}),function(e){e(ft)}(function(e){return e.defineLocale("nn",{months:"januar_februar_mars_april_mai_juni_juli_august_september_oktober_november_desember".split("_"),monthsShort:"jan_feb_mar_apr_mai_jun_jul_aug_sep_okt_nov_des".split("_"),weekdays:"sundag_måndag_tysdag_onsdag_torsdag_fredag_laurdag".split("_"),weekdaysShort:"sun_mån_tys_ons_tor_fre_lau".split("_"),weekdaysMin:"su_må_ty_on_to_fr_lø".split("_"),longDateFormat:{LT:"HH:mm",L:"DD.MM.YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY LT",LLLL:"dddd D MMMM YYYY LT"},calendar:{sameDay:"[I dag klokka] LT",nextDay:"[I morgon klokka] LT",nextWeek:"dddd [klokka] LT",lastDay:"[I går klokka] LT",lastWeek:"[Føregåande] dddd [klokka] LT",sameElse:"L"},relativeTime:{future:"om %s",past:"for %s sidan",s:"nokre sekund",m:"eit minutt",mm:"%d minutt",h:"ein time",hh:"%d timar",d:"ein dag",dd:"%d dagar",M:"ein månad",MM:"%d månader",y:"eit år",yy:"%d år"},ordinal:"%d.",week:{dow:1,doy:4}})}),function(e){e(ft)}(function(e){function t(e){return 5>e%10&&e%10>1&&~~(e/10)%10!==1}function a(e,a,n){var _=e+" ";switch(n){case"m":return a?"minuta":"minutę";case"mm":return _+(t(e)?"minuty":"minut");case"h":return a?"godzina":"godzinę";case"hh":return _+(t(e)?"godziny":"godzin");case"MM":return _+(t(e)?"miesiące":"miesięcy");case"yy":return _+(t(e)?"lata":"lat")}}var n="styczeń_luty_marzec_kwiecień_maj_czerwiec_lipiec_sierpień_wrzesień_październik_listopad_grudzień".split("_"),_="stycznia_lutego_marca_kwietnia_maja_czerwca_lipca_sierpnia_września_października_listopada_grudnia".split("_");return e.defineLocale("pl",{months:function(e,t){return/D MMMM/.test(t)?_[e.month()]:n[e.month()]},monthsShort:"sty_lut_mar_kwi_maj_cze_lip_sie_wrz_paź_lis_gru".split("_"),weekdays:"niedziela_poniedziałek_wtorek_środa_czwartek_piątek_sobota".split("_"),weekdaysShort:"nie_pon_wt_śr_czw_pt_sb".split("_"),weekdaysMin:"N_Pn_Wt_Śr_Cz_Pt_So".split("_"),longDateFormat:{LT:"HH:mm",L:"DD.MM.YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY LT",LLLL:"dddd, D MMMM YYYY LT"},calendar:{sameDay:"[Dziś o] LT",nextDay:"[Jutro o] LT",nextWeek:"[W] dddd [o] LT",lastDay:"[Wczoraj o] LT",lastWeek:function(){switch(this.day()){case 0:return"[W zeszłą niedzielę o] LT";case 3:return"[W zeszłą środę o] LT";case 6:return"[W zeszłą sobotę o] LT";default:return"[W zeszły] dddd [o] LT"}},sameElse:"L"},relativeTime:{future:"za %s",past:"%s temu",s:"kilka sekund",m:a,mm:a,h:a,hh:a,d:"1 dzień",dd:"%d dni",M:"miesiąc",MM:a,y:"rok",yy:a},ordinal:"%d.",week:{dow:1,doy:4}})}),function(e){e(ft)}(function(e){return e.defineLocale("pt-br",{months:"janeiro_fevereiro_março_abril_maio_junho_julho_agosto_setembro_outubro_novembro_dezembro".split("_"),monthsShort:"jan_fev_mar_abr_mai_jun_jul_ago_set_out_nov_dez".split("_"),weekdays:"domingo_segunda-feira_terça-feira_quarta-feira_quinta-feira_sexta-feira_sábado".split("_"),weekdaysShort:"dom_seg_ter_qua_qui_sex_sáb".split("_"),weekdaysMin:"dom_2ª_3ª_4ª_5ª_6ª_sáb".split("_"),longDateFormat:{LT:"HH:mm",L:"DD/MM/YYYY",LL:"D [de] MMMM [de] YYYY",LLL:"D [de] MMMM [de] YYYY [às] LT",LLLL:"dddd, D [de] MMMM [de] YYYY [às] LT"},calendar:{sameDay:"[Hoje às] LT",nextDay:"[Amanhã às] LT",nextWeek:"dddd [às] LT",lastDay:"[Ontem às] LT",lastWeek:function(){return 0===this.day()||6===this.day()?"[Último] dddd [às] LT":"[Última] dddd [às] LT"},sameElse:"L"},relativeTime:{future:"em %s",past:"%s atrás",s:"segundos",m:"um minuto",mm:"%d minutos",h:"uma hora",hh:"%d horas",d:"um dia",dd:"%d dias",M:"um mês",MM:"%d meses",y:"um ano",yy:"%d anos"},ordinal:"%dº"})}),function(e){e(ft)}(function(e){return e.defineLocale("pt",{months:"janeiro_fevereiro_março_abril_maio_junho_julho_agosto_setembro_outubro_novembro_dezembro".split("_"),monthsShort:"jan_fev_mar_abr_mai_jun_jul_ago_set_out_nov_dez".split("_"),weekdays:"domingo_segunda-feira_terça-feira_quarta-feira_quinta-feira_sexta-feira_sábado".split("_"),weekdaysShort:"dom_seg_ter_qua_qui_sex_sáb".split("_"),weekdaysMin:"dom_2ª_3ª_4ª_5ª_6ª_sáb".split("_"),longDateFormat:{LT:"HH:mm",L:"DD/MM/YYYY",LL:"D [de] MMMM [de] YYYY",LLL:"D [de] MMMM [de] YYYY LT",LLLL:"dddd, D [de] MMMM [de] YYYY LT"},calendar:{sameDay:"[Hoje às] LT",nextDay:"[Amanhã às] LT",nextWeek:"dddd [às] LT",lastDay:"[Ontem às] LT",lastWeek:function(){return 0===this.day()||6===this.day()?"[Último] dddd [às] LT":"[Última] dddd [às] LT"},sameElse:"L"},relativeTime:{future:"em %s",past:"há %s",s:"segundos",m:"um minuto",mm:"%d minutos",h:"uma hora",hh:"%d horas",d:"um dia",dd:"%d dias",M:"um mês",MM:"%d meses",y:"um ano",yy:"%d anos"},ordinal:"%dº",week:{dow:1,doy:4}})}),function(e){e(ft)}(function(e){function t(e,t,a){var n={mm:"minute",hh:"ore",dd:"zile",MM:"luni",yy:"ani"},_=" ";return(e%100>=20||e>=100&&e%100===0)&&(_=" de "),e+_+n[a]}return e.defineLocale("ro",{months:"ianuarie_februarie_martie_aprilie_mai_iunie_iulie_august_septembrie_octombrie_noiembrie_decembrie".split("_"),monthsShort:"ian._febr._mart._apr._mai_iun._iul._aug._sept._oct._nov._dec.".split("_"),weekdays:"duminică_luni_marți_miercuri_joi_vineri_sâmbătă".split("_"),weekdaysShort:"Dum_Lun_Mar_Mie_Joi_Vin_Sâm".split("_"),weekdaysMin:"Du_Lu_Ma_Mi_Jo_Vi_Sâ".split("_"),longDateFormat:{LT:"H:mm",L:"DD.MM.YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY H:mm",LLLL:"dddd, D MMMM YYYY H:mm"},calendar:{sameDay:"[azi la] LT",nextDay:"[mâine la] LT",nextWeek:"dddd [la] LT",lastDay:"[ieri la] LT",lastWeek:"[fosta] dddd [la] LT",sameElse:"L"},relativeTime:{future:"peste %s",past:"%s în urmă",s:"câteva secunde",m:"un minut",mm:t,h:"o oră",hh:t,d:"o zi",dd:t,M:"o lună",MM:t,y:"un an",yy:t},week:{dow:1,doy:7}})}),function(e){e(ft)}(function(e){function t(e,t){var a=e.split("_");return t%10===1&&t%100!==11?a[0]:t%10>=2&&4>=t%10&&(10>t%100||t%100>=20)?a[1]:a[2]}function a(e,a,n){var _={mm:a?"минута_минуты_минут":"минуту_минуты_минут",hh:"час_часа_часов",dd:"день_дня_дней",MM:"месяц_месяца_месяцев",yy:"год_года_лет"};return"m"===n?a?"минута":"минуту":e+" "+t(_[n],+e)}function n(e,t){var a={nominative:"январь_февраль_март_апрель_май_июнь_июль_август_сентябрь_октябрь_ноябрь_декабрь".split("_"),accusative:"января_февраля_марта_апреля_мая_июня_июля_августа_сентября_октября_ноября_декабря".split("_")},n=/D[oD]?(\[[^\[\]]*\]|\s+)+MMMM?/.test(t)?"accusative":"nominative";return a[n][e.month()]}function _(e,t){var a={nominative:"янв_фев_мар_апр_май_июнь_июль_авг_сен_окт_ноя_дек".split("_"),accusative:"янв_фев_мар_апр_мая_июня_июля_авг_сен_окт_ноя_дек".split("_")},n=/D[oD]?(\[[^\[\]]*\]|\s+)+MMMM?/.test(t)?"accusative":"nominative";return a[n][e.month()]}function s(e,t){var a={nominative:"воскресенье_понедельник_вторник_среда_четверг_пятница_суббота".split("_"),accusative:"воскресенье_понедельник_вторник_среду_четверг_пятницу_субботу".split("_")},n=/\[ ?[Вв] ?(?:прошлую|следующую)? ?\] ?dddd/.test(t)?"accusative":"nominative";return a[n][e.day()]}return e.defineLocale("ru",{months:n,monthsShort:_,weekdays:s,weekdaysShort:"вс_пн_вт_ср_чт_пт_сб".split("_"),weekdaysMin:"вс_пн_вт_ср_чт_пт_сб".split("_"),monthsParse:[/^янв/i,/^фев/i,/^мар/i,/^апр/i,/^ма[й|я]/i,/^июн/i,/^июл/i,/^авг/i,/^сен/i,/^окт/i,/^ноя/i,/^дек/i],longDateFormat:{LT:"HH:mm",L:"DD.MM.YYYY",LL:"D MMMM YYYY г.",LLL:"D MMMM YYYY г., LT",LLLL:"dddd, D MMMM YYYY г., LT"},calendar:{sameDay:"[Сегодня в] LT",nextDay:"[Завтра в] LT",lastDay:"[Вчера в] LT",nextWeek:function(){return 2===this.day()?"[Во] dddd [в] LT":"[В] dddd [в] LT"},lastWeek:function(){switch(this.day()){case 0:return"[В прошлое] dddd [в] LT";case 1:case 2:case 4:return"[В прошлый] dddd [в] LT";case 3:case 5:case 6:return"[В прошлую] dddd [в] LT"}},sameElse:"L"},relativeTime:{future:"через %s",past:"%s назад",s:"несколько секунд",m:a,mm:a,h:"час",hh:a,d:"день",dd:a,M:"месяц",MM:a,y:"год",yy:a},meridiemParse:/ночи|утра|дня|вечера/i,isPM:function(e){return/^(дня|вечера)$/.test(e)},meridiem:function(e){return 4>e?"ночи":12>e?"утра":17>e?"дня":"вечера"},ordinal:function(e,t){switch(t){case"M":case"d":case"DDD":return e+"-й";case"D":return e+"-го";case"w":case"W":return e+"-я";default:return e}},week:{dow:1,doy:7}})}),function(e){e(ft)}(function(e){function t(e){return e>1&&5>e}function a(e,a,n,_){var s=e+" ";switch(n){case"s":return a||_?"pár sekúnd":"pár sekundami";case"m":return a?"minúta":_?"minútu":"minútou";case"mm":return a||_?s+(t(e)?"minúty":"minút"):s+"minútami";break;case"h":return a?"hodina":_?"hodinu":"hodinou";case"hh":return a||_?s+(t(e)?"hodiny":"hodín"):s+"hodinami";break;case"d":return a||_?"deň":"dňom";case"dd":return a||_?s+(t(e)?"dni":"dní"):s+"dňami";break;case"M":return a||_?"mesiac":"mesiacom";case"MM":return a||_?s+(t(e)?"mesiace":"mesiacov"):s+"mesiacmi";break;case"y":return a||_?"rok":"rokom";case"yy":return a||_?s+(t(e)?"roky":"rokov"):s+"rokmi"}}var n="január_február_marec_apríl_máj_jún_júl_august_september_október_november_december".split("_"),_="jan_feb_mar_apr_máj_jún_júl_aug_sep_okt_nov_dec".split("_");return e.defineLocale("sk",{months:n,monthsShort:_,monthsParse:function(e,t){var a,n=[];for(a=0;12>a;a++)n[a]=new RegExp("^"+e[a]+"$|^"+t[a]+"$","i");return n}(n,_),weekdays:"nedeľa_pondelok_utorok_streda_štvrtok_piatok_sobota".split("_"),weekdaysShort:"ne_po_ut_st_št_pi_so".split("_"),weekdaysMin:"ne_po_ut_st_št_pi_so".split("_"),longDateFormat:{LT:"H:mm",L:"DD.MM.YYYY",LL:"D. MMMM YYYY",LLL:"D. MMMM YYYY LT",LLLL:"dddd D. MMMM YYYY LT"},calendar:{sameDay:"[dnes o] LT",nextDay:"[zajtra o] LT",nextWeek:function(){switch(this.day()){case 0:return"[v nedeľu o] LT";case 1:case 2:return"[v] dddd [o] LT";case 3:return"[v stredu o] LT";case 4:return"[vo štvrtok o] LT";case 5:return"[v piatok o] LT";case 6:return"[v sobotu o] LT"}},lastDay:"[včera o] LT",lastWeek:function(){switch(this.day()){case 0:return"[minulú nedeľu o] LT";case 1:case 2:return"[minulý] dddd [o] LT";case 3:return"[minulú stredu o] LT";case 4:case 5:return"[minulý] dddd [o] LT";case 6:return"[minulú sobotu o] LT"}},sameElse:"L"},relativeTime:{future:"za %s",past:"pred %s",s:a,m:a,mm:a,h:a,hh:a,d:a,dd:a,M:a,MM:a,y:a,yy:a},ordinal:"%d.",week:{dow:1,doy:4}})}),function(e){e(ft)}(function(e){function t(e,t,a){var n=e+" ";switch(a){case"m":return t?"ena minuta":"eno minuto";case"mm":return n+=1===e?"minuta":2===e?"minuti":3===e||4===e?"minute":"minut";case"h":return t?"ena ura":"eno uro";case"hh":return n+=1===e?"ura":2===e?"uri":3===e||4===e?"ure":"ur";case"dd":return n+=1===e?"dan":"dni";case"MM":return n+=1===e?"mesec":2===e?"meseca":3===e||4===e?"mesece":"mesecev";case"yy":return n+=1===e?"leto":2===e?"leti":3===e||4===e?"leta":"let"}}return e.defineLocale("sl",{months:"januar_februar_marec_april_maj_junij_julij_avgust_september_oktober_november_december".split("_"),monthsShort:"jan._feb._mar._apr._maj._jun._jul._avg._sep._okt._nov._dec.".split("_"),weekdays:"nedelja_ponedeljek_torek_sreda_četrtek_petek_sobota".split("_"),weekdaysShort:"ned._pon._tor._sre._čet._pet._sob.".split("_"),weekdaysMin:"ne_po_to_sr_če_pe_so".split("_"),longDateFormat:{LT:"H:mm",L:"DD. MM. YYYY",LL:"D. MMMM YYYY",LLL:"D. MMMM YYYY LT",LLLL:"dddd, D. MMMM YYYY LT"},calendar:{sameDay:"[danes ob] LT",nextDay:"[jutri ob] LT",nextWeek:function(){switch(this.day()){case 0:return"[v] [nedeljo] [ob] LT";case 3:return"[v] [sredo] [ob] LT";case 6:return"[v] [soboto] [ob] LT";case 1:case 2:case 4:case 5:return"[v] dddd [ob] LT"}},lastDay:"[včeraj ob] LT",lastWeek:function(){switch(this.day()){case 0:case 3:case 6:return"[prejšnja] dddd [ob] LT";case 1:case 2:case 4:case 5:return"[prejšnji] dddd [ob] LT"}},sameElse:"L"},relativeTime:{future:"čez %s",past:"%s nazaj",s:"nekaj sekund",m:t,mm:t,h:t,hh:t,d:"en dan",dd:t,M:"en mesec",MM:t,y:"eno leto",yy:t},ordinal:"%d.",week:{dow:1,doy:7}})}),function(e){e(ft)}(function(e){return e.defineLocale("sq",{months:"Janar_Shkurt_Mars_Prill_Maj_Qershor_Korrik_Gusht_Shtator_Tetor_Nëntor_Dhjetor".split("_"),monthsShort:"Jan_Shk_Mar_Pri_Maj_Qer_Kor_Gus_Sht_Tet_Nën_Dhj".split("_"),weekdays:"E Diel_E Hënë_E Martë_E Mërkurë_E Enjte_E Premte_E Shtunë".split("_"),weekdaysShort:"Die_Hën_Mar_Mër_Enj_Pre_Sht".split("_"),weekdaysMin:"D_H_Ma_Më_E_P_Sh".split("_"),meridiem:function(e){return 12>e?"PD":"MD"},longDateFormat:{LT:"HH:mm",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY LT",LLLL:"dddd, D MMMM YYYY LT"},calendar:{sameDay:"[Sot në] LT",nextDay:"[Nesër në] LT",nextWeek:"dddd [në] LT",lastDay:"[Dje në] LT",lastWeek:"dddd [e kaluar në] LT",sameElse:"L"},relativeTime:{future:"në %s",past:"%s më parë",s:"disa sekonda",m:"një minutë",mm:"%d minuta",h:"një orë",hh:"%d orë",d:"një ditë",dd:"%d ditë",M:"një muaj",MM:"%d muaj",y:"një vit",yy:"%d vite"},ordinal:"%d.",week:{dow:1,doy:4}})}),function(e){e(ft)}(function(e){var t={words:{m:["један минут","једне минуте"],mm:["минут","минуте","минута"],h:["један сат","једног сата"],hh:["сат","сата","сати"],dd:["дан","дана","дана"],MM:["месец","месеца","месеци"],yy:["година","године","година"]},correctGrammaticalCase:function(e,t){return 1===e?t[0]:e>=2&&4>=e?t[1]:t[2]},translate:function(e,a,n){var _=t.words[n];return 1===n.length?a?_[0]:_[1]:e+" "+t.correctGrammaticalCase(e,_)}};return e.defineLocale("sr-cyrl",{months:["јануар","фебруар","март","април","мај","јун","јул","август","септембар","октобар","новембар","децембар"],monthsShort:["јан.","феб.","мар.","апр.","мај","јун","јул","авг.","сеп.","окт.","нов.","дец."],weekdays:["недеља","понедељак","уторак","среда","четвртак","петак","субота"],weekdaysShort:["нед.","пон.","уто.","сре.","чет.","пет.","суб."],weekdaysMin:["не","по","ут","ср","че","пе","су"],longDateFormat:{LT:"H:mm",L:"DD. MM. YYYY",LL:"D. MMMM YYYY",LLL:"D. MMMM YYYY LT",LLLL:"dddd, D. MMMM YYYY LT"},calendar:{sameDay:"[данас у] LT",nextDay:"[сутра у] LT",nextWeek:function(){switch(this.day()){case 0:return"[у] [недељу] [у] LT";case 3:return"[у] [среду] [у] LT";case 6:return"[у] [суботу] [у] LT";case 1:case 2:case 4:case 5:return"[у] dddd [у] LT"}},lastDay:"[јуче у] LT",lastWeek:function(){var e=["[прошле] [недеље] [у] LT","[прошлог] [понедељка] [у] LT","[прошлог] [уторка] [у] LT","[прошле] [среде] [у] LT","[прошлог] [четвртка] [у] LT","[прошлог] [петка] [у] LT","[прошле] [суботе] [у] LT"];return e[this.day()]},sameElse:"L"},relativeTime:{future:"за %s",past:"пре %s",s:"неколико секунди",m:t.translate,mm:t.translate,h:t.translate,hh:t.translate,d:"дан",dd:t.translate,M:"месец",MM:t.translate,y:"годину",yy:t.translate},ordinal:"%d.",week:{dow:1,doy:7}})}),function(e){e(ft)}(function(e){var t={words:{m:["jedan minut","jedne minute"],mm:["minut","minute","minuta"],h:["jedan sat","jednog sata"],hh:["sat","sata","sati"],dd:["dan","dana","dana"],MM:["mesec","meseca","meseci"],yy:["godina","godine","godina"]},correctGrammaticalCase:function(e,t){return 1===e?t[0]:e>=2&&4>=e?t[1]:t[2]},translate:function(e,a,n){var _=t.words[n];return 1===n.length?a?_[0]:_[1]:e+" "+t.correctGrammaticalCase(e,_)}};return e.defineLocale("sr",{months:["januar","februar","mart","april","maj","jun","jul","avgust","septembar","oktobar","novembar","decembar"],monthsShort:["jan.","feb.","mar.","apr.","maj","jun","jul","avg.","sep.","okt.","nov.","dec."],weekdays:["nedelja","ponedeljak","utorak","sreda","četvrtak","petak","subota"],weekdaysShort:["ned.","pon.","uto.","sre.","čet.","pet.","sub."],weekdaysMin:["ne","po","ut","sr","če","pe","su"],longDateFormat:{LT:"H:mm",L:"DD. MM. YYYY",LL:"D. MMMM YYYY",LLL:"D. MMMM YYYY LT",LLLL:"dddd, D. MMMM YYYY LT"},calendar:{sameDay:"[danas u] LT",nextDay:"[sutra u] LT",nextWeek:function(){switch(this.day()){case 0:return"[u] [nedelju] [u] LT";case 3:return"[u] [sredu] [u] LT";case 6:return"[u] [subotu] [u] LT";case 1:case 2:case 4:case 5:return"[u] dddd [u] LT"}},lastDay:"[juče u] LT",lastWeek:function(){var e=["[prošle] [nedelje] [u] LT","[prošlog] [ponedeljka] [u] LT","[prošlog] [utorka] [u] LT","[prošle] [srede] [u] LT","[prošlog] [četvrtka] [u] LT","[prošlog] [petka] [u] LT","[prošle] [subote] [u] LT"];return e[this.day()]},sameElse:"L"},relativeTime:{future:"za %s",past:"pre %s",s:"nekoliko sekundi",m:t.translate,mm:t.translate,h:t.translate,hh:t.translate,d:"dan",dd:t.translate,M:"mesec",MM:t.translate,y:"godinu",yy:t.translate},ordinal:"%d.",week:{dow:1,doy:7}})}),function(e){e(ft)}(function(e){return e.defineLocale("sv",{months:"januari_februari_mars_april_maj_juni_juli_augusti_september_oktober_november_december".split("_"),monthsShort:"jan_feb_mar_apr_maj_jun_jul_aug_sep_okt_nov_dec".split("_"),weekdays:"söndag_måndag_tisdag_onsdag_torsdag_fredag_lördag".split("_"),weekdaysShort:"sön_mån_tis_ons_tor_fre_lör".split("_"),weekdaysMin:"sö_må_ti_on_to_fr_lö".split("_"),longDateFormat:{LT:"HH:mm",L:"YYYY-MM-DD",LL:"D MMMM YYYY",LLL:"D MMMM YYYY LT",LLLL:"dddd D MMMM YYYY LT"},calendar:{sameDay:"[Idag] LT",nextDay:"[Imorgon] LT",lastDay:"[Igår] LT",nextWeek:"dddd LT",lastWeek:"[Förra] dddd[en] LT",sameElse:"L"},relativeTime:{future:"om %s",past:"för %s sedan",s:"några sekunder",m:"en minut",mm:"%d minuter",h:"en timme",hh:"%d timmar",d:"en dag",dd:"%d dagar",M:"en månad",MM:"%d månader",y:"ett år",yy:"%d år"},ordinal:function(e){var t=e%10,a=1===~~(e%100/10)?"e":1===t?"a":2===t?"a":3===t?"e":"e";return e+a},week:{dow:1,doy:4}})}),function(e){e(ft)}(function(e){return e.defineLocale("ta",{months:"ஜனவரி_பிப்ரவரி_மார்ச்_ஏப்ரல்_மே_ஜூன்_ஜூலை_ஆகஸ்ட்_செப்டெம்பர்_அக்டோபர்_நவம்பர்_டிசம்பர்".split("_"),monthsShort:"ஜனவரி_பிப்ரவரி_மார்ச்_ஏப்ரல்_மே_ஜூன்_ஜூலை_ஆகஸ்ட்_செப்டெம்பர்_அக்டோபர்_நவம்பர்_டிசம்பர்".split("_"),weekdays:"ஞாயிற்றுக்கிழமை_திங்கட்கிழமை_செவ்வாய்கிழமை_புதன்கிழமை_வியாழக்கிழமை_வெள்ளிக்கிழமை_சனிக்கிழமை".split("_"),weekdaysShort:"ஞாயிறு_திங்கள்_செவ்வாய்_புதன்_வியாழன்_வெள்ளி_சனி".split("_"),weekdaysMin:"ஞா_தி_செ_பு_வி_வெ_ச".split("_"),longDateFormat:{LT:"HH:mm",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY, LT",LLLL:"dddd, D MMMM YYYY, LT"},calendar:{sameDay:"[இன்று] LT",nextDay:"[நாளை] LT",nextWeek:"dddd, LT",lastDay:"[நேற்று] LT",lastWeek:"[கடந்த வாரம்] dddd, LT",sameElse:"L"},relativeTime:{future:"%s இல்",past:"%s முன்",s:"ஒரு சில விநாடிகள்",m:"ஒரு நிமிடம்",mm:"%d நிமிடங்கள்",h:"ஒரு மணி நேரம்",hh:"%d மணி நேரம்",d:"ஒரு நாள்",dd:"%d நாட்கள்",M:"ஒரு மாதம்",MM:"%d மாதங்கள்",y:"ஒரு வருடம்",yy:"%d ஆண்டுகள்"},ordinal:function(e){return e+"வது"},meridiem:function(e){return e>=6&&10>=e?" காலை":e>=10&&14>=e?" நண்பகல்":e>=14&&18>=e?" எற்பாடு":e>=18&&20>=e?" மாலை":e>=20&&24>=e?" இரவு":e>=0&&6>=e?" வைகறை":void 0},week:{dow:0,doy:6}})}),function(e){e(ft)}(function(e){return e.defineLocale("th",{months:"มกราคม_กุมภาพันธ์_มีนาคม_เมษายน_พฤษภาคม_มิถุนายน_กรกฎาคม_สิงหาคม_กันยายน_ตุลาคม_พฤศจิกายน_ธันวาคม".split("_"),monthsShort:"มกรา_กุมภา_มีนา_เมษา_พฤษภา_มิถุนา_กรกฎา_สิงหา_กันยา_ตุลา_พฤศจิกา_ธันวา".split("_"),weekdays:"อาทิตย์_จันทร์_อังคาร_พุธ_พฤหัสบดี_ศุกร์_เสาร์".split("_"),weekdaysShort:"อาทิตย์_จันทร์_อังคาร_พุธ_พฤหัส_ศุกร์_เสาร์".split("_"),weekdaysMin:"อา._จ._อ._พ._พฤ._ศ._ส.".split("_"),longDateFormat:{LT:"H นาฬิกา m นาที",L:"YYYY/MM/DD",LL:"D MMMM YYYY",LLL:"D MMMM YYYY เวลา LT",LLLL:"วันddddที่ D MMMM YYYY เวลา LT"},meridiem:function(e){return 12>e?"ก่อนเที่ยง":"หลังเที่ยง"},calendar:{sameDay:"[วันนี้ เวลา] LT",nextDay:"[พรุ่งนี้ เวลา] LT",nextWeek:"dddd[หน้า เวลา] LT",lastDay:"[เมื่อวานนี้ เวลา] LT",lastWeek:"[วัน]dddd[ที่แล้ว เวลา] LT",sameElse:"L"},relativeTime:{future:"อีก %s",past:"%sที่แล้ว",s:"ไม่กี่วินาที",m:"1 นาที",mm:"%d นาที",h:"1 ชั่วโมง",hh:"%d ชั่วโมง",d:"1 วัน",dd:"%d วัน",M:"1 เดือน",MM:"%d เดือน",y:"1 ปี",yy:"%d ปี"}})}),function(e){e(ft)}(function(e){return e.defineLocale("tl-ph",{months:"Enero_Pebrero_Marso_Abril_Mayo_Hunyo_Hulyo_Agosto_Setyembre_Oktubre_Nobyembre_Disyembre".split("_"),monthsShort:"Ene_Peb_Mar_Abr_May_Hun_Hul_Ago_Set_Okt_Nob_Dis".split("_"),weekdays:"Linggo_Lunes_Martes_Miyerkules_Huwebes_Biyernes_Sabado".split("_"),weekdaysShort:"Lin_Lun_Mar_Miy_Huw_Biy_Sab".split("_"),weekdaysMin:"Li_Lu_Ma_Mi_Hu_Bi_Sab".split("_"),longDateFormat:{LT:"HH:mm",L:"MM/D/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY LT",LLLL:"dddd, MMMM DD, YYYY LT"},calendar:{sameDay:"[Ngayon sa] LT",nextDay:"[Bukas sa] LT",nextWeek:"dddd [sa] LT",lastDay:"[Kahapon sa] LT",lastWeek:"dddd [huling linggo] LT",sameElse:"L"},relativeTime:{future:"sa loob ng %s",past:"%s ang nakalipas",s:"ilang segundo",m:"isang minuto",mm:"%d minuto",h:"isang oras",hh:"%d oras",d:"isang araw",dd:"%d araw",M:"isang buwan",MM:"%d buwan",y:"isang taon",yy:"%d taon"},ordinal:function(e){return e},week:{dow:1,doy:4}})}),function(e){e(ft)}(function(e){var t={1:"'inci",5:"'inci",8:"'inci",70:"'inci",80:"'inci",2:"'nci",7:"'nci",20:"'nci",50:"'nci",3:"'üncü",4:"'üncü",100:"'üncü",6:"'ncı",9:"'uncu",10:"'uncu",30:"'uncu",60:"'ıncı",90:"'ıncı"};return e.defineLocale("tr",{months:"Ocak_Şubat_Mart_Nisan_Mayıs_Haziran_Temmuz_Ağustos_Eylül_Ekim_Kasım_Aralık".split("_"),monthsShort:"Oca_Şub_Mar_Nis_May_Haz_Tem_Ağu_Eyl_Eki_Kas_Ara".split("_"),weekdays:"Pazar_Pazartesi_Salı_Çarşamba_Perşembe_Cuma_Cumartesi".split("_"),weekdaysShort:"Paz_Pts_Sal_Çar_Per_Cum_Cts".split("_"),weekdaysMin:"Pz_Pt_Sa_Ça_Pe_Cu_Ct".split("_"),longDateFormat:{LT:"HH:mm",L:"DD.MM.YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY LT",LLLL:"dddd, D MMMM YYYY LT"},calendar:{sameDay:"[bugün saat] LT",nextDay:"[yarın saat] LT",nextWeek:"[haftaya] dddd [saat] LT",lastDay:"[dün] LT",lastWeek:"[geçen hafta] dddd [saat] LT",sameElse:"L"},relativeTime:{future:"%s sonra",past:"%s önce",s:"birkaç saniye",m:"bir dakika",mm:"%d dakika",h:"bir saat",hh:"%d saat",d:"bir gün",dd:"%d gün",M:"bir ay",MM:"%d ay",y:"bir yıl",yy:"%d yıl"},ordinal:function(e){if(0===e)return e+"'ıncı";var a=e%10,n=e%100-a,_=e>=100?100:null;return e+(t[a]||t[n]||t[_])},week:{dow:1,doy:7}})}),function(e){e(ft)}(function(e){return e.defineLocale("tzm-latn",{months:"innayr_brˤayrˤ_marˤsˤ_ibrir_mayyw_ywnyw_ywlywz_ɣwšt_šwtanbir_ktˤwbrˤ_nwwanbir_dwjnbir".split("_"),monthsShort:"innayr_brˤayrˤ_marˤsˤ_ibrir_mayyw_ywnyw_ywlywz_ɣwšt_šwtanbir_ktˤwbrˤ_nwwanbir_dwjnbir".split("_"),weekdays:"asamas_aynas_asinas_akras_akwas_asimwas_asiḍyas".split("_"),weekdaysShort:"asamas_aynas_asinas_akras_akwas_asimwas_asiḍyas".split("_"),weekdaysMin:"asamas_aynas_asinas_akras_akwas_asimwas_asiḍyas".split("_"),longDateFormat:{LT:"HH:mm",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY LT",LLLL:"dddd D MMMM YYYY LT"},calendar:{sameDay:"[asdkh g] LT",nextDay:"[aska g] LT",nextWeek:"dddd [g] LT",lastDay:"[assant g] LT",lastWeek:"dddd [g] LT",sameElse:"L"},relativeTime:{future:"dadkh s yan %s",past:"yan %s",s:"imik",m:"minuḍ",mm:"%d minuḍ",h:"saɛa",hh:"%d tassaɛin",d:"ass",dd:"%d ossan",M:"ayowr",MM:"%d iyyirn",y:"asgas",yy:"%d isgasn"},week:{dow:6,doy:12}})}),function(e){e(ft)}(function(e){return e.defineLocale("tzm",{months:"ⵉⵏⵏⴰⵢⵔ_ⴱⵕⴰⵢⵕ_ⵎⴰⵕⵚ_ⵉⴱⵔⵉⵔ_ⵎⴰⵢⵢⵓ_ⵢⵓⵏⵢⵓ_ⵢⵓⵍⵢⵓⵣ_ⵖⵓⵛⵜ_ⵛⵓⵜⴰⵏⴱⵉⵔ_ⴽⵟⵓⴱⵕ_ⵏⵓⵡⴰⵏⴱⵉⵔ_ⴷⵓⵊⵏⴱⵉⵔ".split("_"),monthsShort:"ⵉⵏⵏⴰⵢⵔ_ⴱⵕⴰⵢⵕ_ⵎⴰⵕⵚ_ⵉⴱⵔⵉⵔ_ⵎⴰⵢⵢⵓ_ⵢⵓⵏⵢⵓ_ⵢⵓⵍⵢⵓⵣ_ⵖⵓⵛⵜ_ⵛⵓⵜⴰⵏⴱⵉⵔ_ⴽⵟⵓⴱⵕ_ⵏⵓⵡⴰⵏⴱⵉⵔ_ⴷⵓⵊⵏⴱⵉⵔ".split("_"),weekdays:"ⴰⵙⴰⵎⴰⵙ_ⴰⵢⵏⴰⵙ_ⴰⵙⵉⵏⴰⵙ_ⴰⴽⵔⴰⵙ_ⴰⴽⵡⴰⵙ_ⴰⵙⵉⵎⵡⴰⵙ_ⴰⵙⵉⴹⵢⴰⵙ".split("_"),weekdaysShort:"ⴰⵙⴰⵎⴰⵙ_ⴰⵢⵏⴰⵙ_ⴰⵙⵉⵏⴰⵙ_ⴰⴽⵔⴰⵙ_ⴰⴽⵡⴰⵙ_ⴰⵙⵉⵎⵡⴰⵙ_ⴰⵙⵉⴹⵢⴰⵙ".split("_"),weekdaysMin:"ⴰⵙⴰⵎⴰⵙ_ⴰⵢⵏⴰⵙ_ⴰⵙⵉⵏⴰⵙ_ⴰⴽⵔⴰⵙ_ⴰⴽⵡⴰⵙ_ⴰⵙⵉⵎⵡⴰⵙ_ⴰⵙⵉⴹⵢⴰⵙ".split("_"),longDateFormat:{LT:"HH:mm",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY LT",LLLL:"dddd D MMMM YYYY LT"},calendar:{sameDay:"[ⴰⵙⴷⵅ ⴴ] LT",nextDay:"[ⴰⵙⴽⴰ ⴴ] LT",nextWeek:"dddd [ⴴ] LT",lastDay:"[ⴰⵚⴰⵏⵜ ⴴ] LT",lastWeek:"dddd [ⴴ] LT",sameElse:"L"},relativeTime:{future:"ⴷⴰⴷⵅ ⵙ ⵢⴰⵏ %s",past:"ⵢⴰⵏ %s",s:"ⵉⵎⵉⴽ",m:"ⵎⵉⵏⵓⴺ",mm:"%d ⵎⵉⵏⵓⴺ",h:"ⵙⴰⵄⴰ",hh:"%d ⵜⴰⵙⵙⴰⵄⵉⵏ",d:"ⴰⵙⵙ",dd:"%d oⵙⵙⴰⵏ",M:"ⴰⵢoⵓⵔ",MM:"%d ⵉⵢⵢⵉⵔⵏ",y:"ⴰⵙⴳⴰⵙ",yy:"%d ⵉⵙⴳⴰⵙⵏ"},week:{dow:6,doy:12}})}),function(e){e(ft)}(function(e){function t(e,t){var a=e.split("_");return t%10===1&&t%100!==11?a[0]:t%10>=2&&4>=t%10&&(10>t%100||t%100>=20)?a[1]:a[2]}function a(e,a,n){var _={mm:"хвилина_хвилини_хвилин",hh:"година_години_годин",dd:"день_дні_днів",MM:"місяць_місяці_місяців",yy:"рік_роки_років"};return"m"===n?a?"хвилина":"хвилину":"h"===n?a?"година":"годину":e+" "+t(_[n],+e)}function n(e,t){var a={nominative:"січень_лютий_березень_квітень_травень_червень_липень_серпень_вересень_жовтень_листопад_грудень".split("_"),accusative:"січня_лютого_березня_квітня_травня_червня_липня_серпня_вересня_жовтня_листопада_грудня".split("_")},n=/D[oD]? *MMMM?/.test(t)?"accusative":"nominative";return a[n][e.month()]}function _(e,t){var a={nominative:"неділя_понеділок_вівторок_середа_четвер_п’ятниця_субота".split("_"),accusative:"неділю_понеділок_вівторок_середу_четвер_п’ятницю_суботу".split("_"),genitive:"неділі_понеділка_вівторка_середи_четверга_п’ятниці_суботи".split("_")},n=/(\[[ВвУу]\]) ?dddd/.test(t)?"accusative":/\[?(?:минулої|наступної)? ?\] ?dddd/.test(t)?"genitive":"nominative";return a[n][e.day()]}function s(e){return function(){return e+"о"+(11===this.hours()?"б":"")+"] LT"}}return e.defineLocale("uk",{months:n,monthsShort:"січ_лют_бер_квіт_трав_черв_лип_серп_вер_жовт_лист_груд".split("_"),weekdays:_,weekdaysShort:"нд_пн_вт_ср_чт_пт_сб".split("_"),weekdaysMin:"нд_пн_вт_ср_чт_пт_сб".split("_"),longDateFormat:{LT:"HH:mm",L:"DD.MM.YYYY",LL:"D MMMM YYYY р.",LLL:"D MMMM YYYY р., LT",LLLL:"dddd, D MMMM YYYY р., LT"},calendar:{sameDay:s("[Сьогодні "),nextDay:s("[Завтра "),lastDay:s("[Вчора "),nextWeek:s("[У] dddd ["),lastWeek:function(){switch(this.day()){case 0:case 3:case 5:case 6:return s("[Минулої] dddd [").call(this);case 1:case 2:case 4:return s("[Минулого] dddd [").call(this)}},sameElse:"L"},relativeTime:{future:"за %s",past:"%s тому",s:"декілька секунд",m:a,mm:a,h:"годину",hh:a,d:"день",dd:a,M:"місяць",MM:a,y:"рік",yy:a},meridiem:function(e){return 4>e?"ночі":12>e?"ранку":17>e?"дня":"вечора"},ordinal:function(e,t){switch(t){case"M":case"d":case"DDD":case"w":case"W":return e+"-й";case"D":return e+"-го";default:return e}},week:{dow:1,doy:7}})}),function(e){e(ft)}(function(e){return e.defineLocale("uz",{months:"январь_февраль_март_апрель_май_июнь_июль_август_сентябрь_октябрь_ноябрь_декабрь".split("_"),monthsShort:"янв_фев_мар_апр_май_июн_июл_авг_сен_окт_ноя_дек".split("_"),weekdays:"Якшанба_Душанба_Сешанба_Чоршанба_Пайшанба_Жума_Шанба".split("_"),weekdaysShort:"Якш_Душ_Сеш_Чор_Пай_Жум_Шан".split("_"),weekdaysMin:"Як_Ду_Се_Чо_Па_Жу_Ша".split("_"),longDateFormat:{LT:"HH:mm",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY LT",LLLL:"D MMMM YYYY, dddd LT"},calendar:{sameDay:"[Бугун соат] LT [да]",nextDay:"[Эртага] LT [да]",nextWeek:"dddd [куни соат] LT [да]",lastDay:"[Кеча соат] LT [да]",lastWeek:"[Утган] dddd [куни соат] LT [да]",sameElse:"L"},relativeTime:{future:"Якин %s ичида",past:"Бир неча %s олдин",s:"фурсат",m:"бир дакика",mm:"%d дакика",h:"бир соат",hh:"%d соат",d:"бир кун",dd:"%d кун",M:"бир ой",MM:"%d ой",y:"бир йил",yy:"%d йил"},week:{dow:1,doy:7}})}),function(e){e(ft)}(function(e){return e.defineLocale("vi",{months:"tháng 1_tháng 2_tháng 3_tháng 4_tháng 5_tháng 6_tháng 7_tháng 8_tháng 9_tháng 10_tháng 11_tháng 12".split("_"),monthsShort:"Th01_Th02_Th03_Th04_Th05_Th06_Th07_Th08_Th09_Th10_Th11_Th12".split("_"),weekdays:"chủ nhật_thứ hai_thứ ba_thứ tư_thứ năm_thứ sáu_thứ bảy".split("_"),weekdaysShort:"CN_T2_T3_T4_T5_T6_T7".split("_"),weekdaysMin:"CN_T2_T3_T4_T5_T6_T7".split("_"),longDateFormat:{LT:"HH:mm",L:"DD/MM/YYYY",LL:"D MMMM [năm] YYYY",LLL:"D MMMM [năm] YYYY LT",LLLL:"dddd, D MMMM [năm] YYYY LT",l:"DD/M/YYYY",ll:"D MMM YYYY",lll:"D MMM YYYY LT",llll:"ddd, D MMM YYYY LT"},calendar:{sameDay:"[Hôm nay lúc] LT",nextDay:"[Ngày mai lúc] LT",nextWeek:"dddd [tuần tới lúc] LT",lastDay:"[Hôm qua lúc] LT",lastWeek:"dddd [tuần rồi lúc] LT",sameElse:"L"},relativeTime:{future:"%s tới",past:"%s trước",s:"vài giây",m:"một phút",mm:"%d phút",h:"một giờ",hh:"%d giờ",d:"một ngày",dd:"%d ngày",M:"một tháng",MM:"%d tháng",y:"một năm",yy:"%d năm"},ordinal:function(e){return e},week:{dow:1,doy:4}})}),function(e){e(ft)}(function(e){return e.defineLocale("zh-cn",{months:"一月_二月_三月_四月_五月_六月_七月_八月_九月_十月_十一月_十二月".split("_"),monthsShort:"1月_2月_3月_4月_5月_6月_7月_8月_9月_10月_11月_12月".split("_"),weekdays:"星期日_星期一_星期二_星期三_星期四_星期五_星期六".split("_"),weekdaysShort:"周日_周一_周二_周三_周四_周五_周六".split("_"),weekdaysMin:"日_一_二_三_四_五_六".split("_"),longDateFormat:{LT:"Ah点mm",L:"YYYY-MM-DD",LL:"YYYY年MMMD日",LLL:"YYYY年MMMD日LT",LLLL:"YYYY年MMMD日ddddLT",l:"YYYY-MM-DD",ll:"YYYY年MMMD日",lll:"YYYY年MMMD日LT",llll:"YYYY年MMMD日ddddLT"},meridiem:function(e,t){var a=100*e+t;
+return 600>a?"凌晨":900>a?"早上":1130>a?"上午":1230>a?"中午":1800>a?"下午":"晚上"},calendar:{sameDay:function(){return 0===this.minutes()?"[今天]Ah[点整]":"[今天]LT"},nextDay:function(){return 0===this.minutes()?"[明天]Ah[点整]":"[明天]LT"},lastDay:function(){return 0===this.minutes()?"[昨天]Ah[点整]":"[昨天]LT"},nextWeek:function(){var t,a;return t=e().startOf("week"),a=this.unix()-t.unix()>=604800?"[下]":"[本]",0===this.minutes()?a+"dddAh点整":a+"dddAh点mm"},lastWeek:function(){var t,a;return t=e().startOf("week"),a=this.unix()<t.unix()?"[上]":"[本]",0===this.minutes()?a+"dddAh点整":a+"dddAh点mm"},sameElse:"LL"},ordinal:function(e,t){switch(t){case"d":case"D":case"DDD":return e+"日";case"M":return e+"月";case"w":case"W":return e+"周";default:return e}},relativeTime:{future:"%s内",past:"%s前",s:"几秒",m:"1分钟",mm:"%d分钟",h:"1小时",hh:"%d小时",d:"1天",dd:"%d天",M:"1个月",MM:"%d个月",y:"1年",yy:"%d年"},week:{dow:1,doy:4}})}),function(e){e(ft)}(function(e){return e.defineLocale("zh-tw",{months:"一月_二月_三月_四月_五月_六月_七月_八月_九月_十月_十一月_十二月".split("_"),monthsShort:"1月_2月_3月_4月_5月_6月_7月_8月_9月_10月_11月_12月".split("_"),weekdays:"星期日_星期一_星期二_星期三_星期四_星期五_星期六".split("_"),weekdaysShort:"週日_週一_週二_週三_週四_週五_週六".split("_"),weekdaysMin:"日_一_二_三_四_五_六".split("_"),longDateFormat:{LT:"Ah點mm",L:"YYYY年MMMD日",LL:"YYYY年MMMD日",LLL:"YYYY年MMMD日LT",LLLL:"YYYY年MMMD日ddddLT",l:"YYYY年MMMD日",ll:"YYYY年MMMD日",lll:"YYYY年MMMD日LT",llll:"YYYY年MMMD日ddddLT"},meridiem:function(e,t){var a=100*e+t;return 900>a?"早上":1130>a?"上午":1230>a?"中午":1800>a?"下午":"晚上"},calendar:{sameDay:"[今天]LT",nextDay:"[明天]LT",nextWeek:"[下]ddddLT",lastDay:"[昨天]LT",lastWeek:"[上]ddddLT",sameElse:"L"},ordinal:function(e,t){switch(t){case"d":case"D":case"DDD":return e+"日";case"M":return e+"月";case"w":case"W":return e+"週";default:return e}},relativeTime:{future:"%s內",past:"%s前",s:"幾秒",m:"一分鐘",mm:"%d分鐘",h:"一小時",hh:"%d小時",d:"一天",dd:"%d天",M:"一個月",MM:"%d個月",y:"一年",yy:"%d年"}})}),ft.locale("en"),Et?module.exports=ft:"function"==typeof define&&define.amd?(define("moment",function(e,t,a){return a.config&&a.config()&&a.config().noGlobal===!0&&(Tt.moment=pt),ft}),yt(!0)):yt()}).call(this)}).call(this),function(){"undefined"!=typeof Package&&(a=this.moment)}.call(this),"undefined"==typeof Package&&(Package={}),Package["jeeeyul:moment-with-langs"]={moment:a}}();
+
+!function(){var e=Package.meteor.Meteor;"undefined"==typeof Package&&(Package={}),Package.coffeescript={}}();
+
+!function(){var e=Package.meteor.Meteor,t=Package.underscore._,a=Package.tracker.Tracker,i=Package.tracker.Deps,n=Package.ejson.EJSON,r;(function(){var e=function(e){return void 0===e?"undefined":n.stringify(e)},i=function(e){return void 0===e||"undefined"===e?void 0:n.parse(e)};r=function(e){if(e)if("string"==typeof e)r._registerDictForMigrate(e,this),this.keys=r._loadMigratedDict(e)||{};else{if("object"!=typeof e)throw new Error("Invalid ReactiveDict argument: "+e);this.keys=e}else this.keys={};this.keyDeps={},this.keyValueDeps={}},t.extend(r.prototype,{set:function(a,i){var n=this;i=e(i);var r="undefined";if(t.has(n.keys,a)&&(r=n.keys[a]),i!==r){n.keys[a]=i;var s=function(e){e&&e.changed()};s(n.keyDeps[a]),n.keyValueDeps[a]&&(s(n.keyValueDeps[a][r]),s(n.keyValueDeps[a][i]))}},setDefault:function(e,t){var a=this;void 0===a.keys[e]&&a.set(e,t)},get:function(e){var t=this;return t._ensureKey(e),t.keyDeps[e].depend(),i(t.keys[e])},equals:function(r,s){var c=this,o=null;if("undefined"!=typeof Mongo&&(o=Mongo.ObjectID),!("string"==typeof s||"number"==typeof s||"boolean"==typeof s||"undefined"==typeof s||s instanceof Date||o&&s instanceof o||null===s))throw new Error("ReactiveDict.equals: value must be scalar");var u=e(s);if(a.active){c._ensureKey(r),t.has(c.keyValueDeps[r],u)||(c.keyValueDeps[r][u]=new a.Dependency);var d=c.keyValueDeps[r][u].depend();d&&a.onInvalidate(function(){c.keyValueDeps[r][u].hasDependents()||delete c.keyValueDeps[r][u]})}var f=void 0;return t.has(c.keys,r)&&(f=i(c.keys[r])),n.equals(f,s)},_ensureKey:function(e){var t=this;e in t.keyDeps||(t.keyDeps[e]=new a.Dependency,t.keyValueDeps[e]={})},_getMigrationData:function(){return this.keys}})}).call(this),function(){if(r._migratedDictData={},r._dictsToMigrate={},r._loadMigratedDict=function(e){return t.has(r._migratedDictData,e)?r._migratedDictData[e]:null},r._registerDictForMigrate=function(e,a){if(t.has(r._dictsToMigrate,e))throw new Error("Duplicate ReactiveDict name: "+e);r._dictsToMigrate[e]=a},e.isClient&&Package.reload){var a=Package.reload.Reload._migrationData("reactive-dict");a&&a.dicts&&(r._migratedDictData=a.dicts),Package.reload.Reload._onMigrate("reactive-dict",function(){var e=r._dictsToMigrate,t={};for(var a in e)t[a]=e[a]._getMigrationData();return[!0,{dicts:t}]})}}.call(this),"undefined"==typeof Package&&(Package={}),Package["reactive-dict"]={ReactiveDict:r}}();
+
+!function(){var e=Package.meteor.Meteor,a=Package.underscore._,c=Package["reactive-dict"].ReactiveDict,n=Package.ejson.EJSON,i;(function(){i=new c("session")}).call(this),"undefined"==typeof Package&&(Package={}),Package.session={Session:i}}();
+
+!function(){var e=Package.meteor.Meteor,t,n;(function(){!function(e,t){"object"==typeof module&&"object"==typeof module.exports?module.exports=e.document?t(e,!0):function(e){if(!e.document)throw new Error("jQuery requires a window with a document");return t(e)}:t(e)}("undefined"!=typeof window?window:this,function(e,t){function n(e){var t=e.length,n=it.type(e);return"function"===n||it.isWindow(e)?!1:1===e.nodeType&&t?!0:"array"===n||0===t||"number"==typeof t&&t>0&&t-1 in e}function r(e,t,n){if(it.isFunction(t))return it.grep(e,function(e,r){return!!t.call(e,r,e)!==n});if(t.nodeType)return it.grep(e,function(e){return e===t!==n});if("string"==typeof t){if(ft.test(t))return it.filter(t,e,n);t=it.filter(t,e)}return it.grep(e,function(e){return it.inArray(e,t)>=0!==n})}function i(e,t){do e=e[t];while(e&&1!==e.nodeType);return e}function o(e){var t=xt[e]={};return it.each(e.match(bt)||[],function(e,n){t[n]=!0}),t}function a(){ht.addEventListener?(ht.removeEventListener("DOMContentLoaded",s,!1),e.removeEventListener("load",s,!1)):(ht.detachEvent("onreadystatechange",s),e.detachEvent("onload",s))}function s(){(ht.addEventListener||"load"===event.type||"complete"===ht.readyState)&&(a(),it.ready())}function u(e,t,n){if(void 0===n&&1===e.nodeType){var r="data-"+t.replace(Et,"-$1").toLowerCase();if(n=e.getAttribute(r),"string"==typeof n){try{n="true"===n?!0:"false"===n?!1:"null"===n?null:+n+""===n?+n:Nt.test(n)?it.parseJSON(n):n}catch(i){}it.data(e,t,n)}else n=void 0}return n}function l(e){var t;for(t in e)if(("data"!==t||!it.isEmptyObject(e[t]))&&"toJSON"!==t)return!1;return!0}function c(e,t,n,r){if(it.acceptData(e)){var i,o,a=it.expando,s=e.nodeType,u=s?it.cache:e,l=s?e[a]:e[a]&&a;if(l&&u[l]&&(r||u[l].data)||void 0!==n||"string"!=typeof t)return l||(l=s?e[a]=J.pop()||it.guid++:a),u[l]||(u[l]=s?{}:{toJSON:it.noop}),("object"==typeof t||"function"==typeof t)&&(r?u[l]=it.extend(u[l],t):u[l].data=it.extend(u[l].data,t)),o=u[l],r||(o.data||(o.data={}),o=o.data),void 0!==n&&(o[it.camelCase(t)]=n),"string"==typeof t?(i=o[t],null==i&&(i=o[it.camelCase(t)])):i=o,i}}function d(e,t,n){if(it.acceptData(e)){var r,i,o=e.nodeType,a=o?it.cache:e,s=o?e[it.expando]:it.expando;if(a[s]){if(t&&(r=n?a[s]:a[s].data)){it.isArray(t)?t=t.concat(it.map(t,it.camelCase)):t in r?t=[t]:(t=it.camelCase(t),t=t in r?[t]:t.split(" ")),i=t.length;for(;i--;)delete r[t[i]];if(n?!l(r):!it.isEmptyObject(r))return}(n||(delete a[s].data,l(a[s])))&&(o?it.cleanData([e],!0):nt.deleteExpando||a!=a.window?delete a[s]:a[s]=null)}}}function f(){return!0}function p(){return!1}function h(){try{return ht.activeElement}catch(e){}}function m(e){var t=Ft.split("|"),n=e.createDocumentFragment();if(n.createElement)for(;t.length;)n.createElement(t.pop());return n}function g(e,t){var n,r,i=0,o=typeof e.getElementsByTagName!==Tt?e.getElementsByTagName(t||"*"):typeof e.querySelectorAll!==Tt?e.querySelectorAll(t||"*"):void 0;if(!o)for(o=[],n=e.childNodes||e;null!=(r=n[i]);i++)!t||it.nodeName(r,t)?o.push(r):it.merge(o,g(r,t));return void 0===t||t&&it.nodeName(e,t)?it.merge([e],o):o}function v(e){jt.test(e.type)&&(e.defaultChecked=e.checked)}function y(e,t){return it.nodeName(e,"table")&&it.nodeName(11!==t.nodeType?t:t.firstChild,"tr")?e.getElementsByTagName("tbody")[0]||e.appendChild(e.ownerDocument.createElement("tbody")):e}function b(e){return e.type=(null!==it.find.attr(e,"type"))+"/"+e.type,e}function x(e){var t=Vt.exec(e.type);return t?e.type=t[1]:e.removeAttribute("type"),e}function w(e,t){for(var n,r=0;null!=(n=e[r]);r++)it._data(n,"globalEval",!t||it._data(t[r],"globalEval"))}function T(e,t){if(1===t.nodeType&&it.hasData(e)){var n,r,i,o=it._data(e),a=it._data(t,o),s=o.events;if(s){delete a.handle,a.events={};for(n in s)for(r=0,i=s[n].length;i>r;r++)it.event.add(t,n,s[n][r])}a.data&&(a.data=it.extend({},a.data))}}function C(e,t){var n,r,i;if(1===t.nodeType){if(n=t.nodeName.toLowerCase(),!nt.noCloneEvent&&t[it.expando]){i=it._data(t);for(r in i.events)it.removeEvent(t,r,i.handle);t.removeAttribute(it.expando)}"script"===n&&t.text!==e.text?(b(t).text=e.text,x(t)):"object"===n?(t.parentNode&&(t.outerHTML=e.outerHTML),nt.html5Clone&&e.innerHTML&&!it.trim(t.innerHTML)&&(t.innerHTML=e.innerHTML)):"input"===n&&jt.test(e.type)?(t.defaultChecked=t.checked=e.checked,t.value!==e.value&&(t.value=e.value)):"option"===n?t.defaultSelected=t.selected=e.defaultSelected:("input"===n||"textarea"===n)&&(t.defaultValue=e.defaultValue)}}function N(t,n){var r,i=it(n.createElement(t)).appendTo(n.body),o=e.getDefaultComputedStyle&&(r=e.getDefaultComputedStyle(i[0]))?r.display:it.css(i[0],"display");return i.detach(),o}function E(e){var t=ht,n=Zt[e];return n||(n=N(e,t),"none"!==n&&n||(Kt=(Kt||it("<iframe frameborder='0' width='0' height='0'/>")).appendTo(t.documentElement),t=(Kt[0].contentWindow||Kt[0].contentDocument).document,t.write(),t.close(),n=N(e,t),Kt.detach()),Zt[e]=n),n}function k(e,t){return{get:function(){var n=e();if(null!=n)return n?void delete this.get:(this.get=t).apply(this,arguments)}}}function S(e,t){if(t in e)return t;for(var n=t.charAt(0).toUpperCase()+t.slice(1),r=t,i=pn.length;i--;)if(t=pn[i]+n,t in e)return t;return r}function A(e,t){for(var n,r,i,o=[],a=0,s=e.length;s>a;a++)r=e[a],r.style&&(o[a]=it._data(r,"olddisplay"),n=r.style.display,t?(o[a]||"none"!==n||(r.style.display=""),""===r.style.display&&At(r)&&(o[a]=it._data(r,"olddisplay",E(r.nodeName)))):(i=At(r),(n&&"none"!==n||!i)&&it._data(r,"olddisplay",i?n:it.css(r,"display"))));for(a=0;s>a;a++)r=e[a],r.style&&(t&&"none"!==r.style.display&&""!==r.style.display||(r.style.display=t?o[a]||"":"none"));return e}function D(e,t,n){var r=ln.exec(t);return r?Math.max(0,r[1]-(n||0))+(r[2]||"px"):t}function j(e,t,n,r,i){for(var o=n===(r?"border":"content")?4:"width"===t?1:0,a=0;4>o;o+=2)"margin"===n&&(a+=it.css(e,n+St[o],!0,i)),r?("content"===n&&(a-=it.css(e,"padding"+St[o],!0,i)),"margin"!==n&&(a-=it.css(e,"border"+St[o]+"Width",!0,i))):(a+=it.css(e,"padding"+St[o],!0,i),"padding"!==n&&(a+=it.css(e,"border"+St[o]+"Width",!0,i)));return a}function L(e,t,n){var r=!0,i="width"===t?e.offsetWidth:e.offsetHeight,o=nn(e),a=nt.boxSizing&&"border-box"===it.css(e,"boxSizing",!1,o);if(0>=i||null==i){if(i=rn(e,t,o),(0>i||null==i)&&(i=e.style[t]),tn.test(i))return i;r=a&&(nt.boxSizingReliable()||i===e.style[t]),i=parseFloat(i)||0}return i+j(e,t,n||(a?"border":"content"),r,o)+"px"}function H(e,t,n,r,i){return new H.prototype.init(e,t,n,r,i)}function q(){return setTimeout(function(){hn=void 0}),hn=it.now()}function _(e,t){var n,r={height:e},i=0;for(t=t?1:0;4>i;i+=2-t)n=St[i],r["margin"+n]=r["padding"+n]=e;return t&&(r.opacity=r.width=e),r}function M(e,t,n){for(var r,i=(xn[t]||[]).concat(xn["*"]),o=0,a=i.length;a>o;o++)if(r=i[o].call(n,t,e))return r}function F(e,t,n){var r,i,o,a,s,u,l,c,d=this,f={},p=e.style,h=e.nodeType&&At(e),m=it._data(e,"fxshow");n.queue||(s=it._queueHooks(e,"fx"),null==s.unqueued&&(s.unqueued=0,u=s.empty.fire,s.empty.fire=function(){s.unqueued||u()}),s.unqueued++,d.always(function(){d.always(function(){s.unqueued--,it.queue(e,"fx").length||s.empty.fire()})})),1===e.nodeType&&("height"in t||"width"in t)&&(n.overflow=[p.overflow,p.overflowX,p.overflowY],l=it.css(e,"display"),c="none"===l?it._data(e,"olddisplay")||E(e.nodeName):l,"inline"===c&&"none"===it.css(e,"float")&&(nt.inlineBlockNeedsLayout&&"inline"!==E(e.nodeName)?p.zoom=1:p.display="inline-block")),n.overflow&&(p.overflow="hidden",nt.shrinkWrapBlocks()||d.always(function(){p.overflow=n.overflow[0],p.overflowX=n.overflow[1],p.overflowY=n.overflow[2]}));for(r in t)if(i=t[r],gn.exec(i)){if(delete t[r],o=o||"toggle"===i,i===(h?"hide":"show")){if("show"!==i||!m||void 0===m[r])continue;h=!0}f[r]=m&&m[r]||it.style(e,r)}else l=void 0;if(it.isEmptyObject(f))"inline"===("none"===l?E(e.nodeName):l)&&(p.display=l);else{m?"hidden"in m&&(h=m.hidden):m=it._data(e,"fxshow",{}),o&&(m.hidden=!h),h?it(e).show():d.done(function(){it(e).hide()}),d.done(function(){var t;it._removeData(e,"fxshow");for(t in f)it.style(e,t,f[t])});for(r in f)a=M(h?m[r]:0,r,d),r in m||(m[r]=a.start,h&&(a.end=a.start,a.start="width"===r||"height"===r?1:0))}}function O(e,t){var n,r,i,o,a;for(n in e)if(r=it.camelCase(n),i=t[r],o=e[n],it.isArray(o)&&(i=o[1],o=e[n]=o[0]),n!==r&&(e[r]=o,delete e[n]),a=it.cssHooks[r],a&&"expand"in a){o=a.expand(o),delete e[r];for(n in o)n in e||(e[n]=o[n],t[n]=i)}else t[r]=i}function B(e,t,n){var r,i,o=0,a=bn.length,s=it.Deferred().always(function(){delete u.elem}),u=function(){if(i)return!1;for(var t=hn||q(),n=Math.max(0,l.startTime+l.duration-t),r=n/l.duration||0,o=1-r,a=0,u=l.tweens.length;u>a;a++)l.tweens[a].run(o);return s.notifyWith(e,[l,o,n]),1>o&&u?n:(s.resolveWith(e,[l]),!1)},l=s.promise({elem:e,props:it.extend({},t),opts:it.extend(!0,{specialEasing:{}},n),originalProperties:t,originalOptions:n,startTime:hn||q(),duration:n.duration,tweens:[],createTween:function(t,n){var r=it.Tween(e,l.opts,t,n,l.opts.specialEasing[t]||l.opts.easing);return l.tweens.push(r),r},stop:function(t){var n=0,r=t?l.tweens.length:0;if(i)return this;for(i=!0;r>n;n++)l.tweens[n].run(1);return t?s.resolveWith(e,[l,t]):s.rejectWith(e,[l,t]),this}}),c=l.props;for(O(c,l.opts.specialEasing);a>o;o++)if(r=bn[o].call(l,e,c,l.opts))return r;return it.map(c,M,l),it.isFunction(l.opts.start)&&l.opts.start.call(e,l),it.fx.timer(it.extend(u,{elem:e,anim:l,queue:l.opts.queue})),l.progress(l.opts.progress).done(l.opts.done,l.opts.complete).fail(l.opts.fail).always(l.opts.always)}function P(e){return function(t,n){"string"!=typeof t&&(n=t,t="*");var r,i=0,o=t.toLowerCase().match(bt)||[];if(it.isFunction(n))for(;r=o[i++];)"+"===r.charAt(0)?(r=r.slice(1)||"*",(e[r]=e[r]||[]).unshift(n)):(e[r]=e[r]||[]).push(n)}}function R(e,t,n,r){function i(s){var u;return o[s]=!0,it.each(e[s]||[],function(e,s){var l=s(t,n,r);return"string"!=typeof l||a||o[l]?a?!(u=l):void 0:(t.dataTypes.unshift(l),i(l),!1)}),u}var o={},a=e===In;return i(t.dataTypes[0])||!o["*"]&&i("*")}function W(e,t){var n,r,i=it.ajaxSettings.flatOptions||{};for(r in t)void 0!==t[r]&&((i[r]?e:n||(n={}))[r]=t[r]);return n&&it.extend(!0,e,n),e}function $(e,t,n){for(var r,i,o,a,s=e.contents,u=e.dataTypes;"*"===u[0];)u.shift(),void 0===i&&(i=e.mimeType||t.getResponseHeader("Content-Type"));if(i)for(a in s)if(s[a]&&s[a].test(i)){u.unshift(a);break}if(u[0]in n)o=u[0];else{for(a in n){if(!u[0]||e.converters[a+" "+u[0]]){o=a;break}r||(r=a)}o=o||r}return o?(o!==u[0]&&u.unshift(o),n[o]):void 0}function z(e,t,n,r){var i,o,a,s,u,l={},c=e.dataTypes.slice();if(c[1])for(a in e.converters)l[a.toLowerCase()]=e.converters[a];for(o=c.shift();o;)if(e.responseFields[o]&&(n[e.responseFields[o]]=t),!u&&r&&e.dataFilter&&(t=e.dataFilter(t,e.dataType)),u=o,o=c.shift())if("*"===o)o=u;else if("*"!==u&&u!==o){if(a=l[u+" "+o]||l["* "+o],!a)for(i in l)if(s=i.split(" "),s[1]===o&&(a=l[u+" "+s[0]]||l["* "+s[0]])){a===!0?a=l[i]:l[i]!==!0&&(o=s[0],c.unshift(s[1]));break}if(a!==!0)if(a&&e["throws"])t=a(t);else try{t=a(t)}catch(d){return{state:"parsererror",error:a?d:"No conversion from "+u+" to "+o}}}return{state:"success",data:t}}function I(e,t,n,r){var i;if(it.isArray(t))it.each(t,function(t,i){n||Jn.test(e)?r(e,i):I(e+"["+("object"==typeof i?t:"")+"]",i,n,r)});else if(n||"object"!==it.type(t))r(e,t);else for(i in t)I(e+"["+i+"]",t[i],n,r)}function X(){try{return new e.XMLHttpRequest}catch(t){}}function U(){try{return new e.ActiveXObject("Microsoft.XMLHTTP")}catch(t){}}function V(e){return it.isWindow(e)?e:9===e.nodeType?e.defaultView||e.parentWindow:!1}var J=[],Y=J.slice,Q=J.concat,G=J.push,K=J.indexOf,Z={},et=Z.toString,tt=Z.hasOwnProperty,nt={},rt="1.11.2",it=function(e,t){return new it.fn.init(e,t)},ot=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,at=/^-ms-/,st=/-([\da-z])/gi,ut=function(e,t){return t.toUpperCase()};it.fn=it.prototype={jquery:rt,constructor:it,selector:"",length:0,toArray:function(){return Y.call(this)},get:function(e){return null!=e?0>e?this[e+this.length]:this[e]:Y.call(this)},pushStack:function(e){var t=it.merge(this.constructor(),e);return t.prevObject=this,t.context=this.context,t},each:function(e,t){return it.each(this,e,t)},map:function(e){return this.pushStack(it.map(this,function(t,n){return e.call(t,n,t)}))},slice:function(){return this.pushStack(Y.apply(this,arguments))},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},eq:function(e){var t=this.length,n=+e+(0>e?t:0);return this.pushStack(n>=0&&t>n?[this[n]]:[])},end:function(){return this.prevObject||this.constructor(null)},push:G,sort:J.sort,splice:J.splice},it.extend=it.fn.extend=function(){var e,t,n,r,i,o,a=arguments[0]||{},s=1,u=arguments.length,l=!1;for("boolean"==typeof a&&(l=a,a=arguments[s]||{},s++),"object"==typeof a||it.isFunction(a)||(a={}),s===u&&(a=this,s--);u>s;s++)if(null!=(i=arguments[s]))for(r in i)e=a[r],n=i[r],a!==n&&(l&&n&&(it.isPlainObject(n)||(t=it.isArray(n)))?(t?(t=!1,o=e&&it.isArray(e)?e:[]):o=e&&it.isPlainObject(e)?e:{},a[r]=it.extend(l,o,n)):void 0!==n&&(a[r]=n));return a},it.extend({expando:"jQuery"+(rt+Math.random()).replace(/\D/g,""),isReady:!0,error:function(e){throw new Error(e)},noop:function(){},isFunction:function(e){return"function"===it.type(e)},isArray:Array.isArray||function(e){return"array"===it.type(e)},isWindow:function(e){return null!=e&&e==e.window},isNumeric:function(e){return!it.isArray(e)&&e-parseFloat(e)+1>=0},isEmptyObject:function(e){var t;for(t in e)return!1;return!0},isPlainObject:function(e){var t;if(!e||"object"!==it.type(e)||e.nodeType||it.isWindow(e))return!1;try{if(e.constructor&&!tt.call(e,"constructor")&&!tt.call(e.constructor.prototype,"isPrototypeOf"))return!1}catch(n){return!1}if(nt.ownLast)for(t in e)return tt.call(e,t);for(t in e);return void 0===t||tt.call(e,t)},type:function(e){return null==e?e+"":"object"==typeof e||"function"==typeof e?Z[et.call(e)]||"object":typeof e},globalEval:function(t){t&&it.trim(t)&&(e.execScript||function(t){e.eval.call(e,t)})(t)},camelCase:function(e){return e.replace(at,"ms-").replace(st,ut)},nodeName:function(e,t){return e.nodeName&&e.nodeName.toLowerCase()===t.toLowerCase()},each:function(e,t,r){var i,o=0,a=e.length,s=n(e);if(r){if(s)for(;a>o&&(i=t.apply(e[o],r),i!==!1);o++);else for(o in e)if(i=t.apply(e[o],r),i===!1)break}else if(s)for(;a>o&&(i=t.call(e[o],o,e[o]),i!==!1);o++);else for(o in e)if(i=t.call(e[o],o,e[o]),i===!1)break;return e},trim:function(e){return null==e?"":(e+"").replace(ot,"")},makeArray:function(e,t){var r=t||[];return null!=e&&(n(Object(e))?it.merge(r,"string"==typeof e?[e]:e):G.call(r,e)),r},inArray:function(e,t,n){var r;if(t){if(K)return K.call(t,e,n);for(r=t.length,n=n?0>n?Math.max(0,r+n):n:0;r>n;n++)if(n in t&&t[n]===e)return n}return-1},merge:function(e,t){for(var n=+t.length,r=0,i=e.length;n>r;)e[i++]=t[r++];if(n!==n)for(;void 0!==t[r];)e[i++]=t[r++];return e.length=i,e},grep:function(e,t,n){for(var r,i=[],o=0,a=e.length,s=!n;a>o;o++)r=!t(e[o],o),r!==s&&i.push(e[o]);return i},map:function(e,t,r){var i,o=0,a=e.length,s=n(e),u=[];if(s)for(;a>o;o++)i=t(e[o],o,r),null!=i&&u.push(i);else for(o in e)i=t(e[o],o,r),null!=i&&u.push(i);return Q.apply([],u)},guid:1,proxy:function(e,t){var n,r,i;return"string"==typeof t&&(i=e[t],t=e,e=i),it.isFunction(e)?(n=Y.call(arguments,2),r=function(){return e.apply(t||this,n.concat(Y.call(arguments)))},r.guid=e.guid=e.guid||it.guid++,r):void 0},now:function(){return+new Date},support:nt}),it.each("Boolean Number String Function Array Date RegExp Object Error".split(" "),function(e,t){Z["[object "+t+"]"]=t.toLowerCase()});var lt=function(e){function t(e,t,n,r){var i,o,a,s,u,l,d,p,h,m;if((t?t.ownerDocument||t:R)!==H&&L(t),t=t||H,n=n||[],s=t.nodeType,"string"!=typeof e||!e||1!==s&&9!==s&&11!==s)return n;if(!r&&_){if(11!==s&&(i=yt.exec(e)))if(a=i[1]){if(9===s){if(o=t.getElementById(a),!o||!o.parentNode)return n;if(o.id===a)return n.push(o),n}else if(t.ownerDocument&&(o=t.ownerDocument.getElementById(a))&&B(t,o)&&o.id===a)return n.push(o),n}else{if(i[2])return K.apply(n,t.getElementsByTagName(e)),n;if((a=i[3])&&w.getElementsByClassName)return K.apply(n,t.getElementsByClassName(a)),n}if(w.qsa&&(!M||!M.test(e))){if(p=d=P,h=t,m=1!==s&&e,1===s&&"object"!==t.nodeName.toLowerCase()){for(l=E(e),(d=t.getAttribute("id"))?p=d.replace(xt,"\\$&"):t.setAttribute("id",p),p="[id='"+p+"'] ",u=l.length;u--;)l[u]=p+f(l[u]);h=bt.test(e)&&c(t.parentNode)||t,m=l.join(",")}if(m)try{return K.apply(n,h.querySelectorAll(m)),n}catch(g){}finally{d||t.removeAttribute("id")}}}return S(e.replace(ut,"$1"),t,n,r)}function n(){function e(n,r){return t.push(n+" ")>T.cacheLength&&delete e[t.shift()],e[n+" "]=r}var t=[];return e}function r(e){return e[P]=!0,e}function i(e){var t=H.createElement("div");try{return!!e(t)}catch(n){return!1}finally{t.parentNode&&t.parentNode.removeChild(t),t=null}}function o(e,t){for(var n=e.split("|"),r=e.length;r--;)T.attrHandle[n[r]]=t}function a(e,t){var n=t&&e,r=n&&1===e.nodeType&&1===t.nodeType&&(~t.sourceIndex||V)-(~e.sourceIndex||V);if(r)return r;if(n)for(;n=n.nextSibling;)if(n===t)return-1;return e?1:-1}function s(e){return function(t){var n=t.nodeName.toLowerCase();return"input"===n&&t.type===e}}function u(e){return function(t){var n=t.nodeName.toLowerCase();return("input"===n||"button"===n)&&t.type===e}}function l(e){return r(function(t){return t=+t,r(function(n,r){for(var i,o=e([],n.length,t),a=o.length;a--;)n[i=o[a]]&&(n[i]=!(r[i]=n[i]))})})}function c(e){return e&&"undefined"!=typeof e.getElementsByTagName&&e}function d(){}function f(e){for(var t=0,n=e.length,r="";n>t;t++)r+=e[t].value;return r}function p(e,t,n){var r=t.dir,i=n&&"parentNode"===r,o=$++;return t.first?function(t,n,o){for(;t=t[r];)if(1===t.nodeType||i)return e(t,n,o)}:function(t,n,a){var s,u,l=[W,o];if(a){for(;t=t[r];)if((1===t.nodeType||i)&&e(t,n,a))return!0}else for(;t=t[r];)if(1===t.nodeType||i){if(u=t[P]||(t[P]={}),(s=u[r])&&s[0]===W&&s[1]===o)return l[2]=s[2];if(u[r]=l,l[2]=e(t,n,a))return!0}}}function h(e){return e.length>1?function(t,n,r){for(var i=e.length;i--;)if(!e[i](t,n,r))return!1;return!0}:e[0]}function m(e,n,r){for(var i=0,o=n.length;o>i;i++)t(e,n[i],r);return r}function g(e,t,n,r,i){for(var o,a=[],s=0,u=e.length,l=null!=t;u>s;s++)(o=e[s])&&(!n||n(o,r,i))&&(a.push(o),l&&t.push(s));return a}function v(e,t,n,i,o,a){return i&&!i[P]&&(i=v(i)),o&&!o[P]&&(o=v(o,a)),r(function(r,a,s,u){var l,c,d,f=[],p=[],h=a.length,v=r||m(t||"*",s.nodeType?[s]:s,[]),y=!e||!r&&t?v:g(v,f,e,s,u),b=n?o||(r?e:h||i)?[]:a:y;if(n&&n(y,b,s,u),i)for(l=g(b,p),i(l,[],s,u),c=l.length;c--;)(d=l[c])&&(b[p[c]]=!(y[p[c]]=d));if(r){if(o||e){if(o){for(l=[],c=b.length;c--;)(d=b[c])&&l.push(y[c]=d);o(null,b=[],l,u)}for(c=b.length;c--;)(d=b[c])&&(l=o?et(r,d):f[c])>-1&&(r[l]=!(a[l]=d))}}else b=g(b===a?b.splice(h,b.length):b),o?o(null,a,b,u):K.apply(a,b)})}function y(e){for(var t,n,r,i=e.length,o=T.relative[e[0].type],a=o||T.relative[" "],s=o?1:0,u=p(function(e){return e===t},a,!0),l=p(function(e){return et(t,e)>-1},a,!0),c=[function(e,n,r){var i=!o&&(r||n!==A)||((t=n).nodeType?u(e,n,r):l(e,n,r));return t=null,i}];i>s;s++)if(n=T.relative[e[s].type])c=[p(h(c),n)];else{if(n=T.filter[e[s].type].apply(null,e[s].matches),n[P]){for(r=++s;i>r&&!T.relative[e[r].type];r++);return v(s>1&&h(c),s>1&&f(e.slice(0,s-1).concat({value:" "===e[s-2].type?"*":""})).replace(ut,"$1"),n,r>s&&y(e.slice(s,r)),i>r&&y(e=e.slice(r)),i>r&&f(e))}c.push(n)}return h(c)}function b(e,n){var i=n.length>0,o=e.length>0,a=function(r,a,s,u,l){var c,d,f,p=0,h="0",m=r&&[],v=[],y=A,b=r||o&&T.find.TAG("*",l),x=W+=null==y?1:Math.random()||.1,w=b.length;for(l&&(A=a!==H&&a);h!==w&&null!=(c=b[h]);h++){if(o&&c){for(d=0;f=e[d++];)if(f(c,a,s)){u.push(c);break}l&&(W=x)}i&&((c=!f&&c)&&p--,r&&m.push(c))}if(p+=h,i&&h!==p){for(d=0;f=n[d++];)f(m,v,a,s);if(r){if(p>0)for(;h--;)m[h]||v[h]||(v[h]=Q.call(u));v=g(v)}K.apply(u,v),l&&!r&&v.length>0&&p+n.length>1&&t.uniqueSort(u)}return l&&(W=x,A=y),m};return i?r(a):a}var x,w,T,C,N,E,k,S,A,D,j,L,H,q,_,M,F,O,B,P="sizzle"+1*new Date,R=e.document,W=0,$=0,z=n(),I=n(),X=n(),U=function(e,t){return e===t&&(j=!0),0},V=1<<31,J={}.hasOwnProperty,Y=[],Q=Y.pop,G=Y.push,K=Y.push,Z=Y.slice,et=function(e,t){for(var n=0,r=e.length;r>n;n++)if(e[n]===t)return n;return-1},tt="checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped",nt="[\\x20\\t\\r\\n\\f]",rt="(?:\\\\.|[\\w-]|[^\\x00-\\xa0])+",it=rt.replace("w","w#"),ot="\\["+nt+"*("+rt+")(?:"+nt+"*([*^$|!~]?=)"+nt+"*(?:'((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\"|("+it+"))|)"+nt+"*\\]",at=":("+rt+")(?:\\((('((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\")|((?:\\\\.|[^\\\\()[\\]]|"+ot+")*)|.*)\\)|)",st=new RegExp(nt+"+","g"),ut=new RegExp("^"+nt+"+|((?:^|[^\\\\])(?:\\\\.)*)"+nt+"+$","g"),lt=new RegExp("^"+nt+"*,"+nt+"*"),ct=new RegExp("^"+nt+"*([>+~]|"+nt+")"+nt+"*"),dt=new RegExp("="+nt+"*([^\\]'\"]*?)"+nt+"*\\]","g"),ft=new RegExp(at),pt=new RegExp("^"+it+"$"),ht={ID:new RegExp("^#("+rt+")"),CLASS:new RegExp("^\\.("+rt+")"),TAG:new RegExp("^("+rt.replace("w","w*")+")"),ATTR:new RegExp("^"+ot),PSEUDO:new RegExp("^"+at),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+nt+"*(even|odd|(([+-]|)(\\d*)n|)"+nt+"*(?:([+-]|)"+nt+"*(\\d+)|))"+nt+"*\\)|)","i"),bool:new RegExp("^(?:"+tt+")$","i"),needsContext:new RegExp("^"+nt+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+nt+"*((?:-\\d)?\\d*)"+nt+"*\\)|)(?=[^-]|$)","i")},mt=/^(?:input|select|textarea|button)$/i,gt=/^h\d$/i,vt=/^[^{]+\{\s*\[native \w/,yt=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,bt=/[+~]/,xt=/'|\\/g,wt=new RegExp("\\\\([\\da-f]{1,6}"+nt+"?|("+nt+")|.)","ig"),Tt=function(e,t,n){var r="0x"+t-65536;return r!==r||n?t:0>r?String.fromCharCode(r+65536):String.fromCharCode(r>>10|55296,1023&r|56320)},Ct=function(){L()};try{K.apply(Y=Z.call(R.childNodes),R.childNodes),Y[R.childNodes.length].nodeType}catch(Nt){K={apply:Y.length?function(e,t){G.apply(e,Z.call(t))}:function(e,t){for(var n=e.length,r=0;e[n++]=t[r++];);e.length=n-1}}}w=t.support={},N=t.isXML=function(e){var t=e&&(e.ownerDocument||e).documentElement;return t?"HTML"!==t.nodeName:!1},L=t.setDocument=function(e){var t,n,r=e?e.ownerDocument||e:R;return r!==H&&9===r.nodeType&&r.documentElement?(H=r,q=r.documentElement,n=r.defaultView,n&&n!==n.top&&(n.addEventListener?n.addEventListener("unload",Ct,!1):n.attachEvent&&n.attachEvent("onunload",Ct)),_=!N(r),w.attributes=i(function(e){return e.className="i",!e.getAttribute("className")}),w.getElementsByTagName=i(function(e){return e.appendChild(r.createComment("")),!e.getElementsByTagName("*").length}),w.getElementsByClassName=vt.test(r.getElementsByClassName),w.getById=i(function(e){return q.appendChild(e).id=P,!r.getElementsByName||!r.getElementsByName(P).length}),w.getById?(T.find.ID=function(e,t){if("undefined"!=typeof t.getElementById&&_){var n=t.getElementById(e);return n&&n.parentNode?[n]:[]}},T.filter.ID=function(e){var t=e.replace(wt,Tt);return function(e){return e.getAttribute("id")===t}}):(delete T.find.ID,T.filter.ID=function(e){var t=e.replace(wt,Tt);return function(e){var n="undefined"!=typeof e.getAttributeNode&&e.getAttributeNode("id");return n&&n.value===t}}),T.find.TAG=w.getElementsByTagName?function(e,t){return"undefined"!=typeof t.getElementsByTagName?t.getElementsByTagName(e):w.qsa?t.querySelectorAll(e):void 0}:function(e,t){var n,r=[],i=0,o=t.getElementsByTagName(e);if("*"===e){for(;n=o[i++];)1===n.nodeType&&r.push(n);return r}return o},T.find.CLASS=w.getElementsByClassName&&function(e,t){return _?t.getElementsByClassName(e):void 0},F=[],M=[],(w.qsa=vt.test(r.querySelectorAll))&&(i(function(e){q.appendChild(e).innerHTML="<a id='"+P+"'></a><select id='"+P+"-\f]' msallowcapture=''><option selected=''></option></select>",e.querySelectorAll("[msallowcapture^='']").length&&M.push("[*^$]="+nt+"*(?:''|\"\")"),e.querySelectorAll("[selected]").length||M.push("\\["+nt+"*(?:value|"+tt+")"),e.querySelectorAll("[id~="+P+"-]").length||M.push("~="),e.querySelectorAll(":checked").length||M.push(":checked"),e.querySelectorAll("a#"+P+"+*").length||M.push(".#.+[+~]")}),i(function(e){var t=r.createElement("input");t.setAttribute("type","hidden"),e.appendChild(t).setAttribute("name","D"),e.querySelectorAll("[name=d]").length&&M.push("name"+nt+"*[*^$|!~]?="),e.querySelectorAll(":enabled").length||M.push(":enabled",":disabled"),e.querySelectorAll("*,:x"),M.push(",.*:")})),(w.matchesSelector=vt.test(O=q.matches||q.webkitMatchesSelector||q.mozMatchesSelector||q.oMatchesSelector||q.msMatchesSelector))&&i(function(e){w.disconnectedMatch=O.call(e,"div"),O.call(e,"[s!='']:x"),F.push("!=",at)}),M=M.length&&new RegExp(M.join("|")),F=F.length&&new RegExp(F.join("|")),t=vt.test(q.compareDocumentPosition),B=t||vt.test(q.contains)?function(e,t){var n=9===e.nodeType?e.documentElement:e,r=t&&t.parentNode;return e===r||!(!r||1!==r.nodeType||!(n.contains?n.contains(r):e.compareDocumentPosition&&16&e.compareDocumentPosition(r)))}:function(e,t){if(t)for(;t=t.parentNode;)if(t===e)return!0;return!1},U=t?function(e,t){if(e===t)return j=!0,0;var n=!e.compareDocumentPosition-!t.compareDocumentPosition;return n?n:(n=(e.ownerDocument||e)===(t.ownerDocument||t)?e.compareDocumentPosition(t):1,1&n||!w.sortDetached&&t.compareDocumentPosition(e)===n?e===r||e.ownerDocument===R&&B(R,e)?-1:t===r||t.ownerDocument===R&&B(R,t)?1:D?et(D,e)-et(D,t):0:4&n?-1:1)}:function(e,t){if(e===t)return j=!0,0;var n,i=0,o=e.parentNode,s=t.parentNode,u=[e],l=[t];if(!o||!s)return e===r?-1:t===r?1:o?-1:s?1:D?et(D,e)-et(D,t):0;if(o===s)return a(e,t);for(n=e;n=n.parentNode;)u.unshift(n);for(n=t;n=n.parentNode;)l.unshift(n);for(;u[i]===l[i];)i++;return i?a(u[i],l[i]):u[i]===R?-1:l[i]===R?1:0},r):H},t.matches=function(e,n){return t(e,null,null,n)},t.matchesSelector=function(e,n){if((e.ownerDocument||e)!==H&&L(e),n=n.replace(dt,"='$1']"),!(!w.matchesSelector||!_||F&&F.test(n)||M&&M.test(n)))try{var r=O.call(e,n);if(r||w.disconnectedMatch||e.document&&11!==e.document.nodeType)return r}catch(i){}return t(n,H,null,[e]).length>0},t.contains=function(e,t){return(e.ownerDocument||e)!==H&&L(e),B(e,t)},t.attr=function(e,t){(e.ownerDocument||e)!==H&&L(e);var n=T.attrHandle[t.toLowerCase()],r=n&&J.call(T.attrHandle,t.toLowerCase())?n(e,t,!_):void 0;return void 0!==r?r:w.attributes||!_?e.getAttribute(t):(r=e.getAttributeNode(t))&&r.specified?r.value:null},t.error=function(e){throw new Error("Syntax error, unrecognized expression: "+e)},t.uniqueSort=function(e){var t,n=[],r=0,i=0;if(j=!w.detectDuplicates,D=!w.sortStable&&e.slice(0),e.sort(U),j){for(;t=e[i++];)t===e[i]&&(r=n.push(i));for(;r--;)e.splice(n[r],1)}return D=null,e},C=t.getText=function(e){var t,n="",r=0,i=e.nodeType;if(i){if(1===i||9===i||11===i){if("string"==typeof e.textContent)return e.textContent;for(e=e.firstChild;e;e=e.nextSibling)n+=C(e)}else if(3===i||4===i)return e.nodeValue}else for(;t=e[r++];)n+=C(t);return n},T=t.selectors={cacheLength:50,createPseudo:r,match:ht,attrHandle:{},find:{},relative:{">":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(e){return e[1]=e[1].replace(wt,Tt),e[3]=(e[3]||e[4]||e[5]||"").replace(wt,Tt),"~="===e[2]&&(e[3]=" "+e[3]+" "),e.slice(0,4)},CHILD:function(e){return e[1]=e[1].toLowerCase(),"nth"===e[1].slice(0,3)?(e[3]||t.error(e[0]),e[4]=+(e[4]?e[5]+(e[6]||1):2*("even"===e[3]||"odd"===e[3])),e[5]=+(e[7]+e[8]||"odd"===e[3])):e[3]&&t.error(e[0]),e},PSEUDO:function(e){var t,n=!e[6]&&e[2];return ht.CHILD.test(e[0])?null:(e[3]?e[2]=e[4]||e[5]||"":n&&ft.test(n)&&(t=E(n,!0))&&(t=n.indexOf(")",n.length-t)-n.length)&&(e[0]=e[0].slice(0,t),e[2]=n.slice(0,t)),e.slice(0,3))}},filter:{TAG:function(e){var t=e.replace(wt,Tt).toLowerCase();return"*"===e?function(){return!0}:function(e){return e.nodeName&&e.nodeName.toLowerCase()===t}},CLASS:function(e){var t=z[e+" "];return t||(t=new RegExp("(^|"+nt+")"+e+"("+nt+"|$)"))&&z(e,function(e){return t.test("string"==typeof e.className&&e.className||"undefined"!=typeof e.getAttribute&&e.getAttribute("class")||"")})},ATTR:function(e,n,r){return function(i){var o=t.attr(i,e);return null==o?"!="===n:n?(o+="","="===n?o===r:"!="===n?o!==r:"^="===n?r&&0===o.indexOf(r):"*="===n?r&&o.indexOf(r)>-1:"$="===n?r&&o.slice(-r.length)===r:"~="===n?(" "+o.replace(st," ")+" ").indexOf(r)>-1:"|="===n?o===r||o.slice(0,r.length+1)===r+"-":!1):!0}},CHILD:function(e,t,n,r,i){var o="nth"!==e.slice(0,3),a="last"!==e.slice(-4),s="of-type"===t;return 1===r&&0===i?function(e){return!!e.parentNode}:function(t,n,u){var l,c,d,f,p,h,m=o!==a?"nextSibling":"previousSibling",g=t.parentNode,v=s&&t.nodeName.toLowerCase(),y=!u&&!s;if(g){if(o){for(;m;){for(d=t;d=d[m];)if(s?d.nodeName.toLowerCase()===v:1===d.nodeType)return!1;h=m="only"===e&&!h&&"nextSibling"}return!0}if(h=[a?g.firstChild:g.lastChild],a&&y){for(c=g[P]||(g[P]={}),l=c[e]||[],p=l[0]===W&&l[1],f=l[0]===W&&l[2],d=p&&g.childNodes[p];d=++p&&d&&d[m]||(f=p=0)||h.pop();)if(1===d.nodeType&&++f&&d===t){c[e]=[W,p,f];break}}else if(y&&(l=(t[P]||(t[P]={}))[e])&&l[0]===W)f=l[1];else for(;(d=++p&&d&&d[m]||(f=p=0)||h.pop())&&((s?d.nodeName.toLowerCase()!==v:1!==d.nodeType)||!++f||(y&&((d[P]||(d[P]={}))[e]=[W,f]),d!==t)););return f-=i,f===r||f%r===0&&f/r>=0}}},PSEUDO:function(e,n){var i,o=T.pseudos[e]||T.setFilters[e.toLowerCase()]||t.error("unsupported pseudo: "+e);return o[P]?o(n):o.length>1?(i=[e,e,"",n],T.setFilters.hasOwnProperty(e.toLowerCase())?r(function(e,t){for(var r,i=o(e,n),a=i.length;a--;)r=et(e,i[a]),e[r]=!(t[r]=i[a])}):function(e){return o(e,0,i)}):o}},pseudos:{not:r(function(e){var t=[],n=[],i=k(e.replace(ut,"$1"));return i[P]?r(function(e,t,n,r){for(var o,a=i(e,null,r,[]),s=e.length;s--;)(o=a[s])&&(e[s]=!(t[s]=o))}):function(e,r,o){return t[0]=e,i(t,null,o,n),t[0]=null,!n.pop()}}),has:r(function(e){return function(n){return t(e,n).length>0}}),contains:r(function(e){return e=e.replace(wt,Tt),function(t){return(t.textContent||t.innerText||C(t)).indexOf(e)>-1}}),lang:r(function(e){return pt.test(e||"")||t.error("unsupported lang: "+e),e=e.replace(wt,Tt).toLowerCase(),function(t){var n;do if(n=_?t.lang:t.getAttribute("xml:lang")||t.getAttribute("lang"))return n=n.toLowerCase(),n===e||0===n.indexOf(e+"-");while((t=t.parentNode)&&1===t.nodeType);return!1}}),target:function(t){var n=e.location&&e.location.hash;return n&&n.slice(1)===t.id},root:function(e){return e===q},focus:function(e){return e===H.activeElement&&(!H.hasFocus||H.hasFocus())&&!!(e.type||e.href||~e.tabIndex)},enabled:function(e){return e.disabled===!1},disabled:function(e){return e.disabled===!0},checked:function(e){var t=e.nodeName.toLowerCase();return"input"===t&&!!e.checked||"option"===t&&!!e.selected},selected:function(e){return e.parentNode&&e.parentNode.selectedIndex,e.selected===!0},empty:function(e){for(e=e.firstChild;e;e=e.nextSibling)if(e.nodeType<6)return!1;return!0},parent:function(e){return!T.pseudos.empty(e)},header:function(e){return gt.test(e.nodeName)},input:function(e){return mt.test(e.nodeName)},button:function(e){var t=e.nodeName.toLowerCase();return"input"===t&&"button"===e.type||"button"===t},text:function(e){var t;return"input"===e.nodeName.toLowerCase()&&"text"===e.type&&(null==(t=e.getAttribute("type"))||"text"===t.toLowerCase())},first:l(function(){return[0]}),last:l(function(e,t){return[t-1]}),eq:l(function(e,t,n){return[0>n?n+t:n]}),even:l(function(e,t){for(var n=0;t>n;n+=2)e.push(n);return e}),odd:l(function(e,t){for(var n=1;t>n;n+=2)e.push(n);return e}),lt:l(function(e,t,n){for(var r=0>n?n+t:n;--r>=0;)e.push(r);return e}),gt:l(function(e,t,n){for(var r=0>n?n+t:n;++r<t;)e.push(r);return e})}},T.pseudos.nth=T.pseudos.eq;for(x in{radio:!0,checkbox:!0,file:!0,password:!0,image:!0})T.pseudos[x]=s(x);for(x in{submit:!0,reset:!0})T.pseudos[x]=u(x);return d.prototype=T.filters=T.pseudos,T.setFilters=new d,E=t.tokenize=function(e,n){var r,i,o,a,s,u,l,c=I[e+" "];if(c)return n?0:c.slice(0);for(s=e,u=[],l=T.preFilter;s;){(!r||(i=lt.exec(s)))&&(i&&(s=s.slice(i[0].length)||s),u.push(o=[])),r=!1,(i=ct.exec(s))&&(r=i.shift(),o.push({value:r,type:i[0].replace(ut," ")}),s=s.slice(r.length));
+for(a in T.filter)!(i=ht[a].exec(s))||l[a]&&!(i=l[a](i))||(r=i.shift(),o.push({value:r,type:a,matches:i}),s=s.slice(r.length));if(!r)break}return n?s.length:s?t.error(e):I(e,u).slice(0)},k=t.compile=function(e,t){var n,r=[],i=[],o=X[e+" "];if(!o){for(t||(t=E(e)),n=t.length;n--;)o=y(t[n]),o[P]?r.push(o):i.push(o);o=X(e,b(i,r)),o.selector=e}return o},S=t.select=function(e,t,n,r){var i,o,a,s,u,l="function"==typeof e&&e,d=!r&&E(e=l.selector||e);if(n=n||[],1===d.length){if(o=d[0]=d[0].slice(0),o.length>2&&"ID"===(a=o[0]).type&&w.getById&&9===t.nodeType&&_&&T.relative[o[1].type]){if(t=(T.find.ID(a.matches[0].replace(wt,Tt),t)||[])[0],!t)return n;l&&(t=t.parentNode),e=e.slice(o.shift().value.length)}for(i=ht.needsContext.test(e)?0:o.length;i--&&(a=o[i],!T.relative[s=a.type]);)if((u=T.find[s])&&(r=u(a.matches[0].replace(wt,Tt),bt.test(o[0].type)&&c(t.parentNode)||t))){if(o.splice(i,1),e=r.length&&f(o),!e)return K.apply(n,r),n;break}}return(l||k(e,d))(r,t,!_,n,bt.test(e)&&c(t.parentNode)||t),n},w.sortStable=P.split("").sort(U).join("")===P,w.detectDuplicates=!!j,L(),w.sortDetached=i(function(e){return 1&e.compareDocumentPosition(H.createElement("div"))}),i(function(e){return e.innerHTML="<a href='#'></a>","#"===e.firstChild.getAttribute("href")})||o("type|href|height|width",function(e,t,n){return n?void 0:e.getAttribute(t,"type"===t.toLowerCase()?1:2)}),w.attributes&&i(function(e){return e.innerHTML="<input/>",e.firstChild.setAttribute("value",""),""===e.firstChild.getAttribute("value")})||o("value",function(e,t,n){return n||"input"!==e.nodeName.toLowerCase()?void 0:e.defaultValue}),i(function(e){return null==e.getAttribute("disabled")})||o(tt,function(e,t,n){var r;return n?void 0:e[t]===!0?t.toLowerCase():(r=e.getAttributeNode(t))&&r.specified?r.value:null}),t}(e);it.find=lt,it.expr=lt.selectors,it.expr[":"]=it.expr.pseudos,it.unique=lt.uniqueSort,it.text=lt.getText,it.isXMLDoc=lt.isXML,it.contains=lt.contains;var ct=it.expr.match.needsContext,dt=/^<(\w+)\s*\/?>(?:<\/\1>|)$/,ft=/^.[^:#\[\.,]*$/;it.filter=function(e,t,n){var r=t[0];return n&&(e=":not("+e+")"),1===t.length&&1===r.nodeType?it.find.matchesSelector(r,e)?[r]:[]:it.find.matches(e,it.grep(t,function(e){return 1===e.nodeType}))},it.fn.extend({find:function(e){var t,n=[],r=this,i=r.length;if("string"!=typeof e)return this.pushStack(it(e).filter(function(){for(t=0;i>t;t++)if(it.contains(r[t],this))return!0}));for(t=0;i>t;t++)it.find(e,r[t],n);return n=this.pushStack(i>1?it.unique(n):n),n.selector=this.selector?this.selector+" "+e:e,n},filter:function(e){return this.pushStack(r(this,e||[],!1))},not:function(e){return this.pushStack(r(this,e||[],!0))},is:function(e){return!!r(this,"string"==typeof e&&ct.test(e)?it(e):e||[],!1).length}});var pt,ht=e.document,mt=/^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]*))$/,gt=it.fn.init=function(e,t){var n,r;if(!e)return this;if("string"==typeof e){if(n="<"===e.charAt(0)&&">"===e.charAt(e.length-1)&&e.length>=3?[null,e,null]:mt.exec(e),!n||!n[1]&&t)return!t||t.jquery?(t||pt).find(e):this.constructor(t).find(e);if(n[1]){if(t=t instanceof it?t[0]:t,it.merge(this,it.parseHTML(n[1],t&&t.nodeType?t.ownerDocument||t:ht,!0)),dt.test(n[1])&&it.isPlainObject(t))for(n in t)it.isFunction(this[n])?this[n](t[n]):this.attr(n,t[n]);return this}if(r=ht.getElementById(n[2]),r&&r.parentNode){if(r.id!==n[2])return pt.find(e);this.length=1,this[0]=r}return this.context=ht,this.selector=e,this}return e.nodeType?(this.context=this[0]=e,this.length=1,this):it.isFunction(e)?"undefined"!=typeof pt.ready?pt.ready(e):e(it):(void 0!==e.selector&&(this.selector=e.selector,this.context=e.context),it.makeArray(e,this))};gt.prototype=it.fn,pt=it(ht);var vt=/^(?:parents|prev(?:Until|All))/,yt={children:!0,contents:!0,next:!0,prev:!0};it.extend({dir:function(e,t,n){for(var r=[],i=e[t];i&&9!==i.nodeType&&(void 0===n||1!==i.nodeType||!it(i).is(n));)1===i.nodeType&&r.push(i),i=i[t];return r},sibling:function(e,t){for(var n=[];e;e=e.nextSibling)1===e.nodeType&&e!==t&&n.push(e);return n}}),it.fn.extend({has:function(e){var t,n=it(e,this),r=n.length;return this.filter(function(){for(t=0;r>t;t++)if(it.contains(this,n[t]))return!0})},closest:function(e,t){for(var n,r=0,i=this.length,o=[],a=ct.test(e)||"string"!=typeof e?it(e,t||this.context):0;i>r;r++)for(n=this[r];n&&n!==t;n=n.parentNode)if(n.nodeType<11&&(a?a.index(n)>-1:1===n.nodeType&&it.find.matchesSelector(n,e))){o.push(n);break}return this.pushStack(o.length>1?it.unique(o):o)},index:function(e){return e?"string"==typeof e?it.inArray(this[0],it(e)):it.inArray(e.jquery?e[0]:e,this):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(e,t){return this.pushStack(it.unique(it.merge(this.get(),it(e,t))))},addBack:function(e){return this.add(null==e?this.prevObject:this.prevObject.filter(e))}}),it.each({parent:function(e){var t=e.parentNode;return t&&11!==t.nodeType?t:null},parents:function(e){return it.dir(e,"parentNode")},parentsUntil:function(e,t,n){return it.dir(e,"parentNode",n)},next:function(e){return i(e,"nextSibling")},prev:function(e){return i(e,"previousSibling")},nextAll:function(e){return it.dir(e,"nextSibling")},prevAll:function(e){return it.dir(e,"previousSibling")},nextUntil:function(e,t,n){return it.dir(e,"nextSibling",n)},prevUntil:function(e,t,n){return it.dir(e,"previousSibling",n)},siblings:function(e){return it.sibling((e.parentNode||{}).firstChild,e)},children:function(e){return it.sibling(e.firstChild)},contents:function(e){return it.nodeName(e,"iframe")?e.contentDocument||e.contentWindow.document:it.merge([],e.childNodes)}},function(e,t){it.fn[e]=function(n,r){var i=it.map(this,t,n);return"Until"!==e.slice(-5)&&(r=n),r&&"string"==typeof r&&(i=it.filter(r,i)),this.length>1&&(yt[e]||(i=it.unique(i)),vt.test(e)&&(i=i.reverse())),this.pushStack(i)}});var bt=/\S+/g,xt={};it.Callbacks=function(e){e="string"==typeof e?xt[e]||o(e):it.extend({},e);var t,n,r,i,a,s,u=[],l=!e.once&&[],c=function(o){for(n=e.memory&&o,r=!0,a=s||0,s=0,i=u.length,t=!0;u&&i>a;a++)if(u[a].apply(o[0],o[1])===!1&&e.stopOnFalse){n=!1;break}t=!1,u&&(l?l.length&&c(l.shift()):n?u=[]:d.disable())},d={add:function(){if(u){var r=u.length;!function o(t){it.each(t,function(t,n){var r=it.type(n);"function"===r?e.unique&&d.has(n)||u.push(n):n&&n.length&&"string"!==r&&o(n)})}(arguments),t?i=u.length:n&&(s=r,c(n))}return this},remove:function(){return u&&it.each(arguments,function(e,n){for(var r;(r=it.inArray(n,u,r))>-1;)u.splice(r,1),t&&(i>=r&&i--,a>=r&&a--)}),this},has:function(e){return e?it.inArray(e,u)>-1:!(!u||!u.length)},empty:function(){return u=[],i=0,this},disable:function(){return u=l=n=void 0,this},disabled:function(){return!u},lock:function(){return l=void 0,n||d.disable(),this},locked:function(){return!l},fireWith:function(e,n){return!u||r&&!l||(n=n||[],n=[e,n.slice?n.slice():n],t?l.push(n):c(n)),this},fire:function(){return d.fireWith(this,arguments),this},fired:function(){return!!r}};return d},it.extend({Deferred:function(e){var t=[["resolve","done",it.Callbacks("once memory"),"resolved"],["reject","fail",it.Callbacks("once memory"),"rejected"],["notify","progress",it.Callbacks("memory")]],n="pending",r={state:function(){return n},always:function(){return i.done(arguments).fail(arguments),this},then:function(){var e=arguments;return it.Deferred(function(n){it.each(t,function(t,o){var a=it.isFunction(e[t])&&e[t];i[o[1]](function(){var e=a&&a.apply(this,arguments);e&&it.isFunction(e.promise)?e.promise().done(n.resolve).fail(n.reject).progress(n.notify):n[o[0]+"With"](this===r?n.promise():this,a?[e]:arguments)})}),e=null}).promise()},promise:function(e){return null!=e?it.extend(e,r):r}},i={};return r.pipe=r.then,it.each(t,function(e,o){var a=o[2],s=o[3];r[o[1]]=a.add,s&&a.add(function(){n=s},t[1^e][2].disable,t[2][2].lock),i[o[0]]=function(){return i[o[0]+"With"](this===i?r:this,arguments),this},i[o[0]+"With"]=a.fireWith}),r.promise(i),e&&e.call(i,i),i},when:function(e){var t=0,n=Y.call(arguments),r=n.length,i=1!==r||e&&it.isFunction(e.promise)?r:0,o=1===i?e:it.Deferred(),a=function(e,t,n){return function(r){t[e]=this,n[e]=arguments.length>1?Y.call(arguments):r,n===s?o.notifyWith(t,n):--i||o.resolveWith(t,n)}},s,u,l;if(r>1)for(s=new Array(r),u=new Array(r),l=new Array(r);r>t;t++)n[t]&&it.isFunction(n[t].promise)?n[t].promise().done(a(t,l,n)).fail(o.reject).progress(a(t,u,s)):--i;return i||o.resolveWith(l,n),o.promise()}});var wt;it.fn.ready=function(e){return it.ready.promise().done(e),this},it.extend({isReady:!1,readyWait:1,holdReady:function(e){e?it.readyWait++:it.ready(!0)},ready:function(e){if(e===!0?!--it.readyWait:!it.isReady){if(!ht.body)return setTimeout(it.ready);it.isReady=!0,e!==!0&&--it.readyWait>0||(wt.resolveWith(ht,[it]),it.fn.triggerHandler&&(it(ht).triggerHandler("ready"),it(ht).off("ready")))}}}),it.ready.promise=function(t){if(!wt)if(wt=it.Deferred(),"complete"===ht.readyState)setTimeout(it.ready);else if(ht.addEventListener)ht.addEventListener("DOMContentLoaded",s,!1),e.addEventListener("load",s,!1);else{ht.attachEvent("onreadystatechange",s),e.attachEvent("onload",s);var n=!1;try{n=null==e.frameElement&&ht.documentElement}catch(r){}n&&n.doScroll&&!function i(){if(!it.isReady){try{n.doScroll("left")}catch(e){return setTimeout(i,50)}a(),it.ready()}}()}return wt.promise(t)};var Tt="undefined",Ct;for(Ct in it(nt))break;nt.ownLast="0"!==Ct,nt.inlineBlockNeedsLayout=!1,it(function(){var e,t,n,r;n=ht.getElementsByTagName("body")[0],n&&n.style&&(t=ht.createElement("div"),r=ht.createElement("div"),r.style.cssText="position:absolute;border:0;width:0;height:0;top:0;left:-9999px",n.appendChild(r).appendChild(t),typeof t.style.zoom!==Tt&&(t.style.cssText="display:inline;margin:0;border:0;padding:1px;width:1px;zoom:1",nt.inlineBlockNeedsLayout=e=3===t.offsetWidth,e&&(n.style.zoom=1)),n.removeChild(r))}),function(){var e=ht.createElement("div");if(null==nt.deleteExpando){nt.deleteExpando=!0;try{delete e.test}catch(t){nt.deleteExpando=!1}}e=null}(),it.acceptData=function(e){var t=it.noData[(e.nodeName+" ").toLowerCase()],n=+e.nodeType||1;return 1!==n&&9!==n?!1:!t||t!==!0&&e.getAttribute("classid")===t};var Nt=/^(?:\{[\w\W]*\}|\[[\w\W]*\])$/,Et=/([A-Z])/g;it.extend({cache:{},noData:{"applet ":!0,"embed ":!0,"object ":"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"},hasData:function(e){return e=e.nodeType?it.cache[e[it.expando]]:e[it.expando],!!e&&!l(e)},data:function(e,t,n){return c(e,t,n)},removeData:function(e,t){return d(e,t)},_data:function(e,t,n){return c(e,t,n,!0)},_removeData:function(e,t){return d(e,t,!0)}}),it.fn.extend({data:function(e,t){var n,r,i,o=this[0],a=o&&o.attributes;if(void 0===e){if(this.length&&(i=it.data(o),1===o.nodeType&&!it._data(o,"parsedAttrs"))){for(n=a.length;n--;)a[n]&&(r=a[n].name,0===r.indexOf("data-")&&(r=it.camelCase(r.slice(5)),u(o,r,i[r])));it._data(o,"parsedAttrs",!0)}return i}return"object"==typeof e?this.each(function(){it.data(this,e)}):arguments.length>1?this.each(function(){it.data(this,e,t)}):o?u(o,e,it.data(o,e)):void 0},removeData:function(e){return this.each(function(){it.removeData(this,e)})}}),it.extend({queue:function(e,t,n){var r;return e?(t=(t||"fx")+"queue",r=it._data(e,t),n&&(!r||it.isArray(n)?r=it._data(e,t,it.makeArray(n)):r.push(n)),r||[]):void 0},dequeue:function(e,t){t=t||"fx";var n=it.queue(e,t),r=n.length,i=n.shift(),o=it._queueHooks(e,t),a=function(){it.dequeue(e,t)};"inprogress"===i&&(i=n.shift(),r--),i&&("fx"===t&&n.unshift("inprogress"),delete o.stop,i.call(e,a,o)),!r&&o&&o.empty.fire()},_queueHooks:function(e,t){var n=t+"queueHooks";return it._data(e,n)||it._data(e,n,{empty:it.Callbacks("once memory").add(function(){it._removeData(e,t+"queue"),it._removeData(e,n)})})}}),it.fn.extend({queue:function(e,t){var n=2;return"string"!=typeof e&&(t=e,e="fx",n--),arguments.length<n?it.queue(this[0],e):void 0===t?this:this.each(function(){var n=it.queue(this,e,t);it._queueHooks(this,e),"fx"===e&&"inprogress"!==n[0]&&it.dequeue(this,e)})},dequeue:function(e){return this.each(function(){it.dequeue(this,e)})},clearQueue:function(e){return this.queue(e||"fx",[])},promise:function(e,t){var n,r=1,i=it.Deferred(),o=this,a=this.length,s=function(){--r||i.resolveWith(o,[o])};for("string"!=typeof e&&(t=e,e=void 0),e=e||"fx";a--;)n=it._data(o[a],e+"queueHooks"),n&&n.empty&&(r++,n.empty.add(s));return s(),i.promise(t)}});var kt=/[+-]?(?:\d*\.|)\d+(?:[eE][+-]?\d+|)/.source,St=["Top","Right","Bottom","Left"],At=function(e,t){return e=t||e,"none"===it.css(e,"display")||!it.contains(e.ownerDocument,e)},Dt=it.access=function(e,t,n,r,i,o,a){var s=0,u=e.length,l=null==n;if("object"===it.type(n)){i=!0;for(s in n)it.access(e,t,s,n[s],!0,o,a)}else if(void 0!==r&&(i=!0,it.isFunction(r)||(a=!0),l&&(a?(t.call(e,r),t=null):(l=t,t=function(e,t,n){return l.call(it(e),n)})),t))for(;u>s;s++)t(e[s],n,a?r:r.call(e[s],s,t(e[s],n)));return i?e:l?t.call(e):u?t(e[0],n):o},jt=/^(?:checkbox|radio)$/i;!function(){var e=ht.createElement("input"),t=ht.createElement("div"),n=ht.createDocumentFragment();if(t.innerHTML=" <link/><table></table><a href='/a'>a</a><input type='checkbox'/>",nt.leadingWhitespace=3===t.firstChild.nodeType,nt.tbody=!t.getElementsByTagName("tbody").length,nt.htmlSerialize=!!t.getElementsByTagName("link").length,nt.html5Clone="<:nav></:nav>"!==ht.createElement("nav").cloneNode(!0).outerHTML,e.type="checkbox",e.checked=!0,n.appendChild(e),nt.appendChecked=e.checked,t.innerHTML="<textarea>x</textarea>",nt.noCloneChecked=!!t.cloneNode(!0).lastChild.defaultValue,n.appendChild(t),t.innerHTML="<input type='radio' checked='checked' name='t'/>",nt.checkClone=t.cloneNode(!0).cloneNode(!0).lastChild.checked,nt.noCloneEvent=!0,t.attachEvent&&(t.attachEvent("onclick",function(){nt.noCloneEvent=!1}),t.cloneNode(!0).click()),null==nt.deleteExpando){nt.deleteExpando=!0;try{delete t.test}catch(r){nt.deleteExpando=!1}}}(),function(){var t,n,r=ht.createElement("div");for(t in{submit:!0,change:!0,focusin:!0})n="on"+t,(nt[t+"Bubbles"]=n in e)||(r.setAttribute(n,"t"),nt[t+"Bubbles"]=r.attributes[n].expando===!1);r=null}();var Lt=/^(?:input|select|textarea)$/i,Ht=/^key/,qt=/^(?:mouse|pointer|contextmenu)|click/,_t=/^(?:focusinfocus|focusoutblur)$/,Mt=/^([^.]*)(?:\.(.+)|)$/;it.event={global:{},add:function(e,t,n,r,i){var o,a,s,u,l,c,d,f,p,h,m,g=it._data(e);if(g){for(n.handler&&(u=n,n=u.handler,i=u.selector),n.guid||(n.guid=it.guid++),(a=g.events)||(a=g.events={}),(c=g.handle)||(c=g.handle=function(e){return typeof it===Tt||e&&it.event.triggered===e.type?void 0:it.event.dispatch.apply(c.elem,arguments)},c.elem=e),t=(t||"").match(bt)||[""],s=t.length;s--;)o=Mt.exec(t[s])||[],p=m=o[1],h=(o[2]||"").split(".").sort(),p&&(l=it.event.special[p]||{},p=(i?l.delegateType:l.bindType)||p,l=it.event.special[p]||{},d=it.extend({type:p,origType:m,data:r,handler:n,guid:n.guid,selector:i,needsContext:i&&it.expr.match.needsContext.test(i),namespace:h.join(".")},u),(f=a[p])||(f=a[p]=[],f.delegateCount=0,l.setup&&l.setup.call(e,r,h,c)!==!1||(e.addEventListener?e.addEventListener(p,c,!1):e.attachEvent&&e.attachEvent("on"+p,c))),l.add&&(l.add.call(e,d),d.handler.guid||(d.handler.guid=n.guid)),i?f.splice(f.delegateCount++,0,d):f.push(d),it.event.global[p]=!0);e=null}},remove:function(e,t,n,r,i){var o,a,s,u,l,c,d,f,p,h,m,g=it.hasData(e)&&it._data(e);if(g&&(c=g.events)){for(t=(t||"").match(bt)||[""],l=t.length;l--;)if(s=Mt.exec(t[l])||[],p=m=s[1],h=(s[2]||"").split(".").sort(),p){for(d=it.event.special[p]||{},p=(r?d.delegateType:d.bindType)||p,f=c[p]||[],s=s[2]&&new RegExp("(^|\\.)"+h.join("\\.(?:.*\\.|)")+"(\\.|$)"),u=o=f.length;o--;)a=f[o],!i&&m!==a.origType||n&&n.guid!==a.guid||s&&!s.test(a.namespace)||r&&r!==a.selector&&("**"!==r||!a.selector)||(f.splice(o,1),a.selector&&f.delegateCount--,d.remove&&d.remove.call(e,a));u&&!f.length&&(d.teardown&&d.teardown.call(e,h,g.handle)!==!1||it.removeEvent(e,p,g.handle),delete c[p])}else for(p in c)it.event.remove(e,p+t[l],n,r,!0);it.isEmptyObject(c)&&(delete g.handle,it._removeData(e,"events"))}},trigger:function(t,n,r,i){var o,a,s,u,l,c,d,f=[r||ht],p=tt.call(t,"type")?t.type:t,h=tt.call(t,"namespace")?t.namespace.split("."):[];if(s=c=r=r||ht,3!==r.nodeType&&8!==r.nodeType&&!_t.test(p+it.event.triggered)&&(p.indexOf(".")>=0&&(h=p.split("."),p=h.shift(),h.sort()),a=p.indexOf(":")<0&&"on"+p,t=t[it.expando]?t:new it.Event(p,"object"==typeof t&&t),t.isTrigger=i?2:3,t.namespace=h.join("."),t.namespace_re=t.namespace?new RegExp("(^|\\.)"+h.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,t.result=void 0,t.target||(t.target=r),n=null==n?[t]:it.makeArray(n,[t]),l=it.event.special[p]||{},i||!l.trigger||l.trigger.apply(r,n)!==!1)){if(!i&&!l.noBubble&&!it.isWindow(r)){for(u=l.delegateType||p,_t.test(u+p)||(s=s.parentNode);s;s=s.parentNode)f.push(s),c=s;c===(r.ownerDocument||ht)&&f.push(c.defaultView||c.parentWindow||e)}for(d=0;(s=f[d++])&&!t.isPropagationStopped();)t.type=d>1?u:l.bindType||p,o=(it._data(s,"events")||{})[t.type]&&it._data(s,"handle"),o&&o.apply(s,n),o=a&&s[a],o&&o.apply&&it.acceptData(s)&&(t.result=o.apply(s,n),t.result===!1&&t.preventDefault());if(t.type=p,!i&&!t.isDefaultPrevented()&&(!l._default||l._default.apply(f.pop(),n)===!1)&&it.acceptData(r)&&a&&r[p]&&!it.isWindow(r)){c=r[a],c&&(r[a]=null),it.event.triggered=p;try{r[p]()}catch(m){}it.event.triggered=void 0,c&&(r[a]=c)}return t.result}},dispatch:function(e){e=it.event.fix(e);var t,n,r,i,o,a=[],s=Y.call(arguments),u=(it._data(this,"events")||{})[e.type]||[],l=it.event.special[e.type]||{};if(s[0]=e,e.delegateTarget=this,!l.preDispatch||l.preDispatch.call(this,e)!==!1){for(a=it.event.handlers.call(this,e,u),t=0;(i=a[t++])&&!e.isPropagationStopped();)for(e.currentTarget=i.elem,o=0;(r=i.handlers[o++])&&!e.isImmediatePropagationStopped();)(!e.namespace_re||e.namespace_re.test(r.namespace))&&(e.handleObj=r,e.data=r.data,n=((it.event.special[r.origType]||{}).handle||r.handler).apply(i.elem,s),void 0!==n&&(e.result=n)===!1&&(e.preventDefault(),e.stopPropagation()));return l.postDispatch&&l.postDispatch.call(this,e),e.result}},handlers:function(e,t){var n,r,i,o,a=[],s=t.delegateCount,u=e.target;if(s&&u.nodeType&&(!e.button||"click"!==e.type))for(;u!=this;u=u.parentNode||this)if(1===u.nodeType&&(u.disabled!==!0||"click"!==e.type)){for(i=[],o=0;s>o;o++)r=t[o],n=r.selector+" ",void 0===i[n]&&(i[n]=r.needsContext?it(n,this).index(u)>=0:it.find(n,this,null,[u]).length),i[n]&&i.push(r);i.length&&a.push({elem:u,handlers:i})}return s<t.length&&a.push({elem:this,handlers:t.slice(s)}),a},fix:function(e){if(e[it.expando])return e;var t,n,r,i=e.type,o=e,a=this.fixHooks[i];for(a||(this.fixHooks[i]=a=qt.test(i)?this.mouseHooks:Ht.test(i)?this.keyHooks:{}),r=a.props?this.props.concat(a.props):this.props,e=new it.Event(o),t=r.length;t--;)n=r[t],e[n]=o[n];return e.target||(e.target=o.srcElement||ht),3===e.target.nodeType&&(e.target=e.target.parentNode),e.metaKey=!!e.metaKey,a.filter?a.filter(e,o):e},props:"altKey bubbles cancelable ctrlKey currentTarget eventPhase metaKey relatedTarget shiftKey target timeStamp view which".split(" "),fixHooks:{},keyHooks:{props:"char charCode key keyCode".split(" "),filter:function(e,t){return null==e.which&&(e.which=null!=t.charCode?t.charCode:t.keyCode),e}},mouseHooks:{props:"button buttons clientX clientY fromElement offsetX offsetY pageX pageY screenX screenY toElement".split(" "),filter:function(e,t){var n,r,i,o=t.button,a=t.fromElement;return null==e.pageX&&null!=t.clientX&&(r=e.target.ownerDocument||ht,i=r.documentElement,n=r.body,e.pageX=t.clientX+(i&&i.scrollLeft||n&&n.scrollLeft||0)-(i&&i.clientLeft||n&&n.clientLeft||0),e.pageY=t.clientY+(i&&i.scrollTop||n&&n.scrollTop||0)-(i&&i.clientTop||n&&n.clientTop||0)),!e.relatedTarget&&a&&(e.relatedTarget=a===e.target?t.toElement:a),e.which||void 0===o||(e.which=1&o?1:2&o?3:4&o?2:0),e}},special:{load:{noBubble:!0},focus:{trigger:function(){if(this!==h()&&this.focus)try{return this.focus(),!1}catch(e){}},delegateType:"focusin"},blur:{trigger:function(){return this===h()&&this.blur?(this.blur(),!1):void 0},delegateType:"focusout"},click:{trigger:function(){return it.nodeName(this,"input")&&"checkbox"===this.type&&this.click?(this.click(),!1):void 0},_default:function(e){return it.nodeName(e.target,"a")}},beforeunload:{postDispatch:function(e){void 0!==e.result&&e.originalEvent&&(e.originalEvent.returnValue=e.result)}}},simulate:function(e,t,n,r){var i=it.extend(new it.Event,n,{type:e,isSimulated:!0,originalEvent:{}});r?it.event.trigger(i,null,t):it.event.dispatch.call(t,i),i.isDefaultPrevented()&&n.preventDefault()}},it.removeEvent=ht.removeEventListener?function(e,t,n){e.removeEventListener&&e.removeEventListener(t,n,!1)}:function(e,t,n){var r="on"+t;e.detachEvent&&(typeof e[r]===Tt&&(e[r]=null),e.detachEvent(r,n))},it.Event=function(e,t){return this instanceof it.Event?(e&&e.type?(this.originalEvent=e,this.type=e.type,this.isDefaultPrevented=e.defaultPrevented||void 0===e.defaultPrevented&&e.returnValue===!1?f:p):this.type=e,t&&it.extend(this,t),this.timeStamp=e&&e.timeStamp||it.now(),void(this[it.expando]=!0)):new it.Event(e,t)},it.Event.prototype={isDefaultPrevented:p,isPropagationStopped:p,isImmediatePropagationStopped:p,preventDefault:function(){var e=this.originalEvent;this.isDefaultPrevented=f,e&&(e.preventDefault?e.preventDefault():e.returnValue=!1)},stopPropagation:function(){var e=this.originalEvent;this.isPropagationStopped=f,e&&(e.stopPropagation&&e.stopPropagation(),e.cancelBubble=!0)},stopImmediatePropagation:function(){var e=this.originalEvent;this.isImmediatePropagationStopped=f,e&&e.stopImmediatePropagation&&e.stopImmediatePropagation(),this.stopPropagation()}},it.each({mouseenter:"mouseover",mouseleave:"mouseout",pointerenter:"pointerover",pointerleave:"pointerout"},function(e,t){it.event.special[e]={delegateType:t,bindType:t,handle:function(e){var n,r=this,i=e.relatedTarget,o=e.handleObj;return(!i||i!==r&&!it.contains(r,i))&&(e.type=o.origType,n=o.handler.apply(this,arguments),e.type=t),n}}}),nt.submitBubbles||(it.event.special.submit={setup:function(){return it.nodeName(this,"form")?!1:void it.event.add(this,"click._submit keypress._submit",function(e){var t=e.target,n=it.nodeName(t,"input")||it.nodeName(t,"button")?t.form:void 0;n&&!it._data(n,"submitBubbles")&&(it.event.add(n,"submit._submit",function(e){e._submit_bubble=!0}),it._data(n,"submitBubbles",!0))})},postDispatch:function(e){e._submit_bubble&&(delete e._submit_bubble,this.parentNode&&!e.isTrigger&&it.event.simulate("submit",this.parentNode,e,!0))},teardown:function(){return it.nodeName(this,"form")?!1:void it.event.remove(this,"._submit")}}),nt.changeBubbles||(it.event.special.change={setup:function(){return Lt.test(this.nodeName)?(("checkbox"===this.type||"radio"===this.type)&&(it.event.add(this,"propertychange._change",function(e){"checked"===e.originalEvent.propertyName&&(this._just_changed=!0)}),it.event.add(this,"click._change",function(e){this._just_changed&&!e.isTrigger&&(this._just_changed=!1),it.event.simulate("change",this,e,!0)})),!1):void it.event.add(this,"beforeactivate._change",function(e){var t=e.target;Lt.test(t.nodeName)&&!it._data(t,"changeBubbles")&&(it.event.add(t,"change._change",function(e){!this.parentNode||e.isSimulated||e.isTrigger||it.event.simulate("change",this.parentNode,e,!0)}),it._data(t,"changeBubbles",!0))})},handle:function(e){var t=e.target;return this!==t||e.isSimulated||e.isTrigger||"radio"!==t.type&&"checkbox"!==t.type?e.handleObj.handler.apply(this,arguments):void 0},teardown:function(){return it.event.remove(this,"._change"),!Lt.test(this.nodeName)}}),nt.focusinBubbles||it.each({focus:"focusin",blur:"focusout"},function(e,t){var n=function(e){it.event.simulate(t,e.target,it.event.fix(e),!0)};it.event.special[t]={setup:function(){var r=this.ownerDocument||this,i=it._data(r,t);i||r.addEventListener(e,n,!0),it._data(r,t,(i||0)+1)},teardown:function(){var r=this.ownerDocument||this,i=it._data(r,t)-1;i?it._data(r,t,i):(r.removeEventListener(e,n,!0),it._removeData(r,t))}}}),it.fn.extend({on:function(e,t,n,r,i){var o,a;if("object"==typeof e){"string"!=typeof t&&(n=n||t,t=void 0);for(o in e)this.on(o,t,n,e[o],i);return this}if(null==n&&null==r?(r=t,n=t=void 0):null==r&&("string"==typeof t?(r=n,n=void 0):(r=n,n=t,t=void 0)),r===!1)r=p;else if(!r)return this;return 1===i&&(a=r,r=function(e){return it().off(e),a.apply(this,arguments)},r.guid=a.guid||(a.guid=it.guid++)),this.each(function(){it.event.add(this,e,r,n,t)})},one:function(e,t,n,r){return this.on(e,t,n,r,1)},off:function(e,t,n){var r,i;if(e&&e.preventDefault&&e.handleObj)return r=e.handleObj,it(e.delegateTarget).off(r.namespace?r.origType+"."+r.namespace:r.origType,r.selector,r.handler),this;if("object"==typeof e){for(i in e)this.off(i,t,e[i]);return this}return(t===!1||"function"==typeof t)&&(n=t,t=void 0),n===!1&&(n=p),this.each(function(){it.event.remove(this,e,n,t)})},trigger:function(e,t){return this.each(function(){it.event.trigger(e,t,this)})},triggerHandler:function(e,t){var n=this[0];return n?it.event.trigger(e,t,n,!0):void 0}});var Ft="abbr|article|aside|audio|bdi|canvas|data|datalist|details|figcaption|figure|footer|header|hgroup|mark|meter|nav|output|progress|section|summary|time|video",Ot=/ jQuery\d+="(?:null|\d+)"/g,Bt=new RegExp("<(?:"+Ft+")[\\s/>]","i"),Pt=/^\s+/,Rt=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:]+)[^>]*)\/>/gi,Wt=/<([\w:]+)/,$t=/<tbody/i,zt=/<|&#?\w+;/,It=/<(?:script|style|link)/i,Xt=/checked\s*(?:[^=]|=\s*.checked.)/i,Ut=/^$|\/(?:java|ecma)script/i,Vt=/^true\/(.*)/,Jt=/^\s*<!(?:\[CDATA\[|--)|(?:\]\]|--)>\s*$/g,Yt={option:[1,"<select multiple='multiple'>","</select>"],legend:[1,"<fieldset>","</fieldset>"],area:[1,"<map>","</map>"],param:[1,"<object>","</object>"],thead:[1,"<table>","</table>"],tr:[2,"<table><tbody>","</tbody></table>"],col:[2,"<table><tbody></tbody><colgroup>","</colgroup></table>"],td:[3,"<table><tbody><tr>","</tr></tbody></table>"],_default:nt.htmlSerialize?[0,"",""]:[1,"X<div>","</div>"]},Qt=m(ht),Gt=Qt.appendChild(ht.createElement("div"));Yt.optgroup=Yt.option,Yt.tbody=Yt.tfoot=Yt.colgroup=Yt.caption=Yt.thead,Yt.th=Yt.td,it.extend({clone:function(e,t,n){var r,i,o,a,s,u=it.contains(e.ownerDocument,e);if(nt.html5Clone||it.isXMLDoc(e)||!Bt.test("<"+e.nodeName+">")?o=e.cloneNode(!0):(Gt.innerHTML=e.outerHTML,Gt.removeChild(o=Gt.firstChild)),!(nt.noCloneEvent&&nt.noCloneChecked||1!==e.nodeType&&11!==e.nodeType||it.isXMLDoc(e)))for(r=g(o),s=g(e),a=0;null!=(i=s[a]);++a)r[a]&&C(i,r[a]);if(t)if(n)for(s=s||g(e),r=r||g(o),a=0;null!=(i=s[a]);a++)T(i,r[a]);else T(e,o);return r=g(o,"script"),r.length>0&&w(r,!u&&g(e,"script")),r=s=i=null,o},buildFragment:function(e,t,n,r){for(var i,o,a,s,u,l,c,d=e.length,f=m(t),p=[],h=0;d>h;h++)if(o=e[h],o||0===o)if("object"===it.type(o))it.merge(p,o.nodeType?[o]:o);else if(zt.test(o)){for(s=s||f.appendChild(t.createElement("div")),u=(Wt.exec(o)||["",""])[1].toLowerCase(),c=Yt[u]||Yt._default,s.innerHTML=c[1]+o.replace(Rt,"<$1></$2>")+c[2],i=c[0];i--;)s=s.lastChild;if(!nt.leadingWhitespace&&Pt.test(o)&&p.push(t.createTextNode(Pt.exec(o)[0])),!nt.tbody)for(o="table"!==u||$t.test(o)?"<table>"!==c[1]||$t.test(o)?0:s:s.firstChild,i=o&&o.childNodes.length;i--;)it.nodeName(l=o.childNodes[i],"tbody")&&!l.childNodes.length&&o.removeChild(l);for(it.merge(p,s.childNodes),s.textContent="";s.firstChild;)s.removeChild(s.firstChild);s=f.lastChild}else p.push(t.createTextNode(o));for(s&&f.removeChild(s),nt.appendChecked||it.grep(g(p,"input"),v),h=0;o=p[h++];)if((!r||-1===it.inArray(o,r))&&(a=it.contains(o.ownerDocument,o),s=g(f.appendChild(o),"script"),a&&w(s),n))for(i=0;o=s[i++];)Ut.test(o.type||"")&&n.push(o);return s=null,f},cleanData:function(e,t){for(var n,r,i,o,a=0,s=it.expando,u=it.cache,l=nt.deleteExpando,c=it.event.special;null!=(n=e[a]);a++)if((t||it.acceptData(n))&&(i=n[s],o=i&&u[i])){if(o.events)for(r in o.events)c[r]?it.event.remove(n,r):it.removeEvent(n,r,o.handle);u[i]&&(delete u[i],l?delete n[s]:typeof n.removeAttribute!==Tt?n.removeAttribute(s):n[s]=null,J.push(i))}}}),it.fn.extend({text:function(e){return Dt(this,function(e){return void 0===e?it.text(this):this.empty().append((this[0]&&this[0].ownerDocument||ht).createTextNode(e))},null,e,arguments.length)},append:function(){return this.domManip(arguments,function(e){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var t=y(this,e);t.appendChild(e)}})},prepend:function(){return this.domManip(arguments,function(e){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var t=y(this,e);t.insertBefore(e,t.firstChild)}})},before:function(){return this.domManip(arguments,function(e){this.parentNode&&this.parentNode.insertBefore(e,this)})},after:function(){return this.domManip(arguments,function(e){this.parentNode&&this.parentNode.insertBefore(e,this.nextSibling)})},remove:function(e,t){for(var n,r=e?it.filter(e,this):this,i=0;null!=(n=r[i]);i++)t||1!==n.nodeType||it.cleanData(g(n)),n.parentNode&&(t&&it.contains(n.ownerDocument,n)&&w(g(n,"script")),n.parentNode.removeChild(n));return this},empty:function(){for(var e,t=0;null!=(e=this[t]);t++){for(1===e.nodeType&&it.cleanData(g(e,!1));e.firstChild;)e.removeChild(e.firstChild);e.options&&it.nodeName(e,"select")&&(e.options.length=0)}return this},clone:function(e,t){return e=null==e?!1:e,t=null==t?e:t,this.map(function(){return it.clone(this,e,t)})},html:function(e){return Dt(this,function(e){var t=this[0]||{},n=0,r=this.length;if(void 0===e)return 1===t.nodeType?t.innerHTML.replace(Ot,""):void 0;if(!("string"!=typeof e||It.test(e)||!nt.htmlSerialize&&Bt.test(e)||!nt.leadingWhitespace&&Pt.test(e)||Yt[(Wt.exec(e)||["",""])[1].toLowerCase()])){e=e.replace(Rt,"<$1></$2>");try{for(;r>n;n++)t=this[n]||{},1===t.nodeType&&(it.cleanData(g(t,!1)),t.innerHTML=e);t=0}catch(i){}}t&&this.empty().append(e)},null,e,arguments.length)},replaceWith:function(){var e=arguments[0];return this.domManip(arguments,function(t){e=this.parentNode,it.cleanData(g(this)),e&&e.replaceChild(t,this)}),e&&(e.length||e.nodeType)?this:this.remove()},detach:function(e){return this.remove(e,!0)},domManip:function(e,t){e=Q.apply([],e);var n,r,i,o,a,s,u=0,l=this.length,c=this,d=l-1,f=e[0],p=it.isFunction(f);if(p||l>1&&"string"==typeof f&&!nt.checkClone&&Xt.test(f))return this.each(function(n){var r=c.eq(n);p&&(e[0]=f.call(this,n,r.html())),r.domManip(e,t)});if(l&&(s=it.buildFragment(e,this[0].ownerDocument,!1,this),n=s.firstChild,1===s.childNodes.length&&(s=n),n)){for(o=it.map(g(s,"script"),b),i=o.length;l>u;u++)r=s,u!==d&&(r=it.clone(r,!0,!0),i&&it.merge(o,g(r,"script"))),t.call(this[u],r,u);if(i)for(a=o[o.length-1].ownerDocument,it.map(o,x),u=0;i>u;u++)r=o[u],Ut.test(r.type||"")&&!it._data(r,"globalEval")&&it.contains(a,r)&&(r.src?it._evalUrl&&it._evalUrl(r.src):it.globalEval((r.text||r.textContent||r.innerHTML||"").replace(Jt,"")));s=n=null}return this}}),it.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(e,t){it.fn[e]=function(e){for(var n,r=0,i=[],o=it(e),a=o.length-1;a>=r;r++)n=r===a?this:this.clone(!0),it(o[r])[t](n),G.apply(i,n.get());return this.pushStack(i)}});var Kt,Zt={};!function(){var e;nt.shrinkWrapBlocks=function(){if(null!=e)return e;e=!1;var t,n,r;return n=ht.getElementsByTagName("body")[0],n&&n.style?(t=ht.createElement("div"),r=ht.createElement("div"),r.style.cssText="position:absolute;border:0;width:0;height:0;top:0;left:-9999px",n.appendChild(r).appendChild(t),typeof t.style.zoom!==Tt&&(t.style.cssText="-webkit-box-sizing:content-box;-moz-box-sizing:content-box;box-sizing:content-box;display:block;margin:0;border:0;padding:1px;width:1px;zoom:1",t.appendChild(ht.createElement("div")).style.width="5px",e=3!==t.offsetWidth),n.removeChild(r),e):void 0}}();var en=/^margin/,tn=new RegExp("^("+kt+")(?!px)[a-z%]+$","i"),nn,rn,on=/^(top|right|bottom|left)$/;e.getComputedStyle?(nn=function(t){return t.ownerDocument.defaultView.opener?t.ownerDocument.defaultView.getComputedStyle(t,null):e.getComputedStyle(t,null)},rn=function(e,t,n){var r,i,o,a,s=e.style;return n=n||nn(e),a=n?n.getPropertyValue(t)||n[t]:void 0,n&&(""!==a||it.contains(e.ownerDocument,e)||(a=it.style(e,t)),tn.test(a)&&en.test(t)&&(r=s.width,i=s.minWidth,o=s.maxWidth,s.minWidth=s.maxWidth=s.width=a,a=n.width,s.width=r,s.minWidth=i,s.maxWidth=o)),void 0===a?a:a+""
+}):ht.documentElement.currentStyle&&(nn=function(e){return e.currentStyle},rn=function(e,t,n){var r,i,o,a,s=e.style;return n=n||nn(e),a=n?n[t]:void 0,null==a&&s&&s[t]&&(a=s[t]),tn.test(a)&&!on.test(t)&&(r=s.left,i=e.runtimeStyle,o=i&&i.left,o&&(i.left=e.currentStyle.left),s.left="fontSize"===t?"1em":a,a=s.pixelLeft+"px",s.left=r,o&&(i.left=o)),void 0===a?a:a+""||"auto"}),function(){function t(){var t,n,r,i;n=ht.getElementsByTagName("body")[0],n&&n.style&&(t=ht.createElement("div"),r=ht.createElement("div"),r.style.cssText="position:absolute;border:0;width:0;height:0;top:0;left:-9999px",n.appendChild(r).appendChild(t),t.style.cssText="-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;display:block;margin-top:1%;top:1%;border:1px;padding:1px;width:4px;position:absolute",o=a=!1,u=!0,e.getComputedStyle&&(o="1%"!==(e.getComputedStyle(t,null)||{}).top,a="4px"===(e.getComputedStyle(t,null)||{width:"4px"}).width,i=t.appendChild(ht.createElement("div")),i.style.cssText=t.style.cssText="-webkit-box-sizing:content-box;-moz-box-sizing:content-box;box-sizing:content-box;display:block;margin:0;border:0;padding:0",i.style.marginRight=i.style.width="0",t.style.width="1px",u=!parseFloat((e.getComputedStyle(i,null)||{}).marginRight),t.removeChild(i)),t.innerHTML="<table><tr><td></td><td>t</td></tr></table>",i=t.getElementsByTagName("td"),i[0].style.cssText="margin:0;border:0;padding:0;display:none",s=0===i[0].offsetHeight,s&&(i[0].style.display="",i[1].style.display="none",s=0===i[0].offsetHeight),n.removeChild(r))}var n,r,i,o,a,s,u;n=ht.createElement("div"),n.innerHTML=" <link/><table></table><a href='/a'>a</a><input type='checkbox'/>",i=n.getElementsByTagName("a")[0],r=i&&i.style,r&&(r.cssText="float:left;opacity:.5",nt.opacity="0.5"===r.opacity,nt.cssFloat=!!r.cssFloat,n.style.backgroundClip="content-box",n.cloneNode(!0).style.backgroundClip="",nt.clearCloneStyle="content-box"===n.style.backgroundClip,nt.boxSizing=""===r.boxSizing||""===r.MozBoxSizing||""===r.WebkitBoxSizing,it.extend(nt,{reliableHiddenOffsets:function(){return null==s&&t(),s},boxSizingReliable:function(){return null==a&&t(),a},pixelPosition:function(){return null==o&&t(),o},reliableMarginRight:function(){return null==u&&t(),u}}))}(),it.swap=function(e,t,n,r){var i,o,a={};for(o in t)a[o]=e.style[o],e.style[o]=t[o];i=n.apply(e,r||[]);for(o in t)e.style[o]=a[o];return i};var an=/alpha\([^)]*\)/i,sn=/opacity\s*=\s*([^)]*)/,un=/^(none|table(?!-c[ea]).+)/,ln=new RegExp("^("+kt+")(.*)$","i"),cn=new RegExp("^([+-])=("+kt+")","i"),dn={position:"absolute",visibility:"hidden",display:"block"},fn={letterSpacing:"0",fontWeight:"400"},pn=["Webkit","O","Moz","ms"];it.extend({cssHooks:{opacity:{get:function(e,t){if(t){var n=rn(e,"opacity");return""===n?"1":n}}}},cssNumber:{columnCount:!0,fillOpacity:!0,flexGrow:!0,flexShrink:!0,fontWeight:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,widows:!0,zIndex:!0,zoom:!0},cssProps:{"float":nt.cssFloat?"cssFloat":"styleFloat"},style:function(e,t,n,r){if(e&&3!==e.nodeType&&8!==e.nodeType&&e.style){var i,o,a,s=it.camelCase(t),u=e.style;if(t=it.cssProps[s]||(it.cssProps[s]=S(u,s)),a=it.cssHooks[t]||it.cssHooks[s],void 0===n)return a&&"get"in a&&void 0!==(i=a.get(e,!1,r))?i:u[t];if(o=typeof n,"string"===o&&(i=cn.exec(n))&&(n=(i[1]+1)*i[2]+parseFloat(it.css(e,t)),o="number"),null!=n&&n===n&&("number"!==o||it.cssNumber[s]||(n+="px"),nt.clearCloneStyle||""!==n||0!==t.indexOf("background")||(u[t]="inherit"),!(a&&"set"in a&&void 0===(n=a.set(e,n,r)))))try{u[t]=n}catch(l){}}},css:function(e,t,n,r){var i,o,a,s=it.camelCase(t);return t=it.cssProps[s]||(it.cssProps[s]=S(e.style,s)),a=it.cssHooks[t]||it.cssHooks[s],a&&"get"in a&&(o=a.get(e,!0,n)),void 0===o&&(o=rn(e,t,r)),"normal"===o&&t in fn&&(o=fn[t]),""===n||n?(i=parseFloat(o),n===!0||it.isNumeric(i)?i||0:o):o}}),it.each(["height","width"],function(e,t){it.cssHooks[t]={get:function(e,n,r){return n?un.test(it.css(e,"display"))&&0===e.offsetWidth?it.swap(e,dn,function(){return L(e,t,r)}):L(e,t,r):void 0},set:function(e,n,r){var i=r&&nn(e);return D(e,n,r?j(e,t,r,nt.boxSizing&&"border-box"===it.css(e,"boxSizing",!1,i),i):0)}}}),nt.opacity||(it.cssHooks.opacity={get:function(e,t){return sn.test((t&&e.currentStyle?e.currentStyle.filter:e.style.filter)||"")?.01*parseFloat(RegExp.$1)+"":t?"1":""},set:function(e,t){var n=e.style,r=e.currentStyle,i=it.isNumeric(t)?"alpha(opacity="+100*t+")":"",o=r&&r.filter||n.filter||"";n.zoom=1,(t>=1||""===t)&&""===it.trim(o.replace(an,""))&&n.removeAttribute&&(n.removeAttribute("filter"),""===t||r&&!r.filter)||(n.filter=an.test(o)?o.replace(an,i):o+" "+i)}}),it.cssHooks.marginRight=k(nt.reliableMarginRight,function(e,t){return t?it.swap(e,{display:"inline-block"},rn,[e,"marginRight"]):void 0}),it.each({margin:"",padding:"",border:"Width"},function(e,t){it.cssHooks[e+t]={expand:function(n){for(var r=0,i={},o="string"==typeof n?n.split(" "):[n];4>r;r++)i[e+St[r]+t]=o[r]||o[r-2]||o[0];return i}},en.test(e)||(it.cssHooks[e+t].set=D)}),it.fn.extend({css:function(e,t){return Dt(this,function(e,t,n){var r,i,o={},a=0;if(it.isArray(t)){for(r=nn(e),i=t.length;i>a;a++)o[t[a]]=it.css(e,t[a],!1,r);return o}return void 0!==n?it.style(e,t,n):it.css(e,t)},e,t,arguments.length>1)},show:function(){return A(this,!0)},hide:function(){return A(this)},toggle:function(e){return"boolean"==typeof e?e?this.show():this.hide():this.each(function(){At(this)?it(this).show():it(this).hide()})}}),it.Tween=H,H.prototype={constructor:H,init:function(e,t,n,r,i,o){this.elem=e,this.prop=n,this.easing=i||"swing",this.options=t,this.start=this.now=this.cur(),this.end=r,this.unit=o||(it.cssNumber[n]?"":"px")},cur:function(){var e=H.propHooks[this.prop];return e&&e.get?e.get(this):H.propHooks._default.get(this)},run:function(e){var t,n=H.propHooks[this.prop];return this.pos=t=this.options.duration?it.easing[this.easing](e,this.options.duration*e,0,1,this.options.duration):e,this.now=(this.end-this.start)*t+this.start,this.options.step&&this.options.step.call(this.elem,this.now,this),n&&n.set?n.set(this):H.propHooks._default.set(this),this}},H.prototype.init.prototype=H.prototype,H.propHooks={_default:{get:function(e){var t;return null==e.elem[e.prop]||e.elem.style&&null!=e.elem.style[e.prop]?(t=it.css(e.elem,e.prop,""),t&&"auto"!==t?t:0):e.elem[e.prop]},set:function(e){it.fx.step[e.prop]?it.fx.step[e.prop](e):e.elem.style&&(null!=e.elem.style[it.cssProps[e.prop]]||it.cssHooks[e.prop])?it.style(e.elem,e.prop,e.now+e.unit):e.elem[e.prop]=e.now}}},H.propHooks.scrollTop=H.propHooks.scrollLeft={set:function(e){e.elem.nodeType&&e.elem.parentNode&&(e.elem[e.prop]=e.now)}},it.easing={linear:function(e){return e},swing:function(e){return.5-Math.cos(e*Math.PI)/2}},it.fx=H.prototype.init,it.fx.step={};var hn,mn,gn=/^(?:toggle|show|hide)$/,vn=new RegExp("^(?:([+-])=|)("+kt+")([a-z%]*)$","i"),yn=/queueHooks$/,bn=[F],xn={"*":[function(e,t){var n=this.createTween(e,t),r=n.cur(),i=vn.exec(t),o=i&&i[3]||(it.cssNumber[e]?"":"px"),a=(it.cssNumber[e]||"px"!==o&&+r)&&vn.exec(it.css(n.elem,e)),s=1,u=20;if(a&&a[3]!==o){o=o||a[3],i=i||[],a=+r||1;do s=s||".5",a/=s,it.style(n.elem,e,a+o);while(s!==(s=n.cur()/r)&&1!==s&&--u)}return i&&(a=n.start=+a||+r||0,n.unit=o,n.end=i[1]?a+(i[1]+1)*i[2]:+i[2]),n}]};it.Animation=it.extend(B,{tweener:function(e,t){it.isFunction(e)?(t=e,e=["*"]):e=e.split(" ");for(var n,r=0,i=e.length;i>r;r++)n=e[r],xn[n]=xn[n]||[],xn[n].unshift(t)},prefilter:function(e,t){t?bn.unshift(e):bn.push(e)}}),it.speed=function(e,t,n){var r=e&&"object"==typeof e?it.extend({},e):{complete:n||!n&&t||it.isFunction(e)&&e,duration:e,easing:n&&t||t&&!it.isFunction(t)&&t};return r.duration=it.fx.off?0:"number"==typeof r.duration?r.duration:r.duration in it.fx.speeds?it.fx.speeds[r.duration]:it.fx.speeds._default,(null==r.queue||r.queue===!0)&&(r.queue="fx"),r.old=r.complete,r.complete=function(){it.isFunction(r.old)&&r.old.call(this),r.queue&&it.dequeue(this,r.queue)},r},it.fn.extend({fadeTo:function(e,t,n,r){return this.filter(At).css("opacity",0).show().end().animate({opacity:t},e,n,r)},animate:function(e,t,n,r){var i=it.isEmptyObject(e),o=it.speed(t,n,r),a=function(){var t=B(this,it.extend({},e),o);(i||it._data(this,"finish"))&&t.stop(!0)};return a.finish=a,i||o.queue===!1?this.each(a):this.queue(o.queue,a)},stop:function(e,t,n){var r=function(e){var t=e.stop;delete e.stop,t(n)};return"string"!=typeof e&&(n=t,t=e,e=void 0),t&&e!==!1&&this.queue(e||"fx",[]),this.each(function(){var t=!0,i=null!=e&&e+"queueHooks",o=it.timers,a=it._data(this);if(i)a[i]&&a[i].stop&&r(a[i]);else for(i in a)a[i]&&a[i].stop&&yn.test(i)&&r(a[i]);for(i=o.length;i--;)o[i].elem!==this||null!=e&&o[i].queue!==e||(o[i].anim.stop(n),t=!1,o.splice(i,1));(t||!n)&&it.dequeue(this,e)})},finish:function(e){return e!==!1&&(e=e||"fx"),this.each(function(){var t,n=it._data(this),r=n[e+"queue"],i=n[e+"queueHooks"],o=it.timers,a=r?r.length:0;for(n.finish=!0,it.queue(this,e,[]),i&&i.stop&&i.stop.call(this,!0),t=o.length;t--;)o[t].elem===this&&o[t].queue===e&&(o[t].anim.stop(!0),o.splice(t,1));for(t=0;a>t;t++)r[t]&&r[t].finish&&r[t].finish.call(this);delete n.finish})}}),it.each(["toggle","show","hide"],function(e,t){var n=it.fn[t];it.fn[t]=function(e,r,i){return null==e||"boolean"==typeof e?n.apply(this,arguments):this.animate(_(t,!0),e,r,i)}}),it.each({slideDown:_("show"),slideUp:_("hide"),slideToggle:_("toggle"),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"},fadeToggle:{opacity:"toggle"}},function(e,t){it.fn[e]=function(e,n,r){return this.animate(t,e,n,r)}}),it.timers=[],it.fx.tick=function(){var e,t=it.timers,n=0;for(hn=it.now();n<t.length;n++)e=t[n],e()||t[n]!==e||t.splice(n--,1);t.length||it.fx.stop(),hn=void 0},it.fx.timer=function(e){it.timers.push(e),e()?it.fx.start():it.timers.pop()},it.fx.interval=13,it.fx.start=function(){mn||(mn=setInterval(it.fx.tick,it.fx.interval))},it.fx.stop=function(){clearInterval(mn),mn=null},it.fx.speeds={slow:600,fast:200,_default:400},it.fn.delay=function(e,t){return e=it.fx?it.fx.speeds[e]||e:e,t=t||"fx",this.queue(t,function(t,n){var r=setTimeout(t,e);n.stop=function(){clearTimeout(r)}})},function(){var e,t,n,r,i;t=ht.createElement("div"),t.setAttribute("className","t"),t.innerHTML=" <link/><table></table><a href='/a'>a</a><input type='checkbox'/>",r=t.getElementsByTagName("a")[0],n=ht.createElement("select"),i=n.appendChild(ht.createElement("option")),e=t.getElementsByTagName("input")[0],r.style.cssText="top:1px",nt.getSetAttribute="t"!==t.className,nt.style=/top/.test(r.getAttribute("style")),nt.hrefNormalized="/a"===r.getAttribute("href"),nt.checkOn=!!e.value,nt.optSelected=i.selected,nt.enctype=!!ht.createElement("form").enctype,n.disabled=!0,nt.optDisabled=!i.disabled,e=ht.createElement("input"),e.setAttribute("value",""),nt.input=""===e.getAttribute("value"),e.value="t",e.setAttribute("type","radio"),nt.radioValue="t"===e.value}();var wn=/\r/g;it.fn.extend({val:function(e){var t,n,r,i=this[0];{if(arguments.length)return r=it.isFunction(e),this.each(function(n){var i;1===this.nodeType&&(i=r?e.call(this,n,it(this).val()):e,null==i?i="":"number"==typeof i?i+="":it.isArray(i)&&(i=it.map(i,function(e){return null==e?"":e+""})),t=it.valHooks[this.type]||it.valHooks[this.nodeName.toLowerCase()],t&&"set"in t&&void 0!==t.set(this,i,"value")||(this.value=i))});if(i)return t=it.valHooks[i.type]||it.valHooks[i.nodeName.toLowerCase()],t&&"get"in t&&void 0!==(n=t.get(i,"value"))?n:(n=i.value,"string"==typeof n?n.replace(wn,""):null==n?"":n)}}}),it.extend({valHooks:{option:{get:function(e){var t=it.find.attr(e,"value");return null!=t?t:it.trim(it.text(e))}},select:{get:function(e){for(var t,n,r=e.options,i=e.selectedIndex,o="select-one"===e.type||0>i,a=o?null:[],s=o?i+1:r.length,u=0>i?s:o?i:0;s>u;u++)if(n=r[u],!(!n.selected&&u!==i||(nt.optDisabled?n.disabled:null!==n.getAttribute("disabled"))||n.parentNode.disabled&&it.nodeName(n.parentNode,"optgroup"))){if(t=it(n).val(),o)return t;a.push(t)}return a},set:function(e,t){for(var n,r,i=e.options,o=it.makeArray(t),a=i.length;a--;)if(r=i[a],it.inArray(it.valHooks.option.get(r),o)>=0)try{r.selected=n=!0}catch(s){r.scrollHeight}else r.selected=!1;return n||(e.selectedIndex=-1),i}}}}),it.each(["radio","checkbox"],function(){it.valHooks[this]={set:function(e,t){return it.isArray(t)?e.checked=it.inArray(it(e).val(),t)>=0:void 0}},nt.checkOn||(it.valHooks[this].get=function(e){return null===e.getAttribute("value")?"on":e.value})});var Tn,Cn,Nn=it.expr.attrHandle,En=/^(?:checked|selected)$/i,kn=nt.getSetAttribute,Sn=nt.input;it.fn.extend({attr:function(e,t){return Dt(this,it.attr,e,t,arguments.length>1)},removeAttr:function(e){return this.each(function(){it.removeAttr(this,e)})}}),it.extend({attr:function(e,t,n){var r,i,o=e.nodeType;if(e&&3!==o&&8!==o&&2!==o)return typeof e.getAttribute===Tt?it.prop(e,t,n):(1===o&&it.isXMLDoc(e)||(t=t.toLowerCase(),r=it.attrHooks[t]||(it.expr.match.bool.test(t)?Cn:Tn)),void 0===n?r&&"get"in r&&null!==(i=r.get(e,t))?i:(i=it.find.attr(e,t),null==i?void 0:i):null!==n?r&&"set"in r&&void 0!==(i=r.set(e,n,t))?i:(e.setAttribute(t,n+""),n):void it.removeAttr(e,t))},removeAttr:function(e,t){var n,r,i=0,o=t&&t.match(bt);if(o&&1===e.nodeType)for(;n=o[i++];)r=it.propFix[n]||n,it.expr.match.bool.test(n)?Sn&&kn||!En.test(n)?e[r]=!1:e[it.camelCase("default-"+n)]=e[r]=!1:it.attr(e,n,""),e.removeAttribute(kn?n:r)},attrHooks:{type:{set:function(e,t){if(!nt.radioValue&&"radio"===t&&it.nodeName(e,"input")){var n=e.value;return e.setAttribute("type",t),n&&(e.value=n),t}}}}}),Cn={set:function(e,t,n){return t===!1?it.removeAttr(e,n):Sn&&kn||!En.test(n)?e.setAttribute(!kn&&it.propFix[n]||n,n):e[it.camelCase("default-"+n)]=e[n]=!0,n}},it.each(it.expr.match.bool.source.match(/\w+/g),function(e,t){var n=Nn[t]||it.find.attr;Nn[t]=Sn&&kn||!En.test(t)?function(e,t,r){var i,o;return r||(o=Nn[t],Nn[t]=i,i=null!=n(e,t,r)?t.toLowerCase():null,Nn[t]=o),i}:function(e,t,n){return n?void 0:e[it.camelCase("default-"+t)]?t.toLowerCase():null}}),Sn&&kn||(it.attrHooks.value={set:function(e,t,n){return it.nodeName(e,"input")?void(e.defaultValue=t):Tn&&Tn.set(e,t,n)}}),kn||(Tn={set:function(e,t,n){var r=e.getAttributeNode(n);return r||e.setAttributeNode(r=e.ownerDocument.createAttribute(n)),r.value=t+="","value"===n||t===e.getAttribute(n)?t:void 0}},Nn.id=Nn.name=Nn.coords=function(e,t,n){var r;return n?void 0:(r=e.getAttributeNode(t))&&""!==r.value?r.value:null},it.valHooks.button={get:function(e,t){var n=e.getAttributeNode(t);return n&&n.specified?n.value:void 0},set:Tn.set},it.attrHooks.contenteditable={set:function(e,t,n){Tn.set(e,""===t?!1:t,n)}},it.each(["width","height"],function(e,t){it.attrHooks[t]={set:function(e,n){return""===n?(e.setAttribute(t,"auto"),n):void 0}}})),nt.style||(it.attrHooks.style={get:function(e){return e.style.cssText||void 0},set:function(e,t){return e.style.cssText=t+""}});var An=/^(?:input|select|textarea|button|object)$/i,Dn=/^(?:a|area)$/i;it.fn.extend({prop:function(e,t){return Dt(this,it.prop,e,t,arguments.length>1)},removeProp:function(e){return e=it.propFix[e]||e,this.each(function(){try{this[e]=void 0,delete this[e]}catch(t){}})}}),it.extend({propFix:{"for":"htmlFor","class":"className"},prop:function(e,t,n){var r,i,o,a=e.nodeType;if(e&&3!==a&&8!==a&&2!==a)return o=1!==a||!it.isXMLDoc(e),o&&(t=it.propFix[t]||t,i=it.propHooks[t]),void 0!==n?i&&"set"in i&&void 0!==(r=i.set(e,n,t))?r:e[t]=n:i&&"get"in i&&null!==(r=i.get(e,t))?r:e[t]},propHooks:{tabIndex:{get:function(e){var t=it.find.attr(e,"tabindex");return t?parseInt(t,10):An.test(e.nodeName)||Dn.test(e.nodeName)&&e.href?0:-1}}}}),nt.hrefNormalized||it.each(["href","src"],function(e,t){it.propHooks[t]={get:function(e){return e.getAttribute(t,4)}}}),nt.optSelected||(it.propHooks.selected={get:function(e){var t=e.parentNode;return t&&(t.selectedIndex,t.parentNode&&t.parentNode.selectedIndex),null}}),it.each(["tabIndex","readOnly","maxLength","cellSpacing","cellPadding","rowSpan","colSpan","useMap","frameBorder","contentEditable"],function(){it.propFix[this.toLowerCase()]=this}),nt.enctype||(it.propFix.enctype="encoding");var jn=/[\t\r\n\f]/g;it.fn.extend({addClass:function(e){var t,n,r,i,o,a,s=0,u=this.length,l="string"==typeof e&&e;if(it.isFunction(e))return this.each(function(t){it(this).addClass(e.call(this,t,this.className))});if(l)for(t=(e||"").match(bt)||[];u>s;s++)if(n=this[s],r=1===n.nodeType&&(n.className?(" "+n.className+" ").replace(jn," "):" ")){for(o=0;i=t[o++];)r.indexOf(" "+i+" ")<0&&(r+=i+" ");a=it.trim(r),n.className!==a&&(n.className=a)}return this},removeClass:function(e){var t,n,r,i,o,a,s=0,u=this.length,l=0===arguments.length||"string"==typeof e&&e;if(it.isFunction(e))return this.each(function(t){it(this).removeClass(e.call(this,t,this.className))});if(l)for(t=(e||"").match(bt)||[];u>s;s++)if(n=this[s],r=1===n.nodeType&&(n.className?(" "+n.className+" ").replace(jn," "):"")){for(o=0;i=t[o++];)for(;r.indexOf(" "+i+" ")>=0;)r=r.replace(" "+i+" "," ");a=e?it.trim(r):"",n.className!==a&&(n.className=a)}return this},toggleClass:function(e,t){var n=typeof e;return"boolean"==typeof t&&"string"===n?t?this.addClass(e):this.removeClass(e):this.each(it.isFunction(e)?function(n){it(this).toggleClass(e.call(this,n,this.className,t),t)}:function(){if("string"===n)for(var t,r=0,i=it(this),o=e.match(bt)||[];t=o[r++];)i.hasClass(t)?i.removeClass(t):i.addClass(t);else(n===Tt||"boolean"===n)&&(this.className&&it._data(this,"__className__",this.className),this.className=this.className||e===!1?"":it._data(this,"__className__")||"")})},hasClass:function(e){for(var t=" "+e+" ",n=0,r=this.length;r>n;n++)if(1===this[n].nodeType&&(" "+this[n].className+" ").replace(jn," ").indexOf(t)>=0)return!0;return!1}}),it.each("blur focus focusin focusout load resize scroll unload click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup error contextmenu".split(" "),function(e,t){it.fn[t]=function(e,n){return arguments.length>0?this.on(t,null,e,n):this.trigger(t)}}),it.fn.extend({hover:function(e,t){return this.mouseenter(e).mouseleave(t||e)},bind:function(e,t,n){return this.on(e,null,t,n)},unbind:function(e,t){return this.off(e,null,t)},delegate:function(e,t,n,r){return this.on(t,e,n,r)},undelegate:function(e,t,n){return 1===arguments.length?this.off(e,"**"):this.off(t,e||"**",n)}});var Ln=it.now(),Hn=/\?/,qn=/(,)|(\[|{)|(}|])|"(?:[^"\\\r\n]|\\["\\\/bfnrt]|\\u[\da-fA-F]{4})*"\s*:?|true|false|null|-?(?!0\d)\d+(?:\.\d+|)(?:[eE][+-]?\d+|)/g;it.parseJSON=function(t){if(e.JSON&&e.JSON.parse)return e.JSON.parse(t+"");var n,r=null,i=it.trim(t+"");return i&&!it.trim(i.replace(qn,function(e,t,i,o){return n&&t&&(r=0),0===r?e:(n=i||t,r+=!o-!i,"")}))?Function("return "+i)():it.error("Invalid JSON: "+t)},it.parseXML=function(t){var n,r;if(!t||"string"!=typeof t)return null;try{e.DOMParser?(r=new DOMParser,n=r.parseFromString(t,"text/xml")):(n=new ActiveXObject("Microsoft.XMLDOM"),n.async="false",n.loadXML(t))}catch(i){n=void 0}return n&&n.documentElement&&!n.getElementsByTagName("parsererror").length||it.error("Invalid XML: "+t),n};var _n,Mn,Fn=/#.*$/,On=/([?&])_=[^&]*/,Bn=/^(.*?):[ \t]*([^\r\n]*)\r?$/gm,Pn=/^(?:about|app|app-storage|.+-extension|file|res|widget):$/,Rn=/^(?:GET|HEAD)$/,Wn=/^\/\//,$n=/^([\w.+-]+:)(?:\/\/(?:[^\/?#]*@|)([^\/?#:]*)(?::(\d+)|)|)/,zn={},In={},Xn="*/".concat("*");try{Mn=location.href}catch(Un){Mn=ht.createElement("a"),Mn.href="",Mn=Mn.href}_n=$n.exec(Mn.toLowerCase())||[],it.extend({active:0,lastModified:{},etag:{},ajaxSettings:{url:Mn,type:"GET",isLocal:Pn.test(_n[1]),global:!0,processData:!0,async:!0,contentType:"application/x-www-form-urlencoded; charset=UTF-8",accepts:{"*":Xn,text:"text/plain",html:"text/html",xml:"application/xml, text/xml",json:"application/json, text/javascript"},contents:{xml:/xml/,html:/html/,json:/json/},responseFields:{xml:"responseXML",text:"responseText",json:"responseJSON"},converters:{"* text":String,"text html":!0,"text json":it.parseJSON,"text xml":it.parseXML},flatOptions:{url:!0,context:!0}},ajaxSetup:function(e,t){return t?W(W(e,it.ajaxSettings),t):W(it.ajaxSettings,e)},ajaxPrefilter:P(zn),ajaxTransport:P(In),ajax:function(e,t){function n(e,t,n,r){var i,c,v,y,x,T=t;2!==b&&(b=2,s&&clearTimeout(s),l=void 0,a=r||"",w.readyState=e>0?4:0,i=e>=200&&300>e||304===e,n&&(y=$(d,w,n)),y=z(d,y,w,i),i?(d.ifModified&&(x=w.getResponseHeader("Last-Modified"),x&&(it.lastModified[o]=x),x=w.getResponseHeader("etag"),x&&(it.etag[o]=x)),204===e||"HEAD"===d.type?T="nocontent":304===e?T="notmodified":(T=y.state,c=y.data,v=y.error,i=!v)):(v=T,(e||!T)&&(T="error",0>e&&(e=0))),w.status=e,w.statusText=(t||T)+"",i?h.resolveWith(f,[c,T,w]):h.rejectWith(f,[w,T,v]),w.statusCode(g),g=void 0,u&&p.trigger(i?"ajaxSuccess":"ajaxError",[w,d,i?c:v]),m.fireWith(f,[w,T]),u&&(p.trigger("ajaxComplete",[w,d]),--it.active||it.event.trigger("ajaxStop")))}"object"==typeof e&&(t=e,e=void 0),t=t||{};var r,i,o,a,s,u,l,c,d=it.ajaxSetup({},t),f=d.context||d,p=d.context&&(f.nodeType||f.jquery)?it(f):it.event,h=it.Deferred(),m=it.Callbacks("once memory"),g=d.statusCode||{},v={},y={},b=0,x="canceled",w={readyState:0,getResponseHeader:function(e){var t;if(2===b){if(!c)for(c={};t=Bn.exec(a);)c[t[1].toLowerCase()]=t[2];t=c[e.toLowerCase()]}return null==t?null:t},getAllResponseHeaders:function(){return 2===b?a:null},setRequestHeader:function(e,t){var n=e.toLowerCase();return b||(e=y[n]=y[n]||e,v[e]=t),this},overrideMimeType:function(e){return b||(d.mimeType=e),this},statusCode:function(e){var t;if(e)if(2>b)for(t in e)g[t]=[g[t],e[t]];else w.always(e[w.status]);return this},abort:function(e){var t=e||x;return l&&l.abort(t),n(0,t),this}};if(h.promise(w).complete=m.add,w.success=w.done,w.error=w.fail,d.url=((e||d.url||Mn)+"").replace(Fn,"").replace(Wn,_n[1]+"//"),d.type=t.method||t.type||d.method||d.type,d.dataTypes=it.trim(d.dataType||"*").toLowerCase().match(bt)||[""],null==d.crossDomain&&(r=$n.exec(d.url.toLowerCase()),d.crossDomain=!(!r||r[1]===_n[1]&&r[2]===_n[2]&&(r[3]||("http:"===r[1]?"80":"443"))===(_n[3]||("http:"===_n[1]?"80":"443")))),d.data&&d.processData&&"string"!=typeof d.data&&(d.data=it.param(d.data,d.traditional)),R(zn,d,t,w),2===b)return w;u=it.event&&d.global,u&&0===it.active++&&it.event.trigger("ajaxStart"),d.type=d.type.toUpperCase(),d.hasContent=!Rn.test(d.type),o=d.url,d.hasContent||(d.data&&(o=d.url+=(Hn.test(o)?"&":"?")+d.data,delete d.data),d.cache===!1&&(d.url=On.test(o)?o.replace(On,"$1_="+Ln++):o+(Hn.test(o)?"&":"?")+"_="+Ln++)),d.ifModified&&(it.lastModified[o]&&w.setRequestHeader("If-Modified-Since",it.lastModified[o]),it.etag[o]&&w.setRequestHeader("If-None-Match",it.etag[o])),(d.data&&d.hasContent&&d.contentType!==!1||t.contentType)&&w.setRequestHeader("Content-Type",d.contentType),w.setRequestHeader("Accept",d.dataTypes[0]&&d.accepts[d.dataTypes[0]]?d.accepts[d.dataTypes[0]]+("*"!==d.dataTypes[0]?", "+Xn+"; q=0.01":""):d.accepts["*"]);for(i in d.headers)w.setRequestHeader(i,d.headers[i]);if(d.beforeSend&&(d.beforeSend.call(f,w,d)===!1||2===b))return w.abort();x="abort";for(i in{success:1,error:1,complete:1})w[i](d[i]);if(l=R(In,d,t,w)){w.readyState=1,u&&p.trigger("ajaxSend",[w,d]),d.async&&d.timeout>0&&(s=setTimeout(function(){w.abort("timeout")},d.timeout));try{b=1,l.send(v,n)}catch(T){if(!(2>b))throw T;n(-1,T)}}else n(-1,"No Transport");return w},getJSON:function(e,t,n){return it.get(e,t,n,"json")},getScript:function(e,t){return it.get(e,void 0,t,"script")}}),it.each(["get","post"],function(e,t){it[t]=function(e,n,r,i){return it.isFunction(n)&&(i=i||r,r=n,n=void 0),it.ajax({url:e,type:t,dataType:i,data:n,success:r})}}),it._evalUrl=function(e){return it.ajax({url:e,type:"GET",dataType:"script",async:!1,global:!1,"throws":!0})},it.fn.extend({wrapAll:function(e){if(it.isFunction(e))return this.each(function(t){it(this).wrapAll(e.call(this,t))});if(this[0]){var t=it(e,this[0].ownerDocument).eq(0).clone(!0);this[0].parentNode&&t.insertBefore(this[0]),t.map(function(){for(var e=this;e.firstChild&&1===e.firstChild.nodeType;)e=e.firstChild;return e}).append(this)}return this},wrapInner:function(e){return this.each(it.isFunction(e)?function(t){it(this).wrapInner(e.call(this,t))}:function(){var t=it(this),n=t.contents();n.length?n.wrapAll(e):t.append(e)})},wrap:function(e){var t=it.isFunction(e);return this.each(function(n){it(this).wrapAll(t?e.call(this,n):e)})},unwrap:function(){return this.parent().each(function(){it.nodeName(this,"body")||it(this).replaceWith(this.childNodes)}).end()}}),it.expr.filters.hidden=function(e){return e.offsetWidth<=0&&e.offsetHeight<=0||!nt.reliableHiddenOffsets()&&"none"===(e.style&&e.style.display||it.css(e,"display"))},it.expr.filters.visible=function(e){return!it.expr.filters.hidden(e)};var Vn=/%20/g,Jn=/\[\]$/,Yn=/\r?\n/g,Qn=/^(?:submit|button|image|reset|file)$/i,Gn=/^(?:input|select|textarea|keygen)/i;it.param=function(e,t){var n,r=[],i=function(e,t){t=it.isFunction(t)?t():null==t?"":t,r[r.length]=encodeURIComponent(e)+"="+encodeURIComponent(t)};if(void 0===t&&(t=it.ajaxSettings&&it.ajaxSettings.traditional),it.isArray(e)||e.jquery&&!it.isPlainObject(e))it.each(e,function(){i(this.name,this.value)});else for(n in e)I(n,e[n],t,i);return r.join("&").replace(Vn,"+")},it.fn.extend({serialize:function(){return it.param(this.serializeArray())},serializeArray:function(){return this.map(function(){var e=it.prop(this,"elements");return e?it.makeArray(e):this}).filter(function(){var e=this.type;return this.name&&!it(this).is(":disabled")&&Gn.test(this.nodeName)&&!Qn.test(e)&&(this.checked||!jt.test(e))}).map(function(e,t){var n=it(this).val();return null==n?null:it.isArray(n)?it.map(n,function(e){return{name:t.name,value:e.replace(Yn,"\r\n")}}):{name:t.name,value:n.replace(Yn,"\r\n")}}).get()}}),it.ajaxSettings.xhr=void 0!==e.ActiveXObject?function(){return!this.isLocal&&/^(get|post|head|put|delete|options)$/i.test(this.type)&&X()||U()}:X;var Kn=0,Zn={},er=it.ajaxSettings.xhr();e.attachEvent&&e.attachEvent("onunload",function(){for(var e in Zn)Zn[e](void 0,!0)}),nt.cors=!!er&&"withCredentials"in er,er=nt.ajax=!!er,er&&it.ajaxTransport(function(e){if(!e.crossDomain||nt.cors){var t;return{send:function(n,r){var i,o=e.xhr(),a=++Kn;if(o.open(e.type,e.url,e.async,e.username,e.password),e.xhrFields)for(i in e.xhrFields)o[i]=e.xhrFields[i];e.mimeType&&o.overrideMimeType&&o.overrideMimeType(e.mimeType),e.crossDomain||n["X-Requested-With"]||(n["X-Requested-With"]="XMLHttpRequest");for(i in n)void 0!==n[i]&&o.setRequestHeader(i,n[i]+"");o.send(e.hasContent&&e.data||null),t=function(n,i){var s,u,l;if(t&&(i||4===o.readyState))if(delete Zn[a],t=void 0,o.onreadystatechange=it.noop,i)4!==o.readyState&&o.abort();else{l={},s=o.status,"string"==typeof o.responseText&&(l.text=o.responseText);try{u=o.statusText}catch(c){u=""}s||!e.isLocal||e.crossDomain?1223===s&&(s=204):s=l.text?200:404}l&&r(s,u,l,o.getAllResponseHeaders())},e.async?4===o.readyState?setTimeout(t):o.onreadystatechange=Zn[a]=t:t()},abort:function(){t&&t(void 0,!0)}}}}),it.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/(?:java|ecma)script/},converters:{"text script":function(e){return it.globalEval(e),e}}}),it.ajaxPrefilter("script",function(e){void 0===e.cache&&(e.cache=!1),e.crossDomain&&(e.type="GET",e.global=!1)}),it.ajaxTransport("script",function(e){if(e.crossDomain){var t,n=ht.head||it("head")[0]||ht.documentElement;return{send:function(r,i){t=ht.createElement("script"),t.async=!0,e.scriptCharset&&(t.charset=e.scriptCharset),t.src=e.url,t.onload=t.onreadystatechange=function(e,n){(n||!t.readyState||/loaded|complete/.test(t.readyState))&&(t.onload=t.onreadystatechange=null,t.parentNode&&t.parentNode.removeChild(t),t=null,n||i(200,"success"))},n.insertBefore(t,n.firstChild)},abort:function(){t&&t.onload(void 0,!0)}}}});var tr=[],nr=/(=)\?(?=&|$)|\?\?/;it.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var e=tr.pop()||it.expando+"_"+Ln++;return this[e]=!0,e}}),it.ajaxPrefilter("json jsonp",function(t,n,r){var i,o,a,s=t.jsonp!==!1&&(nr.test(t.url)?"url":"string"==typeof t.data&&!(t.contentType||"").indexOf("application/x-www-form-urlencoded")&&nr.test(t.data)&&"data");return s||"jsonp"===t.dataTypes[0]?(i=t.jsonpCallback=it.isFunction(t.jsonpCallback)?t.jsonpCallback():t.jsonpCallback,s?t[s]=t[s].replace(nr,"$1"+i):t.jsonp!==!1&&(t.url+=(Hn.test(t.url)?"&":"?")+t.jsonp+"="+i),t.converters["script json"]=function(){return a||it.error(i+" was not called"),a[0]},t.dataTypes[0]="json",o=e[i],e[i]=function(){a=arguments},r.always(function(){e[i]=o,t[i]&&(t.jsonpCallback=n.jsonpCallback,tr.push(i)),a&&it.isFunction(o)&&o(a[0]),a=o=void 0}),"script"):void 0}),it.parseHTML=function(e,t,n){if(!e||"string"!=typeof e)return null;"boolean"==typeof t&&(n=t,t=!1),t=t||ht;var r=dt.exec(e),i=!n&&[];return r?[t.createElement(r[1])]:(r=it.buildFragment([e],t,i),i&&i.length&&it(i).remove(),it.merge([],r.childNodes))};var rr=it.fn.load;it.fn.load=function(e,t,n){if("string"!=typeof e&&rr)return rr.apply(this,arguments);var r,i,o,a=this,s=e.indexOf(" ");return s>=0&&(r=it.trim(e.slice(s,e.length)),e=e.slice(0,s)),it.isFunction(t)?(n=t,t=void 0):t&&"object"==typeof t&&(o="POST"),a.length>0&&it.ajax({url:e,type:o,dataType:"html",data:t}).done(function(e){i=arguments,a.html(r?it("<div>").append(it.parseHTML(e)).find(r):e)}).complete(n&&function(e,t){a.each(n,i||[e.responseText,t,e])}),this},it.each(["ajaxStart","ajaxStop","ajaxComplete","ajaxError","ajaxSuccess","ajaxSend"],function(e,t){it.fn[t]=function(e){return this.on(t,e)}}),it.expr.filters.animated=function(e){return it.grep(it.timers,function(t){return e===t.elem}).length};var ir=e.document.documentElement;it.offset={setOffset:function(e,t,n){var r,i,o,a,s,u,l,c=it.css(e,"position"),d=it(e),f={};"static"===c&&(e.style.position="relative"),s=d.offset(),o=it.css(e,"top"),u=it.css(e,"left"),l=("absolute"===c||"fixed"===c)&&it.inArray("auto",[o,u])>-1,l?(r=d.position(),a=r.top,i=r.left):(a=parseFloat(o)||0,i=parseFloat(u)||0),it.isFunction(t)&&(t=t.call(e,n,s)),null!=t.top&&(f.top=t.top-s.top+a),null!=t.left&&(f.left=t.left-s.left+i),"using"in t?t.using.call(e,f):d.css(f)}},it.fn.extend({offset:function(e){if(arguments.length)return void 0===e?this:this.each(function(t){it.offset.setOffset(this,e,t)});var t,n,r={top:0,left:0},i=this[0],o=i&&i.ownerDocument;if(o)return t=o.documentElement,it.contains(t,i)?(typeof i.getBoundingClientRect!==Tt&&(r=i.getBoundingClientRect()),n=V(o),{top:r.top+(n.pageYOffset||t.scrollTop)-(t.clientTop||0),left:r.left+(n.pageXOffset||t.scrollLeft)-(t.clientLeft||0)}):r},position:function(){if(this[0]){var e,t,n={top:0,left:0},r=this[0];return"fixed"===it.css(r,"position")?t=r.getBoundingClientRect():(e=this.offsetParent(),t=this.offset(),it.nodeName(e[0],"html")||(n=e.offset()),n.top+=it.css(e[0],"borderTopWidth",!0),n.left+=it.css(e[0],"borderLeftWidth",!0)),{top:t.top-n.top-it.css(r,"marginTop",!0),left:t.left-n.left-it.css(r,"marginLeft",!0)}}},offsetParent:function(){return this.map(function(){for(var e=this.offsetParent||ir;e&&!it.nodeName(e,"html")&&"static"===it.css(e,"position");)e=e.offsetParent;return e||ir})}}),it.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(e,t){var n=/Y/.test(t);it.fn[e]=function(r){return Dt(this,function(e,r,i){var o=V(e);return void 0===i?o?t in o?o[t]:o.document.documentElement[r]:e[r]:void(o?o.scrollTo(n?it(o).scrollLeft():i,n?i:it(o).scrollTop()):e[r]=i)},e,r,arguments.length,null)}}),it.each(["top","left"],function(e,t){it.cssHooks[t]=k(nt.pixelPosition,function(e,n){return n?(n=rn(e,t),tn.test(n)?it(e).position()[t]+"px":n):void 0})}),it.each({Height:"height",Width:"width"},function(e,t){it.each({padding:"inner"+e,content:t,"":"outer"+e},function(n,r){it.fn[r]=function(r,i){var o=arguments.length&&(n||"boolean"!=typeof r),a=n||(r===!0||i===!0?"margin":"border");return Dt(this,function(t,n,r){var i;return it.isWindow(t)?t.document.documentElement["client"+e]:9===t.nodeType?(i=t.documentElement,Math.max(t.body["scroll"+e],i["scroll"+e],t.body["offset"+e],i["offset"+e],i["client"+e])):void 0===r?it.css(t,n,a):it.style(t,n,r,a)
+},t,o?r:void 0,o,null)}})}),it.fn.size=function(){return this.length},it.fn.andSelf=it.fn.addBack,"function"==typeof define&&define.amd&&define("jquery",[],function(){return it});var or=e.jQuery,ar=e.$;return it.noConflict=function(t){return e.$===it&&(e.$=ar),t&&e.jQuery===it&&(e.jQuery=or),it},typeof t===Tt&&(e.jQuery=e.$=it),it})}).call(this),function(){t=n=window.jQuery.noConflict()}.call(this),"undefined"==typeof Package&&(Package={}),Package.jquery={$:t,jQuery:n}}();
+
+!function(){var e=Package.meteor.Meteor,a=Package.tracker.Tracker,c=Package.tracker.Deps,a,c;"undefined"==typeof Package&&(Package={}),Package.deps={Tracker:a,Deps:c}}();
+
+!function(){var t=Package.meteor.Meteor,e=Package.tracker.Tracker,r=Package.tracker.Deps,i,n,a;(function(){i={},n=function(t){return t},a=Array.prototype.slice}).call(this),function(){var t=Object.prototype.hasOwnProperty,e=function(e,r){for(var i in r)t.call(r,i)&&(e[i]=r[i]);return e};i.Visitor=function(t){e(this,t)},i.Visitor.def=function(t){e(this.prototype,t)},i.Visitor.extend=function(t){var r=this,n=function a(){i.Visitor.apply(this,arguments)};return n.prototype=new r,n.extend=r.extend,n.def=r.def,t&&e(n.prototype,t),n},i.Visitor.def({visit:function(t){if(null==t)return this.visitNull.apply(this,arguments);if("object"==typeof t){if(t.htmljsType)switch(t.htmljsType){case i.Tag.htmljsType:return this.visitTag.apply(this,arguments);case i.CharRef.htmljsType:return this.visitCharRef.apply(this,arguments);case i.Comment.htmljsType:return this.visitComment.apply(this,arguments);case i.Raw.htmljsType:return this.visitRaw.apply(this,arguments);default:throw new Error("Unknown htmljs type: "+t.htmljsType)}return i.isArray(t)?this.visitArray.apply(this,arguments):this.visitObject.apply(this,arguments)}if("string"==typeof t||"boolean"==typeof t||"number"==typeof t)return this.visitPrimitive.apply(this,arguments);if("function"==typeof t)return this.visitFunction.apply(this,arguments);throw new Error("Unexpected object in htmljs: "+t)},visitNull:function(t){},visitPrimitive:function(t){},visitArray:function(t){},visitComment:function(t){},visitCharRef:function(t){},visitRaw:function(t){},visitTag:function(t){},visitObject:function(t){throw new Error("Unexpected object in htmljs: "+t)},visitFunction:function(t){throw new Error("Unexpected function in htmljs: "+t)}}),i.TransformingVisitor=i.Visitor.extend(),i.TransformingVisitor.def({visitNull:n,visitPrimitive:n,visitArray:function(t){for(var e=a.call(arguments),r=t,i=0;i<t.length;i++){var n=t[i];e[0]=n;var o=this.visit.apply(this,e);o!==n&&(r===t&&(r=t.slice()),r[i]=o)}return r},visitComment:n,visitCharRef:n,visitRaw:n,visitObject:n,visitFunction:n,visitTag:function(t){var e=t.children,r=a.call(arguments);r[0]=e;var n=this.visitChildren.apply(this,r),o=t.attrs;r[0]=o;var s=this.visitAttributes.apply(this,r);if(s===o&&n===e)return t;var u=i.getTag(t.tagName).apply(null,n);return u.attrs=s,u},visitChildren:function(t){return this.visitArray.apply(this,arguments)},visitAttributes:function(t){if(i.isArray(t)){for(var r=a.call(arguments),n=t,o=0;o<t.length;o++){var s=t[o];r[0]=s;var u=this.visitAttributes.apply(this,r);u!==s&&(n===t&&(n=t.slice()),n[o]=u)}return n}if(t&&i.isConstructedObject(t))throw new Error("The basic HTML.TransformingVisitor does not support foreign objects in attributes. Define a custom visitAttributes for this case.");var l=t,f=l;if(l){var c=[null,null];c.push.apply(c,arguments);for(var h in l){var p=l[h];c[0]=h,c[1]=p;var m=this.visitAttribute.apply(this,c);m!==p&&(f===l&&(f=e({},l)),f[h]=m)}}return f},visitAttribute:function(t,e,r){var i=a.call(arguments,2);return i[0]=e,this.visit.apply(this,i)}}),i.ToTextVisitor=i.Visitor.extend(),i.ToTextVisitor.def({visitNull:function(t){return""},visitPrimitive:function(t){var e=String(t);return this.textMode===i.TEXTMODE.RCDATA?e.replace(/&/g,"&amp;").replace(/</g,"&lt;"):this.textMode===i.TEXTMODE.ATTRIBUTE?e.replace(/&/g,"&amp;").replace(/"/g,"&quot;"):e},visitArray:function(t){for(var e=[],r=0;r<t.length;r++)e.push(this.visit(t[r]));return e.join("")},visitComment:function(t){throw new Error("Can't have a comment here")},visitCharRef:function(t){return this.textMode===i.TEXTMODE.RCDATA||this.textMode===i.TEXTMODE.ATTRIBUTE?t.html:t.str},visitRaw:function(t){return t.value},visitTag:function(t){return this.visit(this.toHTML(t))},visitObject:function(t){throw new Error("Unexpected object in htmljs in toText: "+t)},toHTML:function(t){return i.toHTML(t)}}),i.ToHTMLVisitor=i.Visitor.extend(),i.ToHTMLVisitor.def({visitNull:function(t){return""},visitPrimitive:function(t){var e=String(t);return e.replace(/&/g,"&amp;").replace(/</g,"&lt;")},visitArray:function(t){for(var e=[],r=0;r<t.length;r++)e.push(this.visit(t[r]));return e.join("")},visitComment:function(t){return"<!--"+t.sanitizedValue+"-->"},visitCharRef:function(t){return t.html},visitRaw:function(t){return t.value},visitTag:function(t){var e=[],r=t.tagName,n=t.children,a=t.attrs;if(a){a=i.flattenAttributes(a);for(var o in a)if("value"===o&&"textarea"===r)n=[a[o],n];else{var s=this.toText(a[o],i.TEXTMODE.ATTRIBUTE);e.push(" "+o+'="'+s+'"')}}var u="<"+r+e.join("")+">",l=[],f;if("textarea"===r){for(var c=0;c<n.length;c++)l.push(this.toText(n[c],i.TEXTMODE.RCDATA));f=l.join(""),"\n"===f.slice(0,1)&&(f="\n"+f)}else{for(var c=0;c<n.length;c++)l.push(this.visit(n[c]));f=l.join("")}var h=u+f;return(n.length||!i.isVoidElement(r))&&(h+="</"+r+">"),h},visitObject:function(t){throw new Error("Unexpected object in htmljs in toHTML: "+t)},toText:function(t,e){return i.toText(t,e)}})}.call(this),function(){i.Tag=function(){},i.Tag.prototype.tagName="",i.Tag.prototype.attrs=null,i.Tag.prototype.children=Object.freeze?Object.freeze([]):[],i.Tag.prototype.htmljsType=i.Tag.htmljsType=["Tag"];var t=function(t){var e=function(){var t=this instanceof i.Tag?this:new e,r=0,n=arguments.length&&arguments[0];if(n&&"object"==typeof n)if(i.isConstructedObject(n)){if(n instanceof i.Attrs){var o=n.value;1===o.length?t.attrs=o[0]:o.length>1&&(t.attrs=o),r++}}else t.attrs=n,r++;return r<arguments.length&&(t.children=a.call(arguments,r)),t};return e.prototype=new i.Tag,e.prototype.constructor=e,e.prototype.tagName=t,e},e=i.Attrs=function(){var t=this instanceof e?this:new e;return t.value=a.call(arguments),t};i.getTag=function(e){var r=i.getSymbolName(e);if(r===e)throw new Error("Use the lowercase or camelCase form of '"+e+"' here");return i[r]||(i[r]=t(e)),i[r]},i.ensureTag=function(t){i.getTag(t)},i.isTagEnsured=function(t){return i.isKnownElement(t)},i.getSymbolName=function(t){return t.toUpperCase().replace(/-/g,"_")},i.knownElementNames="a abbr acronym address applet area article aside audio b base basefont bdi bdo big blockquote body br button canvas caption center cite code col colgroup command data datagrid datalist dd del details dfn dir div dl dt em embed eventsource fieldset figcaption figure font footer form frame frameset h1 h2 h3 h4 h5 h6 head header hgroup hr html i iframe img input ins isindex kbd keygen label legend li link main map mark menu meta meter nav noframes noscript object ol optgroup option output p param pre progress q rp rt ruby s samp script section select small source span strike strong style sub summary sup table tbody td textarea tfoot th thead time title tr track tt u ul var video wbr".split(" "),i.knownSVGElementNames="altGlyph altGlyphDef altGlyphItem animate animateColor animateMotion animateTransform circle clipPath color-profile cursor defs desc ellipse feBlend feColorMatrix feComponentTransfer feComposite feConvolveMatrix feDiffuseLighting feDisplacementMap feDistantLight feFlood feFuncA feFuncB feFuncG feFuncR feGaussianBlur feImage feMerge feMergeNode feMorphology feOffset fePointLight feSpecularLighting feSpotLight feTile feTurbulence filter font font-face font-face-format font-face-name font-face-src font-face-uri foreignObject g glyph glyphRef hkern image line linearGradient marker mask metadata missing-glyph path pattern polygon polyline radialGradient rect script set stop style svg switch symbol text textPath title tref tspan use view vkern".split(" "),i.knownElementNames=i.knownElementNames.concat(i.knownSVGElementNames),i.voidElementNames="area base br col command embed hr img input keygen link meta param source track wbr".split(" ");var r={yes:!0},n=function(t){for(var e={},i=0;i<t.length;i++)e[t[i]]=r;return e},o=n(i.voidElementNames),s=n(i.knownElementNames),u=n(i.knownSVGElementNames);i.isKnownElement=function(t){return s[t]===r},i.isKnownSVGElement=function(t){return u[t]===r},i.isVoidElement=function(t){return o[t]===r};for(var l=0;l<i.knownElementNames.length;l++)i.ensureTag(i.knownElementNames[l]);var f=i.CharRef=function(t){if(!(this instanceof f))return new f(t);if(!(t&&t.html&&t.str))throw new Error("HTML.CharRef must be constructed with ({html:..., str:...})");this.html=t.html,this.str=t.str};f.prototype.htmljsType=f.htmljsType=["CharRef"];var c=i.Comment=function(t){if(!(this instanceof c))return new c(t);if("string"!=typeof t)throw new Error("HTML.Comment must be constructed with a string");this.value=t,this.sanitizedValue=t.replace(/^-|--+|-$/g,"")};c.prototype.htmljsType=c.htmljsType=["Comment"];var h=i.Raw=function(t){if(!(this instanceof h))return new h(t);if("string"!=typeof t)throw new Error("HTML.Raw must be constructed with a string");this.value=t};h.prototype.htmljsType=h.htmljsType=["Raw"],i.isArray=function(t){return t instanceof Array},i.isConstructedObject=function(t){return t&&"object"==typeof t&&t.constructor!==Object&&!Object.prototype.hasOwnProperty.call(t,"constructor")},i.isNully=function(t){if(null==t)return!0;if(i.isArray(t)){for(var e=0;e<t.length;e++)if(!i.isNully(t[e]))return!1;return!0}return!1},i.isValidAttributeName=function(t){return/^[:_A-Za-z][:_A-Za-z0-9.\-]*/.test(t)},i.flattenAttributes=function(t){if(!t)return t;var e=i.isArray(t);if(e&&0===t.length)return null;for(var r={},n=0,a=e?t.length:1;a>n;n++){var o=e?t[n]:t;if("object"!=typeof o||i.isConstructedObject(o))throw new Error("Expected plain JS object as attrs, found: "+o);for(var s in o){if(!i.isValidAttributeName(s))throw new Error("Illegal HTML attribute name: "+s);var u=o[s];i.isNully(u)||(r[s]=u)}}return r},i.toHTML=function(t){return(new i.ToHTMLVisitor).visit(t)},i.TEXTMODE={STRING:1,RCDATA:2,ATTRIBUTE:3},i.toText=function(t,e){if(!e)throw new Error("textMode required for HTML.toText");if(e!==i.TEXTMODE.STRING&&e!==i.TEXTMODE.RCDATA&&e!==i.TEXTMODE.ATTRIBUTE)throw new Error("Unknown textMode: "+e);var r=new i.ToTextVisitor({textMode:e});return r.visit(t)}}.call(this),"undefined"==typeof Package&&(Package={}),Package.htmljs={HTML:i}}();
+
+!function(){var e=Package.meteor.Meteor,n=Package.tracker.Tracker,o=Package.tracker.Deps,r=Package.minimongo.LocalCollection,t=Package.minimongo.Minimongo,i=Package.underscore._,a=Package.random.Random,c,u,f,d;(function(){var e=function(){c._suppressWarnings?c._suppressWarnings--:("undefined"!=typeof console&&console.warn&&console.warn.apply(console,arguments),c._loggedWarnings++)},o=r._idStringify,t=r._idParse;c={_suppressWarnings:0,_loggedWarnings:0,observe:function(e,o){var r=null,t=null,a=[],c=n.autorun(function(){var c=e();n.nonreactive(function(){var e;if(t&&(a=i.map(r.fetch(),function(e){return{_id:e._id,item:e}}),t.stop(),t=null),c)if(c instanceof Array)e=f(a,c,o);else{if(!l(c))throw s();var n=d(a,c,o);e=n[0],t=n[1]}else e=u(a,o);v(a,e,o),r=c,a=e})});return{stop:function(){c.stop(),t&&t.stop()}}},fetch:function(e){if(e){if(e instanceof Array)return e;if(l(e))return e.fetch();throw s()}return[]}};var s=function(){return new Error("{{#each}} currently only accepts arrays, cursors or falsey values.")},l=function(e){return e&&i.isObject(e)&&i.isFunction(e.observe)&&i.isFunction(e.fetch)},v=function(e,n,r){var a=Package.minimongo.LocalCollection._diffQueryOrderedChanges,c=[],u=[],f={},d={},s={},l=e.length;i.each(n,function(e,n){u.push({_id:e._id}),d[o(e._id)]=n}),i.each(e,function(e,n){c.push({_id:e._id}),f[o(e._id)]=n,s[o(e._id)]=n}),a(c,u,{addedBefore:function(e,t,a){var c=a?s[o(a)]:l;i.each(s,function(e,n){e>=c&&s[n]++}),l++,s[o(e)]=c,r.addedAt(e,n[d[o(e)]].item,c,a)},movedBefore:function(e,t){var a=s[o(e)],c=t?s[o(t)]:l-1;i.each(s,function(e,n){e>=a&&c>=e?s[n]--:a>=e&&e>=c&&s[n]++}),s[o(e)]=c,r.movedTo(e,n[d[o(e)]].item,a,c,t)},removed:function(n){var t=s[o(n)];i.each(s,function(e,n){e>=t&&s[n]--}),delete s[o(n)],l--,r.removedAt(n,e[f[o(n)]].item,t)}}),i.each(d,function(o,a){var c=t(a);if(i.has(f,a)){var u=n[o].item,d=e[f[a]].item;("object"==typeof u||u!==d)&&r.changedAt(c,u,d,o)}})};u=function(e,n){return[]},f=function(n,r,t){var c={},u=i.map(r,function(n,t){var i;if("string"==typeof n)i="-"+n;else if("number"==typeof n||"boolean"==typeof n||void 0===n)i=n;else{if("object"!=typeof n)throw new Error("{{#each}} doesn't support arrays with elements of type "+typeof n);i=n&&n._id||t}var u=o(i);return c[u]?("object"==typeof n&&"_id"in n&&e("duplicate id "+i+" in",r),i=a.id()):c[u]=!0,{_id:i,item:n}});return u},d=function(e,n,o){var r=!0,t=[],i=n.observe({addedAt:function(e,n,i){if(r){if(null!==i)throw new Error("Expected initial data from observe in order");t.push({_id:e._id,item:e})}else o.addedAt(e._id,e,n,i)},changedAt:function(e,n,r){o.changedAt(e._id,e,n,r)},removedAt:function(e,n){o.removedAt(e._id,e,n)},movedTo:function(e,n,r,t){o.movedTo(e._id,e,n,r,t)}});return r=!1,[t,i]}}).call(this),"undefined"==typeof Package&&(Package={}),Package["observe-sequence"]={ObserveSequence:c}}();
+
+!function(){var e=Package.meteor.Meteor,t=Package.tracker.Tracker,n=Package.tracker.Deps,r;(function(){r=function(e,n){return this instanceof r?(this.curValue=e,this.equalsFunc=n,void(this.dep=new t.Dependency)):new r(e,n)},r._isEqual=function(e,t){var n=e,r=t;return n!==r?!1:!n||"number"==typeof n||"boolean"==typeof n||"string"==typeof n},r.prototype.get=function(){return t.active&&this.dep.depend(),this.curValue},r.prototype.set=function(e){var t=this.curValue;(this.equalsFunc||r._isEqual)(t,e)||(this.curValue=e,this.dep.changed())},r.prototype.toString=function(){return"ReactiveVar{"+this.get()+"}"},r.prototype._numListeners=function(){var e=0;for(var t in this.dep._dependentsById)e++;return e}}).call(this),"undefined"==typeof Package&&(Package={}),Package["reactive-var"]={ReactiveVar:r}}();
+
+!function(){var e=Package.meteor.Meteor,t=Package.jquery.$,n=Package.jquery.jQuery,r=Package.tracker.Tracker,i=Package.tracker.Deps,a=Package.underscore._,o=Package.htmljs.HTML,s=Package["observe-sequence"].ObserveSequence,u=Package["reactive-var"].ReactiveVar,l,c,d,f,p,h;(function(){l={},l._escape=function(){var e={"<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#x27;","`":"&#x60;","&":"&amp;"},t=function(t){return e[t]};return function(e){return e.replace(/[&<>"'`]/g,t)}}(),l._warn=function(e){e="Warning: "+e,"undefined"!=typeof Log&&Log&&Log.warn?Log.warn(e):"undefined"!=typeof console&&console.log&&console.log(e)}}).call(this),function(){var e={};l._DOMBackend=e;var t="undefined"!=typeof n?n:"undefined"!=typeof Package?Package.jquery&&Package.jquery.jQuery:null;if(!t)throw new Error("jQuery not found");e._$jq=t,e.parseHTML=function(e){return t.parseHTML(e)||[]},e.Events={delegateEvents:function(e,n,r,i){t(e).on(n,r,i)},undelegateEvents:function(e,n,r){t(e).off(n,"**",r)},bindEventCapturer:function(n,r,i,a){var o=t(n),s=function(e){e=t.event.fix(e),e.currentTarget=e.target;var r=t(e.currentTarget);r.is(o.find(i))&&a.call(n,e)};a._meteorui_wrapper=s,r=e.Events.parseEventType(r),n.addEventListener(r,s,!0)},unbindEventCapturer:function(t,n,r){n=e.Events.parseEventType(n),t.removeEventListener(n,r._meteorui_wrapper,!0)},parseEventType:function(e){var t=e.indexOf(".");return t>=0?e.slice(0,t):e}};var r=function(){},i=function(e){this.next=this,this.prev=this,this.func=e};i.prototype.linkBefore=function(e){this.prev=e.prev,this.next=e,e.prev.next=this,e.prev=this},i.prototype.unlink=function(){this.prev.next=this.next,this.next.prev=this.prev},i.prototype.go=function(){var e=this.func;e&&e()},i.prototype.stop=i.prototype.unlink,e.Teardown={_JQUERY_EVENT_NAME:"blaze_teardown_watcher",_CB_PROP:"$blaze_teardown_callbacks",onElementTeardown:function(n,a){var o=new i(a),s=e.Teardown._CB_PROP;return n[s]||(n[s]=new i,t(n).on(e.Teardown._JQUERY_EVENT_NAME,r)),o.linkBefore(n[s]),o},tearDownElement:function(e){for(var n=[],r=e.getElementsByTagName("*"),i=0;i<r.length;i++)n.push(r[i]);n.push(e),t.cleanData(n)}},t.event.special[e.Teardown._JQUERY_EVENT_NAME]={setup:function(){},teardown:function(){var t=this,n=t[e.Teardown._CB_PROP];if(n){for(var r=n.next;r!==n;)r.go(),r=r.next;n.go(),t[e.Teardown._CB_PROP]=null}}},e.findBySelector=function(e,n){return t(e,n)}}.call(this),function(){var e=Object.freeze?Object.freeze([]):[];l._DOMRange=function(n){if(!(this instanceof t))return new t(n);var r=n||e;if(!r||"number"!=typeof r.length)throw new Error("Expected array");for(var i=0;i<r.length;i++)this._memberIn(r[i]);this.members=r,this.emptyRangePlaceholder=null,this.attached=!1,this.parentElement=null,this.parentRange=null,this.attachedCallbacks=e};var t=l._DOMRange;t._USE_COMMENT_PLACEHOLDERS=function(){var e=!1,t=document.createTextNode("");try{t.someProp=!0}catch(n){e=!0}return e}(),t._insert=function(e,n,r,i){var a=e;a instanceof t?a.attach(n,r,i):i?t._moveNodeWithHooks(a,n,r):t._insertNodeWithHooks(a,n,r)},t._remove=function(e){var n=e;n instanceof t?n.detach():t._removeNodeWithHooks(n)},t._removeNodeWithHooks=function(e){e.parentNode&&(1===e.nodeType&&e.parentNode._uihooks&&e.parentNode._uihooks.removeElement?e.parentNode._uihooks.removeElement(e):e.parentNode.removeChild(e))},t._insertNodeWithHooks=function(e,t,n){n=n||null,1===e.nodeType&&t._uihooks&&t._uihooks.insertElement?t._uihooks.insertElement(e,n):t.insertBefore(e,n)},t._moveNodeWithHooks=function(e,t,n){e.parentNode===t&&(n=n||null,1===e.nodeType&&t._uihooks&&t._uihooks.moveElement?t._uihooks.moveElement(e,n):t.insertBefore(e,n))},t.forElement=function(e){if(1!==e.nodeType)throw new Error("Expected element, found: "+e);for(var t=null;e&&!t;)t=e.$blaze_range||null,t||(e=e.parentNode);return t},t.prototype.attach=function(e,n,r,i){if((r||i)&&(this.parentElement!==e||!this.attached))throw new Error("Can only move or replace an attached DOMRange, and only under the same parent element");var a=this.members;if(a.length){this.emptyRangePlaceholder=null;for(var o=0;o<a.length;o++)t._insert(a[o],e,n,r)}else{var s=t._USE_COMMENT_PLACEHOLDERS?document.createComment(""):document.createTextNode("");this.emptyRangePlaceholder=s,e.insertBefore(s,n||null)}if(this.attached=!0,this.parentElement=e,!r&&!i)for(var o=0;o<this.attachedCallbacks.length;o++){var u=this.attachedCallbacks[o];u.attached&&u.attached(this,e)}},t.prototype.setMembers=function(e){var t=e;if(!t||"number"!=typeof t.length)throw new Error("Expected array");for(var n=this.members,r=0;r<n.length;r++)this._memberOut(n[r]);for(var r=0;r<t.length;r++)this._memberIn(t[r]);if(this.attached){if(t.length||n.length){var i=this.lastNode().nextSibling,a=this.parentElement;this.detach(!0),this.members=t,this.attach(a,i,!1,!0)}}else this.members=t},t.prototype.firstNode=function(){if(!this.attached)throw new Error("Must be attached");if(!this.members.length)return this.emptyRangePlaceholder;var e=this.members[0];return e instanceof t?e.firstNode():e},t.prototype.lastNode=function(){if(!this.attached)throw new Error("Must be attached");if(!this.members.length)return this.emptyRangePlaceholder;var e=this.members[this.members.length-1];return e instanceof t?e.lastNode():e},t.prototype.detach=function(e){if(!this.attached)throw new Error("Must be attached");var n=this.parentElement,r=this.members;if(r.length)for(var i=0;i<r.length;i++)t._remove(r[i]);else{var a=this.emptyRangePlaceholder;this.parentElement.removeChild(a),this.emptyRangePlaceholder=null}if(!e){this.attached=!1,this.parentElement=null;for(var i=0;i<this.attachedCallbacks.length;i++){var o=this.attachedCallbacks[i];o.detached&&o.detached(this,n)}}},t.prototype.addMember=function(e,n,r){var i=this.members;if(!(n>=0&&n<=i.length))throw new Error("Bad index in range.addMember: "+n);if(r||this._memberIn(e),this.attached)if(0===i.length)this.setMembers([e]);else{var a;if(n===i.length)a=this.lastNode().nextSibling;else{var o=i[n];a=o instanceof t?o.firstNode():o}i.splice(n,0,e),t._insert(e,this.parentElement,a,r)}else i.splice(n,0,e)},t.prototype.removeMember=function(n,r){var i=this.members;if(!(n>=0&&n<i.length))throw new Error("Bad index in range.removeMember: "+n);if(r)i.splice(n,1);else{var a=i[n];this._memberOut(a),1===i.length?this.setMembers(e):(i.splice(n,1),this.attached&&t._remove(a))}},t.prototype.moveMember=function(e,t){var n=this.members[e];this.removeMember(e,!0),this.addMember(n,t,!0)},t.prototype.getMember=function(e){var t=this.members;if(!(e>=0&&e<t.length))throw new Error("Bad index in range.getMember: "+e);return this.members[e]},t.prototype._memberIn=function(e){e instanceof t?e.parentRange=this:1===e.nodeType&&(e.$blaze_range=this)},t._destroy=function(e,n){e instanceof t?e.view&&l._destroyView(e.view,n):n||1!==e.nodeType||e.$blaze_range&&(l._destroyNode(e),e.$blaze_range=null)},t.prototype._memberOut=t._destroy,t.prototype.destroyMembers=function(e){for(var t=this.members,n=0;n<t.length;n++)this._memberOut(t[n],e)},t.prototype.destroy=function(e){t._destroy(this,e)},t.prototype.containsElement=function(e){if(!this.attached)throw new Error("Must be attached");if(!l._elementContains(this.parentElement,e))return!1;for(;e.parentNode!==this.parentElement;)e=e.parentNode;for(var t=e.$blaze_range;t&&t!==this;)t=t.parentRange;return t===this},t.prototype.containsRange=function(e){if(!this.attached)throw new Error("Must be attached");if(!e.attached)return!1;if(e.parentElement!==this.parentElement)return this.containsElement(e.parentElement);if(e===this)return!1;for(;e&&e!==this;)e=e.parentRange;return e===this},t.prototype.onAttached=function(e){this.onAttachedDetached({attached:e})},t.prototype.onAttachedDetached=function(t){this.attachedCallbacks===e&&(this.attachedCallbacks=[]),this.attachedCallbacks.push(t)},t.prototype.$=function(e){var t=this,n=this.parentElement;if(!n)throw new Error("Can't select in removed DomRange");if(11===n.nodeType)throw new Error("Can't use $ on an offscreen range");var r=l._DOMBackend.findBySelector(e,n),i=function(e){return"number"==typeof e&&(e=this),t.containsElement(e)};if(r.filter)r=r.filter(i);else{for(var a=[],o=0;o<r.length;o++){var s=r[o];i(s)&&a.push(s)}r=a}return r},l._elementContains=function(e,t){return 1!==e.nodeType?!1:e===t?!1:e.compareDocumentPosition?16&e.compareDocumentPosition(t):(t=t.parentNode,t&&1===t.nodeType?e===t?!0:e.contains(t):!1)}}.call(this),function(){var e=l._EventSupport={},t=l._DOMBackend,n=e.eventsToDelegate={blur:1,change:1,click:1,focus:1,focusin:1,focusout:1,reset:1,submit:1},r=e.EVENT_MODE={TBD:0,BUBBLING:1,CAPTURING:2},i=1,o=function(e,o,s,u,l){this.elem=e,this.type=o,this.selector=s,this.handler=u,this.recipient=l,this.id=i++,this.mode=r.TBD,this.delegatedHandler=function(e){return function(t){return e.selector||t.currentTarget===t.target?e.handler.apply(e.recipient,arguments):void 0}}(this);var c=e.addEventListener&&!a.has(n,t.Events.parseEventType(o));c?this.capturingHandler=function(e){return function(n){if(e.mode===r.TBD){if(n.bubbles)return e.mode=r.BUBBLING,void t.Events.unbindEventCapturer(e.elem,e.type,e.capturingHandler);e.mode=r.CAPTURING,t.Events.undelegateEvents(e.elem,e.type,e.delegatedHandler)}e.delegatedHandler(n)}}(this):this.mode=r.BUBBLING};e.HandlerRec=o,o.prototype.bind=function(){this.mode!==r.BUBBLING&&t.Events.bindEventCapturer(this.elem,this.type,this.selector||"*",this.capturingHandler),this.mode!==r.CAPTURING&&t.Events.delegateEvents(this.elem,this.type,this.selector||"*",this.delegatedHandler)},o.prototype.unbind=function(){this.mode!==r.BUBBLING&&t.Events.unbindEventCapturer(this.elem,this.type,this.capturingHandler),this.mode!==r.CAPTURING&&t.Events.undelegateEvents(this.elem,this.type,this.delegatedHandler)},e.listen=function(e,t,n,r,i,a){try{e=e}finally{}var s=[];t.replace(/[^ /]+/g,function(e){s.push(e)});for(var u=[],l=0,c=s.length;c>l;l++){var d=s[l],f=e.$blaze_events;f||(f=e.$blaze_events={});var p=f[d];p||(p=f[d]={},p.handlers=[]);var h=p.handlers,m=new o(e,d,n,r,i);if(u.push(m),m.bind(),h.push(m),a)for(var w=a(i);w;w=a(w))for(var v=0,_=h.length;_>v;v++){var g=h[v];g.recipient===w&&(g.unbind(),g.bind(),h.splice(v,1),h.push(g),v--,_--)}}return{stop:function(){var t=e.$blaze_events;if(t){for(var n=0;n<u.length;n++){var r=u[n],i=t[r.type];if(i)for(var a=i.handlers,o=a.length-1;o>=0;o--)a[o]===r&&(r.unbind(),a.splice(o,1))}u.length=0}}}}}.call(this),function(){var n=!1;l._allowJavascriptUrls=function(){n=!0},l._javascriptUrlsAllowed=function(){return n},f=function(e,t){this.name=e,this.value=t},l._AttributeHandler=f,f.prototype.update=function(e,t,n){null===n?null!==t&&e.removeAttribute(this.name):e.setAttribute(this.name,n)},f.extend=function(e){var t=this,n=function r(){f.apply(this,arguments)};return n.prototype=new t,n.extend=t.extend,e&&a.extend(n.prototype,e),n};var r=f.extend({update:function(e,t,n){if(!this.getCurrentValue||!this.setValue||!this.parseValue)throw new Error("Missing methods in subclass of 'DiffingAttributeHandler'");var r=t?this.parseValue(t):{},i=n?this.parseValue(n):{},o=this.getCurrentValue(e),s=o?this.parseValue(o):{};a.each(a.keys(r),function(e){e in i||delete s[e]}),a.each(a.keys(i),function(e){s[e]=i[e]}),this.setValue(e,a.values(s).join(" "))}}),i=r.extend({getCurrentValue:function(e){return e.className},setValue:function(e,t){e.className=t},parseValue:function(e){var t={};return a.each(e.split(" "),function(e){e&&(t[e]=e)}),t}}),o=i.extend({getCurrentValue:function(e){return e.className.baseVal},setValue:function(e,t){e.setAttribute("class",t)}}),s=r.extend({getCurrentValue:function(e){return e.getAttribute("style")},setValue:function(e,t){""===t?e.removeAttribute("style"):e.setAttribute("style",t)},parseValue:function(e){for(var n={},r=/(\*?[-#\/\*\\\w]+(?:\[[0-9a-z_-]+\])?)\s*:\s*(?:\'(?:\\\'|.)*?\'|"(?:\\"|.)*?"|\([^\)]*?\)|[^};])+[;\s]*/g,i=r.exec(e);i;)n[" "+i[1]]=i[0].trim?i[0].trim():t.trim(i[0]),i=r.exec(e);return n}}),u=f.extend({update:function(e,t,n){var r=this.name;null==n?null!=t&&(e[r]=!1):e[r]=!0}}),c=f.extend({update:function(e,t,n){n!==e.value&&(e.value=n)}}),d=f.extend({update:function(e,t,n){var r="http://www.w3.org/1999/xlink";null===n?null!==t&&e.removeAttributeNS(r,this.name):e.setAttributeNS(r,this.name,this.value)}}),m=function(e){return"ownerSVGElement"in e},w=function(e,t){var n={FORM:["action"],BODY:["background"],BLOCKQUOTE:["cite"],Q:["cite"],DEL:["cite"],INS:["cite"],OBJECT:["classid","codebase","data","usemap"],APPLET:["codebase"],A:["href"],AREA:["href"],LINK:["href"],BASE:["href"],IMG:["longdesc","src","usemap"],FRAME:["longdesc","src"],IFRAME:["longdesc","src"],HEAD:["profile"],SCRIPT:["src"],INPUT:["src","usemap","formaction"],BUTTON:["formaction"],BASE:["href"],MENUITEM:["icon"],HTML:["manifest"],VIDEO:["poster"]};if("itemid"===t)return!0;var r=n[e]||[];return a.contains(r,t)};if(e.isClient)var v=document.createElement("A");var _=function(t){if(e.isClient)return v.href=t,(v.protocol||"").toLowerCase();throw new Error("getUrlProtocol not implemented on the server")},g=f.prototype.update,E=f.extend({update:function(e,t,n){var r=this,i=arguments;if(l._javascriptUrlsAllowed())g.apply(r,i);else{var a="javascript:"===_(n);a?(l._warn("URLs that use the 'javascript:' protocol are not allowed in URL attribute values. Call Blaze._allowJavascriptUrls() to enable them."),g.apply(r,[e,t,null])):g.apply(r,i)}}});p=function(e,t,n){return"class"===t?m(e)?new o(t,n):new i(t,n):"style"===t?new s(t,n):"OPTION"===e.tagName&&"selected"===t||"INPUT"===e.tagName&&"checked"===t?new u(t,n):"TEXTAREA"!==e.tagName&&"INPUT"!==e.tagName||"value"!==t?"xlink:"===t.substring(0,6)?new d(t.substring(6),n):w(e.tagName,t)?new E(t,n):new f(t,n):new c(t,n)},h=function(e){this.elem=e,this.handlers={}},h.prototype.update=function(e){var t=this.elem,n=this.handlers;for(var r in n)if(!a.has(e,r)){var i=n[r],o=i.value;i.value=null,i.update(t,o,null),delete n[r]}for(var r in e){var i=null,o,s=e[r];a.has(n,r)?(i=n[r],o=i.value):null!==s&&(i=p(t,r,s),n[r]=i,o=null),o!==s&&(i.value=s,i.update(t,o,s),null===s&&delete n[r])}}}.call(this),function(){l._DOMMaterializer=o.Visitor.extend(),l._DOMMaterializer.def({visitNull:function(e,t){return t},visitPrimitive:function(e,t){var n=String(e);return t.push(document.createTextNode(n)),t},visitCharRef:function(e,t){return this.visitPrimitive(e.str,t)},visitArray:function(e,t){for(var n=0;n<e.length;n++)this.visit(e[n],t);return t},visitComment:function(e,t){return t.push(document.createComment(e.sanitizedValue)),t},visitRaw:function(e,t){for(var n=l._DOMBackend.parseHTML(e.value),r=0;r<n.length;r++)t.push(n[r]);return t},visitTag:function(t,n){var i=this,s=t.tagName,u;u=(o.isKnownSVGElement(s)||e(t))&&document.createElementNS?document.createElementNS("http://www.w3.org/2000/svg",s):document.createElement(s);var c=t.attrs,d=t.children;if("textarea"===s&&t.children.length&&!(c&&"value"in c)){if("function"==typeof c||o.isArray(c))throw new Error("Can't have reactive children of TEXTAREA node; use the 'value' attribute instead.");c=a.extend({},c||null),c.value=l._expand(d,i.parentView),d=[]}if(c){var f=new h(u),p=function(){var e=i.parentView,t=l._expandAttributes(c,e),n=o.flattenAttributes(t),r={};for(var a in n)r[a]=l._toText(n[a],e,o.TEXTMODE.STRING);f.update(r)},m;m=i.parentView?i.parentView.autorun(p):r.nonreactive(function(){return r.autorun(function(){r._withCurrentView(i.parentView,p)})}),l._DOMBackend.Teardown.onElementTeardown(u,function g(){m.stop()})}for(var w=i.visit(d,[]),v=0;v<w.length;v++){var _=w[v];_ instanceof l._DOMRange?_.attach(u):u.appendChild(_)}return n.push(u),n},visitObject:function(e,t){return e instanceof l.Template&&(e=e.constructView()),e instanceof l.View?(t.push(l._materializeView(e,this.parentView)),t):o.Visitor.prototype.visitObject.call(this,e)}});var e=function(e){return"a"===e.tagName&&e.attrs&&void 0!==e.attrs["xlink:href"]}}.call(this),function(){var t;l._throwNextException=!1,l._reportException=function(n,r){if(l._throwNextException)throw l._throwNextException=!1,n;t||(t=function(){return"undefined"!=typeof e?e._debug:"undefined"!=typeof console&&console.log?console.log:function(){}}),t()(r||"Exception caught in template:",n.stack||n.message)},l._wrapCatchingExceptions=function(e,t){return"function"!=typeof e?e:function(){try{return e.apply(this,arguments)}catch(n){l._reportException(n,"Exception in "+t+":")}}}}.call(this),function(){l.View=function(e,t){return this instanceof l.View?("function"==typeof e&&(t=e,e=""),this.name=e,this._render=t,this._callbacks={created:null,rendered:null,destroyed:null},this.isCreated=!1,this._isCreatedForExpansion=!1,this.isRendered=!1,this._isAttached=!1,this.isDestroyed=!1,this._isInRender=!1,this.parentView=null,this._domrange=null,this._hasGeneratedParent=!1,void(this.renderCount=0)):new l.View(e,t)},l.View.prototype._render=function(){return null},l.View.prototype.onViewCreated=function(e){this._callbacks.created=this._callbacks.created||[],this._callbacks.created.push(e)},l.View.prototype._onViewRendered=function(e){this._callbacks.rendered=this._callbacks.rendered||[],this._callbacks.rendered.push(e)},l.View.prototype.onViewReady=function(e){var t=this,n=function(){r.afterFlush(function(){t.isDestroyed||l._withCurrentView(t,function(){e.call(t)})})};t._onViewRendered(function i(){t.isDestroyed||(t._domrange.attached?n():t._domrange.onAttached(n))})},l.View.prototype.onViewDestroyed=function(e){this._callbacks.destroyed=this._callbacks.destroyed||[],this._callbacks.destroyed.push(e)},l.View.prototype.autorun=function(e,t){var n=this;if(!n.isCreated)throw new Error("View#autorun must be called from the created callback at the earliest");if(this._isInRender)throw new Error("Can't call View#autorun from inside render(); try calling it from the created or rendered callback");if(r.active)throw new Error("Can't call View#autorun from a Tracker Computation; try calling it from the created or rendered callback");var i=r.autorun(function a(r){return l._withCurrentView(t||n,function(){return e.call(n,r)})});return n.onViewDestroyed(function(){i.stop()}),i},l.View.prototype.firstNode=function(){if(!this._isAttached)throw new Error("View must be attached before accessing its DOM");return this._domrange.firstNode()},l.View.prototype.lastNode=function(){if(!this._isAttached)throw new Error("View must be attached before accessing its DOM");return this._domrange.lastNode()},l._fireCallbacks=function(e,t){l._withCurrentView(e,function(){r.nonreactive(function n(){for(var n=e._callbacks[t],r=0,i=n&&n.length;i>r;r++)n[r].call(e)})})},l._createView=function(e,t,n){if(e.isCreated)throw new Error("Can't render the same View twice");e.parentView=t||null,e.isCreated=!0,n&&(e._isCreatedForExpansion=!0),l._fireCallbacks(e,"created")},l._materializeView=function(e,t){l._createView(e,t);var n,i;return r.nonreactive(function(){e.autorun(function a(t){e.renderCount++,e._isInRender=!0;var a=e._render();e._isInRender=!1,r.nonreactive(function o(){var r=new l._DOMMaterializer({parentView:e}),o=r.visit(a,[]);(t.firstRun||!l._isContentEqual(i,a))&&(t.firstRun?(n=new l._DOMRange(o),e._domrange=n,n.view=e,e.isRendered=!0):n.setMembers(o),l._fireCallbacks(e,"rendered"))}),i=a,r.onInvalidate(function(){n.destroyMembers()})});var t=null;n.onAttached(function o(n,r){e._isAttached=!0,t=l._DOMBackend.Teardown.onElementTeardown(r,function i(){l._destroyView(e,!0)})}),e.onViewDestroyed(function(){t&&t.stop(),t=null})}),n},l._expandView=function(e,t){l._createView(e,t,!0),e._isInRender=!0;var n=l._withCurrentView(e,function(){return e._render()});e._isInRender=!1;var i=l._expand(n,e);return r.active?r.onInvalidate(function(){l._destroyView(e)}):l._destroyView(e),i},l._HTMLJSExpander=o.TransformingVisitor.extend(),l._HTMLJSExpander.def({visitObject:function(e){return e instanceof l.Template&&(e=e.constructView()),e instanceof l.View?l._expandView(e,this.parentView):o.TransformingVisitor.prototype.visitObject.call(this,e)},visitAttributes:function(e){return"function"==typeof e&&(e=l._withCurrentView(this.parentView,e)),o.TransformingVisitor.prototype.visitAttributes.call(this,e)},visitAttribute:function(e,t,n){return"function"==typeof t&&(t=l._withCurrentView(this.parentView,t)),o.TransformingVisitor.prototype.visitAttribute.call(this,e,t,n)}});var e=function(){var e=l.currentView;return e&&e._isInRender?e:null};l._expand=function(t,n){return n=n||e(),new l._HTMLJSExpander({parentView:n}).visit(t)},l._expandAttributes=function(t,n){return n=n||e(),new l._HTMLJSExpander({parentView:n}).visitAttributes(t)},l._destroyView=function(e,t){e.isDestroyed||(e.isDestroyed=!0,l._fireCallbacks(e,"destroyed"),e._domrange&&e._domrange.destroyMembers(t))},l._destroyNode=function(e){1===e.nodeType&&l._DOMBackend.Teardown.tearDownElement(e)},l._isContentEqual=function(e,t){return e instanceof o.Raw?t instanceof o.Raw&&e.value===t.value:null==e?null==t:e===t&&("number"==typeof e||"boolean"==typeof e||"string"==typeof e)},l.currentView=null,l._withCurrentView=function(e,t){var n=l.currentView;try{return l.currentView=e,t()}finally{l.currentView=n}};var t=function(e){if(null===e)throw new Error("Can't render null");if("undefined"==typeof e)throw new Error("Can't render undefined");if(!(e instanceof l.View||e instanceof l.Template||"function"==typeof e))try{(new o.Visitor).visit(e)}catch(t){throw new Error("Expected Template or View")}},n=function(e){if(t(e),e instanceof l.Template)return e.constructView();if(e instanceof l.View)return e;var n=e;return"function"!=typeof n&&(n=function(){return e}),l.View("render",n)},i=function(e){return t(e),"function"!=typeof e?function(){return e}:e};l.render=function(t,r,i,a){if(r||l._warn("Blaze.render without a parent element is deprecated. You must specify where to insert the rendered content."),i instanceof l.View&&(a=i,i=null),r&&"number"!=typeof r.nodeType)throw new Error("'parentElement' must be a DOM node");if(i&&"number"!=typeof i.nodeType)throw new Error("'nextNode' must be a DOM node");a=a||e();var o=n(t);return l._materializeView(o,a),r&&o._domrange.attach(r,i),o},l.insert=function(e,t,n){if(l._warn("Blaze.insert has been deprecated. Specify where to insert the rendered content in the call to Blaze.render."),!(e&&e._domrange instanceof l._DOMRange))throw new Error("Expected template rendered with Blaze.render");e._domrange.attach(t,n)},l.renderWithData=function(e,t,n,r,a){return l.render(l._TemplateWith(t,i(e)),n,r,a)},l.remove=function(e){if(!(e&&e._domrange instanceof l._DOMRange))throw new Error("Expected template rendered with Blaze.render");for(;e;){if(!e.isDestroyed){var t=e._domrange;t.attached&&!t.parentRange&&t.detach(),t.destroy()}e=e._hasGeneratedParent&&e.parentView}},l.toHTML=function(t,r){return r=r||e(),o.toHTML(l._expandView(n(t),r))},l.toHTMLWithData=function(t,n,r){return r=r||e(),o.toHTML(l._expandView(l._TemplateWith(n,i(t)),r))},l._toText=function(t,n,r){if("function"==typeof t)throw new Error("Blaze._toText doesn't take a function, just HTMLjs");if(null==n||n instanceof l.View||(r=n,n=null),n=n||e(),!r)throw new Error("textMode required");if(r!==o.TEXTMODE.STRING&&r!==o.TEXTMODE.RCDATA&&r!==o.TEXTMODE.ATTRIBUTE)throw new Error("Unknown textMode: "+r);return o.toText(l._expand(t,n),r)},l.getData=function(e){var t;if(e)if(e instanceof l.View){var n=e;t="with"===n.name?n:l.getView(n,"with")}else{if("number"!=typeof e.nodeType)throw new Error("Expected DOM element or View");if(1!==e.nodeType)throw new Error("Expected DOM element");t=l.getView(e,"with")}else t=l.getView("with");return t?t.dataVar.get():null},l.getElementData=function(e){if(l._warn("Blaze.getElementData has been deprecated. Use Blaze.getData(element) instead."),1!==e.nodeType)throw new Error("Expected DOM element");return l.getData(e)},l.getView=function(e,t){var n=t;if("string"==typeof e&&(n=e,e=null),e){if(e instanceof l.View)return l._getParentView(e,n);if("number"==typeof e.nodeType)return l._getElementView(e,n);throw new Error("Expected DOM element or View")}return l._getCurrentView(n)},l._getCurrentView=function(e){var t=l.currentView;if(!t)throw new Error("There is no current view");if(e){for(;t&&t.name!==e;)t=t.parentView;return t||null}return t},l._getParentView=function(e,t){var n=e.parentView;if(t)for(;n&&n.name!==t;)n=n.parentView;return n||null},l._getElementView=function(e,t){for(var n=l._DOMRange.forElement(e),r=null;n&&!r;)r=n.view||null,r||(n=n.parentRange?n.parentRange:l._DOMRange.forElement(n.parentElement));if(t){for(;r&&r.name!==t;)r=r.parentView;return r||null}return r},l._addEventMap=function(e,t,n){n=n||null;var r=[];if(!e._domrange)throw new Error("View must have a DOMRange");e._domrange.onAttached(function i(o,s){a.each(t,function(t,i){var u=i.split(/,\s+/);a.each(u,function(i){var a=i.split(/\s+/);if(0!==a.length){var u=a.shift(),c=a.join(" ");r.push(l._EventSupport.listen(s,u,c,function(r){if(!o.containsElement(r.currentTarget))return null;var i=n||this,a=arguments;return l._withCurrentView(e,function(){return t.apply(i,a)})},o,function(e){return e.parentRange}))}})})}),e.onViewDestroyed(function(){a.each(r,function(e){e.stop()}),r.length=0})}}.call(this),function(){l._calculateCondition=function(e){return e instanceof Array&&0===e.length&&(e=!1),!!e},l.With=function(e,t){var n=l.View("with",t);return n.dataVar=new u,n.onViewCreated(function(){"function"==typeof e?n.autorun(function(){n.dataVar.set(e())},n.parentView):n.dataVar.set(e)}),n},l.If=function(e,t,n,r){var i=new u,a=l.View(r?"unless":"if",function(){return i.get()?t():n?n():null});return a.__conditionVar=i,a.onViewCreated(function(){this.autorun(function(){var t=l._calculateCondition(e());i.set(r?!t:t)},this.parentView)}),a},l.Unless=function(e,t,n){return l.If(e,t,n,!0)},l.Each=function(e,t,n){var i=l.View("each",function(){var e=this.initialSubviews;return this.initialSubviews=null,this._isCreatedForExpansion&&(this.expandedValueDep=new r.Dependency,this.expandedValueDep.depend()),e});return i.initialSubviews=[],i.numItems=0,i.inElseMode=!1,i.stopHandle=null,i.contentFunc=t,i.elseFunc=n,i.argVar=new u,i.onViewCreated(function(){i.autorun(function(){i.argVar.set(e())},i.parentView),i.stopHandle=s.observe(function(){return i.argVar.get()},{addedAt:function(e,t,n){r.nonreactive(function(){var e=l.With(t,i.contentFunc);if(i.numItems++,i.expandedValueDep)i.expandedValueDep.changed();else if(i._domrange){i.inElseMode&&(i._domrange.removeMember(0),i.inElseMode=!1);var r=l._materializeView(e,i);i._domrange.addMember(r,n)}else i.initialSubviews.splice(n,0,e)})},removedAt:function(e,t,n){r.nonreactive(function(){i.numItems--,i.expandedValueDep?i.expandedValueDep.changed():i._domrange?(i._domrange.removeMember(n),i.elseFunc&&0===i.numItems&&(i.inElseMode=!0,i._domrange.addMember(l._materializeView(l.View("each_else",i.elseFunc),i),0))):i.initialSubviews.splice(n,1)})},changedAt:function(e,t,n,a){r.nonreactive(function(){var e;i.expandedValueDep?i.expandedValueDep.changed():e=i._domrange?i._domrange.getMember(a).view:i.initialSubviews[a],e.dataVar.set(t)})},movedTo:function(e,t,n,a){r.nonreactive(function(){if(i.expandedValueDep)i.expandedValueDep.changed();else if(i._domrange)i._domrange.moveMember(n,a);else{var e=i.initialSubviews,t=e[n];e.splice(n,1),e.splice(a,0,t)}})}}),i.elseFunc&&0===i.numItems&&(i.inElseMode=!0,i.initialSubviews[0]=l.View("each_else",i.elseFunc))}),i.onViewDestroyed(function(){i.stopHandle&&i.stopHandle.stop()}),i},l._TemplateWith=function(e,t){var n,r=e;"function"!=typeof e&&(r=function(){return e});var i=function(){var e=null;return n.parentView&&"InOuterTemplateScope"===n.parentView.name&&(e=n.parentView.originalParentView),e?l._withCurrentView(e,r):r()},a=function(){var e=t.call(this);return e instanceof l.Template&&(e=e.constructView()),e instanceof l.View&&(e._hasGeneratedParent=!0),e};return n=l.With(i,a),n.__isTemplateWith=!0,n},l._InOuterTemplateScope=function(e,t){var n=l.View("InOuterTemplateScope",t),r=e.parentView;return r.__isTemplateWith&&(r=r.parentView),n.onViewCreated(function(){this.originalParentView=this.parentView,this.parentView=r}),n},l.InOuterTemplateScope=l._InOuterTemplateScope}.call(this),function(){l._globalHelpers={},l.registerHelper=function(e,t){l._globalHelpers[e]=t};var e=function(e,t){return"function"!=typeof e?e:function(){return e.apply(t,arguments)}},t=function(e){return"function"==typeof e?function(){var t=l.getData();return null==t&&(t={}),e.apply(t,arguments)}:e};l._OLDSTYLE_HELPER={};var n=l._getTemplateHelper=function(e,t){var n=!1;if(e.__helpers.has(t)){var r=e.__helpers.get(t);if(r!==l._OLDSTYLE_HELPER)return r;n=!0}return t in e?(n||(e.__helpers.set(t,l._OLDSTYLE_HELPER),e._NOWARN_OLDSTYLE_HELPERS||l._warn("Assigning helper with `"+e.viewName+"."+t+" = ...` is deprecated. Use `"+e.viewName+".helpers(...)` instead.")),e[t]):null},r=function(e){return l._wrapCatchingExceptions(e,"template helper")};l.View.prototype.lookup=function(e,i){var a=this.template,o=i&&i.template,s;if(/^\./.test(e)){if(!/^(\.)+$/.test(e))throw new Error("id starting with dot must be a series of dots");return l._parentData(e.length-1,!0)}return a&&null!=(s=n(a,e))?r(t(s)):o&&e in l.Template&&l.Template[e]instanceof l.Template?l.Template[e]:null!=l._globalHelpers[e]?r(t(l._globalHelpers[e])):function(){var t=arguments.length>0,n=l.getData();if(o&&(!n||!n[e]))throw new Error("No such template: "+e);if(t&&(!n||!n[e]))throw new Error("No such function: "+e);if(!n)return null;var r=n[e];if("function"!=typeof r){if(t)throw new Error("Can't call non-function: "+r);return r}return r.apply(n,arguments)};return null},l._parentData=function(e,t){null==e&&(e=1);for(var n=l.getView("with"),r=0;e>r&&n;r++)n=l.getView(n,"with");return n?t?function(){return n.dataVar.get()}:n.dataVar.get():null},l.View.prototype.lookupTemplate=function(e){return this.lookup(e,{template:!0})}}.call(this),function(){l.Template=function(e,n){if(!(this instanceof l.Template))return new l.Template(e,n);if("function"==typeof e&&(n=e,e=""),"string"!=typeof e)throw new Error("viewName must be a String (or omitted)");if("function"!=typeof n)throw new Error("renderFunction must be a function");this.viewName=e,this.renderFunction=n,this.__helpers=new t,this.__eventMaps=[]};var e=l.Template,t=function(){};t.prototype.get=function(e){return this[" "+e]},t.prototype.set=function(e,t){this[" "+e]=t},t.prototype.has=function(e){return" "+e in this},l.isTemplate=function(e){return e instanceof l.Template},e.prototype.constructView=function(t,n){var r=this,i=l.View(r.viewName,r.renderFunction);return i.template=r,i.templateContentBlock=t?new e("(contentBlock)",t):null,i.templateElseBlock=n?new e("(elseBlock)",n):null,(r.__eventMaps||"object"==typeof r.events)&&i._onViewRendered(function(){1===i.renderCount&&(r.__eventMaps.length||"object"!=typeof r.events||e.prototype.events.call(r,r.events),a.each(r.__eventMaps,function(e){l._addEventMap(i,e,i)}))}),i._templateInstance=new l.TemplateInstance(i),i.templateInstance=function(){var e=i._templateInstance;return e.data=l.getData(i),i._domrange&&!i.isDestroyed?(e.firstNode=i._domrange.firstNode(),e.lastNode=i._domrange.lastNode()):(e.firstNode=null,e.lastNode=null),e},r.created&&i.onViewCreated(function(){r.created.call(i.templateInstance())}),r.rendered&&i.onViewReady(function(){r.rendered.call(i.templateInstance())}),r.destroyed&&i.onViewDestroyed(function(){r.destroyed.call(i.templateInstance())}),i},l.TemplateInstance=function(e){if(!(this instanceof l.TemplateInstance))return new l.TemplateInstance(e);if(!(e instanceof l.View))throw new Error("View required");e._templateInstance=this,this.view=e,this.data=null,this.firstNode=null,this.lastNode=null},l.TemplateInstance.prototype.$=function(e){var t=this.view;if(!t._domrange)throw new Error("Can't use $ on template instance with no DOM");return t._domrange.$(e)},l.TemplateInstance.prototype.findAll=function(e){return Array.prototype.slice.call(this.$(e))},l.TemplateInstance.prototype.find=function(e){var t=this.$(e);return t[0]||null},l.TemplateInstance.prototype.autorun=function(e){return this.view.autorun(e)
+},e.prototype.helpers=function(e){for(var t in e)this.__helpers.set(t,e[t])},e.prototype.events=function(e){var t=this,n={};for(var r in e)n[r]=function(e,t){return function(e){var n=this,r=l.getData(e.currentTarget);null==r&&(r={});var i=Array.prototype.slice.call(arguments),a=n.templateInstance();return i.splice(1,0,a),t.apply(r,i)}}(r,e[r]);t.__eventMaps.push(n)},e.instance=function(){for(var e=l.currentView;e&&!e.template;)e=e.parentView;return e?e.templateInstance():null},e.currentData=l.getData,e.parentData=l._parentData,e.registerHelper=l.registerHelper}.call(this),function(){c=l,l.ReactiveVar=u,c._templateInstance=l.Template.instance,d={},d.registerHelper=l.registerHelper,d._escape=l._escape,d.SafeString=function(e){this.string=e},d.SafeString.prototype.toString=function(){return this.string.toString()}}.call(this),"undefined"==typeof Package&&(Package={}),Package.blaze={Blaze:l,UI:c,Handlebars:d}}();
+
+!function(){var e=Package.meteor.Meteor,n=Package.underscore._,t=Package.blaze.Blaze,o=Package.blaze.UI,a=Package.blaze.Handlebars,d=Package.htmljs.HTML,c;(function(){c=t.Template;var e="__proto__ name".split(" ");c.__checkName=function(t){if(t in c||n.contains(e,t)){if(c[t]instanceof c&&"body"!==t)throw new Error("There are multiple templates named '"+t+"'. Each template needs a unique name.");throw new Error("This template name is reserved: "+t)}},c.__define__=function(e,n){c.__checkName(e),c[e]=new c("Template."+e,n),c[e]._NOWARN_OLDSTYLE_HELPERS=!0},c.body=new c("body",function(){for(var e=c.body.contentViews,n=0;n<e.length;n++)e[n].template=c.body;return e}),c.body.contentViews=[],c.body.view=null,c.body.addContent=function(e){var n="body_content_"+c.body.contentViews.length;c.body.contentViews.push(t.View(n,e))},c.body.renderToDocument=function(){if(!c.body.view){var e=t.render(c.body,document.body);c.body.view=e}},o.body=c.body,c.__body__=c.body,c.__body__.__contentParts=c.body.contentViews,c.__body__.__instantiate=c.body.renderToDocument}).call(this),"undefined"==typeof Package&&(Package={}),Package.templating={Template:c}}();
+
+!function(){var e=Package.underscore._,n=Package.meteor.Meteor,r=Package.tracker.Tracker,t=Package.tracker.Deps,a=Package.session.Session,u=Package.jquery.$,o=Package.jquery.jQuery,s=Package.templating.Template,l=Package.blaze.Blaze,i=Package.blaze.UI,c=Package.blaze.Handlebars,f=Package.htmljs.HTML,p,m,g,d;(function(){g={fallback_language:"en",langauges_tags_regex:"([a-z]{2})(-[A-Z]{2})?",project_translations_domain:"project",browser_path:"/tap-i18n",debug:!1}}).call(this),function(){p={},function(){function e(e,n){if(!n||"function"==typeof n)return e;for(var r in n)e[r]=n[r];return e}function n(e,n,r){var t,a=0,u=e.length,o=void 0===u||"[object Array]"!==Object.prototype.toString.apply(e)||"function"==typeof e;if(r)if(o){for(t in e)if(n.apply(e[t],r)===!1)break}else for(;u>a&&n.apply(e[a++],r)!==!1;);else if(o){for(t in e)if(n.call(e[t],t,e[t])===!1)break}else for(;u>a&&n.call(e[a],a,e[a++])!==!1;);return e}function r(e){return"string"==typeof e?e.replace(/[&<>"'\/]/g,function(e){return E[e]}):e}function t(e){var n=function(e){if(window.XMLHttpRequest)return e(null,new XMLHttpRequest);if(window.ActiveXObject)try{return e(null,new ActiveXObject("Msxml2.XMLHTTP"))}catch(n){return e(null,new ActiveXObject("Microsoft.XMLHTTP"))}return e(new Error)},r=function(e){if("string"==typeof e)return e;var n=[];for(var r in e)e.hasOwnProperty(r)&&n.push(encodeURIComponent(r)+"="+encodeURIComponent(e[r]));return n.join("&")},t=function(e){e=e.replace(/\r\n/g,"\n");for(var n="",r=0;r<e.length;r++){var t=e.charCodeAt(r);128>t?n+=String.fromCharCode(t):t>127&&2048>t?(n+=String.fromCharCode(t>>6|192),n+=String.fromCharCode(63&t|128)):(n+=String.fromCharCode(t>>12|224),n+=String.fromCharCode(t>>6&63|128),n+=String.fromCharCode(63&t|128))}return n},a=function(e){var n="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";e=t(e);var r="",a,u,o,s,l,i,c,f=0;do a=e.charCodeAt(f++),u=e.charCodeAt(f++),o=e.charCodeAt(f++),s=a>>2,l=(3&a)<<4|u>>4,i=(15&u)<<2|o>>6,c=63&o,isNaN(u)?i=c=64:isNaN(o)&&(c=64),r+=n.charAt(s)+n.charAt(l)+n.charAt(i)+n.charAt(c),a=u=o="",s=l=i=c="";while(f<e.length);return r},u=function(){for(var e=arguments[0],n=1;n<arguments.length;n++){var r=arguments[n];for(var t in r)r.hasOwnProperty(t)&&(e[t]=r[t])}return e},o=function(e,t,a,s){"function"==typeof a&&(s=a,a={}),a.cache=a.cache||!1,a.data=a.data||{},a.headers=a.headers||{},a.jsonp=a.jsonp||!1,a.async=void 0===a.async?!0:a.async;var l=u({accept:"*/*","content-type":"application/x-www-form-urlencoded;charset=UTF-8"},o.headers,a.headers),i;if(i="application/json"===l["content-type"]?JSON.stringify(a.data):r(a.data),"GET"===e){var c=[];if(i&&(c.push(i),i=null),a.cache||c.push("_="+(new Date).getTime()),a.jsonp&&(c.push("callback="+a.jsonp),c.push("jsonp="+a.jsonp)),c=c.join("&"),c.length>1&&(t+=t.indexOf("?")>-1?"&"+c:"?"+c),a.jsonp){var f=document.getElementsByTagName("head")[0],p=document.createElement("script");return p.type="text/javascript",p.src=t,void f.appendChild(p)}}n(function(n,r){if(n)return s(n);r.open(e,t,a.async);for(var u in l)l.hasOwnProperty(u)&&r.setRequestHeader(u,l[u]);r.onreadystatechange=function(){if(4===r.readyState){var e=r.responseText||"";if(!s)return;s(r.status,{text:function(){return e},json:function(){return JSON.parse(e)}})}},r.send(i)})},s={authBasic:function(e,n){o.headers.Authorization="Basic "+a(e+":"+n)},connect:function(e,n,r){return o("CONNECT",e,n,r)},del:function(e,n,r){return o("DELETE",e,n,r)},get:function(e,n,r){return o("GET",e,n,r)},head:function(e,n,r){return o("HEAD",e,n,r)},headers:function(e){o.headers=e||{}},isAllowed:function(e,n,r){this.options(e,function(e,t){r(-1!==t.text().indexOf(n))})},options:function(e,n,r){return o("OPTIONS",e,n,r)},patch:function(e,n,r){return o("PATCH",e,n,r)},post:function(e,n,r){return o("POST",e,n,r)},put:function(e,n,r){return o("PUT",e,n,r)},trace:function(e,n,r){return o("TRACE",e,n,r)}},l=e.type?e.type.toLowerCase():"get";s[l](e.url,e,function(n,r){200===n?e.success(r.json(),n,null):e.error(r.text(),n,null)})}function a(e,n){"function"==typeof e&&(n=e,e={}),e=e||{},D.extend(M,e),delete M.fixLng,"string"==typeof M.ns&&(M.ns={namespaces:[M.ns],defaultNs:M.ns}),"string"==typeof M.fallbackNS&&(M.fallbackNS=[M.fallbackNS]),("string"==typeof M.fallbackLng||"boolean"==typeof M.fallbackLng)&&(M.fallbackLng=[M.fallbackLng]),M.interpolationPrefixEscaped=D.regexEscape(M.interpolationPrefix),M.interpolationSuffixEscaped=D.regexEscape(M.interpolationSuffix),M.lng||(M.lng=D.detectLanguage()),M.lng?M.useCookie&&D.cookie.create(M.cookieName,M.lng,M.cookieExpirationTime,M.cookieDomain):(M.lng=M.fallbackLng[0],M.useCookie&&D.cookie.remove(M.cookieName)),A=D.toLanguages(M.lng),O=A[0],D.log("currentLng set to: "+O);var r=x;e.fixLng&&(r=function(e,n){return n=n||{},n.lng=n.lng||r.lng,x(e,n)},r.lng=O),z.setCurrentLng(O),S&&M.setJqueryExt&&g();var t;if(S&&S.Deferred&&(t=S.Deferred()),!M.resStore){var a=D.toLanguages(M.lng);"string"==typeof M.preload&&(M.preload=[M.preload]);for(var u=0,o=M.preload.length;o>u;u++)for(var s=D.toLanguages(M.preload[u]),l=0,i=s.length;i>l;l++)a.indexOf(s[l])<0&&a.push(s[l]);return p.sync.load(a,M,function(e,a){T=a,C=!0,n&&n(r),t&&t.resolve(r)}),t?t.promise():void 0}return T=M.resStore,C=!0,n&&n(r),t&&t.resolve(r),t?t.promise():void 0}function u(e,n){"string"==typeof e&&(e=[e]);for(var r=0,t=e.length;t>r;r++)M.preload.indexOf(e[r])<0&&M.preload.push(e[r]);return a(n)}function o(e,n,r){"string"!=typeof n?(r=n,n=M.ns.defaultNs):M.ns.namespaces.indexOf(n)<0&&M.ns.namespaces.push(n),T[e]=T[e]||{},T[e][n]=T[e][n]||{},D.extend(T[e][n],r)}function s(e,n){"string"!=typeof n&&(n=M.ns.defaultNs),T[e]=T[e]||{},T[e][n]={}}function l(e){M.ns.defaultNs=e}function i(e,n){c([e],n)}function c(e,n){var r={dynamicLoad:M.dynamicLoad,resGetPath:M.resGetPath,getAsync:M.getAsync,customLoad:M.customLoad,ns:{namespaces:e,defaultNs:""}},t=D.toLanguages(M.lng);"string"==typeof M.preload&&(M.preload=[M.preload]);for(var a=0,u=M.preload.length;u>a;a++)for(var o=D.toLanguages(M.preload[a]),s=0,l=o.length;l>s;s++)t.indexOf(o[s])<0&&t.push(o[s]);for(var i=[],c=0,f=t.length;f>c;c++){var m=!1,g=T[t[c]];if(g)for(var d=0,b=e.length;b>d;d++)g[e[d]]||(m=!0);else m=!0;m&&i.push(t[c])}i.length?p.sync._fetch(i,r,function(r,t){var a=e.length*i.length;D.each(e,function(e,r){M.ns.namespaces.indexOf(r)<0&&M.ns.namespaces.push(r),D.each(i,function(e,u){T[u]=T[u]||{},T[u][r]=t[u][r],a--,0===a&&n&&(M.useLocalStorage&&p.sync._storeLocal(T),n())})})}):n&&n()}function f(e,n,r){return"function"==typeof n?(r=n,n={}):n||(n={}),n.lng=e,a(n,r)}function m(){return O}function g(){function e(e,n,r){if(0!==n.length){var t="text";if(0===n.indexOf("[")){var a=n.split("]");n=a[1],t=a[0].substr(1,a[0].length-1)}n.indexOf(";")===n.length-1&&(n=n.substr(0,n.length-2));var u;if("html"===t)u=M.defaultValueFromContent?S.extend({defaultValue:e.html()},r):r,e.html(S.t(n,u));else if("text"===t)u=M.defaultValueFromContent?S.extend({defaultValue:e.text()},r):r,e.text(S.t(n,u));else if("prepend"===t)u=M.defaultValueFromContent?S.extend({defaultValue:e.html()},r):r,e.prepend(S.t(n,u));else if("append"===t)u=M.defaultValueFromContent?S.extend({defaultValue:e.html()},r):r,e.append(S.t(n,u));else if(0===t.indexOf("data-")){var o=t.substr("data-".length);u=M.defaultValueFromContent?S.extend({defaultValue:e.data(o)},r):r;var s=S.t(n,u);e.data(o,s),e.attr(t,s)}else u=M.defaultValueFromContent?S.extend({defaultValue:e.attr(t)},r):r,e.attr(t,S.t(n,u))}}function n(n,r){var t=n.attr(M.selectorAttr);if(t||"undefined"==typeof t||t===!1||(t=n.text()||n.val()),t){var a=n,u=n.data("i18n-target");if(u&&(a=n.find(u)||n),r||M.useDataAttrOptions!==!0||(r=n.data("i18n-options")),r=r||{},t.indexOf(";")>=0){var o=t.split(";");S.each(o,function(n,t){""!==t&&e(a,t,r)})}else e(a,t,r);M.useDataAttrOptions===!0&&n.data("i18n-options",r)}}S.t=S.t||x,S.fn.TAPi18next=function(e){return this.each(function(){n(S(this),e);var r=S(this).find("["+M.selectorAttr+"]");r.each(function(){n(S(this),e)})})}}function d(e,n,r,t){if(!e)return e;if(t=t||n,e.indexOf(t.interpolationPrefix||M.interpolationPrefix)<0)return e;var a=t.interpolationPrefix?D.regexEscape(t.interpolationPrefix):M.interpolationPrefixEscaped,u=t.interpolationSuffix?D.regexEscape(t.interpolationSuffix):M.interpolationSuffixEscaped,o="HTML"+u;return D.each(n,function(n,s){var l=r?r+M.keyseparator+n:n;"object"==typeof s&&null!==s?e=d(e,s,l,t):t.escapeInterpolation||M.escapeInterpolation?(e=e.replace(new RegExp([a,l,o].join(""),"g"),s),e=e.replace(new RegExp([a,l,u].join(""),"g"),D.escape(s))):e=e.replace(new RegExp([a,l,u].join(""),"g"),s)}),e}function b(e,n){var r=",",t="{",a="}",u=D.extend({},n);for(delete u.postProcess;-1!=e.indexOf(M.reusePrefix)&&(w++,!(w>M.maxRecursion));){var o=e.lastIndexOf(M.reusePrefix),s=e.indexOf(M.reuseSuffix,o)+M.reuseSuffix.length,l=e.substring(o,s),i=l.replace(M.reusePrefix,"").replace(M.reuseSuffix,"");if(-1!=i.indexOf(r)){var c=i.indexOf(r);if(-1!=i.indexOf(t,c)&&-1!=i.indexOf(a,c)){var f=i.indexOf(t,c),p=i.indexOf(a,f)+a.length;try{u=D.extend(u,JSON.parse(i.substring(f,p))),i=i.substring(0,c)}catch(m){}}}var g=k(i,u);e=e.replace(l,g)}return e}function h(e){return e.context&&("string"==typeof e.context||"number"==typeof e.context)}function v(e){return void 0!==e.count&&"string"!=typeof e.count&&1!==e.count}function y(e,n){n=n||{};var r=N(e,n),t=L(e,n);return void 0!==t||t===r}function x(e,n){return n=n||{},C?(w=0,k.apply(null,arguments)):(D.log("i18next not finished initialization. you might have called t function before loading resources finished."),n.defaultValue||"")}function N(e,n){return void 0!==n.defaultValue?n.defaultValue:e}function _(){for(var e=[],n=1;n<arguments.length;n++)e.push(arguments[n]);return{postProcess:"sprintf",sprintf:e}}function k(e,n){if(n&&"object"!=typeof n?"sprintf"===M.shortcutFunction?n=_.apply(null,arguments):"defaultValue"===M.shortcutFunction&&(n={defaultValue:n}):n=n||{},void 0===e||null===e)return"";"string"==typeof e&&(e=[e]);var r=e[0];if(e.length>1)for(var t=0;t<e.length&&(r=e[t],!y(r,n));t++);var a=N(r,n),u=L(r,n),o=n.lng?D.toLanguages(n.lng):A,s=n.ns||M.ns.defaultNs,l;r.indexOf(M.nsseparator)>-1&&(l=r.split(M.nsseparator),s=l[0],r=l[1]),void 0===u&&M.sendMissing&&(n.lng?H.postMissing(o[0],s,r,a,o):H.postMissing(M.lng,s,r,a,o));var i=n.postProcess||M.postProcess;void 0!==u&&i&&I[i]&&(u=I[i](u,r,n));var c=a;if(a.indexOf(M.nsseparator)>-1&&(l=a.split(M.nsseparator),c=l[1]),c===r&&M.parseMissingKey&&(a=M.parseMissingKey(a)),void 0===u&&(a=d(a,n),a=b(a,n),i&&I[i])){var f=N(r,n);u=I[i](f,r,n)}return void 0!==u?u:a}function L(e,n){n=n||{};var r,t,a=N(e,n),u=A;if(!T)return a;if("cimode"===u[0].toLowerCase())return a;if(n.lng&&(u=D.toLanguages(n.lng),!T[u[0]])){var o=M.getAsync;M.getAsync=!1,p.sync.load(u,M,function(e,n){D.extend(T,n),M.getAsync=o})}var s=n.ns||M.ns.defaultNs;if(e.indexOf(M.nsseparator)>-1){var l=e.split(M.nsseparator);s=l[0],e=l[1]}if(h(n)){r=D.extend({},n),delete r.context,r.defaultValue=M.contextNotFound;var i=s+M.nsseparator+e+"_"+n.context;if(t=x(i,r),t!=M.contextNotFound)return d(t,{context:n.context})}if(v(n)){r=D.extend({},n),delete r.count,r.defaultValue=M.pluralNotFound;var c=s+M.nsseparator+e+M.pluralSuffix,f=z.get(u[0],n.count);if(f>=0?c=c+"_"+f:1===f&&(c=s+M.nsseparator+e),t=x(c,r),t!=M.pluralNotFound)return d(t,{count:n.count,interpolationPrefix:n.interpolationPrefix,interpolationSuffix:n.interpolationSuffix})}for(var m,g=e.split(M.keyseparator),y=0,_=u.length;_>y&&void 0===m;y++){for(var j=u[y],P=0,S=T[j]&&T[j][s];g[P];)S=S&&S[g[P]],P++;if(void 0!==S){var O=Object.prototype.toString.apply(S);if("string"==typeof S)S=d(S,n),S=b(S,n);else if("[object Array]"!==O||M.returnObjectTrees||n.returnObjectTrees){if(null===S&&M.fallbackOnNull===!0)S=void 0;else if(null!==S)if(M.returnObjectTrees||n.returnObjectTrees){if("[object Number]"!==O&&"[object Function]"!==O&&"[object RegExp]"!==O){var w="[object Array]"===O?[]:{};D.each(S,function(r){w[r]=k(s+M.nsseparator+e+M.keyseparator+r,n)}),S=w}}else M.objectTreeKeyHandler&&"function"==typeof M.objectTreeKeyHandler?S=M.objectTreeKeyHandler(e,S,j,s,n):(S="key '"+s+":"+e+" ("+j+")' returned an object instead of string.",D.log(S))}else S=S.join("\n"),S=d(S,n),S=b(S,n);"string"==typeof S&&""===S.trim()&&M.fallbackOnEmpty===!0&&(S=void 0),m=S}}if(void 0===m&&!n.isFallbackLookup&&(M.fallbackToDefaultNS===!0||M.fallbackNS&&M.fallbackNS.length>0))if(n.isFallbackLookup=!0,M.fallbackNS.length){for(var C=0,E=M.fallbackNS.length;E>C;C++)if(m=L(M.fallbackNS[C]+M.nsseparator+e,n)){var F=m.indexOf(M.nsseparator)>-1?m.split(M.nsseparator)[1]:m,R=a.indexOf(M.nsseparator)>-1?a.split(M.nsseparator)[1]:a;if(F!==R)break}}else m=L(e,n);return m}function j(){var e,n=[];if("undefined"!=typeof window&&(!function(){for(var e=window.location.search.substring(1),r=e.split("&"),t=0;t<r.length;t++){var a=r[t].indexOf("=");if(a>0){var u=r[t].substring(0,a),o=r[t].substring(a+1);n[u]=o}}}(),n[M.detectLngQS]&&(e=n[M.detectLngQS])),!e&&"undefined"!=typeof document&&M.useCookie){var r=D.cookie.read(M.cookieName);r&&(e=r)}return e||"undefined"==typeof navigator||(e=navigator.language?navigator.language:navigator.userLanguage),e}Array.prototype.indexOf||(Array.prototype.indexOf=function(e){"use strict";if(null==this)throw new TypeError;var n=Object(this),r=n.length>>>0;if(0===r)return-1;var t=0;if(arguments.length>0&&(t=Number(arguments[1]),t!=t?t=0:0!=t&&1/0!=t&&t!=-1/0&&(t=(t>0||-1)*Math.floor(Math.abs(t)))),t>=r)return-1;for(var a=t>=0?t:Math.max(r-Math.abs(t),0);r>a;a++)if(a in n&&n[a]===e)return a;return-1}),Array.prototype.lastIndexOf||(Array.prototype.lastIndexOf=function(e){"use strict";if(null==this)throw new TypeError;var n=Object(this),r=n.length>>>0;if(0===r)return-1;var t=r;arguments.length>1&&(t=Number(arguments[1]),t!=t?t=0:0!=t&&t!=1/0&&t!=-(1/0)&&(t=(t>0||-1)*Math.floor(Math.abs(t))));for(var a=t>=0?Math.min(t,r-1):r-Math.abs(t);a>=0;a--)if(a in n&&n[a]===e)return a;return-1}),"function"!=typeof String.prototype.trim&&(String.prototype.trim=function(){return this.replace(/^\s+|\s+$/g,"")});var P=this,S=P.jQuery||P.Zepto,T={},O,w=0,A=[],C=!1;"undefined"!=typeof module&&module.exports?module.exports=p:(S&&(S.TAPi18next=S.TAPi18next||p),P.TAPi18next=P.TAPi18next||p);var M={lng:void 0,load:"all",preload:[],lowerCaseLng:!1,returnObjectTrees:!1,fallbackLng:["dev"],fallbackNS:[],detectLngQS:"setLng",ns:"translation",fallbackOnNull:!0,fallbackOnEmpty:!1,fallbackToDefaultNS:!1,nsseparator:":",keyseparator:".",selectorAttr:"data-i18n",debug:!1,resGetPath:"locales/__lng__/__ns__.json",resPostPath:"locales/add/__lng__/__ns__",getAsync:!0,postAsync:!0,resStore:void 0,useLocalStorage:!1,localStorageExpirationTime:6048e5,dynamicLoad:!1,sendMissing:!1,sendMissingTo:"fallback",sendType:"POST",interpolationPrefix:"__",interpolationSuffix:"__",reusePrefix:"$t(",reuseSuffix:")",pluralSuffix:"_plural",pluralNotFound:["plural_not_found",Math.random()].join(""),contextNotFound:["context_not_found",Math.random()].join(""),escapeInterpolation:!1,setJqueryExt:!1,defaultValueFromContent:!0,useDataAttrOptions:!1,cookieExpirationTime:void 0,useCookie:!0,cookieName:"TAPi18next",cookieDomain:void 0,objectTreeKeyHandler:void 0,postProcess:["sprintf"],parseMissingKey:void 0,shortcutFunction:"sprintf"},E={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;","/":"&#x2F;"},F={create:function(e,n,r,t){var a;if(r){var u=new Date;u.setTime(u.getTime()+60*r*1e3),a="; expires="+u.toGMTString()}else a="";t=t?"domain="+t+";":"",document.cookie=e+"="+n+a+";"+t+"path=/"},read:function(e){for(var n=e+"=",r=document.cookie.split(";"),t=0;t<r.length;t++){for(var a=r[t];" "==a.charAt(0);)a=a.substring(1,a.length);if(0===a.indexOf(n))return a.substring(n.length,a.length)}return null},remove:function(e){this.create(e,"",-1)}},R={create:function(e,n,r,t){},read:function(e){return null},remove:function(e){}},D={extend:S?S.extend:e,each:S?S.each:n,ajax:S?S.ajax:"undefined"!=typeof document?t:function(){},cookie:"undefined"!=typeof document?F:R,detectLanguage:j,escape:r,log:function(e){M.debug&&"undefined"!=typeof console&&console.log(e)},toLanguages:function(e){var n=[];if("string"==typeof e&&e.indexOf("-")>-1){var r=e.split("-");e=M.lowerCaseLng?r[0].toLowerCase()+"-"+r[1].toLowerCase():r[0].toLowerCase()+"-"+r[1].toUpperCase(),"unspecific"!==M.load&&n.push(e),"current"!==M.load&&n.push(r[0])}else n.push(e);for(var t=0;t<M.fallbackLng.length;t++)-1===n.indexOf(M.fallbackLng[t])&&M.fallbackLng[t]&&n.push(M.fallbackLng[t]);return n},regexEscape:function(e){return e.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&")}};D.applyReplacement=d;var H={load:function(e,n,r){n.useLocalStorage?H._loadLocal(e,n,function(t,a){for(var u=[],o=0,s=e.length;s>o;o++)a[e[o]]||u.push(e[o]);u.length>0?H._fetch(u,n,function(e,n){D.extend(a,n),H._storeLocal(n),r(null,a)}):r(null,a)}):H._fetch(e,n,function(e,n){r(null,n)})},_loadLocal:function(e,n,r){var t={},a=(new Date).getTime();if(window.localStorage){var u=e.length;D.each(e,function(e,o){var s=window.localStorage.getItem("res_"+o);s&&(s=JSON.parse(s),s.i18nStamp&&s.i18nStamp+n.localStorageExpirationTime>a&&(t[o]=s)),u--,0===u&&r(null,t)})}},_storeLocal:function(e){if(window.localStorage)for(var n in e)e[n].i18nStamp=(new Date).getTime(),window.localStorage.setItem("res_"+n,JSON.stringify(e[n]))},_fetch:function(e,n,r){var t=n.ns,a={};if(n.dynamicLoad){var u=function(e,n){r(null,n)};if("function"==typeof n.customLoad)n.customLoad(e,t.namespaces,n,u);else{var o=d(n.resGetPath,{lng:e.join("+"),ns:t.namespaces.join("+")});D.ajax({url:o,success:function(e,n,r){D.log("loaded: "+o),u(null,e)},error:function(e,n,r){D.log("failed loading: "+o),u("failed loading resource.json error: "+r)},dataType:"json",async:n.getAsync})}}else{var s=t.namespaces.length*e.length,l;D.each(t.namespaces,function(t,u){D.each(e,function(e,t){var o=function(e,n){e&&(l=l||[],l.push(e)),a[t]=a[t]||{},a[t][u]=n,s--,0===s&&r(l,a)};"function"==typeof n.customLoad?n.customLoad(t,u,n,o):H._fetchOne(t,u,n,o)})})}},_fetchOne:function(e,n,r,t){var a=d(r.resGetPath,{lng:e,ns:n});D.ajax({url:a,success:function(e,n,r){D.log("loaded: "+a),t(null,e)},error:function(e,n,r){if(n&&200==n||e&&e.status&&200==e.status)D.log("There is a typo in: "+a);else if(n&&404==n||e&&e.status&&404==e.status)D.log("Does not exist: "+a);else{var u=n?n:e&&e.status?e.status:null;D.log(u+" when loading "+a)}t(r,{})},dataType:"json",async:r.getAsync})},postMissing:function(e,n,r,t,a){var u={};u[r]=t;var o=[];if("fallback"===M.sendMissingTo&&M.fallbackLng[0]!==!1)for(var s=0;s<M.fallbackLng.length;s++)o.push({lng:M.fallbackLng[s],url:d(M.resPostPath,{lng:M.fallbackLng[s],ns:n})});else if("current"===M.sendMissingTo||"fallback"===M.sendMissingTo&&M.fallbackLng[0]===!1)o.push({lng:e,url:d(M.resPostPath,{lng:e,ns:n})});else if("all"===M.sendMissingTo)for(var s=0,l=a.length;l>s;s++)o.push({lng:a[s],url:d(M.resPostPath,{lng:a[s],ns:n})});for(var i=0,c=o.length;c>i;i++){var f=o[i];D.ajax({url:f.url,type:M.sendType,data:u,success:function(e,a,u){D.log("posted missing key '"+r+"' to: "+f.url);for(var o=r.split("."),s=0,l=T[f.lng][n];o[s];)l=l[o[s]]=s===o.length-1?t:l[o[s]]||{},s++},error:function(e,n,t){D.log("failed posting missing key '"+r+"' to: "+f.url)},dataType:"json",async:M.postAsync})}}},z={rules:{ach:{name:"Acholi",numbers:[1,2],plurals:function(e){return Number(e>1)}},af:{name:"Afrikaans",numbers:[1,2],plurals:function(e){return Number(1!=e)}},ak:{name:"Akan",numbers:[1,2],plurals:function(e){return Number(e>1)}},am:{name:"Amharic",numbers:[1,2],plurals:function(e){return Number(e>1)}},an:{name:"Aragonese",numbers:[1,2],plurals:function(e){return Number(1!=e)}},ar:{name:"Arabic",numbers:[0,1,2,3,11,100],plurals:function(e){return Number(0===e?0:1==e?1:2==e?2:e%100>=3&&10>=e%100?3:e%100>=11?4:5)}},arn:{name:"Mapudungun",numbers:[1,2],plurals:function(e){return Number(e>1)}},ast:{name:"Asturian",numbers:[1,2],plurals:function(e){return Number(1!=e)}},ay:{name:"Aymará",numbers:[1],plurals:function(e){return 0}},az:{name:"Azerbaijani",numbers:[1,2],plurals:function(e){return Number(1!=e)}},be:{name:"Belarusian",numbers:[1,2,5],plurals:function(e){return Number(e%10==1&&e%100!=11?0:e%10>=2&&4>=e%10&&(10>e%100||e%100>=20)?1:2)}},bg:{name:"Bulgarian",numbers:[1,2],plurals:function(e){return Number(1!=e)}},bn:{name:"Bengali",numbers:[1,2],plurals:function(e){return Number(1!=e)}},bo:{name:"Tibetan",numbers:[1],plurals:function(e){return 0}},br:{name:"Breton",numbers:[1,2],plurals:function(e){return Number(e>1)}},bs:{name:"Bosnian",numbers:[1,2,5],plurals:function(e){return Number(e%10==1&&e%100!=11?0:e%10>=2&&4>=e%10&&(10>e%100||e%100>=20)?1:2)}},ca:{name:"Catalan",numbers:[1,2],plurals:function(e){return Number(1!=e)}},cgg:{name:"Chiga",numbers:[1],plurals:function(e){return 0}},cs:{name:"Czech",numbers:[1,2,5],plurals:function(e){return Number(1==e?0:e>=2&&4>=e?1:2)}},csb:{name:"Kashubian",numbers:[1,2,5],plurals:function(e){return Number(1==e?0:e%10>=2&&4>=e%10&&(10>e%100||e%100>=20)?1:2)}},cy:{name:"Welsh",numbers:[1,2,3,8],plurals:function(e){return Number(1==e?0:2==e?1:8!=e&&11!=e?2:3)}},da:{name:"Danish",numbers:[1,2],plurals:function(e){return Number(1!=e)}},de:{name:"German",numbers:[1,2],plurals:function(e){return Number(1!=e)}},dz:{name:"Dzongkha",numbers:[1],plurals:function(e){return 0}},el:{name:"Greek",numbers:[1,2],plurals:function(e){return Number(1!=e)}},en:{name:"English",numbers:[1,2],plurals:function(e){return Number(1!=e)}},eo:{name:"Esperanto",numbers:[1,2],plurals:function(e){return Number(1!=e)}},es:{name:"Spanish",numbers:[1,2],plurals:function(e){return Number(1!=e)}},es_ar:{name:"Argentinean Spanish",numbers:[1,2],plurals:function(e){return Number(1!=e)}},et:{name:"Estonian",numbers:[1,2],plurals:function(e){return Number(1!=e)}},eu:{name:"Basque",numbers:[1,2],plurals:function(e){return Number(1!=e)}},fa:{name:"Persian",numbers:[1],plurals:function(e){return 0}},fi:{name:"Finnish",numbers:[1,2],plurals:function(e){return Number(1!=e)}},fil:{name:"Filipino",numbers:[1,2],plurals:function(e){return Number(e>1)}},fo:{name:"Faroese",numbers:[1,2],plurals:function(e){return Number(1!=e)}},fr:{name:"French",numbers:[1,2],plurals:function(e){return Number(e>1)}},fur:{name:"Friulian",numbers:[1,2],plurals:function(e){return Number(1!=e)}},fy:{name:"Frisian",numbers:[1,2],plurals:function(e){return Number(1!=e)}},ga:{name:"Irish",numbers:[1,2,3,7,11],plurals:function(e){return Number(1==e?0:2==e?1:7>e?2:11>e?3:4)}},gd:{name:"Scottish Gaelic",numbers:[1,2,3,20],plurals:function(e){return Number(1==e||11==e?0:2==e||12==e?1:e>2&&20>e?2:3)}},gl:{name:"Galician",numbers:[1,2],plurals:function(e){return Number(1!=e)}},gu:{name:"Gujarati",numbers:[1,2],plurals:function(e){return Number(1!=e)}},gun:{name:"Gun",numbers:[1,2],plurals:function(e){return Number(e>1)}},ha:{name:"Hausa",numbers:[1,2],plurals:function(e){return Number(1!=e)}},he:{name:"Hebrew",numbers:[1,2],plurals:function(e){return Number(1!=e)}},hi:{name:"Hindi",numbers:[1,2],plurals:function(e){return Number(1!=e)}},hr:{name:"Croatian",numbers:[1,2,5],plurals:function(e){return Number(e%10==1&&e%100!=11?0:e%10>=2&&4>=e%10&&(10>e%100||e%100>=20)?1:2)}},hu:{name:"Hungarian",numbers:[1,2],plurals:function(e){return Number(1!=e)}},hy:{name:"Armenian",numbers:[1,2],plurals:function(e){return Number(1!=e)}},ia:{name:"Interlingua",numbers:[1,2],plurals:function(e){return Number(1!=e)}},id:{name:"Indonesian",numbers:[1],plurals:function(e){return 0}},is:{name:"Icelandic",numbers:[1,2],plurals:function(e){return Number(e%10!=1||e%100==11)}},it:{name:"Italian",numbers:[1,2],plurals:function(e){return Number(1!=e)}},ja:{name:"Japanese",numbers:[1],plurals:function(e){return 0}},jbo:{name:"Lojban",numbers:[1],plurals:function(e){return 0}},jv:{name:"Javanese",numbers:[0,1],plurals:function(e){return Number(0!==e)}},ka:{name:"Georgian",numbers:[1],plurals:function(e){return 0}},kk:{name:"Kazakh",numbers:[1],plurals:function(e){return 0}},km:{name:"Khmer",numbers:[1],plurals:function(e){return 0}},kn:{name:"Kannada",numbers:[1,2],plurals:function(e){return Number(1!=e)}},ko:{name:"Korean",numbers:[1],plurals:function(e){return 0}},ku:{name:"Kurdish",numbers:[1,2],plurals:function(e){return Number(1!=e)}},kw:{name:"Cornish",numbers:[1,2,3,4],plurals:function(e){return Number(1==e?0:2==e?1:3==e?2:3)}},ky:{name:"Kyrgyz",numbers:[1],plurals:function(e){return 0}},lb:{name:"Letzeburgesch",numbers:[1,2],plurals:function(e){return Number(1!=e)}},ln:{name:"Lingala",numbers:[1,2],plurals:function(e){return Number(e>1)}},lo:{name:"Lao",numbers:[1],plurals:function(e){return 0}},lt:{name:"Lithuanian",numbers:[1,2,10],plurals:function(e){return Number(e%10==1&&e%100!=11?0:e%10>=2&&(10>e%100||e%100>=20)?1:2)}},lv:{name:"Latvian",numbers:[1,2,0],plurals:function(e){return Number(e%10==1&&e%100!=11?0:0!==e?1:2)}},mai:{name:"Maithili",numbers:[1,2],plurals:function(e){return Number(1!=e)}},mfe:{name:"Mauritian Creole",numbers:[1,2],plurals:function(e){return Number(e>1)}},mg:{name:"Malagasy",numbers:[1,2],plurals:function(e){return Number(e>1)}},mi:{name:"Maori",numbers:[1,2],plurals:function(e){return Number(e>1)}},mk:{name:"Macedonian",numbers:[1,2],plurals:function(e){return Number(1==e||e%10==1?0:1)}},ml:{name:"Malayalam",numbers:[1,2],plurals:function(e){return Number(1!=e)}},mn:{name:"Mongolian",numbers:[1,2],plurals:function(e){return Number(1!=e)}},mnk:{name:"Mandinka",numbers:[0,1,2],plurals:function(e){return Number(1==e?1:2)}},mr:{name:"Marathi",numbers:[1,2],plurals:function(e){return Number(1!=e)}},ms:{name:"Malay",numbers:[1],plurals:function(e){return 0}},mt:{name:"Maltese",numbers:[1,2,11,20],plurals:function(e){return Number(1==e?0:0===e||e%100>1&&11>e%100?1:e%100>10&&20>e%100?2:3)}},nah:{name:"Nahuatl",numbers:[1,2],plurals:function(e){return Number(1!=e)}},nap:{name:"Neapolitan",numbers:[1,2],plurals:function(e){return Number(1!=e)}},nb:{name:"Norwegian Bokmal",numbers:[1,2],plurals:function(e){return Number(1!=e)}},ne:{name:"Nepali",numbers:[1,2],plurals:function(e){return Number(1!=e)}},nl:{name:"Dutch",numbers:[1,2],plurals:function(e){return Number(1!=e)}},nn:{name:"Norwegian Nynorsk",numbers:[1,2],plurals:function(e){return Number(1!=e)}},no:{name:"Norwegian",numbers:[1,2],plurals:function(e){return Number(1!=e)}},nso:{name:"Northern Sotho",numbers:[1,2],plurals:function(e){return Number(1!=e)}},oc:{name:"Occitan",numbers:[1,2],plurals:function(e){return Number(e>1)}},or:{name:"Oriya",numbers:[2,1],plurals:function(e){return Number(1!=e)}},pa:{name:"Punjabi",numbers:[1,2],plurals:function(e){return Number(1!=e)}},pap:{name:"Papiamento",numbers:[1,2],plurals:function(e){return Number(1!=e)}},pl:{name:"Polish",numbers:[1,2,5],plurals:function(e){return Number(1==e?0:e%10>=2&&4>=e%10&&(10>e%100||e%100>=20)?1:2)}},pms:{name:"Piemontese",numbers:[1,2],plurals:function(e){return Number(1!=e)}},ps:{name:"Pashto",numbers:[1,2],plurals:function(e){return Number(1!=e)}},pt:{name:"Portuguese",numbers:[1,2],plurals:function(e){return Number(1!=e)}},pt_br:{name:"Brazilian Portuguese",numbers:[1,2],plurals:function(e){return Number(1!=e)}},rm:{name:"Romansh",numbers:[1,2],plurals:function(e){return Number(1!=e)}},ro:{name:"Romanian",numbers:[1,2,20],plurals:function(e){return Number(1==e?0:0===e||e%100>0&&20>e%100?1:2)}},ru:{name:"Russian",numbers:[1,2,5],plurals:function(e){return Number(e%10==1&&e%100!=11?0:e%10>=2&&4>=e%10&&(10>e%100||e%100>=20)?1:2)}},sah:{name:"Yakut",numbers:[1],plurals:function(e){return 0}},sco:{name:"Scots",numbers:[1,2],plurals:function(e){return Number(1!=e)}},se:{name:"Northern Sami",numbers:[1,2],plurals:function(e){return Number(1!=e)}},si:{name:"Sinhala",numbers:[1,2],plurals:function(e){return Number(1!=e)}},sk:{name:"Slovak",numbers:[1,2,5],plurals:function(e){return Number(1==e?0:e>=2&&4>=e?1:2)}},sl:{name:"Slovenian",numbers:[5,1,2,3],plurals:function(e){return Number(e%100==1?1:e%100==2?2:e%100==3||e%100==4?3:0)}},so:{name:"Somali",numbers:[1,2],plurals:function(e){return Number(1!=e)}},son:{name:"Songhay",numbers:[1,2],plurals:function(e){return Number(1!=e)}},sq:{name:"Albanian",numbers:[1,2],plurals:function(e){return Number(1!=e)}},sr:{name:"Serbian",numbers:[1,2,5],plurals:function(e){return Number(e%10==1&&e%100!=11?0:e%10>=2&&4>=e%10&&(10>e%100||e%100>=20)?1:2)}},su:{name:"Sundanese",numbers:[1],plurals:function(e){return 0}},sv:{name:"Swedish",numbers:[1,2],plurals:function(e){return Number(1!=e)}},sw:{name:"Swahili",numbers:[1,2],plurals:function(e){return Number(1!=e)}},ta:{name:"Tamil",numbers:[1,2],plurals:function(e){return Number(1!=e)}},te:{name:"Telugu",numbers:[1,2],plurals:function(e){return Number(1!=e)}},tg:{name:"Tajik",numbers:[1,2],plurals:function(e){return Number(e>1)}},th:{name:"Thai",numbers:[1],plurals:function(e){return 0}},ti:{name:"Tigrinya",numbers:[1,2],plurals:function(e){return Number(e>1)}},tk:{name:"Turkmen",numbers:[1,2],plurals:function(e){return Number(1!=e)}},tr:{name:"Turkish",numbers:[1,2],plurals:function(e){return Number(e>1)}},tt:{name:"Tatar",numbers:[1],plurals:function(e){return 0}},ug:{name:"Uyghur",numbers:[1],plurals:function(e){return 0}},uk:{name:"Ukrainian",numbers:[1,2,5],plurals:function(e){return Number(e%10==1&&e%100!=11?0:e%10>=2&&4>=e%10&&(10>e%100||e%100>=20)?1:2)}},ur:{name:"Urdu",numbers:[1,2],plurals:function(e){return Number(1!=e)}},uz:{name:"Uzbek",numbers:[1,2],plurals:function(e){return Number(e>1)}},vi:{name:"Vietnamese",numbers:[1],plurals:function(e){return 0}},wa:{name:"Walloon",numbers:[1,2],plurals:function(e){return Number(e>1)}},wo:{name:"Wolof",numbers:[1],plurals:function(e){return 0}},yo:{name:"Yoruba",numbers:[1,2],plurals:function(e){return Number(1!=e)}},zh:{name:"Chinese",numbers:[1],plurals:function(e){return 0}}},addRule:function(e,n){z.rules[e]=n},setCurrentLng:function(e){if(!z.currentRule||z.currentRule.lng!==e){var n=e.split("-");z.currentRule={lng:e,rule:z.rules[n[0]]}}},get:function(e,n){function r(n,r){var t;if(t=z.currentRule&&z.currentRule.lng===e?z.currentRule.rule:z.rules[n]){var a=t.plurals(r),u=t.numbers[a];return 2===t.numbers.length&&1===t.numbers[0]&&(2===u?u=-1:1===u&&(u=1)),u}return 1===r?"1":"-1"}var t=e.split("-");return r(t[0],n)}},I={},V=function(e,n){I[e]=n},B=function(){function e(e){return Object.prototype.toString.call(e).slice(8,-1).toLowerCase()}function n(e,n){for(var r=[];n>0;r[--n]=e);return r.join("")}var r=function(){return r.cache.hasOwnProperty(arguments[0])||(r.cache[arguments[0]]=r.parse(arguments[0])),r.format.call(null,r.cache[arguments[0]],arguments)};return r.format=function(r,t){var a=1,u=r.length,o="",s,l=[],i,c,f,p,m,g;for(i=0;u>i;i++)if(o=e(r[i]),"string"===o)l.push(r[i]);else if("array"===o){if(f=r[i],f[2])for(s=t[a],c=0;c<f[2].length;c++){if(!s.hasOwnProperty(f[2][c]))throw B('[sprintf] property "%s" does not exist',f[2][c]);s=s[f[2][c]]}else s=f[1]?t[f[1]]:t[a++];if(/[^s]/.test(f[8])&&"number"!=e(s))throw B("[sprintf] expecting number but found %s",e(s));switch(f[8]){case"b":s=s.toString(2);break;case"c":s=String.fromCharCode(s);break;case"d":s=parseInt(s,10);break;case"e":s=f[7]?s.toExponential(f[7]):s.toExponential();break;case"f":s=f[7]?parseFloat(s).toFixed(f[7]):parseFloat(s);break;case"o":s=s.toString(8);break;case"s":s=(s=String(s))&&f[7]?s.substring(0,f[7]):s;break;case"u":s=Math.abs(s);break;case"x":s=s.toString(16);break;case"X":s=s.toString(16).toUpperCase()}s=/[def]/.test(f[8])&&f[3]&&s>=0?"+"+s:s,m=f[4]?"0"==f[4]?"0":f[4].charAt(1):" ",g=f[6]-String(s).length,p=f[6]?n(m,g):"",l.push(f[5]?s+p:p+s)}return l.join("")},r.cache={},r.parse=function(e){for(var n=e,r=[],t=[],a=0;n;){if(null!==(r=/^[^\x25]+/.exec(n)))t.push(r[0]);else if(null!==(r=/^\x25{2}/.exec(n)))t.push("%");else{if(null===(r=/^\x25(?:([1-9]\d*)\$|\(([^\)]+)\))?(\+)?(0|'[^$])?(-)?(\d+)?(?:\.(\d+))?([b-fosuxX])/.exec(n)))throw"[sprintf] huh?";if(r[2]){a|=1;var u=[],o=r[2],s=[];if(null===(s=/^([a-z_][a-z_\d]*)/i.exec(o)))throw"[sprintf] huh?";for(u.push(s[1]);""!==(o=o.substring(s[0].length));)if(null!==(s=/^\.([a-z_][a-z_\d]*)/i.exec(o)))u.push(s[1]);
+else{if(null===(s=/^\[(\d+)\]/.exec(o)))throw"[sprintf] huh?";u.push(s[1])}r[2]=u}else a|=2;if(3===a)throw"[sprintf] mixing positional and named placeholders is not (yet) supported";t.push(r)}n=n.substring(r[0].length)}return t},r}(),G=function(e,n){return n.unshift(e),B.apply(null,n)};V("sprintf",function(e,n,r){return r.sprintf?"[object Array]"===Object.prototype.toString.apply(r.sprintf)?G(e,r.sprintf):"object"==typeof r.sprintf?B(e,r.sprintf):e:e}),p.init=a,p.setLng=f,p.preload=u,p.addResourceBundle=o,p.removeResourceBundle=s,p.loadNamespace=i,p.loadNamespaces=c,p.setDefaultNamespace=l,p.t=x,p.translate=x,p.exists=y,p.detectLanguage=D.detectLanguage,p.pluralExtensions=z,p.sync=H,p.functions=D,p.lng=m,p.addPostProcessor=V,p.options=M}()}.call(this),function(){p.init({resStore:{},fallbackLng:g.fallback_language,useCookie:!1})}.call(this),function(){d="object"==typeof d?d:{};var e=d;e.helpers={}}.call(this),d="object"==typeof d?d:{};var b=d,h;m={},h=g.fallback_language,e.extend(m,{_language_changed_tracker:new r.Dependency,_loaded_languages:[h],_fallback_language:h,_loaded_lang_session_key:"TAPi18n::loaded_lang",conf:null,packages:{},languages_names:{},translations:{},_enable:function(e){return this.conf=e,this._onceEnabled()},_onceEnabled:function(){},_enabled:function(){return null!=this.conf},_getPackageDomain:function(e){return e.replace(/:/g,"-")},addResourceBundle:function(e,n,r){return p.addResourceBundle(e,m._getPackageDomain(n),r)},_getProjectLanguages:function(){return this._enabled()?e.isArray(this.conf.supported_languages)?e.union([this._fallback_language],this.conf.supported_languages):e.keys(this.languages_names):[this._fallback_language]},getLanguages:function(){var e,n,r,t,a;if(!this._enabled())return null;for(n={},a=this._getProjectLanguages(),r=0,t=a.length;t>r;r++)e=a[r],n[e]={name:this.languages_names[e][1],en:this.languages_names[e][0]};return n},_loadLangFileObject:function(n,r){var t,a,u,o;o=[];for(a in r)t=r[a],t=e.extend({},t,(null!=(u=this._loadTranslations_cache[n])?u[a]:void 0)||{}),o.push(m.addResourceBundle(n,a,t));return o},_loadTranslations_cache:{},loadTranslations:function(r,t){var a,u,o,s;u=this._getProjectLanguages(),s=[];for(a in r)o=r[a],null==this._loadTranslations_cache[a]&&(this._loadTranslations_cache[a]={}),null==this._loadTranslations_cache[a][t]&&(this._loadTranslations_cache[a][t]={}),e.extend(this._loadTranslations_cache[a][t],o),m.addResourceBundle(a,t,o),s.push(n.isClient&&this.getLanguage()===a?this._language_changed_tracker.changed():void 0);return s}}),d="object"==typeof d?d:{};var b=d,v,y=[].indexOf||function(e){for(var n=0,r=this.length;r>n;n++)if(n in this&&this[n]===e)return n;return-1},x=[].slice;v=m._loaded_lang_session_key,a.set(v,null),e.extend(m,{_getLanguageFilePath:function(e){var r;return this._enabled()?(r=null!=this.conf.cdn_path?this.conf.cdn_path:this.conf.i18n_files_route,r=r.replace(/\/$/,""),n.isCordova&&"/"===r[0]&&(r=n.absoluteUrl()+r),""+r+"/"+e+".json"):null},_loadLanguage:function(e){var n,r,t,a,o,s;return s=this,r=new u.Deferred,this._enabled()?(o=s._getProjectLanguages(),y.call(o,e)>=0?y.call(s._loaded_languages,e)<0?(a=function(){var n;return n=u.getJSON(s._getLanguageFilePath(e)),n.done(function(n){return m._loadLangFileObject(e,n),s._loaded_languages.push(e),r.resolve()}),n.fail(function(n,t){return r.reject("Couldn't load language '"+e+"' JSON: "+t)})},t=y.call(e,"-")>=0?e.replace(/-.*/,""):h,e!==h&&y.call(o,t)>=0?(n=s._loadLanguage(t),n.done(function(){return a()}),n.fail(function(e){return r.reject("Loading process failed since dependency language '"+t+"' failed to load: "+e)})):a()):r.resolve():r.reject(["Language "+e+" is not supported"]),r.promise()):r.reject("tap-i18n is not enabled in the project level, check tap-i18n README")},_registerHelpers:function(n,r){var t,a,u,o;return a=this,u=this._getPackageI18nextProxy(n!==g.project_translations_domain?a.packages[n].namespace:g.project_translations_domain),o=function(){var n,r,t;return r=arguments[0],n=2<=arguments.length?x.call(arguments,1):[],t=n.pop().hash,e.isEmpty(n)||(t.sprintf=n),u(r,t)},n===g.project_translations_domain?(i.registerHelper(a.conf.helper_name,o),i.registerHelper("languageTag",function(){return a.getLanguage()})):null!=s[r]&&null!=s[r].helpers?(t={},t[a.packages[n].helper_name]=o,s[r].helpers(t)):void 0},_getRegisterHelpersProxy:function(e){var n;return n=this,function(r){return n._registerHelpers(e,r)}},_getPackageI18nextProxy:function(e){var n;return n=this,function(r,t,a){return null==a&&(a=null),null!=a&&console.log("Warning: specifying lang_tag is not supported in client side, using session language"),n._language_changed_tracker.depend(),p.t(""+m._getPackageDomain(e)+":"+r,t)}},_onceEnabled:function(){return m._registerHelpers(g.project_translations_domain)},setLanguage:function(e){var n;return n=this,this._loadLanguage(e).then(function(){return p.setLng(e),n._language_changed_tracker.changed(),a.set(v,e)})},getLanguage:function(){var e;return this._enabled()?(e=a.get(v),null!=e?e:this._fallback_language):null}}),m.__=m._getPackageI18nextProxy(g.project_translations_domain),"undefined"==typeof Package&&(Package={}),Package["tap:i18n"]={TAPi18next:p,TAPi18n:m}}();
+
+!function(){var a=Package.meteor.Meteor,e=Package.blaze.Blaze,c=Package.blaze.UI,g=Package.blaze.Handlebars,k=Package.htmljs.HTML,e,c,g;"undefined"==typeof Package&&(Package={}),Package.ui={Blaze:e,UI:c,Handlebars:g}}();
+
+!function(){var e=Package.meteor.Meteor,r=Package.blaze.Blaze,n=Package.blaze.UI,t=Package.blaze.Handlebars,i=Package.session.Session,o=Package.tracker.Tracker,a=Package.tracker.Deps,u=Package.underscore._,s=Package.htmljs.HTML,c,n;(function(){"undefined"==typeof c&&(c={});var r={},n=e.isClient?new a.Dependency:null,t="en";c.setLanguage=function(r){r&&r!==t&&(t=r,e.isClient&&n.changed())},c.language=function(){return e.isClient&&n.depend(),t},c.setDictionary=function(e){r=e},c.addDictionary=function(e){u.extend(r,e)};var i=function(e,r){return e==e.toLowerCase()?r.toLowerCase():e==e.toUpperCase()?r.toUpperCase():e.substr(1)==e.substr(1).toLowerCase()?r.substr(0,1).toUpperCase()+r.substr(1).toLowerCase():e.substr(0,2)==e.substr(0,2).toUpperCase()?r:r.replace(/( [a-z])/g,function(e){return e.toUpperCase()})};c.getText=function(e,n){var t=e.toLowerCase(),o=r&&r[t],a="string"==typeof n?n:c.language();return i(e,o?o[a]?o[a]:o.en:"["+e+"]")}}).call(this),function(){("undefined"==typeof n||"function"!=typeof n.registerHelper)&&(n={registerHelper:function(e,r){if("undefined"!=typeof t)return t.registerHelper(e,r);throw new Error("No UI or Handlebars found")}}),"undefined"!=typeof n&&(n.registerHelper("getLength",function(e){return e&&e.length}),n.registerHelper("isSelected",function(e,r){return e===r?" selected":""}),n.registerHelper("isChecked",function(e,r){return e===r?" checked":""}),n.registerHelper("cutString",function(e,r){return e.length>r?e.substr(0,Math.max(r-3,0))+"...":e}),n.registerHelper("$eq",function(e,r){return e===r}),n.registerHelper("$neq",function(e,r){return e!==r}),n.registerHelper("$in",function(e,r,n,t){return e===r||e===n||e===t}),n.registerHelper("$nin",function(e,r,n,t){return e!==r&&e!==n&&e!==t}),n.registerHelper("$exists",function(e){return void 0!==e}),n.registerHelper("$lt",function(e,r){return r>e}),n.registerHelper("$gt",function(e,r){return e>r}),n.registerHelper("$lte",function(e,r){return r>=e}),n.registerHelper("$gte",function(e,r){return e>=r}),n.registerHelper("$and",function(e,r){return e&&r}),n.registerHelper("$or",function(e,r){return e||r}),n.registerHelper("$not",function(e){return!e}),n.registerHelper("nl2br",function(e){var r=(e+"").replace(/([^>\r\n]?)(\r\n|\n\r|\r|\n)/g,"$1<br>$2");return new Spacebars.SafeString(r)}),n.registerHelper("getText",function(e,r){var n=r||null;return c.getText(e,n)}),n.registerHelper("$mapped",function(e){if(!Array.isArray(e))try{e=e.fetch()}catch(r){return console.log("Error in $mapped: perhaps you aren't sending in a collection or array."),[]}var n=e.map(function(r,n){return r.$index=n,r.$first=0===n,r.$last=n===e.length-1,r});return n||[]}),c.superScope={},c.addScope=function(e,r){c.superScope[e]=u.bind(function(){return this},r)},c.removeScope=function(e){delete n._globalHelpers[e],delete c.superScope[e]},c.addScope("Session",i),c.addScope("Meteor",e),n.registerHelper("$",function(){return c.superScope}))}.call(this),"undefined"==typeof Package&&(Package={}),Package["raix:handlebar-helpers"]={Helpers:c}}();
+
+!function(){var n=Package.meteor.Meteor,i=Package.underscore._,e=Package.templating.Template,a=Package.jquery.$,t=Package.jquery.jQuery,o=Package.blaze.Blaze,r=Package.blaze.UI,s=Package.blaze.Handlebars,m=Package.htmljs.HTML;(function(){e.__checkName("Animate"),e.Animate=new e("Template.Animate",function(){var n=this;return o._InOuterTemplateScope(n,function(){return Spacebars.include(function(){return Spacebars.call(n.templateContentBlock)})})})}).call(this),function(){var t=function(n){return"all 0s ease 0s"===n.css("transition")&&"none 0s ease 0s 1 normal none running"===n.css("animation")?(console.warn('animation-helper error: The following element has no transition defined, but an "animate" class:',n[0]),!0):!1};e.Animate.rendered=function(){var e=this;i.each(this.findAll(".animate"),function(n){var i=a(n);t(i)||(i.width(),i.removeClass("animate"),i.on("transitionend webkitTransitionEnd oTransitionEnd MSTransitionEnd transitionEnd msTransitionEnd animationend webkitAnimationEnd oAnimationEnd MSAnimationEnd animationEnd msAnimationEnd",function(e){e.target===n&&(i.off(e),n._animation_helper_isVisible=!0)}))}),e._animation_helper_parentNode=this.firstNode.parentNode,e._animation_helper_parentNode._uihooks={insertElement:function(n,i){var e=a(n);e.insertBefore(i),e.hasClass("animate")&&!t(e)&&(e.width(),e.removeClass("animate"),e.on("transitionend webkitTransitionEnd oTransitionEnd MSTransitionEnd transitionEnd msTransitionEnd animationend webkitAnimationEnd oAnimationEnd MSAnimationEnd animationEnd msAnimationEnd",function(i){i.target===n&&(e.off(i),n._animation_helper_isVisible=!0)}))},removeElement:function(i){var e=a(i);if(i._animation_helper_isVisible){var t;n.isClient&&(t=n.setTimeout(function(){e.remove(),e=null},5e3)),e.on("transitionend webkitTransitionEnd oTransitionEnd MSTransitionEnd transitionEnd msTransitionEnd animationend webkitAnimationEnd oAnimationEnd MSAnimationEnd animationEnd msAnimationEnd",function(a){a.target===i&&(e.off(a),n.clearTimeout(t),delete i._animation_helper_isVisible,e.remove(),e=null)}),e.addClass("animate").width()}else e.remove(),e=null}}},e.Animate.destroyed=function(){var i=this;n.isClient&&i._animation_helper_parentNode&&Tracker.afterFlush(function(){i._animation_helper_parentNode._uihooks=null})}}.call(this),"undefined"==typeof Package&&(Package={}),Package["frozeman:animation-helper"]={}}();
+
+!function(){var e=Package.meteor.Meteor,a=Package.underscore._,t=Package["reactive-var"].ReactiveVar,r;(function(){r={_getTemplateInstance:function(r,n,l){var p=null;if(a.isObject(r)&&(r.hasOwnProperty("_templateInstance")||r.hasOwnProperty("view")))r.hasOwnProperty("_templateInstance")?p=r:r.hasOwnProperty("view")&&(p=r.view);else try{p=Template.instance().view,l=n,n=r}catch(c){throw new e.Error("TemplateVar works only from withing template helpers, callbacks or events. Additonally you can pass a template instance as the first parameter.")}for(;-1===p.name.indexOf("Template.")&&p.parentView;)p=p.parentView;return p&&!p._templateVar&&(p._templateVar={}),p&&!p._templateVar[n]&&(p._templateVar[n]=new t(l)),{key:n,value:l,template:p}},get:function(e,a){var t=r._getTemplateInstance(e,a);return t.template._templateVar[t.key].get()},set:function(e,a,t){var n=r._getTemplateInstance(e,a,t);n.template._templateVar[n.key].set(n.value)}}}).call(this),"undefined"==typeof Package&&(Package={}),Package["frozeman:template-var"]={TemplateVar:r}}();
+
+!function(){var e=Package.meteor.Meteor,t=Package.jquery.$,r=Package.jquery.jQuery;(function(){!function(e,t){var r=[].slice,s={},n=e.amplify={publish:function(e){if("string"!=typeof e)throw new Error("You must provide a valid topic to publish.");var t=r.call(arguments,1),n,u,a,o=0,i;if(!s[e])return!0;for(n=s[e].slice(),a=n.length;a>o&&(u=n[o],i=u.callback.apply(u.context,t),i!==!1);o++);return i!==!1},subscribe:function(e,t,r,n){if("string"!=typeof e)throw new Error("You must provide a valid topic to create a subscription.");3===arguments.length&&"number"==typeof r&&(n=r,r=t,t=null),2===arguments.length&&(r=t,t=null),n=n||10;for(var u=0,a=e.split(/\s/),o=a.length,i;o>u;u++){e=a[u],i=!1,s[e]||(s[e]=[]);for(var c=s[e].length-1,l={callback:r,context:t,priority:n};c>=0;c--)if(s[e][c].priority<=n){s[e].splice(c+1,0,l),i=!0;break}i||s[e].unshift(l)}return r},unsubscribe:function(e,t,r){if("string"!=typeof e)throw new Error("You must provide a valid topic to remove a subscription.");if(2===arguments.length&&(r=t,t=null),s[e])for(var n=s[e].length,u=0;n>u;u++)s[e][u].callback===r&&(t&&s[e][u].context!==t||(s[e].splice(u,1),u--,n--))}}}(this),function(e,t){function r(e,r){s.addType(e,function(u,a,o){var i,c,l,p,f=a,d=(new Date).getTime();if(!u){f={},p=[],l=0;try{for(u=r.length;u=r.key(l++);)n.test(u)&&(c=JSON.parse(r.getItem(u)),c.expires&&c.expires<=d?p.push(u):f[u.replace(n,"")]=c.data);for(;u=p.pop();)r.removeItem(u)}catch(y){}return f}if(u="__amplify__"+u,a===t){if(i=r.getItem(u),c=i?JSON.parse(i):{expires:-1},!(c.expires&&c.expires<=d))return c.data;r.removeItem(u)}else if(null===a)r.removeItem(u);else{c=JSON.stringify({data:a,expires:o.expires?d+o.expires:null});try{r.setItem(u,c)}catch(y){s[e]();try{r.setItem(u,c)}catch(y){throw s.error()}}}return f})}var s=e.store=function(e,t,r){var n=s.type;return r&&r.type&&r.type in s.types&&(n=r.type),s.types[n](e,t,r||{})};s.types={},s.type=null,s.addType=function(e,t){s.type||(s.type=e),s.types[e]=t,s[e]=function(t,r,n){return n=n||{},n.type=e,s(t,r,n)}},s.error=function(){return"amplify.store quota exceeded"};var n=/^__amplify__/;for(var u in{localStorage:1,sessionStorage:1})try{window[u].setItem("__amplify__","x"),window[u].removeItem("__amplify__"),r(u,window[u])}catch(a){}if(!s.types.localStorage&&window.globalStorage)try{r("globalStorage",window.globalStorage[window.location.hostname]),"sessionStorage"===s.type&&(s.type="globalStorage")}catch(a){}!function(){if(!s.types.localStorage){var e=document.createElement("div"),r="amplify";e.style.display="none",document.getElementsByTagName("head")[0].appendChild(e);try{e.addBehavior("#default#userdata"),e.load(r)}catch(n){return void e.parentNode.removeChild(e)}s.addType("userData",function(n,u,a){e.load(r);var o,i,c,l,p,f=u,d=(new Date).getTime();if(!n){for(f={},p=[],l=0;o=e.XMLDocument.documentElement.attributes[l++];)i=JSON.parse(o.value),i.expires&&i.expires<=d?p.push(o.name):f[o.name]=i.data;for(;n=p.pop();)e.removeAttribute(n);return e.save(r),f}if(n=n.replace(/[^\-._0-9A-Za-z\xb7\xc0-\xd6\xd8-\xf6\xf8-\u037d\u037f-\u1fff\u200c-\u200d\u203f\u2040\u2070-\u218f]/g,"-"),n=n.replace(/^-/,"_-"),u===t){if(o=e.getAttribute(n),i=o?JSON.parse(o):{expires:-1},!(i.expires&&i.expires<=d))return i.data;e.removeAttribute(n)}else null===u?e.removeAttribute(n):(c=e.getAttribute(n),i=JSON.stringify({data:u,expires:a.expires?d+a.expires:null}),e.setAttribute(n,i));try{e.save(r)}catch(y){null===c?e.removeAttribute(n):e.setAttribute(n,c),s.userData();try{e.setAttribute(n,i),e.save(r)}catch(y){throw null===c?e.removeAttribute(n):e.setAttribute(n,c),s.error()}}return f})}}(),function(){function e(e){return e===t?t:JSON.parse(JSON.stringify(e))}var r={},n={};s.addType("memory",function(s,u,a){return s?u===t?e(r[s]):(n[s]&&(clearTimeout(n[s]),delete n[s]),null===u?(delete r[s],null):(r[s]=u,a.expires&&(n[s]=setTimeout(function(){delete r[s],delete n[s]},a.expires)),u)):e(r)})}()}(this.amplify=this.amplify||{}),function(e,t){"use strict";function r(){}function s(e){return"[object Function]"==={}.toString.call(e)}function n(e){var t=!1;return setTimeout(function(){t=!0},1),function(){var r=this,s=arguments;t?e.apply(r,s):setTimeout(function(){e.apply(r,s)},1)}}e.request=function(t,u,a){var o=t||{};"string"==typeof o&&(s(u)&&(a=u,u={}),o={resourceId:t,data:u||{},success:a});var i={abort:r},c=e.request.resources[o.resourceId],l=o.success||r,p=o.error||r;if(o.success=n(function(t,r){r=r||"success",e.publish("request.success",o,t,r),e.publish("request.complete",o,t,r),l(t,r)}),o.error=n(function(t,r){r=r||"error",e.publish("request.error",o,t,r),e.publish("request.complete",o,t,r),p(t,r)}),!c){if(!o.resourceId)throw"amplify.request: no resourceId provided";throw"amplify.request: unknown resourceId: "+o.resourceId}return e.publish("request.before",o)?(e.request.resources[o.resourceId](o,i),i):void o.error(null,"abort")},e.request.types={},e.request.resources={},e.request.define=function(t,r,s){if("string"==typeof r){if(!(r in e.request.types))throw"amplify.request.define: unknown type: "+r;s.resourceId=t,e.request.resources[t]=e.request.types[r](s)}else e.request.resources[t]=r}}(amplify),function(e,t,r){"use strict";var s=["status","statusText","responseText","responseXML","readyState"],n=/\{([^\}]+)\}/g;e.request.types.ajax=function(n){return n=t.extend({type:"GET"},n),function(u,a){var o,i,c=n.url,l=a.abort,p=t.extend(!0,{},n,{data:u.data}),f=!1,d={readyState:0,setRequestHeader:function(e,t){return o.setRequestHeader(e,t)},getAllResponseHeaders:function(){return o.getAllResponseHeaders()},getResponseHeader:function(e){return o.getResponseHeader(e)},overrideMimeType:function(e){return o.overrideMimeType(e)},abort:function(){f=!0;try{o.abort()}catch(e){}i(null,"abort")},success:function(e,t){u.success(e,t)},error:function(e,t){u.error(e,t)}};i=function(e,n){t.each(s,function(e,t){try{d[t]=o[t]}catch(r){}}),/OK$/.test(d.statusText)&&(d.statusText="success"),e===r&&(e=null),f&&(n="abort"),/timeout|error|abort/.test(n)?d.error(e,n):d.success(e,n),i=t.noop},e.publish("request.ajax.preprocess",n,u,p,d),t.extend(p,{isJSONP:function(){return/jsonp/gi.test(this.dataType)},cacheURL:function(){if(!this.isJSONP())return this.url;var e="callback";this.hasOwnProperty("jsonp")&&(this.jsonp!==!1?e=this.jsonp:this.hasOwnProperty("jsonpCallback")&&(e=this.jsonpCallback));var t=new RegExp("&?"+e+"=[^&]*&?","gi");return this.url.replace(t,"")},success:function(e,t){i(e,t)},error:function(e,t){i(null,t)},beforeSend:function(t,r){o=t,p=r;var s=n.beforeSend?n.beforeSend.call(this,d,p):!0;return s&&e.publish("request.before.ajax",n,u,p,d)}}),p.cache&&p.isJSONP()&&t.extend(p,{cache:!0}),t.ajax(p),a.abort=function(){d.abort(),l.call(this)}}},e.subscribe("request.ajax.preprocess",function(e,r,s){var u=[],a=s.data;"string"!=typeof a&&(a=t.extend(!0,{},e.data,a),s.url=s.url.replace(n,function(e,t){return t in a?(u.push(t),a[t]):void 0}),t.each(u,function(e,t){delete a[t]}),s.data=a)}),e.subscribe("request.ajax.preprocess",function(e,r,s){var n=s.data,u=e.dataMap;u&&"string"!=typeof n&&(t.isFunction(u)?s.data=u(n):(t.each(e.dataMap,function(e,t){e in n&&(n[t]=n[e],delete n[e])}),s.data=n))});var u=e.request.cache={_key:function(e,t,r){function s(){return r.charCodeAt(u++)<<24|r.charCodeAt(u++)<<16|r.charCodeAt(u++)<<8|r.charCodeAt(u++)<<0}r=t+r;for(var n=r.length,u=0,a=s();n>u;)a^=s();return"request-"+e+"-"+a},_default:function(){var e={};return function(t,r,s,n){var a=u._key(r.resourceId,s.cacheURL(),s.data),o=t.cache;if(a in e)return n.success(e[a]),!1;var i=n.success;n.success=function(t){e[a]=t,"number"==typeof o&&setTimeout(function(){delete e[a]},o),i.apply(this,arguments)}}}()};e.store&&(t.each(e.store.types,function(t){u[t]=function(r,s,n,a){var o=u._key(s.resourceId,n.cacheURL(),n.data),i=e.store[t](o);if(i)return n.success(i),!1;var c=a.success;a.success=function(s){e.store[t](o,s,{expires:r.cache.expires}),c.apply(this,arguments)}}}),u.persist=u[e.store.type]),e.subscribe("request.before.ajax",function(e){var t=e.cache;return t?(t=t.type||t,u[t in u?t:"_default"].apply(this,arguments)):void 0}),e.request.decoders={jsend:function(e,t,r,s,n){"success"===e.status?s(e.data):"fail"===e.status?n(e.data,"fail"):"error"===e.status?(delete e.status,n(e,"error")):n(null,"error")}},e.subscribe("request.before.ajax",function(r,s,n,u){function a(e,t){i(e,t)}function o(e,t){c(e,t)}var i=u.success,c=u.error,l=t.isFunction(r.decoder)?r.decoder:r.decoder in e.request.decoders?e.request.decoders[r.decoder]:e.request.decoders._default;l&&(u.success=function(e,t){l(e,t,u,a,o)},u.error=function(e,t){l(e,t,u,a,o)})})}(amplify,r)}).call(this),"undefined"==typeof Package&&(Package={}),Package.amplify={}}();
+
+!function(){var e=Package.meteor.Meteor,t=Package.underscore._,n;(function(){var o=4.8,a=50;n=function(e){var o=this;if(!(o instanceof n))throw new Error('use "new" to construct a PersistentMinimongo');o.key="minimongo__"+e._name,o.col=e,o.cur=o.col.find({}),o.stats={added:0,removed:0,changed:0},i.push(o),o.refresh(!0),o.cur.observe({added:function(e){o.capCollection();var n=amplify.store(o.key);n||(n=[]),t.contains(n,e._id)||(n.push(e._id),amplify.store(o.key,n));var a=o._makeDataKey(e._id);amplify.store(a)||amplify.store(a,e),++o.stats.added},removed:function(e){var n=amplify.store(o.key);t.contains(n,e._id)&&(n=t.without(n,e._id),amplify.store(o._makeDataKey(e._id),null),amplify.store(o.key,0===n.length?null:n),++o.stats.removed)},changed:function(e,t){amplify.store(o._makeDataKey(e._id),e),++o.stats.changed}})},n.prototype={constructor:n,_getStats:function(){return this.stats},_getKey:function(){return this.key},_makeDataKey:function(e){return this.key+"__"+e},refresh:function(e){var n=this,o=amplify.store(n.key),a=[];if(n.stats.added=0,o){var i=o.length;o=t.filter(o,function(e){var t=amplify.store(n._makeDataKey(e));if(t){var o=n.col.findOne({_id:t._id});o?n.col.update({_id:o._id},t):n.col.insert(t)}return!!t}),e||(n.col.find({}).forEach(function(e){t.contains(o,e._id)||a.push(e._id)}),t.each(a,function(e){n.col.remove({_id:e})})),e&&i!=o.length&&amplify.store(n.key,0===o.length?null:o)}},localStorageSize:function(){var e=0;return localStorage&&t.each(Object.keys(localStorage),function(t){e+=2*localStorage[t].length/1024/1024}),e},capCollection:function(){var e=this;e.localStorageSize()>o&&(console.log(e.localStorageSize(),e.col.find({}).count()),t.each(e.col.find({},{limit:a}).fetch(),function(t){e.col.remove(t._id)}))}};var i=[],r=null;e.startup(function(){$(window).bind("storage",function(n){e.clearTimeout(r),r=e.setTimeout(function(){t.each(i,function(e){e.refresh(!1)})},250)})})}).call(this),"undefined"==typeof Package&&(Package={}),Package["frozeman:persistent-minimongo"]={PersistentMinimongo:n}}();
+
+!function(){var e=Package.meteor.Meteor,t=Package.tracker.Tracker,n=Package.tracker.Deps,a=Package.underscore._,i;(function(){i=function(){function n(e){this._dependency=new t.Dependency,this._intervalId=null,a.isFinite(e)&&this.start(e)}return n.prototype.start=function(t){var n=this;this._intervalId=e.setInterval(function(){n._dependency.changed()},1e3*t)},n.prototype.stop=function(){e.clearInterval(this._intervalId),this._intervalId=null},n.prototype.tick=function(){this._dependency.depend()},n}()}).call(this),"undefined"==typeof Package&&(Package={}),Package["frozeman:reactive-timer"]={ReactiveTimer:i}}();
+
+!function(){var e=Package.meteor.Meteor,n;(function(){n=function(){"use strict";function e(n,t){var r,s,u,f,h,g,v=this;if(!(v instanceof e))return new e(n,t);if(n instanceof e){if(null==t)return S=0,v.s=n.s,v.e=n.e,void(v.c=(n=n.c)?n.slice():n);n+=""}else if(f="number"==(h=typeof n)){if(null==t&&n===~~n){for(v.s=0>1/n?(n=-n,-1):1,s=S=0,u=n;u>=10;u/=10,s++);return v.e=s,void(v.c=[n])}n=0===n&&0>1/n?"-0":n+""}else"string"!=h&&(n+="");if(h=n,null==t&&A.test(h))v.s=45===h.charCodeAt(0)?(h=h.slice(1),-1):1;else{if(10==t)return v=new e(h),l(v,c+v.e+1,a);if(h=R.call(h).replace(/^\+(?!-)/,""),v.s=45===h.charCodeAt(0)?(h=h.replace(/^-(?!-)/,""),-1):1,null!=t?t!=~~t&&d||(O=!(t>=2&&65>t))?(o(t,2),g=A.test(h)):(r="["+b.slice(0,t=0|t)+"]+",h=h.replace(/\.$/,"").replace(/^\./,"0."),(g=new RegExp("^"+r+"(?:\\."+r+")?$",37>t?"i":"").test(h))?(f&&(h.replace(/^0\.0*|\./,"").length>15&&o(n,0),f=!f),h=i(h,10,t,v.s)):"Infinity"!=h&&"NaN"!=h&&(o(n,1,t),n="NaN")):g=A.test(h),!g)return v.c=v.e=null,"Infinity"!=h&&("NaN"!=h&&o(n,3),v.s=null),void(S=0)}for((s=h.indexOf("."))>-1&&(h=h.replace(".","")),(u=h.search(/e/i))>0?(0>s&&(s=u),s+=+h.slice(u+1),h=h.substring(0,u)):0>s&&(s=h.length),u=0;48===h.charCodeAt(u);u++);for(t=h.length;48===h.charCodeAt(--t););if(h=h.slice(u,t+1))if(t=h.length,f&&t>15&&o(n,0),s=s-u-1,s>m)v.c=v.e=null;else if(p>s)v.c=[v.e=0];else{if(v.e=s,v.c=[],u=(s+1)%_,0>s&&(u+=_),t>u){for(u&&v.c.push(+h.slice(0,u)),t-=_;t>u;v.c.push(+h.slice(u,u+=_)));h=h.slice(u),u=_-h.length}else u-=t;for(;u--;h+="0");v.c.push(+h)}else v.c=[v.e=0];S=0}function n(e,n,t){for(var r=1,i=n.length;!n[--i];n.pop());for(i=n[0];i>=10;i/=10,r++);return(t=r+t*_-1)>m?e.c=e.e=null:p>t?e.c=[e.e=0]:(e.e=t,e.c=n),e}function t(e){for(var n,t,r=1,i=e.length,s=e[0]+"";i>r;){for(n=e[r++]+"",t=_-n.length;t--;n="0"+n);s+=n}for(i=s.length;48===s.charCodeAt(--i););return s.slice(0,i+1||1)}function r(e,n,t){for(var r,i=[0],s,o=0,l=e.length;l>o;){for(s=i.length;s--;i[s]*=n);for(i[r=0]+=b.indexOf(e.charAt(o++));r<i.length;r++)i[r]>t-1&&(null==i[r+1]&&(i[r+1]=0),i[r+1]+=i[r]/t|0,i[r]%=t)}return i.reverse()}function i(n,t,i,s){var o,l,u,f,h,g,p,m=n.indexOf("."),d=a;for(37>i&&(n=n.toLowerCase()),m>=0&&(n=n.replace(".",""),p=new e(i),h=p.pow(n.length-m),p.c=r(h.toFixed(),10,t),p.e=p.c.length),g=r(n,i,t),l=u=g.length;0==g[--u];g.pop());if(!g[0])return"0";if(0>m?--l:(h.c=g,h.e=l,h.s=s,h=D(h,p,c,d,t),g=h.c,f=h.r,l=h.e),o=l+c+1,m=g[o],u=t/2,f=f||0>o||null!=g[o+1],f=4>d?(null!=m||f)&&(0==d||d==(h.s<0?3:2)):m>u||m==u&&(4==d||f||6==d&&1&g[o-1]||d==(h.s<0?8:7)),1>o||!g[0])g.length=1,u=0,f?(g[0]=1,l=-c):l=g[0]=0;else{if(g.length=o,f)for(--t;++g[--o]>t;)g[o]=0,o||(++l,g.unshift(1));for(u=g.length;!g[--u];);}for(m=0,n="";u>=m;n+=b.charAt(g[m++]));if(0>l){for(;++l;n="0"+n);n="0."+n}else if(m=n.length,++l>m)for(l-=m;l--;n+="0");else m>l&&(n=n.slice(0,l)+"."+n.slice(l));return n}function s(n,r,i){var s,o,u,f=(n=new e(n)).e;if(null==r?s=0:(l(n,++r,a),s=i?r:r+n.e-f,f=n.e),o=t(n.c),1==i||2==i&&(f>=r||h>=f)){for(;o.length<s;o+="0");o.length>1&&(o=o.charAt(0)+"."+o.slice(1)),o+=(0>f?"e":"e+")+f}else{if(i=o.length,0>f){for(u=s-i;++f;o="0"+o);o="0."+o}else if(++f>i){for(u=s-f,f-=i;f--;o+="0");u>0&&(o+=".")}else u=s-i,i>f?o=o.slice(0,f)+"."+o.slice(f):u>0&&(o+=".");if(u>0)for(;u--;o+="0");}return n.s<0&&n.c[0]?"-"+o:o}function o(e,n,t,r,i,s){if(d){var o,l=["new BigNumber","cmp","div","eq","gt","gte","lt","lte","minus","mod","plus","times","toFraction","divToInt"][S?0>S?-S:S:0>1/S?1:0]+"()",u=O?" out of range":" not a"+(i?" non-zero":"n")+" integer";throw u=([l+" number type has more than 15 significant digits",l+" not a base "+t+" number",l+" base"+u,l+" not a number"][n]||t+"() "+n+(s?" not a boolean or binary digit":u+(r?" or not ["+(O?" negative, positive":" integer, integer")+" ]":"")))+": "+e,O=S=0,o=new Error(u),o.name="BigNumber Error",o}}function l(e,n,t,r){var i,s,o,l,u,f,c,a,h=y;if(a=e.c){e:{for(i=1,l=a[0];l>=10;l/=10,i++);if(s=n-i,0>s)s+=_,o=n,u=a[f=0],c=u/h[i-o-1]%10|0;else if(f=Math.ceil((s+1)/_),f>=a.length){if(!r)break e;for(;a.length<=f;a.push(0));u=c=0,i=1,s%=_,o=s-_+1}else{for(u=l=a[f],i=1;l>=10;l/=10,i++);s%=_,o=s-_+i,c=0>o?0:u/h[i-o-1]%10|0}if(r=r||0>n||null!=a[f+1]||(0>o?u:u%h[i-o-1]),r=4>t?(c||r)&&(0==t||t==(e.s<0?3:2)):c>5||5==c&&(4==t||r||6==t&&(s>0?o>0?u/h[i-o]:0:a[f-1])%10&1||t==(e.s<0?8:7)),1>n||!a[0])return a.length=0,r?(n-=e.e+1,a[0]=h[n%_],e.e=-n||0):a[0]=e.e=0,e;if(0==s?(a.length=f,l=1,f--):(a.length=f+1,l=h[_-s],a[f]=o>0?E(u/h[i-o]%h[o])*l:0),r)for(;;){if(0==f){for(s=1,o=a[0];o>=10;o/=10,s++);for(o=a[0]+=l,l=1;o>=10;o/=10,l++);s!=l&&(e.e++,a[0]==F&&(a[0]=1));break}if(a[f]+=l,a[f]!=F)break;a[f--]=0,l=1}for(s=a.length;0===a[--s];a.pop());}e.e>m?e.c=e.e=null:e.e<p&&(e.c=[e.e=0])}return e}var u=1e9,f=1e6,c=20,a=4,h=-7,g=21,p=-u,m=u,d=!0,v=parseInt,w={decimalSeparator:".",groupSeparator:",",groupSize:3,secondaryGroupSize:0,fractionGroupSeparator:" ",fractionGroupSize:0},N=e.prototype,b="0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ$_",O,S=0,E=Math.floor,A=/^-?(\d+(\.\d*)?|\.\d+)(e[+-]?\d+)?$/i,R=String.prototype.trim||function(){return this.replace(/^\s+|\s+$/g,"")},F=1e14,_=14,x=1e7,y=[1,10,100,1e3,1e4,1e5,1e6,1e7,1e8,1e9,1e10,1e11,1e12,1e13],I=new e(1);e.ROUND_UP=0,e.ROUND_DOWN=1,e.ROUND_CEIL=2,e.ROUND_FLOOR=3,e.ROUND_HALF_UP=4,e.ROUND_HALF_DOWN=5,e.ROUND_HALF_EVEN=6,e.ROUND_HALF_CEIL=7,e.ROUND_HALF_FLOOR=8,e.config=function(){var e,n,t=0,r={},i=arguments,s=i[0],l="config",f=function(e,n,t){return!((O=n>e||e>t)||v(e)!=e&&0!==e)},N=s&&"object"==typeof s?function(){return s.hasOwnProperty(n)?null!=(e=s[n]):void 0}:function(){return i.length>t?null!=(e=i[t++]):void 0};if(N(n="DECIMAL_PLACES")&&(f(e,0,u)?c=0|e:o(e,n,l)),r[n]=c,N(n="ROUNDING_MODE")&&(f(e,0,8)?a=0|e:o(e,n,l)),r[n]=a,N(n="EXPONENTIAL_AT")&&(f(e,-u,u)?h=-(g=~~(0>e?-e:+e)):!O&&e&&f(e[0],-u,0)&&f(e[1],0,u)?(h=~~e[0],g=~~e[1]):o(e,n,l,1)),r[n]=[h,g],N(n="RANGE")&&(f(e,-u,u)&&~~e?p=-(m=~~(0>e?-e:+e)):!O&&e&&f(e[0],-u,-1)&&f(e[1],1,u)?(p=~~e[0],m=~~e[1]):o(e,n,l,1,1)),r[n]=[p,m],N(n="ERRORS")&&(e===!!e||1===e||0===e?(O=S=0,v=(d=!!e)?parseInt:parseFloat):o(e,n,l,0,0,1)),r[n]=d,N(n="FORMAT"))if("object"==typeof e)w=e;else if(d)throw r=new Error(l+"() "+n+" not an object: "+e),r.name="BigNumber Error",r;return r[n]=w,r};var D=function(){function n(e,n,t){var r,i,s,o,l=0,u=e.length,f=n%x,c=n/x|0;for(e=e.slice();u--;)s=e[u]%x,o=e[u]/x|0,r=c*s+o*f,i=f*s+r%x*x+l,l=(i/t|0)+(r/x|0)+c*o,e[u]=i%t;return l&&e.unshift(l),e}function t(e,n,t,r){var i,s;if(t!=r)s=t>r?1:-1;else for(i=s=0;t>i;i++)if(e[i]!=n[i]){s=e[i]>n[i]?1:-1;break}return s}function r(e,n,t,r){for(var i=0;t--;)e[t]-=i,i=e[t]<n[t]?1:0,e[t]=i*r+e[t]-n[t];for(;!e[0]&&e.length>1;e.shift());}return function(i,s,o,u,f){var c,a,h,g,p,m,d,v,w,N,b,O,S,A,R,x,y,I=i.s==s.s?1:-1,D=i.c,L=s.c;if(!(D&&D[0]&&L&&L[0]))return new e(i.s&&s.s&&(D?!L||D[0]!=L[0]:L)?D&&0==D[0]||!L?0*I:I/0:0/0);for(v=new e(I),w=v.c=[],a=i.e-s.e,I=o+a+1,f||(f=F,A=i.e/_,h=0|A,a=(A>0||A===h?h:h-1)-(x=s.e/_,h=0|x,x>0||x===h?h:h-1),I=I/_|0),h=0;L[h]==(D[h]||0);h++);if(L[h]>(D[h]||0)&&a--,0>I)w.push(1),g=!0;else{for(A=D.length,x=L.length,h=0,I+=2,p=E(f/(L[0]+1)),p>1&&(L=n(L,p,f),D=n(D,p,f),x=L.length,A=D.length),S=x,N=D.slice(0,x),b=N.length;x>b;N[b++]=0);y=L.slice(),y.unshift(0),R=L[0],L[1]>=f/2&&R++;do p=0,c=t(L,N,x,b),0>c?(O=N[0],x!=b&&(O=O*f+(N[1]||0)),p=E(O/R),p>1?(p>=f&&(p=f-1),m=n(L,p,f),d=m.length,b=N.length,c=t(m,N,d,b),1==c&&(p--,r(m,d>x?y:L,d,f))):(0==p&&(c=p=1),m=L.slice()),d=m.length,b>d&&m.unshift(0),r(N,m,b,f),-1==c&&(b=N.length,c=t(L,N,x,b),1>c&&(p++,r(N,b>x?y:L,b,f))),b=N.length):0===c&&(p++,N=[0]),w[h++]=p,c&&N[0]?N[b++]=D[S]||0:(N=[D[S]],b=1);while((S++<A||null!=N[0])&&I--);g=null!=N[0],w[0]||w.shift()}if(f==F){for(h=1,I=w[0];I>=10;I/=10,h++);l(v,o+(v.e=h+a*_-1)+1,u,g)}else v.e=a,v.r=+g;return v}}();return N.absoluteValue=N.abs=function(){var n=new e(this);return n.s<0&&(n.s=1),n},N.ceil=function(){return l(new e(this),this.e+1,2)},N.comparedTo=N.cmp=function(n,t){var r,i=this,s=i.c,o=(S=-S,n=new e(n,t)).c,l=i.s,u=n.s,f=i.e,c=n.e;if(!l||!u)return null;if(r=s&&!s[0],t=o&&!o[0],r||t)return r?t?0:-u:l;if(l!=u)return l;if(r=0>l,t=f==c,!s||!o)return t?0:!s^r?1:-1;if(!t)return f>c^r?1:-1;for(l=-1,u=(f=s.length)<(c=o.length)?f:c;++l<u;)if(s[l]!=o[l])return s[l]>o[l]^r?1:-1;return f==c?0:f>c^r?1:-1},N.decimalPlaces=N.dp=function(){var e,n,t=this.c;if(!t)return null;if(e=((n=t.length-1)-E(this.e/_))*_,n=t[n])for(;n%10==0;n/=10,e--);return 0>e&&(e=0),e},N.dividedBy=N.div=function(n,t){return S=2,D(this,new e(n,t),c,a)},N.dividedToIntegerBy=N.divToInt=function(n,t){return S=13,D(this,new e(n,t),0,1)},N.equals=N.eq=function(e,n){return S=3,0===this.cmp(e,n)},N.floor=function(){return l(new e(this),this.e+1,3)},N.greaterThan=N.gt=function(e,n){return S=4,this.cmp(e,n)>0},N.greaterThanOrEqualTo=N.gte=function(e,n){return S=5,1==(n=this.cmp(e,n))||0===n},N.isFinite=function(){return!!this.c},N.isInteger=N.isInt=function(){return!!this.c&&E(this.e/_)>this.c.length-2},N.isNaN=function(){return!this.s},N.isNegative=N.isNeg=function(){return this.s<0},N.isZero=function(){return!!this.c&&0==this.c[0]},N.lessThan=N.lt=function(e,n){return S=6,this.cmp(e,n)<0},N.lessThanOrEqualTo=N.lte=function(e,n){return S=7,-1==(n=this.cmp(e,n))||0===n},N.minus=function(t,r){var i,s,o,l,u=this,f=u.s;if(S=8,t=new e(t,r),r=t.s,!f||!r)return new e(0/0);if(f!=r)return t.s=-r,u.plus(t);var c=u.e/_,h=t.e/_,g=u.c,p=t.c;if(!c||!h){if(!g||!p)return g?(t.s=-r,t):new e(p?u:0/0);if(!g[0]||!p[0])return p[0]?(t.s=-r,t):new e(g[0]?u:3==a?-0:0)}if(i=0|c,c=c>0||c===i?i:i-1,i=0|h,h=h>0||h===i?i:i-1,g=g.slice(),f=c-h){for((l=0>f)?(f=-f,o=g):(h=c,o=p),o.reverse(),r=f;r--;o.push(0));o.reverse()}else for(s=(l=(f=g.length)<(r=p.length))?f:r,f=r=0;s>r;r++)if(g[r]!=p[r]){l=g[r]<p[r];break}if(l&&(o=g,g=p,p=o,t.s=-t.s),r=(s=p.length)-(i=g.length),r>0)for(;r--;g[i++]=0);for(r=F-1;s>f;){if(g[--s]<p[s]){for(i=s;i&&!g[--i];g[i]=r);--g[i],g[s]+=F}g[s]-=p[s]}for(;0==g[0];g.shift(),--h);return g[0]?n(t,g,h):(t.s=3==a?-1:1,t.c=[t.e=0],t)},N.modulo=N.mod=function(n,t){S=9;var r=this,i=r.c,s=(n=new e(n,t)).c,o=r.s,l=n.s;return t=!o||!l||s&&!s[0],t||i&&!i[0]?new e(t?0/0:r):(r.s=n.s=1,t=1==n.cmp(r),r.s=o,n.s=l,t?new e(r):r.minus(D(r,n,0,1).times(n)))},N.negated=N.neg=function(){var n=new e(this);return n.s=-n.s||null,n},N.plus=function(t,r){var i,s=this,o=s.s;if(S=10,t=new e(t,r),r=t.s,!o||!r)return new e(0/0);if(o!=r)return t.s=-r,s.minus(t);var l=s.e/_,u=t.e/_,f=s.c,c=t.c;if(!l||!u){if(!f||!c)return new e(o/0);if(!f[0]||!c[0])return c[0]?t:new e(f[0]?s:0*o)}if(o=0|l,l=l>0||l===o?o:o-1,o=0|u,u=u>0||u===o?o:o-1,f=f.slice(),o=l-u){for(o>0?(u=l,i=c):(o=-o,i=f),i.reverse();o--;i.push(0));i.reverse()}for(o=f.length,r=c.length,0>o-r&&(i=c,c=f,f=i,r=o),o=0;r;)o=(f[--r]=f[r]+c[r]+o)/F|0,f[r]%=F;return o&&(f.unshift(o),++u),n(t,f,u)},N.round=function(n,t){return n=null==n||((O=0>n||n>u)||v(n)!=n)&&!o(n,"decimal places","round")?0:0|n,t=null==t||((O=0>t||t>8)||v(t)!=t&&0!==t)&&!o(t,"mode","round")?a:0|t,l(new e(this),n+this.e+1,t)},N.squareRoot=N.sqrt=function(){var n,r,i,s,o,u=this,f=u.c,h=u.s,g=u.e,p=c+4,m=new e("0.5");if(1!==h||!f||!f[0])return new e(!h||0>h&&(!f||f[0])?0/0:f?u:1/0);if(h=Math.sqrt(+u),0==h||h==1/0?(r=t(f),(r.length+g)%2==0&&(r+="0"),h=Math.sqrt(r),g=E((g+1)/2)-(0>g||g%2),h==1/0?r="1e"+g:(r=h.toExponential(),r=r.slice(0,r.indexOf("e")+1)+g),i=new e(r)):i=new e(h.toString()),i.c[0])for(g=i.e,h=g+p,3>h&&(h=0);;)if(o=i,i=m.times(o.plus(D(u,o,p,1))),t(o.c).slice(0,h)===(r=t(i.c)).slice(0,h)){if(i.e<g&&--h,r=r.slice(h-3,h+1),"9999"!=r&&(s||"4999"!=r)){(!+r||!+r.slice(1)&&"5"==r.charAt(0))&&(l(i,i.e+c+2,1),n=!i.times(i).eq(u));break}if(!s&&(l(o,o.e+c+2,0),o.times(o).eq(u))){i=o;break}p+=4,h+=4,s=1}return l(i,i.e+c+1,a,n)},N.times=function(t,r){var i,s,o,l,u,f,c,a,h,g=this,p=g.c,m=(S=11,t=new e(t,r)).c,d=g.e/_,v=t.e/_,w=g.s;if(t.s=w==(r=t.s)?1:-1,!((d||p&&p[0])&&(v||m&&m[0])))return new e(!w||!r||p&&!p[0]&&!m||m&&!m[0]&&!p?0/0:p&&m?0*t.s:t.s/0);for(s=0|d,s=(d>0||d===s?s:s-1)+(s=0|v,v>0||v===s?s:s-1),w=p.length,r=m.length,r>w&&(u=p,p=m,m=u,v=w,w=r,r=v),v=w+r,u=[];v--;u.push(0));for(d=r;--d>=0;){for(i=0,v=w+d,o=w,a=m[d]%x,h=m[d]/x|0;v>d;)f=p[--o]%x,c=p[o]/x|0,l=h*f+c*a,f=a*f+l%x*x+u[v]+i,i=(f/F|0)+(l/x|0)+h*c,u[v--]=f%F;u[v]=i}return i?++s:u.shift(),n(t,u,s)},N.toExponential=function(e){var n=this;return n.c?s(n,null==e||((O=0>e||e>u)||v(e)!=e&&0!==e)&&!o(e,"decimal places","toExponential")?null:0|e,1):n.toString()},N.toFixed=function(e){var n,t=this,r=h,i=g;return e=null==e||((O=0>e||e>u)||v(e)!=e&&0!==e)&&!o(e,"decimal places","toFixed")?null:t.e+(0|e),h=-(g=1/0),null!=e&&t.c?(n=s(t,e),t.s<0&&t.c&&(t.c[0]?n.indexOf("-")<0&&(n="-"+n):n=n.replace("-",""))):n=t.toString(),h=r,g=i,n},N.toFormat=function(e){var n=this;if(!n.c)return n.toString();var t,r=n.s<0,i=w.groupSeparator,s=+w.groupSize,o=+w.secondaryGroupSize,l=n.toFixed(e).split("."),u=l[0],f=l[1],c=r?u.slice(1):u,a=c.length;if(o&&(t=s,s=o,o=t,a-=t),s>0&&a>0){for(t=a%s||s,u=c.substr(0,t);a>t;t+=s)u+=i+c.substr(t,s);o>0&&(u+=i+c.slice(t)),r&&(u="-"+u)}return f?u+w.decimalSeparator+((o=+w.fractionGroupSize)?f.replace(new RegExp("\\d{"+o+"}\\B","g"),"$&"+w.fractionGroupSeparator):f):u},N.toFraction=function(n){var r,i,s,l,u,f,c,h,g,p=i=new e(I),v=c=new e(I),w=this,N=w.c,b=new e(I);if(!N)return w.toString();for(g=t(N),l=b.e=g.length-w.e-1,b.c[0]=y[(u=l%_)<0?_+u:u],(null==n||(!(S=12,f=new e(n)).s||(O=f.cmp(p)<0||!f.c)||d&&E(f.e/_)<f.c.length-1)&&!o(n,"max denominator","toFraction")||(n=f).cmp(b)>0)&&(n=l>0?b:p),u=m,m=1/0,f=new e(g),c.c[0]=0;h=D(f,b,0,1),s=i.plus(h.times(v)),1!=s.cmp(n);)i=v,v=s,p=c.plus(h.times(s=p)),c=s,b=f.minus(h.times(s=b)),f=s;return s=D(n.minus(i),v,0,1),c=c.plus(s.times(p)),i=i.plus(s.times(v)),c.s=p.s=w.s,l*=2,r=D(p,v,l,a).minus(w).abs().cmp(D(c,i,l,a).minus(w).abs())<1?[p.toString(),v.toString()]:[c.toString(),i.toString()],m=u,r},N.toNumber=function(){var e=this;return+e||(e.s?0*e.s:0/0)},N.toPower=N.pow=function(n){var t=0*n==0?~~n:n,r=new e(this),i=new e(I);if(((O=-f>n||n>f)&&(t=1*n/0)||v(n)!=n&&0!==n&&!(t=0/0))&&!o(n,"exponent","pow")||!t)return new e(Math.pow(+r,t));for(t=0>t?-t:t;1&t&&(i=i.times(r)),t>>=1,t;)r=r.times(r);return 0>n?I.div(i):i},N.toPrecision=function(e){var n=this;return null!=e&&(!(O=1>e||e>u)&&v(e)==e||o(e,"precision","toPrecision"))&&n.c?s(n,0|--e,2):n.toString()},N.toString=function(e){var n,r,l,u=this,f=u.e;if(null===f)r=u.s?"Infinity":"NaN";else{if(e==n&&(h>=f||f>=g))return s(u,n,1);if(r=t(u.c),0>f){for(;++f;r="0"+r);r="0."+r}else if(l=r.length,f>0)if(++f>l)for(f-=l;f--;r+="0");else l>f&&(r=r.slice(0,f)+"."+r.slice(f));else if(n=r.charAt(0),l>1)r=n+"."+r.slice(1);else if("0"==n)return n;if(null!=e)if((O=!(e>=2&&65>e))||e!=~~e&&d)o(e,"base","toS");else if(r=i(r,0|e,10,u.s),"0"==r)return r}return u.s<0?"-"+r:r},N.valueOf=N.toJSON=function(){return this.toString()},e}()}).call(this),"undefined"==typeof Package&&(Package={}),Package["3stack:bignumber"]={BigNumber:n}}();
+
+!function(){var e=Package.meteor.Meteor,r;(function(){r={extensions:{}};var e=r.forEach=function(e,r){if("function"==typeof e.forEach)e.forEach(r);else{var n,t=e.length;for(n=0;t>n;n++)r(e[n],n,e)}},n=function(e){return e.replace(/[_-]||\s/g,"").toLowerCase()};r.converter=function(e){var t,a,c,o=0,l=[],i=[];if("undefind"!=typeof module&&"undefined"!=typeof exports&&"undefind"!=typeof require){var u=require("fs");if(u){var p=u.readdirSync((__dirname||".")+"/extensions").filter(function(e){return~e.indexOf(".js")}).map(function(e){return e.replace(/\.js$/,"")});r.forEach(p,function(e){var t=n(e);r.extensions[t]=require("./extensions/"+e)})}}if(this.makeHtml=function(e){return t={},a={},c=[],e=e.replace(/~/g,"~T"),e=e.replace(/\$/g,"~D"),e=e.replace(/\r\n/g,"\n"),e=e.replace(/\r/g,"\n"),e="\n\n"+e+"\n\n",e=D(e),e=e.replace(/^[ \t]+$/gm,""),r.forEach(l,function(r){e=g(r,e)}),e=C(e),e=d(e),e=s(e),e=m(e),e=j(e),e=e.replace(/~D/g,"$$"),e=e.replace(/~T/g,"~"),r.forEach(i,function(r){e=g(r,e)}),e},e&&e.extensions){var f=this;r.forEach(e.extensions,function(e){if("string"==typeof e&&(e=r.extensions[n(e)]),"function"!=typeof e)throw"Extension '"+e+"' could not be loaded. It was either not found or is not a valid extension.";r.forEach(e(f),function(e){e.type?"language"===e.type||"lang"===e.type?l.push(e):("output"===e.type||"html"===e.type)&&i.push(e):i.push(e)})})}var g=function(e,r){if(e.regex){var n=new RegExp(e.regex,"g");return r.replace(n,e.replace)}return e.filter?e.filter(r):void 0},s=function(e){return e+="~0",e=e.replace(/^[ ]{0,3}\[(.+)\]:[ \t]*\n?[ \t]*<?(\S+?)>?[ \t]*\n?[ \t]*(?:(\n*)["(](.+?)[")][ \t]*)?(?:\n+|(?=~0))/gm,function(e,r,n,c,o){return r=r.toLowerCase(),t[r]=A(n),c?c+o:(o&&(a[r]=o.replace(/"/g,"&quot;")),"")}),e=e.replace(/~0/,"")},d=function(e){e=e.replace(/\n/g,"\n\n");var r="p|div|h[1-6]|blockquote|pre|table|dl|ol|ul|script|noscript|form|fieldset|iframe|math|ins|del|style|section|header|footer|nav|article|aside",n="p|div|h[1-6]|blockquote|pre|table|dl|ol|ul|script|noscript|form|fieldset|iframe|math|style|section|header|footer|nav|article|aside";return e=e.replace(/^(<(p|div|h[1-6]|blockquote|pre|table|dl|ol|ul|script|noscript|form|fieldset|iframe|math|ins|del)\b[^\r]*?\n<\/\2>[ \t]*(?=\n+))/gm,h),e=e.replace(/^(<(p|div|h[1-6]|blockquote|pre|table|dl|ol|ul|script|noscript|form|fieldset|iframe|math|style|section|header|footer|nav|article|aside)\b[^\r]*?<\/\2>[ \t]*(?=\n+)\n)/gm,h),e=e.replace(/(\n[ ]{0,3}(<(hr)\b([^<>])*?\/?>)[ \t]*(?=\n{2,}))/g,h),e=e.replace(/(\n\n[ ]{0,3}<!(--[^\r]*?--\s*)+>[ \t]*(?=\n{2,}))/g,h),e=e.replace(/(?:\n\n)([ ]{0,3}(?:<([?%])[^\r]*?\2>)[ \t]*(?=\n{2,}))/g,h),e=e.replace(/\n\n/g,"\n")},h=function(e,r){var n=r;return n=n.replace(/\n\n/g,"\n"),n=n.replace(/^\n/,""),n=n.replace(/\n+$/g,""),n="\n\n~K"+(c.push(n)-1)+"K\n\n"},m=function(e){e=E(e);var r=q("<hr />");return e=e.replace(/^[ ]{0,2}([ ]?\*[ ]?){3,}[ \t]*$/gm,r),e=e.replace(/^[ ]{0,2}([ ]?\-[ ]?){3,}[ \t]*$/gm,r),e=e.replace(/^[ ]{0,2}([ ]?\_[ ]?){3,}[ \t]*$/gm,r),e=_(e),e=S(e),e=P(e),e=d(e),e=z(e)},v=function(e){return e=K(e),e=$(e),e=B(e),e=x(e),e=w(e),e=M(e),e=A(e),e=L(e),e=e.replace(/ +\n/g," <br />\n")},$=function(e){var r=/(<[a-z\/!$]("[^"]*"|'[^']*'|[^'">])*>|<!(--.*?--\s*)+>)/gi;return e=e.replace(r,function(e){var r=e.replace(/(.)<\/?code>(?=.)/g,"$1`");return r=I(r,"\\`*_")})},w=function(e){return e=e.replace(/(\[((?:\[[^\]]*\]|[^\[\]])*)\][ ]?(?:\n[ ]*)?\[(.*?)\])()()()()/g,k),e=e.replace(/(\[((?:\[[^\]]*\]|[^\[\]])*)\]\([ \t]*()<?(.*?(?:\(.*?\).*?)?)>?[ \t]*((['"])(.*?)\6[ \t]*)?\))/g,k),e=e.replace(/(\[([^\[\]]+)\])()()()()()/g,k)},k=function(e,r,n,c,o,l,i,u){void 0==u&&(u="");var p=r,f=n,g=c.toLowerCase(),s=o,d=u;if(""==s)if(""==g&&(g=f.toLowerCase().replace(/ ?\n/g," ")),s="#"+g,void 0!=t[g])s=t[g],void 0!=a[g]&&(d=a[g]);else{if(!(p.search(/\(\s*\)$/m)>-1))return p;s=""}s=I(s,"*_");var h='<a href="'+s+'"';return""!=d&&(d=d.replace(/"/g,"&quot;"),d=I(d,"*_"),h+=' title="'+d+'"'),h+=">"+f+"</a>"},x=function(e){return e=e.replace(/(!\[(.*?)\][ ]?(?:\n[ ]*)?\[(.*?)\])()()()()/g,y),e=e.replace(/(!\[(.*?)\]\s?\([ \t]*()<?(\S+?)>?[ \t]*((['"])(.*?)\6[ \t]*)?\))/g,y)},y=function(e,r,n,c,o,l,i,u){var p=r,f=n,g=c.toLowerCase(),s=o,d=u;if(d||(d=""),""==s){if(""==g&&(g=f.toLowerCase().replace(/ ?\n/g," ")),s="#"+g,void 0==t[g])return p;s=t[g],void 0!=a[g]&&(d=a[g])}f=f.replace(/"/g,"&quot;"),s=I(s,"*_");var h='<img src="'+s+'" alt="'+f+'"';return d=d.replace(/"/g,"&quot;"),d=I(d,"*_"),h+=' title="'+d+'"',h+=" />"},E=function(e){function r(e){return e.replace(/[^\w]/g,"").toLowerCase()}return e=e.replace(/^(.+)[ \t]*\n=+[ \t]*\n+/gm,function(e,n){return q('<h1 id="'+r(n)+'">'+v(n)+"</h1>")}),e=e.replace(/^(.+)[ \t]*\n-+[ \t]*\n+/gm,function(e,n){return q('<h2 id="'+r(n)+'">'+v(n)+"</h2>")}),e=e.replace(/^(\#{1,6})[ \t]*(.+?)[ \t]*\#*\n+/gm,function(e,n,t){var a=n.length;return q("<h"+a+' id="'+r(t)+'">'+v(t)+"</h"+a+">")})},b,_=function(e){e+="~0";var r=/^(([ ]{0,3}([*+-]|\d+[.])[ \t]+)[^\r]+?(~0|\n{2,}(?=\S)(?![ \t]*(?:[*+-]|\d+[.])[ \t]+)))/gm;return o?e=e.replace(r,function(e,r,n){var t=r,a=n.search(/[*+-]/g)>-1?"ul":"ol";t=t.replace(/\n{2,}/g,"\n\n\n");var c=b(t);return c=c.replace(/\s+$/,""),c="<"+a+">"+c+"</"+a+">\n"}):(r=/(\n\n|^\n?)(([ ]{0,3}([*+-]|\d+[.])[ \t]+)[^\r]+?(~0|\n{2,}(?=\S)(?![ \t]*(?:[*+-]|\d+[.])[ \t]+)))/g,e=e.replace(r,function(e,r,n,t){var a=r,c=n,o=t.search(/[*+-]/g)>-1?"ul":"ol",c=c.replace(/\n{2,}/g,"\n\n\n"),l=b(c);return l=a+"<"+o+">\n"+l+"</"+o+">\n"})),e=e.replace(/~0/,"")};b=function(e){return o++,e=e.replace(/\n{2,}$/,"\n"),e+="~0",e=e.replace(/(\n)?(^[ \t]*)([*+-]|\d+[.])[ \t]+([^\r]+?(\n{1,2}))(?=\n*(~0|\2([*+-]|\d+[.])[ \t]+))/gm,function(e,r,n,t,a){var c=a,o=r,l=n;return o||c.search(/\n{2,}/)>-1?c=m(H(c)):(c=_(H(c)),c=c.replace(/\n$/,""),c=v(c)),"<li>"+c+"</li>\n"}),e=e.replace(/~0/g,""),o--,e};var S=function(e){return e+="~0",e=e.replace(/(?:\n\n|^)((?:(?:[ ]{4}|\t).*\n+)+)(\n*[ ]{0,3}[^ \t\n]|(?=~0))/g,function(e,r,n){var t=r,a=n;return t=T(H(t)),t=D(t),t=t.replace(/^\n+/g,""),t=t.replace(/\n+$/g,""),t="<pre><code>"+t+"\n</code></pre>",q(t)+a}),e=e.replace(/~0/,"")},C=function(e){return e+="~0",e=e.replace(/(?:^|\n)```(.*)\n([\s\S]*?)\n```/g,function(e,r,n){var t=r,a=n;return a=T(a),a=D(a),a=a.replace(/^\n+/g,""),a=a.replace(/\n+$/g,""),a="<pre><code"+(t?' class="'+t+'"':"")+">"+a+"\n</code></pre>",q(a)}),e=e.replace(/~0/,"")},q=function(e){return e=e.replace(/(^\n+|\n+$)/g,""),"\n\n~K"+(c.push(e)-1)+"K\n\n"},K=function(e){return e=e.replace(/(^|[^\\])(`+)([^\r]*?[^`])\2(?!`)/gm,function(e,r,n,t,a){var c=t;return c=c.replace(/^([ \t]*)/g,""),c=c.replace(/[ \t]*$/g,""),c=T(c),r+"<code>"+c+"</code>"})},T=function(e){return e=e.replace(/&/g,"&amp;"),e=e.replace(/</g,"&lt;"),e=e.replace(/>/g,"&gt;"),e=I(e,"*_{}[]\\",!1)},L=function(e){return e=e.replace(/(\*\*|__)(?=\S)([^\r]*?\S[*_]*)\1/g,"<strong>$2</strong>"),e=e.replace(/(\*|_)(?=\S)([^\r]*?\S)\1/g,"<em>$2</em>")},P=function(e){return e=e.replace(/((^[ \t]*>[ \t]?.+\n(.+\n)*\n*)+)/gm,function(e,r){var n=r;return n=n.replace(/^[ \t]*>[ \t]?/gm,"~0"),n=n.replace(/~0/g,""),n=n.replace(/^[ \t]+$/gm,""),n=m(n),n=n.replace(/(^|\n)/g,"$1 "),n=n.replace(/(\s*<pre>[^\r]+?<\/pre>)/gm,function(e,r){var n=r;return n=n.replace(/^ /gm,"~0"),n=n.replace(/~0/g,"")}),q("<blockquote>\n"+n+"\n</blockquote>")})},z=function(e){e=e.replace(/^\n+/g,""),e=e.replace(/\n+$/g,"");for(var r=e.split(/\n{2,}/g),n=[],t=r.length,a=0;t>a;a++){var o=r[a];o.search(/~K(\d+)K/g)>=0?n.push(o):o.search(/\S/)>=0&&(o=v(o),o=o.replace(/^([ \t]*)/g,"<p>"),o+="</p>",n.push(o))}t=n.length;for(var a=0;t>a;a++)for(;n[a].search(/~K(\d+)K/)>=0;){var l=c[RegExp.$1];l=l.replace(/\$/g,"$$$$"),n[a]=n[a].replace(/~K\d+K/,l)}return n.join("\n\n")},A=function(e){return e=e.replace(/&(?!#?[xX]?(?:[0-9a-fA-F]+|\w+);)/g,"&amp;"),e=e.replace(/<(?![a-z\/?\$!])/gi,"&lt;")},B=function(e){return e=e.replace(/\\(\\)/g,O),e=e.replace(/\\([`*_{}\[\]()>#+-.!])/g,O)},M=function(e){return e=e.replace(/<((https?|ftp|dict):[^'">\s]+)>/gi,'<a href="$1">$1</a>'),e=e.replace(/<(?:mailto:)?([-.\w]+\@[-a-z0-9]+(\.[-a-z0-9]+)*\.[a-z]+)>/gi,function(e,r){return R(j(r))})},R=function(e){var r=[function(e){return"&#"+e.charCodeAt(0)+";"},function(e){return"&#x"+e.charCodeAt(0).toString(16)+";"},function(e){return e}];return e="mailto:"+e,e=e.replace(/./g,function(e){if("@"==e)e=r[Math.floor(2*Math.random())](e);else if(":"!=e){var n=Math.random();e=n>.9?r[2](e):n>.45?r[1](e):r[0](e)}return e}),e='<a href="'+e+'">'+e+"</a>",e=e.replace(/">.+:/g,'">')},j=function(e){return e=e.replace(/~E(\d+)E/g,function(e,r){var n=parseInt(r);return String.fromCharCode(n)})},H=function(e){return e=e.replace(/^(\t|[ ]{1,4})/gm,"~0"),e=e.replace(/~0/g,"")},D=function(e){return e=e.replace(/\t(?=\t)/g," "),e=e.replace(/\t/g,"~A~B"),e=e.replace(/~B(.+?)~A/g,function(e,r,n){for(var t=r,a=4-t.length%4,c=0;a>c;c++)t+=" ";return t}),e=e.replace(/~A/g," "),e=e.replace(/~B/g,"")},I=function(e,r,n){var t="(["+r.replace(/([\[\]\\])/g,"\\$1")+"])";n&&(t="\\\\"+t);var a=new RegExp(t,"g");return e=e.replace(a,O)},O=function(e,r){var n=r.charCodeAt(0);return"~E"+n+"E"}},"undefined"!=typeof module&&(module.exports=r),"function"==typeof define&&define.amd&&define("showdown",function(){return r})}).call(this),function(){if(Package.templating){var e=Package.templating.Template,n=Package.blaze.Blaze,t=Package.htmljs.HTML;n.Template.registerHelper("markdown",new e("markdown",function(){var e=this,a="";e.templateContentBlock&&(a=n._toText(e.templateContentBlock,t.TEXTMODE.STRING));var c=new r.converter;return t.Raw(c.makeHtml(a))}))}}.call(this),"undefined"==typeof Package&&(Package={}),Package.markdown={Showdown:r}}();
+
+!function(){var e=Package.meteor.Meteor,n;(function(){(function(){function e(e){this._value=e}function n(e,n,i,t){var l=Math.pow(10,n),o,r;return r=(i(e*l)/l).toFixed(n),t&&(o=new RegExp("0{1,"+t+"}$"),r=r.replace(o,"")),r}function i(e,n,i){var t;return t=n.indexOf("$")>-1?l(e,n,i):n.indexOf("%")>-1?o(e,n,i):n.indexOf(":")>-1?r(e,n):a(e._value,n,i)}function t(e,n){var i=n,t,l,o,r,a=["KB","MB","GB","TB","PB","EB","ZB","YB"],d=!1,s;if(n.indexOf(":")>-1)e._value=u(n);else if(n===b)e._value=0;else{for("."!==h[p].delimiters.decimal&&(n=n.replace(/\./g,"").replace(h[p].delimiters.decimal,".")),t=new RegExp("[^a-zA-Z]"+h[p].abbreviations.thousand+"(?:\\)|(\\"+h[p].currency.symbol+")?(?:\\))?)?$"),l=new RegExp("[^a-zA-Z]"+h[p].abbreviations.million+"(?:\\)|(\\"+h[p].currency.symbol+")?(?:\\))?)?$"),o=new RegExp("[^a-zA-Z]"+h[p].abbreviations.billion+"(?:\\)|(\\"+h[p].currency.symbol+")?(?:\\))?)?$"),r=new RegExp("[^a-zA-Z]"+h[p].abbreviations.trillion+"(?:\\)|(\\"+h[p].currency.symbol+")?(?:\\))?)?$"),s=0;s<=a.length&&!(d=n.indexOf(a[s])>-1?Math.pow(1024,s+1):!1);s++);e._value=(d?d:1)*(i.match(t)?Math.pow(10,3):1)*(i.match(l)?Math.pow(10,6):1)*(i.match(o)?Math.pow(10,9):1)*(i.match(r)?Math.pow(10,12):1)*(n.indexOf("%")>-1?.01:1)*((n.split("-").length+Math.min(n.split("(").length-1,n.split(")").length-1))%2?1:-1)*Number(n.replace(/[^0-9\.]+/g,"")),e._value=d?Math.ceil(e._value):e._value}return e._value}function l(e,n,i){var t=n.indexOf("$"),l=n.indexOf("("),o=n.indexOf("-"),r="",u,d;return n.indexOf(" $")>-1?(r=" ",n=n.replace(" $","")):n.indexOf("$ ")>-1?(r=" ",n=n.replace("$ ","")):n=n.replace("$",""),d=a(e._value,n,i),1>=t?d.indexOf("(")>-1||d.indexOf("-")>-1?(d=d.split(""),u=1,(l>t||o>t)&&(u=0),d.splice(u,0,h[p].currency.symbol+r),d=d.join("")):d=h[p].currency.symbol+r+d:d.indexOf(")")>-1?(d=d.split(""),d.splice(-1,0,r+h[p].currency.symbol),d=d.join("")):d=d+r+h[p].currency.symbol,d}function o(e,n,i){var t="",l,o=100*e._value;return n.indexOf(" %")>-1?(t=" ",n=n.replace(" %","")):n=n.replace("%",""),l=a(o,n,i),l.indexOf(")")>-1?(l=l.split(""),l.splice(-1,0,t+"%"),l=l.join("")):l=l+t+"%",l}function r(e){var n=Math.floor(e._value/60/60),i=Math.floor((e._value-60*n*60)/60),t=Math.round(e._value-60*n*60-60*i);return n+":"+(10>i?"0"+i:i)+":"+(10>t?"0"+t:t)}function u(e){var n=e.split(":"),i=0;return 3===n.length?(i+=60*Number(n[0])*60,i+=60*Number(n[1]),i+=Number(n[2])):2===n.length&&(i+=60*Number(n[0]),i+=Number(n[1])),Number(i)}function a(e,i,t){var l=!1,o=!1,r=!1,u="",a=!1,d=!1,s=!1,m=!1,c=!1,f="",g="",y=Math.abs(e),v=["B","KB","MB","GB","TB","PB","EB","ZB","YB"],w,x,M,O,_,k,$="",B=!1;if(0===e&&null!==b)return b;if(i.indexOf("(")>-1?(l=!0,i=i.slice(1,-1)):i.indexOf("+")>-1&&(o=!0,i=i.replace(/\+/g,"")),i.indexOf("a")>-1&&(a=i.indexOf("aK")>=0,d=i.indexOf("aM")>=0,s=i.indexOf("aB")>=0,m=i.indexOf("aT")>=0,c=a||d||s||m,i.indexOf(" a")>-1?(u=" ",i=i.replace(" a","")):i=i.replace("a",""),y>=Math.pow(10,12)&&!c||m?(u+=h[p].abbreviations.trillion,e/=Math.pow(10,12)):y<Math.pow(10,12)&&y>=Math.pow(10,9)&&!c||s?(u+=h[p].abbreviations.billion,e/=Math.pow(10,9)):y<Math.pow(10,9)&&y>=Math.pow(10,6)&&!c||d?(u+=h[p].abbreviations.million,e/=Math.pow(10,6)):(y<Math.pow(10,6)&&y>=Math.pow(10,3)&&!c||a)&&(u+=h[p].abbreviations.thousand,e/=Math.pow(10,3))),i.indexOf("b")>-1)for(i.indexOf(" b")>-1?(f=" ",i=i.replace(" b","")):i=i.replace("b",""),M=0;M<=v.length;M++)if(w=Math.pow(1024,M),x=Math.pow(1024,M+1),e>=w&&x>e){f+=v[M],w>0&&(e/=w);break}return i.indexOf("o")>-1&&(i.indexOf(" o")>-1?(g=" ",i=i.replace(" o","")):i=i.replace("o",""),g+=h[p].ordinal(e)),i.indexOf("[.]")>-1&&(r=!0,i=i.replace("[.]",".")),O=e.toString().split(".")[0],_=i.split(".")[1],k=i.indexOf(","),_?(_.indexOf("[")>-1?(_=_.replace("]",""),_=_.split("["),$=n(e,_[0].length+_[1].length,t,_[1].length)):$=n(e,_.length,t),O=$.split(".")[0],$=$.split(".")[1].length?h[p].delimiters.decimal+$.split(".")[1]:"",r&&0===Number($.slice(1))&&($="")):O=n(e,null,t),O.indexOf("-")>-1&&(O=O.slice(1),B=!0),k>-1&&(O=O.toString().replace(/(\d)(?=(\d{3})+(?!\d))/g,"$1"+h[p].delimiters.thousands)),0===i.indexOf(".")&&(O=""),(l&&B?"(":"")+(!l&&B?"-":"")+(!B&&o?"+":"")+O+$+(g?g:"")+(u?u:"")+(f?f:"")+(l&&B?")":"")}function d(e,n){h[e]=n}function s(e){var n=e.toString().split(".");return n.length<2?1:Math.pow(10,n[1].length)}function m(){var e=Array.prototype.slice.call(arguments);return e.reduce(function(e,n){var i=s(e),t=s(n);return i>t?i:t},-1/0)}var c,f="1.5.3",h={},p="en",b=null,g="0,0",y="undefined"!=typeof module&&module.exports;c=function(n){return c.isNumeral(n)?n=n.value():0===n||"undefined"==typeof n?n=0:Number(n)||(n=c.fn.unformat(n)),new e(Number(n))},c.version=f,c.isNumeral=function(n){return n instanceof e},c.language=function(e,n){if(!e)return p;if(e=e.toLowerCase(),e&&!n){if(!h[e])throw new Error("Unknown language : "+e);p=e}return(n||!h[e])&&d(e,n),c},c.languageData=function(e){if(!e)return h[p];if(!h[e])throw new Error("Unknown language : "+e);return h[e]},c.language("en",{delimiters:{thousands:",",decimal:"."},abbreviations:{thousand:"k",million:"m",billion:"b",trillion:"t"},ordinal:function(e){var n=e%10;return 1===~~(e%100/10)?"th":1===n?"st":2===n?"nd":3===n?"rd":"th"},currency:{symbol:"$"}}),c.zeroFormat=function(e){b="string"==typeof e?e:null},c.defaultFormat=function(e){g="string"==typeof e?e:"0.0"},c.validate=function(e,n){var i,t,l,o,r,u,a,d;if("string"!=typeof e&&(e+="",console.warn&&console.warn("Numeral.js: Value is not string. It has been co-erced to: ",e)),e=e.trim(),e.match(/^\d+$/))return!0;if(""===e)return!1;try{a=c.languageData(n)}catch(s){a=c.languageData(c.language())}return l=a.currency.symbol,r=a.abbreviations,i=a.delimiters.decimal,t="."===a.delimiters.thousands?"\\.":a.delimiters.thousands,d=e.match(/^[^\d]+/),null!==d&&(e=e.substr(1),d[0]!==l)?!1:(d=e.match(/[^\d]+$/),null!==d&&(e=e.slice(0,-1),d[0]!==r.thousand&&d[0]!==r.million&&d[0]!==r.billion&&d[0]!==r.trillion)?!1:(u=new RegExp(t+"{2}"),e.match(/[^\d.,]/g)?!1:(o=e.split(i),o.length>2?!1:o.length<2?!!o[0].match(/^\d+.*\d$/)&&!o[0].match(u):1===o[0].length?!!o[0].match(/^\d+$/)&&!o[0].match(u)&&!!o[1].match(/^\d+$/):!!o[0].match(/^\d+.*\d$/)&&!o[0].match(u)&&!!o[1].match(/^\d+$/))))},"function"!=typeof Array.prototype.reduce&&(Array.prototype.reduce=function(e,n){"use strict";if(null===this||"undefined"==typeof this)throw new TypeError("Array.prototype.reduce called on null or undefined");if("function"!=typeof e)throw new TypeError(e+" is not a function");var i,t,l=this.length>>>0,o=!1;for(1<arguments.length&&(t=n,o=!0),i=0;l>i;++i)this.hasOwnProperty(i)&&(o?t=e(t,this[i],i,this):(t=this[i],o=!0));if(!o)throw new TypeError("Reduce of empty array with no initial value");return t}),c.fn=e.prototype={clone:function(){return c(this)},format:function(e,n){return i(this,e?e:g,void 0!==n?n:Math.round)},unformat:function(e){return"[object Number]"===Object.prototype.toString.call(e)?e:t(this,e?e:g)},value:function(){return this._value},valueOf:function(){return this._value},set:function(e){return this._value=Number(e),this},add:function(e){function n(e,n,t,l){return e+i*n}var i=m.call(null,this._value,e);return this._value=[this._value,e].reduce(n,0)/i,this},subtract:function(e){function n(e,n,t,l){return e-i*n}var i=m.call(null,this._value,e);return this._value=[e].reduce(n,this._value*i)/i,this},multiply:function(e){function n(e,n,i,t){var l=m(e,n);return e*l*n*l/(l*l)}return this._value=[this._value,e].reduce(n,1),this},divide:function(e){function n(e,n,i,t){var l=m(e,n);return e*l/(n*l)}return this._value=[this._value,e].reduce(n),this},difference:function(e){return Math.abs(c(this._value).subtract(e).value())}},y&&(module.exports=c),"undefined"==typeof ender&&(this.numeral=c),"function"==typeof define&&define.amd&&define([],function(){return c})}).call(this)}).call(this),function(){!function(){var e={delimiters:{thousands:" ",decimal:","},abbreviations:{thousand:"k",million:" mln",billion:" mld",trillion:" bln"},ordinal:function(e){var n=e%100;return 0!==e&&1>=n||8===n||n>=20?"ste":"de"},currency:{symbol:"€ "}};"undefined"!=typeof module&&module.exports&&(module.exports=e),"undefined"!=typeof window&&this.numeral&&this.numeral.language&&this.numeral.language("be-nl",e)}(),function(){var e={delimiters:{thousands:",",decimal:"."},abbreviations:{thousand:"千",million:"百万",billion:"十亿",trillion:"兆"},ordinal:function(){return"."},currency:{symbol:"¥"}};"undefined"!=typeof module&&module.exports&&(module.exports=e),"undefined"!=typeof window&&this.numeral&&this.numeral.language&&this.numeral.language("chs",e)}(),function(){var e={delimiters:{thousands:" ",decimal:","},abbreviations:{thousand:"tis.",million:"mil.",billion:"b",trillion:"t"},ordinal:function(){return"."},currency:{symbol:"Kč"}};"undefined"!=typeof module&&module.exports&&(module.exports=e),"undefined"!=typeof window&&this.numeral&&this.numeral.language&&this.numeral.language("cs",e)}(),function(){var e={delimiters:{thousands:".",decimal:","},abbreviations:{thousand:"k",million:"mio",billion:"mia",trillion:"b"},ordinal:function(){return"."},currency:{symbol:"DKK"}};"undefined"!=typeof module&&module.exports&&(module.exports=e),"undefined"!=typeof window&&this.numeral&&this.numeral.language&&this.numeral.language("da-dk",e)}(),function(){var e={delimiters:{thousands:" ",decimal:","},abbreviations:{thousand:"k",million:"m",billion:"b",trillion:"t"},ordinal:function(){return"."},currency:{symbol:"CHF"}};"undefined"!=typeof module&&module.exports&&(module.exports=e),"undefined"!=typeof window&&this.numeral&&this.numeral.language&&this.numeral.language("de-ch",e)}(),function(){var e={delimiters:{thousands:" ",decimal:","},abbreviations:{thousand:"k",million:"m",billion:"b",trillion:"t"},ordinal:function(){return"."},currency:{symbol:"€"}};"undefined"!=typeof module&&module.exports&&(module.exports=e),"undefined"!=typeof window&&this.numeral&&this.numeral.language&&this.numeral.language("de",e)}(),function(){var e={delimiters:{thousands:",",decimal:"."},abbreviations:{thousand:"k",million:"m",billion:"b",trillion:"t"},ordinal:function(e){var n=e%10;return 1===~~(e%100/10)?"th":1===n?"st":2===n?"nd":3===n?"rd":"th"},currency:{symbol:"£"}};"undefined"!=typeof module&&module.exports&&(module.exports=e),"undefined"!=typeof window&&this.numeral&&this.numeral.language&&this.numeral.language("en-gb",e)}(),function(){var e={delimiters:{thousands:".",decimal:","},abbreviations:{thousand:"k",million:"mm",billion:"b",trillion:"t"},ordinal:function(e){var n=e%10;return 1===n||3===n?"er":2===n?"do":7===n||0===n?"mo":8===n?"vo":9===n?"no":"to"},currency:{symbol:"€"}};"undefined"!=typeof module&&module.exports&&(module.exports=e),"undefined"!=typeof window&&this.numeral&&this.numeral.language&&this.numeral.language("es",e)}(),function(){var e={delimiters:{thousands:".",decimal:","},abbreviations:{thousand:"k",million:"mm",billion:"b",trillion:"t"},ordinal:function(e){var n=e%10;return 1===n||3===n?"er":2===n?"do":7===n||0===n?"mo":8===n?"vo":9===n?"no":"to"},currency:{symbol:"$"}};"undefined"!=typeof module&&module.exports&&(module.exports=e),"undefined"!=typeof window&&this.numeral&&this.numeral.language&&this.numeral.language("es",e)}(),function(){var e={delimiters:{thousands:" ",decimal:","},abbreviations:{thousand:" tuh",million:" mln",billion:" mld",trillion:" trl"},ordinal:function(){return"."},currency:{symbol:"€"}};"undefined"!=typeof module&&module.exports&&(module.exports=e),"undefined"!=typeof window&&this.numeral&&this.numeral.language&&this.numeral.language("et",e)}(),function(){var e={delimiters:{thousands:" ",decimal:","},abbreviations:{thousand:"k",million:"M",billion:"G",trillion:"T"},ordinal:function(){return"."},currency:{symbol:"€"}};"undefined"!=typeof module&&module.exports&&(module.exports=e),"undefined"!=typeof window&&this.numeral&&this.numeral.language&&this.numeral.language("fi",e)}(),function(){var e={delimiters:{thousands:" ",decimal:","},abbreviations:{thousand:"k",million:"M",billion:"G",trillion:"T"},ordinal:function(e){return 1===e?"er":"e"},currency:{symbol:"$"}};"undefined"!=typeof module&&module.exports&&(module.exports=e),"undefined"!=typeof window&&this.numeral&&this.numeral.language&&this.numeral.language("fr-CA",e)}(),function(){var e={delimiters:{thousands:"'",decimal:"."},abbreviations:{thousand:"k",million:"m",billion:"b",trillion:"t"},ordinal:function(e){return 1===e?"er":"e"},currency:{symbol:"CHF"}};"undefined"!=typeof module&&module.exports&&(module.exports=e),"undefined"!=typeof window&&this.numeral&&this.numeral.language&&this.numeral.language("fr-ch",e)}(),function(){var e={delimiters:{thousands:" ",decimal:","},abbreviations:{thousand:"k",million:"m",billion:"b",trillion:"t"},ordinal:function(e){return 1===e?"er":"e"},currency:{symbol:"€"}};"undefined"!=typeof module&&module.exports&&(module.exports=e),"undefined"!=typeof window&&this.numeral&&this.numeral.language&&this.numeral.language("fr",e)}(),function(){var e={delimiters:{thousands:" ",decimal:","},abbreviations:{thousand:"E",million:"M",billion:"Mrd",trillion:"T"},ordinal:function(){return"."},currency:{symbol:" Ft"}};"undefined"!=typeof module&&module.exports&&(module.exports=e),"undefined"!=typeof window&&this.numeral&&this.numeral.language&&this.numeral.language("hu",e)}(),function(){var e={delimiters:{thousands:".",decimal:","},abbreviations:{thousand:"mila",million:"mil",billion:"b",trillion:"t"},ordinal:function(){return"º"},currency:{symbol:"€"}};"undefined"!=typeof module&&module.exports&&(module.exports=e),"undefined"!=typeof window&&this.numeral&&this.numeral.language&&this.numeral.language("it",e)}(),function(){var e={delimiters:{thousands:",",decimal:"."},abbreviations:{thousand:"千",million:"百万",billion:"十億",trillion:"兆"},ordinal:function(){return"."},currency:{symbol:"¥"}};"undefined"!=typeof module&&module.exports&&(module.exports=e),"undefined"!=typeof window&&this.numeral&&this.numeral.language&&this.numeral.language("ja",e)}(),function(){var e={delimiters:{thousands:" ",decimal:","},abbreviations:{thousand:" tūkst.",million:" milj.",billion:" mljrd.",trillion:" trilj."},ordinal:function(){return"."},currency:{symbol:"€"}};"undefined"!=typeof module&&module.exports&&(module.exports=e),"undefined"!=typeof window&&this.numeral&&this.numeral.language&&this.numeral.language("lv",e)}(),function(){var e={delimiters:{thousands:".",decimal:","},abbreviations:{thousand:"k",million:"mln",billion:"mrd",trillion:"bln"},ordinal:function(e){var n=e%100;return 0!==e&&1>=n||8===n||n>=20?"ste":"de"},currency:{symbol:"€ "}};"undefined"!=typeof module&&module.exports&&(module.exports=e),"undefined"!=typeof window&&this.numeral&&this.numeral.language&&this.numeral.language("nl-nl",e)}(),function(){var e={delimiters:{thousands:" ",decimal:","},abbreviations:{thousand:"tys.",million:"mln",billion:"mld",trillion:"bln"},ordinal:function(){return"."},currency:{symbol:"PLN"}};"undefined"!=typeof module&&module.exports&&(module.exports=e),"undefined"!=typeof window&&this.numeral&&this.numeral.language&&this.numeral.language("pl",e)}(),function(){var e={delimiters:{thousands:".",decimal:","},abbreviations:{thousand:"mil",million:"milhões",billion:"b",trillion:"t"},ordinal:function(){return"º"},currency:{symbol:"R$"}};"undefined"!=typeof module&&module.exports&&(module.exports=e),"undefined"!=typeof window&&this.numeral&&this.numeral.language&&this.numeral.language("pt-br",e)}(),function(){var e={delimiters:{thousands:" ",decimal:","},abbreviations:{thousand:"k",million:"m",billion:"b",trillion:"t"},ordinal:function(){return"º"},currency:{symbol:"€"}};"undefined"!=typeof module&&module.exports&&(module.exports=e),"undefined"!=typeof window&&this.numeral&&this.numeral.language&&this.numeral.language("pt-pt",e)}(),function(){var e={delimiters:{thousands:" ",decimal:","},abbreviations:{thousand:"тыс.",million:"млн",billion:"b",trillion:"t"},ordinal:function(){return"."},currency:{symbol:"₴"}};"undefined"!=typeof module&&module.exports&&(module.exports=e),"undefined"!=typeof window&&this.numeral&&this.numeral.language&&this.numeral.language("ru-UA",e)}(),function(){var e={delimiters:{thousands:" ",decimal:","},abbreviations:{thousand:"тыс.",million:"млн",billion:"b",trillion:"t"},ordinal:function(){return"."},currency:{symbol:"руб."}};"undefined"!=typeof module&&module.exports&&(module.exports=e),"undefined"!=typeof window&&this.numeral&&this.numeral.language&&this.numeral.language("ru",e)}(),function(){var e={delimiters:{thousands:" ",decimal:","},abbreviations:{thousand:"tis.",million:"mil.",billion:"b",trillion:"t"},ordinal:function(){return"."},currency:{symbol:"€"}};"undefined"!=typeof module&&module.exports&&(module.exports=e),"undefined"!=typeof window&&this.numeral&&this.numeral.language&&this.numeral.language("sk",e)}(),function(){var e={delimiters:{thousands:",",decimal:"."},abbreviations:{thousand:"พัน",million:"ล้าน",billion:"พันล้าน",trillion:"ล้านล้าน"},ordinal:function(){return"."},currency:{symbol:"฿"}};"undefined"!=typeof module&&module.exports&&(module.exports=e),"undefined"!=typeof window&&this.numeral&&this.numeral.language&&this.numeral.language("th",e)}(),function(){var e={1:"'inci",5:"'inci",8:"'inci",70:"'inci",80:"'inci",2:"'nci",7:"'nci",20:"'nci",50:"'nci",3:"'üncü",4:"'üncü",100:"'üncü",6:"'ncı",9:"'uncu",10:"'uncu",30:"'uncu",60:"'ıncı",90:"'ıncı"},n={delimiters:{thousands:".",decimal:","},abbreviations:{thousand:"bin",million:"milyon",billion:"milyar",trillion:"trilyon"},ordinal:function(n){if(0===n)return"'ıncı";var i=n%10,t=n%100-i,l=n>=100?100:null;return e[i]||e[t]||e[l]},currency:{symbol:"₺"}};"undefined"!=typeof module&&module.exports&&(module.exports=n),"undefined"!=typeof window&&this.numeral&&this.numeral.language&&this.numeral.language("tr",n)}(),function(){var e={delimiters:{thousands:" ",decimal:","},abbreviations:{thousand:"тис.",million:"млн",billion:"млрд",trillion:"блн"},ordinal:function(){return""},currency:{symbol:"₴"}};"undefined"!=typeof module&&module.exports&&(module.exports=e),"undefined"!=typeof window&&this.numeral&&this.numeral.language&&this.numeral.language("uk-UA",e)}()}.call(this),function(){e.isClient&&(n=window.numeral,delete window.numeral),e.isServer&&(n=Npm.require("numeral"))}.call(this),"undefined"==typeof Package&&(Package={}),Package["numeral:numeral"]={numeral:n}}();
+
+!function(){var e=Package.meteor.Meteor,a=Package["3stack:bignumber"].BigNumber,i;(function(){i={},i.fromWei=function(e,i){if(!e)return e;switch("string"==typeof e&&0===e.indexOf("0x")&&(e=web3.toDecimal(e)),e instanceof a||(e=new a(e.toString())),i=i.toLowerCase()){case"kwei":case"ada":e=e.dividedBy(1e3);break;case"mwei":case"babbage":e=e.dividedBy(1e6);break;case"gwei":case"schannon":e=e.dividedBy(1e9);break;case"szabo":e=e.dividedBy(1e12);break;case"finney":e=e.dividedBy(1e15);break;case"ether":e=e.dividedBy(1e18);break;case"kether":case"grand":case"einstein":e=e.dividedBy(1e21);break;case"mether":e=e.dividedBy(1e24);break;case"gether":e=e.dividedBy(1e27);break;case"tether":e=e.dividedBy(1e30)}return e.toNumber()},i.toWei=function(e,i){if(!e)return e;switch("string"==typeof e&&0===e.indexOf("0x")&&(e=web3.toDecimal(e)),e instanceof a||(e=new a(e.toString())),i=i.toLowerCase()){case"kwei":case"ada":e=e.times(1e3);break;case"mwei":case"babbage":e=e.times(1e6);break;case"gwei":case"schannon":e=e.times(1e9);break;case"szabo":e=e.times(1e12);break;case"finney":e=e.times(1e15);break;case"ether":e=e.times(1e18);break;case"kether":case"grand":case"einstein":e=e.times(1e21);break;case"mether":e=e.times(1e24);break;case"gether":e=e.times(1e27);break;case"tether":e=e.times(1e30)}return e.toNumber()},i.isAddress=function(e){return 0===e.indexOf("0x")&&42!=e.length?!1:-1===e.indexOf("0x")&&40!=e.length?!1:/^\w+$/.test(e)}}).call(this),"undefined"==typeof Package&&(Package={}),Package["ethereum:tools"]={EthTools:i}}();
+
+!function(){var e=Package.meteor.Meteor;(function(){!function(){function e(e){c=0;for(var t=0;t<e.length;t+=2){var r=e.charCodeAt(t)<<8|e.charCodeAt(t+1);c^=r}}function t(){var e=(Math.sin(c++)+1)/2,t=1e4*e;return e=t-Math.floor(t)}function r(){var e=Math.floor(360*t()),r=50*t()+50+"%",a=60*t()+20+"%",n="hsl("+e+","+r+","+a+")";return n}function a(e){for(var r=e,a=e,n=Math.ceil(r/2),o=r-n,c=[],i=0;a>i;i++){for(var l=[],f=0;n>f;f++)l[f]=t()>=.5;var h=l.slice(0,o);h.reverse(),l=l.concat(h);for(var s=0;s<l.length;s++)c.push(l[s])}return c}function n(e,t,r,a){var n=document.createElement("canvas"),o=Math.sqrt(e.length);n.width=n.height=o*r;var c=n.getContext("2d");c.fillStyle=a,c.fillRect(0,0,n.width,n.height),c.fillStyle=t;for(var i=0;i<e.length;i++){var l=Math.floor(i/o),f=i%o;e[i]&&c.fillRect(f*r,l*r,r,r)}return n}function o(t){t=t||{};var o=t.size||10,c=t.scale||5,i=t.seed||Math.random().toString(36).substr(2),l=t.bgcolor||"#fff";e(i);var f=t.color||r(),h=a(o),s=n(h,f,c,l);return s}var c=0;window.blockies={create:o}}()}).call(this),function(){"use strict";Package.templating&&Package.templating.Template.registerHelper("identicon",function(e,t){return t=t&&t.hash||{},e&&(t.seed=e),blockies.create(t).toDataURL()})}.call(this),"undefined"==typeof Package&&(Package={}),Package["mistereo:identicon"]={}}();
+
+!function(){var e=Package.meteor.Meteor,a=Package.underscore._,n=Package.jquery.$,t=Package.jquery.jQuery,c=Package.templating.Template,o=Package["ethereum:tools"].EthTools,r=Package["frozeman:template-var"].TemplateVar,u=Package.blaze.Blaze,l=Package.blaze.UI,s=Package.blaze.Handlebars,i=Package.htmljs.HTML;(function(){c.__checkName("dapp_identicon"),c.dapp_identicon=new c("Template.dapp_identicon",function(){var e=this;return u.If(function(){return Spacebars.call(e.lookup("identity"))},function(){return["\n ",i.A({href:function(){return Spacebars.mustache(e.lookup("pathFor"),Spacebars.kw({route:"userProfile",userId:e.lookup("identity")}))},"class":function(){return["dapp-identicon ",Spacebars.mustache(e.lookup("class"))]},style:function(){return["background-image: url('",Spacebars.mustache(e.lookup("identicon"),e.lookup("identity"),Spacebars.kw({size:8,scale:8,bgcolor:"#424343"})),"')"]}}),"\n "]})})}).call(this),function(){c.dapp_identicon.helpers({})}.call(this),function(){c.__checkName("dapp_addressInput"),c.dapp_addressInput=new c("Template.dapp_addressInput",function(){var e=this;return i.DIV({"class":"dapp-address-input"},"\n ",i.INPUT({type:"text",name:"to",placeholder:function(){return Spacebars.mustache(e.lookup("placeholder"))},"class":function(){return[Spacebars.mustache(e.lookup("class"))," ",u.Unless(function(){return Spacebars.call(e.lookup("isValid"))},function(){return"dapp-error"})]},autofocus:"true",value:function(){return Spacebars.mustache(e.lookup("value"))}}),"\n ",u.If(function(){return Spacebars.call(e.lookup("isValid"))},function(){return["\n ",u._TemplateWith(function(){return{identity:Spacebars.call(e.lookup("address")),"class":Spacebars.call("dapp-small")}},function(){return Spacebars.include(e.lookupTemplate("dapp_identicon"))}),"\n "]},function(){return["\n ",i.I({"class":"icon-shield"}),"\n "]}),"\n ")})}.call(this),function(){c.dapp_addressInput.created=function(){r.set("isValid",!0),this.data.value&&r.set("address",this.data.value)},c.dapp_addressInput.helpers({address:function(){var e=r.get("address");return a.isString(e)?e.replace("0x",""):""},isValid:function(){return r.get("isValid")}}),c.dapp_addressInput.events({'input input[name="to"], change input[name="to"]':function(e){o.isAddress(e.currentTarget.value)||a.isEmpty(e.currentTarget.value)?r.set("isValid",!0):r.set("isValid",!1),r.set("address",e.currentTarget.value)},"click a":function(e){e.preventDefault()}})}.call(this),function(){c.__checkName("dapp_modal"),c.dapp_modal=new c("Template.dapp_modal",function(){var e=this;return Spacebars.include(e.lookupTemplate("Animate"),function(){return["\n ",i.DIV({"class":"dapp-modal-overlay animate"},"\n ",i.SECTION({"class":"dapp-modal-container"},"\n ",u.If(function(){return Spacebars.call(e.lookup("yield"))},function(){return["\n ",u._TemplateWith(function(){return{region:Spacebars.call("modalContent")}},function(){return Spacebars.include(e.lookupTemplate("yield"))}),"\n "]}),"\n "),"\n "),"\n "]})})}.call(this),function(){c.dapp_modal.created=function(){n("body").addClass("disable-scroll blur")},c.dapp_modal.destroyed=function(){n("body").removeClass("disable-scroll blur")},c.dapp_modal.events({"click .dapp-modal-overlay":function(e){n(e.target).hasClass("dapp-modal-overlay")&&"undefined"!=typeof Router&&(this.closePath?Router.go(this.closePath):Router.current().render(null,{to:"modal"}))}})}.call(this),function(){c.__checkName("dapp_modal_question"),c.dapp_modal_question=new c("Template.dapp_modal_question",function(){var e=this;return[i.P(u.View(function(){return Spacebars.mustache(e.lookup("text"))})),"\n ",i.DIV({"class":"dapp-modal-buttons"},"\n ",u.If(function(){return Spacebars.call(e.lookup("hasCancel"))},function(){return["\n ",i.BUTTON({"class":"cancel"},u.View(function(){return Spacebars.mustache(e.lookup("i18nText"),"cancel")})),"\n "]}),"\n ",u.If(function(){return Spacebars.call(e.lookup("hasOk"))},function(){return["\n ",i.BUTTON({"class":"ok dapp-primary-button"},u.View(function(){return Spacebars.mustache(e.lookup("i18nText"),"ok")})),"\n "]}),"\n ")]})}.call(this),function(){c.dapp_modal_question.helpers({hasOk:function(){return this.ok},hasCancel:function(){return this.cancel},i18nText:function(e){return"undefined"==typeof TAPi18n?"ok"===e?"OK":"Cancel":TAPi18n.__("buttons."+e)}}),c.dapp_modal_question.events({"click button.ok":function(e){a.isFunction(this.ok)&&this.ok(),Router.current().render(null,{to:"modal"})},"click button.cancel":function(e){a.isFunction(this.cancel)&&this.cancel(),Router.current().render(null,{to:"modal"})}})}.call(this),"undefined"==typeof Package&&(Package={}),Package["ethereum:elements"]={}}();
+
+!function(){var e=Package.meteor.Meteor,t=Package.underscore._,n=Package.ejson.EJSON,r;(function(){if(Package["cmather:iron-core"])throw new Error("\n\n Sorry! The cmather:iron-{x} packages were migrated to the new package system with the wrong name, and you have duplicate copies.\n You can see which cmather:iron-{x} packages have been installed by using this command:\n\n > meteor list\n\n Can you remove any installed cmather:iron-{x} packages like this: \n\n > meteor remove cmather:iron-core\n > meteor remove cmather:iron-router\n > meteor remove cmather:iron-dynamic-template\n > meteor remove cmather:iron-dynamic-layout\n \n The new packages are named iron:{x}. For example:\n\n > meteor add iron:router\n\n Sorry for the hassle, but thank you! \n\n ")}).call(this),function(){r={},r.utils={},r.utils.assert=function(e,t){if(!e)throw new Error(t)},r.utils.warn=function(e,t){e||console&&console.warn&&console.warn(t)},r.utils.defaultValue=function(e,t,n){return"undefined"==typeof e[t]?(e[t]=n,n):e[t]},r.utils.inherits=function(e,o,i){r.utils.assert("undefined"!=typeof e,"Child is undefined in inherits function"),r.utils.assert("undefined"!=typeof o,"Parent is undefined in inherits function");for(var a in o)t.has(o,a)&&(e[a]=n.clone(o[a]));var s=function(){this.constructor=e};return s.prototype=o.prototype,e.prototype=new s,e.__super__=o.prototype,t.isObject(i)&&t.extend(e.prototype,i),e},r.utils.extend=function(e,n){n=n||{};var o=function(){var e;e=t.has(n,"constructor")?n.constructor:o.__super__.constructor,e.apply(this,arguments)};return r.utils.inherits(o,e,n)},r.utils.global=function(){return e.isClient?window:global}(),r.utils.namespace=function(e,t){var n=r.utils.global,o,i,a,s;r.utils.assert("string"==typeof e,"namespace must be a string"),o=e.split("."),a=o.pop(),s=n;for(var u=0;u<o.length;u++)i=o[u],s=s[i]=s[i]||{};return 2===arguments.length?(s[a]=t,t):s[a]},r.utils.resolve=function(e){var t=r.utils.global,n,o;if("string"==typeof e){n=e.split("."),o=t;for(var i=0;i<n.length;i++)if(o=o[n[i]],!o)return void 0}else o=e;return o},r.utils.capitalize=function(e){return e.charAt(0).toUpperCase()+e.slice(1,e.length)},r.utils.classCase=function(e){var n=/_|-|\.|\//;return e?t.map(e.split(n),function(e){return r.utils.capitalize(e)}).join(""):""},r.utils.camelCase=function(e){var t=r.utils.classCase(e);return t=t.charAt(0).toLowerCase()+t.slice(1,t.length)},r.utils.notifyDeprecated=function(e){var n,r,o,i,a="[:where] ':name' is deprecated. Please use ':instead' instead.";t.isObject(e)?(n=e.name,r=e.instead,o=e.message||a,i=e.where||"IronRouter"):(o=e,n="",r="",i=""),"undefined"!=typeof console&&console.warn&&console.warn("<deprecated> "+o.replace(":name",n).replace(":instead",r).replace(":where",i)+" "+(new Error).stack)},r.utils.withDeprecatedNotice=function(e,t,n){return function(){return Utils.notifyDeprecated(e),t&&t.apply(n||this,arguments)}},Function.prototype.deprecate=function(e){var t=this;return r.utils.withDeprecatedNotice(e,t)},r.utils.debug=function(e){return r.utils.assert("string"==typeof e,"debug requires a package name"),function n(){if(console&&console.log&&r.debug===!0){var n=t.toArray(arguments).join(" ");console.log("%c<"+e+"> %c"+n,"color: #999;","color: #000;")}}},r.utils.get=function(e){for(var t=1;t<arguments.length;t++){if(!(e&&arguments[t]in e))return void 0;e=e[arguments[t]]}return e},r.utils.global.Iron=r}.call(this),"undefined"==typeof Package&&(Package={}),Package["iron:core"]={Iron:r}}();
+
+!function(){var e=Package.meteor.Meteor,t=Package.ui.Blaze,n=Package.ui.UI,a=Package.ui.Handlebars,r=Package.underscore._,i=Package.jquery.$,o=Package.jquery.jQuery,s=Package.tracker.Tracker,u=Package.tracker.Deps,c=Package["reactive-var"].ReactiveVar,l=Package.templating.Template,p=Package.random.Random,h=Package["iron:core"].Iron,d=Package.htmljs.HTML,m;(function(){if(Package["cmather:iron-dynamic-template"])throw new Error("\n\n Sorry! The cmather:iron-{x} packages were migrated to the new package system with the wrong name, and you have duplicate copies.\n You can see which cmather:iron-{x} packages have been installed by using this command:\n\n > meteor list\n\n Can you remove any installed cmather:iron-{x} packages like this: \n\n > meteor remove cmather:iron-core\n > meteor remove cmather:iron-router\n > meteor remove cmather:iron-dynamic-template\n > meteor remove cmather:iron-dynamic-layout\n \n The new packages are named iron:{x}. For example:\n\n > meteor add iron:router\n\n Sorry for the hassle, but thank you! \n\n ")}).call(this),function(){l.__checkName("__DynamicTemplateError__"),l.__DynamicTemplateError__=new l("Template.__DynamicTemplateError__",function(){var e=this;return d.DIV({style:"margin: 0 auto; color: red;"},"\n ",t.View(function(){return Spacebars.mustache(e.lookup("msg"))}),"\n ")})}.call(this),function(){var e=h.utils.debug("iron:dynamic-template"),a=h.utils.assert,o=h.utils.get,d=h.utils.camelCase,f=function(e){return Object.prototype.toString.call(e)};m=function(e){this._id=p.id(),this.options=e=e||{},this._template=e.template,this._defaultTemplate=e.defaultTemplate,this._content=e.content,this._data=e.data,this._templateDep=new s.Dependency,this._dataDep=new s.Dependency,this._lookupHostDep=new s.Dependency,this._lookupHostValue=null,this._hooks={},this._eventMap=null,this._eventHandles=null,this._eventThisArg=null,this.name=e.name||this.constructor.prototype.name||"DynamicTemplate",this.isCreated=!1,this.isDestroyed=!1},m.prototype.template=function(e){if(1===arguments.length&&e!==this._template)return this._template=e,void this._templateDep.changed();if(!(arguments.length>0))return this._templateDep.depend(),this._template?"function"==typeof this._template?this._template():this._template:this._defaultTemplate?"function"==typeof this._defaultTemplate?this._defaultTemplate():this._defaultTemplate:void 0},m.prototype.defaultTemplate=function(e){return 1!==arguments.length?this._defaultTemplate:void(this._defaultTemplate=e)},m.prototype.clear=function(){this._template=void 0,this._data=void 0,this._templateDep.changed()},m.prototype.data=function(e){return 1===arguments.length&&e!==this._data?(this._data=e,void this._dataDep.changed()):(this._dataDep.depend(),"function"==typeof this._data?this._data():this._data)},m.prototype.create=function(e){var n=this;if(this.isCreated)throw new Error("DynamicTemplate view is already created");this.isCreated=!0,this.isDestroyed=!1;var a=c(null),i=t.View("DynamicTemplate",function(){var e=this,r=a.get();return t.With(function(){var t=n.data();return"undefined"!=typeof t?t:m.getParentDataContext(e)},function(){return n.renderView(r)})});return i.onViewCreated(function(){this.autorun(function(){a.set(n.template())})}),r.each(["onViewCreated","onViewReady","_onViewRendered","onViewDestroyed"],function(e){i[e](function(){n._runHooks(e,this)})}),i._onViewRendered(function(){n.isInserted=!0,1===i.renderCount&&n._attachEvents()}),i.onViewDestroyed(function(){n._detachEvents()}),i._templateInstance=new t.TemplateInstance(i),i.templateInstance=function(){var e=i._templateInstance;return e.data=t.getData(i),i._domrange&&!i.isDestroyed?(e.firstNode=i._domrange.firstNode(),e.lastNode=i._domrange.lastNode()):(e.firstNode=null,e.lastNode=null),e},this.view=i,i.__dynamicTemplate__=this,i.name=this.name,i},m.prototype.renderView=function(e){var n=this,a=null;return"string"==typeof e?(a=l[e],a||(a=l[d(e)]),a||(a=t.With({msg:"Couldn't find a template named "+JSON.stringify(e)+" or "+JSON.stringify(d(e))+". Are you sure you defined it?"},function(){return l.__DynamicTemplateError__}))):"[object Object]"===f(e)?a=e:"undefined"!=typeof n._content&&(a=n._content),a},m.prototype.destroy=function(){this.isCreated&&(t.remove(this.view),this.view=null,this.isDestroyed=!0,this.isCreated=!1)},r.each(["onViewCreated","onViewReady","_onViewRendered","onViewDestroyed"],function(e){m.prototype[e]=function(t){var n=this._hooks[e]=this._hooks[e]||[];return n.push(t),this}}),m.prototype._runHooks=function(e,t){for(var n=this._hooks[e]||[],a,r=0;r<n.length;r++)a=n[r],a.call(t,this)},m.prototype.events=function(e,n){var a=this;this._detachEvents(),this._eventThisArg=n;var r=this._eventMap={};for(var i in e)r[i]=function(e,r){return function(e){var i=t.getData(e.currentTarget);null==i&&(i={});var o=a.view.templateInstance();return r.call(n||this,e,o,i)}}(i,e[i]);this._attachEvents()},m.prototype._attachEvents=function(){var e=this,n=e._eventThisArg,a=e._eventMap,i=e.view,o=e._eventHandles;if(i){var s=i._domrange;if(!s)throw new Error("no domrange");var u=function(n,s){r.each(a,function(a,u){var c=u.split(/,\s+/);r.each(c,function(r){var u=r.split(/\s+/);if(0!==u.length){var c=u.shift(),l=u.join(" ");o.push(t._EventSupport.listen(s,c,l,function(r){if(!n.containsElement(r.currentTarget))return null;var o=e._eventThisArg||this,s=arguments;return t._withCurrentView(i,function(){return a.apply(o,s)})},n,function(e){return e.parentRange}))}})})};s.attached?u(s,s.parentElement):s.onAttached(u)}},m.prototype._detachEvents=function(){r.each(this._eventHandles,function(e){e.stop()}),this._eventHandles=[]};var _=function(e,n,a,i){r.each(a,function(a,o){var s=o.split(/,\s+/);r.each(s,function(r){var o=r.split(/\s+/);if(0!==o.length){var s=o.shift(),u=o.join(" ");handles.push(t._EventSupport.listen(n,s,u,function(n){if(!e.containsElement(n.currentTarget))return null;var r=i||this,o=arguments;return t._withCurrentView(view,function(){return a.apply(r,o)})},e,function(e){return e.parentRange}))}})})};m.prototype.insert=function(e){if(e=e||{},!this.isInserted){this.isInserted=!0;var n=e.el||document.body,a=i(n);if(0===a.length)throw new Error("No element to insert layout into. Is your element defined? Try a Meteor.startup callback.");return this.view||this.create(e),t.render(this.view,a[0],e.nextNode,e.parentView),this}},m.prototype._getLookupHost=function(){return this._lookupHostValue},m.prototype._setLookupHost=function(e){var t=this;return t._lookupHostValue!==e&&(t._lookupHostValue=e,u.afterFlush(function(){t._lookupHostDep.changed()})),this},m.getParentDataContext=function(e){return m.getDataContext(e&&e.parentView)},m.getDataContext=function(e){for(;e;){if("with"===e.name&&!e.__isTemplateWith)return e.dataVar.get();e=e.parentView}return null},m.getInclusionArguments=function(e){var t=e&&e.parentView;return t&&t.__isTemplateWith?t.dataVar.get():null},m.args=function(e){return function(t){var n=m.getInclusionArguments(e);return n?t?n[t]:n:null}},m.extend=function(e){return h.utils.extend(this,e)},m.findFirstLookupHost=function(e){var n,r;for(a(e instanceof t.View,"view must be a Blaze.View");e;)if(e.__dynamicTemplate__){var n=e.__dynamicTemplate__._getLookupHost();if(n)return n}else e=e.parentView;return void 0},m.findLookupHostWithProperty=function(e,n){var r,i;for(a(e instanceof t.View,"view must be a Blaze.View");e;){if(e.__dynamicTemplate__){var r=e.__dynamicTemplate__._getLookupHost();if(r&&o(r,n))return r}e=e.parentView}return void 0},m.findLookupHostWithHelper=function(e,n){var r,i;for(a(e instanceof t.View,"view must be a Blaze.View");e;){if(e.__dynamicTemplate__){var r=e.__dynamicTemplate__._getLookupHost();if(r&&o(r,"constructor","_helpers",n))return r}e=e.parentView}return void 0},"undefined"!=typeof l&&n.registerHelper("DynamicTemplate",new l("DynamicTemplateHelper",function(){var e=m.args(this);return new m({data:function(){return e("data")},template:function(){return e("template")},content:this.templateContentBlock}).create()})),h.DynamicTemplate=m}.call(this),function(){var e=h.utils.assert,n=h.utils.get,a=t.View.prototype.lookup;t.View.prototype.lookup=function(e){var r;return r=m.findLookupHostWithHelper(t.getView(),e),r?function i(){var t=n(r,"constructor","_helpers",e),a=[].slice.call(arguments);return"function"==typeof t?t.apply(r,a):t}:a.apply(this,arguments)}}.call(this),"undefined"==typeof Package&&(Package={}),Package["iron:dynamic-template"]={}}();
+
+!function(){var e=Package.meteor.Meteor,n=Package.templating.Template,t=Package.blaze.Blaze,r=Package.blaze.UI,o=Package.blaze.Handlebars,i=Package.underscore._,a=Package["iron:core"].Iron,s=Package.htmljs.HTML,c,u,h;(function(){var e=[];if(Package["cmather:iron-layout"]&&e.push("\n\n The cmather:iron-{x} packages were migrated to the new package system with the wrong name, and you have duplicate copies.\n You can see which cmather:iron-{x} packages have been installed by using this command:\n\n > meteor list\n\n Can you remove any installed cmather:iron-{x} packages like this: \n\n > meteor remove cmather:iron-core\n > meteor remove cmather:iron-router\n > meteor remove cmather:iron-dynamic-template\n > meteor remove cmather:iron-dynamic-layout\n \n The new packages are named iron:{x}. For example:\n\n > meteor add iron:router\n\n Sorry for the hassle, but thank you! \n\n "),Package["cmather:blaze-layout"]&&e.push("The blaze-layout package has been replaced by iron-layout. Please remove the package like this:\n> meteor remove cmather:blaze-layout\n"),e.length>0)throw new Error("Sorry! Looks like there's a few errors related to iron:layout\n\n"+e.join("\n\n"))}).call(this),function(){n.__checkName("__IronDefaultLayout__"),n.__IronDefaultLayout__=new n("Template.__IronDefaultLayout__",function(){var e=this;return Spacebars.include(e.lookupTemplate("yield"))})}.call(this),function(){var e=a.DynamicTemplate,o=a.utils.inherits;c=function(e){for(;e;){if("Iron.Layout"===e.name)return e.__dynamicTemplate__;e=e.parentView}return null},u=function(e){var n=this;u.__super__.constructor.apply(this,arguments),e=e||{},this.name="Iron.Layout",this._regions={},this._regionHooks={},this.defaultTemplate("__IronDefaultLayout__"),e.content&&this.render(e.content)},h=u.DEFAULT_REGION="main",o(u,a.DynamicTemplate),u.prototype.region=function(e,n){return this._ensureRegion(e,n)},u.prototype.destroyRegions=function(){i.each(this._regions,function(e){e.destroy()}),this._regions={}},u.prototype.render=function(e,n){n=n||{};var t=n.to||n.region||h,r=this.region(t);return this._trackRenderedRegion(t),r.template(e),r.data(n.data),r},u.prototype.has=function(e){return e=e||u.DEFAULT_REGION,!!this._regions[e]},u.prototype.regionKeys=function(){return i.keys(this._regions)},u.prototype.clear=function(e){return e=e||u.DEFAULT_REGION,this.has(e)&&this.region(e).template(null),this},u.prototype.clearAll=function(){return i.each(this._regions,function(e){e.template(null)}),this},u.prototype.beginRendering=function(e){var n=this;if(this._finishRenderingTransaction&&this._finishRenderingTransaction(),this._finishRenderingTransaction=i.once(function(){var t=n._endRendering({flush:!1});e&&e(t)}),Deps.afterFlush(this._finishRenderingTransaction),this._renderedRegions)throw new Error("You called beginRendering again before calling endRendering");this._renderedRegions={}},u.prototype._trackRenderedRegion=function(e){this._renderedRegions&&(this._renderedRegions[e]=!0)},u.prototype._endRendering=function(e){e=e||{},e.flush!==!1&&Deps.flush();var n=this._renderedRegions||{};return this._renderedRegions=null,i.keys(n)},i.each(["onRegionCreated","onRegionRendered","onRegionDestroyed"],function(e){u.prototype[e]=function(n){var t=this._regionHooks[e]=this._regionHooks[e]||[];return t.push(n),this}}),u.prototype._ensureRegion=function(e,n){return this._regions[e]=this._regions[e]||this._createDynamicTemplate(e,n)},u.prototype._createDynamicTemplate=function(e,n){var t=this,r=new a.DynamicTemplate(n),o=a.utils.capitalize;return r._region=e,i.each(["viewCreated","viewReady","viewDestroyed"],function(e){e=o(e),r["on"+e](function(n){var r=this,o={viewCreated:"regionCreated",viewReady:"regionRendered",viewDestroyed:"regionDestroyed"}[e];t._runRegionHooks("on"+o,r,n)})}),r},u.prototype._runRegionHooks=function(e,n,t){for(var r=this,o=this._regionHooks[e]||[],i,a=0;a<o.length;a++)i=o[a],i.call(n,t.region,t,this)},"undefined"!=typeof n&&(r.registerHelper("yield",new n("yield",function(){var n=c(this);if(!n)throw new Error("No Iron.Layout found so you can't use yield!");var t=e.getInclusionArguments(this),r,o;return i.isString(t)?r=t:i.isObject(t)&&(r=t.region),r=r||h,o=n.region(r),o.isCreated&&o.destroy(),o.create()})),r.registerHelper("contentFor",new n("contentFor",function(){var n=c(this);if(!n)throw new Error("No Iron.Layout found so you can't use contentFor!");var t=e.getInclusionArguments(this)||{},r=this.templateContentBlock,o=t.template,a=t.data,s;if(i.isString(t))s=t;else{if(!i.isObject(t))throw new Error("Which region is this contentFor block supposed to be for?");s=t.region}return n.region(s).template(o||r),n._trackRenderedRegion(s),a&&n.region(s).data(a),null})),r.registerHelper("hasRegion",function(e){var n=c(t.getView());if(!n)throw new Error("No Iron.Layout found so you can't use hasRegion!");if(!i.isString(e))throw new Error("You need to provide an region argument to hasRegion");return!!n.region(e).template()}),r.registerHelper("Layout",new n("layout",function(){var e=a.DynamicTemplate.args(this),n=new u({template:function(){return e("template")},data:function(){return e("data")},content:this.templateContentBlock});return n.create()}))),a.Layout=u}.call(this),"undefined"==typeof Package&&(Package={}),Package["iron:layout"]={}}();
+
+!function(){var e=Package.meteor.Meteor,r=Package.underscore._,n=Package["iron:core"].Iron,t,i;(function(){function e(e){return e.replace(/([=!:$\/()])/g,"\\$1")}function r(t,a,s){a&&"[object Array]"!==n(a)&&(s=a,a=null),a=a||[],s=s||{};var c=s.strict,u=s.end!==!1,p=s.sensitive?"":"i",h=0;if(t instanceof RegExp){var l=t.source.match(/\((?!\?)/g)||[];return a.push.apply(a,l.map(function(e,r){return{name:r,delimiter:null,optional:!1,repeat:!1}})),o(t,a)}if("[object Array]"===n(t))return t=t.map(function(e){return r(e,a,s).source}),o(new RegExp("(?:"+t.join("|")+")",p),a);t=t.replace(i,function(r,n,t,i,o,s,c,u){if(n)return n;if(u)return"\\"+u;var p="+"===c||"*"===c,l="?"===c||"*"===c;return a.push({name:i||h++,delimiter:t||"/",optional:l,repeat:p}),t=t?"\\"+t:"",o=e(o||s||"[^"+(t||"\\/")+"]+?"),p&&(o=o+"(?:"+t+o+")*"),l?"(?:"+t+"("+o+"))?":t+"("+o+")"});var f="/"===t[t.length-1];return c||(t=(f?t.slice(0,-2):t)+"(?:\\/(?=$))?"),u||(t+=c&&f?"":"(?=\\/|$)"),o(new RegExp("^"+t+(u?"$":""),p),a)}var n=function(e){return Object.prototype.toString.call(e)},i=new RegExp(["(\\\\.)","([\\/.])?(?:\\:(\\w+)(?:\\(((?:\\\\.|[^)])*)\\))?|\\(((?:\\\\.|[^)])*)\\))([+*?])?","([.+*?=^!:${}()[\\]|\\/])"].join("|"),"g"),o=function(e,r){return e.keys=r,e};t=r}).call(this),function(){function e(e){try{return decodeURIComponent(e).replace(/\+/g," ")}catch(r){return void(r.constructor==URIError&&a("Tried to decode an invalid URI component: "+JSON.stringify(e)+" "+r.stack))}}function o(e){try{return decodeURI(e).replace(/\+/g," ")}catch(r){return void(r.constructor==URIError&&a("Tried to decode an invalid URI: "+JSON.stringify(e)+" "+r.stack))}}var a=n.utils.warn;i=function(e,n){n=n||{},this.options=n,this.keys=[],this.regexp=t(e,this.keys,n),this._originalPath=e,r.extend(this,i.parse(e))},i.normalize=function(e){if(e instanceof RegExp)return e;if("string"!=typeof e)return"/";var r=i.parse(e),n=r.pathname;return"/"!==n.charAt(0)&&(n="/"+n),n.length>1&&"/"===n.charAt(n.length-1)&&(n=n.slice(0,n.length-1)),n},i.isSameOrigin=function(e,r){var n=i.parse(e),t=i.parse(r),o=n.origin===t.origin;return o},i.fromQueryString=function(n){if(!n)return{};if("string"!=typeof n)throw new Error("expected string");"?"===n.charAt(0)&&(n=n.slice(1));var t=n.split("&"),i={},o;return r.each(t,function(r){var n=r.split("="),t=n[0],o=e(n[1]);"[]"===t.slice(-2)?(t=t.slice(0,-2),i[t]=i[t]||[],i[t].push(o)):i[t]=o}),i},i.toQueryString=function(e){var n=[];return"string"==typeof e?"?"!==e.charAt(0)?"?"+e:e:(r.each(e,function(e,t){r.isArray(e)?r.each(e,function(e){n.push(encodeURIComponent(t+"[]")+"="+encodeURIComponent(e))}):n.push(encodeURIComponent(t)+"="+encodeURIComponent(e))}),n.length>0?"?"+n.join("&"):"")},i.parse=function(e){if("string"!=typeof e)return{};var r=/^(([^:\/?#]+):)?(\/\/([^\/?#]*))?([^?#]*)(\?([^#]*))?(#(.*))?/,n=e.match(r),t=n[1]?n[1].toLowerCase():void 0,o=n[3],a=!!o,s=n[4]?n[4].toLowerCase():void 0,c=s?s.split("@"):[],u,p;2==c.length?(p=c[0],u=c[1]):1==c.length?(u=c[0],p=void 0):(u=void 0,p=void 0);var h=u&&u.split(":")||[],l=h[0],f=h[1],g=t&&u?t+"//"+u:void 0,d=n[5],m=n[8],y=e,v=n[6],w,R=m&&m.indexOf("?")||-1;~R&&!v?(v=m.slice(R),m=m.substr(0,R),w=v.slice(1)):w=n[7];var x=d+(v||""),U=i.fromQueryString(w),S=[t||"",a?"//":"",s||""].join(""),I=[t||"",a?"//":"",s||"",d||"",v||"",m||""].join("");return{rootUrl:S||"",originalUrl:e||"",href:I||"",protocol:t||"",auth:p||"",host:u||"",hostname:l||"",port:f||"",origin:g||"",path:x||"",pathname:d||"",search:v||"",query:w||"",queryObject:U||"",hash:m||"",slashes:a}},i.prototype.test=function(e){return this.regexp.test(i.normalize(e))},i.prototype.exec=function(e){return this.regexp.exec(i.normalize(e))},i.prototype.params=function(r){if(!r)return[];var n=[],t=this.exec(r),a,s=this.keys,c,u;if(!t)throw new Error('The route named "'+this.name+'" does not match the path "'+r+'"');for(var p=1,h=t.length;h>p;++p)c=s[p-1],u="string"==typeof t[p]?e(t[p]):t[p],c?n[c.name]=void 0!==n[c.name]?n[c.name]:u:n.push(u);return r=o(r),"undefined"!=typeof r&&(a=r.split("?")[1],a&&(a=a.split("#")[0]),n.hash=r.split("#")[1]||null,n.query=i.fromQueryString(a)),n},i.prototype.resolve=function(e,n){var t,o,a,s=0,c=this._originalPath,u,p,h=[],l=e;if(n=n||{},e=e||[],p=n.query,u=n.hash&&n.hash.toString(),c instanceof RegExp)throw new Error("Cannot currently resolve a regular expression path");if(c=c.replace(/(\/)?(\.)?:(\w+)(?:(\(.*?\)))?(\?)?/g,function(n,i,a,s,c,u,p){if(i=i||"",t=e[s],o="undefined"!=typeof t,u&&!o)t="";else if(!o)return void h.push(s);t=r.isFunction(t)?t.call(e):t;var l=r.map(String(t).split("/"),function(e){return encodeURIComponent(e)}).join("/");return i+l}).replace(/\*/g,function(n){if("undefined"==typeof e[s])throw new Error("You are trying to access a wild card parameter at index "+s+" but the value of params at that index is undefined");var t=String(e[s++]);return r.map(t.split("/"),function(e){return encodeURIComponent(e)}).join("/")}),p=i.toQueryString(p),c+=p,u&&(u=encodeURI(u.replace("#","")),c=c+"#"+u),c=c.replace(/\/+/g,"/"),c=c.replace(/^(.+)\/$/g,"$1"),0==h.length)return c;if(n.throwOnMissingParams===!0)throw new Error("Missing required parameters on path "+JSON.stringify(this._originalPath)+". The missing params are: "+JSON.stringify(h)+". The params object passed in was: "+JSON.stringify(l)+".");return null},n.Url=i}.call(this),"undefined"==typeof Package&&(Package={}),Package["iron:url"]={}}();
+
+!function(){var t=Package.meteor.Meteor,e=Package.underscore._,n=Package["iron:core"].Iron,r,i,n;(function(){var t=n.Url;r=function(n,r,i){e.isFunction(n)&&(i=i||r||{},r=n,n="/",this.middleware=!0,"undefined"==typeof i.mount&&(i.mount=!0)),"object"==typeof r&&(i=r,r=i.action||"action"),i=i||{},this.options=i,this.mount=i.mount,this.method=i.method&&i.method.toLowerCase()||!1,this.where=i.where||"client",this.mount&&(i.end=!1),i.name?this.name=i.name:"string"==typeof n&&"/"!==n.charAt(0)?this.name=n:r&&r.name?this.name=r.name:"string"==typeof n&&"/"!==n&&(this.name=n.split("/").slice(1).join(".")),n=i.path||n,"string"==typeof n&&"/"!==n.charAt(0)&&(n="/"+n),this.path=n,this.compiledUrl=new t(n,i),e.isString(r)?this.handle=function o(){var t=this[r];if("function"!=typeof t)throw new Error("No method named "+JSON.stringify(r)+" found on handler.");return t.apply(this,arguments)}:e.isFunction(r)&&(this.handle=r)},r.prototype.test=function(t,e){e=e||{};var n=this.compiledUrl.test(t),r=!0,i=!0;return this.method&&e.method&&(r=this.method==e.method.toLowerCase()),e.where&&(i=this.where==e.where),n&&r&&i},r.prototype.params=function(t){return this.compiledUrl.params(t)},r.prototype.resolve=function(t,e){return this.compiledUrl.resolve(t,e)},r.prototype.clone=function(){var t=new r(this.path,this.handle,this.options);return t.name=this.name,t}}).call(this),function(){var o=n.Url,a=n.utils.assert,s=n.utils.defaultValue;i=function(){this._stack=[],this.length=0},i.prototype._create=function(t,n,i){var o=new r(t,n,i),a=o.name;if(a){if(e.has(this._stack,a))throw new Error("Handler with name '"+a+"' already exists.");this._stack[a]=o}return o},i.prototype.findByName=function(t){return this._stack[t]},i.prototype.push=function(t,e,n){var r=this._create(t,e,n);return this._stack.push(r),this.length++,r},i.prototype.append=function(){var t=this,n=e.toArray(arguments),r={};return"object"==typeof n[n.length-1]&&(r=n.pop()),e.each(n,function(n){if("undefined"!=typeof n)if("function"==typeof n)t.push(n,r);else{if(!e.isArray(n))throw new Error("Can only append functions or arrays to the MiddlewareStack");t.append.apply(t,n.concat([r]))}}),this},i.prototype.insertAt=function(t,e,n,r){var i=this._create(e,n,r);return this._stack.splice(t,0,i),this.length=this._stack.length,this},i.prototype.insertBefore=function(t,n,r,i){var o,a;if(!(o=this._stack[t]))throw new Error("Couldn't find a handler named '"+t+"' on the path stack");return a=e.indexOf(this._stack,o),this.insertAt(a,n,r,i),this},i.prototype.insertAfter=function(t,n,r,i){var o,a;if(!(o=this._stack[t]))throw new Error("Couldn't find a handler named '"+t+"' on the path stack");return a=e.indexOf(this._stack,o),this.insertAt(a+1,n,r,i),this},i.prototype.concat=function(){var t=new i,n=Array.prototype.concat,r=EJSON.clone(this._stack),o=e.map(e.toArray(arguments),function(t){return EJSON.clone(t._stack)});return t._stack=n.apply(r,o),this.length=t._stack.length,t},i.prototype.dispatch=function h(e,n,r){var i=this,h=e;a("string"==typeof e,"Requires url"),a("object"==typeof n,"Requires context object"),e=o.normalize(e||"/"),s(n,"request",{}),s(n,"response",{}),s(n,"originalUrl",e),s(n,"_method",n.method),s(n,"_handlersForEnv",{client:!1,server:!1}),s(n,"_handled",!1),s(n,"isHandled",function(){return n._handled}),s(n,"willBeHandledOnClient",function(){return n._handlersForEnv.client}),s(n,"willBeHandledOnServer",function(){return n._handlersForEnv.server});var l=function(){if(r)try{r.apply(this,arguments)}catch(t){throw t._punt=!0,t}},c=0,u=t.bindEnvironment(function p(r){var a=i._stack[c++];if(n.url=n.request.url=n.originalUrl,!a)return l.call(n,r);if(!a.test(e,{method:n._method}))return u(r);var s=t.isClient?"client":"server";if(a.middleware||(n._handlersForEnv[a.where]=!0),a.where!==s)return u(r);if(n.next=u,a.mount){var h=o.normalize(a.compiledUrl.pathname),p=e.substr(h.length,e.length);p=o.normalize(p),n.url=n.request.url=p}try{var d=a.handle.length,f=n.request,m=n.response;return r&&4===d?a.handle.call(n,r,f,m,u):!r&&4>d?a.handle.call(n,f,m,u):u(r)}catch(r){if(r._punt)throw r;u(r)}finally{n._handled=!0,n.next=null}});return u(),n.next=null,n},n=n||{},n.MiddlewareStack=i}.call(this),"undefined"==typeof Package&&(Package={}),Package["iron:middleware-stack"]={Handler:r}}();
+
+!function(){var t=Package.meteor.Meteor,e=Package.underscore._,n=Package.tracker.Tracker,a=Package.tracker.Deps,r=Package.jquery.$,o=Package.jquery.jQuery,i=Package["iron:core"].Iron,c,s,h,u,l;(function(){var t=i.Url,n="__hash__";c=function(e){var a=t.parse(e),r=a.hash&&a.hash.replace("#",""),o=a.search,i=a.pathname,c=a.rootUrl;if(r&&"!"!==r.charAt(0)){var s=n+"="+r;o=o?o+"&":"?",o+=s,r=""}return!r&&i?r="#!"+i.substring(1):r&&(r="#"+r),[c,r,o].join("")},s=function(a){var r=t.parse(a),o=r.hash&&r.hash.replace("#!","/"),i=r.search,c=r.rootUrl,s;return e.has(r.queryObject,n)?(s="#"+r.queryObject[n],delete r.queryObject[n]):s="",[c,o,t.toQueryString(r.queryObject),s].join("")},h=function(e){var a=t.parse(e),r=a.queryObject;return a.hash&&(r[n]=a.hash.replace("#","")),["!",a.pathname.substring(1),t.toQueryString(r)].join("")}}).call(this),function(){var t=i.Url;u=function(n,a){e.extend(this,t.parse(n),{options:a||{}})},u.prototype.equals=function(t){return t&&t instanceof u&&t.pathname==this.pathname&&t.search==this.search&&t.hash==this.hash&&t.options.historyState===this.options.historyState?!0:!1},u.prototype.isCancelled=function(){return!!this._isCancelled},u.prototype.cancelUrlChange=function(){this._isCancelled=!0}}.call(this),function(){var n=i.Url,o=null,f=new a.Dependency,p={go:[],popState:[]},y=function(){return/MSIE 9/.test(navigator.appVersion)},g=function(){return/MSIE 8/.test(navigator.appVersion)},d=function(){return!!Package.appcache},S=function(){return"undefined"==typeof history||"function"!=typeof history.pushState},v=function(){return l.options.useHashPaths||g()||y()||d()||S()},k=function(){return!!l.options.useHashPaths},w=function(t,n){e.each(p[t],function(t){t.call(n)})},P=function(t){if(!(t instanceof u))throw new Error("Expected a State instance");return t.equals(o)?!1:(o=t,f.changed(),!0)},m=function(){var t=location.href,e;e=k()?new u(s(t)):new u(t,{historyState:history.state}),w("popState",e),P(e)},j=function(t){var e=q;e&&e(t)},_=function(t,e){e=e||{};var n=new u(t,e);w("go",n),P(n)&&a.afterFlush(function(){n.isCancelled()||(k()?location.hash=h(t):e.replaceState===!0?history.replaceState(e.historyState,null,t):history.pushState(e.historyState,null,t))})},q=function(t){try{var e=t.currentTarget,a=e.href,r=e.pathname+e.search+e.hash;if(r=r.replace(/(^\/?)/,"/"),t.isDefaultPrevented())return void t.preventDefault();if(t.metaKey||t.ctrlKey||t.shiftKey)return;if(e.target)return;if(!n.isSameOrigin(a,location.href))return;t.preventDefault(),_(r)}catch(o){throw t.preventDefault(),o}};l={},l.options={linkSelector:"a[href]",useHashPaths:!1},l.configure=function(t){e.extend(this.options,t||{})},l.get=function(){return f.depend(),o},l.start=function(){if(!this._isStarted){var e=n.parse(location.href);if(v()){if(e.pathname.length>1){var a=c(location.href);window.location=a}this.configure({useHashPaths:!0})}var o=location.href;if(k()){var i=new u(s(o));P(i)}else{if("!"===e.hash.replace("#","")[0])var o=s(o);var h={initial:!0};history.replaceState(h,null,o);var i=new u(o,{historyState:h});P(i)}r(window).on("popstate.iron-location",m),r(window).on("hashchange.iron-location",m),t.startup(function(){r(document).on("click.iron-location",l.options.linkSelector,j)}),this._isStarted=!0}},l.stop=function(){this._isStarted&&(r(window).on("popstate.iron-location"),r(window).on("hashchange.iron-location"),r(document).off("click.iron-location"),this._isStarted=!1)},l.onClick=function(t){q=t},l.go=function(t,e){return _(t,e)},l.onGo=function(t){p.go.push(t)},l.onPopState=function(t){p.popState.push(t)},l.start(),i.Location=l}.call(this),"undefined"==typeof Package&&(Package={}),Package["iron:location"]={urlToHashStyle:c,urlFromHashStyle:s}}();
+
+!function(){var t=Package.meteor.Meteor,n=Package.underscore._,e=Package.tracker.Tracker,o=Package.tracker.Deps,a=Package["reactive-dict"].ReactiveDict,r=Package.templating.Template,i=Package["iron:core"].Iron,u=Package.blaze.Blaze,s=Package.blaze.UI,c=Package.blaze.Handlebars,l=Package.htmljs.HTML,p,d;(function(){var t=i.utils.assert,e=function(){for(var t={},n=o.currentComputation;n;)t[String(n._id)]=!0,n=n._parent;return t},a=function(o){var a=e(),r=n.keys(o._dependentsById);r.forEach(function(n){t(!a[n],"\n\nYou called wait() after calling ready() inside the same computation tree.\n\nYou can fix this problem in two possible ways:\n\n1) Put all of your wait() calls before any ready() calls.\n2) Put your ready() call in its own computation with Deps.autorun.")})};p=function(){this._readyDep=new o.Dependency,this._comps=[],this._notReadyCount=0},p.prototype.wait=function(t){var e=this,r=o.currentComputation;a(e._readyDep),o.nonreactive(function(){var a=null,i=o.autorun(function(n){var o=!!t(),r=e._notReadyCount;n.firstRun&&!o?e._notReadyCount++:null!==a&&o!==a&&o===!0?e._notReadyCount--:null!==a&&o!==a&&o===!1&&e._notReadyCount++,a=o,0===r&&e._notReadyCount>0?e._readyDep.changed():r>0&&0===e._notReadyCount&&e._readyDep.changed()});e._comps.push(i),r&&r.onInvalidate(function(){o.afterFlush(function(){i.stop(),e._comps.splice(n.indexOf(e._comps,i),1),a===!1&&(e._notReadyCount--,0===e._notReadyCount&&e._readyDep.changed())})})})},p.prototype.ready=function(){return this._readyDep.depend(),0===this._notReadyCount},p.prototype.stop=function(){n.each(this._comps,function(t){t.stop()}),this._comps=[]},i.WaitList=p}).call(this),function(){var t=i.utils.debug("iron:controller"),e=i.Layout,o=i.DynamicTemplate,a=function(t,n){return function(){return"function"==typeof t?t.apply(n,arguments):t}};d=function(t){var n=this;this.options=t||{},this._layout=this.options.layout||new e(this.options),this._isController=!0,this._layout._setLookupHost(this);var o=d._collectEventMaps.call(this.constructor);this._layout.events(o,this),this.init(t)},d.prototype.layout=function(t,e){var o=this;return this._layout.template(t),e&&n.has(e,"data")&&this._layout.data(a(e.data,this)),{data:function(t){return o._layout.data(a(t,o))}}},d.prototype.render=function(t,n){var e=this;n&&"undefined"!=typeof n.data&&(n.data=a(n.data,this));var o=this._layout.render(t,n);return{data:function(t){return o.data(a(t,e))}}},d.prototype.beginRendering=function(t){return this._layout.beginRendering(t)},d.extend=function(t){return i.utils.extend(this,t)},d.events=function(t){return this._eventMap=t,this};var s=function(t,e){var o={};return t.__super__&&n.extend(o,s(t.__super__.constructor,e)),n.has(t,e)?n.extend(o,t[e]):o};d._collectEventMaps=function(){return s(this,"_eventMap")},d._helpers={},d.helpers=function(t){return n.extend(this._helpers,t),this},"undefined"!=typeof r&&(i.controller=function(){return o.findLookupHostWithProperty(u.getView(),"_isController")},r.registerHelper("get",function(t){var n=i.controller();return n&&n.state?n.state.get(t):void 0})),i.Controller=d}.call(this),function(){var t=i.Layout,e=i.utils.debug("iron:controller"),o=i.utils.defaultValue,r=function(t,n){return function(){return"function"==typeof t?t.apply(n,arguments):t}};d.prototype.init=function(t){this._waitlist=new p,this.state=new a},d.prototype.insert=function(t){return this._layout.insert.apply(this._layout,arguments)},d.prototype.wait=function(t){var e=this;if(t)return n.isArray(t)?n.each(t,function o(t){e.wait(t)}):this._waitlist.wait(t.ready?function(){return t.ready()}:t),this},d.prototype.ready=function(){return this._waitlist.ready()},d.prototype.stop=function(){this._waitlist.stop()}}.call(this),"undefined"==typeof Package&&(Package={}),Package["iron:controller"]={}}();
+
+!function(){var t=Package.underscore._,e=Package.tracker.Tracker,o=Package.tracker.Deps,r=Package.blaze.Blaze,n=Package.blaze.UI,i=Package.blaze.Handlebars,a=Package.templating.Template,u=Package.ejson.EJSON,s=Package.meteor.Meteor,l=Package["iron:core"].Iron,p=Package.htmljs.HTML,c,h,f,d,y,m;(function(){f=new s.EnvironmentVariable}).call(this),function(){d=["get","post","put","delete"]}.call(this),function(){var e=l.Controller,o=l.Url,r=l.MiddlewareStack,n=l.utils.assert;h=e.extend({constructor:function(e){h.__super__.constructor.apply(this,arguments),e=e||{},this.options=e,this._onStopCallbacks=[],this.route=e.route,this.params=[];var o=this.lookupOption("data");"function"==typeof o?this.data=t.bind(o,this):"undefined"!=typeof o&&(this.data=function(){return o}),this.init(e)}}),h.prototype.lookupOption=function(e){if(this.route&&this.route.options&&t.has(this.route.options,e))return this.route.options[e];if(t.has(this.options,e))return this.options[e];if("undefined"!=typeof this[e])return this[e];var o=f.get();return o&&t.has(o,e)?o[e]:this.router&&this.router.options&&t.has(this.router.options,e)?this.router.options[e]:void 0},h.prototype.configureFromUrl=function(t,e,o){n("string"==typeof t,"url must be a string"),e=e||{},this.request=e.request||{},this.response=e.response||{},this.url=e.url||t,this.originalUrl=e.originalUrl||t,this.method=this.request.method,this.route&&this.setParams(this.route.params(t),o)},h.prototype._collectHooks=function(){var e=this,o=t.toArray(arguments),r=function(o){if(!o)return[];var r=e.router.lookupHook,n=t.isArray(o)?o:[o];return t.map(n,function(t){return r(t)})},n=function(e,o){var i=[];return e.__super__&&(i=i.concat(n(e.__super__.constructor,o))),t.has(e.prototype,o)?i.concat(r(e.prototype[o])):i},i=function(t){for(var e=0;e<o.length;e++)t(o[e])},a=[];i(function(t){var o=e.route&&e.route.getName(),r=e.router.getHooks(t,o);a=a.concat(r)});var u=[];i(function(t){var o=n(e.constructor,t);u=u.concat(o)});var s=[];i(function(o){if(t.has(e,o)){var n=r(e[o]);s=s.concat(n)}});var l=[];e.route&&i(function(t){var o=r(e.route.options[t]);l=l.concat(o)});var p=a.concat(l).concat(u).concat(s);return p},h.prototype.runHooks=function(){for(var t=this._collectHooks.apply(this,arguments),e=0,o=t.length;o>e;e++){var r=t[e];r.call(this)}return t.length},h.prototype.getParams=function(){return this.params},h.prototype.setParams=function(t){return this.params=t,this},l.RouteController=h}.call(this),function(){var r=l.Controller,n=l.Url,i=l.MiddlewareStack,a=l.utils.debug("iron-router:RouteController");if(h.prototype.init=function(t){h.__super__.init.apply(this,arguments),this._computation=null,this._paramsDep=new e.Dependency,this.location=l.Location},h.prototype.getParams=function(){return this._paramsDep.depend(),this.params},h.prototype.setParams=function(e,o){var r=function(e,r){if(!(e instanceof Array))throw new Error("you called equals with a non array value in setParams");if(!(r instanceof Array))return!1;if(e.length!==r.length)return!1;for(var n=0;n<e.length;n++)if(!u.equals(e[n],r[n],o))return!1;var i=t.keys(e),a=t.keys(r),s;if(i.length!==a.length)return!1;for(var n=0;n<i.length;n++){if(s=i[n],!t.has(r,s))return!1;if(!u.equals(e[s],r[s]))return!1}return!0};if(!r(this.params,e))return this.params=e,o=o||{},o.reactive!==!1&&this._paramsDep.changed(),this},h.prototype.dispatch=function(t,e,r){if(this._computation&&!this._computation.stopped)throw new Error("RouteController computation is already running. Stop it first.");var n=this;return o.nonreactive(function(){o.autorun(function(o){n._computation=o,t.dispatch(e,n,r)})}),n},h.prototype._runRoute=function(e,r,n){var a=this,u=this._collectHooks("subscriptions");t.each(u,function(t){a.wait(t.call(a))});var s=this._collectHooks("waitOn");t.each(s,function(t){a.wait(t.call(a))});var p=s.length>0,c,f,d=function(){return o.nonreactive(function(){return a._layout.template()})},y=function(){return o.nonreactive(function(){var t=a._layout._regions.main;return t&&t.template()})},m=d(),_=y();this.beginRendering(function R(e){if(!a.isStopped){var o=d(),r=y();if(m!==o||_!=r){var n=a._layout.regionKeys(),i=t.difference(n,e);t.each(i,function(t){a._layout.clear(t)})}}}),this.layout(this.lookupOption("layoutTemplate"),{data:this.lookupOption("data")});var g=new i,v=new i,k=new i;v.append(this._collectHooks("onRun","load"),{where:"client"}),k.append(this._collectHooks("onRerun"),{where:"client"}),g.append(function b(t,e,o){this._computation.firstRun&&!h._hasJustReloaded?(h._hasJustReloaded=!1,v.length>0?v.dispatch(t.url,this,o):o()):o()},function C(t,e,o){this._computation.firstRun?o():k.length>0?k.dispatch(t.url,this,o):o()},{where:"client"}),p&&g.push(t.bind(l.Router.hooks.loading,a));var w=this._collectHooks("onBeforeAction","before");g.append(w,{where:"client"}),0===e._actionStack.length&&e._actionStack.push(e._path,"action",e.options),g=g.concat(e._actionStack),this._rendered=!1,g.dispatch(r,this,n),o.afterFlush(function(){l.utils.warn(a._rendered||a.isStopped,"Route dispatch never rendered. Did you forget to call this.next() in an onBeforeAction?")}),this.runHooks("onAfterAction","after")},h.prototype.action=function(){this.render()},h.prototype.lookupTemplate=function(){return this.lookupOption("template")||this.router&&this.router.toTemplateName(this.route.getName())},h.prototype.lookupRegionTemplates=function(){return this.lookupOption("yieldRegions")||this.lookupOption("regionTemplates")||this.lookupOption("yieldTemplates")||{}},h.prototype.render=function(t,e){if(this._rendered=!0,0===arguments.length){var t=this.lookupTemplate(),o=h.__super__.render.call(this,t);return this.renderRegions(),o}return h.__super__.render.call(this,t,e)},h.prototype.renderRegions=function(){var e=this,o=this.lookupRegionTemplates();a("regionTemplates: "+JSON.stringify(o)),t.each(o,function(t,o){e.render(o,t)})},h.prototype.stop=function(){h.__super__.stop.call(this),this._computation&&this._computation.stop(),this.runHooks("onStop","unload"),this.isStopped=!0},h.prototype.redirect=function(){return this.router.go.apply(this.router,arguments)},h.prototype.subscribe=function(){var e=this,o=s.subscribe.apply(this,arguments);return t.extend(o,{wait:function(){e.wait(this)}})},s._reload){s._reload.onMigrate("iron-router",function(){return[!0,!0]});var p=s._reload.migrationData("iron-router");h._hasJustReloaded=p}}.call(this),function(){var e=l.Url,o=l.MiddlewareStack,r=l.utils.assert;y=function(e,r,n){var i=function(t,e,o){var r=this;r.request=t,r.response=e,i.dispatch(t.url,r,o)};return"object"==typeof r&&(n=r,r=n.action),n=n||{},"string"==typeof e&&"/"!==e.charAt(0)&&(e=n.path?n.path:"/"+e),t.extend(i,this),n=i.options=n||{},i._actionStack=new o,i._beforeStack=new o,i._beforeStack.append(i.options.onBeforeAction),i._beforeStack.append(i.options.before),i._afterStack=new o,i._afterStack.append(i.options.onAfterAction),i._afterStack.append(i.options.after),i._methods={},"string"==typeof r?i._actionStack.push(e,t.extend(n,{template:r})):("function"==typeof r||"object"==typeof r)&&i._actionStack.push(e,r,n),i._path=e,i},y.prototype.getName=function(){return this.handler&&this.handler.name},y.prototype.findControllerConstructor=function(){var t=this,e=function(t,e){e=e||{};var o=l.utils.resolve(t);if(o&&h.prototype.isPrototypeOf(o.prototype))return o;if(e.supressErrors!==!0)throw new Error("RouteController '"+t+"' is not defined.");return void 0},o=function(e){return t.router.toControllerName(e)},r,n=this.getName();return"function"==typeof this.options.controller?this.options.controller:"string"==typeof this.options.controller?e(this.options.controller):n&&(r=e(o(n),{supressErrors:!0}))?r:h},y.prototype.createController=function(t){t=t||{};var e=this.findControllerConstructor();t.route=this;var o=new e(t);return o},y.prototype.setControllerParams=function(t,e){},y.prototype.dispatch=function(t,e,o){return r(e._runRoute,"context doesn't have a _runRoute method"),e._runRoute(this,t,o)},y.prototype.path=function(t,e){return this.handler.resolve(t,e)},y.prototype.url=function(t,e){var o=this.path(t,e),r=e&&e.host||s.absoluteUrl();return"/"===r.charAt(r.length-1),r=r.slice(0,r.length-1),r+o},y.prototype.params=function(t){return this.handler.params(t)},t.each(d,function(t){y.prototype[t]=function(e){return this._methods[t]=!0,this._actionStack.push(this._path,e,{name:this.getName()+"_"+t.toLowerCase(),method:t,where:this.handler.where,mount:!1}),this}}),l.Route=y}.call(this),function(){var e=l.MiddlewareStack,o=l.Url,r=l.Layout,n=l.utils.warn,i=l.utils.assert;c=function(o){function r(t,e,o){r.dispatch(t.url,{request:t,response:e},o)}return r._stack=new e,r._globalHooks={},r.routes=[],r.routes._byPath={},this.configure.call(r,o),t.extend(r,this),this.init.call(r,o),s.startup(function(){s.defer(function(){r.options.autoStart!==!1&&r.start()})}),r},c.prototype.init=function(t){},c.prototype.configure=function(e){var o=this;e=e||{};var r=function(e){return e?t.isArray(e)?e:[e]:[]};return t.each(l.Router.HOOK_TYPES,function n(i){e[i]&&(t.each(r(e[i]),function a(t){o.addHook(i,t)}),delete e[i])}),this.options=this.options||{},t.extend(this.options,e),this},c.prototype.map=function(t){return t.call(this)},c.prototype.route=function(t,e,o){var r=function(t){return Object.prototype.toString.call(t)};i("[object String]"===r(t)||"[object RegExp]"===r(t),"Router.route requires a path that is a string or regular expression."),"object"==typeof e&&(o=e,e=o.action);var n=new y(t,e,o);o=o||{},o.mount=!1;var a=this._stack.push(t,n,o);return a.route=n,n.handler=a,n.router=this,i(!this.routes._byPath[a.path],"A route for the path "+JSON.stringify(a.path)+" already exists by the name of "+JSON.stringify(a.name)+"."),this.routes._byPath[a.path]=n,this.routes.push(n),"string"==typeof a.name&&(this.routes[a.name]=n),n},c.prototype.findFirstRoute=function(t){for(var e,o,r=0;r<this.routes.length;r++)if(m=this.routes[r],e=m.handler.test(t,{where:s.isServer?"server":"client"}))return m;return null},c.prototype.path=function(t,e,o){var r=this.routes[t];return n(r,"You called Router.path for a route named "+JSON.stringify(t)+" but that route doesn't seem to exist. Are you sure you created it?"),r&&r.path(e,o)},c.prototype.url=function(t,e,o){var r=this.routes[t];return n(r,"You called Router.url for a route named "+JSON.stringify(t)+" but that route doesn't seem to exist. Are you sure you created it?"),r&&r.url(e,o)},c.prototype.createController=function(t,e){var o=this.findFirstRoute(t),r;return e=e||{},r=o?o.createController({layout:this._layout}):new h({layout:this._layout}),r.router=this,r.configureFromUrl(t,e,{reactive:!1}),r},c.prototype.setTemplateNameConverter=function(t){return this._templateNameConverter=t,this},c.prototype.setControllerNameConverter=function(t){return this._controllerNameConverter=t,this},c.prototype.toTemplateName=function(t){return this._templateNameConverter?this._templateNameConverter(t):l.utils.classCase(t)},c.prototype.toControllerName=function(t){return this._controllerNameConverter?this._controllerNameConverter(t):l.utils.classCase(t)+"Controller"},c.prototype.addHook=function(e,o,r){var n=this;r=r||{};var i=function(e){return e?t.isArray(e)?e:[e]:[]};r.only&&(r.only=i(r.only)),r.except&&(r.except=i(r.except));var a=this._globalHooks[e]=this._globalHooks[e]||[],u=function(){var t=this,e=arguments;return f.withValue(r,function(){return n.lookupHook(o).apply(t,e)})};return a.push({options:r,hook:u}),this},c.prototype.lookupHook=function(e){var o=e;if(t.isFunction(o))return o;if(t.isString(o)&&t.isFunction(l.Router.hooks[o]))return l.Router.hooks[o];throw new Error("No hook found named: "+e)},c.prototype.getHooks=function(e,o){var r=this,n=[];return t.each(this._globalHooks[e],function(e){var r=e.options;return r.except&&t.include(r.except,o)?[]:r.only&&!t.include(r.only,o)?[]:void n.push(e.hook)}),n},c.HOOK_TYPES=["onRun","onRerun","onBeforeAction","onAfterAction","onStop","waitOn","subscriptions","load","before","after","unload"],c.hooks={},c.plugins={},t.each(c.HOOK_TYPES,function(t){c.prototype[t]=function(e,o){this.addHook(t,e,o)}}),c.prototype.plugin=function(t,e){var o;if("function"==typeof t?o=t:"string"==typeof t&&(o=l.Router.plugins[t]),!o)throw new Error("No plugin found named "+JSON.stringify(t));return o.call(this,this,e),this},l.Router=c}.call(this),function(){if("undefined"!=typeof a)var t=new a("DefaultLoadingTemplate",function(){return"Loading..."}),e=new a("DefaultDataNotFoundTemplate",function(){return"Data not found..."});c.hooks.loading=function(){if(this.ready())return void this.next();var e=this.lookupOption("loadingTemplate");this.render(e||t),this.renderRegions()},c.hooks.dataNotFound=function(){if(!this.ready())return void this.next();var t=this.lookupOption("data"),o,r=this.lookupOption("notFoundTemplate");return"function"!=typeof t||(o=t.call(this))?void this.next():(this.render(r||e),void this.renderRegions())}}.call(this),function(){var e=l.utils.warn,o=l.DynamicTemplate,i=l.utils.debug("iron:router <helpers>");n.registerHelper("Router",new r.Template("Router",function(){return c.createView()})),n.registerHelper("pathFor",function(o){var r;arguments.length>1&&(r=arguments[0],o=arguments[1]||{});var n=o&&o.hash;n=n||{};var i="",a=n.query,s=n.hash,r=r||n.route,l=t.extend({},n.data||this),p=c.routes[r];return e(p,"pathFor couldn't find a route named "+JSON.stringify(r)),p&&(t.each(p.handler.compiledUrl.keys,function(e){var o=e.name;t.has(n,o)&&(l[o]=u.clone(n[o]),delete n[o])}),i=p.path(l,{query:a,hash:s})),i}),n.registerHelper("urlFor",function(o){var r;arguments.length>1&&(r=arguments[0],o=arguments[1]||{});var n=o&&o.hash;n=n||{};var i="",a=n.query,s=n.hash,r=r||n.route,l=t.extend({},n.data||this),p=c.routes[r];return e(p,"urlFor couldn't find a route named "+JSON.stringify(r)),p&&(t.each(p.handler.compiledUrl.keys,function(e){var o=e.name;t.has(n,o)&&(l[o]=u.clone(n[o]),delete n[o])}),i=p.url(l,{query:a,hash:s})),i}),n.registerHelper("linkTo",new r.Template("linkTo",function(){var n=this,i=o.getInclusionArguments(this);if("object"!=typeof i)throw new Error("linkTo options must be key value pairs such as {{#linkTo route='my.route.name'}}. You passed: "+JSON.stringify(i));i=i||{};var a="",s=i.query,l=i.hash,h=i.route,f=t.extend({},i.data||o.getParentDataContext(this)),d=c.routes[h],y;e(d,"linkTo couldn't find a route named "+JSON.stringify(h)),d&&(t.each(d.handler.compiledUrl.keys,function(e){var o=e.name;t.has(i,o)&&(f[o]=u.clone(i[o]),delete i[o])}),a=d.path(f,{query:s,hash:l}));var m=t.omit(i,"route","query","hash","data");return m.href=a,r.With(function(){return o.getParentDataContext(n)},function(){return p.A(m,n.templateContentBlock)})}))}.call(this),function(){var e=l.MiddlewareStack,r=l.Url,n=l.Layout,i=l.utils.assert,a="__IronRouterNotFound__",u="__IronRouterNoRoutes__";c.prototype.init=function(t){var e=this;e._currentController=null,e._currentRoute=null,e._currentDep=new o.Dependency,e._locationComputation=null,e._layout=new n({template:e.options.layoutTemplate}),s.startup(function(){setTimeout(function t(){e.options.autoRender!==!1&&e.insert({el:document.body})})})},c.prototype.insert=function(t){return this._layout.insert(t),this},c.prototype.createView=function(){return this._layout.create()},c.prototype.lookupNotFoundTemplate=function(){return this.options.notFoundTemplate?this.options.notFoundTemplate:0===this.routes.length?u:a},c.prototype.lookupLayoutTemplate=function(){return this.options.layoutTemplate},c.prototype.dispatch=function(t,e,r){var n=this;i("string"==typeof t,"expected url string in router dispatch");var s=this._currentController,l=this.findFirstRoute(t),p=this._currentRoute;return this._currentRoute=l,this._currentController&&this._currentController.stop(),s&&l&&p===l?s.configureFromUrl(t,e):s=this.createController(t,e),this._currentController=s,s.dispatch(n._stack,t,function c(t){if(t)throw t;if(!s.isHandled()){var e=o.nonreactive(function(){return s.location.get().options.historyState});if(e&&e.initial===!0){this.layout(this.lookupOption("layoutTemplate"),{data:{url:this.url}});var i=this.lookupOption("notFoundTemplate");i||(i=0===n.routes.length?u:a),this.render(i,{data:{url:this.url}}),this.renderRegions(),s.isHandled=function(){return!0}}return r&&r.call(s)}}),this._currentController==s&&this._currentDep.changed(),s},c.prototype.current=function(){return this._currentDep.depend(),this._currentController},c.prototype._scrollToHash=function(t){try{var e=$(t);$("html, body").scrollTop(e.offset().top)}catch(o){}},c.prototype.start=function(){var t=this,e;t._locationComputation=o.autorun(function r(o){var r,n=l.Location.get(),i,a,u,s=t._currentController;!s||e&&e.path!==n.path?r=t.dispatch(n.href,null,function p(t){this.isHandled()||(n.cancelUrlChange(),window.location=n.path)}):(t._scrollToHash(n.hash),s.configureFromUrl(n.href)),e=n})},c.prototype.stop=function(){this._isStarted&&(this._locationComputation&&this._locationComputation.stop(),this._currentController&&this._currentController.stop(),this._isStarted=!1)},c.prototype.go=function(e,o,r){var n=this,a=/^\/|http/,u;if(r=r||{},a.test(e))u=e;else{var s=n.routes[e];i(s,"No route found named "+JSON.stringify(e)),u=s.path(o,t.extend(r,{throwOnMissingParams:!0}))}l.Location.go(u,r)}}.call(this),function(){c.plugins.loading=function(t,e){t.onBeforeAction("loading",e)},c.plugins.dataNotFound=function(t,e){t.onBeforeAction("dataNotFound",e)}}.call(this),function(){c=new l.Router}.call(this),function(){a.__checkName("__IronRouterNotFound__"),a.__IronRouterNotFound__=new a("Template.__IronRouterNotFound__",function(){var t=this;return p.DIV({style:"width: 600px; margin: 0 auto; padding: 20px;"},"\n ",p.DIV({style:"font-size: 18pt; color: #999;"},"\n Oops, looks like there's no route on the client or the server for url: \"",r.View(function(){return Spacebars.mustache(t.lookup("url"))}),'."\n '),"\n ")}),a.__checkName("__IronRouterNoRoutes__"),a.__IronRouterNoRoutes__=new a("Template.__IronRouterNoRoutes__",function(){var t=this;return p.Raw('<div style="font-family: helvetica; color: #777; max-width: 600px; margin: 20px auto;">\n <h1 style="text-align: center; margin: 0; font-size: 48pt;">\n iron:router\n </h1>\n <p style="text-align: center; font-size: 1.3em;">\n Organize your Meteor application.\n </p>\n <div style="margin: 50px 0px;">\n <pre style="background: #f2f2f2; margin: 0; padding: 10px;">\nRouter.route(\'/\', function () {\n this.render(\'Home\', {\n data: function () { return Items.findOne({_id: this.params._id}); }\n });\n});\n </pre>\n </div>\n <div style="margin: 50px 0px;">\n Check it out on Github:<br>\n <a href="https://github.com/eventedmind/iron-router" target="_blank">https://github.com/eventedmind/iron-router</a>\n <br>\n <br>\n And check out the new Guide:<br>\n <a href="https://eventedmind.github.io/iron-router" target="_blank">\n https://eventedmind.github.io/iron-router\n </a>\n </div>\n </div>')})}.call(this),"undefined"==typeof Package&&(Package={}),Package["iron:router"]={Router:c,RouteController:h}}();
+
+!function(){var e=Package.meteor.Meteor,t=Package.underscore._,n;(function(){n={_isCssLoaded:function(){return 0===document.styleSheets.length?!0:t.find(document.styleSheets,function(e){return e.cssText&&!e.cssRules?!e.cssText.match(/meteor-css-not-found-error/):!t.find(e.cssRules,function(e){return".meteor-css-not-found-error"===e.selectorText})})}}}).call(this),"undefined"==typeof Package&&(Package={}),Package.webapp={WebApp:n}}();
+
+!function(){var a=Package.meteor.Meteor,e=Package.ddp.DDP,e,t;"undefined"==typeof Package&&(Package={}),Package.livedata={DDP:e,LivedataTest:t}}();
+
+!function(){var t=Package.meteor.Meteor,n=Package.htmljs.HTML,e=Package.tracker.Tracker,a=Package.tracker.Deps,r=Package.blaze.Blaze,u=Package.blaze.UI,i=Package.blaze.Handlebars,o=Package["observe-sequence"].ObserveSequence,c=Package.templating.Template,l;(function(){l={};var t=function(t,n){return t===n};l.include=function(n,e,a){if(!n)return null;if("function"!=typeof n){var u=n;if(!r.isTemplate(u))throw new Error("Expected template or null, found: "+u);return n.constructView(e,a)}var i=r.ReactiveVar(null,t),o=r.View("Spacebars.include",function(){var t=i.get();if(null===t)return null;if(!r.isTemplate(t))throw new Error("Expected template or null, found: "+t);return t.constructView(e,a)});return o.__templateVar=i,o.onViewCreated(function(){this.autorun(function(){i.set(n())})}),o},l.mustacheImpl=function(t){var n=arguments;if(n.length>1){var e=n[n.length-1];if(e instanceof l.kw){var a={};for(var r in e.hash){var u=e.hash[r];a[r]="function"==typeof u?u():u}n[n.length-1]=l.kw(a)}else e=l.kw(),n=Array.prototype.slice.call(arguments),n.push(e)}return l.call.apply(null,n)},l.mustache=function(t){var e=l.mustacheImpl.apply(null,arguments);return e instanceof l.SafeString?n.Raw(e.toString()):null==e||e===!1?null:String(e)},l.attrMustache=function(t){var e=l.mustacheImpl.apply(null,arguments);if(null==e||""===e)return null;if("object"==typeof e)return e;if("string"==typeof e&&n.isValidAttributeName(e)){var a={};return a[e]="",a}throw new Error("Expected valid attribute name, '', null, or object")},l.dataMustache=function(t){var n=l.mustacheImpl.apply(null,arguments);return n},l.makeRaw=function(t){return null==t?null:t instanceof n.Raw?t:n.Raw(t)},l.call=function(t){if("function"==typeof t){for(var n=[],e=1;e<arguments.length;e++){var a=arguments[e];n[e-1]="function"==typeof a?a():a}return t.apply(null,n)}if(arguments.length>1)throw new Error("Can't call non-function: "+t);return t},l.kw=function(t){return this instanceof l.kw?void(this.hash=t||{}):new l.kw(t)},l.SafeString=function(t){return this instanceof l.SafeString?new i.SafeString(t):new l.SafeString(t)},l.SafeString.prototype=i.SafeString.prototype,l.dot=function(t,n){if(arguments.length>2){var e=[];return e.push(l.dot(t,n)),e.push.apply(e,Array.prototype.slice.call(arguments,2)),l.dot.apply(null,e)}if("function"==typeof t&&(t=t()),!t)return t;var a=t[n];return"function"!=typeof a?a:function(){return a.apply(t,arguments)}},l.With=function(t,n,a){var u=new r.ReactiveVar,i=r.View("Spacebars_with",function(){return r.If(function(){return u.get()},function(){return r.With(function(){return u.get()},n)},a)});return i.onViewCreated(function(){this.autorun(function(){u.set(t()),e.onInvalidate(function(){u.dep.changed()})})}),i},l.TemplateWith=r._TemplateWith}).call(this),function(){c.__checkName("__dynamic"),c.__dynamic=new c("Template.__dynamic",function(){var t=this;return[r.View(function(){return l.mustache(t.lookup("checkContext"))}),"\n ",r.If(function(){return l.call(t.lookup("dataContextPresent"))},function(){return["\n ",l.include(t.lookupTemplate("__dynamicWithDataContext")),"\n "]},function(){return["\n \n ",r._TemplateWith(function(){return{template:l.call(t.lookup("template")),data:l.call(t.lookup(".."))}},function(){return l.include(t.lookupTemplate("__dynamicWithDataContext"))}),"\n "]})]}),c.__checkName("__dynamicWithDataContext"),c.__dynamicWithDataContext=new c("Template.__dynamicWithDataContext",function(){var t=this;return l.With(function(){return l.dataMustache(t.lookup("chooseTemplate"),t.lookup("template"))},function(){return["\n ",r._TemplateWith(function(){return l.call(l.dot(t.lookup(".."),"data"))},function(){return l.include(t.lookupTemplate(".."))})," \n "]})})}.call(this),function(){c.__dynamicWithDataContext.helpers({chooseTemplate:function(t){return c[t]||null}}),c.__dynamic.helpers({dataContextPresent:function(){return _.has(this,"data")},checkContext:function(){if(!_.has(this,"template"))throw new Error("Must specify name in the 'template' argument to {{> Template.dynamic}}.");_.each(this,function(t,n){if("template"!==n&&"data"!==n)throw new Error("Invalid argument to {{> Template.dynamic}}: "+n)})}})}.call(this),"undefined"==typeof Package&&(Package={}),Package.spacebars={Spacebars:l}}();
+
+!function(){var e=Package.meteor.Meteor,a;(function(){var n=0,r=!1;a={hold:function(){if(!e.isCordova)return{release:function(){}};if(r)throw new Error("Can't show launch screen once it's hidden");n++;var a=!1,t=function(){e.isCordova&&(a||(n--,0===n&&"undefined"!=typeof navigator&&navigator.splashscreen&&(r=!0,navigator.splashscreen.hide())))};return{release:t}}}}).call(this),function(){var n=a.hold(),r=Package.templating&&Package.templating.Template;e.startup(function(){if(r)if(Package["iron:router"])Package["iron:router"].Router.onAfterAction(function(){n.release()});else{var e=setInterval(function(){r.body.view&&r.body.view.isRendered&&(n.release(),clearInterval(e))},50);setTimeout(function(){n.release()},6e3)}else n.release()})}.call(this),"undefined"==typeof Package&&(Package={}),Package["launch-screen"]={LaunchScreen:a}}();
+
+FastClick=Package.fastclick.FastClick,Cookie=Package["chuangbo:cookie"].Cookie,moment=Package["jeeeyul:moment-with-langs"].moment,TAPi18next=Package["tap:i18n"].TAPi18next,TAPi18n=Package["tap:i18n"].TAPi18n,Helpers=Package["raix:handlebar-helpers"].Helpers,TemplateVar=Package["frozeman:template-var"].TemplateVar,PersistentMinimongo=Package["frozeman:persistent-minimongo"].PersistentMinimongo,ReactiveTimer=Package["frozeman:reactive-timer"].ReactiveTimer,BigNumber=Package["3stack:bignumber"].BigNumber,Showdown=Package.markdown.Showdown,numeral=Package["numeral:numeral"].numeral,EthTools=Package["ethereum:tools"].EthTools,Router=Package["iron:router"].Router,RouteController=Package["iron:router"].RouteController,Meteor=Package.meteor.Meteor,WebApp=Package.webapp.WebApp,Log=Package.logging.Log,Tracker=Package.deps.Tracker,Deps=Package.deps.Deps,Session=Package.session.Session,DDP=Package.livedata.DDP,Mongo=Package.mongo.Mongo,Blaze=Package.ui.Blaze,UI=Package.ui.UI,Handlebars=Package.ui.Handlebars,Spacebars=Package.spacebars.Spacebars,Template=Package.templating.Template,check=Package.check.check,Match=Package.check.Match,_=Package.underscore._,$=Package.jquery.$,jQuery=Package.jquery.jQuery,Random=Package.random.Random,EJSON=Package.ejson.EJSON,LaunchScreen=Package["launch-screen"].LaunchScreen,Iron=Package["iron:core"].Iron,HTML=Package.htmljs.HTML;
+
+!function(){Template.__checkName("layout_notFound"),Template.layout_notFound=new Template("Template.layout_notFound",function(){var n=this;return HTML.Raw('<main class="dapp-content">\n <h1>Nothing here...</h1>\n </main>')})}();
+
+!function(){Template.__checkName("views_home"),Template.views_home=new Template("Template.views_home",function(){var e=this;return[HTML.H2({"class":"page-title"}," ",Blaze.View(function(){return Spacebars.mustache(e.lookup("i18n"),"network.home.NetworkHealth")})),"\n \n\n ",HTML.H2(" ",Blaze.View(function(){return Spacebars.mustache(e.lookup("i18n"),"network.home.Mining")})," "),"\n \n ",HTML.DIV({"class":"dapp container mining-stats"},"\n ",HTML.DIV({"class":"mining-slider dapp-big-number"},"\n ",HTML.INPUT({type:"range",name:"fee",min:"0",max:"1",step:"1",value:function(){return Spacebars.mustache(e.lookup("miningSlider"))},"class":"slider-vertical"}),"\n ",HTML.DD(Blaze.View(function(){return Spacebars.mustache(e.lookup("i18n"),"network.home.MiningStatus")})),"\n ",HTML.DT({"class":"mining-status"},"\n ",Blaze.If(function(){return Spacebars.call(e.lookup("miningSlider"))},function(){return["\n ",Blaze.If(function(){return Spacebars.call(e.lookup("hashrate"))},function(){return["\n ",Blaze.View(function(){return Spacebars.mustache(e.lookup("hashrate"))})," ",HTML.SMALL("KHash "),"\n "]},function(){return["\n ",Blaze.View(function(){return Spacebars.mustache(e.lookup("i18n"),"network.home.on")}),"\n "]}),"\n "]},function(){return["\n ",Blaze.View(function(){return Spacebars.mustache(e.lookup("i18n"),"network.home.off")}),"\n "]}),"\n \n "),"\n "),"\n ",HTML.DIV({"class":"dapp-big-number"},"\n ",HTML.DD(Blaze.View(function(){return Spacebars.mustache(e.lookup("i18n"),"network.home.TimeSpent")})),"\n ",HTML.DT({"class":"time-spent"},Blaze.View(function(){return Spacebars.makeRaw(Spacebars.mustache(e.lookup("timeSpent")))})),"\n ")," \n ",HTML.DIV({"class":"dapp-big-number"},"\n ",HTML.DD(Blaze.View(function(){return Spacebars.mustache(e.lookup("i18n"),"network.home.Rewards")})),"\n ",HTML.DT(Blaze.View(function(){return Spacebars.makeRaw(Spacebars.mustache(e.lookup("totalRewards")))})),"\n ")," \n ",HTML.DIV({"class":"dapp-big-number"},"\n ",HTML.DD(Blaze.View(function(){return Spacebars.mustache(e.lookup("i18n"),"network.home.AverageReward")})),"\n ",HTML.DT(" ",Blaze.View(function(){return Spacebars.makeRaw(Spacebars.mustache(e.lookup("averageRewardPerHour")))})),"\n ")," \n "),"\n\n \n ",HTML.H2(" ",Blaze.View(function(){return Spacebars.mustache(e.lookup("i18n"),"network.home.Connections")})," "),"\n\n ",HTML.DIV({"class":"dapp-container"},"\n\n ",HTML.DL({"class":"latest-block-info"},"\n\n ",HTML.DIV({"class":"dapp-big-number"},"\n ",HTML.DD(Blaze.View(function(){return Spacebars.mustache(e.lookup("i18n"),"network.home.PeerCount")})),"\n ",HTML.DT(Blaze.View(function(){return Spacebars.mustache(e.lookup("peerCount"))})," ",HTML.SMALL(" ",Blaze.View(function(){return Spacebars.mustache(e.lookup("i18n"),"network.home.Peers")})," ")),"\n "),"\n ",HTML.DIV({"class":"dapp-big-number"},"\n ",HTML.DD(Blaze.View(function(){return Spacebars.mustache(e.lookup("i18n"),"network.home.GasPrice")})),"\n ",HTML.DT(Blaze.View(function(){return Spacebars.mustache(e.lookup("gasPrice"))})," ",HTML.SMALL(" ",Blaze.View(function(){return Spacebars.mustache(e.lookup("i18n"),"network.home.Finney")})," ")),"\n "),"\n "),"\n\n "),"\n \n ",HTML.H2(" ",Blaze.View(function(){return Spacebars.mustache(e.lookup("i18n"),"network.home.Blockchain")})," "),"\n\n ",HTML.DIV({"class":"block-chain"},"\n ",HTML.DIV({"class":"wrapper"},"\n ",Blaze.Each(function(){return Spacebars.call(e.lookup("blocks"))},function(){return["\n ",HTML.DIV({"class":"dapp-box card",style:function(){return["background-image:",Spacebars.mustache(e.lookup("currentBlockPattern"))]}},"\n ",Blaze._TemplateWith(function(){return{identity:Spacebars.call("miner")}},function(){return Spacebars.include(e.lookupTemplate("dapp_identicon"))}),"\n ",HTML.H1(" ",Blaze.View(function(){return Spacebars.mustache(e.lookup("i18n"),"network.home.Block")})," ",Blaze.View(function(){return Spacebars.mustache(e.lookup("number"))})),"\n ",HTML.H3(Blaze.View(function(){return Spacebars.mustache(e.lookup("hash"))})),"\n ",HTML.DL("\n ",HTML.DD(" ",Blaze.View(function(){return Spacebars.mustache(e.lookup("i18n"),"network.home.GasUsed")})," "),"\n ",HTML.DT(Blaze.View(function(){return Spacebars.mustache(e.lookup("gasUsed"))})),"\n ",HTML.DD(" ",Blaze.View(function(){return Spacebars.mustache(e.lookup("i18n"),"network.home.Size")})," "),"\n ",HTML.DT(Blaze.View(function(){return Spacebars.mustache(e.lookup("size"))})),"\n ",HTML.DD(" ",Blaze.View(function(){return Spacebars.mustache(e.lookup("i18n"),"network.home.Uncles")})," "),"\n ",HTML.DT(Blaze.View(function(){return Spacebars.mustache(e.lookup("uncles"))})),"\n ",HTML.DD(" ",Blaze.View(function(){return Spacebars.mustache(e.lookup("i18n"),"network.home.Time")})," "),"\n ",HTML.DT(Blaze.View(function(){return Spacebars.mustache(e.lookup("formatTime"),e.lookup("time"),"YYYY-MM-DD HH:mm:ss")})),"\n "),"\n "),"\n "]}),"\n ",HTML.DIV({"class":"",style:""},"\n ",HTML.H3(" ",Blaze.View(function(){return Spacebars.mustache(e.lookup("i18n"),"network.home.EndOfBlocks")})," "),"\n "),"\n "),"\n ")]})}();
+
+!function(){Template.body.addContent(function(){var e=this;return[Spacebars.include(e.lookupTemplate("layout_main")),HTML.Raw('\n \n <!-- Form Helper iFrame -->\n <iframe id="dapp-form-helper-iframe" name="dapp-form-helper-iframe" src="javascript:false;"></iframe>')]}),Meteor.startup(Template.body.renderToDocument)}();
+
+!function(){Template.__checkName("layout_main"),Template.layout_main=new Template("Template.layout_main",function(){var n=this;return[HTML.Raw('<!-- <div class="dapp-grid"></div>\n --> \n '),HTML.DIV({"class":"dapp-flex-content"},"\n\n ",HTML.Raw("<!-- content -->"),"\n ",HTML.MAIN({"class":"dapp-content"},"\n ",Spacebars.include(n.lookupTemplate("views_home")),"\n "),"\n\n ")]})}();
+
+!function(){Helpers={},Helpers.rerun={"10s":new ReactiveTimer(10)},Helpers.getLocalStorageSize=function(){var e=0;return localStorage&&_.each(Object.keys(localStorage),function(n){e+=2*localStorage[n].length/1024/1024}),e},Helpers.moment=function(e){return TAPi18n.getLanguage(),_.isFinite(e)&&moment.unix(e).isValid()?moment.unix(e):moment(e)},Helpers.formatTime=function(e,n){return n instanceof Spacebars.kw&&(n=null),e?(_.isString(n)&&!_.isEmpty(n)&&("iso"===n.toLowerCase()?e=Helpers.moment(e).toISOString():"fromnow"===n.toLowerCase()?(Helpers.rerun["10s"].tick(),e=Helpers.moment(e).fromNow()):e=Helpers.moment(e).format(n)),e):""}}();
+
+!function(){Template.registerHelper("debug",function(e){console.log(e)}),Template.registerHelper("username",function(e){var t=Users.findOne(e);return Whisper.getIdentity().identity===e?Whisper.getIdentity().name:t?t.name:"anonymous"}),Template.registerHelper("currentIdentity",function(e){return Whisper.getIdentity()}),Template.registerHelper("formatTime",Helpers.formatTime)}();
+
+!function(){!function(){function a(e){if(!(this instanceof a))return new a(e);if("function"==typeof e)return this.random=e,this;var n;arguments.length&&(this.seed=0);for(var i=0;i<arguments.length;i++){if(n=0,"string"==typeof arguments[i])for(var t=0;t<arguments[i].length;t++)n+=(arguments[i].length-t)*arguments[i].charCodeAt(t);else n=arguments[i];this.seed+=(arguments.length-i)*n}return this.mt=this.mersenne_twister(this.seed),this.random=function(){return this.mt.random(this.seed)},this}function e(a,e){if(a||(a={}),e)for(var n in e)"undefined"==typeof a[n]&&(a[n]=e[n]);return a}function n(a,e){if(a)throw new RangeError(e)}function i(a){return function(){return this.natural(a)}}function t(a,e){for(var n=y(a),i=0,t=n.length;t>i;i++)key=n[i],e[key]=a[key]||e[key]}function r(a,e){for(var n=0,i=a.length;i>n;n++)e[n]=a[n]}function o(a,e){var n=Array.isArray(a),i=e||(n?new Array(a.length):{});return n?r(a,i):t(a,i),i}var s=9007199254740992,m=-s,l="0123456789",b="abcdefghijklmnopqrstuvwxyz",h=b.toUpperCase(),c=l+"abcdef",u=Array.prototype.slice;a.prototype.VERSION="0.7.1";var d=function(){throw new Error("No Base64 encoder available.")};!function(){"function"==typeof btoa?d=btoa:"function"==typeof Buffer&&(d=function(a){return new Buffer(a).toString("base64")})}(),a.prototype.bool=function(a){return a=e(a,{likelihood:50}),n(a.likelihood<0||a.likelihood>100,"Chance: Likelihood accepts values from 0 to 100."),100*this.random()<a.likelihood},a.prototype.character=function(a){a=e(a);var i,t,r="!@#$%^&*()[]";return n(a.alpha&&a.symbols,"Chance: Cannot specify both alpha and symbols."),i="lower"===a.casing?b:"upper"===a.casing?h:b+h,t=a.pool?a.pool:a.alpha?i:a.symbols?r:i+l+r,t.charAt(this.natural({max:t.length-1}))},a.prototype.floating=function(a){var i;a=e(a,{fixed:4});var t=Math.pow(10,a.fixed);n(a.fixed&&a.precision,"Chance: Cannot specify both fixed and precision.");var r=s/t,o=-r;n(a.min&&a.fixed&&a.min<o,"Chance: Min specified is out of range with fixed. Min should be, at least, "+o),n(a.max&&a.fixed&&a.max>r,"Chance: Max specified is out of range with fixed. Max should be, at most, "+r),a=e(a,{min:o,max:r}),i=this.integer({min:a.min*t,max:a.max*t});var m=(i/t).toFixed(a.fixed);return parseFloat(m)},a.prototype.integer=function(a){return a=e(a,{min:m,max:s}),n(a.min>a.max,"Chance: Min cannot be greater than Max."),Math.floor(this.random()*(a.max-a.min+1)+a.min)},a.prototype.natural=function(a){return a=e(a,{min:0,max:s}),this.integer(a)},a.prototype.string=function(a){a=e(a);var n=a.length||this.natural({min:5,max:20}),i=a.pool,t=this.n(this.character,n,{pool:i});return t.join("")},a.prototype.capitalize=function(a){return a.charAt(0).toUpperCase()+a.substr(1)},a.prototype.mixin=function(e){for(var n in e)a.prototype[n]=e[n];return this},a.prototype.unique=function(a,n,i){i=e(i,{comparator:function(a,e){return-1!==a.indexOf(e)}});for(var t,r=[],o=0,s=50*n,m=u.call(arguments,2);r.length<n;)if(t=a.apply(this,m),i.comparator(r,t)||(r.push(t),o=0),++o>s)throw new RangeError("Chance: num is likely too large for sample set");return r},a.prototype.n=function(a,e){var n=e||1,i=[],t=u.call(arguments,2);for(n=Math.max(0,n),null;n--;null)i.push(a.apply(this,t));return i},a.prototype.pad=function(a,e,n){return n=n||"0",a+="",a.length>=e?a:new Array(e-a.length+1).join(n)+a},a.prototype.pick=function(a,e){if(0===a.length)throw new RangeError("Chance: Cannot pick() from an empty array");return e&&1!==e?this.shuffle(a).slice(0,e):a[this.natural({max:a.length-1})]},a.prototype.shuffle=function(a){for(var e=a.slice(0),n=[],i=0,t=Number(e.length),r=0;t>r;r++)i=this.natural({max:e.length-1}),n[r]=e[i],e.splice(i,1);return n},a.prototype.weighted=function(a,e){if(a.length!==e.length)throw new RangeError("Chance: length of array and weights must match");if(e.some(function(a){return 1>a})){var n=e.reduce(function(a,e){return a>e?e:a},e[0]),i=1/n;e=e.map(function(a){return a*i})}var t,r=e.reduce(function(a,e){return a+e},0),o=this.natural({min:1,max:r}),s=0;return e.some(function(e,n){return s+e>=o?(t=a[n],!0):(s+=e,!1)}),t},a.prototype.paragraph=function(a){a=e(a);var n=a.sentences||this.natural({min:3,max:7}),i=this.n(this.sentence,n);return i.join(" ")},a.prototype.sentence=function(a){a=e(a);var n,i=a.words||this.natural({min:12,max:18}),t=this.n(this.word,i);return n=t.join(" "),n=this.capitalize(n)+"."},a.prototype.syllable=function(a){a=e(a);for(var n,i=a.length||this.natural({min:2,max:3}),t="bcdfghjklmnprstvwz",r="aeiou",o=t+r,s="",m=0;i>m;m++)n=this.character(0===m?{pool:o}:-1===t.indexOf(n)?{pool:t}:{pool:r}),s+=n;return s},a.prototype.word=function(a){a=e(a),n(a.syllables&&a.length,"Chance: Cannot specify both syllables AND length.");var i=a.syllables||this.natural({min:1,max:3}),t="";if(a.length){do t+=this.syllable();while(t.length<a.length);t=t.substring(0,a.length)}else for(var r=0;i>r;r++)t+=this.syllable();return t},a.prototype.age=function(a){a=e(a);var n;switch(a.type){case"child":n={min:1,max:12};break;case"teen":n={min:13,max:19};break;case"adult":n={min:18,max:65};break;case"senior":n={min:65,max:100};break;case"all":n={min:1,max:100};break;default:n={min:18,max:65}}return this.natural(n)},a.prototype.birthday=function(a){return a=e(a,{year:(new Date).getFullYear()-this.age(a)}),this.date(a)},a.prototype.cpf=function(){var a=this.n(this.natural,9,{max:9}),e=2*a[8]+3*a[7]+4*a[6]+5*a[5]+6*a[4]+7*a[3]+8*a[2]+9*a[1]+10*a[0];e=11-e%11,e>=10&&(e=0);var n=2*e+3*a[8]+4*a[7]+5*a[6]+6*a[5]+7*a[4]+8*a[3]+9*a[2]+10*a[1]+11*a[0];return n=11-n%11,n>=10&&(n=0),""+a[0]+a[1]+a[2]+"."+a[3]+a[4]+a[5]+"."+a[6]+a[7]+a[8]+"-"+e+n},a.prototype.first=function(a){return a=e(a,{gender:this.gender()}),this.pick(this.get("firstNames")[a.gender.toLowerCase()])},a.prototype.gender=function(){return this.pick(["Male","Female"])},a.prototype.last=function(){return this.pick(this.get("lastNames"))},a.prototype.name=function(a){a=e(a);var n,i=this.first(a),t=this.last();return n=a.middle?i+" "+this.first(a)+" "+t:a.middle_initial?i+" "+this.character({alpha:!0,casing:"upper"})+". "+t:i+" "+t,a.prefix&&(n=this.prefix(a)+" "+n),a.suffix&&(n=n+" "+this.suffix(a)),n},a.prototype.name_prefixes=function(a){a=a||"all",a=a.toLowerCase();var e=[{name:"Doctor",abbreviation:"Dr."}];return("male"===a||"all"===a)&&e.push({name:"Mister",abbreviation:"Mr."}),("female"===a||"all"===a)&&(e.push({name:"Miss",abbreviation:"Miss"}),e.push({name:"Misses",abbreviation:"Mrs."})),e},a.prototype.prefix=function(a){return this.name_prefix(a)},a.prototype.name_prefix=function(a){return a=e(a,{gender:"all"}),a.full?this.pick(this.name_prefixes(a.gender)).name:this.pick(this.name_prefixes(a.gender)).abbreviation},a.prototype.ssn=function(a){a=e(a,{ssnFour:!1,dashes:!0});var n,i="1234567890",t=a.dashes?"-":"";return n=a.ssnFour?this.string({pool:i,length:4}):this.string({pool:i,length:3})+t+this.string({pool:i,length:2})+t+this.string({pool:i,length:4})},a.prototype.name_suffixes=function(){var a=[{name:"Doctor of Osteopathic Medicine",abbreviation:"D.O."},{name:"Doctor of Philosophy",abbreviation:"Ph.D."},{name:"Esquire",abbreviation:"Esq."},{name:"Junior",abbreviation:"Jr."},{name:"Juris Doctor",abbreviation:"J.D."},{name:"Master of Arts",abbreviation:"M.A."},{name:"Master of Business Administration",abbreviation:"M.B.A."},{name:"Master of Science",abbreviation:"M.S."},{name:"Medical Doctor",abbreviation:"M.D."},{name:"Senior",abbreviation:"Sr."},{name:"The Third",abbreviation:"III"},{name:"The Fourth",abbreviation:"IV"}];return a},a.prototype.suffix=function(a){return this.name_suffix(a)},a.prototype.name_suffix=function(a){return a=e(a),a.full?this.pick(this.name_suffixes()).name:this.pick(this.name_suffixes()).abbreviation},a.prototype.android_id=function(){return"APA91"+this.string({pool:"0123456789abcefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ-_",length:178})},a.prototype.apple_token=function(){return this.string({pool:"abcdef1234567890",length:64})},a.prototype.wp8_anid2=function(){return d(this.hash({length:32}))},a.prototype.wp7_anid=function(){return"A="+this.guid().replace(/-/g,"").toUpperCase()+"&E="+this.hash({length:3})+"&W="+this.integer({min:0,max:9})},a.prototype.bb_pin=function(){return this.hash({length:8})},a.prototype.color=function(a){function n(a,e){return[a,a,a].join(e||"")}a=e(a,{format:this.pick(["hex","shorthex","rgb","0x"]),grayscale:!1,casing:"lower"});var i,t=a.grayscale;if("hex"===a.format)i="#"+(t?n(this.hash({length:2})):this.hash({length:6}));else if("shorthex"===a.format)i="#"+(t?n(this.hash({length:1})):this.hash({length:3}));else if("rgb"===a.format)i=t?"rgb("+n(this.natural({max:255}),",")+")":"rgb("+this.natural({max:255})+","+this.natural({max:255})+","+this.natural({max:255})+")";else{if("0x"!==a.format)throw new Error('Invalid format provided. Please provide one of "hex", "shorthex", "rgb" or "0x".');i="0x"+(t?n(this.hash({length:2})):this.hash({length:6}))}return"upper"===a.casing&&(i=i.toUpperCase()),i},a.prototype.domain=function(a){return a=e(a),this.word()+"."+(a.tld||this.tld())},a.prototype.email=function(a){return a=e(a),this.word({length:a.length})+"@"+(a.domain||this.domain())},a.prototype.fbid=function(){return parseInt("10000"+this.natural({max:1e11}),10)},a.prototype.google_analytics=function(){var a=this.pad(this.natural({max:999999}),6),e=this.pad(this.natural({max:99}),2);return"UA-"+a+"-"+e},a.prototype.hashtag=function(){return"#"+this.word()},a.prototype.ip=function(){return this.natural({max:255})+"."+this.natural({max:255})+"."+this.natural({max:255})+"."+this.natural({max:255})},a.prototype.ipv6=function(){var a=this.n(this.hash,8,{length:4});return a.join(":")},a.prototype.klout=function(){return this.natural({min:1,max:99})},a.prototype.tlds=function(){return["com","org","edu","gov","co.uk","net","io"]},a.prototype.tld=function(){return this.pick(this.tlds())},a.prototype.twitter=function(){return"@"+this.word()},a.prototype.url=function(a){a=e(a,{protocol:"http",domain:this.domain(a),domain_prefix:"",path:this.word(),extensions:[]});var n=a.extensions.length>0?"."+this.pick(a.extensions):"",i=a.domain_prefix?a.domain_prefix+"."+a.domain:a.domain;return a.protocol+"://"+i+"/"+a.path+n},a.prototype.address=function(a){return a=e(a),this.natural({min:5,max:2e3})+" "+this.street(a)},a.prototype.altitude=function(a){return a=e(a,{fixed:5,max:8848}),this.floating({min:0,max:a.max,fixed:a.fixed})},a.prototype.areacode=function(a){a=e(a,{parens:!0});var n=this.natural({min:2,max:9}).toString()+this.natural({min:0,max:8}).toString()+this.natural({min:0,max:9}).toString();return a.parens?"("+n+")":n},a.prototype.city=function(){return this.capitalize(this.word({syllables:3}))},a.prototype.coordinates=function(a){return a=e(a),this.latitude(a)+", "+this.longitude(a)},a.prototype.countries=function(){return this.get("countries")},a.prototype.country=function(a){a=e(a);var n=this.pick(this.countries());return a.full?n.name:n.abbreviation},a.prototype.depth=function(a){return a=e(a,{fixed:5,min:-2550}),this.floating({min:a.min,max:0,fixed:a.fixed})},a.prototype.geohash=function(a){return a=e(a,{length:7}),this.string({length:a.length,pool:"0123456789bcdefghjkmnpqrstuvwxyz"})},a.prototype.geojson=function(a){return a=e(a),this.latitude(a)+", "+this.longitude(a)+", "+this.altitude(a)},a.prototype.latitude=function(a){return a=e(a,{fixed:5,min:-90,max:90}),this.floating({min:a.min,max:a.max,fixed:a.fixed})},a.prototype.longitude=function(a){return a=e(a,{fixed:5,min:-180,max:180}),this.floating({min:a.min,max:a.max,fixed:a.fixed})},a.prototype.phone=function(a){var n,i=this,t=function(a){var e=[];return a.sections.forEach(function(a){e.push(i.string({pool:"0123456789",length:a}))}),a.area+e.join(" ")};a=e(a,{formatted:!0,country:"us",mobile:!1}),a.formatted||(a.parens=!1);var r;switch(a.country){case"fr":a.mobile?(n=this.pick(["06","07"])+i.string({pool:"0123456789",length:8}),r=a.formatted?n.match(/../g).join(" "):n):(n=this.pick(["01"+this.pick(["30","34","39","40","41","42","43","44","45","46","47","48","49","53","55","56","58","60","64","69","70","72","73","74","75","76","77","78","79","80","81","82","83"])+i.string({pool:"0123456789",length:6}),"02"+this.pick(["14","18","22","23","28","29","30","31","32","33","34","35","36","37","38","40","41","43","44","45","46","47","48","49","50","51","52","53","54","56","57","61","62","69","72","76","77","78","85","90","96","97","98","99"])+i.string({pool:"0123456789",length:6}),"03"+this.pick(["10","20","21","22","23","24","25","26","27","28","29","39","44","45","51","52","54","55","57","58","59","60","61","62","63","64","65","66","67","68","69","70","71","72","73","80","81","82","83","84","85","86","87","88","89","90"])+i.string({pool:"0123456789",length:6}),"04"+this.pick(["11","13","15","20","22","26","27","30","32","34","37","42","43","44","50","56","57","63","66","67","68","69","70","71","72","73","74","75","76","77","78","79","80","81","82","83","84","85","86","88","89","90","91","92","93","94","95","97","98"])+i.string({pool:"0123456789",length:6}),"05"+this.pick(["08","16","17","19","24","31","32","33","34","35","40","45","46","47","49","53","55","56","57","58","59","61","62","63","64","65","67","79","81","82","86","87","90","94"])+i.string({pool:"0123456789",length:6}),"09"+i.string({pool:"0123456789",length:8})]),r=a.formatted?n.match(/../g).join(" "):n);break;case"uk":a.mobile?(n=this.pick([{area:"07"+this.pick(["4","5","7","8","9"]),sections:[2,6]},{area:"07624 ",sections:[6]}]),r=a.formatted?t(n):t(n).replace(" ","")):(n=this.pick([{area:"01"+this.character({pool:"234569"})+"1 ",sections:[3,4]},{area:"020 "+this.character({pool:"378"}),sections:[3,4]},{area:"023 "+this.character({pool:"89"}),sections:[3,4]},{area:"024 7",sections:[3,4]},{area:"028 "+this.pick(["25","28","37","71","82","90","92","95"]),sections:[2,4]},{area:"012"+this.pick(["04","08","54","76","97","98"])+" ",sections:[5]},{area:"013"+this.pick(["63","64","84","86"])+" ",sections:[5]},{area:"014"+this.pick(["04","20","60","61","80","88"])+" ",sections:[5]},{area:"015"+this.pick(["24","27","62","66"])+" ",sections:[5]},{area:"016"+this.pick(["06","29","35","47","59","95"])+" ",sections:[5]},{area:"017"+this.pick(["26","44","50","68"])+" ",sections:[5]},{area:"018"+this.pick(["27","37","84","97"])+" ",sections:[5]},{area:"019"+this.pick(["00","05","35","46","49","63","95"])+" ",sections:[5]}]),r=a.formatted?t(n):t(n).replace(" ","","g"));break;case"us":var o=this.areacode(a).toString(),s=this.natural({min:2,max:9}).toString()+this.natural({min:0,max:9}).toString()+this.natural({min:0,max:9}).toString(),m=this.natural({min:1e3,max:9999}).toString();r=a.formatted?o+" "+s+"-"+m:o+s+m}return r},a.prototype.postal=function(){var a=this.character({pool:"XVTSRPNKLMHJGECBA"}),e=a+this.natural({max:9})+this.character({alpha:!0,casing:"upper"}),n=this.natural({max:9})+this.character({alpha:!0,casing:"upper"})+this.natural({max:9});return e+" "+n},a.prototype.provinces=function(){return this.get("provinces")},a.prototype.province=function(a){return a&&a.full?this.pick(this.provinces()).name:this.pick(this.provinces()).abbreviation},a.prototype.state=function(a){return a&&a.full?this.pick(this.states(a)).name:this.pick(this.states(a)).abbreviation},a.prototype.states=function(a){a=e(a);var n,i=this.get("us_states_and_dc"),t=this.get("territories"),r=this.get("armed_forces");return n=i,a.territories&&(n=n.concat(t)),a.armed_forces&&(n=n.concat(r)),n},a.prototype.street=function(a){a=e(a);var n=this.word({syllables:2});return n=this.capitalize(n),n+=" ",n+=a.short_suffix?this.street_suffix().abbreviation:this.street_suffix().name},a.prototype.street_suffix=function(){return this.pick(this.street_suffixes())},a.prototype.street_suffixes=function(){return this.get("street_suffixes")},a.prototype.zip=function(a){var e=this.n(this.natural,5,{max:9});return a&&a.plusfour===!0&&(e.push("-"),e=e.concat(this.n(this.natural,4,{max:9}))),e.join("")},a.prototype.ampm=function(){return this.bool()?"am":"pm"},a.prototype.date=function(a){var n,i;if(a&&(a.min||a.max)){a=e(a,{american:!0,string:!1});var t="undefined"!=typeof a.min?a.min.getTime():1,r="undefined"!=typeof a.max?a.max.getTime():864e13;i=new Date(this.natural({min:t,max:r}))}else{var o=this.month({raw:!0});a=e(a,{year:parseInt(this.year(),10),month:o.numeric-1,day:this.natural({min:1,max:o.days}),hour:this.hour(),minute:this.minute(),second:this.second(),millisecond:this.millisecond(),american:!0,string:!1}),i=new Date(a.year,a.month,a.day,a.hour,a.minute,a.second,a.millisecond)}return n=a.american?i.getMonth()+1+"/"+i.getDate()+"/"+i.getFullYear():i.getDate()+"/"+(i.getMonth()+1)+"/"+i.getFullYear(),a.string?n:i},a.prototype.hammertime=function(a){return this.date(a).getTime()},a.prototype.hour=function(a){return a=e(a,{min:1,max:a&&a.twentyfour?24:12}),n(a.min<1,"Chance: Min cannot be less than 1."),n(a.twentyfour&&a.max>24,"Chance: Max cannot be greater than 24 for twentyfour option."),n(!a.twentyfour&&a.max>12,"Chance: Max cannot be greater than 12."),n(a.min>a.max,"Chance: Min cannot be greater than Max."),this.natural({min:a.min,max:a.max})},a.prototype.millisecond=function(){return this.natural({max:999})},a.prototype.minute=a.prototype.second=function(a){return a=e(a,{min:0,max:59}),n(a.min<0,"Chance: Min cannot be less than 0."),n(a.max>59,"Chance: Max cannot be greater than 59."),n(a.min>a.max,"Chance: Min cannot be greater than Max."),this.natural({min:a.min,max:a.max})},a.prototype.month=function(a){a=e(a,{min:1,max:12}),n(a.min<1,"Chance: Min cannot be less than 1."),n(a.max>12,"Chance: Max cannot be greater than 12."),n(a.min>a.max,"Chance: Min cannot be greater than Max.");var i=this.pick(this.months().slice(a.min-1,a.max));return a.raw?i:i.name},a.prototype.months=function(){return this.get("months")},a.prototype.second=function(){return this.natural({max:59})},a.prototype.timestamp=function(){return this.natural({min:1,max:parseInt((new Date).getTime()/1e3,10)})},a.prototype.year=function(a){return a=e(a,{min:(new Date).getFullYear()}),a.max="undefined"!=typeof a.max?a.max:a.min+100,this.natural(a).toString()},a.prototype.cc=function(a){a=e(a);var n,i,t;return n=this.cc_type(a.type?{name:a.type,raw:!0}:{raw:!0}),i=n.prefix.split(""),t=n.length-n.prefix.length-1,i=i.concat(this.n(this.integer,t,{min:0,max:9})),i.push(this.luhn_calculate(i.join(""))),i.join("")},a.prototype.cc_types=function(){return this.get("cc_types")},a.prototype.cc_type=function(a){a=e(a);var n=this.cc_types(),i=null;if(a.name){for(var t=0;t<n.length;t++)if(n[t].name===a.name||n[t].short_name===a.name){i=n[t];break}if(null===i)throw new Error("Credit card type '"+a.name+"'' is not supported")}else i=this.pick(n);return a.raw?i:i.name},a.prototype.currency_types=function(){return this.get("currency_types")},a.prototype.currency=function(){return this.pick(this.currency_types())},a.prototype.currency_pair=function(a){var e=this.unique(this.currency,2,{comparator:function(a,e){return a.reduce(function(a,n){return a||n.code===e.code},!1)}});return a?e[0]+"/"+e[1]:e},a.prototype.dollar=function(a){a=e(a,{max:1e4,min:0});var n=this.floating({min:a.min,max:a.max,fixed:2}).toString(),i=n.split(".")[1];return void 0===i?n+=".00":i.length<2&&(n+="0"),0>n?"-$"+n.replace("-",""):"$"+n},a.prototype.exp=function(a){a=e(a);var n={};return n.year=this.exp_year(),n.month=n.year===(new Date).getFullYear()?this.exp_month({future:!0}):this.exp_month(),a.raw?n:n.month+"/"+n.year},a.prototype.exp_month=function(a){a=e(a);var n,i,t=(new Date).getMonth();if(a.future){do n=this.month({raw:!0}).numeric,i=parseInt(n,10);while(t>i)}else n=this.month({raw:!0}).numeric;return n},a.prototype.exp_year=function(){return this.year({max:(new Date).getFullYear()+10})},a.prototype.d4=i({min:1,max:4}),a.prototype.d6=i({min:1,max:6}),a.prototype.d8=i({min:1,max:8}),a.prototype.d10=i({min:1,max:10}),a.prototype.d12=i({min:1,max:12}),a.prototype.d20=i({min:1,max:20}),a.prototype.d30=i({min:1,max:30}),a.prototype.d100=i({min:1,max:100}),a.prototype.rpg=function(a,n){if(n=e(n),null===a)throw new Error("A type of die roll must be included");var i=a.toLowerCase().split("d"),t=[];if(2!==i.length||!parseInt(i[0],10)||!parseInt(i[1],10))throw new Error("Invalid format provided. Please provide #d# where the first # is the number of dice to roll, the second # is the max of each die");for(var r=i[0];r>0;r--)t[r-1]=this.natural({min:1,max:i[1]});return"undefined"!=typeof n.sum&&n.sum?t.reduce(function(a,e){return a+e}):t},a.prototype.guid=function(a){a=e(a,{version:5});var n="abcdef1234567890",i="ab89",t=this.string({pool:n,length:8})+"-"+this.string({pool:n,length:4})+"-"+a.version+this.string({pool:n,length:3})+"-"+this.string({pool:i,length:1})+this.string({pool:n,length:3})+"-"+this.string({pool:n,length:12});return t},a.prototype.hash=function(a){a=e(a,{length:40,casing:"lower"});var n="upper"===a.casing?c.toUpperCase():c;return this.string({pool:n,length:a.length})},a.prototype.luhn_check=function(a){var e=a.toString(),n=+e.substring(e.length-1);return n===this.luhn_calculate(+e.substring(0,e.length-1))},a.prototype.luhn_calculate=function(a){for(var e,n=a.toString().split("").reverse(),i=0,t=0,r=n.length;r>t;++t)e=+n[t],t%2===0&&(e*=2,e>9&&(e-=9)),i+=e;return 9*i%10};var p={firstNames:{male:["James","John","Robert","Michael","William","David","Richard","Joseph","Charles","Thomas","Christopher","Daniel","Matthew","George","Donald","Anthony","Paul","Mark","Edward","Steven","Kenneth","Andrew","Brian","Joshua","Kevin","Ronald","Timothy","Jason","Jeffrey","Frank","Gary","Ryan","Nicholas","Eric","Stephen","Jacob","Larry","Jonathan","Scott","Raymond","Justin","Brandon","Gregory","Samuel","Benjamin","Patrick","Jack","Henry","Walter","Dennis","Jerry","Alexander","Peter","Tyler","Douglas","Harold","Aaron","Jose","Adam","Arthur","Zachary","Carl","Nathan","Albert","Kyle","Lawrence","Joe","Willie","Gerald","Roger","Keith","Jeremy","Terry","Harry","Ralph","Sean","Jesse","Roy","Louis","Billy","Austin","Bruce","Eugene","Christian","Bryan","Wayne","Russell","Howard","Fred","Ethan","Jordan","Philip","Alan","Juan","Randy","Vincent","Bobby","Dylan","Johnny","Phillip","Victor","Clarence","Ernest","Martin","Craig","Stanley","Shawn","Travis","Bradley","Leonard","Earl","Gabriel","Jimmy","Francis","Todd","Noah","Danny","Dale","Cody","Carlos","Allen","Frederick","Logan","Curtis","Alex","Joel","Luis","Norman","Marvin","Glenn","Tony","Nathaniel","Rodney","Melvin","Alfred","Steve","Cameron","Chad","Edwin","Caleb","Evan","Antonio","Lee","Herbert","Jeffery","Isaac","Derek","Ricky","Marcus","Theodore","Elijah","Luke","Jesus","Eddie","Troy","Mike","Dustin","Ray","Adrian","Bernard","Leroy","Angel","Randall","Wesley","Ian","Jared","Mason","Hunter","Calvin","Oscar","Clifford","Jay","Shane","Ronnie","Barry","Lucas","Corey","Manuel","Leo","Tommy","Warren","Jackson","Isaiah","Connor","Don","Dean","Jon","Julian","Miguel","Bill","Lloyd","Charlie","Mitchell","Leon","Jerome","Darrell","Jeremiah","Alvin","Brett","Seth","Floyd","Jim","Blake","Micheal","Gordon","Trevor","Lewis","Erik","Edgar","Vernon","Devin","Gavin","Jayden","Chris","Clyde","Tom","Derrick","Mario","Brent","Marc","Herman","Chase","Dominic","Ricardo","Franklin","Maurice","Max","Aiden","Owen","Lester","Gilbert","Elmer","Gene","Francisco","Glen","Cory","Garrett","Clayton","Sam","Jorge","Chester","Alejandro","Jeff","Harvey","Milton","Cole","Ivan","Andre","Duane","Landon"],female:["Mary","Emma","Elizabeth","Minnie","Margaret","Ida","Alice","Bertha","Sarah","Annie","Clara","Ella","Florence","Cora","Martha","Laura","Nellie","Grace","Carrie","Maude","Mabel","Bessie","Jennie","Gertrude","Julia","Hattie","Edith","Mattie","Rose","Catherine","Lillian","Ada","Lillie","Helen","Jessie","Louise","Ethel","Lula","Myrtle","Eva","Frances","Lena","Lucy","Edna","Maggie","Pearl","Daisy","Fannie","Josephine","Dora","Rosa","Katherine","Agnes","Marie","Nora","May","Mamie","Blanche","Stella","Ellen","Nancy","Effie","Sallie","Nettie","Della","Lizzie","Flora","Susie","Maud","Mae","Etta","Harriet","Sadie","Caroline","Katie","Lydia","Elsie","Kate","Susan","Mollie","Alma","Addie","Georgia","Eliza","Lulu","Nannie","Lottie","Amanda","Belle","Charlotte","Rebecca","Ruth","Viola","Olive","Amelia","Hannah","Jane","Virginia","Emily","Matilda","Irene","Kathryn","Esther","Willie","Henrietta","Ollie","Amy","Rachel","Sara","Estella","Theresa","Augusta","Ora","Pauline","Josie","Lola","Sophia","Leona","Anne","Mildred","Ann","Beulah","Callie","Lou","Delia","Eleanor","Barbara","Iva","Louisa","Maria","Mayme","Evelyn","Estelle","Nina","Betty","Marion","Bettie","Dorothy","Luella","Inez","Lela","Rosie","Allie","Millie","Janie","Cornelia","Victoria","Ruby","Winifred","Alta","Celia","Christine","Beatrice","Birdie","Harriett","Mable","Myra","Sophie","Tillie","Isabel","Sylvia","Carolyn","Isabelle","Leila","Sally","Ina","Essie","Bertie","Nell","Alberta","Katharine","Lora","Rena","Mina","Rhoda","Mathilda","Abbie","Eula","Dollie","Hettie","Eunice","Fanny","Ola","Lenora","Adelaide","Christina","Lelia","Nelle","Sue","Johanna","Lilly","Lucinda","Minerva","Lettie","Roxie","Cynthia","Helena","Hilda","Hulda","Bernice","Genevieve","Jean","Cordelia","Marian","Francis","Jeanette","Adeline","Gussie","Leah","Lois","Lura","Mittie","Hallie","Isabella","Olga","Phoebe","Teresa","Hester","Lida","Lina","Winnie","Claudia","Marguerite","Vera","Cecelia","Bess","Emilie","John","Rosetta","Verna","Myrtie","Cecilia","Elva","Olivia","Ophelia","Georgie","Elnora","Violet","Adele","Lily","Linnie","Loretta","Madge","Polly","Virgie","Eugenia","Lucile","Lucille","Mabelle","Rosalie"]},lastNames:["Smith","Johnson","Williams","Jones","Brown","Davis","Miller","Wilson","Moore","Taylor","Anderson","Thomas","Jackson","White","Harris","Martin","Thompson","Garcia","Martinez","Robinson","Clark","Rodriguez","Lewis","Lee","Walker","Hall","Allen","Young","Hernandez","King","Wright","Lopez","Hill","Scott","Green","Adams","Baker","Gonzalez","Nelson","Carter","Mitchell","Perez","Roberts","Turner","Phillips","Campbell","Parker","Evans","Edwards","Collins","Stewart","Sanchez","Morris","Rogers","Reed","Cook","Morgan","Bell","Murphy","Bailey","Rivera","Cooper","Richardson","Cox","Howard","Ward","Torres","Peterson","Gray","Ramirez","James","Watson","Brooks","Kelly","Sanders","Price","Bennett","Wood","Barnes","Ross","Henderson","Coleman","Jenkins","Perry","Powell","Long","Patterson","Hughes","Flores","Washington","Butler","Simmons","Foster","Gonzales","Bryant","Alexander","Russell","Griffin","Diaz","Hayes","Myers","Ford","Hamilton","Graham","Sullivan","Wallace","Woods","Cole","West","Jordan","Owens","Reynolds","Fisher","Ellis","Harrison","Gibson","McDonald","Cruz","Marshall","Ortiz","Gomez","Murray","Freeman","Wells","Webb","Simpson","Stevens","Tucker","Porter","Hunter","Hicks","Crawford","Henry","Boyd","Mason","Morales","Kennedy","Warren","Dixon","Ramos","Reyes","Burns","Gordon","Shaw","Holmes","Rice","Robertson","Hunt","Black","Daniels","Palmer","Mills","Nichols","Grant","Knight","Ferguson","Rose","Stone","Hawkins","Dunn","Perkins","Hudson","Spencer","Gardner","Stephens","Payne","Pierce","Berry","Matthews","Arnold","Wagner","Willis","Ray","Watkins","Olson","Carroll","Duncan","Snyder","Hart","Cunningham","Bradley","Lane","Andrews","Ruiz","Harper","Fox","Riley","Armstrong","Carpenter","Weaver","Greene","Lawrence","Elliott","Chavez","Sims","Austin","Peters","Kelley","Franklin","Lawson","Fields","Gutierrez","Ryan","Schmidt","Carr","Vasquez","Castillo","Wheeler","Chapman","Oliver","Montgomery","Richards","Williamson","Johnston","Banks","Meyer","Bishop","McCoy","Howell","Alvarez","Morrison","Hansen","Fernandez","Garza","Harvey","Little","Burton","Stanley","Nguyen","George","Jacobs","Reid","Kim","Fuller","Lynch","Dean","Gilbert","Garrett","Romero","Welch","Larson","Frazier","Burke","Hanson","Day","Mendoza","Moreno","Bowman","Medina","Fowler","Brewer","Hoffman","Carlson","Silva","Pearson","Holland","Douglas","Fleming","Jensen","Vargas","Byrd","Davidson","Hopkins","May","Terry","Herrera","Wade","Soto","Walters","Curtis","Neal","Caldwell","Lowe","Jennings","Barnett","Graves","Jimenez","Horton","Shelton","Barrett","Obrien","Castro","Sutton","Gregory","McKinney","Lucas","Miles","Craig","Rodriquez","Chambers","Holt","Lambert","Fletcher","Watts","Bates","Hale","Rhodes","Pena","Beck","Newman","Haynes","McDaniel","Mendez","Bush","Vaughn","Parks","Dawson","Santiago","Norris","Hardy","Love","Steele","Curry","Powers","Schultz","Barker","Guzman","Page","Munoz","Ball","Keller","Chandler","Weber","Leonard","Walsh","Lyons","Ramsey","Wolfe","Schneider","Mullins","Benson","Sharp","Bowen","Daniel","Barber","Cummings","Hines","Baldwin","Griffith","Valdez","Hubbard","Salazar","Reeves","Warner","Stevenson","Burgess","Santos","Tate","Cross","Garner","Mann","Mack","Moss","Thornton","Dennis","McGee","Farmer","Delgado","Aguilar","Vega","Glover","Manning","Cohen","Harmon","Rodgers","Robbins","Newton","Todd","Blair","Higgins","Ingram","Reese","Cannon","Strickland","Townsend","Potter","Goodwin","Walton","Rowe","Hampton","Ortega","Patton","Swanson","Joseph","Francis","Goodman","Maldonado","Yates","Becker","Erickson","Hodges","Rios","Conner","Adkins","Webster","Norman","Malone","Hammond","Flowers","Cobb","Moody","Quinn","Blake","Maxwell","Pope","Floyd","Osborne","Paul","McCarthy","Guerrero","Lindsey","Estrada","Sandoval","Gibbs","Tyler","Gross","Fitzgerald","Stokes","Doyle","Sherman","Saunders","Wise","Colon","Gill","Alvarado","Greer","Padilla","Simon","Waters","Nunez","Ballard","Schwartz","McBride","Houston","Christensen","Klein","Pratt","Briggs","Parsons","McLaughlin","Zimmerman","French","Buchanan","Moran","Copeland","Roy","Pittman","Brady","McCormick","Holloway","Brock","Poole","Frank","Logan","Owen","Bass","Marsh","Drake","Wong","Jefferson","Park","Morton","Abbott","Sparks","Patrick","Norton","Huff","Clayton","Massey","Lloyd","Figueroa","Carson","Bowers","Roberson","Barton","Tran","Lamb","Harrington","Casey","Boone","Cortez","Clarke","Mathis","Singleton","Wilkins","Cain","Bryan","Underwood","Hogan","McKenzie","Collier","Luna","Phelps","McGuire","Allison","Bridges","Wilkerson","Nash","Summers","Atkins"],countries:[{name:"Afghanistan",abbreviation:"AF"},{name:"Albania",abbreviation:"AL"},{name:"Algeria",abbreviation:"DZ"},{name:"American Samoa",abbreviation:"AS"},{name:"Andorra",abbreviation:"AD"},{name:"Angola",abbreviation:"AO"},{name:"Anguilla",abbreviation:"AI"},{name:"Antarctica",abbreviation:"AQ"},{name:"Antigua and Barbuda",abbreviation:"AG"},{name:"Argentina",abbreviation:"AR"},{name:"Armenia",abbreviation:"AM"},{name:"Aruba",abbreviation:"AW"},{name:"Australia",abbreviation:"AU"},{name:"Austria",abbreviation:"AT"},{name:"Azerbaijan",abbreviation:"AZ"},{name:"Bahamas",abbreviation:"BS"},{name:"Bahrain",abbreviation:"BH"},{name:"Bangladesh",abbreviation:"BD"},{name:"Barbados",abbreviation:"BB"},{name:"Belarus",abbreviation:"BY"},{name:"Belgium",abbreviation:"BE"},{name:"Belize",abbreviation:"BZ"},{name:"Benin",abbreviation:"BJ"},{name:"Bermuda",abbreviation:"BM"},{name:"Bhutan",abbreviation:"BT"},{name:"Bolivia",abbreviation:"BO"},{name:"Bosnia and Herzegovina",abbreviation:"BA"},{name:"Botswana",abbreviation:"BW"},{name:"Bouvet Island",abbreviation:"BV"},{name:"Brazil",abbreviation:"BR"},{name:"British Antarctic Territory",abbreviation:"BQ"},{name:"British Indian Ocean Territory",abbreviation:"IO"},{name:"British Virgin Islands",abbreviation:"VG"},{name:"Brunei",abbreviation:"BN"},{name:"Bulgaria",abbreviation:"BG"},{name:"Burkina Faso",abbreviation:"BF"},{name:"Burundi",abbreviation:"BI"},{name:"Cambodia",abbreviation:"KH"},{name:"Cameroon",abbreviation:"CM"},{name:"Canada",abbreviation:"CA"},{name:"Canton and Enderbury Islands",abbreviation:"CT"},{name:"Cape Verde",abbreviation:"CV"},{name:"Cayman Islands",abbreviation:"KY"},{name:"Central African Republic",abbreviation:"CF"},{name:"Chad",abbreviation:"TD"},{name:"Chile",abbreviation:"CL"},{name:"China",abbreviation:"CN"},{name:"Christmas Island",abbreviation:"CX"},{name:"Cocos [Keeling] Islands",abbreviation:"CC"},{name:"Colombia",abbreviation:"CO"},{name:"Comoros",abbreviation:"KM"},{name:"Congo - Brazzaville",abbreviation:"CG"},{name:"Congo - Kinshasa",abbreviation:"CD"},{name:"Cook Islands",abbreviation:"CK"},{name:"Costa Rica",abbreviation:"CR"},{name:"Croatia",abbreviation:"HR"},{name:"Cuba",abbreviation:"CU"},{name:"Cyprus",abbreviation:"CY"},{name:"Czech Republic",abbreviation:"CZ"},{name:"Côte d’Ivoire",abbreviation:"CI"},{name:"Denmark",abbreviation:"DK"},{name:"Djibouti",abbreviation:"DJ"},{name:"Dominica",abbreviation:"DM"},{name:"Dominican Republic",abbreviation:"DO"},{name:"Dronning Maud Land",abbreviation:"NQ"},{name:"East Germany",abbreviation:"DD"},{name:"Ecuador",abbreviation:"EC"},{name:"Egypt",abbreviation:"EG"},{name:"El Salvador",abbreviation:"SV"},{name:"Equatorial Guinea",abbreviation:"GQ"},{name:"Eritrea",abbreviation:"ER"},{name:"Estonia",abbreviation:"EE"},{name:"Ethiopia",abbreviation:"ET"},{name:"Falkland Islands",abbreviation:"FK"},{name:"Faroe Islands",abbreviation:"FO"},{name:"Fiji",abbreviation:"FJ"},{name:"Finland",abbreviation:"FI"},{name:"France",abbreviation:"FR"},{name:"French Guiana",abbreviation:"GF"},{name:"French Polynesia",abbreviation:"PF"},{name:"French Southern Territories",abbreviation:"TF"},{name:"French Southern and Antarctic Territories",abbreviation:"FQ"},{name:"Gabon",abbreviation:"GA"},{name:"Gambia",abbreviation:"GM"},{name:"Georgia",abbreviation:"GE"},{name:"Germany",abbreviation:"DE"},{name:"Ghana",abbreviation:"GH"},{name:"Gibraltar",abbreviation:"GI"},{name:"Greece",abbreviation:"GR"},{name:"Greenland",abbreviation:"GL"},{name:"Grenada",abbreviation:"GD"},{name:"Guadeloupe",abbreviation:"GP"},{name:"Guam",abbreviation:"GU"},{name:"Guatemala",abbreviation:"GT"},{name:"Guernsey",abbreviation:"GG"},{name:"Guinea",abbreviation:"GN"},{name:"Guinea-Bissau",abbreviation:"GW"},{name:"Guyana",abbreviation:"GY"},{name:"Haiti",abbreviation:"HT"},{name:"Heard Island and McDonald Islands",abbreviation:"HM"},{name:"Honduras",abbreviation:"HN"},{name:"Hong Kong SAR China",abbreviation:"HK"},{name:"Hungary",abbreviation:"HU"},{name:"Iceland",abbreviation:"IS"},{name:"India",abbreviation:"IN"},{name:"Indonesia",abbreviation:"ID"},{name:"Iran",abbreviation:"IR"},{name:"Iraq",abbreviation:"IQ"},{name:"Ireland",abbreviation:"IE"},{name:"Isle of Man",abbreviation:"IM"},{name:"Israel",abbreviation:"IL"},{name:"Italy",abbreviation:"IT"},{name:"Jamaica",abbreviation:"JM"},{name:"Japan",abbreviation:"JP"},{name:"Jersey",abbreviation:"JE"},{name:"Johnston Island",abbreviation:"JT"},{name:"Jordan",abbreviation:"JO"},{name:"Kazakhstan",abbreviation:"KZ"},{name:"Kenya",abbreviation:"KE"},{name:"Kiribati",abbreviation:"KI"},{name:"Kuwait",abbreviation:"KW"},{name:"Kyrgyzstan",abbreviation:"KG"},{name:"Laos",abbreviation:"LA"},{name:"Latvia",abbreviation:"LV"},{name:"Lebanon",abbreviation:"LB"},{name:"Lesotho",abbreviation:"LS"},{name:"Liberia",abbreviation:"LR"},{name:"Libya",abbreviation:"LY"},{name:"Liechtenstein",abbreviation:"LI"},{name:"Lithuania",abbreviation:"LT"},{name:"Luxembourg",abbreviation:"LU"},{name:"Macau SAR China",abbreviation:"MO"},{name:"Macedonia",abbreviation:"MK"},{name:"Madagascar",abbreviation:"MG"},{name:"Malawi",abbreviation:"MW"},{name:"Malaysia",abbreviation:"MY"},{name:"Maldives",abbreviation:"MV"},{name:"Mali",abbreviation:"ML"},{name:"Malta",abbreviation:"MT"},{name:"Marshall Islands",abbreviation:"MH"},{name:"Martinique",abbreviation:"MQ"},{name:"Mauritania",abbreviation:"MR"},{name:"Mauritius",abbreviation:"MU"},{name:"Mayotte",abbreviation:"YT"},{name:"Metropolitan France",abbreviation:"FX"},{name:"Mexico",abbreviation:"MX"},{name:"Micronesia",abbreviation:"FM"},{name:"Midway Islands",abbreviation:"MI"},{name:"Moldova",abbreviation:"MD"},{name:"Monaco",abbreviation:"MC"},{name:"Mongolia",abbreviation:"MN"},{name:"Montenegro",abbreviation:"ME"},{name:"Montserrat",abbreviation:"MS"},{name:"Morocco",abbreviation:"MA"},{name:"Mozambique",abbreviation:"MZ"},{name:"Myanmar [Burma]",abbreviation:"MM"},{name:"Namibia",abbreviation:"NA"},{name:"Nauru",abbreviation:"NR"},{name:"Nepal",abbreviation:"NP"},{name:"Netherlands",abbreviation:"NL"},{name:"Netherlands Antilles",abbreviation:"AN"},{name:"Neutral Zone",abbreviation:"NT"},{name:"New Caledonia",abbreviation:"NC"},{name:"New Zealand",abbreviation:"NZ"},{name:"Nicaragua",abbreviation:"NI"},{name:"Niger",abbreviation:"NE"},{name:"Nigeria",abbreviation:"NG"},{name:"Niue",abbreviation:"NU"},{name:"Norfolk Island",abbreviation:"NF"},{name:"North Korea",abbreviation:"KP"},{name:"North Vietnam",abbreviation:"VD"},{name:"Northern Mariana Islands",abbreviation:"MP"},{name:"Norway",abbreviation:"NO"},{name:"Oman",abbreviation:"OM"},{name:"Pacific Islands Trust Territory",abbreviation:"PC"},{name:"Pakistan",abbreviation:"PK"},{name:"Palau",abbreviation:"PW"},{name:"Palestinian Territories",abbreviation:"PS"},{name:"Panama",abbreviation:"PA"},{name:"Panama Canal Zone",abbreviation:"PZ"},{name:"Papua New Guinea",abbreviation:"PG"},{name:"Paraguay",abbreviation:"PY"},{name:"People's Democratic Republic of Yemen",abbreviation:"YD"},{name:"Peru",abbreviation:"PE"},{name:"Philippines",abbreviation:"PH"},{name:"Pitcairn Islands",abbreviation:"PN"},{name:"Poland",abbreviation:"PL"},{name:"Portugal",abbreviation:"PT"},{name:"Puerto Rico",abbreviation:"PR"},{name:"Qatar",abbreviation:"QA"},{name:"Romania",abbreviation:"RO"},{name:"Russia",abbreviation:"RU"},{name:"Rwanda",abbreviation:"RW"},{name:"Réunion",abbreviation:"RE"},{name:"Saint Barthélemy",abbreviation:"BL"},{name:"Saint Helena",abbreviation:"SH"},{name:"Saint Kitts and Nevis",abbreviation:"KN"},{name:"Saint Lucia",abbreviation:"LC"},{name:"Saint Martin",abbreviation:"MF"},{name:"Saint Pierre and Miquelon",abbreviation:"PM"},{name:"Saint Vincent and the Grenadines",abbreviation:"VC"},{name:"Samoa",abbreviation:"WS"},{name:"San Marino",abbreviation:"SM"},{name:"Saudi Arabia",abbreviation:"SA"},{name:"Senegal",abbreviation:"SN"},{name:"Serbia",abbreviation:"RS"},{name:"Serbia and Montenegro",abbreviation:"CS"},{name:"Seychelles",abbreviation:"SC"},{name:"Sierra Leone",abbreviation:"SL"},{name:"Singapore",abbreviation:"SG"},{name:"Slovakia",abbreviation:"SK"},{name:"Slovenia",abbreviation:"SI"},{name:"Solomon Islands",abbreviation:"SB"},{name:"Somalia",abbreviation:"SO"},{name:"South Africa",abbreviation:"ZA"},{name:"South Georgia and the South Sandwich Islands",abbreviation:"GS"},{name:"South Korea",abbreviation:"KR"},{name:"Spain",abbreviation:"ES"},{name:"Sri Lanka",abbreviation:"LK"},{name:"Sudan",abbreviation:"SD"},{name:"Suriname",abbreviation:"SR"},{name:"Svalbard and Jan Mayen",abbreviation:"SJ"},{name:"Swaziland",abbreviation:"SZ"},{name:"Sweden",abbreviation:"SE"},{name:"Switzerland",abbreviation:"CH"},{name:"Syria",abbreviation:"SY"},{name:"São Tomé and Príncipe",abbreviation:"ST"},{name:"Taiwan",abbreviation:"TW"},{name:"Tajikistan",abbreviation:"TJ"},{name:"Tanzania",abbreviation:"TZ"},{name:"Thailand",abbreviation:"TH"},{name:"Timor-Leste",abbreviation:"TL"},{name:"Togo",abbreviation:"TG"},{name:"Tokelau",abbreviation:"TK"},{name:"Tonga",abbreviation:"TO"},{name:"Trinidad and Tobago",abbreviation:"TT"},{name:"Tunisia",abbreviation:"TN"},{name:"Turkey",abbreviation:"TR"},{name:"Turkmenistan",abbreviation:"TM"},{name:"Turks and Caicos Islands",abbreviation:"TC"},{name:"Tuvalu",abbreviation:"TV"},{name:"U.S. Minor Outlying Islands",abbreviation:"UM"},{name:"U.S. Miscellaneous Pacific Islands",abbreviation:"PU"},{name:"U.S. Virgin Islands",abbreviation:"VI"},{name:"Uganda",abbreviation:"UG"},{name:"Ukraine",abbreviation:"UA"},{name:"Union of Soviet Socialist Republics",abbreviation:"SU"},{name:"United Arab Emirates",abbreviation:"AE"},{name:"United Kingdom",abbreviation:"GB"},{name:"United States",abbreviation:"US"},{name:"Unknown or Invalid Region",abbreviation:"ZZ"},{name:"Uruguay",abbreviation:"UY"},{name:"Uzbekistan",abbreviation:"UZ"},{name:"Vanuatu",abbreviation:"VU"},{name:"Vatican City",abbreviation:"VA"},{name:"Venezuela",abbreviation:"VE"},{name:"Vietnam",abbreviation:"VN"},{name:"Wake Island",abbreviation:"WK"},{name:"Wallis and Futuna",abbreviation:"WF"},{name:"Western Sahara",abbreviation:"EH"},{name:"Yemen",abbreviation:"YE"},{name:"Zambia",abbreviation:"ZM"},{name:"Zimbabwe",abbreviation:"ZW"},{name:"Åland Islands",abbreviation:"AX"}],provinces:[{name:"Alberta",abbreviation:"AB"},{name:"British Columbia",abbreviation:"BC"},{name:"Manitoba",abbreviation:"MB"},{name:"New Brunswick",abbreviation:"NB"},{name:"Newfoundland and Labrador",abbreviation:"NL"},{name:"Nova Scotia",abbreviation:"NS"},{name:"Ontario",abbreviation:"ON"},{name:"Prince Edward Island",abbreviation:"PE"},{name:"Quebec",abbreviation:"QC"},{name:"Saskatchewan",abbreviation:"SK"},{name:"Northwest Territories",abbreviation:"NT"},{name:"Nunavut",abbreviation:"NU"},{name:"Yukon",abbreviation:"YT"}],us_states_and_dc:[{name:"Alabama",abbreviation:"AL"},{name:"Alaska",abbreviation:"AK"},{name:"Arizona",abbreviation:"AZ"},{name:"Arkansas",abbreviation:"AR"},{name:"California",abbreviation:"CA"},{name:"Colorado",abbreviation:"CO"},{name:"Connecticut",abbreviation:"CT"},{name:"Delaware",abbreviation:"DE"},{name:"District of Columbia",abbreviation:"DC"},{name:"Florida",abbreviation:"FL"},{name:"Georgia",abbreviation:"GA"},{name:"Hawaii",abbreviation:"HI"},{name:"Idaho",abbreviation:"ID"},{name:"Illinois",abbreviation:"IL"},{name:"Indiana",abbreviation:"IN"},{name:"Iowa",abbreviation:"IA"},{name:"Kansas",abbreviation:"KS"},{name:"Kentucky",abbreviation:"KY"},{name:"Louisiana",abbreviation:"LA"},{name:"Maine",abbreviation:"ME"},{name:"Maryland",abbreviation:"MD"},{name:"Massachusetts",abbreviation:"MA"},{name:"Michigan",abbreviation:"MI"},{name:"Minnesota",abbreviation:"MN"},{name:"Mississippi",abbreviation:"MS"},{name:"Missouri",abbreviation:"MO"},{name:"Montana",abbreviation:"MT"},{name:"Nebraska",abbreviation:"NE"},{name:"Nevada",abbreviation:"NV"},{name:"New Hampshire",abbreviation:"NH"},{name:"New Jersey",abbreviation:"NJ"},{name:"New Mexico",abbreviation:"NM"},{name:"New York",abbreviation:"NY"},{name:"North Carolina",abbreviation:"NC"},{name:"North Dakota",abbreviation:"ND"},{name:"Ohio",abbreviation:"OH"},{name:"Oklahoma",abbreviation:"OK"},{name:"Oregon",abbreviation:"OR"},{name:"Pennsylvania",abbreviation:"PA"},{name:"Rhode Island",abbreviation:"RI"},{name:"South Carolina",abbreviation:"SC"},{name:"South Dakota",abbreviation:"SD"},{name:"Tennessee",abbreviation:"TN"},{name:"Texas",abbreviation:"TX"},{name:"Utah",abbreviation:"UT"},{name:"Vermont",abbreviation:"VT"},{name:"Virginia",abbreviation:"VA"},{name:"Washington",abbreviation:"WA"},{name:"West Virginia",abbreviation:"WV"},{name:"Wisconsin",abbreviation:"WI"},{name:"Wyoming",abbreviation:"WY"}],territories:[{name:"American Samoa",abbreviation:"AS"},{name:"Federated States of Micronesia",abbreviation:"FM"},{name:"Guam",abbreviation:"GU"},{name:"Marshall Islands",abbreviation:"MH"},{name:"Northern Mariana Islands",abbreviation:"MP"},{name:"Puerto Rico",abbreviation:"PR"},{name:"Virgin Islands, U.S.",abbreviation:"VI"}],armed_forces:[{name:"Armed Forces Europe",abbreviation:"AE"},{name:"Armed Forces Pacific",abbreviation:"AP"},{name:"Armed Forces the Americas",abbreviation:"AA"}],street_suffixes:[{name:"Avenue",abbreviation:"Ave"},{name:"Boulevard",abbreviation:"Blvd"},{name:"Center",abbreviation:"Ctr"},{name:"Circle",abbreviation:"Cir"},{name:"Court",abbreviation:"Ct"},{name:"Drive",abbreviation:"Dr"},{name:"Extension",abbreviation:"Ext"},{name:"Glen",abbreviation:"Gln"},{name:"Grove",abbreviation:"Grv"},{name:"Heights",abbreviation:"Hts"},{name:"Highway",abbreviation:"Hwy"},{name:"Junction",abbreviation:"Jct"},{name:"Key",abbreviation:"Key"},{name:"Lane",abbreviation:"Ln"},{name:"Loop",abbreviation:"Loop"},{name:"Manor",abbreviation:"Mnr"},{name:"Mill",abbreviation:"Mill"},{name:"Park",abbreviation:"Park"},{name:"Parkway",abbreviation:"Pkwy"},{name:"Pass",abbreviation:"Pass"},{name:"Path",abbreviation:"Path"},{name:"Pike",abbreviation:"Pike"},{name:"Place",abbreviation:"Pl"},{name:"Plaza",abbreviation:"Plz"},{name:"Point",abbreviation:"Pt"},{name:"Ridge",abbreviation:"Rdg"},{name:"River",abbreviation:"Riv"},{name:"Road",abbreviation:"Rd"},{name:"Square",abbreviation:"Sq"},{name:"Street",abbreviation:"St"},{name:"Terrace",abbreviation:"Ter"},{name:"Trail",abbreviation:"Trl"},{name:"Turnpike",abbreviation:"Tpke"},{name:"View",abbreviation:"Vw"},{name:"Way",abbreviation:"Way"}],months:[{name:"January",short_name:"Jan",numeric:"01",days:31},{name:"February",short_name:"Feb",numeric:"02",days:28},{name:"March",short_name:"Mar",numeric:"03",days:31},{name:"April",short_name:"Apr",numeric:"04",days:30},{name:"May",short_name:"May",numeric:"05",days:31},{name:"June",short_name:"Jun",numeric:"06",days:30},{name:"July",short_name:"Jul",numeric:"07",days:31},{name:"August",short_name:"Aug",numeric:"08",days:31},{name:"September",short_name:"Sep",numeric:"09",days:30},{name:"October",short_name:"Oct",numeric:"10",days:31},{name:"November",short_name:"Nov",numeric:"11",days:30},{name:"December",short_name:"Dec",numeric:"12",days:31}],cc_types:[{name:"American Express",short_name:"amex",prefix:"34",length:15},{name:"Bankcard",short_name:"bankcard",prefix:"5610",length:16},{name:"China UnionPay",short_name:"chinaunion",prefix:"62",length:16},{name:"Diners Club Carte Blanche",short_name:"dccarte",prefix:"300",length:14},{name:"Diners Club enRoute",short_name:"dcenroute",prefix:"2014",length:15},{name:"Diners Club International",short_name:"dcintl",prefix:"36",length:14},{name:"Diners Club United States & Canada",short_name:"dcusc",prefix:"54",length:16},{name:"Discover Card",short_name:"discover",prefix:"6011",length:16},{name:"InstaPayment",short_name:"instapay",prefix:"637",length:16},{name:"JCB",short_name:"jcb",prefix:"3528",length:16},{name:"Laser",short_name:"laser",prefix:"6304",length:16},{name:"Maestro",short_name:"maestro",prefix:"5018",length:16},{name:"Mastercard",short_name:"mc",prefix:"51",length:16},{name:"Solo",short_name:"solo",prefix:"6334",length:16},{name:"Switch",short_name:"switch",prefix:"4903",length:16},{name:"Visa",short_name:"visa",prefix:"4",length:16},{name:"Visa Electron",short_name:"electron",prefix:"4026",length:16}],currency_types:[{code:"AED",name:"United Arab Emirates Dirham"},{code:"AFN",name:"Afghanistan Afghani"},{code:"ALL",name:"Albania Lek"},{code:"AMD",name:"Armenia Dram"},{code:"ANG",name:"Netherlands Antilles Guilder"},{code:"AOA",name:"Angola Kwanza"},{code:"ARS",name:"Argentina Peso"},{code:"AUD",name:"Australia Dollar"},{code:"AWG",name:"Aruba Guilder"},{code:"AZN",name:"Azerbaijan New Manat"},{code:"BAM",name:"Bosnia and Herzegovina Convertible Marka"},{code:"BBD",name:"Barbados Dollar"},{code:"BDT",name:"Bangladesh Taka"},{code:"BGN",name:"Bulgaria Lev"},{code:"BHD",name:"Bahrain Dinar"},{code:"BIF",name:"Burundi Franc"},{code:"BMD",name:"Bermuda Dollar"},{code:"BND",name:"Brunei Darussalam Dollar"},{code:"BOB",name:"Bolivia Boliviano"},{code:"BRL",name:"Brazil Real"},{code:"BSD",name:"Bahamas Dollar"},{code:"BTN",name:"Bhutan Ngultrum"},{code:"BWP",name:"Botswana Pula"},{code:"BYR",name:"Belarus Ruble"},{code:"BZD",name:"Belize Dollar"},{code:"CAD",name:"Canada Dollar"},{code:"CDF",name:"Congo/Kinshasa Franc"},{code:"CHF",name:"Switzerland Franc"},{code:"CLP",name:"Chile Peso"},{code:"CNY",name:"China Yuan Renminbi"},{code:"COP",name:"Colombia Peso"},{code:"CRC",name:"Costa Rica Colon"},{code:"CUC",name:"Cuba Convertible Peso"},{code:"CUP",name:"Cuba Peso"},{code:"CVE",name:"Cape Verde Escudo"},{code:"CZK",name:"Czech Republic Koruna"},{code:"DJF",name:"Djibouti Franc"},{code:"DKK",name:"Denmark Krone"},{code:"DOP",name:"Dominican Republic Peso"},{code:"DZD",name:"Algeria Dinar"},{code:"EGP",name:"Egypt Pound"},{code:"ERN",name:"Eritrea Nakfa"},{code:"ETB",name:"Ethiopia Birr"},{code:"EUR",name:"Euro Member Countries"},{code:"FJD",name:"Fiji Dollar"},{code:"FKP",name:"Falkland Islands (Malvinas) Pound"},{code:"GBP",name:"United Kingdom Pound"},{code:"GEL",name:"Georgia Lari"},{code:"GGP",name:"Guernsey Pound"},{code:"GHS",name:"Ghana Cedi"},{code:"GIP",name:"Gibraltar Pound"},{code:"GMD",name:"Gambia Dalasi"},{code:"GNF",name:"Guinea Franc"},{code:"GTQ",name:"Guatemala Quetzal"},{code:"GYD",name:"Guyana Dollar"},{code:"HKD",name:"Hong Kong Dollar"},{code:"HNL",name:"Honduras Lempira"},{code:"HRK",name:"Croatia Kuna"},{code:"HTG",name:"Haiti Gourde"},{code:"HUF",name:"Hungary Forint"},{code:"IDR",name:"Indonesia Rupiah"},{code:"ILS",name:"Israel Shekel"},{code:"IMP",name:"Isle of Man Pound"},{code:"INR",name:"India Rupee"},{code:"IQD",name:"Iraq Dinar"},{code:"IRR",name:"Iran Rial"},{code:"ISK",name:"Iceland Krona"},{code:"JEP",name:"Jersey Pound"},{code:"JMD",name:"Jamaica Dollar"},{code:"JOD",name:"Jordan Dinar"},{code:"JPY",name:"Japan Yen"},{code:"KES",name:"Kenya Shilling"},{code:"KGS",name:"Kyrgyzstan Som"},{code:"KHR",name:"Cambodia Riel"},{code:"KMF",name:"Comoros Franc"},{code:"KPW",name:"Korea (North) Won"},{code:"KRW",name:"Korea (South) Won"},{code:"KWD",name:"Kuwait Dinar"},{code:"KYD",name:"Cayman Islands Dollar"},{code:"KZT",name:"Kazakhstan Tenge"},{code:"LAK",name:"Laos Kip"},{code:"LBP",name:"Lebanon Pound"},{code:"LKR",name:"Sri Lanka Rupee"},{code:"LRD",name:"Liberia Dollar"},{code:"LSL",name:"Lesotho Loti"},{code:"LTL",name:"Lithuania Litas"},{code:"LYD",name:"Libya Dinar"},{code:"MAD",name:"Morocco Dirham"},{code:"MDL",name:"Moldova Leu"},{code:"MGA",name:"Madagascar Ariary"},{code:"MKD",name:"Macedonia Denar"},{code:"MMK",name:"Myanmar (Burma) Kyat"},{code:"MNT",name:"Mongolia Tughrik"},{code:"MOP",name:"Macau Pataca"},{code:"MRO",name:"Mauritania Ouguiya"},{code:"MUR",name:"Mauritius Rupee"},{code:"MVR",name:"Maldives (Maldive Islands) Rufiyaa"},{code:"MWK",name:"Malawi Kwacha"},{code:"MXN",name:"Mexico Peso"},{code:"MYR",name:"Malaysia Ringgit"},{code:"MZN",name:"Mozambique Metical"},{code:"NAD",name:"Namibia Dollar"},{code:"NGN",name:"Nigeria Naira"},{code:"NIO",name:"Nicaragua Cordoba"},{code:"NOK",name:"Norway Krone"},{code:"NPR",name:"Nepal Rupee"},{code:"NZD",name:"New Zealand Dollar"},{code:"OMR",name:"Oman Rial"},{code:"PAB",name:"Panama Balboa"},{code:"PEN",name:"Peru Nuevo Sol"},{code:"PGK",name:"Papua New Guinea Kina"},{code:"PHP",name:"Philippines Peso"},{code:"PKR",name:"Pakistan Rupee"},{code:"PLN",name:"Poland Zloty"},{code:"PYG",name:"Paraguay Guarani"},{code:"QAR",name:"Qatar Riyal"},{code:"RON",name:"Romania New Leu"},{code:"RSD",name:"Serbia Dinar"},{code:"RUB",name:"Russia Ruble"},{code:"RWF",name:"Rwanda Franc"},{code:"SAR",name:"Saudi Arabia Riyal"},{code:"SBD",name:"Solomon Islands Dollar"},{code:"SCR",name:"Seychelles Rupee"},{code:"SDG",name:"Sudan Pound"},{code:"SEK",name:"Sweden Krona"},{code:"SGD",name:"Singapore Dollar"},{code:"SHP",name:"Saint Helena Pound"},{code:"SLL",name:"Sierra Leone Leone"},{code:"SOS",name:"Somalia Shilling"},{code:"SPL",name:"Seborga Luigino"},{code:"SRD",name:"Suriname Dollar"},{code:"STD",name:"São Tomé and Príncipe Dobra"},{code:"SVC",name:"El Salvador Colon"},{code:"SYP",name:"Syria Pound"},{code:"SZL",name:"Swaziland Lilangeni"},{code:"THB",name:"Thailand Baht"},{code:"TJS",name:"Tajikistan Somoni"},{code:"TMT",name:"Turkmenistan Manat"},{code:"TND",name:"Tunisia Dinar"},{code:"TOP",name:"Tonga Pa'anga"},{code:"TRY",name:"Turkey Lira"},{code:"TTD",name:"Trinidad and Tobago Dollar"},{code:"TVD",name:"Tuvalu Dollar"},{code:"TWD",name:"Taiwan New Dollar"},{code:"TZS",name:"Tanzania Shilling"},{code:"UAH",name:"Ukraine Hryvnia"},{code:"UGX",name:"Uganda Shilling"},{code:"USD",name:"United States Dollar"},{code:"UYU",name:"Uruguay Peso"},{code:"UZS",name:"Uzbekistan Som"},{code:"VEF",name:"Venezuela Bolivar"},{code:"VND",name:"Viet Nam Dong"},{code:"VUV",name:"Vanuatu Vatu"},{code:"WST",name:"Samoa Tala"},{code:"XAF",name:"Communauté Financière Africaine (BEAC) CFA Franc BEAC"},{code:"XCD",name:"East Caribbean Dollar"},{code:"XDR",name:"International Monetary Fund (IMF) Special Drawing Rights"},{code:"XOF",name:"Communauté Financière Africaine (BCEAO) Franc"},{code:"XPF",name:"Comptoirs Français du Pacifique (CFP) Franc"},{code:"YER",name:"Yemen Rial"},{code:"ZAR",name:"South Africa Rand"},{code:"ZMW",name:"Zambia Kwacha"},{code:"ZWD",name:"Zimbabwe Dollar"}]},v=Object.prototype.hasOwnProperty,y=Object.keys||function(a){var e=[];
+for(var n in a)v.call(a,n)&&e.push(n);return e};a.prototype.get=function(a){return o(p[a])},a.prototype.mac_address=function(a){a=e(a),a.separator||(a.separator=a.networkVersion?".":":");var n="ABCDEF1234567890",i="";return i=a.networkVersion?this.n(this.string,3,{pool:n,length:4}).join(a.separator):this.n(this.string,6,{pool:n,length:2}).join(a.separator)},a.prototype.normal=function(a){a=e(a,{mean:0,dev:1});var n,i,t,r,o=a.mean,s=a.dev;do i=2*this.random()-1,t=2*this.random()-1,n=i*i+t*t;while(n>=1);return r=i*Math.sqrt(-2*Math.log(n)/n),s*r+o},a.prototype.radio=function(a){a=e(a,{side:"?"});var n="";switch(a.side.toLowerCase()){case"east":case"e":n="W";break;case"west":case"w":n="K";break;default:n=this.character({pool:"KW"})}return n+this.character({alpha:!0,casing:"upper"})+this.character({alpha:!0,casing:"upper"})+this.character({alpha:!0,casing:"upper"})},a.prototype.set=function(a,e){"string"==typeof a?p[a]=e:p=o(a,p)},a.prototype.tv=function(a){return this.radio(a)},a.prototype.cnpj=function(){var a=this.n(this.natural,8,{max:9}),e=2+6*a[7]+7*a[6]+8*a[5]+9*a[4]+2*a[3]+3*a[2]+4*a[1]+5*a[0];e=11-e%11,e>=10&&(e=0);var n=2*e+3+7*a[7]+8*a[6]+9*a[5]+2*a[4]+3*a[3]+4*a[2]+5*a[1]+6*a[0];return n=11-n%11,n>=10&&(n=0),""+a[0]+a[1]+"."+a[2]+a[3]+a[4]+"."+a[5]+a[6]+a[7]+"/0001-"+e+n},a.prototype.mersenne_twister=function(a){return new g(a)};var g=function(a){void 0===a&&(a=(new Date).getTime()),this.N=624,this.M=397,this.MATRIX_A=2567483615,this.UPPER_MASK=2147483648,this.LOWER_MASK=2147483647,this.mt=new Array(this.N),this.mti=this.N+1,this.init_genrand(a)};g.prototype.init_genrand=function(a){for(this.mt[0]=a>>>0,this.mti=1;this.mti<this.N;this.mti++)a=this.mt[this.mti-1]^this.mt[this.mti-1]>>>30,this.mt[this.mti]=(1812433253*((4294901760&a)>>>16)<<16)+1812433253*(65535&a)+this.mti,this.mt[this.mti]>>>=0},g.prototype.init_by_array=function(a,e){var n,i,t=1,r=0;for(this.init_genrand(19650218),n=this.N>e?this.N:e;n;n--)i=this.mt[t-1]^this.mt[t-1]>>>30,this.mt[t]=(this.mt[t]^(1664525*((4294901760&i)>>>16)<<16)+1664525*(65535&i))+a[r]+r,this.mt[t]>>>=0,t++,r++,t>=this.N&&(this.mt[0]=this.mt[this.N-1],t=1),r>=e&&(r=0);for(n=this.N-1;n;n--)i=this.mt[t-1]^this.mt[t-1]>>>30,this.mt[t]=(this.mt[t]^(1566083941*((4294901760&i)>>>16)<<16)+1566083941*(65535&i))-t,this.mt[t]>>>=0,t++,t>=this.N&&(this.mt[0]=this.mt[this.N-1],t=1);this.mt[0]=2147483648},g.prototype.genrand_int32=function(){var a,e=new Array(0,this.MATRIX_A);if(this.mti>=this.N){var n;for(this.mti===this.N+1&&this.init_genrand(5489),n=0;n<this.N-this.M;n++)a=this.mt[n]&this.UPPER_MASK|this.mt[n+1]&this.LOWER_MASK,this.mt[n]=this.mt[n+this.M]^a>>>1^e[1&a];for(;n<this.N-1;n++)a=this.mt[n]&this.UPPER_MASK|this.mt[n+1]&this.LOWER_MASK,this.mt[n]=this.mt[n+(this.M-this.N)]^a>>>1^e[1&a];a=this.mt[this.N-1]&this.UPPER_MASK|this.mt[0]&this.LOWER_MASK,this.mt[this.N-1]=this.mt[this.M-1]^a>>>1^e[1&a],this.mti=0}return a=this.mt[this.mti++],a^=a>>>11,a^=a<<7&2636928640,a^=a<<15&4022730752,a^=a>>>18,a>>>0},g.prototype.genrand_int31=function(){return this.genrand_int32()>>>1},g.prototype.genrand_real1=function(){return this.genrand_int32()*(1/4294967295)},g.prototype.random=function(){return this.genrand_int32()*(1/4294967296)},g.prototype.genrand_real3=function(){return(this.genrand_int32()+.5)*(1/4294967296)},g.prototype.genrand_res53=function(){var a=this.genrand_int32()>>>5,e=this.genrand_int32()>>>6;return(67108864*a+e)*(1/9007199254740992)},"undefined"!=typeof exports&&("undefined"!=typeof module&&module.exports&&(exports=module.exports=a),exports.Chance=a),"function"==typeof define&&define.amd&&define([],function(){return a}),"undefined"!=typeof importScripts&&(chance=new a),"object"==typeof window&&"object"==typeof window.document&&(window.Chance=a,window.chance=new a)}()}();
+
+!function(){require=function t(e,n,r){function i(a,f){if(!n[a]){if(!e[a]){var u="function"==typeof require&&require;if(!f&&u)return u(a,!0);if(o)return o(a,!0);var s=new Error("Cannot find module '"+a+"'");throw s.code="MODULE_NOT_FOUND",s}var c=n[a]={exports:{}};e[a][0].call(c.exports,function(t){var n=e[a][1][t];return i(n?n:t)},c,c.exports,t,e,n,r)}return n[a].exports}for(var o="function"==typeof require&&require,a=0;a<r.length;a++)i(r[a]);return i}({1:[function(t,e,n){var r=t("./web3");BigNumber.config({ROUNDING_MODE:BigNumber.ROUND_DOWN});var i=32,o=4,a=function(t,e){for(var n=!1,r=0;r<t.length&&!n;r++)n=e(t[r]);return n?r-1:-1},f=function(t,e){return a(t,function(t){return t.name===e})},u=function(t,e){var n=f(t,e);return-1===n?void console.error("method "+e+" not found in the abi"):t[n]},s=function(t,e,n){return new Array(e-t.length+1).join(n?n:"0")+t},c=function(t){return function(e){return 0===e.indexOf(t)}},l=function(t){return function(e){return t===e}},h=function(t){return"[]"===t.slice(-2)},p=function(t){var e=2*i;return t instanceof BigNumber||"number"==typeof t?("number"==typeof t&&(t=new BigNumber(t)),t=t.round(),t.lessThan(0)&&(t=new BigNumber("ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff",16).plus(t).plus(1)),t=t.toString(16)):t=0===t.indexOf("0x")?t.substr(2):"string"==typeof t?p(new BigNumber(t)):(+t).toString(16),s(t,e)},d=function(t){return r.fromAscii(t,i).substr(2)},m=function(t){return"000000000000000000000000000000000000000000000000000000000000000"+(t?"1":"0")},g=function(t){return p(new BigNumber(t).times(new BigNumber(2).pow(128)))},v=function(t,e){return h(t)||"string"===t?p(e.length):""},b=function(){return[{type:c("uint"),format:p},{type:c("int"),format:p},{type:c("hash"),format:p},{type:c("string"),format:d},{type:c("real"),format:g},{type:c("ureal"),format:g},{type:l("address"),format:p},{type:l("bool"),format:m}]},y=b(),_=function(t,e,n){var r="",o=u(t,e),a=2*i;return o.inputs.forEach(function(t,e){r+=v(t.type,n[e])}),o.inputs.forEach(function(t,e){for(var i=!1,a=0;a<y.length&&!i;a++)i=y[a].type(o.inputs[e].type,n[e]);i||console.error("input parser does not support type: "+o.inputs[e].type);var f=y[a-1].format,u="";u=h(o.inputs[e].type)?n[e].reduce(function(t,e){return t+f(e)},""):f(n[e]),r+=u}),r},w=function(t){return"1"===new BigNumber(t.substr(0,1),16).toString(2).substr(0,1)},N=function(t){return t=t||"0",w(t)?new BigNumber(t,16).minus(new BigNumber("ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff",16)).minus(1):new BigNumber(t,16)},x=function(t){return t=t||"0",new BigNumber(t,16)},B=function(t){return N(t).dividedBy(new BigNumber(2).pow(128))},A=function(t){return x(t).dividedBy(new BigNumber(2).pow(128))},S=function(t){return"0x"+t},O=function(t){return"0000000000000000000000000000000000000000000000000000000000000001"===t?!0:!1},P=function(t){return r.toAscii(t)},E=function(t){return"0x"+t.slice(t.length-40,t.length)},k=function(t){return h(t)||"string"===t?2*i:0},F=function(){return[{type:c("uint"),format:x},{type:c("int"),format:N},{type:c("hash"),format:S},{type:c("string"),format:P},{type:c("real"),format:B},{type:c("ureal"),format:A},{type:l("address"),format:E},{type:l("bool"),format:O}]},T=F(),M=function(t,e,n){n=n.slice(2);var r=[],o=u(t,e),a=2*i,f=o.outputs.reduce(function(t,e){return t+k(e.type)},0),s=n.slice(0,f);return n=n.slice(f),o.outputs.forEach(function(t,e){for(var i=!1,f=0;f<T.length&&!i;f++)i=T[f].type(o.outputs[e].type);i||console.error("output parser does not support type: "+o.outputs[e].type);var u=T[f-1].format;if(h(o.outputs[e].type)){var l=x(s.slice(0,a));s=s.slice(a);for(var p=[],d=0;l>d;d++)p.push(u(n.slice(0,a))),n=n.slice(a);r.push(p)}else c("string")(o.outputs[e].type)?(s=s.slice(a),r.push(u(n.slice(0,a))),n=n.slice(a)):(r.push(u(n.slice(0,a))),n=n.slice(a))}),r},D=function(t){var e=t.indexOf("(");return-1!==e?t.substr(0,e):t},C=function(t){var e=t.indexOf("(");return-1!==e?t.substr(e+1,t.length-1-(e+1)):""},q=function(t){var e={};return t.forEach(function(n){var r=D(n.name),i=C(n.name),o=function(){var e=Array.prototype.slice.call(arguments);return _(t,n.name,e)};void 0===e[r]&&(e[r]=o),e[r][i]=o}),e},I=function(t){var e={};return t.forEach(function(n){var r=D(n.name),i=C(n.name),o=function(e){return M(t,n.name,e)};void 0===e[r]&&(e[r]=o),e[r][i]=o}),e},G=function(t){return r.sha3(r.fromAscii(t)).slice(0,2+2*o)};e.exports={inputParser:q,outputParser:I,methodSignature:G,methodDisplayName:D,methodTypeName:C,getMethodWithName:u}},{"./web3":7}],2:[function(t,e,n){var r=t("./web3"),i=t("./abi"),o=function(t,e){e.forEach(function(t){if(-1===t.name.indexOf("(")){var e=t.name,n=t.inputs.map(function(t){return t.type}).join();t.name=e+"("+n+")"}});var n=i.inputParser(e),o=i.outputParser(e),a={};return a.call=function(t){return a._isTransact=!1,a._options=t,a},a.transact=function(t){return a._isTransact=!0,a._options=t,a},a._options={},["gas","gasPrice","value","from"].forEach(function(t){a[t]=function(e){return a._options[t]=e,a}}),e.forEach(function(f){var u=i.methodDisplayName(f.name),s=i.methodTypeName(f.name),c=function(){var c=Array.prototype.slice.call(arguments),l=i.methodSignature(f.name),h=n[u][s].apply(null,c),p=a._options||{};p.to=t,p.data=l+h;var d=a._isTransact===!0||a._isTransact!==!1&&!f.constant,m=p.collapse!==!1;if(a._options={},a._isTransact=null,d)return r._currentContractAbi=e,r._currentContractAddress=t,r._currentContractMethodName=f.name,r._currentContractMethodParams=c,void r.eth.transact(p);var g=r.eth.call(p),v=o[u][s](g);return m&&(1===v.length?v=v[0]:0===v.length&&(v=null)),v};void 0===a[u]&&(a[u]=c),a[u][s]=c}),a};e.exports=o},{"./abi":1,"./web3":7}],3:[function(t,e,n){var r=t("./web3"),i=function(t,e){this.impl=e,this.callbacks=[],this.id=e.newFilter(t),r.provider.startPolling({call:e.changed,args:[this.id]},this.id,this.trigger.bind(this))};i.prototype.arrived=function(t){this.changed(t)},i.prototype.changed=function(t){this.callbacks.push(t)},i.prototype.trigger=function(t){for(var e=0;e<this.callbacks.length;e++)for(var n=0;n<t.length;n++)this.callbacks[e].call(this,t[n])},i.prototype.uninstall=function(){this.impl.uninstallFilter(this.id),r.provider.stopPolling(this.id)},i.prototype.messages=function(){return this.impl.getMessages(this.id)},i.prototype.logs=function(){return this.messages()},e.exports=i},{"./web3":7}],4:[function(t,e,n){function r(t){return{jsonrpc:"2.0",method:t.call,params:t.args,id:t._id}}function i(t){var e=JSON.parse(t);return{_id:e.id,data:e.result,error:e.error}}var o=function(t){this.handlers=[],this.host=t||"http://localhost:8080"};o.prototype.send=function(t){var e=r(t),n=new XMLHttpRequest;return n.open("POST",this.host,!1),n.send(JSON.stringify(e)),n.responseText},e.exports=o},{}],5:[function(t,e,n){var r=t("./web3"),i=function(){this.polls=[],this.provider=void 0,this.id=1;var t=this,e=function(){t.provider&&t.polls.forEach(function(e){e.data._id=t.id,t.id++;var n=t.provider.send(e.data);n=JSON.parse(n),!n.error&&n.result instanceof Array&&0!==n.result.length&&e.callback(n.result)}),setTimeout(e,1e3)};e()};i.prototype.send=function(t){if(t.args=t.args||[],t._id=this.id++,void 0===this.provider)return console.error("provider is not set"),null;var e=this.provider.send(t);return e=JSON.parse(e),e.error?(console.log(e.error),null):e.result},i.prototype.set=function(t){this.provider=t},i.prototype.startPolling=function(t,e,n){this.polls.push({data:t,id:e,callback:n})},i.prototype.stopPolling=function(t){for(var e=this.polls.length;e--;){var n=this.polls[e];n.id===t&&this.polls.splice(e,1)}},e.exports=i},{"./web3":7}],6:[function(t,e,n){var r=function(){};r.prototype.send=function(t){return navigator.qt.callMethod(JSON.stringify(t))},e.exports=r},{}],7:[function(t,e,n){var r=["wei","Kwei","Mwei","Gwei","szabo","finney","ether","grand","Mether","Gether","Tether","Pether","Eether","Zether","Yether","Nether","Dether","Vether","Uether"],i=function(){return[{name:"sha3",call:"web3_sha3"}]},o=function(){var t=function(t){return"string"==typeof t[0]?"eth_blockByHash":"eth_blockByNumber"},e=function(t){return"string"==typeof t[0]?"eth_transactionByHash":"eth_transactionByNumber"},n=function(t){return"string"==typeof t[0]?"eth_uncleByHash":"eth_uncleByNumber"},r=[{name:"balanceAt",call:"eth_balanceAt"},{name:"stateAt",call:"eth_stateAt"},{name:"storageAt",call:"eth_storageAt"},{name:"countAt",call:"eth_countAt"},{name:"codeAt",call:"eth_codeAt"},{name:"transact",call:"eth_transact"},{name:"call",call:"eth_call"},{name:"block",call:t},{name:"transaction",call:e},{name:"uncle",call:n},{name:"compilers",call:"eth_compilers"},{name:"flush",call:"eth_flush"},{name:"lll",call:"eth_lll"},{name:"solidity",call:"eth_solidity"},{name:"serpent",call:"eth_serpent"},{name:"logs",call:"eth_logs"}];return r},a=function(){return[{name:"coinbase",getter:"eth_coinbase",setter:"eth_setCoinbase"},{name:"listening",getter:"eth_listening",setter:"eth_setListening"},{name:"mining",getter:"eth_mining",setter:"eth_setMining"},{name:"gasPrice",getter:"eth_gasPrice"},{name:"accounts",getter:"eth_accounts"},{name:"peerCount",getter:"eth_peerCount"},{name:"defaultBlock",getter:"eth_defaultBlock",setter:"eth_setDefaultBlock"},{name:"number",getter:"eth_number"}]},f=function(){return[{name:"put",call:"db_put"},{name:"get",call:"db_get"},{name:"putString",call:"db_putString"},{name:"getString",call:"db_getString"}]},u=function(){return[{name:"post",call:"shh_post"},{name:"newIdentity",call:"shh_newIdentity"},{name:"haveIdentity",call:"shh_haveIdentity"},{name:"newGroup",call:"shh_newGroup"},{name:"addToGroup",call:"shh_addToGroup"}]},s=function(){var t=function(t){return"string"==typeof t[0]?"eth_newFilterString":"eth_newFilter"};return[{name:"newFilter",call:t},{name:"uninstallFilter",call:"eth_uninstallFilter"},{name:"getMessages",call:"eth_filterLogs"}]},c=function(){return[{name:"newFilter",call:"shh_newFilter"},{name:"uninstallFilter",call:"shh_uninstallFilter"},{name:"getMessages",call:"shh_getMessages"}]},l=function(t,e){e.forEach(function(e){t[e.name]=function(){var t=Array.prototype.slice.call(arguments),n="function"==typeof e.call?e.call(t):e.call;return p.provider.send({call:n,args:t})}})},h=function(t,e){e.forEach(function(e){var n={};n.get=function(){return p.provider.send({call:e.getter})},e.setter&&(n.set=function(t){return p.provider.send({call:e.setter,args:[t]})}),Object.defineProperty(t,e.name,n)})},p={_callbacks:{},_events:{},providers:{},toHex:function(t){for(var e="",n=0;n<t.length;n++){var r=t.charCodeAt(n).toString(16);e+=r.length<2?"0"+r:r}return e},toAscii:function(t){var e="",n=0,r=t.length;for("0x"===t.substring(0,2)&&(n=2);r>n;n+=2){var i=parseInt(t.substr(n,2),16);if(0===i)break;e+=String.fromCharCode(i)}return e},fromAscii:function(t,e){e=void 0===e?0:e;for(var n=this.toHex(t);n.length<2*e;)n+="00";return"0x"+n},toDecimal:function(t){return t=t.length>2?t.substring(2):"0",new BigNumber(t,16).toString(10)},fromDecimal:function(t){return"0x"+new BigNumber(t).toString(16)},toEth:function(t){for(var e="string"==typeof t?0===t.indexOf("0x")?parseInt(t.substr(2),16):parseInt(t):t,n=0,i=r;e>3e3&&n<i.length-1;)e/=1e3,n++;for(var o=e.toString().length<e.toFixed(2).length?e.toString():e.toFixed(2),a=function(t,e,n){return e+","+n};;){var f=o;if(o=o.replace(/(\d)(\d\d\d[\.\,])/,a),f===o)break}return o+" "+i[n]},eth:{contractFromAbi:function(t){return function(e){e=e||"0xc6d9d2cd449a754c494264e1809c50e34d64562b";var n=p.eth.contract(e,t);return n.address=e,n}},watch:function(t){return new p.filter(t,d)}},db:{},shh:{watch:function(t){return new p.filter(t,m)}},haveProvider:function(){return!!p.provider.provider}};l(p,i()),l(p.eth,o()),h(p.eth,a()),l(p.db,f()),l(p.shh,u());var d={changed:"eth_changed"};l(d,s());var m={changed:"shh_changed"};l(m,c()),p.setProvider=function(t){p.provider.set(t)},e.exports=p},{}],web3:[function(t,e,n){var r=t("./lib/web3"),i=t("./lib/providermanager");r.provider=new i,r.filter=t("./lib/filter"),r.providers.HttpSyncProvider=t("./lib/httpsync"),r.providers.QtSyncProvider=t("./lib/qtsync"),r.eth.contract=t("./lib/contract"),r.abi=t("./lib/abi"),e.exports=r},{"./lib/abi":1,"./lib/contract":2,"./lib/filter":3,"./lib/httpsync":4,"./lib/providermanager":5,"./lib/qtsync":6,"./lib/web3":7}]},{},["web3"])}();
+
+!function(){!function(t){if("object"==typeof exports)module.exports=t();else if("function"==typeof define&&define.amd)define(t);else{var r;"undefined"!=typeof window?r=window:"undefined"!=typeof global?r=global:"undefined"!=typeof self&&(r=self),r.GeoPattern=t()}}(function(){return function t(r,s,e){function i(o,a){if(!s[o]){if(!r[o]){var h="function"==typeof require&&require;if(!a&&h)return h(o,!0);if(n)return n(o,!0);throw new Error("Cannot find module '"+o+"'")}var l=s[o]={exports:{}};r[o][0].call(l.exports,function(t){var s=r[o][1][t];return i(s?s:t)},l,l.exports,t,r,s,e)}return s[o].exports}for(var n="function"==typeof require&&require,o=0;o<e.length;o++)i(e[o]);return i}({1:[function(t,r){r.exports=t("./lib/")},{"./lib/":3}],2:[function(t,r){"use strict";function s(t){var r=/^#?([a-f\d])([a-f\d])([a-f\d])$/i;t=t.replace(r,function(t,r,s,e){return r+r+s+s+e+e});var s=/^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(t);return s?{r:parseInt(s[1],16),g:parseInt(s[2],16),b:parseInt(s[3],16)}:null}function e(t){return"#"+["r","g","b"].map(function(r){return("0"+t[r].toString(16)).slice(-2)}).join("")}function i(t){var r=t.r,s=t.g,e=t.b;r/=255,s/=255,e/=255;var i,n,o=Math.max(r,s,e),a=Math.min(r,s,e),h=(o+a)/2;if(o===a)i=n=0;else{var l=o-a;switch(n=h>.5?l/(2-o-a):l/(o+a),o){case r:i=(s-e)/l+(e>s?6:0);break;case s:i=(e-r)/l+2;break;case e:i=(r-s)/l+4}i/=6}return{h:i,s:n,l:h}}function n(t){function r(t,r,s){return 0>s&&(s+=1),s>1&&(s-=1),1/6>s?t+6*(r-t)*s:.5>s?r:2/3>s?t+(r-t)*(2/3-s)*6:t}var s,e,i,n=t.h,o=t.s,a=t.l;if(0===o)s=e=i=a;else{var h=.5>a?a*(1+o):a+o-a*o,l=2*a-h;s=r(l,h,n+1/3),e=r(l,h,n),i=r(l,h,n-1/3)}return{r:Math.round(255*s),g:Math.round(255*e),b:Math.round(255*i)}}r.exports={hex2rgb:s,rgb2hex:e,rgb2hsl:i,hsl2rgb:n,rgb2rgbString:function(t){return"rgb("+[t.r,t.g,t.b].join(",")+")"}}},{}],3:[function(t,r){!function(s){"use strict";function e(t){return function(r,s){return"object"==typeof r&&(s=r,r=null),(null===r||void 0===r)&&(r=(new Date).toString()),s||(s={}),t.call(this,r,s)}}var i=t("./pattern"),n=r.exports={generate:e(function(t,r){return new i(t,r)})};s&&(s.fn.geopattern=e(function(t,r){return this.each(function(){var e=s(this).attr("data-title-sha");e&&(r=s.extend({hash:e},r));var i=n.generate(t,r);s(this).css("background-image",i.toDataUrl())})}))}("undefined"!=typeof jQuery?jQuery:null)},{"./pattern":4}],4:[function(t,r){(function(s){"use strict";function e(t,r,s){return parseInt(t.substr(r,s||1),16)}function i(t,r,s,e,i){var n=parseFloat(t),o=s-r,a=i-e;return(n-r)*a/o+e}function n(t){return t%2===0?C:j}function o(t){return i(t,0,15,M,W)}function a(t){var r=t,s=r/2,e=Math.sin(60*Math.PI/180)*r;return[0,e,s,0,s+r,0,2*r,e,s+r,2*e,s,2*e,0,e].join(",")}function h(t,r){var s=.66*r;return[[0,0,t/2,r-s,t/2,r,0,s,0,0],[t/2,r-s,t,0,t,s,t/2,r,t/2,r-s]].map(function(t){return t.join(",")})}function l(t){return[[t,0,t,3*t],[0,t,3*t,t]]}function c(t){var r=t,s=.33*r;return[s,0,r-s,0,r,s,r,r-s,r-s,r,s,r,0,r-s,0,s,s,0].join(",")}function f(t,r){var s=t/2;return[s,0,t,r,0,r,s,0].join(",")}function u(t,r){return[t/2,0,t,r/2,t/2,r,0,r/2].join(",")}function p(t){return[0,0,t,t,0,t,0,0].join(",")}function g(t,r,s,e,i){var a=p(e),h=o(i[0]),l=n(i[0]),c={stroke:S,"stroke-opacity":A,"fill-opacity":h,fill:l};t.polyline(a,c).transform({translate:[r+e,s],scale:[-1,1]}),t.polyline(a,c).transform({translate:[r+e,s+2*e],scale:[1,-1]}),h=o(i[1]),l=n(i[1]),c={stroke:S,"stroke-opacity":A,"fill-opacity":h,fill:l},t.polyline(a,c).transform({translate:[r+e,s+2*e],scale:[-1,-1]}),t.polyline(a,c).transform({translate:[r+e,s],scale:[1,1]})}function v(t,r,s,e,i){var a=o(i),h=n(i),l=p(e),c={stroke:S,"stroke-opacity":A,"fill-opacity":a,fill:h};t.polyline(l,c).transform({translate:[r,s+e],scale:[1,-1]}),t.polyline(l,c).transform({translate:[r+2*e,s+e],scale:[-1,-1]}),t.polyline(l,c).transform({translate:[r,s+e],scale:[1,1]}),t.polyline(l,c).transform({translate:[r+2*e,s+e],scale:[-1,1]})}function y(t,r){var s=t/2;return[0,0,r,s,0,t,0,0].join(",")}var d=t("extend"),b=t("./color"),m=t("./sha1"),k=t("./svg"),x={baseColor:"#933c3c"},w=["octogons","overlappingCircles","plusSigns","xes","sineWaves","hexagons","overlappingRings","plaid","triangles","squares","concentricCircles","diamonds","tessellation","nestedSquares","mosaicSquares","chevrons"],j="#222",C="#ddd",S="#000",A=.02,M=.02,W=.15,H=r.exports=function(t,r){return this.opts=d({},x,r),this.hash=r.hash||m(t),this.svg=new k,this.generateBackground(),this.generatePattern(),this};H.prototype.toSvg=function(){return this.svg.toString()},H.prototype.toString=function(){return this.toSvg()},H.prototype.toBase64=function(){var t,r=this.toSvg();return t="undefined"!=typeof window&&"function"==typeof window.btoa?window.btoa(r):new s(r).toString("base64")},H.prototype.toDataUri=function(){return"data:image/svg+xml;base64,"+this.toBase64()},H.prototype.toDataUrl=function(){return'url("'+this.toDataUri()+'")'},H.prototype.generateBackground=function(){var t,r,s,n;this.opts.color?s=b.hex2rgb(this.opts.color):(r=i(e(this.hash,14,3),0,4095,0,359),n=e(this.hash,17),t=b.rgb2hsl(b.hex2rgb(this.opts.baseColor)),t.h=(360*t.h-r+360)%360/360,t.s=n%2===0?Math.min(1,(100*t.s+n)/100):Math.max(0,(100*t.s-n)/100),s=b.hsl2rgb(t)),this.color=b.rgb2hex(s),this.svg.rect(0,0,"100%","100%",{fill:b.rgb2rgbString(s)})},H.prototype.generatePattern=function(){var t=this.opts.generator;if(t){if(w.indexOf(t)<0)throw new Error("The generator "+t+" does not exist.")}else t=w[e(this.hash,20)];return this["geo"+t.slice(0,1).toUpperCase()+t.slice(1)]()},H.prototype.geoHexagons=function(){var t,r,s,h,l,c,f,u,p=e(this.hash,0),g=i(p,0,15,8,60),v=g*Math.sqrt(3),y=2*g,d=a(g);for(this.svg.setWidth(3*y+3*g),this.svg.setHeight(6*v),s=0,u=0;6>u;u++)for(f=0;6>f;f++)c=e(this.hash,s),t=f%2===0?u*v:u*v+v/2,h=o(c),r=n(c),l={fill:r,"fill-opacity":h,stroke:S,"stroke-opacity":A},this.svg.polyline(d,l).transform({translate:[f*g*1.5-y/2,t-v/2]}),0===f&&this.svg.polyline(d,l).transform({translate:[6*g*1.5-y/2,t-v/2]}),0===u&&(t=f%2===0?6*v:6*v+v/2,this.svg.polyline(d,l).transform({translate:[f*g*1.5-y/2,t-v/2]})),0===f&&0===u&&this.svg.polyline(d,l).transform({translate:[6*g*1.5-y/2,5*v+v/2]}),s++},H.prototype.geoSineWaves=function(){var t,r,s,a,h,l,c,f=Math.floor(i(e(this.hash,0),0,15,100,400)),u=Math.floor(i(e(this.hash,1),0,15,30,100)),p=Math.floor(i(e(this.hash,2),0,15,3,30));for(this.svg.setWidth(f),this.svg.setHeight(36*p),r=0;36>r;r++)l=e(this.hash,r),s=o(l),t=n(l),c=f/4*.7,h={fill:"none",stroke:t,opacity:s,"stroke-width":""+p+"px"},a="M0 "+u+" C "+c+" 0, "+(f/2-c)+" 0, "+f/2+" "+u+" S "+(f-c)+" "+2*u+", "+f+" "+u+" S "+(1.5*f-c)+" 0, "+1.5*f+", "+u,this.svg.path(a,h).transform({translate:[-f/4,p*r-1.5*u]}),this.svg.path(a,h).transform({translate:[-f/4,p*r-1.5*u+36*p]})},H.prototype.geoChevrons=function(){var t,r,s,a,l,c,f,u=i(e(this.hash,0),0,15,30,80),p=i(e(this.hash,0),0,15,30,80),g=h(u,p);for(this.svg.setWidth(6*u),this.svg.setHeight(6*p*.66),r=0,f=0;6>f;f++)for(c=0;6>c;c++)l=e(this.hash,r),s=o(l),t=n(l),a={stroke:S,"stroke-opacity":A,fill:t,"fill-opacity":s,"stroke-width":1},this.svg.group(a).transform({translate:[c*u,f*p*.66-p/2]}).polyline(g).end(),0===f&&this.svg.group(a).transform({translate:[c*u,6*p*.66-p/2]}).polyline(g).end(),r+=1},H.prototype.geoPlusSigns=function(){var t,r,s,a,h,c,f,u,p=i(e(this.hash,0),0,15,10,25),g=3*p,v=l(p);for(this.svg.setWidth(12*p),this.svg.setHeight(12*p),s=0,u=0;6>u;u++)for(f=0;6>f;f++)c=e(this.hash,s),a=o(c),r=n(c),t=u%2===0?0:1,h={fill:r,stroke:S,"stroke-opacity":A,"fill-opacity":a},this.svg.group(h).transform({translate:[f*g-f*p+t*p-p,u*g-u*p-g/2]}).rect(v).end(),0===f&&this.svg.group(h).transform({translate:[4*g-f*p+t*p-p,u*g-u*p-g/2]}).rect(v).end(),0===u&&this.svg.group(h).transform({translate:[f*g-f*p+t*p-p,4*g-u*p-g/2]}).rect(v).end(),0===f&&0===u&&this.svg.group(h).transform({translate:[4*g-f*p+t*p-p,4*g-u*p-g/2]}).rect(v).end(),s++},H.prototype.geoXes=function(){var t,r,s,a,h,c,f,u,p=i(e(this.hash,0),0,15,10,25),g=l(p),v=3*p*.943;for(this.svg.setWidth(3*v),this.svg.setHeight(3*v),s=0,u=0;6>u;u++)for(f=0;6>f;f++)c=e(this.hash,s),a=o(c),t=f%2===0?u*v-.5*v:u*v-.5*v+v/4,r=n(c),h={fill:r,opacity:a},this.svg.group(h).transform({translate:[f*v/2-v/2,t-u*v/2],rotate:[45,v/2,v/2]}).rect(g).end(),0===f&&this.svg.group(h).transform({translate:[6*v/2-v/2,t-u*v/2],rotate:[45,v/2,v/2]}).rect(g).end(),0===u&&(t=f%2===0?6*v-v/2:6*v-v/2+v/4,this.svg.group(h).transform({translate:[f*v/2-v/2,t-6*v/2],rotate:[45,v/2,v/2]}).rect(g).end()),5===u&&this.svg.group(h).transform({translate:[f*v/2-v/2,t-11*v/2],rotate:[45,v/2,v/2]}).rect(g).end(),0===f&&0===u&&this.svg.group(h).transform({translate:[6*v/2-v/2,t-6*v/2],rotate:[45,v/2,v/2]}).rect(g).end(),s++},H.prototype.geoOverlappingCircles=function(){var t,r,s,a,h,l,c,f=e(this.hash,0),u=i(f,0,15,25,200),p=u/2;for(this.svg.setWidth(6*p),this.svg.setHeight(6*p),r=0,c=0;6>c;c++)for(l=0;6>l;l++)h=e(this.hash,r),s=o(h),t=n(h),a={fill:t,opacity:s},this.svg.circle(l*p,c*p,p,a),0===l&&this.svg.circle(6*p,c*p,p,a),0===c&&this.svg.circle(l*p,6*p,p,a),0===l&&0===c&&this.svg.circle(6*p,6*p,p,a),r++},H.prototype.geoOctogons=function(){var t,r,s,a,h,l,f=i(e(this.hash,0),0,15,10,60),u=c(f);for(this.svg.setWidth(6*f),this.svg.setHeight(6*f),r=0,l=0;6>l;l++)for(h=0;6>h;h++)a=e(this.hash,r),s=o(a),t=n(a),this.svg.polyline(u,{fill:t,"fill-opacity":s,stroke:S,"stroke-opacity":A}).transform({translate:[h*f,l*f]}),r+=1},H.prototype.geoSquares=function(){var t,r,s,a,h,l,c=i(e(this.hash,0),0,15,10,60);for(this.svg.setWidth(6*c),this.svg.setHeight(6*c),r=0,l=0;6>l;l++)for(h=0;6>h;h++)a=e(this.hash,r),s=o(a),t=n(a),this.svg.rect(h*c,l*c,c,c,{fill:t,"fill-opacity":s,stroke:S,"stroke-opacity":A}),r+=1},H.prototype.geoConcentricCircles=function(){var t,r,s,a,h,l,c=e(this.hash,0),f=i(c,0,15,10,60),u=f/5;for(this.svg.setWidth(6*(f+u)),this.svg.setHeight(6*(f+u)),r=0,l=0;6>l;l++)for(h=0;6>h;h++)a=e(this.hash,r),s=o(a),t=n(a),this.svg.circle(h*f+h*u+(f+u)/2,l*f+l*u+(f+u)/2,f/2,{fill:"none",stroke:t,opacity:s,"stroke-width":u+"px"}),a=e(this.hash,39-r),s=o(a),t=n(a),this.svg.circle(h*f+h*u+(f+u)/2,l*f+l*u+(f+u)/2,f/4,{fill:t,"fill-opacity":s}),r+=1},H.prototype.geoOverlappingRings=function(){var t,r,s,a,h,l,c,f=e(this.hash,0),u=i(f,0,15,10,60),p=u/4;for(this.svg.setWidth(6*u),this.svg.setHeight(6*u),r=0,c=0;6>c;c++)for(l=0;6>l;l++)h=e(this.hash,r),s=o(h),t=n(h),a={fill:"none",stroke:t,opacity:s,"stroke-width":p+"px"},this.svg.circle(l*u,c*u,u-p/2,a),0===l&&this.svg.circle(6*u,c*u,u-p/2,a),0===c&&this.svg.circle(l*u,6*u,u-p/2,a),0===l&&0===c&&this.svg.circle(6*u,6*u,u-p/2,a),r+=1},H.prototype.geoTriangles=function(){var t,r,s,a,h,l,c,u,p=e(this.hash,0),g=i(p,0,15,15,80),v=g/2*Math.sqrt(3),y=f(g,v);for(this.svg.setWidth(3*g),this.svg.setHeight(6*v),r=0,u=0;6>u;u++)for(c=0;6>c;c++)l=e(this.hash,r),s=o(l),t=n(l),h={fill:t,"fill-opacity":s,stroke:S,"stroke-opacity":A},a=u%2===0?c%2===0?180:0:c%2!==0?180:0,this.svg.polyline(y,h).transform({translate:[c*g*.5-g/2,v*u],rotate:[a,g/2,v/2]}),0===c&&this.svg.polyline(y,h).transform({translate:[6*g*.5-g/2,v*u],rotate:[a,g/2,v/2]}),r+=1},H.prototype.geoDiamonds=function(){var t,r,s,a,h,l,c,f,p=i(e(this.hash,0),0,15,10,50),g=i(e(this.hash,1),0,15,10,50),v=u(p,g);for(this.svg.setWidth(6*p),this.svg.setHeight(3*g),s=0,f=0;6>f;f++)for(c=0;6>c;c++)l=e(this.hash,s),a=o(l),r=n(l),h={fill:r,"fill-opacity":a,stroke:S,"stroke-opacity":A},t=f%2===0?0:p/2,this.svg.polyline(v,h).transform({translate:[c*p-p/2+t,g/2*f-g/2]}),0===c&&this.svg.polyline(v,h).transform({translate:[6*p-p/2+t,g/2*f-g/2]}),0===f&&this.svg.polyline(v,h).transform({translate:[c*p-p/2+t,g/2*6-g/2]}),0===c&&0===f&&this.svg.polyline(v,h).transform({translate:[6*p-p/2+t,g/2*6-g/2]}),s+=1},H.prototype.geoNestedSquares=function(){var t,r,s,a,h,l,c,f=i(e(this.hash,0),0,15,4,12),u=7*f;for(this.svg.setWidth(6*(u+f)+6*f),this.svg.setHeight(6*(u+f)+6*f),r=0,c=0;6>c;c++)for(l=0;6>l;l++)h=e(this.hash,r),s=o(h),t=n(h),a={fill:"none",stroke:t,opacity:s,"stroke-width":f+"px"},this.svg.rect(l*u+l*f*2+f/2,c*u+c*f*2+f/2,u,u,a),h=e(this.hash,39-r),s=o(h),t=n(h),a={fill:"none",stroke:t,opacity:s,"stroke-width":f+"px"},this.svg.rect(l*u+l*f*2+f/2+2*f,c*u+c*f*2+f/2+2*f,3*f,3*f,a),r+=1},H.prototype.geoMosaicSquares=function(){var t,r,s,n=i(e(this.hash,0),0,15,15,50);for(this.svg.setWidth(8*n),this.svg.setHeight(8*n),t=0,s=0;4>s;s++)for(r=0;4>r;r++)r%2===0?s%2===0?v(this.svg,r*n*2,s*n*2,n,e(this.hash,t)):g(this.svg,r*n*2,s*n*2,n,[e(this.hash,t),e(this.hash,t+1)]):s%2===0?g(this.svg,r*n*2,s*n*2,n,[e(this.hash,t),e(this.hash,t+1)]):v(this.svg,r*n*2,s*n*2,n,e(this.hash,t)),t+=1},H.prototype.geoPlaid=function(){var t,r,s,i,a,h,l,c=0,f=0;for(r=0;36>r;)i=e(this.hash,r),c+=i+5,l=e(this.hash,r+1),s=o(l),t=n(l),a=l+5,this.svg.rect(0,c,"100%",a,{opacity:s,fill:t}),c+=a,r+=2;for(r=0;36>r;)i=e(this.hash,r),f+=i+5,l=e(this.hash,r+1),s=o(l),t=n(l),h=l+5,this.svg.rect(f,0,h,"100%",{opacity:s,fill:t}),f+=h,r+=2;this.svg.setWidth(f),this.svg.setHeight(c)},H.prototype.geoTessellation=function(){var t,r,s,a,h,l=i(e(this.hash,0),0,15,5,40),c=l*Math.sqrt(3),f=2*l,u=l/2*Math.sqrt(3),p=y(l,u),g=3*l+2*u,v=2*c+2*l;for(this.svg.setWidth(g),this.svg.setHeight(v),r=0;20>r;r++)switch(h=e(this.hash,r),s=o(h),t=n(h),a={stroke:S,"stroke-opacity":A,fill:t,"fill-opacity":s,"stroke-width":1},r){case 0:this.svg.rect(-l/2,-l/2,l,l,a),this.svg.rect(g-l/2,-l/2,l,l,a),this.svg.rect(-l/2,v-l/2,l,l,a),this.svg.rect(g-l/2,v-l/2,l,l,a);break;case 1:this.svg.rect(f/2+u,c/2,l,l,a);break;case 2:this.svg.rect(-l/2,v/2-l/2,l,l,a),this.svg.rect(g-l/2,v/2-l/2,l,l,a);break;case 3:this.svg.rect(f/2+u,1.5*c+l,l,l,a);break;case 4:this.svg.polyline(p,a).transform({translate:[l/2,-l/2],rotate:[0,l/2,u/2]}),this.svg.polyline(p,a).transform({translate:[l/2,v- -l/2],rotate:[0,l/2,u/2],scale:[1,-1]});break;case 5:this.svg.polyline(p,a).transform({translate:[g-l/2,-l/2],rotate:[0,l/2,u/2],scale:[-1,1]}),this.svg.polyline(p,a).transform({translate:[g-l/2,v+l/2],rotate:[0,l/2,u/2],scale:[-1,-1]});break;case 6:this.svg.polyline(p,a).transform({translate:[g/2+l/2,c/2]});break;case 7:this.svg.polyline(p,a).transform({translate:[g-g/2-l/2,c/2],scale:[-1,1]});break;case 8:this.svg.polyline(p,a).transform({translate:[g/2+l/2,v-c/2],scale:[1,-1]});break;case 9:this.svg.polyline(p,a).transform({translate:[g-g/2-l/2,v-c/2],scale:[-1,-1]});break;case 10:this.svg.polyline(p,a).transform({translate:[l/2,v/2-l/2]});break;case 11:this.svg.polyline(p,a).transform({translate:[g-l/2,v/2-l/2],scale:[-1,1]});break;case 12:this.svg.rect(0,0,l,l,a).transform({translate:[l/2,l/2],rotate:[-30,0,0]});break;case 13:this.svg.rect(0,0,l,l,a).transform({scale:[-1,1],translate:[-g+l/2,l/2],rotate:[-30,0,0]});break;case 14:this.svg.rect(0,0,l,l,a).transform({translate:[l/2,v/2-l/2-l],rotate:[30,0,l]});break;case 15:this.svg.rect(0,0,l,l,a).transform({scale:[-1,1],translate:[-g+l/2,v/2-l/2-l],rotate:[30,0,l]});break;case 16:this.svg.rect(0,0,l,l,a).transform({scale:[1,-1],translate:[l/2,-v+v/2-l/2-l],rotate:[30,0,l]});break;case 17:this.svg.rect(0,0,l,l,a).transform({scale:[-1,-1],translate:[-g+l/2,-v+v/2-l/2-l],rotate:[30,0,l]});break;case 18:this.svg.rect(0,0,l,l,a).transform({scale:[1,-1],translate:[l/2,-v+l/2],rotate:[-30,0,0]});break;case 19:this.svg.rect(0,0,l,l,a).transform({scale:[-1,-1],translate:[-g+l/2,-v+l/2],rotate:[-30,0,0]})}}}).call(this,t("buffer").Buffer)},{"./color":2,"./sha1":5,"./svg":6,buffer:8,extend:9}],5:[function(t,r){"use strict";function s(){function t(){for(var t=16;80>t;t++){var r=f[t-3]^f[t-8]^f[t-14]^f[t-16];f[t]=r<<1|r>>>31}var s,e,i=o,n=a,p=h,g=l,v=c;for(t=0;80>t;t++){20>t?(s=g^n&(p^g),e=1518500249):40>t?(s=n^p^g,e=1859775393):60>t?(s=n&p|g&(n|p),e=2400959708):(s=n^p^g,e=3395469782);var y=(i<<5|i>>>27)+s+v+e+(0|f[t]);v=g,g=p,p=n<<30|n>>>2,n=i,i=y}for(o=o+i|0,a=a+n|0,h=h+p|0,l=l+g|0,c=c+v|0,u=0,t=0;16>t;t++)f[t]=0}function r(r){f[u]|=(255&r)<<p,p?p-=8:(u++,p=24),16===u&&t()}function s(t){var s=t.length;g+=8*s;for(var e=0;s>e;e++)r(t.charCodeAt(e))}function e(t){if("string"==typeof t)return s(t);var e=t.length;g+=8*e;for(var i=0;e>i;i++)r(t[i])}function i(t){for(var r="",s=28;s>=0;s-=4)r+=(t>>s&15).toString(16);return r}function n(){r(128),(u>14||14===u&&24>p)&&t(),u=14,p=24,r(0),r(0),r(g>0xffffffffff?g/1099511627776:0),r(g>4294967295?g/4294967296:0);for(var s=24;s>=0;s-=8)r(g>>s);return i(o)+i(a)+i(h)+i(l)+i(c)}var o=1732584193,a=4023233417,h=2562383102,l=271733878,c=3285377520,f=new Uint32Array(80),u=0,p=24,g=0;return{update:e,digest:n}}r.exports=function(t){if(void 0===t)return s();var r=s();return r.update(t),r.digest()}},{}],6:[function(t,r){"use strict";function s(){return this.width=100,this.height=100,this.svg=new i("svg"),this.context=[],this.setAttributes(this.svg,{xmlns:"http://www.w3.org/2000/svg",width:this.width,height:this.height}),this}var e=t("extend"),i=t("./xml");r.exports=s,s.prototype.currentContext=function(){return this.context[this.context.length-1]||this.svg},s.prototype.end=function(){return this.context.pop(),this},s.prototype.currentNode=function(){var t=this.currentContext();return t.lastChild||t},s.prototype.transform=function(t){return this.currentNode().setAttribute("transform",Object.keys(t).map(function(r){return r+"("+t[r].join(",")+")"}).join(" ")),this},s.prototype.setAttributes=function(t,r){Object.keys(r).forEach(function(s){t.setAttribute(s,r[s])})},s.prototype.setWidth=function(t){this.svg.setAttribute("width",Math.floor(t))},s.prototype.setHeight=function(t){this.svg.setAttribute("height",Math.floor(t))},s.prototype.toString=function(){return this.svg.toString()},s.prototype.rect=function(t,r,s,n,o){var a=this;if(Array.isArray(t))return t.forEach(function(t){a.rect.apply(a,t.concat(o))}),this;var h=new i("rect");return this.currentContext().appendChild(h),this.setAttributes(h,e({x:t,y:r,width:s,height:n},o)),this},s.prototype.circle=function(t,r,s,n){var o=new i("circle");return this.currentContext().appendChild(o),this.setAttributes(o,e({cx:t,cy:r,r:s},n)),this},s.prototype.path=function(t,r){var s=new i("path");return this.currentContext().appendChild(s),this.setAttributes(s,e({d:t},r)),this},s.prototype.polyline=function(t,r){var s=this;if(Array.isArray(t))return t.forEach(function(t){s.polyline(t,r)}),this;var n=new i("polyline");return this.currentContext().appendChild(n),this.setAttributes(n,e({points:t},r)),this},s.prototype.group=function(t){var r=new i("g");return this.currentContext().appendChild(r),this.context.push(r),this.setAttributes(r,e({},t)),this}},{"./xml":7,extend:9}],7:[function(t,r){"use strict";var s=r.exports=function(t){return this instanceof s?(this.tagName=t,this.attributes=Object.create(null),this.children=[],this.lastChild=null,this):new s(t)};s.prototype.appendChild=function(t){return this.children.push(t),this.lastChild=t,this},s.prototype.setAttribute=function(t,r){return this.attributes[t]=r,this},s.prototype.toString=function(){var t=this;return["<",t.tagName,Object.keys(t.attributes).map(function(r){return[" ",r,'="',t.attributes[r],'"'].join("")}).join(""),">",t.children.map(function(t){return t.toString()}).join(""),"</",t.tagName,">"].join("")}},{}],8:[function(){},{}],9:[function(t,r){function s(t){if(!t||"[object Object]"!==i.call(t)||t.nodeType||t.setInterval)return!1;var r=e.call(t,"constructor"),s=e.call(t.constructor.prototype,"isPrototypeOf");if(t.constructor&&!r&&!s)return!1;var n;for(n in t);return void 0===n||e.call(t,n)}var e=Object.prototype.hasOwnProperty,i=Object.prototype.toString;r.exports=function n(){var t,r,e,i,o,a,h=arguments[0]||{},l=1,c=arguments.length,f=!1;for("boolean"==typeof h&&(f=h,h=arguments[1]||{},l=2),"object"!=typeof h&&"function"!=typeof h&&(h={});c>l;l++)if(null!=(t=arguments[l]))for(r in t)e=h[r],i=t[r],h!==i&&(f&&i&&(s(i)||(o=Array.isArray(i)))?(o?(o=!1,a=e&&Array.isArray(e)?e:[]):a=e&&s(e)?e:{},h[r]=n(f,a,i)):void 0!==i&&(h[r]=i));return h}},{}]},{},[1])(1)})}();
+
+!function(){!function(t,e,i){!function(t){"function"==typeof define&&define.amd?define(["jquery"],t):jQuery&&!jQuery.fn.sparkline&&t(jQuery)}(function(s){"use strict";var r={},n,a,h,o,l,g,p,u,c,d,f,m,v,x,y,C,w,b,R,S,k,M,_,H,W,T,q,I,j,P,L,A,F=0;n=function(){return{common:{type:"line",lineColor:"#00f",fillColor:"#cdf",defaultPixelsPerValue:3,width:"auto",height:"auto",composite:!1,tagValuesAttribute:"values",tagOptionsPrefix:"spark",enableTagOptions:!1,enableHighlight:!0,highlightLighten:1.4,tooltipSkipNull:!0,tooltipPrefix:"",tooltipSuffix:"",disableHiddenCheck:!1,numberFormatter:!1,numberDigitGroupCount:3,numberDigitGroupSep:",",numberDecimalMark:".",disableTooltips:!1,disableInteraction:!1},line:{spotColor:"#f80",highlightSpotColor:"#5f5",highlightLineColor:"#f22",spotRadius:1.5,minSpotColor:"#f80",maxSpotColor:"#f80",lineWidth:1,normalRangeMin:i,normalRangeMax:i,normalRangeColor:"#ccc",drawNormalOnTop:!1,chartRangeMin:i,chartRangeMax:i,chartRangeMinX:i,chartRangeMaxX:i,tooltipFormat:new h('<span style="color: {{color}}">&#9679;</span> {{prefix}}{{y}}{{suffix}}')},bar:{barColor:"#3366cc",negBarColor:"#f44",stackedBarColor:["#3366cc","#dc3912","#ff9900","#109618","#66aa00","#dd4477","#0099c6","#990099"],zeroColor:i,nullColor:i,zeroAxis:!0,barWidth:4,barSpacing:1,chartRangeMax:i,chartRangeMin:i,chartRangeClip:!1,colorMap:i,tooltipFormat:new h('<span style="color: {{color}}">&#9679;</span> {{prefix}}{{value}}{{suffix}}')},tristate:{barWidth:4,barSpacing:1,posBarColor:"#6f6",negBarColor:"#f44",zeroBarColor:"#999",colorMap:{},tooltipFormat:new h('<span style="color: {{color}}">&#9679;</span> {{value:map}}'),tooltipValueLookups:{map:{"-1":"Loss",0:"Draw",1:"Win"}}},discrete:{lineHeight:"auto",thresholdColor:i,thresholdValue:0,chartRangeMax:i,chartRangeMin:i,chartRangeClip:!1,tooltipFormat:new h("{{prefix}}{{value}}{{suffix}}")},bullet:{targetColor:"#f33",targetWidth:3,performanceColor:"#33f",rangeColors:["#d3dafe","#a8b6ff","#7f94ff"],base:i,tooltipFormat:new h("{{fieldkey:fields}} - {{value}}"),tooltipValueLookups:{fields:{r:"Range",p:"Performance",t:"Target"}}},pie:{offset:0,sliceColors:["#3366cc","#dc3912","#ff9900","#109618","#66aa00","#dd4477","#0099c6","#990099"],borderWidth:0,borderColor:"#000",tooltipFormat:new h('<span style="color: {{color}}">&#9679;</span> {{value}} ({{percent.1}}%)')},box:{raw:!1,boxLineColor:"#000",boxFillColor:"#cdf",whiskerColor:"#000",outlierLineColor:"#333",outlierFillColor:"#fff",medianColor:"#f00",showOutliers:!0,outlierIQR:1.5,spotRadius:1.5,target:i,targetColor:"#4a2",chartRangeMax:i,chartRangeMin:i,tooltipFormat:new h("{{field:fields}}: {{value}}"),tooltipFormatFieldlistKey:"field",tooltipValueLookups:{fields:{lq:"Lower Quartile",med:"Median",uq:"Upper Quartile",lo:"Left Outlier",ro:"Right Outlier",lw:"Left Whisker",rw:"Right Whisker"}}}}},T='.jqstooltip { position: absolute;left: 0px;top: 0px;visibility: hidden;background: rgb(0, 0, 0) transparent;background-color: rgba(0,0,0,0.6);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr=#99000000, endColorstr=#99000000);-ms-filter: "progid:DXImageTransform.Microsoft.gradient(startColorstr=#99000000, endColorstr=#99000000)";color: white;font: 10px arial, san serif;text-align: left;white-space: nowrap;padding: 5px;border: 1px solid white;z-index: 10000;}.jqsfield { color: white;font: 10px arial, san serif;text-align: left;}',a=function(){var t,e;return t=function(){this.init.apply(this,arguments)},arguments.length>1?(arguments[0]?(t.prototype=s.extend(new arguments[0],arguments[arguments.length-1]),t._super=arguments[0].prototype):t.prototype=arguments[arguments.length-1],arguments.length>2&&(e=Array.prototype.slice.call(arguments,1,-1),e.unshift(t.prototype),s.extend.apply(s,e))):t.prototype=arguments[0],t.prototype.cls=t,t},s.SPFormatClass=h=a({fre:/\{\{([\w.]+?)(:(.+?))?\}\}/g,precre:/(\w+)\.(\d+)/,init:function(t,e){this.format=t,this.fclass=e},render:function(t,e,s){var r=this,n=t,a,h,o,l,g;return this.format.replace(this.fre,function(){var t;return h=arguments[1],o=arguments[3],a=r.precre.exec(h),a?(g=a[2],h=a[1]):g=!1,l=n[h],l===i?"":o&&e&&e[o]?(t=e[o],t.get?e[o].get(l)||l:e[o][l]||l):(c(l)&&(l=s.get("numberFormatter")?s.get("numberFormatter")(l):x(l,g,s.get("numberDigitGroupCount"),s.get("numberDigitGroupSep"),s.get("numberDecimalMark"))),l)})}}),s.spformat=function(t,e){return new h(t,e)},o=function(t,e,i){return e>t?e:t>i?i:t},l=function(t,i){var s;return 2===i?(s=e.floor(t.length/2),t.length%2?t[s]:(t[s-1]+t[s])/2):t.length%2?(s=(t.length*i+i)/4,s%1?(t[e.floor(s)]+t[e.floor(s)-1])/2:t[s-1]):(s=(t.length*i+2)/4,s%1?(t[e.floor(s)]+t[e.floor(s)-1])/2:t[s-1])},g=function(t){var e;switch(t){case"undefined":t=i;break;case"null":t=null;break;case"true":t=!0;break;case"false":t=!1;break;default:e=parseFloat(t),t==e&&(t=e)}return t},p=function(t){var e,i=[];for(e=t.length;e--;)i[e]=g(t[e]);return i},u=function(t,e){var i,s,r=[];for(i=0,s=t.length;s>i;i++)t[i]!==e&&r.push(t[i]);return r},c=function(t){return!isNaN(parseFloat(t))&&isFinite(t)},x=function(t,e,i,r,n){var a,h;for(t=(e===!1?parseFloat(t).toString():t.toFixed(e)).split(""),a=(a=s.inArray(".",t))<0?t.length:a,a<t.length&&(t[a]=n),h=a-i;h>0;h-=i)t.splice(h,0,r);return t.join("")},d=function(t,e,i){var s;for(s=e.length;s--;)if((!i||null!==e[s])&&e[s]!==t)return!1;return!0},f=function(t){var e=0,i;for(i=t.length;i--;)e+="number"==typeof t[i]?t[i]:0;return e},v=function(t){return s.isArray(t)?t:[t]},m=function(e){var i;t.createStyleSheet?t.createStyleSheet().cssText=e:(i=t.createElement("style"),i.type="text/css",t.getElementsByTagName("head")[0].appendChild(i),i["string"==typeof t.body.style.WebkitAppearance?"innerText":"innerHTML"]=e)},s.fn.simpledraw=function(e,r,n,a){var h,o;if(n&&(h=this.data("_jqs_vcanvas")))return h;if(s.fn.sparkline.canvas===!1)return!1;if(s.fn.sparkline.canvas===i){var l=t.createElement("canvas");if(l.getContext&&l.getContext("2d"))s.fn.sparkline.canvas=function(t,e,i,s){return new P(t,e,i,s)};else{if(!t.namespaces||t.namespaces.v)return s.fn.sparkline.canvas=!1,!1;t.namespaces.add("v","urn:schemas-microsoft-com:vml","#default#VML"),s.fn.sparkline.canvas=function(t,e,i,s){return new L(t,e,i)}}}return e===i&&(e=s(this).innerWidth()),r===i&&(r=s(this).innerHeight()),h=s.fn.sparkline.canvas(e,r,this,a),o=s(this).data("_jqs_mhandler"),o&&o.registerCanvas(h),h},s.fn.cleardraw=function(){var t=this.data("_jqs_vcanvas");t&&t.reset()},s.RangeMapClass=y=a({init:function(t){var e,i,s=[];for(e in t)t.hasOwnProperty(e)&&"string"==typeof e&&e.indexOf(":")>-1&&(i=e.split(":"),i[0]=0===i[0].length?-1/0:parseFloat(i[0]),i[1]=0===i[1].length?1/0:parseFloat(i[1]),i[2]=t[e],s.push(i));this.map=t,this.rangelist=s||!1},get:function(t){var e=this.rangelist,s,r,n;if((n=this.map[t])!==i)return n;if(e)for(s=e.length;s--;)if(r=e[s],r[0]<=t&&r[1]>=t)return r[2];return i}}),s.range_map=function(t){return new y(t)},C=a({init:function(t,e){var i=s(t);this.$el=i,this.options=e,this.currentPageX=0,this.currentPageY=0,this.el=t,this.splist=[],this.tooltip=null,this.over=!1,this.displayTooltips=!e.get("disableTooltips"),this.highlightEnabled=!e.get("disableHighlight")},registerSparkline:function(t){this.splist.push(t),this.over&&this.updateDisplay()},registerCanvas:function(t){var e=s(t.canvas);this.canvas=t,this.$canvas=e,e.mouseenter(s.proxy(this.mouseenter,this)),e.mouseleave(s.proxy(this.mouseleave,this)),e.click(s.proxy(this.mouseclick,this))},reset:function(t){this.splist=[],this.tooltip&&t&&(this.tooltip.remove(),this.tooltip=i)},mouseclick:function(t){var e=s.Event("sparklineClick");e.originalEvent=t,e.sparklines=this.splist,this.$el.trigger(e)},mouseenter:function(e){s(t.body).unbind("mousemove.jqs"),s(t.body).bind("mousemove.jqs",s.proxy(this.mousemove,this)),this.over=!0,this.currentPageX=e.pageX,this.currentPageY=e.pageY,this.currentEl=e.target,!this.tooltip&&this.displayTooltips&&(this.tooltip=new w(this.options),this.tooltip.updatePosition(e.pageX,e.pageY)),this.updateDisplay()},mouseleave:function(){s(t.body).unbind("mousemove.jqs");var e=this.splist,i=e.length,r=!1,n,a;for(this.over=!1,this.currentEl=null,this.tooltip&&(this.tooltip.remove(),this.tooltip=null),a=0;i>a;a++)n=e[a],n.clearRegionHighlight()&&(r=!0);r&&this.canvas.render()},mousemove:function(t){this.currentPageX=t.pageX,this.currentPageY=t.pageY,this.currentEl=t.target,this.tooltip&&this.tooltip.updatePosition(t.pageX,t.pageY),this.updateDisplay()},updateDisplay:function(){var t=this.splist,e=t.length,i=!1,r=this.$canvas.offset(),n=this.currentPageX-r.left,a=this.currentPageY-r.top,h,o,l,g,p;if(this.over){for(l=0;e>l;l++)o=t[l],g=o.setRegionHighlight(this.currentEl,n,a),g&&(i=!0);if(i){if(p=s.Event("sparklineRegionChange"),p.sparklines=this.splist,this.$el.trigger(p),this.tooltip){for(h="",l=0;e>l;l++)o=t[l],h+=o.getCurrentRegionTooltip();this.tooltip.setContent(h)}this.disableHighlight||this.canvas.render()}null===g&&this.mouseleave()}}}),w=a({sizeStyle:"position: static !important;display: block !important;visibility: hidden !important;float: left !important;",init:function(e){var i=e.get("tooltipClassname","jqstooltip"),r=this.sizeStyle,n;this.container=e.get("tooltipContainer")||t.body,this.tooltipOffsetX=e.get("tooltipOffsetX",10),this.tooltipOffsetY=e.get("tooltipOffsetY",12),s("#jqssizetip").remove(),s("#jqstooltip").remove(),this.sizetip=s("<div/>",{id:"jqssizetip",style:r,"class":i}),this.tooltip=s("<div/>",{id:"jqstooltip","class":i}).appendTo(this.container),n=this.tooltip.offset(),this.offsetLeft=n.left,this.offsetTop=n.top,this.hidden=!0,s(window).unbind("resize.jqs scroll.jqs"),s(window).bind("resize.jqs scroll.jqs",s.proxy(this.updateWindowDims,this)),this.updateWindowDims()},updateWindowDims:function(){this.scrollTop=s(window).scrollTop(),this.scrollLeft=s(window).scrollLeft(),this.scrollRight=this.scrollLeft+s(window).width(),this.updatePosition()},getSize:function(t){this.sizetip.html(t).appendTo(this.container),this.width=this.sizetip.width()+1,this.height=this.sizetip.height(),this.sizetip.remove()},setContent:function(t){return t?(this.getSize(t),this.tooltip.html(t).css({width:this.width,height:this.height,visibility:"visible"}),this.hidden&&(this.hidden=!1,this.updatePosition()),void 0):(this.tooltip.css("visibility","hidden"),void(this.hidden=!0))},updatePosition:function(t,e){if(t===i){if(this.mousex===i)return;t=this.mousex-this.offsetLeft,e=this.mousey-this.offsetTop}else this.mousex=t-=this.offsetLeft,this.mousey=e-=this.offsetTop;this.height&&this.width&&!this.hidden&&(e-=this.height+this.tooltipOffsetY,t+=this.tooltipOffsetX,e<this.scrollTop&&(e=this.scrollTop),t<this.scrollLeft?t=this.scrollLeft:t+this.width>this.scrollRight&&(t=this.scrollRight-this.width),this.tooltip.css({left:t,top:e}))},remove:function(){this.tooltip.remove(),this.sizetip.remove(),this.sizetip=this.tooltip=i,s(window).unbind("resize.jqs scroll.jqs")}}),q=function(){m(T)},s(q),A=[],s.fn.sparkline=function(e,r){return this.each(function(){var n=new s.fn.sparkline.options(this,r),a=s(this),h,o;if(h=function(){var r,h,o,l,g,p,u;return"html"===e||e===i?(u=this.getAttribute(n.get("tagValuesAttribute")),(u===i||null===u)&&(u=a.html()),r=u.replace(/(^\s*<!--)|(-->\s*$)|\s+/g,"").split(",")):r=e,h="auto"===n.get("width")?r.length*n.get("defaultPixelsPerValue"):n.get("width"),"auto"===n.get("height")?n.get("composite")&&s.data(this,"_jqs_vcanvas")||(l=t.createElement("span"),l.innerHTML="a",a.html(l),o=s(l).innerHeight()||s(l).height(),s(l).remove(),l=null):o=n.get("height"),n.get("disableInteraction")?g=!1:(g=s.data(this,"_jqs_mhandler"),g?n.get("composite")||g.reset():(g=new C(this,n),s.data(this,"_jqs_mhandler",g))),n.get("composite")&&!s.data(this,"_jqs_vcanvas")?void(s.data(this,"_jqs_errnotify")||(alert("Attempted to attach a composite sparkline to an element with no existing sparkline"),s.data(this,"_jqs_errnotify",!0))):(p=new(s.fn.sparkline[n.get("type")])(this,r,n,h,o),p.render(),g&&g.registerSparkline(p),void 0)},s(this).html()&&!n.get("disableHiddenCheck")&&s(this).is(":hidden")||!s(this).parents("body").length){if(!n.get("composite")&&s.data(this,"_jqs_pending"))for(o=A.length;o;o--)A[o-1][0]==this&&A.splice(o-1,1);A.push([this,h]),s.data(this,"_jqs_pending",!0)}else h.call(this)})},s.fn.sparkline.defaults=n(),s.sparkline_display_visible=function(){var t,e,i,r=[];for(e=0,i=A.length;i>e;e++)t=A[e][0],s(t).is(":visible")&&!s(t).parents().is(":hidden")?(A[e][1].call(t),s.data(A[e][0],"_jqs_pending",!1),r.push(e)):!s(t).closest("html").length&&!s.data(t,"_jqs_pending")&&(s.data(A[e][0],"_jqs_pending",!1),r.push(e));for(e=r.length;e;e--)A.splice(r[e-1],1)},s.fn.sparkline.options=a({init:function(t,e){var i,n,a,h;this.userOptions=e=e||{},this.tag=t,this.tagValCache={},n=s.fn.sparkline.defaults,a=n.common,this.tagOptionsPrefix=e.enableTagOptions&&(e.tagOptionsPrefix||a.tagOptionsPrefix),h=this.getTagSetting("type"),i=h===r?n[e.type||a.type]:n[h],this.mergedOptions=s.extend({},a,i,e)},getTagSetting:function(t){var e=this.tagOptionsPrefix,s,n,a,h;if(e===!1||e===i)return r;if(this.tagValCache.hasOwnProperty(t))s=this.tagValCache.key;else{if(s=this.tag.getAttribute(e+t),s===i||null===s)s=r;else if("["===s.substr(0,1))for(s=s.substr(1,s.length-2).split(","),n=s.length;n--;)s[n]=g(s[n].replace(/(^\s*)|(\s*$)/g,""));else if("{"===s.substr(0,1))for(a=s.substr(1,s.length-2).split(","),s={},n=a.length;n--;)h=a[n].split(":",2),s[h[0].replace(/(^\s*)|(\s*$)/g,"")]=g(h[1].replace(/(^\s*)|(\s*$)/g,""));else s=g(s);this.tagValCache.key=s}return s},get:function(t,e){var s=this.getTagSetting(t),n;return s!==r?s:(n=this.mergedOptions[t])===i?e:n}}),s.fn.sparkline._base=a({disabled:!1,init:function(t,e,r,n,a){this.el=t,this.$el=s(t),this.values=e,this.options=r,this.width=n,this.height=a,this.currentRegion=i},initTarget:function(){var t=!this.options.get("disableInteraction");(this.target=this.$el.simpledraw(this.width,this.height,this.options.get("composite"),t))?(this.canvasWidth=this.target.pixelWidth,this.canvasHeight=this.target.pixelHeight):this.disabled=!0},render:function(){return this.disabled?(this.el.innerHTML="",!1):!0},getRegion:function(t,e){},setRegionHighlight:function(t,e,s){var r=this.currentRegion,n=!this.options.get("disableHighlight"),a;return e>this.canvasWidth||s>this.canvasHeight||0>e||0>s?null:(a=this.getRegion(t,e,s),r!==a?(r!==i&&n&&this.removeHighlight(),this.currentRegion=a,a!==i&&n&&this.renderHighlight(),!0):!1)},clearRegionHighlight:function(){return this.currentRegion!==i?(this.removeHighlight(),this.currentRegion=i,!0):!1},renderHighlight:function(){this.changeHighlight(!0)},removeHighlight:function(){this.changeHighlight(!1)},changeHighlight:function(t){},getCurrentRegionTooltip:function(){var t=this.options,e="",r=[],n,a,o,l,g,p,u,c,d,f,m,v,x,y;if(this.currentRegion===i)return"";if(n=this.getCurrentRegionFields(),m=t.get("tooltipFormatter"))return m(this,t,n);if(t.get("tooltipChartTitle")&&(e+='<div class="jqs jqstitle">'+t.get("tooltipChartTitle")+"</div>\n"),a=this.options.get("tooltipFormat"),!a)return"";if(s.isArray(a)||(a=[a]),s.isArray(n)||(n=[n]),u=this.options.get("tooltipFormatFieldlist"),c=this.options.get("tooltipFormatFieldlistKey"),u&&c){for(d=[],p=n.length;p--;)f=n[p][c],-1!=(y=s.inArray(f,u))&&(d[y]=n[p]);n=d}for(o=a.length,x=n.length,p=0;o>p;p++)for(v=a[p],"string"==typeof v&&(v=new h(v)),l=v.fclass||"jqsfield",y=0;x>y;y++)n[y].isNull&&t.get("tooltipSkipNull")||(s.extend(n[y],{prefix:t.get("tooltipPrefix"),suffix:t.get("tooltipSuffix")}),g=v.render(n[y],t.get("tooltipValueLookups"),t),r.push('<div class="'+l+'">'+g+"</div>"));return r.length?e+r.join("\n"):""},getCurrentRegionFields:function(){},calcHighlightColor:function(t,i){var s=i.get("highlightColor"),r=i.get("highlightLighten"),n,a,h,l;if(s)return s;if(r&&(n=/^#([0-9a-f])([0-9a-f])([0-9a-f])$/i.exec(t)||/^#([0-9a-f]{2})([0-9a-f]{2})([0-9a-f]{2})$/i.exec(t))){for(h=[],a=4===t.length?16:1,l=0;3>l;l++)h[l]=o(e.round(parseInt(n[l+1],16)*a*r),0,255);return"rgb("+h.join(",")+")"}return t}}),b={changeHighlight:function(t){var e=this.currentRegion,i=this.target,r=this.regionShapes[e],n;r&&(n=this.renderRegion(e,t),s.isArray(n)||s.isArray(r)?(i.replaceWithShapes(r,n),this.regionShapes[e]=s.map(n,function(t){return t.id})):(i.replaceWithShape(r,n),this.regionShapes[e]=n.id))},render:function(){var t=this.values,e=this.target,i=this.regionShapes,r,n,a,h;if(this.cls._super.render.call(this)){for(a=t.length;a--;)if(r=this.renderRegion(a))if(s.isArray(r)){for(n=[],h=r.length;h--;)r[h].append(),n.push(r[h].id);i[a]=n}else r.append(),i[a]=r.id;else i[a]=null;e.render()}}},s.fn.sparkline.line=R=a(s.fn.sparkline._base,{type:"line",init:function(t,e,i,s,r){R._super.init.call(this,t,e,i,s,r),this.vertices=[],this.regionMap=[],this.xvalues=[],this.yvalues=[],this.yminmax=[],this.hightlightSpotId=null,this.lastShapeId=null,this.initTarget()},getRegion:function(t,e,s){var r,n=this.regionMap;for(r=n.length;r--;)if(null!==n[r]&&e>=n[r][0]&&e<=n[r][1])return n[r][2];return i},getCurrentRegionFields:function(){var t=this.currentRegion;return{isNull:null===this.yvalues[t],x:this.xvalues[t],y:this.yvalues[t],color:this.options.get("lineColor"),fillColor:this.options.get("fillColor"),offset:t}},renderHighlight:function(){var t=this.currentRegion,e=this.target,s=this.vertices[t],r=this.options,n=r.get("spotRadius"),a=r.get("highlightSpotColor"),h=r.get("highlightLineColor"),o,l;s&&(n&&a&&(o=e.drawCircle(s[0],s[1],n,i,a),this.highlightSpotId=o.id,e.insertAfterShape(this.lastShapeId,o)),h&&(l=e.drawLine(s[0],this.canvasTop,s[0],this.canvasTop+this.canvasHeight,h),this.highlightLineId=l.id,e.insertAfterShape(this.lastShapeId,l)))},removeHighlight:function(){var t=this.target;this.highlightSpotId&&(t.removeShapeId(this.highlightSpotId),this.highlightSpotId=null),this.highlightLineId&&(t.removeShapeId(this.highlightLineId),this.highlightLineId=null)},scanValues:function(){var t=this.values,i=t.length,s=this.xvalues,r=this.yvalues,n=this.yminmax,a,h,o,l,g;for(a=0;i>a;a++)h=t[a],o="string"==typeof t[a],l="object"==typeof t[a]&&t[a]instanceof Array,g=o&&t[a].split(":"),o&&2===g.length?(s.push(Number(g[0])),r.push(Number(g[1])),n.push(Number(g[1]))):l?(s.push(h[0]),r.push(h[1]),n.push(h[1])):(s.push(a),null===t[a]||"null"===t[a]?r.push(null):(r.push(Number(h)),n.push(Number(h))));this.options.get("xvalues")&&(s=this.options.get("xvalues")),this.maxy=this.maxyorg=e.max.apply(e,n),this.miny=this.minyorg=e.min.apply(e,n),this.maxx=e.max.apply(e,s),this.minx=e.min.apply(e,s),this.xvalues=s,this.yvalues=r,this.yminmax=n},processRangeOptions:function(){var t=this.options,e=t.get("normalRangeMin"),s=t.get("normalRangeMax");e!==i&&(e<this.miny&&(this.miny=e),s>this.maxy&&(this.maxy=s)),t.get("chartRangeMin")!==i&&(t.get("chartRangeClip")||t.get("chartRangeMin")<this.miny)&&(this.miny=t.get("chartRangeMin")),t.get("chartRangeMax")!==i&&(t.get("chartRangeClip")||t.get("chartRangeMax")>this.maxy)&&(this.maxy=t.get("chartRangeMax")),t.get("chartRangeMinX")!==i&&(t.get("chartRangeClipX")||t.get("chartRangeMinX")<this.minx)&&(this.minx=t.get("chartRangeMinX")),t.get("chartRangeMaxX")!==i&&(t.get("chartRangeClipX")||t.get("chartRangeMaxX")>this.maxx)&&(this.maxx=t.get("chartRangeMaxX"))},drawNormalRange:function(t,s,r,n,a){var h=this.options.get("normalRangeMin"),o=this.options.get("normalRangeMax"),l=s+e.round(r-r*((o-this.miny)/a)),g=e.round(r*(o-h)/a);this.target.drawRect(t,l,n,g,i,this.options.get("normalRangeColor")).append()},render:function(){var t=this.options,r=this.target,n=this.canvasWidth,a=this.canvasHeight,h=this.vertices,o=t.get("spotRadius"),l=this.regionMap,g,p,u,c,d,f,m,v,x,C,w,b,S,k,M,_,H,W,T,q,I,j,P,L,A;if(R._super.render.call(this)&&(this.scanValues(),this.processRangeOptions(),P=this.xvalues,L=this.yvalues,this.yminmax.length&&!(this.yvalues.length<2))){for(c=d=0,g=this.maxx-this.minx===0?1:this.maxx-this.minx,p=this.maxy-this.miny===0?1:this.maxy-this.miny,u=this.yvalues.length-1,o&&(4*o>n||4*o>a)&&(o=0),o&&(I=t.get("highlightSpotColor")&&!t.get("disableInteraction"),(I||t.get("minSpotColor")||t.get("spotColor")&&L[u]===this.miny)&&(a-=e.ceil(o)),(I||t.get("maxSpotColor")||t.get("spotColor")&&L[u]===this.maxy)&&(a-=e.ceil(o),c+=e.ceil(o)),(I||(t.get("minSpotColor")||t.get("maxSpotColor"))&&(L[0]===this.miny||L[0]===this.maxy))&&(d+=e.ceil(o),n-=e.ceil(o)),(I||t.get("spotColor")||t.get("minSpotColor")||t.get("maxSpotColor")&&(L[u]===this.miny||L[u]===this.maxy))&&(n-=e.ceil(o))),a--,t.get("normalRangeMin")!==i&&!t.get("drawNormalOnTop")&&this.drawNormalRange(d,c,a,n,p),m=[],v=[m],k=M=null,_=L.length,A=0;_>A;A++)x=P[A],w=P[A+1],C=L[A],b=d+e.round((x-this.minx)*(n/g)),S=_-1>A?d+e.round((w-this.minx)*(n/g)):n,M=b+(S-b)/2,l[A]=[k||0,M,A],k=M,null===C?A&&(null!==L[A-1]&&(m=[],v.push(m)),h.push(null)):(C<this.miny&&(C=this.miny),C>this.maxy&&(C=this.maxy),m.length||m.push([b,c+a]),f=[b,c+e.round(a-a*((C-this.miny)/p))],m.push(f),h.push(f));for(H=[],W=[],T=v.length,A=0;T>A;A++)m=v[A],m.length&&(t.get("fillColor")&&(m.push([m[m.length-1][0],c+a]),W.push(m.slice(0)),m.pop()),m.length>2&&(m[0]=[m[0][0],m[1][1]]),H.push(m));for(T=W.length,A=0;T>A;A++)r.drawShape(W[A],t.get("fillColor"),t.get("fillColor")).append();for(t.get("normalRangeMin")!==i&&t.get("drawNormalOnTop")&&this.drawNormalRange(d,c,a,n,p),T=H.length,A=0;T>A;A++)r.drawShape(H[A],t.get("lineColor"),i,t.get("lineWidth")).append();if(o&&t.get("valueSpots"))for(q=t.get("valueSpots"),q.get===i&&(q=new y(q)),A=0;_>A;A++)j=q.get(L[A]),j&&r.drawCircle(d+e.round((P[A]-this.minx)*(n/g)),c+e.round(a-a*((L[A]-this.miny)/p)),o,i,j).append();o&&t.get("spotColor")&&null!==L[u]&&r.drawCircle(d+e.round((P[P.length-1]-this.minx)*(n/g)),c+e.round(a-a*((L[u]-this.miny)/p)),o,i,t.get("spotColor")).append(),this.maxy!==this.minyorg&&(o&&t.get("minSpotColor")&&(x=P[s.inArray(this.minyorg,L)],r.drawCircle(d+e.round((x-this.minx)*(n/g)),c+e.round(a-a*((this.minyorg-this.miny)/p)),o,i,t.get("minSpotColor")).append()),o&&t.get("maxSpotColor")&&(x=P[s.inArray(this.maxyorg,L)],r.drawCircle(d+e.round((x-this.minx)*(n/g)),c+e.round(a-a*((this.maxyorg-this.miny)/p)),o,i,t.get("maxSpotColor")).append())),this.lastShapeId=r.getLastShapeId(),this.canvasTop=c,r.render()}}}),s.fn.sparkline.bar=S=a(s.fn.sparkline._base,b,{type:"bar",init:function(t,r,n,a,h){var l=parseInt(n.get("barWidth"),10),c=parseInt(n.get("barSpacing"),10),d=n.get("chartRangeMin"),f=n.get("chartRangeMax"),m=n.get("chartRangeClip"),v=1/0,x=-1/0,C,w,b,R,k,M,_,H,W,T,q,I,j,P,L,A,F,B,O,V,X,z,N;for(S._super.init.call(this,t,r,n,a,h),M=0,_=r.length;_>M;M++)V=r[M],C="string"==typeof V&&V.indexOf(":")>-1,(C||s.isArray(V))&&(L=!0,C&&(V=r[M]=p(V.split(":"))),V=u(V,null),w=e.min.apply(e,V),b=e.max.apply(e,V),v>w&&(v=w),b>x&&(x=b));this.stacked=L,this.regionShapes={},this.barWidth=l,this.barSpacing=c,this.totalBarWidth=l+c,this.width=a=r.length*l+(r.length-1)*c,this.initTarget(),m&&(j=d===i?-1/0:d,P=f===i?1/0:f),k=[],R=L?[]:k;var E=[],D=[];for(M=0,_=r.length;_>M;M++)if(L)for(A=r[M],r[M]=O=[],E[M]=0,R[M]=D[M]=0,F=0,B=A.length;B>F;F++)V=O[F]=m?o(A[F],j,P):A[F],null!==V&&(V>0&&(E[M]+=V),0>v&&x>0?0>V?D[M]+=e.abs(V):R[M]+=V:R[M]+=e.abs(V-(0>V?x:v)),k.push(V));else V=m?o(r[M],j,P):r[M],V=r[M]=g(V),null!==V&&k.push(V);this.max=I=e.max.apply(e,k),this.min=q=e.min.apply(e,k),this.stackMax=x=L?e.max.apply(e,E):I,this.stackMin=v=L?e.min.apply(e,k):q,n.get("chartRangeMin")!==i&&(n.get("chartRangeClip")||n.get("chartRangeMin")<q)&&(q=n.get("chartRangeMin")),n.get("chartRangeMax")!==i&&(n.get("chartRangeClip")||n.get("chartRangeMax")>I)&&(I=n.get("chartRangeMax")),this.zeroAxis=W=n.get("zeroAxis",!0),T=0>=q&&I>=0&&W?0:0==W?q:q>0?q:I,this.xaxisOffset=T,H=L?e.max.apply(e,R)+e.max.apply(e,D):I-q,this.canvasHeightEf=W&&0>q?this.canvasHeight-2:this.canvasHeight-1,T>q?(z=L&&I>=0?x:I,X=(z-T)/H*this.canvasHeight,X!==e.ceil(X)&&(this.canvasHeightEf-=2,X=e.ceil(X))):X=this.canvasHeight,this.yoffset=X,s.isArray(n.get("colorMap"))?(this.colorMapByIndex=n.get("colorMap"),this.colorMapByValue=null):(this.colorMapByIndex=null,this.colorMapByValue=n.get("colorMap"),this.colorMapByValue&&this.colorMapByValue.get===i&&(this.colorMapByValue=new y(this.colorMapByValue))),this.range=H},getRegion:function(t,s,r){var n=e.floor(s/this.totalBarWidth);return 0>n||n>=this.values.length?i:n},getCurrentRegionFields:function(){var t=this.currentRegion,e=v(this.values[t]),i=[],s,r;for(r=e.length;r--;)s=e[r],i.push({isNull:null===s,value:s,color:this.calcColor(r,s,t),offset:t});return i},calcColor:function(t,e,r){var n=this.colorMapByIndex,a=this.colorMapByValue,h=this.options,o,l;return o=h.get(this.stacked?"stackedBarColor":0>e?"negBarColor":"barColor"),0===e&&h.get("zeroColor")!==i&&(o=h.get("zeroColor")),a&&(l=a.get(e))?o=l:n&&n.length>r&&(o=n[r]),s.isArray(o)?o[t%o.length]:o},renderRegion:function(t,r){var n=this.values[t],a=this.options,h=this.xaxisOffset,o=[],l=this.range,g=this.stacked,p=this.target,u=t*this.totalBarWidth,c=this.canvasHeightEf,f=this.yoffset,m,v,x,y,C,w,b,R,S,k;if(n=s.isArray(n)?n:[n],b=n.length,R=n[0],y=d(null,n),k=d(h,n,!0),y)return a.get("nullColor")?(x=r?a.get("nullColor"):this.calcHighlightColor(a.get("nullColor"),a),m=f>0?f-1:f,p.drawRect(u,m,this.barWidth-1,0,x,x)):i;for(C=f,w=0;b>w;w++){if(R=n[w],g&&R===h){if(!k||S)continue;S=!0}v=l>0?e.floor(c*(e.abs(R-h)/l))+1:1,h>R||R===h&&0===f?(m=C,C+=v):(m=f-v,f-=v),x=this.calcColor(w,R,t),r&&(x=this.calcHighlightColor(x,a)),o.push(p.drawRect(u,m,this.barWidth-1,v-1,x,x))}return 1===o.length?o[0]:o}}),s.fn.sparkline.tristate=k=a(s.fn.sparkline._base,b,{type:"tristate",init:function(t,e,r,n,a){var h=parseInt(r.get("barWidth"),10),o=parseInt(r.get("barSpacing"),10);k._super.init.call(this,t,e,r,n,a),this.regionShapes={},this.barWidth=h,this.barSpacing=o,this.totalBarWidth=h+o,this.values=s.map(e,Number),this.width=n=e.length*h+(e.length-1)*o,s.isArray(r.get("colorMap"))?(this.colorMapByIndex=r.get("colorMap"),this.colorMapByValue=null):(this.colorMapByIndex=null,this.colorMapByValue=r.get("colorMap"),this.colorMapByValue&&this.colorMapByValue.get===i&&(this.colorMapByValue=new y(this.colorMapByValue))),this.initTarget()},getRegion:function(t,i,s){return e.floor(i/this.totalBarWidth)},getCurrentRegionFields:function(){var t=this.currentRegion;return{isNull:this.values[t]===i,value:this.values[t],color:this.calcColor(this.values[t],t),offset:t}},calcColor:function(t,e){var i=this.values,s=this.options,r=this.colorMapByIndex,n=this.colorMapByValue,a,h;return a=n&&(h=n.get(t))?h:r&&r.length>e?r[e]:s.get(i[e]<0?"negBarColor":i[e]>0?"posBarColor":"zeroBarColor")},renderRegion:function(t,i){var s=this.values,r=this.options,n=this.target,a,h,o,l,g,p;return a=n.pixelHeight,o=e.round(a/2),l=t*this.totalBarWidth,s[t]<0?(g=o,h=o-1):s[t]>0?(g=0,h=o-1):(g=o-1,h=2),p=this.calcColor(s[t],t),null!==p?(i&&(p=this.calcHighlightColor(p,r)),n.drawRect(l,g,this.barWidth-1,h-1,p,p)):void 0}}),s.fn.sparkline.discrete=M=a(s.fn.sparkline._base,b,{type:"discrete",init:function(t,r,n,a,h){M._super.init.call(this,t,r,n,a,h),this.regionShapes={},this.values=r=s.map(r,Number),this.min=e.min.apply(e,r),this.max=e.max.apply(e,r),this.range=this.max-this.min,this.width=a="auto"===n.get("width")?2*r.length:this.width,this.interval=e.floor(a/r.length),this.itemWidth=a/r.length,n.get("chartRangeMin")!==i&&(n.get("chartRangeClip")||n.get("chartRangeMin")<this.min)&&(this.min=n.get("chartRangeMin")),n.get("chartRangeMax")!==i&&(n.get("chartRangeClip")||n.get("chartRangeMax")>this.max)&&(this.max=n.get("chartRangeMax")),this.initTarget(),this.target&&(this.lineHeight="auto"===n.get("lineHeight")?e.round(.3*this.canvasHeight):n.get("lineHeight"))},getRegion:function(t,i,s){return e.floor(i/this.itemWidth)},getCurrentRegionFields:function(){var t=this.currentRegion;return{isNull:this.values[t]===i,value:this.values[t],offset:t}},renderRegion:function(t,i){var s=this.values,r=this.options,n=this.min,a=this.max,h=this.range,l=this.interval,g=this.target,p=this.canvasHeight,u=this.lineHeight,c=p-u,d,f,m,v;return f=o(s[t],n,a),v=t*l,d=e.round(c-c*((f-n)/h)),m=r.get(r.get("thresholdColor")&&f<r.get("thresholdValue")?"thresholdColor":"lineColor"),i&&(m=this.calcHighlightColor(m,r)),g.drawLine(v,d,v,d+u,m)}}),s.fn.sparkline.bullet=_=a(s.fn.sparkline._base,{type:"bullet",init:function(t,s,r,n,a){var h,o,l;_._super.init.call(this,t,s,r,n,a),this.values=s=p(s),l=s.slice(),l[0]=null===l[0]?l[2]:l[0],l[1]=null===s[1]?l[2]:l[1],h=e.min.apply(e,s),o=e.max.apply(e,s),h=r.get("base")===i?0>h?h:0:r.get("base"),this.min=h,this.max=o,this.range=o-h,this.shapes={},this.valueShapes={},this.regiondata={},this.width=n="auto"===r.get("width")?"4.0em":n,this.target=this.$el.simpledraw(n,a,r.get("composite")),s.length||(this.disabled=!0),this.initTarget()},getRegion:function(t,e,s){var r=this.target.getShapeAt(t,e,s);return r!==i&&this.shapes[r]!==i?this.shapes[r]:i},getCurrentRegionFields:function(){var t=this.currentRegion;return{fieldkey:t.substr(0,1),value:this.values[t.substr(1)],region:t}},changeHighlight:function(t){var e=this.currentRegion,i=this.valueShapes[e],s;switch(delete this.shapes[i],e.substr(0,1)){case"r":s=this.renderRange(e.substr(1),t);break;case"p":s=this.renderPerformance(t);break;case"t":s=this.renderTarget(t)}this.valueShapes[e]=s.id,this.shapes[s.id]=e,this.target.replaceWithShape(i,s)},renderRange:function(t,i){var s=this.values[t],r=e.round(this.canvasWidth*((s-this.min)/this.range)),n=this.options.get("rangeColors")[t-2];return i&&(n=this.calcHighlightColor(n,this.options)),this.target.drawRect(0,0,r-1,this.canvasHeight-1,n,n)},renderPerformance:function(t){var i=this.values[1],s=e.round(this.canvasWidth*((i-this.min)/this.range)),r=this.options.get("performanceColor");return t&&(r=this.calcHighlightColor(r,this.options)),this.target.drawRect(0,e.round(.3*this.canvasHeight),s-1,e.round(.4*this.canvasHeight)-1,r,r)},renderTarget:function(t){var i=this.values[0],s=e.round(this.canvasWidth*((i-this.min)/this.range)-this.options.get("targetWidth")/2),r=e.round(.1*this.canvasHeight),n=this.canvasHeight-2*r,a=this.options.get("targetColor");return t&&(a=this.calcHighlightColor(a,this.options)),this.target.drawRect(s,r,this.options.get("targetWidth")-1,n-1,a,a)},render:function(){var t=this.values.length,e=this.target,i,s;if(_._super.render.call(this)){for(i=2;t>i;i++)s=this.renderRange(i).append(),this.shapes[s.id]="r"+i,this.valueShapes["r"+i]=s.id;null!==this.values[1]&&(s=this.renderPerformance().append(),this.shapes[s.id]="p1",this.valueShapes.p1=s.id),null!==this.values[0]&&(s=this.renderTarget().append(),this.shapes[s.id]="t0",this.valueShapes.t0=s.id),e.render()}}}),s.fn.sparkline.pie=H=a(s.fn.sparkline._base,{type:"pie",init:function(t,i,r,n,a){var h=0,o;if(H._super.init.call(this,t,i,r,n,a),this.shapes={},this.valueShapes={},this.values=i=s.map(i,Number),"auto"===r.get("width")&&(this.width=this.height),i.length>0)for(o=i.length;o--;)h+=i[o];this.total=h,this.initTarget(),this.radius=e.floor(e.min(this.canvasWidth,this.canvasHeight)/2)},getRegion:function(t,e,s){var r=this.target.getShapeAt(t,e,s);return r!==i&&this.shapes[r]!==i?this.shapes[r]:i},getCurrentRegionFields:function(){var t=this.currentRegion;return{isNull:this.values[t]===i,value:this.values[t],percent:this.values[t]/this.total*100,color:this.options.get("sliceColors")[t%this.options.get("sliceColors").length],offset:t}},changeHighlight:function(t){var e=this.currentRegion,i=this.renderSlice(e,t),s=this.valueShapes[e];delete this.shapes[s],this.target.replaceWithShape(s,i),this.valueShapes[e]=i.id,this.shapes[i.id]=e},renderSlice:function(t,s){var r=this.target,n=this.options,a=this.radius,h=n.get("borderWidth"),o=n.get("offset"),l=2*e.PI,g=this.values,p=this.total,u=o?2*e.PI*(o/360):0,c,d,f,m,v;for(m=g.length,f=0;m>f;f++){if(c=u,d=u,p>0&&(d=u+l*(g[f]/p)),t===f)return v=n.get("sliceColors")[f%n.get("sliceColors").length],s&&(v=this.calcHighlightColor(v,n)),r.drawPieSlice(a,a,a-h,c,d,i,v);u=d}},render:function(){var t=this.target,s=this.values,r=this.options,n=this.radius,a=r.get("borderWidth"),h,o;
+if(H._super.render.call(this)){for(a&&t.drawCircle(n,n,e.floor(n-a/2),r.get("borderColor"),i,a).append(),o=s.length;o--;)s[o]&&(h=this.renderSlice(o).append(),this.valueShapes[o]=h.id,this.shapes[h.id]=o);t.render()}}}),s.fn.sparkline.box=W=a(s.fn.sparkline._base,{type:"box",init:function(t,e,i,r,n){W._super.init.call(this,t,e,i,r,n),this.values=s.map(e,Number),this.width="auto"===i.get("width")?"4.0em":r,this.initTarget(),this.values.length||(this.disabled=1)},getRegion:function(){return 1},getCurrentRegionFields:function(){var t=[{field:"lq",value:this.quartiles[0]},{field:"med",value:this.quartiles[1]},{field:"uq",value:this.quartiles[2]}];return this.loutlier!==i&&t.push({field:"lo",value:this.loutlier}),this.routlier!==i&&t.push({field:"ro",value:this.routlier}),this.lwhisker!==i&&t.push({field:"lw",value:this.lwhisker}),this.rwhisker!==i&&t.push({field:"rw",value:this.rwhisker}),t},render:function(){var t=this.target,s=this.values,r=s.length,n=this.options,a=this.canvasWidth,h=this.canvasHeight,o=n.get("chartRangeMin")===i?e.min.apply(e,s):n.get("chartRangeMin"),g=n.get("chartRangeMax")===i?e.max.apply(e,s):n.get("chartRangeMax"),p=0,u,c,d,f,m,v,x,y,C,w,b;if(W._super.render.call(this)){if(n.get("raw"))n.get("showOutliers")&&s.length>5?(c=s[0],u=s[1],f=s[2],m=s[3],v=s[4],x=s[5],y=s[6]):(u=s[0],f=s[1],m=s[2],v=s[3],x=s[4]);else if(s.sort(function(t,e){return t-e}),f=l(s,1),m=l(s,2),v=l(s,3),d=v-f,n.get("showOutliers")){for(u=x=i,C=0;r>C;C++)u===i&&s[C]>f-d*n.get("outlierIQR")&&(u=s[C]),s[C]<v+d*n.get("outlierIQR")&&(x=s[C]);c=s[0],y=s[r-1]}else u=s[0],x=s[r-1];this.quartiles=[f,m,v],this.lwhisker=u,this.rwhisker=x,this.loutlier=c,this.routlier=y,b=a/(g-o+1),n.get("showOutliers")&&(p=e.ceil(n.get("spotRadius")),a-=2*e.ceil(n.get("spotRadius")),b=a/(g-o+1),u>c&&t.drawCircle((c-o)*b+p,h/2,n.get("spotRadius"),n.get("outlierLineColor"),n.get("outlierFillColor")).append(),y>x&&t.drawCircle((y-o)*b+p,h/2,n.get("spotRadius"),n.get("outlierLineColor"),n.get("outlierFillColor")).append()),t.drawRect(e.round((f-o)*b+p),e.round(.1*h),e.round((v-f)*b),e.round(.8*h),n.get("boxLineColor"),n.get("boxFillColor")).append(),t.drawLine(e.round((u-o)*b+p),e.round(h/2),e.round((f-o)*b+p),e.round(h/2),n.get("lineColor")).append(),t.drawLine(e.round((u-o)*b+p),e.round(h/4),e.round((u-o)*b+p),e.round(h-h/4),n.get("whiskerColor")).append(),t.drawLine(e.round((x-o)*b+p),e.round(h/2),e.round((v-o)*b+p),e.round(h/2),n.get("lineColor")).append(),t.drawLine(e.round((x-o)*b+p),e.round(h/4),e.round((x-o)*b+p),e.round(h-h/4),n.get("whiskerColor")).append(),t.drawLine(e.round((m-o)*b+p),e.round(.1*h),e.round((m-o)*b+p),e.round(.9*h),n.get("medianColor")).append(),n.get("target")&&(w=e.ceil(n.get("spotRadius")),t.drawLine(e.round((n.get("target")-o)*b+p),e.round(h/2-w),e.round((n.get("target")-o)*b+p),e.round(h/2+w),n.get("targetColor")).append(),t.drawLine(e.round((n.get("target")-o)*b+p-w),e.round(h/2),e.round((n.get("target")-o)*b+p+w),e.round(h/2),n.get("targetColor")).append()),t.render()}}}),I=a({init:function(t,e,i,s){this.target=t,this.id=e,this.type=i,this.args=s},append:function(){return this.target.appendShape(this),this}}),j=a({_pxregex:/(\d+)(px)?\s*$/i,init:function(t,e,i){t&&(this.width=t,this.height=e,this.target=i,this.lastShapeId=null,i[0]&&(i=i[0]),s.data(i,"_jqs_vcanvas",this))},drawLine:function(t,e,i,s,r,n){return this.drawShape([[t,e],[i,s]],r,n)},drawShape:function(t,e,i,s){return this._genShape("Shape",[t,e,i,s])},drawCircle:function(t,e,i,s,r,n){return this._genShape("Circle",[t,e,i,s,r,n])},drawPieSlice:function(t,e,i,s,r,n,a){return this._genShape("PieSlice",[t,e,i,s,r,n,a])},drawRect:function(t,e,i,s,r,n){return this._genShape("Rect",[t,e,i,s,r,n])},getElement:function(){return this.canvas},getLastShapeId:function(){return this.lastShapeId},reset:function(){alert("reset not implemented")},_insert:function(t,e){s(e).html(t)},_calculatePixelDims:function(t,e,i){var r;r=this._pxregex.exec(e),this.pixelHeight=r?r[1]:s(i).height(),r=this._pxregex.exec(t),this.pixelWidth=r?r[1]:s(i).width()},_genShape:function(t,e){var i=F++;return e.unshift(i),new I(this,i,t,e)},appendShape:function(t){alert("appendShape not implemented")},replaceWithShape:function(t,e){alert("replaceWithShape not implemented")},insertAfterShape:function(t,e){alert("insertAfterShape not implemented")},removeShapeId:function(t){alert("removeShapeId not implemented")},getShapeAt:function(t,e,i){alert("getShapeAt not implemented")},render:function(){alert("render not implemented")}}),P=a(j,{init:function(e,r,n,a){P._super.init.call(this,e,r,n),this.canvas=t.createElement("canvas"),n[0]&&(n=n[0]),s.data(n,"_jqs_vcanvas",this),s(this.canvas).css({display:"inline-block",width:e,height:r,verticalAlign:"top"}),this._insert(this.canvas,n),this._calculatePixelDims(e,r,this.canvas),this.canvas.width=this.pixelWidth,this.canvas.height=this.pixelHeight,this.interact=a,this.shapes={},this.shapeseq=[],this.currentTargetShapeId=i,s(this.canvas).css({width:this.pixelWidth,height:this.pixelHeight})},_getContext:function(t,e,s){var r=this.canvas.getContext("2d");return t!==i&&(r.strokeStyle=t),r.lineWidth=s===i?1:s,e!==i&&(r.fillStyle=e),r},reset:function(){var t=this._getContext();t.clearRect(0,0,this.pixelWidth,this.pixelHeight),this.shapes={},this.shapeseq=[],this.currentTargetShapeId=i},_drawShape:function(t,e,s,r,n){var a=this._getContext(s,r,n),h,o;for(a.beginPath(),a.moveTo(e[0][0]+.5,e[0][1]+.5),h=1,o=e.length;o>h;h++)a.lineTo(e[h][0]+.5,e[h][1]+.5);s!==i&&a.stroke(),r!==i&&a.fill(),this.targetX!==i&&this.targetY!==i&&a.isPointInPath(this.targetX,this.targetY)&&(this.currentTargetShapeId=t)},_drawCircle:function(t,s,r,n,a,h,o){var l=this._getContext(a,h,o);l.beginPath(),l.arc(s,r,n,0,2*e.PI,!1),this.targetX!==i&&this.targetY!==i&&l.isPointInPath(this.targetX,this.targetY)&&(this.currentTargetShapeId=t),a!==i&&l.stroke(),h!==i&&l.fill()},_drawPieSlice:function(t,e,s,r,n,a,h,o){var l=this._getContext(h,o);l.beginPath(),l.moveTo(e,s),l.arc(e,s,r,n,a,!1),l.lineTo(e,s),l.closePath(),h!==i&&l.stroke(),o&&l.fill(),this.targetX!==i&&this.targetY!==i&&l.isPointInPath(this.targetX,this.targetY)&&(this.currentTargetShapeId=t)},_drawRect:function(t,e,i,s,r,n,a){return this._drawShape(t,[[e,i],[e+s,i],[e+s,i+r],[e,i+r],[e,i]],n,a)},appendShape:function(t){return this.shapes[t.id]=t,this.shapeseq.push(t.id),this.lastShapeId=t.id,t.id},replaceWithShape:function(t,e){var i=this.shapeseq,s;for(this.shapes[e.id]=e,s=i.length;s--;)i[s]==t&&(i[s]=e.id);delete this.shapes[t]},replaceWithShapes:function(t,e){var i=this.shapeseq,s={},r,n,a;for(n=t.length;n--;)s[t[n]]=!0;for(n=i.length;n--;)r=i[n],s[r]&&(i.splice(n,1),delete this.shapes[r],a=n);for(n=e.length;n--;)i.splice(a,0,e[n].id),this.shapes[e[n].id]=e[n]},insertAfterShape:function(t,e){var i=this.shapeseq,s;for(s=i.length;s--;)if(i[s]===t)return i.splice(s+1,0,e.id),void(this.shapes[e.id]=e)},removeShapeId:function(t){var e=this.shapeseq,i;for(i=e.length;i--;)if(e[i]===t){e.splice(i,1);break}delete this.shapes[t]},getShapeAt:function(t,e,i){return this.targetX=e,this.targetY=i,this.render(),this.currentTargetShapeId},render:function(){var t=this.shapeseq,e=this.shapes,i=t.length,s=this._getContext(),r,n,a;for(s.clearRect(0,0,this.pixelWidth,this.pixelHeight),a=0;i>a;a++)r=t[a],n=e[r],this["_draw"+n.type].apply(this,n.args);this.interact||(this.shapes={},this.shapeseq=[])}}),L=a(j,{init:function(e,i,r){var n;L._super.init.call(this,e,i,r),r[0]&&(r=r[0]),s.data(r,"_jqs_vcanvas",this),this.canvas=t.createElement("span"),s(this.canvas).css({display:"inline-block",position:"relative",overflow:"hidden",width:e,height:i,margin:"0px",padding:"0px",verticalAlign:"top"}),this._insert(this.canvas,r),this._calculatePixelDims(e,i,this.canvas),this.canvas.width=this.pixelWidth,this.canvas.height=this.pixelHeight,n='<v:group coordorigin="0 0" coordsize="'+this.pixelWidth+" "+this.pixelHeight+'" style="position:absolute;top:0;left:0;width:'+this.pixelWidth+"px;height="+this.pixelHeight+'px;"></v:group>',this.canvas.insertAdjacentHTML("beforeEnd",n),this.group=s(this.canvas).children()[0],this.rendered=!1,this.prerender=""},_drawShape:function(t,e,s,r,n){var a=[],h,o,l,g,p,u,c;for(c=0,u=e.length;u>c;c++)a[c]=""+e[c][0]+","+e[c][1];return h=a.splice(0,1),n=n===i?1:n,o=s===i?' stroked="false" ':' strokeWeight="'+n+'px" strokeColor="'+s+'" ',l=r===i?' filled="false"':' fillColor="'+r+'" filled="true" ',g=a[0]===a[a.length-1]?"x ":"",p='<v:shape coordorigin="0 0" coordsize="'+this.pixelWidth+" "+this.pixelHeight+'" id="jqsshape'+t+'" '+o+l+' style="position:absolute;left:0px;top:0px;height:'+this.pixelHeight+"px;width:"+this.pixelWidth+'px;padding:0px;margin:0px;" path="m '+h+" l "+a.join(", ")+" "+g+'e"> </v:shape>'},_drawCircle:function(t,e,s,r,n,a,h){var o,l,g;return e-=r,s-=r,o=n===i?' stroked="false" ':' strokeWeight="'+h+'px" strokeColor="'+n+'" ',l=a===i?' filled="false"':' fillColor="'+a+'" filled="true" ',g='<v:oval id="jqsshape'+t+'" '+o+l+' style="position:absolute;top:'+s+"px; left:"+e+"px; width:"+2*r+"px; height:"+2*r+'px"></v:oval>'},_drawPieSlice:function(t,s,r,n,a,h,o,l){var g,p,u,c,d,f,m,v;if(a===h)return"";if(h-a===2*e.PI&&(a=0,h=2*e.PI),p=s+e.round(e.cos(a)*n),u=r+e.round(e.sin(a)*n),c=s+e.round(e.cos(h)*n),d=r+e.round(e.sin(h)*n),p===c&&u===d){if(h-a<e.PI)return"";p=c=s+n,u=d=r}return p===c&&u===d&&h-a<e.PI?"":(g=[s-n,r-n,s+n,r+n,p,u,c,d],f=o===i?' stroked="false" ':' strokeWeight="1px" strokeColor="'+o+'" ',m=l===i?' filled="false"':' fillColor="'+l+'" filled="true" ',v='<v:shape coordorigin="0 0" coordsize="'+this.pixelWidth+" "+this.pixelHeight+'" id="jqsshape'+t+'" '+f+m+' style="position:absolute;left:0px;top:0px;height:'+this.pixelHeight+"px;width:"+this.pixelWidth+'px;padding:0px;margin:0px;" path="m '+s+","+r+" wa "+g.join(", ")+' x e"> </v:shape>')},_drawRect:function(t,e,i,s,r,n,a){return this._drawShape(t,[[e,i],[e,i+r],[e+s,i+r],[e+s,i],[e,i]],n,a)},reset:function(){this.group.innerHTML=""},appendShape:function(t){var e=this["_draw"+t.type].apply(this,t.args);return this.rendered?this.group.insertAdjacentHTML("beforeEnd",e):this.prerender+=e,this.lastShapeId=t.id,t.id},replaceWithShape:function(t,e){var i=s("#jqsshape"+t),r=this["_draw"+e.type].apply(this,e.args);i[0].outerHTML=r},replaceWithShapes:function(t,e){var i=s("#jqsshape"+t[0]),r="",n=e.length,a;for(a=0;n>a;a++)r+=this["_draw"+e[a].type].apply(this,e[a].args);for(i[0].outerHTML=r,a=1;a<t.length;a++)s("#jqsshape"+t[a]).remove()},insertAfterShape:function(t,e){var i=s("#jqsshape"+t),r=this["_draw"+e.type].apply(this,e.args);i[0].insertAdjacentHTML("afterEnd",r)},removeShapeId:function(t){var e=s("#jqsshape"+t);this.group.removeChild(e[0])},getShapeAt:function(t,e,i){var s=t.id.substr(8);return s},render:function(){this.rendered||(this.group.innerHTML=this.prerender,this.rendered=!0)}})})}(document,Math)}();
+
+!function(){"undefined"==typeof web3&&(web3=require("web3"),web3.setProvider(new web3.providers.HttpSyncProvider("http://localhost:8545")))}();
+
+!function(){Template.views_home.created=function(){var e=Blocks.findOne({},{sort:{number:-1}}),t=GeoPattern.generate(e?e.hash:"---");$(".latest-block-info").css("background-image",t.toDataUrl());try{if(void 0!=web3.eth.number)for(currentBlock=web3.eth.number,Blocks.remove({number:{$lt:currentBlock-50}}),i=currentBlock;i>currentBlock-10;i--)Blocks.upsert("block_"+i,{_id:"block_"+i,number:i,gasUsed:web3.eth.block(i).gasUsed,size:web3.eth.block(i).size,time:web3.eth.block(i).time,hash:web3.eth.block(i).hash,miner:web3.eth.block(i).coinbase,uncles:web3.eth.block(i).uncles.Length})}catch(n){console.log("no web3 object")}},Template.views_home.destroyed=function(){},Template.views_home.helpers({blocks:function(){var e=Blocks.find({},{limit:50,sort:{number:-1}}),t=Template.instance();return Tracker.afterFlush(function(){t.view.isRendered&&t.$(".wrapper").css("width",562*e.count()+500+"px")}),e.fetch()},currentBlockPattern:function(){var e=GeoPattern.generate(this.hash);return e?e.toDataUrl():"white"},peerCount:function(){try{return web3.eth.peerCount}catch(e){return"---"}},gasPrice:function(){try{return EthTools.fromWei(web3.eth.gasPrice,"finney")}catch(e){return"---"}},miningSlider:function(){return Miner.mining||0},hashrate:function(){return Miner.hashrate},timeSpent:function(){var e=MiningData.findOne().totalTimeSpent;return e?180>e?Math.round(10*e)/10+"<small> Seconds </small>":10800>e?Math.round(10*e/60)/10+"<small> Minutes </small>":86400>e?Math.round(10*e/3600)/10+"<small> Hours </small>":Math.round(10*e/86400)/10+"<small> Days </small>":"---"},totalRewards:function(){var e=MiningData.findOne().totalRewards;return e&&e>0?1e3>e?Math.floor(100*e)/100+"<small> Finney </small>":e>1e6?Math.floor(e/1e3).toString().replace(/\B(?=(\d{3})+(?!\d))/g,",")+"<small> Ether </small>":Math.floor(e/10)/100+"<small> Ether </small>":"---"},averageRewardPerHour:function(){var e=MiningData.findOne().totalRewards,t=MiningData.findOne().totalTimeSpent;if(e&&t>0){var n=3600*e/t;return 1e3>n?Math.floor(100*n)/100+"<small> Finney/h </small>":n>1e6?Math.floor(n/1e3).toString().replace(/\B(?=(\d{3})+(?!\d))/g,",")+"<small> Ether/h </small>":Math.floor(n/10)/100+"<small> Ether/h </small>";return reward}return"---"}}),Template.views_home.events({"change input.slider-vertical, input input.slider-vertical":function(e){Miner.mining=Number(e.currentTarget.value)}})}();
+
+!function(){Blocks=new Mongo.Collection("blocks",{connection:null}),new PersistentMinimongo(Blocks),MiningData=new Mongo.Collection("miningdata",{connection:null}),new PersistentMinimongo(MiningData),MiningData.findOne()||MiningData.insert({totalTimeSpent:0,lastCoinbaseBalance:0,totalRewards:0})}();
+
+!function(){"localhost:3000"!==location.host&&"127.0.0.1:3000"!==location.host&&Meteor.disconnect(),Meteor.startup(function(){if(Cookie.get("TAPi18next"))TAPi18n.setLanguage(Cookie.get("TAPi18next"));else{var e=navigator.language||navigator.userLanguage,n=TAPi18n.getLanguages();TAPi18n.setLanguage(_.isObject(n)&&n[e]?e:_.isObject(n)&&n[e.substr(0,2)]?e.substr(0,2):"en")}Tracker.autorun(function(){_.isString(TAPi18n.getLanguage())&&(moment.locale(TAPi18n.getLanguage().substr(0,2)),numeral.language(TAPi18n.getLanguage().substr(0,2)))})})}();
+
+!function(){var e=function(e,n,r){_.isUndefined(r)||(e["__tracker_"+n+"_value__"]=r),e["__tracker_"+n+"_dependency__"]=new Tracker.Dependency,Object.defineProperty(e,n,{get:function(){return this["__tracker_"+n+"_dependency__"].depend(),this["__tracker_"+n+"_value__"]},set:function(_){_!==this["__tracker_"+n+"_value__"]&&(this["__tracker_"+n+"_value__"]=_,this["__tracker_"+n+"_dependency__"].changed())}})};Miner={},e(Miner,"mining",0),e(Miner,"hashrate",0)}();
+
+!function(){Router.configure({layoutTemplate:"layout_main",yieldRegions:{layout_header:{to:"header"}},autoRun:!1,autoRender:!1}),Router.route("/",{template:"views_home",name:"home"}),Router.route("/profile",{template:"views_home",name:"userProfile"})}();
+
+!function(){var e=web3.eth.watch("chain");e.changed(function(e){if(e.number=web3.eth.number,Blocks.upsert("block_"+e.number,{_id:"block_"+e.number,number:e.number,gasUsed:web3.eth.block(e.number).gasUsed,size:web3.eth.block(e.number).size,time:web3.eth.block(e.number).time,hash:web3.eth.block(e.number).hash,miner:web3.eth.block(e.number).coinbase,uncles:web3.eth.block(e.number).uncles.Length}),web3.eth.coinbase==web3.eth.block(e.number).coinbase){var a=MiningData.findOne();WeiToFin=1e15,lastBalance=a.lastCoinbaseBalance||Number(web3.toDecimal(web3.eth.balanceAt(web3.eth.coinbase)))/WeiToFin,currentBalance=Number(web3.toDecimal(web3.eth.balanceAt(web3.eth.coinbase)))/WeiToFin,blockReward=currentBalance-lastBalance,console.log("New Block! last balance: "+a.lastCoinbaseBalance+" Reward: "+blockReward),MiningData.update(a._id,{$inc:{totalRewards:blockReward}}),MiningData.update(a._id,{$set:{lastCoinbaseBalance:currentBalance}})}else{WeiToFin=1e15,currentBalance=Number(web3.toDecimal(web3.eth.balanceAt(web3.eth.coinbase)))/WeiToFin;var a=MiningData.findOne();MiningData.update(a._id,{lastCoinbaseBalance:currentBalance}),console.log("New Block! last balance: "+a.lastCoinbaseBalance)}})}();
+
+!function(){var n=Package.underscore._,e="project",o="project";"project"!=e&&(o=TAPi18n.packages[e].namespace),TAPi18n._enable({helper_name:"_",supported_languages:null,i18n_files_route:"/tap-i18n",cdn_path:null}),TAPi18n.languages_names.en=["English","English"],translations={},translations[o]={app:{loading:"Loading...",offline:"Can't connect are you offline?",logginIn:"Logging in..."},error:{insufficientRights:"You don't have enough rights for this action."},buttons:{ok:"OK",cancel:"Cancel",save:"Save",edit:"edit",send:"Send",create:"Create",tryToReconnect:"Try to reconnect"},commonWords:{you:"You",send:"Send",or:"or","with":"with",and:"and",on:"on",off:"off",per:"per"}},TAPi18n._loadLangFileObject("en",translations)}();
+
+!function(){var e=Package.underscore._,n="project",a="project";"project"!=n&&(a=TAPi18n.packages[n].namespace),translations={},translations[a]={network:{home:{NetworkHealth:"Network Health",Mining:"Mining",MiningStatus:"Mining Status",on:"On",off:"Off",TimeSpent:"Time Spent",Rewards:"Rewards",AverageReward:"Average Reward",Connections:"Connections",PeerCount:"Peer Count",Peers:"Peers",GasPrice:"Gas Price",Finney:"Finney",Blockchain:"Blockchain",Block:"Block",GasUsed:"Gas Used",Size:"Size",Uncles:"Number of uncles",Time:"Time",EndOfBlocks:"No more loaded blocks"}}},TAPi18n._loadLangFileObject("en",translations)}();
+
+!function(){TAPi18n._enable({helper_name:"i18n",supported_languages:["en","de"],i18n_files_route:"/i18n",cdn_path:null}),TAPi18n.languages_names.en=["English","English"],TAPi18n.languages_names.en=["English","English"],TAPi18n.languages_names.de=["German","Deutsch"]}(); \ No newline at end of file
diff --git a/cmd/mist/assets/qml/views/network-health/529f30ee0ee386c5143b4ccb62073179ca8253c3.css b/cmd/mist/assets/qml/views/network-health/529f30ee0ee386c5143b4ccb62073179ca8253c3.css
new file mode 100644
index 000000000..379e5808b
--- /dev/null
+++ b/cmd/mist/assets/qml/views/network-health/529f30ee0ee386c5143b4ccb62073179ca8253c3.css
@@ -0,0 +1,4 @@
+@font-face{font-family:'Simple-Line-Icons';src:url('packages/ethereum_elements/icons/Simple-Line-Icons.eot');src:url('packages/ethereum_elements/icons/Simple-Line-Icons.eot?') format('embedded-opentype'),
+ url('packages/ethereum_elements/icons/Simple-Line-Icons.woff') format('woff'),
+ url('packages/ethereum_elements/icons/Simple-Line-Icons.ttf') format('truetype'),
+ url('packages/ethereum_elements/icons/Simple-Line-Icons.svg') format('svg');font-weight:normal;font-style:normal}[data-icon]:before{font-family:'Simple-Line-Icons';content:attr(data-icon);speak:none;font-weight:normal;font-variant:normal;text-transform:none;line-height:1;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.icon-user-female,.icon-user-follow,.icon-user-following,.icon-user-unfollow,.icon-trophy,.icon-screen-smartphone,.icon-screen-desktop,.icon-plane,.icon-notebook,.icon-moustache,.icon-mouse,.icon-magnet,.icon-energy,.icon-emoticon-smile,.icon-disc,.icon-cursor-move,.icon-crop,.icon-credit-card,.icon-chemistry,.icon-user,.icon-speedometer,.icon-social-youtube,.icon-social-twitter,.icon-social-tumblr,.icon-social-facebook,.icon-social-dropbox,.icon-social-dribbble,.icon-shield,.icon-screen-tablet,.icon-magic-wand,.icon-hourglass,.icon-graduation,.icon-ghost,.icon-game-controller,.icon-fire,.icon-eyeglasses,.icon-envelope-open,.icon-envelope-letter,.icon-bell,.icon-badge,.icon-anchor,.icon-wallet,.icon-vector,.icon-speech,.icon-puzzle,.icon-printer,.icon-present,.icon-playlist,.icon-pin,.icon-picture,.icon-map,.icon-layers,.icon-handbag,.icon-globe-alt,.icon-globe,.icon-frame,.icon-folder-alt,.icon-film,.icon-feed,.icon-earphones-alt,.icon-earphones,.icon-drop,.icon-drawer,.icon-docs,.icon-directions,.icon-direction,.icon-diamond,.icon-cup,.icon-compass,.icon-call-out,.icon-call-in,.icon-call-end,.icon-calculator,.icon-bubbles,.icon-briefcase,.icon-book-open,.icon-basket-loaded,.icon-basket,.icon-bag,.icon-action-undo,.icon-action-redo,.icon-wrench,.icon-umbrella,.icon-trash,.icon-tag,.icon-support,.icon-size-fullscreen,.icon-size-actual,.icon-shuffle,.icon-share-alt,.icon-share,.icon-rocket,.icon-question,.icon-pie-chart,.icon-pencil,.icon-note,.icon-music-tone-alt,.icon-music-tone,.icon-microphone,.icon-loop,.icon-logout,.icon-login,.icon-list,.icon-like,.icon-home,.icon-grid,.icon-graph,.icon-equalizer,.icon-dislike,.icon-cursor,.icon-control-start,.icon-control-rewind,.icon-control-play,.icon-control-pause,.icon-control-forward,.icon-control-end,.icon-calendar,.icon-bulb,.icon-bar-chart,.icon-arrow-up,.icon-arrow-right,.icon-arrow-left,.icon-arrow-down,.icon-ban,.icon-bubble,.icon-camcorder,.icon-camera,.icon-check,.icon-clock,.icon-close,.icon-cloud-download,.icon-cloud-upload,.icon-doc,.icon-envelope,.icon-eye,.icon-flag,.icon-folder,.icon-heart,.icon-info,.icon-key,.icon-link,.icon-lock,.icon-lock-open,.icon-magnifier,.icon-magnifier-add,.icon-magnifier-remove,.icon-paper-clip,.icon-paper-plane,.icon-plus,.icon-pointer,.icon-power,.icon-refresh,.icon-reload,.icon-settings,.icon-star,.icon-symbol-female,.icon-symbol-male,.icon-target,.icon-volume-1,.icon-volume-2,.icon-volume-off,.icon-users{font-family:'Simple-Line-Icons';speak:none;font-style:normal;font-weight:normal;font-variant:normal;text-transform:none;line-height:1;-webkit-font-smoothing:antialiased}.icon-user-female:before{content:"\e000"}.icon-user-follow:before{content:"\e002"}.icon-user-following:before{content:"\e003"}.icon-user-unfollow:before{content:"\e004"}.icon-trophy:before{content:"\e006"}.icon-screen-smartphone:before{content:"\e010"}.icon-screen-desktop:before{content:"\e011"}.icon-plane:before{content:"\e012"}.icon-notebook:before{content:"\e013"}.icon-moustache:before{content:"\e014"}.icon-mouse:before{content:"\e015"}.icon-magnet:before{content:"\e016"}.icon-energy:before{content:"\e020"}.icon-emoticon-smile:before{content:"\e021"}.icon-disc:before{content:"\e022"}.icon-cursor-move:before{content:"\e023"}.icon-crop:before{content:"\e024"}.icon-credit-card:before{content:"\e025"}.icon-chemistry:before{content:"\e026"}.icon-user:before{content:"\e005"}.icon-speedometer:before{content:"\e007"}.icon-social-youtube:before{content:"\e008"}.icon-social-twitter:before{content:"\e009"}.icon-social-tumblr:before{content:"\e00a"}.icon-social-facebook:before{content:"\e00b"}.icon-social-dropbox:before{content:"\e00c"}.icon-social-dribbble:before{content:"\e00d"}.icon-shield:before{content:"\e00e"}.icon-screen-tablet:before{content:"\e00f"}.icon-magic-wand:before{content:"\e017"}.icon-hourglass:before{content:"\e018"}.icon-graduation:before{content:"\e019"}.icon-ghost:before{content:"\e01a"}.icon-game-controller:before{content:"\e01b"}.icon-fire:before{content:"\e01c"}.icon-eyeglasses:before{content:"\e01d"}.icon-envelope-open:before{content:"\e01e"}.icon-envelope-letter:before{content:"\e01f"}.icon-bell:before{content:"\e027"}.icon-badge:before{content:"\e028"}.icon-anchor:before{content:"\e029"}.icon-wallet:before{content:"\e02a"}.icon-vector:before{content:"\e02b"}.icon-speech:before{content:"\e02c"}.icon-puzzle:before{content:"\e02d"}.icon-printer:before{content:"\e02e"}.icon-present:before{content:"\e02f"}.icon-playlist:before{content:"\e030"}.icon-pin:before{content:"\e031"}.icon-picture:before{content:"\e032"}.icon-map:before{content:"\e033"}.icon-layers:before{content:"\e034"}.icon-handbag:before{content:"\e035"}.icon-globe-alt:before{content:"\e036"}.icon-globe:before{content:"\e037"}.icon-frame:before{content:"\e038"}.icon-folder-alt:before{content:"\e039"}.icon-film:before{content:"\e03a"}.icon-feed:before{content:"\e03b"}.icon-earphones-alt:before{content:"\e03c"}.icon-earphones:before{content:"\e03d"}.icon-drop:before{content:"\e03e"}.icon-drawer:before{content:"\e03f"}.icon-docs:before{content:"\e040"}.icon-directions:before{content:"\e041"}.icon-direction:before{content:"\e042"}.icon-diamond:before{content:"\e043"}.icon-cup:before{content:"\e044"}.icon-compass:before{content:"\e045"}.icon-call-out:before{content:"\e046"}.icon-call-in:before{content:"\e047"}.icon-call-end:before{content:"\e048"}.icon-calculator:before{content:"\e049"}.icon-bubbles:before{content:"\e04a"}.icon-briefcase:before{content:"\e04b"}.icon-book-open:before{content:"\e04c"}.icon-basket-loaded:before{content:"\e04d"}.icon-basket:before{content:"\e04e"}.icon-bag:before{content:"\e04f"}.icon-action-undo:before{content:"\e050"}.icon-action-redo:before{content:"\e051"}.icon-wrench:before{content:"\e052"}.icon-umbrella:before{content:"\e053"}.icon-trash:before{content:"\e054"}.icon-tag:before{content:"\e055"}.icon-support:before{content:"\e056"}.icon-size-fullscreen:before{content:"\e057"}.icon-size-actual:before{content:"\e058"}.icon-shuffle:before{content:"\e059"}.icon-share-alt:before{content:"\e05a"}.icon-share:before{content:"\e05b"}.icon-rocket:before{content:"\e05c"}.icon-question:before{content:"\e05d"}.icon-pie-chart:before{content:"\e05e"}.icon-pencil:before{content:"\e05f"}.icon-note:before{content:"\e060"}.icon-music-tone-alt:before{content:"\e061"}.icon-music-tone:before{content:"\e062"}.icon-microphone:before{content:"\e063"}.icon-loop:before{content:"\e064"}.icon-logout:before{content:"\e065"}.icon-login:before{content:"\e066"}.icon-list:before{content:"\e067"}.icon-like:before{content:"\e068"}.icon-home:before{content:"\e069"}.icon-grid:before{content:"\e06a"}.icon-graph:before{content:"\e06b"}.icon-equalizer:before{content:"\e06c"}.icon-dislike:before{content:"\e06d"}.icon-cursor:before{content:"\e06e"}.icon-control-start:before{content:"\e06f"}.icon-control-rewind:before{content:"\e070"}.icon-control-play:before{content:"\e071"}.icon-control-pause:before{content:"\e072"}.icon-control-forward:before{content:"\e073"}.icon-control-end:before{content:"\e074"}.icon-calendar:before{content:"\e075"}.icon-bulb:before{content:"\e076"}.icon-bar-chart:before{content:"\e077"}.icon-arrow-up:before{content:"\e078"}.icon-arrow-right:before{content:"\e079"}.icon-arrow-left:before{content:"\e07a"}.icon-arrow-down:before{content:"\e07b"}.icon-ban:before{content:"\e07c"}.icon-bubble:before{content:"\e07d"}.icon-camcorder:before{content:"\e07e"}.icon-camera:before{content:"\e07f"}.icon-check:before{content:"\e080"}.icon-clock:before{content:"\e081"}.icon-close:before{content:"\e082"}.icon-cloud-download:before{content:"\e083"}.icon-cloud-upload:before{content:"\e084"}.icon-doc:before{content:"\e085"}.icon-envelope:before{content:"\e086"}.icon-eye:before{content:"\e087"}.icon-flag:before{content:"\e088"}.icon-folder:before{content:"\e089"}.icon-heart:before{content:"\e08a"}.icon-info:before{content:"\e08b"}.icon-key:before{content:"\e08c"}.icon-link:before{content:"\e08d"}.icon-lock:before{content:"\e08e"}.icon-lock-open:before{content:"\e08f"}.icon-magnifier:before{content:"\e090"}.icon-magnifier-add:before{content:"\e091"}.icon-magnifier-remove:before{content:"\e092"}.icon-paper-clip:before{content:"\e093"}.icon-paper-plane:before{content:"\e094"}.icon-plus:before{content:"\e095"}.icon-pointer:before{content:"\e096"}.icon-power:before{content:"\e097"}.icon-refresh:before{content:"\e098"}.icon-reload:before{content:"\e099"}.icon-settings:before{content:"\e09a"}.icon-star:before{content:"\e09b"}.icon-symbol-female:before{content:"\e09c"}.icon-symbol-male:before{content:"\e09d"}.icon-target:before{content:"\e09e"}.icon-volume-1:before{content:"\e09f"}.icon-volume-2:before{content:"\e0a0"}.icon-volume-off:before{content:"\e0a1"}.icon-users:before{content:"\e001"}body.disable-scroll{overflow:hidden}body.blur .dapp-flex-content,body.blur .dapp-footer,body.blur .dapp-header{-webkit-filter:blur(4px);-moz-filter:blur(4px);-ms-filter:blur(4px);filter:blur(4px)}.dapp-modal-overlay{z-index:99;position:fixed;top:0;left:0;right:0;bottom:0;display:-webkit-box;display:-moz-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-align:start;-moz-box-align:start;-webkit-align-items:flex-start;-ms-flex-align:start;align-items:flex-start;-webkit-box-pack:center;-moz-box-pack:center;-ms-flex-pack:center;-webkit-justify-content:center;justify-content:center;overflow-y:auto;overflow-x:hidden;-webkit-overflow-scrolling:touch;background:rgba(17, 17, 17, 0.5);-webkit-transition:opacity 400ms;-moz-transition:opacity 400ms;-o-transition:opacity 400ms;transition:opacity 400ms}.dapp-modal-overlay.animate{zoom:1;filter:alpha(opacity=0);-webkit-opacity:0;-moz-opacity:0;opacity:0}.dapp-modal-overlay.animate .dapp-modal-container{-webkit-transform:translateY(-20%);-moz-transform:translateY(-20%);-o-transform:translateY(-20%);-ms-transform:translateY(-20%);transform:translateY(-20%)}.dapp-modal-container{position:relative;width:448px;margin:110.4px auto;padding:18.4px 32px;background:#fafafa;box-sizing:border-box;box-shadow:0 1px 4px rgba(0, 0, 0, 0.3);border-radius:3px;text-align:center;-webkit-transition:-webkit-transform 400ms;-moz-transition:-moz-transform 400ms;-o-transition:-o-transform 400ms;transition:-webkit-transform 400ms,-moz-transform 400ms,-o-transform 400ms,transform 400ms}.dapp-modal-container .dapp-modal-header{position:relative;padding:36.8px 0;margin:-18.4px -32px;margin-bottom:18.4px;border-radius:2px 2px 0 0;color:#111111;line-height:36.8px;text-align:center}.dapp-modal-container .dapp-modal-header.dapp-pattern{color:#fafafa}.dapp-modal-container .dapp-modal-header h1{margin:0}.dapp-modal-container .dapp-modal-header .dapp-identicon{position:absolute;top:-34.96px;left:50%;margin-left:-32px}.dapp-modal-container p{margin:36.8px 0;line-height:22.08px;font-size:1.2em}.dapp-overflow{overflow-y:auto;overflow-x:hidden;-webkit-overflow-scrolling:touch}.dapp-shadow-none{box-shadow:0 0 0 rgba(0, 0, 0, 0)}.dapp-shadow-small{box-shadow:0 0px 1px rgba(0, 0, 0, 0.3)}.dapp-shadow-medium{box-shadow:0 1px 4px rgba(0, 0, 0, 0.3)}.dapp-shadow-large{box-shadow:0 1px 16px rgba(0, 0, 0, 0.3)}.dapp-input{display:inline-block;width:300px;max-width:100%;margin-top:18.4px;padding:9.2px 16px;padding-bottom:6.13333333px;border:0;border-bottom:solid 2px #dddcdb;box-sizing:border-box;background-color:#f5f4f2;font-size:1em;font-weight:300;color:#6691c2}.dapp-input::-webkit-input-placeholder{color:#dddcdb}.dapp-input:-moz-placeholder{color:#dddcdb}.dapp-input::-moz-placeholder{color:#dddcdb}.dapp-input:-ms-input-placeholder{color:#dddcdb}.dapp-input:focus{outline:0}.dapp-input.dapp-large{font-size:1.5em}.dapp-input.dapp-error{color:#c20e25;background:rgba(194, 14, 37, 0.1);border-color:rgba(194, 14, 37, 0.15)}.dapp-input:disabled{color:#797673}.dapp-identicon{display:inline-block;width:64px;height:64px;border-radius:50%;background-size:cover;background-positon:50% 50%;box-shadow:inset rgba(255, 255, 255, 0.2) 0 2px 2px, inset rgba(0, 0, 0, 0.3) 0 -1px 8px}.dapp-identicon.dapp-small{width:32px;height:32px}.dapp-identicon.dapp-medium{width:48px;height:48px}.dapp-modal-buttons{position:relative;display:-webkit-box;display:-moz-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-pack:end;-moz-box-pack:end;-ms-flex-pack:end;-webkit-justify-content:flex-end;justify-content:flex-end;margin-top:16px}.dapp-modal-buttons button,.dapp-modal-buttons a,.dapp-modal-buttons a:visited{-webkit-box-flex:1;-moz-box-flex:1;-webkit-flex:1;-ms-flex:1;flex:1;margin:0 8px;height:36.8px;line-height:36.8px;font-family:'Source Sans Pro', 'Helvetica Neue', Helvetica, Arial, Sans;font-size:0.9em;text-transform:uppercase;font-weight:400}.dapp-modal-buttons button.dapp-primary-button,.dapp-modal-buttons a.dapp-primary-button,.dapp-modal-buttons a:visited.dapp-primary-button{font-weight:600}.dapp-address-input{position:relative}.dapp-address-input input{display:inline-block;width:300px;max-width:100%;margin-top:18.4px;padding:9.2px 16px;padding-bottom:6.13333333px;border:0;border-bottom:solid 2px #dddcdb;box-sizing:border-box;background-color:#f5f4f2;font-size:1em;font-weight:300;color:#6691c2;z-index:1;margin-top:0;padding-left:48px}.dapp-address-input input::-webkit-input-placeholder{color:#dddcdb}.dapp-address-input input:-moz-placeholder{color:#dddcdb}.dapp-address-input input::-moz-placeholder{color:#dddcdb}.dapp-address-input input:-ms-input-placeholder{color:#dddcdb}.dapp-address-input input:focus{outline:0}.dapp-address-input input.dapp-large{font-size:1.5em}.dapp-address-input input.dapp-error{color:#c20e25;background:rgba(194, 14, 37, 0.1);border-color:rgba(194, 14, 37, 0.15)}.dapp-address-input input:disabled{color:#797673}.dapp-address-input input.dapp-large{font-size:1.5em}.dapp-address-input input.dapp-large+.dapp-identicon{top:6px;width:32px;height:32px}.dapp-address-input input.dapp-large+.icon-shield{top:12px}.dapp-address-input input.dapp-error{border-color:#c20e25}.dapp-address-input .dapp-identicon{z-index:2;position:absolute;top:3px;left:5px;width:26.66666667px;height:26.66666667px}.dapp-address-input .icon-shield{position:absolute;top:6px;left:13px;font-size:1.4em;color:#c20e25}@font-face{font-family:'Simple-Line-Icons';src:url('dapp-styles/icons/Simple-Line-Icons.eot');src:url('dapp-styles/icons/Simple-Line-Icons.eot?') format('embedded-opentype'), url('dapp-styles/icons/Simple-Line-Icons.woff') format('woff'), url('dapp-styles/icons/Simple-Line-Icons.ttf') format('truetype'), url('dapp-styles/icons/Simple-Line-Icons.svg') format('svg');font-weight:normal;font-style:normal}[data-icon]:before{font-family:'Simple-Line-Icons';content:attr(data-icon);speak:none;font-weight:normal;font-variant:normal;text-transform:none;line-height:1;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.icon-user-female,.icon-user-follow,.icon-user-following,.icon-user-unfollow,.icon-trophy,.icon-screen-smartphone,.icon-screen-desktop,.icon-plane,.icon-notebook,.icon-moustache,.icon-mouse,.icon-magnet,.icon-energy,.icon-emoticon-smile,.icon-disc,.icon-cursor-move,.icon-crop,.icon-credit-card,.icon-chemistry,.icon-user,.icon-speedometer,.icon-social-youtube,.icon-social-twitter,.icon-social-tumblr,.icon-social-facebook,.icon-social-dropbox,.icon-social-dribbble,.icon-shield,.icon-screen-tablet,.icon-magic-wand,.icon-hourglass,.icon-graduation,.icon-ghost,.icon-game-controller,.icon-fire,.icon-eyeglasses,.icon-envelope-open,.icon-envelope-letter,.icon-bell,.icon-badge,.icon-anchor,.icon-wallet,.icon-vector,.icon-speech,.icon-puzzle,.icon-printer,.icon-present,.icon-playlist,.icon-pin,.icon-picture,.icon-map,.icon-layers,.icon-handbag,.icon-globe-alt,.icon-globe,.icon-frame,.icon-folder-alt,.icon-film,.icon-feed,.icon-earphones-alt,.icon-earphones,.icon-drop,.icon-drawer,.icon-docs,.icon-directions,.icon-direction,.icon-diamond,.icon-cup,.icon-compass,.icon-call-out,.icon-call-in,.icon-call-end,.icon-calculator,.icon-bubbles,.icon-briefcase,.icon-book-open,.icon-basket-loaded,.icon-basket,.icon-bag,.icon-action-undo,.icon-action-redo,.icon-wrench,.icon-umbrella,.icon-trash,.icon-tag,.icon-support,.icon-size-fullscreen,.icon-size-actual,.icon-shuffle,.icon-share-alt,.icon-share,.icon-rocket,.icon-question,.icon-pie-chart,.icon-pencil,.icon-note,.icon-music-tone-alt,.icon-music-tone,.icon-microphone,.icon-loop,.icon-logout,.icon-login,.icon-list,.icon-like,.icon-home,.icon-grid,.icon-graph,.icon-equalizer,.icon-dislike,.icon-cursor,.icon-control-start,.icon-control-rewind,.icon-control-play,.icon-control-pause,.icon-control-forward,.icon-control-end,.icon-calendar,.icon-bulb,.icon-bar-chart,.icon-arrow-up,.icon-arrow-right,.icon-arrow-left,.icon-arrow-down,.icon-ban,.icon-bubble,.icon-camcorder,.icon-camera,.icon-check,.icon-clock,.icon-close,.icon-cloud-download,.icon-cloud-upload,.icon-doc,.icon-envelope,.icon-eye,.icon-flag,.icon-folder,.icon-heart,.icon-info,.icon-key,.icon-link,.icon-lock,.icon-lock-open,.icon-magnifier,.icon-magnifier-add,.icon-magnifier-remove,.icon-paper-clip,.icon-paper-plane,.icon-plus,.icon-pointer,.icon-power,.icon-refresh,.icon-reload,.icon-settings,.icon-star,.icon-symbol-female,.icon-symbol-male,.icon-target,.icon-volume-1,.icon-volume-2,.icon-volume-off,.icon-users{font-family:'Simple-Line-Icons';speak:none;font-style:normal;font-weight:normal;font-variant:normal;text-transform:none;line-height:1;-webkit-font-smoothing:antialiased}.icon-user-female:before{content:"\e000"}.icon-user-follow:before{content:"\e002"}.icon-user-following:before{content:"\e003"}.icon-user-unfollow:before{content:"\e004"}.icon-trophy:before{content:"\e006"}.icon-screen-smartphone:before{content:"\e010"}.icon-screen-desktop:before{content:"\e011"}.icon-plane:before{content:"\e012"}.icon-notebook:before{content:"\e013"}.icon-moustache:before{content:"\e014"}.icon-mouse:before{content:"\e015"}.icon-magnet:before{content:"\e016"}.icon-energy:before{content:"\e020"}.icon-emoticon-smile:before{content:"\e021"}.icon-disc:before{content:"\e022"}.icon-cursor-move:before{content:"\e023"}.icon-crop:before{content:"\e024"}.icon-credit-card:before{content:"\e025"}.icon-chemistry:before{content:"\e026"}.icon-user:before{content:"\e005"}.icon-speedometer:before{content:"\e007"}.icon-social-youtube:before{content:"\e008"}.icon-social-twitter:before{content:"\e009"}.icon-social-tumblr:before{content:"\e00a"}.icon-social-facebook:before{content:"\e00b"}.icon-social-dropbox:before{content:"\e00c"}.icon-social-dribbble:before{content:"\e00d"}.icon-shield:before{content:"\e00e"}.icon-screen-tablet:before{content:"\e00f"}.icon-magic-wand:before{content:"\e017"}.icon-hourglass:before{content:"\e018"}.icon-graduation:before{content:"\e019"}.icon-ghost:before{content:"\e01a"}.icon-game-controller:before{content:"\e01b"}.icon-fire:before{content:"\e01c"}.icon-eyeglasses:before{content:"\e01d"}.icon-envelope-open:before{content:"\e01e"}.icon-envelope-letter:before{content:"\e01f"}.icon-bell:before{content:"\e027"}.icon-badge:before{content:"\e028"}.icon-anchor:before{content:"\e029"}.icon-wallet:before{content:"\e02a"}.icon-vector:before{content:"\e02b"}.icon-speech:before{content:"\e02c"}.icon-puzzle:before{content:"\e02d"}.icon-printer:before{content:"\e02e"}.icon-present:before{content:"\e02f"}.icon-playlist:before{content:"\e030"}.icon-pin:before{content:"\e031"}.icon-picture:before{content:"\e032"}.icon-map:before{content:"\e033"}.icon-layers:before{content:"\e034"}.icon-handbag:before{content:"\e035"}.icon-globe-alt:before{content:"\e036"}.icon-globe:before{content:"\e037"}.icon-frame:before{content:"\e038"}.icon-folder-alt:before{content:"\e039"}.icon-film:before{content:"\e03a"}.icon-feed:before{content:"\e03b"}.icon-earphones-alt:before{content:"\e03c"}.icon-earphones:before{content:"\e03d"}.icon-drop:before{content:"\e03e"}.icon-drawer:before{content:"\e03f"}.icon-docs:before{content:"\e040"}.icon-directions:before{content:"\e041"}.icon-direction:before{content:"\e042"}.icon-diamond:before{content:"\e043"}.icon-cup:before{content:"\e044"}.icon-compass:before{content:"\e045"}.icon-call-out:before{content:"\e046"}.icon-call-in:before{content:"\e047"}.icon-call-end:before{content:"\e048"}.icon-calculator:before{content:"\e049"}.icon-bubbles:before{content:"\e04a"}.icon-briefcase:before{content:"\e04b"}.icon-book-open:before{content:"\e04c"}.icon-basket-loaded:before{content:"\e04d"}.icon-basket:before{content:"\e04e"}.icon-bag:before{content:"\e04f"}.icon-action-undo:before{content:"\e050"}.icon-action-redo:before{content:"\e051"}.icon-wrench:before{content:"\e052"}.icon-umbrella:before{content:"\e053"}.icon-trash:before{content:"\e054"}.icon-tag:before{content:"\e055"}.icon-support:before{content:"\e056"}.icon-size-fullscreen:before{content:"\e057"}.icon-size-actual:before{content:"\e058"}.icon-shuffle:before{content:"\e059"}.icon-share-alt:before{content:"\e05a"}.icon-share:before{content:"\e05b"}.icon-rocket:before{content:"\e05c"}.icon-question:before{content:"\e05d"}.icon-pie-chart:before{content:"\e05e"}.icon-pencil:before{content:"\e05f"}.icon-note:before{content:"\e060"}.icon-music-tone-alt:before{content:"\e061"}.icon-music-tone:before{content:"\e062"}.icon-microphone:before{content:"\e063"}.icon-loop:before{content:"\e064"}.icon-logout:before{content:"\e065"}.icon-login:before{content:"\e066"}.icon-list:before{content:"\e067"}.icon-like:before{content:"\e068"}.icon-home:before{content:"\e069"}.icon-grid:before{content:"\e06a"}.icon-graph:before{content:"\e06b"}.icon-equalizer:before{content:"\e06c"}.icon-dislike:before{content:"\e06d"}.icon-cursor:before{content:"\e06e"}.icon-control-start:before{content:"\e06f"}.icon-control-rewind:before{content:"\e070"}.icon-control-play:before{content:"\e071"}.icon-control-pause:before{content:"\e072"}.icon-control-forward:before{content:"\e073"}.icon-control-end:before{content:"\e074"}.icon-calendar:before{content:"\e075"}.icon-bulb:before{content:"\e076"}.icon-bar-chart:before{content:"\e077"}.icon-arrow-up:before{content:"\e078"}.icon-arrow-right:before{content:"\e079"}.icon-arrow-left:before{content:"\e07a"}.icon-arrow-down:before{content:"\e07b"}.icon-ban:before{content:"\e07c"}.icon-bubble:before{content:"\e07d"}.icon-camcorder:before{content:"\e07e"}.icon-camera:before{content:"\e07f"}.icon-check:before{content:"\e080"}.icon-clock:before{content:"\e081"}.icon-close:before{content:"\e082"}.icon-cloud-download:before{content:"\e083"}.icon-cloud-upload:before{content:"\e084"}.icon-doc:before{content:"\e085"}.icon-envelope:before{content:"\e086"}.icon-eye:before{content:"\e087"}.icon-flag:before{content:"\e088"}.icon-folder:before{content:"\e089"}.icon-heart:before{content:"\e08a"}.icon-info:before{content:"\e08b"}.icon-key:before{content:"\e08c"}.icon-link:before{content:"\e08d"}.icon-lock:before{content:"\e08e"}.icon-lock-open:before{content:"\e08f"}.icon-magnifier:before{content:"\e090"}.icon-magnifier-add:before{content:"\e091"}.icon-magnifier-remove:before{content:"\e092"}.icon-paper-clip:before{content:"\e093"}.icon-paper-plane:before{content:"\e094"}.icon-plus:before{content:"\e095"}.icon-pointer:before{content:"\e096"}.icon-power:before{content:"\e097"}.icon-refresh:before{content:"\e098"}.icon-reload:before{content:"\e099"}.icon-settings:before{content:"\e09a"}.icon-star:before{content:"\e09b"}.icon-symbol-female:before{content:"\e09c"}.icon-symbol-male:before{content:"\e09d"}.icon-target:before{content:"\e09e"}.icon-volume-1:before{content:"\e09f"}.icon-volume-2:before{content:"\e0a0"}.icon-volume-off:before{content:"\e0a1"}.icon-users:before{content:"\e001"}article,aside,details,figcaption,figure,footer,header,hgroup,main,nav,section,summary{display:block}audio,canvas,video{display:inline-block;*display:inline;*zoom:1}audio:not([controls]){display:none;height:0}[hidden]{display:none}html{font-size:100%;-ms-text-size-adjust:100%;-webkit-text-size-adjust:100%;}html,button,input,select,textarea{font-family:sans-serif}body{margin:0}a:focus{outline:thin dotted}a:active,a:hover{outline:0}h1{font-size:2em;margin:0.67em 0}h2{font-size:1.5em;margin:0.83em 0}h3{font-size:1.17em;margin:1em 0}h4{font-size:1em;margin:1.33em 0}h5{font-size:0.83em;margin:1.67em 0}h6{font-size:0.67em;margin:2.33em 0}abbr[title]{border-bottom:1px dotted}b,strong{font-weight:bold}blockquote{margin:1em 40px}dfn{font-style:italic}hr{-moz-box-sizing:content-box;box-sizing:content-box;height:0}mark{background:#ff0;color:#000}p,pre{margin:1em 0}code,kbd,pre,samp{font-family:monospace, serif;_font-family:'courier new', monospace;font-size:1em}pre{white-space:pre;white-space:pre-wrap;word-wrap:break-word}q{quotes:none}q:before,q:after{content:'';content:none}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sup{top:-0.5em}sub{bottom:-0.25em}dl,menu,ol,ul{margin:1em 0}dd{margin:0 0 0 40px}menu,ol,ul{padding:0 0 0 40px}nav ul,nav ol{list-style:none;list-style-image:none}img{border:0;-ms-interpolation-mode:bicubic;}svg:not(:root){overflow:hidden}figure{margin:0}form{margin:0}fieldset{border:1px solid #c0c0c0;margin:0 2px;padding:0.35em 0.625em 0.75em}legend{border:0;padding:0;white-space:normal;*margin-left:-7px;}button,input,select,textarea{font-size:100%;margin:0;vertical-align:baseline;*vertical-align:middle;}button,input{line-height:normal}button,select{text-transform:none}button,html input[type="button"],input[type="reset"],input[type="submit"]{-webkit-appearance:button;cursor:pointer;*overflow:visible;}button[disabled],html input[disabled]{cursor:default}input[type="checkbox"],input[type="radio"]{box-sizing:border-box;padding:0;*height:13px;*width:13px;}input[type="search"]{-webkit-appearance:textfield;-moz-box-sizing:content-box;-webkit-box-sizing:content-box;box-sizing:content-box}input[type="search"]::-webkit-search-cancel-button,input[type="search"]::-webkit-search-decoration{-webkit-appearance:none}button::-moz-focus-inner,input::-moz-focus-inner{border:0;padding:0}textarea{overflow:auto;vertical-align:top;}table{border-collapse:collapse;border-spacing:0}*,*:before,*:after{-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}article,aside,details,figcaption,figure,footer,header,hgroup,main,nav,section,summary{display:block}html,button,input,select,textarea{font-family:sans-serif}body,form,fieldset,legend,input,select,textarea,button{margin:0}html{font-size:100%}.section{position:relative}.container{max-width:960px;margin-left:auto;margin-right:auto;padding-left:10px;padding-right:10px}.container-full{max-width:960px;margin-left:auto;margin-right:auto}.col{float:left;padding-left:10px;padding-right:10px}[class*="pull-"],[class*="push-"]{position:relative}.no-gutter{padding-left:0;padding-right:0}.col-1{width:8.33333%;width:calc(100% / 12 * 1);width:-webkit-calc(100% / 12 * 1);width:-moz-calc(100% / 12 * 1)}.col-2{width:16.66667%;width:calc(100% / 12 * 2);width:-webkit-calc(100% / 12 * 2);width:-moz-calc(100% / 12 * 2)}.col-3,.col-1-4{width:25%;width:calc(100% / 12 * 3);width:-webkit-calc(100% / 12 * 3);width:-moz-calc(100% / 12 * 3)}.col-4,.col-1-3{width:33.33333%;width:calc(100% / 12 * 4);width:-webkit-calc(100% / 12 * 4);width:-moz-calc(100% / 12 * 4)}.col-5{width:41.66665%;width:calc(100% / 12 * 5);width:-webkit-calc(100% / 12 * 5);width:-moz-calc(100% / 12 * 5)}.col-6,.col-1-2{width:50%;width:calc(100% / 12 * 6);width:-webkit-calc(100% / 12 * 6);width:-moz-calc(100% / 12 * 6)}.col-7{width:58.33333%;width:calc(100% / 12 * 7);width:-webkit-calc(100% / 12 * 7);width:-moz-calc(100% / 12 * 7)}.col-8{width:66.66666%;width:calc(100% / 12 * 8);width:-webkit-calc(100% / 12 * 8);width:-moz-calc(100% / 12 * 8)}.col-9,.col-3-4{width:75%;width:calc(100% / 12 * 9);width:-webkit-calc(100% / 12 * 9);width:-moz-calc(100% / 12 * 9)}.col-10{width:83.33333%;width:calc(100% / 12 * 10);width:-webkit-calc(100% / 12 * 10);width:-moz-calc(100% / 12 * 10)}.col-11{width:91.66666%;width:calc(100% / 12 * 11);width:-webkit-calc(100% / 12 * 11);width:-moz-calc(100% / 12 * 11)}.col-12{width:100%}.push-1{left:8.33333%;left:calc(100% / 12 * 1);left:-webkit-calc(100% / 12 * 1);left:-moz-calc(100% / 12 * 1)}.pull-1{left:-8.33333%;left:calc(-100% / 12 * 1);left:-webkit-calc(-100% / 12 * 1);left:-moz-calc(-100% / 12 * 1)}.push-2{left:16.66667%;left:calc(100% / 12 * 2);left:-webkit-calc(100% / 12 * 2);left:-moz-calc(100% / 12 * 2)}.pull-2{left:-16.66667%;left:calc(-100% / 12 * 2);left:-webkit-calc(-100% / 12 * 2);left:-moz-calc(-100% / 12 * 2)}.push-3,.push-1-4{left:25%;left:calc(100% / 12 * 3);left:-webkit-calc(100% / 12 * 3);left:-moz-calc(100% / 12 * 3)}.pull-3,.pull-1-4{left:-25%;left:calc(-100% / 12 * 3);left:-webkit-calc(-100% / 12 * 3);left:-moz-calc(-100% / 12 * 3)}.push-4,.push-1-3{left:33.33333%;left:calc(100% / 12 * 4);left:-webkit-calc(100% / 12 * 4);left:-moz-calc(100% / 12 * 4)}.pull-4,.pull-1-3{left:-33.33333%;left:calc(-100% / 12 * 4);left:-webkit-calc(-100% / 12 * 4);left:-moz-calc(-100% / 12 * 4)}.push-5{left:41.66665%;left:calc(100% / 12 * 5);left:-webkit-calc(100% / 12 * 5);left:-moz-calc(100% / 12 * 5)}.pull-5{left:-41.66665%;left:calc(-100% / 12 * 5);left:-webkit-calc(-100% / 12 * 5);left:-moz-calc(-100% / 12 * 5)}.push-6,.push-1-2{left:50%;left:calc(100% / 12 * 6);left:-webkit-calc(100% / 12 * 6);left:-moz-calc(100% / 12 * 6)}.pull-6,.pull-1-2{left:-50%;left:calc(-100% / 12 * 6);left:-webkit-calc(-100% / 12 * 6);left:-moz-calc(-100% / 12 * 6)}.push-7{left:58.33333%;left:calc(100% / 12 * 7);left:-webkit-calc(100% / 12 * 7);left:-moz-calc(100% / 12 * 7)}.pull-7{left:-58.33333%;left:calc(-100% / 12 * 7);left:-webkit-calc(-100% / 12 * 7);left:-moz-calc(-100% / 12 * 7)}.push-8{left:66.66666%;left:calc(100% / 12 * 8);left:-webkit-calc(100% / 12 * 8);left:-moz-calc(100% / 12 * 8)}.pull-8{left:-66.66666%;left:calc(-100% / 12 * 8);left:-webkit-calc(-100% / 12 * 8);left:-moz-calc(-100% / 12 * 8)}.push-9,.push-3-4{left:75%;left:calc(100% / 12 * 9);left:-webkit-calc(100% / 12 * 9);left:-moz-calc(100% / 12 * 9)}.pull-9,.pull-3-4{left:-75%;left:calc(-100% / 12 * 9);left:-webkit-calc(-100% / 12 * 9);left:-moz-calc(-100% / 12 * 9)}.push-10{left:83.33333%;left:calc(100% / 12 * 10);left:-webkit-calc(100% / 12 * 10);left:-moz-calc(100% / 12 * 10)}.pull-10{left:-83.33333%;left:calc(-100% / 12 * 10);left:-webkit-calc(-100% / 12 * 10);left:-moz-calc(-100% / 12 * 10)}.push-11{left:91.66666%;left:calc(100% / 12 * 11);left:-webkit-calc(100% / 12 * 11);left:-moz-calc(100% / 12 * 11)}.pull-11{left:-91.66666%;left:calc(-100% / 12 * 11);left:-webkit-calc(-100% / 12 * 11);left:-moz-calc(-100% / 12 * 11)}.row{padding-top:1em;padding-bottom:1em}.no-desktop{display:none}.no-margin{margin:0}.no-padding{padding:0}@media only screen and (min-width: 660px) and (max-width: 959px){.container,.tablet-container{max-width:960px;padding-left:20px;padding-right:20px;margin-left:auto;margin-right:auto;float:none}.container:first-child,.tablet-container:first-child{margin-left:auto}.tablet-container-full{padding-left:0;padding-right:0;margin-left:auto;margin-right:auto;float:none}.tablet-container-full:first-child{margin-left:auto}.tablet-no-gutter{padding-left:0;padding-right:0}.tablet-col-1{width:8.33333%;width:calc(100% / 12 * 1);width:-webkit-calc(100% / 12 * 1);width:-moz-calc(100% / 12 * 1)}.tablet-col-2{width:16.66667%;width:calc(100% / 12 * 2);width:-webkit-calc(100% / 12 * 2);width:-moz-calc(100% / 12 * 2)}.tablet-col-3,.tablet-col-1-4{width:25%;width:calc(100% / 12 * 3);width:-webkit-calc(100% / 12 * 3);width:-moz-calc(100% / 12 * 3)}.tablet-col-4,.tablet-col-1-3{width:33.33333%;width:calc(100% / 12 * 4);width:-webkit-calc(100% / 12 * 4);width:-moz-calc(100% / 12 * 4)}.tablet-col-5{width:41.66665%;width:calc(100% / 12 * 5);width:-webkit-calc(100% / 12 * 5);width:-moz-calc(100% / 12 * 5)}.tablet-col-6,.tablet-col-1-2{width:50%;width:calc(100% / 12 * 6);width:-webkit-calc(100% / 12 * 6);width:-moz-calc(100% / 12 * 6)}.tablet-col-7{width:58.33333%;width:calc(100% / 12 * 7);width:-webkit-calc(100% / 12 * 7);width:-moz-calc(100% / 12 * 7)}.tablet-col-8{width:66.66666%;width:calc(100% / 12 * 8);width:-webkit-calc(100% / 12 * 8);width:-moz-calc(100% / 12 * 8)}.tablet-col-9,.tablet-col-3-4{width:75%;width:calc(100% / 12 * 9);width:-webkit-calc(100% / 12 * 9);width:-moz-calc(100% / 12 * 9)}.tablet-col-10{width:83.33333%;width:calc(100% / 12 * 10);width:-webkit-calc(100% / 12 * 10);width:-moz-calc(100% / 12 * 10)}.tablet-col-11{width:91.66666%;width:calc(100% / 12 * 11);width:-webkit-calc(100% / 12 * 11);width:-moz-calc(100% / 12 * 11)}.tablet-col-12{width:100%}.tablet-push-1{left:8.33333%;left:calc(100% / 12 * 1);left:-webkit-calc(100% / 12 * 1);left:-moz-calc(100% / 12 * 1)}.tablet-pull-1{left:-8.33333%;left:calc(-100% / 12 * 1);left:-webkit-calc(-100% / 12 * 1);left:-moz-calc(-100% / 12 * 1)}.tablet-push-2{left:16.66667%;left:calc(100% / 12 * 2);left:-webkit-calc(100% / 12 * 2);left:-moz-calc(100% / 12 * 2)}.tablet-pull-2{left:-16.66667%;left:calc(-100% / 12 * 2);left:-webkit-calc(-100% / 12 * 2);left:-moz-calc(-100% / 12 * 2)}.tablet-push-3,.tablet-push-1-4{left:25%;left:calc(100% / 12 * 3);left:-webkit-calc(100% / 12 * 3);left:-moz-calc(100% / 12 * 3)}.tablet-pull-3,.tablet-pull-1-4{left:-25%;left:calc(-100% / 12 * 3);left:-webkit-calc(-100% / 12 * 3);left:-moz-calc(-100% / 12 * 3)}.tablet-push-4,.tablet-push-1-3{left:33.33333%;left:calc(100% / 12 * 4);left:-webkit-calc(100% / 12 * 4);left:-moz-calc(100% / 12 * 4)}.tablet-pull-4,.tablet-pull-1-3{left:-33.33333%;left:calc(-100% / 12 * 4);left:-webkit-calc(-100% / 12 * 4);left:-moz-calc(-100% / 12 * 4)}.tablet-push-5{left:41.66665%;left:calc(100% / 12 * 5);left:-webkit-calc(100% / 12 * 5);left:-moz-calc(100% / 12 * 5)}.tablet-pull-5{left:-41.66665%;left:calc(-100% / 12 * 5);left:-webkit-calc(-100% / 12 * 5);left:-moz-calc(-100% / 12 * 5)}.tablet-push-6,.tablet-push-1-2{left:50%;left:calc(100% / 12 * 6);left:-webkit-calc(100% / 12 * 6);left:-moz-calc(100% / 12 * 6)}.tablet-pull-6,.tablet-pull-1-2{left:-50%;left:calc(-100% / 12 * 6);left:-webkit-calc(-100% / 12 * 6);left:-moz-calc(-100% / 12 * 6)}.tablet-push-7{left:58.33333%;left:calc(100% / 12 * 7);left:-webkit-calc(100% / 12 * 7);left:-moz-calc(100% / 12 * 7)}.tablet-pull-7{left:-58.33333%;left:calc(-100% / 12 * 7);left:-webkit-calc(-100% / 12 * 7);left:-moz-calc(-100% / 12 * 7)}.tablet-push-8{left:66.66666%;left:calc(100% / 12 * 8);left:-webkit-calc(100% / 12 * 8);left:-moz-calc(100% / 12 * 8)}.tablet-pull-8{left:-66.66666%;left:calc(-100% / 12 * 8);left:-webkit-calc(-100% / 12 * 8);left:-moz-calc(-100% / 12 * 8)}.tablet-push-9,.tablet-push-3-4{left:75%;left:calc(100% / 12 * 9);left:-webkit-calc(100% / 12 * 9);left:-moz-calc(100% / 12 * 9)}.tablet-pull-9,.tablet-pull-3-4{left:-75%;left:calc(-100% / 12 * 9);left:-webkit-calc(-100% / 12 * 9);left:-moz-calc(-100% / 12 * 9)}.tablet-push-10{left:83.33333%;left:calc(100% / 12 * 10);left:-webkit-calc(100% / 12 * 10);left:-moz-calc(100% / 12 * 10)}.tablet-pull-10{left:-83.33333%;left:calc(-100% / 12 * 10);left:-webkit-calc(-100% / 12 * 10);left:-moz-calc(-100% / 12 * 10)}.tablet-push-11{left:91.66666%;left:calc(100% / 12 * 11);left:-webkit-calc(100% / 12 * 11);left:-moz-calc(100% / 12 * 11)}.tablet-pull-11{left:-91.66666%;left:calc(-100% / 12 * 11);left:-webkit-calc(-100% / 12 * 11);left:-moz-calc(-100% / 12 * 11)}.tablet-no-push,.tablet-no-pull{left:auto}.tablet-row{padding-top:1em;padding-bottom:1em}.tablet-full{left:auto;clear:both;float:none;width:100%;margin:1em 0 0 0;display:block}.tablet-full:first-child{margin-top:0}.tablet-text-left{text-align:left}.tablet-text-right{text-align:right}.tablet-text-center{text-align:center}.tablet-left{float:left}.tablet-right{float:right}.tablet-no-float{float:none}.tablet-no-margin{margin:0}.tablet-no-padding{padding:0}.no-tablet{display:none}.show-tablet{display:block}}@media only screen and (max-width: 659px){.container,.mobile-container{padding-left:20px;padding-right:20px;margin-left:auto;margin-right:auto;float:none}.container:first-child,.mobile-container:first-child{margin-left:auto}.mobile-container-full{padding-left:0;padding-right:0;margin-left:auto;margin-right:auto;float:none}.mobile-container-full:first-child{margin-left:auto}.mobile-no-gutter{padding-left:0;padding-right:0}.mobile-col-1-2{width:50%;width:calc(100% / 12 * 6);width:-webkit-calc(100% / 12 * 6);width:-moz-calc(100% / 12 * 6)}.mobile-col-1-3{width:33.33333%;width:calc(100% / 12 * 4);width:-webkit-calc(100% / 12 * 4);width:-moz-calc(100% / 12 * 4)}.mobile-col-1-4{width:25%;width:calc(100% / 12 * 3);width:-webkit-calc(100% / 12 * 3);width:-moz-calc(100% / 12 * 3)}.mobile-col-3-4{width:75%;width:calc(100% / 12 * 9);width:-webkit-calc(100% / 12 * 9);width:-moz-calc(100% / 12 * 9)}.mobile-push-1-2{left:50%;left:calc(100% / 12 * 6);left:-webkit-calc(100% / 12 * 6);left:-moz-calc(100% / 12 * 6)}.mobile-pull-1-2{left:-50%;left:calc(-100% / 12 * 6);left:-webkit-calc(-100% / 12 * 6);left:-moz-calc(-100% / 12 * 6)}.mobile-push-1-3{left:25%;left:calc(100% / 12 * 3);left:-webkit-calc(100% / 12 * 3);left:-moz-calc(100% / 12 * 3)}.mobile-pull-1-3{left:-25%;left:calc(-100% / 12 * 3);left:-webkit-calc(-100% / 12 * 3);left:-moz-calc(-100% / 12 * 3)}.mobile-push-1-4{left:33.33333%;left:calc(100% / 12 * 4);left:-webkit-calc(100% / 12 * 4);left:-moz-calc(100% / 12 * 4)}.mobile-pull-1-4{left:-33.33333%;left:calc(-100% / 12 * 4);left:-webkit-calc(-100% / 12 * 4);left:-moz-calc(-100% / 12 * 4)}.mobile-push-3-4{left:75%;left:calc(100% / 12 * 9);left:-webkit-calc(100% / 12 * 9);left:-moz-calc(100% / 12 * 9)}.mobile-pull-3-4{left:-75%;left:calc(-100% / 12 * 9);left:-webkit-calc(-100% / 12 * 9);left:-moz-calc(-100% / 12 * 9)}.mobile-no-push,.mobile-no-pull{left:auto}.mobile-row{padding-top:1em;padding-bottom:1em}.mobile-full{left:auto;clear:both;float:none;width:100%;margin:0.2em 0 0 0;display:block}.mobile-full:first-child{margin-top:0}.mobile-text-left{text-align:left}.mobile-text-right{text-align:right}.mobile-text-center{text-align:center}.mobile-left{float:left}.mobile-right{float:right}.mobile-no-float{float:none}.mobile-no-margin{margin:0}.mobile-no-padding{padding:0}.no-mobile{display:none}.show-mobile{display:block}}@media print{*{background:transparent}a,a:visited{text-decoration:underline}abbr[title]:after{content:" (" attr(title) ")"}pre,blockquote{border:1px solid #999;page-break-inside:avoid}thead{display:table-header-group}tr,img{page-break-inside:avoid}img{max-width:100%}@page {margin:0.5cm}p,h2,h3{orphans:3;widows:3}h2,h3{page-break-after:avoid}}@font-face{font-family:'Source Sans Pro';src:url('dapp-styles/fonts/SourceSansPro-ExtraLight.otf');font-weight:100;font-style:normal}@font-face{font-family:'Source Sans Pro';src:url('dapp-styles/fonts/SourceSansPro-ExtraLightIt.otf');font-weight:100;font-style:italic}@font-face{font-family:'Source Sans Pro';src:url('dapp-styles/fonts/SourceSansPro-Light.otf');font-weight:300;font-style:normal}@font-face{font-family:'Source Sans Pro';src:url('dapp-styles/fonts/SourceSansPro-Regular.otf');font-weight:400;font-style:normal}@font-face{font-family:'Source Sans Pro';src:url('dapp-styles/fonts/SourceSansPro-Semibold.otf');font-weight:500;font-style:normal}@font-face{font-family:'Source Sans Pro';src:url('dapp-styles/fonts/SourceSansPro-Bold.otf');font-weight:700;font-style:normal}@font-face{font-family:'Montserrat';src:url('dapp-styles/fonts/Montserrat-Regular.otf');font-weight:400;font-style:normal}.dapp-clear-fix{clear:both}.dapp-overflow{overflow:auto;-webkit-overflow-scrolling:touch}.dapp-shorten-text{display:inline-block;-o-text-overflow:ellipsis;text-overflow:ellipsis;overflow:hidden;white-space:nowrap;max-width:100%}.dapp-button-reset{background:none;border:0;padding:0;margin:0;-webkit-box-sizing:content-box;-moz-box-sizing:content-box;box-sizing:content-box}.dapp-button-reset:hover,.dapp-button-reset:focus{outline:0}.dapp-shadow-none{-webkit-box-shadow:0 0 0 rgba(0, 0, 0, 0);-moz-box-shadow:0 0 0 rgba(0, 0, 0, 0);box-shadow:0 0 0 rgba(0, 0, 0, 0)}.dapp-shadow-small{-webkit-box-shadow:0 0px 1px rgba(0, 0, 0, 0.3);-moz-box-shadow:0 0px 1px rgba(0, 0, 0, 0.3);box-shadow:0 0px 1px rgba(0, 0, 0, 0.3)}.dapp-shadow-medium{-webkit-box-shadow:0 1px 4px rgba(0, 0, 0, 0.3);-moz-box-shadow:0 1px 4px rgba(0, 0, 0, 0.3);box-shadow:0 1px 4px rgba(0, 0, 0, 0.3)}.dapp-shadow-large{-webkit-box-shadow:0 1px 16px rgba(0, 0, 0, 0.3);-moz-box-shadow:0 1px 16px rgba(0, 0, 0, 0.3);box-shadow:0 1px 16px rgba(0, 0, 0, 0.3)}.dapp-horizontal-menu,.dapp-vertical-menu{padding:0;margin:0;list-style:none}.dapp-horizontal-menu li{display:inline-block;padding:0;margin:0}.dapp-vertical-menu li{display:block;padding:0;margin:0}.cubic-bezier{-webkit-transition-timing-function:cubic-bezier(0.15, 0.3, 0.1, 1);-moz-transition-timing-function:cubic-bezier(0.15, 0.3, 0.1, 1);-o-transition-timing-function:cubic-bezier(0.15, 0.3, 0.1, 1);transition-timing-function:cubic-bezier(0.15, 0.3, 0.1, 1)}.cubic-bezier.animate{-webkit-transition-timing-function:cubic-bezier(0.5, 0.1, 0.2, 1);-moz-transition-timing-function:cubic-bezier(0.5, 0.1, 0.2, 1);-o-transition-timing-function:cubic-bezier(0.5, 0.1, 0.2, 1);transition-timing-function:cubic-bezier(0.5, 0.1, 0.2, 1)}#dapp-form-helper-iframe{display:none}.dapp-message{position:relative;max-width:512px;margin:48px 0;font-size:1.5em;font-weight:100;line-height:27pt}.dapp-count{display:-webkit-box;display:-moz-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-align:center;-moz-box-align:center;-webkit-align-items:center;-ms-flex-align:center;align-items:center;position:absolute;top:0;bottom:0;right:0;padding:0 8px;color:#fafafa;font-weight:100;zoom:1;filter:alpha(opacity=70);-webkit-opacity:0.7;-moz-opacity:0.7;opacity:0.7;-webkit-transition:opacity 400ms;-moz-transition:opacity 400ms;-o-transition:opacity 400ms;transition:opacity 400ms}.dapp-count.animate{zoom:1;filter:alpha(opacity=0);-webkit-opacity:0;-moz-opacity:0;opacity:0}.active .dapp-count{background-color:#f5f4f2;color:#9c9090}.dapp-url-bar{display:block;text-align:center;width:100%;-webkit-background-clip:padding-box;-moz-background-clip:padding;background-clip:padding-box;-webkit-border-radius:8px;-moz-border-radius:8px;border-radius:8px}.dapp-big-number{font-size:2em;display:inline-block;width:192px;margin-right:16px;padding-top:18.4px}.dapp-big-number dd{margin:0;font-size:50%;font-weight:600;text-transform:uppercase;color:#695e5e}.dapp-big-number dt{color:#02a8f3}a,a:visited,button{text-decoration:none;color:#02a8f3;outline:0}a:hover,a:visited:hover,button:hover,a:focus,a:visited:focus,button:focus{outline:0}a:active,a:visited:active,button:active{-webkit-transform:scale(0.95);-moz-transform:scale(0.95);-o-transform:scale(0.95);-ms-transform:scale(0.95);transform:scale(0.95)}button{background:none;border:0;padding:0;margin:0;-webkit-box-sizing:content-box;-moz-box-sizing:content-box;box-sizing:content-box;font-weight:inherit}button:hover,button:focus{outline:0}hr{border:0;height:0;margin:32px 0;background-color:transparent;border-bottom:1px solid #ccc6c6}h1{margin:16px 0;margin-bottom:48px;font-weight:100;font-size:2.2em;color:#827a7a}h1 span{font-weight:500}h1+h2{margin-top:0}h1 strong{font-weight:400}h2{display:inline-block;padding:0 8px;padding-bottom:1px;margin:64px 0 16px;font-weight:500;font-size:1em;text-transform:uppercase;background:#827a7a;color:#fafafa;font-family:'Montserrat';font-weight:400}h2+table{margin-top:0}h3{margin:16px 0;padding:0;color:rgba(130, 122, 122, 0.7);text-transform:uppercase;font-weight:500;font-size:1em}h4{margin:16px 0;padding:0;color:rgba(130, 122, 122, 0.7);font-weight:500;font-size:1em}table{width:100%;margin:16px 0}table+h2,table+h3{margin-top:32px}table tbody tr:nth-child(odd){background-color:rgba(204, 198, 198, 0.3)}table tbody tr td{padding:2px 0}table tbody tr td span{display:inline-block;-o-text-overflow:ellipsis;text-overflow:ellipsis;overflow:hidden;white-space:nowrap;max-width:100%}.dapp-input{border:0;border-bottom:solid 2px #ccc6c6;background-color:#f5f4f2;color:#02a8f3}.dapp-input::-webkit-input-placeholder{color:#ccc6c6}.dapp-input:-moz-placeholder{color:#ccc6c6}.dapp-input::-moz-placeholder{color:#ccc6c6}.dapp-input:-ms-input-placeholder{color:#ccc6c6}.dapp-input:disabled{color:#695e5e}.dapp-address-input input{border:0;border-bottom:solid 2px #ccc6c6;background-color:#f5f4f2;color:#02a8f3}.dapp-address-input input::-webkit-input-placeholder{color:#ccc6c6}.dapp-address-input input:-moz-placeholder{color:#ccc6c6}.dapp-address-input input::-moz-placeholder{color:#ccc6c6}.dapp-address-input input:-ms-input-placeholder{color:#ccc6c6}.dapp-address-input input:disabled{color:#695e5e}.dapp-address-input .dapp-error+.dapp-identicon{display:none}.dapp-address-input .icon-shield{display:none;position:absolute;top:9px;left:13px;font-size:1.4em;color:#c20e25}.dapp-address-input .dapp-error+.dapp-identicon+.icon-shield{display:block}input,select,textarea{border:0;border-bottom:solid 2px #ccc6c6;background-color:#f5f4f2;color:#02a8f3;display:inline-block;width:300px;max-width:100%;margin-top:18.4px;padding:9.2px 16px;padding-bottom:6.13333333px;-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;font-size:1em;font-weight:300}input::-webkit-input-placeholder,select::-webkit-input-placeholder,textarea::-webkit-input-placeholder{color:#ccc6c6}input:-moz-placeholder,select:-moz-placeholder,textarea:-moz-placeholder{color:#ccc6c6}input::-moz-placeholder,select::-moz-placeholder,textarea::-moz-placeholder{color:#ccc6c6}input:-ms-input-placeholder,select:-ms-input-placeholder,textarea:-ms-input-placeholder{color:#ccc6c6}input:disabled,select:disabled,textarea:disabled{color:#695e5e}input:focus,select:focus,textarea:focus{outline:0}input.dapp-large,select.dapp-large,textarea.dapp-large{font-size:1.5em}input.dapp-error,select.dapp-error,textarea.dapp-error{color:#c20e25;background:#f2d7d7;border-color:#f5b6b6}:disabled{color:#695e5e}input[type="checkbox"],input[type="radio"]{display:inline-block;position:relative;margin:0;outline:none !important;-webkit-appearance:none;width:auto;width:24px;height:24px}input[type="checkbox"]::before,input[type="radio"]::before{content:'';position:relative;top:0;left:0;display:block;background:#f5f4f2;border:1px solid #f5f4f2;-webkit-box-shadow:inset 0 0 2px rgba(0, 0, 0, 0.2);-moz-box-shadow:inset 0 0 2px rgba(0, 0, 0, 0.2);box-shadow:inset 0 0 2px rgba(0, 0, 0, 0.2);width:24px;height:24px}input[type="checkbox"]:focus::before,input[type="radio"]:focus::before{border-color:rgba(2, 168, 243, 0.4)}input[type="checkbox"]:disabled::before,input[type="radio"]:disabled::before{cursor:not-allowed;background-color:rgba(245, 244, 242, 0.8);border-color:#f5f4f2}input[type="checkbox"]:after,input[type="radio"]:after{content:'';display:inline-block;position:absolute;top:6px;left:6px;background:#02a8f3;-webkit-box-shadow:0 0px 1px rgba(0, 0, 0, 0.3);-moz-box-shadow:0 0px 1px rgba(0, 0, 0, 0.3);box-shadow:0 0px 1px rgba(0, 0, 0, 0.3);width:12px;height:12px;-webkit-transition:-webkit-transform 400ms;-moz-transition:-moz-transform 400ms;-o-transition:-o-transform 400ms;transition:-webkit-transform 400ms,-moz-transform 400ms,-o-transform 400ms,transform 400ms;-webkit-transform:scale(0);-moz-transform:scale(0);-o-transform:scale(0);-ms-transform:scale(0);transform:scale(0)}input[type="checkbox"]:checked:after,input[type="radio"]:checked:after{-webkit-transform:scale(1);-moz-transform:scale(1);-o-transform:scale(1);-ms-transform:scale(1);transform:scale(1)}input[type="checkbox"]:disabled:after,input[type="radio"]:disabled:after{background:rgba(2, 168, 243, 0.4)}input[type="radio"]{-webkit-background-clip:padding-box;-moz-background-clip:padding;background-clip:padding-box;-webkit-border-radius:50%;-moz-border-radius:50%;border-radius:50%}input[type="radio"]:before{-webkit-background-clip:padding-box;-moz-background-clip:padding;background-clip:padding-box;-webkit-border-radius:50%;-moz-border-radius:50%;border-radius:50%}input[type="radio"]:after{-webkit-background-clip:padding-box;-moz-background-clip:padding;background-clip:padding-box;-webkit-border-radius:50%;-moz-border-radius:50%;border-radius:50%}input[type="range"]{-webkit-appearance:none;padding:0;border:0;background-color:transparent;overflow:hidden;height:18.4px}input[type="range"]::-webkit-slider-runnable-track{height:5px;background-color:#ccc6c6;border:none;-webkit-background-clip:padding-box;-moz-background-clip:padding;background-clip:padding-box;-webkit-border-radius:3px;-moz-border-radius:3px;border-radius:3px}input[type="range"]::-webkit-slider-thumb{-webkit-appearance:none;border:none;height:16px;width:16px;border-radius:50%;background-color:#02a8f3;margin-top:-6px;z-index:30}input[type="range"]::-webkit-slider-thumb:after{content:" ";width:500px;height:5px;background-image:url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiA/PjxzdmcgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB3aWR0aD0iMTAwJSIgaGVpZ2h0PSIxMDAlIiB2aWV3Qm94PSIwIDAgMSAxIiBwcmVzZXJ2ZUFzcGVjdFJhdGlvPSJub25lIj48bGluZWFyR3JhZGllbnQgaWQ9Imxlc3NoYXQtZ2VuZXJhdGVkIiBncmFkaWVudFVuaXRzPSJ1c2VyU3BhY2VPblVzZSIgeDE9IjEwMCUiIHkxPSIwJSIgeDI9IjAlIiB5Mj0iMCUiPjxzdG9wIG9mZnNldD0iMCUiIHN0b3AtY29sb3I9IiMwMmE4ZjMiIHN0b3Atb3BhY2l0eT0iMSIvPjxzdG9wIG9mZnNldD0iNTAlIiBzdG9wLWNvbG9yPSIjMDJhOGYzIiBzdG9wLW9wYWNpdHk9IjEiLz48c3RvcCBvZmZzZXQ9IjEwMCUiIHN0b3AtY29sb3I9InJnYigwLDAsMCkiIHN0b3Atb3BhY2l0eT0iMCIvPjwvbGluZWFyR3JhZGllbnQ+PHJlY3QgeD0iMCIgeT0iMCIgd2lkdGg9IjEiIGhlaWdodD0iMSIgZmlsbD0idXJsKCNsZXNzaGF0LWdlbmVyYXRlZCkiIC8+PC9zdmc+);background-image:-webkit--webkit-linear-gradient(right, #02a8f3 0%, #02a8f3 50%, transparent 100%);background-image:-webkit--moz-linear-gradient(right, #02a8f3 0%, #02a8f3 50%, transparent 100%);background-image:-webkit--o-linear-gradient(right, #02a8f3 0%, #02a8f3 50%, transparent 100%);background-image:-webkit-linear-gradient(to left, #02a8f3 0%, #02a8f3 50%, transparent 100%);display:block;position:relative;left:-500px;top:6px;z-index:20}input[type="range"]:focus{outline:none}input[type="range"]::-moz-range-track{height:5px;background-color:#02a8f3;border:none;-webkit-background-clip:padding-box;-moz-background-clip:padding;background-clip:padding-box;-webkit-border-radius:3px;-moz-border-radius:3px;border-radius:3px}input[type="range"]::-moz-range-thumb{-webkit-appearance:none;border:none;height:16px;width:16px;border-radius:50%;background-color:#695e5e;margin-top:-4px}input[type="range"]:focus{outline:none}input[type="range"].slider-vertical{transform:rotate(-90deg);width:73.6px}label{font-weight:300}fieldset{border:0;padding:0;margin:16px}select{height:45px}body{display:-webkit-box;display:-moz-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-direction:normal;-moz-box-direction:normal;-webkit-box-orient:vertical;-moz-box-orient:vertical;-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;min-height:100vh;padding:0;margin:0;background-color:#fafafa;font:100 16px 'Source Sans Pro', 'Helvetica Neue', arial, sans-serif;color:#111111}body.disable-scroll{overflow:hidden}body.blur .dapp-flex-content,body.blur .dapp-footer,body.blur .dapp-header{-webkit-filter:blur(4px);-moz-filter:blur(4px);-ms-filter:blur(4px);filter:blur(4px)}.ethereum-dapp-url-bar-style-transparent .dapp-header{padding-top:73.6px}.dapp-grid{z-index:999;background:#ffffff url('dapp-styles/hex-grid-tile.png');background-size:64px 111px;position:absolute;min-height:100%;left:0;right:0;opacity:0.05;pointer-events:none}.dapp-container{display:block;position:relative;margin:0 auto;max-width:960px}.dapp-header,.dapp-aside,.dapp-content,.dapp-footer{position:relative;padding:18.4px 32px;-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}.dapp-header{height:64px;-webkit-box-sizing:content-box;-moz-box-sizing:content-box;box-sizing:content-box;background-image:url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiA/PjxzdmcgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB3aWR0aD0iMTAwJSIgaGVpZ2h0PSIxMDAlIiB2aWV3Qm94PSIwIDAgMSAxIiBwcmVzZXJ2ZUFzcGVjdFJhdGlvPSJub25lIj48bGluZWFyR3JhZGllbnQgaWQ9Imxlc3NoYXQtZ2VuZXJhdGVkIiBncmFkaWVudFVuaXRzPSJ1c2VyU3BhY2VPblVzZSIgeDE9IjAlIiB5MT0iMCUiIHgyPSIwJSIgeTI9IjEwMCUiPjxzdG9wIG9mZnNldD0iMCUiIHN0b3AtY29sb3I9IiNmYmZhZmEiIHN0b3Atb3BhY2l0eT0iMSIvPjxzdG9wIG9mZnNldD0iOTAlIiBzdG9wLWNvbG9yPSIjZDlkMGQwIiBzdG9wLW9wYWNpdHk9IjEiLz48L2xpbmVhckdyYWRpZW50PjxyZWN0IHg9IjAiIHk9IjAiIHdpZHRoPSIxIiBoZWlnaHQ9IjEiIGZpbGw9InVybCgjbGVzc2hhdC1nZW5lcmF0ZWQpIiAvPjwvc3ZnPg==);background-image:-webkit-linear-gradient(top, #fbfafa 0, #d9d0d0 90%);background-image:-moz-linear-gradient(top, #fbfafa 0, #d9d0d0 90%);background-image:-o-linear-gradient(top, #fbfafa 0, #d9d0d0 90%);background-image:linear-gradient(to bottom, #fbfafa 0, #d9d0d0 90%)}.dapp-header nav{position:absolute;bottom:0}.dapp-header nav ul{padding:0;margin:0;list-style:none}.dapp-header nav ul li{display:inline-block;padding:0;margin:0}.dapp-header nav ul a{display:inline-block;padding:9.2px 32px;text-align:center;border-bottom:5px solid transparent;color:#0285c0}.dapp-header nav ul a.active{color:#ab9898;border-bottom:5px solid #fafafa}.dapp-header nav ul a.active{-webkit-transform-origin:50% 100%;-moz-transform-origin:50% 100%;-o-transform-origin:50% 100%;-ms-transform-origin:50% 100%;transform-origin:50% 100%}.dapp-header nav ul a i{font-size:1.5em}.dapp-header nav ul a span{display:block;text-transform:uppercase;font-weight:400}.dapp-footer{height:96px;background-color:#111111}.dapp-flex-content{display:-webkit-box;display:-moz-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-flex:1;-moz-box-flex:1;-webkit-flex:1;-ms-flex:1;flex:1}.dapp-content{-webkit-box-flex:1;-moz-box-flex:1;-webkit-flex:1;-ms-flex:1;flex:1;background:#fafafa}.dapp-content.dapp-has-header{padding-top:175.2px}.dapp-content .dapp-content-header{position:fixed;top:0;width:80%;min-height:36.8px;padding:18.4px 16px;margin-left:-32px;background:rgba(245, 244, 242, 0.8);z-index:10;line-height:36.8px;-webkit-box-shadow:0 1px 4px rgba(0, 0, 0, 0.3);-moz-box-shadow:0 1px 4px rgba(0, 0, 0, 0.3);box-shadow:0 1px 4px rgba(0, 0, 0, 0.3);-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}.dapp-aside{-webkit-box-flex:0;-moz-box-flex:0;-webkit-flex:0 0 224px;-ms-flex:0 0 224px;flex:0 0 224px;padding-right:0;background-image:url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiA/PjxzdmcgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB3aWR0aD0iMTAwJSIgaGVpZ2h0PSIxMDAlIiB2aWV3Qm94PSIwIDAgMSAxIiBwcmVzZXJ2ZUFzcGVjdFJhdGlvPSJub25lIj48bGluZWFyR3JhZGllbnQgaWQ9Imxlc3NoYXQtZ2VuZXJhdGVkIiBncmFkaWVudFVuaXRzPSJ1c2VyU3BhY2VPblVzZSIgeDE9IjAlIiB5MT0iMCUiIHgyPSIwJSIgeTI9IjEwMCUiPjxzdG9wIG9mZnNldD0iMCUiIHN0b3AtY29sb3I9IiNmMGVlZWUiIHN0b3Atb3BhY2l0eT0iMSIvPjxzdG9wIG9mZnNldD0iMTAwJSIgc3RvcC1jb2xvcj0iI2NjYzZjNiIgc3RvcC1vcGFjaXR5PSIxIi8+PC9saW5lYXJHcmFkaWVudD48cmVjdCB4PSIwIiB5PSIwIiB3aWR0aD0iMSIgaGVpZ2h0PSIxIiBmaWxsPSJ1cmwoI2xlc3NoYXQtZ2VuZXJhdGVkKSIgLz48L3N2Zz4=);background-image:-webkit-linear-gradient(top, #f0eeee 0, #ccc6c6 100px);background-image:-moz-linear-gradient(top, #f0eeee 0, #ccc6c6 100px);background-image:-o-linear-gradient(top, #f0eeee 0, #ccc6c6 100px);background-image:linear-gradient(to bottom, #f0eeee 0, #ccc6c6 100px);-webkit-transition:flex 400ms;-moz-transition:flex 400ms;-o-transition:flex 400ms;transition:flex 400ms}.dapp-aside nav ul{padding:0;margin:0;list-style:none;padding-top:18.4px}.dapp-aside nav ul li{display:block;padding:0;margin:0}.dapp-aside nav ul li a,.dapp-aside nav ul li a:visited,.dapp-aside nav ul li button{display:-webkit-box;display:-moz-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-align:center;-moz-box-align:center;-webkit-align-items:center;-ms-flex-align:center;align-items:center;position:relative;min-height:73.6px;max-height:92px;padding:18.4px 32px;padding-left:10.66666667px;overflow:hidden;border-top:#b9b0b0 solid 1px;-webkit-background-clip:padding-box;-moz-background-clip:padding;background-clip:padding-box;-webkit-border-radius:3px 0 0 3px;-moz-border-radius:3px 0 0 3px;border-radius:3px 0 0 3px;-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box;color:#111111;font-weight:300;line-height:20px}.dapp-aside nav ul li a:active,.dapp-aside nav ul li a:visited:active,.dapp-aside nav ul li button:active{-webkit-transform-origin:100% 50%;-moz-transform-origin:100% 50%;-o-transform-origin:100% 50%;-ms-transform-origin:100% 50%;transform-origin:100% 50%;-webkit-transform:scale(0.98);-moz-transform:scale(0.98);-o-transform:scale(0.98);-ms-transform:scale(0.98);transform:scale(0.98)}.dapp-aside nav ul li a>i,.dapp-aside nav ul li a:visited>i,.dapp-aside nav ul li button>i{margin-right:4px}.dapp-aside nav ul li a>span,.dapp-aside nav ul li a:visited>span,.dapp-aside nav ul li button>span{max-width:115px;display:-webkit-box;-webkit-line-clamp:3;-webkit-box-orient:vertical;overflow:hidden;text-overflow:ellipsis}.dapp-aside nav ul li .dapp-main-button{position:relative;width:100%;margin-bottom:73.6px;-webkit-background-clip:padding-box;-moz-background-clip:padding;background-clip:padding-box;-webkit-border-radius:3px 0 0 3px;-moz-border-radius:3px 0 0 3px;border-radius:3px 0 0 3px;background:#665f5f;color:#fafafa;border-top:none}.dapp-aside nav ul li .dapp-main-button i{position:absolute;right:8px;top:27.6px}.dapp-aside nav ul li.active a{background:#fafafa;border-top:none;color:#111111;font-weight:500}.dapp-aside nav ul li:first-child a,.dapp-aside nav ul li.active+li>a,.dapp-aside nav ul li.dapp-main-button+li{border-top:0}.dapp-actionbar{z-index:20;-webkit-box-flex:0;-moz-box-flex:0;-webkit-flex:0 0 64px;-ms-flex:0 0 64px;flex:0 0 64px;background:#fafafa}.dapp-actionbar nav ul{padding:0;margin:0;list-style:none}.dapp-actionbar nav ul li{display:block;padding:0;margin:0}.dapp-actionbar nav ul li{margin:16px 0;color:#02a8f3;position:relative;overflow:hidden;text-align:center;-webkit-transition:height 400ms;-moz-transition:height 400ms;-o-transition:height 400ms;transition:height 400ms}.dapp-actionbar nav ul li button,.dapp-actionbar nav ul li a,.dapp-actionbar nav ul li a:visited{background:none;border:0;padding:0;margin:0;-webkit-box-sizing:content-box;-moz-box-sizing:content-box;box-sizing:content-box;display:inline-block;color:#111111;color:#0e73b8;font-size:0.8em;font-weight:400}.dapp-actionbar nav ul li button:hover,.dapp-actionbar nav ul li a:hover,.dapp-actionbar nav ul li a:visited:hover,.dapp-actionbar nav ul li button:focus,.dapp-actionbar nav ul li a:focus,.dapp-actionbar nav ul li a:visited:focus{outline:0}.dapp-actionbar nav ul li button:active,.dapp-actionbar nav ul li a:active,.dapp-actionbar nav ul li a:visited:active{-webkit-transform:scale(0.95);-moz-transform:scale(0.95);-o-transform:scale(0.95);-ms-transform:scale(0.95);transform:scale(0.95)}.dapp-actionbar nav ul li button:hover,.dapp-actionbar nav ul li a:hover,.dapp-actionbar nav ul li a:visited:hover{opacity:0.9}.dapp-actionbar nav ul li button i,.dapp-actionbar nav ul li a i,.dapp-actionbar nav ul li a:visited i{font-size:2em;display:block}.dapp-box{display:inline-block;float:left;width:192px;height:220.8px;padding-top:18.4px;padding-left:16px;padding-bottom:9.2px;padding-right:16px;margin-bottom:9.2px;margin-right:16px;background-color:#fafafa;-webkit-box-shadow:0 1px 4px rgba(0, 0, 0, 0.3);-moz-box-shadow:0 1px 4px rgba(0, 0, 0, 0.3);box-shadow:0 1px 4px rgba(0, 0, 0, 0.3)}.dapp-box h2{margin:0;padding:0;background-color:transparent;color:#827a7a;font-family:'Source Sans Pro', 'Helvetica Neue', Helvetica, Arial, Sans;text-transform:none;font-size:1.5em;font-weight:100}.dapp-box.card{padding-left:96px;padding-right:64px;width:512px;max-width:none;height:auto;border-radius:4px;background-repeat-x:no-repeat;background-repeat:repeat-y;background-size:64px}.dapp-box.card h1{margin-bottom:0}.dapp-box.card h3{overflow:hidden;white-space:nowrap;text-overflow:ellipsis;text-transform:lowercase;margin-top:0}.dapp-box.card dd,.dapp-box.card dt{display:block;height:36.8px;font-size:1.1em;float:left}.dapp-box.card dd{margin:0;width:128px;clear:both;text-align:right}.dapp-box.card dt{font-weight:500;padding-left:16px}.dapp-modal-overlay{background:rgba(17, 17, 17, 0.5)}.dapp-modal-container{background:#fafafa}.dapp-icon-button{background:none;border:0;padding:0;margin:0;-webkit-box-sizing:content-box;-moz-box-sizing:content-box;box-sizing:content-box;display:inline-block;color:#111111}.dapp-icon-button:hover,.dapp-icon-button:focus{outline:0}.dapp-icon-button:active{-webkit-transform:scale(0.95);-moz-transform:scale(0.95);-o-transform:scale(0.95);-ms-transform:scale(0.95);transform:scale(0.95)}.dapp-icon-button:hover{opacity:0.9}.dapp-block-button,.dapp-block-button:visited{background:none;border:0;padding:0;margin:0;-webkit-box-sizing:content-box;-moz-box-sizing:content-box;box-sizing:content-box;height:36.8px;min-width:100px;padding:4.6px 10.66666667px;background:#02a8f3;color:#fafafa;border-bottom:solid 3px #0297da;-webkit-background-clip:padding-box;-moz-background-clip:padding;background-clip:padding-box;-webkit-border-radius:2px;-moz-border-radius:2px;border-radius:2px;display:inline-block;-o-text-overflow:ellipsis;text-overflow:ellipsis;overflow:hidden;white-space:nowrap;max-width:100%;font-family:'Source Sans Pro', 'Helvetica Neue', Helvetica, Arial, Sans;font-size:1em;font-weight:400;text-transform:uppercase}.dapp-block-button:hover,.dapp-block-button:visited:hover,.dapp-block-button:focus,.dapp-block-button:visited:focus{outline:0}.dapp-block-button:active,.dapp-block-button:visited:active{border-bottom-width:3px}.dapp-block-button i,.dapp-block-button:visited i{position:relative;top:2px}.dapp-tag-button{background:none;border:0;padding:0;margin:0;-webkit-box-sizing:content-box;-moz-box-sizing:content-box;box-sizing:content-box;padding:4.6px 8px;background:#ccc6c6;color:#111111;-webkit-background-clip:padding-box;-moz-background-clip:padding;background-clip:padding-box;-webkit-border-radius:4px;-moz-border-radius:4px;border-radius:4px;display:inline-block;-o-text-overflow:ellipsis;text-overflow:ellipsis;overflow:hidden;white-space:nowrap;max-width:100%;font-size:0.7em}.dapp-tag-button:hover,.dapp-tag-button:focus{outline:0}.dapp-tag-button.active{background:#02a8f3;color:#fafafa}@media screen and (max-width: 576px){aside.dapp-main{-webkit-box-flex:0;-moz-box-flex:0;-webkit-flex:0 0 64px;-ms-flex:0 0 64px;flex:0 0 64px}}@media screen and (max-device-width: 480px) and (orientation: portrait){body{font-size:14px}}@media screen and (max-device-width: 640px) and (orientation: landscape){body{font-size:15px}}.page-title{position:-webkit-sticky;top:15px;left:0;right:0;background:transparent;color:#ccc6c6;display:block;text-align:center;margin:9.2px 0 73.6px}.block-chain{margin:0 -40px;height:331.2px;padding:9.2px 16px;overflow:auto;-webkit-overflow-scrolling:touch}.block-chain .wrapper{padding-right:160px}.block-chain .wrapper .card{position:relative}.block-chain .wrapper .card .dapp-identicon{position:absolute;width:40px;height:40px;left:44px;top:38.2px;border:solid 2px #fafafa}.mining-slider{position:relative;padding-left:16px}.mining-slider .slider-vertical{position:absolute;top:18.4px;left:-40px} \ No newline at end of file
diff --git a/cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/Montserrat-Black.otf b/cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/Montserrat-Black.otf
new file mode 100644
index 000000000..5e04cf3f7
--- /dev/null
+++ b/cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/Montserrat-Black.otf
Binary files differ
diff --git a/cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/Montserrat-Bold.otf b/cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/Montserrat-Bold.otf
new file mode 100644
index 000000000..eaf99a571
--- /dev/null
+++ b/cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/Montserrat-Bold.otf
Binary files differ
diff --git a/cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/Montserrat-Hairline.otf b/cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/Montserrat-Hairline.otf
new file mode 100644
index 000000000..1ee11cede
--- /dev/null
+++ b/cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/Montserrat-Hairline.otf
Binary files differ
diff --git a/cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/Montserrat-Light.otf b/cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/Montserrat-Light.otf
new file mode 100644
index 000000000..a01805ff0
--- /dev/null
+++ b/cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/Montserrat-Light.otf
Binary files differ
diff --git a/cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/Montserrat-Regular.otf b/cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/Montserrat-Regular.otf
new file mode 100644
index 000000000..85d0c1e8f
--- /dev/null
+++ b/cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/Montserrat-Regular.otf
Binary files differ
diff --git a/cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/SIL Open Font License.txt b/cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/SIL Open Font License.txt
new file mode 100644
index 000000000..295975a5d
--- /dev/null
+++ b/cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/SIL Open Font License.txt
@@ -0,0 +1,43 @@
+Copyright 2010, 2012 Adobe Systems Incorporated (http://www.adobe.com/), with Reserved Font Name 'Source'. All Rights Reserved. Source is a trademark of Adobe Systems Incorporated in the United States and/or other countries.
+
+This Font Software is licensed under the SIL Open Font License, Version 1.1.
+This license is copied below, and is also available with a FAQ at: http://scripts.sil.org/OFL
+
+-----------------------------------------------------------
+SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007
+-----------------------------------------------------------
+
+PREAMBLE
+The goals of the Open Font License (OFL) are to stimulate worldwide development of collaborative font projects, to support the font creation efforts of academic and linguistic communities, and to provide a free and open framework in which fonts may be shared and improved in partnership with others.
+
+The OFL allows the licensed fonts to be used, studied, modified and redistributed freely as long as they are not sold by themselves. The fonts, including any derivative works, can be bundled, embedded, redistributed and/or sold with any software provided that any reserved names are not used by derivative works. The fonts and derivatives, however, cannot be released under any other type of license. The requirement for fonts to remain under this license does not apply to any document created using the fonts or their derivatives.
+
+DEFINITIONS
+"Font Software" refers to the set of files released by the Copyright Holder(s) under this license and clearly marked as such. This may include source files, build scripts and documentation.
+
+"Reserved Font Name" refers to any names specified as such after the copyright statement(s).
+
+"Original Version" refers to the collection of Font Software components as distributed by the Copyright Holder(s).
+
+"Modified Version" refers to any derivative made by adding to, deleting, or substituting -- in part or in whole -- any of the components of the Original Version, by changing formats or by porting the Font Software to a new environment.
+
+"Author" refers to any designer, engineer, programmer, technical writer or other person who contributed to the Font Software.
+
+PERMISSION & CONDITIONS
+Permission is hereby granted, free of charge, to any person obtaining a copy of the Font Software, to use, study, copy, merge, embed, modify, redistribute, and sell modified and unmodified copies of the Font Software, subject to the following conditions:
+
+1) Neither the Font Software nor any of its individual components, in Original or Modified Versions, may be sold by itself.
+
+2) Original or Modified Versions of the Font Software may be bundled, redistributed and/or sold with any software, provided that each copy contains the above copyright notice and this license. These can be included either as stand-alone text files, human-readable headers or in the appropriate machine-readable metadata fields within text or binary files as long as those fields can be easily viewed by the user.
+
+3) No Modified Version of the Font Software may use the Reserved Font Name(s) unless explicit written permission is granted by the corresponding Copyright Holder. This restriction only applies to the primary font name as presented to the users.
+
+4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font Software shall not be used to promote, endorse or advertise any Modified Version, except to acknowledge the contribution(s) of the Copyright Holder(s) and the Author(s) or with their explicit written permission.
+
+5) The Font Software, modified or unmodified, in part or in whole, must be distributed entirely under this license, and must not be distributed under any other license. The requirement for fonts to remain under this license does not apply to any document created using the Font Software.
+
+TERMINATION
+This license becomes null and void if any of the above conditions are not met.
+
+DISCLAIMER
+THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM OTHER DEALINGS IN THE FONT SOFTWARE. \ No newline at end of file
diff --git a/cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/SourceSansPro-Black.otf b/cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/SourceSansPro-Black.otf
new file mode 100644
index 000000000..492661cba
--- /dev/null
+++ b/cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/SourceSansPro-Black.otf
Binary files differ
diff --git a/cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/SourceSansPro-BlackIt.otf b/cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/SourceSansPro-BlackIt.otf
new file mode 100644
index 000000000..2fbb1d1a1
--- /dev/null
+++ b/cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/SourceSansPro-BlackIt.otf
Binary files differ
diff --git a/cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/SourceSansPro-Bold.otf b/cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/SourceSansPro-Bold.otf
new file mode 100644
index 000000000..597072f58
--- /dev/null
+++ b/cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/SourceSansPro-Bold.otf
Binary files differ
diff --git a/cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/SourceSansPro-BoldIt.otf b/cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/SourceSansPro-BoldIt.otf
new file mode 100644
index 000000000..56bdfaccd
--- /dev/null
+++ b/cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/SourceSansPro-BoldIt.otf
Binary files differ
diff --git a/cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/SourceSansPro-ExtraLight.otf b/cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/SourceSansPro-ExtraLight.otf
new file mode 100644
index 000000000..20a21c630
--- /dev/null
+++ b/cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/SourceSansPro-ExtraLight.otf
Binary files differ
diff --git a/cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/SourceSansPro-ExtraLightIt.otf b/cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/SourceSansPro-ExtraLightIt.otf
new file mode 100644
index 000000000..787bfcfae
--- /dev/null
+++ b/cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/SourceSansPro-ExtraLightIt.otf
Binary files differ
diff --git a/cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/SourceSansPro-It.otf b/cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/SourceSansPro-It.otf
new file mode 100644
index 000000000..7ab613d4d
--- /dev/null
+++ b/cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/SourceSansPro-It.otf
Binary files differ
diff --git a/cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/SourceSansPro-Light.otf b/cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/SourceSansPro-Light.otf
new file mode 100644
index 000000000..4a8eafd78
--- /dev/null
+++ b/cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/SourceSansPro-Light.otf
Binary files differ
diff --git a/cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/SourceSansPro-LightIt.otf b/cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/SourceSansPro-LightIt.otf
new file mode 100644
index 000000000..c5b8ca860
--- /dev/null
+++ b/cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/SourceSansPro-LightIt.otf
Binary files differ
diff --git a/cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/SourceSansPro-Regular.otf b/cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/SourceSansPro-Regular.otf
new file mode 100644
index 000000000..38941ae72
--- /dev/null
+++ b/cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/SourceSansPro-Regular.otf
Binary files differ
diff --git a/cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/SourceSansPro-Semibold.otf b/cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/SourceSansPro-Semibold.otf
new file mode 100644
index 000000000..fd41bcf1c
--- /dev/null
+++ b/cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/SourceSansPro-Semibold.otf
Binary files differ
diff --git a/cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/SourceSansPro-SemiboldIt.otf b/cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/SourceSansPro-SemiboldIt.otf
new file mode 100644
index 000000000..447ff80bf
--- /dev/null
+++ b/cmd/mist/assets/qml/views/network-health/dapp-styles/fonts/SourceSansPro-SemiboldIt.otf
Binary files differ
diff --git a/cmd/mist/assets/qml/views/network-health/index.html b/cmd/mist/assets/qml/views/network-health/index.html
new file mode 100755
index 000000000..96c958a35
--- /dev/null
+++ b/cmd/mist/assets/qml/views/network-health/index.html
@@ -0,0 +1,30 @@
+<html>
+ <meta charset="utf-8">
+ <title>Network</title>
+
+ <!-- <base href="/"> -->
+
+ <meta name="description" content="">
+ <meta name="keywords" content="dapp, ethereum">
+
+ <!-- <link rel="icon" href="/favicon.ico" type="image/x-icon"> -->
+ <!-- <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon"> -->
+
+ <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1, user-scalable=no">
+ <meta name="apple-mobile-web-app-capable" content="yes">
+ <meta name="apple-mobile-web-app-status-bar-style" content="black">
+
+ <!-- <link rel="apple-touch-icon" href="/apple-touch-icon-precomposed.png"> -->
+ <!-- <link rel="apple-touch-startup-image" href="/startup.png"> -->
+
+
+ <link rel="stylesheet" type="text/css" class="__meteor-css__" href="529f30ee0ee386c5143b4ccb62073179ca8253c3.css?meteor_css_resource=true">
+<body>
+
+
+ <script type="text/javascript">__meteor_runtime_config__ = {"meteorRelease":"METEOR@1.0.3.1","ROOT_URL":"http://localhost:3000/","ROOT_URL_PATH_PREFIX":"","appId":"e350zy16p3kznipbx5o","autoupdateVersion":"df83a37bd2952ddbb9ba6c5f2a59e9caba02642b","autoupdateVersionRefreshable":"81118ed5fac9ef5f8d55835426179e1e058da42b","autoupdateVersionCordova":"none"};</script>
+
+ <script type="text/javascript" src="205f39107b64acf34cb35d7edb57f47893187a12.js"></script>
+
+</body>
+</html> \ No newline at end of file
diff --git a/cmd/mist/assets/qml/views/network-health/loading.css b/cmd/mist/assets/qml/views/network-health/loading.css
new file mode 100644
index 000000000..1b3f4bd65
--- /dev/null
+++ b/cmd/mist/assets/qml/views/network-health/loading.css
@@ -0,0 +1,92 @@
+body {
+ background-color: #000;
+ font: 16px solid 'Helvetica Neue', sans-serif;
+}
+
+.inject-loading-container {
+ position: relative;
+ padding-top: 20%;
+ /*left: 50%;*/
+ margin: 0 auto;
+ /*max-width: 600px;*/
+ /*margin-left: -300px;*/
+ text-align: center;
+
+}
+.inject-loading-container h1 {
+ text-align: center;
+ font-weight: 300;
+ font-size: 2em;
+}
+
+img.loading-circle {
+ width: 24px;
+ height: 24px;
+
+ animation: rotate 1s linear infinite;
+ -moz-animation: rotate 1s linear infinite;
+ -webkit-animation: rotate 1s linear infinite;
+ -ms-animation: rotate 1s linear infinite;
+
+ transform-origin:50% 49.5%;
+ -ms-transform-origin:50% 49.5%; /* IE 9 */
+ -moz-transform-origin:50% 49.5%; /* Chrome, Safari, Opera */
+ -webkit-transform-origin:50% 49.5%; /* Chrome, Safari, Opera */
+}
+
+/* Keyframes */
+@-webkit-keyframes rotate {
+ 0% {
+ -webkit-transform: rotate(0deg);
+ }
+ 50% {
+ opacity: 0.2;
+ }
+ 100% {
+ -webkit-transform: rotate(360deg);
+ }
+}
+@-moz-keyframes rotate {
+ 0% {
+ -moz-transform: rotate(0deg);
+ }
+ 50% {
+ opacity: 0.2;
+ }
+ 100% {
+ -moz-transform: rotate(360deg);
+ }
+}
+@-o-keyframes rotate {
+ 0% {
+ -o-transform: rotate(0deg);
+ }
+ 50% {
+ opacity: 0.2;
+ }
+ 100% {
+ -o-transform: rotate(360deg);
+ }
+}
+@-ms-keyframes rotate {
+ 0% {
+ -ms-transform: rotate(0deg);
+ }
+ 50% {
+ opacity: 0.2;
+ }
+ 100% {
+ -ms-transform-origin: rotate(360deg);
+ }
+}
+@keyframes rotate {
+ 0% {
+ transform: rotate(0deg);
+ }
+ 50% {
+ opacity: 0.2;
+ }
+ 100% {
+ transform: rotate(360deg);
+ }
+} \ No newline at end of file
diff --git a/cmd/mist/assets/qml/views/network.qml b/cmd/mist/assets/qml/views/network.qml
new file mode 100644
index 000000000..fe4c7734f
--- /dev/null
+++ b/cmd/mist/assets/qml/views/network.qml
@@ -0,0 +1,159 @@
+import QtQuick 2.0
+import QtQuick.Controls 1.0;
+import QtQuick.Controls.Styles 1.0
+import QtQuick.Layouts 1.0;
+import QtWebEngine 1.0
+import QtWebEngine.experimental 1.0
+import QtQuick.Window 2.0;
+import Ethereum 1.0
+import Qt.WebSockets 1.0
+//import "qwebchannel.js" as WebChannel
+
+
+
+Rectangle {
+ id: window
+ anchors.fill: parent
+ color: "#00000000"
+
+ property var title: "Network"
+ property var iconSource: "../mining-icon.png"
+ property var menuItem
+ property var hideUrl: true
+
+ property alias url: webview.url
+ property alias windowTitle: webview.title
+ property alias webView: webview
+
+ property var cleanPath: false
+ property var open: function(url) {
+ if(!window.cleanPath) {
+ var uri = url;
+ if(!/.*\:\/\/.*/.test(uri)) {
+ uri = "http://" + uri;
+ }
+
+ var reg = /(^https?\:\/\/(?:www\.)?)([a-zA-Z0-9_\-]*\.eth)(.*)/
+
+ if(reg.test(uri)) {
+ uri.replace(reg, function(match, pre, domain, path) {
+ uri = pre;
+
+ var lookup = eth.lookupDomain(domain.substring(0, domain.length - 4));
+ var ip = [];
+ for(var i = 0, l = lookup.length; i < l; i++) {
+ ip.push(lookup.charCodeAt(i))
+ }
+
+ if(ip.length != 0) {
+ uri += lookup;
+ } else {
+ uri += domain;
+ }
+
+ uri += path;
+ });
+ }
+
+ window.cleanPath = true;
+
+ webview.url = uri;
+
+ //uriNav.text = uri.text.replace(/(^https?\:\/\/(?:www\.)?)([a-zA-Z0-9_\-]*\.\w{2,3})(.*)/, "$1$2<span style='color:#CCC'>$3</span>");
+ uriNav.text = uri;
+
+ } else {
+ // Prevent inf loop.
+ window.cleanPath = false;
+ }
+ }
+
+ Label {
+ objectName: "miningLabel"
+ visible: false
+ font.pixelSize: 10
+ anchors.right: lastBlockLabel.left
+ anchors.rightMargin: 5
+ onTextChanged: {
+ menuItem.secondaryTitle = eth.miner().mining()? eth.miner().hashRate() + " Khash" : ""
+ }
+ }
+
+ Item {
+ objectName: "root"
+ id: root
+ anchors.fill: parent
+ state: "inspectorShown"
+
+ Timer {
+ interval: 1000; running: true; repeat: true
+ onTriggered: {
+ webview.runJavaScript("Miner.mining", function(miningSliderValue) {
+
+ // Check if it's mining and set it accordingly
+ if (miningSliderValue > 0 && !eth.miner().mining()) {
+ // If the
+ eth.miner().start();
+ } else if (miningSliderValue == 0 && eth.miner().mining()) {
+ eth.miner().stop();
+ } else if (eth.miner().mining()) {
+
+ webview.runJavaScript('var miningData = MiningData.findOne(); MiningData.update(miningData._id, {$inc: {totalTimeSpent: 1}}); Miner.hashrate = ' + eth.miner().hashRate() );
+
+ //var miningData = MiningData.findOne(); MiningData.update(miningData._id, {$inc: {totalTimeSpent: 1}});
+
+ } else if (miningSliderValue == "undefined") {
+
+ webview.runJavaScript('Miner.mining = 0' );
+
+ }
+ });
+
+ }
+ }
+
+ WebEngineView {
+ objectName: "webView"
+ id: webview
+ anchors.fill: parent
+
+ url: "network-health/index.html"
+ //url: "http://localhost:3000/"
+
+ experimental.settings.javascriptCanAccessClipboard: true
+
+
+ onJavaScriptConsoleMessage: {
+ console.log(sourceID + ":" + lineNumber + ":" + JSON.stringify(message));
+ }
+
+ onLoadingChanged: {
+ if (loadRequest.status == WebEngineView.LoadSucceededStatus) {
+ webview.runJavaScript(eth.readFile("mist.js"));
+ }
+ }
+ }
+
+ WebEngineView {
+ id: inspector
+ visible: false
+ z:10
+ anchors {
+ left: root.left
+ right: root.right
+ top: root.top
+ bottom: root.bottom
+ }
+
+ }
+
+ states: [
+ State {
+ name: "inspectorShown"
+ PropertyChanges {
+ target: inspector
+ }
+ }
+ ]
+ }
+}
diff --git a/cmd/mist/assets/qml/views/pending_tx.qml b/cmd/mist/assets/qml/views/pending_tx.qml
new file mode 100644
index 000000000..3dcedeff2
--- /dev/null
+++ b/cmd/mist/assets/qml/views/pending_tx.qml
@@ -0,0 +1,53 @@
+import QtQuick 2.0
+import QtQuick.Controls 1.0;
+import QtQuick.Layouts 1.0;
+import QtQuick.Dialogs 1.0;
+import QtQuick.Window 2.1;
+import QtQuick.Controls.Styles 1.1
+import Ethereum 1.0
+
+Rectangle {
+ property var title: "Pending Transactions"
+ property var menuItem
+
+ objectName: "pendingTxView"
+ anchors.fill: parent
+ visible: false
+ id: pendingTxView
+
+ property var pendingTxModel: ListModel {
+ id: pendingTxModel
+ }
+
+ TableView {
+ id: pendingTxTableView
+ anchors.fill: parent
+ TableViewColumn{ role: "value" ; title: "Value" ; width: 100 }
+ TableViewColumn{ role: "from" ; title: "sender" ; width: 230 }
+ TableViewColumn{ role: "to" ; title: "Reciever" ; width: 230 }
+ TableViewColumn{ role: "contract" ; title: "Contract" ; width: 100 }
+
+ model: pendingTxModel
+ }
+
+ function addTx(tx, inout) {
+ var isContract
+ if (tx.contract == true){
+ isContract = "Yes"
+ }else{
+ isContract = "No"
+ }
+
+
+ pendingTxModel.insert(0, {hash: tx.hash, to: tx.address, from: tx.sender, value: tx.value, contract: isContract})
+ }
+
+ function removeTx(tx) {
+ for (var i = 0; i < pendingTxModel.count; i++) {
+ if (tx.hash === pendingTxModel.get(i).hash) {
+ pendingTxModel.remove(i);
+ break;
+ }
+ }
+ }
+}
diff --git a/cmd/mist/assets/qml/views/transaction.qml b/cmd/mist/assets/qml/views/transaction.qml
new file mode 100644
index 000000000..df798a9c0
--- /dev/null
+++ b/cmd/mist/assets/qml/views/transaction.qml
@@ -0,0 +1,216 @@
+import QtQuick 2.0
+import QtQuick.Controls 1.0;
+import QtQuick.Layouts 1.0;
+import QtQuick.Dialogs 1.0;
+import QtQuick.Window 2.1;
+import QtQuick.Controls.Styles 1.1
+import Ethereum 1.0
+
+Rectangle {
+ property var title: "New Transaction"
+ property var menuItem
+
+ objectName: "newTxView"
+ visible: false
+ anchors.fill: parent
+ color: "#00000000"
+
+ Column {
+ id: mainContractColumn
+ anchors.fill: parent
+
+
+ states: [
+ State{
+ name: "ERROR"
+
+ PropertyChanges { target: txResult; visible:true}
+ PropertyChanges { target: codeView; visible:true}
+ },
+ State {
+ name: "DONE"
+
+ PropertyChanges { target: txValue; visible:false}
+ PropertyChanges { target: txGas; visible:false}
+ PropertyChanges { target: txGasPrice; visible:false}
+ PropertyChanges { target: codeView; visible:false}
+ PropertyChanges { target: txButton; visible:false}
+ PropertyChanges { target: txDataLabel; visible:false}
+ PropertyChanges { target: atLabel; visible:false}
+ PropertyChanges { target: txFuelRecipient; visible:false}
+ PropertyChanges { target: valueDenom; visible:false}
+ PropertyChanges { target: gasDenom; visible:false}
+
+ PropertyChanges { target: txResult; visible:true}
+ PropertyChanges { target: txOutput; visible:true}
+ PropertyChanges { target: newTxButton; visible:true}
+ },
+ State {
+ name: "SETUP"
+
+ PropertyChanges { target: txValue; visible:true; text: ""}
+ PropertyChanges { target: txGas; visible:true;}
+ PropertyChanges { target: txGasPrice; visible:true;}
+ PropertyChanges { target: codeView; visible:true; text: ""}
+ PropertyChanges { target: txButton; visible:true}
+ PropertyChanges { target: txDataLabel; visible:true}
+ PropertyChanges { target: valueDenom; visible:true}
+ PropertyChanges { target: gasDenom; visible:true}
+
+ PropertyChanges { target: txResult; visible:false}
+ PropertyChanges { target: txOutput; visible:false}
+ PropertyChanges { target: newTxButton; visible:false}
+ }
+ ]
+ width: 400
+ spacing: 5
+ anchors.left: parent.left
+ anchors.top: parent.top
+ anchors.leftMargin: 5
+ anchors.topMargin: 5
+
+ ListModel {
+ id: denomModel
+ ListElement { text: "Wei" ; zeros: "" }
+ ListElement { text: "Ada" ; zeros: "000" }
+ ListElement { text: "Babbage" ; zeros: "000000" }
+ ListElement { text: "Shannon" ; zeros: "000000000" }
+ ListElement { text: "Szabo" ; zeros: "000000000000" }
+ ListElement { text: "Finney" ; zeros: "000000000000000" }
+ ListElement { text: "Ether" ; zeros: "000000000000000000" }
+ ListElement { text: "Einstein" ;zeros: "000000000000000000000" }
+ ListElement { text: "Douglas" ; zeros: "000000000000000000000000000000000000000000" }
+ }
+
+
+ TextField {
+ id: txFuelRecipient
+ placeholderText: "Address / Name or empty for contract"
+ //validator: RegExpValidator { regExp: /[a-f0-9]{40}/ }
+ width: 400
+ }
+
+ RowLayout {
+ TextField {
+ id: txValue
+ width: 222
+ placeholderText: "Amount"
+ validator: RegExpValidator { regExp: /\d*/ }
+ onTextChanged: {
+ contractFormReady()
+ }
+ }
+
+ ComboBox {
+ id: valueDenom
+ currentIndex: 5
+ model: denomModel
+ }
+ }
+
+ RowLayout {
+ TextField {
+ id: txGas
+ width: 50
+ validator: RegExpValidator { regExp: /\d*/ }
+ placeholderText: "Gas"
+ text: "5000"
+ }
+ Label {
+ id: atLabel
+ text: "@"
+ }
+
+ TextField {
+ id: txGasPrice
+ width: 200
+ placeholderText: "Gas price"
+ text: "10"
+ validator: RegExpValidator { regExp: /\d*/ }
+ }
+
+ ComboBox {
+ id: gasDenom
+ currentIndex: 4
+ model: denomModel
+ }
+ }
+
+ Label {
+ id: txDataLabel
+ text: "Data"
+ }
+
+ TextArea {
+ id: codeView
+ height: 300
+ anchors.topMargin: 5
+ width: 400
+ onTextChanged: {
+ contractFormReady()
+ }
+ }
+
+
+ Button {
+ id: txButton
+ /* enabled: false */
+ states: [
+ State {
+ name: "READY"
+ PropertyChanges { target: txButton; /*enabled: true*/}
+ },
+ State {
+ name: "NOTREADY"
+ PropertyChanges { target: txButton; /*enabled:false*/}
+ }
+ ]
+ text: "Send"
+ onClicked: {
+ var value = txValue.text + denomModel.get(valueDenom.currentIndex).zeros;
+ var gasPrice = txGasPrice.text + denomModel.get(gasDenom.currentIndex).zeros;
+ var res = gui.transact(txFuelRecipient.text, value, txGas.text, gasPrice, codeView.text)
+ if(res[1]) {
+ txResult.text = "Your contract <b>could not</b> be sent over the network:\n<b>"
+ txResult.text += res[1].error()
+ txResult.text += "</b>"
+ mainContractColumn.state = "ERROR"
+ } else {
+ txResult.text = "Your transaction has been submitted:\n"
+ txOutput.text = res.toString()
+ mainContractColumn.state = "DONE"
+
+ console.log(res)
+ }
+ }
+ }
+ Text {
+ id: txResult
+ visible: false
+ }
+ TextField {
+ id: txOutput
+ visible: false
+ width: 530
+ }
+ Button {
+ id: newTxButton
+ visible: false
+ text: "Create a new transaction"
+ onClicked: {
+ this.visible = false
+ txResult.text = ""
+ txOutput.text = ""
+ mainContractColumn.state = "SETUP"
+ }
+ }
+ }
+
+ function contractFormReady(){
+ if(codeView.text.length > 0 && txValue.text.length > 0 && txGas.text.length > 0 && txGasPrice.length > 0) {
+ txButton.state = "READY"
+ }else{
+ txButton.state = "NOTREADY"
+ }
+ }
+}
diff --git a/cmd/mist/assets/qml/views/wallet.qml b/cmd/mist/assets/qml/views/wallet.qml
new file mode 100644
index 000000000..2369390c3
--- /dev/null
+++ b/cmd/mist/assets/qml/views/wallet.qml
@@ -0,0 +1,190 @@
+import QtQuick 2.0
+import QtQuick.Controls 1.0;
+import QtQuick.Layouts 1.0;
+import QtQuick.Dialogs 1.0;
+import QtQuick.Window 2.1;
+import QtQuick.Controls.Styles 1.1
+import Ethereum 1.0
+
+Rectangle {
+ id: root
+ property var title: "Wallet"
+ property var menuItem
+
+ objectName: "walletView"
+ anchors.fill: parent
+
+ Label {
+ objectName: "balanceLabel"
+ visible: false
+ onTextChanged: {
+ balance.text = text
+ menuItem.secondaryTitle = text
+ }
+ }
+
+ function onReady() {
+ setBalance()
+ }
+
+ function setBalance() {
+ balance.text = "<b>Balance</b>: " + eth.numberToHuman(eth.balanceAt(eth.coinbase()))
+ if(menuItem)
+ menuItem.secondaryTitle = eth.numberToHuman(eth.balanceAt(eth.coinbase()))
+ }
+
+ ListModel {
+ id: denomModel
+ ListElement { text: "Wei" ; zeros: "" }
+ ListElement { text: "Ada" ; zeros: "000" }
+ ListElement { text: "Babbage" ; zeros: "000000" }
+ ListElement { text: "Shannon" ; zeros: "000000000" }
+ ListElement { text: "Szabo" ; zeros: "000000000000" }
+ ListElement { text: "Finney" ; zeros: "000000000000000" }
+ ListElement { text: "Ether" ; zeros: "000000000000000000" }
+ ListElement { text: "Einstein" ;zeros: "000000000000000000000" }
+ ListElement { text: "Douglas" ; zeros: "000000000000000000000000000000000000000000" }
+ }
+
+ ColumnLayout {
+ spacing: 10
+ y: 40
+ anchors.fill: parent
+
+ Text {
+ id: balance
+ font.pixelSize: 24
+ anchors {
+ horizontalCenter: parent.horizontalCenter
+ top: parent.top
+ topMargin: 20
+ }
+ }
+
+ Rectangle {
+ id: newTxPane
+ color: "#ececec"
+ border.color: "#cccccc"
+ border.width: 1
+ anchors {
+ top: balance.bottom
+ topMargin: 10
+ left: parent.left
+ leftMargin: 5
+ right: parent.right
+ rightMargin: 5
+ }
+ height: 100
+
+ RowLayout {
+ id: amountFields
+ spacing: 10
+ anchors {
+ top: parent.top
+ topMargin: 20
+ left: parent.left
+ leftMargin: 20
+ }
+
+ Text {
+ text: "Ξ "
+ }
+
+ // There's something off with the row layout where textfields won't listen to the width setting
+ Rectangle {
+ width: 50
+ height: 20
+ TextField {
+ id: txValue
+ width: parent.width
+ placeholderText: "0.00"
+ }
+ }
+
+ ComboBox {
+ id: valueDenom
+ currentIndex: 5
+ model: denomModel
+ }
+
+ }
+
+ RowLayout {
+ id: toFields
+ spacing: 10
+ anchors {
+ top: amountFields.bottom
+ topMargin: 5
+ left: parent.left
+ leftMargin: 20
+ }
+
+ Text {
+ text: "To"
+ }
+
+ Rectangle {
+ width: 200
+ height: 20
+ TextField {
+ id: txTo
+ width: parent.width
+ placeholderText: "Address or name"
+ }
+ }
+
+ Button {
+ text: "Send"
+ onClicked: {
+ var value = txValue.text + denomModel.get(valueDenom.currentIndex).zeros;
+ var gasPrice = "10000000000000"
+ var res = eth.transact({from: eth.coinbase(), to: txTo.text, value: value, gas: "500", gasPrice: gasPrice})
+ }
+ }
+ }
+ }
+
+ Rectangle {
+ anchors {
+ left: parent.left
+ right: parent.right
+ top: newTxPane.bottom
+ topMargin: 10
+ bottom: parent.bottom
+ }
+ TableView {
+ id: txTableView
+ anchors.fill : parent
+ TableViewColumn{ role: "num" ; title: "#" ; width: 30 }
+ TableViewColumn{ role: "from" ; title: "From" ; width: 340 }
+ TableViewColumn{ role: "to" ; title: "To" ; width: 340 }
+ TableViewColumn{ role: "value" ; title: "Amount" ; width: 100 }
+
+ model: ListModel {
+ id: txModel
+ Component.onCompleted: {
+ }
+
+ function addTxs(messages) {
+ /*
+ setBalance()
+
+ for(var i = 0; i < messages.length; i++) {
+ var message = messages.get(i);
+ var to = eth.lookupName(message.to);
+ var from;
+ if(message.from.length == 0) {
+ from = "- MINED -";
+ } else {
+ from = eth.lookupName(message.from);
+ }
+ txModel.insert(0, {num: txModel.count, from: from, to: to, value: eth.numberToHuman(message.value)})
+ }
+ */
+ }
+ }
+ }
+ }
+
+ }
+}
diff --git a/cmd/mist/assets/qml/views/whisper.qml b/cmd/mist/assets/qml/views/whisper.qml
new file mode 100644
index 000000000..dc097b806
--- /dev/null
+++ b/cmd/mist/assets/qml/views/whisper.qml
@@ -0,0 +1,74 @@
+
+import QtQuick 2.0
+import QtQuick.Controls 1.0;
+import QtQuick.Layouts 1.0;
+import QtQuick.Dialogs 1.0;
+import QtQuick.Window 2.1;
+import QtQuick.Controls.Styles 1.1
+import Ethereum 1.0
+
+Rectangle {
+ id: root
+ property var title: "Whisper Traffic"
+ property var menuItem
+
+ objectName: "whisperView"
+ anchors.fill: parent
+
+ property var identity: ""
+ Component.onCompleted: {
+ identity = shh.newIdentity()
+
+ var t = shh.watch({}, root)
+ }
+
+ function onShhMessage(message, i) {
+ whisperModel.insert(0, {from: message.from, payload: eth.toAscii(message.payload)})
+ }
+
+ RowLayout {
+ id: input
+ anchors {
+ left: parent.left
+ leftMargin: 20
+ top: parent.top
+ topMargin: 20
+ }
+
+ TextField {
+ id: to
+ placeholderText: "To"
+ }
+ TextField {
+ id: data
+ placeholderText: "Data"
+ }
+ TextField {
+ id: topics
+ placeholderText: "topic1, topic2, topic3, ..."
+ }
+ Button {
+ text: "Send"
+ onClicked: {
+ shh.post([eth.toHex(data.text)], "", identity, topics.text.split(","), 500, 50)
+ }
+ }
+ }
+
+ TableView {
+ id: txTableView
+ anchors {
+ top: input.bottom
+ topMargin: 10
+ bottom: parent.bottom
+ left: parent.left
+ right: parent.right
+ }
+ TableViewColumn{ id: fromRole; role: "from" ; title: "From"; width: 300 }
+ TableViewColumn{ role: "payload" ; title: "Payload" ; width: parent.width - fromRole.width - 2 }
+
+ model: ListModel {
+ id: whisperModel
+ }
+ }
+}
diff --git a/cmd/mist/assets/tx.png b/cmd/mist/assets/tx.png
new file mode 100644
index 000000000..62204c315
--- /dev/null
+++ b/cmd/mist/assets/tx.png
Binary files differ
diff --git a/cmd/mist/assets/util/test.html b/cmd/mist/assets/util/test.html
new file mode 100644
index 000000000..d458e6670
--- /dev/null
+++ b/cmd/mist/assets/util/test.html
@@ -0,0 +1,43 @@
+<html>
+<head>
+<title>Utils</title>
+</head>
+<body onload="init();">
+<label>Nonce for 2ef47100e0787b915105fd5e3f4ff6752079d5cb</label>
+<p id="nonce"></p>
+
+<label>Connected peers</label>
+<p id="peers"></p>
+
+<label>Is mining</label>
+<p id="isMining"></p>
+
+<label>Is listening</label>
+<p id="isListen"></p>
+
+<label>Coinbase</label>
+<p id="coinbase"></p>
+
+<script type="text/javascript">
+
+function init() {
+ eth.getTxCountAt("2ef47100e0787b915105fd5e3f4ff6752079d5cb", function(nonce){
+ document.querySelector("#nonce").innerHTML = nonce;
+ })
+ eth.getPeerCount(function(peerLength){
+ document.querySelector("#peers").innerHTML = peerLength;
+ })
+ eth.getIsMining(function(mining){
+ document.querySelector("#isMining").innerHTML = mining;
+ })
+ eth.getIsListening(function(listen){
+ document.querySelector("#isListen").innerHTML = listen;
+ })
+ eth.getCoinBase(function(address){
+ document.querySelector("#coinbase").innerHTML = address;
+ })
+}
+</script>
+</body>
+</html>
+
diff --git a/cmd/mist/assets/wallet.png b/cmd/mist/assets/wallet.png
new file mode 100644
index 000000000..92c401e52
--- /dev/null
+++ b/cmd/mist/assets/wallet.png
Binary files differ
diff --git a/cmd/mist/bindings.go b/cmd/mist/bindings.go
new file mode 100644
index 000000000..e7ce50c35
--- /dev/null
+++ b/cmd/mist/bindings.go
@@ -0,0 +1,92 @@
+/*
+ This file is part of go-ethereum
+
+ go-ethereum is free software: you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation, either version 3 of the License, or
+ (at your option) any later version.
+
+ go-ethereum is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with go-ethereum. If not, see <http://www.gnu.org/licenses/>.
+*/
+/**
+ * @authors
+ * Jeffrey Wilcke <i@jev.io>
+ */
+package main
+
+import (
+ "encoding/json"
+ "io/ioutil"
+ "os"
+ "strconv"
+
+ "github.com/ethereum/go-ethereum/cmd/utils"
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/core/state"
+ "github.com/ethereum/go-ethereum/core/types"
+)
+
+type plugin struct {
+ Name string `json:"name"`
+ Path string `json:"path"`
+}
+
+func (gui *Gui) Transact(from, recipient, value, gas, gasPrice, d string) (string, error) {
+ d = common.Bytes2Hex(utils.FormatTransactionData(d))
+
+ return gui.xeth.Transact(from, recipient, value, gas, gasPrice, d)
+}
+
+func (self *Gui) AddPlugin(pluginPath string) {
+ self.plugins[pluginPath] = plugin{Name: pluginPath, Path: pluginPath}
+
+ json, _ := json.MarshalIndent(self.plugins, "", " ")
+ ioutil.WriteFile(self.eth.DataDir+"/plugins.json", json, os.ModePerm)
+}
+
+func (self *Gui) RemovePlugin(pluginPath string) {
+ delete(self.plugins, pluginPath)
+
+ json, _ := json.MarshalIndent(self.plugins, "", " ")
+ ioutil.WriteFile(self.eth.DataDir+"/plugins.json", json, os.ModePerm)
+}
+
+func (self *Gui) DumpState(hash, path string) {
+ var stateDump []byte
+
+ if len(hash) == 0 {
+ stateDump = self.eth.ChainManager().State().Dump()
+ } else {
+ var block *types.Block
+ if hash[0] == '#' {
+ i, _ := strconv.Atoi(hash[1:])
+ block = self.eth.ChainManager().GetBlockByNumber(uint64(i))
+ } else {
+ block = self.eth.ChainManager().GetBlock(common.HexToHash(hash))
+ }
+
+ if block == nil {
+ guilogger.Infof("block err: not found %s\n", hash)
+ return
+ }
+
+ stateDump = state.New(block.Root(), self.eth.StateDb()).Dump()
+ }
+
+ file, err := os.OpenFile(path[7:], os.O_CREATE|os.O_RDWR, os.ModePerm)
+ if err != nil {
+ guilogger.Infoln("dump err: ", err)
+ return
+ }
+ defer file.Close()
+
+ guilogger.Infof("dumped state (%s) to %s\n", hash, path)
+
+ file.Write(stateDump)
+}
diff --git a/cmd/mist/errors.go b/cmd/mist/errors.go
new file mode 100644
index 000000000..255ed07c1
--- /dev/null
+++ b/cmd/mist/errors.go
@@ -0,0 +1,56 @@
+/*
+ This file is part of go-ethereum
+
+ go-ethereum is free software: you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation, either version 3 of the License, or
+ (at your option) any later version.
+
+ go-ethereum is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with go-ethereum. If not, see <http://www.gnu.org/licenses/>.
+*/
+/**
+ * @authors
+ * Jeffrey Wilcke <i@jev.io>
+ */
+package main
+
+import (
+ "fmt"
+ "os"
+
+ "github.com/obscuren/qml"
+)
+
+func ErrorWindow(err error) {
+ engine := qml.NewEngine()
+ component, e := engine.LoadString("local", qmlErr)
+ if e != nil {
+ fmt.Println("err:", err)
+ os.Exit(1)
+ }
+
+ win := component.CreateWindow(nil)
+ win.Root().ObjectByName("label").Set("text", err.Error())
+ win.Show()
+ win.Wait()
+}
+
+const qmlErr = `
+import QtQuick 2.0; import QtQuick.Controls 1.0;
+ApplicationWindow {
+ width: 600; height: 150;
+ flags: Qt.CustomizeWindowHint | Qt.WindowTitleHint | Qt.WindowCloseButtonHint
+ title: "Error"
+ Text {
+ x: parent.width / 2 - this.width / 2;
+ y: parent.height / 2 - this.height / 2;
+ objectName: "label";
+ }
+}
+`
diff --git a/cmd/mist/gui.go b/cmd/mist/gui.go
new file mode 100644
index 000000000..d37d6f81b
--- /dev/null
+++ b/cmd/mist/gui.go
@@ -0,0 +1,464 @@
+/*
+ This file is part of go-ethereum
+
+ go-ethereum is free software: you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation, either version 3 of the License, or
+ (at your option) any later version.
+
+ go-ethereum is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with go-ethereum. If not, see <http://www.gnu.org/licenses/>.
+*/
+/**
+ * @authors
+ * Jeffrey Wilcke <i@jev.io>
+ */
+package main
+
+import "C"
+
+import (
+ "encoding/json"
+ "fmt"
+ "io/ioutil"
+ "math/big"
+ "path"
+ "runtime"
+ "sort"
+ "time"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/core"
+ "github.com/ethereum/go-ethereum/core/types"
+ "github.com/ethereum/go-ethereum/eth"
+ "github.com/ethereum/go-ethereum/ethdb"
+ "github.com/ethereum/go-ethereum/logger"
+ "github.com/ethereum/go-ethereum/ui/qt/qwhisper"
+ "github.com/ethereum/go-ethereum/xeth"
+ "github.com/obscuren/qml"
+)
+
+var guilogger = logger.NewLogger("GUI")
+
+type ServEv byte
+
+const (
+ setup ServEv = iota
+ update
+)
+
+type Gui struct {
+ // The main application window
+ win *qml.Window
+ // QML Engine
+ engine *qml.Engine
+ component *qml.Common
+ // The ethereum interface
+ eth *eth.Ethereum
+ serviceEvents chan ServEv
+
+ // The public Ethereum library
+ uiLib *UiLib
+ whisper *qwhisper.Whisper
+
+ txDb *ethdb.LDBDatabase
+
+ open bool
+
+ xeth *xeth.XEth
+
+ Session string
+
+ plugins map[string]plugin
+}
+
+// Create GUI, but doesn't start it
+func NewWindow(ethereum *eth.Ethereum) *Gui {
+ db, err := ethdb.NewLDBDatabase(path.Join(ethereum.DataDir, "tx_database"))
+ if err != nil {
+ panic(err)
+ }
+
+ xeth := xeth.New(ethereum, nil)
+ gui := &Gui{eth: ethereum,
+ txDb: db,
+ xeth: xeth,
+ open: false,
+ plugins: make(map[string]plugin),
+ serviceEvents: make(chan ServEv, 1),
+ }
+ data, _ := ioutil.ReadFile(path.Join(ethereum.DataDir, "plugins.json"))
+ json.Unmarshal(data, &gui.plugins)
+
+ return gui
+}
+
+func (gui *Gui) Start(assetPath, libPath string) {
+ defer gui.txDb.Close()
+
+ guilogger.Infoln("Starting GUI")
+
+ go gui.service()
+
+ // Register ethereum functions
+ qml.RegisterTypes("Ethereum", 1, 0, []qml.TypeSpec{{
+ Init: func(p *xeth.Block, obj qml.Object) { p.Number = 0; p.Hash = "" },
+ }, {
+ Init: func(p *xeth.Transaction, obj qml.Object) { p.Value = ""; p.Hash = ""; p.Address = "" },
+ }, {
+ Init: func(p *xeth.KeyVal, obj qml.Object) { p.Key = ""; p.Value = "" },
+ }})
+ // Create a new QML engine
+ gui.engine = qml.NewEngine()
+ context := gui.engine.Context()
+ gui.uiLib = NewUiLib(gui.engine, gui.eth, assetPath, libPath)
+ gui.whisper = qwhisper.New(gui.eth.Whisper())
+
+ // Expose the eth library and the ui library to QML
+ context.SetVar("gui", gui)
+ context.SetVar("eth", gui.uiLib)
+ context.SetVar("shh", gui.whisper)
+ //clipboard.SetQMLClipboard(context)
+
+ win, err := gui.showWallet(context)
+ if err != nil {
+ guilogger.Errorln("asset not found: you can set an alternative asset path on the command line using option 'asset_path'", err)
+
+ panic(err)
+ }
+
+ gui.open = true
+ win.Show()
+
+ win.Wait()
+ gui.open = false
+}
+
+func (gui *Gui) Stop() {
+ if gui.open {
+ gui.open = false
+ gui.win.Hide()
+ }
+
+ guilogger.Infoln("Stopped")
+}
+
+func (gui *Gui) showWallet(context *qml.Context) (*qml.Window, error) {
+ component, err := gui.engine.LoadFile(gui.uiLib.AssetPath("qml/main.qml"))
+ if err != nil {
+ return nil, err
+ }
+
+ gui.createWindow(component)
+
+ return gui.win, nil
+}
+
+func (gui *Gui) GenerateKey() {
+ _, err := gui.eth.AccountManager().NewAccount("hurr")
+ if err != nil {
+ // TODO: UI feedback?
+ }
+}
+
+func (gui *Gui) showKeyImport(context *qml.Context) (*qml.Window, error) {
+ context.SetVar("lib", gui)
+ component, err := gui.engine.LoadFile(gui.uiLib.AssetPath("qml/first_run.qml"))
+ if err != nil {
+ return nil, err
+ }
+ return gui.createWindow(component), nil
+}
+
+func (gui *Gui) createWindow(comp qml.Object) *qml.Window {
+ gui.win = comp.CreateWindow(nil)
+ gui.uiLib.win = gui.win
+
+ return gui.win
+}
+
+func (gui *Gui) setInitialChain(ancientBlocks bool) {
+ sBlk := gui.eth.ChainManager().LastBlockHash()
+ blk := gui.eth.ChainManager().GetBlock(sBlk)
+ for ; blk != nil; blk = gui.eth.ChainManager().GetBlock(sBlk) {
+ sBlk = blk.ParentHash()
+ gui.processBlock(blk, true)
+ }
+}
+
+func (gui *Gui) loadAddressBook() {
+ /*
+ view := gui.getObjectByName("infoView")
+ nameReg := gui.xeth.World().Config().Get("NameReg")
+ if nameReg != nil {
+ it := nameReg.Trie().Iterator()
+ for it.Next() {
+ if it.Key[0] != 0 {
+ view.Call("addAddress", struct{ Name, Address string }{string(it.Key), common.Bytes2Hex(it.Value)})
+ }
+
+ }
+ }
+ */
+}
+
+func (self *Gui) loadMergedMiningOptions() {
+ /*
+ view := self.getObjectByName("mergedMiningModel")
+
+ mergeMining := self.xeth.World().Config().Get("MergeMining")
+ if mergeMining != nil {
+ i := 0
+ it := mergeMining.Trie().Iterator()
+ for it.Next() {
+ view.Call("addMergedMiningOption", struct {
+ Checked bool
+ Name, Address string
+ Id, ItemId int
+ }{false, string(it.Key), common.Bytes2Hex(it.Value), 0, i})
+
+ i++
+
+ }
+ }
+ */
+}
+
+func (gui *Gui) insertTransaction(window string, tx *types.Transaction) {
+ var inout string
+ from, _ := tx.From()
+ if gui.eth.AccountManager().HasAccount(common.Hex2Bytes(from.Hex())) {
+ inout = "send"
+ } else {
+ inout = "recv"
+ }
+
+ var (
+ ptx = xeth.NewTx(tx)
+ send = from.Hex()
+ rec = tx.To().Hex()
+ )
+ ptx.Sender = send
+ ptx.Address = rec
+
+ if window == "post" {
+ //gui.getObjectByName("transactionView").Call("addTx", ptx, inout)
+ } else {
+ gui.getObjectByName("pendingTxView").Call("addTx", ptx, inout)
+ }
+}
+
+func (gui *Gui) readPreviousTransactions() {
+ it := gui.txDb.NewIterator()
+ for it.Next() {
+ tx := types.NewTransactionFromBytes(it.Value())
+
+ gui.insertTransaction("post", tx)
+
+ }
+ it.Release()
+}
+
+func (gui *Gui) processBlock(block *types.Block, initial bool) {
+ name := block.Coinbase().Hex()
+ b := xeth.NewBlock(block)
+ b.Name = name
+
+ gui.getObjectByName("chainView").Call("addBlock", b, initial)
+}
+
+func (gui *Gui) setWalletValue(amount, unconfirmedFunds *big.Int) {
+ var str string
+ if unconfirmedFunds != nil {
+ pos := "+"
+ if unconfirmedFunds.Cmp(big.NewInt(0)) < 0 {
+ pos = "-"
+ }
+ val := common.CurrencyToString(new(big.Int).Abs(common.BigCopy(unconfirmedFunds)))
+ str = fmt.Sprintf("%v (%s %v)", common.CurrencyToString(amount), pos, val)
+ } else {
+ str = fmt.Sprintf("%v", common.CurrencyToString(amount))
+ }
+
+ gui.win.Root().Call("setWalletValue", str)
+}
+
+func (self *Gui) getObjectByName(objectName string) qml.Object {
+ return self.win.Root().ObjectByName(objectName)
+}
+
+func (gui *Gui) SendCommand(cmd ServEv) {
+ gui.serviceEvents <- cmd
+}
+
+func (gui *Gui) service() {
+ for ev := range gui.serviceEvents {
+ switch ev {
+ case setup:
+ go gui.setup()
+ case update:
+ go gui.update()
+ }
+ }
+}
+
+func (gui *Gui) setup() {
+ for gui.win == nil {
+ time.Sleep(time.Millisecond * 200)
+ }
+
+ for _, plugin := range gui.plugins {
+ guilogger.Infoln("Loading plugin ", plugin.Name)
+ gui.win.Root().Call("addPlugin", plugin.Path, "")
+ }
+
+ go func() {
+ go gui.setInitialChain(false)
+ gui.loadAddressBook()
+ gui.loadMergedMiningOptions()
+ gui.setPeerInfo()
+ }()
+
+ gui.whisper.SetView(gui.getObjectByName("whisperView"))
+
+ gui.SendCommand(update)
+}
+
+// Simple go routine function that updates the list of peers in the GUI
+func (gui *Gui) update() {
+ peerUpdateTicker := time.NewTicker(5 * time.Second)
+ generalUpdateTicker := time.NewTicker(500 * time.Millisecond)
+ statsUpdateTicker := time.NewTicker(5 * time.Second)
+
+ lastBlockLabel := gui.getObjectByName("lastBlockLabel")
+ //miningLabel := gui.getObjectByName("miningLabel")
+
+ events := gui.eth.EventMux().Subscribe(
+ core.ChainEvent{},
+ core.TxPreEvent{},
+ core.TxPostEvent{},
+ )
+
+ defer events.Unsubscribe()
+ for {
+ select {
+ case ev, isopen := <-events.Chan():
+ if !isopen {
+ return
+ }
+ switch ev := ev.(type) {
+ case core.ChainEvent:
+ gui.processBlock(ev.Block, false)
+ case core.TxPreEvent:
+ gui.insertTransaction("pre", ev.Tx)
+
+ case core.TxPostEvent:
+ gui.getObjectByName("pendingTxView").Call("removeTx", xeth.NewTx(ev.Tx))
+ }
+
+ case <-peerUpdateTicker.C:
+ gui.setPeerInfo()
+
+ case <-generalUpdateTicker.C:
+ statusText := "#" + gui.eth.ChainManager().CurrentBlock().Number().String()
+ lastBlockLabel.Set("text", statusText)
+ //miningLabel.Set("text", strconv.FormatInt(gui.uiLib.Miner().HashRate(), 10))
+ case <-statsUpdateTicker.C:
+ gui.setStatsPane()
+ }
+ }
+}
+
+func (gui *Gui) setStatsPane() {
+ var memStats runtime.MemStats
+ runtime.ReadMemStats(&memStats)
+
+ statsPane := gui.getObjectByName("statsPane")
+ statsPane.Set("text", fmt.Sprintf(`###### Mist %s (%s) #######
+
+eth %d (p2p = %d)
+
+CPU: # %d
+Goroutines: # %d
+CGoCalls: # %d
+
+Alloc: %d
+Heap Alloc: %d
+
+CGNext: %x
+NumGC: %d
+`, Version, runtime.Version(),
+ eth.ProtocolVersion, 2,
+ runtime.NumCPU, runtime.NumGoroutine(), runtime.NumCgoCall(),
+ memStats.Alloc, memStats.HeapAlloc,
+ memStats.NextGC, memStats.NumGC,
+ ))
+}
+
+type qmlpeer struct{ Addr, NodeID, Name, Caps string }
+
+type peersByID []*qmlpeer
+
+func (s peersByID) Len() int { return len(s) }
+func (s peersByID) Less(i, j int) bool { return s[i].NodeID < s[j].NodeID }
+func (s peersByID) Swap(i, j int) { s[i], s[j] = s[j], s[i] }
+
+func (gui *Gui) setPeerInfo() {
+ peers := gui.eth.Peers()
+ qpeers := make(peersByID, len(peers))
+ for i, p := range peers {
+ qpeers[i] = &qmlpeer{
+ NodeID: p.ID().String(),
+ Addr: p.RemoteAddr().String(),
+ Name: p.Name(),
+ Caps: fmt.Sprint(p.Caps()),
+ }
+ }
+ // we need to sort the peers because they jump around randomly
+ // otherwise. order returned by eth.Peers is random because they
+ // are taken from a map.
+ sort.Sort(qpeers)
+
+ gui.win.Root().Call("setPeerCounters", fmt.Sprintf("%d / %d", len(peers), gui.eth.MaxPeers()))
+ gui.win.Root().Call("clearPeers")
+ for _, p := range qpeers {
+ gui.win.Root().Call("addPeer", p)
+ }
+}
+
+/*
+func LoadExtension(path string) (uintptr, error) {
+ lib, err := ffi.NewLibrary(path)
+ if err != nil {
+ return 0, err
+ }
+
+ so, err := lib.Fct("sharedObject", ffi.Pointer, nil)
+ if err != nil {
+ return 0, err
+ }
+
+ ptr := so()
+
+ err = lib.Close()
+ if err != nil {
+ return 0, err
+ }
+
+ return ptr.Interface().(uintptr), nil
+}
+*/
+/*
+ vec, errr := LoadExtension("/Users/jeffrey/Desktop/build-libqmltest-Desktop_Qt_5_2_1_clang_64bit-Debug/liblibqmltest_debug.dylib")
+ fmt.Printf("Fetched vec with addr: %#x\n", vec)
+ if errr != nil {
+ fmt.Println(errr)
+ } else {
+ context.SetVar("vec", (unsafe.Pointer)(vec))
+ }
+*/
diff --git a/cmd/mist/html_container.go b/cmd/mist/html_container.go
new file mode 100644
index 000000000..7c948885a
--- /dev/null
+++ b/cmd/mist/html_container.go
@@ -0,0 +1,153 @@
+/*
+ This file is part of go-ethereum
+
+ go-ethereum is free software: you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation, either version 3 of the License, or
+ (at your option) any later version.
+
+ go-ethereum is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with go-ethereum. If not, see <http://www.gnu.org/licenses/>.
+*/
+/**
+ * @authors
+ * Jeffrey Wilcke <i@jev.io>
+ */
+package main
+
+import (
+ "errors"
+ "fmt"
+ "io/ioutil"
+ "net/url"
+ "os"
+ "path"
+ "path/filepath"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/core/types"
+ "github.com/ethereum/go-ethereum/xeth"
+ "github.com/howeyc/fsnotify"
+ "github.com/obscuren/qml"
+)
+
+type HtmlApplication struct {
+ win *qml.Window
+ webView qml.Object
+ engine *qml.Engine
+ lib *UiLib
+ path string
+ watcher *fsnotify.Watcher
+}
+
+func NewHtmlApplication(path string, lib *UiLib) *HtmlApplication {
+ engine := qml.NewEngine()
+
+ return &HtmlApplication{engine: engine, lib: lib, path: path}
+
+}
+
+func (app *HtmlApplication) Create() error {
+ component, err := app.engine.LoadFile(app.lib.AssetPath("qml/webapp.qml"))
+ if err != nil {
+ return err
+ }
+
+ if filepath.Ext(app.path) == "eth" {
+ return errors.New("Ethereum package not yet supported")
+
+ // TODO
+ //common.OpenPackage(app.path)
+ }
+
+ win := component.CreateWindow(nil)
+ win.Set("url", app.path)
+ webView := win.ObjectByName("webView")
+
+ app.win = win
+ app.webView = webView
+
+ return nil
+}
+
+func (app *HtmlApplication) RootFolder() string {
+ folder, err := url.Parse(app.path)
+ if err != nil {
+ return ""
+ }
+ return path.Dir(common.WindonizePath(folder.RequestURI()))
+}
+func (app *HtmlApplication) RecursiveFolders() []os.FileInfo {
+ files, _ := ioutil.ReadDir(app.RootFolder())
+ var folders []os.FileInfo
+ for _, file := range files {
+ if file.IsDir() {
+ folders = append(folders, file)
+ }
+ }
+ return folders
+}
+
+func (app *HtmlApplication) NewWatcher(quitChan chan bool) {
+ var err error
+
+ app.watcher, err = fsnotify.NewWatcher()
+ if err != nil {
+ guilogger.Infoln("Could not create new auto-reload watcher:", err)
+ return
+ }
+ err = app.watcher.Watch(app.RootFolder())
+ if err != nil {
+ guilogger.Infoln("Could not start auto-reload watcher:", err)
+ return
+ }
+ for _, folder := range app.RecursiveFolders() {
+ fullPath := app.RootFolder() + "/" + folder.Name()
+ app.watcher.Watch(fullPath)
+ }
+
+ go func() {
+ out:
+ for {
+ select {
+ case <-quitChan:
+ app.watcher.Close()
+ break out
+ case <-app.watcher.Event:
+ //guilogger.Debugln("Got event:", ev)
+ app.webView.Call("reload")
+ case err := <-app.watcher.Error:
+ // TODO: Do something here
+ guilogger.Infoln("Watcher error:", err)
+ }
+ }
+ }()
+
+}
+
+func (app *HtmlApplication) Engine() *qml.Engine {
+ return app.engine
+}
+
+func (app *HtmlApplication) Window() *qml.Window {
+ return app.win
+}
+
+func (app *HtmlApplication) NewBlock(block *types.Block) {
+ b := &xeth.Block{Number: int(block.NumberU64()), Hash: block.Hash().Hex()}
+ app.webView.Call("onNewBlockCb", b)
+}
+
+func (app *HtmlApplication) Destroy() {
+ app.engine.Destroy()
+}
+
+func (app *HtmlApplication) Post(data string, seed int) {
+ fmt.Println("about to call 'post'")
+ app.webView.Call("post", seed, data)
+}
diff --git a/cmd/mist/main.go b/cmd/mist/main.go
new file mode 100644
index 000000000..6780cfb3a
--- /dev/null
+++ b/cmd/mist/main.go
@@ -0,0 +1,127 @@
+/*
+ This file is part of go-ethereum
+
+ go-ethereum is free software: you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation, either version 3 of the License, or
+ (at your option) any later version.
+
+ go-ethereum is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with go-ethereum. If not, see <http://www.gnu.org/licenses/>.
+*/
+/**
+ * @authors
+ * Jeffrey Wilcke <i@jev.io>
+ */
+package main
+
+import (
+ "fmt"
+ "os"
+ "runtime"
+ "time"
+
+ "github.com/codegangsta/cli"
+ "github.com/ethereum/go-ethereum/cmd/utils"
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/eth"
+ "github.com/ethereum/go-ethereum/logger"
+ "github.com/ethereum/go-ethereum/ui/qt/webengine"
+ "github.com/obscuren/qml"
+)
+
+const (
+ ClientIdentifier = "Mist"
+ Version = "0.9.0"
+)
+
+var (
+ app = utils.NewApp(Version, "the ether browser")
+ assetPathFlag = cli.StringFlag{
+ Name: "asset_path",
+ Usage: "absolute path to GUI assets directory",
+ Value: common.DefaultAssetPath(),
+ }
+ rpcCorsFlag = utils.RPCCORSDomainFlag
+)
+
+func init() {
+ // Mist-specific default
+ if len(rpcCorsFlag.Value) == 0 {
+ rpcCorsFlag.Value = "http://localhost"
+ }
+
+ app.Action = run
+ app.Flags = []cli.Flag{
+ assetPathFlag,
+ rpcCorsFlag,
+
+ utils.BootnodesFlag,
+ utils.DataDirFlag,
+ utils.ListenPortFlag,
+ utils.LogFileFlag,
+ utils.LogLevelFlag,
+ utils.MaxPeersFlag,
+ utils.MinerThreadsFlag,
+ utils.NATFlag,
+ utils.NodeKeyFileFlag,
+ utils.RPCListenAddrFlag,
+ utils.RPCPortFlag,
+ utils.JSpathFlag,
+ utils.ProtocolVersionFlag,
+ utils.NetworkIdFlag,
+ }
+}
+
+func main() {
+ runtime.GOMAXPROCS(runtime.NumCPU())
+
+ // This is a bit of a cheat, but ey!
+ os.Setenv("QTWEBKIT_INSPECTOR_SERVER", "127.0.0.1:99999")
+
+ var interrupted = false
+ utils.RegisterInterrupt(func(os.Signal) {
+ interrupted = true
+ })
+ utils.HandleInterrupt()
+
+ if err := app.Run(os.Args); err != nil {
+ fmt.Fprintln(os.Stderr, "Error: ", err)
+ }
+
+ // we need to run the interrupt callbacks in case gui is closed
+ // this skips if we got here by actual interrupt stopping the GUI
+ if !interrupted {
+ utils.RunInterruptCallbacks(os.Interrupt)
+ }
+ logger.Flush()
+}
+
+func run(ctx *cli.Context) {
+ tstart := time.Now()
+
+ // TODO: show qml popup instead of exiting if initialization fails.
+ cfg := utils.MakeEthConfig(ClientIdentifier, Version, ctx)
+ ethereum, err := eth.New(cfg)
+ if err != nil {
+ utils.Fatalf("%v", err)
+ }
+ utils.StartRPC(ethereum, ctx)
+ go utils.StartEthereum(ethereum)
+ fmt.Println("initializing eth stack took", time.Since(tstart))
+
+ // Open the window
+ qml.Run(func() error {
+ webengine.Initialize()
+ gui := NewWindow(ethereum)
+ utils.RegisterInterrupt(func(os.Signal) { gui.Stop() })
+ // gui blocks the main thread
+ gui.Start(ctx.GlobalString(assetPathFlag.Name), ctx.GlobalString(utils.JSpathFlag.Name))
+ return nil
+ })
+}
diff --git a/cmd/mist/qml_container.go b/cmd/mist/qml_container.go
new file mode 100644
index 000000000..f2cabb474
--- /dev/null
+++ b/cmd/mist/qml_container.go
@@ -0,0 +1,82 @@
+/*
+ This file is part of go-ethereum
+
+ go-ethereum is free software: you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation, either version 3 of the License, or
+ (at your option) any later version.
+
+ go-ethereum is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with go-ethereum. If not, see <http://www.gnu.org/licenses/>.
+*/
+/**
+ * @authors
+ * Jeffrey Wilcke <i@jev.io>
+ */
+
+package main
+
+import (
+ "runtime"
+
+ "github.com/ethereum/go-ethereum/core/types"
+ "github.com/ethereum/go-ethereum/xeth"
+ "github.com/obscuren/qml"
+)
+
+type QmlApplication struct {
+ win *qml.Window
+ engine *qml.Engine
+ lib *UiLib
+ path string
+}
+
+func NewQmlApplication(path string, lib *UiLib) *QmlApplication {
+ engine := qml.NewEngine()
+ return &QmlApplication{engine: engine, path: path, lib: lib}
+}
+
+func (app *QmlApplication) Create() error {
+ path := string(app.path)
+
+ // For some reason for windows we get /c:/path/to/something, windows doesn't like the first slash but is fine with the others so we are removing it
+ if app.path[0] == '/' && runtime.GOOS == "windows" {
+ path = app.path[1:]
+ }
+
+ component, err := app.engine.LoadFile(path)
+ if err != nil {
+ guilogger.Warnln(err)
+ }
+ app.win = component.CreateWindow(nil)
+
+ return nil
+}
+
+func (app *QmlApplication) Destroy() {
+ app.engine.Destroy()
+}
+
+func (app *QmlApplication) NewWatcher(quitChan chan bool) {
+}
+
+// Events
+func (app *QmlApplication) NewBlock(block *types.Block) {
+ pblock := &xeth.Block{Number: int(block.NumberU64()), Hash: block.Hash().Hex()}
+ app.win.Call("onNewBlockCb", pblock)
+}
+
+// Getters
+func (app *QmlApplication) Engine() *qml.Engine {
+ return app.engine
+}
+func (app *QmlApplication) Window() *qml.Window {
+ return app.win
+}
+
+func (app *QmlApplication) Post(data string, s int) {}
diff --git a/cmd/mist/ui_lib.go b/cmd/mist/ui_lib.go
new file mode 100644
index 000000000..34ce56e77
--- /dev/null
+++ b/cmd/mist/ui_lib.go
@@ -0,0 +1,280 @@
+/*
+ This file is part of go-ethereum
+
+ go-ethereum is free software: you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation, either version 3 of the License, or
+ (at your option) any later version.
+
+ go-ethereum is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with go-ethereum. If not, see <http://www.gnu.org/licenses/>.
+*/
+/**
+ * @authors
+ * Jeffrey Wilcke <i@jev.io>
+ */
+package main
+
+import (
+ "io/ioutil"
+ "path"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/core/types"
+ "github.com/ethereum/go-ethereum/eth"
+ "github.com/ethereum/go-ethereum/event/filter"
+ "github.com/ethereum/go-ethereum/xeth"
+ "github.com/obscuren/qml"
+)
+
+type memAddr struct {
+ Num string
+ Value string
+}
+
+// UI Library that has some basic functionality exposed
+type UiLib struct {
+ *xeth.XEth
+ engine *qml.Engine
+ eth *eth.Ethereum
+ connected bool
+ assetPath string
+ // The main application window
+ win *qml.Window
+
+ filterCallbacks map[int][]int
+ filterManager *filter.FilterManager
+}
+
+func NewUiLib(engine *qml.Engine, eth *eth.Ethereum, assetPath, libPath string) *UiLib {
+ x := xeth.New(eth, nil)
+ lib := &UiLib{
+ XEth: x,
+ engine: engine,
+ eth: eth,
+ assetPath: assetPath,
+ filterCallbacks: make(map[int][]int),
+ }
+ lib.filterManager = filter.NewFilterManager(eth.EventMux())
+ go lib.filterManager.Start()
+
+ return lib
+}
+
+func (self *UiLib) Notef(args []interface{}) {
+ guilogger.Infoln(args...)
+}
+
+func (self *UiLib) ImportTx(rlpTx string) {
+ tx := types.NewTransactionFromBytes(common.Hex2Bytes(rlpTx))
+ err := self.eth.TxPool().Add(tx)
+ if err != nil {
+ guilogger.Infoln("import tx failed ", err)
+ }
+}
+
+func (ui *UiLib) Muted(content string) {
+ component, err := ui.engine.LoadFile(ui.AssetPath("qml/muted.qml"))
+ if err != nil {
+ guilogger.Debugln(err)
+
+ return
+ }
+ win := component.CreateWindow(nil)
+ go func() {
+ path := "file://" + ui.AssetPath("muted/index.html")
+ win.Set("url", path)
+
+ win.Show()
+ win.Wait()
+ }()
+}
+
+func (ui *UiLib) Connect(button qml.Object) {
+ if !ui.connected {
+ ui.eth.Start()
+ ui.connected = true
+ button.Set("enabled", false)
+ }
+}
+
+func (ui *UiLib) ConnectToPeer(nodeURL string) {
+ if err := ui.eth.SuggestPeer(nodeURL); err != nil {
+ guilogger.Infoln("SuggestPeer error: " + err.Error())
+ }
+}
+
+func (ui *UiLib) AssetPath(p string) string {
+ return path.Join(ui.assetPath, p)
+}
+
+func (self *UiLib) Transact(params map[string]interface{}) (string, error) {
+ object := mapToTxParams(params)
+
+ return self.XEth.Transact(
+ object["from"],
+ object["to"],
+ object["value"],
+ object["gas"],
+ object["gasPrice"],
+ object["data"],
+ )
+}
+
+func (self *UiLib) Call(params map[string]interface{}) (string, error) {
+ object := mapToTxParams(params)
+
+ return self.XEth.Call(
+ object["from"],
+ object["to"],
+ object["value"],
+ object["gas"],
+ object["gasPrice"],
+ object["data"],
+ )
+}
+
+func (self *UiLib) AddLocalTransaction(to, data, gas, gasPrice, value string) int {
+ return 0
+ /*
+ return self.miner.AddLocalTx(&miner.LocalTx{
+ To: common.Hex2Bytes(to),
+ Data: common.Hex2Bytes(data),
+ Gas: gas,
+ GasPrice: gasPrice,
+ Value: value,
+ }) - 1
+ */
+}
+
+func (self *UiLib) RemoveLocalTransaction(id int) {
+ //self.miner.RemoveLocalTx(id)
+}
+
+func (self *UiLib) ToggleMining() bool {
+ if !self.eth.IsMining() {
+ err := self.eth.StartMining()
+ return err == nil
+ } else {
+ self.eth.StopMining()
+ return false
+ }
+}
+
+func (self *UiLib) ToHex(data string) string {
+ return "0x" + common.Bytes2Hex([]byte(data))
+}
+
+func (self *UiLib) ToAscii(data string) string {
+ start := 0
+ if len(data) > 1 && data[0:2] == "0x" {
+ start = 2
+ }
+ return string(common.Hex2Bytes(data[start:]))
+}
+
+/// Ethereum filter methods
+func (self *UiLib) NewFilter(object map[string]interface{}, view *qml.Common) (id int) {
+ /* TODO remove me
+ filter := qt.NewFilterFromMap(object, self.eth)
+ filter.MessageCallback = func(messages state.Messages) {
+ view.Call("messages", xeth.ToMessages(messages), id)
+ }
+ id = self.filterManager.InstallFilter(filter)
+ return id
+ */
+ return 0
+}
+
+func (self *UiLib) NewFilterString(typ string, view *qml.Common) (id int) {
+ /* TODO remove me
+ filter := core.NewFilter(self.eth)
+ filter.BlockCallback = func(block *types.Block) {
+ view.Call("messages", "{}", id)
+ }
+ id = self.filterManager.InstallFilter(filter)
+ return id
+ */
+ return 0
+}
+
+func (self *UiLib) Messages(id int) *common.List {
+ /* TODO remove me
+ filter := self.filterManager.GetFilter(id)
+ if filter != nil {
+ messages := xeth.ToMessages(filter.Find())
+
+ return messages
+ }
+ */
+
+ return common.EmptyList()
+}
+
+func (self *UiLib) ReadFile(p string) string {
+ content, err := ioutil.ReadFile(self.AssetPath(path.Join("ext", p)))
+ if err != nil {
+ guilogger.Infoln("error reading file", p, ":", err)
+ }
+ return string(content)
+}
+
+func (self *UiLib) UninstallFilter(id int) {
+ self.filterManager.UninstallFilter(id)
+}
+
+func mapToTxParams(object map[string]interface{}) map[string]string {
+ // Default values
+ if object["from"] == nil {
+ object["from"] = ""
+ }
+ if object["to"] == nil {
+ object["to"] = ""
+ }
+ if object["value"] == nil {
+ object["value"] = ""
+ }
+ if object["gas"] == nil {
+ object["gas"] = ""
+ }
+ if object["gasPrice"] == nil {
+ object["gasPrice"] = ""
+ }
+
+ var dataStr string
+ var data []string
+ if list, ok := object["data"].(*qml.List); ok {
+ list.Convert(&data)
+ } else if str, ok := object["data"].(string); ok {
+ data = []string{str}
+ }
+
+ for _, str := range data {
+ if common.IsHex(str) {
+ str = str[2:]
+
+ if len(str) != 64 {
+ str = common.LeftPadString(str, 64)
+ }
+ } else {
+ str = common.Bytes2Hex(common.LeftPadBytes(common.Big(str).Bytes(), 32))
+ }
+
+ dataStr += str
+ }
+ object["data"] = dataStr
+
+ conv := make(map[string]string)
+ for key, value := range object {
+ if v, ok := value.(string); ok {
+ conv[key] = v
+ }
+ }
+
+ return conv
+}
diff --git a/cmd/rlpdump/main.go b/cmd/rlpdump/main.go
new file mode 100644
index 000000000..8567dcff8
--- /dev/null
+++ b/cmd/rlpdump/main.go
@@ -0,0 +1,148 @@
+/*
+ This file is part of go-ethereum
+
+ go-ethereum is free software: you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation, either version 3 of the License, or
+ (at your option) any later version.
+
+ go-ethereum is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with go-ethereum. If not, see <http://www.gnu.org/licenses/>.
+*/
+/**
+ * @authors
+ * Felix Lange <felix@ethdev.com>
+ */
+
+// rlpdump is a pretty-printer for RLP data.
+package main
+
+import (
+ "bytes"
+ "encoding/hex"
+ "flag"
+ "fmt"
+ "io"
+ "os"
+ "strings"
+
+ "github.com/ethereum/go-ethereum/rlp"
+)
+
+var (
+ hexMode = flag.String("hex", "", "dump given hex data")
+ noASCII = flag.Bool("noascii", false, "don't print ASCII strings readably")
+)
+
+func init() {
+ flag.Usage = func() {
+ fmt.Fprintln(os.Stderr, "Usage:", os.Args[0], "[-noascii] [-hex <data>] [filename]")
+ flag.PrintDefaults()
+ fmt.Fprintln(os.Stderr, `
+Dumps RLP data from the given file in readable form.
+If the filename is omitted, data is read from stdin.`)
+ }
+}
+
+func main() {
+ flag.Parse()
+
+ var r io.Reader
+ switch {
+ case *hexMode != "":
+ data, err := hex.DecodeString(*hexMode)
+ if err != nil {
+ die(err)
+ }
+ r = bytes.NewReader(data)
+
+ case flag.NArg() == 0:
+ r = os.Stdin
+
+ case flag.NArg() == 1:
+ fd, err := os.Open(flag.Arg(0))
+ if err != nil {
+ die(err)
+ }
+ defer fd.Close()
+ r = fd
+
+ default:
+ fmt.Fprintln(os.Stderr, "Error: too many arguments")
+ flag.Usage()
+ os.Exit(2)
+ }
+
+ s := rlp.NewStream(r)
+ for {
+ if err := dump(s, 0); err != nil {
+ if err != io.EOF {
+ die(err)
+ }
+ break
+ }
+ fmt.Println()
+ }
+}
+
+func dump(s *rlp.Stream, depth int) error {
+ kind, size, err := s.Kind()
+ if err != nil {
+ return err
+ }
+ switch kind {
+ case rlp.Byte, rlp.String:
+ str, err := s.Bytes()
+ if err != nil {
+ return err
+ }
+ if len(str) == 0 || !*noASCII && isASCII(str) {
+ fmt.Printf("%s%q", ws(depth), str)
+ } else {
+ fmt.Printf("%s%x", ws(depth), str)
+ }
+ case rlp.List:
+ s.List()
+ defer s.ListEnd()
+ if size == 0 {
+ fmt.Print(ws(depth) + "[]")
+ } else {
+ fmt.Println(ws(depth) + "[")
+ for i := 0; ; i++ {
+ if i > 0 {
+ fmt.Print(",\n")
+ }
+ if err := dump(s, depth+1); err == rlp.EOL {
+ break
+ } else if err != nil {
+ return err
+ }
+ }
+ fmt.Print(ws(depth) + "]")
+ }
+ }
+ return nil
+}
+
+func isASCII(b []byte) bool {
+ for _, c := range b {
+ if c < 32 || c > 126 {
+ return false
+ }
+ }
+ return true
+}
+
+func ws(n int) string {
+ return strings.Repeat(" ", n)
+}
+
+func die(args ...interface{}) {
+ fmt.Fprintln(os.Stderr, args...)
+ os.Exit(1)
+}
diff --git a/cmd/utils/cmd.go b/cmd/utils/cmd.go
new file mode 100644
index 000000000..feea29d64
--- /dev/null
+++ b/cmd/utils/cmd.go
@@ -0,0 +1,186 @@
+/*
+ This file is part of go-ethereum
+
+ go-ethereum is free software: you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation, either version 3 of the License, or
+ (at your option) any later version.
+
+ go-ethereum is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with go-ethereum. If not, see <http://www.gnu.org/licenses/>.
+*/
+/**
+ * @authors
+ * Jeffrey Wilcke <i@jev.io>
+ * Viktor Tron <viktor@ethdev.com>
+ */
+package utils
+
+import (
+ "fmt"
+ "io"
+ "os"
+ "os/signal"
+ "regexp"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/core"
+ "github.com/ethereum/go-ethereum/core/types"
+ "github.com/ethereum/go-ethereum/eth"
+ "github.com/ethereum/go-ethereum/logger"
+ "github.com/ethereum/go-ethereum/rlp"
+)
+
+var clilogger = logger.NewLogger("CLI")
+var interruptCallbacks = []func(os.Signal){}
+
+// Register interrupt handlers callbacks
+func RegisterInterrupt(cb func(os.Signal)) {
+ interruptCallbacks = append(interruptCallbacks, cb)
+}
+
+// go routine that call interrupt handlers in order of registering
+func HandleInterrupt() {
+ c := make(chan os.Signal, 1)
+ go func() {
+ signal.Notify(c, os.Interrupt)
+ for sig := range c {
+ clilogger.Errorf("Shutting down (%v) ... \n", sig)
+ RunInterruptCallbacks(sig)
+ }
+ }()
+}
+
+func RunInterruptCallbacks(sig os.Signal) {
+ for _, cb := range interruptCallbacks {
+ cb(sig)
+ }
+}
+
+func openLogFile(Datadir string, filename string) *os.File {
+ path := common.AbsolutePath(Datadir, filename)
+ file, err := os.OpenFile(path, os.O_RDWR|os.O_CREATE|os.O_APPEND, 0666)
+ if err != nil {
+ panic(fmt.Sprintf("error opening log file '%s': %v", filename, err))
+ }
+ return file
+}
+
+func confirm(message string) bool {
+ fmt.Println(message, "Are you sure? (y/n)")
+ var r string
+ fmt.Scanln(&r)
+ for ; ; fmt.Scanln(&r) {
+ if r == "n" || r == "y" {
+ break
+ } else {
+ fmt.Printf("Yes or no? (%s)", r)
+ }
+ }
+ return r == "y"
+}
+
+func initDataDir(Datadir string) {
+ _, err := os.Stat(Datadir)
+ if err != nil {
+ if os.IsNotExist(err) {
+ fmt.Printf("Data directory '%s' doesn't exist, creating it\n", Datadir)
+ os.Mkdir(Datadir, 0777)
+ }
+ }
+}
+
+func exit(err error) {
+ status := 0
+ if err != nil {
+ fmt.Fprintln(os.Stderr, "Fatal:", err)
+ status = 1
+ }
+ logger.Flush()
+ os.Exit(status)
+}
+
+// Fatalf formats a message to standard output and exits the program.
+func Fatalf(format string, args ...interface{}) {
+ fmt.Fprintf(os.Stderr, "Fatal: "+format+"\n", args...)
+ logger.Flush()
+ os.Exit(1)
+}
+
+func StartEthereum(ethereum *eth.Ethereum) {
+ clilogger.Infoln("Starting ", ethereum.Name())
+ if err := ethereum.Start(); err != nil {
+ exit(err)
+ }
+ RegisterInterrupt(func(sig os.Signal) {
+ ethereum.Stop()
+ logger.Flush()
+ })
+}
+
+func StartEthereumForTest(ethereum *eth.Ethereum) {
+ clilogger.Infoln("Starting ", ethereum.Name())
+ ethereum.StartForTest()
+ RegisterInterrupt(func(sig os.Signal) {
+ ethereum.Stop()
+ logger.Flush()
+ })
+}
+
+func FormatTransactionData(data string) []byte {
+ d := common.StringToByteFunc(data, func(s string) (ret []byte) {
+ slice := regexp.MustCompile("\\n|\\s").Split(s, 1000000000)
+ for _, dataItem := range slice {
+ d := common.FormatData(dataItem)
+ ret = append(ret, d...)
+ }
+ return
+ })
+
+ return d
+}
+
+func ImportChain(chainmgr *core.ChainManager, fn string) error {
+ fmt.Printf("importing blockchain '%s'\n", fn)
+ fh, err := os.OpenFile(fn, os.O_RDONLY, os.ModePerm)
+ if err != nil {
+ return err
+ }
+ defer fh.Close()
+
+ chainmgr.Reset()
+ stream := rlp.NewStream(fh)
+ var i int
+ for ; ; i++ {
+ var b types.Block
+ if err := stream.Decode(&b); err == io.EOF {
+ break
+ } else if err != nil {
+ return fmt.Errorf("at block %d: %v", i, err)
+ }
+ if err := chainmgr.InsertChain(types.Blocks{&b}); err != nil {
+ return fmt.Errorf("invalid block %d: %v", i, err)
+ }
+ }
+ fmt.Printf("imported %d blocks\n", i)
+ return nil
+}
+
+func ExportChain(chainmgr *core.ChainManager, fn string) error {
+ fmt.Printf("exporting blockchain '%s'\n", fn)
+ fh, err := os.OpenFile(fn, os.O_CREATE|os.O_WRONLY|os.O_TRUNC, os.ModePerm)
+ if err != nil {
+ return err
+ }
+ defer fh.Close()
+ if err := chainmgr.Export(fh); err != nil {
+ return err
+ }
+ fmt.Printf("exported blockchain\n")
+ return nil
+}
diff --git a/cmd/utils/flags.go b/cmd/utils/flags.go
new file mode 100644
index 000000000..e82fd9c28
--- /dev/null
+++ b/cmd/utils/flags.go
@@ -0,0 +1,267 @@
+package utils
+
+import (
+ "crypto/ecdsa"
+ "os"
+ "path"
+ "runtime"
+
+ "github.com/codegangsta/cli"
+ "github.com/ethereum/go-ethereum/accounts"
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/core"
+ "github.com/ethereum/go-ethereum/crypto"
+ "github.com/ethereum/go-ethereum/eth"
+ "github.com/ethereum/go-ethereum/ethdb"
+ "github.com/ethereum/go-ethereum/event"
+ "github.com/ethereum/go-ethereum/logger"
+ "github.com/ethereum/go-ethereum/p2p/nat"
+ "github.com/ethereum/go-ethereum/rpc"
+ "github.com/ethereum/go-ethereum/xeth"
+)
+
+func init() {
+ cli.AppHelpTemplate = `{{.Name}} {{if .Flags}}[global options] {{end}}command{{if .Flags}} [command options]{{end}} [arguments...]
+
+VERSION:
+ {{.Version}}
+
+COMMANDS:
+ {{range .Commands}}{{.Name}}{{with .ShortName}}, {{.}}{{end}}{{ "\t" }}{{.Usage}}
+ {{end}}{{if .Flags}}
+GLOBAL OPTIONS:
+ {{range .Flags}}{{.}}
+ {{end}}{{end}}
+`
+
+ cli.CommandHelpTemplate = `{{.Name}}{{if .Subcommands}} command{{end}}{{if .Flags}} [command options]{{end}} [arguments...]
+{{if .Description}}{{.Description}}
+{{end}}{{if .Subcommands}}
+SUBCOMMANDS:
+ {{range .Subcommands}}{{.Name}}{{with .ShortName}}, {{.}}{{end}}{{ "\t" }}{{.Usage}}
+ {{end}}{{end}}{{if .Flags}}
+OPTIONS:
+ {{range .Flags}}{{.}}
+ {{end}}{{end}}
+`
+}
+
+// NewApp creates an app with sane defaults.
+func NewApp(version, usage string) *cli.App {
+ app := cli.NewApp()
+ app.Name = path.Base(os.Args[0])
+ app.Author = ""
+ //app.Authors = nil
+ app.Email = ""
+ app.Version = version
+ app.Usage = usage
+ return app
+}
+
+// These are all the command line flags we support.
+// If you add to this list, please remember to include the
+// flag in the appropriate command definition.
+//
+// The flags are defined here so their names and help texts
+// are the same for all commands.
+
+var (
+ // General settings
+ DataDirFlag = cli.StringFlag{
+ Name: "datadir",
+ Usage: "Data directory to be used",
+ Value: common.DefaultDataDir(),
+ }
+ ProtocolVersionFlag = cli.IntFlag{
+ Name: "protocolversion",
+ Usage: "ETH protocol version",
+ Value: eth.ProtocolVersion,
+ }
+ NetworkIdFlag = cli.IntFlag{
+ Name: "networkid",
+ Usage: "Network Id",
+ Value: eth.NetworkId,
+ }
+
+ // miner settings
+ MinerThreadsFlag = cli.IntFlag{
+ Name: "minerthreads",
+ Usage: "Number of miner threads",
+ Value: runtime.NumCPU(),
+ }
+ MiningEnabledFlag = cli.BoolFlag{
+ Name: "mine",
+ Usage: "Enable mining",
+ }
+ EtherbaseFlag = cli.StringFlag{
+ Name: "etherbase",
+ Usage: "public address for block mining rewards. By default the address of your primary account is used",
+ Value: "primary",
+ }
+
+ UnlockedAccountFlag = cli.StringFlag{
+ Name: "unlock",
+ Usage: "unlock the account given until this program exits (prompts for password). '--unlock primary' unlocks the primary account",
+ Value: "",
+ }
+ PasswordFileFlag = cli.StringFlag{
+ Name: "password",
+ Usage: "Path to password file for (un)locking an existing account.",
+ Value: "",
+ }
+
+ // logging and debug settings
+ LogFileFlag = cli.StringFlag{
+ Name: "logfile",
+ Usage: "Send log output to a file",
+ }
+ LogLevelFlag = cli.IntFlag{
+ Name: "loglevel",
+ Usage: "0-5 (silent, error, warn, info, debug, debug detail)",
+ Value: int(logger.InfoLevel),
+ }
+ LogJSONFlag = cli.StringFlag{
+ Name: "logjson",
+ Usage: "Send json structured log output to a file or '-' for standard output (default: no json output)",
+ Value: "",
+ }
+ VMDebugFlag = cli.BoolFlag{
+ Name: "vmdebug",
+ Usage: "Virtual Machine debug output",
+ }
+
+ // RPC settings
+ RPCEnabledFlag = cli.BoolFlag{
+ Name: "rpc",
+ Usage: "Whether RPC server is enabled",
+ }
+ RPCListenAddrFlag = cli.StringFlag{
+ Name: "rpcaddr",
+ Usage: "Listening address for the JSON-RPC server",
+ Value: "127.0.0.1",
+ }
+ RPCPortFlag = cli.IntFlag{
+ Name: "rpcport",
+ Usage: "Port on which the JSON-RPC server should listen",
+ Value: 8545,
+ }
+ RPCCORSDomainFlag = cli.StringFlag{
+ Name: "rpccorsdomain",
+ Usage: "Domain on which to send Access-Control-Allow-Origin header",
+ Value: "",
+ }
+ // Network Settings
+ MaxPeersFlag = cli.IntFlag{
+ Name: "maxpeers",
+ Usage: "Maximum number of network peers",
+ Value: 16,
+ }
+ ListenPortFlag = cli.IntFlag{
+ Name: "port",
+ Usage: "Network listening port",
+ Value: 30303,
+ }
+ BootnodesFlag = cli.StringFlag{
+ Name: "bootnodes",
+ Usage: "Space-separated enode URLs for discovery bootstrap",
+ Value: "",
+ }
+ NodeKeyFileFlag = cli.StringFlag{
+ Name: "nodekey",
+ Usage: "P2P node key file",
+ }
+ NodeKeyHexFlag = cli.StringFlag{
+ Name: "nodekeyhex",
+ Usage: "P2P node key as hex (for testing)",
+ }
+ NATFlag = cli.StringFlag{
+ Name: "nat",
+ Usage: "Port mapping mechanism (any|none|upnp|pmp|extip:<IP>)",
+ Value: "any",
+ }
+ JSpathFlag = cli.StringFlag{
+ Name: "jspath",
+ Usage: "JS library path to be used with console and js subcommands",
+ Value: ".",
+ }
+)
+
+func GetNAT(ctx *cli.Context) nat.Interface {
+ natif, err := nat.Parse(ctx.GlobalString(NATFlag.Name))
+ if err != nil {
+ Fatalf("Option %s: %v", NATFlag.Name, err)
+ }
+ return natif
+}
+
+func GetNodeKey(ctx *cli.Context) (key *ecdsa.PrivateKey) {
+ hex, file := ctx.GlobalString(NodeKeyHexFlag.Name), ctx.GlobalString(NodeKeyFileFlag.Name)
+ var err error
+ switch {
+ case file != "" && hex != "":
+ Fatalf("Options %q and %q are mutually exclusive", NodeKeyFileFlag.Name, NodeKeyHexFlag.Name)
+ case file != "":
+ if key, err = crypto.LoadECDSA(file); err != nil {
+ Fatalf("Option %q: %v", NodeKeyFileFlag.Name, err)
+ }
+ case hex != "":
+ if key, err = crypto.HexToECDSA(hex); err != nil {
+ Fatalf("Option %q: %v", NodeKeyHexFlag.Name, err)
+ }
+ }
+ return key
+}
+
+func MakeEthConfig(clientID, version string, ctx *cli.Context) *eth.Config {
+ return &eth.Config{
+ Name: common.MakeName(clientID, version),
+ DataDir: ctx.GlobalString(DataDirFlag.Name),
+ ProtocolVersion: ctx.GlobalInt(ProtocolVersionFlag.Name),
+ NetworkId: ctx.GlobalInt(NetworkIdFlag.Name),
+ LogFile: ctx.GlobalString(LogFileFlag.Name),
+ LogLevel: ctx.GlobalInt(LogLevelFlag.Name),
+ LogJSON: ctx.GlobalString(LogJSONFlag.Name),
+ Etherbase: ctx.GlobalString(EtherbaseFlag.Name),
+ MinerThreads: ctx.GlobalInt(MinerThreadsFlag.Name),
+ AccountManager: GetAccountManager(ctx),
+ VmDebug: ctx.GlobalBool(VMDebugFlag.Name),
+ MaxPeers: ctx.GlobalInt(MaxPeersFlag.Name),
+ Port: ctx.GlobalString(ListenPortFlag.Name),
+ NAT: GetNAT(ctx),
+ NodeKey: GetNodeKey(ctx),
+ Shh: true,
+ Dial: true,
+ BootNodes: ctx.GlobalString(BootnodesFlag.Name),
+ }
+}
+
+func GetChain(ctx *cli.Context) (*core.ChainManager, common.Database, common.Database) {
+ dataDir := ctx.GlobalString(DataDirFlag.Name)
+ blockDb, err := ethdb.NewLDBDatabase(path.Join(dataDir, "blockchain"))
+ if err != nil {
+ Fatalf("Could not open database: %v", err)
+ }
+
+ stateDb, err := ethdb.NewLDBDatabase(path.Join(dataDir, "state"))
+ if err != nil {
+ Fatalf("Could not open database: %v", err)
+ }
+ return core.NewChainManager(blockDb, stateDb, new(event.TypeMux)), blockDb, stateDb
+}
+
+func GetAccountManager(ctx *cli.Context) *accounts.Manager {
+ dataDir := ctx.GlobalString(DataDirFlag.Name)
+ ks := crypto.NewKeyStorePassphrase(path.Join(dataDir, "keys"))
+ return accounts.NewManager(ks)
+}
+
+func StartRPC(eth *eth.Ethereum, ctx *cli.Context) {
+ config := rpc.RpcConfig{
+ ListenAddress: ctx.GlobalString(RPCListenAddrFlag.Name),
+ ListenPort: uint(ctx.GlobalInt(RPCPortFlag.Name)),
+ CorsDomain: ctx.GlobalString(RPCCORSDomainFlag.Name),
+ }
+
+ xeth := xeth.New(eth, nil)
+ _ = rpc.Start(xeth, config)
+}
diff --git a/common/.gitignore b/common/.gitignore
new file mode 100644
index 000000000..f725d58d1
--- /dev/null
+++ b/common/.gitignore
@@ -0,0 +1,12 @@
+# See http://help.github.com/ignore-files/ for more about ignoring files.
+#
+# If you find yourself ignoring temporary files generated by your text editor
+# or operating system, you probably want to add a global ignore instead:
+# git config --global core.excludesfile ~/.gitignore_global
+
+/tmp
+*/**/*un~
+*un~
+.DS_Store
+*/**/.DS_Store
+
diff --git a/common/.travis.yml b/common/.travis.yml
new file mode 100644
index 000000000..69359072d
--- /dev/null
+++ b/common/.travis.yml
@@ -0,0 +1,3 @@
+language: go
+go:
+ - 1.2
diff --git a/common/README.md b/common/README.md
new file mode 100644
index 000000000..1ed56b71b
--- /dev/null
+++ b/common/README.md
@@ -0,0 +1,139 @@
+# ethutil
+
+[![Build
+Status](https://travis-ci.org/ethereum/go-ethereum.png?branch=master)](https://travis-ci.org/ethereum/go-ethereum)
+
+The ethutil package contains the ethereum utility library.
+
+# Installation
+
+`go get github.com/ethereum/ethutil-go`
+
+# Usage
+
+## RLP (Recursive Linear Prefix) Encoding
+
+RLP Encoding is an encoding scheme utilized by the Ethereum project. It
+encodes any native value or list to string.
+
+More in depth information about the Encoding scheme see the [Wiki](http://wiki.ethereum.org/index.php/RLP)
+article.
+
+```go
+rlp := ethutil.Encode("doge")
+fmt.Printf("%q\n", rlp) // => "\0x83dog"
+
+rlp = ethutil.Encode([]interface{}{"dog", "cat"})
+fmt.Printf("%q\n", rlp) // => "\0xc8\0x83dog\0x83cat"
+decoded := ethutil.Decode(rlp)
+fmt.Println(decoded) // => ["dog" "cat"]
+```
+
+## Patricia Trie
+
+Patricie Tree is a merkle trie utilized by the Ethereum project.
+
+More in depth information about the (modified) Patricia Trie can be
+found on the [Wiki](http://wiki.ethereum.org/index.php/Patricia_Tree).
+
+The patricia trie uses a db as backend and could be anything as long as
+it satisfies the Database interface found in `ethutil/db.go`.
+
+```go
+db := NewDatabase()
+
+// db, root
+trie := ethutil.NewTrie(db, "")
+
+trie.Put("puppy", "dog")
+trie.Put("horse", "stallion")
+trie.Put("do", "verb")
+trie.Put("doge", "coin")
+
+// Look up the key "do" in the trie
+out := trie.Get("do")
+fmt.Println(out) // => verb
+
+trie.Delete("puppy")
+```
+
+The patricia trie, in combination with RLP, provides a robust,
+cryptographically authenticated data structure that can be used to store
+all (key, value) bindings.
+
+```go
+// ... Create db/trie
+
+// Note that RLP uses interface slices as list
+value := ethutil.Encode([]interface{}{"one", 2, "three", []interface{}{42}})
+// Store the RLP encoded value of the list
+trie.Put("mykey", value)
+```
+
+## Value
+
+Value is a Generic Value which is used in combination with RLP data or
+`([])interface{}` structures. It may serve as a bridge between RLP data
+and actual real values and takes care of all the type checking and
+casting. Unlike Go's `reflect.Value` it does not panic if it's unable to
+cast to the requested value. It simple returns the base value of that
+type (e.g. `Slice()` returns []interface{}, `Uint()` return 0, etc).
+
+### Creating a new Value
+
+`NewEmptyValue()` returns a new \*Value with it's initial value set to a
+`[]interface{}`
+
+`AppendList()` appends a list to the current value.
+
+`Append(v)` appends the value (v) to the current value/list.
+
+```go
+val := ethutil.NewEmptyValue().Append(1).Append("2")
+val.AppendList().Append(3)
+```
+
+### Retrieving values
+
+`Get(i)` returns the `i` item in the list.
+
+`Uint()` returns the value as an unsigned int64.
+
+`Slice()` returns the value as a interface slice.
+
+`Str()` returns the value as a string.
+
+`Bytes()` returns the value as a byte slice.
+
+`Len()` assumes current to be a slice and returns its length.
+
+`Byte()` returns the value as a single byte.
+
+```go
+val := ethutil.NewValue([]interface{}{1,"2",[]interface{}{3}})
+val.Get(0).Uint() // => 1
+val.Get(1).Str() // => "2"
+s := val.Get(2) // => Value([]interface{}{3})
+s.Get(0).Uint() // => 3
+```
+
+## Decoding
+
+Decoding streams of RLP data is simplified
+
+```go
+val := ethutil.NewValueFromBytes(rlpData)
+val.Get(0).Uint()
+```
+
+## Encoding
+
+Encoding from Value to RLP is done with the `Encode` method. The
+underlying value can be anything RLP can encode (int, str, lists, bytes)
+
+```go
+val := ethutil.NewValue([]interface{}{1,"2",[]interface{}{3}})
+rlp := val.Encode()
+// Store the rlp data
+Store(rlp)
+```
diff --git a/common/big.go b/common/big.go
new file mode 100644
index 000000000..e8057acf6
--- /dev/null
+++ b/common/big.go
@@ -0,0 +1,136 @@
+package common
+
+import "math/big"
+
+// Common big integers often used
+var (
+ Big1 = big.NewInt(1)
+ Big2 = big.NewInt(2)
+ Big3 = big.NewInt(3)
+ Big0 = big.NewInt(0)
+ BigTrue = Big1
+ BigFalse = Big0
+ Big32 = big.NewInt(32)
+ Big256 = big.NewInt(0xff)
+ Big257 = big.NewInt(257)
+)
+
+// Big pow
+//
+// Returns the power of two big integers
+func BigPow(a, b int) *big.Int {
+ c := new(big.Int)
+ c.Exp(big.NewInt(int64(a)), big.NewInt(int64(b)), big.NewInt(0))
+
+ return c
+}
+
+// Big
+//
+// Shortcut for new(big.Int).SetString(..., 0)
+func Big(num string) *big.Int {
+ n := new(big.Int)
+ n.SetString(num, 0)
+
+ return n
+}
+
+// BigD
+//
+// Shortcut for new(big.Int).SetBytes(...)
+func Bytes2Big(data []byte) *big.Int {
+ n := new(big.Int)
+ n.SetBytes(data)
+
+ return n
+}
+func BigD(data []byte) *big.Int { return Bytes2Big(data) }
+
+func String2Big(num string) *big.Int {
+ n := new(big.Int)
+ n.SetString(num, 0)
+ return n
+}
+
+func BitTest(num *big.Int, i int) bool {
+ return num.Bit(i) > 0
+}
+
+// To256
+//
+// "cast" the big int to a 256 big int (i.e., limit to)
+var tt256 = new(big.Int).Lsh(big.NewInt(1), 256)
+var tt256m1 = new(big.Int).Sub(new(big.Int).Lsh(big.NewInt(1), 256), big.NewInt(1))
+var tt255 = new(big.Int).Lsh(big.NewInt(1), 255)
+
+func U256(x *big.Int) *big.Int {
+ //if x.Cmp(Big0) < 0 {
+ // return new(big.Int).Add(tt256, x)
+ // }
+
+ x.And(x, tt256m1)
+
+ return x
+}
+
+func S256(x *big.Int) *big.Int {
+ if x.Cmp(tt255) < 0 {
+ return x
+ } else {
+ // We don't want to modify x, ever
+ return new(big.Int).Sub(x, tt256)
+ }
+}
+
+func FirstBitSet(v *big.Int) int {
+ for i := 0; i < v.BitLen(); i++ {
+ if v.Bit(i) > 0 {
+ return i
+ }
+ }
+
+ return v.BitLen()
+}
+
+// Big to bytes
+//
+// Returns the bytes of a big integer with the size specified by **base**
+// Attempts to pad the byte array with zeros.
+func BigToBytes(num *big.Int, base int) []byte {
+ ret := make([]byte, base/8)
+
+ if len(num.Bytes()) > base/8 {
+ return num.Bytes()
+ }
+
+ return append(ret[:len(ret)-len(num.Bytes())], num.Bytes()...)
+}
+
+// Big copy
+//
+// Creates a copy of the given big integer
+func BigCopy(src *big.Int) *big.Int {
+ return new(big.Int).Set(src)
+}
+
+// Big max
+//
+// Returns the maximum size big integer
+func BigMax(x, y *big.Int) *big.Int {
+ if x.Cmp(y) < 0 {
+ return y
+ }
+
+ return x
+}
+
+// Big min
+//
+// Returns the minimum size big integer
+func BigMin(x, y *big.Int) *big.Int {
+ if x.Cmp(y) > 0 {
+ return y
+ }
+
+ return x
+}
diff --git a/common/big_test.go b/common/big_test.go
new file mode 100644
index 000000000..cedbaf144
--- /dev/null
+++ b/common/big_test.go
@@ -0,0 +1,73 @@
+package common
+
+import (
+ "bytes"
+ "testing"
+)
+
+func TestMisc(t *testing.T) {
+ a := Big("10")
+ b := Big("57896044618658097711785492504343953926634992332820282019728792003956564819968")
+ c := []byte{1, 2, 3, 4}
+ z := BitTest(a, 1)
+
+ if z != true {
+ t.Error("Expected true got", z)
+ }
+
+ U256(a)
+ S256(a)
+
+ U256(b)
+ S256(b)
+
+ BigD(c)
+}
+
+func TestBigMax(t *testing.T) {
+ a := Big("10")
+ b := Big("5")
+
+ max1 := BigMax(a, b)
+ if max1 != a {
+ t.Errorf("Expected %d got %d", a, max1)
+ }
+
+ max2 := BigMax(b, a)
+ if max2 != a {
+ t.Errorf("Expected %d got %d", a, max2)
+ }
+}
+
+func TestBigMin(t *testing.T) {
+ a := Big("10")
+ b := Big("5")
+
+ min1 := BigMin(a, b)
+ if min1 != b {
+ t.Errorf("Expected %d got %d", b, min1)
+ }
+
+ min2 := BigMin(b, a)
+ if min2 != b {
+ t.Errorf("Expected %d got %d", b, min2)
+ }
+}
+
+func TestBigCopy(t *testing.T) {
+ a := Big("10")
+ b := BigCopy(a)
+ c := Big("1000000000000")
+ y := BigToBytes(b, 16)
+ ybytes := []byte{0, 10}
+ z := BigToBytes(c, 16)
+ zbytes := []byte{232, 212, 165, 16, 0}
+
+ if bytes.Compare(y, ybytes) != 0 {
+ t.Error("Got", ybytes)
+ }
+
+ if bytes.Compare(z, zbytes) != 0 {
+ t.Error("Got", zbytes)
+ }
+}
diff --git a/common/bytes.go b/common/bytes.go
new file mode 100644
index 000000000..2d885ac74
--- /dev/null
+++ b/common/bytes.go
@@ -0,0 +1,256 @@
+package common
+
+import (
+ "bytes"
+ "encoding/binary"
+ "encoding/hex"
+ "fmt"
+ "math/big"
+ "strings"
+)
+
+func ToHex(b []byte) string {
+ hex := Bytes2Hex(b)
+ // Prefer output of "0x0" instead of "0x"
+ if len(hex) == 0 {
+ hex = "0"
+ }
+ return "0x" + hex
+}
+
+func FromHex(s string) []byte {
+ if len(s) > 1 {
+ if s[0:2] == "0x" {
+ s = s[2:]
+ }
+ if len(s)%2 == 1 {
+ s = "0" + s
+ }
+ return Hex2Bytes(s)
+ }
+ return nil
+}
+
+type Bytes []byte
+
+func (self Bytes) String() string {
+ return string(self)
+}
+
+func DeleteFromByteSlice(s [][]byte, hash []byte) [][]byte {
+ for i, h := range s {
+ if bytes.Compare(h, hash) == 0 {
+ return append(s[:i:i], s[i+1:]...)
+ }
+ }
+
+ return s
+}
+
+// Number to bytes
+//
+// Returns the number in bytes with the specified base
+func NumberToBytes(num interface{}, bits int) []byte {
+ buf := new(bytes.Buffer)
+ err := binary.Write(buf, binary.BigEndian, num)
+ if err != nil {
+ fmt.Println("NumberToBytes failed:", err)
+ }
+
+ return buf.Bytes()[buf.Len()-(bits/8):]
+}
+
+// Bytes to number
+//
+// Attempts to cast a byte slice to a unsigned integer
+func BytesToNumber(b []byte) uint64 {
+ var number uint64
+
+ // Make sure the buffer is 64bits
+ data := make([]byte, 8)
+ data = append(data[:len(b)], b...)
+
+ buf := bytes.NewReader(data)
+ err := binary.Read(buf, binary.BigEndian, &number)
+ if err != nil {
+ fmt.Println("BytesToNumber failed:", err)
+ }
+
+ return number
+}
+
+// Read variable int
+//
+// Read a variable length number in big endian byte order
+func ReadVarInt(buff []byte) (ret uint64) {
+ switch l := len(buff); {
+ case l > 4:
+ d := LeftPadBytes(buff, 8)
+ binary.Read(bytes.NewReader(d), binary.BigEndian, &ret)
+ case l > 2:
+ var num uint32
+ d := LeftPadBytes(buff, 4)
+ binary.Read(bytes.NewReader(d), binary.BigEndian, &num)
+ ret = uint64(num)
+ case l > 1:
+ var num uint16
+ d := LeftPadBytes(buff, 2)
+ binary.Read(bytes.NewReader(d), binary.BigEndian, &num)
+ ret = uint64(num)
+ default:
+ var num uint8
+ binary.Read(bytes.NewReader(buff), binary.BigEndian, &num)
+ ret = uint64(num)
+ }
+
+ return
+}
+
+// Binary length
+//
+// Returns the true binary length of the given number
+func BinaryLength(num int) int {
+ if num == 0 {
+ return 0
+ }
+
+ return 1 + BinaryLength(num>>8)
+}
+
+// Copy bytes
+//
+// Returns an exact copy of the provided bytes
+func CopyBytes(b []byte) (copiedBytes []byte) {
+ copiedBytes = make([]byte, len(b))
+ copy(copiedBytes, b)
+
+ return
+}
+
+func IsHex(str string) bool {
+ l := len(str)
+ return l >= 4 && l%2 == 0 && str[0:2] == "0x"
+}
+
+func Bytes2Hex(d []byte) string {
+ return hex.EncodeToString(d)
+}
+
+func Hex2Bytes(str string) []byte {
+ h, _ := hex.DecodeString(str)
+
+ return h
+}
+
+func StringToByteFunc(str string, cb func(str string) []byte) (ret []byte) {
+ if len(str) > 1 && str[0:2] == "0x" && !strings.Contains(str, "\n") {
+ ret = Hex2Bytes(str[2:])
+ } else {
+ ret = cb(str)
+ }
+
+ return
+}
+
+func FormatData(data string) []byte {
+ if len(data) == 0 {
+ return nil
+ }
+ // Simple stupid
+ d := new(big.Int)
+ if data[0:1] == "\"" && data[len(data)-1:] == "\"" {
+ return RightPadBytes([]byte(data[1:len(data)-1]), 32)
+ } else if len(data) > 1 && data[:2] == "0x" {
+ d.SetBytes(Hex2Bytes(data[2:]))
+ } else {
+ d.SetString(data, 0)
+ }
+
+ return BigToBytes(d, 256)
+}
+
+func ParseData(data ...interface{}) (ret []byte) {
+ for _, item := range data {
+ switch t := item.(type) {
+ case string:
+ var str []byte
+ if IsHex(t) {
+ str = Hex2Bytes(t[2:])
+ } else {
+ str = []byte(t)
+ }
+
+ ret = append(ret, RightPadBytes(str, 32)...)
+ case []byte:
+ ret = append(ret, LeftPadBytes(t, 32)...)
+ }
+ }
+
+ return
+}
+
+func RightPadBytes(slice []byte, l int) []byte {
+ if l < len(slice) {
+ return slice
+ }
+
+ padded := make([]byte, l)
+ copy(padded[0:len(slice)], slice)
+
+ return padded
+}
+
+func LeftPadBytes(slice []byte, l int) []byte {
+ if l < len(slice) {
+ return slice
+ }
+
+ padded := make([]byte, l)
+ copy(padded[l-len(slice):], slice)
+
+ return padded
+}
+
+func LeftPadString(str string, l int) string {
+ if l < len(str) {
+ return str
+ }
+
+ zeros := Bytes2Hex(make([]byte, (l-len(str))/2))
+
+ return zeros + str
+
+}
+
+func RightPadString(str string, l int) string {
+ if l < len(str) {
+ return str
+ }
+
+ zeros := Bytes2Hex(make([]byte, (l-len(str))/2))
+
+ return str + zeros
+
+}
+
+func ToAddress(slice []byte) (addr []byte) {
+ if len(slice) < 20 {
+ addr = LeftPadBytes(slice, 20)
+ } else if len(slice) > 20 {
+ addr = slice[len(slice)-20:]
+ } else {
+ addr = slice
+ }
+
+ addr = CopyBytes(addr)
+
+ return
+}
+
+func ByteSliceToInterface(slice [][]byte) (ret []interface{}) {
+ for _, i := range slice {
+ ret = append(ret, i)
+ }
+
+ return
+}
diff --git a/common/bytes_test.go b/common/bytes_test.go
new file mode 100644
index 000000000..4b00aa49b
--- /dev/null
+++ b/common/bytes_test.go
@@ -0,0 +1,214 @@
+package common
+
+import (
+ "bytes"
+ "testing"
+
+ checker "gopkg.in/check.v1"
+)
+
+type BytesSuite struct{}
+
+var _ = checker.Suite(&BytesSuite{})
+
+func (s *BytesSuite) TestByteString(c *checker.C) {
+ var data Bytes
+ data = []byte{102, 111, 111}
+ exp := "foo"
+ res := data.String()
+
+ c.Assert(res, checker.Equals, exp)
+}
+
+/*
+func (s *BytesSuite) TestDeleteFromByteSlice(c *checker.C) {
+ data := []byte{1, 2, 3, 4}
+ slice := []byte{1, 2, 3, 4}
+ exp := []byte{1, 4}
+ res := DeleteFromByteSlice(data, slice)
+
+ c.Assert(res, checker.DeepEquals, exp)
+}
+
+*/
+func (s *BytesSuite) TestNumberToBytes(c *checker.C) {
+ // data1 := int(1)
+ // res1 := NumberToBytes(data1, 16)
+ // c.Check(res1, checker.Panics)
+
+ var data2 float64 = 3.141592653
+ exp2 := []byte{0xe9, 0x38}
+ res2 := NumberToBytes(data2, 16)
+ c.Assert(res2, checker.DeepEquals, exp2)
+}
+
+func (s *BytesSuite) TestBytesToNumber(c *checker.C) {
+ datasmall := []byte{0xe9, 0x38, 0xe9, 0x38}
+ datalarge := []byte{0xe9, 0x38, 0xe9, 0x38, 0xe9, 0x38, 0xe9, 0x38}
+
+ var expsmall uint64 = 0xe938e938
+ var explarge uint64 = 0x0
+
+ ressmall := BytesToNumber(datasmall)
+ reslarge := BytesToNumber(datalarge)
+
+ c.Assert(ressmall, checker.Equals, expsmall)
+ c.Assert(reslarge, checker.Equals, explarge)
+
+}
+
+func (s *BytesSuite) TestReadVarInt(c *checker.C) {
+ data8 := []byte{1, 2, 3, 4, 5, 6, 7, 8}
+ data4 := []byte{1, 2, 3, 4}
+ data2 := []byte{1, 2}
+ data1 := []byte{1}
+
+ exp8 := uint64(72623859790382856)
+ exp4 := uint64(16909060)
+ exp2 := uint64(258)
+ exp1 := uint64(1)
+
+ res8 := ReadVarInt(data8)
+ res4 := ReadVarInt(data4)
+ res2 := ReadVarInt(data2)
+ res1 := ReadVarInt(data1)
+
+ c.Assert(res8, checker.Equals, exp8)
+ c.Assert(res4, checker.Equals, exp4)
+ c.Assert(res2, checker.Equals, exp2)
+ c.Assert(res1, checker.Equals, exp1)
+}
+
+func (s *BytesSuite) TestBinaryLength(c *checker.C) {
+ data1 := 0
+ data2 := 920987656789
+
+ exp1 := 0
+ exp2 := 5
+
+ res1 := BinaryLength(data1)
+ res2 := BinaryLength(data2)
+
+ c.Assert(res1, checker.Equals, exp1)
+ c.Assert(res2, checker.Equals, exp2)
+}
+
+func (s *BytesSuite) TestCopyBytes(c *checker.C) {
+ data1 := []byte{1, 2, 3, 4}
+ exp1 := []byte{1, 2, 3, 4}
+ res1 := CopyBytes(data1)
+ c.Assert(res1, checker.DeepEquals, exp1)
+}
+
+func (s *BytesSuite) TestIsHex(c *checker.C) {
+ data1 := "a9e67e"
+ exp1 := false
+ res1 := IsHex(data1)
+ c.Assert(res1, checker.DeepEquals, exp1)
+
+ data2 := "0xa9e67e00"
+ exp2 := true
+ res2 := IsHex(data2)
+ c.Assert(res2, checker.DeepEquals, exp2)
+
+}
+
+func (s *BytesSuite) TestParseDataString(c *checker.C) {
+ res1 := ParseData("hello", "world", "0x0106")
+ data := "68656c6c6f000000000000000000000000000000000000000000000000000000776f726c640000000000000000000000000000000000000000000000000000000106000000000000000000000000000000000000000000000000000000000000"
+ exp1 := Hex2Bytes(data)
+ c.Assert(res1, checker.DeepEquals, exp1)
+}
+
+func (s *BytesSuite) TestParseDataBytes(c *checker.C) {
+ data1 := []byte{232, 212, 165, 16, 0}
+ exp1 := []byte{0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 232, 212, 165, 16, 0}
+
+ res1 := ParseData(data1)
+ c.Assert(res1, checker.DeepEquals, exp1)
+
+}
+
+func (s *BytesSuite) TestLeftPadBytes(c *checker.C) {
+ val1 := []byte{1, 2, 3, 4}
+ exp1 := []byte{0, 0, 0, 0, 1, 2, 3, 4}
+
+ res1 := LeftPadBytes(val1, 8)
+ res2 := LeftPadBytes(val1, 2)
+
+ c.Assert(res1, checker.DeepEquals, exp1)
+ c.Assert(res2, checker.DeepEquals, val1)
+}
+
+func (s *BytesSuite) TestFormatData(c *checker.C) {
+ data1 := ""
+ data2 := "0xa9e67e00"
+ data3 := "a9e67e"
+ data4 := "\"a9e67e00\""
+
+ // exp1 := []byte{}
+ exp2 := []byte{00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 0xa9, 0xe6, 0x7e, 00}
+ exp3 := []byte{00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00}
+ exp4 := []byte{0x61, 0x39, 0x65, 0x36, 0x37, 0x65, 0x30, 0x30, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00, 00}
+
+ res1 := FormatData(data1)
+ res2 := FormatData(data2)
+ res3 := FormatData(data3)
+ res4 := FormatData(data4)
+
+ c.Assert(res1, checker.IsNil)
+ c.Assert(res2, checker.DeepEquals, exp2)
+ c.Assert(res3, checker.DeepEquals, exp3)
+ c.Assert(res4, checker.DeepEquals, exp4)
+}
+
+func (s *BytesSuite) TestRightPadBytes(c *checker.C) {
+ val := []byte{1, 2, 3, 4}
+ exp := []byte{1, 2, 3, 4, 0, 0, 0, 0}
+
+ resstd := RightPadBytes(val, 8)
+ resshrt := RightPadBytes(val, 2)
+
+ c.Assert(resstd, checker.DeepEquals, exp)
+ c.Assert(resshrt, checker.DeepEquals, val)
+}
+
+func (s *BytesSuite) TestLeftPadString(c *checker.C) {
+ val := "test"
+ exp := "\x30\x30\x30\x30" + val
+
+ resstd := LeftPadString(val, 8)
+ resshrt := LeftPadString(val, 2)
+
+ c.Assert(resstd, checker.Equals, exp)
+ c.Assert(resshrt, checker.Equals, val)
+}
+
+func (s *BytesSuite) TestRightPadString(c *checker.C) {
+ val := "test"
+ exp := val + "\x30\x30\x30\x30"
+
+ resstd := RightPadString(val, 8)
+ resshrt := RightPadString(val, 2)
+
+ c.Assert(resstd, checker.Equals, exp)
+ c.Assert(resshrt, checker.Equals, val)
+}
+
+func TestFromHex(t *testing.T) {
+ input := "0x01"
+ expected := []byte{1}
+ result := FromHex(input)
+ if bytes.Compare(expected, result) != 0 {
+ t.Errorf("Expected % x got % x", expected, result)
+ }
+}
+
+func TestFromHexOddLength(t *testing.T) {
+ input := "0x1"
+ expected := []byte{1}
+ result := FromHex(input)
+ if bytes.Compare(expected, result) != 0 {
+ t.Errorf("Expected % x got % x", expected, result)
+ }
+}
diff --git a/common/config.go b/common/config.go
new file mode 100644
index 000000000..23a902bc1
--- /dev/null
+++ b/common/config.go
@@ -0,0 +1,67 @@
+package common
+
+import (
+ "flag"
+ "fmt"
+ "os"
+
+ "github.com/rakyll/globalconf"
+)
+
+// Config struct
+type ConfigManager struct {
+ ExecPath string
+ Debug bool
+ Diff bool
+ DiffType string
+ Paranoia bool
+ VmType int
+
+ conf *globalconf.GlobalConf
+}
+
+// Read config
+//
+// Initialize Config from Config File
+func ReadConfig(ConfigFile string, Datadir string, EnvPrefix string) *ConfigManager {
+ if !FileExist(ConfigFile) {
+ // create ConfigFile if it does not exist, otherwise
+ // globalconf will panic when trying to persist flags.
+ fmt.Printf("config file '%s' doesn't exist, creating it\n", ConfigFile)
+ os.Create(ConfigFile)
+ }
+ g, err := globalconf.NewWithOptions(&globalconf.Options{
+ Filename: ConfigFile,
+ EnvPrefix: EnvPrefix,
+ })
+ if err != nil {
+ fmt.Println(err)
+ } else {
+ g.ParseAll()
+ }
+ cfg := &ConfigManager{ExecPath: Datadir, Debug: true, conf: g, Paranoia: true}
+ return cfg
+}
+
+// provides persistence for flags
+func (c *ConfigManager) Save(key string, value interface{}) {
+ f := &flag.Flag{Name: key, Value: newConfValue(value)}
+ c.conf.Set("", f)
+}
+
+func (c *ConfigManager) Delete(key string) {
+ c.conf.Delete("", key)
+}
+
+// private type implementing flag.Value
+type confValue struct {
+ value string
+}
+
+// generic constructor to allow persising non-string values directly
+func newConfValue(value interface{}) *confValue {
+ return &confValue{fmt.Sprintf("%v", value)}
+}
+
+func (self confValue) String() string { return self.value }
+func (self confValue) Set(s string) error { self.value = s; return nil }
diff --git a/common/db.go b/common/db.go
new file mode 100644
index 000000000..6505e61c6
--- /dev/null
+++ b/common/db.go
@@ -0,0 +1,12 @@
+package common
+
+// Database interface
+type Database interface {
+ Put(key []byte, value []byte)
+ Get(key []byte) ([]byte, error)
+ //GetKeys() []*Key
+ Delete(key []byte) error
+ LastKnownTD() []byte
+ Close()
+ Print()
+}
diff --git a/common/list.go b/common/list.go
new file mode 100644
index 000000000..594a8a24b
--- /dev/null
+++ b/common/list.go
@@ -0,0 +1,81 @@
+package common
+
+import (
+ "encoding/json"
+ "reflect"
+ "sync"
+)
+
+// The list type is an anonymous slice handler which can be used
+// for containing any slice type to use in an environment which
+// does not support slice types (e.g., JavaScript, QML)
+type List struct {
+ mut sync.Mutex
+ val interface{}
+ list reflect.Value
+ Length int
+}
+
+// Initialise a new list. Panics if non-slice type is given.
+func NewList(t interface{}) *List {
+ list := reflect.ValueOf(t)
+ if list.Kind() != reflect.Slice {
+ panic("list container initialized with a non-slice type")
+ }
+
+ return &List{sync.Mutex{}, t, list, list.Len()}
+}
+
+func EmptyList() *List {
+ return NewList([]interface{}{})
+}
+
+// Get N element from the embedded slice. Returns nil if OOB.
+func (self *List) Get(i int) interface{} {
+ if self.list.Len() > i {
+ self.mut.Lock()
+ defer self.mut.Unlock()
+
+ i := self.list.Index(i).Interface()
+
+ return i
+ }
+
+ return nil
+}
+
+func (self *List) GetAsJson(i int) interface{} {
+ e := self.Get(i)
+
+ r, _ := json.Marshal(e)
+
+ return string(r)
+}
+
+// Appends value at the end of the slice. Panics when incompatible value
+// is given.
+func (self *List) Append(v interface{}) {
+ self.mut.Lock()
+ defer self.mut.Unlock()
+
+ self.list = reflect.Append(self.list, reflect.ValueOf(v))
+ self.Length = self.list.Len()
+}
+
+// Returns the underlying slice as interface.
+func (self *List) Interface() interface{} {
+ return self.list.Interface()
+}
+
+// For JavaScript <3
+func (self *List) ToJSON() string {
+ // make(T, 0) != nil
+ list := make([]interface{}, 0)
+ for i := 0; i < self.Length; i++ {
+ list = append(list, self.Get(i))
+ }
+
+ data, _ := json.Marshal(list)
+
+ return string(data)
+}
diff --git a/common/main_test.go b/common/main_test.go
new file mode 100644
index 000000000..2bed278e6
--- /dev/null
+++ b/common/main_test.go
@@ -0,0 +1,9 @@
+package common
+
+import (
+ "testing"
+
+ checker "gopkg.in/check.v1"
+)
+
+func Test(t *testing.T) { checker.TestingT(t) }
diff --git a/common/math/dist.go b/common/math/dist.go
new file mode 100644
index 000000000..0a0731971
--- /dev/null
+++ b/common/math/dist.go
@@ -0,0 +1,80 @@
+package math
+
+import (
+ "math/big"
+ "sort"
+
+ "github.com/ethereum/go-ethereum/common"
+)
+
+type Summer interface {
+ Sum(i int) *big.Int
+ Len() int
+}
+
+func Sum(slice Summer) (sum *big.Int) {
+ sum = new(big.Int)
+
+ for i := 0; i < slice.Len(); i++ {
+ sum.Add(sum, slice.Sum(i))
+ }
+ return
+}
+
+type Vector struct {
+ Gas, Price *big.Int
+}
+
+type VectorsBy func(v1, v2 Vector) bool
+
+func (self VectorsBy) Sort(vectors []Vector) {
+ bs := vectorSorter{
+ vectors: vectors,
+ by: self,
+ }
+ sort.Sort(bs)
+}
+
+type vectorSorter struct {
+ vectors []Vector
+ by func(v1, v2 Vector) bool
+}
+
+func (v vectorSorter) Len() int { return len(v.vectors) }
+func (v vectorSorter) Less(i, j int) bool { return v.by(v.vectors[i], v.vectors[j]) }
+func (v vectorSorter) Swap(i, j int) { v.vectors[i], v.vectors[j] = v.vectors[j], v.vectors[i] }
+
+func PriceSort(v1, v2 Vector) bool { return v1.Price.Cmp(v2.Price) < 0 }
+func GasSort(v1, v2 Vector) bool { return v1.Gas.Cmp(v2.Gas) < 0 }
+
+type vectorSummer struct {
+ vectors []Vector
+ by func(v Vector) *big.Int
+}
+
+type VectorSum func(v Vector) *big.Int
+
+func (v VectorSum) Sum(vectors []Vector) *big.Int {
+ vs := vectorSummer{
+ vectors: vectors,
+ by: v,
+ }
+ return Sum(vs)
+}
+
+func (v vectorSummer) Len() int { return len(v.vectors) }
+func (v vectorSummer) Sum(i int) *big.Int { return v.by(v.vectors[i]) }
+
+func GasSum(v Vector) *big.Int { return v.Gas }
+
+var etherInWei = new(big.Rat).SetInt(common.String2Big("1000000000000000000"))
+
+func GasPrice(bp, gl, ep *big.Int) *big.Int {
+ BP := new(big.Rat).SetInt(bp)
+ GL := new(big.Rat).SetInt(gl)
+ EP := new(big.Rat).SetInt(ep)
+ GP := new(big.Rat).Quo(BP, GL)
+ GP = GP.Quo(GP, EP)
+
+ return GP.Mul(GP, etherInWei).Num()
+}
diff --git a/common/math/dist_test.go b/common/math/dist_test.go
new file mode 100644
index 000000000..90e302f44
--- /dev/null
+++ b/common/math/dist_test.go
@@ -0,0 +1,66 @@
+package math
+
+import (
+ "fmt"
+ "math/big"
+ "testing"
+)
+
+type summer struct {
+ numbers []*big.Int
+}
+
+func (s summer) Len() int { return len(s.numbers) }
+func (s summer) Sum(i int) *big.Int {
+ return s.numbers[i]
+}
+
+func TestSum(t *testing.T) {
+ summer := summer{numbers: []*big.Int{big.NewInt(1), big.NewInt(2), big.NewInt(3)}}
+ sum := Sum(summer)
+ if sum.Cmp(big.NewInt(6)) != 0 {
+ t.Errorf("not 6", sum)
+ }
+}
+
+func TestDist(t *testing.T) {
+ var vectors = []Vector{
+ Vector{big.NewInt(1000), big.NewInt(1234)},
+ Vector{big.NewInt(500), big.NewInt(10023)},
+ Vector{big.NewInt(1034), big.NewInt(1987)},
+ Vector{big.NewInt(1034), big.NewInt(1987)},
+ Vector{big.NewInt(8983), big.NewInt(1977)},
+ Vector{big.NewInt(98382), big.NewInt(1887)},
+ Vector{big.NewInt(12398), big.NewInt(1287)},
+ Vector{big.NewInt(12398), big.NewInt(1487)},
+ Vector{big.NewInt(12398), big.NewInt(1987)},
+ Vector{big.NewInt(12398), big.NewInt(128)},
+ Vector{big.NewInt(12398), big.NewInt(1987)},
+ Vector{big.NewInt(1398), big.NewInt(187)},
+ Vector{big.NewInt(12328), big.NewInt(1927)},
+ Vector{big.NewInt(12398), big.NewInt(1987)},
+ Vector{big.NewInt(22398), big.NewInt(1287)},
+ Vector{big.NewInt(1370), big.NewInt(1981)},
+ Vector{big.NewInt(12398), big.NewInt(1957)},
+ Vector{big.NewInt(42198), big.NewInt(1987)},
+ }
+
+ VectorsBy(GasSort).Sort(vectors)
+ fmt.Println(vectors)
+
+ BP := big.NewInt(15)
+ GL := big.NewInt(1000000)
+ EP := big.NewInt(100)
+ fmt.Println("BP", BP, "GL", GL, "EP", EP)
+ GP := GasPrice(BP, GL, EP)
+ fmt.Println("GP =", GP, "Wei per GU")
+
+ S := len(vectors) / 4
+ fmt.Println("L", len(vectors), "S", S)
+ for i := 1; i <= S*4; i += S {
+ fmt.Printf("T%d = %v\n", i, vectors[i])
+ }
+
+ g := VectorSum(GasSum).Sum(vectors)
+ fmt.Printf("G = ∑g* (%v)\n", g)
+}
diff --git a/common/natspec/natspec.go b/common/natspec/natspec.go
new file mode 100644
index 000000000..8e6568cef
--- /dev/null
+++ b/common/natspec/natspec.go
@@ -0,0 +1,63 @@
+package natspec
+
+import (
+ "fmt"
+ "github.com/robertkrimen/otto"
+)
+
+type NatSpec struct {
+ jsvm *otto.Otto
+}
+
+// TODO: should initialise with abi and userdoc jsons
+func New() (self *NatSpec, err error) {
+
+ self = new(NatSpec)
+ self.jsvm = otto.New()
+
+ _, err = self.jsvm.Run(natspecJS)
+ if err != nil {
+ return
+ }
+ _, err = self.jsvm.Run("var natspec = require('natspec');")
+ if err != nil {
+ return
+ }
+
+ return
+}
+
+func (self *NatSpec) Notice(transaction, abi, method, expression string) (string, error) {
+ var err error
+ if _, err = self.jsvm.Run("var transaction = " + transaction + ";"); err != nil {
+ return "", fmt.Errorf("natspec.js error setting transaction: %v", err)
+ }
+
+ if _, err = self.jsvm.Run("var abi = " + abi + ";"); err != nil {
+ return "", fmt.Errorf("natspec.js error setting abi: %v", err)
+ }
+
+ if _, err = self.jsvm.Run("var method = '" + method + "';"); err != nil {
+ return "", fmt.Errorf("natspec.js error setting method: %v", err)
+ }
+
+ if _, err = self.jsvm.Run("var expression = \"" + expression + "\";"); err != nil {
+ return "", fmt.Errorf("natspec.js error setting expression: %v", err)
+ }
+
+ self.jsvm.Run("var call = {method: method,abi: abi,transaction: transaction};")
+ value, err := self.jsvm.Run("natspec.evaluateExpression(expression, call);")
+ if err != nil {
+ return "", fmt.Errorf("natspec.js error evaluating expression: %v", err)
+ }
+ evalError := "Natspec evaluation failed, wrong input params"
+ if value.String() == evalError {
+ return "", fmt.Errorf("natspec.js error evaluating expression: wrong input params in expression '%s'", expression)
+ }
+ if len(value.String()) == 0 {
+ return "", fmt.Errorf("natspec.js error evaluating expression")
+ }
+
+ return value.String(), nil
+
+}
diff --git a/common/natspec/natspec_js.go b/common/natspec/natspec_js.go
new file mode 100644
index 000000000..96d8204fb
--- /dev/null
+++ b/common/natspec/natspec_js.go
@@ -0,0 +1,4 @@
+package natspec
+
+const natspecJS = `require=function t(e,n,r){function i(f,u){if(!n[f]){if(!e[f]){var s="function"==typeof require&&require;if(!u&&s)return s(f,!0);if(o)return o(f,!0);var c=new Error("Cannot find module '"+f+"'");throw c.code="MODULE_NOT_FOUND",c}var a=n[f]={exports:{}};e[f][0].call(a.exports,function(t){var n=e[f][1][t];return i(n?n:t)},a,a.exports,t,e,n,r)}return n[f].exports}for(var o="function"==typeof require&&require,f=0;f<r.length;f++)i(r[f]);return i}({1:[function(){},{}],2:[function(t,e){function n(){if(!f){f=!0;for(var t,e=o.length;e;){t=o,o=[];for(var n=-1;++n<e;)t[n]();e=o.length}f=!1}}function r(){}var i=e.exports={},o=[],f=!1;i.nextTick=function(t){o.push(t),f||setTimeout(n,0)},i.title="browser",i.browser=!0,i.env={},i.argv=[],i.version="",i.on=r,i.addListener=r,i.once=r,i.off=r,i.removeListener=r,i.removeAllListeners=r,i.emit=r,i.binding=function(){throw new Error("process.binding is not supported")},i.cwd=function(){return"/"},i.chdir=function(){throw new Error("process.chdir is not supported")},i.umask=function(){return 0}},{}],3:[function(t,e){var n=t("./utils"),r=t("./types"),i=t("./const"),o=t("./formatters"),f=function(t){console.error("parser does not support type: "+t)},u=function(t){return"[]"===t.slice(-2)},s=function(t,e){return u(t)||"string"===t?o.formatInputInt(e.length):""},c=r.inputTypes(),a=function(t,e){var n="",r="",i="";return t.forEach(function(t,r){n+=s(t.type,e[r])}),t.forEach(function(n,o){for(var s=!1,a=0;a<c.length&&!s;a++)s=c[a].type(t[o].type,e[o]);s||f(t[o].type);var l=c[a-1].format;u(t[o].type)?i+=e[o].reduce(function(t,e){return t+l(e)},""):"string"===t[o].type?i+=l(e[o]):r+=l(e[o])}),n+=r+i},l=function(t){return u(t)||"string"===t?2*i.ETH_PADDING:0},p=r.outputTypes(),h=function(t,e){e=e.slice(2);var n=[],s=2*i.ETH_PADDING,c=t.reduce(function(t,e){return t+l(e.type)},0),a=e.slice(0,c);return e=e.slice(c),t.forEach(function(i,c){for(var l=!1,h=0;h<p.length&&!l;h++)l=p[h].type(t[c].type);l||f(t[c].type);var g=p[h-1].format;if(u(t[c].type)){var m=o.formatOutputUInt(a.slice(0,s));a=a.slice(s);for(var d=[],v=0;m>v;v++)d.push(g(e.slice(0,s))),e=e.slice(s);n.push(d)}else r.prefixedType("string")(t[c].type)?(a=a.slice(s),n.push(g(e.slice(0,s))),e=e.slice(s)):(n.push(g(e.slice(0,s))),e=e.slice(s))}),n},g=function(t){var e={};return t.forEach(function(t){var r=n.extractDisplayName(t.name),i=n.extractTypeName(t.name),o=function(){var e=Array.prototype.slice.call(arguments);return a(t.inputs,e)};void 0===e[r]&&(e[r]=o),e[r][i]=o}),e},m=function(t){var e={};return t.forEach(function(t){var r=n.extractDisplayName(t.name),i=n.extractTypeName(t.name),o=function(e){return h(t.outputs,e)};void 0===e[r]&&(e[r]=o),e[r][i]=o}),e};e.exports={inputParser:g,outputParser:m,formatInput:a,formatOutput:h}},{"./const":4,"./formatters":5,"./types":6,"./utils":7}],4:[function(t,e){(function(n){if("build"!==n.env.NODE_ENV)var r=t("bignumber.js");var i=["wei","Kwei","Mwei","Gwei","szabo","finney","ether","grand","Mether","Gether","Tether","Pether","Eether","Zether","Yether","Nether","Dether","Vether","Uether"];e.exports={ETH_PADDING:32,ETH_SIGNATURE_LENGTH:4,ETH_UNITS:i,ETH_BIGNUMBER_ROUNDING_MODE:{ROUNDING_MODE:r.ROUND_DOWN},ETH_POLLING_TIMEOUT:1e3}}).call(this,t("_process"))},{_process:2,"bignumber.js":8}],5:[function(t,e){(function(n){if("build"!==n.env.NODE_ENV)var r=t("bignumber.js");var i=t("./utils"),o=t("./const"),f=function(t,e,n){return new Array(e-t.length+1).join(n?n:"0")+t},u=function(t){var e=2*o.ETH_PADDING;return t instanceof r||"number"==typeof t?("number"==typeof t&&(t=new r(t)),r.config(o.ETH_BIGNUMBER_ROUNDING_MODE),t=t.round(),t.lessThan(0)&&(t=new r("ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff",16).plus(t).plus(1)),t=t.toString(16)):t=0===t.indexOf("0x")?t.substr(2):"string"==typeof t?u(new r(t)):(+t).toString(16),f(t,e)},s=function(t){return i.fromAscii(t,o.ETH_PADDING).substr(2)},c=function(t){return"000000000000000000000000000000000000000000000000000000000000000"+(t?"1":"0")},a=function(t){return u(new r(t).times(new r(2).pow(128)))},l=function(t){return"1"===new r(t.substr(0,1),16).toString(2).substr(0,1)},p=function(t){return t=t||"0",l(t)?new r(t,16).minus(new r("ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff",16)).minus(1):new r(t,16)},h=function(t){return t=t||"0",new r(t,16)},g=function(t){return p(t).dividedBy(new r(2).pow(128))},m=function(t){return h(t).dividedBy(new r(2).pow(128))},d=function(t){return"0x"+t},v=function(t){return"0000000000000000000000000000000000000000000000000000000000000001"===t?!0:!1},w=function(t){return i.toAscii(t)},y=function(t){return"0x"+t.slice(t.length-40,t.length)};e.exports={formatInputInt:u,formatInputString:s,formatInputBool:c,formatInputReal:a,formatOutputInt:p,formatOutputUInt:h,formatOutputReal:g,formatOutputUReal:m,formatOutputHash:d,formatOutputBool:v,formatOutputString:w,formatOutputAddress:y}}).call(this,t("_process"))},{"./const":4,"./utils":7,_process:2,"bignumber.js":8}],6:[function(t,e){var n=t("./formatters"),r=function(t){return function(e){return 0===e.indexOf(t)}},i=function(t){return function(e){return t===e}},o=function(){return[{type:r("uint"),format:n.formatInputInt},{type:r("int"),format:n.formatInputInt},{type:r("hash"),format:n.formatInputInt},{type:r("string"),format:n.formatInputString},{type:r("real"),format:n.formatInputReal},{type:r("ureal"),format:n.formatInputReal},{type:i("address"),format:n.formatInputInt},{type:i("bool"),format:n.formatInputBool}]},f=function(){return[{type:r("uint"),format:n.formatOutputUInt},{type:r("int"),format:n.formatOutputInt},{type:r("hash"),format:n.formatOutputHash},{type:r("string"),format:n.formatOutputString},{type:r("real"),format:n.formatOutputReal},{type:r("ureal"),format:n.formatOutputUReal},{type:i("address"),format:n.formatOutputAddress},{type:i("bool"),format:n.formatOutputBool}]};e.exports={prefixedType:r,namedType:i,inputTypes:o,outputTypes:f}},{"./formatters":5}],7:[function(t,e){var n=t("./const"),r=function(t,e){for(var n=!1,r=0;r<t.length&&!n;r++)n=e(t[r]);return n?r-1:-1},i=function(t){var e="",n=0,r=t.length;for("0x"===t.substring(0,2)&&(n=2);r>n;n+=2){var i=parseInt(t.substr(n,2),16);if(0===i)break;e+=String.fromCharCode(i)}return e},o=function(t){for(var e="",n=0;n<t.length;n++){var r=t.charCodeAt(n).toString(16);e+=r.length<2?"0"+r:r}return e},f=function(t,e){e=void 0===e?0:e;for(var n=o(t);n.length<2*e;)n+="00";return"0x"+n},u=function(t){var e=t.indexOf("(");return-1!==e?t.substr(0,e):t},s=function(t){var e=t.indexOf("(");return-1!==e?t.substr(e+1,t.length-1-(e+1)).replace(" ",""):""},c=function(t){return t.filter(function(t){return"function"===t.type})},a=function(t){return t.filter(function(t){return"event"===t.type})},l=function(t){for(var e="string"==typeof t?0===t.indexOf("0x")?parseInt(t.substr(2),16):parseInt(t):t,r=0,i=n.ETH_UNITS;e>3e3&&r<i.length-1;)e/=1e3,r++;for(var o=e.toString().length<e.toFixed(2).length?e.toString():e.toFixed(2),f=function(t,e,n){return e+","+n};;){var u=o;if(o=o.replace(/(\d)(\d\d\d[\.\,])/,f),u===o)break}return o+" "+i[r]};e.exports={findIndex:r,toAscii:i,fromAscii:f,extractDisplayName:u,extractTypeName:s,filterFunctions:c,filterEvents:a,toEth:l}},{"./const":4}],8:[function(t,e){!function(n){"use strict";function r(t){function e(t,r){var i,o,f,u,s,c,a=this;if(!(a instanceof e))return $&&U(26,"constructor call without new",t),new e(t,r);if(null!=r&&z(r,2,64,L,"base")){if(r=0|r,c=t+"",10==r)return a=new e(t instanceof e?t:c),F(a,B+a.e+1,H);if((u="number"==typeof t)&&0*t!=0||!new RegExp("^-?"+(i="["+N.slice(0,r)+"]+")+"(?:\\."+i+")?$",37>r?"i":"").test(c))return m(a,c,u,r);u?(a.s=0>1/t?(c=c.slice(1),-1):1,$&&c.replace(/^0\.0*|\./,"").length>15&&U(L,O,t),u=!1):a.s=45===c.charCodeAt(0)?(c=c.slice(1),-1):1,c=n(c,10,r,a.s)}else{if(t instanceof e)return a.s=t.s,a.e=t.e,a.c=(t=t.c)?t.slice():t,void(L=0);if((u="number"==typeof t)&&0*t==0){if(a.s=0>1/t?(t=-t,-1):1,t===~~t){for(o=0,f=t;f>=10;f/=10,o++);return a.e=o,a.c=[t],void(L=0)}c=t+""}else{if(!d.test(c=t+""))return m(a,c,u);a.s=45===c.charCodeAt(0)?(c=c.slice(1),-1):1}}for((o=c.indexOf("."))>-1&&(c=c.replace(".","")),(f=c.search(/e/i))>0?(0>o&&(o=f),o+=+c.slice(f+1),c=c.substring(0,f)):0>o&&(o=c.length),f=0;48===c.charCodeAt(f);f++);for(s=c.length;48===c.charCodeAt(--s););if(c=c.slice(f,s+1))if(s=c.length,u&&$&&s>15&&U(L,O,a.s*t),o=o-f-1,o>q)a.c=a.e=null;else if(k>o)a.c=[a.e=0];else{if(a.e=o,a.c=[],f=(o+1)%I,0>o&&(f+=I),s>f){for(f&&a.c.push(+c.slice(0,f)),s-=I;s>f;)a.c.push(+c.slice(f,f+=I));c=c.slice(f),f=I-c.length}else f-=s;for(;f--;c+="0");a.c.push(+c)}else a.c=[a.e=0];L=0}function n(t,n,r,i){var f,u,s,a,p,h,g,m=t.indexOf("."),d=B,v=H;for(37>r&&(t=t.toLowerCase()),m>=0&&(s=Y,Y=0,t=t.replace(".",""),g=new e(r),p=g.pow(t.length-m),Y=s,g.c=c(l(o(p.c),p.e),10,n),g.e=g.c.length),h=c(t,r,n),u=s=h.length;0==h[--s];h.pop());if(!h[0])return"0";if(0>m?--u:(p.c=h,p.e=u,p.s=i,p=G(p,g,d,v,n),h=p.c,a=p.r,u=p.e),f=u+d+1,m=h[f],s=n/2,a=a||0>f||null!=h[f+1],a=4>v?(null!=m||a)&&(0==v||v==(p.s<0?3:2)):m>s||m==s&&(4==v||a||6==v&&1&h[f-1]||v==(p.s<0?8:7)),1>f||!h[0])t=a?l("1",-d):"0";else{if(h.length=f,a)for(--n;++h[--f]>n;)h[f]=0,f||(++u,h.unshift(1));for(s=h.length;!h[--s];);for(m=0,t="";s>=m;t+=N.charAt(h[m++]));t=l(t,u)}return t}function h(t,n,r,i){var f,u,s,c,p;if(r=null!=r&&z(r,0,8,i,b)?0|r:H,!t.c)return t.toString();if(f=t.c[0],s=t.e,null==n)p=o(t.c),p=19==i||24==i&&C>=s?a(p,s):l(p,s);else if(t=F(new e(t),n,r),u=t.e,p=o(t.c),c=p.length,19==i||24==i&&(u>=n||C>=u)){for(;n>c;p+="0",c++);p=a(p,u)}else if(n-=s,p=l(p,u),u+1>c){if(--n>0)for(p+=".";n--;p+="0");}else if(n+=u-c,n>0)for(u+1==c&&(p+=".");n--;p+="0");return t.s<0&&f?"-"+p:p}function S(t,n){var r,i,o=0;for(s(t[0])&&(t=t[0]),r=new e(t[0]);++o<t.length;){if(i=new e(t[o]),!i.s){r=i;break}n.call(r,i)&&(r=i)}return r}function A(t,e,n,r,i){return(e>t||t>n||t!=p(t))&&U(r,(i||"decimal places")+(e>t||t>n?" out of range":" not an integer"),t),!0}function R(t,e,n){for(var r=1,i=e.length;!e[--i];e.pop());for(i=e[0];i>=10;i/=10,r++);return(n=r+n*I-1)>q?t.c=t.e=null:k>n?t.c=[t.e=0]:(t.e=n,t.c=e),t}function U(t,e,n){var r=new Error(["new BigNumber","cmp","config","div","divToInt","eq","gt","gte","lt","lte","minus","mod","plus","precision","random","round","shift","times","toDigits","toExponential","toFixed","toFormat","toFraction","pow","toPrecision","toString","BigNumber"][t]+"() "+e+": "+n);throw r.name="BigNumber Error",L=0,r}function F(t,e,n,r){var i,o,f,u,s,c,a,l=t.c,p=_;if(l){t:{for(i=1,u=l[0];u>=10;u/=10,i++);if(o=e-i,0>o)o+=I,f=e,s=l[c=0],a=s/p[i-f-1]%10|0;else if(c=v((o+1)/I),c>=l.length){if(!r)break t;for(;l.length<=c;l.push(0));s=a=0,i=1,o%=I,f=o-I+1}else{for(s=u=l[c],i=1;u>=10;u/=10,i++);o%=I,f=o-I+i,a=0>f?0:s/p[i-f-1]%10|0}if(r=r||0>e||null!=l[c+1]||(0>f?s:s%p[i-f-1]),r=4>n?(a||r)&&(0==n||n==(t.s<0?3:2)):a>5||5==a&&(4==n||r||6==n&&(o>0?f>0?s/p[i-f]:0:l[c-1])%10&1||n==(t.s<0?8:7)),1>e||!l[0])return l.length=0,r?(e-=t.e+1,l[0]=p[e%I],t.e=-e||0):l[0]=t.e=0,t;if(0==o?(l.length=c,u=1,c--):(l.length=c+1,u=p[I-o],l[c]=f>0?w(s/p[i-f]%p[f])*u:0),r)for(;;){if(0==c){for(o=1,f=l[0];f>=10;f/=10,o++);for(f=l[0]+=u,u=1;f>=10;f/=10,u++);o!=u&&(t.e++,l[0]==E&&(l[0]=1));break}if(l[c]+=u,l[c]!=E)break;l[c--]=0,u=1}for(o=l.length;0===l[--o];l.pop());}t.e>q?t.c=t.e=null:t.e<k&&(t.c=[t.e=0])}return t}var G,L=0,M=e.prototype,P=new e(1),B=20,H=4,C=-7,j=21,k=-1e7,q=1e7,$=!0,z=A,V=!1,W=1,Y=100,Z={decimalSeparator:".",groupSeparator:",",groupSize:3,secondaryGroupSize:0,fractionGroupSeparator:" ",fractionGroupSize:0};return e.another=r,e.ROUND_UP=0,e.ROUND_DOWN=1,e.ROUND_CEIL=2,e.ROUND_FLOOR=3,e.ROUND_HALF_UP=4,e.ROUND_HALF_DOWN=5,e.ROUND_HALF_EVEN=6,e.ROUND_HALF_CEIL=7,e.ROUND_HALF_FLOOR=8,e.EUCLID=9,e.config=function(){var t,e,n=0,r={},i=arguments,o=i[0],f=o&&"object"==typeof o?function(){return o.hasOwnProperty(e)?null!=(t=o[e]):void 0}:function(){return i.length>n?null!=(t=i[n++]):void 0};return f(e="DECIMAL_PLACES")&&z(t,0,D,2,e)&&(B=0|t),r[e]=B,f(e="ROUNDING_MODE")&&z(t,0,8,2,e)&&(H=0|t),r[e]=H,f(e="EXPONENTIAL_AT")&&(s(t)?z(t[0],-D,0,2,e)&&z(t[1],0,D,2,e)&&(C=0|t[0],j=0|t[1]):z(t,-D,D,2,e)&&(C=-(j=0|(0>t?-t:t)))),r[e]=[C,j],f(e="RANGE")&&(s(t)?z(t[0],-D,-1,2,e)&&z(t[1],1,D,2,e)&&(k=0|t[0],q=0|t[1]):z(t,-D,D,2,e)&&(0|t?k=-(q=0|(0>t?-t:t)):$&&U(2,e+" cannot be zero",t))),r[e]=[k,q],f(e="ERRORS")&&(t===!!t||1===t||0===t?(L=0,z=($=!!t)?A:u):$&&U(2,e+y,t)),r[e]=$,f(e="CRYPTO")&&(t===!!t||1===t||0===t?(V=!(!t||!g||"object"!=typeof g),t&&!V&&$&&U(2,"crypto unavailable",g)):$&&U(2,e+y,t)),r[e]=V,f(e="MODULO_MODE")&&z(t,0,9,2,e)&&(W=0|t),r[e]=W,f(e="POW_PRECISION")&&z(t,0,D,2,e)&&(Y=0|t),r[e]=Y,f(e="FORMAT")&&("object"==typeof t?Z=t:$&&U(2,e+" not an object",t)),r[e]=Z,r},e.max=function(){return S(arguments,M.lt)},e.min=function(){return S(arguments,M.gt)},e.random=function(){var t=9007199254740992,n=Math.random()*t&2097151?function(){return w(Math.random()*t)}:function(){return 8388608*(1073741824*Math.random()|0)+(8388608*Math.random()|0)};return function(t){var r,i,o,f,u,s=0,c=[],a=new e(P);if(t=null!=t&&z(t,0,D,14)?0|t:B,f=v(t/I),V)if(g&&g.getRandomValues){for(r=g.getRandomValues(new Uint32Array(f*=2));f>s;)u=131072*r[s]+(r[s+1]>>>11),u>=9e15?(i=g.getRandomValues(new Uint32Array(2)),r[s]=i[0],r[s+1]=i[1]):(c.push(u%1e14),s+=2);s=f/2}else if(g&&g.randomBytes){for(r=g.randomBytes(f*=7);f>s;)u=281474976710656*(31&r[s])+1099511627776*r[s+1]+4294967296*r[s+2]+16777216*r[s+3]+(r[s+4]<<16)+(r[s+5]<<8)+r[s+6],u>=9e15?g.randomBytes(7).copy(r,s):(c.push(u%1e14),s+=7);s=f/7}else $&&U(14,"crypto unavailable",g);if(!s)for(;f>s;)u=n(),9e15>u&&(c[s++]=u%1e14);for(f=c[--s],t%=I,f&&t&&(u=_[I-t],c[s]=w(f/u)*u);0===c[s];c.pop(),s--);if(0>s)c=[o=0];else{for(o=-1;0===c[0];c.shift(),o-=I);for(s=1,u=c[0];u>=10;u/=10,s++);I>s&&(o-=I-s)}return a.e=o,a.c=c,a}}(),G=function(){function t(t,e,n){var r,i,o,f,u=0,s=t.length,c=e%T,a=e/T|0;for(t=t.slice();s--;)o=t[s]%T,f=t[s]/T|0,r=a*o+f*c,i=c*o+r%T*T+u,u=(i/n|0)+(r/T|0)+a*f,t[s]=i%n;return u&&t.unshift(u),t}function n(t,e,n,r){var i,o;if(n!=r)o=n>r?1:-1;else for(i=o=0;n>i;i++)if(t[i]!=e[i]){o=t[i]>e[i]?1:-1;break}return o}function r(t,e,n,r){for(var i=0;n--;)t[n]-=i,i=t[n]<e[n]?1:0,t[n]=i*r+t[n]-e[n];for(;!t[0]&&t.length>1;t.shift());}return function(o,f,u,s,c){var a,l,p,h,g,m,d,v,y,b,O,N,x,_,T,D,S,A=o.s==f.s?1:-1,R=o.c,U=f.c;if(!(R&&R[0]&&U&&U[0]))return new e(o.s&&f.s&&(R?!U||R[0]!=U[0]:U)?R&&0==R[0]||!U?0*A:A/0:0/0);for(v=new e(A),y=v.c=[],l=o.e-f.e,A=u+l+1,c||(c=E,l=i(o.e/I)-i(f.e/I),A=A/I|0),p=0;U[p]==(R[p]||0);p++);if(U[p]>(R[p]||0)&&l--,0>A)y.push(1),h=!0;else{for(_=R.length,D=U.length,p=0,A+=2,g=w(c/(U[0]+1)),g>1&&(U=t(U,g,c),R=t(R,g,c),D=U.length,_=R.length),x=D,b=R.slice(0,D),O=b.length;D>O;b[O++]=0);S=U.slice(),S.unshift(0),T=U[0],U[1]>=c/2&&T++;do g=0,a=n(U,b,D,O),0>a?(N=b[0],D!=O&&(N=N*c+(b[1]||0)),g=w(N/T),g>1?(g>=c&&(g=c-1),m=t(U,g,c),d=m.length,O=b.length,a=n(m,b,d,O),1==a&&(g--,r(m,d>D?S:U,d,c))):(0==g&&(a=g=1),m=U.slice()),d=m.length,O>d&&m.unshift(0),r(b,m,O,c),-1==a&&(O=b.length,a=n(U,b,D,O),1>a&&(g++,r(b,O>D?S:U,O,c))),O=b.length):0===a&&(g++,b=[0]),y[p++]=g,a&&b[0]?b[O++]=R[x]||0:(b=[R[x]],O=1);while((x++<_||null!=b[0])&&A--);h=null!=b[0],y[0]||y.shift()}if(c==E){for(p=1,A=y[0];A>=10;A/=10,p++);F(v,u+(v.e=p+l*I-1)+1,s,h)}else v.e=l,v.r=+h;return v}}(),m==function(){var t=/^(-?)0([xbo])(\w[\w.]*$)/i,n=/^([^.]+)\.$/,r=/^\.([^.]+)$/,i=/^-?(Infinity|NaN)$/,o=/^\s*\+([\w.])|^\s+|\s+$/g;return function(f,u,s,c){var a,l=s?u:u.replace(o,"$1");if(i.test(l))f.s=isNaN(l)?null:0>l?-1:1;else{if(!s&&(l=l.replace(t,function(t,e,n){return a="x"==(n=n.toLowerCase())?16:"b"==n?2:8,c&&c!=a?t:e}),c&&(a=c,l=l.replace(n,"$1").replace(r,"0.$1")),u!=l))return new e(l,a);$&&U(L,"not a"+(c?" base "+c:"")+" number",u),f.s=null}f.c=f.e=null,L=0}}(),M.absoluteValue=M.abs=function(){var t=new e(this);return t.s<0&&(t.s=1),t},M.ceil=function(){return F(new e(this),this.e+1,2)},M.comparedTo=M.cmp=function(t,n){return L=1,f(this,new e(t,n))},M.decimalPlaces=M.dp=function(){var t,e,n=this.c;if(!n)return null;if(t=((e=n.length-1)-i(this.e/I))*I,e=n[e])for(;e%10==0;e/=10,t--);return 0>t&&(t=0),t},M.dividedBy=M.div=function(t,n){return L=3,G(this,new e(t,n),B,H)},M.dividedToIntegerBy=M.divToInt=function(t,n){return L=4,G(this,new e(t,n),0,1)},M.equals=M.eq=function(t,n){return L=5,0===f(this,new e(t,n))},M.floor=function(){return F(new e(this),this.e+1,3)},M.greaterThan=M.gt=function(t,n){return L=6,f(this,new e(t,n))>0},M.greaterThanOrEqualTo=M.gte=function(t,n){return L=7,1===(n=f(this,new e(t,n)))||0===n},M.isFinite=function(){return!!this.c},M.isInteger=M.isInt=function(){return!!this.c&&i(this.e/I)>this.c.length-2},M.isNaN=function(){return!this.s},M.isNegative=M.isNeg=function(){return this.s<0},M.isZero=function(){return!!this.c&&0==this.c[0]},M.lessThan=M.lt=function(t,n){return L=8,f(this,new e(t,n))<0},M.lessThanOrEqualTo=M.lte=function(t,n){return L=9,-1===(n=f(this,new e(t,n)))||0===n},M.minus=M.sub=function(t,n){var r,o,f,u,s=this,c=s.s;if(L=10,t=new e(t,n),n=t.s,!c||!n)return new e(0/0);if(c!=n)return t.s=-n,s.plus(t);var a=s.e/I,l=t.e/I,p=s.c,h=t.c;if(!a||!l){if(!p||!h)return p?(t.s=-n,t):new e(h?s:0/0);if(!p[0]||!h[0])return h[0]?(t.s=-n,t):new e(p[0]?s:3==H?-0:0)}if(a=i(a),l=i(l),p=p.slice(),c=a-l){for((u=0>c)?(c=-c,f=p):(l=a,f=h),f.reverse(),n=c;n--;f.push(0));f.reverse()}else for(o=(u=(c=p.length)<(n=h.length))?c:n,c=n=0;o>n;n++)if(p[n]!=h[n]){u=p[n]<h[n];break}if(u&&(f=p,p=h,h=f,t.s=-t.s),n=(o=h.length)-(r=p.length),n>0)for(;n--;p[r++]=0);for(n=E-1;o>c;){if(p[--o]<h[o]){for(r=o;r&&!p[--r];p[r]=n);--p[r],p[o]+=E}p[o]-=h[o]}for(;0==p[0];p.shift(),--l);return p[0]?R(t,p,l):(t.s=3==H?-1:1,t.c=[t.e=0],t)},M.modulo=M.mod=function(t,n){var r,i,o=this;return L=11,t=new e(t,n),!o.c||!t.s||t.c&&!t.c[0]?new e(0/0):!t.c||o.c&&!o.c[0]?new e(o):(9==W?(i=t.s,t.s=1,r=G(o,t,0,3),t.s=i,r.s*=i):r=G(o,t,0,W),o.minus(r.times(t)))},M.negated=M.neg=function(){var t=new e(this);return t.s=-t.s||null,t},M.plus=M.add=function(t,n){var r,o=this,f=o.s;if(L=12,t=new e(t,n),n=t.s,!f||!n)return new e(0/0);if(f!=n)return t.s=-n,o.minus(t);var u=o.e/I,s=t.e/I,c=o.c,a=t.c;if(!u||!s){if(!c||!a)return new e(f/0);if(!c[0]||!a[0])return a[0]?t:new e(c[0]?o:0*f)}if(u=i(u),s=i(s),c=c.slice(),f=u-s){for(f>0?(s=u,r=a):(f=-f,r=c),r.reverse();f--;r.push(0));r.reverse()}for(f=c.length,n=a.length,0>f-n&&(r=a,a=c,c=r,n=f),f=0;n;)f=(c[--n]=c[n]+a[n]+f)/E|0,c[n]%=E;return f&&(c.unshift(f),++s),R(t,c,s)},M.precision=M.sd=function(t){var e,n,r=this,i=r.c;if(null!=t&&t!==!!t&&1!==t&&0!==t&&($&&U(13,"argument"+y,t),t!=!!t&&(t=null)),!i)return null;if(n=i.length-1,e=n*I+1,n=i[n]){for(;n%10==0;n/=10,e--);for(n=i[0];n>=10;n/=10,e++);}return t&&r.e+1>e&&(e=r.e+1),e},M.round=function(t,n){var r=new e(this);return(null==t||z(t,0,D,15))&&F(r,~~t+this.e+1,null!=n&&z(n,0,8,15,b)?0|n:H),r},M.shift=function(t){var n=this;return z(t,-x,x,16,"argument")?n.times("1e"+p(t)):new e(n.c&&n.c[0]&&(-x>t||t>x)?n.s*(0>t?0:1/0):n)},M.squareRoot=M.sqrt=function(){var t,n,r,f,u,s=this,c=s.c,a=s.s,l=s.e,p=B+4,h=new e("0.5");if(1!==a||!c||!c[0])return new e(!a||0>a&&(!c||c[0])?0/0:c?s:1/0);if(a=Math.sqrt(+s),0==a||a==1/0?(n=o(c),(n.length+l)%2==0&&(n+="0"),a=Math.sqrt(n),l=i((l+1)/2)-(0>l||l%2),a==1/0?n="1e"+l:(n=a.toExponential(),n=n.slice(0,n.indexOf("e")+1)+l),r=new e(n)):r=new e(a+""),r.c[0])for(l=r.e,a=l+p,3>a&&(a=0);;)if(u=r,r=h.times(u.plus(G(s,u,p,1))),o(u.c).slice(0,a)===(n=o(r.c)).slice(0,a)){if(r.e<l&&--a,n=n.slice(a-3,a+1),"9999"!=n&&(f||"4999"!=n)){(!+n||!+n.slice(1)&&"5"==n.charAt(0))&&(F(r,r.e+B+2,1),t=!r.times(r).eq(s));break}if(!f&&(F(u,u.e+B+2,0),u.times(u).eq(s))){r=u;break}p+=4,a+=4,f=1}return F(r,r.e+B+1,H,t)},M.times=M.mul=function(t,n){var r,o,f,u,s,c,a,l,p,h,g,m,d,v,w,y=this,b=y.c,O=(L=17,t=new e(t,n)).c;if(!(b&&O&&b[0]&&O[0]))return!y.s||!t.s||b&&!b[0]&&!O||O&&!O[0]&&!b?t.c=t.e=t.s=null:(t.s*=y.s,b&&O?(t.c=[0],t.e=0):t.c=t.e=null),t;for(o=i(y.e/I)+i(t.e/I),t.s*=y.s,a=b.length,h=O.length,h>a&&(d=b,b=O,O=d,f=a,a=h,h=f),f=a+h,d=[];f--;d.push(0));for(v=E,w=T,f=h;--f>=0;){for(r=0,g=O[f]%w,m=O[f]/w|0,s=a,u=f+s;u>f;)l=b[--s]%w,p=b[s]/w|0,c=m*l+p*g,l=g*l+c%w*w+d[u]+r,r=(l/v|0)+(c/w|0)+m*p,d[u--]=l%v;d[u]=r}return r?++o:d.shift(),R(t,d,o)},M.toDigits=function(t,n){var r=new e(this);return t=null!=t&&z(t,1,D,18,"precision")?0|t:null,n=null!=n&&z(n,0,8,18,b)?0|n:H,t?F(r,t,n):r},M.toExponential=function(t,e){return h(this,null!=t&&z(t,0,D,19)?~~t+1:null,e,19)},M.toFixed=function(t,e){return h(this,null!=t&&z(t,0,D,20)?~~t+this.e+1:null,e,20)},M.toFormat=function(t,e){var n=h(this,null!=t&&z(t,0,D,21)?~~t+this.e+1:null,e,21);if(this.c){var r,i=n.split("."),o=+Z.groupSize,f=+Z.secondaryGroupSize,u=Z.groupSeparator,s=i[0],c=i[1],a=this.s<0,l=a?s.slice(1):s,p=l.length;if(f&&(r=o,o=f,f=r,p-=r),o>0&&p>0){for(r=p%o||o,s=l.substr(0,r);p>r;r+=o)s+=u+l.substr(r,o);f>0&&(s+=u+l.slice(r)),a&&(s="-"+s)}n=c?s+Z.decimalSeparator+((f=+Z.fractionGroupSize)?c.replace(new RegExp("\\d{"+f+"}\\B","g"),"$&"+Z.fractionGroupSeparator):c):s}return n},M.toFraction=function(t){var n,r,i,f,u,s,c,a,l,p=$,h=this,g=h.c,m=new e(P),d=r=new e(P),v=c=new e(P);if(null!=t&&($=!1,s=new e(t),$=p,(!(p=s.isInt())||s.lt(P))&&($&&U(22,"max denominator "+(p?"out of range":"not an integer"),t),t=!p&&s.c&&F(s,s.e+1,1).gte(P)?s:null)),!g)return h.toString();for(l=o(g),f=m.e=l.length-h.e-1,m.c[0]=_[(u=f%I)<0?I+u:u],t=!t||s.cmp(m)>0?f>0?m:d:s,u=q,q=1/0,s=new e(l),c.c[0]=0;a=G(s,m,0,1),i=r.plus(a.times(v)),1!=i.cmp(t);)r=v,v=i,d=c.plus(a.times(i=d)),c=i,m=s.minus(a.times(i=m)),s=i;return i=G(t.minus(r),v,0,1),c=c.plus(i.times(d)),r=r.plus(i.times(v)),c.s=d.s=h.s,f*=2,n=G(d,v,f,H).minus(h).abs().cmp(G(c,r,f,H).minus(h).abs())<1?[d.toString(),v.toString()]:[c.toString(),r.toString()],q=u,n},M.toNumber=function(){var t=this;return+t||(t.s?0*t.s:0/0)},M.toPower=M.pow=function(t){var n,r,i=w(0>t?-t:+t),o=this;if(!z(t,-x,x,23,"exponent")&&(!isFinite(t)||i>x&&(t/=0)||parseFloat(t)!=t&&!(t=0/0)))return new e(Math.pow(+o,t));for(n=Y?v(Y/I+2):0,r=new e(P);;){if(i%2){if(r=r.times(o),!r.c)break;n&&r.c.length>n&&(r.c.length=n)}if(i=w(i/2),!i)break;o=o.times(o),n&&o.c&&o.c.length>n&&(o.c.length=n)}return 0>t&&(r=P.div(r)),n?F(r,Y,H):r},M.toPrecision=function(t,e){return h(this,null!=t&&z(t,1,D,24,"precision")?0|t:null,e,24)},M.toString=function(t){var e,r=this,i=r.s,f=r.e;return null===f?i?(e="Infinity",0>i&&(e="-"+e)):e="NaN":(e=o(r.c),e=null!=t&&z(t,2,64,25,"base")?n(l(e,f),0|t,10,i):C>=f||f>=j?a(e,f):l(e,f),0>i&&r.c[0]&&(e="-"+e)),e},M.truncated=M.trunc=function(){return F(new e(this),this.e+1,1)},M.valueOf=M.toJSON=function(){return this.toString()},null!=t&&e.config(t),e}function i(t){var e=0|t;return t>0||t===e?e:e-1}function o(t){for(var e,n,r=1,i=t.length,o=t[0]+"";i>r;){for(e=t[r++]+"",n=I-e.length;n--;e="0"+e);o+=e}for(i=o.length;48===o.charCodeAt(--i););return o.slice(0,i+1||1)}function f(t,e){var n,r,i=t.c,o=e.c,f=t.s,u=e.s,s=t.e,c=e.e;if(!f||!u)return null;if(n=i&&!i[0],r=o&&!o[0],n||r)return n?r?0:-u:f;if(f!=u)return f;if(n=0>f,r=s==c,!i||!o)return r?0:!i^n?1:-1;if(!r)return s>c^n?1:-1;for(u=(s=i.length)<(c=o.length)?s:c,f=0;u>f;f++)if(i[f]!=o[f])return i[f]>o[f]^n?1:-1;return s==c?0:s>c^n?1:-1}function u(t,e,n){return(t=p(t))>=e&&n>=t}function s(t){return"[object Array]"==Object.prototype.toString.call(t)}function c(t,e,n){for(var r,i,o=[0],f=0,u=t.length;u>f;){for(i=o.length;i--;o[i]*=e);for(o[r=0]+=N.indexOf(t.charAt(f++));r<o.length;r++)o[r]>n-1&&(null==o[r+1]&&(o[r+1]=0),o[r+1]+=o[r]/n|0,o[r]%=n)}return o.reverse()}function a(t,e){return(t.length>1?t.charAt(0)+"."+t.slice(1):t)+(0>e?"e":"e+")+e}function l(t,e){var n,r;if(0>e){for(r="0.";++e;r+="0");t=r+t}else if(n=t.length,++e>n){for(r="0",e-=n;--e;r+="0");t+=r}else n>e&&(t=t.slice(0,e)+"."+t.slice(e));return t}function p(t){return t=parseFloat(t),0>t?v(t):w(t)}var h,g,m,d=/^-?(\d+(\.\d*)?|\.\d+)(e[+-]?\d+)?$/i,v=Math.ceil,w=Math.floor,y=" not a boolean or binary digit",b="rounding mode",O="number type has more than 15 significant digits",N="0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ$_",E=1e14,I=14,x=9007199254740991,_=[1,10,100,1e3,1e4,1e5,1e6,1e7,1e8,1e9,1e10,1e11,1e12,1e13],T=1e7,D=1e9;if(h=r(),"function"==typeof define&&define.amd)define(function(){return h});else if("undefined"!=typeof e&&e.exports){if(e.exports=h,!g)try{g=t("crypto")}catch(S){}}else n.BigNumber=h}(this)},{crypto:1}],natspec:[function(t,e){var n=t("./node_modules/ethereum.js/lib/abi.js"),r=function(){var t=function(t,e){Object.keys(t).forEach(function(n){e[n]=t[n]})},e=function(t){return Object.keys(t).reduce(function(t,e){return t+"var "+e+" = context['"+e+"'];\n"},"")},r=function(t,e){return t.filter(function(t){return t.name===e})[0]},i=function(t,e){var r=n.formatOutput(t.inputs,"0x"+e.params[0].data.slice(10));return t.inputs.reduce(function(t,e,n){return t[e.name]=r[n],t},{})},o=function(t,e){var n,r="",i=/\` + "`" + `(?:\\.|[^` + "`" + `\\])*\` + "`" + `/gim,o=0;try{for(;null!==(n=i.exec(t));){var f=i.lastIndex-n[0].length,u=n[0].slice(1,n[0].length-1);r+=t.slice(o,f);var s=e(u);r+=s,o=i.lastIndex}r+=t.slice(o)}catch(c){throw new Error("Natspec evaluation failed, wrong input params")}return r},f=function(n,f){var u={};if(f)try{var s=r(f.abi,f.method),c=i(s,f.transaction);t(c,u)}catch(a){throw new Error("Natspec evaluation failed, method does not exist")}var l=e(u),p=o(n,function(t){var e=new Function("context",l+"return "+t+";");return e(u).toString()});return p},u=function(t,e){try{return f(t,e)}catch(n){return n.message}};return{evaluateExpression:f,evaluateExpressionSafe:u}}();e.exports=r},{"./node_modules/ethereum.js/lib/abi.js":3}]},{},[]);
+//# sourceMappingURL=natspec.js.map`
diff --git a/common/natspec/natspec_test.go b/common/natspec/natspec_test.go
new file mode 100644
index 000000000..3b548817b
--- /dev/null
+++ b/common/natspec/natspec_test.go
@@ -0,0 +1,97 @@
+package natspec
+
+import (
+ "testing"
+)
+
+func TestNotice(t *testing.T) {
+
+ tx := `
+ {
+ "jsonrpc": "2.0",
+ "method": "eth_call",
+ "params": [{
+ "to": "0x8521742d3f456bd237e312d6e30724960f72517a",
+ "data": "0xc6888fa1000000000000000000000000000000000000000000000000000000000000007a"
+ }],
+ "id": 6
+ }
+ `
+
+ abi := `
+ [{
+ "name": "multiply",
+ "constant": false,
+ "type": "function",
+ "inputs": [{
+ "name": "a",
+ "type": "uint256"
+ }],
+ "outputs": [{
+ "name": "d",
+ "type": "uint256"
+ }]
+ }]
+ `
+
+ desc := "Will multiply `a` by 7 and return `a * 7`."
+
+ method := "multiply"
+
+ ns, err := New()
+ if err != nil {
+ t.Errorf("NewNATSpec error %v", err)
+ }
+
+ notice, err := ns.Notice(tx, abi, method, desc)
+
+ if err != nil {
+ t.Errorf("expected no error got %v", err)
+ }
+
+ expected := "Will multiply 122 by 7 and return 854."
+ if notice != expected {
+ t.Errorf("incorrect notice. expected %v, got %v", expected, notice)
+ } else {
+ t.Logf("returned notice \"%v\"", notice)
+ }
+
+ notice, err = ns.Notice(tx, abi, method, "Will multiply 122 by \"7\" and return 854.")
+
+ expected = "natspec.js error setting expression: (anonymous): Line 1:41 Unexpected number"
+
+ if err == nil {
+ t.Errorf("expected error, got nothing (notice: '%v')", err, notice)
+ } else {
+ if err.Error() != expected {
+ t.Errorf("expected error '%s' got '%v' (notice: '%v')", expected, err, notice)
+ }
+ }
+
+ // https://github.com/ethereum/natspec.js/issues/1
+ badDesc := "Will multiply `e` by 7 and return `a * 7`."
+ notice, err = ns.Notice(tx, abi, method, badDesc)
+
+ expected = "natspec.js error evaluating expression: Natspec evaluation failed, wrong input params"
+
+ if err == nil {
+ t.Errorf("expected error, got nothing (notice: '%v')", notice)
+ } else {
+ if err.Error() != expected {
+ t.Errorf("expected error '%s' got '%v' (notice: '%v')", expected, err, notice)
+ }
+ }
+
+ notice, err = ns.Notice(tx, abi, "missing_method", desc)
+
+ expected = "natspec.js error evaluating expression: Natspec evaluation failed, method does not exist"
+
+ if err == nil {
+ t.Errorf("expected error, got nothing (notice: '%v')", notice)
+ } else {
+ if err.Error() != expected {
+ t.Errorf("expected error '%s' got '%v' (notice: '%v')", expected, err, notice)
+ }
+ }
+
+}
diff --git a/common/number/int.go b/common/number/int.go
new file mode 100644
index 000000000..6cc5e68b4
--- /dev/null
+++ b/common/number/int.go
@@ -0,0 +1,181 @@
+package number
+
+import (
+ "math/big"
+
+ "github.com/ethereum/go-ethereum/common"
+)
+
+var tt256 = new(big.Int).Lsh(big.NewInt(1), 256)
+var tt256m1 = new(big.Int).Sub(new(big.Int).Lsh(big.NewInt(1), 256), big.NewInt(1))
+var tt255 = new(big.Int).Lsh(big.NewInt(1), 255)
+
+func limitUnsigned256(x *Number) *Number {
+ x.num.And(x.num, tt256m1)
+ return x
+}
+
+func limitSigned256(x *Number) *Number {
+ if x.num.Cmp(tt255) < 0 {
+ return x
+ } else {
+ x.num.Sub(x.num, tt256)
+ return x
+ }
+}
+
+// Number function
+type Initialiser func(n int64) *Number
+
+// A Number represents a generic integer with a bounding function limiter. Limit is called after each operations
+// to give "fake" bounded integers. New types of Number can be created through NewInitialiser returning a lambda
+// with the new Initialiser.
+type Number struct {
+ num *big.Int
+ limit func(n *Number) *Number
+}
+
+// Returns a new initialiser for a new *Number without having to expose certain fields
+func NewInitialiser(limiter func(*Number) *Number) Initialiser {
+ return func(n int64) *Number {
+ return &Number{big.NewInt(n), limiter}
+ }
+}
+
+// Return a Number with a UNSIGNED limiter up to 256 bits
+func Uint256(n int64) *Number {
+ return &Number{big.NewInt(n), limitUnsigned256}
+}
+
+// Return a Number with a SIGNED limiter up to 256 bits
+func Int256(n int64) *Number {
+ return &Number{big.NewInt(n), limitSigned256}
+}
+
+// Returns a Number with a SIGNED unlimited size
+func Big(n int64) *Number {
+ return &Number{big.NewInt(n), func(x *Number) *Number { return x }}
+}
+
+// Sets i to sum of x+y
+func (i *Number) Add(x, y *Number) *Number {
+ i.num.Add(x.num, y.num)
+ return i.limit(i)
+}
+
+// Sets i to difference of x-y
+func (i *Number) Sub(x, y *Number) *Number {
+ i.num.Sub(x.num, y.num)
+ return i.limit(i)
+}
+
+// Sets i to product of x*y
+func (i *Number) Mul(x, y *Number) *Number {
+ i.num.Mul(x.num, y.num)
+ return i.limit(i)
+}
+
+// Sets i to the quotient prodject of x/y
+func (i *Number) Div(x, y *Number) *Number {
+ i.num.Div(x.num, y.num)
+ return i.limit(i)
+}
+
+// Sets i to x % y
+func (i *Number) Mod(x, y *Number) *Number {
+ i.num.Mod(x.num, y.num)
+ return i.limit(i)
+}
+
+// Sets i to x << s
+func (i *Number) Lsh(x *Number, s uint) *Number {
+ i.num.Lsh(x.num, s)
+ return i.limit(i)
+}
+
+// Sets i to x^y
+func (i *Number) Pow(x, y *Number) *Number {
+ i.num.Exp(x.num, y.num, big.NewInt(0))
+ return i.limit(i)
+}
+
+// Setters
+
+// Set x to i
+func (i *Number) Set(x *Number) *Number {
+ i.num.Set(x.num)
+ return i.limit(i)
+}
+
+// Set x bytes to i
+func (i *Number) SetBytes(x []byte) *Number {
+ i.num.SetBytes(x)
+ return i.limit(i)
+}
+
+// Cmp compares x and y and returns:
+//
+// -1 if x < y
+// 0 if x == y
+// +1 if x > y
+func (i *Number) Cmp(x *Number) int {
+ return i.num.Cmp(x.num)
+}
+
+// Getters
+
+// Returns the string representation of i
+func (i *Number) String() string {
+ return i.num.String()
+}
+
+// Returns the byte representation of i
+func (i *Number) Bytes() []byte {
+ return i.num.Bytes()
+}
+
+// Uint64 returns the Uint64 representation of x. If x cannot be represented in an int64, the result is undefined.
+func (i *Number) Uint64() uint64 {
+ return i.num.Uint64()
+}
+
+// Int64 returns the int64 representation of x. If x cannot be represented in an int64, the result is undefined.
+func (i *Number) Int64() int64 {
+ return i.num.Int64()
+}
+
+// Returns the signed version of i
+func (i *Number) Int256() *Number {
+ return Int(0).Set(i)
+}
+
+// Returns the unsigned version of i
+func (i *Number) Uint256() *Number {
+ return Uint(0).Set(i)
+}
+
+// Returns the index of the first bit that's set to 1
+func (i *Number) FirstBitSet() int {
+ for j := 0; j < i.num.BitLen(); j++ {
+ if i.num.Bit(j) > 0 {
+ return j
+ }
+ }
+
+ return i.num.BitLen()
+}
+
+// Variables
+
+var (
+ Zero = Uint(0)
+ One = Uint(1)
+ Two = Uint(2)
+ MaxUint256 = Uint(0).SetBytes(common.Hex2Bytes("ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff"))
+
+ MinOne = Int(-1)
+
+ // "typedefs"
+ Uint = Uint256
+ Int = Int256
+)
diff --git a/common/number/uint_test.go b/common/number/uint_test.go
new file mode 100644
index 000000000..262d584ed
--- /dev/null
+++ b/common/number/uint_test.go
@@ -0,0 +1,92 @@
+package number
+
+import (
+ "math/big"
+ "testing"
+
+ "github.com/ethereum/go-ethereum/common"
+)
+
+func TestSet(t *testing.T) {
+ a := Uint(0)
+ b := Uint(10)
+ a.Set(b)
+ if a.num.Cmp(b.num) != 0 {
+ t.Error("didn't compare", a, b)
+ }
+
+ c := Uint(0).SetBytes(common.Hex2Bytes("0a"))
+ if c.num.Cmp(big.NewInt(10)) != 0 {
+ t.Error("c set bytes failed.")
+ }
+}
+
+func TestInitialiser(t *testing.T) {
+ check := false
+ init := NewInitialiser(func(x *Number) *Number {
+ check = true
+ return x
+ })
+ a := init(0).Add(init(1), init(2))
+ if a.Cmp(init(3)) != 0 {
+ t.Error("expected 3. got", a)
+ }
+ if !check {
+ t.Error("expected limiter to be called")
+ }
+}
+
+func TestGet(t *testing.T) {
+ a := Uint(10)
+ if a.Uint64() != 10 {
+ t.Error("expected to get 10. got", a.Uint64())
+ }
+
+ a = Uint(10)
+ if a.Int64() != 10 {
+ t.Error("expected to get 10. got", a.Int64())
+ }
+}
+
+func TestCmp(t *testing.T) {
+ a := Uint(10)
+ b := Uint(10)
+ c := Uint(11)
+
+ if a.Cmp(b) != 0 {
+ t.Error("a b == 0 failed", a, b)
+ }
+
+ if a.Cmp(c) >= 0 {
+ t.Error("a c < 0 failed", a, c)
+ }
+
+ if c.Cmp(b) <= 0 {
+ t.Error("c b > 0 failed", c, b)
+ }
+}
+
+func TestMaxArith(t *testing.T) {
+ a := Uint(0).Add(MaxUint256, One)
+ if a.Cmp(Zero) != 0 {
+ t.Error("expected max256 + 1 = 0 got", a)
+ }
+
+ a = Uint(0).Sub(Uint(0), One)
+ if a.Cmp(MaxUint256) != 0 {
+ t.Error("expected 0 - 1 = max256 got", a)
+ }
+
+ a = Int(0).Sub(Int(0), One)
+ if a.Cmp(MinOne) != 0 {
+ t.Error("expected 0 - 1 = -1 got", a)
+ }
+}
+
+func TestConversion(t *testing.T) {
+ a := Int(-1)
+ b := a.Uint256()
+ if b.Cmp(MaxUint256) != 0 {
+ t.Error("expected -1 => unsigned to return max. got", b)
+ }
+}
diff --git a/common/package.go b/common/package.go
new file mode 100644
index 000000000..7f38d8e4d
--- /dev/null
+++ b/common/package.go
@@ -0,0 +1,123 @@
+package common
+
+import (
+ "archive/zip"
+ "encoding/json"
+ "fmt"
+ "io"
+ "io/ioutil"
+ "strings"
+)
+
+// Manifest object
+//
+// The manifest object holds all the relevant information supplied with the
+// the manifest specified in the package
+type Manifest struct {
+ Entry string
+ Height, Width int
+}
+
+// External package
+//
+// External package contains the main html file and manifest
+type ExtPackage struct {
+ EntryHtml string
+ Manifest *Manifest
+}
+
+// Read file
+//
+// Read a given compressed file and returns the read bytes.
+// Returns an error otherwise
+func ReadFile(f *zip.File) ([]byte, error) {
+ rc, err := f.Open()
+ if err != nil {
+ return nil, err
+ }
+ defer rc.Close()
+
+ content, err := ioutil.ReadAll(rc)
+ if err != nil {
+ return nil, err
+ }
+
+ return content, nil
+}
+
+// Reads manifest
+//
+// Reads and returns a manifest object. Returns error otherwise
+func ReadManifest(m []byte) (*Manifest, error) {
+ var manifest Manifest
+
+ dec := json.NewDecoder(strings.NewReader(string(m)))
+ if err := dec.Decode(&manifest); err == io.EOF {
+ } else if err != nil {
+ return nil, err
+ }
+
+ return &manifest, nil
+}
+
+// Find file in archive
+//
+// Returns the index of the given file name if it exists. -1 if file not found
+func FindFileInArchive(fn string, files []*zip.File) (index int) {
+ index = -1
+ // Find the manifest first
+ for i, f := range files {
+ if f.Name == fn {
+ index = i
+ }
+ }
+
+ return
+}
+
+// Open package
+//
+// Opens a prepared ethereum package
+// Reads the manifest file and determines file contents and returns and
+// the external package.
+func OpenPackage(fn string) (*ExtPackage, error) {
+ r, err := zip.OpenReader(fn)
+ if err != nil {
+ return nil, err
+ }
+ defer r.Close()
+
+ manifestIndex := FindFileInArchive("manifest.json", r.File)
+
+ if manifestIndex < 0 {
+ return nil, fmt.Errorf("No manifest file found in archive")
+ }
+
+ f, err := ReadFile(r.File[manifestIndex])
+ if err != nil {
+ return nil, err
+ }
+
+ manifest, err := ReadManifest(f)
+ if err != nil {
+ return nil, err
+ }
+
+ if manifest.Entry == "" {
+ return nil, fmt.Errorf("Entry file specified but appears to be empty: %s", manifest.Entry)
+ }
+
+ entryIndex := FindFileInArchive(manifest.Entry, r.File)
+ if entryIndex < 0 {
+ return nil, fmt.Errorf("Entry file not found: '%s'", manifest.Entry)
+ }
+
+ f, err = ReadFile(r.File[entryIndex])
+ if err != nil {
+ return nil, err
+ }
+
+ extPackage := &ExtPackage{string(f), manifest}
+
+ return extPackage, nil
+}
diff --git a/common/path.go b/common/path.go
new file mode 100644
index 000000000..a74a0d5bd
--- /dev/null
+++ b/common/path.go
@@ -0,0 +1,106 @@
+package common
+
+import (
+ "fmt"
+ "os"
+ "os/user"
+ "path"
+ "path/filepath"
+ "runtime"
+ "strings"
+
+ "github.com/kardianos/osext"
+)
+
+// MakeName creates a node name that follows the ethereum convention
+// for such names. It adds the operation system name and Go runtime version
+// the name.
+func MakeName(name, version string) string {
+ return fmt.Sprintf("%s/v%s/%s/%s", name, version, runtime.GOOS, runtime.Version())
+}
+
+func ExpandHomePath(p string) (path string) {
+ path = p
+
+ // Check in case of paths like "/something/~/something/"
+ if len(path) > 1 && path[:2] == "~/" {
+ usr, _ := user.Current()
+ dir := usr.HomeDir
+
+ path = strings.Replace(p, "~", dir, 1)
+ }
+
+ return
+}
+
+func FileExist(filePath string) bool {
+ _, err := os.Stat(filePath)
+ if err != nil && os.IsNotExist(err) {
+ return false
+ }
+
+ return true
+}
+
+func AbsolutePath(Datadir string, filename string) string {
+ if path.IsAbs(filename) {
+ return filename
+ }
+ return path.Join(Datadir, filename)
+}
+
+func DefaultAssetPath() string {
+ var assetPath string
+ pwd, _ := os.Getwd()
+ srcdir := path.Join(os.Getenv("GOPATH"), "src", "github.com", "ethereum", "go-ethereum", "cmd", "mist")
+
+ // If the current working directory is the go-ethereum dir
+ // assume a debug build and use the source directory as
+ // asset directory.
+ if pwd == srcdir {
+ assetPath = path.Join(pwd, "assets")
+ } else {
+ switch runtime.GOOS {
+ case "darwin":
+ // Get Binary Directory
+ exedir, _ := osext.ExecutableFolder()
+ assetPath = filepath.Join(exedir, "../Resources")
+ case "linux":
+ assetPath = "/usr/share/mist"
+ case "windows":
+ assetPath = "./assets"
+ default:
+ assetPath = "."
+ }
+ }
+
+ // Check if the assetPath exists. If not, try the source directory
+ // This happens when binary is run from outside cmd/mist directory
+ if _, err := os.Stat(assetPath); os.IsNotExist(err) {
+ assetPath = path.Join(srcdir, "assets")
+ }
+
+ return assetPath
+}
+
+func DefaultDataDir() string {
+ usr, _ := user.Current()
+ if runtime.GOOS == "darwin" {
+ return path.Join(usr.HomeDir, "Library/Ethereum")
+ } else if runtime.GOOS == "windows" {
+ return path.Join(usr.HomeDir, "AppData/Roaming/Ethereum")
+ } else {
+ return path.Join(usr.HomeDir, ".ethereum")
+ }
+}
+
+func IsWindows() bool {
+ return runtime.GOOS == "windows"
+}
+
+func WindonizePath(path string) string {
+ if string(path[0]) == "/" && IsWindows() {
+ path = path[1:]
+ }
+ return path
+}
diff --git a/common/path_test.go b/common/path_test.go
new file mode 100644
index 000000000..4b90c543b
--- /dev/null
+++ b/common/path_test.go
@@ -0,0 +1,36 @@
+package common
+
+import (
+ "os"
+ // "testing"
+
+ checker "gopkg.in/check.v1"
+)
+
+type CommonSuite struct{}
+
+var _ = checker.Suite(&CommonSuite{})
+
+func (s *CommonSuite) TestOS(c *checker.C) {
+ expwin := (os.PathSeparator == '\\' && os.PathListSeparator == ';')
+ res := IsWindows()
+
+ if !expwin {
+ c.Assert(res, checker.Equals, expwin, checker.Commentf("IsWindows is", res, "but path is", os.PathSeparator))
+ } else {
+ c.Assert(res, checker.Not(checker.Equals), expwin, checker.Commentf("IsWindows is", res, "but path is", os.PathSeparator))
+ }
+}
+
+func (s *CommonSuite) TestWindonziePath(c *checker.C) {
+ iswindowspath := os.PathSeparator == '\\'
+ path := "/opt/eth/test/file.ext"
+ res := WindonizePath(path)
+ ressep := string(res[0])
+
+ if !iswindowspath {
+ c.Assert(ressep, checker.Equals, "/")
+ } else {
+ c.Assert(ressep, checker.Not(checker.Equals), "/")
+ }
+}
diff --git a/common/rlp.go b/common/rlp.go
new file mode 100644
index 000000000..06ac410e9
--- /dev/null
+++ b/common/rlp.go
@@ -0,0 +1,276 @@
+package common
+
+import (
+ "bytes"
+ "fmt"
+ "math/big"
+ "reflect"
+)
+
+type RlpEncode interface {
+ RlpEncode() []byte
+}
+
+type RlpEncodeDecode interface {
+ RlpEncode
+ RlpValue() []interface{}
+}
+
+type RlpEncodable interface {
+ RlpData() interface{}
+}
+
+func Rlp(encoder RlpEncode) []byte {
+ return encoder.RlpEncode()
+}
+
+type RlpEncoder struct {
+ rlpData []byte
+}
+
+func NewRlpEncoder() *RlpEncoder {
+ encoder := &RlpEncoder{}
+
+ return encoder
+}
+func (coder *RlpEncoder) EncodeData(rlpData interface{}) []byte {
+ return Encode(rlpData)
+}
+
+const (
+ RlpEmptyList = 0x80
+ RlpEmptyStr = 0x40
+)
+
+const rlpEof = -1
+
+func Char(c []byte) int {
+ if len(c) > 0 {
+ return int(c[0])
+ }
+
+ return rlpEof
+}
+
+func DecodeWithReader(reader *bytes.Buffer) interface{} {
+ var slice []interface{}
+
+ // Read the next byte
+ char := Char(reader.Next(1))
+ switch {
+ case char <= 0x7f:
+ return char
+
+ case char <= 0xb7:
+ return reader.Next(int(char - 0x80))
+
+ case char <= 0xbf:
+ length := ReadVarInt(reader.Next(int(char - 0xb7)))
+
+ return reader.Next(int(length))
+
+ case char <= 0xf7:
+ length := int(char - 0xc0)
+ for i := 0; i < length; i++ {
+ obj := DecodeWithReader(reader)
+ slice = append(slice, obj)
+ }
+
+ return slice
+ case char <= 0xff:
+ length := ReadVarInt(reader.Next(int(char - 0xf7)))
+ for i := uint64(0); i < length; i++ {
+ obj := DecodeWithReader(reader)
+ slice = append(slice, obj)
+ }
+
+ return slice
+ default:
+ panic(fmt.Sprintf("byte not supported: %q", char))
+ }
+
+ return slice
+}
+
+var (
+ directRlp = big.NewInt(0x7f)
+ numberRlp = big.NewInt(0xb7)
+ zeroRlp = big.NewInt(0x0)
+)
+
+func intlen(i int64) (length int) {
+ for i > 0 {
+ i = i >> 8
+ length++
+ }
+ return
+}
+
+func Encode(object interface{}) []byte {
+ var buff bytes.Buffer
+
+ if object != nil {
+ switch t := object.(type) {
+ case *Value:
+ buff.Write(Encode(t.Val))
+ case RlpEncodable:
+ buff.Write(Encode(t.RlpData()))
+ // Code dup :-/
+ case int:
+ buff.Write(Encode(big.NewInt(int64(t))))
+ case uint:
+ buff.Write(Encode(big.NewInt(int64(t))))
+ case int8:
+ buff.Write(Encode(big.NewInt(int64(t))))
+ case int16:
+ buff.Write(Encode(big.NewInt(int64(t))))
+ case int32:
+ buff.Write(Encode(big.NewInt(int64(t))))
+ case int64:
+ buff.Write(Encode(big.NewInt(t)))
+ case uint16:
+ buff.Write(Encode(big.NewInt(int64(t))))
+ case uint32:
+ buff.Write(Encode(big.NewInt(int64(t))))
+ case uint64:
+ buff.Write(Encode(big.NewInt(int64(t))))
+ case byte:
+ buff.Write(Encode(big.NewInt(int64(t))))
+ case *big.Int:
+ // Not sure how this is possible while we check for nil
+ if t == nil {
+ buff.WriteByte(0xc0)
+ } else {
+ buff.Write(Encode(t.Bytes()))
+ }
+ case Bytes:
+ buff.Write(Encode([]byte(t)))
+ case []byte:
+ if len(t) == 1 && t[0] <= 0x7f {
+ buff.Write(t)
+ } else if len(t) < 56 {
+ buff.WriteByte(byte(len(t) + 0x80))
+ buff.Write(t)
+ } else {
+ b := big.NewInt(int64(len(t)))
+ buff.WriteByte(byte(len(b.Bytes()) + 0xb7))
+ buff.Write(b.Bytes())
+ buff.Write(t)
+ }
+ case string:
+ buff.Write(Encode([]byte(t)))
+ case []interface{}:
+ // Inline function for writing the slice header
+ WriteSliceHeader := func(length int) {
+ if length < 56 {
+ buff.WriteByte(byte(length + 0xc0))
+ } else {
+ b := big.NewInt(int64(length))
+ buff.WriteByte(byte(len(b.Bytes()) + 0xf7))
+ buff.Write(b.Bytes())
+ }
+ }
+
+ var b bytes.Buffer
+ for _, val := range t {
+ b.Write(Encode(val))
+ }
+ WriteSliceHeader(len(b.Bytes()))
+ buff.Write(b.Bytes())
+ default:
+ // This is how it should have been from the start
+ // needs refactoring (@fjl)
+ v := reflect.ValueOf(t)
+ switch v.Kind() {
+ case reflect.Slice:
+ var b bytes.Buffer
+ for i := 0; i < v.Len(); i++ {
+ b.Write(Encode(v.Index(i).Interface()))
+ }
+
+ blen := b.Len()
+ if blen < 56 {
+ buff.WriteByte(byte(blen) + 0xc0)
+ } else {
+ ilen := byte(intlen(int64(blen)))
+ buff.WriteByte(ilen + 0xf7)
+ t := make([]byte, ilen)
+ for i := byte(0); i < ilen; i++ {
+ t[ilen-i-1] = byte(blen >> (i * 8))
+ }
+ buff.Write(t)
+ }
+ buff.ReadFrom(&b)
+ }
+ }
+ } else {
+ // Empty list for nil
+ buff.WriteByte(0xc0)
+ }
+
+ return buff.Bytes()
+}
+
+// TODO Use a bytes.Buffer instead of a raw byte slice.
+// Cleaner code, and use draining instead of seeking the next bytes to read
+func Decode(data []byte, pos uint64) (interface{}, uint64) {
+ var slice []interface{}
+ char := int(data[pos])
+ switch {
+ case char <= 0x7f:
+ return data[pos], pos + 1
+
+ case char <= 0xb7:
+ b := uint64(data[pos]) - 0x80
+
+ return data[pos+1 : pos+1+b], pos + 1 + b
+
+ case char <= 0xbf:
+ b := uint64(data[pos]) - 0xb7
+
+ b2 := ReadVarInt(data[pos+1 : pos+1+b])
+
+ return data[pos+1+b : pos+1+b+b2], pos + 1 + b + b2
+
+ case char <= 0xf7:
+ b := uint64(data[pos]) - 0xc0
+ prevPos := pos
+ pos++
+ for i := uint64(0); i < b; {
+ var obj interface{}
+
+ // Get the next item in the data list and append it
+ obj, prevPos = Decode(data, pos)
+ slice = append(slice, obj)
+
+ // Increment i by the amount bytes read in the previous
+ // read
+ i += (prevPos - pos)
+ pos = prevPos
+ }
+ return slice, pos
+
+ case char <= 0xff:
+ l := uint64(data[pos]) - 0xf7
+ b := ReadVarInt(data[pos+1 : pos+1+l])
+
+ pos = pos + l + 1
+
+ prevPos := b
+ for i := uint64(0); i < uint64(b); {
+ var obj interface{}
+
+ obj, prevPos = Decode(data, pos)
+ slice = append(slice, obj)
+
+ i += (prevPos - pos)
+ pos = prevPos
+ }
+ return slice, pos
+
+ default:
+ panic(fmt.Sprintf("byte not supported: %q", char))
+ }
+
+ return slice, 0
+}
diff --git a/common/rlp_test.go b/common/rlp_test.go
new file mode 100644
index 000000000..2a55da928
--- /dev/null
+++ b/common/rlp_test.go
@@ -0,0 +1,160 @@
+package common
+
+import (
+ "bytes"
+ "math/big"
+ "reflect"
+ "testing"
+
+ "github.com/ethereum/go-ethereum/rlp"
+)
+
+func TestNonInterfaceSlice(t *testing.T) {
+ vala := []string{"value1", "value2", "value3"}
+ valb := []interface{}{"value1", "value2", "value3"}
+ resa := Encode(vala)
+ resb := Encode(valb)
+ if !bytes.Equal(resa, resb) {
+ t.Errorf("expected []string & []interface{} to be equal")
+ }
+}
+
+func TestRlpValueEncoding(t *testing.T) {
+ val := EmptyValue()
+ val.AppendList().Append(byte(1)).Append(byte(2)).Append(byte(3))
+ val.Append("4").AppendList().Append(byte(5))
+
+ res, err := rlp.EncodeToBytes(val)
+ if err != nil {
+ t.Fatalf("encode error: %v", err)
+ }
+ exp := Encode([]interface{}{[]interface{}{1, 2, 3}, "4", []interface{}{5}})
+ if bytes.Compare(res, exp) != 0 {
+ t.Errorf("expected %x, got %x", exp, res)
+ }
+}
+
+func TestValueSlice(t *testing.T) {
+ val := []interface{}{
+ "value1",
+ "valeu2",
+ "value3",
+ }
+
+ value := NewValue(val)
+ splitVal := value.SliceFrom(1)
+
+ if splitVal.Len() != 2 {
+ t.Error("SliceFrom: Expected len", 2, "got", splitVal.Len())
+ }
+
+ splitVal = value.SliceTo(2)
+ if splitVal.Len() != 2 {
+ t.Error("SliceTo: Expected len", 2, "got", splitVal.Len())
+ }
+
+ splitVal = value.SliceFromTo(1, 3)
+ if splitVal.Len() != 2 {
+ t.Error("SliceFromTo: Expected len", 2, "got", splitVal.Len())
+ }
+}
+
+func TestLargeData(t *testing.T) {
+ data := make([]byte, 100000)
+ enc := Encode(data)
+ value := NewValueFromBytes(enc)
+ if value.Len() != len(data) {
+ t.Error("Expected data to be", len(data), "got", value.Len())
+ }
+}
+
+func TestValue(t *testing.T) {
+ value := NewValueFromBytes([]byte("\xcd\x83dog\x83god\x83cat\x01"))
+ if value.Get(0).Str() != "dog" {
+ t.Errorf("expected '%v', got '%v'", value.Get(0).Str(), "dog")
+ }
+
+ if value.Get(3).Uint() != 1 {
+ t.Errorf("expected '%v', got '%v'", value.Get(3).Uint(), 1)
+ }
+}
+
+func TestEncode(t *testing.T) {
+ strRes := "\x83dog"
+ bytes := Encode("dog")
+
+ str := string(bytes)
+ if str != strRes {
+ t.Errorf("Expected %q, got %q", strRes, str)
+ }
+
+ sliceRes := "\xcc\x83dog\x83god\x83cat"
+ strs := []interface{}{"dog", "god", "cat"}
+ bytes = Encode(strs)
+ slice := string(bytes)
+ if slice != sliceRes {
+ t.Error("Expected %q, got %q", sliceRes, slice)
+ }
+
+ intRes := "\x82\x04\x00"
+ bytes = Encode(1024)
+ if string(bytes) != intRes {
+ t.Errorf("Expected %q, got %q", intRes, bytes)
+ }
+}
+
+func TestDecode(t *testing.T) {
+ single := []byte("\x01")
+ b, _ := Decode(single, 0)
+
+ if b.(uint8) != 1 {
+ t.Errorf("Expected 1, got %q", b)
+ }
+
+ str := []byte("\x83dog")
+ b, _ = Decode(str, 0)
+ if bytes.Compare(b.([]byte), []byte("dog")) != 0 {
+ t.Errorf("Expected dog, got %q", b)
+ }
+
+ slice := []byte("\xcc\x83dog\x83god\x83cat")
+ res := []interface{}{"dog", "god", "cat"}
+ b, _ = Decode(slice, 0)
+ if reflect.DeepEqual(b, res) {
+ t.Errorf("Expected %q, got %q", res, b)
+ }
+}
+
+func TestEncodeDecodeBigInt(t *testing.T) {
+ bigInt := big.NewInt(1391787038)
+ encoded := Encode(bigInt)
+
+ value := NewValueFromBytes(encoded)
+ if value.BigInt().Cmp(bigInt) != 0 {
+ t.Errorf("Expected %v, got %v", bigInt, value.BigInt())
+ }
+}
+
+func TestEncodeDecodeBytes(t *testing.T) {
+ bv := NewValue([]interface{}{[]byte{1, 2, 3, 4, 5}, []byte{6}})
+ b, _ := rlp.EncodeToBytes(bv)
+ val := NewValueFromBytes(b)
+ if !bv.Cmp(val) {
+ t.Errorf("Expected %#v, got %#v", bv, val)
+ }
+}
+
+func TestEncodeZero(t *testing.T) {
+ b, _ := rlp.EncodeToBytes(NewValue(0))
+ exp := []byte{0xc0}
+ if bytes.Compare(b, exp) == 0 {
+ t.Error("Expected", exp, "got", b)
+ }
+}
+
+func BenchmarkEncodeDecode(b *testing.B) {
+ for i := 0; i < b.N; i++ {
+ bytes := Encode([]interface{}{"dog", "god", "cat"})
+ Decode(bytes, 0)
+ }
+}
diff --git a/common/size.go b/common/size.go
new file mode 100644
index 000000000..0d9dbf558
--- /dev/null
+++ b/common/size.go
@@ -0,0 +1,79 @@
+package common
+
+import (
+ "fmt"
+ "math/big"
+)
+
+type StorageSize float64
+
+func (self StorageSize) String() string {
+ if self > 1000000 {
+ return fmt.Sprintf("%.2f mB", self/1000000)
+ } else if self > 1000 {
+ return fmt.Sprintf("%.2f kB", self/1000)
+ } else {
+ return fmt.Sprintf("%.2f B", self)
+ }
+}
+
+func (self StorageSize) Int64() int64 {
+ return int64(self)
+}
+
+// The different number of units
+var (
+ Douglas = BigPow(10, 42)
+ Einstein = BigPow(10, 21)
+ Ether = BigPow(10, 18)
+ Finney = BigPow(10, 15)
+ Szabo = BigPow(10, 12)
+ Shannon = BigPow(10, 9)
+ Babbage = BigPow(10, 6)
+ Ada = BigPow(10, 3)
+ Wei = big.NewInt(1)
+)
+
+//
+// Currency to string
+// Returns a string representing a human readable format
+func CurrencyToString(num *big.Int) string {
+ var (
+ fin *big.Int = num
+ denom string = "Wei"
+ )
+
+ switch {
+ case num.Cmp(Douglas) >= 0:
+ fin = new(big.Int).Div(num, Douglas)
+ denom = "Douglas"
+ case num.Cmp(Einstein) >= 0:
+ fin = new(big.Int).Div(num, Einstein)
+ denom = "Einstein"
+ case num.Cmp(Ether) >= 0:
+ fin = new(big.Int).Div(num, Ether)
+ denom = "Ether"
+ case num.Cmp(Finney) >= 0:
+ fin = new(big.Int).Div(num, Finney)
+ denom = "Finney"
+ case num.Cmp(Szabo) >= 0:
+ fin = new(big.Int).Div(num, Szabo)
+ denom = "Szabo"
+ case num.Cmp(Shannon) >= 0:
+ fin = new(big.Int).Div(num, Shannon)
+ denom = "Shannon"
+ case num.Cmp(Babbage) >= 0:
+ fin = new(big.Int).Div(num, Babbage)
+ denom = "Babbage"
+ case num.Cmp(Ada) >= 0:
+ fin = new(big.Int).Div(num, Ada)
+ denom = "Ada"
+ }
+
+ // TODO add comment clarifying expected behavior
+ if len(fin.String()) > 5 {
+ return fmt.Sprintf("%sE%d %s", fin.String()[0:5], len(fin.String())-5, denom)
+ }
+
+ return fmt.Sprintf("%v %s", fin, denom)
+}
diff --git a/common/size_test.go b/common/size_test.go
new file mode 100644
index 000000000..1cbeff0a8
--- /dev/null
+++ b/common/size_test.go
@@ -0,0 +1,57 @@
+package common
+
+import (
+ "math/big"
+
+ checker "gopkg.in/check.v1"
+)
+
+type SizeSuite struct{}
+
+var _ = checker.Suite(&SizeSuite{})
+
+func (s *SizeSuite) TestStorageSizeString(c *checker.C) {
+ data1 := 2381273
+ data2 := 2192
+ data3 := 12
+
+ exp1 := "2.38 mB"
+ exp2 := "2.19 kB"
+ exp3 := "12.00 B"
+
+ c.Assert(StorageSize(data1).String(), checker.Equals, exp1)
+ c.Assert(StorageSize(data2).String(), checker.Equals, exp2)
+ c.Assert(StorageSize(data3).String(), checker.Equals, exp3)
+}
+
+func (s *CommonSuite) TestCommon(c *checker.C) {
+ douglas := CurrencyToString(BigPow(10, 43))
+ einstein := CurrencyToString(BigPow(10, 22))
+ ether := CurrencyToString(BigPow(10, 19))
+ finney := CurrencyToString(BigPow(10, 16))
+ szabo := CurrencyToString(BigPow(10, 13))
+ shannon := CurrencyToString(BigPow(10, 10))
+ babbage := CurrencyToString(BigPow(10, 7))
+ ada := CurrencyToString(BigPow(10, 4))
+ wei := CurrencyToString(big.NewInt(10))
+
+ c.Assert(douglas, checker.Equals, "10 Douglas")
+ c.Assert(einstein, checker.Equals, "10 Einstein")
+ c.Assert(ether, checker.Equals, "10 Ether")
+ c.Assert(finney, checker.Equals, "10 Finney")
+ c.Assert(szabo, checker.Equals, "10 Szabo")
+ c.Assert(shannon, checker.Equals, "10 Shannon")
+ c.Assert(babbage, checker.Equals, "10 Babbage")
+ c.Assert(ada, checker.Equals, "10 Ada")
+ c.Assert(wei, checker.Equals, "10 Wei")
+}
+
+func (s *CommonSuite) TestLarge(c *checker.C) {
+ douglaslarge := CurrencyToString(BigPow(100000000, 43))
+ adalarge := CurrencyToString(BigPow(100000000, 4))
+ weilarge := CurrencyToString(big.NewInt(100000000))
+
+ c.Assert(douglaslarge, checker.Equals, "10000E298 Douglas")
+ c.Assert(adalarge, checker.Equals, "10000E7 Einstein")
+ c.Assert(weilarge, checker.Equals, "100 Babbage")
+}
diff --git a/common/types.go b/common/types.go
new file mode 100644
index 000000000..daefcde11
--- /dev/null
+++ b/common/types.go
@@ -0,0 +1,84 @@
+package common
+
+import "math/big"
+
+const (
+ hashLength = 32
+ addressLength = 20
+)
+
+type (
+ Hash [hashLength]byte
+ Address [addressLength]byte
+)
+
+func BytesToHash(b []byte) Hash {
+ var h Hash
+ h.SetBytes(b)
+ return h
+}
+func StringToHash(s string) Hash { return BytesToHash([]byte(s)) }
+func BigToHash(b *big.Int) Hash { return BytesToHash(b.Bytes()) }
+func HexToHash(s string) Hash { return BytesToHash(FromHex(s)) }
+
+// Don't use the default 'String' method in case we want to overwrite
+
+// Get the string representation of the underlying hash
+func (h Hash) Str() string { return string(h[:]) }
+func (h Hash) Bytes() []byte { return h[:] }
+func (h Hash) Big() *big.Int { return Bytes2Big(h[:]) }
+func (h Hash) Hex() string { return "0x" + Bytes2Hex(h[:]) }
+
+// Sets the hash to the value of b. If b is larger than len(h) it will panic
+func (h *Hash) SetBytes(b []byte) {
+ if len(b) > len(h) {
+ b = b[len(b)-hashLength:]
+ }
+
+ copy(h[hashLength-len(b):], b)
+}
+
+// Set string `s` to h. If s is larger than len(h) it will panic
+func (h *Hash) SetString(s string) { h.SetBytes([]byte(s)) }
+
+// Sets h to other
+func (h *Hash) Set(other Hash) {
+ for i, v := range other {
+ h[i] = v
+ }
+}
+
+/////////// Address
+func BytesToAddress(b []byte) Address {
+ var a Address
+ a.SetBytes(b)
+ return a
+}
+func StringToAddress(s string) Address { return BytesToAddress([]byte(s)) }
+func BigToAddress(b *big.Int) Address { return BytesToAddress(b.Bytes()) }
+func HexToAddress(s string) Address { return BytesToAddress(FromHex(s)) }
+
+// Get the string representation of the underlying address
+func (a Address) Str() string { return string(a[:]) }
+func (a Address) Bytes() []byte { return a[:] }
+func (a Address) Big() *big.Int { return Bytes2Big(a[:]) }
+func (a Address) Hash() Hash { return BytesToHash(a[:]) }
+func (a Address) Hex() string { return "0x" + Bytes2Hex(a[:]) }
+
+// Sets the address to the value of b. If b is larger than len(a) it will panic
+func (a *Address) SetBytes(b []byte) {
+ if len(b) > len(a) {
+ b = b[len(b)-addressLength:]
+ }
+ copy(a[addressLength-len(b):], b)
+}
+
+// Set string `s` to a. If s is larger than len(a) it will panic
+func (a *Address) SetString(s string) { a.SetBytes([]byte(s)) }
+
+// Sets a to other
+func (a *Address) Set(other Address) {
+ for i, v := range other {
+ a[i] = v
+ }
+}
diff --git a/common/types_template.go b/common/types_template.go
new file mode 100644
index 000000000..1c82a36dc
--- /dev/null
+++ b/common/types_template.go
@@ -0,0 +1,48 @@
+// +build none
+//sed -e 's/_N_/Hash/g' -e 's/_S_/32/g' -e '1d' types_template.go | gofmt -w hash.go
+
+package common
+
+import "math/big"
+
+type _N_ [_S_]byte
+
+func BytesTo_N_(b []byte) _N_ {
+ var h _N_
+ h.SetBytes(b)
+ return h
+}
+func StringTo_N_(s string) _N_ { return BytesTo_N_([]byte(s)) }
+func BigTo_N_(b *big.Int) _N_ { return BytesTo_N_(b.Bytes()) }
+func HexTo_N_(s string) _N_ { return BytesTo_N_(FromHex(s)) }
+
+// Don't use the default 'String' method in case we want to overwrite
+
+// Get the string representation of the underlying hash
+func (h _N_) Str() string { return string(h[:]) }
+func (h _N_) Bytes() []byte { return h[:] }
+func (h _N_) Big() *big.Int { return Bytes2Big(h[:]) }
+func (h _N_) Hex() string { return "0x" + Bytes2Hex(h[:]) }
+
+// Sets the hash to the value of b. If b is larger than len(h) it will panic
+func (h *_N_) SetBytes(b []byte) {
+ // Use the right most bytes
+ if len(b) > len(h) {
+ b = b[len(b)-_S_:]
+ }
+
+ // Reverse the loop
+ for i := len(b) - 1; i >= 0; i-- {
+ h[_S_-len(b)+i] = b[i]
+ }
+}
+
+// Set string `s` to h. If s is larger than len(h) it will panic
+func (h *_N_) SetString(s string) { h.SetBytes([]byte(s)) }
+
+// Sets h to other
+func (h *_N_) Set(other _N_) {
+ for i, v := range other {
+ h[i] = v
+ }
+}
diff --git a/common/types_test.go b/common/types_test.go
new file mode 100644
index 000000000..9f303152c
--- /dev/null
+++ b/common/types_test.go
@@ -0,0 +1,15 @@
+package common
+
+import "testing"
+
+func TestBytesConversion(t *testing.T) {
+ bytes := []byte{5}
+ hash := BytesToHash(bytes)
+
+ var exp Hash
+ exp[31] = 5
+
+ if hash != exp {
+ t.Errorf("expected %x got %x", exp, hash)
+ }
+}
diff --git a/common/value.go b/common/value.go
new file mode 100644
index 000000000..c3893d565
--- /dev/null
+++ b/common/value.go
@@ -0,0 +1,412 @@
+package common
+
+import (
+ "bytes"
+ "fmt"
+ "io"
+ "math/big"
+ "reflect"
+ "strconv"
+
+ "github.com/ethereum/go-ethereum/rlp"
+)
+
+// Value can hold values of certain basic types and provides ways to
+// convert between types without bothering to check whether the
+// conversion is actually meaningful.
+//
+// It currently supports the following types:
+//
+// - int{,8,16,32,64}
+// - uint{,8,16,32,64}
+// - *big.Int
+// - []byte, string
+// - []interface{}
+//
+// Value is useful whenever you feel that Go's types limit your
+// ability to express yourself. In these situations, use Value and
+// forget about this strong typing nonsense.
+type Value struct{ Val interface{} }
+
+func (val *Value) String() string {
+ return fmt.Sprintf("%x", val.Val)
+}
+
+func NewValue(val interface{}) *Value {
+ t := val
+ if v, ok := val.(*Value); ok {
+ t = v.Val
+ }
+
+ return &Value{Val: t}
+}
+
+func (val *Value) Type() reflect.Kind {
+ return reflect.TypeOf(val.Val).Kind()
+}
+
+func (val *Value) IsNil() bool {
+ return val.Val == nil
+}
+
+func (val *Value) Len() int {
+ if data, ok := val.Val.([]interface{}); ok {
+ return len(data)
+ }
+
+ return len(val.Bytes())
+}
+
+func (val *Value) Uint() uint64 {
+ if Val, ok := val.Val.(uint8); ok {
+ return uint64(Val)
+ } else if Val, ok := val.Val.(uint16); ok {
+ return uint64(Val)
+ } else if Val, ok := val.Val.(uint32); ok {
+ return uint64(Val)
+ } else if Val, ok := val.Val.(uint64); ok {
+ return Val
+ } else if Val, ok := val.Val.(float32); ok {
+ return uint64(Val)
+ } else if Val, ok := val.Val.(float64); ok {
+ return uint64(Val)
+ } else if Val, ok := val.Val.(int); ok {
+ return uint64(Val)
+ } else if Val, ok := val.Val.(uint); ok {
+ return uint64(Val)
+ } else if Val, ok := val.Val.([]byte); ok {
+ return new(big.Int).SetBytes(Val).Uint64()
+ } else if Val, ok := val.Val.(*big.Int); ok {
+ return Val.Uint64()
+ }
+
+ return 0
+}
+
+func (val *Value) Int() int64 {
+ if Val, ok := val.Val.(int8); ok {
+ return int64(Val)
+ } else if Val, ok := val.Val.(int16); ok {
+ return int64(Val)
+ } else if Val, ok := val.Val.(int32); ok {
+ return int64(Val)
+ } else if Val, ok := val.Val.(int64); ok {
+ return Val
+ } else if Val, ok := val.Val.(int); ok {
+ return int64(Val)
+ } else if Val, ok := val.Val.(float32); ok {
+ return int64(Val)
+ } else if Val, ok := val.Val.(float64); ok {
+ return int64(Val)
+ } else if Val, ok := val.Val.([]byte); ok {
+ return new(big.Int).SetBytes(Val).Int64()
+ } else if Val, ok := val.Val.(*big.Int); ok {
+ return Val.Int64()
+ } else if Val, ok := val.Val.(string); ok {
+ n, _ := strconv.Atoi(Val)
+ return int64(n)
+ }
+
+ return 0
+}
+
+func (val *Value) Byte() byte {
+ if Val, ok := val.Val.(byte); ok {
+ return Val
+ }
+
+ return 0x0
+}
+
+func (val *Value) BigInt() *big.Int {
+ if a, ok := val.Val.([]byte); ok {
+ b := new(big.Int).SetBytes(a)
+
+ return b
+ } else if a, ok := val.Val.(*big.Int); ok {
+ return a
+ } else if a, ok := val.Val.(string); ok {
+ return Big(a)
+ } else {
+ return big.NewInt(int64(val.Uint()))
+ }
+
+ return big.NewInt(0)
+}
+
+func (val *Value) Str() string {
+ if a, ok := val.Val.([]byte); ok {
+ return string(a)
+ } else if a, ok := val.Val.(string); ok {
+ return a
+ } else if a, ok := val.Val.(byte); ok {
+ return string(a)
+ }
+
+ return ""
+}
+
+func (val *Value) Bytes() []byte {
+ if a, ok := val.Val.([]byte); ok {
+ return a
+ } else if s, ok := val.Val.(byte); ok {
+ return []byte{s}
+ } else if s, ok := val.Val.(string); ok {
+ return []byte(s)
+ } else if s, ok := val.Val.(*big.Int); ok {
+ return s.Bytes()
+ } else {
+ return big.NewInt(val.Int()).Bytes()
+ }
+
+ return []byte{}
+}
+
+func (val *Value) Err() error {
+ if err, ok := val.Val.(error); ok {
+ return err
+ }
+
+ return nil
+}
+
+func (val *Value) Slice() []interface{} {
+ if d, ok := val.Val.([]interface{}); ok {
+ return d
+ }
+
+ return []interface{}{}
+}
+
+func (val *Value) SliceFrom(from int) *Value {
+ slice := val.Slice()
+
+ return NewValue(slice[from:])
+}
+
+func (val *Value) SliceTo(to int) *Value {
+ slice := val.Slice()
+
+ return NewValue(slice[:to])
+}
+
+func (val *Value) SliceFromTo(from, to int) *Value {
+ slice := val.Slice()
+
+ return NewValue(slice[from:to])
+}
+
+// TODO More type checking methods
+func (val *Value) IsSlice() bool {
+ return val.Type() == reflect.Slice
+}
+
+func (val *Value) IsStr() bool {
+ return val.Type() == reflect.String
+}
+
+func (self *Value) IsErr() bool {
+ _, ok := self.Val.(error)
+ return ok
+}
+
+// Special list checking function. Something is considered
+// a list if it's of type []interface{}. The list is usually
+// used in conjunction with rlp decoded streams.
+func (val *Value) IsList() bool {
+ _, ok := val.Val.([]interface{})
+
+ return ok
+}
+
+func (val *Value) IsEmpty() bool {
+ return val.Val == nil || ((val.IsSlice() || val.IsStr()) && val.Len() == 0)
+}
+
+// Threat the value as a slice
+func (val *Value) Get(idx int) *Value {
+ if d, ok := val.Val.([]interface{}); ok {
+ // Guard for oob
+ if len(d) <= idx {
+ return NewValue(nil)
+ }
+
+ if idx < 0 {
+ return NewValue(nil)
+ }
+
+ return NewValue(d[idx])
+ }
+
+ // If this wasn't a slice you probably shouldn't be using this function
+ return NewValue(nil)
+}
+
+func (self *Value) Copy() *Value {
+ switch val := self.Val.(type) {
+ case *big.Int:
+ return NewValue(new(big.Int).Set(val))
+ case []byte:
+ return NewValue(CopyBytes(val))
+ default:
+ return NewValue(self.Val)
+ }
+
+ return nil
+}
+
+func (val *Value) Cmp(o *Value) bool {
+ return reflect.DeepEqual(val.Val, o.Val)
+}
+
+func (self *Value) DeepCmp(o *Value) bool {
+ return bytes.Compare(self.Bytes(), o.Bytes()) == 0
+}
+
+func (self *Value) DecodeRLP(s *rlp.Stream) error {
+ var v interface{}
+ if err := s.Decode(&v); err != nil {
+ return err
+ }
+ self.Val = v
+ return nil
+}
+
+func (self *Value) EncodeRLP(w io.Writer) error {
+ if self == nil {
+ w.Write(rlp.EmptyList)
+ return nil
+ } else {
+ return rlp.Encode(w, self.Val)
+ }
+}
+
+// NewValueFromBytes decodes RLP data.
+// The contained value will be nil if data contains invalid RLP.
+func NewValueFromBytes(data []byte) *Value {
+ v := new(Value)
+ if len(data) != 0 {
+ if err := rlp.DecodeBytes(data, v); err != nil {
+ v.Val = nil
+ }
+ }
+ return v
+}
+
+// Value setters
+func NewSliceValue(s interface{}) *Value {
+ list := EmptyValue()
+
+ if s != nil {
+ if slice, ok := s.([]interface{}); ok {
+ for _, val := range slice {
+ list.Append(val)
+ }
+ } else if slice, ok := s.([]string); ok {
+ for _, val := range slice {
+ list.Append(val)
+ }
+ }
+ }
+
+ return list
+}
+
+func EmptyValue() *Value {
+ return NewValue([]interface{}{})
+}
+
+func (val *Value) AppendList() *Value {
+ list := EmptyValue()
+ val.Val = append(val.Slice(), list)
+
+ return list
+}
+
+func (val *Value) Append(v interface{}) *Value {
+ val.Val = append(val.Slice(), v)
+
+ return val
+}
+
+const (
+ valOpAdd = iota
+ valOpDiv
+ valOpMul
+ valOpPow
+ valOpSub
+)
+
+// Math stuff
+func (self *Value) doOp(op int, other interface{}) *Value {
+ left := self.BigInt()
+ right := NewValue(other).BigInt()
+
+ switch op {
+ case valOpAdd:
+ self.Val = left.Add(left, right)
+ case valOpDiv:
+ self.Val = left.Div(left, right)
+ case valOpMul:
+ self.Val = left.Mul(left, right)
+ case valOpPow:
+ self.Val = left.Exp(left, right, Big0)
+ case valOpSub:
+ self.Val = left.Sub(left, right)
+ }
+
+ return self
+}
+
+func (self *Value) Add(other interface{}) *Value {
+ return self.doOp(valOpAdd, other)
+}
+
+func (self *Value) Sub(other interface{}) *Value {
+ return self.doOp(valOpSub, other)
+}
+
+func (self *Value) Div(other interface{}) *Value {
+ return self.doOp(valOpDiv, other)
+}
+
+func (self *Value) Mul(other interface{}) *Value {
+ return self.doOp(valOpMul, other)
+}
+
+func (self *Value) Pow(other interface{}) *Value {
+ return self.doOp(valOpPow, other)
+}
+
+type ValueIterator struct {
+ value *Value
+ currentValue *Value
+ idx int
+}
+
+func (val *Value) NewIterator() *ValueIterator {
+ return &ValueIterator{value: val}
+}
+
+func (it *ValueIterator) Len() int {
+ return it.value.Len()
+}
+
+func (it *ValueIterator) Next() bool {
+ if it.idx >= it.value.Len() {
+ return false
+ }
+
+ it.currentValue = it.value.Get(it.idx)
+ it.idx++
+
+ return true
+}
+
+func (it *ValueIterator) Value() *Value {
+ return it.currentValue
+}
+
+func (it *ValueIterator) Idx() int {
+ return it.idx - 1
+}
diff --git a/common/value_test.go b/common/value_test.go
new file mode 100644
index 000000000..38a0e9843
--- /dev/null
+++ b/common/value_test.go
@@ -0,0 +1,70 @@
+package common
+
+import (
+ "math/big"
+
+ checker "gopkg.in/check.v1"
+)
+
+type ValueSuite struct{}
+
+var _ = checker.Suite(&ValueSuite{})
+
+func (s *ValueSuite) TestValueCmp(c *checker.C) {
+ val1 := NewValue("hello")
+ val2 := NewValue("world")
+ c.Assert(val1.Cmp(val2), checker.Equals, false)
+
+ val3 := NewValue("hello")
+ val4 := NewValue("hello")
+ c.Assert(val3.Cmp(val4), checker.Equals, true)
+}
+
+func (s *ValueSuite) TestValueTypes(c *checker.C) {
+ str := NewValue("str")
+ num := NewValue(1)
+ inter := NewValue([]interface{}{1})
+ byt := NewValue([]byte{1, 2, 3, 4})
+ bigInt := NewValue(big.NewInt(10))
+
+ strExp := "str"
+ numExp := uint64(1)
+ interExp := []interface{}{1}
+ bytExp := []byte{1, 2, 3, 4}
+ bigExp := big.NewInt(10)
+
+ c.Assert(str.Str(), checker.Equals, strExp)
+ c.Assert(num.Uint(), checker.Equals, numExp)
+ c.Assert(NewValue(inter.Val).Cmp(NewValue(interExp)), checker.Equals, true)
+ c.Assert(byt.Bytes(), checker.DeepEquals, bytExp)
+ c.Assert(bigInt.BigInt(), checker.DeepEquals, bigExp)
+}
+
+func (s *ValueSuite) TestIterator(c *checker.C) {
+ value := NewValue([]interface{}{1, 2, 3})
+ iter := value.NewIterator()
+ values := []uint64{1, 2, 3}
+ i := 0
+ for iter.Next() {
+ c.Assert(values[i], checker.Equals, iter.Value().Uint())
+ i++
+ }
+}
+
+func (s *ValueSuite) TestMath(c *checker.C) {
+ data1 := NewValue(1)
+ data1.Add(1).Add(1)
+ exp1 := NewValue(3)
+ data2 := NewValue(2)
+ data2.Sub(1).Sub(1)
+ exp2 := NewValue(0)
+
+ c.Assert(data1.DeepCmp(exp1), checker.Equals, true)
+ c.Assert(data2.DeepCmp(exp2), checker.Equals, true)
+}
+
+func (s *ValueSuite) TestString(c *checker.C) {
+ data := "10"
+ exp := int64(10)
+ c.Assert(NewValue(data).Int(), checker.DeepEquals, exp)
+}
diff --git a/compression/rle/read_write.go b/compression/rle/read_write.go
new file mode 100644
index 000000000..dde0e41ab
--- /dev/null
+++ b/compression/rle/read_write.go
@@ -0,0 +1,84 @@
+package rle
+
+import (
+ "bytes"
+ "errors"
+
+ "github.com/ethereum/go-ethereum/crypto"
+)
+
+const (
+ token byte = 0xfe
+ emptyShaToken = 0xfd
+ emptyListShaToken = 0xfe
+ tokenToken = 0xff
+)
+
+var empty = crypto.Sha3([]byte(""))
+var emptyList = crypto.Sha3([]byte{0x80})
+
+func Decompress(dat []byte) ([]byte, error) {
+ buf := new(bytes.Buffer)
+
+ for i := 0; i < len(dat); i++ {
+ if dat[i] == token {
+ if i+1 < len(dat) {
+ switch dat[i+1] {
+ case emptyShaToken:
+ buf.Write(empty)
+ case emptyListShaToken:
+ buf.Write(emptyList)
+ case tokenToken:
+ buf.WriteByte(token)
+ default:
+ buf.Write(make([]byte, int(dat[i+1]-2)))
+ }
+ i++
+ } else {
+ return nil, errors.New("error reading bytes. token encountered without proceeding bytes")
+ }
+ } else {
+ buf.WriteByte(dat[i])
+ }
+ }
+
+ return buf.Bytes(), nil
+}
+
+func compressChunk(dat []byte) (ret []byte, n int) {
+ switch {
+ case dat[0] == token:
+ return []byte{token, tokenToken}, 1
+ case len(dat) > 1 && dat[0] == 0x0 && dat[1] == 0x0:
+ j := 0
+ for j <= 254 && j < len(dat) {
+ if dat[j] != 0 {
+ break
+ }
+ j++
+ }
+ return []byte{token, byte(j + 2)}, j
+ case len(dat) >= 32:
+ if dat[0] == empty[0] && bytes.Compare(dat[:32], empty) == 0 {
+ return []byte{token, emptyShaToken}, 32
+ } else if dat[0] == emptyList[0] && bytes.Compare(dat[:32], emptyList) == 0 {
+ return []byte{token, emptyListShaToken}, 32
+ }
+ fallthrough
+ default:
+ return dat[:1], 1
+ }
+}
+
+func Compress(dat []byte) []byte {
+ buf := new(bytes.Buffer)
+
+ i := 0
+ for i < len(dat) {
+ b, n := compressChunk(dat[i:])
+ buf.Write(b)
+ i += n
+ }
+
+ return buf.Bytes()
+}
diff --git a/compression/rle/read_write_test.go b/compression/rle/read_write_test.go
new file mode 100644
index 000000000..e6aac9093
--- /dev/null
+++ b/compression/rle/read_write_test.go
@@ -0,0 +1,118 @@
+package rle
+
+import (
+ "testing"
+
+ checker "gopkg.in/check.v1"
+)
+
+func Test(t *testing.T) { checker.TestingT(t) }
+
+type CompressionRleSuite struct{}
+
+var _ = checker.Suite(&CompressionRleSuite{})
+
+func (s *CompressionRleSuite) TestDecompressSimple(c *checker.C) {
+ exp := []byte{0xc5, 0xd2, 0x46, 0x1, 0x86, 0xf7, 0x23, 0x3c, 0x92, 0x7e, 0x7d, 0xb2, 0xdc, 0xc7, 0x3, 0xc0, 0xe5, 0x0, 0xb6, 0x53, 0xca, 0x82, 0x27, 0x3b, 0x7b, 0xfa, 0xd8, 0x4, 0x5d, 0x85, 0xa4, 0x70}
+ res, err := Decompress([]byte{token, 0xfd})
+ c.Assert(err, checker.IsNil)
+ c.Assert(res, checker.DeepEquals, exp)
+ // if bytes.Compare(res, exp) != 0 {
+ // t.Error("empty sha3", res)
+ // }
+
+ exp = []byte{0x56, 0xe8, 0x1f, 0x17, 0x1b, 0xcc, 0x55, 0xa6, 0xff, 0x83, 0x45, 0xe6, 0x92, 0xc0, 0xf8, 0x6e, 0x5b, 0x48, 0xe0, 0x1b, 0x99, 0x6c, 0xad, 0xc0, 0x1, 0x62, 0x2f, 0xb5, 0xe3, 0x63, 0xb4, 0x21}
+ res, err = Decompress([]byte{token, 0xfe})
+ c.Assert(err, checker.IsNil)
+ c.Assert(res, checker.DeepEquals, exp)
+ // if bytes.Compare(res, exp) != 0 {
+ // t.Error("0x80 sha3", res)
+ // }
+
+ res, err = Decompress([]byte{token, 0xff})
+ c.Assert(err, checker.IsNil)
+ c.Assert(res, checker.DeepEquals, []byte{token})
+ // if bytes.Compare(res, []byte{token}) != 0 {
+ // t.Error("token", res)
+ // }
+
+ res, err = Decompress([]byte{token, 12})
+ c.Assert(err, checker.IsNil)
+ c.Assert(res, checker.DeepEquals, make([]byte, 10))
+ // if bytes.Compare(res, make([]byte, 10)) != 0 {
+ // t.Error("10 * zero", res)
+ // }
+}
+
+// func TestDecompressMulti(t *testing.T) {
+// res, err := Decompress([]byte{token, 0xfd, token, 0xfe, token, 12})
+// if err != nil {
+// t.Error(err)
+// }
+
+// var exp []byte
+// exp = append(exp, crypto.Sha3([]byte(""))...)
+// exp = append(exp, crypto.Sha3([]byte{0x80})...)
+// exp = append(exp, make([]byte, 10)...)
+
+// if bytes.Compare(res, res) != 0 {
+// t.Error("Expected", exp, "result", res)
+// }
+// }
+
+// func TestCompressSimple(t *testing.T) {
+// res := Compress([]byte{0, 0, 0, 0, 0})
+// if bytes.Compare(res, []byte{token, 7}) != 0 {
+// t.Error("5 * zero", res)
+// }
+
+// res = Compress(crypto.Sha3([]byte("")))
+// if bytes.Compare(res, []byte{token, emptyShaToken}) != 0 {
+// t.Error("empty sha", res)
+// }
+
+// res = Compress(crypto.Sha3([]byte{0x80}))
+// if bytes.Compare(res, []byte{token, emptyListShaToken}) != 0 {
+// t.Error("empty list sha", res)
+// }
+
+// res = Compress([]byte{token})
+// if bytes.Compare(res, []byte{token, tokenToken}) != 0 {
+// t.Error("token", res)
+// }
+// }
+
+// func TestCompressMulti(t *testing.T) {
+// in := []byte{0, 0, 0, 0, 0}
+// in = append(in, crypto.Sha3([]byte(""))...)
+// in = append(in, crypto.Sha3([]byte{0x80})...)
+// in = append(in, token)
+// res := Compress(in)
+
+// exp := []byte{token, 7, token, emptyShaToken, token, emptyListShaToken, token, tokenToken}
+// if bytes.Compare(res, exp) != 0 {
+// t.Error("expected", exp, "got", res)
+// }
+// }
+
+// func TestCompressDecompress(t *testing.T) {
+// var in []byte
+
+// for i := 0; i < 20; i++ {
+// in = append(in, []byte{0, 0, 0, 0, 0}...)
+// in = append(in, crypto.Sha3([]byte(""))...)
+// in = append(in, crypto.Sha3([]byte{0x80})...)
+// in = append(in, []byte{123, 2, 19, 89, 245, 254, 255, token, 98, 233}...)
+// in = append(in, token)
+// }
+
+// c := Compress(in)
+// d, err := Decompress(c)
+// if err != nil {
+// t.Error(err)
+// }
+
+// if bytes.Compare(d, in) != 0 {
+// t.Error("multi failed\n", d, "\n", in)
+// }
+// }
diff --git a/core/.gitignore b/core/.gitignore
new file mode 100644
index 000000000..f725d58d1
--- /dev/null
+++ b/core/.gitignore
@@ -0,0 +1,12 @@
+# See http://help.github.com/ignore-files/ for more about ignoring files.
+#
+# If you find yourself ignoring temporary files generated by your text editor
+# or operating system, you probably want to add a global ignore instead:
+# git config --global core.excludesfile ~/.gitignore_global
+
+/tmp
+*/**/*un~
+*un~
+.DS_Store
+*/**/.DS_Store
+
diff --git a/core/asm.go b/core/asm.go
new file mode 100644
index 000000000..f40c07904
--- /dev/null
+++ b/core/asm.go
@@ -0,0 +1,50 @@
+package core
+
+import (
+ "fmt"
+ "math/big"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/core/vm"
+)
+
+func Disassemble(script []byte) (asm []string) {
+ pc := new(big.Int)
+ for {
+ if pc.Cmp(big.NewInt(int64(len(script)))) >= 0 {
+ return
+ }
+
+ // Get the memory location of pc
+ val := script[pc.Int64()]
+ // Get the opcode (it must be an opcode!)
+ op := vm.OpCode(val)
+
+ asm = append(asm, fmt.Sprintf("%04v: %v", pc, op))
+
+ switch op {
+ case vm.PUSH1, vm.PUSH2, vm.PUSH3, vm.PUSH4, vm.PUSH5, vm.PUSH6, vm.PUSH7, vm.PUSH8,
+ vm.PUSH9, vm.PUSH10, vm.PUSH11, vm.PUSH12, vm.PUSH13, vm.PUSH14, vm.PUSH15,
+ vm.PUSH16, vm.PUSH17, vm.PUSH18, vm.PUSH19, vm.PUSH20, vm.PUSH21, vm.PUSH22,
+ vm.PUSH23, vm.PUSH24, vm.PUSH25, vm.PUSH26, vm.PUSH27, vm.PUSH28, vm.PUSH29,
+ vm.PUSH30, vm.PUSH31, vm.PUSH32:
+ pc.Add(pc, common.Big1)
+ a := int64(op) - int64(vm.PUSH1) + 1
+ if int(pc.Int64()+a) > len(script) {
+ return
+ }
+
+ data := script[pc.Int64() : pc.Int64()+a]
+ if len(data) == 0 {
+ data = []byte{0}
+ }
+ asm = append(asm, fmt.Sprintf("%04v: 0x%x", pc, data))
+
+ pc.Add(pc, big.NewInt(a-1))
+ }
+
+ pc.Add(pc, common.Big1)
+ }
+
+ return asm
+}
diff --git a/core/block_cache.go b/core/block_cache.go
new file mode 100644
index 000000000..ea39e78e8
--- /dev/null
+++ b/core/block_cache.go
@@ -0,0 +1,73 @@
+package core
+
+import (
+ "sync"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/core/types"
+)
+
+// BlockCache implements a caching mechanism specifically for blocks and uses FILO to pop
+type BlockCache struct {
+ size int
+
+ hashes []common.Hash
+ blocks map[common.Hash]*types.Block
+
+ mu sync.RWMutex
+}
+
+// Creates and returns a `BlockCache` with `size`. If `size` is smaller than 1 it will panic
+func NewBlockCache(size int) *BlockCache {
+ if size < 1 {
+ panic("block cache size not allowed to be smaller than 1")
+ }
+
+ bc := &BlockCache{size: size}
+ bc.Clear()
+ return bc
+}
+
+func (bc *BlockCache) Clear() {
+ bc.blocks = make(map[common.Hash]*types.Block)
+ bc.hashes = nil
+
+}
+
+func (bc *BlockCache) Push(block *types.Block) {
+ bc.mu.Lock()
+ defer bc.mu.Unlock()
+
+ if len(bc.hashes) == bc.size {
+ delete(bc.blocks, bc.hashes[0])
+
+ // XXX There are a few other options on solving this
+ // 1) use a poller / GC like mechanism to clean up untracked objects
+ // 2) copy as below
+ // re-use the slice and remove the reference to bc.hashes[0]
+ // this will allow the element to be garbage collected.
+ copy(bc.hashes, bc.hashes[1:])
+ } else {
+ bc.hashes = append(bc.hashes, common.Hash{})
+ }
+
+ hash := block.Hash()
+ bc.blocks[hash] = block
+ bc.hashes[len(bc.hashes)-1] = hash
+}
+
+func (bc *BlockCache) Get(hash common.Hash) *types.Block {
+ bc.mu.RLock()
+ defer bc.mu.RUnlock()
+
+ if block, haz := bc.blocks[hash]; haz {
+ return block
+ }
+
+ return nil
+}
+
+func (bc *BlockCache) Has(hash common.Hash) bool {
+ _, ok := bc.blocks[hash]
+ return ok
+}
diff --git a/core/block_cache_test.go b/core/block_cache_test.go
new file mode 100644
index 000000000..d4f610b71
--- /dev/null
+++ b/core/block_cache_test.go
@@ -0,0 +1,48 @@
+package core
+
+import (
+ "math/big"
+ "testing"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/core/types"
+)
+
+func newChain(size int) (chain []*types.Block) {
+ var parentHash common.Hash
+ for i := 0; i < size; i++ {
+ block := types.NewBlock(parentHash, common.Address{}, common.Hash{}, new(big.Int), 0, "")
+ block.Header().Number = big.NewInt(int64(i))
+ chain = append(chain, block)
+ parentHash = block.Hash()
+ }
+ return
+}
+
+func insertChainCache(cache *BlockCache, chain []*types.Block) {
+ for _, block := range chain {
+ cache.Push(block)
+ }
+}
+
+func TestNewBlockCache(t *testing.T) {
+ chain := newChain(3)
+ cache := NewBlockCache(2)
+ insertChainCache(cache, chain)
+
+ if cache.hashes[0] != chain[1].Hash() {
+ t.Error("oldest block incorrect")
+ }
+}
+
+func TestInclusion(t *testing.T) {
+ chain := newChain(3)
+ cache := NewBlockCache(3)
+ insertChainCache(cache, chain)
+
+ for _, block := range chain {
+ if b := cache.Get(block.Hash()); b == nil {
+ t.Errorf("getting %x failed", block.Hash())
+ }
+ }
+}
diff --git a/core/block_processor.go b/core/block_processor.go
new file mode 100644
index 000000000..97c885536
--- /dev/null
+++ b/core/block_processor.go
@@ -0,0 +1,393 @@
+package core
+
+import (
+ "fmt"
+ "math/big"
+ "sync"
+ "time"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/core/state"
+ "github.com/ethereum/go-ethereum/core/types"
+ "github.com/ethereum/go-ethereum/event"
+ "github.com/ethereum/go-ethereum/logger"
+ "github.com/ethereum/go-ethereum/params"
+ "github.com/ethereum/go-ethereum/pow"
+ "github.com/ethereum/go-ethereum/rlp"
+ "gopkg.in/fatih/set.v0"
+)
+
+var statelogger = logger.NewLogger("BLOCK")
+
+type BlockProcessor struct {
+ db common.Database
+ extraDb common.Database
+ // Mutex for locking the block processor. Blocks can only be handled one at a time
+ mutex sync.Mutex
+ // Canonical block chain
+ bc *ChainManager
+ // non-persistent key/value memory storage
+ mem map[string]*big.Int
+ // Proof of work used for validating
+ Pow pow.PoW
+
+ txpool *TxPool
+
+ // The last attempted block is mainly used for debugging purposes
+ // This does not have to be a valid block and will be set during
+ // 'Process' & canonical validation.
+ lastAttemptedBlock *types.Block
+
+ events event.Subscription
+
+ eventMux *event.TypeMux
+}
+
+func NewBlockProcessor(db, extra common.Database, pow pow.PoW, txpool *TxPool, chainManager *ChainManager, eventMux *event.TypeMux) *BlockProcessor {
+ sm := &BlockProcessor{
+ db: db,
+ extraDb: extra,
+ mem: make(map[string]*big.Int),
+ Pow: pow,
+ bc: chainManager,
+ eventMux: eventMux,
+ txpool: txpool,
+ }
+
+ return sm
+}
+
+func (sm *BlockProcessor) TransitionState(statedb *state.StateDB, parent, block *types.Block, transientProcess bool) (receipts types.Receipts, err error) {
+ coinbase := statedb.GetOrNewStateObject(block.Header().Coinbase)
+ coinbase.SetGasPool(block.Header().GasLimit)
+
+ // Process the transactions on to parent state
+ receipts, err = sm.ApplyTransactions(coinbase, statedb, block, block.Transactions(), transientProcess)
+ if err != nil {
+ return nil, err
+ }
+
+ return receipts, nil
+}
+
+func (self *BlockProcessor) ApplyTransaction(coinbase *state.StateObject, statedb *state.StateDB, block *types.Block, tx *types.Transaction, usedGas *big.Int, transientProcess bool) (*types.Receipt, *big.Int, error) {
+ // If we are mining this block and validating we want to set the logs back to 0
+ statedb.EmptyLogs()
+
+ cb := statedb.GetStateObject(coinbase.Address())
+ _, gas, err := ApplyMessage(NewEnv(statedb, self.bc, tx, block), tx, cb)
+ if err != nil && (IsNonceErr(err) || state.IsGasLimitErr(err) || IsInvalidTxErr(err)) {
+ // If the account is managed, remove the invalid nonce.
+ from, _ := tx.From()
+ self.bc.TxState().RemoveNonce(from, tx.Nonce())
+ return nil, nil, err
+ }
+
+ // Update the state with pending changes
+ statedb.Update()
+
+ cumulative := new(big.Int).Set(usedGas.Add(usedGas, gas))
+ receipt := types.NewReceipt(statedb.Root().Bytes(), cumulative)
+ receipt.SetLogs(statedb.Logs())
+ receipt.Bloom = types.CreateBloom(types.Receipts{receipt})
+ chainlogger.Debugln(receipt)
+
+ // Notify all subscribers
+ if !transientProcess {
+ go self.eventMux.Post(TxPostEvent{tx})
+ logs := statedb.Logs()
+ go self.eventMux.Post(logs)
+ }
+
+ return receipt, gas, err
+}
+func (self *BlockProcessor) ChainManager() *ChainManager {
+ return self.bc
+}
+
+func (self *BlockProcessor) ApplyTransactions(coinbase *state.StateObject, statedb *state.StateDB, block *types.Block, txs types.Transactions, transientProcess bool) (types.Receipts, error) {
+ var (
+ receipts types.Receipts
+ totalUsedGas = big.NewInt(0)
+ err error
+ cumulativeSum = new(big.Int)
+ )
+
+ for _, tx := range txs {
+ receipt, txGas, err := self.ApplyTransaction(coinbase, statedb, block, tx, totalUsedGas, transientProcess)
+ if err != nil && (IsNonceErr(err) || state.IsGasLimitErr(err) || IsInvalidTxErr(err)) {
+ return nil, err
+ }
+
+ if err != nil {
+ statelogger.Infoln("TX err:", err)
+ }
+ receipts = append(receipts, receipt)
+
+ cumulativeSum.Add(cumulativeSum, new(big.Int).Mul(txGas, tx.GasPrice()))
+ }
+
+ if block.GasUsed().Cmp(totalUsedGas) != 0 {
+ return nil, ValidationError(fmt.Sprintf("gas used error (%v / %v)", block.GasUsed(), totalUsedGas))
+ }
+
+ if transientProcess {
+ go self.eventMux.Post(PendingBlockEvent{block, statedb.Logs()})
+ }
+
+ return receipts, err
+}
+
+// Process block will attempt to process the given block's transactions and applies them
+// on top of the block's parent state (given it exists) and will return wether it was
+// successful or not.
+func (sm *BlockProcessor) Process(block *types.Block) (td *big.Int, logs state.Logs, err error) {
+ // Processing a blocks may never happen simultaneously
+ sm.mutex.Lock()
+ defer sm.mutex.Unlock()
+
+ header := block.Header()
+ if sm.bc.HasBlock(header.Hash()) {
+ return nil, nil, &KnownBlockError{header.Number, header.Hash()}
+ }
+
+ if !sm.bc.HasBlock(header.ParentHash) {
+ return nil, nil, ParentError(header.ParentHash)
+ }
+ parent := sm.bc.GetBlock(header.ParentHash)
+
+ return sm.processWithParent(block, parent)
+}
+
+func (sm *BlockProcessor) processWithParent(block, parent *types.Block) (td *big.Int, logs state.Logs, err error) {
+ sm.lastAttemptedBlock = block
+
+ // Create a new state based on the parent's root (e.g., create copy)
+ state := state.New(parent.Root(), sm.db)
+
+ // track (possible) uncle block
+ var uncle bool
+ // Block validation
+ if err = sm.ValidateHeader(block.Header(), parent.Header()); err != nil {
+ if err != BlockEqualTSErr {
+ return
+ }
+ err = nil
+ uncle = true
+ }
+
+ // There can be at most two uncles
+ if len(block.Uncles()) > 2 {
+ return nil, nil, ValidationError("Block can only contain one uncle (contained %v)", len(block.Uncles()))
+ }
+
+ receipts, err := sm.TransitionState(state, parent, block, false)
+ if err != nil {
+ return
+ }
+
+ header := block.Header()
+
+ // Validate the received block's bloom with the one derived from the generated receipts.
+ // For valid blocks this should always validate to true.
+ rbloom := types.CreateBloom(receipts)
+ if rbloom != header.Bloom {
+ err = fmt.Errorf("unable to replicate block's bloom=%x", rbloom)
+ return
+ }
+
+ // The transactions Trie's root (R = (Tr [[i, RLP(T1)], [i, RLP(T2)], ... [n, RLP(Tn)]]))
+ // can be used by light clients to make sure they've received the correct Txs
+ txSha := types.DeriveSha(block.Transactions())
+ if txSha != header.TxHash {
+ err = fmt.Errorf("validating transaction root. received=%x got=%x", header.TxHash, txSha)
+ return
+ }
+
+ // Tre receipt Trie's root (R = (Tr [[H1, R1], ... [Hn, R1]]))
+ receiptSha := types.DeriveSha(receipts)
+ if receiptSha != header.ReceiptHash {
+ err = fmt.Errorf("validating receipt root. received=%x got=%x", header.ReceiptHash, receiptSha)
+ return
+ }
+
+ // Verify uncles
+ if err = sm.VerifyUncles(state, block, parent); err != nil {
+ return
+ }
+ // Accumulate static rewards; block reward, uncle's and uncle inclusion.
+ AccumulateRewards(state, block)
+
+ // Commit state objects/accounts to a temporary trie (does not save)
+ // used to calculate the state root.
+ state.Update()
+ if header.Root != state.Root() {
+ err = fmt.Errorf("invalid merkle root. received=%x got=%x", header.Root, state.Root())
+ return
+ }
+
+ // Calculate the td for this block
+ td = CalculateTD(block, parent)
+ // Sync the current block's state to the database
+ state.Sync()
+
+ if !uncle {
+ // Remove transactions from the pool
+ sm.txpool.RemoveSet(block.Transactions())
+ }
+
+ // This puts transactions in a extra db for rpc
+ for i, tx := range block.Transactions() {
+ putTx(sm.extraDb, tx, block, uint64(i))
+ }
+
+ if uncle {
+ chainlogger.Infof("found possible uncle block #%d (%x...)\n", header.Number, block.Hash().Bytes()[0:4])
+ return td, nil, BlockEqualTSErr
+ } else {
+ chainlogger.Infof("processed block #%d (%d TXs %d UNCs) (%x...)\n", header.Number, len(block.Transactions()), len(block.Uncles()), block.Hash().Bytes()[0:4])
+ }
+
+ return td, state.Logs(), nil
+}
+
+// Validates the current block. Returns an error if the block was invalid,
+// an uncle or anything that isn't on the current block chain.
+// Validation validates easy over difficult (dagger takes longer time = difficult)
+func (sm *BlockProcessor) ValidateHeader(block, parent *types.Header) error {
+ if big.NewInt(int64(len(block.Extra))).Cmp(params.MaximumExtraDataSize) == 1 {
+ return fmt.Errorf("Block extra data too long (%d)", len(block.Extra))
+ }
+
+ expd := CalcDifficulty(block, parent)
+ if expd.Cmp(block.Difficulty) != 0 {
+ return fmt.Errorf("Difficulty check failed for block %v, %v", block.Difficulty, expd)
+ }
+
+ // block.gasLimit - parent.gasLimit <= parent.gasLimit / GasLimitBoundDivisor
+ a := new(big.Int).Sub(block.GasLimit, parent.GasLimit)
+ a.Abs(a)
+ b := new(big.Int).Div(parent.GasLimit, params.GasLimitBoundDivisor)
+ if !(a.Cmp(b) < 0) || (block.GasLimit.Cmp(params.MinGasLimit) == -1) {
+ return fmt.Errorf("GasLimit check failed for block %v (%v > %v)", block.GasLimit, a, b)
+ }
+
+ if int64(block.Time) > time.Now().Unix() {
+ return BlockFutureErr
+ }
+
+ if new(big.Int).Sub(block.Number, parent.Number).Cmp(big.NewInt(1)) != 0 {
+ return BlockNumberErr
+ }
+
+ // Verify the nonce of the block. Return an error if it's not valid
+ if !sm.Pow.Verify(types.NewBlockWithHeader(block)) {
+ return ValidationError("Block's nonce is invalid (= %x)", block.Nonce)
+ }
+
+ if block.Time <= parent.Time {
+ return BlockEqualTSErr //ValidationError("Block timestamp equal or less than previous block (%v - %v)", block.Time, parent.Time)
+ }
+
+ return nil
+}
+
+func AccumulateRewards(statedb *state.StateDB, block *types.Block) {
+ reward := new(big.Int).Set(BlockReward)
+
+ for _, uncle := range block.Uncles() {
+ num := new(big.Int).Add(big.NewInt(8), uncle.Number)
+ num.Sub(num, block.Number())
+
+ r := new(big.Int)
+ r.Mul(BlockReward, num)
+ r.Div(r, big.NewInt(8))
+
+ statedb.AddBalance(uncle.Coinbase, r)
+
+ reward.Add(reward, new(big.Int).Div(BlockReward, big.NewInt(32)))
+ }
+
+ // Get the account associated with the coinbase
+ statedb.AddBalance(block.Header().Coinbase, reward)
+}
+
+func (sm *BlockProcessor) VerifyUncles(statedb *state.StateDB, block, parent *types.Block) error {
+ ancestors := set.New()
+ uncles := set.New()
+ ancestorHeaders := make(map[common.Hash]*types.Header)
+ for _, ancestor := range sm.bc.GetAncestors(block, 7) {
+ ancestorHeaders[ancestor.Hash()] = ancestor.Header()
+ ancestors.Add(ancestor.Hash())
+ // Include ancestors uncles in the uncle set. Uncles must be unique.
+ for _, uncle := range ancestor.Uncles() {
+ uncles.Add(uncle.Hash())
+ }
+ }
+
+ uncles.Add(block.Hash())
+ for _, uncle := range block.Uncles() {
+ if uncles.Has(uncle.Hash()) {
+ // Error not unique
+ return UncleError("Uncle not unique")
+ }
+
+ uncles.Add(uncle.Hash())
+
+ if ancestors.Has(uncle.Hash()) {
+ return UncleError("Uncle is ancestor")
+ }
+
+ if !ancestors.Has(uncle.ParentHash) {
+ return UncleError(fmt.Sprintf("Uncle's parent unknown (%x)", uncle.ParentHash[0:4]))
+ }
+
+ if err := sm.ValidateHeader(uncle, ancestorHeaders[uncle.ParentHash]); err != nil && err != BlockEqualTSErr {
+ return ValidationError(fmt.Sprintf("%v", err))
+ }
+
+ }
+
+ return nil
+}
+
+func (sm *BlockProcessor) GetLogs(block *types.Block) (logs state.Logs, err error) {
+ if !sm.bc.HasBlock(block.Header().ParentHash) {
+ return nil, ParentError(block.Header().ParentHash)
+ }
+
+ sm.lastAttemptedBlock = block
+
+ var (
+ parent = sm.bc.GetBlock(block.Header().ParentHash)
+ state = state.New(parent.Root(), sm.db)
+ )
+
+ sm.TransitionState(state, parent, block, true)
+
+ return state.Logs(), nil
+}
+
+func putTx(db common.Database, tx *types.Transaction, block *types.Block, i uint64) {
+ rlpEnc, err := rlp.EncodeToBytes(tx)
+ if err != nil {
+ statelogger.Infoln("Failed encoding tx", err)
+ return
+ }
+ db.Put(tx.Hash().Bytes(), rlpEnc)
+
+ var txExtra struct {
+ BlockHash common.Hash
+ BlockIndex uint64
+ Index uint64
+ }
+ txExtra.BlockHash = block.Hash()
+ txExtra.BlockIndex = block.NumberU64()
+ txExtra.Index = i
+ rlpMeta, err := rlp.EncodeToBytes(txExtra)
+ if err != nil {
+ statelogger.Infoln("Failed encoding meta", err)
+ return
+ }
+ db.Put(append(tx.Hash().Bytes(), 0x0001), rlpMeta)
+}
diff --git a/core/block_processor_test.go b/core/block_processor_test.go
new file mode 100644
index 000000000..64add7e8b
--- /dev/null
+++ b/core/block_processor_test.go
@@ -0,0 +1,36 @@
+package core
+
+import (
+ "math/big"
+ "testing"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/ethdb"
+ "github.com/ethereum/go-ethereum/event"
+ "github.com/ethereum/go-ethereum/pow/ezp"
+)
+
+func proc() (*BlockProcessor, *ChainManager) {
+ db, _ := ethdb.NewMemDatabase()
+ var mux event.TypeMux
+
+ chainMan := NewChainManager(db, db, &mux)
+ return NewBlockProcessor(db, db, ezp.New(), nil, chainMan, &mux), chainMan
+}
+
+func TestNumber(t *testing.T) {
+ bp, chain := proc()
+ block1 := chain.NewBlock(common.Address{})
+ block1.Header().Number = big.NewInt(3)
+
+ err := bp.ValidateHeader(block1.Header(), chain.Genesis().Header())
+ if err != BlockNumberErr {
+ t.Errorf("expected block number error")
+ }
+
+ block1 = chain.NewBlock(common.Address{})
+ err = bp.ValidateHeader(block1.Header(), chain.Genesis().Header())
+ if err == BlockNumberErr {
+ t.Errorf("didn't expect block number error")
+ }
+}
diff --git a/core/chain_makers.go b/core/chain_makers.go
new file mode 100644
index 000000000..52cb367c5
--- /dev/null
+++ b/core/chain_makers.go
@@ -0,0 +1,142 @@
+package core
+
+import (
+ "fmt"
+ "math/big"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/core/state"
+ "github.com/ethereum/go-ethereum/core/types"
+ "github.com/ethereum/go-ethereum/event"
+ "github.com/ethereum/go-ethereum/pow"
+)
+
+// So we can generate blocks easily
+type FakePow struct{}
+
+func (f FakePow) Search(block pow.Block, stop <-chan struct{}) (uint64, []byte, []byte) {
+ return 0, nil, nil
+}
+func (f FakePow) Verify(block pow.Block) bool { return true }
+func (f FakePow) GetHashrate() int64 { return 0 }
+func (f FakePow) Turbo(bool) {}
+
+// So we can deterministically seed different blockchains
+var (
+ CanonicalSeed = 1
+ ForkSeed = 2
+)
+
+// Utility functions for making chains on the fly
+// Exposed for sake of testing from other packages (eg. go-ethash)
+func NewBlockFromParent(addr common.Address, parent *types.Block) *types.Block {
+ return newBlockFromParent(addr, parent)
+}
+
+func MakeBlock(bman *BlockProcessor, parent *types.Block, i int, db common.Database, seed int) *types.Block {
+ return makeBlock(bman, parent, i, db, seed)
+}
+
+func MakeChain(bman *BlockProcessor, parent *types.Block, max int, db common.Database, seed int) types.Blocks {
+ return makeChain(bman, parent, max, db, seed)
+}
+
+func NewChainMan(block *types.Block, eventMux *event.TypeMux, db common.Database) *ChainManager {
+ return newChainManager(block, eventMux, db)
+}
+
+func NewBlockProc(db common.Database, txpool *TxPool, cman *ChainManager, eventMux *event.TypeMux) *BlockProcessor {
+ return newBlockProcessor(db, txpool, cman, eventMux)
+}
+
+func NewCanonical(n int, db common.Database) (*BlockProcessor, error) {
+ return newCanonical(n, db)
+}
+
+// block time is fixed at 10 seconds
+func newBlockFromParent(addr common.Address, parent *types.Block) *types.Block {
+ block := types.NewBlock(parent.Hash(), addr, parent.Root(), common.BigPow(2, 32), 0, "")
+ block.SetUncles(nil)
+ block.SetTransactions(nil)
+ block.SetReceipts(nil)
+
+ header := block.Header()
+ header.Difficulty = CalcDifficulty(block.Header(), parent.Header())
+ header.Number = new(big.Int).Add(parent.Header().Number, common.Big1)
+ header.Time = parent.Header().Time + 10
+ header.GasLimit = CalcGasLimit(parent, block)
+
+ block.Td = parent.Td
+
+ return block
+}
+
+// Actually make a block by simulating what miner would do
+// we seed chains by the first byte of the coinbase
+func makeBlock(bman *BlockProcessor, parent *types.Block, i int, db common.Database, seed int) *types.Block {
+ var addr common.Address
+ addr[0], addr[19] = byte(seed), byte(i)
+ block := newBlockFromParent(addr, parent)
+ state := state.New(block.Root(), db)
+ cbase := state.GetOrNewStateObject(addr)
+ cbase.SetGasPool(CalcGasLimit(parent, block))
+ cbase.AddBalance(BlockReward)
+ state.Update()
+ block.SetRoot(state.Root())
+ return block
+}
+
+// Make a chain with real blocks
+// Runs ProcessWithParent to get proper state roots
+func makeChain(bman *BlockProcessor, parent *types.Block, max int, db common.Database, seed int) types.Blocks {
+ bman.bc.currentBlock = parent
+ blocks := make(types.Blocks, max)
+ for i := 0; i < max; i++ {
+ block := makeBlock(bman, parent, i, db, seed)
+ td, _, err := bman.processWithParent(block, parent)
+ if err != nil {
+ fmt.Println("process with parent failed", err)
+ panic(err)
+ }
+ block.Td = td
+ blocks[i] = block
+ parent = block
+ }
+ return blocks
+}
+
+// Create a new chain manager starting from given block
+// Effectively a fork factory
+func newChainManager(block *types.Block, eventMux *event.TypeMux, db common.Database) *ChainManager {
+ bc := &ChainManager{blockDb: db, stateDb: db, genesisBlock: GenesisBlock(db), eventMux: eventMux}
+ if block == nil {
+ bc.Reset()
+ } else {
+ bc.currentBlock = block
+ bc.td = block.Td
+ }
+ return bc
+}
+
+// block processor with fake pow
+func newBlockProcessor(db common.Database, txpool *TxPool, cman *ChainManager, eventMux *event.TypeMux) *BlockProcessor {
+ bman := NewBlockProcessor(db, db, FakePow{}, txpool, newChainManager(nil, eventMux, db), eventMux)
+ return bman
+}
+
+// Make a new, deterministic canonical chain by running InsertChain
+// on result of makeChain
+func newCanonical(n int, db common.Database) (*BlockProcessor, error) {
+ eventMux := &event.TypeMux{}
+ txpool := NewTxPool(eventMux)
+
+ bman := newBlockProcessor(db, txpool, newChainManager(nil, eventMux, db), eventMux)
+ bman.bc.SetProcessor(bman)
+ parent := bman.bc.CurrentBlock()
+ if n == 0 {
+ return bman, nil
+ }
+ lchain := makeChain(bman, parent, n, db, CanonicalSeed)
+ err := bman.bc.InsertChain(lchain)
+ return bman, err
+}
diff --git a/core/chain_manager.go b/core/chain_manager.go
new file mode 100644
index 000000000..d97a94b06
--- /dev/null
+++ b/core/chain_manager.go
@@ -0,0 +1,542 @@
+package core
+
+import (
+ "bytes"
+ "fmt"
+ "io"
+ "math/big"
+ "sync"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/core/state"
+ "github.com/ethereum/go-ethereum/core/types"
+ "github.com/ethereum/go-ethereum/event"
+ "github.com/ethereum/go-ethereum/logger"
+ "github.com/ethereum/go-ethereum/params"
+ "github.com/ethereum/go-ethereum/rlp"
+)
+
+var (
+ chainlogger = logger.NewLogger("CHAIN")
+ jsonlogger = logger.NewJsonLogger()
+
+ blockHashPre = []byte("block-hash-")
+ blockNumPre = []byte("block-num-")
+)
+
+const blockCacheLimit = 10000
+
+type StateQuery interface {
+ GetAccount(addr []byte) *state.StateObject
+}
+
+func CalcDifficulty(block, parent *types.Header) *big.Int {
+ diff := new(big.Int)
+
+ adjust := new(big.Int).Div(parent.Difficulty, params.DifficultyBoundDivisor)
+ if big.NewInt(int64(block.Time)-int64(parent.Time)).Cmp(params.DurationLimit) < 0 {
+ diff.Add(parent.Difficulty, adjust)
+ } else {
+ diff.Sub(parent.Difficulty, adjust)
+ }
+
+ if diff.Cmp(params.MinimumDifficulty) < 0 {
+ return params.MinimumDifficulty
+ }
+
+ return diff
+}
+
+func CalculateTD(block, parent *types.Block) *big.Int {
+ uncleDiff := new(big.Int)
+ for _, uncle := range block.Uncles() {
+ uncleDiff = uncleDiff.Add(uncleDiff, uncle.Difficulty)
+ }
+
+ // TD(genesis_block) = 0 and TD(B) = TD(B.parent) + sum(u.difficulty for u in B.uncles) + B.difficulty
+ td := new(big.Int)
+ td = td.Add(parent.Td, uncleDiff)
+ td = td.Add(td, block.Header().Difficulty)
+
+ return td
+}
+
+func CalcGasLimit(parent, block *types.Block) *big.Int {
+ if block.Number().Cmp(big.NewInt(0)) == 0 {
+ return common.BigPow(10, 6)
+ }
+
+ // ((1024-1) * parent.gasLimit + (gasUsed * 6 / 5)) / 1024
+ previous := new(big.Int).Mul(big.NewInt(1024-1), parent.GasLimit())
+ current := new(big.Rat).Mul(new(big.Rat).SetInt(parent.GasUsed()), big.NewRat(6, 5))
+ curInt := new(big.Int).Div(current.Num(), current.Denom())
+
+ result := new(big.Int).Add(previous, curInt)
+ result.Div(result, big.NewInt(1024))
+
+ return common.BigMax(params.GenesisGasLimit, result)
+}
+
+type ChainManager struct {
+ //eth EthManager
+ blockDb common.Database
+ stateDb common.Database
+ processor types.BlockProcessor
+ eventMux *event.TypeMux
+ genesisBlock *types.Block
+ // Last known total difficulty
+ mu sync.RWMutex
+ tsmu sync.RWMutex
+ td *big.Int
+ currentBlock *types.Block
+ lastBlockHash common.Hash
+
+ transState *state.StateDB
+ txState *state.ManagedState
+
+ cache *BlockCache
+
+ quit chan struct{}
+}
+
+func NewChainManager(blockDb, stateDb common.Database, mux *event.TypeMux) *ChainManager {
+ bc := &ChainManager{blockDb: blockDb, stateDb: stateDb, genesisBlock: GenesisBlock(stateDb), eventMux: mux, quit: make(chan struct{}), cache: NewBlockCache(blockCacheLimit)}
+ bc.setLastBlock()
+ bc.transState = bc.State().Copy()
+ // Take ownership of this particular state
+ bc.txState = state.ManageState(bc.State().Copy())
+
+ bc.makeCache()
+
+ go bc.update()
+
+ return bc
+}
+
+func (self *ChainManager) Td() *big.Int {
+ self.mu.RLock()
+ defer self.mu.RUnlock()
+
+ return self.td
+}
+
+func (self *ChainManager) LastBlockHash() common.Hash {
+ self.mu.RLock()
+ defer self.mu.RUnlock()
+
+ return self.lastBlockHash
+}
+
+func (self *ChainManager) CurrentBlock() *types.Block {
+ self.mu.RLock()
+ defer self.mu.RUnlock()
+
+ return self.currentBlock
+}
+
+func (self *ChainManager) Status() (td *big.Int, currentBlock common.Hash, genesisBlock common.Hash) {
+ self.mu.RLock()
+ defer self.mu.RUnlock()
+
+ return self.td, self.currentBlock.Hash(), self.genesisBlock.Hash()
+}
+
+func (self *ChainManager) SetProcessor(proc types.BlockProcessor) {
+ self.processor = proc
+}
+
+func (self *ChainManager) State() *state.StateDB {
+ return state.New(self.CurrentBlock().Root(), self.stateDb)
+}
+
+func (self *ChainManager) TransState() *state.StateDB {
+ self.tsmu.RLock()
+ defer self.tsmu.RUnlock()
+
+ return self.transState
+}
+
+func (self *ChainManager) TxState() *state.ManagedState {
+ self.tsmu.RLock()
+ defer self.tsmu.RUnlock()
+
+ return self.txState
+}
+
+func (self *ChainManager) setTxState(statedb *state.StateDB) {
+ self.tsmu.Lock()
+ defer self.tsmu.Unlock()
+ self.txState = state.ManageState(statedb)
+}
+
+func (self *ChainManager) setTransState(statedb *state.StateDB) {
+ self.transState = statedb
+}
+
+func (bc *ChainManager) setLastBlock() {
+ data, _ := bc.blockDb.Get([]byte("LastBlock"))
+ if len(data) != 0 {
+ block := bc.GetBlock(common.BytesToHash(data))
+ bc.currentBlock = block
+ bc.lastBlockHash = block.Hash()
+
+ // Set the last know difficulty (might be 0x0 as initial value, Genesis)
+ bc.td = common.BigD(bc.blockDb.LastKnownTD())
+ } else {
+ bc.Reset()
+ }
+
+ chainlogger.Infof("Last block (#%v) %x TD=%v\n", bc.currentBlock.Number(), bc.currentBlock.Hash(), bc.td)
+}
+
+func (bc *ChainManager) makeCache() {
+ if bc.cache == nil {
+ bc.cache = NewBlockCache(blockCacheLimit)
+ }
+ // load in last `blockCacheLimit` - 1 blocks. Last block is the current.
+ ancestors := bc.GetAncestors(bc.currentBlock, blockCacheLimit-1)
+ ancestors = append(ancestors, bc.currentBlock)
+ for _, block := range ancestors {
+ bc.cache.Push(block)
+ }
+}
+
+// Block creation & chain handling
+func (bc *ChainManager) NewBlock(coinbase common.Address) *types.Block {
+ bc.mu.RLock()
+ defer bc.mu.RUnlock()
+
+ var (
+ root common.Hash
+ parentHash common.Hash
+ )
+
+ if bc.currentBlock != nil {
+ root = bc.currentBlock.Header().Root
+ parentHash = bc.lastBlockHash
+ }
+
+ block := types.NewBlock(
+ parentHash,
+ coinbase,
+ root,
+ common.BigPow(2, 32),
+ 0,
+ "")
+ block.SetUncles(nil)
+ block.SetTransactions(nil)
+ block.SetReceipts(nil)
+
+ parent := bc.currentBlock
+ if parent != nil {
+ header := block.Header()
+ header.Difficulty = CalcDifficulty(block.Header(), parent.Header())
+ header.Number = new(big.Int).Add(parent.Header().Number, common.Big1)
+ header.GasLimit = CalcGasLimit(parent, block)
+
+ }
+
+ return block
+}
+
+func (bc *ChainManager) Reset() {
+ bc.mu.Lock()
+ defer bc.mu.Unlock()
+
+ for block := bc.currentBlock; block != nil; block = bc.GetBlock(block.Header().ParentHash) {
+ bc.removeBlock(block)
+ }
+
+ if bc.cache == nil {
+ bc.cache = NewBlockCache(blockCacheLimit)
+ }
+
+ // Prepare the genesis block
+ bc.write(bc.genesisBlock)
+ bc.insert(bc.genesisBlock)
+ bc.currentBlock = bc.genesisBlock
+ bc.makeCache()
+
+ bc.setTotalDifficulty(common.Big("0"))
+}
+
+func (bc *ChainManager) removeBlock(block *types.Block) {
+ bc.blockDb.Delete(append(blockHashPre, block.Hash().Bytes()...))
+}
+
+func (bc *ChainManager) ResetWithGenesisBlock(gb *types.Block) {
+ bc.mu.Lock()
+ defer bc.mu.Unlock()
+
+ for block := bc.currentBlock; block != nil; block = bc.GetBlock(block.Header().ParentHash) {
+ bc.removeBlock(block)
+ }
+
+ // Prepare the genesis block
+ bc.genesisBlock = gb
+ bc.write(bc.genesisBlock)
+ bc.insert(bc.genesisBlock)
+ bc.currentBlock = bc.genesisBlock
+ bc.makeCache()
+}
+
+// Export writes the active chain to the given writer.
+func (self *ChainManager) Export(w io.Writer) error {
+ self.mu.RLock()
+ defer self.mu.RUnlock()
+ chainlogger.Infof("exporting %v blocks...\n", self.currentBlock.Header().Number)
+ for block := self.currentBlock; block != nil; block = self.GetBlock(block.Header().ParentHash) {
+ if err := block.EncodeRLP(w); err != nil {
+ return err
+ }
+ }
+ return nil
+}
+
+func (bc *ChainManager) insert(block *types.Block) {
+ bc.blockDb.Put([]byte("LastBlock"), block.Hash().Bytes())
+ bc.currentBlock = block
+ bc.lastBlockHash = block.Hash()
+
+ key := append(blockNumPre, block.Number().Bytes()...)
+ bc.blockDb.Put(key, bc.lastBlockHash.Bytes())
+ // Push block to cache
+ bc.cache.Push(block)
+}
+
+func (bc *ChainManager) write(block *types.Block) {
+ enc, _ := rlp.EncodeToBytes((*types.StorageBlock)(block))
+ key := append(blockHashPre, block.Hash().Bytes()...)
+ bc.blockDb.Put(key, enc)
+}
+
+// Accessors
+func (bc *ChainManager) Genesis() *types.Block {
+ return bc.genesisBlock
+}
+
+// Block fetching methods
+func (bc *ChainManager) HasBlock(hash common.Hash) bool {
+ data, _ := bc.blockDb.Get(append(blockHashPre, hash[:]...))
+ return len(data) != 0
+}
+
+func (self *ChainManager) GetBlockHashesFromHash(hash common.Hash, max uint64) (chain []common.Hash) {
+ block := self.GetBlock(hash)
+ if block == nil {
+ return
+ }
+ // XXX Could be optimised by using a different database which only holds hashes (i.e., linked list)
+ for i := uint64(0); i < max; i++ {
+ parentHash := block.Header().ParentHash
+ block = self.GetBlock(parentHash)
+ if block == nil {
+ chainlogger.Infof("GetBlockHashesFromHash Parent UNKNOWN %x\n", parentHash)
+ break
+ }
+
+ chain = append(chain, block.Hash())
+ if block.Header().Number.Cmp(common.Big0) <= 0 {
+ break
+ }
+ }
+
+ return
+}
+
+func (self *ChainManager) GetBlock(hash common.Hash) *types.Block {
+ if block := self.cache.Get(hash); block != nil {
+ return block
+ }
+
+ data, _ := self.blockDb.Get(append(blockHashPre, hash[:]...))
+ if len(data) == 0 {
+ return nil
+ }
+ var block types.StorageBlock
+ if err := rlp.Decode(bytes.NewReader(data), &block); err != nil {
+ chainlogger.Errorf("invalid block RLP for hash %x: %v", hash, err)
+ return nil
+ }
+ return (*types.Block)(&block)
+}
+
+func (self *ChainManager) GetBlockByNumber(num uint64) *types.Block {
+ self.mu.RLock()
+ defer self.mu.RUnlock()
+
+ key, _ := self.blockDb.Get(append(blockNumPre, big.NewInt(int64(num)).Bytes()...))
+ if len(key) == 0 {
+ return nil
+ }
+
+ return self.GetBlock(common.BytesToHash(key))
+}
+
+func (self *ChainManager) GetUnclesInChain(block *types.Block, length int) (uncles []*types.Header) {
+ for i := 0; block != nil && i < length; i++ {
+ uncles = append(uncles, block.Uncles()...)
+ block = self.GetBlock(block.ParentHash())
+ }
+
+ return
+}
+
+func (self *ChainManager) GetAncestors(block *types.Block, length int) (blocks []*types.Block) {
+ for i := 0; i < length; i++ {
+ block = self.GetBlock(block.ParentHash())
+ if block == nil {
+ break
+ }
+
+ blocks = append(blocks, block)
+ }
+
+ return
+}
+
+func (bc *ChainManager) setTotalDifficulty(td *big.Int) {
+ bc.blockDb.Put([]byte("LTD"), td.Bytes())
+ bc.td = td
+}
+
+func (self *ChainManager) CalcTotalDiff(block *types.Block) (*big.Int, error) {
+ parent := self.GetBlock(block.Header().ParentHash)
+ if parent == nil {
+ return nil, fmt.Errorf("Unable to calculate total diff without known parent %x", block.Header().ParentHash)
+ }
+
+ parentTd := parent.Td
+
+ uncleDiff := new(big.Int)
+ for _, uncle := range block.Uncles() {
+ uncleDiff = uncleDiff.Add(uncleDiff, uncle.Difficulty)
+ }
+
+ td := new(big.Int)
+ td = td.Add(parentTd, uncleDiff)
+ td = td.Add(td, block.Header().Difficulty)
+
+ return td, nil
+}
+
+func (bc *ChainManager) Stop() {
+ close(bc.quit)
+}
+
+type queueEvent struct {
+ queue []interface{}
+ canonicalCount int
+ sideCount int
+ splitCount int
+}
+
+func (self *ChainManager) InsertChain(chain types.Blocks) error {
+ //self.tsmu.Lock()
+ //defer self.tsmu.Unlock()
+
+ // A queued approach to delivering events. This is generally faster than direct delivery and requires much less mutex acquiring.
+ var queue = make([]interface{}, len(chain))
+ var queueEvent = queueEvent{queue: queue}
+ for i, block := range chain {
+ // Call in to the block processor and check for errors. It's likely that if one block fails
+ // all others will fail too (unless a known block is returned).
+ td, logs, err := self.processor.Process(block)
+ if err != nil {
+ if IsKnownBlockErr(err) {
+ continue
+ }
+
+ if err == BlockEqualTSErr {
+ queue[i] = ChainSideEvent{block, logs}
+ continue
+ }
+
+ h := block.Header()
+ chainlogger.Errorf("INVALID block #%v (%x)\n", h.Number, h.Hash().Bytes()[:4])
+ chainlogger.Errorln(err)
+ chainlogger.Debugln(block)
+ return err
+ }
+ block.Td = td
+
+ self.mu.Lock()
+ cblock := self.currentBlock
+ {
+ // Write block to database. Eventually we'll have to improve on this and throw away blocks that are
+ // not in the canonical chain.
+ self.write(block)
+ // Compare the TD of the last known block in the canonical chain to make sure it's greater.
+ // At this point it's possible that a different chain (fork) becomes the new canonical chain.
+ if td.Cmp(self.td) > 0 {
+ if block.Header().Number.Cmp(new(big.Int).Add(cblock.Header().Number, common.Big1)) < 0 {
+ chash := cblock.Hash()
+ hash := block.Hash()
+ chainlogger.Infof("Split detected. New head #%v (%x) TD=%v, was #%v (%x) TD=%v\n", block.Header().Number, hash[:4], td, cblock.Header().Number, chash[:4], self.td)
+
+ queue[i] = ChainSplitEvent{block, logs}
+ queueEvent.splitCount++
+ }
+
+ self.setTotalDifficulty(td)
+ self.insert(block)
+
+ jsonlogger.LogJson(&logger.EthChainNewHead{
+ BlockHash: block.Hash().Hex(),
+ BlockNumber: block.Number(),
+ ChainHeadHash: cblock.Hash().Hex(),
+ BlockPrevHash: block.ParentHash().Hex(),
+ })
+
+ self.setTransState(state.New(block.Root(), self.stateDb))
+ self.setTxState(state.New(block.Root(), self.stateDb))
+
+ queue[i] = ChainEvent{block, logs}
+ queueEvent.canonicalCount++
+ } else {
+ queue[i] = ChainSideEvent{block, logs}
+ queueEvent.sideCount++
+ }
+ }
+ self.mu.Unlock()
+
+ }
+
+ go self.eventMux.Post(queueEvent)
+
+ return nil
+}
+
+func (self *ChainManager) update() {
+ events := self.eventMux.Subscribe(queueEvent{})
+
+out:
+ for {
+ select {
+ case ev := <-events.Chan():
+ switch ev := ev.(type) {
+ case queueEvent:
+ for i, event := range ev.queue {
+ switch event := event.(type) {
+ case ChainEvent:
+ // We need some control over the mining operation. Acquiring locks and waiting for the miner to create new block takes too long
+ // and in most cases isn't even necessary.
+ if i+1 == ev.canonicalCount {
+ self.eventMux.Post(ChainHeadEvent{event.Block})
+ }
+ case ChainSplitEvent:
+ // On chain splits we need to reset the transaction state. We can't be sure whether the actual
+ // state of the accounts are still valid.
+ if i == ev.splitCount {
+ self.setTxState(state.New(event.Block.Root(), self.stateDb))
+ }
+ }
+
+ self.eventMux.Post(event)
+ }
+ }
+ case <-self.quit:
+ break out
+ }
+ }
+}
diff --git a/core/chain_manager_test.go b/core/chain_manager_test.go
new file mode 100644
index 000000000..bf172f3bf
--- /dev/null
+++ b/core/chain_manager_test.go
@@ -0,0 +1,345 @@
+package core
+
+import (
+ "fmt"
+ "math/big"
+ "os"
+ "path"
+ "runtime"
+ "strconv"
+ "testing"
+
+ "github.com/ethereum/go-ethereum/core/types"
+ "github.com/ethereum/go-ethereum/ethdb"
+ "github.com/ethereum/go-ethereum/event"
+ "github.com/ethereum/go-ethereum/rlp"
+)
+
+func init() {
+ runtime.GOMAXPROCS(runtime.NumCPU())
+}
+
+// Test fork of length N starting from block i
+func testFork(t *testing.T, bman *BlockProcessor, i, N int, f func(td1, td2 *big.Int)) {
+ // switch databases to process the new chain
+ db, err := ethdb.NewMemDatabase()
+ if err != nil {
+ t.Fatal("Failed to create db:", err)
+ }
+ // copy old chain up to i into new db with deterministic canonical
+ bman2, err := newCanonical(i, db)
+ if err != nil {
+ t.Fatal("could not make new canonical in testFork", err)
+ }
+ // asert the bmans have the same block at i
+ bi1 := bman.bc.GetBlockByNumber(uint64(i)).Hash()
+ bi2 := bman2.bc.GetBlockByNumber(uint64(i)).Hash()
+ if bi1 != bi2 {
+ t.Fatal("chains do not have the same hash at height", i)
+ }
+
+ bman2.bc.SetProcessor(bman2)
+
+ // extend the fork
+ parent := bman2.bc.CurrentBlock()
+ chainB := makeChain(bman2, parent, N, db, ForkSeed)
+ err = bman2.bc.InsertChain(chainB)
+ if err != nil {
+ t.Fatal("Insert chain error for fork:", err)
+ }
+
+ tdpre := bman.bc.Td()
+ // Test the fork's blocks on the original chain
+ td, err := testChain(chainB, bman)
+ if err != nil {
+ t.Fatal("expected chainB not to give errors:", err)
+ }
+ // Compare difficulties
+ f(tdpre, td)
+}
+
+func printChain(bc *ChainManager) {
+ for i := bc.CurrentBlock().Number().Uint64(); i > 0; i-- {
+ b := bc.GetBlockByNumber(uint64(i))
+ fmt.Printf("\t%x\n", b.Hash())
+ }
+}
+
+// process blocks against a chain
+func testChain(chainB types.Blocks, bman *BlockProcessor) (*big.Int, error) {
+ td := new(big.Int)
+ for _, block := range chainB {
+ td2, _, err := bman.bc.processor.Process(block)
+ if err != nil {
+ if IsKnownBlockErr(err) {
+ continue
+ }
+ return nil, err
+ }
+ block.Td = td2
+ td = td2
+
+ bman.bc.mu.Lock()
+ {
+ bman.bc.write(block)
+ }
+ bman.bc.mu.Unlock()
+ }
+ return td, nil
+}
+
+func loadChain(fn string, t *testing.T) (types.Blocks, error) {
+ fh, err := os.OpenFile(path.Join(os.Getenv("GOPATH"), "src", "github.com", "ethereum", "go-ethereum", "_data", fn), os.O_RDONLY, os.ModePerm)
+ if err != nil {
+ return nil, err
+ }
+ defer fh.Close()
+
+ var chain types.Blocks
+ if err := rlp.Decode(fh, &chain); err != nil {
+ return nil, err
+ }
+
+ return chain, nil
+}
+
+func insertChain(done chan bool, chainMan *ChainManager, chain types.Blocks, t *testing.T) {
+ err := chainMan.InsertChain(chain)
+ if err != nil {
+ fmt.Println(err)
+ t.FailNow()
+ }
+ done <- true
+}
+
+func TestExtendCanonical(t *testing.T) {
+ CanonicalLength := 5
+ db, err := ethdb.NewMemDatabase()
+ if err != nil {
+ t.Fatal("Failed to create db:", err)
+ }
+ // make first chain starting from genesis
+ bman, err := newCanonical(CanonicalLength, db)
+ if err != nil {
+ t.Fatal("Could not make new canonical chain:", err)
+ }
+ f := func(td1, td2 *big.Int) {
+ if td2.Cmp(td1) <= 0 {
+ t.Error("expected chainB to have higher difficulty. Got", td2, "expected more than", td1)
+ }
+ }
+ // Start fork from current height (CanonicalLength)
+ testFork(t, bman, CanonicalLength, 1, f)
+ testFork(t, bman, CanonicalLength, 2, f)
+ testFork(t, bman, CanonicalLength, 5, f)
+ testFork(t, bman, CanonicalLength, 10, f)
+}
+
+func TestShorterFork(t *testing.T) {
+ db, err := ethdb.NewMemDatabase()
+ if err != nil {
+ t.Fatal("Failed to create db:", err)
+ }
+ // make first chain starting from genesis
+ bman, err := newCanonical(10, db)
+ if err != nil {
+ t.Fatal("Could not make new canonical chain:", err)
+ }
+ f := func(td1, td2 *big.Int) {
+ if td2.Cmp(td1) >= 0 {
+ t.Error("expected chainB to have lower difficulty. Got", td2, "expected less than", td1)
+ }
+ }
+ // Sum of numbers must be less than 10
+ // for this to be a shorter fork
+ testFork(t, bman, 0, 3, f)
+ testFork(t, bman, 0, 7, f)
+ testFork(t, bman, 1, 1, f)
+ testFork(t, bman, 1, 7, f)
+ testFork(t, bman, 5, 3, f)
+ testFork(t, bman, 5, 4, f)
+}
+
+func TestLongerFork(t *testing.T) {
+ db, err := ethdb.NewMemDatabase()
+ if err != nil {
+ t.Fatal("Failed to create db:", err)
+ }
+ // make first chain starting from genesis
+ bman, err := newCanonical(10, db)
+ if err != nil {
+ t.Fatal("Could not make new canonical chain:", err)
+ }
+ f := func(td1, td2 *big.Int) {
+ if td2.Cmp(td1) <= 0 {
+ t.Error("expected chainB to have higher difficulty. Got", td2, "expected more than", td1)
+ }
+ }
+ // Sum of numbers must be greater than 10
+ // for this to be a longer fork
+ testFork(t, bman, 0, 11, f)
+ testFork(t, bman, 0, 15, f)
+ testFork(t, bman, 1, 10, f)
+ testFork(t, bman, 1, 12, f)
+ testFork(t, bman, 5, 6, f)
+ testFork(t, bman, 5, 8, f)
+}
+
+func TestEqualFork(t *testing.T) {
+ db, err := ethdb.NewMemDatabase()
+ if err != nil {
+ t.Fatal("Failed to create db:", err)
+ }
+ bman, err := newCanonical(10, db)
+ if err != nil {
+ t.Fatal("Could not make new canonical chain:", err)
+ }
+ f := func(td1, td2 *big.Int) {
+ if td2.Cmp(td1) != 0 {
+ t.Error("expected chainB to have equal difficulty. Got", td2, "expected ", td1)
+ }
+ }
+ // Sum of numbers must be equal to 10
+ // for this to be an equal fork
+ testFork(t, bman, 0, 10, f)
+ testFork(t, bman, 1, 9, f)
+ testFork(t, bman, 2, 8, f)
+ testFork(t, bman, 5, 5, f)
+ testFork(t, bman, 6, 4, f)
+ testFork(t, bman, 9, 1, f)
+}
+
+func TestBrokenChain(t *testing.T) {
+ db, err := ethdb.NewMemDatabase()
+ if err != nil {
+ t.Fatal("Failed to create db:", err)
+ }
+ bman, err := newCanonical(10, db)
+ if err != nil {
+ t.Fatal("Could not make new canonical chain:", err)
+ }
+ db2, err := ethdb.NewMemDatabase()
+ if err != nil {
+ t.Fatal("Failed to create db:", err)
+ }
+ bman2, err := newCanonical(10, db2)
+ if err != nil {
+ t.Fatal("Could not make new canonical chain:", err)
+ }
+ bman2.bc.SetProcessor(bman2)
+ parent := bman2.bc.CurrentBlock()
+ chainB := makeChain(bman2, parent, 5, db2, ForkSeed)
+ chainB = chainB[1:]
+ _, err = testChain(chainB, bman)
+ if err == nil {
+ t.Error("expected broken chain to return error")
+ }
+}
+
+func TestChainInsertions(t *testing.T) {
+ t.Skip() // travil fails.
+
+ db, _ := ethdb.NewMemDatabase()
+
+ chain1, err := loadChain("valid1", t)
+ if err != nil {
+ fmt.Println(err)
+ t.FailNow()
+ }
+
+ chain2, err := loadChain("valid2", t)
+ if err != nil {
+ fmt.Println(err)
+ t.FailNow()
+ }
+
+ var eventMux event.TypeMux
+ chainMan := NewChainManager(db, db, &eventMux)
+ txPool := NewTxPool(&eventMux)
+ blockMan := NewBlockProcessor(db, db, nil, txPool, chainMan, &eventMux)
+ chainMan.SetProcessor(blockMan)
+
+ const max = 2
+ done := make(chan bool, max)
+
+ go insertChain(done, chainMan, chain1, t)
+ go insertChain(done, chainMan, chain2, t)
+
+ for i := 0; i < max; i++ {
+ <-done
+ }
+
+ if chain2[len(chain2)-1].Hash() != chainMan.CurrentBlock().Hash() {
+ t.Error("chain2 is canonical and shouldn't be")
+ }
+
+ if chain1[len(chain1)-1].Hash() != chainMan.CurrentBlock().Hash() {
+ t.Error("chain1 isn't canonical and should be")
+ }
+}
+
+func TestChainMultipleInsertions(t *testing.T) {
+ t.Skip() // travil fails.
+
+ db, _ := ethdb.NewMemDatabase()
+
+ const max = 4
+ chains := make([]types.Blocks, max)
+ var longest int
+ for i := 0; i < max; i++ {
+ var err error
+ name := "valid" + strconv.Itoa(i+1)
+ chains[i], err = loadChain(name, t)
+ if len(chains[i]) >= len(chains[longest]) {
+ longest = i
+ }
+ fmt.Println("loaded", name, "with a length of", len(chains[i]))
+ if err != nil {
+ fmt.Println(err)
+ t.FailNow()
+ }
+ }
+ var eventMux event.TypeMux
+ chainMan := NewChainManager(db, db, &eventMux)
+ txPool := NewTxPool(&eventMux)
+ blockMan := NewBlockProcessor(db, db, nil, txPool, chainMan, &eventMux)
+ chainMan.SetProcessor(blockMan)
+ done := make(chan bool, max)
+ for i, chain := range chains {
+ // XXX the go routine would otherwise reference the same (chain[3]) variable and fail
+ i := i
+ chain := chain
+ go func() {
+ insertChain(done, chainMan, chain, t)
+ fmt.Println(i, "done")
+ }()
+ }
+
+ for i := 0; i < max; i++ {
+ <-done
+ }
+
+ if chains[longest][len(chains[longest])-1].Hash() != chainMan.CurrentBlock().Hash() {
+ t.Error("Invalid canonical chain")
+ }
+}
+
+func TestGetAncestors(t *testing.T) {
+ t.Skip() // travil fails.
+
+ db, _ := ethdb.NewMemDatabase()
+ var eventMux event.TypeMux
+ chainMan := NewChainManager(db, db, &eventMux)
+ chain, err := loadChain("valid1", t)
+ if err != nil {
+ fmt.Println(err)
+ t.FailNow()
+ }
+
+ for _, block := range chain {
+ chainMan.write(block)
+ }
+
+ ancestors := chainMan.GetAncestors(chain[len(chain)-1], 4)
+ fmt.Println(ancestors)
+}
diff --git a/core/error.go b/core/error.go
new file mode 100644
index 000000000..0642948cd
--- /dev/null
+++ b/core/error.go
@@ -0,0 +1,167 @@
+package core
+
+import (
+ "errors"
+ "fmt"
+ "math/big"
+
+ "github.com/ethereum/go-ethereum/common"
+)
+
+var (
+ BlockNumberErr = errors.New("block number invalid")
+ BlockFutureErr = errors.New("block time is in the future")
+ BlockEqualTSErr = errors.New("block time stamp equal to previous")
+)
+
+// Parent error. In case a parent is unknown this error will be thrown
+// by the block manager
+type ParentErr struct {
+ Message string
+}
+
+func (err *ParentErr) Error() string {
+ return err.Message
+}
+
+func ParentError(hash common.Hash) error {
+ return &ParentErr{Message: fmt.Sprintf("Block's parent unknown %x", hash)}
+}
+
+func IsParentErr(err error) bool {
+ _, ok := err.(*ParentErr)
+
+ return ok
+}
+
+type UncleErr struct {
+ Message string
+}
+
+func (err *UncleErr) Error() string {
+ return err.Message
+}
+
+func UncleError(str string) error {
+ return &UncleErr{Message: str}
+}
+
+func IsUncleErr(err error) bool {
+ _, ok := err.(*UncleErr)
+
+ return ok
+}
+
+// Block validation error. If any validation fails, this error will be thrown
+type ValidationErr struct {
+ Message string
+}
+
+func (err *ValidationErr) Error() string {
+ return err.Message
+}
+
+func ValidationError(format string, v ...interface{}) *ValidationErr {
+ return &ValidationErr{Message: fmt.Sprintf(format, v...)}
+}
+
+func IsValidationErr(err error) bool {
+ _, ok := err.(*ValidationErr)
+
+ return ok
+}
+
+type NonceErr struct {
+ Message string
+ Is, Exp uint64
+}
+
+func (err *NonceErr) Error() string {
+ return err.Message
+}
+
+func NonceError(is, exp uint64) *NonceErr {
+ return &NonceErr{Message: fmt.Sprintf("Transaction w/ invalid nonce (%d / %d)", is, exp), Is: is, Exp: exp}
+}
+
+func IsNonceErr(err error) bool {
+ _, ok := err.(*NonceErr)
+
+ return ok
+}
+
+type InvalidTxErr struct {
+ Message string
+}
+
+func (err *InvalidTxErr) Error() string {
+ return err.Message
+}
+
+func InvalidTxError(err error) *InvalidTxErr {
+ return &InvalidTxErr{fmt.Sprintf("%v", err)}
+}
+
+func IsInvalidTxErr(err error) bool {
+ _, ok := err.(*InvalidTxErr)
+
+ return ok
+}
+
+type OutOfGasErr struct {
+ Message string
+}
+
+func OutOfGasError() *OutOfGasErr {
+ return &OutOfGasErr{Message: "Out of gas"}
+}
+func (self *OutOfGasErr) Error() string {
+ return self.Message
+}
+
+func IsOutOfGasErr(err error) bool {
+ _, ok := err.(*OutOfGasErr)
+
+ return ok
+}
+
+type TDError struct {
+ a, b *big.Int
+}
+
+func (self *TDError) Error() string {
+ return fmt.Sprintf("incoming chain has a lower or equal TD (%v <= %v)", self.a, self.b)
+}
+func IsTDError(e error) bool {
+ _, ok := e.(*TDError)
+ return ok
+}
+
+type KnownBlockError struct {
+ number *big.Int
+ hash common.Hash
+}
+
+func (self *KnownBlockError) Error() string {
+ return fmt.Sprintf("block %v already known (%x)", self.number, self.hash[0:4])
+}
+func IsKnownBlockErr(e error) bool {
+ _, ok := e.(*KnownBlockError)
+ return ok
+}
+
+type ValueTransferError struct {
+ message string
+}
+
+func ValueTransferErr(str string, v ...interface{}) *ValueTransferError {
+ return &ValueTransferError{fmt.Sprintf(str, v...)}
+}
+
+func (self *ValueTransferError) Error() string {
+ return self.message
+}
+func IsValueTransferErr(e error) bool {
+ _, ok := e.(*ValueTransferError)
+ return ok
+}
diff --git a/core/events.go b/core/events.go
new file mode 100644
index 000000000..3da668af5
--- /dev/null
+++ b/core/events.go
@@ -0,0 +1,49 @@
+package core
+
+import (
+ "github.com/ethereum/go-ethereum/core/types"
+ "github.com/ethereum/go-ethereum/core/state"
+)
+
+// TxPreEvent is posted when a transaction enters the transaction pool.
+type TxPreEvent struct{ Tx *types.Transaction }
+
+// TxPostEvent is posted when a transaction has been processed.
+type TxPostEvent struct{ Tx *types.Transaction }
+
+// NewBlockEvent is posted when a block has been imported.
+type NewBlockEvent struct{ Block *types.Block }
+
+// NewMinedBlockEvent is posted when a block has been imported.
+type NewMinedBlockEvent struct{ Block *types.Block }
+
+// ChainSplit is posted when a new head is detected
+type ChainSplitEvent struct {
+ Block *types.Block
+ Logs state.Logs
+}
+
+type ChainEvent struct {
+ Block *types.Block
+ Logs state.Logs
+}
+
+type ChainSideEvent struct {
+ Block *types.Block
+ Logs state.Logs
+}
+
+type PendingBlockEvent struct {
+ Block *types.Block
+ Logs state.Logs
+}
+
+type ChainUncleEvent struct {
+ Block *types.Block
+}
+
+type ChainHeadEvent struct{ Block *types.Block }
+
+// Mining operation events
+type StartMining struct{}
+type TopMining struct{}
diff --git a/core/execution.go b/core/execution.go
new file mode 100644
index 000000000..8134471d1
--- /dev/null
+++ b/core/execution.go
@@ -0,0 +1,96 @@
+package core
+
+import (
+ "math/big"
+ "time"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/core/state"
+ "github.com/ethereum/go-ethereum/core/vm"
+ "github.com/ethereum/go-ethereum/crypto"
+ "github.com/ethereum/go-ethereum/params"
+)
+
+type Execution struct {
+ env vm.Environment
+ address *common.Address
+ input []byte
+ evm vm.VirtualMachine
+
+ Gas, price, value *big.Int
+}
+
+func NewExecution(env vm.Environment, address *common.Address, input []byte, gas, gasPrice, value *big.Int) *Execution {
+ exe := &Execution{env: env, address: address, input: input, Gas: gas, price: gasPrice, value: value}
+ exe.evm = vm.NewVm(env)
+ return exe
+}
+
+func (self *Execution) Call(codeAddr common.Address, caller vm.ContextRef) ([]byte, error) {
+ // Retrieve the executing code
+ code := self.env.State().GetCode(codeAddr)
+
+ return self.exec(&codeAddr, code, caller)
+}
+
+func (self *Execution) Create(caller vm.ContextRef) (ret []byte, err error, account *state.StateObject) {
+ ret, err = self.exec(nil, self.input, caller)
+ account = self.env.State().GetStateObject(*self.address)
+ return
+}
+
+func (self *Execution) exec(contextAddr *common.Address, code []byte, caller vm.ContextRef) (ret []byte, err error) {
+ start := time.Now()
+
+ env := self.env
+ evm := self.evm
+ if env.Depth() > int(params.CallCreateDepth.Int64()) {
+ caller.ReturnGas(self.Gas, self.price)
+
+ return nil, vm.DepthError{}
+ }
+
+ vsnapshot := env.State().Copy()
+ var createAccount bool
+ if self.address == nil {
+ // Generate a new address
+ nonce := env.State().GetNonce(caller.Address())
+ env.State().SetNonce(caller.Address(), nonce+1)
+
+ addr := crypto.CreateAddress(caller.Address(), nonce)
+
+ self.address = &addr
+ createAccount = true
+ }
+ snapshot := env.State().Copy()
+
+ var (
+ from = env.State().GetStateObject(caller.Address())
+ to *state.StateObject
+ )
+ if createAccount {
+ to = env.State().CreateAccount(*self.address)
+ } else {
+ to = env.State().GetOrNewStateObject(*self.address)
+ }
+
+ err = env.Transfer(from, to, self.value)
+ if err != nil {
+ env.State().Set(vsnapshot)
+
+ caller.ReturnGas(self.Gas, self.price)
+
+ return nil, ValueTransferErr("insufficient funds to transfer value. Req %v, has %v", self.value, from.Balance())
+ }
+
+ context := vm.NewContext(caller, to, self.value, self.Gas, self.price)
+ context.SetCallCode(contextAddr, code)
+
+ ret, err = evm.Run(context, self.input)
+ evm.Printf("message call took %v", time.Since(start)).Endl()
+ if err != nil {
+ env.State().Set(snapshot)
+ }
+
+ return
+}
diff --git a/core/fees.go b/core/fees.go
new file mode 100644
index 000000000..bbce01b84
--- /dev/null
+++ b/core/fees.go
@@ -0,0 +1,7 @@
+package core
+
+import (
+ "math/big"
+)
+
+var BlockReward *big.Int = big.NewInt(1.5e+18)
diff --git a/core/filter.go b/core/filter.go
new file mode 100644
index 000000000..1dca5501d
--- /dev/null
+++ b/core/filter.go
@@ -0,0 +1,181 @@
+package core
+
+import (
+ "math"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/core/state"
+ "github.com/ethereum/go-ethereum/core/types"
+)
+
+type AccountChange struct {
+ Address, StateAddress []byte
+}
+
+// Filtering interface
+type Filter struct {
+ eth Backend
+ earliest int64
+ latest int64
+ skip int
+ address []common.Address
+ max int
+ topics [][]common.Hash
+
+ BlockCallback func(*types.Block, state.Logs)
+ PendingCallback func(*types.Transaction)
+ LogsCallback func(state.Logs)
+}
+
+// Create a new filter which uses a bloom filter on blocks to figure out whether a particular block
+// is interesting or not.
+func NewFilter(eth Backend) *Filter {
+ return &Filter{eth: eth}
+}
+
+// Set the earliest and latest block for filtering.
+// -1 = latest block (i.e., the current block)
+// hash = particular hash from-to
+func (self *Filter) SetEarliestBlock(earliest int64) {
+ self.earliest = earliest
+}
+
+func (self *Filter) SetLatestBlock(latest int64) {
+ self.latest = latest
+}
+
+func (self *Filter) SetAddress(addr []common.Address) {
+ self.address = addr
+}
+
+func (self *Filter) SetTopics(topics [][]common.Hash) {
+ self.topics = topics
+}
+
+func (self *Filter) SetMax(max int) {
+ self.max = max
+}
+
+func (self *Filter) SetSkip(skip int) {
+ self.skip = skip
+}
+
+// Run filters logs with the current parameters set
+func (self *Filter) Find() state.Logs {
+ earliestBlock := self.eth.ChainManager().CurrentBlock()
+ var earliestBlockNo uint64 = uint64(self.earliest)
+ if self.earliest == -1 {
+ earliestBlockNo = earliestBlock.NumberU64()
+ }
+ var latestBlockNo uint64 = uint64(self.latest)
+ if self.latest == -1 {
+ latestBlockNo = earliestBlock.NumberU64()
+ }
+
+ var (
+ logs state.Logs
+ block = self.eth.ChainManager().GetBlockByNumber(latestBlockNo)
+ quit bool
+ )
+ for i := 0; !quit && block != nil; i++ {
+ // Quit on latest
+ switch {
+ case block.NumberU64() == earliestBlockNo, block.NumberU64() == 0:
+ quit = true
+ case self.max <= len(logs):
+ break
+ }
+
+ // Use bloom filtering to see if this block is interesting given the
+ // current parameters
+ if self.bloomFilter(block) {
+ // Get the logs of the block
+ unfiltered, err := self.eth.BlockProcessor().GetLogs(block)
+ if err != nil {
+ chainlogger.Warnln("err: filter get logs ", err)
+
+ break
+ }
+
+ logs = append(logs, self.FilterLogs(unfiltered)...)
+ }
+
+ block = self.eth.ChainManager().GetBlock(block.ParentHash())
+ }
+
+ skip := int(math.Min(float64(len(logs)), float64(self.skip)))
+
+ return logs[skip:]
+}
+
+func includes(addresses []common.Address, a common.Address) bool {
+ for _, addr := range addresses {
+ if addr != a {
+ return false
+ }
+ }
+
+ return true
+}
+
+func (self *Filter) FilterLogs(logs state.Logs) state.Logs {
+ var ret state.Logs
+
+ // Filter the logs for interesting stuff
+Logs:
+ for _, log := range logs {
+ if len(self.address) > 0 && !includes(self.address, log.Address()) {
+ continue
+ }
+
+ logTopics := make([]common.Hash, len(self.topics))
+ copy(logTopics, log.Topics())
+
+ for i, topics := range self.topics {
+ for _, topic := range topics {
+ var match bool
+ if log.Topics()[i] == topic {
+ match = true
+ }
+ if !match {
+ continue Logs
+ }
+ }
+ }
+
+ ret = append(ret, log)
+ }
+
+ return ret
+}
+
+func (self *Filter) bloomFilter(block *types.Block) bool {
+ if len(self.address) > 0 {
+ var included bool
+ for _, addr := range self.address {
+ if types.BloomLookup(block.Bloom(), addr.Hash()) {
+ included = true
+ break
+ }
+ }
+
+ if !included {
+ return false
+ }
+ }
+
+ for _, sub := range self.topics {
+ var included bool
+ for _, topic := range sub {
+ if types.BloomLookup(block.Bloom(), topic) {
+ included = true
+ break
+ }
+ }
+ if !included {
+ return false
+ }
+ }
+
+ return true
+}
diff --git a/core/filter_test.go b/core/filter_test.go
new file mode 100644
index 000000000..9a8bc9592
--- /dev/null
+++ b/core/filter_test.go
@@ -0,0 +1 @@
+package core
diff --git a/core/genesis.go b/core/genesis.go
new file mode 100644
index 000000000..13656c40c
--- /dev/null
+++ b/core/genesis.go
@@ -0,0 +1,72 @@
+package core
+
+import (
+ "encoding/json"
+ "fmt"
+ "os"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/core/state"
+ "github.com/ethereum/go-ethereum/core/types"
+ "github.com/ethereum/go-ethereum/params"
+)
+
+/*
+ * This is the special genesis block.
+ */
+
+var ZeroHash256 = make([]byte, 32)
+var ZeroHash160 = make([]byte, 20)
+var ZeroHash512 = make([]byte, 64)
+
+func GenesisBlock(db common.Database) *types.Block {
+ genesis := types.NewBlock(common.Hash{}, common.Address{}, common.Hash{}, params.GenesisDifficulty, 42, "")
+ genesis.Header().Number = common.Big0
+ genesis.Header().GasLimit = params.GenesisGasLimit
+ genesis.Header().GasUsed = common.Big0
+ genesis.Header().Time = 0
+
+ genesis.Td = common.Big0
+
+ genesis.SetUncles([]*types.Header{})
+ genesis.SetTransactions(types.Transactions{})
+ genesis.SetReceipts(types.Receipts{})
+
+ var accounts map[string]struct {
+ Balance string
+ Code string
+ }
+ err := json.Unmarshal(genesisData, &accounts)
+ if err != nil {
+ fmt.Println("enable to decode genesis json data:", err)
+ os.Exit(1)
+ }
+
+ statedb := state.New(genesis.Root(), db)
+ for addr, account := range accounts {
+ codedAddr := common.Hex2Bytes(addr)
+ accountState := statedb.CreateAccount(common.BytesToAddress(codedAddr))
+ accountState.SetBalance(common.Big(account.Balance))
+ accountState.SetCode(common.FromHex(account.Code))
+ statedb.UpdateStateObject(accountState)
+ }
+ statedb.Sync()
+ genesis.Header().Root = statedb.Root()
+
+ return genesis
+}
+
+var genesisData = []byte(`{
+ "0000000000000000000000000000000000000001": {"balance": "1"},
+ "0000000000000000000000000000000000000002": {"balance": "1"},
+ "0000000000000000000000000000000000000003": {"balance": "1"},
+ "0000000000000000000000000000000000000004": {"balance": "1"},
+ "dbdbdb2cbd23b783741e8d7fcf51e459b497e4a6": {"balance": "1606938044258990275541962092341162602522202993782792835301376"},
+ "e4157b34ea9615cfbde6b4fda419828124b70c78": {"balance": "1606938044258990275541962092341162602522202993782792835301376"},
+ "b9c015918bdaba24b4ff057a92a3873d6eb201be": {"balance": "1606938044258990275541962092341162602522202993782792835301376"},
+ "6c386a4b26f73c802f34673f7248bb118f97424a": {"balance": "1606938044258990275541962092341162602522202993782792835301376"},
+ "cd2a3d9f938e13cd947ec05abc7fe734df8dd826": {"balance": "1606938044258990275541962092341162602522202993782792835301376"},
+ "2ef47100e0787b915105fd5e3f4ff6752079d5cb": {"balance": "1606938044258990275541962092341162602522202993782792835301376"},
+ "e6716f9544a56c530d868e4bfbacb172315bdead": {"balance": "1606938044258990275541962092341162602522202993782792835301376"},
+ "1a26338f0d905e295fccb71fa9ea849ffa12aaf4": {"balance": "1606938044258990275541962092341162602522202993782792835301376"}
+}`)
diff --git a/core/helper_test.go b/core/helper_test.go
new file mode 100644
index 000000000..1e0ed178b
--- /dev/null
+++ b/core/helper_test.go
@@ -0,0 +1,83 @@
+package core
+
+import (
+ "container/list"
+ "fmt"
+
+ "github.com/ethereum/go-ethereum/core/types"
+ // "github.com/ethereum/go-ethereum/crypto"
+ "github.com/ethereum/go-ethereum/ethdb"
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/event"
+)
+
+// Implement our EthTest Manager
+type TestManager struct {
+ // stateManager *StateManager
+ eventMux *event.TypeMux
+
+ db common.Database
+ txPool *TxPool
+ blockChain *ChainManager
+ Blocks []*types.Block
+}
+
+func (s *TestManager) IsListening() bool {
+ return false
+}
+
+func (s *TestManager) IsMining() bool {
+ return false
+}
+
+func (s *TestManager) PeerCount() int {
+ return 0
+}
+
+func (s *TestManager) Peers() *list.List {
+ return list.New()
+}
+
+func (s *TestManager) ChainManager() *ChainManager {
+ return s.blockChain
+}
+
+func (tm *TestManager) TxPool() *TxPool {
+ return tm.txPool
+}
+
+// func (tm *TestManager) StateManager() *StateManager {
+// return tm.stateManager
+// }
+
+func (tm *TestManager) EventMux() *event.TypeMux {
+ return tm.eventMux
+}
+
+// func (tm *TestManager) KeyManager() *crypto.KeyManager {
+// return nil
+// }
+
+func (tm *TestManager) Db() common.Database {
+ return tm.db
+}
+
+func NewTestManager() *TestManager {
+ db, err := ethdb.NewMemDatabase()
+ if err != nil {
+ fmt.Println("Could not create mem-db, failing")
+ return nil
+ }
+
+ testManager := &TestManager{}
+ testManager.eventMux = new(event.TypeMux)
+ testManager.db = db
+ // testManager.txPool = NewTxPool(testManager)
+ // testManager.blockChain = NewChainManager(testManager)
+ // testManager.stateManager = NewStateManager(testManager)
+
+ // Start the tx pool
+ testManager.txPool.Start()
+
+ return testManager
+}
diff --git a/core/manager.go b/core/manager.go
new file mode 100644
index 000000000..9b5407a9e
--- /dev/null
+++ b/core/manager.go
@@ -0,0 +1,19 @@
+package core
+
+import (
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/event"
+ "github.com/ethereum/go-ethereum/p2p"
+)
+
+type Backend interface {
+ BlockProcessor() *BlockProcessor
+ ChainManager() *ChainManager
+ TxPool() *TxPool
+ PeerCount() int
+ IsListening() bool
+ Peers() []*p2p.Peer
+ BlockDb() common.Database
+ StateDb() common.Database
+ EventMux() *event.TypeMux
+}
diff --git a/core/state/dump.go b/core/state/dump.go
new file mode 100644
index 000000000..70ea21691
--- /dev/null
+++ b/core/state/dump.go
@@ -0,0 +1,62 @@
+package state
+
+import (
+ "encoding/json"
+ "fmt"
+
+ "github.com/ethereum/go-ethereum/common"
+)
+
+type Account struct {
+ Balance string `json:"balance"`
+ Nonce uint64 `json:"nonce"`
+ Root string `json:"root"`
+ CodeHash string `json:"codeHash"`
+ Storage map[string]string `json:"storage"`
+}
+
+type World struct {
+ Root string `json:"root"`
+ Accounts map[string]Account `json:"accounts"`
+}
+
+func (self *StateDB) RawDump() World {
+ world := World{
+ Root: common.Bytes2Hex(self.trie.Root()),
+ Accounts: make(map[string]Account),
+ }
+
+ it := self.trie.Iterator()
+ for it.Next() {
+ addr := self.trie.GetKey(it.Key)
+ stateObject := NewStateObjectFromBytes(common.BytesToAddress(addr), it.Value, self.db)
+
+ account := Account{Balance: stateObject.balance.String(), Nonce: stateObject.nonce, Root: common.Bytes2Hex(stateObject.Root()), CodeHash: common.Bytes2Hex(stateObject.codeHash)}
+ account.Storage = make(map[string]string)
+
+ storageIt := stateObject.State.trie.Iterator()
+ for storageIt.Next() {
+ account.Storage[common.Bytes2Hex(self.trie.GetKey(storageIt.Key))] = common.Bytes2Hex(storageIt.Value)
+ }
+ world.Accounts[common.Bytes2Hex(addr)] = account
+ }
+ return world
+}
+
+func (self *StateDB) Dump() []byte {
+ json, err := json.MarshalIndent(self.RawDump(), "", " ")
+ if err != nil {
+ fmt.Println("dump err", err)
+ }
+
+ return json
+}
+
+// Debug stuff
+func (self *StateObject) CreateOutputForDiff() {
+ fmt.Printf("%x %x %x %x\n", self.Address(), self.State.Root(), self.balance.Bytes(), self.nonce)
+ it := self.State.trie.Iterator()
+ for it.Next() {
+ fmt.Printf("%x %x\n", it.Key, it.Value)
+ }
+}
diff --git a/core/state/errors.go b/core/state/errors.go
new file mode 100644
index 000000000..5a847d38b
--- /dev/null
+++ b/core/state/errors.go
@@ -0,0 +1,23 @@
+package state
+
+import (
+ "fmt"
+ "math/big"
+)
+
+type GasLimitErr struct {
+ Message string
+ Is, Max *big.Int
+}
+
+func IsGasLimitErr(err error) bool {
+ _, ok := err.(*GasLimitErr)
+
+ return ok
+}
+func (err *GasLimitErr) Error() string {
+ return err.Message
+}
+func GasLimitError(is, max *big.Int) *GasLimitErr {
+ return &GasLimitErr{Message: fmt.Sprintf("GasLimit error. Max %s, transaction would take it to %s", max, is), Is: is, Max: max}
+}
diff --git a/core/state/log.go b/core/state/log.go
new file mode 100644
index 000000000..f8aa4c08c
--- /dev/null
+++ b/core/state/log.go
@@ -0,0 +1,99 @@
+package state
+
+import (
+ "fmt"
+ "io"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/rlp"
+)
+
+type Log interface {
+ Address() common.Address
+ Topics() []common.Hash
+ Data() []byte
+
+ Number() uint64
+}
+
+type StateLog struct {
+ address common.Address
+ topics []common.Hash
+ data []byte
+ number uint64
+}
+
+func NewLog(address common.Address, topics []common.Hash, data []byte, number uint64) *StateLog {
+ return &StateLog{address, topics, data, number}
+}
+
+func (self *StateLog) Address() common.Address {
+ return self.address
+}
+
+func (self *StateLog) Topics() []common.Hash {
+ return self.topics
+}
+
+func (self *StateLog) Data() []byte {
+ return self.data
+}
+
+func (self *StateLog) Number() uint64 {
+ return self.number
+}
+
+/*
+func NewLogFromValue(decoder *common.Value) *StateLog {
+ var extlog struct {
+
+ }
+
+ log := &StateLog{
+ address: decoder.Get(0).Bytes(),
+ data: decoder.Get(2).Bytes(),
+ }
+
+ it := decoder.Get(1).NewIterator()
+ for it.Next() {
+ log.topics = append(log.topics, it.Value().Bytes())
+ }
+
+ return log
+}
+*/
+
+func (self *StateLog) EncodeRLP(w io.Writer) error {
+ return rlp.Encode(w, []interface{}{self.address, self.topics, self.data})
+}
+
+/*
+func (self *StateLog) RlpData() interface{} {
+ return []interface{}{self.address, common.ByteSliceToInterface(self.topics), self.data}
+}
+*/
+
+func (self *StateLog) String() string {
+ return fmt.Sprintf(`log: %x %x %x`, self.address, self.topics, self.data)
+}
+
+type Logs []Log
+
+/*
+func (self Logs) RlpData() interface{} {
+ data := make([]interface{}, len(self))
+ for i, log := range self {
+ data[i] = log.RlpData()
+ }
+
+ return data
+}
+*/
+
+func (self Logs) String() (ret string) {
+ for _, log := range self {
+ ret += fmt.Sprintf("%v", log)
+ }
+
+ return "[" + ret + "]"
+}
diff --git a/core/state/main_test.go b/core/state/main_test.go
new file mode 100644
index 000000000..f3d3f7e23
--- /dev/null
+++ b/core/state/main_test.go
@@ -0,0 +1,9 @@
+package state
+
+import (
+ "testing"
+
+ checker "gopkg.in/check.v1"
+)
+
+func Test(t *testing.T) { checker.TestingT(t) }
diff --git a/core/state/managed_state.go b/core/state/managed_state.go
new file mode 100644
index 000000000..0fcc1be67
--- /dev/null
+++ b/core/state/managed_state.go
@@ -0,0 +1,89 @@
+package state
+
+import (
+ "sync"
+
+ "github.com/ethereum/go-ethereum/common"
+)
+
+type account struct {
+ stateObject *StateObject
+ nstart uint64
+ nonces []bool
+}
+
+type ManagedState struct {
+ *StateDB
+
+ mu sync.RWMutex
+
+ accounts map[string]*account
+}
+
+func ManageState(statedb *StateDB) *ManagedState {
+ return &ManagedState{
+ StateDB: statedb,
+ accounts: make(map[string]*account),
+ }
+}
+
+func (ms *ManagedState) SetState(statedb *StateDB) {
+ ms.mu.Lock()
+ defer ms.mu.Unlock()
+ ms.StateDB = statedb
+}
+
+func (ms *ManagedState) RemoveNonce(addr common.Address, n uint64) {
+ if ms.hasAccount(addr) {
+ ms.mu.Lock()
+ defer ms.mu.Unlock()
+
+ account := ms.getAccount(addr)
+ if n-account.nstart <= uint64(len(account.nonces)) {
+ reslice := make([]bool, n-account.nstart)
+ copy(reslice, account.nonces[:n-account.nstart])
+ account.nonces = reslice
+ }
+ }
+}
+
+func (ms *ManagedState) NewNonce(addr common.Address) uint64 {
+ ms.mu.RLock()
+ defer ms.mu.RUnlock()
+
+ account := ms.getAccount(addr)
+ for i, nonce := range account.nonces {
+ if !nonce {
+ return account.nstart + uint64(i)
+ }
+ }
+ account.nonces = append(account.nonces, true)
+ return uint64(len(account.nonces)) + account.nstart
+}
+
+func (ms *ManagedState) hasAccount(addr common.Address) bool {
+ _, ok := ms.accounts[addr.Str()]
+ return ok
+}
+
+func (ms *ManagedState) getAccount(addr common.Address) *account {
+ straddr := addr.Str()
+ if account, ok := ms.accounts[straddr]; !ok {
+ so := ms.GetOrNewStateObject(addr)
+ ms.accounts[straddr] = newAccount(so)
+ } else {
+ // Always make sure the state account nonce isn't actually higher
+ // than the tracked one.
+ so := ms.StateDB.GetStateObject(addr)
+ if so != nil && uint64(len(account.nonces))+account.nstart < so.nonce {
+ ms.accounts[straddr] = newAccount(so)
+ }
+
+ }
+
+ return ms.accounts[straddr]
+}
+
+func newAccount(so *StateObject) *account {
+ return &account{so, so.nonce - 1, nil}
+}
diff --git a/core/state/managed_state_test.go b/core/state/managed_state_test.go
new file mode 100644
index 000000000..b61f59e6d
--- /dev/null
+++ b/core/state/managed_state_test.go
@@ -0,0 +1,89 @@
+package state
+
+import (
+ "testing"
+
+ "github.com/ethereum/go-ethereum/common"
+)
+
+var addr = common.BytesToAddress([]byte("test"))
+
+func create() (*ManagedState, *account) {
+ ms := ManageState(&StateDB{stateObjects: make(map[string]*StateObject)})
+ so := &StateObject{address: addr, nonce: 100}
+ ms.StateDB.stateObjects[addr.Str()] = so
+ ms.accounts[addr.Str()] = newAccount(so)
+
+ return ms, ms.accounts[addr.Str()]
+}
+
+func TestNewNonce(t *testing.T) {
+ ms, _ := create()
+
+ nonce := ms.NewNonce(addr)
+ if nonce != 100 {
+ t.Error("expected nonce 100. got", nonce)
+ }
+
+ nonce = ms.NewNonce(addr)
+ if nonce != 101 {
+ t.Error("expected nonce 101. got", nonce)
+ }
+}
+
+func TestRemove(t *testing.T) {
+ ms, account := create()
+
+ nn := make([]bool, 10)
+ for i, _ := range nn {
+ nn[i] = true
+ }
+ account.nonces = append(account.nonces, nn...)
+
+ i := uint64(5)
+ ms.RemoveNonce(addr, account.nstart+i)
+ if len(account.nonces) != 5 {
+ t.Error("expected", i, "'th index to be false")
+ }
+}
+
+func TestReuse(t *testing.T) {
+ ms, account := create()
+
+ nn := make([]bool, 10)
+ for i, _ := range nn {
+ nn[i] = true
+ }
+ account.nonces = append(account.nonces, nn...)
+
+ i := uint64(5)
+ ms.RemoveNonce(addr, account.nstart+i)
+ nonce := ms.NewNonce(addr)
+ if nonce != 105 {
+ t.Error("expected nonce to be 105. got", nonce)
+ }
+}
+
+func TestRemoteNonceChange(t *testing.T) {
+ ms, account := create()
+ nn := make([]bool, 10)
+ for i, _ := range nn {
+ nn[i] = true
+ }
+ account.nonces = append(account.nonces, nn...)
+ nonce := ms.NewNonce(addr)
+
+ ms.StateDB.stateObjects[addr.Str()].nonce = 200
+ nonce = ms.NewNonce(addr)
+ if nonce != 200 {
+ t.Error("expected nonce after remote update to be", 201, "got", nonce)
+ }
+ ms.NewNonce(addr)
+ ms.NewNonce(addr)
+ ms.NewNonce(addr)
+ ms.StateDB.stateObjects[addr.Str()].nonce = 200
+ nonce = ms.NewNonce(addr)
+ if nonce != 204 {
+ t.Error("expected nonce after remote update to be", 201, "got", nonce)
+ }
+}
diff --git a/core/state/state_object.go b/core/state/state_object.go
new file mode 100644
index 000000000..a7c20722c
--- /dev/null
+++ b/core/state/state_object.go
@@ -0,0 +1,357 @@
+package state
+
+import (
+ "bytes"
+ "fmt"
+ "math/big"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/crypto"
+ "github.com/ethereum/go-ethereum/rlp"
+ "github.com/ethereum/go-ethereum/trie"
+)
+
+type Code []byte
+
+func (self Code) String() string {
+ return string(self) //strings.Join(Disassemble(self), " ")
+}
+
+type Storage map[string]*common.Value
+
+func (self Storage) String() (str string) {
+ for key, value := range self {
+ str += fmt.Sprintf("%X : %X\n", key, value.Bytes())
+ }
+
+ return
+}
+
+func (self Storage) Copy() Storage {
+ cpy := make(Storage)
+ for key, value := range self {
+ // XXX Do we need a 'value' copy or is this sufficient?
+ cpy[key] = value
+ }
+
+ return cpy
+}
+
+type StateObject struct {
+ // State database for storing state changes
+ db common.Database
+ // The state object
+ State *StateDB
+
+ // Address belonging to this account
+ address common.Address
+ // The balance of the account
+ balance *big.Int
+ // The nonce of the account
+ nonce uint64
+ // The code hash if code is present (i.e. a contract)
+ codeHash []byte
+ // The code for this account
+ code Code
+ // Temporarily initialisation code
+ initCode Code
+ // Cached storage (flushed when updated)
+ storage Storage
+ // Temporary prepaid gas, reward after transition
+ prepaid *big.Int
+
+ // Total gas pool is the total amount of gas currently
+ // left if this object is the coinbase. Gas is directly
+ // purchased of the coinbase.
+ gasPool *big.Int
+
+ // Mark for deletion
+ // When an object is marked for deletion it will be delete from the trie
+ // during the "update" phase of the state transition
+ remove bool
+ dirty bool
+}
+
+func (self *StateObject) Reset() {
+ self.storage = make(Storage)
+ self.State.Reset()
+}
+
+func NewStateObject(address common.Address, db common.Database) *StateObject {
+ // This to ensure that it has 20 bytes (and not 0 bytes), thus left or right pad doesn't matter.
+ //address := common.ToAddress(addr)
+
+ object := &StateObject{db: db, address: address, balance: new(big.Int), gasPool: new(big.Int), dirty: true}
+ object.State = New(common.Hash{}, db) //New(trie.New(common.Config.Db, ""))
+ object.storage = make(Storage)
+ object.gasPool = new(big.Int)
+ object.prepaid = new(big.Int)
+
+ return object
+}
+
+func NewStateObjectFromBytes(address common.Address, data []byte, db common.Database) *StateObject {
+ // TODO clean me up
+ var extobject struct {
+ Nonce uint64
+ Balance *big.Int
+ Root common.Hash
+ CodeHash []byte
+ }
+ err := rlp.Decode(bytes.NewReader(data), &extobject)
+ if err != nil {
+ fmt.Println(err)
+ return nil
+ }
+
+ object := &StateObject{address: address, db: db}
+ //object.RlpDecode(data)
+ object.nonce = extobject.Nonce
+ object.balance = extobject.Balance
+ object.codeHash = extobject.CodeHash
+ object.State = New(extobject.Root, db)
+ object.storage = make(map[string]*common.Value)
+ object.gasPool = new(big.Int)
+ object.prepaid = new(big.Int)
+ object.code, _ = db.Get(extobject.CodeHash)
+
+ return object
+}
+
+func (self *StateObject) MarkForDeletion() {
+ self.remove = true
+ self.dirty = true
+ statelogger.Debugf("%x: #%d %v X\n", self.Address(), self.nonce, self.balance)
+}
+
+func (c *StateObject) getAddr(addr common.Hash) *common.Value {
+ return common.NewValueFromBytes([]byte(c.State.trie.Get(addr[:])))
+}
+
+func (c *StateObject) setAddr(addr []byte, value interface{}) {
+ c.State.trie.Update(addr, common.Encode(value))
+}
+
+func (self *StateObject) GetStorage(key *big.Int) *common.Value {
+ return self.GetState(common.BytesToHash(key.Bytes()))
+}
+func (self *StateObject) SetStorage(key *big.Int, value *common.Value) {
+ self.SetState(common.BytesToHash(key.Bytes()), value)
+}
+
+func (self *StateObject) Storage() Storage {
+ return self.storage
+}
+
+func (self *StateObject) GetState(key common.Hash) *common.Value {
+ strkey := key.Str()
+ value := self.storage[strkey]
+ if value == nil {
+ value = self.getAddr(key)
+
+ if !value.IsNil() {
+ self.storage[strkey] = value
+ }
+ }
+
+ return value
+}
+
+func (self *StateObject) SetState(k common.Hash, value *common.Value) {
+ self.storage[k.Str()] = value.Copy()
+ self.dirty = true
+}
+
+func (self *StateObject) Sync() {
+ for key, value := range self.storage {
+ if value.Len() == 0 {
+ self.State.trie.Delete([]byte(key))
+ continue
+ }
+
+ self.setAddr([]byte(key), value)
+ }
+ self.storage = make(Storage)
+}
+
+func (c *StateObject) GetInstr(pc *big.Int) *common.Value {
+ if int64(len(c.code)-1) < pc.Int64() {
+ return common.NewValue(0)
+ }
+
+ return common.NewValueFromBytes([]byte{c.code[pc.Int64()]})
+}
+
+func (c *StateObject) AddBalance(amount *big.Int) {
+ c.SetBalance(new(big.Int).Add(c.balance, amount))
+
+ statelogger.Debugf("%x: #%d %v (+ %v)\n", c.Address(), c.nonce, c.balance, amount)
+}
+
+func (c *StateObject) SubBalance(amount *big.Int) {
+ c.SetBalance(new(big.Int).Sub(c.balance, amount))
+
+ statelogger.Debugf("%x: #%d %v (- %v)\n", c.Address(), c.nonce, c.balance, amount)
+}
+
+func (c *StateObject) SetBalance(amount *big.Int) {
+ c.balance = amount
+ c.dirty = true
+}
+
+func (c *StateObject) St() Storage {
+ return c.storage
+}
+
+//
+// Gas setters and getters
+//
+
+// Return the gas back to the origin. Used by the Virtual machine or Closures
+func (c *StateObject) ReturnGas(gas, price *big.Int) {}
+func (c *StateObject) ConvertGas(gas, price *big.Int) error {
+ total := new(big.Int).Mul(gas, price)
+ if total.Cmp(c.balance) > 0 {
+ return fmt.Errorf("insufficient amount: %v, %v", c.balance, total)
+ }
+
+ c.SubBalance(total)
+
+ c.dirty = true
+
+ return nil
+}
+
+func (self *StateObject) SetGasPool(gasLimit *big.Int) {
+ self.gasPool = new(big.Int).Set(gasLimit)
+
+ statelogger.Debugf("%x: gas (+ %v)", self.Address(), self.gasPool)
+}
+
+func (self *StateObject) BuyGas(gas, price *big.Int) error {
+ if self.gasPool.Cmp(gas) < 0 {
+ return GasLimitError(self.gasPool, gas)
+ }
+
+ self.gasPool.Sub(self.gasPool, gas)
+
+ rGas := new(big.Int).Set(gas)
+ rGas.Mul(rGas, price)
+
+ self.dirty = true
+
+ return nil
+}
+
+func (self *StateObject) RefundGas(gas, price *big.Int) {
+ self.gasPool.Add(self.gasPool, gas)
+}
+
+func (self *StateObject) Copy() *StateObject {
+ stateObject := NewStateObject(self.Address(), self.db)
+ stateObject.balance.Set(self.balance)
+ stateObject.codeHash = common.CopyBytes(self.codeHash)
+ stateObject.nonce = self.nonce
+ if self.State != nil {
+ stateObject.State = self.State.Copy()
+ }
+ stateObject.code = common.CopyBytes(self.code)
+ stateObject.initCode = common.CopyBytes(self.initCode)
+ stateObject.storage = self.storage.Copy()
+ stateObject.gasPool.Set(self.gasPool)
+ stateObject.remove = self.remove
+ stateObject.dirty = self.dirty
+
+ return stateObject
+}
+
+func (self *StateObject) Set(stateObject *StateObject) {
+ *self = *stateObject
+}
+
+//
+// Attribute accessors
+//
+
+func (self *StateObject) Balance() *big.Int {
+ return self.balance
+}
+
+func (c *StateObject) N() *big.Int {
+ return big.NewInt(int64(c.nonce))
+}
+
+// Returns the address of the contract/account
+func (c *StateObject) Address() common.Address {
+ return c.address
+}
+
+// Returns the initialization Code
+func (c *StateObject) Init() Code {
+ return c.initCode
+}
+
+func (self *StateObject) Trie() *trie.SecureTrie {
+ return self.State.trie
+}
+
+func (self *StateObject) Root() []byte {
+ return self.Trie().Root()
+}
+
+func (self *StateObject) Code() []byte {
+ return self.code
+}
+
+func (self *StateObject) SetCode(code []byte) {
+ self.code = code
+ self.dirty = true
+}
+
+func (self *StateObject) SetInitCode(code []byte) {
+ self.initCode = code
+ self.dirty = true
+}
+
+func (self *StateObject) SetNonce(nonce uint64) {
+ self.nonce = nonce
+ self.dirty = true
+}
+
+func (self *StateObject) Nonce() uint64 {
+ return self.nonce
+}
+
+//
+// Encoding
+//
+
+// State object encoding methods
+func (c *StateObject) RlpEncode() []byte {
+ return common.Encode([]interface{}{c.nonce, c.balance, c.Root(), c.CodeHash()})
+}
+
+func (c *StateObject) CodeHash() common.Bytes {
+ return crypto.Sha3(c.code)
+}
+
+func (c *StateObject) RlpDecode(data []byte) {
+ decoder := common.NewValueFromBytes(data)
+ c.nonce = decoder.Get(0).Uint()
+ c.balance = decoder.Get(1).BigInt()
+ c.State = New(common.BytesToHash(decoder.Get(2).Bytes()), c.db) //New(trie.New(common.Config.Db, decoder.Get(2).Interface()))
+ c.storage = make(map[string]*common.Value)
+ c.gasPool = new(big.Int)
+
+ c.codeHash = decoder.Get(3).Bytes()
+
+ c.code, _ = c.db.Get(c.codeHash)
+}
+
+// Storage change object. Used by the manifest for notifying changes to
+// the sub channels.
+type StorageState struct {
+ StateAddress []byte
+ Address []byte
+ Value *big.Int
+}
diff --git a/core/state/state_test.go b/core/state/state_test.go
new file mode 100644
index 000000000..09a65de54
--- /dev/null
+++ b/core/state/state_test.go
@@ -0,0 +1,106 @@
+package state
+
+import (
+ "math/big"
+ "testing"
+
+ checker "gopkg.in/check.v1"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/ethdb"
+)
+
+type StateSuite struct {
+ state *StateDB
+}
+
+var _ = checker.Suite(&StateSuite{})
+
+var toAddr = common.BytesToAddress
+
+func (s *StateSuite) TestDump(c *checker.C) {
+ return
+ // generate a few entries
+ obj1 := s.state.GetOrNewStateObject(toAddr([]byte{0x01}))
+ obj1.AddBalance(big.NewInt(22))
+ obj2 := s.state.GetOrNewStateObject(toAddr([]byte{0x01, 0x02}))
+ obj2.SetCode([]byte{3, 3, 3, 3, 3, 3, 3})
+ obj3 := s.state.GetOrNewStateObject(toAddr([]byte{0x02}))
+ obj3.SetBalance(big.NewInt(44))
+
+ // write some of them to the trie
+ s.state.UpdateStateObject(obj1)
+ s.state.UpdateStateObject(obj2)
+
+ // check that dump contains the state objects that are in trie
+ got := string(s.state.Dump())
+ want := `{
+ "root": "6e277ae8357d013e50f74eedb66a991f6922f93ae03714de58b3d0c5e9eee53f",
+ "accounts": {
+ "1468288056310c82aa4c01a7e12a10f8111a0560e72b700555479031b86c357d": {
+ "balance": "22",
+ "nonce": 0,
+ "root": "56e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421",
+ "codeHash": "c5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470",
+ "storage": {}
+ },
+ "a17eacbc25cda025e81db9c5c62868822c73ce097cee2a63e33a2e41268358a1": {
+ "balance": "0",
+ "nonce": 0,
+ "root": "56e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421",
+ "codeHash": "87874902497a5bb968da31a2998d8f22e949d1ef6214bcdedd8bae24cca4b9e3",
+ "storage": {}
+ }
+ }
+}`
+ if got != want {
+ c.Errorf("dump mismatch:\ngot: %s\nwant: %s\n", got, want)
+ }
+}
+
+func (s *StateSuite) SetUpTest(c *checker.C) {
+ db, _ := ethdb.NewMemDatabase()
+ s.state = New(common.Hash{}, db)
+}
+
+func TestNull(t *testing.T) {
+ db, _ := ethdb.NewMemDatabase()
+ state := New(common.Hash{}, db)
+
+ address := common.HexToAddress("0x823140710bf13990e4500136726d8b55")
+ state.CreateAccount(address)
+ //value := common.FromHex("0x823140710bf13990e4500136726d8b55")
+ value := make([]byte, 16)
+ state.SetState(address, common.Hash{}, value)
+ state.Update()
+ state.Sync()
+ value = state.GetState(address, common.Hash{})
+}
+
+func (s *StateSuite) TestSnapshot(c *checker.C) {
+ stateobjaddr := toAddr([]byte("aa"))
+ storageaddr := common.Big("0")
+ data1 := common.NewValue(42)
+ data2 := common.NewValue(43)
+
+ // get state object
+ stateObject := s.state.GetOrNewStateObject(stateobjaddr)
+ // set inital state object value
+ stateObject.SetStorage(storageaddr, data1)
+ // get snapshot of current state
+ snapshot := s.state.Copy()
+
+ // get state object. is this strictly necessary?
+ stateObject = s.state.GetStateObject(stateobjaddr)
+ // set new state object value
+ stateObject.SetStorage(storageaddr, data2)
+ // restore snapshot
+ s.state.Set(snapshot)
+
+ // get state object
+ stateObject = s.state.GetStateObject(stateobjaddr)
+ // get state storage value
+ res := stateObject.GetStorage(storageaddr)
+
+ c.Assert(data1, checker.DeepEquals, res)
+}
diff --git a/core/state/statedb.go b/core/state/statedb.go
new file mode 100644
index 000000000..e69bb34fe
--- /dev/null
+++ b/core/state/statedb.go
@@ -0,0 +1,341 @@
+package state
+
+import (
+ "bytes"
+ "math/big"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/logger"
+ "github.com/ethereum/go-ethereum/trie"
+)
+
+var statelogger = logger.NewLogger("STATE")
+
+// StateDBs within the ethereum protocol are used to store anything
+// within the merkle trie. StateDBs take care of caching and storing
+// nested states. It's the general query interface to retrieve:
+// * Contracts
+// * Accounts
+type StateDB struct {
+ db common.Database
+ trie *trie.SecureTrie
+
+ stateObjects map[string]*StateObject
+
+ refund map[string]*big.Int
+
+ logs Logs
+}
+
+// Create a new state from a given trie
+func New(root common.Hash, db common.Database) *StateDB {
+ trie := trie.NewSecure(root[:], db)
+ return &StateDB{db: db, trie: trie, stateObjects: make(map[string]*StateObject), refund: make(map[string]*big.Int)}
+}
+
+func (self *StateDB) PrintRoot() {
+ self.trie.Trie.PrintRoot()
+}
+
+func (self *StateDB) EmptyLogs() {
+ self.logs = nil
+}
+
+func (self *StateDB) AddLog(log Log) {
+ self.logs = append(self.logs, log)
+}
+
+func (self *StateDB) Logs() Logs {
+ return self.logs
+}
+
+func (self *StateDB) Refund(address common.Address, gas *big.Int) {
+ addr := address.Str()
+ if self.refund[addr] == nil {
+ self.refund[addr] = new(big.Int)
+ }
+ self.refund[addr].Add(self.refund[addr], gas)
+}
+
+/*
+ * GETTERS
+ */
+
+// Retrieve the balance from the given address or 0 if object not found
+func (self *StateDB) GetBalance(addr common.Address) *big.Int {
+ stateObject := self.GetStateObject(addr)
+ if stateObject != nil {
+ return stateObject.balance
+ }
+
+ return common.Big0
+}
+
+func (self *StateDB) GetNonce(addr common.Address) uint64 {
+ stateObject := self.GetStateObject(addr)
+ if stateObject != nil {
+ return stateObject.nonce
+ }
+
+ return 0
+}
+
+func (self *StateDB) GetCode(addr common.Address) []byte {
+ stateObject := self.GetStateObject(addr)
+ if stateObject != nil {
+ return stateObject.code
+ }
+
+ return nil
+}
+
+func (self *StateDB) GetState(a common.Address, b common.Hash) []byte {
+ stateObject := self.GetStateObject(a)
+ if stateObject != nil {
+ return stateObject.GetState(b).Bytes()
+ }
+
+ return nil
+}
+
+func (self *StateDB) IsDeleted(addr common.Address) bool {
+ stateObject := self.GetStateObject(addr)
+ if stateObject != nil {
+ return stateObject.remove
+ }
+ return false
+}
+
+/*
+ * SETTERS
+ */
+
+func (self *StateDB) AddBalance(addr common.Address, amount *big.Int) {
+ stateObject := self.GetOrNewStateObject(addr)
+ if stateObject != nil {
+ stateObject.AddBalance(amount)
+ }
+}
+
+func (self *StateDB) SetNonce(addr common.Address, nonce uint64) {
+ stateObject := self.GetOrNewStateObject(addr)
+ if stateObject != nil {
+ stateObject.SetNonce(nonce)
+ }
+}
+
+func (self *StateDB) SetCode(addr common.Address, code []byte) {
+ stateObject := self.GetOrNewStateObject(addr)
+ if stateObject != nil {
+ stateObject.SetCode(code)
+ }
+}
+
+func (self *StateDB) SetState(addr common.Address, key common.Hash, value interface{}) {
+ stateObject := self.GetOrNewStateObject(addr)
+ if stateObject != nil {
+ stateObject.SetState(key, common.NewValue(value))
+ }
+}
+
+func (self *StateDB) Delete(addr common.Address) bool {
+ stateObject := self.GetStateObject(addr)
+ if stateObject != nil {
+ stateObject.MarkForDeletion()
+ stateObject.balance = new(big.Int)
+
+ return true
+ }
+
+ return false
+}
+
+//
+// Setting, updating & deleting state object methods
+//
+
+// Update the given state object and apply it to state trie
+func (self *StateDB) UpdateStateObject(stateObject *StateObject) {
+ //addr := stateObject.Address()
+
+ if len(stateObject.CodeHash()) > 0 {
+ self.db.Put(stateObject.CodeHash(), stateObject.code)
+ }
+
+ addr := stateObject.Address()
+ self.trie.Update(addr[:], stateObject.RlpEncode())
+}
+
+// Delete the given state object and delete it from the state trie
+func (self *StateDB) DeleteStateObject(stateObject *StateObject) {
+ addr := stateObject.Address()
+ self.trie.Delete(addr[:])
+
+ delete(self.stateObjects, addr.Str())
+}
+
+// Retrieve a state object given my the address. Nil if not found
+func (self *StateDB) GetStateObject(addr common.Address) *StateObject {
+ //addr = common.Address(addr)
+
+ stateObject := self.stateObjects[addr.Str()]
+ if stateObject != nil {
+ return stateObject
+ }
+
+ data := self.trie.Get(addr[:])
+ if len(data) == 0 {
+ return nil
+ }
+
+ stateObject = NewStateObjectFromBytes(addr, []byte(data), self.db)
+ self.SetStateObject(stateObject)
+
+ return stateObject
+}
+
+func (self *StateDB) SetStateObject(object *StateObject) {
+ self.stateObjects[object.Address().Str()] = object
+}
+
+// Retrieve a state object or create a new state object if nil
+func (self *StateDB) GetOrNewStateObject(addr common.Address) *StateObject {
+ stateObject := self.GetStateObject(addr)
+ if stateObject == nil {
+ stateObject = self.CreateAccount(addr)
+ }
+
+ return stateObject
+}
+
+// NewStateObject create a state object whether it exist in the trie or not
+func (self *StateDB) newStateObject(addr common.Address) *StateObject {
+ statelogger.Debugf("(+) %x\n", addr)
+
+ stateObject := NewStateObject(addr, self.db)
+ self.stateObjects[addr.Str()] = stateObject
+
+ return stateObject
+}
+
+// Creates creates a new state object and takes ownership. This is different from "NewStateObject"
+func (self *StateDB) CreateAccount(addr common.Address) *StateObject {
+ // Get previous (if any)
+ so := self.GetStateObject(addr)
+ // Create a new one
+ newSo := self.newStateObject(addr)
+
+ // If it existed set the balance to the new account
+ if so != nil {
+ newSo.balance = so.balance
+ }
+
+ return newSo
+}
+
+//
+// Setting, copying of the state methods
+//
+
+func (s *StateDB) Cmp(other *StateDB) bool {
+ return bytes.Equal(s.trie.Root(), other.trie.Root())
+}
+
+func (self *StateDB) Copy() *StateDB {
+ state := New(common.Hash{}, self.db)
+ state.trie = self.trie.Copy()
+ for k, stateObject := range self.stateObjects {
+ state.stateObjects[k] = stateObject.Copy()
+ }
+
+ for addr, refund := range self.refund {
+ state.refund[addr] = new(big.Int).Set(refund)
+ }
+
+ logs := make(Logs, len(self.logs))
+ copy(logs, self.logs)
+ state.logs = logs
+
+ return state
+}
+
+func (self *StateDB) Set(state *StateDB) {
+ self.trie = state.trie
+ self.stateObjects = state.stateObjects
+
+ self.refund = state.refund
+ self.logs = state.logs
+}
+
+func (s *StateDB) Root() common.Hash {
+ return common.BytesToHash(s.trie.Root())
+}
+
+func (s *StateDB) Trie() *trie.SecureTrie {
+ return s.trie
+}
+
+// Resets the trie and all siblings
+func (s *StateDB) Reset() {
+ s.trie.Reset()
+
+ // Reset all nested states
+ for _, stateObject := range s.stateObjects {
+ if stateObject.State == nil {
+ continue
+ }
+
+ stateObject.Reset()
+ }
+
+ s.Empty()
+}
+
+// Syncs the trie and all siblings
+func (s *StateDB) Sync() {
+ // Sync all nested states
+ for _, stateObject := range s.stateObjects {
+ if stateObject.State == nil {
+ continue
+ }
+
+ stateObject.State.Sync()
+ }
+
+ s.trie.Commit()
+
+ s.Empty()
+}
+
+func (self *StateDB) Empty() {
+ self.stateObjects = make(map[string]*StateObject)
+ self.refund = make(map[string]*big.Int)
+}
+
+func (self *StateDB) Refunds() map[string]*big.Int {
+ return self.refund
+}
+
+func (self *StateDB) Update() {
+ self.refund = make(map[string]*big.Int)
+
+ for _, stateObject := range self.stateObjects {
+ if stateObject.dirty {
+ if stateObject.remove {
+ self.DeleteStateObject(stateObject)
+ } else {
+ stateObject.Sync()
+
+ self.UpdateStateObject(stateObject)
+ }
+ stateObject.dirty = false
+ }
+ }
+}
+
+// Debug stuff
+func (self *StateDB) CreateOutputForDiff() {
+ for _, stateObject := range self.stateObjects {
+ stateObject.CreateOutputForDiff()
+ }
+}
diff --git a/core/state_transition.go b/core/state_transition.go
new file mode 100644
index 000000000..1994cabf6
--- /dev/null
+++ b/core/state_transition.go
@@ -0,0 +1,258 @@
+package core
+
+import (
+ "fmt"
+ "math/big"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/core/state"
+ "github.com/ethereum/go-ethereum/core/vm"
+ "github.com/ethereum/go-ethereum/crypto"
+ "github.com/ethereum/go-ethereum/params"
+)
+
+const tryJit = false
+
+var ()
+
+/*
+ * The State transitioning model
+ *
+ * A state transition is a change made when a transaction is applied to the current world state
+ * The state transitioning model does all all the necessary work to work out a valid new state root.
+ * 1) Nonce handling
+ * 2) Pre pay / buy gas of the coinbase (miner)
+ * 3) Create a new state object if the recipient is \0*32
+ * 4) Value transfer
+ * == If contract creation ==
+ * 4a) Attempt to run transaction data
+ * 4b) If valid, use result as code for the new state object
+ * == end ==
+ * 5) Run Script section
+ * 6) Derive new state root
+ */
+type StateTransition struct {
+ coinbase common.Address
+ msg Message
+ gas, gasPrice *big.Int
+ initialGas *big.Int
+ value *big.Int
+ data []byte
+ state *state.StateDB
+
+ cb, rec, sen *state.StateObject
+
+ env vm.Environment
+}
+
+// Message represents a message sent to a contract.
+type Message interface {
+ From() (common.Address, error)
+ To() *common.Address
+
+ GasPrice() *big.Int
+ Gas() *big.Int
+ Value() *big.Int
+
+ Nonce() uint64
+ Data() []byte
+}
+
+func AddressFromMessage(msg Message) common.Address {
+ from, _ := msg.From()
+
+ return crypto.CreateAddress(from, msg.Nonce())
+}
+
+func MessageCreatesContract(msg Message) bool {
+ return msg.To() == nil
+}
+
+func MessageGasValue(msg Message) *big.Int {
+ return new(big.Int).Mul(msg.Gas(), msg.GasPrice())
+}
+
+func ApplyMessage(env vm.Environment, msg Message, coinbase *state.StateObject) ([]byte, *big.Int, error) {
+ return NewStateTransition(env, msg, coinbase).transitionState()
+}
+
+func NewStateTransition(env vm.Environment, msg Message, coinbase *state.StateObject) *StateTransition {
+ return &StateTransition{
+ coinbase: coinbase.Address(),
+ env: env,
+ msg: msg,
+ gas: new(big.Int),
+ gasPrice: new(big.Int).Set(msg.GasPrice()),
+ initialGas: new(big.Int),
+ value: msg.Value(),
+ data: msg.Data(),
+ state: env.State(),
+ cb: coinbase,
+ }
+}
+
+func (self *StateTransition) Coinbase() *state.StateObject {
+ return self.state.GetOrNewStateObject(self.coinbase)
+}
+func (self *StateTransition) From() *state.StateObject {
+ f, _ := self.msg.From()
+ return self.state.GetOrNewStateObject(f)
+}
+func (self *StateTransition) To() *state.StateObject {
+ if self.msg == nil {
+ return nil
+ }
+ to := self.msg.To()
+ if to == nil {
+ return nil // contract creation
+ }
+ return self.state.GetOrNewStateObject(*to)
+}
+
+func (self *StateTransition) UseGas(amount *big.Int) error {
+ if self.gas.Cmp(amount) < 0 {
+ return OutOfGasError()
+ }
+ self.gas.Sub(self.gas, amount)
+
+ return nil
+}
+
+func (self *StateTransition) AddGas(amount *big.Int) {
+ self.gas.Add(self.gas, amount)
+}
+
+func (self *StateTransition) BuyGas() error {
+ var err error
+
+ sender := self.From()
+ if sender.Balance().Cmp(MessageGasValue(self.msg)) < 0 {
+ return fmt.Errorf("insufficient ETH for gas (%x). Req %v, has %v", sender.Address().Bytes()[:4], MessageGasValue(self.msg), sender.Balance())
+ }
+
+ coinbase := self.Coinbase()
+ err = coinbase.BuyGas(self.msg.Gas(), self.msg.GasPrice())
+ if err != nil {
+ return err
+ }
+
+ self.AddGas(self.msg.Gas())
+ self.initialGas.Set(self.msg.Gas())
+ sender.SubBalance(MessageGasValue(self.msg))
+
+ return nil
+}
+
+func (self *StateTransition) preCheck() (err error) {
+ var (
+ msg = self.msg
+ sender = self.From()
+ )
+
+ // Make sure this transaction's nonce is correct
+ if sender.Nonce() != msg.Nonce() {
+ return NonceError(msg.Nonce(), sender.Nonce())
+ }
+
+ // Pre-pay gas / Buy gas of the coinbase account
+ if err = self.BuyGas(); err != nil {
+ if state.IsGasLimitErr(err) {
+ return err
+ }
+ return InvalidTxError(err)
+ }
+
+ return nil
+}
+
+func (self *StateTransition) transitionState() (ret []byte, usedGas *big.Int, err error) {
+ // statelogger.Debugf("(~) %x\n", self.msg.Hash())
+
+ // XXX Transactions after this point are considered valid.
+ if err = self.preCheck(); err != nil {
+ return
+ }
+
+ var (
+ msg = self.msg
+ sender = self.From()
+ )
+
+ // Transaction gas
+ if err = self.UseGas(params.TxGas); err != nil {
+ return nil, nil, InvalidTxError(err)
+ }
+
+ // Pay data gas
+ dgas := new(big.Int)
+ for _, byt := range self.data {
+ if byt != 0 {
+ dgas.Add(dgas, params.TxDataNonZeroGas)
+ } else {
+ dgas.Add(dgas, params.TxDataZeroGas)
+ }
+ }
+
+ if err = self.UseGas(dgas); err != nil {
+ return nil, nil, InvalidTxError(err)
+ }
+
+ vmenv := self.env
+ var ref vm.ContextRef
+ if MessageCreatesContract(msg) {
+ ret, err, ref = vmenv.Create(sender, self.msg.Data(), self.gas, self.gasPrice, self.value)
+ if err == nil {
+ dataGas := big.NewInt(int64(len(ret)))
+ dataGas.Mul(dataGas, params.CreateDataGas)
+ if err := self.UseGas(dataGas); err == nil {
+ ref.SetCode(ret)
+ } else {
+ statelogger.Infoln("Insufficient gas for creating code. Require", dataGas, "and have", self.gas)
+ }
+ }
+ } else {
+ // Increment the nonce for the next transaction
+ self.state.SetNonce(sender.Address(), sender.Nonce()+1)
+ ret, err = vmenv.Call(self.From(), self.To().Address(), self.msg.Data(), self.gas, self.gasPrice, self.value)
+ }
+
+ if err != nil && IsValueTransferErr(err) {
+ return nil, nil, InvalidTxError(err)
+ }
+
+ self.refundGas()
+ self.state.AddBalance(self.coinbase, new(big.Int).Mul(self.gasUsed(), self.gasPrice))
+
+ return ret, self.gasUsed(), err
+}
+
+func (self *StateTransition) refundGas() {
+ coinbase, sender := self.Coinbase(), self.From()
+ // Return remaining gas
+ remaining := new(big.Int).Mul(self.gas, self.msg.GasPrice())
+ sender.AddBalance(remaining)
+
+ uhalf := new(big.Int).Div(self.gasUsed(), common.Big2)
+ for addr, ref := range self.state.Refunds() {
+ refund := common.BigMin(uhalf, ref)
+ self.gas.Add(self.gas, refund)
+ self.state.AddBalance(common.StringToAddress(addr), refund.Mul(refund, self.msg.GasPrice()))
+ }
+
+ coinbase.RefundGas(self.gas, self.msg.GasPrice())
+}
+
+func (self *StateTransition) gasUsed() *big.Int {
+ return new(big.Int).Sub(self.initialGas, self.gas)
+}
+
+// Converts an message in to a state object
+func makeContract(msg Message, state *state.StateDB) *state.StateObject {
+ faddr, _ := msg.From()
+ addr := crypto.CreateAddress(faddr, msg.Nonce())
+
+ contract := state.GetOrNewStateObject(addr)
+ contract.SetInitCode(msg.Data())
+
+ return contract
+}
diff --git a/core/transaction_pool.go b/core/transaction_pool.go
new file mode 100644
index 000000000..f2fe5c748
--- /dev/null
+++ b/core/transaction_pool.go
@@ -0,0 +1,197 @@
+package core
+
+import (
+ "errors"
+ "fmt"
+ "sync"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/core/types"
+ "github.com/ethereum/go-ethereum/event"
+ "github.com/ethereum/go-ethereum/logger"
+)
+
+var (
+ txplogger = logger.NewLogger("TXP")
+
+ ErrInvalidSender = errors.New("Invalid sender")
+)
+
+const txPoolQueueSize = 50
+
+type TxPoolHook chan *types.Transaction
+type TxMsg struct{ Tx *types.Transaction }
+
+const (
+ minGasPrice = 1000000
+)
+
+type TxProcessor interface {
+ ProcessTransaction(tx *types.Transaction)
+}
+
+// The tx pool a thread safe transaction pool handler. In order to
+// guarantee a non blocking pool we use a queue channel which can be
+// independently read without needing access to the actual pool.
+type TxPool struct {
+ mu sync.RWMutex
+ // Queueing channel for reading and writing incoming
+ // transactions to
+ queueChan chan *types.Transaction
+ // Quiting channel
+ quit chan bool
+ // The actual pool
+ //pool *list.List
+ txs map[common.Hash]*types.Transaction
+
+ SecondaryProcessor TxProcessor
+
+ subscribers []chan TxMsg
+
+ eventMux *event.TypeMux
+}
+
+func NewTxPool(eventMux *event.TypeMux) *TxPool {
+ return &TxPool{
+ txs: make(map[common.Hash]*types.Transaction),
+ queueChan: make(chan *types.Transaction, txPoolQueueSize),
+ quit: make(chan bool),
+ eventMux: eventMux,
+ }
+}
+
+func (pool *TxPool) ValidateTransaction(tx *types.Transaction) error {
+ // Validate sender
+ if _, err := tx.From(); err != nil {
+ return ErrInvalidSender
+ }
+ // Validate curve param
+ v, _, _ := tx.Curve()
+ if v > 28 || v < 27 {
+ return fmt.Errorf("tx.v != (28 || 27) => %v", v)
+ }
+ return nil
+
+ /* XXX this kind of validation needs to happen elsewhere in the gui when sending txs.
+ Other clients should do their own validation. Value transfer could throw error
+ but doesn't necessarily invalidate the tx. Gas can still be payed for and miner
+ can still be rewarded for their inclusion and processing.
+ sender := pool.stateQuery.GetAccount(senderAddr)
+ totAmount := new(big.Int).Set(tx.Value())
+ // Make sure there's enough in the sender's account. Having insufficient
+ // funds won't invalidate this transaction but simple ignores it.
+ if sender.Balance().Cmp(totAmount) < 0 {
+ return fmt.Errorf("Insufficient amount in sender's (%x) account", tx.From())
+ }
+ */
+}
+
+func (self *TxPool) addTx(tx *types.Transaction) {
+ self.txs[tx.Hash()] = tx
+}
+
+func (self *TxPool) add(tx *types.Transaction) error {
+ hash := tx.Hash()
+ if self.txs[hash] != nil {
+ return fmt.Errorf("Known transaction (%x)", hash[0:4])
+ }
+ err := self.ValidateTransaction(tx)
+ if err != nil {
+ return err
+ }
+
+ self.addTx(tx)
+
+ var toname string
+ if to := tx.To(); to != nil {
+ toname = common.Bytes2Hex(to[:4])
+ } else {
+ toname = "[NEW_CONTRACT]"
+ }
+ // we can ignore the error here because From is
+ // verified in ValidateTransaction.
+ f, _ := tx.From()
+ from := common.Bytes2Hex(f[:4])
+ txplogger.Debugf("(t) %x => %s (%v) %x\n", from, toname, tx.Value, tx.Hash())
+
+ // Notify the subscribers
+ go self.eventMux.Post(TxPreEvent{tx})
+
+ return nil
+}
+
+func (self *TxPool) Size() int {
+ return len(self.txs)
+}
+
+func (self *TxPool) Add(tx *types.Transaction) error {
+ self.mu.Lock()
+ defer self.mu.Unlock()
+ return self.add(tx)
+}
+
+func (self *TxPool) AddTransactions(txs []*types.Transaction) {
+ self.mu.Lock()
+ defer self.mu.Unlock()
+
+ for _, tx := range txs {
+ if err := self.add(tx); err != nil {
+ txplogger.Debugln(err)
+ } else {
+ h := tx.Hash()
+ txplogger.Debugf("tx %x\n", h[:4])
+ }
+ }
+}
+
+func (self *TxPool) GetTransactions() (txs types.Transactions) {
+ self.mu.RLock()
+ defer self.mu.RUnlock()
+
+ txs = make(types.Transactions, self.Size())
+ i := 0
+ for _, tx := range self.txs {
+ txs[i] = tx
+ i++
+ }
+
+ return
+}
+
+func (pool *TxPool) RemoveInvalid(query StateQuery) {
+ pool.mu.Lock()
+
+ var removedTxs types.Transactions
+ for _, tx := range pool.txs {
+ from, _ := tx.From()
+ sender := query.GetAccount(from[:])
+ err := pool.ValidateTransaction(tx)
+ if err != nil || sender.Nonce() >= tx.Nonce() {
+ removedTxs = append(removedTxs, tx)
+ }
+ }
+ pool.mu.Unlock()
+
+ pool.RemoveSet(removedTxs)
+}
+
+func (self *TxPool) RemoveSet(txs types.Transactions) {
+ self.mu.Lock()
+ defer self.mu.Unlock()
+ for _, tx := range txs {
+ delete(self.txs, tx.Hash())
+ }
+}
+
+func (pool *TxPool) Flush() {
+ pool.txs = make(map[common.Hash]*types.Transaction)
+}
+
+func (pool *TxPool) Start() {
+}
+
+func (pool *TxPool) Stop() {
+ pool.Flush()
+
+ txplogger.Infoln("Stopped")
+}
diff --git a/core/transaction_pool_test.go b/core/transaction_pool_test.go
new file mode 100644
index 000000000..a009a4c9d
--- /dev/null
+++ b/core/transaction_pool_test.go
@@ -0,0 +1,95 @@
+package core
+
+import (
+ "crypto/ecdsa"
+ "testing"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/core/types"
+ "github.com/ethereum/go-ethereum/crypto"
+ "github.com/ethereum/go-ethereum/ethdb"
+ "github.com/ethereum/go-ethereum/event"
+ "github.com/ethereum/go-ethereum/core/state"
+)
+
+// State query interface
+type stateQuery struct{ db common.Database }
+
+func SQ() stateQuery {
+ db, _ := ethdb.NewMemDatabase()
+ return stateQuery{db: db}
+}
+
+func (self stateQuery) GetAccount(addr []byte) *state.StateObject {
+ return state.NewStateObject(common.BytesToAddress(addr), self.db)
+}
+
+func transaction() *types.Transaction {
+ return types.NewTransactionMessage(common.Address{}, common.Big0, common.Big0, common.Big0, nil)
+}
+
+func setup() (*TxPool, *ecdsa.PrivateKey) {
+ var m event.TypeMux
+ key, _ := crypto.GenerateKey()
+ return NewTxPool(&m), key
+}
+
+func TestTxAdding(t *testing.T) {
+ pool, key := setup()
+ tx1 := transaction()
+ tx1.SignECDSA(key)
+ err := pool.Add(tx1)
+ if err != nil {
+ t.Error(err)
+ }
+
+ err = pool.Add(tx1)
+ if err == nil {
+ t.Error("added tx twice")
+ }
+}
+
+func TestAddInvalidTx(t *testing.T) {
+ pool, _ := setup()
+ tx1 := transaction()
+ err := pool.Add(tx1)
+ if err == nil {
+ t.Error("expected error")
+ }
+}
+
+func TestRemoveSet(t *testing.T) {
+ pool, _ := setup()
+ tx1 := transaction()
+ pool.addTx(tx1)
+ pool.RemoveSet(types.Transactions{tx1})
+ if pool.Size() > 0 {
+ t.Error("expected pool size to be 0")
+ }
+}
+
+func TestRemoveInvalid(t *testing.T) {
+ pool, key := setup()
+ tx1 := transaction()
+ pool.addTx(tx1)
+ pool.RemoveInvalid(SQ())
+ if pool.Size() > 0 {
+ t.Error("expected pool size to be 0")
+ }
+
+ tx1.SetNonce(1)
+ tx1.SignECDSA(key)
+ pool.addTx(tx1)
+ pool.RemoveInvalid(SQ())
+ if pool.Size() != 1 {
+ t.Error("expected pool size to be 1, is", pool.Size())
+ }
+}
+
+func TestInvalidSender(t *testing.T) {
+ pool, _ := setup()
+ err := pool.ValidateTransaction(new(types.Transaction))
+ if err != ErrInvalidSender {
+ t.Errorf("expected %v, got %v", ErrInvalidSender, err)
+ }
+}
diff --git a/core/types/block.go b/core/types/block.go
new file mode 100644
index 000000000..d5cd8a21e
--- /dev/null
+++ b/core/types/block.go
@@ -0,0 +1,403 @@
+package types
+
+import (
+ "encoding/binary"
+ "fmt"
+ "io"
+ "math/big"
+ "sort"
+ "time"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/crypto/sha3"
+ "github.com/ethereum/go-ethereum/rlp"
+)
+
+type Header struct {
+ // Hash to the previous block
+ ParentHash common.Hash
+ // Uncles of this block
+ UncleHash common.Hash
+ // The coin base address
+ Coinbase common.Address
+ // Block Trie state
+ Root common.Hash
+ // Tx sha
+ TxHash common.Hash
+ // Receipt sha
+ ReceiptHash common.Hash
+ // Bloom
+ Bloom Bloom
+ // Difficulty for the current block
+ Difficulty *big.Int
+ // The block number
+ Number *big.Int
+ // Gas limit
+ GasLimit *big.Int
+ // Gas used
+ GasUsed *big.Int
+ // Creation time
+ Time uint64
+ // Extra data
+ Extra string
+ // Mix digest for quick checking to prevent DOS
+ MixDigest common.Hash
+ // Nonce
+ Nonce [8]byte
+}
+
+func (self *Header) Hash() common.Hash {
+ return rlpHash(self.rlpData(true))
+}
+
+func (self *Header) HashNoNonce() common.Hash {
+ return rlpHash(self.rlpData(false))
+}
+
+func (self *Header) rlpData(withNonce bool) []interface{} {
+ fields := []interface{}{
+ self.ParentHash,
+ self.UncleHash,
+ self.Coinbase,
+ self.Root,
+ self.TxHash,
+ self.ReceiptHash,
+ self.Bloom,
+ self.Difficulty,
+ self.Number,
+ self.GasLimit,
+ self.GasUsed,
+ self.Time,
+ self.Extra,
+ }
+ if withNonce {
+ fields = append(fields, self.MixDigest, self.Nonce)
+ }
+ return fields
+}
+
+func (self *Header) RlpData() interface{} {
+ return self.rlpData(true)
+}
+
+func rlpHash(x interface{}) (h common.Hash) {
+ hw := sha3.NewKeccak256()
+ rlp.Encode(hw, x)
+ hw.Sum(h[:0])
+ return h
+}
+
+type Block struct {
+ // Preset Hash for mock (Tests)
+ HeaderHash common.Hash
+ ParentHeaderHash common.Hash
+ // ^^^^ ignore ^^^^
+
+ header *Header
+ uncles []*Header
+ transactions Transactions
+ Td *big.Int
+
+ receipts Receipts
+}
+
+// StorageBlock defines the RLP encoding of a Block stored in the
+// state database. The StorageBlock encoding contains fields that
+// would otherwise need to be recomputed.
+type StorageBlock Block
+
+// "external" block encoding. used for eth protocol, etc.
+type extblock struct {
+ Header *Header
+ Txs []*Transaction
+ Uncles []*Header
+}
+
+// "storage" block encoding. used for database.
+type storageblock struct {
+ Header *Header
+ Txs []*Transaction
+ Uncles []*Header
+ TD *big.Int
+}
+
+func NewBlock(parentHash common.Hash, coinbase common.Address, root common.Hash, difficulty *big.Int, nonce uint64, extra string) *Block {
+ header := &Header{
+ Root: root,
+ ParentHash: parentHash,
+ Coinbase: coinbase,
+ Difficulty: difficulty,
+ Time: uint64(time.Now().Unix()),
+ Extra: extra,
+ GasUsed: new(big.Int),
+ GasLimit: new(big.Int),
+ Number: new(big.Int),
+ }
+ header.SetNonce(nonce)
+ block := &Block{header: header}
+ block.Td = new(big.Int)
+
+ return block
+}
+
+func (self *Header) SetNonce(nonce uint64) {
+ binary.BigEndian.PutUint64(self.Nonce[:], nonce)
+}
+
+func NewBlockWithHeader(header *Header) *Block {
+ return &Block{header: header}
+}
+
+func (self *Block) ValidateFields() error {
+ if self.header == nil {
+ return fmt.Errorf("header is nil")
+ }
+ for i, transaction := range self.transactions {
+ if transaction == nil {
+ return fmt.Errorf("transaction %d is nil", i)
+ }
+ }
+ for i, uncle := range self.uncles {
+ if uncle == nil {
+ return fmt.Errorf("uncle %d is nil", i)
+ }
+ }
+ return nil
+}
+
+func (self *Block) DecodeRLP(s *rlp.Stream) error {
+ var eb extblock
+ if err := s.Decode(&eb); err != nil {
+ return err
+ }
+ self.header, self.uncles, self.transactions = eb.Header, eb.Uncles, eb.Txs
+ return nil
+}
+
+func (self Block) EncodeRLP(w io.Writer) error {
+ return rlp.Encode(w, extblock{
+ Header: self.header,
+ Txs: self.transactions,
+ Uncles: self.uncles,
+ })
+}
+
+func (self *StorageBlock) DecodeRLP(s *rlp.Stream) error {
+ var sb storageblock
+ if err := s.Decode(&sb); err != nil {
+ return err
+ }
+ self.header, self.uncles, self.transactions, self.Td = sb.Header, sb.Uncles, sb.Txs, sb.TD
+ return nil
+}
+
+func (self StorageBlock) EncodeRLP(w io.Writer) error {
+ return rlp.Encode(w, storageblock{
+ Header: self.header,
+ Txs: self.transactions,
+ Uncles: self.uncles,
+ TD: self.Td,
+ })
+}
+
+func (self *Block) Header() *Header {
+ return self.header
+}
+
+func (self *Block) Uncles() []*Header {
+ return self.uncles
+}
+
+func (self *Block) SetUncles(uncleHeaders []*Header) {
+ self.uncles = uncleHeaders
+ self.header.UncleHash = rlpHash(uncleHeaders)
+}
+
+func (self *Block) Transactions() Transactions {
+ return self.transactions
+}
+
+func (self *Block) Transaction(hash common.Hash) *Transaction {
+ for _, transaction := range self.transactions {
+ if transaction.Hash() == hash {
+ return transaction
+ }
+ }
+ return nil
+}
+
+func (self *Block) SetTransactions(transactions Transactions) {
+ self.transactions = transactions
+ self.header.TxHash = DeriveSha(transactions)
+}
+func (self *Block) AddTransaction(transaction *Transaction) {
+ self.transactions = append(self.transactions, transaction)
+ self.SetTransactions(self.transactions)
+}
+
+func (self *Block) Receipts() Receipts {
+ return self.receipts
+}
+
+func (self *Block) SetReceipts(receipts Receipts) {
+ self.receipts = receipts
+ self.header.ReceiptHash = DeriveSha(receipts)
+ self.header.Bloom = CreateBloom(receipts)
+}
+func (self *Block) AddReceipt(receipt *Receipt) {
+ self.receipts = append(self.receipts, receipt)
+ self.SetReceipts(self.receipts)
+}
+
+func (self *Block) RlpData() interface{} {
+ return []interface{}{self.header, self.transactions, self.uncles}
+}
+
+func (self *Block) RlpDataForStorage() interface{} {
+ return []interface{}{self.header, self.transactions, self.uncles, self.Td /* TODO receipts */}
+}
+
+// Header accessors (add as you need them)
+func (self *Block) Number() *big.Int { return self.header.Number }
+func (self *Block) NumberU64() uint64 { return self.header.Number.Uint64() }
+func (self *Block) MixDigest() common.Hash { return self.header.MixDigest }
+func (self *Block) Nonce() uint64 {
+ return binary.BigEndian.Uint64(self.header.Nonce[:])
+}
+func (self *Block) SetNonce(nonce uint64) {
+ self.header.SetNonce(nonce)
+}
+
+func (self *Block) Bloom() Bloom { return self.header.Bloom }
+func (self *Block) Coinbase() common.Address { return self.header.Coinbase }
+func (self *Block) Time() int64 { return int64(self.header.Time) }
+func (self *Block) GasLimit() *big.Int { return self.header.GasLimit }
+func (self *Block) GasUsed() *big.Int { return self.header.GasUsed }
+func (self *Block) Root() common.Hash { return self.header.Root }
+func (self *Block) SetRoot(root common.Hash) { self.header.Root = root }
+func (self *Block) GetTransaction(i int) *Transaction {
+ if len(self.transactions) > i {
+ return self.transactions[i]
+ }
+ return nil
+}
+func (self *Block) GetUncle(i int) *Header {
+ if len(self.uncles) > i {
+ return self.uncles[i]
+ }
+ return nil
+}
+
+func (self *Block) Size() common.StorageSize {
+ c := writeCounter(0)
+ rlp.Encode(&c, self)
+ return common.StorageSize(c)
+}
+
+type writeCounter common.StorageSize
+
+func (c *writeCounter) Write(b []byte) (int, error) {
+ *c += writeCounter(len(b))
+ return len(b), nil
+}
+
+// Implement pow.Block
+func (self *Block) Difficulty() *big.Int { return self.header.Difficulty }
+func (self *Block) HashNoNonce() common.Hash { return self.header.HashNoNonce() }
+
+func (self *Block) Hash() common.Hash {
+ if (self.HeaderHash != common.Hash{}) {
+ return self.HeaderHash
+ } else {
+ return self.header.Hash()
+ }
+}
+
+func (self *Block) ParentHash() common.Hash {
+ if (self.ParentHeaderHash != common.Hash{}) {
+ return self.ParentHeaderHash
+ } else {
+ return self.header.ParentHash
+ }
+}
+
+func (self *Block) Copy() *Block {
+ block := NewBlock(self.header.ParentHash, self.Coinbase(), self.Root(), new(big.Int), self.Nonce(), self.header.Extra)
+ block.header.Bloom = self.header.Bloom
+ block.header.TxHash = self.header.TxHash
+ block.transactions = self.transactions
+ block.header.UncleHash = self.header.UncleHash
+ block.uncles = self.uncles
+ block.header.GasLimit.Set(self.header.GasLimit)
+ block.header.GasUsed.Set(self.header.GasUsed)
+ block.header.ReceiptHash = self.header.ReceiptHash
+ block.header.Difficulty.Set(self.header.Difficulty)
+ block.header.Number.Set(self.header.Number)
+ block.header.Time = self.header.Time
+ block.header.MixDigest = self.header.MixDigest
+ if self.Td != nil {
+ block.Td.Set(self.Td)
+ }
+
+ return block
+}
+
+func (self *Block) String() string {
+ return fmt.Sprintf(`BLOCK(%x): Size: %v TD: %v {
+NoNonce: %x
+Header:
+[
+%v
+]
+Transactions:
+%v
+Uncles:
+%v
+}
+`, self.header.Hash(), self.Size(), self.Td, self.header.HashNoNonce(), self.header, self.transactions, self.uncles)
+}
+
+func (self *Header) String() string {
+ return fmt.Sprintf(`
+ ParentHash: %x
+ UncleHash: %x
+ Coinbase: %x
+ Root: %x
+ TxSha %x
+ ReceiptSha: %x
+ Bloom: %x
+ Difficulty: %v
+ Number: %v
+ GasLimit: %v
+ GasUsed: %v
+ Time: %v
+ Extra: %v
+ MixDigest: %x
+ Nonce: %x`,
+ self.ParentHash, self.UncleHash, self.Coinbase, self.Root, self.TxHash, self.ReceiptHash, self.Bloom, self.Difficulty, self.Number, self.GasLimit, self.GasUsed, self.Time, self.Extra, self.MixDigest, self.Nonce)
+}
+
+type Blocks []*Block
+
+type BlockBy func(b1, b2 *Block) bool
+
+func (self BlockBy) Sort(blocks Blocks) {
+ bs := blockSorter{
+ blocks: blocks,
+ by: self,
+ }
+ sort.Sort(bs)
+}
+
+type blockSorter struct {
+ blocks Blocks
+ by func(b1, b2 *Block) bool
+}
+
+func (self blockSorter) Len() int { return len(self.blocks) }
+func (self blockSorter) Swap(i, j int) {
+ self.blocks[i], self.blocks[j] = self.blocks[j], self.blocks[i]
+}
+func (self blockSorter) Less(i, j int) bool { return self.by(self.blocks[i], self.blocks[j]) }
+
+func Number(b1, b2 *Block) bool { return b1.Header().Number.Cmp(b2.Header().Number) < 0 }
diff --git a/core/types/block_test.go b/core/types/block_test.go
new file mode 100644
index 000000000..e4f6c38a5
--- /dev/null
+++ b/core/types/block_test.go
@@ -0,0 +1,60 @@
+package types
+
+import (
+ "bytes"
+ "math/big"
+ "reflect"
+ "testing"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/rlp"
+)
+
+// from bcValidBlockTest.json, "SimpleTx"
+func TestBlockEncoding(t *testing.T) {
+ blockEnc := common.FromHex("f90260f901f9a083cafc574e1f51ba9dc0568fc617a08ea2429fb384059c972f13b19fa1c8dd55a01dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347948888f1f195afa192cfee860698584c030f4c9db1a0ef1552a40b7165c3cd773806b9e0c165b75356e0314bf0706f279c729f51e017a05fe50b260da6308036625b850b5d6ced6d0a9f814c0688bc91ffb7b7a3a54b67a0bc37d79753ad738a6dac4921e57392f145d8887476de3f783dfa7edae9283e52b90100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000008302000001832fefd8825208845506eb0780a0bd4472abb6659ebe3ee06ee4d7b72a00a9f4d001caca51342001075469aff49888a13a5a8c8f2bb1c4f861f85f800a82c35094095e7baea6a6c7c4c2dfeb977efac326af552d870a801ba09bea4c4daac7c7c52e093e6a4c35dbbcf8856f1af7b059ba20253e70848d094fa08a8fae537ce25ed8cb5af9adac3f141af69bd515bd2ba031522df09b97dd72b1c0")
+
+ var block Block
+ if err := rlp.DecodeBytes(blockEnc, &block); err != nil {
+ t.Fatal("decode error: ", err)
+ }
+
+ check := func(f string, got, want interface{}) {
+ if !reflect.DeepEqual(got, want) {
+ t.Errorf("%s mismatch: got %v, want %v", f, got, want)
+ }
+ }
+ check("Difficulty", block.Difficulty(), big.NewInt(131072))
+ check("GasLimit", block.GasLimit(), big.NewInt(3141592))
+ check("GasUsed", block.GasUsed(), big.NewInt(21000))
+ check("Coinbase", block.Coinbase(), common.HexToAddress("8888f1f195afa192cfee860698584c030f4c9db1"))
+ check("MixDigest", block.MixDigest(), common.HexToHash("bd4472abb6659ebe3ee06ee4d7b72a00a9f4d001caca51342001075469aff498"))
+ check("Root", block.Root(), common.HexToHash("ef1552a40b7165c3cd773806b9e0c165b75356e0314bf0706f279c729f51e017"))
+ check("Hash", block.Hash(), common.HexToHash("0a5843ac1cb04865017cb35a57b50b07084e5fcee39b5acadade33149f4fff9e"))
+ check("Nonce", block.Nonce(), uint64(0xa13a5a8c8f2bb1c4))
+ check("Time", block.Time(), int64(1426516743))
+ check("Size", block.Size(), common.StorageSize(len(blockEnc)))
+
+ to := common.HexToAddress("095e7baea6a6c7c4c2dfeb977efac326af552d87")
+ check("Transactions", block.Transactions(), Transactions{
+ {
+ Payload: []byte{},
+ Amount: big.NewInt(10),
+ Price: big.NewInt(10),
+ GasLimit: big.NewInt(50000),
+ AccountNonce: 0,
+ V: 27,
+ R: common.FromHex("9bea4c4daac7c7c52e093e6a4c35dbbcf8856f1af7b059ba20253e70848d094f"),
+ S: common.FromHex("8a8fae537ce25ed8cb5af9adac3f141af69bd515bd2ba031522df09b97dd72b1"),
+ Recipient: &to,
+ },
+ })
+
+ ourBlockEnc, err := rlp.EncodeToBytes(&block)
+ if err != nil {
+ t.Fatal("encode error: ", err)
+ }
+ if !bytes.Equal(ourBlockEnc, blockEnc) {
+ t.Errorf("encoded block mismatch:\ngot: %x\nwant: %x", ourBlockEnc, blockEnc)
+ }
+}
diff --git a/core/types/bloom9.go b/core/types/bloom9.go
new file mode 100644
index 000000000..af90679ce
--- /dev/null
+++ b/core/types/bloom9.go
@@ -0,0 +1,59 @@
+package types
+
+import (
+ "math/big"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/crypto"
+ "github.com/ethereum/go-ethereum/core/state"
+)
+
+func CreateBloom(receipts Receipts) Bloom {
+ bin := new(big.Int)
+ for _, receipt := range receipts {
+ bin.Or(bin, LogsBloom(receipt.logs))
+ }
+
+ return BytesToBloom(bin.Bytes())
+}
+
+func LogsBloom(logs state.Logs) *big.Int {
+ bin := new(big.Int)
+ for _, log := range logs {
+ data := make([]common.Hash, len(log.Topics()))
+ bin.Or(bin, bloom9(log.Address().Bytes()))
+
+ for i, topic := range log.Topics() {
+ data[i] = topic
+ }
+
+ for _, b := range data {
+ bin.Or(bin, bloom9(b[:]))
+ }
+ }
+
+ return bin
+}
+
+func bloom9(b []byte) *big.Int {
+ b = crypto.Sha3(b[:])
+
+ r := new(big.Int)
+
+ for i := 0; i < 6; i += 2 {
+ t := big.NewInt(1)
+ b := (uint(b[i+1]) + (uint(b[i]) << 8)) & 2047
+ r.Or(r, t.Lsh(t, b))
+ }
+
+ return r
+}
+
+var Bloom9 = bloom9
+
+func BloomLookup(bin Bloom, topic common.Hash) bool {
+ bloom := bin.Big()
+ cmp := bloom9(topic[:])
+
+ return bloom.And(bloom, cmp).Cmp(cmp) == 0
+}
diff --git a/core/types/bloom9_test.go b/core/types/bloom9_test.go
new file mode 100644
index 000000000..3c95772ec
--- /dev/null
+++ b/core/types/bloom9_test.go
@@ -0,0 +1,31 @@
+package types
+
+/*
+import (
+ "testing"
+
+ "github.com/ethereum/go-ethereum/core/state"
+)
+
+func TestBloom9(t *testing.T) {
+ testCase := []byte("testtest")
+ bin := LogsBloom([]state.Log{
+ {testCase, [][]byte{[]byte("hellohello")}, nil},
+ }).Bytes()
+ res := BloomLookup(bin, testCase)
+
+ if !res {
+ t.Errorf("Bloom lookup failed")
+ }
+}
+
+
+func TestAddress(t *testing.T) {
+ block := &Block{}
+ block.Coinbase = common.Hex2Bytes("22341ae42d6dd7384bc8584e50419ea3ac75b83f")
+ fmt.Printf("%x\n", crypto.Sha3(block.Coinbase))
+
+ bin := CreateBloom(block)
+ fmt.Printf("bin = %x\n", common.LeftPadBytes(bin, 64))
+}
+*/
diff --git a/core/types/common.go b/core/types/common.go
new file mode 100644
index 000000000..4397d4938
--- /dev/null
+++ b/core/types/common.go
@@ -0,0 +1,40 @@
+package types
+
+import (
+ "math/big"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/core/state"
+
+ "fmt"
+)
+
+type BlockProcessor interface {
+ Process(*Block) (*big.Int, state.Logs, error)
+}
+
+const bloomLength = 256
+
+type Bloom [bloomLength]byte
+
+func BytesToBloom(b []byte) Bloom {
+ var bloom Bloom
+ bloom.SetBytes(b)
+ return bloom
+}
+
+func (b *Bloom) SetBytes(d []byte) {
+ if len(b) < len(d) {
+ panic(fmt.Sprintf("bloom bytes too big %d %d", len(b), len(d)))
+ }
+
+ copy(b[bloomLength-len(d):], d)
+}
+
+func (b Bloom) Big() *big.Int {
+ return common.Bytes2Big(b[:])
+}
+
+func (b Bloom) Bytes() []byte {
+ return b[:]
+}
diff --git a/core/types/derive_sha.go b/core/types/derive_sha.go
new file mode 100644
index 000000000..f25e5937e
--- /dev/null
+++ b/core/types/derive_sha.go
@@ -0,0 +1,24 @@
+package types
+
+import (
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/ethdb"
+ "github.com/ethereum/go-ethereum/rlp"
+ "github.com/ethereum/go-ethereum/trie"
+)
+
+type DerivableList interface {
+ Len() int
+ GetRlp(i int) []byte
+}
+
+func DeriveSha(list DerivableList) common.Hash {
+ db, _ := ethdb.NewMemDatabase()
+ trie := trie.New(nil, db)
+ for i := 0; i < list.Len(); i++ {
+ key, _ := rlp.EncodeToBytes(uint(i))
+ trie.Update(key, list.GetRlp(i))
+ }
+
+ return common.BytesToHash(trie.Root())
+}
diff --git a/core/types/receipt.go b/core/types/receipt.go
new file mode 100644
index 000000000..83c981f93
--- /dev/null
+++ b/core/types/receipt.go
@@ -0,0 +1,81 @@
+package types
+
+import (
+ "bytes"
+ "fmt"
+ "io"
+ "math/big"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/rlp"
+ "github.com/ethereum/go-ethereum/core/state"
+)
+
+type Receipt struct {
+ PostState []byte
+ CumulativeGasUsed *big.Int
+ Bloom Bloom
+ logs state.Logs
+}
+
+func NewReceipt(root []byte, cumalativeGasUsed *big.Int) *Receipt {
+ return &Receipt{PostState: common.CopyBytes(root), CumulativeGasUsed: new(big.Int).Set(cumalativeGasUsed)}
+}
+
+func (self *Receipt) SetLogs(logs state.Logs) {
+ self.logs = logs
+}
+
+func (self *Receipt) EncodeRLP(w io.Writer) error {
+ return rlp.Encode(w, []interface{}{self.PostState, self.CumulativeGasUsed, self.Bloom, self.logs})
+}
+
+/*
+func (self *Receipt) RlpData() interface{} {
+ return []interface{}{self.PostState, self.CumulativeGasUsed, self.Bloom, self.logs.RlpData()}
+}
+*/
+
+func (self *Receipt) RlpEncode() []byte {
+ bytes, err := rlp.EncodeToBytes(self)
+ if err != nil {
+ fmt.Println("TMP -- RECEIPT ENCODE ERROR", err)
+ }
+ return bytes
+}
+
+func (self *Receipt) Cmp(other *Receipt) bool {
+ if bytes.Compare(self.PostState, other.PostState) != 0 {
+ return false
+ }
+
+ return true
+}
+
+func (self *Receipt) String() string {
+ return fmt.Sprintf("receipt{med=%x cgas=%v bloom=%x logs=%v}", self.PostState, self.CumulativeGasUsed, self.Bloom, self.logs)
+}
+
+type Receipts []*Receipt
+
+/*
+func (self Receipts) RlpData() interface{} {
+ data := make([]interface{}, len(self))
+ for i, receipt := range self {
+ data[i] = receipt.RlpData()
+ }
+
+ return data
+}
+*/
+
+func (self Receipts) RlpEncode() []byte {
+ bytes, err := rlp.EncodeToBytes(self)
+ if err != nil {
+ fmt.Println("TMP -- RECEIPTS ENCODE ERROR", err)
+ }
+ return bytes
+}
+
+func (self Receipts) Len() int { return len(self) }
+func (self Receipts) GetRlp(i int) []byte { return common.Rlp(self[i]) }
diff --git a/core/types/transaction.go b/core/types/transaction.go
new file mode 100644
index 000000000..35e8f5ac8
--- /dev/null
+++ b/core/types/transaction.go
@@ -0,0 +1,214 @@
+package types
+
+import (
+ "crypto/ecdsa"
+ "errors"
+ "fmt"
+ "math/big"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/crypto"
+ "github.com/ethereum/go-ethereum/crypto/secp256k1"
+ "github.com/ethereum/go-ethereum/rlp"
+)
+
+func IsContractAddr(addr []byte) bool {
+ return len(addr) == 0
+}
+
+type Transaction struct {
+ AccountNonce uint64
+ Price *big.Int
+ GasLimit *big.Int
+ Recipient *common.Address // nil means contract creation
+ Amount *big.Int
+ Payload []byte
+ V byte
+ R, S []byte
+}
+
+func NewContractCreationTx(amount, gasLimit, gasPrice *big.Int, data []byte) *Transaction {
+ return &Transaction{Recipient: nil, Amount: amount, GasLimit: gasLimit, Price: gasPrice, Payload: data}
+}
+
+func NewTransactionMessage(to common.Address, amount, gasAmount, gasPrice *big.Int, data []byte) *Transaction {
+ return &Transaction{Recipient: &to, Amount: amount, GasLimit: gasAmount, Price: gasPrice, Payload: data}
+}
+
+func NewTransactionFromBytes(data []byte) *Transaction {
+ // TODO: remove this function if possible. callers would
+ // much better off decoding into transaction directly.
+ // it's not that hard.
+ tx := new(Transaction)
+ rlp.DecodeBytes(data, tx)
+ return tx
+}
+
+func (tx *Transaction) Hash() common.Hash {
+ return rlpHash([]interface{}{
+ tx.AccountNonce, tx.Price, tx.GasLimit, tx.Recipient, tx.Amount, tx.Payload,
+ })
+}
+
+func (self *Transaction) Data() []byte {
+ return self.Payload
+}
+
+func (self *Transaction) Gas() *big.Int {
+ return self.GasLimit
+}
+
+func (self *Transaction) GasPrice() *big.Int {
+ return self.Price
+}
+
+func (self *Transaction) Value() *big.Int {
+ return self.Amount
+}
+
+func (self *Transaction) Nonce() uint64 {
+ return self.AccountNonce
+}
+
+func (self *Transaction) SetNonce(AccountNonce uint64) {
+ self.AccountNonce = AccountNonce
+}
+
+func (self *Transaction) From() (common.Address, error) {
+ pubkey := self.PublicKey()
+ if len(pubkey) == 0 || pubkey[0] != 4 {
+ return common.Address{}, errors.New("invalid public key")
+ }
+
+ var addr common.Address
+ copy(addr[:], crypto.Sha3(pubkey[1:])[12:])
+ return addr, nil
+}
+
+// To returns the recipient of the transaction.
+// If transaction is a contract creation (with no recipient address)
+// To returns nil.
+func (tx *Transaction) To() *common.Address {
+ return tx.Recipient
+}
+
+func (tx *Transaction) Curve() (v byte, r []byte, s []byte) {
+ v = byte(tx.V)
+ r = common.LeftPadBytes(tx.R, 32)
+ s = common.LeftPadBytes(tx.S, 32)
+ return
+}
+
+func (tx *Transaction) Signature(key []byte) []byte {
+ hash := tx.Hash()
+ sig, _ := secp256k1.Sign(hash[:], key)
+ return sig
+}
+
+func (tx *Transaction) PublicKey() []byte {
+ hash := tx.Hash()
+ v, r, s := tx.Curve()
+ sig := append(r, s...)
+ sig = append(sig, v-27)
+
+ //pubkey := crypto.Ecrecover(append(hash[:], sig...))
+ //pubkey, _ := secp256k1.RecoverPubkey(hash[:], sig)
+ pubkey := crypto.FromECDSAPub(crypto.SigToPub(hash[:], sig))
+ return pubkey
+}
+
+func (tx *Transaction) SetSignatureValues(sig []byte) error {
+ tx.R = sig[:32]
+ tx.S = sig[32:64]
+ tx.V = sig[64] + 27
+ return nil
+}
+
+func (tx *Transaction) SignECDSA(prv *ecdsa.PrivateKey) error {
+ h := tx.Hash()
+ sig, err := crypto.Sign(h[:], prv)
+ if err != nil {
+ return err
+ }
+ tx.SetSignatureValues(sig)
+ return nil
+}
+
+// TODO: remove
+func (tx *Transaction) RlpData() interface{} {
+ data := []interface{}{tx.AccountNonce, tx.Price, tx.GasLimit, tx.Recipient, tx.Amount, tx.Payload}
+ return append(data, tx.V, new(big.Int).SetBytes(tx.R).Bytes(), new(big.Int).SetBytes(tx.S).Bytes())
+}
+
+func (tx *Transaction) String() string {
+ var from, to string
+ if f, err := tx.From(); err != nil {
+ from = "[invalid sender]"
+ } else {
+ from = fmt.Sprintf("%x", f[:])
+ }
+ if t := tx.To(); t == nil {
+ to = "[contract creation]"
+ } else {
+ to = fmt.Sprintf("%x", t[:])
+ }
+ enc, _ := rlp.EncodeToBytes(tx)
+ return fmt.Sprintf(`
+ TX(%x)
+ Contract: %v
+ From: %s
+ To: %s
+ Nonce: %v
+ GasPrice: %v
+ GasLimit %v
+ Value: %v
+ Data: 0x%x
+ V: 0x%x
+ R: 0x%x
+ S: 0x%x
+ Hex: %x
+`,
+ tx.Hash(),
+ len(tx.Recipient) == 0,
+ from,
+ to,
+ tx.AccountNonce,
+ tx.Price,
+ tx.GasLimit,
+ tx.Amount,
+ tx.Payload,
+ tx.V,
+ tx.R,
+ tx.S,
+ enc,
+ )
+}
+
+// Transaction slice type for basic sorting
+type Transactions []*Transaction
+
+// TODO: remove
+func (self Transactions) RlpData() interface{} {
+ // Marshal the transactions of this block
+ enc := make([]interface{}, len(self))
+ for i, tx := range self {
+ // Cast it to a string (safe)
+ enc[i] = tx.RlpData()
+ }
+
+ return enc
+}
+
+func (s Transactions) Len() int { return len(s) }
+func (s Transactions) Swap(i, j int) { s[i], s[j] = s[j], s[i] }
+
+func (s Transactions) GetRlp(i int) []byte {
+ enc, _ := rlp.EncodeToBytes(s[i])
+ return enc
+}
+
+type TxByNonce struct{ Transactions }
+
+func (s TxByNonce) Less(i, j int) bool {
+ return s.Transactions[i].AccountNonce < s.Transactions[j].AccountNonce
+}
diff --git a/core/types/transaction_test.go b/core/types/transaction_test.go
new file mode 100644
index 000000000..6a015cb9a
--- /dev/null
+++ b/core/types/transaction_test.go
@@ -0,0 +1,111 @@
+package types
+
+import (
+ "bytes"
+ "crypto/ecdsa"
+ "math/big"
+ "testing"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/crypto"
+ "github.com/ethereum/go-ethereum/rlp"
+)
+
+// The values in those tests are from the Transaction Tests
+// at github.com/ethereum/tests.
+
+var (
+ emptyTx = NewTransactionMessage(
+ common.HexToAddress("095e7baea6a6c7c4c2dfeb977efac326af552d87"),
+ big.NewInt(0), big.NewInt(0), big.NewInt(0),
+ nil,
+ )
+
+ rightvrsRecipient = common.HexToAddress("b94f5374fce5edbc8e2a8697c15331677e6ebf0b")
+ rightvrsTx = &Transaction{
+ Recipient: &rightvrsRecipient,
+ AccountNonce: 3,
+ Price: big.NewInt(1),
+ GasLimit: big.NewInt(2000),
+ Amount: big.NewInt(10),
+ Payload: common.FromHex("5544"),
+ V: 28,
+ R: common.FromHex("98ff921201554726367d2be8c804a7ff89ccf285ebc57dff8ae4c44b9c19ac4a"),
+ S: common.FromHex("8887321be575c8095f789dd4c743dfe42c1820f9231f98a962b210e3ac2452a3"),
+ }
+)
+
+func TestTransactionHash(t *testing.T) {
+ // "EmptyTransaction"
+ if emptyTx.Hash() != common.HexToHash("c775b99e7ad12f50d819fcd602390467e28141316969f4b57f0626f74fe3b386") {
+ t.Errorf("empty transaction hash mismatch, got %x", emptyTx.Hash())
+ }
+
+ // "RightVRSTest"
+ if rightvrsTx.Hash() != common.HexToHash("fe7a79529ed5f7c3375d06b26b186a8644e0e16c373d7a12be41c62d6042b77a") {
+ t.Errorf("RightVRS transaction hash mismatch, got %x", rightvrsTx.Hash())
+ }
+}
+
+func TestTransactionEncode(t *testing.T) {
+ // "RightVRSTest"
+ txb, err := rlp.EncodeToBytes(rightvrsTx)
+ if err != nil {
+ t.Fatalf("encode error: %v", err)
+ }
+ should := common.FromHex("f86103018207d094b94f5374fce5edbc8e2a8697c15331677e6ebf0b0a8255441ca098ff921201554726367d2be8c804a7ff89ccf285ebc57dff8ae4c44b9c19ac4aa08887321be575c8095f789dd4c743dfe42c1820f9231f98a962b210e3ac2452a3")
+ if !bytes.Equal(txb, should) {
+ t.Errorf("encoded RLP mismatch, got %x", txb)
+ }
+}
+
+func decodeTx(data []byte) (*Transaction, error) {
+ var tx Transaction
+ return &tx, rlp.Decode(bytes.NewReader(data), &tx)
+}
+
+func defaultTestKey() (*ecdsa.PrivateKey, []byte) {
+ key := crypto.ToECDSA(common.Hex2Bytes("45a915e4d060149eb4365960e6a7a45f334393093061116b197e3240065ff2d8"))
+ addr := crypto.PubkeyToAddress(key.PublicKey)
+ return key, addr
+}
+
+func TestRecipientEmpty(t *testing.T) {
+ _, addr := defaultTestKey()
+
+ tx, err := decodeTx(common.Hex2Bytes("f8498080808080011ca09b16de9d5bdee2cf56c28d16275a4da68cd30273e2525f3959f5d62557489921a0372ebd8fb3345f7db7b5a86d42e24d36e983e259b0664ceb8c227ec9af572f3d"))
+ if err != nil {
+ t.Error(err)
+ t.FailNow()
+ }
+
+ from, err := tx.From()
+ if err != nil {
+ t.Error(err)
+ t.FailNow()
+ }
+
+ if !bytes.Equal(addr, from.Bytes()) {
+ t.Error("derived address doesn't match")
+ }
+}
+
+func TestRecipientNormal(t *testing.T) {
+ _, addr := defaultTestKey()
+
+ tx, err := decodeTx(common.Hex2Bytes("f85d80808094000000000000000000000000000000000000000080011ca0527c0d8f5c63f7b9f41324a7c8a563ee1190bcbf0dac8ab446291bdbf32f5c79a0552c4ef0a09a04395074dab9ed34d3fbfb843c2f2546cc30fe89ec143ca94ca6"))
+ if err != nil {
+ t.Error(err)
+ t.FailNow()
+ }
+
+ from, err := tx.From()
+ if err != nil {
+ t.Error(err)
+ t.FailNow()
+ }
+
+ if !bytes.Equal(addr, from.Bytes()) {
+ t.Error("derived address doesn't match")
+ }
+}
diff --git a/core/vm/address.go b/core/vm/address.go
new file mode 100644
index 000000000..df801863f
--- /dev/null
+++ b/core/vm/address.go
@@ -0,0 +1,95 @@
+package vm
+
+import (
+ "math/big"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/crypto"
+ "github.com/ethereum/go-ethereum/params"
+)
+
+type Address interface {
+ Call(in []byte) []byte
+}
+
+type PrecompiledAccount struct {
+ Gas func(l int) *big.Int
+ fn func(in []byte) []byte
+}
+
+func (self PrecompiledAccount) Call(in []byte) []byte {
+ return self.fn(in)
+}
+
+var Precompiled = PrecompiledContracts()
+
+// XXX Could set directly. Testing requires resetting and setting of pre compiled contracts.
+func PrecompiledContracts() map[string]*PrecompiledAccount {
+ return map[string]*PrecompiledAccount{
+ // ECRECOVER
+ string(common.LeftPadBytes([]byte{1}, 20)): &PrecompiledAccount{func(l int) *big.Int {
+ return params.EcrecoverGas
+ }, ecrecoverFunc},
+
+ // SHA256
+ string(common.LeftPadBytes([]byte{2}, 20)): &PrecompiledAccount{func(l int) *big.Int {
+ n := big.NewInt(int64(l+31) / 32)
+ n.Mul(n, params.Sha256WordGas)
+ return n.Add(n, params.Sha256Gas)
+ }, sha256Func},
+
+ // RIPEMD160
+ string(common.LeftPadBytes([]byte{3}, 20)): &PrecompiledAccount{func(l int) *big.Int {
+ n := big.NewInt(int64(l+31) / 32)
+ n.Mul(n, params.Ripemd160WordGas)
+ return n.Add(n, params.Ripemd160Gas)
+ }, ripemd160Func},
+
+ string(common.LeftPadBytes([]byte{4}, 20)): &PrecompiledAccount{func(l int) *big.Int {
+ n := big.NewInt(int64(l+31) / 32)
+ n.Mul(n, params.IdentityWordGas)
+
+ return n.Add(n, params.IdentityGas)
+ }, memCpy},
+ }
+}
+
+func sha256Func(in []byte) []byte {
+ return crypto.Sha256(in)
+}
+
+func ripemd160Func(in []byte) []byte {
+ return common.LeftPadBytes(crypto.Ripemd160(in), 32)
+}
+
+const ecRecoverInputLength = 128
+
+func ecrecoverFunc(in []byte) []byte {
+ // "in" is (hash, v, r, s), each 32 bytes
+ // but for ecrecover we want (r, s, v)
+ if len(in) < ecRecoverInputLength {
+ return nil
+ }
+
+ // Treat V as a 256bit integer
+ v := new(big.Int).Sub(common.Bytes2Big(in[32:64]), big.NewInt(27))
+ // Ethereum requires V to be either 0 or 1 => (27 || 28)
+ if !(v.Cmp(Zero) == 0 || v.Cmp(One) == 0) {
+ return nil
+ }
+
+ // v needs to be moved to the end
+ rsv := append(in[64:128], byte(v.Uint64()))
+ pubKey := crypto.Ecrecover(in[:32], rsv)
+ // make sure the public key is a valid one
+ if pubKey == nil || len(pubKey) != 65 {
+ return nil
+ }
+
+ // the first byte of pubkey is bitcoin heritage
+ return common.LeftPadBytes(crypto.Sha3(pubKey[1:])[12:], 32)
+}
+
+func memCpy(in []byte) []byte {
+ return in
+}
diff --git a/core/vm/analysis.go b/core/vm/analysis.go
new file mode 100644
index 000000000..264d55cb9
--- /dev/null
+++ b/core/vm/analysis.go
@@ -0,0 +1,36 @@
+package vm
+
+import (
+ "math/big"
+
+ "gopkg.in/fatih/set.v0"
+)
+
+type destinations struct {
+ set *set.Set
+}
+
+func (d *destinations) Has(dest *big.Int) bool {
+ return d.set.Has(string(dest.Bytes()))
+}
+
+func (d *destinations) Add(dest *big.Int) {
+ d.set.Add(string(dest.Bytes()))
+}
+
+func analyseJumpDests(code []byte) (dests *destinations) {
+ dests = &destinations{set.New()}
+
+ for pc := uint64(0); pc < uint64(len(code)); pc++ {
+ var op OpCode = OpCode(code[pc])
+ switch op {
+ case PUSH1, PUSH2, PUSH3, PUSH4, PUSH5, PUSH6, PUSH7, PUSH8, PUSH9, PUSH10, PUSH11, PUSH12, PUSH13, PUSH14, PUSH15, PUSH16, PUSH17, PUSH18, PUSH19, PUSH20, PUSH21, PUSH22, PUSH23, PUSH24, PUSH25, PUSH26, PUSH27, PUSH28, PUSH29, PUSH30, PUSH31, PUSH32:
+ a := uint64(op) - uint64(PUSH1) + 1
+
+ pc += a
+ case JUMPDEST:
+ dests.Add(big.NewInt(int64(pc)))
+ }
+ }
+ return
+}
diff --git a/core/vm/asm.go b/core/vm/asm.go
new file mode 100644
index 000000000..83fcb0e08
--- /dev/null
+++ b/core/vm/asm.go
@@ -0,0 +1,45 @@
+package vm
+
+import (
+ "fmt"
+ "math/big"
+
+ "github.com/ethereum/go-ethereum/common"
+)
+
+func Disassemble(script []byte) (asm []string) {
+ pc := new(big.Int)
+ for {
+ if pc.Cmp(big.NewInt(int64(len(script)))) >= 0 {
+ return
+ }
+
+ // Get the memory location of pc
+ val := script[pc.Int64()]
+ // Get the opcode (it must be an opcode!)
+ op := OpCode(val)
+
+ asm = append(asm, fmt.Sprintf("%v", op))
+
+ switch op {
+ case PUSH1, PUSH2, PUSH3, PUSH4, PUSH5, PUSH6, PUSH7, PUSH8, PUSH9, PUSH10, PUSH11, PUSH12, PUSH13, PUSH14, PUSH15, PUSH16, PUSH17, PUSH18, PUSH19, PUSH20, PUSH21, PUSH22, PUSH23, PUSH24, PUSH25, PUSH26, PUSH27, PUSH28, PUSH29, PUSH30, PUSH31, PUSH32:
+ pc.Add(pc, common.Big1)
+ a := int64(op) - int64(PUSH1) + 1
+ if int(pc.Int64()+a) > len(script) {
+ return nil
+ }
+
+ data := script[pc.Int64() : pc.Int64()+a]
+ if len(data) == 0 {
+ data = []byte{0}
+ }
+ asm = append(asm, fmt.Sprintf("0x%x", data))
+
+ pc.Add(pc, big.NewInt(a-1))
+ }
+
+ pc.Add(pc, common.Big1)
+ }
+
+ return
+}
diff --git a/core/vm/common.go b/core/vm/common.go
new file mode 100644
index 000000000..0a93c3dd9
--- /dev/null
+++ b/core/vm/common.go
@@ -0,0 +1,91 @@
+package vm
+
+import (
+ "math"
+ "math/big"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/logger"
+)
+
+var vmlogger = logger.NewLogger("VM")
+
+// Global Debug flag indicating Debug VM (full logging)
+var Debug bool
+
+type Type byte
+
+const (
+ StdVmTy Type = iota
+ JitVmTy
+ MaxVmTy
+
+ LogTyPretty byte = 0x1
+ LogTyDiff byte = 0x2
+)
+
+var (
+ Pow256 = common.BigPow(2, 256)
+
+ U256 = common.U256
+ S256 = common.S256
+
+ Zero = common.Big0
+ One = common.Big1
+
+ max = big.NewInt(math.MaxInt64)
+)
+
+func NewVm(env Environment) VirtualMachine {
+ switch env.VmType() {
+ case JitVmTy:
+ return NewJitVm(env)
+ default:
+ vmlogger.Infoln("unsupported vm type %d", env.VmType())
+ fallthrough
+ case StdVmTy:
+ return New(env)
+ }
+}
+
+func calcMemSize(off, l *big.Int) *big.Int {
+ if l.Cmp(common.Big0) == 0 {
+ return common.Big0
+ }
+
+ return new(big.Int).Add(off, l)
+}
+
+// Simple helper
+func u256(n int64) *big.Int {
+ return big.NewInt(n)
+}
+
+// Mainly used for print variables and passing to Print*
+func toValue(val *big.Int) interface{} {
+ // Let's assume a string on right padded zero's
+ b := val.Bytes()
+ if b[0] != 0 && b[len(b)-1] == 0x0 && b[len(b)-2] == 0x0 {
+ return string(b)
+ }
+
+ return val
+}
+
+func getData(data []byte, start, size *big.Int) []byte {
+ dlen := big.NewInt(int64(len(data)))
+
+ s := common.BigMin(start, dlen)
+ e := common.BigMin(new(big.Int).Add(s, size), dlen)
+ return common.RightPadBytes(data[s.Uint64():e.Uint64()], int(size.Uint64()))
+}
+
+func UseGas(gas, amount *big.Int) bool {
+ if gas.Cmp(amount) < 0 {
+ return false
+ }
+
+ // Sub the amount of gas from the remaining
+ gas.Sub(gas, amount)
+ return true
+}
diff --git a/core/vm/context.go b/core/vm/context.go
new file mode 100644
index 000000000..29bb9f74e
--- /dev/null
+++ b/core/vm/context.go
@@ -0,0 +1,94 @@
+package vm
+
+import (
+ "math/big"
+
+ "github.com/ethereum/go-ethereum/common"
+)
+
+type ContextRef interface {
+ ReturnGas(*big.Int, *big.Int)
+ Address() common.Address
+ SetCode([]byte)
+}
+
+type Context struct {
+ caller ContextRef
+ self ContextRef
+
+ Code []byte
+ CodeAddr *common.Address
+
+ value, Gas, UsedGas, Price *big.Int
+
+ Args []byte
+}
+
+// Create a new context for the given data items
+func NewContext(caller ContextRef, object ContextRef, value, gas, price *big.Int) *Context {
+ c := &Context{caller: caller, self: object, Args: nil}
+
+ // Gas should be a pointer so it can safely be reduced through the run
+ // This pointer will be off the state transition
+ c.Gas = gas //new(big.Int).Set(gas)
+ c.value = new(big.Int).Set(value)
+ // In most cases price and value are pointers to transaction objects
+ // and we don't want the transaction's values to change.
+ c.Price = new(big.Int).Set(price)
+ c.UsedGas = new(big.Int)
+
+ return c
+}
+
+func (c *Context) GetOp(n *big.Int) OpCode {
+ return OpCode(c.GetByte(n))
+}
+
+func (c *Context) GetByte(n *big.Int) byte {
+ if n.Cmp(big.NewInt(int64(len(c.Code)))) < 0 {
+ return c.Code[n.Int64()]
+ }
+
+ return 0
+}
+
+func (c *Context) Return(ret []byte) []byte {
+ // Return the remaining gas to the caller
+ c.caller.ReturnGas(c.Gas, c.Price)
+
+ return ret
+}
+
+/*
+ * Gas functions
+ */
+func (c *Context) UseGas(gas *big.Int) (ok bool) {
+ ok = UseGas(c.Gas, gas)
+ if ok {
+ c.UsedGas.Add(c.UsedGas, gas)
+ }
+ return
+}
+
+// Implement the caller interface
+func (c *Context) ReturnGas(gas, price *big.Int) {
+ // Return the gas to the context
+ c.Gas.Add(c.Gas, gas)
+ c.UsedGas.Sub(c.UsedGas, gas)
+}
+
+/*
+ * Set / Get
+ */
+func (c *Context) Address() common.Address {
+ return c.self.Address()
+}
+
+func (self *Context) SetCode(code []byte) {
+ self.Code = code
+}
+
+func (self *Context) SetCallCode(addr *common.Address, code []byte) {
+ self.Code = code
+ self.CodeAddr = addr
+}
diff --git a/core/vm/environment.go b/core/vm/environment.go
new file mode 100644
index 000000000..72e18c353
--- /dev/null
+++ b/core/vm/environment.go
@@ -0,0 +1,91 @@
+package vm
+
+import (
+ "errors"
+ "fmt"
+ "io"
+ "math/big"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/core/state"
+ "github.com/ethereum/go-ethereum/rlp"
+)
+
+type Environment interface {
+ State() *state.StateDB
+
+ Origin() common.Address
+ BlockNumber() *big.Int
+ GetHash(n uint64) common.Hash
+ Coinbase() common.Address
+ Time() int64
+ Difficulty() *big.Int
+ GasLimit() *big.Int
+ Transfer(from, to Account, amount *big.Int) error
+ AddLog(state.Log)
+
+ VmType() Type
+
+ Depth() int
+ SetDepth(i int)
+
+ Call(me ContextRef, addr common.Address, data []byte, gas, price, value *big.Int) ([]byte, error)
+ CallCode(me ContextRef, addr common.Address, data []byte, gas, price, value *big.Int) ([]byte, error)
+ Create(me ContextRef, data []byte, gas, price, value *big.Int) ([]byte, error, ContextRef)
+}
+
+type Account interface {
+ SubBalance(amount *big.Int)
+ AddBalance(amount *big.Int)
+ Balance() *big.Int
+ Address() common.Address
+}
+
+// generic transfer method
+func Transfer(from, to Account, amount *big.Int) error {
+ if from.Balance().Cmp(amount) < 0 {
+ return errors.New("Insufficient balance in account")
+ }
+
+ from.SubBalance(amount)
+ to.AddBalance(amount)
+
+ return nil
+}
+
+type Log struct {
+ address common.Address
+ topics []common.Hash
+ data []byte
+ log uint64
+}
+
+func (self *Log) Address() common.Address {
+ return self.address
+}
+
+func (self *Log) Topics() []common.Hash {
+ return self.topics
+}
+
+func (self *Log) Data() []byte {
+ return self.data
+}
+
+func (self *Log) Number() uint64 {
+ return self.log
+}
+
+func (self *Log) EncodeRLP(w io.Writer) error {
+ return rlp.Encode(w, []interface{}{self.address, self.topics, self.data})
+}
+
+/*
+func (self *Log) RlpData() interface{} {
+ return []interface{}{self.address, common.ByteSliceToInterface(self.topics), self.data}
+}
+*/
+
+func (self *Log) String() string {
+ return fmt.Sprintf("{%x %x %x}", self.address, self.data, self.topics)
+}
diff --git a/core/vm/errors.go b/core/vm/errors.go
new file mode 100644
index 000000000..fc3459de0
--- /dev/null
+++ b/core/vm/errors.go
@@ -0,0 +1,52 @@
+package vm
+
+import (
+ "fmt"
+ "github.com/ethereum/go-ethereum/params"
+ "math/big"
+)
+
+type OutOfGasError struct {
+ req, has *big.Int
+}
+
+func OOG(req, has *big.Int) OutOfGasError {
+ return OutOfGasError{req, has}
+}
+
+func (self OutOfGasError) Error() string {
+ return fmt.Sprintf("out of gas! require %v, have %v", self.req, self.has)
+}
+
+func IsOOGErr(err error) bool {
+ _, ok := err.(OutOfGasError)
+ return ok
+}
+
+type StackError struct {
+ req, has int
+}
+
+func StackErr(req, has int) StackError {
+ return StackError{req, has}
+}
+
+func (self StackError) Error() string {
+ return fmt.Sprintf("stack error! require %v, have %v", self.req, self.has)
+}
+
+func IsStack(err error) bool {
+ _, ok := err.(StackError)
+ return ok
+}
+
+type DepthError struct{}
+
+func (self DepthError) Error() string {
+ return fmt.Sprintf("Max call depth exceeded (%d)", params.CallCreateDepth)
+}
+
+func IsDepthErr(err error) bool {
+ _, ok := err.(DepthError)
+ return ok
+}
diff --git a/core/vm/gas.go b/core/vm/gas.go
new file mode 100644
index 000000000..f7abe63f8
--- /dev/null
+++ b/core/vm/gas.go
@@ -0,0 +1,125 @@
+package vm
+
+import (
+ "fmt"
+ "github.com/ethereum/go-ethereum/params"
+ "math/big"
+)
+
+var (
+ GasQuickStep = big.NewInt(2)
+ GasFastestStep = big.NewInt(3)
+ GasFastStep = big.NewInt(5)
+ GasMidStep = big.NewInt(8)
+ GasSlowStep = big.NewInt(10)
+ GasExtStep = big.NewInt(20)
+
+ GasReturn = big.NewInt(0)
+ GasStop = big.NewInt(0)
+
+ GasContractByte = big.NewInt(200)
+)
+
+func baseCheck(op OpCode, stack *stack, gas *big.Int) error {
+ // PUSH and DUP are a bit special. They all cost the same but we do want to have checking on stack push limit
+ // PUSH is also allowed to calculate the same price for all PUSHes
+ // DUP requirements are handled elsewhere (except for the stack limit check)
+ if op >= PUSH1 && op <= PUSH32 {
+ op = PUSH1
+ }
+ if op >= DUP1 && op <= DUP16 {
+ op = DUP1
+ }
+
+ if r, ok := _baseCheck[op]; ok {
+ err := stack.require(r.stackPop)
+ if err != nil {
+ return err
+ }
+
+ if r.stackPush && len(stack.data)-r.stackPop+1 > int(params.StackLimit.Int64()) {
+ return fmt.Errorf("stack limit reached (%d)", params.StackLimit.Int64())
+ }
+
+ gas.Add(gas, r.gas)
+ }
+ return nil
+}
+
+func toWordSize(size *big.Int) *big.Int {
+ tmp := new(big.Int)
+ tmp.Add(size, u256(31))
+ tmp.Div(tmp, u256(32))
+ return tmp
+}
+
+type req struct {
+ stackPop int
+ gas *big.Int
+ stackPush bool
+}
+
+var _baseCheck = map[OpCode]req{
+ // opcode | stack pop | gas price | stack push
+ ADD: {2, GasFastestStep, true},
+ LT: {2, GasFastestStep, true},
+ GT: {2, GasFastestStep, true},
+ SLT: {2, GasFastestStep, true},
+ SGT: {2, GasFastestStep, true},
+ EQ: {2, GasFastestStep, true},
+ ISZERO: {1, GasFastestStep, true},
+ SUB: {2, GasFastestStep, true},
+ AND: {2, GasFastestStep, true},
+ OR: {2, GasFastestStep, true},
+ XOR: {2, GasFastestStep, true},
+ NOT: {1, GasFastestStep, true},
+ BYTE: {2, GasFastestStep, true},
+ CALLDATALOAD: {1, GasFastestStep, true},
+ CALLDATACOPY: {3, GasFastestStep, true},
+ MLOAD: {1, GasFastestStep, true},
+ MSTORE: {2, GasFastestStep, false},
+ MSTORE8: {2, GasFastestStep, false},
+ CODECOPY: {3, GasFastestStep, false},
+ MUL: {2, GasFastStep, true},
+ DIV: {2, GasFastStep, true},
+ SDIV: {2, GasFastStep, true},
+ MOD: {2, GasFastStep, true},
+ SMOD: {2, GasFastStep, true},
+ SIGNEXTEND: {2, GasFastStep, true},
+ ADDMOD: {3, GasMidStep, true},
+ MULMOD: {3, GasMidStep, true},
+ JUMP: {1, GasMidStep, false},
+ JUMPI: {2, GasSlowStep, false},
+ EXP: {2, GasSlowStep, true},
+ ADDRESS: {0, GasQuickStep, true},
+ ORIGIN: {0, GasQuickStep, true},
+ CALLER: {0, GasQuickStep, true},
+ CALLVALUE: {0, GasQuickStep, true},
+ CODESIZE: {0, GasQuickStep, true},
+ GASPRICE: {0, GasQuickStep, true},
+ COINBASE: {0, GasQuickStep, true},
+ TIMESTAMP: {0, GasQuickStep, true},
+ NUMBER: {0, GasQuickStep, true},
+ CALLDATASIZE: {0, GasQuickStep, true},
+ DIFFICULTY: {0, GasQuickStep, true},
+ GASLIMIT: {0, GasQuickStep, true},
+ POP: {1, GasQuickStep, false},
+ PC: {0, GasQuickStep, true},
+ MSIZE: {0, GasQuickStep, true},
+ GAS: {0, GasQuickStep, true},
+ BLOCKHASH: {1, GasExtStep, true},
+ BALANCE: {1, GasExtStep, true},
+ EXTCODESIZE: {1, GasExtStep, true},
+ EXTCODECOPY: {4, GasExtStep, false},
+ SLOAD: {1, params.SloadGas, true},
+ SSTORE: {2, Zero, false},
+ SHA3: {2, params.Sha3Gas, true},
+ CREATE: {3, params.CreateGas, true},
+ CALL: {7, params.CallGas, true},
+ CALLCODE: {7, params.CallGas, true},
+ JUMPDEST: {0, params.JumpdestGas, false},
+ SUICIDE: {1, Zero, false},
+ RETURN: {2, Zero, false},
+ PUSH1: {0, GasFastestStep, true},
+ DUP1: {0, Zero, true},
+}
diff --git a/core/vm/main_test.go b/core/vm/main_test.go
new file mode 100644
index 000000000..0ae03bf6a
--- /dev/null
+++ b/core/vm/main_test.go
@@ -0,0 +1,9 @@
+package vm
+
+import (
+ "testing"
+
+ checker "gopkg.in/check.v1"
+)
+
+func Test(t *testing.T) { checker.TestingT(t) }
diff --git a/core/vm/memory.go b/core/vm/memory.go
new file mode 100644
index 000000000..b77d486eb
--- /dev/null
+++ b/core/vm/memory.go
@@ -0,0 +1,72 @@
+package vm
+
+import (
+ "fmt"
+
+ "github.com/ethereum/go-ethereum/common"
+)
+
+type Memory struct {
+ store []byte
+}
+
+func NewMemory() *Memory {
+ return &Memory{nil}
+}
+
+func (m *Memory) Set(offset, size uint64, value []byte) {
+ // length of store may never be less than offset + size.
+ // The store should be resized PRIOR to setting the memory
+ if size > uint64(len(m.store)) {
+ panic("INVALID memory: store empty")
+ }
+
+ // It's possible the offset is greater than 0 and size equals 0. This is because
+ // the calcMemSize (common.go) could potentially return 0 when size is zero (NO-OP)
+ if size > 0 {
+ copy(m.store[offset:offset+size], common.RightPadBytes(value, int(size)))
+ }
+}
+
+func (m *Memory) Resize(size uint64) {
+ if uint64(m.Len()) < size {
+ m.store = append(m.store, make([]byte, size-uint64(m.Len()))...)
+ }
+}
+
+func (self *Memory) Get(offset, size int64) (cpy []byte) {
+ if size == 0 {
+ return nil
+ }
+
+ if len(self.store) > int(offset) {
+ cpy = make([]byte, size)
+ copy(cpy, self.store[offset:offset+size])
+
+ return
+ }
+
+ return
+}
+
+func (m *Memory) Len() int {
+ return len(m.store)
+}
+
+func (m *Memory) Data() []byte {
+ return m.store
+}
+
+func (m *Memory) Print() {
+ fmt.Printf("### mem %d bytes ###\n", len(m.store))
+ if len(m.store) > 0 {
+ addr := 0
+ for i := 0; i+32 <= len(m.store); i += 32 {
+ fmt.Printf("%03d: % x\n", addr, m.store[i:i+32])
+ addr++
+ }
+ } else {
+ fmt.Println("-- empty --")
+ }
+ fmt.Println("####################")
+}
diff --git a/core/vm/stack.go b/core/vm/stack.go
new file mode 100644
index 000000000..bb232d0b9
--- /dev/null
+++ b/core/vm/stack.go
@@ -0,0 +1,67 @@
+package vm
+
+import (
+ "fmt"
+ "math/big"
+)
+
+func newStack() *stack {
+ return &stack{}
+}
+
+type stack struct {
+ data []*big.Int
+ ptr int
+}
+
+func (st *stack) push(d *big.Int) {
+ // NOTE push limit (1024) is checked in baseCheck
+ stackItem := new(big.Int).Set(d)
+ if len(st.data) > st.ptr {
+ st.data[st.ptr] = stackItem
+ } else {
+ st.data = append(st.data, stackItem)
+ }
+ st.ptr++
+}
+
+func (st *stack) pop() (ret *big.Int) {
+ st.ptr--
+ ret = st.data[st.ptr]
+ return
+}
+
+func (st *stack) len() int {
+ return st.ptr
+}
+
+func (st *stack) swap(n int) {
+ st.data[st.len()-n], st.data[st.len()-1] = st.data[st.len()-1], st.data[st.len()-n]
+}
+
+func (st *stack) dup(n int) {
+ st.push(st.data[st.len()-n])
+}
+
+func (st *stack) peek() *big.Int {
+ return st.data[st.len()-1]
+}
+
+func (st *stack) require(n int) error {
+ if st.len() < n {
+ return fmt.Errorf("stack underflow (%d <=> %d)", len(st.data), n)
+ }
+ return nil
+}
+
+func (st *stack) Print() {
+ fmt.Println("### stack ###")
+ if len(st.data) > 0 {
+ for i, val := range st.data {
+ fmt.Printf("%-3d %v\n", i, val)
+ }
+ } else {
+ fmt.Println("-- empty --")
+ }
+ fmt.Println("#############")
+}
diff --git a/core/vm/types.go b/core/vm/types.go
new file mode 100644
index 000000000..1ea80a212
--- /dev/null
+++ b/core/vm/types.go
@@ -0,0 +1,334 @@
+package vm
+
+import (
+ "fmt"
+)
+
+type OpCode byte
+
+// Op codes
+const (
+ // 0x0 range - arithmetic ops
+ STOP OpCode = iota
+ ADD
+ MUL
+ SUB
+ DIV
+ SDIV
+ MOD
+ SMOD
+ ADDMOD
+ MULMOD
+ EXP
+ SIGNEXTEND
+)
+
+const (
+ LT OpCode = iota + 0x10
+ GT
+ SLT
+ SGT
+ EQ
+ ISZERO
+ AND
+ OR
+ XOR
+ NOT
+ BYTE
+
+ SHA3 = 0x20
+)
+
+const (
+ // 0x30 range - closure state
+ ADDRESS OpCode = 0x30 + iota
+ BALANCE
+ ORIGIN
+ CALLER
+ CALLVALUE
+ CALLDATALOAD
+ CALLDATASIZE
+ CALLDATACOPY
+ CODESIZE
+ CODECOPY
+ GASPRICE
+ EXTCODESIZE
+ EXTCODECOPY
+)
+
+const (
+
+ // 0x40 range - block operations
+ BLOCKHASH OpCode = 0x40 + iota
+ COINBASE
+ TIMESTAMP
+ NUMBER
+ DIFFICULTY
+ GASLIMIT
+)
+
+const (
+ // 0x50 range - 'storage' and execution
+ POP OpCode = 0x50 + iota
+ MLOAD
+ MSTORE
+ MSTORE8
+ SLOAD
+ SSTORE
+ JUMP
+ JUMPI
+ PC
+ MSIZE
+ GAS
+ JUMPDEST
+)
+
+const (
+ // 0x60 range
+ PUSH1 OpCode = 0x60 + iota
+ PUSH2
+ PUSH3
+ PUSH4
+ PUSH5
+ PUSH6
+ PUSH7
+ PUSH8
+ PUSH9
+ PUSH10
+ PUSH11
+ PUSH12
+ PUSH13
+ PUSH14
+ PUSH15
+ PUSH16
+ PUSH17
+ PUSH18
+ PUSH19
+ PUSH20
+ PUSH21
+ PUSH22
+ PUSH23
+ PUSH24
+ PUSH25
+ PUSH26
+ PUSH27
+ PUSH28
+ PUSH29
+ PUSH30
+ PUSH31
+ PUSH32
+ DUP1
+ DUP2
+ DUP3
+ DUP4
+ DUP5
+ DUP6
+ DUP7
+ DUP8
+ DUP9
+ DUP10
+ DUP11
+ DUP12
+ DUP13
+ DUP14
+ DUP15
+ DUP16
+ SWAP1
+ SWAP2
+ SWAP3
+ SWAP4
+ SWAP5
+ SWAP6
+ SWAP7
+ SWAP8
+ SWAP9
+ SWAP10
+ SWAP11
+ SWAP12
+ SWAP13
+ SWAP14
+ SWAP15
+ SWAP16
+)
+
+const (
+ LOG0 OpCode = 0xa0 + iota
+ LOG1
+ LOG2
+ LOG3
+ LOG4
+)
+
+const (
+ // 0xf0 range - closures
+ CREATE OpCode = 0xf0 + iota
+ CALL
+ CALLCODE
+ RETURN
+
+ // 0x70 range - other
+ SUICIDE = 0xff
+)
+
+// Since the opcodes aren't all in order we can't use a regular slice
+var opCodeToString = map[OpCode]string{
+ // 0x0 range - arithmetic ops
+ STOP: "STOP",
+ ADD: "ADD",
+ MUL: "MUL",
+ SUB: "SUB",
+ DIV: "DIV",
+ SDIV: "SDIV",
+ MOD: "MOD",
+ SMOD: "SMOD",
+ EXP: "EXP",
+ NOT: "NOT",
+ LT: "LT",
+ GT: "GT",
+ SLT: "SLT",
+ SGT: "SGT",
+ EQ: "EQ",
+ ISZERO: "ISZERO",
+ SIGNEXTEND: "SIGNEXTEND",
+
+ // 0x10 range - bit ops
+ AND: "AND",
+ OR: "OR",
+ XOR: "XOR",
+ BYTE: "BYTE",
+ ADDMOD: "ADDMOD",
+ MULMOD: "MULMOD",
+
+ // 0x20 range - crypto
+ SHA3: "SHA3",
+
+ // 0x30 range - closure state
+ ADDRESS: "ADDRESS",
+ BALANCE: "BALANCE",
+ ORIGIN: "ORIGIN",
+ CALLER: "CALLER",
+ CALLVALUE: "CALLVALUE",
+ CALLDATALOAD: "CALLDATALOAD",
+ CALLDATASIZE: "CALLDATASIZE",
+ CALLDATACOPY: "CALLDATACOPY",
+ CODESIZE: "CODESIZE",
+ CODECOPY: "CODECOPY",
+ GASPRICE: "TXGASPRICE",
+
+ // 0x40 range - block operations
+ BLOCKHASH: "BLOCKHASH",
+ COINBASE: "COINBASE",
+ TIMESTAMP: "TIMESTAMP",
+ NUMBER: "NUMBER",
+ DIFFICULTY: "DIFFICULTY",
+ GASLIMIT: "GASLIMIT",
+ EXTCODESIZE: "EXTCODESIZE",
+ EXTCODECOPY: "EXTCODECOPY",
+
+ // 0x50 range - 'storage' and execution
+ POP: "POP",
+ //DUP: "DUP",
+ //SWAP: "SWAP",
+ MLOAD: "MLOAD",
+ MSTORE: "MSTORE",
+ MSTORE8: "MSTORE8",
+ SLOAD: "SLOAD",
+ SSTORE: "SSTORE",
+ JUMP: "JUMP",
+ JUMPI: "JUMPI",
+ PC: "PC",
+ MSIZE: "MSIZE",
+ GAS: "GAS",
+ JUMPDEST: "JUMPDEST",
+
+ // 0x60 range - push
+ PUSH1: "PUSH1",
+ PUSH2: "PUSH2",
+ PUSH3: "PUSH3",
+ PUSH4: "PUSH4",
+ PUSH5: "PUSH5",
+ PUSH6: "PUSH6",
+ PUSH7: "PUSH7",
+ PUSH8: "PUSH8",
+ PUSH9: "PUSH9",
+ PUSH10: "PUSH10",
+ PUSH11: "PUSH11",
+ PUSH12: "PUSH12",
+ PUSH13: "PUSH13",
+ PUSH14: "PUSH14",
+ PUSH15: "PUSH15",
+ PUSH16: "PUSH16",
+ PUSH17: "PUSH17",
+ PUSH18: "PUSH18",
+ PUSH19: "PUSH19",
+ PUSH20: "PUSH20",
+ PUSH21: "PUSH21",
+ PUSH22: "PUSH22",
+ PUSH23: "PUSH23",
+ PUSH24: "PUSH24",
+ PUSH25: "PUSH25",
+ PUSH26: "PUSH26",
+ PUSH27: "PUSH27",
+ PUSH28: "PUSH28",
+ PUSH29: "PUSH29",
+ PUSH30: "PUSH30",
+ PUSH31: "PUSH31",
+ PUSH32: "PUSH32",
+
+ DUP1: "DUP1",
+ DUP2: "DUP2",
+ DUP3: "DUP3",
+ DUP4: "DUP4",
+ DUP5: "DUP5",
+ DUP6: "DUP6",
+ DUP7: "DUP7",
+ DUP8: "DUP8",
+ DUP9: "DUP9",
+ DUP10: "DUP10",
+ DUP11: "DUP11",
+ DUP12: "DUP12",
+ DUP13: "DUP13",
+ DUP14: "DUP14",
+ DUP15: "DUP15",
+ DUP16: "DUP16",
+
+ SWAP1: "SWAP1",
+ SWAP2: "SWAP2",
+ SWAP3: "SWAP3",
+ SWAP4: "SWAP4",
+ SWAP5: "SWAP5",
+ SWAP6: "SWAP6",
+ SWAP7: "SWAP7",
+ SWAP8: "SWAP8",
+ SWAP9: "SWAP9",
+ SWAP10: "SWAP10",
+ SWAP11: "SWAP11",
+ SWAP12: "SWAP12",
+ SWAP13: "SWAP13",
+ SWAP14: "SWAP14",
+ SWAP15: "SWAP15",
+ SWAP16: "SWAP16",
+ LOG0: "LOG0",
+ LOG1: "LOG1",
+ LOG2: "LOG2",
+ LOG3: "LOG3",
+ LOG4: "LOG4",
+
+ // 0xf0 range
+ CREATE: "CREATE",
+ CALL: "CALL",
+ RETURN: "RETURN",
+ CALLCODE: "CALLCODE",
+
+ // 0x70 range - other
+ SUICIDE: "SUICIDE",
+}
+
+func (o OpCode) String() string {
+ str := opCodeToString[o]
+ if len(str) == 0 {
+ return fmt.Sprintf("Missing opcode 0x%x", int(o))
+ }
+
+ return str
+}
diff --git a/core/vm/virtual_machine.go b/core/vm/virtual_machine.go
new file mode 100644
index 000000000..6db284f42
--- /dev/null
+++ b/core/vm/virtual_machine.go
@@ -0,0 +1,8 @@
+package vm
+
+type VirtualMachine interface {
+ Env() Environment
+ Run(context *Context, data []byte) ([]byte, error)
+ Printf(string, ...interface{}) VirtualMachine
+ Endl() VirtualMachine
+}
diff --git a/core/vm/vm.go b/core/vm/vm.go
new file mode 100644
index 000000000..6222ef8c2
--- /dev/null
+++ b/core/vm/vm.go
@@ -0,0 +1,909 @@
+package vm
+
+import (
+ "fmt"
+ "math/big"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/core/state"
+ "github.com/ethereum/go-ethereum/crypto"
+ "github.com/ethereum/go-ethereum/params"
+)
+
+type Vm struct {
+ env Environment
+
+ logTy byte
+ logStr string
+
+ err error
+ // For logging
+ debug bool
+
+ BreakPoints []int64
+ Stepping bool
+ Fn string
+
+ Recoverable bool
+
+ // Will be called before the vm returns
+ After func(*Context, error)
+}
+
+func New(env Environment) *Vm {
+ lt := LogTyPretty
+
+ return &Vm{debug: Debug, env: env, logTy: lt, Recoverable: true}
+}
+
+func (self *Vm) Run(context *Context, callData []byte) (ret []byte, err error) {
+ self.env.SetDepth(self.env.Depth() + 1)
+ defer self.env.SetDepth(self.env.Depth() - 1)
+
+ var (
+ caller = context.caller
+ code = context.Code
+ value = context.value
+ price = context.Price
+ )
+
+ self.Printf("(%d) (%x) %x (code=%d) gas: %v (d) %x", self.env.Depth(), caller.Address().Bytes()[:4], context.Address(), len(code), context.Gas, callData).Endl()
+
+ // User defer pattern to check for an error and, based on the error being nil or not, use all gas and return.
+ defer func() {
+ if self.After != nil {
+ self.After(context, err)
+ }
+
+ if err != nil {
+ self.Printf(" %v", err).Endl()
+ // In case of a VM exception (known exceptions) all gas consumed (panics NOT included).
+ context.UseGas(context.Gas)
+
+ ret = context.Return(nil)
+ }
+ }()
+
+ if context.CodeAddr != nil {
+ if p := Precompiled[context.CodeAddr.Str()]; p != nil {
+ return self.RunPrecompiled(p, callData, context)
+ }
+ }
+
+ var (
+ op OpCode
+
+ destinations = analyseJumpDests(context.Code)
+ mem = NewMemory()
+ stack = newStack()
+ pc = new(big.Int)
+ statedb = self.env.State()
+
+ jump = func(from *big.Int, to *big.Int) error {
+ nop := context.GetOp(to)
+ if !destinations.Has(to) {
+ return fmt.Errorf("invalid jump destination (%v) %v", nop, to)
+ }
+
+ self.Printf(" ~> %v", to)
+ pc = to
+
+ self.Endl()
+
+ return nil
+ }
+ )
+
+ // Don't bother with the execution if there's no code.
+ if len(code) == 0 {
+ return context.Return(nil), nil
+ }
+
+ for {
+ // The base for all big integer arithmetic
+ base := new(big.Int)
+
+ // Get the memory location of pc
+ op = context.GetOp(pc)
+
+ self.Printf("(pc) %-3d -o- %-14s (m) %-4d (s) %-4d ", pc, op.String(), mem.Len(), stack.len())
+ newMemSize, gas, err := self.calculateGasAndSize(context, caller, op, statedb, mem, stack)
+ if err != nil {
+ return nil, err
+ }
+
+ self.Printf("(g) %-3v (%v)", gas, context.Gas)
+
+ if !context.UseGas(gas) {
+ self.Endl()
+
+ tmp := new(big.Int).Set(context.Gas)
+
+ context.UseGas(context.Gas)
+
+ return context.Return(nil), OOG(gas, tmp)
+ }
+
+ mem.Resize(newMemSize.Uint64())
+
+ switch op {
+ // 0x20 range
+ case ADD:
+ x, y := stack.pop(), stack.pop()
+ self.Printf(" %v + %v", y, x)
+
+ base.Add(x, y)
+
+ U256(base)
+
+ self.Printf(" = %v", base)
+ // pop result back on the stack
+ stack.push(base)
+ case SUB:
+ x, y := stack.pop(), stack.pop()
+ self.Printf(" %v - %v", y, x)
+
+ base.Sub(x, y)
+
+ U256(base)
+
+ self.Printf(" = %v", base)
+ // pop result back on the stack
+ stack.push(base)
+ case MUL:
+ x, y := stack.pop(), stack.pop()
+ self.Printf(" %v * %v", y, x)
+
+ base.Mul(x, y)
+
+ U256(base)
+
+ self.Printf(" = %v", base)
+ // pop result back on the stack
+ stack.push(base)
+ case DIV:
+ x, y := stack.pop(), stack.pop()
+ self.Printf(" %v / %v", x, y)
+
+ if y.Cmp(common.Big0) != 0 {
+ base.Div(x, y)
+ }
+
+ U256(base)
+
+ self.Printf(" = %v", base)
+ // pop result back on the stack
+ stack.push(base)
+ case SDIV:
+ x, y := S256(stack.pop()), S256(stack.pop())
+
+ self.Printf(" %v / %v", x, y)
+
+ if y.Cmp(common.Big0) == 0 {
+ base.Set(common.Big0)
+ } else {
+ n := new(big.Int)
+ if new(big.Int).Mul(x, y).Cmp(common.Big0) < 0 {
+ n.SetInt64(-1)
+ } else {
+ n.SetInt64(1)
+ }
+
+ base.Div(x.Abs(x), y.Abs(y)).Mul(base, n)
+
+ U256(base)
+ }
+
+ self.Printf(" = %v", base)
+ stack.push(base)
+ case MOD:
+ x, y := stack.pop(), stack.pop()
+
+ self.Printf(" %v %% %v", x, y)
+
+ if y.Cmp(common.Big0) == 0 {
+ base.Set(common.Big0)
+ } else {
+ base.Mod(x, y)
+ }
+
+ U256(base)
+
+ self.Printf(" = %v", base)
+ stack.push(base)
+ case SMOD:
+ x, y := S256(stack.pop()), S256(stack.pop())
+
+ self.Printf(" %v %% %v", x, y)
+
+ if y.Cmp(common.Big0) == 0 {
+ base.Set(common.Big0)
+ } else {
+ n := new(big.Int)
+ if x.Cmp(common.Big0) < 0 {
+ n.SetInt64(-1)
+ } else {
+ n.SetInt64(1)
+ }
+
+ base.Mod(x.Abs(x), y.Abs(y)).Mul(base, n)
+
+ U256(base)
+ }
+
+ self.Printf(" = %v", base)
+ stack.push(base)
+
+ case EXP:
+ x, y := stack.pop(), stack.pop()
+
+ self.Printf(" %v ** %v", x, y)
+
+ base.Exp(x, y, Pow256)
+
+ U256(base)
+
+ self.Printf(" = %v", base)
+
+ stack.push(base)
+ case SIGNEXTEND:
+ back := stack.pop()
+ if back.Cmp(big.NewInt(31)) < 0 {
+ bit := uint(back.Uint64()*8 + 7)
+ num := stack.pop()
+ mask := new(big.Int).Lsh(common.Big1, bit)
+ mask.Sub(mask, common.Big1)
+ if common.BitTest(num, int(bit)) {
+ num.Or(num, mask.Not(mask))
+ } else {
+ num.And(num, mask)
+ }
+
+ num = U256(num)
+
+ self.Printf(" = %v", num)
+
+ stack.push(num)
+ }
+ case NOT:
+ stack.push(U256(new(big.Int).Not(stack.pop())))
+ //base.Sub(Pow256, stack.pop()).Sub(base, common.Big1)
+ //base = U256(base)
+ //stack.push(base)
+ case LT:
+ x, y := stack.pop(), stack.pop()
+ self.Printf(" %v < %v", x, y)
+ // x < y
+ if x.Cmp(y) < 0 {
+ stack.push(common.BigTrue)
+ } else {
+ stack.push(common.BigFalse)
+ }
+ case GT:
+ x, y := stack.pop(), stack.pop()
+ self.Printf(" %v > %v", x, y)
+
+ // x > y
+ if x.Cmp(y) > 0 {
+ stack.push(common.BigTrue)
+ } else {
+ stack.push(common.BigFalse)
+ }
+
+ case SLT:
+ x, y := S256(stack.pop()), S256(stack.pop())
+ self.Printf(" %v < %v", x, y)
+ // x < y
+ if x.Cmp(S256(y)) < 0 {
+ stack.push(common.BigTrue)
+ } else {
+ stack.push(common.BigFalse)
+ }
+ case SGT:
+ x, y := S256(stack.pop()), S256(stack.pop())
+ self.Printf(" %v > %v", x, y)
+
+ // x > y
+ if x.Cmp(y) > 0 {
+ stack.push(common.BigTrue)
+ } else {
+ stack.push(common.BigFalse)
+ }
+
+ case EQ:
+ x, y := stack.pop(), stack.pop()
+ self.Printf(" %v == %v", y, x)
+
+ // x == y
+ if x.Cmp(y) == 0 {
+ stack.push(common.BigTrue)
+ } else {
+ stack.push(common.BigFalse)
+ }
+ case ISZERO:
+ x := stack.pop()
+ if x.Cmp(common.BigFalse) > 0 {
+ stack.push(common.BigFalse)
+ } else {
+ stack.push(common.BigTrue)
+ }
+
+ // 0x10 range
+ case AND:
+ x, y := stack.pop(), stack.pop()
+ self.Printf(" %v & %v", y, x)
+
+ stack.push(base.And(x, y))
+ case OR:
+ x, y := stack.pop(), stack.pop()
+ self.Printf(" %v | %v", x, y)
+
+ stack.push(base.Or(x, y))
+ case XOR:
+ x, y := stack.pop(), stack.pop()
+ self.Printf(" %v ^ %v", x, y)
+
+ stack.push(base.Xor(x, y))
+ case BYTE:
+ th, val := stack.pop(), stack.pop()
+
+ if th.Cmp(big.NewInt(32)) < 0 {
+ byt := big.NewInt(int64(common.LeftPadBytes(val.Bytes(), 32)[th.Int64()]))
+
+ base.Set(byt)
+ } else {
+ base.Set(common.BigFalse)
+ }
+
+ self.Printf(" => 0x%x", base.Bytes())
+
+ stack.push(base)
+ case ADDMOD:
+ x := stack.pop()
+ y := stack.pop()
+ z := stack.pop()
+
+ if z.Cmp(Zero) > 0 {
+ add := new(big.Int).Add(x, y)
+ base.Mod(add, z)
+
+ base = U256(base)
+ }
+
+ self.Printf(" %v + %v %% %v = %v", x, y, z, base)
+
+ stack.push(base)
+ case MULMOD:
+ x := stack.pop()
+ y := stack.pop()
+ z := stack.pop()
+
+ if z.Cmp(Zero) > 0 {
+ mul := new(big.Int).Mul(x, y)
+ base.Mod(mul, z)
+
+ U256(base)
+ }
+
+ self.Printf(" %v + %v %% %v = %v", x, y, z, base)
+
+ stack.push(base)
+
+ // 0x20 range
+ case SHA3:
+ offset, size := stack.pop(), stack.pop()
+ data := crypto.Sha3(mem.Get(offset.Int64(), size.Int64()))
+
+ stack.push(common.BigD(data))
+
+ self.Printf(" => (%v) %x", size, data)
+ // 0x30 range
+ case ADDRESS:
+ stack.push(common.Bytes2Big(context.Address().Bytes()))
+
+ self.Printf(" => %x", context.Address())
+ case BALANCE:
+ addr := common.BigToAddress(stack.pop())
+ balance := statedb.GetBalance(addr)
+
+ stack.push(balance)
+
+ self.Printf(" => %v (%x)", balance, addr)
+ case ORIGIN:
+ origin := self.env.Origin()
+
+ stack.push(origin.Big())
+
+ self.Printf(" => %x", origin)
+ case CALLER:
+ caller := context.caller.Address()
+ stack.push(common.Bytes2Big(caller.Bytes()))
+
+ self.Printf(" => %x", caller)
+ case CALLVALUE:
+ stack.push(value)
+
+ self.Printf(" => %v", value)
+ case CALLDATALOAD:
+ data := getData(callData, stack.pop(), common.Big32)
+
+ self.Printf(" => 0x%x", data)
+
+ stack.push(common.Bytes2Big(data))
+ case CALLDATASIZE:
+ l := int64(len(callData))
+ stack.push(big.NewInt(l))
+
+ self.Printf(" => %d", l)
+ case CALLDATACOPY:
+ var (
+ mOff = stack.pop()
+ cOff = stack.pop()
+ l = stack.pop()
+ )
+ data := getData(callData, cOff, l)
+
+ mem.Set(mOff.Uint64(), l.Uint64(), data)
+
+ self.Printf(" => [%v, %v, %v]", mOff, cOff, l)
+ case CODESIZE, EXTCODESIZE:
+ var code []byte
+ if op == EXTCODESIZE {
+ addr := common.BigToAddress(stack.pop())
+
+ code = statedb.GetCode(addr)
+ } else {
+ code = context.Code
+ }
+
+ l := big.NewInt(int64(len(code)))
+ stack.push(l)
+
+ self.Printf(" => %d", l)
+ case CODECOPY, EXTCODECOPY:
+ var code []byte
+ if op == EXTCODECOPY {
+ addr := common.BigToAddress(stack.pop())
+ code = statedb.GetCode(addr)
+ } else {
+ code = context.Code
+ }
+
+ var (
+ mOff = stack.pop()
+ cOff = stack.pop()
+ l = stack.pop()
+ )
+
+ codeCopy := getData(code, cOff, l)
+
+ mem.Set(mOff.Uint64(), l.Uint64(), codeCopy)
+
+ self.Printf(" => [%v, %v, %v] %x", mOff, cOff, l, codeCopy)
+ case GASPRICE:
+ stack.push(context.Price)
+
+ self.Printf(" => %x", context.Price)
+
+ // 0x40 range
+ case BLOCKHASH:
+ num := stack.pop()
+
+ n := new(big.Int).Sub(self.env.BlockNumber(), common.Big257)
+ if num.Cmp(n) > 0 && num.Cmp(self.env.BlockNumber()) < 0 {
+ stack.push(self.env.GetHash(num.Uint64()).Big())
+ } else {
+ stack.push(common.Big0)
+ }
+
+ self.Printf(" => 0x%x", stack.peek().Bytes())
+ case COINBASE:
+ coinbase := self.env.Coinbase()
+
+ stack.push(coinbase.Big())
+
+ self.Printf(" => 0x%x", coinbase)
+ case TIMESTAMP:
+ time := self.env.Time()
+
+ stack.push(big.NewInt(time))
+
+ self.Printf(" => 0x%x", time)
+ case NUMBER:
+ number := self.env.BlockNumber()
+
+ stack.push(U256(number))
+
+ self.Printf(" => 0x%x", number.Bytes())
+ case DIFFICULTY:
+ difficulty := self.env.Difficulty()
+
+ stack.push(difficulty)
+
+ self.Printf(" => 0x%x", difficulty.Bytes())
+ case GASLIMIT:
+ self.Printf(" => %v", self.env.GasLimit())
+
+ stack.push(self.env.GasLimit())
+
+ // 0x50 range
+ case PUSH1, PUSH2, PUSH3, PUSH4, PUSH5, PUSH6, PUSH7, PUSH8, PUSH9, PUSH10, PUSH11, PUSH12, PUSH13, PUSH14, PUSH15, PUSH16, PUSH17, PUSH18, PUSH19, PUSH20, PUSH21, PUSH22, PUSH23, PUSH24, PUSH25, PUSH26, PUSH27, PUSH28, PUSH29, PUSH30, PUSH31, PUSH32:
+ a := big.NewInt(int64(op - PUSH1 + 1))
+ byts := getData(code, new(big.Int).Add(pc, big.NewInt(1)), a)
+ // push value to stack
+ stack.push(common.Bytes2Big(byts))
+ pc.Add(pc, a)
+
+ self.Printf(" => 0x%x", byts)
+ case POP:
+ stack.pop()
+ case DUP1, DUP2, DUP3, DUP4, DUP5, DUP6, DUP7, DUP8, DUP9, DUP10, DUP11, DUP12, DUP13, DUP14, DUP15, DUP16:
+ n := int(op - DUP1 + 1)
+ stack.dup(n)
+
+ self.Printf(" => [%d] 0x%x", n, stack.peek().Bytes())
+ case SWAP1, SWAP2, SWAP3, SWAP4, SWAP5, SWAP6, SWAP7, SWAP8, SWAP9, SWAP10, SWAP11, SWAP12, SWAP13, SWAP14, SWAP15, SWAP16:
+ n := int(op - SWAP1 + 2)
+ stack.swap(n)
+
+ self.Printf(" => [%d]", n)
+ case LOG0, LOG1, LOG2, LOG3, LOG4:
+ n := int(op - LOG0)
+ topics := make([]common.Hash, n)
+ mStart, mSize := stack.pop(), stack.pop()
+ for i := 0; i < n; i++ {
+ topics[i] = common.BigToHash(stack.pop()) //common.LeftPadBytes(stack.pop().Bytes(), 32)
+ }
+
+ data := mem.Get(mStart.Int64(), mSize.Int64())
+ log := &Log{context.Address(), topics, data, self.env.BlockNumber().Uint64()}
+ self.env.AddLog(log)
+
+ self.Printf(" => %v", log)
+ case MLOAD:
+ offset := stack.pop()
+ val := common.BigD(mem.Get(offset.Int64(), 32))
+ stack.push(val)
+
+ self.Printf(" => 0x%x", val.Bytes())
+ case MSTORE: // Store the value at stack top-1 in to memory at location stack top
+ // pop value of the stack
+ mStart, val := stack.pop(), stack.pop()
+ mem.Set(mStart.Uint64(), 32, common.BigToBytes(val, 256))
+
+ self.Printf(" => 0x%x", val)
+ case MSTORE8:
+ off, val := stack.pop().Int64(), stack.pop().Int64()
+
+ mem.store[off] = byte(val & 0xff)
+
+ self.Printf(" => [%v] 0x%x", off, mem.store[off])
+ case SLOAD:
+ loc := common.BigToHash(stack.pop())
+ val := common.Bytes2Big(statedb.GetState(context.Address(), loc))
+ stack.push(val)
+
+ self.Printf(" {0x%x : 0x%x}", loc, val.Bytes())
+ case SSTORE:
+ loc := common.BigToHash(stack.pop())
+ val := stack.pop()
+
+ statedb.SetState(context.Address(), loc, val)
+
+ self.Printf(" {0x%x : 0x%x}", loc, val.Bytes())
+ case JUMP:
+ if err := jump(pc, stack.pop()); err != nil {
+ return nil, err
+ }
+
+ continue
+ case JUMPI:
+ pos, cond := stack.pop(), stack.pop()
+
+ if cond.Cmp(common.BigTrue) >= 0 {
+ if err := jump(pc, pos); err != nil {
+ return nil, err
+ }
+
+ continue
+ }
+
+ self.Printf(" ~> false")
+
+ case JUMPDEST:
+ case PC:
+ //stack.push(big.NewInt(int64(pc)))
+ stack.push(pc)
+ case MSIZE:
+ stack.push(big.NewInt(int64(mem.Len())))
+ case GAS:
+ stack.push(context.Gas)
+
+ self.Printf(" => %x", context.Gas)
+ // 0x60 range
+ case CREATE:
+
+ var (
+ value = stack.pop()
+ offset, size = stack.pop(), stack.pop()
+ input = mem.Get(offset.Int64(), size.Int64())
+ gas = new(big.Int).Set(context.Gas)
+ addr common.Address
+ )
+ self.Endl()
+
+ context.UseGas(context.Gas)
+ ret, suberr, ref := self.env.Create(context, input, gas, price, value)
+ if suberr != nil {
+ stack.push(common.BigFalse)
+
+ self.Printf(" (*) 0x0 %v", suberr)
+ } else {
+ // gas < len(ret) * CreateDataGas == NO_CODE
+ dataGas := big.NewInt(int64(len(ret)))
+ dataGas.Mul(dataGas, params.CreateDataGas)
+ if context.UseGas(dataGas) {
+ ref.SetCode(ret)
+ }
+ addr = ref.Address()
+
+ stack.push(addr.Big())
+
+ }
+
+ case CALL, CALLCODE:
+ gas := stack.pop()
+ // pop gas and value of the stack.
+ addr, value := stack.pop(), stack.pop()
+ value = U256(value)
+ // pop input size and offset
+ inOffset, inSize := stack.pop(), stack.pop()
+ // pop return size and offset
+ retOffset, retSize := stack.pop(), stack.pop()
+
+ address := common.BigToAddress(addr)
+ self.Printf(" => %x", address).Endl()
+
+ // Get the arguments from the memory
+ args := mem.Get(inOffset.Int64(), inSize.Int64())
+
+ if len(value.Bytes()) > 0 {
+ gas.Add(gas, params.CallStipend)
+ }
+
+ var (
+ ret []byte
+ err error
+ )
+ if op == CALLCODE {
+ ret, err = self.env.CallCode(context, address, args, gas, price, value)
+ } else {
+ ret, err = self.env.Call(context, address, args, gas, price, value)
+ }
+
+ if err != nil {
+ stack.push(common.BigFalse)
+
+ self.Printf("%v").Endl()
+ } else {
+ stack.push(common.BigTrue)
+
+ mem.Set(retOffset.Uint64(), retSize.Uint64(), ret)
+ }
+ self.Printf("resume %x (%v)", context.Address(), context.Gas)
+ case RETURN:
+ offset, size := stack.pop(), stack.pop()
+ ret := mem.Get(offset.Int64(), size.Int64())
+
+ self.Printf(" => [%v, %v] (%d) 0x%x", offset, size, len(ret), ret).Endl()
+
+ return context.Return(ret), nil
+ case SUICIDE:
+ receiver := statedb.GetOrNewStateObject(common.BigToAddress(stack.pop()))
+ balance := statedb.GetBalance(context.Address())
+
+ self.Printf(" => (%x) %v", receiver.Address().Bytes()[:4], balance)
+
+ receiver.AddBalance(balance)
+
+ statedb.Delete(context.Address())
+
+ fallthrough
+ case STOP: // Stop the context
+ self.Endl()
+
+ return context.Return(nil), nil
+ default:
+ self.Printf("(pc) %-3v Invalid opcode %x\n", pc, op).Endl()
+
+ return nil, fmt.Errorf("Invalid opcode %x", op)
+ }
+
+ pc.Add(pc, One)
+
+ self.Endl()
+ }
+}
+
+func (self *Vm) calculateGasAndSize(context *Context, caller ContextRef, op OpCode, statedb *state.StateDB, mem *Memory, stack *stack) (*big.Int, *big.Int, error) {
+ var (
+ gas = new(big.Int)
+ newMemSize *big.Int = new(big.Int)
+ )
+ err := baseCheck(op, stack, gas)
+ if err != nil {
+ return nil, nil, err
+ }
+
+ // stack Check, memory resize & gas phase
+ switch op {
+ case SWAP1, SWAP2, SWAP3, SWAP4, SWAP5, SWAP6, SWAP7, SWAP8, SWAP9, SWAP10, SWAP11, SWAP12, SWAP13, SWAP14, SWAP15, SWAP16:
+ n := int(op - SWAP1 + 2)
+ err := stack.require(n)
+ if err != nil {
+ return nil, nil, err
+ }
+ gas.Set(GasFastestStep)
+ case DUP1, DUP2, DUP3, DUP4, DUP5, DUP6, DUP7, DUP8, DUP9, DUP10, DUP11, DUP12, DUP13, DUP14, DUP15, DUP16:
+ n := int(op - DUP1 + 1)
+ err := stack.require(n)
+ if err != nil {
+ return nil, nil, err
+ }
+ gas.Set(GasFastestStep)
+ case LOG0, LOG1, LOG2, LOG3, LOG4:
+ n := int(op - LOG0)
+ err := stack.require(n + 2)
+ if err != nil {
+ return nil, nil, err
+ }
+
+ mSize, mStart := stack.data[stack.len()-2], stack.data[stack.len()-1]
+
+ gas.Add(gas, params.LogGas)
+ gas.Add(gas, new(big.Int).Mul(big.NewInt(int64(n)), params.LogTopicGas))
+ gas.Add(gas, new(big.Int).Mul(mSize, params.LogDataGas))
+
+ newMemSize = calcMemSize(mStart, mSize)
+ case EXP:
+ gas.Add(gas, new(big.Int).Mul(big.NewInt(int64(len(stack.data[stack.len()-2].Bytes()))), params.ExpByteGas))
+ case SSTORE:
+ err := stack.require(2)
+ if err != nil {
+ return nil, nil, err
+ }
+
+ var g *big.Int
+ y, x := stack.data[stack.len()-2], stack.data[stack.len()-1]
+ val := statedb.GetState(context.Address(), common.BigToHash(x))
+ if len(val) == 0 && len(y.Bytes()) > 0 {
+ // 0 => non 0
+ g = params.SstoreSetGas
+ } else if len(val) > 0 && len(y.Bytes()) == 0 {
+ statedb.Refund(self.env.Origin(), params.SstoreRefundGas)
+
+ g = params.SstoreClearGas
+ } else {
+ // non 0 => non 0 (or 0 => 0)
+ g = params.SstoreClearGas
+ }
+ gas.Set(g)
+ case SUICIDE:
+ if !statedb.IsDeleted(context.Address()) {
+ statedb.Refund(self.env.Origin(), params.SuicideRefundGas)
+ }
+ case MLOAD:
+ newMemSize = calcMemSize(stack.peek(), u256(32))
+ case MSTORE8:
+ newMemSize = calcMemSize(stack.peek(), u256(1))
+ case MSTORE:
+ newMemSize = calcMemSize(stack.peek(), u256(32))
+ case RETURN:
+ newMemSize = calcMemSize(stack.peek(), stack.data[stack.len()-2])
+ case SHA3:
+ newMemSize = calcMemSize(stack.peek(), stack.data[stack.len()-2])
+
+ words := toWordSize(stack.data[stack.len()-2])
+ gas.Add(gas, words.Mul(words, params.Sha3WordGas))
+ case CALLDATACOPY:
+ newMemSize = calcMemSize(stack.peek(), stack.data[stack.len()-3])
+
+ words := toWordSize(stack.data[stack.len()-3])
+ gas.Add(gas, words.Mul(words, params.CopyGas))
+ case CODECOPY:
+ newMemSize = calcMemSize(stack.peek(), stack.data[stack.len()-3])
+
+ words := toWordSize(stack.data[stack.len()-3])
+ gas.Add(gas, words.Mul(words, params.CopyGas))
+ case EXTCODECOPY:
+ newMemSize = calcMemSize(stack.data[stack.len()-2], stack.data[stack.len()-4])
+
+ words := toWordSize(stack.data[stack.len()-4])
+ gas.Add(gas, words.Mul(words, params.CopyGas))
+
+ case CREATE:
+ newMemSize = calcMemSize(stack.data[stack.len()-2], stack.data[stack.len()-3])
+ case CALL, CALLCODE:
+ gas.Add(gas, stack.data[stack.len()-1])
+
+ if op == CALL {
+ if self.env.State().GetStateObject(common.BigToAddress(stack.data[stack.len()-2])) == nil {
+ gas.Add(gas, params.CallNewAccountGas)
+ }
+ }
+
+ if len(stack.data[stack.len()-3].Bytes()) > 0 {
+ gas.Add(gas, params.CallValueTransferGas)
+ }
+
+ x := calcMemSize(stack.data[stack.len()-6], stack.data[stack.len()-7])
+ y := calcMemSize(stack.data[stack.len()-4], stack.data[stack.len()-5])
+
+ newMemSize = common.BigMax(x, y)
+ }
+
+ if newMemSize.Cmp(common.Big0) > 0 {
+ newMemSizeWords := toWordSize(newMemSize)
+ newMemSize.Mul(newMemSizeWords, u256(32))
+
+ if newMemSize.Cmp(u256(int64(mem.Len()))) > 0 {
+ oldSize := toWordSize(big.NewInt(int64(mem.Len())))
+ pow := new(big.Int).Exp(oldSize, common.Big2, Zero)
+ linCoef := new(big.Int).Mul(oldSize, params.MemoryGas)
+ quadCoef := new(big.Int).Div(pow, params.QuadCoeffDiv)
+ oldTotalFee := new(big.Int).Add(linCoef, quadCoef)
+
+ pow.Exp(newMemSizeWords, common.Big2, Zero)
+ linCoef = new(big.Int).Mul(newMemSizeWords, params.MemoryGas)
+ quadCoef = new(big.Int).Div(pow, params.QuadCoeffDiv)
+ newTotalFee := new(big.Int).Add(linCoef, quadCoef)
+
+ fee := new(big.Int).Sub(newTotalFee, oldTotalFee)
+ gas.Add(gas, fee)
+ }
+ }
+
+ return newMemSize, gas, nil
+}
+
+func (self *Vm) RunPrecompiled(p *PrecompiledAccount, callData []byte, context *Context) (ret []byte, err error) {
+ gas := p.Gas(len(callData))
+ if context.UseGas(gas) {
+ ret = p.Call(callData)
+ self.Printf("NATIVE_FUNC => %x", ret)
+ self.Endl()
+
+ return context.Return(ret), nil
+ } else {
+ self.Printf("NATIVE_FUNC => failed").Endl()
+
+ tmp := new(big.Int).Set(context.Gas)
+
+ return nil, OOG(gas, tmp)
+ }
+}
+
+func (self *Vm) Printf(format string, v ...interface{}) VirtualMachine {
+ if self.debug {
+ if self.logTy == LogTyPretty {
+ self.logStr += fmt.Sprintf(format, v...)
+ }
+ }
+
+ return self
+}
+
+func (self *Vm) Endl() VirtualMachine {
+ if self.debug {
+ if self.logTy == LogTyPretty {
+ vmlogger.Infoln(self.logStr)
+ self.logStr = ""
+ }
+ }
+
+ return self
+}
+
+func (self *Vm) Env() Environment {
+ return self.env
+}
diff --git a/core/vm/vm_jit.go b/core/vm/vm_jit.go
new file mode 100644
index 000000000..991ade318
--- /dev/null
+++ b/core/vm/vm_jit.go
@@ -0,0 +1,370 @@
+// +build evmjit
+
+package vm
+
+/*
+
+void* evmjit_create();
+int evmjit_run(void* _jit, void* _data, void* _env);
+void evmjit_destroy(void* _jit);
+
+// Shared library evmjit (e.g. libevmjit.so) is expected to be installed in /usr/local/lib
+// More: https://github.com/ethereum/evmjit
+#cgo LDFLAGS: -levmjit
+*/
+import "C"
+
+import (
+ "bytes"
+ "errors"
+ "fmt"
+ "github.com/ethereum/go-ethereum/core/state"
+ "github.com/ethereum/go-ethereum/crypto"
+ "math/big"
+ "unsafe"
+)
+
+type JitVm struct {
+ env Environment
+ me ContextRef
+ callerAddr []byte
+ price *big.Int
+ data RuntimeData
+}
+
+type i256 [32]byte
+
+type RuntimeData struct {
+ gas int64
+ gasPrice int64
+ callData *byte
+ callDataSize uint64
+ address i256
+ caller i256
+ origin i256
+ callValue i256
+ coinBase i256
+ difficulty i256
+ gasLimit i256
+ number uint64
+ timestamp int64
+ code *byte
+ codeSize uint64
+ codeHash i256
+}
+
+func hash2llvm(h []byte) i256 {
+ var m i256
+ copy(m[len(m)-len(h):], h) // right aligned copy
+ return m
+}
+
+func llvm2hash(m *i256) []byte {
+ return C.GoBytes(unsafe.Pointer(m), C.int(len(m)))
+}
+
+func llvm2hashRef(m *i256) []byte {
+ return (*[1 << 30]byte)(unsafe.Pointer(m))[:len(m):len(m)]
+}
+
+func address2llvm(addr []byte) i256 {
+ n := hash2llvm(addr)
+ bswap(&n)
+ return n
+}
+
+// bswap swap bytes of the 256-bit integer on LLVM side
+// TODO: Do not change memory on LLVM side, that can conflict with memory access optimizations
+func bswap(m *i256) *i256 {
+ for i, l := 0, len(m); i < l/2; i++ {
+ m[i], m[l-i-1] = m[l-i-1], m[i]
+ }
+ return m
+}
+
+func trim(m []byte) []byte {
+ skip := 0
+ for i := 0; i < len(m); i++ {
+ if m[i] == 0 {
+ skip++
+ } else {
+ break
+ }
+ }
+ return m[skip:]
+}
+
+func getDataPtr(m []byte) *byte {
+ var p *byte
+ if len(m) > 0 {
+ p = &m[0]
+ }
+ return p
+}
+
+func big2llvm(n *big.Int) i256 {
+ m := hash2llvm(n.Bytes())
+ bswap(&m)
+ return m
+}
+
+func llvm2big(m *i256) *big.Int {
+ n := big.NewInt(0)
+ for i := 0; i < len(m); i++ {
+ b := big.NewInt(int64(m[i]))
+ b.Lsh(b, uint(i)*8)
+ n.Add(n, b)
+ }
+ return n
+}
+
+// llvm2bytesRef creates a []byte slice that references byte buffer on LLVM side (as of that not controller by GC)
+// User must asure that referenced memory is available to Go until the data is copied or not needed any more
+func llvm2bytesRef(data *byte, length uint64) []byte {
+ if length == 0 {
+ return nil
+ }
+ if data == nil {
+ panic("Unexpected nil data pointer")
+ }
+ return (*[1 << 30]byte)(unsafe.Pointer(data))[:length:length]
+}
+
+func untested(condition bool, message string) {
+ if condition {
+ panic("Condition `" + message + "` tested. Remove assert.")
+ }
+}
+
+func assert(condition bool, message string) {
+ if !condition {
+ panic("Assert `" + message + "` failed!")
+ }
+}
+
+func NewJitVm(env Environment) *JitVm {
+ return &JitVm{env: env}
+}
+
+func (self *JitVm) Run(me, caller ContextRef, code []byte, value, gas, price *big.Int, callData []byte) (ret []byte, err error) {
+ // TODO: depth is increased but never checked by VM. VM should not know about it at all.
+ self.env.SetDepth(self.env.Depth() + 1)
+
+ // TODO: Move it to Env.Call() or sth
+ if Precompiled[string(me.Address())] != nil {
+ // if it's address of precopiled contract
+ // fallback to standard VM
+ stdVm := New(self.env)
+ return stdVm.Run(me, caller, code, value, gas, price, callData)
+ }
+
+ if self.me != nil {
+ panic("JitVm.Run() can be called only once per JitVm instance")
+ }
+
+ self.me = me
+ self.callerAddr = caller.Address()
+ self.price = price
+
+ self.data.gas = gas.Int64()
+ self.data.gasPrice = price.Int64()
+ self.data.callData = getDataPtr(callData)
+ self.data.callDataSize = uint64(len(callData))
+ self.data.address = address2llvm(self.me.Address())
+ self.data.caller = address2llvm(caller.Address())
+ self.data.origin = address2llvm(self.env.Origin())
+ self.data.callValue = big2llvm(value)
+ self.data.coinBase = address2llvm(self.env.Coinbase())
+ self.data.difficulty = big2llvm(self.env.Difficulty())
+ self.data.gasLimit = big2llvm(self.env.GasLimit())
+ self.data.number = self.env.BlockNumber().Uint64()
+ self.data.timestamp = self.env.Time()
+ self.data.code = getDataPtr(code)
+ self.data.codeSize = uint64(len(code))
+ self.data.codeHash = hash2llvm(crypto.Sha3(code)) // TODO: Get already computed hash?
+
+ jit := C.evmjit_create()
+ retCode := C.evmjit_run(jit, unsafe.Pointer(&self.data), unsafe.Pointer(self))
+
+ if retCode < 0 {
+ err = errors.New("OOG from JIT")
+ gas.SetInt64(0) // Set gas to 0, JIT does not bother
+ } else {
+ gas.SetInt64(self.data.gas)
+ if retCode == 1 { // RETURN
+ ret = C.GoBytes(unsafe.Pointer(self.data.callData), C.int(self.data.callDataSize))
+ } else if retCode == 2 { // SUICIDE
+ // TODO: Suicide support logic should be moved to Env to be shared by VM implementations
+ state := self.Env().State()
+ receiverAddr := llvm2hashRef(bswap(&self.data.address))
+ receiver := state.GetOrNewStateObject(receiverAddr)
+ balance := state.GetBalance(me.Address())
+ receiver.AddBalance(balance)
+ state.Delete(me.Address())
+ }
+ }
+
+ C.evmjit_destroy(jit)
+ return
+}
+
+func (self *JitVm) Printf(format string, v ...interface{}) VirtualMachine {
+ return self
+}
+
+func (self *JitVm) Endl() VirtualMachine {
+ return self
+}
+
+func (self *JitVm) Env() Environment {
+ return self.env
+}
+
+//export env_sha3
+func env_sha3(dataPtr *byte, length uint64, resultPtr unsafe.Pointer) {
+ data := llvm2bytesRef(dataPtr, length)
+ hash := crypto.Sha3(data)
+ result := (*i256)(resultPtr)
+ *result = hash2llvm(hash)
+}
+
+//export env_sstore
+func env_sstore(vmPtr unsafe.Pointer, indexPtr unsafe.Pointer, valuePtr unsafe.Pointer) {
+ vm := (*JitVm)(vmPtr)
+ index := llvm2hash(bswap((*i256)(indexPtr)))
+ value := llvm2hash(bswap((*i256)(valuePtr)))
+ value = trim(value)
+ if len(value) == 0 {
+ prevValue := vm.env.State().GetState(vm.me.Address(), index)
+ if len(prevValue) != 0 {
+ vm.Env().State().Refund(vm.callerAddr, GasSStoreRefund)
+ }
+ }
+
+ vm.env.State().SetState(vm.me.Address(), index, value)
+}
+
+//export env_sload
+func env_sload(vmPtr unsafe.Pointer, indexPtr unsafe.Pointer, resultPtr unsafe.Pointer) {
+ vm := (*JitVm)(vmPtr)
+ index := llvm2hash(bswap((*i256)(indexPtr)))
+ value := vm.env.State().GetState(vm.me.Address(), index)
+ result := (*i256)(resultPtr)
+ *result = hash2llvm(value)
+ bswap(result)
+}
+
+//export env_balance
+func env_balance(_vm unsafe.Pointer, _addr unsafe.Pointer, _result unsafe.Pointer) {
+ vm := (*JitVm)(_vm)
+ addr := llvm2hash((*i256)(_addr))
+ balance := vm.Env().State().GetBalance(addr)
+ result := (*i256)(_result)
+ *result = big2llvm(balance)
+}
+
+//export env_blockhash
+func env_blockhash(_vm unsafe.Pointer, _number unsafe.Pointer, _result unsafe.Pointer) {
+ vm := (*JitVm)(_vm)
+ number := llvm2big((*i256)(_number))
+ result := (*i256)(_result)
+
+ currNumber := vm.Env().BlockNumber()
+ limit := big.NewInt(0).Sub(currNumber, big.NewInt(256))
+ if number.Cmp(limit) >= 0 && number.Cmp(currNumber) < 0 {
+ hash := vm.Env().GetHash(uint64(number.Int64()))
+ *result = hash2llvm(hash)
+ } else {
+ *result = i256{}
+ }
+}
+
+//export env_call
+func env_call(_vm unsafe.Pointer, _gas *int64, _receiveAddr unsafe.Pointer, _value unsafe.Pointer, inDataPtr unsafe.Pointer, inDataLen uint64, outDataPtr *byte, outDataLen uint64, _codeAddr unsafe.Pointer) bool {
+ vm := (*JitVm)(_vm)
+
+ //fmt.Printf("env_call (depth %d)\n", vm.Env().Depth())
+
+ defer func() {
+ if r := recover(); r != nil {
+ fmt.Printf("Recovered in env_call (depth %d, out %p %d): %s\n", vm.Env().Depth(), outDataPtr, outDataLen, r)
+ }
+ }()
+
+ balance := vm.Env().State().GetBalance(vm.me.Address())
+ value := llvm2big((*i256)(_value))
+
+ if balance.Cmp(value) >= 0 {
+ receiveAddr := llvm2hash((*i256)(_receiveAddr))
+ inData := C.GoBytes(inDataPtr, C.int(inDataLen))
+ outData := llvm2bytesRef(outDataPtr, outDataLen)
+ codeAddr := llvm2hash((*i256)(_codeAddr))
+ gas := big.NewInt(*_gas)
+ var out []byte
+ var err error
+ if bytes.Equal(codeAddr, receiveAddr) {
+ out, err = vm.env.Call(vm.me, codeAddr, inData, gas, vm.price, value)
+ } else {
+ out, err = vm.env.CallCode(vm.me, codeAddr, inData, gas, vm.price, value)
+ }
+ *_gas = gas.Int64()
+ if err == nil {
+ copy(outData, out)
+ return true
+ }
+ }
+
+ return false
+}
+
+//export env_create
+func env_create(_vm unsafe.Pointer, _gas *int64, _value unsafe.Pointer, initDataPtr unsafe.Pointer, initDataLen uint64, _result unsafe.Pointer) {
+ vm := (*JitVm)(_vm)
+
+ value := llvm2big((*i256)(_value))
+ initData := C.GoBytes(initDataPtr, C.int(initDataLen)) // TODO: Unnecessary if low balance
+ result := (*i256)(_result)
+ *result = i256{}
+
+ gas := big.NewInt(*_gas)
+ ret, suberr, ref := vm.env.Create(vm.me, nil, initData, gas, vm.price, value)
+ if suberr == nil {
+ dataGas := big.NewInt(int64(len(ret))) // TODO: Nto the best design. env.Create can do it, it has the reference to gas counter
+ dataGas.Mul(dataGas, params.CreateDataGas)
+ gas.Sub(gas, dataGas)
+ *result = hash2llvm(ref.Address())
+ }
+ *_gas = gas.Int64()
+}
+
+//export env_log
+func env_log(_vm unsafe.Pointer, dataPtr unsafe.Pointer, dataLen uint64, _topic1 unsafe.Pointer, _topic2 unsafe.Pointer, _topic3 unsafe.Pointer, _topic4 unsafe.Pointer) {
+ vm := (*JitVm)(_vm)
+
+ data := C.GoBytes(dataPtr, C.int(dataLen))
+
+ topics := make([][]byte, 0, 4)
+ if _topic1 != nil {
+ topics = append(topics, llvm2hash((*i256)(_topic1)))
+ }
+ if _topic2 != nil {
+ topics = append(topics, llvm2hash((*i256)(_topic2)))
+ }
+ if _topic3 != nil {
+ topics = append(topics, llvm2hash((*i256)(_topic3)))
+ }
+ if _topic4 != nil {
+ topics = append(topics, llvm2hash((*i256)(_topic4)))
+ }
+
+ vm.Env().AddLog(state.NewLog(vm.me.Address(), topics, data, vm.env.BlockNumber().Uint64()))
+}
+
+//export env_extcode
+func env_extcode(_vm unsafe.Pointer, _addr unsafe.Pointer, o_size *uint64) *byte {
+ vm := (*JitVm)(_vm)
+ addr := llvm2hash((*i256)(_addr))
+ code := vm.Env().State().GetCode(addr)
+ *o_size = uint64(len(code))
+ return getDataPtr(code)
+}
diff --git a/core/vm/vm_jit_fake.go b/core/vm/vm_jit_fake.go
new file mode 100644
index 000000000..d6b5be45b
--- /dev/null
+++ b/core/vm/vm_jit_fake.go
@@ -0,0 +1,10 @@
+// +build !evmjit
+
+package vm
+
+import "fmt"
+
+func NewJitVm(env Environment) VirtualMachine {
+ fmt.Printf("Warning! EVM JIT not enabled.\n")
+ return New(env)
+}
diff --git a/core/vm/vm_test.go b/core/vm/vm_test.go
new file mode 100644
index 000000000..9bd147a72
--- /dev/null
+++ b/core/vm/vm_test.go
@@ -0,0 +1,3 @@
+package vm
+
+// Tests have been removed in favour of general tests. If anything implementation specific needs testing, put it here
diff --git a/core/vm_env.go b/core/vm_env.go
new file mode 100644
index 000000000..6a604fccd
--- /dev/null
+++ b/core/vm_env.go
@@ -0,0 +1,70 @@
+package core
+
+import (
+ "math/big"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/core/state"
+ "github.com/ethereum/go-ethereum/core/types"
+ "github.com/ethereum/go-ethereum/core/vm"
+)
+
+type VMEnv struct {
+ state *state.StateDB
+ block *types.Block
+ msg Message
+ depth int
+ chain *ChainManager
+ typ vm.Type
+}
+
+func NewEnv(state *state.StateDB, chain *ChainManager, msg Message, block *types.Block) *VMEnv {
+ return &VMEnv{
+ chain: chain,
+ state: state,
+ block: block,
+ msg: msg,
+ typ: vm.StdVmTy,
+ }
+}
+
+func (self *VMEnv) Origin() common.Address { f, _ := self.msg.From(); return f }
+func (self *VMEnv) BlockNumber() *big.Int { return self.block.Number() }
+func (self *VMEnv) Coinbase() common.Address { return self.block.Coinbase() }
+func (self *VMEnv) Time() int64 { return self.block.Time() }
+func (self *VMEnv) Difficulty() *big.Int { return self.block.Difficulty() }
+func (self *VMEnv) GasLimit() *big.Int { return self.block.GasLimit() }
+func (self *VMEnv) Value() *big.Int { return self.msg.Value() }
+func (self *VMEnv) State() *state.StateDB { return self.state }
+func (self *VMEnv) Depth() int { return self.depth }
+func (self *VMEnv) SetDepth(i int) { self.depth = i }
+func (self *VMEnv) VmType() vm.Type { return self.typ }
+func (self *VMEnv) SetVmType(t vm.Type) { self.typ = t }
+func (self *VMEnv) GetHash(n uint64) common.Hash {
+ if block := self.chain.GetBlockByNumber(n); block != nil {
+ return block.Hash()
+ }
+
+ return common.Hash{}
+}
+func (self *VMEnv) AddLog(log state.Log) {
+ self.state.AddLog(log)
+}
+func (self *VMEnv) Transfer(from, to vm.Account, amount *big.Int) error {
+ return vm.Transfer(from, to, amount)
+}
+
+func (self *VMEnv) Call(me vm.ContextRef, addr common.Address, data []byte, gas, price, value *big.Int) ([]byte, error) {
+ exe := NewExecution(self, &addr, data, gas, price, value)
+ return exe.Call(addr, me)
+}
+func (self *VMEnv) CallCode(me vm.ContextRef, addr common.Address, data []byte, gas, price, value *big.Int) ([]byte, error) {
+ maddr := me.Address()
+ exe := NewExecution(self, &maddr, data, gas, price, value)
+ return exe.Call(addr, me)
+}
+
+func (self *VMEnv) Create(me vm.ContextRef, data []byte, gas, price, value *big.Int) ([]byte, error, vm.ContextRef) {
+ exe := NewExecution(self, nil, data, gas, price, value)
+ return exe.Create(me)
+}
diff --git a/crypto/crypto.go b/crypto/crypto.go
new file mode 100644
index 000000000..9a1559fbf
--- /dev/null
+++ b/crypto/crypto.go
@@ -0,0 +1,276 @@
+package crypto
+
+import (
+ "crypto/aes"
+ "crypto/cipher"
+ "crypto/ecdsa"
+ "crypto/elliptic"
+ "crypto/rand"
+ "crypto/sha256"
+ "fmt"
+ "io"
+ "io/ioutil"
+ "os"
+
+ "encoding/hex"
+ "encoding/json"
+ "errors"
+
+ "code.google.com/p/go-uuid/uuid"
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/crypto/ecies"
+ "github.com/ethereum/go-ethereum/crypto/secp256k1"
+ "github.com/ethereum/go-ethereum/crypto/sha3"
+ "github.com/ethereum/go-ethereum/rlp"
+ "golang.org/x/crypto/pbkdf2"
+ "golang.org/x/crypto/ripemd160"
+)
+
+func init() {
+ // specify the params for the s256 curve
+ ecies.AddParamsForCurve(S256(), ecies.ECIES_AES128_SHA256)
+}
+
+func Sha3(data ...[]byte) []byte {
+ d := sha3.NewKeccak256()
+ for _, b := range data {
+ d.Write(b)
+ }
+ return d.Sum(nil)
+}
+
+func Sha3Hash(data ...[]byte) (h common.Hash) {
+ d := sha3.NewKeccak256()
+ for _, b := range data {
+ d.Write(b)
+ }
+ d.Sum(h[:0])
+ return h
+}
+
+// Creates an ethereum address given the bytes and the nonce
+func CreateAddress(b common.Address, nonce uint64) common.Address {
+ data, _ := rlp.EncodeToBytes([]interface{}{b, nonce})
+ return common.BytesToAddress(Sha3(data)[12:])
+ //return Sha3(common.NewValue([]interface{}{b, nonce}).Encode())[12:]
+}
+
+func Sha256(data []byte) []byte {
+ hash := sha256.Sum256(data)
+
+ return hash[:]
+}
+
+func Ripemd160(data []byte) []byte {
+ ripemd := ripemd160.New()
+ ripemd.Write(data)
+
+ return ripemd.Sum(nil)
+}
+
+func Ecrecover(hash, sig []byte) []byte {
+ r, _ := secp256k1.RecoverPubkey(hash, sig)
+
+ return r
+}
+
+// New methods using proper ecdsa keys from the stdlib
+func ToECDSA(prv []byte) *ecdsa.PrivateKey {
+ if len(prv) == 0 {
+ return nil
+ }
+
+ priv := new(ecdsa.PrivateKey)
+ priv.PublicKey.Curve = S256()
+ priv.D = common.BigD(prv)
+ priv.PublicKey.X, priv.PublicKey.Y = S256().ScalarBaseMult(prv)
+ return priv
+}
+
+func FromECDSA(prv *ecdsa.PrivateKey) []byte {
+ if prv == nil {
+ return nil
+ }
+ return prv.D.Bytes()
+}
+
+func ToECDSAPub(pub []byte) *ecdsa.PublicKey {
+ if len(pub) == 0 {
+ return nil
+ }
+ x, y := elliptic.Unmarshal(S256(), pub)
+ return &ecdsa.PublicKey{S256(), x, y}
+}
+
+func FromECDSAPub(pub *ecdsa.PublicKey) []byte {
+ if pub == nil || pub.X == nil || pub.Y == nil {
+ return nil
+ }
+ return elliptic.Marshal(S256(), pub.X, pub.Y)
+}
+
+// HexToECDSA parses a secp256k1 private key.
+func HexToECDSA(hexkey string) (*ecdsa.PrivateKey, error) {
+ b, err := hex.DecodeString(hexkey)
+ if err != nil {
+ return nil, errors.New("invalid hex string")
+ }
+ if len(b) != 32 {
+ return nil, errors.New("invalid length, need 256 bits")
+ }
+ return ToECDSA(b), nil
+}
+
+// LoadECDSA loads a secp256k1 private key from the given file.
+func LoadECDSA(file string) (*ecdsa.PrivateKey, error) {
+ buf := make([]byte, 32)
+ fd, err := os.Open(file)
+ if err != nil {
+ return nil, err
+ }
+ defer fd.Close()
+ if _, err := io.ReadFull(fd, buf); err != nil {
+ return nil, err
+ }
+ return ToECDSA(buf), nil
+}
+
+// SaveECDSA saves a secp256k1 private key to the given file with restrictive
+// permissions
+func SaveECDSA(file string, key *ecdsa.PrivateKey) error {
+ return ioutil.WriteFile(file, FromECDSA(key), 0600)
+}
+
+func GenerateKey() (*ecdsa.PrivateKey, error) {
+ return ecdsa.GenerateKey(S256(), rand.Reader)
+}
+
+func SigToPub(hash, sig []byte) *ecdsa.PublicKey {
+ s := Ecrecover(hash, sig)
+ if s == nil || len(s) != 65 {
+ return nil
+ }
+
+ x, y := elliptic.Unmarshal(S256(), s)
+ return &ecdsa.PublicKey{S256(), x, y}
+}
+
+func Sign(hash []byte, prv *ecdsa.PrivateKey) (sig []byte, err error) {
+ if len(hash) != 32 {
+ return nil, fmt.Errorf("hash is required to be exactly 32 bytes (%d)", len(hash))
+ }
+
+ sig, err = secp256k1.Sign(hash, common.LeftPadBytes(prv.D.Bytes(), prv.Params().BitSize/8))
+ return
+}
+
+func Encrypt(pub *ecdsa.PublicKey, message []byte) ([]byte, error) {
+ return ecies.Encrypt(rand.Reader, ecies.ImportECDSAPublic(pub), message, nil, nil)
+}
+
+func Decrypt(prv *ecdsa.PrivateKey, ct []byte) ([]byte, error) {
+ key := ecies.ImportECDSA(prv)
+ return key.Decrypt(rand.Reader, ct, nil, nil)
+}
+
+// creates a Key and stores that in the given KeyStore by decrypting a presale key JSON
+func ImportPreSaleKey(keyStore KeyStore2, keyJSON []byte, password string) (*Key, error) {
+ key, err := decryptPreSaleKey(keyJSON, password)
+ if err != nil {
+ return nil, err
+ }
+ key.Id = uuid.NewRandom()
+ err = keyStore.StoreKey(key, password)
+ return key, err
+}
+
+func decryptPreSaleKey(fileContent []byte, password string) (key *Key, err error) {
+ preSaleKeyStruct := struct {
+ EncSeed string
+ EthAddr string
+ Email string
+ BtcAddr string
+ }{}
+ err = json.Unmarshal(fileContent, &preSaleKeyStruct)
+ if err != nil {
+ return nil, err
+ }
+ encSeedBytes, err := hex.DecodeString(preSaleKeyStruct.EncSeed)
+ iv := encSeedBytes[:16]
+ cipherText := encSeedBytes[16:]
+ /*
+ See https://github.com/ethereum/pyethsaletool
+
+ pyethsaletool generates the encryption key from password by
+ 2000 rounds of PBKDF2 with HMAC-SHA-256 using password as salt (:().
+ 16 byte key length within PBKDF2 and resulting key is used as AES key
+ */
+ passBytes := []byte(password)
+ derivedKey := pbkdf2.Key(passBytes, passBytes, 2000, 16, sha256.New)
+ plainText, err := aesCBCDecrypt(derivedKey, cipherText, iv)
+ ethPriv := Sha3(plainText)
+ ecKey := ToECDSA(ethPriv)
+ key = &Key{
+ Id: nil,
+ Address: PubkeyToAddress(ecKey.PublicKey),
+ PrivateKey: ecKey,
+ }
+ derivedAddr := common.Bytes2Hex(key.Address)
+ expectedAddr := preSaleKeyStruct.EthAddr
+ if derivedAddr != expectedAddr {
+ err = errors.New("decrypted addr not equal to expected addr")
+ }
+ return key, err
+}
+
+func aesCBCDecrypt(key []byte, cipherText []byte, iv []byte) (plainText []byte, err error) {
+ aesBlock, err := aes.NewCipher(key)
+ if err != nil {
+ return plainText, err
+ }
+ decrypter := cipher.NewCBCDecrypter(aesBlock, iv)
+ paddedPlainText := make([]byte, len(cipherText))
+ decrypter.CryptBlocks(paddedPlainText, cipherText)
+ plainText = PKCS7Unpad(paddedPlainText)
+ if plainText == nil {
+ err = errors.New("Decryption failed: PKCS7Unpad failed after decryption")
+ }
+ return plainText, err
+}
+
+// From https://leanpub.com/gocrypto/read#leanpub-auto-block-cipher-modes
+func PKCS7Pad(in []byte) []byte {
+ padding := 16 - (len(in) % 16)
+ if padding == 0 {
+ padding = 16
+ }
+ for i := 0; i < padding; i++ {
+ in = append(in, byte(padding))
+ }
+ return in
+}
+
+func PKCS7Unpad(in []byte) []byte {
+ if len(in) == 0 {
+ return nil
+ }
+
+ padding := in[len(in)-1]
+ if int(padding) > len(in) || padding > aes.BlockSize {
+ return nil
+ } else if padding == 0 {
+ return nil
+ }
+
+ for i := len(in) - 1; i > len(in)-int(padding)-1; i-- {
+ if in[i] != padding {
+ return nil
+ }
+ }
+ return in[:len(in)-int(padding)]
+}
+
+func PubkeyToAddress(p ecdsa.PublicKey) []byte {
+ pubBytes := FromECDSAPub(&p)
+ return Sha3(pubBytes[1:])[12:]
+}
diff --git a/crypto/crypto_test.go b/crypto/crypto_test.go
new file mode 100644
index 000000000..63a9c3f5e
--- /dev/null
+++ b/crypto/crypto_test.go
@@ -0,0 +1,80 @@
+package crypto
+
+import (
+ "bytes"
+ "encoding/hex"
+ "fmt"
+ "testing"
+ "time"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/crypto/secp256k1"
+)
+
+// These tests are sanity checks.
+// They should ensure that we don't e.g. use Sha3-224 instead of Sha3-256
+// and that the sha3 library uses keccak-f permutation.
+
+func TestSha3(t *testing.T) {
+ msg := []byte("abc")
+ exp, _ := hex.DecodeString("4e03657aea45a94fc7d47ba826c8d667c0d1e6e33a64a036ec44f58fa12d6c45")
+ checkhash(t, "Sha3-256", func(in []byte) []byte { return Sha3(in) }, msg, exp)
+}
+
+func TestSha3Hash(t *testing.T) {
+ msg := []byte("abc")
+ exp, _ := hex.DecodeString("4e03657aea45a94fc7d47ba826c8d667c0d1e6e33a64a036ec44f58fa12d6c45")
+ checkhash(t, "Sha3-256-array", func(in []byte) []byte { h := Sha3Hash(in); return h[:] }, msg, exp)
+}
+
+func TestSha256(t *testing.T) {
+ msg := []byte("abc")
+ exp, _ := hex.DecodeString("ba7816bf8f01cfea414140de5dae2223b00361a396177a9cb410ff61f20015ad")
+ checkhash(t, "Sha256", Sha256, msg, exp)
+}
+
+func TestRipemd160(t *testing.T) {
+ msg := []byte("abc")
+ exp, _ := hex.DecodeString("8eb208f7e05d987a9b044a8e98c6b087f15a0bfc")
+ checkhash(t, "Ripemd160", Ripemd160, msg, exp)
+}
+
+func checkhash(t *testing.T, name string, f func([]byte) []byte, msg, exp []byte) {
+ sum := f(msg)
+ if bytes.Compare(exp, sum) != 0 {
+ t.Errorf("hash %s returned wrong result.\ngot: %x\nwant: %x", name, sum, exp)
+ }
+}
+
+func BenchmarkSha3(b *testing.B) {
+ a := []byte("hello world")
+ amount := 1000000
+ start := time.Now()
+ for i := 0; i < amount; i++ {
+ Sha3(a)
+ }
+
+ fmt.Println(amount, ":", time.Since(start))
+}
+
+func Test0Key(t *testing.T) {
+ t.Skip()
+ key := common.Hex2Bytes("1111111111111111111111111111111111111111111111111111111111111111")
+
+ p, err := secp256k1.GeneratePubKey(key)
+ addr := Sha3(p[1:])[12:]
+ fmt.Printf("%x\n", p)
+ fmt.Printf("%v %x\n", err, addr)
+}
+
+func TestInvalidSign(t *testing.T) {
+ _, err := Sign(make([]byte, 1), nil)
+ if err == nil {
+ t.Errorf("expected sign with hash 1 byte to error")
+ }
+
+ _, err = Sign(make([]byte, 33), nil)
+ if err == nil {
+ t.Errorf("expected sign with hash 33 byte to error")
+ }
+}
diff --git a/crypto/curve.go b/crypto/curve.go
new file mode 100644
index 000000000..131a0dd2f
--- /dev/null
+++ b/crypto/curve.go
@@ -0,0 +1,363 @@
+package crypto
+
+// Copyright 2010 The Go Authors. All rights reserved.
+// Copyright 2011 ThePiachu. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Package bitelliptic implements several Koblitz elliptic curves over prime
+// fields.
+
+// This package operates, internally, on Jacobian coordinates. For a given
+// (x, y) position on the curve, the Jacobian coordinates are (x1, y1, z1)
+// where x = x1/z1² and y = y1/z1³. The greatest speedups come when the whole
+// calculation can be performed within the transform (as in ScalarMult and
+// ScalarBaseMult). But even for Add and Double, it's faster to apply and
+// reverse the transform than to operate in affine coordinates.
+
+import (
+ "crypto/elliptic"
+ "io"
+ "math/big"
+ "sync"
+)
+
+// A BitCurve represents a Koblitz Curve with a=0.
+// See http://www.hyperelliptic.org/EFD/g1p/auto-shortw.html
+type BitCurve struct {
+ P *big.Int // the order of the underlying field
+ N *big.Int // the order of the base point
+ B *big.Int // the constant of the BitCurve equation
+ Gx, Gy *big.Int // (x,y) of the base point
+ BitSize int // the size of the underlying field
+}
+
+func (BitCurve *BitCurve) Params() *elliptic.CurveParams {
+ return &elliptic.CurveParams{BitCurve.P, BitCurve.N, BitCurve.B, BitCurve.Gx, BitCurve.Gy, BitCurve.BitSize}
+}
+
+// IsOnBitCurve returns true if the given (x,y) lies on the BitCurve.
+func (BitCurve *BitCurve) IsOnCurve(x, y *big.Int) bool {
+ // y² = x³ + b
+ y2 := new(big.Int).Mul(y, y) //y²
+ y2.Mod(y2, BitCurve.P) //y²%P
+
+ x3 := new(big.Int).Mul(x, x) //x²
+ x3.Mul(x3, x) //x³
+
+ x3.Add(x3, BitCurve.B) //x³+B
+ x3.Mod(x3, BitCurve.P) //(x³+B)%P
+
+ return x3.Cmp(y2) == 0
+}
+
+//TODO: double check if the function is okay
+// affineFromJacobian reverses the Jacobian transform. See the comment at the
+// top of the file.
+func (BitCurve *BitCurve) affineFromJacobian(x, y, z *big.Int) (xOut, yOut *big.Int) {
+ zinv := new(big.Int).ModInverse(z, BitCurve.P)
+ zinvsq := new(big.Int).Mul(zinv, zinv)
+
+ xOut = new(big.Int).Mul(x, zinvsq)
+ xOut.Mod(xOut, BitCurve.P)
+ zinvsq.Mul(zinvsq, zinv)
+ yOut = new(big.Int).Mul(y, zinvsq)
+ yOut.Mod(yOut, BitCurve.P)
+ return
+}
+
+// Add returns the sum of (x1,y1) and (x2,y2)
+func (BitCurve *BitCurve) Add(x1, y1, x2, y2 *big.Int) (*big.Int, *big.Int) {
+ z := new(big.Int).SetInt64(1)
+ return BitCurve.affineFromJacobian(BitCurve.addJacobian(x1, y1, z, x2, y2, z))
+}
+
+// addJacobian takes two points in Jacobian coordinates, (x1, y1, z1) and
+// (x2, y2, z2) and returns their sum, also in Jacobian form.
+func (BitCurve *BitCurve) addJacobian(x1, y1, z1, x2, y2, z2 *big.Int) (*big.Int, *big.Int, *big.Int) {
+ // See http://hyperelliptic.org/EFD/g1p/auto-shortw-jacobian-0.html#addition-add-2007-bl
+ z1z1 := new(big.Int).Mul(z1, z1)
+ z1z1.Mod(z1z1, BitCurve.P)
+ z2z2 := new(big.Int).Mul(z2, z2)
+ z2z2.Mod(z2z2, BitCurve.P)
+
+ u1 := new(big.Int).Mul(x1, z2z2)
+ u1.Mod(u1, BitCurve.P)
+ u2 := new(big.Int).Mul(x2, z1z1)
+ u2.Mod(u2, BitCurve.P)
+ h := new(big.Int).Sub(u2, u1)
+ if h.Sign() == -1 {
+ h.Add(h, BitCurve.P)
+ }
+ i := new(big.Int).Lsh(h, 1)
+ i.Mul(i, i)
+ j := new(big.Int).Mul(h, i)
+
+ s1 := new(big.Int).Mul(y1, z2)
+ s1.Mul(s1, z2z2)
+ s1.Mod(s1, BitCurve.P)
+ s2 := new(big.Int).Mul(y2, z1)
+ s2.Mul(s2, z1z1)
+ s2.Mod(s2, BitCurve.P)
+ r := new(big.Int).Sub(s2, s1)
+ if r.Sign() == -1 {
+ r.Add(r, BitCurve.P)
+ }
+ r.Lsh(r, 1)
+ v := new(big.Int).Mul(u1, i)
+
+ x3 := new(big.Int).Set(r)
+ x3.Mul(x3, x3)
+ x3.Sub(x3, j)
+ x3.Sub(x3, v)
+ x3.Sub(x3, v)
+ x3.Mod(x3, BitCurve.P)
+
+ y3 := new(big.Int).Set(r)
+ v.Sub(v, x3)
+ y3.Mul(y3, v)
+ s1.Mul(s1, j)
+ s1.Lsh(s1, 1)
+ y3.Sub(y3, s1)
+ y3.Mod(y3, BitCurve.P)
+
+ z3 := new(big.Int).Add(z1, z2)
+ z3.Mul(z3, z3)
+ z3.Sub(z3, z1z1)
+ if z3.Sign() == -1 {
+ z3.Add(z3, BitCurve.P)
+ }
+ z3.Sub(z3, z2z2)
+ if z3.Sign() == -1 {
+ z3.Add(z3, BitCurve.P)
+ }
+ z3.Mul(z3, h)
+ z3.Mod(z3, BitCurve.P)
+
+ return x3, y3, z3
+}
+
+// Double returns 2*(x,y)
+func (BitCurve *BitCurve) Double(x1, y1 *big.Int) (*big.Int, *big.Int) {
+ z1 := new(big.Int).SetInt64(1)
+ return BitCurve.affineFromJacobian(BitCurve.doubleJacobian(x1, y1, z1))
+}
+
+// doubleJacobian takes a point in Jacobian coordinates, (x, y, z), and
+// returns its double, also in Jacobian form.
+func (BitCurve *BitCurve) doubleJacobian(x, y, z *big.Int) (*big.Int, *big.Int, *big.Int) {
+ // See http://hyperelliptic.org/EFD/g1p/auto-shortw-jacobian-0.html#doubling-dbl-2009-l
+
+ a := new(big.Int).Mul(x, x) //X1²
+ b := new(big.Int).Mul(y, y) //Y1²
+ c := new(big.Int).Mul(b, b) //B²
+
+ d := new(big.Int).Add(x, b) //X1+B
+ d.Mul(d, d) //(X1+B)²
+ d.Sub(d, a) //(X1+B)²-A
+ d.Sub(d, c) //(X1+B)²-A-C
+ d.Mul(d, big.NewInt(2)) //2*((X1+B)²-A-C)
+
+ e := new(big.Int).Mul(big.NewInt(3), a) //3*A
+ f := new(big.Int).Mul(e, e) //E²
+
+ x3 := new(big.Int).Mul(big.NewInt(2), d) //2*D
+ x3.Sub(f, x3) //F-2*D
+ x3.Mod(x3, BitCurve.P)
+
+ y3 := new(big.Int).Sub(d, x3) //D-X3
+ y3.Mul(e, y3) //E*(D-X3)
+ y3.Sub(y3, new(big.Int).Mul(big.NewInt(8), c)) //E*(D-X3)-8*C
+ y3.Mod(y3, BitCurve.P)
+
+ z3 := new(big.Int).Mul(y, z) //Y1*Z1
+ z3.Mul(big.NewInt(2), z3) //3*Y1*Z1
+ z3.Mod(z3, BitCurve.P)
+
+ return x3, y3, z3
+}
+
+//TODO: double check if it is okay
+// ScalarMult returns k*(Bx,By) where k is a number in big-endian form.
+func (BitCurve *BitCurve) ScalarMult(Bx, By *big.Int, k []byte) (*big.Int, *big.Int) {
+ // We have a slight problem in that the identity of the group (the
+ // point at infinity) cannot be represented in (x, y) form on a finite
+ // machine. Thus the standard add/double algorithm has to be tweaked
+ // slightly: our initial state is not the identity, but x, and we
+ // ignore the first true bit in |k|. If we don't find any true bits in
+ // |k|, then we return nil, nil, because we cannot return the identity
+ // element.
+
+ Bz := new(big.Int).SetInt64(1)
+ x := Bx
+ y := By
+ z := Bz
+
+ seenFirstTrue := false
+ for _, byte := range k {
+ for bitNum := 0; bitNum < 8; bitNum++ {
+ if seenFirstTrue {
+ x, y, z = BitCurve.doubleJacobian(x, y, z)
+ }
+ if byte&0x80 == 0x80 {
+ if !seenFirstTrue {
+ seenFirstTrue = true
+ } else {
+ x, y, z = BitCurve.addJacobian(Bx, By, Bz, x, y, z)
+ }
+ }
+ byte <<= 1
+ }
+ }
+
+ if !seenFirstTrue {
+ return nil, nil
+ }
+
+ return BitCurve.affineFromJacobian(x, y, z)
+}
+
+// ScalarBaseMult returns k*G, where G is the base point of the group and k is
+// an integer in big-endian form.
+func (BitCurve *BitCurve) ScalarBaseMult(k []byte) (*big.Int, *big.Int) {
+ return BitCurve.ScalarMult(BitCurve.Gx, BitCurve.Gy, k)
+}
+
+var mask = []byte{0xff, 0x1, 0x3, 0x7, 0xf, 0x1f, 0x3f, 0x7f}
+
+//TODO: double check if it is okay
+// GenerateKey returns a public/private key pair. The private key is generated
+// using the given reader, which must return random data.
+func (BitCurve *BitCurve) GenerateKey(rand io.Reader) (priv []byte, x, y *big.Int, err error) {
+ byteLen := (BitCurve.BitSize + 7) >> 3
+ priv = make([]byte, byteLen)
+
+ for x == nil {
+ _, err = io.ReadFull(rand, priv)
+ if err != nil {
+ return
+ }
+ // We have to mask off any excess bits in the case that the size of the
+ // underlying field is not a whole number of bytes.
+ priv[0] &= mask[BitCurve.BitSize%8]
+ // This is because, in tests, rand will return all zeros and we don't
+ // want to get the point at infinity and loop forever.
+ priv[1] ^= 0x42
+ x, y = BitCurve.ScalarBaseMult(priv)
+ }
+ return
+}
+
+// Marshal converts a point into the form specified in section 4.3.6 of ANSI
+// X9.62.
+func (BitCurve *BitCurve) Marshal(x, y *big.Int) []byte {
+ byteLen := (BitCurve.BitSize + 7) >> 3
+
+ ret := make([]byte, 1+2*byteLen)
+ ret[0] = 4 // uncompressed point
+
+ xBytes := x.Bytes()
+ copy(ret[1+byteLen-len(xBytes):], xBytes)
+ yBytes := y.Bytes()
+ copy(ret[1+2*byteLen-len(yBytes):], yBytes)
+ return ret
+}
+
+// Unmarshal converts a point, serialised by Marshal, into an x, y pair. On
+// error, x = nil.
+func (BitCurve *BitCurve) Unmarshal(data []byte) (x, y *big.Int) {
+ byteLen := (BitCurve.BitSize + 7) >> 3
+ if len(data) != 1+2*byteLen {
+ return
+ }
+ if data[0] != 4 { // uncompressed form
+ return
+ }
+ x = new(big.Int).SetBytes(data[1 : 1+byteLen])
+ y = new(big.Int).SetBytes(data[1+byteLen:])
+ return
+}
+
+//curve parameters taken from:
+//http://www.secg.org/collateral/sec2_final.pdf
+
+var initonce sync.Once
+var ecp160k1 *BitCurve
+var ecp192k1 *BitCurve
+var ecp224k1 *BitCurve
+var ecp256k1 *BitCurve
+
+func initAll() {
+ initS160()
+ initS192()
+ initS224()
+ initS256()
+}
+
+func initS160() {
+ // See SEC 2 section 2.4.1
+ ecp160k1 = new(BitCurve)
+ ecp160k1.P, _ = new(big.Int).SetString("FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEFFFFAC73", 16)
+ ecp160k1.N, _ = new(big.Int).SetString("0100000000000000000001B8FA16DFAB9ACA16B6B3", 16)
+ ecp160k1.B, _ = new(big.Int).SetString("0000000000000000000000000000000000000007", 16)
+ ecp160k1.Gx, _ = new(big.Int).SetString("3B4C382CE37AA192A4019E763036F4F5DD4D7EBB", 16)
+ ecp160k1.Gy, _ = new(big.Int).SetString("938CF935318FDCED6BC28286531733C3F03C4FEE", 16)
+ ecp160k1.BitSize = 160
+}
+
+func initS192() {
+ // See SEC 2 section 2.5.1
+ ecp192k1 = new(BitCurve)
+ ecp192k1.P, _ = new(big.Int).SetString("FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEFFFFEE37", 16)
+ ecp192k1.N, _ = new(big.Int).SetString("FFFFFFFFFFFFFFFFFFFFFFFE26F2FC170F69466A74DEFD8D", 16)
+ ecp192k1.B, _ = new(big.Int).SetString("000000000000000000000000000000000000000000000003", 16)
+ ecp192k1.Gx, _ = new(big.Int).SetString("DB4FF10EC057E9AE26B07D0280B7F4341DA5D1B1EAE06C7D", 16)
+ ecp192k1.Gy, _ = new(big.Int).SetString("9B2F2F6D9C5628A7844163D015BE86344082AA88D95E2F9D", 16)
+ ecp192k1.BitSize = 192
+}
+
+func initS224() {
+ // See SEC 2 section 2.6.1
+ ecp224k1 = new(BitCurve)
+ ecp224k1.P, _ = new(big.Int).SetString("FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEFFFFE56D", 16)
+ ecp224k1.N, _ = new(big.Int).SetString("010000000000000000000000000001DCE8D2EC6184CAF0A971769FB1F7", 16)
+ ecp224k1.B, _ = new(big.Int).SetString("00000000000000000000000000000000000000000000000000000005", 16)
+ ecp224k1.Gx, _ = new(big.Int).SetString("A1455B334DF099DF30FC28A169A467E9E47075A90F7E650EB6B7A45C", 16)
+ ecp224k1.Gy, _ = new(big.Int).SetString("7E089FED7FBA344282CAFBD6F7E319F7C0B0BD59E2CA4BDB556D61A5", 16)
+ ecp224k1.BitSize = 224
+}
+
+func initS256() {
+ // See SEC 2 section 2.7.1
+ ecp256k1 = new(BitCurve)
+ ecp256k1.P, _ = new(big.Int).SetString("FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEFFFFFC2F", 16)
+ ecp256k1.N, _ = new(big.Int).SetString("FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEBAAEDCE6AF48A03BBFD25E8CD0364141", 16)
+ ecp256k1.B, _ = new(big.Int).SetString("0000000000000000000000000000000000000000000000000000000000000007", 16)
+ ecp256k1.Gx, _ = new(big.Int).SetString("79BE667EF9DCBBAC55A06295CE870B07029BFCDB2DCE28D959F2815B16F81798", 16)
+ ecp256k1.Gy, _ = new(big.Int).SetString("483ADA7726A3C4655DA4FBFC0E1108A8FD17B448A68554199C47D08FFB10D4B8", 16)
+ ecp256k1.BitSize = 256
+}
+
+// S160 returns a BitCurve which implements secp160k1 (see SEC 2 section 2.4.1)
+func S160() *BitCurve {
+ initonce.Do(initAll)
+ return ecp160k1
+}
+
+// S192 returns a BitCurve which implements secp192k1 (see SEC 2 section 2.5.1)
+func S192() *BitCurve {
+ initonce.Do(initAll)
+ return ecp192k1
+}
+
+// S224 returns a BitCurve which implements secp224k1 (see SEC 2 section 2.6.1)
+func S224() *BitCurve {
+ initonce.Do(initAll)
+ return ecp224k1
+}
+
+// S256 returns a BitCurve which implements secp256k1 (see SEC 2 section 2.7.1)
+func S256() *BitCurve {
+ initonce.Do(initAll)
+ return ecp256k1
+}
diff --git a/crypto/ecies/.gitignore b/crypto/ecies/.gitignore
new file mode 100644
index 000000000..802b6744a
--- /dev/null
+++ b/crypto/ecies/.gitignore
@@ -0,0 +1,24 @@
+# Compiled Object files, Static and Dynamic libs (Shared Objects)
+*.o
+*.a
+*.so
+
+# Folders
+_obj
+_test
+
+# Architecture specific extensions/prefixes
+*.[568vq]
+[568vq].out
+
+*.cgo1.go
+*.cgo2.c
+_cgo_defun.c
+_cgo_gotypes.go
+_cgo_export.*
+
+_testmain.go
+
+*.exe
+
+*~
diff --git a/crypto/ecies/LICENSE b/crypto/ecies/LICENSE
new file mode 100644
index 000000000..e1ed19a27
--- /dev/null
+++ b/crypto/ecies/LICENSE
@@ -0,0 +1,28 @@
+Copyright (c) 2013 Kyle Isom <kyle@tyrfingr.is>
+Copyright (c) 2012 The Go Authors. All rights reserved.
+
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions are
+met:
+
+ * Redistributions of source code must retain the above copyright
+notice, this list of conditions and the following disclaimer.
+ * Redistributions in binary form must reproduce the above
+copyright notice, this list of conditions and the following disclaimer
+in the documentation and/or other materials provided with the
+distribution.
+ * Neither the name of Google Inc. nor the names of its
+contributors may be used to endorse or promote products derived from
+this software without specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
diff --git a/crypto/ecies/README b/crypto/ecies/README
new file mode 100644
index 000000000..2650c7b9f
--- /dev/null
+++ b/crypto/ecies/README
@@ -0,0 +1,94 @@
+# NOTE
+
+This implementation is direct fork of Kylom's implementation. I claim no authorship over this code apart from some minor modifications.
+Please be aware this code **has not yet been reviewed**.
+
+ecies implements the Elliptic Curve Integrated Encryption Scheme.
+
+The package is designed to be compliant with the appropriate NIST
+standards, and therefore doesn't support the full SEC 1 algorithm set.
+
+
+STATUS:
+
+ecies should be ready for use. The ASN.1 support is only complete so
+far as to supported the listed algorithms before.
+
+
+CAVEATS
+
+1. CMAC support is currently not present.
+
+
+SUPPORTED ALGORITHMS
+
+ SYMMETRIC CIPHERS HASH FUNCTIONS
+ AES128 SHA-1
+ AES192 SHA-224
+ AES256 SHA-256
+ SHA-384
+ ELLIPTIC CURVE SHA-512
+ P256
+ P384 KEY DERIVATION FUNCTION
+ P521 NIST SP 800-65a Concatenation KDF
+
+Curve P224 isn't supported because it does not provide a minimum security
+level of AES128 with HMAC-SHA1. According to NIST SP 800-57, the security
+level of P224 is 112 bits of security. Symmetric ciphers use CTR-mode;
+message tags are computed using HMAC-<HASH> function.
+
+
+CURVE SELECTION
+
+According to NIST SP 800-57, the following curves should be selected:
+
+ +----------------+-------+
+ | SYMMETRIC SIZE | CURVE |
+ +----------------+-------+
+ | 128-bit | P256 |
+ +----------------+-------+
+ | 192-bit | P384 |
+ +----------------+-------+
+ | 256-bit | P521 |
+ +----------------+-------+
+
+
+TODO
+
+1. Look at serialising the parameters with the SEC 1 ASN.1 module.
+2. Validate ASN.1 formats with SEC 1.
+
+
+TEST VECTORS
+
+The only test vectors I've found so far date from 1993, predating AES
+and including only 163-bit curves. Therefore, there are no published
+test vectors to compare to.
+
+
+LICENSE
+
+ecies is released under the same license as the Go source code. See the
+LICENSE file for details.
+
+
+REFERENCES
+
+* SEC (Standard for Efficient Cryptography) 1, version 2.0: Elliptic
+ Curve Cryptography; Certicom, May 2009.
+ http://www.secg.org/sec1-v2.pdf
+* GEC (Guidelines for Efficient Cryptography) 2, version 0.3: Test
+ Vectors for SEC 1; Certicom, September 1999.
+ http://read.pudn.com/downloads168/doc/772358/TestVectorsforSEC%201-gec2.pdf
+* NIST SP 800-56a: Recommendation for Pair-Wise Key Establishment Schemes
+ Using Discrete Logarithm Cryptography. National Institute of Standards
+ and Technology, May 2007.
+ http://csrc.nist.gov/publications/nistpubs/800-56A/SP800-56A_Revision1_Mar08-2007.pdf
+* Suite B Implementer’s Guide to NIST SP 800-56A. National Security
+ Agency, July 28, 2009.
+ http://www.nsa.gov/ia/_files/SuiteB_Implementer_G-113808.pdf
+* NIST SP 800-57: Recommendation for Key Management – Part 1: General
+ (Revision 3). National Institute of Standards and Technology, July
+ 2012.
+ http://csrc.nist.gov/publications/nistpubs/800-57/sp800-57_part1_rev3_general.pdf
+
diff --git a/crypto/ecies/asn1.go b/crypto/ecies/asn1.go
new file mode 100644
index 000000000..3ef194ea0
--- /dev/null
+++ b/crypto/ecies/asn1.go
@@ -0,0 +1,556 @@
+package ecies
+
+import (
+ "bytes"
+ "crypto"
+ "crypto/elliptic"
+ "crypto/sha1"
+ "crypto/sha256"
+ "crypto/sha512"
+ "encoding/asn1"
+ "encoding/pem"
+ "fmt"
+ "hash"
+ "math/big"
+)
+
+var (
+ secgScheme = []int{1, 3, 132, 1}
+ shaScheme = []int{2, 16, 840, 1, 101, 3, 4, 2}
+ ansiX962Scheme = []int{1, 2, 840, 10045}
+ x963Scheme = []int{1, 2, 840, 63, 0}
+)
+
+var ErrInvalidPrivateKey = fmt.Errorf("ecies: invalid private key")
+
+func doScheme(base, v []int) asn1.ObjectIdentifier {
+ var oidInts asn1.ObjectIdentifier
+ oidInts = append(oidInts, base...)
+ return append(oidInts, v...)
+}
+
+// curve OID code taken from crypto/x509, including
+// - oidNameCurve*
+// - namedCurveFromOID
+// - oidFromNamedCurve
+// RFC 5480, 2.1.1.1. Named Curve
+//
+// secp224r1 OBJECT IDENTIFIER ::= {
+// iso(1) identified-organization(3) certicom(132) curve(0) 33 }
+//
+// secp256r1 OBJECT IDENTIFIER ::= {
+// iso(1) member-body(2) us(840) ansi-X9-62(10045) curves(3)
+// prime(1) 7 }
+//
+// secp384r1 OBJECT IDENTIFIER ::= {
+// iso(1) identified-organization(3) certicom(132) curve(0) 34 }
+//
+// secp521r1 OBJECT IDENTIFIER ::= {
+// iso(1) identified-organization(3) certicom(132) curve(0) 35 }
+//
+// NB: secp256r1 is equivalent to prime256v1
+type secgNamedCurve asn1.ObjectIdentifier
+
+var (
+ secgNamedCurveP224 = secgNamedCurve{1, 3, 132, 0, 33}
+ secgNamedCurveP256 = secgNamedCurve{1, 2, 840, 10045, 3, 1, 7}
+ secgNamedCurveP384 = secgNamedCurve{1, 3, 132, 0, 34}
+ secgNamedCurveP521 = secgNamedCurve{1, 3, 132, 0, 35}
+ rawCurveP224 = []byte{6, 5, 4, 3, 1, 2, 9, 4, 0, 3, 3}
+ rawCurveP256 = []byte{6, 8, 4, 2, 1, 3, 4, 7, 2, 2, 0, 6, 6, 1, 3, 1, 7}
+ rawCurveP384 = []byte{6, 5, 4, 3, 1, 2, 9, 4, 0, 3, 4}
+ rawCurveP521 = []byte{6, 5, 4, 3, 1, 2, 9, 4, 0, 3, 5}
+)
+
+func rawCurve(curve elliptic.Curve) []byte {
+ switch curve {
+ case elliptic.P224():
+ return rawCurveP224
+ case elliptic.P256():
+ return rawCurveP256
+ case elliptic.P384():
+ return rawCurveP384
+ case elliptic.P521():
+ return rawCurveP521
+ default:
+ return nil
+ }
+}
+
+func (curve secgNamedCurve) Equal(curve2 secgNamedCurve) bool {
+ if len(curve) != len(curve2) {
+ return false
+ }
+ for i, _ := range curve {
+ if curve[i] != curve2[i] {
+ return false
+ }
+ }
+ return true
+}
+
+func namedCurveFromOID(curve secgNamedCurve) elliptic.Curve {
+ switch {
+ case curve.Equal(secgNamedCurveP224):
+ return elliptic.P224()
+ case curve.Equal(secgNamedCurveP256):
+ return elliptic.P256()
+ case curve.Equal(secgNamedCurveP384):
+ return elliptic.P384()
+ case curve.Equal(secgNamedCurveP521):
+ return elliptic.P521()
+ }
+ return nil
+}
+
+func oidFromNamedCurve(curve elliptic.Curve) (secgNamedCurve, bool) {
+ switch curve {
+ case elliptic.P224():
+ return secgNamedCurveP224, true
+ case elliptic.P256():
+ return secgNamedCurveP256, true
+ case elliptic.P384():
+ return secgNamedCurveP384, true
+ case elliptic.P521():
+ return secgNamedCurveP521, true
+ }
+
+ return nil, false
+}
+
+// asnAlgorithmIdentifier represents the ASN.1 structure of the same name. See RFC
+// 5280, section 4.1.1.2.
+type asnAlgorithmIdentifier struct {
+ Algorithm asn1.ObjectIdentifier
+ Parameters asn1.RawValue `asn1:"optional"`
+}
+
+func (a asnAlgorithmIdentifier) Cmp(b asnAlgorithmIdentifier) bool {
+ if len(a.Algorithm) != len(b.Algorithm) {
+ return false
+ }
+ for i, _ := range a.Algorithm {
+ if a.Algorithm[i] != b.Algorithm[i] {
+ return false
+ }
+ }
+ return true
+}
+
+type asnHashFunction asnAlgorithmIdentifier
+
+var (
+ oidSHA1 = asn1.ObjectIdentifier{1, 3, 14, 3, 2, 26}
+ oidSHA224 = doScheme(shaScheme, []int{4})
+ oidSHA256 = doScheme(shaScheme, []int{1})
+ oidSHA384 = doScheme(shaScheme, []int{2})
+ oidSHA512 = doScheme(shaScheme, []int{3})
+)
+
+func hashFromOID(oid asn1.ObjectIdentifier) func() hash.Hash {
+ switch {
+ case oid.Equal(oidSHA1):
+ return sha1.New
+ case oid.Equal(oidSHA224):
+ return sha256.New224
+ case oid.Equal(oidSHA256):
+ return sha256.New
+ case oid.Equal(oidSHA384):
+ return sha512.New384
+ case oid.Equal(oidSHA512):
+ return sha512.New
+ }
+ return nil
+}
+
+func oidFromHash(hash crypto.Hash) (asn1.ObjectIdentifier, bool) {
+ switch hash {
+ case crypto.SHA1:
+ return oidSHA1, true
+ case crypto.SHA224:
+ return oidSHA224, true
+ case crypto.SHA256:
+ return oidSHA256, true
+ case crypto.SHA384:
+ return oidSHA384, true
+ case crypto.SHA512:
+ return oidSHA512, true
+ default:
+ return nil, false
+ }
+}
+
+var (
+ asnAlgoSHA1 = asnHashFunction{
+ Algorithm: oidSHA1,
+ }
+ asnAlgoSHA224 = asnHashFunction{
+ Algorithm: oidSHA224,
+ }
+ asnAlgoSHA256 = asnHashFunction{
+ Algorithm: oidSHA256,
+ }
+ asnAlgoSHA384 = asnHashFunction{
+ Algorithm: oidSHA384,
+ }
+ asnAlgoSHA512 = asnHashFunction{
+ Algorithm: oidSHA512,
+ }
+)
+
+// type ASNasnSubjectPublicKeyInfo struct {
+//
+// }
+//
+
+type asnSubjectPublicKeyInfo struct {
+ Algorithm asn1.ObjectIdentifier
+ PublicKey asn1.BitString
+ Supplements ecpksSupplements `asn1:"optional"`
+}
+
+type asnECPKAlgorithms struct {
+ Type asn1.ObjectIdentifier
+}
+
+var idPublicKeyType = doScheme(ansiX962Scheme, []int{2})
+var idEcPublicKey = doScheme(idPublicKeyType, []int{1})
+var idEcPublicKeySupplemented = doScheme(idPublicKeyType, []int{0})
+
+func curveToRaw(curve elliptic.Curve) (rv asn1.RawValue, ok bool) {
+ switch curve {
+ case elliptic.P224(), elliptic.P256(), elliptic.P384(), elliptic.P521():
+ raw := rawCurve(curve)
+ return asn1.RawValue{
+ Tag: 30,
+ Bytes: raw[2:],
+ FullBytes: raw,
+ }, true
+ default:
+ return rv, false
+ }
+}
+
+func asnECPublicKeyType(curve elliptic.Curve) (algo asnAlgorithmIdentifier, ok bool) {
+ raw, ok := curveToRaw(curve)
+ if !ok {
+ return
+ } else {
+ return asnAlgorithmIdentifier{Algorithm: idEcPublicKey,
+ Parameters: raw}, true
+ }
+}
+
+type asnECPrivKeyVer int
+
+var asnECPrivKeyVer1 asnECPrivKeyVer = 1
+
+type asnPrivateKey struct {
+ Version asnECPrivKeyVer
+ Private []byte
+ Curve secgNamedCurve `asn1:"optional"`
+ Public asn1.BitString
+}
+
+var asnECDH = doScheme(secgScheme, []int{12})
+
+type asnECDHAlgorithm asnAlgorithmIdentifier
+
+var (
+ dhSinglePass_stdDH_sha1kdf = asnECDHAlgorithm{
+ Algorithm: doScheme(x963Scheme, []int{2}),
+ }
+ dhSinglePass_stdDH_sha256kdf = asnECDHAlgorithm{
+ Algorithm: doScheme(secgScheme, []int{11, 1}),
+ }
+ dhSinglePass_stdDH_sha384kdf = asnECDHAlgorithm{
+ Algorithm: doScheme(secgScheme, []int{11, 2}),
+ }
+ dhSinglePass_stdDH_sha224kdf = asnECDHAlgorithm{
+ Algorithm: doScheme(secgScheme, []int{11, 0}),
+ }
+ dhSinglePass_stdDH_sha512kdf = asnECDHAlgorithm{
+ Algorithm: doScheme(secgScheme, []int{11, 3}),
+ }
+)
+
+func (a asnECDHAlgorithm) Cmp(b asnECDHAlgorithm) bool {
+ if len(a.Algorithm) != len(b.Algorithm) {
+ return false
+ }
+ for i, _ := range a.Algorithm {
+ if a.Algorithm[i] != b.Algorithm[i] {
+ return false
+ }
+ }
+ return true
+}
+
+// asnNISTConcatenation is the only supported KDF at this time.
+type asnKeyDerivationFunction asnAlgorithmIdentifier
+
+var asnNISTConcatenationKDF = asnKeyDerivationFunction{
+ Algorithm: doScheme(secgScheme, []int{17, 1}),
+}
+
+func (a asnKeyDerivationFunction) Cmp(b asnKeyDerivationFunction) bool {
+ if len(a.Algorithm) != len(b.Algorithm) {
+ return false
+ }
+ for i, _ := range a.Algorithm {
+ if a.Algorithm[i] != b.Algorithm[i] {
+ return false
+ }
+ }
+ return true
+}
+
+var eciesRecommendedParameters = doScheme(secgScheme, []int{7})
+var eciesSpecifiedParameters = doScheme(secgScheme, []int{8})
+
+type asnECIESParameters struct {
+ KDF asnKeyDerivationFunction `asn1:"optional"`
+ Sym asnSymmetricEncryption `asn1:"optional"`
+ MAC asnMessageAuthenticationCode `asn1:"optional"`
+}
+
+type asnSymmetricEncryption asnAlgorithmIdentifier
+
+var (
+ aes128CTRinECIES = asnSymmetricEncryption{
+ Algorithm: doScheme(secgScheme, []int{21, 0}),
+ }
+ aes192CTRinECIES = asnSymmetricEncryption{
+ Algorithm: doScheme(secgScheme, []int{21, 1}),
+ }
+ aes256CTRinECIES = asnSymmetricEncryption{
+ Algorithm: doScheme(secgScheme, []int{21, 2}),
+ }
+)
+
+func (a asnSymmetricEncryption) Cmp(b asnSymmetricEncryption) bool {
+ if len(a.Algorithm) != len(b.Algorithm) {
+ return false
+ }
+ for i, _ := range a.Algorithm {
+ if a.Algorithm[i] != b.Algorithm[i] {
+ return false
+ }
+ }
+ return true
+}
+
+type asnMessageAuthenticationCode asnAlgorithmIdentifier
+
+var (
+ hmacFull = asnMessageAuthenticationCode{
+ Algorithm: doScheme(secgScheme, []int{22}),
+ }
+)
+
+func (a asnMessageAuthenticationCode) Cmp(b asnMessageAuthenticationCode) bool {
+ if len(a.Algorithm) != len(b.Algorithm) {
+ return false
+ }
+ for i, _ := range a.Algorithm {
+ if a.Algorithm[i] != b.Algorithm[i] {
+ return false
+ }
+ }
+ return true
+}
+
+type ecpksSupplements struct {
+ ECDomain secgNamedCurve
+ ECCAlgorithms eccAlgorithmSet
+}
+
+type eccAlgorithmSet struct {
+ ECDH asnECDHAlgorithm `asn1:"optional"`
+ ECIES asnECIESParameters `asn1:"optional"`
+}
+
+func marshalSubjectPublicKeyInfo(pub *PublicKey) (subj asnSubjectPublicKeyInfo, err error) {
+ subj.Algorithm = idEcPublicKeySupplemented
+ curve, ok := oidFromNamedCurve(pub.Curve)
+ if !ok {
+ err = ErrInvalidPublicKey
+ return
+ }
+ subj.Supplements.ECDomain = curve
+ if pub.Params != nil {
+ subj.Supplements.ECCAlgorithms.ECDH = paramsToASNECDH(pub.Params)
+ subj.Supplements.ECCAlgorithms.ECIES = paramsToASNECIES(pub.Params)
+ }
+ pubkey := elliptic.Marshal(pub.Curve, pub.X, pub.Y)
+ subj.PublicKey = asn1.BitString{
+ BitLength: len(pubkey) * 8,
+ Bytes: pubkey,
+ }
+ return
+}
+
+// Encode a public key to DER format.
+func MarshalPublic(pub *PublicKey) ([]byte, error) {
+ subj, err := marshalSubjectPublicKeyInfo(pub)
+ if err != nil {
+ return nil, err
+ }
+ return asn1.Marshal(subj)
+}
+
+// Decode a DER-encoded public key.
+func UnmarshalPublic(in []byte) (pub *PublicKey, err error) {
+ var subj asnSubjectPublicKeyInfo
+
+ if _, err = asn1.Unmarshal(in, &subj); err != nil {
+ return
+ }
+ if !subj.Algorithm.Equal(idEcPublicKeySupplemented) {
+ err = ErrInvalidPublicKey
+ return
+ }
+ pub = new(PublicKey)
+ pub.Curve = namedCurveFromOID(subj.Supplements.ECDomain)
+ x, y := elliptic.Unmarshal(pub.Curve, subj.PublicKey.Bytes)
+ if x == nil {
+ err = ErrInvalidPublicKey
+ return
+ }
+ pub.X = x
+ pub.Y = y
+ pub.Params = new(ECIESParams)
+ asnECIEStoParams(subj.Supplements.ECCAlgorithms.ECIES, pub.Params)
+ asnECDHtoParams(subj.Supplements.ECCAlgorithms.ECDH, pub.Params)
+ if pub.Params == nil {
+ if pub.Params = ParamsFromCurve(pub.Curve); pub.Params == nil {
+ err = ErrInvalidPublicKey
+ }
+ }
+ return
+}
+
+func marshalPrivateKey(prv *PrivateKey) (ecprv asnPrivateKey, err error) {
+ ecprv.Version = asnECPrivKeyVer1
+ ecprv.Private = prv.D.Bytes()
+
+ var ok bool
+ ecprv.Curve, ok = oidFromNamedCurve(prv.PublicKey.Curve)
+ if !ok {
+ err = ErrInvalidPrivateKey
+ return
+ }
+
+ var pub []byte
+ if pub, err = MarshalPublic(&prv.PublicKey); err != nil {
+ return
+ } else {
+ ecprv.Public = asn1.BitString{
+ BitLength: len(pub) * 8,
+ Bytes: pub,
+ }
+ }
+ return
+}
+
+// Encode a private key to DER format.
+func MarshalPrivate(prv *PrivateKey) ([]byte, error) {
+ ecprv, err := marshalPrivateKey(prv)
+ if err != nil {
+ return nil, err
+ }
+ return asn1.Marshal(ecprv)
+}
+
+// Decode a private key from a DER-encoded format.
+func UnmarshalPrivate(in []byte) (prv *PrivateKey, err error) {
+ var ecprv asnPrivateKey
+
+ if _, err = asn1.Unmarshal(in, &ecprv); err != nil {
+ return
+ } else if ecprv.Version != asnECPrivKeyVer1 {
+ err = ErrInvalidPrivateKey
+ return
+ }
+
+ privateCurve := namedCurveFromOID(ecprv.Curve)
+ if privateCurve == nil {
+ err = ErrInvalidPrivateKey
+ return
+ }
+
+ prv = new(PrivateKey)
+ prv.D = new(big.Int).SetBytes(ecprv.Private)
+
+ if pub, err := UnmarshalPublic(ecprv.Public.Bytes); err != nil {
+ return nil, err
+ } else {
+ prv.PublicKey = *pub
+ }
+
+ return
+}
+
+// Export a public key to PEM format.
+func ExportPublicPEM(pub *PublicKey) (out []byte, err error) {
+ der, err := MarshalPublic(pub)
+ if err != nil {
+ return
+ }
+
+ var block pem.Block
+ block.Type = "ELLIPTIC CURVE PUBLIC KEY"
+ block.Bytes = der
+
+ buf := new(bytes.Buffer)
+ err = pem.Encode(buf, &block)
+ if err != nil {
+ return
+ } else {
+ out = buf.Bytes()
+ }
+ return
+}
+
+// Export a private key to PEM format.
+func ExportPrivatePEM(prv *PrivateKey) (out []byte, err error) {
+ der, err := MarshalPrivate(prv)
+ if err != nil {
+ return
+ }
+
+ var block pem.Block
+ block.Type = "ELLIPTIC CURVE PRIVATE KEY"
+ block.Bytes = der
+
+ buf := new(bytes.Buffer)
+ err = pem.Encode(buf, &block)
+ if err != nil {
+ return
+ } else {
+ out = buf.Bytes()
+ }
+ return
+}
+
+// Import a PEM-encoded public key.
+func ImportPublicPEM(in []byte) (pub *PublicKey, err error) {
+ p, _ := pem.Decode(in)
+ if p == nil || p.Type != "ELLIPTIC CURVE PUBLIC KEY" {
+ return nil, ErrInvalidPublicKey
+ }
+
+ pub, err = UnmarshalPublic(p.Bytes)
+ return
+}
+
+// Import a PEM-encoded private key.
+func ImportPrivatePEM(in []byte) (prv *PrivateKey, err error) {
+ p, _ := pem.Decode(in)
+ if p == nil || p.Type != "ELLIPTIC CURVE PRIVATE KEY" {
+ return nil, ErrInvalidPrivateKey
+ }
+
+ prv, err = UnmarshalPrivate(p.Bytes)
+ return
+}
diff --git a/crypto/ecies/ecies.go b/crypto/ecies/ecies.go
new file mode 100644
index 000000000..18952fc0b
--- /dev/null
+++ b/crypto/ecies/ecies.go
@@ -0,0 +1,331 @@
+package ecies
+
+import (
+ "crypto/cipher"
+ "crypto/ecdsa"
+ "crypto/elliptic"
+ "crypto/hmac"
+ "crypto/subtle"
+ "fmt"
+ "hash"
+ "io"
+ "math/big"
+)
+
+var (
+ ErrImport = fmt.Errorf("ecies: failed to import key")
+ ErrInvalidCurve = fmt.Errorf("ecies: invalid elliptic curve")
+ ErrInvalidParams = fmt.Errorf("ecies: invalid ECIES parameters")
+ ErrInvalidPublicKey = fmt.Errorf("ecies: invalid public key")
+ ErrSharedKeyIsPointAtInfinity = fmt.Errorf("ecies: shared key is point at infinity")
+ ErrSharedKeyTooBig = fmt.Errorf("ecies: shared key params are too big")
+)
+
+// PublicKey is a representation of an elliptic curve public key.
+type PublicKey struct {
+ X *big.Int
+ Y *big.Int
+ elliptic.Curve
+ Params *ECIESParams
+}
+
+// Export an ECIES public key as an ECDSA public key.
+func (pub *PublicKey) ExportECDSA() *ecdsa.PublicKey {
+ return &ecdsa.PublicKey{pub.Curve, pub.X, pub.Y}
+}
+
+// Import an ECDSA public key as an ECIES public key.
+func ImportECDSAPublic(pub *ecdsa.PublicKey) *PublicKey {
+ return &PublicKey{
+ X: pub.X,
+ Y: pub.Y,
+ Curve: pub.Curve,
+ Params: ParamsFromCurve(pub.Curve),
+ }
+}
+
+// PrivateKey is a representation of an elliptic curve private key.
+type PrivateKey struct {
+ PublicKey
+ D *big.Int
+}
+
+// Export an ECIES private key as an ECDSA private key.
+func (prv *PrivateKey) ExportECDSA() *ecdsa.PrivateKey {
+ pub := &prv.PublicKey
+ pubECDSA := pub.ExportECDSA()
+ return &ecdsa.PrivateKey{*pubECDSA, prv.D}
+}
+
+// Import an ECDSA private key as an ECIES private key.
+func ImportECDSA(prv *ecdsa.PrivateKey) *PrivateKey {
+ pub := ImportECDSAPublic(&prv.PublicKey)
+ return &PrivateKey{*pub, prv.D}
+}
+
+// Generate an elliptic curve public / private keypair. If params is nil,
+// the recommended default paramters for the key will be chosen.
+func GenerateKey(rand io.Reader, curve elliptic.Curve, params *ECIESParams) (prv *PrivateKey, err error) {
+ pb, x, y, err := elliptic.GenerateKey(curve, rand)
+ if err != nil {
+ return
+ }
+ prv = new(PrivateKey)
+ prv.PublicKey.X = x
+ prv.PublicKey.Y = y
+ prv.PublicKey.Curve = curve
+ prv.D = new(big.Int).SetBytes(pb)
+ if params == nil {
+ params = ParamsFromCurve(curve)
+ }
+ prv.PublicKey.Params = params
+ return
+}
+
+// MaxSharedKeyLength returns the maximum length of the shared key the
+// public key can produce.
+func MaxSharedKeyLength(pub *PublicKey) int {
+ return (pub.Curve.Params().BitSize + 7) / 8
+}
+
+// ECDH key agreement method used to establish secret keys for encryption.
+func (prv *PrivateKey) GenerateShared(pub *PublicKey, skLen, macLen int) (sk []byte, err error) {
+ if prv.PublicKey.Curve != pub.Curve {
+ return nil, ErrInvalidCurve
+ }
+ if skLen+macLen > MaxSharedKeyLength(pub) {
+ return nil, ErrSharedKeyTooBig
+ }
+ x, _ := pub.Curve.ScalarMult(pub.X, pub.Y, prv.D.Bytes())
+ if x == nil {
+ return nil, ErrSharedKeyIsPointAtInfinity
+ }
+
+ sk = make([]byte, skLen+macLen)
+ skBytes := x.Bytes()
+ copy(sk[len(sk)-len(skBytes):], skBytes)
+ return sk, nil
+}
+
+var (
+ ErrKeyDataTooLong = fmt.Errorf("ecies: can't supply requested key data")
+ ErrSharedTooLong = fmt.Errorf("ecies: shared secret is too long")
+ ErrInvalidMessage = fmt.Errorf("ecies: invalid message")
+)
+
+var (
+ big2To32 = new(big.Int).Exp(big.NewInt(2), big.NewInt(32), nil)
+ big2To32M1 = new(big.Int).Sub(big2To32, big.NewInt(1))
+)
+
+func incCounter(ctr []byte) {
+ if ctr[3]++; ctr[3] != 0 {
+ return
+ } else if ctr[2]++; ctr[2] != 0 {
+ return
+ } else if ctr[1]++; ctr[1] != 0 {
+ return
+ } else if ctr[0]++; ctr[0] != 0 {
+ return
+ }
+ return
+}
+
+// NIST SP 800-56 Concatenation Key Derivation Function (see section 5.8.1).
+func concatKDF(hash hash.Hash, z, s1 []byte, kdLen int) (k []byte, err error) {
+ if s1 == nil {
+ s1 = make([]byte, 0)
+ }
+
+ reps := ((kdLen + 7) * 8) / (hash.BlockSize() * 8)
+ if big.NewInt(int64(reps)).Cmp(big2To32M1) > 0 {
+ fmt.Println(big2To32M1)
+ return nil, ErrKeyDataTooLong
+ }
+
+ counter := []byte{0, 0, 0, 1}
+ k = make([]byte, 0)
+
+ for i := 0; i <= reps; i++ {
+ hash.Write(counter)
+ hash.Write(z)
+ hash.Write(s1)
+ k = append(k, hash.Sum(nil)...)
+ hash.Reset()
+ incCounter(counter)
+ }
+
+ k = k[:kdLen]
+ return
+}
+
+// messageTag computes the MAC of a message (called the tag) as per
+// SEC 1, 3.5.
+func messageTag(hash func() hash.Hash, km, msg, shared []byte) []byte {
+ if shared == nil {
+ shared = make([]byte, 0)
+ }
+ mac := hmac.New(hash, km)
+ mac.Write(msg)
+ tag := mac.Sum(nil)
+ return tag
+}
+
+// Generate an initialisation vector for CTR mode.
+func generateIV(params *ECIESParams, rand io.Reader) (iv []byte, err error) {
+ iv = make([]byte, params.BlockSize)
+ _, err = io.ReadFull(rand, iv)
+ return
+}
+
+// symEncrypt carries out CTR encryption using the block cipher specified in the
+// parameters.
+func symEncrypt(rand io.Reader, params *ECIESParams, key, m []byte) (ct []byte, err error) {
+ c, err := params.Cipher(key)
+ if err != nil {
+ return
+ }
+
+ iv, err := generateIV(params, rand)
+ if err != nil {
+ return
+ }
+ ctr := cipher.NewCTR(c, iv)
+
+ ct = make([]byte, len(m)+params.BlockSize)
+ copy(ct, iv)
+ ctr.XORKeyStream(ct[params.BlockSize:], m)
+ return
+}
+
+// symDecrypt carries out CTR decryption using the block cipher specified in
+// the parameters
+func symDecrypt(rand io.Reader, params *ECIESParams, key, ct []byte) (m []byte, err error) {
+ c, err := params.Cipher(key)
+ if err != nil {
+ return
+ }
+
+ ctr := cipher.NewCTR(c, ct[:params.BlockSize])
+
+ m = make([]byte, len(ct)-params.BlockSize)
+ ctr.XORKeyStream(m, ct[params.BlockSize:])
+ return
+}
+
+// Encrypt encrypts a message using ECIES as specified in SEC 1, 5.1. If
+// the shared information parameters aren't being used, they should be
+// nil.
+func Encrypt(rand io.Reader, pub *PublicKey, m, s1, s2 []byte) (ct []byte, err error) {
+ params := pub.Params
+ if params == nil {
+ if params = ParamsFromCurve(pub.Curve); params == nil {
+ err = ErrUnsupportedECIESParameters
+ return
+ }
+ }
+ R, err := GenerateKey(rand, pub.Curve, params)
+ if err != nil {
+ return
+ }
+
+ hash := params.Hash()
+ z, err := R.GenerateShared(pub, params.KeyLen, params.KeyLen)
+ if err != nil {
+ return
+ }
+ K, err := concatKDF(hash, z, s1, params.KeyLen+params.KeyLen)
+ if err != nil {
+ return
+ }
+ Ke := K[:params.KeyLen]
+ Km := K[params.KeyLen:]
+ hash.Write(Km)
+ Km = hash.Sum(nil)
+ hash.Reset()
+
+ em, err := symEncrypt(rand, params, Ke, m)
+ if err != nil || len(em) <= params.BlockSize {
+ return
+ }
+
+ d := messageTag(params.Hash, Km, em, s2)
+
+ Rb := elliptic.Marshal(pub.Curve, R.PublicKey.X, R.PublicKey.Y)
+ ct = make([]byte, len(Rb)+len(em)+len(d))
+ copy(ct, Rb)
+ copy(ct[len(Rb):], em)
+ copy(ct[len(Rb)+len(em):], d)
+ return
+}
+
+// Decrypt decrypts an ECIES ciphertext.
+func (prv *PrivateKey) Decrypt(rand io.Reader, c, s1, s2 []byte) (m []byte, err error) {
+ if c == nil || len(c) == 0 {
+ err = ErrInvalidMessage
+ return
+ }
+ params := prv.PublicKey.Params
+ if params == nil {
+ if params = ParamsFromCurve(prv.PublicKey.Curve); params == nil {
+ err = ErrUnsupportedECIESParameters
+ return
+ }
+ }
+ hash := params.Hash()
+
+ var (
+ rLen int
+ hLen int = hash.Size()
+ mStart int
+ mEnd int
+ )
+
+ switch c[0] {
+ case 2, 3, 4:
+ rLen = ((prv.PublicKey.Curve.Params().BitSize + 7) / 4)
+ if len(c) < (rLen + hLen + 1) {
+ err = ErrInvalidMessage
+ return
+ }
+ default:
+ err = ErrInvalidPublicKey
+ return
+ }
+
+ mStart = rLen
+ mEnd = len(c) - hLen
+
+ R := new(PublicKey)
+ R.Curve = prv.PublicKey.Curve
+ R.X, R.Y = elliptic.Unmarshal(R.Curve, c[:rLen])
+ if R.X == nil {
+ err = ErrInvalidPublicKey
+ return
+ }
+
+ z, err := prv.GenerateShared(R, params.KeyLen, params.KeyLen)
+ if err != nil {
+ return
+ }
+
+ K, err := concatKDF(hash, z, s1, params.KeyLen+params.KeyLen)
+ if err != nil {
+ return
+ }
+
+ Ke := K[:params.KeyLen]
+ Km := K[params.KeyLen:]
+ hash.Write(Km)
+ Km = hash.Sum(nil)
+ hash.Reset()
+
+ d := messageTag(params.Hash, Km, c[mStart:mEnd], s2)
+ if subtle.ConstantTimeCompare(c[mEnd:], d) != 1 {
+ err = ErrInvalidMessage
+ return
+ }
+
+ m, err = symDecrypt(rand, params, Ke, c[mStart:mEnd])
+ return
+}
diff --git a/crypto/ecies/ecies_test.go b/crypto/ecies/ecies_test.go
new file mode 100644
index 000000000..943e4488e
--- /dev/null
+++ b/crypto/ecies/ecies_test.go
@@ -0,0 +1,489 @@
+package ecies
+
+import (
+ "bytes"
+ "crypto/elliptic"
+ "crypto/rand"
+ "crypto/sha256"
+ "flag"
+ "fmt"
+ "io/ioutil"
+ "testing"
+)
+
+var dumpEnc bool
+
+func init() {
+ flDump := flag.Bool("dump", false, "write encrypted test message to file")
+ flag.Parse()
+ dumpEnc = *flDump
+}
+
+// Ensure the KDF generates appropriately sized keys.
+func TestKDF(t *testing.T) {
+ msg := []byte("Hello, world")
+ h := sha256.New()
+
+ k, err := concatKDF(h, msg, nil, 64)
+ if err != nil {
+ fmt.Println(err.Error())
+ t.FailNow()
+ }
+ if len(k) != 64 {
+ fmt.Printf("KDF: generated key is the wrong size (%d instead of 64\n",
+ len(k))
+ t.FailNow()
+ }
+}
+
+var skLen int
+var ErrBadSharedKeys = fmt.Errorf("ecies: shared keys don't match")
+
+// cmpParams compares a set of ECIES parameters. We assume, as per the
+// docs, that AES is the only supported symmetric encryption algorithm.
+func cmpParams(p1, p2 *ECIESParams) bool {
+ if p1.hashAlgo != p2.hashAlgo {
+ return false
+ } else if p1.KeyLen != p2.KeyLen {
+ return false
+ } else if p1.BlockSize != p2.BlockSize {
+ return false
+ }
+ return true
+}
+
+// cmpPublic returns true if the two public keys represent the same pojnt.
+func cmpPublic(pub1, pub2 PublicKey) bool {
+ if pub1.X == nil || pub1.Y == nil {
+ fmt.Println(ErrInvalidPublicKey.Error())
+ return false
+ }
+ if pub2.X == nil || pub2.Y == nil {
+ fmt.Println(ErrInvalidPublicKey.Error())
+ return false
+ }
+ pub1Out := elliptic.Marshal(pub1.Curve, pub1.X, pub1.Y)
+ pub2Out := elliptic.Marshal(pub2.Curve, pub2.X, pub2.Y)
+
+ return bytes.Equal(pub1Out, pub2Out)
+}
+
+// cmpPrivate returns true if the two private keys are the same.
+func cmpPrivate(prv1, prv2 *PrivateKey) bool {
+ if prv1 == nil || prv1.D == nil {
+ return false
+ } else if prv2 == nil || prv2.D == nil {
+ return false
+ } else if prv1.D.Cmp(prv2.D) != 0 {
+ return false
+ } else {
+ return cmpPublic(prv1.PublicKey, prv2.PublicKey)
+ }
+}
+
+// Validate the ECDH component.
+func TestSharedKey(t *testing.T) {
+ prv1, err := GenerateKey(rand.Reader, DefaultCurve, nil)
+ if err != nil {
+ fmt.Println(err.Error())
+ t.FailNow()
+ }
+ skLen = MaxSharedKeyLength(&prv1.PublicKey) / 2
+
+ prv2, err := GenerateKey(rand.Reader, DefaultCurve, nil)
+ if err != nil {
+ fmt.Println(err.Error())
+ t.FailNow()
+ }
+
+ sk1, err := prv1.GenerateShared(&prv2.PublicKey, skLen, skLen)
+ if err != nil {
+ fmt.Println(err.Error())
+ t.FailNow()
+ }
+
+ sk2, err := prv2.GenerateShared(&prv1.PublicKey, skLen, skLen)
+ if err != nil {
+ fmt.Println(err.Error())
+ t.FailNow()
+ }
+
+ if !bytes.Equal(sk1, sk2) {
+ fmt.Println(ErrBadSharedKeys.Error())
+ t.FailNow()
+ }
+}
+
+// Verify that the key generation code fails when too much key data is
+// requested.
+func TestTooBigSharedKey(t *testing.T) {
+ prv1, err := GenerateKey(rand.Reader, DefaultCurve, nil)
+ if err != nil {
+ fmt.Println(err.Error())
+ t.FailNow()
+ }
+
+ prv2, err := GenerateKey(rand.Reader, DefaultCurve, nil)
+ if err != nil {
+ fmt.Println(err.Error())
+ t.FailNow()
+ }
+
+ _, err = prv1.GenerateShared(&prv2.PublicKey, skLen*2, skLen*2)
+ if err != ErrSharedKeyTooBig {
+ fmt.Println("ecdh: shared key should be too large for curve")
+ t.FailNow()
+ }
+
+ _, err = prv2.GenerateShared(&prv1.PublicKey, skLen*2, skLen*2)
+ if err != ErrSharedKeyTooBig {
+ fmt.Println("ecdh: shared key should be too large for curve")
+ t.FailNow()
+ }
+}
+
+// Ensure a public key can be successfully marshalled and unmarshalled, and
+// that the decoded key is the same as the original.
+func TestMarshalPublic(t *testing.T) {
+ prv, err := GenerateKey(rand.Reader, DefaultCurve, nil)
+ if err != nil {
+ fmt.Println(err.Error())
+ t.FailNow()
+ }
+
+ out, err := MarshalPublic(&prv.PublicKey)
+ if err != nil {
+ fmt.Println(err.Error())
+ t.FailNow()
+ }
+
+ pub, err := UnmarshalPublic(out)
+ if err != nil {
+ fmt.Println(err.Error())
+ t.FailNow()
+ }
+
+ if !cmpPublic(prv.PublicKey, *pub) {
+ fmt.Println("ecies: failed to unmarshal public key")
+ t.FailNow()
+ }
+}
+
+// Ensure that a private key can be encoded into DER format, and that
+// the resulting key is properly parsed back into a public key.
+func TestMarshalPrivate(t *testing.T) {
+ prv, err := GenerateKey(rand.Reader, DefaultCurve, nil)
+ if err != nil {
+ fmt.Println(err.Error())
+ t.FailNow()
+ }
+
+ out, err := MarshalPrivate(prv)
+ if err != nil {
+ fmt.Println(err.Error())
+ t.FailNow()
+ }
+
+ if dumpEnc {
+ ioutil.WriteFile("test.out", out, 0644)
+ }
+
+ prv2, err := UnmarshalPrivate(out)
+ if err != nil {
+ fmt.Println(err.Error())
+ t.FailNow()
+ }
+
+ if !cmpPrivate(prv, prv2) {
+ fmt.Println("ecdh: private key import failed")
+ t.FailNow()
+ }
+}
+
+// Ensure that a private key can be successfully encoded to PEM format, and
+// the resulting key is properly parsed back in.
+func TestPrivatePEM(t *testing.T) {
+ prv, err := GenerateKey(rand.Reader, DefaultCurve, nil)
+ if err != nil {
+ fmt.Println(err.Error())
+ t.FailNow()
+ }
+
+ out, err := ExportPrivatePEM(prv)
+ if err != nil {
+ fmt.Println(err.Error())
+ t.FailNow()
+ }
+
+ if dumpEnc {
+ ioutil.WriteFile("test.key", out, 0644)
+ }
+
+ prv2, err := ImportPrivatePEM(out)
+ if err != nil {
+ fmt.Println(err.Error())
+ t.FailNow()
+ } else if !cmpPrivate(prv, prv2) {
+ fmt.Println("ecdh: import from PEM failed")
+ t.FailNow()
+ }
+}
+
+// Ensure that a public key can be successfully encoded to PEM format, and
+// the resulting key is properly parsed back in.
+func TestPublicPEM(t *testing.T) {
+ prv, err := GenerateKey(rand.Reader, DefaultCurve, nil)
+ if err != nil {
+ fmt.Println(err.Error())
+ t.FailNow()
+ }
+
+ out, err := ExportPublicPEM(&prv.PublicKey)
+ if err != nil {
+ fmt.Println(err.Error())
+ t.FailNow()
+ }
+
+ if dumpEnc {
+ ioutil.WriteFile("test.pem", out, 0644)
+ }
+
+ pub2, err := ImportPublicPEM(out)
+ if err != nil {
+ fmt.Println(err.Error())
+ t.FailNow()
+ } else if !cmpPublic(prv.PublicKey, *pub2) {
+ fmt.Println("ecdh: import from PEM failed")
+ t.FailNow()
+ }
+}
+
+// Benchmark the generation of P256 keys.
+func BenchmarkGenerateKeyP256(b *testing.B) {
+ for i := 0; i < b.N; i++ {
+ if _, err := GenerateKey(rand.Reader, elliptic.P256(), nil); err != nil {
+ fmt.Println(err.Error())
+ b.FailNow()
+ }
+ }
+}
+
+// Benchmark the generation of P256 shared keys.
+func BenchmarkGenSharedKeyP256(b *testing.B) {
+ prv, err := GenerateKey(rand.Reader, elliptic.P256(), nil)
+ if err != nil {
+ fmt.Println(err.Error())
+ b.FailNow()
+ }
+
+ for i := 0; i < b.N; i++ {
+ _, err := prv.GenerateShared(&prv.PublicKey, skLen, skLen)
+ if err != nil {
+ fmt.Println(err.Error())
+ b.FailNow()
+ }
+ }
+}
+
+// Verify that an encrypted message can be successfully decrypted.
+func TestEncryptDecrypt(t *testing.T) {
+ prv1, err := GenerateKey(rand.Reader, DefaultCurve, nil)
+ if err != nil {
+ fmt.Println(err.Error())
+ t.FailNow()
+ }
+
+ prv2, err := GenerateKey(rand.Reader, DefaultCurve, nil)
+ if err != nil {
+ fmt.Println(err.Error())
+ t.FailNow()
+ }
+
+ message := []byte("Hello, world.")
+ ct, err := Encrypt(rand.Reader, &prv2.PublicKey, message, nil, nil)
+ if err != nil {
+ fmt.Println(err.Error())
+ t.FailNow()
+ }
+
+ pt, err := prv2.Decrypt(rand.Reader, ct, nil, nil)
+ if err != nil {
+ fmt.Println(err.Error())
+ t.FailNow()
+ }
+
+ if !bytes.Equal(pt, message) {
+ fmt.Println("ecies: plaintext doesn't match message")
+ t.FailNow()
+ }
+
+ _, err = prv1.Decrypt(rand.Reader, ct, nil, nil)
+ if err == nil {
+ fmt.Println("ecies: encryption should not have succeeded")
+ t.FailNow()
+ }
+}
+
+// TestMarshalEncryption validates the encode/decode produces a valid
+// ECIES encryption key.
+func TestMarshalEncryption(t *testing.T) {
+ prv1, err := GenerateKey(rand.Reader, DefaultCurve, nil)
+ if err != nil {
+ fmt.Println(err.Error())
+ t.FailNow()
+ }
+
+ out, err := MarshalPrivate(prv1)
+ if err != nil {
+ fmt.Println(err.Error())
+ t.FailNow()
+ }
+
+ prv2, err := UnmarshalPrivate(out)
+ if err != nil {
+ fmt.Println(err.Error())
+ t.FailNow()
+ }
+
+ message := []byte("Hello, world.")
+ ct, err := Encrypt(rand.Reader, &prv2.PublicKey, message, nil, nil)
+ if err != nil {
+ fmt.Println(err.Error())
+ t.FailNow()
+ }
+
+ pt, err := prv2.Decrypt(rand.Reader, ct, nil, nil)
+ if err != nil {
+ fmt.Println(err.Error())
+ t.FailNow()
+ }
+
+ if !bytes.Equal(pt, message) {
+ fmt.Println("ecies: plaintext doesn't match message")
+ t.FailNow()
+ }
+
+ _, err = prv1.Decrypt(rand.Reader, ct, nil, nil)
+ if err != nil {
+ fmt.Println(err.Error())
+ t.FailNow()
+ }
+
+}
+
+type testCase struct {
+ Curve elliptic.Curve
+ Name string
+ Expected bool
+}
+
+var testCases = []testCase{
+ testCase{
+ Curve: elliptic.P224(),
+ Name: "P224",
+ Expected: false,
+ },
+ testCase{
+ Curve: elliptic.P256(),
+ Name: "P256",
+ Expected: true,
+ },
+ testCase{
+ Curve: elliptic.P384(),
+ Name: "P384",
+ Expected: true,
+ },
+ testCase{
+ Curve: elliptic.P521(),
+ Name: "P521",
+ Expected: true,
+ },
+}
+
+// Test parameter selection for each curve, and that P224 fails automatic
+// parameter selection (see README for a discussion of P224). Ensures that
+// selecting a set of parameters automatically for the given curve works.
+func TestParamSelection(t *testing.T) {
+ for _, c := range testCases {
+ testParamSelection(t, c)
+ }
+}
+
+func testParamSelection(t *testing.T, c testCase) {
+ params := ParamsFromCurve(c.Curve)
+ if params == nil && c.Expected {
+ fmt.Printf("%s (%s)\n", ErrInvalidParams.Error(), c.Name)
+ t.FailNow()
+ } else if params != nil && !c.Expected {
+ fmt.Printf("ecies: parameters should be invalid (%s)\n",
+ c.Name)
+ t.FailNow()
+ }
+
+ prv1, err := GenerateKey(rand.Reader, DefaultCurve, nil)
+ if err != nil {
+ fmt.Printf("%s (%s)\n", err.Error(), c.Name)
+ t.FailNow()
+ }
+
+ prv2, err := GenerateKey(rand.Reader, DefaultCurve, nil)
+ if err != nil {
+ fmt.Printf("%s (%s)\n", err.Error(), c.Name)
+ t.FailNow()
+ }
+
+ message := []byte("Hello, world.")
+ ct, err := Encrypt(rand.Reader, &prv2.PublicKey, message, nil, nil)
+ if err != nil {
+ fmt.Printf("%s (%s)\n", err.Error(), c.Name)
+ t.FailNow()
+ }
+
+ pt, err := prv2.Decrypt(rand.Reader, ct, nil, nil)
+ if err != nil {
+ fmt.Printf("%s (%s)\n", err.Error(), c.Name)
+ t.FailNow()
+ }
+
+ if !bytes.Equal(pt, message) {
+ fmt.Printf("ecies: plaintext doesn't match message (%s)\n",
+ c.Name)
+ t.FailNow()
+ }
+
+ _, err = prv1.Decrypt(rand.Reader, ct, nil, nil)
+ if err == nil {
+ fmt.Printf("ecies: encryption should not have succeeded (%s)\n",
+ c.Name)
+ t.FailNow()
+ }
+
+}
+
+// Ensure that the basic public key validation in the decryption operation
+// works.
+func TestBasicKeyValidation(t *testing.T) {
+ badBytes := []byte{0, 1, 5, 6, 7, 8, 9}
+
+ prv, err := GenerateKey(rand.Reader, DefaultCurve, nil)
+ if err != nil {
+ fmt.Println(err.Error())
+ t.FailNow()
+ }
+
+ message := []byte("Hello, world.")
+ ct, err := Encrypt(rand.Reader, &prv.PublicKey, message, nil, nil)
+ if err != nil {
+ fmt.Println(err.Error())
+ t.FailNow()
+ }
+
+ for _, b := range badBytes {
+ ct[0] = b
+ _, err := prv.Decrypt(rand.Reader, ct, nil, nil)
+ if err != ErrInvalidPublicKey {
+ fmt.Println("ecies: validated an invalid key")
+ t.FailNow()
+ }
+ }
+}
diff --git a/crypto/ecies/params.go b/crypto/ecies/params.go
new file mode 100644
index 000000000..fd1ceedd0
--- /dev/null
+++ b/crypto/ecies/params.go
@@ -0,0 +1,181 @@
+package ecies
+
+// This file contains parameters for ECIES encryption, specifying the
+// symmetric encryption and HMAC parameters.
+
+import (
+ "crypto"
+ "crypto/aes"
+ "crypto/cipher"
+ "crypto/elliptic"
+ "crypto/sha256"
+ "crypto/sha512"
+ "fmt"
+ "hash"
+)
+
+// The default curve for this package is the NIST P256 curve, which
+// provides security equivalent to AES-128.
+var DefaultCurve = elliptic.P256()
+
+var (
+ ErrUnsupportedECDHAlgorithm = fmt.Errorf("ecies: unsupported ECDH algorithm")
+ ErrUnsupportedECIESParameters = fmt.Errorf("ecies: unsupported ECIES parameters")
+)
+
+type ECIESParams struct {
+ Hash func() hash.Hash // hash function
+ hashAlgo crypto.Hash
+ Cipher func([]byte) (cipher.Block, error) // symmetric cipher
+ BlockSize int // block size of symmetric cipher
+ KeyLen int // length of symmetric key
+}
+
+// Standard ECIES parameters:
+// * ECIES using AES128 and HMAC-SHA-256-16
+// * ECIES using AES256 and HMAC-SHA-256-32
+// * ECIES using AES256 and HMAC-SHA-384-48
+// * ECIES using AES256 and HMAC-SHA-512-64
+
+var (
+ ECIES_AES128_SHA256 = &ECIESParams{
+ Hash: sha256.New,
+ hashAlgo: crypto.SHA256,
+ Cipher: aes.NewCipher,
+ BlockSize: aes.BlockSize,
+ KeyLen: 16,
+ }
+
+ ECIES_AES256_SHA256 = &ECIESParams{
+ Hash: sha256.New,
+ hashAlgo: crypto.SHA256,
+ Cipher: aes.NewCipher,
+ BlockSize: aes.BlockSize,
+ KeyLen: 32,
+ }
+
+ ECIES_AES256_SHA384 = &ECIESParams{
+ Hash: sha512.New384,
+ hashAlgo: crypto.SHA384,
+ Cipher: aes.NewCipher,
+ BlockSize: aes.BlockSize,
+ KeyLen: 32,
+ }
+
+ ECIES_AES256_SHA512 = &ECIESParams{
+ Hash: sha512.New,
+ hashAlgo: crypto.SHA512,
+ Cipher: aes.NewCipher,
+ BlockSize: aes.BlockSize,
+ KeyLen: 32,
+ }
+)
+
+var paramsFromCurve = map[elliptic.Curve]*ECIESParams{
+ elliptic.P256(): ECIES_AES128_SHA256,
+ elliptic.P384(): ECIES_AES256_SHA384,
+ elliptic.P521(): ECIES_AES256_SHA512,
+}
+
+func AddParamsForCurve(curve elliptic.Curve, params *ECIESParams) {
+ paramsFromCurve[curve] = params
+}
+
+// ParamsFromCurve selects parameters optimal for the selected elliptic curve.
+// Only the curves P256, P384, and P512 are supported.
+func ParamsFromCurve(curve elliptic.Curve) (params *ECIESParams) {
+ return paramsFromCurve[curve]
+
+ /*
+ switch curve {
+ case elliptic.P256():
+ return ECIES_AES128_SHA256
+ case elliptic.P384():
+ return ECIES_AES256_SHA384
+ case elliptic.P521():
+ return ECIES_AES256_SHA512
+ default:
+ return nil
+ }
+ */
+}
+
+// ASN.1 encode the ECIES parameters relevant to the encryption operations.
+func paramsToASNECIES(params *ECIESParams) (asnParams asnECIESParameters) {
+ if nil == params {
+ return
+ }
+ asnParams.KDF = asnNISTConcatenationKDF
+ asnParams.MAC = hmacFull
+ switch params.KeyLen {
+ case 16:
+ asnParams.Sym = aes128CTRinECIES
+ case 24:
+ asnParams.Sym = aes192CTRinECIES
+ case 32:
+ asnParams.Sym = aes256CTRinECIES
+ }
+ return
+}
+
+// ASN.1 encode the ECIES parameters relevant to ECDH.
+func paramsToASNECDH(params *ECIESParams) (algo asnECDHAlgorithm) {
+ switch params.hashAlgo {
+ case crypto.SHA224:
+ algo = dhSinglePass_stdDH_sha224kdf
+ case crypto.SHA256:
+ algo = dhSinglePass_stdDH_sha256kdf
+ case crypto.SHA384:
+ algo = dhSinglePass_stdDH_sha384kdf
+ case crypto.SHA512:
+ algo = dhSinglePass_stdDH_sha512kdf
+ }
+ return
+}
+
+// ASN.1 decode the ECIES parameters relevant to the encryption stage.
+func asnECIEStoParams(asnParams asnECIESParameters, params *ECIESParams) {
+ if !asnParams.KDF.Cmp(asnNISTConcatenationKDF) {
+ params = nil
+ return
+ } else if !asnParams.MAC.Cmp(hmacFull) {
+ params = nil
+ return
+ }
+
+ switch {
+ case asnParams.Sym.Cmp(aes128CTRinECIES):
+ params.KeyLen = 16
+ params.BlockSize = 16
+ params.Cipher = aes.NewCipher
+ case asnParams.Sym.Cmp(aes192CTRinECIES):
+ params.KeyLen = 24
+ params.BlockSize = 16
+ params.Cipher = aes.NewCipher
+ case asnParams.Sym.Cmp(aes256CTRinECIES):
+ params.KeyLen = 32
+ params.BlockSize = 16
+ params.Cipher = aes.NewCipher
+ default:
+ params = nil
+ }
+}
+
+// ASN.1 decode the ECIES parameters relevant to ECDH.
+func asnECDHtoParams(asnParams asnECDHAlgorithm, params *ECIESParams) {
+ if asnParams.Cmp(dhSinglePass_stdDH_sha224kdf) {
+ params.hashAlgo = crypto.SHA224
+ params.Hash = sha256.New224
+ } else if asnParams.Cmp(dhSinglePass_stdDH_sha256kdf) {
+ params.hashAlgo = crypto.SHA256
+ params.Hash = sha256.New
+ } else if asnParams.Cmp(dhSinglePass_stdDH_sha384kdf) {
+ params.hashAlgo = crypto.SHA384
+ params.Hash = sha512.New384
+ } else if asnParams.Cmp(dhSinglePass_stdDH_sha512kdf) {
+ params.hashAlgo = crypto.SHA512
+ params.Hash = sha512.New
+ } else {
+ params = nil
+ }
+}
diff --git a/crypto/encrypt_decrypt_test.go b/crypto/encrypt_decrypt_test.go
new file mode 100644
index 000000000..6e5b40a37
--- /dev/null
+++ b/crypto/encrypt_decrypt_test.go
@@ -0,0 +1,40 @@
+package crypto
+
+import (
+ "bytes"
+ "fmt"
+ "testing"
+
+ "github.com/ethereum/go-ethereum/common"
+)
+
+func TestBox(t *testing.T) {
+ prv1 := ToECDSA(common.Hex2Bytes("4b50fa71f5c3eeb8fdc452224b2395af2fcc3d125e06c32c82e048c0559db03f"))
+ prv2 := ToECDSA(common.Hex2Bytes("d0b043b4c5d657670778242d82d68a29d25d7d711127d17b8e299f156dad361a"))
+ pub2 := ToECDSAPub(common.Hex2Bytes("04bd27a63c91fe3233c5777e6d3d7b39204d398c8f92655947eb5a373d46e1688f022a1632d264725cbc7dc43ee1cfebde42fa0a86d08b55d2acfbb5e9b3b48dc5"))
+
+ message := []byte("Hello, world.")
+ ct, err := Encrypt(pub2, message)
+ if err != nil {
+ fmt.Println(err.Error())
+ t.FailNow()
+ }
+
+ pt, err := Decrypt(prv2, ct)
+ if err != nil {
+ fmt.Println(err.Error())
+ t.FailNow()
+ }
+
+ if !bytes.Equal(pt, message) {
+ fmt.Println("ecies: plaintext doesn't match message")
+ t.FailNow()
+ }
+
+ _, err = Decrypt(prv1, pt)
+ if err == nil {
+ fmt.Println("ecies: encryption should not have succeeded")
+ t.FailNow()
+ }
+
+}
diff --git a/crypto/key.go b/crypto/key.go
new file mode 100644
index 000000000..0b84bfec1
--- /dev/null
+++ b/crypto/key.go
@@ -0,0 +1,111 @@
+/*
+ This file is part of go-ethereum
+
+ go-ethereum is free software: you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published by
+ the Free Software Foundation, either version 3 of the License, or
+ (at your option) any later version.
+
+ go-ethereum is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with go-ethereum. If not, see <http://www.gnu.org/licenses/>.
+*/
+/**
+ * @authors
+ * Gustav Simonsson <gustav.simonsson@gmail.com>
+ * @date 2015
+ *
+ */
+
+package crypto
+
+import (
+ "bytes"
+ "crypto/ecdsa"
+ "encoding/json"
+ "io"
+
+ "code.google.com/p/go-uuid/uuid"
+)
+
+type Key struct {
+ Id uuid.UUID // Version 4 "random" for unique id not derived from key data
+ // to simplify lookups we also store the address
+ Address []byte
+ // we only store privkey as pubkey/address can be derived from it
+ // privkey in this struct is always in plaintext
+ PrivateKey *ecdsa.PrivateKey
+}
+
+type plainKeyJSON struct {
+ Id []byte
+ Address []byte
+ PrivateKey []byte
+}
+
+type cipherJSON struct {
+ Salt []byte
+ IV []byte
+ CipherText []byte
+}
+
+type encryptedKeyJSON struct {
+ Id []byte
+ Address []byte
+ Crypto cipherJSON
+}
+
+func (k *Key) MarshalJSON() (j []byte, err error) {
+ jStruct := plainKeyJSON{
+ k.Id,
+ k.Address,
+ FromECDSA(k.PrivateKey),
+ }
+ j, err = json.Marshal(jStruct)
+ return j, err
+}
+
+func (k *Key) UnmarshalJSON(j []byte) (err error) {
+ keyJSON := new(plainKeyJSON)
+ err = json.Unmarshal(j, &keyJSON)
+ if err != nil {
+ return err
+ }
+
+ u := new(uuid.UUID)
+ *u = keyJSON.Id
+ k.Id = *u
+ k.Address = keyJSON.Address
+ k.PrivateKey = ToECDSA(keyJSON.PrivateKey)
+
+ return err
+}
+
+func NewKeyFromECDSA(privateKeyECDSA *ecdsa.PrivateKey) *Key {
+ id := uuid.NewRandom()
+ key := &Key{
+ Id: id,
+ Address: PubkeyToAddress(privateKeyECDSA.PublicKey),
+ PrivateKey: privateKeyECDSA,
+ }
+ return key
+}
+
+func NewKey(rand io.Reader) *Key {
+ randBytes := make([]byte, 64)
+ _, err := rand.Read(randBytes)
+ if err != nil {
+ panic("key generation: could not read from random source: " + err.Error())
+ }
+ reader := bytes.NewReader(randBytes)
+ privateKeyECDSA, err := ecdsa.GenerateKey(S256(), reader)
+ if err != nil {
+ panic("key generation: ecdsa.GenerateKey failed: " + err.Error())
+ }
+
+ return NewKeyFromECDSA(privateKeyECDSA)
+}
diff --git a/crypto/key_store_passphrase.go b/crypto/key_store_passphrase.go
new file mode 100644
index 000000000..7d21b6604
--- /dev/null
+++ b/crypto/key_store_passphrase.go
@@ -0,0 +1,200 @@
+/*
+ This file is part of go-ethereum
+
+ go-ethereum is free software: you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published by
+ the Free Software Foundation, either version 3 of the License, or
+ (at your option) any later version.
+
+ go-ethereum is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with go-ethereum. If not, see <http://www.gnu.org/licenses/>.
+*/
+/**
+ * @authors
+ * Gustav Simonsson <gustav.simonsson@gmail.com>
+ * @date 2015
+ *
+ */
+
+/*
+
+This key store behaves as KeyStorePlain with the difference that
+the private key is encrypted and on disk uses another JSON encoding.
+
+Cryptography:
+
+1. Encryption key is scrypt derived key from user passphrase. Scrypt parameters
+ (work factors) [1][2] are defined as constants below.
+2. Scrypt salt is 32 random bytes from CSPRNG. It is appended to ciphertext.
+3. Checksum is SHA3 of the private key bytes.
+4. Plaintext is concatenation of private key bytes and checksum.
+5. Encryption algo is AES 256 CBC [3][4]
+6. CBC IV is 16 random bytes from CSPRNG. It is appended to ciphertext.
+7. Plaintext padding is PKCS #7 [5][6]
+
+Encoding:
+
+1. On disk, ciphertext, salt and IV are encoded in a nested JSON object.
+ cat a key file to see the structure.
+2. byte arrays are base64 JSON strings.
+3. The EC private key bytes are in uncompressed form [7].
+ They are a big-endian byte slice of the absolute value of D [8][9].
+4. The checksum is the last 32 bytes of the plaintext byte array and the
+ private key is the preceeding bytes.
+
+References:
+
+1. http://www.tarsnap.com/scrypt/scrypt-slides.pdf
+2. http://stackoverflow.com/questions/11126315/what-are-optimal-scrypt-work-factors
+3. http://en.wikipedia.org/wiki/Advanced_Encryption_Standard
+4. http://en.wikipedia.org/wiki/Block_cipher_mode_of_operation#Cipher-block_chaining_.28CBC.29
+5. https://leanpub.com/gocrypto/read#leanpub-auto-block-cipher-modes
+6. http://tools.ietf.org/html/rfc2315
+7. http://bitcoin.stackexchange.com/questions/3059/what-is-a-compressed-bitcoin-key
+8. http://golang.org/pkg/crypto/ecdsa/#PrivateKey
+9. https://golang.org/pkg/math/big/#Int.Bytes
+
+*/
+
+package crypto
+
+import (
+ "bytes"
+ "crypto/aes"
+ "crypto/cipher"
+ "encoding/hex"
+ "encoding/json"
+ "errors"
+ "io"
+ "os"
+ "path"
+
+ "code.google.com/p/go-uuid/uuid"
+ "github.com/ethereum/go-ethereum/crypto/randentropy"
+ "golang.org/x/crypto/scrypt"
+)
+
+const (
+ // 2^18 / 8 / 1 uses 256MB memory and approx 1s CPU time on a modern CPU.
+ scryptN = 1 << 18
+ scryptr = 8
+ scryptp = 1
+ scryptdkLen = 32
+)
+
+type keyStorePassphrase struct {
+ keysDirPath string
+}
+
+func NewKeyStorePassphrase(path string) KeyStore2 {
+ return &keyStorePassphrase{path}
+}
+
+func (ks keyStorePassphrase) GenerateNewKey(rand io.Reader, auth string) (key *Key, err error) {
+ return GenerateNewKeyDefault(ks, rand, auth)
+}
+
+func (ks keyStorePassphrase) GetKey(keyAddr []byte, auth string) (key *Key, err error) {
+ keyBytes, keyId, err := DecryptKey(ks, keyAddr, auth)
+ if err != nil {
+ return nil, err
+ }
+ key = &Key{
+ Id: uuid.UUID(keyId),
+ Address: keyAddr,
+ PrivateKey: ToECDSA(keyBytes),
+ }
+ return key, err
+}
+
+func (ks keyStorePassphrase) GetKeyAddresses() (addresses [][]byte, err error) {
+ return GetKeyAddresses(ks.keysDirPath)
+}
+
+func (ks keyStorePassphrase) StoreKey(key *Key, auth string) (err error) {
+ authArray := []byte(auth)
+ salt := randentropy.GetEntropyMixed(32)
+ derivedKey, err := scrypt.Key(authArray, salt, scryptN, scryptr, scryptp, scryptdkLen)
+ if err != nil {
+ return err
+ }
+
+ keyBytes := FromECDSA(key.PrivateKey)
+ keyBytesHash := Sha3(keyBytes)
+ toEncrypt := PKCS7Pad(append(keyBytes, keyBytesHash...))
+
+ AES256Block, err := aes.NewCipher(derivedKey)
+ if err != nil {
+ return err
+ }
+
+ iv := randentropy.GetEntropyMixed(aes.BlockSize) // 16
+ AES256CBCEncrypter := cipher.NewCBCEncrypter(AES256Block, iv)
+ cipherText := make([]byte, len(toEncrypt))
+ AES256CBCEncrypter.CryptBlocks(cipherText, toEncrypt)
+
+ cipherStruct := cipherJSON{
+ salt,
+ iv,
+ cipherText,
+ }
+ keyStruct := encryptedKeyJSON{
+ key.Id,
+ key.Address,
+ cipherStruct,
+ }
+ keyJSON, err := json.Marshal(keyStruct)
+ if err != nil {
+ return err
+ }
+
+ return WriteKeyFile(key.Address, ks.keysDirPath, keyJSON)
+}
+
+func (ks keyStorePassphrase) DeleteKey(keyAddr []byte, auth string) (err error) {
+ // only delete if correct passphrase is given
+ _, _, err = DecryptKey(ks, keyAddr, auth)
+ if err != nil {
+ return err
+ }
+
+ keyDirPath := path.Join(ks.keysDirPath, hex.EncodeToString(keyAddr))
+ return os.RemoveAll(keyDirPath)
+}
+
+func DecryptKey(ks keyStorePassphrase, keyAddr []byte, auth string) (keyBytes []byte, keyId []byte, err error) {
+ fileContent, err := GetKeyFile(ks.keysDirPath, keyAddr)
+ if err != nil {
+ return nil, nil, err
+ }
+
+ keyProtected := new(encryptedKeyJSON)
+ err = json.Unmarshal(fileContent, keyProtected)
+
+ keyId = keyProtected.Id
+ salt := keyProtected.Crypto.Salt
+ iv := keyProtected.Crypto.IV
+ cipherText := keyProtected.Crypto.CipherText
+
+ authArray := []byte(auth)
+ derivedKey, err := scrypt.Key(authArray, salt, scryptN, scryptr, scryptp, scryptdkLen)
+ if err != nil {
+ return nil, nil, err
+ }
+ plainText, err := aesCBCDecrypt(derivedKey, cipherText, iv)
+ if err != nil {
+ return nil, nil, err
+ }
+ keyBytes = plainText[:len(plainText)-32]
+ keyBytesHash := plainText[len(plainText)-32:]
+ if !bytes.Equal(Sha3(keyBytes), keyBytesHash) {
+ err = errors.New("Decryption failed: checksum mismatch")
+ return nil, nil, err
+ }
+ return keyBytes, keyId, err
+}
diff --git a/crypto/key_store_plain.go b/crypto/key_store_plain.go
new file mode 100644
index 000000000..338a4a2c3
--- /dev/null
+++ b/crypto/key_store_plain.go
@@ -0,0 +1,129 @@
+/*
+ This file is part of go-ethereum
+
+ go-ethereum is free software: you can redistribute it and/or modify
+ it under the terms of the GNU Lesser General Public License as published by
+ the Free Software Foundation, either version 3 of the License, or
+ (at your option) any later version.
+
+ go-ethereum is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public License
+ along with go-ethereum. If not, see <http://www.gnu.org/licenses/>.
+*/
+/**
+ * @authors
+ * Gustav Simonsson <gustav.simonsson@gmail.com>
+ * @date 2015
+ *
+ */
+
+package crypto
+
+import (
+ "encoding/hex"
+ "encoding/json"
+ "fmt"
+ "io"
+ "io/ioutil"
+ "os"
+ "path"
+)
+
+// TODO: rename to KeyStore when replacing existing KeyStore
+type KeyStore2 interface {
+ // create new key using io.Reader entropy source and optionally using auth string
+ GenerateNewKey(io.Reader, string) (*Key, error)
+ GetKey([]byte, string) (*Key, error) // key from addr and auth string
+ GetKeyAddresses() ([][]byte, error) // get all addresses
+ StoreKey(*Key, string) error // store key optionally using auth string
+ DeleteKey([]byte, string) error // delete key by addr and auth string
+}
+
+type keyStorePlain struct {
+ keysDirPath string
+}
+
+func NewKeyStorePlain(path string) KeyStore2 {
+ return &keyStorePlain{path}
+}
+
+func (ks keyStorePlain) GenerateNewKey(rand io.Reader, auth string) (key *Key, err error) {
+ return GenerateNewKeyDefault(ks, rand, auth)
+}
+
+func GenerateNewKeyDefault(ks KeyStore2, rand io.Reader, auth string) (key *Key, err error) {
+ defer func() {
+ if r := recover(); r != nil {
+ err = fmt.Errorf("GenerateNewKey error: %v", r)
+ }
+ }()
+ key = NewKey(rand)
+ err = ks.StoreKey(key, auth)
+ return key, err
+}
+
+func (ks keyStorePlain) GetKey(keyAddr []byte, auth string) (key *Key, err error) {
+ fileContent, err := GetKeyFile(ks.keysDirPath, keyAddr)
+ if err != nil {
+ return nil, err
+ }
+
+ key = new(Key)
+ err = json.Unmarshal(fileContent, key)
+ return key, err
+}
+
+func (ks keyStorePlain) GetKeyAddresses() (addresses [][]byte, err error) {
+ return GetKeyAddresses(ks.keysDirPath)
+}
+
+func (ks keyStorePlain) StoreKey(key *Key, auth string) (err error) {
+ keyJSON, err := json.Marshal(key)
+ if err != nil {
+ return err
+ }
+ err = WriteKeyFile(key.Address, ks.keysDirPath, keyJSON)
+ return err
+}
+
+func (ks keyStorePlain) DeleteKey(keyAddr []byte, auth string) (err error) {
+ keyDirPath := path.Join(ks.keysDirPath, hex.EncodeToString(keyAddr))
+ err = os.RemoveAll(keyDirPath)
+ return err
+}
+
+func GetKeyFile(keysDirPath string, keyAddr []byte) (fileContent []byte, err error) {
+ fileName := hex.EncodeToString(keyAddr)
+ return ioutil.ReadFile(path.Join(keysDirPath, fileName, fileName))
+}
+
+func WriteKeyFile(addr []byte, keysDirPath string, content []byte) (err error) {
+ addrHex := hex.EncodeToString(addr)
+ keyDirPath := path.Join(keysDirPath, addrHex)
+ keyFilePath := path.Join(keyDirPath, addrHex)
+ err = os.MkdirAll(keyDirPath, 0700) // read, write and dir search for user
+ if err != nil {
+ return err
+ }
+ return ioutil.WriteFile(keyFilePath, content, 0600) // read, write for user
+}
+
+func GetKeyAddresses(keysDirPath string) (addresses [][]byte, err error) {
+ fileInfos, err := ioutil.ReadDir(keysDirPath)
+ if err != nil {
+ return nil, err
+ }
+ addresses = make([][]byte, len(fileInfos))
+ for i, fileInfo := range fileInfos {
+ address, err := hex.DecodeString(fileInfo.Name())
+ if err != nil {
+ continue
+ }
+ addresses[i] = address
+ }
+ return addresses, err
+}
diff --git a/crypto/key_store_test.go b/crypto/key_store_test.go
new file mode 100644
index 000000000..f0a1e567b
--- /dev/null
+++ b/crypto/key_store_test.go
@@ -0,0 +1,99 @@
+package crypto
+
+import (
+ "github.com/ethereum/go-ethereum/crypto/randentropy"
+ "github.com/ethereum/go-ethereum/common"
+ "reflect"
+ "testing"
+)
+
+func TestKeyStorePlain(t *testing.T) {
+ ks := NewKeyStorePlain(common.DefaultDataDir())
+ pass := "" // not used but required by API
+ k1, err := ks.GenerateNewKey(randentropy.Reader, pass)
+ if err != nil {
+ t.Fatal(err)
+ }
+
+ k2 := new(Key)
+ k2, err = ks.GetKey(k1.Address, pass)
+ if err != nil {
+ t.Fatal(err)
+ }
+
+ if !reflect.DeepEqual(k1.Address, k2.Address) {
+ t.Fatal(err)
+ }
+
+ if !reflect.DeepEqual(k1.PrivateKey, k2.PrivateKey) {
+ t.Fatal(err)
+ }
+
+ err = ks.DeleteKey(k2.Address, pass)
+ if err != nil {
+ t.Fatal(err)
+ }
+}
+
+func TestKeyStorePassphrase(t *testing.T) {
+ ks := NewKeyStorePassphrase(common.DefaultDataDir())
+ pass := "foo"
+ k1, err := ks.GenerateNewKey(randentropy.Reader, pass)
+ if err != nil {
+ t.Fatal(err)
+ }
+ k2 := new(Key)
+ k2, err = ks.GetKey(k1.Address, pass)
+ if err != nil {
+ t.Fatal(err)
+ }
+ if !reflect.DeepEqual(k1.Address, k2.Address) {
+ t.Fatal(err)
+ }
+
+ if !reflect.DeepEqual(k1.PrivateKey, k2.PrivateKey) {
+ t.Fatal(err)
+ }
+
+ err = ks.DeleteKey(k2.Address, pass) // also to clean up created files
+ if err != nil {
+ t.Fatal(err)
+ }
+}
+
+func TestKeyStorePassphraseDecryptionFail(t *testing.T) {
+ ks := NewKeyStorePassphrase(common.DefaultDataDir())
+ pass := "foo"
+ k1, err := ks.GenerateNewKey(randentropy.Reader, pass)
+ if err != nil {
+ t.Fatal(err)
+ }
+
+ _, err = ks.GetKey(k1.Address, "bar") // wrong passphrase
+ if err == nil {
+ t.Fatal(err)
+ }
+
+ err = ks.DeleteKey(k1.Address, "bar") // wrong passphrase
+ if err == nil {
+ t.Fatal(err)
+ }
+
+ err = ks.DeleteKey(k1.Address, pass) // to clean up
+ if err != nil {
+ t.Fatal(err)
+ }
+}
+
+func TestImportPreSaleKey(t *testing.T) {
+ // file content of a presale key file generated with:
+ // python pyethsaletool.py genwallet
+ // with password "foo"
+ fileContent := "{\"encseed\": \"26d87f5f2bf9835f9a47eefae571bc09f9107bb13d54ff12a4ec095d01f83897494cf34f7bed2ed34126ecba9db7b62de56c9d7cd136520a0427bfb11b8954ba7ac39b90d4650d3448e31185affcd74226a68f1e94b1108e6e0a4a91cdd83eba\", \"ethaddr\": \"d4584b5f6229b7be90727b0fc8c6b91bb427821f\", \"email\": \"gustav.simonsson@gmail.com\", \"btcaddr\": \"1EVknXyFC68kKNLkh6YnKzW41svSRoaAcx\"}"
+ ks := NewKeyStorePassphrase(common.DefaultDataDir())
+ pass := "foo"
+ _, err := ImportPreSaleKey(ks, []byte(fileContent), pass)
+ if err != nil {
+ t.Fatal(err)
+ }
+}
diff --git a/crypto/keypair.go b/crypto/keypair.go
new file mode 100644
index 000000000..cc17328cb
--- /dev/null
+++ b/crypto/keypair.go
@@ -0,0 +1,50 @@
+package crypto
+
+import (
+ "strings"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/crypto/secp256k1"
+)
+
+type KeyPair struct {
+ PrivateKey []byte
+ PublicKey []byte
+ address []byte
+ mnemonic string
+ // The associated account
+ // account *StateObject
+}
+
+func GenerateNewKeyPair() *KeyPair {
+ _, prv := secp256k1.GenerateKeyPair()
+ keyPair, _ := NewKeyPairFromSec(prv) // swallow error, this one cannot err
+ return keyPair
+}
+
+func NewKeyPairFromSec(seckey []byte) (*KeyPair, error) {
+ pubkey, err := secp256k1.GeneratePubKey(seckey)
+ if err != nil {
+ return nil, err
+ }
+
+ return &KeyPair{PrivateKey: seckey, PublicKey: pubkey}, nil
+}
+
+func (k *KeyPair) Address() []byte {
+ if k.address == nil {
+ k.address = Sha3(k.PublicKey[1:])[12:]
+ }
+ return k.address
+}
+
+func (k *KeyPair) Mnemonic() string {
+ if k.mnemonic == "" {
+ k.mnemonic = strings.Join(MnemonicEncode(common.Bytes2Hex(k.PrivateKey)), " ")
+ }
+ return k.mnemonic
+}
+
+func (k *KeyPair) AsStrings() (string, string, string, string) {
+ return k.Mnemonic(), common.Bytes2Hex(k.Address()), common.Bytes2Hex(k.PrivateKey), common.Bytes2Hex(k.PublicKey)
+}
diff --git a/crypto/mnemonic.go b/crypto/mnemonic.go
new file mode 100644
index 000000000..0d690f245
--- /dev/null
+++ b/crypto/mnemonic.go
@@ -0,0 +1,60 @@
+package crypto
+
+import (
+ "fmt"
+ "strconv"
+)
+
+// TODO: See if we can refactor this into a shared util lib if we need it multiple times
+func IndexOf(slice []string, value string) int64 {
+ for p, v := range slice {
+ if v == value {
+ return int64(p)
+ }
+ }
+ return -1
+}
+
+func MnemonicEncode(message string) []string {
+ var out []string
+ n := int64(len(MnemonicWords))
+
+ for i := 0; i < len(message); i += (len(message) / 8) {
+ x := message[i : i+8]
+ bit, _ := strconv.ParseInt(x, 16, 64)
+ w1 := (bit % n)
+ w2 := ((bit / n) + w1) % n
+ w3 := ((bit / n / n) + w2) % n
+ out = append(out, MnemonicWords[w1], MnemonicWords[w2], MnemonicWords[w3])
+ }
+ return out
+}
+
+func MnemonicDecode(wordsar []string) string {
+ var out string
+ n := int64(len(MnemonicWords))
+
+ for i := 0; i < len(wordsar); i += 3 {
+ word1 := wordsar[i]
+ word2 := wordsar[i+1]
+ word3 := wordsar[i+2]
+ w1 := IndexOf(MnemonicWords, word1)
+ w2 := IndexOf(MnemonicWords, word2)
+ w3 := IndexOf(MnemonicWords, word3)
+
+ y := (w2 - w1) % n
+ z := (w3 - w2) % n
+
+ // Golang handles modulo with negative numbers different then most languages
+ // The modulo can be negative, we don't want that.
+ if z < 0 {
+ z += n
+ }
+ if y < 0 {
+ y += n
+ }
+ x := w1 + n*(y) + n*n*(z)
+ out += fmt.Sprintf("%08x", x)
+ }
+ return out
+}
diff --git a/crypto/mnemonic_test.go b/crypto/mnemonic_test.go
new file mode 100644
index 000000000..beff476e0
--- /dev/null
+++ b/crypto/mnemonic_test.go
@@ -0,0 +1,74 @@
+package crypto
+
+import (
+ "testing"
+)
+
+func TestMnDecode(t *testing.T) {
+ words := []string{
+ "ink",
+ "balance",
+ "gain",
+ "fear",
+ "happen",
+ "melt",
+ "mom",
+ "surface",
+ "stir",
+ "bottle",
+ "unseen",
+ "expression",
+ "important",
+ "curl",
+ "grant",
+ "fairy",
+ "across",
+ "back",
+ "figure",
+ "breast",
+ "nobody",
+ "scratch",
+ "worry",
+ "yesterday",
+ }
+ encode := "c61d43dc5bb7a4e754d111dae8105b6f25356492df5e50ecb33b858d94f8c338"
+ result := MnemonicDecode(words)
+ if encode != result {
+ t.Error("We expected", encode, "got", result, "instead")
+ }
+}
+func TestMnEncode(t *testing.T) {
+ encode := "c61d43dc5bb7a4e754d111dae8105b6f25356492df5e50ecb33b858d94f8c338"
+ result := []string{
+ "ink",
+ "balance",
+ "gain",
+ "fear",
+ "happen",
+ "melt",
+ "mom",
+ "surface",
+ "stir",
+ "bottle",
+ "unseen",
+ "expression",
+ "important",
+ "curl",
+ "grant",
+ "fairy",
+ "across",
+ "back",
+ "figure",
+ "breast",
+ "nobody",
+ "scratch",
+ "worry",
+ "yesterday",
+ }
+ words := MnemonicEncode(encode)
+ for i, word := range words {
+ if word != result[i] {
+ t.Error("Mnenonic does not match:", words, result)
+ }
+ }
+}
diff --git a/crypto/mnemonic_words.go b/crypto/mnemonic_words.go
new file mode 100644
index 000000000..ebd0d2690
--- /dev/null
+++ b/crypto/mnemonic_words.go
@@ -0,0 +1,1630 @@
+package crypto
+
+var MnemonicWords []string = []string{
+ "like",
+ "just",
+ "love",
+ "know",
+ "never",
+ "want",
+ "time",
+ "out",
+ "there",
+ "make",
+ "look",
+ "eye",
+ "down",
+ "only",
+ "think",
+ "heart",
+ "back",
+ "then",
+ "into",
+ "about",
+ "more",
+ "away",
+ "still",
+ "them",
+ "take",
+ "thing",
+ "even",
+ "through",
+ "long",
+ "always",
+ "world",
+ "too",
+ "friend",
+ "tell",
+ "try",
+ "hand",
+ "thought",
+ "over",
+ "here",
+ "other",
+ "need",
+ "smile",
+ "again",
+ "much",
+ "cry",
+ "been",
+ "night",
+ "ever",
+ "little",
+ "said",
+ "end",
+ "some",
+ "those",
+ "around",
+ "mind",
+ "people",
+ "girl",
+ "leave",
+ "dream",
+ "left",
+ "turn",
+ "myself",
+ "give",
+ "nothing",
+ "really",
+ "off",
+ "before",
+ "something",
+ "find",
+ "walk",
+ "wish",
+ "good",
+ "once",
+ "place",
+ "ask",
+ "stop",
+ "keep",
+ "watch",
+ "seem",
+ "everything",
+ "wait",
+ "got",
+ "yet",
+ "made",
+ "remember",
+ "start",
+ "alone",
+ "run",
+ "hope",
+ "maybe",
+ "believe",
+ "body",
+ "hate",
+ "after",
+ "close",
+ "talk",
+ "stand",
+ "own",
+ "each",
+ "hurt",
+ "help",
+ "home",
+ "god",
+ "soul",
+ "new",
+ "many",
+ "two",
+ "inside",
+ "should",
+ "true",
+ "first",
+ "fear",
+ "mean",
+ "better",
+ "play",
+ "another",
+ "gone",
+ "change",
+ "use",
+ "wonder",
+ "someone",
+ "hair",
+ "cold",
+ "open",
+ "best",
+ "any",
+ "behind",
+ "happen",
+ "water",
+ "dark",
+ "laugh",
+ "stay",
+ "forever",
+ "name",
+ "work",
+ "show",
+ "sky",
+ "break",
+ "came",
+ "deep",
+ "door",
+ "put",
+ "black",
+ "together",
+ "upon",
+ "happy",
+ "such",
+ "great",
+ "white",
+ "matter",
+ "fill",
+ "past",
+ "please",
+ "burn",
+ "cause",
+ "enough",
+ "touch",
+ "moment",
+ "soon",
+ "voice",
+ "scream",
+ "anything",
+ "stare",
+ "sound",
+ "red",
+ "everyone",
+ "hide",
+ "kiss",
+ "truth",
+ "death",
+ "beautiful",
+ "mine",
+ "blood",
+ "broken",
+ "very",
+ "pass",
+ "next",
+ "forget",
+ "tree",
+ "wrong",
+ "air",
+ "mother",
+ "understand",
+ "lip",
+ "hit",
+ "wall",
+ "memory",
+ "sleep",
+ "free",
+ "high",
+ "realize",
+ "school",
+ "might",
+ "skin",
+ "sweet",
+ "perfect",
+ "blue",
+ "kill",
+ "breath",
+ "dance",
+ "against",
+ "fly",
+ "between",
+ "grow",
+ "strong",
+ "under",
+ "listen",
+ "bring",
+ "sometimes",
+ "speak",
+ "pull",
+ "person",
+ "become",
+ "family",
+ "begin",
+ "ground",
+ "real",
+ "small",
+ "father",
+ "sure",
+ "feet",
+ "rest",
+ "young",
+ "finally",
+ "land",
+ "across",
+ "today",
+ "different",
+ "guy",
+ "line",
+ "fire",
+ "reason",
+ "reach",
+ "second",
+ "slowly",
+ "write",
+ "eat",
+ "smell",
+ "mouth",
+ "step",
+ "learn",
+ "three",
+ "floor",
+ "promise",
+ "breathe",
+ "darkness",
+ "push",
+ "earth",
+ "guess",
+ "save",
+ "song",
+ "above",
+ "along",
+ "both",
+ "color",
+ "house",
+ "almost",
+ "sorry",
+ "anymore",
+ "brother",
+ "okay",
+ "dear",
+ "game",
+ "fade",
+ "already",
+ "apart",
+ "warm",
+ "beauty",
+ "heard",
+ "notice",
+ "question",
+ "shine",
+ "began",
+ "piece",
+ "whole",
+ "shadow",
+ "secret",
+ "street",
+ "within",
+ "finger",
+ "point",
+ "morning",
+ "whisper",
+ "child",
+ "moon",
+ "green",
+ "story",
+ "glass",
+ "kid",
+ "silence",
+ "since",
+ "soft",
+ "yourself",
+ "empty",
+ "shall",
+ "angel",
+ "answer",
+ "baby",
+ "bright",
+ "dad",
+ "path",
+ "worry",
+ "hour",
+ "drop",
+ "follow",
+ "power",
+ "war",
+ "half",
+ "flow",
+ "heaven",
+ "act",
+ "chance",
+ "fact",
+ "least",
+ "tired",
+ "children",
+ "near",
+ "quite",
+ "afraid",
+ "rise",
+ "sea",
+ "taste",
+ "window",
+ "cover",
+ "nice",
+ "trust",
+ "lot",
+ "sad",
+ "cool",
+ "force",
+ "peace",
+ "return",
+ "blind",
+ "easy",
+ "ready",
+ "roll",
+ "rose",
+ "drive",
+ "held",
+ "music",
+ "beneath",
+ "hang",
+ "mom",
+ "paint",
+ "emotion",
+ "quiet",
+ "clear",
+ "cloud",
+ "few",
+ "pretty",
+ "bird",
+ "outside",
+ "paper",
+ "picture",
+ "front",
+ "rock",
+ "simple",
+ "anyone",
+ "meant",
+ "reality",
+ "road",
+ "sense",
+ "waste",
+ "bit",
+ "leaf",
+ "thank",
+ "happiness",
+ "meet",
+ "men",
+ "smoke",
+ "truly",
+ "decide",
+ "self",
+ "age",
+ "book",
+ "form",
+ "alive",
+ "carry",
+ "escape",
+ "damn",
+ "instead",
+ "able",
+ "ice",
+ "minute",
+ "throw",
+ "catch",
+ "leg",
+ "ring",
+ "course",
+ "goodbye",
+ "lead",
+ "poem",
+ "sick",
+ "corner",
+ "desire",
+ "known",
+ "problem",
+ "remind",
+ "shoulder",
+ "suppose",
+ "toward",
+ "wave",
+ "drink",
+ "jump",
+ "woman",
+ "pretend",
+ "sister",
+ "week",
+ "human",
+ "joy",
+ "crack",
+ "grey",
+ "pray",
+ "surprise",
+ "dry",
+ "knee",
+ "less",
+ "search",
+ "bleed",
+ "caught",
+ "clean",
+ "embrace",
+ "future",
+ "king",
+ "son",
+ "sorrow",
+ "chest",
+ "hug",
+ "remain",
+ "sat",
+ "worth",
+ "blow",
+ "daddy",
+ "final",
+ "parent",
+ "tight",
+ "also",
+ "create",
+ "lonely",
+ "safe",
+ "cross",
+ "dress",
+ "evil",
+ "silent",
+ "bone",
+ "fate",
+ "perhaps",
+ "anger",
+ "class",
+ "scar",
+ "snow",
+ "tiny",
+ "tonight",
+ "continue",
+ "control",
+ "dog",
+ "edge",
+ "mirror",
+ "month",
+ "suddenly",
+ "comfort",
+ "given",
+ "loud",
+ "quickly",
+ "gaze",
+ "plan",
+ "rush",
+ "stone",
+ "town",
+ "battle",
+ "ignore",
+ "spirit",
+ "stood",
+ "stupid",
+ "yours",
+ "brown",
+ "build",
+ "dust",
+ "hey",
+ "kept",
+ "pay",
+ "phone",
+ "twist",
+ "although",
+ "ball",
+ "beyond",
+ "hidden",
+ "nose",
+ "taken",
+ "fail",
+ "float",
+ "pure",
+ "somehow",
+ "wash",
+ "wrap",
+ "angry",
+ "cheek",
+ "creature",
+ "forgotten",
+ "heat",
+ "rip",
+ "single",
+ "space",
+ "special",
+ "weak",
+ "whatever",
+ "yell",
+ "anyway",
+ "blame",
+ "job",
+ "choose",
+ "country",
+ "curse",
+ "drift",
+ "echo",
+ "figure",
+ "grew",
+ "laughter",
+ "neck",
+ "suffer",
+ "worse",
+ "yeah",
+ "disappear",
+ "foot",
+ "forward",
+ "knife",
+ "mess",
+ "somewhere",
+ "stomach",
+ "storm",
+ "beg",
+ "idea",
+ "lift",
+ "offer",
+ "breeze",
+ "field",
+ "five",
+ "often",
+ "simply",
+ "stuck",
+ "win",
+ "allow",
+ "confuse",
+ "enjoy",
+ "except",
+ "flower",
+ "seek",
+ "strength",
+ "calm",
+ "grin",
+ "gun",
+ "heavy",
+ "hill",
+ "large",
+ "ocean",
+ "shoe",
+ "sigh",
+ "straight",
+ "summer",
+ "tongue",
+ "accept",
+ "crazy",
+ "everyday",
+ "exist",
+ "grass",
+ "mistake",
+ "sent",
+ "shut",
+ "surround",
+ "table",
+ "ache",
+ "brain",
+ "destroy",
+ "heal",
+ "nature",
+ "shout",
+ "sign",
+ "stain",
+ "choice",
+ "doubt",
+ "glance",
+ "glow",
+ "mountain",
+ "queen",
+ "stranger",
+ "throat",
+ "tomorrow",
+ "city",
+ "either",
+ "fish",
+ "flame",
+ "rather",
+ "shape",
+ "spin",
+ "spread",
+ "ash",
+ "distance",
+ "finish",
+ "image",
+ "imagine",
+ "important",
+ "nobody",
+ "shatter",
+ "warmth",
+ "became",
+ "feed",
+ "flesh",
+ "funny",
+ "lust",
+ "shirt",
+ "trouble",
+ "yellow",
+ "attention",
+ "bare",
+ "bite",
+ "money",
+ "protect",
+ "amaze",
+ "appear",
+ "born",
+ "choke",
+ "completely",
+ "daughter",
+ "fresh",
+ "friendship",
+ "gentle",
+ "probably",
+ "six",
+ "deserve",
+ "expect",
+ "grab",
+ "middle",
+ "nightmare",
+ "river",
+ "thousand",
+ "weight",
+ "worst",
+ "wound",
+ "barely",
+ "bottle",
+ "cream",
+ "regret",
+ "relationship",
+ "stick",
+ "test",
+ "crush",
+ "endless",
+ "fault",
+ "itself",
+ "rule",
+ "spill",
+ "art",
+ "circle",
+ "join",
+ "kick",
+ "mask",
+ "master",
+ "passion",
+ "quick",
+ "raise",
+ "smooth",
+ "unless",
+ "wander",
+ "actually",
+ "broke",
+ "chair",
+ "deal",
+ "favorite",
+ "gift",
+ "note",
+ "number",
+ "sweat",
+ "box",
+ "chill",
+ "clothes",
+ "lady",
+ "mark",
+ "park",
+ "poor",
+ "sadness",
+ "tie",
+ "animal",
+ "belong",
+ "brush",
+ "consume",
+ "dawn",
+ "forest",
+ "innocent",
+ "pen",
+ "pride",
+ "stream",
+ "thick",
+ "clay",
+ "complete",
+ "count",
+ "draw",
+ "faith",
+ "press",
+ "silver",
+ "struggle",
+ "surface",
+ "taught",
+ "teach",
+ "wet",
+ "bless",
+ "chase",
+ "climb",
+ "enter",
+ "letter",
+ "melt",
+ "metal",
+ "movie",
+ "stretch",
+ "swing",
+ "vision",
+ "wife",
+ "beside",
+ "crash",
+ "forgot",
+ "guide",
+ "haunt",
+ "joke",
+ "knock",
+ "plant",
+ "pour",
+ "prove",
+ "reveal",
+ "steal",
+ "stuff",
+ "trip",
+ "wood",
+ "wrist",
+ "bother",
+ "bottom",
+ "crawl",
+ "crowd",
+ "fix",
+ "forgive",
+ "frown",
+ "grace",
+ "loose",
+ "lucky",
+ "party",
+ "release",
+ "surely",
+ "survive",
+ "teacher",
+ "gently",
+ "grip",
+ "speed",
+ "suicide",
+ "travel",
+ "treat",
+ "vein",
+ "written",
+ "cage",
+ "chain",
+ "conversation",
+ "date",
+ "enemy",
+ "however",
+ "interest",
+ "million",
+ "page",
+ "pink",
+ "proud",
+ "sway",
+ "themselves",
+ "winter",
+ "church",
+ "cruel",
+ "cup",
+ "demon",
+ "experience",
+ "freedom",
+ "pair",
+ "pop",
+ "purpose",
+ "respect",
+ "shoot",
+ "softly",
+ "state",
+ "strange",
+ "bar",
+ "birth",
+ "curl",
+ "dirt",
+ "excuse",
+ "lord",
+ "lovely",
+ "monster",
+ "order",
+ "pack",
+ "pants",
+ "pool",
+ "scene",
+ "seven",
+ "shame",
+ "slide",
+ "ugly",
+ "among",
+ "blade",
+ "blonde",
+ "closet",
+ "creek",
+ "deny",
+ "drug",
+ "eternity",
+ "gain",
+ "grade",
+ "handle",
+ "key",
+ "linger",
+ "pale",
+ "prepare",
+ "swallow",
+ "swim",
+ "tremble",
+ "wheel",
+ "won",
+ "cast",
+ "cigarette",
+ "claim",
+ "college",
+ "direction",
+ "dirty",
+ "gather",
+ "ghost",
+ "hundred",
+ "loss",
+ "lung",
+ "orange",
+ "present",
+ "swear",
+ "swirl",
+ "twice",
+ "wild",
+ "bitter",
+ "blanket",
+ "doctor",
+ "everywhere",
+ "flash",
+ "grown",
+ "knowledge",
+ "numb",
+ "pressure",
+ "radio",
+ "repeat",
+ "ruin",
+ "spend",
+ "unknown",
+ "buy",
+ "clock",
+ "devil",
+ "early",
+ "false",
+ "fantasy",
+ "pound",
+ "precious",
+ "refuse",
+ "sheet",
+ "teeth",
+ "welcome",
+ "add",
+ "ahead",
+ "block",
+ "bury",
+ "caress",
+ "content",
+ "depth",
+ "despite",
+ "distant",
+ "marry",
+ "purple",
+ "threw",
+ "whenever",
+ "bomb",
+ "dull",
+ "easily",
+ "grasp",
+ "hospital",
+ "innocence",
+ "normal",
+ "receive",
+ "reply",
+ "rhyme",
+ "shade",
+ "someday",
+ "sword",
+ "toe",
+ "visit",
+ "asleep",
+ "bought",
+ "center",
+ "consider",
+ "flat",
+ "hero",
+ "history",
+ "ink",
+ "insane",
+ "muscle",
+ "mystery",
+ "pocket",
+ "reflection",
+ "shove",
+ "silently",
+ "smart",
+ "soldier",
+ "spot",
+ "stress",
+ "train",
+ "type",
+ "view",
+ "whether",
+ "bus",
+ "energy",
+ "explain",
+ "holy",
+ "hunger",
+ "inch",
+ "magic",
+ "mix",
+ "noise",
+ "nowhere",
+ "prayer",
+ "presence",
+ "shock",
+ "snap",
+ "spider",
+ "study",
+ "thunder",
+ "trail",
+ "admit",
+ "agree",
+ "bag",
+ "bang",
+ "bound",
+ "butterfly",
+ "cute",
+ "exactly",
+ "explode",
+ "familiar",
+ "fold",
+ "further",
+ "pierce",
+ "reflect",
+ "scent",
+ "selfish",
+ "sharp",
+ "sink",
+ "spring",
+ "stumble",
+ "universe",
+ "weep",
+ "women",
+ "wonderful",
+ "action",
+ "ancient",
+ "attempt",
+ "avoid",
+ "birthday",
+ "branch",
+ "chocolate",
+ "core",
+ "depress",
+ "drunk",
+ "especially",
+ "focus",
+ "fruit",
+ "honest",
+ "match",
+ "palm",
+ "perfectly",
+ "pillow",
+ "pity",
+ "poison",
+ "roar",
+ "shift",
+ "slightly",
+ "thump",
+ "truck",
+ "tune",
+ "twenty",
+ "unable",
+ "wipe",
+ "wrote",
+ "coat",
+ "constant",
+ "dinner",
+ "drove",
+ "egg",
+ "eternal",
+ "flight",
+ "flood",
+ "frame",
+ "freak",
+ "gasp",
+ "glad",
+ "hollow",
+ "motion",
+ "peer",
+ "plastic",
+ "root",
+ "screen",
+ "season",
+ "sting",
+ "strike",
+ "team",
+ "unlike",
+ "victim",
+ "volume",
+ "warn",
+ "weird",
+ "attack",
+ "await",
+ "awake",
+ "built",
+ "charm",
+ "crave",
+ "despair",
+ "fought",
+ "grant",
+ "grief",
+ "horse",
+ "limit",
+ "message",
+ "ripple",
+ "sanity",
+ "scatter",
+ "serve",
+ "split",
+ "string",
+ "trick",
+ "annoy",
+ "blur",
+ "boat",
+ "brave",
+ "clearly",
+ "cling",
+ "connect",
+ "fist",
+ "forth",
+ "imagination",
+ "iron",
+ "jock",
+ "judge",
+ "lesson",
+ "milk",
+ "misery",
+ "nail",
+ "naked",
+ "ourselves",
+ "poet",
+ "possible",
+ "princess",
+ "sail",
+ "size",
+ "snake",
+ "society",
+ "stroke",
+ "torture",
+ "toss",
+ "trace",
+ "wise",
+ "bloom",
+ "bullet",
+ "cell",
+ "check",
+ "cost",
+ "darling",
+ "during",
+ "footstep",
+ "fragile",
+ "hallway",
+ "hardly",
+ "horizon",
+ "invisible",
+ "journey",
+ "midnight",
+ "mud",
+ "nod",
+ "pause",
+ "relax",
+ "shiver",
+ "sudden",
+ "value",
+ "youth",
+ "abuse",
+ "admire",
+ "blink",
+ "breast",
+ "bruise",
+ "constantly",
+ "couple",
+ "creep",
+ "curve",
+ "difference",
+ "dumb",
+ "emptiness",
+ "gotta",
+ "honor",
+ "plain",
+ "planet",
+ "recall",
+ "rub",
+ "ship",
+ "slam",
+ "soar",
+ "somebody",
+ "tightly",
+ "weather",
+ "adore",
+ "approach",
+ "bond",
+ "bread",
+ "burst",
+ "candle",
+ "coffee",
+ "cousin",
+ "crime",
+ "desert",
+ "flutter",
+ "frozen",
+ "grand",
+ "heel",
+ "hello",
+ "language",
+ "level",
+ "movement",
+ "pleasure",
+ "powerful",
+ "random",
+ "rhythm",
+ "settle",
+ "silly",
+ "slap",
+ "sort",
+ "spoken",
+ "steel",
+ "threaten",
+ "tumble",
+ "upset",
+ "aside",
+ "awkward",
+ "bee",
+ "blank",
+ "board",
+ "button",
+ "card",
+ "carefully",
+ "complain",
+ "crap",
+ "deeply",
+ "discover",
+ "drag",
+ "dread",
+ "effort",
+ "entire",
+ "fairy",
+ "giant",
+ "gotten",
+ "greet",
+ "illusion",
+ "jeans",
+ "leap",
+ "liquid",
+ "march",
+ "mend",
+ "nervous",
+ "nine",
+ "replace",
+ "rope",
+ "spine",
+ "stole",
+ "terror",
+ "accident",
+ "apple",
+ "balance",
+ "boom",
+ "childhood",
+ "collect",
+ "demand",
+ "depression",
+ "eventually",
+ "faint",
+ "glare",
+ "goal",
+ "group",
+ "honey",
+ "kitchen",
+ "laid",
+ "limb",
+ "machine",
+ "mere",
+ "mold",
+ "murder",
+ "nerve",
+ "painful",
+ "poetry",
+ "prince",
+ "rabbit",
+ "shelter",
+ "shore",
+ "shower",
+ "soothe",
+ "stair",
+ "steady",
+ "sunlight",
+ "tangle",
+ "tease",
+ "treasure",
+ "uncle",
+ "begun",
+ "bliss",
+ "canvas",
+ "cheer",
+ "claw",
+ "clutch",
+ "commit",
+ "crimson",
+ "crystal",
+ "delight",
+ "doll",
+ "existence",
+ "express",
+ "fog",
+ "football",
+ "gay",
+ "goose",
+ "guard",
+ "hatred",
+ "illuminate",
+ "mass",
+ "math",
+ "mourn",
+ "rich",
+ "rough",
+ "skip",
+ "stir",
+ "student",
+ "style",
+ "support",
+ "thorn",
+ "tough",
+ "yard",
+ "yearn",
+ "yesterday",
+ "advice",
+ "appreciate",
+ "autumn",
+ "bank",
+ "beam",
+ "bowl",
+ "capture",
+ "carve",
+ "collapse",
+ "confusion",
+ "creation",
+ "dove",
+ "feather",
+ "girlfriend",
+ "glory",
+ "government",
+ "harsh",
+ "hop",
+ "inner",
+ "loser",
+ "moonlight",
+ "neighbor",
+ "neither",
+ "peach",
+ "pig",
+ "praise",
+ "screw",
+ "shield",
+ "shimmer",
+ "sneak",
+ "stab",
+ "subject",
+ "throughout",
+ "thrown",
+ "tower",
+ "twirl",
+ "wow",
+ "army",
+ "arrive",
+ "bathroom",
+ "bump",
+ "cease",
+ "cookie",
+ "couch",
+ "courage",
+ "dim",
+ "guilt",
+ "howl",
+ "hum",
+ "husband",
+ "insult",
+ "led",
+ "lunch",
+ "mock",
+ "mostly",
+ "natural",
+ "nearly",
+ "needle",
+ "nerd",
+ "peaceful",
+ "perfection",
+ "pile",
+ "price",
+ "remove",
+ "roam",
+ "sanctuary",
+ "serious",
+ "shiny",
+ "shook",
+ "sob",
+ "stolen",
+ "tap",
+ "vain",
+ "void",
+ "warrior",
+ "wrinkle",
+ "affection",
+ "apologize",
+ "blossom",
+ "bounce",
+ "bridge",
+ "cheap",
+ "crumble",
+ "decision",
+ "descend",
+ "desperately",
+ "dig",
+ "dot",
+ "flip",
+ "frighten",
+ "heartbeat",
+ "huge",
+ "lazy",
+ "lick",
+ "odd",
+ "opinion",
+ "process",
+ "puzzle",
+ "quietly",
+ "retreat",
+ "score",
+ "sentence",
+ "separate",
+ "situation",
+ "skill",
+ "soak",
+ "square",
+ "stray",
+ "taint",
+ "task",
+ "tide",
+ "underneath",
+ "veil",
+ "whistle",
+ "anywhere",
+ "bedroom",
+ "bid",
+ "bloody",
+ "burden",
+ "careful",
+ "compare",
+ "concern",
+ "curtain",
+ "decay",
+ "defeat",
+ "describe",
+ "double",
+ "dreamer",
+ "driver",
+ "dwell",
+ "evening",
+ "flare",
+ "flicker",
+ "grandma",
+ "guitar",
+ "harm",
+ "horrible",
+ "hungry",
+ "indeed",
+ "lace",
+ "melody",
+ "monkey",
+ "nation",
+ "object",
+ "obviously",
+ "rainbow",
+ "salt",
+ "scratch",
+ "shown",
+ "shy",
+ "stage",
+ "stun",
+ "third",
+ "tickle",
+ "useless",
+ "weakness",
+ "worship",
+ "worthless",
+ "afternoon",
+ "beard",
+ "boyfriend",
+ "bubble",
+ "busy",
+ "certain",
+ "chin",
+ "concrete",
+ "desk",
+ "diamond",
+ "doom",
+ "drawn",
+ "due",
+ "felicity",
+ "freeze",
+ "frost",
+ "garden",
+ "glide",
+ "harmony",
+ "hopefully",
+ "hunt",
+ "jealous",
+ "lightning",
+ "mama",
+ "mercy",
+ "peel",
+ "physical",
+ "position",
+ "pulse",
+ "punch",
+ "quit",
+ "rant",
+ "respond",
+ "salty",
+ "sane",
+ "satisfy",
+ "savior",
+ "sheep",
+ "slept",
+ "social",
+ "sport",
+ "tuck",
+ "utter",
+ "valley",
+ "wolf",
+ "aim",
+ "alas",
+ "alter",
+ "arrow",
+ "awaken",
+ "beaten",
+ "belief",
+ "brand",
+ "ceiling",
+ "cheese",
+ "clue",
+ "confidence",
+ "connection",
+ "daily",
+ "disguise",
+ "eager",
+ "erase",
+ "essence",
+ "everytime",
+ "expression",
+ "fan",
+ "flag",
+ "flirt",
+ "foul",
+ "fur",
+ "giggle",
+ "glorious",
+ "ignorance",
+ "law",
+ "lifeless",
+ "measure",
+ "mighty",
+ "muse",
+ "north",
+ "opposite",
+ "paradise",
+ "patience",
+ "patient",
+ "pencil",
+ "petal",
+ "plate",
+ "ponder",
+ "possibly",
+ "practice",
+ "slice",
+ "spell",
+ "stock",
+ "strife",
+ "strip",
+ "suffocate",
+ "suit",
+ "tender",
+ "tool",
+ "trade",
+ "velvet",
+ "verse",
+ "waist",
+ "witch",
+ "aunt",
+ "bench",
+ "bold",
+ "cap",
+ "certainly",
+ "click",
+ "companion",
+ "creator",
+ "dart",
+ "delicate",
+ "determine",
+ "dish",
+ "dragon",
+ "drama",
+ "drum",
+ "dude",
+ "everybody",
+ "feast",
+ "forehead",
+ "former",
+ "fright",
+ "fully",
+ "gas",
+ "hook",
+ "hurl",
+ "invite",
+ "juice",
+ "manage",
+ "moral",
+ "possess",
+ "raw",
+ "rebel",
+ "royal",
+ "scale",
+ "scary",
+ "several",
+ "slight",
+ "stubborn",
+ "swell",
+ "talent",
+ "tea",
+ "terrible",
+ "thread",
+ "torment",
+ "trickle",
+ "usually",
+ "vast",
+ "violence",
+ "weave",
+ "acid",
+ "agony",
+ "ashamed",
+ "awe",
+ "belly",
+ "blend",
+ "blush",
+ "character",
+ "cheat",
+ "common",
+ "company",
+ "coward",
+ "creak",
+ "danger",
+ "deadly",
+ "defense",
+ "define",
+ "depend",
+ "desperate",
+ "destination",
+ "dew",
+ "duck",
+ "dusty",
+ "embarrass",
+ "engine",
+ "example",
+ "explore",
+ "foe",
+ "freely",
+ "frustrate",
+ "generation",
+ "glove",
+ "guilty",
+ "health",
+ "hurry",
+ "idiot",
+ "impossible",
+ "inhale",
+ "jaw",
+ "kingdom",
+ "mention",
+ "mist",
+ "moan",
+ "mumble",
+ "mutter",
+ "observe",
+ "ode",
+ "pathetic",
+ "pattern",
+ "pie",
+ "prefer",
+ "puff",
+ "rape",
+ "rare",
+ "revenge",
+ "rude",
+ "scrape",
+ "spiral",
+ "squeeze",
+ "strain",
+ "sunset",
+ "suspend",
+ "sympathy",
+ "thigh",
+ "throne",
+ "total",
+ "unseen",
+ "weapon",
+ "weary",
+}
diff --git a/crypto/randentropy/rand_entropy.go b/crypto/randentropy/rand_entropy.go
new file mode 100644
index 000000000..b87fa564e
--- /dev/null
+++ b/crypto/randentropy/rand_entropy.go
@@ -0,0 +1,84 @@
+package randentropy
+
+import (
+ crand "crypto/rand"
+ "encoding/binary"
+ "github.com/ethereum/go-ethereum/crypto/sha3"
+ "io"
+ "os"
+ "strings"
+ "time"
+)
+
+var Reader io.Reader = &randEntropy{}
+
+type randEntropy struct {
+}
+
+func (*randEntropy) Read(bytes []byte) (n int, err error) {
+ readBytes := GetEntropyMixed(len(bytes))
+ copy(bytes, readBytes)
+ return len(bytes), nil
+}
+
+// TODO: copied from crypto.go , move to sha3 package?
+func Sha3(data []byte) []byte {
+ d := sha3.NewKeccak256()
+ d.Write(data)
+
+ return d.Sum(nil)
+}
+
+// TODO: verify. this needs to be audited
+// we start with crypt/rand, then XOR in additional entropy from OS
+func GetEntropyMixed(n int) []byte {
+ startTime := time.Now().UnixNano()
+ // for each source, we take SHA3 of the source and use it as seed to math/rand
+ // then read bytes from it and XOR them onto the bytes read from crypto/rand
+ mainBuff := GetEntropyCSPRNG(n)
+ // 1. OS entropy sources
+ startTimeBytes := make([]byte, 32)
+ binary.PutVarint(startTimeBytes, startTime)
+ startTimeHash := Sha3(startTimeBytes)
+ mixBytes(mainBuff, startTimeHash)
+
+ pid := os.Getpid()
+ pidBytes := make([]byte, 32)
+ binary.PutUvarint(pidBytes, uint64(pid))
+ pidHash := Sha3(pidBytes)
+ mixBytes(mainBuff, pidHash)
+
+ osEnv := os.Environ()
+ osEnvBytes := []byte(strings.Join(osEnv, ""))
+ osEnvHash := Sha3(osEnvBytes)
+ mixBytes(mainBuff, osEnvHash)
+
+ // not all OS have hostname in env variables
+ osHostName, err := os.Hostname()
+ if err != nil {
+ osHostNameBytes := []byte(osHostName)
+ osHostNameHash := Sha3(osHostNameBytes)
+ mixBytes(mainBuff, osHostNameHash)
+ }
+ return mainBuff
+}
+
+func GetEntropyCSPRNG(n int) []byte {
+ mainBuff := make([]byte, n)
+ _, err := io.ReadFull(crand.Reader, mainBuff)
+ if err != nil {
+ panic("reading from crypto/rand failed: " + err.Error())
+ }
+ return mainBuff
+}
+
+func mixBytes(buff []byte, mixBuff []byte) []byte {
+ bytesToMix := len(buff)
+ if bytesToMix > 32 {
+ bytesToMix = 32
+ }
+ for i := 0; i < bytesToMix; i++ {
+ buff[i] ^= mixBuff[i]
+ }
+ return buff
+}
diff --git a/crypto/secp256k1/.gitignore b/crypto/secp256k1/.gitignore
new file mode 100644
index 000000000..802b6744a
--- /dev/null
+++ b/crypto/secp256k1/.gitignore
@@ -0,0 +1,24 @@
+# Compiled Object files, Static and Dynamic libs (Shared Objects)
+*.o
+*.a
+*.so
+
+# Folders
+_obj
+_test
+
+# Architecture specific extensions/prefixes
+*.[568vq]
+[568vq].out
+
+*.cgo1.go
+*.cgo2.c
+_cgo_defun.c
+_cgo_gotypes.go
+_cgo_export.*
+
+_testmain.go
+
+*.exe
+
+*~
diff --git a/crypto/secp256k1/README.md b/crypto/secp256k1/README.md
new file mode 100644
index 000000000..79cdccb38
--- /dev/null
+++ b/crypto/secp256k1/README.md
@@ -0,0 +1,22 @@
+secp256k1-go
+=======
+
+golang secp256k1 library
+
+Implements cryptographic operations for the secp256k1 ECDSA curve used by Bitcoin.
+
+Installing
+===
+```
+sudo apt-get install gmp-dev
+```
+
+Now compiles with cgo!
+
+Test
+===
+
+To run tests do
+```
+go tests
+``` \ No newline at end of file
diff --git a/crypto/secp256k1/notes.go b/crypto/secp256k1/notes.go
new file mode 100644
index 000000000..7ed16caab
--- /dev/null
+++ b/crypto/secp256k1/notes.go
@@ -0,0 +1,192 @@
+package secp256k1
+
+/*
+<HaltingState> sipa, int secp256k1_ecdsa_pubkey_create(unsigned char *pubkey, int *pubkeylen, const unsigned char *seckey, int compressed);
+<HaltingState> is that how i generate private/public keys?
+<sipa> HaltingState: you pass in a random 32-byte string as seckey
+<sipa> HaltingState: if it is valid, the corresponding pubkey is put in pubkey
+<sipa> and true is returned
+<sipa> otherwise, false is returned
+<sipa> around 1 in 2^128 32-byte strings are invalid, so the odds of even ever seeing one is extremely rare
+
+<sipa> private keys are mathematically numbers
+<sipa> each has a corresponding point on the curve as public key
+<sipa> a private key is just a number
+<sipa> a public key is a point with x/y coordinates
+<sipa> almost every 256-bit number is a valid private key (one with a point on the curve corresponding to it)
+<sipa> HaltingState: ok?
+
+<sipa> more than half of random points are not on the curve
+<sipa> and actually, it is less than the square root, not less than half, sorry :)
+!!!
+<sipa> a private key is a NUMBER
+<sipa> a public key is a POINT
+<gmaxwell> half the x,y values in the field are not on the curve, a private key is an integer.
+
+<sipa> HaltingState: yes, n,q = private keys; N,Q = corresponding public keys (N=n*G, Q=q*G); then it follows that n*Q = n*q*G = q*n*G = q*N
+<sipa> that's the reason ECDH works
+<sipa> multiplication is associative and commutativ
+*/
+
+/*
+<HaltingState> sipa, ok; i am doing compact signatures and I want to know; can someone change the signature to get another valid signature for same message without the private key
+<HaltingState> because i know they can do that for the normal 72 byte signatures that openssl was putting out
+<sipa> HaltingState: if you don't enforce non-malleability, yes
+<sipa> HaltingState: if you force the highest bit of t
+
+<sipa> it _creates_ signatures that already satisfy that condition
+<sipa> but it will accept ones that don't
+<sipa> maybe i should change that, and be strict
+<HaltingState> yes; i want some way to know signature is valid but fails malleability
+<sipa> well if the highest bit of S is 1, you can take its complement
+<sipa> and end up with a valid signature
+<sipa> that is canonical
+*/
+
+/*
+
+<HaltingState> sipa, I am signing messages and highest bit of the compact signature is 1!!!
+<HaltingState> if (b & 0x80) == 0x80 {
+<HaltingState> log.Panic("b= %v b2= %v \n", b, b&0x80)
+<HaltingState> }
+<sipa> what bit?
+* Pengoo has quit (Ping timeout: 272 seconds)
+<HaltingState> the highest bit of the first byte of signature
+<sipa> it's the highest bit of S
+<sipa> so the 32nd byte
+<HaltingState> wtf
+
+*/
+
+/*
+ For instance, nonces are used in HTTP digest access authentication to calculate an MD5 digest
+ of the password. The nonces are different each time the 401 authentication challenge
+ response code is presented, thus making replay attacks virtually impossible.
+
+can verify client/server match without sending password over network
+*/
+
+/*
+<hanihani> one thing I dont get about armory for instance,
+is how the hot-wallet can generate new addresses without
+knowing the master key
+*/
+
+/*
+<HaltingState> i am yelling at the telehash people for using secp256r1
+instead of secp256k1; they thing r1 is "more secure" despite fact that
+there is no implementation that works and wrapping it is now taking
+up massive time, lol
+<gmaxwell> ...
+
+<gmaxwell> You know that the *r curves are selected via an undisclosed
+secret process, right?
+<gmaxwell> HaltingState: telehash is offtopic for this channel.
+*/
+/*
+ For instance, nonces are used in HTTP digest access authentication to calculate an MD5 digest
+ of the password. The nonces are different each time the 401 authentication challenge
+ response code is presented, thus making replay attacks virtually impossible.
+
+can verify client/server match without sending password over network
+*/
+
+/*
+void secp256k1_start(void);
+void secp256k1_stop(void);
+
+ * Verify an ECDSA signature.
+ * Returns: 1: correct signature
+ * 0: incorrect signature
+ * -1: invalid public key
+ * -2: invalid signature
+ *
+int secp256k1_ecdsa_verify(const unsigned char *msg, int msglen,
+ const unsigned char *sig, int siglen,
+ const unsigned char *pubkey, int pubkeylen);
+
+http://www.nilsschneider.net/2013/01/28/recovering-bitcoin-private-keys.html
+
+Why did this work? ECDSA requires a random number for each signature. If this random
+number is ever used twice with the same private key it can be recovered.
+This transaction was generated by a hardware bitcoin wallet using a pseudo-random number
+generator that was returning the same “random” number every time.
+
+Nonce is 32 bytes?
+
+ * Create an ECDSA signature.
+ * Returns: 1: signature created
+ * 0: nonce invalid, try another one
+ * In: msg: the message being signed
+ * msglen: the length of the message being signed
+ * seckey: pointer to a 32-byte secret key (assumed to be valid)
+ * nonce: pointer to a 32-byte nonce (generated with a cryptographic PRNG)
+ * Out: sig: pointer to a 72-byte array where the signature will be placed.
+ * siglen: pointer to an int, which will be updated to the signature length (<=72).
+ *
+int secp256k1_ecdsa_sign(const unsigned char *msg, int msglen,
+ unsigned char *sig, int *siglen,
+ const unsigned char *seckey,
+ const unsigned char *nonce);
+
+
+ * Create a compact ECDSA signature (64 byte + recovery id).
+ * Returns: 1: signature created
+ * 0: nonce invalid, try another one
+ * In: msg: the message being signed
+ * msglen: the length of the message being signed
+ * seckey: pointer to a 32-byte secret key (assumed to be valid)
+ * nonce: pointer to a 32-byte nonce (generated with a cryptographic PRNG)
+ * Out: sig: pointer to a 64-byte array where the signature will be placed.
+ * recid: pointer to an int, which will be updated to contain the recovery id.
+ *
+int secp256k1_ecdsa_sign_compact(const unsigned char *msg, int msglen,
+ unsigned char *sig64,
+ const unsigned char *seckey,
+ const unsigned char *nonce,
+ int *recid);
+
+ * Recover an ECDSA public key from a compact signature.
+ * Returns: 1: public key succesfully recovered (which guarantees a correct signature).
+ * 0: otherwise.
+ * In: msg: the message assumed to be signed
+ * msglen: the length of the message
+ * compressed: whether to recover a compressed or uncompressed pubkey
+ * recid: the recovery id (as returned by ecdsa_sign_compact)
+ * Out: pubkey: pointer to a 33 or 65 byte array to put the pubkey.
+ * pubkeylen: pointer to an int that will contain the pubkey length.
+ *
+
+recovery id is between 0 and 3
+
+int secp256k1_ecdsa_recover_compact(const unsigned char *msg, int msglen,
+ const unsigned char *sig64,
+ unsigned char *pubkey, int *pubkeylen,
+ int compressed, int recid);
+
+
+ * Verify an ECDSA secret key.
+ * Returns: 1: secret key is valid
+ * 0: secret key is invalid
+ * In: seckey: pointer to a 32-byte secret key
+ *
+int secp256k1_ecdsa_seckey_verify(const unsigned char *seckey);
+
+** Just validate a public key.
+ * Returns: 1: valid public key
+ * 0: invalid public key
+ *
+int secp256k1_ecdsa_pubkey_verify(const unsigned char *pubkey, int pubkeylen);
+
+** Compute the public key for a secret key.
+ * In: compressed: whether the computed public key should be compressed
+ * seckey: pointer to a 32-byte private key.
+ * Out: pubkey: pointer to a 33-byte (if compressed) or 65-byte (if uncompressed)
+ * area to store the public key.
+ * pubkeylen: pointer to int that will be updated to contains the pubkey's
+ * length.
+ * Returns: 1: secret was valid, public key stores
+ * 0: secret was invalid, try again.
+ *
+int secp256k1_ecdsa_pubkey_create(unsigned char *pubkey, int *pubkeylen, const unsigned char *seckey, int compressed);
+*/
diff --git a/crypto/secp256k1/secp256.go b/crypto/secp256k1/secp256.go
new file mode 100644
index 000000000..4864e8d09
--- /dev/null
+++ b/crypto/secp256k1/secp256.go
@@ -0,0 +1,306 @@
+package secp256k1
+
+/*
+#cgo CFLAGS: -std=gnu99 -Wno-error
+#cgo darwin CFLAGS: -I/usr/local/include
+#cgo LDFLAGS: -lgmp
+#cgo darwin LDFLAGS: -L/usr/local/lib
+#define USE_FIELD_10X26
+#define USE_NUM_GMP
+#define USE_FIELD_INV_BUILTIN
+#include "./secp256k1/src/secp256k1.c"
+*/
+import "C"
+
+import (
+ "bytes"
+ "errors"
+ "unsafe"
+
+ "github.com/ethereum/go-ethereum/crypto/randentropy"
+)
+
+//#define USE_FIELD_5X64
+
+/*
+ Todo:
+ > Centralize key management in module
+ > add pubkey/private key struct
+ > Dont let keys leave module; address keys as ints
+
+ > store private keys in buffer and shuffle (deters persistance on swap disc)
+ > Byte permutation (changing)
+ > xor with chaning random block (to deter scanning memory for 0x63) (stream cipher?)
+
+ On Disk
+ > Store keys in wallets
+ > use slow key derivation function for wallet encryption key (2 seconds)
+*/
+
+func init() {
+ C.secp256k1_start() //takes 10ms to 100ms
+}
+
+func Stop() {
+ C.secp256k1_stop()
+}
+
+/*
+int secp256k1_ecdsa_pubkey_create(
+ unsigned char *pubkey, int *pubkeylen,
+ const unsigned char *seckey, int compressed);
+*/
+
+/** Compute the public key for a secret key.
+ * In: compressed: whether the computed public key should be compressed
+ * seckey: pointer to a 32-byte private key.
+ * Out: pubkey: pointer to a 33-byte (if compressed) or 65-byte (if uncompressed)
+ * area to store the public key.
+ * pubkeylen: pointer to int that will be updated to contains the pubkey's
+ * length.
+ * Returns: 1: secret was valid, public key stores
+ * 0: secret was invalid, try again.
+ */
+
+//pubkey, seckey
+
+func GenerateKeyPair() ([]byte, []byte) {
+
+ pubkey_len := C.int(65)
+ const seckey_len = 32
+
+ var pubkey []byte = make([]byte, pubkey_len)
+ var seckey []byte = randentropy.GetEntropyMixed(seckey_len)
+
+ var pubkey_ptr *C.uchar = (*C.uchar)(unsafe.Pointer(&pubkey[0]))
+ var seckey_ptr *C.uchar = (*C.uchar)(unsafe.Pointer(&seckey[0]))
+
+ ret := C.secp256k1_ecdsa_pubkey_create(
+ pubkey_ptr, &pubkey_len,
+ seckey_ptr, 0)
+
+ if ret != C.int(1) {
+ return GenerateKeyPair() //invalid secret, try again
+ }
+ return pubkey, seckey
+}
+
+func GeneratePubKey(seckey []byte) ([]byte, error) {
+ if err := VerifySeckeyValidity(seckey); err != nil {
+ return nil, err
+ }
+
+ pubkey_len := C.int(65)
+ const seckey_len = 32
+
+ var pubkey []byte = make([]byte, pubkey_len)
+
+ var pubkey_ptr *C.uchar = (*C.uchar)(unsafe.Pointer(&pubkey[0]))
+ var seckey_ptr *C.uchar = (*C.uchar)(unsafe.Pointer(&seckey[0]))
+
+ ret := C.secp256k1_ecdsa_pubkey_create(
+ pubkey_ptr, &pubkey_len,
+ seckey_ptr, 0)
+
+ if ret != C.int(1) {
+ return nil, errors.New("Unable to generate pubkey from seckey")
+ }
+
+ return pubkey, nil
+}
+
+/*
+* Create a compact ECDSA signature (64 byte + recovery id).
+* Returns: 1: signature created
+* 0: nonce invalid, try another one
+* In: msg: the message being signed
+* msglen: the length of the message being signed
+* seckey: pointer to a 32-byte secret key (assumed to be valid)
+* nonce: pointer to a 32-byte nonce (generated with a cryptographic PRNG)
+* Out: sig: pointer to a 64-byte array where the signature will be placed.
+* recid: pointer to an int, which will be updated to contain the recovery id.
+ */
+
+/*
+int secp256k1_ecdsa_sign_compact(const unsigned char *msg, int msglen,
+ unsigned char *sig64,
+ const unsigned char *seckey,
+ const unsigned char *nonce,
+ int *recid);
+*/
+
+func Sign(msg []byte, seckey []byte) ([]byte, error) {
+ nonce := randentropy.GetEntropyMixed(32)
+
+ var sig []byte = make([]byte, 65)
+ var recid C.int
+
+ var msg_ptr *C.uchar = (*C.uchar)(unsafe.Pointer(&msg[0]))
+ var seckey_ptr *C.uchar = (*C.uchar)(unsafe.Pointer(&seckey[0]))
+ var nonce_ptr *C.uchar = (*C.uchar)(unsafe.Pointer(&nonce[0]))
+ var sig_ptr *C.uchar = (*C.uchar)(unsafe.Pointer(&sig[0]))
+
+ if C.secp256k1_ecdsa_seckey_verify(seckey_ptr) != C.int(1) {
+ return nil, errors.New("Invalid secret key")
+ }
+
+ ret := C.secp256k1_ecdsa_sign_compact(
+ msg_ptr, C.int(len(msg)),
+ sig_ptr,
+ seckey_ptr,
+ nonce_ptr,
+ &recid)
+
+ sig[64] = byte(int(recid))
+
+ if ret != C.int(1) {
+ // nonce invalid, retry
+ return Sign(msg, seckey)
+ }
+
+ return sig, nil
+
+}
+
+/*
+* Verify an ECDSA secret key.
+* Returns: 1: secret key is valid
+* 0: secret key is invalid
+* In: seckey: pointer to a 32-byte secret key
+ */
+
+func VerifySeckeyValidity(seckey []byte) error {
+ if len(seckey) != 32 {
+ return errors.New("priv key is not 32 bytes")
+ }
+ var seckey_ptr *C.uchar = (*C.uchar)(unsafe.Pointer(&seckey[0]))
+ ret := C.secp256k1_ecdsa_seckey_verify(seckey_ptr)
+ if int(ret) != 1 {
+ return errors.New("invalid seckey")
+ }
+ return nil
+}
+
+/*
+* Validate a public key.
+* Returns: 1: valid public key
+* 0: invalid public key
+ */
+
+func VerifyPubkeyValidity(pubkey []byte) error {
+ if len(pubkey) != 65 {
+ return errors.New("pub key is not 65 bytes")
+ }
+ var pubkey_ptr *C.uchar = (*C.uchar)(unsafe.Pointer(&pubkey[0]))
+ ret := C.secp256k1_ecdsa_pubkey_verify(pubkey_ptr, 65)
+ if int(ret) != 1 {
+ return errors.New("invalid pubkey")
+ }
+
+ return nil
+}
+
+func VerifySignatureValidity(sig []byte) bool {
+ //64+1
+ if len(sig) != 65 {
+ return false
+ }
+ //malleability check, highest bit must be 1
+ if (sig[32] & 0x80) == 0x80 {
+ return false
+ }
+ //recovery id check
+ if sig[64] >= 4 {
+ return false
+ }
+
+ return true
+}
+
+//for compressed signatures, does not need pubkey
+func VerifySignature(msg []byte, sig []byte, pubkey1 []byte) error {
+ if msg == nil || sig == nil || pubkey1 == nil {
+ return errors.New("inputs must be non-nil")
+ }
+ if len(sig) != 65 {
+ return errors.New("invalid signature length")
+ }
+ if len(pubkey1) != 65 {
+ return errors.New("Invalid public key length")
+ }
+
+ //to enforce malleability, highest bit of S must be 0
+ //S starts at 32nd byte
+ if (sig[32] & 0x80) == 0x80 { //highest bit must be 1
+ return errors.New("Signature not malleable")
+ }
+
+ if sig[64] >= 4 {
+ return errors.New("Recover byte invalid")
+ }
+
+ // if pubkey recovered, signature valid
+ pubkey2, err := RecoverPubkey(msg, sig)
+ if err != nil {
+ return err
+ }
+ if len(pubkey2) != 65 {
+ return errors.New("Invalid recovered public key length")
+ }
+ if !bytes.Equal(pubkey1, pubkey2) {
+ return errors.New("Public key does not match recovered public key")
+ }
+
+ return nil
+}
+
+/*
+int secp256k1_ecdsa_recover_compact(const unsigned char *msg, int msglen,
+ const unsigned char *sig64,
+ unsigned char *pubkey, int *pubkeylen,
+ int compressed, int recid);
+*/
+
+/*
+ * Recover an ECDSA public key from a compact signature.
+ * Returns: 1: public key succesfully recovered (which guarantees a correct signature).
+ * 0: otherwise.
+ * In: msg: the message assumed to be signed
+ * msglen: the length of the message
+ * compressed: whether to recover a compressed or uncompressed pubkey
+ * recid: the recovery id (as returned by ecdsa_sign_compact)
+ * Out: pubkey: pointer to a 33 or 65 byte array to put the pubkey.
+ * pubkeylen: pointer to an int that will contain the pubkey length.
+ */
+
+//recovers the public key from the signature
+//recovery of pubkey means correct signature
+func RecoverPubkey(msg []byte, sig []byte) ([]byte, error) {
+ if len(sig) != 65 {
+ return nil, errors.New("Invalid signature length")
+ }
+
+ var pubkey []byte = make([]byte, 65)
+
+ var msg_ptr *C.uchar = (*C.uchar)(unsafe.Pointer(&msg[0]))
+ var sig_ptr *C.uchar = (*C.uchar)(unsafe.Pointer(&sig[0]))
+ var pubkey_ptr *C.uchar = (*C.uchar)(unsafe.Pointer(&pubkey[0]))
+
+ var pubkeylen C.int
+
+ ret := C.secp256k1_ecdsa_recover_compact(
+ msg_ptr, C.int(len(msg)),
+ sig_ptr,
+ pubkey_ptr, &pubkeylen,
+ C.int(0), C.int(sig[64]),
+ )
+
+ if ret == C.int(0) {
+ return nil, errors.New("Failed to recover public key")
+ } else if pubkeylen != C.int(65) {
+ return nil, errors.New("Impossible Error: Invalid recovered public key length")
+ } else {
+ return pubkey, nil
+ }
+ return nil, errors.New("Impossible Error: func RecoverPubkey has reached an unreachable state")
+}
diff --git a/crypto/secp256k1/secp256_test.go b/crypto/secp256k1/secp256_test.go
new file mode 100644
index 000000000..3599fde38
--- /dev/null
+++ b/crypto/secp256k1/secp256_test.go
@@ -0,0 +1,238 @@
+package secp256k1
+
+import (
+ "bytes"
+ "fmt"
+ "log"
+ "testing"
+
+ "github.com/ethereum/go-ethereum/crypto/randentropy"
+)
+
+const TESTS = 10000 // how many tests
+const SigSize = 65 //64+1
+
+func Test_Secp256_00(t *testing.T) {
+
+ var nonce []byte = randentropy.GetEntropyMixed(32) //going to get bitcoins stolen!
+
+ if len(nonce) != 32 {
+ t.Fatal()
+ }
+
+}
+
+//tests for Malleability
+//highest bit of S must be 0; 32nd byte
+func CompactSigTest(sig []byte) {
+
+ var b int = int(sig[32])
+ if b < 0 {
+ log.Panic()
+ }
+ if ((b >> 7) == 1) != ((b & 0x80) == 0x80) {
+ log.Panic("b= %v b2= %v \n", b, b>>7)
+ }
+ if (b & 0x80) == 0x80 {
+ log.Panic("b= %v b2= %v \n", b, b&0x80)
+ }
+}
+
+//test pubkey/private generation
+func Test_Secp256_01(t *testing.T) {
+ pubkey, seckey := GenerateKeyPair()
+ if err := VerifySeckeyValidity(seckey); err != nil {
+ t.Fatal()
+ }
+ if err := VerifyPubkeyValidity(pubkey); err != nil {
+ t.Fatal()
+ }
+}
+
+//test size of messages
+func Test_Secp256_02s(t *testing.T) {
+ pubkey, seckey := GenerateKeyPair()
+ msg := randentropy.GetEntropyMixed(32)
+ sig, _ := Sign(msg, seckey)
+ CompactSigTest(sig)
+ if sig == nil {
+ t.Fatal("Signature nil")
+ }
+ if len(pubkey) != 65 {
+ t.Fail()
+ }
+ if len(seckey) != 32 {
+ t.Fail()
+ }
+ if len(sig) != 64+1 {
+ t.Fail()
+ }
+ if int(sig[64]) > 4 {
+ t.Fail()
+ } //should be 0 to 4
+}
+
+//test signing message
+func Test_Secp256_02(t *testing.T) {
+ pubkey1, seckey := GenerateKeyPair()
+ msg := randentropy.GetEntropyMixed(32)
+ sig, _ := Sign(msg, seckey)
+ if sig == nil {
+ t.Fatal("Signature nil")
+ }
+
+ pubkey2, _ := RecoverPubkey(msg, sig)
+ if pubkey2 == nil {
+ t.Fatal("Recovered pubkey invalid")
+ }
+ if bytes.Equal(pubkey1, pubkey2) == false {
+ t.Fatal("Recovered pubkey does not match")
+ }
+
+ err := VerifySignature(msg, sig, pubkey1)
+ if err != nil {
+ t.Fatal("Signature invalid")
+ }
+}
+
+//test pubkey recovery
+func Test_Secp256_02a(t *testing.T) {
+ pubkey1, seckey1 := GenerateKeyPair()
+ msg := randentropy.GetEntropyMixed(32)
+ sig, _ := Sign(msg, seckey1)
+
+ if sig == nil {
+ t.Fatal("Signature nil")
+ }
+ err := VerifySignature(msg, sig, pubkey1)
+ if err != nil {
+ t.Fatal("Signature invalid")
+ }
+
+ pubkey2, _ := RecoverPubkey(msg, sig)
+ if len(pubkey1) != len(pubkey2) {
+ t.Fatal()
+ }
+ for i, _ := range pubkey1 {
+ if pubkey1[i] != pubkey2[i] {
+ t.Fatal()
+ }
+ }
+ if bytes.Equal(pubkey1, pubkey2) == false {
+ t.Fatal()
+ }
+}
+
+//test random messages for the same pub/private key
+func Test_Secp256_03(t *testing.T) {
+ _, seckey := GenerateKeyPair()
+ for i := 0; i < TESTS; i++ {
+ msg := randentropy.GetEntropyMixed(32)
+ sig, _ := Sign(msg, seckey)
+ CompactSigTest(sig)
+
+ sig[len(sig)-1] %= 4
+ pubkey2, _ := RecoverPubkey(msg, sig)
+ if pubkey2 == nil {
+ t.Fail()
+ }
+ }
+}
+
+//test random messages for different pub/private keys
+func Test_Secp256_04(t *testing.T) {
+ for i := 0; i < TESTS; i++ {
+ pubkey1, seckey := GenerateKeyPair()
+ msg := randentropy.GetEntropyMixed(32)
+ sig, _ := Sign(msg, seckey)
+ CompactSigTest(sig)
+
+ if sig[len(sig)-1] >= 4 {
+ t.Fail()
+ }
+ pubkey2, _ := RecoverPubkey(msg, sig)
+ if pubkey2 == nil {
+ t.Fail()
+ }
+ if bytes.Equal(pubkey1, pubkey2) == false {
+ t.Fail()
+ }
+ }
+}
+
+//test random signatures against fixed messages; should fail
+
+//crashes:
+// -SIPA look at this
+
+func randSig() []byte {
+ sig := randentropy.GetEntropyMixed(65)
+ sig[32] &= 0x70
+ sig[64] %= 4
+ return sig
+}
+
+func Test_Secp256_06a_alt0(t *testing.T) {
+ pubkey1, seckey := GenerateKeyPair()
+ msg := randentropy.GetEntropyMixed(32)
+ sig, _ := Sign(msg, seckey)
+
+ if sig == nil {
+ t.Fail()
+ }
+ if len(sig) != 65 {
+ t.Fail()
+ }
+ for i := 0; i < TESTS; i++ {
+ sig = randSig()
+ pubkey2, _ := RecoverPubkey(msg, sig)
+
+ if bytes.Equal(pubkey1, pubkey2) == true {
+ t.Fail()
+ }
+
+ if pubkey2 != nil && VerifySignature(msg, sig, pubkey2) != nil {
+ t.Fail()
+ }
+
+ if VerifySignature(msg, sig, pubkey1) == nil {
+ t.Fail()
+ }
+ }
+}
+
+//test random messages against valid signature: should fail
+
+func Test_Secp256_06b(t *testing.T) {
+ pubkey1, seckey := GenerateKeyPair()
+ msg := randentropy.GetEntropyMixed(32)
+ sig, _ := Sign(msg, seckey)
+
+ fail_count := 0
+ for i := 0; i < TESTS; i++ {
+ msg = randentropy.GetEntropyMixed(32)
+ pubkey2, _ := RecoverPubkey(msg, sig)
+ if bytes.Equal(pubkey1, pubkey2) == true {
+ t.Fail()
+ }
+
+ if pubkey2 != nil && VerifySignature(msg, sig, pubkey2) != nil {
+ t.Fail()
+ }
+
+ if VerifySignature(msg, sig, pubkey1) == nil {
+ t.Fail()
+ }
+ }
+ if fail_count != 0 {
+ fmt.Printf("ERROR: Accepted signature for %v of %v random messages\n", fail_count, TESTS)
+ }
+}
+
+func TestInvalidKey(t *testing.T) {
+ p1 := make([]byte, 32)
+ err := VerifySeckeyValidity(p1)
+ if err == nil {
+ t.Errorf("pvk %x varify sec key should have returned error", p1)
+ }
+}
diff --git a/crypto/secp256k1/secp256k1/COPYING b/crypto/secp256k1/secp256k1/COPYING
new file mode 100644
index 000000000..4522a5990
--- /dev/null
+++ b/crypto/secp256k1/secp256k1/COPYING
@@ -0,0 +1,19 @@
+Copyright (c) 2013 Pieter Wuille
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in
+all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+THE SOFTWARE.
diff --git a/crypto/secp256k1/secp256k1/Makefile b/crypto/secp256k1/secp256k1/Makefile
new file mode 100644
index 000000000..21628f308
--- /dev/null
+++ b/crypto/secp256k1/secp256k1/Makefile
@@ -0,0 +1,55 @@
+$(shell CC=$(CC) YASM=$(YASM) ./configure)
+include config.mk
+
+FILES := src/*.h src/impl/*.h
+
+JAVA_FILES := src/java/org_bitcoin_NativeSecp256k1.h src/java/org_bitcoin_NativeSecp256k1.c
+
+OBJS :=
+
+ifeq ($(USE_ASM), 1)
+ OBJS := $(OBJS) obj/field_5x$(HAVE_LIMB)_asm.o
+endif
+STD="gnu99"
+
+default: tests libsecp256k1.a libsecp256k1.so
+
+clean:
+ rm -rf obj/*.o bench tests *.a *.so config.mk
+
+obj/field_5x52_asm.o: src/field_5x52_asm.asm
+ $(YASM) -f elf64 -o obj/field_5x52_asm.o src/field_5x52_asm.asm
+
+obj/field_5x64_asm.o: src/field_5x64_asm.asm
+ $(YASM) -f elf64 -o obj/field_5x64_asm.o src/field_5x64_asm.asm
+
+obj/secp256k1.o: $(FILES) src/secp256k1.c include/secp256k1.h
+ $(CC) -fPIC -std=$(STD) $(CFLAGS) $(CFLAGS_EXTRA) -DNDEBUG -$(OPTLEVEL) src/secp256k1.c -c -o obj/secp256k1.o
+
+bench: $(FILES) src/bench.c $(OBJS)
+ $(CC) -fPIC -std=$(STD) $(CFLAGS) $(CFLAGS_EXTRA) $(CFLAGS_TEST_EXTRA) -DNDEBUG -$(OPTLEVEL) src/bench.c $(OBJS) $(LDFLAGS_EXTRA) $(LDFLAGS_TEST_EXTRA) -o bench
+
+tests: $(FILES) src/tests.c $(OBJS)
+ $(CC) -std=$(STD) $(CFLAGS) $(CFLAGS_EXTRA) $(CFLAGS_TEST_EXTRA) -DVERIFY -fstack-protector-all -$(OPTLEVEL) -ggdb3 src/tests.c $(OBJS) $(LDFLAGS_EXTRA) $(LDFLAGS_TEST_EXTRA) -o tests
+
+tests_fuzzer: $(FILES) src/tests_fuzzer.c obj/secp256k1.o $(OBJS)
+ $(CC) -std=$(STD) $(CFLAGS) $(CFLAGS_EXTRA) $(CFLAGS_TEST_EXTRA) -DVERIFY -fstack-protector-all -$(OPTLEVEL) -ggdb3 src/tests_fuzzer.c $(OBJS) obj/secp256k1.o $(LDFLAGS_EXTRA) $(LDFLAGS_TEST_EXTRA) -o tests_fuzzer
+
+coverage: $(FILES) src/tests.c $(OBJS)
+ rm -rf tests.gcno tests.gcda tests_cov
+ $(CC) -std=$(STD) $(CFLAGS) $(CFLAGS_EXTRA) $(CFLAGS_TEST_EXTRA) -DVERIFY --coverage -$(OPTLEVEL) -g src/tests.c $(OBJS) $(LDFLAGS_EXTRA) $(LDFLAGS_TEST_EXTRA) -o tests_cov
+ rm -rf lcov
+ mkdir -p lcov
+ cd lcov; lcov --directory ../ --zerocounters
+ cd lcov; ../tests_cov
+ cd lcov; lcov --directory ../ --capture --output-file secp256k1.info
+ cd lcov; genhtml -o . secp256k1.info
+
+libsecp256k1.a: obj/secp256k1.o $(OBJS)
+ $(AR) -rs $@ $(OBJS) obj/secp256k1.o
+
+libsecp256k1.so: obj/secp256k1.o $(OBJS)
+ $(CC) -std=$(STD) $(LDFLAGS_EXTRA) $(OBJS) obj/secp256k1.o -shared -o libsecp256k1.so
+
+libjavasecp256k1.so: $(OBJS) obj/secp256k1.o $(JAVA_FILES)
+ $(CC) -fPIC -std=$(STD) $(CFLAGS) $(CFLAGS_EXTRA) -DNDEBUG -$(OPTLEVEL) -I. src/java/org_bitcoin_NativeSecp256k1.c $(LDFLAGS_EXTRA) $(OBJS) obj/secp256k1.o -shared -o libjavasecp256k1.so
diff --git a/crypto/secp256k1/secp256k1/TODO b/crypto/secp256k1/secp256k1/TODO
new file mode 100644
index 000000000..a300e1c5e
--- /dev/null
+++ b/crypto/secp256k1/secp256k1/TODO
@@ -0,0 +1,3 @@
+* Unit tests for fieldelem/groupelem, including ones intended to
+ trigger fieldelem's boundary cases.
+* Complete constant-time operations for signing/keygen
diff --git a/crypto/secp256k1/secp256k1/config.mk b/crypto/secp256k1/secp256k1/config.mk
new file mode 100644
index 000000000..3386b7bcb
--- /dev/null
+++ b/crypto/secp256k1/secp256k1/config.mk
@@ -0,0 +1,9 @@
+CC=cc
+YASM=yasm
+CFLAGS_EXTRA=-DUSE_FIELD_5X52 -DUSE_FIELD_5X52_ASM -DUSE_NUM_GMP -DUSE_FIELD_INV_NUM
+CFLAGS_TEST_EXTRA=-DENABLE_OPENSSL_TESTS
+LDFLAGS_EXTRA=-lgmp
+LDFLAGS_TEST_EXTRA=-lcrypto
+USE_ASM=1
+HAVE_LIMB=52
+OPTLEVEL=O2
diff --git a/crypto/secp256k1/secp256k1/configure b/crypto/secp256k1/secp256k1/configure
new file mode 100755
index 000000000..cb69239b7
--- /dev/null
+++ b/crypto/secp256k1/secp256k1/configure
@@ -0,0 +1,175 @@
+#!/bin/sh
+
+if test -f config.mk; then
+ exit 0
+fi
+
+if test -z "$CC"; then
+ CC=cc
+fi
+
+if test -z "$YASM"; then
+ YASM=yasm
+fi
+
+# test yasm
+$YASM -f elf64 -o /tmp/secp256k1-$$.o - <<EOF
+ BITS 64
+ GLOBAL testyasm
+ ALIGN 32
+testyasm:
+ xor r9,r9
+EOF
+if [ "$?" = 0 ]; then
+ $CC $CFLAGS -std=c99 -x c -c - -o /tmp/secp256k1-$$-2.o 2>/dev/null <<EOF
+void __attribute__ ((sysv_abi)) testyasm(void);
+int main() {
+ testyasm();
+ return 0;
+}
+EOF
+ $CC $CFLAGS -std=c99 /tmp/secp256k1-$$-2.o /tmp/secp256k1-$$.o -o /dev/null 2>/dev/null
+ if [ "$?" = 0 ]; then
+ HAVE_YASM=1
+ fi
+ rm -rf /tmp/secp256k1-$$-2.o /tmp/secp256k1-$$.o
+fi
+
+# test openssl
+HAVE_OPENSSL=0
+$CC $CFLAGS -std=c99 -x c - -o /dev/null -lcrypto 2>/dev/null <<EOF
+#include <openssl/bn.h>
+int main() {
+ BN_CTX *ctx = BN_CTX_new();
+ BN_CTX_free(ctx);
+ return 0;
+}
+EOF
+if [ "$?" = 0 ]; then
+ HAVE_OPENSSL=1
+fi
+
+# test openssl/EC
+HAVE_OPENSSL_EC=0
+if [ "$HAVE_OPENSSL" = "1" ]; then
+$CC $CFLAGS -std=c99 -x c - -o /dev/null -lcrypto 2>/dev/null <<EOF
+#include <openssl/ec.h>
+#include <openssl/ecdsa.h>
+#include <openssl/obj_mac.h>
+int main() {
+ EC_KEY *eckey = EC_KEY_new_by_curve_name(NID_secp256k1);
+ ECDSA_sign(0, NULL, 0, NULL, NULL, eckey);
+ ECDSA_verify(0, NULL, 0, NULL, 0, eckey);
+ EC_KEY_free(eckey);
+ return 0;
+}
+EOF
+if [ "$?" = 0 ]; then
+ HAVE_OPENSSL_EC=1
+fi
+fi
+
+# test gmp
+HAVE_GMP=0
+$CC $CFLAGS -std=c99 -x c - -o /dev/null -lgmp 2>/dev/null <<EOF
+#include <gmp.h>
+int main() {
+ mpz_t n;
+ mpz_init(n);
+ mpz_clear(n);
+ return 0;
+}
+EOF
+if [ "$?" = 0 ]; then
+ HAVE_GMP=1
+fi
+
+# test __int128
+HAVE_INT128=0
+$CC $CFLAGS -std=c99 -x c - -o /dev/null 2>/dev/null <<EOF
+#include <stdint.h>
+int main() {
+ __int128 x = 0;
+ return 0;
+}
+EOF
+if [ "$?" = 0 ]; then
+ HAVE_INT128=1
+fi
+
+#default limb size
+HAVE_LIMB=52
+
+for arg in "$@"; do
+ case "$arg" in
+ --no-yasm)
+ HAVE_YASM=0
+ ;;
+ --no-gmp)
+ HAVE_GMP=0
+ ;;
+ --no-openssl)
+ HAVE_OPENSSL=0
+ ;;
+ --use-5x64)
+ HAVE_LIMB=64
+ ;;
+ esac
+done
+
+LINK_OPENSSL=0
+LINK_GMP=0
+USE_ASM=0
+
+# select field implementation
+if [ "$HAVE_YASM" = "1" ]; then
+ CFLAGS_FIELD="-DUSE_FIELD_5X$HAVE_LIMB -DUSE_FIELD_5X${HAVE_LIMB}_ASM"
+ USE_ASM=1
+elif [ "$HAVE_INT128" = "1" ]; then
+ CFLAGS_FIELD="-DUSE_FIELD_5X$HAVE_LIMB -DUSE_FIELD_5X${HAVE_LIMB}_INT128"
+elif [ "$HAVE_GMP" = "1" ]; then
+ CFLAGS_FIELD="-DUSE_FIELD_GMP"
+ LINK_GMP=1
+else
+ CFLAGS_FIELD="-DUSE_FIELD_10X26"
+fi
+
+# select num implementation
+if [ "$HAVE_GMP" = "1" ]; then
+ CFLAGS_NUM="-DUSE_NUM_GMP -DUSE_FIELD_INV_NUM"
+ LINK_GMP=1
+elif [ "$HAVE_OPENSSL" = "1" ]; then
+ CFLAGS_NUM="-DUSE_NUM_OPENSSL -DUSE_FIELD_INV_BUILTIN"
+ LINK_OPENSSL=1
+else
+ echo "No usable num implementation found" >&2
+ exit 1
+fi
+
+CFLAGS_EXTRA="$CFLAGS_FIELD $CFLAGS_NUM"
+LDFLAGS_EXTRA=""
+if [ "$LINK_GMP" = "1" ]; then
+ LDFLAGS_EXTRA="-lgmp"
+fi
+if [ "$LINK_OPENSSL" = "1" ]; then
+ LDFLAGS_EXTRA="-lcrypto"
+else
+ if [ "$HAVE_OPENSSL_EC" = "1" ]; then
+ LDFLAGS_TEST_EXTRA="-lcrypto"
+ fi
+fi
+
+CFLAGS_TEST_EXTRA=""
+if [ "$HAVE_OPENSSL_EC" = "1" ]; then
+ CFLAGS_TEST_EXTRA="-DENABLE_OPENSSL_TESTS"
+fi
+
+echo "CC=$CC" > config.mk
+echo "YASM=$YASM" >>config.mk
+echo "CFLAGS_EXTRA=$CFLAGS_EXTRA" >> config.mk
+echo "CFLAGS_TEST_EXTRA=$CFLAGS_TEST_EXTRA" >> config.mk
+echo "LDFLAGS_EXTRA=$LDFLAGS_EXTRA" >> config.mk
+echo "LDFLAGS_TEST_EXTRA=$LDFLAGS_TEST_EXTRA" >> config.mk
+echo "USE_ASM=$USE_ASM" >>config.mk
+echo "HAVE_LIMB=$HAVE_LIMB" >>config.mk
+echo "OPTLEVEL=O2" >>config.mk
diff --git a/crypto/secp256k1/secp256k1/include/secp256k1.h b/crypto/secp256k1/secp256k1/include/secp256k1.h
new file mode 100644
index 000000000..fd6d6b1f4
--- /dev/null
+++ b/crypto/secp256k1/secp256k1/include/secp256k1.h
@@ -0,0 +1,121 @@
+#ifndef _SECP256K1_
+#define _SECP256K1_
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+/** Initialize the library. This may take some time (10-100 ms).
+ * You need to call this before calling any other function.
+ * It cannot run in parallel with any other functions, but once
+ * secp256k1_start() returns, all other functions are thread-safe.
+ */
+void secp256k1_start(void);
+
+/** Free all memory associated with this library. After this, no
+ * functions can be called anymore, except secp256k1_start()
+ */
+void secp256k1_stop(void);
+
+/** Verify an ECDSA signature.
+ * Returns: 1: correct signature
+ * 0: incorrect signature
+ * -1: invalid public key
+ * -2: invalid signature
+ */
+int secp256k1_ecdsa_verify(const unsigned char *msg, int msglen,
+ const unsigned char *sig, int siglen,
+ const unsigned char *pubkey, int pubkeylen);
+
+/** Create an ECDSA signature.
+ * Returns: 1: signature created
+ * 0: nonce invalid, try another one
+ * In: msg: the message being signed
+ * msglen: the length of the message being signed
+ * seckey: pointer to a 32-byte secret key (assumed to be valid)
+ * nonce: pointer to a 32-byte nonce (generated with a cryptographic PRNG)
+ * Out: sig: pointer to a 72-byte array where the signature will be placed.
+ * siglen: pointer to an int, which will be updated to the signature length (<=72).
+ */
+int secp256k1_ecdsa_sign(const unsigned char *msg, int msglen,
+ unsigned char *sig, int *siglen,
+ const unsigned char *seckey,
+ const unsigned char *nonce);
+
+/** Create a compact ECDSA signature (64 byte + recovery id).
+ * Returns: 1: signature created
+ * 0: nonce invalid, try another one
+ * In: msg: the message being signed
+ * msglen: the length of the message being signed
+ * seckey: pointer to a 32-byte secret key (assumed to be valid)
+ * nonce: pointer to a 32-byte nonce (generated with a cryptographic PRNG)
+ * Out: sig: pointer to a 64-byte array where the signature will be placed.
+ * recid: pointer to an int, which will be updated to contain the recovery id.
+ */
+int secp256k1_ecdsa_sign_compact(const unsigned char *msg, int msglen,
+ unsigned char *sig64,
+ const unsigned char *seckey,
+ const unsigned char *nonce,
+ int *recid);
+
+/** Recover an ECDSA public key from a compact signature.
+ * Returns: 1: public key succesfully recovered (which guarantees a correct signature).
+ * 0: otherwise.
+ * In: msg: the message assumed to be signed
+ * msglen: the length of the message
+ * sig64: signature as 64 byte array
+ * compressed: whether to recover a compressed or uncompressed pubkey
+ * recid: the recovery id (as returned by ecdsa_sign_compact)
+ * Out: pubkey: pointer to a 33 or 65 byte array to put the pubkey.
+ * pubkeylen: pointer to an int that will contain the pubkey length.
+ */
+
+int secp256k1_ecdsa_recover_compact(const unsigned char *msg, int msglen,
+ const unsigned char *sig64,
+ unsigned char *pubkey, int *pubkeylen,
+ int compressed, int recid);
+
+/** Verify an ECDSA secret key.
+ * Returns: 1: secret key is valid
+ * 0: secret key is invalid
+ * In: seckey: pointer to a 32-byte secret key
+ */
+int secp256k1_ecdsa_seckey_verify(const unsigned char *seckey);
+
+/** Just validate a public key.
+ * Returns: 1: valid public key
+ * 0: invalid public key
+ */
+int secp256k1_ecdsa_pubkey_verify(const unsigned char *pubkey, int pubkeylen);
+
+/** Compute the public key for a secret key.
+ * In: compressed: whether the computed public key should be compressed
+ * seckey: pointer to a 32-byte private key.
+ * Out: pubkey: pointer to a 33-byte (if compressed) or 65-byte (if uncompressed)
+ * area to store the public key.
+ * pubkeylen: pointer to int that will be updated to contains the pubkey's
+ * length.
+ * Returns: 1: secret was valid, public key stores
+ * 0: secret was invalid, try again.
+ */
+int secp256k1_ecdsa_pubkey_create(unsigned char *pubkey, int *pubkeylen, const unsigned char *seckey, int compressed);
+
+int secp256k1_ecdsa_pubkey_decompress(unsigned char *pubkey, int *pubkeylen);
+
+int secp256k1_ecdsa_privkey_export(const unsigned char *seckey,
+ unsigned char *privkey, int *privkeylen,
+ int compressed);
+
+int secp256k1_ecdsa_privkey_import(unsigned char *seckey,
+ const unsigned char *privkey, int privkeylen);
+
+int secp256k1_ecdsa_privkey_tweak_add(unsigned char *seckey, const unsigned char *tweak);
+int secp256k1_ecdsa_pubkey_tweak_add(unsigned char *pubkey, int pubkeylen, const unsigned char *tweak);
+int secp256k1_ecdsa_privkey_tweak_mul(unsigned char *seckey, const unsigned char *tweak);
+int secp256k1_ecdsa_pubkey_tweak_mul(unsigned char *pubkey, int pubkeylen, const unsigned char *tweak);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif
diff --git a/crypto/secp256k1/secp256k1/src/bench.c b/crypto/secp256k1/secp256k1/src/bench.c
new file mode 100644
index 000000000..eeb71343f
--- /dev/null
+++ b/crypto/secp256k1/secp256k1/src/bench.c
@@ -0,0 +1,64 @@
+// Copyright (c) 2013 Pieter Wuille
+// Distributed under the MIT/X11 software license, see the accompanying
+// file COPYING or http://www.opensource.org/licenses/mit-license.php.
+
+#include <stdio.h>
+
+#include "impl/num.h"
+#include "impl/field.h"
+#include "impl/group.h"
+#include "impl/ecmult.h"
+#include "impl/ecdsa.h"
+#include "impl/util.h"
+
+void random_num_order(secp256k1_num_t *num) {
+ do {
+ unsigned char b32[32];
+ secp256k1_rand256(b32);
+ secp256k1_num_set_bin(num, b32, 32);
+ if (secp256k1_num_is_zero(num))
+ continue;
+ if (secp256k1_num_cmp(num, &secp256k1_ge_consts->order) >= 0)
+ continue;
+ break;
+ } while(1);
+}
+
+int main() {
+ secp256k1_fe_start();
+ secp256k1_ge_start();
+ secp256k1_ecmult_start();
+
+ secp256k1_fe_t x;
+ const secp256k1_num_t *order = &secp256k1_ge_consts->order;
+ secp256k1_num_t r, s, m;
+ secp256k1_num_init(&r);
+ secp256k1_num_init(&s);
+ secp256k1_num_init(&m);
+ secp256k1_ecdsa_sig_t sig;
+ secp256k1_ecdsa_sig_init(&sig);
+ secp256k1_fe_set_hex(&x, "a357ae915c4a65281309edf20504740f0eb3343990216b4f81063cb65f2f7e0f", 64);
+ int cnt = 0;
+ int good = 0;
+ for (int i=0; i<1000000; i++) {
+ random_num_order(&r);
+ random_num_order(&s);
+ random_num_order(&m);
+ secp256k1_ecdsa_sig_set_rs(&sig, &r, &s);
+ secp256k1_ge_t pubkey; secp256k1_ge_set_xo(&pubkey, &x, 1);
+ if (secp256k1_ge_is_valid(&pubkey)) {
+ cnt++;
+ good += secp256k1_ecdsa_sig_verify(&sig, &pubkey, &m);
+ }
+ }
+ printf("%i/%i\n", good, cnt);
+ secp256k1_num_free(&r);
+ secp256k1_num_free(&s);
+ secp256k1_num_free(&m);
+ secp256k1_ecdsa_sig_free(&sig);
+
+ secp256k1_ecmult_stop();
+ secp256k1_ge_stop();
+ secp256k1_fe_stop();
+ return 0;
+}
diff --git a/crypto/secp256k1/secp256k1/src/ecdsa.h b/crypto/secp256k1/secp256k1/src/ecdsa.h
new file mode 100644
index 000000000..d9faaa3e8
--- /dev/null
+++ b/crypto/secp256k1/secp256k1/src/ecdsa.h
@@ -0,0 +1,28 @@
+// Copyright (c) 2013 Pieter Wuille
+// Distributed under the MIT/X11 software license, see the accompanying
+// file COPYING or http://www.opensource.org/licenses/mit-license.php.
+
+#ifndef _SECP256K1_ECDSA_
+#define _SECP256K1_ECDSA_
+
+#include "num.h"
+
+typedef struct {
+ secp256k1_num_t r, s;
+} secp256k1_ecdsa_sig_t;
+
+void static secp256k1_ecdsa_sig_init(secp256k1_ecdsa_sig_t *r);
+void static secp256k1_ecdsa_sig_free(secp256k1_ecdsa_sig_t *r);
+
+int static secp256k1_ecdsa_pubkey_parse(secp256k1_ge_t *elem, const unsigned char *pub, int size);
+void static secp256k1_ecdsa_pubkey_serialize(secp256k1_ge_t *elem, unsigned char *pub, int *size, int compressed);
+int static secp256k1_ecdsa_sig_parse(secp256k1_ecdsa_sig_t *r, const unsigned char *sig, int size);
+int static secp256k1_ecdsa_sig_serialize(unsigned char *sig, int *size, const secp256k1_ecdsa_sig_t *a);
+int static secp256k1_ecdsa_sig_verify(const secp256k1_ecdsa_sig_t *sig, const secp256k1_ge_t *pubkey, const secp256k1_num_t *message);
+int static secp256k1_ecdsa_sig_sign(secp256k1_ecdsa_sig_t *sig, const secp256k1_num_t *seckey, const secp256k1_num_t *message, const secp256k1_num_t *nonce, int *recid);
+int static secp256k1_ecdsa_sig_recover(const secp256k1_ecdsa_sig_t *sig, secp256k1_ge_t *pubkey, const secp256k1_num_t *message, int recid);
+void static secp256k1_ecdsa_sig_set_rs(secp256k1_ecdsa_sig_t *sig, const secp256k1_num_t *r, const secp256k1_num_t *s);
+int static secp256k1_ecdsa_privkey_parse(secp256k1_num_t *key, const unsigned char *privkey, int privkeylen);
+int static secp256k1_ecdsa_privkey_serialize(unsigned char *privkey, int *privkeylen, const secp256k1_num_t *key, int compressed);
+
+#endif
diff --git a/crypto/secp256k1/secp256k1/src/ecmult.h b/crypto/secp256k1/secp256k1/src/ecmult.h
new file mode 100644
index 000000000..856bd284f
--- /dev/null
+++ b/crypto/secp256k1/secp256k1/src/ecmult.h
@@ -0,0 +1,19 @@
+// Copyright (c) 2013 Pieter Wuille
+// Distributed under the MIT/X11 software license, see the accompanying
+// file COPYING or http://www.opensource.org/licenses/mit-license.php.
+
+#ifndef _SECP256K1_ECMULT_
+#define _SECP256K1_ECMULT_
+
+#include "num.h"
+#include "group.h"
+
+static void secp256k1_ecmult_start(void);
+static void secp256k1_ecmult_stop(void);
+
+/** Multiply with the generator: R = a*G */
+static void secp256k1_ecmult_gen(secp256k1_gej_t *r, const secp256k1_num_t *a);
+/** Double multiply: R = na*A + ng*G */
+static void secp256k1_ecmult(secp256k1_gej_t *r, const secp256k1_gej_t *a, const secp256k1_num_t *na, const secp256k1_num_t *ng);
+
+#endif
diff --git a/crypto/secp256k1/secp256k1/src/field.h b/crypto/secp256k1/secp256k1/src/field.h
new file mode 100644
index 000000000..4e0f26179
--- /dev/null
+++ b/crypto/secp256k1/secp256k1/src/field.h
@@ -0,0 +1,101 @@
+// Copyright (c) 2013 Pieter Wuille
+// Distributed under the MIT/X11 software license, see the accompanying
+// file COPYING or http://www.opensource.org/licenses/mit-license.php.
+
+#ifndef _SECP256K1_FIELD_
+#define _SECP256K1_FIELD_
+
+/** Field element module.
+ *
+ * Field elements can be represented in several ways, but code accessing
+ * it (and implementations) need to take certain properaties into account:
+ * - Each field element can be normalized or not.
+ * - Each field element has a magnitude, which represents how far away
+ * its representation is away from normalization. Normalized elements
+ * always have a magnitude of 1, but a magnitude of 1 doesn't imply
+ * normality.
+ */
+
+#if defined(USE_FIELD_GMP)
+#include "field_gmp.h"
+#elif defined(USE_FIELD_10X26)
+#include "field_10x26.h"
+#elif defined(USE_FIELD_5X52)
+#include "field_5x52.h"
+#elif defined(USE_FIELD_5X64)
+#include "field_5x64.h"
+#else
+#error "Please select field implementation"
+#endif
+
+typedef struct {
+ secp256k1_num_t p;
+} secp256k1_fe_consts_t;
+
+static const secp256k1_fe_consts_t *secp256k1_fe_consts = NULL;
+
+/** Initialize field element precomputation data. */
+void static secp256k1_fe_start(void);
+
+/** Unload field element precomputation data. */
+void static secp256k1_fe_stop(void);
+
+/** Normalize a field element. */
+void static secp256k1_fe_normalize(secp256k1_fe_t *r);
+
+/** Set a field element equal to a small integer. Resulting field element is normalized. */
+void static secp256k1_fe_set_int(secp256k1_fe_t *r, int a);
+
+/** Verify whether a field element is zero. Requires the input to be normalized. */
+int static secp256k1_fe_is_zero(const secp256k1_fe_t *a);
+
+/** Check the "oddness" of a field element. Requires the input to be normalized. */
+int static secp256k1_fe_is_odd(const secp256k1_fe_t *a);
+
+/** Compare two field elements. Requires both inputs to be normalized */
+int static secp256k1_fe_equal(const secp256k1_fe_t *a, const secp256k1_fe_t *b);
+
+/** Set a field element equal to 32-byte big endian value. Resulting field element is normalized. */
+void static secp256k1_fe_set_b32(secp256k1_fe_t *r, const unsigned char *a);
+
+/** Convert a field element to a 32-byte big endian value. Requires the input to be normalized */
+void static secp256k1_fe_get_b32(unsigned char *r, const secp256k1_fe_t *a);
+
+/** Set a field element equal to the additive inverse of another. Takes a maximum magnitude of the input
+ * as an argument. The magnitude of the output is one higher. */
+void static secp256k1_fe_negate(secp256k1_fe_t *r, const secp256k1_fe_t *a, int m);
+
+/** Multiplies the passed field element with a small integer constant. Multiplies the magnitude by that
+ * small integer. */
+void static secp256k1_fe_mul_int(secp256k1_fe_t *r, int a);
+
+/** Adds a field element to another. The result has the sum of the inputs' magnitudes as magnitude. */
+void static secp256k1_fe_add(secp256k1_fe_t *r, const secp256k1_fe_t *a);
+
+/** Sets a field element to be the product of two others. Requires the inputs' magnitudes to be at most 8.
+ * The output magnitude is 1 (but not guaranteed to be normalized). */
+void static secp256k1_fe_mul(secp256k1_fe_t *r, const secp256k1_fe_t *a, const secp256k1_fe_t *b);
+
+/** Sets a field element to be the square of another. Requires the input's magnitude to be at most 8.
+ * The output magnitude is 1 (but not guaranteed to be normalized). */
+void static secp256k1_fe_sqr(secp256k1_fe_t *r, const secp256k1_fe_t *a);
+
+/** Sets a field element to be the (modular) square root of another. Requires the inputs' magnitude to
+ * be at most 8. The output magnitude is 1 (but not guaranteed to be normalized). */
+void static secp256k1_fe_sqrt(secp256k1_fe_t *r, const secp256k1_fe_t *a);
+
+/** Sets a field element to be the (modular) inverse of another. Requires the input's magnitude to be
+ * at most 8. The output magnitude is 1 (but not guaranteed to be normalized). */
+void static secp256k1_fe_inv(secp256k1_fe_t *r, const secp256k1_fe_t *a);
+
+/** Potentially faster version of secp256k1_fe_inv, without constant-time guarantee. */
+void static secp256k1_fe_inv_var(secp256k1_fe_t *r, const secp256k1_fe_t *a);
+
+
+/** Convert a field element to a hexadecimal string. */
+void static secp256k1_fe_get_hex(char *r, int *rlen, const secp256k1_fe_t *a);
+
+/** Convert a hexadecimal string to a field element. */
+void static secp256k1_fe_set_hex(secp256k1_fe_t *r, const char *a, int alen);
+
+#endif
diff --git a/crypto/secp256k1/secp256k1/src/field_10x26.h b/crypto/secp256k1/secp256k1/src/field_10x26.h
new file mode 100644
index 000000000..d544139e8
--- /dev/null
+++ b/crypto/secp256k1/secp256k1/src/field_10x26.h
@@ -0,0 +1,19 @@
+// Copyright (c) 2013 Pieter Wuille
+// Distributed under the MIT/X11 software license, see the accompanying
+// file COPYING or http://www.opensource.org/licenses/mit-license.php.
+
+#ifndef _SECP256K1_FIELD_REPR_
+#define _SECP256K1_FIELD_REPR_
+
+#include <stdint.h>
+
+typedef struct {
+ // X = sum(i=0..9, elem[i]*2^26) mod n
+ uint32_t n[10];
+#ifdef VERIFY
+ int magnitude;
+ int normalized;
+#endif
+} secp256k1_fe_t;
+
+#endif
diff --git a/crypto/secp256k1/secp256k1/src/field_5x52.h b/crypto/secp256k1/secp256k1/src/field_5x52.h
new file mode 100644
index 000000000..9d5de2cc4
--- /dev/null
+++ b/crypto/secp256k1/secp256k1/src/field_5x52.h
@@ -0,0 +1,19 @@
+// Copyright (c) 2013 Pieter Wuille
+// Distributed under the MIT/X11 software license, see the accompanying
+// file COPYING or http://www.opensource.org/licenses/mit-license.php.
+
+#ifndef _SECP256K1_FIELD_REPR_
+#define _SECP256K1_FIELD_REPR_
+
+#include <stdint.h>
+
+typedef struct {
+ // X = sum(i=0..4, elem[i]*2^52) mod n
+ uint64_t n[5];
+#ifdef VERIFY
+ int magnitude;
+ int normalized;
+#endif
+} secp256k1_fe_t;
+
+#endif
diff --git a/crypto/secp256k1/secp256k1/src/field_5x52_asm.asm b/crypto/secp256k1/secp256k1/src/field_5x52_asm.asm
new file mode 100644
index 000000000..9237b3687
--- /dev/null
+++ b/crypto/secp256k1/secp256k1/src/field_5x52_asm.asm
@@ -0,0 +1,463 @@
+ ;; Added by Diederik Huys, March 2013
+ ;;
+ ;; Provided public procedures:
+ ;; secp256k1_fe_mul_inner
+ ;; secp256k1_fe_sqr_inner
+ ;;
+ ;; Needed tools: YASM (http://yasm.tortall.net)
+ ;;
+ ;;
+
+ BITS 64
+
+ ;; Procedure ExSetMult
+ ;; Register Layout:
+ ;; INPUT: rdi = a->n
+ ;; rsi = b->n
+ ;; rdx = r->a
+ ;;
+ ;; INTERNAL: rdx:rax = multiplication accumulator
+ ;; r9:r8 = c
+ ;; r10-r13 = t0-t3
+ ;; r14 = b.n[0] / t4
+ ;; r15 = b.n[1] / t5
+ ;; rbx = b.n[2] / t6
+ ;; rcx = b.n[3] / t7
+ ;; rbp = Constant 0FFFFFFFFFFFFFh / t8
+ ;; rsi = b.n / b.n[4] / t9
+
+ GLOBAL secp256k1_fe_mul_inner
+ ALIGN 32
+secp256k1_fe_mul_inner:
+ push rbp
+ push rbx
+ push r12
+ push r13
+ push r14
+ push r15
+ push rdx
+ mov r14,[rsi+8*0] ; preload b.n[0]. This will be the case until
+ ; b.n[0] is no longer needed, then we reassign
+ ; r14 to t4
+ ;; c=a.n[0] * b.n[0]
+ mov rax,[rdi+0*8] ; load a.n[0]
+ mov rbp,0FFFFFFFFFFFFFh
+ mul r14 ; rdx:rax=a.n[0]*b.n[0]
+ mov r15,[rsi+1*8]
+ mov r10,rbp ; load modulus into target register for t0
+ mov r8,rax
+ and r10,rax ; only need lower qword of c
+ shrd r8,rdx,52
+ xor r9,r9 ; c < 2^64, so we ditch the HO part
+
+ ;; c+=a.n[0] * b.n[1] + a.n[1] * b.n[0]
+ mov rax,[rdi+0*8]
+ mul r15
+ add r8,rax
+ adc r9,rdx
+
+ mov rax,[rdi+1*8]
+ mul r14
+ mov r11,rbp
+ mov rbx,[rsi+2*8]
+ add r8,rax
+ adc r9,rdx
+ and r11,r8
+ shrd r8,r9,52
+ xor r9,r9
+
+ ;; c+=a.n[0 1 2] * b.n[2 1 0]
+ mov rax,[rdi+0*8]
+ mul rbx
+ add r8,rax
+ adc r9,rdx
+
+ mov rax,[rdi+1*8]
+ mul r15
+ add r8,rax
+ adc r9,rdx
+
+ mov rax,[rdi+2*8]
+ mul r14
+ mov r12,rbp
+ mov rcx,[rsi+3*8]
+ add r8,rax
+ adc r9,rdx
+ and r12,r8
+ shrd r8,r9,52
+ xor r9,r9
+
+ ;; c+=a.n[0 1 2 3] * b.n[3 2 1 0]
+ mov rax,[rdi+0*8]
+ mul rcx
+ add r8,rax
+ adc r9,rdx
+
+ mov rax,[rdi+1*8]
+ mul rbx
+ add r8,rax
+ adc r9,rdx
+
+ mov rax,[rdi+2*8]
+ mul r15
+ add r8,rax
+ adc r9,rdx
+
+ mov rax,[rdi+3*8]
+ mul r14
+ mov r13,rbp
+ mov rsi,[rsi+4*8] ; load b.n[4] and destroy pointer
+ add r8,rax
+ adc r9,rdx
+ and r13,r8
+
+ shrd r8,r9,52
+ xor r9,r9
+
+
+ ;; c+=a.n[0 1 2 3 4] * b.n[4 3 2 1 0]
+ mov rax,[rdi+0*8]
+ mul rsi
+ add r8,rax
+ adc r9,rdx
+
+ mov rax,[rdi+1*8]
+ mul rcx
+ add r8,rax
+ adc r9,rdx
+
+ mov rax,[rdi+2*8]
+ mul rbx
+ add r8,rax
+ adc r9,rdx
+
+ mov rax,[rdi+3*8]
+ mul r15
+ add r8,rax
+ adc r9,rdx
+
+ mov rax,[rdi+4*8]
+ mul r14
+ mov r14,rbp ; load modulus into t4 and destroy a.n[0]
+ add r8,rax
+ adc r9,rdx
+ and r14,r8
+ shrd r8,r9,52
+ xor r9,r9
+
+ ;; c+=a.n[1 2 3 4] * b.n[4 3 2 1]
+ mov rax,[rdi+1*8]
+ mul rsi
+ add r8,rax
+ adc r9,rdx
+
+ mov rax,[rdi+2*8]
+ mul rcx
+ add r8,rax
+ adc r9,rdx
+
+ mov rax,[rdi+3*8]
+ mul rbx
+ add r8,rax
+ adc r9,rdx
+
+ mov rax,[rdi+4*8]
+ mul r15
+ mov r15,rbp
+ add r8,rax
+ adc r9,rdx
+
+ and r15,r8
+ shrd r8,r9,52
+ xor r9,r9
+
+ ;; c+=a.n[2 3 4] * b.n[4 3 2]
+ mov rax,[rdi+2*8]
+ mul rsi
+ add r8,rax
+ adc r9,rdx
+
+ mov rax,[rdi+3*8]
+ mul rcx
+ add r8,rax
+ adc r9,rdx
+
+ mov rax,[rdi+4*8]
+ mul rbx
+ mov rbx,rbp
+ add r8,rax
+ adc r9,rdx
+
+ and rbx,r8
+ shrd r8,r9,52
+ xor r9,r9
+
+ ;; c+=a.n[3 4] * b.n[4 3]
+ mov rax,[rdi+3*8]
+ mul rsi
+ add r8,rax
+ adc r9,rdx
+
+ mov rax,[rdi+4*8]
+ mul rcx
+ mov rcx,rbp
+ add r8,rax
+ adc r9,rdx
+ and rcx,r8
+ shrd r8,r9,52
+ xor r9,r9
+
+ ;; c+=a.n[4] * b.n[4]
+ mov rax,[rdi+4*8]
+ mul rsi
+ ;; mov rbp,rbp ; modulus already there!
+ add r8,rax
+ adc r9,rdx
+ and rbp,r8
+ shrd r8,r9,52
+ xor r9,r9
+
+ mov rsi,r8 ; load c into t9 and destroy b.n[4]
+
+ ;; *******************************************************
+common_exit_norm:
+ mov rdi,01000003D10h ; load constant
+
+ mov rax,r15 ; get t5
+ mul rdi
+ add rax,r10 ; +t0
+ adc rdx,0
+ mov r10,0FFFFFFFFFFFFFh ; modulus. Sadly, we ran out of registers!
+ mov r8,rax ; +c
+ and r10,rax
+ shrd r8,rdx,52
+ xor r9,r9
+
+ mov rax,rbx ; get t6
+ mul rdi
+ add rax,r11 ; +t1
+ adc rdx,0
+ mov r11,0FFFFFFFFFFFFFh ; modulus
+ add r8,rax ; +c
+ adc r9,rdx
+ and r11,r8
+ shrd r8,r9,52
+ xor r9,r9
+
+ mov rax,rcx ; get t7
+ mul rdi
+ add rax,r12 ; +t2
+ adc rdx,0
+ pop rbx ; retrieve pointer to this.n
+ mov r12,0FFFFFFFFFFFFFh ; modulus
+ add r8,rax ; +c
+ adc r9,rdx
+ and r12,r8
+ mov [rbx+2*8],r12 ; mov into this.n[2]
+ shrd r8,r9,52
+ xor r9,r9
+
+ mov rax,rbp ; get t8
+ mul rdi
+ add rax,r13 ; +t3
+ adc rdx,0
+ mov r13,0FFFFFFFFFFFFFh ; modulus
+ add r8,rax ; +c
+ adc r9,rdx
+ and r13,r8
+ mov [rbx+3*8],r13 ; -> this.n[3]
+ shrd r8,r9,52
+ xor r9,r9
+
+ mov rax,rsi ; get t9
+ mul rdi
+ add rax,r14 ; +t4
+ adc rdx,0
+ mov r14,0FFFFFFFFFFFFh ; !!!
+ add r8,rax ; +c
+ adc r9,rdx
+ and r14,r8
+ mov [rbx+4*8],r14 ; -> this.n[4]
+ shrd r8,r9,48 ; !!!
+ xor r9,r9
+
+ mov rax,01000003D1h
+ mul r8
+ add rax,r10
+ adc rdx,0
+ mov r10,0FFFFFFFFFFFFFh ; modulus
+ mov r8,rax
+ and rax,r10
+ shrd r8,rdx,52
+ mov [rbx+0*8],rax ; -> this.n[0]
+ add r8,r11
+ mov [rbx+1*8],r8 ; -> this.n[1]
+
+ pop r15
+ pop r14
+ pop r13
+ pop r12
+ pop rbx
+ pop rbp
+ ret
+
+
+ ;; PROC ExSetSquare
+ ;; Register Layout:
+ ;; INPUT: rdi = a.n
+ ;; rsi = this.a
+ ;; INTERNAL: rdx:rax = multiplication accumulator
+ ;; r9:r8 = c
+ ;; r10-r13 = t0-t3
+ ;; r14 = a.n[0] / t4
+ ;; r15 = a.n[1] / t5
+ ;; rbx = a.n[2] / t6
+ ;; rcx = a.n[3] / t7
+ ;; rbp = 0FFFFFFFFFFFFFh / t8
+ ;; rsi = a.n[4] / t9
+ GLOBAL secp256k1_fe_sqr_inner
+ ALIGN 32
+secp256k1_fe_sqr_inner:
+ push rbp
+ push rbx
+ push r12
+ push r13
+ push r14
+ push r15
+ push rsi
+ mov rbp,0FFFFFFFFFFFFFh
+
+ ;; c=a.n[0] * a.n[0]
+ mov r14,[rdi+0*8] ; r14=a.n[0]
+ mov r10,rbp ; modulus
+ mov rax,r14
+ mul rax
+ mov r15,[rdi+1*8] ; a.n[1]
+ add r14,r14 ; r14=2*a.n[0]
+ mov r8,rax
+ and r10,rax ; only need lower qword
+ shrd r8,rdx,52
+ xor r9,r9
+
+ ;; c+=2*a.n[0] * a.n[1]
+ mov rax,r14 ; r14=2*a.n[0]
+ mul r15
+ mov rbx,[rdi+2*8] ; rbx=a.n[2]
+ mov r11,rbp ; modulus
+ add r8,rax
+ adc r9,rdx
+ and r11,r8
+ shrd r8,r9,52
+ xor r9,r9
+
+ ;; c+=2*a.n[0]*a.n[2]+a.n[1]*a.n[1]
+ mov rax,r14
+ mul rbx
+ add r8,rax
+ adc r9,rdx
+
+ mov rax,r15
+ mov r12,rbp ; modulus
+ mul rax
+ mov rcx,[rdi+3*8] ; rcx=a.n[3]
+ add r15,r15 ; r15=a.n[1]*2
+ add r8,rax
+ adc r9,rdx
+ and r12,r8 ; only need lower dword
+ shrd r8,r9,52
+ xor r9,r9
+
+ ;; c+=2*a.n[0]*a.n[3]+2*a.n[1]*a.n[2]
+ mov rax,r14
+ mul rcx
+ add r8,rax
+ adc r9,rdx
+
+ mov rax,r15 ; rax=2*a.n[1]
+ mov r13,rbp ; modulus
+ mul rbx
+ mov rsi,[rdi+4*8] ; rsi=a.n[4]
+ add r8,rax
+ adc r9,rdx
+ and r13,r8
+ shrd r8,r9,52
+ xor r9,r9
+
+ ;; c+=2*a.n[0]*a.n[4]+2*a.n[1]*a.n[3]+a.n[2]*a.n[2]
+ mov rax,r14 ; last time we need 2*a.n[0]
+ mul rsi
+ add r8,rax
+ adc r9,rdx
+
+ mov rax,r15
+ mul rcx
+ mov r14,rbp ; modulus
+ add r8,rax
+ adc r9,rdx
+
+ mov rax,rbx
+ mul rax
+ add rbx,rbx ; rcx=2*a.n[2]
+ add r8,rax
+ adc r9,rdx
+ and r14,r8
+ shrd r8,r9,52
+ xor r9,r9
+
+ ;; c+=2*a.n[1]*a.n[4]+2*a.n[2]*a.n[3]
+ mov rax,r15 ; last time we need 2*a.n[1]
+ mul rsi
+ add r8,rax
+ adc r9,rdx
+
+ mov rax,rbx
+ mul rcx
+ mov r15,rbp ; modulus
+ add r8,rax
+ adc r9,rdx
+ and r15,r8
+ shrd r8,r9,52
+ xor r9,r9
+
+ ;; c+=2*a.n[2]*a.n[4]+a.n[3]*a.n[3]
+ mov rax,rbx ; last time we need 2*a.n[2]
+ mul rsi
+ add r8,rax
+ adc r9,rdx
+
+ mov rax,rcx ; a.n[3]
+ mul rax
+ mov rbx,rbp ; modulus
+ add r8,rax
+ adc r9,rdx
+ and rbx,r8 ; only need lower dword
+ lea rax,[2*rcx]
+ shrd r8,r9,52
+ xor r9,r9
+
+ ;; c+=2*a.n[3]*a.n[4]
+ mul rsi
+ mov rcx,rbp ; modulus
+ add r8,rax
+ adc r9,rdx
+ and rcx,r8 ; only need lower dword
+ shrd r8,r9,52
+ xor r9,r9
+
+ ;; c+=a.n[4]*a.n[4]
+ mov rax,rsi
+ mul rax
+ ;; mov rbp,rbp ; modulus is already there!
+ add r8,rax
+ adc r9,rdx
+ and rbp,r8
+ shrd r8,r9,52
+ xor r9,r9
+
+ mov rsi,r8
+
+ ;; *******************************************************
+ jmp common_exit_norm
+ end
+
+
diff --git a/crypto/secp256k1/secp256k1/src/field_5x64.h b/crypto/secp256k1/secp256k1/src/field_5x64.h
new file mode 100644
index 000000000..f3d47f547
--- /dev/null
+++ b/crypto/secp256k1/secp256k1/src/field_5x64.h
@@ -0,0 +1,19 @@
+// Copyright (c) 2013 Pieter Wuille
+// Distributed under the MIT/X11 software license, see the accompanying
+// file COPYING or http://www.opensource.org/licenses/mit-license.php.
+
+#ifndef _SECP256K1_FIELD_REPR_
+#define _SECP256K1_FIELD_REPR_
+
+#include <stdint.h>
+
+typedef struct {
+ // X = sum(i=0..4, elem[i]*2^64) mod n
+ uint64_t n[5];
+#ifdef VERIFY
+ int reduced; // n[4] == 0
+ int normalized; // reduced and X < 2^256 - 0x100003D1
+#endif
+} secp256k1_fe_t;
+
+#endif
diff --git a/crypto/secp256k1/secp256k1/src/field_5x64_asm.asm b/crypto/secp256k1/secp256k1/src/field_5x64_asm.asm
new file mode 100644
index 000000000..d449185c7
--- /dev/null
+++ b/crypto/secp256k1/secp256k1/src/field_5x64_asm.asm
@@ -0,0 +1,332 @@
+ ;; Added by Diederik Huys, March 2013
+ ;;
+ ;; Provided public procedures:
+ ;; secp256k1_fe_mul_inner
+ ;; secp256k1_fe_sqr_inner
+ ;;
+ ;; Needed tools: YASM (http://yasm.tortall.net)
+ ;;
+ ;;
+
+ BITS 64
+
+COMP_LIMB EQU 000000001000003D1h
+
+ ;; Procedure ExSetMult
+ ;; Register Layout:
+ ;; INPUT: rdi = a->n
+ ;; rsi = b->n
+ ;; rdx = r->a
+ ;;
+ ;; INTERNAL: rdx:rax = multiplication accumulator
+ ;; r8-r10 = c0-c2
+ ;; r11-r15 = b.n[0]-b.n[4] / r3 - r7
+ ;; rbx = r0
+ ;; rcx = r1
+ ;; rbp = r2
+ ;;
+ GLOBAL secp256k1_fe_mul_inner
+ ALIGN 32
+secp256k1_fe_mul_inner:
+ push rbp
+ push rbx
+ push r12
+ push r13
+ push r14
+ push r15
+ push rdx
+
+ mov r11,[rsi+8*0] ; preload b.n[0]
+
+ ;; step 1: mul_c2
+ mov rax,[rdi+0*8] ; load a.n[0]
+ mul r11 ; rdx:rax=a.n[0]*b.n[0]
+ mov r12,[rsi+1*8] ; preload b.n[1]
+ mov rbx,rax ; retire LO qword (r[0])
+ mov r8,rdx ; save overflow
+ xor r9,r9 ; overflow HO qwords
+ xor r10,r10
+
+ ;; c+=a.n[0] * b.n[1] + a.n[1] * b.n[0]
+ mov rax,[rdi+0*8]
+ mul r12
+ mov r13,[rsi+2*8] ; preload b.n[2]
+ add r8,rax ; still the same :-)
+ adc r9,rdx ;
+ adc r10,0 ; mmm...
+
+ mov rax,[rdi+1*8]
+ mul r11
+ add r8,rax
+ adc r9,rdx
+ adc r10,0
+ mov rcx,r8 ; retire r[1]
+ xor r8,r8
+
+ ;; c+=a.n[0 1 2] * b.n[2 1 0]
+ mov rax,[rdi+0*8]
+ mul r13
+ mov r14,[rsi+3*8] ; preload b.n[3]
+ add r9,rax
+ adc r10,rdx
+ adc r8,0
+
+ mov rax,[rdi+1*8]
+ mul r12
+ add r9,rax
+ adc r10,rdx
+ adc r8,0
+
+ mov rax,[rdi+2*8]
+ mul r11
+ add r9,rax
+ adc r10,rdx
+ adc r8,0
+ mov rbp,r9 ; retire r[2]
+ xor r9,r9
+
+ ;; c+=a.n[0 1 2 3] * b.n[3 2 1 0]
+ mov rax,[rdi+0*8]
+ mul r14
+ add r10,rax
+ adc r8,rdx
+ adc r9,0
+
+ mov rax,[rdi+1*8]
+ mul r13
+ add r10,rax
+ adc r8,rdx
+ adc r9,0
+
+ mov rax,[rdi+2*8]
+ mul r12
+ add r10,rax
+ adc r8,rdx
+ adc r9,0
+
+ mov rax,[rdi+3*8]
+ mul r11
+ add r10,rax
+ adc r8,rdx
+ adc r9,0
+ mov r11,r10 ; retire r[3]
+ xor r10,r10
+
+ ;; c+=a.n[1 2 3] * b.n[3 2 1]
+ mov rax,[rdi+1*8]
+ mul r14
+ add r8,rax
+ adc r9,rdx
+ adc r10,0
+
+ mov rax,[rdi+2*8]
+ mul r13
+ add r8,rax
+ adc r9,rdx
+ adc r10,0
+
+ mov rax,[rdi+3*8]
+ mul r12
+ add r8,rax
+ adc r9,rdx
+ adc r10,0
+ mov r12,r8 ; retire r[4]
+ xor r8,r8
+
+ ;; c+=a.n[2 3] * b.n[3 2]
+ mov rax,[rdi+2*8]
+ mul r14
+ add r9,rax ; still the same :-)
+ adc r10,rdx ;
+ adc r8,0 ; mmm...
+
+ mov rax,[rdi+3*8]
+ mul r13
+ add r9,rax
+ adc r10,rdx
+ adc r8,0
+ mov r13,r9 ; retire r[5]
+ xor r9,r9
+
+ ;; c+=a.n[3] * b.n[3]
+ mov rax,[rdi+3*8]
+ mul r14
+ add r10,rax
+ adc r8,rdx
+
+ mov r14,r10
+ mov r15,r8
+
+
+ ;; *******************************************************
+common_exit_norm:
+ mov rdi,COMP_LIMB
+ mov rax,r12
+ mul rdi
+ add rax,rbx
+ adc rcx,rdx
+ pop rbx
+ mov [rbx],rax
+
+ mov rax,r13 ; get r5
+ mul rdi
+ add rax,rcx ; +r1
+ adc rbp,rdx
+ mov [rbx+1*8],rax
+
+ mov rax,r14 ; get r6
+ mul rdi
+ add rax,rbp ; +r2
+ adc r11,rdx
+ mov [rbx+2*8],rax
+
+ mov rax,r15 ; get r7
+ mul rdi
+ add rax,r11 ; +r3
+ adc rdx,0
+ mov [rbx+3*8],rax
+ mov [rbx+4*8],rdx
+
+ pop r15
+ pop r14
+ pop r13
+ pop r12
+ pop rbx
+ pop rbp
+ ret
+
+
+ ;; PROC ExSetSquare
+ ;; Register Layout:
+ ;; INPUT: rdi = a.n
+ ;; rsi = this.a
+ ;; INTERNAL: rdx:rax = multiplication accumulator
+ ;; r8-r10 = c
+ ;; r11-r15 = a.n[0]-a.n[4] / r3-r7
+ ;; rbx = r0
+ ;; rcx = r1
+ ;; rbp = r2
+ GLOBAL secp256k1_fe_sqr_inner
+
+ ALIGN 32
+secp256k1_fe_sqr_inner:
+ push rbp
+ push rbx
+ push r12
+ push r13
+ push r14
+ push r15
+ push rsi
+
+ mov r11,[rdi+8*0] ; preload a.n[0]
+
+ ;; step 1: mul_c2
+ mov rax,r11 ; load a.n[0]
+ mul rax ; rdx:rax=a.n[0]²
+ mov r12,[rdi+1*8] ; preload a.n[1]
+ mov rbx,rax ; retire LO qword (r[0])
+ mov r8,rdx ; save overflow
+ xor r9,r9 ; overflow HO qwords
+ xor r10,r10
+
+ ;; c+=2*a.n[0] * a.n[1]
+ mov rax,r11 ; load a.n[0]
+ mul r12 ; rdx:rax=a.n[0] * a.n[1]
+ mov r13,[rdi+2*8] ; preload a.n[2]
+ add rax,rax ; rdx:rax*=2
+ adc rdx,rdx
+ adc r10,0
+ add r8,rax ; still the same :-)
+ adc r9,rdx
+ adc r10,0 ; mmm...
+
+ mov rcx,r8 ; retire r[1]
+ xor r8,r8
+
+ ;; c+=2*a.n[0]*a.n[2]+a.n[1]*a.n[1]
+ mov rax,r11 ; load a.n[0]
+ mul r13 ; * a.n[2]
+ mov r14,[rdi+3*8] ; preload a.n[3]
+ add rax,rax ; rdx:rax*=2
+ adc rdx,rdx
+ adc r8,0
+ add r9,rax
+ adc r10,rdx
+ adc r8,0
+
+ mov rax,r12
+ mul rax
+ add r9,rax
+ adc r10,rdx
+ adc r8,0
+
+
+ mov rbp,r9
+ xor r9,r9
+
+ ;; c+=2*a.n[0]*a.n[3]+2*a.n[1]*a.n[2]
+ mov rax,r11 ; load a.n[0]
+ mul r14 ; * a.n[3]
+ add rax,rax ; rdx:rax*=2
+ adc rdx,rdx
+ adc r9,0
+ add r10,rax
+ adc r8,rdx
+ adc r9,0
+
+ mov rax,r12 ; load a.n[1]
+ mul r13 ; * a.n[2]
+ add rax,rax
+ adc rdx,rdx
+ adc r9,0
+ add r10,rax
+ adc r8,rdx
+ adc r9,0
+
+ mov r11,r10
+ xor r10,r10
+
+ ;; c+=2*a.n[1]*a.n[3]+a.n[2]*a.n[2]
+ mov rax,r12 ; load a.n[1]
+ mul r14 ; * a.n[3]
+ add rax,rax ; rdx:rax*=2
+ adc rdx,rdx
+ adc r10,0
+ add r8,rax
+ adc r9,rdx
+ adc r10,0
+
+ mov rax,r13
+ mul rax
+ add r8,rax
+ adc r9,rdx
+ adc r10,0
+
+ mov r12,r8
+ xor r8,r8
+ ;; c+=2*a.n[2]*a.n[3]
+ mov rax,r13 ; load a.n[2]
+ mul r14 ; * a.n[3]
+ add rax,rax ; rdx:rax*=2
+ adc rdx,rdx
+ adc r8,0
+ add r9,rax
+ adc r10,rdx
+ adc r8,0
+
+ mov r13,r9
+ xor r9,r9
+
+ ;; c+=a.n[3]²
+ mov rax,r14
+ mul rax
+ add r10,rax
+ adc r8,rdx
+
+ mov r14,r10
+ mov r15,r8
+
+ jmp common_exit_norm
+ end
+
+
diff --git a/crypto/secp256k1/secp256k1/src/field_gmp.h b/crypto/secp256k1/secp256k1/src/field_gmp.h
new file mode 100644
index 000000000..d51dea0af
--- /dev/null
+++ b/crypto/secp256k1/secp256k1/src/field_gmp.h
@@ -0,0 +1,16 @@
+// Copyright (c) 2013 Pieter Wuille
+// Distributed under the MIT/X11 software license, see the accompanying
+// file COPYING or http://www.opensource.org/licenses/mit-license.php.
+
+#ifndef _SECP256K1_FIELD_REPR_
+#define _SECP256K1_FIELD_REPR_
+
+#include <gmp.h>
+
+#define FIELD_LIMBS ((256 + GMP_NUMB_BITS - 1) / GMP_NUMB_BITS)
+
+typedef struct {
+ mp_limb_t n[FIELD_LIMBS+1];
+} secp256k1_fe_t;
+
+#endif
diff --git a/crypto/secp256k1/secp256k1/src/group.h b/crypto/secp256k1/secp256k1/src/group.h
new file mode 100644
index 000000000..ae291c6ca
--- /dev/null
+++ b/crypto/secp256k1/secp256k1/src/group.h
@@ -0,0 +1,108 @@
+// Copyright (c) 2013 Pieter Wuille
+// Distributed under the MIT/X11 software license, see the accompanying
+// file COPYING or http://www.opensource.org/licenses/mit-license.php.
+
+#ifndef _SECP256K1_GROUP_
+#define _SECP256K1_GROUP_
+
+#include "num.h"
+#include "field.h"
+
+/** A group element of the secp256k1 curve, in affine coordinates. */
+typedef struct {
+ secp256k1_fe_t x;
+ secp256k1_fe_t y;
+ int infinity; // whether this represents the point at infinity
+} secp256k1_ge_t;
+
+/** A group element of the secp256k1 curve, in jacobian coordinates. */
+typedef struct {
+ secp256k1_fe_t x; // actual X: x/z^2
+ secp256k1_fe_t y; // actual Y: y/z^3
+ secp256k1_fe_t z;
+ int infinity; // whether this represents the point at infinity
+} secp256k1_gej_t;
+
+/** Global constants related to the group */
+typedef struct {
+ secp256k1_num_t order; // the order of the curve (= order of its generator)
+ secp256k1_num_t half_order; // half the order of the curve (= order of its generator)
+ secp256k1_ge_t g; // the generator point
+
+ // constants related to secp256k1's efficiently computable endomorphism
+ secp256k1_fe_t beta;
+ secp256k1_num_t lambda, a1b2, b1, a2;
+} secp256k1_ge_consts_t;
+
+static const secp256k1_ge_consts_t *secp256k1_ge_consts = NULL;
+
+/** Initialize the group module. */
+void static secp256k1_ge_start(void);
+
+/** De-initialize the group module. */
+void static secp256k1_ge_stop(void);
+
+/** Set a group element equal to the point at infinity */
+void static secp256k1_ge_set_infinity(secp256k1_ge_t *r);
+
+/** Set a group element equal to the point with given X and Y coordinates */
+void static secp256k1_ge_set_xy(secp256k1_ge_t *r, const secp256k1_fe_t *x, const secp256k1_fe_t *y);
+
+/** Set a group element (jacobian) equal to the point with given X coordinate, and given oddness for Y.
+ The result is not guaranteed to be valid. */
+void static secp256k1_ge_set_xo(secp256k1_ge_t *r, const secp256k1_fe_t *x, int odd);
+
+/** Check whether a group element is the point at infinity. */
+int static secp256k1_ge_is_infinity(const secp256k1_ge_t *a);
+
+/** Check whether a group element is valid (i.e., on the curve). */
+int static secp256k1_ge_is_valid(const secp256k1_ge_t *a);
+
+void static secp256k1_ge_neg(secp256k1_ge_t *r, const secp256k1_ge_t *a);
+
+/** Get a hex representation of a point. *rlen will be overwritten with the real length. */
+void static secp256k1_ge_get_hex(char *r, int *rlen, const secp256k1_ge_t *a);
+
+/** Set a group element equal to another which is given in jacobian coordinates */
+void static secp256k1_ge_set_gej(secp256k1_ge_t *r, secp256k1_gej_t *a);
+
+
+/** Set a group element (jacobian) equal to the point at infinity. */
+void static secp256k1_gej_set_infinity(secp256k1_gej_t *r);
+
+/** Set a group element (jacobian) equal to the point with given X and Y coordinates. */
+void static secp256k1_gej_set_xy(secp256k1_gej_t *r, const secp256k1_fe_t *x, const secp256k1_fe_t *y);
+
+/** Set a group element (jacobian) equal to another which is given in affine coordinates. */
+void static secp256k1_gej_set_ge(secp256k1_gej_t *r, const secp256k1_ge_t *a);
+
+/** Get the X coordinate of a group element (jacobian). */
+void static secp256k1_gej_get_x(secp256k1_fe_t *r, const secp256k1_gej_t *a);
+
+/** Set r equal to the inverse of a (i.e., mirrored around the X axis) */
+void static secp256k1_gej_neg(secp256k1_gej_t *r, const secp256k1_gej_t *a);
+
+/** Check whether a group element is the point at infinity. */
+int static secp256k1_gej_is_infinity(const secp256k1_gej_t *a);
+
+/** Set r equal to the double of a. */
+void static secp256k1_gej_double(secp256k1_gej_t *r, const secp256k1_gej_t *a);
+
+/** Set r equal to the sum of a and b. */
+void static secp256k1_gej_add(secp256k1_gej_t *r, const secp256k1_gej_t *a, const secp256k1_gej_t *b);
+
+/** Set r equal to the sum of a and b (with b given in jacobian coordinates). This is more efficient
+ than secp256k1_gej_add. */
+void static secp256k1_gej_add_ge(secp256k1_gej_t *r, const secp256k1_gej_t *a, const secp256k1_ge_t *b);
+
+/** Get a hex representation of a point. *rlen will be overwritten with the real length. */
+void static secp256k1_gej_get_hex(char *r, int *rlen, const secp256k1_gej_t *a);
+
+/** Set r to be equal to lambda times a, where lambda is chosen in a way such that this is very fast. */
+void static secp256k1_gej_mul_lambda(secp256k1_gej_t *r, const secp256k1_gej_t *a);
+
+/** Find r1 and r2 such that r1+r2*lambda = a, and r1 and r2 are maximum 128 bits long (given that a is
+ not more than 256 bits). */
+void static secp256k1_gej_split_exp(secp256k1_num_t *r1, secp256k1_num_t *r2, const secp256k1_num_t *a);
+
+#endif
diff --git a/crypto/secp256k1/secp256k1/src/impl/ecdsa.h b/crypto/secp256k1/secp256k1/src/impl/ecdsa.h
new file mode 100644
index 000000000..dd26cfd11
--- /dev/null
+++ b/crypto/secp256k1/secp256k1/src/impl/ecdsa.h
@@ -0,0 +1,309 @@
+// Copyright (c) 2013 Pieter Wuille
+// Distributed under the MIT/X11 software license, see the accompanying
+// file COPYING or http://www.opensource.org/licenses/mit-license.php.
+
+#ifndef _SECP256K1_ECDSA_IMPL_H_
+#define _SECP256K1_ECDSA_IMPL_H_
+
+#include "../num.h"
+#include "../field.h"
+#include "../group.h"
+#include "../ecmult.h"
+#include "../ecdsa.h"
+
+void static secp256k1_ecdsa_sig_init(secp256k1_ecdsa_sig_t *r) {
+ secp256k1_num_init(&r->r);
+ secp256k1_num_init(&r->s);
+}
+
+void static secp256k1_ecdsa_sig_free(secp256k1_ecdsa_sig_t *r) {
+ secp256k1_num_free(&r->r);
+ secp256k1_num_free(&r->s);
+}
+
+int static secp256k1_ecdsa_pubkey_parse(secp256k1_ge_t *elem, const unsigned char *pub, int size) {
+ if (size == 33 && (pub[0] == 0x02 || pub[0] == 0x03)) {
+ secp256k1_fe_t x;
+ secp256k1_fe_set_b32(&x, pub+1);
+ secp256k1_ge_set_xo(elem, &x, pub[0] == 0x03);
+ } else if (size == 65 && (pub[0] == 0x04 || pub[0] == 0x06 || pub[0] == 0x07)) {
+ secp256k1_fe_t x, y;
+ secp256k1_fe_set_b32(&x, pub+1);
+ secp256k1_fe_set_b32(&y, pub+33);
+ secp256k1_ge_set_xy(elem, &x, &y);
+ if ((pub[0] == 0x06 || pub[0] == 0x07) && secp256k1_fe_is_odd(&y) != (pub[0] == 0x07))
+ return 0;
+ } else {
+ return 0;
+ }
+ return secp256k1_ge_is_valid(elem);
+}
+
+int static secp256k1_ecdsa_sig_parse(secp256k1_ecdsa_sig_t *r, const unsigned char *sig, int size) {
+ if (sig[0] != 0x30) return 0;
+ int lenr = sig[3];
+ if (5+lenr >= size) return 0;
+ int lens = sig[lenr+5];
+ if (sig[1] != lenr+lens+4) return 0;
+ if (lenr+lens+6 > size) return 0;
+ if (sig[2] != 0x02) return 0;
+ if (lenr == 0) return 0;
+ if (sig[lenr+4] != 0x02) return 0;
+ if (lens == 0) return 0;
+ secp256k1_num_set_bin(&r->r, sig+4, lenr);
+ secp256k1_num_set_bin(&r->s, sig+6+lenr, lens);
+ return 1;
+}
+
+int static secp256k1_ecdsa_sig_serialize(unsigned char *sig, int *size, const secp256k1_ecdsa_sig_t *a) {
+ int lenR = (secp256k1_num_bits(&a->r) + 7)/8;
+ if (lenR == 0 || secp256k1_num_get_bit(&a->r, lenR*8-1))
+ lenR++;
+ int lenS = (secp256k1_num_bits(&a->s) + 7)/8;
+ if (lenS == 0 || secp256k1_num_get_bit(&a->s, lenS*8-1))
+ lenS++;
+ if (*size < 6+lenS+lenR)
+ return 0;
+ *size = 6 + lenS + lenR;
+ sig[0] = 0x30;
+ sig[1] = 4 + lenS + lenR;
+ sig[2] = 0x02;
+ sig[3] = lenR;
+ secp256k1_num_get_bin(sig+4, lenR, &a->r);
+ sig[4+lenR] = 0x02;
+ sig[5+lenR] = lenS;
+ secp256k1_num_get_bin(sig+lenR+6, lenS, &a->s);
+ return 1;
+}
+
+int static secp256k1_ecdsa_sig_recompute(secp256k1_num_t *r2, const secp256k1_ecdsa_sig_t *sig, const secp256k1_ge_t *pubkey, const secp256k1_num_t *message) {
+ const secp256k1_ge_consts_t *c = secp256k1_ge_consts;
+
+ if (secp256k1_num_is_neg(&sig->r) || secp256k1_num_is_neg(&sig->s))
+ return 0;
+ if (secp256k1_num_is_zero(&sig->r) || secp256k1_num_is_zero(&sig->s))
+ return 0;
+ if (secp256k1_num_cmp(&sig->r, &c->order) >= 0 || secp256k1_num_cmp(&sig->s, &c->order) >= 0)
+ return 0;
+
+ int ret = 0;
+ secp256k1_num_t sn, u1, u2;
+ secp256k1_num_init(&sn);
+ secp256k1_num_init(&u1);
+ secp256k1_num_init(&u2);
+ secp256k1_num_mod_inverse(&sn, &sig->s, &c->order);
+ secp256k1_num_mod_mul(&u1, &sn, message, &c->order);
+ secp256k1_num_mod_mul(&u2, &sn, &sig->r, &c->order);
+ secp256k1_gej_t pubkeyj; secp256k1_gej_set_ge(&pubkeyj, pubkey);
+ secp256k1_gej_t pr; secp256k1_ecmult(&pr, &pubkeyj, &u2, &u1);
+ if (!secp256k1_gej_is_infinity(&pr)) {
+ secp256k1_fe_t xr; secp256k1_gej_get_x(&xr, &pr);
+ secp256k1_fe_normalize(&xr);
+ unsigned char xrb[32]; secp256k1_fe_get_b32(xrb, &xr);
+ secp256k1_num_set_bin(r2, xrb, 32);
+ secp256k1_num_mod(r2, &c->order);
+ ret = 1;
+ }
+ secp256k1_num_free(&sn);
+ secp256k1_num_free(&u1);
+ secp256k1_num_free(&u2);
+ return ret;
+}
+
+int static secp256k1_ecdsa_sig_recover(const secp256k1_ecdsa_sig_t *sig, secp256k1_ge_t *pubkey, const secp256k1_num_t *message, int recid) {
+ const secp256k1_ge_consts_t *c = secp256k1_ge_consts;
+
+ if (secp256k1_num_is_neg(&sig->r) || secp256k1_num_is_neg(&sig->s))
+ return 0;
+ if (secp256k1_num_is_zero(&sig->r) || secp256k1_num_is_zero(&sig->s))
+ return 0;
+ if (secp256k1_num_cmp(&sig->r, &c->order) >= 0 || secp256k1_num_cmp(&sig->s, &c->order) >= 0)
+ return 0;
+
+ secp256k1_num_t rx;
+ secp256k1_num_init(&rx);
+ secp256k1_num_copy(&rx, &sig->r);
+ if (recid & 2) {
+ secp256k1_num_add(&rx, &rx, &c->order);
+ if (secp256k1_num_cmp(&rx, &secp256k1_fe_consts->p) >= 0)
+ return 0;
+ }
+ unsigned char brx[32];
+ secp256k1_num_get_bin(brx, 32, &rx);
+ secp256k1_num_free(&rx);
+ secp256k1_fe_t fx;
+ secp256k1_fe_set_b32(&fx, brx);
+ secp256k1_ge_t x;
+ secp256k1_ge_set_xo(&x, &fx, recid & 1);
+ if (!secp256k1_ge_is_valid(&x))
+ return 0;
+ secp256k1_gej_t xj;
+ secp256k1_gej_set_ge(&xj, &x);
+ secp256k1_num_t rn, u1, u2;
+ secp256k1_num_init(&rn);
+ secp256k1_num_init(&u1);
+ secp256k1_num_init(&u2);
+ secp256k1_num_mod_inverse(&rn, &sig->r, &c->order);
+ secp256k1_num_mod_mul(&u1, &rn, message, &c->order);
+ secp256k1_num_sub(&u1, &c->order, &u1);
+ secp256k1_num_mod_mul(&u2, &rn, &sig->s, &c->order);
+ secp256k1_gej_t qj;
+ secp256k1_ecmult(&qj, &xj, &u2, &u1);
+ if (secp256k1_gej_is_infinity(&qj))
+ return 0;
+ secp256k1_ge_set_gej(pubkey, &qj);
+ secp256k1_num_free(&rn);
+ secp256k1_num_free(&u1);
+ secp256k1_num_free(&u2);
+ return 1;
+}
+
+int static secp256k1_ecdsa_sig_verify(const secp256k1_ecdsa_sig_t *sig, const secp256k1_ge_t *pubkey, const secp256k1_num_t *message) {
+ secp256k1_num_t r2;
+ secp256k1_num_init(&r2);
+ int ret = 0;
+ ret = secp256k1_ecdsa_sig_recompute(&r2, sig, pubkey, message) && secp256k1_num_cmp(&sig->r, &r2) == 0;
+ secp256k1_num_free(&r2);
+ return ret;
+}
+
+int static secp256k1_ecdsa_sig_sign(secp256k1_ecdsa_sig_t *sig, const secp256k1_num_t *seckey, const secp256k1_num_t *message, const secp256k1_num_t *nonce, int *recid) {
+ const secp256k1_ge_consts_t *c = secp256k1_ge_consts;
+
+ secp256k1_gej_t rp;
+ secp256k1_ecmult_gen(&rp, nonce);
+ secp256k1_ge_t r;
+ secp256k1_ge_set_gej(&r, &rp);
+ unsigned char b[32];
+ secp256k1_fe_normalize(&r.x);
+ secp256k1_fe_normalize(&r.y);
+ secp256k1_fe_get_b32(b, &r.x);
+ secp256k1_num_set_bin(&sig->r, b, 32);
+ if (recid)
+ *recid = (secp256k1_num_cmp(&sig->r, &c->order) >= 0 ? 2 : 0) | (secp256k1_fe_is_odd(&r.y) ? 1 : 0);
+ secp256k1_num_mod(&sig->r, &c->order);
+ secp256k1_num_t n;
+ secp256k1_num_init(&n);
+ secp256k1_num_mod_mul(&n, &sig->r, seckey, &c->order);
+ secp256k1_num_add(&n, &n, message);
+ secp256k1_num_mod(&n, &c->order);
+ secp256k1_num_mod_inverse(&sig->s, nonce, &c->order);
+ secp256k1_num_mod_mul(&sig->s, &sig->s, &n, &c->order);
+ secp256k1_num_free(&n);
+ if (secp256k1_num_is_zero(&sig->s))
+ return 0;
+ if (secp256k1_num_cmp(&sig->s, &c->half_order) > 0) {
+ secp256k1_num_sub(&sig->s, &c->order, &sig->s);
+ if (recid)
+ *recid ^= 1;
+ }
+ return 1;
+}
+
+void static secp256k1_ecdsa_sig_set_rs(secp256k1_ecdsa_sig_t *sig, const secp256k1_num_t *r, const secp256k1_num_t *s) {
+ secp256k1_num_copy(&sig->r, r);
+ secp256k1_num_copy(&sig->s, s);
+}
+
+void static secp256k1_ecdsa_pubkey_serialize(secp256k1_ge_t *elem, unsigned char *pub, int *size, int compressed) {
+ secp256k1_fe_normalize(&elem->x);
+ secp256k1_fe_normalize(&elem->y);
+ secp256k1_fe_get_b32(&pub[1], &elem->x);
+ if (compressed) {
+ *size = 33;
+ pub[0] = 0x02 | (secp256k1_fe_is_odd(&elem->y) ? 0x01 : 0x00);
+ } else {
+ *size = 65;
+ pub[0] = 0x04;
+ secp256k1_fe_get_b32(&pub[33], &elem->y);
+ }
+}
+
+int static secp256k1_ecdsa_privkey_parse(secp256k1_num_t *key, const unsigned char *privkey, int privkeylen) {
+ const unsigned char *end = privkey + privkeylen;
+ // sequence header
+ if (end < privkey+1 || *privkey != 0x30)
+ return 0;
+ privkey++;
+ // sequence length constructor
+ int lenb = 0;
+ if (end < privkey+1 || !(*privkey & 0x80))
+ return 0;
+ lenb = *privkey & ~0x80; privkey++;
+ if (lenb < 1 || lenb > 2)
+ return 0;
+ if (end < privkey+lenb)
+ return 0;
+ // sequence length
+ int len = 0;
+ len = privkey[lenb-1] | (lenb > 1 ? privkey[lenb-2] << 8 : 0);
+ privkey += lenb;
+ if (end < privkey+len)
+ return 0;
+ // sequence element 0: version number (=1)
+ if (end < privkey+3 || privkey[0] != 0x02 || privkey[1] != 0x01 || privkey[2] != 0x01)
+ return 0;
+ privkey += 3;
+ // sequence element 1: octet string, up to 32 bytes
+ if (end < privkey+2 || privkey[0] != 0x04 || privkey[1] > 0x20 || end < privkey+2+privkey[1])
+ return 0;
+ secp256k1_num_set_bin(key, privkey+2, privkey[1]);
+ return 1;
+}
+
+int static secp256k1_ecdsa_privkey_serialize(unsigned char *privkey, int *privkeylen, const secp256k1_num_t *key, int compressed) {
+ secp256k1_gej_t rp;
+ secp256k1_ecmult_gen(&rp, key);
+ secp256k1_ge_t r;
+ secp256k1_ge_set_gej(&r, &rp);
+ if (compressed) {
+ static const unsigned char begin[] = {
+ 0x30,0x81,0xD3,0x02,0x01,0x01,0x04,0x20
+ };
+ static const unsigned char middle[] = {
+ 0xA0,0x81,0x85,0x30,0x81,0x82,0x02,0x01,0x01,0x30,0x2C,0x06,0x07,0x2A,0x86,0x48,
+ 0xCE,0x3D,0x01,0x01,0x02,0x21,0x00,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,
+ 0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,
+ 0xFF,0xFF,0xFE,0xFF,0xFF,0xFC,0x2F,0x30,0x06,0x04,0x01,0x00,0x04,0x01,0x07,0x04,
+ 0x21,0x02,0x79,0xBE,0x66,0x7E,0xF9,0xDC,0xBB,0xAC,0x55,0xA0,0x62,0x95,0xCE,0x87,
+ 0x0B,0x07,0x02,0x9B,0xFC,0xDB,0x2D,0xCE,0x28,0xD9,0x59,0xF2,0x81,0x5B,0x16,0xF8,
+ 0x17,0x98,0x02,0x21,0x00,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,
+ 0xFF,0xFF,0xFF,0xFF,0xFE,0xBA,0xAE,0xDC,0xE6,0xAF,0x48,0xA0,0x3B,0xBF,0xD2,0x5E,
+ 0x8C,0xD0,0x36,0x41,0x41,0x02,0x01,0x01,0xA1,0x24,0x03,0x22,0x00
+ };
+ unsigned char *ptr = privkey;
+ memcpy(ptr, begin, sizeof(begin)); ptr += sizeof(begin);
+ secp256k1_num_get_bin(ptr, 32, key); ptr += 32;
+ memcpy(ptr, middle, sizeof(middle)); ptr += sizeof(middle);
+ int pubkeylen = 0;
+ secp256k1_ecdsa_pubkey_serialize(&r, ptr, &pubkeylen, 1); ptr += pubkeylen;
+ *privkeylen = ptr - privkey;
+ } else {
+ static const unsigned char begin[] = {
+ 0x30,0x82,0x01,0x13,0x02,0x01,0x01,0x04,0x20
+ };
+ static const unsigned char middle[] = {
+ 0xA0,0x81,0xA5,0x30,0x81,0xA2,0x02,0x01,0x01,0x30,0x2C,0x06,0x07,0x2A,0x86,0x48,
+ 0xCE,0x3D,0x01,0x01,0x02,0x21,0x00,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,
+ 0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,
+ 0xFF,0xFF,0xFE,0xFF,0xFF,0xFC,0x2F,0x30,0x06,0x04,0x01,0x00,0x04,0x01,0x07,0x04,
+ 0x41,0x04,0x79,0xBE,0x66,0x7E,0xF9,0xDC,0xBB,0xAC,0x55,0xA0,0x62,0x95,0xCE,0x87,
+ 0x0B,0x07,0x02,0x9B,0xFC,0xDB,0x2D,0xCE,0x28,0xD9,0x59,0xF2,0x81,0x5B,0x16,0xF8,
+ 0x17,0x98,0x48,0x3A,0xDA,0x77,0x26,0xA3,0xC4,0x65,0x5D,0xA4,0xFB,0xFC,0x0E,0x11,
+ 0x08,0xA8,0xFD,0x17,0xB4,0x48,0xA6,0x85,0x54,0x19,0x9C,0x47,0xD0,0x8F,0xFB,0x10,
+ 0xD4,0xB8,0x02,0x21,0x00,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,
+ 0xFF,0xFF,0xFF,0xFF,0xFE,0xBA,0xAE,0xDC,0xE6,0xAF,0x48,0xA0,0x3B,0xBF,0xD2,0x5E,
+ 0x8C,0xD0,0x36,0x41,0x41,0x02,0x01,0x01,0xA1,0x44,0x03,0x42,0x00
+ };
+ unsigned char *ptr = privkey;
+ memcpy(ptr, begin, sizeof(begin)); ptr += sizeof(begin);
+ secp256k1_num_get_bin(ptr, 32, key); ptr += 32;
+ memcpy(ptr, middle, sizeof(middle)); ptr += sizeof(middle);
+ int pubkeylen = 0;
+ secp256k1_ecdsa_pubkey_serialize(&r, ptr, &pubkeylen, 0); ptr += pubkeylen;
+ *privkeylen = ptr - privkey;
+ }
+ return 1;
+}
+
+#endif
diff --git a/crypto/secp256k1/secp256k1/src/impl/ecmult.h b/crypto/secp256k1/secp256k1/src/impl/ecmult.h
new file mode 100644
index 000000000..6acb4c408
--- /dev/null
+++ b/crypto/secp256k1/secp256k1/src/impl/ecmult.h
@@ -0,0 +1,238 @@
+// Copyright (c) 2013 Pieter Wuille
+// Distributed under the MIT/X11 software license, see the accompanying
+// file COPYING or http://www.opensource.org/licenses/mit-license.php.
+
+#ifndef _SECP256K1_ECMULT_IMPL_H_
+#define _SECP256K1_ECMULT_IMPL_H_
+
+#include "../num.h"
+#include "../group.h"
+#include "../ecmult.h"
+
+// optimal for 128-bit and 256-bit exponents.
+#define WINDOW_A 5
+
+// larger numbers may result in slightly better performance, at the cost of
+// exponentially larger precomputed tables. WINDOW_G == 14 results in 640 KiB.
+#define WINDOW_G 14
+
+/** Fill a table 'pre' with precomputed odd multiples of a. W determines the size of the table.
+ * pre will contains the values [1*a,3*a,5*a,...,(2^(w-1)-1)*a], so it needs place for
+ * 2^(w-2) entries.
+ *
+ * There are two versions of this function:
+ * - secp256k1_ecmult_precomp_wnaf_gej, which operates on group elements in jacobian notation,
+ * fast to precompute, but slower to use in later additions.
+ * - secp256k1_ecmult_precomp_wnaf_ge, which operates on group elements in affine notations,
+ * (much) slower to precompute, but a bit faster to use in later additions.
+ * To compute a*P + b*G, we use the jacobian version for P, and the affine version for G, as
+ * G is constant, so it only needs to be done once in advance.
+ */
+void static secp256k1_ecmult_table_precomp_gej(secp256k1_gej_t *pre, const secp256k1_gej_t *a, int w) {
+ pre[0] = *a;
+ secp256k1_gej_t d; secp256k1_gej_double(&d, &pre[0]);
+ for (int i=1; i<(1 << (w-2)); i++)
+ secp256k1_gej_add(&pre[i], &d, &pre[i-1]);
+}
+
+void static secp256k1_ecmult_table_precomp_ge(secp256k1_ge_t *pre, const secp256k1_ge_t *a, int w) {
+ pre[0] = *a;
+ secp256k1_gej_t x; secp256k1_gej_set_ge(&x, a);
+ secp256k1_gej_t d; secp256k1_gej_double(&d, &x);
+ for (int i=1; i<(1 << (w-2)); i++) {
+ secp256k1_gej_add_ge(&x, &d, &pre[i-1]);
+ secp256k1_ge_set_gej(&pre[i], &x);
+ }
+}
+
+/** The number of entries a table with precomputed multiples needs to have. */
+#define ECMULT_TABLE_SIZE(w) (1 << ((w)-2))
+
+/** The following two macro retrieves a particular odd multiple from a table
+ * of precomputed multiples. */
+#define ECMULT_TABLE_GET(r,pre,n,w,neg) do { \
+ assert(((n) & 1) == 1); \
+ assert((n) >= -((1 << ((w)-1)) - 1)); \
+ assert((n) <= ((1 << ((w)-1)) - 1)); \
+ if ((n) > 0) \
+ *(r) = (pre)[((n)-1)/2]; \
+ else \
+ (neg)((r), &(pre)[(-(n)-1)/2]); \
+} while(0)
+
+#define ECMULT_TABLE_GET_GEJ(r,pre,n,w) ECMULT_TABLE_GET((r),(pre),(n),(w),secp256k1_gej_neg)
+#define ECMULT_TABLE_GET_GE(r,pre,n,w) ECMULT_TABLE_GET((r),(pre),(n),(w),secp256k1_ge_neg)
+
+typedef struct {
+ secp256k1_ge_t pre_g[ECMULT_TABLE_SIZE(WINDOW_G)]; // odd multiples of the generator
+ secp256k1_ge_t pre_g_128[ECMULT_TABLE_SIZE(WINDOW_G)]; // odd multiples of 2^128*generator
+ secp256k1_ge_t prec[64][16]; // prec[j][i] = 16^j * (i+1) * G
+ secp256k1_ge_t fin; // -(sum(prec[j][0], j=0..63))
+} secp256k1_ecmult_consts_t;
+
+static const secp256k1_ecmult_consts_t *secp256k1_ecmult_consts = NULL;
+
+static void secp256k1_ecmult_start(void) {
+ if (secp256k1_ecmult_consts != NULL)
+ return;
+
+ secp256k1_ecmult_consts_t *ret = (secp256k1_ecmult_consts_t*)malloc(sizeof(secp256k1_ecmult_consts_t));
+ secp256k1_ecmult_consts = ret;
+
+ // get the generator
+ const secp256k1_ge_t *g = &secp256k1_ge_consts->g;
+
+ // calculate 2^128*generator
+ secp256k1_gej_t g_128j; secp256k1_gej_set_ge(&g_128j, g);
+ for (int i=0; i<128; i++)
+ secp256k1_gej_double(&g_128j, &g_128j);
+ secp256k1_ge_t g_128; secp256k1_ge_set_gej(&g_128, &g_128j);
+
+ // precompute the tables with odd multiples
+ secp256k1_ecmult_table_precomp_ge(ret->pre_g, g, WINDOW_G);
+ secp256k1_ecmult_table_precomp_ge(ret->pre_g_128, &g_128, WINDOW_G);
+
+ // compute prec and fin
+ secp256k1_gej_t gg; secp256k1_gej_set_ge(&gg, g);
+ secp256k1_ge_t ad = *g;
+ secp256k1_gej_t fn; secp256k1_gej_set_infinity(&fn);
+ for (int j=0; j<64; j++) {
+ secp256k1_ge_set_gej(&ret->prec[j][0], &gg);
+ secp256k1_gej_add(&fn, &fn, &gg);
+ for (int i=1; i<16; i++) {
+ secp256k1_gej_add_ge(&gg, &gg, &ad);
+ secp256k1_ge_set_gej(&ret->prec[j][i], &gg);
+ }
+ ad = ret->prec[j][15];
+ }
+ secp256k1_ge_set_gej(&ret->fin, &fn);
+ secp256k1_ge_neg(&ret->fin, &ret->fin);
+}
+
+static void secp256k1_ecmult_stop(void) {
+ if (secp256k1_ecmult_consts == NULL)
+ return;
+
+ secp256k1_ecmult_consts_t *c = (secp256k1_ecmult_consts_t*)secp256k1_ecmult_consts;
+ free(c);
+ secp256k1_ecmult_consts = NULL;
+}
+
+/** Convert a number to WNAF notation. The number becomes represented by sum(2^i * wnaf[i], i=0..bits),
+ * with the following guarantees:
+ * - each wnaf[i] is either 0, or an odd integer between -(1<<(w-1) - 1) and (1<<(w-1) - 1)
+ * - two non-zero entries in wnaf are separated by at least w-1 zeroes.
+ * - the index of the highest non-zero entry in wnaf (=return value-1) is at most bits, where
+ * bits is the number of bits necessary to represent the absolute value of the input.
+ */
+static int secp256k1_ecmult_wnaf(int *wnaf, const secp256k1_num_t *a, int w) {
+ int ret = 0;
+ int zeroes = 0;
+ secp256k1_num_t x;
+ secp256k1_num_init(&x);
+ secp256k1_num_copy(&x, a);
+ int sign = 1;
+ if (secp256k1_num_is_neg(&x)) {
+ sign = -1;
+ secp256k1_num_negate(&x);
+ }
+ while (!secp256k1_num_is_zero(&x)) {
+ while (!secp256k1_num_is_odd(&x)) {
+ zeroes++;
+ secp256k1_num_shift(&x, 1);
+ }
+ int word = secp256k1_num_shift(&x, w);
+ while (zeroes) {
+ wnaf[ret++] = 0;
+ zeroes--;
+ }
+ if (word & (1 << (w-1))) {
+ secp256k1_num_inc(&x);
+ wnaf[ret++] = sign * (word - (1 << w));
+ } else {
+ wnaf[ret++] = sign * word;
+ }
+ zeroes = w-1;
+ }
+ secp256k1_num_free(&x);
+ return ret;
+}
+
+void static secp256k1_ecmult_gen(secp256k1_gej_t *r, const secp256k1_num_t *gn) {
+ secp256k1_num_t n;
+ secp256k1_num_init(&n);
+ secp256k1_num_copy(&n, gn);
+ const secp256k1_ecmult_consts_t *c = secp256k1_ecmult_consts;
+ secp256k1_gej_set_ge(r, &c->prec[0][secp256k1_num_shift(&n, 4)]);
+ for (int j=1; j<64; j++)
+ secp256k1_gej_add_ge(r, r, &c->prec[j][secp256k1_num_shift(&n, 4)]);
+ secp256k1_num_free(&n);
+ secp256k1_gej_add_ge(r, r, &c->fin);
+}
+
+void static secp256k1_ecmult(secp256k1_gej_t *r, const secp256k1_gej_t *a, const secp256k1_num_t *na, const secp256k1_num_t *ng) {
+ const secp256k1_ecmult_consts_t *c = secp256k1_ecmult_consts;
+
+ secp256k1_num_t na_1, na_lam;
+ secp256k1_num_t ng_1, ng_128;
+ secp256k1_num_init(&na_1);
+ secp256k1_num_init(&na_lam);
+ secp256k1_num_init(&ng_1);
+ secp256k1_num_init(&ng_128);
+
+ // split na into na_1 and na_lam (where na = na_1 + na_lam*lambda, and na_1 and na_lam are ~128 bit)
+ secp256k1_gej_split_exp(&na_1, &na_lam, na);
+ // split ng into ng_1 and ng_128 (where gn = gn_1 + gn_128*2^128, and gn_1 and gn_128 are ~128 bit)
+ secp256k1_num_split(&ng_1, &ng_128, ng, 128);
+
+ // build wnaf representation for na_1, na_lam, ng_1, ng_128
+ int wnaf_na_1[129]; int bits_na_1 = secp256k1_ecmult_wnaf(wnaf_na_1, &na_1, WINDOW_A);
+ int wnaf_na_lam[129]; int bits_na_lam = secp256k1_ecmult_wnaf(wnaf_na_lam, &na_lam, WINDOW_A);
+ int wnaf_ng_1[129]; int bits_ng_1 = secp256k1_ecmult_wnaf(wnaf_ng_1, &ng_1, WINDOW_G);
+ int wnaf_ng_128[129]; int bits_ng_128 = secp256k1_ecmult_wnaf(wnaf_ng_128, &ng_128, WINDOW_G);
+
+ // calculate a_lam = a*lambda
+ secp256k1_gej_t a_lam; secp256k1_gej_mul_lambda(&a_lam, a);
+
+ // calculate odd multiples of a and a_lam
+ secp256k1_gej_t pre_a_1[ECMULT_TABLE_SIZE(WINDOW_A)], pre_a_lam[ECMULT_TABLE_SIZE(WINDOW_A)];
+ secp256k1_ecmult_table_precomp_gej(pre_a_1, a, WINDOW_A);
+ secp256k1_ecmult_table_precomp_gej(pre_a_lam, &a_lam, WINDOW_A);
+
+ int bits = bits_na_1;
+ if (bits_na_lam > bits) bits = bits_na_lam;
+ if (bits_ng_1 > bits) bits = bits_ng_1;
+ if (bits_ng_128 > bits) bits = bits_ng_128;
+
+ secp256k1_gej_set_infinity(r);
+ secp256k1_gej_t tmpj;
+ secp256k1_ge_t tmpa;
+
+ for (int i=bits-1; i>=0; i--) {
+ secp256k1_gej_double(r, r);
+ int n;
+ if (i < bits_na_1 && (n = wnaf_na_1[i])) {
+ ECMULT_TABLE_GET_GEJ(&tmpj, pre_a_1, n, WINDOW_A);
+ secp256k1_gej_add(r, r, &tmpj);
+ }
+ if (i < bits_na_lam && (n = wnaf_na_lam[i])) {
+ ECMULT_TABLE_GET_GEJ(&tmpj, pre_a_lam, n, WINDOW_A);
+ secp256k1_gej_add(r, r, &tmpj);
+ }
+ if (i < bits_ng_1 && (n = wnaf_ng_1[i])) {
+ ECMULT_TABLE_GET_GE(&tmpa, c->pre_g, n, WINDOW_G);
+ secp256k1_gej_add_ge(r, r, &tmpa);
+ }
+ if (i < bits_ng_128 && (n = wnaf_ng_128[i])) {
+ ECMULT_TABLE_GET_GE(&tmpa, c->pre_g_128, n, WINDOW_G);
+ secp256k1_gej_add_ge(r, r, &tmpa);
+ }
+ }
+
+ secp256k1_num_free(&na_1);
+ secp256k1_num_free(&na_lam);
+ secp256k1_num_free(&ng_1);
+ secp256k1_num_free(&ng_128);
+}
+
+#endif
diff --git a/crypto/secp256k1/secp256k1/src/impl/field.h b/crypto/secp256k1/secp256k1/src/impl/field.h
new file mode 100644
index 000000000..edb2acadc
--- /dev/null
+++ b/crypto/secp256k1/secp256k1/src/impl/field.h
@@ -0,0 +1,175 @@
+// Copyright (c) 2013 Pieter Wuille
+// Distributed under the MIT/X11 software license, see the accompanying
+// file COPYING or http://www.opensource.org/licenses/mit-license.php.
+
+#ifndef _SECP256K1_FIELD_IMPL_H_
+#define _SECP256K1_FIELD_IMPL_H_
+
+#if defined(USE_FIELD_GMP)
+#include "field_gmp.h"
+#elif defined(USE_FIELD_10X26)
+#include "field_10x26.h"
+#elif defined(USE_FIELD_5X52)
+#include "field_5x52.h"
+#elif defined(USE_FIELD_5X64)
+#include "field_5x64.h"
+#else
+#error "Please select field implementation"
+#endif
+
+void static secp256k1_fe_get_hex(char *r, int *rlen, const secp256k1_fe_t *a) {
+ if (*rlen < 65) {
+ *rlen = 65;
+ return;
+ }
+ *rlen = 65;
+ unsigned char tmp[32];
+ secp256k1_fe_t b = *a;
+ secp256k1_fe_normalize(&b);
+ secp256k1_fe_get_b32(tmp, &b);
+ for (int i=0; i<32; i++) {
+ static const char *c = "0123456789ABCDEF";
+ r[2*i] = c[(tmp[i] >> 4) & 0xF];
+ r[2*i+1] = c[(tmp[i]) & 0xF];
+ }
+ r[64] = 0x00;
+}
+
+void static secp256k1_fe_set_hex(secp256k1_fe_t *r, const char *a, int alen) {
+ unsigned char tmp[32] = {};
+ static const int cvt[256] = {0, 0, 0, 0, 0, 0, 0,0,0,0,0,0,0,0,0,0,
+ 0, 0, 0, 0, 0, 0, 0,0,0,0,0,0,0,0,0,0,
+ 0, 0, 0, 0, 0, 0, 0,0,0,0,0,0,0,0,0,0,
+ 0, 1, 2, 3, 4, 5, 6,7,8,9,0,0,0,0,0,0,
+ 0,10,11,12,13,14,15,0,0,0,0,0,0,0,0,0,
+ 0, 0, 0, 0, 0, 0, 0,0,0,0,0,0,0,0,0,0,
+ 0,10,11,12,13,14,15,0,0,0,0,0,0,0,0,0,
+ 0, 0, 0, 0, 0, 0, 0,0,0,0,0,0,0,0,0,0,
+ 0, 0, 0, 0, 0, 0, 0,0,0,0,0,0,0,0,0,0,
+ 0, 0, 0, 0, 0, 0, 0,0,0,0,0,0,0,0,0,0,
+ 0, 0, 0, 0, 0, 0, 0,0,0,0,0,0,0,0,0,0,
+ 0, 0, 0, 0, 0, 0, 0,0,0,0,0,0,0,0,0,0,
+ 0, 0, 0, 0, 0, 0, 0,0,0,0,0,0,0,0,0,0,
+ 0, 0, 0, 0, 0, 0, 0,0,0,0,0,0,0,0,0,0,
+ 0, 0, 0, 0, 0, 0, 0,0,0,0,0,0,0,0,0,0,
+ 0, 0, 0, 0, 0, 0, 0,0,0,0,0,0,0,0,0,0};
+ for (int i=0; i<32; i++) {
+ if (alen > i*2)
+ tmp[32 - alen/2 + i] = (cvt[(unsigned char)a[2*i]] << 4) + cvt[(unsigned char)a[2*i+1]];
+ }
+ secp256k1_fe_set_b32(r, tmp);
+}
+
+void static secp256k1_fe_sqrt(secp256k1_fe_t *r, const secp256k1_fe_t *a) {
+ // calculate a^p, with p={15,780,1022,1023}
+ secp256k1_fe_t a2; secp256k1_fe_sqr(&a2, a);
+ secp256k1_fe_t a3; secp256k1_fe_mul(&a3, &a2, a);
+ secp256k1_fe_t a6; secp256k1_fe_sqr(&a6, &a3);
+ secp256k1_fe_t a12; secp256k1_fe_sqr(&a12, &a6);
+ secp256k1_fe_t a15; secp256k1_fe_mul(&a15, &a12, &a3);
+ secp256k1_fe_t a30; secp256k1_fe_sqr(&a30, &a15);
+ secp256k1_fe_t a60; secp256k1_fe_sqr(&a60, &a30);
+ secp256k1_fe_t a120; secp256k1_fe_sqr(&a120, &a60);
+ secp256k1_fe_t a240; secp256k1_fe_sqr(&a240, &a120);
+ secp256k1_fe_t a255; secp256k1_fe_mul(&a255, &a240, &a15);
+ secp256k1_fe_t a510; secp256k1_fe_sqr(&a510, &a255);
+ secp256k1_fe_t a750; secp256k1_fe_mul(&a750, &a510, &a240);
+ secp256k1_fe_t a780; secp256k1_fe_mul(&a780, &a750, &a30);
+ secp256k1_fe_t a1020; secp256k1_fe_sqr(&a1020, &a510);
+ secp256k1_fe_t a1022; secp256k1_fe_mul(&a1022, &a1020, &a2);
+ secp256k1_fe_t a1023; secp256k1_fe_mul(&a1023, &a1022, a);
+ secp256k1_fe_t x = a15;
+ for (int i=0; i<21; i++) {
+ for (int j=0; j<10; j++) secp256k1_fe_sqr(&x, &x);
+ secp256k1_fe_mul(&x, &x, &a1023);
+ }
+ for (int j=0; j<10; j++) secp256k1_fe_sqr(&x, &x);
+ secp256k1_fe_mul(&x, &x, &a1022);
+ for (int i=0; i<2; i++) {
+ for (int j=0; j<10; j++) secp256k1_fe_sqr(&x, &x);
+ secp256k1_fe_mul(&x, &x, &a1023);
+ }
+ for (int j=0; j<10; j++) secp256k1_fe_sqr(&x, &x);
+ secp256k1_fe_mul(r, &x, &a780);
+}
+
+void static secp256k1_fe_inv(secp256k1_fe_t *r, const secp256k1_fe_t *a) {
+ // calculate a^p, with p={45,63,1019,1023}
+ secp256k1_fe_t a2; secp256k1_fe_sqr(&a2, a);
+ secp256k1_fe_t a3; secp256k1_fe_mul(&a3, &a2, a);
+ secp256k1_fe_t a4; secp256k1_fe_sqr(&a4, &a2);
+ secp256k1_fe_t a5; secp256k1_fe_mul(&a5, &a4, a);
+ secp256k1_fe_t a10; secp256k1_fe_sqr(&a10, &a5);
+ secp256k1_fe_t a11; secp256k1_fe_mul(&a11, &a10, a);
+ secp256k1_fe_t a21; secp256k1_fe_mul(&a21, &a11, &a10);
+ secp256k1_fe_t a42; secp256k1_fe_sqr(&a42, &a21);
+ secp256k1_fe_t a45; secp256k1_fe_mul(&a45, &a42, &a3);
+ secp256k1_fe_t a63; secp256k1_fe_mul(&a63, &a42, &a21);
+ secp256k1_fe_t a126; secp256k1_fe_sqr(&a126, &a63);
+ secp256k1_fe_t a252; secp256k1_fe_sqr(&a252, &a126);
+ secp256k1_fe_t a504; secp256k1_fe_sqr(&a504, &a252);
+ secp256k1_fe_t a1008; secp256k1_fe_sqr(&a1008, &a504);
+ secp256k1_fe_t a1019; secp256k1_fe_mul(&a1019, &a1008, &a11);
+ secp256k1_fe_t a1023; secp256k1_fe_mul(&a1023, &a1019, &a4);
+ secp256k1_fe_t x = a63;
+ for (int i=0; i<21; i++) {
+ for (int j=0; j<10; j++) secp256k1_fe_sqr(&x, &x);
+ secp256k1_fe_mul(&x, &x, &a1023);
+ }
+ for (int j=0; j<10; j++) secp256k1_fe_sqr(&x, &x);
+ secp256k1_fe_mul(&x, &x, &a1019);
+ for (int i=0; i<2; i++) {
+ for (int j=0; j<10; j++) secp256k1_fe_sqr(&x, &x);
+ secp256k1_fe_mul(&x, &x, &a1023);
+ }
+ for (int j=0; j<10; j++) secp256k1_fe_sqr(&x, &x);
+ secp256k1_fe_mul(r, &x, &a45);
+}
+
+void static secp256k1_fe_inv_var(secp256k1_fe_t *r, const secp256k1_fe_t *a) {
+#if defined(USE_FIELD_INV_BUILTIN)
+ secp256k1_fe_inv(r, a);
+#elif defined(USE_FIELD_INV_NUM)
+ unsigned char b[32];
+ secp256k1_fe_t c = *a;
+ secp256k1_fe_normalize(&c);
+ secp256k1_fe_get_b32(b, &c);
+ secp256k1_num_t n;
+ secp256k1_num_init(&n);
+ secp256k1_num_set_bin(&n, b, 32);
+ secp256k1_num_mod_inverse(&n, &n, &secp256k1_fe_consts->p);
+ secp256k1_num_get_bin(b, 32, &n);
+ secp256k1_num_free(&n);
+ secp256k1_fe_set_b32(r, b);
+#else
+#error "Please select field inverse implementation"
+#endif
+}
+
+void static secp256k1_fe_start(void) {
+ static const unsigned char secp256k1_fe_consts_p[] = {
+ 0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,
+ 0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,
+ 0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,
+ 0xFF,0xFF,0xFF,0xFE,0xFF,0xFF,0xFC,0x2F
+ };
+ if (secp256k1_fe_consts == NULL) {
+ secp256k1_fe_inner_start();
+ secp256k1_fe_consts_t *ret = (secp256k1_fe_consts_t*)malloc(sizeof(secp256k1_fe_consts_t));
+ secp256k1_num_init(&ret->p);
+ secp256k1_num_set_bin(&ret->p, secp256k1_fe_consts_p, sizeof(secp256k1_fe_consts_p));
+ secp256k1_fe_consts = ret;
+ }
+}
+
+void static secp256k1_fe_stop(void) {
+ if (secp256k1_fe_consts != NULL) {
+ secp256k1_fe_consts_t *c = (secp256k1_fe_consts_t*)secp256k1_fe_consts;
+ secp256k1_num_free(&c->p);
+ free((void*)c);
+ secp256k1_fe_consts = NULL;
+ secp256k1_fe_inner_stop();
+ }
+}
+
+#endif
diff --git a/crypto/secp256k1/secp256k1/src/impl/field_10x26.h b/crypto/secp256k1/secp256k1/src/impl/field_10x26.h
new file mode 100644
index 000000000..449769254
--- /dev/null
+++ b/crypto/secp256k1/secp256k1/src/impl/field_10x26.h
@@ -0,0 +1,487 @@
+// Copyright (c) 2013 Pieter Wuille
+// Distributed under the MIT/X11 software license, see the accompanying
+// file COPYING or http://www.opensource.org/licenses/mit-license.php.
+
+#ifndef _SECP256K1_FIELD_REPR_IMPL_H_
+#define _SECP256K1_FIELD_REPR_IMPL_H_
+
+#include <stdio.h>
+#include <assert.h>
+#include <string.h>
+#include "../num.h"
+#include "../field.h"
+
+void static secp256k1_fe_inner_start(void) {}
+void static secp256k1_fe_inner_stop(void) {}
+
+void static secp256k1_fe_normalize(secp256k1_fe_t *r) {
+// fog("normalize in: ", r);
+ uint32_t c;
+ c = r->n[0];
+ uint32_t t0 = c & 0x3FFFFFFUL;
+ c = (c >> 26) + r->n[1];
+ uint32_t t1 = c & 0x3FFFFFFUL;
+ c = (c >> 26) + r->n[2];
+ uint32_t t2 = c & 0x3FFFFFFUL;
+ c = (c >> 26) + r->n[3];
+ uint32_t t3 = c & 0x3FFFFFFUL;
+ c = (c >> 26) + r->n[4];
+ uint32_t t4 = c & 0x3FFFFFFUL;
+ c = (c >> 26) + r->n[5];
+ uint32_t t5 = c & 0x3FFFFFFUL;
+ c = (c >> 26) + r->n[6];
+ uint32_t t6 = c & 0x3FFFFFFUL;
+ c = (c >> 26) + r->n[7];
+ uint32_t t7 = c & 0x3FFFFFFUL;
+ c = (c >> 26) + r->n[8];
+ uint32_t t8 = c & 0x3FFFFFFUL;
+ c = (c >> 26) + r->n[9];
+ uint32_t t9 = c & 0x03FFFFFUL;
+ c >>= 22;
+/* r->n[0] = t0; r->n[1] = t1; r->n[2] = t2; r->n[3] = t3; r->n[4] = t4;
+ r->n[5] = t5; r->n[6] = t6; r->n[7] = t7; r->n[8] = t8; r->n[9] = t9;
+ fog(" tm1: ", r);
+ fprintf(stderr, "out c= %08lx\n", (unsigned long)c);*/
+
+ // The following code will not modify the t's if c is initially 0.
+ uint32_t d = c * 0x3D1UL + t0;
+ t0 = d & 0x3FFFFFFULL;
+ d = (d >> 26) + t1 + c*0x40;
+ t1 = d & 0x3FFFFFFULL;
+ d = (d >> 26) + t2;
+ t2 = d & 0x3FFFFFFULL;
+ d = (d >> 26) + t3;
+ t3 = d & 0x3FFFFFFULL;
+ d = (d >> 26) + t4;
+ t4 = d & 0x3FFFFFFULL;
+ d = (d >> 26) + t5;
+ t5 = d & 0x3FFFFFFULL;
+ d = (d >> 26) + t6;
+ t6 = d & 0x3FFFFFFULL;
+ d = (d >> 26) + t7;
+ t7 = d & 0x3FFFFFFULL;
+ d = (d >> 26) + t8;
+ t8 = d & 0x3FFFFFFULL;
+ d = (d >> 26) + t9;
+ t9 = d & 0x03FFFFFULL;
+ assert((d >> 22) == 0);
+/* r->n[0] = t0; r->n[1] = t1; r->n[2] = t2; r->n[3] = t3; r->n[4] = t4;
+ r->n[5] = t5; r->n[6] = t6; r->n[7] = t7; r->n[8] = t8; r->n[9] = t9;
+ fog(" tm2: ", r); */
+
+ // Subtract p if result >= p
+ uint64_t low = ((uint64_t)t1 << 26) | t0;
+ uint64_t mask = -(int64_t)((t9 < 0x03FFFFFUL) | (t8 < 0x3FFFFFFUL) | (t7 < 0x3FFFFFFUL) | (t6 < 0x3FFFFFFUL) | (t5 < 0x3FFFFFFUL) | (t4 < 0x3FFFFFFUL) | (t3 < 0x3FFFFFFUL) | (t2 < 0x3FFFFFFUL) | (low < 0xFFFFEFFFFFC2FULL));
+ t9 &= mask;
+ t8 &= mask;
+ t7 &= mask;
+ t6 &= mask;
+ t5 &= mask;
+ t4 &= mask;
+ t3 &= mask;
+ t2 &= mask;
+ low -= (~mask & 0xFFFFEFFFFFC2FULL);
+
+ // push internal variables back
+ r->n[0] = low & 0x3FFFFFFUL; r->n[1] = (low >> 26) & 0x3FFFFFFUL; r->n[2] = t2; r->n[3] = t3; r->n[4] = t4;
+ r->n[5] = t5; r->n[6] = t6; r->n[7] = t7; r->n[8] = t8; r->n[9] = t9;
+/* fog(" out: ", r);*/
+
+#ifdef VERIFY
+ r->magnitude = 1;
+ r->normalized = 1;
+#endif
+}
+
+void static inline secp256k1_fe_set_int(secp256k1_fe_t *r, int a) {
+ r->n[0] = a;
+ r->n[1] = r->n[2] = r->n[3] = r->n[4] = r->n[5] = r->n[6] = r->n[7] = r->n[8] = r->n[9] = 0;
+#ifdef VERIFY
+ r->magnitude = 1;
+ r->normalized = 1;
+#endif
+}
+
+// TODO: not constant time!
+int static inline secp256k1_fe_is_zero(const secp256k1_fe_t *a) {
+#ifdef VERIFY
+ assert(a->normalized);
+#endif
+ return (a->n[0] == 0 && a->n[1] == 0 && a->n[2] == 0 && a->n[3] == 0 && a->n[4] == 0 && a->n[5] == 0 && a->n[6] == 0 && a->n[7] == 0 && a->n[8] == 0 && a->n[9] == 0);
+}
+
+int static inline secp256k1_fe_is_odd(const secp256k1_fe_t *a) {
+#ifdef VERIFY
+ assert(a->normalized);
+#endif
+ return a->n[0] & 1;
+}
+
+// TODO: not constant time!
+int static inline secp256k1_fe_equal(const secp256k1_fe_t *a, const secp256k1_fe_t *b) {
+#ifdef VERIFY
+ assert(a->normalized);
+ assert(b->normalized);
+#endif
+ return (a->n[0] == b->n[0] && a->n[1] == b->n[1] && a->n[2] == b->n[2] && a->n[3] == b->n[3] && a->n[4] == b->n[4] &&
+ a->n[5] == b->n[5] && a->n[6] == b->n[6] && a->n[7] == b->n[7] && a->n[8] == b->n[8] && a->n[9] == b->n[9]);
+}
+
+void static secp256k1_fe_set_b32(secp256k1_fe_t *r, const unsigned char *a) {
+ r->n[0] = r->n[1] = r->n[2] = r->n[3] = r->n[4] = 0;
+ r->n[5] = r->n[6] = r->n[7] = r->n[8] = r->n[9] = 0;
+ for (int i=0; i<32; i++) {
+ for (int j=0; j<4; j++) {
+ int limb = (8*i+2*j)/26;
+ int shift = (8*i+2*j)%26;
+ r->n[limb] |= (uint32_t)((a[31-i] >> (2*j)) & 0x3) << shift;
+ }
+ }
+#ifdef VERIFY
+ r->magnitude = 1;
+ r->normalized = 1;
+#endif
+}
+
+/** Convert a field element to a 32-byte big endian value. Requires the input to be normalized */
+void static secp256k1_fe_get_b32(unsigned char *r, const secp256k1_fe_t *a) {
+#ifdef VERIFY
+ assert(a->normalized);
+#endif
+ for (int i=0; i<32; i++) {
+ int c = 0;
+ for (int j=0; j<4; j++) {
+ int limb = (8*i+2*j)/26;
+ int shift = (8*i+2*j)%26;
+ c |= ((a->n[limb] >> shift) & 0x3) << (2 * j);
+ }
+ r[31-i] = c;
+ }
+}
+
+void static inline secp256k1_fe_negate(secp256k1_fe_t *r, const secp256k1_fe_t *a, int m) {
+#ifdef VERIFY
+ assert(a->magnitude <= m);
+ r->magnitude = m + 1;
+ r->normalized = 0;
+#endif
+ r->n[0] = 0x3FFFC2FUL * (m + 1) - a->n[0];
+ r->n[1] = 0x3FFFFBFUL * (m + 1) - a->n[1];
+ r->n[2] = 0x3FFFFFFUL * (m + 1) - a->n[2];
+ r->n[3] = 0x3FFFFFFUL * (m + 1) - a->n[3];
+ r->n[4] = 0x3FFFFFFUL * (m + 1) - a->n[4];
+ r->n[5] = 0x3FFFFFFUL * (m + 1) - a->n[5];
+ r->n[6] = 0x3FFFFFFUL * (m + 1) - a->n[6];
+ r->n[7] = 0x3FFFFFFUL * (m + 1) - a->n[7];
+ r->n[8] = 0x3FFFFFFUL * (m + 1) - a->n[8];
+ r->n[9] = 0x03FFFFFUL * (m + 1) - a->n[9];
+}
+
+void static inline secp256k1_fe_mul_int(secp256k1_fe_t *r, int a) {
+#ifdef VERIFY
+ r->magnitude *= a;
+ r->normalized = 0;
+#endif
+ r->n[0] *= a;
+ r->n[1] *= a;
+ r->n[2] *= a;
+ r->n[3] *= a;
+ r->n[4] *= a;
+ r->n[5] *= a;
+ r->n[6] *= a;
+ r->n[7] *= a;
+ r->n[8] *= a;
+ r->n[9] *= a;
+}
+
+void static inline secp256k1_fe_add(secp256k1_fe_t *r, const secp256k1_fe_t *a) {
+#ifdef VERIFY
+ r->magnitude += a->magnitude;
+ r->normalized = 0;
+#endif
+ r->n[0] += a->n[0];
+ r->n[1] += a->n[1];
+ r->n[2] += a->n[2];
+ r->n[3] += a->n[3];
+ r->n[4] += a->n[4];
+ r->n[5] += a->n[5];
+ r->n[6] += a->n[6];
+ r->n[7] += a->n[7];
+ r->n[8] += a->n[8];
+ r->n[9] += a->n[9];
+}
+
+void static inline secp256k1_fe_mul_inner(const uint32_t *a, const uint32_t *b, uint32_t *r) {
+ uint64_t c = (uint64_t)a[0] * b[0];
+ uint32_t t0 = c & 0x3FFFFFFUL; c = c >> 26;
+ c = c + (uint64_t)a[0] * b[1] +
+ (uint64_t)a[1] * b[0];
+ uint32_t t1 = c & 0x3FFFFFFUL; c = c >> 26;
+ c = c + (uint64_t)a[0] * b[2] +
+ (uint64_t)a[1] * b[1] +
+ (uint64_t)a[2] * b[0];
+ uint32_t t2 = c & 0x3FFFFFFUL; c = c >> 26;
+ c = c + (uint64_t)a[0] * b[3] +
+ (uint64_t)a[1] * b[2] +
+ (uint64_t)a[2] * b[1] +
+ (uint64_t)a[3] * b[0];
+ uint32_t t3 = c & 0x3FFFFFFUL; c = c >> 26;
+ c = c + (uint64_t)a[0] * b[4] +
+ (uint64_t)a[1] * b[3] +
+ (uint64_t)a[2] * b[2] +
+ (uint64_t)a[3] * b[1] +
+ (uint64_t)a[4] * b[0];
+ uint32_t t4 = c & 0x3FFFFFFUL; c = c >> 26;
+ c = c + (uint64_t)a[0] * b[5] +
+ (uint64_t)a[1] * b[4] +
+ (uint64_t)a[2] * b[3] +
+ (uint64_t)a[3] * b[2] +
+ (uint64_t)a[4] * b[1] +
+ (uint64_t)a[5] * b[0];
+ uint32_t t5 = c & 0x3FFFFFFUL; c = c >> 26;
+ c = c + (uint64_t)a[0] * b[6] +
+ (uint64_t)a[1] * b[5] +
+ (uint64_t)a[2] * b[4] +
+ (uint64_t)a[3] * b[3] +
+ (uint64_t)a[4] * b[2] +
+ (uint64_t)a[5] * b[1] +
+ (uint64_t)a[6] * b[0];
+ uint32_t t6 = c & 0x3FFFFFFUL; c = c >> 26;
+ c = c + (uint64_t)a[0] * b[7] +
+ (uint64_t)a[1] * b[6] +
+ (uint64_t)a[2] * b[5] +
+ (uint64_t)a[3] * b[4] +
+ (uint64_t)a[4] * b[3] +
+ (uint64_t)a[5] * b[2] +
+ (uint64_t)a[6] * b[1] +
+ (uint64_t)a[7] * b[0];
+ uint32_t t7 = c & 0x3FFFFFFUL; c = c >> 26;
+ c = c + (uint64_t)a[0] * b[8] +
+ (uint64_t)a[1] * b[7] +
+ (uint64_t)a[2] * b[6] +
+ (uint64_t)a[3] * b[5] +
+ (uint64_t)a[4] * b[4] +
+ (uint64_t)a[5] * b[3] +
+ (uint64_t)a[6] * b[2] +
+ (uint64_t)a[7] * b[1] +
+ (uint64_t)a[8] * b[0];
+ uint32_t t8 = c & 0x3FFFFFFUL; c = c >> 26;
+ c = c + (uint64_t)a[0] * b[9] +
+ (uint64_t)a[1] * b[8] +
+ (uint64_t)a[2] * b[7] +
+ (uint64_t)a[3] * b[6] +
+ (uint64_t)a[4] * b[5] +
+ (uint64_t)a[5] * b[4] +
+ (uint64_t)a[6] * b[3] +
+ (uint64_t)a[7] * b[2] +
+ (uint64_t)a[8] * b[1] +
+ (uint64_t)a[9] * b[0];
+ uint32_t t9 = c & 0x3FFFFFFUL; c = c >> 26;
+ c = c + (uint64_t)a[1] * b[9] +
+ (uint64_t)a[2] * b[8] +
+ (uint64_t)a[3] * b[7] +
+ (uint64_t)a[4] * b[6] +
+ (uint64_t)a[5] * b[5] +
+ (uint64_t)a[6] * b[4] +
+ (uint64_t)a[7] * b[3] +
+ (uint64_t)a[8] * b[2] +
+ (uint64_t)a[9] * b[1];
+ uint32_t t10 = c & 0x3FFFFFFUL; c = c >> 26;
+ c = c + (uint64_t)a[2] * b[9] +
+ (uint64_t)a[3] * b[8] +
+ (uint64_t)a[4] * b[7] +
+ (uint64_t)a[5] * b[6] +
+ (uint64_t)a[6] * b[5] +
+ (uint64_t)a[7] * b[4] +
+ (uint64_t)a[8] * b[3] +
+ (uint64_t)a[9] * b[2];
+ uint32_t t11 = c & 0x3FFFFFFUL; c = c >> 26;
+ c = c + (uint64_t)a[3] * b[9] +
+ (uint64_t)a[4] * b[8] +
+ (uint64_t)a[5] * b[7] +
+ (uint64_t)a[6] * b[6] +
+ (uint64_t)a[7] * b[5] +
+ (uint64_t)a[8] * b[4] +
+ (uint64_t)a[9] * b[3];
+ uint32_t t12 = c & 0x3FFFFFFUL; c = c >> 26;
+ c = c + (uint64_t)a[4] * b[9] +
+ (uint64_t)a[5] * b[8] +
+ (uint64_t)a[6] * b[7] +
+ (uint64_t)a[7] * b[6] +
+ (uint64_t)a[8] * b[5] +
+ (uint64_t)a[9] * b[4];
+ uint32_t t13 = c & 0x3FFFFFFUL; c = c >> 26;
+ c = c + (uint64_t)a[5] * b[9] +
+ (uint64_t)a[6] * b[8] +
+ (uint64_t)a[7] * b[7] +
+ (uint64_t)a[8] * b[6] +
+ (uint64_t)a[9] * b[5];
+ uint32_t t14 = c & 0x3FFFFFFUL; c = c >> 26;
+ c = c + (uint64_t)a[6] * b[9] +
+ (uint64_t)a[7] * b[8] +
+ (uint64_t)a[8] * b[7] +
+ (uint64_t)a[9] * b[6];
+ uint32_t t15 = c & 0x3FFFFFFUL; c = c >> 26;
+ c = c + (uint64_t)a[7] * b[9] +
+ (uint64_t)a[8] * b[8] +
+ (uint64_t)a[9] * b[7];
+ uint32_t t16 = c & 0x3FFFFFFUL; c = c >> 26;
+ c = c + (uint64_t)a[8] * b[9] +
+ (uint64_t)a[9] * b[8];
+ uint32_t t17 = c & 0x3FFFFFFUL; c = c >> 26;
+ c = c + (uint64_t)a[9] * b[9];
+ uint32_t t18 = c & 0x3FFFFFFUL; c = c >> 26;
+ uint32_t t19 = c;
+
+ c = t0 + (uint64_t)t10 * 0x3D10UL;
+ t0 = c & 0x3FFFFFFUL; c = c >> 26;
+ c = c + t1 + (uint64_t)t10*0x400UL + (uint64_t)t11 * 0x3D10UL;
+ t1 = c & 0x3FFFFFFUL; c = c >> 26;
+ c = c + t2 + (uint64_t)t11*0x400UL + (uint64_t)t12 * 0x3D10UL;
+ t2 = c & 0x3FFFFFFUL; c = c >> 26;
+ c = c + t3 + (uint64_t)t12*0x400UL + (uint64_t)t13 * 0x3D10UL;
+ r[3] = c & 0x3FFFFFFUL; c = c >> 26;
+ c = c + t4 + (uint64_t)t13*0x400UL + (uint64_t)t14 * 0x3D10UL;
+ r[4] = c & 0x3FFFFFFUL; c = c >> 26;
+ c = c + t5 + (uint64_t)t14*0x400UL + (uint64_t)t15 * 0x3D10UL;
+ r[5] = c & 0x3FFFFFFUL; c = c >> 26;
+ c = c + t6 + (uint64_t)t15*0x400UL + (uint64_t)t16 * 0x3D10UL;
+ r[6] = c & 0x3FFFFFFUL; c = c >> 26;
+ c = c + t7 + (uint64_t)t16*0x400UL + (uint64_t)t17 * 0x3D10UL;
+ r[7] = c & 0x3FFFFFFUL; c = c >> 26;
+ c = c + t8 + (uint64_t)t17*0x400UL + (uint64_t)t18 * 0x3D10UL;
+ r[8] = c & 0x3FFFFFFUL; c = c >> 26;
+ c = c + t9 + (uint64_t)t18*0x400UL + (uint64_t)t19 * 0x1000003D10ULL;
+ r[9] = c & 0x03FFFFFUL; c = c >> 22;
+ uint64_t d = t0 + c * 0x3D1UL;
+ r[0] = d & 0x3FFFFFFUL; d = d >> 26;
+ d = d + t1 + c*0x40;
+ r[1] = d & 0x3FFFFFFUL; d = d >> 26;
+ r[2] = t2 + d;
+}
+
+void static inline secp256k1_fe_sqr_inner(const uint32_t *a, uint32_t *r) {
+ uint64_t c = (uint64_t)a[0] * a[0];
+ uint32_t t0 = c & 0x3FFFFFFUL; c = c >> 26;
+ c = c + (uint64_t)(a[0]*2) * a[1];
+ uint32_t t1 = c & 0x3FFFFFFUL; c = c >> 26;
+ c = c + (uint64_t)(a[0]*2) * a[2] +
+ (uint64_t)a[1] * a[1];
+ uint32_t t2 = c & 0x3FFFFFFUL; c = c >> 26;
+ c = c + (uint64_t)(a[0]*2) * a[3] +
+ (uint64_t)(a[1]*2) * a[2];
+ uint32_t t3 = c & 0x3FFFFFFUL; c = c >> 26;
+ c = c + (uint64_t)(a[0]*2) * a[4] +
+ (uint64_t)(a[1]*2) * a[3] +
+ (uint64_t)a[2] * a[2];
+ uint32_t t4 = c & 0x3FFFFFFUL; c = c >> 26;
+ c = c + (uint64_t)(a[0]*2) * a[5] +
+ (uint64_t)(a[1]*2) * a[4] +
+ (uint64_t)(a[2]*2) * a[3];
+ uint32_t t5 = c & 0x3FFFFFFUL; c = c >> 26;
+ c = c + (uint64_t)(a[0]*2) * a[6] +
+ (uint64_t)(a[1]*2) * a[5] +
+ (uint64_t)(a[2]*2) * a[4] +
+ (uint64_t)a[3] * a[3];
+ uint32_t t6 = c & 0x3FFFFFFUL; c = c >> 26;
+ c = c + (uint64_t)(a[0]*2) * a[7] +
+ (uint64_t)(a[1]*2) * a[6] +
+ (uint64_t)(a[2]*2) * a[5] +
+ (uint64_t)(a[3]*2) * a[4];
+ uint32_t t7 = c & 0x3FFFFFFUL; c = c >> 26;
+ c = c + (uint64_t)(a[0]*2) * a[8] +
+ (uint64_t)(a[1]*2) * a[7] +
+ (uint64_t)(a[2]*2) * a[6] +
+ (uint64_t)(a[3]*2) * a[5] +
+ (uint64_t)a[4] * a[4];
+ uint32_t t8 = c & 0x3FFFFFFUL; c = c >> 26;
+ c = c + (uint64_t)(a[0]*2) * a[9] +
+ (uint64_t)(a[1]*2) * a[8] +
+ (uint64_t)(a[2]*2) * a[7] +
+ (uint64_t)(a[3]*2) * a[6] +
+ (uint64_t)(a[4]*2) * a[5];
+ uint32_t t9 = c & 0x3FFFFFFUL; c = c >> 26;
+ c = c + (uint64_t)(a[1]*2) * a[9] +
+ (uint64_t)(a[2]*2) * a[8] +
+ (uint64_t)(a[3]*2) * a[7] +
+ (uint64_t)(a[4]*2) * a[6] +
+ (uint64_t)a[5] * a[5];
+ uint32_t t10 = c & 0x3FFFFFFUL; c = c >> 26;
+ c = c + (uint64_t)(a[2]*2) * a[9] +
+ (uint64_t)(a[3]*2) * a[8] +
+ (uint64_t)(a[4]*2) * a[7] +
+ (uint64_t)(a[5]*2) * a[6];
+ uint32_t t11 = c & 0x3FFFFFFUL; c = c >> 26;
+ c = c + (uint64_t)(a[3]*2) * a[9] +
+ (uint64_t)(a[4]*2) * a[8] +
+ (uint64_t)(a[5]*2) * a[7] +
+ (uint64_t)a[6] * a[6];
+ uint32_t t12 = c & 0x3FFFFFFUL; c = c >> 26;
+ c = c + (uint64_t)(a[4]*2) * a[9] +
+ (uint64_t)(a[5]*2) * a[8] +
+ (uint64_t)(a[6]*2) * a[7];
+ uint32_t t13 = c & 0x3FFFFFFUL; c = c >> 26;
+ c = c + (uint64_t)(a[5]*2) * a[9] +
+ (uint64_t)(a[6]*2) * a[8] +
+ (uint64_t)a[7] * a[7];
+ uint32_t t14 = c & 0x3FFFFFFUL; c = c >> 26;
+ c = c + (uint64_t)(a[6]*2) * a[9] +
+ (uint64_t)(a[7]*2) * a[8];
+ uint32_t t15 = c & 0x3FFFFFFUL; c = c >> 26;
+ c = c + (uint64_t)(a[7]*2) * a[9] +
+ (uint64_t)a[8] * a[8];
+ uint32_t t16 = c & 0x3FFFFFFUL; c = c >> 26;
+ c = c + (uint64_t)(a[8]*2) * a[9];
+ uint32_t t17 = c & 0x3FFFFFFUL; c = c >> 26;
+ c = c + (uint64_t)a[9] * a[9];
+ uint32_t t18 = c & 0x3FFFFFFUL; c = c >> 26;
+ uint32_t t19 = c;
+
+ c = t0 + (uint64_t)t10 * 0x3D10UL;
+ t0 = c & 0x3FFFFFFUL; c = c >> 26;
+ c = c + t1 + (uint64_t)t10*0x400UL + (uint64_t)t11 * 0x3D10UL;
+ t1 = c & 0x3FFFFFFUL; c = c >> 26;
+ c = c + t2 + (uint64_t)t11*0x400UL + (uint64_t)t12 * 0x3D10UL;
+ t2 = c & 0x3FFFFFFUL; c = c >> 26;
+ c = c + t3 + (uint64_t)t12*0x400UL + (uint64_t)t13 * 0x3D10UL;
+ r[3] = c & 0x3FFFFFFUL; c = c >> 26;
+ c = c + t4 + (uint64_t)t13*0x400UL + (uint64_t)t14 * 0x3D10UL;
+ r[4] = c & 0x3FFFFFFUL; c = c >> 26;
+ c = c + t5 + (uint64_t)t14*0x400UL + (uint64_t)t15 * 0x3D10UL;
+ r[5] = c & 0x3FFFFFFUL; c = c >> 26;
+ c = c + t6 + (uint64_t)t15*0x400UL + (uint64_t)t16 * 0x3D10UL;
+ r[6] = c & 0x3FFFFFFUL; c = c >> 26;
+ c = c + t7 + (uint64_t)t16*0x400UL + (uint64_t)t17 * 0x3D10UL;
+ r[7] = c & 0x3FFFFFFUL; c = c >> 26;
+ c = c + t8 + (uint64_t)t17*0x400UL + (uint64_t)t18 * 0x3D10UL;
+ r[8] = c & 0x3FFFFFFUL; c = c >> 26;
+ c = c + t9 + (uint64_t)t18*0x400UL + (uint64_t)t19 * 0x1000003D10ULL;
+ r[9] = c & 0x03FFFFFUL; c = c >> 22;
+ uint64_t d = t0 + c * 0x3D1UL;
+ r[0] = d & 0x3FFFFFFUL; d = d >> 26;
+ d = d + t1 + c*0x40;
+ r[1] = d & 0x3FFFFFFUL; d = d >> 26;
+ r[2] = t2 + d;
+}
+
+
+void static secp256k1_fe_mul(secp256k1_fe_t *r, const secp256k1_fe_t *a, const secp256k1_fe_t *b) {
+#ifdef VERIFY
+ assert(a->magnitude <= 8);
+ assert(b->magnitude <= 8);
+ r->magnitude = 1;
+ r->normalized = 0;
+#endif
+ secp256k1_fe_mul_inner(a->n, b->n, r->n);
+}
+
+void static secp256k1_fe_sqr(secp256k1_fe_t *r, const secp256k1_fe_t *a) {
+#ifdef VERIFY
+ assert(a->magnitude <= 8);
+ r->magnitude = 1;
+ r->normalized = 0;
+#endif
+ secp256k1_fe_sqr_inner(a->n, r->n);
+}
+
+#endif
diff --git a/crypto/secp256k1/secp256k1/src/impl/field_5x52.h b/crypto/secp256k1/secp256k1/src/impl/field_5x52.h
new file mode 100644
index 000000000..5347189f1
--- /dev/null
+++ b/crypto/secp256k1/secp256k1/src/impl/field_5x52.h
@@ -0,0 +1,196 @@
+// Copyright (c) 2013 Pieter Wuille
+// Distributed under the MIT/X11 software license, see the accompanying
+// file COPYING or http://www.opensource.org/licenses/mit-license.php.
+
+#ifndef _SECP256K1_FIELD_REPR_IMPL_H_
+#define _SECP256K1_FIELD_REPR_IMPL_H_
+
+#include <assert.h>
+#include <string.h>
+#include "../num.h"
+#include "../field.h"
+
+#if defined(USE_FIELD_5X52_ASM)
+#include "field_5x52_asm.h"
+#elif defined(USE_FIELD_5X52_INT128)
+#include "field_5x52_int128.h"
+#else
+#error "Please select field_5x52 implementation"
+#endif
+
+/** Implements arithmetic modulo FFFFFFFF FFFFFFFF FFFFFFFF FFFFFFFF FFFFFFFF FFFFFFFF FFFFFFFE FFFFFC2F,
+ * represented as 5 uint64_t's in base 2^52. The values are allowed to contain >52 each. In particular,
+ * each FieldElem has a 'magnitude' associated with it. Internally, a magnitude M means each element
+ * is at most M*(2^53-1), except the most significant one, which is limited to M*(2^49-1). All operations
+ * accept any input with magnitude at most M, and have different rules for propagating magnitude to their
+ * output.
+ */
+
+void static secp256k1_fe_inner_start(void) {}
+void static secp256k1_fe_inner_stop(void) {}
+
+void static secp256k1_fe_normalize(secp256k1_fe_t *r) {
+ uint64_t c;
+ c = r->n[0];
+ uint64_t t0 = c & 0xFFFFFFFFFFFFFULL;
+ c = (c >> 52) + r->n[1];
+ uint64_t t1 = c & 0xFFFFFFFFFFFFFULL;
+ c = (c >> 52) + r->n[2];
+ uint64_t t2 = c & 0xFFFFFFFFFFFFFULL;
+ c = (c >> 52) + r->n[3];
+ uint64_t t3 = c & 0xFFFFFFFFFFFFFULL;
+ c = (c >> 52) + r->n[4];
+ uint64_t t4 = c & 0x0FFFFFFFFFFFFULL;
+ c >>= 48;
+
+ // The following code will not modify the t's if c is initially 0.
+ c = c * 0x1000003D1ULL + t0;
+ t0 = c & 0xFFFFFFFFFFFFFULL;
+ c = (c >> 52) + t1;
+ t1 = c & 0xFFFFFFFFFFFFFULL;
+ c = (c >> 52) + t2;
+ t2 = c & 0xFFFFFFFFFFFFFULL;
+ c = (c >> 52) + t3;
+ t3 = c & 0xFFFFFFFFFFFFFULL;
+ c = (c >> 52) + t4;
+ t4 = c & 0x0FFFFFFFFFFFFULL;
+ assert((c >> 48) == 0);
+
+ // Subtract p if result >= p
+ uint64_t mask = -(int64_t)((t4 < 0xFFFFFFFFFFFFULL) | (t3 < 0xFFFFFFFFFFFFFULL) | (t2 < 0xFFFFFFFFFFFFFULL) | (t1 < 0xFFFFFFFFFFFFFULL) | (t0 < 0xFFFFEFFFFFC2FULL));
+ t4 &= mask;
+ t3 &= mask;
+ t2 &= mask;
+ t1 &= mask;
+ t0 -= (~mask & 0xFFFFEFFFFFC2FULL);
+
+ // push internal variables back
+ r->n[0] = t0; r->n[1] = t1; r->n[2] = t2; r->n[3] = t3; r->n[4] = t4;
+
+#ifdef VERIFY
+ r->magnitude = 1;
+ r->normalized = 1;
+#endif
+}
+
+void static inline secp256k1_fe_set_int(secp256k1_fe_t *r, int a) {
+ r->n[0] = a;
+ r->n[1] = r->n[2] = r->n[3] = r->n[4] = 0;
+#ifdef VERIFY
+ r->magnitude = 1;
+ r->normalized = 1;
+#endif
+}
+
+// TODO: not constant time!
+int static inline secp256k1_fe_is_zero(const secp256k1_fe_t *a) {
+#ifdef VERIFY
+ assert(a->normalized);
+#endif
+ return (a->n[0] == 0 && a->n[1] == 0 && a->n[2] == 0 && a->n[3] == 0 && a->n[4] == 0);
+}
+
+int static inline secp256k1_fe_is_odd(const secp256k1_fe_t *a) {
+#ifdef VERIFY
+ assert(a->normalized);
+#endif
+ return a->n[0] & 1;
+}
+
+// TODO: not constant time!
+int static inline secp256k1_fe_equal(const secp256k1_fe_t *a, const secp256k1_fe_t *b) {
+#ifdef VERIFY
+ assert(a->normalized);
+ assert(b->normalized);
+#endif
+ return (a->n[0] == b->n[0] && a->n[1] == b->n[1] && a->n[2] == b->n[2] && a->n[3] == b->n[3] && a->n[4] == b->n[4]);
+}
+
+void static secp256k1_fe_set_b32(secp256k1_fe_t *r, const unsigned char *a) {
+ r->n[0] = r->n[1] = r->n[2] = r->n[3] = r->n[4] = 0;
+ for (int i=0; i<32; i++) {
+ for (int j=0; j<2; j++) {
+ int limb = (8*i+4*j)/52;
+ int shift = (8*i+4*j)%52;
+ r->n[limb] |= (uint64_t)((a[31-i] >> (4*j)) & 0xF) << shift;
+ }
+ }
+#ifdef VERIFY
+ r->magnitude = 1;
+ r->normalized = 1;
+#endif
+}
+
+/** Convert a field element to a 32-byte big endian value. Requires the input to be normalized */
+void static secp256k1_fe_get_b32(unsigned char *r, const secp256k1_fe_t *a) {
+#ifdef VERIFY
+ assert(a->normalized);
+#endif
+ for (int i=0; i<32; i++) {
+ int c = 0;
+ for (int j=0; j<2; j++) {
+ int limb = (8*i+4*j)/52;
+ int shift = (8*i+4*j)%52;
+ c |= ((a->n[limb] >> shift) & 0xF) << (4 * j);
+ }
+ r[31-i] = c;
+ }
+}
+
+void static inline secp256k1_fe_negate(secp256k1_fe_t *r, const secp256k1_fe_t *a, int m) {
+#ifdef VERIFY
+ assert(a->magnitude <= m);
+ r->magnitude = m + 1;
+ r->normalized = 0;
+#endif
+ r->n[0] = 0xFFFFEFFFFFC2FULL * (m + 1) - a->n[0];
+ r->n[1] = 0xFFFFFFFFFFFFFULL * (m + 1) - a->n[1];
+ r->n[2] = 0xFFFFFFFFFFFFFULL * (m + 1) - a->n[2];
+ r->n[3] = 0xFFFFFFFFFFFFFULL * (m + 1) - a->n[3];
+ r->n[4] = 0x0FFFFFFFFFFFFULL * (m + 1) - a->n[4];
+}
+
+void static inline secp256k1_fe_mul_int(secp256k1_fe_t *r, int a) {
+#ifdef VERIFY
+ r->magnitude *= a;
+ r->normalized = 0;
+#endif
+ r->n[0] *= a;
+ r->n[1] *= a;
+ r->n[2] *= a;
+ r->n[3] *= a;
+ r->n[4] *= a;
+}
+
+void static inline secp256k1_fe_add(secp256k1_fe_t *r, const secp256k1_fe_t *a) {
+#ifdef VERIFY
+ r->magnitude += a->magnitude;
+ r->normalized = 0;
+#endif
+ r->n[0] += a->n[0];
+ r->n[1] += a->n[1];
+ r->n[2] += a->n[2];
+ r->n[3] += a->n[3];
+ r->n[4] += a->n[4];
+}
+
+void static secp256k1_fe_mul(secp256k1_fe_t *r, const secp256k1_fe_t *a, const secp256k1_fe_t *b) {
+#ifdef VERIFY
+ assert(a->magnitude <= 8);
+ assert(b->magnitude <= 8);
+ r->magnitude = 1;
+ r->normalized = 0;
+#endif
+ secp256k1_fe_mul_inner(a->n, b->n, r->n);
+}
+
+void static secp256k1_fe_sqr(secp256k1_fe_t *r, const secp256k1_fe_t *a) {
+#ifdef VERIFY
+ assert(a->magnitude <= 8);
+ r->magnitude = 1;
+ r->normalized = 0;
+#endif
+ secp256k1_fe_sqr_inner(a->n, r->n);
+}
+
+#endif
diff --git a/crypto/secp256k1/secp256k1/src/impl/field_5x52_asm.h b/crypto/secp256k1/secp256k1/src/impl/field_5x52_asm.h
new file mode 100644
index 000000000..93c6ab6b5
--- /dev/null
+++ b/crypto/secp256k1/secp256k1/src/impl/field_5x52_asm.h
@@ -0,0 +1,11 @@
+// Copyright (c) 2013 Pieter Wuille
+// Distributed under the MIT/X11 software license, see the accompanying
+// file COPYING or http://www.opensource.org/licenses/mit-license.php.
+
+#ifndef _SECP256K1_FIELD_INNER5X52_IMPL_H_
+#define _SECP256K1_FIELD_INNER5X52_IMPL_H_
+
+void __attribute__ ((sysv_abi)) secp256k1_fe_mul_inner(const uint64_t *a, const uint64_t *b, uint64_t *r);
+void __attribute__ ((sysv_abi)) secp256k1_fe_sqr_inner(const uint64_t *a, uint64_t *r);
+
+#endif
diff --git a/crypto/secp256k1/secp256k1/src/impl/field_5x52_int128.h b/crypto/secp256k1/secp256k1/src/impl/field_5x52_int128.h
new file mode 100644
index 000000000..23cb13462
--- /dev/null
+++ b/crypto/secp256k1/secp256k1/src/impl/field_5x52_int128.h
@@ -0,0 +1,105 @@
+// Copyright (c) 2013 Pieter Wuille
+// Distributed under the MIT/X11 software license, see the accompanying
+// file COPYING or http://www.opensource.org/licenses/mit-license.php.
+
+#ifndef _SECP256K1_FIELD_INNER5X52_IMPL_H_
+#define _SECP256K1_FIELD_INNER5X52_IMPL_H_
+
+#include <stdint.h>
+
+void static inline secp256k1_fe_mul_inner(const uint64_t *a, const uint64_t *b, uint64_t *r) {
+ __int128 c = (__int128)a[0] * b[0];
+ uint64_t t0 = c & 0xFFFFFFFFFFFFFULL; c = c >> 52; // c max 0FFFFFFFFFFFFFE0
+ c = c + (__int128)a[0] * b[1] +
+ (__int128)a[1] * b[0];
+ uint64_t t1 = c & 0xFFFFFFFFFFFFFULL; c = c >> 52; // c max 20000000000000BF
+ c = c + (__int128)a[0] * b[2] +
+ (__int128)a[1] * b[1] +
+ (__int128)a[2] * b[0];
+ uint64_t t2 = c & 0xFFFFFFFFFFFFFULL; c = c >> 52; // c max 30000000000001A0
+ c = c + (__int128)a[0] * b[3] +
+ (__int128)a[1] * b[2] +
+ (__int128)a[2] * b[1] +
+ (__int128)a[3] * b[0];
+ uint64_t t3 = c & 0xFFFFFFFFFFFFFULL; c = c >> 52; // c max 4000000000000280
+ c = c + (__int128)a[0] * b[4] +
+ (__int128)a[1] * b[3] +
+ (__int128)a[2] * b[2] +
+ (__int128)a[3] * b[1] +
+ (__int128)a[4] * b[0];
+ uint64_t t4 = c & 0xFFFFFFFFFFFFFULL; c = c >> 52; // c max 320000000000037E
+ c = c + (__int128)a[1] * b[4] +
+ (__int128)a[2] * b[3] +
+ (__int128)a[3] * b[2] +
+ (__int128)a[4] * b[1];
+ uint64_t t5 = c & 0xFFFFFFFFFFFFFULL; c = c >> 52; // c max 22000000000002BE
+ c = c + (__int128)a[2] * b[4] +
+ (__int128)a[3] * b[3] +
+ (__int128)a[4] * b[2];
+ uint64_t t6 = c & 0xFFFFFFFFFFFFFULL; c = c >> 52; // c max 12000000000001DE
+ c = c + (__int128)a[3] * b[4] +
+ (__int128)a[4] * b[3];
+ uint64_t t7 = c & 0xFFFFFFFFFFFFFULL; c = c >> 52; // c max 02000000000000FE
+ c = c + (__int128)a[4] * b[4];
+ uint64_t t8 = c & 0xFFFFFFFFFFFFFULL; c = c >> 52; // c max 001000000000001E
+ uint64_t t9 = c;
+
+ c = t0 + (__int128)t5 * 0x1000003D10ULL;
+ t0 = c & 0xFFFFFFFFFFFFFULL; c = c >> 52; // c max 0000001000003D10
+ c = c + t1 + (__int128)t6 * 0x1000003D10ULL;
+ t1 = c & 0xFFFFFFFFFFFFFULL; c = c >> 52; // c max 0000001000003D10
+ c = c + t2 + (__int128)t7 * 0x1000003D10ULL;
+ r[2] = c & 0xFFFFFFFFFFFFFULL; c = c >> 52; // c max 0000001000003D10
+ c = c + t3 + (__int128)t8 * 0x1000003D10ULL;
+ r[3] = c & 0xFFFFFFFFFFFFFULL; c = c >> 52; // c max 0000001000003D10
+ c = c + t4 + (__int128)t9 * 0x1000003D10ULL;
+ r[4] = c & 0x0FFFFFFFFFFFFULL; c = c >> 48; // c max 000001000003D110
+ c = t0 + (__int128)c * 0x1000003D1ULL;
+ r[0] = c & 0xFFFFFFFFFFFFFULL; c = c >> 52; // c max 1000008
+ r[1] = t1 + c;
+
+}
+
+void static inline secp256k1_fe_sqr_inner(const uint64_t *a, uint64_t *r) {
+ __int128 c = (__int128)a[0] * a[0];
+ uint64_t t0 = c & 0xFFFFFFFFFFFFFULL; c = c >> 52; // c max 0FFFFFFFFFFFFFE0
+ c = c + (__int128)(a[0]*2) * a[1];
+ uint64_t t1 = c & 0xFFFFFFFFFFFFFULL; c = c >> 52; // c max 20000000000000BF
+ c = c + (__int128)(a[0]*2) * a[2] +
+ (__int128)a[1] * a[1];
+ uint64_t t2 = c & 0xFFFFFFFFFFFFFULL; c = c >> 52; // c max 30000000000001A0
+ c = c + (__int128)(a[0]*2) * a[3] +
+ (__int128)(a[1]*2) * a[2];
+ uint64_t t3 = c & 0xFFFFFFFFFFFFFULL; c = c >> 52; // c max 4000000000000280
+ c = c + (__int128)(a[0]*2) * a[4] +
+ (__int128)(a[1]*2) * a[3] +
+ (__int128)a[2] * a[2];
+ uint64_t t4 = c & 0xFFFFFFFFFFFFFULL; c = c >> 52; // c max 320000000000037E
+ c = c + (__int128)(a[1]*2) * a[4] +
+ (__int128)(a[2]*2) * a[3];
+ uint64_t t5 = c & 0xFFFFFFFFFFFFFULL; c = c >> 52; // c max 22000000000002BE
+ c = c + (__int128)(a[2]*2) * a[4] +
+ (__int128)a[3] * a[3];
+ uint64_t t6 = c & 0xFFFFFFFFFFFFFULL; c = c >> 52; // c max 12000000000001DE
+ c = c + (__int128)(a[3]*2) * a[4];
+ uint64_t t7 = c & 0xFFFFFFFFFFFFFULL; c = c >> 52; // c max 02000000000000FE
+ c = c + (__int128)a[4] * a[4];
+ uint64_t t8 = c & 0xFFFFFFFFFFFFFULL; c = c >> 52; // c max 001000000000001E
+ uint64_t t9 = c;
+ c = t0 + (__int128)t5 * 0x1000003D10ULL;
+ t0 = c & 0xFFFFFFFFFFFFFULL; c = c >> 52; // c max 0000001000003D10
+ c = c + t1 + (__int128)t6 * 0x1000003D10ULL;
+ t1 = c & 0xFFFFFFFFFFFFFULL; c = c >> 52; // c max 0000001000003D10
+ c = c + t2 + (__int128)t7 * 0x1000003D10ULL;
+ r[2] = c & 0xFFFFFFFFFFFFFULL; c = c >> 52; // c max 0000001000003D10
+ c = c + t3 + (__int128)t8 * 0x1000003D10ULL;
+ r[3] = c & 0xFFFFFFFFFFFFFULL; c = c >> 52; // c max 0000001000003D10
+ c = c + t4 + (__int128)t9 * 0x1000003D10ULL;
+ r[4] = c & 0x0FFFFFFFFFFFFULL; c = c >> 48; // c max 000001000003D110
+ c = t0 + (__int128)c * 0x1000003D1ULL;
+ r[0] = c & 0xFFFFFFFFFFFFFULL; c = c >> 52; // c max 1000008
+ r[1] = t1 + c;
+
+}
+
+#endif
diff --git a/crypto/secp256k1/secp256k1/src/impl/field_5x64.h b/crypto/secp256k1/secp256k1/src/impl/field_5x64.h
new file mode 100644
index 000000000..1e645cddb
--- /dev/null
+++ b/crypto/secp256k1/secp256k1/src/impl/field_5x64.h
@@ -0,0 +1,371 @@
+// Copyright (c) 2013 Pieter Wuille
+// Distributed under the MIT/X11 software license, see the accompanying
+// file COPYING or http://www.opensource.org/licenses/mit-license.php.
+
+#ifndef _SECP256K1_FIELD_REPR_IMPL_H_
+#define _SECP256K1_FIELD_REPR_IMPL_H_
+
+#include <assert.h>
+#include <string.h>
+#include "../num.h"
+#include "../field.h"
+
+#include <stdio.h>
+#include "field_5x64_asm.h"
+
+/** Implements arithmetic modulo FFFFFFFF FFFFFFFF FFFFFFFF FFFFFFFF FFFFFFFF FFFFFFFF FFFFFFFE FFFFFC2F,
+ * represented as 4 uint64_t's in base 2^64, and one overflow uint64_t.
+ */
+
+#define FULL_LIMB (0xFFFFFFFFFFFFFFFFULL)
+#define LAST_LIMB (0xFFFFFFFEFFFFFC2FULL)
+#define COMP_LIMB (0x00000001000003D1ULL)
+
+void static secp256k1_fe_inner_start(void) {}
+void static secp256k1_fe_inner_stop(void) {}
+
+void static secp256k1_fe_reduce(secp256k1_fe_t *r) {
+ unsigned __int128 c = (unsigned __int128)r->n[4] * COMP_LIMB + r->n[0];
+ uint64_t n0 = c;
+ c = (c >> 64) + r->n[1];
+ uint64_t n1 = c;
+ c = (c >> 64) + r->n[2];
+ r->n[2] = c;
+ c = (c >> 64) + r->n[3];
+ r->n[3] = c;
+ c = (c >> 64) * COMP_LIMB + n0;
+ r->n[0] = c;
+ r->n[1] = n1 + (c >> 64);
+ assert(r->n[1] >= n1);
+ r->n[4] = 0;
+#ifdef VERIFY
+ r->reduced = 1;
+#endif
+}
+
+void static secp256k1_fe_normalize(secp256k1_fe_t *r) {
+ secp256k1_fe_reduce(r);
+
+ // Subtract p if result >= p
+ uint64_t mask = -(int64_t)((r->n[0] < LAST_LIMB) | (r->n[1] != ~0ULL) | (r->n[2] != ~0ULL) | (r->n[3] != ~0ULL));
+ r->n[0] -= (~mask & LAST_LIMB);
+ r->n[1] &= mask;
+ r->n[2] &= mask;
+ r->n[3] &= mask;
+ assert(r->n[4] == 0);
+
+#ifdef VERIFY
+ r->normalized = 1;
+#endif
+}
+
+void static inline secp256k1_fe_set_int(secp256k1_fe_t *r, int a) {
+ r->n[0] = a;
+ r->n[1] = r->n[2] = r->n[3] = r->n[4] = 0;
+
+#ifdef VERIFY
+ r->reduced = 1;
+ r->normalized = 1;
+#endif
+}
+
+// TODO: not constant time!
+int static inline secp256k1_fe_is_zero(const secp256k1_fe_t *a) {
+#ifdef VERIFY
+ assert(a->normalized);
+#endif
+ return (a->n[0] == 0 && a->n[1] == 0 && a->n[2] == 0 && a->n[3] == 0);
+}
+
+int static inline secp256k1_fe_is_odd(const secp256k1_fe_t *a) {
+#ifdef VERIFY
+ assert(a->normalized);
+#endif
+ return a->n[0] & 1;
+}
+
+// TODO: not constant time!
+int static inline secp256k1_fe_equal(const secp256k1_fe_t *a, const secp256k1_fe_t *b) {
+#ifdef VERIFY
+ assert(a->normalized);
+ assert(b->normalized);
+#endif
+ return (a->n[0] == b->n[0] && a->n[1] == b->n[1] && a->n[2] == b->n[2] && a->n[3] == b->n[3]);
+}
+
+void static secp256k1_fe_set_b32(secp256k1_fe_t *r, const unsigned char *a) {
+ r->n[0] = r->n[1] = r->n[2] = r->n[3] = r->n[4] = 0;
+ for (int i=0; i<32; i++) {
+ r->n[i/8] |= (uint64_t)a[31-i] << (i&7)*8;
+ }
+#ifdef VERIFY
+ r->reduced = 1;
+ r->normalized = 0;
+#endif
+}
+
+/** Convert a field element to a 32-byte big endian value. Requires the input to be normalized */
+void static secp256k1_fe_get_b32(unsigned char *r, const secp256k1_fe_t *a) {
+#ifdef VERIFY
+ assert(a->normalized);
+#endif
+ for (int i=0; i<32; i++) {
+ r[31-i] = a->n[i/8] >> ((i&7)*8);
+ }
+}
+
+void static inline secp256k1_fe_negate(secp256k1_fe_t *r, const secp256k1_fe_t *ac, int m) {
+ secp256k1_fe_t a = *ac;
+ secp256k1_fe_reduce(&a);
+ unsigned __int128 c = (unsigned __int128)(~a.n[0]) + LAST_LIMB + 1;
+ r->n[0] = c;
+ c = (c >> 64) + (~a.n[1]) + FULL_LIMB;
+ r->n[1] = c;
+ c = (c >> 64) + (~a.n[2]) + FULL_LIMB;
+ r->n[2] = c;
+ c = (c >> 64) + (~a.n[3]) + FULL_LIMB;
+ r->n[3] = c;
+ r->n[4] = 0;
+#ifdef VERIFY
+ r->reduced = 1;
+ r->normalized = 0;
+#endif
+}
+
+void static inline secp256k1_fe_mul_int(secp256k1_fe_t *r, int a) {
+#ifdef VERIFY
+ r->reduced = 0;
+ r->normalized = 0;
+#endif
+ unsigned __int128 c = (unsigned __int128)r->n[0] * a;
+ r->n[0] = c;
+ c = (c >> 64) + (unsigned __int128)r->n[1] * a;
+ r->n[1] = c;
+ c = (c >> 64) + (unsigned __int128)r->n[2] * a;
+ r->n[2] = c;
+ c = (c >> 64) + (unsigned __int128)r->n[3] * a;
+ r->n[3] = c;
+ c = (c >> 64) + (unsigned __int128)r->n[4] * a;
+ r->n[4] = c;
+}
+
+void static inline secp256k1_fe_add(secp256k1_fe_t *r, const secp256k1_fe_t *a) {
+#ifdef VERIFY
+ r->reduced = 0;
+ r->normalized = 0;
+#endif
+ unsigned __int128 c = (unsigned __int128)r->n[0] + a->n[0];
+ r->n[0] = c;
+ c = (unsigned __int128)r->n[1] + a->n[1] + (c >> 64);
+ r->n[1] = c;
+ c = (unsigned __int128)r->n[2] + a->n[2] + (c >> 64);
+ r->n[2] = c;
+ c = (unsigned __int128)r->n[3] + a->n[3] + (c >> 64);
+ r->n[3] = c;
+ c = (unsigned __int128)r->n[4] + a->n[4] + (c >> 64);
+ r->n[4] = c;
+ assert((c >> 64) == 0);
+}
+
+#if 0
+#define muladd_c3(a,b,c0,c1,c2) { \
+ unsigned __int128 q1 = ((unsigned __int128)(a)) * (b) + (c0); \
+ (c0) = q1; \
+ unsigned __int128 q2 = (q1 >> 64) + (c1) + (((unsigned __int128)(c2)) << 64); \
+ (c1) = q2; \
+ (c2) = q2 >> 64; \
+}
+
+#define sqradd_c3(a,c0,c1,c2) muladd_c3(a,a,c0,c1,c2)
+
+/*#define muladd_c3(a,b,c0,c1,c2) { \
+ unsigned __int128 q = (unsigned __int128)(a) * (b) + (c0); \
+ (c0) = q; \
+ (c1) += (q >> 64); \
+ (c2) += ((c1) < (q >> 64))?1:0; \
+}*/
+
+#define muladd2_c3(a,b,c0,c1,c2) { \
+ unsigned __int128 q = (unsigned __int128)(a) * (b); \
+ uint64_t t1 = (q >> 64); \
+ uint64_t t0 = q; \
+ uint64_t t2 = t1+t1; (c2) += (t2<t1)?1:0; \
+ t1 = t0+t0; t2 += (t1<t0)?1:0; \
+ (c0) += t1; t2 += ((c0)<t1)?1:0; \
+ (c1) += t2; (c2) += ((c1)<t2)?1:0; \
+}
+
+/*#define muladd2_c3(a,b,c0,c1,c2) { \
+ muladd_c3(a,b,c0,c1,c2); \
+ muladd_c3(a,b,c0,c1,c2); \
+}*/
+#else
+
+#define muladd_c3(a,b,c0,c1,c2) { \
+ register uint64_t t1, t2; \
+ asm ("mulq %3" \
+ : "=a"(t1),"=d"(t2) \
+ : "a"(a),"m"(b) \
+ : "cc"); \
+ asm ("addq %2,%0; adcq %3,%1" \
+ : "+r"(c0),"+d"(t2) \
+ : "a"(t1),"g"(0) \
+ : "cc"); \
+ asm ("addq %2,%0; adcq %3,%1" \
+ : "+r"(c1),"+r"(c2) \
+ : "d"(t2),"g"(0) \
+ : "cc"); \
+ }
+
+#define sqradd_c3(a,c0,c1,c2) { \
+ register uint64_t t1, t2; \
+ asm ("mulq %2" \
+ : "=a"(t1),"=d"(t2) \
+ : "a"(a) \
+ : "cc"); \
+ asm ("addq %2,%0; adcq %3,%1" \
+ : "+r"(c0),"+d"(t2) \
+ : "a"(t1),"g"(0) \
+ : "cc"); \
+ asm ("addq %2,%0; adcq %3,%1" \
+ : "+r"(c1),"+r"(c2) \
+ : "d"(t2),"g"(0) \
+ : "cc"); \
+ }
+
+#define muladd2_c3(a,b,c0,c1,c2) { \
+ register uint64_t t1, t2; \
+ asm ("mulq %3" \
+ : "=a"(t1),"=d"(t2) \
+ : "a"(a),"m"(b) \
+ : "cc"); \
+ asm ("addq %0,%0; adcq %2,%1" \
+ : "+d"(t2),"+r"(c2) \
+ : "g"(0) \
+ : "cc"); \
+ asm ("addq %0,%0; adcq %2,%1" \
+ : "+a"(t1),"+d"(t2) \
+ : "g"(0) \
+ : "cc"); \
+ asm ("addq %2,%0; adcq %3,%1" \
+ : "+r"(c0),"+d"(t2) \
+ : "a"(t1),"g"(0) \
+ : "cc"); \
+ asm ("addq %2,%0; adcq %3,%1" \
+ : "+r"(c1),"+r"(c2) \
+ : "d"(t2),"g"(0) \
+ : "cc"); \
+ }
+#endif
+
+#define mul_c2(a,b,c0,c1) { \
+ unsigned __int128 q = (unsigned __int128)(a) * (b); \
+ (c0) = q; \
+ (c1) = (q >> 64); \
+}
+
+void static secp256k1_fe_mul(secp256k1_fe_t *r, const secp256k1_fe_t *ac, const secp256k1_fe_t *bc) {
+
+ secp256k1_fe_t a = *ac, b = *bc;
+ secp256k1_fe_reduce(&a);
+ secp256k1_fe_reduce(&b);
+
+#ifdef USE_FIELD_5X64_ASM
+ secp256k1_fe_mul_inner((&a)->n,(&b)->n,r->n);
+#else
+ uint64_t c1,c2,c3;
+ c3=0;
+ mul_c2(a.n[0], b.n[0], c1, c2);
+ uint64_t r0 = c1; c1 = 0;
+ muladd_c3(a.n[0], b.n[1], c2, c3, c1);
+ muladd_c3(a.n[1], b.n[0], c2, c3, c1);
+ uint64_t r1 = c2; c2 = 0;
+ muladd_c3(a.n[2], b.n[0], c3, c1, c2);
+ muladd_c3(a.n[1], b.n[1], c3, c1, c2);
+ muladd_c3(a.n[0], b.n[2], c3, c1, c2);
+ uint64_t r2 = c3; c3 = 0;
+ muladd_c3(a.n[0], b.n[3], c1, c2, c3);
+ muladd_c3(a.n[1], b.n[2], c1, c2, c3);
+ muladd_c3(a.n[2], b.n[1], c1, c2, c3);
+ muladd_c3(a.n[3], b.n[0], c1, c2, c3);
+ uint64_t r3 = c1; c1 = 0;
+ muladd_c3(a.n[3], b.n[1], c2, c3, c1);
+ muladd_c3(a.n[2], b.n[2], c2, c3, c1);
+ muladd_c3(a.n[1], b.n[3], c2, c3, c1);
+ uint64_t r4 = c2; c2 = 0;
+ muladd_c3(a.n[2], b.n[3], c3, c1, c2);
+ muladd_c3(a.n[3], b.n[2], c3, c1, c2);
+ uint64_t r5 = c3; c3 = 0;
+ muladd_c3(a.n[3], b.n[3], c1, c2, c3);
+ uint64_t r6 = c1;
+ uint64_t r7 = c2;
+ assert(c3 == 0);
+ unsigned __int128 c = (unsigned __int128)r4 * COMP_LIMB + r0;
+ r->n[0] = c;
+ c = (unsigned __int128)r5 * COMP_LIMB + r1 + (c >> 64);
+ r->n[1] = c;
+ c = (unsigned __int128)r6 * COMP_LIMB + r2 + (c >> 64);
+ r->n[2] = c;
+ c = (unsigned __int128)r7 * COMP_LIMB + r3 + (c >> 64);
+ r->n[3] = c;
+ r->n[4] = c >> 64;
+#endif
+
+#ifdef VERIFY
+ r->normalized = 0;
+ r->reduced = 0;
+#endif
+ secp256k1_fe_reduce(r);
+}
+
+/*void static secp256k1_fe_sqr(secp256k1_fe_t *r, const secp256k1_fe_t *a) {
+ secp256k1_fe_mul(r, a, a);
+}*/
+
+void static secp256k1_fe_sqr(secp256k1_fe_t *r, const secp256k1_fe_t *ac) {
+ secp256k1_fe_t a = *ac;
+ secp256k1_fe_reduce(&a);
+
+#ifdef USE_FIELD_5X64_ASM
+ secp256k1_fe_sqr_inner((&a)->n,r->n);
+#else
+ uint64_t c1,c2,c3;
+ c3=0;
+ mul_c2(a.n[0], a.n[0], c1, c2);
+ uint64_t r0 = c1; c1 = 0;
+ muladd2_c3(a.n[0], a.n[1], c2, c3, c1);
+ uint64_t r1 = c2; c2 = 0;
+ muladd2_c3(a.n[2], a.n[0], c3, c1, c2);
+ sqradd_c3(a.n[1], c3, c1, c2);
+ uint64_t r2 = c3; c3 = 0;
+ muladd2_c3(a.n[0], a.n[3], c1, c2, c3);
+ muladd2_c3(a.n[1], a.n[2], c1, c2, c3);
+ uint64_t r3 = c1; c1 = 0;
+ muladd2_c3(a.n[3], a.n[1], c2, c3, c1);
+ sqradd_c3(a.n[2], c2, c3, c1);
+ uint64_t r4 = c2; c2 = 0;
+ muladd2_c3(a.n[2], a.n[3], c3, c1, c2);
+ uint64_t r5 = c3; c3 = 0;
+ sqradd_c3(a.n[3], c1, c2, c3);
+ uint64_t r6 = c1;
+ uint64_t r7 = c2;
+ assert(c3 == 0);
+ unsigned __int128 c = (unsigned __int128)r4 * COMP_LIMB + r0;
+ r->n[0] = c;
+ c = (unsigned __int128)r5 * COMP_LIMB + r1 + (c >> 64);
+ r->n[1] = c;
+ c = (unsigned __int128)r6 * COMP_LIMB + r2 + (c >> 64);
+ r->n[2] = c;
+ c = (unsigned __int128)r7 * COMP_LIMB + r3 + (c >> 64);
+ r->n[3] = c;
+ r->n[4] = c >> 64;
+#endif
+
+#ifdef VERIFY
+ r->normalized = 0;
+ r->reduced = 0;
+#endif
+ secp256k1_fe_reduce(r);
+}
+
+#endif
diff --git a/crypto/secp256k1/secp256k1/src/impl/field_5x64_asm.h b/crypto/secp256k1/secp256k1/src/impl/field_5x64_asm.h
new file mode 100644
index 000000000..93c6ab6b5
--- /dev/null
+++ b/crypto/secp256k1/secp256k1/src/impl/field_5x64_asm.h
@@ -0,0 +1,11 @@
+// Copyright (c) 2013 Pieter Wuille
+// Distributed under the MIT/X11 software license, see the accompanying
+// file COPYING or http://www.opensource.org/licenses/mit-license.php.
+
+#ifndef _SECP256K1_FIELD_INNER5X52_IMPL_H_
+#define _SECP256K1_FIELD_INNER5X52_IMPL_H_
+
+void __attribute__ ((sysv_abi)) secp256k1_fe_mul_inner(const uint64_t *a, const uint64_t *b, uint64_t *r);
+void __attribute__ ((sysv_abi)) secp256k1_fe_sqr_inner(const uint64_t *a, uint64_t *r);
+
+#endif
diff --git a/crypto/secp256k1/secp256k1/src/impl/field_gmp.h b/crypto/secp256k1/secp256k1/src/impl/field_gmp.h
new file mode 100644
index 000000000..6172ef48e
--- /dev/null
+++ b/crypto/secp256k1/secp256k1/src/impl/field_gmp.h
@@ -0,0 +1,155 @@
+// Copyright (c) 2013 Pieter Wuille
+// Distributed under the MIT/X11 software license, see the accompanying
+// file COPYING or http://www.opensource.org/licenses/mit-license.php.
+
+#ifndef _SECP256K1_FIELD_REPR_IMPL_H_
+#define _SECP256K1_FIELD_REPR_IMPL_H_
+
+#include <stdio.h>
+#include <assert.h>
+#include <string.h>
+#include "../num.h"
+#include "../field.h"
+
+static mp_limb_t secp256k1_field_p[FIELD_LIMBS];
+static mp_limb_t secp256k1_field_pc[(33+GMP_NUMB_BITS-1)/GMP_NUMB_BITS];
+
+void static secp256k1_fe_inner_start(void) {
+ for (int i=0; i<(33+GMP_NUMB_BITS-1)/GMP_NUMB_BITS; i++)
+ secp256k1_field_pc[i] = 0;
+ secp256k1_field_pc[0] += 0x3D1UL;
+ secp256k1_field_pc[32/GMP_NUMB_BITS] += (1UL << (32 % GMP_NUMB_BITS));
+ for (int i=0; i<FIELD_LIMBS; i++) {
+ secp256k1_field_p[i] = 0;
+ }
+ mpn_sub(secp256k1_field_p, secp256k1_field_p, FIELD_LIMBS, secp256k1_field_pc, (33+GMP_NUMB_BITS-1)/GMP_NUMB_BITS);
+}
+
+void static secp256k1_fe_inner_stop(void) {
+}
+
+void static secp256k1_fe_normalize(secp256k1_fe_t *r) {
+ if (r->n[FIELD_LIMBS] != 0) {
+#if (GMP_NUMB_BITS >= 40)
+ mp_limb_t carry = mpn_add_1(r->n, r->n, FIELD_LIMBS, 0x1000003D1ULL * r->n[FIELD_LIMBS]);
+ mpn_add_1(r->n, r->n, FIELD_LIMBS, 0x1000003D1ULL * carry);
+#else
+ mp_limb_t carry = mpn_add_1(r->n, r->n, FIELD_LIMBS, 0x3D1UL * r->n[FIELD_LIMBS]) +
+ mpn_add_1(r->n+(32/GMP_NUMB_BITS), r->n+(32/GMP_NUMB_BITS), FIELD_LIMBS-(32/GMP_NUMB_BITS), r->n[FIELD_LIMBS] << (32 % GMP_NUMB_BITS));
+ mpn_add_1(r->n, r->n, FIELD_LIMBS, 0x3D1UL * carry);
+ mpn_add_1(r->n+(32/GMP_NUMB_BITS), r->n+(32/GMP_NUMB_BITS), FIELD_LIMBS-(32/GMP_NUMB_BITS), carry << (32%GMP_NUMB_BITS));
+#endif
+ r->n[FIELD_LIMBS] = 0;
+ }
+ if (mpn_cmp(r->n, secp256k1_field_p, FIELD_LIMBS) >= 0)
+ mpn_sub(r->n, r->n, FIELD_LIMBS, secp256k1_field_p, FIELD_LIMBS);
+}
+
+void static inline secp256k1_fe_set_int(secp256k1_fe_t *r, int a) {
+ r->n[0] = a;
+ for (int i=1; i<FIELD_LIMBS+1; i++)
+ r->n[i] = 0;
+}
+
+int static inline secp256k1_fe_is_zero(const secp256k1_fe_t *a) {
+ int ret = 1;
+ for (int i=0; i<FIELD_LIMBS+1; i++)
+ ret &= (a->n[i] == 0);
+ return ret;
+}
+
+int static inline secp256k1_fe_is_odd(const secp256k1_fe_t *a) {
+ return a->n[0] & 1;
+}
+
+int static inline secp256k1_fe_equal(const secp256k1_fe_t *a, const secp256k1_fe_t *b) {
+ int ret = 1;
+ for (int i=0; i<FIELD_LIMBS+1; i++)
+ ret &= (a->n[i] == b->n[i]);
+ return ret;
+}
+
+void static secp256k1_fe_set_b32(secp256k1_fe_t *r, const unsigned char *a) {
+ for (int i=0; i<FIELD_LIMBS+1; i++)
+ r->n[i] = 0;
+ for (int i=0; i<256; i++) {
+ int limb = i/GMP_NUMB_BITS;
+ int shift = i%GMP_NUMB_BITS;
+ r->n[limb] |= (mp_limb_t)((a[31-i/8] >> (i%8)) & 0x1) << shift;
+ }
+}
+
+/** Convert a field element to a 32-byte big endian value. Requires the input to be normalized */
+void static secp256k1_fe_get_b32(unsigned char *r, const secp256k1_fe_t *a) {
+ for (int i=0; i<32; i++) {
+ int c = 0;
+ for (int j=0; j<8; j++) {
+ int limb = (8*i+j)/GMP_NUMB_BITS;
+ int shift = (8*i+j)%GMP_NUMB_BITS;
+ c |= ((a->n[limb] >> shift) & 0x1) << j;
+ }
+ r[31-i] = c;
+ }
+}
+
+void static inline secp256k1_fe_negate(secp256k1_fe_t *r, const secp256k1_fe_t *a, int m) {
+ *r = *a;
+ secp256k1_fe_normalize(r);
+ for (int i=0; i<FIELD_LIMBS; i++)
+ r->n[i] = ~(r->n[i]);
+#if (GMP_NUMB_BITS >= 33)
+ mpn_sub_1(r->n, r->n, FIELD_LIMBS, 0x1000003D0ULL);
+#else
+ mpn_sub_1(r->n, r->n, FIELD_LIMBS, 0x3D0UL);
+ mpn_sub_1(r->n+(32/GMP_NUMB_BITS), r->n+(32/GMP_NUMB_BITS), FIELD_LIMBS-(32/GMP_NUMB_BITS), 0x1UL << (32%GMP_NUMB_BITS));
+#endif
+}
+
+void static inline secp256k1_fe_mul_int(secp256k1_fe_t *r, int a) {
+ mpn_mul_1(r->n, r->n, FIELD_LIMBS+1, a);
+}
+
+void static inline secp256k1_fe_add(secp256k1_fe_t *r, const secp256k1_fe_t *a) {
+ mpn_add(r->n, r->n, FIELD_LIMBS+1, a->n, FIELD_LIMBS+1);
+}
+
+void static secp256k1_fe_reduce(secp256k1_fe_t *r, mp_limb_t *tmp) {
+ // <A1 A2 A3 A4> <B1 B2 B3 B4>
+ // B1 B2 B3 B4
+ // + C * A1 A2 A3 A4
+ // + A1 A2 A3 A4
+
+#if (GMP_NUMB_BITS >= 33)
+ mp_limb_t o = mpn_addmul_1(tmp, tmp+FIELD_LIMBS, FIELD_LIMBS, 0x1000003D1ULL);
+#else
+ mp_limb_t o = mpn_addmul_1(tmp, tmp+FIELD_LIMBS, FIELD_LIMBS, 0x3D1UL) +
+ mpn_addmul_1(tmp+(32/GMP_NUMB_BITS), tmp+FIELD_LIMBS, FIELD_LIMBS-(32/GMP_NUMB_BITS), 0x1UL << (32%GMP_NUMB_BITS));
+#endif
+ mp_limb_t q[1+(33+GMP_NUMB_BITS-1)/GMP_NUMB_BITS];
+ q[(33+GMP_NUMB_BITS-1)/GMP_NUMB_BITS] = mpn_mul_1(q, secp256k1_field_pc, (33+GMP_NUMB_BITS-1)/GMP_NUMB_BITS, o);
+#if (GMP_NUMB_BITS <= 32)
+ mp_limb_t o2 = tmp[2*FIELD_LIMBS-(32/GMP_NUMB_BITS)] << (32%GMP_NUMB_BITS);
+ q[(33+GMP_NUMB_BITS-1)/GMP_NUMB_BITS] += mpn_addmul_1(q, secp256k1_field_pc, (33+GMP_NUMB_BITS-1)/GMP_NUMB_BITS, o2);
+#endif
+ r->n[FIELD_LIMBS] = mpn_add(r->n, tmp, FIELD_LIMBS, q, 1+(33+GMP_NUMB_BITS-1)/GMP_NUMB_BITS);
+}
+
+void static secp256k1_fe_mul(secp256k1_fe_t *r, const secp256k1_fe_t *a, const secp256k1_fe_t *b) {
+ secp256k1_fe_t ac = *a;
+ secp256k1_fe_t bc = *b;
+ secp256k1_fe_normalize(&ac);
+ secp256k1_fe_normalize(&bc);
+ mp_limb_t tmp[2*FIELD_LIMBS];
+ mpn_mul_n(tmp, ac.n, bc.n, FIELD_LIMBS);
+ secp256k1_fe_reduce(r, tmp);
+}
+
+void static secp256k1_fe_sqr(secp256k1_fe_t *r, const secp256k1_fe_t *a) {
+ secp256k1_fe_t ac = *a;
+ secp256k1_fe_normalize(&ac);
+ mp_limb_t tmp[2*FIELD_LIMBS];
+ mpn_sqr(tmp, ac.n, FIELD_LIMBS);
+ secp256k1_fe_reduce(r, tmp);
+}
+
+#endif
diff --git a/crypto/secp256k1/secp256k1/src/impl/group.h b/crypto/secp256k1/secp256k1/src/impl/group.h
new file mode 100644
index 000000000..ce8d7b204
--- /dev/null
+++ b/crypto/secp256k1/secp256k1/src/impl/group.h
@@ -0,0 +1,397 @@
+// Copyright (c) 2013 Pieter Wuille
+// Distributed under the MIT/X11 software license, see the accompanying
+// file COPYING or http://www.opensource.org/licenses/mit-license.php.
+
+#ifndef _SECP256K1_GROUP_IMPL_H_
+#define _SECP256K1_GROUP_IMPL_H_
+
+#include <string.h>
+
+#include "../num.h"
+#include "../field.h"
+#include "../group.h"
+
+void static secp256k1_ge_set_infinity(secp256k1_ge_t *r) {
+ r->infinity = 1;
+}
+
+void static secp256k1_ge_set_xy(secp256k1_ge_t *r, const secp256k1_fe_t *x, const secp256k1_fe_t *y) {
+ r->infinity = 0;
+ r->x = *x;
+ r->y = *y;
+}
+
+int static secp256k1_ge_is_infinity(const secp256k1_ge_t *a) {
+ return a->infinity;
+}
+
+void static secp256k1_ge_neg(secp256k1_ge_t *r, const secp256k1_ge_t *a) {
+ r->infinity = a->infinity;
+ r->x = a->x;
+ r->y = a->y;
+ secp256k1_fe_normalize(&r->y);
+ secp256k1_fe_negate(&r->y, &r->y, 1);
+}
+
+void static secp256k1_ge_get_hex(char *r, int *rlen, const secp256k1_ge_t *a) {
+ char cx[65]; int lx=65;
+ char cy[65]; int ly=65;
+ secp256k1_fe_get_hex(cx, &lx, &a->x);
+ secp256k1_fe_get_hex(cy, &ly, &a->y);
+ lx = strlen(cx);
+ ly = strlen(cy);
+ int len = lx + ly + 3 + 1;
+ if (*rlen < len) {
+ *rlen = len;
+ return;
+ }
+ *rlen = len;
+ r[0] = '(';
+ memcpy(r+1, cx, lx);
+ r[1+lx] = ',';
+ memcpy(r+2+lx, cy, ly);
+ r[2+lx+ly] = ')';
+ r[3+lx+ly] = 0;
+}
+
+void static secp256k1_ge_set_gej(secp256k1_ge_t *r, secp256k1_gej_t *a) {
+ secp256k1_fe_inv_var(&a->z, &a->z);
+ secp256k1_fe_t z2; secp256k1_fe_sqr(&z2, &a->z);
+ secp256k1_fe_t z3; secp256k1_fe_mul(&z3, &a->z, &z2);
+ secp256k1_fe_mul(&a->x, &a->x, &z2);
+ secp256k1_fe_mul(&a->y, &a->y, &z3);
+ secp256k1_fe_set_int(&a->z, 1);
+ r->infinity = a->infinity;
+ r->x = a->x;
+ r->y = a->y;
+}
+
+void static secp256k1_gej_set_infinity(secp256k1_gej_t *r) {
+ r->infinity = 1;
+}
+
+void static secp256k1_gej_set_xy(secp256k1_gej_t *r, const secp256k1_fe_t *x, const secp256k1_fe_t *y) {
+ r->infinity = 0;
+ r->x = *x;
+ r->y = *y;
+ secp256k1_fe_set_int(&r->z, 1);
+}
+
+void static secp256k1_ge_set_xo(secp256k1_ge_t *r, const secp256k1_fe_t *x, int odd) {
+ r->x = *x;
+ secp256k1_fe_t x2; secp256k1_fe_sqr(&x2, x);
+ secp256k1_fe_t x3; secp256k1_fe_mul(&x3, x, &x2);
+ r->infinity = 0;
+ secp256k1_fe_t c; secp256k1_fe_set_int(&c, 7);
+ secp256k1_fe_add(&c, &x3);
+ secp256k1_fe_sqrt(&r->y, &c);
+ secp256k1_fe_normalize(&r->y);
+ if (secp256k1_fe_is_odd(&r->y) != odd)
+ secp256k1_fe_negate(&r->y, &r->y, 1);
+}
+
+void static secp256k1_gej_set_ge(secp256k1_gej_t *r, const secp256k1_ge_t *a) {
+ r->infinity = a->infinity;
+ r->x = a->x;
+ r->y = a->y;
+ secp256k1_fe_set_int(&r->z, 1);
+}
+
+void static secp256k1_gej_get_x(secp256k1_fe_t *r, const secp256k1_gej_t *a) {
+ secp256k1_fe_t zi2; secp256k1_fe_inv_var(&zi2, &a->z); secp256k1_fe_sqr(&zi2, &zi2);
+ secp256k1_fe_mul(r, &a->x, &zi2);
+}
+
+void static secp256k1_gej_neg(secp256k1_gej_t *r, const secp256k1_gej_t *a) {
+ r->infinity = a->infinity;
+ r->x = a->x;
+ r->y = a->y;
+ r->z = a->z;
+ secp256k1_fe_normalize(&r->y);
+ secp256k1_fe_negate(&r->y, &r->y, 1);
+}
+
+int static secp256k1_gej_is_infinity(const secp256k1_gej_t *a) {
+ return a->infinity;
+}
+
+int static secp256k1_gej_is_valid(const secp256k1_gej_t *a) {
+ if (a->infinity)
+ return 0;
+ // y^2 = x^3 + 7
+ // (Y/Z^3)^2 = (X/Z^2)^3 + 7
+ // Y^2 / Z^6 = X^3 / Z^6 + 7
+ // Y^2 = X^3 + 7*Z^6
+ secp256k1_fe_t y2; secp256k1_fe_sqr(&y2, &a->y);
+ secp256k1_fe_t x3; secp256k1_fe_sqr(&x3, &a->x); secp256k1_fe_mul(&x3, &x3, &a->x);
+ secp256k1_fe_t z2; secp256k1_fe_sqr(&z2, &a->z);
+ secp256k1_fe_t z6; secp256k1_fe_sqr(&z6, &z2); secp256k1_fe_mul(&z6, &z6, &z2);
+ secp256k1_fe_mul_int(&z6, 7);
+ secp256k1_fe_add(&x3, &z6);
+ secp256k1_fe_normalize(&y2);
+ secp256k1_fe_normalize(&x3);
+ return secp256k1_fe_equal(&y2, &x3);
+}
+
+int static secp256k1_ge_is_valid(const secp256k1_ge_t *a) {
+ if (a->infinity)
+ return 0;
+ // y^2 = x^3 + 7
+ secp256k1_fe_t y2; secp256k1_fe_sqr(&y2, &a->y);
+ secp256k1_fe_t x3; secp256k1_fe_sqr(&x3, &a->x); secp256k1_fe_mul(&x3, &x3, &a->x);
+ secp256k1_fe_t c; secp256k1_fe_set_int(&c, 7);
+ secp256k1_fe_add(&x3, &c);
+ secp256k1_fe_normalize(&y2);
+ secp256k1_fe_normalize(&x3);
+ return secp256k1_fe_equal(&y2, &x3);
+}
+
+void static secp256k1_gej_double(secp256k1_gej_t *r, const secp256k1_gej_t *a) {
+ secp256k1_fe_t t5 = a->y;
+ secp256k1_fe_normalize(&t5);
+ if (a->infinity || secp256k1_fe_is_zero(&t5)) {
+ r->infinity = 1;
+ return;
+ }
+
+ secp256k1_fe_t t1,t2,t3,t4;
+ secp256k1_fe_mul(&r->z, &t5, &a->z);
+ secp256k1_fe_mul_int(&r->z, 2); // Z' = 2*Y*Z (2)
+ secp256k1_fe_sqr(&t1, &a->x);
+ secp256k1_fe_mul_int(&t1, 3); // T1 = 3*X^2 (3)
+ secp256k1_fe_sqr(&t2, &t1); // T2 = 9*X^4 (1)
+ secp256k1_fe_sqr(&t3, &t5);
+ secp256k1_fe_mul_int(&t3, 2); // T3 = 2*Y^2 (2)
+ secp256k1_fe_sqr(&t4, &t3);
+ secp256k1_fe_mul_int(&t4, 2); // T4 = 8*Y^4 (2)
+ secp256k1_fe_mul(&t3, &a->x, &t3); // T3 = 2*X*Y^2 (1)
+ r->x = t3;
+ secp256k1_fe_mul_int(&r->x, 4); // X' = 8*X*Y^2 (4)
+ secp256k1_fe_negate(&r->x, &r->x, 4); // X' = -8*X*Y^2 (5)
+ secp256k1_fe_add(&r->x, &t2); // X' = 9*X^4 - 8*X*Y^2 (6)
+ secp256k1_fe_negate(&t2, &t2, 1); // T2 = -9*X^4 (2)
+ secp256k1_fe_mul_int(&t3, 6); // T3 = 12*X*Y^2 (6)
+ secp256k1_fe_add(&t3, &t2); // T3 = 12*X*Y^2 - 9*X^4 (8)
+ secp256k1_fe_mul(&r->y, &t1, &t3); // Y' = 36*X^3*Y^2 - 27*X^6 (1)
+ secp256k1_fe_negate(&t2, &t4, 2); // T2 = -8*Y^4 (3)
+ secp256k1_fe_add(&r->y, &t2); // Y' = 36*X^3*Y^2 - 27*X^6 - 8*Y^4 (4)
+ r->infinity = 0;
+}
+
+void static secp256k1_gej_add(secp256k1_gej_t *r, const secp256k1_gej_t *a, const secp256k1_gej_t *b) {
+ if (a->infinity) {
+ *r = *b;
+ return;
+ }
+ if (b->infinity) {
+ *r = *a;
+ return;
+ }
+ r->infinity = 0;
+ secp256k1_fe_t z22; secp256k1_fe_sqr(&z22, &b->z);
+ secp256k1_fe_t z12; secp256k1_fe_sqr(&z12, &a->z);
+ secp256k1_fe_t u1; secp256k1_fe_mul(&u1, &a->x, &z22);
+ secp256k1_fe_t u2; secp256k1_fe_mul(&u2, &b->x, &z12);
+ secp256k1_fe_t s1; secp256k1_fe_mul(&s1, &a->y, &z22); secp256k1_fe_mul(&s1, &s1, &b->z);
+ secp256k1_fe_t s2; secp256k1_fe_mul(&s2, &b->y, &z12); secp256k1_fe_mul(&s2, &s2, &a->z);
+ secp256k1_fe_normalize(&u1);
+ secp256k1_fe_normalize(&u2);
+ if (secp256k1_fe_equal(&u1, &u2)) {
+ secp256k1_fe_normalize(&s1);
+ secp256k1_fe_normalize(&s2);
+ if (secp256k1_fe_equal(&s1, &s2)) {
+ secp256k1_gej_double(r, a);
+ } else {
+ r->infinity = 1;
+ }
+ return;
+ }
+ secp256k1_fe_t h; secp256k1_fe_negate(&h, &u1, 1); secp256k1_fe_add(&h, &u2);
+ secp256k1_fe_t i; secp256k1_fe_negate(&i, &s1, 1); secp256k1_fe_add(&i, &s2);
+ secp256k1_fe_t i2; secp256k1_fe_sqr(&i2, &i);
+ secp256k1_fe_t h2; secp256k1_fe_sqr(&h2, &h);
+ secp256k1_fe_t h3; secp256k1_fe_mul(&h3, &h, &h2);
+ secp256k1_fe_mul(&r->z, &a->z, &b->z); secp256k1_fe_mul(&r->z, &r->z, &h);
+ secp256k1_fe_t t; secp256k1_fe_mul(&t, &u1, &h2);
+ r->x = t; secp256k1_fe_mul_int(&r->x, 2); secp256k1_fe_add(&r->x, &h3); secp256k1_fe_negate(&r->x, &r->x, 3); secp256k1_fe_add(&r->x, &i2);
+ secp256k1_fe_negate(&r->y, &r->x, 5); secp256k1_fe_add(&r->y, &t); secp256k1_fe_mul(&r->y, &r->y, &i);
+ secp256k1_fe_mul(&h3, &h3, &s1); secp256k1_fe_negate(&h3, &h3, 1);
+ secp256k1_fe_add(&r->y, &h3);
+}
+
+void static secp256k1_gej_add_ge(secp256k1_gej_t *r, const secp256k1_gej_t *a, const secp256k1_ge_t *b) {
+ if (a->infinity) {
+ r->infinity = b->infinity;
+ r->x = b->x;
+ r->y = b->y;
+ secp256k1_fe_set_int(&r->z, 1);
+ return;
+ }
+ if (b->infinity) {
+ *r = *a;
+ return;
+ }
+ r->infinity = 0;
+ secp256k1_fe_t z12; secp256k1_fe_sqr(&z12, &a->z);
+ secp256k1_fe_t u1 = a->x; secp256k1_fe_normalize(&u1);
+ secp256k1_fe_t u2; secp256k1_fe_mul(&u2, &b->x, &z12);
+ secp256k1_fe_t s1 = a->y; secp256k1_fe_normalize(&s1);
+ secp256k1_fe_t s2; secp256k1_fe_mul(&s2, &b->y, &z12); secp256k1_fe_mul(&s2, &s2, &a->z);
+ secp256k1_fe_normalize(&u1);
+ secp256k1_fe_normalize(&u2);
+ if (secp256k1_fe_equal(&u1, &u2)) {
+ secp256k1_fe_normalize(&s1);
+ secp256k1_fe_normalize(&s2);
+ if (secp256k1_fe_equal(&s1, &s2)) {
+ secp256k1_gej_double(r, a);
+ } else {
+ r->infinity = 1;
+ }
+ return;
+ }
+ secp256k1_fe_t h; secp256k1_fe_negate(&h, &u1, 1); secp256k1_fe_add(&h, &u2);
+ secp256k1_fe_t i; secp256k1_fe_negate(&i, &s1, 1); secp256k1_fe_add(&i, &s2);
+ secp256k1_fe_t i2; secp256k1_fe_sqr(&i2, &i);
+ secp256k1_fe_t h2; secp256k1_fe_sqr(&h2, &h);
+ secp256k1_fe_t h3; secp256k1_fe_mul(&h3, &h, &h2);
+ r->z = a->z; secp256k1_fe_mul(&r->z, &r->z, &h);
+ secp256k1_fe_t t; secp256k1_fe_mul(&t, &u1, &h2);
+ r->x = t; secp256k1_fe_mul_int(&r->x, 2); secp256k1_fe_add(&r->x, &h3); secp256k1_fe_negate(&r->x, &r->x, 3); secp256k1_fe_add(&r->x, &i2);
+ secp256k1_fe_negate(&r->y, &r->x, 5); secp256k1_fe_add(&r->y, &t); secp256k1_fe_mul(&r->y, &r->y, &i);
+ secp256k1_fe_mul(&h3, &h3, &s1); secp256k1_fe_negate(&h3, &h3, 1);
+ secp256k1_fe_add(&r->y, &h3);
+}
+
+void static secp256k1_gej_get_hex(char *r, int *rlen, const secp256k1_gej_t *a) {
+ secp256k1_gej_t c = *a;
+ secp256k1_ge_t t; secp256k1_ge_set_gej(&t, &c);
+ secp256k1_ge_get_hex(r, rlen, &t);
+}
+
+void static secp256k1_gej_mul_lambda(secp256k1_gej_t *r, const secp256k1_gej_t *a) {
+ const secp256k1_fe_t *beta = &secp256k1_ge_consts->beta;
+ *r = *a;
+ secp256k1_fe_mul(&r->x, &r->x, beta);
+}
+
+void static secp256k1_gej_split_exp(secp256k1_num_t *r1, secp256k1_num_t *r2, const secp256k1_num_t *a) {
+ const secp256k1_ge_consts_t *c = secp256k1_ge_consts;
+ secp256k1_num_t bnc1, bnc2, bnt1, bnt2, bnn2;
+
+ secp256k1_num_init(&bnc1);
+ secp256k1_num_init(&bnc2);
+ secp256k1_num_init(&bnt1);
+ secp256k1_num_init(&bnt2);
+ secp256k1_num_init(&bnn2);
+
+ secp256k1_num_copy(&bnn2, &c->order);
+ secp256k1_num_shift(&bnn2, 1);
+
+ secp256k1_num_mul(&bnc1, a, &c->a1b2);
+ secp256k1_num_add(&bnc1, &bnc1, &bnn2);
+ secp256k1_num_div(&bnc1, &bnc1, &c->order);
+
+ secp256k1_num_mul(&bnc2, a, &c->b1);
+ secp256k1_num_add(&bnc2, &bnc2, &bnn2);
+ secp256k1_num_div(&bnc2, &bnc2, &c->order);
+
+ secp256k1_num_mul(&bnt1, &bnc1, &c->a1b2);
+ secp256k1_num_mul(&bnt2, &bnc2, &c->a2);
+ secp256k1_num_add(&bnt1, &bnt1, &bnt2);
+ secp256k1_num_sub(r1, a, &bnt1);
+ secp256k1_num_mul(&bnt1, &bnc1, &c->b1);
+ secp256k1_num_mul(&bnt2, &bnc2, &c->a1b2);
+ secp256k1_num_sub(r2, &bnt1, &bnt2);
+
+ secp256k1_num_free(&bnc1);
+ secp256k1_num_free(&bnc2);
+ secp256k1_num_free(&bnt1);
+ secp256k1_num_free(&bnt2);
+ secp256k1_num_free(&bnn2);
+}
+
+
+void static secp256k1_ge_start(void) {
+ static const unsigned char secp256k1_ge_consts_order[] = {
+ 0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,
+ 0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFF,0xFE,
+ 0xBA,0xAE,0xDC,0xE6,0xAF,0x48,0xA0,0x3B,
+ 0xBF,0xD2,0x5E,0x8C,0xD0,0x36,0x41,0x41
+ };
+ static const unsigned char secp256k1_ge_consts_g_x[] = {
+ 0x79,0xBE,0x66,0x7E,0xF9,0xDC,0xBB,0xAC,
+ 0x55,0xA0,0x62,0x95,0xCE,0x87,0x0B,0x07,
+ 0x02,0x9B,0xFC,0xDB,0x2D,0xCE,0x28,0xD9,
+ 0x59,0xF2,0x81,0x5B,0x16,0xF8,0x17,0x98
+ };
+ static const unsigned char secp256k1_ge_consts_g_y[] = {
+ 0x48,0x3A,0xDA,0x77,0x26,0xA3,0xC4,0x65,
+ 0x5D,0xA4,0xFB,0xFC,0x0E,0x11,0x08,0xA8,
+ 0xFD,0x17,0xB4,0x48,0xA6,0x85,0x54,0x19,
+ 0x9C,0x47,0xD0,0x8F,0xFB,0x10,0xD4,0xB8
+ };
+ // properties of secp256k1's efficiently computable endomorphism
+ static const unsigned char secp256k1_ge_consts_lambda[] = {
+ 0x53,0x63,0xad,0x4c,0xc0,0x5c,0x30,0xe0,
+ 0xa5,0x26,0x1c,0x02,0x88,0x12,0x64,0x5a,
+ 0x12,0x2e,0x22,0xea,0x20,0x81,0x66,0x78,
+ 0xdf,0x02,0x96,0x7c,0x1b,0x23,0xbd,0x72
+ };
+ static const unsigned char secp256k1_ge_consts_beta[] = {
+ 0x7a,0xe9,0x6a,0x2b,0x65,0x7c,0x07,0x10,
+ 0x6e,0x64,0x47,0x9e,0xac,0x34,0x34,0xe9,
+ 0x9c,0xf0,0x49,0x75,0x12,0xf5,0x89,0x95,
+ 0xc1,0x39,0x6c,0x28,0x71,0x95,0x01,0xee
+ };
+ static const unsigned char secp256k1_ge_consts_a1b2[] = {
+ 0x30,0x86,0xd2,0x21,0xa7,0xd4,0x6b,0xcd,
+ 0xe8,0x6c,0x90,0xe4,0x92,0x84,0xeb,0x15
+ };
+ static const unsigned char secp256k1_ge_consts_b1[] = {
+ 0xe4,0x43,0x7e,0xd6,0x01,0x0e,0x88,0x28,
+ 0x6f,0x54,0x7f,0xa9,0x0a,0xbf,0xe4,0xc3
+ };
+ static const unsigned char secp256k1_ge_consts_a2[] = {
+ 0x01,
+ 0x14,0xca,0x50,0xf7,0xa8,0xe2,0xf3,0xf6,
+ 0x57,0xc1,0x10,0x8d,0x9d,0x44,0xcf,0xd8
+ };
+ if (secp256k1_ge_consts == NULL) {
+ secp256k1_ge_consts_t *ret = (secp256k1_ge_consts_t*)malloc(sizeof(secp256k1_ge_consts_t));
+ secp256k1_num_init(&ret->order);
+ secp256k1_num_init(&ret->half_order);
+ secp256k1_num_init(&ret->lambda);
+ secp256k1_num_init(&ret->a1b2);
+ secp256k1_num_init(&ret->a2);
+ secp256k1_num_init(&ret->b1);
+ secp256k1_num_set_bin(&ret->order, secp256k1_ge_consts_order, sizeof(secp256k1_ge_consts_order));
+ secp256k1_num_set_bin(&ret->lambda, secp256k1_ge_consts_lambda, sizeof(secp256k1_ge_consts_lambda));
+ secp256k1_num_set_bin(&ret->a1b2, secp256k1_ge_consts_a1b2, sizeof(secp256k1_ge_consts_a1b2));
+ secp256k1_num_set_bin(&ret->a2, secp256k1_ge_consts_a2, sizeof(secp256k1_ge_consts_a2));
+ secp256k1_num_set_bin(&ret->b1, secp256k1_ge_consts_b1, sizeof(secp256k1_ge_consts_b1));
+ secp256k1_num_copy(&ret->half_order, &ret->order);
+ secp256k1_num_shift(&ret->half_order, 1);
+ secp256k1_fe_set_b32(&ret->beta, secp256k1_ge_consts_beta);
+ secp256k1_fe_t g_x, g_y;
+ secp256k1_fe_set_b32(&g_x, secp256k1_ge_consts_g_x);
+ secp256k1_fe_set_b32(&g_y, secp256k1_ge_consts_g_y);
+ secp256k1_ge_set_xy(&ret->g, &g_x, &g_y);
+ secp256k1_ge_consts = ret;
+ }
+}
+
+void static secp256k1_ge_stop(void) {
+ if (secp256k1_ge_consts != NULL) {
+ secp256k1_ge_consts_t *c = (secp256k1_ge_consts_t*)secp256k1_ge_consts;
+ secp256k1_num_free(&c->order);
+ secp256k1_num_free(&c->half_order);
+ secp256k1_num_free(&c->lambda);
+ secp256k1_num_free(&c->a1b2);
+ secp256k1_num_free(&c->a2);
+ secp256k1_num_free(&c->b1);
+ free((void*)c);
+ secp256k1_ge_consts = NULL;
+ }
+}
+
+#endif
diff --git a/crypto/secp256k1/secp256k1/src/impl/num.h b/crypto/secp256k1/secp256k1/src/impl/num.h
new file mode 100644
index 000000000..fc6d05c3d
--- /dev/null
+++ b/crypto/secp256k1/secp256k1/src/impl/num.h
@@ -0,0 +1,18 @@
+// Copyright (c) 2013 Pieter Wuille
+// Distributed under the MIT/X11 software license, see the accompanying
+// file COPYING or http://www.opensource.org/licenses/mit-license.php.
+
+#ifndef _SECP256K1_NUM_IMPL_H_
+#define _SECP256K1_NUM_IMPL_H_
+
+#include "../num.h"
+
+#if defined(USE_NUM_GMP)
+#include "num_gmp.h"
+#elif defined(USE_NUM_OPENSSL)
+#include "num_openssl.h"
+#else
+#error "Please select num implementation"
+#endif
+
+#endif
diff --git a/crypto/secp256k1/secp256k1/src/impl/num_gmp.h b/crypto/secp256k1/secp256k1/src/impl/num_gmp.h
new file mode 100644
index 000000000..067c15180
--- /dev/null
+++ b/crypto/secp256k1/secp256k1/src/impl/num_gmp.h
@@ -0,0 +1,346 @@
+// Copyright (c) 2013 Pieter Wuille
+// Distributed under the MIT/X11 software license, see the accompanying
+// file COPYING or http://www.opensource.org/licenses/mit-license.php.
+
+#ifndef _SECP256K1_NUM_REPR_IMPL_H_
+#define _SECP256K1_NUM_REPR_IMPL_H_
+
+#include <assert.h>
+#include <string.h>
+#include <stdlib.h>
+#include <gmp.h>
+
+#include "num.h"
+
+#ifdef VERIFY
+void static secp256k1_num_sanity(const secp256k1_num_t *a) {
+ assert(a->limbs == 1 || (a->limbs > 1 && a->data[a->limbs-1] != 0));
+}
+#else
+#define secp256k1_num_sanity(a) do { } while(0)
+#endif
+
+void static secp256k1_num_init(secp256k1_num_t *r) {
+ r->neg = 0;
+ r->limbs = 1;
+ r->data[0] = 0;
+}
+
+void static secp256k1_num_free(secp256k1_num_t *r) {
+}
+
+void static secp256k1_num_copy(secp256k1_num_t *r, const secp256k1_num_t *a) {
+ *r = *a;
+}
+
+int static secp256k1_num_bits(const secp256k1_num_t *a) {
+ int ret=(a->limbs-1)*GMP_NUMB_BITS;
+ mp_limb_t x=a->data[a->limbs-1];
+ while (x) {
+ x >>= 1;
+ ret++;
+ }
+ return ret;
+}
+
+
+void static secp256k1_num_get_bin(unsigned char *r, unsigned int rlen, const secp256k1_num_t *a) {
+ unsigned char tmp[65];
+ int len = 0;
+ if (a->limbs>1 || a->data[0] != 0) {
+ len = mpn_get_str(tmp, 256, (mp_limb_t*)a->data, a->limbs);
+ }
+ int shift = 0;
+ while (shift < len && tmp[shift] == 0) shift++;
+ assert(len-shift <= rlen);
+ memset(r, 0, rlen - len + shift);
+ if (len > shift)
+ memcpy(r + rlen - len + shift, tmp + shift, len - shift);
+}
+
+void static secp256k1_num_set_bin(secp256k1_num_t *r, const unsigned char *a, unsigned int alen) {
+ assert(alen > 0);
+ assert(alen <= 64);
+ int len = mpn_set_str(r->data, a, alen, 256);
+ assert(len <= NUM_LIMBS*2);
+ r->limbs = len;
+ r->neg = 0;
+ while (r->limbs > 1 && r->data[r->limbs-1]==0) r->limbs--;
+}
+
+void static secp256k1_num_set_int(secp256k1_num_t *r, int a) {
+ r->limbs = 1;
+ r->neg = (a < 0);
+ r->data[0] = (a < 0) ? -a : a;
+}
+
+void static secp256k1_num_add_abs(secp256k1_num_t *r, const secp256k1_num_t *a, const secp256k1_num_t *b) {
+ mp_limb_t c = mpn_add(r->data, a->data, a->limbs, b->data, b->limbs);
+ r->limbs = a->limbs;
+ if (c != 0) {
+ assert(r->limbs < 2*NUM_LIMBS);
+ r->data[r->limbs++] = c;
+ }
+}
+
+void static secp256k1_num_sub_abs(secp256k1_num_t *r, const secp256k1_num_t *a, const secp256k1_num_t *b) {
+ mp_limb_t c = mpn_sub(r->data, a->data, a->limbs, b->data, b->limbs);
+ assert(c == 0);
+ r->limbs = a->limbs;
+ while (r->limbs > 1 && r->data[r->limbs-1]==0) r->limbs--;
+}
+
+void static secp256k1_num_mod(secp256k1_num_t *r, const secp256k1_num_t *m) {
+ secp256k1_num_sanity(r);
+ secp256k1_num_sanity(m);
+
+ if (r->limbs >= m->limbs) {
+ mp_limb_t t[2*NUM_LIMBS];
+ mpn_tdiv_qr(t, r->data, 0, r->data, r->limbs, m->data, m->limbs);
+ r->limbs = m->limbs;
+ while (r->limbs > 1 && r->data[r->limbs-1]==0) r->limbs--;
+ }
+
+ if (r->neg && (r->limbs > 1 || r->data[0] != 0)) {
+ secp256k1_num_sub_abs(r, m, r);
+ r->neg = 0;
+ }
+}
+
+void static secp256k1_num_mod_inverse(secp256k1_num_t *r, const secp256k1_num_t *a, const secp256k1_num_t *m) {
+ secp256k1_num_sanity(a);
+ secp256k1_num_sanity(m);
+
+ // mpn_gcdext computes: (G,S) = gcdext(U,V), where
+ // * G = gcd(U,V)
+ // * G = U*S + V*T
+ // * U has equal or more limbs than V, and V has no padding
+ // If we set U to be (a padded version of) a, and V = m:
+ // G = a*S + m*T
+ // G = a*S mod m
+ // Assuming G=1:
+ // S = 1/a mod m
+ assert(m->limbs <= NUM_LIMBS);
+ assert(m->data[m->limbs-1] != 0);
+ mp_limb_t g[NUM_LIMBS+1];
+ mp_limb_t u[NUM_LIMBS+1];
+ mp_limb_t v[NUM_LIMBS+1];
+ for (int i=0; i < m->limbs; i++) {
+ u[i] = (i < a->limbs) ? a->data[i] : 0;
+ v[i] = m->data[i];
+ }
+ mp_size_t sn = NUM_LIMBS+1;
+ mp_size_t gn = mpn_gcdext(g, r->data, &sn, u, m->limbs, v, m->limbs);
+ assert(gn == 1);
+ assert(g[0] == 1);
+ r->neg = a->neg ^ m->neg;
+ if (sn < 0) {
+ mpn_sub(r->data, m->data, m->limbs, r->data, -sn);
+ r->limbs = m->limbs;
+ while (r->limbs > 1 && r->data[r->limbs-1]==0) r->limbs--;
+ } else {
+ r->limbs = sn;
+ }
+}
+
+int static secp256k1_num_is_zero(const secp256k1_num_t *a) {
+ return (a->limbs == 1 && a->data[0] == 0);
+}
+
+int static secp256k1_num_is_odd(const secp256k1_num_t *a) {
+ return a->data[0] & 1;
+}
+
+int static secp256k1_num_is_neg(const secp256k1_num_t *a) {
+ return (a->limbs > 1 || a->data[0] != 0) && a->neg;
+}
+
+int static secp256k1_num_cmp(const secp256k1_num_t *a, const secp256k1_num_t *b) {
+ if (a->limbs > b->limbs) return 1;
+ if (a->limbs < b->limbs) return -1;
+ return mpn_cmp(a->data, b->data, a->limbs);
+}
+
+void static secp256k1_num_subadd(secp256k1_num_t *r, const secp256k1_num_t *a, const secp256k1_num_t *b, int bneg) {
+ if (!(b->neg ^ bneg ^ a->neg)) { // a and b have the same sign
+ r->neg = a->neg;
+ if (a->limbs >= b->limbs) {
+ secp256k1_num_add_abs(r, a, b);
+ } else {
+ secp256k1_num_add_abs(r, b, a);
+ }
+ } else {
+ if (secp256k1_num_cmp(a, b) > 0) {
+ r->neg = a->neg;
+ secp256k1_num_sub_abs(r, a, b);
+ } else {
+ r->neg = b->neg ^ bneg;
+ secp256k1_num_sub_abs(r, b, a);
+ }
+ }
+}
+
+void static secp256k1_num_add(secp256k1_num_t *r, const secp256k1_num_t *a, const secp256k1_num_t *b) {
+ secp256k1_num_sanity(a);
+ secp256k1_num_sanity(b);
+ secp256k1_num_subadd(r, a, b, 0);
+}
+
+void static secp256k1_num_sub(secp256k1_num_t *r, const secp256k1_num_t *a, const secp256k1_num_t *b) {
+ secp256k1_num_sanity(a);
+ secp256k1_num_sanity(b);
+ secp256k1_num_subadd(r, a, b, 1);
+}
+
+void static secp256k1_num_mul(secp256k1_num_t *r, const secp256k1_num_t *a, const secp256k1_num_t *b) {
+ secp256k1_num_sanity(a);
+ secp256k1_num_sanity(b);
+
+ mp_limb_t tmp[2*NUM_LIMBS+1];
+ assert(a->limbs + b->limbs <= 2*NUM_LIMBS+1);
+ if ((a->limbs==1 && a->data[0]==0) || (b->limbs==1 && b->data[0]==0)) {
+ r->limbs = 1;
+ r->neg = 0;
+ r->data[0] = 0;
+ return;
+ }
+ if (a->limbs >= b->limbs)
+ mpn_mul(tmp, a->data, a->limbs, b->data, b->limbs);
+ else
+ mpn_mul(tmp, b->data, b->limbs, a->data, a->limbs);
+ r->limbs = a->limbs + b->limbs;
+ if (r->limbs > 1 && tmp[r->limbs - 1]==0) r->limbs--;
+ assert(r->limbs <= 2*NUM_LIMBS);
+ mpn_copyi(r->data, tmp, r->limbs);
+ r->neg = a->neg ^ b->neg;
+}
+
+void static secp256k1_num_div(secp256k1_num_t *r, const secp256k1_num_t *a, const secp256k1_num_t *b) {
+ secp256k1_num_sanity(a);
+ secp256k1_num_sanity(b);
+ if (b->limbs > a->limbs) {
+ r->limbs = 1;
+ r->data[0] = 0;
+ r->neg = 0;
+ return;
+ }
+
+ mp_limb_t quo[2*NUM_LIMBS+1];
+ mp_limb_t rem[2*NUM_LIMBS+1];
+ mpn_tdiv_qr(quo, rem, 0, a->data, a->limbs, b->data, b->limbs);
+ mpn_copyi(r->data, quo, a->limbs - b->limbs + 1);
+ r->limbs = a->limbs - b->limbs + 1;
+ while (r->limbs > 1 && r->data[r->limbs - 1]==0) r->limbs--;
+ r->neg = a->neg ^ b->neg;
+}
+
+void static secp256k1_num_mod_mul(secp256k1_num_t *r, const secp256k1_num_t *a, const secp256k1_num_t *b, const secp256k1_num_t *m) {
+ secp256k1_num_mul(r, a, b);
+ secp256k1_num_mod(r, m);
+}
+
+
+int static secp256k1_num_shift(secp256k1_num_t *r, int bits) {
+ assert(bits <= GMP_NUMB_BITS);
+ mp_limb_t ret = mpn_rshift(r->data, r->data, r->limbs, bits);
+ if (r->limbs>1 && r->data[r->limbs-1]==0) r->limbs--;
+ ret >>= (GMP_NUMB_BITS - bits);
+ return ret;
+}
+
+int static secp256k1_num_get_bit(const secp256k1_num_t *a, int pos) {
+ return (a->limbs*GMP_NUMB_BITS > pos) && ((a->data[pos/GMP_NUMB_BITS] >> (pos % GMP_NUMB_BITS)) & 1);
+}
+
+void static secp256k1_num_inc(secp256k1_num_t *r) {
+ mp_limb_t ret = mpn_add_1(r->data, r->data, r->limbs, (mp_limb_t)1);
+ if (ret) {
+ assert(r->limbs < 2*NUM_LIMBS);
+ r->data[r->limbs++] = ret;
+ }
+}
+
+void static secp256k1_num_set_hex(secp256k1_num_t *r, const char *a, int alen) {
+ static const unsigned char cvt[256] = {
+ 0, 0, 0, 0, 0, 0, 0,0,0,0,0,0,0,0,0,0,
+ 0, 0, 0, 0, 0, 0, 0,0,0,0,0,0,0,0,0,0,
+ 0, 0, 0, 0, 0, 0, 0,0,0,0,0,0,0,0,0,0,
+ 0, 1, 2, 3, 4, 5, 6,7,8,9,0,0,0,0,0,0,
+ 0,10,11,12,13,14,15,0,0,0,0,0,0,0,0,0,
+ 0, 0, 0, 0, 0, 0, 0,0,0,0,0,0,0,0,0,0,
+ 0,10,11,12,13,14,15,0,0,0,0,0,0,0,0,0,
+ 0, 0, 0, 0, 0, 0, 0,0,0,0,0,0,0,0,0,0,
+ 0, 0, 0, 0, 0, 0, 0,0,0,0,0,0,0,0,0,0,
+ 0, 0, 0, 0, 0, 0, 0,0,0,0,0,0,0,0,0,0,
+ 0, 0, 0, 0, 0, 0, 0,0,0,0,0,0,0,0,0,0,
+ 0, 0, 0, 0, 0, 0, 0,0,0,0,0,0,0,0,0,0,
+ 0, 0, 0, 0, 0, 0, 0,0,0,0,0,0,0,0,0,0,
+ 0, 0, 0, 0, 0, 0, 0,0,0,0,0,0,0,0,0,0,
+ 0, 0, 0, 0, 0, 0, 0,0,0,0,0,0,0,0,0,0,
+ 0, 0, 0, 0, 0, 0, 0,0,0,0,0,0,0,0,0,0
+ };
+ unsigned char num[257] = {};
+ for (int i=0; i<alen; i++) {
+ num[i] = cvt[a[i]];
+ }
+ r->limbs = mpn_set_str(r->data, num, alen, 16);
+ while (r->limbs > 1 && r->data[r->limbs-1] == 0) r->limbs--;
+}
+
+void static secp256k1_num_get_hex(char *r, int rlen, const secp256k1_num_t *a) {
+ static const unsigned char cvt[16] = {'0', '1', '2', '3', '4', '5', '6', '7', '8', '9', 'A', 'B', 'C', 'D', 'E', 'F'};
+ unsigned char *tmp = malloc(257);
+ mp_size_t len = mpn_get_str(tmp, 16, (mp_limb_t*)a->data, a->limbs);
+ assert(len <= rlen);
+ for (int i=0; i<len; i++) {
+ assert(rlen-len+i >= 0);
+ assert(rlen-len+i < rlen);
+ assert(tmp[i] >= 0);
+ assert(tmp[i] < 16);
+ r[rlen-len+i] = cvt[tmp[i]];
+ }
+ for (int i=0; i<rlen-len; i++) {
+ assert(i >= 0);
+ assert(i < rlen);
+ r[i] = cvt[0];
+ }
+ free(tmp);
+}
+
+void static secp256k1_num_split(secp256k1_num_t *rl, secp256k1_num_t *rh, const secp256k1_num_t *a, int bits) {
+ assert(bits > 0);
+ rh->neg = a->neg;
+ if (bits >= a->limbs * GMP_NUMB_BITS) {
+ *rl = *a;
+ rh->limbs = 1;
+ rh->data[0] = 0;
+ return;
+ }
+ rl->limbs = 0;
+ rl->neg = a->neg;
+ int left = bits;
+ while (left >= GMP_NUMB_BITS) {
+ rl->data[rl->limbs] = a->data[rl->limbs];
+ rl->limbs++;
+ left -= GMP_NUMB_BITS;
+ }
+ if (left == 0) {
+ mpn_copyi(rh->data, a->data + rl->limbs, a->limbs - rl->limbs);
+ rh->limbs = a->limbs - rl->limbs;
+ } else {
+ mpn_rshift(rh->data, a->data + rl->limbs, a->limbs - rl->limbs, left);
+ rh->limbs = a->limbs - rl->limbs;
+ while (rh->limbs>1 && rh->data[rh->limbs-1]==0) rh->limbs--;
+ }
+ if (left > 0) {
+ rl->data[rl->limbs] = a->data[rl->limbs] & ((((mp_limb_t)1) << left) - 1);
+ rl->limbs++;
+ }
+ while (rl->limbs>1 && rl->data[rl->limbs-1]==0) rl->limbs--;
+}
+
+void static secp256k1_num_negate(secp256k1_num_t *r) {
+ r->neg ^= 1;
+}
+
+#endif
diff --git a/crypto/secp256k1/secp256k1/src/impl/num_openssl.h b/crypto/secp256k1/secp256k1/src/impl/num_openssl.h
new file mode 100644
index 000000000..0a54689ac
--- /dev/null
+++ b/crypto/secp256k1/secp256k1/src/impl/num_openssl.h
@@ -0,0 +1,145 @@
+// Copyright (c) 2013 Pieter Wuille
+// Distributed under the MIT/X11 software license, see the accompanying
+// file COPYING or http://www.opensource.org/licenses/mit-license.php.
+
+#ifndef _SECP256K1_NUM_REPR_IMPL_H_
+#define _SECP256K1_NUM_REPR_IMPL_H_
+
+#include <assert.h>
+#include <string.h>
+#include <stdlib.h>
+#include <openssl/bn.h>
+#include <openssl/crypto.h>
+
+#include "../num.h"
+
+void static secp256k1_num_init(secp256k1_num_t *r) {
+ BN_init(&r->bn);
+}
+
+void static secp256k1_num_free(secp256k1_num_t *r) {
+ BN_free(&r->bn);
+}
+
+void static secp256k1_num_copy(secp256k1_num_t *r, const secp256k1_num_t *a) {
+ BN_copy(&r->bn, &a->bn);
+}
+
+void static secp256k1_num_get_bin(unsigned char *r, unsigned int rlen, const secp256k1_num_t *a) {
+ unsigned int size = BN_num_bytes(&a->bn);
+ assert(size <= rlen);
+ memset(r,0,rlen);
+ BN_bn2bin(&a->bn, r + rlen - size);
+}
+
+void static secp256k1_num_set_bin(secp256k1_num_t *r, const unsigned char *a, unsigned int alen) {
+ BN_bin2bn(a, alen, &r->bn);
+}
+
+void static secp256k1_num_set_int(secp256k1_num_t *r, int a) {
+ BN_set_word(&r->bn, a < 0 ? -a : a);
+ BN_set_negative(&r->bn, a < 0);
+}
+
+void static secp256k1_num_mod_inverse(secp256k1_num_t *r, const secp256k1_num_t *a, const secp256k1_num_t *m) {
+ BN_CTX *ctx = BN_CTX_new();
+ BN_mod_inverse(&r->bn, &a->bn, &m->bn, ctx);
+ BN_CTX_free(ctx);
+}
+
+void static secp256k1_num_mod_mul(secp256k1_num_t *r, const secp256k1_num_t *a, const secp256k1_num_t *b, const secp256k1_num_t *m) {
+ BN_CTX *ctx = BN_CTX_new();
+ BN_mod_mul(&r->bn, &a->bn, &b->bn, &m->bn, ctx);
+ BN_CTX_free(ctx);
+}
+
+int static secp256k1_num_cmp(const secp256k1_num_t *a, const secp256k1_num_t *b) {
+ return BN_cmp(&a->bn, &b->bn);
+}
+
+void static secp256k1_num_add(secp256k1_num_t *r, const secp256k1_num_t *a, const secp256k1_num_t *b) {
+ BN_add(&r->bn, &a->bn, &b->bn);
+}
+
+void static secp256k1_num_sub(secp256k1_num_t *r, const secp256k1_num_t *a, const secp256k1_num_t *b) {
+ BN_sub(&r->bn, &a->bn, &b->bn);
+}
+
+void static secp256k1_num_mul(secp256k1_num_t *r, const secp256k1_num_t *a, const secp256k1_num_t *b) {
+ BN_CTX *ctx = BN_CTX_new();
+ BN_mul(&r->bn, &a->bn, &b->bn, ctx);
+ BN_CTX_free(ctx);
+}
+
+void static secp256k1_num_div(secp256k1_num_t *r, const secp256k1_num_t *a, const secp256k1_num_t *b) {
+ BN_CTX *ctx = BN_CTX_new();
+ BN_div(&r->bn, NULL, &a->bn, &b->bn, ctx);
+ BN_CTX_free(ctx);
+}
+
+void static secp256k1_num_mod(secp256k1_num_t *r, const secp256k1_num_t *m) {
+ BN_CTX *ctx = BN_CTX_new();
+ BN_nnmod(&r->bn, &r->bn, &m->bn, ctx);
+ BN_CTX_free(ctx);
+}
+
+int static secp256k1_num_bits(const secp256k1_num_t *a) {
+ return BN_num_bits(&a->bn);
+}
+
+int static secp256k1_num_shift(secp256k1_num_t *r, int bits) {
+ int ret = BN_is_zero(&r->bn) ? 0 : r->bn.d[0] & ((1 << bits) - 1);
+ BN_rshift(&r->bn, &r->bn, bits);
+ return ret;
+}
+
+int static secp256k1_num_is_zero(const secp256k1_num_t *a) {
+ return BN_is_zero(&a->bn);
+}
+
+int static secp256k1_num_is_odd(const secp256k1_num_t *a) {
+ return BN_is_odd(&a->bn);
+}
+
+int static secp256k1_num_is_neg(const secp256k1_num_t *a) {
+ return BN_is_negative(&a->bn);
+}
+
+int static secp256k1_num_get_bit(const secp256k1_num_t *a, int pos) {
+ return BN_is_bit_set(&a->bn, pos);
+}
+
+void static secp256k1_num_inc(secp256k1_num_t *r) {
+ BN_add_word(&r->bn, 1);
+}
+
+void static secp256k1_num_set_hex(secp256k1_num_t *r, const char *a, int alen) {
+ char *str = (char*)malloc(alen+1);
+ memcpy(str, a, alen);
+ str[alen] = 0;
+ BIGNUM *pbn = &r->bn;
+ BN_hex2bn(&pbn, str);
+ free(str);
+}
+
+void static secp256k1_num_get_hex(char *r, int rlen, const secp256k1_num_t *a) {
+ char *str = BN_bn2hex(&a->bn);
+ int len = strlen(str);
+ assert(rlen >= len);
+ for (int i=0; i<rlen-len; i++)
+ r[i] = '0';
+ memcpy(r+rlen-len, str, len);
+ OPENSSL_free(str);
+}
+
+void static secp256k1_num_split(secp256k1_num_t *rl, secp256k1_num_t *rh, const secp256k1_num_t *a, int bits) {
+ BN_copy(&rl->bn, &a->bn);
+ BN_rshift(&rh->bn, &a->bn, bits);
+ BN_mask_bits(&rl->bn, bits);
+}
+
+void static secp256k1_num_negate(secp256k1_num_t *r) {
+ BN_set_negative(&r->bn, !BN_is_negative(&r->bn));
+}
+
+#endif
diff --git a/crypto/secp256k1/secp256k1/src/impl/util.h b/crypto/secp256k1/secp256k1/src/impl/util.h
new file mode 100644
index 000000000..a59a00cac
--- /dev/null
+++ b/crypto/secp256k1/secp256k1/src/impl/util.h
@@ -0,0 +1,45 @@
+// Copyright (c) 2013 Pieter Wuille
+// Distributed under the MIT/X11 software license, see the accompanying
+// file COPYING or http://www.opensource.org/licenses/mit-license.php.
+
+#ifndef _SECP256K1_UTIL_IMPL_H_
+#define _SECP256K1_UTIL_IMPL_H_
+
+#include <stdint.h>
+#include <string.h>
+
+#include "../util.h"
+
+static inline uint32_t secp256k1_rand32(void) {
+ static uint32_t Rz = 11, Rw = 11;
+ Rz = 36969 * (Rz & 0xFFFF) + (Rz >> 16);
+ Rw = 18000 * (Rw & 0xFFFF) + (Rw >> 16);
+ return (Rw << 16) + (Rw >> 16) + Rz;
+}
+
+static void secp256k1_rand256(unsigned char *b32) {
+ for (int i=0; i<8; i++) {
+ uint32_t r = secp256k1_rand32();
+ b32[i*4 + 0] = (r >> 0) & 0xFF;
+ b32[i*4 + 1] = (r >> 8) & 0xFF;
+ b32[i*4 + 2] = (r >> 16) & 0xFF;
+ b32[i*4 + 3] = (r >> 24) & 0xFF;
+ }
+}
+
+static void secp256k1_rand256_test(unsigned char *b32) {
+ int bits=0;
+ memset(b32, 0, 32);
+ while (bits < 256) {
+ uint32_t ent = secp256k1_rand32();
+ int now = 1 + ((ent % 64)*((ent >> 6) % 32)+16)/31;
+ uint32_t val = 1 & (ent >> 11);
+ while (now > 0 && bits < 256) {
+ b32[bits / 8] |= val << (bits % 8);
+ now--;
+ bits++;
+ }
+ }
+}
+
+#endif
diff --git a/crypto/secp256k1/secp256k1/src/java/org/bitcoin/NativeSecp256k1.java b/crypto/secp256k1/secp256k1/src/java/org/bitcoin/NativeSecp256k1.java
new file mode 100644
index 000000000..90a498eaa
--- /dev/null
+++ b/crypto/secp256k1/secp256k1/src/java/org/bitcoin/NativeSecp256k1.java
@@ -0,0 +1,60 @@
+package org.bitcoin;
+
+import java.nio.ByteBuffer;
+import java.nio.ByteOrder;
+
+import com.google.common.base.Preconditions;
+
+
+/**
+ * This class holds native methods to handle ECDSA verification.
+ * You can find an example library that can be used for this at
+ * https://github.com/sipa/secp256k1
+ */
+public class NativeSecp256k1 {
+ public static final boolean enabled;
+ static {
+ boolean isEnabled = true;
+ try {
+ System.loadLibrary("javasecp256k1");
+ } catch (UnsatisfiedLinkError e) {
+ isEnabled = false;
+ }
+ enabled = isEnabled;
+ }
+
+ private static ThreadLocal<ByteBuffer> nativeECDSABuffer = new ThreadLocal<ByteBuffer>();
+ /**
+ * Verifies the given secp256k1 signature in native code.
+ * Calling when enabled == false is undefined (probably library not loaded)
+ *
+ * @param data The data which was signed, must be exactly 32 bytes
+ * @param signature The signature
+ * @param pub The public key which did the signing
+ */
+ public static boolean verify(byte[] data, byte[] signature, byte[] pub) {
+ Preconditions.checkArgument(data.length == 32 && signature.length <= 520 && pub.length <= 520);
+
+ ByteBuffer byteBuff = nativeECDSABuffer.get();
+ if (byteBuff == null) {
+ byteBuff = ByteBuffer.allocateDirect(32 + 8 + 520 + 520);
+ byteBuff.order(ByteOrder.nativeOrder());
+ nativeECDSABuffer.set(byteBuff);
+ }
+ byteBuff.rewind();
+ byteBuff.put(data);
+ byteBuff.putInt(signature.length);
+ byteBuff.putInt(pub.length);
+ byteBuff.put(signature);
+ byteBuff.put(pub);
+ return secp256k1_ecdsa_verify(byteBuff) == 1;
+ }
+
+ /**
+ * @param byteBuff signature format is byte[32] data,
+ * native-endian int signatureLength, native-endian int pubkeyLength,
+ * byte[signatureLength] signature, byte[pubkeyLength] pub
+ * @returns 1 for valid signature, anything else for invalid
+ */
+ private static native int secp256k1_ecdsa_verify(ByteBuffer byteBuff);
+}
diff --git a/crypto/secp256k1/secp256k1/src/java/org_bitcoin_NativeSecp256k1.c b/crypto/secp256k1/secp256k1/src/java/org_bitcoin_NativeSecp256k1.c
new file mode 100644
index 000000000..ed65cccf6
--- /dev/null
+++ b/crypto/secp256k1/secp256k1/src/java/org_bitcoin_NativeSecp256k1.c
@@ -0,0 +1,23 @@
+#include "org_bitcoin_NativeSecp256k1.h"
+#include "include/secp256k1.h"
+
+JNIEXPORT jint JNICALL Java_org_bitcoin_NativeSecp256k1_secp256k1_1ecdsa_1verify
+ (JNIEnv* env, jclass classObject, jobject byteBufferObject)
+{
+ unsigned char* data = (unsigned char*) (*env)->GetDirectBufferAddress(env, byteBufferObject);
+ int sigLen = *((int*)(data + 32));
+ int pubLen = *((int*)(data + 32 + 4));
+
+ return secp256k1_ecdsa_verify(data, 32, data+32+8, sigLen, data+32+8+sigLen, pubLen);
+}
+
+static void __javasecp256k1_attach(void) __attribute__((constructor));
+static void __javasecp256k1_detach(void) __attribute__((destructor));
+
+static void __javasecp256k1_attach(void) {
+ secp256k1_start();
+}
+
+static void __javasecp256k1_detach(void) {
+ secp256k1_stop();
+}
diff --git a/crypto/secp256k1/secp256k1/src/java/org_bitcoin_NativeSecp256k1.h b/crypto/secp256k1/secp256k1/src/java/org_bitcoin_NativeSecp256k1.h
new file mode 100644
index 000000000..d7fb004fa
--- /dev/null
+++ b/crypto/secp256k1/secp256k1/src/java/org_bitcoin_NativeSecp256k1.h
@@ -0,0 +1,21 @@
+/* DO NOT EDIT THIS FILE - it is machine generated */
+#include <jni.h>
+/* Header for class org_bitcoin_NativeSecp256k1 */
+
+#ifndef _Included_org_bitcoin_NativeSecp256k1
+#define _Included_org_bitcoin_NativeSecp256k1
+#ifdef __cplusplus
+extern "C" {
+#endif
+/*
+ * Class: org_bitcoin_NativeSecp256k1
+ * Method: secp256k1_ecdsa_verify
+ * Signature: (Ljava/nio/ByteBuffer;)I
+ */
+JNIEXPORT jint JNICALL Java_org_bitcoin_NativeSecp256k1_secp256k1_1ecdsa_1verify
+ (JNIEnv *, jclass, jobject);
+
+#ifdef __cplusplus
+}
+#endif
+#endif
diff --git a/crypto/secp256k1/secp256k1/src/num.h b/crypto/secp256k1/secp256k1/src/num.h
new file mode 100644
index 000000000..b2e7462bc
--- /dev/null
+++ b/crypto/secp256k1/secp256k1/src/num.h
@@ -0,0 +1,93 @@
+// Copyright (c) 2013 Pieter Wuille
+// Distributed under the MIT/X11 software license, see the accompanying
+// file COPYING or http://www.opensource.org/licenses/mit-license.php.
+
+#ifndef _SECP256K1_NUM_
+#define _SECP256K1_NUM_
+
+#if defined(USE_NUM_GMP)
+#include "num_gmp.h"
+#elif defined(USE_NUM_OPENSSL)
+#include "num_openssl.h"
+#else
+#error "Please select num implementation"
+#endif
+
+/** Initialize a number. */
+void static secp256k1_num_init(secp256k1_num_t *r);
+
+/** Free a number. */
+void static secp256k1_num_free(secp256k1_num_t *r);
+
+/** Copy a number. */
+void static secp256k1_num_copy(secp256k1_num_t *r, const secp256k1_num_t *a);
+
+/** Convert a number's absolute value to a binary big-endian string.
+ * There must be enough place. */
+void static secp256k1_num_get_bin(unsigned char *r, unsigned int rlen, const secp256k1_num_t *a);
+
+/** Set a number to the value of a binary big-endian string. */
+void static secp256k1_num_set_bin(secp256k1_num_t *r, const unsigned char *a, unsigned int alen);
+
+/** Set a number equal to a (signed) integer. */
+void static secp256k1_num_set_int(secp256k1_num_t *r, int a);
+
+/** Compute a modular inverse. The input must be less than the modulus. */
+void static secp256k1_num_mod_inverse(secp256k1_num_t *r, const secp256k1_num_t *a, const secp256k1_num_t *m);
+
+/** Multiply two numbers modulo another. */
+void static secp256k1_num_mod_mul(secp256k1_num_t *r, const secp256k1_num_t *a, const secp256k1_num_t *b, const secp256k1_num_t *m);
+
+/** Compare the absolute value of two numbers. */
+int static secp256k1_num_cmp(const secp256k1_num_t *a, const secp256k1_num_t *b);
+
+/** Add two (signed) numbers. */
+void static secp256k1_num_add(secp256k1_num_t *r, const secp256k1_num_t *a, const secp256k1_num_t *b);
+
+/** Subtract two (signed) numbers. */
+void static secp256k1_num_sub(secp256k1_num_t *r, const secp256k1_num_t *a, const secp256k1_num_t *b);
+
+/** Multiply two (signed) numbers. */
+void static secp256k1_num_mul(secp256k1_num_t *r, const secp256k1_num_t *a, const secp256k1_num_t *b);
+
+/** Divide two (signed) numbers. */
+void static secp256k1_num_div(secp256k1_num_t *r, const secp256k1_num_t *a, const secp256k1_num_t *b);
+
+/** Replace a number by its remainder modulo m. M's sign is ignored. The result is a number between 0 and m-1,
+ even if r was negative. */
+void static secp256k1_num_mod(secp256k1_num_t *r, const secp256k1_num_t *m);
+
+/** Calculate the number of bits in (the absolute value of) a number. */
+int static secp256k1_num_bits(const secp256k1_num_t *a);
+
+/** Right-shift the passed number by bits bits, and return those bits. */
+int static secp256k1_num_shift(secp256k1_num_t *r, int bits);
+
+/** Check whether a number is zero. */
+int static secp256k1_num_is_zero(const secp256k1_num_t *a);
+
+/** Check whether a number is odd. */
+int static secp256k1_num_is_odd(const secp256k1_num_t *a);
+
+/** Check whether a number is strictly negative. */
+int static secp256k1_num_is_neg(const secp256k1_num_t *a);
+
+/** Check whether a particular bit is set in a number. */
+int static secp256k1_num_get_bit(const secp256k1_num_t *a, int pos);
+
+/** Increase a number by 1. */
+void static secp256k1_num_inc(secp256k1_num_t *r);
+
+/** Set a number equal to the value of a hex string (unsigned). */
+void static secp256k1_num_set_hex(secp256k1_num_t *r, const char *a, int alen);
+
+/** Convert (the absolute value of) a number to a hexadecimal string. */
+void static secp256k1_num_get_hex(char *r, int rlen, const secp256k1_num_t *a);
+
+/** Split a number into a low and high part. */
+void static secp256k1_num_split(secp256k1_num_t *rl, secp256k1_num_t *rh, const secp256k1_num_t *a, int bits);
+
+/** Change a number's sign. */
+void static secp256k1_num_negate(secp256k1_num_t *r);
+
+#endif
diff --git a/crypto/secp256k1/secp256k1/src/num_gmp.h b/crypto/secp256k1/secp256k1/src/num_gmp.h
new file mode 100644
index 000000000..960df8605
--- /dev/null
+++ b/crypto/secp256k1/secp256k1/src/num_gmp.h
@@ -0,0 +1,18 @@
+// Copyright (c) 2013 Pieter Wuille
+// Distributed under the MIT/X11 software license, see the accompanying
+// file COPYING or http://www.opensource.org/licenses/mit-license.php.
+
+#ifndef _SECP256K1_NUM_REPR_
+#define _SECP256K1_NUM_REPR_
+
+#include <gmp.h>
+
+#define NUM_LIMBS ((256+GMP_NUMB_BITS-1)/GMP_NUMB_BITS)
+
+typedef struct {
+ mp_limb_t data[2*NUM_LIMBS];
+ int neg;
+ int limbs;
+} secp256k1_num_t;
+
+#endif
diff --git a/crypto/secp256k1/secp256k1/src/num_openssl.h b/crypto/secp256k1/secp256k1/src/num_openssl.h
new file mode 100644
index 000000000..7d03757f6
--- /dev/null
+++ b/crypto/secp256k1/secp256k1/src/num_openssl.h
@@ -0,0 +1,14 @@
+// Copyright (c) 2013 Pieter Wuille
+// Distributed under the MIT/X11 software license, see the accompanying
+// file COPYING or http://www.opensource.org/licenses/mit-license.php.
+
+#ifndef _SECP256K1_NUM_REPR_
+#define _SECP256K1_NUM_REPR_
+
+#include <openssl/bn.h>
+
+typedef struct {
+ BIGNUM bn;
+} secp256k1_num_t;
+
+#endif
diff --git a/crypto/secp256k1/secp256k1/src/secp256k1.c b/crypto/secp256k1/secp256k1/src/secp256k1.c
new file mode 100644
index 000000000..ed8bf2e95
--- /dev/null
+++ b/crypto/secp256k1/secp256k1/src/secp256k1.c
@@ -0,0 +1,269 @@
+// Copyright (c) 2013 Pieter Wuille
+// Distributed under the MIT/X11 software license, see the accompanying
+// file COPYING or http://www.opensource.org/licenses/mit-license.php.
+
+#include "impl/num.h"
+#include "impl/field.h"
+#include "impl/group.h"
+#include "impl/ecmult.h"
+#include "impl/ecdsa.h"
+
+void secp256k1_start(void) {
+ secp256k1_fe_start();
+ secp256k1_ge_start();
+ secp256k1_ecmult_start();
+}
+
+void secp256k1_stop(void) {
+ secp256k1_ecmult_stop();
+ secp256k1_ge_stop();
+ secp256k1_fe_stop();
+}
+
+int secp256k1_ecdsa_verify(const unsigned char *msg, int msglen, const unsigned char *sig, int siglen, const unsigned char *pubkey, int pubkeylen) {
+ int ret = -3;
+ secp256k1_num_t m;
+ secp256k1_num_init(&m);
+ secp256k1_ecdsa_sig_t s;
+ secp256k1_ecdsa_sig_init(&s);
+ secp256k1_ge_t q;
+ secp256k1_num_set_bin(&m, msg, msglen);
+
+ if (!secp256k1_ecdsa_pubkey_parse(&q, pubkey, pubkeylen)) {
+ ret = -1;
+ goto end;
+ }
+ if (!secp256k1_ecdsa_sig_parse(&s, sig, siglen)) {
+ ret = -2;
+ goto end;
+ }
+ if (!secp256k1_ecdsa_sig_verify(&s, &q, &m)) {
+ ret = 0;
+ goto end;
+ }
+ ret = 1;
+end:
+ secp256k1_ecdsa_sig_free(&s);
+ secp256k1_num_free(&m);
+ return ret;
+}
+
+int secp256k1_ecdsa_sign(const unsigned char *message, int messagelen, unsigned char *signature, int *signaturelen, const unsigned char *seckey, const unsigned char *nonce) {
+ secp256k1_num_t sec, non, msg;
+ secp256k1_num_init(&sec);
+ secp256k1_num_init(&non);
+ secp256k1_num_init(&msg);
+ secp256k1_num_set_bin(&sec, seckey, 32);
+ secp256k1_num_set_bin(&non, nonce, 32);
+ secp256k1_num_set_bin(&msg, message, messagelen);
+ secp256k1_ecdsa_sig_t sig;
+ secp256k1_ecdsa_sig_init(&sig);
+ int ret = secp256k1_ecdsa_sig_sign(&sig, &sec, &msg, &non, NULL);
+ if (ret) {
+ secp256k1_ecdsa_sig_serialize(signature, signaturelen, &sig);
+ }
+ secp256k1_ecdsa_sig_free(&sig);
+ secp256k1_num_free(&msg);
+ secp256k1_num_free(&non);
+ secp256k1_num_free(&sec);
+ return ret;
+}
+
+int secp256k1_ecdsa_sign_compact(const unsigned char *message, int messagelen, unsigned char *sig64, const unsigned char *seckey, const unsigned char *nonce, int *recid) {
+ secp256k1_num_t sec, non, msg;
+ secp256k1_num_init(&sec);
+ secp256k1_num_init(&non);
+ secp256k1_num_init(&msg);
+ secp256k1_num_set_bin(&sec, seckey, 32);
+ secp256k1_num_set_bin(&non, nonce, 32);
+ secp256k1_num_set_bin(&msg, message, messagelen);
+ secp256k1_ecdsa_sig_t sig;
+ secp256k1_ecdsa_sig_init(&sig);
+ int ret = secp256k1_ecdsa_sig_sign(&sig, &sec, &msg, &non, recid);
+ if (ret) {
+ secp256k1_num_get_bin(sig64, 32, &sig.r);
+ secp256k1_num_get_bin(sig64 + 32, 32, &sig.s);
+ }
+ secp256k1_ecdsa_sig_free(&sig);
+ secp256k1_num_free(&msg);
+ secp256k1_num_free(&non);
+ secp256k1_num_free(&sec);
+ return ret;
+}
+
+int secp256k1_ecdsa_recover_compact(const unsigned char *msg, int msglen, const unsigned char *sig64, unsigned char *pubkey, int *pubkeylen, int compressed, int recid) {
+ int ret = 0;
+ secp256k1_num_t m;
+ secp256k1_num_init(&m);
+ secp256k1_ecdsa_sig_t sig;
+ secp256k1_ecdsa_sig_init(&sig);
+ secp256k1_num_set_bin(&sig.r, sig64, 32);
+ secp256k1_num_set_bin(&sig.s, sig64 + 32, 32);
+ secp256k1_num_set_bin(&m, msg, msglen);
+
+ secp256k1_ge_t q;
+ if (secp256k1_ecdsa_sig_recover(&sig, &q, &m, recid)) {
+ secp256k1_ecdsa_pubkey_serialize(&q, pubkey, pubkeylen, compressed);
+ ret = 1;
+ }
+ secp256k1_ecdsa_sig_free(&sig);
+ secp256k1_num_free(&m);
+ return ret;
+}
+
+int secp256k1_ecdsa_seckey_verify(const unsigned char *seckey) {
+ secp256k1_num_t sec;
+ secp256k1_num_init(&sec);
+ secp256k1_num_set_bin(&sec, seckey, 32);
+ int ret = !secp256k1_num_is_zero(&sec) &&
+ (secp256k1_num_cmp(&sec, &secp256k1_ge_consts->order) < 0);
+ secp256k1_num_free(&sec);
+ return ret;
+}
+
+int secp256k1_ecdsa_pubkey_verify(const unsigned char *pubkey, int pubkeylen) {
+ secp256k1_ge_t q;
+ return secp256k1_ecdsa_pubkey_parse(&q, pubkey, pubkeylen);
+}
+
+int secp256k1_ecdsa_pubkey_create(unsigned char *pubkey, int *pubkeylen, const unsigned char *seckey, int compressed) {
+ secp256k1_num_t sec;
+ secp256k1_num_init(&sec);
+ secp256k1_num_set_bin(&sec, seckey, 32);
+ secp256k1_gej_t pj;
+ secp256k1_ecmult_gen(&pj, &sec);
+ secp256k1_ge_t p;
+ secp256k1_ge_set_gej(&p, &pj);
+ secp256k1_ecdsa_pubkey_serialize(&p, pubkey, pubkeylen, compressed);
+ return 1;
+}
+
+int secp256k1_ecdsa_pubkey_decompress(unsigned char *pubkey, int *pubkeylen) {
+ secp256k1_ge_t p;
+ if (!secp256k1_ecdsa_pubkey_parse(&p, pubkey, *pubkeylen))
+ return 0;
+ secp256k1_ecdsa_pubkey_serialize(&p, pubkey, pubkeylen, 0);
+ return 1;
+}
+
+int secp256k1_ecdsa_privkey_tweak_add(unsigned char *seckey, const unsigned char *tweak) {
+ int ret = 1;
+ secp256k1_num_t term;
+ secp256k1_num_init(&term);
+ secp256k1_num_set_bin(&term, tweak, 32);
+ if (secp256k1_num_cmp(&term, &secp256k1_ge_consts->order) >= 0)
+ ret = 0;
+ secp256k1_num_t sec;
+ secp256k1_num_init(&sec);
+ if (ret) {
+ secp256k1_num_set_bin(&sec, seckey, 32);
+ secp256k1_num_add(&sec, &sec, &term);
+ secp256k1_num_mod(&sec, &secp256k1_ge_consts->order);
+ if (secp256k1_num_is_zero(&sec))
+ ret = 0;
+ }
+ if (ret)
+ secp256k1_num_get_bin(seckey, 32, &sec);
+ secp256k1_num_free(&sec);
+ secp256k1_num_free(&term);
+ return ret;
+}
+
+int secp256k1_ecdsa_pubkey_tweak_add(unsigned char *pubkey, int pubkeylen, const unsigned char *tweak) {
+ int ret = 1;
+ secp256k1_num_t term;
+ secp256k1_num_init(&term);
+ secp256k1_num_set_bin(&term, tweak, 32);
+ if (secp256k1_num_cmp(&term, &secp256k1_ge_consts->order) >= 0)
+ ret = 0;
+ secp256k1_ge_t p;
+ if (ret) {
+ if (!secp256k1_ecdsa_pubkey_parse(&p, pubkey, pubkeylen))
+ ret = 0;
+ }
+ if (ret) {
+ secp256k1_gej_t pt;
+ secp256k1_ecmult_gen(&pt, &term);
+ secp256k1_gej_add_ge(&pt, &pt, &p);
+ if (secp256k1_gej_is_infinity(&pt))
+ ret = 0;
+ secp256k1_ge_set_gej(&p, &pt);
+ int oldlen = pubkeylen;
+ secp256k1_ecdsa_pubkey_serialize(&p, pubkey, &pubkeylen, oldlen <= 33);
+ assert(pubkeylen == oldlen);
+ }
+ secp256k1_num_free(&term);
+ return ret;
+}
+
+int secp256k1_ecdsa_privkey_tweak_mul(unsigned char *seckey, const unsigned char *tweak) {
+ int ret = 1;
+ secp256k1_num_t factor;
+ secp256k1_num_init(&factor);
+ secp256k1_num_set_bin(&factor, tweak, 32);
+ if (secp256k1_num_is_zero(&factor))
+ ret = 0;
+ if (secp256k1_num_cmp(&factor, &secp256k1_ge_consts->order) >= 0)
+ ret = 0;
+ secp256k1_num_t sec;
+ secp256k1_num_init(&sec);
+ if (ret) {
+ secp256k1_num_set_bin(&sec, seckey, 32);
+ secp256k1_num_mod_mul(&sec, &sec, &factor, &secp256k1_ge_consts->order);
+ }
+ if (ret)
+ secp256k1_num_get_bin(seckey, 32, &sec);
+ secp256k1_num_free(&sec);
+ secp256k1_num_free(&factor);
+ return ret;
+}
+
+int secp256k1_ecdsa_pubkey_tweak_mul(unsigned char *pubkey, int pubkeylen, const unsigned char *tweak) {
+ int ret = 1;
+ secp256k1_num_t factor;
+ secp256k1_num_init(&factor);
+ secp256k1_num_set_bin(&factor, tweak, 32);
+ if (secp256k1_num_is_zero(&factor))
+ ret = 0;
+ if (secp256k1_num_cmp(&factor, &secp256k1_ge_consts->order) >= 0)
+ ret = 0;
+ secp256k1_ge_t p;
+ if (ret) {
+ if (!secp256k1_ecdsa_pubkey_parse(&p, pubkey, pubkeylen))
+ ret = 0;
+ }
+ if (ret) {
+ secp256k1_num_t zero;
+ secp256k1_num_init(&zero);
+ secp256k1_num_set_int(&zero, 0);
+ secp256k1_gej_t pt;
+ secp256k1_gej_set_ge(&pt, &p);
+ secp256k1_ecmult(&pt, &pt, &factor, &zero);
+ secp256k1_num_free(&zero);
+ secp256k1_ge_set_gej(&p, &pt);
+ int oldlen = pubkeylen;
+ secp256k1_ecdsa_pubkey_serialize(&p, pubkey, &pubkeylen, oldlen <= 33);
+ assert(pubkeylen == oldlen);
+ }
+ secp256k1_num_free(&factor);
+ return ret;
+}
+
+int secp256k1_ecdsa_privkey_export(const unsigned char *seckey, unsigned char *privkey, int *privkeylen, int compressed) {
+ secp256k1_num_t key;
+ secp256k1_num_init(&key);
+ secp256k1_num_set_bin(&key, seckey, 32);
+ int ret = secp256k1_ecdsa_privkey_serialize(privkey, privkeylen, &key, compressed);
+ secp256k1_num_free(&key);
+ return ret;
+}
+
+int secp256k1_ecdsa_privkey_import(unsigned char *seckey, const unsigned char *privkey, int privkeylen) {
+ secp256k1_num_t key;
+ secp256k1_num_init(&key);
+ int ret = secp256k1_ecdsa_privkey_parse(&key, privkey, privkeylen);
+ if (ret)
+ secp256k1_num_get_bin(seckey, 32, &key);
+ secp256k1_num_free(&key);
+ return ret;
+}
diff --git a/crypto/secp256k1/secp256k1/src/tests.c b/crypto/secp256k1/secp256k1/src/tests.c
new file mode 100644
index 000000000..af7bbaad0
--- /dev/null
+++ b/crypto/secp256k1/secp256k1/src/tests.c
@@ -0,0 +1,465 @@
+// Copyright (c) 2013 Pieter Wuille
+// Distributed under the MIT/X11 software license, see the accompanying
+// file COPYING or http://www.opensource.org/licenses/mit-license.php.
+
+#include <assert.h>
+
+#include "impl/num.h"
+#include "impl/field.h"
+#include "impl/group.h"
+#include "impl/ecmult.h"
+#include "impl/ecdsa.h"
+#include "impl/util.h"
+
+#ifdef ENABLE_OPENSSL_TESTS
+#include "openssl/bn.h"
+#include "openssl/ec.h"
+#include "openssl/ecdsa.h"
+#include "openssl/obj_mac.h"
+#endif
+
+static int count = 100;
+
+/***** NUM TESTS *****/
+
+void random_num_negate(secp256k1_num_t *num) {
+ if (secp256k1_rand32() & 1)
+ secp256k1_num_negate(num);
+}
+
+void random_num_order_test(secp256k1_num_t *num) {
+ do {
+ unsigned char b32[32];
+ secp256k1_rand256_test(b32);
+ secp256k1_num_set_bin(num, b32, 32);
+ if (secp256k1_num_is_zero(num))
+ continue;
+ if (secp256k1_num_cmp(num, &secp256k1_ge_consts->order) >= 0)
+ continue;
+ break;
+ } while(1);
+}
+
+void random_num_order(secp256k1_num_t *num) {
+ do {
+ unsigned char b32[32];
+ secp256k1_rand256(b32);
+ secp256k1_num_set_bin(num, b32, 32);
+ if (secp256k1_num_is_zero(num))
+ continue;
+ if (secp256k1_num_cmp(num, &secp256k1_ge_consts->order) >= 0)
+ continue;
+ break;
+ } while(1);
+}
+
+void test_num_copy_inc_cmp() {
+ secp256k1_num_t n1,n2;
+ secp256k1_num_init(&n1);
+ secp256k1_num_init(&n2);
+ random_num_order(&n1);
+ secp256k1_num_copy(&n2, &n1);
+ assert(secp256k1_num_cmp(&n1, &n2) == 0);
+ assert(secp256k1_num_cmp(&n2, &n1) == 0);
+ secp256k1_num_inc(&n2);
+ assert(secp256k1_num_cmp(&n1, &n2) != 0);
+ assert(secp256k1_num_cmp(&n2, &n1) != 0);
+ secp256k1_num_free(&n1);
+ secp256k1_num_free(&n2);
+}
+
+
+void test_num_get_set_hex() {
+ secp256k1_num_t n1,n2;
+ secp256k1_num_init(&n1);
+ secp256k1_num_init(&n2);
+ random_num_order_test(&n1);
+ char c[64];
+ secp256k1_num_get_hex(c, 64, &n1);
+ secp256k1_num_set_hex(&n2, c, 64);
+ assert(secp256k1_num_cmp(&n1, &n2) == 0);
+ for (int i=0; i<64; i++) {
+ // check whether the lower 4 bits correspond to the last hex character
+ int low1 = secp256k1_num_shift(&n1, 4);
+ int lowh = c[63];
+ int low2 = (lowh>>6)*9+(lowh-'0')&15;
+ assert(low1 == low2);
+ // shift bits off the hex representation, and compare
+ memmove(c+1, c, 63);
+ c[0] = '0';
+ secp256k1_num_set_hex(&n2, c, 64);
+ assert(secp256k1_num_cmp(&n1, &n2) == 0);
+ }
+ secp256k1_num_free(&n2);
+ secp256k1_num_free(&n1);
+}
+
+void test_num_get_set_bin() {
+ secp256k1_num_t n1,n2;
+ secp256k1_num_init(&n1);
+ secp256k1_num_init(&n2);
+ random_num_order_test(&n1);
+ unsigned char c[32];
+ secp256k1_num_get_bin(c, 32, &n1);
+ secp256k1_num_set_bin(&n2, c, 32);
+ assert(secp256k1_num_cmp(&n1, &n2) == 0);
+ for (int i=0; i<32; i++) {
+ // check whether the lower 8 bits correspond to the last byte
+ int low1 = secp256k1_num_shift(&n1, 8);
+ int low2 = c[31];
+ assert(low1 == low2);
+ // shift bits off the byte representation, and compare
+ memmove(c+1, c, 31);
+ c[0] = 0;
+ secp256k1_num_set_bin(&n2, c, 32);
+ assert(secp256k1_num_cmp(&n1, &n2) == 0);
+ }
+ secp256k1_num_free(&n2);
+ secp256k1_num_free(&n1);
+}
+
+void run_num_int() {
+ secp256k1_num_t n1;
+ secp256k1_num_init(&n1);
+ for (int i=-255; i<256; i++) {
+ unsigned char c1[3] = {};
+ c1[2] = abs(i);
+ unsigned char c2[3] = {0x11,0x22,0x33};
+ secp256k1_num_set_int(&n1, i);
+ secp256k1_num_get_bin(c2, 3, &n1);
+ assert(memcmp(c1, c2, 3) == 0);
+ }
+ secp256k1_num_free(&n1);
+}
+
+void test_num_negate() {
+ secp256k1_num_t n1;
+ secp256k1_num_t n2;
+ secp256k1_num_init(&n1);
+ secp256k1_num_init(&n2);
+ random_num_order_test(&n1); // n1 = R
+ random_num_negate(&n1);
+ secp256k1_num_copy(&n2, &n1); // n2 = R
+ secp256k1_num_sub(&n1, &n2, &n1); // n1 = n2-n1 = 0
+ assert(secp256k1_num_is_zero(&n1));
+ secp256k1_num_copy(&n1, &n2); // n1 = R
+ secp256k1_num_negate(&n1); // n1 = -R
+ assert(!secp256k1_num_is_zero(&n1));
+ secp256k1_num_add(&n1, &n2, &n1); // n1 = n2+n1 = 0
+ assert(secp256k1_num_is_zero(&n1));
+ secp256k1_num_copy(&n1, &n2); // n1 = R
+ secp256k1_num_negate(&n1); // n1 = -R
+ assert(secp256k1_num_is_neg(&n1) != secp256k1_num_is_neg(&n2));
+ secp256k1_num_negate(&n1); // n1 = R
+ assert(secp256k1_num_cmp(&n1, &n2) == 0);
+ assert(secp256k1_num_is_neg(&n1) == secp256k1_num_is_neg(&n2));
+ secp256k1_num_free(&n2);
+ secp256k1_num_free(&n1);
+}
+
+void test_num_add_sub() {
+ secp256k1_num_t n1;
+ secp256k1_num_t n2;
+ secp256k1_num_init(&n1);
+ secp256k1_num_init(&n2);
+ random_num_order_test(&n1); // n1 = R1
+ random_num_negate(&n1);
+ random_num_order_test(&n2); // n2 = R2
+ random_num_negate(&n2);
+ secp256k1_num_t n1p2, n2p1, n1m2, n2m1;
+ secp256k1_num_init(&n1p2);
+ secp256k1_num_init(&n2p1);
+ secp256k1_num_init(&n1m2);
+ secp256k1_num_init(&n2m1);
+ secp256k1_num_add(&n1p2, &n1, &n2); // n1p2 = R1 + R2
+ secp256k1_num_add(&n2p1, &n2, &n1); // n2p1 = R2 + R1
+ secp256k1_num_sub(&n1m2, &n1, &n2); // n1m2 = R1 - R2
+ secp256k1_num_sub(&n2m1, &n2, &n1); // n2m1 = R2 - R1
+ assert(secp256k1_num_cmp(&n1p2, &n2p1) == 0);
+ assert(secp256k1_num_cmp(&n1p2, &n1m2) != 0);
+ secp256k1_num_negate(&n2m1); // n2m1 = -R2 + R1
+ assert(secp256k1_num_cmp(&n2m1, &n1m2) == 0);
+ assert(secp256k1_num_cmp(&n2m1, &n1) != 0);
+ secp256k1_num_add(&n2m1, &n2m1, &n2); // n2m1 = -R2 + R1 + R2 = R1
+ assert(secp256k1_num_cmp(&n2m1, &n1) == 0);
+ assert(secp256k1_num_cmp(&n2p1, &n1) != 0);
+ secp256k1_num_sub(&n2p1, &n2p1, &n2); // n2p1 = R2 + R1 - R2 = R1
+ assert(secp256k1_num_cmp(&n2p1, &n1) == 0);
+ secp256k1_num_free(&n2m1);
+ secp256k1_num_free(&n1m2);
+ secp256k1_num_free(&n2p1);
+ secp256k1_num_free(&n1p2);
+ secp256k1_num_free(&n2);
+ secp256k1_num_free(&n1);
+}
+
+void run_num_smalltests() {
+ for (int i=0; i<100*count; i++) {
+ test_num_copy_inc_cmp();
+ test_num_get_set_hex();
+ test_num_get_set_bin();
+ test_num_negate();
+ test_num_add_sub();
+ }
+ run_num_int();
+}
+
+void run_ecmult_chain() {
+ // random starting point A (on the curve)
+ secp256k1_fe_t ax; secp256k1_fe_set_hex(&ax, "8b30bbe9ae2a990696b22f670709dff3727fd8bc04d3362c6c7bf458e2846004", 64);
+ secp256k1_fe_t ay; secp256k1_fe_set_hex(&ay, "a357ae915c4a65281309edf20504740f0eb3343990216b4f81063cb65f2f7e0f", 64);
+ secp256k1_gej_t a; secp256k1_gej_set_xy(&a, &ax, &ay);
+ // two random initial factors xn and gn
+ secp256k1_num_t xn;
+ secp256k1_num_init(&xn);
+ secp256k1_num_set_hex(&xn, "84cc5452f7fde1edb4d38a8ce9b1b84ccef31f146e569be9705d357a42985407", 64);
+ secp256k1_num_t gn;
+ secp256k1_num_init(&gn);
+ secp256k1_num_set_hex(&gn, "a1e58d22553dcd42b23980625d4c57a96e9323d42b3152e5ca2c3990edc7c9de", 64);
+ // two small multipliers to be applied to xn and gn in every iteration:
+ secp256k1_num_t xf;
+ secp256k1_num_init(&xf);
+ secp256k1_num_set_hex(&xf, "1337", 4);
+ secp256k1_num_t gf;
+ secp256k1_num_init(&gf);
+ secp256k1_num_set_hex(&gf, "7113", 4);
+ // accumulators with the resulting coefficients to A and G
+ secp256k1_num_t ae;
+ secp256k1_num_init(&ae);
+ secp256k1_num_set_int(&ae, 1);
+ secp256k1_num_t ge;
+ secp256k1_num_init(&ge);
+ secp256k1_num_set_int(&ge, 0);
+ // the point being computed
+ secp256k1_gej_t x = a;
+ const secp256k1_num_t *order = &secp256k1_ge_consts->order;
+ for (int i=0; i<200*count; i++) {
+ // in each iteration, compute X = xn*X + gn*G;
+ secp256k1_ecmult(&x, &x, &xn, &gn);
+ // also compute ae and ge: the actual accumulated factors for A and G
+ // if X was (ae*A+ge*G), xn*X + gn*G results in (xn*ae*A + (xn*ge+gn)*G)
+ secp256k1_num_mod_mul(&ae, &ae, &xn, order);
+ secp256k1_num_mod_mul(&ge, &ge, &xn, order);
+ secp256k1_num_add(&ge, &ge, &gn);
+ secp256k1_num_mod(&ge, order);
+ // modify xn and gn
+ secp256k1_num_mod_mul(&xn, &xn, &xf, order);
+ secp256k1_num_mod_mul(&gn, &gn, &gf, order);
+
+ // verify
+ if (i == 19999) {
+ char res[132]; int resl = 132;
+ secp256k1_gej_get_hex(res, &resl, &x);
+ assert(strcmp(res, "(D6E96687F9B10D092A6F35439D86CEBEA4535D0D409F53586440BD74B933E830,B95CBCA2C77DA786539BE8FD53354D2D3B4F566AE658045407ED6015EE1B2A88)") == 0);
+ }
+ }
+ // redo the computation, but directly with the resulting ae and ge coefficients:
+ secp256k1_gej_t x2; secp256k1_ecmult(&x2, &a, &ae, &ge);
+ char res[132]; int resl = 132;
+ char res2[132]; int resl2 = 132;
+ secp256k1_gej_get_hex(res, &resl, &x);
+ secp256k1_gej_get_hex(res2, &resl2, &x2);
+ assert(strcmp(res, res2) == 0);
+ assert(strlen(res) == 131);
+ secp256k1_num_free(&xn);
+ secp256k1_num_free(&gn);
+ secp256k1_num_free(&xf);
+ secp256k1_num_free(&gf);
+ secp256k1_num_free(&ae);
+ secp256k1_num_free(&ge);
+}
+
+void test_point_times_order(const secp256k1_gej_t *point) {
+ // either the point is not on the curve, or multiplying it by the order results in O
+ if (!secp256k1_gej_is_valid(point))
+ return;
+
+ const secp256k1_num_t *order = &secp256k1_ge_consts->order;
+ secp256k1_num_t zero;
+ secp256k1_num_init(&zero);
+ secp256k1_num_set_int(&zero, 0);
+ secp256k1_gej_t res;
+ secp256k1_ecmult(&res, point, order, order); // calc res = order * point + order * G;
+ assert(secp256k1_gej_is_infinity(&res));
+ secp256k1_num_free(&zero);
+}
+
+void run_point_times_order() {
+ secp256k1_fe_t x; secp256k1_fe_set_hex(&x, "02", 2);
+ for (int i=0; i<500; i++) {
+ secp256k1_ge_t p; secp256k1_ge_set_xo(&p, &x, 1);
+ secp256k1_gej_t j; secp256k1_gej_set_ge(&j, &p);
+ test_point_times_order(&j);
+ secp256k1_fe_sqr(&x, &x);
+ }
+ char c[65]; int cl=65;
+ secp256k1_fe_get_hex(c, &cl, &x);
+ assert(strcmp(c, "7603CB59B0EF6C63FE6084792A0C378CDB3233A80F8A9A09A877DEAD31B38C45") == 0);
+}
+
+void test_wnaf(const secp256k1_num_t *number, int w) {
+ secp256k1_num_t x, two, t;
+ secp256k1_num_init(&x);
+ secp256k1_num_init(&two);
+ secp256k1_num_init(&t);
+ secp256k1_num_set_int(&x, 0);
+ secp256k1_num_set_int(&two, 2);
+ int wnaf[257];
+ int bits = secp256k1_ecmult_wnaf(wnaf, number, w);
+ int zeroes = -1;
+ for (int i=bits-1; i>=0; i--) {
+ secp256k1_num_mul(&x, &x, &two);
+ int v = wnaf[i];
+ if (v) {
+ assert(zeroes == -1 || zeroes >= w-1); // check that distance between non-zero elements is at least w-1
+ zeroes=0;
+ assert((v & 1) == 1); // check non-zero elements are odd
+ assert(v <= (1 << (w-1)) - 1); // check range below
+ assert(v >= -(1 << (w-1)) - 1); // check range above
+ } else {
+ assert(zeroes != -1); // check that no unnecessary zero padding exists
+ zeroes++;
+ }
+ secp256k1_num_set_int(&t, v);
+ secp256k1_num_add(&x, &x, &t);
+ }
+ assert(secp256k1_num_cmp(&x, number) == 0); // check that wnaf represents number
+ secp256k1_num_free(&x);
+ secp256k1_num_free(&two);
+ secp256k1_num_free(&t);
+}
+
+void run_wnaf() {
+ secp256k1_num_t n;
+ secp256k1_num_init(&n);
+ for (int i=0; i<count; i++) {
+ random_num_order(&n);
+ if (i % 1)
+ secp256k1_num_negate(&n);
+ test_wnaf(&n, 4+(i%10));
+ }
+ secp256k1_num_free(&n);
+}
+
+void random_sign(secp256k1_ecdsa_sig_t *sig, const secp256k1_num_t *key, const secp256k1_num_t *msg, int *recid) {
+ secp256k1_num_t nonce;
+ secp256k1_num_init(&nonce);
+ do {
+ random_num_order_test(&nonce);
+ } while(!secp256k1_ecdsa_sig_sign(sig, key, msg, &nonce, recid));
+ secp256k1_num_free(&nonce);
+}
+
+void test_ecdsa_sign_verify() {
+ const secp256k1_ge_consts_t *c = secp256k1_ge_consts;
+ secp256k1_num_t msg, key;
+ secp256k1_num_init(&msg);
+ random_num_order_test(&msg);
+ secp256k1_num_init(&key);
+ random_num_order_test(&key);
+ secp256k1_gej_t pubj; secp256k1_ecmult_gen(&pubj, &key);
+ secp256k1_ge_t pub; secp256k1_ge_set_gej(&pub, &pubj);
+ secp256k1_ecdsa_sig_t sig;
+ secp256k1_ecdsa_sig_init(&sig);
+ random_sign(&sig, &key, &msg, NULL);
+ assert(secp256k1_ecdsa_sig_verify(&sig, &pub, &msg));
+ secp256k1_num_inc(&msg);
+ assert(!secp256k1_ecdsa_sig_verify(&sig, &pub, &msg));
+ secp256k1_ecdsa_sig_free(&sig);
+ secp256k1_num_free(&msg);
+ secp256k1_num_free(&key);
+}
+
+void run_ecdsa_sign_verify() {
+ for (int i=0; i<10*count; i++) {
+ test_ecdsa_sign_verify();
+ }
+}
+
+#ifdef ENABLE_OPENSSL_TESTS
+EC_KEY *get_openssl_key(const secp256k1_num_t *key) {
+ unsigned char privkey[300];
+ int privkeylen;
+ int compr = secp256k1_rand32() & 1;
+ const unsigned char* pbegin = privkey;
+ EC_KEY *ec_key = EC_KEY_new_by_curve_name(NID_secp256k1);
+ assert(secp256k1_ecdsa_privkey_serialize(privkey, &privkeylen, key, compr));
+ assert(d2i_ECPrivateKey(&ec_key, &pbegin, privkeylen));
+ assert(EC_KEY_check_key(ec_key));
+ return ec_key;
+}
+
+void test_ecdsa_openssl() {
+ const secp256k1_ge_consts_t *c = secp256k1_ge_consts;
+ secp256k1_num_t key, msg;
+ secp256k1_num_init(&msg);
+ unsigned char message[32];
+ secp256k1_rand256_test(message);
+ secp256k1_num_set_bin(&msg, message, 32);
+ secp256k1_num_init(&key);
+ random_num_order_test(&key);
+ secp256k1_gej_t qj;
+ secp256k1_ecmult_gen(&qj, &key);
+ secp256k1_ge_t q;
+ secp256k1_ge_set_gej(&q, &qj);
+ EC_KEY *ec_key = get_openssl_key(&key);
+ assert(ec_key);
+ unsigned char signature[80];
+ int sigsize = 80;
+ assert(ECDSA_sign(0, message, sizeof(message), signature, &sigsize, ec_key));
+ secp256k1_ecdsa_sig_t sig;
+ secp256k1_ecdsa_sig_init(&sig);
+ assert(secp256k1_ecdsa_sig_parse(&sig, signature, sigsize));
+ assert(secp256k1_ecdsa_sig_verify(&sig, &q, &msg));
+ secp256k1_num_inc(&sig.r);
+ assert(!secp256k1_ecdsa_sig_verify(&sig, &q, &msg));
+
+ random_sign(&sig, &key, &msg, NULL);
+ sigsize = 80;
+ assert(secp256k1_ecdsa_sig_serialize(signature, &sigsize, &sig));
+ assert(ECDSA_verify(0, message, sizeof(message), signature, sigsize, ec_key) == 1);
+
+ secp256k1_ecdsa_sig_free(&sig);
+ EC_KEY_free(ec_key);
+ secp256k1_num_free(&key);
+ secp256k1_num_free(&msg);
+}
+
+void run_ecdsa_openssl() {
+ for (int i=0; i<10*count; i++) {
+ test_ecdsa_openssl();
+ }
+}
+#endif
+
+int main(int argc, char **argv) {
+ if (argc > 1)
+ count = strtol(argv[1], NULL, 0)*47;
+
+ printf("test count = %i\n", count);
+
+ // initialize
+ secp256k1_fe_start();
+ secp256k1_ge_start();
+ secp256k1_ecmult_start();
+
+ // num tests
+ run_num_smalltests();
+
+ // ecmult tests
+ run_wnaf();
+ run_point_times_order();
+ run_ecmult_chain();
+
+ // ecdsa tests
+ run_ecdsa_sign_verify();
+#ifdef ENABLE_OPENSSL_TESTS
+ run_ecdsa_openssl();
+#endif
+
+ // shutdown
+ secp256k1_ecmult_stop();
+ secp256k1_ge_stop();
+ secp256k1_fe_stop();
+ return 0;
+}
diff --git a/crypto/secp256k1/secp256k1/src/util.h b/crypto/secp256k1/secp256k1/src/util.h
new file mode 100644
index 000000000..357c7e06b
--- /dev/null
+++ b/crypto/secp256k1/secp256k1/src/util.h
@@ -0,0 +1,19 @@
+// Copyright (c) 2013 Pieter Wuille
+// Distributed under the MIT/X11 software license, see the accompanying
+// file COPYING or http://www.opensource.org/licenses/mit-license.php.
+
+#ifndef _SECP256K1_UTIL_H_
+#define _SECP256K1_UTIL_H_
+
+/** Generate a pseudorandom 32-bit number. */
+static uint32_t secp256k1_rand32(void);
+
+/** Generate a pseudorandom 32-byte array. */
+static void secp256k1_rand256(unsigned char *b32);
+
+/** Generate a pseudorandom 32-byte array with long sequences of zero and one bits. */
+static void secp256k1_rand256_test(unsigned char *b32);
+
+#include "impl/util.h"
+
+#endif
diff --git a/crypto/sha3/keccakf.go b/crypto/sha3/keccakf.go
new file mode 100644
index 000000000..3baf13ba3
--- /dev/null
+++ b/crypto/sha3/keccakf.go
@@ -0,0 +1,171 @@
+// Copyright 2013 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+package sha3
+
+// This file implements the core Keccak permutation function necessary for computing SHA3.
+// This is implemented in a separate file to allow for replacement by an optimized implementation.
+// Nothing in this package is exported.
+// For the detailed specification, refer to the Keccak web site (http://keccak.noekeon.org/).
+
+// rc stores the round constants for use in the ι step.
+var rc = [...]uint64{
+ 0x0000000000000001,
+ 0x0000000000008082,
+ 0x800000000000808A,
+ 0x8000000080008000,
+ 0x000000000000808B,
+ 0x0000000080000001,
+ 0x8000000080008081,
+ 0x8000000000008009,
+ 0x000000000000008A,
+ 0x0000000000000088,
+ 0x0000000080008009,
+ 0x000000008000000A,
+ 0x000000008000808B,
+ 0x800000000000008B,
+ 0x8000000000008089,
+ 0x8000000000008003,
+ 0x8000000000008002,
+ 0x8000000000000080,
+ 0x000000000000800A,
+ 0x800000008000000A,
+ 0x8000000080008081,
+ 0x8000000000008080,
+ 0x0000000080000001,
+ 0x8000000080008008,
+}
+
+// ro_xx represent the rotation offsets for use in the χ step.
+// Defining them as const instead of in an array allows the compiler to insert constant shifts.
+const (
+ ro_00 = 0
+ ro_01 = 36
+ ro_02 = 3
+ ro_03 = 41
+ ro_04 = 18
+ ro_05 = 1
+ ro_06 = 44
+ ro_07 = 10
+ ro_08 = 45
+ ro_09 = 2
+ ro_10 = 62
+ ro_11 = 6
+ ro_12 = 43
+ ro_13 = 15
+ ro_14 = 61
+ ro_15 = 28
+ ro_16 = 55
+ ro_17 = 25
+ ro_18 = 21
+ ro_19 = 56
+ ro_20 = 27
+ ro_21 = 20
+ ro_22 = 39
+ ro_23 = 8
+ ro_24 = 14
+)
+
+// keccakF computes the complete Keccak-f function consisting of 24 rounds with a different
+// constant (rc) in each round. This implementation fully unrolls the round function to avoid
+// inner loops, as well as pre-calculating shift offsets.
+func (d *digest) keccakF() {
+ for _, roundConstant := range rc {
+ // θ step
+ d.c[0] = d.a[0] ^ d.a[5] ^ d.a[10] ^ d.a[15] ^ d.a[20]
+ d.c[1] = d.a[1] ^ d.a[6] ^ d.a[11] ^ d.a[16] ^ d.a[21]
+ d.c[2] = d.a[2] ^ d.a[7] ^ d.a[12] ^ d.a[17] ^ d.a[22]
+ d.c[3] = d.a[3] ^ d.a[8] ^ d.a[13] ^ d.a[18] ^ d.a[23]
+ d.c[4] = d.a[4] ^ d.a[9] ^ d.a[14] ^ d.a[19] ^ d.a[24]
+
+ d.d[0] = d.c[4] ^ (d.c[1]<<1 ^ d.c[1]>>63)
+ d.d[1] = d.c[0] ^ (d.c[2]<<1 ^ d.c[2]>>63)
+ d.d[2] = d.c[1] ^ (d.c[3]<<1 ^ d.c[3]>>63)
+ d.d[3] = d.c[2] ^ (d.c[4]<<1 ^ d.c[4]>>63)
+ d.d[4] = d.c[3] ^ (d.c[0]<<1 ^ d.c[0]>>63)
+
+ d.a[0] ^= d.d[0]
+ d.a[1] ^= d.d[1]
+ d.a[2] ^= d.d[2]
+ d.a[3] ^= d.d[3]
+ d.a[4] ^= d.d[4]
+ d.a[5] ^= d.d[0]
+ d.a[6] ^= d.d[1]
+ d.a[7] ^= d.d[2]
+ d.a[8] ^= d.d[3]
+ d.a[9] ^= d.d[4]
+ d.a[10] ^= d.d[0]
+ d.a[11] ^= d.d[1]
+ d.a[12] ^= d.d[2]
+ d.a[13] ^= d.d[3]
+ d.a[14] ^= d.d[4]
+ d.a[15] ^= d.d[0]
+ d.a[16] ^= d.d[1]
+ d.a[17] ^= d.d[2]
+ d.a[18] ^= d.d[3]
+ d.a[19] ^= d.d[4]
+ d.a[20] ^= d.d[0]
+ d.a[21] ^= d.d[1]
+ d.a[22] ^= d.d[2]
+ d.a[23] ^= d.d[3]
+ d.a[24] ^= d.d[4]
+
+ // ρ and π steps
+ d.b[0] = d.a[0]
+ d.b[1] = d.a[6]<<ro_06 ^ d.a[6]>>(64-ro_06)
+ d.b[2] = d.a[12]<<ro_12 ^ d.a[12]>>(64-ro_12)
+ d.b[3] = d.a[18]<<ro_18 ^ d.a[18]>>(64-ro_18)
+ d.b[4] = d.a[24]<<ro_24 ^ d.a[24]>>(64-ro_24)
+ d.b[5] = d.a[3]<<ro_15 ^ d.a[3]>>(64-ro_15)
+ d.b[6] = d.a[9]<<ro_21 ^ d.a[9]>>(64-ro_21)
+ d.b[7] = d.a[10]<<ro_02 ^ d.a[10]>>(64-ro_02)
+ d.b[8] = d.a[16]<<ro_08 ^ d.a[16]>>(64-ro_08)
+ d.b[9] = d.a[22]<<ro_14 ^ d.a[22]>>(64-ro_14)
+ d.b[10] = d.a[1]<<ro_05 ^ d.a[1]>>(64-ro_05)
+ d.b[11] = d.a[7]<<ro_11 ^ d.a[7]>>(64-ro_11)
+ d.b[12] = d.a[13]<<ro_17 ^ d.a[13]>>(64-ro_17)
+ d.b[13] = d.a[19]<<ro_23 ^ d.a[19]>>(64-ro_23)
+ d.b[14] = d.a[20]<<ro_04 ^ d.a[20]>>(64-ro_04)
+ d.b[15] = d.a[4]<<ro_20 ^ d.a[4]>>(64-ro_20)
+ d.b[16] = d.a[5]<<ro_01 ^ d.a[5]>>(64-ro_01)
+ d.b[17] = d.a[11]<<ro_07 ^ d.a[11]>>(64-ro_07)
+ d.b[18] = d.a[17]<<ro_13 ^ d.a[17]>>(64-ro_13)
+ d.b[19] = d.a[23]<<ro_19 ^ d.a[23]>>(64-ro_19)
+ d.b[20] = d.a[2]<<ro_10 ^ d.a[2]>>(64-ro_10)
+ d.b[21] = d.a[8]<<ro_16 ^ d.a[8]>>(64-ro_16)
+ d.b[22] = d.a[14]<<ro_22 ^ d.a[14]>>(64-ro_22)
+ d.b[23] = d.a[15]<<ro_03 ^ d.a[15]>>(64-ro_03)
+ d.b[24] = d.a[21]<<ro_09 ^ d.a[21]>>(64-ro_09)
+
+ // χ step
+ d.a[0] = d.b[0] ^ (^d.b[1] & d.b[2])
+ d.a[1] = d.b[1] ^ (^d.b[2] & d.b[3])
+ d.a[2] = d.b[2] ^ (^d.b[3] & d.b[4])
+ d.a[3] = d.b[3] ^ (^d.b[4] & d.b[0])
+ d.a[4] = d.b[4] ^ (^d.b[0] & d.b[1])
+ d.a[5] = d.b[5] ^ (^d.b[6] & d.b[7])
+ d.a[6] = d.b[6] ^ (^d.b[7] & d.b[8])
+ d.a[7] = d.b[7] ^ (^d.b[8] & d.b[9])
+ d.a[8] = d.b[8] ^ (^d.b[9] & d.b[5])
+ d.a[9] = d.b[9] ^ (^d.b[5] & d.b[6])
+ d.a[10] = d.b[10] ^ (^d.b[11] & d.b[12])
+ d.a[11] = d.b[11] ^ (^d.b[12] & d.b[13])
+ d.a[12] = d.b[12] ^ (^d.b[13] & d.b[14])
+ d.a[13] = d.b[13] ^ (^d.b[14] & d.b[10])
+ d.a[14] = d.b[14] ^ (^d.b[10] & d.b[11])
+ d.a[15] = d.b[15] ^ (^d.b[16] & d.b[17])
+ d.a[16] = d.b[16] ^ (^d.b[17] & d.b[18])
+ d.a[17] = d.b[17] ^ (^d.b[18] & d.b[19])
+ d.a[18] = d.b[18] ^ (^d.b[19] & d.b[15])
+ d.a[19] = d.b[19] ^ (^d.b[15] & d.b[16])
+ d.a[20] = d.b[20] ^ (^d.b[21] & d.b[22])
+ d.a[21] = d.b[21] ^ (^d.b[22] & d.b[23])
+ d.a[22] = d.b[22] ^ (^d.b[23] & d.b[24])
+ d.a[23] = d.b[23] ^ (^d.b[24] & d.b[20])
+ d.a[24] = d.b[24] ^ (^d.b[20] & d.b[21])
+
+ // ι step
+ d.a[0] ^= roundConstant
+ }
+}
diff --git a/crypto/sha3/sha3.go b/crypto/sha3/sha3.go
new file mode 100644
index 000000000..22df0ef11
--- /dev/null
+++ b/crypto/sha3/sha3.go
@@ -0,0 +1,216 @@
+// Copyright 2013 The Go Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style
+// license that can be found in the LICENSE file.
+
+// Package sha3 implements the SHA3 hash algorithm (formerly called Keccak) chosen by NIST in 2012.
+// This file provides a SHA3 implementation which implements the standard hash.Hash interface.
+// Writing input data, including padding, and reading output data are computed in this file.
+// Note that the current implementation can compute the hash of an integral number of bytes only.
+// This is a consequence of the hash interface in which a buffer of bytes is passed in.
+// The internals of the Keccak-f function are computed in keccakf.go.
+// For the detailed specification, refer to the Keccak web site (http://keccak.noekeon.org/).
+package sha3
+
+import (
+ "encoding/binary"
+ "hash"
+)
+
+// laneSize is the size in bytes of each "lane" of the internal state of SHA3 (5 * 5 * 8).
+// Note that changing this size would requires using a type other than uint64 to store each lane.
+const laneSize = 8
+
+// sliceSize represents the dimensions of the internal state, a square matrix of
+// sliceSize ** 2 lanes. This is the size of both the "rows" and "columns" dimensions in the
+// terminology of the SHA3 specification.
+const sliceSize = 5
+
+// numLanes represents the total number of lanes in the state.
+const numLanes = sliceSize * sliceSize
+
+// stateSize is the size in bytes of the internal state of SHA3 (5 * 5 * WSize).
+const stateSize = laneSize * numLanes
+
+// digest represents the partial evaluation of a checksum.
+// Note that capacity, and not outputSize, is the critical security parameter, as SHA3 can output
+// an arbitrary number of bytes for any given capacity. The Keccak proposal recommends that
+// capacity = 2*outputSize to ensure that finding a collision of size outputSize requires
+// O(2^{outputSize/2}) computations (the birthday lower bound). Future standards may modify the
+// capacity/outputSize ratio to allow for more output with lower cryptographic security.
+type digest struct {
+ a [numLanes]uint64 // main state of the hash
+ b [numLanes]uint64 // intermediate states
+ c [sliceSize]uint64 // intermediate states
+ d [sliceSize]uint64 // intermediate states
+ outputSize int // desired output size in bytes
+ capacity int // number of bytes to leave untouched during squeeze/absorb
+ absorbed int // number of bytes absorbed thus far
+}
+
+// minInt returns the lesser of two integer arguments, to simplify the absorption routine.
+func minInt(v1, v2 int) int {
+ if v1 <= v2 {
+ return v1
+ }
+ return v2
+}
+
+// rate returns the number of bytes of the internal state which can be absorbed or squeezed
+// in between calls to the permutation function.
+func (d *digest) rate() int {
+ return stateSize - d.capacity
+}
+
+// Reset clears the internal state by zeroing bytes in the state buffer.
+// This can be skipped for a newly-created hash state; the default zero-allocated state is correct.
+func (d *digest) Reset() {
+ d.absorbed = 0
+ for i := range d.a {
+ d.a[i] = 0
+ }
+}
+
+// BlockSize, required by the hash.Hash interface, does not have a standard intepretation
+// for a sponge-based construction like SHA3. We return the data rate: the number of bytes which
+// can be absorbed per invocation of the permutation function. For Merkle-Damgård based hashes
+// (ie SHA1, SHA2, MD5) the output size of the internal compression function is returned.
+// We consider this to be roughly equivalent because it represents the number of bytes of output
+// produced per cryptographic operation.
+func (d *digest) BlockSize() int { return d.rate() }
+
+// Size returns the output size of the hash function in bytes.
+func (d *digest) Size() int {
+ return d.outputSize
+}
+
+// unalignedAbsorb is a helper function for Write, which absorbs data that isn't aligned with an
+// 8-byte lane. This requires shifting the individual bytes into position in a uint64.
+func (d *digest) unalignedAbsorb(p []byte) {
+ var t uint64
+ for i := len(p) - 1; i >= 0; i-- {
+ t <<= 8
+ t |= uint64(p[i])
+ }
+ offset := (d.absorbed) % d.rate()
+ t <<= 8 * uint(offset%laneSize)
+ d.a[offset/laneSize] ^= t
+ d.absorbed += len(p)
+}
+
+// Write "absorbs" bytes into the state of the SHA3 hash, updating as needed when the sponge
+// "fills up" with rate() bytes. Since lanes are stored internally as type uint64, this requires
+// converting the incoming bytes into uint64s using a little endian interpretation. This
+// implementation is optimized for large, aligned writes of multiples of 8 bytes (laneSize).
+// Non-aligned or uneven numbers of bytes require shifting and are slower.
+func (d *digest) Write(p []byte) (int, error) {
+ // An initial offset is needed if the we aren't absorbing to the first lane initially.
+ offset := d.absorbed % d.rate()
+ toWrite := len(p)
+
+ // The first lane may need to absorb unaligned and/or incomplete data.
+ if (offset%laneSize != 0 || len(p) < 8) && len(p) > 0 {
+ toAbsorb := minInt(laneSize-(offset%laneSize), len(p))
+ d.unalignedAbsorb(p[:toAbsorb])
+ p = p[toAbsorb:]
+ offset = (d.absorbed) % d.rate()
+
+ // For every rate() bytes absorbed, the state must be permuted via the F Function.
+ if (d.absorbed)%d.rate() == 0 {
+ d.keccakF()
+ }
+ }
+
+ // This loop should absorb the bulk of the data into full, aligned lanes.
+ // It will call the update function as necessary.
+ for len(p) > 7 {
+ firstLane := offset / laneSize
+ lastLane := minInt(d.rate()/laneSize, firstLane+len(p)/laneSize)
+
+ // This inner loop absorbs input bytes into the state in groups of 8, converted to uint64s.
+ for lane := firstLane; lane < lastLane; lane++ {
+ d.a[lane] ^= binary.LittleEndian.Uint64(p[:laneSize])
+ p = p[laneSize:]
+ }
+ d.absorbed += (lastLane - firstLane) * laneSize
+ // For every rate() bytes absorbed, the state must be permuted via the F Function.
+ if (d.absorbed)%d.rate() == 0 {
+ d.keccakF()
+ }
+
+ offset = 0
+ }
+
+ // If there are insufficient bytes to fill the final lane, an unaligned absorption.
+ // This should always start at a correct lane boundary though, or else it would be caught
+ // by the uneven opening lane case above.
+ if len(p) > 0 {
+ d.unalignedAbsorb(p)
+ }
+
+ return toWrite, nil
+}
+
+// pad computes the SHA3 padding scheme based on the number of bytes absorbed.
+// The padding is a 1 bit, followed by an arbitrary number of 0s and then a final 1 bit, such that
+// the input bits plus padding bits are a multiple of rate(). Adding the padding simply requires
+// xoring an opening and closing bit into the appropriate lanes.
+func (d *digest) pad() {
+ offset := d.absorbed % d.rate()
+ // The opening pad bit must be shifted into position based on the number of bytes absorbed
+ padOpenLane := offset / laneSize
+ d.a[padOpenLane] ^= 0x0000000000000001 << uint(8*(offset%laneSize))
+ // The closing padding bit is always in the last position
+ padCloseLane := (d.rate() / laneSize) - 1
+ d.a[padCloseLane] ^= 0x8000000000000000
+}
+
+// finalize prepares the hash to output data by padding and one final permutation of the state.
+func (d *digest) finalize() {
+ d.pad()
+ d.keccakF()
+}
+
+// squeeze outputs an arbitrary number of bytes from the hash state.
+// Squeezing can require multiple calls to the F function (one per rate() bytes squeezed),
+// although this is not the case for standard SHA3 parameters. This implementation only supports
+// squeezing a single time, subsequent squeezes may lose alignment. Future implementations
+// may wish to support multiple squeeze calls, for example to support use as a PRNG.
+func (d *digest) squeeze(in []byte, toSqueeze int) []byte {
+ // Because we read in blocks of laneSize, we need enough room to read
+ // an integral number of lanes
+ needed := toSqueeze + (laneSize-toSqueeze%laneSize)%laneSize
+ if cap(in)-len(in) < needed {
+ newIn := make([]byte, len(in), len(in)+needed)
+ copy(newIn, in)
+ in = newIn
+ }
+ out := in[len(in) : len(in)+needed]
+
+ for len(out) > 0 {
+ for i := 0; i < d.rate() && len(out) > 0; i += laneSize {
+ binary.LittleEndian.PutUint64(out[:], d.a[i/laneSize])
+ out = out[laneSize:]
+ }
+ if len(out) > 0 {
+ d.keccakF()
+ }
+ }
+ return in[:len(in)+toSqueeze] // Re-slice in case we wrote extra data.
+}
+
+// Sum applies padding to the hash state and then squeezes out the desired nubmer of output bytes.
+func (d *digest) Sum(in []byte) []byte {
+ // Make a copy of the original hash so that caller can keep writing and summing.
+ dup := *d
+ dup.finalize()
+ return dup.squeeze(in, dup.outputSize)
+}
+
+// The NewKeccakX constructors enable initializing a hash in any of the four recommend sizes
+// from the Keccak specification, all of which set capacity=2*outputSize. Note that the final
+// NIST standard for SHA3 may specify different input/output lengths.
+// The output size is indicated in bits but converted into bytes internally.
+func NewKeccak224() hash.Hash { return &digest{outputSize: 224 / 8, capacity: 2 * 224 / 8} }
+func NewKeccak256() hash.Hash { return &digest{outputSize: 256 / 8, capacity: 2 * 256 / 8} }
+func NewKeccak384() hash.Hash { return &digest{outputSize: 384 / 8, capacity: 2 * 384 / 8} }
+func NewKeccak512() hash.Hash { return &digest{outputSize: 512 / 8, capacity: 2 * 512 / 8} }
diff --git a/errs/errors.go b/errs/errors.go
new file mode 100644
index 000000000..f1b0ebdbb
--- /dev/null
+++ b/errs/errors.go
@@ -0,0 +1,91 @@
+package errs
+
+import (
+ "fmt"
+
+ "github.com/ethereum/go-ethereum/logger"
+)
+
+/*
+Errors implements an error handler providing standardised errors for a package.
+Fields:
+
+ Errors:
+ a map from error codes to description
+
+ Package:
+ name of the package/component
+
+ Level:
+ a function mapping error code to logger.LogLevel (severity)
+ if not given, errors default to logger.InfoLevel
+*/
+type Errors struct {
+ Errors map[int]string
+ Package string
+ Level func(code int) logger.LogLevel
+}
+
+/*
+Error implements the standard go error interface.
+
+ errors.New(code, format, params ...interface{})
+
+Prints as:
+
+ [package] description: details
+
+where details is fmt.Sprintf(self.format, self.params...)
+*/
+type Error struct {
+ Code int
+ Name string
+ Package string
+ level logger.LogLevel
+ message string
+ format string
+ params []interface{}
+}
+
+func (self *Errors) New(code int, format string, params ...interface{}) *Error {
+ name, ok := self.Errors[code]
+ if !ok {
+ panic("invalid error code")
+ }
+ level := logger.InfoLevel
+ if self.Level != nil {
+ level = self.Level(code)
+ }
+ return &Error{
+ Code: code,
+ Name: name,
+ Package: self.Package,
+ level: level,
+ format: format,
+ params: params,
+ }
+}
+
+func (self Error) Error() (message string) {
+ if len(message) == 0 {
+ self.message = fmt.Sprintf("[%s] %s", self.Package, self.Name)
+ if self.format != "" {
+ self.message += ": " + fmt.Sprintf(self.format, self.params...)
+ }
+ }
+ return self.message
+}
+
+func (self Error) Log(log *logger.Logger) {
+ log.Sendln(self.level, self)
+}
+
+/*
+err.Fatal() is true if err's severity level is 0 or 1 (logger.ErrorLevel or logger.Silence)
+*/
+func (self *Error) Fatal() (fatal bool) {
+ if self.level < logger.WarnLevel {
+ fatal = true
+ }
+ return
+}
diff --git a/errs/errors_test.go b/errs/errors_test.go
new file mode 100644
index 000000000..09f70eef5
--- /dev/null
+++ b/errs/errors_test.go
@@ -0,0 +1,46 @@
+package errs
+
+import (
+ "fmt"
+ "testing"
+
+ "github.com/ethereum/go-ethereum/logger"
+)
+
+func testErrors() *Errors {
+ return &Errors{
+ Package: "TEST",
+ Errors: map[int]string{
+ 0: "zero",
+ 1: "one",
+ },
+ Level: func(i int) (l logger.LogLevel) {
+ if i == 0 {
+ l = logger.ErrorLevel
+ } else {
+ l = logger.WarnLevel
+ }
+ return
+ },
+ }
+}
+
+func TestErrorMessage(t *testing.T) {
+ err := testErrors().New(0, "zero detail %v", "available")
+ message := fmt.Sprintf("%v", err)
+ exp := "[TEST] zero: zero detail available"
+ if message != exp {
+ t.Errorf("error message incorrect. expected %v, got %v", exp, message)
+ }
+}
+
+func TestErrorSeverity(t *testing.T) {
+ err0 := testErrors().New(0, "zero detail")
+ if !err0.Fatal() {
+ t.Errorf("error should be fatal")
+ }
+ err1 := testErrors().New(1, "one detail")
+ if err1.Fatal() {
+ t.Errorf("error should not be fatal")
+ }
+}
diff --git a/eth/backend.go b/eth/backend.go
new file mode 100644
index 000000000..cc4f807bf
--- /dev/null
+++ b/eth/backend.go
@@ -0,0 +1,459 @@
+package eth
+
+import (
+ "crypto/ecdsa"
+ "fmt"
+ "io/ioutil"
+ "path"
+ "strings"
+
+ "github.com/ethereum/ethash"
+ "github.com/ethereum/go-ethereum/accounts"
+ "github.com/ethereum/go-ethereum/blockpool"
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/core"
+ "github.com/ethereum/go-ethereum/core/types"
+ "github.com/ethereum/go-ethereum/core/vm"
+ "github.com/ethereum/go-ethereum/crypto"
+ "github.com/ethereum/go-ethereum/ethdb"
+ "github.com/ethereum/go-ethereum/event"
+ "github.com/ethereum/go-ethereum/logger"
+ "github.com/ethereum/go-ethereum/miner"
+ "github.com/ethereum/go-ethereum/p2p"
+ "github.com/ethereum/go-ethereum/p2p/discover"
+ "github.com/ethereum/go-ethereum/p2p/nat"
+ "github.com/ethereum/go-ethereum/whisper"
+)
+
+var (
+ servlogger = logger.NewLogger("SERV")
+ jsonlogger = logger.NewJsonLogger()
+
+ defaultBootNodes = []*discover.Node{
+ // ETH/DEV cmd/bootnode
+ discover.MustParseNode("enode://09fbeec0d047e9a37e63f60f8618aa9df0e49271f3fadb2c070dc09e2099b95827b63a8b837c6fd01d0802d457dd83e3bd48bd3e6509f8209ed90dabbc30e3d3@52.16.188.185:30303"),
+ // ETH/DEV cpp-ethereum (poc-9.ethdev.com)
+ discover.MustParseNode("enode://487611428e6c99a11a9795a6abe7b529e81315ca6aad66e2a2fc76e3adf263faba0d35466c2f8f68d561dbefa8878d4df5f1f2ddb1fbeab7f42ffb8cd328bd4a@5.1.83.226:30303"),
+ }
+)
+
+type Config struct {
+ Name string
+ ProtocolVersion int
+ NetworkId int
+
+ DataDir string
+ LogFile string
+ LogLevel int
+ LogJSON string
+ VmDebug bool
+
+ MaxPeers int
+ Port string
+
+ // This should be a space-separated list of
+ // discovery node URLs.
+ BootNodes string
+
+ // This key is used to identify the node on the network.
+ // If nil, an ephemeral key is used.
+ NodeKey *ecdsa.PrivateKey
+
+ NAT nat.Interface
+ Shh bool
+ Dial bool
+
+ Etherbase string
+ MinerThreads int
+ AccountManager *accounts.Manager
+
+ // NewDB is used to create databases.
+ // If nil, the default is to create leveldb databases on disk.
+ NewDB func(path string) (common.Database, error)
+}
+
+func (cfg *Config) parseBootNodes() []*discover.Node {
+ if cfg.BootNodes == "" {
+ return defaultBootNodes
+ }
+ var ns []*discover.Node
+ for _, url := range strings.Split(cfg.BootNodes, " ") {
+ if url == "" {
+ continue
+ }
+ n, err := discover.ParseNode(url)
+ if err != nil {
+ servlogger.Errorf("Bootstrap URL %s: %v\n", url, err)
+ continue
+ }
+ ns = append(ns, n)
+ }
+ return ns
+}
+
+func (cfg *Config) nodeKey() (*ecdsa.PrivateKey, error) {
+ // use explicit key from command line args if set
+ if cfg.NodeKey != nil {
+ return cfg.NodeKey, nil
+ }
+ // use persistent key if present
+ keyfile := path.Join(cfg.DataDir, "nodekey")
+ key, err := crypto.LoadECDSA(keyfile)
+ if err == nil {
+ return key, nil
+ }
+ // no persistent key, generate and store a new one
+ if key, err = crypto.GenerateKey(); err != nil {
+ return nil, fmt.Errorf("could not generate server key: %v", err)
+ }
+ if err := ioutil.WriteFile(keyfile, crypto.FromECDSA(key), 0600); err != nil {
+ servlogger.Errorln("could not persist nodekey: ", err)
+ }
+ return key, nil
+}
+
+type Ethereum struct {
+ // Channel for shutting down the ethereum
+ shutdownChan chan bool
+
+ // DB interfaces
+ blockDb common.Database // Block chain database
+ stateDb common.Database // State changes database
+ extraDb common.Database // Extra database (txs, etc)
+
+ //*** SERVICES ***
+ // State manager for processing new blocks and managing the over all states
+ blockProcessor *core.BlockProcessor
+ txPool *core.TxPool
+ chainManager *core.ChainManager
+ blockPool *blockpool.BlockPool
+ accountManager *accounts.Manager
+ whisper *whisper.Whisper
+ pow *ethash.Ethash
+
+ net *p2p.Server
+ eventMux *event.TypeMux
+ txSub event.Subscription
+ blockSub event.Subscription
+ miner *miner.Miner
+
+ // logger logger.LogSystem
+
+ Mining bool
+ DataDir string
+ etherbase common.Address
+ clientVersion string
+ ethVersionId int
+ netVersionId int
+ shhVersionId int
+}
+
+func New(config *Config) (*Ethereum, error) {
+ // Boostrap database
+ logger.New(config.DataDir, config.LogFile, config.LogLevel)
+ if len(config.LogJSON) > 0 {
+ logger.NewJSONsystem(config.DataDir, config.LogJSON)
+ }
+
+ newdb := config.NewDB
+ if newdb == nil {
+ newdb = func(path string) (common.Database, error) { return ethdb.NewLDBDatabase(path) }
+ }
+ blockDb, err := newdb(path.Join(config.DataDir, "blockchain"))
+ if err != nil {
+ return nil, err
+ }
+ stateDb, err := newdb(path.Join(config.DataDir, "state"))
+ if err != nil {
+ return nil, err
+ }
+ extraDb, err := ethdb.NewLDBDatabase(path.Join(config.DataDir, "extra"))
+
+ // Perform database sanity checks
+ d, _ := blockDb.Get([]byte("ProtocolVersion"))
+ protov := int(common.NewValue(d).Uint())
+ if protov != config.ProtocolVersion && protov != 0 {
+ path := path.Join(config.DataDir, "blockchain")
+ return nil, fmt.Errorf("Database version mismatch. Protocol(%d / %d). `rm -rf %s`", protov, config.ProtocolVersion, path)
+ }
+ saveProtocolVersion(blockDb, config.ProtocolVersion)
+ servlogger.Infof("Protocol Version: %v, Network Id: %v", config.ProtocolVersion, config.NetworkId)
+
+ eth := &Ethereum{
+ shutdownChan: make(chan bool),
+ blockDb: blockDb,
+ stateDb: stateDb,
+ extraDb: extraDb,
+ eventMux: &event.TypeMux{},
+ accountManager: config.AccountManager,
+ DataDir: config.DataDir,
+ etherbase: common.HexToAddress(config.Etherbase),
+ clientVersion: config.Name, // TODO should separate from Name
+ ethVersionId: config.ProtocolVersion,
+ netVersionId: config.NetworkId,
+ }
+
+ eth.chainManager = core.NewChainManager(blockDb, stateDb, eth.EventMux())
+ eth.pow = ethash.New(eth.chainManager)
+ eth.txPool = core.NewTxPool(eth.EventMux())
+ eth.blockProcessor = core.NewBlockProcessor(stateDb, extraDb, eth.pow, eth.txPool, eth.chainManager, eth.EventMux())
+ eth.chainManager.SetProcessor(eth.blockProcessor)
+ eth.whisper = whisper.New()
+ eth.shhVersionId = int(eth.whisper.Version())
+ eth.miner = miner.New(eth, eth.pow, config.MinerThreads)
+
+ hasBlock := eth.chainManager.HasBlock
+ insertChain := eth.chainManager.InsertChain
+ td := eth.chainManager.Td()
+ eth.blockPool = blockpool.New(hasBlock, insertChain, eth.pow.Verify, eth.EventMux(), td)
+
+ netprv, err := config.nodeKey()
+ if err != nil {
+ return nil, err
+ }
+
+ ethProto := EthProtocol(config.ProtocolVersion, config.NetworkId, eth.txPool, eth.chainManager, eth.blockPool)
+ protocols := []p2p.Protocol{ethProto}
+ if config.Shh {
+ protocols = append(protocols, eth.whisper.Protocol())
+ }
+
+ eth.net = &p2p.Server{
+ PrivateKey: netprv,
+ Name: config.Name,
+ MaxPeers: config.MaxPeers,
+ Protocols: protocols,
+ NAT: config.NAT,
+ NoDial: !config.Dial,
+ BootstrapNodes: config.parseBootNodes(),
+ }
+ if len(config.Port) > 0 {
+ eth.net.ListenAddr = ":" + config.Port
+ }
+
+ vm.Debug = config.VmDebug
+
+ return eth, nil
+}
+
+type NodeInfo struct {
+ Name string
+ NodeUrl string
+ NodeID string
+ IP string
+ DiscPort int // UDP listening port for discovery protocol
+ TCPPort int // TCP listening port for RLPx
+ Td string
+ ListenAddr string
+}
+
+func (s *Ethereum) NodeInfo() *NodeInfo {
+ node := s.net.Self()
+
+ return &NodeInfo{
+ Name: s.Name(),
+ NodeUrl: node.String(),
+ NodeID: node.ID.String(),
+ IP: node.IP.String(),
+ DiscPort: node.DiscPort,
+ TCPPort: node.TCPPort,
+ ListenAddr: s.net.ListenAddr,
+ Td: s.ChainManager().Td().String(),
+ }
+}
+
+type PeerInfo struct {
+ ID string
+ Name string
+ Caps string
+ RemoteAddress string
+ LocalAddress string
+}
+
+func newPeerInfo(peer *p2p.Peer) *PeerInfo {
+ var caps []string
+ for _, cap := range peer.Caps() {
+ caps = append(caps, cap.String())
+ }
+ return &PeerInfo{
+ ID: peer.ID().String(),
+ Name: peer.Name(),
+ Caps: strings.Join(caps, ", "),
+ RemoteAddress: peer.RemoteAddr().String(),
+ LocalAddress: peer.LocalAddr().String(),
+ }
+}
+
+// PeersInfo returns an array of PeerInfo objects describing connected peers
+func (s *Ethereum) PeersInfo() (peersinfo []*PeerInfo) {
+ for _, peer := range s.net.Peers() {
+ if peer != nil {
+ peersinfo = append(peersinfo, newPeerInfo(peer))
+ }
+ }
+ return
+}
+
+func (s *Ethereum) ResetWithGenesisBlock(gb *types.Block) {
+ s.chainManager.ResetWithGenesisBlock(gb)
+ s.pow.UpdateCache(true)
+}
+
+func (s *Ethereum) StartMining() error {
+ eb, err := s.Etherbase()
+ if err != nil {
+ err = fmt.Errorf("Cannot start mining without etherbase address: %v", err)
+ servlogger.Errorln(err)
+ return err
+
+ }
+
+ s.miner.Start(eb)
+ return nil
+}
+
+func (s *Ethereum) Etherbase() (eb common.Address, err error) {
+ eb = s.etherbase
+ if (eb == common.Address{}) {
+ var ebbytes []byte
+ ebbytes, err = s.accountManager.Primary()
+ eb = common.BytesToAddress(ebbytes)
+ if (eb == common.Address{}) {
+ err = fmt.Errorf("no accounts found")
+ }
+ }
+ return
+}
+
+func (s *Ethereum) StopMining() { s.miner.Stop() }
+func (s *Ethereum) IsMining() bool { return s.miner.Mining() }
+func (s *Ethereum) Miner() *miner.Miner { return s.miner }
+
+// func (s *Ethereum) Logger() logger.LogSystem { return s.logger }
+func (s *Ethereum) Name() string { return s.net.Name }
+func (s *Ethereum) AccountManager() *accounts.Manager { return s.accountManager }
+func (s *Ethereum) ChainManager() *core.ChainManager { return s.chainManager }
+func (s *Ethereum) BlockProcessor() *core.BlockProcessor { return s.blockProcessor }
+func (s *Ethereum) TxPool() *core.TxPool { return s.txPool }
+func (s *Ethereum) BlockPool() *blockpool.BlockPool { return s.blockPool }
+func (s *Ethereum) Whisper() *whisper.Whisper { return s.whisper }
+func (s *Ethereum) EventMux() *event.TypeMux { return s.eventMux }
+func (s *Ethereum) BlockDb() common.Database { return s.blockDb }
+func (s *Ethereum) StateDb() common.Database { return s.stateDb }
+func (s *Ethereum) ExtraDb() common.Database { return s.extraDb }
+func (s *Ethereum) IsListening() bool { return true } // Always listening
+func (s *Ethereum) PeerCount() int { return s.net.PeerCount() }
+func (s *Ethereum) Peers() []*p2p.Peer { return s.net.Peers() }
+func (s *Ethereum) MaxPeers() int { return s.net.MaxPeers }
+func (s *Ethereum) ClientVersion() string { return s.clientVersion }
+func (s *Ethereum) EthVersion() int { return s.ethVersionId }
+func (s *Ethereum) NetVersion() int { return s.netVersionId }
+func (s *Ethereum) ShhVersion() int { return s.shhVersionId }
+
+// Start the ethereum
+func (s *Ethereum) Start() error {
+ jsonlogger.LogJson(&logger.LogStarting{
+ ClientString: s.net.Name,
+ ProtocolVersion: ProtocolVersion,
+ })
+
+ if s.net.MaxPeers > 0 {
+ err := s.net.Start()
+ if err != nil {
+ return err
+ }
+ }
+
+ // Start services
+ s.txPool.Start()
+ s.blockPool.Start()
+
+ if s.whisper != nil {
+ s.whisper.Start()
+ }
+
+ // broadcast transactions
+ s.txSub = s.eventMux.Subscribe(core.TxPreEvent{})
+ go s.txBroadcastLoop()
+
+ // broadcast mined blocks
+ s.blockSub = s.eventMux.Subscribe(core.ChainHeadEvent{})
+ go s.blockBroadcastLoop()
+
+ servlogger.Infoln("Server started")
+ return nil
+}
+
+func (s *Ethereum) StartForTest() {
+ jsonlogger.LogJson(&logger.LogStarting{
+ ClientString: s.net.Name,
+ ProtocolVersion: ProtocolVersion,
+ })
+
+ // Start services
+ s.txPool.Start()
+ s.blockPool.Start()
+}
+
+func (self *Ethereum) SuggestPeer(nodeURL string) error {
+ n, err := discover.ParseNode(nodeURL)
+ if err != nil {
+ return fmt.Errorf("invalid node URL: %v", err)
+ }
+ self.net.SuggestPeer(n)
+ return nil
+}
+
+func (s *Ethereum) Stop() {
+ // Close the database
+ defer s.blockDb.Close()
+ defer s.stateDb.Close()
+ defer s.extraDb.Close()
+
+ s.txSub.Unsubscribe() // quits txBroadcastLoop
+ s.blockSub.Unsubscribe() // quits blockBroadcastLoop
+
+ s.txPool.Stop()
+ s.eventMux.Stop()
+ s.blockPool.Stop()
+ if s.whisper != nil {
+ s.whisper.Stop()
+ }
+
+ servlogger.Infoln("Server stopped")
+ close(s.shutdownChan)
+}
+
+// This function will wait for a shutdown and resumes main thread execution
+func (s *Ethereum) WaitForShutdown() {
+ <-s.shutdownChan
+}
+
+// now tx broadcasting is taken out of txPool
+// handled here via subscription, efficiency?
+func (self *Ethereum) txBroadcastLoop() {
+ // automatically stops if unsubscribe
+ for obj := range self.txSub.Chan() {
+ event := obj.(core.TxPreEvent)
+ self.net.Broadcast("eth", TxMsg, []*types.Transaction{event.Tx})
+ }
+}
+
+func (self *Ethereum) blockBroadcastLoop() {
+ // automatically stops if unsubscribe
+ for obj := range self.blockSub.Chan() {
+ switch ev := obj.(type) {
+ case core.ChainHeadEvent:
+ self.net.Broadcast("eth", NewBlockMsg, []interface{}{ev.Block, ev.Block.Td})
+ }
+ }
+}
+
+func saveProtocolVersion(db common.Database, protov int) {
+ d, _ := db.Get([]byte("ProtocolVersion"))
+ protocolVersion := common.NewValue(d).Uint()
+
+ if protocolVersion == 0 {
+ db.Put([]byte("ProtocolVersion"), common.NewValue(protov).Bytes())
+ }
+}
diff --git a/eth/protocol.go b/eth/protocol.go
new file mode 100644
index 000000000..a0ab177cd
--- /dev/null
+++ b/eth/protocol.go
@@ -0,0 +1,389 @@
+package eth
+
+import (
+ "fmt"
+ "math/big"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/core/types"
+ "github.com/ethereum/go-ethereum/errs"
+ "github.com/ethereum/go-ethereum/logger"
+ "github.com/ethereum/go-ethereum/p2p"
+ "github.com/ethereum/go-ethereum/rlp"
+)
+
+const (
+ ProtocolVersion = 60
+ NetworkId = 0
+ ProtocolLength = uint64(8)
+ ProtocolMaxMsgSize = 10 * 1024 * 1024
+ maxHashes = 256
+ maxBlocks = 64
+)
+
+// eth protocol message codes
+const (
+ StatusMsg = iota
+ GetTxMsg // unused
+ TxMsg
+ GetBlockHashesMsg
+ BlockHashesMsg
+ GetBlocksMsg
+ BlocksMsg
+ NewBlockMsg
+)
+
+const (
+ ErrMsgTooLarge = iota
+ ErrDecode
+ ErrInvalidMsgCode
+ ErrProtocolVersionMismatch
+ ErrNetworkIdMismatch
+ ErrGenesisBlockMismatch
+ ErrNoStatusMsg
+ ErrExtraStatusMsg
+ ErrSuspendedPeer
+)
+
+var errorToString = map[int]string{
+ ErrMsgTooLarge: "Message too long",
+ ErrDecode: "Invalid message",
+ ErrInvalidMsgCode: "Invalid message code",
+ ErrProtocolVersionMismatch: "Protocol version mismatch",
+ ErrNetworkIdMismatch: "NetworkId mismatch",
+ ErrGenesisBlockMismatch: "Genesis block mismatch",
+ ErrNoStatusMsg: "No status message",
+ ErrExtraStatusMsg: "Extra status message",
+ ErrSuspendedPeer: "Suspended peer",
+}
+
+// ethProtocol represents the ethereum wire protocol
+// instance is running on each peer
+type ethProtocol struct {
+ txPool txPool
+ chainManager chainManager
+ blockPool blockPool
+ peer *p2p.Peer
+ id string
+ rw p2p.MsgReadWriter
+ errors *errs.Errors
+ protocolVersion int
+ networkId int
+}
+
+// backend is the interface the ethereum protocol backend should implement
+// used as an argument to EthProtocol
+type txPool interface {
+ AddTransactions([]*types.Transaction)
+ GetTransactions() types.Transactions
+}
+
+type chainManager interface {
+ GetBlockHashesFromHash(hash common.Hash, amount uint64) (hashes []common.Hash)
+ GetBlock(hash common.Hash) (block *types.Block)
+ Status() (td *big.Int, currentBlock common.Hash, genesisBlock common.Hash)
+}
+
+type blockPool interface {
+ AddBlockHashes(next func() (common.Hash, bool), peerId string)
+ AddBlock(block *types.Block, peerId string)
+ AddPeer(td *big.Int, currentBlock common.Hash, peerId string, requestHashes func(common.Hash) error, requestBlocks func([]common.Hash) error, peerError func(*errs.Error)) (best bool, suspended bool)
+ RemovePeer(peerId string)
+}
+
+// message structs used for RLP serialization
+type newBlockMsgData struct {
+ Block *types.Block
+ TD *big.Int
+}
+
+type getBlockHashesMsgData struct {
+ Hash common.Hash
+ Amount uint64
+}
+
+type statusMsgData struct {
+ ProtocolVersion uint32
+ NetworkId uint32
+ TD *big.Int
+ CurrentBlock common.Hash
+ GenesisBlock common.Hash
+}
+
+// main entrypoint, wrappers starting a server running the eth protocol
+// use this constructor to attach the protocol ("class") to server caps
+// the Dev p2p layer then runs the protocol instance on each peer
+func EthProtocol(protocolVersion, networkId int, txPool txPool, chainManager chainManager, blockPool blockPool) p2p.Protocol {
+ return p2p.Protocol{
+ Name: "eth",
+ Version: uint(protocolVersion),
+ Length: ProtocolLength,
+ Run: func(peer *p2p.Peer, rw p2p.MsgReadWriter) error {
+ return runEthProtocol(protocolVersion, networkId, txPool, chainManager, blockPool, peer, rw)
+ },
+ }
+}
+
+// the main loop that handles incoming messages
+// note RemovePeer in the post-disconnect hook
+func runEthProtocol(protocolVersion, networkId int, txPool txPool, chainManager chainManager, blockPool blockPool, peer *p2p.Peer, rw p2p.MsgReadWriter) (err error) {
+ id := peer.ID()
+ self := &ethProtocol{
+ txPool: txPool,
+ chainManager: chainManager,
+ blockPool: blockPool,
+ rw: rw,
+ peer: peer,
+ protocolVersion: protocolVersion,
+ networkId: networkId,
+ errors: &errs.Errors{
+ Package: "ETH",
+ Errors: errorToString,
+ },
+ id: fmt.Sprintf("%x", id[:8]),
+ }
+
+ // handshake.
+ if err := self.handleStatus(); err != nil {
+ return err
+ }
+ defer self.blockPool.RemovePeer(self.id)
+
+ // propagate existing transactions. new transactions appearing
+ // after this will be sent via broadcasts.
+ if err := p2p.Send(rw, TxMsg, txPool.GetTransactions()); err != nil {
+ return err
+ }
+
+ // main loop. handle incoming messages.
+ for {
+ if err := self.handle(); err != nil {
+ return err
+ }
+ }
+}
+
+func (self *ethProtocol) handle() error {
+ msg, err := self.rw.ReadMsg()
+ if err != nil {
+ return err
+ }
+ if msg.Size > ProtocolMaxMsgSize {
+ return self.protoError(ErrMsgTooLarge, "%v > %v", msg.Size, ProtocolMaxMsgSize)
+ }
+ // make sure that the payload has been fully consumed
+ defer msg.Discard()
+
+ switch msg.Code {
+ case GetTxMsg: // ignore
+ case StatusMsg:
+ return self.protoError(ErrExtraStatusMsg, "")
+
+ case TxMsg:
+ // TODO: rework using lazy RLP stream
+ var txs []*types.Transaction
+ if err := msg.Decode(&txs); err != nil {
+ return self.protoError(ErrDecode, "msg %v: %v", msg, err)
+ }
+ for i, tx := range txs {
+ if tx == nil {
+ return self.protoError(ErrDecode, "transaction %d is nil", i)
+ }
+ jsonlogger.LogJson(&logger.EthTxReceived{
+ TxHash: tx.Hash().Hex(),
+ RemoteId: self.peer.ID().String(),
+ })
+ }
+ self.txPool.AddTransactions(txs)
+
+ case GetBlockHashesMsg:
+ var request getBlockHashesMsgData
+ if err := msg.Decode(&request); err != nil {
+ return self.protoError(ErrDecode, "->msg %v: %v", msg, err)
+ }
+
+ if request.Amount > maxHashes {
+ request.Amount = maxHashes
+ }
+ hashes := self.chainManager.GetBlockHashesFromHash(request.Hash, request.Amount)
+ return p2p.Send(self.rw, BlockHashesMsg, hashes)
+
+ case BlockHashesMsg:
+ msgStream := rlp.NewStream(msg.Payload)
+ if _, err := msgStream.List(); err != nil {
+ return err
+ }
+
+ var i int
+ iter := func() (hash common.Hash, ok bool) {
+ err := msgStream.Decode(&hash)
+ if err == rlp.EOL {
+ return common.Hash{}, false
+ } else if err != nil {
+ self.protoError(ErrDecode, "msg %v: after %v hashes : %v", msg, i, err)
+ return common.Hash{}, false
+ }
+
+ i++
+ return hash, true
+ }
+ self.blockPool.AddBlockHashes(iter, self.id)
+
+ case GetBlocksMsg:
+ msgStream := rlp.NewStream(msg.Payload)
+ if _, err := msgStream.List(); err != nil {
+ return err
+ }
+
+ var blocks []*types.Block
+ var i int
+ for {
+ i++
+ var hash common.Hash
+ err := msgStream.Decode(&hash)
+ if err == rlp.EOL {
+ break
+ } else if err != nil {
+ return self.protoError(ErrDecode, "msg %v: %v", msg, err)
+ }
+
+ block := self.chainManager.GetBlock(hash)
+ if block != nil {
+ blocks = append(blocks, block)
+ }
+ if i == maxBlocks {
+ break
+ }
+ }
+ return p2p.Send(self.rw, BlocksMsg, blocks)
+
+ case BlocksMsg:
+ msgStream := rlp.NewStream(msg.Payload)
+ if _, err := msgStream.List(); err != nil {
+ return err
+ }
+ for {
+ var block types.Block
+ if err := msgStream.Decode(&block); err != nil {
+ if err == rlp.EOL {
+ break
+ } else {
+ return self.protoError(ErrDecode, "msg %v: %v", msg, err)
+ }
+ }
+ if err := block.ValidateFields(); err != nil {
+ return self.protoError(ErrDecode, "block validation %v: %v", msg, err)
+ }
+ self.blockPool.AddBlock(&block, self.id)
+ }
+
+ case NewBlockMsg:
+ var request newBlockMsgData
+ if err := msg.Decode(&request); err != nil {
+ return self.protoError(ErrDecode, "%v: %v", msg, err)
+ }
+ if err := request.Block.ValidateFields(); err != nil {
+ return self.protoError(ErrDecode, "block validation %v: %v", msg, err)
+ }
+ hash := request.Block.Hash()
+ _, chainHead, _ := self.chainManager.Status()
+
+ jsonlogger.LogJson(&logger.EthChainReceivedNewBlock{
+ BlockHash: hash.Hex(),
+ BlockNumber: request.Block.Number(), // this surely must be zero
+ ChainHeadHash: chainHead.Hex(),
+ BlockPrevHash: request.Block.ParentHash().Hex(),
+ RemoteId: self.peer.ID().String(),
+ })
+ // to simplify backend interface adding a new block
+ // uses AddPeer followed by AddBlock only if peer is the best peer
+ // (or selected as new best peer)
+ if best, _ := self.blockPool.AddPeer(request.TD, hash, self.id, self.requestBlockHashes, self.requestBlocks, self.protoErrorDisconnect); best {
+ self.blockPool.AddBlock(request.Block, self.id)
+ }
+
+ default:
+ return self.protoError(ErrInvalidMsgCode, "%v", msg.Code)
+ }
+ return nil
+}
+
+func (self *ethProtocol) handleStatus() error {
+ if err := self.sendStatus(); err != nil {
+ return err
+ }
+
+ // read and handle remote status
+ msg, err := self.rw.ReadMsg()
+ if err != nil {
+ return err
+ }
+ if msg.Code != StatusMsg {
+ return self.protoError(ErrNoStatusMsg, "first msg has code %x (!= %x)", msg.Code, StatusMsg)
+ }
+ if msg.Size > ProtocolMaxMsgSize {
+ return self.protoError(ErrMsgTooLarge, "%v > %v", msg.Size, ProtocolMaxMsgSize)
+ }
+
+ var status statusMsgData
+ if err := msg.Decode(&status); err != nil {
+ return self.protoError(ErrDecode, "msg %v: %v", msg, err)
+ }
+
+ _, _, genesisBlock := self.chainManager.Status()
+
+ if status.GenesisBlock != genesisBlock {
+ return self.protoError(ErrGenesisBlockMismatch, "%x (!= %x)", status.GenesisBlock, genesisBlock)
+ }
+
+ if int(status.NetworkId) != self.networkId {
+ return self.protoError(ErrNetworkIdMismatch, "%d (!= %d)", status.NetworkId, self.networkId)
+ }
+
+ if int(status.ProtocolVersion) != self.protocolVersion {
+ return self.protoError(ErrProtocolVersionMismatch, "%d (!= %d)", status.ProtocolVersion, self.protocolVersion)
+ }
+
+ _, suspended := self.blockPool.AddPeer(status.TD, status.CurrentBlock, self.id, self.requestBlockHashes, self.requestBlocks, self.protoErrorDisconnect)
+ if suspended {
+ return self.protoError(ErrSuspendedPeer, "")
+ }
+
+ self.peer.Infof("Peer is [eth] capable (%d/%d). TD=%v H=%x\n", status.ProtocolVersion, status.NetworkId, status.TD, status.CurrentBlock[:4])
+
+ return nil
+}
+
+func (self *ethProtocol) requestBlockHashes(from common.Hash) error {
+ self.peer.Debugf("fetching hashes (%d) %x...\n", maxHashes, from[0:4])
+ return p2p.Send(self.rw, GetBlockHashesMsg, getBlockHashesMsgData{from, maxHashes})
+}
+
+func (self *ethProtocol) requestBlocks(hashes []common.Hash) error {
+ self.peer.Debugf("fetching %v blocks", len(hashes))
+ return p2p.Send(self.rw, GetBlocksMsg, hashes)
+}
+
+func (self *ethProtocol) protoError(code int, format string, params ...interface{}) (err *errs.Error) {
+ err = self.errors.New(code, format, params...)
+ err.Log(self.peer.Logger)
+ return
+}
+
+func (self *ethProtocol) sendStatus() error {
+ td, currentBlock, genesisBlock := self.chainManager.Status()
+ return p2p.Send(self.rw, StatusMsg, &statusMsgData{
+ ProtocolVersion: uint32(self.protocolVersion),
+ NetworkId: uint32(self.networkId),
+ TD: td,
+ CurrentBlock: currentBlock,
+ GenesisBlock: genesisBlock,
+ })
+}
+
+func (self *ethProtocol) protoErrorDisconnect(err *errs.Error) {
+ err.Log(self.peer.Logger)
+ if err.Fatal() {
+ self.peer.Disconnect(p2p.DiscSubprotocolError)
+ }
+}
diff --git a/eth/protocol_test.go b/eth/protocol_test.go
new file mode 100644
index 000000000..d3466326a
--- /dev/null
+++ b/eth/protocol_test.go
@@ -0,0 +1,400 @@
+package eth
+
+import (
+ "log"
+ "math/big"
+ "os"
+ "testing"
+ "time"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/core/types"
+ "github.com/ethereum/go-ethereum/crypto"
+ "github.com/ethereum/go-ethereum/errs"
+ ethlogger "github.com/ethereum/go-ethereum/logger"
+ "github.com/ethereum/go-ethereum/p2p"
+ "github.com/ethereum/go-ethereum/p2p/discover"
+)
+
+var logsys = ethlogger.NewStdLogSystem(os.Stdout, log.LstdFlags, ethlogger.LogLevel(ethlogger.DebugDetailLevel))
+
+var ini = false
+
+func logInit() {
+ if !ini {
+ ethlogger.AddLogSystem(logsys)
+ ini = true
+ }
+}
+
+type testTxPool struct {
+ getTransactions func() []*types.Transaction
+ addTransactions func(txs []*types.Transaction)
+}
+
+type testChainManager struct {
+ getBlockHashes func(hash common.Hash, amount uint64) (hashes []common.Hash)
+ getBlock func(hash common.Hash) *types.Block
+ status func() (td *big.Int, currentBlock common.Hash, genesisBlock common.Hash)
+}
+
+type testBlockPool struct {
+ addBlockHashes func(next func() (common.Hash, bool), peerId string)
+ addBlock func(block *types.Block, peerId string) (err error)
+ addPeer func(td *big.Int, currentBlock common.Hash, peerId string, requestHashes func(common.Hash) error, requestBlocks func([]common.Hash) error, peerError func(*errs.Error)) (best bool, suspended bool)
+ removePeer func(peerId string)
+}
+
+func (self *testTxPool) AddTransactions(txs []*types.Transaction) {
+ if self.addTransactions != nil {
+ self.addTransactions(txs)
+ }
+}
+
+func (self *testTxPool) GetTransactions() types.Transactions { return nil }
+
+func (self *testChainManager) GetBlockHashesFromHash(hash common.Hash, amount uint64) (hashes []common.Hash) {
+ if self.getBlockHashes != nil {
+ hashes = self.getBlockHashes(hash, amount)
+ }
+ return
+}
+
+func (self *testChainManager) Status() (td *big.Int, currentBlock common.Hash, genesisBlock common.Hash) {
+ if self.status != nil {
+ td, currentBlock, genesisBlock = self.status()
+ } else {
+ td = common.Big1
+ currentBlock = common.Hash{1}
+ genesisBlock = common.Hash{2}
+ }
+ return
+}
+
+func (self *testChainManager) GetBlock(hash common.Hash) (block *types.Block) {
+ if self.getBlock != nil {
+ block = self.getBlock(hash)
+ }
+ return
+}
+
+func (self *testBlockPool) AddBlockHashes(next func() (common.Hash, bool), peerId string) {
+ if self.addBlockHashes != nil {
+ self.addBlockHashes(next, peerId)
+ }
+}
+
+func (self *testBlockPool) AddBlock(block *types.Block, peerId string) {
+ if self.addBlock != nil {
+ self.addBlock(block, peerId)
+ }
+}
+
+func (self *testBlockPool) AddPeer(td *big.Int, currentBlock common.Hash, peerId string, requestBlockHashes func(common.Hash) error, requestBlocks func([]common.Hash) error, peerError func(*errs.Error)) (best bool, suspended bool) {
+ if self.addPeer != nil {
+ best, suspended = self.addPeer(td, currentBlock, peerId, requestBlockHashes, requestBlocks, peerError)
+ }
+ return
+}
+
+func (self *testBlockPool) RemovePeer(peerId string) {
+ if self.removePeer != nil {
+ self.removePeer(peerId)
+ }
+}
+
+func testPeer() *p2p.Peer {
+ var id discover.NodeID
+ pk := crypto.GenerateNewKeyPair().PublicKey
+ copy(id[:], pk)
+ return p2p.NewPeer(id, "test peer", []p2p.Cap{})
+}
+
+type ethProtocolTester struct {
+ p2p.MsgReadWriter // writing to the tester feeds the protocol
+
+ quit chan error
+ pipe *p2p.MsgPipeRW // the protocol read/writes on this end
+ txPool *testTxPool // txPool
+ chainManager *testChainManager // chainManager
+ blockPool *testBlockPool // blockPool
+ t *testing.T
+}
+
+func newEth(t *testing.T) *ethProtocolTester {
+ p1, p2 := p2p.MsgPipe()
+ return &ethProtocolTester{
+ MsgReadWriter: p1,
+ quit: make(chan error, 1),
+ pipe: p2,
+ txPool: &testTxPool{},
+ chainManager: &testChainManager{},
+ blockPool: &testBlockPool{},
+ t: t,
+ }
+}
+
+func (self *ethProtocolTester) reset() {
+ self.pipe.Close()
+
+ p1, p2 := p2p.MsgPipe()
+ self.MsgReadWriter = p1
+ self.pipe = p2
+ self.quit = make(chan error, 1)
+}
+
+func (self *ethProtocolTester) checkError(expCode int, delay time.Duration) (err error) {
+ var timer = time.After(delay)
+ select {
+ case err = <-self.quit:
+ case <-timer:
+ self.t.Errorf("no error after %v, expected %v", delay, expCode)
+ return
+ }
+ perr, ok := err.(*errs.Error)
+ if ok && perr != nil {
+ if code := perr.Code; code != expCode {
+ self.t.Errorf("expected protocol error (code %v), got %v (%v)", expCode, code, err)
+ }
+ } else {
+ self.t.Errorf("expected protocol error (code %v), got %v", expCode, err)
+ }
+ return
+}
+
+func (self *ethProtocolTester) run() {
+ err := runEthProtocol(ProtocolVersion, NetworkId, self.txPool, self.chainManager, self.blockPool, testPeer(), self.pipe)
+ self.quit <- err
+}
+
+func (self *ethProtocolTester) handshake(t *testing.T, mock bool) {
+ td, currentBlock, genesis := self.chainManager.Status()
+ // first outgoing msg should be StatusMsg.
+ err := p2p.ExpectMsg(self, StatusMsg, &statusMsgData{
+ ProtocolVersion: ProtocolVersion,
+ NetworkId: NetworkId,
+ TD: td,
+ CurrentBlock: currentBlock,
+ GenesisBlock: genesis,
+ })
+ if err != nil {
+ t.Fatalf("incorrect outgoing status: %v", err)
+ }
+ if mock {
+ go p2p.Send(self, StatusMsg, &statusMsgData{ProtocolVersion, NetworkId, td, currentBlock, genesis})
+ }
+}
+
+func TestStatusMsgErrors(t *testing.T) {
+ logInit()
+ eth := newEth(t)
+ go eth.run()
+ td, currentBlock, genesis := eth.chainManager.Status()
+
+ tests := []struct {
+ code uint64
+ data interface{}
+ wantErrorCode int
+ }{
+ {
+ code: TxMsg, data: []interface{}{},
+ wantErrorCode: ErrNoStatusMsg,
+ },
+ {
+ code: StatusMsg, data: statusMsgData{10, NetworkId, td, currentBlock, genesis},
+ wantErrorCode: ErrProtocolVersionMismatch,
+ },
+ {
+ code: StatusMsg, data: statusMsgData{ProtocolVersion, 999, td, currentBlock, genesis},
+ wantErrorCode: ErrNetworkIdMismatch,
+ },
+ {
+ code: StatusMsg, data: statusMsgData{ProtocolVersion, NetworkId, td, currentBlock, common.Hash{3}},
+ wantErrorCode: ErrGenesisBlockMismatch,
+ },
+ }
+ for _, test := range tests {
+ eth.handshake(t, false)
+ // the send call might hang until reset because
+ // the protocol might not read the payload.
+ go p2p.Send(eth, test.code, test.data)
+ eth.checkError(test.wantErrorCode, 1*time.Second)
+
+ eth.reset()
+ go eth.run()
+ }
+}
+
+func TestNewBlockMsg(t *testing.T) {
+ // logInit()
+ eth := newEth(t)
+
+ var disconnected bool
+ eth.blockPool.removePeer = func(peerId string) {
+ disconnected = true
+ }
+
+ go eth.run()
+
+ eth.handshake(t, true)
+ err := p2p.ExpectMsg(eth, TxMsg, []interface{}{})
+ if err != nil {
+ t.Errorf("transactions expected, got %v", err)
+ }
+
+ var tds = make(chan *big.Int)
+ eth.blockPool.addPeer = func(td *big.Int, currentBlock common.Hash, peerId string, requestHashes func(common.Hash) error, requestBlocks func([]common.Hash) error, peerError func(*errs.Error)) (best bool, suspended bool) {
+ tds <- td
+ return
+ }
+
+ var delay = 1 * time.Second
+ // eth.reset()
+ block := types.NewBlock(common.Hash{1}, common.Address{1}, common.Hash{1}, common.Big1, 1, "extra")
+
+ go p2p.Send(eth, NewBlockMsg, &newBlockMsgData{Block: block})
+ timer := time.After(delay)
+
+ select {
+ case td := <-tds:
+ if td.Cmp(common.Big0) != 0 {
+ t.Errorf("incorrect td %v, expected %v", td, common.Big0)
+ }
+ case <-timer:
+ t.Errorf("no td recorded after %v", delay)
+ return
+ case err := <-eth.quit:
+ t.Errorf("no error expected, got %v", err)
+ return
+ }
+
+ go p2p.Send(eth, NewBlockMsg, &newBlockMsgData{block, common.Big2})
+ timer = time.After(delay)
+
+ select {
+ case td := <-tds:
+ if td.Cmp(common.Big2) != 0 {
+ t.Errorf("incorrect td %v, expected %v", td, common.Big2)
+ }
+ case <-timer:
+ t.Errorf("no td recorded after %v", delay)
+ return
+ case err := <-eth.quit:
+ t.Errorf("no error expected, got %v", err)
+ return
+ }
+
+ go p2p.Send(eth, NewBlockMsg, []interface{}{})
+ // Block.DecodeRLP: validation failed: header is nil
+ eth.checkError(ErrDecode, delay)
+
+}
+
+func TestBlockMsg(t *testing.T) {
+ // logInit()
+ eth := newEth(t)
+ blocks := make(chan *types.Block)
+ eth.blockPool.addBlock = func(block *types.Block, peerId string) (err error) {
+ blocks <- block
+ return
+ }
+
+ var disconnected bool
+ eth.blockPool.removePeer = func(peerId string) {
+ disconnected = true
+ }
+
+ go eth.run()
+
+ eth.handshake(t, true)
+ err := p2p.ExpectMsg(eth, TxMsg, []interface{}{})
+ if err != nil {
+ t.Errorf("transactions expected, got %v", err)
+ }
+
+ var delay = 3 * time.Second
+ // eth.reset()
+ newblock := func(i int64) *types.Block {
+ return types.NewBlock(common.Hash{byte(i)}, common.Address{byte(i)}, common.Hash{byte(i)}, big.NewInt(i), uint64(i), string(i))
+ }
+ b := newblock(0)
+ b.Header().Difficulty = nil // check if nil as *big.Int decodes as 0
+ go p2p.Send(eth, BlocksMsg, types.Blocks{b, newblock(1), newblock(2)})
+ timer := time.After(delay)
+ for i := int64(0); i < 3; i++ {
+ select {
+ case block := <-blocks:
+ if (block.ParentHash() != common.Hash{byte(i)}) {
+ t.Errorf("incorrect block %v, expected %v", block.ParentHash(), common.Hash{byte(i)})
+ }
+ if block.Difficulty().Cmp(big.NewInt(i)) != 0 {
+ t.Errorf("incorrect block %v, expected %v", block.Difficulty(), big.NewInt(i))
+ }
+ case <-timer:
+ t.Errorf("no td recorded after %v", delay)
+ return
+ case err := <-eth.quit:
+ t.Errorf("no error expected, got %v", err)
+ return
+ }
+ }
+
+ go p2p.Send(eth, BlocksMsg, []interface{}{[]interface{}{}})
+ eth.checkError(ErrDecode, delay)
+ if !disconnected {
+ t.Errorf("peer not disconnected after error")
+ }
+
+ // test empty transaction
+ eth.reset()
+ go eth.run()
+ eth.handshake(t, true)
+ err = p2p.ExpectMsg(eth, TxMsg, []interface{}{})
+ if err != nil {
+ t.Errorf("transactions expected, got %v", err)
+ }
+ b = newblock(0)
+ b.AddTransaction(nil)
+ go p2p.Send(eth, BlocksMsg, types.Blocks{b})
+ eth.checkError(ErrDecode, delay)
+
+}
+
+func TestTransactionsMsg(t *testing.T) {
+ logInit()
+ eth := newEth(t)
+ txs := make(chan *types.Transaction)
+
+ eth.txPool.addTransactions = func(t []*types.Transaction) {
+ for _, tx := range t {
+ txs <- tx
+ }
+ }
+ go eth.run()
+
+ eth.handshake(t, true)
+ err := p2p.ExpectMsg(eth, TxMsg, []interface{}{})
+ if err != nil {
+ t.Errorf("transactions expected, got %v", err)
+ }
+
+ var delay = 3 * time.Second
+ tx := &types.Transaction{}
+
+ go p2p.Send(eth, TxMsg, []interface{}{tx, tx})
+ timer := time.After(delay)
+ for i := int64(0); i < 2; i++ {
+ select {
+ case <-txs:
+ case <-timer:
+ return
+ case err := <-eth.quit:
+ t.Errorf("no error expected, got %v", err)
+ return
+ }
+ }
+
+ go p2p.Send(eth, TxMsg, []interface{}{[]interface{}{}})
+ eth.checkError(ErrDecode, delay)
+
+}
diff --git a/ethdb/.gitignore b/ethdb/.gitignore
new file mode 100644
index 000000000..f725d58d1
--- /dev/null
+++ b/ethdb/.gitignore
@@ -0,0 +1,12 @@
+# See http://help.github.com/ignore-files/ for more about ignoring files.
+#
+# If you find yourself ignoring temporary files generated by your text editor
+# or operating system, you probably want to add a global ignore instead:
+# git config --global core.excludesfile ~/.gitignore_global
+
+/tmp
+*/**/*un~
+*un~
+.DS_Store
+*/**/.DS_Store
+
diff --git a/ethdb/README.md b/ethdb/README.md
new file mode 100644
index 000000000..5bed8eedc
--- /dev/null
+++ b/ethdb/README.md
@@ -0,0 +1,11 @@
+# ethdb
+
+The ethdb package contains the ethereum database interfaces
+
+# Installation
+
+`go get github.com/ethereum/ethdb-go`
+
+# Usage
+
+Todo :-)
diff --git a/ethdb/database.go b/ethdb/database.go
new file mode 100644
index 000000000..cc2df5fa0
--- /dev/null
+++ b/ethdb/database.go
@@ -0,0 +1,88 @@
+package ethdb
+
+import (
+ "fmt"
+
+ "github.com/ethereum/go-ethereum/compression/rle"
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/syndtr/goleveldb/leveldb"
+ "github.com/syndtr/goleveldb/leveldb/iterator"
+)
+
+type LDBDatabase struct {
+ db *leveldb.DB
+ comp bool
+}
+
+func NewLDBDatabase(file string) (*LDBDatabase, error) {
+ // Open the db
+ db, err := leveldb.OpenFile(file, nil)
+ if err != nil {
+ return nil, err
+ }
+ database := &LDBDatabase{db: db, comp: true}
+ return database, nil
+}
+
+func (self *LDBDatabase) Put(key []byte, value []byte) {
+ if self.comp {
+ value = rle.Compress(value)
+ }
+
+ err := self.db.Put(key, value, nil)
+ if err != nil {
+ fmt.Println("Error put", err)
+ }
+}
+
+func (self *LDBDatabase) Get(key []byte) ([]byte, error) {
+ dat, err := self.db.Get(key, nil)
+ if err != nil {
+ return nil, err
+ }
+
+ if self.comp {
+ return rle.Decompress(dat)
+ }
+
+ return dat, nil
+}
+
+func (self *LDBDatabase) Delete(key []byte) error {
+ return self.db.Delete(key, nil)
+}
+
+func (self *LDBDatabase) LastKnownTD() []byte {
+ data, _ := self.Get([]byte("LTD"))
+
+ if len(data) == 0 {
+ data = []byte{0x0}
+ }
+
+ return data
+}
+
+func (self *LDBDatabase) NewIterator() iterator.Iterator {
+ return self.db.NewIterator(nil, nil)
+}
+
+func (self *LDBDatabase) Write(batch *leveldb.Batch) error {
+ return self.db.Write(batch, nil)
+}
+
+func (self *LDBDatabase) Close() {
+ // Close the leveldb database
+ self.db.Close()
+}
+
+func (self *LDBDatabase) Print() {
+ iter := self.db.NewIterator(nil, nil)
+ for iter.Next() {
+ key := iter.Key()
+ value := iter.Value()
+
+ fmt.Printf("%x(%d): ", key, len(key))
+ node := common.NewValueFromBytes(value)
+ fmt.Printf("%v\n", node)
+ }
+}
diff --git a/ethdb/database_test.go b/ethdb/database_test.go
new file mode 100644
index 000000000..7de30fd81
--- /dev/null
+++ b/ethdb/database_test.go
@@ -0,0 +1,26 @@
+package ethdb
+
+/*
+import (
+ "bytes"
+ "testing"
+)
+
+func TestCompression(t *testing.T) {
+ db, err := NewLDBDatabase("testdb")
+ if err != nil {
+ t.Fatal(err)
+ }
+
+ in := make([]byte, 10)
+ db.Put([]byte("test1"), in)
+ out, err := db.Get([]byte("test1"))
+ if err != nil {
+ t.Fatal(err)
+ }
+
+ if bytes.Compare(out, in) != 0 {
+ t.Error("put get", in, out)
+ }
+}
+*/
diff --git a/ethdb/memory_database.go b/ethdb/memory_database.go
new file mode 100644
index 000000000..d4988d0d8
--- /dev/null
+++ b/ethdb/memory_database.go
@@ -0,0 +1,67 @@
+package ethdb
+
+import (
+ "fmt"
+
+ "github.com/ethereum/go-ethereum/common"
+)
+
+/*
+ * This is a test memory database. Do not use for any production it does not get persisted
+ */
+type MemDatabase struct {
+ db map[string][]byte
+}
+
+func NewMemDatabase() (*MemDatabase, error) {
+ db := &MemDatabase{db: make(map[string][]byte)}
+
+ return db, nil
+}
+
+func (db *MemDatabase) Put(key []byte, value []byte) {
+ db.db[string(key)] = value
+}
+
+func (db *MemDatabase) Set(key []byte, value []byte) {
+ db.Put(key, value)
+}
+
+func (db *MemDatabase) Get(key []byte) ([]byte, error) {
+ return db.db[string(key)], nil
+}
+
+/*
+func (db *MemDatabase) GetKeys() []*common.Key {
+ data, _ := db.Get([]byte("KeyRing"))
+
+ return []*common.Key{common.NewKeyFromBytes(data)}
+}
+*/
+
+func (db *MemDatabase) Delete(key []byte) error {
+ delete(db.db, string(key))
+
+ return nil
+}
+
+func (db *MemDatabase) Print() {
+ for key, val := range db.db {
+ fmt.Printf("%x(%d): ", key, len(key))
+ node := common.NewValueFromBytes(val)
+ fmt.Printf("%q\n", node.Val)
+ }
+}
+
+func (db *MemDatabase) Close() {
+}
+
+func (db *MemDatabase) LastKnownTD() []byte {
+ data, _ := db.Get([]byte("LastKnownTotalDifficulty"))
+
+ if len(data) == 0 || data == nil {
+ data = []byte{0x0}
+ }
+
+ return data
+}
diff --git a/event/event.go b/event/event.go
new file mode 100644
index 000000000..540fbba65
--- /dev/null
+++ b/event/event.go
@@ -0,0 +1,183 @@
+// Package event implements an event multiplexer.
+package event
+
+import (
+ "errors"
+ "fmt"
+ "reflect"
+ "sync"
+)
+
+// Subscription is implemented by event subscriptions.
+type Subscription interface {
+ // Chan returns a channel that carries events.
+ // Implementations should return the same channel
+ // for any subsequent calls to Chan.
+ Chan() <-chan interface{}
+
+ // Unsubscribe stops delivery of events to a subscription.
+ // The event channel is closed.
+ // Unsubscribe can be called more than once.
+ Unsubscribe()
+}
+
+// A TypeMux dispatches events to registered receivers. Receivers can be
+// registered to handle events of certain type. Any operation
+// called after mux is stopped will return ErrMuxClosed.
+//
+// The zero value is ready to use.
+type TypeMux struct {
+ mutex sync.RWMutex
+ subm map[reflect.Type][]*muxsub
+ stopped bool
+}
+
+// ErrMuxClosed is returned when Posting on a closed TypeMux.
+var ErrMuxClosed = errors.New("event: mux closed")
+
+// Subscribe creates a subscription for events of the given types. The
+// subscription's channel is closed when it is unsubscribed
+// or the mux is closed.
+func (mux *TypeMux) Subscribe(types ...interface{}) Subscription {
+ sub := newsub(mux)
+ mux.mutex.Lock()
+ defer mux.mutex.Unlock()
+ if mux.stopped {
+ close(sub.postC)
+ } else {
+ if mux.subm == nil {
+ mux.subm = make(map[reflect.Type][]*muxsub)
+ }
+ for _, t := range types {
+ rtyp := reflect.TypeOf(t)
+ oldsubs := mux.subm[rtyp]
+ if find(oldsubs, sub) != -1 {
+ panic(fmt.Sprintf("event: duplicate type %s in Subscribe", rtyp))
+ }
+ subs := make([]*muxsub, len(oldsubs)+1)
+ copy(subs, oldsubs)
+ subs[len(oldsubs)] = sub
+ mux.subm[rtyp] = subs
+ }
+ }
+ return sub
+}
+
+// Post sends an event to all receivers registered for the given type.
+// It returns ErrMuxClosed if the mux has been stopped.
+func (mux *TypeMux) Post(ev interface{}) error {
+ rtyp := reflect.TypeOf(ev)
+ mux.mutex.RLock()
+ if mux.stopped {
+ mux.mutex.RUnlock()
+ return ErrMuxClosed
+ }
+ subs := mux.subm[rtyp]
+ mux.mutex.RUnlock()
+ for _, sub := range subs {
+ sub.deliver(ev)
+ }
+ return nil
+}
+
+// Stop closes a mux. The mux can no longer be used.
+// Future Post calls will fail with ErrMuxClosed.
+// Stop blocks until all current deliveries have finished.
+func (mux *TypeMux) Stop() {
+ mux.mutex.Lock()
+ for _, subs := range mux.subm {
+ for _, sub := range subs {
+ sub.closewait()
+ }
+ }
+ mux.subm = nil
+ mux.stopped = true
+ mux.mutex.Unlock()
+}
+
+func (mux *TypeMux) del(s *muxsub) {
+ mux.mutex.Lock()
+ for typ, subs := range mux.subm {
+ if pos := find(subs, s); pos >= 0 {
+ if len(subs) == 1 {
+ delete(mux.subm, typ)
+ } else {
+ mux.subm[typ] = posdelete(subs, pos)
+ }
+ }
+ }
+ s.mux.mutex.Unlock()
+}
+
+func find(slice []*muxsub, item *muxsub) int {
+ for i, v := range slice {
+ if v == item {
+ return i
+ }
+ }
+ return -1
+}
+
+func posdelete(slice []*muxsub, pos int) []*muxsub {
+ news := make([]*muxsub, len(slice)-1)
+ copy(news[:pos], slice[:pos])
+ copy(news[pos:], slice[pos+1:])
+ return news
+}
+
+type muxsub struct {
+ mux *TypeMux
+ closeMu sync.Mutex
+ closing chan struct{}
+ closed bool
+
+ // these two are the same channel. they are stored separately so
+ // postC can be set to nil without affecting the return value of
+ // Chan.
+ postMu sync.RWMutex
+ readC <-chan interface{}
+ postC chan<- interface{}
+}
+
+func newsub(mux *TypeMux) *muxsub {
+ c := make(chan interface{})
+ return &muxsub{
+ mux: mux,
+ readC: c,
+ postC: c,
+ closing: make(chan struct{}),
+ }
+}
+
+func (s *muxsub) Chan() <-chan interface{} {
+ return s.readC
+}
+
+func (s *muxsub) Unsubscribe() {
+ s.mux.del(s)
+ s.closewait()
+}
+
+func (s *muxsub) closewait() {
+ s.closeMu.Lock()
+ defer s.closeMu.Unlock()
+ if s.closed {
+ return
+ }
+ close(s.closing)
+ s.closed = true
+
+ s.postMu.Lock()
+ close(s.postC)
+ s.postC = nil
+ s.postMu.Unlock()
+}
+
+func (s *muxsub) deliver(ev interface{}) {
+ s.postMu.RLock()
+ select {
+ case s.postC <- ev:
+ case <-s.closing:
+ }
+ s.postMu.RUnlock()
+}
diff --git a/event/event_test.go b/event/event_test.go
new file mode 100644
index 000000000..c7c0266c1
--- /dev/null
+++ b/event/event_test.go
@@ -0,0 +1,176 @@
+package event
+
+import (
+ "math/rand"
+ "sync"
+ "testing"
+ "time"
+)
+
+type testEvent int
+
+func TestSub(t *testing.T) {
+ mux := new(TypeMux)
+ defer mux.Stop()
+
+ sub := mux.Subscribe(testEvent(0))
+ go func() {
+ if err := mux.Post(testEvent(5)); err != nil {
+ t.Errorf("Post returned unexpected error: %v", err)
+ }
+ }()
+ ev := <-sub.Chan()
+
+ if ev.(testEvent) != testEvent(5) {
+ t.Errorf("Got %v (%T), expected event %v (%T)",
+ ev, ev, testEvent(5), testEvent(5))
+ }
+}
+
+func TestMuxErrorAfterStop(t *testing.T) {
+ mux := new(TypeMux)
+ mux.Stop()
+
+ sub := mux.Subscribe(testEvent(0))
+ if _, isopen := <-sub.Chan(); isopen {
+ t.Errorf("subscription channel was not closed")
+ }
+ if err := mux.Post(testEvent(0)); err != ErrMuxClosed {
+ t.Errorf("Post error mismatch, got: %s, expected: %s", err, ErrMuxClosed)
+ }
+}
+
+func TestUnsubscribeUnblockPost(t *testing.T) {
+ mux := new(TypeMux)
+ defer mux.Stop()
+
+ sub := mux.Subscribe(testEvent(0))
+ unblocked := make(chan bool)
+ go func() {
+ mux.Post(testEvent(5))
+ unblocked <- true
+ }()
+
+ select {
+ case <-unblocked:
+ t.Errorf("Post returned before Unsubscribe")
+ default:
+ sub.Unsubscribe()
+ <-unblocked
+ }
+}
+
+func TestSubscribeDuplicateType(t *testing.T) {
+ mux := new(TypeMux)
+ expected := "event: duplicate type event.testEvent in Subscribe"
+
+ defer func() {
+ err := recover()
+ if err == nil {
+ t.Errorf("Subscribe didn't panic for duplicate type")
+ } else if err != expected {
+ t.Errorf("panic mismatch: got %#v, expected %#v", err, expected)
+ }
+ }()
+ mux.Subscribe(testEvent(1), testEvent(2))
+}
+
+func TestMuxConcurrent(t *testing.T) {
+ rand.Seed(time.Now().Unix())
+ mux := new(TypeMux)
+ defer mux.Stop()
+
+ recv := make(chan int)
+ poster := func() {
+ for {
+ err := mux.Post(testEvent(0))
+ if err != nil {
+ return
+ }
+ }
+ }
+ sub := func(i int) {
+ time.Sleep(time.Duration(rand.Intn(99)) * time.Millisecond)
+ sub := mux.Subscribe(testEvent(0))
+ <-sub.Chan()
+ sub.Unsubscribe()
+ recv <- i
+ }
+
+ go poster()
+ go poster()
+ go poster()
+ nsubs := 1000
+ for i := 0; i < nsubs; i++ {
+ go sub(i)
+ }
+
+ // wait until everyone has been served
+ counts := make(map[int]int, nsubs)
+ for i := 0; i < nsubs; i++ {
+ counts[<-recv]++
+ }
+ for i, count := range counts {
+ if count != 1 {
+ t.Errorf("receiver %d called %d times, expected only 1 call", i, count)
+ }
+ }
+}
+
+func emptySubscriber(mux *TypeMux, types ...interface{}) {
+ s := mux.Subscribe(testEvent(0))
+ go func() {
+ for _ = range s.Chan() {
+ }
+ }()
+}
+
+func BenchmarkPost3(b *testing.B) {
+ var mux = new(TypeMux)
+ defer mux.Stop()
+ emptySubscriber(mux, testEvent(0))
+ emptySubscriber(mux, testEvent(0))
+ emptySubscriber(mux, testEvent(0))
+
+ for i := 0; i < b.N; i++ {
+ mux.Post(testEvent(0))
+ }
+}
+
+func BenchmarkPostConcurrent(b *testing.B) {
+ var mux = new(TypeMux)
+ defer mux.Stop()
+ emptySubscriber(mux, testEvent(0))
+ emptySubscriber(mux, testEvent(0))
+ emptySubscriber(mux, testEvent(0))
+
+ var wg sync.WaitGroup
+ poster := func() {
+ for i := 0; i < b.N; i++ {
+ mux.Post(testEvent(0))
+ }
+ wg.Done()
+ }
+ wg.Add(5)
+ for i := 0; i < 5; i++ {
+ go poster()
+ }
+ wg.Wait()
+}
+
+// for comparison
+func BenchmarkChanSend(b *testing.B) {
+ c := make(chan interface{})
+ closed := make(chan struct{})
+ go func() {
+ for _ = range c {
+ }
+ }()
+
+ for i := 0; i < b.N; i++ {
+ select {
+ case c <- i:
+ case <-closed:
+ }
+ }
+}
diff --git a/event/example_test.go b/event/example_test.go
new file mode 100644
index 000000000..2f47f6f27
--- /dev/null
+++ b/event/example_test.go
@@ -0,0 +1,42 @@
+package event
+
+import "fmt"
+
+func ExampleTypeMux() {
+ type someEvent struct{ I int }
+ type otherEvent struct{ S string }
+ type yetAnotherEvent struct{ X, Y int }
+
+ var mux TypeMux
+
+ // Start a subscriber.
+ done := make(chan struct{})
+ sub := mux.Subscribe(someEvent{}, otherEvent{})
+ go func() {
+ for event := range sub.Chan() {
+ fmt.Printf("Received: %#v\n", event)
+ }
+ fmt.Println("done")
+ close(done)
+ }()
+
+ // Post some events.
+ mux.Post(someEvent{5})
+ mux.Post(yetAnotherEvent{X: 3, Y: 4})
+ mux.Post(someEvent{6})
+ mux.Post(otherEvent{"whoa"})
+
+ // Stop closes all subscription channels.
+ // The subscriber goroutine will print "done"
+ // and exit.
+ mux.Stop()
+
+ // Wait for subscriber to return.
+ <-done
+
+ // Output:
+ // Received: event.someEvent{I:5}
+ // Received: event.someEvent{I:6}
+ // Received: event.otherEvent{S:"whoa"}
+ // done
+}
diff --git a/event/filter/eth_filter.go b/event/filter/eth_filter.go
new file mode 100644
index 000000000..dc032b5c2
--- /dev/null
+++ b/event/filter/eth_filter.go
@@ -0,0 +1,111 @@
+package filter
+
+// TODO make use of the generic filtering system
+
+import (
+ "sync"
+
+ "github.com/ethereum/go-ethereum/core"
+ "github.com/ethereum/go-ethereum/event"
+ "github.com/ethereum/go-ethereum/core/state"
+)
+
+type FilterManager struct {
+ eventMux *event.TypeMux
+
+ filterMu sync.RWMutex
+ filterId int
+ filters map[int]*core.Filter
+
+ quit chan struct{}
+}
+
+func NewFilterManager(mux *event.TypeMux) *FilterManager {
+ return &FilterManager{
+ eventMux: mux,
+ filters: make(map[int]*core.Filter),
+ }
+}
+
+func (self *FilterManager) Start() {
+ go self.filterLoop()
+}
+
+func (self *FilterManager) Stop() {
+ close(self.quit)
+}
+
+func (self *FilterManager) InstallFilter(filter *core.Filter) (id int) {
+ self.filterMu.Lock()
+ defer self.filterMu.Unlock()
+ id = self.filterId
+ self.filters[id] = filter
+ self.filterId++
+
+ return id
+}
+
+func (self *FilterManager) UninstallFilter(id int) {
+ self.filterMu.Lock()
+ defer self.filterMu.Unlock()
+ if _, ok := self.filters[id]; ok {
+ delete(self.filters, id)
+ }
+}
+
+// GetFilter retrieves a filter installed using InstallFilter.
+// The filter may not be modified.
+func (self *FilterManager) GetFilter(id int) *core.Filter {
+ self.filterMu.RLock()
+ defer self.filterMu.RUnlock()
+ return self.filters[id]
+}
+
+func (self *FilterManager) filterLoop() {
+ // Subscribe to events
+ events := self.eventMux.Subscribe(
+ //core.PendingBlockEvent{},
+ core.ChainEvent{},
+ core.TxPreEvent{},
+ state.Logs(nil))
+
+out:
+ for {
+ select {
+ case <-self.quit:
+ break out
+ case event := <-events.Chan():
+ switch event := event.(type) {
+ case core.ChainEvent:
+ self.filterMu.RLock()
+ for _, filter := range self.filters {
+ if filter.BlockCallback != nil {
+ filter.BlockCallback(event.Block, event.Logs)
+ }
+ }
+ self.filterMu.RUnlock()
+
+ case core.TxPreEvent:
+ self.filterMu.RLock()
+ for _, filter := range self.filters {
+ if filter.PendingCallback != nil {
+ filter.PendingCallback(event.Tx)
+ }
+ }
+ self.filterMu.RUnlock()
+
+ case state.Logs:
+ self.filterMu.RLock()
+ for _, filter := range self.filters {
+ if filter.LogsCallback != nil {
+ msgs := filter.FilterLogs(event)
+ if len(msgs) > 0 {
+ filter.LogsCallback(msgs)
+ }
+ }
+ }
+ self.filterMu.RUnlock()
+ }
+ }
+ }
+}
diff --git a/event/filter/filter.go b/event/filter/filter.go
new file mode 100644
index 000000000..ca767f413
--- /dev/null
+++ b/event/filter/filter.go
@@ -0,0 +1,78 @@
+package filter
+
+import "reflect"
+
+type Filter interface {
+ Compare(Filter) bool
+ Trigger(data interface{})
+}
+
+type FilterEvent struct {
+ filter Filter
+ data interface{}
+}
+
+type Filters struct {
+ id int
+ watchers map[int]Filter
+ ch chan FilterEvent
+
+ quit chan struct{}
+}
+
+func New() *Filters {
+ return &Filters{
+ ch: make(chan FilterEvent),
+ watchers: make(map[int]Filter),
+ quit: make(chan struct{}),
+ }
+}
+
+func (self *Filters) Start() {
+ go self.loop()
+}
+
+func (self *Filters) Stop() {
+ close(self.quit)
+}
+
+func (self *Filters) Notify(filter Filter, data interface{}) {
+ self.ch <- FilterEvent{filter, data}
+}
+
+func (self *Filters) Install(watcher Filter) int {
+ self.watchers[self.id] = watcher
+ self.id++
+
+ return self.id - 1
+}
+
+func (self *Filters) Uninstall(id int) {
+ delete(self.watchers, id)
+}
+
+func (self *Filters) loop() {
+out:
+ for {
+ select {
+ case <-self.quit:
+ break out
+ case event := <-self.ch:
+ for _, watcher := range self.watchers {
+ if reflect.TypeOf(watcher) == reflect.TypeOf(event.filter) {
+ if watcher.Compare(event.filter) {
+ watcher.Trigger(event.data)
+ }
+ }
+ }
+ }
+ }
+}
+
+func (self *Filters) Match(a, b Filter) bool {
+ return reflect.TypeOf(a) == reflect.TypeOf(b) && a.Compare(b)
+}
+
+func (self *Filters) Get(i int) Filter {
+ return self.watchers[i]
+}
diff --git a/event/filter/filter_test.go b/event/filter/filter_test.go
new file mode 100644
index 000000000..815deb63a
--- /dev/null
+++ b/event/filter/filter_test.go
@@ -0,0 +1,34 @@
+package filter
+
+import "testing"
+
+func TestFilters(t *testing.T) {
+ var success bool
+ var failure bool
+
+ fm := New()
+ fm.Start()
+ fm.Install(Generic{
+ Str1: "hello",
+ Fn: func(data interface{}) {
+ success = data.(bool)
+ },
+ })
+ fm.Install(Generic{
+ Str1: "hello1",
+ Str2: "hello",
+ Fn: func(data interface{}) {
+ failure = true
+ },
+ })
+ fm.Notify(Generic{Str1: "hello"}, true)
+ fm.Stop()
+
+ if !success {
+ t.Error("expected 'hello' to be posted")
+ }
+
+ if failure {
+ t.Error("hello1 was triggered")
+ }
+}
diff --git a/event/filter/generic_filter.go b/event/filter/generic_filter.go
new file mode 100644
index 000000000..2ce0f0642
--- /dev/null
+++ b/event/filter/generic_filter.go
@@ -0,0 +1,32 @@
+package filter
+
+type Generic struct {
+ Str1, Str2, Str3 string
+ Data map[string]struct{}
+
+ Fn func(data interface{})
+}
+
+// self = registered, f = incoming
+func (self Generic) Compare(f Filter) bool {
+ var strMatch, dataMatch = true, true
+
+ filter := f.(Generic)
+ if (len(self.Str1) > 0 && filter.Str1 != self.Str1) ||
+ (len(self.Str2) > 0 && filter.Str2 != self.Str2) ||
+ (len(self.Str3) > 0 && filter.Str3 != self.Str3) {
+ strMatch = false
+ }
+
+ for k, _ := range self.Data {
+ if _, ok := filter.Data[k]; !ok {
+ return false
+ }
+ }
+
+ return strMatch && dataMatch
+}
+
+func (self Generic) Trigger(data interface{}) {
+ self.Fn(data)
+}
diff --git a/generators/defaults.go b/generators/defaults.go
new file mode 100644
index 000000000..41d46729c
--- /dev/null
+++ b/generators/defaults.go
@@ -0,0 +1,65 @@
+//go:generate go run defaults.go default.json defs.go
+
+package main //build !none
+
+import (
+ "encoding/json"
+ "fmt"
+ "io/ioutil"
+ "os"
+ "os/exec"
+ "path"
+ "strings"
+)
+
+func fatal(str string, v ...interface{}) {
+ fmt.Fprintf(os.Stderr, str, v...)
+ os.Exit(1)
+}
+
+type setting struct {
+ Value int64 `json:"v"`
+ Comment string `json:"d"`
+}
+
+func main() {
+ if len(os.Args) < 3 {
+ fatal("usage %s <input> <output>\n", os.Args[0])
+ }
+
+ content, err := ioutil.ReadFile(os.Args[1])
+ if err != nil {
+ fatal("error reading file %v\n", err)
+ }
+
+ m := make(map[string]setting)
+ json.Unmarshal(content, &m)
+
+ filepath := path.Join(os.Getenv("GOPATH"), "src", "github.com", "ethereum", "go-ethereum", "params", os.Args[2])
+ output, err := os.OpenFile(filepath, os.O_RDWR|os.O_CREATE, os.ModePerm /*0777*/)
+ if err != nil {
+ fatal("error opening file for writing %v\n", err)
+ }
+
+ output.WriteString(`// DO NOT EDIT!!!
+// AUTOGENERATED FROM generators/defaults.go
+
+package params
+
+import "math/big"
+
+var (
+`)
+
+ for name, setting := range m {
+ output.WriteString(fmt.Sprintf("%s=big.NewInt(%d) // %s\n", strings.Title(name), setting.Value, setting.Comment))
+ }
+
+ output.WriteString(")\n")
+ output.Close()
+
+ cmd := exec.Command("gofmt", "-w", filepath)
+ if err := cmd.Run(); err != nil {
+ fatal("gofmt failed: %v\n", err)
+ }
+}
diff --git a/gocoverage.sh b/gocoverage.sh
new file mode 100755
index 000000000..5479d8d3b
--- /dev/null
+++ b/gocoverage.sh
@@ -0,0 +1,31 @@
+#!/bin/bash
+
+set -e
+
+# Add godep workspace to GOPATH. We do it manually instead of using
+# 'godep go test' or 'godep restore' so godep doesn't need to be installed.
+GOPATH="$PWD/Godeps/_workspace:$GOPATH"
+
+# Install packages before testing. Not doing this would cause
+# 'go test' to recompile all package dependencies before testing each package.
+go install ./...
+
+# Run test coverage on each subdirectories and merge the coverage profile.
+echo "mode: count" > profile.cov
+
+# Standard go tooling behavior is to ignore dirs with leading underscors
+for dir in $(find . -maxdepth 10 -not -path './.git*' -not -path '*/_*' -type d);
+do
+if ls $dir/*.go &> /dev/null; then
+ # echo $dir
+ if [[ $dir != "./tests/vm" && $dir != "." ]]
+ then
+ go test -covermode=count -coverprofile=$dir/profile.tmp $dir
+ fi
+ if [ -f $dir/profile.tmp ]
+ then
+ cat $dir/profile.tmp | tail -n +2 >> profile.cov
+ rm $dir/profile.tmp
+ fi
+fi
+done
diff --git a/jsre/bignumber_js.go b/jsre/bignumber_js.go
new file mode 100644
index 000000000..7902018be
--- /dev/null
+++ b/jsre/bignumber_js.go
@@ -0,0 +1,6 @@
+package jsre
+
+const BigNumber_JS = `/* bignumber.js v2.0.3 https://github.com/MikeMcl/bignumber.js/LICENCE */
+/* modified by zelig to fix https://github.com/robertkrimen/otto#regular-expression-incompatibility */
+!function(e){"use strict";function n(e){function a(e,n){var t,r,i,o,u,s,f=this;if(!(f instanceof a))return j&&L(26,"constructor call without new",e),new a(e,n);if(null!=n&&H(n,2,64,M,"base")){if(n=0|n,s=e+"",10==n)return f=new a(e instanceof a?e:s),U(f,P+f.e+1,k);if((o="number"==typeof e)&&0*e!=0||!new RegExp("^-?"+(t="["+O.slice(0,n)+"]+")+"(?:\\."+t+")?$",37>n?"i":"").test(s))return g(f,s,o,n);o?(f.s=0>1/e?(s=s.slice(1),-1):1,j&&s.replace(/^0\.0*|\./,"").length>15&&L(M,b,e),o=!1):f.s=45===s.charCodeAt(0)?(s=s.slice(1),-1):1,s=D(s,10,n,f.s)}else{if(e instanceof a)return f.s=e.s,f.e=e.e,f.c=(e=e.c)?e.slice():e,void(M=0);if((o="number"==typeof e)&&0*e==0){if(f.s=0>1/e?(e=-e,-1):1,e===~~e){for(r=0,i=e;i>=10;i/=10,r++);return f.e=r,f.c=[e],void(M=0)}s=e+""}else{if(!p.test(s=e+""))return g(f,s,o);f.s=45===s.charCodeAt(0)?(s=s.slice(1),-1):1}}for((r=s.indexOf("."))>-1&&(s=s.replace(".","")),(i=s.search(/e/i))>0?(0>r&&(r=i),r+=+s.slice(i+1),s=s.substring(0,i)):0>r&&(r=s.length),i=0;48===s.charCodeAt(i);i++);for(u=s.length;48===s.charCodeAt(--u););if(s=s.slice(i,u+1))if(u=s.length,o&&j&&u>15&&L(M,b,f.s*e),r=r-i-1,r>z)f.c=f.e=null;else if(G>r)f.c=[f.e=0];else{if(f.e=r,f.c=[],i=(r+1)%y,0>r&&(i+=y),u>i){for(i&&f.c.push(+s.slice(0,i)),u-=y;u>i;)f.c.push(+s.slice(i,i+=y));s=s.slice(i),i=y-s.length}else i-=u;for(;i--;s+="0");f.c.push(+s)}else f.c=[f.e=0];M=0}function D(e,n,t,i){var o,u,f,c,h,g,p,d=e.indexOf("."),m=P,w=k;for(37>t&&(e=e.toLowerCase()),d>=0&&(f=J,J=0,e=e.replace(".",""),p=new a(t),h=p.pow(e.length-d),J=f,p.c=s(l(r(h.c),h.e),10,n),p.e=p.c.length),g=s(e,t,n),u=f=g.length;0==g[--f];g.pop());if(!g[0])return"0";if(0>d?--u:(h.c=g,h.e=u,h.s=i,h=C(h,p,m,w,n),g=h.c,c=h.r,u=h.e),o=u+m+1,d=g[o],f=n/2,c=c||0>o||null!=g[o+1],c=4>w?(null!=d||c)&&(0==w||w==(h.s<0?3:2)):d>f||d==f&&(4==w||c||6==w&&1&g[o-1]||w==(h.s<0?8:7)),1>o||!g[0])e=c?l("1",-m):"0";else{if(g.length=o,c)for(--n;++g[--o]>n;)g[o]=0,o||(++u,g.unshift(1));for(f=g.length;!g[--f];);for(d=0,e="";f>=d;e+=O.charAt(g[d++]));e=l(e,u)}return e}function _(e,n,t,i){var o,u,s,c,h;if(t=null!=t&&H(t,0,8,i,v)?0|t:k,!e.c)return e.toString();if(o=e.c[0],s=e.e,null==n)h=r(e.c),h=19==i||24==i&&B>=s?f(h,s):l(h,s);else if(e=U(new a(e),n,t),u=e.e,h=r(e.c),c=h.length,19==i||24==i&&(u>=n||B>=u)){for(;n>c;h+="0",c++);h=f(h,u)}else if(n-=s,h=l(h,u),u+1>c){if(--n>0)for(h+=".";n--;h+="0");}else if(n+=u-c,n>0)for(u+1==c&&(h+=".");n--;h+="0");return e.s<0&&o?"-"+h:h}function x(e,n){var t,r,i=0;for(u(e[0])&&(e=e[0]),t=new a(e[0]);++i<e.length;){if(r=new a(e[i]),!r.s){t=r;break}n.call(t,r)&&(t=r)}return t}function F(e,n,t,r,i){return(n>e||e>t||e!=c(e))&&L(r,(i||"decimal places")+(n>e||e>t?" out of range":" not an integer"),e),!0}function I(e,n,t){for(var r=1,i=n.length;!n[--i];n.pop());for(i=n[0];i>=10;i/=10,r++);return(t=r+t*y-1)>z?e.c=e.e=null:G>t?e.c=[e.e=0]:(e.e=t,e.c=n),e}function L(e,n,t){var r=new Error(["new BigNumber","cmp","config","div","divToInt","eq","gt","gte","lt","lte","minus","mod","plus","precision","random","round","shift","times","toDigits","toExponential","toFixed","toFormat","toFraction","pow","toPrecision","toString","BigNumber"][e]+"() "+n+": "+t);throw r.name="BigNumber Error",M=0,r}function U(e,n,t,r){var i,o,u,s,f,l,c,a=e.c,h=R;if(a){e:{for(i=1,s=a[0];s>=10;s/=10,i++);if(o=n-i,0>o)o+=y,u=n,f=a[l=0],c=f/h[i-u-1]%10|0;else if(l=d((o+1)/y),l>=a.length){if(!r)break e;for(;a.length<=l;a.push(0));f=c=0,i=1,o%=y,u=o-y+1}else{for(f=s=a[l],i=1;s>=10;s/=10,i++);o%=y,u=o-y+i,c=0>u?0:f/h[i-u-1]%10|0}if(r=r||0>n||null!=a[l+1]||(0>u?f:f%h[i-u-1]),r=4>t?(c||r)&&(0==t||t==(e.s<0?3:2)):c>5||5==c&&(4==t||r||6==t&&(o>0?u>0?f/h[i-u]:0:a[l-1])%10&1||t==(e.s<0?8:7)),1>n||!a[0])return a.length=0,r?(n-=e.e+1,a[0]=h[n%y],e.e=-n||0):a[0]=e.e=0,e;if(0==o?(a.length=l,s=1,l--):(a.length=l+1,s=h[y-o],a[l]=u>0?m(f/h[i-u]%h[u])*s:0),r)for(;;){if(0==l){for(o=1,u=a[0];u>=10;u/=10,o++);for(u=a[0]+=s,s=1;u>=10;u/=10,s++);o!=s&&(e.e++,a[0]==N&&(a[0]=1));break}if(a[l]+=s,a[l]!=N)break;a[l--]=0,s=1}for(o=a.length;0===a[--o];a.pop());}e.e>z?e.c=e.e=null:e.e<G&&(e.c=[e.e=0])}return e}var C,M=0,T=a.prototype,q=new a(1),P=20,k=4,B=-7,$=21,G=-1e7,z=1e7,j=!0,H=F,V=!1,W=1,J=100,X={decimalSeparator:".",groupSeparator:",",groupSize:3,secondaryGroupSize:0,fractionGroupSeparator:" ",fractionGroupSize:0};return a.another=n,a.ROUND_UP=0,a.ROUND_DOWN=1,a.ROUND_CEIL=2,a.ROUND_FLOOR=3,a.ROUND_HALF_UP=4,a.ROUND_HALF_DOWN=5,a.ROUND_HALF_EVEN=6,a.ROUND_HALF_CEIL=7,a.ROUND_HALF_FLOOR=8,a.EUCLID=9,a.config=function(){var e,n,t=0,r={},i=arguments,s=i[0],f=s&&"object"==typeof s?function(){return s.hasOwnProperty(n)?null!=(e=s[n]):void 0}:function(){return i.length>t?null!=(e=i[t++]):void 0};return f(n="DECIMAL_PLACES")&&H(e,0,E,2,n)&&(P=0|e),r[n]=P,f(n="ROUNDING_MODE")&&H(e,0,8,2,n)&&(k=0|e),r[n]=k,f(n="EXPONENTIAL_AT")&&(u(e)?H(e[0],-E,0,2,n)&&H(e[1],0,E,2,n)&&(B=0|e[0],$=0|e[1]):H(e,-E,E,2,n)&&(B=-($=0|(0>e?-e:e)))),r[n]=[B,$],f(n="RANGE")&&(u(e)?H(e[0],-E,-1,2,n)&&H(e[1],1,E,2,n)&&(G=0|e[0],z=0|e[1]):H(e,-E,E,2,n)&&(0|e?G=-(z=0|(0>e?-e:e)):j&&L(2,n+" cannot be zero",e))),r[n]=[G,z],f(n="ERRORS")&&(e===!!e||1===e||0===e?(M=0,H=(j=!!e)?F:o):j&&L(2,n+w,e)),r[n]=j,f(n="CRYPTO")&&(e===!!e||1===e||0===e?(V=!(!e||!h||"object"!=typeof h),e&&!V&&j&&L(2,"crypto unavailable",h)):j&&L(2,n+w,e)),r[n]=V,f(n="MODULO_MODE")&&H(e,0,9,2,n)&&(W=0|e),r[n]=W,f(n="POW_PRECISION")&&H(e,0,E,2,n)&&(J=0|e),r[n]=J,f(n="FORMAT")&&("object"==typeof e?X=e:j&&L(2,n+" not an object",e)),r[n]=X,r},a.max=function(){return x(arguments,T.lt)},a.min=function(){return x(arguments,T.gt)},a.random=function(){var e=9007199254740992,n=Math.random()*e&2097151?function(){return m(Math.random()*e)}:function(){return 8388608*(1073741824*Math.random()|0)+(8388608*Math.random()|0)};return function(e){var t,r,i,o,u,s=0,f=[],l=new a(q);if(e=null!=e&&H(e,0,E,14)?0|e:P,o=d(e/y),V)if(h&&h.getRandomValues){for(t=h.getRandomValues(new Uint32Array(o*=2));o>s;)u=131072*t[s]+(t[s+1]>>>11),u>=9e15?(r=h.getRandomValues(new Uint32Array(2)),t[s]=r[0],t[s+1]=r[1]):(f.push(u%1e14),s+=2);s=o/2}else if(h&&h.randomBytes){for(t=h.randomBytes(o*=7);o>s;)u=281474976710656*(31&t[s])+1099511627776*t[s+1]+4294967296*t[s+2]+16777216*t[s+3]+(t[s+4]<<16)+(t[s+5]<<8)+t[s+6],u>=9e15?h.randomBytes(7).copy(t,s):(f.push(u%1e14),s+=7);s=o/7}else j&&L(14,"crypto unavailable",h);if(!s)for(;o>s;)u=n(),9e15>u&&(f[s++]=u%1e14);for(o=f[--s],e%=y,o&&e&&(u=R[y-e],f[s]=m(o/u)*u);0===f[s];f.pop(),s--);if(0>s)f=[i=0];else{for(i=-1;0===f[0];f.shift(),i-=y);for(s=1,u=f[0];u>=10;u/=10,s++);y>s&&(i-=y-s)}return l.e=i,l.c=f,l}}(),C=function(){function e(e,n,t){var r,i,o,u,s=0,f=e.length,l=n%A,c=n/A|0;for(e=e.slice();f--;)o=e[f]%A,u=e[f]/A|0,r=c*o+u*l,i=l*o+r%A*A+s,s=(i/t|0)+(r/A|0)+c*u,e[f]=i%t;return s&&e.unshift(s),e}function n(e,n,t,r){var i,o;if(t!=r)o=t>r?1:-1;else for(i=o=0;t>i;i++)if(e[i]!=n[i]){o=e[i]>n[i]?1:-1;break}return o}function r(e,n,t,r){for(var i=0;t--;)e[t]-=i,i=e[t]<n[t]?1:0,e[t]=i*r+e[t]-n[t];for(;!e[0]&&e.length>1;e.shift());}return function(i,o,u,s,f){var l,c,h,g,p,d,w,v,b,O,S,R,A,E,D,_,x,F=i.s==o.s?1:-1,I=i.c,L=o.c;if(!(I&&I[0]&&L&&L[0]))return new a(i.s&&o.s&&(I?!L||I[0]!=L[0]:L)?I&&0==I[0]||!L?0*F:F/0:0/0);for(v=new a(F),b=v.c=[],c=i.e-o.e,F=u+c+1,f||(f=N,c=t(i.e/y)-t(o.e/y),F=F/y|0),h=0;L[h]==(I[h]||0);h++);if(L[h]>(I[h]||0)&&c--,0>F)b.push(1),g=!0;else{for(E=I.length,_=L.length,h=0,F+=2,p=m(f/(L[0]+1)),p>1&&(L=e(L,p,f),I=e(I,p,f),_=L.length,E=I.length),A=_,O=I.slice(0,_),S=O.length;_>S;O[S++]=0);x=L.slice(),x.unshift(0),D=L[0],L[1]>=f/2&&D++;do p=0,l=n(L,O,_,S),0>l?(R=O[0],_!=S&&(R=R*f+(O[1]||0)),p=m(R/D),p>1?(p>=f&&(p=f-1),d=e(L,p,f),w=d.length,S=O.length,l=n(d,O,w,S),1==l&&(p--,r(d,w>_?x:L,w,f))):(0==p&&(l=p=1),d=L.slice()),w=d.length,S>w&&d.unshift(0),r(O,d,S,f),-1==l&&(S=O.length,l=n(L,O,_,S),1>l&&(p++,r(O,S>_?x:L,S,f))),S=O.length):0===l&&(p++,O=[0]),b[h++]=p,l&&O[0]?O[S++]=I[A]||0:(O=[I[A]],S=1);while((A++<E||null!=O[0])&&F--);g=null!=O[0],b[0]||b.shift()}if(f==N){for(h=1,F=b[0];F>=10;F/=10,h++);U(v,u+(v.e=h+c*y-1)+1,s,g)}else v.e=c,v.r=+g;return v}}(),g=function(){var e=/^(-?)0([xbo])(\w[\w.]*$)/i,n=/^([^.]+)\.$/,t=/^\.([^.]+)$/,r=/^-?(Infinity|NaN)$/,i=/^\s*\+([\w.])|^\s+|\s+$/g;return function(o,u,s,f){var l,c=s?u:u.replace(i,"$1");if(r.test(c))o.s=isNaN(c)?null:0>c?-1:1;else{if(!s&&(c=c.replace(e,function(e,n,t){return l="x"==(t=t.toLowerCase())?16:"b"==t?2:8,f&&f!=l?e:n}),f&&(l=f,c=c.replace(n,"$1").replace(t,"0.$1")),u!=c))return new a(c,l);j&&L(M,"not a"+(f?" base "+f:"")+" number",u),o.s=null}o.c=o.e=null,M=0}}(),T.absoluteValue=T.abs=function(){var e=new a(this);return e.s<0&&(e.s=1),e},T.ceil=function(){return U(new a(this),this.e+1,2)},T.comparedTo=T.cmp=function(e,n){return M=1,i(this,new a(e,n))},T.decimalPlaces=T.dp=function(){var e,n,r=this.c;if(!r)return null;if(e=((n=r.length-1)-t(this.e/y))*y,n=r[n])for(;n%10==0;n/=10,e--);return 0>e&&(e=0),e},T.dividedBy=T.div=function(e,n){return M=3,C(this,new a(e,n),P,k)},T.dividedToIntegerBy=T.divToInt=function(e,n){return M=4,C(this,new a(e,n),0,1)},T.equals=T.eq=function(e,n){return M=5,0===i(this,new a(e,n))},T.floor=function(){return U(new a(this),this.e+1,3)},T.greaterThan=T.gt=function(e,n){return M=6,i(this,new a(e,n))>0},T.greaterThanOrEqualTo=T.gte=function(e,n){return M=7,1===(n=i(this,new a(e,n)))||0===n},T.isFinite=function(){return!!this.c},T.isInteger=T.isInt=function(){return!!this.c&&t(this.e/y)>this.c.length-2},T.isNaN=function(){return!this.s},T.isNegative=T.isNeg=function(){return this.s<0},T.isZero=function(){return!!this.c&&0==this.c[0]},T.lessThan=T.lt=function(e,n){return M=8,i(this,new a(e,n))<0},T.lessThanOrEqualTo=T.lte=function(e,n){return M=9,-1===(n=i(this,new a(e,n)))||0===n},T.minus=T.sub=function(e,n){var r,i,o,u,s=this,f=s.s;if(M=10,e=new a(e,n),n=e.s,!f||!n)return new a(0/0);if(f!=n)return e.s=-n,s.plus(e);var l=s.e/y,c=e.e/y,h=s.c,g=e.c;if(!l||!c){if(!h||!g)return h?(e.s=-n,e):new a(g?s:0/0);if(!h[0]||!g[0])return g[0]?(e.s=-n,e):new a(h[0]?s:3==k?-0:0)}if(l=t(l),c=t(c),h=h.slice(),f=l-c){for((u=0>f)?(f=-f,o=h):(c=l,o=g),o.reverse(),n=f;n--;o.push(0));o.reverse()}else for(i=(u=(f=h.length)<(n=g.length))?f:n,f=n=0;i>n;n++)if(h[n]!=g[n]){u=h[n]<g[n];break}if(u&&(o=h,h=g,g=o,e.s=-e.s),n=(i=g.length)-(r=h.length),n>0)for(;n--;h[r++]=0);for(n=N-1;i>f;){if(h[--i]<g[i]){for(r=i;r&&!h[--r];h[r]=n);--h[r],h[i]+=N}h[i]-=g[i]}for(;0==h[0];h.shift(),--c);return h[0]?I(e,h,c):(e.s=3==k?-1:1,e.c=[e.e=0],e)},T.modulo=T.mod=function(e,n){var t,r,i=this;return M=11,e=new a(e,n),!i.c||!e.s||e.c&&!e.c[0]?new a(0/0):!e.c||i.c&&!i.c[0]?new a(i):(9==W?(r=e.s,e.s=1,t=C(i,e,0,3),e.s=r,t.s*=r):t=C(i,e,0,W),i.minus(t.times(e)))},T.negated=T.neg=function(){var e=new a(this);return e.s=-e.s||null,e},T.plus=T.add=function(e,n){var r,i=this,o=i.s;if(M=12,e=new a(e,n),n=e.s,!o||!n)return new a(0/0);if(o!=n)return e.s=-n,i.minus(e);var u=i.e/y,s=e.e/y,f=i.c,l=e.c;if(!u||!s){if(!f||!l)return new a(o/0);if(!f[0]||!l[0])return l[0]?e:new a(f[0]?i:0*o)}if(u=t(u),s=t(s),f=f.slice(),o=u-s){for(o>0?(s=u,r=l):(o=-o,r=f),r.reverse();o--;r.push(0));r.reverse()}for(o=f.length,n=l.length,0>o-n&&(r=l,l=f,f=r,n=o),o=0;n;)o=(f[--n]=f[n]+l[n]+o)/N|0,f[n]%=N;return o&&(f.unshift(o),++s),I(e,f,s)},T.precision=T.sd=function(e){var n,t,r=this,i=r.c;if(null!=e&&e!==!!e&&1!==e&&0!==e&&(j&&L(13,"argument"+w,e),e!=!!e&&(e=null)),!i)return null;if(t=i.length-1,n=t*y+1,t=i[t]){for(;t%10==0;t/=10,n--);for(t=i[0];t>=10;t/=10,n++);}return e&&r.e+1>n&&(n=r.e+1),n},T.round=function(e,n){var t=new a(this);return(null==e||H(e,0,E,15))&&U(t,~~e+this.e+1,null!=n&&H(n,0,8,15,v)?0|n:k),t},T.shift=function(e){var n=this;return H(e,-S,S,16,"argument")?n.times("1e"+c(e)):new a(n.c&&n.c[0]&&(-S>e||e>S)?n.s*(0>e?0:1/0):n)},T.squareRoot=T.sqrt=function(){var e,n,i,o,u,s=this,f=s.c,l=s.s,c=s.e,h=P+4,g=new a("0.5");if(1!==l||!f||!f[0])return new a(!l||0>l&&(!f||f[0])?0/0:f?s:1/0);if(l=Math.sqrt(+s),0==l||l==1/0?(n=r(f),(n.length+c)%2==0&&(n+="0"),l=Math.sqrt(n),c=t((c+1)/2)-(0>c||c%2),l==1/0?n="1e"+c:(n=l.toExponential(),n=n.slice(0,n.indexOf("e")+1)+c),i=new a(n)):i=new a(l+""),i.c[0])for(c=i.e,l=c+h,3>l&&(l=0);;)if(u=i,i=g.times(u.plus(C(s,u,h,1))),r(u.c).slice(0,l)===(n=r(i.c)).slice(0,l)){if(i.e<c&&--l,n=n.slice(l-3,l+1),"9999"!=n&&(o||"4999"!=n)){(!+n||!+n.slice(1)&&"5"==n.charAt(0))&&(U(i,i.e+P+2,1),e=!i.times(i).eq(s));break}if(!o&&(U(u,u.e+P+2,0),u.times(u).eq(s))){i=u;break}h+=4,l+=4,o=1}return U(i,i.e+P+1,k,e)},T.times=T.mul=function(e,n){var r,i,o,u,s,f,l,c,h,g,p,d,m,w,v,b=this,O=b.c,S=(M=17,e=new a(e,n)).c;if(!(O&&S&&O[0]&&S[0]))return!b.s||!e.s||O&&!O[0]&&!S||S&&!S[0]&&!O?e.c=e.e=e.s=null:(e.s*=b.s,O&&S?(e.c=[0],e.e=0):e.c=e.e=null),e;for(i=t(b.e/y)+t(e.e/y),e.s*=b.s,l=O.length,g=S.length,g>l&&(m=O,O=S,S=m,o=l,l=g,g=o),o=l+g,m=[];o--;m.push(0));for(w=N,v=A,o=g;--o>=0;){for(r=0,p=S[o]%v,d=S[o]/v|0,s=l,u=o+s;u>o;)c=O[--s]%v,h=O[s]/v|0,f=d*c+h*p,c=p*c+f%v*v+m[u]+r,r=(c/w|0)+(f/v|0)+d*h,m[u--]=c%w;m[u]=r}return r?++i:m.shift(),I(e,m,i)},T.toDigits=function(e,n){var t=new a(this);return e=null!=e&&H(e,1,E,18,"precision")?0|e:null,n=null!=n&&H(n,0,8,18,v)?0|n:k,e?U(t,e,n):t},T.toExponential=function(e,n){return _(this,null!=e&&H(e,0,E,19)?~~e+1:null,n,19)},T.toFixed=function(e,n){return _(this,null!=e&&H(e,0,E,20)?~~e+this.e+1:null,n,20)},T.toFormat=function(e,n){var t=_(this,null!=e&&H(e,0,E,21)?~~e+this.e+1:null,n,21);if(this.c){var r,i=t.split("."),o=+X.groupSize,u=+X.secondaryGroupSize,s=X.groupSeparator,f=i[0],l=i[1],c=this.s<0,a=c?f.slice(1):f,h=a.length;if(u&&(r=o,o=u,u=r,h-=r),o>0&&h>0){for(r=h%o||o,f=a.substr(0,r);h>r;r+=o)f+=s+a.substr(r,o);u>0&&(f+=s+a.slice(r)),c&&(f="-"+f)}t=l?f+X.decimalSeparator+((u=+X.fractionGroupSize)?l.replace(new RegExp("\\d{"+u+"}\\B","g"),"$&"+X.fractionGroupSeparator):l):f}return t},T.toFraction=function(e){var n,t,i,o,u,s,f,l,c,h=j,g=this,p=g.c,d=new a(q),m=t=new a(q),w=f=new a(q);if(null!=e&&(j=!1,s=new a(e),j=h,(!(h=s.isInt())||s.lt(q))&&(j&&L(22,"max denominator "+(h?"out of range":"not an integer"),e),e=!h&&s.c&&U(s,s.e+1,1).gte(q)?s:null)),!p)return g.toString();for(c=r(p),o=d.e=c.length-g.e-1,d.c[0]=R[(u=o%y)<0?y+u:u],e=!e||s.cmp(d)>0?o>0?d:m:s,u=z,z=1/0,s=new a(c),f.c[0]=0;l=C(s,d,0,1),i=t.plus(l.times(w)),1!=i.cmp(e);)t=w,w=i,m=f.plus(l.times(i=m)),f=i,d=s.minus(l.times(i=d)),s=i;return i=C(e.minus(t),w,0,1),f=f.plus(i.times(m)),t=t.plus(i.times(w)),f.s=m.s=g.s,o*=2,n=C(m,w,o,k).minus(g).abs().cmp(C(f,t,o,k).minus(g).abs())<1?[m.toString(),w.toString()]:[f.toString(),t.toString()],z=u,n},T.toNumber=function(){var e=this;return+e||(e.s?0*e.s:0/0)},T.toPower=T.pow=function(e){var n,t,r=m(0>e?-e:+e),i=this;if(!H(e,-S,S,23,"exponent")&&(!isFinite(e)||r>S&&(e/=0)||parseFloat(e)!=e&&!(e=0/0)))return new a(Math.pow(+i,e));for(n=J?d(J/y+2):0,t=new a(q);;){if(r%2){if(t=t.times(i),!t.c)break;n&&t.c.length>n&&(t.c.length=n)}if(r=m(r/2),!r)break;i=i.times(i),n&&i.c&&i.c.length>n&&(i.c.length=n)}return 0>e&&(t=q.div(t)),n?U(t,J,k):t},T.toPrecision=function(e,n){return _(this,null!=e&&H(e,1,E,24,"precision")?0|e:null,n,24)},T.toString=function(e){var n,t=this,i=t.s,o=t.e;return null===o?i?(n="Infinity",0>i&&(n="-"+n)):n="NaN":(n=r(t.c),n=null!=e&&H(e,2,64,25,"base")?D(l(n,o),0|e,10,i):B>=o||o>=$?f(n,o):l(n,o),0>i&&t.c[0]&&(n="-"+n)),n},T.truncated=T.trunc=function(){return U(new a(this),this.e+1,1)},T.valueOf=T.toJSON=function(){return this.toString()},null!=e&&a.config(e),a}function t(e){var n=0|e;return e>0||e===n?n:n-1}function r(e){for(var n,t,r=1,i=e.length,o=e[0]+"";i>r;){for(n=e[r++]+"",t=y-n.length;t--;n="0"+n);o+=n}for(i=o.length;48===o.charCodeAt(--i););return o.slice(0,i+1||1)}function i(e,n){var t,r,i=e.c,o=n.c,u=e.s,s=n.s,f=e.e,l=n.e;if(!u||!s)return null;if(t=i&&!i[0],r=o&&!o[0],t||r)return t?r?0:-s:u;if(u!=s)return u;if(t=0>u,r=f==l,!i||!o)return r?0:!i^t?1:-1;if(!r)return f>l^t?1:-1;for(s=(f=i.length)<(l=o.length)?f:l,u=0;s>u;u++)if(i[u]!=o[u])return i[u]>o[u]^t?1:-1;return f==l?0:f>l^t?1:-1}function o(e,n,t){return(e=c(e))>=n&&t>=e}function u(e){return"[object Array]"==Object.prototype.toString.call(e)}function s(e,n,t){for(var r,i,o=[0],u=0,s=e.length;s>u;){for(i=o.length;i--;o[i]*=n);for(o[r=0]+=O.indexOf(e.charAt(u++));r<o.length;r++)o[r]>t-1&&(null==o[r+1]&&(o[r+1]=0),o[r+1]+=o[r]/t|0,o[r]%=t)}return o.reverse()}function f(e,n){return(e.length>1?e.charAt(0)+"."+e.slice(1):e)+(0>n?"e":"e+")+n}function l(e,n){var t,r;if(0>n){for(r="0.";++n;r+="0");e=r+e}else if(t=e.length,++n>t){for(r="0",n-=t;--n;r+="0");e+=r}else t>n&&(e=e.slice(0,n)+"."+e.slice(n));return e}function c(e){return e=parseFloat(e),0>e?d(e):m(e)}var a,h,g,p=/^-?(\d+(\.\d*)?|\.\d+)(e[+-]?\d+)?$/i,d=Math.ceil,m=Math.floor,w=" not a boolean or binary digit",v="rounding mode",b="number type has more than 15 significant digits",O="0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ$_",N=1e14,y=14,S=9007199254740991,R=[1,10,100,1e3,1e4,1e5,1e6,1e7,1e8,1e9,1e10,1e11,1e12,1e13],A=1e7,E=1e9;if(a=n(),"function"==typeof define&&define.amd)define(function(){return a});else if("undefined"!=typeof module&&module.exports){if(module.exports=a,!h)try{h=require("crypto")}catch(D){}}else e.BigNumber=a}(this);
+//# sourceMappingURL=doc/bignumber.js.map`
diff --git a/jsre/ethereum_js.go b/jsre/ethereum_js.go
new file mode 100644
index 000000000..0c38cd0e4
--- /dev/null
+++ b/jsre/ethereum_js.go
@@ -0,0 +1,4 @@
+package jsre
+
+const Ethereum_JS = `
+require=function t(e,n,r){function o(a,s){if(!n[a]){if(!e[a]){var u="function"==typeof require&&require;if(!s&&u)return u(a,!0);if(i)return i(a,!0);var c=new Error("Cannot find module '"+a+"'");throw c.code="MODULE_NOT_FOUND",c}var l=n[a]={exports:{}};e[a][0].call(l.exports,function(t){var n=e[a][1][t];return o(n?n:t)},l,l.exports,t,e,n,r)}return n[a].exports}for(var i="function"==typeof require&&require,a=0;a<r.length;a++)o(r[a]);return o}({1:[function(t,e){var n=t("../utils/utils"),r=t("../utils/config"),o=t("./types"),i=t("./formatters"),a=function(t){throw new Error("parser does not support type: "+t)},s=function(t){return"[]"===t.slice(-2)},u=function(t,e){return s(t)||"bytes"===t?i.formatInputInt(e.length):""},c=o.inputTypes(),l=function(t,e){var n="",r="",o="";return t.forEach(function(t,r){n+=u(t.type,e[r])}),t.forEach(function(n,i){for(var u=!1,l=0;l<c.length&&!u;l++)u=c[l].type(t[i].type,e[i]);u||a(t[i].type);var f=c[l-1].format;s(t[i].type)?o+=e[i].reduce(function(t,e){return t+f(e)},""):"bytes"===t[i].type?o+=f(e[i]):r+=f(e[i])}),n+=r+o},f=function(t){return s(t)||"bytes"===t?2*r.ETH_PADDING:0},p=o.outputTypes(),m=function(t,e){e=e.slice(2);var n=[],u=2*r.ETH_PADDING,c=t.reduce(function(t,e){return t+f(e.type)},0),l=e.slice(0,c);return e=e.slice(c),t.forEach(function(r,c){for(var f=!1,m=0;m<p.length&&!f;m++)f=p[m].type(t[c].type);f||a(t[c].type);var h=p[m-1].format;if(s(t[c].type)){var d=i.formatOutputUInt(l.slice(0,u));l=l.slice(u);for(var g=[],v=0;d>v;v++)g.push(h(e.slice(0,u))),e=e.slice(u);n.push(g)}else o.prefixedType("bytes")(t[c].type)?(l=l.slice(u),n.push(h(e.slice(0,u))),e=e.slice(u)):(n.push(h(e.slice(0,u))),e=e.slice(u))}),n},h=function(t){var e={};return t.forEach(function(t){var r=n.extractDisplayName(t.name),o=n.extractTypeName(t.name),i=function(){var e=Array.prototype.slice.call(arguments);return l(t.inputs,e)};void 0===e[r]&&(e[r]=i),e[r][o]=i}),e},d=function(t){var e={};return t.forEach(function(t){var r=n.extractDisplayName(t.name),o=n.extractTypeName(t.name),i=function(e){return m(t.outputs,e)};void 0===e[r]&&(e[r]=i),e[r][o]=i}),e};e.exports={inputParser:h,outputParser:d,formatInput:l,formatOutput:m}},{"../utils/config":5,"../utils/utils":6,"./formatters":2,"./types":3}],2:[function(t,e){var n=t("bignumber.js"),r=t("../utils/utils"),o=t("../utils/config"),i=function(t){var e=2*o.ETH_PADDING;return n.config(o.ETH_BIGNUMBER_ROUNDING_MODE),r.padLeft(r.toTwosComplement(t).round().toString(16),e)},a=function(t){return r.fromAscii(t,o.ETH_PADDING).substr(2)},s=function(t){return"000000000000000000000000000000000000000000000000000000000000000"+(t?"1":"0")},u=function(t){return i(new n(t).times(new n(2).pow(128)))},c=function(t){return"1"===new n(t.substr(0,1),16).toString(2).substr(0,1)},l=function(t){return t=t||"0",c(t)?new n(t,16).minus(new n("ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff",16)).minus(1):new n(t,16)},f=function(t){return t=t||"0",new n(t,16)},p=function(t){return l(t).dividedBy(new n(2).pow(128))},m=function(t){return f(t).dividedBy(new n(2).pow(128))},h=function(t){return"0x"+t},d=function(t){return"0000000000000000000000000000000000000000000000000000000000000001"===t?!0:!1},g=function(t){return r.toAscii(t)},v=function(t){return"0x"+t.slice(t.length-40,t.length)};e.exports={formatInputInt:i,formatInputString:a,formatInputBool:s,formatInputReal:u,formatOutputInt:l,formatOutputUInt:f,formatOutputReal:p,formatOutputUReal:m,formatOutputHash:h,formatOutputBool:d,formatOutputString:g,formatOutputAddress:v}},{"../utils/config":5,"../utils/utils":6,"bignumber.js":"bignumber.js"}],3:[function(t,e){var n=t("./formatters"),r=function(t){return function(e){return 0===e.indexOf(t)}},o=function(t){return function(e){return t===e}},i=function(){return[{type:r("uint"),format:n.formatInputInt},{type:r("int"),format:n.formatInputInt},{type:r("bytes"),format:n.formatInputString},{type:r("real"),format:n.formatInputReal},{type:r("ureal"),format:n.formatInputReal},{type:o("address"),format:n.formatInputInt},{type:o("bool"),format:n.formatInputBool}]},a=function(){return[{type:r("uint"),format:n.formatOutputUInt},{type:r("int"),format:n.formatOutputInt},{type:r("bytes"),format:n.formatOutputString},{type:r("real"),format:n.formatOutputReal},{type:r("ureal"),format:n.formatOutputUReal},{type:o("address"),format:n.formatOutputAddress},{type:o("bool"),format:n.formatOutputBool}]};e.exports={prefixedType:r,namedType:o,inputTypes:i,outputTypes:a}},{"./formatters":2}],4:[function(t,e,n){"use strict";n.XMLHttpRequest="undefined"==typeof XMLHttpRequest?{}:XMLHttpRequest},{}],5:[function(t,e){var n=t("bignumber.js"),r=["wei","Kwei","Mwei","Gwei","szabo","finney","ether","grand","Mether","Gether","Tether","Pether","Eether","Zether","Yether","Nether","Dether","Vether","Uether"];e.exports={ETH_PADDING:32,ETH_SIGNATURE_LENGTH:4,ETH_UNITS:r,ETH_BIGNUMBER_ROUNDING_MODE:{ROUNDING_MODE:n.ROUND_DOWN},ETH_POLLING_TIMEOUT:1e3,ETH_DEFAULTBLOCK:"latest"}},{"bignumber.js":"bignumber.js"}],6:[function(t,e){var n=t("bignumber.js"),r={wei:"1",kwei:"1000",ada:"1000",mwei:"1000000",babbage:"1000000",gwei:"1000000000",shannon:"1000000000",szabo:"1000000000000",finney:"1000000000000000",ether:"1000000000000000000",kether:"1000000000000000000000",grand:"1000000000000000000000",einstein:"1000000000000000000000",mether:"1000000000000000000000000",gether:"1000000000000000000000000000",tether:"1000000000000000000000000000000"},o=function(t,e,n){return new Array(e-t.length+1).join(n?n:"0")+t},i=function(t,e){for(var n=!1,r=0;r<t.length&&!n;r++)n=e(t[r]);return n?r-1:-1},a=function(t){var e="",n=0,r=t.length;for("0x"===t.substring(0,2)&&(n=2);r>n;n+=2){var o=parseInt(t.substr(n,2),16);if(0===o)break;e+=String.fromCharCode(o)}return e},s=function(t){for(var e="",n=0;n<t.length;n++){var r=t.charCodeAt(n).toString(16);e+=r.length<2?"0"+r:r}return e},u=function(t,e){e=void 0===e?0:e;for(var n=s(t);n.length<2*e;)n+="00";return"0x"+n},c=function(t){var e=t.indexOf("(");return-1!==e?t.substr(0,e):t},l=function(t){var e=t.indexOf("(");return-1!==e?t.substr(e+1,t.length-1-(e+1)).replace(" ",""):""},f=function(t){return t.filter(function(t){return"function"===t.type})},p=function(t){return t.filter(function(t){return"event"===t.type})},m=function(t){return b(t).toNumber()},h=function(t){var e=b(t),n=e.toString(16);return e.lessThan(0)?"-0x"+n.substr(1):"0x"+n},d=function(t){if(O(t))return h(+t);if(F(t))return h(t);if(N(t))return u(JSON.stringify(t));if(_(t)){if(0===t.indexOf("-0x"))return h(t);if(!isFinite(t))return u(t)}return h(t)},g=function(t){t=t?t.toLowerCase():"ether";var e=r[t];if(void 0===e)throw new Error("This unit doesn't exists, please use the one of the following units"+JSON.stringify(r,null,2));return new n(e,10)},v=function(t,e){var n=b(t).dividedBy(g(e));return F(t)?n:n.toString(10)},y=function(t,e){var n=b(t).times(g(e));return F(t)?n:n.toString(10)},b=function(t){return t=t||0,F(t)?t:!_(t)||0!==t.indexOf("0x")&&0!==t.indexOf("-0x")?new n(t.toString(10),10):new n(t.replace("0x",""),16)},w=function(t){var e=b(t);return e.lessThan(0)?new n("ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff",16).plus(e).plus(1):e},x=function(t){return/^0x[0-9a-f]{40}$/.test(t)},I=function(t){return x(t)?t:/^[0-9a-f]{40}$/.test(t)?"0x"+t:"0x"+o(d(t).substr(2),40)},F=function(t){return t instanceof n||t&&t.constructor&&"BigNumber"===t.constructor.name},_=function(t){return"string"==typeof t||t&&t.constructor&&"String"===t.constructor.name},T=function(t){return"function"==typeof t},N=function(t){return"object"==typeof t},O=function(t){return"boolean"==typeof t},B=function(t){return t instanceof Array},D=function(t){try{return!!JSON.parse(t)}catch(e){return!1}};e.exports={padLeft:o,findIndex:i,toHex:d,toDecimal:m,fromDecimal:h,toAscii:a,fromAscii:u,extractDisplayName:c,extractTypeName:l,filterFunctions:f,filterEvents:p,toWei:y,fromWei:v,toBigNumber:b,toTwosComplement:w,toAddress:I,isBigNumber:F,isAddress:x,isFunction:T,isString:_,isObject:N,isBoolean:O,isArray:B,isJson:D}},{"bignumber.js":"bignumber.js"}],7:[function(t,e){e.exports={version:"0.2.2"}},{}],8:[function(t,e){var n=t("./version.json"),r=t("./web3/net"),o=t("./web3/eth"),i=t("./web3/db"),a=t("./web3/shh"),s=t("./web3/watches"),u=t("./web3/filter"),c=t("./utils/utils"),l=t("./web3/formatters"),f=t("./web3/requestmanager"),p=t("./utils/config"),m=t("./web3/method"),h=t("./web3/property"),d=[new m({name:"sha3",call:"web3_sha3",params:1})],g=[new h({name:"version.client",getter:"web3_clientVersion"}),new h({name:"version.network",getter:"net_version",inputFormatter:c.toDecimal}),new h({name:"version.ethereum",getter:"eth_version",inputFormatter:c.toDecimal}),new h({name:"version.whisper",getter:"shh_version",inputFormatter:c.toDecimal})],v=function(t,e){e.forEach(function(e){e.attachToObject(t)})},y=function(t,e){e.forEach(function(e){e.attachToObject(t)})},b={};b.providers={},b.version={},b.version.api=n.version,b.eth={},b.eth.filter=function(t,e,n,r){return t._isEvent?t(e,n):new u(t,s.eth(),r||l.outputLogFormatter)},b.shh={},b.shh.filter=function(t){return new u(t,s.shh(),l.outputPostFormatter)},b.net={},b.db={},b.setProvider=function(t){f.getInstance().setProvider(t)},b.reset=function(){f.getInstance().reset()},b.toHex=c.toHex,b.toAscii=c.toAscii,b.fromAscii=c.fromAscii,b.toDecimal=c.toDecimal,b.fromDecimal=c.fromDecimal,b.toBigNumber=c.toBigNumber,b.toWei=c.toWei,b.fromWei=c.fromWei,b.isAddress=c.isAddress,Object.defineProperty(b.eth,"defaultBlock",{get:function(){return p.ETH_DEFAULTBLOCK},set:function(t){return p.ETH_DEFAULTBLOCK=t,p.ETH_DEFAULTBLOCK}}),v(b,d),y(b,g),v(b.net,r.methods),y(b.net,r.properties),v(b.eth,o.methods),y(b.eth,o.properties),v(b.db,i.methods),v(b.shh,a.methods),e.exports=b},{"./utils/config":5,"./utils/utils":6,"./version.json":7,"./web3/db":10,"./web3/eth":12,"./web3/filter":14,"./web3/formatters":15,"./web3/method":18,"./web3/net":19,"./web3/property":20,"./web3/requestmanager":22,"./web3/shh":23,"./web3/watches":25}],9:[function(t,e){function n(t,e){t.forEach(function(t){if(-1===t.name.indexOf("(")){var e=t.name,n=t.inputs.map(function(t){return t.type}).join();t.name=e+"("+n+")"}});var n={};return u(n),c(n,t,e),l(n,t,e),f(n,t,e),n}var r=t("../web3"),o=t("../solidity/abi"),i=t("../utils/utils"),a=t("./event"),s=t("./signature"),u=function(t){t.call=function(e){return t._isTransaction=!1,t._options=e,t},t.sendTransaction=function(e){return t._isTransaction=!0,t._options=e,t}},c=function(t,e,n){var a=o.inputParser(e),u=o.outputParser(e);i.filterFunctions(e).forEach(function(e){var o=i.extractDisplayName(e.name),c=i.extractTypeName(e.name),l=function(){var i=Array.prototype.slice.call(arguments),l=s.functionSignatureFromAscii(e.name),f=a[o][c].apply(null,i),p=t._options||{};p.to=n,p.data=l+f;var m=t._isTransaction===!0||t._isTransaction!==!1&&!e.constant,h=p.collapse!==!1;if(t._options={},t._isTransaction=null,m)return void r.eth.sendTransaction(p);var d=r.eth.call(p),g=u[o][c](d);return h&&(1===g.length?g=g[0]:0===g.length&&(g=null)),g};void 0===t[o]&&(t[o]=l),t[o][c]=l})},l=function(t,e,n){t.address=n,t._onWatchEventResult=function(t){var n=event.getMatchingEvent(i.filterEvents(e)),r=a.outputParser(n);return r(t)},Object.defineProperty(t,"topics",{get:function(){return i.filterEvents(e).map(function(t){return s.eventSignatureFromAscii(t.name)})}})},f=function(t,e,n){i.filterEvents(e).forEach(function(e){var o=function(){var t=Array.prototype.slice.call(arguments),o=s.eventSignatureFromAscii(e.name),i=a.inputParser(n,o,e),u=i.apply(null,t),c=function(t){var n=a.outputParser(e);return n(t)};return r.eth.filter(u,void 0,void 0,c)};o._isEvent=!0;var u=i.extractDisplayName(e.name),c=i.extractTypeName(e.name);void 0===t[u]&&(t[u]=o),t[u][c]=o})},p=function(t){return n.bind(null,t)};e.exports=p},{"../solidity/abi":1,"../utils/utils":6,"../web3":8,"./event":13,"./signature":24}],10:[function(t,e){var n=t("./method"),r=new n({name:"putString",call:"db_putString",params:3}),o=new n({name:"getString",call:"db_getString",params:2}),i=new n({name:"putHex",call:"db_putHex",params:3}),a=new n({name:"getHex",call:"db_getHex",params:2}),s=[r,o,i,a];e.exports={methods:s}},{"./method":18}],11:[function(t,e){var n=t("../utils/utils");e.exports={InvalidNumberOfParams:new Error("Invalid number of input parameters"),InvalidProvider:new Error("Providor not set or invalid"),InvalidResponse:function(t){var e="Invalid JSON RPC response";return n.isObject(t)&&t.error&&t.error.message&&(e=t.error.message),new Error(e)}}},{"../utils/utils":6}],12:[function(t,e){"use strict";var n=t("./formatters"),r=t("../utils/utils"),o=t("./method"),i=t("./property"),a=function(t){return r.isString(t[0])&&0===t[0].indexOf("0x")?"eth_getBlockByHash":"eth_getBlockByNumber"},s=function(t){return r.isString(t[0])&&0===t[0].indexOf("0x")?"eth_getTransactionByBlockHashAndIndex":"eth_getTransactionByBlockNumberAndIndex"},u=function(t){return r.isString(t[0])&&0===t[0].indexOf("0x")?"eth_getUncleByBlockHashAndIndex":"eth_getUncleByBlockNumberAndIndex"},c=function(t){return r.isString(t[0])&&0===t[0].indexOf("0x")?"eth_getBlockTransactionCountByHash":"eth_getBlockTransactionCountByNumber"},l=function(t){return r.isString(t[0])&&0===t[0].indexOf("0x")?"eth_getUncleCountByBlockHash":"eth_getUncleCountByBlockNumber"},f=new o({name:"getBalance",call:"eth_getBalance",params:2,inputFormatter:[r.toAddress,n.inputDefaultBlockNumberFormatter],outputFormatter:n.outputBigNumberFormatter}),p=new o({name:"getStorageAt",call:"eth_getStorageAt",params:3,inputFormatter:[null,r.toHex,n.inputDefaultBlockNumberFormatter]}),m=new o({name:"getCode",call:"eth_getCode",params:2,inputFormatter:[r.toAddress,n.inputDefaultBlockNumberFormatter]}),h=new o({name:"getBlock",call:a,params:2,inputFormatter:[r.toHex,function(t){return!!t}],outputFormatter:n.outputBlockFormatter}),d=new o({name:"getUncle",call:u,params:3,inputFormatter:[r.toHex,r.toHex,function(t){return!!t}],outputFormatter:n.outputBlockFormatter}),g=new o({name:"getCompilers",call:"eth_getCompilers",params:0}),v=new o({name:"getBlockTransactionCount",call:c,params:1,inputFormatter:[r.toHex],outputFormatter:r.toDecimal}),y=new o({name:"getBlockUncleCount",call:l,params:1,inputFormatter:[r.toHex],outputFormatter:r.toDecimal}),b=new o({name:"getTransaction",call:"eth_getTransactionByHash",params:1,outputFormatter:n.outputTransactionFormatter}),w=new o({name:"getTransactionFromBlock",call:s,params:2,inputFormatter:[r.toHex,r.toHex],outputFormatter:n.outputTransactionFormatter}),x=new o({name:"getTransactionCount",call:"eth_getTransactionCount",params:2,inputFormatter:[null,n.inputDefaultBlockNumberFormatter],outputFormatter:r.toDecimal}),I=new o({name:"sendTransaction",call:"eth_sendTransaction",params:1,inputFormatter:[n.inputTransactionFormatter]}),F=new o({name:"call",call:"eth_call",params:2,inputFormatter:[n.inputTransactionFormatter,n.inputDefaultBlockNumberFormatter]}),_=new o({name:"compile.solidity",call:"eth_compileSolidity",params:1}),T=new o({name:"compile.lll",call:"eth_compileLLL",params:1}),N=new o({name:"compile.serpent",call:"eth_compileSerpent",params:1}),O=new o({name:"flush",call:"eth_flush",params:0}),B=[f,p,m,h,d,g,v,y,b,w,x,F,I,_,T,N,O],D=[new i({name:"coinbase",getter:"eth_coinbase"}),new i({name:"mining",getter:"eth_mining"}),new i({name:"gasPrice",getter:"eth_gasPrice",outputFormatter:n.inputNumberFormatter}),new i({name:"accounts",getter:"eth_accounts"}),new i({name:"blockNumber",getter:"eth_blockNumber",outputFormatter:r.toDecimal})];e.exports={methods:B,properties:D}},{"../utils/utils":6,"./formatters":15,"./method":18,"./property":20}],13:[function(t,e){var n=t("../solidity/abi"),r=t("../utils/utils"),o=t("./signature"),i=function(t,e){return t.filter(function(t){return t.indexed===e})},a=function(t,e){var n=r.findIndex(t,function(t){return t.name===e});return-1===n?void console.error("indexed param with name "+e+" not found"):t[n]},s=function(t,e){return Object.keys(e).map(function(r){var o=[a(i(t.inputs,!0),r)],s=e[r];return s instanceof Array?s.map(function(t){return n.formatInput(o,[t])}):"0x"+n.formatInput(o,[s])})},u=function(t,e,n){return function(r,o){var i=o||{};return i.address=t,i.topics=[],i.topics.push(e),r&&(i.topics=i.topics.concat(s(n,r))),i}},c=function(t,e,n){var r=e.slice(),o=n.slice();return t.reduce(function(t,e){var n;return n=e.indexed?r.splice(0,1)[0]:o.splice(0,1)[0],t[e.name]=n,t},{})},l=function(t){return function(e){var o={event:r.extractDisplayName(t.name),number:e.number,hash:e.hash,args:{}};if(!e.topics)return o;e.data=e.data||"";var a=i(t.inputs,!0),s="0x"+e.topics.slice(1,e.topics.length).map(function(t){return t.slice(2)}).join(""),u=n.formatOutput(a,s),l=i(t.inputs,!1),f=n.formatOutput(l,e.data);return o.args=c(t.inputs,u,f),o}},f=function(t,e){for(var n=0;n<t.length;n++){var r=o.eventSignatureFromAscii(t[n].name);if(r===e.topics[0])return t[n]}return void 0};e.exports={inputParser:u,outputParser:l,getMatchingEvent:f}},{"../solidity/abi":1,"../utils/utils":6,"./signature":24}],14:[function(t,e){var n=t("./requestmanager"),r=t("./formatters"),o=t("../utils/utils"),i=function(t){return o.isString(t)?t:(t=t||{},t.topics=t.topics||[],t.topics=t.topics.map(function(t){return o.toHex(t)}),{topics:t.topics,to:t.to,address:t.address,fromBlock:r.inputBlockNumberFormatter(t.fromBlock),toBlock:r.inputBlockNumberFormatter(t.toBlock)})},a=function(t,e,n){var r={};e.forEach(function(t){t.attachToObject(r)}),this.options=i(t),this.implementation=r,this.callbacks=[],this.formatter=n,this.filterId=this.implementation.newFilter(this.options)};a.prototype.watch=function(t){this.callbacks.push(t);var e=this,r=function(t,n){return t?e.callbacks.forEach(function(e){e(t)}):void n.forEach(function(t){t=e.formatter?e.formatter(t):t,e.callbacks.forEach(function(e){e(null,t)})})};n.getInstance().startPolling({method:this.implementation.poll.call,params:[this.filterId]},this.filterId,r,this.stopWatching.bind(this))},a.prototype.stopWatching=function(){n.getInstance().stopPolling(this.filterId),this.implementation.uninstallFilter(this.filterId),this.callbacks=[]},a.prototype.get=function(){var t=this.implementation.getLogs(this.filterId),e=this;return t.map(function(t){return e.formatter?e.formatter(t):t})},e.exports=a},{"../utils/utils":6,"./formatters":15,"./requestmanager":22}],15:[function(t,e){var n=t("../utils/utils"),r=t("../utils/config"),o=function(t){return n.toBigNumber(t)},i=function(t){return"latest"===t||"pending"===t||"earliest"===t},a=function(t){return void 0===t?r.ETH_DEFAULTBLOCK:s(t)},s=function(t){return void 0===t?void 0:i(t)?t:n.toHex(t)},u=function(t){return t.code&&(t.data=t.code,delete t.code),["gasPrice","gas","value"].filter(function(e){return void 0!==t[e]}).forEach(function(e){t[e]=n.fromDecimal(t[e])}),t},c=function(t){return t.blockNumber=n.toDecimal(t.blockNumber),t.transactionIndex=n.toDecimal(t.transactionIndex),t.gas=n.toDecimal(t.gas),t.gasPrice=n.toBigNumber(t.gasPrice),t.value=n.toBigNumber(t.value),t},l=function(t){return t.gasLimit=n.toDecimal(t.gasLimit),t.gasUsed=n.toDecimal(t.gasUsed),t.size=n.toDecimal(t.size),t.timestamp=n.toDecimal(t.timestamp),t.number=n.toDecimal(t.number),t.minGasPrice=n.toBigNumber(t.minGasPrice),t.difficulty=n.toBigNumber(t.difficulty),t.totalDifficulty=n.toBigNumber(t.totalDifficulty),n.isArray(t.transactions)&&t.transactions.forEach(function(t){return n.isString(t)?void 0:c(t)}),t},f=function(t){return null===t?null:(t.blockNumber=n.toDecimal(t.blockNumber),t.transactionIndex=n.toDecimal(t.transactionIndex),t.logIndex=n.toDecimal(t.logIndex),t)},p=function(t){return t.payload=n.toHex(t.payload),t.ttl=n.fromDecimal(t.ttl),t.priority=n.fromDecimal(t.priority),n.isArray(t.topics)||(t.topics=[t.topics]),t.topics=t.topics.map(function(t){return n.fromAscii(t)}),t},m=function(t){return t.expiry=n.toDecimal(t.expiry),t.sent=n.toDecimal(t.sent),t.ttl=n.toDecimal(t.ttl),t.workProved=n.toDecimal(t.workProved),t.payloadRaw=t.payload,t.payload=n.toAscii(t.payload),n.isJson(t.payload)&&(t.payload=JSON.parse(t.payload)),t.topics=t.topics.map(function(t){return n.toAscii(t)}),t};e.exports={inputDefaultBlockNumberFormatter:a,inputBlockNumberFormatter:s,inputTransactionFormatter:u,inputPostFormatter:p,outputBigNumberFormatter:o,outputTransactionFormatter:c,outputBlockFormatter:l,outputLogFormatter:f,outputPostFormatter:m}},{"../utils/config":5,"../utils/utils":6}],16:[function(t,e){"use strict";var n=t("xmlhttprequest").XMLHttpRequest,r=function(t){this.host=t||"http://localhost:8080"};r.prototype.send=function(t){var e=new n;return e.open("POST",this.host,!1),e.send(JSON.stringify(t)),JSON.parse(e.responseText)},r.prototype.sendAsync=function(t,e){var r=new n;r.onreadystatechange=function(){4===r.readyState&&e(null,JSON.parse(r.responseText))},r.open("POST",this.host,!0),r.send(JSON.stringify(t))},e.exports=r},{xmlhttprequest:4}],17:[function(t,e){var n=function(){return arguments.callee._singletonInstance?arguments.callee._singletonInstance:(arguments.callee._singletonInstance=this,void(this.messageId=1))};n.getInstance=function(){var t=new n;return t},n.prototype.toPayload=function(t,e){return t||console.error("jsonrpc method should be specified!"),{jsonrpc:"2.0",method:t,params:e||[],id:this.messageId++}},n.prototype.isValidResponse=function(t){return!!t&&!t.error&&"2.0"===t.jsonrpc&&"number"==typeof t.id&&void 0!==t.result},n.prototype.toBatchPayload=function(t){var e=this;return t.map(function(t){return e.toPayload(t.method,t.params)})},e.exports=n},{}],18:[function(t,e){var n=t("./requestmanager"),r=t("../utils/utils"),o=t("./errors"),i=function(t){this.name=t.name,this.call=t.call,this.params=t.params||0,this.inputFormatter=t.inputFormatter,this.outputFormatter=t.outputFormatter};i.prototype.getCall=function(t){return r.isFunction(this.call)?this.call(t):this.call},i.prototype.extractCallback=function(t){return r.isFunction(t[t.length-1])?t.pop():null},i.prototype.validateArgs=function(t){if(t.length!==this.params)throw o.InvalidNumberOfParams},i.prototype.formatInput=function(t){return this.inputFormatter?this.inputFormatter.map(function(e,n){return e?e(t[n]):t[n]}):t},i.prototype.formatOutput=function(t){return this.outputFormatter&&null!==t?this.outputFormatter(t):t},i.prototype.attachToObject=function(t){var e=this.send.bind(this);e.call=this.call;var n=this.name.split(".");n.length>1?(t[n[0]]=t[n[0]]||{},t[n[0]][n[1]]=e):t[n[0]]=e},i.prototype.toPayload=function(t){var e=this.getCall(t),n=this.extractCallback(t),r=this.formatInput(t);return this.validateArgs(r),{method:e,params:r,callback:n}},i.prototype.send=function(){var t=this.toPayload(Array.prototype.slice.call(arguments));if(t.callback){var e=this;return n.getInstance().sendAsync(t,function(n,r){t.callback(null,e.formatOutput(r))})}return this.formatOutput(n.getInstance().send(t))},e.exports=i},{"../utils/utils":6,"./errors":11,"./requestmanager":22}],19:[function(t,e){var n=t("../utils/utils"),r=t("./property"),o=[],i=[new r({name:"listening",getter:"net_listening"}),new r({name:"peerCount",getter:"net_peerCount",outputFormatter:n.toDecimal})];e.exports={methods:o,properties:i}},{"../utils/utils":6,"./property":20}],20:[function(t,e){var n=t("./requestmanager"),r=function(t){this.name=t.name,this.getter=t.getter,this.setter=t.setter,this.outputFormatter=t.outputFormatter,this.inputFormatter=t.inputFormatter};r.prototype.formatInput=function(t){return this.inputFormatter?this.inputFormatter(t):t},r.prototype.formatOutput=function(t){return this.outputFormatter&&null!==t?this.outputFormatter(t):t},r.prototype.attachToObject=function(t){var e={get:this.get.bind(this),set:this.set.bind(this)},n=this.name.split(".");n.length>1?(t[n[0]]=t[n[0]]||{},Object.defineProperty(t[n[0]],n[1],e)):Object.defineProperty(t,n[0],e)},r.prototype.get=function(){return this.formatOutput(n.getInstance().send({method:this.getter}))},r.prototype.set=function(t){return n.getInstance().send({method:this.setter,params:[this.formatInput(t)]})},e.exports=r},{"./requestmanager":22}],21:[function(t,e){var n=function(){};n.prototype.send=function(t){var e=navigator.qt.callMethod(JSON.stringify(t));return JSON.parse(e)},e.exports=n},{}],22:[function(t,e){var n=t("./jsonrpc"),r=t("../utils/utils"),o=t("../utils/config"),i=t("./errors"),a=function(t){return arguments.callee._singletonInstance?arguments.callee._singletonInstance:(arguments.callee._singletonInstance=this,this.provider=t,this.polls=[],this.timeout=null,void this.poll())};a.getInstance=function(){var t=new a;return t},a.prototype.send=function(t){if(!this.provider)return console.error(i.InvalidProvider),null;var e=n.getInstance().toPayload(t.method,t.params),r=this.provider.send(e);if(!n.getInstance().isValidResponse(r))throw i.InvalidResponse(r);return r.result},a.prototype.sendAsync=function(t,e){if(!this.provider)return e(i.InvalidProvider);var r=n.getInstance().toPayload(t.method,t.params);this.provider.sendAsync(r,function(t,r){return t?e(t):n.getInstance().isValidResponse(r)?void e(null,r.result):e(i.InvalidResponse(r))})},a.prototype.setProvider=function(t){this.provider=t},a.prototype.startPolling=function(t,e,n,r){this.polls.push({data:t,id:e,callback:n,uninstall:r})},a.prototype.stopPolling=function(t){for(var e=this.polls.length;e--;){var n=this.polls[e];n.id===t&&this.polls.splice(e,1)}},a.prototype.reset=function(){this.polls.forEach(function(t){t.uninstall(t.id)}),this.polls=[],this.timeout&&(clearTimeout(this.timeout),this.timeout=null),this.poll()},a.prototype.poll=function(){if(this.timeout=setTimeout(this.poll.bind(this),o.ETH_POLLING_TIMEOUT),this.polls.length){if(!this.provider)return void console.error(i.InvalidProvider);var t=n.getInstance().toBatchPayload(this.polls.map(function(t){return t.data})),e=this;this.provider.sendAsync(t,function(t,o){if(!t){if(!r.isArray(o))throw i.InvalidResponse(o);o.map(function(t,n){return t.callback=e.polls[n].callback,t}).filter(function(t){var e=n.getInstance().isValidResponse(t);return e||t.callback(i.InvalidResponse(t)),e}).filter(function(t){return r.isArray(t.result)&&t.result.length>0}).forEach(function(t){t.callback(null,t.result)})}})}},e.exports=a},{"../utils/config":5,"../utils/utils":6,"./errors":11,"./jsonrpc":17}],23:[function(t,e){var n=t("./method"),r=t("./formatters"),o=new n({name:"post",call:"shh_post",params:1,inputFormatter:r.inputPostFormatter}),i=new n({name:"newIdentity",call:"shh_newIdentity",params:0}),a=new n({name:"hasIdentity",call:"shh_hasIdentity",params:1}),s=new n({name:"newGroup",call:"shh_newGroup",params:0}),u=new n({name:"addToGroup",call:"shh_addToGroup",params:0}),c=[o,i,a,s,u];e.exports={methods:c}},{"./formatters":15,"./method":18}],24:[function(t,e){var n=t("../web3"),r=t("../utils/config"),o=function(t){return n.sha3(n.fromAscii(t)).slice(0,2+2*r.ETH_SIGNATURE_LENGTH)},i=function(t){return n.sha3(n.fromAscii(t))};e.exports={functionSignatureFromAscii:o,eventSignatureFromAscii:i}},{"../utils/config":5,"../web3":8}],25:[function(t,e){var n=t("./method"),r=function(){var t=function(t){return"string"==typeof t[0]?"eth_newBlockFilter":"eth_newFilter"},e=new n({name:"newFilter",call:t,params:1}),r=new n({name:"uninstallFilter",call:"eth_uninstallFilter",params:1}),o=new n({name:"getLogs",call:"eth_getFilterLogs",params:1}),i=new n({name:"poll",call:"eth_getFilterChanges",params:1});return[e,r,o,i]},o=function(){var t=new n({name:"newFilter",call:"shh_newFilter",params:1}),e=new n({name:"uninstallFilter",call:"shh_uninstallFilter",params:1}),r=new n({name:"getLogs",call:"shh_getMessages",params:1}),o=new n({name:"poll",call:"shh_getFilterChanges",params:1});return[t,e,r,o]};e.exports={eth:r,shh:o}},{"./method":18}],26:[function(){},{}],"bignumber.js":[function(t,e){"use strict";e.exports=BigNumber},{}],"ethereum.js":[function(t,e){var n=t("./lib/web3");n.providers.HttpProvider=t("./lib/web3/httpprovider"),n.providers.QtSyncProvider=t("./lib/web3/qtsync"),n.eth.contract=t("./lib/web3/contract"),n.abi=t("./lib/solidity/abi"),e.exports=n},{"./lib/solidity/abi":1,"./lib/web3":8,"./lib/web3/contract":9,"./lib/web3/httpprovider":16,"./lib/web3/qtsync":21}]},{},["ethereum.js"]);`
diff --git a/jsre/jsre.go b/jsre/jsre.go
new file mode 100644
index 000000000..a49422a12
--- /dev/null
+++ b/jsre/jsre.go
@@ -0,0 +1,125 @@
+package jsre
+
+import (
+ "fmt"
+ "io/ioutil"
+
+ "github.com/robertkrimen/otto"
+
+ "github.com/ethereum/go-ethereum/common"
+)
+
+/*
+JSRE is a generic JS runtime environment embedding the otto JS interpreter.
+It provides some helper functions to
+- load code from files
+- run code snippets
+- require libraries
+- bind native go objects
+*/
+type JSRE struct {
+ assetPath string
+ vm *otto.Otto
+}
+
+func New(assetPath string) *JSRE {
+ re := &JSRE{
+ assetPath,
+ otto.New(),
+ }
+
+ // load prettyprint func definition
+ re.vm.Run(pp_js)
+ re.vm.Set("loadScript", re.loadScript)
+
+ return re
+}
+
+// Exec(file) loads and runs the contents of a file
+// if a relative path is given, the jsre's assetPath is used
+func (self *JSRE) Exec(file string) error {
+ return self.exec(common.AbsolutePath(self.assetPath, file))
+}
+
+func (self *JSRE) exec(path string) error {
+ code, err := ioutil.ReadFile(path)
+ if err != nil {
+ return err
+ }
+ _, err = self.vm.Run(code)
+ return err
+}
+
+func (self *JSRE) Bind(name string, v interface{}) (err error) {
+ self.vm.Set(name, v)
+ return
+}
+
+func (self *JSRE) Run(code string) (otto.Value, error) {
+ return self.vm.Run(code)
+}
+
+func (self *JSRE) Get(ns string) (otto.Value, error) {
+ return self.vm.Get(ns)
+}
+
+func (self *JSRE) Set(ns string, v interface{}) error {
+ return self.vm.Set(ns, v)
+}
+
+func (self *JSRE) loadScript(call otto.FunctionCall) otto.Value {
+ file, err := call.Argument(0).ToString()
+ if err != nil {
+ return otto.FalseValue()
+ }
+ if err := self.Exec(file); err != nil {
+ fmt.Println("err:", err)
+ return otto.FalseValue()
+ }
+
+ return otto.TrueValue()
+}
+
+func (self *JSRE) PrettyPrint(v interface{}) (val otto.Value, err error) {
+ var method otto.Value
+ v, err = self.vm.ToValue(v)
+ if err != nil {
+ return
+ }
+ method, err = self.vm.Get("prettyPrint")
+ if err != nil {
+ return
+ }
+ return method.Call(method, v)
+}
+
+func (self *JSRE) ToVal(v interface{}) otto.Value {
+ result, err := self.vm.ToValue(v)
+ if err != nil {
+ fmt.Println("Value unknown:", err)
+ return otto.UndefinedValue()
+ }
+ return result
+}
+
+func (self *JSRE) Eval(code string) (s string, err error) {
+ var val otto.Value
+ val, err = self.Run(code)
+ if err != nil {
+ return
+ }
+ val, err = self.PrettyPrint(val)
+ if err != nil {
+ return
+ }
+ return fmt.Sprintf("%v", val), nil
+}
+
+func (self *JSRE) Compile(fn string, src interface{}) error {
+ script, err := self.vm.Compile(fn, src)
+ if err != nil {
+ return err
+ }
+ self.vm.Run(script)
+ return nil
+}
diff --git a/jsre/jsre_test.go b/jsre/jsre_test.go
new file mode 100644
index 000000000..667ed4bdc
--- /dev/null
+++ b/jsre/jsre_test.go
@@ -0,0 +1,84 @@
+package jsre
+
+import (
+ "github.com/robertkrimen/otto"
+ "io/ioutil"
+ "os"
+ "testing"
+)
+
+type testNativeObjectBinding struct {
+ toVal func(interface{}) otto.Value
+}
+
+type msg struct {
+ Msg string
+}
+
+func (no *testNativeObjectBinding) TestMethod(call otto.FunctionCall) otto.Value {
+ m, err := call.Argument(0).ToString()
+ if err != nil {
+ return otto.UndefinedValue()
+ }
+ return no.toVal(&msg{m})
+}
+
+func TestExec(t *testing.T) {
+ jsre := New("/tmp")
+
+ ioutil.WriteFile("/tmp/test.js", []byte(`msg = "testMsg"`), os.ModePerm)
+ err := jsre.Exec("test.js")
+ if err != nil {
+ t.Errorf("expected no error, got %v", err)
+ }
+ val, err := jsre.Run("msg")
+ if err != nil {
+ t.Errorf("expected no error, got %v", err)
+ }
+ if !val.IsString() {
+ t.Errorf("expected string value, got %v", val)
+ }
+ exp := "testMsg"
+ got, _ := val.ToString()
+ if exp != got {
+ t.Errorf("expected '%v', got '%v'", exp, got)
+ }
+}
+
+func TestBind(t *testing.T) {
+ jsre := New("/tmp")
+
+ jsre.Bind("no", &testNativeObjectBinding{jsre.ToVal})
+
+ val, err := jsre.Run(`no.TestMethod("testMsg")`)
+ if err != nil {
+ t.Errorf("expected no error, got %v", err)
+ }
+ pp, err := jsre.PrettyPrint(val)
+ if err != nil {
+ t.Errorf("expected no error, got %v", err)
+ }
+ t.Logf("no: %v", pp)
+}
+
+func TestLoadScript(t *testing.T) {
+ jsre := New("/tmp")
+
+ ioutil.WriteFile("/tmp/test.js", []byte(`msg = "testMsg"`), os.ModePerm)
+ _, err := jsre.Run(`loadScript("test.js")`)
+ if err != nil {
+ t.Errorf("expected no error, got %v", err)
+ }
+ val, err := jsre.Run("msg")
+ if err != nil {
+ t.Errorf("expected no error, got %v", err)
+ }
+ if !val.IsString() {
+ t.Errorf("expected string value, got %v", val)
+ }
+ exp := "testMsg"
+ got, _ := val.ToString()
+ if exp != got {
+ t.Errorf("expected '%v', got '%v'", exp, got)
+ }
+}
diff --git a/jsre/pp_js.go b/jsre/pp_js.go
new file mode 100644
index 000000000..0b22afe6d
--- /dev/null
+++ b/jsre/pp_js.go
@@ -0,0 +1,81 @@
+package jsre
+
+const pp_js = `
+function pp(object, indent) {
+ var str = "";
+ /*
+ var o = object;
+ try {
+ object = JSON.stringify(object)
+ object = JSON.parse(object);
+ } catch(e) {
+ object = o;
+ }
+ */
+
+ if(object instanceof Array) {
+ str += "[";
+ for(var i = 0, l = object.length; i < l; i++) {
+ str += pp(object[i], indent);
+
+ if(i < l-1) {
+ str += ", ";
+ }
+ }
+ str += " ]";
+ } else if (object instanceof Error) {
+ str += "\033[31m" + "Error";
+ } else if (isBigNumber(object)) {
+ str += "\033[32m'" + object.toString(10) + "'";
+ } else if(typeof(object) === "object") {
+ str += "{\n";
+ indent += " ";
+ var last = Object.getOwnPropertyNames(object).pop()
+ Object.getOwnPropertyNames(object).forEach(function (k) {
+ str += indent + k + ": ";
+ try {
+ str += pp(object[k], indent);
+ } catch (e) {
+ str += pp(e, indent);
+ }
+
+ if(k !== last) {
+ str += ",";
+ }
+
+ str += "\n";
+ });
+ str += indent.substr(2, indent.length) + "}";
+ } else if(typeof(object) === "string") {
+ str += "\033[32m'" + object + "'";
+ } else if(typeof(object) === "undefined") {
+ str += "\033[1m\033[30m" + object;
+ } else if(typeof(object) === "number") {
+ str += "\033[31m" + object;
+ } else if(typeof(object) === "function") {
+ str += "\033[35m[Function]";
+ } else {
+ str += object;
+ }
+
+ str += "\033[0m";
+
+ return str;
+}
+
+var isBigNumber = function (object) {
+ return typeof BigNumber !== 'undefined' && object instanceof BigNumber;
+};
+
+
+function prettyPrint(/* */) {
+ var args = arguments;
+ var ret = "";
+ for(var i = 0, l = args.length; i < l; i++) {
+ ret += pp(args[i], "") + "\n";
+ }
+ return ret;
+}
+
+var print = prettyPrint;
+`
diff --git a/logger/example_test.go b/logger/example_test.go
new file mode 100644
index 000000000..c624252b8
--- /dev/null
+++ b/logger/example_test.go
@@ -0,0 +1,21 @@
+package logger
+
+import "os"
+
+func ExampleLogger() {
+ logger := NewLogger("TAG")
+ logger.Infoln("so awesome") // prints [TAG] so awesome
+ logger.Infof("this %q is raw", "coin") // prints [TAG] this "coin" is raw
+}
+
+func ExampleLogSystem() {
+ filename := "test.log"
+ file, _ := os.OpenFile(filename, os.O_RDWR|os.O_CREATE, os.ModePerm)
+ fileLog := NewStdLogSystem(file, 0, WarnLevel)
+ AddLogSystem(fileLog)
+
+ stdoutLog := NewStdLogSystem(os.Stdout, 0, WarnLevel)
+ AddLogSystem(stdoutLog)
+
+ NewLogger("TAG").Warnln("reactor meltdown") // writes to both logs
+}
diff --git a/logger/log.go b/logger/log.go
new file mode 100644
index 000000000..e2a35ba53
--- /dev/null
+++ b/logger/log.go
@@ -0,0 +1,49 @@
+package logger
+
+import (
+ "fmt"
+ "io"
+ "log"
+ "os"
+
+ "github.com/ethereum/go-ethereum/common"
+)
+
+func openLogFile(datadir string, filename string) *os.File {
+ path := common.AbsolutePath(datadir, filename)
+ file, err := os.OpenFile(path, os.O_RDWR|os.O_CREATE|os.O_APPEND, 0666)
+ if err != nil {
+ panic(fmt.Sprintf("error opening log file '%s': %v", filename, err))
+ }
+ return file
+}
+
+func New(datadir string, logFile string, logLevel int) LogSystem {
+ var writer io.Writer
+ if logFile == "" {
+ writer = os.Stdout
+ } else {
+ writer = openLogFile(datadir, logFile)
+ }
+
+ var sys LogSystem
+ sys = NewStdLogSystem(writer, log.LstdFlags, LogLevel(logLevel))
+ AddLogSystem(sys)
+
+ return sys
+}
+
+func NewJSONsystem(datadir string, logFile string) LogSystem {
+ var writer io.Writer
+ if logFile == "-" {
+ writer = os.Stdout
+ } else {
+ writer = openLogFile(datadir, logFile)
+ }
+
+ var sys LogSystem
+ sys = NewJsonLogSystem(writer)
+ AddLogSystem(sys)
+
+ return sys
+}
diff --git a/logger/loggers.go b/logger/loggers.go
new file mode 100644
index 000000000..42c8cbc07
--- /dev/null
+++ b/logger/loggers.go
@@ -0,0 +1,133 @@
+/*
+Package logger implements a multi-output leveled logger.
+
+Other packages use tagged logger to send log messages to shared
+(process-wide) logging engine. The shared logging engine dispatches to
+multiple log systems. The log level can be set separately per log
+system.
+
+Logging is asynchronous and does not block the caller. Message
+formatting is performed by the caller goroutine to avoid incorrect
+logging of mutable state.
+*/
+package logger
+
+import (
+ "encoding/json"
+ "fmt"
+ "os"
+)
+
+type LogLevel uint32
+
+const (
+ // Standard log levels
+ Silence LogLevel = iota
+ ErrorLevel
+ WarnLevel
+ InfoLevel
+ DebugLevel
+ DebugDetailLevel
+)
+
+// A Logger prints messages prefixed by a given tag. It provides named
+// Printf and Println style methods for all loglevels. Each ethereum
+// component should have its own logger with a unique prefix.
+type Logger struct {
+ tag string
+}
+
+func NewLogger(tag string) *Logger {
+ return &Logger{"[" + tag + "] "}
+}
+
+func (logger *Logger) Sendln(level LogLevel, v ...interface{}) {
+ logMessageC <- stdMsg{level, logger.tag + fmt.Sprintln(v...)}
+}
+
+func (logger *Logger) Sendf(level LogLevel, format string, v ...interface{}) {
+ logMessageC <- stdMsg{level, logger.tag + fmt.Sprintf(format, v...)}
+}
+
+// Errorln writes a message with ErrorLevel.
+func (logger *Logger) Errorln(v ...interface{}) {
+ logger.Sendln(ErrorLevel, v...)
+}
+
+// Warnln writes a message with WarnLevel.
+func (logger *Logger) Warnln(v ...interface{}) {
+ logger.Sendln(WarnLevel, v...)
+}
+
+// Infoln writes a message with InfoLevel.
+func (logger *Logger) Infoln(v ...interface{}) {
+ logger.Sendln(InfoLevel, v...)
+}
+
+// Debugln writes a message with DebugLevel.
+func (logger *Logger) Debugln(v ...interface{}) {
+ logger.Sendln(DebugLevel, v...)
+}
+
+// DebugDetailln writes a message with DebugDetailLevel.
+func (logger *Logger) DebugDetailln(v ...interface{}) {
+ logger.Sendln(DebugDetailLevel, v...)
+}
+
+// Errorf writes a message with ErrorLevel.
+func (logger *Logger) Errorf(format string, v ...interface{}) {
+ logger.Sendf(ErrorLevel, format, v...)
+}
+
+// Warnf writes a message with WarnLevel.
+func (logger *Logger) Warnf(format string, v ...interface{}) {
+ logger.Sendf(WarnLevel, format, v...)
+}
+
+// Infof writes a message with InfoLevel.
+func (logger *Logger) Infof(format string, v ...interface{}) {
+ logger.Sendf(InfoLevel, format, v...)
+}
+
+// Debugf writes a message with DebugLevel.
+func (logger *Logger) Debugf(format string, v ...interface{}) {
+ logger.Sendf(DebugLevel, format, v...)
+}
+
+// DebugDetailf writes a message with DebugDetailLevel.
+func (logger *Logger) DebugDetailf(format string, v ...interface{}) {
+ logger.Sendf(DebugDetailLevel, format, v...)
+}
+
+// Fatalln writes a message with ErrorLevel and exits the program.
+func (logger *Logger) Fatalln(v ...interface{}) {
+ logger.Sendln(ErrorLevel, v...)
+ Flush()
+ os.Exit(0)
+}
+
+// Fatalf writes a message with ErrorLevel and exits the program.
+func (logger *Logger) Fatalf(format string, v ...interface{}) {
+ logger.Sendf(ErrorLevel, format, v...)
+ Flush()
+ os.Exit(0)
+}
+
+type JsonLogger struct {
+ Coinbase string
+}
+
+func NewJsonLogger() *JsonLogger {
+ return &JsonLogger{}
+}
+
+func (logger *JsonLogger) LogJson(v JsonLog) {
+ msgname := v.EventName()
+ obj := map[string]interface{}{
+ msgname: v,
+ }
+
+ jsontxt, _ := json.Marshal(obj)
+ logMessageC <- (jsonMsg(jsontxt))
+
+}
diff --git a/logger/loggers_test.go b/logger/loggers_test.go
new file mode 100644
index 000000000..276b65b78
--- /dev/null
+++ b/logger/loggers_test.go
@@ -0,0 +1,176 @@
+package logger
+
+import (
+ "io/ioutil"
+ "math/rand"
+ "os"
+ "sync"
+ "testing"
+ "time"
+)
+
+type TestLogSystem struct {
+ mutex sync.Mutex
+ output string
+ level LogLevel
+}
+
+func (ls *TestLogSystem) LogPrint(msg LogMsg) {
+ ls.mutex.Lock()
+ if ls.level >= msg.Level() {
+ ls.output += msg.String()
+ }
+ ls.mutex.Unlock()
+}
+
+func (ls *TestLogSystem) SetLogLevel(i LogLevel) {
+ ls.mutex.Lock()
+ ls.level = i
+ ls.mutex.Unlock()
+}
+
+func (ls *TestLogSystem) GetLogLevel() LogLevel {
+ ls.mutex.Lock()
+ defer ls.mutex.Unlock()
+ return ls.level
+}
+
+func (ls *TestLogSystem) CheckOutput(t *testing.T, expected string) {
+ ls.mutex.Lock()
+ output := ls.output
+ ls.mutex.Unlock()
+ if output != expected {
+ t.Errorf("log output mismatch:\n got: %q\n want: %q\n", output, expected)
+ }
+}
+
+type blockedLogSystem struct {
+ LogSystem
+ unblock chan struct{}
+}
+
+func (ls blockedLogSystem) LogPrint(msg LogMsg) {
+ <-ls.unblock
+ ls.LogSystem.LogPrint(msg)
+}
+
+func TestLoggerFlush(t *testing.T) {
+ Reset()
+
+ logger := NewLogger("TEST")
+ ls := blockedLogSystem{&TestLogSystem{level: WarnLevel}, make(chan struct{})}
+ AddLogSystem(ls)
+ for i := 0; i < 5; i++ {
+ // these writes shouldn't hang even though ls is blocked
+ logger.Errorf(".")
+ }
+
+ beforeFlush := time.Now()
+ time.AfterFunc(80*time.Millisecond, func() { close(ls.unblock) })
+ Flush() // this should hang for approx. 80ms
+ if blockd := time.Now().Sub(beforeFlush); blockd < 80*time.Millisecond {
+ t.Errorf("Flush didn't block long enough, blocked for %v, should've been >= 80ms", blockd)
+ }
+
+ ls.LogSystem.(*TestLogSystem).CheckOutput(t, "[TEST] .[TEST] .[TEST] .[TEST] .[TEST] .")
+}
+
+func TestLoggerPrintln(t *testing.T) {
+ Reset()
+
+ logger := NewLogger("TEST")
+ testLogSystem := &TestLogSystem{level: WarnLevel}
+ AddLogSystem(testLogSystem)
+ logger.Errorln("error")
+ logger.Warnln("warn")
+ logger.Infoln("info")
+ logger.Debugln("debug")
+ Flush()
+
+ testLogSystem.CheckOutput(t, "[TEST] error\n[TEST] warn\n")
+}
+
+func TestLoggerPrintf(t *testing.T) {
+ Reset()
+
+ logger := NewLogger("TEST")
+ testLogSystem := &TestLogSystem{level: WarnLevel}
+ AddLogSystem(testLogSystem)
+ logger.Errorf("error to %v\n", []int{1, 2, 3})
+ logger.Warnf("warn %%d %d", 5)
+ logger.Infof("info")
+ logger.Debugf("debug")
+ Flush()
+ testLogSystem.CheckOutput(t, "[TEST] error to [1 2 3]\n[TEST] warn %d 5")
+}
+
+func TestMultipleLogSystems(t *testing.T) {
+ Reset()
+
+ logger := NewLogger("TEST")
+ testLogSystem0 := &TestLogSystem{level: ErrorLevel}
+ testLogSystem1 := &TestLogSystem{level: WarnLevel}
+ AddLogSystem(testLogSystem0)
+ AddLogSystem(testLogSystem1)
+ logger.Errorln("error")
+ logger.Warnln("warn")
+ Flush()
+
+ testLogSystem0.CheckOutput(t, "[TEST] error\n")
+ testLogSystem1.CheckOutput(t, "[TEST] error\n[TEST] warn\n")
+}
+
+func TestFileLogSystem(t *testing.T) {
+ Reset()
+
+ logger := NewLogger("TEST")
+ filename := "test.log"
+ file, _ := os.OpenFile(filename, os.O_RDWR|os.O_CREATE, os.ModePerm)
+ testLogSystem := NewStdLogSystem(file, 0, WarnLevel)
+ AddLogSystem(testLogSystem)
+ logger.Errorf("error to %s\n", filename)
+ logger.Warnln("warn")
+ Flush()
+ contents, _ := ioutil.ReadFile(filename)
+ output := string(contents)
+ if output != "[TEST] error to test.log\n[TEST] warn\n" {
+ t.Error("Expected contents of file 'test.log': '[TEST] error to test.log\\n[TEST] warn\\n', got ", output)
+ } else {
+ os.Remove(filename)
+ }
+}
+
+func TestNoLogSystem(t *testing.T) {
+ Reset()
+
+ logger := NewLogger("TEST")
+ logger.Warnln("warn")
+ Flush()
+}
+
+func TestConcurrentAddSystem(t *testing.T) {
+ rand.Seed(time.Now().Unix())
+ Reset()
+
+ logger := NewLogger("TEST")
+ stop := make(chan struct{})
+ writer := func() {
+ select {
+ case <-stop:
+ return
+ default:
+ logger.Infoln("foo")
+ Flush()
+ }
+ }
+
+ go writer()
+ go writer()
+
+ stopTime := time.Now().Add(100 * time.Millisecond)
+ for time.Now().Before(stopTime) {
+ time.Sleep(time.Duration(rand.Intn(20)) * time.Millisecond)
+ AddLogSystem(NewStdLogSystem(ioutil.Discard, 0, InfoLevel))
+ }
+ close(stop)
+}
diff --git a/logger/logsystem.go b/logger/logsystem.go
new file mode 100644
index 000000000..4dadb126e
--- /dev/null
+++ b/logger/logsystem.go
@@ -0,0 +1,60 @@
+package logger
+
+import (
+ "io"
+ "log"
+ "sync/atomic"
+)
+
+// LogSystem is implemented by log output devices.
+// All methods can be called concurrently from multiple goroutines.
+type LogSystem interface {
+ LogPrint(LogMsg)
+}
+
+// NewStdLogSystem creates a LogSystem that prints to the given writer.
+// The flag values are defined package log.
+func NewStdLogSystem(writer io.Writer, flags int, level LogLevel) *StdLogSystem {
+ logger := log.New(writer, "", flags)
+ return &StdLogSystem{logger, uint32(level)}
+}
+
+type StdLogSystem struct {
+ logger *log.Logger
+ level uint32
+}
+
+func (t *StdLogSystem) LogPrint(msg LogMsg) {
+ stdmsg, ok := msg.(stdMsg)
+ if ok {
+ if t.GetLogLevel() >= stdmsg.Level() {
+ t.logger.Print(stdmsg.String())
+ }
+ }
+}
+
+func (t *StdLogSystem) SetLogLevel(i LogLevel) {
+ atomic.StoreUint32(&t.level, uint32(i))
+}
+
+func (t *StdLogSystem) GetLogLevel() LogLevel {
+ return LogLevel(atomic.LoadUint32(&t.level))
+}
+
+// NewJSONLogSystem creates a LogSystem that prints to the given writer without
+// adding extra information irrespective of loglevel only if message is JSON type
+func NewJsonLogSystem(writer io.Writer) LogSystem {
+ logger := log.New(writer, "", 0)
+ return &jsonLogSystem{logger}
+}
+
+type jsonLogSystem struct {
+ logger *log.Logger
+}
+
+func (t *jsonLogSystem) LogPrint(msg LogMsg) {
+ jsonmsg, ok := msg.(jsonMsg)
+ if ok {
+ t.logger.Print(jsonmsg.String())
+ }
+}
diff --git a/logger/sys.go b/logger/sys.go
new file mode 100644
index 000000000..c4d5c382a
--- /dev/null
+++ b/logger/sys.go
@@ -0,0 +1,126 @@
+package logger
+
+import (
+ "fmt"
+ "sync"
+)
+
+type stdMsg struct {
+ level LogLevel
+ msg string
+}
+
+type jsonMsg []byte
+
+func (m jsonMsg) Level() LogLevel {
+ return 0
+}
+
+func (m jsonMsg) String() string {
+ return string(m)
+}
+
+type LogMsg interface {
+ Level() LogLevel
+ fmt.Stringer
+}
+
+func (m stdMsg) Level() LogLevel {
+ return m.level
+}
+
+func (m stdMsg) String() string {
+ return m.msg
+}
+
+var (
+ logMessageC = make(chan LogMsg)
+ addSystemC = make(chan LogSystem)
+ flushC = make(chan chan struct{})
+ resetC = make(chan chan struct{})
+)
+
+func init() {
+ go dispatchLoop()
+}
+
+// each system can buffer this many messages before
+// blocking incoming log messages.
+const sysBufferSize = 500
+
+func dispatchLoop() {
+ var (
+ systems []LogSystem
+ systemIn []chan LogMsg
+ systemWG sync.WaitGroup
+ )
+ bootSystem := func(sys LogSystem) {
+ in := make(chan LogMsg, sysBufferSize)
+ systemIn = append(systemIn, in)
+ systemWG.Add(1)
+ go sysLoop(sys, in, &systemWG)
+ }
+
+ for {
+ select {
+ case msg := <-logMessageC:
+ for _, c := range systemIn {
+ c <- msg
+ }
+
+ case sys := <-addSystemC:
+ systems = append(systems, sys)
+ bootSystem(sys)
+
+ case waiter := <-resetC:
+ // reset means terminate all systems
+ for _, c := range systemIn {
+ close(c)
+ }
+ systems = nil
+ systemIn = nil
+ systemWG.Wait()
+ close(waiter)
+
+ case waiter := <-flushC:
+ // flush means reboot all systems
+ for _, c := range systemIn {
+ close(c)
+ }
+ systemIn = nil
+ systemWG.Wait()
+ for _, sys := range systems {
+ bootSystem(sys)
+ }
+ close(waiter)
+ }
+ }
+}
+
+func sysLoop(sys LogSystem, in <-chan LogMsg, wg *sync.WaitGroup) {
+ for msg := range in {
+ sys.LogPrint(msg)
+ }
+ wg.Done()
+}
+
+// Reset removes all active log systems.
+// It blocks until all current messages have been delivered.
+func Reset() {
+ waiter := make(chan struct{})
+ resetC <- waiter
+ <-waiter
+}
+
+// Flush waits until all current log messages have been dispatched to
+// the active log systems.
+func Flush() {
+ waiter := make(chan struct{})
+ flushC <- waiter
+ <-waiter
+}
+
+// AddLogSystem starts printing messages to the given LogSystem.
+func AddLogSystem(sys LogSystem) {
+ addSystemC <- sys
+}
diff --git a/logger/types.go b/logger/types.go
new file mode 100644
index 000000000..0f70578ba
--- /dev/null
+++ b/logger/types.go
@@ -0,0 +1,365 @@
+package logger
+
+import (
+ "math/big"
+ "time"
+)
+
+type utctime8601 struct{}
+
+func (utctime8601) MarshalJSON() ([]byte, error) {
+ timestr := time.Now().UTC().Format(time.RFC3339Nano)
+ // Bounds check
+ if len(timestr) > 26 {
+ timestr = timestr[:26]
+ }
+ return []byte(`"` + timestr + `Z"`), nil
+}
+
+type JsonLog interface {
+ EventName() string
+}
+
+type LogEvent struct {
+ // Guid string `json:"guid"`
+ Ts utctime8601 `json:"ts"`
+ // Level string `json:"level"`
+}
+
+type LogStarting struct {
+ ClientString string `json:"client_impl"`
+ ProtocolVersion int `json:"eth_version"`
+ LogEvent
+}
+
+func (l *LogStarting) EventName() string {
+ return "starting"
+}
+
+type P2PConnected struct {
+ RemoteId string `json:"remote_id"`
+ RemoteAddress string `json:"remote_addr"`
+ RemoteVersionString string `json:"remote_version_string"`
+ NumConnections int `json:"num_connections"`
+ LogEvent
+}
+
+func (l *P2PConnected) EventName() string {
+ return "p2p.connected"
+}
+
+type P2PDisconnected struct {
+ NumConnections int `json:"num_connections"`
+ RemoteId string `json:"remote_id"`
+ LogEvent
+}
+
+func (l *P2PDisconnected) EventName() string {
+ return "p2p.disconnected"
+}
+
+type EthMinerNewBlock struct {
+ BlockHash string `json:"block_hash"`
+ BlockNumber *big.Int `json:"block_number"`
+ ChainHeadHash string `json:"chain_head_hash"`
+ BlockPrevHash string `json:"block_prev_hash"`
+ LogEvent
+}
+
+func (l *EthMinerNewBlock) EventName() string {
+ return "eth.miner.new_block"
+}
+
+type EthChainReceivedNewBlock struct {
+ BlockHash string `json:"block_hash"`
+ BlockNumber *big.Int `json:"block_number"`
+ ChainHeadHash string `json:"chain_head_hash"`
+ BlockPrevHash string `json:"block_prev_hash"`
+ RemoteId string `json:"remote_id"`
+ LogEvent
+}
+
+func (l *EthChainReceivedNewBlock) EventName() string {
+ return "eth.chain.received.new_block"
+}
+
+type EthChainNewHead struct {
+ BlockHash string `json:"block_hash"`
+ BlockNumber *big.Int `json:"block_number"`
+ ChainHeadHash string `json:"chain_head_hash"`
+ BlockPrevHash string `json:"block_prev_hash"`
+ LogEvent
+}
+
+func (l *EthChainNewHead) EventName() string {
+ return "eth.chain.new_head"
+}
+
+type EthTxReceived struct {
+ TxHash string `json:"tx_hash"`
+ RemoteId string `json:"remote_id"`
+ LogEvent
+}
+
+func (l *EthTxReceived) EventName() string {
+ return "eth.tx.received"
+}
+
+//
+//
+// The types below are legacy and need to be converted to new format or deleted
+//
+//
+
+// type P2PConnecting struct {
+// RemoteId string `json:"remote_id"`
+// RemoteEndpoint string `json:"remote_endpoint"`
+// NumConnections int `json:"num_connections"`
+// LogEvent
+// }
+
+// func (l *P2PConnecting) EventName() string {
+// return "p2p.connecting"
+// }
+
+// type P2PHandshaked struct {
+// RemoteCapabilities []string `json:"remote_capabilities"`
+// RemoteId string `json:"remote_id"`
+// NumConnections int `json:"num_connections"`
+// LogEvent
+// }
+
+// func (l *P2PHandshaked) EventName() string {
+// return "p2p.handshaked"
+// }
+
+// type P2PDisconnecting struct {
+// Reason string `json:"reason"`
+// RemoteId string `json:"remote_id"`
+// NumConnections int `json:"num_connections"`
+// LogEvent
+// }
+
+// func (l *P2PDisconnecting) EventName() string {
+// return "p2p.disconnecting"
+// }
+
+// type P2PDisconnectingBadHandshake struct {
+// Reason string `json:"reason"`
+// RemoteId string `json:"remote_id"`
+// NumConnections int `json:"num_connections"`
+// LogEvent
+// }
+
+// func (l *P2PDisconnectingBadHandshake) EventName() string {
+// return "p2p.disconnecting.bad_handshake"
+// }
+
+// type P2PDisconnectingBadProtocol struct {
+// Reason string `json:"reason"`
+// RemoteId string `json:"remote_id"`
+// NumConnections int `json:"num_connections"`
+// LogEvent
+// }
+
+// func (l *P2PDisconnectingBadProtocol) EventName() string {
+// return "p2p.disconnecting.bad_protocol"
+// }
+
+// type P2PDisconnectingReputation struct {
+// Reason string `json:"reason"`
+// RemoteId string `json:"remote_id"`
+// NumConnections int `json:"num_connections"`
+// LogEvent
+// }
+
+// func (l *P2PDisconnectingReputation) EventName() string {
+// return "p2p.disconnecting.reputation"
+// }
+
+// type P2PDisconnectingDHT struct {
+// Reason string `json:"reason"`
+// RemoteId string `json:"remote_id"`
+// NumConnections int `json:"num_connections"`
+// LogEvent
+// }
+
+// func (l *P2PDisconnectingDHT) EventName() string {
+// return "p2p.disconnecting.dht"
+// }
+
+// type P2PEthDisconnectingBadBlock struct {
+// Reason string `json:"reason"`
+// RemoteId string `json:"remote_id"`
+// NumConnections int `json:"num_connections"`
+// LogEvent
+// }
+
+// func (l *P2PEthDisconnectingBadBlock) EventName() string {
+// return "p2p.eth.disconnecting.bad_block"
+// }
+
+// type P2PEthDisconnectingBadTx struct {
+// Reason string `json:"reason"`
+// RemoteId string `json:"remote_id"`
+// NumConnections int `json:"num_connections"`
+// LogEvent
+// }
+
+// func (l *P2PEthDisconnectingBadTx) EventName() string {
+// return "p2p.eth.disconnecting.bad_tx"
+// }
+
+// type EthNewBlockBroadcasted struct {
+// BlockNumber int `json:"block_number"`
+// HeadHash string `json:"head_hash"`
+// BlockHash string `json:"block_hash"`
+// BlockDifficulty int `json:"block_difficulty"`
+// BlockPrevHash string `json:"block_prev_hash"`
+// LogEvent
+// }
+
+// func (l *EthNewBlockBroadcasted) EventName() string {
+// return "eth.newblock.broadcasted"
+// }
+
+// type EthNewBlockIsKnown struct {
+// BlockNumber int `json:"block_number"`
+// HeadHash string `json:"head_hash"`
+// BlockHash string `json:"block_hash"`
+// BlockDifficulty int `json:"block_difficulty"`
+// BlockPrevHash string `json:"block_prev_hash"`
+// LogEvent
+// }
+
+// func (l *EthNewBlockIsKnown) EventName() string {
+// return "eth.newblock.is_known"
+// }
+
+// type EthNewBlockIsNew struct {
+// BlockNumber int `json:"block_number"`
+// HeadHash string `json:"head_hash"`
+// BlockHash string `json:"block_hash"`
+// BlockDifficulty int `json:"block_difficulty"`
+// BlockPrevHash string `json:"block_prev_hash"`
+// LogEvent
+// }
+
+// func (l *EthNewBlockIsNew) EventName() string {
+// return "eth.newblock.is_new"
+// }
+
+// type EthNewBlockMissingParent struct {
+// BlockNumber int `json:"block_number"`
+// HeadHash string `json:"head_hash"`
+// BlockHash string `json:"block_hash"`
+// BlockDifficulty int `json:"block_difficulty"`
+// BlockPrevHash string `json:"block_prev_hash"`
+// LogEvent
+// }
+
+// func (l *EthNewBlockMissingParent) EventName() string {
+// return "eth.newblock.missing_parent"
+// }
+
+// type EthNewBlockIsInvalid struct {
+// BlockNumber int `json:"block_number"`
+// HeadHash string `json:"head_hash"`
+// BlockHash string `json:"block_hash"`
+// BlockDifficulty int `json:"block_difficulty"`
+// BlockPrevHash string `json:"block_prev_hash"`
+// LogEvent
+// }
+
+// func (l *EthNewBlockIsInvalid) EventName() string {
+// return "eth.newblock.is_invalid"
+// }
+
+// type EthNewBlockChainIsOlder struct {
+// BlockNumber int `json:"block_number"`
+// HeadHash string `json:"head_hash"`
+// BlockHash string `json:"block_hash"`
+// BlockDifficulty int `json:"block_difficulty"`
+// BlockPrevHash string `json:"block_prev_hash"`
+// LogEvent
+// }
+
+// func (l *EthNewBlockChainIsOlder) EventName() string {
+// return "eth.newblock.chain.is_older"
+// }
+
+// type EthNewBlockChainIsCanonical struct {
+// BlockNumber int `json:"block_number"`
+// HeadHash string `json:"head_hash"`
+// BlockHash string `json:"block_hash"`
+// BlockDifficulty int `json:"block_difficulty"`
+// BlockPrevHash string `json:"block_prev_hash"`
+// LogEvent
+// }
+
+// func (l *EthNewBlockChainIsCanonical) EventName() string {
+// return "eth.newblock.chain.is_cannonical"
+// }
+
+// type EthNewBlockChainNotCanonical struct {
+// BlockNumber int `json:"block_number"`
+// HeadHash string `json:"head_hash"`
+// BlockHash string `json:"block_hash"`
+// BlockDifficulty int `json:"block_difficulty"`
+// BlockPrevHash string `json:"block_prev_hash"`
+// LogEvent
+// }
+
+// func (l *EthNewBlockChainNotCanonical) EventName() string {
+// return "eth.newblock.chain.not_cannonical"
+// }
+
+// type EthTxCreated struct {
+// TxHash string `json:"tx_hash"`
+// TxSender string `json:"tx_sender"`
+// TxAddress string `json:"tx_address"`
+// TxHexRLP string `json:"tx_hexrlp"`
+// TxNonce int `json:"tx_nonce"`
+// LogEvent
+// }
+
+// func (l *EthTxCreated) EventName() string {
+// return "eth.tx.created"
+// }
+
+// type EthTxBroadcasted struct {
+// TxHash string `json:"tx_hash"`
+// TxSender string `json:"tx_sender"`
+// TxAddress string `json:"tx_address"`
+// TxNonce int `json:"tx_nonce"`
+// LogEvent
+// }
+
+// func (l *EthTxBroadcasted) EventName() string {
+// return "eth.tx.broadcasted"
+// }
+
+// type EthTxValidated struct {
+// TxHash string `json:"tx_hash"`
+// TxSender string `json:"tx_sender"`
+// TxAddress string `json:"tx_address"`
+// TxNonce int `json:"tx_nonce"`
+// LogEvent
+// }
+
+// func (l *EthTxValidated) EventName() string {
+// return "eth.tx.validated"
+// }
+
+// type EthTxIsInvalid struct {
+// TxHash string `json:"tx_hash"`
+// TxSender string `json:"tx_sender"`
+// TxAddress string `json:"tx_address"`
+// Reason string `json:"reason"`
+// TxNonce int `json:"tx_nonce"`
+// LogEvent
+// }
+
+// func (l *EthTxIsInvalid) EventName() string {
+// return "eth.tx.is_invalid"
+// }
diff --git a/miner/agent.go b/miner/agent.go
new file mode 100644
index 000000000..ad08e3841
--- /dev/null
+++ b/miner/agent.go
@@ -0,0 +1,98 @@
+package miner
+
+import (
+ "sync"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/core/types"
+ "github.com/ethereum/go-ethereum/pow"
+)
+
+type CpuMiner struct {
+ chMu sync.Mutex
+ c chan *types.Block
+ quit chan struct{}
+ quitCurrentOp chan struct{}
+ returnCh chan<- *types.Block
+
+ index int
+ pow pow.PoW
+}
+
+func NewCpuMiner(index int, pow pow.PoW) *CpuMiner {
+ miner := &CpuMiner{
+ pow: pow,
+ index: index,
+ }
+
+ return miner
+}
+
+func (self *CpuMiner) Work() chan<- *types.Block { return self.c }
+func (self *CpuMiner) Pow() pow.PoW { return self.pow }
+func (self *CpuMiner) SetReturnCh(ch chan<- *types.Block) { self.returnCh = ch }
+
+func (self *CpuMiner) Stop() {
+ close(self.quit)
+ close(self.quitCurrentOp)
+}
+
+func (self *CpuMiner) Start() {
+ self.quit = make(chan struct{})
+ self.quitCurrentOp = make(chan struct{}, 1)
+ self.c = make(chan *types.Block, 1)
+
+ go self.update()
+}
+
+func (self *CpuMiner) update() {
+out:
+ for {
+ select {
+ case block := <-self.c:
+ self.chMu.Lock()
+ self.quitCurrentOp <- struct{}{}
+ self.chMu.Unlock()
+
+ go self.mine(block)
+ case <-self.quit:
+ break out
+ }
+ }
+
+ //close(self.quitCurrentOp)
+done:
+ // Empty channel
+ for {
+ select {
+ case <-self.c:
+ default:
+ close(self.c)
+
+ break done
+ }
+ }
+}
+
+func (self *CpuMiner) mine(block *types.Block) {
+ minerlogger.Debugf("(re)started agent[%d]. mining...\n", self.index)
+
+ // Reset the channel
+ self.chMu.Lock()
+ self.quitCurrentOp = make(chan struct{}, 1)
+ self.chMu.Unlock()
+
+ // Mine
+ nonce, mixDigest, _ := self.pow.Search(block, self.quitCurrentOp)
+ if nonce != 0 {
+ block.SetNonce(nonce)
+ block.Header().MixDigest = common.BytesToHash(mixDigest)
+ self.returnCh <- block
+ } else {
+ self.returnCh <- nil
+ }
+}
+
+func (self *CpuMiner) GetHashRate() int64 {
+ return self.pow.GetHashrate()
+}
diff --git a/miner/miner.go b/miner/miner.go
new file mode 100644
index 000000000..cf84c11f3
--- /dev/null
+++ b/miner/miner.go
@@ -0,0 +1,63 @@
+package miner
+
+import (
+ "math/big"
+
+ "github.com/ethereum/ethash"
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/core"
+ "github.com/ethereum/go-ethereum/logger"
+ "github.com/ethereum/go-ethereum/pow"
+)
+
+var minerlogger = logger.NewLogger("MINER")
+
+type Miner struct {
+ worker *worker
+
+ MinAcceptedGasPrice *big.Int
+ Extra string
+
+ mining bool
+ eth core.Backend
+ pow pow.PoW
+}
+
+func New(eth core.Backend, pow pow.PoW, minerThreads int) *Miner {
+ // note: minerThreads is currently ignored because
+ // ethash is not thread safe.
+ miner := &Miner{eth: eth, pow: pow, worker: newWorker(common.Address{}, eth)}
+ for i := 0; i < minerThreads; i++ {
+ miner.worker.register(NewCpuMiner(i, pow))
+ }
+ return miner
+}
+
+func (self *Miner) Mining() bool {
+ return self.mining
+}
+
+func (self *Miner) Start(coinbase common.Address) {
+ self.mining = true
+ self.worker.coinbase = coinbase
+
+ self.pow.(*ethash.Ethash).UpdateDAG()
+
+ self.worker.start()
+ self.worker.commitNewWork()
+}
+
+func (self *Miner) Register(agent Agent) {
+ self.worker.register(agent)
+}
+
+func (self *Miner) Stop() {
+ self.mining = false
+ self.worker.stop()
+
+ //self.pow.(*ethash.Ethash).Stop()
+}
+
+func (self *Miner) HashRate() int64 {
+ return self.worker.HashRate()
+}
diff --git a/miner/remote_agent.go b/miner/remote_agent.go
new file mode 100644
index 000000000..aa04a58aa
--- /dev/null
+++ b/miner/remote_agent.go
@@ -0,0 +1,85 @@
+package miner
+
+import (
+ "github.com/ethereum/ethash"
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/core/types"
+)
+
+type RemoteAgent struct {
+ work *types.Block
+ currentWork *types.Block
+
+ quit chan struct{}
+ workCh chan *types.Block
+ returnCh chan<- *types.Block
+}
+
+func NewRemoteAgent() *RemoteAgent {
+ agent := &RemoteAgent{}
+
+ return agent
+}
+
+func (a *RemoteAgent) Work() chan<- *types.Block {
+ return a.workCh
+}
+
+func (a *RemoteAgent) SetReturnCh(returnCh chan<- *types.Block) {
+ a.returnCh = returnCh
+}
+
+func (a *RemoteAgent) Start() {
+ a.quit = make(chan struct{})
+ a.workCh = make(chan *types.Block, 1)
+ go a.run()
+}
+
+func (a *RemoteAgent) Stop() {
+ close(a.quit)
+ close(a.workCh)
+}
+
+func (a *RemoteAgent) GetHashRate() int64 { return 0 }
+
+func (a *RemoteAgent) run() {
+out:
+ for {
+ select {
+ case <-a.quit:
+ break out
+ case work := <-a.workCh:
+ a.work = work
+ a.returnCh <- nil
+ }
+ }
+}
+
+func (a *RemoteAgent) GetWork() [3]string {
+ var res [3]string
+
+ // XXX Wait here until work != nil ?
+ if a.work != nil {
+ res[0] = a.work.HashNoNonce().Hex()
+ seedHash, _ := ethash.GetSeedHash(a.currentWork.NumberU64())
+ res[1] = common.Bytes2Hex(seedHash)
+ res[2] = common.Bytes2Hex(a.work.Difficulty().Bytes())
+ }
+
+ return res
+}
+
+func (a *RemoteAgent) SubmitWork(nonce uint64, mixDigest, seedHash common.Hash) bool {
+ // Return true or false, but does not indicate if the PoW was correct
+
+ // Make sure the external miner was working on the right hash
+ if a.currentWork != nil && a.work != nil {
+ a.currentWork.SetNonce(nonce)
+ a.currentWork.Header().MixDigest = mixDigest
+ a.returnCh <- a.currentWork
+ //a.returnCh <- Work{a.currentWork.Number().Uint64(), nonce, mixDigest.Bytes(), seedHash.Bytes()}
+ return true
+ }
+
+ return false
+}
diff --git a/miner/worker.go b/miner/worker.go
new file mode 100644
index 000000000..4385b51c8
--- /dev/null
+++ b/miner/worker.go
@@ -0,0 +1,326 @@
+package miner
+
+import (
+ "fmt"
+ "math/big"
+ "sort"
+ "sync"
+ "sync/atomic"
+ "time"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/core"
+ "github.com/ethereum/go-ethereum/core/state"
+ "github.com/ethereum/go-ethereum/core/types"
+ "github.com/ethereum/go-ethereum/event"
+ "github.com/ethereum/go-ethereum/logger"
+ "github.com/ethereum/go-ethereum/pow"
+ "gopkg.in/fatih/set.v0"
+)
+
+var jsonlogger = logger.NewJsonLogger()
+
+type environment struct {
+ totalUsedGas *big.Int
+ state *state.StateDB
+ coinbase *state.StateObject
+ block *types.Block
+ family *set.Set
+ uncles *set.Set
+}
+
+func env(block *types.Block, eth core.Backend) *environment {
+ state := state.New(block.Root(), eth.StateDb())
+ env := &environment{
+ totalUsedGas: new(big.Int),
+ state: state,
+ block: block,
+ family: set.New(),
+ uncles: set.New(),
+ coinbase: state.GetOrNewStateObject(block.Coinbase()),
+ }
+
+ return env
+}
+
+type Work struct {
+ Number uint64
+ Nonce uint64
+ MixDigest []byte
+ SeedHash []byte
+}
+
+type Agent interface {
+ Work() chan<- *types.Block
+ SetReturnCh(chan<- *types.Block)
+ Stop()
+ Start()
+ GetHashRate() int64
+}
+
+type worker struct {
+ mu sync.Mutex
+
+ agents []Agent
+ recv chan *types.Block
+ mux *event.TypeMux
+ quit chan struct{}
+ pow pow.PoW
+ atWork int64
+
+ eth core.Backend
+ chain *core.ChainManager
+ proc *core.BlockProcessor
+ coinbase common.Address
+
+ current *environment
+
+ uncleMu sync.Mutex
+ possibleUncles map[common.Hash]*types.Block
+
+ mining bool
+}
+
+func newWorker(coinbase common.Address, eth core.Backend) *worker {
+ return &worker{
+ eth: eth,
+ mux: eth.EventMux(),
+ recv: make(chan *types.Block),
+ chain: eth.ChainManager(),
+ proc: eth.BlockProcessor(),
+ possibleUncles: make(map[common.Hash]*types.Block),
+ coinbase: coinbase,
+ }
+}
+
+func (self *worker) start() {
+ self.mining = true
+
+ self.quit = make(chan struct{})
+
+ // spin up agents
+ for _, agent := range self.agents {
+ agent.Start()
+ }
+
+ go self.update()
+ go self.wait()
+}
+
+func (self *worker) stop() {
+ self.mining = false
+ atomic.StoreInt64(&self.atWork, 0)
+
+ close(self.quit)
+}
+
+func (self *worker) register(agent Agent) {
+ self.agents = append(self.agents, agent)
+ agent.SetReturnCh(self.recv)
+}
+
+func (self *worker) update() {
+ events := self.mux.Subscribe(core.ChainHeadEvent{}, core.ChainSideEvent{})
+
+ timer := time.NewTicker(2 * time.Second)
+
+out:
+ for {
+ select {
+ case event := <-events.Chan():
+ switch ev := event.(type) {
+ case core.ChainHeadEvent:
+ self.commitNewWork()
+ case core.ChainSideEvent:
+ self.uncleMu.Lock()
+ self.possibleUncles[ev.Block.Hash()] = ev.Block
+ self.uncleMu.Unlock()
+ }
+
+ case <-self.quit:
+ // stop all agents
+ for _, agent := range self.agents {
+ agent.Stop()
+ }
+ break out
+ case <-timer.C:
+ minerlogger.Infoln("Hash rate:", self.HashRate(), "Khash")
+
+ // XXX In case all mined a possible uncle
+ if atomic.LoadInt64(&self.atWork) == 0 {
+ self.commitNewWork()
+ }
+ }
+ }
+
+ events.Unsubscribe()
+}
+
+func (self *worker) wait() {
+ for {
+ for block := range self.recv {
+ atomic.AddInt64(&self.atWork, -1)
+
+ if block == nil {
+ continue
+ }
+
+ if err := self.chain.InsertChain(types.Blocks{block}); err == nil {
+ for _, uncle := range block.Uncles() {
+ delete(self.possibleUncles, uncle.Hash())
+ }
+ self.mux.Post(core.NewMinedBlockEvent{block})
+
+ minerlogger.Infof("🔨 Mined block #%v", block.Number())
+
+ jsonlogger.LogJson(&logger.EthMinerNewBlock{
+ BlockHash: block.Hash().Hex(),
+ BlockNumber: block.Number(),
+ ChainHeadHash: block.ParentHeaderHash.Hex(),
+ BlockPrevHash: block.ParentHeaderHash.Hex(),
+ })
+ } else {
+ self.commitNewWork()
+ }
+ }
+ }
+}
+
+func (self *worker) push() {
+ if self.mining {
+ self.current.block.Header().GasUsed = self.current.totalUsedGas
+ self.current.block.SetRoot(self.current.state.Root())
+
+ // push new work to agents
+ for _, agent := range self.agents {
+ atomic.AddInt64(&self.atWork, 1)
+
+ agent.Work() <- self.current.block.Copy()
+ }
+ }
+}
+
+func (self *worker) commitNewWork() {
+ self.mu.Lock()
+ defer self.mu.Unlock()
+ self.uncleMu.Lock()
+ defer self.uncleMu.Unlock()
+
+ block := self.chain.NewBlock(self.coinbase)
+
+ self.current = env(block, self.eth)
+ for _, ancestor := range self.chain.GetAncestors(block, 7) {
+ self.current.family.Add(ancestor.Hash())
+ }
+
+ parent := self.chain.GetBlock(self.current.block.ParentHash())
+ self.current.coinbase.SetGasPool(core.CalcGasLimit(parent, self.current.block))
+
+ transactions := self.eth.TxPool().GetTransactions()
+ sort.Sort(types.TxByNonce{transactions})
+
+ // Keep track of transactions which return errors so they can be removed
+ var (
+ remove types.Transactions
+ tcount = 0
+ )
+gasLimit:
+ for i, tx := range transactions {
+ err := self.commitTransaction(tx)
+ switch {
+ case core.IsNonceErr(err):
+ fallthrough
+ case core.IsInvalidTxErr(err):
+ // Remove invalid transactions
+ from, _ := tx.From()
+ self.chain.TxState().RemoveNonce(from, tx.Nonce())
+ remove = append(remove, tx)
+ minerlogger.Infof("TX (%x) failed, will be removed: %v\n", tx.Hash().Bytes()[:4], err)
+ minerlogger.Infoln(tx)
+ case state.IsGasLimitErr(err):
+ minerlogger.Infof("Gas limit reached for block. %d TXs included in this block\n", i)
+ // Break on gas limit
+ break gasLimit
+ default:
+ tcount++
+ }
+ }
+ self.eth.TxPool().RemoveSet(remove)
+
+ var (
+ uncles []*types.Header
+ badUncles []common.Hash
+ )
+ for hash, uncle := range self.possibleUncles {
+ if len(uncles) == 2 {
+ break
+ }
+
+ if err := self.commitUncle(uncle.Header()); err != nil {
+ minerlogger.Infof("Bad uncle found and will be removed (%x)\n", hash[:4])
+ minerlogger.Debugln(uncle)
+ badUncles = append(badUncles, hash)
+ } else {
+ minerlogger.Infof("commiting %x as uncle\n", hash[:4])
+ uncles = append(uncles, uncle.Header())
+ }
+ }
+ minerlogger.Infof("commit new work on block %v with %d txs & %d uncles\n", self.current.block.Number(), tcount, len(uncles))
+ for _, hash := range badUncles {
+ delete(self.possibleUncles, hash)
+ }
+
+ self.current.block.SetUncles(uncles)
+
+ core.AccumulateRewards(self.current.state, self.current.block)
+
+ self.current.state.Update()
+ self.push()
+}
+
+var (
+ inclusionReward = new(big.Int).Div(core.BlockReward, big.NewInt(32))
+ _uncleReward = new(big.Int).Mul(core.BlockReward, big.NewInt(15))
+ uncleReward = new(big.Int).Div(_uncleReward, big.NewInt(16))
+)
+
+func (self *worker) commitUncle(uncle *types.Header) error {
+ if self.current.uncles.Has(uncle.Hash()) {
+ // Error not unique
+ return core.UncleError("Uncle not unique")
+ }
+ self.current.uncles.Add(uncle.Hash())
+
+ if !self.current.family.Has(uncle.ParentHash) {
+ return core.UncleError(fmt.Sprintf("Uncle's parent unknown (%x)", uncle.ParentHash[0:4]))
+ }
+
+ if self.current.family.Has(uncle.Hash()) {
+ return core.UncleError(fmt.Sprintf("Uncle already in family (%x)", uncle.Hash()))
+ }
+
+ return nil
+}
+
+func (self *worker) commitTransaction(tx *types.Transaction) error {
+ snap := self.current.state.Copy()
+ receipt, _, err := self.proc.ApplyTransaction(self.current.coinbase, self.current.state, self.current.block, tx, self.current.totalUsedGas, true)
+ if err != nil && (core.IsNonceErr(err) || state.IsGasLimitErr(err) || core.IsInvalidTxErr(err)) {
+ self.current.state.Set(snap)
+ return err
+ }
+
+ self.current.block.AddTransaction(tx)
+ self.current.block.AddReceipt(receipt)
+
+ return nil
+}
+
+func (self *worker) HashRate() int64 {
+ var tot int64
+ for _, agent := range self.agents {
+ tot += agent.GetHashRate()
+ }
+
+ return tot
+}
diff --git a/p2p/discover/node.go b/p2p/discover/node.go
new file mode 100644
index 000000000..99cb549a5
--- /dev/null
+++ b/p2p/discover/node.go
@@ -0,0 +1,345 @@
+package discover
+
+import (
+ "crypto/ecdsa"
+ "crypto/elliptic"
+ "encoding/hex"
+ "errors"
+ "fmt"
+ "io"
+ "math/big"
+ "math/rand"
+ "net"
+ "net/url"
+ "strconv"
+ "strings"
+ "sync"
+ "sync/atomic"
+ "time"
+
+ "github.com/ethereum/go-ethereum/crypto"
+ "github.com/ethereum/go-ethereum/crypto/secp256k1"
+ "github.com/ethereum/go-ethereum/rlp"
+)
+
+const nodeIDBits = 512
+
+// Node represents a host on the network.
+type Node struct {
+ ID NodeID
+ IP net.IP
+
+ DiscPort int // UDP listening port for discovery protocol
+ TCPPort int // TCP listening port for RLPx
+
+ // this must be set/read using atomic load and store.
+ activeStamp int64
+}
+
+func newNode(id NodeID, addr *net.UDPAddr) *Node {
+ return &Node{
+ ID: id,
+ IP: addr.IP,
+ DiscPort: addr.Port,
+ TCPPort: addr.Port,
+ }
+}
+
+func (n *Node) isValid() bool {
+ // TODO: don't accept localhost, LAN addresses from internet hosts
+ return !n.IP.IsMulticast() && !n.IP.IsUnspecified() && n.TCPPort != 0 && n.DiscPort != 0
+}
+
+func (n *Node) bumpActive() {
+ stamp := time.Now().Unix()
+ atomic.StoreInt64(&n.activeStamp, stamp)
+}
+
+func (n *Node) active() time.Time {
+ stamp := atomic.LoadInt64(&n.activeStamp)
+ return time.Unix(stamp, 0)
+}
+
+func (n *Node) addr() *net.UDPAddr {
+ return &net.UDPAddr{IP: n.IP, Port: n.DiscPort}
+}
+
+// The string representation of a Node is a URL.
+// Please see ParseNode for a description of the format.
+func (n *Node) String() string {
+ addr := net.TCPAddr{IP: n.IP, Port: n.TCPPort}
+ u := url.URL{
+ Scheme: "enode",
+ User: url.User(fmt.Sprintf("%x", n.ID[:])),
+ Host: addr.String(),
+ }
+ if n.DiscPort != n.TCPPort {
+ u.RawQuery = "discport=" + strconv.Itoa(n.DiscPort)
+ }
+ return u.String()
+}
+
+// ParseNode parses a node URL.
+//
+// A node URL has scheme "enode".
+//
+// The hexadecimal node ID is encoded in the username portion of the
+// URL, separated from the host by an @ sign. The hostname can only be
+// given as an IP address, DNS domain names are not allowed. The port
+// in the host name section is the TCP listening port. If the TCP and
+// UDP (discovery) ports differ, the UDP port is specified as query
+// parameter "discport".
+//
+// In the following example, the node URL describes
+// a node with IP address 10.3.58.6, TCP listening port 30303
+// and UDP discovery port 30301.
+//
+// enode://<hex node id>@10.3.58.6:30303?discport=30301
+func ParseNode(rawurl string) (*Node, error) {
+ var n Node
+ u, err := url.Parse(rawurl)
+ if u.Scheme != "enode" {
+ return nil, errors.New("invalid URL scheme, want \"enode\"")
+ }
+ if u.User == nil {
+ return nil, errors.New("does not contain node ID")
+ }
+ if n.ID, err = HexID(u.User.String()); err != nil {
+ return nil, fmt.Errorf("invalid node ID (%v)", err)
+ }
+ ip, port, err := net.SplitHostPort(u.Host)
+ if err != nil {
+ return nil, fmt.Errorf("invalid host: %v", err)
+ }
+ if n.IP = net.ParseIP(ip); n.IP == nil {
+ return nil, errors.New("invalid IP address")
+ }
+ if n.TCPPort, err = strconv.Atoi(port); err != nil {
+ return nil, errors.New("invalid port")
+ }
+ qv := u.Query()
+ if qv.Get("discport") == "" {
+ n.DiscPort = n.TCPPort
+ } else {
+ if n.DiscPort, err = strconv.Atoi(qv.Get("discport")); err != nil {
+ return nil, errors.New("invalid discport in query")
+ }
+ }
+ return &n, nil
+}
+
+// MustParseNode parses a node URL. It panics if the URL is not valid.
+func MustParseNode(rawurl string) *Node {
+ n, err := ParseNode(rawurl)
+ if err != nil {
+ panic("invalid node URL: " + err.Error())
+ }
+ return n
+}
+
+func (n Node) EncodeRLP(w io.Writer) error {
+ return rlp.Encode(w, rpcNode{IP: n.IP.String(), Port: uint16(n.TCPPort), ID: n.ID})
+}
+func (n *Node) DecodeRLP(s *rlp.Stream) (err error) {
+ var ext rpcNode
+ if err = s.Decode(&ext); err == nil {
+ n.TCPPort = int(ext.Port)
+ n.DiscPort = int(ext.Port)
+ n.ID = ext.ID
+ if n.IP = net.ParseIP(ext.IP); n.IP == nil {
+ return errors.New("invalid IP string")
+ }
+ }
+ return err
+}
+
+// NodeID is a unique identifier for each node.
+// The node identifier is a marshaled elliptic curve public key.
+type NodeID [nodeIDBits / 8]byte
+
+// NodeID prints as a long hexadecimal number.
+func (n NodeID) String() string {
+ return fmt.Sprintf("%x", n[:])
+}
+
+// The Go syntax representation of a NodeID is a call to HexID.
+func (n NodeID) GoString() string {
+ return fmt.Sprintf("discover.HexID(\"%x\")", n[:])
+}
+
+// HexID converts a hex string to a NodeID.
+// The string may be prefixed with 0x.
+func HexID(in string) (NodeID, error) {
+ if strings.HasPrefix(in, "0x") {
+ in = in[2:]
+ }
+ var id NodeID
+ b, err := hex.DecodeString(in)
+ if err != nil {
+ return id, err
+ } else if len(b) != len(id) {
+ return id, fmt.Errorf("wrong length, need %d hex bytes", len(id))
+ }
+ copy(id[:], b)
+ return id, nil
+}
+
+// MustHexID converts a hex string to a NodeID.
+// It panics if the string is not a valid NodeID.
+func MustHexID(in string) NodeID {
+ id, err := HexID(in)
+ if err != nil {
+ panic(err)
+ }
+ return id
+}
+
+// PubkeyID returns a marshaled representation of the given public key.
+func PubkeyID(pub *ecdsa.PublicKey) NodeID {
+ var id NodeID
+ pbytes := elliptic.Marshal(pub.Curve, pub.X, pub.Y)
+ if len(pbytes)-1 != len(id) {
+ panic(fmt.Errorf("need %d bit pubkey, got %d bits", (len(id)+1)*8, len(pbytes)))
+ }
+ copy(id[:], pbytes[1:])
+ return id
+}
+
+// Pubkey returns the public key represented by the node ID.
+// It returns an error if the ID is not a point on the curve.
+func (id NodeID) Pubkey() (*ecdsa.PublicKey, error) {
+ p := &ecdsa.PublicKey{Curve: crypto.S256(), X: new(big.Int), Y: new(big.Int)}
+ half := len(id) / 2
+ p.X.SetBytes(id[:half])
+ p.Y.SetBytes(id[half:])
+ if !p.Curve.IsOnCurve(p.X, p.Y) {
+ return nil, errors.New("not a point on the S256 curve")
+ }
+ return p, nil
+}
+
+// recoverNodeID computes the public key used to sign the
+// given hash from the signature.
+func recoverNodeID(hash, sig []byte) (id NodeID, err error) {
+ pubkey, err := secp256k1.RecoverPubkey(hash, sig)
+ if err != nil {
+ return id, err
+ }
+ if len(pubkey)-1 != len(id) {
+ return id, fmt.Errorf("recovered pubkey has %d bits, want %d bits", len(pubkey)*8, (len(id)+1)*8)
+ }
+ for i := range id {
+ id[i] = pubkey[i+1]
+ }
+ return id, nil
+}
+
+// distcmp compares the distances a->target and b->target.
+// Returns -1 if a is closer to target, 1 if b is closer to target
+// and 0 if they are equal.
+func distcmp(target, a, b NodeID) int {
+ for i := range target {
+ da := a[i] ^ target[i]
+ db := b[i] ^ target[i]
+ if da > db {
+ return 1
+ } else if da < db {
+ return -1
+ }
+ }
+ return 0
+}
+
+// table of leading zero counts for bytes [0..255]
+var lzcount = [256]int{
+ 8, 7, 6, 6, 5, 5, 5, 5,
+ 4, 4, 4, 4, 4, 4, 4, 4,
+ 3, 3, 3, 3, 3, 3, 3, 3,
+ 3, 3, 3, 3, 3, 3, 3, 3,
+ 2, 2, 2, 2, 2, 2, 2, 2,
+ 2, 2, 2, 2, 2, 2, 2, 2,
+ 2, 2, 2, 2, 2, 2, 2, 2,
+ 2, 2, 2, 2, 2, 2, 2, 2,
+ 1, 1, 1, 1, 1, 1, 1, 1,
+ 1, 1, 1, 1, 1, 1, 1, 1,
+ 1, 1, 1, 1, 1, 1, 1, 1,
+ 1, 1, 1, 1, 1, 1, 1, 1,
+ 1, 1, 1, 1, 1, 1, 1, 1,
+ 1, 1, 1, 1, 1, 1, 1, 1,
+ 1, 1, 1, 1, 1, 1, 1, 1,
+ 1, 1, 1, 1, 1, 1, 1, 1,
+ 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0,
+}
+
+// logdist returns the logarithmic distance between a and b, log2(a ^ b).
+func logdist(a, b NodeID) int {
+ lz := 0
+ for i := range a {
+ x := a[i] ^ b[i]
+ if x == 0 {
+ lz += 8
+ } else {
+ lz += lzcount[x]
+ break
+ }
+ }
+ return len(a)*8 - lz
+}
+
+// randomID returns a random NodeID such that logdist(a, b) == n
+func randomID(a NodeID, n int) (b NodeID) {
+ if n == 0 {
+ return a
+ }
+ // flip bit at position n, fill the rest with random bits
+ b = a
+ pos := len(a) - n/8 - 1
+ bit := byte(0x01) << (byte(n%8) - 1)
+ if bit == 0 {
+ pos++
+ bit = 0x80
+ }
+ b[pos] = a[pos]&^bit | ^a[pos]&bit // TODO: randomize end bits
+ for i := pos + 1; i < len(a); i++ {
+ b[i] = byte(rand.Intn(255))
+ }
+ return b
+}
+
+// nodeDB stores all nodes we know about.
+type nodeDB struct {
+ mu sync.RWMutex
+ byID map[NodeID]*Node
+}
+
+func (db *nodeDB) get(id NodeID) *Node {
+ db.mu.RLock()
+ defer db.mu.RUnlock()
+ return db.byID[id]
+}
+
+func (db *nodeDB) add(id NodeID, addr *net.UDPAddr, tcpPort uint16) *Node {
+ db.mu.Lock()
+ defer db.mu.Unlock()
+ if db.byID == nil {
+ db.byID = make(map[NodeID]*Node)
+ }
+ n := &Node{ID: id, IP: addr.IP, DiscPort: addr.Port, TCPPort: int(tcpPort)}
+ db.byID[n.ID] = n
+ return n
+}
diff --git a/p2p/discover/node_test.go b/p2p/discover/node_test.go
new file mode 100644
index 000000000..60b01b6ca
--- /dev/null
+++ b/p2p/discover/node_test.go
@@ -0,0 +1,219 @@
+package discover
+
+import (
+ "math/big"
+ "math/rand"
+ "net"
+ "reflect"
+ "testing"
+ "testing/quick"
+ "time"
+
+ "github.com/ethereum/go-ethereum/crypto"
+)
+
+var (
+ quickrand = rand.New(rand.NewSource(time.Now().Unix()))
+ quickcfg = &quick.Config{MaxCount: 5000, Rand: quickrand}
+)
+
+var parseNodeTests = []struct {
+ rawurl string
+ wantError string
+ wantResult *Node
+}{
+ {
+ rawurl: "http://foobar",
+ wantError: `invalid URL scheme, want "enode"`,
+ },
+ {
+ rawurl: "enode://foobar",
+ wantError: `does not contain node ID`,
+ },
+ {
+ rawurl: "enode://01010101@123.124.125.126:3",
+ wantError: `invalid node ID (wrong length, need 64 hex bytes)`,
+ },
+ {
+ rawurl: "enode://1dd9d65c4552b5eb43d5ad55a2ee3f56c6cbc1c64a5c8d659f51fcd51bace24351232b8d7821617d2b29b54b81cdefb9b3e9c37d7fd5f63270bcc9e1a6f6a439@hostname:3",
+ wantError: `invalid IP address`,
+ },
+ {
+ rawurl: "enode://1dd9d65c4552b5eb43d5ad55a2ee3f56c6cbc1c64a5c8d659f51fcd51bace24351232b8d7821617d2b29b54b81cdefb9b3e9c37d7fd5f63270bcc9e1a6f6a439@127.0.0.1:foo",
+ wantError: `invalid port`,
+ },
+ {
+ rawurl: "enode://1dd9d65c4552b5eb43d5ad55a2ee3f56c6cbc1c64a5c8d659f51fcd51bace24351232b8d7821617d2b29b54b81cdefb9b3e9c37d7fd5f63270bcc9e1a6f6a439@127.0.0.1:3?discport=foo",
+ wantError: `invalid discport in query`,
+ },
+ {
+ rawurl: "enode://1dd9d65c4552b5eb43d5ad55a2ee3f56c6cbc1c64a5c8d659f51fcd51bace24351232b8d7821617d2b29b54b81cdefb9b3e9c37d7fd5f63270bcc9e1a6f6a439@127.0.0.1:52150",
+ wantResult: &Node{
+ ID: MustHexID("0x1dd9d65c4552b5eb43d5ad55a2ee3f56c6cbc1c64a5c8d659f51fcd51bace24351232b8d7821617d2b29b54b81cdefb9b3e9c37d7fd5f63270bcc9e1a6f6a439"),
+ IP: net.ParseIP("127.0.0.1"),
+ DiscPort: 52150,
+ TCPPort: 52150,
+ },
+ },
+ {
+ rawurl: "enode://1dd9d65c4552b5eb43d5ad55a2ee3f56c6cbc1c64a5c8d659f51fcd51bace24351232b8d7821617d2b29b54b81cdefb9b3e9c37d7fd5f63270bcc9e1a6f6a439@[::]:52150",
+ wantResult: &Node{
+ ID: MustHexID("0x1dd9d65c4552b5eb43d5ad55a2ee3f56c6cbc1c64a5c8d659f51fcd51bace24351232b8d7821617d2b29b54b81cdefb9b3e9c37d7fd5f63270bcc9e1a6f6a439"),
+ IP: net.ParseIP("::"),
+ DiscPort: 52150,
+ TCPPort: 52150,
+ },
+ },
+ {
+ rawurl: "enode://1dd9d65c4552b5eb43d5ad55a2ee3f56c6cbc1c64a5c8d659f51fcd51bace24351232b8d7821617d2b29b54b81cdefb9b3e9c37d7fd5f63270bcc9e1a6f6a439@127.0.0.1:52150?discport=223344",
+ wantResult: &Node{
+ ID: MustHexID("0x1dd9d65c4552b5eb43d5ad55a2ee3f56c6cbc1c64a5c8d659f51fcd51bace24351232b8d7821617d2b29b54b81cdefb9b3e9c37d7fd5f63270bcc9e1a6f6a439"),
+ IP: net.ParseIP("127.0.0.1"),
+ DiscPort: 223344,
+ TCPPort: 52150,
+ },
+ },
+}
+
+func TestParseNode(t *testing.T) {
+ for i, test := range parseNodeTests {
+ n, err := ParseNode(test.rawurl)
+ if err == nil && test.wantError != "" {
+ t.Errorf("test %d: got nil error, expected %#q", i, test.wantError)
+ continue
+ }
+ if err != nil && err.Error() != test.wantError {
+ t.Errorf("test %d: got error %#q, expected %#q", i, err.Error(), test.wantError)
+ continue
+ }
+ if !reflect.DeepEqual(n, test.wantResult) {
+ t.Errorf("test %d: result mismatch:\ngot: %#v, want: %#v", i, n, test.wantResult)
+ }
+ }
+}
+
+func TestNodeString(t *testing.T) {
+ for i, test := range parseNodeTests {
+ if test.wantError != "" {
+ continue
+ }
+ str := test.wantResult.String()
+ if str != test.rawurl {
+ t.Errorf("test %d: Node.String() mismatch:\ngot: %s\nwant: %s", i, str, test.rawurl)
+ }
+ }
+}
+
+func TestHexID(t *testing.T) {
+ ref := NodeID{0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 128, 106, 217, 182, 31, 165, 174, 1, 67, 7, 235, 220, 150, 66, 83, 173, 205, 159, 44, 10, 57, 42, 161, 26, 188}
+ id1 := MustHexID("0x000000000000000000000000000000000000000000000000000000000000000000000000000000806ad9b61fa5ae014307ebdc964253adcd9f2c0a392aa11abc")
+ id2 := MustHexID("000000000000000000000000000000000000000000000000000000000000000000000000000000806ad9b61fa5ae014307ebdc964253adcd9f2c0a392aa11abc")
+
+ if id1 != ref {
+ t.Errorf("wrong id1\ngot %v\nwant %v", id1[:], ref[:])
+ }
+ if id2 != ref {
+ t.Errorf("wrong id2\ngot %v\nwant %v", id2[:], ref[:])
+ }
+}
+
+func TestNodeID_recover(t *testing.T) {
+ prv := newkey()
+ hash := make([]byte, 32)
+ sig, err := crypto.Sign(hash, prv)
+ if err != nil {
+ t.Fatalf("signing error: %v", err)
+ }
+
+ pub := PubkeyID(&prv.PublicKey)
+ recpub, err := recoverNodeID(hash, sig)
+ if err != nil {
+ t.Fatalf("recovery error: %v", err)
+ }
+ if pub != recpub {
+ t.Errorf("recovered wrong pubkey:\ngot: %v\nwant: %v", recpub, pub)
+ }
+
+ ecdsa, err := pub.Pubkey()
+ if err != nil {
+ t.Errorf("Pubkey error: %v", err)
+ }
+ if !reflect.DeepEqual(ecdsa, &prv.PublicKey) {
+ t.Errorf("Pubkey mismatch:\n got: %#v\n want: %#v", ecdsa, &prv.PublicKey)
+ }
+}
+
+func TestNodeID_pubkeyBad(t *testing.T) {
+ ecdsa, err := NodeID{}.Pubkey()
+ if err == nil {
+ t.Error("expected error for zero ID")
+ }
+ if ecdsa != nil {
+ t.Error("expected nil result")
+ }
+}
+
+func TestNodeID_distcmp(t *testing.T) {
+ distcmpBig := func(target, a, b NodeID) int {
+ tbig := new(big.Int).SetBytes(target[:])
+ abig := new(big.Int).SetBytes(a[:])
+ bbig := new(big.Int).SetBytes(b[:])
+ return new(big.Int).Xor(tbig, abig).Cmp(new(big.Int).Xor(tbig, bbig))
+ }
+ if err := quick.CheckEqual(distcmp, distcmpBig, quickcfg); err != nil {
+ t.Error(err)
+ }
+}
+
+// the random tests is likely to miss the case where they're equal.
+func TestNodeID_distcmpEqual(t *testing.T) {
+ base := NodeID{0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15}
+ x := NodeID{15, 14, 13, 12, 11, 10, 9, 8, 7, 6, 5, 4, 3, 2, 1, 0}
+ if distcmp(base, x, x) != 0 {
+ t.Errorf("distcmp(base, x, x) != 0")
+ }
+}
+
+func TestNodeID_logdist(t *testing.T) {
+ logdistBig := func(a, b NodeID) int {
+ abig, bbig := new(big.Int).SetBytes(a[:]), new(big.Int).SetBytes(b[:])
+ return new(big.Int).Xor(abig, bbig).BitLen()
+ }
+ if err := quick.CheckEqual(logdist, logdistBig, quickcfg); err != nil {
+ t.Error(err)
+ }
+}
+
+// the random tests is likely to miss the case where they're equal.
+func TestNodeID_logdistEqual(t *testing.T) {
+ x := NodeID{0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15}
+ if logdist(x, x) != 0 {
+ t.Errorf("logdist(x, x) != 0")
+ }
+}
+
+func TestNodeID_randomID(t *testing.T) {
+ // we don't use quick.Check here because its output isn't
+ // very helpful when the test fails.
+ for i := 0; i < quickcfg.MaxCount; i++ {
+ a := gen(NodeID{}, quickrand).(NodeID)
+ dist := quickrand.Intn(len(NodeID{}) * 8)
+ result := randomID(a, dist)
+ actualdist := logdist(result, a)
+
+ if dist != actualdist {
+ t.Log("a: ", a)
+ t.Log("result:", result)
+ t.Fatalf("#%d: distance of result is %d, want %d", i, actualdist, dist)
+ }
+ }
+}
+
+func (NodeID) Generate(rand *rand.Rand, size int) reflect.Value {
+ var id NodeID
+ m := rand.Intn(len(id))
+ for i := len(id) - 1; i > m; i-- {
+ id[i] = byte(rand.Uint32())
+ }
+ return reflect.ValueOf(id)
+}
diff --git a/p2p/discover/table.go b/p2p/discover/table.go
new file mode 100644
index 000000000..dbf86c084
--- /dev/null
+++ b/p2p/discover/table.go
@@ -0,0 +1,363 @@
+// Package discover implements the Node Discovery Protocol.
+//
+// The Node Discovery protocol provides a way to find RLPx nodes that
+// can be connected to. It uses a Kademlia-like protocol to maintain a
+// distributed database of the IDs and endpoints of all listening
+// nodes.
+package discover
+
+import (
+ "net"
+ "sort"
+ "sync"
+ "time"
+)
+
+const (
+ alpha = 3 // Kademlia concurrency factor
+ bucketSize = 16 // Kademlia bucket size
+ nBuckets = nodeIDBits + 1 // Number of buckets
+ maxBondingPingPongs = 10
+)
+
+type Table struct {
+ mutex sync.Mutex // protects buckets, their content, and nursery
+ buckets [nBuckets]*bucket // index of known nodes by distance
+ nursery []*Node // bootstrap nodes
+
+ bondmu sync.Mutex
+ bonding map[NodeID]*bondproc
+ bondslots chan struct{} // limits total number of active bonding processes
+
+ net transport
+ self *Node // metadata of the local node
+ db *nodeDB
+}
+
+type bondproc struct {
+ err error
+ n *Node
+ done chan struct{}
+}
+
+// transport is implemented by the UDP transport.
+// it is an interface so we can test without opening lots of UDP
+// sockets and without generating a private key.
+type transport interface {
+ ping(NodeID, *net.UDPAddr) error
+ waitping(NodeID) error
+ findnode(toid NodeID, addr *net.UDPAddr, target NodeID) ([]*Node, error)
+ close()
+}
+
+// bucket contains nodes, ordered by their last activity.
+// the entry that was most recently active is the last element
+// in entries.
+type bucket struct {
+ lastLookup time.Time
+ entries []*Node
+}
+
+func newTable(t transport, ourID NodeID, ourAddr *net.UDPAddr) *Table {
+ tab := &Table{
+ net: t,
+ db: new(nodeDB),
+ self: newNode(ourID, ourAddr),
+ bonding: make(map[NodeID]*bondproc),
+ bondslots: make(chan struct{}, maxBondingPingPongs),
+ }
+ for i := 0; i < cap(tab.bondslots); i++ {
+ tab.bondslots <- struct{}{}
+ }
+ for i := range tab.buckets {
+ tab.buckets[i] = new(bucket)
+ }
+ return tab
+}
+
+// Self returns the local node.
+func (tab *Table) Self() *Node {
+ return tab.self
+}
+
+// Close terminates the network listener.
+func (tab *Table) Close() {
+ tab.net.close()
+}
+
+// Bootstrap sets the bootstrap nodes. These nodes are used to connect
+// to the network if the table is empty. Bootstrap will also attempt to
+// fill the table by performing random lookup operations on the
+// network.
+func (tab *Table) Bootstrap(nodes []*Node) {
+ tab.mutex.Lock()
+ // TODO: maybe filter nodes with bad fields (nil, etc.) to avoid strange crashes
+ tab.nursery = make([]*Node, 0, len(nodes))
+ for _, n := range nodes {
+ cpy := *n
+ tab.nursery = append(tab.nursery, &cpy)
+ }
+ tab.mutex.Unlock()
+ tab.refresh()
+}
+
+// Lookup performs a network search for nodes close
+// to the given target. It approaches the target by querying
+// nodes that are closer to it on each iteration.
+func (tab *Table) Lookup(target NodeID) []*Node {
+ var (
+ asked = make(map[NodeID]bool)
+ seen = make(map[NodeID]bool)
+ reply = make(chan []*Node, alpha)
+ pendingQueries = 0
+ )
+ // don't query further if we hit the target or ourself.
+ // unlikely to happen often in practice.
+ asked[target] = true
+ asked[tab.self.ID] = true
+
+ tab.mutex.Lock()
+ // update last lookup stamp (for refresh logic)
+ tab.buckets[logdist(tab.self.ID, target)].lastLookup = time.Now()
+ // generate initial result set
+ result := tab.closest(target, bucketSize)
+ tab.mutex.Unlock()
+
+ for {
+ // ask the alpha closest nodes that we haven't asked yet
+ for i := 0; i < len(result.entries) && pendingQueries < alpha; i++ {
+ n := result.entries[i]
+ if !asked[n.ID] {
+ asked[n.ID] = true
+ pendingQueries++
+ go func() {
+ r, _ := tab.net.findnode(n.ID, n.addr(), target)
+ reply <- tab.bondall(r)
+ }()
+ }
+ }
+ if pendingQueries == 0 {
+ // we have asked all closest nodes, stop the search
+ break
+ }
+ // wait for the next reply
+ for _, n := range <-reply {
+ if n != nil && !seen[n.ID] {
+ seen[n.ID] = true
+ result.push(n, bucketSize)
+ }
+ }
+ pendingQueries--
+ }
+ return result.entries
+}
+
+// refresh performs a lookup for a random target to keep buckets full.
+func (tab *Table) refresh() {
+ ld := -1 // logdist of chosen bucket
+ tab.mutex.Lock()
+ for i, b := range tab.buckets {
+ if i > 0 && b.lastLookup.Before(time.Now().Add(-1*time.Hour)) {
+ ld = i
+ break
+ }
+ }
+ tab.mutex.Unlock()
+
+ result := tab.Lookup(randomID(tab.self.ID, ld))
+ if len(result) == 0 {
+ // bootstrap the table with a self lookup
+ all := tab.bondall(tab.nursery)
+ tab.mutex.Lock()
+ tab.add(all)
+ tab.mutex.Unlock()
+ tab.Lookup(tab.self.ID)
+ // TODO: the Kademlia paper says that we're supposed to perform
+ // random lookups in all buckets further away than our closest neighbor.
+ }
+}
+
+// closest returns the n nodes in the table that are closest to the
+// given id. The caller must hold tab.mutex.
+func (tab *Table) closest(target NodeID, nresults int) *nodesByDistance {
+ // This is a very wasteful way to find the closest nodes but
+ // obviously correct. I believe that tree-based buckets would make
+ // this easier to implement efficiently.
+ close := &nodesByDistance{target: target}
+ for _, b := range tab.buckets {
+ for _, n := range b.entries {
+ close.push(n, nresults)
+ }
+ }
+ return close
+}
+
+func (tab *Table) len() (n int) {
+ for _, b := range tab.buckets {
+ n += len(b.entries)
+ }
+ return n
+}
+
+// bondall bonds with all given nodes concurrently and returns
+// those nodes for which bonding has probably succeeded.
+func (tab *Table) bondall(nodes []*Node) (result []*Node) {
+ rc := make(chan *Node, len(nodes))
+ for i := range nodes {
+ go func(n *Node) {
+ nn, _ := tab.bond(false, n.ID, n.addr(), uint16(n.TCPPort))
+ rc <- nn
+ }(nodes[i])
+ }
+ for _ = range nodes {
+ if n := <-rc; n != nil {
+ result = append(result, n)
+ }
+ }
+ return result
+}
+
+// bond ensures the local node has a bond with the given remote node.
+// It also attempts to insert the node into the table if bonding succeeds.
+// The caller must not hold tab.mutex.
+//
+// A bond is must be established before sending findnode requests.
+// Both sides must have completed a ping/pong exchange for a bond to
+// exist. The total number of active bonding processes is limited in
+// order to restrain network use.
+//
+// bond is meant to operate idempotently in that bonding with a remote
+// node which still remembers a previously established bond will work.
+// The remote node will simply not send a ping back, causing waitping
+// to time out.
+//
+// If pinged is true, the remote node has just pinged us and one half
+// of the process can be skipped.
+func (tab *Table) bond(pinged bool, id NodeID, addr *net.UDPAddr, tcpPort uint16) (*Node, error) {
+ var n *Node
+ if n = tab.db.get(id); n == nil {
+ tab.bondmu.Lock()
+ w := tab.bonding[id]
+ if w != nil {
+ // Wait for an existing bonding process to complete.
+ tab.bondmu.Unlock()
+ <-w.done
+ } else {
+ // Register a new bonding process.
+ w = &bondproc{done: make(chan struct{})}
+ tab.bonding[id] = w
+ tab.bondmu.Unlock()
+ // Do the ping/pong. The result goes into w.
+ tab.pingpong(w, pinged, id, addr, tcpPort)
+ // Unregister the process after it's done.
+ tab.bondmu.Lock()
+ delete(tab.bonding, id)
+ tab.bondmu.Unlock()
+ }
+ n = w.n
+ if w.err != nil {
+ return nil, w.err
+ }
+ }
+ tab.mutex.Lock()
+ defer tab.mutex.Unlock()
+ if b := tab.buckets[logdist(tab.self.ID, n.ID)]; !b.bump(n) {
+ tab.pingreplace(n, b)
+ }
+ return n, nil
+}
+
+func (tab *Table) pingpong(w *bondproc, pinged bool, id NodeID, addr *net.UDPAddr, tcpPort uint16) {
+ <-tab.bondslots
+ defer func() { tab.bondslots <- struct{}{} }()
+ if w.err = tab.net.ping(id, addr); w.err != nil {
+ close(w.done)
+ return
+ }
+ if !pinged {
+ // Give the remote node a chance to ping us before we start
+ // sending findnode requests. If they still remember us,
+ // waitping will simply time out.
+ tab.net.waitping(id)
+ }
+ w.n = tab.db.add(id, addr, tcpPort)
+ close(w.done)
+}
+
+func (tab *Table) pingreplace(new *Node, b *bucket) {
+ if len(b.entries) == bucketSize {
+ oldest := b.entries[bucketSize-1]
+ if err := tab.net.ping(oldest.ID, oldest.addr()); err == nil {
+ // The node responded, we don't need to replace it.
+ return
+ }
+ } else {
+ // Add a slot at the end so the last entry doesn't
+ // fall off when adding the new node.
+ b.entries = append(b.entries, nil)
+ }
+ copy(b.entries[1:], b.entries)
+ b.entries[0] = new
+}
+
+// add puts the entries into the table if their corresponding
+// bucket is not full. The caller must hold tab.mutex.
+func (tab *Table) add(entries []*Node) {
+outer:
+ for _, n := range entries {
+ if n == nil || n.ID == tab.self.ID {
+ // skip bad entries. The RLP decoder returns nil for empty
+ // input lists.
+ continue
+ }
+ bucket := tab.buckets[logdist(tab.self.ID, n.ID)]
+ for i := range bucket.entries {
+ if bucket.entries[i].ID == n.ID {
+ // already in bucket
+ continue outer
+ }
+ }
+ if len(bucket.entries) < bucketSize {
+ bucket.entries = append(bucket.entries, n)
+ }
+ }
+}
+
+func (b *bucket) bump(n *Node) bool {
+ for i := range b.entries {
+ if b.entries[i].ID == n.ID {
+ n.bumpActive()
+ // move it to the front
+ copy(b.entries[1:], b.entries[:i])
+ b.entries[0] = n
+ return true
+ }
+ }
+ return false
+}
+
+// nodesByDistance is a list of nodes, ordered by
+// distance to target.
+type nodesByDistance struct {
+ entries []*Node
+ target NodeID
+}
+
+// push adds the given node to the list, keeping the total size below maxElems.
+func (h *nodesByDistance) push(n *Node, maxElems int) {
+ ix := sort.Search(len(h.entries), func(i int) bool {
+ return distcmp(h.target, h.entries[i].ID, n.ID) > 0
+ })
+ if len(h.entries) < maxElems {
+ h.entries = append(h.entries, n)
+ }
+ if ix == len(h.entries) {
+ // farther away than all nodes we already have.
+ // if there was room for it, the node is now the last element.
+ } else {
+ // slide existing entries down to make room
+ // this will overwrite the entry we just appended.
+ copy(h.entries[ix+1:], h.entries[ix:])
+ h.entries[ix] = n
+ }
+}
diff --git a/p2p/discover/table_test.go b/p2p/discover/table_test.go
new file mode 100644
index 000000000..a98376bca
--- /dev/null
+++ b/p2p/discover/table_test.go
@@ -0,0 +1,323 @@
+package discover
+
+import (
+ "crypto/ecdsa"
+ "fmt"
+ "math/rand"
+ "net"
+ "reflect"
+ "testing"
+ "testing/quick"
+
+ "github.com/ethereum/go-ethereum/crypto"
+)
+
+func TestTable_pingReplace(t *testing.T) {
+ doit := func(newNodeIsResponding, lastInBucketIsResponding bool) {
+ transport := newPingRecorder()
+ tab := newTable(transport, NodeID{}, &net.UDPAddr{})
+ last := fillBucket(tab, 200)
+ pingSender := randomID(tab.self.ID, 200)
+
+ // this gotPing should replace the last node
+ // if the last node is not responding.
+ transport.responding[last.ID] = lastInBucketIsResponding
+ transport.responding[pingSender] = newNodeIsResponding
+ tab.bond(true, pingSender, &net.UDPAddr{}, 0)
+
+ // first ping goes to sender (bonding pingback)
+ if !transport.pinged[pingSender] {
+ t.Error("table did not ping back sender")
+ }
+ if newNodeIsResponding {
+ // second ping goes to oldest node in bucket
+ // to see whether it is still alive.
+ if !transport.pinged[last.ID] {
+ t.Error("table did not ping last node in bucket")
+ }
+ }
+
+ tab.mutex.Lock()
+ defer tab.mutex.Unlock()
+ if l := len(tab.buckets[200].entries); l != bucketSize {
+ t.Errorf("wrong bucket size after gotPing: got %d, want %d", bucketSize, l)
+ }
+
+ if lastInBucketIsResponding || !newNodeIsResponding {
+ if !contains(tab.buckets[200].entries, last.ID) {
+ t.Error("last entry was removed")
+ }
+ if contains(tab.buckets[200].entries, pingSender) {
+ t.Error("new entry was added")
+ }
+ } else {
+ if contains(tab.buckets[200].entries, last.ID) {
+ t.Error("last entry was not removed")
+ }
+ if !contains(tab.buckets[200].entries, pingSender) {
+ t.Error("new entry was not added")
+ }
+ }
+ }
+
+ doit(true, true)
+ doit(false, true)
+ doit(false, true)
+ doit(false, false)
+}
+
+func TestBucket_bumpNoDuplicates(t *testing.T) {
+ t.Parallel()
+ cfg := &quick.Config{
+ MaxCount: 1000,
+ Rand: quickrand,
+ Values: func(args []reflect.Value, rand *rand.Rand) {
+ // generate a random list of nodes. this will be the content of the bucket.
+ n := rand.Intn(bucketSize-1) + 1
+ nodes := make([]*Node, n)
+ for i := range nodes {
+ nodes[i] = &Node{ID: randomID(NodeID{}, 200)}
+ }
+ args[0] = reflect.ValueOf(nodes)
+ // generate random bump positions.
+ bumps := make([]int, rand.Intn(100))
+ for i := range bumps {
+ bumps[i] = rand.Intn(len(nodes))
+ }
+ args[1] = reflect.ValueOf(bumps)
+ },
+ }
+
+ prop := func(nodes []*Node, bumps []int) (ok bool) {
+ b := &bucket{entries: make([]*Node, len(nodes))}
+ copy(b.entries, nodes)
+ for i, pos := range bumps {
+ b.bump(b.entries[pos])
+ if hasDuplicates(b.entries) {
+ t.Logf("bucket has duplicates after %d/%d bumps:", i+1, len(bumps))
+ for _, n := range b.entries {
+ t.Logf(" %p", n)
+ }
+ return false
+ }
+ }
+ return true
+ }
+ if err := quick.Check(prop, cfg); err != nil {
+ t.Error(err)
+ }
+}
+
+func fillBucket(tab *Table, ld int) (last *Node) {
+ b := tab.buckets[ld]
+ for len(b.entries) < bucketSize {
+ b.entries = append(b.entries, &Node{ID: randomID(tab.self.ID, ld)})
+ }
+ return b.entries[bucketSize-1]
+}
+
+type pingRecorder struct{ responding, pinged map[NodeID]bool }
+
+func newPingRecorder() *pingRecorder {
+ return &pingRecorder{make(map[NodeID]bool), make(map[NodeID]bool)}
+}
+
+func (t *pingRecorder) findnode(toid NodeID, toaddr *net.UDPAddr, target NodeID) ([]*Node, error) {
+ panic("findnode called on pingRecorder")
+}
+func (t *pingRecorder) close() {
+ panic("close called on pingRecorder")
+}
+func (t *pingRecorder) waitping(from NodeID) error {
+ return nil // remote always pings
+}
+func (t *pingRecorder) ping(toid NodeID, toaddr *net.UDPAddr) error {
+ t.pinged[toid] = true
+ if t.responding[toid] {
+ return nil
+ } else {
+ return errTimeout
+ }
+}
+
+func TestTable_closest(t *testing.T) {
+ t.Parallel()
+
+ test := func(test *closeTest) bool {
+ // for any node table, Target and N
+ tab := newTable(nil, test.Self, &net.UDPAddr{})
+ tab.add(test.All)
+
+ // check that doClosest(Target, N) returns nodes
+ result := tab.closest(test.Target, test.N).entries
+ if hasDuplicates(result) {
+ t.Errorf("result contains duplicates")
+ return false
+ }
+ if !sortedByDistanceTo(test.Target, result) {
+ t.Errorf("result is not sorted by distance to target")
+ return false
+ }
+
+ // check that the number of results is min(N, tablen)
+ wantN := test.N
+ if tlen := tab.len(); tlen < test.N {
+ wantN = tlen
+ }
+ if len(result) != wantN {
+ t.Errorf("wrong number of nodes: got %d, want %d", len(result), wantN)
+ return false
+ } else if len(result) == 0 {
+ return true // no need to check distance
+ }
+
+ // check that the result nodes have minimum distance to target.
+ for _, b := range tab.buckets {
+ for _, n := range b.entries {
+ if contains(result, n.ID) {
+ continue // don't run the check below for nodes in result
+ }
+ farthestResult := result[len(result)-1].ID
+ if distcmp(test.Target, n.ID, farthestResult) < 0 {
+ t.Errorf("table contains node that is closer to target but it's not in result")
+ t.Logf(" Target: %v", test.Target)
+ t.Logf(" Farthest Result: %v", farthestResult)
+ t.Logf(" ID: %v", n.ID)
+ return false
+ }
+ }
+ }
+ return true
+ }
+ if err := quick.Check(test, quickcfg); err != nil {
+ t.Error(err)
+ }
+}
+
+type closeTest struct {
+ Self NodeID
+ Target NodeID
+ All []*Node
+ N int
+}
+
+func (*closeTest) Generate(rand *rand.Rand, size int) reflect.Value {
+ t := &closeTest{
+ Self: gen(NodeID{}, rand).(NodeID),
+ Target: gen(NodeID{}, rand).(NodeID),
+ N: rand.Intn(bucketSize),
+ }
+ for _, id := range gen([]NodeID{}, rand).([]NodeID) {
+ t.All = append(t.All, &Node{ID: id})
+ }
+ return reflect.ValueOf(t)
+}
+
+func TestTable_Lookup(t *testing.T) {
+ self := gen(NodeID{}, quickrand).(NodeID)
+ target := randomID(self, 200)
+ transport := findnodeOracle{t, target}
+ tab := newTable(transport, self, &net.UDPAddr{})
+
+ // lookup on empty table returns no nodes
+ if results := tab.Lookup(target); len(results) > 0 {
+ t.Fatalf("lookup on empty table returned %d results: %#v", len(results), results)
+ }
+ // seed table with initial node (otherwise lookup will terminate immediately)
+ tab.add([]*Node{newNode(randomID(target, 200), &net.UDPAddr{Port: 200})})
+
+ results := tab.Lookup(target)
+ t.Logf("results:")
+ for _, e := range results {
+ t.Logf(" ld=%d, %v", logdist(target, e.ID), e.ID)
+ }
+ if len(results) != bucketSize {
+ t.Errorf("wrong number of results: got %d, want %d", len(results), bucketSize)
+ }
+ if hasDuplicates(results) {
+ t.Errorf("result set contains duplicate entries")
+ }
+ if !sortedByDistanceTo(target, results) {
+ t.Errorf("result set not sorted by distance to target")
+ }
+ if !contains(results, target) {
+ t.Errorf("result set does not contain target")
+ }
+}
+
+// findnode on this transport always returns at least one node
+// that is one bucket closer to the target.
+type findnodeOracle struct {
+ t *testing.T
+ target NodeID
+}
+
+func (t findnodeOracle) findnode(toid NodeID, toaddr *net.UDPAddr, target NodeID) ([]*Node, error) {
+ t.t.Logf("findnode query at dist %d", toaddr.Port)
+ // current log distance is encoded in port number
+ var result []*Node
+ switch toaddr.Port {
+ case 0:
+ panic("query to node at distance 0")
+ default:
+ // TODO: add more randomness to distances
+ next := toaddr.Port - 1
+ for i := 0; i < bucketSize; i++ {
+ result = append(result, &Node{ID: randomID(t.target, next), DiscPort: next})
+ }
+ }
+ return result, nil
+}
+
+func (t findnodeOracle) close() {}
+func (t findnodeOracle) waitping(from NodeID) error { return nil }
+func (t findnodeOracle) ping(toid NodeID, toaddr *net.UDPAddr) error { return nil }
+
+func hasDuplicates(slice []*Node) bool {
+ seen := make(map[NodeID]bool)
+ for _, e := range slice {
+ if seen[e.ID] {
+ return true
+ }
+ seen[e.ID] = true
+ }
+ return false
+}
+
+func sortedByDistanceTo(distbase NodeID, slice []*Node) bool {
+ var last NodeID
+ for i, e := range slice {
+ if i > 0 && distcmp(distbase, e.ID, last) < 0 {
+ return false
+ }
+ last = e.ID
+ }
+ return true
+}
+
+func contains(ns []*Node, id NodeID) bool {
+ for _, n := range ns {
+ if n.ID == id {
+ return true
+ }
+ }
+ return false
+}
+
+// gen wraps quick.Value so it's easier to use.
+// it generates a random value of the given value's type.
+func gen(typ interface{}, rand *rand.Rand) interface{} {
+ v, ok := quick.Value(reflect.TypeOf(typ), rand)
+ if !ok {
+ panic(fmt.Sprintf("couldn't generate random value of type %T", typ))
+ }
+ return v.Interface()
+}
+
+func newkey() *ecdsa.PrivateKey {
+ key, err := crypto.GenerateKey()
+ if err != nil {
+ panic("couldn't generate key: " + err.Error())
+ }
+ return key
+}
diff --git a/p2p/discover/udp.go b/p2p/discover/udp.go
new file mode 100644
index 000000000..e9ede1397
--- /dev/null
+++ b/p2p/discover/udp.go
@@ -0,0 +1,486 @@
+package discover
+
+import (
+ "bytes"
+ "crypto/ecdsa"
+ "errors"
+ "fmt"
+ "net"
+ "time"
+
+ "github.com/ethereum/go-ethereum/crypto"
+ "github.com/ethereum/go-ethereum/logger"
+ "github.com/ethereum/go-ethereum/p2p/nat"
+ "github.com/ethereum/go-ethereum/rlp"
+)
+
+var log = logger.NewLogger("P2P Discovery")
+
+const Version = 3
+
+// Errors
+var (
+ errPacketTooSmall = errors.New("too small")
+ errBadHash = errors.New("bad hash")
+ errExpired = errors.New("expired")
+ errBadVersion = errors.New("version mismatch")
+ errUnsolicitedReply = errors.New("unsolicited reply")
+ errUnknownNode = errors.New("unknown node")
+ errTimeout = errors.New("RPC timeout")
+ errClosed = errors.New("socket closed")
+)
+
+// Timeouts
+const (
+ respTimeout = 300 * time.Millisecond
+ sendTimeout = 300 * time.Millisecond
+ expiration = 20 * time.Second
+
+ refreshInterval = 1 * time.Hour
+)
+
+// RPC packet types
+const (
+ pingPacket = iota + 1 // zero is 'reserved'
+ pongPacket
+ findnodePacket
+ neighborsPacket
+)
+
+// RPC request structures
+type (
+ ping struct {
+ Version uint // must match Version
+ IP string // our IP
+ Port uint16 // our port
+ Expiration uint64
+ }
+
+ // reply to Ping
+ pong struct {
+ ReplyTok []byte
+ Expiration uint64
+ }
+
+ findnode struct {
+ // Id to look up. The responding node will send back nodes
+ // closest to the target.
+ Target NodeID
+ Expiration uint64
+ }
+
+ // reply to findnode
+ neighbors struct {
+ Nodes []*Node
+ Expiration uint64
+ }
+)
+
+type rpcNode struct {
+ IP string
+ Port uint16
+ ID NodeID
+}
+
+type packet interface {
+ handle(t *udp, from *net.UDPAddr, fromID NodeID, mac []byte) error
+}
+
+type conn interface {
+ ReadFromUDP(b []byte) (n int, addr *net.UDPAddr, err error)
+ WriteToUDP(b []byte, addr *net.UDPAddr) (n int, err error)
+ Close() error
+ LocalAddr() net.Addr
+}
+
+// udp implements the RPC protocol.
+type udp struct {
+ conn conn
+ priv *ecdsa.PrivateKey
+
+ addpending chan *pending
+ gotreply chan reply
+
+ closing chan struct{}
+ nat nat.Interface
+
+ *Table
+}
+
+// pending represents a pending reply.
+//
+// some implementations of the protocol wish to send more than one
+// reply packet to findnode. in general, any neighbors packet cannot
+// be matched up with a specific findnode packet.
+//
+// our implementation handles this by storing a callback function for
+// each pending reply. incoming packets from a node are dispatched
+// to all the callback functions for that node.
+type pending struct {
+ // these fields must match in the reply.
+ from NodeID
+ ptype byte
+
+ // time when the request must complete
+ deadline time.Time
+
+ // callback is called when a matching reply arrives. if it returns
+ // true, the callback is removed from the pending reply queue.
+ // if it returns false, the reply is considered incomplete and
+ // the callback will be invoked again for the next matching reply.
+ callback func(resp interface{}) (done bool)
+
+ // errc receives nil when the callback indicates completion or an
+ // error if no further reply is received within the timeout.
+ errc chan<- error
+}
+
+type reply struct {
+ from NodeID
+ ptype byte
+ data interface{}
+ // loop indicates whether there was
+ // a matching request by sending on this channel.
+ matched chan<- bool
+}
+
+// ListenUDP returns a new table that listens for UDP packets on laddr.
+func ListenUDP(priv *ecdsa.PrivateKey, laddr string, natm nat.Interface) (*Table, error) {
+ addr, err := net.ResolveUDPAddr("udp", laddr)
+ if err != nil {
+ return nil, err
+ }
+ conn, err := net.ListenUDP("udp", addr)
+ if err != nil {
+ return nil, err
+ }
+ tab, _ := newUDP(priv, conn, natm)
+ log.Infoln("Listening,", tab.self)
+ return tab, nil
+}
+
+func newUDP(priv *ecdsa.PrivateKey, c conn, natm nat.Interface) (*Table, *udp) {
+ udp := &udp{
+ conn: c,
+ priv: priv,
+ closing: make(chan struct{}),
+ gotreply: make(chan reply),
+ addpending: make(chan *pending),
+ }
+ realaddr := c.LocalAddr().(*net.UDPAddr)
+ if natm != nil {
+ if !realaddr.IP.IsLoopback() {
+ go nat.Map(natm, udp.closing, "udp", realaddr.Port, realaddr.Port, "ethereum discovery")
+ }
+ // TODO: react to external IP changes over time.
+ if ext, err := natm.ExternalIP(); err == nil {
+ realaddr = &net.UDPAddr{IP: ext, Port: realaddr.Port}
+ }
+ }
+ udp.Table = newTable(udp, PubkeyID(&priv.PublicKey), realaddr)
+ go udp.loop()
+ go udp.readLoop()
+ return udp.Table, udp
+}
+
+func (t *udp) close() {
+ close(t.closing)
+ t.conn.Close()
+ // TODO: wait for the loops to end.
+}
+
+// ping sends a ping message to the given node and waits for a reply.
+func (t *udp) ping(toid NodeID, toaddr *net.UDPAddr) error {
+ // TODO: maybe check for ReplyTo field in callback to measure RTT
+ errc := t.pending(toid, pongPacket, func(interface{}) bool { return true })
+ t.send(toaddr, pingPacket, ping{
+ Version: Version,
+ IP: t.self.IP.String(),
+ Port: uint16(t.self.TCPPort),
+ Expiration: uint64(time.Now().Add(expiration).Unix()),
+ })
+ return <-errc
+}
+
+func (t *udp) waitping(from NodeID) error {
+ return <-t.pending(from, pingPacket, func(interface{}) bool { return true })
+}
+
+// findnode sends a findnode request to the given node and waits until
+// the node has sent up to k neighbors.
+func (t *udp) findnode(toid NodeID, toaddr *net.UDPAddr, target NodeID) ([]*Node, error) {
+ nodes := make([]*Node, 0, bucketSize)
+ nreceived := 0
+ errc := t.pending(toid, neighborsPacket, func(r interface{}) bool {
+ reply := r.(*neighbors)
+ for _, n := range reply.Nodes {
+ nreceived++
+ if n.isValid() {
+ nodes = append(nodes, n)
+ }
+ }
+ return nreceived >= bucketSize
+ })
+ t.send(toaddr, findnodePacket, findnode{
+ Target: target,
+ Expiration: uint64(time.Now().Add(expiration).Unix()),
+ })
+ err := <-errc
+ return nodes, err
+}
+
+// pending adds a reply callback to the pending reply queue.
+// see the documentation of type pending for a detailed explanation.
+func (t *udp) pending(id NodeID, ptype byte, callback func(interface{}) bool) <-chan error {
+ ch := make(chan error, 1)
+ p := &pending{from: id, ptype: ptype, callback: callback, errc: ch}
+ select {
+ case t.addpending <- p:
+ // loop will handle it
+ case <-t.closing:
+ ch <- errClosed
+ }
+ return ch
+}
+
+func (t *udp) handleReply(from NodeID, ptype byte, req packet) bool {
+ matched := make(chan bool)
+ select {
+ case t.gotreply <- reply{from, ptype, req, matched}:
+ // loop will handle it
+ return <-matched
+ case <-t.closing:
+ return false
+ }
+}
+
+// loop runs in its own goroutin. it keeps track of
+// the refresh timer and the pending reply queue.
+func (t *udp) loop() {
+ var (
+ pending []*pending
+ nextDeadline time.Time
+ timeout = time.NewTimer(0)
+ refresh = time.NewTicker(refreshInterval)
+ )
+ <-timeout.C // ignore first timeout
+ defer refresh.Stop()
+ defer timeout.Stop()
+
+ rearmTimeout := func() {
+ if len(pending) == 0 || nextDeadline == pending[0].deadline {
+ return
+ }
+ nextDeadline = pending[0].deadline
+ timeout.Reset(nextDeadline.Sub(time.Now()))
+ }
+
+ for {
+ select {
+ case <-refresh.C:
+ go t.refresh()
+
+ case <-t.closing:
+ for _, p := range pending {
+ p.errc <- errClosed
+ }
+ pending = nil
+ return
+
+ case p := <-t.addpending:
+ p.deadline = time.Now().Add(respTimeout)
+ pending = append(pending, p)
+ rearmTimeout()
+
+ case r := <-t.gotreply:
+ var matched bool
+ for i := 0; i < len(pending); i++ {
+ if p := pending[i]; p.from == r.from && p.ptype == r.ptype {
+ matched = true
+ if p.callback(r.data) {
+ // callback indicates the request is done, remove it.
+ p.errc <- nil
+ copy(pending[i:], pending[i+1:])
+ pending = pending[:len(pending)-1]
+ i--
+ }
+ }
+ }
+ r.matched <- matched
+
+ case now := <-timeout.C:
+ // notify and remove callbacks whose deadline is in the past.
+ i := 0
+ for ; i < len(pending) && now.After(pending[i].deadline); i++ {
+ pending[i].errc <- errTimeout
+ }
+ if i > 0 {
+ copy(pending, pending[i:])
+ pending = pending[:len(pending)-i]
+ }
+ rearmTimeout()
+ }
+ }
+}
+
+const (
+ macSize = 256 / 8
+ sigSize = 520 / 8
+ headSize = macSize + sigSize // space of packet frame data
+)
+
+var headSpace = make([]byte, headSize)
+
+func (t *udp) send(toaddr *net.UDPAddr, ptype byte, req interface{}) error {
+ packet, err := encodePacket(t.priv, ptype, req)
+ if err != nil {
+ return err
+ }
+ log.DebugDetailf(">>> %v %T %v\n", toaddr, req, req)
+ if _, err = t.conn.WriteToUDP(packet, toaddr); err != nil {
+ log.DebugDetailln("UDP send failed:", err)
+ }
+ return err
+}
+
+func encodePacket(priv *ecdsa.PrivateKey, ptype byte, req interface{}) ([]byte, error) {
+ b := new(bytes.Buffer)
+ b.Write(headSpace)
+ b.WriteByte(ptype)
+ if err := rlp.Encode(b, req); err != nil {
+ log.Errorln("error encoding packet:", err)
+ return nil, err
+ }
+ packet := b.Bytes()
+ sig, err := crypto.Sign(crypto.Sha3(packet[headSize:]), priv)
+ if err != nil {
+ log.Errorln("could not sign packet:", err)
+ return nil, err
+ }
+ copy(packet[macSize:], sig)
+ // add the hash to the front. Note: this doesn't protect the
+ // packet in any way. Our public key will be part of this hash in
+ // The future.
+ copy(packet, crypto.Sha3(packet[macSize:]))
+ return packet, nil
+}
+
+// readLoop runs in its own goroutine. it handles incoming UDP packets.
+func (t *udp) readLoop() {
+ defer t.conn.Close()
+ buf := make([]byte, 4096) // TODO: good buffer size
+ for {
+ nbytes, from, err := t.conn.ReadFromUDP(buf)
+ if err != nil {
+ return
+ }
+ packet, fromID, hash, err := decodePacket(buf[:nbytes])
+ if err != nil {
+ log.Debugf("Bad packet from %v: %v\n", from, err)
+ continue
+ }
+ log.DebugDetailf("<<< %v %T %v\n", from, packet, packet)
+ go func() {
+ if err := packet.handle(t, from, fromID, hash); err != nil {
+ log.Debugf("error handling %T from %v: %v", packet, from, err)
+ }
+ }()
+ }
+}
+
+func decodePacket(buf []byte) (packet, NodeID, []byte, error) {
+ if len(buf) < headSize+1 {
+ return nil, NodeID{}, nil, errPacketTooSmall
+ }
+ hash, sig, sigdata := buf[:macSize], buf[macSize:headSize], buf[headSize:]
+ shouldhash := crypto.Sha3(buf[macSize:])
+ if !bytes.Equal(hash, shouldhash) {
+ return nil, NodeID{}, nil, errBadHash
+ }
+ fromID, err := recoverNodeID(crypto.Sha3(buf[headSize:]), sig)
+ if err != nil {
+ return nil, NodeID{}, hash, err
+ }
+ var req packet
+ switch ptype := sigdata[0]; ptype {
+ case pingPacket:
+ req = new(ping)
+ case pongPacket:
+ req = new(pong)
+ case findnodePacket:
+ req = new(findnode)
+ case neighborsPacket:
+ req = new(neighbors)
+ default:
+ return nil, fromID, hash, fmt.Errorf("unknown type: %d", ptype)
+ }
+ err = rlp.Decode(bytes.NewReader(sigdata[1:]), req)
+ return req, fromID, hash, err
+}
+
+func (req *ping) handle(t *udp, from *net.UDPAddr, fromID NodeID, mac []byte) error {
+ if expired(req.Expiration) {
+ return errExpired
+ }
+ if req.Version != Version {
+ return errBadVersion
+ }
+ t.send(from, pongPacket, pong{
+ ReplyTok: mac,
+ Expiration: uint64(time.Now().Add(expiration).Unix()),
+ })
+ if !t.handleReply(fromID, pingPacket, req) {
+ // Note: we're ignoring the provided IP address right now
+ t.bond(true, fromID, from, req.Port)
+ }
+ return nil
+}
+
+func (req *pong) handle(t *udp, from *net.UDPAddr, fromID NodeID, mac []byte) error {
+ if expired(req.Expiration) {
+ return errExpired
+ }
+ if !t.handleReply(fromID, pongPacket, req) {
+ return errUnsolicitedReply
+ }
+ return nil
+}
+
+func (req *findnode) handle(t *udp, from *net.UDPAddr, fromID NodeID, mac []byte) error {
+ if expired(req.Expiration) {
+ return errExpired
+ }
+ if t.db.get(fromID) == nil {
+ // No bond exists, we don't process the packet. This prevents
+ // an attack vector where the discovery protocol could be used
+ // to amplify traffic in a DDOS attack. A malicious actor
+ // would send a findnode request with the IP address and UDP
+ // port of the target as the source address. The recipient of
+ // the findnode packet would then send a neighbors packet
+ // (which is a much bigger packet than findnode) to the victim.
+ return errUnknownNode
+ }
+ t.mutex.Lock()
+ closest := t.closest(req.Target, bucketSize).entries
+ t.mutex.Unlock()
+
+ t.send(from, neighborsPacket, neighbors{
+ Nodes: closest,
+ Expiration: uint64(time.Now().Add(expiration).Unix()),
+ })
+ return nil
+}
+
+func (req *neighbors) handle(t *udp, from *net.UDPAddr, fromID NodeID, mac []byte) error {
+ if expired(req.Expiration) {
+ return errExpired
+ }
+ if !t.handleReply(fromID, neighborsPacket, req) {
+ return errUnsolicitedReply
+ }
+ return nil
+}
+
+func expired(ts uint64) bool {
+ return time.Unix(int64(ts), 0).Before(time.Now())
+}
diff --git a/p2p/discover/udp_test.go b/p2p/discover/udp_test.go
new file mode 100644
index 000000000..c6c4d78e3
--- /dev/null
+++ b/p2p/discover/udp_test.go
@@ -0,0 +1,339 @@
+package discover
+
+import (
+ "bytes"
+ "crypto/ecdsa"
+ "errors"
+ "fmt"
+ "io"
+ logpkg "log"
+ "net"
+ "os"
+ "path"
+ "reflect"
+ "runtime"
+ "sync"
+ "testing"
+ "time"
+
+ "github.com/ethereum/go-ethereum/logger"
+)
+
+func init() {
+ logger.AddLogSystem(logger.NewStdLogSystem(os.Stdout, logpkg.LstdFlags, logger.ErrorLevel))
+}
+
+type udpTest struct {
+ t *testing.T
+ pipe *dgramPipe
+ table *Table
+ udp *udp
+ sent [][]byte
+ localkey, remotekey *ecdsa.PrivateKey
+ remoteaddr *net.UDPAddr
+}
+
+func newUDPTest(t *testing.T) *udpTest {
+ test := &udpTest{
+ t: t,
+ pipe: newpipe(),
+ localkey: newkey(),
+ remotekey: newkey(),
+ remoteaddr: &net.UDPAddr{IP: net.IP{1, 2, 3, 4}, Port: 30303},
+ }
+ test.table, test.udp = newUDP(test.localkey, test.pipe, nil)
+ return test
+}
+
+// handles a packet as if it had been sent to the transport.
+func (test *udpTest) packetIn(wantError error, ptype byte, data packet) error {
+ enc, err := encodePacket(test.remotekey, ptype, data)
+ if err != nil {
+ return test.errorf("packet (%d) encode error: %v", err)
+ }
+ test.sent = append(test.sent, enc)
+ err = data.handle(test.udp, test.remoteaddr, PubkeyID(&test.remotekey.PublicKey), enc[:macSize])
+ if err != wantError {
+ return test.errorf("error mismatch: got %q, want %q", err, wantError)
+ }
+ return nil
+}
+
+// waits for a packet to be sent by the transport.
+// validate should have type func(*udpTest, X) error, where X is a packet type.
+func (test *udpTest) waitPacketOut(validate interface{}) error {
+ dgram := test.pipe.waitPacketOut()
+ p, _, _, err := decodePacket(dgram)
+ if err != nil {
+ return test.errorf("sent packet decode error: %v", err)
+ }
+ fn := reflect.ValueOf(validate)
+ exptype := fn.Type().In(0)
+ if reflect.TypeOf(p) != exptype {
+ return test.errorf("sent packet type mismatch, got: %v, want: %v", reflect.TypeOf(p), exptype)
+ }
+ fn.Call([]reflect.Value{reflect.ValueOf(p)})
+ return nil
+}
+
+func (test *udpTest) errorf(format string, args ...interface{}) error {
+ _, file, line, ok := runtime.Caller(2) // errorf + waitPacketOut
+ if ok {
+ file = path.Base(file)
+ } else {
+ file = "???"
+ line = 1
+ }
+ err := fmt.Errorf(format, args...)
+ fmt.Printf("\t%s:%d: %v\n", file, line, err)
+ test.t.Fail()
+ return err
+}
+
+// shared test variables
+var (
+ futureExp = uint64(time.Now().Add(10 * time.Hour).Unix())
+ testTarget = MustHexID("01010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101010101")
+)
+
+func TestUDP_packetErrors(t *testing.T) {
+ test := newUDPTest(t)
+ defer test.table.Close()
+
+ test.packetIn(errExpired, pingPacket, &ping{IP: "foo", Port: 99, Version: Version})
+ test.packetIn(errBadVersion, pingPacket, &ping{IP: "foo", Port: 99, Version: 99, Expiration: futureExp})
+ test.packetIn(errUnsolicitedReply, pongPacket, &pong{ReplyTok: []byte{}, Expiration: futureExp})
+ test.packetIn(errUnknownNode, findnodePacket, &findnode{Expiration: futureExp})
+ test.packetIn(errUnsolicitedReply, neighborsPacket, &neighbors{Expiration: futureExp})
+}
+
+func TestUDP_pingTimeout(t *testing.T) {
+ t.Parallel()
+ test := newUDPTest(t)
+ defer test.table.Close()
+
+ toaddr := &net.UDPAddr{IP: net.ParseIP("1.2.3.4"), Port: 2222}
+ toid := NodeID{1, 2, 3, 4}
+ if err := test.udp.ping(toid, toaddr); err != errTimeout {
+ t.Error("expected timeout error, got", err)
+ }
+}
+
+func TestUDP_findnodeTimeout(t *testing.T) {
+ t.Parallel()
+ test := newUDPTest(t)
+ defer test.table.Close()
+
+ toaddr := &net.UDPAddr{IP: net.ParseIP("1.2.3.4"), Port: 2222}
+ toid := NodeID{1, 2, 3, 4}
+ target := NodeID{4, 5, 6, 7}
+ result, err := test.udp.findnode(toid, toaddr, target)
+ if err != errTimeout {
+ t.Error("expected timeout error, got", err)
+ }
+ if len(result) > 0 {
+ t.Error("expected empty result, got", result)
+ }
+}
+
+func TestUDP_findnode(t *testing.T) {
+ test := newUDPTest(t)
+ defer test.table.Close()
+
+ // put a few nodes into the table. their exact
+ // distribution shouldn't matter much, altough we need to
+ // take care not to overflow any bucket.
+ target := testTarget
+ nodes := &nodesByDistance{target: target}
+ for i := 0; i < bucketSize; i++ {
+ nodes.push(&Node{
+ IP: net.IP{1, 2, 3, byte(i)},
+ DiscPort: i + 2,
+ TCPPort: i + 2,
+ ID: randomID(test.table.self.ID, i+2),
+ }, bucketSize)
+ }
+ test.table.add(nodes.entries)
+
+ // ensure there's a bond with the test node,
+ // findnode won't be accepted otherwise.
+ test.table.db.add(PubkeyID(&test.remotekey.PublicKey), test.remoteaddr, 99)
+
+ // check that closest neighbors are returned.
+ test.packetIn(nil, findnodePacket, &findnode{Target: testTarget, Expiration: futureExp})
+ test.waitPacketOut(func(p *neighbors) {
+ expected := test.table.closest(testTarget, bucketSize)
+ if len(p.Nodes) != bucketSize {
+ t.Errorf("wrong number of results: got %d, want %d", len(p.Nodes), bucketSize)
+ }
+ for i := range p.Nodes {
+ if p.Nodes[i].ID != expected.entries[i].ID {
+ t.Errorf("result mismatch at %d:\n got: %v\n want: %v", i, p.Nodes[i], expected.entries[i])
+ }
+ }
+ })
+}
+
+func TestUDP_findnodeMultiReply(t *testing.T) {
+ test := newUDPTest(t)
+ defer test.table.Close()
+
+ // queue a pending findnode request
+ resultc, errc := make(chan []*Node), make(chan error)
+ go func() {
+ rid := PubkeyID(&test.remotekey.PublicKey)
+ ns, err := test.udp.findnode(rid, test.remoteaddr, testTarget)
+ if err != nil && len(ns) == 0 {
+ errc <- err
+ } else {
+ resultc <- ns
+ }
+ }()
+
+ // wait for the findnode to be sent.
+ // after it is sent, the transport is waiting for a reply
+ test.waitPacketOut(func(p *findnode) {
+ if p.Target != testTarget {
+ t.Errorf("wrong target: got %v, want %v", p.Target, testTarget)
+ }
+ })
+
+ // send the reply as two packets.
+ list := []*Node{
+ MustParseNode("enode://ba85011c70bcc5c04d8607d3a0ed29aa6179c092cbdda10d5d32684fb33ed01bd94f588ca8f91ac48318087dcb02eaf36773a7a453f0eedd6742af668097b29c@10.0.1.16:30303"),
+ MustParseNode("enode://81fa361d25f157cd421c60dcc28d8dac5ef6a89476633339c5df30287474520caca09627da18543d9079b5b288698b542d56167aa5c09111e55acdbbdf2ef799@10.0.1.16:30303"),
+ MustParseNode("enode://9bffefd833d53fac8e652415f4973bee289e8b1a5c6c4cbe70abf817ce8a64cee11b823b66a987f51aaa9fba0d6a91b3e6bf0d5a5d1042de8e9eeea057b217f8@10.0.1.36:30301"),
+ MustParseNode("enode://1b5b4aa662d7cb44a7221bfba67302590b643028197a7d5214790f3bac7aaa4a3241be9e83c09cf1f6c69d007c634faae3dc1b1221793e8446c0b3a09de65960@10.0.1.16:30303"),
+ }
+ test.packetIn(nil, neighborsPacket, &neighbors{Expiration: futureExp, Nodes: list[:2]})
+ test.packetIn(nil, neighborsPacket, &neighbors{Expiration: futureExp, Nodes: list[2:]})
+
+ // check that the sent neighbors are all returned by findnode
+ select {
+ case result := <-resultc:
+ if !reflect.DeepEqual(result, list) {
+ t.Errorf("neighbors mismatch:\n got: %v\n want: %v", result, list)
+ }
+ case err := <-errc:
+ t.Errorf("findnode error: %v", err)
+ case <-time.After(5 * time.Second):
+ t.Error("findnode did not return within 5 seconds")
+ }
+}
+
+func TestUDP_successfulPing(t *testing.T) {
+ test := newUDPTest(t)
+ defer test.table.Close()
+
+ done := make(chan struct{})
+ go func() {
+ test.packetIn(nil, pingPacket, &ping{IP: "foo", Port: 99, Version: Version, Expiration: futureExp})
+ close(done)
+ }()
+
+ // the ping is replied to.
+ test.waitPacketOut(func(p *pong) {
+ pinghash := test.sent[0][:macSize]
+ if !bytes.Equal(p.ReplyTok, pinghash) {
+ t.Errorf("got ReplyTok %x, want %x", p.ReplyTok, pinghash)
+ }
+ })
+
+ // remote is unknown, the table pings back.
+ test.waitPacketOut(func(p *ping) error { return nil })
+ test.packetIn(nil, pongPacket, &pong{Expiration: futureExp})
+
+ // ping should return shortly after getting the pong packet.
+ <-done
+
+ // check that the node was added.
+ rid := PubkeyID(&test.remotekey.PublicKey)
+ rnode := find(test.table, rid)
+ if rnode == nil {
+ t.Fatalf("node %v not found in table", rid)
+ }
+ if !bytes.Equal(rnode.IP, test.remoteaddr.IP) {
+ t.Errorf("node has wrong IP: got %v, want: %v", rnode.IP, test.remoteaddr.IP)
+ }
+ if rnode.DiscPort != test.remoteaddr.Port {
+ t.Errorf("node has wrong Port: got %v, want: %v", rnode.DiscPort, test.remoteaddr.Port)
+ }
+ if rnode.TCPPort != 99 {
+ t.Errorf("node has wrong Port: got %v, want: %v", rnode.TCPPort, 99)
+ }
+}
+
+func find(tab *Table, id NodeID) *Node {
+ for _, b := range tab.buckets {
+ for _, e := range b.entries {
+ if e.ID == id {
+ return e
+ }
+ }
+ }
+ return nil
+}
+
+// dgramPipe is a fake UDP socket. It queues all sent datagrams.
+type dgramPipe struct {
+ mu *sync.Mutex
+ cond *sync.Cond
+ closing chan struct{}
+ closed bool
+ queue [][]byte
+}
+
+func newpipe() *dgramPipe {
+ mu := new(sync.Mutex)
+ return &dgramPipe{
+ closing: make(chan struct{}),
+ cond: &sync.Cond{L: mu},
+ mu: mu,
+ }
+}
+
+// WriteToUDP queues a datagram.
+func (c *dgramPipe) WriteToUDP(b []byte, to *net.UDPAddr) (n int, err error) {
+ msg := make([]byte, len(b))
+ copy(msg, b)
+ c.mu.Lock()
+ defer c.mu.Unlock()
+ if c.closed {
+ return 0, errors.New("closed")
+ }
+ c.queue = append(c.queue, msg)
+ c.cond.Signal()
+ return len(b), nil
+}
+
+// ReadFromUDP just hangs until the pipe is closed.
+func (c *dgramPipe) ReadFromUDP(b []byte) (n int, addr *net.UDPAddr, err error) {
+ <-c.closing
+ return 0, nil, io.EOF
+}
+
+func (c *dgramPipe) Close() error {
+ c.mu.Lock()
+ defer c.mu.Unlock()
+ if !c.closed {
+ close(c.closing)
+ c.closed = true
+ }
+ return nil
+}
+
+func (c *dgramPipe) LocalAddr() net.Addr {
+ return &net.UDPAddr{}
+}
+
+func (c *dgramPipe) waitPacketOut() []byte {
+ c.mu.Lock()
+ defer c.mu.Unlock()
+ for len(c.queue) == 0 {
+ c.cond.Wait()
+ }
+ p := c.queue[0]
+ copy(c.queue, c.queue[1:])
+ c.queue = c.queue[:len(c.queue)-1]
+ return p
+}
diff --git a/p2p/handshake.go b/p2p/handshake.go
new file mode 100644
index 000000000..031064407
--- /dev/null
+++ b/p2p/handshake.go
@@ -0,0 +1,432 @@
+package p2p
+
+import (
+ "crypto/ecdsa"
+ "crypto/elliptic"
+ "crypto/rand"
+ "errors"
+ "fmt"
+ "hash"
+ "io"
+ "net"
+
+ "github.com/ethereum/go-ethereum/crypto"
+ "github.com/ethereum/go-ethereum/crypto/ecies"
+ "github.com/ethereum/go-ethereum/crypto/secp256k1"
+ "github.com/ethereum/go-ethereum/crypto/sha3"
+ "github.com/ethereum/go-ethereum/p2p/discover"
+ "github.com/ethereum/go-ethereum/rlp"
+)
+
+const (
+ sskLen = 16 // ecies.MaxSharedKeyLength(pubKey) / 2
+ sigLen = 65 // elliptic S256
+ pubLen = 64 // 512 bit pubkey in uncompressed representation without format byte
+ shaLen = 32 // hash length (for nonce etc)
+
+ authMsgLen = sigLen + shaLen + pubLen + shaLen + 1
+ authRespLen = pubLen + shaLen + 1
+
+ eciesBytes = 65 + 16 + 32
+ encAuthMsgLen = authMsgLen + eciesBytes // size of the final ECIES payload sent as initiator's handshake
+ encAuthRespLen = authRespLen + eciesBytes // size of the final ECIES payload sent as receiver's handshake
+)
+
+// conn represents a remote connection after encryption handshake
+// and protocol handshake have completed.
+//
+// The MsgReadWriter is usually layered as follows:
+//
+// netWrapper (I/O timeouts, thread-safe ReadMsg, WriteMsg)
+// rlpxFrameRW (message encoding, encryption, authentication)
+// bufio.ReadWriter (buffering)
+// net.Conn (network I/O)
+//
+type conn struct {
+ MsgReadWriter
+ *protoHandshake
+}
+
+// secrets represents the connection secrets
+// which are negotiated during the encryption handshake.
+type secrets struct {
+ RemoteID discover.NodeID
+ AES, MAC []byte
+ EgressMAC, IngressMAC hash.Hash
+ Token []byte
+}
+
+// protoHandshake is the RLP structure of the protocol handshake.
+type protoHandshake struct {
+ Version uint64
+ Name string
+ Caps []Cap
+ ListenPort uint64
+ ID discover.NodeID
+}
+
+// setupConn starts a protocol session on the given connection.
+// It runs the encryption handshake and the protocol handshake.
+// If dial is non-nil, the connection the local node is the initiator.
+func setupConn(fd net.Conn, prv *ecdsa.PrivateKey, our *protoHandshake, dial *discover.Node) (*conn, error) {
+ if dial == nil {
+ return setupInboundConn(fd, prv, our)
+ } else {
+ return setupOutboundConn(fd, prv, our, dial)
+ }
+}
+
+func setupInboundConn(fd net.Conn, prv *ecdsa.PrivateKey, our *protoHandshake) (*conn, error) {
+ secrets, err := receiverEncHandshake(fd, prv, nil)
+ if err != nil {
+ return nil, fmt.Errorf("encryption handshake failed: %v", err)
+ }
+
+ // Run the protocol handshake using authenticated messages.
+ rw := newRlpxFrameRW(fd, secrets)
+ rhs, err := readProtocolHandshake(rw, our)
+ if err != nil {
+ return nil, err
+ }
+ if rhs.ID != secrets.RemoteID {
+ return nil, errors.New("node ID in protocol handshake does not match encryption handshake")
+ }
+ // TODO: validate that handshake node ID matches
+ if err := Send(rw, handshakeMsg, our); err != nil {
+ return nil, fmt.Errorf("protocol write error: %v", err)
+ }
+ return &conn{rw, rhs}, nil
+}
+
+func setupOutboundConn(fd net.Conn, prv *ecdsa.PrivateKey, our *protoHandshake, dial *discover.Node) (*conn, error) {
+ secrets, err := initiatorEncHandshake(fd, prv, dial.ID, nil)
+ if err != nil {
+ return nil, fmt.Errorf("encryption handshake failed: %v", err)
+ }
+
+ // Run the protocol handshake using authenticated messages.
+ rw := newRlpxFrameRW(fd, secrets)
+ if err := Send(rw, handshakeMsg, our); err != nil {
+ return nil, fmt.Errorf("protocol write error: %v", err)
+ }
+ rhs, err := readProtocolHandshake(rw, our)
+ if err != nil {
+ return nil, fmt.Errorf("protocol handshake read error: %v", err)
+ }
+ if rhs.ID != dial.ID {
+ return nil, errors.New("dialed node id mismatch")
+ }
+ return &conn{rw, rhs}, nil
+}
+
+// encHandshake contains the state of the encryption handshake.
+type encHandshake struct {
+ initiator bool
+ remoteID discover.NodeID
+
+ remotePub *ecies.PublicKey // remote-pubk
+ initNonce, respNonce []byte // nonce
+ randomPrivKey *ecies.PrivateKey // ecdhe-random
+ remoteRandomPub *ecies.PublicKey // ecdhe-random-pubk
+}
+
+// secrets is called after the handshake is completed.
+// It extracts the connection secrets from the handshake values.
+func (h *encHandshake) secrets(auth, authResp []byte) (secrets, error) {
+ ecdheSecret, err := h.randomPrivKey.GenerateShared(h.remoteRandomPub, sskLen, sskLen)
+ if err != nil {
+ return secrets{}, err
+ }
+
+ // derive base secrets from ephemeral key agreement
+ sharedSecret := crypto.Sha3(ecdheSecret, crypto.Sha3(h.respNonce, h.initNonce))
+ aesSecret := crypto.Sha3(ecdheSecret, sharedSecret)
+ s := secrets{
+ RemoteID: h.remoteID,
+ AES: aesSecret,
+ MAC: crypto.Sha3(ecdheSecret, aesSecret),
+ Token: crypto.Sha3(sharedSecret),
+ }
+
+ // setup sha3 instances for the MACs
+ mac1 := sha3.NewKeccak256()
+ mac1.Write(xor(s.MAC, h.respNonce))
+ mac1.Write(auth)
+ mac2 := sha3.NewKeccak256()
+ mac2.Write(xor(s.MAC, h.initNonce))
+ mac2.Write(authResp)
+ if h.initiator {
+ s.EgressMAC, s.IngressMAC = mac1, mac2
+ } else {
+ s.EgressMAC, s.IngressMAC = mac2, mac1
+ }
+
+ return s, nil
+}
+
+func (h *encHandshake) ecdhShared(prv *ecdsa.PrivateKey) ([]byte, error) {
+ return ecies.ImportECDSA(prv).GenerateShared(h.remotePub, sskLen, sskLen)
+}
+
+// initiatorEncHandshake negotiates a session token on conn.
+// it should be called on the dialing side of the connection.
+//
+// prv is the local client's private key.
+// token is the token from a previous session with this node.
+func initiatorEncHandshake(conn io.ReadWriter, prv *ecdsa.PrivateKey, remoteID discover.NodeID, token []byte) (s secrets, err error) {
+ h, err := newInitiatorHandshake(remoteID)
+ if err != nil {
+ return s, err
+ }
+ auth, err := h.authMsg(prv, token)
+ if err != nil {
+ return s, err
+ }
+ if _, err = conn.Write(auth); err != nil {
+ return s, err
+ }
+
+ response := make([]byte, encAuthRespLen)
+ if _, err = io.ReadFull(conn, response); err != nil {
+ return s, err
+ }
+ if err := h.decodeAuthResp(response, prv); err != nil {
+ return s, err
+ }
+ return h.secrets(auth, response)
+}
+
+func newInitiatorHandshake(remoteID discover.NodeID) (*encHandshake, error) {
+ // generate random initiator nonce
+ n := make([]byte, shaLen)
+ if _, err := rand.Read(n); err != nil {
+ return nil, err
+ }
+ // generate random keypair to use for signing
+ randpriv, err := ecies.GenerateKey(rand.Reader, crypto.S256(), nil)
+ if err != nil {
+ return nil, err
+ }
+ rpub, err := remoteID.Pubkey()
+ if err != nil {
+ return nil, fmt.Errorf("bad remoteID: %v", err)
+ }
+ h := &encHandshake{
+ initiator: true,
+ remoteID: remoteID,
+ remotePub: ecies.ImportECDSAPublic(rpub),
+ initNonce: n,
+ randomPrivKey: randpriv,
+ }
+ return h, nil
+}
+
+// authMsg creates an encrypted initiator handshake message.
+func (h *encHandshake) authMsg(prv *ecdsa.PrivateKey, token []byte) ([]byte, error) {
+ var tokenFlag byte
+ if token == nil {
+ // no session token found means we need to generate shared secret.
+ // ecies shared secret is used as initial session token for new peers
+ // generate shared key from prv and remote pubkey
+ var err error
+ if token, err = h.ecdhShared(prv); err != nil {
+ return nil, err
+ }
+ } else {
+ // for known peers, we use stored token from the previous session
+ tokenFlag = 0x01
+ }
+
+ // sign known message:
+ // ecdh-shared-secret^nonce for new peers
+ // token^nonce for old peers
+ signed := xor(token, h.initNonce)
+ signature, err := crypto.Sign(signed, h.randomPrivKey.ExportECDSA())
+ if err != nil {
+ return nil, err
+ }
+
+ // encode auth message
+ // signature || sha3(ecdhe-random-pubk) || pubk || nonce || token-flag
+ msg := make([]byte, authMsgLen)
+ n := copy(msg, signature)
+ n += copy(msg[n:], crypto.Sha3(exportPubkey(&h.randomPrivKey.PublicKey)))
+ n += copy(msg[n:], crypto.FromECDSAPub(&prv.PublicKey)[1:])
+ n += copy(msg[n:], h.initNonce)
+ msg[n] = tokenFlag
+
+ // encrypt auth message using remote-pubk
+ return ecies.Encrypt(rand.Reader, h.remotePub, msg, nil, nil)
+}
+
+// decodeAuthResp decode an encrypted authentication response message.
+func (h *encHandshake) decodeAuthResp(auth []byte, prv *ecdsa.PrivateKey) error {
+ msg, err := crypto.Decrypt(prv, auth)
+ if err != nil {
+ return fmt.Errorf("could not decrypt auth response (%v)", err)
+ }
+ h.respNonce = msg[pubLen : pubLen+shaLen]
+ h.remoteRandomPub, err = importPublicKey(msg[:pubLen])
+ if err != nil {
+ return err
+ }
+ // ignore token flag for now
+ return nil
+}
+
+// receiverEncHandshake negotiates a session token on conn.
+// it should be called on the listening side of the connection.
+//
+// prv is the local client's private key.
+// token is the token from a previous session with this node.
+func receiverEncHandshake(conn io.ReadWriter, prv *ecdsa.PrivateKey, token []byte) (s secrets, err error) {
+ // read remote auth sent by initiator.
+ auth := make([]byte, encAuthMsgLen)
+ if _, err := io.ReadFull(conn, auth); err != nil {
+ return s, err
+ }
+ h, err := decodeAuthMsg(prv, token, auth)
+ if err != nil {
+ return s, err
+ }
+
+ // send auth response
+ resp, err := h.authResp(prv, token)
+ if err != nil {
+ return s, err
+ }
+ if _, err = conn.Write(resp); err != nil {
+ return s, err
+ }
+
+ return h.secrets(auth, resp)
+}
+
+func decodeAuthMsg(prv *ecdsa.PrivateKey, token []byte, auth []byte) (*encHandshake, error) {
+ var err error
+ h := new(encHandshake)
+ // generate random keypair for session
+ h.randomPrivKey, err = ecies.GenerateKey(rand.Reader, crypto.S256(), nil)
+ if err != nil {
+ return nil, err
+ }
+ // generate random nonce
+ h.respNonce = make([]byte, shaLen)
+ if _, err = rand.Read(h.respNonce); err != nil {
+ return nil, err
+ }
+
+ msg, err := crypto.Decrypt(prv, auth)
+ if err != nil {
+ return nil, fmt.Errorf("could not decrypt auth message (%v)", err)
+ }
+
+ // decode message parameters
+ // signature || sha3(ecdhe-random-pubk) || pubk || nonce || token-flag
+ h.initNonce = msg[authMsgLen-shaLen-1 : authMsgLen-1]
+ copy(h.remoteID[:], msg[sigLen+shaLen:sigLen+shaLen+pubLen])
+ rpub, err := h.remoteID.Pubkey()
+ if err != nil {
+ return nil, fmt.Errorf("bad remoteID: %#v", err)
+ }
+ h.remotePub = ecies.ImportECDSAPublic(rpub)
+
+ // recover remote random pubkey from signed message.
+ if token == nil {
+ // TODO: it is an error if the initiator has a token and we don't. check that.
+
+ // no session token means we need to generate shared secret.
+ // ecies shared secret is used as initial session token for new peers.
+ // generate shared key from prv and remote pubkey.
+ if token, err = h.ecdhShared(prv); err != nil {
+ return nil, err
+ }
+ }
+ signedMsg := xor(token, h.initNonce)
+ remoteRandomPub, err := secp256k1.RecoverPubkey(signedMsg, msg[:sigLen])
+ if err != nil {
+ return nil, err
+ }
+ h.remoteRandomPub, _ = importPublicKey(remoteRandomPub)
+ return h, nil
+}
+
+// authResp generates the encrypted authentication response message.
+func (h *encHandshake) authResp(prv *ecdsa.PrivateKey, token []byte) ([]byte, error) {
+ // responder auth message
+ // E(remote-pubk, ecdhe-random-pubk || nonce || 0x0)
+ resp := make([]byte, authRespLen)
+ n := copy(resp, exportPubkey(&h.randomPrivKey.PublicKey))
+ n += copy(resp[n:], h.respNonce)
+ if token == nil {
+ resp[n] = 0
+ } else {
+ resp[n] = 1
+ }
+ // encrypt using remote-pubk
+ return ecies.Encrypt(rand.Reader, h.remotePub, resp, nil, nil)
+}
+
+// importPublicKey unmarshals 512 bit public keys.
+func importPublicKey(pubKey []byte) (*ecies.PublicKey, error) {
+ var pubKey65 []byte
+ switch len(pubKey) {
+ case 64:
+ // add 'uncompressed key' flag
+ pubKey65 = append([]byte{0x04}, pubKey...)
+ case 65:
+ pubKey65 = pubKey
+ default:
+ return nil, fmt.Errorf("invalid public key length %v (expect 64/65)", len(pubKey))
+ }
+ // TODO: fewer pointless conversions
+ return ecies.ImportECDSAPublic(crypto.ToECDSAPub(pubKey65)), nil
+}
+
+func exportPubkey(pub *ecies.PublicKey) []byte {
+ if pub == nil {
+ panic("nil pubkey")
+ }
+ return elliptic.Marshal(pub.Curve, pub.X, pub.Y)[1:]
+}
+
+func xor(one, other []byte) (xor []byte) {
+ xor = make([]byte, len(one))
+ for i := 0; i < len(one); i++ {
+ xor[i] = one[i] ^ other[i]
+ }
+ return xor
+}
+
+func readProtocolHandshake(r MsgReader, our *protoHandshake) (*protoHandshake, error) {
+ // read and handle remote handshake
+ msg, err := r.ReadMsg()
+ if err != nil {
+ return nil, err
+ }
+ if msg.Code == discMsg {
+ // disconnect before protocol handshake is valid according to the
+ // spec and we send it ourself if Server.addPeer fails.
+ var reason DiscReason
+ rlp.Decode(msg.Payload, &reason)
+ return nil, discRequestedError(reason)
+ }
+ if msg.Code != handshakeMsg {
+ return nil, fmt.Errorf("expected handshake, got %x", msg.Code)
+ }
+ if msg.Size > baseProtocolMaxMsgSize {
+ return nil, fmt.Errorf("message too big (%d > %d)", msg.Size, baseProtocolMaxMsgSize)
+ }
+ var hs protoHandshake
+ if err := msg.Decode(&hs); err != nil {
+ return nil, err
+ }
+ // validate handshake info
+ if hs.Version != our.Version {
+ return nil, newPeerError(errP2PVersionMismatch, "required version %d, received %d\n", baseProtocolVersion, hs.Version)
+ }
+ if (hs.ID == discover.NodeID{}) {
+ return nil, newPeerError(errPubkeyInvalid, "missing")
+ }
+ return &hs, nil
+}
diff --git a/p2p/handshake_test.go b/p2p/handshake_test.go
new file mode 100644
index 000000000..19423bb82
--- /dev/null
+++ b/p2p/handshake_test.go
@@ -0,0 +1,171 @@
+package p2p
+
+import (
+ "bytes"
+ "crypto/rand"
+ "fmt"
+ "net"
+ "reflect"
+ "testing"
+ "time"
+
+ "github.com/ethereum/go-ethereum/crypto"
+ "github.com/ethereum/go-ethereum/crypto/ecies"
+ "github.com/ethereum/go-ethereum/p2p/discover"
+)
+
+func TestSharedSecret(t *testing.T) {
+ prv0, _ := crypto.GenerateKey() // = ecdsa.GenerateKey(crypto.S256(), rand.Reader)
+ pub0 := &prv0.PublicKey
+ prv1, _ := crypto.GenerateKey()
+ pub1 := &prv1.PublicKey
+
+ ss0, err := ecies.ImportECDSA(prv0).GenerateShared(ecies.ImportECDSAPublic(pub1), sskLen, sskLen)
+ if err != nil {
+ return
+ }
+ ss1, err := ecies.ImportECDSA(prv1).GenerateShared(ecies.ImportECDSAPublic(pub0), sskLen, sskLen)
+ if err != nil {
+ return
+ }
+ t.Logf("Secret:\n%v %x\n%v %x", len(ss0), ss0, len(ss0), ss1)
+ if !bytes.Equal(ss0, ss1) {
+ t.Errorf("dont match :(")
+ }
+}
+
+func TestEncHandshake(t *testing.T) {
+ for i := 0; i < 20; i++ {
+ start := time.Now()
+ if err := testEncHandshake(nil); err != nil {
+ t.Fatalf("i=%d %v", i, err)
+ }
+ t.Logf("(without token) %d %v\n", i+1, time.Since(start))
+ }
+
+ for i := 0; i < 20; i++ {
+ tok := make([]byte, shaLen)
+ rand.Reader.Read(tok)
+ start := time.Now()
+ if err := testEncHandshake(tok); err != nil {
+ t.Fatalf("i=%d %v", i, err)
+ }
+ t.Logf("(with token) %d %v\n", i+1, time.Since(start))
+ }
+}
+
+func testEncHandshake(token []byte) error {
+ type result struct {
+ side string
+ s secrets
+ err error
+ }
+ var (
+ prv0, _ = crypto.GenerateKey()
+ prv1, _ = crypto.GenerateKey()
+ rw0, rw1 = net.Pipe()
+ output = make(chan result)
+ )
+
+ go func() {
+ r := result{side: "initiator"}
+ defer func() { output <- r }()
+
+ pub1s := discover.PubkeyID(&prv1.PublicKey)
+ r.s, r.err = initiatorEncHandshake(rw0, prv0, pub1s, token)
+ if r.err != nil {
+ return
+ }
+ id1 := discover.PubkeyID(&prv1.PublicKey)
+ if r.s.RemoteID != id1 {
+ r.err = fmt.Errorf("remote ID mismatch: got %v, want: %v", r.s.RemoteID, id1)
+ }
+ }()
+ go func() {
+ r := result{side: "receiver"}
+ defer func() { output <- r }()
+
+ r.s, r.err = receiverEncHandshake(rw1, prv1, token)
+ if r.err != nil {
+ return
+ }
+ id0 := discover.PubkeyID(&prv0.PublicKey)
+ if r.s.RemoteID != id0 {
+ r.err = fmt.Errorf("remote ID mismatch: got %v, want: %v", r.s.RemoteID, id0)
+ }
+ }()
+
+ // wait for results from both sides
+ r1, r2 := <-output, <-output
+
+ if r1.err != nil {
+ return fmt.Errorf("%s side error: %v", r1.side, r1.err)
+ }
+ if r2.err != nil {
+ return fmt.Errorf("%s side error: %v", r2.side, r2.err)
+ }
+
+ // don't compare remote node IDs
+ r1.s.RemoteID, r2.s.RemoteID = discover.NodeID{}, discover.NodeID{}
+ // flip MACs on one of them so they compare equal
+ r1.s.EgressMAC, r1.s.IngressMAC = r1.s.IngressMAC, r1.s.EgressMAC
+ if !reflect.DeepEqual(r1.s, r2.s) {
+ return fmt.Errorf("secrets mismatch:\n t1: %#v\n t2: %#v", r1.s, r2.s)
+ }
+ return nil
+}
+
+func TestSetupConn(t *testing.T) {
+ prv0, _ := crypto.GenerateKey()
+ prv1, _ := crypto.GenerateKey()
+ node0 := &discover.Node{
+ ID: discover.PubkeyID(&prv0.PublicKey),
+ IP: net.IP{1, 2, 3, 4},
+ TCPPort: 33,
+ }
+ node1 := &discover.Node{
+ ID: discover.PubkeyID(&prv1.PublicKey),
+ IP: net.IP{5, 6, 7, 8},
+ TCPPort: 44,
+ }
+ hs0 := &protoHandshake{
+ Version: baseProtocolVersion,
+ ID: node0.ID,
+ Caps: []Cap{{"a", 0}, {"b", 2}},
+ }
+ hs1 := &protoHandshake{
+ Version: baseProtocolVersion,
+ ID: node1.ID,
+ Caps: []Cap{{"c", 1}, {"d", 3}},
+ }
+ fd0, fd1 := net.Pipe()
+
+ done := make(chan struct{})
+ go func() {
+ defer close(done)
+ conn0, err := setupConn(fd0, prv0, hs0, node1)
+ if err != nil {
+ t.Errorf("outbound side error: %v", err)
+ return
+ }
+ if conn0.ID != node1.ID {
+ t.Errorf("outbound conn id mismatch: got %v, want %v", conn0.ID, node1.ID)
+ }
+ if !reflect.DeepEqual(conn0.Caps, hs1.Caps) {
+ t.Errorf("outbound caps mismatch: got %v, want %v", conn0.Caps, hs1.Caps)
+ }
+ }()
+
+ conn1, err := setupConn(fd1, prv1, hs1, nil)
+ if err != nil {
+ t.Fatalf("inbound side error: %v", err)
+ }
+ if conn1.ID != node0.ID {
+ t.Errorf("inbound conn id mismatch: got %v, want %v", conn1.ID, node0.ID)
+ }
+ if !reflect.DeepEqual(conn1.Caps, hs0.Caps) {
+ t.Errorf("inbound caps mismatch: got %v, want %v", conn1.Caps, hs0.Caps)
+ }
+
+ <-done
+}
diff --git a/p2p/message.go b/p2p/message.go
new file mode 100644
index 000000000..b42acbe3c
--- /dev/null
+++ b/p2p/message.go
@@ -0,0 +1,255 @@
+package p2p
+
+import (
+ "bytes"
+ "errors"
+ "fmt"
+ "io"
+ "io/ioutil"
+ "net"
+ "sync"
+ "sync/atomic"
+ "time"
+
+ "github.com/ethereum/go-ethereum/rlp"
+)
+
+// Msg defines the structure of a p2p message.
+//
+// Note that a Msg can only be sent once since the Payload reader is
+// consumed during sending. It is not possible to create a Msg and
+// send it any number of times. If you want to reuse an encoded
+// structure, encode the payload into a byte array and create a
+// separate Msg with a bytes.Reader as Payload for each send.
+type Msg struct {
+ Code uint64
+ Size uint32 // size of the paylod
+ Payload io.Reader
+}
+
+// Decode parses the RLP content of a message into
+// the given value, which must be a pointer.
+//
+// For the decoding rules, please see package rlp.
+func (msg Msg) Decode(val interface{}) error {
+ if err := rlp.Decode(msg.Payload, val); err != nil {
+ return newPeerError(errInvalidMsg, "(code %x) (size %d) %v", msg.Code, msg.Size, err)
+ }
+ return nil
+}
+
+func (msg Msg) String() string {
+ return fmt.Sprintf("msg #%v (%v bytes)", msg.Code, msg.Size)
+}
+
+// Discard reads any remaining payload data into a black hole.
+func (msg Msg) Discard() error {
+ _, err := io.Copy(ioutil.Discard, msg.Payload)
+ return err
+}
+
+type MsgReader interface {
+ ReadMsg() (Msg, error)
+}
+
+type MsgWriter interface {
+ // WriteMsg sends a message. It will block until the message's
+ // Payload has been consumed by the other end.
+ //
+ // Note that messages can be sent only once because their
+ // payload reader is drained.
+ WriteMsg(Msg) error
+}
+
+// MsgReadWriter provides reading and writing of encoded messages.
+// Implementations should ensure that ReadMsg and WriteMsg can be
+// called simultaneously from multiple goroutines.
+type MsgReadWriter interface {
+ MsgReader
+ MsgWriter
+}
+
+// Send writes an RLP-encoded message with the given code.
+// data should encode as an RLP list.
+func Send(w MsgWriter, msgcode uint64, data interface{}) error {
+ size, r, err := rlp.EncodeToReader(data)
+ if err != nil {
+ return err
+ }
+ return w.WriteMsg(Msg{Code: msgcode, Size: uint32(size), Payload: r})
+}
+
+// SendItems writes an RLP with the given code and data elements.
+// For a call such as:
+//
+// SendItems(w, code, e1, e2, e3)
+//
+// the message payload will be an RLP list containing the items:
+//
+// [e1, e2, e3]
+//
+func SendItems(w MsgWriter, msgcode uint64, elems ...interface{}) error {
+ return Send(w, msgcode, elems)
+}
+
+// netWrapper wraps a MsgReadWriter with locks around
+// ReadMsg/WriteMsg and applies read/write deadlines.
+type netWrapper struct {
+ rmu, wmu sync.Mutex
+
+ rtimeout, wtimeout time.Duration
+ conn net.Conn
+ wrapped MsgReadWriter
+}
+
+func (rw *netWrapper) ReadMsg() (Msg, error) {
+ rw.rmu.Lock()
+ defer rw.rmu.Unlock()
+ rw.conn.SetReadDeadline(time.Now().Add(rw.rtimeout))
+ return rw.wrapped.ReadMsg()
+}
+
+func (rw *netWrapper) WriteMsg(msg Msg) error {
+ rw.wmu.Lock()
+ defer rw.wmu.Unlock()
+ rw.conn.SetWriteDeadline(time.Now().Add(rw.wtimeout))
+ return rw.wrapped.WriteMsg(msg)
+}
+
+// eofSignal wraps a reader with eof signaling. the eof channel is
+// closed when the wrapped reader returns an error or when count bytes
+// have been read.
+type eofSignal struct {
+ wrapped io.Reader
+ count uint32 // number of bytes left
+ eof chan<- struct{}
+}
+
+// note: when using eofSignal to detect whether a message payload
+// has been read, Read might not be called for zero sized messages.
+func (r *eofSignal) Read(buf []byte) (int, error) {
+ if r.count == 0 {
+ if r.eof != nil {
+ r.eof <- struct{}{}
+ r.eof = nil
+ }
+ return 0, io.EOF
+ }
+
+ max := len(buf)
+ if int(r.count) < len(buf) {
+ max = int(r.count)
+ }
+ n, err := r.wrapped.Read(buf[:max])
+ r.count -= uint32(n)
+ if (err != nil || r.count == 0) && r.eof != nil {
+ r.eof <- struct{}{} // tell Peer that msg has been consumed
+ r.eof = nil
+ }
+ return n, err
+}
+
+// MsgPipe creates a message pipe. Reads on one end are matched
+// with writes on the other. The pipe is full-duplex, both ends
+// implement MsgReadWriter.
+func MsgPipe() (*MsgPipeRW, *MsgPipeRW) {
+ var (
+ c1, c2 = make(chan Msg), make(chan Msg)
+ closing = make(chan struct{})
+ closed = new(int32)
+ rw1 = &MsgPipeRW{c1, c2, closing, closed}
+ rw2 = &MsgPipeRW{c2, c1, closing, closed}
+ )
+ return rw1, rw2
+}
+
+// ErrPipeClosed is returned from pipe operations after the
+// pipe has been closed.
+var ErrPipeClosed = errors.New("p2p: read or write on closed message pipe")
+
+// MsgPipeRW is an endpoint of a MsgReadWriter pipe.
+type MsgPipeRW struct {
+ w chan<- Msg
+ r <-chan Msg
+ closing chan struct{}
+ closed *int32
+}
+
+// WriteMsg sends a messsage on the pipe.
+// It blocks until the receiver has consumed the message payload.
+func (p *MsgPipeRW) WriteMsg(msg Msg) error {
+ if atomic.LoadInt32(p.closed) == 0 {
+ consumed := make(chan struct{}, 1)
+ msg.Payload = &eofSignal{msg.Payload, msg.Size, consumed}
+ select {
+ case p.w <- msg:
+ if msg.Size > 0 {
+ // wait for payload read or discard
+ select {
+ case <-consumed:
+ case <-p.closing:
+ }
+ }
+ return nil
+ case <-p.closing:
+ }
+ }
+ return ErrPipeClosed
+}
+
+// ReadMsg returns a message sent on the other end of the pipe.
+func (p *MsgPipeRW) ReadMsg() (Msg, error) {
+ if atomic.LoadInt32(p.closed) == 0 {
+ select {
+ case msg := <-p.r:
+ return msg, nil
+ case <-p.closing:
+ }
+ }
+ return Msg{}, ErrPipeClosed
+}
+
+// Close unblocks any pending ReadMsg and WriteMsg calls on both ends
+// of the pipe. They will return ErrPipeClosed. Close also
+// interrupts any reads from a message payload.
+func (p *MsgPipeRW) Close() error {
+ if atomic.AddInt32(p.closed, 1) != 1 {
+ // someone else is already closing
+ atomic.StoreInt32(p.closed, 1) // avoid overflow
+ return nil
+ }
+ close(p.closing)
+ return nil
+}
+
+// ExpectMsg reads a message from r and verifies that its
+// code and encoded RLP content match the provided values.
+// If content is nil, the payload is discarded and not verified.
+func ExpectMsg(r MsgReader, code uint64, content interface{}) error {
+ msg, err := r.ReadMsg()
+ if err != nil {
+ return err
+ }
+ if msg.Code != code {
+ return fmt.Errorf("message code mismatch: got %d, expected %d", msg.Code, code)
+ }
+ if content == nil {
+ return msg.Discard()
+ } else {
+ contentEnc, err := rlp.EncodeToBytes(content)
+ if err != nil {
+ panic("content encode error: " + err.Error())
+ }
+ if int(msg.Size) != len(contentEnc) {
+ return fmt.Errorf("message size mismatch: got %d, want %d", msg.Size, len(contentEnc))
+ }
+ actualContent, err := ioutil.ReadAll(msg.Payload)
+ if err != nil {
+ return err
+ }
+ if !bytes.Equal(actualContent, contentEnc) {
+ return fmt.Errorf("message payload mismatch:\ngot: %x\nwant: %x", actualContent, contentEnc)
+ }
+ }
+ return nil
+}
diff --git a/p2p/message_test.go b/p2p/message_test.go
new file mode 100644
index 000000000..9a93dd347
--- /dev/null
+++ b/p2p/message_test.go
@@ -0,0 +1,135 @@
+package p2p
+
+import (
+ "bytes"
+ "encoding/hex"
+ "fmt"
+ "io"
+ "runtime"
+ "strings"
+ "testing"
+ "time"
+)
+
+func ExampleMsgPipe() {
+ rw1, rw2 := MsgPipe()
+ go func() {
+ Send(rw1, 8, [][]byte{{0, 0}})
+ Send(rw1, 5, [][]byte{{1, 1}})
+ rw1.Close()
+ }()
+
+ for {
+ msg, err := rw2.ReadMsg()
+ if err != nil {
+ break
+ }
+ var data [][]byte
+ msg.Decode(&data)
+ fmt.Printf("msg: %d, %x\n", msg.Code, data[0])
+ }
+ // Output:
+ // msg: 8, 0000
+ // msg: 5, 0101
+}
+
+func TestMsgPipeUnblockWrite(t *testing.T) {
+loop:
+ for i := 0; i < 100; i++ {
+ rw1, rw2 := MsgPipe()
+ done := make(chan struct{})
+ go func() {
+ if err := SendItems(rw1, 1); err == nil {
+ t.Error("EncodeMsg returned nil error")
+ } else if err != ErrPipeClosed {
+ t.Error("EncodeMsg returned wrong error: got %v, want %v", err, ErrPipeClosed)
+ }
+ close(done)
+ }()
+
+ // this call should ensure that EncodeMsg is waiting to
+ // deliver sometimes. if this isn't done, Close is likely to
+ // be executed before EncodeMsg starts and then we won't test
+ // all the cases.
+ runtime.Gosched()
+
+ rw2.Close()
+ select {
+ case <-done:
+ case <-time.After(200 * time.Millisecond):
+ t.Errorf("write didn't unblock")
+ break loop
+ }
+ }
+}
+
+// This test should panic if concurrent close isn't implemented correctly.
+func TestMsgPipeConcurrentClose(t *testing.T) {
+ rw1, _ := MsgPipe()
+ for i := 0; i < 10; i++ {
+ go rw1.Close()
+ }
+}
+
+func TestEOFSignal(t *testing.T) {
+ rb := make([]byte, 10)
+
+ // empty reader
+ eof := make(chan struct{}, 1)
+ sig := &eofSignal{new(bytes.Buffer), 0, eof}
+ if n, err := sig.Read(rb); n != 0 || err != io.EOF {
+ t.Errorf("Read returned unexpected values: (%v, %v)", n, err)
+ }
+ select {
+ case <-eof:
+ default:
+ t.Error("EOF chan not signaled")
+ }
+
+ // count before error
+ eof = make(chan struct{}, 1)
+ sig = &eofSignal{bytes.NewBufferString("aaaaaaaa"), 4, eof}
+ if n, err := sig.Read(rb); n != 4 || err != nil {
+ t.Errorf("Read returned unexpected values: (%v, %v)", n, err)
+ }
+ select {
+ case <-eof:
+ default:
+ t.Error("EOF chan not signaled")
+ }
+
+ // error before count
+ eof = make(chan struct{}, 1)
+ sig = &eofSignal{bytes.NewBufferString("aaaa"), 999, eof}
+ if n, err := sig.Read(rb); n != 4 || err != nil {
+ t.Errorf("Read returned unexpected values: (%v, %v)", n, err)
+ }
+ if n, err := sig.Read(rb); n != 0 || err != io.EOF {
+ t.Errorf("Read returned unexpected values: (%v, %v)", n, err)
+ }
+ select {
+ case <-eof:
+ default:
+ t.Error("EOF chan not signaled")
+ }
+
+ // no signal if neither occurs
+ eof = make(chan struct{}, 1)
+ sig = &eofSignal{bytes.NewBufferString("aaaaaaaaaaaaaaaaaaaaa"), 999, eof}
+ if n, err := sig.Read(rb); n != 10 || err != nil {
+ t.Errorf("Read returned unexpected values: (%v, %v)", n, err)
+ }
+ select {
+ case <-eof:
+ t.Error("unexpected EOF signal")
+ default:
+ }
+}
+
+func unhex(str string) []byte {
+ b, err := hex.DecodeString(strings.Replace(str, "\n", "", -1))
+ if err != nil {
+ panic(fmt.Sprintf("invalid hex string: %q", str))
+ }
+ return b
+}
diff --git a/p2p/nat/nat.go b/p2p/nat/nat.go
new file mode 100644
index 000000000..12d355ba1
--- /dev/null
+++ b/p2p/nat/nat.go
@@ -0,0 +1,235 @@
+// Package nat provides access to common port mapping protocols.
+package nat
+
+import (
+ "errors"
+ "fmt"
+ "net"
+ "strings"
+ "sync"
+ "time"
+
+ "github.com/ethereum/go-ethereum/logger"
+ "github.com/jackpal/go-nat-pmp"
+)
+
+var log = logger.NewLogger("P2P NAT")
+
+// An implementation of nat.Interface can map local ports to ports
+// accessible from the Internet.
+type Interface interface {
+ // These methods manage a mapping between a port on the local
+ // machine to a port that can be connected to from the internet.
+ //
+ // protocol is "UDP" or "TCP". Some implementations allow setting
+ // a display name for the mapping. The mapping may be removed by
+ // the gateway when its lifetime ends.
+ AddMapping(protocol string, extport, intport int, name string, lifetime time.Duration) error
+ DeleteMapping(protocol string, extport, intport int) error
+
+ // This method should return the external (Internet-facing)
+ // address of the gateway device.
+ ExternalIP() (net.IP, error)
+
+ // Should return name of the method. This is used for logging.
+ String() string
+}
+
+// Parse parses a NAT interface description.
+// The following formats are currently accepted.
+// Note that mechanism names are not case-sensitive.
+//
+// "" or "none" return nil
+// "extip:77.12.33.4" will assume the local machine is reachable on the given IP
+// "any" uses the first auto-detected mechanism
+// "upnp" uses the Universal Plug and Play protocol
+// "pmp" uses NAT-PMP with an auto-detected gateway address
+// "pmp:192.168.0.1" uses NAT-PMP with the given gateway address
+func Parse(spec string) (Interface, error) {
+ var (
+ parts = strings.SplitN(spec, ":", 2)
+ mech = strings.ToLower(parts[0])
+ ip net.IP
+ )
+ if len(parts) > 1 {
+ ip = net.ParseIP(parts[1])
+ if ip == nil {
+ return nil, errors.New("invalid IP address")
+ }
+ }
+ switch mech {
+ case "", "none", "off":
+ return nil, nil
+ case "any", "auto", "on":
+ return Any(), nil
+ case "extip", "ip":
+ if ip == nil {
+ return nil, errors.New("missing IP address")
+ }
+ return ExtIP(ip), nil
+ case "upnp":
+ return UPnP(), nil
+ case "pmp", "natpmp", "nat-pmp":
+ return PMP(ip), nil
+ default:
+ return nil, fmt.Errorf("unknown mechanism %q", parts[0])
+ }
+}
+
+const (
+ mapTimeout = 20 * time.Minute
+ mapUpdateInterval = 15 * time.Minute
+)
+
+// Map adds a port mapping on m and keeps it alive until c is closed.
+// This function is typically invoked in its own goroutine.
+func Map(m Interface, c chan struct{}, protocol string, extport, intport int, name string) {
+ refresh := time.NewTimer(mapUpdateInterval)
+ defer func() {
+ refresh.Stop()
+ log.Debugf("Deleting port mapping: %s %d -> %d (%s) using %s\n", protocol, extport, intport, name, m)
+ m.DeleteMapping(protocol, extport, intport)
+ }()
+ log.Debugf("add mapping: %s %d -> %d (%s) using %s\n", protocol, extport, intport, name, m)
+ if err := m.AddMapping(protocol, intport, extport, name, mapTimeout); err != nil {
+ log.Errorf("mapping error: %v\n", err)
+ }
+ for {
+ select {
+ case _, ok := <-c:
+ if !ok {
+ return
+ }
+ case <-refresh.C:
+ log.DebugDetailf("refresh mapping: %s %d -> %d (%s) using %s\n", protocol, extport, intport, name, m)
+ if err := m.AddMapping(protocol, intport, extport, name, mapTimeout); err != nil {
+ log.Errorf("mapping error: %v\n", err)
+ }
+ refresh.Reset(mapUpdateInterval)
+ }
+ }
+}
+
+// ExtIP assumes that the local machine is reachable on the given
+// external IP address, and that any required ports were mapped manually.
+// Mapping operations will not return an error but won't actually do anything.
+func ExtIP(ip net.IP) Interface {
+ if ip == nil {
+ panic("IP must not be nil")
+ }
+ return extIP(ip)
+}
+
+type extIP net.IP
+
+func (n extIP) ExternalIP() (net.IP, error) { return net.IP(n), nil }
+func (n extIP) String() string { return fmt.Sprintf("ExtIP(%v)", net.IP(n)) }
+
+// These do nothing.
+func (extIP) AddMapping(string, int, int, string, time.Duration) error { return nil }
+func (extIP) DeleteMapping(string, int, int) error { return nil }
+
+// Any returns a port mapper that tries to discover any supported
+// mechanism on the local network.
+func Any() Interface {
+ // TODO: attempt to discover whether the local machine has an
+ // Internet-class address. Return ExtIP in this case.
+ return startautodisc("UPnP or NAT-PMP", func() Interface {
+ found := make(chan Interface, 2)
+ go func() { found <- discoverUPnP() }()
+ go func() { found <- discoverPMP() }()
+ for i := 0; i < cap(found); i++ {
+ if c := <-found; c != nil {
+ return c
+ }
+ }
+ return nil
+ })
+}
+
+// UPnP returns a port mapper that uses UPnP. It will attempt to
+// discover the address of your router using UDP broadcasts.
+func UPnP() Interface {
+ return startautodisc("UPnP", discoverUPnP)
+}
+
+// PMP returns a port mapper that uses NAT-PMP. The provided gateway
+// address should be the IP of your router. If the given gateway
+// address is nil, PMP will attempt to auto-discover the router.
+func PMP(gateway net.IP) Interface {
+ if gateway != nil {
+ return &pmp{gw: gateway, c: natpmp.NewClient(gateway)}
+ }
+ return startautodisc("NAT-PMP", discoverPMP)
+}
+
+// autodisc represents a port mapping mechanism that is still being
+// auto-discovered. Calls to the Interface methods on this type will
+// wait until the discovery is done and then call the method on the
+// discovered mechanism.
+//
+// This type is useful because discovery can take a while but we
+// want return an Interface value from UPnP, PMP and Auto immediately.
+type autodisc struct {
+ what string
+ done <-chan Interface
+
+ mu sync.Mutex
+ found Interface
+}
+
+func startautodisc(what string, doit func() Interface) Interface {
+ // TODO: monitor network configuration and rerun doit when it changes.
+ done := make(chan Interface)
+ ad := &autodisc{what: what, done: done}
+ go func() { done <- doit(); close(done) }()
+ return ad
+}
+
+func (n *autodisc) AddMapping(protocol string, extport, intport int, name string, lifetime time.Duration) error {
+ if err := n.wait(); err != nil {
+ return err
+ }
+ return n.found.AddMapping(protocol, extport, intport, name, lifetime)
+}
+
+func (n *autodisc) DeleteMapping(protocol string, extport, intport int) error {
+ if err := n.wait(); err != nil {
+ return err
+ }
+ return n.found.DeleteMapping(protocol, extport, intport)
+}
+
+func (n *autodisc) ExternalIP() (net.IP, error) {
+ if err := n.wait(); err != nil {
+ return nil, err
+ }
+ return n.found.ExternalIP()
+}
+
+func (n *autodisc) String() string {
+ n.mu.Lock()
+ defer n.mu.Unlock()
+ if n.found == nil {
+ return n.what
+ } else {
+ return n.found.String()
+ }
+}
+
+func (n *autodisc) wait() error {
+ n.mu.Lock()
+ found := n.found
+ n.mu.Unlock()
+ if found != nil {
+ // already discovered
+ return nil
+ }
+ if found = <-n.done; found == nil {
+ return errors.New("no devices discovered")
+ }
+ n.mu.Lock()
+ n.found = found
+ n.mu.Unlock()
+ return nil
+}
diff --git a/p2p/nat/natpmp.go b/p2p/nat/natpmp.go
new file mode 100644
index 000000000..f249c6073
--- /dev/null
+++ b/p2p/nat/natpmp.go
@@ -0,0 +1,115 @@
+package nat
+
+import (
+ "fmt"
+ "net"
+ "strings"
+ "time"
+
+ "github.com/jackpal/go-nat-pmp"
+)
+
+// natPMPClient adapts the NAT-PMP protocol implementation so it conforms to
+// the common interface.
+type pmp struct {
+ gw net.IP
+ c *natpmp.Client
+}
+
+func (n *pmp) String() string {
+ return fmt.Sprintf("NAT-PMP(%v)", n.gw)
+}
+
+func (n *pmp) ExternalIP() (net.IP, error) {
+ response, err := n.c.GetExternalAddress()
+ if err != nil {
+ return nil, err
+ }
+ return response.ExternalIPAddress[:], nil
+}
+
+func (n *pmp) AddMapping(protocol string, extport, intport int, name string, lifetime time.Duration) error {
+ if lifetime <= 0 {
+ return fmt.Errorf("lifetime must not be <= 0")
+ }
+ // Note order of port arguments is switched between our
+ // AddMapping and the client's AddPortMapping.
+ _, err := n.c.AddPortMapping(strings.ToLower(protocol), intport, extport, int(lifetime/time.Second))
+ return err
+}
+
+func (n *pmp) DeleteMapping(protocol string, extport, intport int) (err error) {
+ // To destroy a mapping, send an add-port with an internalPort of
+ // the internal port to destroy, an external port of zero and a
+ // time of zero.
+ _, err = n.c.AddPortMapping(strings.ToLower(protocol), intport, 0, 0)
+ return err
+}
+
+func discoverPMP() Interface {
+ // run external address lookups on all potential gateways
+ gws := potentialGateways()
+ found := make(chan *pmp, len(gws))
+ for i := range gws {
+ gw := gws[i]
+ go func() {
+ c := natpmp.NewClient(gw)
+ if _, err := c.GetExternalAddress(); err != nil {
+ found <- nil
+ } else {
+ found <- &pmp{gw, c}
+ }
+ }()
+ }
+ // return the one that responds first.
+ // discovery needs to be quick, so we stop caring about
+ // any responses after a very short timeout.
+ timeout := time.NewTimer(1 * time.Second)
+ defer timeout.Stop()
+ for _ = range gws {
+ select {
+ case c := <-found:
+ if c != nil {
+ return c
+ }
+ case <-timeout.C:
+ return nil
+ }
+ }
+ return nil
+}
+
+var (
+ // LAN IP ranges
+ _, lan10, _ = net.ParseCIDR("10.0.0.0/8")
+ _, lan176, _ = net.ParseCIDR("172.16.0.0/12")
+ _, lan192, _ = net.ParseCIDR("192.168.0.0/16")
+)
+
+// TODO: improve this. We currently assume that (on most networks)
+// the router is X.X.X.1 in a local LAN range.
+func potentialGateways() (gws []net.IP) {
+ ifaces, err := net.Interfaces()
+ if err != nil {
+ return nil
+ }
+ for _, iface := range ifaces {
+ ifaddrs, err := iface.Addrs()
+ if err != nil {
+ return gws
+ }
+ for _, addr := range ifaddrs {
+ switch x := addr.(type) {
+ case *net.IPNet:
+ if lan10.Contains(x.IP) || lan176.Contains(x.IP) || lan192.Contains(x.IP) {
+ ip := x.IP.Mask(x.Mask).To4()
+ if ip != nil {
+ ip[3] = ip[3] | 0x01
+ gws = append(gws, ip)
+ }
+ }
+ }
+ }
+ }
+ return gws
+}
diff --git a/p2p/nat/natupnp.go b/p2p/nat/natupnp.go
new file mode 100644
index 000000000..ef7765e8d
--- /dev/null
+++ b/p2p/nat/natupnp.go
@@ -0,0 +1,149 @@
+package nat
+
+import (
+ "errors"
+ "fmt"
+ "net"
+ "strings"
+ "time"
+
+ "github.com/huin/goupnp"
+ "github.com/huin/goupnp/dcps/internetgateway1"
+ "github.com/huin/goupnp/dcps/internetgateway2"
+)
+
+type upnp struct {
+ dev *goupnp.RootDevice
+ service string
+ client upnpClient
+}
+
+type upnpClient interface {
+ GetExternalIPAddress() (string, error)
+ AddPortMapping(string, uint16, string, uint16, string, bool, string, uint32) error
+ DeletePortMapping(string, uint16, string) error
+ GetNATRSIPStatus() (sip bool, nat bool, err error)
+}
+
+func (n *upnp) ExternalIP() (addr net.IP, err error) {
+ ipString, err := n.client.GetExternalIPAddress()
+ if err != nil {
+ return nil, err
+ }
+ ip := net.ParseIP(ipString)
+ if ip == nil {
+ return nil, errors.New("bad IP in response")
+ }
+ return ip, nil
+}
+
+func (n *upnp) AddMapping(protocol string, extport, intport int, desc string, lifetime time.Duration) error {
+ ip, err := n.internalAddress()
+ if err != nil {
+ return nil
+ }
+ protocol = strings.ToUpper(protocol)
+ lifetimeS := uint32(lifetime / time.Second)
+ return n.client.AddPortMapping("", uint16(extport), protocol, uint16(intport), ip.String(), true, desc, lifetimeS)
+}
+
+func (n *upnp) internalAddress() (net.IP, error) {
+ devaddr, err := net.ResolveUDPAddr("udp4", n.dev.URLBase.Host)
+ if err != nil {
+ return nil, err
+ }
+ ifaces, err := net.Interfaces()
+ if err != nil {
+ return nil, err
+ }
+ for _, iface := range ifaces {
+ addrs, err := iface.Addrs()
+ if err != nil {
+ return nil, err
+ }
+ for _, addr := range addrs {
+ switch x := addr.(type) {
+ case *net.IPNet:
+ if x.Contains(devaddr.IP) {
+ return x.IP, nil
+ }
+ }
+ }
+ }
+ return nil, fmt.Errorf("could not find local address in same net as %v", devaddr)
+}
+
+func (n *upnp) DeleteMapping(protocol string, extport, intport int) error {
+ return n.client.DeletePortMapping("", uint16(extport), strings.ToUpper(protocol))
+}
+
+func (n *upnp) String() string {
+ return "UPNP " + n.service
+}
+
+// discoverUPnP searches for Internet Gateway Devices
+// and returns the first one it can find on the local network.
+func discoverUPnP() Interface {
+ found := make(chan *upnp, 2)
+ // IGDv1
+ go discover(found, internetgateway1.URN_WANConnectionDevice_1, func(dev *goupnp.RootDevice, sc goupnp.ServiceClient) *upnp {
+ switch sc.Service.ServiceType {
+ case internetgateway1.URN_WANIPConnection_1:
+ return &upnp{dev, "IGDv1-IP1", &internetgateway1.WANIPConnection1{sc}}
+ case internetgateway1.URN_WANPPPConnection_1:
+ return &upnp{dev, "IGDv1-PPP1", &internetgateway1.WANPPPConnection1{sc}}
+ }
+ return nil
+ })
+ // IGDv2
+ go discover(found, internetgateway2.URN_WANConnectionDevice_2, func(dev *goupnp.RootDevice, sc goupnp.ServiceClient) *upnp {
+ switch sc.Service.ServiceType {
+ case internetgateway2.URN_WANIPConnection_1:
+ return &upnp{dev, "IGDv2-IP1", &internetgateway2.WANIPConnection1{sc}}
+ case internetgateway2.URN_WANIPConnection_2:
+ return &upnp{dev, "IGDv2-IP2", &internetgateway2.WANIPConnection2{sc}}
+ case internetgateway2.URN_WANPPPConnection_1:
+ return &upnp{dev, "IGDv2-PPP1", &internetgateway2.WANPPPConnection1{sc}}
+ }
+ return nil
+ })
+ for i := 0; i < cap(found); i++ {
+ if c := <-found; c != nil {
+ return c
+ }
+ }
+ return nil
+}
+
+func discover(out chan<- *upnp, target string, matcher func(*goupnp.RootDevice, goupnp.ServiceClient) *upnp) {
+ devs, err := goupnp.DiscoverDevices(target)
+ if err != nil {
+ return
+ }
+ found := false
+ for i := 0; i < len(devs) && !found; i++ {
+ if devs[i].Root == nil {
+ continue
+ }
+ devs[i].Root.Device.VisitServices(func(service *goupnp.Service) {
+ if found {
+ return
+ }
+ // check for a matching IGD service
+ sc := goupnp.ServiceClient{service.NewSOAPClient(), devs[i].Root, service}
+ upnp := matcher(devs[i].Root, sc)
+ if upnp == nil {
+ return
+ }
+ // check whether port mapping is enabled
+ if _, nat, err := upnp.client.GetNATRSIPStatus(); err != nil || !nat {
+ return
+ }
+ out <- upnp
+ found = true
+ })
+ }
+ if !found {
+ out <- nil
+ }
+}
diff --git a/p2p/peer.go b/p2p/peer.go
new file mode 100644
index 000000000..6b97ea58d
--- /dev/null
+++ b/p2p/peer.go
@@ -0,0 +1,313 @@
+package p2p
+
+import (
+ "errors"
+ "fmt"
+ "io"
+ "io/ioutil"
+ "net"
+ "sort"
+ "sync"
+ "time"
+
+ "github.com/ethereum/go-ethereum/logger"
+ "github.com/ethereum/go-ethereum/p2p/discover"
+ "github.com/ethereum/go-ethereum/rlp"
+)
+
+const (
+ baseProtocolVersion = 3
+ baseProtocolLength = uint64(16)
+ baseProtocolMaxMsgSize = 10 * 1024 * 1024
+
+ pingInterval = 15 * time.Second
+ disconnectGracePeriod = 2 * time.Second
+)
+
+const (
+ // devp2p message codes
+ handshakeMsg = 0x00
+ discMsg = 0x01
+ pingMsg = 0x02
+ pongMsg = 0x03
+ getPeersMsg = 0x04
+ peersMsg = 0x05
+)
+
+// Peer represents a connected remote node.
+type Peer struct {
+ // Peers have all the log methods.
+ // Use them to display messages related to the peer.
+ *logger.Logger
+
+ conn net.Conn
+ rw *conn
+ running map[string]*protoRW
+
+ protoWG sync.WaitGroup
+ protoErr chan error
+ closed chan struct{}
+ disc chan DiscReason
+}
+
+// NewPeer returns a peer for testing purposes.
+func NewPeer(id discover.NodeID, name string, caps []Cap) *Peer {
+ pipe, _ := net.Pipe()
+ msgpipe, _ := MsgPipe()
+ conn := &conn{msgpipe, &protoHandshake{ID: id, Name: name, Caps: caps}}
+ peer := newPeer(pipe, conn, nil)
+ close(peer.closed) // ensures Disconnect doesn't block
+ return peer
+}
+
+// ID returns the node's public key.
+func (p *Peer) ID() discover.NodeID {
+ return p.rw.ID
+}
+
+// Name returns the node name that the remote node advertised.
+func (p *Peer) Name() string {
+ return p.rw.Name
+}
+
+// Caps returns the capabilities (supported subprotocols) of the remote peer.
+func (p *Peer) Caps() []Cap {
+ // TODO: maybe return copy
+ return p.rw.Caps
+}
+
+// RemoteAddr returns the remote address of the network connection.
+func (p *Peer) RemoteAddr() net.Addr {
+ return p.conn.RemoteAddr()
+}
+
+// LocalAddr returns the local address of the network connection.
+func (p *Peer) LocalAddr() net.Addr {
+ return p.conn.LocalAddr()
+}
+
+// Disconnect terminates the peer connection with the given reason.
+// It returns immediately and does not wait until the connection is closed.
+func (p *Peer) Disconnect(reason DiscReason) {
+ select {
+ case p.disc <- reason:
+ case <-p.closed:
+ }
+}
+
+// String implements fmt.Stringer.
+func (p *Peer) String() string {
+ return fmt.Sprintf("Peer %.8x %v", p.rw.ID[:], p.RemoteAddr())
+}
+
+func newPeer(fd net.Conn, conn *conn, protocols []Protocol) *Peer {
+ logtag := fmt.Sprintf("Peer %.8x %v", conn.ID[:], fd.RemoteAddr())
+ p := &Peer{
+ Logger: logger.NewLogger(logtag),
+ conn: fd,
+ rw: conn,
+ running: matchProtocols(protocols, conn.Caps, conn),
+ disc: make(chan DiscReason),
+ protoErr: make(chan error),
+ closed: make(chan struct{}),
+ }
+ return p
+}
+
+func (p *Peer) run() DiscReason {
+ var readErr = make(chan error, 1)
+ defer p.closeProtocols()
+ defer close(p.closed)
+
+ p.startProtocols()
+ go func() { readErr <- p.readLoop() }()
+
+ ping := time.NewTicker(pingInterval)
+ defer ping.Stop()
+
+ // Wait for an error or disconnect.
+ var reason DiscReason
+loop:
+ for {
+ select {
+ case <-ping.C:
+ go func() {
+ if err := SendItems(p.rw, pingMsg); err != nil {
+ p.protoErr <- err
+ return
+ }
+ }()
+ case err := <-readErr:
+ // We rely on protocols to abort if there is a write error. It
+ // might be more robust to handle them here as well.
+ p.DebugDetailf("Read error: %v\n", err)
+ p.conn.Close()
+ return DiscNetworkError
+ case err := <-p.protoErr:
+ reason = discReasonForError(err)
+ break loop
+ case reason = <-p.disc:
+ break loop
+ }
+ }
+ p.politeDisconnect(reason)
+
+ // Wait for readLoop. It will end because conn is now closed.
+ <-readErr
+ p.Debugf("Disconnected: %v\n", reason)
+ return reason
+}
+
+func (p *Peer) politeDisconnect(reason DiscReason) {
+ done := make(chan struct{})
+ go func() {
+ SendItems(p.rw, discMsg, uint(reason))
+ // Wait for the other side to close the connection.
+ // Discard any data that they send until then.
+ io.Copy(ioutil.Discard, p.conn)
+ close(done)
+ }()
+ select {
+ case <-done:
+ case <-time.After(disconnectGracePeriod):
+ }
+ p.conn.Close()
+}
+
+func (p *Peer) readLoop() error {
+ for {
+ p.conn.SetDeadline(time.Now().Add(frameReadTimeout))
+ msg, err := p.rw.ReadMsg()
+ if err != nil {
+ return err
+ }
+ if err = p.handle(msg); err != nil {
+ return err
+ }
+ }
+ return nil
+}
+
+func (p *Peer) handle(msg Msg) error {
+ switch {
+ case msg.Code == pingMsg:
+ msg.Discard()
+ go SendItems(p.rw, pongMsg)
+ case msg.Code == discMsg:
+ var reason [1]DiscReason
+ // no need to discard or for error checking, we'll close the
+ // connection after this.
+ rlp.Decode(msg.Payload, &reason)
+ p.Debugf("Disconnect requested: %v\n", reason[0])
+ p.Disconnect(DiscRequested)
+ return discRequestedError(reason[0])
+ case msg.Code < baseProtocolLength:
+ // ignore other base protocol messages
+ return msg.Discard()
+ default:
+ // it's a subprotocol message
+ proto, err := p.getProto(msg.Code)
+ if err != nil {
+ return fmt.Errorf("msg code out of range: %v", msg.Code)
+ }
+ proto.in <- msg
+ }
+ return nil
+}
+
+// matchProtocols creates structures for matching named subprotocols.
+func matchProtocols(protocols []Protocol, caps []Cap, rw MsgReadWriter) map[string]*protoRW {
+ sort.Sort(capsByName(caps))
+ offset := baseProtocolLength
+ result := make(map[string]*protoRW)
+outer:
+ for _, cap := range caps {
+ for _, proto := range protocols {
+ if proto.Name == cap.Name && proto.Version == cap.Version && result[cap.Name] == nil {
+ result[cap.Name] = &protoRW{Protocol: proto, offset: offset, in: make(chan Msg), w: rw}
+ offset += proto.Length
+ continue outer
+ }
+ }
+ }
+ return result
+}
+
+func (p *Peer) startProtocols() {
+ for _, proto := range p.running {
+ proto := proto
+ p.DebugDetailf("Starting protocol %s/%d\n", proto.Name, proto.Version)
+ p.protoWG.Add(1)
+ go func() {
+ err := proto.Run(p, proto)
+ if err == nil {
+ p.DebugDetailf("Protocol %s/%d returned\n", proto.Name, proto.Version)
+ err = errors.New("protocol returned")
+ } else {
+ p.DebugDetailf("Protocol %s/%d error: %v\n", proto.Name, proto.Version, err)
+ }
+ select {
+ case p.protoErr <- err:
+ case <-p.closed:
+ }
+ p.protoWG.Done()
+ }()
+ }
+}
+
+// getProto finds the protocol responsible for handling
+// the given message code.
+func (p *Peer) getProto(code uint64) (*protoRW, error) {
+ for _, proto := range p.running {
+ if code >= proto.offset && code < proto.offset+proto.Length {
+ return proto, nil
+ }
+ }
+ return nil, newPeerError(errInvalidMsgCode, "%d", code)
+}
+
+func (p *Peer) closeProtocols() {
+ for _, p := range p.running {
+ close(p.in)
+ }
+ p.protoWG.Wait()
+}
+
+// writeProtoMsg sends the given message on behalf of the given named protocol.
+// this exists because of Server.Broadcast.
+func (p *Peer) writeProtoMsg(protoName string, msg Msg) error {
+ proto, ok := p.running[protoName]
+ if !ok {
+ return fmt.Errorf("protocol %s not handled by peer", protoName)
+ }
+ if msg.Code >= proto.Length {
+ return newPeerError(errInvalidMsgCode, "code %x is out of range for protocol %q", msg.Code, protoName)
+ }
+ msg.Code += proto.offset
+ return p.rw.WriteMsg(msg)
+}
+
+type protoRW struct {
+ Protocol
+
+ in chan Msg
+ offset uint64
+ w MsgWriter
+}
+
+func (rw *protoRW) WriteMsg(msg Msg) error {
+ if msg.Code >= rw.Length {
+ return newPeerError(errInvalidMsgCode, "not handled")
+ }
+ msg.Code += rw.offset
+ return rw.w.WriteMsg(msg)
+}
+
+func (rw *protoRW) ReadMsg() (Msg, error) {
+ msg, ok := <-rw.in
+ if !ok {
+ return msg, io.EOF
+ }
+ msg.Code -= rw.offset
+ return msg, nil
+}
diff --git a/p2p/peer_error.go b/p2p/peer_error.go
new file mode 100644
index 000000000..0ff4f4b43
--- /dev/null
+++ b/p2p/peer_error.go
@@ -0,0 +1,131 @@
+package p2p
+
+import (
+ "fmt"
+)
+
+const (
+ errMagicTokenMismatch = iota
+ errRead
+ errWrite
+ errMisc
+ errInvalidMsgCode
+ errInvalidMsg
+ errP2PVersionMismatch
+ errPubkeyInvalid
+ errPubkeyForbidden
+ errProtocolBreach
+ errPingTimeout
+ errInvalidNetworkId
+ errInvalidProtocolVersion
+)
+
+var errorToString = map[int]string{
+ errMagicTokenMismatch: "magic token mismatch",
+ errRead: "read error",
+ errWrite: "write error",
+ errMisc: "misc error",
+ errInvalidMsgCode: "invalid message code",
+ errInvalidMsg: "invalid message",
+ errP2PVersionMismatch: "P2P Version Mismatch",
+ errPubkeyInvalid: "public key invalid",
+ errPubkeyForbidden: "public key forbidden",
+ errProtocolBreach: "protocol Breach",
+ errPingTimeout: "ping timeout",
+ errInvalidNetworkId: "invalid network id",
+ errInvalidProtocolVersion: "invalid protocol version",
+}
+
+type peerError struct {
+ Code int
+ message string
+}
+
+func newPeerError(code int, format string, v ...interface{}) *peerError {
+ desc, ok := errorToString[code]
+ if !ok {
+ panic("invalid error code")
+ }
+ err := &peerError{code, desc}
+ if format != "" {
+ err.message += ": " + fmt.Sprintf(format, v...)
+ }
+ return err
+}
+
+func (self *peerError) Error() string {
+ return self.message
+}
+
+type DiscReason byte
+
+const (
+ DiscRequested DiscReason = iota
+ DiscNetworkError
+ DiscProtocolError
+ DiscUselessPeer
+ DiscTooManyPeers
+ DiscAlreadyConnected
+ DiscIncompatibleVersion
+ DiscInvalidIdentity
+ DiscQuitting
+ DiscUnexpectedIdentity
+ DiscSelf
+ DiscReadTimeout
+ DiscSubprotocolError
+)
+
+var discReasonToString = [...]string{
+ DiscRequested: "Disconnect requested",
+ DiscNetworkError: "Network error",
+ DiscProtocolError: "Breach of protocol",
+ DiscUselessPeer: "Useless peer",
+ DiscTooManyPeers: "Too many peers",
+ DiscAlreadyConnected: "Already connected",
+ DiscIncompatibleVersion: "Incompatible P2P protocol version",
+ DiscInvalidIdentity: "Invalid node identity",
+ DiscQuitting: "Client quitting",
+ DiscUnexpectedIdentity: "Unexpected identity",
+ DiscSelf: "Connected to self",
+ DiscReadTimeout: "Read timeout",
+ DiscSubprotocolError: "Subprotocol error",
+}
+
+func (d DiscReason) String() string {
+ if len(discReasonToString) < int(d) {
+ return fmt.Sprintf("Unknown Reason(%d)", d)
+ }
+ return discReasonToString[d]
+}
+
+type discRequestedError DiscReason
+
+func (err discRequestedError) Error() string {
+ return fmt.Sprintf("disconnect requested: %v", DiscReason(err))
+}
+
+func discReasonForError(err error) DiscReason {
+ if reason, ok := err.(discRequestedError); ok {
+ return DiscReason(reason)
+ }
+ peerError, ok := err.(*peerError)
+ if !ok {
+ return DiscSubprotocolError
+ }
+ switch peerError.Code {
+ case errP2PVersionMismatch:
+ return DiscIncompatibleVersion
+ case errPubkeyInvalid:
+ return DiscInvalidIdentity
+ case errPubkeyForbidden:
+ return DiscUselessPeer
+ case errInvalidMsgCode, errMagicTokenMismatch, errProtocolBreach:
+ return DiscProtocolError
+ case errPingTimeout:
+ return DiscReadTimeout
+ case errRead, errWrite:
+ return DiscNetworkError
+ default:
+ return DiscSubprotocolError
+ }
+}
diff --git a/p2p/peer_test.go b/p2p/peer_test.go
new file mode 100644
index 000000000..3c4c71c0c
--- /dev/null
+++ b/p2p/peer_test.go
@@ -0,0 +1,195 @@
+package p2p
+
+import (
+ "bytes"
+ "fmt"
+ "io"
+ "net"
+ "reflect"
+ "testing"
+ "time"
+)
+
+var discard = Protocol{
+ Name: "discard",
+ Length: 1,
+ Run: func(p *Peer, rw MsgReadWriter) error {
+ for {
+ msg, err := rw.ReadMsg()
+ if err != nil {
+ return err
+ }
+ fmt.Printf("discarding %d\n", msg.Code)
+ if err = msg.Discard(); err != nil {
+ return err
+ }
+ }
+ },
+}
+
+func testPeer(protos []Protocol) (io.Closer, *conn, *Peer, <-chan DiscReason) {
+ fd1, _ := net.Pipe()
+ hs1 := &protoHandshake{ID: randomID(), Version: baseProtocolVersion}
+ hs2 := &protoHandshake{ID: randomID(), Version: baseProtocolVersion}
+ for _, p := range protos {
+ hs1.Caps = append(hs1.Caps, p.cap())
+ hs2.Caps = append(hs2.Caps, p.cap())
+ }
+
+ p1, p2 := MsgPipe()
+ peer := newPeer(fd1, &conn{p1, hs1}, protos)
+ errc := make(chan DiscReason, 1)
+ go func() { errc <- peer.run() }()
+
+ return p1, &conn{p2, hs2}, peer, errc
+}
+
+func TestPeerProtoReadMsg(t *testing.T) {
+ defer testlog(t).detach()
+
+ done := make(chan struct{})
+ proto := Protocol{
+ Name: "a",
+ Length: 5,
+ Run: func(peer *Peer, rw MsgReadWriter) error {
+ if err := ExpectMsg(rw, 2, []uint{1}); err != nil {
+ t.Error(err)
+ }
+ if err := ExpectMsg(rw, 3, []uint{2}); err != nil {
+ t.Error(err)
+ }
+ if err := ExpectMsg(rw, 4, []uint{3}); err != nil {
+ t.Error(err)
+ }
+ close(done)
+ return nil
+ },
+ }
+
+ closer, rw, _, errc := testPeer([]Protocol{proto})
+ defer closer.Close()
+
+ Send(rw, baseProtocolLength+2, []uint{1})
+ Send(rw, baseProtocolLength+3, []uint{2})
+ Send(rw, baseProtocolLength+4, []uint{3})
+
+ select {
+ case <-done:
+ case err := <-errc:
+ t.Errorf("peer returned: %v", err)
+ case <-time.After(2 * time.Second):
+ t.Errorf("receive timeout")
+ }
+}
+
+func TestPeerProtoEncodeMsg(t *testing.T) {
+ defer testlog(t).detach()
+
+ proto := Protocol{
+ Name: "a",
+ Length: 2,
+ Run: func(peer *Peer, rw MsgReadWriter) error {
+ if err := SendItems(rw, 2); err == nil {
+ t.Error("expected error for out-of-range msg code, got nil")
+ }
+ if err := SendItems(rw, 1, "foo", "bar"); err != nil {
+ t.Errorf("write error: %v", err)
+ }
+ return nil
+ },
+ }
+ closer, rw, _, _ := testPeer([]Protocol{proto})
+ defer closer.Close()
+
+ if err := ExpectMsg(rw, 17, []string{"foo", "bar"}); err != nil {
+ t.Error(err)
+ }
+}
+
+func TestPeerWriteForBroadcast(t *testing.T) {
+ defer testlog(t).detach()
+
+ closer, rw, peer, peerErr := testPeer([]Protocol{discard})
+ defer closer.Close()
+
+ emptymsg := func(code uint64) Msg {
+ return Msg{Code: code, Size: 0, Payload: bytes.NewReader(nil)}
+ }
+
+ // test write errors
+ if err := peer.writeProtoMsg("b", emptymsg(3)); err == nil {
+ t.Errorf("expected error for unknown protocol, got nil")
+ }
+ if err := peer.writeProtoMsg("discard", emptymsg(8)); err == nil {
+ t.Errorf("expected error for out-of-range msg code, got nil")
+ } else if perr, ok := err.(*peerError); !ok || perr.Code != errInvalidMsgCode {
+ t.Errorf("wrong error for out-of-range msg code, got %#v", err)
+ }
+
+ // setup for reading the message on the other end
+ read := make(chan struct{})
+ go func() {
+ if err := ExpectMsg(rw, 16, nil); err != nil {
+ t.Error(err)
+ }
+ close(read)
+ }()
+
+ // test successful write
+ if err := peer.writeProtoMsg("discard", emptymsg(0)); err != nil {
+ t.Errorf("expect no error for known protocol: %v", err)
+ }
+ select {
+ case <-read:
+ case err := <-peerErr:
+ t.Fatalf("peer stopped: %v", err)
+ }
+}
+
+func TestPeerPing(t *testing.T) {
+ defer testlog(t).detach()
+
+ closer, rw, _, _ := testPeer(nil)
+ defer closer.Close()
+ if err := SendItems(rw, pingMsg); err != nil {
+ t.Fatal(err)
+ }
+ if err := ExpectMsg(rw, pongMsg, nil); err != nil {
+ t.Error(err)
+ }
+}
+
+func TestPeerDisconnect(t *testing.T) {
+ defer testlog(t).detach()
+
+ closer, rw, _, disc := testPeer(nil)
+ defer closer.Close()
+ if err := SendItems(rw, discMsg, DiscQuitting); err != nil {
+ t.Fatal(err)
+ }
+ if err := ExpectMsg(rw, discMsg, []interface{}{DiscRequested}); err != nil {
+ t.Error(err)
+ }
+ closer.Close() // make test end faster
+ if reason := <-disc; reason != DiscRequested {
+ t.Errorf("run returned wrong reason: got %v, want %v", reason, DiscRequested)
+ }
+}
+
+func TestNewPeer(t *testing.T) {
+ name := "nodename"
+ caps := []Cap{{"foo", 2}, {"bar", 3}}
+ id := randomID()
+ p := NewPeer(id, name, caps)
+ if p.ID() != id {
+ t.Errorf("ID mismatch: got %v, expected %v", p.ID(), id)
+ }
+ if p.Name() != name {
+ t.Errorf("Name mismatch: got %v, expected %v", p.Name(), name)
+ }
+ if !reflect.DeepEqual(p.Caps(), caps) {
+ t.Errorf("Caps mismatch: got %v, expected %v", p.Caps(), caps)
+ }
+
+ p.Disconnect(DiscAlreadyConnected) // Should not hang
+}
diff --git a/p2p/protocol.go b/p2p/protocol.go
new file mode 100644
index 000000000..5fa395eda
--- /dev/null
+++ b/p2p/protocol.go
@@ -0,0 +1,50 @@
+package p2p
+
+import "fmt"
+
+// Protocol represents a P2P subprotocol implementation.
+type Protocol struct {
+ // Name should contain the official protocol name,
+ // often a three-letter word.
+ Name string
+
+ // Version should contain the version number of the protocol.
+ Version uint
+
+ // Length should contain the number of message codes used
+ // by the protocol.
+ Length uint64
+
+ // Run is called in a new groutine when the protocol has been
+ // negotiated with a peer. It should read and write messages from
+ // rw. The Payload for each message must be fully consumed.
+ //
+ // The peer connection is closed when Start returns. It should return
+ // any protocol-level error (such as an I/O error) that is
+ // encountered.
+ Run func(peer *Peer, rw MsgReadWriter) error
+}
+
+func (p Protocol) cap() Cap {
+ return Cap{p.Name, p.Version}
+}
+
+// Cap is the structure of a peer capability.
+type Cap struct {
+ Name string
+ Version uint
+}
+
+func (cap Cap) RlpData() interface{} {
+ return []interface{}{cap.Name, cap.Version}
+}
+
+func (cap Cap) String() string {
+ return fmt.Sprintf("%s/%d", cap.Name, cap.Version)
+}
+
+type capsByName []Cap
+
+func (cs capsByName) Len() int { return len(cs) }
+func (cs capsByName) Less(i, j int) bool { return cs[i].Name < cs[j].Name }
+func (cs capsByName) Swap(i, j int) { cs[i], cs[j] = cs[j], cs[i] }
diff --git a/p2p/rlpx.go b/p2p/rlpx.go
new file mode 100644
index 000000000..6b533e275
--- /dev/null
+++ b/p2p/rlpx.go
@@ -0,0 +1,174 @@
+package p2p
+
+import (
+ "bytes"
+ "crypto/aes"
+ "crypto/cipher"
+ "crypto/hmac"
+ "errors"
+ "hash"
+ "io"
+
+ "github.com/ethereum/go-ethereum/rlp"
+)
+
+var (
+ // this is used in place of actual frame header data.
+ // TODO: replace this when Msg contains the protocol type code.
+ zeroHeader = []byte{0xC2, 0x80, 0x80}
+
+ // sixteen zero bytes
+ zero16 = make([]byte, 16)
+
+ maxUint24 = ^uint32(0) >> 8
+)
+
+// rlpxFrameRW implements a simplified version of RLPx framing.
+// chunked messages are not supported and all headers are equal to
+// zeroHeader.
+//
+// rlpxFrameRW is not safe for concurrent use from multiple goroutines.
+type rlpxFrameRW struct {
+ conn io.ReadWriter
+ enc cipher.Stream
+ dec cipher.Stream
+
+ macCipher cipher.Block
+ egressMAC hash.Hash
+ ingressMAC hash.Hash
+}
+
+func newRlpxFrameRW(conn io.ReadWriter, s secrets) *rlpxFrameRW {
+ macc, err := aes.NewCipher(s.MAC)
+ if err != nil {
+ panic("invalid MAC secret: " + err.Error())
+ }
+ encc, err := aes.NewCipher(s.AES)
+ if err != nil {
+ panic("invalid AES secret: " + err.Error())
+ }
+ // we use an all-zeroes IV for AES because the key used
+ // for encryption is ephemeral.
+ iv := make([]byte, encc.BlockSize())
+ return &rlpxFrameRW{
+ conn: conn,
+ enc: cipher.NewCTR(encc, iv),
+ dec: cipher.NewCTR(encc, iv),
+ macCipher: macc,
+ egressMAC: s.EgressMAC,
+ ingressMAC: s.IngressMAC,
+ }
+}
+
+func (rw *rlpxFrameRW) WriteMsg(msg Msg) error {
+ ptype, _ := rlp.EncodeToBytes(msg.Code)
+
+ // write header
+ headbuf := make([]byte, 32)
+ fsize := uint32(len(ptype)) + msg.Size
+ if fsize > maxUint24 {
+ return errors.New("message size overflows uint24")
+ }
+ putInt24(fsize, headbuf) // TODO: check overflow
+ copy(headbuf[3:], zeroHeader)
+ rw.enc.XORKeyStream(headbuf[:16], headbuf[:16]) // first half is now encrypted
+
+ // write header MAC
+ copy(headbuf[16:], updateMAC(rw.egressMAC, rw.macCipher, headbuf[:16]))
+ if _, err := rw.conn.Write(headbuf); err != nil {
+ return err
+ }
+
+ // write encrypted frame, updating the egress MAC hash with
+ // the data written to conn.
+ tee := cipher.StreamWriter{S: rw.enc, W: io.MultiWriter(rw.conn, rw.egressMAC)}
+ if _, err := tee.Write(ptype); err != nil {
+ return err
+ }
+ if _, err := io.Copy(tee, msg.Payload); err != nil {
+ return err
+ }
+ if padding := fsize % 16; padding > 0 {
+ if _, err := tee.Write(zero16[:16-padding]); err != nil {
+ return err
+ }
+ }
+
+ // write frame MAC. egress MAC hash is up to date because
+ // frame content was written to it as well.
+ fmacseed := rw.egressMAC.Sum(nil)
+ mac := updateMAC(rw.egressMAC, rw.macCipher, fmacseed)
+ _, err := rw.conn.Write(mac)
+ return err
+}
+
+func (rw *rlpxFrameRW) ReadMsg() (msg Msg, err error) {
+ // read the header
+ headbuf := make([]byte, 32)
+ if _, err := io.ReadFull(rw.conn, headbuf); err != nil {
+ return msg, err
+ }
+ // verify header mac
+ shouldMAC := updateMAC(rw.ingressMAC, rw.macCipher, headbuf[:16])
+ if !hmac.Equal(shouldMAC, headbuf[16:]) {
+ return msg, errors.New("bad header MAC")
+ }
+ rw.dec.XORKeyStream(headbuf[:16], headbuf[:16]) // first half is now decrypted
+ fsize := readInt24(headbuf)
+ // ignore protocol type for now
+
+ // read the frame content
+ var rsize = fsize // frame size rounded up to 16 byte boundary
+ if padding := fsize % 16; padding > 0 {
+ rsize += 16 - padding
+ }
+ framebuf := make([]byte, rsize)
+ if _, err := io.ReadFull(rw.conn, framebuf); err != nil {
+ return msg, err
+ }
+
+ // read and validate frame MAC. we can re-use headbuf for that.
+ rw.ingressMAC.Write(framebuf)
+ fmacseed := rw.ingressMAC.Sum(nil)
+ if _, err := io.ReadFull(rw.conn, headbuf[:16]); err != nil {
+ return msg, err
+ }
+ shouldMAC = updateMAC(rw.ingressMAC, rw.macCipher, fmacseed)
+ if !hmac.Equal(shouldMAC, headbuf[:16]) {
+ return msg, errors.New("bad frame MAC")
+ }
+
+ // decrypt frame content
+ rw.dec.XORKeyStream(framebuf, framebuf)
+
+ // decode message code
+ content := bytes.NewReader(framebuf[:fsize])
+ if err := rlp.Decode(content, &msg.Code); err != nil {
+ return msg, err
+ }
+ msg.Size = uint32(content.Len())
+ msg.Payload = content
+ return msg, nil
+}
+
+// updateMAC reseeds the given hash with encrypted seed.
+// it returns the first 16 bytes of the hash sum after seeding.
+func updateMAC(mac hash.Hash, block cipher.Block, seed []byte) []byte {
+ aesbuf := make([]byte, aes.BlockSize)
+ block.Encrypt(aesbuf, mac.Sum(nil))
+ for i := range aesbuf {
+ aesbuf[i] ^= seed[i]
+ }
+ mac.Write(aesbuf)
+ return mac.Sum(nil)[:16]
+}
+
+func readInt24(b []byte) uint32 {
+ return uint32(b[2]) | uint32(b[1])<<8 | uint32(b[0])<<16
+}
+
+func putInt24(v uint32, b []byte) {
+ b[0] = byte(v >> 16)
+ b[1] = byte(v >> 8)
+ b[2] = byte(v)
+}
diff --git a/p2p/rlpx_test.go b/p2p/rlpx_test.go
new file mode 100644
index 000000000..d98f1c2cd
--- /dev/null
+++ b/p2p/rlpx_test.go
@@ -0,0 +1,124 @@
+package p2p
+
+import (
+ "bytes"
+ "crypto/rand"
+ "io/ioutil"
+ "strings"
+ "testing"
+
+ "github.com/ethereum/go-ethereum/crypto"
+ "github.com/ethereum/go-ethereum/crypto/sha3"
+ "github.com/ethereum/go-ethereum/rlp"
+)
+
+func TestRlpxFrameFake(t *testing.T) {
+ buf := new(bytes.Buffer)
+ hash := fakeHash([]byte{1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1})
+ rw := newRlpxFrameRW(buf, secrets{
+ AES: crypto.Sha3(),
+ MAC: crypto.Sha3(),
+ IngressMAC: hash,
+ EgressMAC: hash,
+ })
+
+ golden := unhex(`
+00828ddae471818bb0bfa6b551d1cb42
+01010101010101010101010101010101
+ba628a4ba590cb43f7848f41c4382885
+01010101010101010101010101010101
+`)
+
+ // Check WriteMsg. This puts a message into the buffer.
+ if err := Send(rw, 8, []uint{1, 2, 3, 4}); err != nil {
+ t.Fatalf("WriteMsg error: %v", err)
+ }
+ written := buf.Bytes()
+ if !bytes.Equal(written, golden) {
+ t.Fatalf("output mismatch:\n got: %x\n want: %x", written, golden)
+ }
+
+ // Check ReadMsg. It reads the message encoded by WriteMsg, which
+ // is equivalent to the golden message above.
+ msg, err := rw.ReadMsg()
+ if err != nil {
+ t.Fatalf("ReadMsg error: %v", err)
+ }
+ if msg.Size != 5 {
+ t.Errorf("msg size mismatch: got %d, want %d", msg.Size, 5)
+ }
+ if msg.Code != 8 {
+ t.Errorf("msg code mismatch: got %d, want %d", msg.Code, 8)
+ }
+ payload, _ := ioutil.ReadAll(msg.Payload)
+ wantPayload := unhex("C401020304")
+ if !bytes.Equal(payload, wantPayload) {
+ t.Errorf("msg payload mismatch:\ngot %x\nwant %x", payload, wantPayload)
+ }
+}
+
+type fakeHash []byte
+
+func (fakeHash) Write(p []byte) (int, error) { return len(p), nil }
+func (fakeHash) Reset() {}
+func (fakeHash) BlockSize() int { return 0 }
+
+func (h fakeHash) Size() int { return len(h) }
+func (h fakeHash) Sum(b []byte) []byte { return append(b, h...) }
+
+func TestRlpxFrameRW(t *testing.T) {
+ var (
+ aesSecret = make([]byte, 16)
+ macSecret = make([]byte, 16)
+ egressMACinit = make([]byte, 32)
+ ingressMACinit = make([]byte, 32)
+ )
+ for _, s := range [][]byte{aesSecret, macSecret, egressMACinit, ingressMACinit} {
+ rand.Read(s)
+ }
+ conn := new(bytes.Buffer)
+
+ s1 := secrets{
+ AES: aesSecret,
+ MAC: macSecret,
+ EgressMAC: sha3.NewKeccak256(),
+ IngressMAC: sha3.NewKeccak256(),
+ }
+ s1.EgressMAC.Write(egressMACinit)
+ s1.IngressMAC.Write(ingressMACinit)
+ rw1 := newRlpxFrameRW(conn, s1)
+
+ s2 := secrets{
+ AES: aesSecret,
+ MAC: macSecret,
+ EgressMAC: sha3.NewKeccak256(),
+ IngressMAC: sha3.NewKeccak256(),
+ }
+ s2.EgressMAC.Write(ingressMACinit)
+ s2.IngressMAC.Write(egressMACinit)
+ rw2 := newRlpxFrameRW(conn, s2)
+
+ // send some messages
+ for i := 0; i < 10; i++ {
+ // write message into conn buffer
+ wmsg := []interface{}{"foo", "bar", strings.Repeat("test", i)}
+ err := Send(rw1, uint64(i), wmsg)
+ if err != nil {
+ t.Fatalf("WriteMsg error (i=%d): %v", i, err)
+ }
+
+ // read message that rw1 just wrote
+ msg, err := rw2.ReadMsg()
+ if err != nil {
+ t.Fatalf("ReadMsg error (i=%d): %v", i, err)
+ }
+ if msg.Code != uint64(i) {
+ t.Fatalf("msg code mismatch: got %d, want %d", msg.Code, i)
+ }
+ payload, _ := ioutil.ReadAll(msg.Payload)
+ wantPayload, _ := rlp.EncodeToBytes(wmsg)
+ if !bytes.Equal(payload, wantPayload) {
+ t.Fatalf("msg payload mismatch:\ngot %x\nwant %x", payload, wantPayload)
+ }
+ }
+}
diff --git a/p2p/server.go b/p2p/server.go
new file mode 100644
index 000000000..813b0676f
--- /dev/null
+++ b/p2p/server.go
@@ -0,0 +1,426 @@
+package p2p
+
+import (
+ "bytes"
+ "crypto/ecdsa"
+ "errors"
+ "fmt"
+ "net"
+ "sync"
+ "time"
+
+ "github.com/ethereum/go-ethereum/logger"
+ "github.com/ethereum/go-ethereum/p2p/discover"
+ "github.com/ethereum/go-ethereum/p2p/nat"
+ "github.com/ethereum/go-ethereum/rlp"
+)
+
+const (
+ defaultDialTimeout = 10 * time.Second
+ refreshPeersInterval = 30 * time.Second
+
+ // total timeout for encryption handshake and protocol
+ // handshake in both directions.
+ handshakeTimeout = 5 * time.Second
+ // maximum time allowed for reading a complete message.
+ // this is effectively the amount of time a connection can be idle.
+ frameReadTimeout = 1 * time.Minute
+ // maximum amount of time allowed for writing a complete message.
+ frameWriteTimeout = 5 * time.Second
+)
+
+var srvlog = logger.NewLogger("P2P Server")
+var srvjslog = logger.NewJsonLogger()
+
+// Server manages all peer connections.
+//
+// The fields of Server are used as configuration parameters.
+// You should set them before starting the Server. Fields may not be
+// modified while the server is running.
+type Server struct {
+ // This field must be set to a valid secp256k1 private key.
+ PrivateKey *ecdsa.PrivateKey
+
+ // MaxPeers is the maximum number of peers that can be
+ // connected. It must be greater than zero.
+ MaxPeers int
+
+ // Name sets the node name of this server.
+ // Use common.MakeName to create a name that follows existing conventions.
+ Name string
+
+ // Bootstrap nodes are used to establish connectivity
+ // with the rest of the network.
+ BootstrapNodes []*discover.Node
+
+ // Protocols should contain the protocols supported
+ // by the server. Matching protocols are launched for
+ // each peer.
+ Protocols []Protocol
+
+ // If ListenAddr is set to a non-nil address, the server
+ // will listen for incoming connections.
+ //
+ // If the port is zero, the operating system will pick a port. The
+ // ListenAddr field will be updated with the actual address when
+ // the server is started.
+ ListenAddr string
+
+ // If set to a non-nil value, the given NAT port mapper
+ // is used to make the listening port available to the
+ // Internet.
+ NAT nat.Interface
+
+ // If Dialer is set to a non-nil value, the given Dialer
+ // is used to dial outbound peer connections.
+ Dialer *net.Dialer
+
+ // If NoDial is true, the server will not dial any peers.
+ NoDial bool
+
+ // Hooks for testing. These are useful because we can inhibit
+ // the whole protocol stack.
+ setupFunc
+ newPeerHook
+
+ ourHandshake *protoHandshake
+
+ lock sync.RWMutex
+ running bool
+ listener net.Listener
+ peers map[discover.NodeID]*Peer
+
+ ntab *discover.Table
+
+ quit chan struct{}
+ loopWG sync.WaitGroup // {dial,listen,nat}Loop
+ peerWG sync.WaitGroup // active peer goroutines
+ peerConnect chan *discover.Node
+}
+
+type setupFunc func(net.Conn, *ecdsa.PrivateKey, *protoHandshake, *discover.Node) (*conn, error)
+type newPeerHook func(*Peer)
+
+// Peers returns all connected peers.
+func (srv *Server) Peers() (peers []*Peer) {
+ srv.lock.RLock()
+ defer srv.lock.RUnlock()
+ for _, peer := range srv.peers {
+ if peer != nil {
+ peers = append(peers, peer)
+ }
+ }
+ return
+}
+
+// PeerCount returns the number of connected peers.
+func (srv *Server) PeerCount() int {
+ srv.lock.RLock()
+ n := len(srv.peers)
+ srv.lock.RUnlock()
+ return n
+}
+
+// SuggestPeer creates a connection to the given Node if it
+// is not already connected.
+func (srv *Server) SuggestPeer(n *discover.Node) {
+ srv.peerConnect <- n
+}
+
+// Broadcast sends an RLP-encoded message to all connected peers.
+// This method is deprecated and will be removed later.
+func (srv *Server) Broadcast(protocol string, code uint64, data interface{}) error {
+ var payload []byte
+ if data != nil {
+ var err error
+ payload, err = rlp.EncodeToBytes(data)
+ if err != nil {
+ return err
+ }
+ }
+ srv.lock.RLock()
+ defer srv.lock.RUnlock()
+ for _, peer := range srv.peers {
+ if peer != nil {
+ var msg = Msg{Code: code}
+ if data != nil {
+ msg.Payload = bytes.NewReader(payload)
+ msg.Size = uint32(len(payload))
+ }
+ peer.writeProtoMsg(protocol, msg)
+ }
+ }
+ return nil
+}
+
+// Start starts running the server.
+// Servers can be re-used and started again after stopping.
+func (srv *Server) Start() (err error) {
+ srv.lock.Lock()
+ defer srv.lock.Unlock()
+ if srv.running {
+ return errors.New("server already running")
+ }
+ srvlog.Infoln("Starting Server")
+
+ // static fields
+ if srv.PrivateKey == nil {
+ return fmt.Errorf("Server.PrivateKey must be set to a non-nil key")
+ }
+ if srv.MaxPeers <= 0 {
+ return fmt.Errorf("Server.MaxPeers must be > 0")
+ }
+ srv.quit = make(chan struct{})
+ srv.peers = make(map[discover.NodeID]*Peer)
+ srv.peerConnect = make(chan *discover.Node)
+ if srv.setupFunc == nil {
+ srv.setupFunc = setupConn
+ }
+
+ // node table
+ ntab, err := discover.ListenUDP(srv.PrivateKey, srv.ListenAddr, srv.NAT)
+ if err != nil {
+ return err
+ }
+ srv.ntab = ntab
+
+ // handshake
+ srv.ourHandshake = &protoHandshake{Version: baseProtocolVersion, Name: srv.Name, ID: ntab.Self().ID}
+ for _, p := range srv.Protocols {
+ srv.ourHandshake.Caps = append(srv.ourHandshake.Caps, p.cap())
+ }
+
+ // listen/dial
+ if srv.ListenAddr != "" {
+ if err := srv.startListening(); err != nil {
+ return err
+ }
+ }
+ if srv.Dialer == nil {
+ srv.Dialer = &net.Dialer{Timeout: defaultDialTimeout}
+ }
+ if !srv.NoDial {
+ srv.loopWG.Add(1)
+ go srv.dialLoop()
+ }
+ if srv.NoDial && srv.ListenAddr == "" {
+ srvlog.Warnln("I will be kind-of useless, neither dialing nor listening.")
+ }
+
+ srv.running = true
+ return nil
+}
+
+func (srv *Server) startListening() error {
+ listener, err := net.Listen("tcp", srv.ListenAddr)
+ if err != nil {
+ return err
+ }
+ laddr := listener.Addr().(*net.TCPAddr)
+ srv.ListenAddr = laddr.String()
+ srv.listener = listener
+ srv.loopWG.Add(1)
+ go srv.listenLoop()
+ if !laddr.IP.IsLoopback() && srv.NAT != nil {
+ srv.loopWG.Add(1)
+ go func() {
+ nat.Map(srv.NAT, srv.quit, "tcp", laddr.Port, laddr.Port, "ethereum p2p")
+ srv.loopWG.Done()
+ }()
+ }
+ return nil
+}
+
+// Stop terminates the server and all active peer connections.
+// It blocks until all active connections have been closed.
+func (srv *Server) Stop() {
+ srv.lock.Lock()
+ if !srv.running {
+ srv.lock.Unlock()
+ return
+ }
+ srv.running = false
+ srv.lock.Unlock()
+
+ srvlog.Infoln("Stopping Server")
+ srv.ntab.Close()
+ if srv.listener != nil {
+ // this unblocks listener Accept
+ srv.listener.Close()
+ }
+ close(srv.quit)
+ srv.loopWG.Wait()
+
+ // No new peers can be added at this point because dialLoop and
+ // listenLoop are down. It is safe to call peerWG.Wait because
+ // peerWG.Add is not called outside of those loops.
+ for _, peer := range srv.peers {
+ peer.Disconnect(DiscQuitting)
+ }
+ srv.peerWG.Wait()
+}
+
+// main loop for adding connections via listening
+func (srv *Server) listenLoop() {
+ defer srv.loopWG.Done()
+ srvlog.Infoln("Listening on", srv.listener.Addr())
+ for {
+ conn, err := srv.listener.Accept()
+ if err != nil {
+ return
+ }
+ srvlog.Debugf("Accepted conn %v\n", conn.RemoteAddr())
+ srv.peerWG.Add(1)
+ go srv.startPeer(conn, nil)
+ }
+}
+
+func (srv *Server) dialLoop() {
+ defer srv.loopWG.Done()
+ refresh := time.NewTicker(refreshPeersInterval)
+ defer refresh.Stop()
+
+ srv.ntab.Bootstrap(srv.BootstrapNodes)
+ go srv.findPeers()
+
+ dialed := make(chan *discover.Node)
+ dialing := make(map[discover.NodeID]bool)
+
+ // TODO: limit number of active dials
+ // TODO: ensure only one findPeers goroutine is running
+ // TODO: pause findPeers when we're at capacity
+
+ for {
+ select {
+ case <-refresh.C:
+
+ go srv.findPeers()
+
+ case dest := <-srv.peerConnect:
+ // avoid dialing nodes that are already connected.
+ // there is another check for this in addPeer,
+ // which runs after the handshake.
+ srv.lock.Lock()
+ _, isconnected := srv.peers[dest.ID]
+ srv.lock.Unlock()
+ if isconnected || dialing[dest.ID] || dest.ID == srv.Self().ID {
+ continue
+ }
+
+ dialing[dest.ID] = true
+ srv.peerWG.Add(1)
+ go func() {
+ srv.dialNode(dest)
+ // at this point, the peer has been added
+ // or discarded. either way, we're not dialing it anymore.
+ dialed <- dest
+ }()
+
+ case dest := <-dialed:
+ delete(dialing, dest.ID)
+
+ case <-srv.quit:
+ // TODO: maybe wait for active dials
+ return
+ }
+ }
+}
+
+func (srv *Server) dialNode(dest *discover.Node) {
+ addr := &net.TCPAddr{IP: dest.IP, Port: dest.TCPPort}
+ srvlog.Debugf("Dialing %v\n", dest)
+ conn, err := srv.Dialer.Dial("tcp", addr.String())
+ if err != nil {
+ srvlog.DebugDetailf("dial error: %v", err)
+ return
+ }
+ srv.startPeer(conn, dest)
+}
+
+func (srv *Server) Self() *discover.Node {
+ return srv.ntab.Self()
+}
+
+func (srv *Server) findPeers() {
+ far := srv.Self().ID
+ for i := range far {
+ far[i] = ^far[i]
+ }
+ closeToSelf := srv.ntab.Lookup(srv.Self().ID)
+ farFromSelf := srv.ntab.Lookup(far)
+
+ for i := 0; i < len(closeToSelf) || i < len(farFromSelf); i++ {
+ if i < len(closeToSelf) {
+ srv.peerConnect <- closeToSelf[i]
+ }
+ if i < len(farFromSelf) {
+ srv.peerConnect <- farFromSelf[i]
+ }
+ }
+}
+
+func (srv *Server) startPeer(fd net.Conn, dest *discover.Node) {
+ // TODO: handle/store session token
+ fd.SetDeadline(time.Now().Add(handshakeTimeout))
+ conn, err := srv.setupFunc(fd, srv.PrivateKey, srv.ourHandshake, dest)
+ if err != nil {
+ fd.Close()
+ srvlog.Debugf("Handshake with %v failed: %v", fd.RemoteAddr(), err)
+ return
+ }
+
+ conn.MsgReadWriter = &netWrapper{
+ wrapped: conn.MsgReadWriter,
+ conn: fd, rtimeout: frameReadTimeout, wtimeout: frameWriteTimeout,
+ }
+ p := newPeer(fd, conn, srv.Protocols)
+ if ok, reason := srv.addPeer(conn.ID, p); !ok {
+ srvlog.DebugDetailf("Not adding %v (%v)\n", p, reason)
+ p.politeDisconnect(reason)
+ return
+ }
+
+ srvlog.Debugf("Added %v\n", p)
+ srvjslog.LogJson(&logger.P2PConnected{
+ RemoteId: fmt.Sprintf("%x", conn.ID[:]),
+ RemoteAddress: fd.RemoteAddr().String(),
+ RemoteVersionString: conn.Name,
+ NumConnections: srv.PeerCount(),
+ })
+
+ if srv.newPeerHook != nil {
+ srv.newPeerHook(p)
+ }
+ discreason := p.run()
+ srv.removePeer(p)
+
+ srvlog.Debugf("Removed %v (%v)\n", p, discreason)
+ srvjslog.LogJson(&logger.P2PDisconnected{
+ RemoteId: fmt.Sprintf("%x", conn.ID[:]),
+ NumConnections: srv.PeerCount(),
+ })
+}
+
+func (srv *Server) addPeer(id discover.NodeID, p *Peer) (bool, DiscReason) {
+ srv.lock.Lock()
+ defer srv.lock.Unlock()
+ switch {
+ case !srv.running:
+ return false, DiscQuitting
+ case len(srv.peers) >= srv.MaxPeers:
+ return false, DiscTooManyPeers
+ case srv.peers[id] != nil:
+ return false, DiscAlreadyConnected
+ case id == srv.Self().ID:
+ return false, DiscSelf
+ }
+ srv.peers[id] = p
+ return true, 0
+}
+
+func (srv *Server) removePeer(p *Peer) {
+ srv.lock.Lock()
+ delete(srv.peers, p.ID())
+ srv.lock.Unlock()
+ srv.peerWG.Done()
+}
diff --git a/p2p/server_test.go b/p2p/server_test.go
new file mode 100644
index 000000000..14e7c7de2
--- /dev/null
+++ b/p2p/server_test.go
@@ -0,0 +1,179 @@
+package p2p
+
+import (
+ "bytes"
+ "crypto/ecdsa"
+ "io"
+ "math/rand"
+ "net"
+ "sync"
+ "testing"
+ "time"
+
+ "github.com/ethereum/go-ethereum/crypto"
+ "github.com/ethereum/go-ethereum/crypto/sha3"
+ "github.com/ethereum/go-ethereum/p2p/discover"
+)
+
+func startTestServer(t *testing.T, pf newPeerHook) *Server {
+ server := &Server{
+ Name: "test",
+ MaxPeers: 10,
+ ListenAddr: "127.0.0.1:0",
+ PrivateKey: newkey(),
+ newPeerHook: pf,
+ setupFunc: func(fd net.Conn, prv *ecdsa.PrivateKey, our *protoHandshake, dial *discover.Node) (*conn, error) {
+ id := randomID()
+ rw := newRlpxFrameRW(fd, secrets{
+ MAC: zero16,
+ AES: zero16,
+ IngressMAC: sha3.NewKeccak256(),
+ EgressMAC: sha3.NewKeccak256(),
+ })
+ return &conn{
+ MsgReadWriter: rw,
+ protoHandshake: &protoHandshake{ID: id, Version: baseProtocolVersion},
+ }, nil
+ },
+ }
+ if err := server.Start(); err != nil {
+ t.Fatalf("Could not start server: %v", err)
+ }
+ return server
+}
+
+func TestServerListen(t *testing.T) {
+ defer testlog(t).detach()
+
+ // start the test server
+ connected := make(chan *Peer)
+ srv := startTestServer(t, func(p *Peer) {
+ if p == nil {
+ t.Error("peer func called with nil conn")
+ }
+ connected <- p
+ })
+ defer close(connected)
+ defer srv.Stop()
+
+ // dial the test server
+ conn, err := net.DialTimeout("tcp", srv.ListenAddr, 5*time.Second)
+ if err != nil {
+ t.Fatalf("could not dial: %v", err)
+ }
+ defer conn.Close()
+
+ select {
+ case peer := <-connected:
+ if peer.LocalAddr().String() != conn.RemoteAddr().String() {
+ t.Errorf("peer started with wrong conn: got %v, want %v",
+ peer.LocalAddr(), conn.RemoteAddr())
+ }
+ case <-time.After(1 * time.Second):
+ t.Error("server did not accept within one second")
+ }
+}
+
+func TestServerDial(t *testing.T) {
+ defer testlog(t).detach()
+
+ // run a one-shot TCP server to handle the connection.
+ listener, err := net.Listen("tcp", "127.0.0.1:0")
+ if err != nil {
+ t.Fatalf("could not setup listener: %v")
+ }
+ defer listener.Close()
+ accepted := make(chan net.Conn)
+ go func() {
+ conn, err := listener.Accept()
+ if err != nil {
+ t.Error("accept error:", err)
+ return
+ }
+ conn.Close()
+ accepted <- conn
+ }()
+
+ // start the server
+ connected := make(chan *Peer)
+ srv := startTestServer(t, func(p *Peer) { connected <- p })
+ defer close(connected)
+ defer srv.Stop()
+
+ // tell the server to connect
+ tcpAddr := listener.Addr().(*net.TCPAddr)
+ srv.SuggestPeer(&discover.Node{IP: tcpAddr.IP, TCPPort: tcpAddr.Port})
+
+ select {
+ case conn := <-accepted:
+ select {
+ case peer := <-connected:
+ if peer.RemoteAddr().String() != conn.LocalAddr().String() {
+ t.Errorf("peer started with wrong conn: got %v, want %v",
+ peer.RemoteAddr(), conn.LocalAddr())
+ }
+ // TODO: validate more fields
+ case <-time.After(1 * time.Second):
+ t.Error("server did not launch peer within one second")
+ }
+
+ case <-time.After(1 * time.Second):
+ t.Error("server did not connect within one second")
+ }
+}
+
+func TestServerBroadcast(t *testing.T) {
+ defer testlog(t).detach()
+
+ var connected sync.WaitGroup
+ srv := startTestServer(t, func(p *Peer) {
+ p.running = matchProtocols([]Protocol{discard}, []Cap{discard.cap()}, p.rw)
+ connected.Done()
+ })
+ defer srv.Stop()
+
+ // create a few peers
+ var conns = make([]net.Conn, 8)
+ connected.Add(len(conns))
+ deadline := time.Now().Add(3 * time.Second)
+ dialer := &net.Dialer{Deadline: deadline}
+ for i := range conns {
+ conn, err := dialer.Dial("tcp", srv.ListenAddr)
+ if err != nil {
+ t.Fatalf("conn %d: dial error: %v", i, err)
+ }
+ defer conn.Close()
+ conn.SetDeadline(deadline)
+ conns[i] = conn
+ }
+ connected.Wait()
+
+ // broadcast one message
+ srv.Broadcast("discard", 0, []string{"foo"})
+ golden := unhex("66e94d166f0a2c3b884cfa59ca34")
+
+ // check that the message has been written everywhere
+ for i, conn := range conns {
+ buf := make([]byte, len(golden))
+ if _, err := io.ReadFull(conn, buf); err != nil {
+ t.Errorf("conn %d: read error: %v", i, err)
+ } else if !bytes.Equal(buf, golden) {
+ t.Errorf("conn %d: msg mismatch\ngot: %x\nwant: %x", i, buf, golden)
+ }
+ }
+}
+
+func newkey() *ecdsa.PrivateKey {
+ key, err := crypto.GenerateKey()
+ if err != nil {
+ panic("couldn't generate key: " + err.Error())
+ }
+ return key
+}
+
+func randomID() (id discover.NodeID) {
+ for i := range id {
+ id[i] = byte(rand.Intn(255))
+ }
+ return id
+}
diff --git a/p2p/testlog_test.go b/p2p/testlog_test.go
new file mode 100644
index 000000000..ac973bcf5
--- /dev/null
+++ b/p2p/testlog_test.go
@@ -0,0 +1,25 @@
+package p2p
+
+import (
+ "testing"
+
+ "github.com/ethereum/go-ethereum/logger"
+)
+
+type testLogger struct{ t *testing.T }
+
+func testlog(t *testing.T) testLogger {
+ logger.Reset()
+ l := testLogger{t}
+ logger.AddLogSystem(l)
+ return l
+}
+
+func (l testLogger) LogPrint(msg logger.LogMsg) {
+ l.t.Logf("%s", msg.String())
+}
+
+func (testLogger) detach() {
+ logger.Flush()
+ logger.Reset()
+}
diff --git a/params/protocol_params.go b/params/protocol_params.go
new file mode 100755
index 000000000..d0bc2f4ad
--- /dev/null
+++ b/params/protocol_params.go
@@ -0,0 +1,54 @@
+// DO NOT EDIT!!!
+// AUTOGENERATED FROM generators/defaults.go
+
+package params
+
+import "math/big"
+
+var (
+ MaximumExtraDataSize = big.NewInt(1024) // Maximum size extra data may be after Genesis.
+ ExpByteGas = big.NewInt(10) // Times ceil(log256(exponent)) for the EXP instruction.
+ SloadGas = big.NewInt(50) // Multiplied by the number of 32-byte words that are copied (round up) for any *COPY operation and added.
+ CallValueTransferGas = big.NewInt(9000) // Paid for CALL when the value transfor is non-zero.
+ CallNewAccountGas = big.NewInt(25000) // Paid for CALL when the destination address didn't exist prior.
+ TxGas = big.NewInt(21000) // Per transaction. NOTE: Not payable on data of calls between transactions.
+ TxDataZeroGas = big.NewInt(4) // Per byte of data attached to a transaction that equals zero. NOTE: Not payable on data of calls between transactions.
+ GenesisGasLimit = big.NewInt(3141592) // Gas limit of the Genesis block.
+ DifficultyBoundDivisor = big.NewInt(2048) // The bound divisor of the difficulty, used in the update calculations.
+ QuadCoeffDiv = big.NewInt(512) // Divisor for the quadratic particle of the memory cost equation.
+ GenesisDifficulty = big.NewInt(131072) // Difficulty of the Genesis block.
+ DurationLimit = big.NewInt(8) // The decision boundary on the blocktime duration used to determine whether difficulty should go up or not.
+ SstoreSetGas = big.NewInt(20000) // Once per SLOAD operation.
+ LogDataGas = big.NewInt(8) // Per byte in a LOG* operation's data.
+ CallStipend = big.NewInt(2300) // Free gas given at beginning of call.
+ EcrecoverGas = big.NewInt(3000) //
+ Sha256WordGas = big.NewInt(12) //
+ MinGasLimit = big.NewInt(125000) // Minimum the gas limit may ever be.
+ Sha3Gas = big.NewInt(30) // Once per SHA3 operation.
+ Sha256Gas = big.NewInt(60) //
+ IdentityWordGas = big.NewInt(3) //
+ Sha3WordGas = big.NewInt(6) // Once per word of the SHA3 operation's data.
+ SstoreResetGas = big.NewInt(5000) // Once per SSTORE operation if the zeroness changes from zero.
+ SstoreClearGas = big.NewInt(5000) // Once per SSTORE operation if the zeroness doesn't change.
+ SstoreRefundGas = big.NewInt(15000) // Once per SSTORE operation if the zeroness changes to zero.
+ JumpdestGas = big.NewInt(1) // Refunded gas, once per SSTORE operation if the zeroness changes to zero.
+ IdentityGas = big.NewInt(15) //
+ GasLimitBoundDivisor = big.NewInt(1024) // The bound divisor of the gas limit, used in update calculations.
+ EpochDuration = big.NewInt(30000) // Duration between proof-of-work epochs.
+ CallGas = big.NewInt(40) // Once per CALL operation & message call transaction.
+ CreateDataGas = big.NewInt(200) //
+ Ripemd160Gas = big.NewInt(600) //
+ Ripemd160WordGas = big.NewInt(120) //
+ MinimumDifficulty = big.NewInt(131072) // The minimum that the difficulty may ever be.
+ CallCreateDepth = big.NewInt(1024) // Maximum depth of call/create stack.
+ ExpGas = big.NewInt(10) // Once per EXP instuction.
+ LogGas = big.NewInt(375) // Per LOG* operation.
+ CopyGas = big.NewInt(3) //
+ StackLimit = big.NewInt(1024) // Maximum size of VM stack allowed.
+ TierStepGas = big.NewInt(0) // Once per operation, for a selection of them.
+ LogTopicGas = big.NewInt(375) // Multiplied by the * of the LOG*, per LOG transaction. e.g. LOG0 incurs 0 * c_txLogTopicGas, LOG4 incurs 4 * c_txLogTopicGas.
+ CreateGas = big.NewInt(32000) // Once per CREATE operation & contract-creation transaction.
+ SuicideRefundGas = big.NewInt(24000) // Refunded following a suicide operation.
+ MemoryGas = big.NewInt(3) // Times the address of the (highest referenced byte in memory + 1). NOTE: referencing happens on read, write and in instructions such as RETURN and CALL.
+ TxDataNonZeroGas = big.NewInt(68) // Per byte of data attached to a transaction that is not equal to zero. NOTE: Not payable on data of calls between transactions.
+)
diff --git a/pow/block.go b/pow/block.go
new file mode 100644
index 000000000..9ae25bd4d
--- /dev/null
+++ b/pow/block.go
@@ -0,0 +1,21 @@
+package pow
+
+import (
+ "math/big"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/core/types"
+)
+
+type Block interface {
+ Difficulty() *big.Int
+ HashNoNonce() common.Hash
+ Nonce() uint64
+ MixDigest() common.Hash
+ NumberU64() uint64
+}
+
+type ChainManager interface {
+ GetBlockByNumber(uint64) *types.Block
+ CurrentBlock() *types.Block
+}
diff --git a/pow/dagger/dagger.go b/pow/dagger/dagger.go
new file mode 100644
index 000000000..f2d65e8ef
--- /dev/null
+++ b/pow/dagger/dagger.go
@@ -0,0 +1,160 @@
+package dagger
+
+import (
+ "hash"
+ "math/big"
+ "math/rand"
+ "time"
+
+ "github.com/ethereum/go-ethereum/crypto/sha3"
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/logger"
+)
+
+var powlogger = logger.NewLogger("POW")
+
+type Dagger struct {
+ hash *big.Int
+ xn *big.Int
+}
+
+var Found bool
+
+func (dag *Dagger) Find(obj *big.Int, resChan chan int64) {
+ r := rand.New(rand.NewSource(time.Now().UnixNano()))
+
+ for i := 0; i < 1000; i++ {
+ rnd := r.Int63()
+
+ res := dag.Eval(big.NewInt(rnd))
+ powlogger.Infof("rnd %v\nres %v\nobj %v\n", rnd, res, obj)
+ if res.Cmp(obj) < 0 {
+ // Post back result on the channel
+ resChan <- rnd
+ // Notify other threads we've found a valid nonce
+ Found = true
+ }
+
+ // Break out if found
+ if Found {
+ break
+ }
+ }
+
+ resChan <- 0
+}
+
+func (dag *Dagger) Search(hash, diff *big.Int) ([]byte, []byte, []byte) {
+ // TODO fix multi threading. Somehow it results in the wrong nonce
+ amountOfRoutines := 1
+
+ dag.hash = hash
+
+ obj := common.BigPow(2, 256)
+ obj = obj.Div(obj, diff)
+
+ Found = false
+ resChan := make(chan int64, 3)
+ var res int64
+
+ for k := 0; k < amountOfRoutines; k++ {
+ go dag.Find(obj, resChan)
+
+ // Wait for each go routine to finish
+ }
+ for k := 0; k < amountOfRoutines; k++ {
+ // Get the result from the channel. 0 = quit
+ if r := <-resChan; r != 0 {
+ res = r
+ }
+ }
+
+ return big.NewInt(res).Bytes(), nil, nil
+}
+
+func (dag *Dagger) Verify(hash, diff, nonce *big.Int) bool {
+ dag.hash = hash
+
+ obj := common.BigPow(2, 256)
+ obj = obj.Div(obj, diff)
+
+ return dag.Eval(nonce).Cmp(obj) < 0
+}
+
+func DaggerVerify(hash, diff, nonce *big.Int) bool {
+ dagger := &Dagger{}
+ dagger.hash = hash
+
+ obj := common.BigPow(2, 256)
+ obj = obj.Div(obj, diff)
+
+ return dagger.Eval(nonce).Cmp(obj) < 0
+}
+
+func (dag *Dagger) Node(L uint64, i uint64) *big.Int {
+ if L == i {
+ return dag.hash
+ }
+
+ var m *big.Int
+ if L == 9 {
+ m = big.NewInt(16)
+ } else {
+ m = big.NewInt(3)
+ }
+
+ sha := sha3.NewKeccak256()
+ sha.Reset()
+ d := sha3.NewKeccak256()
+ b := new(big.Int)
+ ret := new(big.Int)
+
+ for k := 0; k < int(m.Uint64()); k++ {
+ d.Reset()
+ d.Write(dag.hash.Bytes())
+ d.Write(dag.xn.Bytes())
+ d.Write(big.NewInt(int64(L)).Bytes())
+ d.Write(big.NewInt(int64(i)).Bytes())
+ d.Write(big.NewInt(int64(k)).Bytes())
+
+ b.SetBytes(Sum(d))
+ pk := b.Uint64() & ((1 << ((L - 1) * 3)) - 1)
+ sha.Write(dag.Node(L-1, pk).Bytes())
+ }
+
+ ret.SetBytes(Sum(sha))
+
+ return ret
+}
+
+func Sum(sha hash.Hash) []byte {
+ //in := make([]byte, 32)
+ return sha.Sum(nil)
+}
+
+func (dag *Dagger) Eval(N *big.Int) *big.Int {
+ pow := common.BigPow(2, 26)
+ dag.xn = pow.Div(N, pow)
+
+ sha := sha3.NewKeccak256()
+ sha.Reset()
+ ret := new(big.Int)
+
+ for k := 0; k < 4; k++ {
+ d := sha3.NewKeccak256()
+ b := new(big.Int)
+
+ d.Reset()
+ d.Write(dag.hash.Bytes())
+ d.Write(dag.xn.Bytes())
+ d.Write(N.Bytes())
+ d.Write(big.NewInt(int64(k)).Bytes())
+
+ b.SetBytes(Sum(d))
+ pk := (b.Uint64() & 0x1ffffff)
+
+ sha.Write(dag.Node(9, pk).Bytes())
+ }
+
+ return ret.SetBytes(Sum(sha))
+}
diff --git a/pow/dagger/dagger_test.go b/pow/dagger/dagger_test.go
new file mode 100644
index 000000000..f53f4bac9
--- /dev/null
+++ b/pow/dagger/dagger_test.go
@@ -0,0 +1,19 @@
+package dagger
+
+import (
+ "math/big"
+ "testing"
+
+ "github.com/ethereum/go-ethereum/common"
+)
+
+func BenchmarkDaggerSearch(b *testing.B) {
+ hash := big.NewInt(0)
+ diff := common.BigPow(2, 36)
+ o := big.NewInt(0) // nonce doesn't matter. We're only testing against speed, not validity
+
+ // Reset timer so the big generation isn't included in the benchmark
+ b.ResetTimer()
+ // Validate
+ DaggerVerify(hash, diff, o)
+}
diff --git a/pow/ezp/pow.go b/pow/ezp/pow.go
new file mode 100644
index 000000000..bd2927fe8
--- /dev/null
+++ b/pow/ezp/pow.go
@@ -0,0 +1,99 @@
+package ezp
+
+import (
+ "encoding/binary"
+ "math/big"
+ "math/rand"
+ "time"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/crypto/sha3"
+ "github.com/ethereum/go-ethereum/logger"
+ "github.com/ethereum/go-ethereum/pow"
+)
+
+var powlogger = logger.NewLogger("POW")
+
+type EasyPow struct {
+ hash *big.Int
+ HashRate int64
+ turbo bool
+}
+
+func New() *EasyPow {
+ return &EasyPow{turbo: false}
+}
+
+func (pow *EasyPow) GetHashrate() int64 {
+ return pow.HashRate
+}
+
+func (pow *EasyPow) Turbo(on bool) {
+ pow.turbo = on
+}
+
+func (pow *EasyPow) Search(block pow.Block, stop <-chan struct{}) (uint64, []byte, []byte) {
+ r := rand.New(rand.NewSource(time.Now().UnixNano()))
+ hash := block.HashNoNonce()
+ diff := block.Difficulty()
+ //i := int64(0)
+ // TODO fix offset
+ i := rand.Int63()
+ starti := i
+ start := time.Now().UnixNano()
+
+ defer func() { pow.HashRate = 0 }()
+
+ // Make sure stop is empty
+empty:
+ for {
+ select {
+ case <-stop:
+ default:
+ break empty
+ }
+ }
+
+ for {
+ select {
+ case <-stop:
+ return 0, nil, nil
+ default:
+ i++
+
+ elapsed := time.Now().UnixNano() - start
+ hashes := ((float64(1e9) / float64(elapsed)) * float64(i-starti)) / 1000
+ pow.HashRate = int64(hashes)
+
+ sha := uint64(r.Int63())
+ if verify(hash, diff, sha) {
+ return sha, nil, nil
+ }
+ }
+
+ if !pow.turbo {
+ time.Sleep(20 * time.Microsecond)
+ }
+ }
+
+ return 0, nil, nil
+}
+
+func (pow *EasyPow) Verify(block pow.Block) bool {
+ return Verify(block)
+}
+
+func verify(hash common.Hash, diff *big.Int, nonce uint64) bool {
+ sha := sha3.NewKeccak256()
+ n := make([]byte, 8)
+ binary.PutUvarint(n, nonce)
+ sha.Write(n)
+ sha.Write(hash[:])
+ verification := new(big.Int).Div(common.BigPow(2, 256), diff)
+ res := common.BigD(sha.Sum(nil))
+ return res.Cmp(verification) <= 0
+}
+
+func Verify(block pow.Block) bool {
+ return verify(block.HashNoNonce(), block.Difficulty(), block.Nonce())
+}
diff --git a/pow/pow.go b/pow/pow.go
new file mode 100644
index 000000000..3908e5f76
--- /dev/null
+++ b/pow/pow.go
@@ -0,0 +1,8 @@
+package pow
+
+type PoW interface {
+ Search(block Block, stop <-chan struct{}) (uint64, []byte, []byte)
+ Verify(block Block) bool
+ GetHashrate() int64
+ Turbo(bool)
+}
diff --git a/rlp/decode.go b/rlp/decode.go
new file mode 100644
index 000000000..0fde0a947
--- /dev/null
+++ b/rlp/decode.go
@@ -0,0 +1,798 @@
+package rlp
+
+import (
+ "bufio"
+ "bytes"
+ "encoding/binary"
+ "errors"
+ "fmt"
+ "io"
+ "math/big"
+ "reflect"
+)
+
+var (
+ errNoPointer = errors.New("rlp: interface given to Decode must be a pointer")
+ errDecodeIntoNil = errors.New("rlp: pointer given to Decode must not be nil")
+)
+
+// Decoder is implemented by types that require custom RLP
+// decoding rules or need to decode into private fields.
+//
+// The DecodeRLP method should read one value from the given
+// Stream. It is not forbidden to read less or more, but it might
+// be confusing.
+type Decoder interface {
+ DecodeRLP(*Stream) error
+}
+
+// Decode parses RLP-encoded data from r and stores the result in the
+// value pointed to by val. Val must be a non-nil pointer. If r does
+// not implement ByteReader, Decode will do its own buffering.
+//
+// Decode uses the following type-dependent decoding rules:
+//
+// If the type implements the Decoder interface, decode calls
+// DecodeRLP.
+//
+// To decode into a pointer, Decode will set the pointer to nil if the
+// input has size zero or the input is a single byte with value zero.
+// If the input has nonzero size, Decode will allocate a new value of
+// the type being pointed to.
+//
+// To decode into a struct, Decode expects the input to be an RLP
+// list. The decoded elements of the list are assigned to each public
+// field in the order given by the struct's definition. If the input
+// list has too few elements, no error is returned and the remaining
+// fields will have the zero value.
+// Recursive struct types are supported.
+//
+// To decode into a slice, the input must be a list and the resulting
+// slice will contain the input elements in order.
+// As a special case, if the slice has a byte-size element type, the input
+// can also be an RLP string.
+//
+// To decode into a Go string, the input must be an RLP string. The
+// bytes are taken as-is and will not necessarily be valid UTF-8.
+//
+// To decode into an unsigned integer type, the input must also be an RLP
+// string. The bytes are interpreted as a big endian representation of
+// the integer. If the RLP string is larger than the bit size of the
+// type, Decode will return an error. Decode also supports *big.Int.
+// There is no size limit for big integers.
+//
+// To decode into an interface value, Decode stores one of these
+// in the value:
+//
+// []interface{}, for RLP lists
+// []byte, for RLP strings
+//
+// Non-empty interface types are not supported, nor are booleans,
+// signed integers, floating point numbers, maps, channels and
+// functions.
+func Decode(r io.Reader, val interface{}) error {
+ return NewStream(r).Decode(val)
+}
+
+// DecodeBytes parses RLP data from b into val.
+// Please see the documentation of Decode for the decoding rules.
+func DecodeBytes(b []byte, val interface{}) error {
+ return NewStream(bytes.NewReader(b)).Decode(val)
+}
+
+type decodeError struct {
+ msg string
+ typ reflect.Type
+ ctx []string
+}
+
+func (err *decodeError) Error() string {
+ ctx := ""
+ if len(err.ctx) > 0 {
+ ctx = ", decoding into "
+ for i := len(err.ctx) - 1; i >= 0; i-- {
+ ctx += err.ctx[i]
+ }
+ }
+ return fmt.Sprintf("rlp: %s for %v%s", err.msg, err.typ, ctx)
+}
+
+func wrapStreamError(err error, typ reflect.Type) error {
+ switch err {
+ case ErrExpectedList:
+ return &decodeError{msg: "expected input list", typ: typ}
+ case ErrExpectedString:
+ return &decodeError{msg: "expected input string or byte", typ: typ}
+ case errUintOverflow:
+ return &decodeError{msg: "input string too long", typ: typ}
+ case errNotAtEOL:
+ return &decodeError{msg: "input list has too many elements", typ: typ}
+ }
+ return err
+}
+
+func addErrorContext(err error, ctx string) error {
+ if decErr, ok := err.(*decodeError); ok {
+ decErr.ctx = append(decErr.ctx, ctx)
+ }
+ return err
+}
+
+var (
+ decoderInterface = reflect.TypeOf(new(Decoder)).Elem()
+ bigInt = reflect.TypeOf(big.Int{})
+)
+
+func makeDecoder(typ reflect.Type) (dec decoder, err error) {
+ kind := typ.Kind()
+ switch {
+ case typ.Implements(decoderInterface):
+ return decodeDecoder, nil
+ case kind != reflect.Ptr && reflect.PtrTo(typ).Implements(decoderInterface):
+ return decodeDecoderNoPtr, nil
+ case typ.AssignableTo(reflect.PtrTo(bigInt)):
+ return decodeBigInt, nil
+ case typ.AssignableTo(bigInt):
+ return decodeBigIntNoPtr, nil
+ case isUint(kind):
+ return decodeUint, nil
+ case kind == reflect.String:
+ return decodeString, nil
+ case kind == reflect.Slice || kind == reflect.Array:
+ return makeListDecoder(typ)
+ case kind == reflect.Struct:
+ return makeStructDecoder(typ)
+ case kind == reflect.Ptr:
+ return makePtrDecoder(typ)
+ case kind == reflect.Interface:
+ return decodeInterface, nil
+ default:
+ return nil, fmt.Errorf("rlp: type %v is not RLP-serializable", typ)
+ }
+}
+
+func decodeUint(s *Stream, val reflect.Value) error {
+ typ := val.Type()
+ num, err := s.uint(typ.Bits())
+ if err != nil {
+ return wrapStreamError(err, val.Type())
+ }
+ val.SetUint(num)
+ return nil
+}
+
+func decodeString(s *Stream, val reflect.Value) error {
+ b, err := s.Bytes()
+ if err != nil {
+ return wrapStreamError(err, val.Type())
+ }
+ val.SetString(string(b))
+ return nil
+}
+
+func decodeBigIntNoPtr(s *Stream, val reflect.Value) error {
+ return decodeBigInt(s, val.Addr())
+}
+
+func decodeBigInt(s *Stream, val reflect.Value) error {
+ b, err := s.Bytes()
+ if err != nil {
+ return wrapStreamError(err, val.Type())
+ }
+ i := val.Interface().(*big.Int)
+ if i == nil {
+ i = new(big.Int)
+ val.Set(reflect.ValueOf(i))
+ }
+ i.SetBytes(b)
+ return nil
+}
+
+func makeListDecoder(typ reflect.Type) (decoder, error) {
+ etype := typ.Elem()
+ if etype.Kind() == reflect.Uint8 && !reflect.PtrTo(etype).Implements(decoderInterface) {
+ if typ.Kind() == reflect.Array {
+ return decodeByteArray, nil
+ } else {
+ return decodeByteSlice, nil
+ }
+ }
+ etypeinfo, err := cachedTypeInfo1(etype)
+ if err != nil {
+ return nil, err
+ }
+
+ isArray := typ.Kind() == reflect.Array
+ return func(s *Stream, val reflect.Value) error {
+ if isArray {
+ return decodeListArray(s, val, etypeinfo.decoder)
+ } else {
+ return decodeListSlice(s, val, etypeinfo.decoder)
+ }
+ }, nil
+}
+
+func decodeListSlice(s *Stream, val reflect.Value, elemdec decoder) error {
+ size, err := s.List()
+ if err != nil {
+ return wrapStreamError(err, val.Type())
+ }
+ if size == 0 {
+ val.Set(reflect.MakeSlice(val.Type(), 0, 0))
+ return s.ListEnd()
+ }
+
+ i := 0
+ for ; ; i++ {
+ // grow slice if necessary
+ if i >= val.Cap() {
+ newcap := val.Cap() + val.Cap()/2
+ if newcap < 4 {
+ newcap = 4
+ }
+ newv := reflect.MakeSlice(val.Type(), val.Len(), newcap)
+ reflect.Copy(newv, val)
+ val.Set(newv)
+ }
+ if i >= val.Len() {
+ val.SetLen(i + 1)
+ }
+ // decode into element
+ if err := elemdec(s, val.Index(i)); err == EOL {
+ break
+ } else if err != nil {
+ return addErrorContext(err, fmt.Sprint("[", i, "]"))
+ }
+ }
+ if i < val.Len() {
+ val.SetLen(i)
+ }
+ return s.ListEnd()
+}
+
+func decodeListArray(s *Stream, val reflect.Value, elemdec decoder) error {
+ size, err := s.List()
+ if err != nil {
+ return err
+ }
+ if size == 0 {
+ zero(val, 0)
+ return s.ListEnd()
+ }
+
+ // The approach here is stolen from package json, although we differ
+ // in the semantics for arrays. package json discards remaining
+ // elements that would not fit into the array. We generate an error in
+ // this case because we'd be losing information.
+ vlen := val.Len()
+ i := 0
+ for ; i < vlen; i++ {
+ if err := elemdec(s, val.Index(i)); err == EOL {
+ break
+ } else if err != nil {
+ return addErrorContext(err, fmt.Sprint("[", i, "]"))
+ }
+ }
+ if i < vlen {
+ zero(val, i)
+ }
+ return wrapStreamError(s.ListEnd(), val.Type())
+}
+
+func decodeByteSlice(s *Stream, val reflect.Value) error {
+ kind, _, err := s.Kind()
+ if err != nil {
+ return err
+ }
+ if kind == List {
+ return decodeListSlice(s, val, decodeUint)
+ }
+ b, err := s.Bytes()
+ if err == nil {
+ val.SetBytes(b)
+ }
+ return err
+}
+
+func decodeByteArray(s *Stream, val reflect.Value) error {
+ kind, size, err := s.Kind()
+ if err != nil {
+ return err
+ }
+ switch kind {
+ case Byte:
+ if val.Len() == 0 {
+ return &decodeError{msg: "input string too long", typ: val.Type()}
+ }
+ bv, _ := s.Uint()
+ val.Index(0).SetUint(bv)
+ zero(val, 1)
+ case String:
+ if uint64(val.Len()) < size {
+ return &decodeError{msg: "input string too long", typ: val.Type()}
+ }
+ slice := val.Slice(0, int(size)).Interface().([]byte)
+ if err := s.readFull(slice); err != nil {
+ return err
+ }
+ zero(val, int(size))
+ case List:
+ return decodeListArray(s, val, decodeUint)
+ }
+ return nil
+}
+
+func zero(val reflect.Value, start int) {
+ z := reflect.Zero(val.Type().Elem())
+ end := val.Len()
+ for i := start; i < end; i++ {
+ val.Index(i).Set(z)
+ }
+}
+
+type field struct {
+ index int
+ info *typeinfo
+}
+
+func makeStructDecoder(typ reflect.Type) (decoder, error) {
+ fields, err := structFields(typ)
+ if err != nil {
+ return nil, err
+ }
+ dec := func(s *Stream, val reflect.Value) (err error) {
+ if _, err = s.List(); err != nil {
+ return wrapStreamError(err, typ)
+ }
+ for _, f := range fields {
+ err = f.info.decoder(s, val.Field(f.index))
+ if err == EOL {
+ // too few elements. leave the rest at their zero value.
+ break
+ } else if err != nil {
+ return addErrorContext(err, "."+typ.Field(f.index).Name)
+ }
+ }
+ return wrapStreamError(s.ListEnd(), typ)
+ }
+ return dec, nil
+}
+
+func makePtrDecoder(typ reflect.Type) (decoder, error) {
+ etype := typ.Elem()
+ etypeinfo, err := cachedTypeInfo1(etype)
+ if err != nil {
+ return nil, err
+ }
+ dec := func(s *Stream, val reflect.Value) (err error) {
+ _, size, err := s.Kind()
+ if err != nil || size == 0 && s.byteval == 0 {
+ // rearm s.Kind. This is important because the input
+ // position must advance to the next value even though
+ // we don't read anything.
+ s.kind = -1
+ // set the pointer to nil.
+ val.Set(reflect.Zero(typ))
+ return err
+ }
+ newval := val
+ if val.IsNil() {
+ newval = reflect.New(etype)
+ }
+ if err = etypeinfo.decoder(s, newval.Elem()); err == nil {
+ val.Set(newval)
+ }
+ return err
+ }
+ return dec, nil
+}
+
+var ifsliceType = reflect.TypeOf([]interface{}{})
+
+func decodeInterface(s *Stream, val reflect.Value) error {
+ if val.Type().NumMethod() != 0 {
+ return fmt.Errorf("rlp: type %v is not RLP-serializable", val.Type())
+ }
+ kind, _, err := s.Kind()
+ if err != nil {
+ return err
+ }
+ if kind == List {
+ slice := reflect.New(ifsliceType).Elem()
+ if err := decodeListSlice(s, slice, decodeInterface); err != nil {
+ return err
+ }
+ val.Set(slice)
+ } else {
+ b, err := s.Bytes()
+ if err != nil {
+ return err
+ }
+ val.Set(reflect.ValueOf(b))
+ }
+ return nil
+}
+
+// This decoder is used for non-pointer values of types
+// that implement the Decoder interface using a pointer receiver.
+func decodeDecoderNoPtr(s *Stream, val reflect.Value) error {
+ return val.Addr().Interface().(Decoder).DecodeRLP(s)
+}
+
+func decodeDecoder(s *Stream, val reflect.Value) error {
+ // Decoder instances are not handled using the pointer rule if the type
+ // implements Decoder with pointer receiver (i.e. always)
+ // because it might handle empty values specially.
+ // We need to allocate one here in this case, like makePtrDecoder does.
+ if val.Kind() == reflect.Ptr && val.IsNil() {
+ val.Set(reflect.New(val.Type().Elem()))
+ }
+ return val.Interface().(Decoder).DecodeRLP(s)
+}
+
+// Kind represents the kind of value contained in an RLP stream.
+type Kind int
+
+const (
+ Byte Kind = iota
+ String
+ List
+)
+
+func (k Kind) String() string {
+ switch k {
+ case Byte:
+ return "Byte"
+ case String:
+ return "String"
+ case List:
+ return "List"
+ default:
+ return fmt.Sprintf("Unknown(%d)", k)
+ }
+}
+
+var (
+ // EOL is returned when the end of the current list
+ // has been reached during streaming.
+ EOL = errors.New("rlp: end of list")
+
+ // Other errors
+ ErrExpectedString = errors.New("rlp: expected String or Byte")
+ ErrExpectedList = errors.New("rlp: expected List")
+ ErrElemTooLarge = errors.New("rlp: element is larger than containing list")
+
+ // internal errors
+ errNotInList = errors.New("rlp: call of ListEnd outside of any list")
+ errNotAtEOL = errors.New("rlp: call of ListEnd not positioned at EOL")
+)
+
+// ByteReader must be implemented by any input reader for a Stream. It
+// is implemented by e.g. bufio.Reader and bytes.Reader.
+type ByteReader interface {
+ io.Reader
+ io.ByteReader
+}
+
+// Stream can be used for piecemeal decoding of an input stream. This
+// is useful if the input is very large or if the decoding rules for a
+// type depend on the input structure. Stream does not keep an
+// internal buffer. After decoding a value, the input reader will be
+// positioned just before the type information for the next value.
+//
+// When decoding a list and the input position reaches the declared
+// length of the list, all operations will return error EOL.
+// The end of the list must be acknowledged using ListEnd to continue
+// reading the enclosing list.
+//
+// Stream is not safe for concurrent use.
+type Stream struct {
+ r ByteReader
+ uintbuf []byte
+
+ kind Kind // kind of value ahead
+ size uint64 // size of value ahead
+ byteval byte // value of single byte in type tag
+ stack []listpos
+}
+
+type listpos struct{ pos, size uint64 }
+
+// NewStream creates a new stream reading from r.
+// If r does not implement ByteReader, the Stream will
+// introduce its own buffering.
+func NewStream(r io.Reader) *Stream {
+ s := new(Stream)
+ s.Reset(r)
+ return s
+}
+
+// NewListStream creates a new stream that pretends to be positioned
+// at an encoded list of the given length.
+func NewListStream(r io.Reader, len uint64) *Stream {
+ s := new(Stream)
+ s.Reset(r)
+ s.kind = List
+ s.size = len
+ return s
+}
+
+// Bytes reads an RLP string and returns its contents as a byte slice.
+// If the input does not contain an RLP string, the returned
+// error will be ErrExpectedString.
+func (s *Stream) Bytes() ([]byte, error) {
+ kind, size, err := s.Kind()
+ if err != nil {
+ return nil, err
+ }
+ switch kind {
+ case Byte:
+ s.kind = -1 // rearm Kind
+ return []byte{s.byteval}, nil
+ case String:
+ b := make([]byte, size)
+ if err = s.readFull(b); err != nil {
+ return nil, err
+ }
+ return b, nil
+ default:
+ return nil, ErrExpectedString
+ }
+}
+
+// Raw reads a raw encoded value including RLP type information.
+func (s *Stream) Raw() ([]byte, error) {
+ kind, size, err := s.Kind()
+ if err != nil {
+ return nil, err
+ }
+ if kind == Byte {
+ s.kind = -1 // rearm Kind
+ return []byte{s.byteval}, nil
+ }
+ // the original header has already been read and is no longer
+ // available. read content and put a new header in front of it.
+ start := headsize(size)
+ buf := make([]byte, uint64(start)+size)
+ if err := s.readFull(buf[start:]); err != nil {
+ return nil, err
+ }
+ if kind == String {
+ puthead(buf, 0x80, 0xB8, size)
+ } else {
+ puthead(buf, 0xC0, 0xF7, size)
+ }
+ return buf, nil
+}
+
+var errUintOverflow = errors.New("rlp: uint overflow")
+
+// Uint reads an RLP string of up to 8 bytes and returns its contents
+// as an unsigned integer. If the input does not contain an RLP string, the
+// returned error will be ErrExpectedString.
+func (s *Stream) Uint() (uint64, error) {
+ return s.uint(64)
+}
+
+func (s *Stream) uint(maxbits int) (uint64, error) {
+ kind, size, err := s.Kind()
+ if err != nil {
+ return 0, err
+ }
+ switch kind {
+ case Byte:
+ s.kind = -1 // rearm Kind
+ return uint64(s.byteval), nil
+ case String:
+ if size > uint64(maxbits/8) {
+ return 0, errUintOverflow
+ }
+ return s.readUint(byte(size))
+ default:
+ return 0, ErrExpectedString
+ }
+}
+
+// List starts decoding an RLP list. If the input does not contain a
+// list, the returned error will be ErrExpectedList. When the list's
+// end has been reached, any Stream operation will return EOL.
+func (s *Stream) List() (size uint64, err error) {
+ kind, size, err := s.Kind()
+ if err != nil {
+ return 0, err
+ }
+ if kind != List {
+ return 0, ErrExpectedList
+ }
+ s.stack = append(s.stack, listpos{0, size})
+ s.kind = -1
+ s.size = 0
+ return size, nil
+}
+
+// ListEnd returns to the enclosing list.
+// The input reader must be positioned at the end of a list.
+func (s *Stream) ListEnd() error {
+ if len(s.stack) == 0 {
+ return errNotInList
+ }
+ tos := s.stack[len(s.stack)-1]
+ if tos.pos != tos.size {
+ return errNotAtEOL
+ }
+ s.stack = s.stack[:len(s.stack)-1] // pop
+ if len(s.stack) > 0 {
+ s.stack[len(s.stack)-1].pos += tos.size
+ }
+ s.kind = -1
+ s.size = 0
+ return nil
+}
+
+// Decode decodes a value and stores the result in the value pointed
+// to by val. Please see the documentation for the Decode function
+// to learn about the decoding rules.
+func (s *Stream) Decode(val interface{}) error {
+ if val == nil {
+ return errDecodeIntoNil
+ }
+ rval := reflect.ValueOf(val)
+ rtyp := rval.Type()
+ if rtyp.Kind() != reflect.Ptr {
+ return errNoPointer
+ }
+ if rval.IsNil() {
+ return errDecodeIntoNil
+ }
+ info, err := cachedTypeInfo(rtyp.Elem())
+ if err != nil {
+ return err
+ }
+
+ err = info.decoder(s, rval.Elem())
+ if decErr, ok := err.(*decodeError); ok && len(decErr.ctx) > 0 {
+ // add decode target type to error so context has more meaning
+ decErr.ctx = append(decErr.ctx, fmt.Sprint("(", rtyp.Elem(), ")"))
+ }
+ return err
+}
+
+// Reset discards any information about the current decoding context
+// and starts reading from r. If r does not also implement ByteReader,
+// Stream will do its own buffering.
+func (s *Stream) Reset(r io.Reader) {
+ bufr, ok := r.(ByteReader)
+ if !ok {
+ bufr = bufio.NewReader(r)
+ }
+ s.r = bufr
+ s.stack = s.stack[:0]
+ s.size = 0
+ s.kind = -1
+ if s.uintbuf == nil {
+ s.uintbuf = make([]byte, 8)
+ }
+}
+
+// Kind returns the kind and size of the next value in the
+// input stream.
+//
+// The returned size is the number of bytes that make up the value.
+// For kind == Byte, the size is zero because the value is
+// contained in the type tag.
+//
+// The first call to Kind will read size information from the input
+// reader and leave it positioned at the start of the actual bytes of
+// the value. Subsequent calls to Kind (until the value is decoded)
+// will not advance the input reader and return cached information.
+func (s *Stream) Kind() (kind Kind, size uint64, err error) {
+ var tos *listpos
+ if len(s.stack) > 0 {
+ tos = &s.stack[len(s.stack)-1]
+ }
+ if s.kind < 0 {
+ if tos != nil && tos.pos == tos.size {
+ return 0, 0, EOL
+ }
+ kind, size, err = s.readKind()
+ if err != nil {
+ return 0, 0, err
+ }
+ s.kind, s.size = kind, size
+ }
+ if tos != nil && tos.pos+s.size > tos.size {
+ return 0, 0, ErrElemTooLarge
+ }
+ return s.kind, s.size, nil
+}
+
+func (s *Stream) readKind() (kind Kind, size uint64, err error) {
+ b, err := s.readByte()
+ if err != nil {
+ return 0, 0, err
+ }
+ s.byteval = 0
+ switch {
+ case b < 0x80:
+ // For a single byte whose value is in the [0x00, 0x7F] range, that byte
+ // is its own RLP encoding.
+ s.byteval = b
+ return Byte, 0, nil
+ case b < 0xB8:
+ // Otherwise, if a string is 0-55 bytes long,
+ // the RLP encoding consists of a single byte with value 0x80 plus the
+ // length of the string followed by the string. The range of the first
+ // byte is thus [0x80, 0xB7].
+ return String, uint64(b - 0x80), nil
+ case b < 0xC0:
+ // If a string is more than 55 bytes long, the
+ // RLP encoding consists of a single byte with value 0xB7 plus the length
+ // of the length of the string in binary form, followed by the length of
+ // the string, followed by the string. For example, a length-1024 string
+ // would be encoded as 0xB90400 followed by the string. The range of
+ // the first byte is thus [0xB8, 0xBF].
+ size, err = s.readUint(b - 0xB7)
+ return String, size, err
+ case b < 0xF8:
+ // If the total payload of a list
+ // (i.e. the combined length of all its items) is 0-55 bytes long, the
+ // RLP encoding consists of a single byte with value 0xC0 plus the length
+ // of the list followed by the concatenation of the RLP encodings of the
+ // items. The range of the first byte is thus [0xC0, 0xF7].
+ return List, uint64(b - 0xC0), nil
+ default:
+ // If the total payload of a list is more than 55 bytes long,
+ // the RLP encoding consists of a single byte with value 0xF7
+ // plus the length of the length of the payload in binary
+ // form, followed by the length of the payload, followed by
+ // the concatenation of the RLP encodings of the items. The
+ // range of the first byte is thus [0xF8, 0xFF].
+ size, err = s.readUint(b - 0xF7)
+ return List, size, err
+ }
+}
+
+func (s *Stream) readUint(size byte) (uint64, error) {
+ if size == 1 {
+ b, err := s.readByte()
+ if err == io.EOF {
+ err = io.ErrUnexpectedEOF
+ }
+ return uint64(b), err
+ }
+ start := int(8 - size)
+ for i := 0; i < start; i++ {
+ s.uintbuf[i] = 0
+ }
+ err := s.readFull(s.uintbuf[start:])
+ return binary.BigEndian.Uint64(s.uintbuf), err
+}
+
+func (s *Stream) readFull(buf []byte) (err error) {
+ s.willRead(uint64(len(buf)))
+ var nn, n int
+ for n < len(buf) && err == nil {
+ nn, err = s.r.Read(buf[n:])
+ n += nn
+ }
+ if err == io.EOF {
+ err = io.ErrUnexpectedEOF
+ }
+ return err
+}
+
+func (s *Stream) readByte() (byte, error) {
+ s.willRead(1)
+ b, err := s.r.ReadByte()
+ if len(s.stack) > 0 && err == io.EOF {
+ err = io.ErrUnexpectedEOF
+ }
+ return b, err
+}
+
+func (s *Stream) willRead(n uint64) {
+ s.kind = -1 // rearm Kind
+ if len(s.stack) > 0 {
+ s.stack[len(s.stack)-1].pos += n
+ }
+}
diff --git a/rlp/decode_test.go b/rlp/decode_test.go
new file mode 100644
index 000000000..a18ff1d08
--- /dev/null
+++ b/rlp/decode_test.go
@@ -0,0 +1,596 @@
+package rlp
+
+import (
+ "bytes"
+ "encoding/hex"
+ "fmt"
+ "io"
+ "math/big"
+ "reflect"
+ "testing"
+)
+
+func TestStreamKind(t *testing.T) {
+ tests := []struct {
+ input string
+ wantKind Kind
+ wantLen uint64
+ }{
+ {"00", Byte, 0},
+ {"01", Byte, 0},
+ {"7F", Byte, 0},
+ {"80", String, 0},
+ {"B7", String, 55},
+ {"B800", String, 0},
+ {"B90400", String, 1024},
+ {"BA000400", String, 1024},
+ {"BB00000400", String, 1024},
+ {"BFFFFFFFFFFFFFFFFF", String, ^uint64(0)},
+ {"C0", List, 0},
+ {"C8", List, 8},
+ {"F7", List, 55},
+ {"F800", List, 0},
+ {"F804", List, 4},
+ {"F90400", List, 1024},
+ {"FFFFFFFFFFFFFFFFFF", List, ^uint64(0)},
+ }
+
+ for i, test := range tests {
+ s := NewStream(bytes.NewReader(unhex(test.input)))
+ kind, len, err := s.Kind()
+ if err != nil {
+ t.Errorf("test %d: Kind returned error: %v", i, err)
+ continue
+ }
+ if kind != test.wantKind {
+ t.Errorf("test %d: kind mismatch: got %d, want %d", i, kind, test.wantKind)
+ }
+ if len != test.wantLen {
+ t.Errorf("test %d: len mismatch: got %d, want %d", i, len, test.wantLen)
+ }
+ }
+}
+
+func TestNewListStream(t *testing.T) {
+ ls := NewListStream(bytes.NewReader(unhex("0101010101")), 3)
+ if k, size, err := ls.Kind(); k != List || size != 3 || err != nil {
+ t.Errorf("Kind() returned (%v, %d, %v), expected (List, 3, nil)", k, size, err)
+ }
+ if size, err := ls.List(); size != 3 || err != nil {
+ t.Errorf("List() returned (%d, %v), expected (3, nil)", size, err)
+ }
+ for i := 0; i < 3; i++ {
+ if val, err := ls.Uint(); val != 1 || err != nil {
+ t.Errorf("Uint() returned (%d, %v), expected (1, nil)", val, err)
+ }
+ }
+ if err := ls.ListEnd(); err != nil {
+ t.Errorf("ListEnd() returned %v, expected (3, nil)", err)
+ }
+}
+
+func TestStreamErrors(t *testing.T) {
+ type calls []string
+ tests := []struct {
+ string
+ calls
+ error
+ }{
+ {"", calls{"Kind"}, io.EOF},
+ {"", calls{"List"}, io.EOF},
+ {"", calls{"Uint"}, io.EOF},
+ {"C0", calls{"Bytes"}, ErrExpectedString},
+ {"C0", calls{"Uint"}, ErrExpectedString},
+ {"81", calls{"Bytes"}, io.ErrUnexpectedEOF},
+ {"81", calls{"Uint"}, io.ErrUnexpectedEOF},
+ {"BFFFFFFFFFFFFFFF", calls{"Bytes"}, io.ErrUnexpectedEOF},
+ {"89000000000000000001", calls{"Uint"}, errUintOverflow},
+ {"00", calls{"List"}, ErrExpectedList},
+ {"80", calls{"List"}, ErrExpectedList},
+ {"C0", calls{"List", "Uint"}, EOL},
+ {"C801", calls{"List", "Uint", "Uint"}, io.ErrUnexpectedEOF},
+ {"C8C9", calls{"List", "Kind"}, ErrElemTooLarge},
+ {"C3C2010201", calls{"List", "List", "Uint", "Uint", "ListEnd", "Uint"}, EOL},
+ {"00", calls{"ListEnd"}, errNotInList},
+ {"C40102", calls{"List", "Uint", "ListEnd"}, errNotAtEOL},
+
+ // This test verifies that the input position is advanced
+ // correctly when calling Bytes for empty strings. Kind can be called
+ // any number of times in between and doesn't advance.
+ {"C3808080", calls{
+ "List", // enter the list
+ "Bytes", // past first element
+
+ "Kind", "Kind", "Kind", // this shouldn't advance
+
+ "Bytes", // past second element
+
+ "Kind", "Kind", // can't hurt to try
+
+ "Bytes", // past final element
+ "Bytes", // this one should fail
+ }, EOL},
+ }
+
+testfor:
+ for i, test := range tests {
+ s := NewStream(bytes.NewReader(unhex(test.string)))
+ rs := reflect.ValueOf(s)
+ for j, call := range test.calls {
+ fval := rs.MethodByName(call)
+ ret := fval.Call(nil)
+ err := "<nil>"
+ if lastret := ret[len(ret)-1].Interface(); lastret != nil {
+ err = lastret.(error).Error()
+ }
+ if j == len(test.calls)-1 {
+ if err != test.error.Error() {
+ t.Errorf("test %d: last call (%s) error mismatch\ngot: %s\nwant: %v",
+ i, call, err, test.error)
+ }
+ } else if err != "<nil>" {
+ t.Errorf("test %d: call %d (%s) unexpected error: %q", i, j, call, err)
+ continue testfor
+ }
+ }
+ }
+}
+
+func TestStreamList(t *testing.T) {
+ s := NewStream(bytes.NewReader(unhex("C80102030405060708")))
+
+ len, err := s.List()
+ if err != nil {
+ t.Fatalf("List error: %v", err)
+ }
+ if len != 8 {
+ t.Fatalf("List returned invalid length, got %d, want 8", len)
+ }
+
+ for i := uint64(1); i <= 8; i++ {
+ v, err := s.Uint()
+ if err != nil {
+ t.Fatalf("Uint error: %v", err)
+ }
+ if i != v {
+ t.Errorf("Uint returned wrong value, got %d, want %d", v, i)
+ }
+ }
+
+ if _, err := s.Uint(); err != EOL {
+ t.Errorf("Uint error mismatch, got %v, want %v", err, EOL)
+ }
+ if err = s.ListEnd(); err != nil {
+ t.Fatalf("ListEnd error: %v", err)
+ }
+}
+
+func TestStreamRaw(t *testing.T) {
+ s := NewStream(bytes.NewReader(unhex("C58401010101")))
+ s.List()
+
+ want := unhex("8401010101")
+ raw, err := s.Raw()
+ if err != nil {
+ t.Fatal(err)
+ }
+ if !bytes.Equal(want, raw) {
+ t.Errorf("raw mismatch: got %x, want %x", raw, want)
+ }
+}
+
+func TestDecodeErrors(t *testing.T) {
+ r := bytes.NewReader(nil)
+
+ if err := Decode(r, nil); err != errDecodeIntoNil {
+ t.Errorf("Decode(r, nil) error mismatch, got %q, want %q", err, errDecodeIntoNil)
+ }
+
+ var nilptr *struct{}
+ if err := Decode(r, nilptr); err != errDecodeIntoNil {
+ t.Errorf("Decode(r, nilptr) error mismatch, got %q, want %q", err, errDecodeIntoNil)
+ }
+
+ if err := Decode(r, struct{}{}); err != errNoPointer {
+ t.Errorf("Decode(r, struct{}{}) error mismatch, got %q, want %q", err, errNoPointer)
+ }
+
+ expectErr := "rlp: type chan bool is not RLP-serializable"
+ if err := Decode(r, new(chan bool)); err == nil || err.Error() != expectErr {
+ t.Errorf("Decode(r, new(chan bool)) error mismatch, got %q, want %q", err, expectErr)
+ }
+
+ if err := Decode(r, new(uint)); err != io.EOF {
+ t.Errorf("Decode(r, new(int)) error mismatch, got %q, want %q", err, io.EOF)
+ }
+}
+
+type decodeTest struct {
+ input string
+ ptr interface{}
+ value interface{}
+ error string
+}
+
+type simplestruct struct {
+ A uint
+ B string
+}
+
+type recstruct struct {
+ I uint
+ Child *recstruct
+}
+
+var (
+ veryBigInt = big.NewInt(0).Add(
+ big.NewInt(0).Lsh(big.NewInt(0xFFFFFFFFFFFFFF), 16),
+ big.NewInt(0xFFFF),
+ )
+)
+
+var (
+ sharedByteArray [5]byte
+ sharedPtr = new(*uint)
+)
+
+var decodeTests = []decodeTest{
+ // integers
+ {input: "05", ptr: new(uint32), value: uint32(5)},
+ {input: "80", ptr: new(uint32), value: uint32(0)},
+ {input: "8105", ptr: new(uint32), value: uint32(5)},
+ {input: "820505", ptr: new(uint32), value: uint32(0x0505)},
+ {input: "83050505", ptr: new(uint32), value: uint32(0x050505)},
+ {input: "8405050505", ptr: new(uint32), value: uint32(0x05050505)},
+ {input: "850505050505", ptr: new(uint32), error: "rlp: input string too long for uint32"},
+ {input: "C0", ptr: new(uint32), error: "rlp: expected input string or byte for uint32"},
+
+ // slices
+ {input: "C0", ptr: new([]uint), value: []uint{}},
+ {input: "C80102030405060708", ptr: new([]uint), value: []uint{1, 2, 3, 4, 5, 6, 7, 8}},
+
+ // arrays
+ {input: "C0", ptr: new([5]uint), value: [5]uint{}},
+ {input: "C50102030405", ptr: new([5]uint), value: [5]uint{1, 2, 3, 4, 5}},
+ {input: "C6010203040506", ptr: new([5]uint), error: "rlp: input list has too many elements for [5]uint"},
+
+ // byte slices
+ {input: "01", ptr: new([]byte), value: []byte{1}},
+ {input: "80", ptr: new([]byte), value: []byte{}},
+ {input: "8D6162636465666768696A6B6C6D", ptr: new([]byte), value: []byte("abcdefghijklm")},
+ {input: "C0", ptr: new([]byte), value: []byte{}},
+ {input: "C3010203", ptr: new([]byte), value: []byte{1, 2, 3}},
+
+ {
+ input: "C3820102",
+ ptr: new([]byte),
+ error: "rlp: input string too long for uint8, decoding into ([]uint8)[0]",
+ },
+
+ // byte arrays
+ {input: "01", ptr: new([5]byte), value: [5]byte{1}},
+ {input: "80", ptr: new([5]byte), value: [5]byte{}},
+ {input: "850102030405", ptr: new([5]byte), value: [5]byte{1, 2, 3, 4, 5}},
+ {input: "C0", ptr: new([5]byte), value: [5]byte{}},
+ {input: "C3010203", ptr: new([5]byte), value: [5]byte{1, 2, 3, 0, 0}},
+
+ {
+ input: "C3820102",
+ ptr: new([5]byte),
+ error: "rlp: input string too long for uint8, decoding into ([5]uint8)[0]",
+ },
+ {
+ input: "86010203040506",
+ ptr: new([5]byte),
+ error: "rlp: input string too long for [5]uint8",
+ },
+ {
+ input: "850101",
+ ptr: new([5]byte),
+ error: io.ErrUnexpectedEOF.Error(),
+ },
+
+ // byte array reuse (should be zeroed)
+ {input: "850102030405", ptr: &sharedByteArray, value: [5]byte{1, 2, 3, 4, 5}},
+ {input: "8101", ptr: &sharedByteArray, value: [5]byte{1}}, // kind: String
+ {input: "850102030405", ptr: &sharedByteArray, value: [5]byte{1, 2, 3, 4, 5}},
+ {input: "01", ptr: &sharedByteArray, value: [5]byte{1}}, // kind: Byte
+ {input: "C3010203", ptr: &sharedByteArray, value: [5]byte{1, 2, 3, 0, 0}},
+ {input: "C101", ptr: &sharedByteArray, value: [5]byte{1}}, // kind: List
+
+ // zero sized byte arrays
+ {input: "80", ptr: new([0]byte), value: [0]byte{}},
+ {input: "C0", ptr: new([0]byte), value: [0]byte{}},
+ {input: "01", ptr: new([0]byte), error: "rlp: input string too long for [0]uint8"},
+ {input: "8101", ptr: new([0]byte), error: "rlp: input string too long for [0]uint8"},
+
+ // strings
+ {input: "00", ptr: new(string), value: "\000"},
+ {input: "8D6162636465666768696A6B6C6D", ptr: new(string), value: "abcdefghijklm"},
+ {input: "C0", ptr: new(string), error: "rlp: expected input string or byte for string"},
+
+ // big ints
+ {input: "01", ptr: new(*big.Int), value: big.NewInt(1)},
+ {input: "89FFFFFFFFFFFFFFFFFF", ptr: new(*big.Int), value: veryBigInt},
+ {input: "10", ptr: new(big.Int), value: *big.NewInt(16)}, // non-pointer also works
+ {input: "C0", ptr: new(*big.Int), error: "rlp: expected input string or byte for *big.Int"},
+
+ // structs
+ {input: "C0", ptr: new(simplestruct), value: simplestruct{0, ""}},
+ {input: "C105", ptr: new(simplestruct), value: simplestruct{5, ""}},
+ {input: "C50583343434", ptr: new(simplestruct), value: simplestruct{5, "444"}},
+ {
+ input: "C501C302C103",
+ ptr: new(recstruct),
+ value: recstruct{1, &recstruct{2, &recstruct{3, nil}}},
+ },
+
+ {
+ input: "C3010101",
+ ptr: new(simplestruct),
+ error: "rlp: input list has too many elements for rlp.simplestruct",
+ },
+ {
+ input: "C501C3C00000",
+ ptr: new(recstruct),
+ error: "rlp: expected input string or byte for uint, decoding into (rlp.recstruct).Child.I",
+ },
+
+ // pointers
+ {input: "00", ptr: new(*uint), value: (*uint)(nil)},
+ {input: "80", ptr: new(*uint), value: (*uint)(nil)},
+ {input: "C0", ptr: new(*uint), value: (*uint)(nil)},
+ {input: "07", ptr: new(*uint), value: uintp(7)},
+ {input: "8108", ptr: new(*uint), value: uintp(8)},
+ {input: "C109", ptr: new(*[]uint), value: &[]uint{9}},
+ {input: "C58403030303", ptr: new(*[][]byte), value: &[][]byte{{3, 3, 3, 3}}},
+
+ // check that input position is advanced also for empty values.
+ {input: "C3808005", ptr: new([]*uint), value: []*uint{nil, nil, uintp(5)}},
+
+ // pointer should be reset to nil
+ {input: "05", ptr: sharedPtr, value: uintp(5)},
+ {input: "80", ptr: sharedPtr, value: (*uint)(nil)},
+
+ // interface{}
+ {input: "00", ptr: new(interface{}), value: []byte{0}},
+ {input: "01", ptr: new(interface{}), value: []byte{1}},
+ {input: "80", ptr: new(interface{}), value: []byte{}},
+ {input: "850505050505", ptr: new(interface{}), value: []byte{5, 5, 5, 5, 5}},
+ {input: "C0", ptr: new(interface{}), value: []interface{}{}},
+ {input: "C50183040404", ptr: new(interface{}), value: []interface{}{[]byte{1}, []byte{4, 4, 4}}},
+ {
+ input: "C3010203",
+ ptr: new([]io.Reader),
+ error: "rlp: type io.Reader is not RLP-serializable",
+ },
+}
+
+func uintp(i uint) *uint { return &i }
+
+func runTests(t *testing.T, decode func([]byte, interface{}) error) {
+ for i, test := range decodeTests {
+ input, err := hex.DecodeString(test.input)
+ if err != nil {
+ t.Errorf("test %d: invalid hex input %q", i, test.input)
+ continue
+ }
+ err = decode(input, test.ptr)
+ if err != nil && test.error == "" {
+ t.Errorf("test %d: unexpected Decode error: %v\ndecoding into %T\ninput %q",
+ i, err, test.ptr, test.input)
+ continue
+ }
+ if test.error != "" && fmt.Sprint(err) != test.error {
+ t.Errorf("test %d: Decode error mismatch\ngot %v\nwant %v\ndecoding into %T\ninput %q",
+ i, err, test.error, test.ptr, test.input)
+ continue
+ }
+ deref := reflect.ValueOf(test.ptr).Elem().Interface()
+ if err == nil && !reflect.DeepEqual(deref, test.value) {
+ t.Errorf("test %d: value mismatch\ngot %#v\nwant %#v\ndecoding into %T\ninput %q",
+ i, deref, test.value, test.ptr, test.input)
+ }
+ }
+}
+
+func TestDecodeWithByteReader(t *testing.T) {
+ runTests(t, func(input []byte, into interface{}) error {
+ return Decode(bytes.NewReader(input), into)
+ })
+}
+
+// dumbReader reads from a byte slice but does not
+// implement ReadByte.
+type dumbReader []byte
+
+func (r *dumbReader) Read(buf []byte) (n int, err error) {
+ if len(*r) == 0 {
+ return 0, io.EOF
+ }
+ n = copy(buf, *r)
+ *r = (*r)[n:]
+ return n, nil
+}
+
+func TestDecodeWithNonByteReader(t *testing.T) {
+ runTests(t, func(input []byte, into interface{}) error {
+ r := dumbReader(input)
+ return Decode(&r, into)
+ })
+}
+
+func TestDecodeStreamReset(t *testing.T) {
+ s := NewStream(nil)
+ runTests(t, func(input []byte, into interface{}) error {
+ s.Reset(bytes.NewReader(input))
+ return s.Decode(into)
+ })
+}
+
+type testDecoder struct{ called bool }
+
+func (t *testDecoder) DecodeRLP(s *Stream) error {
+ if _, err := s.Uint(); err != nil {
+ return err
+ }
+ t.called = true
+ return nil
+}
+
+func TestDecodeDecoder(t *testing.T) {
+ var s struct {
+ T1 testDecoder
+ T2 *testDecoder
+ T3 **testDecoder
+ }
+ if err := Decode(bytes.NewReader(unhex("C3010203")), &s); err != nil {
+ t.Fatalf("Decode error: %v", err)
+ }
+
+ if !s.T1.called {
+ t.Errorf("DecodeRLP was not called for (non-pointer) testDecoder")
+ }
+
+ if s.T2 == nil {
+ t.Errorf("*testDecoder has not been allocated")
+ } else if !s.T2.called {
+ t.Errorf("DecodeRLP was not called for *testDecoder")
+ }
+
+ if s.T3 == nil || *s.T3 == nil {
+ t.Errorf("**testDecoder has not been allocated")
+ } else if !(*s.T3).called {
+ t.Errorf("DecodeRLP was not called for **testDecoder")
+ }
+}
+
+type byteDecoder byte
+
+func (bd *byteDecoder) DecodeRLP(s *Stream) error {
+ _, err := s.Uint()
+ *bd = 255
+ return err
+}
+
+func (bd byteDecoder) called() bool {
+ return bd == 255
+}
+
+// This test verifies that the byte slice/byte array logic
+// does not kick in for element types implementing Decoder.
+func TestDecoderInByteSlice(t *testing.T) {
+ var slice []byteDecoder
+ if err := Decode(bytes.NewReader(unhex("C101")), &slice); err != nil {
+ t.Errorf("unexpected Decode error %v", err)
+ } else if !slice[0].called() {
+ t.Errorf("DecodeRLP not called for slice element")
+ }
+
+ var array [1]byteDecoder
+ if err := Decode(bytes.NewReader(unhex("C101")), &array); err != nil {
+ t.Errorf("unexpected Decode error %v", err)
+ } else if !array[0].called() {
+ t.Errorf("DecodeRLP not called for array element")
+ }
+}
+
+func ExampleDecode() {
+ input, _ := hex.DecodeString("C90A1486666F6F626172")
+
+ type example struct {
+ A, B uint
+ private uint // private fields are ignored
+ String string
+ }
+
+ var s example
+ err := Decode(bytes.NewReader(input), &s)
+ if err != nil {
+ fmt.Printf("Error: %v\n", err)
+ } else {
+ fmt.Printf("Decoded value: %#v\n", s)
+ }
+ // Output:
+ // Decoded value: rlp.example{A:0xa, B:0x14, private:0x0, String:"foobar"}
+}
+
+func ExampleStream() {
+ input, _ := hex.DecodeString("C90A1486666F6F626172")
+ s := NewStream(bytes.NewReader(input))
+
+ // Check what kind of value lies ahead
+ kind, size, _ := s.Kind()
+ fmt.Printf("Kind: %v size:%d\n", kind, size)
+
+ // Enter the list
+ if _, err := s.List(); err != nil {
+ fmt.Printf("List error: %v\n", err)
+ return
+ }
+
+ // Decode elements
+ fmt.Println(s.Uint())
+ fmt.Println(s.Uint())
+ fmt.Println(s.Bytes())
+
+ // Acknowledge end of list
+ if err := s.ListEnd(); err != nil {
+ fmt.Printf("ListEnd error: %v\n", err)
+ }
+ // Output:
+ // Kind: List size:9
+ // 10 <nil>
+ // 20 <nil>
+ // [102 111 111 98 97 114] <nil>
+}
+
+func BenchmarkDecode(b *testing.B) {
+ enc := encodeTestSlice(90000)
+ b.SetBytes(int64(len(enc)))
+ b.ReportAllocs()
+ b.ResetTimer()
+
+ for i := 0; i < b.N; i++ {
+ var s []uint
+ r := bytes.NewReader(enc)
+ if err := Decode(r, &s); err != nil {
+ b.Fatalf("Decode error: %v", err)
+ }
+ }
+}
+
+func BenchmarkDecodeIntSliceReuse(b *testing.B) {
+ enc := encodeTestSlice(100000)
+ b.SetBytes(int64(len(enc)))
+ b.ReportAllocs()
+ b.ResetTimer()
+
+ var s []uint
+ for i := 0; i < b.N; i++ {
+ r := bytes.NewReader(enc)
+ if err := Decode(r, &s); err != nil {
+ b.Fatalf("Decode error: %v", err)
+ }
+ }
+}
+
+func encodeTestSlice(n uint) []byte {
+ s := make([]uint, n)
+ for i := uint(0); i < n; i++ {
+ s[i] = i
+ }
+ b, err := EncodeToBytes(s)
+ if err != nil {
+ panic(fmt.Sprintf("encode error: %v", err))
+ }
+ return b
+}
+
+func unhex(str string) []byte {
+ b, err := hex.DecodeString(str)
+ if err != nil {
+ panic(fmt.Sprintf("invalid hex string: %q", str))
+ }
+ return b
+}
diff --git a/rlp/doc.go b/rlp/doc.go
new file mode 100644
index 000000000..aab98ea43
--- /dev/null
+++ b/rlp/doc.go
@@ -0,0 +1,17 @@
+/*
+Package rlp implements the RLP serialization format.
+
+The purpose of RLP (Recursive Linear Prefix) qis to encode arbitrarily
+nested arrays of binary data, and RLP is the main encoding method used
+to serialize objects in Ethereum. The only purpose of RLP is to encode
+structure; encoding specific atomic data types (eg. strings, ints,
+floats) is left up to higher-order protocols; in Ethereum integers
+must be represented in big endian binary form with no leading zeroes
+(thus making the integer value zero be equivalent to the empty byte
+array).
+
+RLP values are distinguished by a type tag. The type tag precedes the
+value in the input stream and defines the size and kind of the bytes
+that follow.
+*/
+package rlp
diff --git a/rlp/encode.go b/rlp/encode.go
new file mode 100644
index 000000000..6cf6776d6
--- /dev/null
+++ b/rlp/encode.go
@@ -0,0 +1,638 @@
+package rlp
+
+import (
+ "fmt"
+ "io"
+ "math/big"
+ "reflect"
+)
+
+// TODO: put encbufs in a sync.Pool.
+// Doing that requires zeroing the buffers after use.
+// encReader will need to drop it's buffer when done.
+
+var (
+ // Common encoded values.
+ // These are useful when implementing EncodeRLP.
+ EmptyString = []byte{0x80}
+ EmptyList = []byte{0xC0}
+)
+
+// Encoder is implemented by types that require custom
+// encoding rules or want to encode private fields.
+type Encoder interface {
+ // EncodeRLP should write the RLP encoding of its receiver to w.
+ // If the implementation is a pointer method, it may also be
+ // called for nil pointers.
+ //
+ // Implementations should generate valid RLP. The data written is
+ // not verified at the moment, but a future version might. It is
+ // recommended to write only a single value but writing multiple
+ // values or no value at all is also permitted.
+ EncodeRLP(io.Writer) error
+}
+
+// Flat wraps a value (which must encode as a list) so
+// it encodes as the list's elements.
+//
+// Example: suppose you have defined a type
+//
+// type foo struct { A, B uint }
+//
+// Under normal encoding rules,
+//
+// rlp.Encode(foo{1, 2}) --> 0xC20102
+//
+// This function can help you achieve the following encoding:
+//
+// rlp.Encode(rlp.Flat(foo{1, 2})) --> 0x0102
+func Flat(val interface{}) Encoder {
+ return flatenc{val}
+}
+
+type flatenc struct{ val interface{} }
+
+func (e flatenc) EncodeRLP(out io.Writer) error {
+ // record current output position
+ var (
+ eb = out.(*encbuf)
+ prevstrsize = len(eb.str)
+ prevnheads = len(eb.lheads)
+ )
+ if err := eb.encode(e.val); err != nil {
+ return err
+ }
+ // check that a new list header has appeared
+ if len(eb.lheads) == prevnheads || eb.lheads[prevnheads].offset == prevstrsize-1 {
+ return fmt.Errorf("rlp.Flat: %T did not encode as list", e.val)
+ }
+ // remove the new list header
+ newhead := eb.lheads[prevnheads]
+ copy(eb.lheads[prevnheads:], eb.lheads[prevnheads+1:])
+ eb.lheads = eb.lheads[:len(eb.lheads)-1]
+ eb.lhsize -= headsize(uint64(newhead.size))
+ return nil
+}
+
+// Encode writes the RLP encoding of val to w. Note that Encode may
+// perform many small writes in some cases. Consider making w
+// buffered.
+//
+// Encode uses the following type-dependent encoding rules:
+//
+// If the type implements the Encoder interface, Encode calls
+// EncodeRLP. This is true even for nil pointers, please see the
+// documentation for Encoder.
+//
+// To encode a pointer, the value being pointed to is encoded. For nil
+// pointers, Encode will encode the zero value of the type. A nil
+// pointer to a struct type always encodes as an empty RLP list.
+// A nil pointer to an array encodes as an empty list (or empty string
+// if the array has element type byte).
+//
+// Struct values are encoded as an RLP list of all their encoded
+// public fields. Recursive struct types are supported.
+//
+// To encode slices and arrays, the elements are encoded as an RLP
+// list of the value's elements. Note that arrays and slices with
+// element type uint8 or byte are always encoded as an RLP string.
+//
+// A Go string is encoded as an RLP string.
+//
+// An unsigned integer value is encoded as an RLP string. Zero always
+// encodes as an empty RLP string. Encode also supports *big.Int.
+//
+// An interface value encodes as the value contained in the interface.
+//
+// Boolean values are not supported, nor are signed integers, floating
+// point numbers, maps, channels and functions.
+func Encode(w io.Writer, val interface{}) error {
+ if outer, ok := w.(*encbuf); ok {
+ // Encode was called by some type's EncodeRLP.
+ // Avoid copying by writing to the outer encbuf directly.
+ return outer.encode(val)
+ }
+ eb := newencbuf()
+ if err := eb.encode(val); err != nil {
+ return err
+ }
+ return eb.toWriter(w)
+}
+
+// EncodeBytes returns the RLP encoding of val.
+// Please see the documentation of Encode for the encoding rules.
+func EncodeToBytes(val interface{}) ([]byte, error) {
+ eb := newencbuf()
+ if err := eb.encode(val); err != nil {
+ return nil, err
+ }
+ return eb.toBytes(), nil
+}
+
+// EncodeReader returns a reader from which the RLP encoding of val
+// can be read. The returned size is the total size of the encoded
+// data.
+//
+// Please see the documentation of Encode for the encoding rules.
+func EncodeToReader(val interface{}) (size int, r io.Reader, err error) {
+ eb := newencbuf()
+ if err := eb.encode(val); err != nil {
+ return 0, nil, err
+ }
+ return eb.size(), &encReader{buf: eb}, nil
+}
+
+type encbuf struct {
+ str []byte // string data, contains everything except list headers
+ lheads []*listhead // all list headers
+ lhsize int // sum of sizes of all encoded list headers
+ sizebuf []byte // 9-byte auxiliary buffer for uint encoding
+}
+
+type listhead struct {
+ offset int // index of this header in string data
+ size int // total size of encoded data (including list headers)
+}
+
+// encode writes head to the given buffer, which must be at least
+// 9 bytes long. It returns the encoded bytes.
+func (head *listhead) encode(buf []byte) []byte {
+ return buf[:puthead(buf, 0xC0, 0xF7, uint64(head.size))]
+}
+
+// headsize returns the size of a list or string header
+// for a value of the given size.
+func headsize(size uint64) int {
+ if size < 56 {
+ return 1
+ }
+ return 1 + intsize(size)
+}
+
+// puthead writes a list or string header to buf.
+// buf must be at least 9 bytes long.
+func puthead(buf []byte, smalltag, largetag byte, size uint64) int {
+ if size < 56 {
+ buf[0] = smalltag + byte(size)
+ return 1
+ } else {
+ sizesize := putint(buf[1:], size)
+ buf[0] = largetag + byte(sizesize)
+ return sizesize + 1
+ }
+}
+
+func newencbuf() *encbuf {
+ return &encbuf{sizebuf: make([]byte, 9)}
+}
+
+// encbuf implements io.Writer so it can be passed it into EncodeRLP.
+func (w *encbuf) Write(b []byte) (int, error) {
+ w.str = append(w.str, b...)
+ return len(b), nil
+}
+
+func (w *encbuf) encode(val interface{}) error {
+ rval := reflect.ValueOf(val)
+ ti, err := cachedTypeInfo(rval.Type())
+ if err != nil {
+ return err
+ }
+ return ti.writer(rval, w)
+}
+
+func (w *encbuf) encodeStringHeader(size int) {
+ if size < 56 {
+ w.str = append(w.str, 0x80+byte(size))
+ } else {
+ // TODO: encode to w.str directly
+ sizesize := putint(w.sizebuf[1:], uint64(size))
+ w.sizebuf[0] = 0xB7 + byte(sizesize)
+ w.str = append(w.str, w.sizebuf[:sizesize+1]...)
+ }
+}
+
+func (w *encbuf) encodeString(b []byte) {
+ if len(b) == 1 && b[0] <= 0x7F {
+ // fits single byte, no string header
+ w.str = append(w.str, b[0])
+ } else {
+ w.encodeStringHeader(len(b))
+ w.str = append(w.str, b...)
+ }
+}
+
+func (w *encbuf) list() *listhead {
+ lh := &listhead{offset: len(w.str), size: w.lhsize}
+ w.lheads = append(w.lheads, lh)
+ return lh
+}
+
+func (w *encbuf) listEnd(lh *listhead) {
+ lh.size = w.size() - lh.offset - lh.size
+ if lh.size < 56 {
+ w.lhsize += 1 // length encoded into kind tag
+ } else {
+ w.lhsize += 1 + intsize(uint64(lh.size))
+ }
+}
+
+func (w *encbuf) size() int {
+ return len(w.str) + w.lhsize
+}
+
+func (w *encbuf) toBytes() []byte {
+ out := make([]byte, w.size())
+ strpos := 0
+ pos := 0
+ for _, head := range w.lheads {
+ // write string data before header
+ n := copy(out[pos:], w.str[strpos:head.offset])
+ pos += n
+ strpos += n
+ // write the header
+ enc := head.encode(out[pos:])
+ pos += len(enc)
+ }
+ // copy string data after the last list header
+ copy(out[pos:], w.str[strpos:])
+ return out
+}
+
+func (w *encbuf) toWriter(out io.Writer) (err error) {
+ strpos := 0
+ for _, head := range w.lheads {
+ // write string data before header
+ if head.offset-strpos > 0 {
+ n, err := out.Write(w.str[strpos:head.offset])
+ strpos += n
+ if err != nil {
+ return err
+ }
+ }
+ // write the header
+ enc := head.encode(w.sizebuf)
+ if _, err = out.Write(enc); err != nil {
+ return err
+ }
+ }
+ if strpos < len(w.str) {
+ // write string data after the last list header
+ _, err = out.Write(w.str[strpos:])
+ }
+ return err
+}
+
+// encReader is the io.Reader returned by EncodeToReader.
+// It releases its encbuf at EOF.
+type encReader struct {
+ buf *encbuf // the buffer we're reading from. this is nil when we're at EOF.
+ lhpos int // index of list header that we're reading
+ strpos int // current position in string buffer
+ piece []byte // next piece to be read
+}
+
+func (r *encReader) Read(b []byte) (n int, err error) {
+ for {
+ if r.piece = r.next(); r.piece == nil {
+ return n, io.EOF
+ }
+ nn := copy(b[n:], r.piece)
+ n += nn
+ if nn < len(r.piece) {
+ // piece didn't fit, see you next time.
+ r.piece = r.piece[nn:]
+ return n, nil
+ }
+ r.piece = nil
+ }
+ panic("not reached")
+}
+
+// next returns the next piece of data to be read.
+// it returns nil at EOF.
+func (r *encReader) next() []byte {
+ switch {
+ case r.piece != nil:
+ // There is still data available for reading.
+ return r.piece
+
+ case r.lhpos < len(r.buf.lheads):
+ // We're before the last list header.
+ head := r.buf.lheads[r.lhpos]
+ sizebefore := head.offset - r.strpos
+ if sizebefore > 0 {
+ // String data before header.
+ p := r.buf.str[r.strpos:head.offset]
+ r.strpos += sizebefore
+ return p
+ } else {
+ r.lhpos++
+ return head.encode(r.buf.sizebuf)
+ }
+
+ case r.strpos < len(r.buf.str):
+ // String data at the end, after all list headers.
+ p := r.buf.str[r.strpos:]
+ r.strpos = len(r.buf.str)
+ return p
+
+ default:
+ return nil
+ }
+}
+
+var (
+ encoderInterface = reflect.TypeOf(new(Encoder)).Elem()
+ big0 = big.NewInt(0)
+)
+
+// makeWriter creates a writer function for the given type.
+func makeWriter(typ reflect.Type) (writer, error) {
+ kind := typ.Kind()
+ switch {
+ case typ.Implements(encoderInterface):
+ return writeEncoder, nil
+ case kind != reflect.Ptr && reflect.PtrTo(typ).Implements(encoderInterface):
+ return writeEncoderNoPtr, nil
+ case kind == reflect.Interface:
+ return writeInterface, nil
+ case typ.AssignableTo(reflect.PtrTo(bigInt)):
+ return writeBigIntPtr, nil
+ case typ.AssignableTo(bigInt):
+ return writeBigIntNoPtr, nil
+ case isUint(kind):
+ return writeUint, nil
+ case kind == reflect.String:
+ return writeString, nil
+ case kind == reflect.Slice && isByte(typ.Elem()):
+ return writeBytes, nil
+ case kind == reflect.Array && isByte(typ.Elem()):
+ return writeByteArray, nil
+ case kind == reflect.Slice || kind == reflect.Array:
+ return makeSliceWriter(typ)
+ case kind == reflect.Struct:
+ return makeStructWriter(typ)
+ case kind == reflect.Ptr:
+ return makePtrWriter(typ)
+ default:
+ return nil, fmt.Errorf("rlp: type %v is not RLP-serializable", typ)
+ }
+}
+
+func isByte(typ reflect.Type) bool {
+ return typ.Kind() == reflect.Uint8 && !typ.Implements(encoderInterface)
+}
+
+func writeUint(val reflect.Value, w *encbuf) error {
+ i := val.Uint()
+ if i == 0 {
+ w.str = append(w.str, 0x80)
+ } else if i < 128 {
+ // fits single byte
+ w.str = append(w.str, byte(i))
+ } else {
+ // TODO: encode int to w.str directly
+ s := putint(w.sizebuf[1:], i)
+ w.sizebuf[0] = 0x80 + byte(s)
+ w.str = append(w.str, w.sizebuf[:s+1]...)
+ }
+ return nil
+}
+
+func writeBigIntPtr(val reflect.Value, w *encbuf) error {
+ ptr := val.Interface().(*big.Int)
+ if ptr == nil {
+ w.str = append(w.str, 0x80)
+ return nil
+ }
+ return writeBigInt(ptr, w)
+}
+
+func writeBigIntNoPtr(val reflect.Value, w *encbuf) error {
+ i := val.Interface().(big.Int)
+ return writeBigInt(&i, w)
+}
+
+func writeBigInt(i *big.Int, w *encbuf) error {
+ if cmp := i.Cmp(big0); cmp == -1 {
+ return fmt.Errorf("rlp: cannot encode negative *big.Int")
+ } else if cmp == 0 {
+ w.str = append(w.str, 0x80)
+ } else {
+ w.encodeString(i.Bytes())
+ }
+ return nil
+}
+
+func writeBytes(val reflect.Value, w *encbuf) error {
+ w.encodeString(val.Bytes())
+ return nil
+}
+
+func writeByteArray(val reflect.Value, w *encbuf) error {
+ if !val.CanAddr() {
+ // Slice requires the value to be addressable.
+ // Make it addressable by copying.
+ copy := reflect.New(val.Type()).Elem()
+ copy.Set(val)
+ val = copy
+ }
+ size := val.Len()
+ slice := val.Slice(0, size).Bytes()
+ w.encodeString(slice)
+ return nil
+}
+
+func writeString(val reflect.Value, w *encbuf) error {
+ s := val.String()
+ if len(s) == 1 && s[0] <= 0x7f {
+ // fits single byte, no string header
+ w.str = append(w.str, s[0])
+ } else {
+ w.encodeStringHeader(len(s))
+ w.str = append(w.str, s...)
+ }
+ return nil
+}
+
+func writeEncoder(val reflect.Value, w *encbuf) error {
+ return val.Interface().(Encoder).EncodeRLP(w)
+}
+
+// writeEncoderNoPtr handles non-pointer values that implement Encoder
+// with a pointer receiver.
+func writeEncoderNoPtr(val reflect.Value, w *encbuf) error {
+ if !val.CanAddr() {
+ // We can't get the address. It would be possible make the
+ // value addressable by creating a shallow copy, but this
+ // creates other problems so we're not doing it (yet).
+ //
+ // package json simply doesn't call MarshalJSON for cases like
+ // this, but encodes the value as if it didn't implement the
+ // interface. We don't want to handle it that way.
+ return fmt.Errorf("rlp: game over: unadressable value of type %v, EncodeRLP is pointer method", val.Type())
+ }
+ return val.Addr().Interface().(Encoder).EncodeRLP(w)
+}
+
+func writeInterface(val reflect.Value, w *encbuf) error {
+ if val.IsNil() {
+ // Write empty list. This is consistent with the previous RLP
+ // encoder that we had and should therefore avoid any
+ // problems.
+ w.str = append(w.str, 0xC0)
+ return nil
+ }
+ eval := val.Elem()
+ ti, err := cachedTypeInfo(eval.Type())
+ if err != nil {
+ return err
+ }
+ return ti.writer(eval, w)
+}
+
+func makeSliceWriter(typ reflect.Type) (writer, error) {
+ etypeinfo, err := cachedTypeInfo1(typ.Elem())
+ if err != nil {
+ return nil, err
+ }
+ writer := func(val reflect.Value, w *encbuf) error {
+ lh := w.list()
+ vlen := val.Len()
+ for i := 0; i < vlen; i++ {
+ if err := etypeinfo.writer(val.Index(i), w); err != nil {
+ return err
+ }
+ }
+ w.listEnd(lh)
+ return nil
+ }
+ return writer, nil
+}
+
+func makeStructWriter(typ reflect.Type) (writer, error) {
+ fields, err := structFields(typ)
+ if err != nil {
+ return nil, err
+ }
+ writer := func(val reflect.Value, w *encbuf) error {
+ lh := w.list()
+ for _, f := range fields {
+ if err := f.info.writer(val.Field(f.index), w); err != nil {
+ return err
+ }
+ }
+ w.listEnd(lh)
+ return nil
+ }
+ return writer, nil
+}
+
+func makePtrWriter(typ reflect.Type) (writer, error) {
+ etypeinfo, err := cachedTypeInfo1(typ.Elem())
+ if err != nil {
+ return nil, err
+ }
+
+ // determine nil pointer handler
+ var nilfunc func(*encbuf) error
+ kind := typ.Elem().Kind()
+ switch {
+ case kind == reflect.Array && isByte(typ.Elem().Elem()):
+ nilfunc = func(w *encbuf) error {
+ w.str = append(w.str, 0x80)
+ return nil
+ }
+ case kind == reflect.Struct || kind == reflect.Array:
+ nilfunc = func(w *encbuf) error {
+ // encoding the zero value of a struct/array could trigger
+ // infinite recursion, avoid that.
+ w.listEnd(w.list())
+ return nil
+ }
+ default:
+ zero := reflect.Zero(typ.Elem())
+ nilfunc = func(w *encbuf) error {
+ return etypeinfo.writer(zero, w)
+ }
+ }
+
+ writer := func(val reflect.Value, w *encbuf) error {
+ if val.IsNil() {
+ return nilfunc(w)
+ } else {
+ return etypeinfo.writer(val.Elem(), w)
+ }
+ }
+ return writer, err
+}
+
+// putint writes i to the beginning of b in with big endian byte
+// order, using the least number of bytes needed to represent i.
+func putint(b []byte, i uint64) (size int) {
+ switch {
+ case i < (1 << 8):
+ b[0] = byte(i)
+ return 1
+ case i < (1 << 16):
+ b[0] = byte(i >> 8)
+ b[1] = byte(i)
+ return 2
+ case i < (1 << 24):
+ b[0] = byte(i >> 16)
+ b[1] = byte(i >> 8)
+ b[2] = byte(i)
+ return 3
+ case i < (1 << 32):
+ b[0] = byte(i >> 24)
+ b[1] = byte(i >> 16)
+ b[2] = byte(i >> 8)
+ b[3] = byte(i)
+ return 4
+ case i < (1 << 40):
+ b[0] = byte(i >> 32)
+ b[1] = byte(i >> 24)
+ b[2] = byte(i >> 16)
+ b[3] = byte(i >> 8)
+ b[4] = byte(i)
+ return 5
+ case i < (1 << 48):
+ b[0] = byte(i >> 40)
+ b[1] = byte(i >> 32)
+ b[2] = byte(i >> 24)
+ b[3] = byte(i >> 16)
+ b[4] = byte(i >> 8)
+ b[5] = byte(i)
+ return 6
+ case i < (1 << 56):
+ b[0] = byte(i >> 48)
+ b[1] = byte(i >> 40)
+ b[2] = byte(i >> 32)
+ b[3] = byte(i >> 24)
+ b[4] = byte(i >> 16)
+ b[5] = byte(i >> 8)
+ b[6] = byte(i)
+ return 7
+ default:
+ b[0] = byte(i >> 56)
+ b[1] = byte(i >> 48)
+ b[2] = byte(i >> 40)
+ b[3] = byte(i >> 32)
+ b[4] = byte(i >> 24)
+ b[5] = byte(i >> 16)
+ b[6] = byte(i >> 8)
+ b[7] = byte(i)
+ return 8
+ }
+}
+
+// intsize computes the minimum number of bytes required to store i.
+func intsize(i uint64) (size int) {
+ for size = 1; ; size++ {
+ if i >>= 8; i == 0 {
+ return size
+ }
+ }
+ panic("not reached")
+}
diff --git a/rlp/encode_test.go b/rlp/encode_test.go
new file mode 100644
index 000000000..6eb930d6c
--- /dev/null
+++ b/rlp/encode_test.go
@@ -0,0 +1,297 @@
+package rlp
+
+import (
+ "bytes"
+ "errors"
+ "fmt"
+ "io"
+ "io/ioutil"
+ "math/big"
+ "testing"
+)
+
+type testEncoder struct {
+ err error
+}
+
+func (e *testEncoder) EncodeRLP(w io.Writer) error {
+ if e == nil {
+ w.Write([]byte{0, 0, 0, 0})
+ } else if e.err != nil {
+ return e.err
+ } else {
+ w.Write([]byte{0, 1, 0, 1, 0, 1, 0, 1, 0, 1})
+ }
+ return nil
+}
+
+type byteEncoder byte
+
+func (e byteEncoder) EncodeRLP(w io.Writer) error {
+ w.Write(EmptyList)
+ return nil
+}
+
+type encodableReader struct {
+ A, B uint
+}
+
+func (e *encodableReader) Read(b []byte) (int, error) {
+ panic("called")
+}
+
+type namedByteType byte
+
+var (
+ _ = Encoder(&testEncoder{})
+ _ = Encoder(byteEncoder(0))
+
+ reader io.Reader = &encodableReader{1, 2}
+)
+
+type encTest struct {
+ val interface{}
+ output, error string
+}
+
+var encTests = []encTest{
+ // integers
+ {val: uint32(0), output: "80"},
+ {val: uint32(127), output: "7F"},
+ {val: uint32(128), output: "8180"},
+ {val: uint32(256), output: "820100"},
+ {val: uint32(1024), output: "820400"},
+ {val: uint32(0xFFFFFF), output: "83FFFFFF"},
+ {val: uint32(0xFFFFFFFF), output: "84FFFFFFFF"},
+ {val: uint64(0xFFFFFFFF), output: "84FFFFFFFF"},
+ {val: uint64(0xFFFFFFFFFF), output: "85FFFFFFFFFF"},
+ {val: uint64(0xFFFFFFFFFFFF), output: "86FFFFFFFFFFFF"},
+ {val: uint64(0xFFFFFFFFFFFFFF), output: "87FFFFFFFFFFFFFF"},
+ {val: uint64(0xFFFFFFFFFFFFFFFF), output: "88FFFFFFFFFFFFFFFF"},
+
+ // big integers (should match uint for small values)
+ {val: big.NewInt(0), output: "80"},
+ {val: big.NewInt(1), output: "01"},
+ {val: big.NewInt(127), output: "7F"},
+ {val: big.NewInt(128), output: "8180"},
+ {val: big.NewInt(256), output: "820100"},
+ {val: big.NewInt(1024), output: "820400"},
+ {val: big.NewInt(0xFFFFFF), output: "83FFFFFF"},
+ {val: big.NewInt(0xFFFFFFFF), output: "84FFFFFFFF"},
+ {val: big.NewInt(0xFFFFFFFFFF), output: "85FFFFFFFFFF"},
+ {val: big.NewInt(0xFFFFFFFFFFFF), output: "86FFFFFFFFFFFF"},
+ {val: big.NewInt(0xFFFFFFFFFFFFFF), output: "87FFFFFFFFFFFFFF"},
+ {
+ val: big.NewInt(0).SetBytes(unhex("102030405060708090A0B0C0D0E0F2")),
+ output: "8F102030405060708090A0B0C0D0E0F2",
+ },
+ {
+ val: big.NewInt(0).SetBytes(unhex("0100020003000400050006000700080009000A000B000C000D000E01")),
+ output: "9C0100020003000400050006000700080009000A000B000C000D000E01",
+ },
+ {
+ val: big.NewInt(0).SetBytes(unhex("010000000000000000000000000000000000000000000000000000000000000000")),
+ output: "A1010000000000000000000000000000000000000000000000000000000000000000",
+ },
+
+ // non-pointer big.Int
+ {val: *big.NewInt(0), output: "80"},
+ {val: *big.NewInt(0xFFFFFF), output: "83FFFFFF"},
+
+ // negative ints are not supported
+ {val: big.NewInt(-1), error: "rlp: cannot encode negative *big.Int"},
+
+ // byte slices, strings
+ {val: []byte{}, output: "80"},
+ {val: []byte{0x7E}, output: "7E"},
+ {val: []byte{0x7F}, output: "7F"},
+ {val: []byte{0x80}, output: "8180"},
+ {val: []byte{1, 2, 3}, output: "83010203"},
+
+ {val: []namedByteType{1, 2, 3}, output: "83010203"},
+ {val: [...]namedByteType{1, 2, 3}, output: "83010203"},
+
+ {val: "", output: "80"},
+ {val: "\x7E", output: "7E"},
+ {val: "\x7F", output: "7F"},
+ {val: "\x80", output: "8180"},
+ {val: "dog", output: "83646F67"},
+ {
+ val: "Lorem ipsum dolor sit amet, consectetur adipisicing eli",
+ output: "B74C6F72656D20697073756D20646F6C6F722073697420616D65742C20636F6E7365637465747572206164697069736963696E6720656C69",
+ },
+ {
+ val: "Lorem ipsum dolor sit amet, consectetur adipisicing elit",
+ output: "B8384C6F72656D20697073756D20646F6C6F722073697420616D65742C20636F6E7365637465747572206164697069736963696E6720656C6974",
+ },
+ {
+ val: "Lorem ipsum dolor sit amet, consectetur adipiscing elit. Curabitur mauris magna, suscipit sed vehicula non, iaculis faucibus tortor. Proin suscipit ultricies malesuada. Duis tortor elit, dictum quis tristique eu, ultrices at risus. Morbi a est imperdiet mi ullamcorper aliquet suscipit nec lorem. Aenean quis leo mollis, vulputate elit varius, consequat enim. Nulla ultrices turpis justo, et posuere urna consectetur nec. Proin non convallis metus. Donec tempor ipsum in mauris congue sollicitudin. Vestibulum ante ipsum primis in faucibus orci luctus et ultrices posuere cubilia Curae; Suspendisse convallis sem vel massa faucibus, eget lacinia lacus tempor. Nulla quis ultricies purus. Proin auctor rhoncus nibh condimentum mollis. Aliquam consequat enim at metus luctus, a eleifend purus egestas. Curabitur at nibh metus. Nam bibendum, neque at auctor tristique, lorem libero aliquet arcu, non interdum tellus lectus sit amet eros. Cras rhoncus, metus ac ornare cursus, dolor justo ultrices metus, at ullamcorper volutpat",
+ output: "B904004C6F72656D20697073756D20646F6C6F722073697420616D65742C20636F6E73656374657475722061646970697363696E6720656C69742E20437572616269747572206D6175726973206D61676E612C20737573636970697420736564207665686963756C61206E6F6E2C20696163756C697320666175636962757320746F72746F722E2050726F696E20737573636970697420756C74726963696573206D616C6573756164612E204475697320746F72746F7220656C69742C2064696374756D2071756973207472697374697175652065752C20756C7472696365732061742072697375732E204D6F72626920612065737420696D70657264696574206D6920756C6C616D636F7270657220616C6971756574207375736369706974206E6563206C6F72656D2E2041656E65616E2071756973206C656F206D6F6C6C69732C2076756C70757461746520656C6974207661726975732C20636F6E73657175617420656E696D2E204E756C6C6120756C74726963657320747572706973206A7573746F2C20657420706F73756572652075726E6120636F6E7365637465747572206E65632E2050726F696E206E6F6E20636F6E76616C6C6973206D657475732E20446F6E65632074656D706F7220697073756D20696E206D617572697320636F6E67756520736F6C6C696369747564696E2E20566573746962756C756D20616E746520697073756D207072696D697320696E206661756369627573206F726369206C756374757320657420756C74726963657320706F737565726520637562696C69612043757261653B2053757370656E646973736520636F6E76616C6C69732073656D2076656C206D617373612066617563696275732C2065676574206C6163696E6961206C616375732074656D706F722E204E756C6C61207175697320756C747269636965732070757275732E2050726F696E20617563746F722072686F6E637573206E69626820636F6E64696D656E74756D206D6F6C6C69732E20416C697175616D20636F6E73657175617420656E696D206174206D65747573206C75637475732C206120656C656966656E6420707572757320656765737461732E20437572616269747572206174206E696268206D657475732E204E616D20626962656E64756D2C206E6571756520617420617563746F72207472697374697175652C206C6F72656D206C696265726F20616C697175657420617263752C206E6F6E20696E74657264756D2074656C6C7573206C65637475732073697420616D65742065726F732E20437261732072686F6E6375732C206D65747573206163206F726E617265206375727375732C20646F6C6F72206A7573746F20756C747269636573206D657475732C20617420756C6C616D636F7270657220766F6C7574706174",
+ },
+
+ // slices
+ {val: []uint{}, output: "C0"},
+ {val: []uint{1, 2, 3}, output: "C3010203"},
+ {
+ // [ [], [[]], [ [], [[]] ] ]
+ val: []interface{}{[]interface{}{}, [][]interface{}{{}}, []interface{}{[]interface{}{}, [][]interface{}{{}}}},
+ output: "C7C0C1C0C3C0C1C0",
+ },
+ {
+ val: []string{"aaa", "bbb", "ccc", "ddd", "eee", "fff", "ggg", "hhh", "iii", "jjj", "kkk", "lll", "mmm", "nnn", "ooo"},
+ output: "F83C836161618362626283636363836464648365656583666666836767678368686883696969836A6A6A836B6B6B836C6C6C836D6D6D836E6E6E836F6F6F",
+ },
+ {
+ val: []interface{}{uint(1), uint(0xFFFFFF), []interface{}{[]uint{4, 5, 5}}, "abc"},
+ output: "CE0183FFFFFFC4C304050583616263",
+ },
+ {
+ val: [][]string{
+ {"asdf", "qwer", "zxcv"},
+ {"asdf", "qwer", "zxcv"},
+ {"asdf", "qwer", "zxcv"},
+ {"asdf", "qwer", "zxcv"},
+ {"asdf", "qwer", "zxcv"},
+ {"asdf", "qwer", "zxcv"},
+ {"asdf", "qwer", "zxcv"},
+ {"asdf", "qwer", "zxcv"},
+ {"asdf", "qwer", "zxcv"},
+ {"asdf", "qwer", "zxcv"},
+ {"asdf", "qwer", "zxcv"},
+ {"asdf", "qwer", "zxcv"},
+ {"asdf", "qwer", "zxcv"},
+ {"asdf", "qwer", "zxcv"},
+ {"asdf", "qwer", "zxcv"},
+ {"asdf", "qwer", "zxcv"},
+ {"asdf", "qwer", "zxcv"},
+ {"asdf", "qwer", "zxcv"},
+ {"asdf", "qwer", "zxcv"},
+ {"asdf", "qwer", "zxcv"},
+ {"asdf", "qwer", "zxcv"},
+ {"asdf", "qwer", "zxcv"},
+ {"asdf", "qwer", "zxcv"},
+ {"asdf", "qwer", "zxcv"},
+ {"asdf", "qwer", "zxcv"},
+ {"asdf", "qwer", "zxcv"},
+ {"asdf", "qwer", "zxcv"},
+ {"asdf", "qwer", "zxcv"},
+ {"asdf", "qwer", "zxcv"},
+ {"asdf", "qwer", "zxcv"},
+ {"asdf", "qwer", "zxcv"},
+ {"asdf", "qwer", "zxcv"},
+ },
+ output: "F90200CF84617364668471776572847A786376CF84617364668471776572847A786376CF84617364668471776572847A786376CF84617364668471776572847A786376CF84617364668471776572847A786376CF84617364668471776572847A786376CF84617364668471776572847A786376CF84617364668471776572847A786376CF84617364668471776572847A786376CF84617364668471776572847A786376CF84617364668471776572847A786376CF84617364668471776572847A786376CF84617364668471776572847A786376CF84617364668471776572847A786376CF84617364668471776572847A786376CF84617364668471776572847A786376CF84617364668471776572847A786376CF84617364668471776572847A786376CF84617364668471776572847A786376CF84617364668471776572847A786376CF84617364668471776572847A786376CF84617364668471776572847A786376CF84617364668471776572847A786376CF84617364668471776572847A786376CF84617364668471776572847A786376CF84617364668471776572847A786376CF84617364668471776572847A786376CF84617364668471776572847A786376CF84617364668471776572847A786376CF84617364668471776572847A786376CF84617364668471776572847A786376CF84617364668471776572847A786376",
+ },
+
+ // structs
+ {val: simplestruct{}, output: "C28080"},
+ {val: simplestruct{A: 3, B: "foo"}, output: "C50383666F6F"},
+ {val: &recstruct{5, nil}, output: "C205C0"},
+ {val: &recstruct{5, &recstruct{4, &recstruct{3, nil}}}, output: "C605C404C203C0"},
+
+ // flat
+ {val: Flat(uint(1)), error: "rlp.Flat: uint did not encode as list"},
+ {val: Flat(simplestruct{A: 3, B: "foo"}), output: "0383666F6F"},
+ {
+ // value generates more list headers after the Flat
+ val: []interface{}{"foo", []uint{1, 2}, Flat([]uint{3, 4}), []uint{5, 6}, "bar"},
+ output: "D083666F6FC201020304C2050683626172",
+ },
+
+ // nil
+ {val: (*uint)(nil), output: "80"},
+ {val: (*string)(nil), output: "80"},
+ {val: (*[]byte)(nil), output: "80"},
+ {val: (*[10]byte)(nil), output: "80"},
+ {val: (*big.Int)(nil), output: "80"},
+ {val: (*[]string)(nil), output: "C0"},
+ {val: (*[10]string)(nil), output: "C0"},
+ {val: (*[]interface{})(nil), output: "C0"},
+ {val: (*[]struct{ uint })(nil), output: "C0"},
+ {val: (*interface{})(nil), output: "C0"},
+
+ // interfaces
+ {val: []io.Reader{reader}, output: "C3C20102"}, // the contained value is a struct
+
+ // Encoder
+ {val: (*testEncoder)(nil), output: "00000000"},
+ {val: &testEncoder{}, output: "00010001000100010001"},
+ {val: &testEncoder{errors.New("test error")}, error: "test error"},
+ // verify that pointer method testEncoder.EncodeRLP is called for
+ // addressable non-pointer values.
+ {val: &struct{ TE testEncoder }{testEncoder{}}, output: "CA00010001000100010001"},
+ {val: &struct{ TE testEncoder }{testEncoder{errors.New("test error")}}, error: "test error"},
+ // verify the error for non-addressable non-pointer Encoder
+ {val: testEncoder{}, error: "rlp: game over: unadressable value of type rlp.testEncoder, EncodeRLP is pointer method"},
+ // verify the special case for []byte
+ {val: []byteEncoder{0, 1, 2, 3, 4}, output: "C5C0C0C0C0C0"},
+}
+
+func runEncTests(t *testing.T, f func(val interface{}) ([]byte, error)) {
+ for i, test := range encTests {
+ output, err := f(test.val)
+ if err != nil && test.error == "" {
+ t.Errorf("test %d: unexpected error: %v\nvalue %#v\ntype %T",
+ i, err, test.val, test.val)
+ continue
+ }
+ if test.error != "" && fmt.Sprint(err) != test.error {
+ t.Errorf("test %d: error mismatch\ngot %v\nwant %v\nvalue %#v\ntype %T",
+ i, err, test.error, test.val, test.val)
+ continue
+ }
+ if err == nil && !bytes.Equal(output, unhex(test.output)) {
+ t.Errorf("test %d: output mismatch:\ngot %X\nwant %s\nvalue %#v\ntype %T",
+ i, output, test.output, test.val, test.val)
+ }
+ }
+}
+
+func TestEncode(t *testing.T) {
+ runEncTests(t, func(val interface{}) ([]byte, error) {
+ b := new(bytes.Buffer)
+ err := Encode(b, val)
+ return b.Bytes(), err
+ })
+}
+
+func TestEncodeToBytes(t *testing.T) {
+ runEncTests(t, EncodeToBytes)
+}
+
+func TestEncodeToReader(t *testing.T) {
+ runEncTests(t, func(val interface{}) ([]byte, error) {
+ _, r, err := EncodeToReader(val)
+ if err != nil {
+ return nil, err
+ }
+ return ioutil.ReadAll(r)
+ })
+}
+
+func TestEncodeToReaderPiecewise(t *testing.T) {
+ runEncTests(t, func(val interface{}) ([]byte, error) {
+ size, r, err := EncodeToReader(val)
+ if err != nil {
+ return nil, err
+ }
+
+ // read output piecewise
+ output := make([]byte, size)
+ for start, end := 0, 0; start < size; start = end {
+ if remaining := size - start; remaining < 3 {
+ end += remaining
+ } else {
+ end = start + 3
+ }
+ n, err := r.Read(output[start:end])
+ end = start + n
+ if err == io.EOF {
+ break
+ } else if err != nil {
+ return nil, err
+ }
+ }
+ return output, nil
+ })
+}
diff --git a/rlp/encoder_example_test.go b/rlp/encoder_example_test.go
new file mode 100644
index 000000000..57bad604d
--- /dev/null
+++ b/rlp/encoder_example_test.go
@@ -0,0 +1,38 @@
+package rlp
+
+import (
+ "fmt"
+ "io"
+)
+
+type MyCoolType struct {
+ Name string
+ a, b uint
+}
+
+// EncodeRLP writes x as RLP list [a, b] that omits the Name field.
+func (x *MyCoolType) EncodeRLP(w io.Writer) (err error) {
+ // Note: the receiver can be a nil pointer. This allows you to
+ // control the encoding of nil, but it also means that you have to
+ // check for a nil receiver.
+ if x == nil {
+ err = Encode(w, []uint{0, 0})
+ } else {
+ err = Encode(w, []uint{x.a, x.b})
+ }
+ return err
+}
+
+func ExampleEncoder() {
+ var t *MyCoolType // t is nil pointer to MyCoolType
+ bytes, _ := EncodeToBytes(t)
+ fmt.Printf("%v → %X\n", t, bytes)
+
+ t = &MyCoolType{Name: "foobar", a: 5, b: 6}
+ bytes, _ = EncodeToBytes(t)
+ fmt.Printf("%v → %X\n", t, bytes)
+
+ // Output:
+ // <nil> → C28080
+ // &{foobar 5 6} → C20506
+}
diff --git a/rlp/typecache.go b/rlp/typecache.go
new file mode 100644
index 000000000..398f25d90
--- /dev/null
+++ b/rlp/typecache.go
@@ -0,0 +1,81 @@
+package rlp
+
+import (
+ "reflect"
+ "sync"
+)
+
+var (
+ typeCacheMutex sync.RWMutex
+ typeCache = make(map[reflect.Type]*typeinfo)
+)
+
+type typeinfo struct {
+ decoder
+ writer
+}
+
+type decoder func(*Stream, reflect.Value) error
+
+type writer func(reflect.Value, *encbuf) error
+
+func cachedTypeInfo(typ reflect.Type) (*typeinfo, error) {
+ typeCacheMutex.RLock()
+ info := typeCache[typ]
+ typeCacheMutex.RUnlock()
+ if info != nil {
+ return info, nil
+ }
+ // not in the cache, need to generate info for this type.
+ typeCacheMutex.Lock()
+ defer typeCacheMutex.Unlock()
+ return cachedTypeInfo1(typ)
+}
+
+func cachedTypeInfo1(typ reflect.Type) (*typeinfo, error) {
+ info := typeCache[typ]
+ if info != nil {
+ // another goroutine got the write lock first
+ return info, nil
+ }
+ // put a dummmy value into the cache before generating.
+ // if the generator tries to lookup itself, it will get
+ // the dummy value and won't call itself recursively.
+ typeCache[typ] = new(typeinfo)
+ info, err := genTypeInfo(typ)
+ if err != nil {
+ // remove the dummy value if the generator fails
+ delete(typeCache, typ)
+ return nil, err
+ }
+ *typeCache[typ] = *info
+ return typeCache[typ], err
+}
+
+func structFields(typ reflect.Type) (fields []field, err error) {
+ for i := 0; i < typ.NumField(); i++ {
+ if f := typ.Field(i); f.PkgPath == "" { // exported
+ info, err := cachedTypeInfo1(f.Type)
+ if err != nil {
+ return nil, err
+ }
+ fields = append(fields, field{i, info})
+ }
+ }
+ return fields, nil
+}
+
+func genTypeInfo(typ reflect.Type) (info *typeinfo, err error) {
+ info = new(typeinfo)
+ if info.decoder, err = makeDecoder(typ); err != nil {
+ return nil, err
+ }
+ if info.writer, err = makeWriter(typ); err != nil {
+ return nil, err
+ }
+ return info, nil
+}
+
+func isUint(k reflect.Kind) bool {
+ return k >= reflect.Uint && k <= reflect.Uintptr
+}
diff --git a/rpc/api.go b/rpc/api.go
new file mode 100644
index 000000000..afd242aa3
--- /dev/null
+++ b/rpc/api.go
@@ -0,0 +1,462 @@
+package rpc
+
+import (
+ "encoding/json"
+ "math/big"
+ "sync"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/crypto"
+ "github.com/ethereum/go-ethereum/xeth"
+)
+
+type EthereumApi struct {
+ eth *xeth.XEth
+ xethMu sync.RWMutex
+}
+
+func NewEthereumApi(xeth *xeth.XEth) *EthereumApi {
+ api := &EthereumApi{
+ eth: xeth,
+ }
+
+ return api
+}
+
+func (api *EthereumApi) xeth() *xeth.XEth {
+ api.xethMu.RLock()
+ defer api.xethMu.RUnlock()
+
+ return api.eth
+}
+
+func (api *EthereumApi) xethAtStateNum(num int64) *xeth.XEth {
+ return api.xeth().AtStateNum(num)
+}
+
+func (api *EthereumApi) GetRequestReply(req *RpcRequest, reply *interface{}) error {
+ // Spec at https://github.com/ethereum/wiki/wiki/JSON-RPC
+ rpclogger.Debugf("%s %s", req.Method, req.Params)
+
+ switch req.Method {
+ case "web3_sha3":
+ args := new(Sha3Args)
+ if err := json.Unmarshal(req.Params, &args); err != nil {
+ return err
+ }
+ *reply = common.ToHex(crypto.Sha3(common.FromHex(args.Data)))
+ case "web3_clientVersion":
+ *reply = api.xeth().ClientVersion()
+ case "net_version":
+ *reply = api.xeth().NetworkVersion()
+ case "net_listening":
+ *reply = api.xeth().IsListening()
+ case "net_peerCount":
+ v := api.xeth().PeerCount()
+ *reply = common.ToHex(big.NewInt(int64(v)).Bytes())
+ case "eth_protocolVersion":
+ *reply = api.xeth().EthVersion()
+ case "eth_coinbase":
+ // TODO handling of empty coinbase due to lack of accounts
+ res := api.xeth().Coinbase()
+ if res == "0x" || res == "0x0" {
+ *reply = nil
+ } else {
+ *reply = res
+ }
+ case "eth_mining":
+ *reply = api.xeth().IsMining()
+ case "eth_gasPrice":
+ v := xeth.DefaultGas()
+ *reply = common.ToHex(v.Bytes())
+ case "eth_accounts":
+ *reply = api.xeth().Accounts()
+ case "eth_blockNumber":
+ v := api.xeth().CurrentBlock().Number()
+ *reply = common.ToHex(v.Bytes())
+ case "eth_getBalance":
+ args := new(GetBalanceArgs)
+ if err := json.Unmarshal(req.Params, &args); err != nil {
+ return err
+ }
+
+ *reply = api.xethAtStateNum(args.BlockNumber).BalanceAt(args.Address)
+ //v := api.xethAtStateNum(args.BlockNumber).State().SafeGet(args.Address).Balance()
+ //*reply = common.ToHex(v.Bytes())
+ case "eth_getStorage", "eth_storageAt":
+ args := new(GetStorageArgs)
+ if err := json.Unmarshal(req.Params, &args); err != nil {
+ return err
+ }
+
+ *reply = api.xethAtStateNum(args.BlockNumber).State().SafeGet(args.Address).Storage()
+ case "eth_getStorageAt":
+ args := new(GetStorageAtArgs)
+ if err := json.Unmarshal(req.Params, &args); err != nil {
+ return err
+ }
+
+ *reply = api.xethAtStateNum(args.BlockNumber).StorageAt(args.Address, args.Key)
+ case "eth_getTransactionCount":
+ args := new(GetTxCountArgs)
+ if err := json.Unmarshal(req.Params, &args); err != nil {
+ return err
+ }
+
+ count := api.xethAtStateNum(args.BlockNumber).TxCountAt(args.Address)
+ *reply = common.ToHex(big.NewInt(int64(count)).Bytes())
+ case "eth_getBlockTransactionCountByHash":
+ args := new(HashArgs)
+ if err := json.Unmarshal(req.Params, &args); err != nil {
+ return err
+ }
+
+ block := NewBlockRes(api.xeth().EthBlockByHash(args.Hash), false)
+ *reply = common.ToHex(big.NewInt(int64(len(block.Transactions))).Bytes())
+ case "eth_getBlockTransactionCountByNumber":
+ args := new(BlockNumArg)
+ if err := json.Unmarshal(req.Params, &args); err != nil {
+ return err
+ }
+
+ block := NewBlockRes(api.xeth().EthBlockByNumber(args.BlockNumber), false)
+ *reply = common.ToHex(big.NewInt(int64(len(block.Transactions))).Bytes())
+ case "eth_getUncleCountByBlockHash":
+ args := new(HashArgs)
+ if err := json.Unmarshal(req.Params, &args); err != nil {
+ return err
+ }
+
+ block := api.xeth().EthBlockByHash(args.Hash)
+ br := NewBlockRes(block, false)
+ *reply = common.ToHex(big.NewInt(int64(len(br.Uncles))).Bytes())
+ case "eth_getUncleCountByBlockNumber":
+ args := new(BlockNumArg)
+ if err := json.Unmarshal(req.Params, &args); err != nil {
+ return err
+ }
+
+ block := api.xeth().EthBlockByNumber(args.BlockNumber)
+ br := NewBlockRes(block, false)
+ *reply = common.ToHex(big.NewInt(int64(len(br.Uncles))).Bytes())
+ case "eth_getData", "eth_getCode":
+ args := new(GetDataArgs)
+ if err := json.Unmarshal(req.Params, &args); err != nil {
+ return err
+ }
+ v := api.xethAtStateNum(args.BlockNumber).CodeAtBytes(args.Address)
+ *reply = newHexData(v)
+ case "eth_sendTransaction", "eth_transact":
+ args := new(NewTxArgs)
+ if err := json.Unmarshal(req.Params, &args); err != nil {
+ return err
+ }
+
+ v, err := api.xeth().Transact(args.From, args.To, args.Value.String(), args.Gas.String(), args.GasPrice.String(), args.Data)
+ if err != nil {
+ return err
+ }
+ *reply = v
+ case "eth_call":
+ args := new(CallArgs)
+ if err := json.Unmarshal(req.Params, &args); err != nil {
+ return err
+ }
+
+ v, err := api.xethAtStateNum(args.BlockNumber).Call(args.From, args.To, args.Value.String(), args.Gas.String(), args.GasPrice.String(), args.Data)
+ if err != nil {
+ return err
+ }
+
+ *reply = v
+ case "eth_flush":
+ return NewNotImplementedError(req.Method)
+ case "eth_getBlockByHash":
+ args := new(GetBlockByHashArgs)
+ if err := json.Unmarshal(req.Params, &args); err != nil {
+ return err
+ }
+
+ block := api.xeth().EthBlockByHash(args.BlockHash)
+ br := NewBlockRes(block, args.IncludeTxs)
+
+ *reply = br
+ case "eth_getBlockByNumber":
+ args := new(GetBlockByNumberArgs)
+ if err := json.Unmarshal(req.Params, &args); err != nil {
+ return err
+ }
+
+ block := api.xeth().EthBlockByNumber(args.BlockNumber)
+ br := NewBlockRes(block, args.IncludeTxs)
+
+ *reply = br
+ case "eth_getTransactionByHash":
+ // HashIndexArgs used, but only the "Hash" part we need.
+ args := new(HashIndexArgs)
+ if err := json.Unmarshal(req.Params, &args); err != nil {
+ }
+ tx, bhash, bnum, txi := api.xeth().EthTransactionByHash(args.Hash)
+ if tx != nil {
+ v := NewTransactionRes(tx)
+ v.BlockHash = newHexData(bhash)
+ v.BlockNumber = newHexNum(bnum)
+ v.TxIndex = newHexNum(txi)
+ *reply = v
+ }
+ case "eth_getTransactionByBlockHashAndIndex":
+ args := new(HashIndexArgs)
+ if err := json.Unmarshal(req.Params, &args); err != nil {
+ return err
+ }
+
+ block := api.xeth().EthBlockByHash(args.Hash)
+ br := NewBlockRes(block, true)
+
+ if args.Index >= int64(len(br.Transactions)) || args.Index < 0 {
+ return NewValidationError("Index", "does not exist")
+ }
+ *reply = br.Transactions[args.Index]
+ case "eth_getTransactionByBlockNumberAndIndex":
+ args := new(BlockNumIndexArgs)
+ if err := json.Unmarshal(req.Params, &args); err != nil {
+ return err
+ }
+
+ block := api.xeth().EthBlockByNumber(args.BlockNumber)
+ v := NewBlockRes(block, true)
+
+ if args.Index >= int64(len(v.Transactions)) || args.Index < 0 {
+ return NewValidationError("Index", "does not exist")
+ }
+ *reply = v.Transactions[args.Index]
+ case "eth_getUncleByBlockHashAndIndex":
+ args := new(HashIndexArgs)
+ if err := json.Unmarshal(req.Params, &args); err != nil {
+ return err
+ }
+
+ br := NewBlockRes(api.xeth().EthBlockByHash(args.Hash), false)
+ if br == nil {
+ *reply = nil
+ return nil
+ }
+
+ if args.Index >= int64(len(br.Uncles)) || args.Index < 0 {
+ return NewValidationError("Index", "does not exist")
+ }
+
+ uhash := br.Uncles[args.Index]
+ uncle := NewBlockRes(api.xeth().EthBlockByHash(uhash.String()), false)
+
+ *reply = uncle
+ case "eth_getUncleByBlockNumberAndIndex":
+ args := new(BlockNumIndexArgs)
+ if err := json.Unmarshal(req.Params, &args); err != nil {
+ return err
+ }
+
+ block := api.xeth().EthBlockByNumber(args.BlockNumber)
+ v := NewBlockRes(block, true)
+
+ if v == nil {
+ *reply = nil
+ return nil
+ }
+
+ if args.Index >= int64(len(v.Uncles)) || args.Index < 0 {
+ return NewValidationError("Index", "does not exist")
+ }
+
+ uhash := v.Uncles[args.Index]
+ uncle := NewBlockRes(api.xeth().EthBlockByHash(uhash.String()), false)
+
+ *reply = uncle
+ case "eth_getCompilers":
+ c := []string{""}
+ *reply = c
+ case "eth_compileSolidity", "eth_compileLLL", "eth_compileSerpent":
+ return NewNotImplementedError(req.Method)
+ case "eth_newFilter":
+ args := new(BlockFilterArgs)
+ if err := json.Unmarshal(req.Params, &args); err != nil {
+ return err
+ }
+
+ id := api.xeth().RegisterFilter(args.Earliest, args.Latest, args.Skip, args.Max, args.Address, args.Topics)
+ *reply = common.ToHex(big.NewInt(int64(id)).Bytes())
+ case "eth_newBlockFilter":
+ args := new(FilterStringArgs)
+ if err := json.Unmarshal(req.Params, &args); err != nil {
+ return err
+ }
+ id := api.xeth().NewFilterString(args.Word)
+ *reply = common.ToHex(big.NewInt(int64(id)).Bytes())
+ case "eth_uninstallFilter":
+ args := new(FilterIdArgs)
+ if err := json.Unmarshal(req.Params, &args); err != nil {
+ return err
+ }
+ *reply = api.xeth().UninstallFilter(args.Id)
+ case "eth_getFilterChanges":
+ args := new(FilterIdArgs)
+ if err := json.Unmarshal(req.Params, &args); err != nil {
+ return err
+ }
+ *reply = NewLogsRes(api.xeth().FilterChanged(args.Id))
+ case "eth_getFilterLogs":
+ args := new(FilterIdArgs)
+ if err := json.Unmarshal(req.Params, &args); err != nil {
+ return err
+ }
+ *reply = NewLogsRes(api.xeth().Logs(args.Id))
+ case "eth_getLogs":
+ args := new(BlockFilterArgs)
+ if err := json.Unmarshal(req.Params, &args); err != nil {
+ return err
+ }
+ *reply = NewLogsRes(api.xeth().AllLogs(args.Earliest, args.Latest, args.Skip, args.Max, args.Address, args.Topics))
+ case "eth_getWork":
+ api.xeth().SetMining(true)
+ *reply = api.xeth().RemoteMining().GetWork()
+ case "eth_submitWork":
+ args := new(SubmitWorkArgs)
+ if err := json.Unmarshal(req.Params, &args); err != nil {
+ return err
+ }
+ *reply = api.xeth().RemoteMining().SubmitWork(args.Nonce, common.HexToHash(args.Digest), common.HexToHash(args.Header))
+ case "db_putString":
+ args := new(DbArgs)
+ if err := json.Unmarshal(req.Params, &args); err != nil {
+ return err
+ }
+
+ if err := args.requirements(); err != nil {
+ return err
+ }
+
+ api.xeth().DbPut([]byte(args.Database+args.Key), args.Value)
+
+ *reply = true
+ case "db_getString":
+ args := new(DbArgs)
+ if err := json.Unmarshal(req.Params, &args); err != nil {
+ return err
+ }
+
+ if err := args.requirements(); err != nil {
+ return err
+ }
+
+ res, _ := api.xeth().DbGet([]byte(args.Database + args.Key))
+ *reply = string(res)
+ case "db_putHex":
+ args := new(DbHexArgs)
+ if err := json.Unmarshal(req.Params, &args); err != nil {
+ return err
+ }
+
+ if err := args.requirements(); err != nil {
+ return err
+ }
+
+ api.xeth().DbPut([]byte(args.Database+args.Key), args.Value)
+ *reply = true
+ case "db_getHex":
+ args := new(DbHexArgs)
+ if err := json.Unmarshal(req.Params, &args); err != nil {
+ return err
+ }
+
+ if err := args.requirements(); err != nil {
+ return err
+ }
+
+ res, _ := api.xeth().DbGet([]byte(args.Database + args.Key))
+ *reply = common.ToHex(res)
+ case "shh_version":
+ *reply = api.xeth().WhisperVersion()
+ case "shh_post":
+ args := new(WhisperMessageArgs)
+ if err := json.Unmarshal(req.Params, &args); err != nil {
+ return err
+ }
+
+ err := api.xeth().Whisper().Post(args.Payload, args.To, args.From, args.Topics, args.Priority, args.Ttl)
+ if err != nil {
+ return err
+ }
+
+ *reply = true
+ case "shh_newIdentity":
+ *reply = api.xeth().Whisper().NewIdentity()
+ // case "shh_removeIdentity":
+ // args := new(WhisperIdentityArgs)
+ // if err := json.Unmarshal(req.Params, &args); err != nil {
+ // return err
+ // }
+ // *reply = api.xeth().Whisper().RemoveIdentity(args.Identity)
+ case "shh_hasIdentity":
+ args := new(WhisperIdentityArgs)
+ if err := json.Unmarshal(req.Params, &args); err != nil {
+ return err
+ }
+ *reply = api.xeth().Whisper().HasIdentity(args.Identity)
+ case "shh_newGroup", "shh_addToGroup":
+ return NewNotImplementedError(req.Method)
+ case "shh_newFilter":
+ args := new(WhisperFilterArgs)
+ if err := json.Unmarshal(req.Params, &args); err != nil {
+ return err
+ }
+ opts := new(xeth.Options)
+ // opts.From = args.From
+ opts.To = args.To
+ opts.Topics = args.Topics
+ id := api.xeth().NewWhisperFilter(opts)
+ *reply = common.ToHex(big.NewInt(int64(id)).Bytes())
+ case "shh_uninstallFilter":
+ args := new(FilterIdArgs)
+ if err := json.Unmarshal(req.Params, &args); err != nil {
+ return err
+ }
+ *reply = api.xeth().UninstallWhisperFilter(args.Id)
+ case "shh_getFilterChanges":
+ args := new(FilterIdArgs)
+ if err := json.Unmarshal(req.Params, &args); err != nil {
+ return err
+ }
+ *reply = api.xeth().MessagesChanged(args.Id)
+ case "shh_getMessages":
+ args := new(FilterIdArgs)
+ if err := json.Unmarshal(req.Params, &args); err != nil {
+ return err
+ }
+ *reply = api.xeth().Whisper().Messages(args.Id)
+
+ // case "eth_register":
+ // // Placeholder for actual type
+ // args := new(HashIndexArgs)
+ // if err := json.Unmarshal(req.Params, &args); err != nil {
+ // return err
+ // }
+ // *reply = api.xeth().Register(args.Hash)
+ // case "eth_unregister":
+ // args := new(HashIndexArgs)
+ // if err := json.Unmarshal(req.Params, &args); err != nil {
+ // return err
+ // }
+ // *reply = api.xeth().Unregister(args.Hash)
+ // case "eth_watchTx":
+ // args := new(HashIndexArgs)
+ // if err := json.Unmarshal(req.Params, &args); err != nil {
+ // return err
+ // }
+ // *reply = api.xeth().PullWatchTx(args.Hash)
+ default:
+ return NewNotImplementedError(req.Method)
+ }
+
+ rpclogger.DebugDetailf("Reply: %T %s", reply, reply)
+ return nil
+}
diff --git a/rpc/api_test.go b/rpc/api_test.go
new file mode 100644
index 000000000..ac9b67fac
--- /dev/null
+++ b/rpc/api_test.go
@@ -0,0 +1,101 @@
+package rpc
+
+import (
+ "encoding/json"
+ // "sync"
+ "testing"
+ // "time"
+
+ // "github.com/ethereum/go-ethereum/xeth"
+)
+
+func TestWeb3Sha3(t *testing.T) {
+ jsonstr := `{"jsonrpc":"2.0","method":"web3_sha3","params":["0x68656c6c6f20776f726c64"],"id":64}`
+ expected := "0x47173285a8d7341e5e972fc677286384f802f8ef42a5ec5f03bbfa254cb01fad"
+
+ api := &EthereumApi{}
+
+ var req RpcRequest
+ json.Unmarshal([]byte(jsonstr), &req)
+
+ var response interface{}
+ _ = api.GetRequestReply(&req, &response)
+
+ if response.(string) != expected {
+ t.Errorf("Expected %s got %s", expected, response)
+ }
+}
+
+// func TestDbStr(t *testing.T) {
+// jsonput := `{"jsonrpc":"2.0","method":"db_putString","params":["testDB","myKey","myString"],"id":64}`
+// jsonget := `{"jsonrpc":"2.0","method":"db_getString","params":["testDB","myKey"],"id":64}`
+// expected := "myString"
+
+// xeth := &xeth.XEth{}
+// api := NewEthereumApi(xeth)
+// var response interface{}
+
+// var req RpcRequest
+// json.Unmarshal([]byte(jsonput), &req)
+// _ = api.GetRequestReply(&req, &response)
+
+// json.Unmarshal([]byte(jsonget), &req)
+// _ = api.GetRequestReply(&req, &response)
+
+// if response.(string) != expected {
+// t.Errorf("Expected %s got %s", expected, response)
+// }
+// }
+
+// func TestDbHexStr(t *testing.T) {
+// jsonput := `{"jsonrpc":"2.0","method":"db_putHex","params":["testDB","beefKey","0xbeef"],"id":64}`
+// jsonget := `{"jsonrpc":"2.0","method":"db_getHex","params":["testDB","beefKey"],"id":64}`
+// expected := "0xbeef"
+
+// xeth := &xeth.XEth{}
+// api := NewEthereumApi(xeth)
+// defer api.db.Close()
+// var response interface{}
+
+// var req RpcRequest
+// json.Unmarshal([]byte(jsonput), &req)
+// _ = api.GetRequestReply(&req, &response)
+
+// json.Unmarshal([]byte(jsonget), &req)
+// _ = api.GetRequestReply(&req, &response)
+
+// if response.(string) != expected {
+// t.Errorf("Expected %s got %s", expected, response)
+// }
+// }
+
+// func TestFilterClose(t *testing.T) {
+// t.Skip()
+// api := &EthereumApi{
+// logs: make(map[int]*logFilter),
+// messages: make(map[int]*whisperFilter),
+// quit: make(chan struct{}),
+// }
+
+// filterTickerTime = 1
+// api.logs[0] = &logFilter{}
+// api.messages[0] = &whisperFilter{}
+// var wg sync.WaitGroup
+// wg.Add(1)
+// go api.start()
+// go func() {
+// select {
+// case <-time.After(500 * time.Millisecond):
+// api.stop()
+// wg.Done()
+// }
+// }()
+// wg.Wait()
+// if len(api.logs) != 0 {
+// t.Error("expected logs to be empty")
+// }
+
+// if len(api.messages) != 0 {
+// t.Error("expected messages to be empty")
+// }
+// }
diff --git a/rpc/args.go b/rpc/args.go
new file mode 100644
index 000000000..70618a01a
--- /dev/null
+++ b/rpc/args.go
@@ -0,0 +1,1080 @@
+package rpc
+
+import (
+ "encoding/json"
+ "fmt"
+ "math/big"
+
+ "github.com/ethereum/go-ethereum/common"
+)
+
+const (
+ defaultLogLimit = 100
+ defaultLogOffset = 0
+)
+
+func blockHeightFromJson(msg json.RawMessage, number *int64) error {
+ var raw interface{}
+ if err := json.Unmarshal(msg, &raw); err != nil {
+ return NewDecodeParamError(err.Error())
+ }
+ return blockHeight(raw, number)
+}
+
+func blockHeight(raw interface{}, number *int64) error {
+ // Parse as integer
+ num, ok := raw.(float64)
+ if ok {
+ *number = int64(num)
+ return nil
+ }
+
+ // Parse as string/hexstring
+ str, ok := raw.(string)
+ if !ok {
+ return NewInvalidTypeError("", "not a number or string")
+ }
+
+ switch str {
+ case "latest":
+ *number = -1
+ case "pending":
+ *number = -2
+ default:
+ *number = common.String2Big(str).Int64()
+ }
+
+ return nil
+}
+
+func numString(raw interface{}, number *int64) error {
+ // Parse as integer
+ num, ok := raw.(float64)
+ if ok {
+ *number = int64(num)
+ return nil
+ }
+
+ // Parse as string/hexstring
+ str, ok := raw.(string)
+ if !ok {
+ return NewInvalidTypeError("", "not a number or string")
+ }
+ *number = common.String2Big(str).Int64()
+
+ return nil
+}
+
+// func toNumber(v interface{}) (int64, error) {
+// var str string
+// if v != nil {
+// var ok bool
+// str, ok = v.(string)
+// if !ok {
+// return 0, errors.New("is not a string or undefined")
+// }
+// } else {
+// str = "latest"
+// }
+
+// switch str {
+// case "latest":
+// return -1, nil
+// default:
+// return int64(common.Big(v.(string)).Int64()), nil
+// }
+// }
+
+// func hashString(raw interface{}, hash *string) error {
+// argstr, ok := raw.(string)
+// if !ok {
+// return NewInvalidTypeError("", "not a string")
+// }
+// v := common.IsHex(argstr)
+// hash = &argstr
+
+// return nil
+// }
+
+type GetBlockByHashArgs struct {
+ BlockHash string
+ IncludeTxs bool
+}
+
+func (args *GetBlockByHashArgs) UnmarshalJSON(b []byte) (err error) {
+ var obj []interface{}
+
+ if err := json.Unmarshal(b, &obj); err != nil {
+ return NewDecodeParamError(err.Error())
+ }
+
+ if len(obj) < 2 {
+ return NewInsufficientParamsError(len(obj), 2)
+ }
+
+ argstr, ok := obj[0].(string)
+ if !ok {
+ return NewInvalidTypeError("blockHash", "not a string")
+ }
+ args.BlockHash = argstr
+
+ args.IncludeTxs = obj[1].(bool)
+
+ return nil
+}
+
+type GetBlockByNumberArgs struct {
+ BlockNumber int64
+ IncludeTxs bool
+}
+
+func (args *GetBlockByNumberArgs) UnmarshalJSON(b []byte) (err error) {
+ var obj []interface{}
+ if err := json.Unmarshal(b, &obj); err != nil {
+ return NewDecodeParamError(err.Error())
+ }
+
+ if len(obj) < 2 {
+ return NewInsufficientParamsError(len(obj), 2)
+ }
+
+ if v, ok := obj[0].(float64); ok {
+ args.BlockNumber = int64(v)
+ } else if v, ok := obj[0].(string); ok {
+ args.BlockNumber = common.Big(v).Int64()
+ } else {
+ return NewInvalidTypeError("blockNumber", "not a number or string")
+ }
+
+ args.IncludeTxs = obj[1].(bool)
+
+ return nil
+}
+
+type NewTxArgs struct {
+ From string
+ To string
+ Value *big.Int
+ Gas *big.Int
+ GasPrice *big.Int
+ Data string
+
+ BlockNumber int64
+}
+
+func (args *NewTxArgs) UnmarshalJSON(b []byte) (err error) {
+ var obj []json.RawMessage
+ var ext struct {
+ From string
+ To string
+ Value interface{}
+ Gas interface{}
+ GasPrice interface{}
+ Data string
+ }
+
+ // Decode byte slice to array of RawMessages
+ if err := json.Unmarshal(b, &obj); err != nil {
+ return NewDecodeParamError(err.Error())
+ }
+
+ // Check for sufficient params
+ if len(obj) < 1 {
+ return NewInsufficientParamsError(len(obj), 1)
+ }
+
+ // Decode 0th RawMessage to temporary struct
+ if err := json.Unmarshal(obj[0], &ext); err != nil {
+ return NewDecodeParamError(err.Error())
+ }
+
+ if len(ext.From) == 0 {
+ return NewValidationError("from", "is required")
+ }
+
+ args.From = ext.From
+ args.To = ext.To
+ args.Data = ext.Data
+
+ var num int64
+ if ext.Value == nil {
+ num = 0
+ } else {
+ if err := numString(ext.Value, &num); err != nil {
+ return err
+ }
+ }
+ args.Value = big.NewInt(num)
+
+ if ext.Gas == nil {
+ num = 0
+ } else {
+ if err := numString(ext.Gas, &num); err != nil {
+ return err
+ }
+ }
+ args.Gas = big.NewInt(num)
+
+ if ext.GasPrice == nil {
+ num = 0
+ } else {
+ if err := numString(ext.GasPrice, &num); err != nil {
+ return err
+ }
+ }
+ args.GasPrice = big.NewInt(num)
+
+ // Check for optional BlockNumber param
+ if len(obj) > 1 {
+ if err := blockHeightFromJson(obj[1], &args.BlockNumber); err != nil {
+ return err
+ }
+ } else {
+ args.BlockNumber = -1
+ }
+
+ return nil
+}
+
+type CallArgs struct {
+ From string
+ To string
+ Value *big.Int
+ Gas *big.Int
+ GasPrice *big.Int
+ Data string
+
+ BlockNumber int64
+}
+
+func (args *CallArgs) UnmarshalJSON(b []byte) (err error) {
+ var obj []json.RawMessage
+ var ext struct {
+ From string
+ To string
+ Value interface{}
+ Gas interface{}
+ GasPrice interface{}
+ Data string
+ }
+
+ // Decode byte slice to array of RawMessages
+ if err := json.Unmarshal(b, &obj); err != nil {
+ return NewDecodeParamError(err.Error())
+ }
+
+ // Check for sufficient params
+ if len(obj) < 1 {
+ return NewInsufficientParamsError(len(obj), 1)
+ }
+
+ // Decode 0th RawMessage to temporary struct
+ if err := json.Unmarshal(obj[0], &ext); err != nil {
+ return NewDecodeParamError(err.Error())
+ }
+
+ if len(ext.From) == 0 {
+ return NewValidationError("from", "is required")
+ }
+ args.From = ext.From
+
+ if len(ext.To) == 0 {
+ return NewValidationError("to", "is required")
+ }
+ args.To = ext.To
+
+ var num int64
+ if ext.Value == nil {
+ num = int64(0)
+ } else {
+ if err := numString(ext.Value, &num); err != nil {
+ return err
+ }
+ }
+ args.Value = big.NewInt(num)
+
+ if ext.Gas == nil {
+ num = int64(0)
+ } else {
+ if err := numString(ext.Gas, &num); err != nil {
+ return err
+ }
+ }
+ args.Gas = big.NewInt(num)
+
+ if ext.GasPrice == nil {
+ num = int64(0)
+ } else {
+ if err := numString(ext.GasPrice, &num); err != nil {
+ return err
+ }
+ }
+ args.GasPrice = big.NewInt(num)
+
+ args.Data = ext.Data
+
+ // Check for optional BlockNumber param
+ if len(obj) > 1 {
+ if err := blockHeightFromJson(obj[1], &args.BlockNumber); err != nil {
+ return err
+ }
+ } else {
+ args.BlockNumber = -1
+ }
+
+ return nil
+}
+
+type GetStorageArgs struct {
+ Address string
+ BlockNumber int64
+}
+
+func (args *GetStorageArgs) UnmarshalJSON(b []byte) (err error) {
+ var obj []interface{}
+ if err := json.Unmarshal(b, &obj); err != nil {
+ return NewDecodeParamError(err.Error())
+ }
+
+ if len(obj) < 1 {
+ return NewInsufficientParamsError(len(obj), 1)
+ }
+
+ addstr, ok := obj[0].(string)
+ if !ok {
+ return NewInvalidTypeError("address", "not a string")
+ }
+ args.Address = addstr
+
+ if len(obj) > 1 {
+ if err := blockHeight(obj[1], &args.BlockNumber); err != nil {
+ return err
+ }
+ } else {
+ args.BlockNumber = -1
+ }
+
+ return nil
+}
+
+type GetStorageAtArgs struct {
+ Address string
+ Key string
+ BlockNumber int64
+}
+
+func (args *GetStorageAtArgs) UnmarshalJSON(b []byte) (err error) {
+ var obj []interface{}
+ if err := json.Unmarshal(b, &obj); err != nil {
+ return NewDecodeParamError(err.Error())
+ }
+
+ if len(obj) < 2 {
+ return NewInsufficientParamsError(len(obj), 2)
+ }
+
+ addstr, ok := obj[0].(string)
+ if !ok {
+ return NewInvalidTypeError("address", "not a string")
+ }
+ args.Address = addstr
+
+ keystr, ok := obj[1].(string)
+ if !ok {
+ return NewInvalidTypeError("key", "not a string")
+ }
+ args.Key = keystr
+
+ if len(obj) > 2 {
+ if err := blockHeight(obj[2], &args.BlockNumber); err != nil {
+ return err
+ }
+ } else {
+ args.BlockNumber = -1
+ }
+
+ return nil
+}
+
+type GetTxCountArgs struct {
+ Address string
+ BlockNumber int64
+}
+
+func (args *GetTxCountArgs) UnmarshalJSON(b []byte) (err error) {
+ var obj []interface{}
+ if err := json.Unmarshal(b, &obj); err != nil {
+ return NewDecodeParamError(err.Error())
+ }
+
+ if len(obj) < 1 {
+ return NewInsufficientParamsError(len(obj), 1)
+ }
+
+ addstr, ok := obj[0].(string)
+ if !ok {
+ return NewInvalidTypeError("address", "not a string")
+ }
+ args.Address = addstr
+
+ if len(obj) > 1 {
+ if err := blockHeight(obj[1], &args.BlockNumber); err != nil {
+ return err
+ }
+ } else {
+ args.BlockNumber = -1
+ }
+
+ return nil
+}
+
+type GetBalanceArgs struct {
+ Address string
+ BlockNumber int64
+}
+
+func (args *GetBalanceArgs) UnmarshalJSON(b []byte) (err error) {
+ var obj []interface{}
+ if err := json.Unmarshal(b, &obj); err != nil {
+ return NewDecodeParamError(err.Error())
+ }
+
+ if len(obj) < 1 {
+ return NewInsufficientParamsError(len(obj), 1)
+ }
+
+ addstr, ok := obj[0].(string)
+ if !ok {
+ return NewInvalidTypeError("address", "not a string")
+ }
+ args.Address = addstr
+
+ if len(obj) > 1 {
+ if err := blockHeight(obj[1], &args.BlockNumber); err != nil {
+ return err
+ }
+ } else {
+ args.BlockNumber = -1
+ }
+
+ return nil
+}
+
+type GetDataArgs struct {
+ Address string
+ BlockNumber int64
+}
+
+func (args *GetDataArgs) UnmarshalJSON(b []byte) (err error) {
+ var obj []interface{}
+ if err := json.Unmarshal(b, &obj); err != nil {
+ return NewDecodeParamError(err.Error())
+ }
+
+ if len(obj) < 1 {
+ return NewInsufficientParamsError(len(obj), 1)
+ }
+
+ addstr, ok := obj[0].(string)
+ if !ok {
+ return NewInvalidTypeError("address", "not a string")
+ }
+ args.Address = addstr
+
+ if len(obj) > 1 {
+ if err := blockHeight(obj[1], &args.BlockNumber); err != nil {
+ return err
+ }
+ } else {
+ args.BlockNumber = -1
+ }
+
+ return nil
+}
+
+type BlockNumArg struct {
+ BlockNumber int64
+}
+
+func (args *BlockNumArg) UnmarshalJSON(b []byte) (err error) {
+ var obj []interface{}
+ if err := json.Unmarshal(b, &obj); err != nil {
+ return NewDecodeParamError(err.Error())
+ }
+
+ if len(obj) < 1 {
+ return NewInsufficientParamsError(len(obj), 1)
+ }
+
+ if err := blockHeight(obj[0], &args.BlockNumber); err != nil {
+ return err
+ }
+
+ return nil
+}
+
+type BlockNumIndexArgs struct {
+ BlockNumber int64
+ Index int64
+}
+
+func (args *BlockNumIndexArgs) UnmarshalJSON(b []byte) (err error) {
+ var obj []interface{}
+ if err := json.Unmarshal(b, &obj); err != nil {
+ return NewDecodeParamError(err.Error())
+ }
+
+ if len(obj) < 2 {
+ return NewInsufficientParamsError(len(obj), 2)
+ }
+
+ if err := blockHeight(obj[0], &args.BlockNumber); err != nil {
+ return err
+ }
+
+ arg1, ok := obj[1].(string)
+ if !ok {
+ return NewInvalidTypeError("index", "not a string")
+ }
+ args.Index = common.Big(arg1).Int64()
+
+ return nil
+}
+
+type HashArgs struct {
+ Hash string
+}
+
+func (args *HashArgs) UnmarshalJSON(b []byte) (err error) {
+ var obj []interface{}
+ if err := json.Unmarshal(b, &obj); err != nil {
+ return NewDecodeParamError(err.Error())
+ }
+
+ if len(obj) < 1 {
+ return NewInsufficientParamsError(len(obj), 1)
+ }
+
+ arg0, ok := obj[0].(string)
+ if !ok {
+ return NewInvalidTypeError("hash", "not a string")
+ }
+ args.Hash = arg0
+
+ return nil
+}
+
+type HashIndexArgs struct {
+ Hash string
+ Index int64
+}
+
+func (args *HashIndexArgs) UnmarshalJSON(b []byte) (err error) {
+ var obj []interface{}
+ if err := json.Unmarshal(b, &obj); err != nil {
+ return NewDecodeParamError(err.Error())
+ }
+
+ if len(obj) < 2 {
+ return NewInsufficientParamsError(len(obj), 2)
+ }
+
+ arg0, ok := obj[0].(string)
+ if !ok {
+ return NewInvalidTypeError("hash", "not a string")
+ }
+ args.Hash = arg0
+
+ arg1, ok := obj[1].(string)
+ if !ok {
+ return NewInvalidTypeError("index", "not a string")
+ }
+ args.Index = common.Big(arg1).Int64()
+
+ return nil
+}
+
+type Sha3Args struct {
+ Data string
+}
+
+func (args *Sha3Args) UnmarshalJSON(b []byte) (err error) {
+ var obj []interface{}
+ if err := json.Unmarshal(b, &obj); err != nil {
+ return NewDecodeParamError(err.Error())
+ }
+
+ if len(obj) < 1 {
+ return NewInsufficientParamsError(len(obj), 1)
+ }
+
+ argstr, ok := obj[0].(string)
+ if !ok {
+ return NewInvalidTypeError("data", "is not a string")
+ }
+ args.Data = argstr
+ return nil
+}
+
+type BlockFilterArgs struct {
+ Earliest int64
+ Latest int64
+ Address []string
+ Topics [][]string
+ Skip int
+ Max int
+}
+
+func (args *BlockFilterArgs) UnmarshalJSON(b []byte) (err error) {
+ var obj []struct {
+ FromBlock interface{} `json:"fromBlock"`
+ ToBlock interface{} `json:"toBlock"`
+ Limit interface{} `json:"limit"`
+ Offset interface{} `json:"offset"`
+ Address interface{} `json:"address"`
+ Topics interface{} `json:"topics"`
+ }
+
+ if err = json.Unmarshal(b, &obj); err != nil {
+ return NewDecodeParamError(err.Error())
+ }
+
+ if len(obj) < 1 {
+ return NewInsufficientParamsError(len(obj), 1)
+ }
+
+ // args.Earliest, err = toNumber(obj[0].ToBlock)
+ // if err != nil {
+ // return NewDecodeParamError(fmt.Sprintf("FromBlock %v", err))
+ // }
+ // args.Latest, err = toNumber(obj[0].FromBlock)
+ // if err != nil {
+ // return NewDecodeParamError(fmt.Sprintf("ToBlock %v", err))
+
+ var num int64
+
+ // if blank then latest
+ if obj[0].FromBlock == nil {
+ num = -1
+ } else {
+ if err := blockHeight(obj[0].FromBlock, &num); err != nil {
+ return err
+ }
+ }
+ // if -2 or other "silly" number, use latest
+ if num < 0 {
+ args.Earliest = -1 //latest block
+ } else {
+ args.Earliest = num
+ }
+
+ // if blank than latest
+ if obj[0].ToBlock == nil {
+ num = -1
+ } else {
+ if err := blockHeight(obj[0].ToBlock, &num); err != nil {
+ return err
+ }
+ }
+ args.Latest = num
+
+ if obj[0].Limit == nil {
+ num = defaultLogLimit
+ } else {
+ if err := numString(obj[0].Limit, &num); err != nil {
+ return err
+ }
+ }
+ args.Max = int(num)
+
+ if obj[0].Offset == nil {
+ num = defaultLogOffset
+ } else {
+ if err := numString(obj[0].Offset, &num); err != nil {
+ return err
+ }
+ }
+ args.Skip = int(num)
+
+ if obj[0].Address != nil {
+ marg, ok := obj[0].Address.([]interface{})
+ if ok {
+ v := make([]string, len(marg))
+ for i, arg := range marg {
+ argstr, ok := arg.(string)
+ if !ok {
+ return NewInvalidTypeError(fmt.Sprintf("address[%d]", i), "is not a string")
+ }
+ v[i] = argstr
+ }
+ args.Address = v
+ } else {
+ argstr, ok := obj[0].Address.(string)
+ if ok {
+ v := make([]string, 1)
+ v[0] = argstr
+ args.Address = v
+ } else {
+ return NewInvalidTypeError("address", "is not a string or array")
+ }
+ }
+ }
+
+ if obj[0].Topics != nil {
+ other, ok := obj[0].Topics.([]interface{})
+ if ok {
+ topicdbl := make([][]string, len(other))
+ for i, iv := range other {
+ if argstr, ok := iv.(string); ok {
+ // Found a string, push into first element of array
+ topicsgl := make([]string, 1)
+ topicsgl[0] = argstr
+ topicdbl[i] = topicsgl
+ } else if argarray, ok := iv.([]interface{}); ok {
+ // Found an array of other
+ topicdbl[i] = make([]string, len(argarray))
+ for j, jv := range argarray {
+ if v, ok := jv.(string); ok {
+ topicdbl[i][j] = v
+ } else {
+ return NewInvalidTypeError(fmt.Sprintf("topic[%d][%d]", i, j), "is not a string")
+ }
+ }
+ } else {
+ return NewInvalidTypeError(fmt.Sprintf("topic[%d]", i), "not a string or array")
+ }
+ }
+ args.Topics = topicdbl
+ return nil
+ } else {
+ return NewInvalidTypeError("topic", "is not a string or array")
+ }
+ }
+
+ return nil
+}
+
+type DbArgs struct {
+ Database string
+ Key string
+ Value []byte
+}
+
+func (args *DbArgs) UnmarshalJSON(b []byte) (err error) {
+ var obj []interface{}
+ if err := json.Unmarshal(b, &obj); err != nil {
+ return NewDecodeParamError(err.Error())
+ }
+
+ if len(obj) < 2 {
+ return NewInsufficientParamsError(len(obj), 2)
+ }
+
+ var objstr string
+ var ok bool
+
+ if objstr, ok = obj[0].(string); !ok {
+ return NewInvalidTypeError("database", "not a string")
+ }
+ args.Database = objstr
+
+ if objstr, ok = obj[1].(string); !ok {
+ return NewInvalidTypeError("key", "not a string")
+ }
+ args.Key = objstr
+
+ if len(obj) > 2 {
+ objstr, ok = obj[2].(string)
+ if !ok {
+ return NewInvalidTypeError("value", "not a string")
+ }
+
+ args.Value = []byte(objstr)
+ }
+
+ return nil
+}
+
+func (a *DbArgs) requirements() error {
+ if len(a.Database) == 0 {
+ return NewValidationError("Database", "cannot be blank")
+ }
+ if len(a.Key) == 0 {
+ return NewValidationError("Key", "cannot be blank")
+ }
+ return nil
+}
+
+type DbHexArgs struct {
+ Database string
+ Key string
+ Value []byte
+}
+
+func (args *DbHexArgs) UnmarshalJSON(b []byte) (err error) {
+ var obj []interface{}
+ if err := json.Unmarshal(b, &obj); err != nil {
+ return NewDecodeParamError(err.Error())
+ }
+
+ if len(obj) < 2 {
+ return NewInsufficientParamsError(len(obj), 2)
+ }
+
+ var objstr string
+ var ok bool
+
+ if objstr, ok = obj[0].(string); !ok {
+ return NewInvalidTypeError("database", "not a string")
+ }
+ args.Database = objstr
+
+ if objstr, ok = obj[1].(string); !ok {
+ return NewInvalidTypeError("key", "not a string")
+ }
+ args.Key = objstr
+
+ if len(obj) > 2 {
+ objstr, ok = obj[2].(string)
+ if !ok {
+ return NewInvalidTypeError("value", "not a string")
+ }
+
+ args.Value = common.FromHex(objstr)
+ }
+
+ return nil
+}
+
+func (a *DbHexArgs) requirements() error {
+ if len(a.Database) == 0 {
+ return NewValidationError("Database", "cannot be blank")
+ }
+ if len(a.Key) == 0 {
+ return NewValidationError("Key", "cannot be blank")
+ }
+ return nil
+}
+
+type WhisperMessageArgs struct {
+ Payload string
+ To string
+ From string
+ Topics []string
+ Priority uint32
+ Ttl uint32
+}
+
+func (args *WhisperMessageArgs) UnmarshalJSON(b []byte) (err error) {
+ var obj []struct {
+ Payload string
+ To string
+ From string
+ Topics []string
+ Priority interface{}
+ Ttl interface{}
+ }
+
+ if err = json.Unmarshal(b, &obj); err != nil {
+ return NewDecodeParamError(err.Error())
+ }
+
+ if len(obj) < 1 {
+ return NewInsufficientParamsError(len(obj), 1)
+ }
+ args.Payload = obj[0].Payload
+ args.To = obj[0].To
+ args.From = obj[0].From
+ args.Topics = obj[0].Topics
+
+ var num int64
+ if err := numString(obj[0].Priority, &num); err != nil {
+ return err
+ }
+ args.Priority = uint32(num)
+
+ if err := numString(obj[0].Ttl, &num); err != nil {
+ return err
+ }
+ args.Ttl = uint32(num)
+
+ return nil
+}
+
+type CompileArgs struct {
+ Source string
+}
+
+func (args *CompileArgs) UnmarshalJSON(b []byte) (err error) {
+ var obj []interface{}
+ if err := json.Unmarshal(b, &obj); err != nil {
+ return NewDecodeParamError(err.Error())
+ }
+
+ if len(obj) < 1 {
+ return NewInsufficientParamsError(len(obj), 1)
+ }
+ argstr, ok := obj[0].(string)
+ if !ok {
+ return NewInvalidTypeError("arg0", "is not a string")
+ }
+ args.Source = argstr
+
+ return nil
+}
+
+type FilterStringArgs struct {
+ Word string
+}
+
+func (args *FilterStringArgs) UnmarshalJSON(b []byte) (err error) {
+ var obj []interface{}
+ if err := json.Unmarshal(b, &obj); err != nil {
+ return NewDecodeParamError(err.Error())
+ }
+
+ if len(obj) < 1 {
+ return NewInsufficientParamsError(len(obj), 1)
+ }
+
+ var argstr string
+ argstr, ok := obj[0].(string)
+ if !ok {
+ return NewInvalidTypeError("filter", "not a string")
+ }
+ switch argstr {
+ case "latest", "pending":
+ break
+ default:
+ return NewValidationError("Word", "Must be `latest` or `pending`")
+ }
+ args.Word = argstr
+ return nil
+}
+
+type FilterIdArgs struct {
+ Id int
+}
+
+func (args *FilterIdArgs) UnmarshalJSON(b []byte) (err error) {
+ var obj []interface{}
+ if err := json.Unmarshal(b, &obj); err != nil {
+ return NewDecodeParamError(err.Error())
+ }
+
+ if len(obj) < 1 {
+ return NewInsufficientParamsError(len(obj), 1)
+ }
+
+ var num int64
+ if err := numString(obj[0], &num); err != nil {
+ return err
+ }
+ args.Id = int(num)
+
+ return nil
+}
+
+type WhisperIdentityArgs struct {
+ Identity string
+}
+
+func (args *WhisperIdentityArgs) UnmarshalJSON(b []byte) (err error) {
+ var obj []interface{}
+ if err := json.Unmarshal(b, &obj); err != nil {
+ return NewDecodeParamError(err.Error())
+ }
+
+ if len(obj) < 1 {
+ return NewInsufficientParamsError(len(obj), 1)
+ }
+
+ argstr, ok := obj[0].(string)
+ if !ok {
+ return NewInvalidTypeError("arg0", "not a string")
+ }
+ // if !common.IsHex(argstr) {
+ // return NewValidationError("arg0", "not a hexstring")
+ // }
+ args.Identity = argstr
+
+ return nil
+}
+
+type WhisperFilterArgs struct {
+ To string `json:"to"`
+ From string
+ Topics []string
+}
+
+func (args *WhisperFilterArgs) UnmarshalJSON(b []byte) (err error) {
+ var obj []struct {
+ To interface{}
+ Topics []interface{}
+ }
+
+ if err = json.Unmarshal(b, &obj); err != nil {
+ return NewDecodeParamError(err.Error())
+ }
+
+ if len(obj) < 1 {
+ return NewInsufficientParamsError(len(obj), 1)
+ }
+
+ var argstr string
+ argstr, ok := obj[0].To.(string)
+ if !ok {
+ return NewInvalidTypeError("to", "is not a string")
+ }
+ args.To = argstr
+
+ t := make([]string, len(obj[0].Topics))
+ for i, j := range obj[0].Topics {
+ argstr, ok := j.(string)
+ if !ok {
+ return NewInvalidTypeError("topics["+string(i)+"]", "is not a string")
+ }
+ t[i] = argstr
+ }
+ args.Topics = t
+
+ return nil
+}
+
+type SubmitWorkArgs struct {
+ Nonce uint64
+ Header string
+ Digest string
+}
+
+func (args *SubmitWorkArgs) UnmarshalJSON(b []byte) (err error) {
+ var obj []interface{}
+ if err = json.Unmarshal(b, &obj); err != nil {
+ return NewDecodeParamError(err.Error())
+ }
+
+ if len(obj) < 3 {
+ return NewInsufficientParamsError(len(obj), 3)
+ }
+
+ var objstr string
+ var ok bool
+ if objstr, ok = obj[0].(string); !ok {
+ return NewInvalidTypeError("nonce", "not a string")
+ }
+
+ args.Nonce = common.String2Big(objstr).Uint64()
+ if objstr, ok = obj[1].(string); !ok {
+ return NewInvalidTypeError("header", "not a string")
+ }
+
+ args.Header = objstr
+
+ if objstr, ok = obj[2].(string); !ok {
+ return NewInvalidTypeError("digest", "not a string")
+ }
+
+ args.Digest = objstr
+
+ return nil
+}
diff --git a/rpc/args_test.go b/rpc/args_test.go
new file mode 100644
index 000000000..902f8013e
--- /dev/null
+++ b/rpc/args_test.go
@@ -0,0 +1,2173 @@
+package rpc
+
+import (
+ "bytes"
+ "encoding/json"
+ "fmt"
+ "math/big"
+ "testing"
+)
+
+func ExpectValidationError(err error) string {
+ var str string
+ switch err.(type) {
+ case nil:
+ str = "Expected error but didn't get one"
+ case *ValidationError:
+ break
+ default:
+ str = fmt.Sprintf("Expected *rpc.ValidationError but got %T with message `%s`", err, err.Error())
+ }
+ return str
+}
+
+func ExpectInvalidTypeError(err error) string {
+ var str string
+ switch err.(type) {
+ case nil:
+ str = "Expected error but didn't get one"
+ case *InvalidTypeError:
+ break
+ default:
+ str = fmt.Sprintf("Expected *rpc.InvalidTypeError but got %T with message `%s`", err, err.Error())
+ }
+ return str
+}
+
+func ExpectInsufficientParamsError(err error) string {
+ var str string
+ switch err.(type) {
+ case nil:
+ str = "Expected error but didn't get one"
+ case *InsufficientParamsError:
+ break
+ default:
+ str = fmt.Sprintf("Expected *rpc.InsufficientParamsError but got %T with message %s", err, err.Error())
+ }
+ return str
+}
+
+func ExpectDecodeParamError(err error) string {
+ var str string
+ switch err.(type) {
+ case nil:
+ str = "Expected error but didn't get one"
+ case *DecodeParamError:
+ break
+ default:
+ str = fmt.Sprintf("Expected *rpc.DecodeParamError but got %T with message `%s`", err, err.Error())
+ }
+ return str
+}
+
+func TestSha3(t *testing.T) {
+ input := `["0x68656c6c6f20776f726c64"]`
+ expected := "0x68656c6c6f20776f726c64"
+
+ args := new(Sha3Args)
+ json.Unmarshal([]byte(input), &args)
+
+ if args.Data != expected {
+ t.Error("got %s expected %s", input, expected)
+ }
+}
+
+func TestSha3ArgsInvalid(t *testing.T) {
+ input := `{}`
+
+ args := new(Sha3Args)
+ str := ExpectDecodeParamError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestSha3ArgsEmpty(t *testing.T) {
+ input := `[]`
+
+ args := new(Sha3Args)
+ str := ExpectInsufficientParamsError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+func TestSha3ArgsDataInvalid(t *testing.T) {
+ input := `[4]`
+
+ args := new(Sha3Args)
+ str := ExpectInvalidTypeError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestGetBalanceArgs(t *testing.T) {
+ input := `["0x407d73d8a49eeb85d32cf465507dd71d507100c1", "0x1f"]`
+ expected := new(GetBalanceArgs)
+ expected.Address = "0x407d73d8a49eeb85d32cf465507dd71d507100c1"
+ expected.BlockNumber = 31
+
+ args := new(GetBalanceArgs)
+ if err := json.Unmarshal([]byte(input), &args); err != nil {
+ t.Error(err)
+ }
+
+ if args.Address != expected.Address {
+ t.Errorf("Address should be %v but is %v", expected.Address, args.Address)
+ }
+
+ if args.BlockNumber != expected.BlockNumber {
+ t.Errorf("BlockNumber should be %v but is %v", expected.BlockNumber, args.BlockNumber)
+ }
+}
+
+func TestGetBalanceArgsLatest(t *testing.T) {
+ input := `["0x407d73d8a49eeb85d32cf465507dd71d507100c1", "latest"]`
+ expected := new(GetBalanceArgs)
+ expected.Address = "0x407d73d8a49eeb85d32cf465507dd71d507100c1"
+ expected.BlockNumber = -1
+
+ args := new(GetBalanceArgs)
+ if err := json.Unmarshal([]byte(input), &args); err != nil {
+ t.Error(err)
+ }
+
+ if args.Address != expected.Address {
+ t.Errorf("Address should be %v but is %v", expected.Address, args.Address)
+ }
+
+ if args.BlockNumber != expected.BlockNumber {
+ t.Errorf("BlockNumber should be %v but is %v", expected.BlockNumber, args.BlockNumber)
+ }
+}
+
+func TestGetBalanceArgsEmpty(t *testing.T) {
+ input := `[]`
+
+ args := new(GetBalanceArgs)
+ str := ExpectInsufficientParamsError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestGetBalanceArgsInvalid(t *testing.T) {
+ input := `6`
+
+ args := new(GetBalanceArgs)
+ str := ExpectDecodeParamError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestGetBalanceArgsBlockInvalid(t *testing.T) {
+ input := `["0x407d73d8a49eeb85d32cf465507dd71d507100c1", false]`
+
+ args := new(GetBalanceArgs)
+ str := ExpectInvalidTypeError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestGetBalanceArgsAddressInvalid(t *testing.T) {
+ input := `[-9, "latest"]`
+
+ args := new(GetBalanceArgs)
+ str := ExpectInvalidTypeError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestGetBlockByHashArgs(t *testing.T) {
+ input := `["0xe670ec64341771606e55d6b4ca35a1a6b75ee3d5145a99d05921026d1527331", true]`
+ expected := new(GetBlockByHashArgs)
+ expected.BlockHash = "0xe670ec64341771606e55d6b4ca35a1a6b75ee3d5145a99d05921026d1527331"
+ expected.IncludeTxs = true
+
+ args := new(GetBlockByHashArgs)
+ if err := json.Unmarshal([]byte(input), &args); err != nil {
+ t.Error(err)
+ }
+
+ if args.BlockHash != expected.BlockHash {
+ t.Errorf("BlockHash should be %v but is %v", expected.BlockHash, args.BlockHash)
+ }
+
+ if args.IncludeTxs != expected.IncludeTxs {
+ t.Errorf("IncludeTxs should be %v but is %v", expected.IncludeTxs, args.IncludeTxs)
+ }
+}
+
+func TestGetBlockByHashArgsEmpty(t *testing.T) {
+ input := `[]`
+
+ args := new(GetBlockByHashArgs)
+ str := ExpectInsufficientParamsError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestGetBlockByHashArgsInvalid(t *testing.T) {
+ input := `{}`
+
+ args := new(GetBlockByHashArgs)
+ str := ExpectDecodeParamError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestGetBlockByHashArgsHashInt(t *testing.T) {
+ input := `[8]`
+
+ args := new(GetBlockByHashArgs)
+ str := ExpectInsufficientParamsError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestGetBlockByNumberArgsBlockNum(t *testing.T) {
+ input := `[436, false]`
+ expected := new(GetBlockByNumberArgs)
+ expected.BlockNumber = 436
+ expected.IncludeTxs = false
+
+ args := new(GetBlockByNumberArgs)
+ if err := json.Unmarshal([]byte(input), &args); err != nil {
+ t.Error(err)
+ }
+
+ if args.BlockNumber != expected.BlockNumber {
+ t.Errorf("BlockNumber should be %v but is %v", expected.BlockNumber, args.BlockNumber)
+ }
+
+ if args.IncludeTxs != expected.IncludeTxs {
+ t.Errorf("IncludeTxs should be %v but is %v", expected.IncludeTxs, args.IncludeTxs)
+ }
+}
+
+func TestGetBlockByNumberArgsBlockHex(t *testing.T) {
+ input := `["0x1b4", false]`
+ expected := new(GetBlockByNumberArgs)
+ expected.BlockNumber = 436
+ expected.IncludeTxs = false
+
+ args := new(GetBlockByNumberArgs)
+ if err := json.Unmarshal([]byte(input), &args); err != nil {
+ t.Error(err)
+ }
+
+ if args.BlockNumber != expected.BlockNumber {
+ t.Errorf("BlockNumber should be %v but is %v", expected.BlockNumber, args.BlockNumber)
+ }
+
+ if args.IncludeTxs != expected.IncludeTxs {
+ t.Errorf("IncludeTxs should be %v but is %v", expected.IncludeTxs, args.IncludeTxs)
+ }
+}
+
+func TestGetBlockByNumberEmpty(t *testing.T) {
+ input := `[]`
+
+ args := new(GetBlockByNumberArgs)
+ str := ExpectInsufficientParamsError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestGetBlockByNumberShort(t *testing.T) {
+ input := `["0xbbb"]`
+
+ args := new(GetBlockByNumberArgs)
+ str := ExpectInsufficientParamsError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestGetBlockByNumberBool(t *testing.T) {
+ input := `[true, true]`
+
+ args := new(GetBlockByNumberArgs)
+ str := ExpectInvalidTypeError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+func TestGetBlockByNumberBlockObject(t *testing.T) {
+ input := `{}`
+
+ args := new(GetBlockByNumberArgs)
+ str := ExpectDecodeParamError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestNewTxArgs(t *testing.T) {
+ input := `[{"from": "0xb60e8dd61c5d32be8058bb8eb970870f07233155",
+ "to": "0xd46e8dd67c5d32be8058bb8eb970870f072445675",
+ "gas": "0x76c0",
+ "gasPrice": "0x9184e72a000",
+ "value": "0x9184e72a000",
+ "data": "0xd46e8dd67c5d32be8d46e8dd67c5d32be8058bb8eb970870f072445675058bb8eb970870f072445675"},
+ "0x10"]`
+ expected := new(NewTxArgs)
+ expected.From = "0xb60e8dd61c5d32be8058bb8eb970870f07233155"
+ expected.To = "0xd46e8dd67c5d32be8058bb8eb970870f072445675"
+ expected.Gas = big.NewInt(30400)
+ expected.GasPrice = big.NewInt(10000000000000)
+ expected.Value = big.NewInt(10000000000000)
+ expected.Data = "0xd46e8dd67c5d32be8d46e8dd67c5d32be8058bb8eb970870f072445675058bb8eb970870f072445675"
+ expected.BlockNumber = big.NewInt(16).Int64()
+
+ args := new(NewTxArgs)
+ if err := json.Unmarshal([]byte(input), &args); err != nil {
+ t.Error(err)
+ }
+
+ if expected.From != args.From {
+ t.Errorf("From shoud be %#v but is %#v", expected.From, args.From)
+ }
+
+ if expected.To != args.To {
+ t.Errorf("To shoud be %#v but is %#v", expected.To, args.To)
+ }
+
+ if bytes.Compare(expected.Gas.Bytes(), args.Gas.Bytes()) != 0 {
+ t.Errorf("Gas shoud be %#v but is %#v", expected.Gas.Bytes(), args.Gas.Bytes())
+ }
+
+ if bytes.Compare(expected.GasPrice.Bytes(), args.GasPrice.Bytes()) != 0 {
+ t.Errorf("GasPrice shoud be %#v but is %#v", expected.GasPrice, args.GasPrice)
+ }
+
+ if bytes.Compare(expected.Value.Bytes(), args.Value.Bytes()) != 0 {
+ t.Errorf("Value shoud be %#v but is %#v", expected.Value, args.Value)
+ }
+
+ if expected.Data != args.Data {
+ t.Errorf("Data shoud be %#v but is %#v", expected.Data, args.Data)
+ }
+
+ if expected.BlockNumber != args.BlockNumber {
+ t.Errorf("BlockNumber shoud be %#v but is %#v", expected.BlockNumber, args.BlockNumber)
+ }
+}
+
+func TestNewTxArgsInt(t *testing.T) {
+ input := `[{"from": "0xb60e8dd61c5d32be8058bb8eb970870f07233155",
+ "to": "0xd46e8dd67c5d32be8058bb8eb970870f072445675",
+ "gas": 100,
+ "gasPrice": 50,
+ "value": 8765456789,
+ "data": "0xd46e8dd67c5d32be8d46e8dd67c5d32be8058bb8eb970870f072445675058bb8eb970870f072445675"},
+ 5]`
+ expected := new(NewTxArgs)
+ expected.Gas = big.NewInt(100)
+ expected.GasPrice = big.NewInt(50)
+ expected.Value = big.NewInt(8765456789)
+ expected.BlockNumber = int64(5)
+
+ args := new(NewTxArgs)
+ if err := json.Unmarshal([]byte(input), &args); err != nil {
+ t.Error(err)
+ }
+
+ if bytes.Compare(expected.Gas.Bytes(), args.Gas.Bytes()) != 0 {
+ t.Errorf("Gas shoud be %v but is %v", expected.Gas, args.Gas)
+ }
+
+ if bytes.Compare(expected.GasPrice.Bytes(), args.GasPrice.Bytes()) != 0 {
+ t.Errorf("GasPrice shoud be %v but is %v", expected.GasPrice, args.GasPrice)
+ }
+
+ if bytes.Compare(expected.Value.Bytes(), args.Value.Bytes()) != 0 {
+ t.Errorf("Value shoud be %v but is %v", expected.Value, args.Value)
+ }
+
+ if expected.BlockNumber != args.BlockNumber {
+ t.Errorf("BlockNumber shoud be %v but is %v", expected.BlockNumber, args.BlockNumber)
+ }
+}
+
+func TestNewTxArgsBlockBool(t *testing.T) {
+ input := `[{"from": "0xb60e8dd61c5d32be8058bb8eb970870f07233155",
+ "to": "0xd46e8dd67c5d32be8058bb8eb970870f072445675",
+ "gas": "0x76c0",
+ "gasPrice": "0x9184e72a000",
+ "value": "0x9184e72a000",
+ "data": "0xd46e8dd67c5d32be8d46e8dd67c5d32be8058bb8eb970870f072445675058bb8eb970870f072445675"},
+ false]`
+
+ args := new(NewTxArgs)
+ str := ExpectInvalidTypeError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestNewTxArgsGasInvalid(t *testing.T) {
+ input := `[{"from": "0xb60e8dd61c5d32be8058bb8eb970870f07233155",
+ "to": "0xd46e8dd67c5d32be8058bb8eb970870f072445675",
+ "gas": false,
+ "gasPrice": "0x9184e72a000",
+ "value": "0x9184e72a000",
+ "data": "0xd46e8dd67c5d32be8d46e8dd67c5d32be8058bb8eb970870f072445675058bb8eb970870f072445675"
+ }]`
+
+ args := new(NewTxArgs)
+ str := ExpectInvalidTypeError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestNewTxArgsGaspriceInvalid(t *testing.T) {
+ input := `[{"from": "0xb60e8dd61c5d32be8058bb8eb970870f07233155",
+ "to": "0xd46e8dd67c5d32be8058bb8eb970870f072445675",
+ "gas": "0x76c0",
+ "gasPrice": false,
+ "value": "0x9184e72a000",
+ "data": "0xd46e8dd67c5d32be8d46e8dd67c5d32be8058bb8eb970870f072445675058bb8eb970870f072445675"
+ }]`
+
+ args := new(NewTxArgs)
+ str := ExpectInvalidTypeError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestNewTxArgsValueInvalid(t *testing.T) {
+ input := `[{"from": "0xb60e8dd61c5d32be8058bb8eb970870f07233155",
+ "to": "0xd46e8dd67c5d32be8058bb8eb970870f072445675",
+ "gas": "0x76c0",
+ "gasPrice": "0x9184e72a000",
+ "value": false,
+ "data": "0xd46e8dd67c5d32be8d46e8dd67c5d32be8058bb8eb970870f072445675058bb8eb970870f072445675"
+ }]`
+
+ args := new(NewTxArgs)
+ str := ExpectInvalidTypeError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestNewTxArgsGasMissing(t *testing.T) {
+ input := `[{"from": "0xb60e8dd61c5d32be8058bb8eb970870f07233155",
+ "to": "0xd46e8dd67c5d32be8058bb8eb970870f072445675",
+ "gasPrice": "0x9184e72a000",
+ "value": "0x9184e72a000",
+ "data": "0xd46e8dd67c5d32be8d46e8dd67c5d32be8058bb8eb970870f072445675058bb8eb970870f072445675"
+ }]`
+ expected := new(NewTxArgs)
+ expected.Gas = big.NewInt(0)
+
+ args := new(NewTxArgs)
+ if err := json.Unmarshal([]byte(input), &args); err != nil {
+ t.Error(err)
+ }
+
+ if bytes.Compare(expected.Gas.Bytes(), args.Gas.Bytes()) != 0 {
+ t.Errorf("Gas shoud be %v but is %v", expected.Gas, args.Gas)
+ }
+}
+
+func TestNewTxArgsBlockGaspriceMissing(t *testing.T) {
+ input := `[{
+ "from": "0xb60e8dd61c5d32be8058bb8eb970870f07233155",
+ "to": "0xd46e8dd67c5d32be8058bb8eb970870f072445675",
+ "gas": "0x76c0",
+ "value": "0x9184e72a000",
+ "data": "0xd46e8dd67c5d32be8d46e8dd67c5d32be8058bb8eb970870f072445675058bb8eb970870f072445675"
+ }]`
+ expected := new(NewTxArgs)
+ expected.GasPrice = big.NewInt(0)
+
+ args := new(NewTxArgs)
+ if err := json.Unmarshal([]byte(input), &args); err != nil {
+ t.Error(err)
+ }
+
+ if bytes.Compare(expected.GasPrice.Bytes(), args.GasPrice.Bytes()) != 0 {
+ t.Errorf("GasPrice shoud be %v but is %v", expected.GasPrice, args.GasPrice)
+ }
+
+}
+
+func TestNewTxArgsValueMissing(t *testing.T) {
+ input := `[{
+ "from": "0xb60e8dd61c5d32be8058bb8eb970870f07233155",
+ "to": "0xd46e8dd67c5d32be8058bb8eb970870f072445675",
+ "gas": "0x76c0",
+ "gasPrice": "0x9184e72a000",
+ "data": "0xd46e8dd67c5d32be8d46e8dd67c5d32be8058bb8eb970870f072445675058bb8eb970870f072445675"
+ }]`
+ expected := new(NewTxArgs)
+ expected.Value = big.NewInt(0)
+
+ args := new(NewTxArgs)
+ if err := json.Unmarshal([]byte(input), &args); err != nil {
+ t.Error(err)
+ }
+
+ if bytes.Compare(expected.Value.Bytes(), args.Value.Bytes()) != 0 {
+ t.Errorf("Value shoud be %v but is %v", expected.Value, args.Value)
+ }
+
+}
+
+func TestNewTxArgsEmpty(t *testing.T) {
+ input := `[]`
+
+ args := new(NewTxArgs)
+ str := ExpectInsufficientParamsError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestNewTxArgsInvalid(t *testing.T) {
+ input := `{}`
+
+ args := new(NewTxArgs)
+ str := ExpectDecodeParamError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+func TestNewTxArgsNotStrings(t *testing.T) {
+ input := `[{"from":6}]`
+
+ args := new(NewTxArgs)
+ str := ExpectDecodeParamError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestNewTxArgsFromEmpty(t *testing.T) {
+ input := `[{"to": "0xb60e8dd61c5d32be8058bb8eb970870f07233155"}]`
+
+ args := new(NewTxArgs)
+ str := ExpectValidationError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestCallArgs(t *testing.T) {
+ input := `[{"from": "0xb60e8dd61c5d32be8058bb8eb970870f07233155",
+ "to": "0xd46e8dd67c5d32be8058bb8eb970870f072445675",
+ "gas": "0x76c0",
+ "gasPrice": "0x9184e72a000",
+ "value": "0x9184e72a000",
+ "data": "0xd46e8dd67c5d32be8d46e8dd67c5d32be8058bb8eb970870f072445675058bb8eb970870f072445675"},
+ "0x10"]`
+ expected := new(CallArgs)
+ expected.From = "0xb60e8dd61c5d32be8058bb8eb970870f07233155"
+ expected.To = "0xd46e8dd67c5d32be8058bb8eb970870f072445675"
+ expected.Gas = big.NewInt(30400)
+ expected.GasPrice = big.NewInt(10000000000000)
+ expected.Value = big.NewInt(10000000000000)
+ expected.Data = "0xd46e8dd67c5d32be8d46e8dd67c5d32be8058bb8eb970870f072445675058bb8eb970870f072445675"
+ expected.BlockNumber = big.NewInt(16).Int64()
+
+ args := new(CallArgs)
+ if err := json.Unmarshal([]byte(input), &args); err != nil {
+ t.Error(err)
+ }
+
+ if expected.From != args.From {
+ t.Errorf("From shoud be %#v but is %#v", expected.From, args.From)
+ }
+
+ if expected.To != args.To {
+ t.Errorf("To shoud be %#v but is %#v", expected.To, args.To)
+ }
+
+ if bytes.Compare(expected.Gas.Bytes(), args.Gas.Bytes()) != 0 {
+ t.Errorf("Gas shoud be %#v but is %#v", expected.Gas.Bytes(), args.Gas.Bytes())
+ }
+
+ if bytes.Compare(expected.GasPrice.Bytes(), args.GasPrice.Bytes()) != 0 {
+ t.Errorf("GasPrice shoud be %#v but is %#v", expected.GasPrice, args.GasPrice)
+ }
+
+ if bytes.Compare(expected.Value.Bytes(), args.Value.Bytes()) != 0 {
+ t.Errorf("Value shoud be %#v but is %#v", expected.Value, args.Value)
+ }
+
+ if expected.Data != args.Data {
+ t.Errorf("Data shoud be %#v but is %#v", expected.Data, args.Data)
+ }
+
+ if expected.BlockNumber != args.BlockNumber {
+ t.Errorf("BlockNumber shoud be %#v but is %#v", expected.BlockNumber, args.BlockNumber)
+ }
+}
+
+func TestCallArgsInt(t *testing.T) {
+ input := `[{"from": "0xb60e8dd61c5d32be8058bb8eb970870f07233155",
+ "to": "0xd46e8dd67c5d32be8058bb8eb970870f072445675",
+ "gas": 100,
+ "gasPrice": 50,
+ "value": 8765456789,
+ "data": "0xd46e8dd67c5d32be8d46e8dd67c5d32be8058bb8eb970870f072445675058bb8eb970870f072445675"},
+ 5]`
+ expected := new(CallArgs)
+ expected.Gas = big.NewInt(100)
+ expected.GasPrice = big.NewInt(50)
+ expected.Value = big.NewInt(8765456789)
+ expected.BlockNumber = int64(5)
+
+ args := new(CallArgs)
+ if err := json.Unmarshal([]byte(input), &args); err != nil {
+ t.Error(err)
+ }
+
+ if bytes.Compare(expected.Gas.Bytes(), args.Gas.Bytes()) != 0 {
+ t.Errorf("Gas shoud be %v but is %v", expected.Gas, args.Gas)
+ }
+
+ if bytes.Compare(expected.GasPrice.Bytes(), args.GasPrice.Bytes()) != 0 {
+ t.Errorf("GasPrice shoud be %v but is %v", expected.GasPrice, args.GasPrice)
+ }
+
+ if bytes.Compare(expected.Value.Bytes(), args.Value.Bytes()) != 0 {
+ t.Errorf("Value shoud be %v but is %v", expected.Value, args.Value)
+ }
+
+ if expected.BlockNumber != args.BlockNumber {
+ t.Errorf("BlockNumber shoud be %v but is %v", expected.BlockNumber, args.BlockNumber)
+ }
+}
+
+func TestCallArgsBlockBool(t *testing.T) {
+ input := `[{"from": "0xb60e8dd61c5d32be8058bb8eb970870f07233155",
+ "to": "0xd46e8dd67c5d32be8058bb8eb970870f072445675",
+ "gas": "0x76c0",
+ "gasPrice": "0x9184e72a000",
+ "value": "0x9184e72a000",
+ "data": "0xd46e8dd67c5d32be8d46e8dd67c5d32be8058bb8eb970870f072445675058bb8eb970870f072445675"},
+ false]`
+
+ args := new(CallArgs)
+ str := ExpectInvalidTypeError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestCallArgsGasInvalid(t *testing.T) {
+ input := `[{"from": "0xb60e8dd61c5d32be8058bb8eb970870f07233155",
+ "to": "0xd46e8dd67c5d32be8058bb8eb970870f072445675",
+ "gas": false,
+ "gasPrice": "0x9184e72a000",
+ "value": "0x9184e72a000",
+ "data": "0xd46e8dd67c5d32be8d46e8dd67c5d32be8058bb8eb970870f072445675058bb8eb970870f072445675"
+ }]`
+
+ args := new(CallArgs)
+ str := ExpectInvalidTypeError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestCallArgsGaspriceInvalid(t *testing.T) {
+ input := `[{"from": "0xb60e8dd61c5d32be8058bb8eb970870f07233155",
+ "to": "0xd46e8dd67c5d32be8058bb8eb970870f072445675",
+ "gas": "0x76c0",
+ "gasPrice": false,
+ "value": "0x9184e72a000",
+ "data": "0xd46e8dd67c5d32be8d46e8dd67c5d32be8058bb8eb970870f072445675058bb8eb970870f072445675"
+ }]`
+
+ args := new(CallArgs)
+ str := ExpectInvalidTypeError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestCallArgsValueInvalid(t *testing.T) {
+ input := `[{"from": "0xb60e8dd61c5d32be8058bb8eb970870f07233155",
+ "to": "0xd46e8dd67c5d32be8058bb8eb970870f072445675",
+ "gas": "0x76c0",
+ "gasPrice": "0x9184e72a000",
+ "value": false,
+ "data": "0xd46e8dd67c5d32be8d46e8dd67c5d32be8058bb8eb970870f072445675058bb8eb970870f072445675"
+ }]`
+
+ args := new(CallArgs)
+ str := ExpectInvalidTypeError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestCallArgsGasMissing(t *testing.T) {
+ input := `[{"from": "0xb60e8dd61c5d32be8058bb8eb970870f07233155",
+ "to": "0xd46e8dd67c5d32be8058bb8eb970870f072445675",
+ "gasPrice": "0x9184e72a000",
+ "value": "0x9184e72a000",
+ "data": "0xd46e8dd67c5d32be8d46e8dd67c5d32be8058bb8eb970870f072445675058bb8eb970870f072445675"
+ }]`
+
+ args := new(CallArgs)
+ if err := json.Unmarshal([]byte(input), &args); err != nil {
+ t.Error(err)
+ }
+
+ expected := new(CallArgs)
+ expected.Gas = big.NewInt(0)
+
+ if bytes.Compare(expected.Gas.Bytes(), args.Gas.Bytes()) != 0 {
+ t.Errorf("Gas shoud be %v but is %v", expected.Gas, args.Gas)
+ }
+
+}
+
+func TestCallArgsBlockGaspriceMissing(t *testing.T) {
+ input := `[{
+ "from": "0xb60e8dd61c5d32be8058bb8eb970870f07233155",
+ "to": "0xd46e8dd67c5d32be8058bb8eb970870f072445675",
+ "gas": "0x76c0",
+ "value": "0x9184e72a000",
+ "data": "0xd46e8dd67c5d32be8d46e8dd67c5d32be8058bb8eb970870f072445675058bb8eb970870f072445675"
+ }]`
+
+ args := new(CallArgs)
+ if err := json.Unmarshal([]byte(input), &args); err != nil {
+ t.Error(err)
+ }
+
+ expected := new(CallArgs)
+ expected.GasPrice = big.NewInt(0)
+
+ if bytes.Compare(expected.GasPrice.Bytes(), args.GasPrice.Bytes()) != 0 {
+ t.Errorf("GasPrice shoud be %v but is %v", expected.GasPrice, args.GasPrice)
+ }
+}
+
+func TestCallArgsValueMissing(t *testing.T) {
+ input := `[{
+ "from": "0xb60e8dd61c5d32be8058bb8eb970870f07233155",
+ "to": "0xd46e8dd67c5d32be8058bb8eb970870f072445675",
+ "gas": "0x76c0",
+ "gasPrice": "0x9184e72a000",
+ "data": "0xd46e8dd67c5d32be8d46e8dd67c5d32be8058bb8eb970870f072445675058bb8eb970870f072445675"
+ }]`
+
+ args := new(CallArgs)
+ if err := json.Unmarshal([]byte(input), &args); err != nil {
+ t.Error(err)
+ }
+
+ expected := new(CallArgs)
+ expected.Value = big.NewInt(int64(0))
+
+ if bytes.Compare(expected.Value.Bytes(), args.Value.Bytes()) != 0 {
+ t.Errorf("GasPrice shoud be %v but is %v", expected.Value, args.Value)
+ }
+}
+
+func TestCallArgsEmpty(t *testing.T) {
+ input := `[]`
+
+ args := new(CallArgs)
+ str := ExpectInsufficientParamsError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestCallArgsInvalid(t *testing.T) {
+ input := `{}`
+
+ args := new(CallArgs)
+ str := ExpectDecodeParamError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+func TestCallArgsNotStrings(t *testing.T) {
+ input := `[{"from":6}]`
+
+ args := new(CallArgs)
+ str := ExpectDecodeParamError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestCallArgsFromEmpty(t *testing.T) {
+ input := `[{"to": "0xb60e8dd61c5d32be8058bb8eb970870f07233155"}]`
+
+ args := new(CallArgs)
+ str := ExpectValidationError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestCallArgsToEmpty(t *testing.T) {
+ input := `[{"from": "0xb60e8dd61c5d32be8058bb8eb970870f07233155"}]`
+
+ args := new(CallArgs)
+ str := ExpectValidationError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestGetStorageArgs(t *testing.T) {
+ input := `["0x407d73d8a49eeb85d32cf465507dd71d507100c1", "latest"]`
+ expected := new(GetStorageArgs)
+ expected.Address = "0x407d73d8a49eeb85d32cf465507dd71d507100c1"
+ expected.BlockNumber = -1
+
+ args := new(GetStorageArgs)
+ if err := json.Unmarshal([]byte(input), &args); err != nil {
+ t.Error(err)
+ }
+
+ if expected.Address != args.Address {
+ t.Errorf("Address shoud be %#v but is %#v", expected.Address, args.Address)
+ }
+
+ if expected.BlockNumber != args.BlockNumber {
+ t.Errorf("BlockNumber shoud be %#v but is %#v", expected.BlockNumber, args.BlockNumber)
+ }
+}
+
+func TestGetStorageInvalidArgs(t *testing.T) {
+ input := `{}`
+
+ args := new(GetStorageArgs)
+ str := ExpectDecodeParamError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestGetStorageInvalidBlockheight(t *testing.T) {
+ input := `["0x407d73d8a49eeb85d32cf465507dd71d507100c1", {}]`
+
+ args := new(GetStorageArgs)
+ str := ExpectInvalidTypeError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestGetStorageEmptyArgs(t *testing.T) {
+ input := `[]`
+
+ args := new(GetStorageArgs)
+ str := ExpectInsufficientParamsError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestGetStorageAddressInt(t *testing.T) {
+ input := `[32456785432456, "latest"]`
+
+ args := new(GetStorageArgs)
+ str := ExpectInvalidTypeError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestGetStorageAtArgs(t *testing.T) {
+ input := `["0x407d73d8a49eeb85d32cf465507dd71d507100c1", "0x0", "0x2"]`
+ expected := new(GetStorageAtArgs)
+ expected.Address = "0x407d73d8a49eeb85d32cf465507dd71d507100c1"
+ expected.Key = "0x0"
+ expected.BlockNumber = 2
+
+ args := new(GetStorageAtArgs)
+ if err := json.Unmarshal([]byte(input), &args); err != nil {
+ t.Error(err)
+ }
+
+ if expected.Address != args.Address {
+ t.Errorf("Address shoud be %#v but is %#v", expected.Address, args.Address)
+ }
+
+ if expected.Key != args.Key {
+ t.Errorf("Address shoud be %#v but is %#v", expected.Address, args.Address)
+ }
+
+ if expected.BlockNumber != args.BlockNumber {
+ t.Errorf("BlockNumber shoud be %#v but is %#v", expected.BlockNumber, args.BlockNumber)
+ }
+}
+
+func TestGetStorageAtEmptyArgs(t *testing.T) {
+ input := `[]`
+
+ args := new(GetStorageAtArgs)
+ str := ExpectInsufficientParamsError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestGetStorageAtArgsInvalid(t *testing.T) {
+ input := `{}`
+
+ args := new(GetStorageAtArgs)
+ str := ExpectDecodeParamError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestGetStorageAtArgsAddressNotString(t *testing.T) {
+ input := `[true, "0x0", "0x2"]`
+
+ args := new(GetStorageAtArgs)
+ str := ExpectInvalidTypeError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestGetStorageAtArgsKeyNotString(t *testing.T) {
+ input := `["0x407d73d8a49eeb85d32cf465507dd71d507100c1", true, "0x2"]`
+
+ args := new(GetStorageAtArgs)
+ str := ExpectInvalidTypeError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestGetStorageAtArgsValueNotString(t *testing.T) {
+ input := `["0x407d73d8a49eeb85d32cf465507dd71d507100c1", "0x1", true]`
+
+ args := new(GetStorageAtArgs)
+ str := ExpectInvalidTypeError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestGetTxCountArgs(t *testing.T) {
+ input := `["0x407d73d8a49eeb85d32cf465507dd71d507100c1", "pending"]`
+ expected := new(GetTxCountArgs)
+ expected.Address = "0x407d73d8a49eeb85d32cf465507dd71d507100c1"
+ expected.BlockNumber = -2
+
+ args := new(GetTxCountArgs)
+ if err := json.Unmarshal([]byte(input), &args); err != nil {
+ t.Error(err)
+ }
+
+ if expected.Address != args.Address {
+ t.Errorf("Address shoud be %#v but is %#v", expected.Address, args.Address)
+ }
+
+ if expected.BlockNumber != args.BlockNumber {
+ t.Errorf("BlockNumber shoud be %#v but is %#v", expected.BlockNumber, args.BlockNumber)
+ }
+}
+
+func TestGetTxCountEmptyArgs(t *testing.T) {
+ input := `[]`
+
+ args := new(GetTxCountArgs)
+ str := ExpectInsufficientParamsError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestGetTxCountEmptyArgsInvalid(t *testing.T) {
+ input := `false`
+
+ args := new(GetTxCountArgs)
+ str := ExpectDecodeParamError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestGetTxCountAddressNotString(t *testing.T) {
+ input := `[false, "pending"]`
+
+ args := new(GetTxCountArgs)
+ str := ExpectInvalidTypeError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestGetTxCountBlockheightInvalid(t *testing.T) {
+ input := `["0x407d73d8a49eeb85d32cf465507dd71d507100c1", {}]`
+
+ args := new(GetTxCountArgs)
+ str := ExpectInvalidTypeError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestGetDataArgs(t *testing.T) {
+ input := `["0xd5677cf67b5aa051bb40496e68ad359eb97cfbf8", "latest"]`
+ expected := new(GetDataArgs)
+ expected.Address = "0xd5677cf67b5aa051bb40496e68ad359eb97cfbf8"
+ expected.BlockNumber = -1
+
+ args := new(GetDataArgs)
+ if err := json.Unmarshal([]byte(input), &args); err != nil {
+ t.Error(err)
+ }
+
+ if expected.Address != args.Address {
+ t.Errorf("Address shoud be %#v but is %#v", expected.Address, args.Address)
+ }
+
+ if expected.BlockNumber != args.BlockNumber {
+ t.Errorf("BlockNumber shoud be %#v but is %#v", expected.BlockNumber, args.BlockNumber)
+ }
+}
+
+func TestGetDataArgsEmpty(t *testing.T) {
+ input := `[]`
+
+ args := new(GetDataArgs)
+ str := ExpectInsufficientParamsError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestGetDataArgsInvalid(t *testing.T) {
+ input := `{}`
+
+ args := new(GetDataArgs)
+ str := ExpectDecodeParamError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestGetDataArgsAddressNotString(t *testing.T) {
+ input := `[12, "latest"]`
+
+ args := new(GetDataArgs)
+ str := ExpectInvalidTypeError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestGetDataArgsBlocknumberNotString(t *testing.T) {
+ input := `["0xd5677cf67b5aa051bb40496e68ad359eb97cfbf8", false]`
+
+ args := new(GetDataArgs)
+ str := ExpectInvalidTypeError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestBlockFilterArgs(t *testing.T) {
+ input := `[{
+ "fromBlock": "0x1",
+ "toBlock": "0x2",
+ "limit": "0x3",
+ "offset": "0x0",
+ "address": "0xd5677cf67b5aa051bb40496e68ad359eb97cfbf8",
+ "topics":
+ [
+ ["0xAA", "0xBB"],
+ ["0xCC", "0xDD"]
+ ]
+ }]`
+
+ expected := new(BlockFilterArgs)
+ expected.Earliest = 1
+ expected.Latest = 2
+ expected.Max = 3
+ expected.Skip = 0
+ expected.Address = []string{"0xd5677cf67b5aa051bb40496e68ad359eb97cfbf8"}
+ expected.Topics = [][]string{
+ []string{"0xAA", "0xBB"},
+ []string{"0xCC", "0xDD"},
+ }
+
+ args := new(BlockFilterArgs)
+ if err := json.Unmarshal([]byte(input), &args); err != nil {
+ t.Error(err)
+ }
+
+ if expected.Earliest != args.Earliest {
+ t.Errorf("Earliest shoud be %#v but is %#v", expected.Earliest, args.Earliest)
+ }
+
+ if expected.Latest != args.Latest {
+ t.Errorf("Latest shoud be %#v but is %#v", expected.Latest, args.Latest)
+ }
+
+ if expected.Max != args.Max {
+ t.Errorf("Max shoud be %#v but is %#v", expected.Max, args.Max)
+ }
+
+ if expected.Skip != args.Skip {
+ t.Errorf("Skip shoud be %#v but is %#v", expected.Skip, args.Skip)
+ }
+
+ if expected.Address[0] != args.Address[0] {
+ t.Errorf("Address shoud be %#v but is %#v", expected.Address, args.Address)
+ }
+
+ if expected.Topics[0][0] != args.Topics[0][0] {
+ t.Errorf("Topics shoud be %#v but is %#v", expected.Topics, args.Topics)
+ }
+ if expected.Topics[0][1] != args.Topics[0][1] {
+ t.Errorf("Topics shoud be %#v but is %#v", expected.Topics, args.Topics)
+ }
+ if expected.Topics[1][0] != args.Topics[1][0] {
+ t.Errorf("Topics shoud be %#v but is %#v", expected.Topics, args.Topics)
+ }
+ if expected.Topics[1][1] != args.Topics[1][1] {
+ t.Errorf("Topics shoud be %#v but is %#v", expected.Topics, args.Topics)
+ }
+
+}
+
+func TestBlockFilterArgsDefaults(t *testing.T) {
+ input := `[{
+ "address": ["0xd5677cf67b5aa051bb40496e68ad359eb97cfbf8"],
+ "topics": ["0xAA","0xBB"]
+ }]`
+ expected := new(BlockFilterArgs)
+ expected.Earliest = -1
+ expected.Latest = -1
+ expected.Max = 100
+ expected.Skip = 0
+ expected.Address = []string{"0xd5677cf67b5aa051bb40496e68ad359eb97cfbf8"}
+ expected.Topics = [][]string{[]string{"0xAA"}, []string{"0xBB"}}
+
+ args := new(BlockFilterArgs)
+ if err := json.Unmarshal([]byte(input), &args); err != nil {
+ t.Error(err)
+ }
+
+ if expected.Earliest != args.Earliest {
+ t.Errorf("Earliest shoud be %#v but is %#v", expected.Earliest, args.Earliest)
+ }
+
+ if expected.Latest != args.Latest {
+ t.Errorf("Latest shoud be %#v but is %#v", expected.Latest, args.Latest)
+ }
+
+ if expected.Max != args.Max {
+ t.Errorf("Max shoud be %#v but is %#v", expected.Max, args.Max)
+ }
+
+ if expected.Skip != args.Skip {
+ t.Errorf("Skip shoud be %#v but is %#v", expected.Skip, args.Skip)
+ }
+
+ if expected.Address[0] != args.Address[0] {
+ t.Errorf("Address shoud be %#v but is %#v", expected.Address, args.Address)
+ }
+
+ if expected.Topics[0][0] != args.Topics[0][0] {
+ t.Errorf("Topics shoud be %#v but is %#v", expected.Topics, args.Topics)
+ }
+
+ if expected.Topics[1][0] != args.Topics[1][0] {
+ t.Errorf("Topics shoud be %#v but is %#v", expected.Topics, args.Topics)
+ }
+}
+
+func TestBlockFilterArgsWords(t *testing.T) {
+ input := `[{
+ "fromBlock": "latest",
+ "toBlock": "pending"
+ }]`
+ expected := new(BlockFilterArgs)
+ expected.Earliest = -1
+ expected.Latest = -2
+
+ args := new(BlockFilterArgs)
+ if err := json.Unmarshal([]byte(input), &args); err != nil {
+ t.Error(err)
+ }
+
+ if expected.Earliest != args.Earliest {
+ t.Errorf("Earliest shoud be %#v but is %#v", expected.Earliest, args.Earliest)
+ }
+
+ if expected.Latest != args.Latest {
+ t.Errorf("Latest shoud be %#v but is %#v", expected.Latest, args.Latest)
+ }
+}
+
+func TestBlockFilterArgsInvalid(t *testing.T) {
+ input := `{}`
+
+ args := new(BlockFilterArgs)
+ str := ExpectDecodeParamError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestBlockFilterArgsFromBool(t *testing.T) {
+ input := `[{
+ "fromBlock": true,
+ "toBlock": "pending"
+ }]`
+
+ args := new(BlockFilterArgs)
+ str := ExpectInvalidTypeError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestBlockFilterArgsToBool(t *testing.T) {
+ input := `[{
+ "fromBlock": "pending",
+ "toBlock": true
+ }]`
+
+ args := new(BlockFilterArgs)
+ str := ExpectInvalidTypeError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestBlockFilterArgsEmptyArgs(t *testing.T) {
+ input := `[]`
+
+ args := new(BlockFilterArgs)
+ err := json.Unmarshal([]byte(input), &args)
+ if err == nil {
+ t.Error("Expected error but didn't get one")
+ }
+}
+
+func TestBlockFilterArgsLimitInvalid(t *testing.T) {
+ input := `[{"limit": false}]`
+
+ args := new(BlockFilterArgs)
+ str := ExpectInvalidTypeError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestBlockFilterArgsOffsetInvalid(t *testing.T) {
+ input := `[{"offset": true}]`
+
+ args := new(BlockFilterArgs)
+ str := ExpectInvalidTypeError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestBlockFilterArgsAddressInt(t *testing.T) {
+ input := `[{
+ "address": 1,
+ "topics": "0x12341234"}]`
+
+ args := new(BlockFilterArgs)
+ str := ExpectInvalidTypeError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestBlockFilterArgsAddressSliceInt(t *testing.T) {
+ input := `[{
+ "address": [1],
+ "topics": "0x12341234"}]`
+
+ args := new(BlockFilterArgs)
+ str := ExpectInvalidTypeError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestBlockFilterArgsTopicInt(t *testing.T) {
+ input := `[{
+ "address": ["0xd5677cf67b5aa051bb40496e68ad359eb97cfbf8"],
+ "topics": 1}]`
+
+ args := new(BlockFilterArgs)
+ str := ExpectInvalidTypeError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestBlockFilterArgsTopicSliceInt(t *testing.T) {
+ input := `[{
+ "address": "0xd5677cf67b5aa051bb40496e68ad359eb97cfbf8",
+ "topics": [1]}]`
+
+ args := new(BlockFilterArgs)
+ str := ExpectInvalidTypeError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestBlockFilterArgsTopicSliceInt2(t *testing.T) {
+ input := `[{
+ "address": "0xd5677cf67b5aa051bb40496e68ad359eb97cfbf8",
+ "topics": ["0xAA", [1]]}]`
+
+ args := new(BlockFilterArgs)
+ str := ExpectInvalidTypeError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestBlockFilterArgsTopicComplex(t *testing.T) {
+ input := `[{
+ "address": "0xd5677cf67b5aa051bb40496e68ad359eb97cfbf8",
+ "topics": ["0xAA", ["0xBB", "0xCC"]]
+ }]`
+
+ args := new(BlockFilterArgs)
+ if err := json.Unmarshal([]byte(input), &args); err != nil {
+ t.Error(err)
+ fmt.Printf("%v\n", args)
+ return
+ }
+
+ if args.Topics[0][0] != "0xAA" {
+ t.Errorf("Topic should be %s but is %s", "0xAA", args.Topics[0][0])
+ }
+
+ if args.Topics[1][0] != "0xBB" {
+ t.Errorf("Topic should be %s but is %s", "0xBB", args.Topics[0][0])
+ }
+
+ if args.Topics[1][1] != "0xCC" {
+ t.Errorf("Topic should be %s but is %s", "0xCC", args.Topics[0][0])
+ }
+}
+
+func TestDbArgs(t *testing.T) {
+ input := `["testDB","myKey","0xbeef"]`
+ expected := new(DbArgs)
+ expected.Database = "testDB"
+ expected.Key = "myKey"
+ expected.Value = []byte("0xbeef")
+
+ args := new(DbArgs)
+ if err := json.Unmarshal([]byte(input), &args); err != nil {
+ t.Error(err)
+ }
+
+ if err := args.requirements(); err != nil {
+ t.Error(err)
+ }
+
+ if expected.Database != args.Database {
+ t.Errorf("Database shoud be %#v but is %#v", expected.Database, args.Database)
+ }
+
+ if expected.Key != args.Key {
+ t.Errorf("Key shoud be %#v but is %#v", expected.Key, args.Key)
+ }
+
+ if bytes.Compare(expected.Value, args.Value) != 0 {
+ t.Errorf("Value shoud be %#v but is %#v", expected.Value, args.Value)
+ }
+}
+
+func TestDbArgsInvalid(t *testing.T) {
+ input := `{}`
+
+ args := new(DbArgs)
+ str := ExpectDecodeParamError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestDbArgsEmpty(t *testing.T) {
+ input := `[]`
+
+ args := new(DbArgs)
+ str := ExpectInsufficientParamsError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestDbArgsDatabaseType(t *testing.T) {
+ input := `[true, "keyval", "valval"]`
+
+ args := new(DbArgs)
+ str := ExpectInvalidTypeError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestDbArgsKeyType(t *testing.T) {
+ input := `["dbval", 3, "valval"]`
+
+ args := new(DbArgs)
+ str := ExpectInvalidTypeError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestDbArgsValType(t *testing.T) {
+ input := `["dbval", "keyval", {}]`
+
+ args := new(DbArgs)
+ str := ExpectInvalidTypeError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestDbArgsDatabaseEmpty(t *testing.T) {
+ input := `["", "keyval", "valval"]`
+
+ args := new(DbArgs)
+ if err := json.Unmarshal([]byte(input), &args); err != nil {
+ t.Error(err.Error())
+ }
+
+ str := ExpectValidationError(args.requirements())
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestDbArgsKeyEmpty(t *testing.T) {
+ input := `["dbval", "", "valval"]`
+
+ args := new(DbArgs)
+ if err := json.Unmarshal([]byte(input), &args); err != nil {
+ t.Error(err.Error())
+ }
+
+ str := ExpectValidationError(args.requirements())
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestDbHexArgs(t *testing.T) {
+ input := `["testDB","myKey","0xbeef"]`
+ expected := new(DbHexArgs)
+ expected.Database = "testDB"
+ expected.Key = "myKey"
+ expected.Value = []byte{0xbe, 0xef}
+
+ args := new(DbHexArgs)
+ if err := json.Unmarshal([]byte(input), &args); err != nil {
+ t.Error(err)
+ }
+
+ if err := args.requirements(); err != nil {
+ t.Error(err)
+ }
+
+ if expected.Database != args.Database {
+ t.Errorf("Database shoud be %#v but is %#v", expected.Database, args.Database)
+ }
+
+ if expected.Key != args.Key {
+ t.Errorf("Key shoud be %#v but is %#v", expected.Key, args.Key)
+ }
+
+ if bytes.Compare(expected.Value, args.Value) != 0 {
+ t.Errorf("Value shoud be %#v but is %#v", expected.Value, args.Value)
+ }
+}
+
+func TestDbHexArgsInvalid(t *testing.T) {
+ input := `{}`
+
+ args := new(DbHexArgs)
+ str := ExpectDecodeParamError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestDbHexArgsEmpty(t *testing.T) {
+ input := `[]`
+
+ args := new(DbHexArgs)
+ str := ExpectInsufficientParamsError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestDbHexArgsDatabaseType(t *testing.T) {
+ input := `[true, "keyval", "valval"]`
+
+ args := new(DbHexArgs)
+ str := ExpectInvalidTypeError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestDbHexArgsKeyType(t *testing.T) {
+ input := `["dbval", 3, "valval"]`
+
+ args := new(DbHexArgs)
+ str := ExpectInvalidTypeError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestDbHexArgsValType(t *testing.T) {
+ input := `["dbval", "keyval", {}]`
+
+ args := new(DbHexArgs)
+ str := ExpectInvalidTypeError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestDbHexArgsDatabaseEmpty(t *testing.T) {
+ input := `["", "keyval", "valval"]`
+
+ args := new(DbHexArgs)
+ if err := json.Unmarshal([]byte(input), &args); err != nil {
+ t.Error(err.Error())
+ }
+
+ str := ExpectValidationError(args.requirements())
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestDbHexArgsKeyEmpty(t *testing.T) {
+ input := `["dbval", "", "valval"]`
+
+ args := new(DbHexArgs)
+ if err := json.Unmarshal([]byte(input), &args); err != nil {
+ t.Error(err.Error())
+ }
+
+ str := ExpectValidationError(args.requirements())
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestWhisperMessageArgs(t *testing.T) {
+ input := `[{"from":"0xc931d93e97ab07fe42d923478ba2465f2",
+ "topics": ["0x68656c6c6f20776f726c64"],
+ "payload":"0x68656c6c6f20776f726c64",
+ "ttl": "0x64",
+ "priority": "0x64"}]`
+ expected := new(WhisperMessageArgs)
+ expected.From = "0xc931d93e97ab07fe42d923478ba2465f2"
+ expected.To = ""
+ expected.Payload = "0x68656c6c6f20776f726c64"
+ expected.Priority = 100
+ expected.Ttl = 100
+ // expected.Topics = []string{"0x68656c6c6f20776f726c64"}
+
+ args := new(WhisperMessageArgs)
+ if err := json.Unmarshal([]byte(input), &args); err != nil {
+ t.Error(err)
+ }
+
+ if expected.From != args.From {
+ t.Errorf("From shoud be %#v but is %#v", expected.From, args.From)
+ }
+
+ if expected.To != args.To {
+ t.Errorf("To shoud be %#v but is %#v", expected.To, args.To)
+ }
+
+ if expected.Payload != args.Payload {
+ t.Errorf("Value shoud be %#v but is %#v", expected.Payload, args.Payload)
+ }
+
+ if expected.Ttl != args.Ttl {
+ t.Errorf("Ttl shoud be %#v but is %#v", expected.Ttl, args.Ttl)
+ }
+
+ if expected.Priority != args.Priority {
+ t.Errorf("Priority shoud be %#v but is %#v", expected.Priority, args.Priority)
+ }
+
+ // if expected.Topics != args.Topics {
+ // t.Errorf("Topic shoud be %#v but is %#v", expected.Topic, args.Topic)
+ // }
+}
+
+func TestWhisperMessageArgsInt(t *testing.T) {
+ input := `[{"from":"0xc931d93e97ab07fe42d923478ba2465f2",
+ "topics": ["0x68656c6c6f20776f726c64"],
+ "payload":"0x68656c6c6f20776f726c64",
+ "ttl": 12,
+ "priority": 16}]`
+ expected := new(WhisperMessageArgs)
+ expected.From = "0xc931d93e97ab07fe42d923478ba2465f2"
+ expected.To = ""
+ expected.Payload = "0x68656c6c6f20776f726c64"
+ expected.Priority = 16
+ expected.Ttl = 12
+ // expected.Topics = []string{"0x68656c6c6f20776f726c64"}
+
+ args := new(WhisperMessageArgs)
+ if err := json.Unmarshal([]byte(input), &args); err != nil {
+ t.Error(err)
+ }
+
+ if expected.From != args.From {
+ t.Errorf("From shoud be %#v but is %#v", expected.From, args.From)
+ }
+
+ if expected.To != args.To {
+ t.Errorf("To shoud be %#v but is %#v", expected.To, args.To)
+ }
+
+ if expected.Payload != args.Payload {
+ t.Errorf("Value shoud be %#v but is %#v", expected.Payload, args.Payload)
+ }
+
+ if expected.Ttl != args.Ttl {
+ t.Errorf("Ttl shoud be %v but is %v", expected.Ttl, args.Ttl)
+ }
+
+ if expected.Priority != args.Priority {
+ t.Errorf("Priority shoud be %v but is %v", expected.Priority, args.Priority)
+ }
+
+ // if expected.Topics != args.Topics {
+ // t.Errorf("Topic shoud be %#v but is %#v", expected.Topic, args.Topic)
+ // }
+}
+
+func TestWhisperMessageArgsInvalid(t *testing.T) {
+ input := `{}`
+
+ args := new(WhisperMessageArgs)
+ str := ExpectDecodeParamError(json.Unmarshal([]byte(input), args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestWhisperMessageArgsEmpty(t *testing.T) {
+ input := `[]`
+
+ args := new(WhisperMessageArgs)
+ str := ExpectInsufficientParamsError(json.Unmarshal([]byte(input), args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestWhisperMessageArgsTtlBool(t *testing.T) {
+ input := `[{"from":"0xc931d93e97ab07fe42d923478ba2465f2",
+ "topics": ["0x68656c6c6f20776f726c64"],
+ "payload":"0x68656c6c6f20776f726c64",
+ "ttl": true,
+ "priority": "0x64"}]`
+ args := new(WhisperMessageArgs)
+ str := ExpectInvalidTypeError(json.Unmarshal([]byte(input), args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestWhisperMessageArgsPriorityBool(t *testing.T) {
+ input := `[{"from":"0xc931d93e97ab07fe42d923478ba2465f2",
+ "topics": ["0x68656c6c6f20776f726c64"],
+ "payload":"0x68656c6c6f20776f726c64",
+ "ttl": "0x12",
+ "priority": true}]`
+ args := new(WhisperMessageArgs)
+ str := ExpectInvalidTypeError(json.Unmarshal([]byte(input), args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestFilterIdArgs(t *testing.T) {
+ input := `["0x7"]`
+ expected := new(FilterIdArgs)
+ expected.Id = 7
+
+ args := new(FilterIdArgs)
+ if err := json.Unmarshal([]byte(input), &args); err != nil {
+ t.Error(err)
+ }
+
+ if expected.Id != args.Id {
+ t.Errorf("Id shoud be %#v but is %#v", expected.Id, args.Id)
+ }
+}
+
+func TestFilterIdArgsInvalid(t *testing.T) {
+ input := `{}`
+
+ args := new(FilterIdArgs)
+ str := ExpectDecodeParamError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Errorf(str)
+ }
+}
+
+func TestFilterIdArgsEmpty(t *testing.T) {
+ input := `[]`
+
+ args := new(FilterIdArgs)
+ str := ExpectInsufficientParamsError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Errorf(str)
+ }
+}
+
+func TestFilterIdArgsBool(t *testing.T) {
+ input := `[true]`
+
+ args := new(FilterIdArgs)
+ str := ExpectInvalidTypeError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Errorf(str)
+ }
+}
+
+func TestWhisperFilterArgs(t *testing.T) {
+ input := `[{"topics": ["0x68656c6c6f20776f726c64"], "to": "0x34ag445g3455b34"}]`
+ expected := new(WhisperFilterArgs)
+ expected.To = "0x34ag445g3455b34"
+ expected.Topics = []string{"0x68656c6c6f20776f726c64"}
+
+ args := new(WhisperFilterArgs)
+ if err := json.Unmarshal([]byte(input), &args); err != nil {
+ t.Error(err)
+ }
+
+ if expected.To != args.To {
+ t.Errorf("To shoud be %#v but is %#v", expected.To, args.To)
+ }
+
+ // if expected.Topics != args.Topics {
+ // t.Errorf("Topics shoud be %#v but is %#v", expected.Topics, args.Topics)
+ // }
+}
+
+func TestWhisperFilterArgsInvalid(t *testing.T) {
+ input := `{}`
+
+ args := new(WhisperFilterArgs)
+ str := ExpectDecodeParamError(json.Unmarshal([]byte(input), args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestWhisperFilterArgsEmpty(t *testing.T) {
+ input := `[]`
+
+ args := new(WhisperFilterArgs)
+ str := ExpectInsufficientParamsError(json.Unmarshal([]byte(input), args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestWhisperFilterArgsToBool(t *testing.T) {
+ input := `[{"topics": ["0x68656c6c6f20776f726c64"], "to": false}]`
+
+ args := new(WhisperFilterArgs)
+ str := ExpectInvalidTypeError(json.Unmarshal([]byte(input), args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestWhisperFilterArgsTopicInt(t *testing.T) {
+ input := `[{"topics": [6], "to": "0x34ag445g3455b34"}]`
+
+ args := new(WhisperFilterArgs)
+ str := ExpectInvalidTypeError(json.Unmarshal([]byte(input), args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestCompileArgs(t *testing.T) {
+ input := `["contract test { function multiply(uint a) returns(uint d) { return a * 7; } }"]`
+ expected := new(CompileArgs)
+ expected.Source = `contract test { function multiply(uint a) returns(uint d) { return a * 7; } }`
+
+ args := new(CompileArgs)
+ if err := json.Unmarshal([]byte(input), &args); err != nil {
+ t.Error(err)
+ }
+
+ if expected.Source != args.Source {
+ t.Errorf("Source shoud be %#v but is %#v", expected.Source, args.Source)
+ }
+}
+
+func TestCompileArgsInvalid(t *testing.T) {
+ input := `{}`
+
+ args := new(CompileArgs)
+ str := ExpectDecodeParamError(json.Unmarshal([]byte(input), args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestCompileArgsEmpty(t *testing.T) {
+ input := `[]`
+
+ args := new(CompileArgs)
+ str := ExpectInsufficientParamsError(json.Unmarshal([]byte(input), args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestCompileArgsBool(t *testing.T) {
+ input := `[false]`
+
+ args := new(CompileArgs)
+ str := ExpectInvalidTypeError(json.Unmarshal([]byte(input), args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestFilterStringArgs(t *testing.T) {
+ input := `["pending"]`
+ expected := new(FilterStringArgs)
+ expected.Word = "pending"
+
+ args := new(FilterStringArgs)
+ if err := json.Unmarshal([]byte(input), &args); err != nil {
+ t.Error(err)
+ }
+
+ if expected.Word != args.Word {
+ t.Errorf("Word shoud be %#v but is %#v", expected.Word, args.Word)
+ }
+}
+
+func TestFilterStringEmptyArgs(t *testing.T) {
+ input := `[]`
+
+ args := new(FilterStringArgs)
+ str := ExpectInsufficientParamsError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Errorf(str)
+ }
+}
+
+func TestFilterStringInvalidArgs(t *testing.T) {
+ input := `{}`
+
+ args := new(FilterStringArgs)
+ str := ExpectDecodeParamError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Errorf(str)
+ }
+}
+
+func TestFilterStringWordInt(t *testing.T) {
+ input := `[7]`
+
+ args := new(FilterStringArgs)
+ str := ExpectInvalidTypeError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Errorf(str)
+ }
+}
+
+func TestFilterStringWordWrong(t *testing.T) {
+ input := `["foo"]`
+
+ args := new(FilterStringArgs)
+ str := ExpectValidationError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Errorf(str)
+ }
+}
+
+func TestWhisperIdentityArgs(t *testing.T) {
+ input := `["0xc931d93e97ab07fe42d923478ba2465f283"]`
+ expected := new(WhisperIdentityArgs)
+ expected.Identity = "0xc931d93e97ab07fe42d923478ba2465f283"
+
+ args := new(WhisperIdentityArgs)
+ if err := json.Unmarshal([]byte(input), &args); err != nil {
+ t.Error(err)
+ }
+
+ if expected.Identity != args.Identity {
+ t.Errorf("Identity shoud be %#v but is %#v", expected.Identity, args.Identity)
+ }
+}
+
+func TestWhisperIdentityArgsInvalid(t *testing.T) {
+ input := `{}`
+
+ args := new(WhisperIdentityArgs)
+ str := ExpectDecodeParamError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Errorf(str)
+ }
+}
+
+func TestWhisperIdentityArgsEmpty(t *testing.T) {
+ input := `[]`
+
+ args := new(WhisperIdentityArgs)
+ str := ExpectInsufficientParamsError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Errorf(str)
+ }
+}
+
+func TestWhisperIdentityArgsInt(t *testing.T) {
+ input := `[4]`
+
+ args := new(WhisperIdentityArgs)
+ str := ExpectInvalidTypeError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Errorf(str)
+ }
+}
+
+func TestBlockNumIndexArgs(t *testing.T) {
+ input := `["0x29a", "0x0"]`
+ expected := new(BlockNumIndexArgs)
+ expected.BlockNumber = 666
+ expected.Index = 0
+
+ args := new(BlockNumIndexArgs)
+ if err := json.Unmarshal([]byte(input), &args); err != nil {
+ t.Error(err)
+ }
+
+ if expected.BlockNumber != args.BlockNumber {
+ t.Errorf("BlockNumber shoud be %#v but is %#v", expected.BlockNumber, args.BlockNumber)
+ }
+
+ if expected.Index != args.Index {
+ t.Errorf("Index shoud be %#v but is %#v", expected.Index, args.Index)
+ }
+}
+
+func TestBlockNumIndexArgsEmpty(t *testing.T) {
+ input := `[]`
+
+ args := new(BlockNumIndexArgs)
+ str := ExpectInsufficientParamsError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestBlockNumIndexArgsInvalid(t *testing.T) {
+ input := `"foo"`
+
+ args := new(BlockNumIndexArgs)
+ str := ExpectDecodeParamError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestBlockNumIndexArgsBlocknumInvalid(t *testing.T) {
+ input := `[{}, "0x1"]`
+
+ args := new(BlockNumIndexArgs)
+ str := ExpectInvalidTypeError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestBlockNumIndexArgsIndexInvalid(t *testing.T) {
+ input := `["0x29a", 1]`
+
+ args := new(BlockNumIndexArgs)
+ str := ExpectInvalidTypeError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestHashIndexArgs(t *testing.T) {
+ input := `["0xc6ef2fc5426d6ad6fd9e2a26abeab0aa2411b7ab17f30a99d3cb96aed1d1055b", "0x1"]`
+ expected := new(HashIndexArgs)
+ expected.Hash = "0xc6ef2fc5426d6ad6fd9e2a26abeab0aa2411b7ab17f30a99d3cb96aed1d1055b"
+ expected.Index = 1
+
+ args := new(HashIndexArgs)
+ if err := json.Unmarshal([]byte(input), &args); err != nil {
+ t.Error(err)
+ }
+
+ if expected.Hash != args.Hash {
+ t.Errorf("Hash shoud be %#v but is %#v", expected.Hash, args.Hash)
+ }
+
+ if expected.Index != args.Index {
+ t.Errorf("Index shoud be %#v but is %#v", expected.Index, args.Index)
+ }
+}
+
+func TestHashIndexArgsEmpty(t *testing.T) {
+ input := `[]`
+
+ args := new(HashIndexArgs)
+ str := ExpectInsufficientParamsError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestHashIndexArgsInvalid(t *testing.T) {
+ input := `{}`
+
+ args := new(HashIndexArgs)
+ str := ExpectDecodeParamError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestHashIndexArgsInvalidHash(t *testing.T) {
+ input := `[7, "0x1"]`
+
+ args := new(HashIndexArgs)
+ str := ExpectInvalidTypeError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestHashIndexArgsInvalidIndex(t *testing.T) {
+ input := `["0xc6ef2fc5426d6ad6fd9e2a26abeab0aa2411b7ab17f30a99d3cb96aed1d1055b", false]`
+
+ args := new(HashIndexArgs)
+ str := ExpectInvalidTypeError(json.Unmarshal([]byte(input), &args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestSubmitWorkArgs(t *testing.T) {
+ input := `["0x0000000000000001", "0x1234567890abcdef1234567890abcdef", "0xD1GE5700000000000000000000000000"]`
+ expected := new(SubmitWorkArgs)
+ expected.Nonce = 1
+ expected.Header = "0x1234567890abcdef1234567890abcdef"
+ expected.Digest = "0xD1GE5700000000000000000000000000"
+
+ args := new(SubmitWorkArgs)
+ if err := json.Unmarshal([]byte(input), &args); err != nil {
+ t.Error(err)
+ }
+
+ if expected.Nonce != args.Nonce {
+ t.Errorf("Nonce shoud be %d but is %d", expected.Nonce, args.Nonce)
+ }
+
+ if expected.Header != args.Header {
+ t.Errorf("Header shoud be %#v but is %#v", expected.Header, args.Header)
+ }
+
+ if expected.Digest != args.Digest {
+ t.Errorf("Digest shoud be %#v but is %#v", expected.Digest, args.Digest)
+ }
+}
+
+func TestSubmitWorkArgsInvalid(t *testing.T) {
+ input := `{}`
+
+ args := new(SubmitWorkArgs)
+ str := ExpectDecodeParamError(json.Unmarshal([]byte(input), args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestSubmitWorkArgsEmpty(t *testing.T) {
+ input := `[]`
+
+ args := new(SubmitWorkArgs)
+ str := ExpectInsufficientParamsError(json.Unmarshal([]byte(input), args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestSubmitWorkArgsNonceInt(t *testing.T) {
+ input := `[1, "0x1234567890abcdef1234567890abcdef", "0xD1GE5700000000000000000000000000"]`
+
+ args := new(SubmitWorkArgs)
+ str := ExpectInvalidTypeError(json.Unmarshal([]byte(input), args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+func TestSubmitWorkArgsHeaderInt(t *testing.T) {
+ input := `["0x0000000000000001", 1, "0xD1GE5700000000000000000000000000"]`
+
+ args := new(SubmitWorkArgs)
+ str := ExpectInvalidTypeError(json.Unmarshal([]byte(input), args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+func TestSubmitWorkArgsDigestInt(t *testing.T) {
+ input := `["0x0000000000000001", "0x1234567890abcdef1234567890abcdef", 1]`
+
+ args := new(SubmitWorkArgs)
+ str := ExpectInvalidTypeError(json.Unmarshal([]byte(input), args))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
+
+func TestBlockHeightFromJsonInvalid(t *testing.T) {
+ var num int64
+ var msg json.RawMessage = []byte(`}{`)
+ str := ExpectDecodeParamError(blockHeightFromJson(msg, &num))
+ if len(str) > 0 {
+ t.Error(str)
+ }
+}
diff --git a/rpc/http.go b/rpc/http.go
new file mode 100644
index 000000000..f15d557ad
--- /dev/null
+++ b/rpc/http.go
@@ -0,0 +1,127 @@
+package rpc
+
+import (
+ "encoding/json"
+ "fmt"
+ "io"
+ "io/ioutil"
+ "net"
+ "net/http"
+
+ "github.com/ethereum/go-ethereum/logger"
+ "github.com/ethereum/go-ethereum/xeth"
+ "github.com/rs/cors"
+)
+
+var rpclogger = logger.NewLogger("RPC")
+
+const (
+ jsonrpcver = "2.0"
+ maxSizeReqLength = 1024 * 1024 // 1MB
+)
+
+func Start(pipe *xeth.XEth, config RpcConfig) error {
+ l, err := net.Listen("tcp", fmt.Sprintf("%s:%d", config.ListenAddress, config.ListenPort))
+ if err != nil {
+ rpclogger.Errorf("Can't listen on %s:%d: %v", config.ListenAddress, config.ListenPort, err)
+ return err
+ }
+
+ var handler http.Handler
+ if len(config.CorsDomain) > 0 {
+ var opts cors.Options
+ opts.AllowedMethods = []string{"POST"}
+ opts.AllowedOrigins = []string{config.CorsDomain}
+
+ c := cors.New(opts)
+ handler = c.Handler(JSONRPC(pipe))
+ } else {
+ handler = JSONRPC(pipe)
+ }
+
+ go http.Serve(l, handler)
+
+ return nil
+}
+
+// JSONRPC returns a handler that implements the Ethereum JSON-RPC API.
+func JSONRPC(pipe *xeth.XEth) http.Handler {
+ api := NewEthereumApi(pipe)
+
+ return http.HandlerFunc(func(w http.ResponseWriter, req *http.Request) {
+ w.Header().Set("Content-Type", "application/json")
+
+ // Limit request size to resist DoS
+ if req.ContentLength > maxSizeReqLength {
+ jsonerr := &RpcErrorObject{-32700, "Request too large"}
+ send(w, &RpcErrorResponse{Jsonrpc: jsonrpcver, Id: nil, Error: jsonerr})
+ return
+ }
+
+ // Read request body
+ defer req.Body.Close()
+ body, err := ioutil.ReadAll(req.Body)
+ if err != nil {
+ jsonerr := &RpcErrorObject{-32700, "Could not read request body"}
+ send(w, &RpcErrorResponse{Jsonrpc: jsonrpcver, Id: nil, Error: jsonerr})
+ }
+
+ // Try to parse the request as a single
+ var reqSingle RpcRequest
+ if err := json.Unmarshal(body, &reqSingle); err == nil {
+ response := RpcResponse(api, &reqSingle)
+ send(w, &response)
+ return
+ }
+
+ // Try to parse the request to batch
+ var reqBatch []RpcRequest
+ if err := json.Unmarshal(body, &reqBatch); err == nil {
+ // Build response batch
+ resBatch := make([]*interface{}, len(reqBatch))
+ for i, request := range reqBatch {
+ response := RpcResponse(api, &request)
+ resBatch[i] = response
+ }
+ send(w, resBatch)
+ return
+ }
+
+ // Not a batch or single request, error
+ jsonerr := &RpcErrorObject{-32600, "Could not decode request"}
+ send(w, &RpcErrorResponse{Jsonrpc: jsonrpcver, Id: nil, Error: jsonerr})
+ })
+}
+
+func RpcResponse(api *EthereumApi, request *RpcRequest) *interface{} {
+ var reply, response interface{}
+ reserr := api.GetRequestReply(request, &reply)
+ switch reserr.(type) {
+ case nil:
+ response = &RpcSuccessResponse{Jsonrpc: jsonrpcver, Id: request.Id, Result: reply}
+ case *NotImplementedError:
+ jsonerr := &RpcErrorObject{-32601, reserr.Error()}
+ response = &RpcErrorResponse{Jsonrpc: jsonrpcver, Id: request.Id, Error: jsonerr}
+ case *DecodeParamError, *InsufficientParamsError, *ValidationError, *InvalidTypeError:
+ jsonerr := &RpcErrorObject{-32602, reserr.Error()}
+ response = &RpcErrorResponse{Jsonrpc: jsonrpcver, Id: request.Id, Error: jsonerr}
+ default:
+ jsonerr := &RpcErrorObject{-32603, reserr.Error()}
+ response = &RpcErrorResponse{Jsonrpc: jsonrpcver, Id: request.Id, Error: jsonerr}
+ }
+
+ rpclogger.DebugDetailf("Generated response: %T %s", response, response)
+ return &response
+}
+
+func send(writer io.Writer, v interface{}) (n int, err error) {
+ var payload []byte
+ payload, err = json.MarshalIndent(v, "", "\t")
+ if err != nil {
+ rpclogger.Fatalln("Error marshalling JSON", err)
+ return 0, err
+ }
+ rpclogger.DebugDetailf("Sending payload: %s", payload)
+
+ return writer.Write(payload)
+}
diff --git a/rpc/jeth.go b/rpc/jeth.go
new file mode 100644
index 000000000..e83212bb5
--- /dev/null
+++ b/rpc/jeth.go
@@ -0,0 +1,58 @@
+package rpc
+
+import (
+ "encoding/json"
+ "fmt"
+ // "fmt"
+ "github.com/ethereum/go-ethereum/jsre"
+ "github.com/robertkrimen/otto"
+)
+
+type Jeth struct {
+ ethApi *EthereumApi
+ toVal func(interface{}) otto.Value
+ re *jsre.JSRE
+}
+
+func NewJeth(ethApi *EthereumApi, toVal func(interface{}) otto.Value, re *jsre.JSRE) *Jeth {
+ return &Jeth{ethApi, toVal, re}
+}
+
+func (self *Jeth) err(code int, msg string, id interface{}) (response otto.Value) {
+ rpcerr := &RpcErrorObject{code, msg}
+ self.re.Set("ret_jsonrpc", jsonrpcver)
+ self.re.Set("ret_id", id)
+ self.re.Set("ret_error", rpcerr)
+ response, _ = self.re.Run(`
+ ret_response = { jsonrpc: ret_jsonrpc, id: ret_id, error: ret_error };
+ `)
+ return
+}
+
+func (self *Jeth) Send(call otto.FunctionCall) (response otto.Value) {
+ reqif, err := call.Argument(0).Export()
+ if err != nil {
+ return self.err(-32700, err.Error(), nil)
+ }
+
+ jsonreq, err := json.Marshal(reqif)
+
+ var req RpcRequest
+ err = json.Unmarshal(jsonreq, &req)
+
+ var respif interface{}
+ err = self.ethApi.GetRequestReply(&req, &respif)
+ if err != nil {
+ fmt.Printf("error: %s\n", err)
+ return self.err(-32603, err.Error(), req.Id)
+ }
+ self.re.Set("ret_jsonrpc", jsonrpcver)
+ self.re.Set("ret_id", req.Id)
+
+ res, _ := json.Marshal(respif)
+ self.re.Set("ret_result", string(res))
+ response, err = self.re.Run(`
+ ret_response = { jsonrpc: ret_jsonrpc, id: ret_id, result: JSON.parse(ret_result) };
+ `)
+ return
+}
diff --git a/rpc/responses.go b/rpc/responses.go
new file mode 100644
index 000000000..3d1687cb6
--- /dev/null
+++ b/rpc/responses.go
@@ -0,0 +1,257 @@
+package rpc
+
+import (
+ "encoding/json"
+
+ "github.com/ethereum/go-ethereum/core/state"
+ "github.com/ethereum/go-ethereum/core/types"
+)
+
+type BlockRes struct {
+ fullTx bool
+
+ BlockNumber *hexnum `json:"number"`
+ BlockHash *hexdata `json:"hash"`
+ ParentHash *hexdata `json:"parentHash"`
+ Nonce *hexdata `json:"nonce"`
+ Sha3Uncles *hexdata `json:"sha3Uncles"`
+ LogsBloom *hexdata `json:"logsBloom"`
+ TransactionRoot *hexdata `json:"transactionsRoot"`
+ StateRoot *hexdata `json:"stateRoot"`
+ Miner *hexdata `json:"miner"`
+ Difficulty *hexnum `json:"difficulty"`
+ TotalDifficulty *hexnum `json:"totalDifficulty"`
+ Size *hexnum `json:"size"`
+ ExtraData *hexdata `json:"extraData"`
+ GasLimit *hexnum `json:"gasLimit"`
+ MinGasPrice *hexnum `json:"minGasPrice"`
+ GasUsed *hexnum `json:"gasUsed"`
+ UnixTimestamp *hexnum `json:"timestamp"`
+ Transactions []*TransactionRes `json:"transactions"`
+ Uncles []*hexdata `json:"uncles"`
+}
+
+func (b *BlockRes) MarshalJSON() ([]byte, error) {
+ if b.fullTx {
+ var ext struct {
+ BlockNumber *hexnum `json:"number"`
+ BlockHash *hexdata `json:"hash"`
+ ParentHash *hexdata `json:"parentHash"`
+ Nonce *hexdata `json:"nonce"`
+ Sha3Uncles *hexdata `json:"sha3Uncles"`
+ LogsBloom *hexdata `json:"logsBloom"`
+ TransactionRoot *hexdata `json:"transactionsRoot"`
+ StateRoot *hexdata `json:"stateRoot"`
+ Miner *hexdata `json:"miner"`
+ Difficulty *hexnum `json:"difficulty"`
+ TotalDifficulty *hexnum `json:"totalDifficulty"`
+ Size *hexnum `json:"size"`
+ ExtraData *hexdata `json:"extraData"`
+ GasLimit *hexnum `json:"gasLimit"`
+ MinGasPrice *hexnum `json:"minGasPrice"`
+ GasUsed *hexnum `json:"gasUsed"`
+ UnixTimestamp *hexnum `json:"timestamp"`
+ Transactions []*TransactionRes `json:"transactions"`
+ Uncles []*hexdata `json:"uncles"`
+ }
+
+ ext.BlockNumber = b.BlockNumber
+ ext.BlockHash = b.BlockHash
+ ext.ParentHash = b.ParentHash
+ ext.Nonce = b.Nonce
+ ext.Sha3Uncles = b.Sha3Uncles
+ ext.LogsBloom = b.LogsBloom
+ ext.TransactionRoot = b.TransactionRoot
+ ext.StateRoot = b.StateRoot
+ ext.Miner = b.Miner
+ ext.Difficulty = b.Difficulty
+ ext.TotalDifficulty = b.TotalDifficulty
+ ext.Size = b.Size
+ ext.ExtraData = b.ExtraData
+ ext.GasLimit = b.GasLimit
+ ext.MinGasPrice = b.MinGasPrice
+ ext.GasUsed = b.GasUsed
+ ext.UnixTimestamp = b.UnixTimestamp
+ ext.Transactions = b.Transactions
+ ext.Uncles = b.Uncles
+ return json.Marshal(ext)
+ } else {
+ var ext struct {
+ BlockNumber *hexnum `json:"number"`
+ BlockHash *hexdata `json:"hash"`
+ ParentHash *hexdata `json:"parentHash"`
+ Nonce *hexdata `json:"nonce"`
+ Sha3Uncles *hexdata `json:"sha3Uncles"`
+ LogsBloom *hexdata `json:"logsBloom"`
+ TransactionRoot *hexdata `json:"transactionsRoot"`
+ StateRoot *hexdata `json:"stateRoot"`
+ Miner *hexdata `json:"miner"`
+ Difficulty *hexnum `json:"difficulty"`
+ TotalDifficulty *hexnum `json:"totalDifficulty"`
+ Size *hexnum `json:"size"`
+ ExtraData *hexdata `json:"extraData"`
+ GasLimit *hexnum `json:"gasLimit"`
+ MinGasPrice *hexnum `json:"minGasPrice"`
+ GasUsed *hexnum `json:"gasUsed"`
+ UnixTimestamp *hexnum `json:"timestamp"`
+ Transactions []*hexdata `json:"transactions"`
+ Uncles []*hexdata `json:"uncles"`
+ }
+
+ ext.BlockNumber = b.BlockNumber
+ ext.BlockHash = b.BlockHash
+ ext.ParentHash = b.ParentHash
+ ext.Nonce = b.Nonce
+ ext.Sha3Uncles = b.Sha3Uncles
+ ext.LogsBloom = b.LogsBloom
+ ext.TransactionRoot = b.TransactionRoot
+ ext.StateRoot = b.StateRoot
+ ext.Miner = b.Miner
+ ext.Difficulty = b.Difficulty
+ ext.TotalDifficulty = b.TotalDifficulty
+ ext.Size = b.Size
+ ext.ExtraData = b.ExtraData
+ ext.GasLimit = b.GasLimit
+ ext.MinGasPrice = b.MinGasPrice
+ ext.GasUsed = b.GasUsed
+ ext.UnixTimestamp = b.UnixTimestamp
+ ext.Transactions = make([]*hexdata, len(b.Transactions))
+ for i, tx := range b.Transactions {
+ ext.Transactions[i] = tx.Hash
+ }
+ ext.Uncles = b.Uncles
+ return json.Marshal(ext)
+ }
+}
+
+func NewBlockRes(block *types.Block, fullTx bool) *BlockRes {
+ // TODO respect fullTx flag
+
+ if block == nil {
+ return nil
+ }
+
+ res := new(BlockRes)
+ res.fullTx = fullTx
+ res.BlockNumber = newHexNum(block.Number())
+ res.BlockHash = newHexData(block.Hash())
+ res.ParentHash = newHexData(block.ParentHash())
+ res.Nonce = newHexData(block.Nonce())
+ res.Sha3Uncles = newHexData(block.Header().UncleHash)
+ res.LogsBloom = newHexData(block.Bloom())
+ res.TransactionRoot = newHexData(block.Header().TxHash)
+ res.StateRoot = newHexData(block.Root())
+ res.Miner = newHexData(block.Header().Coinbase)
+ res.Difficulty = newHexNum(block.Difficulty())
+ res.TotalDifficulty = newHexNum(block.Td)
+ res.Size = newHexNum(block.Size().Int64())
+ res.ExtraData = newHexData(block.Header().Extra)
+ res.GasLimit = newHexNum(block.GasLimit())
+ // res.MinGasPrice =
+ res.GasUsed = newHexNum(block.GasUsed())
+ res.UnixTimestamp = newHexNum(block.Time())
+
+ res.Transactions = make([]*TransactionRes, len(block.Transactions()))
+ for i, tx := range block.Transactions() {
+ res.Transactions[i] = NewTransactionRes(tx)
+ res.Transactions[i].BlockHash = res.BlockHash
+ res.Transactions[i].BlockNumber = res.BlockNumber
+ res.Transactions[i].TxIndex = newHexNum(i)
+ }
+
+ res.Uncles = make([]*hexdata, len(block.Uncles()))
+ for i, uncle := range block.Uncles() {
+ res.Uncles[i] = newHexData(uncle.Hash())
+ }
+
+ return res
+}
+
+type TransactionRes struct {
+ Hash *hexdata `json:"hash"`
+ Nonce *hexnum `json:"nonce"`
+ BlockHash *hexdata `json:"blockHash"`
+ BlockNumber *hexnum `json:"blockNumber"`
+ TxIndex *hexnum `json:"transactionIndex"`
+ From *hexdata `json:"from"`
+ To *hexdata `json:"to"`
+ Value *hexnum `json:"value"`
+ Gas *hexnum `json:"gas"`
+ GasPrice *hexnum `json:"gasPrice"`
+ Input *hexdata `json:"input"`
+}
+
+func NewTransactionRes(tx *types.Transaction) *TransactionRes {
+ var v = new(TransactionRes)
+ v.Hash = newHexData(tx.Hash())
+ v.Nonce = newHexNum(tx.Nonce())
+ // v.BlockHash =
+ // v.BlockNumber =
+ // v.TxIndex =
+ from, _ := tx.From()
+ v.From = newHexData(from)
+ v.To = newHexData(tx.To())
+ v.Value = newHexNum(tx.Value())
+ v.Gas = newHexNum(tx.Gas())
+ v.GasPrice = newHexNum(tx.GasPrice())
+ v.Input = newHexData(tx.Data())
+ return v
+}
+
+// type FilterLogRes struct {
+// Hash string `json:"hash"`
+// Address string `json:"address"`
+// Data string `json:"data"`
+// BlockNumber string `json:"blockNumber"`
+// TransactionHash string `json:"transactionHash"`
+// BlockHash string `json:"blockHash"`
+// TransactionIndex string `json:"transactionIndex"`
+// LogIndex string `json:"logIndex"`
+// }
+
+// type FilterWhisperRes struct {
+// Hash string `json:"hash"`
+// From string `json:"from"`
+// To string `json:"to"`
+// Expiry string `json:"expiry"`
+// Sent string `json:"sent"`
+// Ttl string `json:"ttl"`
+// Topics string `json:"topics"`
+// Payload string `json:"payload"`
+// WorkProved string `json:"workProved"`
+// }
+
+type LogRes struct {
+ Address *hexdata `json:"address"`
+ Topics []*hexdata `json:"topics"`
+ Data *hexdata `json:"data"`
+ BlockNumber *hexnum `json:"blockNumber"`
+ Hash *hexdata `json:"hash"`
+ LogIndex *hexnum `json:"logIndex"`
+ BlockHash *hexdata `json:"blockHash"`
+ TransactionHash *hexdata `json:"transactionHash"`
+ TransactionIndex *hexnum `json:"transactionIndex"`
+}
+
+func NewLogRes(log state.Log) LogRes {
+ var l LogRes
+ l.Topics = make([]*hexdata, len(log.Topics()))
+ for j, topic := range log.Topics() {
+ l.Topics[j] = newHexData(topic)
+ }
+ l.Address = newHexData(log.Address())
+ l.Data = newHexData(log.Data())
+ l.BlockNumber = newHexNum(log.Number())
+
+ return l
+}
+
+func NewLogsRes(logs state.Logs) (ls []LogRes) {
+ ls = make([]LogRes, len(logs))
+
+ for i, log := range logs {
+ ls[i] = NewLogRes(log)
+ }
+
+ return
+}
diff --git a/rpc/responses_test.go b/rpc/responses_test.go
new file mode 100644
index 000000000..2ec6d9d15
--- /dev/null
+++ b/rpc/responses_test.go
@@ -0,0 +1,219 @@
+package rpc
+
+import (
+ "encoding/json"
+ "fmt"
+ "math/big"
+ "regexp"
+ "testing"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/core/state"
+ "github.com/ethereum/go-ethereum/core/types"
+)
+
+const (
+ reHash = `"0x[0-9a-f]{64}"` // 32 bytes
+ reHashOpt = `"(0x[0-9a-f]{64})"|null` // 32 bytes or null
+ reAddress = `"0x[0-9a-f]{40}"` // 20 bytes
+ reAddressOpt = `"0x[0-9a-f]{40}"|null` // 20 bytes or null
+ reNum = `"0x([1-9a-f][0-9a-f]{0,15})|0"` // must not have left-padded zeros
+ reNumNonZero = `"0x([1-9a-f][0-9a-f]{0,15})"` // non-zero required must not have left-padded zeros
+ reNumOpt = `"0x([1-9a-f][0-9a-f]{0,15})|0"|null` // must not have left-padded zeros or null
+ reData = `"0x[0-9a-f]*"` // can be "empty"
+ // reListHash = `[("\w":"0x[0-9a-f]{64}",?)*]`
+ // reListObj = `[("\w":(".+"|null),?)*]`
+)
+
+func TestNewBlockRes(t *testing.T) {
+ parentHash := common.HexToHash("0x01")
+ coinbase := common.HexToAddress("0x01")
+ root := common.HexToHash("0x01")
+ difficulty := common.Big1
+ nonce := uint64(1)
+ extra := ""
+ block := types.NewBlock(parentHash, coinbase, root, difficulty, nonce, extra)
+ tests := map[string]string{
+ "number": reNum,
+ "hash": reHash,
+ "parentHash": reHash,
+ "nonce": reData,
+ "sha3Uncles": reHash,
+ "logsBloom": reData,
+ "transactionsRoot": reHash,
+ "stateRoot": reHash,
+ "miner": reAddress,
+ "difficulty": `"0x1"`,
+ "totalDifficulty": reNum,
+ "size": reNumNonZero,
+ "extraData": reData,
+ "gasLimit": reNum,
+ // "minGasPrice": "0x",
+ "gasUsed": reNum,
+ "timestamp": reNum,
+ // "transactions": reListHash,
+ // "uncles": reListHash,
+ }
+
+ to := common.HexToAddress("0x02")
+ amount := big.NewInt(1)
+ gasAmount := big.NewInt(1)
+ gasPrice := big.NewInt(1)
+ data := []byte{1, 2, 3}
+ tx := types.NewTransactionMessage(to, amount, gasAmount, gasPrice, data)
+
+ v := NewBlockRes(block, false)
+ v.Transactions = make([]*TransactionRes, 1)
+ v.Transactions[0] = NewTransactionRes(tx)
+ j, _ := json.Marshal(v)
+
+ for k, re := range tests {
+ match, _ := regexp.MatchString(fmt.Sprintf(`{.*"%s":%s.*}`, k, re), string(j))
+ if !match {
+ t.Error(fmt.Sprintf("%s output json does not match format %s. Got %s", k, re, j))
+ }
+ }
+}
+
+func TestNewBlockResWithTrans(t *testing.T) {
+ parentHash := common.HexToHash("0x01")
+ coinbase := common.HexToAddress("0x01")
+ root := common.HexToHash("0x01")
+ difficulty := common.Big1
+ nonce := uint64(1)
+ extra := ""
+ block := types.NewBlock(parentHash, coinbase, root, difficulty, nonce, extra)
+ tests := map[string]string{
+ "number": reNum,
+ "hash": reHash,
+ "parentHash": reHash,
+ "nonce": reData,
+ "sha3Uncles": reHash,
+ "logsBloom": reData,
+ "transactionsRoot": reHash,
+ "stateRoot": reHash,
+ "miner": reAddress,
+ "difficulty": `"0x1"`,
+ "totalDifficulty": reNum,
+ "size": reNumNonZero,
+ "extraData": reData,
+ "gasLimit": reNum,
+ // "minGasPrice": "0x",
+ "gasUsed": reNum,
+ "timestamp": reNum,
+ // "transactions": `[{.*}]`,
+ // "uncles": reListHash,
+ }
+
+ to := common.HexToAddress("0x02")
+ amount := big.NewInt(1)
+ gasAmount := big.NewInt(1)
+ gasPrice := big.NewInt(1)
+ data := []byte{1, 2, 3}
+ tx := types.NewTransactionMessage(to, amount, gasAmount, gasPrice, data)
+
+ v := NewBlockRes(block, true)
+ v.Transactions = make([]*TransactionRes, 1)
+ v.Transactions[0] = NewTransactionRes(tx)
+ j, _ := json.Marshal(v)
+
+ for k, re := range tests {
+ match, _ := regexp.MatchString(fmt.Sprintf(`{.*"%s":%s.*}`, k, re), string(j))
+ if !match {
+ t.Error(fmt.Sprintf("%s output json does not match format %s. Got %s", k, re, j))
+ }
+ }
+}
+
+func TestNewTransactionRes(t *testing.T) {
+ to := common.HexToAddress("0x02")
+ amount := big.NewInt(1)
+ gasAmount := big.NewInt(1)
+ gasPrice := big.NewInt(1)
+ data := []byte{1, 2, 3}
+ tx := types.NewTransactionMessage(to, amount, gasAmount, gasPrice, data)
+
+ tests := map[string]string{
+ "hash": reHash,
+ "nonce": reNum,
+ "blockHash": reHashOpt,
+ "blockNum": reNumOpt,
+ "transactionIndex": reNumOpt,
+ "from": reAddress,
+ "to": reAddressOpt,
+ "value": reNum,
+ "gas": reNum,
+ "gasPrice": reNum,
+ "input": reData,
+ }
+
+ v := NewTransactionRes(tx)
+ v.BlockHash = newHexData(common.HexToHash("0x030201"))
+ v.BlockNumber = newHexNum(5)
+ v.TxIndex = newHexNum(0)
+ j, _ := json.Marshal(v)
+ for k, re := range tests {
+ match, _ := regexp.MatchString(fmt.Sprintf(`{.*"%s":%s.*}`, k, re), string(j))
+ if !match {
+ t.Error(fmt.Sprintf("`%s` output json does not match format %s. Source %s", k, re, j))
+ }
+ }
+
+}
+
+func TestNewLogRes(t *testing.T) {
+ log := makeStateLog(0)
+ tests := map[string]string{
+ "address": reAddress,
+ // "topics": "[.*]"
+ "data": reData,
+ "blockNumber": reNum,
+ // "hash": reHash,
+ // "logIndex": reNum,
+ // "blockHash": reHash,
+ // "transactionHash": reHash,
+ "transactionIndex": reNum,
+ }
+
+ v := NewLogRes(log)
+ j, _ := json.Marshal(v)
+
+ for k, re := range tests {
+ match, _ := regexp.MatchString(fmt.Sprintf(`{.*"%s":%s.*}`, k, re), string(j))
+ if !match {
+ t.Error(fmt.Sprintf("`%s` output json does not match format %s. Got %s", k, re, j))
+ }
+ }
+
+}
+
+func TestNewLogsRes(t *testing.T) {
+ logs := make([]state.Log, 3)
+ logs[0] = makeStateLog(1)
+ logs[1] = makeStateLog(2)
+ logs[2] = makeStateLog(3)
+ tests := map[string]string{}
+
+ v := NewLogsRes(logs)
+ j, _ := json.Marshal(v)
+
+ for k, re := range tests {
+ match, _ := regexp.MatchString(fmt.Sprintf(`[{.*"%s":%s.*}]`, k, re), string(j))
+ if !match {
+ t.Error(fmt.Sprintf("%s output json does not match format %s. Got %s", k, re, j))
+ }
+ }
+
+}
+
+func makeStateLog(num int) state.Log {
+ address := common.HexToAddress("0x0")
+ data := []byte{1, 2, 3}
+ number := uint64(num)
+ topics := make([]common.Hash, 3)
+ topics = append(topics, common.HexToHash("0x00"))
+ topics = append(topics, common.HexToHash("0x10"))
+ topics = append(topics, common.HexToHash("0x20"))
+ log := state.NewLog(address, topics, data, number)
+ return log
+}
diff --git a/rpc/types.go b/rpc/types.go
new file mode 100644
index 000000000..806c9c8a4
--- /dev/null
+++ b/rpc/types.go
@@ -0,0 +1,269 @@
+/*
+ This file is part of go-ethereum
+
+ go-ethereum is free software: you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation, either version 3 of the License, or
+ (at your option) any later version.
+
+ go-ethereum is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with go-ethereum. If not, see <http://www.gnu.org/licenses/>.
+*/
+package rpc
+
+import (
+ "encoding/binary"
+ "encoding/json"
+ "fmt"
+ "math/big"
+ "strings"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/core/types"
+)
+
+type hexdata struct {
+ data []byte
+ isNil bool
+}
+
+func (d *hexdata) String() string {
+ return "0x" + common.Bytes2Hex(d.data)
+}
+
+func (d *hexdata) MarshalJSON() ([]byte, error) {
+ if d.isNil {
+ return json.Marshal(nil)
+ }
+ return json.Marshal(d.String())
+}
+
+func (d *hexdata) UnmarshalJSON(b []byte) (err error) {
+ d.data = common.FromHex(string(b))
+ return nil
+}
+
+func newHexData(input interface{}) *hexdata {
+ d := new(hexdata)
+
+ if input == nil {
+ d.data = nil
+ return d
+ }
+ switch input := input.(type) {
+ case []byte:
+ d.data = input
+ case common.Hash:
+ d.data = input.Bytes()
+ case *common.Hash:
+ if input == nil {
+ d.isNil = true
+ } else {
+ d.data = input.Bytes()
+ }
+ case common.Address:
+ d.data = input.Bytes()
+ case *common.Address:
+ if input == nil {
+ d.isNil = true
+ } else {
+ d.data = input.Bytes()
+ }
+ case types.Bloom:
+ d.data = input.Bytes()
+ case *types.Bloom:
+ if input == nil {
+ d.isNil = true
+ } else {
+ d.data = input.Bytes()
+ }
+ case *big.Int:
+ if input == nil {
+ d.isNil = true
+ } else {
+ d.data = input.Bytes()
+ }
+ case int64:
+ d.data = big.NewInt(input).Bytes()
+ case uint64:
+ buff := make([]byte, 8)
+ binary.BigEndian.PutUint64(buff, input)
+ d.data = buff
+ case int:
+ d.data = big.NewInt(int64(input)).Bytes()
+ case uint:
+ d.data = big.NewInt(int64(input)).Bytes()
+ case int8:
+ d.data = big.NewInt(int64(input)).Bytes()
+ case uint8:
+ d.data = big.NewInt(int64(input)).Bytes()
+ case int16:
+ d.data = big.NewInt(int64(input)).Bytes()
+ case uint16:
+ buff := make([]byte, 8)
+ binary.BigEndian.PutUint16(buff, input)
+ d.data = buff
+ case int32:
+ d.data = big.NewInt(int64(input)).Bytes()
+ case uint32:
+ buff := make([]byte, 8)
+ binary.BigEndian.PutUint32(buff, input)
+ d.data = buff
+ case string: // hexstring
+ d.data = common.Big(input).Bytes()
+ default:
+ d.data = nil
+ }
+
+ return d
+}
+
+type hexnum struct {
+ data []byte
+ isNil bool
+}
+
+func (d *hexnum) String() string {
+ // Get hex string from bytes
+ out := common.Bytes2Hex(d.data)
+ // Trim leading 0s
+ out = strings.TrimLeft(out, "0")
+ // Output "0x0" when value is 0
+ if len(out) == 0 {
+ out = "0"
+ }
+ return "0x" + out
+}
+
+func (d *hexnum) MarshalJSON() ([]byte, error) {
+ if d.isNil {
+ return json.Marshal(nil)
+ }
+ return json.Marshal(d.String())
+}
+
+func (d *hexnum) UnmarshalJSON(b []byte) (err error) {
+ d.data = common.FromHex(string(b))
+ return nil
+}
+
+func newHexNum(input interface{}) *hexnum {
+ d := new(hexnum)
+
+ d.data = newHexData(input).data
+
+ return d
+}
+
+type RpcConfig struct {
+ ListenAddress string
+ ListenPort uint
+ CorsDomain string
+}
+
+type InvalidTypeError struct {
+ method string
+ msg string
+}
+
+func (e *InvalidTypeError) Error() string {
+ return fmt.Sprintf("invalid type on field %s: %s", e.method, e.msg)
+}
+
+func NewInvalidTypeError(method, msg string) *InvalidTypeError {
+ return &InvalidTypeError{
+ method: method,
+ msg: msg,
+ }
+}
+
+type InsufficientParamsError struct {
+ have int
+ want int
+}
+
+func (e *InsufficientParamsError) Error() string {
+ return fmt.Sprintf("insufficient params, want %d have %d", e.want, e.have)
+}
+
+func NewInsufficientParamsError(have int, want int) *InsufficientParamsError {
+ return &InsufficientParamsError{
+ have: have,
+ want: want,
+ }
+}
+
+type NotImplementedError struct {
+ Method string
+}
+
+func (e *NotImplementedError) Error() string {
+ return fmt.Sprintf("%s method not implemented", e.Method)
+}
+
+func NewNotImplementedError(method string) *NotImplementedError {
+ return &NotImplementedError{
+ Method: method,
+ }
+}
+
+type DecodeParamError struct {
+ err string
+}
+
+func (e *DecodeParamError) Error() string {
+ return fmt.Sprintf("could not decode, %s", e.err)
+
+}
+
+func NewDecodeParamError(errstr string) error {
+ return &DecodeParamError{
+ err: errstr,
+ }
+}
+
+type ValidationError struct {
+ ParamName string
+ msg string
+}
+
+func (e *ValidationError) Error() string {
+ return fmt.Sprintf("%s not valid, %s", e.ParamName, e.msg)
+}
+
+func NewValidationError(param string, msg string) error {
+ return &ValidationError{
+ ParamName: param,
+ msg: msg,
+ }
+}
+
+type RpcRequest struct {
+ Id interface{} `json:"id"`
+ Jsonrpc string `json:"jsonrpc"`
+ Method string `json:"method"`
+ Params json.RawMessage `json:"params"`
+}
+
+type RpcSuccessResponse struct {
+ Id interface{} `json:"id"`
+ Jsonrpc string `json:"jsonrpc"`
+ Result interface{} `json:"result"`
+}
+
+type RpcErrorResponse struct {
+ Id interface{} `json:"id"`
+ Jsonrpc string `json:"jsonrpc"`
+ Error *RpcErrorObject `json:"error"`
+}
+
+type RpcErrorObject struct {
+ Code int `json:"code"`
+ Message string `json:"message"`
+ // Data interface{} `json:"data"`
+}
diff --git a/rpc/types_test.go b/rpc/types_test.go
new file mode 100644
index 000000000..91f0152dc
--- /dev/null
+++ b/rpc/types_test.go
@@ -0,0 +1,50 @@
+package rpc
+
+import (
+ "testing"
+)
+
+func TestInvalidTypeError(t *testing.T) {
+ err := NewInvalidTypeError("testField", "not string")
+ expected := "invalid type on field testField: not string"
+
+ if err.Error() != expected {
+ t.Error(err.Error())
+ }
+}
+
+func TestInsufficientParamsError(t *testing.T) {
+ err := NewInsufficientParamsError(0, 1)
+ expected := "insufficient params, want 1 have 0"
+
+ if err.Error() != expected {
+ t.Error(err.Error())
+ }
+}
+
+func TestNotImplementedError(t *testing.T) {
+ err := NewNotImplementedError("foo")
+ expected := "foo method not implemented"
+
+ if err.Error() != expected {
+ t.Error(err.Error())
+ }
+}
+
+func TestDecodeParamError(t *testing.T) {
+ err := NewDecodeParamError("foo")
+ expected := "could not decode, foo"
+
+ if err.Error() != expected {
+ t.Error(err.Error())
+ }
+}
+
+func TestValidationError(t *testing.T) {
+ err := NewValidationError("foo", "should be `bar`")
+ expected := "foo not valid, should be `bar`"
+
+ if err.Error() != expected {
+ t.Error(err.Error())
+ }
+}
diff --git a/tests/blocktest.go b/tests/blocktest.go
new file mode 100644
index 000000000..1c4f1c2f2
--- /dev/null
+++ b/tests/blocktest.go
@@ -0,0 +1,289 @@
+package tests
+
+import (
+ "bytes"
+ "encoding/hex"
+ "encoding/json"
+ "fmt"
+ "io/ioutil"
+ "math/big"
+ "runtime"
+ "strconv"
+ "strings"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/core/state"
+ "github.com/ethereum/go-ethereum/core/types"
+ "github.com/ethereum/go-ethereum/rlp"
+)
+
+// Block Test JSON Format
+type btJSON struct {
+ Blocks []btBlock
+ GenesisBlockHeader btHeader
+ Pre map[string]btAccount
+ PostState map[string]btAccount
+}
+
+type btAccount struct {
+ Balance string
+ Code string
+ Nonce string
+ Storage map[string]string
+}
+
+type btHeader struct {
+ Bloom string
+ Coinbase string
+ MixHash string
+ Nonce string
+ Number string
+ ParentHash string
+ ReceiptTrie string
+ SeedHash string
+ StateRoot string
+ TransactionsTrie string
+ UncleHash string
+
+ ExtraData string
+ Difficulty string
+ GasLimit string
+ GasUsed string
+ Timestamp string
+}
+
+type btTransaction struct {
+ Data string
+ GasLimit string
+ GasPrice string
+ Nonce string
+ R string
+ S string
+ To string
+ V string
+ Value string
+}
+
+type btBlock struct {
+ BlockHeader *btHeader
+ Rlp string
+ Transactions []btTransaction
+ UncleHeaders []*btHeader
+}
+
+type BlockTest struct {
+ Genesis *types.Block
+ Blocks []*types.Block
+
+ preAccounts map[string]btAccount
+}
+
+// LoadBlockTests loads a block test JSON file.
+func LoadBlockTests(file string) (map[string]*BlockTest, error) {
+ bt := make(map[string]*btJSON)
+ if err := loadJSON(file, &bt); err != nil {
+ return nil, err
+ }
+ out := make(map[string]*BlockTest)
+ for name, in := range bt {
+ var err error
+ if out[name], err = convertTest(in); err != nil {
+ return nil, fmt.Errorf("bad test %q: %v", err)
+ }
+ }
+ return out, nil
+}
+
+// InsertPreState populates the given database with the genesis
+// accounts defined by the test.
+func (t *BlockTest) InsertPreState(db common.Database) (*state.StateDB, error) {
+ statedb := state.New(common.Hash{}, db)
+ for addrString, acct := range t.preAccounts {
+ // XXX: is is worth it checking for errors here?
+ //addr, _ := hex.DecodeString(addrString)
+ code, _ := hex.DecodeString(strings.TrimPrefix(acct.Code, "0x"))
+ balance, _ := new(big.Int).SetString(acct.Balance, 0)
+ nonce, _ := strconv.ParseUint(acct.Nonce, 16, 64)
+
+ obj := statedb.CreateAccount(common.HexToAddress(addrString))
+ obj.SetCode(code)
+ obj.SetBalance(balance)
+ obj.SetNonce(nonce)
+ for k, v := range acct.Storage {
+ statedb.SetState(common.HexToAddress(addrString), common.HexToHash(k), common.FromHex(v))
+ }
+ }
+ // sync objects to trie
+ statedb.Update()
+ // sync trie to disk
+ statedb.Sync()
+
+ if !bytes.Equal(t.Genesis.Root().Bytes(), statedb.Root().Bytes()) {
+ return nil, fmt.Errorf("computed state root does not match genesis block %x %x", t.Genesis.Root().Bytes()[:4], statedb.Root().Bytes()[:4])
+ }
+ return statedb, nil
+}
+
+func (t *BlockTest) ValidatePostState(statedb *state.StateDB) error {
+ for addrString, acct := range t.preAccounts {
+ // XXX: is is worth it checking for errors here?
+ addr, _ := hex.DecodeString(addrString)
+ code, _ := hex.DecodeString(strings.TrimPrefix(acct.Code, "0x"))
+ balance, _ := new(big.Int).SetString(acct.Balance, 0)
+ nonce, _ := strconv.ParseUint(acct.Nonce, 16, 64)
+
+ // address is indirectly verified by the other fields, as it's the db key
+ code2 := statedb.GetCode(common.BytesToAddress(addr))
+ balance2 := statedb.GetBalance(common.BytesToAddress(addr))
+ nonce2 := statedb.GetNonce(common.BytesToAddress(addr))
+ if !bytes.Equal(code2, code) {
+ return fmt.Errorf("account code mismatch, addr, found, expected: ", addrString, hex.EncodeToString(code2), hex.EncodeToString(code))
+ }
+ if balance2.Cmp(balance) != 0 {
+ return fmt.Errorf("account balance mismatch, addr, found, expected: ", addrString, balance2, balance)
+ }
+ if nonce2 != nonce {
+ return fmt.Errorf("account nonce mismatch, addr, found, expected: ", addrString, nonce2, nonce)
+ }
+ }
+ return nil
+}
+
+func convertTest(in *btJSON) (out *BlockTest, err error) {
+ // the conversion handles errors by catching panics.
+ // you might consider this ugly, but the alternative (passing errors)
+ // would be much harder to read.
+ defer func() {
+ if recovered := recover(); recovered != nil {
+ buf := make([]byte, 64<<10)
+ buf = buf[:runtime.Stack(buf, false)]
+ err = fmt.Errorf("%v\n%s", recovered, buf)
+ }
+ }()
+ out = &BlockTest{preAccounts: in.Pre}
+ out.Genesis = mustConvertGenesis(in.GenesisBlockHeader)
+ out.Blocks = mustConvertBlocks(in.Blocks)
+ return out, err
+}
+
+func mustConvertGenesis(testGenesis btHeader) *types.Block {
+ hdr := mustConvertHeader(testGenesis)
+ hdr.Number = big.NewInt(0)
+ b := types.NewBlockWithHeader(hdr)
+ b.Td = new(big.Int)
+ return b
+}
+
+func mustConvertHeader(in btHeader) *types.Header {
+ // hex decode these fields
+ header := &types.Header{
+ //SeedHash: mustConvertBytes(in.SeedHash),
+ MixDigest: mustConvertHash(in.MixHash),
+ Bloom: mustConvertBloom(in.Bloom),
+ ReceiptHash: mustConvertHash(in.ReceiptTrie),
+ TxHash: mustConvertHash(in.TransactionsTrie),
+ Root: mustConvertHash(in.StateRoot),
+ Coinbase: mustConvertAddress(in.Coinbase),
+ UncleHash: mustConvertHash(in.UncleHash),
+ ParentHash: mustConvertHash(in.ParentHash),
+ Extra: string(mustConvertBytes(in.ExtraData)),
+ GasUsed: mustConvertBigInt10(in.GasUsed),
+ GasLimit: mustConvertBigInt10(in.GasLimit),
+ Difficulty: mustConvertBigInt10(in.Difficulty),
+ Time: mustConvertUint(in.Timestamp),
+ }
+ // XXX cheats? :-)
+ header.SetNonce(common.BytesToHash(mustConvertBytes(in.Nonce)).Big().Uint64())
+ return header
+}
+
+func mustConvertBlocks(testBlocks []btBlock) []*types.Block {
+ var out []*types.Block
+ for i, inb := range testBlocks {
+ var b types.Block
+ r := bytes.NewReader(mustConvertBytes(inb.Rlp))
+ if err := rlp.Decode(r, &b); err != nil {
+ panic(fmt.Errorf("invalid block %d: %q", i, inb.Rlp))
+ }
+ out = append(out, &b)
+ }
+ return out
+}
+
+func mustConvertBytes(in string) []byte {
+ out, err := hex.DecodeString(strings.TrimPrefix(in, "0x"))
+ if err != nil {
+ panic(fmt.Errorf("invalid hex: %q", in))
+ }
+ return out
+}
+
+func mustConvertHash(in string) common.Hash {
+ out, err := hex.DecodeString(strings.TrimPrefix(in, "0x"))
+ if err != nil {
+ panic(fmt.Errorf("invalid hex: %q", in))
+ }
+ return common.BytesToHash(out)
+}
+
+func mustConvertAddress(in string) common.Address {
+ out, err := hex.DecodeString(strings.TrimPrefix(in, "0x"))
+ if err != nil {
+ panic(fmt.Errorf("invalid hex: %q", in))
+ }
+ return common.BytesToAddress(out)
+}
+
+func mustConvertBloom(in string) types.Bloom {
+ out, err := hex.DecodeString(strings.TrimPrefix(in, "0x"))
+ if err != nil {
+ panic(fmt.Errorf("invalid hex: %q", in))
+ }
+ return types.BytesToBloom(out)
+}
+
+func mustConvertBigInt10(in string) *big.Int {
+ out, ok := new(big.Int).SetString(in, 10)
+ if !ok {
+ panic(fmt.Errorf("invalid integer: %q", in))
+ }
+ return out
+}
+
+func mustConvertUint(in string) uint64 {
+ out, err := strconv.ParseUint(in, 0, 64)
+ if err != nil {
+ panic(fmt.Errorf("invalid integer: %q", in))
+ }
+ return out
+}
+
+// loadJSON reads the given file and unmarshals its content.
+func loadJSON(file string, val interface{}) error {
+ content, err := ioutil.ReadFile(file)
+ if err != nil {
+ return err
+ }
+ if err := json.Unmarshal(content, val); err != nil {
+ if syntaxerr, ok := err.(*json.SyntaxError); ok {
+ line := findLine(content, syntaxerr.Offset)
+ return fmt.Errorf("JSON syntax error at %v:%v: %v", file, line, err)
+ }
+ return fmt.Errorf("JSON unmarshal error in %v: %v", file, err)
+ }
+ return nil
+}
+
+// findLine returns the line number for the given offset into data.
+func findLine(data []byte, offset int64) (line int) {
+ line = 1
+ for i, r := range string(data) {
+ if int64(i) >= offset {
+ return
+ }
+ if r == '\n' {
+ line++
+ }
+ }
+ return
+}
diff --git a/tests/files/.gitignore b/tests/files/.gitignore
new file mode 100644
index 000000000..188ff005d
--- /dev/null
+++ b/tests/files/.gitignore
@@ -0,0 +1,5 @@
+venv/
+*~
+*.sw?
+.vagrant/
+*.pem
diff --git a/BasicTests/blockgenesistest.json b/tests/files/BasicTests/blockgenesistest.json
index 8ad5590f1..8ad5590f1 100644
--- a/BasicTests/blockgenesistest.json
+++ b/tests/files/BasicTests/blockgenesistest.json
diff --git a/BasicTests/crypto.json b/tests/files/BasicTests/crypto.json
index 64a4f8842..64a4f8842 100644
--- a/BasicTests/crypto.json
+++ b/tests/files/BasicTests/crypto.json
diff --git a/BasicTests/genesishashestest.json b/tests/files/BasicTests/genesishashestest.json
index 4687cab9b..4687cab9b 100644
--- a/BasicTests/genesishashestest.json
+++ b/tests/files/BasicTests/genesishashestest.json
diff --git a/BasicTests/hexencodetest.json b/tests/files/BasicTests/hexencodetest.json
index 26c5bc7ed..26c5bc7ed 100644
--- a/BasicTests/hexencodetest.json
+++ b/tests/files/BasicTests/hexencodetest.json
diff --git a/BasicTests/keyaddrtest.json b/tests/files/BasicTests/keyaddrtest.json
index c65b2ae33..c65b2ae33 100644
--- a/BasicTests/keyaddrtest.json
+++ b/tests/files/BasicTests/keyaddrtest.json
diff --git a/BasicTests/rlptest.json b/tests/files/BasicTests/rlptest.json
index 19adbb8e2..19adbb8e2 100644
--- a/BasicTests/rlptest.json
+++ b/tests/files/BasicTests/rlptest.json
diff --git a/BasicTests/txtest.json b/tests/files/BasicTests/txtest.json
index 1261d0766..1261d0766 100644
--- a/BasicTests/txtest.json
+++ b/tests/files/BasicTests/txtest.json
diff --git a/BlockTests/bcInvalidHeaderTest.json b/tests/files/BlockTests/bcInvalidHeaderTest.json
index bd39992dd..bd39992dd 100644
--- a/BlockTests/bcInvalidHeaderTest.json
+++ b/tests/files/BlockTests/bcInvalidHeaderTest.json
diff --git a/BlockTests/bcInvalidRLPTest.json b/tests/files/BlockTests/bcInvalidRLPTest.json
index a1e8839ac..a1e8839ac 100644
--- a/BlockTests/bcInvalidRLPTest.json
+++ b/tests/files/BlockTests/bcInvalidRLPTest.json
diff --git a/BlockTests/bcJS_API_Test.json b/tests/files/BlockTests/bcJS_API_Test.json
index 5c07f9ffb..5c07f9ffb 100644
--- a/BlockTests/bcJS_API_Test.json
+++ b/tests/files/BlockTests/bcJS_API_Test.json
diff --git a/BlockTests/bcUncleTest.json b/tests/files/BlockTests/bcUncleTest.json
index 5638a354a..5638a354a 100644
--- a/BlockTests/bcUncleTest.json
+++ b/tests/files/BlockTests/bcUncleTest.json
diff --git a/BlockTests/bcValidBlockTest.json b/tests/files/BlockTests/bcValidBlockTest.json
index 8f432e725..8f432e725 100644
--- a/BlockTests/bcValidBlockTest.json
+++ b/tests/files/BlockTests/bcValidBlockTest.json
diff --git a/BlockchainTests/badBlockChain.json b/tests/files/BlockchainTests/badBlockChain.json
index 78c5e8c49..78c5e8c49 100644
--- a/BlockchainTests/badBlockChain.json
+++ b/tests/files/BlockchainTests/badBlockChain.json
diff --git a/BlockchainTests/basicBlockChain.json b/tests/files/BlockchainTests/basicBlockChain.json
index 4cda9964b..4cda9964b 100644
--- a/BlockchainTests/basicBlockChain.json
+++ b/tests/files/BlockchainTests/basicBlockChain.json
diff --git a/PoWTests/ethash_tests.json b/tests/files/PoWTests/ethash_tests.json
index ceacd78a7..ceacd78a7 100644
--- a/PoWTests/ethash_tests.json
+++ b/tests/files/PoWTests/ethash_tests.json
diff --git a/tests/files/README.md b/tests/files/README.md
new file mode 100644
index 000000000..0f7dbe5a6
--- /dev/null
+++ b/tests/files/README.md
@@ -0,0 +1,26 @@
+tests
+=====
+
+Common tests for all clients to test against.
+
+All files should be of the form:
+
+```
+{
+ "test1name":
+ {
+ "test1property1": ...,
+ "test1property2": ...,
+ ...
+ },
+ "test2name":
+ {
+ "test2property1": ...,
+ "test2property2": ...,
+ ...
+ }
+}
+```
+
+Arrays are allowed, but don't use them for sets of properties - only use them for data that is clearly a continuous contiguous sequence of values.
+
diff --git a/StateTests/RandomTests/st201503121803PYTHON.json b/tests/files/StateTests/RandomTests/st201503121803PYTHON.json
index aa6ade198..aa6ade198 100644
--- a/StateTests/RandomTests/st201503121803PYTHON.json
+++ b/tests/files/StateTests/RandomTests/st201503121803PYTHON.json
diff --git a/StateTests/RandomTests/st201503121806PYTHON.json b/tests/files/StateTests/RandomTests/st201503121806PYTHON.json
index 4cff23f02..4cff23f02 100644
--- a/StateTests/RandomTests/st201503121806PYTHON.json
+++ b/tests/files/StateTests/RandomTests/st201503121806PYTHON.json
diff --git a/StateTests/RandomTests/st201503121848GO.json b/tests/files/StateTests/RandomTests/st201503121848GO.json
index 8c339ebce..8c339ebce 100644
--- a/StateTests/RandomTests/st201503121848GO.json
+++ b/tests/files/StateTests/RandomTests/st201503121848GO.json
diff --git a/StateTests/RandomTests/st201503121849GO.json b/tests/files/StateTests/RandomTests/st201503121849GO.json
index 6f4f716d8..6f4f716d8 100644
--- a/StateTests/RandomTests/st201503121849GO.json
+++ b/tests/files/StateTests/RandomTests/st201503121849GO.json
diff --git a/StateTests/RandomTests/st201503121850GO.json b/tests/files/StateTests/RandomTests/st201503121850GO.json
index a25986314..a25986314 100644
--- a/StateTests/RandomTests/st201503121850GO.json
+++ b/tests/files/StateTests/RandomTests/st201503121850GO.json
diff --git a/StateTests/RandomTests/st201503121851GO.json b/tests/files/StateTests/RandomTests/st201503121851GO.json
index b14f68a2f..b14f68a2f 100644
--- a/StateTests/RandomTests/st201503121851GO.json
+++ b/tests/files/StateTests/RandomTests/st201503121851GO.json
diff --git a/StateTests/RandomTests/st201503121953GO.json b/tests/files/StateTests/RandomTests/st201503121953GO.json
index d1c10f7f2..d1c10f7f2 100644
--- a/StateTests/RandomTests/st201503121953GO.json
+++ b/tests/files/StateTests/RandomTests/st201503121953GO.json
diff --git a/StateTests/RandomTests/st201503122023GO.json b/tests/files/StateTests/RandomTests/st201503122023GO.json
index a809a6888..a809a6888 100644
--- a/StateTests/RandomTests/st201503122023GO.json
+++ b/tests/files/StateTests/RandomTests/st201503122023GO.json
diff --git a/StateTests/RandomTests/st201503122023PYTHON.json b/tests/files/StateTests/RandomTests/st201503122023PYTHON.json
index a809a6888..a809a6888 100644
--- a/StateTests/RandomTests/st201503122023PYTHON.json
+++ b/tests/files/StateTests/RandomTests/st201503122023PYTHON.json
diff --git a/StateTests/RandomTests/st201503122027GO.json b/tests/files/StateTests/RandomTests/st201503122027GO.json
index 3ad4ebee0..3ad4ebee0 100644
--- a/StateTests/RandomTests/st201503122027GO.json
+++ b/tests/files/StateTests/RandomTests/st201503122027GO.json
diff --git a/StateTests/RandomTests/st201503122054GO.json b/tests/files/StateTests/RandomTests/st201503122054GO.json
index ff92b2efc..ff92b2efc 100644
--- a/StateTests/RandomTests/st201503122054GO.json
+++ b/tests/files/StateTests/RandomTests/st201503122054GO.json
diff --git a/StateTests/RandomTests/st201503122055GO.json b/tests/files/StateTests/RandomTests/st201503122055GO.json
index cd9e4fcfa..cd9e4fcfa 100644
--- a/StateTests/RandomTests/st201503122055GO.json
+++ b/tests/files/StateTests/RandomTests/st201503122055GO.json
diff --git a/StateTests/RandomTests/st201503122115CPPJIT.json b/tests/files/StateTests/RandomTests/st201503122115CPPJIT.json
index 7e99b5d82..7e99b5d82 100644
--- a/StateTests/RandomTests/st201503122115CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503122115CPPJIT.json
diff --git a/StateTests/RandomTests/st201503122115GO.json b/tests/files/StateTests/RandomTests/st201503122115GO.json
index 7e99b5d82..7e99b5d82 100644
--- a/StateTests/RandomTests/st201503122115GO.json
+++ b/tests/files/StateTests/RandomTests/st201503122115GO.json
diff --git a/StateTests/RandomTests/st201503122123GO.json b/tests/files/StateTests/RandomTests/st201503122123GO.json
index f3edd668c..f3edd668c 100644
--- a/StateTests/RandomTests/st201503122123GO.json
+++ b/tests/files/StateTests/RandomTests/st201503122123GO.json
diff --git a/StateTests/RandomTests/st201503122124GO.json b/tests/files/StateTests/RandomTests/st201503122124GO.json
index 96bb8c03e..96bb8c03e 100644
--- a/StateTests/RandomTests/st201503122124GO.json
+++ b/tests/files/StateTests/RandomTests/st201503122124GO.json
diff --git a/StateTests/RandomTests/st201503122128PYTHON.json b/tests/files/StateTests/RandomTests/st201503122128PYTHON.json
index 6d79b7584..6d79b7584 100644
--- a/StateTests/RandomTests/st201503122128PYTHON.json
+++ b/tests/files/StateTests/RandomTests/st201503122128PYTHON.json
diff --git a/StateTests/RandomTests/st201503122140GO.json b/tests/files/StateTests/RandomTests/st201503122140GO.json
index 89e4d9765..89e4d9765 100644
--- a/StateTests/RandomTests/st201503122140GO.json
+++ b/tests/files/StateTests/RandomTests/st201503122140GO.json
diff --git a/StateTests/RandomTests/st201503122159GO.json b/tests/files/StateTests/RandomTests/st201503122159GO.json
index c9e7c7f9a..c9e7c7f9a 100644
--- a/StateTests/RandomTests/st201503122159GO.json
+++ b/tests/files/StateTests/RandomTests/st201503122159GO.json
diff --git a/StateTests/RandomTests/st201503122204GO.json b/tests/files/StateTests/RandomTests/st201503122204GO.json
index c888af2ad..c888af2ad 100644
--- a/StateTests/RandomTests/st201503122204GO.json
+++ b/tests/files/StateTests/RandomTests/st201503122204GO.json
diff --git a/StateTests/RandomTests/st201503122212GO.json b/tests/files/StateTests/RandomTests/st201503122212GO.json
index 90d652955..90d652955 100644
--- a/StateTests/RandomTests/st201503122212GO.json
+++ b/tests/files/StateTests/RandomTests/st201503122212GO.json
diff --git a/StateTests/RandomTests/st201503122231GO.json b/tests/files/StateTests/RandomTests/st201503122231GO.json
index 30df87fe8..30df87fe8 100644
--- a/StateTests/RandomTests/st201503122231GO.json
+++ b/tests/files/StateTests/RandomTests/st201503122231GO.json
diff --git a/StateTests/RandomTests/st201503122238GO.json b/tests/files/StateTests/RandomTests/st201503122238GO.json
index 7a459d82f..7a459d82f 100644
--- a/StateTests/RandomTests/st201503122238GO.json
+++ b/tests/files/StateTests/RandomTests/st201503122238GO.json
diff --git a/StateTests/RandomTests/st201503122252GO.json b/tests/files/StateTests/RandomTests/st201503122252GO.json
index 7fe4a9abb..7fe4a9abb 100644
--- a/StateTests/RandomTests/st201503122252GO.json
+++ b/tests/files/StateTests/RandomTests/st201503122252GO.json
diff --git a/StateTests/RandomTests/st201503122316GO.json b/tests/files/StateTests/RandomTests/st201503122316GO.json
index 82fec2041..82fec2041 100644
--- a/StateTests/RandomTests/st201503122316GO.json
+++ b/tests/files/StateTests/RandomTests/st201503122316GO.json
diff --git a/StateTests/RandomTests/st201503122324GO.json b/tests/files/StateTests/RandomTests/st201503122324GO.json
index 6b8b35c2b..6b8b35c2b 100644
--- a/StateTests/RandomTests/st201503122324GO.json
+++ b/tests/files/StateTests/RandomTests/st201503122324GO.json
diff --git a/StateTests/RandomTests/st201503122358GO.json b/tests/files/StateTests/RandomTests/st201503122358GO.json
index 4dc049efd..4dc049efd 100644
--- a/StateTests/RandomTests/st201503122358GO.json
+++ b/tests/files/StateTests/RandomTests/st201503122358GO.json
diff --git a/StateTests/RandomTests/st201503130002GO.json b/tests/files/StateTests/RandomTests/st201503130002GO.json
index 9342f274d..9342f274d 100644
--- a/StateTests/RandomTests/st201503130002GO.json
+++ b/tests/files/StateTests/RandomTests/st201503130002GO.json
diff --git a/StateTests/RandomTests/st201503130005GO.json b/tests/files/StateTests/RandomTests/st201503130005GO.json
index 878fbbaf9..878fbbaf9 100644
--- a/StateTests/RandomTests/st201503130005GO.json
+++ b/tests/files/StateTests/RandomTests/st201503130005GO.json
diff --git a/StateTests/RandomTests/st201503130007GO.json b/tests/files/StateTests/RandomTests/st201503130007GO.json
index 9fcfde44c..9fcfde44c 100644
--- a/StateTests/RandomTests/st201503130007GO.json
+++ b/tests/files/StateTests/RandomTests/st201503130007GO.json
diff --git a/StateTests/RandomTests/st201503130010GO.json b/tests/files/StateTests/RandomTests/st201503130010GO.json
index 2d8a464a0..2d8a464a0 100644
--- a/StateTests/RandomTests/st201503130010GO.json
+++ b/tests/files/StateTests/RandomTests/st201503130010GO.json
diff --git a/StateTests/RandomTests/st201503130023PYTHON.json b/tests/files/StateTests/RandomTests/st201503130023PYTHON.json
index 520b73083..520b73083 100644
--- a/StateTests/RandomTests/st201503130023PYTHON.json
+++ b/tests/files/StateTests/RandomTests/st201503130023PYTHON.json
diff --git a/StateTests/RandomTests/st201503130059GO.json b/tests/files/StateTests/RandomTests/st201503130059GO.json
index fb02264c8..fb02264c8 100644
--- a/StateTests/RandomTests/st201503130059GO.json
+++ b/tests/files/StateTests/RandomTests/st201503130059GO.json
diff --git a/StateTests/RandomTests/st201503130101GO.json b/tests/files/StateTests/RandomTests/st201503130101GO.json
index 082be8453..082be8453 100644
--- a/StateTests/RandomTests/st201503130101GO.json
+++ b/tests/files/StateTests/RandomTests/st201503130101GO.json
diff --git a/StateTests/RandomTests/st201503130109GO.json b/tests/files/StateTests/RandomTests/st201503130109GO.json
index 2cae9bca2..2cae9bca2 100644
--- a/StateTests/RandomTests/st201503130109GO.json
+++ b/tests/files/StateTests/RandomTests/st201503130109GO.json
diff --git a/StateTests/RandomTests/st201503130117GO.json b/tests/files/StateTests/RandomTests/st201503130117GO.json
index 01e46e1c6..01e46e1c6 100644
--- a/StateTests/RandomTests/st201503130117GO.json
+++ b/tests/files/StateTests/RandomTests/st201503130117GO.json
diff --git a/StateTests/RandomTests/st201503130122GO.json b/tests/files/StateTests/RandomTests/st201503130122GO.json
index 462411e52..462411e52 100644
--- a/StateTests/RandomTests/st201503130122GO.json
+++ b/tests/files/StateTests/RandomTests/st201503130122GO.json
diff --git a/StateTests/RandomTests/st201503130156GO.json b/tests/files/StateTests/RandomTests/st201503130156GO.json
index 876e65fae..876e65fae 100644
--- a/StateTests/RandomTests/st201503130156GO.json
+++ b/tests/files/StateTests/RandomTests/st201503130156GO.json
diff --git a/StateTests/RandomTests/st201503130156PYTHON.json b/tests/files/StateTests/RandomTests/st201503130156PYTHON.json
index 3dbb6c830..3dbb6c830 100644
--- a/StateTests/RandomTests/st201503130156PYTHON.json
+++ b/tests/files/StateTests/RandomTests/st201503130156PYTHON.json
diff --git a/StateTests/RandomTests/st201503130207GO.json b/tests/files/StateTests/RandomTests/st201503130207GO.json
index 795bdfa63..795bdfa63 100644
--- a/StateTests/RandomTests/st201503130207GO.json
+++ b/tests/files/StateTests/RandomTests/st201503130207GO.json
diff --git a/StateTests/RandomTests/st201503130219CPPJIT.json b/tests/files/StateTests/RandomTests/st201503130219CPPJIT.json
index 257e70a34..257e70a34 100644
--- a/StateTests/RandomTests/st201503130219CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503130219CPPJIT.json
diff --git a/StateTests/RandomTests/st201503130219GO.json b/tests/files/StateTests/RandomTests/st201503130219GO.json
index 257e70a34..257e70a34 100644
--- a/StateTests/RandomTests/st201503130219GO.json
+++ b/tests/files/StateTests/RandomTests/st201503130219GO.json
diff --git a/StateTests/RandomTests/st201503130243GO.json b/tests/files/StateTests/RandomTests/st201503130243GO.json
index d16616a55..d16616a55 100644
--- a/StateTests/RandomTests/st201503130243GO.json
+++ b/tests/files/StateTests/RandomTests/st201503130243GO.json
diff --git a/StateTests/RandomTests/st201503130246GO.json b/tests/files/StateTests/RandomTests/st201503130246GO.json
index 1d927b88a..1d927b88a 100644
--- a/StateTests/RandomTests/st201503130246GO.json
+++ b/tests/files/StateTests/RandomTests/st201503130246GO.json
diff --git a/StateTests/RandomTests/st201503130321GO.json b/tests/files/StateTests/RandomTests/st201503130321GO.json
index 766ac8c98..766ac8c98 100644
--- a/StateTests/RandomTests/st201503130321GO.json
+++ b/tests/files/StateTests/RandomTests/st201503130321GO.json
diff --git a/StateTests/RandomTests/st201503130322GO.json b/tests/files/StateTests/RandomTests/st201503130322GO.json
index 564bb2e10..564bb2e10 100644
--- a/StateTests/RandomTests/st201503130322GO.json
+++ b/tests/files/StateTests/RandomTests/st201503130322GO.json
diff --git a/StateTests/RandomTests/st201503130332GO.json b/tests/files/StateTests/RandomTests/st201503130332GO.json
index 7498e0816..7498e0816 100644
--- a/StateTests/RandomTests/st201503130332GO.json
+++ b/tests/files/StateTests/RandomTests/st201503130332GO.json
diff --git a/StateTests/RandomTests/st201503130359GO.json b/tests/files/StateTests/RandomTests/st201503130359GO.json
index 6ef42fd94..6ef42fd94 100644
--- a/StateTests/RandomTests/st201503130359GO.json
+++ b/tests/files/StateTests/RandomTests/st201503130359GO.json
diff --git a/StateTests/RandomTests/st201503130405GO.json b/tests/files/StateTests/RandomTests/st201503130405GO.json
index f8a23b4ab..f8a23b4ab 100644
--- a/StateTests/RandomTests/st201503130405GO.json
+++ b/tests/files/StateTests/RandomTests/st201503130405GO.json
diff --git a/StateTests/RandomTests/st201503130408GO.json b/tests/files/StateTests/RandomTests/st201503130408GO.json
index 4809df125..4809df125 100644
--- a/StateTests/RandomTests/st201503130408GO.json
+++ b/tests/files/StateTests/RandomTests/st201503130408GO.json
diff --git a/StateTests/RandomTests/st201503130411GO.json b/tests/files/StateTests/RandomTests/st201503130411GO.json
index 763a2be72..763a2be72 100644
--- a/StateTests/RandomTests/st201503130411GO.json
+++ b/tests/files/StateTests/RandomTests/st201503130411GO.json
diff --git a/StateTests/RandomTests/st201503130431GO.json b/tests/files/StateTests/RandomTests/st201503130431GO.json
index e76d1d658..e76d1d658 100644
--- a/StateTests/RandomTests/st201503130431GO.json
+++ b/tests/files/StateTests/RandomTests/st201503130431GO.json
diff --git a/StateTests/RandomTests/st201503130437GO.json b/tests/files/StateTests/RandomTests/st201503130437GO.json
index 028279ff0..028279ff0 100644
--- a/StateTests/RandomTests/st201503130437GO.json
+++ b/tests/files/StateTests/RandomTests/st201503130437GO.json
diff --git a/StateTests/RandomTests/st201503130450GO.json b/tests/files/StateTests/RandomTests/st201503130450GO.json
index d860cf86e..d860cf86e 100644
--- a/StateTests/RandomTests/st201503130450GO.json
+++ b/tests/files/StateTests/RandomTests/st201503130450GO.json
diff --git a/StateTests/RandomTests/st201503130512CPPJIT.json b/tests/files/StateTests/RandomTests/st201503130512CPPJIT.json
index a4111beeb..a4111beeb 100644
--- a/StateTests/RandomTests/st201503130512CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503130512CPPJIT.json
diff --git a/StateTests/RandomTests/st201503130512GO.json b/tests/files/StateTests/RandomTests/st201503130512GO.json
index a4111beeb..a4111beeb 100644
--- a/StateTests/RandomTests/st201503130512GO.json
+++ b/tests/files/StateTests/RandomTests/st201503130512GO.json
diff --git a/StateTests/RandomTests/st201503130615GO.json b/tests/files/StateTests/RandomTests/st201503130615GO.json
index 575756f59..575756f59 100644
--- a/StateTests/RandomTests/st201503130615GO.json
+++ b/tests/files/StateTests/RandomTests/st201503130615GO.json
diff --git a/StateTests/RandomTests/st201503130705GO.json b/tests/files/StateTests/RandomTests/st201503130705GO.json
index 1dadca4cf..1dadca4cf 100644
--- a/StateTests/RandomTests/st201503130705GO.json
+++ b/tests/files/StateTests/RandomTests/st201503130705GO.json
diff --git a/StateTests/RandomTests/st201503130733CPPJIT.json b/tests/files/StateTests/RandomTests/st201503130733CPPJIT.json
index 65a679be8..65a679be8 100644
--- a/StateTests/RandomTests/st201503130733CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503130733CPPJIT.json
diff --git a/StateTests/RandomTests/st201503130733GO.json b/tests/files/StateTests/RandomTests/st201503130733GO.json
index 65a679be8..65a679be8 100644
--- a/StateTests/RandomTests/st201503130733GO.json
+++ b/tests/files/StateTests/RandomTests/st201503130733GO.json
diff --git a/StateTests/RandomTests/st201503130747GO.json b/tests/files/StateTests/RandomTests/st201503130747GO.json
index 0107d5309..0107d5309 100644
--- a/StateTests/RandomTests/st201503130747GO.json
+++ b/tests/files/StateTests/RandomTests/st201503130747GO.json
diff --git a/StateTests/RandomTests/st201503130751GO.json b/tests/files/StateTests/RandomTests/st201503130751GO.json
index 9b12f01dd..9b12f01dd 100644
--- a/StateTests/RandomTests/st201503130751GO.json
+++ b/tests/files/StateTests/RandomTests/st201503130751GO.json
diff --git a/StateTests/RandomTests/st201503130752PYTHON.json b/tests/files/StateTests/RandomTests/st201503130752PYTHON.json
index 1975c1bb8..1975c1bb8 100644
--- a/StateTests/RandomTests/st201503130752PYTHON.json
+++ b/tests/files/StateTests/RandomTests/st201503130752PYTHON.json
diff --git a/StateTests/RandomTests/st201503130757PYTHON.json b/tests/files/StateTests/RandomTests/st201503130757PYTHON.json
index cfb2da72d..cfb2da72d 100644
--- a/StateTests/RandomTests/st201503130757PYTHON.json
+++ b/tests/files/StateTests/RandomTests/st201503130757PYTHON.json
diff --git a/StateTests/RandomTests/st201503131658GO.json b/tests/files/StateTests/RandomTests/st201503131658GO.json
index 9f9db88ad..9f9db88ad 100644
--- a/StateTests/RandomTests/st201503131658GO.json
+++ b/tests/files/StateTests/RandomTests/st201503131658GO.json
diff --git a/StateTests/RandomTests/st201503131739GO.json b/tests/files/StateTests/RandomTests/st201503131739GO.json
index 2c3e4b32b..2c3e4b32b 100644
--- a/StateTests/RandomTests/st201503131739GO.json
+++ b/tests/files/StateTests/RandomTests/st201503131739GO.json
diff --git a/StateTests/RandomTests/st201503131755CPPJIT.json b/tests/files/StateTests/RandomTests/st201503131755CPPJIT.json
index dbfda6332..dbfda6332 100644
--- a/StateTests/RandomTests/st201503131755CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503131755CPPJIT.json
diff --git a/StateTests/RandomTests/st201503131755GO.json b/tests/files/StateTests/RandomTests/st201503131755GO.json
index dbfda6332..dbfda6332 100644
--- a/StateTests/RandomTests/st201503131755GO.json
+++ b/tests/files/StateTests/RandomTests/st201503131755GO.json
diff --git a/StateTests/RandomTests/st201503132001CPPJIT.json b/tests/files/StateTests/RandomTests/st201503132001CPPJIT.json
index 2ff2c7135..2ff2c7135 100644
--- a/StateTests/RandomTests/st201503132001CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503132001CPPJIT.json
diff --git a/StateTests/RandomTests/st201503132127PYTHON.json b/tests/files/StateTests/RandomTests/st201503132127PYTHON.json
index 7d81effa8..7d81effa8 100644
--- a/StateTests/RandomTests/st201503132127PYTHON.json
+++ b/tests/files/StateTests/RandomTests/st201503132127PYTHON.json
diff --git a/StateTests/RandomTests/st201503132201CPPJIT.json b/tests/files/StateTests/RandomTests/st201503132201CPPJIT.json
index 10cf91614..10cf91614 100644
--- a/StateTests/RandomTests/st201503132201CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503132201CPPJIT.json
diff --git a/StateTests/RandomTests/st201503132201GO.json b/tests/files/StateTests/RandomTests/st201503132201GO.json
index 10cf91614..10cf91614 100644
--- a/StateTests/RandomTests/st201503132201GO.json
+++ b/tests/files/StateTests/RandomTests/st201503132201GO.json
diff --git a/StateTests/RandomTests/st201503132202PYTHON.json b/tests/files/StateTests/RandomTests/st201503132202PYTHON.json
index 231f70273..231f70273 100644
--- a/StateTests/RandomTests/st201503132202PYTHON.json
+++ b/tests/files/StateTests/RandomTests/st201503132202PYTHON.json
diff --git a/StateTests/RandomTests/st201503140002PYTHON.json b/tests/files/StateTests/RandomTests/st201503140002PYTHON.json
index 162e68fc0..162e68fc0 100644
--- a/StateTests/RandomTests/st201503140002PYTHON.json
+++ b/tests/files/StateTests/RandomTests/st201503140002PYTHON.json
diff --git a/StateTests/RandomTests/st201503140240PYTHON.json b/tests/files/StateTests/RandomTests/st201503140240PYTHON.json
index f313315af..f313315af 100644
--- a/StateTests/RandomTests/st201503140240PYTHON.json
+++ b/tests/files/StateTests/RandomTests/st201503140240PYTHON.json
diff --git a/StateTests/RandomTests/st201503140522PYTHON.json b/tests/files/StateTests/RandomTests/st201503140522PYTHON.json
index fbb51ea51..fbb51ea51 100644
--- a/StateTests/RandomTests/st201503140522PYTHON.json
+++ b/tests/files/StateTests/RandomTests/st201503140522PYTHON.json
diff --git a/StateTests/RandomTests/st201503140756PYTHON.json b/tests/files/StateTests/RandomTests/st201503140756PYTHON.json
index d18cf91e5..d18cf91e5 100644
--- a/StateTests/RandomTests/st201503140756PYTHON.json
+++ b/tests/files/StateTests/RandomTests/st201503140756PYTHON.json
diff --git a/StateTests/RandomTests/st201503141144PYTHON.json b/tests/files/StateTests/RandomTests/st201503141144PYTHON.json
index e74776d7c..e74776d7c 100644
--- a/StateTests/RandomTests/st201503141144PYTHON.json
+++ b/tests/files/StateTests/RandomTests/st201503141144PYTHON.json
diff --git a/StateTests/RandomTests/st201503141510PYTHON.json b/tests/files/StateTests/RandomTests/st201503141510PYTHON.json
index 10e3f3711..10e3f3711 100644
--- a/StateTests/RandomTests/st201503141510PYTHON.json
+++ b/tests/files/StateTests/RandomTests/st201503141510PYTHON.json
diff --git a/StateTests/RandomTests/st201503150427PYTHON.json b/tests/files/StateTests/RandomTests/st201503150427PYTHON.json
index 33297298d..33297298d 100644
--- a/StateTests/RandomTests/st201503150427PYTHON.json
+++ b/tests/files/StateTests/RandomTests/st201503150427PYTHON.json
diff --git a/StateTests/RandomTests/st201503150716PYTHON.json b/tests/files/StateTests/RandomTests/st201503150716PYTHON.json
index 7928adeb1..7928adeb1 100644
--- a/StateTests/RandomTests/st201503150716PYTHON.json
+++ b/tests/files/StateTests/RandomTests/st201503150716PYTHON.json
diff --git a/StateTests/RandomTests/st201503151450PYTHON.json b/tests/files/StateTests/RandomTests/st201503151450PYTHON.json
index 39cac070c..39cac070c 100644
--- a/StateTests/RandomTests/st201503151450PYTHON.json
+++ b/tests/files/StateTests/RandomTests/st201503151450PYTHON.json
diff --git a/StateTests/RandomTests/st201503151516PYTHON.json b/tests/files/StateTests/RandomTests/st201503151516PYTHON.json
index 05ce7e2dd..05ce7e2dd 100644
--- a/StateTests/RandomTests/st201503151516PYTHON.json
+++ b/tests/files/StateTests/RandomTests/st201503151516PYTHON.json
diff --git a/StateTests/RandomTests/st201503151753PYTHON.json b/tests/files/StateTests/RandomTests/st201503151753PYTHON.json
index 7245b5bf1..7245b5bf1 100644
--- a/StateTests/RandomTests/st201503151753PYTHON.json
+++ b/tests/files/StateTests/RandomTests/st201503151753PYTHON.json
diff --git a/StateTests/RandomTests/st201503152057PYTHON.json b/tests/files/StateTests/RandomTests/st201503152057PYTHON.json
index 9f6954cc7..9f6954cc7 100644
--- a/StateTests/RandomTests/st201503152057PYTHON.json
+++ b/tests/files/StateTests/RandomTests/st201503152057PYTHON.json
diff --git a/StateTests/RandomTests/st201503152241PYTHON.json b/tests/files/StateTests/RandomTests/st201503152241PYTHON.json
index 5757add05..5757add05 100644
--- a/StateTests/RandomTests/st201503152241PYTHON.json
+++ b/tests/files/StateTests/RandomTests/st201503152241PYTHON.json
diff --git a/StateTests/RandomTests/st201503160014PYTHON.json b/tests/files/StateTests/RandomTests/st201503160014PYTHON.json
index 0f4bbcb34..0f4bbcb34 100644
--- a/StateTests/RandomTests/st201503160014PYTHON.json
+++ b/tests/files/StateTests/RandomTests/st201503160014PYTHON.json
diff --git a/StateTests/RandomTests/st201503160733PYTHON.json b/tests/files/StateTests/RandomTests/st201503160733PYTHON.json
index e2510fc6a..e2510fc6a 100644
--- a/StateTests/RandomTests/st201503160733PYTHON.json
+++ b/tests/files/StateTests/RandomTests/st201503160733PYTHON.json
diff --git a/StateTests/RandomTests/st201503170051PYTHON.json b/tests/files/StateTests/RandomTests/st201503170051PYTHON.json
index e3c6ee2d0..e3c6ee2d0 100644
--- a/StateTests/RandomTests/st201503170051PYTHON.json
+++ b/tests/files/StateTests/RandomTests/st201503170051PYTHON.json
diff --git a/StateTests/RandomTests/st201503170433PYTHON.json b/tests/files/StateTests/RandomTests/st201503170433PYTHON.json
index efc0dd65c..efc0dd65c 100644
--- a/StateTests/RandomTests/st201503170433PYTHON.json
+++ b/tests/files/StateTests/RandomTests/st201503170433PYTHON.json
diff --git a/StateTests/RandomTests/st201503170523PYTHON.json b/tests/files/StateTests/RandomTests/st201503170523PYTHON.json
index 664601c56..664601c56 100644
--- a/StateTests/RandomTests/st201503170523PYTHON.json
+++ b/tests/files/StateTests/RandomTests/st201503170523PYTHON.json
diff --git a/StateTests/RandomTests/st201503171108PYTHON.json b/tests/files/StateTests/RandomTests/st201503171108PYTHON.json
index 59e9480d3..59e9480d3 100644
--- a/StateTests/RandomTests/st201503171108PYTHON.json
+++ b/tests/files/StateTests/RandomTests/st201503171108PYTHON.json
diff --git a/StateTests/RandomTests/st201503181223GO.json b/tests/files/StateTests/RandomTests/st201503181223GO.json
index e77432400..e77432400 100644
--- a/StateTests/RandomTests/st201503181223GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181223GO.json
diff --git a/StateTests/RandomTests/st201503181225GO.json b/tests/files/StateTests/RandomTests/st201503181225GO.json
index 46023b6da..46023b6da 100644
--- a/StateTests/RandomTests/st201503181225GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181225GO.json
diff --git a/StateTests/RandomTests/st201503181226CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181226CPPJIT.json
index 1c8a936a9..1c8a936a9 100644
--- a/StateTests/RandomTests/st201503181226CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181226CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181227CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181227CPPJIT.json
index 4b2d080b4..4b2d080b4 100644
--- a/StateTests/RandomTests/st201503181227CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181227CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181227GO.json b/tests/files/StateTests/RandomTests/st201503181227GO.json
index 84668189b..84668189b 100644
--- a/StateTests/RandomTests/st201503181227GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181227GO.json
diff --git a/StateTests/RandomTests/st201503181229GO.json b/tests/files/StateTests/RandomTests/st201503181229GO.json
index 4fc8b548c..4fc8b548c 100644
--- a/StateTests/RandomTests/st201503181229GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181229GO.json
diff --git a/StateTests/RandomTests/st201503181230CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181230CPPJIT.json
index 2ab88ef34..2ab88ef34 100644
--- a/StateTests/RandomTests/st201503181230CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181230CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181230GO.json b/tests/files/StateTests/RandomTests/st201503181230GO.json
index 69e17d59e..69e17d59e 100644
--- a/StateTests/RandomTests/st201503181230GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181230GO.json
diff --git a/StateTests/RandomTests/st201503181231GO.json b/tests/files/StateTests/RandomTests/st201503181231GO.json
index d79afb876..d79afb876 100644
--- a/StateTests/RandomTests/st201503181231GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181231GO.json
diff --git a/StateTests/RandomTests/st201503181232CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181232CPPJIT.json
index 660738e2f..660738e2f 100644
--- a/StateTests/RandomTests/st201503181232CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181232CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181232GO.json b/tests/files/StateTests/RandomTests/st201503181232GO.json
index 04fb7e049..04fb7e049 100644
--- a/StateTests/RandomTests/st201503181232GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181232GO.json
diff --git a/StateTests/RandomTests/st201503181233GO.json b/tests/files/StateTests/RandomTests/st201503181233GO.json
index 1d16eaea1..1d16eaea1 100644
--- a/StateTests/RandomTests/st201503181233GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181233GO.json
diff --git a/StateTests/RandomTests/st201503181234CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181234CPPJIT.json
index e4e13685b..e4e13685b 100644
--- a/StateTests/RandomTests/st201503181234CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181234CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181234GO.json b/tests/files/StateTests/RandomTests/st201503181234GO.json
index 3e809bd43..3e809bd43 100644
--- a/StateTests/RandomTests/st201503181234GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181234GO.json
diff --git a/StateTests/RandomTests/st201503181235CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181235CPPJIT.json
index ed85c6c7d..ed85c6c7d 100644
--- a/StateTests/RandomTests/st201503181235CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181235CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181235GO.json b/tests/files/StateTests/RandomTests/st201503181235GO.json
index 2655a3a89..2655a3a89 100644
--- a/StateTests/RandomTests/st201503181235GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181235GO.json
diff --git a/StateTests/RandomTests/st201503181236GO.json b/tests/files/StateTests/RandomTests/st201503181236GO.json
index b0b095c80..b0b095c80 100644
--- a/StateTests/RandomTests/st201503181236GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181236GO.json
diff --git a/StateTests/RandomTests/st201503181237GO.json b/tests/files/StateTests/RandomTests/st201503181237GO.json
index 5119c4e7e..5119c4e7e 100644
--- a/StateTests/RandomTests/st201503181237GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181237GO.json
diff --git a/StateTests/RandomTests/st201503181239GO.json b/tests/files/StateTests/RandomTests/st201503181239GO.json
index dc5578c27..dc5578c27 100644
--- a/StateTests/RandomTests/st201503181239GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181239GO.json
diff --git a/StateTests/RandomTests/st201503181241CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181241CPPJIT.json
index 2110015bd..2110015bd 100644
--- a/StateTests/RandomTests/st201503181241CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181241CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181241GO.json b/tests/files/StateTests/RandomTests/st201503181241GO.json
index c17354336..c17354336 100644
--- a/StateTests/RandomTests/st201503181241GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181241GO.json
diff --git a/StateTests/RandomTests/st201503181243GO.json b/tests/files/StateTests/RandomTests/st201503181243GO.json
index 2943a6bbd..2943a6bbd 100644
--- a/StateTests/RandomTests/st201503181243GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181243GO.json
diff --git a/StateTests/RandomTests/st201503181244GO.json b/tests/files/StateTests/RandomTests/st201503181244GO.json
index 64c1d8b89..64c1d8b89 100644
--- a/StateTests/RandomTests/st201503181244GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181244GO.json
diff --git a/StateTests/RandomTests/st201503181245CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181245CPPJIT.json
index 39230c8c4..39230c8c4 100644
--- a/StateTests/RandomTests/st201503181245CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181245CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181245GO.json b/tests/files/StateTests/RandomTests/st201503181245GO.json
index 00e41a295..00e41a295 100644
--- a/StateTests/RandomTests/st201503181245GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181245GO.json
diff --git a/StateTests/RandomTests/st201503181246CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181246CPPJIT.json
index 9858b2130..9858b2130 100644
--- a/StateTests/RandomTests/st201503181246CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181246CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181246GO.json b/tests/files/StateTests/RandomTests/st201503181246GO.json
index 0e7dd8ce6..0e7dd8ce6 100644
--- a/StateTests/RandomTests/st201503181246GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181246GO.json
diff --git a/StateTests/RandomTests/st201503181247GO.json b/tests/files/StateTests/RandomTests/st201503181247GO.json
index 194865b29..194865b29 100644
--- a/StateTests/RandomTests/st201503181247GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181247GO.json
diff --git a/StateTests/RandomTests/st201503181248GO.json b/tests/files/StateTests/RandomTests/st201503181248GO.json
index 07b08b854..07b08b854 100644
--- a/StateTests/RandomTests/st201503181248GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181248GO.json
diff --git a/StateTests/RandomTests/st201503181249GO.json b/tests/files/StateTests/RandomTests/st201503181249GO.json
index 1b7fd747b..1b7fd747b 100644
--- a/StateTests/RandomTests/st201503181249GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181249GO.json
diff --git a/StateTests/RandomTests/st201503181250CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181250CPPJIT.json
index 7fab2fd3e..7fab2fd3e 100644
--- a/StateTests/RandomTests/st201503181250CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181250CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181250GO.json b/tests/files/StateTests/RandomTests/st201503181250GO.json
index 836172919..836172919 100644
--- a/StateTests/RandomTests/st201503181250GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181250GO.json
diff --git a/StateTests/RandomTests/st201503181251GO.json b/tests/files/StateTests/RandomTests/st201503181251GO.json
index 090af6e1c..090af6e1c 100644
--- a/StateTests/RandomTests/st201503181251GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181251GO.json
diff --git a/StateTests/RandomTests/st201503181252CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181252CPPJIT.json
index d3a5fbf25..d3a5fbf25 100644
--- a/StateTests/RandomTests/st201503181252CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181252CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181253GO.json b/tests/files/StateTests/RandomTests/st201503181253GO.json
index 6f0616558..6f0616558 100644
--- a/StateTests/RandomTests/st201503181253GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181253GO.json
diff --git a/StateTests/RandomTests/st201503181255CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181255CPPJIT.json
index 48a47fbf5..48a47fbf5 100644
--- a/StateTests/RandomTests/st201503181255CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181255CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181255GO.json b/tests/files/StateTests/RandomTests/st201503181255GO.json
index 213f5cbd5..213f5cbd5 100644
--- a/StateTests/RandomTests/st201503181255GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181255GO.json
diff --git a/StateTests/RandomTests/st201503181257GO.json b/tests/files/StateTests/RandomTests/st201503181257GO.json
index cfc731bde..cfc731bde 100644
--- a/StateTests/RandomTests/st201503181257GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181257GO.json
diff --git a/StateTests/RandomTests/st201503181258CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181258CPPJIT.json
index 6076b0040..6076b0040 100644
--- a/StateTests/RandomTests/st201503181258CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181258CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181258GO.json b/tests/files/StateTests/RandomTests/st201503181258GO.json
index 4bd21bf32..4bd21bf32 100644
--- a/StateTests/RandomTests/st201503181258GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181258GO.json
diff --git a/StateTests/RandomTests/st201503181301CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181301CPPJIT.json
index 1cd83cd63..1cd83cd63 100644
--- a/StateTests/RandomTests/st201503181301CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181301CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181301GO.json b/tests/files/StateTests/RandomTests/st201503181301GO.json
index e8dc5c53d..e8dc5c53d 100644
--- a/StateTests/RandomTests/st201503181301GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181301GO.json
diff --git a/StateTests/RandomTests/st201503181303GO.json b/tests/files/StateTests/RandomTests/st201503181303GO.json
index 4cc4aadf8..4cc4aadf8 100644
--- a/StateTests/RandomTests/st201503181303GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181303GO.json
diff --git a/StateTests/RandomTests/st201503181304GO.json b/tests/files/StateTests/RandomTests/st201503181304GO.json
index c56eca060..c56eca060 100644
--- a/StateTests/RandomTests/st201503181304GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181304GO.json
diff --git a/StateTests/RandomTests/st201503181305GO.json b/tests/files/StateTests/RandomTests/st201503181305GO.json
index 7e8502082..7e8502082 100644
--- a/StateTests/RandomTests/st201503181305GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181305GO.json
diff --git a/StateTests/RandomTests/st201503181306GO.json b/tests/files/StateTests/RandomTests/st201503181306GO.json
index a17d4a817..a17d4a817 100644
--- a/StateTests/RandomTests/st201503181306GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181306GO.json
diff --git a/StateTests/RandomTests/st201503181307CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181307CPPJIT.json
index 9a29c8f3b..9a29c8f3b 100644
--- a/StateTests/RandomTests/st201503181307CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181307CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181307GO.json b/tests/files/StateTests/RandomTests/st201503181307GO.json
index d045e0df3..d045e0df3 100644
--- a/StateTests/RandomTests/st201503181307GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181307GO.json
diff --git a/StateTests/RandomTests/st201503181308GO.json b/tests/files/StateTests/RandomTests/st201503181308GO.json
index a465adc26..a465adc26 100644
--- a/StateTests/RandomTests/st201503181308GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181308GO.json
diff --git a/StateTests/RandomTests/st201503181309GO.json b/tests/files/StateTests/RandomTests/st201503181309GO.json
index 70573f284..70573f284 100644
--- a/StateTests/RandomTests/st201503181309GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181309GO.json
diff --git a/StateTests/RandomTests/st201503181310GO.json b/tests/files/StateTests/RandomTests/st201503181310GO.json
index 97896a56e..97896a56e 100644
--- a/StateTests/RandomTests/st201503181310GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181310GO.json
diff --git a/StateTests/RandomTests/st201503181311GO.json b/tests/files/StateTests/RandomTests/st201503181311GO.json
index ddf9ed71a..ddf9ed71a 100644
--- a/StateTests/RandomTests/st201503181311GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181311GO.json
diff --git a/StateTests/RandomTests/st201503181313GO.json b/tests/files/StateTests/RandomTests/st201503181313GO.json
index d560a7995..d560a7995 100644
--- a/StateTests/RandomTests/st201503181313GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181313GO.json
diff --git a/StateTests/RandomTests/st201503181314GO.json b/tests/files/StateTests/RandomTests/st201503181314GO.json
index 7be59c0d0..7be59c0d0 100644
--- a/StateTests/RandomTests/st201503181314GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181314GO.json
diff --git a/StateTests/RandomTests/st201503181315CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181315CPPJIT.json
index 51369c41c..51369c41c 100644
--- a/StateTests/RandomTests/st201503181315CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181315CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181315GO.json b/tests/files/StateTests/RandomTests/st201503181315GO.json
index d0ae79370..d0ae79370 100644
--- a/StateTests/RandomTests/st201503181315GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181315GO.json
diff --git a/StateTests/RandomTests/st201503181316CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181316CPPJIT.json
index 2e7d8a57d..2e7d8a57d 100644
--- a/StateTests/RandomTests/st201503181316CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181316CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181316PYTHON.json b/tests/files/StateTests/RandomTests/st201503181316PYTHON.json
index 1d2cbbfc9..1d2cbbfc9 100644
--- a/StateTests/RandomTests/st201503181316PYTHON.json
+++ b/tests/files/StateTests/RandomTests/st201503181316PYTHON.json
diff --git a/StateTests/RandomTests/st201503181317GO.json b/tests/files/StateTests/RandomTests/st201503181317GO.json
index a76e391dd..a76e391dd 100644
--- a/StateTests/RandomTests/st201503181317GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181317GO.json
diff --git a/StateTests/RandomTests/st201503181318CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181318CPPJIT.json
index d186f83ee..d186f83ee 100644
--- a/StateTests/RandomTests/st201503181318CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181318CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181318GO.json b/tests/files/StateTests/RandomTests/st201503181318GO.json
index 8af247d7e..8af247d7e 100644
--- a/StateTests/RandomTests/st201503181318GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181318GO.json
diff --git a/StateTests/RandomTests/st201503181319GO.json b/tests/files/StateTests/RandomTests/st201503181319GO.json
index 9bdd4e376..9bdd4e376 100644
--- a/StateTests/RandomTests/st201503181319GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181319GO.json
diff --git a/StateTests/RandomTests/st201503181319PYTHON.json b/tests/files/StateTests/RandomTests/st201503181319PYTHON.json
index 343478498..343478498 100644
--- a/StateTests/RandomTests/st201503181319PYTHON.json
+++ b/tests/files/StateTests/RandomTests/st201503181319PYTHON.json
diff --git a/StateTests/RandomTests/st201503181322GO.json b/tests/files/StateTests/RandomTests/st201503181322GO.json
index 05da535ee..05da535ee 100644
--- a/StateTests/RandomTests/st201503181322GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181322GO.json
diff --git a/StateTests/RandomTests/st201503181323CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181323CPPJIT.json
index ffe27596d..ffe27596d 100644
--- a/StateTests/RandomTests/st201503181323CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181323CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181323GO.json b/tests/files/StateTests/RandomTests/st201503181323GO.json
index 665e920e3..665e920e3 100644
--- a/StateTests/RandomTests/st201503181323GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181323GO.json
diff --git a/StateTests/RandomTests/st201503181324GO.json b/tests/files/StateTests/RandomTests/st201503181324GO.json
index c70f6d620..c70f6d620 100644
--- a/StateTests/RandomTests/st201503181324GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181324GO.json
diff --git a/StateTests/RandomTests/st201503181325GO.json b/tests/files/StateTests/RandomTests/st201503181325GO.json
index 243665ac3..243665ac3 100644
--- a/StateTests/RandomTests/st201503181325GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181325GO.json
diff --git a/StateTests/RandomTests/st201503181326CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181326CPPJIT.json
index e4463e134..e4463e134 100644
--- a/StateTests/RandomTests/st201503181326CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181326CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181326GO.json b/tests/files/StateTests/RandomTests/st201503181326GO.json
index a39ae84f5..a39ae84f5 100644
--- a/StateTests/RandomTests/st201503181326GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181326GO.json
diff --git a/StateTests/RandomTests/st201503181327GO.json b/tests/files/StateTests/RandomTests/st201503181327GO.json
index 3f1db217a..3f1db217a 100644
--- a/StateTests/RandomTests/st201503181327GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181327GO.json
diff --git a/StateTests/RandomTests/st201503181329CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181329CPPJIT.json
index 0b82a5c04..0b82a5c04 100644
--- a/StateTests/RandomTests/st201503181329CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181329CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181329GO.json b/tests/files/StateTests/RandomTests/st201503181329GO.json
index 2c1eeabfb..2c1eeabfb 100644
--- a/StateTests/RandomTests/st201503181329GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181329GO.json
diff --git a/StateTests/RandomTests/st201503181330GO.json b/tests/files/StateTests/RandomTests/st201503181330GO.json
index 88131ce34..88131ce34 100644
--- a/StateTests/RandomTests/st201503181330GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181330GO.json
diff --git a/StateTests/RandomTests/st201503181332GO.json b/tests/files/StateTests/RandomTests/st201503181332GO.json
index 02abdbc56..02abdbc56 100644
--- a/StateTests/RandomTests/st201503181332GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181332GO.json
diff --git a/StateTests/RandomTests/st201503181333GO.json b/tests/files/StateTests/RandomTests/st201503181333GO.json
index a4e5d5fc7..a4e5d5fc7 100644
--- a/StateTests/RandomTests/st201503181333GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181333GO.json
diff --git a/StateTests/RandomTests/st201503181334GO.json b/tests/files/StateTests/RandomTests/st201503181334GO.json
index 96cd596cd..96cd596cd 100644
--- a/StateTests/RandomTests/st201503181334GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181334GO.json
diff --git a/StateTests/RandomTests/st201503181336CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181336CPPJIT.json
index f378ea864..f378ea864 100644
--- a/StateTests/RandomTests/st201503181336CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181336CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181337GO.json b/tests/files/StateTests/RandomTests/st201503181337GO.json
index 3eaa145b7..3eaa145b7 100644
--- a/StateTests/RandomTests/st201503181337GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181337GO.json
diff --git a/StateTests/RandomTests/st201503181338GO.json b/tests/files/StateTests/RandomTests/st201503181338GO.json
index 737b657c5..737b657c5 100644
--- a/StateTests/RandomTests/st201503181338GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181338GO.json
diff --git a/StateTests/RandomTests/st201503181339CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181339CPPJIT.json
index 257307a9e..257307a9e 100644
--- a/StateTests/RandomTests/st201503181339CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181339CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181339GO.json b/tests/files/StateTests/RandomTests/st201503181339GO.json
index 3666ea34c..3666ea34c 100644
--- a/StateTests/RandomTests/st201503181339GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181339GO.json
diff --git a/StateTests/RandomTests/st201503181340GO.json b/tests/files/StateTests/RandomTests/st201503181340GO.json
index 04621e277..04621e277 100644
--- a/StateTests/RandomTests/st201503181340GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181340GO.json
diff --git a/StateTests/RandomTests/st201503181341CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181341CPPJIT.json
index 9eb1a456f..9eb1a456f 100644
--- a/StateTests/RandomTests/st201503181341CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181341CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181342CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181342CPPJIT.json
index 7b204e48e..7b204e48e 100644
--- a/StateTests/RandomTests/st201503181342CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181342CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181342GO.json b/tests/files/StateTests/RandomTests/st201503181342GO.json
index d7be98e5f..d7be98e5f 100644
--- a/StateTests/RandomTests/st201503181342GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181342GO.json
diff --git a/StateTests/RandomTests/st201503181345GO.json b/tests/files/StateTests/RandomTests/st201503181345GO.json
index ed560cfac..ed560cfac 100644
--- a/StateTests/RandomTests/st201503181345GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181345GO.json
diff --git a/StateTests/RandomTests/st201503181346GO.json b/tests/files/StateTests/RandomTests/st201503181346GO.json
index d0ba62022..d0ba62022 100644
--- a/StateTests/RandomTests/st201503181346GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181346GO.json
diff --git a/StateTests/RandomTests/st201503181347CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181347CPPJIT.json
index 3c67604cb..3c67604cb 100644
--- a/StateTests/RandomTests/st201503181347CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181347CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181347GO.json b/tests/files/StateTests/RandomTests/st201503181347GO.json
index b54f70dc3..b54f70dc3 100644
--- a/StateTests/RandomTests/st201503181347GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181347GO.json
diff --git a/StateTests/RandomTests/st201503181347PYTHON.json b/tests/files/StateTests/RandomTests/st201503181347PYTHON.json
index d4db9102b..d4db9102b 100644
--- a/StateTests/RandomTests/st201503181347PYTHON.json
+++ b/tests/files/StateTests/RandomTests/st201503181347PYTHON.json
diff --git a/StateTests/RandomTests/st201503181350CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181350CPPJIT.json
index a080101f7..a080101f7 100644
--- a/StateTests/RandomTests/st201503181350CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181350CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181352GO.json b/tests/files/StateTests/RandomTests/st201503181352GO.json
index 4fd8ef813..4fd8ef813 100644
--- a/StateTests/RandomTests/st201503181352GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181352GO.json
diff --git a/StateTests/RandomTests/st201503181353GO.json b/tests/files/StateTests/RandomTests/st201503181353GO.json
index bb71390c9..bb71390c9 100644
--- a/StateTests/RandomTests/st201503181353GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181353GO.json
diff --git a/StateTests/RandomTests/st201503181354CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181354CPPJIT.json
index 06ed9eec6..06ed9eec6 100644
--- a/StateTests/RandomTests/st201503181354CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181354CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181354GO.json b/tests/files/StateTests/RandomTests/st201503181354GO.json
index 3318562a8..3318562a8 100644
--- a/StateTests/RandomTests/st201503181354GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181354GO.json
diff --git a/StateTests/RandomTests/st201503181355GO.json b/tests/files/StateTests/RandomTests/st201503181355GO.json
index eb42a741d..eb42a741d 100644
--- a/StateTests/RandomTests/st201503181355GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181355GO.json
diff --git a/StateTests/RandomTests/st201503181356CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181356CPPJIT.json
index a9d4b2ec2..a9d4b2ec2 100644
--- a/StateTests/RandomTests/st201503181356CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181356CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181357CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181357CPPJIT.json
index 131bbeded..131bbeded 100644
--- a/StateTests/RandomTests/st201503181357CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181357CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181358CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181358CPPJIT.json
index 8f447e35f..8f447e35f 100644
--- a/StateTests/RandomTests/st201503181358CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181358CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181358GO.json b/tests/files/StateTests/RandomTests/st201503181358GO.json
index d97f656ef..d97f656ef 100644
--- a/StateTests/RandomTests/st201503181358GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181358GO.json
diff --git a/StateTests/RandomTests/st201503181359GO.json b/tests/files/StateTests/RandomTests/st201503181359GO.json
index 017f4b235..017f4b235 100644
--- a/StateTests/RandomTests/st201503181359GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181359GO.json
diff --git a/StateTests/RandomTests/st201503181402CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181402CPPJIT.json
index 62a44be7d..62a44be7d 100644
--- a/StateTests/RandomTests/st201503181402CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181402CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181403GO.json b/tests/files/StateTests/RandomTests/st201503181403GO.json
index e98cb4d04..e98cb4d04 100644
--- a/StateTests/RandomTests/st201503181403GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181403GO.json
diff --git a/StateTests/RandomTests/st201503181406CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181406CPPJIT.json
index 74ceed9d8..74ceed9d8 100644
--- a/StateTests/RandomTests/st201503181406CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181406CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181406GO.json b/tests/files/StateTests/RandomTests/st201503181406GO.json
index 7b9798fa5..7b9798fa5 100644
--- a/StateTests/RandomTests/st201503181406GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181406GO.json
diff --git a/StateTests/RandomTests/st201503181410GO.json b/tests/files/StateTests/RandomTests/st201503181410GO.json
index 72d52d301..72d52d301 100644
--- a/StateTests/RandomTests/st201503181410GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181410GO.json
diff --git a/StateTests/RandomTests/st201503181412CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181412CPPJIT.json
index 78cb7a58e..78cb7a58e 100644
--- a/StateTests/RandomTests/st201503181412CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181412CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181413GO.json b/tests/files/StateTests/RandomTests/st201503181413GO.json
index a82f513d9..a82f513d9 100644
--- a/StateTests/RandomTests/st201503181413GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181413GO.json
diff --git a/StateTests/RandomTests/st201503181415GO.json b/tests/files/StateTests/RandomTests/st201503181415GO.json
index a246e9c8c..a246e9c8c 100644
--- a/StateTests/RandomTests/st201503181415GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181415GO.json
diff --git a/StateTests/RandomTests/st201503181416GO.json b/tests/files/StateTests/RandomTests/st201503181416GO.json
index 2a34f5a6b..2a34f5a6b 100644
--- a/StateTests/RandomTests/st201503181416GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181416GO.json
diff --git a/StateTests/RandomTests/st201503181417CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181417CPPJIT.json
index edbfbe23f..edbfbe23f 100644
--- a/StateTests/RandomTests/st201503181417CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181417CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181417GO.json b/tests/files/StateTests/RandomTests/st201503181417GO.json
index d74f68087..d74f68087 100644
--- a/StateTests/RandomTests/st201503181417GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181417GO.json
diff --git a/StateTests/RandomTests/st201503181418CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181418CPPJIT.json
index 22628b3bd..22628b3bd 100644
--- a/StateTests/RandomTests/st201503181418CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181418CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181422GO.json b/tests/files/StateTests/RandomTests/st201503181422GO.json
index 1e5284d92..1e5284d92 100644
--- a/StateTests/RandomTests/st201503181422GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181422GO.json
diff --git a/StateTests/RandomTests/st201503181423CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181423CPPJIT.json
index cc04680ff..cc04680ff 100644
--- a/StateTests/RandomTests/st201503181423CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181423CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181424GO.json b/tests/files/StateTests/RandomTests/st201503181424GO.json
index f6bb7dc94..f6bb7dc94 100644
--- a/StateTests/RandomTests/st201503181424GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181424GO.json
diff --git a/StateTests/RandomTests/st201503181426CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181426CPPJIT.json
index 48a575198..48a575198 100644
--- a/StateTests/RandomTests/st201503181426CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181426CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181426GO.json b/tests/files/StateTests/RandomTests/st201503181426GO.json
index 13f17b2f6..13f17b2f6 100644
--- a/StateTests/RandomTests/st201503181426GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181426GO.json
diff --git a/StateTests/RandomTests/st201503181428GO.json b/tests/files/StateTests/RandomTests/st201503181428GO.json
index 6f5f71a76..6f5f71a76 100644
--- a/StateTests/RandomTests/st201503181428GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181428GO.json
diff --git a/StateTests/RandomTests/st201503181430CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181430CPPJIT.json
index 075350aab..075350aab 100644
--- a/StateTests/RandomTests/st201503181430CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181430CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181435GO.json b/tests/files/StateTests/RandomTests/st201503181435GO.json
index 15e094641..15e094641 100644
--- a/StateTests/RandomTests/st201503181435GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181435GO.json
diff --git a/StateTests/RandomTests/st201503181436GO.json b/tests/files/StateTests/RandomTests/st201503181436GO.json
index e36078336..e36078336 100644
--- a/StateTests/RandomTests/st201503181436GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181436GO.json
diff --git a/StateTests/RandomTests/st201503181437CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181437CPPJIT.json
index fd2863bfb..fd2863bfb 100644
--- a/StateTests/RandomTests/st201503181437CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181437CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181437GO.json b/tests/files/StateTests/RandomTests/st201503181437GO.json
index 47c7e3f59..47c7e3f59 100644
--- a/StateTests/RandomTests/st201503181437GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181437GO.json
diff --git a/StateTests/RandomTests/st201503181438CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181438CPPJIT.json
index 0ce121bfe..0ce121bfe 100644
--- a/StateTests/RandomTests/st201503181438CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181438CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181438GO.json b/tests/files/StateTests/RandomTests/st201503181438GO.json
index 63e0a59f0..63e0a59f0 100644
--- a/StateTests/RandomTests/st201503181438GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181438GO.json
diff --git a/StateTests/RandomTests/st201503181439CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181439CPPJIT.json
index af32d22c6..af32d22c6 100644
--- a/StateTests/RandomTests/st201503181439CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181439CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181439GO.json b/tests/files/StateTests/RandomTests/st201503181439GO.json
index e705706f2..e705706f2 100644
--- a/StateTests/RandomTests/st201503181439GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181439GO.json
diff --git a/StateTests/RandomTests/st201503181439PYTHON.json b/tests/files/StateTests/RandomTests/st201503181439PYTHON.json
index e705706f2..e705706f2 100644
--- a/StateTests/RandomTests/st201503181439PYTHON.json
+++ b/tests/files/StateTests/RandomTests/st201503181439PYTHON.json
diff --git a/StateTests/RandomTests/st201503181440GO.json b/tests/files/StateTests/RandomTests/st201503181440GO.json
index 73afdcfab..73afdcfab 100644
--- a/StateTests/RandomTests/st201503181440GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181440GO.json
diff --git a/StateTests/RandomTests/st201503181441GO.json b/tests/files/StateTests/RandomTests/st201503181441GO.json
index d8e9e12a9..d8e9e12a9 100644
--- a/StateTests/RandomTests/st201503181441GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181441GO.json
diff --git a/StateTests/RandomTests/st201503181442GO.json b/tests/files/StateTests/RandomTests/st201503181442GO.json
index bfed727d9..bfed727d9 100644
--- a/StateTests/RandomTests/st201503181442GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181442GO.json
diff --git a/StateTests/RandomTests/st201503181445CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181445CPPJIT.json
index 2ba2ea05c..2ba2ea05c 100644
--- a/StateTests/RandomTests/st201503181445CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181445CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181446GO.json b/tests/files/StateTests/RandomTests/st201503181446GO.json
index d8f017c69..d8f017c69 100644
--- a/StateTests/RandomTests/st201503181446GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181446GO.json
diff --git a/StateTests/RandomTests/st201503181447GO.json b/tests/files/StateTests/RandomTests/st201503181447GO.json
index d2fefa0b6..d2fefa0b6 100644
--- a/StateTests/RandomTests/st201503181447GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181447GO.json
diff --git a/StateTests/RandomTests/st201503181450GO.json b/tests/files/StateTests/RandomTests/st201503181450GO.json
index 510fc59c8..510fc59c8 100644
--- a/StateTests/RandomTests/st201503181450GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181450GO.json
diff --git a/StateTests/RandomTests/st201503181451CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181451CPPJIT.json
index db6e92588..db6e92588 100644
--- a/StateTests/RandomTests/st201503181451CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181451CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181453GO.json b/tests/files/StateTests/RandomTests/st201503181453GO.json
index de903f28b..de903f28b 100644
--- a/StateTests/RandomTests/st201503181453GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181453GO.json
diff --git a/StateTests/RandomTests/st201503181455GO.json b/tests/files/StateTests/RandomTests/st201503181455GO.json
index caeca004f..caeca004f 100644
--- a/StateTests/RandomTests/st201503181455GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181455GO.json
diff --git a/StateTests/RandomTests/st201503181456CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181456CPPJIT.json
index 67ae5f2fa..67ae5f2fa 100644
--- a/StateTests/RandomTests/st201503181456CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181456CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181457GO.json b/tests/files/StateTests/RandomTests/st201503181457GO.json
index 322c9792a..322c9792a 100644
--- a/StateTests/RandomTests/st201503181457GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181457GO.json
diff --git a/StateTests/RandomTests/st201503181458GO.json b/tests/files/StateTests/RandomTests/st201503181458GO.json
index aae996dd6..aae996dd6 100644
--- a/StateTests/RandomTests/st201503181458GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181458GO.json
diff --git a/StateTests/RandomTests/st201503181459GO.json b/tests/files/StateTests/RandomTests/st201503181459GO.json
index a67607627..a67607627 100644
--- a/StateTests/RandomTests/st201503181459GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181459GO.json
diff --git a/StateTests/RandomTests/st201503181500GO.json b/tests/files/StateTests/RandomTests/st201503181500GO.json
index b2b89dd79..b2b89dd79 100644
--- a/StateTests/RandomTests/st201503181500GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181500GO.json
diff --git a/StateTests/RandomTests/st201503181501GO.json b/tests/files/StateTests/RandomTests/st201503181501GO.json
index 39030d6e3..39030d6e3 100644
--- a/StateTests/RandomTests/st201503181501GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181501GO.json
diff --git a/StateTests/RandomTests/st201503181503GO.json b/tests/files/StateTests/RandomTests/st201503181503GO.json
index ffef4714b..ffef4714b 100644
--- a/StateTests/RandomTests/st201503181503GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181503GO.json
diff --git a/StateTests/RandomTests/st201503181504GO.json b/tests/files/StateTests/RandomTests/st201503181504GO.json
index 002d65cfb..002d65cfb 100644
--- a/StateTests/RandomTests/st201503181504GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181504GO.json
diff --git a/StateTests/RandomTests/st201503181505GO.json b/tests/files/StateTests/RandomTests/st201503181505GO.json
index f131bde24..f131bde24 100644
--- a/StateTests/RandomTests/st201503181505GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181505GO.json
diff --git a/StateTests/RandomTests/st201503181506CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181506CPPJIT.json
index 04d38295f..04d38295f 100644
--- a/StateTests/RandomTests/st201503181506CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181506CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181507GO.json b/tests/files/StateTests/RandomTests/st201503181507GO.json
index c17c3d2a6..c17c3d2a6 100644
--- a/StateTests/RandomTests/st201503181507GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181507GO.json
diff --git a/StateTests/RandomTests/st201503181509CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181509CPPJIT.json
index 70251794e..70251794e 100644
--- a/StateTests/RandomTests/st201503181509CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181509CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181509GO.json b/tests/files/StateTests/RandomTests/st201503181509GO.json
index 46abe10d2..46abe10d2 100644
--- a/StateTests/RandomTests/st201503181509GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181509GO.json
diff --git a/StateTests/RandomTests/st201503181510GO.json b/tests/files/StateTests/RandomTests/st201503181510GO.json
index ede879a10..ede879a10 100644
--- a/StateTests/RandomTests/st201503181510GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181510GO.json
diff --git a/StateTests/RandomTests/st201503181511GO.json b/tests/files/StateTests/RandomTests/st201503181511GO.json
index 24a4ddfb3..24a4ddfb3 100644
--- a/StateTests/RandomTests/st201503181511GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181511GO.json
diff --git a/StateTests/RandomTests/st201503181512GO.json b/tests/files/StateTests/RandomTests/st201503181512GO.json
index c14dc1682..c14dc1682 100644
--- a/StateTests/RandomTests/st201503181512GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181512GO.json
diff --git a/StateTests/RandomTests/st201503181513CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181513CPPJIT.json
index 7fbc88027..7fbc88027 100644
--- a/StateTests/RandomTests/st201503181513CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181513CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181513GO.json b/tests/files/StateTests/RandomTests/st201503181513GO.json
index a175b5dcd..a175b5dcd 100644
--- a/StateTests/RandomTests/st201503181513GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181513GO.json
diff --git a/StateTests/RandomTests/st201503181514CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181514CPPJIT.json
index 0a6308e9c..0a6308e9c 100644
--- a/StateTests/RandomTests/st201503181514CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181514CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181514GO.json b/tests/files/StateTests/RandomTests/st201503181514GO.json
index 5188e066b..5188e066b 100644
--- a/StateTests/RandomTests/st201503181514GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181514GO.json
diff --git a/StateTests/RandomTests/st201503181517CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181517CPPJIT.json
index 8d8cc5117..8d8cc5117 100644
--- a/StateTests/RandomTests/st201503181517CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181517CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181517GO.json b/tests/files/StateTests/RandomTests/st201503181517GO.json
index cec96c3ca..cec96c3ca 100644
--- a/StateTests/RandomTests/st201503181517GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181517GO.json
diff --git a/StateTests/RandomTests/st201503181519CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181519CPPJIT.json
index c9e33c7a5..c9e33c7a5 100644
--- a/StateTests/RandomTests/st201503181519CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181519CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181519GO.json b/tests/files/StateTests/RandomTests/st201503181519GO.json
index b961cc746..b961cc746 100644
--- a/StateTests/RandomTests/st201503181519GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181519GO.json
diff --git a/StateTests/RandomTests/st201503181520CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181520CPPJIT.json
index 7e4a40377..7e4a40377 100644
--- a/StateTests/RandomTests/st201503181520CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181520CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181520GO.json b/tests/files/StateTests/RandomTests/st201503181520GO.json
index 86f573fbc..86f573fbc 100644
--- a/StateTests/RandomTests/st201503181520GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181520GO.json
diff --git a/StateTests/RandomTests/st201503181521GO.json b/tests/files/StateTests/RandomTests/st201503181521GO.json
index 124acc156..124acc156 100644
--- a/StateTests/RandomTests/st201503181521GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181521GO.json
diff --git a/StateTests/RandomTests/st201503181522GO.json b/tests/files/StateTests/RandomTests/st201503181522GO.json
index 410cd35b2..410cd35b2 100644
--- a/StateTests/RandomTests/st201503181522GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181522GO.json
diff --git a/StateTests/RandomTests/st201503181524CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181524CPPJIT.json
index 12a97f9ae..12a97f9ae 100644
--- a/StateTests/RandomTests/st201503181524CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181524CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181524GO.json b/tests/files/StateTests/RandomTests/st201503181524GO.json
index f6ccea64c..f6ccea64c 100644
--- a/StateTests/RandomTests/st201503181524GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181524GO.json
diff --git a/StateTests/RandomTests/st201503181526GO.json b/tests/files/StateTests/RandomTests/st201503181526GO.json
index fdcab26fd..fdcab26fd 100644
--- a/StateTests/RandomTests/st201503181526GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181526GO.json
diff --git a/StateTests/RandomTests/st201503181527GO.json b/tests/files/StateTests/RandomTests/st201503181527GO.json
index 43ecbfc93..43ecbfc93 100644
--- a/StateTests/RandomTests/st201503181527GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181527GO.json
diff --git a/StateTests/RandomTests/st201503181528CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181528CPPJIT.json
index fc2a66802..fc2a66802 100644
--- a/StateTests/RandomTests/st201503181528CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181528CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181528GO.json b/tests/files/StateTests/RandomTests/st201503181528GO.json
index fc2a66802..fc2a66802 100644
--- a/StateTests/RandomTests/st201503181528GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181528GO.json
diff --git a/StateTests/RandomTests/st201503181528PYTHON.json b/tests/files/StateTests/RandomTests/st201503181528PYTHON.json
index fc2a66802..fc2a66802 100644
--- a/StateTests/RandomTests/st201503181528PYTHON.json
+++ b/tests/files/StateTests/RandomTests/st201503181528PYTHON.json
diff --git a/StateTests/RandomTests/st201503181529GO.json b/tests/files/StateTests/RandomTests/st201503181529GO.json
index b74f9ef45..b74f9ef45 100644
--- a/StateTests/RandomTests/st201503181529GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181529GO.json
diff --git a/StateTests/RandomTests/st201503181531CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181531CPPJIT.json
index df24ab9ab..df24ab9ab 100644
--- a/StateTests/RandomTests/st201503181531CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181531CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181533GO.json b/tests/files/StateTests/RandomTests/st201503181533GO.json
index c7a8b4b0e..c7a8b4b0e 100644
--- a/StateTests/RandomTests/st201503181533GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181533GO.json
diff --git a/StateTests/RandomTests/st201503181534CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181534CPPJIT.json
index f46d148cd..f46d148cd 100644
--- a/StateTests/RandomTests/st201503181534CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181534CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181534GO.json b/tests/files/StateTests/RandomTests/st201503181534GO.json
index 7d8cc9b70..7d8cc9b70 100644
--- a/StateTests/RandomTests/st201503181534GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181534GO.json
diff --git a/StateTests/RandomTests/st201503181536CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181536CPPJIT.json
index 48121f64c..48121f64c 100644
--- a/StateTests/RandomTests/st201503181536CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181536CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181536GO.json b/tests/files/StateTests/RandomTests/st201503181536GO.json
index 2005acfd2..2005acfd2 100644
--- a/StateTests/RandomTests/st201503181536GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181536GO.json
diff --git a/StateTests/RandomTests/st201503181537GO.json b/tests/files/StateTests/RandomTests/st201503181537GO.json
index d5452d98f..d5452d98f 100644
--- a/StateTests/RandomTests/st201503181537GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181537GO.json
diff --git a/StateTests/RandomTests/st201503181538GO.json b/tests/files/StateTests/RandomTests/st201503181538GO.json
index ecffc6630..ecffc6630 100644
--- a/StateTests/RandomTests/st201503181538GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181538GO.json
diff --git a/StateTests/RandomTests/st201503181539GO.json b/tests/files/StateTests/RandomTests/st201503181539GO.json
index bae5f01bf..bae5f01bf 100644
--- a/StateTests/RandomTests/st201503181539GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181539GO.json
diff --git a/StateTests/RandomTests/st201503181540CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181540CPPJIT.json
index a3d87e3cf..a3d87e3cf 100644
--- a/StateTests/RandomTests/st201503181540CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181540CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181540PYTHON.json b/tests/files/StateTests/RandomTests/st201503181540PYTHON.json
index a3d87e3cf..a3d87e3cf 100644
--- a/StateTests/RandomTests/st201503181540PYTHON.json
+++ b/tests/files/StateTests/RandomTests/st201503181540PYTHON.json
diff --git a/StateTests/RandomTests/st201503181543GO.json b/tests/files/StateTests/RandomTests/st201503181543GO.json
index 71418cb62..71418cb62 100644
--- a/StateTests/RandomTests/st201503181543GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181543GO.json
diff --git a/StateTests/RandomTests/st201503181544CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181544CPPJIT.json
index 615b970b9..615b970b9 100644
--- a/StateTests/RandomTests/st201503181544CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181544CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181544GO.json b/tests/files/StateTests/RandomTests/st201503181544GO.json
index 10683a4df..10683a4df 100644
--- a/StateTests/RandomTests/st201503181544GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181544GO.json
diff --git a/StateTests/RandomTests/st201503181547GO.json b/tests/files/StateTests/RandomTests/st201503181547GO.json
index 02e9dc776..02e9dc776 100644
--- a/StateTests/RandomTests/st201503181547GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181547GO.json
diff --git a/StateTests/RandomTests/st201503181548CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181548CPPJIT.json
index 5adeb5d75..5adeb5d75 100644
--- a/StateTests/RandomTests/st201503181548CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181548CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181548GO.json b/tests/files/StateTests/RandomTests/st201503181548GO.json
index fb5cb3cbd..fb5cb3cbd 100644
--- a/StateTests/RandomTests/st201503181548GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181548GO.json
diff --git a/StateTests/RandomTests/st201503181551GO.json b/tests/files/StateTests/RandomTests/st201503181551GO.json
index e7015a553..e7015a553 100644
--- a/StateTests/RandomTests/st201503181551GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181551GO.json
diff --git a/StateTests/RandomTests/st201503181552CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181552CPPJIT.json
index 74136240b..74136240b 100644
--- a/StateTests/RandomTests/st201503181552CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181552CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181553GO.json b/tests/files/StateTests/RandomTests/st201503181553GO.json
index a4b5ba048..a4b5ba048 100644
--- a/StateTests/RandomTests/st201503181553GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181553GO.json
diff --git a/StateTests/RandomTests/st201503181555CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181555CPPJIT.json
index d23357b14..d23357b14 100644
--- a/StateTests/RandomTests/st201503181555CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181555CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181555GO.json b/tests/files/StateTests/RandomTests/st201503181555GO.json
index 9003609d9..9003609d9 100644
--- a/StateTests/RandomTests/st201503181555GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181555GO.json
diff --git a/StateTests/RandomTests/st201503181557GO.json b/tests/files/StateTests/RandomTests/st201503181557GO.json
index 87690e602..87690e602 100644
--- a/StateTests/RandomTests/st201503181557GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181557GO.json
diff --git a/StateTests/RandomTests/st201503181559GO.json b/tests/files/StateTests/RandomTests/st201503181559GO.json
index 417cce81e..417cce81e 100644
--- a/StateTests/RandomTests/st201503181559GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181559GO.json
diff --git a/StateTests/RandomTests/st201503181601CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181601CPPJIT.json
index 59dc7217a..59dc7217a 100644
--- a/StateTests/RandomTests/st201503181601CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181601CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181601GO.json b/tests/files/StateTests/RandomTests/st201503181601GO.json
index ca505b6b6..ca505b6b6 100644
--- a/StateTests/RandomTests/st201503181601GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181601GO.json
diff --git a/StateTests/RandomTests/st201503181602GO.json b/tests/files/StateTests/RandomTests/st201503181602GO.json
index 35c0b91c6..35c0b91c6 100644
--- a/StateTests/RandomTests/st201503181602GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181602GO.json
diff --git a/StateTests/RandomTests/st201503181603GO.json b/tests/files/StateTests/RandomTests/st201503181603GO.json
index 9dddbaacf..9dddbaacf 100644
--- a/StateTests/RandomTests/st201503181603GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181603GO.json
diff --git a/StateTests/RandomTests/st201503181604GO.json b/tests/files/StateTests/RandomTests/st201503181604GO.json
index f705acf35..f705acf35 100644
--- a/StateTests/RandomTests/st201503181604GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181604GO.json
diff --git a/StateTests/RandomTests/st201503181605GO.json b/tests/files/StateTests/RandomTests/st201503181605GO.json
index 5de2923c8..5de2923c8 100644
--- a/StateTests/RandomTests/st201503181605GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181605GO.json
diff --git a/StateTests/RandomTests/st201503181606GO.json b/tests/files/StateTests/RandomTests/st201503181606GO.json
index a8a1d1cec..a8a1d1cec 100644
--- a/StateTests/RandomTests/st201503181606GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181606GO.json
diff --git a/StateTests/RandomTests/st201503181607GO.json b/tests/files/StateTests/RandomTests/st201503181607GO.json
index ec72b787f..ec72b787f 100644
--- a/StateTests/RandomTests/st201503181607GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181607GO.json
diff --git a/StateTests/RandomTests/st201503181608CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181608CPPJIT.json
index 23ee287bb..23ee287bb 100644
--- a/StateTests/RandomTests/st201503181608CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181608CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181608GO.json b/tests/files/StateTests/RandomTests/st201503181608GO.json
index fb5f74913..fb5f74913 100644
--- a/StateTests/RandomTests/st201503181608GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181608GO.json
diff --git a/StateTests/RandomTests/st201503181609GO.json b/tests/files/StateTests/RandomTests/st201503181609GO.json
index 600a10d3f..600a10d3f 100644
--- a/StateTests/RandomTests/st201503181609GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181609GO.json
diff --git a/StateTests/RandomTests/st201503181610CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181610CPPJIT.json
index 0a1e6c7c9..0a1e6c7c9 100644
--- a/StateTests/RandomTests/st201503181610CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181610CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181610GO.json b/tests/files/StateTests/RandomTests/st201503181610GO.json
index 82839d826..82839d826 100644
--- a/StateTests/RandomTests/st201503181610GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181610GO.json
diff --git a/StateTests/RandomTests/st201503181611CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181611CPPJIT.json
index 4fbe99e80..4fbe99e80 100644
--- a/StateTests/RandomTests/st201503181611CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181611CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181611GO.json b/tests/files/StateTests/RandomTests/st201503181611GO.json
index 8c0c62bd2..8c0c62bd2 100644
--- a/StateTests/RandomTests/st201503181611GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181611GO.json
diff --git a/StateTests/RandomTests/st201503181612GO.json b/tests/files/StateTests/RandomTests/st201503181612GO.json
index c6fc26729..c6fc26729 100644
--- a/StateTests/RandomTests/st201503181612GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181612GO.json
diff --git a/StateTests/RandomTests/st201503181614CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181614CPPJIT.json
index 055eaa2d4..055eaa2d4 100644
--- a/StateTests/RandomTests/st201503181614CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181614CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181614GO.json b/tests/files/StateTests/RandomTests/st201503181614GO.json
index 3604fc0b7..3604fc0b7 100644
--- a/StateTests/RandomTests/st201503181614GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181614GO.json
diff --git a/StateTests/RandomTests/st201503181616CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181616CPPJIT.json
index ca37e6267..ca37e6267 100644
--- a/StateTests/RandomTests/st201503181616CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181616CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181616GO.json b/tests/files/StateTests/RandomTests/st201503181616GO.json
index 00ffe12ce..00ffe12ce 100644
--- a/StateTests/RandomTests/st201503181616GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181616GO.json
diff --git a/StateTests/RandomTests/st201503181617GO.json b/tests/files/StateTests/RandomTests/st201503181617GO.json
index fb9ad0436..fb9ad0436 100644
--- a/StateTests/RandomTests/st201503181617GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181617GO.json
diff --git a/StateTests/RandomTests/st201503181618GO.json b/tests/files/StateTests/RandomTests/st201503181618GO.json
index 1a4d63c86..1a4d63c86 100644
--- a/StateTests/RandomTests/st201503181618GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181618GO.json
diff --git a/StateTests/RandomTests/st201503181619GO.json b/tests/files/StateTests/RandomTests/st201503181619GO.json
index 2060ba588..2060ba588 100644
--- a/StateTests/RandomTests/st201503181619GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181619GO.json
diff --git a/StateTests/RandomTests/st201503181620CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181620CPPJIT.json
index 586ac5ff5..586ac5ff5 100644
--- a/StateTests/RandomTests/st201503181620CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181620CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181620GO.json b/tests/files/StateTests/RandomTests/st201503181620GO.json
index b83f65efe..b83f65efe 100644
--- a/StateTests/RandomTests/st201503181620GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181620GO.json
diff --git a/StateTests/RandomTests/st201503181621GO.json b/tests/files/StateTests/RandomTests/st201503181621GO.json
index ff0723f70..ff0723f70 100644
--- a/StateTests/RandomTests/st201503181621GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181621GO.json
diff --git a/StateTests/RandomTests/st201503181625GO.json b/tests/files/StateTests/RandomTests/st201503181625GO.json
index cc76a1d4b..cc76a1d4b 100644
--- a/StateTests/RandomTests/st201503181625GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181625GO.json
diff --git a/StateTests/RandomTests/st201503181626CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181626CPPJIT.json
index 15111187f..15111187f 100644
--- a/StateTests/RandomTests/st201503181626CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181626CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181626GO.json b/tests/files/StateTests/RandomTests/st201503181626GO.json
index 90ebb2643..90ebb2643 100644
--- a/StateTests/RandomTests/st201503181626GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181626GO.json
diff --git a/StateTests/RandomTests/st201503181627GO.json b/tests/files/StateTests/RandomTests/st201503181627GO.json
index aef319d78..aef319d78 100644
--- a/StateTests/RandomTests/st201503181627GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181627GO.json
diff --git a/StateTests/RandomTests/st201503181628GO.json b/tests/files/StateTests/RandomTests/st201503181628GO.json
index 883ea003c..883ea003c 100644
--- a/StateTests/RandomTests/st201503181628GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181628GO.json
diff --git a/StateTests/RandomTests/st201503181629GO.json b/tests/files/StateTests/RandomTests/st201503181629GO.json
index e9a788e47..e9a788e47 100644
--- a/StateTests/RandomTests/st201503181629GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181629GO.json
diff --git a/StateTests/RandomTests/st201503181630CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181630CPPJIT.json
index 4282b9ecd..4282b9ecd 100644
--- a/StateTests/RandomTests/st201503181630CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181630CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181630GO.json b/tests/files/StateTests/RandomTests/st201503181630GO.json
index c0f885e1b..c0f885e1b 100644
--- a/StateTests/RandomTests/st201503181630GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181630GO.json
diff --git a/StateTests/RandomTests/st201503181630PYTHON.json b/tests/files/StateTests/RandomTests/st201503181630PYTHON.json
index 4282b9ecd..4282b9ecd 100644
--- a/StateTests/RandomTests/st201503181630PYTHON.json
+++ b/tests/files/StateTests/RandomTests/st201503181630PYTHON.json
diff --git a/StateTests/RandomTests/st201503181632GO.json b/tests/files/StateTests/RandomTests/st201503181632GO.json
index d9ed5a76f..d9ed5a76f 100644
--- a/StateTests/RandomTests/st201503181632GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181632GO.json
diff --git a/StateTests/RandomTests/st201503181634CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181634CPPJIT.json
index ce6ae8205..ce6ae8205 100644
--- a/StateTests/RandomTests/st201503181634CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181634CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181635GO.json b/tests/files/StateTests/RandomTests/st201503181635GO.json
index 683955716..683955716 100644
--- a/StateTests/RandomTests/st201503181635GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181635GO.json
diff --git a/StateTests/RandomTests/st201503181636GO.json b/tests/files/StateTests/RandomTests/st201503181636GO.json
index b72bc2825..b72bc2825 100644
--- a/StateTests/RandomTests/st201503181636GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181636GO.json
diff --git a/StateTests/RandomTests/st201503181638GO.json b/tests/files/StateTests/RandomTests/st201503181638GO.json
index d64026675..d64026675 100644
--- a/StateTests/RandomTests/st201503181638GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181638GO.json
diff --git a/StateTests/RandomTests/st201503181639CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181639CPPJIT.json
index 82cafb85a..82cafb85a 100644
--- a/StateTests/RandomTests/st201503181639CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181639CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181641GO.json b/tests/files/StateTests/RandomTests/st201503181641GO.json
index ecb939853..ecb939853 100644
--- a/StateTests/RandomTests/st201503181641GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181641GO.json
diff --git a/StateTests/RandomTests/st201503181645GO.json b/tests/files/StateTests/RandomTests/st201503181645GO.json
index c69b57b9c..c69b57b9c 100644
--- a/StateTests/RandomTests/st201503181645GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181645GO.json
diff --git a/StateTests/RandomTests/st201503181646GO.json b/tests/files/StateTests/RandomTests/st201503181646GO.json
index 7525d5355..7525d5355 100644
--- a/StateTests/RandomTests/st201503181646GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181646GO.json
diff --git a/StateTests/RandomTests/st201503181647CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181647CPPJIT.json
index cb9b27fbf..cb9b27fbf 100644
--- a/StateTests/RandomTests/st201503181647CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181647CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181649CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181649CPPJIT.json
index b32588bdc..b32588bdc 100644
--- a/StateTests/RandomTests/st201503181649CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181649CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181650GO.json b/tests/files/StateTests/RandomTests/st201503181650GO.json
index 32271df19..32271df19 100644
--- a/StateTests/RandomTests/st201503181650GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181650GO.json
diff --git a/StateTests/RandomTests/st201503181652CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181652CPPJIT.json
index e0ea04838..e0ea04838 100644
--- a/StateTests/RandomTests/st201503181652CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181652CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181653GO.json b/tests/files/StateTests/RandomTests/st201503181653GO.json
index 77e937099..77e937099 100644
--- a/StateTests/RandomTests/st201503181653GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181653GO.json
diff --git a/StateTests/RandomTests/st201503181654GO.json b/tests/files/StateTests/RandomTests/st201503181654GO.json
index 2e77ed50b..2e77ed50b 100644
--- a/StateTests/RandomTests/st201503181654GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181654GO.json
diff --git a/StateTests/RandomTests/st201503181655CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181655CPPJIT.json
index 10e3a1a79..10e3a1a79 100644
--- a/StateTests/RandomTests/st201503181655CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181655CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181655GO.json b/tests/files/StateTests/RandomTests/st201503181655GO.json
index e495131cf..e495131cf 100644
--- a/StateTests/RandomTests/st201503181655GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181655GO.json
diff --git a/StateTests/RandomTests/st201503181656CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181656CPPJIT.json
index e5fd790c9..e5fd790c9 100644
--- a/StateTests/RandomTests/st201503181656CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181656CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181656GO.json b/tests/files/StateTests/RandomTests/st201503181656GO.json
index 249b77e50..249b77e50 100644
--- a/StateTests/RandomTests/st201503181656GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181656GO.json
diff --git a/StateTests/RandomTests/st201503181657GO.json b/tests/files/StateTests/RandomTests/st201503181657GO.json
index b94fe2e9d..b94fe2e9d 100644
--- a/StateTests/RandomTests/st201503181657GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181657GO.json
diff --git a/StateTests/RandomTests/st201503181658GO.json b/tests/files/StateTests/RandomTests/st201503181658GO.json
index e0890cc7f..e0890cc7f 100644
--- a/StateTests/RandomTests/st201503181658GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181658GO.json
diff --git a/StateTests/RandomTests/st201503181700GO.json b/tests/files/StateTests/RandomTests/st201503181700GO.json
index f032abd1e..f032abd1e 100644
--- a/StateTests/RandomTests/st201503181700GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181700GO.json
diff --git a/StateTests/RandomTests/st201503181702GO.json b/tests/files/StateTests/RandomTests/st201503181702GO.json
index 403ee1d07..403ee1d07 100644
--- a/StateTests/RandomTests/st201503181702GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181702GO.json
diff --git a/StateTests/RandomTests/st201503181703CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181703CPPJIT.json
index ba8222df8..ba8222df8 100644
--- a/StateTests/RandomTests/st201503181703CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181703CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181703GO.json b/tests/files/StateTests/RandomTests/st201503181703GO.json
index 625f96e70..625f96e70 100644
--- a/StateTests/RandomTests/st201503181703GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181703GO.json
diff --git a/StateTests/RandomTests/st201503181704GO.json b/tests/files/StateTests/RandomTests/st201503181704GO.json
index 940c8fa21..940c8fa21 100644
--- a/StateTests/RandomTests/st201503181704GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181704GO.json
diff --git a/StateTests/RandomTests/st201503181706GO.json b/tests/files/StateTests/RandomTests/st201503181706GO.json
index f4f07f4d8..f4f07f4d8 100644
--- a/StateTests/RandomTests/st201503181706GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181706GO.json
diff --git a/StateTests/RandomTests/st201503181709GO.json b/tests/files/StateTests/RandomTests/st201503181709GO.json
index 73afd5300..73afd5300 100644
--- a/StateTests/RandomTests/st201503181709GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181709GO.json
diff --git a/StateTests/RandomTests/st201503181711CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181711CPPJIT.json
index 346cdc9fe..346cdc9fe 100644
--- a/StateTests/RandomTests/st201503181711CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181711CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181711GO.json b/tests/files/StateTests/RandomTests/st201503181711GO.json
index eca15906f..eca15906f 100644
--- a/StateTests/RandomTests/st201503181711GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181711GO.json
diff --git a/StateTests/RandomTests/st201503181713CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181713CPPJIT.json
index fc2d60952..fc2d60952 100644
--- a/StateTests/RandomTests/st201503181713CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181713CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181713GO.json b/tests/files/StateTests/RandomTests/st201503181713GO.json
index bcf74ec09..bcf74ec09 100644
--- a/StateTests/RandomTests/st201503181713GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181713GO.json
diff --git a/StateTests/RandomTests/st201503181714GO.json b/tests/files/StateTests/RandomTests/st201503181714GO.json
index 01689b2a7..01689b2a7 100644
--- a/StateTests/RandomTests/st201503181714GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181714GO.json
diff --git a/StateTests/RandomTests/st201503181715CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181715CPPJIT.json
index 78403a0fb..78403a0fb 100644
--- a/StateTests/RandomTests/st201503181715CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181715CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181715GO.json b/tests/files/StateTests/RandomTests/st201503181715GO.json
index 4d9cb3517..4d9cb3517 100644
--- a/StateTests/RandomTests/st201503181715GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181715GO.json
diff --git a/StateTests/RandomTests/st201503181716GO.json b/tests/files/StateTests/RandomTests/st201503181716GO.json
index 14eeff6d0..14eeff6d0 100644
--- a/StateTests/RandomTests/st201503181716GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181716GO.json
diff --git a/StateTests/RandomTests/st201503181717GO.json b/tests/files/StateTests/RandomTests/st201503181717GO.json
index ecfd1a954..ecfd1a954 100644
--- a/StateTests/RandomTests/st201503181717GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181717GO.json
diff --git a/StateTests/RandomTests/st201503181720CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181720CPPJIT.json
index b43b00639..b43b00639 100644
--- a/StateTests/RandomTests/st201503181720CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181720CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181722GO.json b/tests/files/StateTests/RandomTests/st201503181722GO.json
index ad5febb46..ad5febb46 100644
--- a/StateTests/RandomTests/st201503181722GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181722GO.json
diff --git a/StateTests/RandomTests/st201503181723CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181723CPPJIT.json
index 9f654d5d0..9f654d5d0 100644
--- a/StateTests/RandomTests/st201503181723CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181723CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181723GO.json b/tests/files/StateTests/RandomTests/st201503181723GO.json
index e85694e23..e85694e23 100644
--- a/StateTests/RandomTests/st201503181723GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181723GO.json
diff --git a/StateTests/RandomTests/st201503181724CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181724CPPJIT.json
index 2ea9e5bee..2ea9e5bee 100644
--- a/StateTests/RandomTests/st201503181724CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181724CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181724GO.json b/tests/files/StateTests/RandomTests/st201503181724GO.json
index 5c5decbd6..5c5decbd6 100644
--- a/StateTests/RandomTests/st201503181724GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181724GO.json
diff --git a/StateTests/RandomTests/st201503181725GO.json b/tests/files/StateTests/RandomTests/st201503181725GO.json
index c819dc299..c819dc299 100644
--- a/StateTests/RandomTests/st201503181725GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181725GO.json
diff --git a/StateTests/RandomTests/st201503181728GO.json b/tests/files/StateTests/RandomTests/st201503181728GO.json
index bd20fc7ed..bd20fc7ed 100644
--- a/StateTests/RandomTests/st201503181728GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181728GO.json
diff --git a/StateTests/RandomTests/st201503181729GO.json b/tests/files/StateTests/RandomTests/st201503181729GO.json
index 66b27af28..66b27af28 100644
--- a/StateTests/RandomTests/st201503181729GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181729GO.json
diff --git a/StateTests/RandomTests/st201503181730GO.json b/tests/files/StateTests/RandomTests/st201503181730GO.json
index d8cfe600a..d8cfe600a 100644
--- a/StateTests/RandomTests/st201503181730GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181730GO.json
diff --git a/StateTests/RandomTests/st201503181731CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181731CPPJIT.json
index 72b0b93f0..72b0b93f0 100644
--- a/StateTests/RandomTests/st201503181731CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181731CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181732GO.json b/tests/files/StateTests/RandomTests/st201503181732GO.json
index 30777467e..30777467e 100644
--- a/StateTests/RandomTests/st201503181732GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181732GO.json
diff --git a/StateTests/RandomTests/st201503181734CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181734CPPJIT.json
index 464c79285..464c79285 100644
--- a/StateTests/RandomTests/st201503181734CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181734CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181734GO.json b/tests/files/StateTests/RandomTests/st201503181734GO.json
index 0dd1cdeff..0dd1cdeff 100644
--- a/StateTests/RandomTests/st201503181734GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181734GO.json
diff --git a/StateTests/RandomTests/st201503181735GO.json b/tests/files/StateTests/RandomTests/st201503181735GO.json
index a7073a655..a7073a655 100644
--- a/StateTests/RandomTests/st201503181735GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181735GO.json
diff --git a/StateTests/RandomTests/st201503181737CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181737CPPJIT.json
index b8c3ce0d7..b8c3ce0d7 100644
--- a/StateTests/RandomTests/st201503181737CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181737CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181737GO.json b/tests/files/StateTests/RandomTests/st201503181737GO.json
index b77e52010..b77e52010 100644
--- a/StateTests/RandomTests/st201503181737GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181737GO.json
diff --git a/StateTests/RandomTests/st201503181738CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181738CPPJIT.json
index 088f62c23..088f62c23 100644
--- a/StateTests/RandomTests/st201503181738CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181738CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181738GO.json b/tests/files/StateTests/RandomTests/st201503181738GO.json
index 151877283..151877283 100644
--- a/StateTests/RandomTests/st201503181738GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181738GO.json
diff --git a/StateTests/RandomTests/st201503181739GO.json b/tests/files/StateTests/RandomTests/st201503181739GO.json
index e045d32cb..e045d32cb 100644
--- a/StateTests/RandomTests/st201503181739GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181739GO.json
diff --git a/StateTests/RandomTests/st201503181740CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181740CPPJIT.json
index ceb19f488..ceb19f488 100644
--- a/StateTests/RandomTests/st201503181740CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181740CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181740GO.json b/tests/files/StateTests/RandomTests/st201503181740GO.json
index 27db73da3..27db73da3 100644
--- a/StateTests/RandomTests/st201503181740GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181740GO.json
diff --git a/StateTests/RandomTests/st201503181742CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181742CPPJIT.json
index 4d57b12ea..4d57b12ea 100644
--- a/StateTests/RandomTests/st201503181742CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181742CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181743GO.json b/tests/files/StateTests/RandomTests/st201503181743GO.json
index 7545688ac..7545688ac 100644
--- a/StateTests/RandomTests/st201503181743GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181743GO.json
diff --git a/StateTests/RandomTests/st201503181744GO.json b/tests/files/StateTests/RandomTests/st201503181744GO.json
index 1ab010191..1ab010191 100644
--- a/StateTests/RandomTests/st201503181744GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181744GO.json
diff --git a/StateTests/RandomTests/st201503181745CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181745CPPJIT.json
index cdad1d881..cdad1d881 100644
--- a/StateTests/RandomTests/st201503181745CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181745CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181746GO.json b/tests/files/StateTests/RandomTests/st201503181746GO.json
index 6e3753dda..6e3753dda 100644
--- a/StateTests/RandomTests/st201503181746GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181746GO.json
diff --git a/StateTests/RandomTests/st201503181747GO.json b/tests/files/StateTests/RandomTests/st201503181747GO.json
index d32c79abb..d32c79abb 100644
--- a/StateTests/RandomTests/st201503181747GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181747GO.json
diff --git a/StateTests/RandomTests/st201503181748GO.json b/tests/files/StateTests/RandomTests/st201503181748GO.json
index ec9cbaff3..ec9cbaff3 100644
--- a/StateTests/RandomTests/st201503181748GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181748GO.json
diff --git a/StateTests/RandomTests/st201503181749GO.json b/tests/files/StateTests/RandomTests/st201503181749GO.json
index 86ff13659..86ff13659 100644
--- a/StateTests/RandomTests/st201503181749GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181749GO.json
diff --git a/StateTests/RandomTests/st201503181750CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181750CPPJIT.json
index 562f68c05..562f68c05 100644
--- a/StateTests/RandomTests/st201503181750CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181750CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181750GO.json b/tests/files/StateTests/RandomTests/st201503181750GO.json
index 567d5a611..567d5a611 100644
--- a/StateTests/RandomTests/st201503181750GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181750GO.json
diff --git a/StateTests/RandomTests/st201503181752GO.json b/tests/files/StateTests/RandomTests/st201503181752GO.json
index 23216cce2..23216cce2 100644
--- a/StateTests/RandomTests/st201503181752GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181752GO.json
diff --git a/StateTests/RandomTests/st201503181753CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181753CPPJIT.json
index 022168734..022168734 100644
--- a/StateTests/RandomTests/st201503181753CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181753CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181754CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181754CPPJIT.json
index a4bbeb096..a4bbeb096 100644
--- a/StateTests/RandomTests/st201503181754CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181754CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181754GO.json b/tests/files/StateTests/RandomTests/st201503181754GO.json
index b07ea8281..b07ea8281 100644
--- a/StateTests/RandomTests/st201503181754GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181754GO.json
diff --git a/StateTests/RandomTests/st201503181755CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181755CPPJIT.json
index ff9b8a5b3..ff9b8a5b3 100644
--- a/StateTests/RandomTests/st201503181755CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181755CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181755GO.json b/tests/files/StateTests/RandomTests/st201503181755GO.json
index 2385c2b13..2385c2b13 100644
--- a/StateTests/RandomTests/st201503181755GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181755GO.json
diff --git a/StateTests/RandomTests/st201503181756GO.json b/tests/files/StateTests/RandomTests/st201503181756GO.json
index ae3733446..ae3733446 100644
--- a/StateTests/RandomTests/st201503181756GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181756GO.json
diff --git a/StateTests/RandomTests/st201503181757CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181757CPPJIT.json
index 5f28b119d..5f28b119d 100644
--- a/StateTests/RandomTests/st201503181757CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181757CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181757GO.json b/tests/files/StateTests/RandomTests/st201503181757GO.json
index 2f9f20cc0..2f9f20cc0 100644
--- a/StateTests/RandomTests/st201503181757GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181757GO.json
diff --git a/StateTests/RandomTests/st201503181759GO.json b/tests/files/StateTests/RandomTests/st201503181759GO.json
index c2f3e268f..c2f3e268f 100644
--- a/StateTests/RandomTests/st201503181759GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181759GO.json
diff --git a/StateTests/RandomTests/st201503181800GO.json b/tests/files/StateTests/RandomTests/st201503181800GO.json
index 873a6689e..873a6689e 100644
--- a/StateTests/RandomTests/st201503181800GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181800GO.json
diff --git a/StateTests/RandomTests/st201503181801GO.json b/tests/files/StateTests/RandomTests/st201503181801GO.json
index 299636ac5..299636ac5 100644
--- a/StateTests/RandomTests/st201503181801GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181801GO.json
diff --git a/StateTests/RandomTests/st201503181802GO.json b/tests/files/StateTests/RandomTests/st201503181802GO.json
index 22672b6ce..22672b6ce 100644
--- a/StateTests/RandomTests/st201503181802GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181802GO.json
diff --git a/StateTests/RandomTests/st201503181803CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181803CPPJIT.json
index 14a4646fd..14a4646fd 100644
--- a/StateTests/RandomTests/st201503181803CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181803CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181803GO.json b/tests/files/StateTests/RandomTests/st201503181803GO.json
index a46bdfb3a..a46bdfb3a 100644
--- a/StateTests/RandomTests/st201503181803GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181803GO.json
diff --git a/StateTests/RandomTests/st201503181804GO.json b/tests/files/StateTests/RandomTests/st201503181804GO.json
index dc54505df..dc54505df 100644
--- a/StateTests/RandomTests/st201503181804GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181804GO.json
diff --git a/StateTests/RandomTests/st201503181806GO.json b/tests/files/StateTests/RandomTests/st201503181806GO.json
index 7b1cddb2b..7b1cddb2b 100644
--- a/StateTests/RandomTests/st201503181806GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181806GO.json
diff --git a/StateTests/RandomTests/st201503181808GO.json b/tests/files/StateTests/RandomTests/st201503181808GO.json
index 97fe0cb47..97fe0cb47 100644
--- a/StateTests/RandomTests/st201503181808GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181808GO.json
diff --git a/StateTests/RandomTests/st201503181809CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181809CPPJIT.json
index 33ddc785b..33ddc785b 100644
--- a/StateTests/RandomTests/st201503181809CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181809CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181812CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181812CPPJIT.json
index fb674d2e8..fb674d2e8 100644
--- a/StateTests/RandomTests/st201503181812CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181812CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181812GO.json b/tests/files/StateTests/RandomTests/st201503181812GO.json
index f038ace2b..f038ace2b 100644
--- a/StateTests/RandomTests/st201503181812GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181812GO.json
diff --git a/StateTests/RandomTests/st201503181814CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181814CPPJIT.json
index 61f27f0af..61f27f0af 100644
--- a/StateTests/RandomTests/st201503181814CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181814CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181815GO.json b/tests/files/StateTests/RandomTests/st201503181815GO.json
index 6b70b123d..6b70b123d 100644
--- a/StateTests/RandomTests/st201503181815GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181815GO.json
diff --git a/StateTests/RandomTests/st201503181816CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181816CPPJIT.json
index 2fcce88dc..2fcce88dc 100644
--- a/StateTests/RandomTests/st201503181816CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181816CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181817CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181817CPPJIT.json
index b4d409791..b4d409791 100644
--- a/StateTests/RandomTests/st201503181817CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181817CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181819GO.json b/tests/files/StateTests/RandomTests/st201503181819GO.json
index 37b94908e..37b94908e 100644
--- a/StateTests/RandomTests/st201503181819GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181819GO.json
diff --git a/StateTests/RandomTests/st201503181821GO.json b/tests/files/StateTests/RandomTests/st201503181821GO.json
index c00d36901..c00d36901 100644
--- a/StateTests/RandomTests/st201503181821GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181821GO.json
diff --git a/StateTests/RandomTests/st201503181822GO.json b/tests/files/StateTests/RandomTests/st201503181822GO.json
index ae682ae3e..ae682ae3e 100644
--- a/StateTests/RandomTests/st201503181822GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181822GO.json
diff --git a/StateTests/RandomTests/st201503181823GO.json b/tests/files/StateTests/RandomTests/st201503181823GO.json
index f2bd2b426..f2bd2b426 100644
--- a/StateTests/RandomTests/st201503181823GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181823GO.json
diff --git a/StateTests/RandomTests/st201503181824GO.json b/tests/files/StateTests/RandomTests/st201503181824GO.json
index a9674cef1..a9674cef1 100644
--- a/StateTests/RandomTests/st201503181824GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181824GO.json
diff --git a/StateTests/RandomTests/st201503181825GO.json b/tests/files/StateTests/RandomTests/st201503181825GO.json
index 5b9130bde..5b9130bde 100644
--- a/StateTests/RandomTests/st201503181825GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181825GO.json
diff --git a/StateTests/RandomTests/st201503181829GO.json b/tests/files/StateTests/RandomTests/st201503181829GO.json
index def54871f..def54871f 100644
--- a/StateTests/RandomTests/st201503181829GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181829GO.json
diff --git a/StateTests/RandomTests/st201503181830CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181830CPPJIT.json
index 242c568eb..242c568eb 100644
--- a/StateTests/RandomTests/st201503181830CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181830CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181833GO.json b/tests/files/StateTests/RandomTests/st201503181833GO.json
index 184fb0ba3..184fb0ba3 100644
--- a/StateTests/RandomTests/st201503181833GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181833GO.json
diff --git a/StateTests/RandomTests/st201503181834CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181834CPPJIT.json
index fc7d8734b..fc7d8734b 100644
--- a/StateTests/RandomTests/st201503181834CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181834CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181834GO.json b/tests/files/StateTests/RandomTests/st201503181834GO.json
index e952236c2..e952236c2 100644
--- a/StateTests/RandomTests/st201503181834GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181834GO.json
diff --git a/StateTests/RandomTests/st201503181837GO.json b/tests/files/StateTests/RandomTests/st201503181837GO.json
index 5f55dc144..5f55dc144 100644
--- a/StateTests/RandomTests/st201503181837GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181837GO.json
diff --git a/StateTests/RandomTests/st201503181840GO.json b/tests/files/StateTests/RandomTests/st201503181840GO.json
index efd088b9b..efd088b9b 100644
--- a/StateTests/RandomTests/st201503181840GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181840GO.json
diff --git a/StateTests/RandomTests/st201503181842GO.json b/tests/files/StateTests/RandomTests/st201503181842GO.json
index f3b3a1b8e..f3b3a1b8e 100644
--- a/StateTests/RandomTests/st201503181842GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181842GO.json
diff --git a/StateTests/RandomTests/st201503181843GO.json b/tests/files/StateTests/RandomTests/st201503181843GO.json
index 88f0335ea..88f0335ea 100644
--- a/StateTests/RandomTests/st201503181843GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181843GO.json
diff --git a/StateTests/RandomTests/st201503181844GO.json b/tests/files/StateTests/RandomTests/st201503181844GO.json
index e55271897..e55271897 100644
--- a/StateTests/RandomTests/st201503181844GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181844GO.json
diff --git a/StateTests/RandomTests/st201503181845GO.json b/tests/files/StateTests/RandomTests/st201503181845GO.json
index 5c7c20fa4..5c7c20fa4 100644
--- a/StateTests/RandomTests/st201503181845GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181845GO.json
diff --git a/StateTests/RandomTests/st201503181846GO.json b/tests/files/StateTests/RandomTests/st201503181846GO.json
index 8fea3c33d..8fea3c33d 100644
--- a/StateTests/RandomTests/st201503181846GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181846GO.json
diff --git a/StateTests/RandomTests/st201503181847GO.json b/tests/files/StateTests/RandomTests/st201503181847GO.json
index c9a11b103..c9a11b103 100644
--- a/StateTests/RandomTests/st201503181847GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181847GO.json
diff --git a/StateTests/RandomTests/st201503181848GO.json b/tests/files/StateTests/RandomTests/st201503181848GO.json
index 4ac0c2728..4ac0c2728 100644
--- a/StateTests/RandomTests/st201503181848GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181848GO.json
diff --git a/StateTests/RandomTests/st201503181849GO.json b/tests/files/StateTests/RandomTests/st201503181849GO.json
index 1abc9cd65..1abc9cd65 100644
--- a/StateTests/RandomTests/st201503181849GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181849GO.json
diff --git a/StateTests/RandomTests/st201503181850GO.json b/tests/files/StateTests/RandomTests/st201503181850GO.json
index da3f36922..da3f36922 100644
--- a/StateTests/RandomTests/st201503181850GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181850GO.json
diff --git a/StateTests/RandomTests/st201503181851CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181851CPPJIT.json
index 318e40b68..318e40b68 100644
--- a/StateTests/RandomTests/st201503181851CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181851CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181851GO.json b/tests/files/StateTests/RandomTests/st201503181851GO.json
index 0fedf96e5..0fedf96e5 100644
--- a/StateTests/RandomTests/st201503181851GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181851GO.json
diff --git a/StateTests/RandomTests/st201503181852CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181852CPPJIT.json
index 6d5b3145d..6d5b3145d 100644
--- a/StateTests/RandomTests/st201503181852CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181852CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181854GO.json b/tests/files/StateTests/RandomTests/st201503181854GO.json
index 18104d3a6..18104d3a6 100644
--- a/StateTests/RandomTests/st201503181854GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181854GO.json
diff --git a/StateTests/RandomTests/st201503181855CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181855CPPJIT.json
index 925522de9..925522de9 100644
--- a/StateTests/RandomTests/st201503181855CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181855CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181857PYTHON.json b/tests/files/StateTests/RandomTests/st201503181857PYTHON.json
index bc433b1ad..bc433b1ad 100644
--- a/StateTests/RandomTests/st201503181857PYTHON.json
+++ b/tests/files/StateTests/RandomTests/st201503181857PYTHON.json
diff --git a/StateTests/RandomTests/st201503181859GO.json b/tests/files/StateTests/RandomTests/st201503181859GO.json
index 32dbf3a62..32dbf3a62 100644
--- a/StateTests/RandomTests/st201503181859GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181859GO.json
diff --git a/StateTests/RandomTests/st201503181900GO.json b/tests/files/StateTests/RandomTests/st201503181900GO.json
index 4fa97e5b9..4fa97e5b9 100644
--- a/StateTests/RandomTests/st201503181900GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181900GO.json
diff --git a/StateTests/RandomTests/st201503181903GO.json b/tests/files/StateTests/RandomTests/st201503181903GO.json
index a81b3c3ac..a81b3c3ac 100644
--- a/StateTests/RandomTests/st201503181903GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181903GO.json
diff --git a/StateTests/RandomTests/st201503181904GO.json b/tests/files/StateTests/RandomTests/st201503181904GO.json
index e47f5b22f..e47f5b22f 100644
--- a/StateTests/RandomTests/st201503181904GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181904GO.json
diff --git a/StateTests/RandomTests/st201503181906GO.json b/tests/files/StateTests/RandomTests/st201503181906GO.json
index 2cc52e42e..2cc52e42e 100644
--- a/StateTests/RandomTests/st201503181906GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181906GO.json
diff --git a/StateTests/RandomTests/st201503181907GO.json b/tests/files/StateTests/RandomTests/st201503181907GO.json
index ee8a402f3..ee8a402f3 100644
--- a/StateTests/RandomTests/st201503181907GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181907GO.json
diff --git a/StateTests/RandomTests/st201503181910GO.json b/tests/files/StateTests/RandomTests/st201503181910GO.json
index 49312ddf0..49312ddf0 100644
--- a/StateTests/RandomTests/st201503181910GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181910GO.json
diff --git a/StateTests/RandomTests/st201503181915GO.json b/tests/files/StateTests/RandomTests/st201503181915GO.json
index f09c3e4ba..f09c3e4ba 100644
--- a/StateTests/RandomTests/st201503181915GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181915GO.json
diff --git a/StateTests/RandomTests/st201503181919CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181919CPPJIT.json
index a6d4fd50a..a6d4fd50a 100644
--- a/StateTests/RandomTests/st201503181919CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181919CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181919PYTHON.json b/tests/files/StateTests/RandomTests/st201503181919PYTHON.json
index a6d4fd50a..a6d4fd50a 100644
--- a/StateTests/RandomTests/st201503181919PYTHON.json
+++ b/tests/files/StateTests/RandomTests/st201503181919PYTHON.json
diff --git a/StateTests/RandomTests/st201503181920GO.json b/tests/files/StateTests/RandomTests/st201503181920GO.json
index 0ba584e34..0ba584e34 100644
--- a/StateTests/RandomTests/st201503181920GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181920GO.json
diff --git a/StateTests/RandomTests/st201503181922GO.json b/tests/files/StateTests/RandomTests/st201503181922GO.json
index d364e0f65..d364e0f65 100644
--- a/StateTests/RandomTests/st201503181922GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181922GO.json
diff --git a/StateTests/RandomTests/st201503181926GO.json b/tests/files/StateTests/RandomTests/st201503181926GO.json
index f1145fc8f..f1145fc8f 100644
--- a/StateTests/RandomTests/st201503181926GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181926GO.json
diff --git a/StateTests/RandomTests/st201503181929GO.json b/tests/files/StateTests/RandomTests/st201503181929GO.json
index a040e1b5f..a040e1b5f 100644
--- a/StateTests/RandomTests/st201503181929GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181929GO.json
diff --git a/StateTests/RandomTests/st201503181931CPPJIT.json b/tests/files/StateTests/RandomTests/st201503181931CPPJIT.json
index 6a0e5b0e8..6a0e5b0e8 100644
--- a/StateTests/RandomTests/st201503181931CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201503181931CPPJIT.json
diff --git a/StateTests/RandomTests/st201503181931GO.json b/tests/files/StateTests/RandomTests/st201503181931GO.json
index 56f2b9428..56f2b9428 100644
--- a/StateTests/RandomTests/st201503181931GO.json
+++ b/tests/files/StateTests/RandomTests/st201503181931GO.json
diff --git a/StateTests/RandomTests/st201503181931PYTHON.json b/tests/files/StateTests/RandomTests/st201503181931PYTHON.json
index 6a0e5b0e8..6a0e5b0e8 100644
--- a/StateTests/RandomTests/st201503181931PYTHON.json
+++ b/tests/files/StateTests/RandomTests/st201503181931PYTHON.json
diff --git a/StateTests/RandomTests/st201503191646GO.json b/tests/files/StateTests/RandomTests/st201503191646GO.json
index e5389a786..e5389a786 100644
--- a/StateTests/RandomTests/st201503191646GO.json
+++ b/tests/files/StateTests/RandomTests/st201503191646GO.json
diff --git a/StateTests/RandomTests/st201503200837JS.json b/tests/files/StateTests/RandomTests/st201503200837JS.json
index ec8ede075..ec8ede075 100644
--- a/StateTests/RandomTests/st201503200837JS.json
+++ b/tests/files/StateTests/RandomTests/st201503200837JS.json
diff --git a/StateTests/RandomTests/st201503200838JS.json b/tests/files/StateTests/RandomTests/st201503200838JS.json
index 5bfc4f877..5bfc4f877 100644
--- a/StateTests/RandomTests/st201503200838JS.json
+++ b/tests/files/StateTests/RandomTests/st201503200838JS.json
diff --git a/StateTests/RandomTests/st201503200841JS.json b/tests/files/StateTests/RandomTests/st201503200841JS.json
index a3b8d085c..a3b8d085c 100644
--- a/StateTests/RandomTests/st201503200841JS.json
+++ b/tests/files/StateTests/RandomTests/st201503200841JS.json
diff --git a/StateTests/RandomTests/st201503200848JS.json b/tests/files/StateTests/RandomTests/st201503200848JS.json
index 17718059e..17718059e 100644
--- a/StateTests/RandomTests/st201503200848JS.json
+++ b/tests/files/StateTests/RandomTests/st201503200848JS.json
diff --git a/StateTests/RandomTests/st201503240609JS.json b/tests/files/StateTests/RandomTests/st201503240609JS.json
index d452f0cd4..d452f0cd4 100644
--- a/StateTests/RandomTests/st201503240609JS.json
+++ b/tests/files/StateTests/RandomTests/st201503240609JS.json
diff --git a/StateTests/RandomTests/st201503302200JS.json b/tests/files/StateTests/RandomTests/st201503302200JS.json
index 04cda0cad..04cda0cad 100644
--- a/StateTests/RandomTests/st201503302200JS.json
+++ b/tests/files/StateTests/RandomTests/st201503302200JS.json
diff --git a/StateTests/RandomTests/st201503302202JS.json b/tests/files/StateTests/RandomTests/st201503302202JS.json
index 2bd3d6b88..2bd3d6b88 100644
--- a/StateTests/RandomTests/st201503302202JS.json
+++ b/tests/files/StateTests/RandomTests/st201503302202JS.json
diff --git a/StateTests/RandomTests/st201503302206JS.json b/tests/files/StateTests/RandomTests/st201503302206JS.json
index 86f9b42c9..86f9b42c9 100644
--- a/StateTests/RandomTests/st201503302206JS.json
+++ b/tests/files/StateTests/RandomTests/st201503302206JS.json
diff --git a/StateTests/RandomTests/st201503302208JS.json b/tests/files/StateTests/RandomTests/st201503302208JS.json
index 9c49f721a..9c49f721a 100644
--- a/StateTests/RandomTests/st201503302208JS.json
+++ b/tests/files/StateTests/RandomTests/st201503302208JS.json
diff --git a/StateTests/RandomTests/st201503302210JS.json b/tests/files/StateTests/RandomTests/st201503302210JS.json
index 42d53b12b..42d53b12b 100644
--- a/StateTests/RandomTests/st201503302210JS.json
+++ b/tests/files/StateTests/RandomTests/st201503302210JS.json
diff --git a/StateTests/RandomTests/st201503302211JS.json b/tests/files/StateTests/RandomTests/st201503302211JS.json
index 9bf18da15..9bf18da15 100644
--- a/StateTests/RandomTests/st201503302211JS.json
+++ b/tests/files/StateTests/RandomTests/st201503302211JS.json
diff --git a/StateTests/RandomTests/st201504011535GO.json b/tests/files/StateTests/RandomTests/st201504011535GO.json
index 449ca0407..449ca0407 100644
--- a/StateTests/RandomTests/st201504011535GO.json
+++ b/tests/files/StateTests/RandomTests/st201504011535GO.json
diff --git a/StateTests/RandomTests/st201504011536GO.json b/tests/files/StateTests/RandomTests/st201504011536GO.json
index 53b487063..53b487063 100644
--- a/StateTests/RandomTests/st201504011536GO.json
+++ b/tests/files/StateTests/RandomTests/st201504011536GO.json
diff --git a/StateTests/RandomTests/st201504011547GO.json b/tests/files/StateTests/RandomTests/st201504011547GO.json
index 9e94ee717..9e94ee717 100644
--- a/StateTests/RandomTests/st201504011547GO.json
+++ b/tests/files/StateTests/RandomTests/st201504011547GO.json
diff --git a/StateTests/RandomTests/st201504011916JS.json b/tests/files/StateTests/RandomTests/st201504011916JS.json
index 0acfd0570..0acfd0570 100644
--- a/StateTests/RandomTests/st201504011916JS.json
+++ b/tests/files/StateTests/RandomTests/st201504011916JS.json
diff --git a/StateTests/RandomTests/st201504012130JS.json b/tests/files/StateTests/RandomTests/st201504012130JS.json
index 08a248afe..08a248afe 100644
--- a/StateTests/RandomTests/st201504012130JS.json
+++ b/tests/files/StateTests/RandomTests/st201504012130JS.json
diff --git a/StateTests/RandomTests/st201504012259JS.json b/tests/files/StateTests/RandomTests/st201504012259JS.json
index 85db6d213..85db6d213 100644
--- a/StateTests/RandomTests/st201504012259JS.json
+++ b/tests/files/StateTests/RandomTests/st201504012259JS.json
diff --git a/StateTests/RandomTests/st201504012359JS.json b/tests/files/StateTests/RandomTests/st201504012359JS.json
index 94901a7ce..94901a7ce 100644
--- a/StateTests/RandomTests/st201504012359JS.json
+++ b/tests/files/StateTests/RandomTests/st201504012359JS.json
diff --git a/StateTests/RandomTests/st201504020305JS.json b/tests/files/StateTests/RandomTests/st201504020305JS.json
index d89752854..d89752854 100644
--- a/StateTests/RandomTests/st201504020305JS.json
+++ b/tests/files/StateTests/RandomTests/st201504020305JS.json
diff --git a/StateTests/RandomTests/st201504020400JS.json b/tests/files/StateTests/RandomTests/st201504020400JS.json
index d04173ebc..d04173ebc 100644
--- a/StateTests/RandomTests/st201504020400JS.json
+++ b/tests/files/StateTests/RandomTests/st201504020400JS.json
diff --git a/StateTests/RandomTests/st201504020428JS.json b/tests/files/StateTests/RandomTests/st201504020428JS.json
index 630e65563..630e65563 100644
--- a/StateTests/RandomTests/st201504020428JS.json
+++ b/tests/files/StateTests/RandomTests/st201504020428JS.json
diff --git a/StateTests/RandomTests/st201504020431JS.json b/tests/files/StateTests/RandomTests/st201504020431JS.json
index 59c06c169..59c06c169 100644
--- a/StateTests/RandomTests/st201504020431JS.json
+++ b/tests/files/StateTests/RandomTests/st201504020431JS.json
diff --git a/StateTests/RandomTests/st201504020444JS.json b/tests/files/StateTests/RandomTests/st201504020444JS.json
index 3b68c5282..3b68c5282 100644
--- a/StateTests/RandomTests/st201504020444JS.json
+++ b/tests/files/StateTests/RandomTests/st201504020444JS.json
diff --git a/StateTests/RandomTests/st201504020538JS.json b/tests/files/StateTests/RandomTests/st201504020538JS.json
index 15c6c4bb3..15c6c4bb3 100644
--- a/StateTests/RandomTests/st201504020538JS.json
+++ b/tests/files/StateTests/RandomTests/st201504020538JS.json
diff --git a/StateTests/RandomTests/st201504020639JS.json b/tests/files/StateTests/RandomTests/st201504020639JS.json
index 42c0aad4c..42c0aad4c 100644
--- a/StateTests/RandomTests/st201504020639JS.json
+++ b/tests/files/StateTests/RandomTests/st201504020639JS.json
diff --git a/StateTests/RandomTests/st201504020836JS.json b/tests/files/StateTests/RandomTests/st201504020836JS.json
index a606c05bb..a606c05bb 100644
--- a/StateTests/RandomTests/st201504020836JS.json
+++ b/tests/files/StateTests/RandomTests/st201504020836JS.json
diff --git a/StateTests/RandomTests/st201504020910JS.json b/tests/files/StateTests/RandomTests/st201504020910JS.json
index 5e48178e6..5e48178e6 100644
--- a/StateTests/RandomTests/st201504020910JS.json
+++ b/tests/files/StateTests/RandomTests/st201504020910JS.json
diff --git a/StateTests/RandomTests/st201504021057JS.json b/tests/files/StateTests/RandomTests/st201504021057JS.json
index ef95cd583..ef95cd583 100644
--- a/StateTests/RandomTests/st201504021057JS.json
+++ b/tests/files/StateTests/RandomTests/st201504021057JS.json
diff --git a/StateTests/RandomTests/st201504021104JS.json b/tests/files/StateTests/RandomTests/st201504021104JS.json
index a85329136..a85329136 100644
--- a/StateTests/RandomTests/st201504021104JS.json
+++ b/tests/files/StateTests/RandomTests/st201504021104JS.json
diff --git a/StateTests/RandomTests/st201504021237CPPJIT.json b/tests/files/StateTests/RandomTests/st201504021237CPPJIT.json
index 5d8d56827..5d8d56827 100644
--- a/StateTests/RandomTests/st201504021237CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201504021237CPPJIT.json
diff --git a/StateTests/RandomTests/st201504021237GO.json b/tests/files/StateTests/RandomTests/st201504021237GO.json
index 5d8d56827..5d8d56827 100644
--- a/StateTests/RandomTests/st201504021237GO.json
+++ b/tests/files/StateTests/RandomTests/st201504021237GO.json
diff --git a/StateTests/RandomTests/st201504021237JS.json b/tests/files/StateTests/RandomTests/st201504021237JS.json
index 5d8d56827..5d8d56827 100644
--- a/StateTests/RandomTests/st201504021237JS.json
+++ b/tests/files/StateTests/RandomTests/st201504021237JS.json
diff --git a/StateTests/RandomTests/st201504021237PYTHON.json b/tests/files/StateTests/RandomTests/st201504021237PYTHON.json
index 5d8d56827..5d8d56827 100644
--- a/StateTests/RandomTests/st201504021237PYTHON.json
+++ b/tests/files/StateTests/RandomTests/st201504021237PYTHON.json
diff --git a/StateTests/RandomTests/st201504021949JS.json b/tests/files/StateTests/RandomTests/st201504021949JS.json
index 7b853f8d2..7b853f8d2 100644
--- a/StateTests/RandomTests/st201504021949JS.json
+++ b/tests/files/StateTests/RandomTests/st201504021949JS.json
diff --git a/StateTests/RandomTests/st201504022003CPPJIT.json b/tests/files/StateTests/RandomTests/st201504022003CPPJIT.json
index 48d8ed883..48d8ed883 100644
--- a/StateTests/RandomTests/st201504022003CPPJIT.json
+++ b/tests/files/StateTests/RandomTests/st201504022003CPPJIT.json
diff --git a/StateTests/RandomTests/st201504022124JS.json b/tests/files/StateTests/RandomTests/st201504022124JS.json
index 73e34b6df..73e34b6df 100644
--- a/StateTests/RandomTests/st201504022124JS.json
+++ b/tests/files/StateTests/RandomTests/st201504022124JS.json
diff --git a/StateTests/RandomTests/st201504030138JS.json b/tests/files/StateTests/RandomTests/st201504030138JS.json
index d3134ec63..d3134ec63 100644
--- a/StateTests/RandomTests/st201504030138JS.json
+++ b/tests/files/StateTests/RandomTests/st201504030138JS.json
diff --git a/StateTests/RandomTests/st201504030646JS.json b/tests/files/StateTests/RandomTests/st201504030646JS.json
index e97c1bdd5..e97c1bdd5 100644
--- a/StateTests/RandomTests/st201504030646JS.json
+++ b/tests/files/StateTests/RandomTests/st201504030646JS.json
diff --git a/StateTests/RandomTests/st201504030709JS.json b/tests/files/StateTests/RandomTests/st201504030709JS.json
index 17f16d7e3..17f16d7e3 100644
--- a/StateTests/RandomTests/st201504030709JS.json
+++ b/tests/files/StateTests/RandomTests/st201504030709JS.json
diff --git a/StateTests/stBlockHashTest.json b/tests/files/StateTests/stBlockHashTest.json
index c18d9f422..c18d9f422 100644
--- a/StateTests/stBlockHashTest.json
+++ b/tests/files/StateTests/stBlockHashTest.json
diff --git a/StateTests/stCallCreateCallCodeTest.json b/tests/files/StateTests/stCallCreateCallCodeTest.json
index 04f9cc434..04f9cc434 100644
--- a/StateTests/stCallCreateCallCodeTest.json
+++ b/tests/files/StateTests/stCallCreateCallCodeTest.json
diff --git a/StateTests/stExample.json b/tests/files/StateTests/stExample.json
index 40a5b2c17..40a5b2c17 100644
--- a/StateTests/stExample.json
+++ b/tests/files/StateTests/stExample.json
diff --git a/StateTests/stInitCodeTest.json b/tests/files/StateTests/stInitCodeTest.json
index cf904c1b7..cf904c1b7 100644
--- a/StateTests/stInitCodeTest.json
+++ b/tests/files/StateTests/stInitCodeTest.json
diff --git a/StateTests/stLogTests.json b/tests/files/StateTests/stLogTests.json
index c964fb659..c964fb659 100644
--- a/StateTests/stLogTests.json
+++ b/tests/files/StateTests/stLogTests.json
diff --git a/StateTests/stMemoryStressTest.json b/tests/files/StateTests/stMemoryStressTest.json
index 203caae51..203caae51 100644
--- a/StateTests/stMemoryStressTest.json
+++ b/tests/files/StateTests/stMemoryStressTest.json
diff --git a/StateTests/stMemoryTest.json b/tests/files/StateTests/stMemoryTest.json
index 884dc650d..884dc650d 100644
--- a/StateTests/stMemoryTest.json
+++ b/tests/files/StateTests/stMemoryTest.json
diff --git a/StateTests/stPreCompiledContracts.json b/tests/files/StateTests/stPreCompiledContracts.json
index 055611f7d..055611f7d 100644
--- a/StateTests/stPreCompiledContracts.json
+++ b/tests/files/StateTests/stPreCompiledContracts.json
diff --git a/StateTests/stQuadraticComplexityTest.json b/tests/files/StateTests/stQuadraticComplexityTest.json
index 87bcdcb8b..87bcdcb8b 100644
--- a/StateTests/stQuadraticComplexityTest.json
+++ b/tests/files/StateTests/stQuadraticComplexityTest.json
diff --git a/StateTests/stRecursiveCreate.json b/tests/files/StateTests/stRecursiveCreate.json
index 6ea9efac5..6ea9efac5 100644
--- a/StateTests/stRecursiveCreate.json
+++ b/tests/files/StateTests/stRecursiveCreate.json
diff --git a/StateTests/stRefundTest.json b/tests/files/StateTests/stRefundTest.json
index 4d19605fe..4d19605fe 100644
--- a/StateTests/stRefundTest.json
+++ b/tests/files/StateTests/stRefundTest.json
diff --git a/StateTests/stSolidityTest.json b/tests/files/StateTests/stSolidityTest.json
index f32425c4a..f32425c4a 100644
--- a/StateTests/stSolidityTest.json
+++ b/tests/files/StateTests/stSolidityTest.json
diff --git a/StateTests/stSpecialTest.json b/tests/files/StateTests/stSpecialTest.json
index c8a3921f2..c8a3921f2 100644
--- a/StateTests/stSpecialTest.json
+++ b/tests/files/StateTests/stSpecialTest.json
diff --git a/StateTests/stSystemOperationsTest.json b/tests/files/StateTests/stSystemOperationsTest.json
index 06ca31eef..06ca31eef 100644
--- a/StateTests/stSystemOperationsTest.json
+++ b/tests/files/StateTests/stSystemOperationsTest.json
diff --git a/StateTests/stTransactionTest.json b/tests/files/StateTests/stTransactionTest.json
index 826f90d47..826f90d47 100644
--- a/StateTests/stTransactionTest.json
+++ b/tests/files/StateTests/stTransactionTest.json
diff --git a/TODO b/tests/files/TODO
index 91d0f358b..91d0f358b 100644
--- a/TODO
+++ b/tests/files/TODO
diff --git a/TransactionTests/tt10mbDataField.json b/tests/files/TransactionTests/tt10mbDataField.json
index cf000cd6f..cf000cd6f 100644
--- a/TransactionTests/tt10mbDataField.json
+++ b/tests/files/TransactionTests/tt10mbDataField.json
diff --git a/TransactionTests/ttTransactionTest.json b/tests/files/TransactionTests/ttTransactionTest.json
index ae47d7a8f..ae47d7a8f 100644
--- a/TransactionTests/ttTransactionTest.json
+++ b/tests/files/TransactionTests/ttTransactionTest.json
diff --git a/TransactionTests/ttWrongRLPTransaction.json b/tests/files/TransactionTests/ttWrongRLPTransaction.json
index 743770b70..743770b70 100644
--- a/TransactionTests/ttWrongRLPTransaction.json
+++ b/tests/files/TransactionTests/ttWrongRLPTransaction.json
diff --git a/TrieTests/hex_encoded_securetrie_test.json b/tests/files/TrieTests/hex_encoded_securetrie_test.json
index 473f96419..473f96419 100644
--- a/TrieTests/hex_encoded_securetrie_test.json
+++ b/tests/files/TrieTests/hex_encoded_securetrie_test.json
diff --git a/TrieTests/trieanyorder.json b/tests/files/TrieTests/trieanyorder.json
index 58fcc4f34..58fcc4f34 100644
--- a/TrieTests/trieanyorder.json
+++ b/tests/files/TrieTests/trieanyorder.json
diff --git a/TrieTests/trieanyorder_secureTrie.json b/tests/files/TrieTests/trieanyorder_secureTrie.json
index a1d9a6961..a1d9a6961 100644
--- a/TrieTests/trieanyorder_secureTrie.json
+++ b/tests/files/TrieTests/trieanyorder_secureTrie.json
diff --git a/TrieTests/trietest.json b/tests/files/TrieTests/trietest.json
index d871a8a81..d871a8a81 100644
--- a/TrieTests/trietest.json
+++ b/tests/files/TrieTests/trietest.json
diff --git a/TrieTests/trietest_secureTrie.json b/tests/files/TrieTests/trietest_secureTrie.json
index ac4ecd2dd..ac4ecd2dd 100644
--- a/TrieTests/trietest_secureTrie.json
+++ b/tests/files/TrieTests/trietest_secureTrie.json
diff --git a/TrieTests/trietestnextprev.json b/tests/files/TrieTests/trietestnextprev.json
index f2ad924e3..f2ad924e3 100644
--- a/TrieTests/trietestnextprev.json
+++ b/tests/files/TrieTests/trietestnextprev.json
diff --git a/VMTests/RandomTests/201503102037PYTHON.json b/tests/files/VMTests/RandomTests/201503102037PYTHON.json
index 38d840482..38d840482 100644
--- a/VMTests/RandomTests/201503102037PYTHON.json
+++ b/tests/files/VMTests/RandomTests/201503102037PYTHON.json
diff --git a/VMTests/RandomTests/201503102148PYTHON.json b/tests/files/VMTests/RandomTests/201503102148PYTHON.json
index f39145f98..f39145f98 100644
--- a/VMTests/RandomTests/201503102148PYTHON.json
+++ b/tests/files/VMTests/RandomTests/201503102148PYTHON.json
diff --git a/VMTests/RandomTests/201503102300PYTHON.json b/tests/files/VMTests/RandomTests/201503102300PYTHON.json
index 34684d0fa..34684d0fa 100644
--- a/VMTests/RandomTests/201503102300PYTHON.json
+++ b/tests/files/VMTests/RandomTests/201503102300PYTHON.json
diff --git a/VMTests/RandomTests/201503102320PYTHON.json b/tests/files/VMTests/RandomTests/201503102320PYTHON.json
index 39635ad83..39635ad83 100644
--- a/VMTests/RandomTests/201503102320PYTHON.json
+++ b/tests/files/VMTests/RandomTests/201503102320PYTHON.json
diff --git a/VMTests/RandomTests/201503110050PYTHON.json b/tests/files/VMTests/RandomTests/201503110050PYTHON.json
index a147d42c4..a147d42c4 100644
--- a/VMTests/RandomTests/201503110050PYTHON.json
+++ b/tests/files/VMTests/RandomTests/201503110050PYTHON.json
diff --git a/VMTests/RandomTests/201503110206PYTHON.json b/tests/files/VMTests/RandomTests/201503110206PYTHON.json
index 02a73c2b9..02a73c2b9 100644
--- a/VMTests/RandomTests/201503110206PYTHON.json
+++ b/tests/files/VMTests/RandomTests/201503110206PYTHON.json
diff --git a/VMTests/RandomTests/201503110219PYTHON.json b/tests/files/VMTests/RandomTests/201503110219PYTHON.json
index 20a52afe6..20a52afe6 100644
--- a/VMTests/RandomTests/201503110219PYTHON.json
+++ b/tests/files/VMTests/RandomTests/201503110219PYTHON.json
diff --git a/VMTests/RandomTests/201503110226PYTHON_DUP6.json b/tests/files/VMTests/RandomTests/201503110226PYTHON_DUP6.json
index 4348a9672..4348a9672 100644
--- a/VMTests/RandomTests/201503110226PYTHON_DUP6.json
+++ b/tests/files/VMTests/RandomTests/201503110226PYTHON_DUP6.json
diff --git a/VMTests/RandomTests/201503110346PYTHON_PUSH24.json b/tests/files/VMTests/RandomTests/201503110346PYTHON_PUSH24.json
index 23dbca54e..23dbca54e 100644
--- a/VMTests/RandomTests/201503110346PYTHON_PUSH24.json
+++ b/tests/files/VMTests/RandomTests/201503110346PYTHON_PUSH24.json
diff --git a/VMTests/RandomTests/201503110526PYTHON.json b/tests/files/VMTests/RandomTests/201503110526PYTHON.json
index 2e93808da..2e93808da 100644
--- a/VMTests/RandomTests/201503110526PYTHON.json
+++ b/tests/files/VMTests/RandomTests/201503110526PYTHON.json
diff --git a/VMTests/RandomTests/201503111844PYTHON.json b/tests/files/VMTests/RandomTests/201503111844PYTHON.json
index a90ca56e4..a90ca56e4 100644
--- a/VMTests/RandomTests/201503111844PYTHON.json
+++ b/tests/files/VMTests/RandomTests/201503111844PYTHON.json
diff --git a/VMTests/RandomTests/201503112218PYTHON.json b/tests/files/VMTests/RandomTests/201503112218PYTHON.json
index fdc43998e..fdc43998e 100644
--- a/VMTests/RandomTests/201503112218PYTHON.json
+++ b/tests/files/VMTests/RandomTests/201503112218PYTHON.json
diff --git a/VMTests/RandomTests/201503120317PYTHON.json b/tests/files/VMTests/RandomTests/201503120317PYTHON.json
index 7c0338da6..7c0338da6 100644
--- a/VMTests/RandomTests/201503120317PYTHON.json
+++ b/tests/files/VMTests/RandomTests/201503120317PYTHON.json
diff --git a/VMTests/RandomTests/201503120525PYTHON.json b/tests/files/VMTests/RandomTests/201503120525PYTHON.json
index 1d827a175..1d827a175 100644
--- a/VMTests/RandomTests/201503120525PYTHON.json
+++ b/tests/files/VMTests/RandomTests/201503120525PYTHON.json
diff --git a/VMTests/RandomTests/201503120547PYTHON.json b/tests/files/VMTests/RandomTests/201503120547PYTHON.json
index d3dcdbe04..d3dcdbe04 100644
--- a/VMTests/RandomTests/201503120547PYTHON.json
+++ b/tests/files/VMTests/RandomTests/201503120547PYTHON.json
diff --git a/VMTests/RandomTests/201503120909PYTHON.json b/tests/files/VMTests/RandomTests/201503120909PYTHON.json
index 29d575dcf..29d575dcf 100644
--- a/VMTests/RandomTests/201503120909PYTHON.json
+++ b/tests/files/VMTests/RandomTests/201503120909PYTHON.json
diff --git a/VMTests/RandomTests/randomTest.json b/tests/files/VMTests/RandomTests/randomTest.json
index 56c4f62c7..56c4f62c7 100644
--- a/VMTests/RandomTests/randomTest.json
+++ b/tests/files/VMTests/RandomTests/randomTest.json
diff --git a/VMTests/vmArithmeticTest.json b/tests/files/VMTests/vmArithmeticTest.json
index d463f0cdb..d463f0cdb 100644
--- a/VMTests/vmArithmeticTest.json
+++ b/tests/files/VMTests/vmArithmeticTest.json
diff --git a/VMTests/vmBitwiseLogicOperationTest.json b/tests/files/VMTests/vmBitwiseLogicOperationTest.json
index b53568d01..b53568d01 100644
--- a/VMTests/vmBitwiseLogicOperationTest.json
+++ b/tests/files/VMTests/vmBitwiseLogicOperationTest.json
diff --git a/VMTests/vmBlockInfoTest.json b/tests/files/VMTests/vmBlockInfoTest.json
index e8b81dc98..e8b81dc98 100644
--- a/VMTests/vmBlockInfoTest.json
+++ b/tests/files/VMTests/vmBlockInfoTest.json
diff --git a/VMTests/vmEnvironmentalInfoTest.json b/tests/files/VMTests/vmEnvironmentalInfoTest.json
index 7139e68bb..7139e68bb 100644
--- a/VMTests/vmEnvironmentalInfoTest.json
+++ b/tests/files/VMTests/vmEnvironmentalInfoTest.json
diff --git a/VMTests/vmIOandFlowOperationsTest.json b/tests/files/VMTests/vmIOandFlowOperationsTest.json
index 6a2e0f640..6a2e0f640 100644
--- a/VMTests/vmIOandFlowOperationsTest.json
+++ b/tests/files/VMTests/vmIOandFlowOperationsTest.json
diff --git a/VMTests/vmInputLimits1.json b/tests/files/VMTests/vmInputLimits1.json
index 45fa47cbe..45fa47cbe 100644
--- a/VMTests/vmInputLimits1.json
+++ b/tests/files/VMTests/vmInputLimits1.json
diff --git a/VMTests/vmInputLimits2.json b/tests/files/VMTests/vmInputLimits2.json
index ccce32f04..ccce32f04 100644
--- a/VMTests/vmInputLimits2.json
+++ b/tests/files/VMTests/vmInputLimits2.json
diff --git a/VMTests/vmInputLimitsLight.json b/tests/files/VMTests/vmInputLimitsLight.json
index 76fd78b98..76fd78b98 100644
--- a/VMTests/vmInputLimitsLight.json
+++ b/tests/files/VMTests/vmInputLimitsLight.json
diff --git a/VMTests/vmLogTest.json b/tests/files/VMTests/vmLogTest.json
index 81eb0895e..81eb0895e 100644
--- a/VMTests/vmLogTest.json
+++ b/tests/files/VMTests/vmLogTest.json
diff --git a/VMTests/vmPerformanceTest.json b/tests/files/VMTests/vmPerformanceTest.json
index 5139a567e..5139a567e 100644
--- a/VMTests/vmPerformanceTest.json
+++ b/tests/files/VMTests/vmPerformanceTest.json
diff --git a/VMTests/vmPushDupSwapTest.json b/tests/files/VMTests/vmPushDupSwapTest.json
index 20156efb8..20156efb8 100644
--- a/VMTests/vmPushDupSwapTest.json
+++ b/tests/files/VMTests/vmPushDupSwapTest.json
diff --git a/VMTests/vmSha3Test.json b/tests/files/VMTests/vmSha3Test.json
index 7c3e66ad3..7c3e66ad3 100644
--- a/VMTests/vmSha3Test.json
+++ b/tests/files/VMTests/vmSha3Test.json
diff --git a/VMTests/vmSystemOperationsTest.json b/tests/files/VMTests/vmSystemOperationsTest.json
index c9b19f304..c9b19f304 100644
--- a/VMTests/vmSystemOperationsTest.json
+++ b/tests/files/VMTests/vmSystemOperationsTest.json
diff --git a/VMTests/vmtests.json b/tests/files/VMTests/vmtests.json
index edb36651e..edb36651e 100644
--- a/VMTests/vmtests.json
+++ b/tests/files/VMTests/vmtests.json
diff --git a/ansible/README.md b/tests/files/ansible/README.md
index cef407986..cef407986 100644
--- a/ansible/README.md
+++ b/tests/files/ansible/README.md
diff --git a/ansible/Vagrantfile b/tests/files/ansible/Vagrantfile
index ce6ac3dde..ce6ac3dde 100644
--- a/ansible/Vagrantfile
+++ b/tests/files/ansible/Vagrantfile
diff --git a/ansible/ec2-setup.yml b/tests/files/ansible/ec2-setup.yml
index 37396d523..37396d523 100644
--- a/ansible/ec2-setup.yml
+++ b/tests/files/ansible/ec2-setup.yml
diff --git a/ansible/ec2-terminate.yml b/tests/files/ansible/ec2-terminate.yml
index 8a8edc536..8a8edc536 100644
--- a/ansible/ec2-terminate.yml
+++ b/tests/files/ansible/ec2-terminate.yml
diff --git a/ansible/ec2.ini b/tests/files/ansible/ec2.ini
index 064920410..064920410 100644
--- a/ansible/ec2.ini
+++ b/tests/files/ansible/ec2.ini
diff --git a/ansible/ec2.py b/tests/files/ansible/ec2.py
index f1b3524e1..f1b3524e1 100755
--- a/ansible/ec2.py
+++ b/tests/files/ansible/ec2.py
diff --git a/ansible/host-config.yml b/tests/files/ansible/host-config.yml
index c4c8e6eb9..c4c8e6eb9 100644
--- a/ansible/host-config.yml
+++ b/tests/files/ansible/host-config.yml
diff --git a/ansible/roles/common/handlers/main.yml b/tests/files/ansible/roles/common/handlers/main.yml
index 767fc7ba6..767fc7ba6 100644
--- a/ansible/roles/common/handlers/main.yml
+++ b/tests/files/ansible/roles/common/handlers/main.yml
diff --git a/ansible/roles/common/tasks/main.yml b/tests/files/ansible/roles/common/tasks/main.yml
index 6c0c7a119..6c0c7a119 100644
--- a/ansible/roles/common/tasks/main.yml
+++ b/tests/files/ansible/roles/common/tasks/main.yml
diff --git a/ansible/roles/docker/handlers/main.yml b/tests/files/ansible/roles/docker/handlers/main.yml
index 767fc7ba6..767fc7ba6 100644
--- a/ansible/roles/docker/handlers/main.yml
+++ b/tests/files/ansible/roles/docker/handlers/main.yml
diff --git a/ansible/roles/docker/tasks/main.yml b/tests/files/ansible/roles/docker/tasks/main.yml
index c434b34a5..c434b34a5 100644
--- a/ansible/roles/docker/tasks/main.yml
+++ b/tests/files/ansible/roles/docker/tasks/main.yml
diff --git a/ansible/roles/ec2/tasks/setup.yml b/tests/files/ansible/roles/ec2/tasks/setup.yml
index 299b55c35..299b55c35 100644
--- a/ansible/roles/ec2/tasks/setup.yml
+++ b/tests/files/ansible/roles/ec2/tasks/setup.yml
diff --git a/ansible/roles/ec2/tasks/terminate.yml b/tests/files/ansible/roles/ec2/tasks/terminate.yml
index e3d3df672..e3d3df672 100644
--- a/ansible/roles/ec2/tasks/terminate.yml
+++ b/tests/files/ansible/roles/ec2/tasks/terminate.yml
diff --git a/ansible/roles/ec2/vars/main.yml b/tests/files/ansible/roles/ec2/vars/main.yml
index f5cf28596..f5cf28596 100644
--- a/ansible/roles/ec2/vars/main.yml
+++ b/tests/files/ansible/roles/ec2/vars/main.yml
diff --git a/ansible/roles/testrunner/tasks/main.yml b/tests/files/ansible/roles/testrunner/tasks/main.yml
index 41c195f24..41c195f24 100644
--- a/ansible/roles/testrunner/tasks/main.yml
+++ b/tests/files/ansible/roles/testrunner/tasks/main.yml
diff --git a/ansible/site.yml b/tests/files/ansible/site.yml
index cc04daa94..cc04daa94 100644
--- a/ansible/site.yml
+++ b/tests/files/ansible/site.yml
diff --git a/ansible/test-files/create-docker-images.sh b/tests/files/ansible/test-files/create-docker-images.sh
index 06728c6d7..06728c6d7 100755
--- a/ansible/test-files/create-docker-images.sh
+++ b/tests/files/ansible/test-files/create-docker-images.sh
diff --git a/ansible/test-files/docker-cpp/Dockerfile b/tests/files/ansible/test-files/docker-cpp/Dockerfile
index a3b0e4ca6..a3b0e4ca6 100644
--- a/ansible/test-files/docker-cpp/Dockerfile
+++ b/tests/files/ansible/test-files/docker-cpp/Dockerfile
diff --git a/ansible/test-files/docker-cppjit/Dockerfile b/tests/files/ansible/test-files/docker-cppjit/Dockerfile
index 2b10727f0..2b10727f0 100644
--- a/ansible/test-files/docker-cppjit/Dockerfile
+++ b/tests/files/ansible/test-files/docker-cppjit/Dockerfile
diff --git a/ansible/test-files/docker-go/Dockerfile b/tests/files/ansible/test-files/docker-go/Dockerfile
index a5a2f0f23..a5a2f0f23 100644
--- a/ansible/test-files/docker-go/Dockerfile
+++ b/tests/files/ansible/test-files/docker-go/Dockerfile
diff --git a/ansible/test-files/docker-python/Dockerfile b/tests/files/ansible/test-files/docker-python/Dockerfile
index e83faf3d6..e83faf3d6 100644
--- a/ansible/test-files/docker-python/Dockerfile
+++ b/tests/files/ansible/test-files/docker-python/Dockerfile
diff --git a/ansible/test-files/testrunner.sh b/tests/files/ansible/test-files/testrunner.sh
index c7763b1f1..c7763b1f1 100755
--- a/ansible/test-files/testrunner.sh
+++ b/tests/files/ansible/test-files/testrunner.sh
diff --git a/ansible/testrunner-config.yml b/tests/files/ansible/testrunner-config.yml
index e9cf497f6..e9cf497f6 100644
--- a/ansible/testrunner-config.yml
+++ b/tests/files/ansible/testrunner-config.yml
diff --git a/index.js b/tests/files/index.js
index 732cb7b26..732cb7b26 100644
--- a/index.js
+++ b/tests/files/index.js
diff --git a/package.json b/tests/files/package.json
index beadb63bc..beadb63bc 100644
--- a/package.json
+++ b/tests/files/package.json
diff --git a/tests/helper/common.go b/tests/helper/common.go
new file mode 100644
index 000000000..21ea2261f
--- /dev/null
+++ b/tests/helper/common.go
@@ -0,0 +1,11 @@
+package helper
+
+import "github.com/ethereum/go-ethereum/common"
+
+func FromHex(h string) []byte {
+ if common.IsHex(h) {
+ h = h[2:]
+ }
+
+ return common.Hex2Bytes(h)
+}
diff --git a/tests/helper/init.go b/tests/helper/init.go
new file mode 100644
index 000000000..73d563e02
--- /dev/null
+++ b/tests/helper/init.go
@@ -0,0 +1,16 @@
+package helper
+
+import (
+ "log"
+ "os"
+
+ logpkg "github.com/ethereum/go-ethereum/logger"
+)
+
+var Logger *logpkg.StdLogSystem
+var Log = logpkg.NewLogger("TEST")
+
+func init() {
+ Logger = logpkg.NewStdLogSystem(os.Stdout, log.LstdFlags, logpkg.InfoLevel)
+ logpkg.AddLogSystem(Logger)
+}
diff --git a/tests/helper/readers.go b/tests/helper/readers.go
new file mode 100644
index 000000000..03313aeda
--- /dev/null
+++ b/tests/helper/readers.go
@@ -0,0 +1,42 @@
+package helper
+
+import (
+ "encoding/json"
+ "io"
+ "io/ioutil"
+ "net/http"
+ "os"
+ "testing"
+)
+
+func readJSON(t *testing.T, reader io.Reader, value interface{}) {
+ data, err := ioutil.ReadAll(reader)
+ err = json.Unmarshal(data, &value)
+ if err != nil {
+ t.Error(err)
+ }
+}
+
+func CreateHttpTests(t *testing.T, uri string, value interface{}) {
+ resp, err := http.Get(uri)
+ if err != nil {
+ t.Error(err)
+
+ return
+ }
+ defer resp.Body.Close()
+
+ readJSON(t, resp.Body, value)
+}
+
+func CreateFileTests(t *testing.T, fn string, value interface{}) {
+ file, err := os.Open(fn)
+ if err != nil {
+ t.Error(err)
+
+ return
+ }
+ defer file.Close()
+
+ readJSON(t, file, value)
+}
diff --git a/tests/helper/trie.go b/tests/helper/trie.go
new file mode 100644
index 000000000..9e666d333
--- /dev/null
+++ b/tests/helper/trie.go
@@ -0,0 +1,31 @@
+package helper
+
+import "github.com/ethereum/go-ethereum/trie"
+
+type MemDatabase struct {
+ db map[string][]byte
+}
+
+func NewMemDatabase() (*MemDatabase, error) {
+ db := &MemDatabase{db: make(map[string][]byte)}
+ return db, nil
+}
+func (db *MemDatabase) Put(key []byte, value []byte) {
+ db.db[string(key)] = value
+}
+func (db *MemDatabase) Get(key []byte) ([]byte, error) {
+ return db.db[string(key)], nil
+}
+func (db *MemDatabase) Delete(key []byte) error {
+ delete(db.db, string(key))
+ return nil
+}
+func (db *MemDatabase) Print() {}
+func (db *MemDatabase) Close() {}
+func (db *MemDatabase) LastKnownTD() []byte { return nil }
+
+func NewTrie() *trie.Trie {
+ db, _ := NewMemDatabase()
+
+ return trie.New(nil, db)
+}
diff --git a/tests/helper/vm.go b/tests/helper/vm.go
new file mode 100644
index 000000000..9f62ada95
--- /dev/null
+++ b/tests/helper/vm.go
@@ -0,0 +1,211 @@
+package helper
+
+import (
+ "errors"
+ "math/big"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/core"
+ "github.com/ethereum/go-ethereum/core/state"
+ "github.com/ethereum/go-ethereum/core/vm"
+ "github.com/ethereum/go-ethereum/crypto"
+)
+
+type Env struct {
+ depth int
+ state *state.StateDB
+ skipTransfer bool
+ initial bool
+ Gas *big.Int
+
+ origin common.Address
+ //parent common.Hash
+ coinbase common.Address
+
+ number *big.Int
+ time int64
+ difficulty *big.Int
+ gasLimit *big.Int
+
+ logs state.Logs
+
+ vmTest bool
+}
+
+func NewEnv(state *state.StateDB) *Env {
+ return &Env{
+ state: state,
+ }
+}
+
+func NewEnvFromMap(state *state.StateDB, envValues map[string]string, exeValues map[string]string) *Env {
+ env := NewEnv(state)
+
+ env.origin = common.HexToAddress(exeValues["caller"])
+ //env.parent = common.Hex2Bytes(envValues["previousHash"])
+ env.coinbase = common.HexToAddress(envValues["currentCoinbase"])
+ env.number = common.Big(envValues["currentNumber"])
+ env.time = common.Big(envValues["currentTimestamp"]).Int64()
+ env.difficulty = common.Big(envValues["currentDifficulty"])
+ env.gasLimit = common.Big(envValues["currentGasLimit"])
+ env.Gas = new(big.Int)
+
+ return env
+}
+
+func (self *Env) Origin() common.Address { return self.origin }
+func (self *Env) BlockNumber() *big.Int { return self.number }
+
+//func (self *Env) PrevHash() []byte { return self.parent }
+func (self *Env) Coinbase() common.Address { return self.coinbase }
+func (self *Env) Time() int64 { return self.time }
+func (self *Env) Difficulty() *big.Int { return self.difficulty }
+func (self *Env) State() *state.StateDB { return self.state }
+func (self *Env) GasLimit() *big.Int { return self.gasLimit }
+func (self *Env) VmType() vm.Type { return vm.StdVmTy }
+func (self *Env) GetHash(n uint64) common.Hash {
+ return common.BytesToHash(crypto.Sha3([]byte(big.NewInt(int64(n)).String())))
+}
+func (self *Env) AddLog(log state.Log) {
+ self.logs = append(self.logs, log)
+}
+func (self *Env) Depth() int { return self.depth }
+func (self *Env) SetDepth(i int) { self.depth = i }
+func (self *Env) Transfer(from, to vm.Account, amount *big.Int) error {
+ if self.skipTransfer {
+ // ugly hack
+ if self.initial {
+ self.initial = false
+ return nil
+ }
+
+ if from.Balance().Cmp(amount) < 0 {
+ return errors.New("Insufficient balance in account")
+ }
+
+ return nil
+ }
+ return vm.Transfer(from, to, amount)
+}
+
+func (self *Env) vm(addr *common.Address, data []byte, gas, price, value *big.Int) *core.Execution {
+ exec := core.NewExecution(self, addr, data, gas, price, value)
+
+ return exec
+}
+
+func (self *Env) Call(caller vm.ContextRef, addr common.Address, data []byte, gas, price, value *big.Int) ([]byte, error) {
+ if self.vmTest && self.depth > 0 {
+ caller.ReturnGas(gas, price)
+
+ return nil, nil
+ }
+ exe := self.vm(&addr, data, gas, price, value)
+ ret, err := exe.Call(addr, caller)
+ self.Gas = exe.Gas
+
+ return ret, err
+
+}
+func (self *Env) CallCode(caller vm.ContextRef, addr common.Address, data []byte, gas, price, value *big.Int) ([]byte, error) {
+ if self.vmTest && self.depth > 0 {
+ caller.ReturnGas(gas, price)
+
+ return nil, nil
+ }
+
+ caddr := caller.Address()
+ exe := self.vm(&caddr, data, gas, price, value)
+ return exe.Call(addr, caller)
+}
+
+func (self *Env) Create(caller vm.ContextRef, data []byte, gas, price, value *big.Int) ([]byte, error, vm.ContextRef) {
+ exe := self.vm(nil, data, gas, price, value)
+ if self.vmTest {
+ caller.ReturnGas(gas, price)
+
+ nonce := self.state.GetNonce(caller.Address())
+ obj := self.state.GetOrNewStateObject(crypto.CreateAddress(caller.Address(), nonce))
+
+ return nil, nil, obj
+ } else {
+ return exe.Create(caller)
+ }
+}
+
+func RunVm(state *state.StateDB, env, exec map[string]string) ([]byte, state.Logs, *big.Int, error) {
+ var (
+ to = common.HexToAddress(exec["address"])
+ from = common.HexToAddress(exec["caller"])
+ data = FromHex(exec["data"])
+ gas = common.Big(exec["gas"])
+ price = common.Big(exec["gasPrice"])
+ value = common.Big(exec["value"])
+ )
+ // Reset the pre-compiled contracts for VM tests.
+ vm.Precompiled = make(map[string]*vm.PrecompiledAccount)
+
+ caller := state.GetOrNewStateObject(from)
+
+ vmenv := NewEnvFromMap(state, env, exec)
+ vmenv.vmTest = true
+ vmenv.skipTransfer = true
+ vmenv.initial = true
+ ret, err := vmenv.Call(caller, to, data, gas, price, value)
+
+ return ret, vmenv.logs, vmenv.Gas, err
+}
+
+func RunState(statedb *state.StateDB, env, tx map[string]string) ([]byte, state.Logs, *big.Int, error) {
+ var (
+ keyPair, _ = crypto.NewKeyPairFromSec([]byte(common.Hex2Bytes(tx["secretKey"])))
+ data = FromHex(tx["data"])
+ gas = common.Big(tx["gasLimit"])
+ price = common.Big(tx["gasPrice"])
+ value = common.Big(tx["value"])
+ caddr = common.HexToAddress(env["currentCoinbase"])
+ )
+
+ var to *common.Address
+ if len(tx["to"]) > 2 {
+ t := common.HexToAddress(tx["to"])
+ to = &t
+ }
+ // Set pre compiled contracts
+ vm.Precompiled = vm.PrecompiledContracts()
+
+ snapshot := statedb.Copy()
+ coinbase := statedb.GetOrNewStateObject(caddr)
+ coinbase.SetGasPool(common.Big(env["currentGasLimit"]))
+
+ message := NewMessage(common.BytesToAddress(keyPair.Address()), to, data, value, gas, price)
+ vmenv := NewEnvFromMap(statedb, env, tx)
+ vmenv.origin = common.BytesToAddress(keyPair.Address())
+ ret, _, err := core.ApplyMessage(vmenv, message, coinbase)
+ if core.IsNonceErr(err) || core.IsInvalidTxErr(err) {
+ statedb.Set(snapshot)
+ }
+ statedb.Update()
+
+ return ret, vmenv.logs, vmenv.Gas, err
+}
+
+type Message struct {
+ from common.Address
+ to *common.Address
+ value, gas, price *big.Int
+ data []byte
+}
+
+func NewMessage(from common.Address, to *common.Address, data []byte, value, gas, price *big.Int) Message {
+ return Message{from, to, value, gas, price, data}
+}
+
+func (self Message) Hash() []byte { return nil }
+func (self Message) From() (common.Address, error) { return self.from, nil }
+func (self Message) To() *common.Address { return self.to }
+func (self Message) GasPrice() *big.Int { return self.price }
+func (self Message) Gas() *big.Int { return self.gas }
+func (self Message) Value() *big.Int { return self.value }
+func (self Message) Nonce() uint64 { return 0 }
+func (self Message) Data() []byte { return self.data }
diff --git a/tests/vm/.ethtest b/tests/vm/.ethtest
new file mode 100644
index 000000000..e69de29bb
--- /dev/null
+++ b/tests/vm/.ethtest
diff --git a/tests/vm/gh_test.go b/tests/vm/gh_test.go
new file mode 100644
index 000000000..cd5684dd4
--- /dev/null
+++ b/tests/vm/gh_test.go
@@ -0,0 +1,313 @@
+package vm
+
+import (
+ "bytes"
+ "math/big"
+ "strconv"
+ "testing"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/core/state"
+ "github.com/ethereum/go-ethereum/core/types"
+ "github.com/ethereum/go-ethereum/ethdb"
+ "github.com/ethereum/go-ethereum/logger"
+ "github.com/ethereum/go-ethereum/tests/helper"
+)
+
+type Account struct {
+ Balance string
+ Code string
+ Nonce string
+ Storage map[string]string
+}
+
+type Log struct {
+ AddressF string `json:"address"`
+ DataF string `json:"data"`
+ TopicsF []string `json:"topics"`
+ BloomF string `json:"bloom"`
+}
+
+func (self Log) Address() []byte { return common.Hex2Bytes(self.AddressF) }
+func (self Log) Data() []byte { return common.Hex2Bytes(self.DataF) }
+func (self Log) RlpData() interface{} { return nil }
+func (self Log) Topics() [][]byte {
+ t := make([][]byte, len(self.TopicsF))
+ for i, topic := range self.TopicsF {
+ t[i] = common.Hex2Bytes(topic)
+ }
+ return t
+}
+
+func StateObjectFromAccount(db common.Database, addr string, account Account) *state.StateObject {
+ obj := state.NewStateObject(common.HexToAddress(addr), db)
+ obj.SetBalance(common.Big(account.Balance))
+
+ if common.IsHex(account.Code) {
+ account.Code = account.Code[2:]
+ }
+ obj.SetCode(common.Hex2Bytes(account.Code))
+ obj.SetNonce(common.Big(account.Nonce).Uint64())
+
+ return obj
+}
+
+type Env struct {
+ CurrentCoinbase string
+ CurrentDifficulty string
+ CurrentGasLimit string
+ CurrentNumber string
+ CurrentTimestamp interface{}
+ PreviousHash string
+}
+
+type VmTest struct {
+ Callcreates interface{}
+ //Env map[string]string
+ Env Env
+ Exec map[string]string
+ Transaction map[string]string
+ Logs []Log
+ Gas string
+ Out string
+ Post map[string]Account
+ Pre map[string]Account
+ PostStateRoot string
+}
+
+func RunVmTest(p string, t *testing.T) {
+
+ tests := make(map[string]VmTest)
+ helper.CreateFileTests(t, p, &tests)
+
+ for name, test := range tests {
+ db, _ := ethdb.NewMemDatabase()
+ statedb := state.New(common.Hash{}, db)
+ for addr, account := range test.Pre {
+ obj := StateObjectFromAccount(db, addr, account)
+ statedb.SetStateObject(obj)
+ for a, v := range account.Storage {
+ obj.SetState(common.HexToHash(a), common.NewValue(helper.FromHex(v)))
+ }
+ }
+
+ // XXX Yeah, yeah...
+ env := make(map[string]string)
+ env["currentCoinbase"] = test.Env.CurrentCoinbase
+ env["currentDifficulty"] = test.Env.CurrentDifficulty
+ env["currentGasLimit"] = test.Env.CurrentGasLimit
+ env["currentNumber"] = test.Env.CurrentNumber
+ env["previousHash"] = test.Env.PreviousHash
+ if n, ok := test.Env.CurrentTimestamp.(float64); ok {
+ env["currentTimestamp"] = strconv.Itoa(int(n))
+ } else {
+ env["currentTimestamp"] = test.Env.CurrentTimestamp.(string)
+ }
+
+ var (
+ ret []byte
+ gas *big.Int
+ err error
+ logs state.Logs
+ )
+
+ isVmTest := len(test.Exec) > 0
+ if isVmTest {
+ ret, logs, gas, err = helper.RunVm(statedb, env, test.Exec)
+ } else {
+ ret, logs, gas, err = helper.RunState(statedb, env, test.Transaction)
+ }
+
+ rexp := helper.FromHex(test.Out)
+ if bytes.Compare(rexp, ret) != 0 {
+ t.Errorf("%s's return failed. Expected %x, got %x\n", name, rexp, ret)
+ }
+
+ if isVmTest {
+ if len(test.Gas) == 0 && err == nil {
+ t.Errorf("%s's gas unspecified, indicating an error. VM returned (incorrectly) successfull", name)
+ } else {
+ gexp := common.Big(test.Gas)
+ if gexp.Cmp(gas) != 0 {
+ t.Errorf("%s's gas failed. Expected %v, got %v\n", name, gexp, gas)
+ }
+ }
+ }
+
+ for addr, account := range test.Post {
+ obj := statedb.GetStateObject(common.HexToAddress(addr))
+ if obj == nil {
+ continue
+ }
+
+ if len(test.Exec) == 0 {
+ if obj.Balance().Cmp(common.Big(account.Balance)) != 0 {
+ t.Errorf("%s's : (%x) balance failed. Expected %v, got %v => %v\n", name, obj.Address().Bytes()[:4], account.Balance, obj.Balance(), new(big.Int).Sub(common.Big(account.Balance), obj.Balance()))
+ }
+
+ if obj.Nonce() != common.String2Big(account.Nonce).Uint64() {
+ t.Errorf("%s's : (%x) nonce failed. Expected %v, got %v\n", name, obj.Address().Bytes()[:4], account.Nonce, obj.Nonce())
+ }
+
+ }
+
+ for addr, value := range account.Storage {
+ v := obj.GetState(common.HexToHash(addr)).Bytes()
+ vexp := helper.FromHex(value)
+
+ if bytes.Compare(v, vexp) != 0 {
+ t.Errorf("%s's : (%x: %s) storage failed. Expected %x, got %x (%v %v)\n", name, obj.Address().Bytes()[0:4], addr, vexp, v, common.BigD(vexp), common.BigD(v))
+ }
+ }
+ }
+
+ if !isVmTest {
+ statedb.Sync()
+ //if !bytes.Equal(common.Hex2Bytes(test.PostStateRoot), statedb.Root()) {
+ if common.HexToHash(test.PostStateRoot) != statedb.Root() {
+ t.Errorf("%s's : Post state root error. Expected %s, got %x", name, test.PostStateRoot, statedb.Root())
+ }
+ }
+
+ if len(test.Logs) > 0 {
+ if len(test.Logs) != len(logs) {
+ t.Errorf("log length mismatch. Expected %d, got %d", len(test.Logs), len(logs))
+ } else {
+ for i, log := range test.Logs {
+ if common.HexToAddress(log.AddressF) != logs[i].Address() {
+ t.Errorf("'%s' log address expected %v got %x", name, log.AddressF, logs[i].Address())
+ }
+
+ if !bytes.Equal(logs[i].Data(), helper.FromHex(log.DataF)) {
+ t.Errorf("'%s' log data expected %v got %x", name, log.DataF, logs[i].Data())
+ }
+
+ if len(log.TopicsF) != len(logs[i].Topics()) {
+ t.Errorf("'%s' log topics length expected %d got %d", name, len(log.TopicsF), logs[i].Topics())
+ } else {
+ for j, topic := range log.TopicsF {
+ if common.HexToHash(topic) != logs[i].Topics()[j] {
+ t.Errorf("'%s' log topic[%d] expected %v got %x", name, j, topic, logs[i].Topics()[j])
+ }
+ }
+ }
+ genBloom := common.LeftPadBytes(types.LogsBloom(state.Logs{logs[i]}).Bytes(), 256)
+
+ if !bytes.Equal(genBloom, common.Hex2Bytes(log.BloomF)) {
+ t.Errorf("'%s' bloom mismatch", name)
+ }
+ }
+ }
+ }
+ //fmt.Println(string(statedb.Dump()))
+ }
+ logger.Flush()
+}
+
+// I've created a new function for each tests so it's easier to identify where the problem lies if any of them fail.
+func TestVMArithmetic(t *testing.T) {
+ const fn = "../files/VMTests/vmArithmeticTest.json"
+ RunVmTest(fn, t)
+}
+
+func TestBitwiseLogicOperation(t *testing.T) {
+ const fn = "../files/VMTests/vmBitwiseLogicOperationTest.json"
+ RunVmTest(fn, t)
+}
+
+func TestBlockInfo(t *testing.T) {
+ const fn = "../files/VMTests/vmBlockInfoTest.json"
+ RunVmTest(fn, t)
+}
+
+func TestEnvironmentalInfo(t *testing.T) {
+ const fn = "../files/VMTests/vmEnvironmentalInfoTest.json"
+ RunVmTest(fn, t)
+}
+
+func TestFlowOperation(t *testing.T) {
+ const fn = "../files/VMTests/vmIOandFlowOperationsTest.json"
+ RunVmTest(fn, t)
+}
+
+func TestLogTest(t *testing.T) {
+ const fn = "../files/VMTests/vmLogTest.json"
+ RunVmTest(fn, t)
+}
+
+func TestPerformance(t *testing.T) {
+ t.Skip()
+ const fn = "../files/VMTests/vmPerformance.json"
+ RunVmTest(fn, t)
+}
+
+func TestPushDupSwap(t *testing.T) {
+ const fn = "../files/VMTests/vmPushDupSwapTest.json"
+ RunVmTest(fn, t)
+}
+
+func TestVMSha3(t *testing.T) {
+ const fn = "../files/VMTests/vmSha3Test.json"
+ RunVmTest(fn, t)
+}
+
+func TestVm(t *testing.T) {
+ const fn = "../files/VMTests/vmtests.json"
+ RunVmTest(fn, t)
+}
+
+func TestVmLog(t *testing.T) {
+ const fn = "../files/VMTests/vmLogTest.json"
+ RunVmTest(fn, t)
+}
+
+func TestStateExample(t *testing.T) {
+ const fn = "../files/StateTests/stExample.json"
+ RunVmTest(fn, t)
+}
+
+func TestStateSystemOperations(t *testing.T) {
+ const fn = "../files/StateTests/stSystemOperationsTest.json"
+ RunVmTest(fn, t)
+}
+
+func TestStatePreCompiledContracts(t *testing.T) {
+ const fn = "../files/StateTests/stPreCompiledContracts.json"
+ RunVmTest(fn, t)
+}
+
+func TestStateRecursiveCreate(t *testing.T) {
+ const fn = "../files/StateTests/stRecursiveCreate.json"
+ RunVmTest(fn, t)
+}
+
+func TestStateSpecial(t *testing.T) {
+ const fn = "../files/StateTests/stSpecialTest.json"
+ RunVmTest(fn, t)
+}
+
+func TestStateRefund(t *testing.T) {
+ const fn = "../files/StateTests/stRefundTest.json"
+ RunVmTest(fn, t)
+}
+
+func TestStateBlockHash(t *testing.T) {
+ const fn = "../files/StateTests/stBlockHashTest.json"
+ RunVmTest(fn, t)
+}
+
+func TestStateInitCode(t *testing.T) {
+ const fn = "../files/StateTests/stInitCodeTest.json"
+ RunVmTest(fn, t)
+}
+
+func TestStateLog(t *testing.T) {
+ const fn = "../files/StateTests/stLogTests.json"
+ RunVmTest(fn, t)
+}
+
+func TestStateTransaction(t *testing.T) {
+ t.Skip()
+ const fn = "../files/StateTests/stTransactionTest.json"
+ RunVmTest(fn, t)
+}
diff --git a/tests/vm/nowarn.go b/tests/vm/nowarn.go
new file mode 100644
index 000000000..2a45a6cc6
--- /dev/null
+++ b/tests/vm/nowarn.go
@@ -0,0 +1,3 @@
+// This silences the warning given by 'go install ./...'.
+
+package vm
diff --git a/trie/cache.go b/trie/cache.go
new file mode 100644
index 000000000..2143785fa
--- /dev/null
+++ b/trie/cache.go
@@ -0,0 +1,50 @@
+package trie
+
+type Backend interface {
+ Get([]byte) ([]byte, error)
+ Put([]byte, []byte)
+}
+
+type Cache struct {
+ store map[string][]byte
+ backend Backend
+}
+
+func NewCache(backend Backend) *Cache {
+ return &Cache{make(map[string][]byte), backend}
+}
+
+func (self *Cache) Get(key []byte) []byte {
+ data := self.store[string(key)]
+ if data == nil {
+ data, _ = self.backend.Get(key)
+ }
+
+ return data
+}
+
+func (self *Cache) Put(key []byte, data []byte) {
+ self.store[string(key)] = data
+}
+
+func (self *Cache) Flush() {
+ for k, v := range self.store {
+ self.backend.Put([]byte(k), v)
+ }
+
+ // This will eventually grow too large. We'd could
+ // do a make limit on storage and push out not-so-popular nodes.
+ //self.Reset()
+}
+
+func (self *Cache) Copy() *Cache {
+ cache := NewCache(self.backend)
+ for k, v := range self.store {
+ cache.store[k] = v
+ }
+ return cache
+}
+
+func (self *Cache) Reset() {
+ //self.store = make(map[string][]byte)
+}
diff --git a/trie/encoding.go b/trie/encoding.go
new file mode 100644
index 000000000..5c42c556f
--- /dev/null
+++ b/trie/encoding.go
@@ -0,0 +1,76 @@
+package trie
+
+import (
+ "bytes"
+ "encoding/hex"
+ "strings"
+)
+
+func CompactEncode(hexSlice []byte) string {
+ terminator := 0
+ if hexSlice[len(hexSlice)-1] == 16 {
+ terminator = 1
+ }
+
+ if terminator == 1 {
+ hexSlice = hexSlice[:len(hexSlice)-1]
+ }
+
+ oddlen := len(hexSlice) % 2
+ flags := byte(2*terminator + oddlen)
+ if oddlen != 0 {
+ hexSlice = append([]byte{flags}, hexSlice...)
+ } else {
+ hexSlice = append([]byte{flags, 0}, hexSlice...)
+ }
+
+ var buff bytes.Buffer
+ for i := 0; i < len(hexSlice); i += 2 {
+ buff.WriteByte(byte(16*hexSlice[i] + hexSlice[i+1]))
+ }
+
+ return buff.String()
+}
+
+func CompactDecode(str string) []byte {
+ base := CompactHexDecode(str)
+ base = base[:len(base)-1]
+ if base[0] >= 2 {
+ base = append(base, 16)
+ }
+ if base[0]%2 == 1 {
+ base = base[1:]
+ } else {
+ base = base[2:]
+ }
+
+ return base
+}
+
+func CompactHexDecode(str string) []byte {
+ base := "0123456789abcdef"
+ var hexSlice []byte
+
+ enc := hex.EncodeToString([]byte(str))
+ for _, v := range enc {
+ hexSlice = append(hexSlice, byte(strings.IndexByte(base, byte(v))))
+ }
+ hexSlice = append(hexSlice, 16)
+
+ return hexSlice
+}
+
+func DecodeCompact(key []byte) string {
+ const base = "0123456789abcdef"
+ var str string
+
+ for _, v := range key {
+ if v < 16 {
+ str += string(base[v])
+ }
+ }
+
+ res, _ := hex.DecodeString(str)
+
+ return string(res)
+}
diff --git a/trie/encoding_test.go b/trie/encoding_test.go
new file mode 100644
index 000000000..193c898f3
--- /dev/null
+++ b/trie/encoding_test.go
@@ -0,0 +1,59 @@
+package trie
+
+import (
+ checker "gopkg.in/check.v1"
+)
+
+type TrieEncodingSuite struct{}
+
+var _ = checker.Suite(&TrieEncodingSuite{})
+
+func (s *TrieEncodingSuite) TestCompactEncode(c *checker.C) {
+ // even compact encode
+ test1 := []byte{1, 2, 3, 4, 5}
+ res1 := CompactEncode(test1)
+ c.Assert(res1, checker.Equals, "\x11\x23\x45")
+
+ // odd compact encode
+ test2 := []byte{0, 1, 2, 3, 4, 5}
+ res2 := CompactEncode(test2)
+ c.Assert(res2, checker.Equals, "\x00\x01\x23\x45")
+
+ //odd terminated compact encode
+ test3 := []byte{0, 15, 1, 12, 11, 8 /*term*/, 16}
+ res3 := CompactEncode(test3)
+ c.Assert(res3, checker.Equals, "\x20\x0f\x1c\xb8")
+
+ // even terminated compact encode
+ test4 := []byte{15, 1, 12, 11, 8 /*term*/, 16}
+ res4 := CompactEncode(test4)
+ c.Assert(res4, checker.Equals, "\x3f\x1c\xb8")
+}
+
+func (s *TrieEncodingSuite) TestCompactHexDecode(c *checker.C) {
+ exp := []byte{7, 6, 6, 5, 7, 2, 6, 2, 16}
+ res := CompactHexDecode("verb")
+ c.Assert(res, checker.DeepEquals, exp)
+}
+
+func (s *TrieEncodingSuite) TestCompactDecode(c *checker.C) {
+ // odd compact decode
+ exp := []byte{1, 2, 3, 4, 5}
+ res := CompactDecode("\x11\x23\x45")
+ c.Assert(res, checker.DeepEquals, exp)
+
+ // even compact decode
+ exp = []byte{0, 1, 2, 3, 4, 5}
+ res = CompactDecode("\x00\x01\x23\x45")
+ c.Assert(res, checker.DeepEquals, exp)
+
+ // even terminated compact decode
+ exp = []byte{0, 15, 1, 12, 11, 8 /*term*/, 16}
+ res = CompactDecode("\x20\x0f\x1c\xb8")
+ c.Assert(res, checker.DeepEquals, exp)
+
+ // even terminated compact decode
+ exp = []byte{15, 1, 12, 11, 8 /*term*/, 16}
+ res = CompactDecode("\x3f\x1c\xb8")
+ c.Assert(res, checker.DeepEquals, exp)
+}
diff --git a/trie/fullnode.go b/trie/fullnode.go
new file mode 100644
index 000000000..522fdb373
--- /dev/null
+++ b/trie/fullnode.go
@@ -0,0 +1,77 @@
+package trie
+
+import "fmt"
+
+type FullNode struct {
+ trie *Trie
+ nodes [17]Node
+}
+
+func NewFullNode(t *Trie) *FullNode {
+ return &FullNode{trie: t}
+}
+
+func (self *FullNode) Dirty() bool { return true }
+func (self *FullNode) Value() Node {
+ self.nodes[16] = self.trie.trans(self.nodes[16])
+ return self.nodes[16]
+}
+func (self *FullNode) Branches() []Node {
+ return self.nodes[:16]
+}
+
+func (self *FullNode) Copy(t *Trie) Node {
+ nnode := NewFullNode(t)
+ for i, node := range self.nodes {
+ if node != nil {
+ nnode.nodes[i] = node.Copy(t)
+ }
+ }
+
+ return nnode
+}
+
+// Returns the length of non-nil nodes
+func (self *FullNode) Len() (amount int) {
+ for _, node := range self.nodes {
+ if node != nil {
+ amount++
+ }
+ }
+
+ return
+}
+
+func (self *FullNode) Hash() interface{} {
+ return self.trie.store(self)
+}
+
+func (self *FullNode) RlpData() interface{} {
+ t := make([]interface{}, 17)
+ for i, node := range self.nodes {
+ if node != nil {
+ t[i] = node.Hash()
+ } else {
+ t[i] = ""
+ }
+ }
+
+ return t
+}
+
+func (self *FullNode) set(k byte, value Node) {
+ if _, ok := value.(*ValueNode); ok && k != 16 {
+ fmt.Println(value, k)
+ }
+
+ self.nodes[int(k)] = value
+}
+
+func (self *FullNode) branch(i byte) Node {
+ if self.nodes[int(i)] != nil {
+ self.nodes[int(i)] = self.trie.trans(self.nodes[int(i)])
+
+ return self.nodes[int(i)]
+ }
+ return nil
+}
diff --git a/trie/hashnode.go b/trie/hashnode.go
new file mode 100644
index 000000000..8125cc3c9
--- /dev/null
+++ b/trie/hashnode.go
@@ -0,0 +1,25 @@
+package trie
+
+import "github.com/ethereum/go-ethereum/common"
+
+type HashNode struct {
+ key []byte
+ trie *Trie
+}
+
+func NewHash(key []byte, trie *Trie) *HashNode {
+ return &HashNode{key, trie}
+}
+
+func (self *HashNode) RlpData() interface{} {
+ return self.key
+}
+
+func (self *HashNode) Hash() interface{} {
+ return self.key
+}
+
+// These methods will never be called but we have to satisfy Node interface
+func (self *HashNode) Value() Node { return nil }
+func (self *HashNode) Dirty() bool { return true }
+func (self *HashNode) Copy(t *Trie) Node { return NewHash(common.CopyBytes(self.key), t) }
diff --git a/trie/iterator.go b/trie/iterator.go
new file mode 100644
index 000000000..fda7c6cbe
--- /dev/null
+++ b/trie/iterator.go
@@ -0,0 +1,124 @@
+package trie
+
+import (
+ "bytes"
+)
+
+type Iterator struct {
+ trie *Trie
+
+ Key []byte
+ Value []byte
+}
+
+func NewIterator(trie *Trie) *Iterator {
+ return &Iterator{trie: trie, Key: nil}
+}
+
+func (self *Iterator) Next() bool {
+ self.trie.mu.Lock()
+ defer self.trie.mu.Unlock()
+
+ isIterStart := false
+ if self.Key == nil {
+ isIterStart = true
+ self.Key = make([]byte, 32)
+ }
+
+ key := RemTerm(CompactHexDecode(string(self.Key)))
+ k := self.next(self.trie.root, key, isIterStart)
+
+ self.Key = []byte(DecodeCompact(k))
+
+ return len(k) > 0
+}
+
+func (self *Iterator) next(node Node, key []byte, isIterStart bool) []byte {
+ if node == nil {
+ return nil
+ }
+
+ switch node := node.(type) {
+ case *FullNode:
+ if len(key) > 0 {
+ k := self.next(node.branch(key[0]), key[1:], isIterStart)
+ if k != nil {
+ return append([]byte{key[0]}, k...)
+ }
+ }
+
+ var r byte
+ if len(key) > 0 {
+ r = key[0] + 1
+ }
+
+ for i := r; i < 16; i++ {
+ k := self.key(node.branch(byte(i)))
+ if k != nil {
+ return append([]byte{i}, k...)
+ }
+ }
+
+ case *ShortNode:
+ k := RemTerm(node.Key())
+ if vnode, ok := node.Value().(*ValueNode); ok {
+ switch bytes.Compare([]byte(k), key) {
+ case 0:
+ if isIterStart {
+ self.Value = vnode.Val()
+ return k
+ }
+ case 1:
+ self.Value = vnode.Val()
+ return k
+ }
+ } else {
+ cnode := node.Value()
+
+ var ret []byte
+ skey := key[len(k):]
+ if BeginsWith(key, k) {
+ ret = self.next(cnode, skey, isIterStart)
+ } else if bytes.Compare(k, key[:len(k)]) > 0 {
+ return self.key(node)
+ }
+
+ if ret != nil {
+ return append(k, ret...)
+ }
+ }
+ }
+
+ return nil
+}
+
+func (self *Iterator) key(node Node) []byte {
+ switch node := node.(type) {
+ case *ShortNode:
+ // Leaf node
+ if vnode, ok := node.Value().(*ValueNode); ok {
+ k := RemTerm(node.Key())
+ self.Value = vnode.Val()
+
+ return k
+ } else {
+ k := RemTerm(node.Key())
+ return append(k, self.key(node.Value())...)
+ }
+ case *FullNode:
+ if node.Value() != nil {
+ self.Value = node.Value().(*ValueNode).Val()
+
+ return []byte{16}
+ }
+
+ for i := 0; i < 16; i++ {
+ k := self.key(node.branch(byte(i)))
+ if k != nil {
+ return append([]byte{byte(i)}, k...)
+ }
+ }
+ }
+
+ return nil
+}
diff --git a/trie/iterator_test.go b/trie/iterator_test.go
new file mode 100644
index 000000000..74d9e903c
--- /dev/null
+++ b/trie/iterator_test.go
@@ -0,0 +1,33 @@
+package trie
+
+import "testing"
+
+func TestIterator(t *testing.T) {
+ trie := NewEmpty()
+ vals := []struct{ k, v string }{
+ {"do", "verb"},
+ {"ether", "wookiedoo"},
+ {"horse", "stallion"},
+ {"shaman", "horse"},
+ {"doge", "coin"},
+ {"dog", "puppy"},
+ {"somethingveryoddindeedthis is", "myothernodedata"},
+ }
+ v := make(map[string]bool)
+ for _, val := range vals {
+ v[val.k] = false
+ trie.UpdateString(val.k, val.v)
+ }
+ trie.Commit()
+
+ it := trie.Iterator()
+ for it.Next() {
+ v[string(it.Key)] = true
+ }
+
+ for k, found := range v {
+ if !found {
+ t.Error("iterator didn't find", k)
+ }
+ }
+}
diff --git a/trie/node.go b/trie/node.go
new file mode 100644
index 000000000..0d8a7cff9
--- /dev/null
+++ b/trie/node.go
@@ -0,0 +1,44 @@
+package trie
+
+import "fmt"
+
+var indices = []string{"0", "1", "2", "3", "4", "5", "6", "7", "8", "9", "a", "b", "c", "d", "e", "f", "[17]"}
+
+type Node interface {
+ Value() Node
+ Copy(*Trie) Node // All nodes, for now, return them self
+ Dirty() bool
+ fstring(string) string
+ Hash() interface{}
+ RlpData() interface{}
+}
+
+// Value node
+func (self *ValueNode) String() string { return self.fstring("") }
+func (self *FullNode) String() string { return self.fstring("") }
+func (self *ShortNode) String() string { return self.fstring("") }
+func (self *ValueNode) fstring(ind string) string { return fmt.Sprintf("%x ", self.data) }
+
+//func (self *HashNode) fstring(ind string) string { return fmt.Sprintf("< %x > ", self.key) }
+func (self *HashNode) fstring(ind string) string {
+ return fmt.Sprintf("%v", self.trie.trans(self))
+}
+
+// Full node
+func (self *FullNode) fstring(ind string) string {
+ resp := fmt.Sprintf("[\n%s ", ind)
+ for i, node := range self.nodes {
+ if node == nil {
+ resp += fmt.Sprintf("%s: <nil> ", indices[i])
+ } else {
+ resp += fmt.Sprintf("%s: %v", indices[i], node.fstring(ind+" "))
+ }
+ }
+
+ return resp + fmt.Sprintf("\n%s] ", ind)
+}
+
+// Short node
+func (self *ShortNode) fstring(ind string) string {
+ return fmt.Sprintf("[ %x: %v ] ", self.key, self.value.fstring(ind+" "))
+}
diff --git a/trie/secure_trie.go b/trie/secure_trie.go
new file mode 100644
index 000000000..f7a1950e5
--- /dev/null
+++ b/trie/secure_trie.go
@@ -0,0 +1,45 @@
+package trie
+
+import "github.com/ethereum/go-ethereum/crypto"
+
+var keyPrefix = []byte("secure-key-")
+
+type SecureTrie struct {
+ *Trie
+}
+
+func NewSecure(root []byte, backend Backend) *SecureTrie {
+ return &SecureTrie{New(root, backend)}
+}
+
+func (self *SecureTrie) Update(key, value []byte) Node {
+ shaKey := crypto.Sha3(key)
+ self.Trie.cache.Put(append(keyPrefix, shaKey...), key)
+
+ return self.Trie.Update(shaKey, value)
+}
+func (self *SecureTrie) UpdateString(key, value string) Node {
+ return self.Update([]byte(key), []byte(value))
+}
+
+func (self *SecureTrie) Get(key []byte) []byte {
+ return self.Trie.Get(crypto.Sha3(key))
+}
+func (self *SecureTrie) GetString(key string) []byte {
+ return self.Get([]byte(key))
+}
+
+func (self *SecureTrie) Delete(key []byte) Node {
+ return self.Trie.Delete(crypto.Sha3(key))
+}
+func (self *SecureTrie) DeleteString(key string) Node {
+ return self.Delete([]byte(key))
+}
+
+func (self *SecureTrie) Copy() *SecureTrie {
+ return &SecureTrie{self.Trie.Copy()}
+}
+
+func (self *SecureTrie) GetKey(shaKey []byte) []byte {
+ return self.Trie.cache.Get(append(keyPrefix, shaKey...))
+}
diff --git a/trie/shortnode.go b/trie/shortnode.go
new file mode 100644
index 000000000..edd490b4d
--- /dev/null
+++ b/trie/shortnode.go
@@ -0,0 +1,35 @@
+package trie
+
+import "github.com/ethereum/go-ethereum/common"
+
+type ShortNode struct {
+ trie *Trie
+ key []byte
+ value Node
+}
+
+func NewShortNode(t *Trie, key []byte, value Node) *ShortNode {
+ return &ShortNode{t, []byte(CompactEncode(key)), value}
+}
+func (self *ShortNode) Value() Node {
+ self.value = self.trie.trans(self.value)
+
+ return self.value
+}
+func (self *ShortNode) Dirty() bool { return true }
+func (self *ShortNode) Copy(t *Trie) Node {
+ node := &ShortNode{t, nil, self.value.Copy(t)}
+ node.key = common.CopyBytes(self.key)
+ return node
+}
+
+func (self *ShortNode) RlpData() interface{} {
+ return []interface{}{self.key, self.value.Hash()}
+}
+func (self *ShortNode) Hash() interface{} {
+ return self.trie.store(self)
+}
+
+func (self *ShortNode) Key() []byte {
+ return CompactDecode(string(self.key))
+}
diff --git a/trie/slice.go b/trie/slice.go
new file mode 100644
index 000000000..f53b6c749
--- /dev/null
+++ b/trie/slice.go
@@ -0,0 +1,53 @@
+package trie
+
+import (
+ "bytes"
+ "math"
+)
+
+// Helper function for comparing slices
+func CompareIntSlice(a, b []int) bool {
+ if len(a) != len(b) {
+ return false
+ }
+ for i, v := range a {
+ if v != b[i] {
+ return false
+ }
+ }
+ return true
+}
+
+// Returns the amount of nibbles that match each other from 0 ...
+func MatchingNibbleLength(a, b []byte) int {
+ var i, length = 0, int(math.Min(float64(len(a)), float64(len(b))))
+
+ for i < length {
+ if a[i] != b[i] {
+ break
+ }
+ i++
+ }
+
+ return i
+}
+
+func HasTerm(s []byte) bool {
+ return s[len(s)-1] == 16
+}
+
+func RemTerm(s []byte) []byte {
+ if HasTerm(s) {
+ return s[:len(s)-1]
+ }
+
+ return s
+}
+
+func BeginsWith(a, b []byte) bool {
+ if len(b) > len(a) {
+ return false
+ }
+
+ return bytes.Equal(a[:len(b)], b)
+}
diff --git a/trie/trie.go b/trie/trie.go
new file mode 100644
index 000000000..d990338ee
--- /dev/null
+++ b/trie/trie.go
@@ -0,0 +1,352 @@
+package trie
+
+import (
+ "bytes"
+ "container/list"
+ "fmt"
+ "sync"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/crypto"
+)
+
+func ParanoiaCheck(t1 *Trie, backend Backend) (bool, *Trie) {
+ t2 := New(nil, backend)
+
+ it := t1.Iterator()
+ for it.Next() {
+ t2.Update(it.Key, it.Value)
+ }
+
+ return bytes.Equal(t2.Hash(), t1.Hash()), t2
+}
+
+type Trie struct {
+ mu sync.Mutex
+ root Node
+ roothash []byte
+ cache *Cache
+
+ revisions *list.List
+}
+
+func New(root []byte, backend Backend) *Trie {
+ trie := &Trie{}
+ trie.revisions = list.New()
+ trie.roothash = root
+ if backend != nil {
+ trie.cache = NewCache(backend)
+ }
+
+ if root != nil {
+ value := common.NewValueFromBytes(trie.cache.Get(root))
+ trie.root = trie.mknode(value)
+ }
+
+ return trie
+}
+
+func (self *Trie) Iterator() *Iterator {
+ return NewIterator(self)
+}
+
+func (self *Trie) Copy() *Trie {
+ cpy := make([]byte, 32)
+ copy(cpy, self.roothash)
+ trie := New(nil, nil)
+ trie.cache = self.cache.Copy()
+ if self.root != nil {
+ trie.root = self.root.Copy(trie)
+ }
+
+ return trie
+}
+
+// Legacy support
+func (self *Trie) Root() []byte { return self.Hash() }
+func (self *Trie) Hash() []byte {
+ var hash []byte
+ if self.root != nil {
+ t := self.root.Hash()
+ if byts, ok := t.([]byte); ok && len(byts) > 0 {
+ hash = byts
+ } else {
+ hash = crypto.Sha3(common.Encode(self.root.RlpData()))
+ }
+ } else {
+ hash = crypto.Sha3(common.Encode(""))
+ }
+
+ if !bytes.Equal(hash, self.roothash) {
+ self.revisions.PushBack(self.roothash)
+ self.roothash = hash
+ }
+
+ return hash
+}
+func (self *Trie) Commit() {
+ self.mu.Lock()
+ defer self.mu.Unlock()
+
+ // Hash first
+ self.Hash()
+
+ self.cache.Flush()
+}
+
+// Reset should only be called if the trie has been hashed
+func (self *Trie) Reset() {
+ self.mu.Lock()
+ defer self.mu.Unlock()
+
+ self.cache.Reset()
+
+ if self.revisions.Len() > 0 {
+ revision := self.revisions.Remove(self.revisions.Back()).([]byte)
+ self.roothash = revision
+ }
+ value := common.NewValueFromBytes(self.cache.Get(self.roothash))
+ self.root = self.mknode(value)
+}
+
+func (self *Trie) UpdateString(key, value string) Node { return self.Update([]byte(key), []byte(value)) }
+func (self *Trie) Update(key, value []byte) Node {
+ self.mu.Lock()
+ defer self.mu.Unlock()
+
+ k := CompactHexDecode(string(key))
+
+ if len(value) != 0 {
+ self.root = self.insert(self.root, k, &ValueNode{self, value})
+ } else {
+ self.root = self.delete(self.root, k)
+ }
+
+ return self.root
+}
+
+func (self *Trie) GetString(key string) []byte { return self.Get([]byte(key)) }
+func (self *Trie) Get(key []byte) []byte {
+ self.mu.Lock()
+ defer self.mu.Unlock()
+
+ k := CompactHexDecode(string(key))
+
+ n := self.get(self.root, k)
+ if n != nil {
+ return n.(*ValueNode).Val()
+ }
+
+ return nil
+}
+
+func (self *Trie) DeleteString(key string) Node { return self.Delete([]byte(key)) }
+func (self *Trie) Delete(key []byte) Node {
+ self.mu.Lock()
+ defer self.mu.Unlock()
+
+ k := CompactHexDecode(string(key))
+ self.root = self.delete(self.root, k)
+
+ return self.root
+}
+
+func (self *Trie) insert(node Node, key []byte, value Node) Node {
+ if len(key) == 0 {
+ return value
+ }
+
+ if node == nil {
+ return NewShortNode(self, key, value)
+ }
+
+ switch node := node.(type) {
+ case *ShortNode:
+ k := node.Key()
+ cnode := node.Value()
+ if bytes.Equal(k, key) {
+ return NewShortNode(self, key, value)
+ }
+
+ var n Node
+ matchlength := MatchingNibbleLength(key, k)
+ if matchlength == len(k) {
+ n = self.insert(cnode, key[matchlength:], value)
+ } else {
+ pnode := self.insert(nil, k[matchlength+1:], cnode)
+ nnode := self.insert(nil, key[matchlength+1:], value)
+ fulln := NewFullNode(self)
+ fulln.set(k[matchlength], pnode)
+ fulln.set(key[matchlength], nnode)
+ n = fulln
+ }
+ if matchlength == 0 {
+ return n
+ }
+
+ return NewShortNode(self, key[:matchlength], n)
+
+ case *FullNode:
+ cpy := node.Copy(self).(*FullNode)
+ cpy.set(key[0], self.insert(node.branch(key[0]), key[1:], value))
+
+ return cpy
+
+ default:
+ panic(fmt.Sprintf("%T: invalid node: %v", node, node))
+ }
+}
+
+func (self *Trie) get(node Node, key []byte) Node {
+ if len(key) == 0 {
+ return node
+ }
+
+ if node == nil {
+ return nil
+ }
+
+ switch node := node.(type) {
+ case *ShortNode:
+ k := node.Key()
+ cnode := node.Value()
+
+ if len(key) >= len(k) && bytes.Equal(k, key[:len(k)]) {
+ return self.get(cnode, key[len(k):])
+ }
+
+ return nil
+ case *FullNode:
+ return self.get(node.branch(key[0]), key[1:])
+ default:
+ panic(fmt.Sprintf("%T: invalid node: %v", node, node))
+ }
+}
+
+func (self *Trie) delete(node Node, key []byte) Node {
+ if len(key) == 0 && node == nil {
+ return nil
+ }
+
+ switch node := node.(type) {
+ case *ShortNode:
+ k := node.Key()
+ cnode := node.Value()
+ if bytes.Equal(key, k) {
+ return nil
+ } else if bytes.Equal(key[:len(k)], k) {
+ child := self.delete(cnode, key[len(k):])
+
+ var n Node
+ switch child := child.(type) {
+ case *ShortNode:
+ nkey := append(k, child.Key()...)
+ n = NewShortNode(self, nkey, child.Value())
+ case *FullNode:
+ sn := NewShortNode(self, node.Key(), child)
+ sn.key = node.key
+ n = sn
+ }
+
+ return n
+ } else {
+ return node
+ }
+
+ case *FullNode:
+ n := node.Copy(self).(*FullNode)
+ n.set(key[0], self.delete(n.branch(key[0]), key[1:]))
+
+ pos := -1
+ for i := 0; i < 17; i++ {
+ if n.branch(byte(i)) != nil {
+ if pos == -1 {
+ pos = i
+ } else {
+ pos = -2
+ }
+ }
+ }
+
+ var nnode Node
+ if pos == 16 {
+ nnode = NewShortNode(self, []byte{16}, n.branch(byte(pos)))
+ } else if pos >= 0 {
+ cnode := n.branch(byte(pos))
+ switch cnode := cnode.(type) {
+ case *ShortNode:
+ // Stitch keys
+ k := append([]byte{byte(pos)}, cnode.Key()...)
+ nnode = NewShortNode(self, k, cnode.Value())
+ case *FullNode:
+ nnode = NewShortNode(self, []byte{byte(pos)}, n.branch(byte(pos)))
+ }
+ } else {
+ nnode = n
+ }
+
+ return nnode
+ case nil:
+ return nil
+ default:
+ panic(fmt.Sprintf("%T: invalid node: %v (%v)", node, node, key))
+ }
+}
+
+// casting functions and cache storing
+func (self *Trie) mknode(value *common.Value) Node {
+ l := value.Len()
+ switch l {
+ case 0:
+ return nil
+ case 2:
+ // A value node may consists of 2 bytes.
+ if value.Get(0).Len() != 0 {
+ key := CompactDecode(string(value.Get(0).Bytes()))
+ if key[len(key)-1] == 16 {
+ return NewShortNode(self, key, &ValueNode{self, value.Get(1).Bytes()})
+ } else {
+ return NewShortNode(self, key, self.mknode(value.Get(1)))
+ }
+ }
+ case 17:
+ if len(value.Bytes()) != 17 {
+ fnode := NewFullNode(self)
+ for i := 0; i < 16; i++ {
+ fnode.set(byte(i), self.mknode(value.Get(i)))
+ }
+ return fnode
+ }
+ case 32:
+ return &HashNode{value.Bytes(), self}
+ }
+
+ return &ValueNode{self, value.Bytes()}
+}
+
+func (self *Trie) trans(node Node) Node {
+ switch node := node.(type) {
+ case *HashNode:
+ value := common.NewValueFromBytes(self.cache.Get(node.key))
+ return self.mknode(value)
+ default:
+ return node
+ }
+}
+
+func (self *Trie) store(node Node) interface{} {
+ data := common.Encode(node)
+ if len(data) >= 32 {
+ key := crypto.Sha3(data)
+ self.cache.Put(key, data)
+
+ return key
+ }
+
+ return node.RlpData()
+}
+
+func (self *Trie) PrintRoot() {
+ fmt.Println(self.root)
+ fmt.Printf("root=%x\n", self.Root())
+}
diff --git a/trie/trie_test.go b/trie/trie_test.go
new file mode 100644
index 000000000..16311aadf
--- /dev/null
+++ b/trie/trie_test.go
@@ -0,0 +1,338 @@
+package trie
+
+import (
+ "bytes"
+ "fmt"
+ "testing"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/crypto"
+)
+
+type Db map[string][]byte
+
+func (self Db) Get(k []byte) ([]byte, error) { return self[string(k)], nil }
+func (self Db) Put(k, v []byte) { self[string(k)] = v }
+
+// Used for testing
+func NewEmpty() *Trie {
+ return New(nil, make(Db))
+}
+
+func NewEmptySecure() *SecureTrie {
+ return NewSecure(nil, make(Db))
+}
+
+func TestEmptyTrie(t *testing.T) {
+ trie := NewEmpty()
+ res := trie.Hash()
+ exp := crypto.Sha3(common.Encode(""))
+ if !bytes.Equal(res, exp) {
+ t.Errorf("expected %x got %x", exp, res)
+ }
+}
+
+func TestNull(t *testing.T) {
+ trie := NewEmpty()
+
+ key := make([]byte, 32)
+ value := common.FromHex("0x823140710bf13990e4500136726d8b55")
+ trie.Update(key, value)
+ value = trie.Get(key)
+}
+
+func TestInsert(t *testing.T) {
+ trie := NewEmpty()
+
+ trie.UpdateString("doe", "reindeer")
+ trie.UpdateString("dog", "puppy")
+ trie.UpdateString("dogglesworth", "cat")
+
+ exp := common.Hex2Bytes("8aad789dff2f538bca5d8ea56e8abe10f4c7ba3a5dea95fea4cd6e7c3a1168d3")
+ root := trie.Hash()
+ if !bytes.Equal(root, exp) {
+ t.Errorf("exp %x got %x", exp, root)
+ }
+
+ trie = NewEmpty()
+ trie.UpdateString("A", "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa")
+
+ exp = common.Hex2Bytes("d23786fb4a010da3ce639d66d5e904a11dbc02746d1ce25029e53290cabf28ab")
+ root = trie.Hash()
+ if !bytes.Equal(root, exp) {
+ t.Errorf("exp %x got %x", exp, root)
+ }
+}
+
+func TestGet(t *testing.T) {
+ trie := NewEmpty()
+
+ trie.UpdateString("doe", "reindeer")
+ trie.UpdateString("dog", "puppy")
+ trie.UpdateString("dogglesworth", "cat")
+
+ res := trie.GetString("dog")
+ if !bytes.Equal(res, []byte("puppy")) {
+ t.Errorf("expected puppy got %x", res)
+ }
+
+ unknown := trie.GetString("unknown")
+ if unknown != nil {
+ t.Errorf("expected nil got %x", unknown)
+ }
+}
+
+func TestDelete(t *testing.T) {
+ trie := NewEmpty()
+
+ vals := []struct{ k, v string }{
+ {"do", "verb"},
+ {"ether", "wookiedoo"},
+ {"horse", "stallion"},
+ {"shaman", "horse"},
+ {"doge", "coin"},
+ {"ether", ""},
+ {"dog", "puppy"},
+ {"shaman", ""},
+ }
+ for _, val := range vals {
+ if val.v != "" {
+ trie.UpdateString(val.k, val.v)
+ } else {
+ trie.DeleteString(val.k)
+ }
+ }
+
+ hash := trie.Hash()
+ exp := common.Hex2Bytes("5991bb8c6514148a29db676a14ac506cd2cd5775ace63c30a4fe457715e9ac84")
+ if !bytes.Equal(hash, exp) {
+ t.Errorf("expected %x got %x", exp, hash)
+ }
+}
+
+func TestEmptyValues(t *testing.T) {
+ trie := NewEmpty()
+
+ vals := []struct{ k, v string }{
+ {"do", "verb"},
+ {"ether", "wookiedoo"},
+ {"horse", "stallion"},
+ {"shaman", "horse"},
+ {"doge", "coin"},
+ {"ether", ""},
+ {"dog", "puppy"},
+ {"shaman", ""},
+ }
+ for _, val := range vals {
+ trie.UpdateString(val.k, val.v)
+ }
+
+ hash := trie.Hash()
+ exp := common.Hex2Bytes("5991bb8c6514148a29db676a14ac506cd2cd5775ace63c30a4fe457715e9ac84")
+ if !bytes.Equal(hash, exp) {
+ t.Errorf("expected %x got %x", exp, hash)
+ }
+}
+
+func TestReplication(t *testing.T) {
+ trie := NewEmpty()
+ vals := []struct{ k, v string }{
+ {"do", "verb"},
+ {"ether", "wookiedoo"},
+ {"horse", "stallion"},
+ {"shaman", "horse"},
+ {"doge", "coin"},
+ {"ether", ""},
+ {"dog", "puppy"},
+ {"shaman", ""},
+ {"somethingveryoddindeedthis is", "myothernodedata"},
+ }
+ for _, val := range vals {
+ trie.UpdateString(val.k, val.v)
+ }
+ trie.Commit()
+
+ trie2 := New(trie.roothash, trie.cache.backend)
+ if string(trie2.GetString("horse")) != "stallion" {
+ t.Error("expected to have horse => stallion")
+ }
+
+ hash := trie2.Hash()
+ exp := trie.Hash()
+ if !bytes.Equal(hash, exp) {
+ t.Errorf("root failure. expected %x got %x", exp, hash)
+ }
+
+}
+
+func TestReset(t *testing.T) {
+ trie := NewEmpty()
+ vals := []struct{ k, v string }{
+ {"do", "verb"},
+ {"ether", "wookiedoo"},
+ {"horse", "stallion"},
+ }
+ for _, val := range vals {
+ trie.UpdateString(val.k, val.v)
+ }
+ trie.Commit()
+
+ before := common.CopyBytes(trie.roothash)
+ trie.UpdateString("should", "revert")
+ trie.Hash()
+ // Should have no effect
+ trie.Hash()
+ trie.Hash()
+ // ###
+
+ trie.Reset()
+ after := common.CopyBytes(trie.roothash)
+
+ if !bytes.Equal(before, after) {
+ t.Errorf("expected roots to be equal. %x - %x", before, after)
+ }
+}
+
+func TestParanoia(t *testing.T) {
+ t.Skip()
+ trie := NewEmpty()
+
+ vals := []struct{ k, v string }{
+ {"do", "verb"},
+ {"ether", "wookiedoo"},
+ {"horse", "stallion"},
+ {"shaman", "horse"},
+ {"doge", "coin"},
+ {"ether", ""},
+ {"dog", "puppy"},
+ {"shaman", ""},
+ {"somethingveryoddindeedthis is", "myothernodedata"},
+ }
+ for _, val := range vals {
+ trie.UpdateString(val.k, val.v)
+ }
+ trie.Commit()
+
+ ok, t2 := ParanoiaCheck(trie, trie.cache.backend)
+ if !ok {
+ t.Errorf("trie paranoia check failed %x %x", trie.roothash, t2.roothash)
+ }
+}
+
+// Not an actual test
+func TestOutput(t *testing.T) {
+ t.Skip()
+
+ base := "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"
+ trie := NewEmpty()
+ for i := 0; i < 50; i++ {
+ trie.UpdateString(fmt.Sprintf("%s%d", base, i), "valueeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee")
+ }
+ fmt.Println("############################## FULL ################################")
+ fmt.Println(trie.root)
+
+ trie.Commit()
+ fmt.Println("############################## SMALL ################################")
+ trie2 := New(trie.roothash, trie.cache.backend)
+ trie2.GetString(base + "20")
+ fmt.Println(trie2.root)
+}
+
+func BenchmarkGets(b *testing.B) {
+ trie := NewEmpty()
+ vals := []struct{ k, v string }{
+ {"do", "verb"},
+ {"ether", "wookiedoo"},
+ {"horse", "stallion"},
+ {"shaman", "horse"},
+ {"doge", "coin"},
+ {"ether", ""},
+ {"dog", "puppy"},
+ {"shaman", ""},
+ {"somethingveryoddindeedthis is", "myothernodedata"},
+ }
+ for _, val := range vals {
+ trie.UpdateString(val.k, val.v)
+ }
+
+ b.ResetTimer()
+ for i := 0; i < b.N; i++ {
+ trie.Get([]byte("horse"))
+ }
+}
+
+func BenchmarkUpdate(b *testing.B) {
+ trie := NewEmpty()
+
+ b.ResetTimer()
+ for i := 0; i < b.N; i++ {
+ trie.UpdateString(fmt.Sprintf("aaaaaaaaa%d", i), "value")
+ }
+ trie.Hash()
+}
+
+type kv struct {
+ k, v []byte
+ t bool
+}
+
+func TestLargeData(t *testing.T) {
+ trie := NewEmpty()
+ vals := make(map[string]*kv)
+
+ for i := byte(0); i < 255; i++ {
+ value := &kv{common.LeftPadBytes([]byte{i}, 32), []byte{i}, false}
+ value2 := &kv{common.LeftPadBytes([]byte{10, i}, 32), []byte{i}, false}
+ trie.Update(value.k, value.v)
+ trie.Update(value2.k, value2.v)
+ vals[string(value.k)] = value
+ vals[string(value2.k)] = value2
+ }
+
+ it := trie.Iterator()
+ for it.Next() {
+ vals[string(it.Key)].t = true
+ }
+
+ var untouched []*kv
+ for _, value := range vals {
+ if !value.t {
+ untouched = append(untouched, value)
+ }
+ }
+
+ if len(untouched) > 0 {
+ t.Errorf("Missed %d nodes", len(untouched))
+ for _, value := range untouched {
+ t.Error(value)
+ }
+ }
+}
+
+func TestSecureDelete(t *testing.T) {
+ trie := NewEmptySecure()
+
+ vals := []struct{ k, v string }{
+ {"do", "verb"},
+ {"ether", "wookiedoo"},
+ {"horse", "stallion"},
+ {"shaman", "horse"},
+ {"doge", "coin"},
+ {"ether", ""},
+ {"dog", "puppy"},
+ {"shaman", ""},
+ }
+ for _, val := range vals {
+ if val.v != "" {
+ trie.UpdateString(val.k, val.v)
+ } else {
+ trie.DeleteString(val.k)
+ }
+ }
+
+ hash := trie.Hash()
+ exp := common.Hex2Bytes("29b235a58c3c25ab83010c327d5932bcf05324b7d6b1185e650798034783ca9d")
+ if !bytes.Equal(hash, exp) {
+ t.Errorf("expected %x got %x", exp, hash)
+ }
+}
diff --git a/trie/valuenode.go b/trie/valuenode.go
new file mode 100644
index 000000000..7bf8ff06e
--- /dev/null
+++ b/trie/valuenode.go
@@ -0,0 +1,15 @@
+package trie
+
+import "github.com/ethereum/go-ethereum/common"
+
+type ValueNode struct {
+ trie *Trie
+ data []byte
+}
+
+func (self *ValueNode) Value() Node { return self } // Best not to call :-)
+func (self *ValueNode) Val() []byte { return self.data }
+func (self *ValueNode) Dirty() bool { return true }
+func (self *ValueNode) Copy(t *Trie) Node { return &ValueNode{t, common.CopyBytes(self.data)} }
+func (self *ValueNode) RlpData() interface{} { return self.data }
+func (self *ValueNode) Hash() interface{} { return self.data }
diff --git a/ui/filter.go b/ui/filter.go
new file mode 100644
index 000000000..5b1faa293
--- /dev/null
+++ b/ui/filter.go
@@ -0,0 +1 @@
+package ui
diff --git a/ui/qt/filter.go b/ui/qt/filter.go
new file mode 100644
index 000000000..090260e4e
--- /dev/null
+++ b/ui/qt/filter.go
@@ -0,0 +1 @@
+package qt
diff --git a/ui/qt/qwhisper/message.go b/ui/qt/qwhisper/message.go
new file mode 100644
index 000000000..f8bed8a2d
--- /dev/null
+++ b/ui/qt/qwhisper/message.go
@@ -0,0 +1,23 @@
+package qwhisper
+
+import (
+ "github.com/ethereum/go-ethereum/crypto"
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/whisper"
+)
+
+type Message struct {
+ ref *whisper.Message
+ Flags int32 `json:"flags"`
+ Payload string `json:"payload"`
+ From string `json:"from"`
+}
+
+func ToQMessage(msg *whisper.Message) *Message {
+ return &Message{
+ ref: msg,
+ Flags: int32(msg.Flags),
+ Payload: "0x" + common.Bytes2Hex(msg.Payload),
+ From: "0x" + common.Bytes2Hex(crypto.FromECDSAPub(msg.Recover())),
+ }
+}
diff --git a/ui/qt/qwhisper/watch.go b/ui/qt/qwhisper/watch.go
new file mode 100644
index 000000000..0ccedc719
--- /dev/null
+++ b/ui/qt/qwhisper/watch.go
@@ -0,0 +1,13 @@
+package qwhisper
+
+import (
+ "fmt"
+ "unsafe"
+)
+
+type Watch struct {
+}
+
+func (self *Watch) Arrived(v unsafe.Pointer) {
+ fmt.Println(v)
+}
diff --git a/ui/qt/qwhisper/whisper.go b/ui/qt/qwhisper/whisper.go
new file mode 100644
index 000000000..bf165bbcc
--- /dev/null
+++ b/ui/qt/qwhisper/whisper.go
@@ -0,0 +1,113 @@
+// QWhisper package. This package is temporarily on hold until QML DApp dev will reemerge.
+package qwhisper
+
+import (
+ "time"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/crypto"
+ "github.com/ethereum/go-ethereum/logger"
+ "github.com/ethereum/go-ethereum/whisper"
+ "github.com/obscuren/qml"
+)
+
+var qlogger = logger.NewLogger("QSHH")
+
+type Whisper struct {
+ *whisper.Whisper
+ view qml.Object
+
+ watches map[int]*Watch
+}
+
+func New(w *whisper.Whisper) *Whisper {
+ return &Whisper{w, nil, make(map[int]*Watch)}
+}
+
+func (self *Whisper) SetView(view qml.Object) {
+ self.view = view
+}
+
+func (self *Whisper) Post(payload []string, to, from string, topics []string, priority, ttl uint32) {
+ var data []byte
+ for _, d := range payload {
+ data = append(data, common.FromHex(d)...)
+ }
+
+ pk := crypto.ToECDSAPub(common.FromHex(from))
+ if key := self.Whisper.GetIdentity(pk); key != nil {
+ msg := whisper.NewMessage(data)
+ envelope, err := msg.Seal(time.Duration(priority*100000), whisper.Opts{
+ Ttl: time.Duration(ttl) * time.Second,
+ To: crypto.ToECDSAPub(common.FromHex(to)),
+ From: key,
+ Topics: whisper.TopicsFromString(topics...),
+ })
+
+ if err != nil {
+ qlogger.Infoln(err)
+ // handle error
+ return
+ }
+
+ if err := self.Whisper.Send(envelope); err != nil {
+ qlogger.Infoln(err)
+ // handle error
+ return
+ }
+ } else {
+ qlogger.Infoln("unmatched pub / priv for seal")
+ }
+
+}
+
+func (self *Whisper) NewIdentity() string {
+ key := self.Whisper.NewIdentity()
+
+ return common.ToHex(crypto.FromECDSAPub(&key.PublicKey))
+}
+
+func (self *Whisper) HasIdentity(key string) bool {
+ return self.Whisper.HasIdentity(crypto.ToECDSAPub(common.FromHex(key)))
+}
+
+func (self *Whisper) Watch(opts map[string]interface{}, view *qml.Common) int {
+ filter := filterFromMap(opts)
+ var i int
+ filter.Fn = func(msg *whisper.Message) {
+ if view != nil {
+ view.Call("onShhMessage", ToQMessage(msg), i)
+ }
+ }
+
+ i = self.Whisper.Watch(filter)
+ self.watches[i] = &Watch{}
+
+ return i
+}
+
+func (self *Whisper) Messages(id int) (messages *common.List) {
+ msgs := self.Whisper.Messages(id)
+ messages = common.EmptyList()
+ for _, message := range msgs {
+ messages.Append(ToQMessage(message))
+ }
+
+ return
+}
+
+func filterFromMap(opts map[string]interface{}) (f whisper.Filter) {
+ if to, ok := opts["to"].(string); ok {
+ f.To = crypto.ToECDSAPub(common.FromHex(to))
+ }
+ if from, ok := opts["from"].(string); ok {
+ f.From = crypto.ToECDSAPub(common.FromHex(from))
+ }
+ if topicList, ok := opts["topics"].(*qml.List); ok {
+ var topics []string
+ topicList.Convert(&topics)
+ f.Topics = whisper.TopicsFromString(topics...)
+ }
+
+ return
+}
diff --git a/ui/qt/qwhisper/whisper_test.go b/ui/qt/qwhisper/whisper_test.go
new file mode 100644
index 000000000..efa4e6238
--- /dev/null
+++ b/ui/qt/qwhisper/whisper_test.go
@@ -0,0 +1,15 @@
+package qwhisper
+
+import (
+ "testing"
+
+ "github.com/ethereum/go-ethereum/whisper"
+)
+
+func TestHasIdentity(t *testing.T) {
+ qw := New(whisper.New())
+ id := qw.NewIdentity()
+ if !qw.HasIdentity(id) {
+ t.Error("expected to have identity")
+ }
+}
diff --git a/ui/qt/webengine/all.cpp b/ui/qt/webengine/all.cpp
new file mode 100644
index 000000000..3b7c2f7b8
--- /dev/null
+++ b/ui/qt/webengine/all.cpp
@@ -0,0 +1 @@
+#include "cpp/webengine.cpp"
diff --git a/ui/qt/webengine/cpp/webengine.cpp b/ui/qt/webengine/cpp/webengine.cpp
new file mode 100644
index 000000000..118b451ef
--- /dev/null
+++ b/ui/qt/webengine/cpp/webengine.cpp
@@ -0,0 +1,6 @@
+#include <QtWebEngine>
+#include "webengine.h"
+
+void webengineInitialize() {
+ QtWebEngine::initialize();
+}
diff --git a/ui/qt/webengine/cpp/webengine.h b/ui/qt/webengine/cpp/webengine.h
new file mode 100644
index 000000000..9c3b13bfa
--- /dev/null
+++ b/ui/qt/webengine/cpp/webengine.h
@@ -0,0 +1,14 @@
+#ifndef WEBENGINE_H
+#define WEBENGINE_H
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+void webengineInitialize();
+
+#ifdef __cplusplus
+} // extern "C"
+#endif
+
+#endif // WEBENGINE_H
diff --git a/ui/qt/webengine/webengine.go b/ui/qt/webengine/webengine.go
new file mode 100644
index 000000000..600dbb6cb
--- /dev/null
+++ b/ui/qt/webengine/webengine.go
@@ -0,0 +1,18 @@
+package webengine
+
+// #cgo CPPFLAGS: -I./
+// #cgo CXXFLAGS: -std=c++0x -pedantic-errors -Wall -fno-strict-aliasing
+// #cgo LDFLAGS: -lstdc++
+// #cgo pkg-config: Qt5WebEngine
+//
+// #include "cpp/webengine.h"
+import "C"
+
+import "github.com/obscuren/qml"
+
+// Initializes the WebEngine extension.
+func Initialize() {
+ qml.RunMain(func() {
+ C.webengineInitialize()
+ })
+}
diff --git a/update-license.go b/update-license.go
new file mode 100644
index 000000000..e55732a53
--- /dev/null
+++ b/update-license.go
@@ -0,0 +1,248 @@
+// +build none
+
+/*
+This command generates GPL license headers on top of all source files.
+You can run it once per month, before cutting a release or just
+whenever you feel like it.
+
+ go run update-license.go
+
+The copyright in each file is assigned to any authors for which git
+can find commits in the file's history. It will try to follow renames
+throughout history. The author names are mapped and deduplicated using
+the .mailmap file. You can use .mailmap to set the canonical name and
+address for each author. See git-shortlog(1) for an explanation
+of the .mailmap format.
+
+Please review the resulting diff to check whether the correct
+copyright assignments are performed.
+*/
+package main
+
+import (
+ "bufio"
+ "bytes"
+ "fmt"
+ "io/ioutil"
+ "os"
+ "os/exec"
+ "path"
+ "regexp"
+ "runtime"
+ "sort"
+ "strings"
+ "sync"
+ "text/template"
+)
+
+var (
+ // only files with these extensions will be considered
+ extensions = []string{".go", ".js", ".qml"}
+
+ // paths with any of these prefixes will be skipped
+ skipPrefixes = []string{"Godeps/", "tests/files/", "cmd/mist/assets/ext/", "cmd/mist/assets/muted/"}
+
+ // paths with this prefix are licensed as GPL. all other files are LGPL.
+ gplPrefixes = []string{"cmd/"}
+
+ // this regexp must match the entire license comment at the
+ // beginning of each file.
+ licenseCommentRE = regexp.MustCompile(`(?s)^/\*\s*(Copyright|This file is part of) .*?\*/\n*`)
+
+ // this line is used when git doesn't find any authors for a file
+ defaultCopyright = "Copyright (C) 2014 Jeffrey Wilcke <jeffrey@ethereum.org>"
+)
+
+// this template generates the license comment.
+// its input is an info structure.
+var licenseT = template.Must(template.New("").Parse(`/*
+ {{.Copyrights}}
+
+ This file is part of go-ethereum
+
+ go-ethereum is free software: you can redistribute it and/or modify
+ it under the terms of the GNU {{.License}} as published by
+ the Free Software Foundation, either version 3 of the License, or
+ (at your option) any later version.
+
+ go-ethereum is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU {{.License}} for more details.
+
+ You should have received a copy of the GNU {{.License}}
+ along with go-ethereum. If not, see <http://www.gnu.org/licenses/>.
+*/
+
+`))
+
+type info struct {
+ file string
+ mode os.FileMode
+ authors map[string][]string // map keys are authors, values are years
+ gpl bool
+}
+
+func (i info) Copyrights() string {
+ var lines []string
+ for name, years := range i.authors {
+ lines = append(lines, "Copyright (C) "+strings.Join(years, ", ")+" "+name)
+ }
+ if len(lines) == 0 {
+ lines = []string{defaultCopyright}
+ }
+ sort.Strings(lines)
+ return strings.Join(lines, "\n\t")
+}
+
+func (i info) License() string {
+ if i.gpl {
+ return "General Public License"
+ } else {
+ return "Lesser General Public License"
+ }
+}
+
+func (i info) ShortLicense() string {
+ if i.gpl {
+ return "GPL"
+ } else {
+ return "LGPL"
+ }
+}
+
+func (i *info) addAuthorYear(name, year string) {
+ for _, y := range i.authors[name] {
+ if y == year {
+ return
+ }
+ }
+ i.authors[name] = append(i.authors[name], year)
+ sort.Strings(i.authors[name])
+}
+
+func main() {
+ files := make(chan string)
+ infos := make(chan *info)
+ wg := new(sync.WaitGroup)
+
+ go getFiles(files)
+ for i := runtime.NumCPU(); i >= 0; i-- {
+ // getting file info is slow and needs to be parallel
+ wg.Add(1)
+ go getInfo(files, infos, wg)
+ }
+ go func() { wg.Wait(); close(infos) }()
+ writeLicenses(infos)
+}
+
+func getFiles(out chan<- string) {
+ cmd := exec.Command("git", "ls-tree", "-r", "--name-only", "HEAD")
+ err := doLines(cmd, func(line string) {
+ for _, p := range skipPrefixes {
+ if strings.HasPrefix(line, p) {
+ return
+ }
+ }
+ ext := path.Ext(line)
+ for _, wantExt := range extensions {
+ if ext == wantExt {
+ goto send
+ }
+ }
+ return
+
+ send:
+ out <- line
+ })
+ if err != nil {
+ fmt.Println("error getting files:", err)
+ }
+ close(out)
+}
+
+func getInfo(files <-chan string, out chan<- *info, wg *sync.WaitGroup) {
+ for file := range files {
+ stat, err := os.Lstat(file)
+ if err != nil {
+ fmt.Printf("ERROR %s: %v\n", file, err)
+ continue
+ }
+ if !stat.Mode().IsRegular() {
+ continue
+ }
+ info, err := fileInfo(file)
+ if err != nil {
+ fmt.Printf("ERROR %s: %v\n", file, err)
+ continue
+ }
+ info.mode = stat.Mode()
+ out <- info
+ }
+ wg.Done()
+}
+
+func fileInfo(file string) (*info, error) {
+ info := &info{file: file, authors: make(map[string][]string)}
+ for _, p := range gplPrefixes {
+ if strings.HasPrefix(file, p) {
+ info.gpl = true
+ break
+ }
+ }
+ cmd := exec.Command("git", "log", "--follow", "--find-copies", "--pretty=format:%ai | %aN <%aE>", "--", file)
+ err := doLines(cmd, func(line string) {
+ sep := strings.IndexByte(line, '|')
+ year, name := line[:4], line[sep+2:]
+ info.addAuthorYear(name, year)
+ })
+ return info, err
+}
+
+func writeLicenses(infos <-chan *info) {
+ buf := new(bytes.Buffer)
+ for info := range infos {
+ content, err := ioutil.ReadFile(info.file)
+ if err != nil {
+ fmt.Printf("ERROR: couldn't read %s: %v\n", info.file, err)
+ continue
+ }
+
+ // construct new file content
+ buf.Reset()
+ licenseT.Execute(buf, info)
+ if m := licenseCommentRE.FindIndex(content); m != nil && m[0] == 0 {
+ buf.Write(content[m[1]:])
+ } else {
+ buf.Write(content)
+ }
+
+ if !bytes.Equal(content, buf.Bytes()) {
+ fmt.Println("writing", info.ShortLicense(), info.file)
+ if err := ioutil.WriteFile(info.file, buf.Bytes(), info.mode); err != nil {
+ fmt.Printf("ERROR: couldn't write %s: %v", info.file, err)
+ }
+ }
+ }
+}
+
+func doLines(cmd *exec.Cmd, f func(string)) error {
+ stdout, err := cmd.StdoutPipe()
+ if err != nil {
+ return err
+ }
+ if err := cmd.Start(); err != nil {
+ return err
+ }
+ s := bufio.NewScanner(stdout)
+ for s.Scan() {
+ f(s.Text())
+ }
+ if s.Err() != nil {
+ return s.Err()
+ }
+ if err := cmd.Wait(); err != nil {
+ return fmt.Errorf("%v (for %s)", err, strings.Join(cmd.Args, " "))
+ }
+ return nil
+}
diff --git a/whisper/doc.go b/whisper/doc.go
new file mode 100644
index 000000000..986df8fb9
--- /dev/null
+++ b/whisper/doc.go
@@ -0,0 +1,16 @@
+/*
+Package whisper implements the Whisper PoC-1.
+
+(https://github.com/ethereum/wiki/wiki/Whisper-PoC-1-Protocol-Spec)
+
+Whisper combines aspects of both DHTs and datagram messaging systems (e.g. UDP).
+As such it may be likened and compared to both, not dissimilar to the
+matter/energy duality (apologies to physicists for the blatant abuse of a
+fundamental and beautiful natural principle).
+
+Whisper is a pure identity-based messaging system. Whisper provides a low-level
+(non-application-specific) but easily-accessible API without being based upon
+or prejudiced by the low-level hardware attributes and characteristics,
+particularly the notion of singular endpoints.
+*/
+package whisper
diff --git a/whisper/envelope.go b/whisper/envelope.go
new file mode 100644
index 000000000..20e3e6d39
--- /dev/null
+++ b/whisper/envelope.go
@@ -0,0 +1,129 @@
+package whisper
+
+import (
+ "crypto/ecdsa"
+ "encoding/binary"
+ "fmt"
+ "time"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/crypto"
+ "github.com/ethereum/go-ethereum/crypto/ecies"
+ "github.com/ethereum/go-ethereum/rlp"
+)
+
+const (
+ DefaultPow = 50 * time.Millisecond
+)
+
+type Envelope struct {
+ Expiry uint32 // Whisper protocol specifies int32, really should be int64
+ TTL uint32 // ^^^^^^
+ Topics [][]byte
+ Data []byte
+ Nonce uint32
+
+ hash common.Hash
+}
+
+func (self *Envelope) Hash() common.Hash {
+ if (self.hash == common.Hash{}) {
+ enc, _ := rlp.EncodeToBytes(self)
+ self.hash = crypto.Sha3Hash(enc)
+ }
+ return self.hash
+}
+
+func NewEnvelope(ttl time.Duration, topics [][]byte, data *Message) *Envelope {
+ exp := time.Now().Add(ttl)
+ return &Envelope{
+ Expiry: uint32(exp.Unix()),
+ TTL: uint32(ttl.Seconds()),
+ Topics: topics,
+ Data: data.Bytes(),
+ Nonce: 0,
+ }
+}
+
+func (self *Envelope) Seal(pow time.Duration) {
+ self.proveWork(pow)
+}
+
+func (self *Envelope) Open(prv *ecdsa.PrivateKey) (msg *Message, err error) {
+ data := self.Data
+ var message Message
+ dataStart := 1
+ if data[0] > 0 {
+ if len(data) < 66 {
+ return nil, fmt.Errorf("unable to open envelope. First bit set but len(data) < 66")
+ }
+ dataStart = 66
+ message.Flags = data[0]
+ message.Signature = data[1:66]
+ }
+
+ payload := data[dataStart:]
+ if prv != nil {
+ message.Payload, err = crypto.Decrypt(prv, payload)
+ switch err {
+ case nil: // OK
+ case ecies.ErrInvalidPublicKey: // Payload isn't encrypted
+ message.Payload = payload
+ return &message, err
+ default:
+ return nil, fmt.Errorf("unable to open envelope. Decrypt failed: %v", err)
+ }
+ }
+
+ return &message, nil
+}
+
+func (self *Envelope) proveWork(dura time.Duration) {
+ var bestBit int
+ d := make([]byte, 64)
+ enc, _ := rlp.EncodeToBytes(self.withoutNonce())
+ copy(d[:32], enc)
+
+ then := time.Now().Add(dura).UnixNano()
+ for n := uint32(0); time.Now().UnixNano() < then; {
+ for i := 0; i < 1024; i++ {
+ binary.BigEndian.PutUint32(d[60:], n)
+
+ fbs := common.FirstBitSet(common.BigD(crypto.Sha3(d)))
+ if fbs > bestBit {
+ bestBit = fbs
+ self.Nonce = n
+ }
+
+ n++
+ }
+ }
+}
+
+func (self *Envelope) valid() bool {
+ d := make([]byte, 64)
+ enc, _ := rlp.EncodeToBytes(self.withoutNonce())
+ copy(d[:32], enc)
+ binary.BigEndian.PutUint32(d[60:], self.Nonce)
+ return common.FirstBitSet(common.BigD(crypto.Sha3(d))) > 0
+}
+
+func (self *Envelope) withoutNonce() interface{} {
+ return []interface{}{self.Expiry, self.TTL, self.Topics, self.Data}
+}
+
+// rlpenv is an Envelope but is not an rlp.Decoder.
+// It is used for decoding because we need to
+type rlpenv Envelope
+
+func (self *Envelope) DecodeRLP(s *rlp.Stream) error {
+ raw, err := s.Raw()
+ if err != nil {
+ return err
+ }
+ if err := rlp.DecodeBytes(raw, (*rlpenv)(self)); err != nil {
+ return err
+ }
+ self.hash = crypto.Sha3Hash(raw)
+ return nil
+}
diff --git a/whisper/filter.go b/whisper/filter.go
new file mode 100644
index 000000000..b33f2c1a2
--- /dev/null
+++ b/whisper/filter.go
@@ -0,0 +1,10 @@
+package whisper
+
+import "crypto/ecdsa"
+
+type Filter struct {
+ To *ecdsa.PublicKey
+ From *ecdsa.PublicKey
+ Topics [][]byte
+ Fn func(*Message)
+}
diff --git a/whisper/main.go b/whisper/main.go
new file mode 100644
index 000000000..9f35dbb8d
--- /dev/null
+++ b/whisper/main.go
@@ -0,0 +1,37 @@
+// +build none
+
+package main
+
+import (
+ "fmt"
+ "log"
+ "os"
+
+ "github.com/ethereum/go-ethereum/crypto/secp256k1"
+ "github.com/ethereum/go-ethereum/logger"
+ "github.com/ethereum/go-ethereum/p2p"
+ "github.com/ethereum/go-ethereum/whisper"
+)
+
+func main() {
+ logger.AddLogSystem(logger.NewStdLogSystem(os.Stdout, log.LstdFlags, logger.InfoLevel))
+
+ pub, _ := secp256k1.GenerateKeyPair()
+
+ whisper := whisper.New()
+
+ srv := p2p.Server{
+ MaxPeers: 10,
+ Identity: p2p.NewSimpleClientIdentity("whisper-go", "1.0", "", string(pub)),
+ ListenAddr: ":30300",
+ NAT: p2p.UPNP(),
+
+ Protocols: []p2p.Protocol{whisper.Protocol()},
+ }
+ if err := srv.Start(); err != nil {
+ fmt.Println("could not start server:", err)
+ os.Exit(1)
+ }
+
+ select {}
+}
diff --git a/whisper/message.go b/whisper/message.go
new file mode 100644
index 000000000..5d9e5b5c1
--- /dev/null
+++ b/whisper/message.go
@@ -0,0 +1,81 @@
+package whisper
+
+import (
+ "crypto/ecdsa"
+ "time"
+
+ "github.com/ethereum/go-ethereum/crypto"
+)
+
+type Message struct {
+ Flags byte
+ Signature []byte
+ Payload []byte
+ Sent int64
+
+ To *ecdsa.PublicKey
+}
+
+func NewMessage(payload []byte) *Message {
+ return &Message{Flags: 0, Payload: payload, Sent: time.Now().Unix()}
+}
+
+func (self *Message) hash() []byte {
+ return crypto.Sha3(append([]byte{self.Flags}, self.Payload...))
+}
+
+func (self *Message) sign(key *ecdsa.PrivateKey) (err error) {
+ self.Flags = 1
+ self.Signature, err = crypto.Sign(self.hash(), key)
+ return
+}
+
+func (self *Message) Recover() *ecdsa.PublicKey {
+ defer func() { recover() }() // in case of invalid sig
+ return crypto.SigToPub(self.hash(), self.Signature)
+}
+
+func (self *Message) Encrypt(to *ecdsa.PublicKey) (err error) {
+ self.Payload, err = crypto.Encrypt(to, self.Payload)
+ if err != nil {
+ return err
+ }
+
+ return nil
+}
+
+func (self *Message) Bytes() []byte {
+ return append([]byte{self.Flags}, append(self.Signature, self.Payload...)...)
+}
+
+type Opts struct {
+ From *ecdsa.PrivateKey
+ To *ecdsa.PublicKey
+ Ttl time.Duration
+ Topics [][]byte
+}
+
+func (self *Message) Seal(pow time.Duration, opts Opts) (*Envelope, error) {
+ if opts.From != nil {
+ err := self.sign(opts.From)
+ if err != nil {
+ return nil, err
+ }
+ }
+
+ if opts.To != nil {
+ err := self.Encrypt(opts.To)
+ if err != nil {
+ return nil, err
+ }
+ }
+
+ if opts.Ttl == 0 {
+ opts.Ttl = DefaultTtl
+ }
+
+ envelope := NewEnvelope(opts.Ttl, opts.Topics, self)
+ envelope.Seal(pow)
+
+ return envelope, nil
+}
diff --git a/whisper/messages_test.go b/whisper/messages_test.go
new file mode 100644
index 000000000..93caa31b3
--- /dev/null
+++ b/whisper/messages_test.go
@@ -0,0 +1,50 @@
+package whisper
+
+import (
+ "bytes"
+ "crypto/elliptic"
+ "fmt"
+ "testing"
+
+ "github.com/ethereum/go-ethereum/crypto"
+)
+
+func TestSign(t *testing.T) {
+ prv, _ := crypto.GenerateKey()
+ msg := NewMessage([]byte("hello world"))
+ msg.sign(prv)
+
+ pubKey := msg.Recover()
+ p1 := elliptic.Marshal(crypto.S256(), prv.PublicKey.X, prv.PublicKey.Y)
+ p2 := elliptic.Marshal(crypto.S256(), pubKey.X, pubKey.Y)
+
+ if !bytes.Equal(p1, p2) {
+ t.Error("recovered pub key did not match")
+ }
+}
+
+func TestMessageEncryptDecrypt(t *testing.T) {
+ prv1, _ := crypto.GenerateKey()
+ prv2, _ := crypto.GenerateKey()
+
+ data := []byte("hello world")
+ msg := NewMessage(data)
+ envelope, err := msg.Seal(DefaultPow, Opts{
+ From: prv1,
+ To: &prv2.PublicKey,
+ })
+ if err != nil {
+ fmt.Println(err)
+ t.FailNow()
+ }
+
+ msg1, err := envelope.Open(prv2)
+ if err != nil {
+ t.Error(err)
+ t.FailNow()
+ }
+
+ if !bytes.Equal(msg1.Payload, data) {
+ t.Error("encryption error. data did not match")
+ }
+}
diff --git a/whisper/peer.go b/whisper/peer.go
new file mode 100644
index 000000000..338166c25
--- /dev/null
+++ b/whisper/peer.go
@@ -0,0 +1,113 @@
+package whisper
+
+import (
+ "fmt"
+ "time"
+
+ "github.com/ethereum/go-ethereum/p2p"
+ "github.com/ethereum/go-ethereum/rlp"
+ "gopkg.in/fatih/set.v0"
+)
+
+const (
+ protocolVersion uint64 = 0x02
+)
+
+type peer struct {
+ host *Whisper
+ peer *p2p.Peer
+ ws p2p.MsgReadWriter
+
+ // XXX Eventually this is going to reach exceptional large space. We need an expiry here
+ known *set.Set
+
+ quit chan struct{}
+}
+
+func NewPeer(host *Whisper, p *p2p.Peer, ws p2p.MsgReadWriter) *peer {
+ return &peer{host, p, ws, set.New(), make(chan struct{})}
+}
+
+func (self *peer) init() error {
+ if err := self.handleStatus(); err != nil {
+ return err
+ }
+
+ return nil
+}
+
+func (self *peer) start() {
+ go self.update()
+ self.peer.Debugln("whisper started")
+}
+
+func (self *peer) stop() {
+ self.peer.Debugln("whisper stopped")
+
+ close(self.quit)
+}
+
+func (self *peer) update() {
+ relay := time.NewTicker(300 * time.Millisecond)
+out:
+ for {
+ select {
+ case <-relay.C:
+ err := self.broadcast(self.host.envelopes())
+ if err != nil {
+ self.peer.Infoln("broadcast err:", err)
+ break out
+ }
+
+ case <-self.quit:
+ break out
+ }
+ }
+}
+
+func (self *peer) broadcast(envelopes []*Envelope) error {
+ envs := make([]*Envelope, 0, len(envelopes))
+ for _, env := range envelopes {
+ if !self.known.Has(env.Hash()) {
+ envs = append(envs, env)
+ self.known.Add(env.Hash())
+ }
+ }
+ if len(envs) > 0 {
+ if err := p2p.Send(self.ws, envelopesMsg, envs); err != nil {
+ return err
+ }
+ self.peer.DebugDetailln("broadcasted", len(envs), "message(s)")
+ }
+ return nil
+}
+
+func (self *peer) addKnown(envelope *Envelope) {
+ self.known.Add(envelope.Hash())
+}
+
+func (self *peer) handleStatus() error {
+ ws := self.ws
+ if err := p2p.SendItems(ws, statusMsg, protocolVersion); err != nil {
+ return err
+ }
+ msg, err := ws.ReadMsg()
+ if err != nil {
+ return err
+ }
+ if msg.Code != statusMsg {
+ return fmt.Errorf("peer send %x before status msg", msg.Code)
+ }
+ s := rlp.NewStream(msg.Payload)
+ if _, err := s.List(); err != nil {
+ return fmt.Errorf("bad status message: %v", err)
+ }
+ pv, err := s.Uint()
+ if err != nil {
+ return fmt.Errorf("bad status message: %v", err)
+ }
+ if pv != protocolVersion {
+ return fmt.Errorf("protocol version mismatch %d != %d", pv, protocolVersion)
+ }
+ return msg.Discard() // ignore anything after protocol version
+}
diff --git a/whisper/sort.go b/whisper/sort.go
new file mode 100644
index 000000000..313ba5ac0
--- /dev/null
+++ b/whisper/sort.go
@@ -0,0 +1,29 @@
+package whisper
+
+import (
+ "sort"
+
+ "github.com/ethereum/go-ethereum/common"
+)
+
+type sortedKeys struct {
+ k []int32
+}
+
+func (self *sortedKeys) Len() int { return len(self.k) }
+func (self *sortedKeys) Less(i, j int) bool { return self.k[i] < self.k[j] }
+func (self *sortedKeys) Swap(i, j int) { self.k[i], self.k[j] = self.k[j], self.k[i] }
+
+func sortKeys(m map[int32]common.Hash) []int32 {
+ sorted := new(sortedKeys)
+ sorted.k = make([]int32, len(m))
+ i := 0
+ for key, _ := range m {
+ sorted.k[i] = key
+ i++
+ }
+
+ sort.Sort(sorted)
+
+ return sorted.k
+}
diff --git a/whisper/sort_test.go b/whisper/sort_test.go
new file mode 100644
index 000000000..a61fde4c2
--- /dev/null
+++ b/whisper/sort_test.go
@@ -0,0 +1,23 @@
+package whisper
+
+import (
+ "testing"
+
+ "github.com/ethereum/go-ethereum/common"
+)
+
+func TestSorting(t *testing.T) {
+ m := map[int32]common.Hash{
+ 1: {1},
+ 3: {3},
+ 2: {2},
+ 5: {5},
+ }
+ exp := []int32{1, 2, 3, 5}
+ res := sortKeys(m)
+ for i, k := range res {
+ if k != exp[i] {
+ t.Error(k, "failed. Expected", exp[i])
+ }
+ }
+}
diff --git a/whisper/util.go b/whisper/util.go
new file mode 100644
index 000000000..7a222395f
--- /dev/null
+++ b/whisper/util.go
@@ -0,0 +1,36 @@
+package whisper
+
+import "github.com/ethereum/go-ethereum/crypto"
+
+func hashTopic(topic []byte) []byte {
+ return crypto.Sha3(topic)[:4]
+}
+
+// NOTE this isn't DRY, but I don't want to iterate twice.
+
+// Returns a formatted topics byte slice.
+// data: unformatted data (e.g., no hashes needed)
+func Topics(data [][]byte) [][]byte {
+ d := make([][]byte, len(data))
+ for i, byts := range data {
+ d[i] = hashTopic(byts)
+ }
+ return d
+}
+
+func TopicsFromString(data ...string) [][]byte {
+ d := make([][]byte, len(data))
+ for i, str := range data {
+ d[i] = hashTopic([]byte(str))
+ }
+ return d
+}
+
+func bytesToMap(s [][]byte) map[string]struct{} {
+ m := make(map[string]struct{})
+ for _, topic := range s {
+ m[string(topic)] = struct{}{}
+ }
+
+ return m
+}
diff --git a/whisper/whisper.go b/whisper/whisper.go
new file mode 100644
index 000000000..1d019aea5
--- /dev/null
+++ b/whisper/whisper.go
@@ -0,0 +1,275 @@
+package whisper
+
+import (
+ "crypto/ecdsa"
+ "errors"
+ "sync"
+ "time"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/crypto"
+ "github.com/ethereum/go-ethereum/crypto/ecies"
+ "github.com/ethereum/go-ethereum/event/filter"
+ "github.com/ethereum/go-ethereum/logger"
+ "github.com/ethereum/go-ethereum/p2p"
+ "gopkg.in/fatih/set.v0"
+)
+
+const (
+ statusMsg = 0x0
+ envelopesMsg = 0x01
+ whisperVersion = 0x02
+)
+
+type MessageEvent struct {
+ To *ecdsa.PrivateKey
+ From *ecdsa.PublicKey
+ Message *Message
+}
+
+const DefaultTtl = 50 * time.Second
+
+var wlogger = logger.NewLogger("SHH")
+
+type Whisper struct {
+ protocol p2p.Protocol
+ filters *filter.Filters
+
+ mmu sync.RWMutex
+ messages map[common.Hash]*Envelope
+ expiry map[uint32]*set.SetNonTS
+
+ quit chan struct{}
+
+ keys map[string]*ecdsa.PrivateKey
+}
+
+func New() *Whisper {
+ whisper := &Whisper{
+ messages: make(map[common.Hash]*Envelope),
+ filters: filter.New(),
+ expiry: make(map[uint32]*set.SetNonTS),
+ quit: make(chan struct{}),
+ keys: make(map[string]*ecdsa.PrivateKey),
+ }
+ whisper.filters.Start()
+
+ // p2p whisper sub protocol handler
+ whisper.protocol = p2p.Protocol{
+ Name: "shh",
+ Version: uint(whisperVersion),
+ Length: 2,
+ Run: whisper.msgHandler,
+ }
+
+ return whisper
+}
+
+func (self *Whisper) Version() uint {
+ return self.protocol.Version
+}
+
+func (self *Whisper) Start() {
+ wlogger.Infoln("Whisper started")
+ go self.update()
+}
+
+func (self *Whisper) Stop() {
+ close(self.quit)
+}
+
+func (self *Whisper) Send(envelope *Envelope) error {
+ return self.add(envelope)
+}
+
+func (self *Whisper) NewIdentity() *ecdsa.PrivateKey {
+ key, err := crypto.GenerateKey()
+ if err != nil {
+ panic(err)
+ }
+
+ self.keys[string(crypto.FromECDSAPub(&key.PublicKey))] = key
+
+ return key
+}
+
+func (self *Whisper) HasIdentity(key *ecdsa.PublicKey) bool {
+ return self.keys[string(crypto.FromECDSAPub(key))] != nil
+}
+
+func (self *Whisper) GetIdentity(key *ecdsa.PublicKey) *ecdsa.PrivateKey {
+ return self.keys[string(crypto.FromECDSAPub(key))]
+}
+
+// func (self *Whisper) RemoveIdentity(key *ecdsa.PublicKey) bool {
+// k := string(crypto.FromECDSAPub(key))
+// if _, ok := self.keys[k]; ok {
+// delete(self.keys, k)
+// return true
+// }
+// return false
+// }
+
+func (self *Whisper) Watch(opts Filter) int {
+ return self.filters.Install(filter.Generic{
+ Str1: string(crypto.FromECDSAPub(opts.To)),
+ Str2: string(crypto.FromECDSAPub(opts.From)),
+ Data: bytesToMap(opts.Topics),
+ Fn: func(data interface{}) {
+ opts.Fn(data.(*Message))
+ },
+ })
+}
+
+func (self *Whisper) Unwatch(id int) {
+ self.filters.Uninstall(id)
+}
+
+func (self *Whisper) Messages(id int) (messages []*Message) {
+ filter := self.filters.Get(id)
+ if filter != nil {
+ for _, e := range self.messages {
+ if msg, key := self.open(e); msg != nil {
+ f := createFilter(msg, e.Topics, key)
+ if self.filters.Match(filter, f) {
+ messages = append(messages, msg)
+ }
+ }
+ }
+ }
+
+ return
+}
+
+// Main handler for passing whisper messages to whisper peer objects
+func (self *Whisper) msgHandler(peer *p2p.Peer, ws p2p.MsgReadWriter) error {
+ wpeer := NewPeer(self, peer, ws)
+ // initialise whisper peer (handshake/status)
+ if err := wpeer.init(); err != nil {
+ return err
+ }
+ // kick of the main handler for broadcasting/managing envelopes
+ go wpeer.start()
+ defer wpeer.stop()
+
+ // Main *read* loop. Writing is done by the peer it self.
+ for {
+ msg, err := ws.ReadMsg()
+ if err != nil {
+ return err
+ }
+
+ var envelopes []*Envelope
+ if err := msg.Decode(&envelopes); err != nil {
+ peer.Infoln(err)
+ continue
+ }
+
+ for _, envelope := range envelopes {
+ if err := self.add(envelope); err != nil {
+ // TODO Punish peer here. Invalid envelope.
+ peer.Infoln(err)
+ }
+ wpeer.addKnown(envelope)
+ }
+ }
+}
+
+// takes care of adding envelopes to the messages pool. At this moment no sanity checks are being performed.
+func (self *Whisper) add(envelope *Envelope) error {
+ if !envelope.valid() {
+ return errors.New("invalid pow provided for envelope")
+ }
+
+ self.mmu.Lock()
+ defer self.mmu.Unlock()
+
+ hash := envelope.Hash()
+ self.messages[hash] = envelope
+ if self.expiry[envelope.Expiry] == nil {
+ self.expiry[envelope.Expiry] = set.NewNonTS()
+ }
+
+ if !self.expiry[envelope.Expiry].Has(hash) {
+ self.expiry[envelope.Expiry].Add(hash)
+ go self.postEvent(envelope)
+ }
+
+ wlogger.DebugDetailf("added whisper envelope %x\n", envelope)
+
+ return nil
+}
+
+func (self *Whisper) update() {
+ expire := time.NewTicker(800 * time.Millisecond)
+out:
+ for {
+ select {
+ case <-expire.C:
+ self.expire()
+ case <-self.quit:
+ break out
+ }
+ }
+}
+
+func (self *Whisper) expire() {
+ self.mmu.Lock()
+ defer self.mmu.Unlock()
+
+ now := uint32(time.Now().Unix())
+ for then, hashSet := range self.expiry {
+ if then > now {
+ continue
+ }
+
+ hashSet.Each(func(v interface{}) bool {
+ delete(self.messages, v.(common.Hash))
+ return true
+ })
+ self.expiry[then].Clear()
+ }
+}
+
+func (self *Whisper) envelopes() (envelopes []*Envelope) {
+ self.mmu.RLock()
+ defer self.mmu.RUnlock()
+
+ envelopes = make([]*Envelope, len(self.messages))
+ i := 0
+ for _, envelope := range self.messages {
+ envelopes[i] = envelope
+ i++
+ }
+
+ return
+}
+
+func (self *Whisper) postEvent(envelope *Envelope) {
+ if message, key := self.open(envelope); message != nil {
+ self.filters.Notify(createFilter(message, envelope.Topics, key), message)
+ }
+}
+
+func (self *Whisper) open(envelope *Envelope) (*Message, *ecdsa.PrivateKey) {
+ for _, key := range self.keys {
+ if message, err := envelope.Open(key); err == nil || (err != nil && err == ecies.ErrInvalidPublicKey) {
+ message.To = &key.PublicKey
+
+ return message, key
+ }
+ }
+
+ return nil, nil
+}
+
+func (self *Whisper) Protocol() p2p.Protocol {
+ return self.protocol
+}
+
+func createFilter(message *Message, topics [][]byte, key *ecdsa.PrivateKey) filter.Filter {
+ return filter.Generic{
+ Str1: string(crypto.FromECDSAPub(&key.PublicKey)), Str2: string(crypto.FromECDSAPub(message.Recover())),
+ Data: bytesToMap(topics),
+ }
+}
diff --git a/whisper/whisper_test.go b/whisper/whisper_test.go
new file mode 100644
index 000000000..3e3945a0a
--- /dev/null
+++ b/whisper/whisper_test.go
@@ -0,0 +1,38 @@
+package whisper
+
+import (
+ "fmt"
+ "testing"
+ "time"
+)
+
+func TestEvent(t *testing.T) {
+ res := make(chan *Message, 1)
+ whisper := New()
+ id := whisper.NewIdentity()
+ whisper.Watch(Filter{
+ To: &id.PublicKey,
+ Fn: func(msg *Message) {
+ res <- msg
+ },
+ })
+
+ msg := NewMessage([]byte(fmt.Sprintf("Hello world. This is whisper-go. Incase you're wondering; the time is %v", time.Now())))
+ envelope, err := msg.Seal(DefaultPow, Opts{
+ Ttl: DefaultTtl,
+ From: id,
+ To: &id.PublicKey,
+ })
+ if err != nil {
+ fmt.Println(err)
+ t.FailNow()
+ }
+
+ tick := time.NewTicker(time.Second)
+ whisper.postEvent(envelope)
+ select {
+ case <-res:
+ case <-tick.C:
+ t.Error("did not receive message")
+ }
+}
diff --git a/xeth/frontend.go b/xeth/frontend.go
new file mode 100644
index 000000000..8deb5c98c
--- /dev/null
+++ b/xeth/frontend.go
@@ -0,0 +1,32 @@
+package xeth
+
+import (
+ "github.com/ethereum/go-ethereum/core/types"
+)
+
+// Frontend should be implemented by users of XEth. Its methods are
+// called whenever XEth makes a decision that requires user input.
+type Frontend interface {
+ // UnlockAccount is called when a transaction needs to be signed
+ // but the key corresponding to the transaction's sender is
+ // locked.
+ //
+ // It should unlock the account with the given address and return
+ // true if unlocking succeeded.
+ UnlockAccount(address []byte) bool
+
+ // This is called for all transactions inititated through
+ // Transact. It should prompt the user to confirm the transaction
+ // and return true if the transaction was acknowledged.
+ //
+ // ConfirmTransaction is not used for Call transactions
+ // because they cannot change any state.
+ ConfirmTransaction(tx *types.Transaction) bool
+}
+
+// dummyFrontend is a non-interactive frontend that allows all
+// transactions but cannot not unlock any keys.
+type dummyFrontend struct{}
+
+func (dummyFrontend) UnlockAccount([]byte) bool { return false }
+func (dummyFrontend) ConfirmTransaction(*types.Transaction) bool { return true }
diff --git a/xeth/state.go b/xeth/state.go
new file mode 100644
index 000000000..669cf91e6
--- /dev/null
+++ b/xeth/state.go
@@ -0,0 +1,36 @@
+package xeth
+
+import (
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/core/state"
+)
+
+type State struct {
+ xeth *XEth
+ state *state.StateDB
+}
+
+func NewState(xeth *XEth, statedb *state.StateDB) *State {
+ return &State{xeth, statedb}
+}
+
+func (self *State) State() *state.StateDB {
+ return self.state
+}
+
+func (self *State) Get(addr string) *Object {
+ return &Object{self.state.GetStateObject(common.HexToAddress(addr))}
+}
+
+func (self *State) SafeGet(addr string) *Object {
+ return &Object{self.safeGet(addr)}
+}
+
+func (self *State) safeGet(addr string) *state.StateObject {
+ object := self.state.GetStateObject(common.HexToAddress(addr))
+ if object == nil {
+ object = state.NewStateObject(common.HexToAddress(addr), self.xeth.backend.StateDb())
+ }
+
+ return object
+}
diff --git a/xeth/types.go b/xeth/types.go
new file mode 100644
index 000000000..3f96f8f8b
--- /dev/null
+++ b/xeth/types.go
@@ -0,0 +1,223 @@
+package xeth
+
+import (
+ "bytes"
+ "fmt"
+ "strings"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/core"
+ "github.com/ethereum/go-ethereum/core/state"
+ "github.com/ethereum/go-ethereum/core/types"
+ "github.com/ethereum/go-ethereum/crypto"
+ "github.com/ethereum/go-ethereum/p2p"
+ "github.com/ethereum/go-ethereum/rlp"
+)
+
+type Object struct {
+ *state.StateObject
+}
+
+func NewObject(state *state.StateObject) *Object {
+ return &Object{state}
+}
+
+func (self *Object) StorageString(str string) *common.Value {
+ if common.IsHex(str) {
+ return self.storage(common.Hex2Bytes(str[2:]))
+ } else {
+ return self.storage(common.RightPadBytes([]byte(str), 32))
+ }
+}
+
+func (self *Object) StorageValue(addr *common.Value) *common.Value {
+ return self.storage(addr.Bytes())
+}
+
+func (self *Object) storage(addr []byte) *common.Value {
+ return self.StateObject.GetStorage(common.BigD(addr))
+}
+
+func (self *Object) Storage() (storage map[string]string) {
+ storage = make(map[string]string)
+
+ it := self.StateObject.Trie().Iterator()
+ for it.Next() {
+ var data []byte
+ rlp.Decode(bytes.NewReader(it.Value), &data)
+ storage[common.ToHex(self.Trie().GetKey(it.Key))] = common.ToHex(data)
+ }
+
+ return
+}
+
+// Block interface exposed to QML
+type Block struct {
+ //Transactions string `json:"transactions"`
+ ref *types.Block
+ Size string `json:"size"`
+ Number int `json:"number"`
+ Hash string `json:"hash"`
+ Transactions *common.List `json:"transactions"`
+ Uncles *common.List `json:"uncles"`
+ Time int64 `json:"time"`
+ Coinbase string `json:"coinbase"`
+ Name string `json:"name"`
+ GasLimit string `json:"gasLimit"`
+ GasUsed string `json:"gasUsed"`
+ PrevHash string `json:"prevHash"`
+ Bloom string `json:"bloom"`
+ Raw string `json:"raw"`
+}
+
+// Creates a new QML Block from a chain block
+func NewBlock(block *types.Block) *Block {
+ if block == nil {
+ return &Block{}
+ }
+
+ ptxs := make([]*Transaction, len(block.Transactions()))
+ for i, tx := range block.Transactions() {
+ ptxs[i] = NewTx(tx)
+ }
+ txlist := common.NewList(ptxs)
+
+ puncles := make([]*Block, len(block.Uncles()))
+ for i, uncle := range block.Uncles() {
+ puncles[i] = NewBlock(types.NewBlockWithHeader(uncle))
+ }
+ ulist := common.NewList(puncles)
+
+ return &Block{
+ ref: block, Size: block.Size().String(),
+ Number: int(block.NumberU64()), GasUsed: block.GasUsed().String(),
+ GasLimit: block.GasLimit().String(), Hash: block.Hash().Hex(),
+ Transactions: txlist, Uncles: ulist,
+ Time: block.Time(),
+ Coinbase: block.Coinbase().Hex(),
+ PrevHash: block.ParentHash().Hex(),
+ Bloom: common.ToHex(block.Bloom().Bytes()),
+ Raw: block.String(),
+ }
+}
+
+func (self *Block) ToString() string {
+ if self.ref != nil {
+ return self.ref.String()
+ }
+
+ return ""
+}
+
+func (self *Block) GetTransaction(hash string) *Transaction {
+ tx := self.ref.Transaction(common.HexToHash(hash))
+ if tx == nil {
+ return nil
+ }
+
+ return NewTx(tx)
+}
+
+type Transaction struct {
+ ref *types.Transaction
+
+ Value string `json:"value"`
+ Gas string `json:"gas"`
+ GasPrice string `json:"gasPrice"`
+ Hash string `json:"hash"`
+ Address string `json:"address"`
+ Sender string `json:"sender"`
+ RawData string `json:"rawData"`
+ Data string `json:"data"`
+ Contract bool `json:"isContract"`
+ CreatesContract bool `json:"createsContract"`
+ Confirmations int `json:"confirmations"`
+}
+
+func NewTx(tx *types.Transaction) *Transaction {
+ hash := tx.Hash().Hex()
+ receiver := tx.To().Hex()
+ if len(receiver) == 0 {
+ receiver = core.AddressFromMessage(tx).Hex()
+ }
+ sender, _ := tx.From()
+ createsContract := core.MessageCreatesContract(tx)
+
+ var data string
+ if createsContract {
+ data = strings.Join(core.Disassemble(tx.Data()), "\n")
+ } else {
+ data = common.ToHex(tx.Data())
+ }
+
+ return &Transaction{ref: tx, Hash: hash, Value: common.CurrencyToString(tx.Value()), Address: receiver, Contract: createsContract, Gas: tx.Gas().String(), GasPrice: tx.GasPrice().String(), Data: data, Sender: sender.Hex(), CreatesContract: createsContract, RawData: common.ToHex(tx.Data())}
+}
+
+func (self *Transaction) ToString() string {
+ return self.ref.String()
+}
+
+type Key struct {
+ Address string `json:"address"`
+ PrivateKey string `json:"privateKey"`
+ PublicKey string `json:"publicKey"`
+}
+
+func NewKey(key *crypto.KeyPair) *Key {
+ return &Key{common.ToHex(key.Address()), common.ToHex(key.PrivateKey), common.ToHex(key.PublicKey)}
+}
+
+type PReceipt struct {
+ CreatedContract bool `json:"createdContract"`
+ Address string `json:"address"`
+ Hash string `json:"hash"`
+ Sender string `json:"sender"`
+}
+
+func NewPReciept(contractCreation bool, creationAddress, hash, address []byte) *PReceipt {
+ return &PReceipt{
+ contractCreation,
+ common.ToHex(creationAddress),
+ common.ToHex(hash),
+ common.ToHex(address),
+ }
+}
+
+// Peer interface exposed to QML
+
+type Peer struct {
+ ref *p2p.Peer
+ Ip string `json:"ip"`
+ Version string `json:"version"`
+ Caps string `json:"caps"`
+}
+
+func NewPeer(peer *p2p.Peer) *Peer {
+ var caps []string
+ for _, cap := range peer.Caps() {
+ caps = append(caps, fmt.Sprintf("%s/%d", cap.Name, cap.Version))
+ }
+
+ return &Peer{
+ ref: peer,
+ Ip: fmt.Sprintf("%v", peer.RemoteAddr()),
+ Version: fmt.Sprintf("%v", peer.ID()),
+ Caps: fmt.Sprintf("%v", caps),
+ }
+}
+
+type Receipt struct {
+ CreatedContract bool `json:"createdContract"`
+ Address string `json:"address"`
+ Hash string `json:"hash"`
+ Sender string `json:"sender"`
+}
+
+func NewReciept(contractCreation bool, creationAddress, hash, address []byte) *Receipt {
+ return &Receipt{
+ contractCreation,
+ common.ToHex(creationAddress),
+ common.ToHex(hash),
+ common.ToHex(address),
+ }
+}
diff --git a/xeth/whisper.go b/xeth/whisper.go
new file mode 100644
index 000000000..72e1ee04f
--- /dev/null
+++ b/xeth/whisper.go
@@ -0,0 +1,120 @@
+package xeth
+
+import (
+ "errors"
+ "time"
+
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/crypto"
+ "github.com/ethereum/go-ethereum/logger"
+ "github.com/ethereum/go-ethereum/whisper"
+)
+
+var qlogger = logger.NewLogger("XSHH")
+
+type Whisper struct {
+ *whisper.Whisper
+}
+
+func NewWhisper(w *whisper.Whisper) *Whisper {
+ return &Whisper{w}
+}
+
+func (self *Whisper) Post(payload string, to, from string, topics []string, priority, ttl uint32) error {
+ if priority == 0 {
+ priority = 1000
+ }
+
+ if ttl == 0 {
+ ttl = 100
+ }
+
+ pk := crypto.ToECDSAPub(common.FromHex(from))
+ if key := self.Whisper.GetIdentity(pk); key != nil || len(from) == 0 {
+ msg := whisper.NewMessage(common.FromHex(payload))
+ envelope, err := msg.Seal(time.Duration(priority*100000), whisper.Opts{
+ Ttl: time.Duration(ttl) * time.Second,
+ To: crypto.ToECDSAPub(common.FromHex(to)),
+ From: key,
+ Topics: whisper.TopicsFromString(topics...),
+ })
+
+ if err != nil {
+ return err
+ }
+
+ if err := self.Whisper.Send(envelope); err != nil {
+ return err
+ }
+ } else {
+ return errors.New("unmatched pub / priv for seal")
+ }
+
+ return nil
+}
+
+func (self *Whisper) NewIdentity() string {
+ key := self.Whisper.NewIdentity()
+
+ return common.ToHex(crypto.FromECDSAPub(&key.PublicKey))
+}
+
+func (self *Whisper) HasIdentity(key string) bool {
+ return self.Whisper.HasIdentity(crypto.ToECDSAPub(common.FromHex(key)))
+}
+
+// func (self *Whisper) RemoveIdentity(key string) bool {
+// return self.Whisper.RemoveIdentity(crypto.ToECDSAPub(common.FromHex(key)))
+// }
+
+func (self *Whisper) Watch(opts *Options) int {
+ filter := whisper.Filter{
+ To: crypto.ToECDSAPub(common.FromHex(opts.To)),
+ From: crypto.ToECDSAPub(common.FromHex(opts.From)),
+ Topics: whisper.TopicsFromString(opts.Topics...),
+ }
+
+ var i int
+ filter.Fn = func(msg *whisper.Message) {
+ opts.Fn(NewWhisperMessage(msg))
+ }
+
+ i = self.Whisper.Watch(filter)
+
+ return i
+}
+
+func (self *Whisper) Messages(id int) (messages []WhisperMessage) {
+ msgs := self.Whisper.Messages(id)
+ messages = make([]WhisperMessage, len(msgs))
+ for i, message := range msgs {
+ messages[i] = NewWhisperMessage(message)
+ }
+
+ return
+}
+
+type Options struct {
+ To string
+ From string
+ Topics []string
+ Fn func(msg WhisperMessage)
+}
+
+type WhisperMessage struct {
+ ref *whisper.Message
+ Payload string `json:"payload"`
+ To string `json:"to"`
+ From string `json:"from"`
+ Sent int64 `json:"sent"`
+}
+
+func NewWhisperMessage(msg *whisper.Message) WhisperMessage {
+ return WhisperMessage{
+ ref: msg,
+ Payload: common.ToHex(msg.Payload),
+ From: common.ToHex(crypto.FromECDSAPub(msg.Recover())),
+ To: common.ToHex(crypto.FromECDSAPub(msg.To)),
+ Sent: msg.Sent,
+ }
+}
diff --git a/xeth/xeth.go b/xeth/xeth.go
new file mode 100644
index 000000000..b203e45de
--- /dev/null
+++ b/xeth/xeth.go
@@ -0,0 +1,729 @@
+// eXtended ETHereum
+package xeth
+
+import (
+ "bytes"
+ "encoding/json"
+ "fmt"
+ "math/big"
+ "sync"
+ "time"
+
+ "github.com/ethereum/go-ethereum/accounts"
+ "github.com/ethereum/go-ethereum/common"
+ "github.com/ethereum/go-ethereum/core"
+ "github.com/ethereum/go-ethereum/core/state"
+ "github.com/ethereum/go-ethereum/core/types"
+ "github.com/ethereum/go-ethereum/crypto"
+ "github.com/ethereum/go-ethereum/eth"
+ "github.com/ethereum/go-ethereum/event/filter"
+ "github.com/ethereum/go-ethereum/logger"
+ "github.com/ethereum/go-ethereum/miner"
+ "github.com/ethereum/go-ethereum/rlp"
+)
+
+var (
+ pipelogger = logger.NewLogger("XETH")
+ filterTickerTime = 5 * time.Minute
+ defaultGasPrice = big.NewInt(10000000000000) //150000000000
+ defaultGas = big.NewInt(90000) //500000
+)
+
+func DefaultGas() *big.Int { return new(big.Int).Set(defaultGas) }
+func DefaultGasPrice() *big.Int { return new(big.Int).Set(defaultGasPrice) }
+
+type XEth struct {
+ backend *eth.Ethereum
+ frontend Frontend
+
+ state *State
+ whisper *Whisper
+
+ quit chan struct{}
+ filterManager *filter.FilterManager
+
+ logMut sync.RWMutex
+ logs map[int]*logFilter
+
+ messagesMut sync.RWMutex
+ messages map[int]*whisperFilter
+
+ // regmut sync.Mutex
+ // register map[string][]*interface{} // TODO improve return type
+
+ agent *miner.RemoteAgent
+}
+
+// New creates an XEth that uses the given frontend.
+// If a nil Frontend is provided, a default frontend which
+// confirms all transactions will be used.
+func New(eth *eth.Ethereum, frontend Frontend) *XEth {
+ xeth := &XEth{
+ backend: eth,
+ frontend: frontend,
+ whisper: NewWhisper(eth.Whisper()),
+ quit: make(chan struct{}),
+ filterManager: filter.NewFilterManager(eth.EventMux()),
+ logs: make(map[int]*logFilter),
+ messages: make(map[int]*whisperFilter),
+ agent: miner.NewRemoteAgent(),
+ }
+ eth.Miner().Register(xeth.agent)
+
+ if frontend == nil {
+ xeth.frontend = dummyFrontend{}
+ }
+ xeth.state = NewState(xeth, xeth.backend.ChainManager().TransState())
+
+ go xeth.start()
+ go xeth.filterManager.Start()
+
+ return xeth
+}
+
+func (self *XEth) start() {
+ timer := time.NewTicker(2 * time.Second)
+done:
+ for {
+ select {
+ case <-timer.C:
+ self.logMut.Lock()
+ self.messagesMut.Lock()
+ for id, filter := range self.logs {
+ if time.Since(filter.timeout) > filterTickerTime {
+ self.filterManager.UninstallFilter(id)
+ delete(self.logs, id)
+ }
+ }
+
+ for id, filter := range self.messages {
+ if time.Since(filter.timeout) > filterTickerTime {
+ self.Whisper().Unwatch(id)
+ delete(self.messages, id)
+ }
+ }
+ self.messagesMut.Unlock()
+ self.logMut.Unlock()
+ case <-self.quit:
+ break done
+ }
+ }
+}
+
+func (self *XEth) stop() {
+ close(self.quit)
+}
+
+func cAddress(a []string) []common.Address {
+ bslice := make([]common.Address, len(a))
+ for i, addr := range a {
+ bslice[i] = common.HexToAddress(addr)
+ }
+ return bslice
+}
+
+func cTopics(t [][]string) [][]common.Hash {
+ topics := make([][]common.Hash, len(t))
+ for i, iv := range t {
+ topics[i] = make([]common.Hash, len(iv))
+ for j, jv := range iv {
+ topics[i][j] = common.HexToHash(jv)
+ }
+ }
+ return topics
+}
+
+func (self *XEth) RemoteMining() *miner.RemoteAgent { return self.agent }
+
+func (self *XEth) AtStateNum(num int64) *XEth {
+ block := self.getBlockByHeight(num)
+
+ var st *state.StateDB
+ if block != nil {
+ st = state.New(block.Root(), self.backend.StateDb())
+ } else {
+ st = self.backend.ChainManager().State()
+ }
+
+ return self.withState(st)
+}
+
+func (self *XEth) withState(statedb *state.StateDB) *XEth {
+ xeth := &XEth{
+ backend: self.backend,
+ }
+
+ xeth.state = NewState(xeth, statedb)
+ return xeth
+}
+
+func (self *XEth) State() *State { return self.state }
+
+func (self *XEth) Whisper() *Whisper { return self.whisper }
+
+func (self *XEth) getBlockByHeight(height int64) *types.Block {
+ var num uint64
+
+ if height < 0 {
+ num = self.CurrentBlock().NumberU64() + uint64(-1*height)
+ } else {
+ num = uint64(height)
+ }
+
+ return self.backend.ChainManager().GetBlockByNumber(num)
+}
+
+func (self *XEth) BlockByHash(strHash string) *Block {
+ hash := common.HexToHash(strHash)
+ block := self.backend.ChainManager().GetBlock(hash)
+
+ return NewBlock(block)
+}
+
+func (self *XEth) EthBlockByHash(strHash string) *types.Block {
+ hash := common.HexToHash(strHash)
+ block := self.backend.ChainManager().GetBlock(hash)
+
+ return block
+}
+
+func (self *XEth) EthTransactionByHash(hash string) (tx *types.Transaction, blhash common.Hash, blnum *big.Int, txi uint64) {
+ data, _ := self.backend.ExtraDb().Get(common.FromHex(hash))
+ if len(data) != 0 {
+ tx = types.NewTransactionFromBytes(data)
+ }
+
+ // meta
+ var txExtra struct {
+ BlockHash common.Hash
+ BlockIndex int64
+ Index uint64
+ }
+
+ v, _ := self.backend.ExtraDb().Get(append(common.FromHex(hash), 0x0001))
+ r := bytes.NewReader(v)
+ err := rlp.Decode(r, &txExtra)
+ if err == nil {
+ blhash = txExtra.BlockHash
+ blnum = big.NewInt(txExtra.BlockIndex)
+ txi = txExtra.Index
+ }
+
+ return
+}
+
+func (self *XEth) BlockByNumber(num int64) *Block {
+ return NewBlock(self.getBlockByHeight(num))
+}
+
+func (self *XEth) EthBlockByNumber(num int64) *types.Block {
+ return self.getBlockByHeight(num)
+}
+
+func (self *XEth) CurrentBlock() *types.Block {
+ return self.backend.ChainManager().CurrentBlock()
+}
+
+func (self *XEth) Block(v interface{}) *Block {
+ if n, ok := v.(int32); ok {
+ return self.BlockByNumber(int64(n))
+ } else if str, ok := v.(string); ok {
+ return self.BlockByHash(str)
+ } else if f, ok := v.(float64); ok { // Don't ask ...
+ return self.BlockByNumber(int64(f))
+ }
+
+ return nil
+}
+
+func (self *XEth) Accounts() []string {
+ // TODO: check err?
+ accounts, _ := self.backend.AccountManager().Accounts()
+ accountAddresses := make([]string, len(accounts))
+ for i, ac := range accounts {
+ accountAddresses[i] = common.ToHex(ac.Address)
+ }
+ return accountAddresses
+}
+
+func (self *XEth) DbPut(key, val []byte) bool {
+ self.backend.ExtraDb().Put(key, val)
+ return true
+}
+
+func (self *XEth) DbGet(key []byte) ([]byte, error) {
+ val, err := self.backend.ExtraDb().Get(key)
+ return val, err
+}
+
+func (self *XEth) PeerCount() int {
+ return self.backend.PeerCount()
+}
+
+func (self *XEth) IsMining() bool {
+ return self.backend.IsMining()
+}
+
+func (self *XEth) EthVersion() string {
+ return fmt.Sprintf("%d", self.backend.EthVersion())
+}
+
+func (self *XEth) NetworkVersion() string {
+ return fmt.Sprintf("%d", self.backend.NetVersion())
+}
+
+func (self *XEth) WhisperVersion() string {
+ return fmt.Sprintf("%d", self.backend.ShhVersion())
+}
+
+func (self *XEth) ClientVersion() string {
+ return self.backend.ClientVersion()
+}
+
+func (self *XEth) SetMining(shouldmine bool) bool {
+ ismining := self.backend.IsMining()
+ if shouldmine && !ismining {
+ err := self.backend.StartMining()
+ return err == nil
+ }
+ if ismining && !shouldmine {
+ self.backend.StopMining()
+ }
+ return self.backend.IsMining()
+}
+
+func (self *XEth) IsListening() bool {
+ return self.backend.IsListening()
+}
+
+func (self *XEth) Coinbase() string {
+ eb, _ := self.backend.Etherbase()
+ return eb.Hex()
+}
+
+func (self *XEth) NumberToHuman(balance string) string {
+ b := common.Big(balance)
+
+ return common.CurrencyToString(b)
+}
+
+func (self *XEth) StorageAt(addr, storageAddr string) string {
+ return common.ToHex(self.State().state.GetState(common.HexToAddress(addr), common.HexToHash(storageAddr)))
+}
+
+func (self *XEth) BalanceAt(addr string) string {
+ return common.ToHex(self.State().state.GetBalance(common.HexToAddress(addr)).Bytes())
+}
+
+func (self *XEth) TxCountAt(address string) int {
+ return int(self.State().state.GetNonce(common.HexToAddress(address)))
+}
+
+func (self *XEth) CodeAt(address string) string {
+ return common.ToHex(self.State().state.GetCode(common.HexToAddress(address)))
+}
+
+func (self *XEth) CodeAtBytes(address string) []byte {
+ return self.State().SafeGet(address).Code()
+}
+
+func (self *XEth) IsContract(address string) bool {
+ return len(self.State().SafeGet(address).Code()) > 0
+}
+
+func (self *XEth) SecretToAddress(key string) string {
+ pair, err := crypto.NewKeyPairFromSec(common.FromHex(key))
+ if err != nil {
+ return ""
+ }
+
+ return common.ToHex(pair.Address())
+}
+
+func (self *XEth) RegisterFilter(earliest, latest int64, skip, max int, address []string, topics [][]string) int {
+ var id int
+ filter := core.NewFilter(self.backend)
+ filter.SetEarliestBlock(earliest)
+ filter.SetLatestBlock(latest)
+ filter.SetSkip(skip)
+ filter.SetMax(max)
+ filter.SetAddress(cAddress(address))
+ filter.SetTopics(cTopics(topics))
+ filter.LogsCallback = func(logs state.Logs) {
+ self.logMut.Lock()
+ defer self.logMut.Unlock()
+
+ self.logs[id].add(logs...)
+ }
+ id = self.filterManager.InstallFilter(filter)
+ self.logs[id] = &logFilter{timeout: time.Now()}
+
+ return id
+}
+
+func (self *XEth) UninstallFilter(id int) bool {
+ if _, ok := self.logs[id]; ok {
+ delete(self.logs, id)
+ self.filterManager.UninstallFilter(id)
+ return true
+ }
+
+ return false
+}
+
+func (self *XEth) NewFilterString(word string) int {
+ var id int
+ filter := core.NewFilter(self.backend)
+
+ switch word {
+ case "pending":
+ filter.PendingCallback = func(tx *types.Transaction) {
+ self.logMut.Lock()
+ defer self.logMut.Unlock()
+
+ self.logs[id].add(&state.StateLog{})
+ }
+ case "latest":
+ filter.BlockCallback = func(block *types.Block, logs state.Logs) {
+ self.logMut.Lock()
+ defer self.logMut.Unlock()
+
+ for _, log := range logs {
+ self.logs[id].add(log)
+ }
+ self.logs[id].add(&state.StateLog{})
+ }
+ }
+
+ id = self.filterManager.InstallFilter(filter)
+ self.logs[id] = &logFilter{timeout: time.Now()}
+
+ return id
+}
+
+func (self *XEth) FilterChanged(id int) state.Logs {
+ self.logMut.Lock()
+ defer self.logMut.Unlock()
+
+ if self.logs[id] != nil {
+ return self.logs[id].get()
+ }
+
+ return nil
+}
+
+func (self *XEth) Logs(id int) state.Logs {
+ self.logMut.Lock()
+ defer self.logMut.Unlock()
+
+ filter := self.filterManager.GetFilter(id)
+ if filter != nil {
+ return filter.Find()
+ }
+
+ return nil
+}
+
+func (self *XEth) AllLogs(earliest, latest int64, skip, max int, address []string, topics [][]string) state.Logs {
+ filter := core.NewFilter(self.backend)
+ filter.SetEarliestBlock(earliest)
+ filter.SetLatestBlock(latest)
+ filter.SetSkip(skip)
+ filter.SetMax(max)
+ filter.SetAddress(cAddress(address))
+ filter.SetTopics(cTopics(topics))
+
+ return filter.Find()
+}
+
+func (p *XEth) NewWhisperFilter(opts *Options) int {
+ var id int
+ opts.Fn = func(msg WhisperMessage) {
+ p.messagesMut.Lock()
+ defer p.messagesMut.Unlock()
+ p.messages[id].add(msg) // = append(p.messages[id], msg)
+ }
+ id = p.Whisper().Watch(opts)
+ p.messages[id] = &whisperFilter{timeout: time.Now()}
+ return id
+}
+
+func (p *XEth) UninstallWhisperFilter(id int) bool {
+ if _, ok := p.messages[id]; ok {
+ delete(p.messages, id)
+ return true
+ }
+
+ return false
+}
+
+func (self *XEth) MessagesChanged(id int) []WhisperMessage {
+ self.messagesMut.Lock()
+ defer self.messagesMut.Unlock()
+
+ if self.messages[id] != nil {
+ return self.messages[id].get()
+ }
+
+ return nil
+}
+
+// func (self *XEth) Register(args string) bool {
+// self.regmut.Lock()
+// defer self.regmut.Unlock()
+
+// if _, ok := self.register[args]; ok {
+// self.register[args] = nil // register with empty
+// }
+// return true
+// }
+
+// func (self *XEth) Unregister(args string) bool {
+// self.regmut.Lock()
+// defer self.regmut.Unlock()
+
+// if _, ok := self.register[args]; ok {
+// delete(self.register, args)
+// return true
+// }
+
+// return false
+// }
+
+// // TODO improve return type
+// func (self *XEth) PullWatchTx(args string) []*interface{} {
+// self.regmut.Lock()
+// defer self.regmut.Unlock()
+
+// txs := self.register[args]
+// self.register[args] = nil
+
+// return txs
+// }
+
+type KeyVal struct {
+ Key string `json:"key"`
+ Value string `json:"value"`
+}
+
+func (self *XEth) EachStorage(addr string) string {
+ var values []KeyVal
+ object := self.State().SafeGet(addr)
+ it := object.Trie().Iterator()
+ for it.Next() {
+ values = append(values, KeyVal{common.ToHex(object.Trie().GetKey(it.Key)), common.ToHex(it.Value)})
+ }
+
+ valuesJson, err := json.Marshal(values)
+ if err != nil {
+ return ""
+ }
+
+ return string(valuesJson)
+}
+
+func (self *XEth) ToAscii(str string) string {
+ padded := common.RightPadBytes([]byte(str), 32)
+
+ return "0x" + common.ToHex(padded)
+}
+
+func (self *XEth) FromAscii(str string) string {
+ if common.IsHex(str) {
+ str = str[2:]
+ }
+
+ return string(bytes.Trim(common.FromHex(str), "\x00"))
+}
+
+func (self *XEth) FromNumber(str string) string {
+ if common.IsHex(str) {
+ str = str[2:]
+ }
+
+ return common.BigD(common.FromHex(str)).String()
+}
+
+func (self *XEth) PushTx(encodedTx string) (string, error) {
+ tx := types.NewTransactionFromBytes(common.FromHex(encodedTx))
+ err := self.backend.TxPool().Add(tx)
+ if err != nil {
+ return "", err
+ }
+
+ if tx.To() == nil {
+ addr := core.AddressFromMessage(tx)
+ return addr.Hex(), nil
+ }
+ return tx.Hash().Hex(), nil
+}
+
+func (self *XEth) Call(fromStr, toStr, valueStr, gasStr, gasPriceStr, dataStr string) (string, error) {
+ statedb := self.State().State() //self.eth.ChainManager().TransState()
+ msg := callmsg{
+ from: statedb.GetOrNewStateObject(common.HexToAddress(fromStr)),
+ to: common.HexToAddress(toStr),
+ gas: common.Big(gasStr),
+ gasPrice: common.Big(gasPriceStr),
+ value: common.Big(valueStr),
+ data: common.FromHex(dataStr),
+ }
+
+ if msg.gas.Cmp(big.NewInt(0)) == 0 {
+ msg.gas = DefaultGas()
+ }
+
+ if msg.gasPrice.Cmp(big.NewInt(0)) == 0 {
+ msg.gasPrice = DefaultGasPrice()
+ }
+
+ block := self.CurrentBlock()
+ vmenv := core.NewEnv(statedb, self.backend.ChainManager(), msg, block)
+
+ res, err := vmenv.Call(msg.from, msg.to, msg.data, msg.gas, msg.gasPrice, msg.value)
+ return common.ToHex(res), err
+}
+
+func (self *XEth) Transact(fromStr, toStr, valueStr, gasStr, gasPriceStr, codeStr string) (string, error) {
+ var (
+ from = common.HexToAddress(fromStr)
+ to = common.HexToAddress(toStr)
+ value = common.NewValue(valueStr)
+ gas = common.Big(gasStr)
+ price = common.Big(gasPriceStr)
+ data []byte
+ contractCreation bool
+ )
+
+ // TODO if no_private_key then
+ //if _, exists := p.register[args.From]; exists {
+ // p.register[args.From] = append(p.register[args.From], args)
+ //} else {
+ /*
+ account := accounts.Get(common.FromHex(args.From))
+ if account != nil {
+ if account.Unlocked() {
+ if !unlockAccount(account) {
+ return
+ }
+ }
+
+ result, _ := account.Transact(common.FromHex(args.To), common.FromHex(args.Value), common.FromHex(args.Gas), common.FromHex(args.GasPrice), common.FromHex(args.Data))
+ if len(result) > 0 {
+ *reply = common.ToHex(result)
+ }
+ } else if _, exists := p.register[args.From]; exists {
+ p.register[ags.From] = append(p.register[args.From], args)
+ }
+ */
+
+ // TODO: align default values to have the same type, e.g. not depend on
+ // common.Value conversions later on
+ if gas.Cmp(big.NewInt(0)) == 0 {
+ gas = DefaultGas()
+ }
+
+ if price.Cmp(big.NewInt(0)) == 0 {
+ price = DefaultGasPrice()
+ }
+
+ data = common.FromHex(codeStr)
+ if len(toStr) == 0 {
+ contractCreation = true
+ }
+
+ var tx *types.Transaction
+ if contractCreation {
+ tx = types.NewContractCreationTx(value.BigInt(), gas, price, data)
+ } else {
+ tx = types.NewTransactionMessage(to, value.BigInt(), gas, price, data)
+ }
+
+ state := self.backend.ChainManager().TxState()
+ nonce := state.NewNonce(from)
+ tx.SetNonce(nonce)
+
+ if err := self.sign(tx, from, false); err != nil {
+ return "", err
+ }
+ if err := self.backend.TxPool().Add(tx); err != nil {
+ return "", err
+ }
+
+ if contractCreation {
+ addr := core.AddressFromMessage(tx)
+ pipelogger.Infof("Contract addr %x\n", addr)
+
+ return core.AddressFromMessage(tx).Hex(), nil
+ }
+ return tx.Hash().Hex(), nil
+}
+
+func (self *XEth) sign(tx *types.Transaction, from common.Address, didUnlock bool) error {
+ sig, err := self.backend.AccountManager().Sign(accounts.Account{Address: from.Bytes()}, tx.Hash().Bytes())
+ if err == accounts.ErrLocked {
+ if didUnlock {
+ return fmt.Errorf("sender account still locked after successful unlock")
+ }
+ if !self.frontend.UnlockAccount(from.Bytes()) {
+ return fmt.Errorf("could not unlock sender account")
+ }
+ // retry signing, the account should now be unlocked.
+ return self.sign(tx, from, true)
+ } else if err != nil {
+ return err
+ }
+ tx.SetSignatureValues(sig)
+ return nil
+}
+
+// callmsg is the message type used for call transations.
+type callmsg struct {
+ from *state.StateObject
+ to common.Address
+ gas, gasPrice *big.Int
+ value *big.Int
+ data []byte
+}
+
+// accessor boilerplate to implement core.Message
+func (m callmsg) From() (common.Address, error) { return m.from.Address(), nil }
+func (m callmsg) Nonce() uint64 { return m.from.Nonce() }
+func (m callmsg) To() *common.Address { return &m.to }
+func (m callmsg) GasPrice() *big.Int { return m.gasPrice }
+func (m callmsg) Gas() *big.Int { return m.gas }
+func (m callmsg) Value() *big.Int { return m.value }
+func (m callmsg) Data() []byte { return m.data }
+
+type whisperFilter struct {
+ messages []WhisperMessage
+ timeout time.Time
+ id int
+}
+
+func (w *whisperFilter) add(msgs ...WhisperMessage) {
+ w.messages = append(w.messages, msgs...)
+}
+func (w *whisperFilter) get() []WhisperMessage {
+ w.timeout = time.Now()
+ tmp := w.messages
+ w.messages = nil
+ return tmp
+}
+
+type logFilter struct {
+ logs state.Logs
+ timeout time.Time
+ id int
+}
+
+func (l *logFilter) add(logs ...state.Log) {
+ l.logs = append(l.logs, logs...)
+}
+
+func (l *logFilter) get() state.Logs {
+ l.timeout = time.Now()
+ tmp := l.logs
+ l.logs = nil
+ return tmp
+}